@moduix/solid-tailwind 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 +7 -7
- 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 +10 -11
- package/dist/components/avatar/Avatar.js +10 -7
- package/dist/components/avatar/Avatar.jsx +6 -6
- package/dist/components/bleed/Bleed.js +1 -1
- package/dist/components/bleed/Bleed.jsx +1 -1
- package/dist/components/button/Button.js +1 -6
- package/dist/components/button/Button.jsx +2 -4
- package/dist/components/card/Card.js +54 -44
- package/dist/components/card/Card.jsx +12 -12
- 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.js +5 -5
- package/dist/components/container/Container.jsx +5 -5
- 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/empty/Empty.js +1 -1
- package/dist/components/empty/Empty.jsx +1 -1
- 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/input-group/InputGroup.js +3 -2
- package/dist/components/input-group/InputGroup.jsx +3 -2
- package/dist/components/json-tree-view/JsonTreeView.js +1 -1
- package/dist/components/json-tree-view/JsonTreeView.jsx +1 -1
- 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 +9 -9
- package/dist/components/menu/Menu.js +66 -44
- package/dist/components/menu/Menu.jsx +28 -28
- 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 +17 -12
- 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 +72 -43
- package/dist/components/sidebar/Sidebar.jsx +34 -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 +20 -9
- package/dist/components/split-button/SplitButton.jsx +13 -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 +38 -26
- 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 +10 -11
|
@@ -9,7 +9,7 @@ function NumberInputRoot(props) {
|
|
|
9
9
|
'class',
|
|
10
10
|
'value'
|
|
11
11
|
]);
|
|
12
|
-
return <NumberInput.Root asChild={local.asChild} value={local.value}
|
|
12
|
+
return <NumberInput.Root asChild={local.asChild} value={local.value} class={cn('group/number-input flex w-auto max-w-none flex-col items-start gap-1 data-disabled:opacity-50', local.class)} {...others} data-slot="number-input-root">
|
|
13
13
|
{local.children}
|
|
14
14
|
</NumberInput.Root>;
|
|
15
15
|
}
|
|
@@ -20,7 +20,7 @@ function NumberInputRootProvider(props) {
|
|
|
20
20
|
'class',
|
|
21
21
|
'value'
|
|
22
22
|
]);
|
|
23
|
-
return <NumberInput.RootProvider asChild={local.asChild} value={local.value}
|
|
23
|
+
return <NumberInput.RootProvider asChild={local.asChild} value={local.value} class={cn('group/number-input flex w-auto max-w-none flex-col items-start gap-1 data-disabled:opacity-50', local.class)} {...others} data-slot="number-input-root-provider">
|
|
24
24
|
{local.children}
|
|
25
25
|
</NumberInput.RootProvider>;
|
|
26
26
|
}
|
|
@@ -28,19 +28,19 @@ function NumberInputLabel(props) {
|
|
|
28
28
|
const [local, others] = splitProps(props, [
|
|
29
29
|
'class'
|
|
30
30
|
]);
|
|
31
|
-
return <NumberInput.Label
|
|
31
|
+
return <NumberInput.Label class={cn('text-sm leading-5 font-medium text-foreground', local.class)} {...others} data-slot="number-input-label"/>;
|
|
32
32
|
}
|
|
33
33
|
function NumberInputScrubber(props) {
|
|
34
34
|
const [local, others] = splitProps(props, [
|
|
35
35
|
'class'
|
|
36
36
|
]);
|
|
37
|
-
return <NumberInput.Scrubber
|
|
37
|
+
return <NumberInput.Scrubber class={cn('inline-flex cursor-ew-resize items-center gap-2 text-foreground select-none data-disabled:cursor-default', local.class)} {...others} data-slot="number-input-scrubber"/>;
|
|
38
38
|
}
|
|
39
39
|
function NumberInputControl(props) {
|
|
40
40
|
const [local, others] = splitProps(props, [
|
|
41
41
|
'class'
|
|
42
42
|
]);
|
|
43
|
-
return <NumberInput.Control
|
|
43
|
+
return <NumberInput.Control class={cn('inline-flex items-stretch', local.class)} {...others} data-slot="number-input-control"/>;
|
|
44
44
|
}
|
|
45
45
|
function NumberInputDecrementTrigger(props) {
|
|
46
46
|
const [local, others] = splitProps(props, [
|
|
@@ -48,7 +48,7 @@ function NumberInputDecrementTrigger(props) {
|
|
|
48
48
|
'class'
|
|
49
49
|
]);
|
|
50
50
|
const resolvedChildren = children(()=>local.children);
|
|
51
|
-
return <NumberInput.DecrementTrigger
|
|
51
|
+
return <NumberInput.DecrementTrigger class={cn('box-border inline-flex size-control-md min-w-control-md cursor-pointer items-center justify-center rounded-s-md border border-e-0 border-border bg-background p-0 text-foreground outline-0 transition-[background-color,border-color,color,opacity] duration-200 ease-in-out select-none group-data-invalid/number-input:border-destructive focus-visible:z-1 focus-visible:outline-1 focus-visible:-outline-offset-1 focus-visible:outline-ring group-data-invalid/number-input:focus-visible:outline-destructive active:bg-accent disabled:pointer-events-none data-disabled:pointer-events-none data-focus:z-1 data-focus:outline-1 data-focus:-outline-offset-1 data-focus:outline-ring group-data-invalid/number-input:data-focus:outline-destructive data-invalid:border-destructive data-invalid:focus-visible:outline-destructive data-invalid:data-focus:outline-destructive motion-reduce:transition-none [&>svg]:size-3.5 [&>svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', local.class)} {...others} data-slot="number-input-decrement-trigger">
|
|
52
52
|
{resolvedChildren() ?? <MinusIcon/>}
|
|
53
53
|
</NumberInput.DecrementTrigger>;
|
|
54
54
|
}
|
|
@@ -56,7 +56,7 @@ function NumberInputInput(props) {
|
|
|
56
56
|
const [local, others] = splitProps(props, [
|
|
57
57
|
'class'
|
|
58
58
|
]);
|
|
59
|
-
return <NumberInput.Input
|
|
59
|
+
return <NumberInput.Input class={cn('h-control-md w-24 rounded-none border-x-0 border-y border-border border-x-current bg-background px-3 py-1 text-center text-md leading-6 text-foreground tabular-nums outline-1 -outline-offset-1 outline-transparent transition-[border-color,outline-color,opacity] duration-200 ease-in-out group-data-invalid/number-input:border-t-destructive group-data-invalid/number-input:border-b-destructive focus-visible:z-1 focus-visible:outline-ring group-data-invalid/number-input:focus-visible:outline-destructive data-focus:z-1 data-focus:outline-ring group-data-invalid/number-input:data-focus:outline-destructive data-invalid:border-t-destructive data-invalid:border-b-destructive data-invalid:focus-visible:outline-destructive data-invalid:data-focus:outline-destructive motion-reduce:transition-none', local.class)} {...others} data-slot="number-input-input"/>;
|
|
60
60
|
}
|
|
61
61
|
function NumberInputIncrementTrigger(props) {
|
|
62
62
|
const [local, others] = splitProps(props, [
|
|
@@ -64,7 +64,7 @@ function NumberInputIncrementTrigger(props) {
|
|
|
64
64
|
'class'
|
|
65
65
|
]);
|
|
66
66
|
const resolvedChildren = children(()=>local.children);
|
|
67
|
-
return <NumberInput.IncrementTrigger
|
|
67
|
+
return <NumberInput.IncrementTrigger class={cn('box-border inline-flex size-control-md min-w-control-md cursor-pointer items-center justify-center rounded-e-md border border-s-0 border-border bg-background p-0 text-foreground outline-0 transition-[background-color,border-color,color,opacity] duration-200 ease-in-out select-none group-data-invalid/number-input:border-destructive focus-visible:z-1 focus-visible:outline-1 focus-visible:-outline-offset-1 focus-visible:outline-ring group-data-invalid/number-input:focus-visible:outline-destructive active:bg-accent disabled:pointer-events-none data-disabled:pointer-events-none data-focus:z-1 data-focus:outline-1 data-focus:-outline-offset-1 data-focus:outline-ring group-data-invalid/number-input:data-focus:outline-destructive data-invalid:border-destructive data-invalid:focus-visible:outline-destructive data-invalid:data-focus:outline-destructive motion-reduce:transition-none [&>svg]:size-3.5 [&>svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', local.class)} {...others} data-slot="number-input-increment-trigger">
|
|
68
68
|
{resolvedChildren() ?? <PlusIcon/>}
|
|
69
69
|
</NumberInput.IncrementTrigger>;
|
|
70
70
|
}
|
|
@@ -72,7 +72,7 @@ function NumberInputValueText(props) {
|
|
|
72
72
|
const [local, others] = splitProps(props, [
|
|
73
73
|
'class'
|
|
74
74
|
]);
|
|
75
|
-
return <NumberInput.ValueText
|
|
75
|
+
return <NumberInput.ValueText class={cn('text-sm leading-5 text-muted-foreground tabular-nums', local.class)} {...others} data-slot="number-input-value-text"/>;
|
|
76
76
|
}
|
|
77
77
|
function NumberInputField(props) {
|
|
78
78
|
return <NumberInputControl {...props}>
|
|
@@ -14,11 +14,11 @@ function PaginationRoot(props) {
|
|
|
14
14
|
get asChild () {
|
|
15
15
|
return local.asChild;
|
|
16
16
|
},
|
|
17
|
-
"data-slot": "pagination-root",
|
|
18
17
|
get ["class"] () {
|
|
19
18
|
return cn('inline-flex max-w-full items-center gap-1 overflow-x-auto text-foreground', local.class);
|
|
20
19
|
}
|
|
21
20
|
}, others, {
|
|
21
|
+
"data-slot": "pagination-root",
|
|
22
22
|
get children () {
|
|
23
23
|
return local.children;
|
|
24
24
|
}
|
|
@@ -34,11 +34,11 @@ function PaginationRootProvider(props) {
|
|
|
34
34
|
get asChild () {
|
|
35
35
|
return local.asChild;
|
|
36
36
|
},
|
|
37
|
-
"data-slot": "pagination-root-provider",
|
|
38
37
|
get ["class"] () {
|
|
39
38
|
return cn('inline-flex max-w-full items-center gap-1 overflow-x-auto text-foreground', local.class);
|
|
40
39
|
}
|
|
41
40
|
}, others, {
|
|
41
|
+
"data-slot": "pagination-root-provider",
|
|
42
42
|
get children () {
|
|
43
43
|
return local.children;
|
|
44
44
|
}
|
|
@@ -53,11 +53,12 @@ function PaginationItem(props) {
|
|
|
53
53
|
get asChild () {
|
|
54
54
|
return local.asChild;
|
|
55
55
|
},
|
|
56
|
-
"data-slot": "pagination-item",
|
|
57
56
|
get ["class"] () {
|
|
58
57
|
return cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-2 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', 'data-selected:border-foreground data-selected:bg-foreground data-selected:text-background [@media(hover:hover)]:hover:bg-accent [@media(hover:hover)]:data-selected:hover:bg-foreground', '[&_svg]:size-4 [&_svg]:shrink-0', local.class);
|
|
59
58
|
}
|
|
60
|
-
}, others
|
|
59
|
+
}, others, {
|
|
60
|
+
"data-slot": "pagination-item"
|
|
61
|
+
}));
|
|
61
62
|
}
|
|
62
63
|
function PaginationEllipsis(props) {
|
|
63
64
|
const [local, others] = splitProps(props, [
|
|
@@ -70,11 +71,11 @@ function PaginationEllipsis(props) {
|
|
|
70
71
|
get asChild () {
|
|
71
72
|
return local.asChild;
|
|
72
73
|
},
|
|
73
|
-
"data-slot": "pagination-ellipsis",
|
|
74
74
|
get ["class"] () {
|
|
75
75
|
return cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium text-muted-foreground tabular-nums select-none', local.class);
|
|
76
76
|
}
|
|
77
77
|
}, others, {
|
|
78
|
+
"data-slot": "pagination-ellipsis",
|
|
78
79
|
get children () {
|
|
79
80
|
return resolvedChildren() ?? (!local.asChild && '...');
|
|
80
81
|
}
|
|
@@ -105,11 +106,11 @@ function PaginationPrevTrigger(props) {
|
|
|
105
106
|
get asChild () {
|
|
106
107
|
return local.asChild;
|
|
107
108
|
},
|
|
108
|
-
"data-slot": "pagination-prev-trigger",
|
|
109
109
|
get ["class"] () {
|
|
110
110
|
return cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-3 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', '[&_svg]:size-4 [&_svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', null == local.children && 'w-control-md p-0 rtl:[&_svg]:-scale-x-100', local.class);
|
|
111
111
|
}
|
|
112
112
|
}, others, {
|
|
113
|
+
"data-slot": "pagination-prev-trigger",
|
|
113
114
|
get children () {
|
|
114
115
|
return resolvedChildren() ?? (!local.asChild && createComponent(ChevronLeftIcon, {}));
|
|
115
116
|
}
|
|
@@ -126,11 +127,11 @@ function PaginationNextTrigger(props) {
|
|
|
126
127
|
get asChild () {
|
|
127
128
|
return local.asChild;
|
|
128
129
|
},
|
|
129
|
-
"data-slot": "pagination-next-trigger",
|
|
130
130
|
get ["class"] () {
|
|
131
131
|
return cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-3 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', '[&_svg]:size-4 [&_svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', null == local.children && 'w-control-md p-0 rtl:[&_svg]:-scale-x-100', local.class);
|
|
132
132
|
}
|
|
133
133
|
}, others, {
|
|
134
|
+
"data-slot": "pagination-next-trigger",
|
|
134
135
|
get children () {
|
|
135
136
|
return resolvedChildren() ?? (!local.asChild && createComponent(ChevronRightIcon, {}));
|
|
136
137
|
}
|
|
@@ -147,11 +148,11 @@ function PaginationFirstTrigger(props) {
|
|
|
147
148
|
get asChild () {
|
|
148
149
|
return local.asChild;
|
|
149
150
|
},
|
|
150
|
-
"data-slot": "pagination-first-trigger",
|
|
151
151
|
get ["class"] () {
|
|
152
152
|
return cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-3 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', '[&_svg]:size-4 [&_svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', null == local.children && 'w-control-md p-0 rtl:[&_svg]:-scale-x-100', local.class);
|
|
153
153
|
}
|
|
154
154
|
}, others, {
|
|
155
|
+
"data-slot": "pagination-first-trigger",
|
|
155
156
|
get children () {
|
|
156
157
|
return resolvedChildren() ?? (!local.asChild && createComponent(EdgeIcon, {
|
|
157
158
|
side: "left"
|
|
@@ -170,11 +171,11 @@ function PaginationLastTrigger(props) {
|
|
|
170
171
|
get asChild () {
|
|
171
172
|
return local.asChild;
|
|
172
173
|
},
|
|
173
|
-
"data-slot": "pagination-last-trigger",
|
|
174
174
|
get ["class"] () {
|
|
175
175
|
return cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-3 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', '[&_svg]:size-4 [&_svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', null == local.children && 'w-control-md p-0 rtl:[&_svg]:-scale-x-100', local.class);
|
|
176
176
|
}
|
|
177
177
|
}, others, {
|
|
178
|
+
"data-slot": "pagination-last-trigger",
|
|
178
179
|
get children () {
|
|
179
180
|
return resolvedChildren() ?? (!local.asChild && createComponent(EdgeIcon, {
|
|
180
181
|
side: "right"
|
|
@@ -8,7 +8,7 @@ function PaginationRoot(props) {
|
|
|
8
8
|
'children',
|
|
9
9
|
'class'
|
|
10
10
|
]);
|
|
11
|
-
return <Pagination.Root asChild={local.asChild}
|
|
11
|
+
return <Pagination.Root asChild={local.asChild} class={cn('inline-flex max-w-full items-center gap-1 overflow-x-auto text-foreground', local.class)} {...others} data-slot="pagination-root">
|
|
12
12
|
{local.children}
|
|
13
13
|
</Pagination.Root>;
|
|
14
14
|
}
|
|
@@ -18,7 +18,7 @@ function PaginationRootProvider(props) {
|
|
|
18
18
|
'children',
|
|
19
19
|
'class'
|
|
20
20
|
]);
|
|
21
|
-
return <Pagination.RootProvider asChild={local.asChild}
|
|
21
|
+
return <Pagination.RootProvider asChild={local.asChild} class={cn('inline-flex max-w-full items-center gap-1 overflow-x-auto text-foreground', local.class)} {...others} data-slot="pagination-root-provider">
|
|
22
22
|
{local.children}
|
|
23
23
|
</Pagination.RootProvider>;
|
|
24
24
|
}
|
|
@@ -27,7 +27,7 @@ function PaginationItem(props) {
|
|
|
27
27
|
'asChild',
|
|
28
28
|
'class'
|
|
29
29
|
]);
|
|
30
|
-
return <Pagination.Item asChild={local.asChild}
|
|
30
|
+
return <Pagination.Item asChild={local.asChild} class={cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-2 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', 'data-selected:border-foreground data-selected:bg-foreground data-selected:text-background [@media(hover:hover)]:hover:bg-accent [@media(hover:hover)]:data-selected:hover:bg-foreground', '[&_svg]:size-4 [&_svg]:shrink-0', local.class)} {...others} data-slot="pagination-item"/>;
|
|
31
31
|
}
|
|
32
32
|
function PaginationEllipsis(props) {
|
|
33
33
|
const [local, others] = splitProps(props, [
|
|
@@ -36,7 +36,7 @@ function PaginationEllipsis(props) {
|
|
|
36
36
|
'class'
|
|
37
37
|
]);
|
|
38
38
|
const resolvedChildren = children(()=>local.children);
|
|
39
|
-
return <Pagination.Ellipsis asChild={local.asChild}
|
|
39
|
+
return <Pagination.Ellipsis asChild={local.asChild} class={cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium text-muted-foreground tabular-nums select-none', local.class)} {...others} data-slot="pagination-ellipsis">
|
|
40
40
|
{resolvedChildren() ?? (!local.asChild && '...')}
|
|
41
41
|
</Pagination.Ellipsis>;
|
|
42
42
|
}
|
|
@@ -53,7 +53,7 @@ function PaginationPrevTrigger(props) {
|
|
|
53
53
|
'class'
|
|
54
54
|
]);
|
|
55
55
|
const resolvedChildren = children(()=>local.children);
|
|
56
|
-
return <Pagination.PrevTrigger asChild={local.asChild}
|
|
56
|
+
return <Pagination.PrevTrigger asChild={local.asChild} class={cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-3 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', '[&_svg]:size-4 [&_svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', null == local.children && 'w-control-md p-0 rtl:[&_svg]:-scale-x-100', local.class)} {...others} data-slot="pagination-prev-trigger">
|
|
57
57
|
{resolvedChildren() ?? (!local.asChild && <ChevronLeftIcon/>)}
|
|
58
58
|
</Pagination.PrevTrigger>;
|
|
59
59
|
}
|
|
@@ -64,7 +64,7 @@ function PaginationNextTrigger(props) {
|
|
|
64
64
|
'class'
|
|
65
65
|
]);
|
|
66
66
|
const resolvedChildren = children(()=>local.children);
|
|
67
|
-
return <Pagination.NextTrigger asChild={local.asChild}
|
|
67
|
+
return <Pagination.NextTrigger asChild={local.asChild} class={cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-3 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', '[&_svg]:size-4 [&_svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', null == local.children && 'w-control-md p-0 rtl:[&_svg]:-scale-x-100', local.class)} {...others} data-slot="pagination-next-trigger">
|
|
68
68
|
{resolvedChildren() ?? (!local.asChild && <ChevronRightIcon/>)}
|
|
69
69
|
</Pagination.NextTrigger>;
|
|
70
70
|
}
|
|
@@ -75,7 +75,7 @@ function PaginationFirstTrigger(props) {
|
|
|
75
75
|
'class'
|
|
76
76
|
]);
|
|
77
77
|
const resolvedChildren = children(()=>local.children);
|
|
78
|
-
return <Pagination.FirstTrigger asChild={local.asChild}
|
|
78
|
+
return <Pagination.FirstTrigger asChild={local.asChild} class={cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-3 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', '[&_svg]:size-4 [&_svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', null == local.children && 'w-control-md p-0 rtl:[&_svg]:-scale-x-100', local.class)} {...others} data-slot="pagination-first-trigger">
|
|
79
79
|
{resolvedChildren() ?? (!local.asChild && <EdgeIcon side="left"/>)}
|
|
80
80
|
</Pagination.FirstTrigger>;
|
|
81
81
|
}
|
|
@@ -86,7 +86,7 @@ function PaginationLastTrigger(props) {
|
|
|
86
86
|
'class'
|
|
87
87
|
]);
|
|
88
88
|
const resolvedChildren = children(()=>local.children);
|
|
89
|
-
return <Pagination.LastTrigger asChild={local.asChild}
|
|
89
|
+
return <Pagination.LastTrigger asChild={local.asChild} class={cn('inline-flex h-control-md min-w-control-md items-center justify-center rounded-md text-sm leading-5 font-medium tabular-nums', 'cursor-pointer gap-2 border border-border bg-background px-3 whitespace-nowrap text-foreground no-underline select-none', 'focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50', '[&_svg]:size-4 [&_svg]:shrink-0 [@media(hover:hover)]:hover:bg-accent', null == local.children && 'w-control-md p-0 rtl:[&_svg]:-scale-x-100', local.class)} {...others} data-slot="pagination-last-trigger">
|
|
90
90
|
{resolvedChildren() ?? (!local.asChild && <EdgeIcon side="right"/>)}
|
|
91
91
|
</Pagination.LastTrigger>;
|
|
92
92
|
}
|
|
@@ -8,44 +8,48 @@ function PasswordInputRoot(props) {
|
|
|
8
8
|
'class'
|
|
9
9
|
]);
|
|
10
10
|
return createComponent(PasswordInput.Root, mergeProps({
|
|
11
|
-
"data-slot": "password-input-root",
|
|
12
11
|
get ["class"] () {
|
|
13
12
|
return cn('flex w-full max-w-none flex-col gap-1 text-foreground data-disabled:opacity-50', local.class);
|
|
14
13
|
}
|
|
15
|
-
}, others
|
|
14
|
+
}, others, {
|
|
15
|
+
"data-slot": "password-input-root"
|
|
16
|
+
}));
|
|
16
17
|
}
|
|
17
18
|
function PasswordInputRootProvider(props) {
|
|
18
19
|
const [local, others] = splitProps(props, [
|
|
19
20
|
'class'
|
|
20
21
|
]);
|
|
21
22
|
return createComponent(PasswordInput.RootProvider, mergeProps({
|
|
22
|
-
"data-slot": "password-input-root-provider",
|
|
23
23
|
get ["class"] () {
|
|
24
24
|
return cn('flex w-full max-w-none flex-col gap-1 text-foreground data-disabled:opacity-50', local.class);
|
|
25
25
|
}
|
|
26
|
-
}, others
|
|
26
|
+
}, others, {
|
|
27
|
+
"data-slot": "password-input-root-provider"
|
|
28
|
+
}));
|
|
27
29
|
}
|
|
28
30
|
function PasswordInputLabel(props) {
|
|
29
31
|
const [local, others] = splitProps(props, [
|
|
30
32
|
'class'
|
|
31
33
|
]);
|
|
32
34
|
return createComponent(PasswordInput.Label, mergeProps({
|
|
33
|
-
"data-slot": "password-input-label",
|
|
34
35
|
get ["class"] () {
|
|
35
36
|
return cn('inline-flex items-center gap-1 text-sm leading-5 font-medium text-foreground', local.class);
|
|
36
37
|
}
|
|
37
|
-
}, others
|
|
38
|
+
}, others, {
|
|
39
|
+
"data-slot": "password-input-label"
|
|
40
|
+
}));
|
|
38
41
|
}
|
|
39
42
|
function PasswordInputControl(props) {
|
|
40
43
|
const [local, others] = splitProps(props, [
|
|
41
44
|
'class'
|
|
42
45
|
]);
|
|
43
46
|
return createComponent(PasswordInput.Control, mergeProps({
|
|
44
|
-
"data-slot": "password-input-control",
|
|
45
47
|
get ["class"] () {
|
|
46
48
|
return cn('flex min-h-control-md w-full items-center rounded-md border border-border bg-background pr-2 text-foreground outline-1 -outline-offset-1 outline-transparent transition-[border-color,outline-color,opacity] duration-200 ease-in-out focus-within:outline-ring data-invalid:border-destructive data-invalid:focus-within:outline-destructive data-readonly:bg-background data-readonly:text-foreground motion-reduce:transition-none', local.class);
|
|
47
49
|
}
|
|
48
|
-
}, others
|
|
50
|
+
}, others, {
|
|
51
|
+
"data-slot": "password-input-control"
|
|
52
|
+
}));
|
|
49
53
|
}
|
|
50
54
|
function PasswordInputInput(props) {
|
|
51
55
|
const [local, others] = splitProps(props, [
|
|
@@ -80,11 +84,12 @@ function PasswordInputVisibilityTrigger(props) {
|
|
|
80
84
|
'class'
|
|
81
85
|
]);
|
|
82
86
|
return createComponent(PasswordInput.VisibilityTrigger, mergeProps({
|
|
83
|
-
"data-slot": "password-input-visibility-trigger",
|
|
84
87
|
get ["class"] () {
|
|
85
88
|
return cn('group/password-input-trigger inline-flex size-control-sm min-w-control-sm shrink-0 cursor-pointer items-center justify-center rounded-sm bg-transparent text-muted-foreground outline-1 -outline-offset-1 outline-transparent transition-[color,outline-color,opacity] duration-200 ease-in-out focus-visible:outline-ring disabled:cursor-default data-disabled:cursor-default data-readonly:cursor-default motion-reduce:transition-none [@media(hover:hover)]:[&:not(:disabled):not([data-disabled]):not([data-readonly]):hover]:text-foreground', local.class);
|
|
86
89
|
}
|
|
87
|
-
}, others
|
|
90
|
+
}, others, {
|
|
91
|
+
"data-slot": "password-input-visibility-trigger"
|
|
92
|
+
}));
|
|
88
93
|
}
|
|
89
94
|
function PasswordInputIndicator(props) {
|
|
90
95
|
const [local, others] = splitProps(props, [
|
|
@@ -94,7 +99,6 @@ function PasswordInputIndicator(props) {
|
|
|
94
99
|
]);
|
|
95
100
|
const resolvedChildren = children(()=>local.children);
|
|
96
101
|
return createComponent(PasswordInput.Indicator, mergeProps({
|
|
97
|
-
"data-slot": "password-input-indicator",
|
|
98
102
|
get ["class"] () {
|
|
99
103
|
return cn("inline-flex items-center justify-center rounded-sm p-1 transition-[background-color,color] duration-200 ease-in-out group-hover/password-input-trigger:bg-muted group-focus-visible/password-input-trigger:bg-muted group-data-[disabled]/password-input-trigger:bg-transparent group-data-[readonly]/password-input-trigger:bg-transparent motion-reduce:transition-none [&>svg:not([class*='size-'])]:size-4", local.class);
|
|
100
104
|
},
|
|
@@ -102,6 +106,7 @@ function PasswordInputIndicator(props) {
|
|
|
102
106
|
return local.fallback ?? createComponent(EyeClosedIcon, {});
|
|
103
107
|
}
|
|
104
108
|
}, others, {
|
|
109
|
+
"data-slot": "password-input-indicator",
|
|
105
110
|
get children () {
|
|
106
111
|
return resolvedChildren() ?? createComponent(EyeIcon, {});
|
|
107
112
|
}
|
|
@@ -6,25 +6,25 @@ function PasswordInputRoot(props) {
|
|
|
6
6
|
const [local, others] = splitProps(props, [
|
|
7
7
|
'class'
|
|
8
8
|
]);
|
|
9
|
-
return <PasswordInput.Root
|
|
9
|
+
return <PasswordInput.Root class={cn('flex w-full max-w-none flex-col gap-1 text-foreground data-disabled:opacity-50', local.class)} {...others} data-slot="password-input-root"/>;
|
|
10
10
|
}
|
|
11
11
|
function PasswordInputRootProvider(props) {
|
|
12
12
|
const [local, others] = splitProps(props, [
|
|
13
13
|
'class'
|
|
14
14
|
]);
|
|
15
|
-
return <PasswordInput.RootProvider
|
|
15
|
+
return <PasswordInput.RootProvider class={cn('flex w-full max-w-none flex-col gap-1 text-foreground data-disabled:opacity-50', local.class)} {...others} data-slot="password-input-root-provider"/>;
|
|
16
16
|
}
|
|
17
17
|
function PasswordInputLabel(props) {
|
|
18
18
|
const [local, others] = splitProps(props, [
|
|
19
19
|
'class'
|
|
20
20
|
]);
|
|
21
|
-
return <PasswordInput.Label
|
|
21
|
+
return <PasswordInput.Label class={cn('inline-flex items-center gap-1 text-sm leading-5 font-medium text-foreground', local.class)} {...others} data-slot="password-input-label"/>;
|
|
22
22
|
}
|
|
23
23
|
function PasswordInputControl(props) {
|
|
24
24
|
const [local, others] = splitProps(props, [
|
|
25
25
|
'class'
|
|
26
26
|
]);
|
|
27
|
-
return <PasswordInput.Control
|
|
27
|
+
return <PasswordInput.Control class={cn('flex min-h-control-md w-full items-center rounded-md border border-border bg-background pr-2 text-foreground outline-1 -outline-offset-1 outline-transparent transition-[border-color,outline-color,opacity] duration-200 ease-in-out focus-within:outline-ring data-invalid:border-destructive data-invalid:focus-within:outline-destructive data-readonly:bg-background data-readonly:text-foreground motion-reduce:transition-none', local.class)} {...others} data-slot="password-input-control"/>;
|
|
28
28
|
}
|
|
29
29
|
function PasswordInputInput(props) {
|
|
30
30
|
const [local, others] = splitProps(props, [
|
|
@@ -48,7 +48,7 @@ function PasswordInputVisibilityTrigger(props) {
|
|
|
48
48
|
const [local, others] = splitProps(props, [
|
|
49
49
|
'class'
|
|
50
50
|
]);
|
|
51
|
-
return <PasswordInput.VisibilityTrigger
|
|
51
|
+
return <PasswordInput.VisibilityTrigger class={cn('group/password-input-trigger inline-flex size-control-sm min-w-control-sm shrink-0 cursor-pointer items-center justify-center rounded-sm bg-transparent text-muted-foreground outline-1 -outline-offset-1 outline-transparent transition-[color,outline-color,opacity] duration-200 ease-in-out focus-visible:outline-ring disabled:cursor-default data-disabled:cursor-default data-readonly:cursor-default motion-reduce:transition-none [@media(hover:hover)]:[&:not(:disabled):not([data-disabled]):not([data-readonly]):hover]:text-foreground', local.class)} {...others} data-slot="password-input-visibility-trigger"/>;
|
|
52
52
|
}
|
|
53
53
|
function PasswordInputIndicator(props) {
|
|
54
54
|
const [local, others] = splitProps(props, [
|
|
@@ -57,7 +57,7 @@ function PasswordInputIndicator(props) {
|
|
|
57
57
|
'fallback'
|
|
58
58
|
]);
|
|
59
59
|
const resolvedChildren = children(()=>local.children);
|
|
60
|
-
return <PasswordInput.Indicator
|
|
60
|
+
return <PasswordInput.Indicator class={cn("inline-flex items-center justify-center rounded-sm p-1 transition-[background-color,color] duration-200 ease-in-out group-hover/password-input-trigger:bg-muted group-focus-visible/password-input-trigger:bg-muted group-data-[disabled]/password-input-trigger:bg-transparent group-data-[readonly]/password-input-trigger:bg-transparent motion-reduce:transition-none [&>svg:not([class*='size-'])]:size-4", local.class)} fallback={local.fallback ?? <EyeClosedIcon/>} {...others} data-slot="password-input-indicator">
|
|
61
61
|
{resolvedChildren() ?? <EyeIcon/>}
|
|
62
62
|
</PasswordInput.Indicator>;
|
|
63
63
|
}
|
|
@@ -3,7 +3,7 @@ import { PinInput, usePinInput, usePinInputContext } from "@ark-ui/solid/pin-inp
|
|
|
3
3
|
import { For, children, splitProps } from "solid-js";
|
|
4
4
|
import { cn } from "../../internal/cn.js";
|
|
5
5
|
import { SeparatorMarkIcon } from "../../internal/icons/ui/Icons.js";
|
|
6
|
-
var _tmpl$ = /*#__PURE__*/ template("<span
|
|
6
|
+
var _tmpl$ = /*#__PURE__*/ template("<span>");
|
|
7
7
|
function PinInputRoot(props) {
|
|
8
8
|
const [local, others] = splitProps(props, [
|
|
9
9
|
'asChild',
|
|
@@ -22,11 +22,11 @@ function PinInputRoot(props) {
|
|
|
22
22
|
get placeholder () {
|
|
23
23
|
return local.placeholder ?? '';
|
|
24
24
|
},
|
|
25
|
-
"data-slot": "pin-input-root",
|
|
26
25
|
get ["class"] () {
|
|
27
26
|
return cn('inline-flex w-auto max-w-none flex-col items-start gap-2 data-disabled:opacity-50', local.class);
|
|
28
27
|
}
|
|
29
28
|
}, others, {
|
|
29
|
+
"data-slot": "pin-input-root",
|
|
30
30
|
get children () {
|
|
31
31
|
return local.children;
|
|
32
32
|
}
|
|
@@ -42,11 +42,11 @@ function PinInputRootProvider(props) {
|
|
|
42
42
|
get asChild () {
|
|
43
43
|
return local.asChild;
|
|
44
44
|
},
|
|
45
|
-
"data-slot": "pin-input-root-provider",
|
|
46
45
|
get ["class"] () {
|
|
47
46
|
return cn('inline-flex w-auto max-w-none flex-col items-start gap-2 data-disabled:opacity-50', local.class);
|
|
48
47
|
}
|
|
49
48
|
}, others, {
|
|
49
|
+
"data-slot": "pin-input-root-provider",
|
|
50
50
|
get children () {
|
|
51
51
|
return local.children;
|
|
52
52
|
}
|
|
@@ -57,33 +57,36 @@ function PinInputLabel(props) {
|
|
|
57
57
|
'class'
|
|
58
58
|
]);
|
|
59
59
|
return createComponent(PinInput.Label, mergeProps({
|
|
60
|
-
"data-slot": "pin-input-label",
|
|
61
60
|
get ["class"] () {
|
|
62
61
|
return cn('text-sm leading-5 font-medium text-foreground', local.class);
|
|
63
62
|
}
|
|
64
|
-
}, others
|
|
63
|
+
}, others, {
|
|
64
|
+
"data-slot": "pin-input-label"
|
|
65
|
+
}));
|
|
65
66
|
}
|
|
66
67
|
function PinInputControl(props) {
|
|
67
68
|
const [local, others] = splitProps(props, [
|
|
68
69
|
'class'
|
|
69
70
|
]);
|
|
70
71
|
return createComponent(PinInput.Control, mergeProps({
|
|
71
|
-
"data-slot": "pin-input-control",
|
|
72
72
|
get ["class"] () {
|
|
73
73
|
return cn('inline-flex items-center gap-2', local.class);
|
|
74
74
|
}
|
|
75
|
-
}, others
|
|
75
|
+
}, others, {
|
|
76
|
+
"data-slot": "pin-input-control"
|
|
77
|
+
}));
|
|
76
78
|
}
|
|
77
79
|
function PinInputInput(props) {
|
|
78
80
|
const [local, others] = splitProps(props, [
|
|
79
81
|
'class'
|
|
80
82
|
]);
|
|
81
83
|
return createComponent(PinInput.Input, mergeProps({
|
|
82
|
-
"data-slot": "pin-input-input",
|
|
83
84
|
get ["class"] () {
|
|
84
85
|
return cn('size-control-md flex-none rounded-md border border-border bg-background px-0 py-0 text-center text-lg leading-7 font-medium text-foreground tabular-nums outline-1 -outline-offset-1 outline-transparent transition-[border-color,outline-color,background-color] duration-200 ease-in-out placeholder:text-muted-foreground focus-visible:outline-ring disabled:pointer-events-none data-disabled:pointer-events-none data-invalid:border-destructive data-invalid:focus-visible:outline-destructive motion-reduce:transition-none', local.class);
|
|
85
86
|
}
|
|
86
|
-
}, others
|
|
87
|
+
}, others, {
|
|
88
|
+
"data-slot": "pin-input-input"
|
|
89
|
+
}));
|
|
87
90
|
}
|
|
88
91
|
function PinInputInputs(props) {
|
|
89
92
|
const pinInput = usePinInputContext();
|
|
@@ -119,7 +122,9 @@ function PinInputSeparator(props) {
|
|
|
119
122
|
get ["class"] () {
|
|
120
123
|
return cn('pointer-events-none inline-flex size-4 flex-none items-center justify-center leading-none text-muted-foreground [&>svg]:size-full [&>svg]:flex-none', local.class);
|
|
121
124
|
}
|
|
122
|
-
}, others
|
|
125
|
+
}, others, {
|
|
126
|
+
"data-slot": "pin-input-separator"
|
|
127
|
+
}), false, true);
|
|
123
128
|
insert(_el$, ()=>resolvedChildren() ?? createComponent(SeparatorMarkIcon, {}));
|
|
124
129
|
return _el$;
|
|
125
130
|
})();
|
|
@@ -10,7 +10,7 @@ function PinInputRoot(props) {
|
|
|
10
10
|
'count',
|
|
11
11
|
'placeholder'
|
|
12
12
|
]);
|
|
13
|
-
return <PinInput.Root asChild={local.asChild} count={local.count} placeholder={local.placeholder ?? ''}
|
|
13
|
+
return <PinInput.Root asChild={local.asChild} count={local.count} placeholder={local.placeholder ?? ''} class={cn('inline-flex w-auto max-w-none flex-col items-start gap-2 data-disabled:opacity-50', local.class)} {...others} data-slot="pin-input-root">
|
|
14
14
|
{local.children}
|
|
15
15
|
</PinInput.Root>;
|
|
16
16
|
}
|
|
@@ -20,7 +20,7 @@ function PinInputRootProvider(props) {
|
|
|
20
20
|
'children',
|
|
21
21
|
'class'
|
|
22
22
|
]);
|
|
23
|
-
return <PinInput.RootProvider asChild={local.asChild}
|
|
23
|
+
return <PinInput.RootProvider asChild={local.asChild} class={cn('inline-flex w-auto max-w-none flex-col items-start gap-2 data-disabled:opacity-50', local.class)} {...others} data-slot="pin-input-root-provider">
|
|
24
24
|
{local.children}
|
|
25
25
|
</PinInput.RootProvider>;
|
|
26
26
|
}
|
|
@@ -28,19 +28,19 @@ function PinInputLabel(props) {
|
|
|
28
28
|
const [local, others] = splitProps(props, [
|
|
29
29
|
'class'
|
|
30
30
|
]);
|
|
31
|
-
return <PinInput.Label
|
|
31
|
+
return <PinInput.Label class={cn('text-sm leading-5 font-medium text-foreground', local.class)} {...others} data-slot="pin-input-label"/>;
|
|
32
32
|
}
|
|
33
33
|
function PinInputControl(props) {
|
|
34
34
|
const [local, others] = splitProps(props, [
|
|
35
35
|
'class'
|
|
36
36
|
]);
|
|
37
|
-
return <PinInput.Control
|
|
37
|
+
return <PinInput.Control class={cn('inline-flex items-center gap-2', local.class)} {...others} data-slot="pin-input-control"/>;
|
|
38
38
|
}
|
|
39
39
|
function PinInputInput(props) {
|
|
40
40
|
const [local, others] = splitProps(props, [
|
|
41
41
|
'class'
|
|
42
42
|
]);
|
|
43
|
-
return <PinInput.Input
|
|
43
|
+
return <PinInput.Input class={cn('size-control-md flex-none rounded-md border border-border bg-background px-0 py-0 text-center text-lg leading-7 font-medium text-foreground tabular-nums outline-1 -outline-offset-1 outline-transparent transition-[border-color,outline-color,background-color] duration-200 ease-in-out placeholder:text-muted-foreground focus-visible:outline-ring disabled:pointer-events-none data-disabled:pointer-events-none data-invalid:border-destructive data-invalid:focus-visible:outline-destructive motion-reduce:transition-none', local.class)} {...others} data-slot="pin-input-input"/>;
|
|
44
44
|
}
|
|
45
45
|
function PinInputInputs(props) {
|
|
46
46
|
const pinInput = usePinInputContext();
|
|
@@ -56,7 +56,7 @@ function PinInputSeparator(props) {
|
|
|
56
56
|
'role'
|
|
57
57
|
]);
|
|
58
58
|
const resolvedChildren = children(()=>local.children);
|
|
59
|
-
return <span
|
|
59
|
+
return <span aria-hidden={local['aria-hidden'] ?? true} role={local.role ?? 'presentation'} class={cn('pointer-events-none inline-flex size-4 flex-none items-center justify-center leading-none text-muted-foreground [&>svg]:size-full [&>svg]:flex-none', local.class)} {...others} data-slot="pin-input-separator">
|
|
60
60
|
{resolvedChildren() ?? <SeparatorMarkIcon/>}
|
|
61
61
|
</span>;
|
|
62
62
|
}
|