@volverjs/ui-vue 0.0.1-beta.11 → 0.0.1-beta.16
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/bin/icons.cjs +73 -0
- package/bin/icons.js +75 -0
- package/dist/Volver.d.ts +15 -2
- package/dist/components/VvAccordion/VvAccordion.es.js +133 -236
- package/dist/components/VvAccordion/VvAccordion.umd.js +1 -1
- package/dist/components/VvAccordion/VvAccordion.vue.d.ts +32 -97
- package/dist/components/VvAccordion/index.d.ts +46 -0
- package/dist/components/VvAccordionGroup/VvAccordionGroup.es.js +199 -277
- package/dist/components/VvAccordionGroup/VvAccordionGroup.umd.js +1 -1
- package/dist/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +44 -151
- package/dist/components/VvAccordionGroup/{VvAccordionGroup.d.ts → index.d.ts} +9 -13
- package/dist/components/VvBadge/VvBadge.es.js +57 -13
- package/dist/components/VvBadge/VvBadge.umd.js +1 -1
- package/dist/components/VvBadge/VvBadge.vue.d.ts +13 -54
- package/dist/components/VvBadge/{VvBadge.d.ts → index.d.ts} +1 -1
- package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +55 -168
- package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
- package/dist/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +25 -105
- package/dist/components/VvBreadcrumb/{VvBreadcrumb.d.ts → index.d.ts} +2 -2
- package/dist/components/VvButton/VvButton.es.js +304 -333
- package/dist/components/VvButton/VvButton.umd.js +1 -1
- package/dist/components/VvButton/VvButton.vue.d.ts +92 -199
- package/dist/components/VvButton/{VvButton.d.ts → index.d.ts} +44 -38
- package/dist/components/VvButtonGroup/VvButtonGroup.es.js +58 -181
- package/dist/components/VvButtonGroup/VvButtonGroup.umd.js +1 -1
- package/dist/components/VvButtonGroup/VvButtonGroup.vue.d.ts +26 -181
- package/dist/components/VvButtonGroup/{VvButtonGroup.d.ts → index.d.ts} +2 -26
- package/dist/components/VvCard/VvCard.es.js +55 -166
- package/dist/components/VvCard/VvCard.umd.js +1 -1
- package/dist/components/VvCard/VvCard.vue.d.ts +16 -61
- package/dist/components/VvCard/{VvCard.d.ts → index.d.ts} +1 -1
- package/dist/components/VvCheckbox/VvCheckbox.es.js +344 -0
- package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -0
- package/dist/components/VvCheckbox/VvCheckbox.vue.d.ts +87 -0
- package/dist/components/VvCheckbox/index.d.ts +86 -0
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +415 -0
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -0
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +113 -0
- package/dist/components/{VvCheckGroup/VvCheckGroup.d.ts → VvCheckboxGroup/index.d.ts} +10 -10
- package/dist/components/VvDialog/VvDialog.es.js +108 -230
- package/dist/components/VvDialog/VvDialog.umd.js +1 -1
- package/dist/components/VvDialog/VvDialog.vue.d.ts +28 -132
- package/dist/components/VvDialog/{VvDialog.d.ts → index.d.ts} +2 -6
- package/dist/components/VvDropdown/VvDropdown.es.js +167 -186
- package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
- package/dist/components/VvDropdown/VvDropdown.vue.d.ts +35 -137
- package/dist/components/VvDropdown/{VvDropdown.d.ts → index.d.ts} +8 -4
- package/dist/components/VvIcon/VvIcon.es.js +62 -174
- package/dist/components/VvIcon/VvIcon.umd.js +1 -1
- package/dist/components/VvIcon/VvIcon.vue.d.ts +36 -150
- package/dist/components/VvIcon/{VvIcon.d.ts → index.d.ts} +9 -0
- package/dist/components/VvInputText/VvInputClearAction.d.ts +36 -0
- package/dist/components/VvInputText/VvInputPasswordAction.d.ts +56 -0
- package/dist/components/VvInputText/VvInputStepAction.d.ts +37 -0
- package/dist/components/VvInputText/VvInputText.es.js +586 -577
- package/dist/components/VvInputText/VvInputText.umd.js +1 -2
- package/dist/components/VvInputText/VvInputText.vue.d.ts +188 -276
- package/dist/components/VvInputText/VvInputTextActions.d.ts +1 -1
- package/dist/components/VvInputText/index.d.ts +175 -0
- package/dist/components/VvNativeSelect/VvNativeSelect.es.js +299 -347
- package/dist/components/VvNativeSelect/VvNativeSelect.umd.js +1 -2
- package/dist/components/VvNativeSelect/VvNativeSelect.vue.d.ts +78 -190
- package/dist/components/VvNativeSelect/{VvNativeSelect.d.ts → index.d.ts} +35 -8
- package/dist/components/VvProgress/VvProgress.es.js +45 -162
- package/dist/components/VvProgress/VvProgress.umd.js +1 -1
- package/dist/components/VvProgress/VvProgress.vue.d.ts +18 -104
- package/dist/components/VvProgress/{VvProgress.d.ts → index.d.ts} +2 -8
- package/dist/components/VvRadio/VvRadio.es.js +292 -267
- package/dist/components/VvRadio/VvRadio.umd.js +1 -1
- package/dist/components/VvRadio/VvRadio.vue.d.ts +52 -122
- package/dist/components/VvRadio/index.d.ts +64 -0
- package/dist/components/VvRadioGroup/VvRadioGroup.es.js +342 -380
- package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -2
- package/dist/components/VvRadioGroup/VvRadioGroup.vue.d.ts +58 -213
- package/dist/components/VvRadioGroup/{VvRadioGroup.d.ts → index.d.ts} +2 -2
- package/dist/components/VvSelect/VvSelect.es.js +602 -368
- package/dist/components/VvSelect/VvSelect.umd.js +1 -2
- package/dist/components/VvSelect/VvSelect.vue.d.ts +78 -236
- package/dist/components/VvSelect/{VvSelect.d.ts → index.d.ts} +17 -6
- package/dist/components/VvTextarea/VvTextarea.es.js +372 -481
- package/dist/components/VvTextarea/VvTextarea.umd.js +1 -2
- package/dist/components/VvTextarea/VvTextarea.vue.d.ts +104 -300
- package/dist/components/VvTextarea/{VvTextarea.d.ts → index.d.ts} +37 -14
- package/dist/components/common/HintSlot.d.ts +10 -4
- package/dist/components/index.d.ts +13 -6
- package/dist/components/index.es.js +2091 -947
- package/dist/components/index.umd.js +1 -2
- package/dist/composables/debouncedInput/useDebouncedInput.d.ts +2 -2
- package/dist/composables/focus/useComponentFocus.d.ts +3 -3
- package/dist/composables/group/types/IAccordionGroupState.d.ts +1 -3
- package/dist/composables/group/types/IButtonGroupState.d.ts +4 -0
- package/dist/composables/group/types/IGroupState.d.ts +2 -2
- package/dist/composables/group/useInjectedGroupState.d.ts +4 -4
- package/dist/composables/group/useProvideGroupState.d.ts +1 -1
- package/dist/composables/icons/useComponentIcons.d.ts +2 -2
- package/dist/composables/textLimit/useTextLimit.d.ts +0 -3
- package/dist/constants.d.ts +4 -4
- package/dist/icons.d.ts +1881 -0
- package/dist/icons.es.js +4 -6
- package/dist/icons.umd.js +1 -1
- package/dist/index.es.js +2106 -957
- package/dist/index.umd.js +1 -2
- package/dist/props/index.d.ts +11 -4
- package/dist/resolvers/unplugin.d.ts +27 -0
- package/dist/resolvers/unplugin.es.js +40 -0
- package/dist/resolvers/unplugin.umd.js +1 -0
- package/dist/stories/Accordion/Accordion.test.d.ts +4 -0
- package/dist/stories/Badge/Badge.test.d.ts +2 -0
- package/dist/stories/Breadcrumb/Breadcrumb.test.d.ts +2 -0
- package/dist/stories/Button/Button.test.d.ts +3 -8
- package/dist/stories/Card/Card.test.d.ts +3 -0
- package/dist/stories/Dialog/Dialog.test.d.ts +2 -0
- package/dist/stories/Dropdown/Dropdown.test.d.ts +2 -0
- package/dist/stories/Icon/IconList.vue.d.ts +1 -43
- package/dist/stories/InputText/InputText.test.d.ts +6 -0
- package/dist/stories/Radio/Radio.test.d.ts +3 -0
- package/dist/stories/RadioGroup/RadioGroup.test.d.ts +8 -0
- package/dist/stories/Select/Select.test.d.ts +3 -0
- package/dist/stories/Textarea/Textarea.test.d.ts +8 -0
- package/dist/stories/utils.d.ts +1 -3
- package/dist/test/sleep.d.ts +1 -0
- package/dist/utils/ObjectUtilities.d.ts +82 -95
- package/env.d.ts +1 -0
- package/package.json +102 -68
- package/src/Volver.ts +32 -3
- 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 +80 -76
- package/src/components/VvAccordion/index.ts +69 -0
- package/src/components/VvAccordionGroup/VvAccordionGroup.vue +77 -41
- package/src/components/VvAccordionGroup/{VvAccordionGroup.ts → index.ts} +8 -12
- package/src/components/VvBadge/VvBadge.vue +16 -7
- package/src/components/VvBadge/index.ts +6 -0
- package/src/components/VvBreadcrumb/VvBreadcrumb.vue +18 -19
- package/src/components/VvBreadcrumb/{VvBreadcrumb.ts → index.ts} +1 -1
- package/src/components/VvButton/VvButton.vue +125 -124
- package/src/components/VvButton/index.ts +147 -0
- package/src/components/VvButtonGroup/VvButtonGroup.vue +26 -33
- package/src/components/VvButtonGroup/{VvButtonGroup.ts → index.ts} +4 -17
- package/src/components/VvCard/VvCard.vue +20 -22
- package/src/components/VvCard/{VvCard.ts → index.ts} +0 -0
- package/src/components/VvCheckbox/VvCheckbox.vue +124 -0
- package/src/components/VvCheckbox/index.ts +94 -0
- package/src/components/{VvCheckGroup/VvCheckGroup.vue → VvCheckboxGroup/VvCheckboxGroup.vue} +49 -54
- package/src/components/{VvCheckGroup/VvCheckGroup.ts → VvCheckboxGroup/index.ts} +9 -9
- package/src/components/VvDialog/VvDialog.vue +47 -50
- package/src/components/VvDialog/index.ts +10 -0
- package/src/components/VvDropdown/VvDropdown.vue +61 -40
- package/src/components/VvDropdown/{VvDropdown.ts → index.ts} +8 -4
- package/src/components/VvIcon/VvIcon.vue +31 -25
- package/src/components/VvIcon/{VvIcon.ts → index.ts} +9 -0
- package/src/components/VvInputText/VvInputClearAction.ts +53 -0
- package/src/components/VvInputText/VvInputPasswordAction.ts +70 -0
- package/src/components/VvInputText/VvInputStepAction.ts +49 -0
- package/src/components/VvInputText/VvInputText.vue +168 -170
- package/src/components/VvInputText/VvInputTextActions.ts +54 -108
- package/src/components/VvInputText/index.ts +135 -0
- package/src/components/VvNativeSelect/VvNativeSelect.vue +130 -68
- package/src/components/VvNativeSelect/{VvNativeSelect.ts → index.ts} +26 -7
- package/src/components/VvProgress/VvProgress.vue +25 -26
- package/src/components/VvProgress/{VvProgress.ts → index.ts} +4 -7
- package/src/components/VvRadio/VvRadio.vue +81 -108
- package/src/components/VvRadio/index.ts +78 -0
- package/src/components/VvRadioGroup/VvRadioGroup.vue +45 -45
- package/src/components/VvRadioGroup/{VvRadioGroup.ts → index.ts} +1 -1
- package/src/components/VvSelect/VvSelect.vue +91 -64
- package/src/components/VvSelect/{VvSelect.ts → index.ts} +16 -5
- package/src/components/VvTextarea/VvTextarea.vue +121 -128
- package/src/components/VvTextarea/{VvTextarea.ts → index.ts} +31 -11
- package/src/components/common/HintSlot.ts +157 -136
- package/src/components/index.ts +13 -6
- package/src/composables/debouncedInput/useDebouncedInput.ts +21 -15
- package/src/composables/focus/useComponentFocus.ts +6 -8
- package/src/composables/group/types/IAccordionGroupState.ts +1 -3
- package/src/composables/group/types/IButtonGroupState.ts +4 -0
- package/src/composables/group/types/IGroupState.ts +2 -2
- package/src/composables/group/useInjectedGroupState.ts +20 -30
- package/src/composables/group/useProvideGroupState.ts +1 -2
- package/src/composables/icons/useComponentIcons.ts +2 -3
- package/src/composables/options/useOptions.ts +3 -0
- package/src/composables/textLimit/useTextLimit.ts +1 -4
- package/src/composables/useModifiers.ts +13 -15
- package/src/constants.ts +5 -7
- package/src/directives/{.README → .gitkeep} +0 -0
- package/src/icons.ts +7 -0
- package/src/index.ts +0 -1
- package/src/props/index.ts +10 -2
- package/src/resolvers/unplugin.ts +103 -0
- package/src/shims.d.ts +11 -0
- package/src/stories/Accordion/Accordion.stories.mdx +10 -9
- package/src/stories/Accordion/Accordion.test.ts +37 -0
- package/src/stories/Accordion/AccordionSlots.stories.mdx +40 -25
- package/src/stories/AccordionGroup/AccordionGroup.stories.mdx +10 -16
- package/src/stories/AccordionGroup/{accordionGroupTest.js → AccordionGroup.test.js} +15 -17
- package/src/stories/AccordionGroup/AccordionGroupCollapse.stories.mdx +38 -0
- package/src/stories/AccordionGroup/{AccordionItems.stories.mdx → AccordionGroupItems.stories.mdx} +7 -13
- package/src/stories/Badge/Badge.stories.mdx +8 -8
- package/src/stories/Badge/Badge.test.ts +16 -0
- package/src/stories/Badge/BadgeColor.stories.mdx +10 -11
- package/src/stories/Badge/BadgeDot.stories.mdx +4 -3
- package/src/stories/Badge/BadgeModifiers.stories.mdx +66 -0
- package/src/stories/Breadcrumb/Breadcrumb.stories.mdx +15 -7
- package/src/stories/Breadcrumb/Breadcrumb.test.ts +49 -0
- package/src/stories/Breadcrumb/BreadcrumbMultiline.stories.mdx +15 -7
- package/src/stories/Button/Button.stories.mdx +16 -17
- package/src/stories/Button/Button.test.ts +8 -12
- package/src/stories/Button/ButtonActive.stories.mdx +28 -0
- package/src/stories/Button/ButtonBadge.stories.mdx +2 -2
- package/src/stories/Button/ButtonDisabled.stories.mdx +28 -0
- package/src/stories/Button/ButtonIcon.stories.mdx +6 -3
- package/src/stories/Button/ButtonIconPosition.stories.mdx +1 -2
- package/src/stories/Button/ButtonLink.stories.mdx +1 -19
- package/src/stories/Button/ButtonLoading.stories.mdx +4 -4
- package/src/stories/Button/ButtonModifiers.stories.mdx +104 -47
- package/src/stories/Button/ButtonPressed.stories.mdx +31 -0
- package/src/stories/Button/ButtonSlots.stories.mdx +1 -1
- package/src/stories/ButtonGroup/ButtonGroup.stories.mdx +5 -6
- package/src/stories/ButtonGroup/{ButtonGroupTest.js → ButtonGroup.test.js} +6 -28
- package/src/stories/ButtonGroup/ButtonGroupAction.stories.mdx +6 -7
- package/src/stories/ButtonGroup/ButtonGroupActionQuiet.stories.mdx +5 -6
- package/src/stories/ButtonGroup/ButtonGroupBlock.stories.mdx +4 -5
- package/src/stories/ButtonGroup/ButtonGroupCompact.stories.mdx +3 -4
- package/src/stories/ButtonGroup/ButtonGroupRounded.stories.mdx +4 -5
- package/src/stories/ButtonGroup/ButtonGroupToggle.stories.mdx +11 -12
- package/src/stories/ButtonGroup/ButtonGroupVertical.stories.mdx +3 -4
- package/src/stories/Card/Card.stories.mdx +7 -5
- package/src/stories/Card/Card.test.ts +26 -0
- package/src/stories/Card/CardSlots.stories.mdx +5 -5
- package/src/stories/Card/CardVariant.stories.mdx +5 -4
- package/src/stories/Checkbox/Checkbox.stories.mdx +51 -0
- package/src/stories/Checkbox/Checkbox.test.js +115 -0
- package/src/stories/Checkbox/CheckboxBinary.stories.mdx +76 -0
- package/src/stories/{Check/CheckDisabled.stories.mdx → Checkbox/CheckboxDisabled.stories.mdx} +7 -7
- package/src/stories/Checkbox/CheckboxError.stories.mdx +43 -0
- package/src/stories/Checkbox/CheckboxHintLabel.stories.mdx +35 -0
- package/src/stories/{Check/CheckReadonly.stories.mdx → Checkbox/CheckboxReadonly.stories.mdx} +6 -8
- package/src/stories/Checkbox/CheckboxSlots.stories.mdx +69 -0
- package/src/stories/{Check/CheckSwitch.stories.mdx → Checkbox/CheckboxSwitch.stories.mdx} +8 -8
- package/src/stories/CheckboxGroup/CheckboxGroup.stories.mdx +69 -0
- package/src/stories/CheckboxGroup/CheckboxGroupDisabled.stories.mdx +26 -0
- package/src/stories/CheckboxGroup/CheckboxGroupError.stories.mdx +28 -0
- package/src/stories/CheckboxGroup/CheckboxGroupHintLabel.stories.mdx +27 -0
- package/src/stories/CheckboxGroup/CheckboxGroupLabel.stories.mdx +26 -0
- package/src/stories/{CheckGroup/CheckGroupOptionLabel.stories.mdx → CheckboxGroup/CheckboxGroupOptionLabel.stories.mdx} +14 -11
- package/src/stories/{CheckGroup/CheckGroupOptionValue.stories.mdx → CheckboxGroup/CheckboxGroupOptionValue.stories.mdx} +13 -10
- package/src/stories/{CheckGroup/CheckGroupOptions.stories.mdx → CheckboxGroup/CheckboxGroupOptions.stories.mdx} +8 -8
- package/src/stories/CheckboxGroup/CheckboxGroupReadonly.stories.mdx +26 -0
- package/src/stories/CheckboxGroup/CheckboxGroupSlots.stories.mdx +152 -0
- package/src/stories/CheckboxGroup/CheckboxGroupValid.stories.mdx +28 -0
- package/src/stories/CheckboxGroup/CheckboxGroupVertical.stories.mdx +26 -0
- package/src/stories/Dialog/Dialog.stories.mdx +5 -5
- package/src/stories/Dialog/Dialog.test.ts +26 -0
- package/src/stories/Dialog/DialogAutoClose.stories.mdx +1 -1
- package/src/stories/Dialog/DialogSize.stories.mdx +1 -1
- package/src/stories/Dropdown/Dropdown.stories.mdx +11 -7
- package/src/stories/Dropdown/Dropdown.test.ts +80 -0
- package/src/stories/Dropdown/DropdownDisabled.stories.mdx +9 -2
- package/src/stories/Dropdown/DropdownLabelNoResults.stories.mdx +2 -2
- package/src/stories/Dropdown/DropdownMaxValues.stories.mdx +4 -2
- package/src/stories/Dropdown/DropdownMultiple.stories.mdx +4 -2
- package/src/stories/Dropdown/DropdownOptions.stories.mdx +4 -4
- package/src/stories/Dropdown/DropdownUseObject.stories.mdx +4 -2
- package/src/stories/Icon/Icon.stories.mdx +8 -8
- package/src/stories/Icon/{IconTest.js → Icon.test.js} +2 -5
- package/src/stories/Icon/IconList.vue +5 -6
- package/src/stories/Icon/IconPrefix.stories.mdx +2 -2
- package/src/stories/Icon/IconRemote.stories.mdx +2 -2
- package/src/stories/Icon/IconsList.stories.mdx +2 -18
- package/src/stories/InputText/InputText.stories.mdx +25 -19
- package/src/stories/InputText/InputText.test.ts +156 -0
- package/src/stories/InputText/InputTextAutocomplete.stories.mdx +9 -2
- package/src/stories/InputText/InputTextAutofocus.stories.mdx +6 -3
- package/src/stories/InputText/InputTextDisabled.stories.mdx +10 -2
- package/src/stories/InputText/InputTextError.stories.mdx +10 -2
- package/src/stories/InputText/InputTextFloating.stories.mdx +10 -3
- package/src/stories/InputText/InputTextHintLabel.stories.mdx +10 -2
- package/src/stories/InputText/InputTextIcon.stories.mdx +6 -2
- package/src/stories/InputText/InputTextIconPosition.stories.mdx +10 -3
- package/src/stories/InputText/InputTextLabel.stories.mdx +8 -2
- package/src/stories/InputText/InputTextLoading.stories.mdx +10 -2
- package/src/stories/InputText/InputTextMax.stories.mdx +10 -3
- package/src/stories/InputText/InputTextMaxLength.stories.mdx +22 -5
- package/src/stories/InputText/InputTextMin.stories.mdx +10 -3
- package/src/stories/InputText/InputTextMinLength.stories.mdx +9 -2
- package/src/stories/InputText/InputTextPlaceholder.stories.mdx +8 -2
- package/src/stories/InputText/InputTextReadonly.stories.mdx +6 -2
- package/src/stories/InputText/InputTextSlots.stories.mdx +4 -5
- package/src/stories/InputText/InputTextStep.stories.mdx +9 -3
- package/src/stories/InputText/InputTextType.stories.mdx +110 -13
- package/src/stories/InputText/InputTextValid.stories.mdx +10 -2
- package/src/stories/NativeSelect/NativeSelect.stories.mdx +15 -11
- package/src/stories/NativeSelect/NativeSelect.test.js +151 -0
- package/src/stories/NativeSelect/NativeSelectDisabled.stories.mdx +6 -7
- package/src/stories/NativeSelect/NativeSelectError.stories.mdx +7 -3
- package/src/stories/NativeSelect/NativeSelectHintLabel.stories.mdx +7 -3
- package/src/stories/NativeSelect/NativeSelectIconLeftRight.stories.mdx +14 -12
- package/src/stories/NativeSelect/NativeSelectLoading.stories.mdx +7 -3
- package/src/stories/NativeSelect/NativeSelectOptions.stories.mdx +44 -38
- package/src/stories/NativeSelect/NativeSelectReadonly.stories.mdx +19 -11
- package/src/stories/NativeSelect/NativeSelectUseObject.stories.mdx +26 -30
- package/src/stories/NativeSelect/NativeSelectValid.stories.mdx +7 -3
- package/src/stories/NativeSelect/NativeSelectValueKey.stories.mdx +30 -30
- package/src/stories/Progress/Progress.stories.mdx +8 -11
- package/src/stories/Progress/{ProgressTest.js → Progress.test.js} +4 -10
- package/src/stories/Progress/ProgressDeterminate.stories.mdx +3 -6
- package/src/stories/Radio/Radio.stories.mdx +11 -17
- package/src/stories/Radio/Radio.test.ts +52 -0
- package/src/stories/Radio/RadioDisabled.stories.mdx +4 -7
- package/src/stories/Radio/RadioError.stories.mdx +8 -28
- package/src/stories/Radio/RadioHintLabel.stories.mdx +6 -7
- package/src/stories/Radio/RadioSlots.stories.mdx +21 -7
- package/src/stories/RadioGroup/RadioGroup.stories.mdx +20 -27
- package/src/stories/RadioGroup/RadioGroup.test.ts +139 -0
- package/src/stories/RadioGroup/RadioGroupDisabled.stories.mdx +6 -8
- package/src/stories/RadioGroup/RadioGroupError.stories.mdx +9 -11
- package/src/stories/RadioGroup/RadioGroupHintLabel.stories.mdx +13 -15
- package/src/stories/RadioGroup/RadioGroupLabel.stories.mdx +12 -9
- package/src/stories/RadioGroup/RadioGroupOptionLabel.stories.mdx +16 -30
- package/src/stories/RadioGroup/RadioGroupOptionValue.stories.mdx +15 -29
- package/src/stories/RadioGroup/RadioGroupOptions.stories.mdx +9 -25
- package/src/stories/RadioGroup/RadioGroupReadonly.stories.mdx +6 -8
- package/src/stories/RadioGroup/RadioGroupSlots.stories.mdx +48 -70
- package/src/stories/RadioGroup/RadioGroupValid.stories.mdx +9 -11
- package/src/stories/RadioGroup/RadioGroupVertical.stories.mdx +6 -8
- package/src/stories/Select/Select.stories.mdx +32 -29
- package/src/stories/Select/Select.test.ts +104 -0
- package/src/stories/Select/SelectDisabled.stories.mdx +3 -3
- package/src/stories/Select/SelectMaxValues.stories.mdx +3 -3
- package/src/stories/Select/SelectMultiple.stories.mdx +5 -6
- package/src/stories/Select/SelectNative.stories.mdx +43 -0
- package/src/stories/Select/SelectOptions.stories.mdx +4 -4
- package/src/stories/Select/SelectSearchable.stories.mdx +13 -12
- package/src/stories/Select/SelectSeparator.stories.mdx +3 -3
- package/src/stories/Select/SelectUseObject.stories.mdx +3 -3
- package/src/stories/Textarea/Textarea.stories.mdx +6 -10
- package/src/stories/Textarea/Textarea.test.ts +204 -0
- package/src/stories/Textarea/TextareaAutoclear.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaAutocomplete.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaAutofocus.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaDebounce.stories.mdx +7 -6
- package/src/stories/Textarea/TextareaDisabled.stories.mdx +9 -3
- package/src/stories/Textarea/TextareaError.stories.mdx +7 -2
- package/src/stories/Textarea/TextareaErrorLabel.stories.mdx +12 -2
- package/src/stories/Textarea/TextareaFloating.stories.mdx +7 -2
- package/src/stories/Textarea/TextareaHintLabel.stories.mdx +7 -2
- package/src/stories/Textarea/TextareaIcon.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaIconPosition.stories.mdx +4 -2
- package/src/stories/Textarea/TextareaId.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaLabel.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaLimit.stories.mdx +5 -2
- package/src/stories/Textarea/TextareaLoading.stories.mdx +7 -2
- package/src/stories/Textarea/TextareaLoadingLabel.stories.mdx +9 -3
- package/src/stories/Textarea/TextareaMaxLength.stories.mdx +5 -4
- package/src/stories/Textarea/TextareaMinLength.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaModifiers.stories.mdx +10 -2
- package/src/stories/Textarea/TextareaName.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaPlaceholder.stories.mdx +4 -3
- package/src/stories/Textarea/TextareaReadonly.stories.mdx +8 -3
- package/src/stories/Textarea/TextareaRequired.stories.mdx +3 -2
- package/src/stories/Textarea/TextareaResizable.stories.mdx +7 -2
- package/src/stories/Textarea/TextareaRowsCols.stories.mdx +4 -2
- package/src/stories/Textarea/TextareaSlots.stories.mdx +7 -8
- package/src/stories/Textarea/TextareaValid.stories.mdx +7 -1
- package/src/stories/Textarea/TextareaValidLabel.stories.mdx +14 -4
- package/src/stories/utils.ts +1 -1
- package/src/stories/volver-ui-vue.stories.mdx +1 -1
- package/src/test/expect.ts +3 -1
- package/src/test/sleep.ts +2 -0
- package/src/test/types.d.ts +14 -1
- package/src/types/{.README → .gitkeep} +0 -0
- package/src/utils/ObjectUtilities.ts +247 -241
- package/dist/components/VvAccordion/VvAccordion.d.ts +0 -32
- package/dist/components/VvAccordion/useAccordionProps.d.ts +0 -16
- package/dist/components/VvButton/useButtonGroupProps.d.ts +0 -23
- package/dist/components/VvCheck/VvCheck.d.ts +0 -47
- package/dist/components/VvCheck/VvCheck.es.js +0 -318
- package/dist/components/VvCheck/VvCheck.umd.js +0 -1
- package/dist/components/VvCheck/VvCheck.vue.d.ts +0 -165
- package/dist/components/VvCheck/useCheckProps.d.ts +0 -16
- package/dist/components/VvCheckGroup/VvCheckGroup.es.js +0 -451
- package/dist/components/VvCheckGroup/VvCheckGroup.umd.js +0 -2
- package/dist/components/VvCheckGroup/VvCheckGroup.vue.d.ts +0 -272
- package/dist/components/VvDialog/constants.d.ts +0 -5
- package/dist/components/VvInputText/VvInputText.d.ts +0 -73
- package/dist/components/VvInputText/constants.d.ts +0 -55
- package/dist/components/VvRadio/VvRadio.d.ts +0 -22
- package/dist/components/VvRadio/useRadioProps.d.ts +0 -15
- package/dist/components/VvTextarea/constants.d.ts +0 -19
- package/dist/stories/RadioGroup/RadioProperty.test.d.ts +0 -12
- package/src/assets/icons/index.js +0 -7
- package/src/components/VvAccordion/VvAccordion.ts +0 -34
- package/src/components/VvAccordion/useAccordionProps.ts +0 -45
- package/src/components/VvBadge/VvBadge.ts +0 -4
- package/src/components/VvButton/VvButton.ts +0 -117
- package/src/components/VvButton/useButtonGroupProps.ts +0 -51
- package/src/components/VvCheck/VvCheck.ts +0 -48
- package/src/components/VvCheck/VvCheck.vue +0 -147
- package/src/components/VvCheck/useCheckProps.ts +0 -41
- package/src/components/VvDialog/VvDialog.ts +0 -17
- package/src/components/VvDialog/constants.ts +0 -5
- package/src/components/VvInputText/VvInputText.ts +0 -66
- package/src/components/VvInputText/constants.ts +0 -34
- package/src/components/VvRadio/VvRadio.ts +0 -25
- package/src/components/VvRadio/useRadioProps.ts +0 -40
- package/src/components/VvTextarea/constants.ts +0 -14
- package/src/stories/Accordion/AccordionBordered.stories.mdx +0 -26
- package/src/stories/Accordion/AccordionIconRight.stories.mdx +0 -32
- package/src/stories/Accordion/accordionTest.js +0 -36
- package/src/stories/AccordionGroup/Accordion.stories.mdx +0 -42
- package/src/stories/Badge/BadgeTest.js +0 -21
- package/src/stories/Button/ButtonVariant.stories.mdx +0 -205
- package/src/stories/Button/test.js +0 -41
- package/src/stories/Check/Check.stories.mdx +0 -62
- package/src/stories/Check/CheckBinary.stories.mdx +0 -75
- package/src/stories/Check/CheckError.stories.mdx +0 -64
- package/src/stories/Check/CheckErrorTests.js +0 -74
- package/src/stories/Check/CheckHintLabel.stories.mdx +0 -30
- package/src/stories/Check/CheckPropertyTest.js +0 -102
- package/src/stories/Check/CheckSlots.stories.mdx +0 -51
- package/src/stories/CheckGroup/CheckGroup.stories.mdx +0 -69
- package/src/stories/CheckGroup/CheckGroupDisabled.stories.mdx +0 -26
- package/src/stories/CheckGroup/CheckGroupError.stories.mdx +0 -28
- package/src/stories/CheckGroup/CheckGroupHintLabel.stories.mdx +0 -27
- package/src/stories/CheckGroup/CheckGroupLabel.stories.mdx +0 -26
- package/src/stories/CheckGroup/CheckGroupReadonly.stories.mdx +0 -26
- package/src/stories/CheckGroup/CheckGroupSlots.stories.mdx +0 -152
- package/src/stories/CheckGroup/CheckGroupValid.stories.mdx +0 -28
- package/src/stories/CheckGroup/CheckGroupVertical.stories.mdx +0 -26
- package/src/stories/Radio/RadioTest.js +0 -90
- package/src/stories/RadioGroup/RadioOptionsTest.js +0 -78
- package/src/stories/RadioGroup/RadioProperty.test.ts +0 -87
- package/src/stories/RadioGroup/RadioPropertyTest.js +0 -131
- package/src/stories/RadioGroup/RadioSlotsTest.js +0 -20
- package/src/stories/stories.scss +0 -35
|
@@ -1,2 +1 @@
|
|
|
1
|
-
(function(t,k){typeof exports=="object"&&typeof module<"u"?module.exports=k(require("vue"),require("@vueuse/core"),require("uuid")):typeof define=="function"&&define.amd?define(["vue","@vueuse/core","uuid"],k):(t=typeof globalThis<"u"?globalThis:t||self,t.VvSelect=k(t.vue,t.core,t.uuid))})(this,function(t,k,N){"use strict";const g={equals(r,n,e){return e?this.resolveFieldData(r,e)===this.resolveFieldData(n,e):this.deepEquals(r,n)},deepEquals(r,n){if(r===n)return!0;if(r&&n&&typeof r=="object"&&typeof n=="object"){const e=Array.isArray(r),u=Array.isArray(n);let l,s,c;if(e&&u){if(s=r.length,s!=n.length)return!1;for(l=s;l--!==0;)if(!this.deepEquals(r[l],n[l]))return!1;return!0}if(e!=u)return!1;const m=r instanceof Date,a=n instanceof Date;if(m!=a)return!1;if(m&&a)return r.getTime()==n.getTime();const h=r instanceof RegExp,b=n instanceof RegExp;if(h!=b)return!1;if(h&&b)return r.toString()==n.toString();const o=Object.keys(r);if(s=o.length,s!==Object.keys(n).length)return!1;for(l=s;l--!==0;)if(!Object.prototype.hasOwnProperty.call(n,o[l]))return!1;for(l=s;l--!==0;)if(c=o[l],!this.deepEquals(r[c],n[c]))return!1;return!0}return r!==r&&n!==n},resolveFieldData(r,n){if(r&&Object.keys(r).length&&n){if(n.indexOf(".")===-1)return r[n];{const e=n.split(".");let u=r;for(let l=0,s=e.length;l<s;++l){if(r==null)return null;u=u[e[l]]}return u}}else return null},isFunction(r){return!!(r&&r.constructor&&r.call&&r.apply)},findIndexInList(r,n){let e=-1;if(n){for(let u=0;u<n.length;u++)if(this.equals(n[u],r)){e=u;break}}return e},contains(r,n){if(r!=null&&n&&n.length){for(const e of n)if(this.equals(r,e))return!0}return!1},isEmpty(r){return r==null||r===""||Array.isArray(r)&&r.length===0||!(r instanceof Date)&&typeof r=="object"&&Object.keys(r).length===0},isNotEmpty(r){return!this.isEmpty(r)},pickBy(r,n){return Object.fromEntries(Object.entries(r).filter(([e])=>n(e)))},removeFromList(r,n){const e=this.findIndexInList(r,n);return e>-1?n.filter((u,l)=>l!==e):n},isString(r){return typeof r=="string"||r instanceof String},propsToObject(r){return Object.keys(r).reduce((n,e)=>{var u,l,s,c,m;return this.isFunction(r[e])?n[e]=r[e]():Array.isArray(r[e])?n[e]=r[e][0]():(u=r[e])!=null&&u.type&&(Array.isArray(r[e].type)?n[e]=((l=r[e])==null?void 0:l.default)||((s=r[e])==null?void 0:s.type[0]()):n[e]=((c=r[e])==null?void 0:c.default)||((m=r[e])==null?void 0:m.type())),n},{})},filterArray(r,n,e){return r.filter(u=>n.some(l=>typeof l=="string"?u[e]==l:this.equals(u[e],l[e])))},kebabCase(r){var n,e;if(r)return(e=(n=r.match(/[A-Z]{2,}(?=[A-Z][a-z]+[0-9]*|\b)|[A-Z]?[a-z]+[0-9]*|[A-Z]|[0-9]+/g))==null?void 0:n.join("-"))==null?void 0:e.toLowerCase()}},K={valid:Boolean,validLabel:[String,Array]},q={error:Boolean,errorLabel:[String,Array]},P={loading:Boolean,loadingLabel:String},w={disabled:Boolean},$={readonly:Boolean},D={modifiers:[String,Array]},x={...K,...q,...{hintLabel:{type:String,default:""}},...P,...w,...$,...D,modelValue:[String,Array,Object],label:String,labelNoResult:{type:String,default:"No results"},placeholder:String,searchable:Boolean,searchPlaceholder:String,debounceSearch:{type:[Number,String],default:0},options:{type:Array,required:!0},useObject:Boolean,multiple:Boolean,maxValues:[Number,String],separator:{type:String,default:", "},labelKey:{type:String,default:"label"},valueKey:{type:String,default:"value"},iconLeft:String,iconRight:String};function E(r){return Array.isArray(r)?r.filter(n=>g.isString(n)).reduce((n,e)=>n.length>0?n+`
|
|
2
|
-
`+e:e,""):r}function F(r,n){return{name:"HintSlot",props:{params:{type:Object,default:()=>({})}},setup(e){const u=t.toRefs(r),{error:l,valid:s,hint:c,loading:m}=n,{hintLabel:a,modelValue:h,valid:b,validLabel:o,error:V,errorLabel:i}=u,f=g.resolveFieldData(u,"loading"),y=g.resolveFieldData(u,"loadingLabel"),S=t.computed(()=>V.value?!!(V.value&&l||(i==null?void 0:i.value)&&Array.isArray(i.value)&&i.value.length>0||(i==null?void 0:i.value)&&g.isNotEmpty(i.value)):!1),C=t.computed(()=>!!(a&&a.value||c||s||o&&o.value||S.value||(f==null?void 0:f.value)&&m||(f==null?void 0:f.value)&&(y==null?void 0:y.value))),O=t.computed(()=>{const B=k.toReactive({hintLabel:a,modelValue:h,valid:b,validLabel:o,error:V,errorLabel:i,loading:f,loadingLabel:y,...e.params});return V!=null&&V.value?(l==null?void 0:l(B))||E(i==null?void 0:i.value)||(a==null?void 0:a.value):b!=null&&b.value?(s==null?void 0:s(B))||E(o==null?void 0:o.value)||(a==null?void 0:a.value):f!=null&&f.value?(m==null?void 0:m(B))||E(y==null?void 0:y.value)||(a==null?void 0:a.value):(c==null?void 0:c(B))||E(a==null?void 0:a.value)||(a==null?void 0:a.value)});return{hasHint:C,hintContent:O}},render(){if(this.hasHint)return t.h("pre",{style:{"white-space":"pre"}},this.hintContent)}}}function _(r,n){const e={[`${r}`]:!0};return{bemCssClasses:t.computed(()=>Object.keys(n).reduce((l,s)=>{const c=t.unref(n[s])||!1;if(!c)return l;if(s==="modifiers"){const m=Array.isArray(c)?c:[c];return{...l,...m.reduce((a,h)=>({...a,[`${r}--${g.kebabCase(h)}`]:!0}),{})}}else return{...l,[`${r}--${g.kebabCase(s)}`]:c}},e)||{})}}const R={...w,...D,modelValue:[String,Array,Object],labelNoResult:{type:String,default:"No results"},options:{type:Array,required:!0},useObject:Boolean,multiple:Boolean,maxValues:[Number,String],labelKey:{type:String,default:"label"},valueKey:{type:String,default:"value"}},T={key:0},H=["for"],I=["id","type","value","checked","disabled"],z=t.defineComponent({__name:"VvDropdown",props:R,emits:["update:modelValue"],setup(r,{emit:n}){const e=r,u=N.v4(),{modifiers:l,disabled:s}=t.toRefs(e),{bemCssClasses:c}=_("vv-dropdown",{modifiers:l,disabled:s});function m(o){return Array.isArray(e.modelValue)?g.contains(o,e.modelValue)||g.contains(a(o),e.modelValue):g.equals(o,e.modelValue)||g.equals(a(o),e.modelValue)}function a(o){return typeof o=="string"?o:String(o[e.valueKey])}function h(o){return typeof o=="string"?o:o[e.labelKey]}function b(o){var y,S;const V=o.target;let i=V.value;if(i=(e.useObject?(y=e.options)==null?void 0:y.find(C=>C[e.valueKey]==i):null)||i,e.multiple){if(typeof e.maxValues<"u"&&e.maxValues>=0&&((S=e.modelValue)==null?void 0:S.length)>=e.maxValues&&(Array.isArray(e.modelValue)&&!g.contains(i,e.modelValue)||e.maxValues==0)){V.checked=!1;return}Array.isArray(e.modelValue)?i=g.contains(i,e.modelValue)?g.removeFromList(i,e.modelValue):[...e.modelValue,i]:i=[i]}n("update:modelValue",i)}return(o,V)=>{var i;return t.openBlock(),t.createElementBlock("ul",{class:t.normalizeClass(t.unref(c)),role:"listbox"},[(i=o.options)!=null&&i.length?t.createCommentVNode("",!0):(t.openBlock(),t.createElementBlock("li",T,[t.createElementVNode("label",null,t.toDisplayString(o.labelNoResult),1)])),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.options,(f,y)=>{var S;return t.openBlock(),t.createElementBlock("li",{key:y},[t.createElementVNode("label",{for:`dropdown-${y}-${t.unref(u)}`},[t.createElementVNode("input",{id:`dropdown-${y}-${t.unref(u)}`,type:o.multiple?"checkbox":"radio",value:a(f),checked:m(f),disabled:typeof f=="object"&&(S=f.disabled)!=null?S:t.unref(s),onInput:b},null,40,I),t.createTextVNode(" "+t.toDisplayString(h(f)),1)],8,H)])}),128))],2)}}}),M=["id"],Z={key:0,for:"select"},U=["placeholder"];return t.defineComponent({__name:"VvSelect",props:x,emits:["update:modelValue","change:search"],setup(r,{emit:n}){const e=r,u=t.useSlots(),l=F(e,u),s=t.ref(),c=t.ref();k.useFocus(c,{initialValue:!0});const m=N.v4(),a=t.ref(""),h=k.refDebounced(a,Number(e.debounceSearch)),b=t.ref(!1),{modifiers:o,disabled:V,readonly:i,loading:f,iconLeft:y,iconRight:S,valid:C,error:O}=t.toRefs(e);t.watch(h,()=>n("change:search",h.value));const{bemCssClasses:B}=_("vv-select",{modifiers:o,disabled:V,loading:f,readonly:i,iconLeft:y,iconRight:S,valid:C,invalid:O,dirty:t.computed(()=>g.isNotEmpty(e.modelValue))}),L=t.computed(()=>{var d;return(d=e.options)==null?void 0:d.every(p=>typeof p=="object")}),G=t.computed(()=>e.searchable?J.value:e.options),J=t.computed(()=>{var d;return(d=e.options)==null?void 0:d.filter(p=>typeof p=="string"?p.toLowerCase().includes(h.value.toLowerCase().trim()):p[e.labelKey].toLowerCase().includes(h.value.toLowerCase().trim()))}),Q=t.computed(()=>{var p,A;if(e.multiple&&((p=e.modelValue)==null?void 0:p.length)&&Array.isArray(e.modelValue))return L.value?g.filterArray(e.options,e.modelValue,e.valueKey).map(j=>j[e.labelKey]).join(e.separator):e.modelValue.join(e.separator);const d=e.useObject?e.modelValue:(A=e.options)==null?void 0:A.find(j=>typeof j=="object"?j[e.valueKey]==e.modelValue:j==e.modelValue);return typeof d=="object"?d==null?void 0:d[e.labelKey]:d});k.onClickOutside(s,()=>{s.value.open=!1});function W(d){const p=d.target;b.value=p.open}function X(d){s.value&&!e.multiple&&(s.value.open=!1),n("update:modelValue",d)}return(d,p)=>(t.openBlock(),t.createElementBlock("div",{id:t.unref(m),class:t.normalizeClass(t.unref(B))},[d.label?(t.openBlock(),t.createElementBlock("label",Z,t.toDisplayString(d.label),1)):t.createCommentVNode("",!0),t.createElementVNode("details",{ref_key:"dropdown",ref:s,role:"list",class:"vv-select__wrapper",onClick:p[2]||(p[2]=A=>t.unref(V)||t.unref(i)?A.preventDefault():null),onKeyup:p[3]||(p[3]=t.withKeys(A=>s.value.open=!1,["esc"])),onToggle:W},[t.createElementVNode("summary",{class:"vv-select__input","aria-haspopup":"listbox",onKeyup:p[1]||(p[1]=t.withKeys(A=>d.searchable?A.preventDefault():null,["space"]))},[d.searchable&&b.value?t.withDirectives((t.openBlock(),t.createElementBlock("input",{key:0,ref_key:"inputSearch",ref:c,"onUpdate:modelValue":p[0]||(p[0]=A=>a.value=A),placeholder:d.searchPlaceholder},null,8,U)),[[t.vModelText,a.value]]):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createTextVNode(t.toDisplayString(t.unref(Q)||d.placeholder),1)],64))],32),t.createVNode(z,t.mergeProps({...e,options:t.unref(G)},{"onUpdate:modelValue":X}),null,16)],544),t.createVNode(t.unref(l),{class:"vv-select__hint"})],10,M))}})});
|
|
1
|
+
(function(e,C){typeof exports=="object"&&typeof module<"u"?module.exports=C(require("vue"),require("nanoid"),require("@vueuse/core"),require("@iconify/vue")):typeof define=="function"&&define.amd?define(["vue","nanoid","@vueuse/core","@iconify/vue"],C):(e=typeof globalThis<"u"?globalThis:e||self,e.VvSelect=C(e.vue,e.nanoid,e.core,e.vue$1))})(this,function(e,C,P,N){"use strict";function $(n,r,t){return t?x(n,t)===x(r,t):T(n,r)}function T(n,r){if(n===r)return!0;if(n&&r&&typeof n=="object"&&typeof r=="object"){const t=Array.isArray(n),u=Array.isArray(r);let o,c,l;if(t&&u){if(c=n.length,c!=r.length)return!1;for(o=c;o--!==0;)if(!T(n[o],r[o]))return!1;return!0}if(t!=u)return!1;const b=n instanceof Date,h=r instanceof Date;if(b!=h)return!1;if(b&&h)return n.getTime()==r.getTime();const g=n instanceof RegExp,i=r instanceof RegExp;if(g!=i)return!1;if(g&&i)return n.toString()==r.toString();const s=Object.keys(n);if(c=s.length,c!==Object.keys(r).length)return!1;for(o=c;o--!==0;)if(!Object.prototype.hasOwnProperty.call(r,s[o]))return!1;for(o=c;o--!==0;)if(l=s[o],!T(n[l],r[l]))return!1;return!0}return n!==n&&r!==r}function x(n,r){if(n&&Object.keys(n).length&&r){if(r.indexOf(".")===-1)return n[r];{const t=r.split(".");let u=n;for(let o=0,c=t.length;o<c;++o){if(n==null)return null;u=u[t[o]]}return u}}else return null}function Y(n,r){let t=-1;if(r){for(let u=0;u<r.length;u++)if($(r[u],n)){t=u;break}}return t}function K(n,r){if(n!=null&&r&&r.length){for(const t of r)if($(n,t))return!0}return!1}function F(n){return(r=>r==null||r===""||Array.isArray(r)&&r.length===0||!(r instanceof Date)&&typeof r=="object"&&Object.keys(r).length===0)(e.unref(n))}function ee(n,r){const t=Y(n,r);return t>-1?r.filter((u,o)=>o!==t):r}function te(n){return typeof n=="string"||n instanceof String}function re(n,r,t){return n.filter(u=>r.some(o=>typeof o=="string"?u[t]==o:$(u[t],o[t])))}function z(n){var r,t;if(n)return(t=(r=n.match(/[A-Z]{2,}(?=[A-Z][a-z]+[0-9]*|\b)|[A-Z]?[a-z]+[0-9]*|[A-Z]|[0-9]+/g))==null?void 0:r.join("-"))==null?void 0:t.toLowerCase()}function R(n,r){const t={[`${n}`]:!0};return{bemCssClasses:e.computed(()=>Object.keys(r).reduce((o,c)=>{const l=e.unref(r[c])||!1;if(!l)return o;if(c==="modifiers"){const b=Array.isArray(l)?l:l.split(" ");return{...o,...b.reduce((h,g)=>({...h,[`${n}--${z(g)}`]:!0}),{})}}else return{...o,[`${n}--${z(c)}`]:l}},t)||{})}}function q(n){return Array.isArray(n)?n.filter(r=>te(r)).join(" "):n}function U(n,r){const{error:t,valid:u,hint:o,loading:c}=r,{hintLabel:l,modelValue:b,valid:h,validLabel:g,error:i,errorLabel:s,...a}=e.toRefs(n),y=x(a,"loading"),m=x(a,"loadingLabel"),V=e.computed(()=>i.value?!!(i.value&&t||s!=null&&s.value&&Array.isArray(s.value)&&s.value.length>0||s!=null&&s.value&&!F(s)):!1),S=e.computed(()=>!!(l&&l.value||o)),B=e.computed(()=>!!(g&&g.value||u)),_=e.computed(()=>!!(y!=null&&y.value&&c||y!=null&&y.value&&(m!=null&&m.value))),w=e.computed(()=>S.value||B||V.value||_.value);return{hasErrors:V,hasHint:S,hasValid:B,hasLoading:_,HintSlot:{name:"HintSlot",props:{params:{type:Object,default:()=>({})}},setup(E){const j=e.computed(()=>{const A=P.toReactive({hintLabel:l,modelValue:b,valid:h,validLabel:g,error:i,errorLabel:s,loading:y,loadingLabel:m,...E.params});return i!=null&&i.value?(t==null?void 0:t(A))||q(s==null?void 0:s.value)||(l==null?void 0:l.value):h!=null&&h.value?(u==null?void 0:u(A))||q(g==null?void 0:g.value)||(l==null?void 0:l.value):y!=null&&y.value?(c==null?void 0:c(A))||q(m==null?void 0:m.value)||(l==null?void 0:l.value):(o==null?void 0:o(A))||q(l==null?void 0:l.value)||(l==null?void 0:l.value)});return{isVisible:w,hasErrors:V,hasValid:B,hintContent:j}},render(){if(this.isVisible)return e.h("small",{role:this.hasErrors||this.hasValid?"alert":void 0},this.hintContent)}}}}const Z={valid:Boolean,validLabel:[String,Array]},J={error:Boolean,errorLabel:[String,Array]},X={loading:Boolean,loadingLabel:String},I={disabled:Boolean},G={readonly:Boolean},M={modifiers:[String,Array]},Q={hintLabel:{type:String,default:""}},ne={...I,...M,modelValue:{type:[String,Number,Boolean,Object,Array],required:!0},labelNoResult:{type:String,default:"No results"},options:{type:Array,required:!0},useObject:Boolean,multiple:Boolean,maxValues:[Number,String],labelKey:{type:String,default:"label"},valueKey:{type:String,default:"value"}},oe={key:0,role:"option"},le=["aria-selected"],se=["for"],ae=["id","type","value","checked","disabled"],ie={name:"VvDropdown"},ce=e.defineComponent({...ie,props:ne,emits:["update:modelValue"],setup(n,{emit:r}){const t=n,u=C.nanoid(),{modifiers:o,disabled:c}=e.toRefs(t),{bemCssClasses:l}=R("vv-dropdown",{modifiers:o,disabled:c});function b(a){return Array.isArray(t.modelValue)?K(a,t.modelValue)||K(h(a),t.modelValue):$(a,t.modelValue)||$(h(a),t.modelValue)}function h(a){return typeof a=="string"?a:String(a[t.valueKey])}function g(a){return typeof a=="string"?a:a[t.labelKey]}function i(a){return typeof a=="string"||a.disabled===void 0?c.value:a.disabled}function s(a){var S,B;const y=a.target;let m=y.value;if(m=(t.useObject?(S=t.options)==null?void 0:S.find(_=>_[t.valueKey]==m):null)||m,t.multiple){if(typeof t.maxValues<"u"&&t.maxValues>=0&&Array.isArray(t.modelValue)&&((B=t.modelValue)==null?void 0:B.length)>=t.maxValues&&(Array.isArray(t.modelValue)&&!K(m,t.modelValue)||t.maxValues==0)){y.checked=!1;return}Array.isArray(t.modelValue)?m=K(m,t.modelValue)?ee(m,t.modelValue):[...t.modelValue,m]:m=[m]}r("update:modelValue",m)}return(a,y)=>{var m;return e.openBlock(),e.createElementBlock("ul",{class:e.normalizeClass(e.unref(l)),role:"listbox"},[(m=a.options)!=null&&m.length?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("li",oe,[e.createElementVNode("label",null,e.toDisplayString(a.labelNoResult),1)])),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.options,(V,S)=>(e.openBlock(),e.createElementBlock("li",{key:S,role:"option","aria-selected":b(V)},[e.createElementVNode("label",{for:`dropdown-${S}-${e.unref(u)}`},[e.createElementVNode("input",{id:`dropdown-${S}-${e.unref(u)}`,type:a.multiple?"checkbox":"radio",value:h(V),checked:b(V),disabled:i(V),tabindex:"-1","aria-hidden":"true",onInput:s},null,40,ae),e.createTextVNode(" "+e.toDisplayString(g(V)),1)],8,se)],8,le))),128))],2)}}}),de="ds",ue={color:String,width:{type:[String,Number]},height:{type:[String,Number]},name:{type:String,required:!0},provider:{type:String},prefix:{type:String,default:"normal"},src:String,horizontalFlip:Boolean,verticalFlip:Boolean,flip:String,mode:String,inline:Boolean,rotate:[Number,String],onLoad:Function,svg:String,modifiers:{type:[String,Array]}},fe={name:"VvIcon"},W=e.defineComponent({...fe,props:ue,setup(n){const r=n,t=e.ref(!0),{modifiers:u}=e.toRefs(r),o=e.inject(de),{bemCssClasses:c}=R("vv-icon",{modifiers:u}),l=e.computed(()=>r.provider||(o==null?void 0:o.provider)),b=e.computed(()=>{const i=r.name||"",s=`@${l.value}:${r.prefix}:${r.name}`;return N.iconExists(i)?i:N.iconExists(s)?s:(o==null?void 0:o.iconsCollections.find(a=>{const y=`@${l.value}:${a.prefix}:${i}`;if(N.iconExists(y))return y}))||i});function h(i){let s=null;if(typeof window>"u"){const{JSDOM:V}=require("jsdom");s=new V().window}return(s?new s.DOMParser:new window.DOMParser).parseFromString(i,"text/html").querySelector("svg")}function g(i){const s=h(i),a=(s==null?void 0:s.innerHTML.trim())||"";s&&a&&N.addIcon(`@${l.value}:${r.prefix}:${r.name}`,{body:a,height:s.viewBox.baseVal.height,width:s.viewBox.baseVal.width})}return o&&(r.src&&!N.iconExists(`@${l.value}:${r.prefix}:${r.name}`)?(t.value=!1,o.fetchIcon(r.src).then(i=>{i&&(g(i),t.value=!0)}).catch(i=>{throw new Error(`During fetch icon: ${i==null?void 0:i.message}`)})):r.svg&&g(r.svg)),(i,s)=>t.value?(e.openBlock(),e.createBlock(e.unref(N.Icon),e.mergeProps({key:0,class:e.unref(c)},{...i.$props,provider:e.unref(l),icon:e.unref(b)}),null,16,["class"])):e.createCommentVNode("",!0)}}),pe={...Z,...J,...Q,...X,...I,...G,...M,id:[String,Number],name:{type:String,required:!0},modelValue:{type:[String,Number,Boolean,Object,Array],default:void 0},label:String,required:Boolean,placeholder:String,options:{type:Array,required:!0},useObject:Boolean,labelKey:{type:String,default:"label"},valueKey:{type:String,default:"value"},iconLeft:String,iconRight:String,modifiers:[String,Array],tabindex:{type:[String,Number],default:0}},me=["update:modelValue"],ye=["for"],ge={class:"vv-select__wrapper"},he=["id","disabled","required"],be={key:0,value:void 0,disabled:""},Ve=["disabled","value"],Se={name:"VvNativeSelect"},ke=e.defineComponent({...Se,props:pe,emits:me,setup(n,{emit:r}){const t=n,u=e.useSlots(),{HintSlot:o,hasHint:c,hasErrors:l}=U(t,u),{modifiers:b,disabled:h,readonly:g,loading:i,iconLeft:s,iconRight:a,error:y,valid:m}=e.toRefs(t),V=e.computed(()=>String(t.id||C.nanoid())),S=e.computed(()=>`${V.value}-hint`),B=e.computed(()=>!F(t.modelValue)),_=e.computed(()=>t.disabled||t.readonly),w=e.computed(()=>_.value?-1:t.tabindex),E=e.computed(()=>{if(t.error===!0)return!0;if(t.valid===!0)return!1}),{bemCssClasses:j}=R("vv-select",{modifiers:b,loading:i,readonly:g,iconLeft:s,iconRight:a,valid:m,invalid:y,dirty:B}),A=e.computed(()=>({name:t.name,tabindex:w.value,"aria-invalid":E.value,"aria-describedby":!l.value&&c.value?S.value:void 0,"aria-errormessage":l.value?S.value:void 0}));function H(p){return typeof p=="string"?p:p[t.valueKey]}function L(p){return typeof p=="string"?p:p[t.labelKey]}function v(p){return typeof p=="string"||p.disabled===void 0?h.value:p.disabled}const D=e.computed({get:()=>{var p;return typeof t.modelValue=="object"?(p=t.modelValue)==null?void 0:p[t.valueKey]:t.modelValue},set:p=>{var d;const f=t.useObject?(d=t.options)==null?void 0:d.find(k=>k[t.valueKey]===p):void 0;r("update:modelValue",f??p)}});return(p,f)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(e.unref(j))},[p.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:e.unref(V)},e.toDisplayString(p.label),9,ye)):e.createCommentVNode("",!0),e.createElementVNode("div",ge,[e.renderSlot(p.$slots,"icon-left",{},()=>[e.unref(s)?(e.openBlock(),e.createBlock(W,{key:0,name:e.unref(s)},null,8,["name"])):e.createCommentVNode("",!0)]),e.withDirectives(e.createElementVNode("select",e.mergeProps({id:e.unref(V),"onUpdate:modelValue":f[0]||(f[0]=d=>e.isRef(D)?D.value=d:null)},e.unref(A),{disabled:e.unref(_),required:p.required}),[p.placeholder?(e.openBlock(),e.createElementBlock("option",be,e.toDisplayString(p.placeholder),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.options,(d,k)=>(e.openBlock(),e.createElementBlock("option",{key:k,disabled:v(d),value:H(d)},e.toDisplayString(L(d)),9,Ve))),128))],16,he),[[e.vModelSelect,e.unref(D)]]),e.renderSlot(p.$slots,"icon-right",{},()=>[e.unref(a)?(e.openBlock(),e.createBlock(W,{key:0,name:e.unref(a)},null,8,["name"])):e.createCommentVNode("",!0)])]),e.createVNode(e.unref(o),{id:e.unref(S),class:"vv-select__hint"},null,8,["id"])],2))}}),Be={...Z,...J,...Q,...X,...I,...G,...M,modelValue:{type:[String,Number,Boolean,Object,Array],default:void 0},label:String,labelNoResult:{type:String,default:"No results"},placeholder:String,searchable:Boolean,searchPlaceholder:String,debounceSearch:{type:[Number,String],default:0},options:{type:Array,required:!0},useObject:Boolean,multiple:Boolean,maxValues:[Number,String],separator:{type:String,default:", "},labelKey:{type:String,default:"label"},valueKey:{type:String,default:"value"},iconLeft:String,iconRight:String,native:Boolean,tabindex:{type:[Number,String],default:0}},_e=["id"],Ae=["id","for"],Ce=["tabindex"],Ne=["id","placeholder"],$e={name:"VvSelect"};return e.defineComponent({...$e,props:Be,emits:["update:modelValue","change:search"],setup(n,{emit:r}){const t=n,u=e.useSlots(),{HintSlot:o}=U(t,u),c=e.ref(),l=e.ref();P.useFocus(l,{initialValue:!0});const b=C.nanoid(),h=e.ref(""),g=P.refDebounced(h,Number(t.debounceSearch)),i=e.ref(!1),{modifiers:s,disabled:a,readonly:y,loading:m,iconLeft:V,iconRight:S,valid:B,error:_}=e.toRefs(t);e.watch(g,()=>r("change:search",g.value));const w=e.computed(()=>!F(t.modelValue)),E=e.computed(()=>a.value||y.value?-1:t.tabindex),{bemCssClasses:j}=R("vv-select",{modifiers:s,disabled:a,loading:m,readonly:y,iconLeft:V,iconRight:S,valid:B,invalid:_,dirty:w}),A=e.computed(()=>{var f;return(f=t.options)==null?void 0:f.every(d=>typeof d=="object")}),H=e.computed(()=>t.searchable?L.value:t.options),L=e.computed(()=>{var f;return(f=t.options)==null?void 0:f.filter(d=>typeof d=="string"?d.toLowerCase().includes(g.value.toLowerCase().trim()):typeof d[t.labelKey]=="string"?d[t.labelKey].toLowerCase().includes(g.value.toLowerCase().trim()):!1)}),v=e.computed(()=>{var d,k;if(t.multiple&&Array.isArray(t.modelValue)&&((d=t.modelValue)!=null&&d.length))return A.value?re(t.options,t.modelValue,t.valueKey).map(O=>O[t.labelKey]).join(t.separator):t.modelValue.join(t.separator);const f=t.useObject?t.modelValue:(k=t.options)==null?void 0:k.find(O=>typeof O=="object"?O[t.valueKey]==t.modelValue:O==t.modelValue);return typeof f=="object"?f==null?void 0:f[t.labelKey]:f});P.onClickOutside(c,()=>{c.value.open=!1});function D(f){const d=f.target;i.value=d.open}function p(f){c.value&&!t.multiple&&(c.value.open=!1),r("update:modelValue",f)}return(f,d)=>f.native?(e.openBlock(),e.createBlock(ke,e.mergeProps({key:1},t,{"onUpdate:modelValue":d[4]||(d[4]=k=>r("update:modelValue",k))}),null,16)):(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(b),class:e.normalizeClass(e.unref(j))},[f.label?(e.openBlock(),e.createElementBlock("label",{key:0,id:`${e.unref(b)}-label`,for:f.searchable&&i.value?`${e.unref(b)}-input`:void 0},e.toDisplayString(f.label),9,Ae)):e.createCommentVNode("",!0),e.createElementVNode("details",{ref_key:"dropdown",ref:c,class:"vv-select__wrapper",onClick:d[2]||(d[2]=k=>e.unref(a)||e.unref(y)?k.preventDefault():null),onKeyup:d[3]||(d[3]=e.withKeys(k=>c.value.open=!1,["esc"])),onToggle:D},[e.createElementVNode("summary",{class:"vv-select__input",tabindex:e.unref(E),onKeyup:d[1]||(d[1]=e.withKeys(k=>f.searchable?k.preventDefault():null,["space"]))},[f.searchable&&i.value?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:0,id:`${e.unref(b)}-input`,ref_key:"inputSearch",ref:l,"onUpdate:modelValue":d[0]||(d[0]=k=>h.value=k),role:"combobox",placeholder:f.searchPlaceholder},null,8,Ne)),[[e.vModelText,h.value]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(e.unref(v)||f.placeholder),1)],64))],40,Ce),e.createVNode(ce,e.mergeProps({id:`${e.unref(b)}-dropdown`},{...t,options:e.unref(H)},{"onUpdate:modelValue":p}),null,16,["id"])],544),e.createVNode(e.unref(o),{class:"vv-select__hint"})],10,_e))}})});
|
|
@@ -1,231 +1,9 @@
|
|
|
1
|
-
import type { Option } from '
|
|
2
|
-
declare const _default: {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
disabled: boolean;
|
|
8
|
-
readonly: boolean;
|
|
9
|
-
loading: boolean;
|
|
10
|
-
error: boolean;
|
|
11
|
-
valid: boolean;
|
|
12
|
-
hintLabel: string;
|
|
13
|
-
labelNoResult: string;
|
|
14
|
-
useObject: boolean;
|
|
15
|
-
multiple: boolean;
|
|
16
|
-
labelKey: string;
|
|
17
|
-
valueKey: string;
|
|
18
|
-
searchable: boolean;
|
|
19
|
-
debounceSearch: string | number;
|
|
20
|
-
separator: string;
|
|
21
|
-
}> & Omit<Readonly<import("vue").ExtractPropTypes<{
|
|
22
|
-
modelValue: (StringConstructor | ArrayConstructor | ObjectConstructor)[];
|
|
23
|
-
label: StringConstructor;
|
|
24
|
-
labelNoResult: {
|
|
25
|
-
type: StringConstructor;
|
|
26
|
-
default: string;
|
|
27
|
-
};
|
|
28
|
-
placeholder: StringConstructor;
|
|
29
|
-
searchable: BooleanConstructor;
|
|
30
|
-
searchPlaceholder: StringConstructor;
|
|
31
|
-
debounceSearch: {
|
|
32
|
-
type: (StringConstructor | NumberConstructor)[];
|
|
33
|
-
default: number;
|
|
34
|
-
};
|
|
35
|
-
options: {
|
|
36
|
-
type: import("vue").PropType<(string | Option)[]>;
|
|
37
|
-
required: boolean;
|
|
38
|
-
};
|
|
39
|
-
useObject: BooleanConstructor;
|
|
40
|
-
multiple: BooleanConstructor;
|
|
41
|
-
maxValues: (StringConstructor | NumberConstructor)[];
|
|
42
|
-
separator: {
|
|
43
|
-
type: StringConstructor;
|
|
44
|
-
default: string;
|
|
45
|
-
};
|
|
46
|
-
labelKey: {
|
|
47
|
-
type: StringConstructor;
|
|
48
|
-
default: string;
|
|
49
|
-
};
|
|
50
|
-
valueKey: {
|
|
51
|
-
type: StringConstructor;
|
|
52
|
-
default: string;
|
|
53
|
-
};
|
|
54
|
-
iconLeft: StringConstructor;
|
|
55
|
-
iconRight: StringConstructor;
|
|
56
|
-
modifiers: (StringConstructor | ArrayConstructor)[];
|
|
57
|
-
readonly: BooleanConstructor;
|
|
58
|
-
disabled: BooleanConstructor;
|
|
59
|
-
loading: BooleanConstructor;
|
|
60
|
-
loadingLabel: StringConstructor;
|
|
61
|
-
hintLabel: {
|
|
62
|
-
type: StringConstructor;
|
|
63
|
-
default: string;
|
|
64
|
-
};
|
|
65
|
-
error: BooleanConstructor;
|
|
66
|
-
errorLabel: (StringConstructor | ArrayConstructor)[];
|
|
67
|
-
valid: BooleanConstructor;
|
|
68
|
-
validLabel: (StringConstructor | ArrayConstructor)[];
|
|
69
|
-
}>> & {
|
|
70
|
-
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
71
|
-
"onChange:search"?: ((...args: any[]) => any) | undefined;
|
|
72
|
-
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "disabled" | "readonly" | "loading" | "error" | "valid" | "hintLabel" | "labelNoResult" | "useObject" | "multiple" | "labelKey" | "valueKey" | "searchable" | "debounceSearch" | "separator">;
|
|
73
|
-
$attrs: {
|
|
74
|
-
[x: string]: unknown;
|
|
75
|
-
};
|
|
76
|
-
$refs: {
|
|
77
|
-
[x: string]: unknown;
|
|
78
|
-
};
|
|
79
|
-
$slots: Readonly<{
|
|
80
|
-
[name: string]: import("vue").Slot | undefined;
|
|
81
|
-
}>;
|
|
82
|
-
$root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null;
|
|
83
|
-
$parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null;
|
|
84
|
-
$emit: (event: "update:modelValue" | "change:search", ...args: any[]) => void;
|
|
85
|
-
$el: any;
|
|
86
|
-
$options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
|
87
|
-
modelValue: (StringConstructor | ArrayConstructor | ObjectConstructor)[];
|
|
88
|
-
label: StringConstructor;
|
|
89
|
-
labelNoResult: {
|
|
90
|
-
type: StringConstructor;
|
|
91
|
-
default: string;
|
|
92
|
-
};
|
|
93
|
-
placeholder: StringConstructor;
|
|
94
|
-
searchable: BooleanConstructor;
|
|
95
|
-
searchPlaceholder: StringConstructor;
|
|
96
|
-
debounceSearch: {
|
|
97
|
-
type: (StringConstructor | NumberConstructor)[];
|
|
98
|
-
default: number;
|
|
99
|
-
};
|
|
100
|
-
options: {
|
|
101
|
-
type: import("vue").PropType<(string | Option)[]>;
|
|
102
|
-
required: boolean;
|
|
103
|
-
};
|
|
104
|
-
useObject: BooleanConstructor;
|
|
105
|
-
multiple: BooleanConstructor;
|
|
106
|
-
maxValues: (StringConstructor | NumberConstructor)[];
|
|
107
|
-
separator: {
|
|
108
|
-
type: StringConstructor;
|
|
109
|
-
default: string;
|
|
110
|
-
};
|
|
111
|
-
labelKey: {
|
|
112
|
-
type: StringConstructor;
|
|
113
|
-
default: string;
|
|
114
|
-
};
|
|
115
|
-
valueKey: {
|
|
116
|
-
type: StringConstructor;
|
|
117
|
-
default: string;
|
|
118
|
-
};
|
|
119
|
-
iconLeft: StringConstructor;
|
|
120
|
-
iconRight: StringConstructor;
|
|
121
|
-
modifiers: (StringConstructor | ArrayConstructor)[];
|
|
122
|
-
readonly: BooleanConstructor;
|
|
123
|
-
disabled: BooleanConstructor;
|
|
124
|
-
loading: BooleanConstructor;
|
|
125
|
-
loadingLabel: StringConstructor;
|
|
126
|
-
hintLabel: {
|
|
127
|
-
type: StringConstructor;
|
|
128
|
-
default: string;
|
|
129
|
-
};
|
|
130
|
-
error: BooleanConstructor;
|
|
131
|
-
errorLabel: (StringConstructor | ArrayConstructor)[];
|
|
132
|
-
valid: BooleanConstructor;
|
|
133
|
-
validLabel: (StringConstructor | ArrayConstructor)[];
|
|
134
|
-
}>> & {
|
|
135
|
-
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
136
|
-
"onChange:search"?: ((...args: any[]) => any) | undefined;
|
|
137
|
-
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "change:search")[], string, {
|
|
138
|
-
disabled: boolean;
|
|
139
|
-
readonly: boolean;
|
|
140
|
-
loading: boolean;
|
|
141
|
-
error: boolean;
|
|
142
|
-
valid: boolean;
|
|
143
|
-
hintLabel: string;
|
|
144
|
-
labelNoResult: string;
|
|
145
|
-
useObject: boolean;
|
|
146
|
-
multiple: boolean;
|
|
147
|
-
labelKey: string;
|
|
148
|
-
valueKey: string;
|
|
149
|
-
searchable: boolean;
|
|
150
|
-
debounceSearch: string | number;
|
|
151
|
-
separator: string;
|
|
152
|
-
}, {}, string> & {
|
|
153
|
-
beforeCreate?: ((() => void) | (() => void)[]) | undefined;
|
|
154
|
-
created?: ((() => void) | (() => void)[]) | undefined;
|
|
155
|
-
beforeMount?: ((() => void) | (() => void)[]) | undefined;
|
|
156
|
-
mounted?: ((() => void) | (() => void)[]) | undefined;
|
|
157
|
-
beforeUpdate?: ((() => void) | (() => void)[]) | undefined;
|
|
158
|
-
updated?: ((() => void) | (() => void)[]) | undefined;
|
|
159
|
-
activated?: ((() => void) | (() => void)[]) | undefined;
|
|
160
|
-
deactivated?: ((() => void) | (() => void)[]) | undefined;
|
|
161
|
-
beforeDestroy?: ((() => void) | (() => void)[]) | undefined;
|
|
162
|
-
beforeUnmount?: ((() => void) | (() => void)[]) | undefined;
|
|
163
|
-
destroyed?: ((() => void) | (() => void)[]) | undefined;
|
|
164
|
-
unmounted?: ((() => void) | (() => void)[]) | undefined;
|
|
165
|
-
renderTracked?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
|
|
166
|
-
renderTriggered?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
|
|
167
|
-
errorCaptured?: (((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null, info: string) => boolean | void)[]) | undefined;
|
|
168
|
-
};
|
|
169
|
-
$forceUpdate: () => void;
|
|
170
|
-
$nextTick: typeof import("vue").nextTick;
|
|
171
|
-
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (args_0: R, args_1: R) => any : (...args: any) => any, options?: import("vue").WatchOptions<boolean> | undefined): import("vue").WatchStopHandle;
|
|
172
|
-
} & Readonly<import("vue").ExtractPropTypes<{
|
|
173
|
-
modelValue: (StringConstructor | ArrayConstructor | ObjectConstructor)[];
|
|
174
|
-
label: StringConstructor;
|
|
175
|
-
labelNoResult: {
|
|
176
|
-
type: StringConstructor;
|
|
177
|
-
default: string;
|
|
178
|
-
};
|
|
179
|
-
placeholder: StringConstructor;
|
|
180
|
-
searchable: BooleanConstructor;
|
|
181
|
-
searchPlaceholder: StringConstructor;
|
|
182
|
-
debounceSearch: {
|
|
183
|
-
type: (StringConstructor | NumberConstructor)[];
|
|
184
|
-
default: number;
|
|
185
|
-
};
|
|
186
|
-
options: {
|
|
187
|
-
type: import("vue").PropType<(string | Option)[]>;
|
|
188
|
-
required: boolean;
|
|
189
|
-
};
|
|
190
|
-
useObject: BooleanConstructor;
|
|
191
|
-
multiple: BooleanConstructor;
|
|
192
|
-
maxValues: (StringConstructor | NumberConstructor)[];
|
|
193
|
-
separator: {
|
|
194
|
-
type: StringConstructor;
|
|
195
|
-
default: string;
|
|
196
|
-
};
|
|
197
|
-
labelKey: {
|
|
198
|
-
type: StringConstructor;
|
|
199
|
-
default: string;
|
|
200
|
-
};
|
|
201
|
-
valueKey: {
|
|
202
|
-
type: StringConstructor;
|
|
203
|
-
default: string;
|
|
204
|
-
};
|
|
205
|
-
iconLeft: StringConstructor;
|
|
206
|
-
iconRight: StringConstructor;
|
|
207
|
-
modifiers: (StringConstructor | ArrayConstructor)[];
|
|
208
|
-
readonly: BooleanConstructor;
|
|
209
|
-
disabled: BooleanConstructor;
|
|
210
|
-
loading: BooleanConstructor;
|
|
211
|
-
loadingLabel: StringConstructor;
|
|
212
|
-
hintLabel: {
|
|
213
|
-
type: StringConstructor;
|
|
214
|
-
default: string;
|
|
215
|
-
};
|
|
216
|
-
error: BooleanConstructor;
|
|
217
|
-
errorLabel: (StringConstructor | ArrayConstructor)[];
|
|
218
|
-
valid: BooleanConstructor;
|
|
219
|
-
validLabel: (StringConstructor | ArrayConstructor)[];
|
|
220
|
-
}>> & {
|
|
221
|
-
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
222
|
-
"onChange:search"?: ((...args: any[]) => any) | undefined;
|
|
223
|
-
} & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties & {};
|
|
224
|
-
__isFragment?: undefined;
|
|
225
|
-
__isTeleport?: undefined;
|
|
226
|
-
__isSuspense?: undefined;
|
|
227
|
-
} & import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
|
228
|
-
modelValue: (StringConstructor | ArrayConstructor | ObjectConstructor)[];
|
|
1
|
+
import type { Option } from '@/components/VvDropdown';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
modelValue: {
|
|
4
|
+
type: (ArrayConstructor | ObjectConstructor | StringConstructor | BooleanConstructor | NumberConstructor)[];
|
|
5
|
+
default: undefined;
|
|
6
|
+
};
|
|
229
7
|
label: StringConstructor;
|
|
230
8
|
labelNoResult: {
|
|
231
9
|
type: StringConstructor;
|
|
@@ -259,7 +37,12 @@ declare const _default: {
|
|
|
259
37
|
};
|
|
260
38
|
iconLeft: StringConstructor;
|
|
261
39
|
iconRight: StringConstructor;
|
|
262
|
-
|
|
40
|
+
native: BooleanConstructor;
|
|
41
|
+
tabindex: {
|
|
42
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
43
|
+
default: number;
|
|
44
|
+
};
|
|
45
|
+
modifiers: import("vue").PropType<string | string[]>;
|
|
263
46
|
readonly: BooleanConstructor;
|
|
264
47
|
disabled: BooleanConstructor;
|
|
265
48
|
loading: BooleanConstructor;
|
|
@@ -269,19 +52,77 @@ declare const _default: {
|
|
|
269
52
|
default: string;
|
|
270
53
|
};
|
|
271
54
|
error: BooleanConstructor;
|
|
272
|
-
errorLabel: (
|
|
55
|
+
errorLabel: (ArrayConstructor | StringConstructor)[];
|
|
273
56
|
valid: BooleanConstructor;
|
|
274
|
-
validLabel: (
|
|
57
|
+
validLabel: (ArrayConstructor | StringConstructor)[];
|
|
58
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "change:search")[], "update:modelValue" | "change:search", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
59
|
+
modelValue: {
|
|
60
|
+
type: (ArrayConstructor | ObjectConstructor | StringConstructor | BooleanConstructor | NumberConstructor)[];
|
|
61
|
+
default: undefined;
|
|
62
|
+
};
|
|
63
|
+
label: StringConstructor;
|
|
64
|
+
labelNoResult: {
|
|
65
|
+
type: StringConstructor;
|
|
66
|
+
default: string;
|
|
67
|
+
};
|
|
68
|
+
placeholder: StringConstructor;
|
|
69
|
+
searchable: BooleanConstructor;
|
|
70
|
+
searchPlaceholder: StringConstructor;
|
|
71
|
+
debounceSearch: {
|
|
72
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
73
|
+
default: number;
|
|
74
|
+
};
|
|
75
|
+
options: {
|
|
76
|
+
type: import("vue").PropType<(string | Option)[]>;
|
|
77
|
+
required: boolean;
|
|
78
|
+
};
|
|
79
|
+
useObject: BooleanConstructor;
|
|
80
|
+
multiple: BooleanConstructor;
|
|
81
|
+
maxValues: (StringConstructor | NumberConstructor)[];
|
|
82
|
+
separator: {
|
|
83
|
+
type: StringConstructor;
|
|
84
|
+
default: string;
|
|
85
|
+
};
|
|
86
|
+
labelKey: {
|
|
87
|
+
type: StringConstructor;
|
|
88
|
+
default: string;
|
|
89
|
+
};
|
|
90
|
+
valueKey: {
|
|
91
|
+
type: StringConstructor;
|
|
92
|
+
default: string;
|
|
93
|
+
};
|
|
94
|
+
iconLeft: StringConstructor;
|
|
95
|
+
iconRight: StringConstructor;
|
|
96
|
+
native: BooleanConstructor;
|
|
97
|
+
tabindex: {
|
|
98
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
99
|
+
default: number;
|
|
100
|
+
};
|
|
101
|
+
modifiers: import("vue").PropType<string | string[]>;
|
|
102
|
+
readonly: BooleanConstructor;
|
|
103
|
+
disabled: BooleanConstructor;
|
|
104
|
+
loading: BooleanConstructor;
|
|
105
|
+
loadingLabel: StringConstructor;
|
|
106
|
+
hintLabel: {
|
|
107
|
+
type: StringConstructor;
|
|
108
|
+
default: string;
|
|
109
|
+
};
|
|
110
|
+
error: BooleanConstructor;
|
|
111
|
+
errorLabel: (ArrayConstructor | StringConstructor)[];
|
|
112
|
+
valid: BooleanConstructor;
|
|
113
|
+
validLabel: (ArrayConstructor | StringConstructor)[];
|
|
275
114
|
}>> & {
|
|
276
115
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
277
116
|
"onChange:search"?: ((...args: any[]) => any) | undefined;
|
|
278
|
-
}, {
|
|
117
|
+
}, {
|
|
118
|
+
modelValue: string | number | boolean | unknown[] | Record<string, any>;
|
|
279
119
|
disabled: boolean;
|
|
280
|
-
readonly: boolean;
|
|
281
|
-
loading: boolean;
|
|
282
120
|
error: boolean;
|
|
283
|
-
|
|
121
|
+
loading: boolean;
|
|
122
|
+
readonly: boolean;
|
|
123
|
+
tabindex: string | number;
|
|
284
124
|
hintLabel: string;
|
|
125
|
+
valid: boolean;
|
|
285
126
|
labelNoResult: string;
|
|
286
127
|
useObject: boolean;
|
|
287
128
|
multiple: boolean;
|
|
@@ -290,5 +131,6 @@ declare const _default: {
|
|
|
290
131
|
searchable: boolean;
|
|
291
132
|
debounceSearch: string | number;
|
|
292
133
|
separator: string;
|
|
293
|
-
|
|
134
|
+
native: boolean;
|
|
135
|
+
}>;
|
|
294
136
|
export default _default;
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import type { PropType } from 'vue';
|
|
2
|
-
import type { Option } from '
|
|
2
|
+
import type { Option } from '@/components/VvDropdown';
|
|
3
3
|
export declare const VvSelectProps: {
|
|
4
4
|
/**
|
|
5
|
-
* modelValue can be
|
|
5
|
+
* modelValue can be a string, number, boolean, object or array of string, number, boolean, object
|
|
6
6
|
*/
|
|
7
|
-
modelValue:
|
|
7
|
+
modelValue: {
|
|
8
|
+
type: (ArrayConstructor | ObjectConstructor | StringConstructor | BooleanConstructor | NumberConstructor)[];
|
|
9
|
+
default: undefined;
|
|
10
|
+
};
|
|
8
11
|
/**
|
|
9
12
|
* Select input label
|
|
10
13
|
*/
|
|
@@ -83,7 +86,15 @@ export declare const VvSelectProps: {
|
|
|
83
86
|
* Icon name of icon in right position
|
|
84
87
|
*/
|
|
85
88
|
iconRight: StringConstructor;
|
|
86
|
-
|
|
89
|
+
/**
|
|
90
|
+
* Icon name of icon in right position
|
|
91
|
+
*/
|
|
92
|
+
native: BooleanConstructor;
|
|
93
|
+
tabindex: {
|
|
94
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
95
|
+
default: number;
|
|
96
|
+
};
|
|
97
|
+
modifiers: PropType<string | string[]>;
|
|
87
98
|
readonly: BooleanConstructor;
|
|
88
99
|
disabled: BooleanConstructor;
|
|
89
100
|
loading: BooleanConstructor;
|
|
@@ -93,7 +104,7 @@ export declare const VvSelectProps: {
|
|
|
93
104
|
default: string;
|
|
94
105
|
};
|
|
95
106
|
error: BooleanConstructor;
|
|
96
|
-
errorLabel: (
|
|
107
|
+
errorLabel: (ArrayConstructor | StringConstructor)[];
|
|
97
108
|
valid: BooleanConstructor;
|
|
98
|
-
validLabel: (
|
|
109
|
+
validLabel: (ArrayConstructor | StringConstructor)[];
|
|
99
110
|
};
|