@groupteknology/vuno 1.0.1 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +53 -27
- package/dist/module.d.mts +2 -0
- package/dist/module.json +1 -1
- package/dist/module.mjs +33 -12
- package/dist/runtime/app/assets/css/dialog.css +1 -1
- package/dist/runtime/app/assets/css/stylesheet.css +1 -0
- package/dist/runtime/app/assets/css/theme.css +1 -1
- package/dist/runtime/app/assets/css/tokens.css +1 -1
- package/dist/runtime/app/components/Alert/Alert.d.vue.ts +20 -0
- package/dist/runtime/app/components/Alert/Alert.theme.d.ts +13 -0
- package/dist/runtime/app/components/Alert/Alert.theme.js +13 -0
- package/dist/runtime/app/components/Alert/Alert.vue +59 -0
- package/dist/runtime/app/components/Alert/Alert.vue.d.ts +20 -0
- package/dist/runtime/app/components/{overlays → App}/App.d.vue.ts +4 -5
- package/dist/runtime/app/components/{overlays → App}/App.vue +8 -12
- package/dist/runtime/app/components/{overlays → App}/App.vue.d.ts +4 -5
- package/dist/runtime/app/components/App/internal/Overlay/Overlay.d.vue.ts +7 -0
- package/dist/runtime/app/components/{overlays → App/internal/Overlay}/Overlay.vue +5 -6
- package/dist/runtime/app/components/App/internal/Overlay/Overlay.vue.d.ts +7 -0
- package/dist/runtime/app/components/App/internal/OverlayItem/OverlayItem.d.vue.ts +8 -0
- package/dist/runtime/app/components/App/internal/OverlayItem/OverlayItem.vue +19 -0
- package/dist/runtime/app/components/App/internal/OverlayItem/OverlayItem.vue.d.ts +8 -0
- package/dist/runtime/app/components/{overlays → App/internal/Toast}/Toast.d.vue.ts +3 -3
- package/dist/runtime/app/components/App/internal/Toast/Toast.theme.d.ts +13 -0
- package/dist/runtime/app/components/App/internal/Toast/Toast.theme.js +18 -0
- package/dist/runtime/app/components/{overlays → App/internal/Toast}/Toast.vue +3 -2
- package/dist/runtime/app/components/{overlays → App/internal/Toast}/Toast.vue.d.ts +3 -3
- package/dist/runtime/app/components/{overlays → App/internal/Toaster}/Toaster.d.vue.ts +3 -3
- package/dist/runtime/app/components/App/internal/Toaster/Toaster.theme.d.ts +15 -0
- package/dist/runtime/app/components/App/internal/Toaster/Toaster.theme.js +16 -0
- package/dist/runtime/app/components/{overlays → App/internal/Toaster}/Toaster.vue +3 -2
- package/dist/runtime/app/components/{overlays → App/internal/Toaster}/Toaster.vue.d.ts +3 -3
- package/dist/runtime/app/components/{actions → Avatar}/Avatar.d.vue.ts +9 -5
- package/dist/runtime/app/components/Avatar/Avatar.theme.d.ts +30 -0
- package/dist/runtime/app/components/Avatar/Avatar.theme.js +22 -0
- package/dist/runtime/app/components/{actions → Avatar}/Avatar.vue +7 -5
- package/dist/runtime/app/components/{actions → Avatar}/Avatar.vue.d.ts +9 -5
- package/dist/runtime/app/components/{actions → Badge}/Badge.d.vue.ts +9 -5
- package/dist/runtime/app/components/Badge/Badge.theme.d.ts +40 -0
- package/dist/runtime/app/components/Badge/Badge.theme.js +22 -0
- package/dist/runtime/app/components/{actions → Badge}/Badge.vue +3 -0
- package/dist/runtime/app/components/{actions → Badge}/Badge.vue.d.ts +9 -5
- package/dist/runtime/app/components/{actions → Button}/Button.d.vue.ts +10 -6
- package/dist/runtime/app/components/Button/Button.theme.d.ts +88 -0
- package/dist/runtime/app/components/Button/Button.theme.js +59 -0
- package/dist/runtime/app/components/{actions → Button}/Button.vue +10 -3
- package/dist/runtime/app/components/{actions → Button}/Button.vue.d.ts +10 -6
- package/dist/runtime/app/components/{structure → Card}/Card.d.vue.ts +9 -5
- package/dist/runtime/app/components/Card/Card.theme.d.ts +57 -0
- package/dist/runtime/app/components/Card/Card.theme.js +62 -0
- package/dist/runtime/app/components/{structure → Card}/Card.vue +3 -1
- package/dist/runtime/app/components/{structure → Card}/Card.vue.d.ts +9 -5
- package/dist/runtime/app/components/Code/Code.d.vue.ts +19 -0
- package/dist/runtime/app/components/Code/Code.theme.d.ts +11 -0
- package/dist/runtime/app/components/Code/Code.theme.js +12 -0
- package/dist/runtime/app/components/Code/Code.vue +109 -0
- package/dist/runtime/app/components/Code/Code.vue.d.ts +19 -0
- package/dist/runtime/app/components/{overlays → Confirm}/Confirm.d.vue.ts +2 -2
- package/dist/runtime/app/components/Confirm/Confirm.theme.d.ts +12 -0
- package/dist/runtime/app/components/Confirm/Confirm.theme.js +13 -0
- package/dist/runtime/app/components/{overlays → Confirm}/Confirm.vue +10 -5
- package/dist/runtime/app/components/{overlays → Confirm}/Confirm.vue.d.ts +2 -2
- package/dist/runtime/app/components/{structure → Container}/Container.d.vue.ts +5 -5
- package/dist/runtime/app/components/Container/Container.theme.d.ts +53 -0
- package/dist/runtime/app/components/Container/Container.theme.js +31 -0
- package/dist/runtime/app/components/{structure → Container}/Container.vue +2 -1
- package/dist/runtime/app/components/{structure → Container}/Container.vue.d.ts +5 -5
- package/dist/runtime/app/components/ControlGroup/ControlGroup.d.vue.ts +26 -0
- package/dist/runtime/app/components/ControlGroup/ControlGroup.theme.d.ts +16 -0
- package/dist/runtime/app/components/ControlGroup/ControlGroup.theme.js +13 -0
- package/dist/runtime/app/components/ControlGroup/ControlGroup.vue +26 -0
- package/dist/runtime/app/components/ControlGroup/ControlGroup.vue.d.ts +26 -0
- package/dist/runtime/app/components/FieldArray/FieldArray.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldArray/FieldArray.theme.d.ts +12 -0
- package/dist/runtime/app/components/FieldArray/FieldArray.theme.js +13 -0
- package/dist/runtime/app/components/FieldArray/FieldArray.vue +173 -0
- package/dist/runtime/app/components/FieldArray/FieldArray.vue.d.ts +13 -0
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.theme.js +2 -0
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.vue +39 -0
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.vue.d.ts +13 -0
- package/dist/runtime/app/components/{forms → FieldCheckbox/internal/Checkbox}/Checkbox.d.vue.ts +9 -4
- package/dist/runtime/app/components/FieldCheckbox/internal/Checkbox/Checkbox.theme.d.ts +30 -0
- package/dist/runtime/app/components/FieldCheckbox/internal/Checkbox/Checkbox.theme.js +10 -0
- package/dist/runtime/app/components/{forms → FieldCheckbox/internal/Checkbox}/Checkbox.vue +7 -4
- package/dist/runtime/app/components/{forms → FieldCheckbox/internal/Checkbox}/Checkbox.vue.d.ts +9 -4
- package/dist/runtime/app/components/FieldColor/FieldColor.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldColor/FieldColor.theme.d.ts +27 -0
- package/dist/runtime/app/components/FieldColor/FieldColor.theme.js +18 -0
- package/dist/runtime/app/components/{forms/fields → FieldColor}/FieldColor.vue +39 -32
- package/dist/runtime/app/components/FieldColor/FieldColor.vue.d.ts +13 -0
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.theme.js +2 -0
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.vue +51 -0
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.vue.d.ts +13 -0
- package/dist/runtime/app/components/{forms/fields → FieldFile}/FieldFile.d.vue.ts +10 -2
- package/dist/runtime/app/components/FieldFile/FieldFile.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldFile/FieldFile.theme.js +2 -0
- package/dist/runtime/app/components/FieldFile/FieldFile.vue +99 -0
- package/dist/runtime/app/components/{forms/fields → FieldFile}/FieldFile.vue.d.ts +10 -2
- package/dist/runtime/app/components/{forms → FieldFile/internal/FileUpload}/FileUpload.d.vue.ts +25 -20
- package/dist/runtime/app/components/FieldFile/internal/FileUpload/FileUpload.theme.d.ts +88 -0
- package/dist/runtime/app/components/FieldFile/internal/FileUpload/FileUpload.theme.js +55 -0
- package/dist/runtime/app/components/{forms → FieldFile/internal/FileUpload}/FileUpload.vue +21 -20
- package/dist/runtime/app/components/{forms → FieldFile/internal/FileUpload}/FileUpload.vue.d.ts +25 -20
- package/dist/runtime/app/components/FieldInput/FieldInput.d.vue.ts +24 -0
- package/dist/runtime/app/components/FieldInput/FieldInput.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldInput/FieldInput.theme.js +2 -0
- package/dist/runtime/app/components/FieldInput/FieldInput.vue +61 -0
- package/dist/runtime/app/components/FieldInput/FieldInput.vue.d.ts +24 -0
- package/dist/runtime/app/components/FieldNumber/FieldNumber.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldNumber/FieldNumber.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldNumber/FieldNumber.theme.js +2 -0
- package/dist/runtime/app/components/FieldNumber/FieldNumber.vue +47 -0
- package/dist/runtime/app/components/FieldNumber/FieldNumber.vue.d.ts +13 -0
- package/dist/runtime/app/components/FieldPassword/FieldPassword.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldPassword/FieldPassword.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldPassword/FieldPassword.theme.js +2 -0
- package/dist/runtime/app/components/FieldPassword/FieldPassword.vue +62 -0
- package/dist/runtime/app/components/FieldPassword/FieldPassword.vue.d.ts +13 -0
- package/dist/runtime/app/components/FieldRadio/FieldRadio.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldRadio/FieldRadio.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldRadio/FieldRadio.theme.js +2 -0
- package/dist/runtime/app/components/FieldRadio/FieldRadio.vue +41 -0
- package/dist/runtime/app/components/FieldRadio/FieldRadio.vue.d.ts +13 -0
- package/dist/runtime/app/components/{forms → FieldRadio/internal/RadioGroup}/RadioGroup.d.vue.ts +10 -8
- package/dist/runtime/app/components/FieldRadio/internal/RadioGroup/RadioGroup.theme.d.ts +54 -0
- package/dist/runtime/app/components/FieldRadio/internal/RadioGroup/RadioGroup.theme.js +31 -0
- package/dist/runtime/app/components/{forms → FieldRadio/internal/RadioGroup}/RadioGroup.vue +7 -4
- package/dist/runtime/app/components/{forms → FieldRadio/internal/RadioGroup}/RadioGroup.vue.d.ts +10 -8
- package/dist/runtime/app/components/FieldSearch/FieldSearch.d.vue.ts +17 -0
- package/dist/runtime/app/components/FieldSearch/FieldSearch.theme.d.ts +6 -0
- package/dist/runtime/app/components/FieldSearch/FieldSearch.theme.js +7 -0
- package/dist/runtime/app/components/FieldSearch/FieldSearch.vue +74 -0
- package/dist/runtime/app/components/FieldSearch/FieldSearch.vue.d.ts +17 -0
- package/dist/runtime/app/components/FieldSelect/FieldSelect.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldSelect/FieldSelect.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldSelect/FieldSelect.theme.js +2 -0
- package/dist/runtime/app/components/FieldSelect/FieldSelect.vue +45 -0
- package/dist/runtime/app/components/FieldSelect/FieldSelect.vue.d.ts +13 -0
- package/dist/runtime/app/components/FieldSelect/internal/Select/Select.d.vue.ts +97 -0
- package/dist/runtime/app/components/FieldSelect/internal/Select/Select.theme.d.ts +36 -0
- package/dist/runtime/app/components/FieldSelect/internal/Select/Select.theme.js +49 -0
- package/dist/runtime/app/components/FieldSelect/internal/Select/Select.vue +196 -0
- package/dist/runtime/app/components/FieldSelect/internal/Select/Select.vue.d.ts +97 -0
- package/dist/runtime/app/{utils → components/FieldSelect/internal/Select}/option.d.ts +3 -4
- package/dist/runtime/app/components/FieldSelect/internal/Select/useVunoSelectState.d.ts +30 -0
- package/dist/runtime/app/components/FieldSelect/internal/Select/useVunoSelectState.js +142 -0
- package/dist/runtime/app/components/FieldSlug/FieldSlug.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldSlug/FieldSlug.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldSlug/FieldSlug.theme.js +2 -0
- package/dist/runtime/app/components/{forms/fields → FieldSlug}/FieldSlug.vue +58 -47
- package/dist/runtime/app/components/FieldSlug/FieldSlug.vue.d.ts +13 -0
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.theme.js +2 -0
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.vue +37 -0
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.vue.d.ts +13 -0
- package/dist/runtime/app/components/{forms → FieldSwitch/internal/Switch}/Switch.d.vue.ts +9 -4
- package/dist/runtime/app/components/FieldSwitch/internal/Switch/Switch.theme.d.ts +39 -0
- package/dist/runtime/app/components/FieldSwitch/internal/Switch/Switch.theme.js +20 -0
- package/dist/runtime/app/components/{forms → FieldSwitch/internal/Switch}/Switch.vue +4 -2
- package/dist/runtime/app/components/{forms → FieldSwitch/internal/Switch}/Switch.vue.d.ts +9 -4
- package/dist/runtime/app/components/FieldTags/FieldTags.d.vue.ts +13 -0
- package/dist/runtime/app/components/FieldTags/FieldTags.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldTags/FieldTags.theme.js +2 -0
- package/dist/runtime/app/components/FieldTags/FieldTags.vue +41 -0
- package/dist/runtime/app/components/FieldTags/FieldTags.vue.d.ts +13 -0
- package/dist/runtime/app/components/FieldTags/internal/TagsInput/TagsInput.d.vue.ts +26 -0
- package/dist/runtime/app/components/FieldTags/internal/TagsInput/TagsInput.theme.d.ts +34 -0
- package/dist/runtime/app/components/FieldTags/internal/TagsInput/TagsInput.theme.js +20 -0
- package/dist/runtime/app/components/FieldTags/internal/TagsInput/TagsInput.vue +97 -0
- package/dist/runtime/app/components/FieldTags/internal/TagsInput/TagsInput.vue.d.ts +26 -0
- package/dist/runtime/app/components/{forms/fields → FieldTextarea}/FieldTextarea.d.vue.ts +10 -2
- package/dist/runtime/app/components/FieldTextarea/FieldTextarea.theme.d.ts +5 -0
- package/dist/runtime/app/components/FieldTextarea/FieldTextarea.theme.js +2 -0
- package/dist/runtime/app/components/FieldTextarea/FieldTextarea.vue +45 -0
- package/dist/runtime/app/components/{forms/fields → FieldTextarea}/FieldTextarea.vue.d.ts +10 -2
- package/dist/runtime/app/components/{forms → FieldTextarea/internal/Textarea}/Textarea.d.vue.ts +9 -4
- package/dist/runtime/app/components/FieldTextarea/internal/Textarea/Textarea.theme.d.ts +36 -0
- package/dist/runtime/app/components/FieldTextarea/internal/Textarea/Textarea.theme.js +37 -0
- package/dist/runtime/app/components/{forms → FieldTextarea/internal/Textarea}/Textarea.vue +6 -4
- package/dist/runtime/app/components/{forms → FieldTextarea/internal/Textarea}/Textarea.vue.d.ts +9 -4
- package/dist/runtime/app/components/{forms → Form}/Form.d.vue.ts +3 -4
- package/dist/runtime/app/components/Form/Form.theme.d.ts +9 -0
- package/dist/runtime/app/components/Form/Form.theme.js +10 -0
- package/dist/runtime/app/components/{forms → Form}/Form.vue +7 -6
- package/dist/runtime/app/components/{forms → Form}/Form.vue.d.ts +3 -4
- package/dist/runtime/app/components/Form/internal/FormFieldRenderer/FormFieldRenderer.d.vue.ts +7 -0
- package/dist/runtime/app/components/Form/internal/FormFieldRenderer/FormFieldRenderer.vue +67 -0
- package/dist/runtime/app/components/Form/internal/FormFieldRenderer/FormFieldRenderer.vue.d.ts +7 -0
- package/dist/runtime/app/components/Form/internal/standard-schema.d.ts +29 -0
- package/dist/runtime/app/{internal → components/Form/internal}/useVunoFormState.d.ts +5 -3
- package/dist/runtime/app/{internal → components/Form/internal}/useVunoFormState.js +4 -3
- package/dist/runtime/app/components/{forms → FormField}/FormField.d.vue.ts +7 -4
- package/dist/runtime/app/components/FormField/FormField.theme.d.ts +62 -0
- package/dist/runtime/app/components/FormField/FormField.theme.js +28 -0
- package/dist/runtime/app/components/{forms → FormField}/FormField.vue +61 -42
- package/dist/runtime/app/components/{forms → FormField}/FormField.vue.d.ts +7 -4
- package/dist/runtime/app/components/{forms → FormModal}/FormModal.d.vue.ts +9 -7
- package/dist/runtime/app/components/FormModal/FormModal.theme.d.ts +8 -0
- package/dist/runtime/app/components/FormModal/FormModal.theme.js +9 -0
- package/dist/runtime/app/components/{forms → FormModal}/FormModal.vue +15 -12
- package/dist/runtime/app/components/{forms → FormModal}/FormModal.vue.d.ts +9 -7
- package/dist/runtime/app/components/FormSection/FormSection.d.vue.ts +15 -0
- package/dist/runtime/app/components/FormSection/FormSection.theme.d.ts +12 -0
- package/dist/runtime/app/components/FormSection/FormSection.theme.js +14 -0
- package/dist/runtime/app/components/{forms → FormSection}/FormSection.vue +5 -3
- package/dist/runtime/app/components/FormSection/FormSection.vue.d.ts +15 -0
- package/dist/runtime/app/components/Icon/Icon.d.vue.ts +6 -0
- package/dist/runtime/app/components/Icon/Icon.vue +32 -0
- package/dist/runtime/app/components/Icon/Icon.vue.d.ts +6 -0
- package/dist/runtime/app/components/{actions → Menu}/Menu.d.vue.ts +6 -4
- package/dist/runtime/app/components/Menu/Menu.theme.d.ts +17 -0
- package/dist/runtime/app/components/Menu/Menu.theme.js +20 -0
- package/dist/runtime/app/components/{actions → Menu}/Menu.vue +20 -27
- package/dist/runtime/app/components/{actions → Menu}/Menu.vue.d.ts +6 -4
- package/dist/runtime/app/components/Modal/Modal.d.vue.ts +43 -0
- package/dist/runtime/app/components/Modal/Modal.theme.d.ts +59 -0
- package/dist/runtime/app/components/Modal/Modal.theme.js +47 -0
- package/dist/runtime/app/components/{overlays → Modal}/Modal.vue +89 -32
- package/dist/runtime/app/components/Modal/Modal.vue.d.ts +43 -0
- package/dist/runtime/app/components/{structure → Navbar}/Navbar.d.vue.ts +14 -18
- package/dist/runtime/app/components/Navbar/Navbar.theme.d.ts +31 -0
- package/dist/runtime/app/components/Navbar/Navbar.theme.js +32 -0
- package/dist/runtime/app/components/{structure → Navbar}/Navbar.vue +1 -0
- package/dist/runtime/app/components/{structure → Navbar}/Navbar.vue.d.ts +14 -18
- package/dist/runtime/app/components/NavigationList/NavigationList.d.vue.ts +38 -0
- package/dist/runtime/app/components/NavigationList/NavigationList.theme.d.ts +32 -0
- package/dist/runtime/app/components/NavigationList/NavigationList.theme.js +35 -0
- package/dist/runtime/app/components/{structure/Navigation.vue → NavigationList/NavigationList.vue} +74 -34
- package/dist/runtime/app/components/NavigationList/NavigationList.vue.d.ts +38 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.d.vue.ts +31 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.theme.d.ts +26 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.theme.js +27 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.vue +236 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.vue.d.ts +31 -0
- package/dist/runtime/app/components/NavigationToc/NavigationToc.d.vue.ts +14 -0
- package/dist/runtime/app/components/NavigationToc/NavigationToc.theme.d.ts +9 -0
- package/dist/runtime/app/components/NavigationToc/NavigationToc.theme.js +10 -0
- package/dist/runtime/app/components/NavigationToc/NavigationToc.vue +81 -0
- package/dist/runtime/app/components/NavigationToc/NavigationToc.vue.d.ts +14 -0
- package/dist/runtime/app/components/{structure → Page}/Page.d.vue.ts +6 -5
- package/dist/runtime/app/components/Page/Page.theme.d.ts +32 -0
- package/dist/runtime/app/components/Page/Page.theme.js +31 -0
- package/dist/runtime/app/components/{structure → Page}/Page.vue +11 -3
- package/dist/runtime/app/components/{structure → Page}/Page.vue.d.ts +6 -5
- package/dist/runtime/app/components/{structure → Pagination}/Pagination.d.vue.ts +8 -7
- package/dist/runtime/app/components/Pagination/Pagination.theme.d.ts +13 -0
- package/dist/runtime/app/components/Pagination/Pagination.theme.js +14 -0
- package/dist/runtime/app/components/{structure → Pagination}/Pagination.vue +4 -2
- package/dist/runtime/app/components/{structure → Pagination}/Pagination.vue.d.ts +8 -7
- package/dist/runtime/app/components/{overlays/Modal.d.vue.ts → Slideover/Slideover.d.vue.ts} +10 -18
- package/dist/runtime/app/components/Slideover/Slideover.theme.d.ts +35 -0
- package/dist/runtime/app/components/Slideover/Slideover.theme.js +24 -0
- package/dist/runtime/app/components/Slideover/Slideover.vue +58 -0
- package/dist/runtime/app/components/{overlays/Modal.vue.d.ts → Slideover/Slideover.vue.d.ts} +10 -18
- package/dist/runtime/app/components/State/State.theme.d.ts +19 -0
- package/dist/runtime/app/components/State/State.theme.js +26 -0
- package/dist/runtime/app/components/{structure → State}/State.vue +8 -3
- package/dist/runtime/app/components/{structure → Table}/Table.d.vue.ts +5 -2
- package/dist/runtime/app/components/Table/Table.theme.d.ts +50 -0
- package/dist/runtime/app/components/Table/Table.theme.js +64 -0
- package/dist/runtime/app/components/{structure → Table}/Table.vue +62 -72
- package/dist/runtime/app/components/{structure → Table}/Table.vue.d.ts +5 -2
- package/dist/runtime/app/components/{structure/cells → Table/internal/CellBadge}/CellBadge.vue +2 -1
- package/dist/runtime/app/components/Table/internal/CellBoolean/CellBoolean.theme.d.ts +21 -0
- package/dist/runtime/app/components/Table/internal/CellBoolean/CellBoolean.theme.js +11 -0
- package/dist/runtime/app/components/Table/internal/CellBoolean/CellBoolean.vue +32 -0
- package/dist/runtime/app/components/Table/internal/CellCurrency/CellCurrency.theme.d.ts +5 -0
- package/dist/runtime/app/components/Table/internal/CellCurrency/CellCurrency.theme.js +4 -0
- package/dist/runtime/app/components/{structure/cells → Table/internal/CellCurrency}/CellCurrency.vue +1 -0
- package/dist/runtime/app/components/Table/internal/CellDate/CellDate.theme.d.ts +5 -0
- package/dist/runtime/app/components/Table/internal/CellDate/CellDate.theme.js +4 -0
- package/dist/runtime/app/components/{structure/cells → Table/internal/CellDate}/CellDate.vue +1 -0
- package/dist/runtime/app/components/{structure/cells → Table/internal/CellImage}/CellImage.vue +2 -1
- package/dist/runtime/app/components/Table/internal/CellNumber/CellNumber.theme.d.ts +5 -0
- package/dist/runtime/app/components/Table/internal/CellNumber/CellNumber.theme.js +4 -0
- package/dist/runtime/app/components/{structure/cells → Table/internal/CellNumber}/CellNumber.vue +1 -0
- package/dist/runtime/app/components/Table/internal/CellText/CellText.theme.d.ts +13 -0
- package/dist/runtime/app/components/Table/internal/CellText/CellText.theme.js +11 -0
- package/dist/runtime/app/components/{structure/cells → Table/internal/CellText}/CellText.vue +1 -0
- package/dist/runtime/app/components/{structure → Table/internal/TableCell}/TableCell.vue +9 -8
- package/dist/runtime/app/{utils → components/Table/internal}/column.js +1 -1
- package/dist/runtime/app/{internal → components/Table/internal}/useVunoTable.d.ts +23 -22
- package/dist/runtime/app/{internal → components/Table/internal}/useVunoTable.js +1 -1
- package/dist/runtime/app/components/Table/internal/useVunoTableSelection.d.ts +21 -0
- package/dist/runtime/app/components/Table/internal/useVunoTableSelection.js +29 -0
- package/dist/runtime/app/components/{structure → Tabs}/Tabs.d.vue.ts +8 -7
- package/dist/runtime/app/components/Tabs/Tabs.theme.d.ts +32 -0
- package/dist/runtime/app/components/Tabs/Tabs.theme.js +23 -0
- package/dist/runtime/app/components/{structure → Tabs}/Tabs.vue +13 -8
- package/dist/runtime/app/components/{structure → Tabs}/Tabs.vue.d.ts +8 -7
- package/dist/runtime/app/components/{actions → Tooltip}/Tooltip.d.vue.ts +6 -6
- package/dist/runtime/app/components/Tooltip/Tooltip.theme.d.ts +12 -0
- package/dist/runtime/app/components/Tooltip/Tooltip.theme.js +13 -0
- package/dist/runtime/app/components/{actions → Tooltip}/Tooltip.vue +10 -23
- package/dist/runtime/app/components/{actions → Tooltip}/Tooltip.vue.d.ts +6 -6
- package/dist/runtime/app/components/{forms → internal/ControlShell}/ControlShell.d.vue.ts +9 -5
- package/dist/runtime/app/components/internal/ControlShell/ControlShell.theme.d.ts +50 -0
- package/dist/runtime/app/components/internal/ControlShell/ControlShell.theme.js +38 -0
- package/dist/runtime/app/components/internal/ControlShell/ControlShell.vue +33 -0
- package/dist/runtime/app/components/{forms → internal/ControlShell}/ControlShell.vue.d.ts +9 -5
- package/dist/runtime/app/components/internal/FieldShell/FieldShell.d.vue.ts +23 -0
- package/dist/runtime/app/components/internal/FieldShell/FieldShell.vue +63 -0
- package/dist/runtime/app/components/internal/FieldShell/FieldShell.vue.d.ts +23 -0
- package/dist/runtime/app/components/{forms → internal/Input}/Input.d.vue.ts +15 -10
- package/dist/runtime/app/components/internal/Input/Input.theme.d.ts +30 -0
- package/dist/runtime/app/components/internal/Input/Input.theme.js +21 -0
- package/dist/runtime/app/components/{forms → internal/Input}/Input.vue +8 -6
- package/dist/runtime/app/components/{forms → internal/Input}/Input.vue.d.ts +15 -10
- package/dist/runtime/app/components/{forms → internal/NumberInput}/NumberInput.d.vue.ts +14 -8
- package/dist/runtime/app/components/internal/NumberInput/NumberInput.theme.d.ts +31 -0
- package/dist/runtime/app/components/internal/NumberInput/NumberInput.theme.js +26 -0
- package/dist/runtime/app/components/internal/NumberInput/NumberInput.vue +221 -0
- package/dist/runtime/app/components/{forms → internal/NumberInput}/NumberInput.vue.d.ts +14 -8
- package/dist/runtime/app/{utils → components/internal/NumberInput}/number.d.ts +7 -0
- package/dist/runtime/app/components/internal/NumberInput/number.js +64 -0
- package/dist/runtime/app/composables/defineShortcuts.d.ts +19 -0
- package/dist/runtime/app/composables/defineShortcuts.js +68 -0
- package/dist/runtime/app/{internal → composables/internal}/useVunoAnchor.d.ts +6 -4
- package/dist/runtime/app/{internal → composables/internal}/useVunoAnchor.js +3 -2
- package/dist/runtime/app/composables/internal/useVunoControlGroup.d.ts +17 -0
- package/dist/runtime/app/composables/internal/useVunoControlGroup.js +18 -0
- package/dist/runtime/app/{internal → composables/internal}/useVunoPortal.d.ts +3 -8
- package/dist/runtime/app/composables/internal/useVunoPortal.js +12 -0
- package/dist/runtime/app/composables/useCrud.js +5 -4
- package/dist/runtime/app/composables/useField.d.ts +3 -3
- package/dist/runtime/app/composables/useField.js +16 -8
- package/dist/runtime/app/composables/useForm.d.ts +3 -0
- package/dist/runtime/app/composables/useForm.js +2 -2
- package/dist/runtime/app/composables/useModal.js +1 -3
- package/dist/runtime/app/composables/useTableQuery.js +29 -13
- package/dist/runtime/app/composables/useTheme.d.ts +3 -2
- package/dist/runtime/app/composables/useTheme.js +4 -2
- package/dist/runtime/app/internal/keys.d.ts +11 -5
- package/dist/runtime/app/internal/keys.js +5 -2
- package/dist/runtime/app/internal/slots.d.ts +3 -0
- package/dist/runtime/app/internal/slots.js +13 -1
- package/dist/runtime/app/plugins/vue-query.d.ts +8 -0
- package/dist/runtime/app/plugins/vue-query.js +13 -0
- package/dist/runtime/app/theme/icons.js +4 -1
- package/dist/runtime/app/theme/index.d.ts +1158 -4
- package/dist/runtime/app/theme/index.js +116 -10
- package/dist/runtime/app/theme/messages.js +10 -3
- package/dist/runtime/app/theme/shared.d.ts +19 -3
- package/dist/runtime/app/theme/shared.js +15 -1
- package/dist/runtime/app/types/alert.d.ts +13 -0
- package/dist/runtime/app/types/base.d.ts +19 -1
- package/dist/runtime/app/types/field-type.d.ts +4 -0
- package/dist/runtime/app/types/field-type.js +0 -0
- package/dist/runtime/app/types/field.d.ts +132 -26
- package/dist/runtime/app/types/form.d.ts +27 -1
- package/dist/runtime/app/types/index.d.ts +15 -12
- package/dist/runtime/app/types/page.d.ts +9 -1
- package/dist/runtime/app/types/shortcuts.d.ts +44 -0
- package/dist/runtime/app/types/shortcuts.js +0 -0
- package/dist/runtime/app/types/slots.d.ts +30 -0
- package/dist/runtime/app/types/slots.js +0 -0
- package/dist/runtime/app/types/state.d.ts +3 -3
- package/dist/runtime/app/types/table.d.ts +3 -2
- package/dist/runtime/app/types/theme.d.ts +51 -13
- package/dist/runtime/app/utils/format.js +2 -2
- package/dist/runtime/app/utils/path.js +4 -2
- package/dist/runtime/app/utils/theme.d.ts +19 -1
- package/dist/runtime/app/utils/theme.js +21 -3
- package/package.json +18 -3
- package/dist/runtime/app/components/actions/Icon.d.vue.ts +0 -6
- package/dist/runtime/app/components/actions/Icon.vue +0 -32
- package/dist/runtime/app/components/actions/Icon.vue.d.ts +0 -6
- package/dist/runtime/app/components/forms/ControlShell.vue +0 -19
- package/dist/runtime/app/components/forms/FormFieldRenderer.d.vue.ts +0 -7
- package/dist/runtime/app/components/forms/FormFieldRenderer.vue +0 -88
- package/dist/runtime/app/components/forms/FormFieldRenderer.vue.d.ts +0 -7
- package/dist/runtime/app/components/forms/FormSection.d.vue.ts +0 -12
- package/dist/runtime/app/components/forms/FormSection.vue.d.ts +0 -12
- package/dist/runtime/app/components/forms/NumberInput.vue +0 -160
- package/dist/runtime/app/components/forms/Select.d.vue.ts +0 -61
- package/dist/runtime/app/components/forms/Select.vue +0 -336
- package/dist/runtime/app/components/forms/Select.vue.d.ts +0 -61
- package/dist/runtime/app/components/forms/fields/FieldArray.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldArray.vue +0 -129
- package/dist/runtime/app/components/forms/fields/FieldArray.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldCheckbox.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldCheckbox.vue +0 -31
- package/dist/runtime/app/components/forms/fields/FieldCheckbox.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldColor.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldColor.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldEmail.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldEmail.vue +0 -38
- package/dist/runtime/app/components/forms/fields/FieldEmail.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldFile.vue +0 -91
- package/dist/runtime/app/components/forms/fields/FieldNumber.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldNumber.vue +0 -39
- package/dist/runtime/app/components/forms/fields/FieldNumber.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldPassword.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldPassword.vue +0 -36
- package/dist/runtime/app/components/forms/fields/FieldPassword.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldRadio.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldRadio.vue +0 -33
- package/dist/runtime/app/components/forms/fields/FieldRadio.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldSelect.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldSelect.vue +0 -37
- package/dist/runtime/app/components/forms/fields/FieldSelect.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldSlug.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldSlug.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldSwitch.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldSwitch.vue +0 -29
- package/dist/runtime/app/components/forms/fields/FieldSwitch.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldText.d.vue.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldText.vue +0 -39
- package/dist/runtime/app/components/forms/fields/FieldText.vue.d.ts +0 -5
- package/dist/runtime/app/components/forms/fields/FieldTextarea.vue +0 -37
- package/dist/runtime/app/components/layouts/dashboard/DashboardAside.d.vue.ts +0 -56
- package/dist/runtime/app/components/layouts/dashboard/DashboardAside.vue +0 -96
- package/dist/runtime/app/components/layouts/dashboard/DashboardAside.vue.d.ts +0 -56
- package/dist/runtime/app/components/layouts/dashboard/DashboardLayout.d.vue.ts +0 -57
- package/dist/runtime/app/components/layouts/dashboard/DashboardLayout.vue +0 -164
- package/dist/runtime/app/components/layouts/dashboard/DashboardLayout.vue.d.ts +0 -57
- package/dist/runtime/app/components/layouts/dashboard/DashboardPage.d.vue.ts +0 -49
- package/dist/runtime/app/components/layouts/dashboard/DashboardPage.vue +0 -45
- package/dist/runtime/app/components/layouts/dashboard/DashboardPage.vue.d.ts +0 -49
- package/dist/runtime/app/components/layouts/public/PublicLayout.d.vue.ts +0 -50
- package/dist/runtime/app/components/layouts/public/PublicLayout.vue +0 -56
- package/dist/runtime/app/components/layouts/public/PublicLayout.vue.d.ts +0 -50
- package/dist/runtime/app/components/overlays/Context.d.vue.ts +0 -3
- package/dist/runtime/app/components/overlays/Context.vue +0 -7
- package/dist/runtime/app/components/overlays/Context.vue.d.ts +0 -3
- package/dist/runtime/app/components/overlays/Overlay.d.vue.ts +0 -7
- package/dist/runtime/app/components/overlays/Overlay.vue.d.ts +0 -7
- package/dist/runtime/app/components/structure/Navigation.d.vue.ts +0 -14
- package/dist/runtime/app/components/structure/Navigation.vue.d.ts +0 -14
- package/dist/runtime/app/components/structure/cells/CellBoolean.vue +0 -26
- package/dist/runtime/app/composables/useDashboard.d.ts +0 -14
- package/dist/runtime/app/composables/useDashboard.js +0 -9
- package/dist/runtime/app/internal/useVunoDashboard.d.ts +0 -15
- package/dist/runtime/app/internal/useVunoDashboard.js +0 -5
- package/dist/runtime/app/internal/useVunoPortal.js +0 -8
- package/dist/runtime/app/theme/actions.d.ts +0 -2
- package/dist/runtime/app/theme/actions.js +0 -123
- package/dist/runtime/app/theme/forms.d.ts +0 -2
- package/dist/runtime/app/theme/forms.js +0 -442
- package/dist/runtime/app/theme/layouts.d.ts +0 -2
- package/dist/runtime/app/theme/layouts.js +0 -76
- package/dist/runtime/app/theme/overlays.d.ts +0 -2
- package/dist/runtime/app/theme/overlays.js +0 -90
- package/dist/runtime/app/theme/structure.d.ts +0 -2
- package/dist/runtime/app/theme/structure.js +0 -351
- package/dist/runtime/app/types/dashboard.d.ts +0 -7
- package/dist/runtime/app/utils/number.js +0 -30
- package/dist/runtime/app/utils/standard-schema.d.ts +0 -62
- /package/dist/runtime/app/{utils → components/FieldSelect/internal/Select}/option.js +0 -0
- /package/dist/runtime/app/{utils → components/Form/internal}/grid.d.ts +0 -0
- /package/dist/runtime/app/{utils → components/Form/internal}/grid.js +0 -0
- /package/dist/runtime/app/{utils → components/Form/internal}/standard-schema.js +0 -0
- /package/dist/runtime/app/components/{structure → State}/State.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure → State}/State.vue.d.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellBadge}/CellBadge.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellBadge}/CellBadge.vue.d.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellBoolean}/CellBoolean.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellBoolean}/CellBoolean.vue.d.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellCurrency}/CellCurrency.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellCurrency}/CellCurrency.vue.d.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellDate}/CellDate.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellDate}/CellDate.vue.d.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellImage}/CellImage.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellImage}/CellImage.vue.d.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellNumber}/CellNumber.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellNumber}/CellNumber.vue.d.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellText}/CellText.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure/cells → Table/internal/CellText}/CellText.vue.d.ts +0 -0
- /package/dist/runtime/app/components/{structure → Table/internal/TableCell}/TableCell.d.vue.ts +0 -0
- /package/dist/runtime/app/components/{structure → Table/internal/TableCell}/TableCell.vue.d.ts +0 -0
- /package/dist/runtime/app/{utils → components/Table/internal}/column.d.ts +0 -0
- /package/dist/runtime/app/{utils → components/Table/internal}/query.d.ts +0 -0
- /package/dist/runtime/app/{utils → components/Table/internal}/query.js +0 -0
- /package/dist/runtime/app/{utils → components/Table/internal}/selection.d.ts +0 -0
- /package/dist/runtime/app/{utils → components/Table/internal}/selection.js +0 -0
- /package/dist/runtime/app/types/{dashboard.js → alert.js} +0 -0
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { useField } from "#vuno/composables/useField";
|
|
3
|
+
import { useTheme } from "#vuno/composables/useTheme";
|
|
4
|
+
import Switch from "#vuno/components/FieldSwitch/internal/Switch/Switch.vue";
|
|
5
|
+
import FieldShell from "#vuno/components/internal/FieldShell/FieldShell.vue";
|
|
6
|
+
defineOptions({ name: "VunoFieldSwitch" });
|
|
7
|
+
const model = defineModel({ type: Boolean });
|
|
8
|
+
const props = defineProps({
|
|
9
|
+
name: { type: String, required: false },
|
|
10
|
+
class: { type: String, required: false },
|
|
11
|
+
description: { type: String, required: false },
|
|
12
|
+
disabled: { type: Boolean, required: false },
|
|
13
|
+
error: { type: String, required: false },
|
|
14
|
+
help: { type: String, required: false },
|
|
15
|
+
hint: { type: String, required: false },
|
|
16
|
+
label: { type: String, required: false },
|
|
17
|
+
orientation: { type: String, required: false },
|
|
18
|
+
required: { type: Boolean, required: false },
|
|
19
|
+
size: { type: String, required: false },
|
|
20
|
+
ui: { type: Object, required: false }
|
|
21
|
+
});
|
|
22
|
+
const { value } = useField(() => props.name, model);
|
|
23
|
+
const ui = useTheme("fieldSwitch", () => props.ui);
|
|
24
|
+
</script>
|
|
25
|
+
|
|
26
|
+
<template>
|
|
27
|
+
<FieldShell v-bind="props">
|
|
28
|
+
<template #default="control">
|
|
29
|
+
<Switch
|
|
30
|
+
v-bind="control"
|
|
31
|
+
v-model="value"
|
|
32
|
+
:disabled="props.disabled"
|
|
33
|
+
:ui="ui"
|
|
34
|
+
/>
|
|
35
|
+
</template>
|
|
36
|
+
</FieldShell>
|
|
37
|
+
</template>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { VunoFieldSwitch } from '#vuno/types/field';
|
|
2
|
+
type __VLS_Props = Omit<VunoFieldSwitch, 'columns'>;
|
|
3
|
+
type __VLS_ModelProps = {
|
|
4
|
+
modelValue?: boolean;
|
|
5
|
+
};
|
|
6
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
7
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
8
|
+
"update:modelValue": (value: boolean | undefined) => any;
|
|
9
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
10
|
+
"onUpdate:modelValue"?: ((value: boolean | undefined) => any) | undefined;
|
|
11
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
declare const _default: typeof __VLS_export;
|
|
13
|
+
export default _default;
|
|
@@ -1,8 +1,12 @@
|
|
|
1
|
-
import type { VunoColor,
|
|
2
|
-
type
|
|
1
|
+
import type { VunoColor, VunoRadius, VunoSize } from '#vuno/types/base';
|
|
2
|
+
import type { VunoUi } from '#vuno/types/slots';
|
|
3
|
+
type __VLS_Props = Props;
|
|
4
|
+
type Props = {
|
|
3
5
|
color?: VunoColor;
|
|
6
|
+
/** La curvatura. Sin valor, la que traiga el tema. */
|
|
7
|
+
radius?: VunoRadius;
|
|
4
8
|
size?: VunoSize;
|
|
5
|
-
ui?:
|
|
9
|
+
ui?: VunoUi<'fieldSwitch' | 'switch'>;
|
|
6
10
|
};
|
|
7
11
|
type __VLS_ModelProps = {
|
|
8
12
|
modelValue?: boolean | undefined;
|
|
@@ -14,8 +18,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
14
18
|
"onUpdate:modelValue"?: ((value: boolean | undefined) => any) | undefined;
|
|
15
19
|
}>, {
|
|
16
20
|
color: VunoColor;
|
|
21
|
+
radius: VunoRadius;
|
|
17
22
|
size: VunoSize;
|
|
18
|
-
ui:
|
|
23
|
+
ui: VunoUi<"fieldSwitch" | "switch">;
|
|
19
24
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
20
25
|
declare const _default: typeof __VLS_export;
|
|
21
26
|
export default _default;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* El interruptor. La pista es el propio `<input>` y el círculo un hermano
|
|
3
|
+
* que se desplaza con `peer-checked`, así que el recorrido de cada tamaño
|
|
4
|
+
* es el ancho menos el círculo menos sus dos márgenes: con otro número el
|
|
5
|
+
* círculo se sale o se queda corto, y no hay forma de deducirlo leyendo.
|
|
6
|
+
*/
|
|
7
|
+
export declare const switchTheme: Record<"switch", {
|
|
8
|
+
readonly slots: {
|
|
9
|
+
readonly base: "peer absolute inset-0 m-0 size-full cursor-pointer appearance-none rounded-full border border-vuno-border-strong bg-vuno-surface-2 transition-[background-color,border-color] checked:border-(--vuno-accent) checked:bg-(--vuno-accent) focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-(--vuno-accent) enabled:hover:border-(--vuno-accent) disabled:cursor-not-allowed motion-reduce:transition-none";
|
|
10
|
+
readonly root: "relative inline-flex shrink-0 items-center transition-opacity has-disabled:opacity-50 motion-reduce:transition-none";
|
|
11
|
+
readonly thumb: "pointer-events-none absolute top-1/2 left-0.5 -translate-y-1/2 rounded-full bg-vuno-surface transition-transform peer-active:scale-90 peer-disabled:scale-100 motion-reduce:transition-none";
|
|
12
|
+
};
|
|
13
|
+
readonly variants: {
|
|
14
|
+
readonly color: Record<import("../../../../types/base.js").VunoColor, Record<"base", string>>;
|
|
15
|
+
readonly radius: Record<import("../../../../types/base.js").VunoRadius, Record<"base" | "thumb", string>>;
|
|
16
|
+
readonly size: {
|
|
17
|
+
readonly xs: {
|
|
18
|
+
readonly root: "h-3.5 w-6";
|
|
19
|
+
readonly thumb: "size-2.5 peer-checked:translate-x-2.5";
|
|
20
|
+
};
|
|
21
|
+
readonly sm: {
|
|
22
|
+
readonly root: "h-4 w-7";
|
|
23
|
+
readonly thumb: "size-3 peer-checked:translate-x-3";
|
|
24
|
+
};
|
|
25
|
+
readonly md: {
|
|
26
|
+
readonly root: "h-5 w-9";
|
|
27
|
+
readonly thumb: "size-4 peer-checked:translate-x-4";
|
|
28
|
+
};
|
|
29
|
+
readonly lg: {
|
|
30
|
+
readonly root: "h-6 w-11";
|
|
31
|
+
readonly thumb: "size-5 peer-checked:translate-x-5";
|
|
32
|
+
};
|
|
33
|
+
readonly xl: {
|
|
34
|
+
readonly root: "h-7 w-12";
|
|
35
|
+
readonly thumb: "size-6 peer-checked:translate-x-5";
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
}>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { accentByColor, radiusByStep } from "#vuno/theme/shared";
|
|
2
|
+
import { defineTheme } from "#vuno/utils/theme";
|
|
3
|
+
export const switchTheme = defineTheme("switch", {
|
|
4
|
+
slots: {
|
|
5
|
+
base: "peer absolute inset-0 m-0 size-full cursor-pointer appearance-none rounded-full border border-vuno-border-strong bg-vuno-surface-2 transition-[background-color,border-color] checked:border-(--vuno-accent) checked:bg-(--vuno-accent) focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-(--vuno-accent) enabled:hover:border-(--vuno-accent) disabled:cursor-not-allowed motion-reduce:transition-none",
|
|
6
|
+
root: "relative inline-flex shrink-0 items-center transition-opacity has-disabled:opacity-50 motion-reduce:transition-none",
|
|
7
|
+
thumb: "pointer-events-none absolute top-1/2 left-0.5 -translate-y-1/2 rounded-full bg-vuno-surface transition-transform peer-active:scale-90 peer-disabled:scale-100 motion-reduce:transition-none"
|
|
8
|
+
},
|
|
9
|
+
variants: {
|
|
10
|
+
color: accentByColor("base"),
|
|
11
|
+
radius: radiusByStep("base", "thumb"),
|
|
12
|
+
size: {
|
|
13
|
+
xs: { root: "h-3.5 w-6", thumb: "size-2.5 peer-checked:translate-x-2.5" },
|
|
14
|
+
sm: { root: "h-4 w-7", thumb: "size-3 peer-checked:translate-x-3" },
|
|
15
|
+
md: { root: "h-5 w-9", thumb: "size-4 peer-checked:translate-x-4" },
|
|
16
|
+
lg: { root: "h-6 w-11", thumb: "size-5 peer-checked:translate-x-5" },
|
|
17
|
+
xl: { root: "h-7 w-12", thumb: "size-6 peer-checked:translate-x-5" }
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
});
|
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
import { useTheme } from "#vuno/composables/useTheme";
|
|
3
|
-
defineOptions({ inheritAttrs: false });
|
|
3
|
+
defineOptions({ name: "VunoSwitch", inheritAttrs: false });
|
|
4
|
+
const model = defineModel({ type: Boolean, skipCheck: true, ...{ default: void 0 } });
|
|
4
5
|
const props = defineProps({
|
|
5
6
|
color: { type: String, required: false, default: "primary" },
|
|
7
|
+
radius: { type: String, required: false, default: void 0 },
|
|
6
8
|
size: { type: String, required: false, default: "md" },
|
|
7
9
|
ui: { type: Object, required: false, default: void 0 }
|
|
8
10
|
});
|
|
9
|
-
const model = defineModel({ type: Boolean, skipCheck: true, ...{ default: void 0 } });
|
|
10
11
|
const ui = useTheme(
|
|
11
12
|
"switch",
|
|
12
13
|
() => props.ui,
|
|
13
14
|
() => ({
|
|
14
15
|
color: props.color,
|
|
16
|
+
radius: props.radius,
|
|
15
17
|
size: props.size
|
|
16
18
|
})
|
|
17
19
|
);
|
|
@@ -1,8 +1,12 @@
|
|
|
1
|
-
import type { VunoColor,
|
|
2
|
-
type
|
|
1
|
+
import type { VunoColor, VunoRadius, VunoSize } from '#vuno/types/base';
|
|
2
|
+
import type { VunoUi } from '#vuno/types/slots';
|
|
3
|
+
type __VLS_Props = Props;
|
|
4
|
+
type Props = {
|
|
3
5
|
color?: VunoColor;
|
|
6
|
+
/** La curvatura. Sin valor, la que traiga el tema. */
|
|
7
|
+
radius?: VunoRadius;
|
|
4
8
|
size?: VunoSize;
|
|
5
|
-
ui?:
|
|
9
|
+
ui?: VunoUi<'fieldSwitch' | 'switch'>;
|
|
6
10
|
};
|
|
7
11
|
type __VLS_ModelProps = {
|
|
8
12
|
modelValue?: boolean | undefined;
|
|
@@ -14,8 +18,9 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
14
18
|
"onUpdate:modelValue"?: ((value: boolean | undefined) => any) | undefined;
|
|
15
19
|
}>, {
|
|
16
20
|
color: VunoColor;
|
|
21
|
+
radius: VunoRadius;
|
|
17
22
|
size: VunoSize;
|
|
18
|
-
ui:
|
|
23
|
+
ui: VunoUi<"fieldSwitch" | "switch">;
|
|
19
24
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
20
25
|
declare const _default: typeof __VLS_export;
|
|
21
26
|
export default _default;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { VunoFieldTags } from '#vuno/types/field';
|
|
2
|
+
type __VLS_Props = Omit<VunoFieldTags, 'columns'>;
|
|
3
|
+
type __VLS_ModelProps = {
|
|
4
|
+
modelValue?: string[] | undefined;
|
|
5
|
+
};
|
|
6
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
7
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
8
|
+
"update:modelValue": (value: string[] | undefined) => any;
|
|
9
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
10
|
+
"onUpdate:modelValue"?: ((value: string[] | undefined) => any) | undefined;
|
|
11
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
declare const _default: typeof __VLS_export;
|
|
13
|
+
export default _default;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { useField } from "#vuno/composables/useField";
|
|
3
|
+
import { useTheme } from "#vuno/composables/useTheme";
|
|
4
|
+
import TagsInput from "#vuno/components/FieldTags/internal/TagsInput/TagsInput.vue";
|
|
5
|
+
import FieldShell from "#vuno/components/internal/FieldShell/FieldShell.vue";
|
|
6
|
+
defineOptions({ name: "VunoFieldTags" });
|
|
7
|
+
const model = defineModel({ type: null, ...{ default: void 0 } });
|
|
8
|
+
const props = defineProps({
|
|
9
|
+
name: { type: String, required: false },
|
|
10
|
+
class: { type: String, required: false },
|
|
11
|
+
description: { type: String, required: false },
|
|
12
|
+
disabled: { type: Boolean, required: false },
|
|
13
|
+
error: { type: String, required: false },
|
|
14
|
+
help: { type: String, required: false },
|
|
15
|
+
hint: { type: String, required: false },
|
|
16
|
+
label: { type: String, required: false },
|
|
17
|
+
orientation: { type: String, required: false },
|
|
18
|
+
required: { type: Boolean, required: false },
|
|
19
|
+
size: { type: String, required: false },
|
|
20
|
+
ui: { type: Object, required: false },
|
|
21
|
+
max: { type: Number, required: false },
|
|
22
|
+
placeholder: { type: String, required: false }
|
|
23
|
+
});
|
|
24
|
+
const { value } = useField(() => props.name, model);
|
|
25
|
+
const ui = useTheme("fieldTags", () => props.ui);
|
|
26
|
+
</script>
|
|
27
|
+
|
|
28
|
+
<template>
|
|
29
|
+
<FieldShell v-bind="props">
|
|
30
|
+
<template #default="control">
|
|
31
|
+
<TagsInput
|
|
32
|
+
v-bind="control"
|
|
33
|
+
v-model="value"
|
|
34
|
+
:disabled="props.disabled"
|
|
35
|
+
:max="props.max"
|
|
36
|
+
:placeholder="props.placeholder"
|
|
37
|
+
:ui="ui"
|
|
38
|
+
/>
|
|
39
|
+
</template>
|
|
40
|
+
</FieldShell>
|
|
41
|
+
</template>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { VunoFieldTags } from '#vuno/types/field';
|
|
2
|
+
type __VLS_Props = Omit<VunoFieldTags, 'columns'>;
|
|
3
|
+
type __VLS_ModelProps = {
|
|
4
|
+
modelValue?: string[] | undefined;
|
|
5
|
+
};
|
|
6
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
7
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
8
|
+
"update:modelValue": (value: string[] | undefined) => any;
|
|
9
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
10
|
+
"onUpdate:modelValue"?: ((value: string[] | undefined) => any) | undefined;
|
|
11
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
declare const _default: typeof __VLS_export;
|
|
13
|
+
export default _default;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { VunoSize } from '#vuno/types/base';
|
|
2
|
+
import type { VunoUi } from '#vuno/types/slots';
|
|
3
|
+
type __VLS_Props = Props;
|
|
4
|
+
type Props = {
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
max?: number;
|
|
7
|
+
placeholder?: string;
|
|
8
|
+
size?: VunoSize;
|
|
9
|
+
ui?: VunoUi<'control' | 'tagsInput'>;
|
|
10
|
+
};
|
|
11
|
+
type __VLS_ModelProps = {
|
|
12
|
+
modelValue?: string[] | undefined;
|
|
13
|
+
};
|
|
14
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
15
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
16
|
+
"update:modelValue": (value: string[] | undefined) => any;
|
|
17
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
18
|
+
"onUpdate:modelValue"?: ((value: string[] | undefined) => any) | undefined;
|
|
19
|
+
}>, {
|
|
20
|
+
size: VunoSize;
|
|
21
|
+
ui: VunoUi<"control" | "tagsInput">;
|
|
22
|
+
placeholder: string;
|
|
23
|
+
max: number;
|
|
24
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
25
|
+
declare const _default: typeof __VLS_export;
|
|
26
|
+
export default _default;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
export declare const tagsInputTheme: Record<"tagsInput", {
|
|
2
|
+
readonly slots: {
|
|
3
|
+
readonly content: "flex min-w-0 flex-1 flex-wrap items-center gap-1 py-1";
|
|
4
|
+
readonly input: "min-w-24 flex-1 bg-transparent outline-none placeholder:text-vuno-subtle disabled:cursor-not-allowed";
|
|
5
|
+
readonly remove: "inline-flex shrink-0 items-center justify-center rounded-sm text-vuno-muted transition-colors hover:text-vuno-body focus-visible:outline-2 focus-visible:outline-offset-1 focus-visible:outline-(--vuno-accent) disabled:cursor-not-allowed";
|
|
6
|
+
readonly removeIcon: "size-3.5";
|
|
7
|
+
readonly tag: "inline-flex max-w-full items-center gap-0.5 rounded-sm bg-vuno-surface-2 px-1.5 text-vuno-body";
|
|
8
|
+
readonly tagLabel: "truncate";
|
|
9
|
+
};
|
|
10
|
+
readonly variants: {
|
|
11
|
+
readonly size: {
|
|
12
|
+
readonly xs: {
|
|
13
|
+
readonly input: "text-xs";
|
|
14
|
+
readonly tag: "text-xs";
|
|
15
|
+
};
|
|
16
|
+
readonly sm: {
|
|
17
|
+
readonly input: "text-sm";
|
|
18
|
+
readonly tag: "text-xs";
|
|
19
|
+
};
|
|
20
|
+
readonly md: {
|
|
21
|
+
readonly input: "text-sm";
|
|
22
|
+
readonly tag: "text-sm";
|
|
23
|
+
};
|
|
24
|
+
readonly lg: {
|
|
25
|
+
readonly input: "text-base";
|
|
26
|
+
readonly tag: "text-sm";
|
|
27
|
+
};
|
|
28
|
+
readonly xl: {
|
|
29
|
+
readonly input: "text-base";
|
|
30
|
+
readonly tag: "text-base";
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
}>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { defineTheme } from "#vuno/utils/theme";
|
|
2
|
+
export const tagsInputTheme = defineTheme("tagsInput", {
|
|
3
|
+
slots: {
|
|
4
|
+
content: "flex min-w-0 flex-1 flex-wrap items-center gap-1 py-1",
|
|
5
|
+
input: "min-w-24 flex-1 bg-transparent outline-none placeholder:text-vuno-subtle disabled:cursor-not-allowed",
|
|
6
|
+
remove: "inline-flex shrink-0 items-center justify-center rounded-sm text-vuno-muted transition-colors hover:text-vuno-body focus-visible:outline-2 focus-visible:outline-offset-1 focus-visible:outline-(--vuno-accent) disabled:cursor-not-allowed",
|
|
7
|
+
removeIcon: "size-3.5",
|
|
8
|
+
tag: "inline-flex max-w-full items-center gap-0.5 rounded-sm bg-vuno-surface-2 px-1.5 text-vuno-body",
|
|
9
|
+
tagLabel: "truncate"
|
|
10
|
+
},
|
|
11
|
+
variants: {
|
|
12
|
+
size: {
|
|
13
|
+
xs: { input: "text-xs", tag: "text-xs" },
|
|
14
|
+
sm: { input: "text-sm", tag: "text-xs" },
|
|
15
|
+
md: { input: "text-sm", tag: "text-sm" },
|
|
16
|
+
lg: { input: "text-base", tag: "text-sm" },
|
|
17
|
+
xl: { input: "text-base", tag: "text-base" }
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
});
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { computed, ref, useTemplateRef } from "vue";
|
|
3
|
+
import { useIcons, useMessages, useTheme } from "#vuno/composables/useTheme";
|
|
4
|
+
import Icon from "#vuno/components/Icon/Icon.vue";
|
|
5
|
+
import ControlShell from "#vuno/components/internal/ControlShell/ControlShell.vue";
|
|
6
|
+
defineOptions({ name: "VunoTagsInput", inheritAttrs: false });
|
|
7
|
+
const model = defineModel({ type: null, ...{ default: void 0 } });
|
|
8
|
+
const props = defineProps({
|
|
9
|
+
disabled: { type: Boolean, required: false },
|
|
10
|
+
max: { type: Number, required: false, default: void 0 },
|
|
11
|
+
placeholder: { type: String, required: false, default: void 0 },
|
|
12
|
+
size: { type: String, required: false, default: "md" },
|
|
13
|
+
ui: { type: Object, required: false, default: void 0 }
|
|
14
|
+
});
|
|
15
|
+
const icons = useIcons();
|
|
16
|
+
const messages = useMessages();
|
|
17
|
+
const ui = useTheme(
|
|
18
|
+
"tagsInput",
|
|
19
|
+
() => props.ui,
|
|
20
|
+
() => ({ size: props.size })
|
|
21
|
+
);
|
|
22
|
+
const draft = ref("");
|
|
23
|
+
const inputRef = useTemplateRef("input");
|
|
24
|
+
const tags = computed(() => model.value ?? []);
|
|
25
|
+
const canAdd = computed(() => props.max === void 0 || tags.value.length < props.max);
|
|
26
|
+
function add() {
|
|
27
|
+
const tag = draft.value.trim();
|
|
28
|
+
draft.value = "";
|
|
29
|
+
if (!tag || !canAdd.value || tags.value.includes(tag)) return;
|
|
30
|
+
model.value = [...tags.value, tag];
|
|
31
|
+
}
|
|
32
|
+
function remove(index) {
|
|
33
|
+
if (props.disabled) return;
|
|
34
|
+
model.value = tags.value.filter((_, position) => position !== index);
|
|
35
|
+
inputRef.value?.focus();
|
|
36
|
+
}
|
|
37
|
+
function onInput(event) {
|
|
38
|
+
draft.value = event.target.value;
|
|
39
|
+
}
|
|
40
|
+
function onKeydown(event) {
|
|
41
|
+
if (event.isComposing) return;
|
|
42
|
+
if ((event.key === "Enter" || event.key === ",") && draft.value.trim()) {
|
|
43
|
+
event.preventDefault();
|
|
44
|
+
add();
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
if (event.key === "Backspace" && !draft.value && tags.value.length > 0) {
|
|
48
|
+
event.preventDefault();
|
|
49
|
+
remove(tags.value.length - 1);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
</script>
|
|
53
|
+
|
|
54
|
+
<template>
|
|
55
|
+
<ControlShell
|
|
56
|
+
:size="props.size"
|
|
57
|
+
:ui="props.ui"
|
|
58
|
+
>
|
|
59
|
+
<div
|
|
60
|
+
:class="ui.content"
|
|
61
|
+
@click="inputRef?.focus()"
|
|
62
|
+
>
|
|
63
|
+
<span
|
|
64
|
+
v-for="(tag, index) in tags"
|
|
65
|
+
:key="tag"
|
|
66
|
+
:class="ui.tag"
|
|
67
|
+
>
|
|
68
|
+
<span :class="ui.tagLabel">{{ tag }}</span>
|
|
69
|
+
|
|
70
|
+
<button
|
|
71
|
+
:aria-label="`${messages.removeItem}: ${tag}`"
|
|
72
|
+
:class="ui.remove"
|
|
73
|
+
:disabled="props.disabled"
|
|
74
|
+
type="button"
|
|
75
|
+
@click.stop="remove(index)"
|
|
76
|
+
>
|
|
77
|
+
<Icon
|
|
78
|
+
:class="ui.removeIcon"
|
|
79
|
+
:name="icons.removeItem"
|
|
80
|
+
/>
|
|
81
|
+
</button>
|
|
82
|
+
</span>
|
|
83
|
+
|
|
84
|
+
<input
|
|
85
|
+
ref="input"
|
|
86
|
+
v-bind="$attrs"
|
|
87
|
+
:class="ui.input"
|
|
88
|
+
:disabled="props.disabled"
|
|
89
|
+
:placeholder="tags.length === 0 ? props.placeholder : void 0"
|
|
90
|
+
type="text"
|
|
91
|
+
:value="draft"
|
|
92
|
+
@input="onInput"
|
|
93
|
+
@keydown="onKeydown"
|
|
94
|
+
/>
|
|
95
|
+
</div>
|
|
96
|
+
</ControlShell>
|
|
97
|
+
</template>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { VunoSize } from '#vuno/types/base';
|
|
2
|
+
import type { VunoUi } from '#vuno/types/slots';
|
|
3
|
+
type __VLS_Props = Props;
|
|
4
|
+
type Props = {
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
max?: number;
|
|
7
|
+
placeholder?: string;
|
|
8
|
+
size?: VunoSize;
|
|
9
|
+
ui?: VunoUi<'control' | 'tagsInput'>;
|
|
10
|
+
};
|
|
11
|
+
type __VLS_ModelProps = {
|
|
12
|
+
modelValue?: string[] | undefined;
|
|
13
|
+
};
|
|
14
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
15
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
16
|
+
"update:modelValue": (value: string[] | undefined) => any;
|
|
17
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
18
|
+
"onUpdate:modelValue"?: ((value: string[] | undefined) => any) | undefined;
|
|
19
|
+
}>, {
|
|
20
|
+
size: VunoSize;
|
|
21
|
+
ui: VunoUi<"control" | "tagsInput">;
|
|
22
|
+
placeholder: string;
|
|
23
|
+
max: number;
|
|
24
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
25
|
+
declare const _default: typeof __VLS_export;
|
|
26
|
+
export default _default;
|
|
@@ -10,8 +10,16 @@ import type { VunoFieldTextarea } from '#vuno/types/field';
|
|
|
10
10
|
* `multiple` y `dropzone` en el campo de archivo, y por eso se arregla
|
|
11
11
|
* igual.
|
|
12
12
|
*/
|
|
13
|
-
type __VLS_Props = Omit<VunoFieldTextarea, '
|
|
14
|
-
|
|
13
|
+
type __VLS_Props = Omit<VunoFieldTextarea, 'columns'>;
|
|
14
|
+
type __VLS_ModelProps = {
|
|
15
|
+
modelValue?: string | undefined;
|
|
16
|
+
};
|
|
17
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
18
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
19
|
+
"update:modelValue": (value: string | undefined) => any;
|
|
20
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
21
|
+
"onUpdate:modelValue"?: ((value: string | undefined) => any) | undefined;
|
|
22
|
+
}>, {
|
|
15
23
|
autoresize: boolean;
|
|
16
24
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
17
25
|
declare const _default: typeof __VLS_export;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { useField } from "#vuno/composables/useField";
|
|
3
|
+
import { useTheme } from "#vuno/composables/useTheme";
|
|
4
|
+
import Textarea from "#vuno/components/FieldTextarea/internal/Textarea/Textarea.vue";
|
|
5
|
+
import FieldShell from "#vuno/components/internal/FieldShell/FieldShell.vue";
|
|
6
|
+
defineOptions({ name: "VunoFieldTextarea" });
|
|
7
|
+
const model = defineModel({ type: null, ...{ default: void 0 } });
|
|
8
|
+
const props = defineProps({
|
|
9
|
+
name: { type: String, required: false },
|
|
10
|
+
class: { type: String, required: false },
|
|
11
|
+
description: { type: String, required: false },
|
|
12
|
+
disabled: { type: Boolean, required: false },
|
|
13
|
+
error: { type: String, required: false },
|
|
14
|
+
help: { type: String, required: false },
|
|
15
|
+
hint: { type: String, required: false },
|
|
16
|
+
label: { type: String, required: false },
|
|
17
|
+
orientation: { type: String, required: false },
|
|
18
|
+
required: { type: Boolean, required: false },
|
|
19
|
+
size: { type: String, required: false },
|
|
20
|
+
ui: { type: Object, required: false },
|
|
21
|
+
autoresize: { type: Boolean, required: false, default: true },
|
|
22
|
+
maxrows: { type: Number, required: false },
|
|
23
|
+
placeholder: { type: String, required: false },
|
|
24
|
+
rows: { type: Number, required: false }
|
|
25
|
+
});
|
|
26
|
+
const { value } = useField(() => props.name, model);
|
|
27
|
+
const ui = useTheme("fieldTextarea", () => props.ui);
|
|
28
|
+
</script>
|
|
29
|
+
|
|
30
|
+
<template>
|
|
31
|
+
<FieldShell v-bind="props">
|
|
32
|
+
<template #default="control">
|
|
33
|
+
<Textarea
|
|
34
|
+
v-bind="control"
|
|
35
|
+
v-model="value"
|
|
36
|
+
:autoresize="props.autoresize"
|
|
37
|
+
:disabled="props.disabled"
|
|
38
|
+
:maxrows="props.maxrows"
|
|
39
|
+
:placeholder="props.placeholder"
|
|
40
|
+
:rows="props.rows"
|
|
41
|
+
:ui="ui"
|
|
42
|
+
/>
|
|
43
|
+
</template>
|
|
44
|
+
</FieldShell>
|
|
45
|
+
</template>
|
|
@@ -10,8 +10,16 @@ import type { VunoFieldTextarea } from '#vuno/types/field';
|
|
|
10
10
|
* `multiple` y `dropzone` en el campo de archivo, y por eso se arregla
|
|
11
11
|
* igual.
|
|
12
12
|
*/
|
|
13
|
-
type __VLS_Props = Omit<VunoFieldTextarea, '
|
|
14
|
-
|
|
13
|
+
type __VLS_Props = Omit<VunoFieldTextarea, 'columns'>;
|
|
14
|
+
type __VLS_ModelProps = {
|
|
15
|
+
modelValue?: string | undefined;
|
|
16
|
+
};
|
|
17
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
18
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
19
|
+
"update:modelValue": (value: string | undefined) => any;
|
|
20
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
21
|
+
"onUpdate:modelValue"?: ((value: string | undefined) => any) | undefined;
|
|
22
|
+
}>, {
|
|
15
23
|
autoresize: boolean;
|
|
16
24
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
17
25
|
declare const _default: typeof __VLS_export;
|
package/dist/runtime/app/components/{forms → FieldTextarea/internal/Textarea}/Textarea.d.vue.ts
RENAMED
|
@@ -1,12 +1,16 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
type
|
|
1
|
+
import type { VunoRadius, VunoSize } from '#vuno/types/base';
|
|
2
|
+
import type { VunoUi } from '#vuno/types/slots';
|
|
3
|
+
type __VLS_Props = Props;
|
|
4
|
+
type Props = {
|
|
3
5
|
/** Crece con el contenido en vez de enseñar su propia barra. */
|
|
4
6
|
autoresize?: boolean;
|
|
5
7
|
/** Tope al crecer, en filas. Sin él crece sin límite. */
|
|
6
8
|
maxrows?: number;
|
|
9
|
+
/** La curvatura de la caja. Sin valor, la que traiga el tema. */
|
|
10
|
+
radius?: VunoRadius;
|
|
7
11
|
rows?: number;
|
|
8
12
|
size?: VunoSize;
|
|
9
|
-
ui?:
|
|
13
|
+
ui?: VunoUi<'control' | 'textarea'>;
|
|
10
14
|
};
|
|
11
15
|
type __VLS_ModelProps = {
|
|
12
16
|
modelValue?: string | undefined;
|
|
@@ -19,9 +23,10 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
|
19
23
|
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
20
24
|
"onUpdate:modelValue"?: ((value: string | undefined) => any) | undefined;
|
|
21
25
|
}>, {
|
|
26
|
+
radius: VunoRadius;
|
|
22
27
|
size: VunoSize;
|
|
23
28
|
autoresize: boolean;
|
|
24
|
-
ui:
|
|
29
|
+
ui: VunoUi<"control" | "textarea">;
|
|
25
30
|
maxrows: number;
|
|
26
31
|
rows: number;
|
|
27
32
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|