@cronocode/react-box 1.8.5 → 1.8.7

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.
@@ -1 +1 @@
1
- "use strict";const u=require("react/jsx-runtime"),c=require("react"),i=require("../box.cjs"),s=require("../utils.cjs");require("../core.cjs");const a=["name","onInput","onChange","autoFocus","readOnly","required","value","checked","defaultChecked"];function l(o,e){const{indeterminate:n}=o,r=s.ObjectUtils.buildProps(o,a,{type:"checkbox"}),t=c.useRef(null);return c.useEffect(()=>{e&&typeof e!="function"&&e.current?e.current.indeterminate=!!n:t.current&&(t.current.indeterminate=!!n)},[e,t,n]),u.jsx(i,{tag:"input",ref:e||t,component:"checkbox",...r})}const d=c.forwardRef(l);module.exports=d;
1
+ "use strict";const u=require("react/jsx-runtime"),t=require("react"),s=require("../box.cjs"),i=require("../utils.cjs");require("../core.cjs");const a=["name","onInput","onChange","autoFocus","readOnly","required","value","checked","defaultChecked"];function d(n,c){const{indeterminate:r}=n,o=i.ObjectUtils.buildProps(n,a,{type:"checkbox"}),e=t.useRef(null);return t.useImperativeHandle(c,()=>e.current),t.useEffect(()=>{e.current&&(e.current.indeterminate=!!r)},[e,r]),u.jsx(s,{tag:"input",ref:e,component:"checkbox",...o})}const f=t.forwardRef(d);module.exports=f;
@@ -1,16 +1,16 @@
1
- import { jsx as r } from "react/jsx-runtime";
2
- import { forwardRef as i, useRef as u, useEffect as a } from "react";
1
+ import { jsx as c } from "react/jsx-runtime";
2
+ import { forwardRef as u, useRef as a, useImperativeHandle as i, useEffect as f } from "react";
3
3
  import s from "../box.mjs";
4
4
  import { O as m } from "../utils.mjs";
5
5
  import "../core.mjs";
