@groupteknology/vuno 2.0.0 → 3.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 +193 -175
- package/dist/module.json +1 -1
- package/dist/module.mjs +7 -1
- package/dist/runtime/app/assets/css/dialog.css +1 -1
- package/dist/runtime/app/assets/css/main.css +1 -1
- 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 +2 -2
- package/dist/runtime/app/components/Alert/Alert.theme.d.ts +7 -6
- package/dist/runtime/app/components/Alert/Alert.theme.js +7 -6
- package/dist/runtime/app/components/Alert/Alert.types.d.ts +10 -0
- package/dist/runtime/app/components/Alert/Alert.vue +17 -8
- package/dist/runtime/app/components/Alert/Alert.vue.d.ts +2 -2
- package/dist/runtime/app/components/App/App.d.vue.ts +3 -19
- package/dist/runtime/app/components/App/App.types.d.ts +4 -0
- package/dist/runtime/app/components/App/App.vue +48 -29
- package/dist/runtime/app/components/App/App.vue.d.ts +3 -19
- package/dist/runtime/app/components/App/internal/OverlayItem/OverlayItem.vue +2 -3
- package/dist/runtime/app/components/App/internal/Toast/Toast.theme.d.ts +5 -5
- package/dist/runtime/app/components/App/internal/Toast/Toast.theme.js +7 -9
- package/dist/runtime/app/components/App/internal/Toast/Toast.vue +27 -36
- package/dist/runtime/app/components/App/internal/Toaster/Toaster.theme.d.ts +3 -3
- package/dist/runtime/app/components/App/internal/Toaster/Toaster.theme.js +3 -3
- package/dist/runtime/app/components/Avatar/Avatar.d.vue.ts +5 -22
- package/dist/runtime/app/components/Avatar/Avatar.types.d.ts +10 -0
- package/dist/runtime/app/components/Avatar/Avatar.types.js +0 -0
- package/dist/runtime/app/components/Avatar/Avatar.vue.d.ts +5 -22
- package/dist/runtime/app/components/Badge/Badge.d.vue.ts +7 -26
- package/dist/runtime/app/components/Badge/Badge.types.d.ts +12 -0
- package/dist/runtime/app/components/Badge/Badge.types.js +0 -0
- package/dist/runtime/app/components/Badge/Badge.vue.d.ts +7 -26
- package/dist/runtime/app/components/Breadcrumb/Breadcrumb.d.vue.ts +7 -0
- package/dist/runtime/app/components/Breadcrumb/Breadcrumb.theme.d.ts +15 -0
- package/dist/runtime/app/components/Breadcrumb/Breadcrumb.theme.js +16 -0
- package/dist/runtime/app/components/Breadcrumb/Breadcrumb.types.d.ts +7 -0
- package/dist/runtime/app/components/Breadcrumb/Breadcrumb.types.js +0 -0
- package/dist/runtime/app/components/Breadcrumb/Breadcrumb.vue +109 -0
- package/dist/runtime/app/components/Breadcrumb/Breadcrumb.vue.d.ts +7 -0
- package/dist/runtime/app/components/Button/Button.d.vue.ts +11 -31
- package/dist/runtime/app/components/Button/Button.theme.d.ts +36 -22
- package/dist/runtime/app/components/Button/Button.theme.js +28 -20
- package/dist/runtime/app/components/Button/Button.types.d.ts +24 -0
- package/dist/runtime/app/components/Button/Button.types.js +0 -0
- package/dist/runtime/app/components/Button/Button.vue +84 -33
- package/dist/runtime/app/components/Button/Button.vue.d.ts +11 -31
- package/dist/runtime/app/components/Card/Card.d.vue.ts +7 -69
- package/dist/runtime/app/components/Card/Card.theme.d.ts +56 -13
- package/dist/runtime/app/components/Card/Card.theme.js +39 -19
- package/dist/runtime/app/components/Card/Card.types.d.ts +12 -0
- package/dist/runtime/app/components/Card/Card.types.js +0 -0
- package/dist/runtime/app/components/Card/Card.vue +17 -11
- package/dist/runtime/app/components/Card/Card.vue.d.ts +7 -69
- package/dist/runtime/app/components/Code/Code.d.vue.ts +3 -13
- package/dist/runtime/app/components/Code/Code.theme.d.ts +1 -1
- package/dist/runtime/app/components/Code/Code.theme.js +1 -1
- package/dist/runtime/app/components/Code/Code.types.d.ts +8 -0
- package/dist/runtime/app/components/Code/Code.types.js +0 -0
- package/dist/runtime/app/components/Code/Code.vue +12 -5
- package/dist/runtime/app/components/Code/Code.vue.d.ts +3 -13
- package/dist/runtime/app/components/Collapsible/Collapsible.d.vue.ts +31 -0
- package/dist/runtime/app/components/Collapsible/Collapsible.theme.d.ts +6 -0
- package/dist/runtime/app/components/Collapsible/Collapsible.theme.js +7 -0
- package/dist/runtime/app/components/Collapsible/Collapsible.types.d.ts +4 -0
- package/dist/runtime/app/components/Collapsible/Collapsible.types.js +0 -0
- package/dist/runtime/app/components/Collapsible/Collapsible.vue +72 -0
- package/dist/runtime/app/components/Collapsible/Collapsible.vue.d.ts +31 -0
- package/dist/runtime/app/components/ColorModeButton/ColorModeButton.d.vue.ts +12 -0
- package/dist/runtime/app/components/ColorModeButton/ColorModeButton.types.d.ts +13 -0
- package/dist/runtime/app/components/ColorModeButton/ColorModeButton.types.js +0 -0
- package/dist/runtime/app/components/ColorModeButton/ColorModeButton.vue +55 -0
- package/dist/runtime/app/components/ColorModeButton/ColorModeButton.vue.d.ts +12 -0
- package/dist/runtime/app/components/Confirm/Confirm.d.vue.ts +2 -6
- package/dist/runtime/app/components/Confirm/Confirm.types.d.ts +6 -0
- package/dist/runtime/app/components/Confirm/Confirm.types.js +0 -0
- package/dist/runtime/app/components/Confirm/Confirm.vue.d.ts +2 -6
- package/dist/runtime/app/components/Container/Container.d.vue.ts +4 -28
- package/dist/runtime/app/components/Container/Container.types.d.ts +9 -0
- package/dist/runtime/app/components/Container/Container.types.js +0 -0
- package/dist/runtime/app/components/Container/Container.vue +1 -1
- package/dist/runtime/app/components/Container/Container.vue.d.ts +4 -28
- package/dist/runtime/app/components/ControlGroup/ControlGroup.d.vue.ts +5 -14
- package/dist/runtime/app/components/ControlGroup/ControlGroup.types.d.ts +9 -0
- package/dist/runtime/app/components/ControlGroup/ControlGroup.types.js +0 -0
- package/dist/runtime/app/components/ControlGroup/ControlGroup.vue.d.ts +5 -14
- package/dist/runtime/app/components/DataTable/DataTable.d.vue.ts +64 -0
- package/dist/runtime/app/components/DataTable/DataTable.theme.d.ts +17 -0
- package/dist/runtime/app/components/DataTable/DataTable.theme.js +19 -0
- package/dist/runtime/app/components/DataTable/DataTable.types.d.ts +13 -0
- package/dist/runtime/app/components/DataTable/DataTable.types.js +0 -0
- package/dist/runtime/app/components/DataTable/DataTable.vue +356 -0
- package/dist/runtime/app/components/DataTable/DataTable.vue.d.ts +64 -0
- package/dist/runtime/app/components/{Table/internal/useVunoTable.d.ts → DataTable/internal/useVunoDataTable.d.ts} +6 -29
- package/dist/runtime/app/components/{Table/internal/useVunoTable.js → DataTable/internal/useVunoDataTable.js} +2 -29
- package/dist/runtime/app/components/FieldArray/FieldArray.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldArray/FieldArray.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldArray/FieldArray.types.js +0 -0
- package/dist/runtime/app/components/FieldArray/FieldArray.vue +12 -5
- package/dist/runtime/app/components/FieldArray/FieldArray.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.types.js +0 -0
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.vue +1 -1
- package/dist/runtime/app/components/FieldCheckbox/FieldCheckbox.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldCheckbox/internal/Checkbox/Checkbox.d.vue.ts +4 -3
- package/dist/runtime/app/components/FieldCheckbox/internal/Checkbox/Checkbox.vue.d.ts +4 -3
- package/dist/runtime/app/components/FieldColor/FieldColor.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldColor/FieldColor.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldColor/FieldColor.types.js +0 -0
- package/dist/runtime/app/components/FieldColor/FieldColor.vue +3 -3
- package/dist/runtime/app/components/FieldColor/FieldColor.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.types.js +0 -0
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.vue +3 -3
- package/dist/runtime/app/components/FieldCurrency/FieldCurrency.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldFile/FieldFile.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldFile/FieldFile.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldFile/FieldFile.types.js +0 -0
- package/dist/runtime/app/components/FieldFile/FieldFile.vue +1 -1
- package/dist/runtime/app/components/FieldFile/FieldFile.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldFile/internal/FileUpload/FileUpload.d.vue.ts +4 -3
- package/dist/runtime/app/components/FieldFile/internal/FileUpload/FileUpload.theme.d.ts +1 -0
- package/dist/runtime/app/components/FieldFile/internal/FileUpload/FileUpload.theme.js +1 -0
- package/dist/runtime/app/components/FieldFile/internal/FileUpload/FileUpload.vue +26 -5
- package/dist/runtime/app/components/FieldFile/internal/FileUpload/FileUpload.vue.d.ts +4 -3
- package/dist/runtime/app/components/FieldInput/FieldInput.d.vue.ts +4 -4
- package/dist/runtime/app/components/FieldInput/FieldInput.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldInput/FieldInput.types.js +0 -0
- package/dist/runtime/app/components/FieldInput/FieldInput.vue +3 -3
- package/dist/runtime/app/components/FieldInput/FieldInput.vue.d.ts +4 -4
- package/dist/runtime/app/components/FieldNumber/FieldNumber.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldNumber/FieldNumber.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldNumber/FieldNumber.types.js +0 -0
- package/dist/runtime/app/components/FieldNumber/FieldNumber.vue +3 -3
- package/dist/runtime/app/components/FieldNumber/FieldNumber.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldPassword/FieldPassword.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldPassword/FieldPassword.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldPassword/FieldPassword.types.js +0 -0
- package/dist/runtime/app/components/FieldPassword/FieldPassword.vue +4 -4
- package/dist/runtime/app/components/FieldPassword/FieldPassword.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldRadio/FieldRadio.d.vue.ts +3 -2
- package/dist/runtime/app/components/FieldRadio/FieldRadio.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldRadio/FieldRadio.types.js +0 -0
- package/dist/runtime/app/components/FieldRadio/FieldRadio.vue +1 -1
- package/dist/runtime/app/components/FieldRadio/FieldRadio.vue.d.ts +3 -2
- package/dist/runtime/app/components/FieldRadio/internal/RadioGroup/RadioGroup.d.vue.ts +4 -4
- package/dist/runtime/app/components/FieldRadio/internal/RadioGroup/RadioGroup.vue +6 -2
- package/dist/runtime/app/components/FieldRadio/internal/RadioGroup/RadioGroup.vue.d.ts +4 -4
- package/dist/runtime/app/components/FieldSearch/FieldSearch.d.vue.ts +3 -3
- package/dist/runtime/app/components/FieldSearch/FieldSearch.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldSearch/FieldSearch.types.js +0 -0
- package/dist/runtime/app/components/FieldSearch/FieldSearch.vue +4 -4
- package/dist/runtime/app/components/FieldSearch/FieldSearch.vue.d.ts +3 -3
- package/dist/runtime/app/components/FieldSelect/FieldSelect.d.vue.ts +3 -2
- package/dist/runtime/app/components/FieldSelect/FieldSelect.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldSelect/FieldSelect.types.js +0 -0
- package/dist/runtime/app/components/FieldSelect/FieldSelect.vue +1 -1
- package/dist/runtime/app/components/FieldSelect/FieldSelect.vue.d.ts +3 -2
- package/dist/runtime/app/components/FieldSelect/internal/Select/Select.d.vue.ts +7 -7
- package/dist/runtime/app/components/FieldSelect/internal/Select/Select.vue +16 -6
- package/dist/runtime/app/components/FieldSelect/internal/Select/Select.vue.d.ts +7 -7
- package/dist/runtime/app/components/FieldSlug/FieldSlug.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldSlug/FieldSlug.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldSlug/FieldSlug.types.js +0 -0
- package/dist/runtime/app/components/FieldSlug/FieldSlug.vue +4 -4
- package/dist/runtime/app/components/FieldSlug/FieldSlug.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.types.js +0 -0
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.vue +1 -1
- package/dist/runtime/app/components/FieldSwitch/FieldSwitch.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldSwitch/internal/Switch/Switch.d.vue.ts +4 -3
- package/dist/runtime/app/components/FieldSwitch/internal/Switch/Switch.vue.d.ts +4 -3
- package/dist/runtime/app/components/FieldTags/FieldTags.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldTags/FieldTags.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldTags/FieldTags.types.js +0 -0
- package/dist/runtime/app/components/FieldTags/FieldTags.vue +1 -1
- package/dist/runtime/app/components/FieldTags/FieldTags.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldTags/internal/TagsInput/TagsInput.d.vue.ts +4 -4
- package/dist/runtime/app/components/FieldTags/internal/TagsInput/TagsInput.vue +16 -6
- package/dist/runtime/app/components/FieldTags/internal/TagsInput/TagsInput.vue.d.ts +4 -4
- package/dist/runtime/app/components/FieldTextarea/FieldTextarea.d.vue.ts +2 -2
- package/dist/runtime/app/components/FieldTextarea/FieldTextarea.types.d.ts +2 -0
- package/dist/runtime/app/components/FieldTextarea/FieldTextarea.types.js +0 -0
- package/dist/runtime/app/components/FieldTextarea/FieldTextarea.vue +1 -1
- package/dist/runtime/app/components/FieldTextarea/FieldTextarea.vue.d.ts +2 -2
- package/dist/runtime/app/components/FieldTextarea/internal/Textarea/Textarea.d.vue.ts +4 -3
- package/dist/runtime/app/components/FieldTextarea/internal/Textarea/Textarea.vue +4 -4
- package/dist/runtime/app/components/FieldTextarea/internal/Textarea/Textarea.vue.d.ts +4 -3
- package/dist/runtime/app/components/Form/Form.d.vue.ts +3 -19
- package/dist/runtime/app/components/Form/Form.types.d.ts +8 -0
- package/dist/runtime/app/components/Form/Form.types.js +0 -0
- package/dist/runtime/app/components/Form/Form.vue +3 -3
- package/dist/runtime/app/components/Form/Form.vue.d.ts +3 -19
- package/dist/runtime/app/components/FormField/FormField.d.vue.ts +4 -18
- package/dist/runtime/app/components/FormField/FormField.types.d.ts +14 -0
- package/dist/runtime/app/components/FormField/FormField.types.js +0 -0
- package/dist/runtime/app/components/FormField/FormField.vue +26 -10
- package/dist/runtime/app/components/FormField/FormField.vue.d.ts +4 -18
- package/dist/runtime/app/components/{internal → FormField/internal}/FieldShell/FieldShell.d.vue.ts +2 -3
- package/dist/runtime/app/components/{internal → FormField/internal}/FieldShell/FieldShell.vue.d.ts +2 -3
- package/dist/runtime/app/components/FormModal/FormModal.d.vue.ts +6 -25
- package/dist/runtime/app/components/FormModal/FormModal.types.d.ts +14 -0
- package/dist/runtime/app/components/FormModal/FormModal.types.js +0 -0
- package/dist/runtime/app/components/FormModal/FormModal.vue +12 -2
- package/dist/runtime/app/components/FormModal/FormModal.vue.d.ts +6 -25
- package/dist/runtime/app/components/FormSection/FormSection.d.vue.ts +2 -13
- package/dist/runtime/app/components/FormSection/FormSection.types.d.ts +7 -0
- package/dist/runtime/app/components/FormSection/FormSection.types.js +0 -0
- package/dist/runtime/app/components/FormSection/FormSection.vue +11 -4
- package/dist/runtime/app/components/FormSection/FormSection.vue.d.ts +2 -13
- package/dist/runtime/app/components/Icon/Icon.d.vue.ts +2 -4
- package/dist/runtime/app/components/Icon/Icon.types.d.ts +3 -0
- package/dist/runtime/app/components/Icon/Icon.types.js +0 -0
- package/dist/runtime/app/components/Icon/Icon.vue.d.ts +2 -4
- package/dist/runtime/app/components/Menu/Menu.d.vue.ts +4 -21
- package/dist/runtime/app/components/Menu/Menu.types.d.ts +7 -0
- package/dist/runtime/app/components/Menu/Menu.types.js +0 -0
- package/dist/runtime/app/components/Menu/Menu.vue +18 -110
- package/dist/runtime/app/components/Menu/Menu.vue.d.ts +4 -21
- package/dist/runtime/app/components/Menu/internal/MenuLevel/MenuLevel.d.vue.ts +26 -0
- package/dist/runtime/app/components/Menu/internal/MenuLevel/MenuLevel.vue +167 -0
- package/dist/runtime/app/components/Menu/internal/MenuLevel/MenuLevel.vue.d.ts +26 -0
- package/dist/runtime/app/components/Modal/Modal.d.vue.ts +6 -18
- package/dist/runtime/app/components/Modal/Modal.theme.d.ts +18 -14
- package/dist/runtime/app/components/Modal/Modal.theme.js +17 -21
- package/dist/runtime/app/components/Modal/Modal.types.d.ts +12 -0
- package/dist/runtime/app/components/Modal/Modal.types.js +0 -0
- package/dist/runtime/app/components/Modal/Modal.vue +99 -65
- package/dist/runtime/app/components/Modal/Modal.vue.d.ts +6 -18
- package/dist/runtime/app/components/Navbar/Navbar.d.vue.ts +3 -28
- package/dist/runtime/app/components/Navbar/Navbar.theme.d.ts +2 -3
- package/dist/runtime/app/components/Navbar/Navbar.theme.js +2 -3
- package/dist/runtime/app/components/Navbar/Navbar.types.d.ts +4 -0
- package/dist/runtime/app/components/Navbar/Navbar.types.js +0 -0
- package/dist/runtime/app/components/Navbar/Navbar.vue.d.ts +3 -28
- package/dist/runtime/app/components/NavigationList/NavigationList.d.vue.ts +4 -33
- package/dist/runtime/app/components/NavigationList/NavigationList.keys.d.ts +3 -0
- package/dist/runtime/app/components/NavigationList/NavigationList.keys.js +1 -0
- package/dist/runtime/app/components/NavigationList/NavigationList.types.d.ts +9 -0
- package/dist/runtime/app/components/NavigationList/NavigationList.types.js +0 -0
- package/dist/runtime/app/components/NavigationList/NavigationList.vue +65 -19
- package/dist/runtime/app/components/NavigationList/NavigationList.vue.d.ts +4 -33
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.d.vue.ts +3 -24
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.keys.d.ts +7 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.keys.js +3 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.types.d.ts +10 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.types.js +0 -0
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.vue +45 -13
- package/dist/runtime/app/components/NavigationMenu/NavigationMenu.vue.d.ts +3 -24
- package/dist/runtime/app/components/NavigationToc/NavigationToc.d.vue.ts +3 -10
- package/dist/runtime/app/components/NavigationToc/NavigationToc.types.d.ts +7 -0
- package/dist/runtime/app/components/NavigationToc/NavigationToc.types.js +0 -0
- package/dist/runtime/app/components/NavigationToc/NavigationToc.vue +8 -1
- package/dist/runtime/app/components/NavigationToc/NavigationToc.vue.d.ts +3 -10
- package/dist/runtime/app/components/Pagination/Pagination.d.vue.ts +5 -23
- package/dist/runtime/app/components/Pagination/Pagination.types.d.ts +11 -0
- package/dist/runtime/app/components/Pagination/Pagination.types.js +0 -0
- package/dist/runtime/app/components/Pagination/Pagination.vue +6 -2
- package/dist/runtime/app/components/Pagination/Pagination.vue.d.ts +5 -23
- package/dist/runtime/app/components/Slideover/Slideover.d.vue.ts +4 -13
- package/dist/runtime/app/components/Slideover/Slideover.types.d.ts +12 -0
- package/dist/runtime/app/components/Slideover/Slideover.types.js +0 -0
- package/dist/runtime/app/components/Slideover/Slideover.vue.d.ts +4 -13
- package/dist/runtime/app/components/State/State.d.vue.ts +2 -2
- package/dist/runtime/app/components/State/State.types.d.ts +15 -0
- package/dist/runtime/app/components/State/State.types.js +0 -0
- package/dist/runtime/app/components/State/State.vue +13 -3
- package/dist/runtime/app/components/State/State.vue.d.ts +2 -2
- package/dist/runtime/app/components/Table/Table.d.vue.ts +8 -55
- package/dist/runtime/app/components/Table/Table.theme.d.ts +17 -35
- package/dist/runtime/app/components/Table/Table.theme.js +15 -48
- package/dist/runtime/app/components/Table/Table.types.d.ts +9 -0
- package/dist/runtime/app/components/Table/Table.types.js +0 -0
- package/dist/runtime/app/components/Table/Table.vue +143 -415
- package/dist/runtime/app/components/Table/Table.vue.d.ts +8 -55
- package/dist/runtime/app/components/Table/internal/CellBoolean/CellBoolean.vue +13 -3
- package/dist/runtime/app/components/Table/internal/CellCurrency/CellCurrency.vue +8 -1
- package/dist/runtime/app/components/Table/internal/CellDate/CellDate.vue +8 -1
- package/dist/runtime/app/components/Table/internal/CellNumber/CellNumber.vue +8 -1
- package/dist/runtime/app/components/Table/internal/CellText/CellText.vue +8 -1
- package/dist/runtime/app/components/Table/internal/TableCell/TableCell.d.vue.ts +2 -2
- package/dist/runtime/app/components/Table/internal/TableCell/TableCell.vue.d.ts +2 -2
- package/dist/runtime/app/components/Table/internal/column.d.ts +9 -0
- package/dist/runtime/app/components/Table/internal/column.js +15 -0
- package/dist/runtime/app/components/Table/internal/useVunoTableSelection.d.ts +1 -1
- package/dist/runtime/app/components/Tabs/Tabs.d.vue.ts +5 -24
- package/dist/runtime/app/components/Tabs/Tabs.theme.d.ts +15 -6
- package/dist/runtime/app/components/Tabs/Tabs.theme.js +15 -6
- package/dist/runtime/app/components/Tabs/Tabs.types.d.ts +10 -0
- package/dist/runtime/app/components/Tabs/Tabs.types.js +0 -0
- package/dist/runtime/app/components/Tabs/Tabs.vue +91 -17
- package/dist/runtime/app/components/Tabs/Tabs.vue.d.ts +5 -24
- package/dist/runtime/app/components/Text/Text.d.vue.ts +19 -0
- package/dist/runtime/app/components/Text/Text.theme.d.ts +55 -0
- package/dist/runtime/app/components/Text/Text.theme.js +28 -0
- package/dist/runtime/app/components/Text/Text.types.d.ts +9 -0
- package/dist/runtime/app/components/Text/Text.types.js +0 -0
- package/dist/runtime/app/components/Text/Text.vue +37 -0
- package/dist/runtime/app/components/Text/Text.vue.d.ts +19 -0
- package/dist/runtime/app/components/Toolbar/Toolbar.d.vue.ts +17 -0
- package/dist/runtime/app/components/Toolbar/Toolbar.theme.d.ts +5 -0
- package/dist/runtime/app/components/Toolbar/Toolbar.theme.js +6 -0
- package/dist/runtime/app/components/Toolbar/Toolbar.types.d.ts +9 -0
- package/dist/runtime/app/components/Toolbar/Toolbar.types.js +0 -0
- package/dist/runtime/app/components/Toolbar/Toolbar.vue +76 -0
- package/dist/runtime/app/components/Toolbar/Toolbar.vue.d.ts +17 -0
- package/dist/runtime/app/components/Tooltip/Tooltip.d.vue.ts +5 -26
- package/dist/runtime/app/components/Tooltip/Tooltip.types.d.ts +11 -0
- package/dist/runtime/app/components/Tooltip/Tooltip.types.js +0 -0
- package/dist/runtime/app/components/Tooltip/Tooltip.vue +1 -1
- package/dist/runtime/app/components/Tooltip/Tooltip.vue.d.ts +5 -26
- package/dist/runtime/app/composables/internal/useVunoContext.d.ts +5 -0
- package/dist/runtime/app/composables/internal/useVunoContext.js +8 -0
- package/dist/runtime/app/composables/internal/useVunoControlGroup.d.ts +3 -4
- package/dist/runtime/app/composables/internal/useVunoDirection.d.ts +5 -0
- package/dist/runtime/app/composables/internal/useVunoDirection.js +8 -0
- package/dist/runtime/app/composables/internal/useVunoFormContext.d.ts +5 -0
- package/dist/runtime/app/composables/internal/useVunoFormContext.js +8 -0
- package/dist/runtime/app/composables/internal/useVunoOverlayBehind.d.ts +6 -0
- package/dist/runtime/app/composables/internal/useVunoOverlayBehind.js +8 -0
- package/dist/runtime/app/composables/useContext.js +2 -3
- package/dist/runtime/app/composables/useForm.js +2 -3
- package/dist/runtime/app/composables/useTableQuery.d.ts +1 -1
- package/dist/runtime/app/composables/useTheme.js +6 -3
- package/dist/runtime/app/{components/internal/ControlShell/ControlShell.vue.d.ts → primitives/PrimitiveControl/PrimitiveControl.d.vue.ts} +4 -3
- package/dist/runtime/app/{components/internal/ControlShell/ControlShell.theme.d.ts → primitives/PrimitiveControl/PrimitiveControl.theme.d.ts} +1 -1
- package/dist/runtime/app/{components/internal/ControlShell/ControlShell.vue → primitives/PrimitiveControl/PrimitiveControl.vue} +1 -1
- package/dist/runtime/app/{components/internal/ControlShell/ControlShell.d.vue.ts → primitives/PrimitiveControl/PrimitiveControl.vue.d.ts} +4 -3
- package/dist/runtime/app/{components/internal/Input/Input.d.vue.ts → primitives/PrimitiveInput/PrimitiveInput.d.vue.ts} +4 -3
- package/dist/runtime/app/{components/internal/Input/Input.vue → primitives/PrimitiveInput/PrimitiveInput.vue} +4 -4
- package/dist/runtime/app/{components/internal/Input/Input.vue.d.ts → primitives/PrimitiveInput/PrimitiveInput.vue.d.ts} +4 -3
- package/dist/runtime/app/{components/internal/NumberInput/NumberInput.d.vue.ts → primitives/PrimitiveNumberInput/PrimitiveNumberInput.d.vue.ts} +3 -4
- package/dist/runtime/app/{components/internal/NumberInput/NumberInput.theme.d.ts → primitives/PrimitiveNumberInput/PrimitiveNumberInput.theme.d.ts} +3 -0
- package/dist/runtime/app/{components/internal/NumberInput/NumberInput.theme.js → primitives/PrimitiveNumberInput/PrimitiveNumberInput.theme.js} +4 -1
- package/dist/runtime/app/{components/internal/NumberInput/NumberInput.vue → primitives/PrimitiveNumberInput/PrimitiveNumberInput.vue} +7 -5
- package/dist/runtime/app/{components/internal/NumberInput/NumberInput.vue.d.ts → primitives/PrimitiveNumberInput/PrimitiveNumberInput.vue.d.ts} +3 -4
- package/dist/runtime/app/theme/index.d.ts +254 -96
- package/dist/runtime/app/theme/index.js +13 -5
- package/dist/runtime/app/theme/messages.js +1 -0
- package/dist/runtime/app/theme/shared.d.ts +3 -2
- package/dist/runtime/app/theme/shared.js +2 -1
- package/dist/runtime/app/types/app.d.ts +4 -2
- package/dist/runtime/app/types/base.d.ts +5 -23
- package/dist/runtime/app/types/field.d.ts +3 -1
- package/dist/runtime/app/types/form.d.ts +3 -4
- package/dist/runtime/app/types/index.d.ts +55 -7
- package/dist/runtime/app/types/menu.d.ts +22 -0
- package/dist/runtime/app/types/menu.js +0 -0
- package/dist/runtime/app/types/page.d.ts +6 -10
- package/dist/runtime/app/types/slots.d.ts +8 -4
- package/dist/runtime/app/types/table.d.ts +28 -28
- package/dist/runtime/app/types/text.d.ts +6 -0
- package/dist/runtime/app/types/text.js +0 -0
- package/dist/runtime/app/types/theme.d.ts +15 -6
- package/dist/runtime/app/utils/format.js +3 -2
- package/dist/runtime/app/utils/path.js +1 -1
- package/dist/runtime/app/{internal → utils}/slots.d.ts +2 -2
- package/dist/runtime/app/utils/theme.d.ts +8 -41
- package/dist/runtime/app/utils/theme.js +31 -29
- package/package.json +9 -9
- package/dist/runtime/app/components/Page/Page.d.vue.ts +0 -40
- package/dist/runtime/app/components/Page/Page.theme.d.ts +0 -32
- package/dist/runtime/app/components/Page/Page.theme.js +0 -31
- package/dist/runtime/app/components/Page/Page.vue +0 -132
- package/dist/runtime/app/components/Page/Page.vue.d.ts +0 -40
- package/dist/runtime/app/internal/keys.d.ts +0 -43
- package/dist/runtime/app/internal/keys.js +0 -8
- package/dist/runtime/app/types/alert.d.ts +0 -13
- package/dist/runtime/app/types/state.d.ts +0 -35
- /package/dist/runtime/app/{types/alert.js → components/Alert/Alert.types.js} +0 -0
- /package/dist/runtime/app/{types/state.js → components/App/App.types.js} +0 -0
- /package/dist/runtime/app/components/{Table → DataTable}/internal/query.d.ts +0 -0
- /package/dist/runtime/app/components/{Table → DataTable}/internal/query.js +0 -0
- /package/dist/runtime/app/components/{internal → FormField/internal}/FieldShell/FieldShell.vue +0 -0
- /package/dist/runtime/app/{components/internal/ControlShell/ControlShell.theme.js → primitives/PrimitiveControl/PrimitiveControl.theme.js} +0 -0
- /package/dist/runtime/app/{components/internal/Input/Input.theme.d.ts → primitives/PrimitiveInput/PrimitiveInput.theme.d.ts} +0 -0
- /package/dist/runtime/app/{components/internal/Input/Input.theme.js → primitives/PrimitiveInput/PrimitiveInput.theme.js} +0 -0
- /package/dist/runtime/app/{components/internal/NumberInput → primitives/PrimitiveNumberInput}/number.d.ts +0 -0
- /package/dist/runtime/app/{components/internal/NumberInput → primitives/PrimitiveNumberInput}/number.js +0 -0
- /package/dist/runtime/app/{internal → utils}/slots.js +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import type { VunoStateFailureProps } from '
|
|
1
|
+
import type { VunoStateFailureProps } from './State.types.js';
|
|
2
2
|
type __VLS_Slots = {
|
|
3
3
|
/** La invitación a crear el primer registro. Solo en el estado vacío: un fallo ya trae su reintento. */
|
|
4
4
|
actions?: () => unknown;
|
|
5
5
|
};
|
|
6
|
-
declare const __VLS_base: import("vue").DefineComponent<(Partial<VunoStateFailureProps> & import("
|
|
6
|
+
declare const __VLS_base: import("vue").DefineComponent<(Partial<VunoStateFailureProps> & import("./State.types.js").VunoStateEmptyProps) | (Partial<VunoStateFailureProps> & VunoStateFailureProps), {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<(Partial<VunoStateFailureProps> & import("./State.types.js").VunoStateEmptyProps) | (Partial<VunoStateFailureProps> & VunoStateFailureProps)> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
7
7
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
8
8
|
declare const _default: typeof __VLS_export;
|
|
9
9
|
export default _default;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { VunoUi } from '#vuno/types/slots';
|
|
2
|
+
import type { VunoTableFailure } from '#vuno/types/table';
|
|
3
|
+
export type VunoStateEmptyProps = {
|
|
4
|
+
hint?: string;
|
|
5
|
+
icon?: string;
|
|
6
|
+
title?: string;
|
|
7
|
+
tone?: 'empty';
|
|
8
|
+
ui?: VunoUi<'state'>;
|
|
9
|
+
};
|
|
10
|
+
export type VunoStateFailureProps = {
|
|
11
|
+
failure: VunoTableFailure;
|
|
12
|
+
tone: 'failure';
|
|
13
|
+
ui?: VunoUi<'state'>;
|
|
14
|
+
};
|
|
15
|
+
export type VunoStateProps = VunoStateEmptyProps | VunoStateFailureProps;
|
|
File without changes
|
|
@@ -3,6 +3,7 @@ import { computed } from "vue";
|
|
|
3
3
|
import { useIcons, useMessages, useTheme } from "#vuno/composables/useTheme";
|
|
4
4
|
import Button from "#vuno/components/Button/Button.vue";
|
|
5
5
|
import Icon from "#vuno/components/Icon/Icon.vue";
|
|
6
|
+
import Text from "#vuno/components/Text/Text.vue";
|
|
6
7
|
defineOptions({ name: "VunoState" });
|
|
7
8
|
const props = defineProps({
|
|
8
9
|
failure: { type: Object, required: false },
|
|
@@ -34,14 +35,23 @@ const hint = computed(() => failure.value ? failure.value.hint ?? messages.value
|
|
|
34
35
|
:name="iconName"
|
|
35
36
|
/>
|
|
36
37
|
|
|
37
|
-
<
|
|
38
|
+
<Text
|
|
39
|
+
:class="ui.title"
|
|
40
|
+
tag="p"
|
|
41
|
+
tone="inherit"
|
|
42
|
+
variant="inherit"
|
|
43
|
+
>{{ title }}</Text
|
|
44
|
+
>
|
|
38
45
|
|
|
39
|
-
<
|
|
46
|
+
<Text
|
|
40
47
|
v-if="hint"
|
|
41
48
|
:class="ui.hint"
|
|
49
|
+
tag="p"
|
|
50
|
+
tone="inherit"
|
|
51
|
+
variant="inherit"
|
|
42
52
|
>
|
|
43
53
|
{{ hint }}
|
|
44
|
-
</
|
|
54
|
+
</Text>
|
|
45
55
|
|
|
46
56
|
<div :class="ui.actions">
|
|
47
57
|
<!--
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import type { VunoStateFailureProps } from '
|
|
1
|
+
import type { VunoStateFailureProps } from './State.types.js';
|
|
2
2
|
type __VLS_Slots = {
|
|
3
3
|
/** La invitación a crear el primer registro. Solo en el estado vacío: un fallo ya trae su reintento. */
|
|
4
4
|
actions?: () => unknown;
|
|
5
5
|
};
|
|
6
|
-
declare const __VLS_base: import("vue").DefineComponent<(Partial<VunoStateFailureProps> & import("
|
|
6
|
+
declare const __VLS_base: import("vue").DefineComponent<(Partial<VunoStateFailureProps> & import("./State.types.js").VunoStateEmptyProps) | (Partial<VunoStateFailureProps> & VunoStateFailureProps), {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<(Partial<VunoStateFailureProps> & import("./State.types.js").VunoStateEmptyProps) | (Partial<VunoStateFailureProps> & VunoStateFailureProps)> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
7
7
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
8
8
|
declare const _default: typeof __VLS_export;
|
|
9
9
|
export default _default;
|
|
@@ -1,49 +1,17 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
props: import("vue").PublicProps & __VLS_PrettifyLocal<({
|
|
6
|
-
data: TRow[];
|
|
7
|
-
definition: VunoTableDefinition<TRow>;
|
|
8
|
-
/**
|
|
9
|
-
* Fallo de la consulta. Sin esto, un error se pintaría como «no hay
|
|
10
|
-
* resultados» y la tabla afirmaría que no hay nada cuando en realidad
|
|
11
|
-
* no se pudo saber.
|
|
12
|
-
*/
|
|
13
|
-
failure?: VunoTableFailure;
|
|
14
|
-
loading?: boolean;
|
|
15
|
-
/** La curvatura. Sin valor, la que traiga el tema. */
|
|
16
|
-
radius?: VunoRadius;
|
|
17
|
-
/** Total de filas en servidor, no las de la página actual. */
|
|
18
|
-
total?: number;
|
|
19
|
-
ui?: VunoUi<"table">;
|
|
20
|
-
} & {
|
|
21
|
-
/**
|
|
22
|
-
* Estado de consulta. El consumidor lo observa y devuelve `data` y `total`.
|
|
23
|
-
*
|
|
24
|
-
* Es obligatorio a propósito: la tabla no trae datos por sí misma, así que
|
|
25
|
-
* un estado interno avanzaría de página sin que nadie pidiera la siguiente
|
|
26
|
-
* —el pie diría «11-20» mientras se siguen viendo las filas 1-10—. Dónde
|
|
27
|
-
* vive ese estado lo decide `useTableQuery`: un `ref` normal o la
|
|
28
|
-
* query string.
|
|
29
|
-
*/
|
|
30
|
-
query: VunoTableQuery;
|
|
31
|
-
/** Claves de las filas seleccionadas, no las filas: con paginación en servidor las de otras páginas no están cargadas. */
|
|
1
|
+
import type { VunoTableSort } from '#vuno/types/table';
|
|
2
|
+
import type { VunoTableProps } from './Table.types.js';
|
|
3
|
+
declare const __VLS_export: <TRow extends import("#vuno/types/table").VunoTableRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
4
|
+
props: import("vue").PublicProps & __VLS_PrettifyLocal<(VunoTableProps<TRow> & {
|
|
32
5
|
selection?: (number | string)[];
|
|
6
|
+
sort?: null | VunoTableSort;
|
|
33
7
|
}) & {
|
|
34
8
|
onRowClick?: ((row: TRow) => any) | undefined;
|
|
35
|
-
"onUpdate:query"?: ((value: VunoTableQuery) => any) | undefined;
|
|
36
9
|
"onUpdate:selection"?: ((value: (string | number)[]) => any) | undefined;
|
|
10
|
+
"onUpdate:sort"?: ((value: VunoTableSort | null) => any) | undefined;
|
|
37
11
|
}> & (typeof globalThis extends {
|
|
38
12
|
__VLS_PROPS_FALLBACK: infer P;
|
|
39
13
|
} ? P : {});
|
|
40
|
-
expose: (exposed:
|
|
41
|
-
clearFilters: () => void;
|
|
42
|
-
clearQuery: () => void;
|
|
43
|
-
clearSearch: () => void;
|
|
44
|
-
clearSelection: () => void;
|
|
45
|
-
goToPage: (page: number) => void;
|
|
46
|
-
}>) => void;
|
|
14
|
+
expose: (exposed: {}) => void;
|
|
47
15
|
attrs: any;
|
|
48
16
|
slots: {
|
|
49
17
|
[key: `cell-${string}`]: (props: {
|
|
@@ -51,23 +19,8 @@ declare const __VLS_export: <TRow extends VunoTableRow>(__VLS_props: NonNullable
|
|
|
51
19
|
value: unknown;
|
|
52
20
|
}) => unknown;
|
|
53
21
|
empty?: () => unknown;
|
|
54
|
-
'empty-actions'?: () => unknown;
|
|
55
|
-
'no-matches'?: (props: {
|
|
56
|
-
clear: () => void;
|
|
57
|
-
}) => unknown;
|
|
58
|
-
'no-matches-actions'?: (props: {
|
|
59
|
-
clear: () => void;
|
|
60
|
-
}) => unknown;
|
|
61
|
-
selection?: (props: {
|
|
62
|
-
count: number;
|
|
63
|
-
keys: (number | string)[];
|
|
64
|
-
clear: () => void;
|
|
65
|
-
}) => unknown;
|
|
66
|
-
toolbar?: (props: {
|
|
67
|
-
query: VunoTableQuery;
|
|
68
|
-
}) => unknown;
|
|
69
22
|
};
|
|
70
|
-
emit: ((evt: "rowClick", row: TRow) => void) & (((event: "update:
|
|
23
|
+
emit: ((evt: "rowClick", row: TRow) => void) & (((event: "update:selection", value: (string | number)[]) => void) & ((event: "update:sort", value: VunoTableSort | null) => void));
|
|
71
24
|
}>) => import("vue").VNode & {
|
|
72
25
|
__ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
|
|
73
26
|
};
|
|
@@ -1,50 +1,32 @@
|
|
|
1
1
|
export declare const tableTheme: Record<"table", {
|
|
2
2
|
readonly slots: {
|
|
3
|
-
readonly
|
|
4
|
-
readonly emptyCell: "px-4 py-6";
|
|
5
|
-
readonly filtersBody: "flex flex-col gap-4";
|
|
6
|
-
readonly filtersFooter: "flex items-center justify-between gap-2";
|
|
7
|
-
readonly footer: "flex flex-wrap items-center justify-between gap-4 px-1";
|
|
3
|
+
readonly caption: "px-4 py-3 text-start text-sm font-semibold text-vuno-strong";
|
|
4
|
+
readonly emptyCell: "px-4 py-6 text-center text-sm text-vuno-muted";
|
|
8
5
|
readonly headRow: "border-b border-vuno-border";
|
|
9
|
-
readonly
|
|
10
|
-
readonly pageSizeControl: "w-auto";
|
|
11
|
-
readonly pageSizeSelect: "cursor-pointer bg-transparent py-1 pr-1 outline-none";
|
|
12
|
-
readonly root: "flex w-full flex-col gap-4";
|
|
13
|
-
readonly search: "w-full sm:max-w-xs";
|
|
6
|
+
readonly interactiveRow: "cursor-pointer focus-visible:outline-2 focus-visible:outline-offset-[-2px] focus-visible:outline-vuno-primary";
|
|
14
7
|
readonly selectCell: "w-0";
|
|
15
|
-
readonly selection: "flex items-center justify-between gap-2 rounded-sm bg-vuno-primary/10 px-3 py-2 text-sm";
|
|
16
|
-
readonly skip: "sr-only rounded-sm bg-vuno-surface text-vuno-body focus:not-sr-only focus:outline-vuno-primary focus:z-10 focus:inline-block focus:px-3 focus:py-1.5 focus:text-sm focus:outline-2 focus:outline-offset-2";
|
|
17
8
|
readonly sortButton: "-mx-2";
|
|
9
|
+
readonly stickyColumn: "sticky z-10 bg-vuno-surface after:pointer-events-none after:absolute after:inset-y-0 after:w-6 group-hover/row:bg-vuno-surface-1 group-data-[selected=true]/row:bg-[color-mix(in_oklch,var(--color-vuno-primary)_10%,var(--color-vuno-surface))]";
|
|
10
|
+
readonly stickyColumnEnd: "end-0 after:-start-6 after:bg-linear-to-l after:from-vuno-surface after:to-transparent group-hover/row:after:from-vuno-surface-1 group-data-[selected=true]/row:after:from-[color-mix(in_oklch,var(--color-vuno-primary)_10%,var(--color-vuno-surface))]";
|
|
11
|
+
readonly stickyColumnStart: "start-0 after:-end-6 after:bg-linear-to-r after:from-vuno-surface after:to-transparent group-hover/row:after:from-vuno-surface-1 group-data-[selected=true]/row:after:from-[color-mix(in_oklch,var(--color-vuno-primary)_10%,var(--color-vuno-surface))]";
|
|
12
|
+
readonly stickyHeader: "sticky top-0 z-20 bg-vuno-surface";
|
|
13
|
+
readonly stickyIntersection: "z-30";
|
|
18
14
|
readonly table: "min-w-full";
|
|
19
|
-
readonly tableRoot: "relative overflow-auto rounded-sm border border-vuno-border";
|
|
20
|
-
/**
|
|
21
|
-
* El marco va en el contenedor y no en la `<table>`.
|
|
22
|
-
*
|
|
23
|
-
* Ponerlo en la tabla obliga a `border-separate` para que el radio
|
|
24
|
-
* no lo ignore el navegador, y en ese modo el navegador **también**
|
|
25
|
-
* ignora los bordes declarados en `<tr>`, que es donde Nuxt UI pone
|
|
26
|
-
* la línea entre filas: el marco salía y las divisiones
|
|
27
|
-
* desaparecían, sin ningún error de por medio.
|
|
28
|
-
*
|
|
29
|
-
* Aquí la tabla se queda colapsada —sus líneas vuelven— y el radio
|
|
30
|
-
* recorta porque el contenedor ya tiene `overflow` propio para el
|
|
31
|
-
* desplazamiento horizontal.
|
|
32
|
-
*/
|
|
33
|
-
/**
|
|
34
|
-
* Nuxt UI solo aplica hover a las filas con `data-selectable`, que
|
|
35
|
-
* son las que reciben un manejador de selección. Aquí se aplica
|
|
36
|
-
* siempre, y con su misma utilidad semántica para que el color lo
|
|
37
|
-
* siga decidiendo el tema del proyecto.
|
|
38
|
-
*/
|
|
15
|
+
readonly tableRoot: "relative isolate overflow-auto rounded-sm border border-vuno-border";
|
|
39
16
|
readonly tbody: "[&>tr]:transition-colors [&>tr]:hover:bg-vuno-surface-1";
|
|
40
17
|
readonly td: "p-4 text-sm whitespace-nowrap text-vuno-muted";
|
|
41
18
|
readonly th: "px-4 py-3.5 text-start text-sm font-semibold text-vuno-strong";
|
|
42
19
|
readonly thead: "";
|
|
43
|
-
readonly
|
|
44
|
-
readonly toolbarActions: "flex items-center gap-2";
|
|
45
|
-
readonly tr: "border-b border-vuno-border transition-colors last:border-b-0 hover:bg-vuno-surface-1 data-[selected=true]:bg-vuno-primary/10";
|
|
20
|
+
readonly tr: "group/row border-b border-vuno-border transition-colors last:border-b-0 hover:bg-vuno-surface-1 data-[selected=true]:bg-vuno-primary/10";
|
|
46
21
|
};
|
|
47
22
|
readonly variants: {
|
|
23
|
+
readonly density: {
|
|
24
|
+
readonly compact: {
|
|
25
|
+
readonly td: "px-3 py-2 text-xs";
|
|
26
|
+
readonly th: "px-3 py-2 text-xs";
|
|
27
|
+
};
|
|
28
|
+
readonly default: {};
|
|
29
|
+
};
|
|
48
30
|
readonly radius: Record<import("../../types/base.js").VunoRadius, Record<"tableRoot", string>>;
|
|
49
31
|
};
|
|
50
32
|
}>;
|
|
@@ -1,64 +1,31 @@
|
|
|
1
|
-
import { radiusByStep
|
|
1
|
+
import { radiusByStep } from "#vuno/theme/shared";
|
|
2
2
|
import { defineTheme } from "#vuno/utils/theme";
|
|
3
3
|
export const tableTheme = defineTheme("table", {
|
|
4
4
|
slots: {
|
|
5
|
-
|
|
6
|
-
emptyCell: "px-4 py-6",
|
|
7
|
-
filtersBody: "flex flex-col gap-4",
|
|
8
|
-
filtersFooter: "flex items-center justify-between gap-2",
|
|
9
|
-
footer: "flex flex-wrap items-center justify-between gap-4 px-1",
|
|
5
|
+
caption: "px-4 py-3 text-start text-sm font-semibold text-vuno-strong",
|
|
6
|
+
emptyCell: "px-4 py-6 text-center text-sm text-vuno-muted",
|
|
10
7
|
headRow: "border-b border-vuno-border",
|
|
11
|
-
|
|
12
|
-
/*
|
|
13
|
-
* El ancho viaja por `ui` de instancia a propósito —pelea con el
|
|
14
|
-
* `w-full` del tema y puesto como clase convivirían los dos—, pero
|
|
15
|
-
* el valor sale de aquí en vez de estar escrito en la plantilla.
|
|
16
|
-
*/
|
|
17
|
-
pageSizeControl: "w-auto",
|
|
18
|
-
pageSizeSelect: "cursor-pointer bg-transparent py-1 pr-1 outline-none",
|
|
19
|
-
root: "flex w-full flex-col gap-4",
|
|
20
|
-
search: "w-full sm:max-w-xs",
|
|
8
|
+
interactiveRow: "cursor-pointer focus-visible:outline-2 focus-visible:outline-offset-[-2px] focus-visible:outline-vuno-primary",
|
|
21
9
|
selectCell: "w-0",
|
|
22
|
-
selection: "flex items-center justify-between gap-2 rounded-sm bg-vuno-primary/10 px-3 py-2 text-sm",
|
|
23
|
-
/* Ver `skipLink`: la clase está en un solo sitio para las tres. */
|
|
24
|
-
skip: skipLink,
|
|
25
|
-
/*
|
|
26
|
-
* El margen negativo cancela el relleno del botón para que la
|
|
27
|
-
* cabecera se alinee con el texto de la columna, así que depende del
|
|
28
|
-
* relleno de `baseButton`: un proyecto que cambie uno tiene que poder
|
|
29
|
-
* cambiar el otro.
|
|
30
|
-
*/
|
|
31
10
|
sortButton: "-mx-2",
|
|
11
|
+
stickyColumn: "sticky z-10 bg-vuno-surface after:pointer-events-none after:absolute after:inset-y-0 after:w-6 group-hover/row:bg-vuno-surface-1 group-data-[selected=true]/row:bg-[color-mix(in_oklch,var(--color-vuno-primary)_10%,var(--color-vuno-surface))]",
|
|
12
|
+
stickyColumnEnd: "end-0 after:-start-6 after:bg-linear-to-l after:from-vuno-surface after:to-transparent group-hover/row:after:from-vuno-surface-1 group-data-[selected=true]/row:after:from-[color-mix(in_oklch,var(--color-vuno-primary)_10%,var(--color-vuno-surface))]",
|
|
13
|
+
stickyColumnStart: "start-0 after:-end-6 after:bg-linear-to-r after:from-vuno-surface after:to-transparent group-hover/row:after:from-vuno-surface-1 group-data-[selected=true]/row:after:from-[color-mix(in_oklch,var(--color-vuno-primary)_10%,var(--color-vuno-surface))]",
|
|
14
|
+
stickyHeader: "sticky top-0 z-20 bg-vuno-surface",
|
|
15
|
+
stickyIntersection: "z-30",
|
|
32
16
|
table: "min-w-full",
|
|
33
|
-
tableRoot: "relative overflow-auto rounded-sm border border-vuno-border",
|
|
34
|
-
/**
|
|
35
|
-
* El marco va en el contenedor y no en la `<table>`.
|
|
36
|
-
*
|
|
37
|
-
* Ponerlo en la tabla obliga a `border-separate` para que el radio
|
|
38
|
-
* no lo ignore el navegador, y en ese modo el navegador **también**
|
|
39
|
-
* ignora los bordes declarados en `<tr>`, que es donde Nuxt UI pone
|
|
40
|
-
* la línea entre filas: el marco salía y las divisiones
|
|
41
|
-
* desaparecían, sin ningún error de por medio.
|
|
42
|
-
*
|
|
43
|
-
* Aquí la tabla se queda colapsada —sus líneas vuelven— y el radio
|
|
44
|
-
* recorta porque el contenedor ya tiene `overflow` propio para el
|
|
45
|
-
* desplazamiento horizontal.
|
|
46
|
-
*/
|
|
47
|
-
/**
|
|
48
|
-
* Nuxt UI solo aplica hover a las filas con `data-selectable`, que
|
|
49
|
-
* son las que reciben un manejador de selección. Aquí se aplica
|
|
50
|
-
* siempre, y con su misma utilidad semántica para que el color lo
|
|
51
|
-
* siga decidiendo el tema del proyecto.
|
|
52
|
-
*/
|
|
17
|
+
tableRoot: "relative isolate overflow-auto rounded-sm border border-vuno-border",
|
|
53
18
|
tbody: "[&>tr]:transition-colors [&>tr]:hover:bg-vuno-surface-1",
|
|
54
19
|
td: "p-4 text-sm whitespace-nowrap text-vuno-muted",
|
|
55
20
|
th: "px-4 py-3.5 text-start text-sm font-semibold text-vuno-strong",
|
|
56
21
|
thead: "",
|
|
57
|
-
|
|
58
|
-
toolbarActions: "flex items-center gap-2",
|
|
59
|
-
tr: "border-b border-vuno-border transition-colors last:border-b-0 hover:bg-vuno-surface-1 data-[selected=true]:bg-vuno-primary/10"
|
|
22
|
+
tr: "group/row border-b border-vuno-border transition-colors last:border-b-0 hover:bg-vuno-surface-1 data-[selected=true]:bg-vuno-primary/10"
|
|
60
23
|
},
|
|
61
24
|
variants: {
|
|
25
|
+
density: {
|
|
26
|
+
compact: { td: "px-3 py-2 text-xs", th: "px-3 py-2 text-xs" },
|
|
27
|
+
default: {}
|
|
28
|
+
},
|
|
62
29
|
radius: radiusByStep("tableRoot")
|
|
63
30
|
}
|
|
64
31
|
});
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { VunoRadius } from '#vuno/types/base';
|
|
2
|
+
import type { VunoUi } from '#vuno/types/slots';
|
|
3
|
+
import type { VunoTableDefinition, VunoTableRow } from '#vuno/types/table';
|
|
4
|
+
export type VunoTableProps<TRow extends VunoTableRow> = {
|
|
5
|
+
data: TRow[];
|
|
6
|
+
definition: VunoTableDefinition<TRow>;
|
|
7
|
+
radius?: VunoRadius;
|
|
8
|
+
ui?: VunoUi<'table'>;
|
|
9
|
+
};
|
|
File without changes
|