@ark-ui/solid 5.25.0 → 5.25.1
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/{checkbox.anatomy-CuzDSmDj.d.ts → checkbox.anatomy-YlC7nNXs.d.ts} +1 -1
- package/dist/chunk/2R6SK2X3.js +1 -0
- package/dist/chunk/{BSNUALOI.jsx → 3DVV7RSQ.jsx} +1 -1
- package/dist/chunk/{GXTZJORW.jsx → 4FGVJWA3.jsx} +1 -1
- package/dist/chunk/{GYZIX2L5.jsx → 4MVVOEQO.jsx} +1 -1
- package/dist/chunk/{4GP7G5GU.jsx → 5ERIBIYY.jsx} +1 -1
- package/dist/chunk/{JILQVPOB.jsx → 5STEWKY6.jsx} +1 -1
- package/dist/chunk/5Y4OZGVJ.jsx +231 -0
- package/dist/chunk/7FCJ264O.js +2 -2
- package/dist/chunk/{D4ONWUSA.jsx → AXR7KJPM.jsx} +1 -1
- package/dist/chunk/{4QGNGFEY.jsx → EKMENCH5.jsx} +1 -1
- package/dist/chunk/F2QWYZEN.js +178 -0
- package/dist/chunk/{3TIJNVWF.jsx → G5ZFI73B.jsx} +1 -1
- package/dist/chunk/{Y73674NQ.jsx → H5NQWWX6.jsx} +1 -1
- package/dist/chunk/{TSTI54MO.jsx → PVLPVADA.jsx} +1 -1
- package/dist/chunk/{QHUHQ7AB.jsx → QA6UN3SS.jsx} +1 -1
- package/dist/chunk/{YDC3FJFI.jsx → QTCH6M6U.jsx} +1 -1
- package/dist/chunk/WMZBRARY.jsx +6 -0
- package/dist/chunk/{MQ2S3D55.jsx → YL3RNWHK.jsx} +1 -1
- package/dist/{color-picker.anatomy-CMDtAoEh.d.ts → color-picker.anatomy-Dxw1DJ2S.d.ts} +1 -1
- package/dist/{combobox.anatomy-DBsVyPqM.d.ts → combobox.anatomy-CW3VXK4N.d.ts} +1 -1
- package/dist/components/anatomy.d.ts +9 -8
- package/dist/components/anatomy.js +16 -15
- package/dist/components/anatomy.jsx +79 -75
- package/dist/components/bottom-sheet/index.d.ts +92 -0
- package/dist/components/bottom-sheet/index.js +2 -0
- package/dist/components/bottom-sheet/index.jsx +45 -0
- package/dist/components/checkbox/index.d.ts +1 -1
- package/dist/components/checkbox/index.jsx +3 -3
- package/dist/components/color-picker/index.d.ts +1 -1
- package/dist/components/color-picker/index.jsx +3 -3
- package/dist/components/combobox/index.d.ts +1 -1
- package/dist/components/combobox/index.jsx +7 -7
- package/dist/components/date-picker/index.d.ts +1 -1
- package/dist/components/editable/index.jsx +3 -3
- package/dist/components/field/index.d.ts +1 -1
- package/dist/components/field/index.jsx +2 -2
- package/dist/components/fieldset/index.d.ts +1 -1
- package/dist/components/file-upload/index.jsx +3 -3
- package/dist/components/format/index.d.ts +4 -0
- package/dist/components/index.d.ts +10 -8
- package/dist/components/index.js +36 -34
- package/dist/components/index.jsx +367 -335
- package/dist/components/json-tree-view/index.jsx +2 -2
- package/dist/components/listbox/index.d.ts +1 -1
- package/dist/components/listbox/index.jsx +1 -1
- package/dist/components/number-input/index.jsx +3 -3
- package/dist/components/password-input/index.jsx +3 -3
- package/dist/components/pin-input/index.jsx +3 -3
- package/dist/components/rating-group/index.jsx +3 -3
- package/dist/components/select/index.jsx +7 -7
- package/dist/components/signature-pad/index.jsx +3 -3
- package/dist/components/switch/index.jsx +3 -3
- package/dist/components/tags-input/index.jsx +3 -3
- package/dist/components/tour/index.d.ts +1 -1
- package/dist/components/tree-view/index.jsx +3 -3
- package/dist/{date-picker.anatomy-C7QaSOwg.d.ts → date-picker.anatomy-DLXcqHH9.d.ts} +1 -1
- package/dist/field.anatomy-BA_rbPae.d.ts +5 -0
- package/dist/{fieldset.anatomy-BHBXaVuM.d.ts → fieldset.anatomy-ByHwSFid.d.ts} +1 -1
- package/dist/index.d.ts +10 -8
- package/dist/index.js +36 -34
- package/dist/index.jsx +367 -335
- package/dist/{listbox.anatomy-CuSvGz29.d.ts → listbox.anatomy-ogRrsXMY.d.ts} +1 -1
- package/dist/{tour.anatomy-dhFVCgSh.d.ts → tour.anatomy-LyAf9UF9.d.ts} +1 -1
- package/package.json +66 -65
- package/dist/field.anatomy-BkeW0gbI.d.ts +0 -5
- package/dist/chunk/{HRWYG4MB.jsx → 5XTAFT5P.jsx} +0 -0
- package/dist/chunk/{4GQ4Q3XI.jsx → 7SG5GQHN.jsx} +3 -3
- package/dist/chunk/{LL2PRNHK.jsx → BH37SJGO.jsx} +3 -3
- /package/dist/chunk/{5WVPNAWS.js → W6MHACH4.js} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _zag_js_anatomy from '@zag-js/anatomy';
|
|
2
2
|
|
|
3
|
-
declare const checkboxAnatomy: _zag_js_anatomy.AnatomyInstance<"label" | "
|
|
3
|
+
declare const checkboxAnatomy: _zag_js_anatomy.AnatomyInstance<"label" | "group" | "root" | "control" | "indicator">;
|
|
4
4
|
|
|
5
5
|
export { checkboxAnatomy as c };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { anatomy } from '@zag-js/bottom-sheet';
|
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
import {
|
|
2
|
+
PresenceProvider,
|
|
3
|
+
splitPresenceProps,
|
|
4
|
+
usePresence,
|
|
5
|
+
usePresenceContext
|
|
6
|
+
} from "./VA3VRJ56.jsx";
|
|
7
|
+
import {
|
|
8
|
+
RenderStrategyProvider,
|
|
9
|
+
splitRenderStrategyProps,
|
|
10
|
+
useRenderStrategyContext
|
|
11
|
+
} from "./NEBB7COJ.jsx";
|
|
12
|
+
import {
|
|
13
|
+
composeRefs
|
|
14
|
+
} from "./PT2CJE3O.jsx";
|
|
15
|
+
import {
|
|
16
|
+
createSplitProps
|
|
17
|
+
} from "./6WEDGJKQ.jsx";
|
|
18
|
+
import {
|
|
19
|
+
ark
|
|
20
|
+
} from "./UFYZ7HLU.jsx";
|
|
21
|
+
import {
|
|
22
|
+
useEnvironmentContext
|
|
23
|
+
} from "./6J5H27AQ.jsx";
|
|
24
|
+
import {
|
|
25
|
+
runIfFn
|
|
26
|
+
} from "./KGOB2IMX.jsx";
|
|
27
|
+
import {
|
|
28
|
+
useLocaleContext
|
|
29
|
+
} from "./XIYHIOP3.jsx";
|
|
30
|
+
import {
|
|
31
|
+
createContext
|
|
32
|
+
} from "./TVCIHLER.jsx";
|
|
33
|
+
import {
|
|
34
|
+
__export
|
|
35
|
+
} from "./7IUG3E2V.jsx";
|
|
36
|
+
|
|
37
|
+
// src/components/bottom-sheet/bottom-sheet-backdrop.tsx
|
|
38
|
+
import { mergeProps } from "@zag-js/solid";
|
|
39
|
+
import { Show } from "solid-js";
|
|
40
|
+
|
|
41
|
+
// src/components/bottom-sheet/use-bottom-sheet-context.ts
|
|
42
|
+
var [BottomSheetProvider, useBottomSheetContext] = createContext({
|
|
43
|
+
hookName: "useBottomSheetContext",
|
|
44
|
+
providerName: "<BottomSheetProvider />"
|
|
45
|
+
});
|
|
46
|
+
|
|
47
|
+
// src/components/bottom-sheet/bottom-sheet-backdrop.tsx
|
|
48
|
+
var BottomSheetBackdrop = (props) => {
|
|
49
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
50
|
+
const renderStrategyProps = useRenderStrategyContext();
|
|
51
|
+
const presence = usePresence(mergeProps(renderStrategyProps, () => ({ present: bottomSheet2().open })));
|
|
52
|
+
const mergedProps = mergeProps(
|
|
53
|
+
() => bottomSheet2().getBackdropProps(),
|
|
54
|
+
() => presence().presenceProps,
|
|
55
|
+
props
|
|
56
|
+
);
|
|
57
|
+
return <Show when={!presence().unmounted}>
|
|
58
|
+
<ark.div {...mergedProps} ref={composeRefs(presence().ref, props.ref)} />
|
|
59
|
+
</Show>;
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
// src/components/bottom-sheet/bottom-sheet-close-trigger.tsx
|
|
63
|
+
import { mergeProps as mergeProps2 } from "@zag-js/solid";
|
|
64
|
+
var BottomSheetCloseTrigger = (props) => {
|
|
65
|
+
const context = useBottomSheetContext();
|
|
66
|
+
const mergedProps = mergeProps2(() => context().getCloseTriggerProps(), props);
|
|
67
|
+
return <ark.button {...mergedProps} />;
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
// src/components/bottom-sheet/bottom-sheet-content.tsx
|
|
71
|
+
import { mergeProps as mergeProps3 } from "@zag-js/solid";
|
|
72
|
+
import { Show as Show2 } from "solid-js";
|
|
73
|
+
var BottomSheetContent = (props) => {
|
|
74
|
+
const [contentProps, localProps] = createSplitProps()(props, ["draggable"]);
|
|
75
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
76
|
+
const presence = usePresenceContext();
|
|
77
|
+
const mergedProps = mergeProps3(
|
|
78
|
+
() => bottomSheet2().getContentProps({ draggable: true, ...contentProps }),
|
|
79
|
+
() => presence().presenceProps,
|
|
80
|
+
localProps
|
|
81
|
+
);
|
|
82
|
+
return <Show2 when={!presence().unmounted}>
|
|
83
|
+
<ark.div {...mergedProps} ref={composeRefs(presence().ref, localProps.ref)} />
|
|
84
|
+
</Show2>;
|
|
85
|
+
};
|
|
86
|
+
|
|
87
|
+
// src/components/bottom-sheet/bottom-sheet-context.tsx
|
|
88
|
+
var BottomSheetContext = (props) => props.children(useBottomSheetContext());
|
|
89
|
+
|
|
90
|
+
// src/components/bottom-sheet/bottom-sheet-grabber.tsx
|
|
91
|
+
import { mergeProps as mergeProps4 } from "@zag-js/solid";
|
|
92
|
+
var BottomSheetGrabber = (props) => {
|
|
93
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
94
|
+
const mergedProps = mergeProps4(() => bottomSheet2().getGrabberProps(), props);
|
|
95
|
+
return <ark.div {...mergedProps} />;
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
// src/components/bottom-sheet/bottom-sheet-grabber-indicator.tsx
|
|
99
|
+
import { mergeProps as mergeProps5 } from "@zag-js/solid";
|
|
100
|
+
var BottomSheetGrabberIndicator = (props) => {
|
|
101
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
102
|
+
const mergedProps = mergeProps5(() => bottomSheet2().getGrabberIndicatorProps(), props);
|
|
103
|
+
return <ark.div {...mergedProps} />;
|
|
104
|
+
};
|
|
105
|
+
|
|
106
|
+
// src/components/bottom-sheet/bottom-sheet-root.tsx
|
|
107
|
+
import { mergeProps as mergeProps6 } from "@zag-js/solid";
|
|
108
|
+
|
|
109
|
+
// src/components/bottom-sheet/use-bottom-sheet.ts
|
|
110
|
+
import * as bottomSheet from "@zag-js/bottom-sheet";
|
|
111
|
+
import { normalizeProps, useMachine } from "@zag-js/solid";
|
|
112
|
+
import { createMemo, createUniqueId } from "solid-js";
|
|
113
|
+
var useBottomSheet = (props) => {
|
|
114
|
+
const locale = useLocaleContext();
|
|
115
|
+
const environment = useEnvironmentContext();
|
|
116
|
+
const id = createUniqueId();
|
|
117
|
+
const machineProps = createMemo(() => ({
|
|
118
|
+
id,
|
|
119
|
+
dir: locale().dir,
|
|
120
|
+
getRootNode: environment().getRootNode,
|
|
121
|
+
...runIfFn(props)
|
|
122
|
+
}));
|
|
123
|
+
const service = useMachine(bottomSheet.machine, machineProps);
|
|
124
|
+
return createMemo(() => bottomSheet.connect(service, normalizeProps));
|
|
125
|
+
};
|
|
126
|
+
|
|
127
|
+
// src/components/bottom-sheet/bottom-sheet-root.tsx
|
|
128
|
+
var BottomSheetRoot = (props) => {
|
|
129
|
+
const [presenceProps, bottomSheetProps] = splitPresenceProps(props);
|
|
130
|
+
const [renderStrategyProps] = splitRenderStrategyProps(presenceProps);
|
|
131
|
+
const [useBottomSheetProps, localProps] = createSplitProps()(bottomSheetProps, [
|
|
132
|
+
"id",
|
|
133
|
+
"ids",
|
|
134
|
+
"open",
|
|
135
|
+
"defaultOpen",
|
|
136
|
+
"onOpenChange",
|
|
137
|
+
"closeOnInteractOutside",
|
|
138
|
+
"closeOnEscape",
|
|
139
|
+
"snapPoints",
|
|
140
|
+
"swipeVelocityThreshold",
|
|
141
|
+
"closeThreshold",
|
|
142
|
+
"preventDragOnScroll",
|
|
143
|
+
"activeSnapPoint",
|
|
144
|
+
"defaultActiveSnapPoint",
|
|
145
|
+
"onActiveSnapPointChange",
|
|
146
|
+
"modal",
|
|
147
|
+
"trapFocus",
|
|
148
|
+
"restoreFocus",
|
|
149
|
+
"preventScroll",
|
|
150
|
+
"initialFocusEl",
|
|
151
|
+
"finalFocusEl",
|
|
152
|
+
"role",
|
|
153
|
+
"onInteractOutside",
|
|
154
|
+
"onEscapeKeyDown",
|
|
155
|
+
"onPointerDownOutside",
|
|
156
|
+
"onFocusOutside",
|
|
157
|
+
"onRequestDismiss"
|
|
158
|
+
]);
|
|
159
|
+
const bottomSheet2 = useBottomSheet(useBottomSheetProps);
|
|
160
|
+
const presence = usePresence(mergeProps6(presenceProps, () => ({ present: bottomSheet2().open })));
|
|
161
|
+
return <BottomSheetProvider value={bottomSheet2}>
|
|
162
|
+
<RenderStrategyProvider value={renderStrategyProps}>
|
|
163
|
+
<PresenceProvider value={presence}>{localProps.children}</PresenceProvider>
|
|
164
|
+
</RenderStrategyProvider>
|
|
165
|
+
</BottomSheetProvider>;
|
|
166
|
+
};
|
|
167
|
+
|
|
168
|
+
// src/components/bottom-sheet/bottom-sheet-root-provider.tsx
|
|
169
|
+
import { mergeProps as mergeProps7 } from "@zag-js/solid";
|
|
170
|
+
var BottomSheetRootProvider = (props) => {
|
|
171
|
+
const [presenceProps, bottomSheetProps] = splitPresenceProps(props);
|
|
172
|
+
const [renderStrategyProps] = splitRenderStrategyProps(presenceProps);
|
|
173
|
+
const presence = usePresence(mergeProps7(() => ({ present: bottomSheetProps.value().open }), presenceProps));
|
|
174
|
+
return <BottomSheetProvider value={bottomSheetProps.value}>
|
|
175
|
+
<RenderStrategyProvider value={renderStrategyProps}>
|
|
176
|
+
<PresenceProvider value={presence}>{bottomSheetProps.children}</PresenceProvider>
|
|
177
|
+
</RenderStrategyProvider>
|
|
178
|
+
</BottomSheetProvider>;
|
|
179
|
+
};
|
|
180
|
+
|
|
181
|
+
// src/components/bottom-sheet/bottom-sheet-title.tsx
|
|
182
|
+
import { mergeProps as mergeProps8 } from "@zag-js/solid";
|
|
183
|
+
var BottomSheetTitle = (props) => {
|
|
184
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
185
|
+
const mergedProps = mergeProps8(() => bottomSheet2().getTitleProps(), props);
|
|
186
|
+
return <ark.h2 {...mergedProps} />;
|
|
187
|
+
};
|
|
188
|
+
|
|
189
|
+
// src/components/bottom-sheet/bottom-sheet-trigger.tsx
|
|
190
|
+
import { mergeProps as mergeProps9 } from "@zag-js/solid";
|
|
191
|
+
var BottomSheetTrigger = (props) => {
|
|
192
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
193
|
+
const presence = usePresenceContext();
|
|
194
|
+
const mergedProps = mergeProps9(
|
|
195
|
+
() => bottomSheet2().getTriggerProps(),
|
|
196
|
+
() => ({ "aria-controls": presence().unmounted && null }),
|
|
197
|
+
props
|
|
198
|
+
);
|
|
199
|
+
return <ark.button {...mergedProps} />;
|
|
200
|
+
};
|
|
201
|
+
|
|
202
|
+
// src/components/bottom-sheet/bottom-sheet.ts
|
|
203
|
+
var bottom_sheet_exports = {};
|
|
204
|
+
__export(bottom_sheet_exports, {
|
|
205
|
+
Backdrop: () => BottomSheetBackdrop,
|
|
206
|
+
CloseTrigger: () => BottomSheetCloseTrigger,
|
|
207
|
+
Content: () => BottomSheetContent,
|
|
208
|
+
Context: () => BottomSheetContext,
|
|
209
|
+
Grabber: () => BottomSheetGrabber,
|
|
210
|
+
GrabberIndicator: () => BottomSheetGrabberIndicator,
|
|
211
|
+
Root: () => BottomSheetRoot,
|
|
212
|
+
RootProvider: () => BottomSheetRootProvider,
|
|
213
|
+
Title: () => BottomSheetTitle,
|
|
214
|
+
Trigger: () => BottomSheetTrigger
|
|
215
|
+
});
|
|
216
|
+
|
|
217
|
+
export {
|
|
218
|
+
useBottomSheetContext,
|
|
219
|
+
BottomSheetBackdrop,
|
|
220
|
+
BottomSheetCloseTrigger,
|
|
221
|
+
BottomSheetContent,
|
|
222
|
+
BottomSheetContext,
|
|
223
|
+
BottomSheetGrabber,
|
|
224
|
+
BottomSheetGrabberIndicator,
|
|
225
|
+
useBottomSheet,
|
|
226
|
+
BottomSheetRoot,
|
|
227
|
+
BottomSheetRootProvider,
|
|
228
|
+
BottomSheetTitle,
|
|
229
|
+
BottomSheetTrigger,
|
|
230
|
+
bottom_sheet_exports
|
|
231
|
+
};
|
package/dist/chunk/7FCJ264O.js
CHANGED
|
@@ -49,8 +49,8 @@ var useFieldset = (props) => {
|
|
|
49
49
|
const legendId = `fieldset::${id}::legend`;
|
|
50
50
|
const errorTextId = `fieldset::${id}::error-text`;
|
|
51
51
|
const helperTextId = `fieldset::${id}::helper-text`;
|
|
52
|
-
const [hasErrorText
|
|
53
|
-
const [hasHelperText
|
|
52
|
+
const [hasErrorText] = createSignal(false);
|
|
53
|
+
const [hasHelperText] = createSignal(false);
|
|
54
54
|
createEffect(() => {
|
|
55
55
|
return;
|
|
56
56
|
});
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
import { usePresenceContext, splitPresenceProps, usePresence, PresenceProvider } from './PKGJ2YMV.js';
|
|
2
|
+
import { composeRefs } from './ROP6QZQ7.js';
|
|
3
|
+
import { splitRenderStrategyProps, RenderStrategyProvider, useRenderStrategyContext } from './QFAL6GWC.js';
|
|
4
|
+
import { createSplitProps } from './ZMHI4GDJ.js';
|
|
5
|
+
import { ark } from './EPLBB4QN.js';
|
|
6
|
+
import { useEnvironmentContext } from './QM3ROTYU.js';
|
|
7
|
+
import { useLocaleContext } from './JOLWKIPW.js';
|
|
8
|
+
import { runIfFn } from './DT73WLR4.js';
|
|
9
|
+
import { createContext } from './TROPIN4C.js';
|
|
10
|
+
import { __export } from './ESLJRKWD.js';
|
|
11
|
+
import { createComponent, mergeProps as mergeProps$1 } from 'solid-js/web';
|
|
12
|
+
import { mergeProps, useMachine, normalizeProps } from '@zag-js/solid';
|
|
13
|
+
import { Show, createUniqueId, createMemo } from 'solid-js';
|
|
14
|
+
import * as bottomSheet from '@zag-js/bottom-sheet';
|
|
15
|
+
|
|
16
|
+
// src/components/bottom-sheet/use-bottom-sheet-context.ts
|
|
17
|
+
var [BottomSheetProvider, useBottomSheetContext] = createContext({
|
|
18
|
+
hookName: "useBottomSheetContext",
|
|
19
|
+
providerName: "<BottomSheetProvider />"
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
// src/components/bottom-sheet/bottom-sheet-backdrop.tsx
|
|
23
|
+
var BottomSheetBackdrop = (props) => {
|
|
24
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
25
|
+
const renderStrategyProps = useRenderStrategyContext();
|
|
26
|
+
const presence = usePresence(mergeProps(renderStrategyProps, () => ({
|
|
27
|
+
present: bottomSheet2().open
|
|
28
|
+
})));
|
|
29
|
+
const mergedProps = mergeProps(() => bottomSheet2().getBackdropProps(), () => presence().presenceProps, props);
|
|
30
|
+
return createComponent(Show, {
|
|
31
|
+
get when() {
|
|
32
|
+
return !presence().unmounted;
|
|
33
|
+
},
|
|
34
|
+
get children() {
|
|
35
|
+
return createComponent(ark.div, mergeProps$1(mergedProps, {
|
|
36
|
+
ref(r$) {
|
|
37
|
+
var _ref$ = composeRefs(presence().ref, props.ref);
|
|
38
|
+
typeof _ref$ === "function" && _ref$(r$);
|
|
39
|
+
}
|
|
40
|
+
}));
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
};
|
|
44
|
+
var BottomSheetCloseTrigger = (props) => {
|
|
45
|
+
const context = useBottomSheetContext();
|
|
46
|
+
const mergedProps = mergeProps(() => context().getCloseTriggerProps(), props);
|
|
47
|
+
return createComponent(ark.button, mergedProps);
|
|
48
|
+
};
|
|
49
|
+
var BottomSheetContent = (props) => {
|
|
50
|
+
const [contentProps, localProps] = createSplitProps()(props, ["draggable"]);
|
|
51
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
52
|
+
const presence = usePresenceContext();
|
|
53
|
+
const mergedProps = mergeProps(() => bottomSheet2().getContentProps({
|
|
54
|
+
draggable: true,
|
|
55
|
+
...contentProps
|
|
56
|
+
}), () => presence().presenceProps, localProps);
|
|
57
|
+
return createComponent(Show, {
|
|
58
|
+
get when() {
|
|
59
|
+
return !presence().unmounted;
|
|
60
|
+
},
|
|
61
|
+
get children() {
|
|
62
|
+
return createComponent(ark.div, mergeProps$1(mergedProps, {
|
|
63
|
+
ref(r$) {
|
|
64
|
+
var _ref$ = composeRefs(presence().ref, localProps.ref);
|
|
65
|
+
typeof _ref$ === "function" && _ref$(r$);
|
|
66
|
+
}
|
|
67
|
+
}));
|
|
68
|
+
}
|
|
69
|
+
});
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
// src/components/bottom-sheet/bottom-sheet-context.tsx
|
|
73
|
+
var BottomSheetContext = (props) => props.children(useBottomSheetContext());
|
|
74
|
+
var BottomSheetGrabber = (props) => {
|
|
75
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
76
|
+
const mergedProps = mergeProps(() => bottomSheet2().getGrabberProps(), props);
|
|
77
|
+
return createComponent(ark.div, mergedProps);
|
|
78
|
+
};
|
|
79
|
+
var BottomSheetGrabberIndicator = (props) => {
|
|
80
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
81
|
+
const mergedProps = mergeProps(() => bottomSheet2().getGrabberIndicatorProps(), props);
|
|
82
|
+
return createComponent(ark.div, mergedProps);
|
|
83
|
+
};
|
|
84
|
+
var useBottomSheet = (props) => {
|
|
85
|
+
const locale = useLocaleContext();
|
|
86
|
+
const environment = useEnvironmentContext();
|
|
87
|
+
const id = createUniqueId();
|
|
88
|
+
const machineProps = createMemo(() => ({
|
|
89
|
+
id,
|
|
90
|
+
dir: locale().dir,
|
|
91
|
+
getRootNode: environment().getRootNode,
|
|
92
|
+
...runIfFn(props)
|
|
93
|
+
}));
|
|
94
|
+
const service = useMachine(bottomSheet.machine, machineProps);
|
|
95
|
+
return createMemo(() => bottomSheet.connect(service, normalizeProps));
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
// src/components/bottom-sheet/bottom-sheet-root.tsx
|
|
99
|
+
var BottomSheetRoot = (props) => {
|
|
100
|
+
const [presenceProps, bottomSheetProps] = splitPresenceProps(props);
|
|
101
|
+
const [renderStrategyProps] = splitRenderStrategyProps(presenceProps);
|
|
102
|
+
const [useBottomSheetProps, localProps] = createSplitProps()(bottomSheetProps, ["id", "ids", "open", "defaultOpen", "onOpenChange", "closeOnInteractOutside", "closeOnEscape", "snapPoints", "swipeVelocityThreshold", "closeThreshold", "preventDragOnScroll", "activeSnapPoint", "defaultActiveSnapPoint", "onActiveSnapPointChange", "modal", "trapFocus", "restoreFocus", "preventScroll", "initialFocusEl", "finalFocusEl", "role", "onInteractOutside", "onEscapeKeyDown", "onPointerDownOutside", "onFocusOutside", "onRequestDismiss"]);
|
|
103
|
+
const bottomSheet2 = useBottomSheet(useBottomSheetProps);
|
|
104
|
+
const presence = usePresence(mergeProps(presenceProps, () => ({
|
|
105
|
+
present: bottomSheet2().open
|
|
106
|
+
})));
|
|
107
|
+
return createComponent(BottomSheetProvider, {
|
|
108
|
+
value: bottomSheet2,
|
|
109
|
+
get children() {
|
|
110
|
+
return createComponent(RenderStrategyProvider, {
|
|
111
|
+
value: renderStrategyProps,
|
|
112
|
+
get children() {
|
|
113
|
+
return createComponent(PresenceProvider, {
|
|
114
|
+
value: presence,
|
|
115
|
+
get children() {
|
|
116
|
+
return localProps.children;
|
|
117
|
+
}
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
});
|
|
123
|
+
};
|
|
124
|
+
var BottomSheetRootProvider = (props) => {
|
|
125
|
+
const [presenceProps, bottomSheetProps] = splitPresenceProps(props);
|
|
126
|
+
const [renderStrategyProps] = splitRenderStrategyProps(presenceProps);
|
|
127
|
+
const presence = usePresence(mergeProps(() => ({
|
|
128
|
+
present: bottomSheetProps.value().open
|
|
129
|
+
}), presenceProps));
|
|
130
|
+
return createComponent(BottomSheetProvider, {
|
|
131
|
+
get value() {
|
|
132
|
+
return bottomSheetProps.value;
|
|
133
|
+
},
|
|
134
|
+
get children() {
|
|
135
|
+
return createComponent(RenderStrategyProvider, {
|
|
136
|
+
value: renderStrategyProps,
|
|
137
|
+
get children() {
|
|
138
|
+
return createComponent(PresenceProvider, {
|
|
139
|
+
value: presence,
|
|
140
|
+
get children() {
|
|
141
|
+
return bottomSheetProps.children;
|
|
142
|
+
}
|
|
143
|
+
});
|
|
144
|
+
}
|
|
145
|
+
});
|
|
146
|
+
}
|
|
147
|
+
});
|
|
148
|
+
};
|
|
149
|
+
var BottomSheetTitle = (props) => {
|
|
150
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
151
|
+
const mergedProps = mergeProps(() => bottomSheet2().getTitleProps(), props);
|
|
152
|
+
return createComponent(ark.h2, mergedProps);
|
|
153
|
+
};
|
|
154
|
+
var BottomSheetTrigger = (props) => {
|
|
155
|
+
const bottomSheet2 = useBottomSheetContext();
|
|
156
|
+
const presence = usePresenceContext();
|
|
157
|
+
const mergedProps = mergeProps(() => bottomSheet2().getTriggerProps(), () => ({
|
|
158
|
+
"aria-controls": presence().unmounted && null
|
|
159
|
+
}), props);
|
|
160
|
+
return createComponent(ark.button, mergedProps);
|
|
161
|
+
};
|
|
162
|
+
|
|
163
|
+
// src/components/bottom-sheet/bottom-sheet.ts
|
|
164
|
+
var bottom_sheet_exports = {};
|
|
165
|
+
__export(bottom_sheet_exports, {
|
|
166
|
+
Backdrop: () => BottomSheetBackdrop,
|
|
167
|
+
CloseTrigger: () => BottomSheetCloseTrigger,
|
|
168
|
+
Content: () => BottomSheetContent,
|
|
169
|
+
Context: () => BottomSheetContext,
|
|
170
|
+
Grabber: () => BottomSheetGrabber,
|
|
171
|
+
GrabberIndicator: () => BottomSheetGrabberIndicator,
|
|
172
|
+
Root: () => BottomSheetRoot,
|
|
173
|
+
RootProvider: () => BottomSheetRootProvider,
|
|
174
|
+
Title: () => BottomSheetTitle,
|
|
175
|
+
Trigger: () => BottomSheetTrigger
|
|
176
|
+
});
|
|
177
|
+
|
|
178
|
+
export { BottomSheetBackdrop, BottomSheetCloseTrigger, BottomSheetContent, BottomSheetContext, BottomSheetGrabber, BottomSheetGrabberIndicator, BottomSheetRoot, BottomSheetRootProvider, BottomSheetTitle, BottomSheetTrigger, bottom_sheet_exports, useBottomSheet, useBottomSheetContext };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _zag_js_anatomy from '@zag-js/anatomy';
|
|
2
2
|
|
|
3
|
-
declare const colorPickerAnatomy: _zag_js_anatomy.AnatomyInstance<"
|
|
3
|
+
declare const colorPickerAnatomy: _zag_js_anatomy.AnatomyInstance<"area" | "label" | "view" | "content" | "root" | "trigger" | "control" | "valueText" | "positioner" | "formatSelect" | "areaThumb" | "channelInput" | "channelSliderTrack" | "channelSliderThumb" | "areaBackground" | "channelSlider" | "channelSliderLabel" | "channelSliderValueText" | "transparencyGrid" | "swatchGroup" | "swatchTrigger" | "swatchIndicator" | "swatch" | "eyeDropperTrigger" | "formatTrigger">;
|
|
4
4
|
|
|
5
5
|
export { colorPickerAnatomy as c };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _zag_js_anatomy from '@zag-js/anatomy';
|
|
2
2
|
|
|
3
|
-
declare const comboboxAnatomy: _zag_js_anatomy.AnatomyInstance<"
|
|
3
|
+
declare const comboboxAnatomy: _zag_js_anatomy.AnatomyInstance<"input" | "label" | "list" | "content" | "root" | "item" | "trigger" | "control" | "itemGroup" | "positioner" | "clearTrigger" | "itemGroupLabel" | "itemIndicator" | "itemText" | "empty">;
|
|
4
4
|
|
|
5
5
|
export { comboboxAnatomy as c };
|
|
@@ -2,21 +2,22 @@ export * from '@zag-js/anatomy';
|
|
|
2
2
|
export { anatomy as accordionAnatomy } from '@zag-js/accordion';
|
|
3
3
|
export { anatomy as angleSliderAnatomy } from '@zag-js/angle-slider';
|
|
4
4
|
export { anatomy as avatarAnatomy } from '@zag-js/avatar';
|
|
5
|
+
export { anatomy as bottomSheetAnatomy } from '@zag-js/bottom-sheet';
|
|
5
6
|
export { anatomy as carouselAnatomy } from '@zag-js/carousel';
|
|
6
|
-
export { c as checkboxAnatomy } from '../checkbox.anatomy-
|
|
7
|
+
export { c as checkboxAnatomy } from '../checkbox.anatomy-YlC7nNXs.js';
|
|
7
8
|
export { anatomy as clipboardAnatomy } from '@zag-js/clipboard';
|
|
8
9
|
export { anatomy as collapsibleAnatomy } from '@zag-js/collapsible';
|
|
9
|
-
export { c as colorPickerAnatomy } from '../color-picker.anatomy-
|
|
10
|
-
export { c as comboboxAnatomy } from '../combobox.anatomy-
|
|
11
|
-
export { d as datePickerAnatomy } from '../date-picker.anatomy-
|
|
10
|
+
export { c as colorPickerAnatomy } from '../color-picker.anatomy-Dxw1DJ2S.js';
|
|
11
|
+
export { c as comboboxAnatomy } from '../combobox.anatomy-CW3VXK4N.js';
|
|
12
|
+
export { d as datePickerAnatomy } from '../date-picker.anatomy-DLXcqHH9.js';
|
|
12
13
|
export { anatomy as dialogAnatomy } from '@zag-js/dialog';
|
|
13
14
|
export { anatomy as editableAnatomy } from '@zag-js/editable';
|
|
14
|
-
export { f as fieldAnatomy } from '../field.anatomy-
|
|
15
|
-
export { f as fieldsetAnatomy } from '../fieldset.anatomy-
|
|
15
|
+
export { f as fieldAnatomy } from '../field.anatomy-BA_rbPae.js';
|
|
16
|
+
export { f as fieldsetAnatomy } from '../fieldset.anatomy-ByHwSFid.js';
|
|
16
17
|
export { anatomy as fileUploadAnatomy } from '@zag-js/file-upload';
|
|
17
18
|
export { anatomy as floatingPanelAnatomy } from '@zag-js/floating-panel';
|
|
18
19
|
export { anatomy as hoverCardAnatomy } from '@zag-js/hover-card';
|
|
19
|
-
export { l as listboxAnatomy } from '../listbox.anatomy-
|
|
20
|
+
export { l as listboxAnatomy } from '../listbox.anatomy-ogRrsXMY.js';
|
|
20
21
|
export { anatomy as menuAnatomy } from '@zag-js/menu';
|
|
21
22
|
export { anatomy as numberInputAnatomy } from '@zag-js/number-input';
|
|
22
23
|
export { anatomy as paginationAnatomy } from '@zag-js/pagination';
|
|
@@ -42,5 +43,5 @@ export { anatomy as toastAnatomy } from '@zag-js/toast';
|
|
|
42
43
|
export { t as toggleAnatomy } from '../toggle.anatomy-kQyY2NzP.js';
|
|
43
44
|
export { anatomy as toggleGroupAnatomy } from '@zag-js/toggle-group';
|
|
44
45
|
export { anatomy as tooltipAnatomy } from '@zag-js/tooltip';
|
|
45
|
-
export { t as tourAnatomy } from '../tour.anatomy-
|
|
46
|
+
export { t as tourAnatomy } from '../tour.anatomy-LyAf9UF9.js';
|
|
46
47
|
export { anatomy as treeViewAnatomy } from '@zag-js/tree-view';
|