@ark-ui/solid 5.29.0 → 5.30.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk/{ZV3HBWS5.jsx → 2JSSDQEE.jsx} +23 -9
- package/dist/chunk/{GFKCCGJB.js → 2V2P2JZV.js} +10 -6
- package/dist/chunk/{EM4XSE5H.js → 3BRVNFB3.js} +1 -1
- package/dist/chunk/{I3MLFUBK.jsx → 3ZDGZCBV.jsx} +15 -9
- package/dist/chunk/{VAEEL2O7.jsx → 4A6UNZ4T.jsx} +5 -3
- package/dist/chunk/{YTFMRBD2.js → 52VYWTHF.js} +1 -1
- package/dist/chunk/{S7S4GNYZ.jsx → 76KFR2EJ.jsx} +5 -4
- package/dist/chunk/{5KPLCG77.jsx → 7HLG62OR.jsx} +4 -4
- package/dist/chunk/{TQYNU5YV.js → AH5KB6LR.js} +1 -1
- package/dist/chunk/{62N4ZDOB.js → B434DN6B.js} +14 -2
- package/dist/chunk/{MZEGYYMT.js → F7OI3RZ3.js} +1 -1
- package/dist/chunk/{HRPXPYHQ.js → FDE3GI6Q.js} +1 -1
- package/dist/chunk/{U7FAF24E.js → G2THT6E6.js} +1 -1
- package/dist/chunk/{TPLBK6KL.js → GBGTOFYC.js} +1 -1
- package/dist/chunk/{TBRRDX3X.jsx → GCEYGQPA.jsx} +6 -6
- package/dist/chunk/{Y66OHGAM.js → HCQSZULR.js} +1 -1
- package/dist/chunk/{TPRSB43T.jsx → HVXJLFJY.jsx} +4 -4
- package/dist/chunk/{IEP4WYW2.jsx → HWHAUHQ5.jsx} +6 -5
- package/dist/chunk/{CCNCOLB2.jsx → IGSOSLB3.jsx} +4 -4
- package/dist/chunk/{WLITP5TP.jsx → J5ODILBT.jsx} +9 -9
- package/dist/chunk/{WOSN63AN.jsx → JNBFQ7ZP.jsx} +9 -9
- package/dist/chunk/{PMI7UADJ.jsx → JRY66LXS.jsx} +4 -4
- package/dist/chunk/{KQ6IUY4K.js → K3TLO6S6.js} +1 -1
- package/dist/chunk/{J3XZT7EL.js → LNZGGTI5.js} +1 -1
- package/dist/chunk/{2UC6SEQ4.jsx → NHEM6XZR.jsx} +21 -10
- package/dist/chunk/{TNKGDI7Y.jsx → NPSTVZUG.jsx} +4 -4
- package/dist/chunk/{CM2ALDJ7.jsx → NZQO4OJP.jsx} +4 -4
- package/dist/chunk/{ARA55KUE.jsx → ORJXW4SC.jsx} +1 -1
- package/dist/chunk/{QRDTSOYR.jsx → OVPRCDDL.jsx} +4 -4
- package/dist/chunk/{FLYTMLX4.js → QGXWXVZ5.js} +17 -7
- package/dist/chunk/{QQMFSE7Q.jsx → RRFWSRAD.jsx} +11 -9
- package/dist/chunk/{3GKO4C5T.js → RSWPJEWK.js} +1 -1
- package/dist/chunk/{7B2MTJPJ.jsx → SH4J3NPA.jsx} +34 -13
- package/dist/chunk/{Y3GFUOZP.jsx → SZNFUIJQ.jsx} +4 -4
- package/dist/chunk/TILTTA4A.js +1 -0
- package/dist/chunk/{RNVRDALA.js → TP32AKQX.js} +1 -1
- package/dist/chunk/{XNP7QM5Q.jsx → UHWLTCQZ.jsx} +0 -3
- package/dist/chunk/{KAO2IPN7.js → UTULIPW7.js} +1 -1
- package/dist/chunk/{SKC2JUHO.jsx → VH6MDPEX.jsx} +4 -4
- package/dist/chunk/{OX3264V7.jsx → VIKFXGE5.jsx} +4 -4
- package/dist/chunk/{BQJK3XJQ.js → W7YDKZGP.js} +1 -1
- package/dist/chunk/WCB4ISVQ.jsx +6 -0
- package/dist/chunk/{7XIUKXCN.js → WUBTAV2O.js} +1 -1
- package/dist/chunk/{CN63YZUE.js → Z4EBWHQF.js} +2 -2
- package/dist/chunk/{UXNQOU36.js → Z5ZRFFPU.js} +40 -15
- package/dist/chunk/{36P5AXKU.js → ZYFWVVTC.js} +1 -1
- package/dist/components/accordion/index.jsx +4 -4
- package/dist/components/anatomy.d.ts +1 -0
- package/dist/components/anatomy.js +20 -19
- package/dist/components/anatomy.jsx +51 -47
- package/dist/components/angle-slider/index.jsx +2 -2
- package/dist/components/avatar/index.jsx +2 -2
- package/dist/components/bottom-sheet/index.jsx +3 -3
- package/dist/components/carousel/index.jsx +2 -2
- package/dist/components/checkbox/index.d.ts +4 -4
- package/dist/components/checkbox/index.js +1 -1
- package/dist/components/checkbox/index.jsx +5 -5
- package/dist/components/clipboard/index.jsx +1 -1
- package/dist/components/collapsible/index.jsx +3 -3
- package/dist/components/color-picker/index.js +1 -1
- package/dist/components/color-picker/index.jsx +6 -6
- package/dist/components/combobox/index.js +1 -1
- package/dist/components/combobox/index.jsx +6 -6
- package/dist/components/date-picker/index.js +1 -1
- package/dist/components/date-picker/index.jsx +4 -4
- package/dist/components/dialog/index.jsx +4 -4
- package/dist/components/download-trigger/index.jsx +1 -1
- package/dist/components/editable/index.js +1 -1
- package/dist/components/editable/index.jsx +5 -5
- package/dist/components/field/index.js +1 -1
- package/dist/components/field/index.jsx +4 -4
- package/dist/components/fieldset/index.d.ts +6 -1
- package/dist/components/fieldset/index.js +1 -1
- package/dist/components/fieldset/index.jsx +3 -2
- package/dist/components/file-upload/index.js +1 -1
- package/dist/components/file-upload/index.jsx +5 -5
- package/dist/components/floating-panel/index.jsx +4 -4
- package/dist/components/format/index.jsx +1 -1
- package/dist/components/frame/index.jsx +2 -2
- package/dist/components/hover-card/index.jsx +4 -4
- package/dist/components/image-cropper/index.jsx +2 -2
- package/dist/components/index.d.ts +1 -1
- package/dist/components/index.js +52 -52
- package/dist/components/index.jsx +402 -398
- package/dist/components/json-tree-view/index.js +1 -1
- package/dist/components/json-tree-view/index.jsx +5 -5
- package/dist/components/listbox/index.jsx +2 -2
- package/dist/components/marquee/index.jsx +2 -2
- package/dist/components/menu/index.jsx +4 -4
- package/dist/components/navigation-menu/index.d.ts +106 -0
- package/dist/components/navigation-menu/index.js +274 -0
- package/dist/components/navigation-menu/index.jsx +304 -0
- package/dist/components/number-input/index.js +1 -1
- package/dist/components/number-input/index.jsx +5 -5
- package/dist/components/pagination/index.d.ts +14 -2
- package/dist/components/pagination/index.js +1 -1
- package/dist/components/pagination/index.jsx +6 -2
- package/dist/components/password-input/index.js +1 -1
- package/dist/components/password-input/index.jsx +5 -5
- package/dist/components/pin-input/index.js +1 -1
- package/dist/components/pin-input/index.jsx +5 -5
- package/dist/components/popover/index.jsx +4 -4
- package/dist/components/progress/index.jsx +2 -2
- package/dist/components/qr-code/index.jsx +2 -2
- package/dist/components/radio-group/index.js +1 -1
- package/dist/components/radio-group/index.jsx +5 -2
- package/dist/components/rating-group/index.js +1 -1
- package/dist/components/rating-group/index.jsx +5 -5
- package/dist/components/scroll-area/index.jsx +2 -2
- package/dist/components/segment-group/index.js +1 -1
- package/dist/components/segment-group/index.jsx +2 -2
- package/dist/components/select/index.js +1 -1
- package/dist/components/select/index.jsx +6 -6
- package/dist/components/signature-pad/index.js +1 -1
- package/dist/components/signature-pad/index.jsx +5 -5
- package/dist/components/slider/index.jsx +2 -2
- package/dist/components/splitter/index.jsx +2 -2
- package/dist/components/steps/index.jsx +2 -2
- package/dist/components/switch/index.js +1 -1
- package/dist/components/switch/index.jsx +5 -5
- package/dist/components/tabs/index.jsx +4 -4
- package/dist/components/tags-input/index.js +1 -1
- package/dist/components/tags-input/index.jsx +5 -5
- package/dist/components/timer/index.jsx +1 -1
- package/dist/components/toast/index.jsx +2 -2
- package/dist/components/toggle-group/index.jsx +2 -2
- package/dist/components/tooltip/index.jsx +4 -4
- package/dist/components/tour/index.jsx +4 -4
- package/dist/components/tree-view/index.js +1 -1
- package/dist/components/tree-view/index.jsx +4 -4
- package/dist/index.d.ts +1 -1
- package/dist/index.js +52 -52
- package/dist/index.jsx +406 -402
- package/dist/providers/index.jsx +4 -4
- package/package.json +67 -66
- package/dist/chunk/{Q7K5GRG2.jsx → 2S7Z6JX4.jsx} +3 -3
- package/dist/chunk/{VC57LYBD.jsx → 6QF5SDIE.jsx} +3 -3
- package/dist/chunk/{JOPZMH6Q.jsx → AQ27SOWE.jsx} +3 -3
- package/dist/chunk/{ZMMBPM35.jsx → CCK5XI24.jsx} +3 -3
- package/dist/chunk/{O4IVFUVT.jsx → CNHYYRWI.jsx} +3 -3
- package/dist/chunk/{D6FFYEZW.jsx → DH3KPRGA.jsx} +3 -3
- package/dist/chunk/{K3ONGLLK.jsx → DR7CHNBO.jsx} +3 -3
- package/dist/chunk/{FJR3IQ57.jsx → FKF6FOYL.jsx} +3 -3
- package/dist/chunk/{B7UDMWBC.jsx → FXYVJXLF.jsx} +3 -3
- package/dist/chunk/{UWQ2GKVZ.jsx → HNIBOZUS.jsx} +6 -6
- package/dist/chunk/{2W623CVF.jsx → IEJ4RWIV.jsx} +3 -3
- package/dist/chunk/{RCX3BG4L.jsx → J6B3R7PY.jsx} +3 -3
- package/dist/chunk/{H55FBH2X.jsx → JEKNEIFC.jsx} +3 -3
- package/dist/chunk/{5MH7IW2U.jsx → KEZ2WH2A.jsx} +3 -3
- package/dist/chunk/{ETBHESWM.jsx → MNZUELWU.jsx} +3 -3
- package/dist/chunk/{XRV7I5LE.jsx → OF7DNWIQ.jsx} +3 -3
- package/dist/chunk/{7UYY44WH.jsx → QTWOIUHU.jsx} +3 -3
- package/dist/chunk/{RTSM3MM5.jsx → RYD4Z3LT.jsx} +3 -3
- package/dist/chunk/{2RZITRBG.jsx → UOOMXEJO.jsx} +3 -3
- package/dist/chunk/{RVZWPVOQ.jsx → UOTT3RUB.jsx} +3 -3
- package/dist/chunk/{4CGGPY3A.jsx → VRCOVKZM.jsx} +3 -3
- package/dist/chunk/{5KWWA73X.jsx → XH4Y4U2G.jsx} +3 -3
- package/dist/chunk/{HKNRED3R.jsx → XNAQLSZW.jsx} +3 -3
- package/dist/chunk/{JLH74767.jsx → XXP27BHC.jsx} +3 -3
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
parts
|
|
3
3
|
} from "./4YNGVMW2.jsx";
|
|
4
|
+
import {
|
|
5
|
+
composeRefs
|
|
6
|
+
} from "./PT2CJE3O.jsx";
|
|
4
7
|
import {
|
|
5
8
|
createSplitProps
|
|
6
9
|
} from "./6WEDGJKQ.jsx";
|
|
@@ -62,19 +65,19 @@ import { mergeProps as mergeProps5 } from "@zag-js/solid";
|
|
|
62
65
|
|
|
63
66
|
// src/components/fieldset/use-fieldset.ts
|
|
64
67
|
import { dataAttr } from "@zag-js/dom-query";
|
|
65
|
-
import {
|
|
68
|
+
import { createMemo, createSignal, createUniqueId, mergeProps as mergeProps4, onCleanup, onMount } from "solid-js";
|
|
66
69
|
var useFieldset = (props) => {
|
|
67
70
|
const env = useEnvironmentContext();
|
|
68
71
|
const mergedProps = mergeProps4({ disabled: false, invalid: false }, runIfFn(props));
|
|
69
|
-
|
|
72
|
+
const [rootRef, setRootRef] = createSignal(void 0);
|
|
70
73
|
const id = mergedProps.id ?? createUniqueId();
|
|
71
74
|
const legendId = `fieldset::${id}::legend`;
|
|
72
75
|
const errorTextId = `fieldset::${id}::error-text`;
|
|
73
76
|
const helperTextId = `fieldset::${id}::helper-text`;
|
|
74
77
|
const [hasErrorText, setHasErrorText] = createSignal(false);
|
|
75
78
|
const [hasHelperText, setHasHelperText] = createSignal(false);
|
|
76
|
-
|
|
77
|
-
const rootNode = rootRef;
|
|
79
|
+
onMount(() => {
|
|
80
|
+
const rootNode = rootRef();
|
|
78
81
|
if (!rootNode) return;
|
|
79
82
|
const checkTextElements = () => {
|
|
80
83
|
const docOrShadowRoot = env().getRootNode();
|
|
@@ -87,16 +90,19 @@ var useFieldset = (props) => {
|
|
|
87
90
|
observer.observe(rootNode, { childList: true, subtree: true });
|
|
88
91
|
onCleanup(() => observer.disconnect());
|
|
89
92
|
});
|
|
90
|
-
const labelIds =
|
|
91
|
-
|
|
92
|
-
|
|
93
|
+
const labelIds = createMemo(() => {
|
|
94
|
+
const ids = [];
|
|
95
|
+
if (hasErrorText() && mergedProps.invalid) ids.push(errorTextId);
|
|
96
|
+
if (hasHelperText()) ids.push(helperTextId);
|
|
97
|
+
return ids;
|
|
98
|
+
});
|
|
93
99
|
const getRootProps = () => ({
|
|
94
100
|
...parts.root.attrs,
|
|
95
101
|
disabled: mergedProps.disabled,
|
|
96
102
|
"data-disabled": dataAttr(mergedProps.disabled),
|
|
97
103
|
"data-invalid": dataAttr(mergedProps.invalid),
|
|
98
104
|
"aria-labelledby": legendId,
|
|
99
|
-
"aria-describedby": labelIds.join(" ") || void 0
|
|
105
|
+
"aria-describedby": labelIds().join(" ") || void 0
|
|
100
106
|
});
|
|
101
107
|
const getLegendProps = () => ({
|
|
102
108
|
id: legendId,
|
|
@@ -115,7 +121,12 @@ var useFieldset = (props) => {
|
|
|
115
121
|
});
|
|
116
122
|
return createMemo(() => ({
|
|
117
123
|
refs: {
|
|
118
|
-
rootRef
|
|
124
|
+
rootRef: setRootRef
|
|
125
|
+
},
|
|
126
|
+
ids: {
|
|
127
|
+
legend: legendId,
|
|
128
|
+
errorText: errorTextId,
|
|
129
|
+
helperText: helperTextId
|
|
119
130
|
},
|
|
120
131
|
disabled: mergedProps.disabled,
|
|
121
132
|
invalid: mergedProps.invalid,
|
|
@@ -132,7 +143,7 @@ var FieldsetRoot = (props) => {
|
|
|
132
143
|
const fieldset = useFieldset(useFieldsetProps);
|
|
133
144
|
const mergedProps = mergeProps5(() => fieldset().getRootProps(), localProps);
|
|
134
145
|
return <FieldsetProvider value={fieldset}>
|
|
135
|
-
<ark.fieldset {...mergedProps} />
|
|
146
|
+
<ark.fieldset {...mergedProps} ref={composeRefs(fieldset().refs.rootRef, props.ref)} />
|
|
136
147
|
</FieldsetProvider>;
|
|
137
148
|
};
|
|
138
149
|
FieldsetRoot.displayName = "FieldsetRoot";
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useFieldContext
|
|
3
|
-
} from "./
|
|
3
|
+
} from "./7HLG62OR.jsx";
|
|
4
4
|
import {
|
|
5
5
|
createSplitProps
|
|
6
6
|
} from "./6WEDGJKQ.jsx";
|
|
7
7
|
import {
|
|
8
8
|
ark
|
|
9
9
|
} from "./UFYZ7HLU.jsx";
|
|
10
|
-
import {
|
|
11
|
-
useLocaleContext
|
|
12
|
-
} from "./JFOWNFC7.jsx";
|
|
13
10
|
import {
|
|
14
11
|
useEnvironmentContext
|
|
15
12
|
} from "./CGW54HAQ.jsx";
|
|
13
|
+
import {
|
|
14
|
+
useLocaleContext
|
|
15
|
+
} from "./JFOWNFC7.jsx";
|
|
16
16
|
import {
|
|
17
17
|
runIfFn
|
|
18
18
|
} from "./KGOB2IMX.jsx";
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useFieldContext
|
|
3
|
-
} from "./
|
|
3
|
+
} from "./7HLG62OR.jsx";
|
|
4
4
|
import {
|
|
5
5
|
createSplitProps
|
|
6
6
|
} from "./6WEDGJKQ.jsx";
|
|
7
7
|
import {
|
|
8
8
|
ark
|
|
9
9
|
} from "./UFYZ7HLU.jsx";
|
|
10
|
-
import {
|
|
11
|
-
useLocaleContext
|
|
12
|
-
} from "./JFOWNFC7.jsx";
|
|
13
10
|
import {
|
|
14
11
|
useEnvironmentContext
|
|
15
12
|
} from "./CGW54HAQ.jsx";
|
|
13
|
+
import {
|
|
14
|
+
useLocaleContext
|
|
15
|
+
} from "./JFOWNFC7.jsx";
|
|
16
16
|
import {
|
|
17
17
|
runIfFn
|
|
18
18
|
} from "./KGOB2IMX.jsx";
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useFieldContext
|
|
3
|
-
} from "./
|
|
3
|
+
} from "./7HLG62OR.jsx";
|
|
4
4
|
import {
|
|
5
5
|
createSplitProps
|
|
6
6
|
} from "./6WEDGJKQ.jsx";
|
|
7
7
|
import {
|
|
8
8
|
ark
|
|
9
9
|
} from "./UFYZ7HLU.jsx";
|
|
10
|
-
import {
|
|
11
|
-
useLocaleContext
|
|
12
|
-
} from "./JFOWNFC7.jsx";
|
|
13
10
|
import {
|
|
14
11
|
useEnvironmentContext
|
|
15
12
|
} from "./CGW54HAQ.jsx";
|
|
13
|
+
import {
|
|
14
|
+
useLocaleContext
|
|
15
|
+
} from "./JFOWNFC7.jsx";
|
|
16
16
|
import {
|
|
17
17
|
runIfFn
|
|
18
18
|
} from "./KGOB2IMX.jsx";
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { useFieldsetContext } from './Z5ZRFFPU.js';
|
|
1
2
|
import { createSplitProps } from './ZMHI4GDJ.js';
|
|
2
3
|
import { ark } from './EPLBB4QN.js';
|
|
3
4
|
import { useEnvironmentContext } from './5QLLQM7E.js';
|
|
@@ -84,19 +85,28 @@ var useRadioGroup = (props) => {
|
|
|
84
85
|
const id = createUniqueId();
|
|
85
86
|
const locale = useLocaleContext();
|
|
86
87
|
const environment = useEnvironmentContext();
|
|
87
|
-
const
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
88
|
+
const fieldset = useFieldsetContext();
|
|
89
|
+
const machineProps = createMemo(() => {
|
|
90
|
+
const fieldsetContext = fieldset?.();
|
|
91
|
+
return {
|
|
92
|
+
id,
|
|
93
|
+
ids: {
|
|
94
|
+
label: fieldsetContext?.ids?.legend
|
|
95
|
+
},
|
|
96
|
+
dir: locale().dir,
|
|
97
|
+
disabled: fieldsetContext?.disabled,
|
|
98
|
+
invalid: fieldsetContext?.invalid,
|
|
99
|
+
getRootNode: environment().getRootNode,
|
|
100
|
+
...runIfFn(props)
|
|
101
|
+
};
|
|
102
|
+
});
|
|
93
103
|
const service = useMachine(radio.machine, machineProps);
|
|
94
104
|
return createMemo(() => radio.connect(service, normalizeProps));
|
|
95
105
|
};
|
|
96
106
|
|
|
97
107
|
// src/components/radio-group/radio-group-root.tsx
|
|
98
108
|
var RadioGroupRoot = (props) => {
|
|
99
|
-
const [useRadioGroupProps, localProps] = createSplitProps()(props, ["defaultValue", "disabled", "form", "id", "ids", "name", "onValueChange", "orientation", "readOnly", "value"]);
|
|
109
|
+
const [useRadioGroupProps, localProps] = createSplitProps()(props, ["defaultValue", "disabled", "form", "id", "ids", "invalid", "name", "onValueChange", "orientation", "readOnly", "required", "value"]);
|
|
100
110
|
const radioGroup = useRadioGroup(useRadioGroupProps);
|
|
101
111
|
const mergedProps = mergeProps(() => radioGroup().getRootProps(), localProps);
|
|
102
112
|
return createComponent(RadioGroupProvider, {
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import {
|
|
2
|
+
datePickerAnatomy
|
|
3
|
+
} from "./6UXNGS66.jsx";
|
|
1
4
|
import {
|
|
2
5
|
PresenceProvider,
|
|
3
6
|
splitPresenceProps,
|
|
@@ -7,21 +10,18 @@ import {
|
|
|
7
10
|
import {
|
|
8
11
|
composeRefs
|
|
9
12
|
} from "./PT2CJE3O.jsx";
|
|
10
|
-
import {
|
|
11
|
-
datePickerAnatomy
|
|
12
|
-
} from "./6UXNGS66.jsx";
|
|
13
13
|
import {
|
|
14
14
|
createSplitProps
|
|
15
15
|
} from "./6WEDGJKQ.jsx";
|
|
16
16
|
import {
|
|
17
17
|
ark
|
|
18
18
|
} from "./UFYZ7HLU.jsx";
|
|
19
|
-
import {
|
|
20
|
-
useLocaleContext
|
|
21
|
-
} from "./JFOWNFC7.jsx";
|
|
22
19
|
import {
|
|
23
20
|
useEnvironmentContext
|
|
24
21
|
} from "./CGW54HAQ.jsx";
|
|
22
|
+
import {
|
|
23
|
+
useLocaleContext
|
|
24
|
+
} from "./JFOWNFC7.jsx";
|
|
25
25
|
import {
|
|
26
26
|
runIfFn
|
|
27
27
|
} from "./KGOB2IMX.jsx";
|
|
@@ -206,6 +206,8 @@ var DatePickerRoot = (props) => {
|
|
|
206
206
|
"format",
|
|
207
207
|
"id",
|
|
208
208
|
"ids",
|
|
209
|
+
"inline",
|
|
210
|
+
"invalid",
|
|
209
211
|
"isDateUnavailable",
|
|
210
212
|
"locale",
|
|
211
213
|
"max",
|
|
@@ -214,23 +216,23 @@ var DatePickerRoot = (props) => {
|
|
|
214
216
|
"minView",
|
|
215
217
|
"name",
|
|
216
218
|
"numOfMonths",
|
|
217
|
-
"outsideDaySelectable",
|
|
218
219
|
"onFocusChange",
|
|
219
220
|
"onOpenChange",
|
|
220
221
|
"onValueChange",
|
|
221
222
|
"onViewChange",
|
|
222
223
|
"open",
|
|
224
|
+
"outsideDaySelectable",
|
|
223
225
|
"parse",
|
|
224
226
|
"placeholder",
|
|
225
227
|
"positioning",
|
|
226
228
|
"readOnly",
|
|
229
|
+
"required",
|
|
227
230
|
"selectionMode",
|
|
228
231
|
"startOfWeek",
|
|
229
232
|
"timeZone",
|
|
230
233
|
"translations",
|
|
231
234
|
"value",
|
|
232
|
-
"view"
|
|
233
|
-
"inline"
|
|
235
|
+
"view"
|
|
234
236
|
]);
|
|
235
237
|
const api = useDatePicker(useDatePickerProps);
|
|
236
238
|
const apiPresence = usePresence(mergeProps12(presenceProps, () => ({ present: api().open })));
|
|
@@ -4,12 +4,12 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
ark
|
|
6
6
|
} from "./UFYZ7HLU.jsx";
|
|
7
|
-
import {
|
|
8
|
-
useLocaleContext
|
|
9
|
-
} from "./JFOWNFC7.jsx";
|
|
10
7
|
import {
|
|
11
8
|
useEnvironmentContext
|
|
12
9
|
} from "./CGW54HAQ.jsx";
|
|
10
|
+
import {
|
|
11
|
+
useLocaleContext
|
|
12
|
+
} from "./JFOWNFC7.jsx";
|
|
13
13
|
import {
|
|
14
14
|
runIfFn
|
|
15
15
|
} from "./KGOB2IMX.jsx";
|
|
@@ -38,33 +38,49 @@ var PaginationEllipsis = (props) => {
|
|
|
38
38
|
return <ark.div {...mergedProps} />;
|
|
39
39
|
};
|
|
40
40
|
|
|
41
|
-
// src/components/pagination/pagination-
|
|
41
|
+
// src/components/pagination/pagination-first-trigger.tsx
|
|
42
42
|
import { mergeProps as mergeProps2 } from "@zag-js/solid";
|
|
43
|
+
var PaginationFirstTrigger = (props) => {
|
|
44
|
+
const api = usePaginationContext();
|
|
45
|
+
const mergedProps = mergeProps2(() => api().getFirstTriggerProps(), props);
|
|
46
|
+
return <ark.button {...mergedProps} />;
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
// src/components/pagination/pagination-item.tsx
|
|
50
|
+
import { mergeProps as mergeProps3 } from "@zag-js/solid";
|
|
43
51
|
var PaginationItem = (props) => {
|
|
44
52
|
const [itemProps, localProps] = createSplitProps()(props, ["value", "type"]);
|
|
45
53
|
const api = usePaginationContext();
|
|
46
|
-
const mergedProps =
|
|
54
|
+
const mergedProps = mergeProps3(() => api().getItemProps(itemProps), localProps);
|
|
55
|
+
return <ark.button {...mergedProps} />;
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
// src/components/pagination/pagination-last-trigger.tsx
|
|
59
|
+
import { mergeProps as mergeProps4 } from "@zag-js/solid";
|
|
60
|
+
var PaginationLastTrigger = (props) => {
|
|
61
|
+
const api = usePaginationContext();
|
|
62
|
+
const mergedProps = mergeProps4(() => api().getLastTriggerProps(), props);
|
|
47
63
|
return <ark.button {...mergedProps} />;
|
|
48
64
|
};
|
|
49
65
|
|
|
50
66
|
// src/components/pagination/pagination-next-trigger.tsx
|
|
51
|
-
import { mergeProps as
|
|
67
|
+
import { mergeProps as mergeProps5 } from "@zag-js/solid";
|
|
52
68
|
var PaginationNextTrigger = (props) => {
|
|
53
69
|
const api = usePaginationContext();
|
|
54
|
-
const mergedProps =
|
|
70
|
+
const mergedProps = mergeProps5(() => api().getNextTriggerProps(), props);
|
|
55
71
|
return <ark.button {...mergedProps} />;
|
|
56
72
|
};
|
|
57
73
|
|
|
58
74
|
// src/components/pagination/pagination-prev-trigger.tsx
|
|
59
|
-
import { mergeProps as
|
|
75
|
+
import { mergeProps as mergeProps6 } from "@zag-js/solid";
|
|
60
76
|
var PaginationPrevTrigger = (props) => {
|
|
61
77
|
const api = usePaginationContext();
|
|
62
|
-
const mergedProps =
|
|
78
|
+
const mergedProps = mergeProps6(() => api().getPrevTriggerProps(), props);
|
|
63
79
|
return <ark.button {...mergedProps} />;
|
|
64
80
|
};
|
|
65
81
|
|
|
66
82
|
// src/components/pagination/pagination-root.tsx
|
|
67
|
-
import { mergeProps as
|
|
83
|
+
import { mergeProps as mergeProps7 } from "@zag-js/solid";
|
|
68
84
|
|
|
69
85
|
// src/components/pagination/use-pagination.ts
|
|
70
86
|
import * as pagination from "@zag-js/pagination";
|
|
@@ -87,6 +103,7 @@ var usePagination = (props) => {
|
|
|
87
103
|
// src/components/pagination/pagination-root.tsx
|
|
88
104
|
var PaginationRoot = (props) => {
|
|
89
105
|
const [usePaginationProps, localProps] = createSplitProps()(props, [
|
|
106
|
+
"boundaryCount",
|
|
90
107
|
"count",
|
|
91
108
|
"defaultPage",
|
|
92
109
|
"defaultPageSize",
|
|
@@ -102,17 +119,17 @@ var PaginationRoot = (props) => {
|
|
|
102
119
|
"type"
|
|
103
120
|
]);
|
|
104
121
|
const api = usePagination(usePaginationProps);
|
|
105
|
-
const mergedProps =
|
|
122
|
+
const mergedProps = mergeProps7(() => api().getRootProps(), localProps);
|
|
106
123
|
return <PaginationProvider value={api}>
|
|
107
124
|
<ark.nav {...mergedProps} />
|
|
108
125
|
</PaginationProvider>;
|
|
109
126
|
};
|
|
110
127
|
|
|
111
128
|
// src/components/pagination/pagination-root-provider.tsx
|
|
112
|
-
import { mergeProps as
|
|
129
|
+
import { mergeProps as mergeProps8 } from "@zag-js/solid";
|
|
113
130
|
var PaginationRootProvider = (props) => {
|
|
114
131
|
const [{ value: pagination2 }, localProps] = createSplitProps()(props, ["value"]);
|
|
115
|
-
const mergedProps =
|
|
132
|
+
const mergedProps = mergeProps8(() => pagination2().getRootProps(), localProps);
|
|
116
133
|
return <PaginationProvider value={pagination2}>
|
|
117
134
|
<ark.nav {...mergedProps} />
|
|
118
135
|
</PaginationProvider>;
|
|
@@ -123,7 +140,9 @@ var pagination_exports = {};
|
|
|
123
140
|
__export(pagination_exports, {
|
|
124
141
|
Context: () => PaginationContext,
|
|
125
142
|
Ellipsis: () => PaginationEllipsis,
|
|
143
|
+
FirstTrigger: () => PaginationFirstTrigger,
|
|
126
144
|
Item: () => PaginationItem,
|
|
145
|
+
LastTrigger: () => PaginationLastTrigger,
|
|
127
146
|
NextTrigger: () => PaginationNextTrigger,
|
|
128
147
|
PrevTrigger: () => PaginationPrevTrigger,
|
|
129
148
|
Root: () => PaginationRoot,
|
|
@@ -134,7 +153,9 @@ export {
|
|
|
134
153
|
usePaginationContext,
|
|
135
154
|
PaginationContext,
|
|
136
155
|
PaginationEllipsis,
|
|
156
|
+
PaginationFirstTrigger,
|
|
137
157
|
PaginationItem,
|
|
158
|
+
PaginationLastTrigger,
|
|
138
159
|
PaginationNextTrigger,
|
|
139
160
|
PaginationPrevTrigger,
|
|
140
161
|
usePagination,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
collapsible_exports,
|
|
3
3
|
useCollapsibleContext
|
|
4
|
-
} from "./
|
|
4
|
+
} from "./UOOMXEJO.jsx";
|
|
5
5
|
import {
|
|
6
6
|
RenderStrategyProvider,
|
|
7
7
|
splitRenderStrategyProps,
|
|
@@ -13,12 +13,12 @@ import {
|
|
|
13
13
|
import {
|
|
14
14
|
ark
|
|
15
15
|
} from "./UFYZ7HLU.jsx";
|
|
16
|
-
import {
|
|
17
|
-
useLocaleContext
|
|
18
|
-
} from "./JFOWNFC7.jsx";
|
|
19
16
|
import {
|
|
20
17
|
useEnvironmentContext
|
|
21
18
|
} from "./CGW54HAQ.jsx";
|
|
19
|
+
import {
|
|
20
|
+
useLocaleContext
|
|
21
|
+
} from "./JFOWNFC7.jsx";
|
|
22
22
|
import {
|
|
23
23
|
runIfFn
|
|
24
24
|
} from "./KGOB2IMX.jsx";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { anatomy } from '@zag-js/navigation-menu';
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useFieldContext
|
|
3
|
-
} from "./
|
|
3
|
+
} from "./7HLG62OR.jsx";
|
|
4
4
|
import {
|
|
5
5
|
createSplitProps
|
|
6
6
|
} from "./6WEDGJKQ.jsx";
|
|
7
7
|
import {
|
|
8
8
|
ark
|
|
9
9
|
} from "./UFYZ7HLU.jsx";
|
|
10
|
-
import {
|
|
11
|
-
useLocaleContext
|
|
12
|
-
} from "./JFOWNFC7.jsx";
|
|
13
10
|
import {
|
|
14
11
|
useEnvironmentContext
|
|
15
12
|
} from "./CGW54HAQ.jsx";
|
|
13
|
+
import {
|
|
14
|
+
useLocaleContext
|
|
15
|
+
} from "./JFOWNFC7.jsx";
|
|
16
16
|
import {
|
|
17
17
|
runIfFn
|
|
18
18
|
} from "./KGOB2IMX.jsx";
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useFieldContext
|
|
3
|
-
} from "./
|
|
3
|
+
} from "./7HLG62OR.jsx";
|
|
4
4
|
import {
|
|
5
5
|
createSplitProps
|
|
6
6
|
} from "./6WEDGJKQ.jsx";
|
|
7
7
|
import {
|
|
8
8
|
ark
|
|
9
9
|
} from "./UFYZ7HLU.jsx";
|
|
10
|
-
import {
|
|
11
|
-
useLocaleContext
|
|
12
|
-
} from "./JFOWNFC7.jsx";
|
|
13
10
|
import {
|
|
14
11
|
useEnvironmentContext
|
|
15
12
|
} from "./CGW54HAQ.jsx";
|
|
13
|
+
import {
|
|
14
|
+
useLocaleContext
|
|
15
|
+
} from "./JFOWNFC7.jsx";
|
|
16
16
|
import {
|
|
17
17
|
runIfFn
|
|
18
18
|
} from "./KGOB2IMX.jsx";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { useFieldContext } from './
|
|
1
|
+
import { useFieldContext } from './GBGTOFYC.js';
|
|
2
2
|
import { createSplitProps } from './ZMHI4GDJ.js';
|
|
3
3
|
import { ark } from './EPLBB4QN.js';
|
|
4
4
|
import { useEnvironmentContext } from './5QLLQM7E.js';
|
|
@@ -75,7 +75,7 @@ var useNumberInput = (props) => {
|
|
|
75
75
|
|
|
76
76
|
// src/components/number-input/number-input-root.tsx
|
|
77
77
|
var NumberInputRoot = (props) => {
|
|
78
|
-
const [useNumberInputProps, localProps] = createSplitProps()(props, ["allowMouseWheel", "allowOverflow", "clampValueOnBlur", "defaultValue", "disabled", "focusInputOnChange", "form", "formatOptions", "id", "ids", "inputMode", "invalid", "locale", "max", "min", "name", "onFocusChange", "onValueChange", "onValueInvalid", "pattern", "readOnly", "required", "spinOnPress", "step", "translations", "value"]);
|
|
78
|
+
const [useNumberInputProps, localProps] = createSplitProps()(props, ["allowMouseWheel", "allowOverflow", "clampValueOnBlur", "defaultValue", "disabled", "focusInputOnChange", "form", "formatOptions", "id", "ids", "inputMode", "invalid", "locale", "max", "min", "name", "onFocusChange", "onValueChange", "onValueCommit", "onValueInvalid", "pattern", "readOnly", "required", "spinOnPress", "step", "translations", "value"]);
|
|
79
79
|
const api = useNumberInput(useNumberInputProps);
|
|
80
80
|
const mergedProps = mergeProps(() => api().getRootProps(), localProps);
|
|
81
81
|
return createComponent(NumberInputProvider, {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { composeRefs } from './ROP6QZQ7.js';
|
|
1
2
|
import { parts } from './FCMJTSIR.js';
|
|
2
3
|
import { createSplitProps } from './ZMHI4GDJ.js';
|
|
3
4
|
import { ark } from './EPLBB4QN.js';
|
|
@@ -5,9 +6,9 @@ import { useEnvironmentContext } from './5QLLQM7E.js';
|
|
|
5
6
|
import { runIfFn } from './DT73WLR4.js';
|
|
6
7
|
import { createContext } from './THN5C4U6.js';
|
|
7
8
|
import { __export } from './ESLJRKWD.js';
|
|
8
|
-
import { createComponent } from 'solid-js/web';
|
|
9
|
+
import { createComponent, mergeProps as mergeProps$1 } from 'solid-js/web';
|
|
9
10
|
import { mergeProps } from '@zag-js/solid';
|
|
10
|
-
import { Show, mergeProps as mergeProps$
|
|
11
|
+
import { Show, mergeProps as mergeProps$2, createSignal, createUniqueId, onMount, onCleanup, createMemo } from 'solid-js';
|
|
11
12
|
import { dataAttr } from '@zag-js/dom-query';
|
|
12
13
|
|
|
13
14
|
// src/components/fieldset/use-fieldset-context.ts
|
|
@@ -42,28 +43,42 @@ var FieldsetLegend = (props) => {
|
|
|
42
43
|
return createComponent(ark.legend, mergedProps);
|
|
43
44
|
};
|
|
44
45
|
var useFieldset = (props) => {
|
|
45
|
-
useEnvironmentContext();
|
|
46
|
-
const mergedProps = mergeProps$
|
|
47
|
-
|
|
46
|
+
const env = useEnvironmentContext();
|
|
47
|
+
const mergedProps = mergeProps$2({ disabled: false, invalid: false }, runIfFn(props));
|
|
48
|
+
const [rootRef, setRootRef] = createSignal(void 0);
|
|
48
49
|
const id = mergedProps.id ?? createUniqueId();
|
|
49
50
|
const legendId = `fieldset::${id}::legend`;
|
|
50
51
|
const errorTextId = `fieldset::${id}::error-text`;
|
|
51
52
|
const helperTextId = `fieldset::${id}::helper-text`;
|
|
52
|
-
const [hasErrorText] = createSignal(false);
|
|
53
|
-
const [hasHelperText] = createSignal(false);
|
|
54
|
-
|
|
55
|
-
|
|
53
|
+
const [hasErrorText, setHasErrorText] = createSignal(false);
|
|
54
|
+
const [hasHelperText, setHasHelperText] = createSignal(false);
|
|
55
|
+
onMount(() => {
|
|
56
|
+
const rootNode = rootRef();
|
|
57
|
+
if (!rootNode) return;
|
|
58
|
+
const checkTextElements = () => {
|
|
59
|
+
const docOrShadowRoot = env().getRootNode();
|
|
60
|
+
setHasErrorText(!!docOrShadowRoot.getElementById(errorTextId));
|
|
61
|
+
setHasHelperText(!!docOrShadowRoot.getElementById(helperTextId));
|
|
62
|
+
};
|
|
63
|
+
checkTextElements();
|
|
64
|
+
const win = env().getWindow();
|
|
65
|
+
const observer = new win.MutationObserver(checkTextElements);
|
|
66
|
+
observer.observe(rootNode, { childList: true, subtree: true });
|
|
67
|
+
onCleanup(() => observer.disconnect());
|
|
68
|
+
});
|
|
69
|
+
const labelIds = createMemo(() => {
|
|
70
|
+
const ids = [];
|
|
71
|
+
if (hasErrorText() && mergedProps.invalid) ids.push(errorTextId);
|
|
72
|
+
if (hasHelperText()) ids.push(helperTextId);
|
|
73
|
+
return ids;
|
|
56
74
|
});
|
|
57
|
-
const labelIds = [];
|
|
58
|
-
if (hasErrorText() && mergedProps.invalid) labelIds.push(errorTextId);
|
|
59
|
-
if (hasHelperText()) labelIds.push(helperTextId);
|
|
60
75
|
const getRootProps = () => ({
|
|
61
76
|
...parts.root.attrs,
|
|
62
77
|
disabled: mergedProps.disabled,
|
|
63
78
|
"data-disabled": dataAttr(mergedProps.disabled),
|
|
64
79
|
"data-invalid": dataAttr(mergedProps.invalid),
|
|
65
80
|
"aria-labelledby": legendId,
|
|
66
|
-
"aria-describedby": labelIds.join(" ") || void 0
|
|
81
|
+
"aria-describedby": labelIds().join(" ") || void 0
|
|
67
82
|
});
|
|
68
83
|
const getLegendProps = () => ({
|
|
69
84
|
id: legendId,
|
|
@@ -82,7 +97,12 @@ var useFieldset = (props) => {
|
|
|
82
97
|
});
|
|
83
98
|
return createMemo(() => ({
|
|
84
99
|
refs: {
|
|
85
|
-
rootRef
|
|
100
|
+
rootRef: setRootRef
|
|
101
|
+
},
|
|
102
|
+
ids: {
|
|
103
|
+
legend: legendId,
|
|
104
|
+
errorText: errorTextId,
|
|
105
|
+
helperText: helperTextId
|
|
86
106
|
},
|
|
87
107
|
disabled: mergedProps.disabled,
|
|
88
108
|
invalid: mergedProps.invalid,
|
|
@@ -101,7 +121,12 @@ var FieldsetRoot = (props) => {
|
|
|
101
121
|
return createComponent(FieldsetProvider, {
|
|
102
122
|
value: fieldset,
|
|
103
123
|
get children() {
|
|
104
|
-
return createComponent(ark.fieldset, mergedProps
|
|
124
|
+
return createComponent(ark.fieldset, mergeProps$1(mergedProps, {
|
|
125
|
+
ref(r$) {
|
|
126
|
+
var _ref$ = composeRefs(fieldset().refs.rootRef, props.ref);
|
|
127
|
+
typeof _ref$ === "function" && _ref$(r$);
|
|
128
|
+
}
|
|
129
|
+
}));
|
|
105
130
|
}
|
|
106
131
|
});
|
|
107
132
|
};
|
|
@@ -159,7 +159,7 @@ var useDatePicker = (props) => {
|
|
|
159
159
|
// src/components/date-picker/date-picker-root.tsx
|
|
160
160
|
var DatePickerRoot = (props) => {
|
|
161
161
|
const [presenceProps, datePickerProps] = splitPresenceProps(props);
|
|
162
|
-
const [useDatePickerProps, localProps] = createSplitProps()(datePickerProps, ["closeOnSelect", "defaultFocusedValue", "defaultOpen", "defaultValue", "defaultView", "disabled", "fixedWeeks", "focusedValue", "format", "id", "ids", "isDateUnavailable", "locale", "max", "maxView", "min", "minView", "name", "numOfMonths", "
|
|
162
|
+
const [useDatePickerProps, localProps] = createSplitProps()(datePickerProps, ["closeOnSelect", "defaultFocusedValue", "defaultOpen", "defaultValue", "defaultView", "disabled", "fixedWeeks", "focusedValue", "format", "id", "ids", "inline", "invalid", "isDateUnavailable", "locale", "max", "maxView", "min", "minView", "name", "numOfMonths", "onFocusChange", "onOpenChange", "onValueChange", "onViewChange", "open", "outsideDaySelectable", "parse", "placeholder", "positioning", "readOnly", "required", "selectionMode", "startOfWeek", "timeZone", "translations", "value", "view"]);
|
|
163
163
|
const api = useDatePicker(useDatePickerProps);
|
|
164
164
|
const apiPresence = usePresence(mergeProps(presenceProps, () => ({
|
|
165
165
|
present: api().open
|