@volverjs/ui-vue 0.0.10-beta.3 → 0.0.10-beta.30
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/LICENSE +1 -1
- package/README.md +106 -10
- package/auto-imports.d.ts +7 -2
- package/bin/icons.cjs +1 -1
- package/bin/icons.js +22 -15
- package/dist/.storybook/main.d.ts +3 -0
- package/dist/.storybook/preview.d.ts +89 -0
- package/dist/components/VvAccordion/VvAccordion.es.js +192 -103
- package/dist/components/VvAccordion/VvAccordion.umd.js +1 -1
- package/dist/components/VvAccordionGroup/VvAccordionGroup.es.js +451 -172
- package/dist/components/VvAccordionGroup/VvAccordionGroup.umd.js +1 -1
- package/dist/components/VvAction/VvAction.es.js +78 -27
- package/dist/components/VvAction/VvAction.umd.js +1 -1
- package/dist/components/VvAlert/VvAlert.es.js +204 -171
- package/dist/components/VvAlert/VvAlert.umd.js +1 -1
- package/dist/components/VvAlertGroup/VvAlertGroup.es.js +250 -188
- package/dist/components/VvAlertGroup/VvAlertGroup.umd.js +1 -1
- package/dist/components/VvAvatar/VvAvatar.es.js +61 -21
- package/dist/components/VvAvatar/VvAvatar.umd.js +1 -1
- package/dist/components/VvAvatarGroup/VvAvatarGroup.es.js +118 -48
- package/dist/components/VvAvatarGroup/VvAvatarGroup.umd.js +1 -1
- package/dist/components/VvBadge/VvBadge.es.js +78 -28
- package/dist/components/VvBadge/VvBadge.umd.js +1 -1
- package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +276 -60
- package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
- package/dist/components/VvButton/VvButton.es.js +291 -252
- package/dist/components/VvButton/VvButton.umd.js +1 -1
- package/dist/components/VvButtonGroup/VvButtonGroup.es.js +81 -40
- package/dist/components/VvButtonGroup/VvButtonGroup.umd.js +1 -1
- package/dist/components/VvCard/VvCard.es.js +86 -36
- package/dist/components/VvCard/VvCard.umd.js +1 -1
- package/dist/components/VvCheckbox/VvCheckbox.es.js +177 -120
- package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -1
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +190 -107
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -1
- package/dist/components/VvCombobox/VvCombobox.es.js +806 -581
- package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
- package/dist/components/VvDialog/VvDialog.es.js +140 -153
- package/dist/components/VvDialog/VvDialog.umd.js +1 -1
- package/dist/components/VvDropdown/VvDropdown.es.js +138 -71
- package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
- package/dist/components/VvDropdownAction/VvDropdownAction.es.js +152 -39
- package/dist/components/VvDropdownAction/VvDropdownAction.umd.js +1 -1
- package/dist/components/VvDropdownItem/VvDropdownItem.es.js +335 -8
- package/dist/components/VvDropdownItem/VvDropdownItem.umd.js +1 -1
- package/dist/components/VvDropdownOptgroup/VvDropdownOptgroup.es.js +63 -20
- package/dist/components/VvDropdownOptgroup/VvDropdownOptgroup.umd.js +1 -1
- package/dist/components/VvDropdownOption/VvDropdownOption.es.js +188 -80
- package/dist/components/VvDropdownOption/VvDropdownOption.umd.js +1 -1
- package/dist/components/VvIcon/VvIcon.es.js +23 -96
- package/dist/components/VvIcon/VvIcon.umd.js +1 -1
- package/dist/components/VvInputFile/VvInputFile.es.js +1777 -0
- package/dist/components/VvInputFile/VvInputFile.umd.js +1 -0
- package/dist/components/VvInputText/VvInputText.es.js +1237 -324
- package/dist/components/VvInputText/VvInputText.umd.js +1 -1
- package/dist/components/VvNav/VvNav.es.js +135 -56
- package/dist/components/VvNav/VvNav.umd.js +1 -1
- package/dist/components/VvNavItem/VvNavItem.es.js +91 -33
- package/dist/components/VvNavItem/VvNavItem.umd.js +1 -1
- package/dist/components/VvProgress/VvProgress.es.js +72 -26
- package/dist/components/VvProgress/VvProgress.umd.js +1 -1
- package/dist/components/VvRadio/VvRadio.es.js +160 -103
- package/dist/components/VvRadio/VvRadio.umd.js +1 -1
- package/dist/components/VvRadioGroup/VvRadioGroup.es.js +190 -107
- package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -1
- package/dist/components/VvSelect/VvSelect.es.js +251 -238
- package/dist/components/VvSelect/VvSelect.umd.js +1 -1
- package/dist/components/VvTab/VvTab.es.js +191 -75
- package/dist/components/VvTab/VvTab.umd.js +1 -1
- package/dist/components/VvTextarea/VvTextarea.es.js +232 -224
- package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
- package/dist/components/VvTooltip/VvTooltip.es.js +79 -29
- package/dist/components/VvTooltip/VvTooltip.umd.js +1 -1
- package/dist/components/index.es.js +3534 -1650
- package/dist/components/index.umd.js +1 -1
- package/dist/composables/index.es.js +92 -3
- package/dist/composables/index.umd.js +1 -1
- package/dist/directives/index.es.js +99 -43
- package/dist/directives/index.umd.js +1 -1
- package/dist/directives/v-tooltip.es.js +97 -38
- package/dist/directives/v-tooltip.umd.js +1 -1
- package/dist/icons.es.js +267 -267
- package/dist/icons.umd.js +1 -1
- package/dist/index.es.js +90 -16
- package/dist/index.umd.js +1 -1
- package/dist/resolvers/unplugin.es.js +87 -10
- package/dist/resolvers/unplugin.umd.js +1 -1
- package/dist/src/components/VvAccordion/VvAccordion.vue.d.ts +194 -0
- package/dist/{components → src/components}/VvAccordion/index.d.ts +8 -9
- package/dist/src/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +92 -0
- package/dist/{components → src/components}/VvAccordionGroup/index.d.ts +14 -6
- package/dist/{components → src/components}/VvAction/VvAction.vue.d.ts +57 -22
- package/dist/{components → src/components}/VvAction/index.d.ts +25 -9
- package/dist/{components → src/components}/VvAlert/VvAlert.vue.d.ts +24 -14
- package/dist/{components → src/components}/VvAlert/index.d.ts +17 -9
- package/dist/{components → src/components}/VvAlertGroup/VvAlertGroup.vue.d.ts +16 -9
- package/dist/{components → src/components}/VvAlertGroup/index.d.ts +6 -14
- package/dist/src/components/VvAvatar/VvAvatar.vue.d.ts +23 -0
- package/dist/{components → src/components}/VvAvatar/index.d.ts +4 -1
- package/dist/{components → src/components}/VvAvatarGroup/VvAvatarGroup.vue.d.ts +10 -3
- package/dist/{components → src/components}/VvAvatarGroup/index.d.ts +4 -1
- package/dist/{components → src/components}/VvBadge/VvBadge.vue.d.ts +12 -4
- package/dist/src/components/VvBadge/index.d.ts +7 -0
- package/dist/src/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +38 -0
- package/dist/src/components/VvBreadcrumb/index.d.ts +8 -0
- package/dist/{components → src/components}/VvButton/VvButton.vue.d.ts +94 -40
- package/dist/{components → src/components}/VvButton/index.d.ts +51 -29
- package/dist/{components → src/components}/VvButtonGroup/VvButtonGroup.vue.d.ts +24 -11
- package/dist/{components → src/components}/VvButtonGroup/index.d.ts +8 -2
- package/dist/{components → src/components}/VvCard/VvCard.vue.d.ts +12 -4
- package/dist/src/components/VvCard/index.d.ts +7 -0
- package/dist/src/components/VvCheckbox/VvCheckbox.vue.d.ts +184 -0
- package/dist/{components → src/components}/VvCheckbox/index.d.ts +47 -14
- package/dist/{components → src/components}/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +101 -30
- package/dist/src/components/VvCheckboxGroup/index.d.ts +75 -0
- package/dist/{components → src/components}/VvCombobox/VvCombobox.vue.d.ts +171 -104
- package/dist/{components → src/components}/VvCombobox/index.d.ts +62 -26
- package/dist/{components → src/components}/VvDialog/VvDialog.vue.d.ts +4 -4
- package/dist/{components → src/components}/VvDropdown/VvDropdown.vue.d.ts +101 -75
- package/dist/src/components/VvDropdown/VvDropdownAction.vue.d.ts +114 -0
- package/dist/src/components/VvDropdown/VvDropdownItem.vue.d.ts +21 -0
- package/dist/src/components/VvDropdown/VvDropdownOptgroup.vue.d.ts +14 -0
- package/dist/{components → src/components}/VvDropdown/VvDropdownOption.vue.d.ts +35 -7
- package/dist/{components → src/components}/VvDropdown/index.d.ts +52 -10
- package/dist/src/components/VvIcon/VvIcon.vue.d.ts +26 -0
- package/dist/{components → src/components}/VvIcon/index.d.ts +33 -48
- package/dist/src/components/VvInputFile/VvInputFile.vue.d.ts +359 -0
- package/dist/src/components/VvInputFile/index.d.ts +200 -0
- package/dist/{components → src/components}/VvInputText/VvInputClearAction.d.ts +7 -5
- package/dist/{components → src/components}/VvInputText/VvInputPasswordAction.d.ts +10 -8
- package/dist/{components → src/components}/VvInputText/VvInputStepAction.d.ts +2 -2
- package/dist/{components → src/components}/VvInputText/VvInputText.vue.d.ts +207 -57
- package/dist/{components → src/components}/VvInputText/index.d.ts +99 -29
- package/dist/src/components/VvNav/VvNav.vue.d.ts +48 -0
- package/dist/{components → src/components}/VvNav/VvNavItem.vue.d.ts +1 -1
- package/dist/src/components/VvNav/VvNavSeparator.vue.d.ts +2 -0
- package/dist/src/components/VvNav/index.d.ts +11 -0
- package/dist/{components → src/components}/VvProgress/VvProgress.vue.d.ts +10 -3
- package/dist/{components → src/components}/VvProgress/index.d.ts +4 -1
- package/dist/src/components/VvRadio/VvRadio.vue.d.ts +176 -0
- package/dist/src/components/VvRadio/index.d.ts +80 -0
- package/dist/{components → src/components}/VvRadioGroup/VvRadioGroup.vue.d.ts +101 -30
- package/dist/src/components/VvRadioGroup/index.d.ts +75 -0
- package/dist/{components → src/components}/VvSelect/VvSelect.vue.d.ts +117 -44
- package/dist/{components → src/components}/VvSelect/index.d.ts +48 -14
- package/dist/src/components/VvTab/VvTab.vue.d.ts +63 -0
- package/dist/{components → src/components}/VvTab/index.d.ts +4 -1
- package/dist/{components → src/components}/VvTextarea/VvTextarea.vue.d.ts +156 -49
- package/dist/{components → src/components}/VvTextarea/index.d.ts +68 -19
- package/dist/src/components/VvTooltip/VvTooltip.vue.d.ts +36 -0
- package/dist/{components → src/components}/VvTooltip/index.d.ts +5 -2
- package/dist/{components → src/components}/common/HintSlot.d.ts +1 -1
- package/dist/{components → src/components}/index.d.ts +10 -0
- package/dist/src/composables/alert/useAlert.d.ts +122 -0
- package/dist/src/composables/alert/useInjectAlert.d.ts +4 -0
- package/dist/src/composables/dropdown/useInjectDropdown.d.ts +12 -0
- package/dist/{composables → src/composables}/dropdown/useProvideDropdown.d.ts +3 -4
- package/dist/src/composables/group/useInjectedGroupState.d.ts +9 -0
- package/dist/src/composables/group/useProvideGroupState.d.ts +6 -0
- package/dist/{composables → src/composables}/index.d.ts +1 -0
- package/dist/src/composables/useBlurhash.d.ts +7 -0
- package/dist/src/composables/useComponentIcon.d.ts +11 -0
- package/dist/src/composables/usePersistence.d.ts +2 -0
- package/dist/src/composables/useVolver.d.ts +1 -0
- package/dist/{constants.d.ts → src/constants.d.ts} +34 -32
- package/dist/src/directives/index.d.ts +3 -0
- package/dist/{index.d.ts → src/index.d.ts} +3 -1
- package/dist/{props → src/props}/index.d.ts +272 -81
- package/dist/{resolvers → src/resolvers}/unplugin.d.ts +6 -1
- package/dist/src/stories/AccordionGroup/AccordionGroup.stories.d.ts +188 -0
- package/dist/src/stories/AccordionGroup/AccordionGroupSlots.stories.d.ts +1262 -0
- package/dist/{stories → src/stories}/AlertGroup/AlertGroupWithComposable.stories.d.ts +1 -1
- package/dist/src/stories/Blurhash/BlurhashComposable.stories.d.ts +4 -0
- package/dist/{stories → src/stories}/Button/Button.settings.d.ts +0 -1
- package/dist/{stories → src/stories}/Combobox/Combobox.settings.d.ts +8 -0
- package/dist/{stories → src/stories}/Icon/Icon.settings.d.ts +1 -0
- package/dist/src/stories/InputFile/InputFile.settings.d.ts +56 -0
- package/dist/src/stories/InputFile/InputFile.stories.d.ts +12 -0
- package/dist/src/stories/InputFile/InputFileDropArea.stories.d.ts +9 -0
- package/dist/src/stories/InputFile/InputFileIconPosition.stories.d.ts +8 -0
- package/dist/src/stories/InputFile/InputFileSlots.stories.d.ts +7 -0
- package/dist/src/stories/Tab/Tab.settings.d.ts +4 -0
- package/dist/{test → src/test}/expect.d.ts +1 -1
- package/dist/src/types/alert.d.ts +15 -0
- package/dist/src/types/blurhash.d.ts +12 -0
- package/dist/{types → src/types}/generic.d.ts +1 -2
- package/dist/src/types/group.d.ts +59 -0
- package/dist/src/types/index.d.ts +7 -0
- package/dist/src/types/input-file.d.ts +16 -0
- package/dist/{types → src/types}/nav.d.ts +2 -2
- package/dist/{utils → src/utils}/ObjectUtilities.d.ts +0 -1
- package/dist/src/workers/blurhash.d.ts +1 -0
- package/package.json +78 -78
- package/src/Volver.ts +31 -20
- 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 +121 -58
- package/src/components/VvAccordion/index.ts +8 -23
- package/src/components/VvAccordionGroup/VvAccordionGroup.vue +164 -47
- package/src/components/VvAccordionGroup/index.ts +6 -6
- package/src/components/VvAction/VvAction.vue +17 -5
- package/src/components/VvAlert/index.ts +14 -9
- package/src/components/VvAlertGroup/index.ts +3 -15
- package/src/components/VvBreadcrumb/VvBreadcrumb.vue +20 -19
- package/src/components/VvBreadcrumb/index.ts +2 -8
- package/src/components/VvButton/VvButton.vue +17 -7
- package/src/components/VvButton/index.ts +9 -16
- package/src/components/VvButtonGroup/VvButtonGroup.vue +1 -2
- package/src/components/VvCheckbox/index.ts +2 -2
- package/src/components/VvCheckboxGroup/VvCheckboxGroup.vue +1 -2
- package/src/components/VvCombobox/VvCombobox.vue +15 -12
- package/src/components/VvCombobox/index.ts +4 -0
- package/src/components/VvDropdown/VvDropdown.vue +11 -2
- package/src/components/VvDropdown/VvDropdownItem.vue +4 -1
- package/src/components/VvDropdown/VvDropdownOption.vue +4 -21
- package/src/components/VvDropdown/index.ts +35 -1
- package/src/components/VvIcon/VvIcon.vue +2 -2
- package/src/components/VvIcon/index.ts +35 -48
- package/src/components/VvInputFile/VvInputFile.vue +395 -0
- package/src/components/VvInputFile/index.ts +135 -0
- package/src/components/VvInputText/VvInputClearAction.ts +10 -6
- package/src/components/VvInputText/VvInputPasswordAction.ts +13 -9
- package/src/components/VvInputText/VvInputText.vue +141 -33
- package/src/components/VvInputText/index.ts +31 -16
- package/src/components/VvNav/VvNav.vue +4 -2
- package/src/components/VvRadio/index.ts +5 -5
- package/src/components/VvRadioGroup/VvRadioGroup.vue +1 -2
- package/src/components/VvSelect/VvSelect.vue +5 -8
- package/src/components/VvTab/VvTab.vue +5 -1
- package/src/components/VvTextarea/VvTextarea.vue +6 -9
- package/src/components/index.ts +10 -0
- package/src/composables/alert/useAlert.ts +12 -9
- package/src/composables/dropdown/useProvideDropdown.ts +4 -4
- package/src/composables/group/useInjectedGroupState.ts +20 -16
- package/src/composables/group/useProvideGroupState.ts +10 -15
- package/src/composables/index.ts +1 -0
- package/src/composables/useBlurhash.ts +76 -0
- package/src/composables/useComponentIcon.ts +15 -14
- package/src/composables/usePersistence.ts +76 -0
- package/src/composables/useUniqueId.ts +2 -2
- package/src/constants.ts +47 -32
- package/src/directives/index.ts +3 -6
- package/src/directives/v-tooltip.ts +19 -10
- package/src/index.ts +3 -1
- package/src/props/index.ts +108 -31
- package/src/resolvers/unplugin.ts +24 -14
- package/src/stories/Accordion/Accordion.test.ts +1 -1
- package/src/stories/AccordionGroup/AccordionGroup.settings.ts +2 -2
- package/src/stories/AccordionGroup/AccordionGroup.test.ts +17 -11
- package/src/stories/AccordionGroup/AccordionGroupSlots.stories.ts +1 -1
- package/src/stories/Alert/Alert.test.ts +1 -1
- package/src/stories/AlertGroup/AlertGroup.test.ts +1 -1
- package/src/stories/AlertGroup/AlertGroupWithComposable.stories.ts +2 -2
- package/src/stories/Avatar/Avatar.test.ts +1 -1
- package/src/stories/AvatarGroup/AvatarGroup.test.ts +1 -1
- package/src/stories/Badge/Badge.test.ts +1 -1
- package/src/stories/Blurhash/BlurhashComposable.stories.ts +195 -0
- package/src/stories/Button/Button.settings.ts +1 -4
- package/src/stories/Button/Button.test.ts +1 -1
- package/src/stories/ButtonGroup/ButtonGroup.test.ts +1 -1
- package/src/stories/Card/Card.test.ts +1 -1
- package/src/stories/Checkbox/Checkbox.test.ts +1 -1
- package/src/stories/CheckboxGroup/CheckboxGroup.test.ts +1 -1
- package/src/stories/Combobox/Combobox.settings.ts +8 -0
- package/src/stories/Combobox/Combobox.test.ts +1 -1
- package/src/stories/Dialog/Dialog.test.ts +2 -2
- package/src/stories/Dropdown/Dropdown.test.ts +1 -1
- package/src/stories/Icon/Icon.settings.ts +3 -3
- package/src/stories/InputFile/InputFile.settings.ts +36 -0
- package/src/stories/InputFile/InputFile.stories.ts +89 -0
- package/src/stories/InputFile/InputFileDropArea.stories.ts +56 -0
- package/src/stories/InputFile/InputFileIconPosition.stories.ts +43 -0
- package/src/stories/InputFile/InputFileSlots.stories.ts +33 -0
- package/src/stories/InputText/InputText.test.ts +1 -1
- package/src/stories/Nav/Nav.test.ts +1 -1
- package/src/stories/Progress/Progress.test.ts +1 -1
- package/src/stories/Radio/Radio.test.ts +1 -1
- package/src/stories/RadioGroup/RadioGroup.test.ts +1 -1
- package/src/stories/Select/Select.test.ts +1 -1
- package/src/stories/Tab/Tab.settings.ts +2 -2
- package/src/stories/Tab/Tab.test.ts +1 -1
- package/src/stories/Textarea/Textarea.test.ts +1 -1
- package/src/stories/Tooltip/Tooltip.test.ts +1 -1
- package/src/stories/argTypes.ts +1 -1
- package/src/test/expect.ts +2 -4
- package/src/types/alert.ts +11 -7
- package/src/types/blurhash.ts +21 -0
- package/src/types/generic.ts +3 -3
- package/src/types/group.ts +22 -14
- package/src/types/index.ts +7 -0
- package/src/types/input-file.ts +18 -0
- package/src/types/nav.ts +2 -3
- package/src/utils/ObjectUtilities.ts +0 -11
- package/src/workers/blurhash.ts +9 -0
- package/dist/components/VvAccordion/VvAccordion.vue.d.ts +0 -42
- package/dist/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +0 -47
- package/dist/components/VvAvatar/VvAvatar.vue.d.ts +0 -15
- package/dist/components/VvBadge/index.d.ts +0 -4
- package/dist/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +0 -18
- package/dist/components/VvBreadcrumb/index.d.ts +0 -12
- package/dist/components/VvCard/index.d.ts +0 -4
- package/dist/components/VvCheckbox/VvCheckbox.vue.d.ts +0 -112
- package/dist/components/VvCheckboxGroup/index.d.ts +0 -42
- package/dist/components/VvDropdown/VvDropdownAction.vue.d.ts +0 -73
- package/dist/components/VvDropdown/VvDropdownItem.vue.d.ts +0 -9
- package/dist/components/VvDropdown/VvDropdownOptgroup.vue.d.ts +0 -6
- package/dist/components/VvIcon/VvIcon.vue.d.ts +0 -69
- package/dist/components/VvNav/VvNav.vue.d.ts +0 -25
- package/dist/components/VvNav/VvNavSeparator.vue.d.ts +0 -2
- package/dist/components/VvNav/index.d.ts +0 -8
- package/dist/components/VvRadio/VvRadio.vue.d.ts +0 -104
- package/dist/components/VvRadio/index.d.ts +0 -47
- package/dist/components/VvRadioGroup/index.d.ts +0 -42
- package/dist/components/VvTab/VvTab.vue.d.ts +0 -39
- package/dist/components/VvTooltip/VvTooltip.vue.d.ts +0 -29
- package/dist/composables/alert/useAlert.d.ts +0 -27
- package/dist/composables/alert/useInjectAlert.d.ts +0 -9
- package/dist/composables/dropdown/useInjectDropdown.d.ts +0 -32
- package/dist/composables/group/useInjectedGroupState.d.ts +0 -10
- package/dist/composables/group/useProvideGroupState.d.ts +0 -6
- package/dist/composables/useComponentIcon.d.ts +0 -10
- package/dist/composables/useVolver.d.ts +0 -1
- package/dist/directives/index.d.ts +0 -5
- package/dist/stories/AccordionGroup/AccordionGroup.stories.d.ts +0 -134
- package/dist/stories/AccordionGroup/AccordionGroupSlots.stories.d.ts +0 -679
- package/dist/stories/Tab/Tab.settings.d.ts +0 -17
- package/dist/types/alert.d.ts +0 -13
- package/dist/types/group.d.ts +0 -37
- package/dist/{Volver.d.ts → src/Volver.d.ts} +1 -1
- /package/dist/{components → src/components}/VvDialog/index.d.ts +0 -0
- /package/dist/{components → src/components}/VvInputText/VvInputTextActions.d.ts +0 -0
- /package/dist/{composables → src/composables}/alert/useProvideAlert.d.ts +0 -0
- /package/dist/{composables → src/composables}/useComponentFocus.d.ts +0 -0
- /package/dist/{composables → src/composables}/useDebouncedInput.d.ts +0 -0
- /package/dist/{composables → src/composables}/useDefaults.d.ts +0 -0
- /package/dist/{composables → src/composables}/useModifiers.d.ts +0 -0
- /package/dist/{composables → src/composables}/useOptions.d.ts +0 -0
- /package/dist/{composables → src/composables}/useTextCount.d.ts +0 -0
- /package/dist/{composables → src/composables}/useUniqueId.d.ts +0 -0
- /package/dist/{directives → src/directives}/v-contextmenu.d.ts +0 -0
- /package/dist/{directives → src/directives}/v-tooltip.d.ts +0 -0
- /package/dist/{icons.d.ts → src/icons.d.ts} +0 -0
- /package/dist/{stories → src/stories}/Accordion/Accordion.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Accordion/Accordion.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Accordion/Accordion.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Accordion/AccordionSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/AccordionGroup/AccordionGroup.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/AccordionGroup/AccordionGroup.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Alert/Alert.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Alert/Alert.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Alert/Alert.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Alert/AlertModifiers.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Alert/AlertSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/AlertGroup/AlertGroup.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/AlertGroup/AlertGroup.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/AlertGroup/AlertGroup.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/AlertGroup/AlertGroupPosition.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/AlertGroup/AlertGroupSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Avatar/Avatar.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Avatar/Avatar.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Avatar/Avatar.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Avatar/AvatarBadge.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Avatar/AvatarModifiers.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Avatar/AvatarSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/AvatarGroup/AvatarGroup.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/AvatarGroup/AvatarGroup.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/AvatarGroup/AvatarGroup.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/AvatarGroup/AvatarGroupModifiers.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/AvatarGroup/AvatarGroupSlotDefault.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Badge/Badge.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Badge/Badge.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Badge/Badge.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Badge/BadgeSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Breadcrumb/Breadcrumb.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Breadcrumb/Breadcrumb.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Breadcrumb/Breadcrumb.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Breadcrumb/BreadcrumbSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/Button.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/Button.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/ButtonIcon.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/ButtonLink.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/ButtonLoading.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/ButtonModifiers.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/ButtonSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/ButtonState.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Button/ButtonToggle.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/ButtonGroup/ButtonGroup.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/ButtonGroup/ButtonGroup.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/ButtonGroup/ButtonGroup.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/ButtonGroup/ButtonGroupModifiers.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/ButtonGroup/ButtonGroupSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/ButtonGroup/ButtonGroupToggle.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Card/Card.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Card/Card.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Card/Card.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Card/CardSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Checkbox/Checkbox.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Checkbox/Checkbox.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Checkbox/Checkbox.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Checkbox/CheckboxBinary.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Checkbox/CheckboxSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/CheckboxGroup/CheckboxGroup.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/CheckboxGroup/CheckboxGroup.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/CheckboxGroup/CheckboxGroup.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/CheckboxGroup/CheckboxGroupOptions.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/CheckboxGroup/CheckboxGroupSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Combobox/Combobox.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Combobox/Combobox.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Combobox/ComboboxIconPosition.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Combobox/ComboboxMultiple.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Combobox/ComboboxOptions.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Combobox/ComboboxSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dialog/Dialog.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dialog/Dialog.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dialog/Dialog.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dialog/DialogSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dropdown/Dropdown.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dropdown/Dropdown.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dropdown/Dropdown.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dropdown/DropdownContextmenuDirective.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dropdown/DropdownMultilevel.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Dropdown/DropdownSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Icon/Icon.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Icon/IconsCollection.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputText.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputText.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputText.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputTextIconPosition.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputTextLength.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputTextMask.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputTextMinMax.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputTextSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/InputText/InputTextType.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Nav/Nav.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Nav/Nav.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Nav/Nav.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Nav/NavModifiers.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Progress/Progress.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Progress/Progress.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Progress/Progress.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Radio/Radio.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Radio/Radio.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Radio/Radio.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Radio/RadioSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/RadioGroup/RadioGroup.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/RadioGroup/RadioGroup.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/RadioGroup/RadioGroup.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/RadioGroup/RadioGroupOptions.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/RadioGroup/RadioGroupSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Select/Select.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Select/Select.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Select/Select.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Select/SelectIconPosition.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Select/SelectOptions.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Select/SelectSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Tab/Tab.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Tab/Tab.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Textarea/Textarea.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Textarea/Textarea.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Textarea/Textarea.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Textarea/TextareaLength.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Textarea/TextareaSlots.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Textarea/TextareatIconPosition.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Tooltip/Tooltip.settings.d.ts +0 -0
- /package/dist/{stories → src/stories}/Tooltip/Tooltip.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/Tooltip/Tooltip.test.d.ts +0 -0
- /package/dist/{stories → src/stories}/Tooltip/TooltipDirective.stories.d.ts +0 -0
- /package/dist/{stories → src/stories}/argTypes.d.ts +0 -0
- /package/dist/{test → src/test}/options.d.ts +0 -0
- /package/dist/{test → src/test}/sleep.d.ts +0 -0
- /package/dist/{types → src/types}/floating-ui.d.ts +0 -0
|
@@ -1,10 +1,15 @@
|
|
|
1
|
-
import { inject, computed, unref, defineComponent, ref, toRefs, openBlock, createBlock, mergeProps, createCommentVNode, provide, h, Fragment, useAttrs, onMounted, watch, nextTick, createElementBlock, createVNode, withCtx, renderSlot, normalizeProps, guardReactiveProps, Transition, toHandlers, withDirectives, createElementVNode, normalizeStyle, normalizeClass, vShow, createTextVNode, toDisplayString, isRef, useSlots, renderList, vModelSelect, createSlots, resolveDynamicComponent, toRef, withModifiers, vModelText } from "vue";
|
|
1
|
+
import { inject, computed, unref, defineComponent, mergeDefaults, ref, toRefs, openBlock, createBlock, mergeProps, createCommentVNode, provide, h, Fragment, useAttrs, onMounted, watch, nextTick, createElementBlock, createVNode, withCtx, renderSlot, normalizeProps, guardReactiveProps, Transition, toHandlers, withDirectives, createElementVNode, normalizeStyle, normalizeClass, vShow, createTextVNode, toDisplayString, isRef, useSlots, renderList, vModelSelect, createSlots, getCurrentInstance, resolveDynamicComponent, toRef, withModifiers, vModelText } from "vue";
|
|
2
2
|
import { iconExists, Icon, addIcon } from "@iconify/vue";
|
|
3
3
|
import { autoPlacement, flip, shift, size, offset, arrow, useFloating, autoUpdate } from "@floating-ui/vue";
|
|
4
|
-
import {
|
|
5
|
-
import { useMutationObserver, useVModel, onClickOutside, useFocusWithin,
|
|
4
|
+
import { uid } from "uid";
|
|
5
|
+
import { useMutationObserver, useVModel, onClickOutside, useFocusWithin, useElementHover, onKeyStroke, useFocus, useElementVisibility, refDebounced, computedAsync } from "@vueuse/core";
|
|
6
6
|
import mitt from "mitt";
|
|
7
7
|
import { get } from "ts-dot-prop";
|
|
8
|
+
var StorageType = /* @__PURE__ */ ((StorageType2) => {
|
|
9
|
+
StorageType2["local"] = "local";
|
|
10
|
+
StorageType2["session"] = "session";
|
|
11
|
+
return StorageType2;
|
|
12
|
+
})(StorageType || {});
|
|
8
13
|
var Strategy = /* @__PURE__ */ ((Strategy2) => {
|
|
9
14
|
Strategy2["absolute"] = "absolute";
|
|
10
15
|
Strategy2["fixed"] = "fixed";
|
|
@@ -62,15 +67,10 @@ var DropdownItemRole = /* @__PURE__ */ ((DropdownItemRole2) => {
|
|
|
62
67
|
DropdownItemRole2["presentation"] = "presentation";
|
|
63
68
|
return DropdownItemRole2;
|
|
64
69
|
})(DropdownItemRole || {});
|
|
65
|
-
var AnchorTarget = /* @__PURE__ */ ((AnchorTarget2) => {
|
|
66
|
-
AnchorTarget2["_blank"] = "_blank";
|
|
67
|
-
AnchorTarget2["_self"] = "_self";
|
|
68
|
-
AnchorTarget2["_parent"] = "_parent";
|
|
69
|
-
AnchorTarget2["_top"] = "_top";
|
|
70
|
-
return AnchorTarget2;
|
|
71
|
-
})(AnchorTarget || {});
|
|
72
70
|
const INJECTION_KEY_VOLVER = Symbol.for("volver");
|
|
73
|
-
const INJECTION_KEY_BUTTON_GROUP = Symbol.for(
|
|
71
|
+
const INJECTION_KEY_BUTTON_GROUP = Symbol.for(
|
|
72
|
+
"buttonGroup"
|
|
73
|
+
);
|
|
74
74
|
const INJECTION_KEY_DROPDOWN_TRIGGER = Symbol.for(
|
|
75
75
|
"dropdownTrigger"
|
|
76
76
|
);
|
|
@@ -95,10 +95,7 @@ const LinkProps = {
|
|
|
95
95
|
/**
|
|
96
96
|
* Anchor target
|
|
97
97
|
*/
|
|
98
|
-
target:
|
|
99
|
-
type: String,
|
|
100
|
-
validator: (value) => Object.values(AnchorTarget).includes(value)
|
|
101
|
-
},
|
|
98
|
+
target: String,
|
|
102
99
|
/**
|
|
103
100
|
* Anchor rel
|
|
104
101
|
*/
|
|
@@ -111,27 +108,33 @@ const ValidProps = {
|
|
|
111
108
|
/**
|
|
112
109
|
* Valid status
|
|
113
110
|
*/
|
|
114
|
-
valid: Boolean,
|
|
111
|
+
valid: { type: Boolean, default: false },
|
|
115
112
|
/**
|
|
116
113
|
* Valid label
|
|
117
114
|
*/
|
|
118
|
-
validLabel: [String, Array]
|
|
115
|
+
validLabel: { type: [String, Array], default: void 0 }
|
|
119
116
|
};
|
|
120
117
|
const InvalidProps = {
|
|
121
118
|
/**
|
|
122
119
|
* Invalid status
|
|
123
120
|
*/
|
|
124
|
-
invalid:
|
|
121
|
+
invalid: {
|
|
122
|
+
type: Boolean,
|
|
123
|
+
default: false
|
|
124
|
+
},
|
|
125
125
|
/**
|
|
126
126
|
* Invalid label
|
|
127
127
|
*/
|
|
128
|
-
invalidLabel: [String, Array]
|
|
128
|
+
invalidLabel: { type: [String, Array], default: void 0 }
|
|
129
129
|
};
|
|
130
130
|
const LoadingProps = {
|
|
131
131
|
/**
|
|
132
132
|
* Loading status
|
|
133
133
|
*/
|
|
134
|
-
loading:
|
|
134
|
+
loading: {
|
|
135
|
+
type: Boolean,
|
|
136
|
+
default: false
|
|
137
|
+
},
|
|
135
138
|
/**
|
|
136
139
|
* Loading label
|
|
137
140
|
*/
|
|
@@ -144,49 +147,73 @@ const DisabledProps = {
|
|
|
144
147
|
/**
|
|
145
148
|
* Whether the form control is disabled
|
|
146
149
|
*/
|
|
147
|
-
disabled:
|
|
150
|
+
disabled: {
|
|
151
|
+
type: Boolean,
|
|
152
|
+
default: false
|
|
153
|
+
}
|
|
148
154
|
};
|
|
149
155
|
const SelectedProps = {
|
|
150
156
|
/**
|
|
151
157
|
* Whether the item is selected
|
|
152
158
|
*/
|
|
153
|
-
selected:
|
|
159
|
+
selected: {
|
|
160
|
+
type: Boolean,
|
|
161
|
+
default: false
|
|
162
|
+
}
|
|
154
163
|
};
|
|
155
164
|
const ActiveProps = {
|
|
156
165
|
/**
|
|
157
166
|
* Whether the item is active
|
|
158
167
|
*/
|
|
159
|
-
active:
|
|
168
|
+
active: {
|
|
169
|
+
type: Boolean,
|
|
170
|
+
default: false
|
|
171
|
+
}
|
|
160
172
|
};
|
|
161
173
|
const CurrentProps = {
|
|
162
174
|
/**
|
|
163
175
|
* Whether the item is current
|
|
164
176
|
*/
|
|
165
|
-
current:
|
|
177
|
+
current: {
|
|
178
|
+
type: Boolean,
|
|
179
|
+
default: false
|
|
180
|
+
}
|
|
166
181
|
};
|
|
167
182
|
const PressedProps = {
|
|
168
183
|
/**
|
|
169
184
|
* Whether the item is pressed
|
|
170
185
|
*/
|
|
171
|
-
pressed:
|
|
186
|
+
pressed: {
|
|
187
|
+
type: Boolean,
|
|
188
|
+
default: false
|
|
189
|
+
}
|
|
172
190
|
};
|
|
173
191
|
const LabelProps = {
|
|
174
192
|
/**
|
|
175
193
|
* The item label
|
|
176
194
|
*/
|
|
177
|
-
label:
|
|
195
|
+
label: {
|
|
196
|
+
type: [String, Number],
|
|
197
|
+
default: void 0
|
|
198
|
+
}
|
|
178
199
|
};
|
|
179
200
|
const ReadonlyProps = {
|
|
180
201
|
/**
|
|
181
202
|
* The value is not editable
|
|
182
203
|
*/
|
|
183
|
-
readonly:
|
|
204
|
+
readonly: {
|
|
205
|
+
type: Boolean,
|
|
206
|
+
default: false
|
|
207
|
+
}
|
|
184
208
|
};
|
|
185
209
|
const ModifiersProps = {
|
|
186
210
|
/**
|
|
187
211
|
* Component BEM modifiers
|
|
188
212
|
*/
|
|
189
|
-
modifiers:
|
|
213
|
+
modifiers: {
|
|
214
|
+
type: [String, Array],
|
|
215
|
+
default: void 0
|
|
216
|
+
}
|
|
190
217
|
};
|
|
191
218
|
const HintProps = {
|
|
192
219
|
hintLabel: { type: String, default: "" }
|
|
@@ -217,7 +244,10 @@ const IconProps = {
|
|
|
217
244
|
* VvIcon name or props
|
|
218
245
|
* @see VVIcon
|
|
219
246
|
*/
|
|
220
|
-
icon: {
|
|
247
|
+
icon: {
|
|
248
|
+
type: [String, Object],
|
|
249
|
+
default: void 0
|
|
250
|
+
},
|
|
221
251
|
/**
|
|
222
252
|
* VvIcon position
|
|
223
253
|
*/
|
|
@@ -238,7 +268,10 @@ const FloatingLabelProps = {
|
|
|
238
268
|
/**
|
|
239
269
|
* If true the label will be floating
|
|
240
270
|
*/
|
|
241
|
-
floating:
|
|
271
|
+
floating: {
|
|
272
|
+
type: Boolean,
|
|
273
|
+
default: false
|
|
274
|
+
}
|
|
242
275
|
};
|
|
243
276
|
const UnselectableProps = {
|
|
244
277
|
/**
|
|
@@ -274,7 +307,8 @@ const DropdownProps = {
|
|
|
274
307
|
* Dropdown show / hide transition name
|
|
275
308
|
*/
|
|
276
309
|
transitionName: {
|
|
277
|
-
type: String
|
|
310
|
+
type: String,
|
|
311
|
+
default: void 0
|
|
278
312
|
},
|
|
279
313
|
/**
|
|
280
314
|
* Offset of the dropdown from the trigger
|
|
@@ -342,7 +376,8 @@ const DropdownProps = {
|
|
|
342
376
|
* Set dropdown width to the same as the trigger
|
|
343
377
|
*/
|
|
344
378
|
triggerWidth: {
|
|
345
|
-
type: Boolean
|
|
379
|
+
type: Boolean,
|
|
380
|
+
default: false
|
|
346
381
|
}
|
|
347
382
|
};
|
|
348
383
|
const IdNameProps = {
|
|
@@ -359,7 +394,10 @@ const AutofocusProps = {
|
|
|
359
394
|
* Global attribute autofocus
|
|
360
395
|
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/autofocus
|
|
361
396
|
*/
|
|
362
|
-
autofocus:
|
|
397
|
+
autofocus: {
|
|
398
|
+
type: Boolean,
|
|
399
|
+
default: false
|
|
400
|
+
}
|
|
363
401
|
};
|
|
364
402
|
const AutocompleteProps = {
|
|
365
403
|
/**
|
|
@@ -389,10 +427,29 @@ const ActionProps = {
|
|
|
389
427
|
ariaLabel: {
|
|
390
428
|
type: String,
|
|
391
429
|
default: void 0
|
|
430
|
+
},
|
|
431
|
+
/**
|
|
432
|
+
* Default tag for the action
|
|
433
|
+
*/
|
|
434
|
+
defaultTag: {
|
|
435
|
+
type: String,
|
|
436
|
+
default: ActionTag.button
|
|
392
437
|
}
|
|
393
438
|
};
|
|
439
|
+
({
|
|
440
|
+
storageType: {
|
|
441
|
+
type: String,
|
|
442
|
+
default: StorageType.local,
|
|
443
|
+
validator: (value) => Object.values(StorageType).includes(value)
|
|
444
|
+
},
|
|
445
|
+
storageKey: String
|
|
446
|
+
});
|
|
394
447
|
const VvComboboxEvents = [
|
|
395
448
|
"update:modelValue",
|
|
449
|
+
"update:search",
|
|
450
|
+
/**
|
|
451
|
+
* @deprecated change:search should not be used, use update:search instead
|
|
452
|
+
*/
|
|
396
453
|
"change:search",
|
|
397
454
|
"focus",
|
|
398
455
|
"blur"
|
|
@@ -540,99 +597,9 @@ const VvComboboxProps = {
|
|
|
540
597
|
default: false
|
|
541
598
|
}
|
|
542
599
|
};
|
|
543
|
-
const
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
*/
|
|
547
|
-
color: String,
|
|
548
|
-
/**
|
|
549
|
-
* Width
|
|
550
|
-
*/
|
|
551
|
-
width: {
|
|
552
|
-
type: [String, Number]
|
|
553
|
-
},
|
|
554
|
-
/**
|
|
555
|
-
* Height
|
|
556
|
-
*/
|
|
557
|
-
height: {
|
|
558
|
-
type: [String, Number]
|
|
559
|
-
},
|
|
560
|
-
/**
|
|
561
|
-
* Icon name
|
|
562
|
-
* Can be the full composition of iconify name "@{provider}:{prefix}:{name}" or "{prefix}:{name}" or "{name}"
|
|
563
|
-
* https://docs.iconify.design/api/providers.html#provider-in-icon-name
|
|
564
|
-
*/
|
|
565
|
-
name: {
|
|
566
|
-
type: String,
|
|
567
|
-
required: true
|
|
568
|
-
},
|
|
569
|
-
/**
|
|
570
|
-
* By default 'vv'
|
|
571
|
-
* If custom collection is not added with "addCollection" DS class method, this prop could not be used
|
|
572
|
-
* Icon provider: https://docs.iconify.design/api/providers.html#provider-in-icon-name
|
|
573
|
-
*/
|
|
574
|
-
provider: {
|
|
575
|
-
type: String
|
|
576
|
-
},
|
|
577
|
-
/**
|
|
578
|
-
* The name of icon set.
|
|
579
|
-
* Icon default options prefix: simple | normal | detailed
|
|
580
|
-
*/
|
|
581
|
-
prefix: {
|
|
582
|
-
type: String,
|
|
583
|
-
default: "normal"
|
|
584
|
-
},
|
|
585
|
-
/**
|
|
586
|
-
* Url remote SVG icon
|
|
587
|
-
*/
|
|
588
|
-
src: String,
|
|
589
|
-
/**
|
|
590
|
-
* Horizontal flip
|
|
591
|
-
*/
|
|
592
|
-
horizontalFlip: Boolean,
|
|
593
|
-
/**
|
|
594
|
-
* Vertical flip
|
|
595
|
-
*/
|
|
596
|
-
verticalFlip: Boolean,
|
|
597
|
-
/**
|
|
598
|
-
* String alternative to "horizontalFlip" and "verticalFlip".
|
|
599
|
-
* Example: https://docs.iconify.design/icon-components/vue/transform.html
|
|
600
|
-
*/
|
|
601
|
-
flip: String,
|
|
602
|
-
/**
|
|
603
|
-
* Icon render mode
|
|
604
|
-
* 'style' = 'bg' or 'mask', depending on icon content
|
|
605
|
-
* 'bg' = span with style using `background`
|
|
606
|
-
* 'mask' = span with style using `mask`
|
|
607
|
-
* 'svg' = svg
|
|
608
|
-
* Iconify doc: https://docs.iconify.design/iconify-icon/modes.html
|
|
609
|
-
*/
|
|
610
|
-
mode: String,
|
|
611
|
-
/**
|
|
612
|
-
* Toggles inline or block mode
|
|
613
|
-
* Example https://docs.iconify.design/icon-components/vue/inline.html
|
|
614
|
-
*/
|
|
615
|
-
inline: Boolean,
|
|
616
|
-
/**
|
|
617
|
-
* rotates icon
|
|
618
|
-
* Example https://docs.iconify.design/icon-components/vue/transform.html
|
|
619
|
-
*/
|
|
620
|
-
rotate: [Number, String],
|
|
621
|
-
/**
|
|
622
|
-
* A callback that is called when icon data has been loaded
|
|
623
|
-
*/
|
|
624
|
-
onLoad: Function,
|
|
625
|
-
/**
|
|
626
|
-
* SVG icon string
|
|
627
|
-
*/
|
|
628
|
-
svg: String,
|
|
629
|
-
/**
|
|
630
|
-
* Icon modifiers: vv-icon css helper classes, value/s are concatened with prefix 'vv-icon--'
|
|
631
|
-
* @values string | string[]
|
|
632
|
-
*/
|
|
633
|
-
modifiers: {
|
|
634
|
-
type: [String, Array]
|
|
635
|
-
}
|
|
600
|
+
const VvIconPropsDefaults = {
|
|
601
|
+
prefix: "normal"
|
|
602
|
+
/* normal */
|
|
636
603
|
};
|
|
637
604
|
function useVolver() {
|
|
638
605
|
return inject(INJECTION_KEY_VOLVER);
|
|
@@ -665,7 +632,24 @@ const __default__$9 = {
|
|
|
665
632
|
};
|
|
666
633
|
const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
667
634
|
...__default__$9,
|
|
668
|
-
props:
|
|
635
|
+
props: /* @__PURE__ */ mergeDefaults({
|
|
636
|
+
name: {},
|
|
637
|
+
color: {},
|
|
638
|
+
width: {},
|
|
639
|
+
height: {},
|
|
640
|
+
provider: {},
|
|
641
|
+
prefix: {},
|
|
642
|
+
src: {},
|
|
643
|
+
horizontalFlip: { type: Boolean },
|
|
644
|
+
verticalFlip: { type: Boolean },
|
|
645
|
+
flip: {},
|
|
646
|
+
mode: {},
|
|
647
|
+
inline: { type: Boolean },
|
|
648
|
+
rotate: {},
|
|
649
|
+
onLoad: { type: Function },
|
|
650
|
+
svg: {},
|
|
651
|
+
modifiers: {}
|
|
652
|
+
}, VvIconPropsDefaults),
|
|
669
653
|
setup(__props) {
|
|
670
654
|
const props = __props;
|
|
671
655
|
const hasRotate = computed(() => {
|
|
@@ -752,7 +736,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
752
736
|
color: _ctx.color,
|
|
753
737
|
onLoad: _ctx.onLoad,
|
|
754
738
|
icon: unref(icon)
|
|
755
|
-
}), null, 16, ["class"])) : createCommentVNode("", true);
|
|
739
|
+
}), null, 16, ["class"])) : createCommentVNode("v-if", true);
|
|
756
740
|
};
|
|
757
741
|
}
|
|
758
742
|
});
|
|
@@ -783,7 +767,32 @@ const VvDropdownProps = {
|
|
|
783
767
|
validator: (value) => Object.values(DropdownRole).includes(value)
|
|
784
768
|
}
|
|
785
769
|
};
|
|
786
|
-
const
|
|
770
|
+
const VvDropdownItemProps = {
|
|
771
|
+
focusOnHover: {
|
|
772
|
+
type: Boolean,
|
|
773
|
+
default: false
|
|
774
|
+
}
|
|
775
|
+
};
|
|
776
|
+
const VvDropdownOptionProps = {
|
|
777
|
+
...DisabledProps,
|
|
778
|
+
...SelectedProps,
|
|
779
|
+
...UnselectableProps,
|
|
780
|
+
...ModifiersProps,
|
|
781
|
+
deselectHintLabel: {
|
|
782
|
+
type: String
|
|
783
|
+
},
|
|
784
|
+
selectHintLabel: {
|
|
785
|
+
type: String
|
|
786
|
+
},
|
|
787
|
+
selectedHintLabel: {
|
|
788
|
+
type: String
|
|
789
|
+
},
|
|
790
|
+
focusOnHover: {
|
|
791
|
+
type: Boolean,
|
|
792
|
+
default: false
|
|
793
|
+
}
|
|
794
|
+
};
|
|
795
|
+
const useUniqueId = (id) => computed(() => String((id == null ? void 0 : id.value) || uid()));
|
|
787
796
|
function useProvideDropdownTrigger({
|
|
788
797
|
reference,
|
|
789
798
|
id,
|
|
@@ -814,14 +823,14 @@ function useProvideDropdownTrigger({
|
|
|
814
823
|
}
|
|
815
824
|
function useProvideDropdownItem({
|
|
816
825
|
role,
|
|
817
|
-
|
|
826
|
+
...others
|
|
818
827
|
}) {
|
|
819
828
|
const itemRole = computed(
|
|
820
829
|
() => role.value === DropdownRole.listbox ? DropdownItemRole.option : DropdownItemRole.presentation
|
|
821
830
|
);
|
|
822
831
|
provide(INJECTION_KEY_DROPDOWN_ITEM, {
|
|
823
832
|
role: itemRole,
|
|
824
|
-
|
|
833
|
+
...others
|
|
825
834
|
});
|
|
826
835
|
return { itemRole };
|
|
827
836
|
}
|
|
@@ -856,8 +865,9 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
|
856
865
|
"leave",
|
|
857
866
|
"leave-cancelled"
|
|
858
867
|
],
|
|
859
|
-
setup(__props, { expose: __expose, emit }) {
|
|
868
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
860
869
|
const props = __props;
|
|
870
|
+
const emit = __emit;
|
|
861
871
|
const { id } = toRefs(props);
|
|
862
872
|
const hasId = useUniqueId(id);
|
|
863
873
|
const attrs = useAttrs();
|
|
@@ -1071,7 +1081,6 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
|
1071
1081
|
});
|
|
1072
1082
|
bus.on("click", toggle);
|
|
1073
1083
|
const { role, modifiers } = toRefs(props);
|
|
1074
|
-
const { itemRole } = useProvideDropdownItem({ role, expanded });
|
|
1075
1084
|
const bemCssClasses = useModifiers(
|
|
1076
1085
|
"vv-dropdown",
|
|
1077
1086
|
modifiers,
|
|
@@ -1140,6 +1149,13 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
|
1140
1149
|
}
|
|
1141
1150
|
});
|
|
1142
1151
|
};
|
|
1152
|
+
const hovered = useElementHover(floatingEl);
|
|
1153
|
+
const { itemRole } = useProvideDropdownItem({
|
|
1154
|
+
role,
|
|
1155
|
+
expanded,
|
|
1156
|
+
focused,
|
|
1157
|
+
hovered
|
|
1158
|
+
});
|
|
1143
1159
|
onKeyStroke("Escape", (e) => {
|
|
1144
1160
|
if (expanded.value) {
|
|
1145
1161
|
e.preventDefault();
|
|
@@ -1193,50 +1209,70 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
|
1193
1209
|
}
|
|
1194
1210
|
};
|
|
1195
1211
|
return (_ctx, _cache) => {
|
|
1196
|
-
return openBlock(), createElementBlock(
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1212
|
+
return openBlock(), createElementBlock(
|
|
1213
|
+
Fragment,
|
|
1214
|
+
null,
|
|
1215
|
+
[
|
|
1216
|
+
createVNode(unref(VvDropdownTriggerProvider), null, {
|
|
1217
|
+
default: withCtx(() => [
|
|
1218
|
+
renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ init, show, hide, toggle, expanded: unref(expanded), aria: unref(referenceAria) })))
|
|
1219
|
+
]),
|
|
1220
|
+
_: 3
|
|
1221
|
+
/* FORWARDED */
|
|
1222
|
+
}),
|
|
1223
|
+
createVNode(Transition, mergeProps({ name: _ctx.transitionName }, toHandlers(dropdownTransitionHandlers), { persisted: "" }), {
|
|
1224
|
+
default: withCtx(() => [
|
|
1225
|
+
withDirectives(createElementVNode(
|
|
1226
|
+
"div",
|
|
1227
|
+
{
|
|
1228
|
+
ref_key: "floatingEl",
|
|
1229
|
+
ref: floatingEl,
|
|
1230
|
+
style: normalizeStyle(unref(dropdownPlacement)),
|
|
1231
|
+
class: normalizeClass(unref(bemCssClasses))
|
|
1232
|
+
},
|
|
1233
|
+
[
|
|
1234
|
+
props.arrow ? (openBlock(), createElementBlock(
|
|
1235
|
+
"div",
|
|
1236
|
+
{
|
|
1237
|
+
key: 0,
|
|
1238
|
+
ref_key: "arrowEl",
|
|
1239
|
+
ref: arrowEl,
|
|
1240
|
+
style: normalizeStyle(unref(arrowPlacement)),
|
|
1241
|
+
class: "vv-dropdown__arrow"
|
|
1242
|
+
},
|
|
1243
|
+
null,
|
|
1244
|
+
4
|
|
1245
|
+
/* STYLE */
|
|
1246
|
+
)) : createCommentVNode("v-if", true),
|
|
1247
|
+
renderSlot(_ctx.$slots, "before", normalizeProps(guardReactiveProps({ expanded: unref(expanded) }))),
|
|
1248
|
+
createElementVNode("div", mergeProps(unref(attrs), {
|
|
1249
|
+
id: unref(hasId),
|
|
1250
|
+
ref_key: "listEl",
|
|
1251
|
+
ref: listEl,
|
|
1252
|
+
tabindex: !unref(expanded) ? -1 : void 0,
|
|
1253
|
+
role: unref(role),
|
|
1254
|
+
"aria-labelledby": unref(hasAriaLabelledby),
|
|
1255
|
+
class: "vv-dropdown__list"
|
|
1256
|
+
}), [
|
|
1257
|
+
renderSlot(_ctx.$slots, "items", normalizeProps(guardReactiveProps({
|
|
1258
|
+
role: unref(itemRole)
|
|
1259
|
+
})))
|
|
1260
|
+
], 16, _hoisted_1$5),
|
|
1261
|
+
renderSlot(_ctx.$slots, "after", normalizeProps(guardReactiveProps({ expanded: unref(expanded) })))
|
|
1262
|
+
],
|
|
1263
|
+
6
|
|
1264
|
+
/* CLASS, STYLE */
|
|
1265
|
+
), [
|
|
1266
|
+
[vShow, unref(expanded)]
|
|
1267
|
+
])
|
|
1268
|
+
]),
|
|
1269
|
+
_: 3
|
|
1270
|
+
/* FORWARDED */
|
|
1271
|
+
}, 16, ["name"])
|
|
1272
|
+
],
|
|
1273
|
+
64
|
|
1274
|
+
/* STABLE_FRAGMENT */
|
|
1275
|
+
);
|
|
1240
1276
|
};
|
|
1241
1277
|
}
|
|
1242
1278
|
});
|
|
@@ -1254,7 +1290,9 @@ const __default__$7 = {
|
|
|
1254
1290
|
};
|
|
1255
1291
|
const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
1256
1292
|
...__default__$7,
|
|
1293
|
+
props: VvDropdownItemProps,
|
|
1257
1294
|
setup(__props) {
|
|
1295
|
+
const props = __props;
|
|
1258
1296
|
const { role, expanded } = useInjectedDropdownItem();
|
|
1259
1297
|
const element = ref(null);
|
|
1260
1298
|
useProvideDropdownAction({ expanded });
|
|
@@ -1262,18 +1300,24 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
1262
1300
|
const { focused } = useFocus(element);
|
|
1263
1301
|
const { focused: focusedWithin } = useFocusWithin(element);
|
|
1264
1302
|
watch(hovered, (newValue) => {
|
|
1265
|
-
if (newValue) {
|
|
1303
|
+
if (newValue && props.focusOnHover) {
|
|
1266
1304
|
focused.value = true;
|
|
1267
1305
|
}
|
|
1268
1306
|
});
|
|
1269
1307
|
return (_ctx, _cache) => {
|
|
1270
|
-
return openBlock(), createElementBlock(
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1308
|
+
return openBlock(), createElementBlock(
|
|
1309
|
+
"div",
|
|
1310
|
+
mergeProps({ role: unref(role) }, {
|
|
1311
|
+
ref_key: "element",
|
|
1312
|
+
ref: element,
|
|
1313
|
+
class: ["vv-dropdown__item", { "focus-visible": unref(focused) || unref(focusedWithin) }]
|
|
1314
|
+
}),
|
|
1315
|
+
[
|
|
1316
|
+
renderSlot(_ctx.$slots, "default")
|
|
1317
|
+
],
|
|
1318
|
+
16
|
|
1319
|
+
/* FULL_PROPS */
|
|
1320
|
+
);
|
|
1277
1321
|
};
|
|
1278
1322
|
}
|
|
1279
1323
|
});
|
|
@@ -1283,21 +1327,7 @@ const __default__$6 = {
|
|
|
1283
1327
|
};
|
|
1284
1328
|
const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
1285
1329
|
...__default__$6,
|
|
1286
|
-
props:
|
|
1287
|
-
...DisabledProps,
|
|
1288
|
-
...SelectedProps,
|
|
1289
|
-
...UnselectableProps,
|
|
1290
|
-
...ModifiersProps,
|
|
1291
|
-
deselectHintLabel: {
|
|
1292
|
-
type: String
|
|
1293
|
-
},
|
|
1294
|
-
selectHintLabel: {
|
|
1295
|
-
type: String
|
|
1296
|
-
},
|
|
1297
|
-
selectedHintLabel: {
|
|
1298
|
-
type: String
|
|
1299
|
-
}
|
|
1300
|
-
},
|
|
1330
|
+
props: VvDropdownOptionProps,
|
|
1301
1331
|
setup(__props) {
|
|
1302
1332
|
const props = __props;
|
|
1303
1333
|
const { modifiers } = toRefs(props);
|
|
@@ -1317,13 +1347,15 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
|
1317
1347
|
if (!props.disabled) {
|
|
1318
1348
|
return props.selectHintLabel;
|
|
1319
1349
|
}
|
|
1350
|
+
return "";
|
|
1320
1351
|
});
|
|
1321
1352
|
return (_ctx, _cache) => {
|
|
1322
1353
|
return openBlock(), createBlock(_sfc_main$7, {
|
|
1323
1354
|
class: normalizeClass(unref(bemCssClasses)),
|
|
1324
1355
|
tabindex: _ctx.disabled ? -1 : 0,
|
|
1325
1356
|
"aria-selected": _ctx.selected,
|
|
1326
|
-
"aria-disabled": _ctx.disabled
|
|
1357
|
+
"aria-disabled": _ctx.disabled,
|
|
1358
|
+
"focus-on-hover": _ctx.focusOnHover
|
|
1327
1359
|
}, {
|
|
1328
1360
|
default: withCtx(() => [
|
|
1329
1361
|
renderSlot(_ctx.$slots, "default"),
|
|
@@ -1332,12 +1364,17 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
|
1332
1364
|
title: unref(hintLabel)
|
|
1333
1365
|
}, [
|
|
1334
1366
|
renderSlot(_ctx.$slots, "hint", normalizeProps(guardReactiveProps({ disabled: _ctx.disabled, selected: _ctx.selected, unselectable: _ctx.unselectable })), () => [
|
|
1335
|
-
createTextVNode(
|
|
1367
|
+
createTextVNode(
|
|
1368
|
+
toDisplayString(unref(hintLabel)),
|
|
1369
|
+
1
|
|
1370
|
+
/* TEXT */
|
|
1371
|
+
)
|
|
1336
1372
|
])
|
|
1337
1373
|
], 8, _hoisted_1$4)
|
|
1338
1374
|
]),
|
|
1339
1375
|
_: 3
|
|
1340
|
-
|
|
1376
|
+
/* FORWARDED */
|
|
1377
|
+
}, 8, ["class", "tabindex", "aria-selected", "aria-disabled", "focus-on-hover"]);
|
|
1341
1378
|
};
|
|
1342
1379
|
}
|
|
1343
1380
|
});
|
|
@@ -1357,7 +1394,13 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
1357
1394
|
setup(__props) {
|
|
1358
1395
|
const props = __props;
|
|
1359
1396
|
return (_ctx, _cache) => {
|
|
1360
|
-
return openBlock(), createElementBlock(
|
|
1397
|
+
return openBlock(), createElementBlock(
|
|
1398
|
+
"li",
|
|
1399
|
+
_hoisted_1$3,
|
|
1400
|
+
toDisplayString(props.label),
|
|
1401
|
+
1
|
|
1402
|
+
/* TEXT */
|
|
1403
|
+
);
|
|
1361
1404
|
};
|
|
1362
1405
|
}
|
|
1363
1406
|
});
|
|
@@ -1696,30 +1739,30 @@ function useComponentFocus(inputTemplateRef, emit) {
|
|
|
1696
1739
|
};
|
|
1697
1740
|
}
|
|
1698
1741
|
function useComponentIcon(icon, iconPosition) {
|
|
1742
|
+
const hasIcon = computed(() => {
|
|
1743
|
+
if (typeof (icon == null ? void 0 : icon.value) === "string") {
|
|
1744
|
+
return { name: icon == null ? void 0 : icon.value };
|
|
1745
|
+
}
|
|
1746
|
+
return icon == null ? void 0 : icon.value;
|
|
1747
|
+
});
|
|
1699
1748
|
const hasIconBefore = computed(
|
|
1700
|
-
() =>
|
|
1749
|
+
() => (iconPosition == null ? void 0 : iconPosition.value) === Position.before ? hasIcon.value : void 0
|
|
1701
1750
|
);
|
|
1702
1751
|
const hasIconAfter = computed(
|
|
1703
|
-
() =>
|
|
1752
|
+
() => (iconPosition == null ? void 0 : iconPosition.value) === Position.after ? hasIcon.value : void 0
|
|
1704
1753
|
);
|
|
1705
1754
|
const hasIconLeft = computed(
|
|
1706
|
-
() =>
|
|
1755
|
+
() => (iconPosition == null ? void 0 : iconPosition.value) === Side.left ? hasIcon.value : void 0
|
|
1707
1756
|
);
|
|
1708
1757
|
const hasIconRight = computed(
|
|
1709
|
-
() =>
|
|
1758
|
+
() => (iconPosition == null ? void 0 : iconPosition.value) === Side.right ? hasIcon.value : void 0
|
|
1710
1759
|
);
|
|
1711
1760
|
const hasIconTop = computed(
|
|
1712
|
-
() =>
|
|
1761
|
+
() => (iconPosition == null ? void 0 : iconPosition.value) === Side.top ? hasIcon.value : void 0
|
|
1713
1762
|
);
|
|
1714
1763
|
const hasIconBottom = computed(
|
|
1715
|
-
() =>
|
|
1764
|
+
() => (iconPosition == null ? void 0 : iconPosition.value) === Side.bottom ? hasIcon.value : void 0
|
|
1716
1765
|
);
|
|
1717
|
-
const hasIcon = computed(() => {
|
|
1718
|
-
if (typeof (icon == null ? void 0 : icon.value) === "string") {
|
|
1719
|
-
return { name: icon == null ? void 0 : icon.value };
|
|
1720
|
-
}
|
|
1721
|
-
return icon == null ? void 0 : icon.value;
|
|
1722
|
-
});
|
|
1723
1766
|
return {
|
|
1724
1767
|
hasIcon,
|
|
1725
1768
|
hasIconLeft,
|
|
@@ -1785,8 +1828,9 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
1785
1828
|
...__default__$4,
|
|
1786
1829
|
props: VvSelectProps,
|
|
1787
1830
|
emits: VvSelectEmits,
|
|
1788
|
-
setup(__props, { emit }) {
|
|
1831
|
+
setup(__props, { emit: __emit }) {
|
|
1789
1832
|
const props = __props;
|
|
1833
|
+
const emit = __emit;
|
|
1790
1834
|
const slots = useSlots();
|
|
1791
1835
|
const propsDefaults = useDefaults(
|
|
1792
1836
|
"VvSelect",
|
|
@@ -1822,10 +1866,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
1822
1866
|
focused.value = true;
|
|
1823
1867
|
}
|
|
1824
1868
|
});
|
|
1825
|
-
const {
|
|
1826
|
-
icon,
|
|
1827
|
-
iconPosition
|
|
1828
|
-
);
|
|
1869
|
+
const { hasIconBefore, hasIconAfter } = useComponentIcon(icon, iconPosition);
|
|
1829
1870
|
const isDirty = computed(() => !isEmpty(props.modelValue));
|
|
1830
1871
|
const isDisabled = computed(() => props.disabled || props.readonly);
|
|
1831
1872
|
const hasTabindex = computed(() => {
|
|
@@ -1849,8 +1890,8 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
1849
1890
|
loading: loading.value,
|
|
1850
1891
|
disabled: disabled.value,
|
|
1851
1892
|
readonly: readonly.value,
|
|
1852
|
-
"icon-before": hasIconBefore.value,
|
|
1853
|
-
"icon-after": hasIconAfter.value,
|
|
1893
|
+
"icon-before": hasIconBefore.value !== void 0,
|
|
1894
|
+
"icon-after": hasIconAfter.value !== void 0,
|
|
1854
1895
|
dirty: isDirty.value,
|
|
1855
1896
|
focus: focused.value,
|
|
1856
1897
|
floating: floating.value,
|
|
@@ -1899,101 +1940,134 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
1899
1940
|
return option && option.options && option.options.length > 0;
|
|
1900
1941
|
};
|
|
1901
1942
|
return (_ctx, _cache) => {
|
|
1902
|
-
return openBlock(), createElementBlock(
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
},
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1943
|
+
return openBlock(), createElementBlock(
|
|
1944
|
+
"div",
|
|
1945
|
+
{
|
|
1946
|
+
class: normalizeClass(unref(bemCssClasses))
|
|
1947
|
+
},
|
|
1948
|
+
[
|
|
1949
|
+
_ctx.label ? (openBlock(), createElementBlock("label", {
|
|
1950
|
+
key: 0,
|
|
1951
|
+
for: unref(hasId)
|
|
1952
|
+
}, toDisplayString(_ctx.label), 9, _hoisted_1$2)) : createCommentVNode("v-if", true),
|
|
1953
|
+
createElementVNode("div", _hoisted_2$2, [
|
|
1954
|
+
_ctx.$slots.before ? (openBlock(), createElementBlock("div", _hoisted_3$1, [
|
|
1955
|
+
renderSlot(_ctx.$slots, "before", normalizeProps(guardReactiveProps(unref(slotProps))))
|
|
1956
|
+
])) : createCommentVNode("v-if", true),
|
|
1957
|
+
createElementVNode("div", _hoisted_4$1, [
|
|
1958
|
+
unref(hasIconBefore) ? (openBlock(), createBlock(
|
|
1959
|
+
_sfc_main$9,
|
|
1960
|
+
mergeProps({ key: 0 }, unref(hasIconBefore), { class: "vv-select__icon" }),
|
|
1961
|
+
null,
|
|
1962
|
+
16
|
|
1963
|
+
/* FULL_PROPS */
|
|
1964
|
+
)) : createCommentVNode("v-if", true),
|
|
1965
|
+
withDirectives(createElementVNode("select", mergeProps({
|
|
1966
|
+
id: unref(hasId),
|
|
1967
|
+
ref_key: "select",
|
|
1968
|
+
ref: select,
|
|
1969
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(localModelValue) ? localModelValue.value = $event : null)
|
|
1970
|
+
}, unref(hasAttrs)), [
|
|
1971
|
+
_ctx.placeholder ? (openBlock(), createElementBlock("option", {
|
|
1972
|
+
key: 0,
|
|
1973
|
+
value: void 0,
|
|
1974
|
+
disabled: !_ctx.unselectable,
|
|
1975
|
+
hidden: !_ctx.unselectable
|
|
1976
|
+
}, toDisplayString(_ctx.placeholder), 9, _hoisted_6$1)) : createCommentVNode("v-if", true),
|
|
1977
|
+
(openBlock(true), createElementBlock(
|
|
1978
|
+
Fragment,
|
|
1979
|
+
null,
|
|
1980
|
+
renderList(_ctx.options, (option, index) => {
|
|
1981
|
+
return openBlock(), createElementBlock(
|
|
1982
|
+
Fragment,
|
|
1983
|
+
null,
|
|
1984
|
+
[
|
|
1985
|
+
!isGroup(option) ? (openBlock(), createElementBlock("option", {
|
|
1986
|
+
key: index,
|
|
1987
|
+
disabled: unref(isOptionDisabled)(option),
|
|
1988
|
+
value: unref(getOptionValue)(option)
|
|
1989
|
+
}, toDisplayString(unref(getOptionLabel)(option)), 9, _hoisted_7$1)) : (openBlock(), createElementBlock("optgroup", {
|
|
1990
|
+
key: `group-${index}`,
|
|
1991
|
+
disabled: unref(isOptionDisabled)(option),
|
|
1992
|
+
label: unref(getOptionLabel)(option)
|
|
1993
|
+
}, [
|
|
1994
|
+
(openBlock(true), createElementBlock(
|
|
1995
|
+
Fragment,
|
|
1996
|
+
null,
|
|
1997
|
+
renderList(unref(getOptionGrouped)(option), (item, i) => {
|
|
1998
|
+
return openBlock(), createElementBlock("option", {
|
|
1999
|
+
key: `group-${index}-item-${i}`,
|
|
2000
|
+
disabled: unref(isOptionDisabled)(item),
|
|
2001
|
+
value: unref(getOptionValue)(item)
|
|
2002
|
+
}, toDisplayString(unref(getOptionLabel)(item)), 9, _hoisted_9$1);
|
|
2003
|
+
}),
|
|
2004
|
+
128
|
|
2005
|
+
/* KEYED_FRAGMENT */
|
|
2006
|
+
))
|
|
2007
|
+
], 8, _hoisted_8$1))
|
|
2008
|
+
],
|
|
2009
|
+
64
|
|
2010
|
+
/* STABLE_FRAGMENT */
|
|
2011
|
+
);
|
|
2012
|
+
}),
|
|
2013
|
+
256
|
|
2014
|
+
/* UNKEYED_FRAGMENT */
|
|
2015
|
+
))
|
|
2016
|
+
], 16, _hoisted_5$1), [
|
|
2017
|
+
[vModelSelect, unref(localModelValue)]
|
|
2018
|
+
]),
|
|
2019
|
+
unref(hasIconAfter) ? (openBlock(), createBlock(
|
|
2020
|
+
_sfc_main$9,
|
|
2021
|
+
mergeProps({ key: 1 }, unref(hasIconAfter), { class: "vv-select__icon vv-select__icon-after" }),
|
|
2022
|
+
null,
|
|
2023
|
+
16
|
|
2024
|
+
/* FULL_PROPS */
|
|
2025
|
+
)) : createCommentVNode("v-if", true)
|
|
1953
2026
|
]),
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
}, unref(hasIcon)), null, 16)) : createCommentVNode("", true)
|
|
2027
|
+
_ctx.$slots.after ? (openBlock(), createElementBlock("div", _hoisted_10, [
|
|
2028
|
+
renderSlot(_ctx.$slots, "after", normalizeProps(guardReactiveProps(unref(slotProps))))
|
|
2029
|
+
])) : createCommentVNode("v-if", true)
|
|
1958
2030
|
]),
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
]
|
|
1996
|
-
|
|
2031
|
+
createVNode(unref(HintSlot), {
|
|
2032
|
+
id: unref(hasHintId),
|
|
2033
|
+
class: "vv-select__hint"
|
|
2034
|
+
}, createSlots({
|
|
2035
|
+
_: 2
|
|
2036
|
+
/* DYNAMIC */
|
|
2037
|
+
}, [
|
|
2038
|
+
_ctx.$slots.hint ? {
|
|
2039
|
+
name: "hint",
|
|
2040
|
+
fn: withCtx(() => [
|
|
2041
|
+
renderSlot(_ctx.$slots, "hint", normalizeProps(guardReactiveProps(unref(hintSlotScope))))
|
|
2042
|
+
]),
|
|
2043
|
+
key: "0"
|
|
2044
|
+
} : void 0,
|
|
2045
|
+
_ctx.$slots.loading ? {
|
|
2046
|
+
name: "loading",
|
|
2047
|
+
fn: withCtx(() => [
|
|
2048
|
+
renderSlot(_ctx.$slots, "loading", normalizeProps(guardReactiveProps(unref(hintSlotScope))))
|
|
2049
|
+
]),
|
|
2050
|
+
key: "1"
|
|
2051
|
+
} : void 0,
|
|
2052
|
+
_ctx.$slots.valid ? {
|
|
2053
|
+
name: "valid",
|
|
2054
|
+
fn: withCtx(() => [
|
|
2055
|
+
renderSlot(_ctx.$slots, "valid", normalizeProps(guardReactiveProps(unref(hintSlotScope))))
|
|
2056
|
+
]),
|
|
2057
|
+
key: "2"
|
|
2058
|
+
} : void 0,
|
|
2059
|
+
_ctx.$slots.invalid ? {
|
|
2060
|
+
name: "invalid",
|
|
2061
|
+
fn: withCtx(() => [
|
|
2062
|
+
renderSlot(_ctx.$slots, "invalid", normalizeProps(guardReactiveProps(unref(hintSlotScope))))
|
|
2063
|
+
]),
|
|
2064
|
+
key: "3"
|
|
2065
|
+
} : void 0
|
|
2066
|
+
]), 1032, ["id"])
|
|
2067
|
+
],
|
|
2068
|
+
2
|
|
2069
|
+
/* CLASS */
|
|
2070
|
+
);
|
|
1997
2071
|
};
|
|
1998
2072
|
}
|
|
1999
2073
|
});
|
|
@@ -2012,14 +2086,24 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
2012
2086
|
const { modifiers } = toRefs(props);
|
|
2013
2087
|
const bemCssClasses = useModifiers("vv-badge", modifiers);
|
|
2014
2088
|
return (_ctx, _cache) => {
|
|
2015
|
-
return openBlock(), createElementBlock(
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2089
|
+
return openBlock(), createElementBlock(
|
|
2090
|
+
"span",
|
|
2091
|
+
{
|
|
2092
|
+
class: normalizeClass(unref(bemCssClasses)),
|
|
2093
|
+
role: "status"
|
|
2094
|
+
},
|
|
2095
|
+
[
|
|
2096
|
+
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
2097
|
+
createTextVNode(
|
|
2098
|
+
toDisplayString(_ctx.value),
|
|
2099
|
+
1
|
|
2100
|
+
/* TEXT */
|
|
2101
|
+
)
|
|
2102
|
+
])
|
|
2103
|
+
],
|
|
2104
|
+
2
|
|
2105
|
+
/* CLASS */
|
|
2106
|
+
);
|
|
2023
2107
|
};
|
|
2024
2108
|
}
|
|
2025
2109
|
});
|
|
@@ -2032,8 +2116,10 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
2032
2116
|
...__default__$2,
|
|
2033
2117
|
props: VvActionProps,
|
|
2034
2118
|
emits: VvActionEvents,
|
|
2035
|
-
setup(__props, { expose: __expose, emit }) {
|
|
2119
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
2036
2120
|
const props = __props;
|
|
2121
|
+
const emit = __emit;
|
|
2122
|
+
const instance = getCurrentInstance();
|
|
2037
2123
|
const volver = useVolver();
|
|
2038
2124
|
const element = ref(null);
|
|
2039
2125
|
__expose({ $el: element });
|
|
@@ -2064,7 +2150,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
2064
2150
|
case props.href !== void 0:
|
|
2065
2151
|
return ActionTag.a;
|
|
2066
2152
|
default:
|
|
2067
|
-
return
|
|
2153
|
+
return props.defaultTag;
|
|
2068
2154
|
}
|
|
2069
2155
|
});
|
|
2070
2156
|
const hasProps = computed(() => {
|
|
@@ -2089,29 +2175,43 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
2089
2175
|
to: props.to,
|
|
2090
2176
|
target: props.target
|
|
2091
2177
|
};
|
|
2092
|
-
|
|
2178
|
+
case ActionTag.button:
|
|
2093
2179
|
return {
|
|
2094
2180
|
...toReturn,
|
|
2095
2181
|
type: props.type,
|
|
2096
2182
|
disabled: props.disabled
|
|
2097
2183
|
};
|
|
2184
|
+
default:
|
|
2185
|
+
return toReturn;
|
|
2098
2186
|
}
|
|
2099
2187
|
});
|
|
2100
2188
|
const onClick = (e) => {
|
|
2189
|
+
var _a;
|
|
2101
2190
|
if (props.disabled) {
|
|
2102
2191
|
e.preventDefault();
|
|
2103
2192
|
return;
|
|
2104
2193
|
}
|
|
2194
|
+
if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onClick) {
|
|
2195
|
+
emit("click", e);
|
|
2196
|
+
return;
|
|
2197
|
+
}
|
|
2105
2198
|
dropdownEventBus == null ? void 0 : dropdownEventBus.emit("click", e);
|
|
2106
|
-
emit("click", e);
|
|
2107
2199
|
};
|
|
2108
2200
|
const onMouseover = (e) => {
|
|
2201
|
+
var _a;
|
|
2202
|
+
if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onMouseover) {
|
|
2203
|
+
emit("mouseover", e);
|
|
2204
|
+
return;
|
|
2205
|
+
}
|
|
2109
2206
|
dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseover", e);
|
|
2110
|
-
emit("mouseover", e);
|
|
2111
2207
|
};
|
|
2112
2208
|
const onMouseleave = (e) => {
|
|
2209
|
+
var _a;
|
|
2210
|
+
if ((_a = instance == null ? void 0 : instance.vnode.props) == null ? void 0 : _a.onMouseleave) {
|
|
2211
|
+
emit("mouseleave", e);
|
|
2212
|
+
return;
|
|
2213
|
+
}
|
|
2113
2214
|
dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseleave", e);
|
|
2114
|
-
emit("mouseleave", e);
|
|
2115
2215
|
};
|
|
2116
2216
|
return (_ctx, _cache) => {
|
|
2117
2217
|
return openBlock(), createBlock(resolveDynamicComponent(unref(hasTag)), mergeProps(unref(hasProps), {
|
|
@@ -2129,23 +2229,28 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
2129
2229
|
}), {
|
|
2130
2230
|
default: withCtx(() => [
|
|
2131
2231
|
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
2132
|
-
createTextVNode(
|
|
2232
|
+
createTextVNode(
|
|
2233
|
+
toDisplayString(_ctx.label),
|
|
2234
|
+
1
|
|
2235
|
+
/* TEXT */
|
|
2236
|
+
)
|
|
2133
2237
|
])
|
|
2134
2238
|
]),
|
|
2135
2239
|
_: 3
|
|
2240
|
+
/* FORWARDED */
|
|
2136
2241
|
}, 16, ["class"]);
|
|
2137
2242
|
};
|
|
2138
2243
|
}
|
|
2139
2244
|
});
|
|
2140
2245
|
function useInjectedGroupState(groupKey) {
|
|
2141
2246
|
const group = inject(groupKey, void 0);
|
|
2142
|
-
const isInGroup = computed(() =>
|
|
2247
|
+
const isInGroup = computed(() => group !== void 0);
|
|
2143
2248
|
function getGroupOrLocalRef(propName, props, emit) {
|
|
2144
|
-
|
|
2145
|
-
|
|
2249
|
+
const groupPropValue = group == null ? void 0 : group[propName];
|
|
2250
|
+
if (groupPropValue) {
|
|
2146
2251
|
return computed({
|
|
2147
2252
|
get() {
|
|
2148
|
-
return groupPropValue
|
|
2253
|
+
return groupPropValue.value;
|
|
2149
2254
|
},
|
|
2150
2255
|
set(value) {
|
|
2151
2256
|
groupPropValue.value = value;
|
|
@@ -2158,8 +2263,9 @@ function useInjectedGroupState(groupKey) {
|
|
|
2158
2263
|
return propRef.value;
|
|
2159
2264
|
},
|
|
2160
2265
|
set(value) {
|
|
2161
|
-
if (emit)
|
|
2266
|
+
if (emit) {
|
|
2162
2267
|
emit(`update:${propName}`, value);
|
|
2268
|
+
}
|
|
2163
2269
|
}
|
|
2164
2270
|
});
|
|
2165
2271
|
}
|
|
@@ -2176,10 +2282,7 @@ const VvButtonProps = {
|
|
|
2176
2282
|
...ModifiersProps,
|
|
2177
2283
|
...UnselectableProps,
|
|
2178
2284
|
...LoadingProps,
|
|
2179
|
-
|
|
2180
|
-
* Button icon
|
|
2181
|
-
*/
|
|
2182
|
-
icon: [String, Object],
|
|
2285
|
+
...IconProps,
|
|
2183
2286
|
/**
|
|
2184
2287
|
* Button icon position
|
|
2185
2288
|
*/
|
|
@@ -2226,14 +2329,11 @@ function useGroupProps(props, emit) {
|
|
|
2226
2329
|
const { id, iconPosition, icon, label, pressed } = toRefs(props);
|
|
2227
2330
|
const modelValue = getGroupOrLocalRef("modelValue", props, emit);
|
|
2228
2331
|
const toggle = getGroupOrLocalRef("toggle", props);
|
|
2229
|
-
const unselectable = getGroupOrLocalRef(
|
|
2230
|
-
|
|
2231
|
-
props
|
|
2232
|
-
);
|
|
2233
|
-
const multiple = computed(() => (group == null ? void 0 : group.value.multiple.value) ?? false);
|
|
2332
|
+
const unselectable = getGroupOrLocalRef("unselectable", props);
|
|
2333
|
+
const multiple = computed(() => (group == null ? void 0 : group.multiple.value) ?? false);
|
|
2234
2334
|
const modifiers = computed(() => {
|
|
2235
2335
|
let localModifiers = props.modifiers;
|
|
2236
|
-
let groupModifiers = group == null ? void 0 : group.
|
|
2336
|
+
let groupModifiers = group == null ? void 0 : group.modifiers.value;
|
|
2237
2337
|
const toReturn = /* @__PURE__ */ new Set();
|
|
2238
2338
|
if (localModifiers) {
|
|
2239
2339
|
if (!Array.isArray(localModifiers)) {
|
|
@@ -2250,10 +2350,7 @@ function useGroupProps(props, emit) {
|
|
|
2250
2350
|
return Array.from(toReturn);
|
|
2251
2351
|
});
|
|
2252
2352
|
const disabled = computed(
|
|
2253
|
-
() =>
|
|
2254
|
-
var _a;
|
|
2255
|
-
return Boolean(props.disabled || ((_a = group == null ? void 0 : group.value) == null ? void 0 : _a.disabled.value));
|
|
2256
|
-
}
|
|
2353
|
+
() => Boolean(props.disabled || (group == null ? void 0 : group.disabled.value))
|
|
2257
2354
|
);
|
|
2258
2355
|
return {
|
|
2259
2356
|
// group props
|
|
@@ -2282,16 +2379,18 @@ const _hoisted_2$1 = {
|
|
|
2282
2379
|
class: "vv-button__label"
|
|
2283
2380
|
};
|
|
2284
2381
|
const __default__$1 = {
|
|
2285
|
-
name: "VvButton"
|
|
2382
|
+
name: "VvButton",
|
|
2383
|
+
inheritAttrs: false
|
|
2286
2384
|
};
|
|
2287
2385
|
const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
2288
2386
|
...__default__$1,
|
|
2289
2387
|
props: VvButtonProps,
|
|
2290
2388
|
emits: VvButtonEvents,
|
|
2291
|
-
setup(__props, { expose: __expose, emit }) {
|
|
2389
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
2292
2390
|
const props = __props;
|
|
2293
2391
|
const attrs = useAttrs();
|
|
2294
2392
|
const slots = useSlots();
|
|
2393
|
+
const emit = __emit;
|
|
2295
2394
|
const {
|
|
2296
2395
|
id,
|
|
2297
2396
|
modifiers,
|
|
@@ -2335,12 +2434,18 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2335
2434
|
)
|
|
2336
2435
|
}))
|
|
2337
2436
|
);
|
|
2338
|
-
const
|
|
2339
|
-
() => typeof (icon == null ? void 0 : icon.value) === "string" ? { name: icon == null ? void 0 : icon.value } : icon == null ? void 0 : icon.value
|
|
2340
|
-
);
|
|
2437
|
+
const { hasIcon } = useComponentIcon(icon);
|
|
2341
2438
|
const toggleValue = computed(() => {
|
|
2342
2439
|
return props.value !== void 0 ? props.value : name.value;
|
|
2343
2440
|
});
|
|
2441
|
+
const hasListeners = computed(() => {
|
|
2442
|
+
if (!toggle.value) {
|
|
2443
|
+
return void 0;
|
|
2444
|
+
}
|
|
2445
|
+
return {
|
|
2446
|
+
onClick
|
|
2447
|
+
};
|
|
2448
|
+
});
|
|
2344
2449
|
const onClick = () => {
|
|
2345
2450
|
if (toggle.value) {
|
|
2346
2451
|
if (Array.isArray(modelValue.value)) {
|
|
@@ -2364,6 +2469,8 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2364
2469
|
};
|
|
2365
2470
|
return (_ctx, _cache) => {
|
|
2366
2471
|
return openBlock(), createBlock(_sfc_main$2, mergeProps({
|
|
2472
|
+
...unref(attrs),
|
|
2473
|
+
...unref(hasListeners),
|
|
2367
2474
|
disabled: unref(disabled),
|
|
2368
2475
|
pressed: unref(pressed),
|
|
2369
2476
|
active: _ctx.active,
|
|
@@ -2377,8 +2484,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2377
2484
|
id: unref(hasId),
|
|
2378
2485
|
ref_key: "element",
|
|
2379
2486
|
ref: element,
|
|
2380
|
-
class: unref(bemCssClasses)
|
|
2381
|
-
onClick
|
|
2487
|
+
class: unref(bemCssClasses)
|
|
2382
2488
|
}), {
|
|
2383
2489
|
default: withCtx(() => [
|
|
2384
2490
|
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
@@ -2387,24 +2493,44 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2387
2493
|
key: 0,
|
|
2388
2494
|
class: "vv-button__loading-icon",
|
|
2389
2495
|
name: _ctx.loadingIcon
|
|
2390
|
-
}, null, 8, ["name"])) : createCommentVNode("", true),
|
|
2391
|
-
_ctx.loadingLabel ? (openBlock(), createElementBlock(
|
|
2392
|
-
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2496
|
+
}, null, 8, ["name"])) : createCommentVNode("v-if", true),
|
|
2497
|
+
_ctx.loadingLabel ? (openBlock(), createElementBlock(
|
|
2498
|
+
"span",
|
|
2499
|
+
_hoisted_1$1,
|
|
2500
|
+
toDisplayString(_ctx.loadingLabel),
|
|
2501
|
+
1
|
|
2502
|
+
/* TEXT */
|
|
2503
|
+
)) : createCommentVNode("v-if", true)
|
|
2504
|
+
]) : (openBlock(), createElementBlock(
|
|
2505
|
+
Fragment,
|
|
2506
|
+
{ key: 1 },
|
|
2507
|
+
[
|
|
2508
|
+
renderSlot(_ctx.$slots, "before"),
|
|
2509
|
+
unref(hasIcon) ? (openBlock(), createBlock(
|
|
2510
|
+
_sfc_main$9,
|
|
2511
|
+
mergeProps({ key: 0 }, unref(hasIcon), { class: "vv-button__icon" }),
|
|
2512
|
+
null,
|
|
2513
|
+
16
|
|
2514
|
+
/* FULL_PROPS */
|
|
2515
|
+
)) : createCommentVNode("v-if", true),
|
|
2516
|
+
unref(label) ? (openBlock(), createElementBlock("span", _hoisted_2$1, [
|
|
2517
|
+
renderSlot(_ctx.$slots, "label", {}, () => [
|
|
2518
|
+
createTextVNode(
|
|
2519
|
+
toDisplayString(unref(label)),
|
|
2520
|
+
1
|
|
2521
|
+
/* TEXT */
|
|
2522
|
+
)
|
|
2523
|
+
])
|
|
2524
|
+
])) : createCommentVNode("v-if", true),
|
|
2525
|
+
renderSlot(_ctx.$slots, "after")
|
|
2526
|
+
],
|
|
2527
|
+
64
|
|
2528
|
+
/* STABLE_FRAGMENT */
|
|
2529
|
+
))
|
|
2405
2530
|
])
|
|
2406
2531
|
]),
|
|
2407
2532
|
_: 3
|
|
2533
|
+
/* FORWARDED */
|
|
2408
2534
|
}, 16, ["id", "class"]);
|
|
2409
2535
|
};
|
|
2410
2536
|
}
|
|
@@ -2440,8 +2566,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
2440
2566
|
...__default__,
|
|
2441
2567
|
props: VvComboboxProps,
|
|
2442
2568
|
emits: VvComboboxEvents,
|
|
2443
|
-
setup(__props, { emit }) {
|
|
2569
|
+
setup(__props, { emit: __emit }) {
|
|
2444
2570
|
const props = __props;
|
|
2571
|
+
const emit = __emit;
|
|
2445
2572
|
const slots = useSlots();
|
|
2446
2573
|
const propsDefaults = useDefaults(
|
|
2447
2574
|
"VvCombobox",
|
|
@@ -2487,10 +2614,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
2487
2614
|
searchText,
|
|
2488
2615
|
computed(() => Number(props.debounceSearch))
|
|
2489
2616
|
);
|
|
2490
|
-
watch(
|
|
2491
|
-
debouncedSearchText
|
|
2492
|
-
|
|
2493
|
-
);
|
|
2617
|
+
watch(debouncedSearchText, () => {
|
|
2618
|
+
emit("update:search", debouncedSearchText.value);
|
|
2619
|
+
emit("change:search", debouncedSearchText.value);
|
|
2620
|
+
});
|
|
2494
2621
|
const expanded = ref(false);
|
|
2495
2622
|
const toggleExpanded = () => {
|
|
2496
2623
|
if (props.disabled || props.readonly)
|
|
@@ -2541,10 +2668,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
2541
2668
|
const localLoading = ref(false);
|
|
2542
2669
|
const isLoading = computed(() => localLoading.value || loading.value);
|
|
2543
2670
|
const dropdownEl = ref();
|
|
2544
|
-
const {
|
|
2545
|
-
icon,
|
|
2546
|
-
iconPosition
|
|
2547
|
-
);
|
|
2671
|
+
const { hasIconBefore, hasIconAfter } = useComponentIcon(icon, iconPosition);
|
|
2548
2672
|
const isDirty = computed(() => !isEmpty(props.modelValue));
|
|
2549
2673
|
const hasTabindex = computed(() => {
|
|
2550
2674
|
return disabled.value || readonly.value ? -1 : props.tabindex;
|
|
@@ -2556,12 +2680,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
2556
2680
|
disabled: disabled.value,
|
|
2557
2681
|
loading: isLoading.value,
|
|
2558
2682
|
readonly: readonly.value,
|
|
2559
|
-
"icon-before":
|
|
2560
|
-
"icon-after":
|
|
2683
|
+
"icon-before": hasIconBefore.value !== void 0,
|
|
2684
|
+
"icon-after": hasIconAfter.value !== void 0,
|
|
2561
2685
|
valid: valid.value,
|
|
2562
2686
|
invalid: invalid.value,
|
|
2563
2687
|
dirty: isDirty.value,
|
|
2564
|
-
focus: focused.value,
|
|
2688
|
+
focus: focused.value || focusedWithin.value || expanded.value,
|
|
2565
2689
|
floating: floating.value,
|
|
2566
2690
|
badges: props.badges
|
|
2567
2691
|
}))
|
|
@@ -2720,208 +2844,303 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
2720
2844
|
key: 0,
|
|
2721
2845
|
id: unref(hasLabelId),
|
|
2722
2846
|
for: unref(propsDefaults).searchable ? unref(hasSearchId) : void 0
|
|
2723
|
-
}, toDisplayString(_ctx.label), 9, _hoisted_2)) : createCommentVNode("", true),
|
|
2724
|
-
createElementVNode(
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
|
|
2749
|
-
|
|
2750
|
-
|
|
2751
|
-
|
|
2752
|
-
|
|
2753
|
-
|
|
2754
|
-
"
|
|
2755
|
-
|
|
2756
|
-
|
|
2757
|
-
|
|
2758
|
-
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
unref(
|
|
2763
|
-
|
|
2764
|
-
|
|
2765
|
-
|
|
2766
|
-
|
|
2767
|
-
|
|
2768
|
-
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2799
|
-
|
|
2800
|
-
|
|
2801
|
-
|
|
2802
|
-
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2808
|
-
|
|
2809
|
-
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
|
|
2813
|
-
|
|
2814
|
-
|
|
2815
|
-
|
|
2816
|
-
|
|
2817
|
-
|
|
2818
|
-
|
|
2819
|
-
|
|
2820
|
-
|
|
2821
|
-
|
|
2822
|
-
|
|
2823
|
-
|
|
2824
|
-
|
|
2825
|
-
selected: isOptionSelected(item),
|
|
2826
|
-
disabled: unref(isOptionDisabled)(item)
|
|
2827
|
-
})), () => [
|
|
2828
|
-
createTextVNode(toDisplayString(unref(getOptionLabel)(item)), 1)
|
|
2829
|
-
])
|
|
2830
|
-
]),
|
|
2831
|
-
_: 2
|
|
2832
|
-
}, 1040, ["onClickPassive"]);
|
|
2833
|
-
}), 128))
|
|
2834
|
-
], 64)) : (openBlock(), createBlock(_sfc_main$6, mergeProps({ key: 1 }, {
|
|
2835
|
-
selected: isOptionSelected(option),
|
|
2836
|
-
disabled: unref(isOptionDisabled)(option),
|
|
2837
|
-
unselectable: _ctx.unselectable,
|
|
2838
|
-
deselectHintLabel: unref(propsDefaults).deselectHintLabel,
|
|
2839
|
-
selectHintLabel: unref(propsDefaults).selectHintLabel,
|
|
2840
|
-
selectedHintLabel: unref(propsDefaults).selectedHintLabel
|
|
2841
|
-
}, {
|
|
2842
|
-
class: "vv-dropdown-option",
|
|
2843
|
-
onClickPassive: ($event) => onInput(option)
|
|
2844
|
-
}), {
|
|
2845
|
-
default: withCtx(() => [
|
|
2846
|
-
renderSlot(_ctx.$slots, "option", normalizeProps(guardReactiveProps({
|
|
2847
|
-
option,
|
|
2848
|
-
selectedOptions: unref(selectedOptions),
|
|
2849
|
-
selected: isOptionSelected(option),
|
|
2850
|
-
disabled: unref(isOptionDisabled)(option)
|
|
2851
|
-
})), () => [
|
|
2852
|
-
createTextVNode(toDisplayString(unref(getOptionLabel)(option)), 1)
|
|
2853
|
-
])
|
|
2854
|
-
]),
|
|
2855
|
-
_: 2
|
|
2856
|
-
}, 1040, ["onClickPassive"]))
|
|
2857
|
-
], 64);
|
|
2858
|
-
}), 128)) : !_ctx.options.length ? (openBlock(), createBlock(_sfc_main$6, {
|
|
2859
|
-
key: 1,
|
|
2860
|
-
modifiers: "inert"
|
|
2861
|
-
}, {
|
|
2862
|
-
default: withCtx(() => [
|
|
2863
|
-
renderSlot(_ctx.$slots, "no-options", {}, () => [
|
|
2864
|
-
createTextVNode(toDisplayString(unref(propsDefaults).noOptionsLabel), 1)
|
|
2865
|
-
])
|
|
2866
|
-
]),
|
|
2867
|
-
_: 3
|
|
2868
|
-
})) : !unref(disabled) ? (openBlock(), createBlock(_sfc_main$6, {
|
|
2869
|
-
key: 2,
|
|
2870
|
-
modifiers: "inert"
|
|
2871
|
-
}, {
|
|
2872
|
-
default: withCtx(() => [
|
|
2873
|
-
renderSlot(_ctx.$slots, "no-results", {}, () => [
|
|
2874
|
-
createTextVNode(toDisplayString(unref(propsDefaults).noResultsLabel), 1)
|
|
2847
|
+
}, toDisplayString(_ctx.label), 9, _hoisted_2)) : createCommentVNode("v-if", true),
|
|
2848
|
+
createElementVNode(
|
|
2849
|
+
"div",
|
|
2850
|
+
{
|
|
2851
|
+
ref_key: "wrapperEl",
|
|
2852
|
+
ref: wrapperEl,
|
|
2853
|
+
class: "vv-select__wrapper"
|
|
2854
|
+
},
|
|
2855
|
+
[
|
|
2856
|
+
createVNode(_sfc_main$8, mergeProps({
|
|
2857
|
+
ref_key: "dropdownEl",
|
|
2858
|
+
ref: dropdownEl,
|
|
2859
|
+
modelValue: unref(expanded),
|
|
2860
|
+
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => isRef(expanded) ? expanded.value = $event : null)
|
|
2861
|
+
}, unref(dropdownProps), {
|
|
2862
|
+
role: unref(DropdownRole).listbox,
|
|
2863
|
+
onAfterExpand,
|
|
2864
|
+
onAfterCollapse
|
|
2865
|
+
}), createSlots({
|
|
2866
|
+
default: withCtx(({ aria }) => [
|
|
2867
|
+
_ctx.$slots.before ? (openBlock(), createElementBlock("div", _hoisted_4, [
|
|
2868
|
+
renderSlot(_ctx.$slots, "before", normalizeProps(guardReactiveProps(unref(slotProps))))
|
|
2869
|
+
])) : createCommentVNode("v-if", true),
|
|
2870
|
+
createElementVNode("div", _hoisted_5, [
|
|
2871
|
+
unref(hasIconBefore) ? (openBlock(), createBlock(
|
|
2872
|
+
_sfc_main$9,
|
|
2873
|
+
mergeProps({ key: 0 }, unref(hasIconBefore), { class: "vv-select__icon" }),
|
|
2874
|
+
null,
|
|
2875
|
+
16
|
|
2876
|
+
/* FULL_PROPS */
|
|
2877
|
+
)) : createCommentVNode("v-if", true),
|
|
2878
|
+
createElementVNode("div", mergeProps({
|
|
2879
|
+
ref_key: "inputEl",
|
|
2880
|
+
ref: inputEl
|
|
2881
|
+
}, aria, {
|
|
2882
|
+
class: "vv-select__input",
|
|
2883
|
+
role: "combobox",
|
|
2884
|
+
"aria-expanded": unref(expanded),
|
|
2885
|
+
"aria-labelledby": unref(hasLabelId),
|
|
2886
|
+
"aria-describedby": unref(hasHintLabelOrSlot) ? unref(hasHintId) : void 0,
|
|
2887
|
+
"aria-errormessage": unref(hasInvalidLabelOrSlot) ? unref(hasHintId) : void 0,
|
|
2888
|
+
tabindex: unref(hasTabindex),
|
|
2889
|
+
onClickPassive: onClickInput
|
|
2890
|
+
}), [
|
|
2891
|
+
renderSlot(_ctx.$slots, "value", normalizeProps(guardReactiveProps({ selectedOptions: unref(selectedOptions), onInput })), () => [
|
|
2892
|
+
unref(hasValue) ? (openBlock(), createElementBlock(
|
|
2893
|
+
Fragment,
|
|
2894
|
+
{ key: 0 },
|
|
2895
|
+
[
|
|
2896
|
+
!_ctx.badges ? (openBlock(), createElementBlock(
|
|
2897
|
+
"div",
|
|
2898
|
+
_hoisted_7,
|
|
2899
|
+
toDisplayString(unref(hasValue)),
|
|
2900
|
+
1
|
|
2901
|
+
/* TEXT */
|
|
2902
|
+
)) : (openBlock(true), createElementBlock(
|
|
2903
|
+
Fragment,
|
|
2904
|
+
{ key: 1 },
|
|
2905
|
+
renderList(unref(selectedOptions), (option, index) => {
|
|
2906
|
+
return openBlock(), createBlock(_sfc_main$3, {
|
|
2907
|
+
key: index,
|
|
2908
|
+
modifiers: _ctx.badgeModifiers,
|
|
2909
|
+
class: "vv-select__badge"
|
|
2910
|
+
}, {
|
|
2911
|
+
default: withCtx(() => [
|
|
2912
|
+
createTextVNode(
|
|
2913
|
+
toDisplayString(unref(getOptionLabel)(option)) + " ",
|
|
2914
|
+
1
|
|
2915
|
+
/* TEXT */
|
|
2916
|
+
),
|
|
2917
|
+
_ctx.unselectable && !unref(readonly) && !unref(disabled) ? (openBlock(), createElementBlock("button", {
|
|
2918
|
+
key: 0,
|
|
2919
|
+
"aria-label": unref(propsDefaults).deselectActionLabel,
|
|
2920
|
+
type: "button",
|
|
2921
|
+
onClick: withModifiers(($event) => onInput(option), ["stop"])
|
|
2922
|
+
}, [
|
|
2923
|
+
createVNode(_sfc_main$9, { name: "close" })
|
|
2924
|
+
], 8, _hoisted_8)) : createCommentVNode("v-if", true)
|
|
2925
|
+
]),
|
|
2926
|
+
_: 2
|
|
2927
|
+
/* DYNAMIC */
|
|
2928
|
+
}, 1032, ["modifiers"]);
|
|
2929
|
+
}),
|
|
2930
|
+
128
|
|
2931
|
+
/* KEYED_FRAGMENT */
|
|
2932
|
+
))
|
|
2933
|
+
],
|
|
2934
|
+
64
|
|
2935
|
+
/* STABLE_FRAGMENT */
|
|
2936
|
+
)) : (openBlock(), createElementBlock(
|
|
2937
|
+
Fragment,
|
|
2938
|
+
{ key: 1 },
|
|
2939
|
+
[
|
|
2940
|
+
createTextVNode(
|
|
2941
|
+
toDisplayString(_ctx.placeholder),
|
|
2942
|
+
1
|
|
2943
|
+
/* TEXT */
|
|
2944
|
+
)
|
|
2945
|
+
],
|
|
2946
|
+
64
|
|
2947
|
+
/* STABLE_FRAGMENT */
|
|
2948
|
+
))
|
|
2875
2949
|
])
|
|
2876
|
-
]),
|
|
2877
|
-
|
|
2878
|
-
|
|
2879
|
-
|
|
2880
|
-
|
|
2881
|
-
|
|
2882
|
-
|
|
2950
|
+
], 16, _hoisted_6),
|
|
2951
|
+
unref(hasIconAfter) ? (openBlock(), createBlock(
|
|
2952
|
+
_sfc_main$9,
|
|
2953
|
+
mergeProps({ key: 1 }, unref(hasIconAfter), { class: "vv-select__icon vv-select__icon-after" }),
|
|
2954
|
+
null,
|
|
2955
|
+
16
|
|
2956
|
+
/* FULL_PROPS */
|
|
2957
|
+
)) : createCommentVNode("v-if", true)
|
|
2958
|
+
]),
|
|
2959
|
+
_ctx.$slots.after ? (openBlock(), createElementBlock("div", _hoisted_9, [
|
|
2960
|
+
renderSlot(_ctx.$slots, "after", normalizeProps(guardReactiveProps(unref(slotProps))))
|
|
2961
|
+
])) : createCommentVNode("v-if", true)
|
|
2962
|
+
]),
|
|
2963
|
+
items: withCtx(() => {
|
|
2883
2964
|
var _a;
|
|
2884
2965
|
return [
|
|
2885
|
-
((_a = unref(
|
|
2886
|
-
|
|
2887
|
-
|
|
2888
|
-
|
|
2889
|
-
|
|
2890
|
-
|
|
2966
|
+
!unref(disabled) && ((_a = unref(filteredOptions)) == null ? void 0 : _a.length) ? (openBlock(true), createElementBlock(
|
|
2967
|
+
Fragment,
|
|
2968
|
+
{ key: 0 },
|
|
2969
|
+
renderList(unref(filteredOptions), (option, index) => {
|
|
2970
|
+
return openBlock(), createElementBlock(
|
|
2971
|
+
Fragment,
|
|
2972
|
+
{ key: index },
|
|
2973
|
+
[
|
|
2974
|
+
isGroup(option) ? (openBlock(), createElementBlock(
|
|
2975
|
+
Fragment,
|
|
2976
|
+
{ key: 0 },
|
|
2977
|
+
[
|
|
2978
|
+
createVNode(_sfc_main$5, {
|
|
2979
|
+
label: unref(getOptionLabel)(option)
|
|
2980
|
+
}, null, 8, ["label"]),
|
|
2981
|
+
(openBlock(true), createElementBlock(
|
|
2982
|
+
Fragment,
|
|
2983
|
+
null,
|
|
2984
|
+
renderList(unref(getOptionGrouped)(
|
|
2985
|
+
option
|
|
2986
|
+
), (item, i) => {
|
|
2987
|
+
return openBlock(), createBlock(_sfc_main$6, mergeProps({
|
|
2988
|
+
selected: isOptionSelected(item),
|
|
2989
|
+
disabled: unref(isOptionDisabled)(item),
|
|
2990
|
+
unselectable: _ctx.unselectable,
|
|
2991
|
+
deselectHintLabel: unref(propsDefaults).deselectHintLabel,
|
|
2992
|
+
selectHintLabel: unref(propsDefaults).selectHintLabel,
|
|
2993
|
+
selectedHintLabel: unref(propsDefaults).selectedHintLabel
|
|
2994
|
+
}, {
|
|
2995
|
+
key: i,
|
|
2996
|
+
class: "vv-dropdown-option",
|
|
2997
|
+
"focus-on-hover": "",
|
|
2998
|
+
onClickPassive: ($event) => onInput(item)
|
|
2999
|
+
}), {
|
|
3000
|
+
default: withCtx(() => [
|
|
3001
|
+
renderSlot(_ctx.$slots, "option", normalizeProps(guardReactiveProps({
|
|
3002
|
+
option,
|
|
3003
|
+
selectedOptions: unref(selectedOptions),
|
|
3004
|
+
selected: isOptionSelected(item),
|
|
3005
|
+
disabled: unref(isOptionDisabled)(item)
|
|
3006
|
+
})), () => [
|
|
3007
|
+
createTextVNode(
|
|
3008
|
+
toDisplayString(unref(getOptionLabel)(item)),
|
|
3009
|
+
1
|
|
3010
|
+
/* TEXT */
|
|
3011
|
+
)
|
|
3012
|
+
])
|
|
3013
|
+
]),
|
|
3014
|
+
_: 2
|
|
3015
|
+
/* DYNAMIC */
|
|
3016
|
+
}, 1040, ["onClickPassive"]);
|
|
3017
|
+
}),
|
|
3018
|
+
128
|
|
3019
|
+
/* KEYED_FRAGMENT */
|
|
3020
|
+
))
|
|
3021
|
+
],
|
|
3022
|
+
64
|
|
3023
|
+
/* STABLE_FRAGMENT */
|
|
3024
|
+
)) : (openBlock(), createBlock(_sfc_main$6, mergeProps({ key: 1 }, {
|
|
3025
|
+
selected: isOptionSelected(option),
|
|
3026
|
+
disabled: unref(isOptionDisabled)(option),
|
|
3027
|
+
unselectable: _ctx.unselectable,
|
|
3028
|
+
deselectHintLabel: unref(propsDefaults).deselectHintLabel,
|
|
3029
|
+
selectHintLabel: unref(propsDefaults).selectHintLabel,
|
|
3030
|
+
selectedHintLabel: unref(propsDefaults).selectedHintLabel
|
|
3031
|
+
}, {
|
|
3032
|
+
class: "vv-dropdown-option",
|
|
3033
|
+
"focus-on-hover": "",
|
|
3034
|
+
onClickPassive: ($event) => onInput(option)
|
|
3035
|
+
}), {
|
|
3036
|
+
default: withCtx(() => [
|
|
3037
|
+
renderSlot(_ctx.$slots, "option", normalizeProps(guardReactiveProps({
|
|
3038
|
+
option,
|
|
3039
|
+
selectedOptions: unref(selectedOptions),
|
|
3040
|
+
selected: isOptionSelected(option),
|
|
3041
|
+
disabled: unref(isOptionDisabled)(option)
|
|
3042
|
+
})), () => [
|
|
3043
|
+
createTextVNode(
|
|
3044
|
+
toDisplayString(unref(getOptionLabel)(option)),
|
|
3045
|
+
1
|
|
3046
|
+
/* TEXT */
|
|
3047
|
+
)
|
|
3048
|
+
])
|
|
3049
|
+
]),
|
|
3050
|
+
_: 2
|
|
3051
|
+
/* DYNAMIC */
|
|
3052
|
+
}, 1040, ["onClickPassive"]))
|
|
3053
|
+
],
|
|
3054
|
+
64
|
|
3055
|
+
/* STABLE_FRAGMENT */
|
|
3056
|
+
);
|
|
3057
|
+
}),
|
|
3058
|
+
128
|
|
3059
|
+
/* KEYED_FRAGMENT */
|
|
3060
|
+
)) : !_ctx.options.length ? (openBlock(), createBlock(_sfc_main$6, {
|
|
3061
|
+
key: 1,
|
|
3062
|
+
modifiers: "inert"
|
|
3063
|
+
}, {
|
|
3064
|
+
default: withCtx(() => [
|
|
3065
|
+
renderSlot(_ctx.$slots, "no-options", {}, () => [
|
|
3066
|
+
createTextVNode(
|
|
3067
|
+
toDisplayString(unref(propsDefaults).noOptionsLabel),
|
|
3068
|
+
1
|
|
3069
|
+
/* TEXT */
|
|
3070
|
+
)
|
|
3071
|
+
])
|
|
3072
|
+
]),
|
|
3073
|
+
_: 3
|
|
3074
|
+
/* FORWARDED */
|
|
3075
|
+
})) : !unref(disabled) ? (openBlock(), createBlock(_sfc_main$6, {
|
|
3076
|
+
key: 2,
|
|
3077
|
+
modifiers: "inert"
|
|
3078
|
+
}, {
|
|
3079
|
+
default: withCtx(() => [
|
|
3080
|
+
renderSlot(_ctx.$slots, "no-results", {}, () => [
|
|
3081
|
+
createTextVNode(
|
|
3082
|
+
toDisplayString(unref(propsDefaults).noResultsLabel),
|
|
3083
|
+
1
|
|
3084
|
+
/* TEXT */
|
|
3085
|
+
)
|
|
3086
|
+
])
|
|
3087
|
+
]),
|
|
3088
|
+
_: 3
|
|
3089
|
+
/* FORWARDED */
|
|
3090
|
+
})) : createCommentVNode("v-if", true)
|
|
2891
3091
|
];
|
|
2892
|
-
})
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2899
|
-
|
|
2900
|
-
|
|
2901
|
-
|
|
2902
|
-
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(searchText) ? searchText.value = $event : null),
|
|
2906
|
-
"aria-autocomplete": "list",
|
|
2907
|
-
"aria-controls": unref(hasDropdownId),
|
|
2908
|
-
autocomplete: "off",
|
|
2909
|
-
spellcheck: "false",
|
|
2910
|
-
type: "search",
|
|
2911
|
-
class: "vv-dropdown__search",
|
|
2912
|
-
placeholder: unref(propsDefaults).searchPlaceholder
|
|
2913
|
-
}, null, 8, _hoisted_3)), [
|
|
2914
|
-
[vModelText, unref(searchText)]
|
|
2915
|
-
]) : createCommentVNode("", true)
|
|
3092
|
+
}),
|
|
3093
|
+
after: withCtx(() => [
|
|
3094
|
+
renderSlot(_ctx.$slots, "dropdown::after", {}, () => {
|
|
3095
|
+
var _a;
|
|
3096
|
+
return [
|
|
3097
|
+
((_a = unref(dropdownEl)) == null ? void 0 : _a.customPosition) ? (openBlock(), createBlock(_sfc_main$1, {
|
|
3098
|
+
key: 0,
|
|
3099
|
+
label: unref(propsDefaults).closeLabel,
|
|
3100
|
+
modifiers: "secondary",
|
|
3101
|
+
onClick: _cache[1] || (_cache[1] = ($event) => unref(dropdownEl).hide())
|
|
3102
|
+
}, null, 8, ["label"])) : createCommentVNode("v-if", true)
|
|
3103
|
+
];
|
|
3104
|
+
})
|
|
2916
3105
|
]),
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
|
|
2920
|
-
|
|
3106
|
+
_: 2
|
|
3107
|
+
/* DYNAMIC */
|
|
3108
|
+
}, [
|
|
3109
|
+
unref(propsDefaults).searchable || _ctx.$slots["dropdown::before"] ? {
|
|
3110
|
+
name: "before",
|
|
3111
|
+
fn: withCtx(() => [
|
|
3112
|
+
renderSlot(_ctx.$slots, "dropdown::before"),
|
|
3113
|
+
unref(propsDefaults).searchable && !unref(disabled) ? withDirectives((openBlock(), createElementBlock("input", {
|
|
3114
|
+
key: 0,
|
|
3115
|
+
id: unref(hasSearchId),
|
|
3116
|
+
ref_key: "inputSearchEl",
|
|
3117
|
+
ref: inputSearchEl,
|
|
3118
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(searchText) ? searchText.value = $event : null),
|
|
3119
|
+
"aria-autocomplete": "list",
|
|
3120
|
+
"aria-controls": unref(hasDropdownId),
|
|
3121
|
+
autocomplete: "off",
|
|
3122
|
+
spellcheck: "false",
|
|
3123
|
+
type: "search",
|
|
3124
|
+
class: "vv-dropdown__search",
|
|
3125
|
+
placeholder: unref(propsDefaults).searchPlaceholder
|
|
3126
|
+
}, null, 8, _hoisted_3)), [
|
|
3127
|
+
[vModelText, unref(searchText)]
|
|
3128
|
+
]) : createCommentVNode("v-if", true)
|
|
3129
|
+
]),
|
|
3130
|
+
key: "0"
|
|
3131
|
+
} : void 0
|
|
3132
|
+
]), 1040, ["modelValue", "role"])
|
|
3133
|
+
],
|
|
3134
|
+
512
|
|
3135
|
+
/* NEED_PATCH */
|
|
3136
|
+
),
|
|
2921
3137
|
createVNode(unref(HintSlot), {
|
|
2922
3138
|
id: unref(hasHintId),
|
|
2923
3139
|
class: "vv-select__hint"
|
|
2924
|
-
}, createSlots({
|
|
3140
|
+
}, createSlots({
|
|
3141
|
+
_: 2
|
|
3142
|
+
/* DYNAMIC */
|
|
3143
|
+
}, [
|
|
2925
3144
|
_ctx.$slots.hint ? {
|
|
2926
3145
|
name: "hint",
|
|
2927
3146
|
fn: withCtx(() => [
|
|
@@ -2951,9 +3170,15 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
2951
3170
|
key: "3"
|
|
2952
3171
|
} : void 0
|
|
2953
3172
|
]), 1032, ["id"])
|
|
2954
|
-
], 10, _hoisted_1)) : (openBlock(), createBlock(
|
|
2955
|
-
|
|
2956
|
-
|
|
3173
|
+
], 10, _hoisted_1)) : (openBlock(), createBlock(
|
|
3174
|
+
_sfc_main$4,
|
|
3175
|
+
mergeProps({ key: 1 }, unref(selectProps), {
|
|
3176
|
+
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => emit("update:modelValue", $event))
|
|
3177
|
+
}),
|
|
3178
|
+
null,
|
|
3179
|
+
16
|
|
3180
|
+
/* FULL_PROPS */
|
|
3181
|
+
));
|
|
2957
3182
|
};
|
|
2958
3183
|
}
|
|
2959
3184
|
});
|