@shmidko61/lc-ui-kit 0.2.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/accordion.js CHANGED
@@ -15,9 +15,7 @@ function ae() {
15
15
  throw new Error("Accordion.Item должен использоваться внутри Accordion.");
16
16
  return t;
17
17
  }
18
- function ie({
19
- children: t
20
- }) {
18
+ function ie({ children: t }) {
21
19
  return /* @__PURE__ */ e(l, { align: "center", gap: 16, justify: "space-between", width: "100%", children: t });
22
20
  }
23
21
  function ce({
package/dist/box/box.d.ts CHANGED
@@ -8,5 +8,5 @@ type BoxComponentType = {
8
8
  displayName?: string;
9
9
  };
10
10
  export declare const Box: BoxComponentType;
11
+ export type { BorderRadiusItem, BorderRadiusKeys, BorderRadiusSides, BorderWidthItem, BorderWidthSides, PositionValue, UiKitAnyIndentationMargin, UiKitAnyIndentationPadding, UiKitArrayIndentation, UiKitAspectRatioProps, UiKitAspectRatioValue, UiKitAxisIndentationMargin, UiKitAxisIndentationPadding, UiKitBackgroundProps, UiKitBorderColor, UiKitBorderProps, UiKitBorderRadius, UiKitBorderWidth, UiKitBoxShadowProps, UiKitBoxShadowValue, UiKitColorProps, UiKitColorValue, UiKitCursorProps, UiKitDimensionProps, UiKitDisplayProps, UiKitIndentations, UiKitIndentationsProps, UiKitListStyleProps, UiKitMarginArrayIndentation, UiKitMarginIndentation, UiKitMixedXAxisIndentationMargin, UiKitMixedXAxisIndentationPadding, UiKitMixedYAxisIndentationMargin, UiKitMixedYAxisIndentationPadding, UiKitOpacityProps, UiKitOpacityValue, UiKitOutlineProps, UiKitOverflowProps, UiKitOverflowValue, UiKitPointerEventsProps, UiKitPointerEventsValue, UiKitPositionProps, UiKitTransformOriginValue, UiKitTransformProps, UiKitTransformValue, } from '../types';
11
12
  export type { BoxAs, BoxBackgroundValue, BoxBreakpointProps, BoxComponentProps, BoxProps, } from './box.types';
12
- export type { BorderRadiusItem, BorderRadiusKeys, BorderRadiusSides, BorderWidthItem, BorderWidthSides, PositionValue, UiKitAnyIndentationMargin, UiKitAnyIndentationPadding, UiKitArrayIndentation, UiKitAxisIndentationMargin, UiKitAxisIndentationPadding, UiKitDimensionProps, UiKitIndentations, UiKitIndentationsProps, UiKitMarginArrayIndentation, UiKitMarginIndentation, UiKitBackgroundProps, UiKitAspectRatioProps, UiKitAspectRatioValue, UiKitBoxShadowProps, UiKitBoxShadowValue, UiKitBorderColor, UiKitBorderProps, UiKitBorderRadius, UiKitBorderWidth, UiKitCursorProps, UiKitColorProps, UiKitColorValue, UiKitDisplayProps, UiKitListStyleProps, UiKitMixedXAxisIndentationMargin, UiKitMixedXAxisIndentationPadding, UiKitMixedYAxisIndentationMargin, UiKitMixedYAxisIndentationPadding, UiKitOutlineProps, UiKitOpacityProps, UiKitOpacityValue, UiKitOverflowProps, UiKitOverflowValue, UiKitPointerEventsProps, UiKitPointerEventsValue, UiKitPositionProps, } from '../types/index';
@@ -1,6 +1,6 @@
1
1
  import { ComponentPropsWithoutRef, ElementType, ReactNode } from 'react';
2
2
  import { ResponsiveStyleBreakpoint } from '../shared/responsive-style/responsive-style.types';
3
- import { UiKitBackgroundProps, UiKitBackgroundValue, UiKitAspectRatioProps, UiKitBoxShadowProps, UiKitBorderProps, UiKitColorProps, UiKitCursorProps, UiKitDimensionProps, UiKitIndentationsProps, UiKitDisplayProps, UiKitListStyleProps, UiKitOutlineProps, UiKitOpacityProps, UiKitOverflowProps, UiKitPointerEventsProps, UiKitPositionProps } from '../types/index';
3
+ import { UiKitAspectRatioProps, UiKitBackgroundProps, UiKitBackgroundValue, UiKitBorderProps, UiKitBoxShadowProps, UiKitColorProps, UiKitCursorProps, UiKitDimensionProps, UiKitDisplayProps, UiKitIndentationsProps, UiKitListStyleProps, UiKitOpacityProps, UiKitOutlineProps, UiKitOverflowProps, UiKitPointerEventsProps, UiKitPositionProps, UiKitTransformProps } from '../types';
4
4
  /**
5
5
  * Допустимые HTML-теги для Box.
6
6
  *
@@ -20,7 +20,7 @@ export type BoxBackgroundValue = UiKitBackgroundValue;
20
20
  /**
21
21
  * Стилевые props, общие для base-состояния и responsive overrides.
22
22
  */
23
- export type BoxStyleProps = UiKitDisplayProps & UiKitPositionProps & UiKitOverflowProps & UiKitAspectRatioProps & UiKitColorProps & UiKitOpacityProps & UiKitPointerEventsProps & UiKitBoxShadowProps & UiKitBackgroundProps & UiKitCursorProps & UiKitIndentationsProps & UiKitOutlineProps & UiKitListStyleProps & UiKitDimensionProps;
23
+ export type BoxStyleProps = UiKitDisplayProps & UiKitPositionProps & UiKitOverflowProps & UiKitAspectRatioProps & UiKitTransformProps & UiKitColorProps & UiKitOpacityProps & UiKitPointerEventsProps & UiKitBoxShadowProps & UiKitBackgroundProps & UiKitCursorProps & UiKitIndentationsProps & UiKitOutlineProps & UiKitListStyleProps & UiKitDimensionProps;
24
24
  /**
25
25
  * Собственные стилевые props Box поверх общих контрактов ui-kit.
26
26
  */
package/dist/box.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const to=require("react/jsx-runtime"),io=require("react"),X=require("./responsive-style.config-B2m9jVlX.cjs");function eo({background:t,backgroundColor:o,bg:i,bgSize:d,bgRepeat:u,bgPosition:a,border:v,boxShadow:f,color:l,cursor:b,opacity:c,overflow:s,overflowX:p,overflowY:x,pointerEvents:R,aspectRatio:g,p:O,m:A,outlineColor:k,outlineWidth:S,outlineOffset:z,outlineStyle:W,listStyle:h,display:C,position:r,width:T,maxWidth:L,minWidth:N,height:V,maxHeight:P,minHeight:w}){const e={};return i!==void 0?Bo(e,i):t!==void 0&&(e.background=I(t)),o!==void 0&&(e.backgroundColor=I(o)),d!==void 0&&(e.backgroundSize=ho(d)),u!==void 0&&(e.backgroundRepeat=$o(u)),a!==void 0&&(e.backgroundPosition=vo(a)),so(e,v),f!==void 0&&(e.boxShadow=m(f)),l!==void 0&&(e.color=m(l)),b!==void 0&&(e.cursor=b),c!==void 0&&(e.opacity=typeof c=="number"?c:m(c)),s!==void 0&&(e.overflowX=s,e.overflowY=s),p!==void 0&&(e.overflowX=p),x!==void 0&&(e.overflowY=x),R!==void 0&&(e.pointerEvents=R),g!==void 0&&(e.aspectRatio=typeof g=="number"?String(g):m(g)),ao(e,O),co(e,A),k!==void 0&&(e.outlineColor=m(k)),S!==void 0&&(e.outlineWidth=S),z!==void 0&&(e.outlineOffset=z),W!==void 0&&(e.outlineStyle=W),h?.position!==void 0&&(e.listStylePosition=h.position),h?.type!==void 0&&(e.listStyleType=h.type),C!==void 0&&(e.display=go(C)),r?.type!==void 0&&(e.position=r.type),r?.top!==void 0&&(e.top=j(r.top)),r?.left!==void 0&&(e.left=j(r.left)),r?.right!==void 0&&(e.right=j(r.right)),r?.bottom!==void 0&&(e.bottom=j(r.bottom)),r?.zIndex!==void 0&&(e.zIndex=r.zIndex),T!==void 0&&(e.width=$(T)),L!==void 0&&(e.maxWidth=$(L)),N!==void 0&&(e.minWidth=$(N)),V!==void 0&&(e.height=$(V)),P!==void 0&&(e.maxHeight=$(P)),w!==void 0&&(e.minHeight=$(w)),Object.keys(e).length>0?e:void 0}function no(t){const o=[],i={},d=t.groupParent===!0;q(t,o,i,"","",d);for(const u of X.responsiveBreakpoints){const a=t[u];a&&q(a,o,i,`${u}:`,`${u}-`,d)}return{className:o.join(" "),style:Object.keys(i).length>0?i:void 0}}function q(t,o,i,d="",u="",a=!1){const v=eo(t);for(const[f,l]of Object.entries(v??{})){if(l==null)continue;const b=String(l),c=ro(f,b);if(c){o.push(`${d}${c}`);continue}const s=`${u}${uo(f)}`,p=fo(f,s);p&&(i[`--${s}`]=b,o.push(`${d}${p}`))}if(t.bgGroup!==void 0){const f=`${u}group-background`;i[`--${f}`]=I(t.bgGroup),o.push(`${d}group-hover:[background:var(--${f})]`),a&&o.push(`${d}hover:[background:var(--${f})]`)}}function ro(t,o){if(t==="display")return o==="none"?"hidden":o;if(t==="position")return o==="inherit"?"[position:inherit]":o;if(t==="cursor")return`cursor-${o}`;if(t==="backgroundRepeat")return{"no-repeat":"bg-no-repeat",repeat:"bg-repeat",round:"bg-repeat-round",space:"bg-repeat-space","repeat-x":"bg-repeat-x","repeat-y":"bg-repeat-y"}[o];if(t==="backgroundSize")return{auto:"bg-auto",contain:"bg-contain",cover:"bg-cover"}[o];if(t==="backgroundPosition")return{bottom:"bg-bottom",center:"bg-center",left:"bg-left","left bottom":"bg-left-bottom","left top":"bg-left-top",right:"bg-right","right bottom":"bg-right-bottom","right top":"bg-right-top",top:"bg-top"}[o];if(t==="borderStyle")return o==="none"?"border-none":`border-${o}`;if(t==="outlineStyle")return o==="none"?"outline-none":`outline-${o}`;if(t==="listStylePosition")return`list-${o}`;if(t==="listStyleType")return`list-${o}`}function fo(t,o){const i=`var(--${o})`;return{background:`[background:${i}]`,backgroundColor:`bg-[${i}]`,backgroundPosition:`bg-[position:${i}]`,backgroundSize:`bg-[length:${i}]`,aspectRatio:`[aspect-ratio:${i}]`,borderBottomLeftRadius:`rounded-bl-[${i}]`,borderBottomRightRadius:`rounded-br-[${i}]`,borderBottomWidth:`border-b-[length:${i}]`,borderColor:`border-[color:${i}]`,borderLeftWidth:`border-l-[length:${i}]`,borderRadius:`rounded-[${i}]`,borderRightWidth:`border-r-[length:${i}]`,borderTopLeftRadius:`rounded-tl-[${i}]`,borderTopRightRadius:`rounded-tr-[${i}]`,borderTopWidth:`border-t-[length:${i}]`,borderWidth:`border-[length:${i}]`,boxShadow:`[box-shadow:${i}]`,bottom:`bottom-[${i}]`,color:`[color:${i}]`,height:`h-[${i}]`,left:`left-[${i}]`,margin:`m-[${i}]`,marginBottom:`mb-[${i}]`,marginLeft:`ml-[${i}]`,marginRight:`mr-[${i}]`,marginTop:`mt-[${i}]`,maxHeight:`max-h-[${i}]`,maxWidth:`max-w-[${i}]`,minHeight:`min-h-[${i}]`,minWidth:`min-w-[${i}]`,outlineColor:`outline-[color:${i}]`,outlineOffset:`outline-offset-[${i}]`,outlineWidth:`outline-[length:${i}]`,opacity:`[opacity:${i}]`,overflowX:`[overflow-x:${i}]`,overflowY:`[overflow-y:${i}]`,padding:`p-[${i}]`,paddingBottom:`pb-[${i}]`,paddingLeft:`pl-[${i}]`,paddingRight:`pr-[${i}]`,paddingTop:`pt-[${i}]`,pointerEvents:`[pointer-events:${i}]`,right:`right-[${i}]`,top:`top-[${i}]`,width:`w-[${i}]`,zIndex:`z-[${i}]`}[t]}function uo(t){return t.replace(/[A-Z]/g,o=>`-${o.toLowerCase()}`)}function ao(t,o){if(o!==void 0){if(Array.isArray(o)){t.padding=o.map(n).join(" ");return}if(typeof o!="object"){t.padding=n(o);return}"px"in o&&o.px!==void 0&&(t.paddingLeft=n(o.px),t.paddingRight=n(o.px)),"py"in o&&o.py!==void 0&&(t.paddingTop=n(o.py),t.paddingBottom=n(o.py)),"pt"in o&&o.pt!==void 0&&(t.paddingTop=n(o.pt)),"pb"in o&&o.pb!==void 0&&(t.paddingBottom=n(o.pb)),"pl"in o&&o.pl!==void 0&&(t.paddingLeft=n(o.pl)),"pr"in o&&o.pr!==void 0&&(t.paddingRight=n(o.pr))}}function co(t,o){if(o!==void 0){if(Array.isArray(o)){t.margin=o.map(n).join(" ");return}if(typeof o!="object"){t.margin=n(o);return}"mx"in o&&o.mx!==void 0&&(t.marginLeft=n(o.mx),t.marginRight=n(o.mx)),"my"in o&&o.my!==void 0&&(t.marginTop=n(o.my),t.marginBottom=n(o.my)),"mt"in o&&o.mt!==void 0&&(t.marginTop=n(o.mt)),"mb"in o&&o.mb!==void 0&&(t.marginBottom=n(o.mb)),"ml"in o&&o.ml!==void 0&&(t.marginLeft=n(o.ml)),"mr"in o&&o.mr!==void 0&&(t.marginRight=n(o.mr))}}function so(t,o){o&&(o.radius!==void 0&&lo(t,o.radius),o.color!==void 0&&(t.borderColor=m(o.color)),o.width!==void 0&&bo(t,o.width),o.style!==void 0&&(t.borderStyle=o.style))}function lo(t,o){if(po(o)){o.topLeft!==void 0&&(t.borderTopLeftRadius=B(o.topLeft)),o.topRight!==void 0&&(t.borderTopRightRadius=B(o.topRight)),o.bottomLeft!==void 0&&(t.borderBottomLeftRadius=B(o.bottomLeft)),o.bottomRight!==void 0&&(t.borderBottomRightRadius=B(o.bottomRight));return}t.borderRadius=B(o)}function bo(t,o){if(mo(o)){o.top!==void 0&&(t.borderTopWidth=y(o.top)),o.bottom!==void 0&&(t.borderBottomWidth=y(o.bottom)),o.left!==void 0&&(t.borderLeftWidth=y(o.left)),o.right!==void 0&&(t.borderRightWidth=y(o.right));return}t.borderWidth=y(o)}function po(t){return typeof t=="object"}function mo(t){return typeof t=="object"}function B(t){return t.startsWith("--")?`var(${t})`:t}function y(t){return t.startsWith("--")?`var(${t})`:t}function go(t){return t==="hidden"?"none":t}function j(t){return typeof t=="number"?`${t}px`:t}function n(t){return typeof t=="number"?`${t}px`:t}function $(t){return typeof t=="number"?`${t}px`:t}function ho(t){return typeof t=="number"?`${t}px`:t}function $o(t){return{"no-repeat":"no-repeat",repeat:"repeat","repeat-round":"round","repeat-space":"space","repeat-x":"repeat-x","repeat-y":"repeat-y"}[t]}function vo(t){return t.replace("-"," ")}function I(t){return m(t)}function Bo(t,o){const i=I(o);if(yo(o)){t.background=i;return}t.backgroundColor=i}function yo(t){const o=t.trim().toLowerCase();return o.includes("url(")||o.includes("gradient(")||o.includes("image-set(")||o.includes("cross-fade(")||o.includes("element(")||o.includes("paint(")}function m(t){return t.startsWith("--")?`var(${t})`:t}function xo(t,o){const{as:i,children:d,className:u,background:a,backgroundColor:v,bg:f,bgSize:l,bgRepeat:b,bgGroup:c,groupParent:s,bgPosition:p,border:x,boxShadow:R,color:g,cursor:O,opacity:A,overflow:k,overflowX:S,overflowY:z,pointerEvents:W,aspectRatio:h,p:C,m:r,outlineColor:T,outlineWidth:L,outlineOffset:N,outlineStyle:V,listStyle:P,display:w,position:e,width:Y,maxWidth:D,minWidth:E,height:M,maxHeight:K,minHeight:Z,md:_,lg:F,xl:J,style:H,...Q}=t,U=i??"div",G=no({background:a,backgroundColor:v,bg:f,bgSize:l,bgRepeat:b,bgGroup:c,groupParent:s,bgPosition:p,border:x,boxShadow:R,color:g,cursor:O,opacity:A,overflow:k,overflowX:S,overflowY:z,pointerEvents:W,aspectRatio:h,p:C,m:r,outlineColor:T,outlineWidth:L,outlineOffset:N,outlineStyle:V,listStyle:P,display:w,position:e,width:Y,maxWidth:D,minWidth:E,height:M,maxHeight:K,minHeight:Z,md:_,lg:F,xl:J}),oo=G.style||H?{...G.style,...H}:void 0;return to.jsx(U,{className:X.cn(G.className,s&&"group",u),ref:o,style:oo,...Q,children:d})}const Ro=io.forwardRef(xo);exports.Box=Ro;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const eo=require("react/jsx-runtime"),ro=require("react"),D=require("./responsive-style.config-B2m9jVlX.cjs");function no({background:t,backgroundColor:o,bg:i,bgSize:d,bgRepeat:a,bgPosition:u,border:v,boxShadow:f,color:b,cursor:m,opacity:c,overflow:s,overflowX:p,overflowY:x,pointerEvents:R,aspectRatio:g,transform:k,transformOrigin:S,p:G,m:H,outlineColor:z,outlineWidth:W,outlineOffset:C,outlineStyle:T,listStyle:h,display:L,position:n,width:N,maxWidth:V,minWidth:P,height:w,maxHeight:j,minHeight:I}){const e={};return i!==void 0?xo(e,i):t!==void 0&&(e.background=A(t)),o!==void 0&&(e.backgroundColor=A(o)),d!==void 0&&(e.backgroundSize=vo(d)),a!==void 0&&(e.backgroundRepeat=Bo(a)),u!==void 0&&(e.backgroundPosition=yo(u)),bo(e,v),f!==void 0&&(e.boxShadow=l(f)),b!==void 0&&(e.color=l(b)),m!==void 0&&(e.cursor=m),c!==void 0&&(e.opacity=typeof c=="number"?c:l(c)),s!==void 0&&(e.overflowX=s,e.overflowY=s),p!==void 0&&(e.overflowX=p),x!==void 0&&(e.overflowY=x),R!==void 0&&(e.pointerEvents=R),g!==void 0&&(e.aspectRatio=typeof g=="number"?String(g):l(g)),k!==void 0&&(e.transform=l(k)),S!==void 0&&(e.transformOrigin=l(S)),so(e,G),lo(e,H),z!==void 0&&(e.outlineColor=l(z)),W!==void 0&&(e.outlineWidth=W),C!==void 0&&(e.outlineOffset=C),T!==void 0&&(e.outlineStyle=T),h?.position!==void 0&&(e.listStylePosition=h.position),h?.type!==void 0&&(e.listStyleType=h.type),L!==void 0&&(e.display=$o(L)),n?.type!==void 0&&(e.position=n.type),n?.top!==void 0&&(e.top=O(n.top)),n?.left!==void 0&&(e.left=O(n.left)),n?.right!==void 0&&(e.right=O(n.right)),n?.bottom!==void 0&&(e.bottom=O(n.bottom)),n?.zIndex!==void 0&&(e.zIndex=n.zIndex),N!==void 0&&(e.width=$(N)),V!==void 0&&(e.maxWidth=$(V)),P!==void 0&&(e.minWidth=$(P)),w!==void 0&&(e.height=$(w)),j!==void 0&&(e.maxHeight=$(j)),I!==void 0&&(e.minHeight=$(I)),Object.keys(e).length>0?e:void 0}function fo(t){const o=[],i={},d=t.groupParent===!0;Y(t,o,i,"","",d);for(const a of D.responsiveBreakpoints){const u=t[a];u&&Y(u,o,i,`${a}:`,`${a}-`,d)}return{className:o.join(" "),style:Object.keys(i).length>0?i:void 0}}function Y(t,o,i,d="",a="",u=!1){const v=no(t);for(const[f,b]of Object.entries(v??{})){if(b==null)continue;const m=String(b),c=ao(f,m);if(c){o.push(`${d}${c}`);continue}const s=`${a}${co(f)}`,p=uo(f,s);p&&(i[`--${s}`]=m,o.push(`${d}${p}`))}if(t.bgGroup!==void 0){const f=`${a}group-background`;i[`--${f}`]=A(t.bgGroup),o.push(`${d}group-hover:[background:var(--${f})]`),u&&o.push(`${d}hover:[background:var(--${f})]`)}}function ao(t,o){if(t==="display")return o==="none"?"hidden":o;if(t==="position")return o==="inherit"?"[position:inherit]":o;if(t==="cursor")return`cursor-${o}`;if(t==="backgroundRepeat")return{"no-repeat":"bg-no-repeat",repeat:"bg-repeat",round:"bg-repeat-round",space:"bg-repeat-space","repeat-x":"bg-repeat-x","repeat-y":"bg-repeat-y"}[o];if(t==="backgroundSize")return{auto:"bg-auto",contain:"bg-contain",cover:"bg-cover"}[o];if(t==="backgroundPosition")return{bottom:"bg-bottom",center:"bg-center",left:"bg-left","left bottom":"bg-left-bottom","left top":"bg-left-top",right:"bg-right","right bottom":"bg-right-bottom","right top":"bg-right-top",top:"bg-top"}[o];if(t==="borderStyle")return o==="none"?"border-none":`border-${o}`;if(t==="outlineStyle")return o==="none"?"outline-none":`outline-${o}`;if(t==="listStylePosition")return`list-${o}`;if(t==="listStyleType")return`list-${o}`}function uo(t,o){const i=`var(--${o})`;return{background:`[background:${i}]`,backgroundColor:`bg-[${i}]`,backgroundPosition:`bg-[position:${i}]`,backgroundSize:`bg-[length:${i}]`,aspectRatio:`[aspect-ratio:${i}]`,borderBottomLeftRadius:`rounded-bl-[${i}]`,borderBottomRightRadius:`rounded-br-[${i}]`,borderBottomWidth:`border-b-[length:${i}]`,borderColor:`border-[color:${i}]`,borderLeftWidth:`border-l-[length:${i}]`,borderRadius:`rounded-[${i}]`,borderRightWidth:`border-r-[length:${i}]`,borderTopLeftRadius:`rounded-tl-[${i}]`,borderTopRightRadius:`rounded-tr-[${i}]`,borderTopWidth:`border-t-[length:${i}]`,borderWidth:`border-[length:${i}]`,boxShadow:`[box-shadow:${i}]`,bottom:`bottom-[${i}]`,color:`[color:${i}]`,height:`h-[${i}]`,left:`left-[${i}]`,margin:`m-[${i}]`,marginBottom:`mb-[${i}]`,marginLeft:`ml-[${i}]`,marginRight:`mr-[${i}]`,marginTop:`mt-[${i}]`,maxHeight:`max-h-[${i}]`,maxWidth:`max-w-[${i}]`,minHeight:`min-h-[${i}]`,minWidth:`min-w-[${i}]`,outlineColor:`outline-[color:${i}]`,outlineOffset:`outline-offset-[${i}]`,outlineWidth:`outline-[length:${i}]`,opacity:`[opacity:${i}]`,overflowX:`[overflow-x:${i}]`,overflowY:`[overflow-y:${i}]`,padding:`p-[${i}]`,paddingBottom:`pb-[${i}]`,paddingLeft:`pl-[${i}]`,paddingRight:`pr-[${i}]`,paddingTop:`pt-[${i}]`,pointerEvents:`[pointer-events:${i}]`,right:`right-[${i}]`,top:`top-[${i}]`,transform:`[transform:${i}]`,transformOrigin:`[transform-origin:${i}]`,width:`w-[${i}]`,zIndex:`z-[${i}]`}[t]}function co(t){return t.replace(/[A-Z]/g,o=>`-${o.toLowerCase()}`)}function so(t,o){if(o!==void 0){if(Array.isArray(o)){t.padding=o.map(r).join(" ");return}if(typeof o!="object"){t.padding=r(o);return}"px"in o&&o.px!==void 0&&(t.paddingLeft=r(o.px),t.paddingRight=r(o.px)),"py"in o&&o.py!==void 0&&(t.paddingTop=r(o.py),t.paddingBottom=r(o.py)),"pt"in o&&o.pt!==void 0&&(t.paddingTop=r(o.pt)),"pb"in o&&o.pb!==void 0&&(t.paddingBottom=r(o.pb)),"pl"in o&&o.pl!==void 0&&(t.paddingLeft=r(o.pl)),"pr"in o&&o.pr!==void 0&&(t.paddingRight=r(o.pr))}}function lo(t,o){if(o!==void 0){if(Array.isArray(o)){t.margin=o.map(r).join(" ");return}if(typeof o!="object"){t.margin=r(o);return}"mx"in o&&o.mx!==void 0&&(t.marginLeft=r(o.mx),t.marginRight=r(o.mx)),"my"in o&&o.my!==void 0&&(t.marginTop=r(o.my),t.marginBottom=r(o.my)),"mt"in o&&o.mt!==void 0&&(t.marginTop=r(o.mt)),"mb"in o&&o.mb!==void 0&&(t.marginBottom=r(o.mb)),"ml"in o&&o.ml!==void 0&&(t.marginLeft=r(o.ml)),"mr"in o&&o.mr!==void 0&&(t.marginRight=r(o.mr))}}function bo(t,o){o&&(o.radius!==void 0&&mo(t,o.radius),o.color!==void 0&&(t.borderColor=l(o.color)),o.width!==void 0&&po(t,o.width),o.style!==void 0&&(t.borderStyle=o.style))}function mo(t,o){if(go(o)){o.topLeft!==void 0&&(t.borderTopLeftRadius=B(o.topLeft)),o.topRight!==void 0&&(t.borderTopRightRadius=B(o.topRight)),o.bottomLeft!==void 0&&(t.borderBottomLeftRadius=B(o.bottomLeft)),o.bottomRight!==void 0&&(t.borderBottomRightRadius=B(o.bottomRight));return}t.borderRadius=B(o)}function po(t,o){if(ho(o)){o.top!==void 0&&(t.borderTopWidth=y(o.top)),o.bottom!==void 0&&(t.borderBottomWidth=y(o.bottom)),o.left!==void 0&&(t.borderLeftWidth=y(o.left)),o.right!==void 0&&(t.borderRightWidth=y(o.right));return}t.borderWidth=y(o)}function go(t){return typeof t=="object"}function ho(t){return typeof t=="object"}function B(t){return t.startsWith("--")?`var(${t})`:t}function y(t){return t.startsWith("--")?`var(${t})`:t}function $o(t){return t==="hidden"?"none":t}function O(t){return typeof t=="number"?`${t}px`:t}function r(t){return typeof t=="number"?`${t}px`:t}function $(t){return typeof t=="number"?`${t}px`:t}function vo(t){return typeof t=="number"?`${t}px`:t}function Bo(t){return{"no-repeat":"no-repeat",repeat:"repeat","repeat-round":"round","repeat-space":"space","repeat-x":"repeat-x","repeat-y":"repeat-y"}[t]}function yo(t){return t.replace("-"," ")}function A(t){return l(t)}function xo(t,o){const i=A(o);if(Ro(o)){t.background=i;return}t.backgroundColor=i}function Ro(t){const o=t.trim().toLowerCase();return o.includes("url(")||o.includes("gradient(")||o.includes("image-set(")||o.includes("cross-fade(")||o.includes("element(")||o.includes("paint(")}function l(t){return t.startsWith("--")?`var(${t})`:t}function ko(t,o){const{as:i,children:d,className:a,background:u,backgroundColor:v,bg:f,bgSize:b,bgRepeat:m,bgGroup:c,groupParent:s,bgPosition:p,border:x,boxShadow:R,color:g,cursor:k,opacity:S,overflow:G,overflowX:H,overflowY:z,pointerEvents:W,aspectRatio:C,transform:T,transformOrigin:h,p:L,m:n,outlineColor:N,outlineWidth:V,outlineOffset:P,outlineStyle:w,listStyle:j,display:I,position:e,width:E,maxWidth:M,minWidth:K,height:Z,maxHeight:_,minHeight:F,md:J,lg:Q,xl:U,style:X,...oo}=t,to=i??"div",q=fo({background:u,backgroundColor:v,bg:f,bgSize:b,bgRepeat:m,bgGroup:c,groupParent:s,bgPosition:p,border:x,boxShadow:R,color:g,cursor:k,opacity:S,overflow:G,overflowX:H,overflowY:z,pointerEvents:W,aspectRatio:C,transform:T,transformOrigin:h,p:L,m:n,outlineColor:N,outlineWidth:V,outlineOffset:P,outlineStyle:w,listStyle:j,display:I,position:e,width:E,maxWidth:M,minWidth:K,height:Z,maxHeight:_,minHeight:F,md:J,lg:Q,xl:U}),io=q.style||X?{...q.style,...X}:void 0;return eo.jsx(to,{className:D.cn(q.className,s&&"group",a),ref:o,style:io,...oo,children:d})}const So=ro.forwardRef(ko);exports.Box=So;
package/dist/box.js CHANGED
@@ -1,7 +1,7 @@
1
- import { jsx as oo } from "react/jsx-runtime";
2
- import { forwardRef as to } from "react";
3
- import { a as io, c as eo } from "./responsive-style.config-DFuATrIM.js";
4
- function ro({
1
+ import { jsx as io } from "react/jsx-runtime";
2
+ import { forwardRef as eo } from "react";
3
+ import { a as ro, c as no } from "./responsive-style.config-DFuATrIM.js";
4
+ function fo({
5
5
  background: t,
6
6
  backgroundColor: o,
7
7
  bg: i,
@@ -10,39 +10,41 @@ function ro({
10
10
  bgPosition: u,
11
11
  border: v,
12
12
  boxShadow: f,
13
- color: l,
14
- cursor: b,
13
+ color: b,
14
+ cursor: m,
15
15
  opacity: c,
16
16
  overflow: s,
17
- overflowX: m,
17
+ overflowX: p,
18
18
  overflowY: x,
19
19
  pointerEvents: R,
20
20
  aspectRatio: g,
21
- p: A,
22
- m: O,
23
- outlineColor: k,
24
- outlineWidth: S,
25
- outlineOffset: z,
26
- outlineStyle: W,
21
+ transform: k,
22
+ transformOrigin: S,
23
+ p: G,
24
+ m: H,
25
+ outlineColor: z,
26
+ outlineWidth: W,
27
+ outlineOffset: C,
28
+ outlineStyle: T,
27
29
  listStyle: h,
28
- display: C,
30
+ display: L,
29
31
  position: n,
30
- width: T,
31
- maxWidth: L,
32
- minWidth: N,
33
- height: V,
34
- maxHeight: w,
35
- minHeight: P
32
+ width: N,
33
+ maxWidth: V,
34
+ minWidth: w,
35
+ height: P,
36
+ maxHeight: I,
37
+ minHeight: j
36
38
  }) {
37
39
  const e = {};
38
- return i !== void 0 ? yo(e, i) : t !== void 0 && (e.background = j(t)), o !== void 0 && (e.backgroundColor = j(o)), d !== void 0 && (e.backgroundSize = $o(d)), a !== void 0 && (e.backgroundRepeat = vo(a)), u !== void 0 && (e.backgroundPosition = Bo(u)), lo(e, v), f !== void 0 && (e.boxShadow = p(f)), l !== void 0 && (e.color = p(l)), b !== void 0 && (e.cursor = b), c !== void 0 && (e.opacity = typeof c == "number" ? c : p(c)), s !== void 0 && (e.overflowX = s, e.overflowY = s), m !== void 0 && (e.overflowX = m), x !== void 0 && (e.overflowY = x), R !== void 0 && (e.pointerEvents = R), g !== void 0 && (e.aspectRatio = typeof g == "number" ? String(g) : p(g)), co(e, A), so(e, O), k !== void 0 && (e.outlineColor = p(k)), S !== void 0 && (e.outlineWidth = S), z !== void 0 && (e.outlineOffset = z), W !== void 0 && (e.outlineStyle = W), h?.position !== void 0 && (e.listStylePosition = h.position), h?.type !== void 0 && (e.listStyleType = h.type), C !== void 0 && (e.display = ho(C)), n?.type !== void 0 && (e.position = n.type), n?.top !== void 0 && (e.top = I(n.top)), n?.left !== void 0 && (e.left = I(n.left)), n?.right !== void 0 && (e.right = I(n.right)), n?.bottom !== void 0 && (e.bottom = I(n.bottom)), n?.zIndex !== void 0 && (e.zIndex = n.zIndex), T !== void 0 && (e.width = $(T)), L !== void 0 && (e.maxWidth = $(L)), N !== void 0 && (e.minWidth = $(N)), V !== void 0 && (e.height = $(V)), w !== void 0 && (e.maxHeight = $(w)), P !== void 0 && (e.minHeight = $(P)), Object.keys(e).length > 0 ? e : void 0;
40
+ return i !== void 0 ? Ro(e, i) : t !== void 0 && (e.background = A(t)), o !== void 0 && (e.backgroundColor = A(o)), d !== void 0 && (e.backgroundSize = Bo(d)), a !== void 0 && (e.backgroundRepeat = yo(a)), u !== void 0 && (e.backgroundPosition = xo(u)), mo(e, v), f !== void 0 && (e.boxShadow = l(f)), b !== void 0 && (e.color = l(b)), m !== void 0 && (e.cursor = m), c !== void 0 && (e.opacity = typeof c == "number" ? c : l(c)), s !== void 0 && (e.overflowX = s, e.overflowY = s), p !== void 0 && (e.overflowX = p), x !== void 0 && (e.overflowY = x), R !== void 0 && (e.pointerEvents = R), g !== void 0 && (e.aspectRatio = typeof g == "number" ? String(g) : l(g)), k !== void 0 && (e.transform = l(k)), S !== void 0 && (e.transformOrigin = l(S)), lo(e, G), bo(e, H), z !== void 0 && (e.outlineColor = l(z)), W !== void 0 && (e.outlineWidth = W), C !== void 0 && (e.outlineOffset = C), T !== void 0 && (e.outlineStyle = T), h?.position !== void 0 && (e.listStylePosition = h.position), h?.type !== void 0 && (e.listStyleType = h.type), L !== void 0 && (e.display = vo(L)), n?.type !== void 0 && (e.position = n.type), n?.top !== void 0 && (e.top = O(n.top)), n?.left !== void 0 && (e.left = O(n.left)), n?.right !== void 0 && (e.right = O(n.right)), n?.bottom !== void 0 && (e.bottom = O(n.bottom)), n?.zIndex !== void 0 && (e.zIndex = n.zIndex), N !== void 0 && (e.width = $(N)), V !== void 0 && (e.maxWidth = $(V)), w !== void 0 && (e.minWidth = $(w)), P !== void 0 && (e.height = $(P)), I !== void 0 && (e.maxHeight = $(I)), j !== void 0 && (e.minHeight = $(j)), Object.keys(e).length > 0 ? e : void 0;
39
41
  }
40
- function no(t) {
42
+ function ao(t) {
41
43
  const o = [], i = {}, d = t.groupParent === !0;
42
- X(t, o, i, "", "", d);
43
- for (const a of io) {
44
+ D(t, o, i, "", "", d);
45
+ for (const a of ro) {
44
46
  const u = t[a];
45
- u && X(
47
+ u && D(
46
48
  u,
47
49
  o,
48
50
  i,
@@ -56,25 +58,25 @@ function no(t) {
56
58
  style: Object.keys(i).length > 0 ? i : void 0
57
59
  };
58
60
  }
59
- function X(t, o, i, d = "", a = "", u = !1) {
60
- const v = ro(t);
61
- for (const [f, l] of Object.entries(v ?? {})) {
62
- if (l == null)
61
+ function D(t, o, i, d = "", a = "", u = !1) {
62
+ const v = fo(t);
63
+ for (const [f, b] of Object.entries(v ?? {})) {
64
+ if (b == null)
63
65
  continue;
64
- const b = String(l), c = fo(f, b);
66
+ const m = String(b), c = uo(f, m);
65
67
  if (c) {
66
68
  o.push(`${d}${c}`);
67
69
  continue;
68
70
  }
69
- const s = `${a}${uo(f)}`, m = ao(f, s);
70
- m && (i[`--${s}`] = b, o.push(`${d}${m}`));
71
+ const s = `${a}${so(f)}`, p = co(f, s);
72
+ p && (i[`--${s}`] = m, o.push(`${d}${p}`));
71
73
  }
72
74
  if (t.bgGroup !== void 0) {
73
75
  const f = `${a}group-background`;
74
- i[`--${f}`] = j(t.bgGroup), o.push(`${d}group-hover:[background:var(--${f})]`), u && o.push(`${d}hover:[background:var(--${f})]`);
76
+ i[`--${f}`] = A(t.bgGroup), o.push(`${d}group-hover:[background:var(--${f})]`), u && o.push(`${d}hover:[background:var(--${f})]`);
75
77
  }
76
78
  }
77
- function fo(t, o) {
79
+ function uo(t, o) {
78
80
  if (t === "display")
79
81
  return o === "none" ? "hidden" : o;
80
82
  if (t === "position")
@@ -117,7 +119,7 @@ function fo(t, o) {
117
119
  if (t === "listStyleType")
118
120
  return `list-${o}`;
119
121
  }
120
- function ao(t, o) {
122
+ function co(t, o) {
121
123
  const i = `var(--${o})`;
122
124
  return {
123
125
  background: `[background:${i}]`,
@@ -164,14 +166,16 @@ function ao(t, o) {
164
166
  pointerEvents: `[pointer-events:${i}]`,
165
167
  right: `right-[${i}]`,
166
168
  top: `top-[${i}]`,
169
+ transform: `[transform:${i}]`,
170
+ transformOrigin: `[transform-origin:${i}]`,
167
171
  width: `w-[${i}]`,
168
172
  zIndex: `z-[${i}]`
169
173
  }[t];
170
174
  }
171
- function uo(t) {
175
+ function so(t) {
172
176
  return t.replace(/[A-Z]/g, (o) => `-${o.toLowerCase()}`);
173
177
  }
174
- function co(t, o) {
178
+ function lo(t, o) {
175
179
  if (o !== void 0) {
176
180
  if (Array.isArray(o)) {
177
181
  t.padding = o.map(r).join(" ");
@@ -184,7 +188,7 @@ function co(t, o) {
184
188
  "px" in o && o.px !== void 0 && (t.paddingLeft = r(o.px), t.paddingRight = r(o.px)), "py" in o && o.py !== void 0 && (t.paddingTop = r(o.py), t.paddingBottom = r(o.py)), "pt" in o && o.pt !== void 0 && (t.paddingTop = r(o.pt)), "pb" in o && o.pb !== void 0 && (t.paddingBottom = r(o.pb)), "pl" in o && o.pl !== void 0 && (t.paddingLeft = r(o.pl)), "pr" in o && o.pr !== void 0 && (t.paddingRight = r(o.pr));
185
189
  }
186
190
  }
187
- function so(t, o) {
191
+ function bo(t, o) {
188
192
  if (o !== void 0) {
189
193
  if (Array.isArray(o)) {
190
194
  t.margin = o.map(r).join(" ");
@@ -197,27 +201,27 @@ function so(t, o) {
197
201
  "mx" in o && o.mx !== void 0 && (t.marginLeft = r(o.mx), t.marginRight = r(o.mx)), "my" in o && o.my !== void 0 && (t.marginTop = r(o.my), t.marginBottom = r(o.my)), "mt" in o && o.mt !== void 0 && (t.marginTop = r(o.mt)), "mb" in o && o.mb !== void 0 && (t.marginBottom = r(o.mb)), "ml" in o && o.ml !== void 0 && (t.marginLeft = r(o.ml)), "mr" in o && o.mr !== void 0 && (t.marginRight = r(o.mr));
198
202
  }
199
203
  }
200
- function lo(t, o) {
201
- o && (o.radius !== void 0 && bo(t, o.radius), o.color !== void 0 && (t.borderColor = p(o.color)), o.width !== void 0 && mo(t, o.width), o.style !== void 0 && (t.borderStyle = o.style));
204
+ function mo(t, o) {
205
+ o && (o.radius !== void 0 && po(t, o.radius), o.color !== void 0 && (t.borderColor = l(o.color)), o.width !== void 0 && go(t, o.width), o.style !== void 0 && (t.borderStyle = o.style));
202
206
  }
203
- function bo(t, o) {
204
- if (po(o)) {
207
+ function po(t, o) {
208
+ if (ho(o)) {
205
209
  o.topLeft !== void 0 && (t.borderTopLeftRadius = B(o.topLeft)), o.topRight !== void 0 && (t.borderTopRightRadius = B(o.topRight)), o.bottomLeft !== void 0 && (t.borderBottomLeftRadius = B(o.bottomLeft)), o.bottomRight !== void 0 && (t.borderBottomRightRadius = B(o.bottomRight));
206
210
  return;
207
211
  }
208
212
  t.borderRadius = B(o);
209
213
  }
210
- function mo(t, o) {
211
- if (go(o)) {
214
+ function go(t, o) {
215
+ if ($o(o)) {
212
216
  o.top !== void 0 && (t.borderTopWidth = y(o.top)), o.bottom !== void 0 && (t.borderBottomWidth = y(o.bottom)), o.left !== void 0 && (t.borderLeftWidth = y(o.left)), o.right !== void 0 && (t.borderRightWidth = y(o.right));
213
217
  return;
214
218
  }
215
219
  t.borderWidth = y(o);
216
220
  }
217
- function po(t) {
221
+ function ho(t) {
218
222
  return typeof t == "object";
219
223
  }
220
- function go(t) {
224
+ function $o(t) {
221
225
  return typeof t == "object";
222
226
  }
223
227
  function B(t) {
@@ -226,10 +230,10 @@ function B(t) {
226
230
  function y(t) {
227
231
  return t.startsWith("--") ? `var(${t})` : t;
228
232
  }
229
- function ho(t) {
233
+ function vo(t) {
230
234
  return t === "hidden" ? "none" : t;
231
235
  }
232
- function I(t) {
236
+ function O(t) {
233
237
  return typeof t == "number" ? `${t}px` : t;
234
238
  }
235
239
  function r(t) {
@@ -238,10 +242,10 @@ function r(t) {
238
242
  function $(t) {
239
243
  return typeof t == "number" ? `${t}px` : t;
240
244
  }
241
- function $o(t) {
245
+ function Bo(t) {
242
246
  return typeof t == "number" ? `${t}px` : t;
243
247
  }
244
- function vo(t) {
248
+ function yo(t) {
245
249
  return {
246
250
  "no-repeat": "no-repeat",
247
251
  repeat: "repeat",
@@ -251,28 +255,28 @@ function vo(t) {
251
255
  "repeat-y": "repeat-y"
252
256
  }[t];
253
257
  }
254
- function Bo(t) {
258
+ function xo(t) {
255
259
  return t.replace("-", " ");
256
260
  }
257
- function j(t) {
258
- return p(t);
261
+ function A(t) {
262
+ return l(t);
259
263
  }
260
- function yo(t, o) {
261
- const i = j(o);
262
- if (xo(o)) {
264
+ function Ro(t, o) {
265
+ const i = A(o);
266
+ if (ko(o)) {
263
267
  t.background = i;
264
268
  return;
265
269
  }
266
270
  t.backgroundColor = i;
267
271
  }
268
- function xo(t) {
272
+ function ko(t) {
269
273
  const o = t.trim().toLowerCase();
270
274
  return o.includes("url(") || o.includes("gradient(") || o.includes("image-set(") || o.includes("cross-fade(") || o.includes("element(") || o.includes("paint(");
271
275
  }
272
- function p(t) {
276
+ function l(t) {
273
277
  return t.startsWith("--") ? `var(${t})` : t;
274
278
  }
275
- function Ro(t, o) {
279
+ function So(t, o) {
276
280
  const {
277
281
  as: i,
278
282
  children: d,
@@ -280,94 +284,98 @@ function Ro(t, o) {
280
284
  background: u,
281
285
  backgroundColor: v,
282
286
  bg: f,
283
- bgSize: l,
284
- bgRepeat: b,
287
+ bgSize: b,
288
+ bgRepeat: m,
285
289
  bgGroup: c,
286
290
  groupParent: s,
287
- bgPosition: m,
291
+ bgPosition: p,
288
292
  border: x,
289
293
  boxShadow: R,
290
294
  color: g,
291
- cursor: A,
292
- opacity: O,
293
- overflow: k,
294
- overflowX: S,
295
+ cursor: k,
296
+ opacity: S,
297
+ overflow: G,
298
+ overflowX: H,
295
299
  overflowY: z,
296
300
  pointerEvents: W,
297
- aspectRatio: h,
298
- p: C,
301
+ aspectRatio: C,
302
+ transform: T,
303
+ transformOrigin: h,
304
+ p: L,
299
305
  m: n,
300
- outlineColor: T,
301
- outlineWidth: L,
302
- outlineOffset: N,
303
- outlineStyle: V,
304
- listStyle: w,
305
- display: P,
306
+ outlineColor: N,
307
+ outlineWidth: V,
308
+ outlineOffset: w,
309
+ outlineStyle: P,
310
+ listStyle: I,
311
+ display: j,
306
312
  position: e,
307
- width: Y,
308
- maxWidth: D,
309
- minWidth: E,
310
- height: K,
311
- maxHeight: M,
312
- minHeight: Z,
313
- md: q,
314
- lg: F,
315
- xl: J,
316
- style: H,
317
- ...Q
318
- } = t, U = i ?? "div", G = no({
313
+ width: E,
314
+ maxWidth: K,
315
+ minWidth: M,
316
+ height: Z,
317
+ maxHeight: q,
318
+ minHeight: F,
319
+ md: J,
320
+ lg: Q,
321
+ xl: U,
322
+ style: Y,
323
+ ..._
324
+ } = t, oo = i ?? "div", X = ao({
319
325
  background: u,
320
326
  backgroundColor: v,
321
327
  bg: f,
322
- bgSize: l,
323
- bgRepeat: b,
328
+ bgSize: b,
329
+ bgRepeat: m,
324
330
  bgGroup: c,
325
331
  groupParent: s,
326
- bgPosition: m,
332
+ bgPosition: p,
327
333
  border: x,
328
334
  boxShadow: R,
329
335
  color: g,
330
- cursor: A,
331
- opacity: O,
332
- overflow: k,
333
- overflowX: S,
336
+ cursor: k,
337
+ opacity: S,
338
+ overflow: G,
339
+ overflowX: H,
334
340
  overflowY: z,
335
341
  pointerEvents: W,
336
- aspectRatio: h,
337
- p: C,
342
+ aspectRatio: C,
343
+ transform: T,
344
+ transformOrigin: h,
345
+ p: L,
338
346
  m: n,
339
- outlineColor: T,
340
- outlineWidth: L,
341
- outlineOffset: N,
342
- outlineStyle: V,
343
- listStyle: w,
344
- display: P,
347
+ outlineColor: N,
348
+ outlineWidth: V,
349
+ outlineOffset: w,
350
+ outlineStyle: P,
351
+ listStyle: I,
352
+ display: j,
345
353
  position: e,
346
- width: Y,
347
- maxWidth: D,
348
- minWidth: E,
349
- height: K,
350
- maxHeight: M,
351
- minHeight: Z,
352
- md: q,
353
- lg: F,
354
- xl: J
355
- }), _ = G.style || H ? {
356
- ...G.style,
357
- ...H
354
+ width: E,
355
+ maxWidth: K,
356
+ minWidth: M,
357
+ height: Z,
358
+ maxHeight: q,
359
+ minHeight: F,
360
+ md: J,
361
+ lg: Q,
362
+ xl: U
363
+ }), to = X.style || Y ? {
364
+ ...X.style,
365
+ ...Y
358
366
  } : void 0;
359
- return /* @__PURE__ */ oo(
360
- U,
367
+ return /* @__PURE__ */ io(
368
+ oo,
361
369
  {
362
- className: eo(G.className, s && "group", a),
370
+ className: no(X.className, s && "group", a),
363
371
  ref: o,
364
- style: _,
365
- ...Q,
372
+ style: to,
373
+ ..._,
366
374
  children: d
367
375
  }
368
376
  );
369
377
  }
370
- const Co = to(Ro);
378
+ const Lo = eo(So);
371
379
  export {
372
- Co as Box
380
+ Lo as Box
373
381
  };
@@ -19,4 +19,4 @@ type AnchorButtonProps = ButtonBaseProps & Omit<AnchorHTMLAttributes<HTMLAnchorE
19
19
  };
20
20
  export type ButtonProps = NativeButtonProps | AnchorButtonProps;
21
21
  export declare function Button({ alignContent, children, className, disabled, display, border, bg, color, cursor, fullWidth, href, hoverBg, activeBg, fontSize, fontWeight, isLoading, lineHeight, minHeight, minWidth, md, lg, xl, p, position, size, style, variant, width, ...props }: ButtonProps): ReactNode;
22
- export { buttonSizeBoxProps, buttonSizeBorderRadius, buttonSizeClassNames, buttonVariantClassNames, buttonVariants, } from './button.helpers';
22
+ export { buttonSizeBorderRadius, buttonSizeBoxProps, buttonSizeClassNames, buttonVariantClassNames, buttonVariants, } from './button.helpers';
@@ -1,7 +1,7 @@
1
1
  import { CSSProperties } from 'react';
2
2
  import { BoxBreakpointProps } from '../box/box';
3
3
  import { ResponsiveStyleBreakpoint } from '../shared/responsive-style/responsive-style.types';
4
- import { TypographyFontSizeValue, TypographyFontWeightValue, TypographyLineHeightValue, UiKitBackgroundValue } from '../types/index';
4
+ import { TypographyFontSizeValue, TypographyFontWeightValue, TypographyLineHeightValue, UiKitBackgroundValue } from '../types';
5
5
  export type ButtonAlignContent = 'start' | 'center' | 'end';
6
6
  export type ButtonAlignContentBreakpointProps = {
7
7
  alignContent?: ButtonAlignContent;
@@ -5,5 +5,5 @@ export declare function Flex(props: FlexProps<'div'>): JSX.Element;
5
5
  export declare function Flex<TAs extends BoxAs>(props: FlexProps<TAs> & {
6
6
  as: TAs;
7
7
  }): JSX.Element;
8
+ export type { UiKitAlign, UiKitFlexDirection, UiKitFlexParams, UiKitFlexWrap, UiKitGap, UiKitJustify, } from '../types';
8
9
  export type { FlexBreakpointProps, FlexProps, FlexResponsiveProps } from './flex.types';
9
- export type { UiKitAlign, UiKitFlexDirection, UiKitFlexParams, UiKitFlexWrap, UiKitGap, UiKitJustify, } from '../types/index';
@@ -1,6 +1,6 @@
1
1
  import { BoxAs, BoxBreakpointProps, BoxProps } from '../box/box.types';
2
2
  import { ResponsiveStyleBreakpoint } from '../shared/responsive-style/responsive-style.types';
3
- import { UiKitFlexParams } from '../types/index';
3
+ import { UiKitFlexParams } from '../types';
4
4
  export type FlexBreakpointProps = BoxBreakpointProps & UiKitFlexParams;
5
5
  export type FlexProps<TAs extends BoxAs = 'div'> = Omit<BoxProps<TAs>, keyof BoxBreakpointProps | 'display' | 'md' | 'lg' | 'xl'> & FlexBreakpointProps & {
6
6
  /** Рендерит контейнер как `inline-flex` вместо `flex`. */
package/dist/grid.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react/jsx-runtime"),w=require("./box.cjs"),g=require("./responsive-style.config-B2m9jVlX.cjs");function j(t){const i=[],n={},l={md:t.md,lg:t.lg,xl:t.xl};r(t,i,n);for(const e of g.responsiveBreakpoints){const o=l[e];o&&r(o,i,n,`${e}:`,`${e}-`)}return{className:i.join(" "),style:Object.keys(n).length>0?n:void 0}}function r({cols:t,gap:i},n,l,e="",o=""){if(t!==void 0){const c=`${o}grid-template-columns`;l[`--${c}`]=`repeat(${t}, minmax(0, 1fr))`,n.push(`${e}${u("grid-cols",`var(--${c})`)}`)}if(i!==void 0){const c=`${o}grid-gap`;l[`--${c}`]=G(i),n.push(`${e}${u("gap",`var(--${c})`)}`)}}function u(t,i){return[t,"-[",i,"]"].join("")}function G(t){return typeof t=="number"?`${t}px`:t}function N({children:t,className:i,cols:n=1,gap:l=0,md:e,lg:o,xl:c,style:a,...h}){const d=j({cols:n,gap:l,md:e,lg:o,xl:c}),v=s(e),x=s(o),y=s(c),$=d.style||a?{...d.style,...a}:void 0;return m.jsx(w.Box,{...h,display:"grid",className:g.cn(d.className,i),md:v,lg:x,xl:y,style:$,children:t})}function f({children:t,className:i,...n}){return m.jsx("div",{className:i,...n,children:t})}const S=Object.assign(N,{Item:f});function s(t){if(t)return{aspectRatio:t.aspectRatio,background:t.background,backgroundColor:t.backgroundColor,boxShadow:t.boxShadow,color:t.color,height:t.height,maxHeight:t.maxHeight,maxWidth:t.maxWidth,minHeight:t.minHeight,minWidth:t.minWidth,opacity:t.opacity,overflow:t.overflow,overflowX:t.overflowX,overflowY:t.overflowY,pointerEvents:t.pointerEvents,width:t.width}}exports.Grid=S;exports.GridItem=f;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("react/jsx-runtime"),w=require("./box.cjs"),g=require("./responsive-style.config-B2m9jVlX.cjs");function j(t){const i=[],n={},l={md:t.md,lg:t.lg,xl:t.xl};a(t,i,n);for(const e of g.responsiveBreakpoints){const o=l[e];o&&a(o,i,n,`${e}:`,`${e}-`)}return{className:i.join(" "),style:Object.keys(n).length>0?n:void 0}}function a({cols:t,gap:i},n,l,e="",o=""){if(t!==void 0){const c=`${o}grid-template-columns`;l[`--${c}`]=`repeat(${t}, minmax(0, 1fr))`,n.push(`${e}${m("grid-cols",`var(--${c})`)}`)}if(i!==void 0){const c=`${o}grid-gap`;l[`--${c}`]=G(i),n.push(`${e}${m("gap",`var(--${c})`)}`)}}function m(t,i){return[t,"-[",i,"]"].join("")}function G(t){return typeof t=="number"?`${t}px`:t}function N({children:t,className:i,cols:n=1,gap:l=0,md:e,lg:o,xl:c,style:s,...h}){const r=j({cols:n,gap:l,md:e,lg:o,xl:c}),v=d(e),x=d(o),y=d(c),$=r.style||s?{...r.style,...s}:void 0;return u.jsx(w.Box,{...h,display:"grid",className:g.cn(r.className,i),md:v,lg:x,xl:y,style:$,children:t})}function f({children:t,className:i,...n}){return u.jsx("div",{className:i,...n,children:t})}const S=Object.assign(N,{Item:f});function d(t){if(t)return{aspectRatio:t.aspectRatio,background:t.background,backgroundColor:t.backgroundColor,boxShadow:t.boxShadow,color:t.color,height:t.height,maxHeight:t.maxHeight,maxWidth:t.maxWidth,minHeight:t.minHeight,minWidth:t.minWidth,opacity:t.opacity,overflow:t.overflow,overflowX:t.overflowX,overflowY:t.overflowY,pointerEvents:t.pointerEvents,transform:t.transform,transformOrigin:t.transformOrigin,width:t.width}}exports.Grid=S;exports.GridItem=f;