@volverjs/ui-vue 0.0.13 → 0.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Volver.d.ts +121 -0
- package/dist/components/VvAccordion/VvAccordion.vue.d.ts +68 -0
- package/dist/components/VvAccordion/index.d.ts +47 -0
- package/dist/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +98 -0
- package/dist/components/VvAccordionGroup/index.d.ts +54 -0
- package/dist/components/VvAction/VvAction.es.js +26 -26
- package/dist/components/VvAction/VvAction.umd.js +1 -1
- package/dist/components/VvAction/VvAction.vue.d.ts +110 -0
- package/dist/components/VvAction/index.d.ts +2 -0
- package/dist/components/VvAlert/VvAlert.es.js +43 -44
- package/dist/components/VvAlert/VvAlert.umd.js +1 -1
- package/dist/components/VvAlert/VvAlert.vue.d.ts +124 -0
- package/dist/components/VvAlert/index.d.ts +104 -0
- package/dist/components/VvAlertGroup/VvAlertGroup.es.js +54 -55
- package/dist/components/VvAlertGroup/VvAlertGroup.umd.js +1 -1
- package/dist/components/VvAlertGroup/VvAlertGroup.vue.d.ts +97 -0
- package/dist/components/VvAlertGroup/index.d.ts +47 -0
- package/dist/components/VvAvatar/VvAvatar.vue.d.ts +24 -0
- package/dist/components/VvAvatar/index.d.ts +10 -0
- package/dist/components/VvAvatarGroup/VvAvatarGroup.vue.d.ts +50 -0
- package/dist/components/VvAvatarGroup/index.d.ts +28 -0
- package/dist/components/VvBadge/VvBadge.vue.d.ts +24 -0
- package/dist/components/VvBadge/index.d.ts +7 -0
- package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +34 -34
- package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
- package/dist/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +39 -0
- package/dist/components/VvBreadcrumb/index.d.ts +8 -0
- package/dist/components/VvButton/VvButton.es.js +186 -187
- package/dist/components/VvButton/VvButton.umd.js +1 -1
- package/dist/components/VvButton/VvButton.vue.d.ts +221 -0
- package/dist/components/VvButton/index.d.ts +131 -0
- package/dist/components/VvButtonGroup/VvButtonGroup.vue.d.ts +84 -0
- package/dist/components/VvButtonGroup/index.d.ts +37 -0
- package/dist/components/VvCard/VvCard.vue.d.ts +30 -0
- package/dist/components/VvCard/index.d.ts +7 -0
- package/dist/components/VvCheckbox/VvCheckbox.es.js +215 -217
- package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -1
- package/dist/components/VvCheckbox/VvCheckbox.vue.d.ts +187 -0
- package/dist/components/VvCheckbox/index.d.ts +94 -0
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +235 -237
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -1
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +212 -0
- package/dist/components/VvCheckboxGroup/index.d.ts +2 -0
- package/dist/components/VvCombobox/VvCombobox.es.js +810 -813
- package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
- package/dist/components/VvCombobox/VvCombobox.vue.d.ts +346 -0
- package/dist/components/VvCombobox/index.d.ts +694 -0
- package/dist/components/VvDialog/VvDialog.vue.d.ts +73 -0
- package/dist/components/VvDialog/index.d.ts +45 -0
- package/dist/components/VvDropdown/VvDropdown.es.js +4 -4
- package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
- package/dist/components/VvDropdown/VvDropdown.vue.d.ts +258 -0
- package/dist/components/VvDropdown/VvDropdownAction.vue.d.ts +118 -0
- package/dist/components/VvDropdown/VvDropdownItem.vue.d.ts +22 -0
- package/dist/components/VvDropdown/VvDropdownOptgroup.vue.d.ts +22 -0
- package/dist/components/VvDropdown/VvDropdownOption.vue.d.ts +82 -0
- package/dist/components/VvDropdown/index.d.ts +120 -0
- package/dist/components/VvDropdownAction/VvDropdownAction.es.js +50 -50
- package/dist/components/VvDropdownAction/VvDropdownAction.umd.js +1 -1
- package/dist/components/VvIcon/VvIcon.es.js +30 -31
- package/dist/components/VvIcon/VvIcon.umd.js +1 -1
- package/dist/components/VvIcon/VvIcon.vue.d.ts +6 -0
- package/dist/components/VvIcon/index.d.ts +86 -0
- package/dist/components/VvInputFile/VvInputFile.es.js +415 -418
- package/dist/components/VvInputFile/VvInputFile.umd.js +1 -1
- package/dist/components/VvInputFile/VvInputFile.vue.d.ts +361 -0
- package/dist/components/VvInputFile/index.d.ts +204 -0
- package/dist/components/VvInputText/VvInputText.es.js +595 -588
- package/dist/components/VvInputText/VvInputText.umd.js +1 -1
- package/dist/components/VvInputText/VvInputText.vue.d.ts +524 -0
- package/dist/components/VvInputText/VvInputTextActions.d.ts +4 -0
- package/dist/components/VvInputText/index.d.ts +313 -0
- package/dist/components/VvNav/VvNav.es.js +63 -63
- package/dist/components/VvNav/VvNav.umd.js +1 -1
- package/dist/components/VvNav/VvNav.vue.d.ts +48 -0
- package/dist/components/VvNav/VvNavItem.vue.d.ts +14 -0
- package/dist/components/VvNav/VvNavSeparator.vue.d.ts +3 -0
- package/dist/components/VvNav/index.d.ts +11 -0
- package/dist/components/VvNavItem/VvNavItem.es.js +41 -41
- package/dist/components/VvNavItem/VvNavItem.umd.js +1 -1
- package/dist/components/VvProgress/VvProgress.vue.d.ts +38 -0
- package/dist/components/VvProgress/index.d.ts +33 -0
- package/dist/components/VvRadio/VvRadio.es.js +222 -224
- package/dist/components/VvRadio/VvRadio.umd.js +1 -1
- package/dist/components/VvRadio/VvRadio.vue.d.ts +179 -0
- package/dist/components/VvRadio/index.d.ts +80 -0
- package/dist/components/VvRadioGroup/VvRadioGroup.es.js +234 -236
- package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -1
- package/dist/components/VvRadioGroup/VvRadioGroup.vue.d.ts +212 -0
- package/dist/components/VvRadioGroup/index.d.ts +2 -0
- package/dist/components/VvSelect/VvSelect.es.js +200 -203
- package/dist/components/VvSelect/VvSelect.umd.js +1 -1
- package/dist/components/VvSelect/VvSelect.vue.d.ts +183 -0
- package/dist/components/VvSelect/index.d.ts +298 -0
- package/dist/components/VvTab/VvTab.es.js +35 -35
- package/dist/components/VvTab/VvTab.umd.js +1 -1
- package/dist/components/VvTab/VvTab.vue.d.ts +64 -0
- package/dist/components/VvTab/index.d.ts +19 -0
- package/dist/components/VvTextarea/VvTextarea.es.js +341 -344
- package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
- package/dist/components/VvTextarea/VvTextarea.vue.d.ts +384 -0
- package/dist/components/VvTextarea/index.d.ts +190 -0
- package/dist/components/VvTooltip/VvTooltip.vue.d.ts +37 -0
- package/dist/components/VvTooltip/index.d.ts +19 -0
- package/dist/components/VvVirtualScroll/VvVirtualScroll.vue.d.ts +51 -0
- package/dist/components/common/HintSlot.d.ts +57 -0
- package/dist/components/common/VvInputClearAction.d.ts +52 -0
- package/dist/components/common/VvInputPasswordAction.d.ts +71 -0
- package/dist/components/common/VvInputStepAction.d.ts +50 -0
- package/dist/components/index.d.ts +34 -0
- package/dist/components/index.es.js +1965 -1958
- package/dist/components/index.umd.js +1 -1
- package/dist/composables/alert/useAlerInject.d.ts +4 -0
- package/dist/composables/alert/useAlert.d.ts +92 -0
- package/dist/composables/alert/useAlertProvide.d.ts +10 -0
- package/dist/composables/dropdown/useDropdownContextmenu.d.ts +18 -0
- package/dist/composables/dropdown/useDropdownInject.d.ts +12 -0
- package/dist/composables/dropdown/useDropdownProvide.d.ts +40 -0
- package/dist/composables/dropdown/useDropdownVirtualElement.d.ts +17 -0
- package/dist/composables/group/useGroupStateInject.d.ts +9 -0
- package/dist/composables/group/useGroupStateProvide.d.ts +6 -0
- package/dist/composables/index.d.ts +5 -0
- package/dist/composables/index.es.js +34 -34
- package/dist/composables/index.umd.js +2 -2
- package/dist/composables/useBlurhash.d.ts +7 -0
- package/dist/composables/useComponentFocus.d.ts +4 -0
- package/dist/composables/useComponentIcon.d.ts +11 -0
- package/dist/composables/useDebouncedInput.d.ts +5 -0
- package/dist/composables/useDefaults.d.ts +2 -0
- package/dist/composables/useModifiers.d.ts +2 -0
- package/dist/composables/useOptions.d.ts +8 -0
- package/dist/composables/usePersistence.d.ts +3 -0
- package/dist/composables/useTextCount.d.ts +10 -0
- package/dist/composables/useUniqueId.d.ts +2 -0
- package/dist/composables/useVirtualScroll.d.ts +35 -0
- package/dist/composables/useVolver.d.ts +4 -0
- package/dist/constants.d.ts +104 -0
- package/dist/directives/index.d.ts +3 -0
- package/dist/directives/index.es.js +22 -22
- package/dist/directives/index.umd.js +1 -1
- package/dist/directives/v-contextmenu.d.ts +3 -0
- package/dist/directives/v-contextmenu.es.js +13 -13
- package/dist/directives/v-contextmenu.umd.js +1 -1
- package/dist/directives/v-tooltip.d.ts +3 -0
- package/dist/icons.d.ts +1889 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.es.js +19 -19
- package/dist/index.umd.js +1 -1
- package/dist/json-render/catalog.d.ts +395 -0
- package/dist/json-render/components.d.ts +111 -0
- package/dist/json-render/definitions.d.ts +697 -0
- package/dist/json-render/index.d.ts +55 -0
- package/dist/json-render/index.es.js +1877 -1870
- package/dist/json-render/index.umd.js +1 -1
- package/dist/json-render/registry.d.ts +34 -0
- package/dist/props/index.d.ts +959 -0
- package/dist/resolvers/unplugin.d.ts +38 -0
- package/dist/resolvers/unplugin.es.js +28 -28
- package/dist/resolvers/unplugin.umd.js +1 -1
- package/dist/stories/Accordion/Accordion.settings.d.ts +9 -0
- package/dist/stories/Accordion/Accordion.stories.d.ts +7 -0
- package/dist/stories/Accordion/Accordion.test.d.ts +2 -0
- package/dist/stories/Accordion/AccordionSlots.stories.d.ts +7 -0
- package/dist/stories/AccordionGroup/AccordionGroup.settings.d.ts +13 -0
- package/dist/stories/AccordionGroup/AccordionGroup.stories.d.ts +9 -0
- package/dist/stories/AccordionGroup/AccordionGroup.test.d.ts +2 -0
- package/dist/stories/AccordionGroup/AccordionGroupSlots.stories.d.ts +1788 -0
- package/dist/stories/Alert/Alert.settings.d.ts +4 -0
- package/dist/stories/Alert/Alert.stories.d.ts +9 -0
- package/dist/stories/Alert/Alert.test.d.ts +2 -0
- package/dist/stories/Alert/AlertModifiers.stories.d.ts +13 -0
- package/dist/stories/Alert/AlertSlots.stories.d.ts +10 -0
- package/dist/stories/AlertGroup/AlertGroup.settings.d.ts +14 -0
- package/dist/stories/AlertGroup/AlertGroup.stories.d.ts +8 -0
- package/dist/stories/AlertGroup/AlertGroup.test.d.ts +2 -0
- package/dist/stories/AlertGroup/AlertGroupPosition.stories.d.ts +14 -0
- package/dist/stories/AlertGroup/AlertGroupSlots.stories.d.ts +8 -0
- package/dist/stories/AlertGroup/AlertGroupWithComposable.stories.d.ts +4 -0
- package/dist/stories/Avatar/Avatar.settings.d.ts +5 -0
- package/dist/stories/Avatar/Avatar.stories.d.ts +7 -0
- package/dist/stories/Avatar/Avatar.test.d.ts +2 -0
- package/dist/stories/Avatar/AvatarBadge.stories.d.ts +6 -0
- package/dist/stories/Avatar/AvatarModifiers.stories.d.ts +13 -0
- package/dist/stories/Avatar/AvatarSlots.stories.d.ts +6 -0
- package/dist/stories/AvatarGroup/AvatarGroup.settings.d.ts +14 -0
- package/dist/stories/AvatarGroup/AvatarGroup.stories.d.ts +6 -0
- package/dist/stories/AvatarGroup/AvatarGroup.test.d.ts +2 -0
- package/dist/stories/AvatarGroup/AvatarGroupModifiers.stories.d.ts +7 -0
- package/dist/stories/AvatarGroup/AvatarGroupSlotDefault.stories.d.ts +6 -0
- package/dist/stories/Badge/Badge.settings.d.ts +5 -0
- package/dist/stories/Badge/Badge.stories.d.ts +7 -0
- package/dist/stories/Badge/Badge.test.d.ts +2 -0
- package/dist/stories/Badge/BadgeSlots.stories.d.ts +6 -0
- package/dist/stories/Blurhash/BlurhashComposable.stories.d.ts +4 -0
- package/dist/stories/Breadcrumb/Breadcrumb.settings.d.ts +13 -0
- package/dist/stories/Breadcrumb/Breadcrumb.stories.d.ts +7 -0
- package/dist/stories/Breadcrumb/Breadcrumb.test.d.ts +2 -0
- package/dist/stories/Breadcrumb/BreadcrumbSlots.stories.d.ts +6 -0
- package/dist/stories/Button/Button.settings.d.ts +4 -0
- package/dist/stories/Button/Button.stories.d.ts +6 -0
- package/dist/stories/Button/Button.test.d.ts +2 -0
- package/dist/stories/Button/ButtonIcon.stories.d.ts +10 -0
- package/dist/stories/Button/ButtonLink.stories.d.ts +7 -0
- package/dist/stories/Button/ButtonLoading.stories.d.ts +8 -0
- package/dist/stories/Button/ButtonModifiers.stories.d.ts +17 -0
- package/dist/stories/Button/ButtonSlots.stories.d.ts +9 -0
- package/dist/stories/Button/ButtonState.stories.d.ts +8 -0
- package/dist/stories/Button/ButtonToggle.stories.d.ts +9 -0
- package/dist/stories/ButtonGroup/ButtonGroup.settings.d.ts +5 -0
- package/dist/stories/ButtonGroup/ButtonGroup.stories.d.ts +6 -0
- package/dist/stories/ButtonGroup/ButtonGroup.test.d.ts +2 -0
- package/dist/stories/ButtonGroup/ButtonGroupModifiers.stories.d.ts +8 -0
- package/dist/stories/ButtonGroup/ButtonGroupSlots.stories.d.ts +6 -0
- package/dist/stories/ButtonGroup/ButtonGroupToggle.stories.d.ts +8 -0
- package/dist/stories/Card/Card.settings.d.ts +6 -0
- package/dist/stories/Card/Card.stories.d.ts +6 -0
- package/dist/stories/Card/Card.test.d.ts +2 -0
- package/dist/stories/Card/CardSlots.stories.d.ts +9 -0
- package/dist/stories/Checkbox/Checkbox.settings.d.ts +15 -0
- package/dist/stories/Checkbox/Checkbox.stories.d.ts +13 -0
- package/dist/stories/Checkbox/Checkbox.test.d.ts +2 -0
- package/dist/stories/Checkbox/CheckboxBinary.stories.d.ts +7 -0
- package/dist/stories/Checkbox/CheckboxSlots.stories.d.ts +7 -0
- package/dist/stories/CheckboxGroup/CheckboxGroup.settings.d.ts +12 -0
- package/dist/stories/CheckboxGroup/CheckboxGroup.stories.d.ts +12 -0
- package/dist/stories/CheckboxGroup/CheckboxGroup.test.d.ts +2 -0
- package/dist/stories/CheckboxGroup/CheckboxGroupOptions.stories.d.ts +8 -0
- package/dist/stories/CheckboxGroup/CheckboxGroupSlots.stories.d.ts +7 -0
- package/dist/stories/Combobox/Combobox.settings.d.ts +4 -0
- package/dist/stories/Combobox/Combobox.stories.d.ts +24 -0
- package/dist/stories/Combobox/Combobox.test.d.ts +2 -0
- package/dist/stories/Combobox/ComboboxIconPosition.stories.d.ts +8 -0
- package/dist/stories/Combobox/ComboboxMultiple.stories.d.ts +9 -0
- package/dist/stories/Combobox/ComboboxOptions.stories.d.ts +11 -0
- package/dist/stories/Combobox/ComboboxSlots.stories.d.ts +10 -0
- package/dist/stories/Dialog/Dialog.settings.d.ts +10 -0
- package/dist/stories/Dialog/Dialog.stories.d.ts +7 -0
- package/dist/stories/Dialog/Dialog.test.d.ts +2 -0
- package/dist/stories/Dialog/DialogModifiers.stories.d.ts +8 -0
- package/dist/stories/Dialog/DialogSlots.stories.d.ts +8 -0
- package/dist/stories/Dropdown/Dropdown.settings.d.ts +5 -0
- package/dist/stories/Dropdown/Dropdown.stories.d.ts +9 -0
- package/dist/stories/Dropdown/Dropdown.test.d.ts +2 -0
- package/dist/stories/Dropdown/DropdownContextmenuDirective.stories.d.ts +6 -0
- package/dist/stories/Dropdown/DropdownMultilevel.stories.d.ts +6 -0
- package/dist/stories/Dropdown/DropdownSlots.stories.d.ts +8 -0
- package/dist/stories/Icon/Icon.settings.d.ts +7 -0
- package/dist/stories/Icon/Icon.stories.d.ts +8 -0
- package/dist/stories/Icon/IconsCollection.stories.d.ts +6 -0
- package/dist/stories/InputFile/InputFile.settings.d.ts +6 -0
- package/dist/stories/InputFile/InputFile.stories.d.ts +13 -0
- package/dist/stories/InputFile/InputFileDropArea.stories.d.ts +9 -0
- package/dist/stories/InputFile/InputFileIconPosition.stories.d.ts +8 -0
- package/dist/stories/InputFile/InputFileSlots.stories.d.ts +7 -0
- package/dist/stories/InputText/InputText.settings.d.ts +11 -0
- package/dist/stories/InputText/InputText.stories.d.ts +16 -0
- package/dist/stories/InputText/InputText.test.d.ts +5 -0
- package/dist/stories/InputText/InputTextIconPosition.stories.d.ts +8 -0
- package/dist/stories/InputText/InputTextIso.stories.d.ts +10 -0
- package/dist/stories/InputText/InputTextLength.stories.d.ts +10 -0
- package/dist/stories/InputText/InputTextMask.stories.d.ts +12 -0
- package/dist/stories/InputText/InputTextMinMax.stories.d.ts +9 -0
- package/dist/stories/InputText/InputTextSlots.stories.d.ts +8 -0
- package/dist/stories/InputText/InputTextSuggestions.stories.d.ts +8 -0
- package/dist/stories/InputText/InputTextType.stories.d.ts +18 -0
- package/dist/stories/Nav/Nav.settings.d.ts +4 -0
- package/dist/stories/Nav/Nav.stories.d.ts +6 -0
- package/dist/stories/Nav/Nav.test.d.ts +2 -0
- package/dist/stories/Nav/NavModifiers.stories.d.ts +9 -0
- package/dist/stories/Progress/Progress.settings.d.ts +7 -0
- package/dist/stories/Progress/Progress.stories.d.ts +7 -0
- package/dist/stories/Progress/Progress.test.d.ts +2 -0
- package/dist/stories/Radio/Radio.settings.d.ts +12 -0
- package/dist/stories/Radio/Radio.stories.d.ts +11 -0
- package/dist/stories/Radio/Radio.test.d.ts +2 -0
- package/dist/stories/Radio/RadioSlots.stories.d.ts +7 -0
- package/dist/stories/RadioGroup/RadioGroup.settings.d.ts +12 -0
- package/dist/stories/RadioGroup/RadioGroup.stories.d.ts +12 -0
- package/dist/stories/RadioGroup/RadioGroup.test.d.ts +2 -0
- package/dist/stories/RadioGroup/RadioGroupOptions.stories.d.ts +8 -0
- package/dist/stories/RadioGroup/RadioGroupSlots.stories.d.ts +7 -0
- package/dist/stories/Select/Select.settings.d.ts +8 -0
- package/dist/stories/Select/Select.stories.d.ts +16 -0
- package/dist/stories/Select/Select.test.d.ts +2 -0
- package/dist/stories/Select/SelectIconPosition.stories.d.ts +8 -0
- package/dist/stories/Select/SelectOptions.stories.d.ts +9 -0
- package/dist/stories/Select/SelectSlots.stories.d.ts +8 -0
- package/dist/stories/Tab/Tab.settings.d.ts +4 -0
- package/dist/stories/Tab/Tab.stories.d.ts +6 -0
- package/dist/stories/Tab/Tab.test.d.ts +2 -0
- package/dist/stories/Textarea/Textarea.settings.d.ts +9 -0
- package/dist/stories/Textarea/Textarea.stories.d.ts +14 -0
- package/dist/stories/Textarea/Textarea.test.d.ts +2 -0
- package/dist/stories/Textarea/TextareaLength.stories.d.ts +10 -0
- package/dist/stories/Textarea/TextareaSlots.stories.d.ts +8 -0
- package/dist/stories/Textarea/TextareatIconPosition.stories.d.ts +8 -0
- package/dist/stories/Tooltip/Tooltip.settings.d.ts +5 -0
- package/dist/stories/Tooltip/Tooltip.stories.d.ts +6 -0
- package/dist/stories/Tooltip/Tooltip.test.d.ts +2 -0
- package/dist/stories/Tooltip/TooltipDirective.stories.d.ts +10 -0
- package/dist/stories/VirtualScroll/VirtualScroll.settings.d.ts +5 -0
- package/dist/stories/VirtualScroll/VirtualScroll.stories.d.ts +7 -0
- package/dist/stories/VirtualScroll/VirtualScroll.test.d.ts +2 -0
- package/dist/stories/VirtualScroll/VirtualScrollWithComposable.stories.d.ts +4 -0
- package/dist/stories/argTypes.d.ts +56 -0
- package/dist/test/expect.d.ts +18 -0
- package/dist/test/options.d.ts +1 -0
- package/dist/test/sleep.d.ts +1 -0
- package/dist/types/alert.d.ts +15 -0
- package/dist/types/blurhash.d.ts +12 -0
- package/dist/types/floating-ui.d.ts +15 -0
- package/dist/types/generic.d.ts +4 -0
- package/dist/types/group.d.ts +59 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/input-file.d.ts +9 -0
- package/dist/types/nav.d.ts +17 -0
- package/dist/utils/DateUtilities.d.ts +14 -0
- package/dist/utils/DomUtilities.d.ts +1 -0
- package/dist/utils/FileUtilities.d.ts +14 -0
- package/dist/utils/ObjectUtilities.d.ts +76 -0
- package/dist/workers/blurhash.d.ts +1 -0
- package/package.json +3 -2
- package/src/Volver.ts +8 -6
- package/src/components/VvAction/index.ts +1 -3
- package/src/components/VvButton/VvButton.vue +1 -1
- package/src/components/VvCheckboxGroup/index.ts +1 -3
- package/src/components/VvCombobox/VvCombobox.vue +3 -3
- package/src/components/VvDropdown/VvDropdown.vue +8 -8
- package/src/components/VvIcon/VvIcon.vue +3 -6
- package/src/components/VvInputFile/VvInputFile.vue +6 -6
- package/src/components/VvInputText/VvInputText.vue +95 -78
- package/src/components/VvRadioGroup/index.ts +1 -3
- package/src/composables/useBlurhash.ts +1 -1
- package/src/composables/useDebouncedInput.ts +1 -1
- package/src/composables/useDefaults.ts +55 -44
- package/src/composables/useModifiers.ts +1 -1
- package/src/index.ts +2 -2
- package/src/resolvers/unplugin.ts +6 -6
- package/src/types/alert.ts +1 -1
- package/src/types/nav.ts +1 -1
- package/src/utils/DateUtilities.ts +3 -3
- package/src/utils/DomUtilities.ts +7 -1
- package/src/utils/ObjectUtilities.ts +60 -59
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(e,h){typeof exports=="object"&&typeof module<"u"?module.exports=h(require("vue"),require("@floating-ui/vue"),require("@vueuse/core"),require("mitt"),require("@iconify/vue")):typeof define=="function"&&define.amd?define(["vue","@floating-ui/vue","@vueuse/core","mitt","@iconify/vue"],h):(e=typeof globalThis<"u"?globalThis:e||self,e.VvTextarea=h(e.Vue,e.FloatingUiVue,e.VueuseCore,e.mitt,e.IconifyVue))})(this,function(e,h,w,ee,j){var Re=Object.create,Pe=Object.defineProperty,je=Object.getOwnPropertyDescriptor,Fe=Object.getOwnPropertyNames,Ae=Object.getPrototypeOf,ze=Object.prototype.hasOwnProperty,Te=(t,o,r,a)=>{if(o&&typeof o=="object"||typeof o=="function")for(var l=Fe(o),i=0,c=l.length,d;i<c;i++)d=l[i],!ze.call(t,d)&&d!==r&&Pe(t,d,{get:(p=>o[p]).bind(null,d),enumerable:!(a=je(o,d))||a.enumerable});return t},He=(t,o,r)=>(r=t!=null?Re(Ae(t)):{},Te(o||!t||!t.__esModule?Pe(r,"default",{value:t,enumerable:!0}):r,t));ee=He(ee,1);var xe={showPassword:"eye-on",hidePassword:"eye-off",showDatePicker:"calendar",showTimePicker:"time",showColorPicker:"color",clear:"close",add:"add",remove:"trash",edit:"edit",download:"download"},Me={prefix:"normal"},I=(function(t){return t.local="local",t.session="session",t})({}),Ce=(function(t){return t.absolute="absolute",t.fixed="fixed",t})({}),P=(function(t){return t.left="left",t.right="right",t.top="top",t.bottom="bottom",t})({}),qe=(function(t){return t.topStart="top-start",t.topEnd="top-end",t.bottomStart="bottom-start",t.bottomEnd="bottom-end",t.leftStart="left-start",t.leftEnd="left-end",t.rightStart="right-start",t.rightEnd="right-end",t})({}),q=(function(t){return t.before="before",t.after="after",t})({}),Ve=(function(t){return t.button="button",t.submit="submit",t.reset="reset",t})({}),We=(function(t){return t.nuxtLink="nuxt-link",t.routerLink="router-link",t.a="a",t.button="button",t})({}),Ke=(function(t){return t.button="button",t.link="link",t.menuitem="menuitem",t})({}),te=(function(t){return t.listbox="listbox",t.menu="menu",t})({}),Ee=(function(t){return t.option="option",t.presentation="presentation",t})({}),Je=Symbol.for("volver"),Ue=Symbol.for("dropdownTrigger"),Le=Symbol.for("dropdownItem"),Ye=Symbol.for("dropdownAction"),Ge={to:{type:[String,Object]},href:String,target:String,rel:{type:String,default:"noopener noreferrer"}},re={valid:{type:Boolean,default:!1},validLabel:{type:[String,Array],default:void 0}},oe={invalid:{type:Boolean,default:!1},invalidLabel:{type:[String,Array],default:void 0}},ae={loading:{type:Boolean,default:!1},loadingLabel:{type:String,default:"Loading..."}},F={disabled:{type:Boolean,default:!1}},Oe={required:{type:Boolean,default:!1}},Qe={selected:{type:Boolean,default:!1}},Xe={active:{type:Boolean,default:!1}},Ze={current:{type:Boolean,default:!1}},tr={showClearAction:{type:Boolean,default:!1},iconClear:{type:[String,Object],default:xe.clear},labelClear:{type:String,default:"Clear"}},et={pressed:{type:Boolean,default:!1}},W={label:{type:[String,Number],default:void 0}},ne={readonly:{type:Boolean,default:!1}},A={modifiers:{type:[String,Array],default:void 0}},le={hintLabel:{type:String,default:""}},tt={options:{type:Array,default:()=>[]},labelKey:{type:[String,Function],default:"label"},valueKey:{type:[String,Function],default:"value"},disabledKey:{type:[String,Function],default:"disabled"}},rt={count:{type:[Boolean,String],default:!1,validator:t=>[!0,!1,"limit","countdown"].includes(t)}},ot={debounce:{type:[Number,String],default:void 0}},at={icon:{type:[String,Object],default:void 0},iconPosition:{type:String,default:q.before,validation:t=>Object.values(q).includes(t)}},Be={tabindex:{type:[String,Number],default:0}},nt={floating:{type:Boolean,default:!1}},lt={unselectable:{type:Boolean,default:!0}},$e={id:[String,Number]},it={placement:{type:String,default:P.bottom,validator:t=>Object.values(P).includes(t)||Object.values(qe).includes(t)},strategy:{type:String,default:void 0,validator:t=>Object.values(Ce).includes(t)},transitionName:{type:String,default:void 0},offset:{type:[Number,String,Object],default:0},shift:{type:[Boolean,Object],default:!1},flip:{type:[Boolean,Object],default:!0},size:{type:[Boolean,Object],default:()=>({padding:10})},autoPlacement:{type:[Boolean,Object],default:!1},arrow:{type:Boolean,default:!1},keepOpen:{type:Boolean,default:!1},autofocusFirst:{type:Boolean,default:!0},triggerWidth:{type:Boolean,default:!1}},ke={...$e,name:{type:String,required:!0}},st={autofocus:{type:Boolean,default:!1}},dt={autocomplete:{type:String,default:"off"}},ct={...ke,...st,...dt,...Be,...F,...ne,...re,...oe,...le,...ae,...A,...rt,...ot,...at,...nt,...W,minlength:{type:[String,Number],default:void 0},maxlength:{type:[String,Number],default:void 0},placeholder:{type:String,default:void 0},...Oe},rr={...ke,...Be,...re,...oe,...le,...F,...ne,...A,...W,...ae,value:{type:[String,Number,Boolean],default:void 0},modelValue:{type:[Object,Number,Boolean,String],default:void 0}},or={...re,...oe,...tt,...le,...F,...ne,...A,...W,...ae,...Oe,modelValue:{type:[String,Array,Boolean,Number,Symbol],default:void 0},name:{type:String,required:!0},vertical:{type:Boolean,default:!1}},ar={...F,...W,...et,...Xe,...Ze,...Ge,type:{type:String,default:Ve.button,validator:t=>Object.values(Ve).includes(t)},ariaLabel:{type:String,default:void 0},defaultTag:{type:String,default:We.button}},ft={storageType:{type:String,default:I.local,validator:t=>Object.values(I).includes(t)},storageKey:String},ut={hard:"hard",soft:"soft"},pt={true:!0,false:!1,default:"default"},mt=["update:modelValue","focus","blur","keyup","suggestion:selected","suggestion:removed"],Ne={...ct,...ft,modelValue:String,cols:{type:[String,Number],default:20},rows:{type:[String,Number],default:2},wrap:{type:String,default:ut.soft},spellcheck:{type:[Boolean,String],default:pt.default},iconRemoveSuggestion:{type:[String,Object],default:xe.remove},labelRemoveSuggestion:{type:String,default:"Remove suggestion"},maxSuggestions:{type:Number,default:5},selectOnFocus:{type:Boolean,default:!1},resizable:Boolean};function K(t){return(o=>o==null||o===""||Array.isArray(o)&&o.length===0||!(o instanceof Date)&&typeof o=="object"&&Object.keys(o).length===0)((0,e.unref)(t))}function gt(t){return typeof t=="string"}function Ie(t){return Array.isArray(t)?t.filter(o=>gt(o)).join(" "):t}function vt(t,o){const r=(0,e.computed)(()=>(0,e.isRef)(t)?t.value:t),a=(0,e.computed)(()=>Ie(r.value.invalidLabel)),l=(0,e.computed)(()=>Ie(r.value.validLabel)),i=(0,e.computed)(()=>r.value.loadingLabel),c=(0,e.computed)(()=>r.value.hintLabel),d=(0,e.computed)(()=>!!(r.value.loading&&(o.loading||i.value))),p=(0,e.computed)(()=>!d.value&&!!(r.value.invalid&&(o.invalid||a.value))),f=(0,e.computed)(()=>!d.value&&!p.value&&!!(r.value.valid&&(o.valid||l.value))),y=(0,e.computed)(()=>!d.value&&!p.value&&!f.value&&!!(o.hint||c.value)),s=(0,e.computed)(()=>p.value||f.value||d.value||y.value);return{hasInvalidLabelOrSlot:p,hasHintLabelOrSlot:y,hasValidLabelOrSlot:f,hasLoadingLabelOrSlot:d,hintSlotScope:(0,e.computed)(()=>({modelValue:r.value.modelValue,valid:r.value.valid,invalid:r.value.invalid,loading:r.value.loading})),HintSlot:(0,e.defineComponent)({name:"HintSlot",props:{tag:{type:String,default:"small"}},setup(){return{isVisible:s,invalidLabel:a,validLabel:l,loadingLabel:i,hintLabel:c,hasInvalidLabelOrSlot:p,hasValidLabelOrSlot:f,hasLoadingLabelOrSlot:d,hasHintLabelOrSlot:y}},render(){if(this.isVisible){let g;return this.hasInvalidLabelOrSlot&&(g="alert"),this.hasValidLabelOrSlot&&(g="status"),this.hasLoadingLabelOrSlot?(0,e.h)(this.tag,{role:g},this.$slots.loading?.()??this.loadingLabel):this.hasInvalidLabelOrSlot?(0,e.h)(this.tag,{role:g},this.$slots.invalid?.()??this.$slots.invalid??this.invalidLabel):this.hasValidLabelOrSlot?(0,e.h)(this.tag,{role:g},this.$slots.valid?.()??this.validLabel):(0,e.h)(this.tag,{role:g},this.$slots.hint?.()??this.$slots.hint??this.hintLabel)}return null}})}}var bt={...$e,...it,...A,modelValue:{type:Boolean,default:void 0},reference:{type:Object,default:null},role:{type:String,default:te.menu,validator:t=>Object.values(te).includes(t)}},ht={focusOnHover:{type:Boolean,default:!1}},yt={...F,...Qe,...lt,...A,deselectHintLabel:{type:String},selectHintLabel:{type:String},selectedHintLabel:{type:String},focusOnHover:{type:Boolean,default:!1}};function De(t){return(0,e.computed)(()=>String(t?.value||(0,e.useId)()))}function St({reference:t,id:o,expanded:r,aria:a}){const l=(0,ee.default)();return{bus:l,component:(0,e.defineComponent)({name:"VvDropdownTriggerProvider",setup(){(0,e.provide)(Ue,{reference:t,id:o,expanded:r,aria:a,bus:l})},render(){return(0,e.h)(e.Fragment,{},this.$slots.default?.())}})}}function wt({role:t,...o}){const r=(0,e.computed)(()=>t.value===te.listbox?Ee.option:Ee.presentation);return(0,e.provide)(Le,{role:r,...o}),{itemRole:r}}function Pt({expanded:t}){(0,e.provide)(Ye,{role:(0,e.ref)(Ke.menuitem),expanded:t})}function J(t,o,r){return(0,e.computed)(()=>{const a={[t]:!0},l=typeof o?.value=="string"?o.value.split(" "):o?.value;return l&&Array.isArray(l)&&l.forEach(i=>{i&&(a[`${t}--${i}`]=!0)}),r&&Object.keys(r.value).forEach(i=>{a[`${t}--${i}`]=(0,e.unref)(r.value[i])}),a})}var xt=["id","tabindex","role","aria-labelledby"],Ct={name:"VvDropdown",inheritAttrs:!1},Vt=(0,e.defineComponent)({...Ct,props:bt,emits:["update:modelValue","beforeEnter","afterLeave","beforeExpand","beforeCollapse","afterExpand","afterCollapse","before-enter","after-leave","enter","afterEnter","enterCancelled","beforeLeave","leave","leaveCancelled"],setup(t,{expose:o,emit:r}){const a=t,l=r,{id:i}=(0,e.toRefs)(a),c=De(i),d=(0,e.useAttrs)(),p=(0,e.ref)("auto"),f=(0,e.ref)("auto"),y=(0,e.ref)(),s=(0,e.ref)(),g=(0,e.ref)(),C=(0,e.ref)(),x=(0,e.computed)({get:()=>a.reference??y.value,set:n=>{y.value=n}}),O=(0,e.ref)(!1);(0,e.onMounted)(()=>{(0,w.useMutationObserver)(s.value,()=>{O.value=window.getComputedStyle(s.value).getPropertyValue("--dropdown-custom-position")?.trim()==="true"},{attributeFilter:["style"],window})});function B(n,m,k){return typeof n=="boolean"?m():k(n)}const U=(0,e.computed)(()=>{const n=[];if(a.autoPlacement?n.push(B(a.autoPlacement,()=>(0,h.autoPlacement)(),m=>(0,h.autoPlacement)(m))):a.flip&&n.push(B(a.flip,()=>(0,h.flip)({fallbackStrategy:"initialPlacement"}),m=>(0,h.flip)(m))),a.shift&&n.push(B(a.shift,()=>(0,h.shift)(),m=>(0,h.shift)(m))),a.size){const m=({availableWidth:k,availableHeight:M})=>{p.value=`${k}px`,f.value=`${M}px`};n.push(B(a.size,()=>(0,h.size)({apply:m}),k=>(0,h.size)({...k,apply:m})))}return a.offset&&n.push(["string","number"].includes(typeof a.offset)?(0,h.offset)(Number(a.offset)):(0,h.offset)(a.offset)),a.arrow&&n.push((0,h.arrow)({element:g})),n}),{x:de,y:ce,middlewareData:D,placement:fe,strategy:ue}=(0,h.useFloating)(x,s,{whileElementsMounted:(...n)=>(0,h.autoUpdate)(...n,{animationFrame:a.strategy===Ce.fixed}),placement:(0,e.computed)(()=>a.placement),strategy:(0,e.computed)(()=>a.strategy),middleware:U}),pe=(0,e.computed)(()=>{if(O.value)return;const n=a.triggerWidth&&x.value?`${x.value?.offsetWidth}px`:void 0;return{position:ue.value,top:`${ce.value??0}px`,left:`${de.value??0}px`,maxWidth:n?void 0:p.value,maxHeight:f.value,width:n}}),me=(0,e.computed)(()=>fe.value.split("-")[0]),ge=(0,e.computed)(()=>{if(O.value)return;const n={[P.top]:P.bottom,[P.right]:P.left,[P.bottom]:P.top,[P.left]:P.right}[me.value];return{left:D.value.arrow?.x!==void 0?`${D.value.arrow?.x}px`:void 0,top:D.value.arrow?.y!==void 0?`${D.value.arrow?.y}px`:void 0,[n]:`${-(g.value?.offsetWidth??0)/2}px`}}),$=(0,w.useVModel)(a,"modelValue",l),_=(0,e.ref)(!1),v=(0,e.computed)({get:()=>$.value??_.value,set:n=>{if($.value===void 0){_.value=n;return}$.value=n}});function S(){v.value=!0}function V(){v.value=!1}function E(){v.value=!v.value}function z(n){x.value=n}(0,w.onClickOutside)(s,()=>{!a.keepOpen&&v.value&&(v.value=!1)},{ignore:[x]});const T=(0,e.computed)(()=>x.value?.getAttribute?.("id")??void 0),Y=(0,e.computed)(()=>({"aria-controls":c.value,"aria-haspopup":!0,"aria-expanded":v.value})),{component:ve,bus:be}=St({reference:x,id:c,expanded:v,aria:Y});be.on("click",E);const{role:H,modifiers:he}=(0,e.toRefs)(a),G=J("vv-dropdown",he,(0,e.computed)(()=>({arrow:a.arrow}))),{focused:b}=(0,w.useFocusWithin)(s);function R(n){return n?[...n.querySelectorAll('a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"])')].filter(m=>!m.hasAttribute("disabled")&&!m.getAttribute("aria-hidden")):[]}function Q(){(0,e.nextTick)(()=>{const n=R(s.value);n.length>0&&n[0].focus({preventScroll:!0})})}function ye(){(0,e.nextTick)(()=>{const n=R(C.value);n.length>0&&n[0].focus({preventScroll:!0})})}function X(){(0,e.nextTick)(()=>{if(b.value){const n=R(s.value);if(n.length===0||!document.activeElement)return;const m=n.indexOf(document.activeElement);m<n.length-1?n[m+1].focus({preventScroll:!0}):n[0].focus({preventScroll:!0})}})}function Z(){(0,e.nextTick)(()=>{if(b.value){const n=R(s.value);if(n.length===0||!document.activeElement)return;const m=n.indexOf(document.activeElement);if(m>0){n[m-1].focus({preventScroll:!0});return}n.at(-1)?.focus({preventScroll:!0})}})}(0,e.watch)(v,n=>{n&&a.autofocusFirst&&Q()}),o({toggle:E,show:S,hide:V,init:z,focusFirst:Q,focusFirstListElement:ye,focusNext:X,focusPrev:Z,customPosition:O});const{itemRole:Se}=wt({role:H,expanded:v,focused:b,hovered:(0,w.useElementHover)(s)});(0,w.onKeyStroke)("Escape",n=>{v.value&&(n.preventDefault(),V())}),(0,w.onKeyStroke)("ArrowDown",n=>{v.value&&b.value&&(n.preventDefault(),X())}),(0,w.onKeyStroke)("ArrowUp",n=>{v.value&&b.value&&(n.preventDefault(),Z())}),(0,w.onKeyStroke)([" ","Enter"],n=>{const m=n.target;v.value&&b.value&&m&&m?.click()});const we={"before-enter":()=>{l(v.value?"beforeExpand":"beforeCollapse"),l("beforeEnter")},"after-leave":()=>{l(v.value?"afterExpand":"afterCollapse"),l("afterLeave")},enter:()=>{l("enter")},"after-enter":()=>{l("afterEnter")},"enter-cancelled":()=>{l("enterCancelled")},"before-leave":()=>{l("beforeLeave")},leave:()=>{l("leave")},"leave-cancelled":()=>{l("leaveCancelled")}};return(n,m)=>((0,e.openBlock)(),(0,e.createElementBlock)(e.Fragment,null,[(0,e.createVNode)((0,e.unref)(ve),null,{default:(0,e.withCtx)(()=>[(0,e.renderSlot)(n.$slots,"default",(0,e.normalizeProps)((0,e.guardReactiveProps)({init:z,show:S,hide:V,toggle:E,expanded:(0,e.unref)(v),aria:(0,e.unref)(Y)})))]),_:3}),(0,e.createVNode)(e.Transition,(0,e.mergeProps)({name:n.transitionName},(0,e.toHandlers)(we),{persisted:""}),{default:(0,e.withCtx)(()=>[(0,e.withDirectives)((0,e.createElementVNode)("div",{ref_key:"floatingEl",ref:s,style:(0,e.normalizeStyle)((0,e.unref)(pe)),class:(0,e.normalizeClass)((0,e.unref)(G))},[a.arrow?((0,e.openBlock)(),(0,e.createElementBlock)("div",{key:0,ref_key:"arrowEl",ref:g,style:(0,e.normalizeStyle)((0,e.unref)(ge)),class:"vv-dropdown__arrow"},null,4)):(0,e.createCommentVNode)("v-if",!0),(0,e.renderSlot)(n.$slots,"before",(0,e.normalizeProps)((0,e.guardReactiveProps)({show:S,hide:V,toggle:E,expanded:(0,e.unref)(v)}))),(0,e.createElementVNode)("div",(0,e.mergeProps)((0,e.unref)(d),{id:(0,e.unref)(c),ref_key:"listEl",ref:C,tabindex:(0,e.unref)(v)?void 0:-1,role:(0,e.unref)(H),"aria-labelledby":(0,e.unref)(T),class:"vv-dropdown__list"}),[(0,e.renderSlot)(n.$slots,"items",(0,e.normalizeProps)((0,e.guardReactiveProps)({show:S,hide:V,toggle:E,expanded:(0,e.unref)(v),role:(0,e.unref)(Se)})))],16,xt),(0,e.renderSlot)(n.$slots,"after",(0,e.normalizeProps)((0,e.guardReactiveProps)({show:S,hide:V,toggle:E,expanded:(0,e.unref)(v)})))],6),[[e.vShow,(0,e.unref)(v)]])]),_:3},16,["name"])],64))}}),Et=Vt;function Lt(){return(0,e.inject)(Le,{})}var Ot={name:"VvDropdownItem"},Bt=(0,e.defineComponent)({...Ot,props:ht,setup(t){const o=t,{role:r,expanded:a}=Lt(),l=(0,e.ref)(null);Pt({expanded:a});const i=(0,w.useElementHover)(l),{focused:c}=(0,w.useFocus)(l),{focused:d}=(0,w.useFocusWithin)(l);return(0,e.watch)(i,p=>{p&&o.focusOnHover&&(c.value=!0)}),(p,f)=>((0,e.openBlock)(),(0,e.createElementBlock)("div",(0,e.mergeProps)({role:(0,e.unref)(r)},{ref_key:"element",ref:l,class:["vv-dropdown__item",{"focus-visible":(0,e.unref)(c)||(0,e.unref)(d)}]}),[(0,e.renderSlot)(p.$slots,"default")],16))}}),$t=Bt,kt=["title"],Nt={name:"VvDropdownOption"},It=(0,e.defineComponent)({...Nt,props:yt,setup(t){const o=t,{modifiers:r}=(0,e.toRefs)(o),a=J("vv-dropdown-option",r,(0,e.computed)(()=>({disabled:o.disabled,selected:o.selected,unselectable:o.unselectable&&o.selected}))),l=(0,e.computed)(()=>o.selected?o.unselectable?o.deselectHintLabel:o.selectedHintLabel:o.disabled?"":o.selectHintLabel);return(i,c)=>((0,e.openBlock)(),(0,e.createBlock)($t,{class:(0,e.normalizeClass)((0,e.unref)(a)),tabindex:i.disabled?-1:0,"aria-selected":i.selected,"aria-disabled":i.disabled,"focus-on-hover":i.focusOnHover},{default:(0,e.withCtx)(()=>[(0,e.renderSlot)(i.$slots,"default"),(0,e.createElementVNode)("span",{class:"vv-dropdown-option__hint",title:(0,e.unref)(l)},[(0,e.renderSlot)(i.$slots,"hint",(0,e.normalizeProps)((0,e.guardReactiveProps)({disabled:i.disabled,selected:i.selected,unselectable:i.unselectable})),()=>[(0,e.createTextVNode)((0,e.toDisplayString)((0,e.unref)(l)),1)])],8,kt)]),_:3},8,["class","tabindex","aria-selected","aria-disabled","focus-on-hover"]))}}),Dt=It;function ie(){return(0,e.inject)(Je,void 0)}var _t={name:"VvIcon"},Rt=(0,e.defineComponent)({..._t,props:(0,e.mergeDefaults)({name:{},color:{},width:{},height:{},provider:{},prefix:{},src:{},horizontalFlip:{type:Boolean},verticalFlip:{type:Boolean},flip:{},mode:{},inline:{type:Boolean},rotate:{},onLoad:{type:Function},svg:{},modifiers:{}},Me),setup(t){const o=t,r=(0,e.computed)(()=>typeof o.rotate=="string"?Number.parseFloat(o.rotate):o.rotate),a=(0,e.ref)(!0),l=ie(),{modifiers:i}=(0,e.toRefs)(o),c=J("vv-icon",i),d=(0,e.computed)(()=>o.provider||l?.iconsProvider),p=(0,e.computed)(()=>{const s=o.name??"",g=`@${d.value}:${o.prefix}:${s}`;if((0,j.iconLoaded)(g))return g;const C=l?.iconsCollections.find(x=>(0,j.iconLoaded)(`@${d.value}:${x.prefix}:${s}`));return C?`@${d.value}:${C.prefix}:${s}`:s});function f(s){const g=typeof window<"u"?new window.DOMParser:null;return g?g.parseFromString(s,"text/html").querySelector("svg"):null}function y(s){const g=f(s),C=g?.innerHTML.trim()||"";g&&C&&(0,j.addIcon)(`@${d.value}:${o.prefix}:${o.name}`,{body:C,height:g.viewBox.baseVal.height,width:g.viewBox.baseVal.width})}return l&&o.src&&!(0,j.iconLoaded)(`@${d.value}:${o.prefix}:${o.name}`)&&(a.value=!1,l.fetchIcon(o.src).then(s=>{s&&y(s),a.value=!0}).catch(s=>{throw a.value=!0,new Error(`Error during fetch icon: ${s?.message}`)})),o.svg&&y(o.svg),(s,g)=>(0,e.unref)(a)?((0,e.openBlock)(),(0,e.createBlock)((0,e.unref)(j.Icon),(0,e.mergeProps)({key:0,class:(0,e.unref)(c)},{inline:t.inline,width:t.width,height:t.height,horizontalFlip:t.horizontalFlip,verticalFlip:t.verticalFlip,flip:t.flip,rotate:(0,e.unref)(r),color:t.color,icon:(0,e.unref)(p)},{onLoad:t.onLoad}),null,16,["class","onLoad"])):(0,e.createCommentVNode)("v-if",!0)}}),se=Rt;function jt(t,o,r){const a=ie(),l=(0,e.computed)(()=>{if(!(!a||!a.defaults.value?.[t]))return a.defaults.value[t]});return(0,e.computed)(()=>{if(l.value===void 0)return r;const i=l.value,c=o,d=r;return Object.keys(c).reduce((p,f)=>{const y=d[f];if(p[f]=y,f in i){if(Array.isArray(c[f])){const s=c[f];s.length&&s[0]===y&&(p[f]=i[f])}if(typeof c[f]=="function"){const s=c[f];s()===y&&(p[f]=i[f])}if(typeof c[f]=="object"){let s=c[f].default;typeof s=="function"&&(s=s()),typeof s=="object"?JSON.stringify(s)===JSON.stringify(y)&&(p[f]=i[f]):s===y&&(p[f]=i[f])}}return p},{})})}function Ft(t,o,r=0,{getter:a=i=>i,setter:l=i=>i}={}){let i;return typeof r=="string"&&(r=Number.parseInt(r)),(0,e.computed)({get:()=>a(t?.value),set:c=>{i&&clearTimeout(i),i=setTimeout(()=>{o("update:modelValue",l(c))},r)}})}function _e(t,o){const r=(0,e.computed)(()=>typeof t?.value=="string"?{name:t?.value}:t?.value),a=(0,e.computed)(()=>o?.value===q.before?r.value:void 0),l=(0,e.computed)(()=>o?.value===q.after?r.value:void 0);return{hasIcon:r,hasIconLeft:(0,e.computed)(()=>o?.value===P.left?r.value:void 0),hasIconRight:(0,e.computed)(()=>o?.value===P.right?r.value:void 0),hasIconTop:(0,e.computed)(()=>o?.value===P.top?r.value:void 0),hasIconBottom:(0,e.computed)(()=>o?.value===P.bottom?r.value:void 0),hasIconBefore:a,hasIconAfter:l}}function At(t,o){const{focused:r}=(0,w.useFocus)(t);return(0,e.watch)(r,a=>{o(a?"focus":"blur",(0,e.unref)(t))}),{focused:r}}function zt(t,o){const r=(0,e.computed)(()=>((0,e.unref)(t)??"").length),a=(0,e.computed)(()=>o?.lowerLimit!==void 0&&r.value<o?.lowerLimit?r.value-o.lowerLimit:o?.upperLimit!==void 0?o.upperLimit-r.value:0);return{length:r,gap:a,formatted:(0,e.computed)(()=>o?.mode===!1?"":o?.mode==="limit"&&o?.upperLimit?`${r.value} / ${o.lowerLimit?`${o.lowerLimit}-`:""}${o.upperLimit}`:o?.mode==="countdown"?a.value===0?void 0:a.value:r.value)}}function Tt(t,o=I.local,r){const a=(0,e.ref)();r&&(a.value=r);let l;return(0,e.onMounted)(()=>{t&&(0,e.watch)(t,(i,c)=>{const d=(0,e.unref)(o)===I.session?sessionStorage:localStorage;if(c&&c!==i&&d.removeItem(c),i){l=(0,w.useStorage)(i,l?.value??a.value,d),l.value&&(a.value=l.value);return}l=void 0},{immediate:!0}),(0,e.isRef)(o)&&(0,e.watch)(o,(i,c)=>{if(t?.value){if(i){const d=i===I.session?sessionStorage:localStorage;l=(0,w.useStorage)(t.value,l?.value??a.value,d)}c&&c!==i&&(c===I.session?sessionStorage:localStorage).removeItem(t.value)}})}),(0,e.watch)(a,i=>{l&&(l.value=i)},{deep:!0,immediate:!0}),a}var Ht=["for"],Mt={key:0,class:"vv-textarea__input-before"},qt={class:"vv-textarea__inner"},Wt=["id"],Kt={key:1,class:"vv-textarea__input-after"},Jt={key:2,class:"vv-textarea__limit"},Ut={class:"flex-1"},Yt=["title","onClick"],Gt={name:"VvTextarea"},Qt=(0,e.defineComponent)({...Gt,props:Ne,emits:mt,setup(t,{emit:o}){const r=t,a=o,l=(0,e.useSlots)(),i=ie(),c=jt("VvTextarea",Ne,r),d=(0,e.ref)(),p=(0,e.ref)(),f=(0,e.ref)(),{id:y,icon:s,iconPosition:g,iconRemoveSuggestion:C,labelRemoveSuggestion:x,label:O,modelValue:B,count:U,valid:de,invalid:ce,loading:D,modifiers:fe,debounce:ue,minlength:pe,maxlength:me,storageType:ge}=(0,e.toRefs)(r),$=De(y),_=(0,e.computed)(()=>`${$.value}-hint`),v=(0,e.computed)(()=>r.floating&&K(r.placeholder)?" ":r.placeholder),S=Ft(B,a,ue?.value),{hasIconBefore:V,hasIconAfter:E}=_e(s,g),{hasIcon:z}=_e(C),{focused:T}=At(d,a);(0,e.watch)((0,e.computed)(()=>T.value&&!r.disabled&&!r.readonly),u=>{if(u&&c.value.selectOnFocus&&d.value&&d.value.select(),u&&b.value?.size){f.value?.show();return}if(H.value&&b.value){const N=r.maxSuggestions;b.value.size>=N&&!b.value.has(S.value)&&(b.value=new Set([...b.value].slice(b.value.size-N+1))),b.value.add(S.value)}}),(0,e.watch)((0,w.useElementVisibility)(d),u=>{u&&r.autofocus&&(T.value=!0)});const{formatted:Y}=zt(S,{mode:U?.value,upperLimit:Number(me?.value),lowerLimit:Number(pe?.value)}),ve=(0,e.computed)(()=>!r.disabled&&!r.readonly),be=(0,e.computed)(()=>ve.value?r.tabindex:-1),H=(0,e.computed)(()=>!K(B)),he=(0,e.computed)(()=>{if(r.invalid===!0)return!0;if(r.valid===!0)return!1}),G=(0,e.computed)(()=>r.storageKey??(i?.experimentalFeatures.forceInputSuggestions?r.name:void 0)),b=Tt(G,ge,new Set),R=(0,e.computed)(()=>b.value?[...b.value].filter(u=>K(S.value)||`${u}`.toLowerCase().includes(`${S.value}`.toLowerCase())&&u!==S.value).reverse():[]),Q=(0,e.computed)(()=>G?.value&&b.value&&b.value.size>0);function ye(u){S.value=u,f.value?.hide(),a("suggestion:selected",u)}function X(u){b.value?.delete(u),a("suggestion:removed",u)}const{HintSlot:Z,hasHintLabelOrSlot:Se,hasInvalidLabelOrSlot:we,hintSlotScope:n}=vt(c,l),m=J("vv-textarea",fe,(0,e.computed)(()=>({valid:de.value,invalid:ce.value,loading:D.value,disabled:r.disabled,readonly:r.readonly,required:r.required,"icon-before":V.value!==void 0,"icon-after":E.value!==void 0,floating:r.floating&&!K(r.label),dirty:H.value,focus:T.value,resizable:r.resizable}))),k=(0,e.computed)(()=>({name:r.name,placeholder:v.value,tabindex:be.value,disabled:r.disabled,readonly:r.readonly,required:r.required,autocomplete:r.autocomplete,minlength:r.minlength,maxlength:r.maxlength,cols:r.cols,rows:r.rows,wrap:r.wrap,spellcheck:r.spellcheck,"aria-invalid":he.value,"aria-describedby":Se.value?_.value:void 0,"aria-errormessage":we.value?_.value:void 0})),M=(0,e.computed)(()=>({valid:r.valid,invalid:r.invalid,modelValue:r.modelValue,hintLabel:r.hintLabel,maxlength:r.maxlength,minlength:r.minlength,clear:Zt}));function Zt(){S.value=void 0}return(u,N)=>((0,e.openBlock)(),(0,e.createElementBlock)("div",{class:(0,e.normalizeClass)((0,e.unref)(m))},[(0,e.unref)(O)?((0,e.openBlock)(),(0,e.createElementBlock)("label",{key:0,for:(0,e.unref)($),class:"vv-textarea__label"},(0,e.toDisplayString)((0,e.unref)(O)),9,Ht)):(0,e.createCommentVNode)("v-if",!0),(0,e.createElementVNode)("div",{ref_key:"wrapperEl",ref:p,class:"vv-textarea__wrapper"},[u.$slots.before?((0,e.openBlock)(),(0,e.createElementBlock)("div",Mt,[(0,e.renderSlot)(u.$slots,"before",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(M))))])):(0,e.createCommentVNode)("v-if",!0),(0,e.createElementVNode)("div",qt,[(0,e.unref)(V)?((0,e.openBlock)(),(0,e.createBlock)(se,(0,e.mergeProps)({key:0},(0,e.unref)(V),{class:"vv-textarea__icon"}),null,16)):(0,e.createCommentVNode)("v-if",!0),(0,e.withDirectives)((0,e.createElementVNode)("textarea",(0,e.mergeProps)({id:(0,e.unref)($),ref_key:"textareaEl",ref:d,"onUpdate:modelValue":N[0]||(N[0]=L=>(0,e.isRef)(S)?S.value=L:null)},(0,e.unref)(k),{onKeyup:N[1]||(N[1]=L=>a("keyup",L))}),null,16,Wt),[[e.vModelText,(0,e.unref)(S)]]),(0,e.unref)(E)?((0,e.openBlock)(),(0,e.createBlock)(se,(0,e.mergeProps)({key:1},(0,e.unref)(E),{class:"vv-textarea__icon vv-textarea__icon-after"}),null,16)):(0,e.createCommentVNode)("v-if",!0)]),u.$slots.after?((0,e.openBlock)(),(0,e.createElementBlock)("div",Kt,[(0,e.renderSlot)(u.$slots,"after",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(M))))])):(0,e.createCommentVNode)("v-if",!0),(0,e.unref)(U)?((0,e.openBlock)(),(0,e.createElementBlock)("span",Jt,[(0,e.renderSlot)(u.$slots,"count",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(M))),()=>[(0,e.createTextVNode)((0,e.toDisplayString)((0,e.unref)(Y)),1)])])):(0,e.createCommentVNode)("v-if",!0)],512),(0,e.createVNode)((0,e.unref)(Z),{id:(0,e.unref)(_),class:"vv-textarea__hint"},(0,e.createSlots)({_:2},[u.$slots.hint?{name:"hint",fn:(0,e.withCtx)(()=>[(0,e.renderSlot)(u.$slots,"hint",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(n))))]),key:"0"}:void 0,u.$slots.loading?{name:"loading",fn:(0,e.withCtx)(()=>[(0,e.renderSlot)(u.$slots,"loading",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(n))))]),key:"1"}:void 0,u.$slots.valid?{name:"valid",fn:(0,e.withCtx)(()=>[(0,e.renderSlot)(u.$slots,"valid",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(n))))]),key:"2"}:void 0,u.$slots.invalid?{name:"invalid",fn:(0,e.withCtx)(()=>[(0,e.renderSlot)(u.$slots,"invalid",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(n))))]),key:"3"}:void 0]),1032,["id"]),(0,e.unref)(Q)?((0,e.openBlock)(),(0,e.createBlock)(Et,{key:1,ref_key:"suggestionsDropdownEl",ref:f,reference:(0,e.unref)(p),"autofocus-first":!1,"trigger-width":!0},{items:(0,e.withCtx)(()=>[((0,e.openBlock)(!0),(0,e.createElementBlock)(e.Fragment,null,(0,e.renderList)((0,e.unref)(R),L=>((0,e.openBlock)(),(0,e.createBlock)(Dt,{key:L,onClick:(0,e.withModifiers)(er=>ye(L),["stop"])},{default:(0,e.withCtx)(()=>[(0,e.createElementVNode)("div",Ut,[(0,e.renderSlot)(u.$slots,"suggestion",(0,e.mergeProps)({ref_for:!0},{value:L}),()=>[(0,e.createTextVNode)((0,e.toDisplayString)(L),1)])]),(0,e.unref)(b)&&(0,e.unref)(z)?((0,e.openBlock)(),(0,e.createElementBlock)("button",{key:0,type:"button",tabindex:"-1",class:"cursor-pointer",title:(0,e.unref)(x),onClick:(0,e.withModifiers)(er=>X(L),["stop"])},[(0,e.createVNode)(se,(0,e.mergeProps)({ref_for:!0},(0,e.unref)(z)),null,16)],8,Yt)):(0,e.createCommentVNode)("v-if",!0)]),_:2},1032,["onClick"]))),128))]),_:3},8,["reference"])):(0,e.createCommentVNode)("v-if",!0)],2))}}),Xt=Qt;return Xt});
|
|
1
|
+
(function(e,h){typeof exports=="object"&&typeof module<"u"?module.exports=h(require("vue"),require("@floating-ui/vue"),require("@vueuse/core"),require("mitt"),require("@iconify/vue")):typeof define=="function"&&define.amd?define(["vue","@floating-ui/vue","@vueuse/core","mitt","@iconify/vue"],h):(e=typeof globalThis<"u"?globalThis:e||self,e.VvTextarea=h(e.Vue,e.FloatingUiVue,e.VueuseCore,e.mitt,e.IconifyVue))})(this,function(e,h,S,ee,j){var Re=Object.create,Pe=Object.defineProperty,je=Object.getOwnPropertyDescriptor,Fe=Object.getOwnPropertyNames,Te=Object.getPrototypeOf,ze=Object.prototype.hasOwnProperty,Ae=(t,o,r,a)=>{if(o&&typeof o=="object"||typeof o=="function")for(var n=Fe(o),i=0,d=n.length,s;i<d;i++)s=n[i],!ze.call(t,s)&&s!==r&&Pe(t,s,{get:(m=>o[m]).bind(null,s),enumerable:!(a=je(o,s))||a.enumerable});return t},He=(t,o,r)=>(r=t!=null?Re(Te(t)):{},Ae(o||!t||!t.__esModule?Pe(r,"default",{value:t,enumerable:!0}):r,t));ee=He(ee,1);var xe={showPassword:"eye-on",hidePassword:"eye-off",showDatePicker:"calendar",showTimePicker:"time",showColorPicker:"color",clear:"close",add:"add",remove:"trash",edit:"edit",download:"download"},Me={prefix:"normal"},I=(function(t){return t.local="local",t.session="session",t})({}),Ce=(function(t){return t.absolute="absolute",t.fixed="fixed",t})({}),w=(function(t){return t.left="left",t.right="right",t.top="top",t.bottom="bottom",t})({}),qe=(function(t){return t.topStart="top-start",t.topEnd="top-end",t.bottomStart="bottom-start",t.bottomEnd="bottom-end",t.leftStart="left-start",t.leftEnd="left-end",t.rightStart="right-start",t.rightEnd="right-end",t})({}),q=(function(t){return t.before="before",t.after="after",t})({}),Ee=(function(t){return t.button="button",t.submit="submit",t.reset="reset",t})({}),We=(function(t){return t.nuxtLink="nuxt-link",t.routerLink="router-link",t.a="a",t.button="button",t})({}),Ke=(function(t){return t.button="button",t.link="link",t.menuitem="menuitem",t})({}),te=(function(t){return t.listbox="listbox",t.menu="menu",t})({}),ke=(function(t){return t.option="option",t.presentation="presentation",t})({}),Je=Symbol.for("volver"),Ue=Symbol.for("dropdownTrigger"),Ve=Symbol.for("dropdownItem"),Ye=Symbol.for("dropdownAction"),Ge={to:{type:[String,Object]},href:String,target:String,rel:{type:String,default:"noopener noreferrer"}},re={valid:{type:Boolean,default:!1},validLabel:{type:[String,Array],default:void 0}},oe={invalid:{type:Boolean,default:!1},invalidLabel:{type:[String,Array],default:void 0}},ae={loading:{type:Boolean,default:!1},loadingLabel:{type:String,default:"Loading..."}},F={disabled:{type:Boolean,default:!1}},Le={required:{type:Boolean,default:!1}},Qe={selected:{type:Boolean,default:!1}},Xe={active:{type:Boolean,default:!1}},Ze={current:{type:Boolean,default:!1}},rr={showClearAction:{type:Boolean,default:!1},iconClear:{type:[String,Object],default:xe.clear},labelClear:{type:String,default:"Clear"}},et={pressed:{type:Boolean,default:!1}},W={label:{type:[String,Number],default:void 0}},ne={readonly:{type:Boolean,default:!1}},T={modifiers:{type:[String,Array],default:void 0}},le={hintLabel:{type:String,default:""}},tt={options:{type:Array,default:()=>[]},labelKey:{type:[String,Function],default:"label"},valueKey:{type:[String,Function],default:"value"},disabledKey:{type:[String,Function],default:"disabled"}},rt={count:{type:[Boolean,String],default:!1,validator:t=>[!0,!1,"limit","countdown"].includes(t)}},ot={debounce:{type:[Number,String],default:void 0}},at={icon:{type:[String,Object],default:void 0},iconPosition:{type:String,default:q.before,validation:t=>Object.values(q).includes(t)}},Oe={tabindex:{type:[String,Number],default:0}},nt={floating:{type:Boolean,default:!1}},lt={unselectable:{type:Boolean,default:!0}},Be={id:[String,Number]},it={placement:{type:String,default:w.bottom,validator:t=>Object.values(w).includes(t)||Object.values(qe).includes(t)},strategy:{type:String,default:void 0,validator:t=>Object.values(Ce).includes(t)},transitionName:{type:String,default:void 0},offset:{type:[Number,String,Object],default:0},shift:{type:[Boolean,Object],default:!1},flip:{type:[Boolean,Object],default:!0},size:{type:[Boolean,Object],default:()=>({padding:10})},autoPlacement:{type:[Boolean,Object],default:!1},arrow:{type:Boolean,default:!1},keepOpen:{type:Boolean,default:!1},autofocusFirst:{type:Boolean,default:!0},triggerWidth:{type:Boolean,default:!1}},$e={...Be,name:{type:String,required:!0}},st={autofocus:{type:Boolean,default:!1}},dt={autocomplete:{type:String,default:"off"}},ct={...$e,...st,...dt,...Oe,...F,...ne,...re,...oe,...le,...ae,...T,...rt,...ot,...at,...nt,...W,minlength:{type:[String,Number],default:void 0},maxlength:{type:[String,Number],default:void 0},placeholder:{type:String,default:void 0},...Le},or={...$e,...Oe,...re,...oe,...le,...F,...ne,...T,...W,...ae,value:{type:[String,Number,Boolean],default:void 0},modelValue:{type:[Object,Number,Boolean,String],default:void 0}},ar={...re,...oe,...tt,...le,...F,...ne,...T,...W,...ae,...Le,modelValue:{type:[String,Array,Boolean,Number,Symbol],default:void 0},name:{type:String,required:!0},vertical:{type:Boolean,default:!1}},nr={...F,...W,...et,...Xe,...Ze,...Ge,type:{type:String,default:Ee.button,validator:t=>Object.values(Ee).includes(t)},ariaLabel:{type:String,default:void 0},defaultTag:{type:String,default:We.button}},ft={storageType:{type:String,default:I.local,validator:t=>Object.values(I).includes(t)},storageKey:String},ut={hard:"hard",soft:"soft"},pt={true:!0,false:!1,default:"default"},mt=["update:modelValue","focus","blur","keyup","suggestion:selected","suggestion:removed"],Ne={...ct,...ft,modelValue:String,cols:{type:[String,Number],default:20},rows:{type:[String,Number],default:2},wrap:{type:String,default:ut.soft},spellcheck:{type:[Boolean,String],default:pt.default},iconRemoveSuggestion:{type:[String,Object],default:xe.remove},labelRemoveSuggestion:{type:String,default:"Remove suggestion"},maxSuggestions:{type:Number,default:5},selectOnFocus:{type:Boolean,default:!1},resizable:Boolean};function K(t){return(o=>o==null||o===""||Array.isArray(o)&&o.length===0||!(o instanceof Date)&&typeof o=="object"&&Object.keys(o).length===0)((0,e.unref)(t))}function gt(t){return typeof t=="string"}function Ie(t){return Array.isArray(t)?t.filter(o=>gt(o)).join(" "):t}function vt(t,o){const r=(0,e.computed)(()=>(0,e.isRef)(t)?t.value:t),a=(0,e.computed)(()=>Ie(r.value.invalidLabel)),n=(0,e.computed)(()=>Ie(r.value.validLabel)),i=(0,e.computed)(()=>r.value.loadingLabel),d=(0,e.computed)(()=>r.value.hintLabel),s=(0,e.computed)(()=>!!(r.value.loading&&(o.loading||i.value))),m=(0,e.computed)(()=>!s.value&&!!(r.value.invalid&&(o.invalid||a.value))),b=(0,e.computed)(()=>!s.value&&!m.value&&!!(r.value.valid&&(o.valid||n.value))),P=(0,e.computed)(()=>!s.value&&!m.value&&!b.value&&!!(o.hint||d.value)),c=(0,e.computed)(()=>m.value||b.value||s.value||P.value);return{hasInvalidLabelOrSlot:m,hasHintLabelOrSlot:P,hasValidLabelOrSlot:b,hasLoadingLabelOrSlot:s,hintSlotScope:(0,e.computed)(()=>({modelValue:r.value.modelValue,valid:r.value.valid,invalid:r.value.invalid,loading:r.value.loading})),HintSlot:(0,e.defineComponent)({name:"HintSlot",props:{tag:{type:String,default:"small"}},setup(){return{isVisible:c,invalidLabel:a,validLabel:n,loadingLabel:i,hintLabel:d,hasInvalidLabelOrSlot:m,hasValidLabelOrSlot:b,hasLoadingLabelOrSlot:s,hasHintLabelOrSlot:P}},render(){if(this.isVisible){let g;return this.hasInvalidLabelOrSlot&&(g="alert"),this.hasValidLabelOrSlot&&(g="status"),this.hasLoadingLabelOrSlot?(0,e.h)(this.tag,{role:g},this.$slots.loading?.()??this.loadingLabel):this.hasInvalidLabelOrSlot?(0,e.h)(this.tag,{role:g},this.$slots.invalid?.()??this.$slots.invalid??this.invalidLabel):this.hasValidLabelOrSlot?(0,e.h)(this.tag,{role:g},this.$slots.valid?.()??this.validLabel):(0,e.h)(this.tag,{role:g},this.$slots.hint?.()??this.$slots.hint??this.hintLabel)}return null}})}}var bt={...Be,...it,...T,modelValue:{type:Boolean,default:void 0},reference:{type:Object,default:null},role:{type:String,default:te.menu,validator:t=>Object.values(te).includes(t)}},ht={focusOnHover:{type:Boolean,default:!1}},yt={...F,...Qe,...lt,...T,deselectHintLabel:{type:String},selectHintLabel:{type:String},selectedHintLabel:{type:String},focusOnHover:{type:Boolean,default:!1}};function De(t){return(0,e.computed)(()=>String(t?.value||(0,e.useId)()))}function St({reference:t,id:o,expanded:r,aria:a}){const n=(0,ee.default)();return{bus:n,component:(0,e.defineComponent)({name:"VvDropdownTriggerProvider",setup(){(0,e.provide)(Ue,{reference:t,id:o,expanded:r,aria:a,bus:n})},render(){return(0,e.h)(e.Fragment,{},this.$slots.default?.())}})}}function wt({role:t,...o}){const r=(0,e.computed)(()=>t.value===te.listbox?ke.option:ke.presentation);return(0,e.provide)(Ve,{role:r,...o}),{itemRole:r}}function Pt({expanded:t}){(0,e.provide)(Ye,{role:(0,e.ref)(Ke.menuitem),expanded:t})}function J(t,o,r){return(0,e.computed)(()=>{const a={[t]:!0},n=typeof o?.value=="string"?o.value.split(" "):o?.value;return n&&Array.isArray(n)&&n.forEach(i=>{i&&(a[`${t}--${i}`]=!0)}),r&&Object.keys(r.value).forEach(i=>{a[`${t}--${i}`]=(0,e.unref)(r.value[i])}),a})}var xt=["id","tabindex","role","aria-labelledby"],Ct={name:"VvDropdown",inheritAttrs:!1},Et=(0,e.defineComponent)({...Ct,props:bt,emits:["update:modelValue","beforeEnter","afterLeave","beforeExpand","beforeCollapse","afterExpand","afterCollapse","before-enter","after-leave","enter","afterEnter","enterCancelled","beforeLeave","leave","leaveCancelled"],setup(t,{expose:o,emit:r}){const a=t,n=r,{id:i}=(0,e.toRefs)(a),d=De(i),s=(0,e.useAttrs)(),m=(0,e.ref)("auto"),b=(0,e.ref)("auto"),P=(0,e.ref)(),c=(0,e.ref)(),g=(0,e.ref)(),C=(0,e.ref)(),x=(0,e.computed)({get:()=>a.reference??P.value,set:l=>{P.value=l}}),L=(0,e.ref)(!1);(0,e.onMounted)(()=>{(0,S.useMutationObserver)(c.value,()=>{L.value=globalThis.getComputedStyle(c.value).getPropertyValue("--dropdown-custom-position")?.trim()==="true"},{attributeFilter:["style"],window:globalThis.window})});function O(l,u,$){return typeof l=="boolean"?u():$(l)}const U=(0,e.computed)(()=>{const l=[];if(a.autoPlacement?l.push(O(a.autoPlacement,()=>(0,h.autoPlacement)(),u=>(0,h.autoPlacement)(u))):a.flip&&l.push(O(a.flip,()=>(0,h.flip)({fallbackStrategy:"initialPlacement"}),u=>(0,h.flip)(u))),a.shift&&l.push(O(a.shift,()=>(0,h.shift)(),u=>(0,h.shift)(u))),a.size){const u=({availableWidth:$,availableHeight:M})=>{m.value=`${$}px`,b.value=`${M}px`};l.push(O(a.size,()=>(0,h.size)({apply:u}),$=>(0,h.size)({...$,apply:u})))}return a.offset&&l.push(["string","number"].includes(typeof a.offset)?(0,h.offset)(Number(a.offset)):(0,h.offset)(a.offset)),a.arrow&&l.push((0,h.arrow)({element:g})),l}),{x:de,y:ce,middlewareData:D,placement:fe,strategy:ue}=(0,h.useFloating)(x,c,{whileElementsMounted:(...l)=>(0,h.autoUpdate)(...l,{animationFrame:a.strategy===Ce.fixed}),placement:(0,e.computed)(()=>a.placement),strategy:(0,e.computed)(()=>a.strategy),middleware:U}),pe=(0,e.computed)(()=>{if(L.value)return;const l=a.triggerWidth&&x.value?`${x.value?.offsetWidth}px`:void 0;return{position:ue.value,top:`${ce.value??0}px`,left:`${de.value??0}px`,maxWidth:l?void 0:m.value,maxHeight:b.value,width:l}}),me=(0,e.computed)(()=>fe.value.split("-")[0]),ge=(0,e.computed)(()=>{if(L.value)return;const l={[w.top]:w.bottom,[w.right]:w.left,[w.bottom]:w.top,[w.left]:w.right}[me.value];return{left:D.value.arrow?.x===void 0?void 0:`${D.value.arrow?.x}px`,top:D.value.arrow?.y===void 0?void 0:`${D.value.arrow?.y}px`,[l]:`${-(g.value?.offsetWidth??0)/2}px`}}),B=(0,S.useVModel)(a,"modelValue",n),_=(0,e.ref)(!1),p=(0,e.computed)({get:()=>B.value??_.value,set:l=>{if(B.value===void 0){_.value=l;return}B.value=l}});function y(){p.value=!0}function E(){p.value=!1}function k(){p.value=!p.value}function z(l){x.value=l}(0,S.onClickOutside)(c,()=>{!a.keepOpen&&p.value&&(p.value=!1)},{ignore:[x]});const A=(0,e.computed)(()=>x.value?.getAttribute?.("id")??void 0),Y=(0,e.computed)(()=>({"aria-controls":d.value,"aria-haspopup":!0,"aria-expanded":p.value})),{component:ve,bus:be}=St({reference:x,id:d,expanded:p,aria:Y});be.on("click",k);const{role:H,modifiers:he}=(0,e.toRefs)(a),G=J("vv-dropdown",he,(0,e.computed)(()=>({arrow:a.arrow}))),{focused:v}=(0,S.useFocusWithin)(c);function R(l){return l?[...l.querySelectorAll('a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"])')].filter(u=>!u.hasAttribute("disabled")&&!u.getAttribute("aria-hidden")):[]}function Q(){(0,e.nextTick)(()=>{const l=R(c.value);l.length>0&&l[0].focus({preventScroll:!0})})}function ye(){(0,e.nextTick)(()=>{const l=R(C.value);l.length>0&&l[0].focus({preventScroll:!0})})}function X(){(0,e.nextTick)(()=>{if(v.value){const l=R(c.value);if(l.length===0||!document.activeElement)return;const u=l.indexOf(document.activeElement);u<l.length-1?l[u+1].focus({preventScroll:!0}):l[0].focus({preventScroll:!0})}})}function Z(){(0,e.nextTick)(()=>{if(v.value){const l=R(c.value);if(l.length===0||!document.activeElement)return;const u=l.indexOf(document.activeElement);if(u>0){l[u-1].focus({preventScroll:!0});return}l.at(-1)?.focus({preventScroll:!0})}})}(0,e.watch)(p,l=>{l&&a.autofocusFirst&&Q()}),o({toggle:k,show:y,hide:E,init:z,focusFirst:Q,focusFirstListElement:ye,focusNext:X,focusPrev:Z,customPosition:L});const{itemRole:Se}=wt({role:H,expanded:p,focused:v,hovered:(0,S.useElementHover)(c)});(0,S.onKeyStroke)("Escape",l=>{p.value&&(l.preventDefault(),E())}),(0,S.onKeyStroke)("ArrowDown",l=>{p.value&&v.value&&(l.preventDefault(),X())}),(0,S.onKeyStroke)("ArrowUp",l=>{p.value&&v.value&&(l.preventDefault(),Z())}),(0,S.onKeyStroke)([" ","Enter"],l=>{const u=l.target;p.value&&v.value&&u&&u?.click()});const we={"before-enter":()=>{n(p.value?"beforeExpand":"beforeCollapse"),n("beforeEnter")},"after-leave":()=>{n(p.value?"afterExpand":"afterCollapse"),n("afterLeave")},enter:()=>{n("enter")},"after-enter":()=>{n("afterEnter")},"enter-cancelled":()=>{n("enterCancelled")},"before-leave":()=>{n("beforeLeave")},leave:()=>{n("leave")},"leave-cancelled":()=>{n("leaveCancelled")}};return(l,u)=>((0,e.openBlock)(),(0,e.createElementBlock)(e.Fragment,null,[(0,e.createVNode)((0,e.unref)(ve),null,{default:(0,e.withCtx)(()=>[(0,e.renderSlot)(l.$slots,"default",(0,e.normalizeProps)((0,e.guardReactiveProps)({init:z,show:y,hide:E,toggle:k,expanded:(0,e.unref)(p),aria:(0,e.unref)(Y)})))]),_:3}),(0,e.createVNode)(e.Transition,(0,e.mergeProps)({name:l.transitionName},(0,e.toHandlers)(we),{persisted:""}),{default:(0,e.withCtx)(()=>[(0,e.withDirectives)((0,e.createElementVNode)("div",{ref_key:"floatingEl",ref:c,style:(0,e.normalizeStyle)((0,e.unref)(pe)),class:(0,e.normalizeClass)((0,e.unref)(G))},[a.arrow?((0,e.openBlock)(),(0,e.createElementBlock)("div",{key:0,ref_key:"arrowEl",ref:g,style:(0,e.normalizeStyle)((0,e.unref)(ge)),class:"vv-dropdown__arrow"},null,4)):(0,e.createCommentVNode)("v-if",!0),(0,e.renderSlot)(l.$slots,"before",(0,e.normalizeProps)((0,e.guardReactiveProps)({show:y,hide:E,toggle:k,expanded:(0,e.unref)(p)}))),(0,e.createElementVNode)("div",(0,e.mergeProps)((0,e.unref)(s),{id:(0,e.unref)(d),ref_key:"listEl",ref:C,tabindex:(0,e.unref)(p)?void 0:-1,role:(0,e.unref)(H),"aria-labelledby":(0,e.unref)(A),class:"vv-dropdown__list"}),[(0,e.renderSlot)(l.$slots,"items",(0,e.normalizeProps)((0,e.guardReactiveProps)({show:y,hide:E,toggle:k,expanded:(0,e.unref)(p),role:(0,e.unref)(Se)})))],16,xt),(0,e.renderSlot)(l.$slots,"after",(0,e.normalizeProps)((0,e.guardReactiveProps)({show:y,hide:E,toggle:k,expanded:(0,e.unref)(p)})))],6),[[e.vShow,(0,e.unref)(p)]])]),_:3},16,["name"])],64))}}),kt=Et;function Vt(){return(0,e.inject)(Ve,{})}var Lt={name:"VvDropdownItem"},Ot=(0,e.defineComponent)({...Lt,props:ht,setup(t){const o=t,{role:r,expanded:a}=Vt(),n=(0,e.ref)(null);Pt({expanded:a});const i=(0,S.useElementHover)(n),{focused:d}=(0,S.useFocus)(n),{focused:s}=(0,S.useFocusWithin)(n);return(0,e.watch)(i,m=>{m&&o.focusOnHover&&(d.value=!0)}),(m,b)=>((0,e.openBlock)(),(0,e.createElementBlock)("div",(0,e.mergeProps)({role:(0,e.unref)(r)},{ref_key:"element",ref:n,class:["vv-dropdown__item",{"focus-visible":(0,e.unref)(d)||(0,e.unref)(s)}]}),[(0,e.renderSlot)(m.$slots,"default")],16))}}),Bt=Ot,$t=["title"],Nt={name:"VvDropdownOption"},It=(0,e.defineComponent)({...Nt,props:yt,setup(t){const o=t,{modifiers:r}=(0,e.toRefs)(o),a=J("vv-dropdown-option",r,(0,e.computed)(()=>({disabled:o.disabled,selected:o.selected,unselectable:o.unselectable&&o.selected}))),n=(0,e.computed)(()=>o.selected?o.unselectable?o.deselectHintLabel:o.selectedHintLabel:o.disabled?"":o.selectHintLabel);return(i,d)=>((0,e.openBlock)(),(0,e.createBlock)(Bt,{class:(0,e.normalizeClass)((0,e.unref)(a)),tabindex:i.disabled?-1:0,"aria-selected":i.selected,"aria-disabled":i.disabled,"focus-on-hover":i.focusOnHover},{default:(0,e.withCtx)(()=>[(0,e.renderSlot)(i.$slots,"default"),(0,e.createElementVNode)("span",{class:"vv-dropdown-option__hint",title:(0,e.unref)(n)},[(0,e.renderSlot)(i.$slots,"hint",(0,e.normalizeProps)((0,e.guardReactiveProps)({disabled:i.disabled,selected:i.selected,unselectable:i.unselectable})),()=>[(0,e.createTextVNode)((0,e.toDisplayString)((0,e.unref)(n)),1)])],8,$t)]),_:3},8,["class","tabindex","aria-selected","aria-disabled","focus-on-hover"]))}}),Dt=It;function ie(){return(0,e.inject)(Je,void 0)}var _t={name:"VvIcon"},Rt=(0,e.defineComponent)({..._t,props:(0,e.mergeDefaults)({name:{},color:{},width:{},height:{},provider:{},prefix:{},src:{},horizontalFlip:{type:Boolean},verticalFlip:{type:Boolean},flip:{},mode:{},inline:{type:Boolean},rotate:{},onLoad:{type:Function},svg:{},modifiers:{}},Me),setup(t){const o=t,r=(0,e.computed)(()=>typeof o.rotate=="string"?Number.parseFloat(o.rotate):o.rotate),a=(0,e.ref)(!0),n=ie(),{modifiers:i}=(0,e.toRefs)(o),d=J("vv-icon",i),s=(0,e.computed)(()=>o.provider||n?.iconsProvider),m=(0,e.computed)(()=>{const c=o.name??"",g=`@${s.value}:${o.prefix}:${c}`;if((0,j.iconLoaded)(g))return g;const C=n?.iconsCollections.find(x=>(0,j.iconLoaded)(`@${s.value}:${x.prefix}:${c}`));return C?`@${s.value}:${C.prefix}:${c}`:c});function b(c){return globalThis.window===void 0?null:new globalThis.DOMParser().parseFromString(c,"text/html").querySelector("svg")}function P(c){const g=b(c),C=g?.innerHTML.trim()||"";g&&C&&(0,j.addIcon)(`@${s.value}:${o.prefix}:${o.name}`,{body:C,height:g.viewBox.baseVal.height,width:g.viewBox.baseVal.width})}return n&&o.src&&!(0,j.iconLoaded)(`@${s.value}:${o.prefix}:${o.name}`)&&(a.value=!1,n.fetchIcon(o.src).then(c=>{c&&P(c),a.value=!0}).catch(c=>{throw a.value=!0,new Error(`Error during fetch icon: ${c?.message}`)})),o.svg&&P(o.svg),(c,g)=>(0,e.unref)(a)?((0,e.openBlock)(),(0,e.createBlock)((0,e.unref)(j.Icon),(0,e.mergeProps)({key:0,class:(0,e.unref)(d)},{inline:t.inline,width:t.width,height:t.height,horizontalFlip:t.horizontalFlip,verticalFlip:t.verticalFlip,flip:t.flip,rotate:(0,e.unref)(r),color:t.color,icon:(0,e.unref)(m)},{onLoad:t.onLoad}),null,16,["class","onLoad"])):(0,e.createCommentVNode)("v-if",!0)}}),se=Rt;function jt(t,o,r){let a=o;if(Array.isArray(t)&&t.length){const n=t[0];n()===o&&(a=r)}if(typeof t=="function"&&t()===o&&(a=r),typeof t=="object"){let n=t.default;typeof n=="function"&&(n=n()),(typeof n=="object"?JSON.stringify(n)===JSON.stringify(o):n===o)&&(a=r)}return a}function Ft(t,o,r){const a=ie(),n=(0,e.computed)(()=>{if(a?.defaults.value?.[t])return a.defaults.value[t]});return(0,e.computed)(()=>{if(n.value===void 0)return r;const i=n.value,d=o,s=r;return Object.keys(d).reduce((m,b)=>{const P=s[b];return m[b]=b in i?jt(d[b],P,i[b]):P,m},{})})}function Tt(t,o,r=0,{getter:a=i=>i,setter:n=i=>i}={}){let i;return typeof r=="string"&&(r=Number.parseInt(r)),(0,e.computed)({get:()=>a(t?.value),set:d=>{i&&clearTimeout(i),i=setTimeout(()=>{o("update:modelValue",n(d))},r)}})}function _e(t,o){const r=(0,e.computed)(()=>typeof t?.value=="string"?{name:t?.value}:t?.value),a=(0,e.computed)(()=>o?.value===q.before?r.value:void 0),n=(0,e.computed)(()=>o?.value===q.after?r.value:void 0);return{hasIcon:r,hasIconLeft:(0,e.computed)(()=>o?.value===w.left?r.value:void 0),hasIconRight:(0,e.computed)(()=>o?.value===w.right?r.value:void 0),hasIconTop:(0,e.computed)(()=>o?.value===w.top?r.value:void 0),hasIconBottom:(0,e.computed)(()=>o?.value===w.bottom?r.value:void 0),hasIconBefore:a,hasIconAfter:n}}function zt(t,o){const{focused:r}=(0,S.useFocus)(t);return(0,e.watch)(r,a=>{o(a?"focus":"blur",(0,e.unref)(t))}),{focused:r}}function At(t,o){const r=(0,e.computed)(()=>((0,e.unref)(t)??"").length),a=(0,e.computed)(()=>o?.lowerLimit!==void 0&&r.value<o?.lowerLimit?r.value-o.lowerLimit:o?.upperLimit!==void 0?o.upperLimit-r.value:0);return{length:r,gap:a,formatted:(0,e.computed)(()=>o?.mode===!1?"":o?.mode==="limit"&&o?.upperLimit?`${r.value} / ${o.lowerLimit?`${o.lowerLimit}-`:""}${o.upperLimit}`:o?.mode==="countdown"?a.value===0?void 0:a.value:r.value)}}function Ht(t,o=I.local,r){const a=(0,e.ref)();r&&(a.value=r);let n;return(0,e.onMounted)(()=>{t&&(0,e.watch)(t,(i,d)=>{const s=(0,e.unref)(o)===I.session?sessionStorage:localStorage;if(d&&d!==i&&s.removeItem(d),i){n=(0,S.useStorage)(i,n?.value??a.value,s),n.value&&(a.value=n.value);return}n=void 0},{immediate:!0}),(0,e.isRef)(o)&&(0,e.watch)(o,(i,d)=>{if(t?.value){if(i){const s=i===I.session?sessionStorage:localStorage;n=(0,S.useStorage)(t.value,n?.value??a.value,s)}d&&d!==i&&(d===I.session?sessionStorage:localStorage).removeItem(t.value)}})}),(0,e.watch)(a,i=>{n&&(n.value=i)},{deep:!0,immediate:!0}),a}var Mt=["for"],qt={key:0,class:"vv-textarea__input-before"},Wt={class:"vv-textarea__inner"},Kt=["id"],Jt={key:1,class:"vv-textarea__input-after"},Ut={key:2,class:"vv-textarea__limit"},Yt={class:"flex-1"},Gt=["title","onClick"],Qt={name:"VvTextarea"},Xt=(0,e.defineComponent)({...Qt,props:Ne,emits:mt,setup(t,{emit:o}){const r=t,a=o,n=(0,e.useSlots)(),i=ie(),d=Ft("VvTextarea",Ne,r),s=(0,e.ref)(),m=(0,e.ref)(),b=(0,e.ref)(),{id:P,icon:c,iconPosition:g,iconRemoveSuggestion:C,labelRemoveSuggestion:x,label:L,modelValue:O,count:U,valid:de,invalid:ce,loading:D,modifiers:fe,debounce:ue,minlength:pe,maxlength:me,storageType:ge}=(0,e.toRefs)(r),B=De(P),_=(0,e.computed)(()=>`${B.value}-hint`),p=(0,e.computed)(()=>r.floating&&K(r.placeholder)?" ":r.placeholder),y=Tt(O,a,ue?.value),{hasIconBefore:E,hasIconAfter:k}=_e(c,g),{hasIcon:z}=_e(C),{focused:A}=zt(s,a);(0,e.watch)((0,e.computed)(()=>A.value&&!r.disabled&&!r.readonly),f=>{if(f&&d.value.selectOnFocus&&s.value&&s.value.select(),f&&v.value?.size){b.value?.show();return}if(H.value&&v.value){const N=r.maxSuggestions;v.value.size>=N&&!v.value.has(y.value)&&(v.value=new Set([...v.value].slice(v.value.size-N+1))),v.value.add(y.value)}}),(0,e.watch)((0,S.useElementVisibility)(s),f=>{f&&r.autofocus&&(A.value=!0)});const{formatted:Y}=At(y,{mode:U?.value,upperLimit:Number(me?.value),lowerLimit:Number(pe?.value)}),ve=(0,e.computed)(()=>!r.disabled&&!r.readonly),be=(0,e.computed)(()=>ve.value?r.tabindex:-1),H=(0,e.computed)(()=>!K(O)),he=(0,e.computed)(()=>{if(r.invalid===!0)return!0;if(r.valid===!0)return!1}),G=(0,e.computed)(()=>r.storageKey??(i?.experimentalFeatures.forceInputSuggestions?r.name:void 0)),v=Ht(G,ge,new Set),R=(0,e.computed)(()=>v.value?[...v.value].filter(f=>K(y.value)||`${f}`.toLowerCase().includes(`${y.value}`.toLowerCase())&&f!==y.value).reverse():[]),Q=(0,e.computed)(()=>G?.value&&v.value&&v.value.size>0);function ye(f){y.value=f,b.value?.hide(),a("suggestion:selected",f)}function X(f){v.value?.delete(f),a("suggestion:removed",f)}const{HintSlot:Z,hasHintLabelOrSlot:Se,hasInvalidLabelOrSlot:we,hintSlotScope:l}=vt(d,n),u=J("vv-textarea",fe,(0,e.computed)(()=>({valid:de.value,invalid:ce.value,loading:D.value,disabled:r.disabled,readonly:r.readonly,required:r.required,"icon-before":E.value!==void 0,"icon-after":k.value!==void 0,floating:r.floating&&!K(r.label),dirty:H.value,focus:A.value,resizable:r.resizable}))),$=(0,e.computed)(()=>({name:r.name,placeholder:p.value,tabindex:be.value,disabled:r.disabled,readonly:r.readonly,required:r.required,autocomplete:r.autocomplete,minlength:r.minlength,maxlength:r.maxlength,cols:r.cols,rows:r.rows,wrap:r.wrap,spellcheck:r.spellcheck,"aria-invalid":he.value,"aria-describedby":Se.value?_.value:void 0,"aria-errormessage":we.value?_.value:void 0})),M=(0,e.computed)(()=>({valid:r.valid,invalid:r.invalid,modelValue:r.modelValue,hintLabel:r.hintLabel,maxlength:r.maxlength,minlength:r.minlength,clear:er}));function er(){y.value=void 0}return(f,N)=>((0,e.openBlock)(),(0,e.createElementBlock)("div",{class:(0,e.normalizeClass)((0,e.unref)(u))},[(0,e.unref)(L)?((0,e.openBlock)(),(0,e.createElementBlock)("label",{key:0,for:(0,e.unref)(B),class:"vv-textarea__label"},(0,e.toDisplayString)((0,e.unref)(L)),9,Mt)):(0,e.createCommentVNode)("v-if",!0),(0,e.createElementVNode)("div",{ref_key:"wrapperEl",ref:m,class:"vv-textarea__wrapper"},[f.$slots.before?((0,e.openBlock)(),(0,e.createElementBlock)("div",qt,[(0,e.renderSlot)(f.$slots,"before",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(M))))])):(0,e.createCommentVNode)("v-if",!0),(0,e.createElementVNode)("div",Wt,[(0,e.unref)(E)?((0,e.openBlock)(),(0,e.createBlock)(se,(0,e.mergeProps)({key:0},(0,e.unref)(E),{class:"vv-textarea__icon"}),null,16)):(0,e.createCommentVNode)("v-if",!0),(0,e.withDirectives)((0,e.createElementVNode)("textarea",(0,e.mergeProps)({id:(0,e.unref)(B),ref_key:"textareaEl",ref:s,"onUpdate:modelValue":N[0]||(N[0]=V=>(0,e.isRef)(y)?y.value=V:null)},(0,e.unref)($),{onKeyup:N[1]||(N[1]=V=>a("keyup",V))}),null,16,Kt),[[e.vModelText,(0,e.unref)(y)]]),(0,e.unref)(k)?((0,e.openBlock)(),(0,e.createBlock)(se,(0,e.mergeProps)({key:1},(0,e.unref)(k),{class:"vv-textarea__icon vv-textarea__icon-after"}),null,16)):(0,e.createCommentVNode)("v-if",!0)]),f.$slots.after?((0,e.openBlock)(),(0,e.createElementBlock)("div",Jt,[(0,e.renderSlot)(f.$slots,"after",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(M))))])):(0,e.createCommentVNode)("v-if",!0),(0,e.unref)(U)?((0,e.openBlock)(),(0,e.createElementBlock)("span",Ut,[(0,e.renderSlot)(f.$slots,"count",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(M))),()=>[(0,e.createTextVNode)((0,e.toDisplayString)((0,e.unref)(Y)),1)])])):(0,e.createCommentVNode)("v-if",!0)],512),(0,e.createVNode)((0,e.unref)(Z),{id:(0,e.unref)(_),class:"vv-textarea__hint"},(0,e.createSlots)({_:2},[f.$slots.hint?{name:"hint",fn:(0,e.withCtx)(()=>[(0,e.renderSlot)(f.$slots,"hint",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(l))))]),key:"0"}:void 0,f.$slots.loading?{name:"loading",fn:(0,e.withCtx)(()=>[(0,e.renderSlot)(f.$slots,"loading",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(l))))]),key:"1"}:void 0,f.$slots.valid?{name:"valid",fn:(0,e.withCtx)(()=>[(0,e.renderSlot)(f.$slots,"valid",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(l))))]),key:"2"}:void 0,f.$slots.invalid?{name:"invalid",fn:(0,e.withCtx)(()=>[(0,e.renderSlot)(f.$slots,"invalid",(0,e.normalizeProps)((0,e.guardReactiveProps)((0,e.unref)(l))))]),key:"3"}:void 0]),1032,["id"]),(0,e.unref)(Q)?((0,e.openBlock)(),(0,e.createBlock)(kt,{key:1,ref_key:"suggestionsDropdownEl",ref:b,reference:(0,e.unref)(m),"autofocus-first":!1,"trigger-width":!0},{items:(0,e.withCtx)(()=>[((0,e.openBlock)(!0),(0,e.createElementBlock)(e.Fragment,null,(0,e.renderList)((0,e.unref)(R),V=>((0,e.openBlock)(),(0,e.createBlock)(Dt,{key:V,onClick:(0,e.withModifiers)(tr=>ye(V),["stop"])},{default:(0,e.withCtx)(()=>[(0,e.createElementVNode)("div",Yt,[(0,e.renderSlot)(f.$slots,"suggestion",(0,e.mergeProps)({ref_for:!0},{value:V}),()=>[(0,e.createTextVNode)((0,e.toDisplayString)(V),1)])]),(0,e.unref)(v)&&(0,e.unref)(z)?((0,e.openBlock)(),(0,e.createElementBlock)("button",{key:0,type:"button",tabindex:"-1",class:"cursor-pointer",title:(0,e.unref)(x),onClick:(0,e.withModifiers)(tr=>X(V),["stop"])},[(0,e.createVNode)(se,(0,e.mergeProps)({ref_for:!0},(0,e.unref)(z)),null,16)],8,Gt)):(0,e.createCommentVNode)("v-if",!0)]),_:2},1032,["onClick"]))),128))]),_:3},8,["reference"])):(0,e.createCommentVNode)("v-if",!0)],2))}}),Zt=Xt;return Zt});
|
|
@@ -0,0 +1,384 @@
|
|
|
1
|
+
declare const _default: typeof __VLS_export;
|
|
2
|
+
export default _default;
|
|
3
|
+
declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<globalThis.ExtractPropTypes<{
|
|
4
|
+
modelValue: StringConstructor;
|
|
5
|
+
cols: {
|
|
6
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
7
|
+
default: number;
|
|
8
|
+
};
|
|
9
|
+
rows: {
|
|
10
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
11
|
+
default: number;
|
|
12
|
+
};
|
|
13
|
+
wrap: {
|
|
14
|
+
type: StringConstructor;
|
|
15
|
+
default: string;
|
|
16
|
+
};
|
|
17
|
+
spellcheck: {
|
|
18
|
+
type: (BooleanConstructor | StringConstructor)[];
|
|
19
|
+
default: string;
|
|
20
|
+
};
|
|
21
|
+
iconRemoveSuggestion: {
|
|
22
|
+
type: PropType<string | import("../VvIcon").VvIconProps>;
|
|
23
|
+
default: "trash";
|
|
24
|
+
};
|
|
25
|
+
labelRemoveSuggestion: {
|
|
26
|
+
type: StringConstructor;
|
|
27
|
+
default: string;
|
|
28
|
+
};
|
|
29
|
+
maxSuggestions: {
|
|
30
|
+
type: NumberConstructor;
|
|
31
|
+
default: number;
|
|
32
|
+
};
|
|
33
|
+
selectOnFocus: {
|
|
34
|
+
type: BooleanConstructor;
|
|
35
|
+
default: boolean;
|
|
36
|
+
};
|
|
37
|
+
resizable: BooleanConstructor;
|
|
38
|
+
storageType: {
|
|
39
|
+
type: PropType<`${import("../../constants").StorageType}`>;
|
|
40
|
+
default: import("../../constants").StorageType;
|
|
41
|
+
validator: (value: import("../../constants").StorageType) => boolean;
|
|
42
|
+
};
|
|
43
|
+
storageKey: StringConstructor;
|
|
44
|
+
required: {
|
|
45
|
+
type: BooleanConstructor;
|
|
46
|
+
default: boolean;
|
|
47
|
+
};
|
|
48
|
+
minlength: {
|
|
49
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
50
|
+
default: undefined;
|
|
51
|
+
};
|
|
52
|
+
maxlength: {
|
|
53
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
54
|
+
default: undefined;
|
|
55
|
+
};
|
|
56
|
+
placeholder: {
|
|
57
|
+
type: StringConstructor;
|
|
58
|
+
default: undefined;
|
|
59
|
+
};
|
|
60
|
+
label: {
|
|
61
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
62
|
+
default: undefined;
|
|
63
|
+
};
|
|
64
|
+
floating: {
|
|
65
|
+
type: BooleanConstructor;
|
|
66
|
+
default: boolean;
|
|
67
|
+
};
|
|
68
|
+
icon: {
|
|
69
|
+
type: PropType<string | import("../VvIcon").VvIconProps>;
|
|
70
|
+
default: undefined;
|
|
71
|
+
};
|
|
72
|
+
iconPosition: {
|
|
73
|
+
type: PropType<`${import("../../constants").Position}`>;
|
|
74
|
+
default: import("../../constants").Position;
|
|
75
|
+
validation: (value: import("../../constants").Position) => boolean;
|
|
76
|
+
};
|
|
77
|
+
debounce: {
|
|
78
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
79
|
+
default: undefined;
|
|
80
|
+
};
|
|
81
|
+
count: {
|
|
82
|
+
type: (BooleanConstructor | StringConstructor)[];
|
|
83
|
+
default: boolean;
|
|
84
|
+
validator: (value: string) => boolean;
|
|
85
|
+
};
|
|
86
|
+
modifiers: {
|
|
87
|
+
type: PropType<string | string[]>;
|
|
88
|
+
default: undefined;
|
|
89
|
+
};
|
|
90
|
+
loading: {
|
|
91
|
+
type: BooleanConstructor;
|
|
92
|
+
default: boolean;
|
|
93
|
+
};
|
|
94
|
+
loadingLabel: {
|
|
95
|
+
type: StringConstructor;
|
|
96
|
+
default: string;
|
|
97
|
+
};
|
|
98
|
+
hintLabel: {
|
|
99
|
+
type: StringConstructor;
|
|
100
|
+
default: string;
|
|
101
|
+
};
|
|
102
|
+
invalid: {
|
|
103
|
+
type: BooleanConstructor;
|
|
104
|
+
default: boolean;
|
|
105
|
+
};
|
|
106
|
+
invalidLabel: {
|
|
107
|
+
type: (ArrayConstructor | StringConstructor)[];
|
|
108
|
+
default: undefined;
|
|
109
|
+
};
|
|
110
|
+
valid: {
|
|
111
|
+
type: BooleanConstructor;
|
|
112
|
+
default: boolean;
|
|
113
|
+
};
|
|
114
|
+
validLabel: {
|
|
115
|
+
type: (ArrayConstructor | StringConstructor)[];
|
|
116
|
+
default: undefined;
|
|
117
|
+
};
|
|
118
|
+
readonly: {
|
|
119
|
+
type: BooleanConstructor;
|
|
120
|
+
default: boolean;
|
|
121
|
+
};
|
|
122
|
+
disabled: {
|
|
123
|
+
type: BooleanConstructor;
|
|
124
|
+
default: boolean;
|
|
125
|
+
};
|
|
126
|
+
tabindex: {
|
|
127
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
128
|
+
default: number;
|
|
129
|
+
};
|
|
130
|
+
autocomplete: {
|
|
131
|
+
type: StringConstructor;
|
|
132
|
+
default: string;
|
|
133
|
+
};
|
|
134
|
+
autofocus: {
|
|
135
|
+
type: BooleanConstructor;
|
|
136
|
+
default: boolean;
|
|
137
|
+
};
|
|
138
|
+
name: {
|
|
139
|
+
type: StringConstructor;
|
|
140
|
+
required: boolean;
|
|
141
|
+
};
|
|
142
|
+
id: (NumberConstructor | StringConstructor)[];
|
|
143
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
144
|
+
modelValue: StringConstructor;
|
|
145
|
+
cols: {
|
|
146
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
147
|
+
default: number;
|
|
148
|
+
};
|
|
149
|
+
rows: {
|
|
150
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
151
|
+
default: number;
|
|
152
|
+
};
|
|
153
|
+
wrap: {
|
|
154
|
+
type: StringConstructor;
|
|
155
|
+
default: string;
|
|
156
|
+
};
|
|
157
|
+
spellcheck: {
|
|
158
|
+
type: (BooleanConstructor | StringConstructor)[];
|
|
159
|
+
default: string;
|
|
160
|
+
};
|
|
161
|
+
iconRemoveSuggestion: {
|
|
162
|
+
type: PropType<string | import("../VvIcon").VvIconProps>;
|
|
163
|
+
default: "trash";
|
|
164
|
+
};
|
|
165
|
+
labelRemoveSuggestion: {
|
|
166
|
+
type: StringConstructor;
|
|
167
|
+
default: string;
|
|
168
|
+
};
|
|
169
|
+
maxSuggestions: {
|
|
170
|
+
type: NumberConstructor;
|
|
171
|
+
default: number;
|
|
172
|
+
};
|
|
173
|
+
selectOnFocus: {
|
|
174
|
+
type: BooleanConstructor;
|
|
175
|
+
default: boolean;
|
|
176
|
+
};
|
|
177
|
+
resizable: BooleanConstructor;
|
|
178
|
+
storageType: {
|
|
179
|
+
type: PropType<`${import("../../constants").StorageType}`>;
|
|
180
|
+
default: import("../../constants").StorageType;
|
|
181
|
+
validator: (value: import("../../constants").StorageType) => boolean;
|
|
182
|
+
};
|
|
183
|
+
storageKey: StringConstructor;
|
|
184
|
+
required: {
|
|
185
|
+
type: BooleanConstructor;
|
|
186
|
+
default: boolean;
|
|
187
|
+
};
|
|
188
|
+
minlength: {
|
|
189
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
190
|
+
default: undefined;
|
|
191
|
+
};
|
|
192
|
+
maxlength: {
|
|
193
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
194
|
+
default: undefined;
|
|
195
|
+
};
|
|
196
|
+
placeholder: {
|
|
197
|
+
type: StringConstructor;
|
|
198
|
+
default: undefined;
|
|
199
|
+
};
|
|
200
|
+
label: {
|
|
201
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
202
|
+
default: undefined;
|
|
203
|
+
};
|
|
204
|
+
floating: {
|
|
205
|
+
type: BooleanConstructor;
|
|
206
|
+
default: boolean;
|
|
207
|
+
};
|
|
208
|
+
icon: {
|
|
209
|
+
type: PropType<string | import("../VvIcon").VvIconProps>;
|
|
210
|
+
default: undefined;
|
|
211
|
+
};
|
|
212
|
+
iconPosition: {
|
|
213
|
+
type: PropType<`${import("../../constants").Position}`>;
|
|
214
|
+
default: import("../../constants").Position;
|
|
215
|
+
validation: (value: import("../../constants").Position) => boolean;
|
|
216
|
+
};
|
|
217
|
+
debounce: {
|
|
218
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
219
|
+
default: undefined;
|
|
220
|
+
};
|
|
221
|
+
count: {
|
|
222
|
+
type: (BooleanConstructor | StringConstructor)[];
|
|
223
|
+
default: boolean;
|
|
224
|
+
validator: (value: string) => boolean;
|
|
225
|
+
};
|
|
226
|
+
modifiers: {
|
|
227
|
+
type: PropType<string | string[]>;
|
|
228
|
+
default: undefined;
|
|
229
|
+
};
|
|
230
|
+
loading: {
|
|
231
|
+
type: BooleanConstructor;
|
|
232
|
+
default: boolean;
|
|
233
|
+
};
|
|
234
|
+
loadingLabel: {
|
|
235
|
+
type: StringConstructor;
|
|
236
|
+
default: string;
|
|
237
|
+
};
|
|
238
|
+
hintLabel: {
|
|
239
|
+
type: StringConstructor;
|
|
240
|
+
default: string;
|
|
241
|
+
};
|
|
242
|
+
invalid: {
|
|
243
|
+
type: BooleanConstructor;
|
|
244
|
+
default: boolean;
|
|
245
|
+
};
|
|
246
|
+
invalidLabel: {
|
|
247
|
+
type: (ArrayConstructor | StringConstructor)[];
|
|
248
|
+
default: undefined;
|
|
249
|
+
};
|
|
250
|
+
valid: {
|
|
251
|
+
type: BooleanConstructor;
|
|
252
|
+
default: boolean;
|
|
253
|
+
};
|
|
254
|
+
validLabel: {
|
|
255
|
+
type: (ArrayConstructor | StringConstructor)[];
|
|
256
|
+
default: undefined;
|
|
257
|
+
};
|
|
258
|
+
readonly: {
|
|
259
|
+
type: BooleanConstructor;
|
|
260
|
+
default: boolean;
|
|
261
|
+
};
|
|
262
|
+
disabled: {
|
|
263
|
+
type: BooleanConstructor;
|
|
264
|
+
default: boolean;
|
|
265
|
+
};
|
|
266
|
+
tabindex: {
|
|
267
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
268
|
+
default: number;
|
|
269
|
+
};
|
|
270
|
+
autocomplete: {
|
|
271
|
+
type: StringConstructor;
|
|
272
|
+
default: string;
|
|
273
|
+
};
|
|
274
|
+
autofocus: {
|
|
275
|
+
type: BooleanConstructor;
|
|
276
|
+
default: boolean;
|
|
277
|
+
};
|
|
278
|
+
name: {
|
|
279
|
+
type: StringConstructor;
|
|
280
|
+
required: boolean;
|
|
281
|
+
};
|
|
282
|
+
id: (NumberConstructor | StringConstructor)[];
|
|
283
|
+
}>> & Readonly<{}>, {
|
|
284
|
+
floating: boolean;
|
|
285
|
+
icon: string | import("../VvIcon").VvIconProps;
|
|
286
|
+
modifiers: string | string[];
|
|
287
|
+
label: string | number;
|
|
288
|
+
disabled: boolean;
|
|
289
|
+
tabindex: string | number;
|
|
290
|
+
invalid: boolean;
|
|
291
|
+
count: string | boolean;
|
|
292
|
+
storageType: "local" | "session";
|
|
293
|
+
iconPosition: "before" | "after";
|
|
294
|
+
required: boolean;
|
|
295
|
+
loading: boolean;
|
|
296
|
+
loadingLabel: string;
|
|
297
|
+
readonly: boolean;
|
|
298
|
+
hintLabel: string;
|
|
299
|
+
invalidLabel: string | unknown[];
|
|
300
|
+
valid: boolean;
|
|
301
|
+
validLabel: string | unknown[];
|
|
302
|
+
placeholder: string;
|
|
303
|
+
autocomplete: string;
|
|
304
|
+
autofocus: boolean;
|
|
305
|
+
spellcheck: string | boolean;
|
|
306
|
+
iconRemoveSuggestion: string | import("../VvIcon").VvIconProps;
|
|
307
|
+
labelRemoveSuggestion: string;
|
|
308
|
+
selectOnFocus: boolean;
|
|
309
|
+
maxSuggestions: number;
|
|
310
|
+
minlength: string | number;
|
|
311
|
+
maxlength: string | number;
|
|
312
|
+
debounce: string | number;
|
|
313
|
+
cols: string | number;
|
|
314
|
+
rows: string | number;
|
|
315
|
+
wrap: string;
|
|
316
|
+
resizable: boolean;
|
|
317
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>, {
|
|
318
|
+
before?: (props: {
|
|
319
|
+
valid: boolean;
|
|
320
|
+
invalid: boolean;
|
|
321
|
+
modelValue: string | undefined;
|
|
322
|
+
hintLabel: string;
|
|
323
|
+
maxlength: string | number | undefined;
|
|
324
|
+
minlength: string | number | undefined;
|
|
325
|
+
clear: () => void;
|
|
326
|
+
}) => any;
|
|
327
|
+
} & {
|
|
328
|
+
after?: (props: {
|
|
329
|
+
valid: boolean;
|
|
330
|
+
invalid: boolean;
|
|
331
|
+
modelValue: string | undefined;
|
|
332
|
+
hintLabel: string;
|
|
333
|
+
maxlength: string | number | undefined;
|
|
334
|
+
minlength: string | number | undefined;
|
|
335
|
+
clear: () => void;
|
|
336
|
+
}) => any;
|
|
337
|
+
} & {
|
|
338
|
+
count?: (props: {
|
|
339
|
+
valid: boolean;
|
|
340
|
+
invalid: boolean;
|
|
341
|
+
modelValue: string | undefined;
|
|
342
|
+
hintLabel: string;
|
|
343
|
+
maxlength: string | number | undefined;
|
|
344
|
+
minlength: string | number | undefined;
|
|
345
|
+
clear: () => void;
|
|
346
|
+
}) => any;
|
|
347
|
+
} & {
|
|
348
|
+
hint?: (props: {
|
|
349
|
+
modelValue: unknown;
|
|
350
|
+
valid: boolean;
|
|
351
|
+
invalid: boolean;
|
|
352
|
+
loading: boolean;
|
|
353
|
+
}) => any;
|
|
354
|
+
} & {
|
|
355
|
+
loading?: (props: {
|
|
356
|
+
modelValue: unknown;
|
|
357
|
+
valid: boolean;
|
|
358
|
+
invalid: boolean;
|
|
359
|
+
loading: boolean;
|
|
360
|
+
}) => any;
|
|
361
|
+
} & {
|
|
362
|
+
valid?: (props: {
|
|
363
|
+
modelValue: unknown;
|
|
364
|
+
valid: boolean;
|
|
365
|
+
invalid: boolean;
|
|
366
|
+
loading: boolean;
|
|
367
|
+
}) => any;
|
|
368
|
+
} & {
|
|
369
|
+
invalid?: (props: {
|
|
370
|
+
modelValue: unknown;
|
|
371
|
+
valid: boolean;
|
|
372
|
+
invalid: boolean;
|
|
373
|
+
loading: boolean;
|
|
374
|
+
}) => any;
|
|
375
|
+
} & {
|
|
376
|
+
suggestion?: (props: {
|
|
377
|
+
value: string;
|
|
378
|
+
}) => any;
|
|
379
|
+
}>;
|
|
380
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
381
|
+
new (): {
|
|
382
|
+
$slots: S;
|
|
383
|
+
};
|
|
384
|
+
};
|