@nuxt/ui 2.16.0 → 2.18.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/dist/module.d.mts +3 -1985
- package/dist/module.d.ts +3 -1985
- package/dist/module.json +6 -2
- package/dist/module.mjs +6 -71
- package/dist/runtime/components/data/Table.vue +54 -19
- package/dist/runtime/components/data/Table.vue.d.ts +247 -48
- package/dist/runtime/components/elements/Accordion.vue +1 -2
- package/dist/runtime/components/elements/Accordion.vue.d.ts +140 -14
- package/dist/runtime/components/elements/Alert.vue +12 -10
- package/dist/runtime/components/elements/Alert.vue.d.ts +107 -24
- package/dist/runtime/components/elements/Avatar.vue +1 -1
- package/dist/runtime/components/elements/Avatar.vue.d.ts +153 -32
- package/dist/runtime/components/elements/AvatarGroup.d.ts +17 -8
- package/dist/runtime/components/elements/{AvatarGroup.mjs → AvatarGroup.js} +2 -2
- package/dist/runtime/components/elements/Badge.vue.d.ts +55 -18
- package/dist/runtime/components/elements/Button.vue +1 -2
- package/dist/runtime/components/elements/Button.vue.d.ts +259 -96
- package/dist/runtime/components/elements/ButtonGroup.d.ts +110 -6
- package/dist/runtime/components/elements/{ButtonGroup.mjs → ButtonGroup.js} +3 -3
- package/dist/runtime/components/elements/Carousel.vue.d.ts +75 -20
- package/dist/runtime/components/elements/Chip.vue.d.ts +97 -25
- package/dist/runtime/components/elements/Dropdown.vue +4 -9
- package/dist/runtime/components/elements/Dropdown.vue.d.ts +135 -16
- package/dist/runtime/components/elements/Kbd.vue.d.ts +45 -10
- package/dist/runtime/components/elements/Link.vue.d.ts +73 -73
- package/dist/runtime/components/elements/Meter.vue +1 -1
- package/dist/runtime/components/elements/Meter.vue.d.ts +178 -22
- package/dist/runtime/components/elements/MeterGroup.d.ts +70 -13
- package/dist/runtime/components/elements/{MeterGroup.mjs → MeterGroup.js} +3 -3
- package/dist/runtime/components/elements/Progress.vue +7 -2
- package/dist/runtime/components/elements/Progress.vue.d.ts +187 -31
- package/dist/runtime/components/forms/Checkbox.vue +5 -3
- package/dist/runtime/components/forms/Checkbox.vue.d.ts +76 -35
- package/dist/runtime/components/forms/Form.vue +9 -13
- package/dist/runtime/components/forms/Form.vue.d.ts +14 -18
- package/dist/runtime/components/forms/FormGroup.vue +1 -1
- package/dist/runtime/components/forms/FormGroup.vue.d.ts +80 -27
- package/dist/runtime/components/forms/Input.vue +3 -3
- package/dist/runtime/components/forms/Input.vue.d.ts +276 -59
- package/dist/runtime/components/forms/InputMenu.vue +12 -10
- package/dist/runtime/components/forms/InputMenu.vue.d.ts +434 -84
- package/dist/runtime/components/forms/Radio.vue +5 -3
- package/dist/runtime/components/forms/Radio.vue.d.ts +74 -35
- package/dist/runtime/components/forms/RadioGroup.vue +11 -3
- package/dist/runtime/components/forms/RadioGroup.vue.d.ts +85 -27
- package/dist/runtime/components/forms/Range.vue.d.ts +155 -26
- package/dist/runtime/components/forms/Select.vue +4 -4
- package/dist/runtime/components/forms/Select.vue.d.ts +273 -50
- package/dist/runtime/components/forms/SelectMenu.vue +51 -26
- package/dist/runtime/components/forms/SelectMenu.vue.d.ts +451 -86
- package/dist/runtime/components/forms/Textarea.vue.d.ts +263 -48
- package/dist/runtime/components/forms/Toggle.vue +1 -1
- package/dist/runtime/components/forms/Toggle.vue.d.ts +153 -26
- package/dist/runtime/components/layout/Card.vue.d.ts +55 -5
- package/dist/runtime/components/layout/Container.vue.d.ts +19 -5
- package/dist/runtime/components/layout/Divider.vue +1 -2
- package/dist/runtime/components/layout/Divider.vue.d.ts +121 -16
- package/dist/runtime/components/layout/Skeleton.vue +5 -1
- package/dist/runtime/components/layout/Skeleton.vue.d.ts +27 -4
- package/dist/runtime/components/navigation/Breadcrumb.vue +2 -3
- package/dist/runtime/components/navigation/Breadcrumb.vue.d.ts +52 -9
- package/dist/runtime/components/navigation/CommandPalette.vue +11 -5
- package/dist/runtime/components/navigation/CommandPalette.vue.d.ts +198 -40
- package/dist/runtime/components/navigation/CommandPaletteGroup.vue +1 -3
- package/dist/runtime/components/navigation/CommandPaletteGroup.vue.d.ts +5 -7
- package/dist/runtime/components/navigation/HorizontalNavigation.vue +1 -4
- package/dist/runtime/components/navigation/HorizontalNavigation.vue.d.ts +64 -9
- package/dist/runtime/components/navigation/Pagination.vue +2 -4
- package/dist/runtime/components/navigation/Pagination.vue.d.ts +84 -12
- package/dist/runtime/components/navigation/Tabs.vue +15 -1
- package/dist/runtime/components/navigation/Tabs.vue.d.ts +95 -15
- package/dist/runtime/components/navigation/VerticalNavigation.vue +1 -5
- package/dist/runtime/components/navigation/VerticalNavigation.vue.d.ts +78 -9
- package/dist/runtime/components/overlays/ContextMenu.vue.d.ts +71 -8
- package/dist/runtime/components/overlays/Modal.vue.d.ts +85 -11
- package/dist/runtime/components/overlays/Notification.vue +5 -6
- package/dist/runtime/components/overlays/Notification.vue.d.ts +130 -29
- package/dist/runtime/components/overlays/Notifications.vue.d.ts +31 -16
- package/dist/runtime/components/overlays/Popover.vue +3 -6
- package/dist/runtime/components/overlays/Popover.vue.d.ts +110 -15
- package/dist/runtime/components/overlays/Slideover.vue +43 -6
- package/dist/runtime/components/overlays/Slideover.vue.d.ts +87 -14
- package/dist/runtime/components/overlays/Tooltip.vue.d.ts +90 -15
- package/dist/runtime/composables/{defineShortcuts.mjs → defineShortcuts.js} +1 -1
- package/dist/runtime/composables/{useButtonGroup.mjs → useButtonGroup.js} +8 -9
- package/dist/runtime/composables/{useCarouselScroll.mjs → useCarouselScroll.js} +2 -0
- package/dist/runtime/composables/useCopyToClipboard.d.ts +1 -1
- package/dist/runtime/composables/{useCopyToClipboard.mjs → useCopyToClipboard.js} +1 -1
- package/dist/runtime/composables/useFormGroup.d.ts +5 -5
- package/dist/runtime/composables/useFormGroup.js +49 -0
- package/dist/runtime/composables/useModal.d.ts +3 -3
- package/dist/runtime/composables/{useModal.mjs → useModal.js} +2 -4
- package/dist/runtime/composables/usePopper.d.ts +91 -55
- package/dist/runtime/composables/useShortcuts.d.ts +4 -4
- package/dist/runtime/composables/useSlideover.d.ts +3 -3
- package/dist/runtime/composables/{useSlideover.mjs → useSlideover.js} +2 -4
- package/dist/runtime/composables/useTimer.d.ts +1 -1
- package/dist/runtime/composables/useToast.d.ts +11 -11
- package/dist/runtime/composables/useUI.d.ts +1 -1
- package/dist/runtime/composables/{useUI.mjs → useUI.js} +1 -1
- package/dist/runtime/plugins/colors.d.ts +1 -1
- package/dist/runtime/plugins/{colors.mjs → colors.js} +1 -1
- package/dist/runtime/plugins/modals.d.ts +1 -1
- package/dist/runtime/plugins/{modals.mjs → modals.js} +1 -1
- package/dist/runtime/plugins/slideovers.d.ts +1 -1
- package/dist/runtime/plugins/{slideovers.mjs → slideovers.js} +1 -1
- package/dist/runtime/types/accordion.d.ts +6 -7
- package/dist/runtime/types/accordion.js +0 -0
- package/dist/runtime/types/alert.d.ts +8 -10
- package/dist/runtime/types/alert.js +0 -0
- package/dist/runtime/types/avatar.d.ts +13 -15
- package/dist/runtime/types/avatar.js +0 -0
- package/dist/runtime/types/badge.d.ts +11 -13
- package/dist/runtime/types/badge.js +0 -0
- package/dist/runtime/types/breadcrumb.d.ts +6 -8
- package/dist/runtime/types/breadcrumb.js +0 -0
- package/dist/runtime/types/button.d.ts +27 -29
- package/dist/runtime/types/button.js +0 -0
- package/dist/runtime/types/chip.d.ts +11 -13
- package/dist/runtime/types/chip.js +0 -0
- package/dist/runtime/types/clipboard.d.ts +7 -1
- package/dist/runtime/types/clipboard.js +0 -0
- package/dist/runtime/types/command-palette.d.ts +23 -24
- package/dist/runtime/types/command-palette.js +0 -0
- package/dist/runtime/types/component.d.ts +17 -14
- package/dist/runtime/types/component.js +0 -0
- package/dist/runtime/types/divider.d.ts +2 -3
- package/dist/runtime/types/divider.js +0 -0
- package/dist/runtime/types/dropdown.d.ts +12 -13
- package/dist/runtime/types/dropdown.js +0 -0
- package/dist/runtime/types/form-group.d.ts +4 -5
- package/dist/runtime/types/form-group.js +0 -0
- package/dist/runtime/types/form.d.ts +29 -28
- package/dist/runtime/types/form.js +0 -0
- package/dist/runtime/types/horizontal-navigation.d.ts +10 -11
- package/dist/runtime/types/horizontal-navigation.js +0 -0
- package/dist/runtime/types/index.d.ts +31 -31
- package/dist/runtime/types/index.js +31 -0
- package/dist/runtime/types/input.d.ts +7 -8
- package/dist/runtime/types/input.js +0 -0
- package/dist/runtime/types/kbd.d.ts +4 -5
- package/dist/runtime/types/kbd.js +0 -0
- package/dist/runtime/types/link.d.ts +9 -10
- package/dist/runtime/types/link.js +0 -0
- package/dist/runtime/types/meter.d.ts +4 -5
- package/dist/runtime/types/meter.js +0 -0
- package/dist/runtime/types/modal.d.ts +13 -15
- package/dist/runtime/types/modal.js +0 -0
- package/dist/runtime/types/notification.d.ts +17 -20
- package/dist/runtime/types/notification.js +0 -0
- package/dist/runtime/types/popper.d.ts +13 -15
- package/dist/runtime/types/popper.js +0 -0
- package/dist/runtime/types/progress.d.ts +5 -6
- package/dist/runtime/types/progress.js +0 -0
- package/dist/runtime/types/range.d.ts +6 -7
- package/dist/runtime/types/range.js +0 -0
- package/dist/runtime/types/select.d.ts +7 -8
- package/dist/runtime/types/select.js +0 -0
- package/dist/runtime/types/slideover.d.ts +10 -12
- package/dist/runtime/types/slideover.js +0 -0
- package/dist/runtime/types/tabs.d.ts +6 -5
- package/dist/runtime/types/tabs.js +0 -0
- package/dist/runtime/types/textarea.d.ts +7 -8
- package/dist/runtime/types/textarea.js +0 -0
- package/dist/runtime/types/toggle.d.ts +6 -7
- package/dist/runtime/types/toggle.js +0 -0
- package/dist/runtime/types/tooltip.d.ts +5 -5
- package/dist/runtime/types/tooltip.js +0 -0
- package/dist/runtime/types/utils.d.ts +15 -27
- package/dist/runtime/types/utils.js +0 -0
- package/dist/runtime/types/vertical-navigation.d.ts +10 -11
- package/dist/runtime/types/vertical-navigation.js +0 -0
- package/dist/runtime/ui.config/data/table.d.ts +10 -0
- package/dist/runtime/ui.config/data/{table.mjs → table.js} +10 -0
- package/dist/runtime/ui.config/elements/accordion.d.ts +1 -0
- package/dist/runtime/ui.config/elements/{accordion.mjs → accordion.js} +3 -2
- package/dist/runtime/ui.config/elements/alert.d.ts +2 -2
- package/dist/runtime/ui.config/elements/avatar.d.ts +2 -2
- package/dist/runtime/ui.config/elements/{carousel.mjs → carousel.js} +1 -1
- package/dist/runtime/ui.config/elements/{dropdown.mjs → dropdown.js} +1 -1
- package/dist/runtime/ui.config/forms/{inputMenu.mjs → inputMenu.js} +1 -1
- package/dist/runtime/ui.config/forms/{select.mjs → select.js} +1 -1
- package/dist/runtime/ui.config/forms/{selectMenu.mjs → selectMenu.js} +2 -2
- package/dist/runtime/ui.config/forms/{textarea.mjs → textarea.js} +1 -1
- package/dist/runtime/ui.config/forms/toggle.d.ts +2 -2
- package/dist/runtime/ui.config/index.d.ts +43 -43
- package/dist/runtime/ui.config/index.js +43 -0
- package/dist/runtime/ui.config/navigation/{breadcrumb.mjs → breadcrumb.js} +2 -2
- package/dist/runtime/ui.config/navigation/commandPalette.d.ts +1 -1
- package/dist/runtime/ui.config/navigation/tabs.d.ts +1 -0
- package/dist/runtime/ui.config/navigation/{tabs.mjs → tabs.js} +2 -1
- package/dist/runtime/ui.config/overlays/{contextMenu.mjs → contextMenu.js} +1 -1
- package/dist/runtime/ui.config/overlays/{modal.mjs → modal.js} +2 -2
- package/dist/runtime/ui.config/overlays/notification.d.ts +1 -1
- package/dist/runtime/ui.config/overlays/{popover.mjs → popover.js} +1 -1
- package/dist/runtime/ui.config/overlays/slideover.d.ts +3 -0
- package/dist/runtime/ui.config/overlays/{slideover.mjs → slideover.js} +6 -3
- package/dist/runtime/ui.config/overlays/{tooltip.mjs → tooltip.js} +1 -1
- package/dist/runtime/utils/colors.d.ts +2 -2
- package/dist/runtime/utils/{colors.mjs → colors.js} +1 -1
- package/dist/runtime/utils/index.d.ts +4 -4
- package/dist/runtime/utils/{index.mjs → index.js} +2 -2
- package/dist/runtime/utils/link.d.ts +26 -24
- package/dist/runtime/utils/{link.mjs → link.js} +1 -1
- package/dist/types.d.mts +1 -16
- package/dist/types.d.ts +1 -16
- package/package.json +29 -27
- package/dist/runtime/components/elements/Icon.vue +0 -29
- package/dist/runtime/components/elements/Icon.vue.d.ts +0 -24
- package/dist/runtime/composables/useFormGroup.mjs +0 -45
- package/dist/runtime/ui.config/index.mjs +0 -43
- /package/dist/runtime/composables/{usePopper.mjs → usePopper.js} +0 -0
- /package/dist/runtime/composables/{useShortcuts.mjs → useShortcuts.js} +0 -0
- /package/dist/runtime/composables/{useTimer.mjs → useTimer.js} +0 -0
- /package/dist/runtime/composables/{useToast.mjs → useToast.js} +0 -0
- /package/dist/runtime/ui.config/elements/{alert.mjs → alert.js} +0 -0
- /package/dist/runtime/ui.config/elements/{avatar.mjs → avatar.js} +0 -0
- /package/dist/runtime/ui.config/elements/{avatarGroup.mjs → avatarGroup.js} +0 -0
- /package/dist/runtime/ui.config/elements/{badge.mjs → badge.js} +0 -0
- /package/dist/runtime/ui.config/elements/{button.mjs → button.js} +0 -0
- /package/dist/runtime/ui.config/elements/{buttonGroup.mjs → buttonGroup.js} +0 -0
- /package/dist/runtime/ui.config/elements/{chip.mjs → chip.js} +0 -0
- /package/dist/runtime/ui.config/elements/{kbd.mjs → kbd.js} +0 -0
- /package/dist/runtime/ui.config/elements/{meter.mjs → meter.js} +0 -0
- /package/dist/runtime/ui.config/elements/{meterGroup.mjs → meterGroup.js} +0 -0
- /package/dist/runtime/ui.config/elements/{progress.mjs → progress.js} +0 -0
- /package/dist/runtime/ui.config/forms/{checkbox.mjs → checkbox.js} +0 -0
- /package/dist/runtime/ui.config/forms/{formGroup.mjs → formGroup.js} +0 -0
- /package/dist/runtime/ui.config/forms/{input.mjs → input.js} +0 -0
- /package/dist/runtime/ui.config/forms/{radio.mjs → radio.js} +0 -0
- /package/dist/runtime/ui.config/forms/{radioGroup.mjs → radioGroup.js} +0 -0
- /package/dist/runtime/ui.config/forms/{range.mjs → range.js} +0 -0
- /package/dist/runtime/ui.config/forms/{toggle.mjs → toggle.js} +0 -0
- /package/dist/runtime/ui.config/layout/{card.mjs → card.js} +0 -0
- /package/dist/runtime/ui.config/layout/{container.mjs → container.js} +0 -0
- /package/dist/runtime/ui.config/layout/{divider.mjs → divider.js} +0 -0
- /package/dist/runtime/ui.config/layout/{skeleton.mjs → skeleton.js} +0 -0
- /package/dist/runtime/ui.config/navigation/{commandPalette.mjs → commandPalette.js} +0 -0
- /package/dist/runtime/ui.config/navigation/{horizontalNavigation.mjs → horizontalNavigation.js} +0 -0
- /package/dist/runtime/ui.config/navigation/{pagination.mjs → pagination.js} +0 -0
- /package/dist/runtime/ui.config/navigation/{verticalNavigation.mjs → verticalNavigation.js} +0 -0
- /package/dist/runtime/ui.config/overlays/{notification.mjs → notification.js} +0 -0
- /package/dist/runtime/ui.config/overlays/{notifications.mjs → notifications.js} +0 -0
- /package/dist/runtime/ui.config/{popper.mjs → popper.js} +0 -0
- /package/dist/runtime/utils/{lodash.mjs → lodash.js} +0 -0
|
@@ -1,4 +1,39 @@
|
|
|
1
1
|
import type { WritableComputedRef, PropType } from 'vue';
|
|
2
|
+
import type { Strategy } from '../../types.js';
|
|
3
|
+
declare const config: {
|
|
4
|
+
wrapper: string;
|
|
5
|
+
overlay: {
|
|
6
|
+
base: string;
|
|
7
|
+
background: string;
|
|
8
|
+
transition: {
|
|
9
|
+
enter: string;
|
|
10
|
+
enterFrom: string;
|
|
11
|
+
enterTo: string;
|
|
12
|
+
leave: string;
|
|
13
|
+
leaveFrom: string;
|
|
14
|
+
leaveTo: string;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
base: string;
|
|
18
|
+
background: string;
|
|
19
|
+
ring: string;
|
|
20
|
+
rounded: string;
|
|
21
|
+
padding: string;
|
|
22
|
+
shadow: string;
|
|
23
|
+
width: string;
|
|
24
|
+
height: string;
|
|
25
|
+
translate: {
|
|
26
|
+
base: string;
|
|
27
|
+
left: string;
|
|
28
|
+
right: string;
|
|
29
|
+
top: string;
|
|
30
|
+
bottom: string;
|
|
31
|
+
};
|
|
32
|
+
transition: {
|
|
33
|
+
enter: string;
|
|
34
|
+
leave: string;
|
|
35
|
+
};
|
|
36
|
+
};
|
|
2
37
|
declare const _default: import("vue").DefineComponent<{
|
|
3
38
|
modelValue: {
|
|
4
39
|
type: PropType<boolean>;
|
|
@@ -9,7 +44,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
9
44
|
default: boolean;
|
|
10
45
|
};
|
|
11
46
|
side: {
|
|
12
|
-
type: PropType<"left" | "right">;
|
|
47
|
+
type: PropType<"left" | "right" | "top" | "bottom">;
|
|
13
48
|
default: string;
|
|
14
49
|
validator: (value: string) => boolean;
|
|
15
50
|
};
|
|
@@ -30,19 +65,55 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
30
65
|
default: () => string;
|
|
31
66
|
};
|
|
32
67
|
ui: {
|
|
33
|
-
type: PropType<
|
|
68
|
+
type: PropType<Partial<typeof config> & {
|
|
69
|
+
strategy?: Strategy;
|
|
70
|
+
}>;
|
|
34
71
|
default: () => {};
|
|
35
72
|
};
|
|
36
73
|
}, {
|
|
37
|
-
ui: import("vue").ComputedRef<
|
|
74
|
+
ui: import("vue").ComputedRef<{
|
|
75
|
+
wrapper: string;
|
|
76
|
+
overlay: {
|
|
77
|
+
base: string;
|
|
78
|
+
background: string;
|
|
79
|
+
transition: {
|
|
80
|
+
enter: string;
|
|
81
|
+
enterFrom: string;
|
|
82
|
+
enterTo: string;
|
|
83
|
+
leave: string;
|
|
84
|
+
leaveFrom: string;
|
|
85
|
+
leaveTo: string;
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
base: string;
|
|
89
|
+
background: string;
|
|
90
|
+
ring: string;
|
|
91
|
+
rounded: string;
|
|
92
|
+
padding: string;
|
|
93
|
+
shadow: string;
|
|
94
|
+
width: string;
|
|
95
|
+
height: string;
|
|
96
|
+
translate: {
|
|
97
|
+
base: string;
|
|
98
|
+
left: string;
|
|
99
|
+
right: string;
|
|
100
|
+
top: string;
|
|
101
|
+
bottom: string;
|
|
102
|
+
};
|
|
103
|
+
transition: {
|
|
104
|
+
enter: string;
|
|
105
|
+
leave: string;
|
|
106
|
+
};
|
|
107
|
+
}>;
|
|
38
108
|
attrs: import("vue").ComputedRef<Pick<{
|
|
39
109
|
[x: string]: unknown;
|
|
40
110
|
}, string>>;
|
|
41
111
|
isOpen: WritableComputedRef<boolean>;
|
|
42
|
-
transitionClass: import("vue").ComputedRef<
|
|
112
|
+
transitionClass: import("vue").ComputedRef<{}>;
|
|
113
|
+
sideType: import("vue").ComputedRef<"horizontal" | "vertical" | "right">;
|
|
43
114
|
onAfterLeave: () => void;
|
|
44
115
|
close: (value: boolean) => void;
|
|
45
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("
|
|
116
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("close" | "update:modelValue" | "close-prevented" | "after-leave")[], "close" | "update:modelValue" | "close-prevented" | "after-leave", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
46
117
|
modelValue: {
|
|
47
118
|
type: PropType<boolean>;
|
|
48
119
|
default: boolean;
|
|
@@ -52,7 +123,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
52
123
|
default: boolean;
|
|
53
124
|
};
|
|
54
125
|
side: {
|
|
55
|
-
type: PropType<"left" | "right">;
|
|
126
|
+
type: PropType<"left" | "right" | "top" | "bottom">;
|
|
56
127
|
default: string;
|
|
57
128
|
validator: (value: string) => boolean;
|
|
58
129
|
};
|
|
@@ -73,22 +144,24 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
73
144
|
default: () => string;
|
|
74
145
|
};
|
|
75
146
|
ui: {
|
|
76
|
-
type: PropType<
|
|
147
|
+
type: PropType<Partial<typeof config> & {
|
|
148
|
+
strategy?: Strategy;
|
|
149
|
+
}>;
|
|
77
150
|
default: () => {};
|
|
78
151
|
};
|
|
79
152
|
}>> & {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
"onClose-prevented"?: (
|
|
83
|
-
"onAfter-leave"?: (
|
|
153
|
+
onClose?: (...args: any[]) => any;
|
|
154
|
+
"onUpdate:modelValue"?: (...args: any[]) => any;
|
|
155
|
+
"onClose-prevented"?: (...args: any[]) => any;
|
|
156
|
+
"onAfter-leave"?: (...args: any[]) => any;
|
|
84
157
|
}, {
|
|
158
|
+
ui: {};
|
|
85
159
|
class: any;
|
|
86
160
|
transition: boolean;
|
|
87
|
-
ui: any;
|
|
88
|
-
modelValue: boolean;
|
|
89
161
|
appear: boolean;
|
|
90
162
|
overlay: boolean;
|
|
91
163
|
preventClose: boolean;
|
|
92
|
-
side: "left" | "
|
|
164
|
+
side: "right" | "left" | "top" | "bottom";
|
|
165
|
+
modelValue: boolean;
|
|
93
166
|
}, {}>;
|
|
94
167
|
export default _default;
|
|
@@ -1,9 +1,45 @@
|
|
|
1
1
|
import type { PropType } from 'vue';
|
|
2
|
-
import type { PopperOptions } from '../../types';
|
|
2
|
+
import type { PopperOptions, Strategy } from '../../types.js';
|
|
3
|
+
declare const config: {
|
|
4
|
+
wrapper: string;
|
|
5
|
+
container: string;
|
|
6
|
+
width: string;
|
|
7
|
+
background: string;
|
|
8
|
+
color: string;
|
|
9
|
+
shadow: string;
|
|
10
|
+
rounded: string;
|
|
11
|
+
ring: string;
|
|
12
|
+
base: string;
|
|
13
|
+
shortcuts: string;
|
|
14
|
+
middot: string;
|
|
15
|
+
transition: {
|
|
16
|
+
enterActiveClass: string;
|
|
17
|
+
enterFromClass: string;
|
|
18
|
+
enterToClass: string;
|
|
19
|
+
leaveActiveClass: string;
|
|
20
|
+
leaveFromClass: string;
|
|
21
|
+
leaveToClass: string;
|
|
22
|
+
};
|
|
23
|
+
popper: {
|
|
24
|
+
strategy: string;
|
|
25
|
+
};
|
|
26
|
+
default: {
|
|
27
|
+
openDelay: number;
|
|
28
|
+
closeDelay: number;
|
|
29
|
+
};
|
|
30
|
+
arrow: {
|
|
31
|
+
base: string;
|
|
32
|
+
ring: string;
|
|
33
|
+
rounded: string;
|
|
34
|
+
background: string;
|
|
35
|
+
shadow: string;
|
|
36
|
+
placement: string;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
3
39
|
declare const _default: import("vue").DefineComponent<{
|
|
4
40
|
text: {
|
|
5
41
|
type: StringConstructor;
|
|
6
|
-
default:
|
|
42
|
+
default: any;
|
|
7
43
|
};
|
|
8
44
|
prevent: {
|
|
9
45
|
type: BooleanConstructor;
|
|
@@ -11,15 +47,15 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
11
47
|
};
|
|
12
48
|
shortcuts: {
|
|
13
49
|
type: PropType<string[]>;
|
|
14
|
-
default: () =>
|
|
50
|
+
default: () => any[];
|
|
15
51
|
};
|
|
16
52
|
openDelay: {
|
|
17
53
|
type: NumberConstructor;
|
|
18
|
-
default: () =>
|
|
54
|
+
default: () => number;
|
|
19
55
|
};
|
|
20
56
|
closeDelay: {
|
|
21
57
|
type: NumberConstructor;
|
|
22
|
-
default: () =>
|
|
58
|
+
default: () => number;
|
|
23
59
|
};
|
|
24
60
|
popper: {
|
|
25
61
|
type: PropType<PopperOptions>;
|
|
@@ -30,11 +66,48 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
30
66
|
default: () => string;
|
|
31
67
|
};
|
|
32
68
|
ui: {
|
|
33
|
-
type: PropType<
|
|
69
|
+
type: PropType<Partial<typeof config> & {
|
|
70
|
+
strategy?: Strategy;
|
|
71
|
+
}>;
|
|
34
72
|
default: () => {};
|
|
35
73
|
};
|
|
36
74
|
}, {
|
|
37
|
-
ui: import("vue").ComputedRef<
|
|
75
|
+
ui: import("vue").ComputedRef<{
|
|
76
|
+
wrapper: string;
|
|
77
|
+
container: string;
|
|
78
|
+
width: string;
|
|
79
|
+
background: string;
|
|
80
|
+
color: string;
|
|
81
|
+
shadow: string;
|
|
82
|
+
rounded: string;
|
|
83
|
+
ring: string;
|
|
84
|
+
base: string;
|
|
85
|
+
shortcuts: string;
|
|
86
|
+
middot: string;
|
|
87
|
+
transition: {
|
|
88
|
+
enterActiveClass: string;
|
|
89
|
+
enterFromClass: string;
|
|
90
|
+
enterToClass: string;
|
|
91
|
+
leaveActiveClass: string;
|
|
92
|
+
leaveFromClass: string;
|
|
93
|
+
leaveToClass: string;
|
|
94
|
+
};
|
|
95
|
+
popper: {
|
|
96
|
+
strategy: string;
|
|
97
|
+
};
|
|
98
|
+
default: {
|
|
99
|
+
openDelay: number;
|
|
100
|
+
closeDelay: number;
|
|
101
|
+
};
|
|
102
|
+
arrow: {
|
|
103
|
+
base: string;
|
|
104
|
+
ring: string;
|
|
105
|
+
rounded: string;
|
|
106
|
+
background: string;
|
|
107
|
+
shadow: string;
|
|
108
|
+
placement: string;
|
|
109
|
+
};
|
|
110
|
+
}>;
|
|
38
111
|
attrs: import("vue").ComputedRef<Pick<{
|
|
39
112
|
[x: string]: unknown;
|
|
40
113
|
}, string>>;
|
|
@@ -47,7 +120,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
47
120
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
48
121
|
text: {
|
|
49
122
|
type: StringConstructor;
|
|
50
|
-
default:
|
|
123
|
+
default: any;
|
|
51
124
|
};
|
|
52
125
|
prevent: {
|
|
53
126
|
type: BooleanConstructor;
|
|
@@ -55,15 +128,15 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
55
128
|
};
|
|
56
129
|
shortcuts: {
|
|
57
130
|
type: PropType<string[]>;
|
|
58
|
-
default: () =>
|
|
131
|
+
default: () => any[];
|
|
59
132
|
};
|
|
60
133
|
openDelay: {
|
|
61
134
|
type: NumberConstructor;
|
|
62
|
-
default: () =>
|
|
135
|
+
default: () => number;
|
|
63
136
|
};
|
|
64
137
|
closeDelay: {
|
|
65
138
|
type: NumberConstructor;
|
|
66
|
-
default: () =>
|
|
139
|
+
default: () => number;
|
|
67
140
|
};
|
|
68
141
|
popper: {
|
|
69
142
|
type: PropType<PopperOptions>;
|
|
@@ -74,17 +147,19 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
74
147
|
default: () => string;
|
|
75
148
|
};
|
|
76
149
|
ui: {
|
|
77
|
-
type: PropType<
|
|
150
|
+
type: PropType<Partial<typeof config> & {
|
|
151
|
+
strategy?: Strategy;
|
|
152
|
+
}>;
|
|
78
153
|
default: () => {};
|
|
79
154
|
};
|
|
80
155
|
}>>, {
|
|
81
|
-
|
|
156
|
+
ui: {};
|
|
157
|
+
shortcuts: string[];
|
|
82
158
|
class: any;
|
|
83
159
|
popper: PopperOptions;
|
|
84
|
-
|
|
160
|
+
text: string;
|
|
85
161
|
openDelay: number;
|
|
86
162
|
closeDelay: number;
|
|
87
163
|
prevent: boolean;
|
|
88
|
-
shortcuts: string[];
|
|
89
164
|
}, {}>;
|
|
90
165
|
export default _default;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ref, computed } from "vue";
|
|
2
2
|
import { logicAnd, logicNot } from "@vueuse/math";
|
|
3
3
|
import { useEventListener, useDebounceFn } from "@vueuse/core";
|
|
4
|
-
import { useShortcuts } from "./useShortcuts.
|
|
4
|
+
import { useShortcuts } from "./useShortcuts.js";
|
|
5
5
|
const chainedShortcutRegex = /^[^-]+.*-.*[^-]+$/;
|
|
6
6
|
const combinedShortcutRegex = /^[^_]+.*_.*[^_]+$/;
|
|
7
7
|
export const defineShortcuts = (config, options = {}) => {
|
|
@@ -44,16 +44,15 @@ export function useInjectButtonGroup({ ui, props }) {
|
|
|
44
44
|
groupContext?.value.unregister(instance);
|
|
45
45
|
});
|
|
46
46
|
return {
|
|
47
|
-
size: computed(() =>
|
|
47
|
+
size: computed(() => {
|
|
48
|
+
if (!groupContext?.value) return props.size;
|
|
49
|
+
return groupContext?.value.size ?? ui.value.default.size;
|
|
50
|
+
}),
|
|
48
51
|
rounded: computed(() => {
|
|
49
|
-
if (!groupContext || positionInGroup.value === -1)
|
|
50
|
-
|
|
51
|
-
if (
|
|
52
|
-
|
|
53
|
-
if (positionInGroup.value === 0)
|
|
54
|
-
return groupContext.value.rounded.start;
|
|
55
|
-
if (positionInGroup.value === groupContext.value.children.length - 1)
|
|
56
|
-
return groupContext.value.rounded.end;
|
|
52
|
+
if (!groupContext || positionInGroup.value === -1) return ui.value.rounded;
|
|
53
|
+
if (groupContext.value.children.length === 1) return groupContext.value.ui.rounded;
|
|
54
|
+
if (positionInGroup.value === 0) return groupContext.value.rounded.start;
|
|
55
|
+
if (positionInGroup.value === groupContext.value.children.length - 1) return groupContext.value.rounded.end;
|
|
57
56
|
return "rounded-none";
|
|
58
57
|
})
|
|
59
58
|
};
|
|
@@ -11,11 +11,13 @@ export const useCarouselScroll = (el) => {
|
|
|
11
11
|
function onMouseUp() {
|
|
12
12
|
el.value.style.removeProperty("scroll-behavior");
|
|
13
13
|
el.value.style.removeProperty("scroll-snap-type");
|
|
14
|
+
el.value.style.removeProperty("pointer-events");
|
|
14
15
|
window.removeEventListener("mousemove", onMouseMove);
|
|
15
16
|
window.removeEventListener("mouseup", onMouseUp);
|
|
16
17
|
}
|
|
17
18
|
function onMouseMove(e) {
|
|
18
19
|
e.preventDefault();
|
|
20
|
+
el.value.style.pointerEvents = "none";
|
|
19
21
|
const delta = e.pageX - x.value;
|
|
20
22
|
x.value = e.pageX;
|
|
21
23
|
el.value.scrollBy(-delta, 0);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useClipboard } from "@vueuse/core";
|
|
2
|
-
import { useToast } from "./useToast.
|
|
2
|
+
import { useToast } from "./useToast.js";
|
|
3
3
|
export function useCopyToClipboard(options = {}) {
|
|
4
4
|
const { copy: copyToClipboard, isSupported } = useClipboard();
|
|
5
5
|
const toast = useToast();
|
|
@@ -7,12 +7,12 @@ type InputProps = {
|
|
|
7
7
|
legend?: string | null;
|
|
8
8
|
};
|
|
9
9
|
export declare const useFormGroup: (inputProps?: InputProps, config?: any) => {
|
|
10
|
-
inputId: import("vue").ComputedRef<string
|
|
11
|
-
name: import("vue").ComputedRef<string
|
|
12
|
-
size: import("vue").ComputedRef<
|
|
13
|
-
color: import("vue").ComputedRef<string
|
|
10
|
+
inputId: import("vue").ComputedRef<string>;
|
|
11
|
+
name: import("vue").ComputedRef<string>;
|
|
12
|
+
size: import("vue").ComputedRef<string | number | symbol>;
|
|
13
|
+
color: import("vue").ComputedRef<string>;
|
|
14
14
|
emitFormBlur: () => void;
|
|
15
|
-
emitFormInput: import("@vueuse/
|
|
15
|
+
emitFormInput: import("@vueuse/shared").PromisifyFn<() => void>;
|
|
16
16
|
emitFormChange: () => void;
|
|
17
17
|
};
|
|
18
18
|
export {};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { inject, ref, computed } from "vue";
|
|
2
|
+
import { useDebounceFn } from "@vueuse/core";
|
|
3
|
+
import { mergeConfig } from "../utils/index.js";
|
|
4
|
+
import appConfig from "#build/app.config";
|
|
5
|
+
import { formGroup } from "#ui/ui.config";
|
|
6
|
+
const formGroupConfig = mergeConfig(appConfig.ui.strategy, appConfig.ui.formGroup, formGroup);
|
|
7
|
+
export const useFormGroup = (inputProps, config) => {
|
|
8
|
+
const formBus = inject("form-events", void 0);
|
|
9
|
+
const formGroup2 = inject("form-group", void 0);
|
|
10
|
+
const formInputs = inject("form-inputs", void 0);
|
|
11
|
+
if (formGroup2) {
|
|
12
|
+
if (inputProps?.id) {
|
|
13
|
+
formGroup2.inputId.value = inputProps?.id;
|
|
14
|
+
}
|
|
15
|
+
if (formInputs) {
|
|
16
|
+
formInputs.value[formGroup2.name.value] = formGroup2.inputId.value;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
const blurred = ref(false);
|
|
20
|
+
function emitFormEvent(type, path) {
|
|
21
|
+
if (formBus) {
|
|
22
|
+
formBus.emit({ type, path });
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
function emitFormBlur() {
|
|
26
|
+
emitFormEvent("blur", formGroup2?.name.value);
|
|
27
|
+
blurred.value = true;
|
|
28
|
+
}
|
|
29
|
+
function emitFormChange() {
|
|
30
|
+
emitFormEvent("change", formGroup2?.name.value);
|
|
31
|
+
}
|
|
32
|
+
const emitFormInput = useDebounceFn(() => {
|
|
33
|
+
if (blurred.value || formGroup2?.eagerValidation.value) {
|
|
34
|
+
emitFormEvent("input", formGroup2?.name.value);
|
|
35
|
+
}
|
|
36
|
+
}, 300);
|
|
37
|
+
return {
|
|
38
|
+
inputId: computed(() => inputProps?.id ?? formGroup2?.inputId.value),
|
|
39
|
+
name: computed(() => inputProps?.name ?? formGroup2?.name.value),
|
|
40
|
+
size: computed(() => {
|
|
41
|
+
const formGroupSize = config.size[formGroup2?.size.value] ? formGroup2?.size.value : null;
|
|
42
|
+
return inputProps?.size ?? formGroupSize ?? formGroupConfig?.default?.size;
|
|
43
|
+
}),
|
|
44
|
+
color: computed(() => formGroup2?.error?.value ? "red" : inputProps?.color),
|
|
45
|
+
emitFormBlur,
|
|
46
|
+
emitFormInput,
|
|
47
|
+
emitFormChange
|
|
48
|
+
};
|
|
49
|
+
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import type { ShallowRef, Component, InjectionKey } from 'vue';
|
|
2
|
-
import type { ComponentProps } from '../types/component';
|
|
3
|
-
import type { Modal, ModalState } from '../types/modal';
|
|
2
|
+
import type { ComponentProps } from '../types/component.js';
|
|
3
|
+
import type { Modal, ModalState } from '../types/modal.js';
|
|
4
4
|
export declare const modalInjectionKey: InjectionKey<ShallowRef<ModalState>>;
|
|
5
5
|
declare function _useModal(): {
|
|
6
6
|
open: <T extends Component>(component: T, props?: Modal & ComponentProps<T>) => void;
|
|
7
7
|
close: () => Promise<void>;
|
|
8
8
|
reset: () => void;
|
|
9
|
-
patch: <
|
|
9
|
+
patch: <T extends Component = {}>(props: Partial<Modal & ComponentProps<T>>) => void;
|
|
10
10
|
isOpen: import("vue").Ref<boolean>;
|
|
11
11
|
};
|
|
12
12
|
export declare const useModal: typeof _useModal;
|
|
@@ -15,8 +15,7 @@ function _useModal() {
|
|
|
15
15
|
isOpen.value = true;
|
|
16
16
|
}
|
|
17
17
|
async function close() {
|
|
18
|
-
if (!modalState)
|
|
19
|
-
return;
|
|
18
|
+
if (!modalState) return;
|
|
20
19
|
isOpen.value = false;
|
|
21
20
|
}
|
|
22
21
|
function reset() {
|
|
@@ -26,8 +25,7 @@ function _useModal() {
|
|
|
26
25
|
};
|
|
27
26
|
}
|
|
28
27
|
function patch(props) {
|
|
29
|
-
if (!modalState)
|
|
30
|
-
return;
|
|
28
|
+
if (!modalState) return;
|
|
31
29
|
modalState.value = {
|
|
32
30
|
...modalState.value,
|
|
33
31
|
props: {
|