6
- const f = ["name", "onInput", "onChange", "autoFocus", "readOnly", "required", "value", "checked", "defaultChecked"];
7
- function p(n, e) {
8
- const { indeterminate: t } = n, c = m.buildProps(n, f, { type: "checkbox" }), o = u(null);
9
- return a(() => {
10
- e && typeof e != "function" && e.current ? e.current.indeterminate = !!t : o.current && (o.current.indeterminate = !!t);
11
- }, [e, o, t]), /* @__PURE__ */ r(s, { tag: "input", ref: e || o, component: "checkbox", ...c });
6
+ const p = ["name", "onInput", "onChange", "autoFocus", "readOnly", "required", "value", "checked", "defaultChecked"];
7
+ function d(o, r) {
8
+ const { indeterminate: t } = o, n = m.buildProps(o, p, { type: "checkbox" }), e = a(null);
9
+ return i(r, () => e.current), f(() => {
10
+ e.current && (e.current.indeterminate = !!t);
11
+ }, [e, t]), /* @__PURE__ */ c(s, { tag: "input", ref: e, component: "checkbox", ...n });
12
12
  }
13
- const k = i(p);
13
+ const g = u(d);
14
14
  export {
15
- k as default
15
+ g as default
16
16
  };
@@ -1,13 +1,11 @@
1
1
  import { BoxStylesFormatters } from './boxStylesFormatters';
2
2
  export interface StyleValues {
3
3
  values: Readonly<Array<unknown>>;
4
- formatClassName?: (key: string, value: any) => string;
5
4
  formatSelector?: (selector: string) => string[];
6
5
  formatValue?: (key: string, value: any) => string;
7
6
  }
8
7
  export interface ThemeItem {
9
8
  cssNames: string[];
10
- formatClassName?: (key: string, value: any) => string;
11
9
  formatSelector?: (selector: string) => string[];
12
10
  formatValue?: (key: string, value: any) => string;
13
11
  }
@@ -17,6 +15,7 @@ export interface StyleItem {
17
15
  values2: StyleValues;
18
16
  values3: StyleValues;
19
17
  pseudoSuffix?: PseudoClassSuffix;
18
+ breakpoint?: BoxBreakpointsType;
20
19
  isThemeStyle?: boolean;
21
20
  }
22
21
  export declare const boxStyles: {
@@ -38,6 +37,7 @@ export declare const boxStyles: {
38
37
  cssNames: string[];
39
38
  values1: {
40
39
  values: readonly [true];
40
+ formatValue: () => string;
41
41
  };
42
42
  values2: {
43
43
  values: readonly [];
@@ -1217,6 +1217,9 @@ export declare const svgThemeStyles: {
1217
1217
  };
1218
1218
  export declare const pseudoClassSuffixesExtended: readonly ["H", "F", "A", "Checked", "Indeterminate", "Valid", "Invalid", "Required", "Optional", "Disabled"];
1219
1219
  export type PseudoClassSuffix = (typeof pseudoClassSuffixesExtended)[number];
1220
+ export declare const boxBreakpoints: readonly ["sm", "md", "lg", "xl", "xxl"];
1221
+ export type BoxBreakpointsType = (typeof boxBreakpoints)[number];
1222
+ export declare const boxBreakpointsMinWidth: Record<BoxBreakpointsType, number>;
1220
1223
  export declare const pseudoClassClassName: {
1221
1224
  hover: {
1222
1225
  className: string;
@@ -1,8 +1,9 @@
1
+ import { BoxBreakpointsType } from './boxStyles';
1
2
  declare namespace StylesContext {
2
3
  const boxClassName = "_box";
3
4
  const svgClassName = "_svg";
4
5
  const cronoStylesElementId = "crono-styles";
5
- function get(key: string, value: unknown): string | undefined;
6
+ function get(key: string, value: unknown, breakpoint?: BoxBreakpointsType): string | undefined;
6
7
  function flush(): void;
7
8
  function clear(): void;
8
9
  }
package/core/theme.d.ts CHANGED
@@ -1,11 +1,10 @@
1
- import { BoxStyleProps } from './types';
2
- import { BoxThemeProps } from './types';
1
+ import { BoxStyleProps, BoxThemeProps } from './types';
3
2
  export interface ThemeStyles<T> {
4
3
  styles: T;
5
4
  }
6
5
  export interface ThemeComponentStyles<T = BoxStyleProps> extends ThemeStyles<T> {
7
6
  themes?: {
8
- [name: string]: ThemeStyles<T>;
7
+ [name: string]: T;
9
8
  };
10
9
  children?: {
11
10
  [name: string]: ThemeComponentStyles<T>;
@@ -22,10 +21,10 @@ export interface ThemeSetup<T = BoxStyleProps> {
22
21
  radioButton?: ThemeComponentStyles<T>;
23
22
  }
24
23
  interface BoxAugmentedProps {
25
- colors: Record<string, string>;
26
- shadows: Record<string, string>;
27
- backgrounds: Record<string, string>;
28
- backgroundImages: Record<string, string>;
24
+ colors?: Record<string, string>;
25
+ shadows?: Record<string, string>;
26
+ backgrounds?: Record<string, string>;
27
+ backgroundImages?: Record<string, string>;
29
28
  }
30
29
  declare namespace Theme {
31
30
  let Styles: ThemeSetup<BoxStyleProps>;
package/core/types.d.ts CHANGED
@@ -13,7 +13,7 @@ type BoxStyles<T extends Record<string, StyleItem>> = {
13
13
  [K in keyof T]?: T[K]['values1']['values'][number] | T[K]['values2']['values'][number] | T[K]['values3']['values'][number];
14
14
  };
15
15
  type BoxNormalStyles = BoxStyles<typeof boxStyles> & Augmented.BoxProps;
16
- interface BoxPseudoClasses2 {
16
+ interface BoxPseudoClasses {
17
17
  disabled?: boolean | [boolean, BoxNormalStyles];
18
18
  hover?: boolean | [boolean, BoxNormalStyles] | BoxNormalStyles;
19
19
  focus?: boolean | [boolean, BoxNormalStyles] | BoxNormalStyles;
@@ -27,12 +27,20 @@ interface BoxThemePseudoClassProps {
27
27
  indeterminate?: BoxNormalStyles;
28
28
  checked?: BoxNormalStyles;
29
29
  }
30
- export type BoxThemeProps = BoxNormalStyles & BoxThemePseudoClassProps;
31
- export type BoxStyleProps = BoxNormalStyles & BoxPseudoClasses2 & ThemeComponentProps;
30
+ export interface BoxBreakpoints<T = BoxThemeProps> {
31
+ sm?: T;
32
+ md?: T;
33
+ lg?: T;
34
+ xl?: T;
35
+ xxl?: T;
36
+ }
37
+ export type BoxThemeProps = BoxNormalStyles & BoxThemePseudoClassProps & BoxBreakpoints;
38
+ export type BoxStyleProps = BoxNormalStyles & BoxPseudoClasses & ThemeComponentProps & BoxBreakpoints<BoxStyleProps>;
32
39
  interface SvgNormalStyles {
33
40
  rotate?: BoxNormalStyles['rotate'];
34
41
  flip?: BoxNormalStyles['flip'];
35
42
  transitionDuration?: BoxNormalStyles['transitionDuration'];
43
+ hover?: boolean | [boolean, BoxNormalStyles];
36
44
  }
37
45
  export type BoxSvgStyles = SvgNormalStyles & ThemeComponentProps & Augmented.SvgProps;
38
46
  export {};
package/core.cjs CHANGED
@@ -1,20 +1,20 @@
1
- "use strict";const S=require("react"),_=require("./utils.cjs");var e;(u=>{(r=>{function c(l,v){return`${l}${v.replace("/","-")}`}r.fraction=c;function h(l){return[`${l} path`,`${l} circle`,`${l} rect`,`${l} line`]}r.svg=h})(u.ClassName||(u.ClassName={})),(r=>{function c(a,s){return`${s/4}rem`}r.rem=c;function h(a,s){return`${s}px`}r.px=h;function l(a,s){const[t,N]=s.split("/");return`${+t/+N*100}%`}r.fraction=l;function v(a,s){switch(s){case"fit":return"100%";case"fit-screen":return a.toLocaleLowerCase().includes("height")?"100vh":"100vw";default:return s}}r.widthHeight=v;function m(a){return(s,t)=>`var(--${a}${t});`}r.variables=m;function C(a){return(s,t)=>`var(--${a}${t});`}r.svgVariables=C;function i(a,s){return`repeat(${s},minmax(0,1fr))`}r.gridColumns=i;function g(a,s){return s==="full-row"?"1/-1":`span ${s}/span ${s}`}r.gridColumn=g;function f(a,s){return`${s}ms`}r.ms=f;function b(a,s){return`${s}deg`}r.rotate=b;function V(a,s){return s==="xAxis"?"-1 1":"1 -1"}r.flip=V})(u.Value||(u.Value={}))})(e||(e={}));const n=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,64,68,72,76,80,84,88,92,96,100,120,140,160,180,200,250,300],U=[-1,-2,-3,-4,-5,-6,-7,-8,-9,-10,-11,-12,-13,-14,-15,-16,-17,-18,-19,-20,-22,-24,-26,-28,-30,-32,-34,-36,-38,-40,-44,-48,-52,-56,-60,-64,-68,-72,-76,-80,-84,-88,-92,-96,-100],d=[...n,...U],q=["solid","dashed","dotted","double","groove","ridge","inset","outset","none","hidden"],E=["auto","hidden","scroll","visible"],k=["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"],j=["fit","fit-screen","auto","fit-content","max-content","min-content"],D=["auto","flex-start","flex-end","center","baseline","stretch"],x={display:{cssNames:["display"],values1:{values:["none","block","inline-block","flex","inline-flex","grid","inline-grid","contents"]},values2:{values:[]},values3:{values:[]}},inline:{cssNames:["display"],values1:{values:[!0]},values2:{values:[]},values3:{values:[]}},boxSizing:{cssNames:["box-sizing"],values1:{values:["border-box","content-box"]},values2:{values:[]},values3:{values:[]}},width:{cssNames:["width"],values1:{values:j,formatValue:e.Value.widthHeight},values2:{values:n,formatValue:e.Value.rem},values3:{values:k,formatValue:e.Value.fraction}},minWidth:{cssNames:["min-width"],values1:{values:j,formatValue:e.Value.widthHeight},values2:{values:n,formatValue:e.Value.rem},values3:{values:k,formatValue:e.Value.fraction}},maxWidth:{cssNames:["max-width"],values1:{values:j,formatValue:e.Value.widthHeight},values2:{values:n,formatValue:e.Value.rem},values3:{values:k,formatValue:e.Value.fraction}},height:{cssNames:["height"],values1:{values:j,formatValue:e.Value.widthHeight},values2:{values:n,formatValue:e.Value.rem},values3:{values:k,formatValue:e.Value.fraction}},minHeight:{cssNames:["min-height"],values1:{values:j,formatValue:e.Value.widthHeight},values2:{values:n,formatValue:e.Value.rem},values3:{values:k,formatValue:e.Value.fraction}},maxHeight:{cssNames:["max-height"],values1:{values:j,formatValue:e.Value.widthHeight},values2:{values:n,formatValue:e.Value.rem},values3:{values:k,formatValue:e.Value.fraction}},position:{cssNames:["position"],values1:{values:["static","relative","absolute","fixed","sticky"]},values2:{values:[]},values3:{values:[]}},top:{cssNames:["top"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},right:{cssNames:["right"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},bottom:{cssNames:["bottom"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},left:{cssNames:["left"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},inset:{cssNames:["inset"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},m:{cssNames:["margin"],values1:{values:d,formatValue:e.Value.rem},values2:{values:["auto"]},values3:{values:[]}},mx:{cssNames:["margin-inline"],values1:{values:d,formatValue:e.Value.rem},values2:{values:["auto"]},values3:{values:[]}},my:{cssNames:["margin-block"],values1:{values:d,formatValue:e.Value.rem},values2:{values:["auto"]},values3:{values:[]}},mt:{cssNames:["margin-top"],values1:{values:d,formatValue:e.Value.rem},values2:{values:["auto"]},values3:{values:[]}},mr:{cssNames:["margin-right"],values1:{values:d,formatValue:e.Value.rem},values2:{values:["auto"]},values3:{values:[]}},mb:{cssNames:["margin-bottom"],values1:{values:d,formatValue:e.Value.rem},values2:{values:["auto"]},values3:{values:[]}},ml:{cssNames:["margin-left"],values1:{values:d,formatValue:e.Value.rem},values2:{values:["auto"]},values3:{values:[]}},p:{cssNames:["padding"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},px:{cssNames:["padding-inline"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},py:{cssNames:["padding-block"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},pt:{cssNames:["padding-top"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},pr:{cssNames:["padding-right"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},pb:{cssNames:["padding-bottom"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},pl:{cssNames:["padding-left"],values1:{values:d,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},b:{cssNames:["border-width"],values1:{values:n,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},bx:{cssNames:["border-inline-width"],values1:{values:d,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},by:{cssNames:["border-block-width"],values1:{values:d,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},bt:{cssNames:["border-top-width"],values1:{values:d,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},br:{cssNames:["border-right-width"],values1:{values:d,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},bb:{cssNames:["border-bottom-width"],values1:{values:d,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},bl:{cssNames:["border-left-width"],values1:{values:d,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},borderStyle:{cssNames:["border-style"],values1:{values:q},values2:{values:[]},values3:{values:[]}},borderRadius:{cssNames:["border-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusTop:{cssNames:["border-top-left-radius","border-top-right-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusRight:{cssNames:["border-top-right-radius","border-bottom-right-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusBottom:{cssNames:["border-bottom-left-radius","border-bottom-right-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusLeft:{cssNames:["border-top-left-radius","border-bottom-left-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusTopLeft:{cssNames:["border-top-left-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusTopRight:{cssNames:["border-top-right-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusBottomLeft:{cssNames:["border-bottom-left-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusBottomRight:{cssNames:["border-bottom-right-radius"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},cursor:{cssNames:["cursor"],values1:{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"]},values2:{values:[]},values3:{values:[]}},zIndex:{cssNames:["z-index"],values1:{values:[1,2,3,4,5,10,11,12,13,14,15,100,101,102,103,104,105,1e3,1001,1002,1003,1004,1005]},values2:{values:[]},values3:{values:[]}},overflow:{cssNames:["overflow"],values1:{values:E},values2:{values:[]},values3:{values:[]}},overflowX:{cssNames:["overflow-x"],values1:{values:E},values2:{values:[]},values3:{values:[]}},overflowY:{cssNames:["overflow-y"],values1:{values:E},values2:{values:[]},values3:{values:[]}},opacity:{cssNames:["opacity"],values1:{values:[0,.1,.2,.3,.4,.5,.6,.7,.8,.9,1]},values2:{values:[]},values3:{values:[]}},fontSize:{cssNames:["font-size"],values1:{values:n,formatValue:e.Value.px},values2:{values:["inherit"]},values3:{values:[]}},fontStyle:{cssNames:["font-style"],values1:{values:["italic","normal","oblique"]},values2:{values:[]},values3:{values:[]}},fontWeight:{cssNames:["font-weight"],values1:{values:[100,200,300,400,500,600,700,800,900]},values2:{values:[]},values3:{values:[]}},letterSpacing:{cssNames:["letter-spacing"],values1:{values:n,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},lineHeight:{cssNames:["line-height"],values1:{values:n,formatValue:e.Value.px},values2:{values:["font-size"],formatValue:()=>"1"},values3:{values:[]}},textDecoration:{cssNames:["text-decoration"],values1:{values:["none","underline","overline","line-through"]},values2:{values:[]},values3:{values:[]}},textTransform:{cssNames:["text-transform"],values1:{values:["none","capitalize","lowercase","uppercase"]},values2:{values:[]},values3:{values:[]}},textAlign:{cssNames:["text-align"],values1:{values:["left","right","center","justify"]},values2:{values:[]},values3:{values:[]}},flexWrap:{cssNames:["flex-wrap"],values1:{values:["nowrap","wrap","wrap-reverse"]},values2:{values:[]},values3:{values:[]}},jc:{cssNames:["justify-content"],values1:{values:["start","end","flex-start","flex-end","center","left","right","space-between","space-around","space-evenly","stretch"]},values2:{values:[]},values3:{values:[]}},ai:{cssNames:["align-items"],values1:{values:["stretch","flex-start","flex-end","center","baseline","start","end","self-start","self-end"]},values2:{values:[]},values3:{values:[]}},alignContent:{cssNames:["align-content"],values1:{values:["flex-start","flex-end","center","space-between","space-around","space-evenly","stretch","start","end","baseline"]},values2:{values:[]},values3:{values:[]}},flex1:{cssNames:["flex"],values1:{values:[!0],formatValue:()=>"1"},values2:{values:[]},values3:{values:[]}},d:{cssNames:["flex-direction"],values1:{values:["row","row-reverse","column","column-reverse"]},values2:{values:[]},values3:{values:[]}},gap:{cssNames:["gap"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},rowGap:{cssNames:["row-gap"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},columnGap:{cssNames:["column-gap"],values1:{values:n,formatValue:e.Value.rem},values2:{values:[]},values3:{values:[]}},order:{cssNames:["order"],values1:{values:n},values2:{values:[]},values3:{values:[]}},flexGrow:{cssNames:["flex-grow"],values1:{values:n},values2:{values:[]},values3:{values:[]}},flexShrink:{cssNames:["flex-shrink"],values1:{values:n},values2:{values:[]},values3:{values:[]}},alignSelf:{cssNames:["align-self"],values1:{values:D},values2:{values:[]},values3:{values:[]}},justifySelf:{cssNames:["justify-self"],values1:{values:D},values2:{values:[]},values3:{values:[]}},gridColumns:{cssNames:["grid-template-columns"],values1:{values:n,formatValue:e.Value.gridColumns},values2:{values:[]},values3:{values:[]}},colSpan:{cssNames:["grid-column"],values1:{values:n,formatValue:e.Value.gridColumn},values2:{values:["full-row"],formatValue:e.Value.gridColumn},values3:{values:[]}},colStart:{cssNames:["grid-column-start"],values1:{values:n},values2:{values:[]},values3:{values:[]}},colEnd:{cssNames:["grid-column-end"],values1:{values:n},values2:{values:[]},values3:{values:[]}},outline:{cssNames:["outline-width"],values1:{values:n,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},outlineStyle:{cssNames:["outline-style"],values1:{values:q},values2:{values:[]},values3:{values:[]}},outlineOffset:{cssNames:["outline-offset"],values1:{values:n,formatValue:e.Value.px},values2:{values:[]},values3:{values:[]}},transition:{cssNames:["transition-property"],values1:{values:["none","all"]},values2:{values:[]},values3:{values:[]}},transitionDuration:{cssNames:["transition-duration"],values1:{values:[50,100,150,200,250,300,350,400,450,500,550,600,650,700,750,800,850,900,950,1e3],formatValue:e.Value.ms},values2:{values:[]},values3:{values:[]}},userSelect:{cssNames:["user-select"],values1:{values:["none","auto","text","all"]},values2:{values:[]},values3:{values:[]}},appearance:{cssNames:["appearance"],values1:{values:["none"]},values2:{values:[]},values3:{values:[]}},pointerEvents:{cssNames:["pointer-events"],values1:{values:["none","auto","all"]},values2:{values:[]},values3:{values:[]}},whiteSpace:{cssNames:["white-space"],values1:{values:["break-spaces","normal","nowrap","pre","pre-line","pre-wrap"]},values2:{values:[]},values3:{values:[]}},textOverflow:{cssNames:["text-overflow"],values1:{values:["clip","ellipsis"]},values2:{values:[]},values3:{values:[]}},rotate:{cssNames:["rotate"],values1:{values:[0,90,180,270,-90,-180,-270],formatValue:e.Value.rotate},values2:{values:[]},values3:{values:[]}},flip:{cssNames:["scale"],values1:{values:["xAxis","yAxis"],formatValue:e.Value.flip},values2:{values:[]},values3:{values:[]}}},L={shadow:{cssNames:["box-shadow"],formatValue:e.Value.variables("shadow")},background:{cssNames:["background"],formatValue:e.Value.variables("background")},backgroundImage:{cssNames:["background-image"],formatValue:e.Value.variables("backgroundImage")},color:{cssNames:["color"],formatValue:e.Value.variables("color")},bgColor:{cssNames:["background-color"],formatValue:e.Value.variables("color")},borderColor:{cssNames:["border-color"],formatValue:e.Value.variables("color")},outlineColor:{cssNames:["outline-color"],formatValue:e.Value.variables("color")}},P={fill:{cssNames:["fill"],formatValue:e.Value.svgVariables("color"),formatSelector:e.ClassName.svg},stroke:{cssNames:["stroke"],formatValue:e.Value.svgVariables("color"),formatSelector:e.ClassName.svg}},X=["H","F","A","Checked","Indeterminate","Valid","Invalid","Required","Optional","Disabled"],O={hover:{className:"_h"},focus:{className:"_f"}};Object.keys(L).forEach(u=>{x[u]=L[u],x[u].isThemeStyle=!0});Object.keys(P).forEach(u=>{x[u]=P[u],x[u].isThemeStyle=!0});const Y=Object.keys(x);X.forEach(u=>{Y.forEach(r=>{x[`${r}${u}`]={...x[r],pseudoSuffix:u}})});class J{constructor(){this._index=0,this._cache={}}getIdentity(r){return this._cache[r]||(this._cache[r]=this.getByIndex(this._index++)),this._cache[r]}getByIndex(r){const{first:c,next:h}=Q,l=r-c.length;if(l<0)return c[r];const v=Math.floor(l/h.length),m=l-v*h.length;return this.getByIndex(v)+h[m]}}const Q={first:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",next:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"};var A;(u=>{u.boxClassName="_box",u.svgClassName="_svg",u.cronoStylesElementId="crono-styles";const r=`:root{--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 B=require("react"),Q=require("./utils.cjs");var s;(l=>{(u=>{function i(o,h){return`${o}${h.replace("/","-")}`}u.fraction=i;function m(o){return[`${o} path`,`${o} circle`,`${o} rect`,`${o} line`]}u.svg=m})(l.ClassName||(l.ClassName={})),(u=>{function i(e,a){return`${a/4}rem`}u.rem=i;function m(e,a){return`${a}px`}u.px=m;function o(e,a){const[t,v]=a.split("/");return`${+t/+v*100}%`}u.fraction=o;function h(e,a){switch(a){case"fit":return"100%";case"fit-screen":return e.toLocaleLowerCase().includes("height")?"100vh":"100vw";default:return a}}u.widthHeight=h;function V(e){return(a,t)=>`var(--${e}${t});`}u.variables=V;function T(e){return(a,t)=>`var(--${e}${t});`}u.svgVariables=T;function C(e,a){return`repeat(${a},minmax(0,1fr))`}u.gridColumns=C;function c(e,a){return a==="full-row"?"1/-1":`span ${a}/span ${a}`}u.gridColumn=c;function r(e,a){return`${a}ms`}u.ms=r;function b(e,a){return`${a}deg`}u.rotate=b;function f(e,a){return a==="xAxis"?"-1 1":"1 -1"}u.flip=f})(l.Value||(l.Value={}))})(s||(s={}));const n=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,64,68,72,76,80,84,88,92,96,100,120,140,160,180,200,250,300],Z=[-1,-2,-3,-4,-5,-6,-7,-8,-9,-10,-11,-12,-13,-14,-15,-16,-17,-18,-19,-20,-22,-24,-26,-28,-30,-32,-34,-36,-38,-40,-44,-48,-52,-56,-60,-64,-68,-72,-76,-80,-84,-88,-92,-96,-100],d=[...n,...Z],M=["solid","dashed","dotted","double","groove","ridge","inset","outset","none","hidden"],_=["auto","hidden","scroll","visible"],S=["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"],z=["fit","fit-screen","auto","fit-content","max-content","min-content"],G=["auto","flex-start","flex-end","center","baseline","stretch"],N={display:{cssNames:["display"],values1:{values:["none","block","inline-block","flex","inline-flex","grid","inline-grid","contents"]},values2:{values:[]},values3:{values:[]}},inline:{cssNames:["display"],values1:{values:[!0],formatValue:()=>"inline-block"},values2:{values:[]},values3:{values:[]}},boxSizing:{cssNames:["box-sizing"],values1:{values:["border-box","content-box"]},values2:{values:[]},values3:{values:[]}},width:{cssNames:["width"],values1:{values:z,formatValue:s.Value.widthHeight},values2:{values:n,formatValue:s.Value.rem},values3:{values:S,formatValue:s.Value.fraction}},minWidth:{cssNames:["min-width"],values1:{values:z,formatValue:s.Value.widthHeight},values2:{values:n,formatValue:s.Value.rem},values3:{values:S,formatValue:s.Value.fraction}},maxWidth:{cssNames:["max-width"],values1:{values:z,formatValue:s.Value.widthHeight},values2:{values:n,formatValue:s.Value.rem},values3:{values:S,formatValue:s.Value.fraction}},height:{cssNames:["height"],values1:{values:z,formatValue:s.Value.widthHeight},values2:{values:n,formatValue:s.Value.rem},values3:{values:S,formatValue:s.Value.fraction}},minHeight:{cssNames:["min-height"],values1:{values:z,formatValue:s.Value.widthHeight},values2:{values:n,formatValue:s.Value.rem},values3:{values:S,formatValue:s.Value.fraction}},maxHeight:{cssNames:["max-height"],values1:{values:z,formatValue:s.Value.widthHeight},values2:{values:n,formatValue:s.Value.rem},values3:{values:S,formatValue:s.Value.fraction}},position:{cssNames:["position"],values1:{values:["static","relative","absolute","fixed","sticky"]},values2:{values:[]},values3:{values:[]}},top:{cssNames:["top"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},right:{cssNames:["right"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},bottom:{cssNames:["bottom"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},left:{cssNames:["left"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},inset:{cssNames:["inset"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},m:{cssNames:["margin"],values1:{values:d,formatValue:s.Value.rem},values2:{values:["auto"]},values3:{values:[]}},mx:{cssNames:["margin-inline"],values1:{values:d,formatValue:s.Value.rem},values2:{values:["auto"]},values3:{values:[]}},my:{cssNames:["margin-block"],values1:{values:d,formatValue:s.Value.rem},values2:{values:["auto"]},values3:{values:[]}},mt:{cssNames:["margin-top"],values1:{values:d,formatValue:s.Value.rem},values2:{values:["auto"]},values3:{values:[]}},mr:{cssNames:["margin-right"],values1:{values:d,formatValue:s.Value.rem},values2:{values:["auto"]},values3:{values:[]}},mb:{cssNames:["margin-bottom"],values1:{values:d,formatValue:s.Value.rem},values2:{values:["auto"]},values3:{values:[]}},ml:{cssNames:["margin-left"],values1:{values:d,formatValue:s.Value.rem},values2:{values:["auto"]},values3:{values:[]}},p:{cssNames:["padding"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},px:{cssNames:["padding-inline"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},py:{cssNames:["padding-block"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},pt:{cssNames:["padding-top"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},pr:{cssNames:["padding-right"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},pb:{cssNames:["padding-bottom"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},pl:{cssNames:["padding-left"],values1:{values:d,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},b:{cssNames:["border-width"],values1:{values:n,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},bx:{cssNames:["border-inline-width"],values1:{values:d,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},by:{cssNames:["border-block-width"],values1:{values:d,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},bt:{cssNames:["border-top-width"],values1:{values:d,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},br:{cssNames:["border-right-width"],values1:{values:d,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},bb:{cssNames:["border-bottom-width"],values1:{values:d,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},bl:{cssNames:["border-left-width"],values1:{values:d,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},borderStyle:{cssNames:["border-style"],values1:{values:M},values2:{values:[]},values3:{values:[]}},borderRadius:{cssNames:["border-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusTop:{cssNames:["border-top-left-radius","border-top-right-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusRight:{cssNames:["border-top-right-radius","border-bottom-right-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusBottom:{cssNames:["border-bottom-left-radius","border-bottom-right-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusLeft:{cssNames:["border-top-left-radius","border-bottom-left-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusTopLeft:{cssNames:["border-top-left-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusTopRight:{cssNames:["border-top-right-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusBottomLeft:{cssNames:["border-bottom-left-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},borderRadiusBottomRight:{cssNames:["border-bottom-right-radius"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},cursor:{cssNames:["cursor"],values1:{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"]},values2:{values:[]},values3:{values:[]}},zIndex:{cssNames:["z-index"],values1:{values:[1,2,3,4,5,10,11,12,13,14,15,100,101,102,103,104,105,1e3,1001,1002,1003,1004,1005]},values2:{values:[]},values3:{values:[]}},overflow:{cssNames:["overflow"],values1:{values:_},values2:{values:[]},values3:{values:[]}},overflowX:{cssNames:["overflow-x"],values1:{values:_},values2:{values:[]},values3:{values:[]}},overflowY:{cssNames:["overflow-y"],values1:{values:_},values2:{values:[]},values3:{values:[]}},opacity:{cssNames:["opacity"],values1:{values:[0,.1,.2,.3,.4,.5,.6,.7,.8,.9,1]},values2:{values:[]},values3:{values:[]}},fontSize:{cssNames:["font-size"],values1:{values:n,formatValue:s.Value.px},values2:{values:["inherit"]},values3:{values:[]}},fontStyle:{cssNames:["font-style"],values1:{values:["italic","normal","oblique"]},values2:{values:[]},values3:{values:[]}},fontWeight:{cssNames:["font-weight"],values1:{values:[100,200,300,400,500,600,700,800,900]},values2:{values:[]},values3:{values:[]}},letterSpacing:{cssNames:["letter-spacing"],values1:{values:n,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},lineHeight:{cssNames:["line-height"],values1:{values:n,formatValue:s.Value.px},values2:{values:["font-size"],formatValue:()=>"1"},values3:{values:[]}},textDecoration:{cssNames:["text-decoration"],values1:{values:["none","underline","overline","line-through"]},values2:{values:[]},values3:{values:[]}},textTransform:{cssNames:["text-transform"],values1:{values:["none","capitalize","lowercase","uppercase"]},values2:{values:[]},values3:{values:[]}},textAlign:{cssNames:["text-align"],values1:{values:["left","right","center","justify"]},values2:{values:[]},values3:{values:[]}},flexWrap:{cssNames:["flex-wrap"],values1:{values:["nowrap","wrap","wrap-reverse"]},values2:{values:[]},values3:{values:[]}},jc:{cssNames:["justify-content"],values1:{values:["start","end","flex-start","flex-end","center","left","right","space-between","space-around","space-evenly","stretch"]},values2:{values:[]},values3:{values:[]}},ai:{cssNames:["align-items"],values1:{values:["stretch","flex-start","flex-end","center","baseline","start","end","self-start","self-end"]},values2:{values:[]},values3:{values:[]}},alignContent:{cssNames:["align-content"],values1:{values:["flex-start","flex-end","center","space-between","space-around","space-evenly","stretch","start","end","baseline"]},values2:{values:[]},values3:{values:[]}},flex1:{cssNames:["flex"],values1:{values:[!0],formatValue:()=>"1"},values2:{values:[]},values3:{values:[]}},d:{cssNames:["flex-direction"],values1:{values:["row","row-reverse","column","column-reverse"]},values2:{values:[]},values3:{values:[]}},gap:{cssNames:["gap"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},rowGap:{cssNames:["row-gap"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},columnGap:{cssNames:["column-gap"],values1:{values:n,formatValue:s.Value.rem},values2:{values:[]},values3:{values:[]}},order:{cssNames:["order"],values1:{values:n},values2:{values:[]},values3:{values:[]}},flexGrow:{cssNames:["flex-grow"],values1:{values:n},values2:{values:[]},values3:{values:[]}},flexShrink:{cssNames:["flex-shrink"],values1:{values:n},values2:{values:[]},values3:{values:[]}},alignSelf:{cssNames:["align-self"],values1:{values:G},values2:{values:[]},values3:{values:[]}},justifySelf:{cssNames:["justify-self"],values1:{values:G},values2:{values:[]},values3:{values:[]}},gridColumns:{cssNames:["grid-template-columns"],values1:{values:n,formatValue:s.Value.gridColumns},values2:{values:[]},values3:{values:[]}},colSpan:{cssNames:["grid-column"],values1:{values:n,formatValue:s.Value.gridColumn},values2:{values:["full-row"],formatValue:s.Value.gridColumn},values3:{values:[]}},colStart:{cssNames:["grid-column-start"],values1:{values:n},values2:{values:[]},values3:{values:[]}},colEnd:{cssNames:["grid-column-end"],values1:{values:n},values2:{values:[]},values3:{values:[]}},outline:{cssNames:["outline-width"],values1:{values:n,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},outlineStyle:{cssNames:["outline-style"],values1:{values:M},values2:{values:[]},values3:{values:[]}},outlineOffset:{cssNames:["outline-offset"],values1:{values:n,formatValue:s.Value.px},values2:{values:[]},values3:{values:[]}},transition:{cssNames:["transition-property"],values1:{values:["none","all"]},values2:{values:[]},values3:{values:[]}},transitionDuration:{cssNames:["transition-duration"],values1:{values:[50,100,150,200,250,300,350,400,450,500,550,600,650,700,750,800,850,900,950,1e3],formatValue:s.Value.ms},values2:{values:[]},values3:{values:[]}},userSelect:{cssNames:["user-select"],values1:{values:["none","auto","text","all"]},values2:{values:[]},values3:{values:[]}},appearance:{cssNames:["appearance"],values1:{values:["none"]},values2:{values:[]},values3:{values:[]}},pointerEvents:{cssNames:["pointer-events"],values1:{values:["none","auto","all"]},values2:{values:[]},values3:{values:[]}},whiteSpace:{cssNames:["white-space"],values1:{values:["break-spaces","normal","nowrap","pre","pre-line","pre-wrap"]},values2:{values:[]},values3:{values:[]}},textOverflow:{cssNames:["text-overflow"],values1:{values:["clip","ellipsis"]},values2:{values:[]},values3:{values:[]}},rotate:{cssNames:["rotate"],values1:{values:[0,90,180,270,-90,-180,-270],formatValue:s.Value.rotate},values2:{values:[]},values3:{values:[]}},flip:{cssNames:["scale"],values1:{values:["xAxis","yAxis"],formatValue:s.Value.flip},values2:{values:[]},values3:{values:[]}}},K={shadow:{cssNames:["box-shadow"],formatValue:s.Value.variables("shadow")},background:{cssNames:["background"],formatValue:s.Value.variables("background")},backgroundImage:{cssNames:["background-image"],formatValue:s.Value.variables("backgroundImage")},color:{cssNames:["color"],formatValue:s.Value.variables("color")},bgColor:{cssNames:["background-color"],formatValue:s.Value.variables("color")},borderColor:{cssNames:["border-color"],formatValue:s.Value.variables("color")},outlineColor:{cssNames:["outline-color"],formatValue:s.Value.variables("color")}},U={fill:{cssNames:["fill"],formatValue:s.Value.svgVariables("color"),formatSelector:s.ClassName.svg},stroke:{cssNames:["stroke"],formatValue:s.Value.svgVariables("color"),formatSelector:s.ClassName.svg}},ee=["H","F","A","Checked","Indeterminate","Valid","Invalid","Required","Optional","Disabled"],E=["sm","md","lg","xl","xxl"],se={sm:640,md:768,lg:1024,xl:1280,xxl:1536},H={hover:{className:"_h"},focus:{className:"_f"}};Object.keys(K).forEach(l=>{N[l]=K[l],N[l].isThemeStyle=!0});Object.keys(U).forEach(l=>{N[l]=U[l],N[l].isThemeStyle=!0});let P=Object.keys(N);ee.forEach(l=>{P.forEach(u=>{N[`${u}${l}`]={...N[u],pseudoSuffix:l}})});P=Object.keys(N);E.forEach(l=>{P.forEach(u=>{N[`${l}${u}`]={...N[u],breakpoint:l}})});class ae{constructor(){this._index=0,this._cache={}}getIdentity(u){return this._cache[u]||(this._cache[u]=this.getByIndex(this._index++)),this._cache[u]}getByIndex(u){const{first:i,next:m}=le,o=u-i.length;if(o<0)return i[u];const h=Math.floor(o/m.length),V=o-h*m.length;return this.getByIndex(h)+m[V]}}const le={first:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",next:"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"};var D;(l=>{l.boxClassName="_box",l.svgClassName="_svg",l.cronoStylesElementId="crono-styles";const u=`:root{--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
- .${u.boxClassName}{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
- .${u.svgClassName}{transition: all var(--svgTransitionTime);}.${u.svgClassName} path,.${u.svgClassName} circle,.${u.svgClassName} rect,.${u.svgClassName} line {transition: all var(--svgTransitionTime);}
7
- `,c=new J,h=Object.keys(x);let l=!0,v=h.reduce((a,s)=>(a[s]=new Set,a),{});function m(a,s){if(a in x)return g(a,s);if(a in O&&s)return O[a].className}u.get=m;function C(){if(l){let a=f([r]);a=f(a,"H"),a=f(a,"F"),a=f(a,"A"),a=f(a,"Checked"),a=f(a,"Indeterminate"),a=f(a,"Valid"),a=f(a,"Invalid"),a=f(a,"Required"),a=f(a,"Disabled");const s=V();s.innerHTML=a.join(""),l=!1}}u.flush=C;function i(){v=h.reduce((a,s)=>(a[s]=new Set,a),{})}u.clear=i;function g(a,s){var y;v[a].has(s)||(l=!0,v[a].add(s));const t=b(a,s),N=((y=t.formatClassName)==null?void 0:y.call(t,a,s))??`${a}${s}`;return c.getIdentity(N)}function f(a,s){return Object.entries(v).filter(([N])=>{var y;return((y=x[N])==null?void 0:y.pseudoSuffix)===s}).reduce((N,[y,I])=>(I.forEach($=>{var R;const o=b(y,$),p=`.${g(y,$)}`;let w=[];s?s==="H"?w=[...t(`${p}:hover`,o),...t(`.${O.hover.className}:hover>${p}`,o)]:s==="F"?w=[...t(`${p}:focus-within`,o),...t(`.${O.focus.className}:focus-within>${p}`,o)]:s==="A"?w=t(`${p}:active`,o):s==="Checked"?w=t(`${p}:checked`,o):s==="Indeterminate"?w=t(`${p}:indeterminate`,o):s==="Valid"?w=t(`${p}:valid`,o):s==="Invalid"?w=t(`${p}:invalid`,o):s==="Required"?w=t(`${p}:required`,o):s==="Optional"?w=t(`${p}:optional`,o):s==="Disabled"&&(w=t(`${p}:disabled`,o)):w=t(p,o);const M=((R=o.formatValue)==null?void 0:R.call(o,y,$))??$,W=x[y].cssNames.map(G=>`${G}:${M};`).join("");N.push(`${w.join(",")}{${W}}`)}),N),a);function t(N,y){return y.formatSelector?y.formatSelector(N):[N]}}function b(a,s){const t=x[a];return t.isThemeStyle?t:t.values1.values.includes(s)?t.values1:t.values2.values.includes(s)?t.values2:t.values3}function V(){const s=typeof window<"u"&&typeof window.document<"u"?window.document:global.document;let t=s.getElementById(u.cronoStylesElementId);return t||(t=s.createElement("style"),t.setAttribute("id",u.cronoStylesElementId),t.setAttribute("type","text/css"),s.head.insertBefore(t,s.head.firstChild)),t}})(A||(A={}));const T=A,z={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}}};var H;(u=>{u.Styles=l(z);function r(i){u.Styles=h(i)}u.setup=r;function c(i,g){const f=Object.entries(i.colors).map(([o,p])=>`--color${o}: ${p};`).join(`
8
- `),b=Object.entries(i.shadows).map(([o,p])=>`--shadow${o}: ${p};`).join(`
9
- `),V=Object.entries(i.backgrounds).map(([o,p])=>`--background${o}: ${p};`).join(`
10
- `),a=Object.entries(i.backgroundImages).map(([o,p])=>`--backgroundImage${o}: ${p};`).join(`
11
- `),s=[":root {"];f&&s.push(` ${f}`),b&&s.push(` ${b}`),V&&s.push(` ${V}`),a&&s.push(` ${a}`),s.push("}");const t=Object.keys(i.colors).map(o=>`'${o}'`).join(" | "),N=Object.keys(i.backgrounds).map(o=>`'${o}'`).join(" | "),y=Object.keys(i.backgroundImages).map(o=>`'${o}'`).join(" | "),I=Object.keys(i.shadows).map(o=>`'${o}'`).join(" | "),$=`import '@cronocode/react-box';
5
+ .${l.boxClassName}{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
+ .${l.svgClassName}{transition: all var(--svgTransitionTime);}.${l.svgClassName} path,.${l.svgClassName} circle,.${l.svgClassName} rect,.${l.svgClassName} line {transition: all var(--svgTransitionTime);}
7
+ `,i=new ae,m=Object.keys(N);let o=!0,h=m.reduce((e,a)=>(e[a]=new Set,e),{});function V(e,a,t){if(e in N)return c(e,a,t);if(e in H&&a)return H[e].className}l.get=V;function T(){if(o){let e=r([u]);e=r(e,"H"),e=r(e,"F"),e=r(e,"A"),e=r(e,"Checked"),e=r(e,"Indeterminate"),e=r(e,"Valid"),e=r(e,"Invalid"),e=r(e,"Required"),e=r(e,"Disabled"),E.forEach(t=>{e.push(`@media(min-width: ${se[t]}px){`),e=r(e,void 0,t),e=r(e,"H",t),e=r(e,"F",t),e=r(e,"A",t),e=r(e,"Checked",t),e=r(e,"Indeterminate",t),e=r(e,"Valid",t),e=r(e,"Invalid",t),e=r(e,"Required",t),e=r(e,"Disabled",t),e.push("}")});const a=f();a.innerHTML=e.join(""),o=!1}}l.flush=T;function C(){h=m.reduce((e,a)=>(e[a]=new Set,e),{})}l.clear=C;function c(e,a,t){const v=(t??"")+e;h[v].has(a)||(o=!0,h[v].add(a));const x=`${v}${a}`;return i.getIdentity(x)}function r(e,a,t){return Object.entries(h).filter(([x])=>{var $,j;return(($=N[x])==null?void 0:$.pseudoSuffix)===a&&((j=N[x])==null?void 0:j.breakpoint)===t}).reduce((x,[$,j])=>(j.forEach(O=>{var W;const g=b($,O),y=`.${c($,O)}`;let w=[];a?a==="H"?w=[...v(`${y}:hover`,g),...v(`.${H.hover.className}:hover>${y}`,g)]:a==="F"?w=[...v(`${y}:focus-within`,g),...v(`.${H.focus.className}:focus-within>${y}`,g)]:a==="A"?w=v(`${y}:active`,g):a==="Checked"?w=v(`${y}:checked`,g):a==="Indeterminate"?w=v(`${y}:indeterminate`,g):a==="Valid"?w=v(`${y}:valid`,g):a==="Invalid"?w=v(`${y}:invalid`,g):a==="Required"?w=v(`${y}:required`,g):a==="Optional"?w=v(`${y}:optional`,g):a==="Disabled"&&(w=v(`${y}:disabled`,g)):w=v(y,g);const q=((W=g.formatValue)==null?void 0:W.call(g,$,O))??O,k=N[$].cssNames.map(J=>`${J}:${q};`).join("");x.push(`${w.join(",")}{${k}}`)}),x),e);function v(x,$){return $.formatSelector?$.formatSelector(x):[x]}}function b(e,a){const t=N[e];return t.isThemeStyle?t:t.values1.values.includes(a)?t.values1:t.values2.values.includes(a)?t.values2:t.values3}function f(){const a=typeof window<"u"&&typeof window.document<"u"?window.document:global.document;let t=a.getElementById(l.cronoStylesElementId);return t||(t=a.createElement("style"),t.setAttribute("id",l.cronoStylesElementId),t.setAttribute("type","text/css"),a.head.insertBefore(t,a.head.firstChild)),t}})(D||(D={}));const I=D,A={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}}},ue={H:"hover",F:"focus",A:"active",Checked:"checked",Indeterminate:"indeterminate",Valid:"valid",Invalid:"invalid",Required:"required",Optional:"optional",Disabled:"disabled"};var F;(l=>{l.Styles={};function u(c){l.Styles=o(A),l.Styles=m(c)}l.setup=u;function i(c,r){const{colors:b={},shadows:f={},backgrounds:e={},backgroundImages:a={}}=c;b.none="none",f.none="none",e.none="none",a.none="none";const t=Object.entries(b).map(([p,k])=>`--color${p}: ${k};`).join(`
8
+ `),v=Object.entries(f).map(([p,k])=>`--shadow${p}: ${k};`).join(`
9
+ `),x=Object.entries(e).map(([p,k])=>`--background${p}: ${k};`).join(`
10
+ `),$=Object.entries(a).map(([p,k])=>`--backgroundImage${p}: ${k};`).join(`
11
+ `),j=[":root {"];t&&j.push(` ${t}`),v&&j.push(` ${v}`),x&&j.push(` ${x}`),$&&j.push(` ${$}`),j.push("}");const O=Object.keys(b).map(p=>`'${p}'`).join(" | "),g=Object.keys(e).map(p=>`'${p}'`).join(" | "),y=Object.keys(a).map(p=>`'${p}'`).join(" | "),w=Object.keys(f).map(p=>`'${p}'`).join(" | "),q=`import '@cronocode/react-box';
12
12
 
13
- declare module '${(g==null?void 0:g.namespacePath)??"@cronocode/react-box/core/types"}' {
14
- type ColorType = ${t};
15
- type BackgroundType = ${N};
13
+ declare module '${(r==null?void 0:r.namespacePath)??"@cronocode/react-box/core/types"}' {
14
+ type ColorType = ${O};
15
+ type BackgroundType = ${g};
16
16
  type BackgroundImageType = ${y};
17
- type ShadowType = ${I};
17
+ type ShadowType = ${w};
18
18
 
19
19
  namespace Augmented {
20
20
  interface BoxProps {
@@ -33,5 +33,5 @@ a,ul{all: unset;}
33
33
  }
34
34
  }
35
35
  }
36
- `;return{variables:s.join(`
37
- `),boxDts:$}}u.setupAugmentedProps=c;function h(i){const g=l(i);return Object.keys(z).forEach(b=>{const V=g[b],a=z[b];V?V.styles={...a.styles,...V.styles}:g[b]=z[b]}),g}function l(i){return v(i),C(i),i}function v(i){if(!i.components)return;const g=Object.keys(i.components);for(const f of g){const b=i.components[f],V=m(f,b);delete b.children;for(const a of V){const[s,t]=a;i.components[s]=t}}}function m(i,g){if(!g.children)return[];const f=Object.keys(g.children),b=[];for(const V of f){const a=`${i}.${V}`,s=g.children[V],t=m(a,s);b.push(...t),delete s.children,b.push([a,s])}return b}function C(i){const{components:g,...f}=i,b=Object.values(f);g&&b.push(...Object.values(g));for(const V of b)[["disabled","Disabled"],["indeterminate","Indeterminate"],["checked","Checked"]].forEach(([a,s])=>{a in V.styles&&(Object.entries(V.styles[a]).map(([t,N])=>{V.styles[`${t}${s}`]=N}),delete V.styles[a])})}})(H||(H={}));const B=H;function Z(u){const{clean:r,theme:c,component:h}=u;return S.useMemo(()=>{var v,m;if(r)return;let l=B.Styles[h]??((v=B.Styles.components)==null?void 0:v[h]);if(l)return c?{...l.styles,...(m=l.themes)==null?void 0:m[c].styles}:l.styles},[h,r,c])}const K=typeof window<"u"&&typeof window.document<"u",ee=K?S.useLayoutEffect:S.useEffect;function se(u,r){const c=Z(u);return ee(T.flush,[u]),S.useMemo(()=>{const h=[r?T.svgClassName:T.boxClassName],l=c?{...c,...u}:{...u};return Array.isArray(l.disabled)&&(Object.entries(l.disabled[1]).forEach(([v,m])=>{l[`${v}Disabled`]=m}),delete l.disabled),Array.isArray(l.hover)?(Object.entries(l.hover[1]).forEach(([v,m])=>{l[`${v}H`]=m}),l.hover=l.hover[0]):_.ObjectUtils.isObject(l.hover)&&(Object.entries(l.hover).forEach(([v,m])=>{l[`${v}H`]=m}),delete l.hover),Array.isArray(l.focus)?(Object.entries(l.focus[1]).forEach(([v,m])=>{l[`${v}F`]=m}),l.focus=l.focus[0]):_.ObjectUtils.isObject(l.focus)&&(Object.entries(l.focus).forEach(([v,m])=>{l[`${v}F`]=m}),delete l.focus),l.active&&(Object.entries(l.active).forEach(([v,m])=>{l[`${v}A`]=m}),delete l.active),"inline"in l&&(l.display==="block"||!l.display?l.display="inline-block":l.display==="flex"?l.display="inline-flex":l.display==="grid"&&(l.display="inline-grid"),delete l.inline),Object.entries(l).forEach(([v,m])=>{h.push(T.get(v,m))}),h},[u,c])}function F(...u){return u.reduce((r,c)=>c?typeof c=="string"?(r.push(c),r):Array.isArray(c)?(r.push(...F(...c)),r):(Object.entries(c).forEach(([h,l])=>{l&&r.push(h)}),r):r,[])}exports.StylesContext=T;exports.Theme=B;exports.classNames=F;exports.useStyles=se;
36
+ `;return{variables:j.join(`
37
+ `),boxDts:q}}l.setupAugmentedProps=i;function m(c){const r=o(c);return Object.keys(A).forEach(f=>{const e=r[f],a=A[f];e?e.styles={...a.styles,...e.styles}:r[f]=A[f]}),r}function o(c){return h(c),T(c),c}function h(c){if(!c.components)return;const r=Object.keys(c.components);for(const b of r){const f=c.components[b],e=V(b,f);delete f.children;for(const a of e){const[t,v]=a;c.components[t]=v}}}function V(c,r){if(!r.children)return[];const b=Object.keys(r.children),f=[];for(const e of b){const a=`${c}.${e}`,t=r.children[e],v=V(a,t);f.push(...v),delete t.children,f.push([a,t])}return f}function T(c){const{components:r,...b}=c,f=Object.values(b);r&&f.push(...Object.values(r));for(const e of f)C(e.styles),E.forEach(a=>{if(a in e.styles){const t=e.styles[a];C(t)}}),e.themes&&Object.values(e.themes).forEach(a=>{C(a),E.forEach(t=>{if(t in a){const v=a[t];C(v)}})})}function C(c){Object.entries(ue).forEach(([r,b])=>{if(b in c){const f=c[b];Object.entries(f).map(([e,a])=>{c[`${e}${r}`]=a}),delete c[b]}})}})(F||(F={}));const L=F;function te(l){const{clean:u,theme:i,component:m}=l;return B.useMemo(()=>{var h,V;if(u)return;let o=L.Styles[m]??((h=L.Styles.components)==null?void 0:h[m]);if(o)return i?{...o.styles,...(V=o.themes)==null?void 0:V[i]}:o.styles},[m,u,i])}const re=typeof window<"u"&&typeof window.document<"u",oe=re?B.useLayoutEffect:B.useEffect;function ne(l,u){const i=te(l);return oe(I.flush,[l]),B.useMemo(()=>{const m=[u?I.svgClassName:I.boxClassName],o=i?{...i,...l}:{...l};return X(o),E.forEach(h=>{if(h in o){const V=o[h];X(V),Object.entries(V).forEach(([T,C])=>{m.push(I.get(T,C,h))}),delete o[h]}}),Object.entries(o).forEach(([h,V])=>{m.push(I.get(h,V))}),m},[l,i])}function X(l){R(l,"disabled","Disabled"),R(l,"hover","H"),R(l,"focus","F"),R(l,"active","A")}function R(l,u,i){u in l&&(Array.isArray(l[u])?(Object.entries(l[u][1]).forEach(([m,o])=>{l[`${m}${i}`]=o}),l[u]=l[u][0]):Q.ObjectUtils.isObject(l[u])&&(Object.entries(l[u]).forEach(([m,o])=>{l[`${m}${i}`]=o}),delete l[u]))}function Y(...l){return l.reduce((u,i)=>i?typeof i=="string"?(u.push(i),u):Array.isArray(i)?(u.push(...Y(...i)),u):(Object.entries(i).forEach(([m,o])=>{o&&u.push(m)}),u):u,[])}exports.StylesContext=I;exports.Theme=L;exports.classNames=Y;exports.useStyles=ne;