@moduix/solid 1.0.0 → 1.1.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/components/accordion/Accordion.js +19 -13
- package/dist/components/accordion/Accordion.jsx +7 -7
- package/dist/components/alert/Alert.js +19 -13
- package/dist/components/alert/Alert.jsx +6 -6
- package/dist/components/angle-slider/AngleSlider.d.ts +2 -6
- package/dist/components/angle-slider/AngleSlider.js +21 -16
- package/dist/components/angle-slider/AngleSlider.jsx +9 -10
- package/dist/components/avatar/Avatar.js +10 -7
- package/dist/components/avatar/Avatar.jsx +4 -4
- package/dist/components/button/Button.js +0 -5
- package/dist/components/button/Button.jsx +1 -3
- package/dist/components/button/Button_module.css +1 -3
- package/dist/components/card/Card.js +45 -36
- package/dist/components/card/Card.jsx +9 -9
- package/dist/components/card/Card_module.css +1 -1
- package/dist/components/carousel/Carousel.d.ts +1 -1
- package/dist/components/carousel/Carousel.js +32 -23
- package/dist/components/carousel/Carousel.jsx +12 -13
- package/dist/components/checkbox/Checkbox.js +16 -14
- package/dist/components/checkbox/Checkbox.jsx +6 -6
- package/dist/components/clipboard/Clipboard.js +28 -17
- package/dist/components/clipboard/Clipboard.jsx +12 -11
- package/dist/components/collapsible/Collapsible.js +16 -11
- package/dist/components/collapsible/Collapsible.jsx +6 -6
- package/dist/components/color-picker/ColorPicker.js +69 -48
- package/dist/components/color-picker/ColorPicker.jsx +28 -28
- package/dist/components/combobox/Combobox.js +44 -31
- package/dist/components/combobox/Combobox.jsx +18 -18
- package/dist/components/command-palette/CommandPalette.js +72 -53
- package/dist/components/command-palette/CommandPalette.jsx +29 -32
- package/dist/components/container/Container_module.css +1 -1
- package/dist/components/date-input/DateInput.js +18 -12
- package/dist/components/date-input/DateInput.jsx +7 -7
- package/dist/components/date-picker/DatePicker.js +73 -51
- package/dist/components/date-picker/DatePicker.jsx +29 -29
- package/dist/components/dialog/Dialog.js +30 -20
- package/dist/components/dialog/Dialog.jsx +10 -10
- package/dist/components/drawer/Drawer.js +45 -30
- package/dist/components/drawer/Drawer.jsx +15 -15
- package/dist/components/editable/Editable.js +24 -17
- package/dist/components/editable/Editable.jsx +10 -10
- package/dist/components/file-upload/FileUpload.js +39 -28
- package/dist/components/file-upload/FileUpload.jsx +17 -17
- package/dist/components/floating-panel/FloatingPanel.js +35 -23
- package/dist/components/floating-panel/FloatingPanel.jsx +12 -12
- package/dist/components/hover-card/HoverCard.js +16 -11
- package/dist/components/hover-card/HoverCard.jsx +6 -6
- package/dist/components/image-cropper/ImageCropper.js +21 -14
- package/dist/components/image-cropper/ImageCropper.jsx +7 -7
- package/dist/components/kbd/Kbd.js +8 -8
- package/dist/components/kbd/Kbd.jsx +2 -2
- package/dist/components/lightbox/Lightbox.d.ts +1 -0
- package/dist/components/lightbox/Lightbox.js +41 -27
- package/dist/components/lightbox/Lightbox.jsx +13 -12
- package/dist/components/listbox/Listbox.js +48 -32
- package/dist/components/listbox/Listbox.jsx +17 -17
- package/dist/components/marquee/Marquee.js +18 -12
- package/dist/components/marquee/Marquee.jsx +6 -6
- package/dist/components/menu/Menu.js +64 -43
- package/dist/components/menu/Menu.jsx +24 -24
- package/dist/components/navigation-menu/NavigationMenu.js +36 -24
- package/dist/components/navigation-menu/NavigationMenu.jsx +12 -12
- package/dist/components/number-input/NumberInput.js +19 -14
- package/dist/components/number-input/NumberInput.jsx +9 -9
- package/dist/components/pagination/Pagination.js +10 -9
- package/dist/components/pagination/Pagination.jsx +8 -8
- package/dist/components/password-input/PasswordInput.js +16 -11
- package/dist/components/password-input/PasswordInput.jsx +6 -6
- package/dist/components/pin-input/PinInput.js +15 -10
- package/dist/components/pin-input/PinInput.jsx +6 -6
- package/dist/components/popover/Popover.js +37 -25
- package/dist/components/popover/Popover.jsx +13 -13
- package/dist/components/progress-circular/ProgressCircular.js +18 -13
- package/dist/components/progress-circular/ProgressCircular.jsx +8 -8
- package/dist/components/progress-linear/ProgressLinear.js +21 -14
- package/dist/components/progress-linear/ProgressLinear.jsx +7 -7
- package/dist/components/qr-code/QrCode.js +8 -7
- package/dist/components/qr-code/QrCode.jsx +6 -6
- package/dist/components/rating-group/RatingGroup.js +15 -10
- package/dist/components/rating-group/RatingGroup.jsx +6 -6
- package/dist/components/segment-group/SegmentGroup.js +17 -12
- package/dist/components/segment-group/SegmentGroup.jsx +7 -7
- package/dist/components/select/Select.js +50 -35
- package/dist/components/select/Select.jsx +20 -20
- package/dist/components/sidebar/Sidebar.js +73 -43
- package/dist/components/sidebar/Sidebar.jsx +35 -27
- package/dist/components/signature-pad/SignaturePad.js +16 -12
- package/dist/components/signature-pad/SignaturePad.jsx +8 -8
- package/dist/components/slider/Slider.js +29 -20
- package/dist/components/slider/Slider.jsx +11 -11
- package/dist/components/split-button/SplitButton.d.ts +4 -3
- package/dist/components/split-button/SplitButton.js +21 -9
- package/dist/components/split-button/SplitButton.jsx +14 -7
- package/dist/components/splitter/Splitter.js +13 -9
- package/dist/components/splitter/Splitter.jsx +5 -5
- package/dist/components/steps/Steps.js +34 -23
- package/dist/components/steps/Steps.jsx +12 -12
- package/dist/components/swap/Swap.js +9 -6
- package/dist/components/swap/Swap.jsx +3 -3
- package/dist/components/switch/Switch.js +9 -7
- package/dist/components/switch/Switch.jsx +5 -5
- package/dist/components/tabs/Tabs.js +18 -12
- package/dist/components/tabs/Tabs.jsx +6 -6
- package/dist/components/tags-input/TagsInput.js +28 -20
- package/dist/components/tags-input/TagsInput.jsx +12 -12
- package/dist/components/timer/Timer.js +21 -14
- package/dist/components/timer/Timer.jsx +7 -7
- package/dist/components/toast/Toast.js +11 -9
- package/dist/components/toast/Toast.jsx +7 -7
- package/dist/components/toc/Toc.js +31 -20
- package/dist/components/toc/Toc.jsx +10 -10
- package/dist/components/tooltip/Tooltip.js +13 -9
- package/dist/components/tooltip/Tooltip.jsx +5 -5
- package/dist/components/tour/Tour.js +37 -25
- package/dist/components/tour/Tour.jsx +13 -13
- package/dist/components/tree-view/TreeView.js +39 -28
- package/dist/components/tree-view/TreeView.jsx +17 -17
- package/dist/styles/animations.css +8 -8
- package/package.json +9 -10
|
@@ -6,43 +6,43 @@ function ImageCropperRoot(props) {
|
|
|
6
6
|
const [local, others] = splitProps(props, [
|
|
7
7
|
'class'
|
|
8
8
|
]);
|
|
9
|
-
return <ImageCropper.Root
|
|
9
|
+
return <ImageCropper.Root class={clsx(ImageCropper_module.root, local.class)} {...others} data-slot="image-cropper-root"/>;
|
|
10
10
|
}
|
|
11
11
|
function ImageCropperRootProvider(props) {
|
|
12
12
|
const [local, others] = splitProps(props, [
|
|
13
13
|
'class'
|
|
14
14
|
]);
|
|
15
|
-
return <ImageCropper.RootProvider
|
|
15
|
+
return <ImageCropper.RootProvider class={clsx(ImageCropper_module.root, local.class)} {...others} data-slot="image-cropper-root-provider"/>;
|
|
16
16
|
}
|
|
17
17
|
function ImageCropperViewport(props) {
|
|
18
18
|
const [local, others] = splitProps(props, [
|
|
19
19
|
'class'
|
|
20
20
|
]);
|
|
21
|
-
return <ImageCropper.Viewport
|
|
21
|
+
return <ImageCropper.Viewport class={clsx(ImageCropper_module.viewport, local.class)} {...others} data-slot="image-cropper-viewport"/>;
|
|
22
22
|
}
|
|
23
23
|
function ImageCropperImage(props) {
|
|
24
24
|
const [local, others] = splitProps(props, [
|
|
25
25
|
'class'
|
|
26
26
|
]);
|
|
27
|
-
return <ImageCropper.Image
|
|
27
|
+
return <ImageCropper.Image class={clsx(ImageCropper_module.image, local.class)} {...others} data-slot="image-cropper-image"/>;
|
|
28
28
|
}
|
|
29
29
|
function ImageCropperSelection(props) {
|
|
30
30
|
const [local, others] = splitProps(props, [
|
|
31
31
|
'class'
|
|
32
32
|
]);
|
|
33
|
-
return <ImageCropper.Selection
|
|
33
|
+
return <ImageCropper.Selection class={clsx(ImageCropper_module.selection, local.class)} {...others} data-slot="image-cropper-selection"/>;
|
|
34
34
|
}
|
|
35
35
|
function ImageCropperGrid(props) {
|
|
36
36
|
const [local, others] = splitProps(props, [
|
|
37
37
|
'class'
|
|
38
38
|
]);
|
|
39
|
-
return <ImageCropper.Grid
|
|
39
|
+
return <ImageCropper.Grid class={clsx(ImageCropper_module.grid, local.class)} {...others} data-slot="image-cropper-grid"/>;
|
|
40
40
|
}
|
|
41
41
|
function ImageCropperHandle(props) {
|
|
42
42
|
const [local, others] = splitProps(props, [
|
|
43
43
|
'class'
|
|
44
44
|
]);
|
|
45
|
-
return <ImageCropper.Handle
|
|
45
|
+
return <ImageCropper.Handle class={clsx(ImageCropper_module.handle, local.class)} {...others} data-slot="image-cropper-handle"/>;
|
|
46
46
|
}
|
|
47
47
|
function ImageCropperCropArea(props) {
|
|
48
48
|
const [local, others] = splitProps(props, [
|
|
@@ -7,28 +7,28 @@ function KbdRoot(props) {
|
|
|
7
7
|
const [local, others] = splitProps(props, [
|
|
8
8
|
'class'
|
|
9
9
|
]);
|
|
10
|
-
return createComponent(ark.kbd, mergeProps({
|
|
10
|
+
return createComponent(ark.kbd, mergeProps(others, {
|
|
11
11
|
"data-scope": "kbd",
|
|
12
12
|
"data-part": "root",
|
|
13
|
-
"data-slot": "kbd-root",
|
|
14
13
|
get ["class"] () {
|
|
15
14
|
return clsx(Kbd_module.root, local.class);
|
|
16
|
-
}
|
|
17
|
-
|
|
15
|
+
},
|
|
16
|
+
"data-slot": "kbd-root"
|
|
17
|
+
}));
|
|
18
18
|
}
|
|
19
19
|
function KbdGroupPart(props) {
|
|
20
20
|
const [local, others] = splitProps(props, [
|
|
21
21
|
'class'
|
|
22
22
|
]);
|
|
23
|
-
return createComponent(ark.span, mergeProps({
|
|
23
|
+
return createComponent(ark.span, mergeProps(others, {
|
|
24
24
|
role: "group",
|
|
25
25
|
"data-scope": "kbd",
|
|
26
26
|
"data-part": "group",
|
|
27
|
-
"data-slot": "kbd-group",
|
|
28
27
|
get ["class"] () {
|
|
29
28
|
return clsx(Kbd_module.group, local.class);
|
|
30
|
-
}
|
|
31
|
-
|
|
29
|
+
},
|
|
30
|
+
"data-slot": "kbd-group"
|
|
31
|
+
}));
|
|
32
32
|
}
|
|
33
33
|
const Kbd = Object.assign(KbdRoot, {
|
|
34
34
|
Root: KbdRoot,
|
|
@@ -6,13 +6,13 @@ function KbdRoot(props) {
|
|
|
6
6
|
const [local, others] = splitProps(props, [
|
|
7
7
|
'class'
|
|
8
8
|
]);
|
|
9
|
-
return <ark.kbd data-scope="kbd" data-part="root"
|
|
9
|
+
return <ark.kbd {...others} data-scope="kbd" data-part="root" class={clsx(Kbd_module.root, local.class)} data-slot="kbd-root"/>;
|
|
10
10
|
}
|
|
11
11
|
function KbdGroupPart(props) {
|
|
12
12
|
const [local, others] = splitProps(props, [
|
|
13
13
|
'class'
|
|
14
14
|
]);
|
|
15
|
-
return <ark.span role="group" data-scope="kbd" data-part="group"
|
|
15
|
+
return <ark.span {...others} role="group" data-scope="kbd" data-part="group" class={clsx(Kbd_module.group, local.class)} data-slot="kbd-group"/>;
|
|
16
16
|
}
|
|
17
17
|
const Kbd = Object.assign(KbdRoot, {
|
|
18
18
|
Root: KbdRoot,
|
|
@@ -9,6 +9,7 @@ type LightboxImageSelectDetails = {
|
|
|
9
9
|
};
|
|
10
10
|
type LightboxImageProps = ComponentProps<'img'> & {
|
|
11
11
|
closeOnClick?: boolean;
|
|
12
|
+
'data-close-on-click'?: string;
|
|
12
13
|
};
|
|
13
14
|
type LightboxRootProps = ComponentProps<typeof DialogPrimitive.Root> & OverlayPortalProps;
|
|
14
15
|
type LightboxRootProviderProps = ComponentProps<typeof DialogPrimitive.RootProvider> & OverlayPortalProps;
|
|
@@ -6,7 +6,7 @@ import { children, createEffect, onCleanup, splitProps } from "solid-js";
|
|
|
6
6
|
import { OverlayPortal, OverlayPortalProvider } from "../../internal/overlayPortal.js";
|
|
7
7
|
import { CloseButton } from "../close-button/index.js";
|
|
8
8
|
import Lightbox_module from "./Lightbox.module.js";
|
|
9
|
-
var _tmpl$ = /*#__PURE__*/ template("<img
|
|
9
|
+
var _tmpl$ = /*#__PURE__*/ template("<img>");
|
|
10
10
|
const DEFAULT_CLOSE_LABEL = 'Close image';
|
|
11
11
|
function preloadImage(src) {
|
|
12
12
|
if (!src || "u" < typeof Image) return;
|
|
@@ -102,11 +102,12 @@ function LightboxTrigger(props) {
|
|
|
102
102
|
get asChild () {
|
|
103
103
|
return local.asChild;
|
|
104
104
|
},
|
|
105
|
-
"data-slot": "lightbox-trigger",
|
|
106
105
|
get ["class"] () {
|
|
107
106
|
return clsx(Lightbox_module.trigger, local.class);
|
|
108
107
|
}
|
|
109
|
-
}, others
|
|
108
|
+
}, others, {
|
|
109
|
+
"data-slot": "lightbox-trigger"
|
|
110
|
+
}));
|
|
110
111
|
}
|
|
111
112
|
function LightboxBackdrop(props) {
|
|
112
113
|
const [local, others] = splitProps(props, [
|
|
@@ -115,11 +116,12 @@ function LightboxBackdrop(props) {
|
|
|
115
116
|
return createComponent(OverlayPortal, {
|
|
116
117
|
get children () {
|
|
117
118
|
return createComponent(Dialog.Backdrop, mergeProps({
|
|
118
|
-
"data-slot": "lightbox-backdrop",
|
|
119
119
|
get ["class"] () {
|
|
120
120
|
return clsx(Lightbox_module.backdrop, local.class);
|
|
121
121
|
}
|
|
122
|
-
}, others
|
|
122
|
+
}, others, {
|
|
123
|
+
"data-slot": "lightbox-backdrop"
|
|
124
|
+
}));
|
|
123
125
|
}
|
|
124
126
|
});
|
|
125
127
|
}
|
|
@@ -130,11 +132,12 @@ function LightboxPositioner(props) {
|
|
|
130
132
|
return createComponent(OverlayPortal, {
|
|
131
133
|
get children () {
|
|
132
134
|
return createComponent(Dialog.Positioner, mergeProps({
|
|
133
|
-
"data-slot": "lightbox-positioner",
|
|
134
135
|
get ["class"] () {
|
|
135
136
|
return clsx(Lightbox_module.positioner, local.class);
|
|
136
137
|
}
|
|
137
|
-
}, others
|
|
138
|
+
}, others, {
|
|
139
|
+
"data-slot": "lightbox-positioner"
|
|
140
|
+
}));
|
|
138
141
|
}
|
|
139
142
|
});
|
|
140
143
|
}
|
|
@@ -143,33 +146,36 @@ function LightboxContent(props) {
|
|
|
143
146
|
'class'
|
|
144
147
|
]);
|
|
145
148
|
return createComponent(Dialog.Content, mergeProps({
|
|
146
|
-
"data-slot": "lightbox-content",
|
|
147
149
|
get ["class"] () {
|
|
148
150
|
return clsx(Lightbox_module.content, local.class);
|
|
149
151
|
}
|
|
150
|
-
}, others
|
|
152
|
+
}, others, {
|
|
153
|
+
"data-slot": "lightbox-content"
|
|
154
|
+
}));
|
|
151
155
|
}
|
|
152
156
|
function LightboxTitle(props) {
|
|
153
157
|
const [local, others] = splitProps(props, [
|
|
154
158
|
'class'
|
|
155
159
|
]);
|
|
156
160
|
return createComponent(Dialog.Title, mergeProps({
|
|
157
|
-
"data-slot": "lightbox-title",
|
|
158
161
|
get ["class"] () {
|
|
159
162
|
return clsx(Lightbox_module.title, local.class);
|
|
160
163
|
}
|
|
161
|
-
}, others
|
|
164
|
+
}, others, {
|
|
165
|
+
"data-slot": "lightbox-title"
|
|
166
|
+
}));
|
|
162
167
|
}
|
|
163
168
|
function LightboxDescription(props) {
|
|
164
169
|
const [local, others] = splitProps(props, [
|
|
165
170
|
'class'
|
|
166
171
|
]);
|
|
167
172
|
return createComponent(Dialog.Description, mergeProps({
|
|
168
|
-
"data-slot": "lightbox-description",
|
|
169
173
|
get ["class"] () {
|
|
170
174
|
return clsx(Lightbox_module.description, local.class);
|
|
171
175
|
}
|
|
172
|
-
}, others
|
|
176
|
+
}, others, {
|
|
177
|
+
"data-slot": "lightbox-description"
|
|
178
|
+
}));
|
|
173
179
|
}
|
|
174
180
|
function LightboxCloseTrigger(props) {
|
|
175
181
|
const [local, others] = splitProps(props, [
|
|
@@ -180,11 +186,12 @@ function LightboxCloseTrigger(props) {
|
|
|
180
186
|
get asChild () {
|
|
181
187
|
return local.asChild;
|
|
182
188
|
},
|
|
183
|
-
"data-slot": "lightbox-close-trigger",
|
|
184
189
|
get ["class"] () {
|
|
185
190
|
return local.class;
|
|
186
191
|
}
|
|
187
|
-
}, others
|
|
192
|
+
}, others, {
|
|
193
|
+
"data-slot": "lightbox-close-trigger"
|
|
194
|
+
}));
|
|
188
195
|
}
|
|
189
196
|
function LightboxCloseIcon(props) {
|
|
190
197
|
const [local, others] = splitProps(props, [
|
|
@@ -220,6 +227,7 @@ function LightboxImage(props) {
|
|
|
220
227
|
const [local, others] = splitProps(props, [
|
|
221
228
|
'class',
|
|
222
229
|
'closeOnClick',
|
|
230
|
+
'data-close-on-click',
|
|
223
231
|
'onClick'
|
|
224
232
|
]);
|
|
225
233
|
const dialog = useDialogContext();
|
|
@@ -231,13 +239,15 @@ function LightboxImage(props) {
|
|
|
231
239
|
var _el$ = _tmpl$();
|
|
232
240
|
_el$.$$click = handleClick;
|
|
233
241
|
spread(_el$, mergeProps({
|
|
234
|
-
get ["data-close-on-click"] () {
|
|
235
|
-
return local.closeOnClick ? '' : void 0;
|
|
236
|
-
},
|
|
237
242
|
get ["class"] () {
|
|
238
243
|
return clsx(Lightbox_module.image, local.class);
|
|
239
244
|
}
|
|
240
|
-
}, others
|
|
245
|
+
}, others, {
|
|
246
|
+
get ["data-close-on-click"] () {
|
|
247
|
+
return local.closeOnClick ? '' : void 0;
|
|
248
|
+
},
|
|
249
|
+
"data-slot": "lightbox-image"
|
|
250
|
+
}), false, false);
|
|
241
251
|
return _el$;
|
|
242
252
|
})();
|
|
243
253
|
}
|
|
@@ -246,44 +256,48 @@ function LightboxGallery(props) {
|
|
|
246
256
|
'class'
|
|
247
257
|
]);
|
|
248
258
|
return createComponent(ark.div, mergeProps({
|
|
249
|
-
"data-slot": "lightbox-gallery",
|
|
250
259
|
get ["class"] () {
|
|
251
260
|
return clsx(Lightbox_module.gallery, local.class);
|
|
252
261
|
}
|
|
253
|
-
}, others
|
|
262
|
+
}, others, {
|
|
263
|
+
"data-slot": "lightbox-gallery"
|
|
264
|
+
}));
|
|
254
265
|
}
|
|
255
266
|
function LightboxHeader(props) {
|
|
256
267
|
const [local, others] = splitProps(props, [
|
|
257
268
|
'class'
|
|
258
269
|
]);
|
|
259
270
|
return createComponent(ark.div, mergeProps({
|
|
260
|
-
"data-slot": "lightbox-header",
|
|
261
271
|
get ["class"] () {
|
|
262
272
|
return clsx(Lightbox_module.header, local.class);
|
|
263
273
|
}
|
|
264
|
-
}, others
|
|
274
|
+
}, others, {
|
|
275
|
+
"data-slot": "lightbox-header"
|
|
276
|
+
}));
|
|
265
277
|
}
|
|
266
278
|
function LightboxBody(props) {
|
|
267
279
|
const [local, others] = splitProps(props, [
|
|
268
280
|
'class'
|
|
269
281
|
]);
|
|
270
282
|
return createComponent(ark.div, mergeProps({
|
|
271
|
-
"data-slot": "lightbox-body",
|
|
272
283
|
get ["class"] () {
|
|
273
284
|
return clsx(Lightbox_module.body, local.class);
|
|
274
285
|
}
|
|
275
|
-
}, others
|
|
286
|
+
}, others, {
|
|
287
|
+
"data-slot": "lightbox-body"
|
|
288
|
+
}));
|
|
276
289
|
}
|
|
277
290
|
function LightboxFooter(props) {
|
|
278
291
|
const [local, others] = splitProps(props, [
|
|
279
292
|
'class'
|
|
280
293
|
]);
|
|
281
294
|
return createComponent(ark.div, mergeProps({
|
|
282
|
-
"data-slot": "lightbox-footer",
|
|
283
295
|
get ["class"] () {
|
|
284
296
|
return clsx(Lightbox_module.footer, local.class);
|
|
285
297
|
}
|
|
286
|
-
}, others
|
|
298
|
+
}, others, {
|
|
299
|
+
"data-slot": "lightbox-footer"
|
|
300
|
+
}));
|
|
287
301
|
}
|
|
288
302
|
function LightboxBind(props) {
|
|
289
303
|
const [local] = splitProps(props, [
|
|
@@ -62,14 +62,14 @@ function LightboxTrigger(props) {
|
|
|
62
62
|
'asChild',
|
|
63
63
|
'class'
|
|
64
64
|
]);
|
|
65
|
-
return <Dialog.Trigger asChild={local.asChild}
|
|
65
|
+
return <Dialog.Trigger asChild={local.asChild} class={clsx(Lightbox_module.trigger, local.class)} {...others} data-slot="lightbox-trigger"/>;
|
|
66
66
|
}
|
|
67
67
|
function LightboxBackdrop(props) {
|
|
68
68
|
const [local, others] = splitProps(props, [
|
|
69
69
|
'class'
|
|
70
70
|
]);
|
|
71
71
|
return <OverlayPortal>
|
|
72
|
-
<Dialog.Backdrop
|
|
72
|
+
<Dialog.Backdrop class={clsx(Lightbox_module.backdrop, local.class)} {...others} data-slot="lightbox-backdrop"/>
|
|
73
73
|
</OverlayPortal>;
|
|
74
74
|
}
|
|
75
75
|
function LightboxPositioner(props) {
|
|
@@ -77,33 +77,33 @@ function LightboxPositioner(props) {
|
|
|
77
77
|
'class'
|
|
78
78
|
]);
|
|
79
79
|
return <OverlayPortal>
|
|
80
|
-
<Dialog.Positioner
|
|
80
|
+
<Dialog.Positioner class={clsx(Lightbox_module.positioner, local.class)} {...others} data-slot="lightbox-positioner"/>
|
|
81
81
|
</OverlayPortal>;
|
|
82
82
|
}
|
|
83
83
|
function LightboxContent(props) {
|
|
84
84
|
const [local, others] = splitProps(props, [
|
|
85
85
|
'class'
|
|
86
86
|
]);
|
|
87
|
-
return <Dialog.Content
|
|
87
|
+
return <Dialog.Content class={clsx(Lightbox_module.content, local.class)} {...others} data-slot="lightbox-content"/>;
|
|
88
88
|
}
|
|
89
89
|
function LightboxTitle(props) {
|
|
90
90
|
const [local, others] = splitProps(props, [
|
|
91
91
|
'class'
|
|
92
92
|
]);
|
|
93
|
-
return <Dialog.Title
|
|
93
|
+
return <Dialog.Title class={clsx(Lightbox_module.title, local.class)} {...others} data-slot="lightbox-title"/>;
|
|
94
94
|
}
|
|
95
95
|
function LightboxDescription(props) {
|
|
96
96
|
const [local, others] = splitProps(props, [
|
|
97
97
|
'class'
|
|
98
98
|
]);
|
|
99
|
-
return <Dialog.Description
|
|
99
|
+
return <Dialog.Description class={clsx(Lightbox_module.description, local.class)} {...others} data-slot="lightbox-description"/>;
|
|
100
100
|
}
|
|
101
101
|
function LightboxCloseTrigger(props) {
|
|
102
102
|
const [local, others] = splitProps(props, [
|
|
103
103
|
'asChild',
|
|
104
104
|
'class'
|
|
105
105
|
]);
|
|
106
|
-
return <Dialog.CloseTrigger asChild={local.asChild}
|
|
106
|
+
return <Dialog.CloseTrigger asChild={local.asChild} class={local.class} {...others} data-slot="lightbox-close-trigger"/>;
|
|
107
107
|
}
|
|
108
108
|
function LightboxCloseIcon(props) {
|
|
109
109
|
const [local, others] = splitProps(props, [
|
|
@@ -122,6 +122,7 @@ function LightboxImage(props) {
|
|
|
122
122
|
const [local, others] = splitProps(props, [
|
|
123
123
|
'class',
|
|
124
124
|
'closeOnClick',
|
|
125
|
+
'data-close-on-click',
|
|
125
126
|
'onClick'
|
|
126
127
|
]);
|
|
127
128
|
const dialog = useDialogContext();
|
|
@@ -129,31 +130,31 @@ function LightboxImage(props) {
|
|
|
129
130
|
local.onClick?.(event);
|
|
130
131
|
if (local.closeOnClick && !event.defaultPrevented) dialog().setOpen(false);
|
|
131
132
|
};
|
|
132
|
-
return <img
|
|
133
|
+
return <img class={clsx(Lightbox_module.image, local.class)} onClick={handleClick} {...others} data-close-on-click={local.closeOnClick ? '' : void 0} data-slot="lightbox-image"/>;
|
|
133
134
|
}
|
|
134
135
|
function LightboxGallery(props) {
|
|
135
136
|
const [local, others] = splitProps(props, [
|
|
136
137
|
'class'
|
|
137
138
|
]);
|
|
138
|
-
return <ark.div
|
|
139
|
+
return <ark.div class={clsx(Lightbox_module.gallery, local.class)} {...others} data-slot="lightbox-gallery"/>;
|
|
139
140
|
}
|
|
140
141
|
function LightboxHeader(props) {
|
|
141
142
|
const [local, others] = splitProps(props, [
|
|
142
143
|
'class'
|
|
143
144
|
]);
|
|
144
|
-
return <ark.div
|
|
145
|
+
return <ark.div class={clsx(Lightbox_module.header, local.class)} {...others} data-slot="lightbox-header"/>;
|
|
145
146
|
}
|
|
146
147
|
function LightboxBody(props) {
|
|
147
148
|
const [local, others] = splitProps(props, [
|
|
148
149
|
'class'
|
|
149
150
|
]);
|
|
150
|
-
return <ark.div
|
|
151
|
+
return <ark.div class={clsx(Lightbox_module.body, local.class)} {...others} data-slot="lightbox-body"/>;
|
|
151
152
|
}
|
|
152
153
|
function LightboxFooter(props) {
|
|
153
154
|
const [local, others] = splitProps(props, [
|
|
154
155
|
'class'
|
|
155
156
|
]);
|
|
156
|
-
return <ark.div
|
|
157
|
+
return <ark.div class={clsx(Lightbox_module.footer, local.class)} {...others} data-slot="lightbox-footer"/>;
|
|
157
158
|
}
|
|
158
159
|
function LightboxBind(props) {
|
|
159
160
|
const [local] = splitProps(props, [
|
|
@@ -6,50 +6,54 @@ import { children, splitProps } from "solid-js";
|
|
|
6
6
|
import { CheckIcon, SearchIcon } from "../../internal/icons/ui/Icons.js";
|
|
7
7
|
import { CloseButton } from "../close-button/index.js";
|
|
8
8
|
import Listbox_module from "./Listbox.module.js";
|
|
9
|
-
var _tmpl$ = /*#__PURE__*/ template("<div
|
|
9
|
+
var _tmpl$ = /*#__PURE__*/ template("<div>");
|
|
10
10
|
const Listbox_ListboxRoot = function(props) {
|
|
11
11
|
const [local, others] = splitProps(props, [
|
|
12
12
|
'class'
|
|
13
13
|
]);
|
|
14
14
|
return createComponent(Listbox.Root, mergeProps({
|
|
15
|
-
"data-slot": "listbox-root",
|
|
16
15
|
get ["class"] () {
|
|
17
16
|
return clsx(Listbox_module.root, local.class);
|
|
18
17
|
}
|
|
19
|
-
}, others
|
|
18
|
+
}, others, {
|
|
19
|
+
"data-slot": "listbox-root"
|
|
20
|
+
}));
|
|
20
21
|
};
|
|
21
22
|
const Listbox_ListboxRootProvider = function(props) {
|
|
22
23
|
const [local, others] = splitProps(props, [
|
|
23
24
|
'class'
|
|
24
25
|
]);
|
|
25
26
|
return createComponent(Listbox.RootProvider, mergeProps({
|
|
26
|
-
"data-slot": "listbox-root-provider",
|
|
27
27
|
get ["class"] () {
|
|
28
28
|
return clsx(Listbox_module.root, local.class);
|
|
29
29
|
}
|
|
30
|
-
}, others
|
|
30
|
+
}, others, {
|
|
31
|
+
"data-slot": "listbox-root-provider"
|
|
32
|
+
}));
|
|
31
33
|
};
|
|
32
34
|
function ListboxLabel(props) {
|
|
33
35
|
const [local, others] = splitProps(props, [
|
|
34
36
|
'class'
|
|
35
37
|
]);
|
|
36
38
|
return createComponent(Listbox.Label, mergeProps({
|
|
37
|
-
"data-slot": "listbox-label",
|
|
38
39
|
get ["class"] () {
|
|
39
40
|
return clsx(Listbox_module.label, local.class);
|
|
40
41
|
}
|
|
41
|
-
}, others
|
|
42
|
+
}, others, {
|
|
43
|
+
"data-slot": "listbox-label"
|
|
44
|
+
}));
|
|
42
45
|
}
|
|
43
46
|
function ListboxInput(props) {
|
|
44
47
|
const [local, others] = splitProps(props, [
|
|
45
48
|
'class'
|
|
46
49
|
]);
|
|
47
50
|
return createComponent(Listbox.Input, mergeProps({
|
|
48
|
-
"data-slot": "listbox-input",
|
|
49
51
|
get ["class"] () {
|
|
50
52
|
return clsx(Listbox_module.input, local.class);
|
|
51
53
|
}
|
|
52
|
-
}, others
|
|
54
|
+
}, others, {
|
|
55
|
+
"data-slot": "listbox-input"
|
|
56
|
+
}));
|
|
53
57
|
}
|
|
54
58
|
function ListboxFilter(props) {
|
|
55
59
|
const [local, others] = splitProps(props, [
|
|
@@ -62,7 +66,9 @@ function ListboxFilter(props) {
|
|
|
62
66
|
get ["class"] () {
|
|
63
67
|
return clsx(Listbox_module.filter, local.class);
|
|
64
68
|
}
|
|
65
|
-
}, others
|
|
69
|
+
}, others, {
|
|
70
|
+
"data-slot": "listbox-filter"
|
|
71
|
+
}), false, true);
|
|
66
72
|
insert(_el$, createComponent(SearchIcon, {
|
|
67
73
|
"data-slot": "listbox-filter-icon",
|
|
68
74
|
get ["class"] () {
|
|
@@ -82,7 +88,6 @@ function ListboxClearTrigger(props) {
|
|
|
82
88
|
]);
|
|
83
89
|
const resolvedChildren = children(()=>local.children);
|
|
84
90
|
return createComponent(CloseButton.Root, mergeProps({
|
|
85
|
-
"data-slot": "listbox-clear-trigger",
|
|
86
91
|
get ["class"] () {
|
|
87
92
|
return clsx(Listbox_module.clearTrigger, local.class);
|
|
88
93
|
},
|
|
@@ -93,6 +98,7 @@ function ListboxClearTrigger(props) {
|
|
|
93
98
|
return local['aria-label'] ?? 'Clear search';
|
|
94
99
|
}
|
|
95
100
|
}, others, {
|
|
101
|
+
"data-slot": "listbox-clear-trigger",
|
|
96
102
|
get children () {
|
|
97
103
|
return resolvedChildren();
|
|
98
104
|
}
|
|
@@ -103,66 +109,72 @@ function ListboxContent(props) {
|
|
|
103
109
|
'class'
|
|
104
110
|
]);
|
|
105
111
|
return createComponent(Listbox.Content, mergeProps({
|
|
106
|
-
"data-slot": "listbox-content",
|
|
107
112
|
get ["class"] () {
|
|
108
113
|
return clsx(Listbox_module.content, local.class);
|
|
109
114
|
}
|
|
110
|
-
}, others
|
|
115
|
+
}, others, {
|
|
116
|
+
"data-slot": "listbox-content"
|
|
117
|
+
}));
|
|
111
118
|
}
|
|
112
119
|
function ListboxEmpty(props) {
|
|
113
120
|
const [local, others] = splitProps(props, [
|
|
114
121
|
'class'
|
|
115
122
|
]);
|
|
116
123
|
return createComponent(Listbox.Empty, mergeProps({
|
|
117
|
-
"data-slot": "listbox-empty",
|
|
118
124
|
get ["class"] () {
|
|
119
125
|
return clsx(Listbox_module.empty, local.class);
|
|
120
126
|
}
|
|
121
|
-
}, others
|
|
127
|
+
}, others, {
|
|
128
|
+
"data-slot": "listbox-empty"
|
|
129
|
+
}));
|
|
122
130
|
}
|
|
123
131
|
function ListboxItemGroup(props) {
|
|
124
132
|
const [local, others] = splitProps(props, [
|
|
125
133
|
'class'
|
|
126
134
|
]);
|
|
127
135
|
return createComponent(Listbox.ItemGroup, mergeProps({
|
|
128
|
-
"data-slot": "listbox-item-group",
|
|
129
136
|
get ["class"] () {
|
|
130
137
|
return clsx(Listbox_module.itemGroup, local.class);
|
|
131
138
|
}
|
|
132
|
-
}, others
|
|
139
|
+
}, others, {
|
|
140
|
+
"data-slot": "listbox-item-group"
|
|
141
|
+
}));
|
|
133
142
|
}
|
|
134
143
|
function ListboxItemGroupLabel(props) {
|
|
135
144
|
const [local, others] = splitProps(props, [
|
|
136
145
|
'class'
|
|
137
146
|
]);
|
|
138
147
|
return createComponent(Listbox.ItemGroupLabel, mergeProps({
|
|
139
|
-
"data-slot": "listbox-item-group-label",
|
|
140
148
|
get ["class"] () {
|
|
141
149
|
return clsx(Listbox_module.itemGroupLabel, local.class);
|
|
142
150
|
}
|
|
143
|
-
}, others
|
|
151
|
+
}, others, {
|
|
152
|
+
"data-slot": "listbox-item-group-label"
|
|
153
|
+
}));
|
|
144
154
|
}
|
|
145
155
|
function ListboxItem(props) {
|
|
146
156
|
const [local, others] = splitProps(props, [
|
|
147
157
|
'class'
|
|
148
158
|
]);
|
|
149
159
|
return createComponent(Listbox.Item, mergeProps({
|
|
150
|
-
"data-slot": "listbox-item",
|
|
151
160
|
get ["class"] () {
|
|
152
161
|
return clsx(Listbox_module.item, local.class);
|
|
153
162
|
}
|
|
154
|
-
}, others
|
|
163
|
+
}, others, {
|
|
164
|
+
"data-slot": "listbox-item"
|
|
165
|
+
}));
|
|
155
166
|
}
|
|
156
167
|
function ListboxItemText(props) {
|
|
157
168
|
const [local, others] = splitProps(props, [
|
|
158
169
|
'class'
|
|
159
170
|
]);
|
|
160
171
|
return createComponent(Listbox.ItemText, mergeProps({
|
|
161
|
-
"data-slot": "listbox-item-text",
|
|
162
172
|
get ["class"] () {
|
|
163
173
|
return clsx(Listbox_module.itemText, local.class);
|
|
164
174
|
}
|
|
165
|
-
}, others
|
|
175
|
+
}, others, {
|
|
176
|
+
"data-slot": "listbox-item-text"
|
|
177
|
+
}));
|
|
166
178
|
}
|
|
167
179
|
function ListboxItemIndicator(props) {
|
|
168
180
|
const [local, others] = splitProps(props, [
|
|
@@ -171,11 +183,11 @@ function ListboxItemIndicator(props) {
|
|
|
171
183
|
]);
|
|
172
184
|
const resolvedChildren = children(()=>local.children);
|
|
173
185
|
return createComponent(Listbox.ItemIndicator, mergeProps({
|
|
174
|
-
"data-slot": "listbox-item-indicator",
|
|
175
186
|
get ["class"] () {
|
|
176
187
|
return clsx(Listbox_module.itemIndicator, local.class);
|
|
177
188
|
}
|
|
178
189
|
}, others, {
|
|
190
|
+
"data-slot": "listbox-item-indicator",
|
|
179
191
|
get children () {
|
|
180
192
|
return resolvedChildren() ?? createComponent(CheckIcon, {});
|
|
181
193
|
}
|
|
@@ -186,44 +198,48 @@ function ListboxValueText(props) {
|
|
|
186
198
|
'class'
|
|
187
199
|
]);
|
|
188
200
|
return createComponent(Listbox.ValueText, mergeProps({
|
|
189
|
-
"data-slot": "listbox-value-text",
|
|
190
201
|
get ["class"] () {
|
|
191
202
|
return clsx(Listbox_module.valueText, local.class);
|
|
192
203
|
}
|
|
193
|
-
}, others
|
|
204
|
+
}, others, {
|
|
205
|
+
"data-slot": "listbox-value-text"
|
|
206
|
+
}));
|
|
194
207
|
}
|
|
195
208
|
function ListboxItemTextContent(props) {
|
|
196
209
|
const [local, others] = splitProps(props, [
|
|
197
210
|
'class'
|
|
198
211
|
]);
|
|
199
212
|
return createComponent(ark.span, mergeProps({
|
|
200
|
-
"data-slot": "listbox-item-text-content",
|
|
201
213
|
get ["class"] () {
|
|
202
214
|
return clsx(Listbox_module.itemTextContent, local.class);
|
|
203
215
|
}
|
|
204
|
-
}, others
|
|
216
|
+
}, others, {
|
|
217
|
+
"data-slot": "listbox-item-text-content"
|
|
218
|
+
}));
|
|
205
219
|
}
|
|
206
220
|
function ListboxItemTextIcon(props) {
|
|
207
221
|
const [local, others] = splitProps(props, [
|
|
208
222
|
'class'
|
|
209
223
|
]);
|
|
210
224
|
return createComponent(ark.span, mergeProps({
|
|
211
|
-
"data-slot": "listbox-item-text-icon",
|
|
212
225
|
get ["class"] () {
|
|
213
226
|
return clsx(Listbox_module.itemTextIcon, local.class);
|
|
214
227
|
}
|
|
215
|
-
}, others
|
|
228
|
+
}, others, {
|
|
229
|
+
"data-slot": "listbox-item-text-icon"
|
|
230
|
+
}));
|
|
216
231
|
}
|
|
217
232
|
function ListboxItemTextLabel(props) {
|
|
218
233
|
const [local, others] = splitProps(props, [
|
|
219
234
|
'class'
|
|
220
235
|
]);
|
|
221
236
|
return createComponent(ark.span, mergeProps({
|
|
222
|
-
"data-slot": "listbox-item-text-label",
|
|
223
237
|
get ["class"] () {
|
|
224
238
|
return clsx(Listbox_module.itemTextLabel, local.class);
|
|
225
239
|
}
|
|
226
|
-
}, others
|
|
240
|
+
}, others, {
|
|
241
|
+
"data-slot": "listbox-item-text-label"
|
|
242
|
+
}));
|
|
227
243
|
}
|
|
228
244
|
const Listbox_Listbox = Object.assign(Listbox_ListboxRoot, {
|
|
229
245
|
Root: Listbox_ListboxRoot,
|