@nuxt/ui 3.0.1 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.nuxt/ui/accordion.ts +25 -4
- package/.nuxt/ui/alert.ts +52 -31
- package/.nuxt/ui/avatar-group.ts +24 -3
- package/.nuxt/ui/avatar.ts +26 -5
- package/.nuxt/ui/badge.ts +56 -35
- package/.nuxt/ui/breadcrumb.ts +28 -7
- package/.nuxt/ui/button-group.ts +23 -2
- package/.nuxt/ui/button.ts +66 -45
- package/.nuxt/ui/calendar.ts +39 -18
- package/.nuxt/ui/card.ts +28 -7
- package/.nuxt/ui/carousel.ts +29 -8
- package/.nuxt/ui/checkbox-group.ts +82 -0
- package/.nuxt/ui/checkbox.ts +163 -29
- package/.nuxt/ui/chip.ts +31 -10
- package/.nuxt/ui/collapsible.ts +23 -2
- package/.nuxt/ui/color-picker.ts +26 -5
- package/.nuxt/ui/command-palette.ts +37 -16
- package/.nuxt/ui/container.ts +24 -3
- package/.nuxt/ui/context-menu.ts +56 -35
- package/.nuxt/ui/drawer.ts +33 -12
- package/.nuxt/ui/dropdown-menu.ts +57 -36
- package/.nuxt/ui/form-field.ts +29 -8
- package/.nuxt/ui/form.ts +23 -2
- package/.nuxt/ui/index.ts +1 -0
- package/.nuxt/ui/input-menu.ts +65 -44
- package/.nuxt/ui/input-number.ts +43 -22
- package/.nuxt/ui/input.ts +46 -25
- package/.nuxt/ui/kbd.ts +27 -6
- package/.nuxt/ui/link.ts +26 -5
- package/.nuxt/ui/modal.ts +28 -7
- package/.nuxt/ui/navigation-menu.ts +103 -84
- package/.nuxt/ui/pagination.ts +23 -2
- package/.nuxt/ui/pin-input.ts +43 -22
- package/.nuxt/ui/popover.ts +25 -4
- package/.nuxt/ui/progress.ts +40 -19
- package/.nuxt/ui/radio-group.ts +273 -37
- package/.nuxt/ui/select-menu.ts +59 -35
- package/.nuxt/ui/select.ts +55 -34
- package/.nuxt/ui/separator.ts +31 -10
- package/.nuxt/ui/skeleton.ts +24 -3
- package/.nuxt/ui/slideover.ts +27 -6
- package/.nuxt/ui/slider.ts +39 -18
- package/.nuxt/ui/stepper.ts +41 -20
- package/.nuxt/ui/switch.ts +44 -23
- package/.nuxt/ui/table.ts +38 -17
- package/.nuxt/ui/tabs.ts +55 -34
- package/.nuxt/ui/textarea.ts +63 -37
- package/.nuxt/ui/toast.ts +47 -26
- package/.nuxt/ui/toaster.ts +23 -2
- package/.nuxt/ui/tooltip.ts +25 -4
- package/.nuxt/ui/tree.ts +41 -20
- package/.nuxt/ui.css +56 -12
- package/README.md +11 -0
- package/cli/templates.mjs +18 -17
- package/dist/module.d.mts +2 -1
- package/dist/module.json +5 -5
- package/dist/module.mjs +11 -7
- package/dist/runtime/components/Accordion.vue +36 -92
- package/dist/runtime/components/Accordion.vue.d.ts +91 -0
- package/dist/runtime/components/Alert.vue +37 -100
- package/dist/runtime/components/Alert.vue.d.ts +96 -0
- package/dist/runtime/components/App.vue +28 -34
- package/dist/runtime/components/App.vue.d.ts +24 -0
- package/dist/runtime/components/Avatar.vue +47 -78
- package/dist/runtime/components/Avatar.vue.d.ts +60 -0
- package/dist/runtime/components/AvatarGroup.vue +40 -77
- package/dist/runtime/components/AvatarGroup.vue.d.ts +40 -0
- package/dist/runtime/components/Badge.vue +33 -62
- package/dist/runtime/components/Badge.vue.d.ts +62 -0
- package/dist/runtime/components/Breadcrumb.vue +36 -88
- package/dist/runtime/components/Breadcrumb.vue.d.ts +82 -0
- package/dist/runtime/components/Button.vue +96 -105
- package/dist/runtime/components/Button.vue.d.ts +73 -0
- package/dist/runtime/components/ButtonGroup.vue +20 -46
- package/dist/runtime/components/ButtonGroup.vue.d.ts +55 -0
- package/dist/runtime/components/Calendar.vue +73 -127
- package/dist/runtime/components/Calendar.vue.d.ts +107 -0
- package/dist/runtime/components/Card.vue +18 -40
- package/dist/runtime/components/Card.vue.d.ts +38 -0
- package/dist/runtime/components/Carousel.vue +112 -230
- package/dist/runtime/components/Carousel.vue.d.ts +120 -0
- package/dist/runtime/components/Checkbox.vue +52 -93
- package/dist/runtime/components/Checkbox.vue.d.ts +76 -0
- package/dist/runtime/components/CheckboxGroup.vue +121 -0
- package/dist/runtime/components/CheckboxGroup.vue.d.ts +75 -0
- package/dist/runtime/components/Chip.vue +26 -69
- package/dist/runtime/components/Chip.vue.d.ts +71 -0
- package/dist/runtime/components/Collapsible.vue +22 -41
- package/dist/runtime/components/Collapsible.vue.d.ts +50 -0
- package/dist/runtime/components/ColorPicker.vue +111 -197
- package/dist/runtime/components/ColorPicker.vue.d.ts +63 -0
- package/dist/runtime/components/CommandPalette.vue +94 -234
- package/dist/runtime/components/CommandPalette.vue.d.ts +173 -0
- package/dist/runtime/components/Container.vue +15 -28
- package/dist/runtime/components/Container.vue.d.ts +27 -0
- package/dist/runtime/components/ContextMenu.vue +32 -119
- package/dist/runtime/components/ContextMenu.vue.d.ts +127 -0
- package/dist/runtime/components/ContextMenuContent.vue +71 -72
- package/dist/runtime/components/ContextMenuContent.vue.d.ts +105 -0
- package/dist/runtime/components/Drawer.vue +49 -87
- package/dist/runtime/components/Drawer.vue.d.ts +88 -0
- package/dist/runtime/components/DropdownMenu.vue +37 -129
- package/dist/runtime/components/DropdownMenu.vue.d.ts +141 -0
- package/dist/runtime/components/DropdownMenuContent.vue +76 -79
- package/dist/runtime/components/DropdownMenuContent.vue.d.ts +55 -0
- package/dist/runtime/components/Form.vue +135 -219
- package/dist/runtime/components/Form.vue.d.ts +66 -0
- package/dist/runtime/components/FormField.vue +36 -77
- package/dist/runtime/components/FormField.vue.d.ts +70 -0
- package/dist/runtime/components/Icon.vue +12 -19
- package/dist/runtime/components/Icon.vue.d.ts +17 -0
- package/dist/runtime/components/Input.vue +82 -140
- package/dist/runtime/components/Input.vue.d.ts +91 -0
- package/dist/runtime/components/InputMenu.vue +193 -302
- package/dist/runtime/components/InputMenu.vue.d.ts +312 -0
- package/dist/runtime/components/InputNumber.vue +71 -133
- package/dist/runtime/components/InputNumber.vue.d.ts +193 -0
- package/dist/runtime/components/Kbd.vue +20 -46
- package/dist/runtime/components/Kbd.vue.d.ts +55 -0
- package/dist/runtime/components/Link.vue +98 -173
- package/dist/runtime/components/Link.vue.d.ts +124 -0
- package/dist/runtime/components/LinkBase.vue +33 -41
- package/dist/runtime/components/LinkBase.vue.d.ts +48 -0
- package/dist/runtime/components/Modal.vue +53 -116
- package/dist/runtime/components/Modal.vue.d.ts +109 -0
- package/dist/runtime/components/NavigationMenu.vue +78 -186
- package/dist/runtime/components/NavigationMenu.vue.d.ts +159 -0
- package/dist/runtime/components/OverlayProvider.vue +14 -18
- package/dist/runtime/components/OverlayProvider.vue.d.ts +2 -0
- package/dist/runtime/components/Pagination.vue +46 -140
- package/dist/runtime/components/Pagination.vue.d.ts +143 -0
- package/dist/runtime/components/PinInput.vue +61 -78
- package/dist/runtime/components/PinInput.vue.d.ts +68 -0
- package/dist/runtime/components/Popover.vue +47 -84
- package/dist/runtime/components/Popover.vue.d.ts +80 -0
- package/dist/runtime/components/Progress.vue +70 -131
- package/dist/runtime/components/Progress.vue.d.ts +97 -0
- package/dist/runtime/components/RadioGroup.vue +75 -126
- package/dist/runtime/components/RadioGroup.vue.d.ts +88 -0
- package/dist/runtime/components/Select.vue +115 -202
- package/dist/runtime/components/Select.vue.d.ts +139 -0
- package/dist/runtime/components/SelectMenu.vue +167 -281
- package/dist/runtime/components/SelectMenu.vue.d.ts +184 -0
- package/dist/runtime/components/Separator.vue +29 -71
- package/dist/runtime/components/Separator.vue.d.ts +75 -0
- package/dist/runtime/components/Skeleton.vue +21 -23
- package/dist/runtime/components/Skeleton.vue.d.ts +26 -0
- package/dist/runtime/components/Slideover.vue +53 -120
- package/dist/runtime/components/Slideover.vue.d.ts +111 -0
- package/dist/runtime/components/Slider.vue +46 -84
- package/dist/runtime/components/Slider.vue.d.ts +71 -0
- package/dist/runtime/components/Stepper.vue +44 -113
- package/dist/runtime/components/Stepper.vue.d.ts +89 -0
- package/dist/runtime/components/Switch.vue +45 -93
- package/dist/runtime/components/Switch.vue.d.ts +73 -0
- package/dist/runtime/components/Table.vue +165 -264
- package/dist/runtime/components/Table.vue.d.ts +183 -0
- package/dist/runtime/components/Tabs.vue +40 -105
- package/dist/runtime/components/Tabs.vue.d.ts +104 -0
- package/dist/runtime/components/Textarea.vue +113 -158
- package/dist/runtime/components/Textarea.vue.d.ts +95 -0
- package/dist/runtime/components/Toast.vue +49 -110
- package/dist/runtime/components/Toast.vue.d.ts +95 -0
- package/dist/runtime/components/Toaster.vue +70 -107
- package/dist/runtime/components/Toaster.vue.d.ts +63 -0
- package/dist/runtime/components/Tooltip.vue +38 -65
- package/dist/runtime/components/Tooltip.vue.d.ts +65 -0
- package/dist/runtime/components/Tree.vue +57 -150
- package/dist/runtime/components/Tree.vue.d.ts +128 -0
- package/dist/runtime/composables/defineShortcuts.d.ts +1 -1
- package/dist/runtime/composables/defineShortcuts.js +0 -1
- package/dist/runtime/composables/useAvatarGroup.d.ts +1 -1
- package/dist/runtime/composables/useButtonGroup.d.ts +2 -2
- package/dist/runtime/composables/useFormField.d.ts +2 -2
- package/dist/runtime/composables/useFormField.js +1 -1
- package/dist/runtime/composables/useOverlay.d.ts +16 -8
- package/dist/runtime/composables/useOverlay.js +14 -6
- package/dist/runtime/composables/usePortal.d.ts +6 -0
- package/dist/runtime/composables/usePortal.js +17 -0
- package/dist/runtime/index.css +1 -1
- package/dist/runtime/inertia/components/Link.vue +146 -0
- package/dist/runtime/inertia/components/Link.vue.d.ts +92 -0
- package/dist/runtime/inertia/stubs.d.ts +43 -0
- package/dist/runtime/inertia/stubs.js +82 -0
- package/dist/runtime/locale/bg.d.ts +3 -0
- package/dist/runtime/locale/bg.js +54 -0
- package/dist/runtime/locale/hy.d.ts +3 -0
- package/dist/runtime/locale/hy.js +54 -0
- package/dist/runtime/locale/index.d.ts +6 -1
- package/dist/runtime/locale/index.js +6 -1
- package/dist/runtime/locale/kk.d.ts +3 -0
- package/dist/runtime/locale/kk.js +54 -0
- package/dist/runtime/locale/tj.d.ts +3 -0
- package/dist/runtime/locale/tj.js +54 -0
- package/dist/runtime/locale/ug_cn.d.ts +3 -0
- package/dist/runtime/locale/ug_cn.js +55 -0
- package/dist/runtime/types/form.d.ts +5 -1
- package/dist/runtime/types/index.d.ts +2 -0
- package/dist/runtime/types/index.js +2 -0
- package/dist/runtime/types/utils.d.ts +70 -10
- package/dist/runtime/utils/index.d.ts +1 -0
- package/dist/runtime/utils/index.js +3 -0
- package/dist/runtime/utils/link.d.ts +4 -27
- package/dist/runtime/utils/link.js +32 -1
- package/dist/runtime/utils/tv.js +2 -2
- package/dist/runtime/vue/components/Icon.vue +7 -8
- package/dist/runtime/vue/components/Icon.vue.d.ts +14 -0
- package/dist/runtime/vue/components/Link.vue +118 -199
- package/dist/runtime/vue/components/Link.vue.d.ts +124 -0
- package/dist/runtime/vue/stubs.d.ts +5 -0
- package/dist/runtime/vue/stubs.js +11 -2
- package/dist/shared/{ui.BCaWD5Ek.mjs → ui.D7lOOabO.mjs} +623 -364
- package/dist/types.d.mts +5 -1
- package/dist/unplugin.d.mts +6 -1
- package/dist/unplugin.mjs +25 -4
- package/dist/vite.mjs +1 -1
- package/package.json +122 -64
- package/dist/module.cjs +0 -62
- package/dist/module.d.cts +0 -44
- package/dist/module.d.ts +0 -44
- package/dist/shared/ui.C6uTSFTI.cjs +0 -3555
- package/dist/types.d.ts +0 -1
- package/dist/unplugin.cjs +0 -232
- package/dist/unplugin.d.cts +0 -61
- package/dist/unplugin.d.ts +0 -61
- package/dist/vite.cjs +0 -23
- package/dist/vite.d.cts +0 -15
- package/dist/vite.d.ts +0 -15
package/.nuxt/ui/radio-group.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import template from "/home/runner/work/ui/ui/src/theme/radio-group"
|
|
2
|
+
|
|
1
3
|
const color = [
|
|
2
4
|
"primary",
|
|
3
5
|
"secondary",
|
|
@@ -8,11 +10,23 @@ const color = [
|
|
|
8
10
|
"neutral"
|
|
9
11
|
] as const
|
|
10
12
|
|
|
13
|
+
const variant = [
|
|
14
|
+
"list",
|
|
15
|
+
"card",
|
|
16
|
+
"table"
|
|
17
|
+
] as const
|
|
18
|
+
|
|
11
19
|
const orientation = [
|
|
12
20
|
"horizontal",
|
|
13
21
|
"vertical"
|
|
14
22
|
] as const
|
|
15
23
|
|
|
24
|
+
const indicator = [
|
|
25
|
+
"start",
|
|
26
|
+
"end",
|
|
27
|
+
"hidden"
|
|
28
|
+
] as const
|
|
29
|
+
|
|
16
30
|
const size = [
|
|
17
31
|
"xs",
|
|
18
32
|
"sm",
|
|
@@ -21,99 +35,140 @@ const size = [
|
|
|
21
35
|
"xl"
|
|
22
36
|
] as const
|
|
23
37
|
|
|
24
|
-
|
|
38
|
+
const result = typeof template === 'function' ? (template as Function)({
|
|
39
|
+
"prefix": "U",
|
|
40
|
+
"fonts": true,
|
|
41
|
+
"colorMode": true,
|
|
42
|
+
"theme": {
|
|
43
|
+
"colors": [
|
|
44
|
+
"primary",
|
|
45
|
+
"secondary",
|
|
46
|
+
"success",
|
|
47
|
+
"info",
|
|
48
|
+
"warning",
|
|
49
|
+
"error"
|
|
50
|
+
],
|
|
51
|
+
"transitions": true
|
|
52
|
+
}
|
|
53
|
+
}) : template
|
|
54
|
+
|
|
55
|
+
const theme = {
|
|
25
56
|
"slots": {
|
|
26
57
|
"root": "relative",
|
|
27
|
-
"fieldset": "flex",
|
|
28
|
-
"legend": "mb-1 block font-medium text-
|
|
58
|
+
"fieldset": "flex gap-x-2",
|
|
59
|
+
"legend": "mb-1 block font-medium text-default",
|
|
29
60
|
"item": "flex items-start",
|
|
30
|
-
"base": "rounded-full ring ring-inset ring-(--ui-border-accented) focus-visible:outline-2 focus-visible:outline-offset-2",
|
|
31
|
-
"indicator": "flex items-center justify-center size-full rounded-full after:bg-(--ui-bg) after:rounded-full",
|
|
32
61
|
"container": "flex items-center",
|
|
33
|
-
"
|
|
34
|
-
"
|
|
35
|
-
"
|
|
62
|
+
"base": "rounded-full ring ring-inset ring-accented overflow-hidden focus-visible:outline-2 focus-visible:outline-offset-2",
|
|
63
|
+
"indicator": "flex items-center justify-center size-full after:bg-default after:rounded-full" as typeof indicator[number],
|
|
64
|
+
"wrapper": "w-full",
|
|
65
|
+
"label": "block font-medium text-default",
|
|
66
|
+
"description": "text-muted"
|
|
36
67
|
},
|
|
37
68
|
"variants": {
|
|
38
69
|
"color": {
|
|
39
70
|
"primary": {
|
|
40
|
-
"base": "focus-visible:outline-
|
|
41
|
-
"indicator": "bg-
|
|
71
|
+
"base": "focus-visible:outline-primary",
|
|
72
|
+
"indicator": "bg-primary" as typeof indicator[number]
|
|
42
73
|
},
|
|
43
74
|
"secondary": {
|
|
44
|
-
"base": "focus-visible:outline-
|
|
45
|
-
"indicator": "bg-
|
|
75
|
+
"base": "focus-visible:outline-secondary",
|
|
76
|
+
"indicator": "bg-secondary" as typeof indicator[number]
|
|
46
77
|
},
|
|
47
78
|
"success": {
|
|
48
|
-
"base": "focus-visible:outline-
|
|
49
|
-
"indicator": "bg-
|
|
79
|
+
"base": "focus-visible:outline-success",
|
|
80
|
+
"indicator": "bg-success" as typeof indicator[number]
|
|
50
81
|
},
|
|
51
82
|
"info": {
|
|
52
|
-
"base": "focus-visible:outline-
|
|
53
|
-
"indicator": "bg-
|
|
83
|
+
"base": "focus-visible:outline-info",
|
|
84
|
+
"indicator": "bg-info" as typeof indicator[number]
|
|
54
85
|
},
|
|
55
86
|
"warning": {
|
|
56
|
-
"base": "focus-visible:outline-
|
|
57
|
-
"indicator": "bg-
|
|
87
|
+
"base": "focus-visible:outline-warning",
|
|
88
|
+
"indicator": "bg-warning" as typeof indicator[number]
|
|
58
89
|
},
|
|
59
90
|
"error": {
|
|
60
|
-
"base": "focus-visible:outline-
|
|
61
|
-
"indicator": "bg-
|
|
91
|
+
"base": "focus-visible:outline-error",
|
|
92
|
+
"indicator": "bg-error" as typeof indicator[number]
|
|
62
93
|
},
|
|
63
94
|
"neutral": {
|
|
64
|
-
"base": "focus-visible:outline-
|
|
65
|
-
"indicator": "bg-
|
|
95
|
+
"base": "focus-visible:outline-inverted",
|
|
96
|
+
"indicator": "bg-inverted" as typeof indicator[number]
|
|
97
|
+
}
|
|
98
|
+
},
|
|
99
|
+
"variant": {
|
|
100
|
+
"list": {
|
|
101
|
+
"item": ""
|
|
102
|
+
},
|
|
103
|
+
"card": {
|
|
104
|
+
"item": "border border-muted rounded-lg"
|
|
105
|
+
},
|
|
106
|
+
"table": {
|
|
107
|
+
"item": "border border-muted"
|
|
66
108
|
}
|
|
67
109
|
},
|
|
68
110
|
"orientation": {
|
|
69
111
|
"horizontal": {
|
|
70
|
-
"fieldset": "flex-row"
|
|
71
|
-
"wrapper": "me-2"
|
|
112
|
+
"fieldset": "flex-row"
|
|
72
113
|
},
|
|
73
114
|
"vertical": {
|
|
74
115
|
"fieldset": "flex-col"
|
|
75
116
|
}
|
|
76
117
|
},
|
|
118
|
+
"indicator": {
|
|
119
|
+
"start": {
|
|
120
|
+
"item": "flex-row",
|
|
121
|
+
"wrapper": "ms-2"
|
|
122
|
+
},
|
|
123
|
+
"end": {
|
|
124
|
+
"item": "flex-row-reverse",
|
|
125
|
+
"wrapper": "me-2"
|
|
126
|
+
},
|
|
127
|
+
"hidden": {
|
|
128
|
+
"base": "sr-only",
|
|
129
|
+
"wrapper": "text-center"
|
|
130
|
+
}
|
|
131
|
+
},
|
|
77
132
|
"size": {
|
|
78
133
|
"xs": {
|
|
79
|
-
"fieldset": "gap-0.5",
|
|
134
|
+
"fieldset": "gap-y-0.5",
|
|
80
135
|
"legend": "text-xs",
|
|
81
136
|
"base": "size-3",
|
|
82
137
|
"item": "text-xs",
|
|
83
138
|
"container": "h-4",
|
|
84
|
-
"indicator": "after:size-1"
|
|
139
|
+
"indicator": "after:size-1" as typeof indicator[number]
|
|
85
140
|
},
|
|
86
141
|
"sm": {
|
|
87
|
-
"fieldset": "gap-0.5",
|
|
142
|
+
"fieldset": "gap-y-0.5",
|
|
88
143
|
"legend": "text-xs",
|
|
89
144
|
"base": "size-3.5",
|
|
90
145
|
"item": "text-xs",
|
|
91
146
|
"container": "h-4",
|
|
92
|
-
"indicator": "after:size-1"
|
|
147
|
+
"indicator": "after:size-1" as typeof indicator[number]
|
|
93
148
|
},
|
|
94
149
|
"md": {
|
|
95
|
-
"fieldset": "gap-1",
|
|
150
|
+
"fieldset": "gap-y-1",
|
|
96
151
|
"legend": "text-sm",
|
|
97
152
|
"base": "size-4",
|
|
98
153
|
"item": "text-sm",
|
|
99
154
|
"container": "h-5",
|
|
100
|
-
"indicator": "after:size-1.5"
|
|
155
|
+
"indicator": "after:size-1.5" as typeof indicator[number]
|
|
101
156
|
},
|
|
102
157
|
"lg": {
|
|
103
|
-
"fieldset": "gap-1",
|
|
158
|
+
"fieldset": "gap-y-1",
|
|
104
159
|
"legend": "text-sm",
|
|
105
160
|
"base": "size-4.5",
|
|
106
161
|
"item": "text-sm",
|
|
107
162
|
"container": "h-5",
|
|
108
|
-
"indicator": "after:size-1.5"
|
|
163
|
+
"indicator": "after:size-1.5" as typeof indicator[number]
|
|
109
164
|
},
|
|
110
165
|
"xl": {
|
|
111
|
-
"fieldset": "gap-1.5",
|
|
166
|
+
"fieldset": "gap-y-1.5",
|
|
112
167
|
"legend": "text-base",
|
|
113
168
|
"base": "size-5",
|
|
114
169
|
"item": "text-base",
|
|
115
170
|
"container": "h-6",
|
|
116
|
-
"indicator": "after:size-2"
|
|
171
|
+
"indicator": "after:size-2" as typeof indicator[number]
|
|
117
172
|
}
|
|
118
173
|
},
|
|
119
174
|
"disabled": {
|
|
@@ -124,12 +179,193 @@ export default {
|
|
|
124
179
|
},
|
|
125
180
|
"required": {
|
|
126
181
|
"true": {
|
|
127
|
-
"legend": "after:content-['*'] after:ms-0.5 after:text-
|
|
182
|
+
"legend": "after:content-['*'] after:ms-0.5 after:text-error"
|
|
128
183
|
}
|
|
129
184
|
}
|
|
130
185
|
},
|
|
186
|
+
"compoundVariants": [
|
|
187
|
+
{
|
|
188
|
+
"size": "xs" as typeof size[number],
|
|
189
|
+
"variant": [
|
|
190
|
+
"card" as typeof variant[number],
|
|
191
|
+
"table" as typeof variant[number]
|
|
192
|
+
],
|
|
193
|
+
"class": {
|
|
194
|
+
"item": "p-2.5"
|
|
195
|
+
}
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
"size": "sm" as typeof size[number],
|
|
199
|
+
"variant": [
|
|
200
|
+
"card" as typeof variant[number],
|
|
201
|
+
"table" as typeof variant[number]
|
|
202
|
+
],
|
|
203
|
+
"class": {
|
|
204
|
+
"item": "p-3"
|
|
205
|
+
}
|
|
206
|
+
},
|
|
207
|
+
{
|
|
208
|
+
"size": "md" as typeof size[number],
|
|
209
|
+
"variant": [
|
|
210
|
+
"card" as typeof variant[number],
|
|
211
|
+
"table" as typeof variant[number]
|
|
212
|
+
],
|
|
213
|
+
"class": {
|
|
214
|
+
"item": "p-3.5"
|
|
215
|
+
}
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
"size": "lg" as typeof size[number],
|
|
219
|
+
"variant": [
|
|
220
|
+
"card" as typeof variant[number],
|
|
221
|
+
"table" as typeof variant[number]
|
|
222
|
+
],
|
|
223
|
+
"class": {
|
|
224
|
+
"item": "p-4"
|
|
225
|
+
}
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
"size": "xl" as typeof size[number],
|
|
229
|
+
"variant": [
|
|
230
|
+
"card" as typeof variant[number],
|
|
231
|
+
"table" as typeof variant[number]
|
|
232
|
+
],
|
|
233
|
+
"class": {
|
|
234
|
+
"item": "p-4.5"
|
|
235
|
+
}
|
|
236
|
+
},
|
|
237
|
+
{
|
|
238
|
+
"orientation": "horizontal" as typeof orientation[number],
|
|
239
|
+
"variant": "table" as typeof variant[number],
|
|
240
|
+
"class": {
|
|
241
|
+
"item": "first-of-type:rounded-l-lg last-of-type:rounded-r-lg",
|
|
242
|
+
"fieldset": "gap-0 -space-x-px"
|
|
243
|
+
}
|
|
244
|
+
},
|
|
245
|
+
{
|
|
246
|
+
"orientation": "vertical" as typeof orientation[number],
|
|
247
|
+
"variant": "table" as typeof variant[number],
|
|
248
|
+
"class": {
|
|
249
|
+
"item": "first-of-type:rounded-t-lg last-of-type:rounded-b-lg",
|
|
250
|
+
"fieldset": "gap-0 -space-y-px"
|
|
251
|
+
}
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
"color": "primary" as typeof color[number],
|
|
255
|
+
"variant": "card" as typeof variant[number],
|
|
256
|
+
"class": {
|
|
257
|
+
"item": "has-data-[state=checked]:border-primary"
|
|
258
|
+
}
|
|
259
|
+
},
|
|
260
|
+
{
|
|
261
|
+
"color": "secondary" as typeof color[number],
|
|
262
|
+
"variant": "card" as typeof variant[number],
|
|
263
|
+
"class": {
|
|
264
|
+
"item": "has-data-[state=checked]:border-secondary"
|
|
265
|
+
}
|
|
266
|
+
},
|
|
267
|
+
{
|
|
268
|
+
"color": "success" as typeof color[number],
|
|
269
|
+
"variant": "card" as typeof variant[number],
|
|
270
|
+
"class": {
|
|
271
|
+
"item": "has-data-[state=checked]:border-success"
|
|
272
|
+
}
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
"color": "info" as typeof color[number],
|
|
276
|
+
"variant": "card" as typeof variant[number],
|
|
277
|
+
"class": {
|
|
278
|
+
"item": "has-data-[state=checked]:border-info"
|
|
279
|
+
}
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
"color": "warning" as typeof color[number],
|
|
283
|
+
"variant": "card" as typeof variant[number],
|
|
284
|
+
"class": {
|
|
285
|
+
"item": "has-data-[state=checked]:border-warning"
|
|
286
|
+
}
|
|
287
|
+
},
|
|
288
|
+
{
|
|
289
|
+
"color": "error" as typeof color[number],
|
|
290
|
+
"variant": "card" as typeof variant[number],
|
|
291
|
+
"class": {
|
|
292
|
+
"item": "has-data-[state=checked]:border-error"
|
|
293
|
+
}
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
"color": "neutral" as typeof color[number],
|
|
297
|
+
"variant": "card" as typeof variant[number],
|
|
298
|
+
"class": {
|
|
299
|
+
"item": "has-data-[state=checked]:border-inverted"
|
|
300
|
+
}
|
|
301
|
+
},
|
|
302
|
+
{
|
|
303
|
+
"color": "primary" as typeof color[number],
|
|
304
|
+
"variant": "table" as typeof variant[number],
|
|
305
|
+
"class": {
|
|
306
|
+
"item": "has-data-[state=checked]:bg-primary/10 has-data-[state=checked]:border-primary/50 has-data-[state=checked]:z-[1]"
|
|
307
|
+
}
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
"color": "secondary" as typeof color[number],
|
|
311
|
+
"variant": "table" as typeof variant[number],
|
|
312
|
+
"class": {
|
|
313
|
+
"item": "has-data-[state=checked]:bg-secondary/10 has-data-[state=checked]:border-secondary/50 has-data-[state=checked]:z-[1]"
|
|
314
|
+
}
|
|
315
|
+
},
|
|
316
|
+
{
|
|
317
|
+
"color": "success" as typeof color[number],
|
|
318
|
+
"variant": "table" as typeof variant[number],
|
|
319
|
+
"class": {
|
|
320
|
+
"item": "has-data-[state=checked]:bg-success/10 has-data-[state=checked]:border-success/50 has-data-[state=checked]:z-[1]"
|
|
321
|
+
}
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
"color": "info" as typeof color[number],
|
|
325
|
+
"variant": "table" as typeof variant[number],
|
|
326
|
+
"class": {
|
|
327
|
+
"item": "has-data-[state=checked]:bg-info/10 has-data-[state=checked]:border-info/50 has-data-[state=checked]:z-[1]"
|
|
328
|
+
}
|
|
329
|
+
},
|
|
330
|
+
{
|
|
331
|
+
"color": "warning" as typeof color[number],
|
|
332
|
+
"variant": "table" as typeof variant[number],
|
|
333
|
+
"class": {
|
|
334
|
+
"item": "has-data-[state=checked]:bg-warning/10 has-data-[state=checked]:border-warning/50 has-data-[state=checked]:z-[1]"
|
|
335
|
+
}
|
|
336
|
+
},
|
|
337
|
+
{
|
|
338
|
+
"color": "error" as typeof color[number],
|
|
339
|
+
"variant": "table" as typeof variant[number],
|
|
340
|
+
"class": {
|
|
341
|
+
"item": "has-data-[state=checked]:bg-error/10 has-data-[state=checked]:border-error/50 has-data-[state=checked]:z-[1]"
|
|
342
|
+
}
|
|
343
|
+
},
|
|
344
|
+
{
|
|
345
|
+
"color": "neutral" as typeof color[number],
|
|
346
|
+
"variant": "table" as typeof variant[number],
|
|
347
|
+
"class": {
|
|
348
|
+
"item": "has-data-[state=checked]:bg-elevated has-data-[state=checked]:border-inverted/50 has-data-[state=checked]:z-[1]"
|
|
349
|
+
}
|
|
350
|
+
},
|
|
351
|
+
{
|
|
352
|
+
"variant": [
|
|
353
|
+
"card" as typeof variant[number],
|
|
354
|
+
"table" as typeof variant[number]
|
|
355
|
+
],
|
|
356
|
+
"disabled": true,
|
|
357
|
+
"class": {
|
|
358
|
+
"item": "cursor-not-allowed opacity-75"
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
],
|
|
131
362
|
"defaultVariants": {
|
|
132
363
|
"size": "md" as typeof size[number],
|
|
133
|
-
"color": "primary" as typeof color[number]
|
|
364
|
+
"color": "primary" as typeof color[number],
|
|
365
|
+
"variant": "list" as typeof variant[number],
|
|
366
|
+
"orientation": "vertical" as typeof orientation[number],
|
|
367
|
+
"indicator": "start" as typeof indicator[number]
|
|
134
368
|
}
|
|
135
|
-
}
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
export default result as typeof theme
|
package/.nuxt/ui/select-menu.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import template from "/home/runner/work/ui/ui/src/theme/select-menu"
|
|
2
|
+
|
|
1
3
|
const buttonGroup = [
|
|
2
4
|
"horizontal",
|
|
3
5
|
"vertical"
|
|
@@ -33,33 +35,53 @@ const type = [
|
|
|
33
35
|
"file"
|
|
34
36
|
] as const
|
|
35
37
|
|
|
36
|
-
|
|
38
|
+
const result = typeof template === 'function' ? (template as Function)({
|
|
39
|
+
"prefix": "U",
|
|
40
|
+
"fonts": true,
|
|
41
|
+
"colorMode": true,
|
|
42
|
+
"theme": {
|
|
43
|
+
"colors": [
|
|
44
|
+
"primary",
|
|
45
|
+
"secondary",
|
|
46
|
+
"success",
|
|
47
|
+
"info",
|
|
48
|
+
"warning",
|
|
49
|
+
"error"
|
|
50
|
+
],
|
|
51
|
+
"transitions": true
|
|
52
|
+
}
|
|
53
|
+
}) : template
|
|
54
|
+
|
|
55
|
+
const theme = {
|
|
37
56
|
"slots": {
|
|
38
57
|
"base": [
|
|
39
|
-
"relative group rounded-
|
|
58
|
+
"relative group rounded-md inline-flex items-center focus:outline-none disabled:cursor-not-allowed disabled:opacity-75",
|
|
40
59
|
"transition-colors"
|
|
41
60
|
],
|
|
42
61
|
"leading": "absolute inset-y-0 start-0 flex items-center",
|
|
43
|
-
"leadingIcon": "shrink-0 text-
|
|
62
|
+
"leadingIcon": "shrink-0 text-dimmed",
|
|
44
63
|
"leadingAvatar": "shrink-0",
|
|
45
64
|
"leadingAvatarSize": "",
|
|
46
65
|
"trailing": "absolute inset-y-0 end-0 flex items-center",
|
|
47
|
-
"trailingIcon": "shrink-0 text-
|
|
66
|
+
"trailingIcon": "shrink-0 text-dimmed",
|
|
48
67
|
"value": "truncate pointer-events-none",
|
|
49
|
-
"placeholder": "truncate text-
|
|
50
|
-
"arrow": "fill-
|
|
51
|
-
"content":
|
|
52
|
-
|
|
68
|
+
"placeholder": "truncate text-dimmed",
|
|
69
|
+
"arrow": "fill-default",
|
|
70
|
+
"content": [
|
|
71
|
+
"max-h-60 w-(--reka-select-trigger-width) bg-default shadow-lg rounded-md ring ring-default overflow-hidden data-[state=open]:animate-[scale-in_100ms_ease-out] data-[state=closed]:animate-[scale-out_100ms_ease-in] origin-(--reka-select-content-transform-origin) pointer-events-auto",
|
|
72
|
+
"origin-(--reka-combobox-content-transform-origin) w-(--reka-combobox-trigger-width)"
|
|
73
|
+
],
|
|
74
|
+
"viewport": "divide-y divide-default scroll-py-1",
|
|
53
75
|
"group": "p-1 isolate",
|
|
54
|
-
"empty": "py-2 text-center text-sm text-
|
|
55
|
-
"label": "font-semibold text-
|
|
56
|
-
"separator": "-mx-1 my-1 h-px bg-
|
|
76
|
+
"empty": "py-2 text-center text-sm text-muted",
|
|
77
|
+
"label": "font-semibold text-highlighted",
|
|
78
|
+
"separator": "-mx-1 my-1 h-px bg-border",
|
|
57
79
|
"item": [
|
|
58
|
-
"group relative w-full flex items-center select-none outline-none before:absolute before:z-[-1] before:inset-px before:rounded-
|
|
80
|
+
"group relative w-full flex items-center select-none outline-none before:absolute before:z-[-1] before:inset-px before:rounded-md data-disabled:cursor-not-allowed data-disabled:opacity-75 text-default data-highlighted:not-data-disabled:text-highlighted data-highlighted:not-data-disabled:before:bg-elevated/50",
|
|
59
81
|
"transition-colors before:transition-colors"
|
|
60
82
|
],
|
|
61
83
|
"itemLeadingIcon": [
|
|
62
|
-
"shrink-0 text-
|
|
84
|
+
"shrink-0 text-dimmed group-data-highlighted:not-group-data-disabled:text-default",
|
|
63
85
|
"transition-colors"
|
|
64
86
|
],
|
|
65
87
|
"itemLeadingAvatar": "shrink-0",
|
|
@@ -69,7 +91,7 @@ export default {
|
|
|
69
91
|
"itemTrailing": "ms-auto inline-flex gap-1.5 items-center",
|
|
70
92
|
"itemTrailingIcon": "shrink-0",
|
|
71
93
|
"itemLabel": "truncate",
|
|
72
|
-
"input": "border-b border-
|
|
94
|
+
"input": "border-b border-default",
|
|
73
95
|
"focusScope": "flex flex-col min-h-0"
|
|
74
96
|
},
|
|
75
97
|
"variants": {
|
|
@@ -155,11 +177,11 @@ export default {
|
|
|
155
177
|
}
|
|
156
178
|
},
|
|
157
179
|
"variant": {
|
|
158
|
-
"outline": "text-
|
|
159
|
-
"soft": "text-
|
|
160
|
-
"subtle": "text-
|
|
161
|
-
"ghost": "text-
|
|
162
|
-
"none": "text-
|
|
180
|
+
"outline": "text-highlighted bg-default ring ring-inset ring-accented",
|
|
181
|
+
"soft": "text-highlighted bg-elevated/50 hover:bg-elevated focus:bg-elevated disabled:bg-elevated/50",
|
|
182
|
+
"subtle": "text-highlighted bg-elevated ring ring-inset ring-accented",
|
|
183
|
+
"ghost": "text-highlighted bg-transparent hover:bg-elevated focus:bg-elevated disabled:bg-transparent dark:disabled:bg-transparent",
|
|
184
|
+
"none": "text-highlighted bg-transparent"
|
|
163
185
|
},
|
|
164
186
|
"color": {
|
|
165
187
|
"primary": "",
|
|
@@ -183,7 +205,7 @@ export default {
|
|
|
183
205
|
"true": ""
|
|
184
206
|
},
|
|
185
207
|
"type": {
|
|
186
|
-
"file": "file:me-1.5 file:font-medium file:text-
|
|
208
|
+
"file": "file:me-1.5 file:font-medium file:text-muted file:outline-none"
|
|
187
209
|
}
|
|
188
210
|
},
|
|
189
211
|
"compoundVariants": [
|
|
@@ -193,7 +215,7 @@ export default {
|
|
|
193
215
|
"outline" as typeof variant[number],
|
|
194
216
|
"subtle" as typeof variant[number]
|
|
195
217
|
],
|
|
196
|
-
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-
|
|
218
|
+
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-primary"
|
|
197
219
|
},
|
|
198
220
|
{
|
|
199
221
|
"color": "secondary" as typeof color[number],
|
|
@@ -201,7 +223,7 @@ export default {
|
|
|
201
223
|
"outline" as typeof variant[number],
|
|
202
224
|
"subtle" as typeof variant[number]
|
|
203
225
|
],
|
|
204
|
-
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-
|
|
226
|
+
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-secondary"
|
|
205
227
|
},
|
|
206
228
|
{
|
|
207
229
|
"color": "success" as typeof color[number],
|
|
@@ -209,7 +231,7 @@ export default {
|
|
|
209
231
|
"outline" as typeof variant[number],
|
|
210
232
|
"subtle" as typeof variant[number]
|
|
211
233
|
],
|
|
212
|
-
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-
|
|
234
|
+
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-success"
|
|
213
235
|
},
|
|
214
236
|
{
|
|
215
237
|
"color": "info" as typeof color[number],
|
|
@@ -217,7 +239,7 @@ export default {
|
|
|
217
239
|
"outline" as typeof variant[number],
|
|
218
240
|
"subtle" as typeof variant[number]
|
|
219
241
|
],
|
|
220
|
-
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-
|
|
242
|
+
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-info"
|
|
221
243
|
},
|
|
222
244
|
{
|
|
223
245
|
"color": "warning" as typeof color[number],
|
|
@@ -225,7 +247,7 @@ export default {
|
|
|
225
247
|
"outline" as typeof variant[number],
|
|
226
248
|
"subtle" as typeof variant[number]
|
|
227
249
|
],
|
|
228
|
-
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-
|
|
250
|
+
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-warning"
|
|
229
251
|
},
|
|
230
252
|
{
|
|
231
253
|
"color": "error" as typeof color[number],
|
|
@@ -233,37 +255,37 @@ export default {
|
|
|
233
255
|
"outline" as typeof variant[number],
|
|
234
256
|
"subtle" as typeof variant[number]
|
|
235
257
|
],
|
|
236
|
-
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-
|
|
258
|
+
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-error"
|
|
237
259
|
},
|
|
238
260
|
{
|
|
239
261
|
"color": "primary" as typeof color[number],
|
|
240
262
|
"highlight": true,
|
|
241
|
-
"class": "ring ring-inset ring-
|
|
263
|
+
"class": "ring ring-inset ring-primary"
|
|
242
264
|
},
|
|
243
265
|
{
|
|
244
266
|
"color": "secondary" as typeof color[number],
|
|
245
267
|
"highlight": true,
|
|
246
|
-
"class": "ring ring-inset ring-
|
|
268
|
+
"class": "ring ring-inset ring-secondary"
|
|
247
269
|
},
|
|
248
270
|
{
|
|
249
271
|
"color": "success" as typeof color[number],
|
|
250
272
|
"highlight": true,
|
|
251
|
-
"class": "ring ring-inset ring-
|
|
273
|
+
"class": "ring ring-inset ring-success"
|
|
252
274
|
},
|
|
253
275
|
{
|
|
254
276
|
"color": "info" as typeof color[number],
|
|
255
277
|
"highlight": true,
|
|
256
|
-
"class": "ring ring-inset ring-
|
|
278
|
+
"class": "ring ring-inset ring-info"
|
|
257
279
|
},
|
|
258
280
|
{
|
|
259
281
|
"color": "warning" as typeof color[number],
|
|
260
282
|
"highlight": true,
|
|
261
|
-
"class": "ring ring-inset ring-
|
|
283
|
+
"class": "ring ring-inset ring-warning"
|
|
262
284
|
},
|
|
263
285
|
{
|
|
264
286
|
"color": "error" as typeof color[number],
|
|
265
287
|
"highlight": true,
|
|
266
|
-
"class": "ring ring-inset ring-
|
|
288
|
+
"class": "ring ring-inset ring-error"
|
|
267
289
|
},
|
|
268
290
|
{
|
|
269
291
|
"color": "neutral" as typeof color[number],
|
|
@@ -271,12 +293,12 @@ export default {
|
|
|
271
293
|
"outline" as typeof variant[number],
|
|
272
294
|
"subtle" as typeof variant[number]
|
|
273
295
|
],
|
|
274
|
-
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-
|
|
296
|
+
"class": "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-inverted"
|
|
275
297
|
},
|
|
276
298
|
{
|
|
277
299
|
"color": "neutral" as typeof color[number],
|
|
278
300
|
"highlight": true,
|
|
279
|
-
"class": "ring ring-inset ring-
|
|
301
|
+
"class": "ring ring-inset ring-inverted"
|
|
280
302
|
},
|
|
281
303
|
{
|
|
282
304
|
"leading": true,
|
|
@@ -349,4 +371,6 @@ export default {
|
|
|
349
371
|
"color": "primary" as typeof color[number],
|
|
350
372
|
"variant": "outline" as typeof variant[number]
|
|
351
373
|
}
|
|
352
|
-
}
|
|
374
|
+
}
|
|
375
|
+
|
|
376
|
+
export default result as typeof theme
|