@cronocode/react-box 3.0.0-alpha.4 → 3.0.0-alpha.6

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.
@@ -60,50 +60,50 @@ export declare const cssStyles: {
60
60
  /** The border-top-radius CSS property rounds the top corners of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
61
61
  borderRadiusTop: {
62
62
  values: number;
63
- styleName: string;
64
- valueFormat: (value: number) => string;
63
+ styleName: string[];
64
+ valueFormat: typeof BoxStylesFormatters.Value.rem;
65
65
  }[];
66
66
  /** The border-right-radius CSS property rounds the right corners of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
67
67
  borderRadiusRight: {
68
68
  values: number;
69
- styleName: string;
70
- valueFormat: (value: number) => string;
69
+ styleName: string[];
70
+ valueFormat: typeof BoxStylesFormatters.Value.rem;
71
71
  }[];
72
72
  /** The border-bottom-radius CSS property rounds the bottom corners of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
73
73
  borderRadiusBottom: {
74
74
  values: number;
75
- styleName: string;
76
- valueFormat: (value: number) => string;
75
+ styleName: string[];
76
+ valueFormat: typeof BoxStylesFormatters.Value.rem;
77
77
  }[];
78
78
  /** The border-left-radius CSS property rounds the left corners of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
79
79
  borderRadiusLeft: {
80
80
  values: number;
81
- styleName: string;
82
- valueFormat: (value: number) => string;
81
+ styleName: string[];
82
+ valueFormat: typeof BoxStylesFormatters.Value.rem;
83
83
  }[];
84
84
  /** The border-top-left-radius CSS property rounds the top-left corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
85
85
  borderRadiusTopLeft: {
86
86
  values: number;
87
87
  styleName: string;
88
- valueFormat: (value: number) => string;
88
+ valueFormat: typeof BoxStylesFormatters.Value.rem;
89
89
  }[];
90
90
  /** The border-top-right-radius CSS property rounds the top-right corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
91
91
  borderRadiusTopRight: {
92
92
  values: number;
93
93
  styleName: string;
94
- valueFormat: (value: number) => string;
94
+ valueFormat: typeof BoxStylesFormatters.Value.rem;
95
95
  }[];
96
96
  /** The border-bottom-right-radius CSS property rounds the bottom-right corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
97
97
  borderRadiusBottomRight: {
98
98
  values: number;
99
99
  styleName: string;
100
- valueFormat: (value: number) => string;
100
+ valueFormat: typeof BoxStylesFormatters.Value.rem;
101
101
  }[];
102
102
  /** The border-bottom-left-radius CSS property rounds the bottom-left corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
103
103
  borderRadiusBottomLeft: {
104
104
  values: number;
105
105
  styleName: string;
106
- valueFormat: (value: number) => string;
106
+ valueFormat: typeof BoxStylesFormatters.Value.rem;
107
107
  }[];
108
108
  /** The position CSS property sets how an element is positioned in a document. The top, right, bottom, and left properties determine the final location of positioned elements. */
109
109
  position: {
@@ -728,6 +728,7 @@ export declare const pseudoGroupClasses: {
728
728
  hoverGroup: "hover";
729
729
  focusGroup: "focus";
730
730
  activeGroup: "active";
731
+ disabledGroup: "disabled";
731
732
  };
732
733
  export declare const breakpoints: {
733
734
  sm: number;
@@ -23,7 +23,7 @@ interface BoxStyleString {
23
23
  valueFormat?: (value: string) => string;
24
24
  }
25
25
  export type BoxStyle = (BoxStyleArrayString | BoxStyleArrayBoolean | BoxStyleArrayNumber | BoxStyleNumber | BoxStyleString) & {
26
- styleName?: string;
26
+ styleName?: string | string[];
27
27
  selector?: (className: string, pseudoClass: string) => string;
28
28
  };
29
29
  export type ExtractKeys<T extends Record<string, unknown>, TT> = {
package/core.cjs CHANGED
@@ -1,7 +1,7 @@
1
- "use strict";const C=require("react");function te(...e){return e.reduce((t,s)=>s?typeof s=="string"?(t.push(s),t):Array.isArray(s)?(t.push(...te(...s)),t):(Object.entries(s).forEach(([u,m])=>{m&&t.push(u)}),t):t,[])}var c;(e=>{(t=>{function s(m,n){return`${m}${n.replace("/","-")}`}t.fraction=s;function u(m){return[`${m} path`,`${m} circle`,`${m} rect`,`${m} line`]}t.svg=u})(e.ClassName||(e.ClassName={})),(t=>{function s(h){return`${h/4}rem`}t.rem=s;function u(h){return`${h}px`}t.px=u;function m(h,r){const[o,l]=r.split("/");return`${+o/+l*100}%`}t.fraction=m;function n(h,r){switch(r){case"fit":return"100%";case"fit-screen":return h.toLocaleLowerCase().includes("height")?"100vh":"100vw";default:return r}}t.widthHeight=n;function d(h){return(r,o)=>`var(--${h}${o});`}t.variables=d;function i(h){return(r,o)=>`var(--${h}${o});`}t.svgVariables=i;function v(h,r){return`repeat(${r},minmax(0,1fr))`}t.gridColumns=v;function y(h,r){return r==="full-row"?"1/-1":`span ${r}/span ${r}`}t.gridColumn=y;function a(h,r){return`${r}ms`}t.ms=a;function f(h,r){return`${r}deg`}t.rotate=f;function p(h,r){return r==="xAxis"?"-1 1":"1 -1"}t.flip=p})(e.Value||(e.Value={}))})(c||(c={}));const A={appearance:[{values:["none","auto","menulist-button","textfield","button","checkbox"]}],b:[{values:0,styleName:"border-width",valueFormat:c.Value.px}],bx:[{values:0,styleName:"border-inline-width",valueFormat:c.Value.px}],by:[{values:0,styleName:"border-block-width",valueFormat:c.Value.px}],bt:[{values:0,styleName:"border-top-width",valueFormat:c.Value.px}],br:[{values:0,styleName:"border-right-width",valueFormat:c.Value.px}],bb:[{values:0,styleName:"border-bottom-width",valueFormat:c.Value.px}],bl:[{values:0,styleName:"border-left-width",valueFormat:c.Value.px}],borderStyle:[{styleName:"border-style",values:["solid","dashed","dotted","double","groove","ridge","inset","outset","none","hidden"]}],borderRadius:[{styleName:"border-radius",values:0,valueFormat:c.Value.rem}],borderRadiusTop:[{values:0,styleName:"border-radius",valueFormat:e=>`${e/4}rem ${e/4}rem 0 0`}],borderRadiusRight:[{values:0,styleName:"border-radius",valueFormat:e=>`0 ${e/4}rem ${e/4}rem 0`}],borderRadiusBottom:[{values:0,styleName:"border-radius",valueFormat:e=>`0 0 ${e/4}rem ${e/4}rem`}],borderRadiusLeft:[{values:0,styleName:"border-radius",valueFormat:e=>`${e/4}rem 0 0 ${e/4}rem`}],borderRadiusTopLeft:[{values:0,styleName:"border-radius",valueFormat:e=>`${e/4}rem 0 0 0`}],borderRadiusTopRight:[{values:0,styleName:"border-radius",valueFormat:e=>`0 ${e/4}rem 0 0`}],borderRadiusBottomRight:[{values:0,styleName:"border-radius",valueFormat:e=>`0 0 ${e/4}rem 0`}],borderRadiusBottomLeft:[{values:0,styleName:"border-radius",valueFormat:e=>`0 0 0 ${e/4}rem`}],position:[{values:["static","relative","absolute","fixed","sticky"]}],top:[{values:0,valueFormat:c.Value.rem}],right:[{values:0,valueFormat:c.Value.rem}],bottom:[{values:0,valueFormat:c.Value.rem}],left:[{values:0,valueFormat:c.Value.rem}],inset:[{values:0,valueFormat:c.Value.rem}],boxSizing:[{values:["border-box","content-box"],styleName:"box-sizing"}],contentVisibility:[{values:["visible","hidden"],styleName:"content-visibility"}],cursor:[{values:["auto","default","none","context-menu","help","pointer","progress","wait","cell","crosshair","text","vertical-text","alias","copy","move","no-drop","not-allowed","e-resize","n-resize","ne-resize","nw-resize","s-resize","se-resize","sw-resize","w-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","col-resize","row-resize","all-scroll","zoom-in","zoom-out","grab","grabbing"]}],display:[{values:["none","block","inline-block","flex","inline-flex","grid","inline-grid","contents"]}],inline:[{values:[!0],styleName:"display",valueFormat:()=>"inline-block"}],jc:[{styleName:"justify-content",values:["start","end","flex-start","flex-end","center","left","right","space-between","space-around","space-evenly","stretch"]}],ai:[{styleName:"align-items",values:["stretch","flex-start","flex-end","center","baseline","start","end","self-start","self-end"]}],alignContent:[{styleName:"align-content",values:["flex-start","flex-end","center","space-between","space-around","space-evenly","stretch","start","end","baseline"]}],flex1:[{styleName:"flex",values:[!0],valueFormat:()=>"1"}],d:[{styleName:"flex-direction",values:["row","row-reverse","column","column-reverse"]}],flexWrap:[{styleName:"flex-wrap",values:["nowrap","wrap","wrap-reverse"]}],flexGrow:[{styleName:"flex-grow",values:0}],flexShrink:[{styleName:"flex-shrink",values:0}],alignSelf:[{styleName:"align-self",values:["auto","flex-start","flex-end","center","baseline","stretch"]}],justifySelf:[{styleName:"justify-self",values:["auto","flex-start","flex-end","center","baseline","stretch"]}],fontSize:[{styleName:"font-size",values:0,valueFormat:c.Value.px},{styleName:"font-size",values:["inherit"]}],fontStyle:[{styleName:"font-style",values:["italic","normal","oblique"]}],fontWeight:[{styleName:"font-weight",values:[100,200,300,400,500,600,700,800,900]}],gap:[{values:0,valueFormat:c.Value.rem}],rowGap:[{styleName:"row-gap",values:0,valueFormat:c.Value.rem}],columnGap:[{styleName:"column-gap",values:0,valueFormat:c.Value.rem}],order:[{styleName:"order",values:0}],height:[{values:0,valueFormat:e=>`${e/4}rem`},{values:["fit"],valueFormat:()=>"100%"},{values:["fit-screen"],valueFormat:()=>"100vh"},{values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{values:["auto","fit-content","max-content","min-content"]}],minHeight:[{styleName:"min-height",values:0,valueFormat:e=>`${e/4}rem`},{styleName:"min-height",values:["fit"],valueFormat:()=>"100%"},{styleName:"min-height",values:["fit-screen"],valueFormat:()=>"100vh"},{styleName:"min-height",values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{styleName:"min-height",values:["auto","fit-content","max-content","min-content"]}],maxHeight:[{styleName:"max-height",values:0,valueFormat:e=>`${e/4}rem`},{styleName:"max-height",values:["fit"],valueFormat:()=>"100%"},{styleName:"max-height",values:["fit-screen"],valueFormat:()=>"100vh"},{styleName:"max-height",values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{styleName:"max-height",values:["auto","fit-content","max-content","min-content"]}],width:[{values:0,valueFormat:e=>`${e/4}rem`},{values:["fit"],valueFormat:()=>"100%"},{values:["fit-screen"],valueFormat:()=>"100vw"},{values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{values:["auto","fit-content","max-content","min-content"]}],minWidth:[{styleName:"min-width",values:0,valueFormat:e=>`${e/4}rem`},{styleName:"min-width",values:["fit"],valueFormat:()=>"100%"},{styleName:"min-width",values:["fit-screen"],valueFormat:()=>"100vw"},{styleName:"min-width",values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{styleName:"min-width",values:["auto","fit-content","max-content","min-content"]}],maxWidth:[{styleName:"max-width",values:0,valueFormat:e=>`${e/4}rem`},{styleName:"max-width",values:["fit"],valueFormat:()=>"100%"},{styleName:"max-width",values:["fit-screen"],valueFormat:()=>"100vw"},{styleName:"max-width",values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{styleName:"max-width",values:["auto","fit-content","max-content","min-content"]}],letterSpacing:[{styleName:"letter-spacing",values:0,valueFormat:c.Value.px}],lineHeight:[{styleName:"line-height",values:0,valueFormat:c.Value.px},{styleName:"line-height",values:["font-size"],valueFormat:e=>"1"}],listStyle:[{styleName:"list-style",values:["square","inside","outside","none"]}],m:[{values:0,styleName:"margin",valueFormat:c.Value.rem},{values:["auto"],styleName:"margin"}],mx:[{values:0,styleName:"margin-inline",valueFormat:c.Value.rem},{values:["auto"],styleName:"margin-inline"}],my:[{values:0,styleName:"margin-block",valueFormat:c.Value.rem},{values:["auto"],styleName:"margin-block"}],mt:[{values:0,styleName:"margin-top",valueFormat:c.Value.rem},{values:["auto"],styleName:"margin-top"}],mr:[{values:0,styleName:"margin-right",valueFormat:c.Value.rem},{values:["auto"],styleName:"margin-right"}],mb:[{values:0,styleName:"margin-bottom",valueFormat:c.Value.rem},{values:["auto"],styleName:"margin-bottom"}],ml:[{values:0,styleName:"margin-left",valueFormat:c.Value.rem},{values:["auto"],styleName:"margin-left"}],p:[{values:0,styleName:"padding",valueFormat:c.Value.rem}],px:[{values:0,styleName:"padding-inline",valueFormat:c.Value.rem}],py:[{values:0,styleName:"padding-block",valueFormat:c.Value.rem}],pt:[{values:0,styleName:"padding-top",valueFormat:c.Value.rem}],pr:[{values:0,styleName:"padding-right",valueFormat:c.Value.rem}],pb:[{values:0,styleName:"padding-bottom",valueFormat:c.Value.rem}],pl:[{values:0,styleName:"padding-left",valueFormat:c.Value.rem}],objectFit:[{styleName:"object-fit",values:["fill","contain","cover","scale-down","none"]}],opacity:[{values:[0,.1,.2,.3,.4,.5,.6,.7,.8,.9,1]}],outline:[{styleName:"outline-width",values:0,valueFormat:c.Value.px}],outlineStyle:[{styleName:"outline-style",values:["solid","dashed","dotted","double","groove","ridge","inset","outset","none","hidden"]}],outlineOffset:[{styleName:"outline-offset",values:0,valueFormat:c.Value.px}],overflow:[{values:["auto","hidden","scroll","visible"]}],overflowX:[{styleName:"overflow-x",values:["auto","hidden","scroll","visible"]}],overflowY:[{styleName:"overflow-y",values:["auto","hidden","scroll","visible"]}],pointerEvents:[{styleName:"pointer-events",values:["none","auto","all"]}],resize:[{values:["none","both","horizontal","vertical","block","inline"]}],rotate:[{values:[0,90,180,270,-90,-180,-270],valueFormat:e=>`${e}deg`}],flip:[{styleName:"scale",values:["xAxis","yAxis"],valueFormat:e=>e==="xAxis"?"-1 1":"1 -1"}],textAlign:[{styleName:"text-align",values:["left","right","center","justify"]}],textDecoration:[{styleName:"text-decoration",values:["none","underline","overline","line-through"]}],textOverflow:[{styleName:"text-overflow",values:["clip","ellipsis"]}],textTransform:[{styleName:"text-transform",values:["none","capitalize","lowercase","uppercase"]}],textWrap:[{styleName:"text-wrap",values:["wrap","nowrap","balance","pretty"]}],transition:[{styleName:"transition-property",values:["none","all"]}],transitionDuration:[{styleName:"transition-duration",values:[50,100,150,200,250,300,350,400,450,500,550,600,650,700,750,800,850,900,950,1e3],valueFormat:e=>`${e}ms`}],userSelect:[{styleName:"user-select",values:["none","auto","text","all"]}],visibility:[{styleName:"visibility",values:["visible","hidden","collapse"]}],whiteSpace:[{styleName:"white-space",values:["break-spaces","normal","nowrap","pre","pre-line","pre-wrap"]}],zIndex:[{styleName:"z-index",values:[1,2,3,4,5,10,11,12,13,14,15,100,101,102,103,104,105,1e3,1001,1002,1003,1004,1005]}],gridTemplateColumns:[{styleName:"grid-template-columns",values:0,valueFormat:e=>`repeat(${e},minmax(0,1fr))`},{styleName:"grid-template-columns",values:["subgrid"]}],gridTemplateRows:[{styleName:"grid-template-rows",values:0,valueFormat:e=>`repeat(${e},minmax(0,1fr))`},{styleName:"grid-template-rows",values:["subgrid"]}],gridColumn:[{styleName:"grid-column",values:0,valueFormat:e=>`span ${e}/span ${e}`},{styleName:"grid-column",values:["full-row"],valueFormat:()=>"1/-1"}],gridColumnStart:[{styleName:"grid-column-start",values:0}],gridColumnEnd:[{styleName:"grid-column-end",values:0}],gridRow:[{styleName:"grid-row",values:0,valueFormat:e=>`span ${e}/span ${e}`},{styleName:"grid-row",values:["full-column"],valueFormat:()=>"1/-1"}],gridRowStart:[{styleName:"grid-row-start",values:0}],gridRowEnd:[{styleName:"grid-row-end",values:0}]},se={hover:":hover",focus:":focus-within",hasFocus:":has(:focus)",active:":active",valid:":user-valid",hasValid:":has(:valid)",invalid:":user-invalid",hasInvalid:":has(:user-invalid)",optional:":optional",hasChecked:":has(:checked)",hasRequired:":has(:required)",hasDisabled:":has([disabled])"},B={indeterminate:":indeterminate",checked:":checked",required:":required",disabled:"[disabled]"},Y={...se,...B},ae=Object.entries(Y).reduce((e,[t],s)=>(e[t]=Math.pow(2,s),e),{}),K=Object.entries(Y).reduce((e,[t])=>{const s=ae[t];return Object.entries(e).forEach(([u,m])=>{e[+u+s]=[...m,t]}),e},{0:[]}),L={hoverGroup:"hover",focusGroup:"focus",activeGroup:"active"},R={sm:640,md:768,lg:1024,xl:1280,xxl:1536};var U;(e=>{function t(n,d,i){const v={...n},y=v.props||{};return d.forEach(a=>{a in v&&(y[a]=v[a],delete v[a])}),i&&Object.entries(i).forEach(([a,f])=>{y[a]=f}),v.props=y,v}e.buildProps=t;function s(n){return!!n&&typeof n=="object"}e.isObject=s;function u(...n){return n.reduce((d,i)=>(Object.keys(i).forEach(v=>{const y=d[v],a=i[v];v in B&&typeof a=="boolean"||(v in B&&Array.isArray(a)?d[v]=u(y,a[1]??{}):Array.isArray(y)&&Array.isArray(a)?d[v]=y.concat(...a):s(y)&&s(a)?d[v]=u(y,a):d[v]=a)}),d),{})}e.mergeDeep=u;function m(n,d){return n in d}e.isKeyOf=m})(U||(U={}));const w=U;class ie{constructor(){this._index=0,this._cache={}}getIdentity(t){return this._cache[t]||(this._cache[t]=this.getByIndex(this._index++)),this._cache[t]}getByIndex(t){const{first:s,next:u}=ue,m=t-s.length;if(m<0)return s[t];const n=Math.floor(m/u.length),d=m-n*u.length;return this.getByIndex(n)+u[d]}}const ue={first:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",next:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"};var W;(e=>{let t="";function s(m,n){return t=Object.entries(m).map(([d,i])=>`--${d}: ${i};`).join(""),Object.entries(n).forEach(([d,i])=>{A[d]=i}),n}e.extend=s;function u(){return t}e.getVariables=u})(W||(W={}));const re=W;var G;(e=>{e.components={}})(G||(G={}));function me(e){const{clean:t,theme:s,component:u}=e;return C.useMemo(()=>{var n,d;if(t)return;let m=(n=G.components)==null?void 0:n[u];if(m)return s?w.mergeDeep(m.styles,((d=m.themes)==null?void 0:d[s])??{}):m.styles},[u,t,s])}const ce=new ie,de=typeof window<"u"&&typeof window.document<"u";var ee;const le=typeof process=="object"&&((ee=process.env)==null?void 0:ee.NODE_ENV)==="test",ve=de&&!le?C.useLayoutEffect:C.useEffect,ne="_b",O="_s";function fe(e,t){ve(S.flush,[e]);const s=me(e);return C.useMemo(()=>{var n;const u=[t?O:ne];(n=e.props)==null||n.name;const m=s?w.mergeDeep(s,e):e;return S.addClassNames(m,u,[]),u},[e,t,s])}var S;(e=>{let t=!0,s={};function u(a,f,p,h,r){Object.entries(a).forEach(([o,l])=>{if(w.isKeyOf(o,A))d(o,l,f,p,h,r);else if(w.isKeyOf(o,se))u(l,f,[...p,o],h,r);else if(w.isKeyOf(o,B)){if(Array.isArray(l)){const[b,x]=l;u(x,f,[...p,o],h,r)}w.isObject(l)&&u(l,f,[...p,o],h,r)}else w.isKeyOf(o,R)?u(l,f,p,o,r):w.isKeyOf(o,L)&&(typeof l=="string"?f.push(`${L[o]}-${l}`):Object.entries(l).forEach(([b,x])=>{u(x,f,[...p,L[o]],h,b)}))})}e.addClassNames=u;function m(){if(!t)return;console.debug("\x1B[36m%s\x1B[0m","[react-box]: flush");const a=Object.entries(A).reduce((o,[l],b)=>(o[l]=b,o),{}),f=`:root{${re.getVariables()}--borderColor: black;--outlineColor: black;--lineHeight: 1.2;--fontSize: 14px;--transitionTime: 0.25s;--svgTransitionTime: 0.3s;}#crono-box {position: absolute;top: 0;left: 0;height: 0;}
1
+ "use strict";const C=require("react");function te(...e){return e.reduce((t,s)=>s?typeof s=="string"?(t.push(s),t):Array.isArray(s)?(t.push(...te(...s)),t):(Object.entries(s).forEach(([m,c])=>{c&&t.push(m)}),t):t,[])}var l;(e=>{(t=>{function s(c,n){return`${c}${n.replace("/","-")}`}t.fraction=s;function m(c){return[`${c} path`,`${c} circle`,`${c} rect`,`${c} line`]}t.svg=m})(e.ClassName||(e.ClassName={})),(t=>{function s(y){return`${y/4}rem`}t.rem=s;function m(y){return`${y}px`}t.px=m;function c(y,r){const[i,o]=r.split("/");return`${+i/+o*100}%`}t.fraction=c;function n(y,r){switch(r){case"fit":return"100%";case"fit-screen":return y.toLocaleLowerCase().includes("height")?"100vh":"100vw";default:return r}}t.widthHeight=n;function d(y){return(r,i)=>`var(--${y}${i});`}t.variables=d;function u(y){return(r,i)=>`var(--${y}${i});`}t.svgVariables=u;function v(y,r){return`repeat(${r},minmax(0,1fr))`}t.gridColumns=v;function h(y,r){return r==="full-row"?"1/-1":`span ${r}/span ${r}`}t.gridColumn=h;function a(y,r){return`${r}ms`}t.ms=a;function f(y,r){return`${r}deg`}t.rotate=f;function p(y,r){return r==="xAxis"?"-1 1":"1 -1"}t.flip=p})(e.Value||(e.Value={}))})(l||(l={}));const T={appearance:[{values:["none","auto","menulist-button","textfield","button","checkbox"]}],b:[{values:0,styleName:"border-width",valueFormat:l.Value.px}],bx:[{values:0,styleName:"border-inline-width",valueFormat:l.Value.px}],by:[{values:0,styleName:"border-block-width",valueFormat:l.Value.px}],bt:[{values:0,styleName:"border-top-width",valueFormat:l.Value.px}],br:[{values:0,styleName:"border-right-width",valueFormat:l.Value.px}],bb:[{values:0,styleName:"border-bottom-width",valueFormat:l.Value.px}],bl:[{values:0,styleName:"border-left-width",valueFormat:l.Value.px}],borderStyle:[{styleName:"border-style",values:["solid","dashed","dotted","double","groove","ridge","inset","outset","none","hidden"]}],borderRadius:[{styleName:"border-radius",values:0,valueFormat:l.Value.rem}],borderRadiusTop:[{values:0,styleName:["border-top-left-radius","border-top-right-radius"],valueFormat:l.Value.rem}],borderRadiusRight:[{values:0,styleName:["border-top-right-radius","border-bottom-right-radius"],valueFormat:l.Value.rem}],borderRadiusBottom:[{values:0,styleName:["border-bottom-left-radius","border-bottom-right-radius"],valueFormat:l.Value.rem}],borderRadiusLeft:[{values:0,styleName:["border-top-left-radius","border-bottom-left-radius"],valueFormat:l.Value.rem}],borderRadiusTopLeft:[{values:0,styleName:"border-top-left-radius",valueFormat:l.Value.rem}],borderRadiusTopRight:[{values:0,styleName:"border-top-right-radius",valueFormat:l.Value.rem}],borderRadiusBottomRight:[{values:0,styleName:"border-bottom-right-radius",valueFormat:l.Value.rem}],borderRadiusBottomLeft:[{values:0,styleName:"border-bottom-left-radius",valueFormat:l.Value.rem}],position:[{values:["static","relative","absolute","fixed","sticky"]}],top:[{values:0,valueFormat:l.Value.rem}],right:[{values:0,valueFormat:l.Value.rem}],bottom:[{values:0,valueFormat:l.Value.rem}],left:[{values:0,valueFormat:l.Value.rem}],inset:[{values:0,valueFormat:l.Value.rem}],boxSizing:[{values:["border-box","content-box"],styleName:"box-sizing"}],contentVisibility:[{values:["visible","hidden"],styleName:"content-visibility"}],cursor:[{values:["auto","default","none","context-menu","help","pointer","progress","wait","cell","crosshair","text","vertical-text","alias","copy","move","no-drop","not-allowed","e-resize","n-resize","ne-resize","nw-resize","s-resize","se-resize","sw-resize","w-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","col-resize","row-resize","all-scroll","zoom-in","zoom-out","grab","grabbing"]}],display:[{values:["none","block","inline-block","flex","inline-flex","grid","inline-grid","contents"]}],inline:[{values:[!0],styleName:"display",valueFormat:()=>"inline-block"}],jc:[{styleName:"justify-content",values:["start","end","flex-start","flex-end","center","left","right","space-between","space-around","space-evenly","stretch"]}],ai:[{styleName:"align-items",values:["stretch","flex-start","flex-end","center","baseline","start","end","self-start","self-end"]}],alignContent:[{styleName:"align-content",values:["flex-start","flex-end","center","space-between","space-around","space-evenly","stretch","start","end","baseline"]}],flex1:[{styleName:"flex",values:[!0],valueFormat:()=>"1"}],d:[{styleName:"flex-direction",values:["row","row-reverse","column","column-reverse"]}],flexWrap:[{styleName:"flex-wrap",values:["nowrap","wrap","wrap-reverse"]}],flexGrow:[{styleName:"flex-grow",values:0}],flexShrink:[{styleName:"flex-shrink",values:0}],alignSelf:[{styleName:"align-self",values:["auto","flex-start","flex-end","center","baseline","stretch"]}],justifySelf:[{styleName:"justify-self",values:["auto","flex-start","flex-end","center","baseline","stretch"]}],fontSize:[{styleName:"font-size",values:0,valueFormat:l.Value.px},{styleName:"font-size",values:["inherit"]}],fontStyle:[{styleName:"font-style",values:["italic","normal","oblique"]}],fontWeight:[{styleName:"font-weight",values:[100,200,300,400,500,600,700,800,900]}],gap:[{values:0,valueFormat:l.Value.rem}],rowGap:[{styleName:"row-gap",values:0,valueFormat:l.Value.rem}],columnGap:[{styleName:"column-gap",values:0,valueFormat:l.Value.rem}],order:[{styleName:"order",values:0}],height:[{values:0,valueFormat:e=>`${e/4}rem`},{values:["fit"],valueFormat:()=>"100%"},{values:["fit-screen"],valueFormat:()=>"100vh"},{values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{values:["auto","fit-content","max-content","min-content"]}],minHeight:[{styleName:"min-height",values:0,valueFormat:e=>`${e/4}rem`},{styleName:"min-height",values:["fit"],valueFormat:()=>"100%"},{styleName:"min-height",values:["fit-screen"],valueFormat:()=>"100vh"},{styleName:"min-height",values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{styleName:"min-height",values:["auto","fit-content","max-content","min-content"]}],maxHeight:[{styleName:"max-height",values:0,valueFormat:e=>`${e/4}rem`},{styleName:"max-height",values:["fit"],valueFormat:()=>"100%"},{styleName:"max-height",values:["fit-screen"],valueFormat:()=>"100vh"},{styleName:"max-height",values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{styleName:"max-height",values:["auto","fit-content","max-content","min-content"]}],width:[{values:0,valueFormat:e=>`${e/4}rem`},{values:["fit"],valueFormat:()=>"100%"},{values:["fit-screen"],valueFormat:()=>"100vw"},{values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{values:["auto","fit-content","max-content","min-content"]}],minWidth:[{styleName:"min-width",values:0,valueFormat:e=>`${e/4}rem`},{styleName:"min-width",values:["fit"],valueFormat:()=>"100%"},{styleName:"min-width",values:["fit-screen"],valueFormat:()=>"100vw"},{styleName:"min-width",values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{styleName:"min-width",values:["auto","fit-content","max-content","min-content"]}],maxWidth:[{styleName:"max-width",values:0,valueFormat:e=>`${e/4}rem`},{styleName:"max-width",values:["fit"],valueFormat:()=>"100%"},{styleName:"max-width",values:["fit-screen"],valueFormat:()=>"100vw"},{styleName:"max-width",values:["1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],valueFormat:e=>{const[t,s]=e.split("/");return`${+t/+s*100}%`}},{styleName:"max-width",values:["auto","fit-content","max-content","min-content"]}],letterSpacing:[{styleName:"letter-spacing",values:0,valueFormat:l.Value.px}],lineHeight:[{styleName:"line-height",values:0,valueFormat:l.Value.px},{styleName:"line-height",values:["font-size"],valueFormat:e=>"1"}],listStyle:[{styleName:"list-style",values:["square","inside","outside","none"]}],m:[{values:0,styleName:"margin",valueFormat:l.Value.rem},{values:["auto"],styleName:"margin"}],mx:[{values:0,styleName:"margin-inline",valueFormat:l.Value.rem},{values:["auto"],styleName:"margin-inline"}],my:[{values:0,styleName:"margin-block",valueFormat:l.Value.rem},{values:["auto"],styleName:"margin-block"}],mt:[{values:0,styleName:"margin-top",valueFormat:l.Value.rem},{values:["auto"],styleName:"margin-top"}],mr:[{values:0,styleName:"margin-right",valueFormat:l.Value.rem},{values:["auto"],styleName:"margin-right"}],mb:[{values:0,styleName:"margin-bottom",valueFormat:l.Value.rem},{values:["auto"],styleName:"margin-bottom"}],ml:[{values:0,styleName:"margin-left",valueFormat:l.Value.rem},{values:["auto"],styleName:"margin-left"}],p:[{values:0,styleName:"padding",valueFormat:l.Value.rem}],px:[{values:0,styleName:"padding-inline",valueFormat:l.Value.rem}],py:[{values:0,styleName:"padding-block",valueFormat:l.Value.rem}],pt:[{values:0,styleName:"padding-top",valueFormat:l.Value.rem}],pr:[{values:0,styleName:"padding-right",valueFormat:l.Value.rem}],pb:[{values:0,styleName:"padding-bottom",valueFormat:l.Value.rem}],pl:[{values:0,styleName:"padding-left",valueFormat:l.Value.rem}],objectFit:[{styleName:"object-fit",values:["fill","contain","cover","scale-down","none"]}],opacity:[{values:[0,.1,.2,.3,.4,.5,.6,.7,.8,.9,1]}],outline:[{styleName:"outline-width",values:0,valueFormat:l.Value.px}],outlineStyle:[{styleName:"outline-style",values:["solid","dashed","dotted","double","groove","ridge","inset","outset","none","hidden"]}],outlineOffset:[{styleName:"outline-offset",values:0,valueFormat:l.Value.px}],overflow:[{values:["auto","hidden","scroll","visible"]}],overflowX:[{styleName:"overflow-x",values:["auto","hidden","scroll","visible"]}],overflowY:[{styleName:"overflow-y",values:["auto","hidden","scroll","visible"]}],pointerEvents:[{styleName:"pointer-events",values:["none","auto","all"]}],resize:[{values:["none","both","horizontal","vertical","block","inline"]}],rotate:[{values:[0,90,180,270,-90,-180,-270],valueFormat:e=>`${e}deg`}],flip:[{styleName:"scale",values:["xAxis","yAxis"],valueFormat:e=>e==="xAxis"?"-1 1":"1 -1"}],textAlign:[{styleName:"text-align",values:["left","right","center","justify"]}],textDecoration:[{styleName:"text-decoration",values:["none","underline","overline","line-through"]}],textOverflow:[{styleName:"text-overflow",values:["clip","ellipsis"]}],textTransform:[{styleName:"text-transform",values:["none","capitalize","lowercase","uppercase"]}],textWrap:[{styleName:"text-wrap",values:["wrap","nowrap","balance","pretty"]}],transition:[{styleName:"transition-property",values:["none","all"]}],transitionDuration:[{styleName:"transition-duration",values:[50,100,150,200,250,300,350,400,450,500,550,600,650,700,750,800,850,900,950,1e3],valueFormat:e=>`${e}ms`}],userSelect:[{styleName:"user-select",values:["none","auto","text","all"]}],visibility:[{styleName:"visibility",values:["visible","hidden","collapse"]}],whiteSpace:[{styleName:"white-space",values:["break-spaces","normal","nowrap","pre","pre-line","pre-wrap"]}],zIndex:[{styleName:"z-index",values:[1,2,3,4,5,10,11,12,13,14,15,100,101,102,103,104,105,1e3,1001,1002,1003,1004,1005]}],gridTemplateColumns:[{styleName:"grid-template-columns",values:0,valueFormat:e=>`repeat(${e},minmax(0,1fr))`},{styleName:"grid-template-columns",values:["subgrid"]}],gridTemplateRows:[{styleName:"grid-template-rows",values:0,valueFormat:e=>`repeat(${e},minmax(0,1fr))`},{styleName:"grid-template-rows",values:["subgrid"]}],gridColumn:[{styleName:"grid-column",values:0,valueFormat:e=>`span ${e}/span ${e}`},{styleName:"grid-column",values:["full-row"],valueFormat:()=>"1/-1"}],gridColumnStart:[{styleName:"grid-column-start",values:0}],gridColumnEnd:[{styleName:"grid-column-end",values:0}],gridRow:[{styleName:"grid-row",values:0,valueFormat:e=>`span ${e}/span ${e}`},{styleName:"grid-row",values:["full-column"],valueFormat:()=>"1/-1"}],gridRowStart:[{styleName:"grid-row-start",values:0}],gridRowEnd:[{styleName:"grid-row-end",values:0}]},se={hover:":hover",focus:":focus-within",hasFocus:":has(:focus)",active:":active",valid:":user-valid",hasValid:":has(:valid)",invalid:":user-invalid",hasInvalid:":has(:user-invalid)",optional:":optional",hasChecked:":has(:checked)",hasRequired:":has(:required)",hasDisabled:":has([disabled])"},D={indeterminate:":indeterminate",checked:":checked",required:":required",disabled:"[disabled]"},J={...se,...D},ae=Object.entries(J).reduce((e,[t],s)=>(e[t]=Math.pow(2,s),e),{}),L=Object.entries(J).reduce((e,[t])=>{const s=ae[t];return Object.entries(e).forEach(([m,c])=>{e[+m+s]=[...c,t]}),e},{0:[]}),U={hoverGroup:"hover",focusGroup:"focus",activeGroup:"active",disabledGroup:"disabled"},G={sm:640,md:768,lg:1024,xl:1280,xxl:1536};var W;(e=>{function t(n,d,u){const v={...n},h=v.props||{};return d.forEach(a=>{a in v&&(h[a]=v[a],delete v[a])}),u&&Object.entries(u).forEach(([a,f])=>{h[a]=f}),v.props=h,v}e.buildProps=t;function s(n){return!!n&&typeof n=="object"}e.isObject=s;function m(...n){return n.reduce((d,u)=>(Object.keys(u).forEach(v=>{const h=d[v],a=u[v];v in D&&typeof a=="boolean"||(v in D&&Array.isArray(a)?d[v]=m(h,a[1]??{}):Array.isArray(h)&&Array.isArray(a)?d[v]=h.concat(...a):s(h)&&s(a)?d[v]=m(h,a):d[v]=a)}),d),{})}e.mergeDeep=m;function c(n,d){return n in d}e.isKeyOf=c})(W||(W={}));const w=W;class ie{constructor(){this._index=0,this._cache={}}getIdentity(t){return this._cache[t]||(this._cache[t]=this.getByIndex(this._index++)),this._cache[t]}getByIndex(t){const{first:s,next:m}=ue,c=t-s.length;if(c<0)return s[t];const n=Math.floor(c/m.length),d=c-n*m.length;return this.getByIndex(n)+m[d]}}const ue={first:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",next:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"};var M;(e=>{let t="";function s(c,n){return t=Object.entries(c).map(([d,u])=>`--${d}: ${u};`).join(""),Object.entries(n).forEach(([d,u])=>{T[d]=u}),n}e.extend=s;function m(){return t}e.getVariables=m})(M||(M={}));const re=M;var q;(e=>{e.components={}})(q||(q={}));function me(e){const{clean:t,theme:s,component:m}=e;return C.useMemo(()=>{var n,d;if(t)return;let c=(n=q.components)==null?void 0:n[m];if(c)return s?w.mergeDeep(c.styles,((d=c.themes)==null?void 0:d[s])??{}):c.styles},[m,t,s])}const ce=new ie,de=typeof window<"u"&&typeof window.document<"u";var ee;const le=typeof process=="object"&&((ee=process.env)==null?void 0:ee.NODE_ENV)==="test",ve=de&&!le?C.useLayoutEffect:C.useEffect,oe="_b",O="_s";function fe(e,t){ve(S.flush,[e]);const s=me(e);return C.useMemo(()=>{var n;const m=[t?O:oe];(n=e.props)==null||n.name;const c=s?w.mergeDeep(s,e):e;return S.addClassNames(c,m,[]),m},[e,t,s])}var S;(e=>{let t=!0,s={};function m(a,f,p,y,r){Object.entries(a).forEach(([i,o])=>{if(w.isKeyOf(i,T))d(i,o,f,p,y,r);else if(w.isKeyOf(i,se))m(o,f,[...p,i],y,r);else if(w.isKeyOf(i,D)){if(Array.isArray(o)){const[x,N]=o;m(N,f,[...p,i],y,r)}w.isObject(o)&&m(o,f,[...p,i],y,r)}else w.isKeyOf(i,G)?m(o,f,p,i,r):w.isKeyOf(i,U)&&(typeof o=="string"?f.push(`${U[i]}-${o}`):Object.entries(o).forEach(([x,N])=>{m(N,f,[...p,U[i]],y,x)}))})}e.addClassNames=m;function c(){if(!t)return;console.debug("\x1B[36m%s\x1B[0m","[react-box]: flush");const a=Object.entries(T).reduce((i,[o],x)=>(i[o]=x,i),{}),f=`:root{${re.getVariables()}--borderColor: black;--outlineColor: black;--lineHeight: 1.2;--fontSize: 14px;--transitionTime: 0.25s;--svgTransitionTime: 0.3s;}#crono-box {position: absolute;top: 0;left: 0;height: 0;}
2
2
  html{font-size: 16px;font-family: Arial, sans-serif;}
3
3
  body{margin: 0;line-height: var(--lineHeight);font-size: var(--fontSize);}
4
4
  a,ul{all: unset;}
5
- .${ne}{display: block;border: 0 solid var(--borderColor);outline: 0px solid var(--outlineColor);margin: 0;padding: 0;background-color: initial;transition: all var(--transitionTime);box-sizing: border-box;font-family: inherit;font-size: inherit;}
5
+ .${oe}{display: block;border: 0 solid var(--borderColor);outline: 0px solid var(--outlineColor);margin: 0;padding: 0;background-color: initial;transition: all var(--transitionTime);box-sizing: border-box;font-family: inherit;font-size: inherit;}
6
6
  .${O}{display: block;border: 0 solid var(--borderColor);outline: 0px solid var(--outlineColor);margin: 0;padding: 0;transition: all var(--svgTransitionTime);}.${O} path,.${O} circle,.${O} rect,.${O} line {transition: all var(--svgTransitionTime);}
7
- `,p=Object.entries(s);p.sort(([o],[l])=>(R[o]??0)-(R[l]??0));const h=p.reduce((o,[l,b])=>(l!=="normal"&&o.push(`@media(min-width: ${R[l]}px){`),Object.entries(b).forEach(([x,D])=>{const{__parents:J,...oe}=D,Q=Object.entries(oe);Q.sort(([$],[_])=>a[$]-a[_]),Q.forEach(([$,_])=>{_.forEach(F=>{var I,V;const g=A[$].find(z=>Array.isArray(z.values)?z.values.includes(F):typeof F==typeof z.values);if(!g)return;const E=i($,F,+x,l),Z=g.styleName??$,N=((I=g.valueFormat)==null?void 0:I.call(g,F))??F,T=K[+x].map(z=>Y[z]).join(""),q=((V=g.selector)==null?void 0:V.call(g,`.${E}`,T))??`.${E}${T}`;o.push(`${q}{${Z}:${N}}`)})}),J&&Object.entries(J).forEach(([$,_])=>{const F=Object.entries(_);F.sort(([j],[g])=>a[j]-a[g]),F.forEach(([j,g])=>{g.forEach(E=>{var P,k;const N=A[j].find(H=>Array.isArray(H.values)?H.values.includes(E):typeof E==typeof H.values);if(!N)return;const T=i(j,E,+x,l,$),q=N.styleName??j,I=((P=N.valueFormat)==null?void 0:P.call(N,E))??E,[V]=K[+x],z=((k=N.selector)==null?void 0:k.call(N,`.${V}-${$}:${V} .${T}`,""))??`.${V}-${$}:${V} .${T}`;o.push(`${z}{${q}:${I}}`)})})})}),l!=="normal"&&o.push("}"),o),[f]),r=y();r.innerHTML=h.join(""),t=!1}e.flush=m;function n(){s={}}e.clear=n;function d(a,f,p,h,r="normal",o){if(f==null)return;const l=h.reduce((x,D)=>x+ae[D],0);s[r]?s[r][l]?s[r][l][a]||(s[r][l][a]=new Set):s[r][l]={[a]:new Set}:s[r]={[l]:{[a]:new Set}},o?(s[r][l].__parents?s[r][l].__parents[o]?s[r][l].__parents[o][a]||(s[r][l].__parents[o][a]=new Set):s[r][l].__parents[o]={[a]:new Set}:s[r][l].__parents={[o]:{[a]:new Set}},s[r][l].__parents[o][a].has(f)||(s[r][l].__parents[o][a].add(f),t=!0)):s[r][l][a].has(f)||(s[r][l][a].add(f),t=!0);const b=i(a,f,l,r,o);p.push(b)}function i(a,f,p,h,r){const o=K[p],l=`${h==="normal"?"":`${h}-`}${o.map(b=>`${b}-`).join("")}${r?`${r}-`:""}${a}-${f}`;return le?l:ce.getIdentity(l)}const v="crono-styles";function y(){let a=document.getElementById(v);return a||(a=document.createElement("style"),a.setAttribute("id",v),a.setAttribute("type","text/css"),document.head.insertBefore(a,document.head.firstChild)),a}})(S||(S={}));exports.StylesContext=void 0;(e=>{e.flush=S.flush,e.clear=S.clear})(exports.StylesContext||(exports.StylesContext={}));var M;(e=>{const t={button:{styles:{display:"inline-block",p:3,cursor:"pointer",b:1,borderRadius:1,userSelect:"none",disabled:{cursor:"default"}}},checkbox:{styles:{display:"inline-block"}},radioButton:{styles:{display:"inline-block",b:1,p:2}},textbox:{styles:{display:"inline-block",b:1,borderRadius:1,p:3}},textarea:{styles:{display:"inline-block",b:1,borderRadius:1}}};function s(u){const{components:m,...n}=u,d=m??{};Object.entries(n).forEach(([i,v])=>{d[i]=v}),G.components=w.mergeDeep(t,d)}e.setup=s})(M||(M={}));const he=M;var X;(e=>{function t(u){const m=Array.from(u.elements).reduce((n,d)=>{const i=d.name;return i&&(n[i]||(n[i]=[]),n[i].push(d)),n},{});return Object.entries(m).reduce((n,[d,i])=>{if(i.length===1){const v=i[0];s(n,d,v.type==="checkbox"||v.type==="radio"?v.checked:v.value)}else{const v=i.reduce((y,a)=>(a.type==="checkbox"||a.type==="radio"?a.checked&&y.push(a.value):y.push(a.value),y),[]);s(n,d,v)}return n},{})}e.getFormEntries=t;function s(u,m,n){if(m.includes(".")){const d=m.split(".");let i=u;d.forEach((v,y)=>{if(d.length>y+1){const a=v.match(/^(.+)\[(\d)\]$/);if(a){const[,f,p]=a;i[f]=i[f]||[],i[f][p]=i[f][p]||{},i=i[f][p]}else i[v]=i[v]||{},i=i[v]}else i[v]=n})}else u[m]=n}})(X||(X={}));const ye=X;function pe(){return C.useMemo(()=>{const e="crono-box";let t=document.getElementById(e);return t||(t=document.createElement("div"),t.id=e,document.body.appendChild(t)),t},[])}exports.BoxExtends=re;exports.FormUtils=ye;exports.ObjectUtils=w;exports.Theme=he;exports.classNames=te;exports.usePortalContainer=pe;exports.useStyles=fe;
7
+ `,p=Object.entries(s);p.sort(([i],[o])=>(G[i]??0)-(G[o]??0));const y=p.reduce((i,[o,x])=>(o!=="normal"&&i.push(`@media(min-width: ${G[o]}px){`),Object.entries(x).forEach(([N,H])=>{const{__parents:Q,...ne}=H,Z=Object.entries(ne);Z.sort(([F],[_])=>a[F]-a[_]),Z.forEach(([F,_])=>{_.forEach(V=>{var R,B;const b=T[F].find($=>Array.isArray($.values)?$.values.includes(V):typeof V==typeof $.values);if(!b)return;const E=u(F,V,+N,o),K=L[+N].map($=>J[$]).join(""),g=((R=b.selector)==null?void 0:R.call(b,`.${E}`,K))??`.${E}${K}`,I=Array.isArray(b.styleName)?b.styleName:[b.styleName??F],z=((B=b.valueFormat)==null?void 0:B.call(b,V))??V;i.push(`${g}{${I.map($=>`${$}:${z}`).join(";")}}`)})}),Q&&Object.entries(Q).forEach(([F,_])=>{const V=Object.entries(_);V.sort(([j],[b])=>a[j]-a[b]),V.forEach(([j,b])=>{b.forEach(E=>{var P,k;const g=T[j].find(A=>Array.isArray(A.values)?A.values.includes(E):typeof E==typeof A.values);if(!g)return;const I=u(j,E,+N,o,F),[z]=L[+N],R=((P=g.selector)==null?void 0:P.call(g,`.${z}-${F}:${z} .${I}`,""))??`.${z}-${F}:${z} .${I}`,B=Array.isArray(g.styleName)?g.styleName:[g.styleName??j],$=((k=g.valueFormat)==null?void 0:k.call(g,E))??E;i.push(`${R}{${B.map(A=>`${A}:${$}`).join(";")}}`)})})})}),o!=="normal"&&i.push("}"),i),[f]),r=h();r.innerHTML=y.join(""),t=!1}e.flush=c;function n(){s={}}e.clear=n;function d(a,f,p,y,r="normal",i){if(f==null)return;const o=y.reduce((N,H)=>N+ae[H],0);s[r]?s[r][o]?s[r][o][a]||(s[r][o][a]=new Set):s[r][o]={[a]:new Set}:s[r]={[o]:{[a]:new Set}},i?(s[r][o].__parents?s[r][o].__parents[i]?s[r][o].__parents[i][a]||(s[r][o].__parents[i][a]=new Set):s[r][o].__parents[i]={[a]:new Set}:s[r][o].__parents={[i]:{[a]:new Set}},s[r][o].__parents[i][a].has(f)||(s[r][o].__parents[i][a].add(f),t=!0)):s[r][o][a].has(f)||(s[r][o][a].add(f),t=!0);const x=u(a,f,o,r,i);p.push(x)}function u(a,f,p,y,r){const i=L[p],o=`${y==="normal"?"":`${y}-`}${i.map(x=>`${x}-`).join("")}${r?`${r}-`:""}${a}-${f}`;return le?o:ce.getIdentity(o)}const v="crono-styles";function h(){let a=document.getElementById(v);return a||(a=document.createElement("style"),a.setAttribute("id",v),a.setAttribute("type","text/css"),document.head.insertBefore(a,document.head.firstChild)),a}})(S||(S={}));exports.StylesContext=void 0;(e=>{e.flush=S.flush,e.clear=S.clear})(exports.StylesContext||(exports.StylesContext={}));var X;(e=>{const t={button:{styles:{display:"inline-block",p:3,cursor:"pointer",b:1,borderRadius:1,userSelect:"none",disabled:{cursor:"default"}}},checkbox:{styles:{display:"inline-block"}},radioButton:{styles:{display:"inline-block",b:1,p:2}},textbox:{styles:{display:"inline-block",b:1,borderRadius:1,p:3}},textarea:{styles:{display:"inline-block",b:1,borderRadius:1}}};function s(m){const{components:c,...n}=m,d=c??{};Object.entries(n).forEach(([u,v])=>{d[u]=v}),q.components=w.mergeDeep(t,d)}e.setup=s})(X||(X={}));const ye=X;var Y;(e=>{function t(m){const c=Array.from(m.elements).reduce((n,d)=>{const u=d.name;return u&&(n[u]||(n[u]=[]),n[u].push(d)),n},{});return Object.entries(c).reduce((n,[d,u])=>{if(u.length===1){const v=u[0];s(n,d,v.type==="checkbox"||v.type==="radio"?v.checked:v.value)}else{const v=u.reduce((h,a)=>(a.type==="checkbox"||a.type==="radio"?a.checked&&h.push(a.value):h.push(a.value),h),[]);s(n,d,v)}return n},{})}e.getFormEntries=t;function s(m,c,n){if(c.includes(".")){const d=c.split(".");let u=m;d.forEach((v,h)=>{if(d.length>h+1){const a=v.match(/^(.+)\[(\d)\]$/);if(a){const[,f,p]=a;u[f]=u[f]||[],u[f][p]=u[f][p]||{},u=u[f][p]}else u[v]=u[v]||{},u=u[v]}else u[v]=n})}else m[c]=n}})(Y||(Y={}));const he=Y;function pe(){return C.useMemo(()=>{const e="crono-box";let t=document.getElementById(e);return t||(t=document.createElement("div"),t.id=e,document.body.appendChild(t)),t},[])}exports.BoxExtends=re;exports.FormUtils=he;exports.ObjectUtils=w;exports.Theme=ye;exports.classNames=te;exports.usePortalContainer=pe;exports.useStyles=fe;
package/core.mjs CHANGED
@@ -1,34 +1,34 @@
1
- import { useMemo as X, useLayoutEffect as oe, useEffect as ie } from "react";
1
+ import { useMemo as Y, useLayoutEffect as ne, useEffect as ie } from "react";
2
2
  function ue(...e) {
3
- return e.reduce((t, s) => s ? typeof s == "string" ? (t.push(s), t) : Array.isArray(s) ? (t.push(...ue(...s)), t) : (Object.entries(s).forEach(([u, m]) => {
4
- m && t.push(u);
3
+ return e.reduce((t, a) => a ? typeof a == "string" ? (t.push(a), t) : Array.isArray(a) ? (t.push(...ue(...a)), t) : (Object.entries(a).forEach(([m, c]) => {
4
+ c && t.push(m);
5
5
  }), t) : t, []);
6
6
  }
7
- var c;
7
+ var l;
8
8
  ((e) => {
9
9
  ((t) => {
10
- function s(m, n) {
11
- return `${m}${n.replace("/", "-")}`;
10
+ function a(c, n) {
11
+ return `${c}${n.replace("/", "-")}`;
12
12
  }
13
- t.fraction = s;
14
- function u(m) {
15
- return [`${m} path`, `${m} circle`, `${m} rect`, `${m} line`];
13
+ t.fraction = a;
14
+ function m(c) {
15
+ return [`${c} path`, `${c} circle`, `${c} rect`, `${c} line`];
16
16
  }
17
- t.svg = u;
17
+ t.svg = m;
18
18
  })(e.ClassName || (e.ClassName = {})), ((t) => {
19
- function s(h) {
19
+ function a(h) {
20
20
  return `${h / 4}rem`;
21
21
  }
22
- t.rem = s;
23
- function u(h) {
22
+ t.rem = a;
23
+ function m(h) {
24
24
  return `${h}px`;
25
25
  }
26
- t.px = u;
27
- function m(h, r) {
28
- const [o, l] = r.split("/");
29
- return `${+o / +l * 100}%`;
26
+ t.px = m;
27
+ function c(h, r) {
28
+ const [i, o] = r.split("/");
29
+ return `${+i / +o * 100}%`;
30
30
  }
31
- t.fraction = m;
31
+ t.fraction = c;
32
32
  function n(h, r) {
33
33
  switch (r) {
34
34
  case "fit":
@@ -41,13 +41,13 @@ var c;
41
41
  }
42
42
  t.widthHeight = n;
43
43
  function d(h) {
44
- return (r, o) => `var(--${h}${o});`;
44
+ return (r, i) => `var(--${h}${i});`;
45
45
  }
46
46
  t.variables = d;
47
- function i(h) {
48
- return (r, o) => `var(--${h}${o});`;
47
+ function u(h) {
48
+ return (r, i) => `var(--${h}${i});`;
49
49
  }
50
- t.svgVariables = i;
50
+ t.svgVariables = u;
51
51
  function v(h, r) {
52
52
  return `repeat(${r},minmax(0,1fr))`;
53
53
  }
@@ -56,10 +56,10 @@ var c;
56
56
  return r === "full-row" ? "1/-1" : `span ${r}/span ${r}`;
57
57
  }
58
58
  t.gridColumn = y;
59
- function a(h, r) {
59
+ function s(h, r) {
60
60
  return `${r}ms`;
61
61
  }
62
- t.ms = a;
62
+ t.ms = s;
63
63
  function f(h, r) {
64
64
  return `${r}deg`;
65
65
  }
@@ -69,8 +69,8 @@ var c;
69
69
  }
70
70
  t.flip = p;
71
71
  })(e.Value || (e.Value = {}));
72
- })(c || (c = {}));
73
- const A = {
72
+ })(l || (l = {}));
73
+ const T = {
74
74
  /** The appearance CSS property is used to display UI elements with platform-specific styling, based on the operating system's theme. */
75
75
  appearance: [
76
76
  {
@@ -82,7 +82,7 @@ const A = {
82
82
  {
83
83
  values: 0,
84
84
  styleName: "border-width",
85
- valueFormat: c.Value.px
85
+ valueFormat: l.Value.px
86
86
  }
87
87
  ],
88
88
  /** The border-width shorthand CSS property sets the width of an element's left and right border. */
@@ -90,7 +90,7 @@ const A = {
90
90
  {
91
91
  values: 0,
92
92
  styleName: "border-inline-width",
93
- valueFormat: c.Value.px
93
+ valueFormat: l.Value.px
94
94
  }
95
95
  ],
96
96
  /** The border-width shorthand CSS property sets the width of an element's top and bottom border. */
@@ -98,7 +98,7 @@ const A = {
98
98
  {
99
99
  values: 0,
100
100
  styleName: "border-block-width",
101
- valueFormat: c.Value.px
101
+ valueFormat: l.Value.px
102
102
  }
103
103
  ],
104
104
  /** The border-top-width CSS property sets the width of the top border of an element. */
@@ -106,7 +106,7 @@ const A = {
106
106
  {
107
107
  values: 0,
108
108
  styleName: "border-top-width",
109
- valueFormat: c.Value.px
109
+ valueFormat: l.Value.px
110
110
  }
111
111
  ],
112
112
  /** The border-right-width CSS property sets the width of the right border of an element. */
@@ -114,7 +114,7 @@ const A = {
114
114
  {
115
115
  values: 0,
116
116
  styleName: "border-right-width",
117
- valueFormat: c.Value.px
117
+ valueFormat: l.Value.px
118
118
  }
119
119
  ],
120
120
  /** The border-bottom-width CSS property sets the width of the bottom border of an element. */
@@ -122,7 +122,7 @@ const A = {
122
122
  {
123
123
  values: 0,
124
124
  styleName: "border-bottom-width",
125
- valueFormat: c.Value.px
125
+ valueFormat: l.Value.px
126
126
  }
127
127
  ],
128
128
  /** The border-left-width CSS property sets the width of the left border of an element. */
@@ -130,7 +130,7 @@ const A = {
130
130
  {
131
131
  values: 0,
132
132
  styleName: "border-left-width",
133
- valueFormat: c.Value.px
133
+ valueFormat: l.Value.px
134
134
  }
135
135
  ],
136
136
  /** The border-style shorthand CSS property sets the line style for all four sides of an element's border. */
@@ -145,71 +145,71 @@ const A = {
145
145
  {
146
146
  styleName: "border-radius",
147
147
  values: 0,
148
- valueFormat: c.Value.rem
148
+ valueFormat: l.Value.rem
149
149
  }
150
150
  ],
151
151
  /** The border-top-radius CSS property rounds the top corners of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
152
152
  borderRadiusTop: [
153
153
  {
154
154
  values: 0,
155
- styleName: "border-radius",
156
- valueFormat: (e) => `${e / 4}rem ${e / 4}rem 0 0`
155
+ styleName: ["border-top-left-radius", "border-top-right-radius"],
156
+ valueFormat: l.Value.rem
157
157
  }
158
158
  ],
159
159
  /** The border-right-radius CSS property rounds the right corners of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
160
160
  borderRadiusRight: [
161
161
  {
162
162
  values: 0,
163
- styleName: "border-radius",
164
- valueFormat: (e) => `0 ${e / 4}rem ${e / 4}rem 0`
163
+ styleName: ["border-top-right-radius", "border-bottom-right-radius"],
164
+ valueFormat: l.Value.rem
165
165
  }
166
166
  ],
167
167
  /** The border-bottom-radius CSS property rounds the bottom corners of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
168
168
  borderRadiusBottom: [
169
169
  {
170
170
  values: 0,
171
- styleName: "border-radius",
172
- valueFormat: (e) => `0 0 ${e / 4}rem ${e / 4}rem`
171
+ styleName: ["border-bottom-left-radius", "border-bottom-right-radius"],
172
+ valueFormat: l.Value.rem
173
173
  }
174
174
  ],
175
175
  /** The border-left-radius CSS property rounds the left corners of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
176
176
  borderRadiusLeft: [
177
177
  {
178
178
  values: 0,
179
- styleName: "border-radius",
180
- valueFormat: (e) => `${e / 4}rem 0 0 ${e / 4}rem`
179
+ styleName: ["border-top-left-radius", "border-bottom-left-radius"],
180
+ valueFormat: l.Value.rem
181
181
  }
182
182
  ],
183
183
  /** The border-top-left-radius CSS property rounds the top-left corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
184
184
  borderRadiusTopLeft: [
185
185
  {
186
186
  values: 0,
187
- styleName: "border-radius",
188
- valueFormat: (e) => `${e / 4}rem 0 0 0`
187
+ styleName: "border-top-left-radius",
188
+ valueFormat: l.Value.rem
189
189
  }
190
190
  ],
191
191
  /** The border-top-right-radius CSS property rounds the top-right corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
192
192
  borderRadiusTopRight: [
193
193
  {
194
194
  values: 0,
195
- styleName: "border-radius",
196
- valueFormat: (e) => `0 ${e / 4}rem 0 0`
195
+ styleName: "border-top-right-radius",
196
+ valueFormat: l.Value.rem
197
197
  }
198
198
  ],
199
199
  /** The border-bottom-right-radius CSS property rounds the bottom-right corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
200
200
  borderRadiusBottomRight: [
201
201
  {
202
202
  values: 0,
203
- styleName: "border-radius",
204
- valueFormat: (e) => `0 0 ${e / 4}rem 0`
203
+ styleName: "border-bottom-right-radius",
204
+ valueFormat: l.Value.rem
205
205
  }
206
206
  ],
207
207
  /** The border-bottom-left-radius CSS property rounds the bottom-left corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner. */
208
208
  borderRadiusBottomLeft: [
209
209
  {
210
210
  values: 0,
211
- styleName: "border-radius",
212
- valueFormat: (e) => `0 0 0 ${e / 4}rem`
211
+ styleName: "border-bottom-left-radius",
212
+ valueFormat: l.Value.rem
213
213
  }
214
214
  ],
215
215
  /** The position CSS property sets how an element is positioned in a document. The top, right, bottom, and left properties determine the final location of positioned elements. */
@@ -222,35 +222,35 @@ const A = {
222
222
  top: [
223
223
  {
224
224
  values: 0,
225
- valueFormat: c.Value.rem
225
+ valueFormat: l.Value.rem
226
226
  }
227
227
  ],
228
228
  /** The right CSS property participates in specifying the horizontal position of a positioned element. This inset property has no effect on non-positioned elements. */
229
229
  right: [
230
230
  {
231
231
  values: 0,
232
- valueFormat: c.Value.rem
232
+ valueFormat: l.Value.rem
233
233
  }
234
234
  ],
235
235
  /** The bottom CSS property participates in setting the vertical position of a positioned element. This inset property has no effect on non-positioned elements. */
236
236
  bottom: [
237
237
  {
238
238
  values: 0,
239
- valueFormat: c.Value.rem
239
+ valueFormat: l.Value.rem
240
240
  }
241
241
  ],
242
242
  /** The left CSS property participates in specifying the horizontal position of a positioned element. This inset property has no effect on non-positioned elements. */
243
243
  left: [
244
244
  {
245
245
  values: 0,
246
- valueFormat: c.Value.rem
246
+ valueFormat: l.Value.rem
247
247
  }
248
248
  ],
249
249
  /** The inset CSS property is a shorthand that corresponds to the top, right, bottom, and/or left properties. It has the same multi-value syntax of the margin shorthand. */
250
250
  inset: [
251
251
  {
252
252
  values: 0,
253
- valueFormat: c.Value.rem
253
+ valueFormat: l.Value.rem
254
254
  }
255
255
  ],
256
256
  /** The `box-sizing` CSS property sets how the total width and height of an element is calculated. */
@@ -423,7 +423,7 @@ const A = {
423
423
  {
424
424
  styleName: "font-size",
425
425
  values: 0,
426
- valueFormat: c.Value.px
426
+ valueFormat: l.Value.px
427
427
  },
428
428
  {
429
429
  styleName: "font-size",
@@ -448,7 +448,7 @@ const A = {
448
448
  gap: [
449
449
  {
450
450
  values: 0,
451
- valueFormat: c.Value.rem
451
+ valueFormat: l.Value.rem
452
452
  }
453
453
  ],
454
454
  /** The row-gap CSS property sets the size of the gap (gutter) between an element's rows. */
@@ -456,7 +456,7 @@ const A = {
456
456
  {
457
457
  styleName: "row-gap",
458
458
  values: 0,
459
- valueFormat: c.Value.rem
459
+ valueFormat: l.Value.rem
460
460
  }
461
461
  ],
462
462
  /** The column-gap CSS property sets the size of the gap (gutter) between an element's columns. */
@@ -464,7 +464,7 @@ const A = {
464
464
  {
465
465
  styleName: "column-gap",
466
466
  values: 0,
467
- valueFormat: c.Value.rem
467
+ valueFormat: l.Value.rem
468
468
  }
469
469
  ],
470
470
  /** The order CSS property sets the order to lay out an item in a flex or grid container. Items in a container are sorted by ascending order value and then by their source code order. Items not given an explicit order value are assigned the default value of 0. */
@@ -515,8 +515,8 @@ const A = {
515
515
  "11/12"
516
516
  ],
517
517
  valueFormat: (e) => {
518
- const [t, s] = e.split("/");
519
- return `${+t / +s * 100}%`;
518
+ const [t, a] = e.split("/");
519
+ return `${+t / +a * 100}%`;
520
520
  }
521
521
  },
522
522
  {
@@ -567,8 +567,8 @@ const A = {
567
567
  "11/12"
568
568
  ],
569
569
  valueFormat: (e) => {
570
- const [t, s] = e.split("/");
571
- return `${+t / +s * 100}%`;
570
+ const [t, a] = e.split("/");
571
+ return `${+t / +a * 100}%`;
572
572
  }
573
573
  },
574
574
  {
@@ -620,8 +620,8 @@ const A = {
620
620
  "11/12"
621
621
  ],
622
622
  valueFormat: (e) => {
623
- const [t, s] = e.split("/");
624
- return `${+t / +s * 100}%`;
623
+ const [t, a] = e.split("/");
624
+ return `${+t / +a * 100}%`;
625
625
  }
626
626
  },
627
627
  {
@@ -670,8 +670,8 @@ const A = {
670
670
  "11/12"
671
671
  ],
672
672
  valueFormat: (e) => {
673
- const [t, s] = e.split("/");
674
- return `${+t / +s * 100}%`;
673
+ const [t, a] = e.split("/");
674
+ return `${+t / +a * 100}%`;
675
675
  }
676
676
  },
677
677
  {
@@ -722,8 +722,8 @@ const A = {
722
722
  "11/12"
723
723
  ],
724
724
  valueFormat: (e) => {
725
- const [t, s] = e.split("/");
726
- return `${+t / +s * 100}%`;
725
+ const [t, a] = e.split("/");
726
+ return `${+t / +a * 100}%`;
727
727
  }
728
728
  },
729
729
  {
@@ -775,8 +775,8 @@ const A = {
775
775
  "11/12"
776
776
  ],
777
777
  valueFormat: (e) => {
778
- const [t, s] = e.split("/");
779
- return `${+t / +s * 100}%`;
778
+ const [t, a] = e.split("/");
779
+ return `${+t / +a * 100}%`;
780
780
  }
781
781
  },
782
782
  {
@@ -789,7 +789,7 @@ const A = {
789
789
  {
790
790
  styleName: "letter-spacing",
791
791
  values: 0,
792
- valueFormat: c.Value.px
792
+ valueFormat: l.Value.px
793
793
  }
794
794
  ],
795
795
  /** The line-height CSS property sets the height of a line box in horizontal writing modes. In vertical writing modes, it sets the width of a line box. It's commonly used to set the distance between lines of text. On block-level elements in horizontal writing modes, it specifies the preferred height of line boxes within the element, and on non-replaced inline elements, it specifies the height that is used to calculate line box height. */
@@ -797,7 +797,7 @@ const A = {
797
797
  {
798
798
  styleName: "line-height",
799
799
  values: 0,
800
- valueFormat: c.Value.px
800
+ valueFormat: l.Value.px
801
801
  },
802
802
  {
803
803
  styleName: "line-height",
@@ -817,7 +817,7 @@ const A = {
817
817
  {
818
818
  values: 0,
819
819
  styleName: "margin",
820
- valueFormat: c.Value.rem
820
+ valueFormat: l.Value.rem
821
821
  },
822
822
  {
823
823
  values: ["auto"],
@@ -829,7 +829,7 @@ const A = {
829
829
  {
830
830
  values: 0,
831
831
  styleName: "margin-inline",
832
- valueFormat: c.Value.rem
832
+ valueFormat: l.Value.rem
833
833
  },
834
834
  {
835
835
  values: ["auto"],
@@ -841,7 +841,7 @@ const A = {
841
841
  {
842
842
  values: 0,
843
843
  styleName: "margin-block",
844
- valueFormat: c.Value.rem
844
+ valueFormat: l.Value.rem
845
845
  },
846
846
  {
847
847
  values: ["auto"],
@@ -853,7 +853,7 @@ const A = {
853
853
  {
854
854
  values: 0,
855
855
  styleName: "margin-top",
856
- valueFormat: c.Value.rem
856
+ valueFormat: l.Value.rem
857
857
  },
858
858
  {
859
859
  values: ["auto"],
@@ -865,7 +865,7 @@ const A = {
865
865
  {
866
866
  values: 0,
867
867
  styleName: "margin-right",
868
- valueFormat: c.Value.rem
868
+ valueFormat: l.Value.rem
869
869
  },
870
870
  {
871
871
  values: ["auto"],
@@ -877,7 +877,7 @@ const A = {
877
877
  {
878
878
  values: 0,
879
879
  styleName: "margin-bottom",
880
- valueFormat: c.Value.rem
880
+ valueFormat: l.Value.rem
881
881
  },
882
882
  {
883
883
  values: ["auto"],
@@ -889,7 +889,7 @@ const A = {
889
889
  {
890
890
  values: 0,
891
891
  styleName: "margin-left",
892
- valueFormat: c.Value.rem
892
+ valueFormat: l.Value.rem
893
893
  },
894
894
  {
895
895
  values: ["auto"],
@@ -901,7 +901,7 @@ const A = {
901
901
  {
902
902
  values: 0,
903
903
  styleName: "padding",
904
- valueFormat: c.Value.rem
904
+ valueFormat: l.Value.rem
905
905
  }
906
906
  ],
907
907
  /** The padding-inline CSS shorthand property defines the logical inline start and end padding of an element, which maps to physical padding properties depending on the element's writing mode, directionality, and text orientation. */
@@ -909,7 +909,7 @@ const A = {
909
909
  {
910
910
  values: 0,
911
911
  styleName: "padding-inline",
912
- valueFormat: c.Value.rem
912
+ valueFormat: l.Value.rem
913
913
  }
914
914
  ],
915
915
  /** The padding-block CSS shorthand property defines the logical block start and end padding of an element, which maps to physical padding properties depending on the element's writing mode, directionality, and text orientation. */
@@ -917,7 +917,7 @@ const A = {
917
917
  {
918
918
  values: 0,
919
919
  styleName: "padding-block",
920
- valueFormat: c.Value.rem
920
+ valueFormat: l.Value.rem
921
921
  }
922
922
  ],
923
923
  /** The padding-top CSS property sets the height of the padding area on the top of an element. */
@@ -925,7 +925,7 @@ const A = {
925
925
  {
926
926
  values: 0,
927
927
  styleName: "padding-top",
928
- valueFormat: c.Value.rem
928
+ valueFormat: l.Value.rem
929
929
  }
930
930
  ],
931
931
  /** The padding-right CSS property sets the width of the padding area on the right of an element. */
@@ -933,7 +933,7 @@ const A = {
933
933
  {
934
934
  values: 0,
935
935
  styleName: "padding-right",
936
- valueFormat: c.Value.rem
936
+ valueFormat: l.Value.rem
937
937
  }
938
938
  ],
939
939
  /** The padding-bottom CSS property sets the height of the padding area on the bottom of an element. */
@@ -941,7 +941,7 @@ const A = {
941
941
  {
942
942
  values: 0,
943
943
  styleName: "padding-bottom",
944
- valueFormat: c.Value.rem
944
+ valueFormat: l.Value.rem
945
945
  }
946
946
  ],
947
947
  /** The padding-left CSS property sets the width of the padding area to the left of an element. */
@@ -949,7 +949,7 @@ const A = {
949
949
  {
950
950
  values: 0,
951
951
  styleName: "padding-left",
952
- valueFormat: c.Value.rem
952
+ valueFormat: l.Value.rem
953
953
  }
954
954
  ],
955
955
  /** The object-fit CSS property sets how the content of a replaced element, such as an <img> or <video>, should be resized to fit its container. */
@@ -970,7 +970,7 @@ const A = {
970
970
  {
971
971
  styleName: "outline-width",
972
972
  values: 0,
973
- valueFormat: c.Value.px
973
+ valueFormat: l.Value.px
974
974
  }
975
975
  ],
976
976
  /** The outline-style CSS property sets the style of an element's outline. An outline is a line that is drawn around an element, outside the border. */
@@ -985,7 +985,7 @@ const A = {
985
985
  {
986
986
  styleName: "outline-offset",
987
987
  values: 0,
988
- valueFormat: c.Value.px
988
+ valueFormat: l.Value.px
989
989
  }
990
990
  ],
991
991
  /** The overflow CSS shorthand property sets the desired behavior when content does not fit in the element's padding box (overflows) in the horizontal and/or vertical direction. */
@@ -1191,7 +1191,7 @@ const A = {
1191
1191
  values: 0
1192
1192
  }
1193
1193
  ]
1194
- }, se = {
1194
+ }, ae = {
1195
1195
  hover: ":hover",
1196
1196
  focus: ":focus-within",
1197
1197
  hasFocus: ":has(:focus)",
@@ -1204,61 +1204,62 @@ const A = {
1204
1204
  hasChecked: ":has(:checked)",
1205
1205
  hasRequired: ":has(:required)",
1206
1206
  hasDisabled: ":has([disabled])"
1207
- }, B = {
1207
+ }, G = {
1208
1208
  indeterminate: ":indeterminate",
1209
1209
  checked: ":checked",
1210
1210
  required: ":required",
1211
1211
  disabled: "[disabled]"
1212
- }, Y = { ...se, ...B }, ae = Object.entries(Y).reduce(
1213
- (e, [t], s) => (e[t] = Math.pow(2, s), e),
1212
+ }, J = { ...ae, ...G }, se = Object.entries(J).reduce(
1213
+ (e, [t], a) => (e[t] = Math.pow(2, a), e),
1214
1214
  {}
1215
- ), q = Object.entries(Y).reduce(
1215
+ ), K = Object.entries(J).reduce(
1216
1216
  (e, [t]) => {
1217
- const s = ae[t];
1218
- return Object.entries(e).forEach(([u, m]) => {
1219
- e[+u + s] = [...m, t];
1217
+ const a = se[t];
1218
+ return Object.entries(e).forEach(([m, c]) => {
1219
+ e[+m + a] = [...c, t];
1220
1220
  }), e;
1221
1221
  },
1222
1222
  { 0: [] }
1223
- ), K = {
1223
+ ), L = {
1224
1224
  hoverGroup: "hover",
1225
1225
  focusGroup: "focus",
1226
- activeGroup: "active"
1227
- }, I = {
1226
+ activeGroup: "active",
1227
+ disabledGroup: "disabled"
1228
+ }, R = {
1228
1229
  sm: 640,
1229
1230
  md: 768,
1230
1231
  lg: 1024,
1231
1232
  xl: 1280,
1232
1233
  xxl: 1536
1233
1234
  };
1234
- var L;
1235
+ var W;
1235
1236
  ((e) => {
1236
- function t(n, d, i) {
1237
+ function t(n, d, u) {
1237
1238
  const v = { ...n }, y = v.props || {};
1238
- return d.forEach((a) => {
1239
- a in v && (y[a] = v[a], delete v[a]);
1240
- }), i && Object.entries(i).forEach(([a, f]) => {
1241
- y[a] = f;
1239
+ return d.forEach((s) => {
1240
+ s in v && (y[s] = v[s], delete v[s]);
1241
+ }), u && Object.entries(u).forEach(([s, f]) => {
1242
+ y[s] = f;
1242
1243
  }), v.props = y, v;
1243
1244
  }
1244
1245
  e.buildProps = t;
1245
- function s(n) {
1246
+ function a(n) {
1246
1247
  return !!n && typeof n == "object";
1247
1248
  }
1248
- e.isObject = s;
1249
- function u(...n) {
1250
- return n.reduce((d, i) => (Object.keys(i).forEach((v) => {
1251
- const y = d[v], a = i[v];
1252
- v in B && typeof a == "boolean" || (v in B && Array.isArray(a) ? d[v] = u(y, a[1] ?? {}) : Array.isArray(y) && Array.isArray(a) ? d[v] = y.concat(...a) : s(y) && s(a) ? d[v] = u(y, a) : d[v] = a);
1249
+ e.isObject = a;
1250
+ function m(...n) {
1251
+ return n.reduce((d, u) => (Object.keys(u).forEach((v) => {
1252
+ const y = d[v], s = u[v];
1253
+ v in G && typeof s == "boolean" || (v in G && Array.isArray(s) ? d[v] = m(y, s[1] ?? {}) : Array.isArray(y) && Array.isArray(s) ? d[v] = y.concat(...s) : a(y) && a(s) ? d[v] = m(y, s) : d[v] = s);
1253
1254
  }), d), {});
1254
1255
  }
1255
- e.mergeDeep = u;
1256
- function m(n, d) {
1256
+ e.mergeDeep = m;
1257
+ function c(n, d) {
1257
1258
  return n in d;
1258
1259
  }
1259
- e.isKeyOf = m;
1260
- })(L || (L = {}));
1261
- const $ = L;
1260
+ e.isKeyOf = c;
1261
+ })(W || (W = {}));
1262
+ const $ = W;
1262
1263
  class me {
1263
1264
  constructor() {
1264
1265
  this._index = 0, this._cache = {};
@@ -1267,149 +1268,149 @@ class me {
1267
1268
  return this._cache[t] || (this._cache[t] = this.getByIndex(this._index++)), this._cache[t];
1268
1269
  }
1269
1270
  getByIndex(t) {
1270
- const { first: s, next: u } = ce, m = t - s.length;
1271
- if (m < 0)
1272
- return s[t];
1273
- const n = Math.floor(m / u.length), d = m - n * u.length;
1274
- return this.getByIndex(n) + u[d];
1271
+ const { first: a, next: m } = ce, c = t - a.length;
1272
+ if (c < 0)
1273
+ return a[t];
1274
+ const n = Math.floor(c / m.length), d = c - n * m.length;
1275
+ return this.getByIndex(n) + m[d];
1275
1276
  }
1276
1277
  }
1277
1278
  const ce = {
1278
1279
  first: "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",
1279
1280
  next: "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
1280
1281
  };
1281
- var W;
1282
+ var U;
1282
1283
  ((e) => {
1283
1284
  let t = "";
1284
- function s(m, n) {
1285
- return t = Object.entries(m).map(([d, i]) => `--${d}: ${i};`).join(""), Object.entries(n).forEach(([d, i]) => {
1286
- A[d] = i;
1285
+ function a(c, n) {
1286
+ return t = Object.entries(c).map(([d, u]) => `--${d}: ${u};`).join(""), Object.entries(n).forEach(([d, u]) => {
1287
+ T[d] = u;
1287
1288
  }), n;
1288
1289
  }
1289
- e.extend = s;
1290
- function u() {
1290
+ e.extend = a;
1291
+ function m() {
1291
1292
  return t;
1292
1293
  }
1293
- e.getVariables = u;
1294
- })(W || (W = {}));
1295
- const de = W;
1296
- var R;
1294
+ e.getVariables = m;
1295
+ })(U || (U = {}));
1296
+ const de = U;
1297
+ var D;
1297
1298
  ((e) => {
1298
1299
  e.components = {};
1299
- })(R || (R = {}));
1300
+ })(D || (D = {}));
1300
1301
  function ve(e) {
1301
- const { clean: t, theme: s, component: u } = e;
1302
- return X(() => {
1302
+ const { clean: t, theme: a, component: m } = e;
1303
+ return Y(() => {
1303
1304
  var n, d;
1304
1305
  if (t) return;
1305
- let m = (n = R.components) == null ? void 0 : n[u];
1306
- if (m)
1307
- return s ? $.mergeDeep(m.styles, ((d = m.themes) == null ? void 0 : d[s]) ?? {}) : m.styles;
1308
- }, [u, t, s]);
1306
+ let c = (n = D.components) == null ? void 0 : n[m];
1307
+ if (c)
1308
+ return a ? $.mergeDeep(c.styles, ((d = c.themes) == null ? void 0 : d[a]) ?? {}) : c.styles;
1309
+ }, [m, t, a]);
1309
1310
  }
1310
1311
  const fe = new me(), he = typeof window < "u" && typeof window.document < "u";
1311
1312
  var te;
1312
- const re = typeof process == "object" && ((te = process.env) == null ? void 0 : te.NODE_ENV) === "test", ye = he && !re ? oe : ie, le = "_b", j = "_s";
1313
- function ge(e, t) {
1313
+ const re = typeof process == "object" && ((te = process.env) == null ? void 0 : te.NODE_ENV) === "test", ye = he && !re ? ne : ie, le = "_b", O = "_s";
1314
+ function be(e, t) {
1314
1315
  ye(_.flush, [e]);
1315
- const s = ve(e);
1316
- return X(() => {
1316
+ const a = ve(e);
1317
+ return Y(() => {
1317
1318
  var n;
1318
- const u = [t ? j : le];
1319
+ const m = [t ? O : le];
1319
1320
  (n = e.props) == null || n.name;
1320
- const m = s ? $.mergeDeep(s, e) : e;
1321
- return _.addClassNames(m, u, []), u;
1322
- }, [e, t, s]);
1321
+ const c = a ? $.mergeDeep(a, e) : e;
1322
+ return _.addClassNames(c, m, []), m;
1323
+ }, [e, t, a]);
1323
1324
  }
1324
1325
  var _;
1325
1326
  ((e) => {
1326
- let t = !0, s = {};
1327
- function u(a, f, p, h, r) {
1328
- Object.entries(a).forEach(([o, l]) => {
1329
- if ($.isKeyOf(o, A))
1330
- d(o, l, f, p, h, r);
1331
- else if ($.isKeyOf(o, se))
1332
- u(l, f, [...p, o], h, r);
1333
- else if ($.isKeyOf(o, B)) {
1334
- if (Array.isArray(l)) {
1335
- const [b, x] = l;
1336
- u(x, f, [...p, o], h, r);
1327
+ let t = !0, a = {};
1328
+ function m(s, f, p, h, r) {
1329
+ Object.entries(s).forEach(([i, o]) => {
1330
+ if ($.isKeyOf(i, T))
1331
+ d(i, o, f, p, h, r);
1332
+ else if ($.isKeyOf(i, ae))
1333
+ m(o, f, [...p, i], h, r);
1334
+ else if ($.isKeyOf(i, G)) {
1335
+ if (Array.isArray(o)) {
1336
+ const [x, N] = o;
1337
+ m(N, f, [...p, i], h, r);
1337
1338
  }
1338
- $.isObject(l) && u(l, f, [...p, o], h, r);
1339
- } else $.isKeyOf(o, I) ? u(l, f, p, o, r) : $.isKeyOf(o, K) && (typeof l == "string" ? f.push(`${K[o]}-${l}`) : Object.entries(l).forEach(([b, x]) => {
1340
- u(x, f, [...p, K[o]], h, b);
1339
+ $.isObject(o) && m(o, f, [...p, i], h, r);
1340
+ } else $.isKeyOf(i, R) ? m(o, f, p, i, r) : $.isKeyOf(i, L) && (typeof o == "string" ? f.push(`${L[i]}-${o}`) : Object.entries(o).forEach(([x, N]) => {
1341
+ m(N, f, [...p, L[i]], h, x);
1341
1342
  }));
1342
1343
  });
1343
1344
  }
1344
- e.addClassNames = u;
1345
- function m() {
1345
+ e.addClassNames = m;
1346
+ function c() {
1346
1347
  if (!t) return;
1347
1348
  console.debug("\x1B[36m%s\x1B[0m", "[react-box]: flush");
1348
- const a = Object.entries(A).reduce((o, [l], b) => (o[l] = b, o), {}), f = `:root{${de.getVariables()}--borderColor: black;--outlineColor: black;--lineHeight: 1.2;--fontSize: 14px;--transitionTime: 0.25s;--svgTransitionTime: 0.3s;}#crono-box {position: absolute;top: 0;left: 0;height: 0;}
1349
+ const s = Object.entries(T).reduce((i, [o], x) => (i[o] = x, i), {}), f = `:root{${de.getVariables()}--borderColor: black;--outlineColor: black;--lineHeight: 1.2;--fontSize: 14px;--transitionTime: 0.25s;--svgTransitionTime: 0.3s;}#crono-box {position: absolute;top: 0;left: 0;height: 0;}
1349
1350
  html{font-size: 16px;font-family: Arial, sans-serif;}
1350
1351
  body{margin: 0;line-height: var(--lineHeight);font-size: var(--fontSize);}
1351
1352
  a,ul{all: unset;}
1352
1353
  .${le}{display: block;border: 0 solid var(--borderColor);outline: 0px solid var(--outlineColor);margin: 0;padding: 0;background-color: initial;transition: all var(--transitionTime);box-sizing: border-box;font-family: inherit;font-size: inherit;}
1353
- .${j}{display: block;border: 0 solid var(--borderColor);outline: 0px solid var(--outlineColor);margin: 0;padding: 0;transition: all var(--svgTransitionTime);}.${j} path,.${j} circle,.${j} rect,.${j} line {transition: all var(--svgTransitionTime);}
1354
- `, p = Object.entries(s);
1354
+ .${O}{display: block;border: 0 solid var(--borderColor);outline: 0px solid var(--outlineColor);margin: 0;padding: 0;transition: all var(--svgTransitionTime);}.${O} path,.${O} circle,.${O} rect,.${O} line {transition: all var(--svgTransitionTime);}
1355
+ `, p = Object.entries(a);
1355
1356
  p.sort(
1356
- ([o], [l]) => (I[o] ?? 0) - (I[l] ?? 0)
1357
+ ([i], [o]) => (R[i] ?? 0) - (R[o] ?? 0)
1357
1358
  );
1358
1359
  const h = p.reduce(
1359
- (o, [l, b]) => (l !== "normal" && o.push(`@media(min-width: ${I[l]}px){`), Object.entries(b).forEach(([x, G]) => {
1360
- const { __parents: J, ...ne } = G, Q = Object.entries(ne);
1361
- Q.sort(([w], [S]) => a[w] - a[S]), Q.forEach(([w, S]) => {
1362
- S.forEach((F) => {
1363
- var C, V;
1364
- const g = A[w].find((z) => Array.isArray(z.values) ? z.values.includes(F) : typeof F == typeof z.values);
1365
- if (!g) return;
1366
- const E = i(w, F, +x, l), Z = g.styleName ?? w, N = ((C = g.valueFormat) == null ? void 0 : C.call(g, F)) ?? F, T = q[+x].map((z) => Y[z]).join(""), D = ((V = g.selector) == null ? void 0 : V.call(g, `.${E}`, T)) ?? `.${E}${T}`;
1367
- o.push(`${D}{${Z}:${N}}`);
1360
+ (i, [o, x]) => (o !== "normal" && i.push(`@media(min-width: ${R[o]}px){`), Object.entries(x).forEach(([N, H]) => {
1361
+ const { __parents: Q, ...oe } = H, Z = Object.entries(oe);
1362
+ Z.sort(([w], [A]) => s[w] - s[A]), Z.forEach(([w, A]) => {
1363
+ A.forEach((V) => {
1364
+ var I, B;
1365
+ const b = T[w].find((F) => Array.isArray(F.values) ? F.values.includes(V) : typeof V == typeof F.values);
1366
+ if (!b) return;
1367
+ const E = u(w, V, +N, o), q = K[+N].map((F) => J[F]).join(""), g = ((I = b.selector) == null ? void 0 : I.call(b, `.${E}`, q)) ?? `.${E}${q}`, C = Array.isArray(b.styleName) ? b.styleName : [b.styleName ?? w], j = ((B = b.valueFormat) == null ? void 0 : B.call(b, V)) ?? V;
1368
+ i.push(`${g}{${C.map((F) => `${F}:${j}`).join(";")}}`);
1368
1369
  });
1369
- }), J && Object.entries(J).forEach(([w, S]) => {
1370
- const F = Object.entries(S);
1371
- F.sort(([O], [g]) => a[O] - a[g]), F.forEach(([O, g]) => {
1372
- g.forEach((E) => {
1370
+ }), Q && Object.entries(Q).forEach(([w, A]) => {
1371
+ const V = Object.entries(A);
1372
+ V.sort(([z], [b]) => s[z] - s[b]), V.forEach(([z, b]) => {
1373
+ b.forEach((E) => {
1373
1374
  var P, k;
1374
- const N = A[O].find((H) => Array.isArray(H.values) ? H.values.includes(E) : typeof E == typeof H.values);
1375
- if (!N) return;
1376
- const T = i(O, E, +x, l, w), D = N.styleName ?? O, C = ((P = N.valueFormat) == null ? void 0 : P.call(N, E)) ?? E, [V] = q[+x], z = ((k = N.selector) == null ? void 0 : k.call(N, `.${V}-${w}:${V} .${T}`, "")) ?? `.${V}-${w}:${V} .${T}`;
1377
- o.push(`${z}{${D}:${C}}`);
1375
+ const g = T[z].find((S) => Array.isArray(S.values) ? S.values.includes(E) : typeof E == typeof S.values);
1376
+ if (!g) return;
1377
+ const C = u(z, E, +N, o, w), [j] = K[+N], I = ((P = g.selector) == null ? void 0 : P.call(g, `.${j}-${w}:${j} .${C}`, "")) ?? `.${j}-${w}:${j} .${C}`, B = Array.isArray(g.styleName) ? g.styleName : [g.styleName ?? z], F = ((k = g.valueFormat) == null ? void 0 : k.call(g, E)) ?? E;
1378
+ i.push(`${I}{${B.map((S) => `${S}:${F}`).join(";")}}`);
1378
1379
  });
1379
1380
  });
1380
1381
  });
1381
- }), l !== "normal" && o.push("}"), o),
1382
+ }), o !== "normal" && i.push("}"), i),
1382
1383
  [f]
1383
1384
  ), r = y();
1384
1385
  r.innerHTML = h.join(""), t = !1;
1385
1386
  }
1386
- e.flush = m;
1387
+ e.flush = c;
1387
1388
  function n() {
1388
- s = {};
1389
+ a = {};
1389
1390
  }
1390
1391
  e.clear = n;
1391
- function d(a, f, p, h, r = "normal", o) {
1392
+ function d(s, f, p, h, r = "normal", i) {
1392
1393
  if (f == null) return;
1393
- const l = h.reduce((x, G) => x + ae[G], 0);
1394
- s[r] ? s[r][l] ? s[r][l][a] || (s[r][l][a] = /* @__PURE__ */ new Set()) : s[r][l] = { [a]: /* @__PURE__ */ new Set() } : s[r] = { [l]: { [a]: /* @__PURE__ */ new Set() } }, o ? (s[r][l].__parents ? s[r][l].__parents[o] ? s[r][l].__parents[o][a] || (s[r][l].__parents[o][a] = /* @__PURE__ */ new Set()) : s[r][l].__parents[o] = { [a]: /* @__PURE__ */ new Set() } : s[r][l].__parents = { [o]: { [a]: /* @__PURE__ */ new Set() } }, s[r][l].__parents[o][a].has(f) || (s[r][l].__parents[o][a].add(f), t = !0)) : s[r][l][a].has(f) || (s[r][l][a].add(f), t = !0);
1395
- const b = i(a, f, l, r, o);
1396
- p.push(b);
1394
+ const o = h.reduce((N, H) => N + se[H], 0);
1395
+ a[r] ? a[r][o] ? a[r][o][s] || (a[r][o][s] = /* @__PURE__ */ new Set()) : a[r][o] = { [s]: /* @__PURE__ */ new Set() } : a[r] = { [o]: { [s]: /* @__PURE__ */ new Set() } }, i ? (a[r][o].__parents ? a[r][o].__parents[i] ? a[r][o].__parents[i][s] || (a[r][o].__parents[i][s] = /* @__PURE__ */ new Set()) : a[r][o].__parents[i] = { [s]: /* @__PURE__ */ new Set() } : a[r][o].__parents = { [i]: { [s]: /* @__PURE__ */ new Set() } }, a[r][o].__parents[i][s].has(f) || (a[r][o].__parents[i][s].add(f), t = !0)) : a[r][o][s].has(f) || (a[r][o][s].add(f), t = !0);
1396
+ const x = u(s, f, o, r, i);
1397
+ p.push(x);
1397
1398
  }
1398
- function i(a, f, p, h, r) {
1399
- const o = q[p], l = `${h === "normal" ? "" : `${h}-`}${o.map((b) => `${b}-`).join("")}${r ? `${r}-` : ""}${a}-${f}`;
1400
- return re ? l : fe.getIdentity(l);
1399
+ function u(s, f, p, h, r) {
1400
+ const i = K[p], o = `${h === "normal" ? "" : `${h}-`}${i.map((x) => `${x}-`).join("")}${r ? `${r}-` : ""}${s}-${f}`;
1401
+ return re ? o : fe.getIdentity(o);
1401
1402
  }
1402
1403
  const v = "crono-styles";
1403
1404
  function y() {
1404
- let a = document.getElementById(v);
1405
- return a || (a = document.createElement("style"), a.setAttribute("id", v), a.setAttribute("type", "text/css"), document.head.insertBefore(a, document.head.firstChild)), a;
1405
+ let s = document.getElementById(v);
1406
+ return s || (s = document.createElement("style"), s.setAttribute("id", v), s.setAttribute("type", "text/css"), document.head.insertBefore(s, document.head.firstChild)), s;
1406
1407
  }
1407
1408
  })(_ || (_ = {}));
1408
1409
  var ee;
1409
1410
  ((e) => {
1410
1411
  e.flush = _.flush, e.clear = _.clear;
1411
1412
  })(ee || (ee = {}));
1412
- var U;
1413
+ var M;
1413
1414
  ((e) => {
1414
1415
  const t = {
1415
1416
  button: {
@@ -1453,59 +1454,59 @@ var U;
1453
1454
  }
1454
1455
  }
1455
1456
  };
1456
- function s(u) {
1457
- const { components: m, ...n } = u, d = m ?? {};
1458
- Object.entries(n).forEach(([i, v]) => {
1459
- d[i] = v;
1460
- }), R.components = $.mergeDeep(t, d);
1457
+ function a(m) {
1458
+ const { components: c, ...n } = m, d = c ?? {};
1459
+ Object.entries(n).forEach(([u, v]) => {
1460
+ d[u] = v;
1461
+ }), D.components = $.mergeDeep(t, d);
1461
1462
  }
1462
- e.setup = s;
1463
- })(U || (U = {}));
1464
- const be = U;
1465
- var M;
1463
+ e.setup = a;
1464
+ })(M || (M = {}));
1465
+ const ge = M;
1466
+ var X;
1466
1467
  ((e) => {
1467
- function t(u) {
1468
- const m = Array.from(u.elements).reduce(
1468
+ function t(m) {
1469
+ const c = Array.from(m.elements).reduce(
1469
1470
  (n, d) => {
1470
- const i = d.name;
1471
- return i && (n[i] || (n[i] = []), n[i].push(d)), n;
1471
+ const u = d.name;
1472
+ return u && (n[u] || (n[u] = []), n[u].push(d)), n;
1472
1473
  },
1473
1474
  {}
1474
1475
  );
1475
- return Object.entries(m).reduce((n, [d, i]) => {
1476
- if (i.length === 1) {
1477
- const v = i[0];
1478
- s(n, d, v.type === "checkbox" || v.type === "radio" ? v.checked : v.value);
1476
+ return Object.entries(c).reduce((n, [d, u]) => {
1477
+ if (u.length === 1) {
1478
+ const v = u[0];
1479
+ a(n, d, v.type === "checkbox" || v.type === "radio" ? v.checked : v.value);
1479
1480
  } else {
1480
- const v = i.reduce((y, a) => (a.type === "checkbox" || a.type === "radio" ? a.checked && y.push(a.value) : y.push(a.value), y), []);
1481
- s(n, d, v);
1481
+ const v = u.reduce((y, s) => (s.type === "checkbox" || s.type === "radio" ? s.checked && y.push(s.value) : y.push(s.value), y), []);
1482
+ a(n, d, v);
1482
1483
  }
1483
1484
  return n;
1484
1485
  }, {});
1485
1486
  }
1486
1487
  e.getFormEntries = t;
1487
- function s(u, m, n) {
1488
- if (m.includes(".")) {
1489
- const d = m.split(".");
1490
- let i = u;
1488
+ function a(m, c, n) {
1489
+ if (c.includes(".")) {
1490
+ const d = c.split(".");
1491
+ let u = m;
1491
1492
  d.forEach((v, y) => {
1492
1493
  if (d.length > y + 1) {
1493
- const a = v.match(/^(.+)\[(\d)\]$/);
1494
- if (a) {
1495
- const [, f, p] = a;
1496
- i[f] = i[f] || [], i[f][p] = i[f][p] || {}, i = i[f][p];
1494
+ const s = v.match(/^(.+)\[(\d)\]$/);
1495
+ if (s) {
1496
+ const [, f, p] = s;
1497
+ u[f] = u[f] || [], u[f][p] = u[f][p] || {}, u = u[f][p];
1497
1498
  } else
1498
- i[v] = i[v] || {}, i = i[v];
1499
+ u[v] = u[v] || {}, u = u[v];
1499
1500
  } else
1500
- i[v] = n;
1501
+ u[v] = n;
1501
1502
  });
1502
1503
  } else
1503
- u[m] = n;
1504
+ m[c] = n;
1504
1505
  }
1505
- })(M || (M = {}));
1506
- const xe = M;
1506
+ })(X || (X = {}));
1507
+ const xe = X;
1507
1508
  function Ne() {
1508
- return X(() => {
1509
+ return Y(() => {
1509
1510
  const e = "crono-box";
1510
1511
  let t = document.getElementById(e);
1511
1512
  return t || (t = document.createElement("div"), t.id = e, document.body.appendChild(t)), t;
@@ -1516,8 +1517,8 @@ export {
1516
1517
  xe as F,
1517
1518
  $ as O,
1518
1519
  ee as S,
1519
- be as T,
1520
+ ge as T,
1520
1521
  Ne as a,
1521
1522
  ue as c,
1522
- ge as u
1523
+ be as u
1523
1524
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cronocode/react-box",
3
- "version": "3.0.0-alpha.4",
3
+ "version": "3.0.0-alpha.6",
4
4
  "type": "module",
5
5
  "main": "./box.cjs",
6
6
  "module": "./box.mjs",