@volverjs/ui-vue 0.0.10-beta.1 → 0.0.10-beta.10
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 +64 -1
- package/auto-imports.d.ts +1 -1
- package/bin/icons.cjs +1 -1
- package/bin/icons.js +34 -19
- package/dist/components/VvAccordion/VvAccordion.es.js +33 -4
- package/dist/components/VvAccordion/VvAccordion.umd.js +1 -1
- package/dist/components/VvAccordion/VvAccordion.vue.d.ts +4 -4
- package/dist/components/VvAccordion/index.d.ts +1 -1
- package/dist/components/VvAccordionGroup/VvAccordionGroup.es.js +75 -27
- package/dist/components/VvAccordionGroup/VvAccordionGroup.umd.js +1 -1
- package/dist/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +5 -5
- package/dist/components/VvAction/VvAction.es.js +26 -4
- package/dist/components/VvAction/VvAction.umd.js +1 -1
- package/dist/components/VvAction/VvAction.vue.d.ts +17 -4
- package/dist/components/VvAction/index.d.ts +5 -0
- package/dist/components/VvAlert/VvAlert.es.js +96 -45
- package/dist/components/VvAlert/VvAlert.umd.js +1 -1
- package/dist/components/VvAlert/VvAlert.vue.d.ts +4 -4
- package/dist/components/VvAlertGroup/VvAlertGroup.es.js +136 -66
- package/dist/components/VvAlertGroup/VvAlertGroup.umd.js +1 -1
- package/dist/components/VvAlertGroup/VvAlertGroup.vue.d.ts +4 -4
- package/dist/components/VvAvatar/VvAvatar.es.js +22 -1
- package/dist/components/VvAvatar/VvAvatar.umd.js +1 -1
- package/dist/components/VvAvatarGroup/VvAvatarGroup.es.js +79 -28
- package/dist/components/VvAvatarGroup/VvAvatarGroup.umd.js +1 -1
- package/dist/components/VvBadge/VvBadge.es.js +39 -8
- package/dist/components/VvBadge/VvBadge.umd.js +1 -1
- package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +224 -41
- package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
- package/dist/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +14 -3
- package/dist/components/VvBreadcrumb/index.d.ts +2 -9
- package/dist/components/VvButton/VvButton.es.js +67 -22
- package/dist/components/VvButton/VvButton.umd.js +1 -1
- package/dist/components/VvButton/VvButton.vue.d.ts +25 -9
- package/dist/components/VvButton/index.d.ts +5 -0
- package/dist/components/VvButtonGroup/VvButtonGroup.es.js +33 -6
- package/dist/components/VvButtonGroup/VvButtonGroup.umd.js +1 -1
- package/dist/components/VvButtonGroup/VvButtonGroup.vue.d.ts +6 -6
- package/dist/components/VvCard/VvCard.es.js +47 -16
- package/dist/components/VvCard/VvCard.umd.js +1 -1
- package/dist/components/VvCheckbox/VvCheckbox.es.js +32 -4
- package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -1
- package/dist/components/VvCheckbox/VvCheckbox.vue.d.ts +8 -8
- package/dist/components/VvCheckbox/index.d.ts +1 -1
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +101 -46
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -1
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +7 -7
- package/dist/components/VvCheckboxGroup/index.d.ts +1 -1
- package/dist/components/VvCombobox/VvCombobox.es.js +625 -379
- package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
- package/dist/components/VvCombobox/VvCombobox.vue.d.ts +112 -112
- package/dist/components/VvCombobox/index.d.ts +32 -32
- package/dist/components/VvDialog/VvDialog.es.js +65 -27
- package/dist/components/VvDialog/VvDialog.umd.js +1 -1
- package/dist/components/VvDialog/VvDialog.vue.d.ts +4 -4
- package/dist/components/VvDropdown/VvDropdown.es.js +87 -46
- package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
- package/dist/components/VvDropdown/VvDropdown.vue.d.ts +203 -189
- package/dist/components/VvDropdown/VvDropdownAction.vue.d.ts +12 -0
- package/dist/components/VvDropdown/index.d.ts +32 -32
- package/dist/components/VvDropdownAction/VvDropdownAction.es.js +46 -12
- package/dist/components/VvDropdownAction/VvDropdownAction.umd.js +1 -1
- package/dist/components/VvDropdownItem/VvDropdownItem.es.js +13 -7
- package/dist/components/VvDropdownOptgroup/VvDropdownOptgroup.es.js +28 -1
- package/dist/components/VvDropdownOptgroup/VvDropdownOptgroup.umd.js +1 -1
- package/dist/components/VvDropdownOption/VvDropdownOption.es.js +40 -8
- package/dist/components/VvDropdownOption/VvDropdownOption.umd.js +1 -1
- package/dist/components/VvIcon/VvIcon.es.js +1 -1
- package/dist/components/VvIcon/VvIcon.umd.js +1 -1
- package/dist/components/VvInputText/VvInputClearAction.d.ts +1 -1
- package/dist/components/VvInputText/VvInputText.es.js +149 -99
- package/dist/components/VvInputText/VvInputText.umd.js +1 -1
- package/dist/components/VvInputText/VvInputText.vue.d.ts +10 -10
- package/dist/components/VvInputText/index.d.ts +8 -2
- package/dist/components/VvNav/VvNav.es.js +115 -63
- package/dist/components/VvNav/VvNav.umd.js +1 -1
- package/dist/components/VvNav/VvNav.vue.d.ts +31 -12
- package/dist/components/VvNav/VvNavItem.vue.d.ts +9 -0
- package/dist/components/VvNav/index.d.ts +1 -12
- package/dist/components/VvNavItem/VvNavItem.es.js +413 -0
- package/dist/components/VvNavItem/VvNavItem.umd.js +1 -0
- package/dist/components/VvNavSeparator/VvNavSeparator.es.js +24 -0
- package/dist/components/VvNavSeparator/VvNavSeparator.umd.js +1 -0
- package/dist/components/VvProgress/VvProgress.es.js +33 -6
- package/dist/components/VvProgress/VvProgress.umd.js +1 -1
- package/dist/components/VvRadio/VvRadio.es.js +32 -4
- package/dist/components/VvRadio/VvRadio.umd.js +1 -1
- package/dist/components/VvRadio/VvRadio.vue.d.ts +8 -8
- package/dist/components/VvRadio/index.d.ts +1 -1
- package/dist/components/VvRadioGroup/VvRadioGroup.es.js +101 -46
- package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -1
- package/dist/components/VvRadioGroup/VvRadioGroup.vue.d.ts +7 -7
- package/dist/components/VvRadioGroup/index.d.ts +1 -1
- package/dist/components/VvSelect/VvSelect.es.js +156 -96
- package/dist/components/VvSelect/VvSelect.umd.js +1 -1
- package/dist/components/VvSelect/VvSelect.vue.d.ts +13 -13
- package/dist/components/VvSelect/index.d.ts +1 -1
- package/dist/components/VvTab/VvTab.es.js +214 -99
- package/dist/components/VvTab/VvTab.umd.js +1 -1
- package/dist/components/VvTab/VvTab.vue.d.ts +40 -11
- package/dist/components/VvTab/index.d.ts +9 -3
- package/dist/components/VvTextarea/VvTextarea.es.js +123 -77
- package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
- package/dist/components/VvTextarea/VvTextarea.vue.d.ts +10 -10
- package/dist/components/VvTooltip/VvTooltip.es.js +40 -9
- package/dist/components/VvTooltip/VvTooltip.umd.js +1 -1
- package/dist/components/index.es.js +1583 -991
- package/dist/components/index.umd.js +1 -1
- package/dist/composables/group/useInjectedGroupState.d.ts +1 -1
- package/dist/composables/useVolver.d.ts +1 -1
- package/dist/directives/index.d.ts +3 -5
- package/dist/directives/index.es.js +60 -23
- package/dist/directives/index.umd.js +1 -1
- package/dist/directives/v-tooltip.es.js +58 -18
- package/dist/directives/v-tooltip.umd.js +1 -1
- package/dist/icons.es.js +3 -3
- package/dist/icons.umd.js +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.es.js +19 -16
- package/dist/index.umd.js +1 -1
- package/dist/props/index.d.ts +58 -34
- package/dist/stories/AccordionGroup/AccordionGroup.stories.d.ts +50 -15
- package/dist/stories/AccordionGroup/AccordionGroupSlots.stories.d.ts +332 -83
- package/dist/stories/Combobox/Combobox.settings.d.ts +8 -0
- package/dist/stories/Tab/Tab.settings.d.ts +4 -37
- package/dist/types/alert.d.ts +13 -0
- package/dist/types/floating-ui.d.ts +6 -0
- package/dist/types/generic.d.ts +4 -0
- package/dist/types/group.d.ts +37 -0
- package/dist/types/index.d.ts +5 -0
- package/dist/types/nav.d.ts +17 -0
- package/package.json +60 -51
- package/src/Volver.ts +22 -16
- package/src/assets/icons/detailed.json +1 -1
- package/src/assets/icons/normal.json +1 -1
- package/src/assets/icons/simple.json +1 -1
- package/src/components/VvAccordion/VvAccordion.vue +2 -2
- package/src/components/VvAction/VvAction.vue +5 -2
- package/src/components/VvBreadcrumb/VvBreadcrumb.vue +20 -19
- package/src/components/VvBreadcrumb/index.ts +2 -8
- package/src/components/VvCombobox/VvCombobox.vue +19 -8
- package/src/components/VvCombobox/index.ts +4 -0
- package/src/components/VvInputText/VvInputText.vue +2 -2
- package/src/components/VvNav/VvNav.vue +30 -50
- package/src/components/VvNav/VvNavItem.vue +18 -0
- package/src/components/VvNav/VvNavSeparator.vue +11 -0
- package/src/components/VvNav/index.ts +2 -15
- package/src/components/VvTab/VvTab.vue +63 -35
- package/src/components/VvTab/index.ts +10 -4
- package/src/components/VvTextarea/VvTextarea.vue +1 -1
- package/src/composables/useUniqueId.ts +2 -2
- package/src/directives/index.ts +1 -4
- package/src/directives/v-tooltip.ts +19 -10
- package/src/index.ts +3 -1
- package/src/props/index.ts +27 -3
- package/src/stories/Button/ButtonModifiers.stories.ts +4 -14
- package/src/stories/Combobox/Combobox.settings.ts +8 -0
- package/src/stories/Nav/Nav.settings.ts +3 -4
- package/src/stories/Nav/Nav.test.ts +4 -15
- package/src/stories/Tab/Tab.settings.ts +9 -9
- package/src/stories/Tab/Tab.stories.ts +2 -2
- package/src/stories/Tab/Tab.test.ts +6 -14
- package/src/stories/argTypes.ts +1 -1
- package/src/types/generic.ts +6 -0
- package/src/types/index.ts +5 -0
- package/src/types/nav.ts +19 -0
- package/dist/components/VvNav/VvNavItemTitle.vue.d.ts +0 -6
- package/dist/components/VvNavItemTitle/VvNavItemTitle.es.js +0 -19
- package/dist/components/VvNavItemTitle/VvNavItemTitle.umd.js +0 -1
- package/src/components/VvNav/VvNavItemTitle.vue +0 -11
- package/src/components/VvNav/VvNavSeparator.ts +0 -8
- package/src/types/generic.d.ts +0 -6
- /package/dist/components/VvNav/{VvNavSeparator.d.ts → VvNavSeparator.vue.d.ts} +0 -0
- /package/src/types/{alert.d.ts → alert.ts} +0 -0
- /package/src/types/{floating-ui.d.ts → floating-ui.ts} +0 -0
- /package/src/types/{group.d.ts → group.ts} +0 -0
|
@@ -9,6 +9,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
9
9
|
type: StringConstructor;
|
|
10
10
|
default: undefined;
|
|
11
11
|
};
|
|
12
|
+
defaultTag: {
|
|
13
|
+
type: StringConstructor;
|
|
14
|
+
default: import("../../constants").ActionTag;
|
|
15
|
+
};
|
|
12
16
|
to: {
|
|
13
17
|
type: (ObjectConstructor | StringConstructor)[];
|
|
14
18
|
};
|
|
@@ -21,6 +25,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
21
25
|
type: StringConstructor;
|
|
22
26
|
default: string;
|
|
23
27
|
};
|
|
28
|
+
current: BooleanConstructor;
|
|
24
29
|
active: BooleanConstructor;
|
|
25
30
|
pressed: BooleanConstructor;
|
|
26
31
|
label: (StringConstructor | NumberConstructor)[];
|
|
@@ -36,6 +41,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
36
41
|
type: StringConstructor;
|
|
37
42
|
default: undefined;
|
|
38
43
|
};
|
|
44
|
+
defaultTag: {
|
|
45
|
+
type: StringConstructor;
|
|
46
|
+
default: import("../../constants").ActionTag;
|
|
47
|
+
};
|
|
39
48
|
to: {
|
|
40
49
|
type: (ObjectConstructor | StringConstructor)[];
|
|
41
50
|
};
|
|
@@ -48,6 +57,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
48
57
|
type: StringConstructor;
|
|
49
58
|
default: string;
|
|
50
59
|
};
|
|
60
|
+
current: BooleanConstructor;
|
|
51
61
|
active: BooleanConstructor;
|
|
52
62
|
pressed: BooleanConstructor;
|
|
53
63
|
label: (StringConstructor | NumberConstructor)[];
|
|
@@ -56,7 +66,9 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
56
66
|
disabled: boolean;
|
|
57
67
|
type: "button" | "submit" | "reset";
|
|
58
68
|
ariaLabel: string;
|
|
69
|
+
defaultTag: string;
|
|
59
70
|
rel: string;
|
|
71
|
+
current: boolean;
|
|
60
72
|
active: boolean;
|
|
61
73
|
pressed: boolean;
|
|
62
74
|
}, {}>, {
|
|
@@ -43,24 +43,24 @@ export declare const VvDropdownProps: {
|
|
|
43
43
|
};
|
|
44
44
|
shift: {
|
|
45
45
|
type: PropType<boolean | {
|
|
46
|
-
mainAxis?: boolean | undefined;
|
|
47
|
-
crossAxis?: boolean | undefined;
|
|
48
46
|
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
49
47
|
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
50
48
|
altBoundary?: boolean | undefined;
|
|
51
|
-
padding?: import("@floating-ui/
|
|
49
|
+
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
50
|
+
crossAxis?: boolean | undefined;
|
|
51
|
+
mainAxis?: boolean | undefined;
|
|
52
52
|
limiter?: {
|
|
53
53
|
fn: (state: import("@floating-ui/core").MiddlewareState) => import("@floating-ui/core").Coords;
|
|
54
54
|
options?: any;
|
|
55
55
|
} | undefined;
|
|
56
56
|
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
57
57
|
} | import("@floating-ui/dom").Derivable<{
|
|
58
|
-
mainAxis?: boolean | undefined;
|
|
59
|
-
crossAxis?: boolean | undefined;
|
|
60
58
|
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
61
59
|
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
62
60
|
altBoundary?: boolean | undefined;
|
|
63
|
-
padding?: import("@floating-ui/
|
|
61
|
+
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
62
|
+
crossAxis?: boolean | undefined;
|
|
63
|
+
mainAxis?: boolean | undefined;
|
|
64
64
|
limiter?: {
|
|
65
65
|
fn: (state: import("@floating-ui/core").MiddlewareState) => import("@floating-ui/core").Coords;
|
|
66
66
|
options?: any;
|
|
@@ -71,25 +71,25 @@ export declare const VvDropdownProps: {
|
|
|
71
71
|
};
|
|
72
72
|
flip: {
|
|
73
73
|
type: PropType<boolean | {
|
|
74
|
-
mainAxis?: boolean | undefined;
|
|
75
|
-
crossAxis?: boolean | undefined;
|
|
76
74
|
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
77
75
|
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
78
76
|
altBoundary?: boolean | undefined;
|
|
79
|
-
padding?: import("@floating-ui/
|
|
80
|
-
|
|
77
|
+
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
78
|
+
crossAxis?: boolean | undefined;
|
|
79
|
+
mainAxis?: boolean | undefined;
|
|
80
|
+
fallbackPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
81
81
|
fallbackStrategy?: "initialPlacement" | "bestFit" | undefined;
|
|
82
82
|
fallbackAxisSideDirection?: "start" | "end" | "none" | undefined;
|
|
83
83
|
flipAlignment?: boolean | undefined;
|
|
84
84
|
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
85
85
|
} | import("@floating-ui/dom").Derivable<{
|
|
86
|
-
mainAxis?: boolean | undefined;
|
|
87
|
-
crossAxis?: boolean | undefined;
|
|
88
86
|
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
89
87
|
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
90
88
|
altBoundary?: boolean | undefined;
|
|
91
|
-
padding?: import("@floating-ui/
|
|
92
|
-
|
|
89
|
+
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
90
|
+
crossAxis?: boolean | undefined;
|
|
91
|
+
mainAxis?: boolean | undefined;
|
|
92
|
+
fallbackPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
93
93
|
fallbackStrategy?: "initialPlacement" | "bestFit" | undefined;
|
|
94
94
|
fallbackAxisSideDirection?: "start" | "end" | "none" | undefined;
|
|
95
95
|
flipAlignment?: boolean | undefined;
|
|
@@ -102,16 +102,16 @@ export declare const VvDropdownProps: {
|
|
|
102
102
|
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
103
103
|
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
104
104
|
altBoundary?: boolean | undefined;
|
|
105
|
-
padding?: import("@floating-ui/
|
|
105
|
+
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
106
106
|
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
107
107
|
apply?: ((args: {
|
|
108
108
|
x: number;
|
|
109
109
|
y: number;
|
|
110
|
-
initialPlacement: import("@floating-ui/
|
|
111
|
-
placement: import("@floating-ui/
|
|
112
|
-
strategy: import("@floating-ui/
|
|
110
|
+
initialPlacement: import("@floating-ui/utils").Placement;
|
|
111
|
+
placement: import("@floating-ui/utils").Placement;
|
|
112
|
+
strategy: import("@floating-ui/utils").Strategy;
|
|
113
113
|
middlewareData: import("@floating-ui/core").MiddlewareData;
|
|
114
|
-
rects: import("@floating-ui/
|
|
114
|
+
rects: import("@floating-ui/utils").ElementRects;
|
|
115
115
|
platform: import("@floating-ui/core").Platform;
|
|
116
116
|
elements: import("@floating-ui/dom").Elements;
|
|
117
117
|
} & {
|
|
@@ -122,16 +122,16 @@ export declare const VvDropdownProps: {
|
|
|
122
122
|
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
123
123
|
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
124
124
|
altBoundary?: boolean | undefined;
|
|
125
|
-
padding?: import("@floating-ui/
|
|
125
|
+
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
126
126
|
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
127
127
|
apply?: ((args: {
|
|
128
128
|
x: number;
|
|
129
129
|
y: number;
|
|
130
|
-
initialPlacement: import("@floating-ui/
|
|
131
|
-
placement: import("@floating-ui/
|
|
132
|
-
strategy: import("@floating-ui/
|
|
130
|
+
initialPlacement: import("@floating-ui/utils").Placement;
|
|
131
|
+
placement: import("@floating-ui/utils").Placement;
|
|
132
|
+
strategy: import("@floating-ui/utils").Strategy;
|
|
133
133
|
middlewareData: import("@floating-ui/core").MiddlewareData;
|
|
134
|
-
rects: import("@floating-ui/
|
|
134
|
+
rects: import("@floating-ui/utils").ElementRects;
|
|
135
135
|
platform: import("@floating-ui/core").Platform;
|
|
136
136
|
elements: import("@floating-ui/dom").Elements;
|
|
137
137
|
} & {
|
|
@@ -145,24 +145,24 @@ export declare const VvDropdownProps: {
|
|
|
145
145
|
};
|
|
146
146
|
autoPlacement: {
|
|
147
147
|
type: PropType<boolean | {
|
|
148
|
-
crossAxis?: boolean | undefined;
|
|
149
148
|
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
150
149
|
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
151
150
|
altBoundary?: boolean | undefined;
|
|
152
|
-
padding?: import("@floating-ui/
|
|
153
|
-
|
|
151
|
+
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
152
|
+
crossAxis?: boolean | undefined;
|
|
153
|
+
alignment?: import("@floating-ui/utils").Alignment | null | undefined;
|
|
154
154
|
autoAlignment?: boolean | undefined;
|
|
155
|
-
allowedPlacements?: import("@floating-ui/
|
|
155
|
+
allowedPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
156
156
|
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
157
157
|
} | import("@floating-ui/dom").Derivable<{
|
|
158
|
-
crossAxis?: boolean | undefined;
|
|
159
158
|
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
160
159
|
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
161
160
|
altBoundary?: boolean | undefined;
|
|
162
|
-
padding?: import("@floating-ui/
|
|
163
|
-
|
|
161
|
+
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
162
|
+
crossAxis?: boolean | undefined;
|
|
163
|
+
alignment?: import("@floating-ui/utils").Alignment | null | undefined;
|
|
164
164
|
autoAlignment?: boolean | undefined;
|
|
165
|
-
allowedPlacements?: import("@floating-ui/
|
|
165
|
+
allowedPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
166
166
|
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
167
167
|
}> | undefined>;
|
|
168
168
|
default: boolean;
|
|
@@ -104,6 +104,12 @@ const ActiveProps = {
|
|
|
104
104
|
*/
|
|
105
105
|
active: Boolean
|
|
106
106
|
};
|
|
107
|
+
const CurrentProps = {
|
|
108
|
+
/**
|
|
109
|
+
* Whether the item is current
|
|
110
|
+
*/
|
|
111
|
+
current: Boolean
|
|
112
|
+
};
|
|
107
113
|
const PressedProps = {
|
|
108
114
|
/**
|
|
109
115
|
* Whether the item is pressed
|
|
@@ -234,6 +240,7 @@ const ActionProps = {
|
|
|
234
240
|
...LabelProps,
|
|
235
241
|
...PressedProps,
|
|
236
242
|
...ActiveProps,
|
|
243
|
+
...CurrentProps,
|
|
237
244
|
...LinkProps,
|
|
238
245
|
/**
|
|
239
246
|
* Button type
|
|
@@ -249,6 +256,13 @@ const ActionProps = {
|
|
|
249
256
|
ariaLabel: {
|
|
250
257
|
type: String,
|
|
251
258
|
default: void 0
|
|
259
|
+
},
|
|
260
|
+
/**
|
|
261
|
+
* Default tag for the action
|
|
262
|
+
*/
|
|
263
|
+
defaultTag: {
|
|
264
|
+
type: String,
|
|
265
|
+
default: ActionTag.button
|
|
252
266
|
}
|
|
253
267
|
};
|
|
254
268
|
const VvActionEvents = ["click", "mouseover", "mouseleave"];
|
|
@@ -304,7 +318,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
304
318
|
case props.href !== void 0:
|
|
305
319
|
return ActionTag.a;
|
|
306
320
|
default:
|
|
307
|
-
return
|
|
321
|
+
return props.defaultTag;
|
|
308
322
|
}
|
|
309
323
|
});
|
|
310
324
|
const hasProps = computed(() => {
|
|
@@ -329,12 +343,14 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
329
343
|
to: props.to,
|
|
330
344
|
target: props.target
|
|
331
345
|
};
|
|
332
|
-
|
|
346
|
+
case ActionTag.button:
|
|
333
347
|
return {
|
|
334
348
|
...toReturn,
|
|
335
349
|
type: props.type,
|
|
336
350
|
disabled: props.disabled
|
|
337
351
|
};
|
|
352
|
+
default:
|
|
353
|
+
return toReturn;
|
|
338
354
|
}
|
|
339
355
|
});
|
|
340
356
|
const onClick = (e) => {
|
|
@@ -360,7 +376,8 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
360
376
|
class: {
|
|
361
377
|
active: _ctx.active,
|
|
362
378
|
pressed: unref(pressed),
|
|
363
|
-
disabled: _ctx.disabled
|
|
379
|
+
disabled: _ctx.disabled,
|
|
380
|
+
current: _ctx.current
|
|
364
381
|
},
|
|
365
382
|
onClickPassive: onClick,
|
|
366
383
|
onMouseoverPassive: onMouseover,
|
|
@@ -368,10 +385,15 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
368
385
|
}), {
|
|
369
386
|
default: withCtx(() => [
|
|
370
387
|
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
371
|
-
createTextVNode(
|
|
388
|
+
createTextVNode(
|
|
389
|
+
toDisplayString(_ctx.label),
|
|
390
|
+
1
|
|
391
|
+
/* TEXT */
|
|
392
|
+
)
|
|
372
393
|
])
|
|
373
394
|
]),
|
|
374
395
|
_: 3
|
|
396
|
+
/* FORWARDED */
|
|
375
397
|
}, 16, ["class"]);
|
|
376
398
|
};
|
|
377
399
|
}
|
|
@@ -402,13 +424,19 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
402
424
|
}
|
|
403
425
|
});
|
|
404
426
|
return (_ctx, _cache) => {
|
|
405
|
-
return openBlock(), createElementBlock(
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
427
|
+
return openBlock(), createElementBlock(
|
|
428
|
+
"div",
|
|
429
|
+
mergeProps({ role: unref(role) }, {
|
|
430
|
+
ref_key: "element",
|
|
431
|
+
ref: element,
|
|
432
|
+
class: ["vv-dropdown__item", { "focus-visible": unref(focused) || unref(focusedWithin) }]
|
|
433
|
+
}),
|
|
434
|
+
[
|
|
435
|
+
renderSlot(_ctx.$slots, "default")
|
|
436
|
+
],
|
|
437
|
+
16
|
|
438
|
+
/* FULL_PROPS */
|
|
439
|
+
);
|
|
412
440
|
};
|
|
413
441
|
}
|
|
414
442
|
});
|
|
@@ -463,13 +491,19 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
463
491
|
}, { class: unref(bemCssClasses) }), {
|
|
464
492
|
default: withCtx(() => [
|
|
465
493
|
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
466
|
-
createTextVNode(
|
|
494
|
+
createTextVNode(
|
|
495
|
+
toDisplayString(_ctx.label),
|
|
496
|
+
1
|
|
497
|
+
/* TEXT */
|
|
498
|
+
)
|
|
467
499
|
])
|
|
468
500
|
]),
|
|
469
501
|
_: 3
|
|
502
|
+
/* FORWARDED */
|
|
470
503
|
}, 16, ["class"])
|
|
471
504
|
]),
|
|
472
505
|
_: 3
|
|
506
|
+
/* FORWARDED */
|
|
473
507
|
});
|
|
474
508
|
};
|
|
475
509
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("vue"),require("mitt"),require("@vueuse/core")):"function"==typeof define&&define.amd?define(["vue","mitt","@vueuse/core"],t):(e="undefined"!=typeof globalThis?globalThis:e||self).VvDropdownAction=t(e.vue,null,e.core)}(this,(function(e,t,o){"use strict";var r=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(r||{}),n=(e=>(e.before="before",e.after="after",e))(n||{}),l=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(l||{}),a=(e=>(e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e))(a||{}),u=(e=>(e.button="button",e.link="link",e.menuitem="menuitem",e))(u||{}),i=(e=>(e._blank="_blank",e._self="_self",e._parent="_parent",e._top="_top",e))(i||{});const s=Symbol.for("volver"),d=Symbol.for("dropdownTrigger"),c=Symbol.for("dropdownItem"),f=Symbol.for("dropdownAction"),p={to:{type:[String,Object]},href:String,target:{type:String,validator:e=>Object.values(i).includes(e)},rel:{type:String,default:"noopener noreferrer"}},v={disabled:Boolean},m={active:Boolean},b={pressed:Boolean},y={label:[String,Number]},
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("vue"),require("mitt"),require("@vueuse/core")):"function"==typeof define&&define.amd?define(["vue","mitt","@vueuse/core"],t):(e="undefined"!=typeof globalThis?globalThis:e||self).VvDropdownAction=t(e.vue,null,e.core)}(this,(function(e,t,o){"use strict";var r=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(r||{}),n=(e=>(e.before="before",e.after="after",e))(n||{}),l=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(l||{}),a=(e=>(e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e))(a||{}),u=(e=>(e.button="button",e.link="link",e.menuitem="menuitem",e))(u||{}),i=(e=>(e._blank="_blank",e._self="_self",e._parent="_parent",e._top="_top",e))(i||{});const s=Symbol.for("volver"),d=Symbol.for("dropdownTrigger"),c=Symbol.for("dropdownItem"),f=Symbol.for("dropdownAction"),p={to:{type:[String,Object]},href:String,target:{type:String,validator:e=>Object.values(i).includes(e)},rel:{type:String,default:"noopener noreferrer"}},v={disabled:Boolean},m={active:Boolean},b={current:Boolean},g={pressed:Boolean},y={label:[String,Number]},k={modifiers:[String,Array]};n.before,r.bottom,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean;const h={...v,...y,...g,...m,...b,...p,type:{type:String,default:l.button,validator:e=>Object.values(l).includes(e)},ariaLabel:{type:String,default:void 0},defaultTag:{type:String,default:a.button}},x=h;const B=e.defineComponent({name:"VvAction",props:x,emits:["click","mouseover","mouseleave"],setup(t,{expose:o,emit:r}){const n=t,l=e.inject(s),u=e.ref(null);o({$el:u});const{reference:i,bus:c,aria:p,expanded:v}=e.inject(d,{});e.watch((()=>u.value),(e=>{i&&(i.value=e)}));const m=e.computed((()=>n.pressed||(null==v?void 0:v.value))),{role:b}=e.inject(f,{}),g=e.computed((()=>{switch(!0){case n.disabled:return a.button;case void 0!==n.to:return(null==l?void 0:l.nuxt)?a.nuxtLink:a.routerLink;case void 0!==n.href:return a.a;default:return n.defaultTag}})),y=e.computed((()=>{const e={...null==p?void 0:p.value,ariaPressed:!!m.value||void 0,ariaLabel:n.ariaLabel,role:null==b?void 0:b.value};switch(g.value){case a.a:return{...e,href:n.href,target:n.target,rel:n.rel};case a.routerLink:case a.nuxtLink:return{...e,to:n.to,target:n.target};case a.button:return{...e,type:n.type,disabled:n.disabled};default:return e}})),k=e=>{n.disabled?e.preventDefault():(null==c||c.emit("click",e),r("click",e))},h=e=>{null==c||c.emit("mouseover",e),r("mouseover",e)},x=e=>{null==c||c.emit("mouseleave",e),r("mouseleave",e)};return(t,o)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(g)),e.mergeProps(e.unref(y),{ref_key:"element",ref:u,class:{active:t.active,pressed:e.unref(m),disabled:t.disabled,current:t.current},onClickPassive:k,onMouseoverPassive:h,onMouseleavePassive:x}),{default:e.withCtx((()=>[e.renderSlot(t.$slots,"default",{},(()=>[e.createTextVNode(e.toDisplayString(t.label),1)]))])),_:3},16,["class"]))}});const S=e.defineComponent({name:"VvDropdownItem",setup(t){const{role:r,expanded:n}=e.inject(c,{}),l=e.ref(null);!function({expanded:t}){e.provide(f,{role:e.ref(u.menuitem),expanded:t})}({expanded:n});const a=o.useElementHover(l),{focused:i}=o.useFocus(l),{focused:s}=o.useFocusWithin(l);return e.watch(a,(e=>{e&&(i.value=!0)})),(t,o)=>(e.openBlock(),e.createElementBlock("div",e.mergeProps({role:e.unref(r)},{ref_key:"element",ref:l,class:["vv-dropdown__item",{"focus-visible":e.unref(i)||e.unref(s)}]}),[e.renderSlot(t.$slots,"default")],16))}});return e.defineComponent({name:"VvDropdownAction",props:{...h,...k},setup(t){const o=t,{modifiers:r}=e.toRefs(o),n=function(t,o,r){return e.computed((()=>{const n={[t]:!0},l="string"==typeof(null==o?void 0:o.value)?o.value.split(" "):null==o?void 0:o.value;return l&&Array.isArray(l)&&l.forEach((e=>{e&&(n[`${t}--${e}`]=!0)})),r&&Object.keys(r.value).forEach((o=>{n[`${t}--${o}`]=e.unref(r.value[o])})),n}))}("vv-dropdown-action",r);return(t,o)=>(e.openBlock(),e.createBlock(S,null,{default:e.withCtx((()=>[e.createVNode(B,e.mergeProps({disabled:t.disabled,pressed:t.pressed,active:t.active,type:t.type,to:t.to,href:t.href,target:t.target,rel:t.rel},{class:e.unref(n)}),{default:e.withCtx((()=>[e.renderSlot(t.$slots,"default",{},(()=>[e.createTextVNode(e.toDisplayString(t.label),1)]))])),_:3},16,["class"])])),_:3}))}})}));
|
|
@@ -42,13 +42,19 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
42
42
|
}
|
|
43
43
|
});
|
|
44
44
|
return (_ctx, _cache) => {
|
|
45
|
-
return openBlock(), createElementBlock(
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
45
|
+
return openBlock(), createElementBlock(
|
|
46
|
+
"div",
|
|
47
|
+
mergeProps({ role: unref(role) }, {
|
|
48
|
+
ref_key: "element",
|
|
49
|
+
ref: element,
|
|
50
|
+
class: ["vv-dropdown__item", { "focus-visible": unref(focused) || unref(focusedWithin) }]
|
|
51
|
+
}),
|
|
52
|
+
[
|
|
53
|
+
renderSlot(_ctx.$slots, "default")
|
|
54
|
+
],
|
|
55
|
+
16
|
|
56
|
+
/* FULL_PROPS */
|
|
57
|
+
);
|
|
52
58
|
};
|
|
53
59
|
}
|
|
54
60
|
});
|
|
@@ -33,6 +33,13 @@ var ButtonType = /* @__PURE__ */ ((ButtonType2) => {
|
|
|
33
33
|
ButtonType2["reset"] = "reset";
|
|
34
34
|
return ButtonType2;
|
|
35
35
|
})(ButtonType || {});
|
|
36
|
+
var ActionTag = /* @__PURE__ */ ((ActionTag2) => {
|
|
37
|
+
ActionTag2["nuxtLink"] = "nuxt-link";
|
|
38
|
+
ActionTag2["routerLink"] = "router-link";
|
|
39
|
+
ActionTag2["a"] = "a";
|
|
40
|
+
ActionTag2["button"] = "button";
|
|
41
|
+
return ActionTag2;
|
|
42
|
+
})(ActionTag || {});
|
|
36
43
|
var AnchorTarget = /* @__PURE__ */ ((AnchorTarget2) => {
|
|
37
44
|
AnchorTarget2["_blank"] = "_blank";
|
|
38
45
|
AnchorTarget2["_self"] = "_self";
|
|
@@ -79,6 +86,12 @@ const ActiveProps = {
|
|
|
79
86
|
*/
|
|
80
87
|
active: Boolean
|
|
81
88
|
};
|
|
89
|
+
const CurrentProps = {
|
|
90
|
+
/**
|
|
91
|
+
* Whether the item is current
|
|
92
|
+
*/
|
|
93
|
+
current: Boolean
|
|
94
|
+
};
|
|
82
95
|
const PressedProps = {
|
|
83
96
|
/**
|
|
84
97
|
* Whether the item is pressed
|
|
@@ -203,6 +216,7 @@ const LabelProps = {
|
|
|
203
216
|
...LabelProps,
|
|
204
217
|
...PressedProps,
|
|
205
218
|
...ActiveProps,
|
|
219
|
+
...CurrentProps,
|
|
206
220
|
...LinkProps,
|
|
207
221
|
/**
|
|
208
222
|
* Button type
|
|
@@ -218,6 +232,13 @@ const LabelProps = {
|
|
|
218
232
|
ariaLabel: {
|
|
219
233
|
type: String,
|
|
220
234
|
default: void 0
|
|
235
|
+
},
|
|
236
|
+
/**
|
|
237
|
+
* Default tag for the action
|
|
238
|
+
*/
|
|
239
|
+
defaultTag: {
|
|
240
|
+
type: String,
|
|
241
|
+
default: ActionTag.button
|
|
221
242
|
}
|
|
222
243
|
});
|
|
223
244
|
const _hoisted_1 = {
|
|
@@ -236,7 +257,13 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
236
257
|
setup(__props) {
|
|
237
258
|
const props = __props;
|
|
238
259
|
return (_ctx, _cache) => {
|
|
239
|
-
return openBlock(), createElementBlock(
|
|
260
|
+
return openBlock(), createElementBlock(
|
|
261
|
+
"li",
|
|
262
|
+
_hoisted_1,
|
|
263
|
+
toDisplayString(props.label),
|
|
264
|
+
1
|
|
265
|
+
/* TEXT */
|
|
266
|
+
);
|
|
240
267
|
};
|
|
241
268
|
}
|
|
242
269
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(o,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("vue")):"function"==typeof define&&define.amd?define(["vue"],e):(o="undefined"!=typeof globalThis?globalThis:o||self).VvDropdownOptgroup=e(o.vue)}(this,(function(o){"use strict";var e=(o=>(o.left="left",o.right="right",o.top="top",o.bottom="bottom",o))(e||{}),t=(o=>(o.before="before",o.after="after",o))(t||{}),n=(o=>(o.button="button",o.submit="submit",o.reset="reset",o))(n||{});Boolean,Boolean,Boolean;const
|
|
1
|
+
!function(o,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("vue")):"function"==typeof define&&define.amd?define(["vue"],e):(o="undefined"!=typeof globalThis?globalThis:o||self).VvDropdownOptgroup=e(o.vue)}(this,(function(o){"use strict";var e=(o=>(o.left="left",o.right="right",o.top="top",o.bottom="bottom",o))(e||{}),t=(o=>(o.before="before",o.after="after",o))(t||{}),n=(o=>(o.button="button",o.submit="submit",o.reset="reset",o))(n||{}),r=(o=>(o.nuxtLink="nuxt-link",o.routerLink="router-link",o.a="a",o.button="button",o))(r||{});Boolean,Boolean,Boolean,Boolean;const l={label:[String,Number]};t.before,e.bottom,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,n.button,r.button;const u={class:"vv-dropdown-optgroup",role:"presentation",tabindex:"-1"};return o.defineComponent({name:"VvDropdownOptgroup",props:{...l},setup(e){const t=e;return(e,n)=>(o.openBlock(),o.createElementBlock("li",u,o.toDisplayString(t.label),1))}})}));
|
|
@@ -35,6 +35,13 @@ var ButtonType = /* @__PURE__ */ ((ButtonType2) => {
|
|
|
35
35
|
ButtonType2["reset"] = "reset";
|
|
36
36
|
return ButtonType2;
|
|
37
37
|
})(ButtonType || {});
|
|
38
|
+
var ActionTag = /* @__PURE__ */ ((ActionTag2) => {
|
|
39
|
+
ActionTag2["nuxtLink"] = "nuxt-link";
|
|
40
|
+
ActionTag2["routerLink"] = "router-link";
|
|
41
|
+
ActionTag2["a"] = "a";
|
|
42
|
+
ActionTag2["button"] = "button";
|
|
43
|
+
return ActionTag2;
|
|
44
|
+
})(ActionTag || {});
|
|
38
45
|
var ActionRoles = /* @__PURE__ */ ((ActionRoles2) => {
|
|
39
46
|
ActionRoles2["button"] = "button";
|
|
40
47
|
ActionRoles2["link"] = "link";
|
|
@@ -83,13 +90,19 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
83
90
|
}
|
|
84
91
|
});
|
|
85
92
|
return (_ctx, _cache) => {
|
|
86
|
-
return openBlock(), createElementBlock(
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
+
return openBlock(), createElementBlock(
|
|
94
|
+
"div",
|
|
95
|
+
mergeProps({ role: unref(role) }, {
|
|
96
|
+
ref_key: "element",
|
|
97
|
+
ref: element,
|
|
98
|
+
class: ["vv-dropdown__item", { "focus-visible": unref(focused) || unref(focusedWithin) }]
|
|
99
|
+
}),
|
|
100
|
+
[
|
|
101
|
+
renderSlot(_ctx.$slots, "default")
|
|
102
|
+
],
|
|
103
|
+
16
|
|
104
|
+
/* FULL_PROPS */
|
|
105
|
+
);
|
|
93
106
|
};
|
|
94
107
|
}
|
|
95
108
|
});
|
|
@@ -138,6 +151,12 @@ const ActiveProps = {
|
|
|
138
151
|
*/
|
|
139
152
|
active: Boolean
|
|
140
153
|
};
|
|
154
|
+
const CurrentProps = {
|
|
155
|
+
/**
|
|
156
|
+
* Whether the item is current
|
|
157
|
+
*/
|
|
158
|
+
current: Boolean
|
|
159
|
+
};
|
|
141
160
|
const PressedProps = {
|
|
142
161
|
/**
|
|
143
162
|
* Whether the item is pressed
|
|
@@ -274,6 +293,7 @@ const UnselectableProps = {
|
|
|
274
293
|
...LabelProps,
|
|
275
294
|
...PressedProps,
|
|
276
295
|
...ActiveProps,
|
|
296
|
+
...CurrentProps,
|
|
277
297
|
...LinkProps,
|
|
278
298
|
/**
|
|
279
299
|
* Button type
|
|
@@ -289,6 +309,13 @@ const UnselectableProps = {
|
|
|
289
309
|
ariaLabel: {
|
|
290
310
|
type: String,
|
|
291
311
|
default: void 0
|
|
312
|
+
},
|
|
313
|
+
/**
|
|
314
|
+
* Default tag for the action
|
|
315
|
+
*/
|
|
316
|
+
defaultTag: {
|
|
317
|
+
type: String,
|
|
318
|
+
default: ActionTag.button
|
|
292
319
|
}
|
|
293
320
|
});
|
|
294
321
|
function useModifiers(prefix, modifiers, others) {
|
|
@@ -369,11 +396,16 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
369
396
|
title: unref(hintLabel)
|
|
370
397
|
}, [
|
|
371
398
|
renderSlot(_ctx.$slots, "hint", normalizeProps(guardReactiveProps({ disabled: _ctx.disabled, selected: _ctx.selected, unselectable: _ctx.unselectable })), () => [
|
|
372
|
-
createTextVNode(
|
|
399
|
+
createTextVNode(
|
|
400
|
+
toDisplayString(unref(hintLabel)),
|
|
401
|
+
1
|
|
402
|
+
/* TEXT */
|
|
403
|
+
)
|
|
373
404
|
])
|
|
374
405
|
], 8, _hoisted_1)
|
|
375
406
|
]),
|
|
376
407
|
_: 3
|
|
408
|
+
/* FORWARDED */
|
|
377
409
|
}, 8, ["class", "tabindex", "aria-selected", "aria-disabled"]);
|
|
378
410
|
};
|
|
379
411
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("vue"),require("mitt"),require("@vueuse/core")):"function"==typeof define&&define.amd?define(["vue","mitt","@vueuse/core"],t):(e="undefined"!=typeof globalThis?globalThis:e||self).VvDropdownOption=t(e.vue,null,e.core)}(this,(function(e,t,o){"use strict";var n=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(n||{}),l=(e=>(e.before="before",e.after="after",e))(l||{}),r=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(r||{}),s=(e=>(e.button="button",e.link="link",e.menuitem="menuitem",e))(
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("vue"),require("mitt"),require("@vueuse/core")):"function"==typeof define&&define.amd?define(["vue","mitt","@vueuse/core"],t):(e="undefined"!=typeof globalThis?globalThis:e||self).VvDropdownOption=t(e.vue,null,e.core)}(this,(function(e,t,o){"use strict";var n=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(n||{}),l=(e=>(e.before="before",e.after="after",e))(l||{}),r=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(r||{}),s=(e=>(e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e))(s||{}),i=(e=>(e.button="button",e.link="link",e.menuitem="menuitem",e))(i||{});const a=Symbol.for("dropdownItem"),d=Symbol.for("dropdownAction");const u=e.defineComponent({name:"VvDropdownItem",setup(t){const{role:n,expanded:l}=e.inject(a,{}),r=e.ref(null);!function({expanded:t}){e.provide(d,{role:e.ref(i.menuitem),expanded:t})}({expanded:l});const s=o.useElementHover(r),{focused:u}=o.useFocus(r),{focused:c}=o.useFocusWithin(r);return e.watch(s,(e=>{e&&(u.value=!0)})),(t,o)=>(e.openBlock(),e.createElementBlock("div",e.mergeProps({role:e.unref(n)},{ref_key:"element",ref:r,class:["vv-dropdown__item",{"focus-visible":e.unref(u)||e.unref(c)}]}),[e.renderSlot(t.$slots,"default")],16))}}),c={disabled:Boolean},f={selected:Boolean},b=(Boolean,Boolean,Boolean,{modifiers:[String,Array]});l.before;const p={unselectable:{type:Boolean,default:!0}};n.bottom,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,r.button,s.button;const m=["title"];return e.defineComponent({name:"VvDropdownOption",props:{...c,...f,...p,...b,deselectHintLabel:{type:String},selectHintLabel:{type:String},selectedHintLabel:{type:String}},setup(t){const o=t,{modifiers:n}=e.toRefs(o),l=function(t,o,n){return e.computed((()=>{const l={[t]:!0},r="string"==typeof(null==o?void 0:o.value)?o.value.split(" "):null==o?void 0:o.value;return r&&Array.isArray(r)&&r.forEach((e=>{e&&(l[`${t}--${e}`]=!0)})),n&&Object.keys(n.value).forEach((o=>{l[`${t}--${o}`]=e.unref(n.value[o])})),l}))}("vv-dropdown-option",n,e.computed((()=>({disabled:o.disabled,selected:o.selected,unselectable:o.unselectable&&o.selected})))),r=e.computed((()=>o.selected?o.unselectable?o.deselectHintLabel:o.selectedHintLabel:o.disabled?void 0:o.selectHintLabel));return(t,o)=>(e.openBlock(),e.createBlock(u,{class:e.normalizeClass(e.unref(l)),tabindex:t.disabled?-1:0,"aria-selected":t.selected,"aria-disabled":t.disabled},{default:e.withCtx((()=>[e.renderSlot(t.$slots,"default"),e.createElementVNode("span",{class:"vv-dropdown-option__hint",title:e.unref(r)},[e.renderSlot(t.$slots,"hint",e.normalizeProps(e.guardReactiveProps({disabled:t.disabled,selected:t.selected,unselectable:t.unselectable})),(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)),1)]))],8,m)])),_:3},8,["class","tabindex","aria-selected","aria-disabled"]))}})}));
|
|
@@ -213,7 +213,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
213
213
|
color: _ctx.color,
|
|
214
214
|
onLoad: _ctx.onLoad,
|
|
215
215
|
icon: unref(icon)
|
|
216
|
-
}), null, 16, ["class"])) : createCommentVNode("", true);
|
|
216
|
+
}), null, 16, ["class"])) : createCommentVNode("v-if", true);
|
|
217
217
|
};
|
|
218
218
|
}
|
|
219
219
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n(require("vue"),require("@iconify/vue")):"function"==typeof define&&define.amd?define(["vue","@iconify/vue"],n):(e="undefined"!=typeof globalThis?globalThis:e||self).VvIcon=n(e.vue,e.vue$1)}(this,(function(e,n){"use strict";const o={color:String,width:{type:[String,Number]},height:{type:[String,Number]},name:{type:String,required:!0},provider:{type:String},prefix:{type:String,default:"normal"},src:String,horizontalFlip:Boolean,verticalFlip:Boolean,flip:String,mode:String,inline:Boolean,rotate:[Number,String],onLoad:Function,svg:String,modifiers:{type:[String,Array]}},
|
|
1
|
+
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n(require("vue"),require("@iconify/vue")):"function"==typeof define&&define.amd?define(["vue","@iconify/vue"],n):(e="undefined"!=typeof globalThis?globalThis:e||self).VvIcon=n(e.vue,e.vue$1)}(this,(function(e,n){"use strict";const o={color:String,width:{type:[String,Number]},height:{type:[String,Number]},name:{type:String,required:!0},provider:{type:String},prefix:{type:String,default:"normal"},src:String,horizontalFlip:Boolean,verticalFlip:Boolean,flip:String,mode:String,inline:Boolean,rotate:[Number,String],onLoad:Function,svg:String,modifiers:{type:[String,Array]}},i=Symbol.for("volver");return e.defineComponent({name:"VvIcon",props:o,setup(o){const r=o,t=e.computed((()=>"string"==typeof r.rotate?parseFloat(r.rotate):r.rotate)),l=e.ref(!0),u=e.inject(i),{modifiers:c}=e.toRefs(r),a=function(n,o,i){return e.computed((()=>{const r={[n]:!0},t="string"==typeof(null==o?void 0:o.value)?o.value.split(" "):null==o?void 0:o.value;return t&&Array.isArray(t)&&t.forEach((e=>{e&&(r[`${n}--${e}`]=!0)})),i&&Object.keys(i.value).forEach((o=>{r[`${n}--${o}`]=e.unref(i.value[o])})),r}))}("vv-icon",c),s=e.computed((()=>r.provider||(null==u?void 0:u.iconsProvider))),f=e.computed((()=>{const e=r.name??"",o=`@${s.value}:${r.prefix}:${e}`;if(n.iconExists(o))return o;const i=null==u?void 0:u.iconsCollections.find((o=>{const i=`@${s.value}:${o.prefix}:${e}`;return n.iconExists(i)}));return i?`@${s.value}:${i.prefix}:${e}`:e}));function d(e){const o=function(e){let n;if("undefined"==typeof window){const{JSDOM:e}=require("jsdom");n=(new e).window}return(n?new n.DOMParser:new window.DOMParser).parseFromString(e,"text/html").querySelector("svg")}(e),i=(null==o?void 0:o.innerHTML.trim())||"";o&&i&&n.addIcon(`@${s.value}:${r.prefix}:${r.name}`,{body:i,height:o.viewBox.baseVal.height,width:o.viewBox.baseVal.width})}return u&&r.src&&!n.iconExists(`@${s.value}:${r.prefix}:${r.name}`)&&(l.value=!1,u.fetchIcon(r.src).then((e=>{e&&(d(e),l.value=!0)})).catch((e=>{throw new Error(`Error during fetch icon: ${null==e?void 0:e.message}`)}))),r.svg&&d(r.svg),(o,i)=>e.unref(l)?(e.openBlock(),e.createBlock(e.unref(n.Icon),e.mergeProps({key:0,class:e.unref(a)},{inline:o.inline,width:o.width,height:o.height,horizontalFlip:o.horizontalFlip,verticalFlip:o.verticalFlip,flip:o.flip,rotate:e.unref(t),color:o.color,onLoad:o.onLoad,icon:e.unref(f)}),null,16,["class"])):e.createCommentVNode("v-if",!0)}})}));
|