@byyuurin/ui 0.0.11 → 0.2.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/README.md +170 -58
- package/dist/module.d.mts +4 -13
- package/dist/module.json +4 -4
- package/dist/module.mjs +54 -20
- package/dist/runtime/components/Accordion.vue +28 -23
- package/dist/runtime/components/Accordion.vue.d.ts +51 -29
- package/dist/runtime/components/Alert.vue +47 -27
- package/dist/runtime/components/Alert.vue.d.ts +37 -25
- package/dist/runtime/components/App.vue +9 -8
- package/dist/runtime/components/App.vue.d.ts +22 -20
- package/dist/runtime/components/Avatar.vue +65 -21
- package/dist/runtime/components/Avatar.vue.d.ts +27 -13
- package/dist/runtime/components/AvatarGroup.vue +14 -10
- package/dist/runtime/components/AvatarGroup.vue.d.ts +12 -9
- package/dist/runtime/components/Badge.vue +64 -32
- package/dist/runtime/components/Badge.vue.d.ts +30 -29
- package/dist/runtime/components/Breadcrumb.vue +40 -22
- package/dist/runtime/components/Breadcrumb.vue.d.ts +48 -21
- package/dist/runtime/components/Button.vue +113 -52
- package/dist/runtime/components/Button.vue.d.ts +36 -20
- package/dist/runtime/components/Calendar.vue +50 -43
- package/dist/runtime/components/Calendar.vue.d.ts +58 -31
- package/dist/runtime/components/Card.vue +18 -14
- package/dist/runtime/components/Card.vue.d.ts +18 -14
- package/dist/runtime/components/Carousel.vue +99 -46
- package/dist/runtime/components/Carousel.vue.d.ts +46 -25
- package/dist/runtime/components/Checkbox.vue +60 -35
- package/dist/runtime/components/Checkbox.vue.d.ts +35 -28
- package/dist/runtime/components/CheckboxGroup.vue +131 -0
- package/dist/runtime/components/CheckboxGroup.vue.d.ts +89 -0
- package/dist/runtime/components/Chip.vue +35 -32
- package/dist/runtime/components/Chip.vue.d.ts +33 -15
- package/dist/runtime/components/Collapsible.vue +13 -9
- package/dist/runtime/components/Collapsible.vue.d.ts +16 -8
- package/dist/runtime/components/Drawer.vue +80 -70
- package/dist/runtime/components/Drawer.vue.d.ts +51 -28
- package/dist/runtime/components/DropdownMenu.vue +23 -16
- package/dist/runtime/components/DropdownMenu.vue.d.ts +77 -36
- package/dist/runtime/components/DropdownMenuContent.vue +136 -106
- package/dist/runtime/components/DropdownMenuContent.vue.d.ts +38 -26
- package/dist/runtime/components/FieldGroup.vue +33 -0
- package/dist/runtime/components/FieldGroup.vue.d.ts +33 -0
- package/dist/runtime/components/Form.vue +172 -88
- package/dist/runtime/components/Form.vue.d.ts +69 -44
- package/dist/runtime/components/FormField.vue +108 -0
- package/dist/runtime/components/FormField.vue.d.ts +63 -0
- package/dist/runtime/components/Icon.vue +20 -0
- package/dist/runtime/components/Icon.vue.d.ts +9 -0
- package/dist/runtime/components/Input.vue +84 -79
- package/dist/runtime/components/Input.vue.d.ts +55 -43
- package/dist/runtime/components/InputNumber.vue +66 -52
- package/dist/runtime/components/InputNumber.vue.d.ts +50 -109
- package/dist/runtime/components/InputTags.vue +155 -0
- package/dist/runtime/components/InputTags.vue.d.ts +85 -0
- package/dist/runtime/components/Kbd.vue +11 -5
- package/dist/runtime/components/Kbd.vue.d.ts +17 -11
- package/dist/runtime/components/Link.vue +54 -197
- package/dist/runtime/components/Link.vue.d.ts +17 -17
- package/dist/runtime/components/LinkBase.vue +11 -33
- package/dist/runtime/components/LinkBase.vue.d.ts +8 -3
- package/dist/runtime/components/Marquee.vue +38 -0
- package/dist/runtime/components/Marquee.vue.d.ts +54 -0
- package/dist/runtime/components/Modal.vue +53 -39
- package/dist/runtime/components/Modal.vue.d.ts +64 -34
- package/dist/runtime/components/NavigationMenu.vue +345 -0
- package/dist/runtime/components/NavigationMenu.vue.d.ts +216 -0
- package/dist/runtime/components/OverlayProvider.vue +3 -3
- package/dist/runtime/components/OverlayProvider.vue.d.ts +2 -1
- package/dist/runtime/components/Pagination.vue +39 -47
- package/dist/runtime/components/Pagination.vue.d.ts +54 -31
- package/dist/runtime/components/PinInput.vue +46 -32
- package/dist/runtime/components/PinInput.vue.d.ts +40 -21
- package/dist/runtime/components/Popover.vue +33 -19
- package/dist/runtime/components/Popover.vue.d.ts +57 -32
- package/dist/runtime/components/Progress.vue +31 -26
- package/dist/runtime/components/Progress.vue.d.ts +32 -23
- package/dist/runtime/components/RadioGroup.vue +75 -48
- package/dist/runtime/components/RadioGroup.vue.d.ts +58 -36
- package/dist/runtime/components/ScrollArea.vue +33 -31
- package/dist/runtime/components/ScrollArea.vue.d.ts +9 -5
- package/dist/runtime/components/Select.vue +166 -76
- package/dist/runtime/components/Select.vue.d.ts +206 -65
- package/dist/runtime/components/Separator.vue +42 -16
- package/dist/runtime/components/Separator.vue.d.ts +35 -14
- package/dist/runtime/components/Skeleton.vue +18 -6
- package/dist/runtime/components/Skeleton.vue.d.ts +4 -4
- package/dist/runtime/components/Slider.vue +42 -24
- package/dist/runtime/components/Slider.vue.d.ts +43 -27
- package/dist/runtime/components/Switch.vue +40 -31
- package/dist/runtime/components/Switch.vue.d.ts +36 -27
- package/dist/runtime/components/Table.vue +329 -79
- package/dist/runtime/components/Table.vue.d.ts +152 -66
- package/dist/runtime/components/Tabs.vue +70 -23
- package/dist/runtime/components/Tabs.vue.d.ts +61 -29
- package/dist/runtime/components/Textarea.vue +102 -54
- package/dist/runtime/components/Textarea.vue.d.ts +57 -41
- package/dist/runtime/components/Timeline.vue +102 -0
- package/dist/runtime/components/Timeline.vue.d.ts +74 -0
- package/dist/runtime/components/Toast.vue +84 -38
- package/dist/runtime/components/Toast.vue.d.ts +48 -27
- package/dist/runtime/components/ToastProvider.vue +31 -22
- package/dist/runtime/components/ToastProvider.vue.d.ts +30 -17
- package/dist/runtime/components/Tooltip.vue +33 -21
- package/dist/runtime/components/Tooltip.vue.d.ts +37 -15
- package/dist/runtime/composables/defineShortcuts.d.ts +16 -0
- package/dist/runtime/composables/defineShortcuts.js +129 -0
- package/dist/runtime/composables/useAvatarGroup.d.ts +8 -3
- package/dist/runtime/composables/useAvatarGroup.js +10 -3
- package/dist/runtime/composables/useComponentIcons.d.ts +9 -6
- package/dist/runtime/composables/useComponentIcons.js +4 -4
- package/dist/runtime/composables/useFieldGroup.d.ts +8 -0
- package/dist/runtime/composables/useFieldGroup.js +14 -0
- package/dist/runtime/composables/useFormField.d.ts +62 -0
- package/dist/runtime/composables/useFormField.js +99 -0
- package/dist/runtime/composables/useKbd.d.ts +3 -2
- package/dist/runtime/composables/useKbd.js +3 -2
- package/dist/runtime/composables/useLocale.d.ts +68 -5
- package/dist/runtime/composables/useLocale.js +11 -11
- package/dist/runtime/composables/useOverlay.d.ts +51 -15
- package/dist/runtime/composables/useOverlay.js +44 -30
- package/dist/runtime/composables/usePortal.d.ts +6 -0
- package/dist/runtime/composables/usePortal.js +17 -0
- package/dist/runtime/composables/useToast.d.ts +12 -5
- package/dist/runtime/composables/useToast.js +12 -7
- package/dist/runtime/locale/en.d.ts +30 -1
- package/dist/runtime/locale/en.js +2 -1
- package/dist/runtime/locale/index.d.ts +2 -2
- package/dist/runtime/locale/index.js +1 -1
- package/dist/runtime/locale/zh_tw.d.ts +31 -0
- package/dist/runtime/locale/{zh-tw.js → zh_tw.js} +2 -1
- package/dist/runtime/plugins/colors.d.ts +2 -0
- package/dist/runtime/plugins/colors.js +50 -0
- package/dist/runtime/types/app.config.d.ts +6 -0
- package/dist/runtime/types/form.d.ts +58 -17
- package/dist/runtime/types/form.js +11 -0
- package/dist/runtime/types/index.d.ts +56 -8
- package/dist/runtime/types/index.js +49 -1
- package/dist/runtime/types/input.d.ts +8 -0
- package/dist/runtime/types/locale.d.ts +5 -0
- package/dist/runtime/types/style.d.ts +33 -0
- package/dist/runtime/types/style.js +0 -0
- package/dist/runtime/types/unocss.d.ts +4 -0
- package/dist/runtime/types/utils.d.ts +41 -37
- package/dist/runtime/utils/form.d.ts +5 -1
- package/dist/runtime/utils/form.js +49 -0
- package/dist/runtime/utils/index.d.ts +10 -13
- package/dist/runtime/utils/index.js +41 -48
- package/dist/runtime/utils/link.d.ts +3 -2
- package/dist/runtime/utils/link.js +16 -2
- package/dist/runtime/utils/locale.d.ts +5 -0
- package/dist/runtime/utils/locale.js +10 -0
- package/dist/runtime/utils/style.d.ts +94 -0
- package/dist/runtime/utils/style.js +37 -0
- package/dist/runtime/vue/components/Icon.vue +15 -0
- package/dist/runtime/vue/components/Icon.vue.d.ts +7 -0
- package/dist/runtime/vue/components/Link.vue +163 -0
- package/dist/runtime/vue/components/Link.vue.d.ts +95 -0
- package/dist/runtime/vue/composables/useAppConfig.d.ts +1 -0
- package/dist/runtime/vue/composables/useAppConfig.js +4 -0
- package/dist/runtime/vue/plugins/color-mode.d.ts +4 -0
- package/dist/runtime/vue/plugins/color-mode.js +6 -0
- package/dist/runtime/vue/plugins/head.d.ts +4 -0
- package/dist/runtime/vue/plugins/head.js +9 -0
- package/dist/runtime/vue/stubs.d.ts +16 -1
- package/dist/runtime/vue/stubs.js +32 -1
- package/dist/setup.d.mts +13 -0
- package/dist/setup.mjs +12 -0
- package/dist/shared/ui.CzIlLITK.mjs +51 -0
- package/dist/shared/ui.DLOxhmP0.mjs +4242 -0
- package/dist/shared/ui.DpbffTXs.d.mts +84 -0
- package/dist/shared/ui.IulR-OYx.d.mts +64 -0
- package/dist/types.d.mts +3 -1
- package/dist/unocss.d.mts +12 -52
- package/dist/unocss.mjs +144 -254
- package/dist/unplugin.d.mts +13 -26
- package/dist/unplugin.mjs +193 -18
- package/dist/vite.d.mts +10 -1
- package/dist/vite.mjs +12 -3
- package/package.json +154 -87
- package/vue-plugin.d.ts +5 -0
- package/dist/module.d.ts +0 -13
- package/dist/module.mjs.map +0 -1
- package/dist/runtime/app/injections.d.ts +0 -9331
- package/dist/runtime/app/injections.js +0 -61
- package/dist/runtime/components/ButtonGroup.vue +0 -26
- package/dist/runtime/components/ButtonGroup.vue.d.ts +0 -26
- package/dist/runtime/components/FormItem.vue +0 -90
- package/dist/runtime/components/FormItem.vue.d.ts +0 -60
- package/dist/runtime/composables/useButtonGroup.d.ts +0 -5
- package/dist/runtime/composables/useButtonGroup.js +0 -9
- package/dist/runtime/composables/useFormItem.d.ts +0 -27
- package/dist/runtime/composables/useFormItem.js +0 -64
- package/dist/runtime/composables/useTheme.d.ts +0 -9
- package/dist/runtime/composables/useTheme.js +0 -23
- package/dist/runtime/index.d.ts +0 -44
- package/dist/runtime/index.js +0 -44
- package/dist/runtime/locale/zh-tw.d.ts +0 -2
- package/dist/runtime/theme/accordion.d.ts +0 -50
- package/dist/runtime/theme/accordion.js +0 -28
- package/dist/runtime/theme/alert.d.ts +0 -119
- package/dist/runtime/theme/alert.js +0 -47
- package/dist/runtime/theme/app.d.ts +0 -19
- package/dist/runtime/theme/app.js +0 -19
- package/dist/runtime/theme/avatar-group.d.ts +0 -46
- package/dist/runtime/theme/avatar-group.js +0 -32
- package/dist/runtime/theme/avatar.d.ts +0 -50
- package/dist/runtime/theme/avatar.js +0 -34
- package/dist/runtime/theme/badge.d.ts +0 -76
- package/dist/runtime/theme/badge.js +0 -92
- package/dist/runtime/theme/breadcrumb.d.ts +0 -61
- package/dist/runtime/theme/breadcrumb.js +0 -44
- package/dist/runtime/theme/button-group.d.ts +0 -60
- package/dist/runtime/theme/button-group.js +0 -42
- package/dist/runtime/theme/button.d.ts +0 -184
- package/dist/runtime/theme/button.js +0 -164
- package/dist/runtime/theme/calendar.d.ts +0 -58
- package/dist/runtime/theme/calendar.js +0 -86
- package/dist/runtime/theme/card.d.ts +0 -56
- package/dist/runtime/theme/card.js +0 -37
- package/dist/runtime/theme/carousel.d.ts +0 -107
- package/dist/runtime/theme/carousel.js +0 -43
- package/dist/runtime/theme/checkbox.d.ts +0 -82
- package/dist/runtime/theme/checkbox.js +0 -54
- package/dist/runtime/theme/chip.d.ts +0 -61
- package/dist/runtime/theme/chip.js +0 -66
- package/dist/runtime/theme/collapsible.d.ts +0 -32
- package/dist/runtime/theme/collapsible.js +0 -10
- package/dist/runtime/theme/drawer.d.ts +0 -142
- package/dist/runtime/theme/drawer.js +0 -113
- package/dist/runtime/theme/dropdown-menu.d.ts +0 -65
- package/dist/runtime/theme/dropdown-menu.js +0 -83
- package/dist/runtime/theme/form-item.d.ts +0 -70
- package/dist/runtime/theme/form-item.js +0 -34
- package/dist/runtime/theme/form.d.ts +0 -2
- package/dist/runtime/theme/form.js +0 -7
- package/dist/runtime/theme/index.d.ts +0 -41
- package/dist/runtime/theme/index.js +0 -41
- package/dist/runtime/theme/input-number.d.ts +0 -115
- package/dist/runtime/theme/input-number.js +0 -95
- package/dist/runtime/theme/input.d.ts +0 -172
- package/dist/runtime/theme/input.js +0 -151
- package/dist/runtime/theme/kbd.d.ts +0 -33
- package/dist/runtime/theme/kbd.js +0 -26
- package/dist/runtime/theme/link.d.ts +0 -38
- package/dist/runtime/theme/link.js +0 -26
- package/dist/runtime/theme/modal.d.ts +0 -42
- package/dist/runtime/theme/modal.js +0 -55
- package/dist/runtime/theme/pagination.d.ts +0 -74
- package/dist/runtime/theme/pagination.js +0 -17
- package/dist/runtime/theme/pinInput.d.ts +0 -94
- package/dist/runtime/theme/pinInput.js +0 -111
- package/dist/runtime/theme/popover.d.ts +0 -32
- package/dist/runtime/theme/popover.js +0 -13
- package/dist/runtime/theme/progress.d.ts +0 -180
- package/dist/runtime/theme/progress.js +0 -95
- package/dist/runtime/theme/radio-group.d.ts +0 -104
- package/dist/runtime/theme/radio-group.js +0 -61
- package/dist/runtime/theme/scroll-area.d.ts +0 -67
- package/dist/runtime/theme/scroll-area.js +0 -33
- package/dist/runtime/theme/select.d.ts +0 -186
- package/dist/runtime/theme/select.js +0 -173
- package/dist/runtime/theme/separator.d.ts +0 -74
- package/dist/runtime/theme/separator.js +0 -53
- package/dist/runtime/theme/skeleton.d.ts +0 -2
- package/dist/runtime/theme/skeleton.js +0 -7
- package/dist/runtime/theme/slider.d.ts +0 -70
- package/dist/runtime/theme/slider.js +0 -52
- package/dist/runtime/theme/switch.d.ts +0 -116
- package/dist/runtime/theme/switch.js +0 -78
- package/dist/runtime/theme/table.d.ts +0 -86
- package/dist/runtime/theme/table.js +0 -36
- package/dist/runtime/theme/tabs.d.ts +0 -129
- package/dist/runtime/theme/tabs.js +0 -146
- package/dist/runtime/theme/textarea.d.ts +0 -90
- package/dist/runtime/theme/textarea.js +0 -116
- package/dist/runtime/theme/toast-provider.d.ts +0 -116
- package/dist/runtime/theme/toast-provider.js +0 -97
- package/dist/runtime/theme/toast.d.ts +0 -83
- package/dist/runtime/theme/toast.js +0 -35
- package/dist/runtime/theme/tooltip.d.ts +0 -38
- package/dist/runtime/theme/tooltip.js +0 -11
- package/dist/runtime/types/components.d.ts +0 -42
- package/dist/runtime/utils/extend-theme.d.ts +0 -9
- package/dist/runtime/utils/extend-theme.js +0 -27
- package/dist/runtime/utils/styler.d.ts +0 -4
- package/dist/runtime/utils/styler.js +0 -10
- package/dist/runtime/utils/translator.d.ts +0 -18
- package/dist/runtime/utils/translator.js +0 -8
- package/dist/shared/ui.D1BTWZFB.mjs +0 -5
- package/dist/shared/ui.D1BTWZFB.mjs.map +0 -1
- package/dist/unocss.d.ts +0 -52
- package/dist/unocss.mjs.map +0 -1
- package/dist/unplugin.d.ts +0 -26
- package/dist/unplugin.mjs.map +0 -1
- package/dist/vite.d.ts +0 -9
- package/dist/vite.mjs.map +0 -1
- /package/dist/runtime/types/{components.js → input.js} +0 -0
package/README.md
CHANGED
|
@@ -12,104 +12,216 @@ https://byyuurin-ui.netlify.app/
|
|
|
12
12
|
|
|
13
13
|
## Installation
|
|
14
14
|
|
|
15
|
-
```
|
|
16
|
-
pnpm
|
|
15
|
+
```bash [pnpm]
|
|
16
|
+
pnpm add @byyuurin/ui
|
|
17
17
|
```
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
```bash [yarn]
|
|
20
|
+
yarn add @byyuurin/ui
|
|
21
|
+
```
|
|
20
22
|
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
+
```bash [npm]
|
|
24
|
+
npm install @byyuurin/ui
|
|
23
25
|
```
|
|
24
26
|
|
|
25
|
-
|
|
27
|
+
> [!WARNING]
|
|
28
|
+
> If you're using pnpm, ensure that you either set [`shamefully-hoist=true`](https://pnpm.io/settings#shamefully-hoist) in your `.npmrc` file or install `@byyuurin/ui-kit` in your project's root directory.
|
|
29
|
+
|
|
30
|
+
### Nuxt
|
|
26
31
|
|
|
27
|
-
|
|
32
|
+
1. Add the UI module in your `nuxt.config.ts`:
|
|
28
33
|
|
|
29
34
|
```ts
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
35
|
+
export default defineNuxtConfig({
|
|
36
|
+
modules: [
|
|
37
|
+
'@byyuurin/ui',
|
|
38
|
+
],
|
|
39
|
+
|
|
40
|
+
ui: {
|
|
41
|
+
prefix: 'U',
|
|
42
|
+
colorMode: true,
|
|
43
|
+
theme: {
|
|
44
|
+
colors: ['primary', 'secondary', 'success', 'info', 'warning', 'error'],
|
|
45
|
+
transitions: true,
|
|
46
|
+
defaultVariants: {
|
|
47
|
+
color: 'primary',
|
|
48
|
+
size: 'md',
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
})
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
2. Add UnoCSS preset in your `uno.config.ts`:
|
|
56
|
+
|
|
57
|
+
```ts
|
|
58
|
+
import { createUnoPreset } from '@byyuurin/ui/unocss'
|
|
59
|
+
import { defineConfig, presetWind4 } from 'unocss'
|
|
33
60
|
|
|
34
61
|
export default defineConfig({
|
|
35
62
|
presets: [
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
}),
|
|
40
|
-
ui({
|
|
41
|
-
radius: '0rem', // optional
|
|
42
|
-
radiusBox: '0rem', // optional
|
|
43
|
-
radiusButton: '0rem', // optional
|
|
44
|
-
radiusCheckbox: '0rem', // optional
|
|
45
|
-
radiusRadio: '0rem', // optional
|
|
46
|
-
radiusSwitch: '0rem', // optional
|
|
47
|
-
radiusTabs: '0rem', // optional
|
|
48
|
-
cb: '#1f2937', // optional
|
|
49
|
-
cp: '#1f2937', // optional
|
|
50
|
-
cx: '#ffffff', // optional
|
|
63
|
+
presetWind4(),
|
|
64
|
+
createUnoPreset({
|
|
65
|
+
colors: ['primary', 'secondary', 'success', 'info', 'warning', 'error'],
|
|
51
66
|
}),
|
|
52
67
|
],
|
|
53
68
|
})
|
|
54
69
|
```
|
|
55
70
|
|
|
56
|
-
|
|
71
|
+
> [!IMPORTANT]
|
|
72
|
+
> The preset colors configuration must be the same as your nuxt configuration
|
|
57
73
|
|
|
58
|
-
|
|
59
|
-
- `bg-soft-[color]`
|
|
60
|
-
- `bg-soft-[color]/[mix-ratio]`
|
|
74
|
+
### Vue
|
|
61
75
|
|
|
62
|
-
|
|
76
|
+
1. Create `ui.config.ts` file for unified management of UI settings:
|
|
63
77
|
|
|
64
78
|
```ts
|
|
65
|
-
//
|
|
79
|
+
// @unocss-include
|
|
80
|
+
import { setup } from '@byyuurin/ui/setup'
|
|
81
|
+
|
|
82
|
+
export default setup({
|
|
83
|
+
prefix: 'U',
|
|
84
|
+
autoImport: {
|
|
85
|
+
// ... unplugin-auto-import options
|
|
86
|
+
},
|
|
87
|
+
components: {
|
|
88
|
+
// ... unplugin-vue-components options
|
|
89
|
+
},
|
|
90
|
+
colorMode: true,
|
|
91
|
+
theme: {
|
|
92
|
+
colors: ['primary', 'secondary', 'success', 'info', 'warning', 'error'],
|
|
93
|
+
transitions: true,
|
|
94
|
+
defaultVariants: {
|
|
95
|
+
color: 'primary',
|
|
96
|
+
size: 'md',
|
|
97
|
+
},
|
|
98
|
+
},
|
|
99
|
+
ui: {
|
|
100
|
+
colors: {
|
|
101
|
+
primary: 'green',
|
|
102
|
+
secondary: 'blue',
|
|
103
|
+
success: 'green',
|
|
104
|
+
info: 'blue',
|
|
105
|
+
warning: 'yellow',
|
|
106
|
+
error: 'red',
|
|
107
|
+
neutral: 'slate',
|
|
108
|
+
},
|
|
109
|
+
icons: {
|
|
110
|
+
close: 'i-lucide-x',
|
|
111
|
+
loading: 'i-lucide-loader-circle',
|
|
112
|
+
check: 'i-lucide-check',
|
|
113
|
+
chevronUp: 'i-lucide-chevron-up',
|
|
114
|
+
chevronDown: 'i-lucide-chevron-down',
|
|
115
|
+
chevronLeft: 'i-lucide-chevron-left',
|
|
116
|
+
chevronRight: 'i-lucide-chevron-right',
|
|
117
|
+
chevronDoubleLeft: 'i-lucide-chevrons-left',
|
|
118
|
+
chevronDoubleRight: 'i-lucide-chevrons-right',
|
|
119
|
+
ellipsis: 'i-lucide-ellipsis',
|
|
120
|
+
plus: 'i-lucide-plus',
|
|
121
|
+
minus: 'i-lucide-minus',
|
|
122
|
+
external: 'i-lucide-arrow-up-right',
|
|
123
|
+
},
|
|
124
|
+
},
|
|
125
|
+
})
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
> [!IMPORTANT]
|
|
129
|
+
> Add `// @unocss-include` to add ui.config.ts to unocss scan files
|
|
130
|
+
|
|
131
|
+
> [!NOTE]
|
|
132
|
+
> Internally relies on custom alias to resolve the theme types. If you're using TypeScript, you should add an alias to your tsconfig to enable auto-completion in your ui.config.ts.
|
|
133
|
+
|
|
134
|
+
```jsonc
|
|
135
|
+
// tsconfig.node.json
|
|
66
136
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
137
|
+
{
|
|
138
|
+
"compilerOptions": {
|
|
139
|
+
"paths": {
|
|
140
|
+
"#build/*": ["./node_modules/.nuxt/*"]
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
2. Add the UI Vite plugin in your `vite.config.ts`:
|
|
147
|
+
|
|
148
|
+
```ts
|
|
149
|
+
import ui from '@byyuurin/ui/vite' // <---
|
|
150
|
+
import vue from '@vitejs/plugin-vue'
|
|
151
|
+
import unocss from 'unocss/vite'
|
|
70
152
|
import { defineConfig } from 'vite'
|
|
153
|
+
import uiConfig from './ui.config' // <---
|
|
71
154
|
|
|
72
155
|
export default defineConfig({
|
|
73
156
|
plugins: [
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
157
|
+
unocss(),
|
|
158
|
+
vue(),
|
|
159
|
+
ui(uiConfig.vite), // <---
|
|
160
|
+
],
|
|
161
|
+
})
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
3. Add UnoCSS preset in your `uno.config.ts`:
|
|
165
|
+
|
|
166
|
+
```ts
|
|
167
|
+
import { createUnoPreset } from '@byyuurin/ui/unocss' // <---
|
|
168
|
+
import { defineConfig, presetWebFonts, presetWind4 } from 'unocss'
|
|
169
|
+
import uiConfig from './ui.config' // <---
|
|
170
|
+
|
|
171
|
+
export default defineConfig({
|
|
172
|
+
presets: [
|
|
173
|
+
presetWind4(),
|
|
174
|
+
createUnoPreset(uiConfig.uno), // <---
|
|
175
|
+
presetWebFonts({
|
|
176
|
+
fonts: {
|
|
177
|
+
sans: { provider: 'google', name: 'Public Sans', weights: [400, 500, 600, 700] },
|
|
84
178
|
},
|
|
85
179
|
}),
|
|
86
180
|
],
|
|
87
181
|
})
|
|
88
182
|
```
|
|
89
183
|
|
|
90
|
-
|
|
184
|
+
4. Add the UI Vue plugin in your `src/main.ts`
|
|
91
185
|
|
|
92
186
|
```ts
|
|
93
|
-
|
|
187
|
+
import 'uno.css'
|
|
94
188
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
},
|
|
189
|
+
import ui from '@byyuurin/ui/vue-plugin' // <---
|
|
190
|
+
import { createApp } from 'vue'
|
|
191
|
+
import { createRouter, createWebHistory } from 'vue-router'
|
|
192
|
+
import App from './App.vue'
|
|
193
|
+
|
|
194
|
+
const app = createApp(App)
|
|
195
|
+
|
|
196
|
+
const router = createRouter({
|
|
197
|
+
routes: [],
|
|
198
|
+
history: createWebHistory(),
|
|
106
199
|
})
|
|
200
|
+
|
|
201
|
+
app.use(ui) // <----
|
|
202
|
+
app.use(router)
|
|
203
|
+
|
|
204
|
+
app.mount('#app')
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
5. Add the `isolate` class to your root container
|
|
208
|
+
|
|
209
|
+
```html
|
|
210
|
+
<!doctype html>
|
|
211
|
+
<html lang="en">
|
|
212
|
+
<head>
|
|
213
|
+
...
|
|
214
|
+
</head>
|
|
215
|
+
<body>
|
|
216
|
+
<div id="app" class="isolate"></div>
|
|
217
|
+
<script type="module" src="/src/main.ts"></script>
|
|
218
|
+
</body>
|
|
219
|
+
</html>
|
|
107
220
|
```
|
|
108
221
|
|
|
109
222
|
## Credits
|
|
110
223
|
|
|
111
224
|
- [UnoCSS](https://github.com/unocss/unocss)
|
|
112
|
-
- [daisyui](https://github.com/saadeghi/daisyui)
|
|
113
225
|
- [@nuxt/ui](https://github.com/nuxt/ui)
|
|
114
226
|
- [Reka UI](https://github.com/unovue/radix-vue)
|
|
115
227
|
- [VueUse](https://github.com/vueuse/vueuse)
|
package/dist/module.d.mts
CHANGED
|
@@ -1,13 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
* prefix for components used in templates
|
|
6
|
-
*
|
|
7
|
-
* @default "U"
|
|
8
|
-
*/
|
|
9
|
-
prefix?: string;
|
|
10
|
-
}
|
|
11
|
-
declare const _default: _nuxt_schema.NuxtModule<ModuleOptions, ModuleOptions, false>;
|
|
12
|
-
|
|
13
|
-
export { type ModuleOptions, _default as default };
|
|
1
|
+
import '@nuxt/schema';
|
|
2
|
+
export { M as ModuleOptions, _ as default } from './shared/ui.IulR-OYx.mjs';
|
|
3
|
+
export * from '../dist/runtime/types/index.js';
|
|
4
|
+
import '@unocss/preset-wind4/colors';
|
package/dist/module.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@byyuurin/ui",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"configKey": "ui",
|
|
5
5
|
"compatibility": {
|
|
6
|
-
"nuxt": ">=3.
|
|
6
|
+
"nuxt": ">=3.16.2"
|
|
7
7
|
},
|
|
8
8
|
"builder": {
|
|
9
|
-
"@nuxt/module-builder": "1.0.
|
|
10
|
-
"unbuild": "3.
|
|
9
|
+
"@nuxt/module-builder": "1.0.2",
|
|
10
|
+
"unbuild": "3.6.1"
|
|
11
11
|
}
|
|
12
12
|
}
|
package/dist/module.mjs
CHANGED
|
@@ -1,37 +1,71 @@
|
|
|
1
|
-
import { defineNuxtModule,
|
|
2
|
-
import {
|
|
1
|
+
import { defineNuxtModule, createResolver, addPlugin, addComponentsDir, addImportsDir, hasNuxtModule, installModule } from '@nuxt/kit';
|
|
2
|
+
import { defu } from 'defu';
|
|
3
|
+
import { v as version, n as name, a as addTemplates } from './shared/ui.DLOxhmP0.mjs';
|
|
4
|
+
import { d as defaultOptions, r as resolveColors, g as getDefaultUIConfig } from './shared/ui.CzIlLITK.mjs';
|
|
5
|
+
import 'node:process';
|
|
6
|
+
import 'node:url';
|
|
7
|
+
import '@unocss/config';
|
|
8
|
+
import 'knitwork';
|
|
9
|
+
import 'scule';
|
|
10
|
+
import '@byyuurin/ui-kit';
|
|
11
|
+
import '../dist/runtime/utils/index.js';
|
|
3
12
|
|
|
4
13
|
const module = defineNuxtModule({
|
|
5
14
|
meta: {
|
|
6
|
-
name
|
|
7
|
-
version
|
|
15
|
+
name,
|
|
16
|
+
version,
|
|
8
17
|
configKey: "ui",
|
|
9
18
|
compatibility: {
|
|
10
|
-
nuxt: ">=3.
|
|
19
|
+
nuxt: ">=3.16.2"
|
|
11
20
|
}
|
|
12
21
|
},
|
|
13
|
-
defaults:
|
|
14
|
-
|
|
15
|
-
},
|
|
16
|
-
setup(options, nuxt) {
|
|
17
|
-
const logger = useLogger(name);
|
|
22
|
+
defaults: defaultOptions,
|
|
23
|
+
async setup(options, nuxt) {
|
|
18
24
|
const { resolve } = createResolver(import.meta.url);
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
nuxt.options.vite.optimizeDeps ??= {};
|
|
24
|
-
nuxt.options.vite.optimizeDeps.include ??= [];
|
|
25
|
-
nuxt.options.vite.optimizeDeps.include.push(`${name}/unocss`);
|
|
25
|
+
options.theme ||= {};
|
|
26
|
+
options.theme.colors = resolveColors(options.theme.colors);
|
|
27
|
+
nuxt.options.ui = options;
|
|
26
28
|
nuxt.options.alias["#ui"] = resolve("./runtime");
|
|
29
|
+
nuxt.options.appConfig.ui = defu(nuxt.options.appConfig.ui || {}, getDefaultUIConfig(options.theme.colors));
|
|
30
|
+
nuxt.options.app.rootAttrs ||= {};
|
|
31
|
+
nuxt.options.app.rootAttrs.class = [nuxt.options.app.rootAttrs.class, "isolate"].filter(Boolean).join(" ");
|
|
32
|
+
async function registerModule(name2, key, options2) {
|
|
33
|
+
if (hasNuxtModule(name2))
|
|
34
|
+
nuxt.options[key] = defu(nuxt.options[key], options2);
|
|
35
|
+
else
|
|
36
|
+
await installModule(name2, defu(nuxt.options[key], options2));
|
|
37
|
+
}
|
|
38
|
+
await registerModule("@unocss/nuxt", "unocss", {
|
|
39
|
+
preflight: false,
|
|
40
|
+
wind3: false,
|
|
41
|
+
wind4: true,
|
|
42
|
+
mergeSelectors: false
|
|
43
|
+
});
|
|
44
|
+
await registerModule("@nuxt/icon", "icon", {
|
|
45
|
+
cssLayer: "components"
|
|
46
|
+
});
|
|
47
|
+
if (options.fonts) {
|
|
48
|
+
await registerModule("@nuxt/fonts", "fonts", {
|
|
49
|
+
defaults: {
|
|
50
|
+
weights: [400, 500, 600, 700]
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
if (options.colorMode) {
|
|
55
|
+
await registerModule("@nuxtjs/color-mode", "colorMode", {
|
|
56
|
+
classSuffix: "",
|
|
57
|
+
disableTransition: true
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
addPlugin({ src: resolve("./runtime/plugins/colors") });
|
|
27
61
|
addComponentsDir({
|
|
28
62
|
path: resolve("./runtime/components"),
|
|
29
|
-
|
|
30
|
-
|
|
63
|
+
pathPrefix: false,
|
|
64
|
+
prefix: options.prefix
|
|
31
65
|
});
|
|
32
66
|
addImportsDir(resolve("./runtime/composables"));
|
|
67
|
+
addTemplates(options, nuxt, resolve);
|
|
33
68
|
}
|
|
34
69
|
});
|
|
35
70
|
|
|
36
71
|
export { module as default };
|
|
37
|
-
//# sourceMappingURL=module.mjs.map
|
|
@@ -1,20 +1,22 @@
|
|
|
1
1
|
<script>
|
|
2
|
-
|
|
2
|
+
import theme from "#build/ui/accordion";
|
|
3
3
|
</script>
|
|
4
4
|
|
|
5
5
|
<script setup>
|
|
6
6
|
import { reactivePick } from "@vueuse/core";
|
|
7
7
|
import { AccordionContent, AccordionHeader, AccordionItem, AccordionRoot, AccordionTrigger, useForwardPropsEmits } from "reka-ui";
|
|
8
8
|
import { computed } from "vue";
|
|
9
|
-
import {
|
|
9
|
+
import { useAppConfig } from "#imports";
|
|
10
10
|
import { get } from "../utils";
|
|
11
|
+
import { cv, merge } from "../utils/style";
|
|
12
|
+
import Icon from "./Icon.vue";
|
|
11
13
|
const props = defineProps({
|
|
14
|
+
as: { type: null, required: false },
|
|
12
15
|
items: { type: Array, required: false },
|
|
13
|
-
trailingIcon: { type: String, required: false },
|
|
14
|
-
labelKey: { type:
|
|
15
|
-
class: { type: null, required: false },
|
|
16
|
+
trailingIcon: { type: [String, Object], required: false },
|
|
17
|
+
labelKey: { type: null, required: false, default: "label" },
|
|
16
18
|
ui: { type: null, required: false },
|
|
17
|
-
|
|
19
|
+
class: { type: [Object, String, Number, Boolean, null, Array], required: false, skipCheck: true },
|
|
18
20
|
collapsible: { type: Boolean, required: false, default: true },
|
|
19
21
|
defaultValue: { type: null, required: false },
|
|
20
22
|
modelValue: { type: null, required: false },
|
|
@@ -24,46 +26,49 @@ const props = defineProps({
|
|
|
24
26
|
});
|
|
25
27
|
const emit = defineEmits(["update:modelValue"]);
|
|
26
28
|
const slots = defineSlots();
|
|
27
|
-
const rootProps = useForwardPropsEmits(reactivePick(props, "as", "collapsible", "defaultValue", "disabled", "modelValue", "
|
|
28
|
-
const
|
|
29
|
-
const
|
|
29
|
+
const rootProps = useForwardPropsEmits(reactivePick(props, "as", "collapsible", "defaultValue", "disabled", "modelValue", "unmountOnHide"), emit);
|
|
30
|
+
const appConfig = useAppConfig();
|
|
31
|
+
const ui = computed(() => {
|
|
32
|
+
const styler = cv(merge(theme, appConfig.ui.accordion));
|
|
33
|
+
return styler(props);
|
|
34
|
+
});
|
|
30
35
|
</script>
|
|
31
36
|
|
|
32
37
|
<template>
|
|
33
|
-
<AccordionRoot v-bind="rootProps" :class="
|
|
38
|
+
<AccordionRoot v-bind="rootProps" :class="ui.root({ class: [props.ui?.root, props.class] })" data-part="root">
|
|
34
39
|
<AccordionItem
|
|
35
40
|
v-for="(item, index) in props.items"
|
|
36
41
|
v-slot="{ open }"
|
|
37
42
|
:key="index"
|
|
38
43
|
:value="item.value || String(index)"
|
|
39
44
|
:disabled="item.disabled"
|
|
40
|
-
:class="
|
|
45
|
+
:class="ui.item({ class: [props.ui?.item, item.ui?.item, item.class] })"
|
|
41
46
|
data-part="item"
|
|
42
47
|
>
|
|
43
|
-
<AccordionHeader :class="
|
|
44
|
-
<AccordionTrigger :class="
|
|
45
|
-
<slot name="leading" v-bind="{ item, index, open }">
|
|
46
|
-
<
|
|
48
|
+
<AccordionHeader as="div" :class="ui.header({ class: [props.ui?.header, item.ui?.header] })" data-part="header">
|
|
49
|
+
<AccordionTrigger :class="ui.trigger({ class: [props.ui?.trigger, item.ui?.trigger], disabled: item.disabled })" data-part="trigger">
|
|
50
|
+
<slot name="leading" v-bind="{ item, index, open, ui }">
|
|
51
|
+
<Icon v-if="item.icon" :name="item.icon" :class="ui.leadingIcon({ class: [props.ui?.leadingIcon, item.ui?.leadingIcon] })" data-part="leadingIcon" />
|
|
47
52
|
</slot>
|
|
48
53
|
|
|
49
|
-
<span v-if="get(item, props.labelKey) || slots.default" :class="
|
|
54
|
+
<span v-if="get(item, props.labelKey) || !!slots.default" :class="ui.label({ class: [props.ui?.label, item.ui?.label] })" data-part="label">
|
|
50
55
|
<slot v-bind="{ item, index, open }">{{ get(item, props.labelKey) }}</slot>
|
|
51
56
|
</span>
|
|
52
57
|
|
|
53
|
-
<slot name="trailing" v-bind="{ item, index, open }">
|
|
54
|
-
<
|
|
58
|
+
<slot name="trailing" v-bind="{ item, index, open, ui }">
|
|
59
|
+
<Icon :name="item.trailingIcon || props.trailingIcon || appConfig.ui.icons.chevronDown" :class="ui.trailingIcon({ class: [props.ui?.trailingIcon, item.ui?.trailingIcon] })" data-part="trailingIcon" />
|
|
55
60
|
</slot>
|
|
56
61
|
</AccordionTrigger>
|
|
57
62
|
</AccordionHeader>
|
|
58
63
|
|
|
59
64
|
<AccordionContent
|
|
60
|
-
v-if="item.content || slots.content || item.slot && slots[item.slot] || slots.body || item.slot && slots[`${item.slot}-body`]"
|
|
61
|
-
:class="
|
|
65
|
+
v-if="item.content || !!slots.content || item.slot && slots[item.slot] || !!slots.body || item.slot && slots[`${item.slot}-body`]"
|
|
66
|
+
:class="ui.content({ class: [props.ui?.content, item.ui?.content] })"
|
|
62
67
|
data-part="content"
|
|
63
68
|
>
|
|
64
|
-
<slot :name="item.slot || 'content'"
|
|
65
|
-
<div :class="
|
|
66
|
-
<slot :name="item.slot ? `${item.slot}-body` : 'body'"
|
|
69
|
+
<slot :name="item.slot || 'content'" :item="item" :index="index" :open="open" :ui="ui">
|
|
70
|
+
<div :class="ui.body({ class: [props.ui?.body, item.ui?.body] })" data-part="body">
|
|
71
|
+
<slot :name="item.slot ? `${item.slot}-body` : 'body'" :item="item" :index="index" :open="open" :ui="ui">
|
|
67
72
|
{{ item.content }}
|
|
68
73
|
</slot>
|
|
69
74
|
</div>
|
|
@@ -1,52 +1,74 @@
|
|
|
1
|
-
import type { AccordionRootEmits, AccordionRootProps } from 'reka-ui';
|
|
2
|
-
import
|
|
3
|
-
import type {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
export interface AccordionItem {
|
|
1
|
+
import type { AccordionRootEmits, AccordionRootProps, PrimitiveProps } from 'reka-ui';
|
|
2
|
+
import theme from '#build/ui/accordion';
|
|
3
|
+
import type { ComponentBaseProps, ComponentStyler, ComponentUIProps, IconProps } from '../types';
|
|
4
|
+
import type { DynamicSlots, GetItemKeys, StaticSlot } from '../types/utils';
|
|
5
|
+
export interface AccordionItem extends ComponentBaseProps {
|
|
7
6
|
label?: string;
|
|
8
|
-
icon?:
|
|
9
|
-
trailingIcon?:
|
|
7
|
+
icon?: IconProps['name'];
|
|
8
|
+
trailingIcon?: IconProps['name'];
|
|
10
9
|
slot?: string;
|
|
11
10
|
content?: string;
|
|
12
11
|
/** A unique value for the accordion item. Defaults to the index. */
|
|
13
12
|
value?: string;
|
|
14
13
|
disabled?: boolean;
|
|
14
|
+
ui?: Pick<ComponentUIProps<typeof theme>, 'item' | 'header' | 'trigger' | 'leadingIcon' | 'label' | 'trailingIcon' | 'content' | 'body'>;
|
|
15
15
|
[key: string]: any;
|
|
16
16
|
}
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
default?: SlotProps<T>;
|
|
24
|
-
leading?: SlotProps<T>;
|
|
25
|
-
trailing?: SlotProps<T>;
|
|
26
|
-
content?: SlotProps<T>;
|
|
27
|
-
body?: SlotProps<T>;
|
|
28
|
-
} & DynamicSlots<T, 'body', SlotProps<T>>;
|
|
29
|
-
export interface AccordionProps<T extends AccordionItem = AccordionItem> extends ComponentAttrs<typeof accordion>, Pick<AccordionRootProps, 'as' | 'collapsible' | 'defaultValue' | 'modelValue' | 'type' | 'disabled' | 'unmountOnHide'> {
|
|
17
|
+
export interface AccordionProps<T extends AccordionItem = AccordionItem> extends ComponentBaseProps, Pick<AccordionRootProps, 'collapsible' | 'defaultValue' | 'modelValue' | 'type' | 'disabled' | 'unmountOnHide'> {
|
|
18
|
+
/**
|
|
19
|
+
* The element or component this component should render as.
|
|
20
|
+
* @default "div"
|
|
21
|
+
*/
|
|
22
|
+
as?: PrimitiveProps['as'];
|
|
30
23
|
items?: T[];
|
|
31
24
|
/**
|
|
32
25
|
* The icon displayed on the right side of the trigger.
|
|
33
26
|
* @default app.icons.chevronDown
|
|
34
27
|
*/
|
|
35
|
-
trailingIcon?:
|
|
36
|
-
|
|
28
|
+
trailingIcon?: IconProps['name'];
|
|
29
|
+
/**
|
|
30
|
+
* The key used to get the label from the item.
|
|
31
|
+
* @default "label"
|
|
32
|
+
*/
|
|
33
|
+
labelKey?: GetItemKeys<T>;
|
|
34
|
+
ui?: ComponentUIProps<typeof theme>;
|
|
35
|
+
}
|
|
36
|
+
export interface AccordionEmits extends AccordionRootEmits {
|
|
37
37
|
}
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
38
|
+
type SlotProps<T extends AccordionItem> = StaticSlot<{
|
|
39
|
+
item: T;
|
|
40
|
+
index: number;
|
|
41
|
+
open: boolean;
|
|
42
|
+
ui: ComponentStyler<typeof theme>;
|
|
43
|
+
}>;
|
|
44
|
+
export type AccordionSlots<T extends AccordionItem = AccordionItem> = {
|
|
45
|
+
default: StaticSlot<{
|
|
46
|
+
item: T;
|
|
47
|
+
index: number;
|
|
48
|
+
open: boolean;
|
|
49
|
+
}>;
|
|
50
|
+
leading: SlotProps<T>;
|
|
51
|
+
trailing: SlotProps<T>;
|
|
52
|
+
content: SlotProps<T>;
|
|
53
|
+
body: SlotProps<T>;
|
|
54
|
+
} & DynamicSlots<T, 'body', {
|
|
55
|
+
index: number;
|
|
56
|
+
open: boolean;
|
|
57
|
+
ui: ComponentStyler<typeof theme>;
|
|
58
|
+
}>;
|
|
59
|
+
declare const __VLS_export: <T extends AccordionItem>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
60
|
+
props: __VLS_PrettifyLocal<AccordionProps<T> & {
|
|
61
|
+
"onUpdate:modelValue"?: ((value: string | string[] | undefined) => any) | undefined;
|
|
62
|
+
}> & import("vue").PublicProps;
|
|
63
|
+
expose: (exposed: {}) => void;
|
|
43
64
|
attrs: any;
|
|
44
65
|
slots: AccordionSlots<T>;
|
|
45
66
|
emit: (evt: "update:modelValue", value: string | string[] | undefined) => void;
|
|
46
67
|
}>) => import("vue").VNode & {
|
|
47
68
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
48
69
|
};
|
|
70
|
+
declare const _default: typeof __VLS_export;
|
|
49
71
|
export default _default;
|
|
50
72
|
type __VLS_PrettifyLocal<T> = {
|
|
51
|
-
[K in keyof T]: T[K];
|
|
73
|
+
[K in keyof T as K]: T[K];
|
|
52
74
|
} & {};
|