@indielayer/ui 1.0.9 → 1.1.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/LICENSE +1 -1
- package/README.md +2 -2
- package/{src/exports/nuxt.js → exports/nuxt.mjs} +1 -1
- package/{lib → exports}/nuxt.plugin.js +1 -1
- package/lib/_virtual/_plugin-vue_export-helper.js +9 -0
- package/lib/common/icons.js +18 -0
- package/lib/common/utils.d.ts +4 -0
- package/lib/common/utils.js +25 -0
- package/lib/components/alert/Alert.theme.d.ts +10 -8
- package/lib/components/alert/Alert.theme.js +41 -0
- package/lib/components/alert/Alert.vue.d.ts +33 -7
- package/lib/components/alert/Alert.vue.js +9 -0
- package/lib/components/alert/Alert.vue2.js +62 -0
- package/lib/components/alert/Alert.vue3.js +8 -0
- package/lib/components/alert/index.d.ts +3 -0
- package/lib/components/avatar/Avatar.theme.d.ts +13 -7
- package/lib/components/avatar/Avatar.theme.js +25 -0
- package/lib/components/avatar/Avatar.vue.d.ts +32 -3
- package/lib/components/avatar/Avatar.vue.js +9 -0
- package/lib/components/avatar/Avatar.vue2.js +76 -0
- package/lib/components/avatar/Avatar.vue3.js +7 -0
- package/lib/components/avatar/index.d.ts +3 -0
- package/lib/components/badge/Badge.theme.d.ts +10 -8
- package/lib/components/badge/Badge.theme.js +12 -0
- package/lib/components/badge/Badge.vue.d.ts +54 -9
- package/lib/components/badge/Badge.vue.js +94 -0
- package/lib/components/badge/Badge.vue2.js +4 -0
- package/lib/components/badge/index.d.ts +3 -0
- package/lib/components/breadcrumbs/Breadcrumbs.theme.d.ts +10 -8
- package/lib/components/breadcrumbs/Breadcrumbs.theme.js +10 -0
- package/lib/components/breadcrumbs/Breadcrumbs.vue.d.ts +20 -6
- package/lib/components/breadcrumbs/Breadcrumbs.vue.js +79 -0
- package/lib/components/breadcrumbs/Breadcrumbs.vue2.js +4 -0
- package/lib/components/breadcrumbs/index.d.ts +3 -0
- package/lib/components/button/Button.theme.d.ts +12 -9
- package/lib/components/button/Button.theme.js +138 -0
- package/lib/components/button/Button.vue.d.ts +49 -8
- package/lib/components/button/Button.vue.js +9 -0
- package/lib/components/button/Button.vue2.js +115 -0
- package/lib/components/button/Button.vue3.js +8 -0
- package/lib/components/button/ButtonGroup.theme.d.ts +12 -5
- package/lib/components/button/ButtonGroup.theme.js +8 -0
- package/lib/components/button/ButtonGroup.vue.d.ts +44 -6
- package/lib/components/button/ButtonGroup.vue.js +9 -0
- package/lib/components/button/ButtonGroup.vue2.js +54 -0
- package/lib/components/button/ButtonGroup.vue3.js +7 -0
- package/lib/components/button/index.d.ts +6 -0
- package/lib/components/card/Card.theme.d.ts +10 -7
- package/lib/components/card/Card.theme.js +8 -0
- package/lib/components/card/Card.vue.d.ts +17 -1
- package/lib/components/card/Card.vue.js +31 -0
- package/lib/components/card/Card.vue2.js +4 -0
- package/lib/components/card/index.d.ts +3 -0
- package/lib/components/checkbox/Checkbox.theme.d.ts +13 -10
- package/lib/components/checkbox/Checkbox.theme.js +52 -0
- package/lib/components/checkbox/Checkbox.vue.d.ts +46 -7
- package/lib/components/checkbox/Checkbox.vue.js +9 -0
- package/lib/components/checkbox/Checkbox.vue2.js +108 -0
- package/lib/components/checkbox/Checkbox.vue3.js +6 -0
- package/lib/components/checkbox/index.d.ts +3 -0
- package/lib/components/collapse/Collapse.theme.d.ts +10 -9
- package/lib/components/collapse/Collapse.theme.js +10 -0
- package/lib/components/collapse/Collapse.vue.d.ts +32 -2
- package/lib/components/collapse/Collapse.vue.js +132 -0
- package/lib/components/collapse/Collapse.vue2.js +4 -0
- package/lib/components/collapse/index.d.ts +3 -0
- package/lib/components/container/Container.theme.d.ts +10 -6
- package/lib/components/container/Container.theme.js +8 -0
- package/lib/components/container/Container.vue.d.ts +16 -1
- package/lib/components/container/Container.vue.js +30 -0
- package/lib/components/container/Container.vue2.js +4 -0
- package/lib/components/container/index.d.ts +3 -0
- package/lib/components/divider/Divider.theme.d.ts +10 -9
- package/lib/components/divider/Divider.theme.js +10 -0
- package/lib/components/divider/Divider.vue.d.ts +7 -1
- package/lib/components/divider/Divider.vue.js +53 -0
- package/lib/components/divider/Divider.vue2.js +4 -0
- package/lib/components/divider/index.d.ts +3 -0
- package/lib/components/drawer/Drawer.theme.d.ts +10 -7
- package/lib/components/drawer/Drawer.theme.js +9 -0
- package/lib/components/drawer/Drawer.vue.d.ts +50 -14
- package/lib/components/drawer/Drawer.vue.js +171 -0
- package/lib/components/drawer/Drawer.vue2.js +4 -0
- package/lib/components/drawer/index.d.ts +3 -0
- package/lib/components/form/Form.theme.d.ts +10 -6
- package/lib/components/form/Form.theme.js +8 -0
- package/lib/components/form/Form.vue.d.ts +34 -6
- package/lib/components/form/Form.vue.js +79 -0
- package/lib/components/form/Form.vue2.js +4 -0
- package/lib/components/form/index.d.ts +3 -0
- package/lib/components/helpers/InputError.d.ts +2 -2
- package/lib/components/helpers/InputError.js +18 -0
- package/lib/components/icon/Icon.theme.d.ts +10 -7
- package/lib/components/icon/Icon.theme.js +11 -0
- package/lib/components/icon/Icon.vue.d.ts +22 -4
- package/lib/components/icon/Icon.vue.js +74 -0
- package/lib/components/icon/Icon.vue2.js +4 -0
- package/lib/components/icon/index.d.ts +3 -0
- package/lib/components/image/Image.theme.d.ts +10 -6
- package/lib/components/image/Image.theme.js +8 -0
- package/lib/components/image/Image.vue.d.ts +6 -1
- package/lib/components/image/Image.vue.js +32 -0
- package/lib/components/image/Image.vue2.js +4 -0
- package/lib/components/image/index.d.ts +3 -0
- package/lib/components/index.d.ts +35 -45
- package/lib/components/index.js +92 -0
- package/lib/components/input/Input.theme.d.ts +12 -10
- package/lib/components/input/Input.theme.js +21 -0
- package/lib/components/input/Input.vue.d.ts +73 -22
- package/lib/components/input/Input.vue.js +140 -0
- package/lib/components/input/Input.vue2.js +4 -0
- package/lib/components/input/index.d.ts +3 -0
- package/lib/components/link/Link.theme.d.ts +10 -8
- package/lib/components/link/Link.theme.js +25 -0
- package/lib/components/link/Link.vue.d.ts +25 -2
- package/lib/components/link/Link.vue.js +9 -0
- package/lib/components/link/Link.vue2.js +48 -0
- package/lib/components/link/Link.vue3.js +8 -0
- package/lib/components/link/index.d.ts +3 -0
- package/lib/components/menu/Menu.theme.d.ts +10 -6
- package/lib/components/menu/Menu.theme.js +8 -0
- package/lib/components/menu/Menu.vue.d.ts +62 -9
- package/lib/components/menu/Menu.vue.js +133 -0
- package/lib/components/menu/Menu.vue2.js +4 -0
- package/lib/components/menu/MenuItem.theme.d.ts +13 -7
- package/lib/components/menu/MenuItem.theme.js +86 -0
- package/lib/components/menu/MenuItem.vue.d.ts +63 -14
- package/lib/components/menu/MenuItem.vue.js +9 -0
- package/lib/components/menu/MenuItem.vue2.js +143 -0
- package/lib/components/menu/MenuItem.vue3.js +7 -0
- package/lib/components/menu/index.d.ts +6 -0
- package/lib/components/modal/Modal.theme.d.ts +10 -13
- package/lib/components/modal/Modal.theme.js +17 -0
- package/lib/components/modal/Modal.vue.d.ts +24 -2
- package/lib/components/modal/Modal.vue.js +127 -0
- package/lib/components/modal/Modal.vue2.js +4 -0
- package/lib/components/modal/index.d.ts +3 -0
- package/lib/components/notifications/Notifications.theme.d.ts +10 -8
- package/lib/components/notifications/Notifications.theme.js +10 -0
- package/lib/components/notifications/Notifications.vue.d.ts +56 -16
- package/lib/components/notifications/Notifications.vue.js +234 -0
- package/lib/components/notifications/Notifications.vue2.js +4 -0
- package/lib/components/notifications/index.d.ts +3 -0
- package/lib/components/pagination/Pagination.theme.d.ts +10 -9
- package/lib/components/pagination/Pagination.theme.js +13 -0
- package/lib/components/pagination/Pagination.vue.d.ts +28 -5
- package/lib/components/pagination/Pagination.vue.js +131 -0
- package/lib/components/pagination/Pagination.vue2.js +4 -0
- package/lib/components/pagination/PaginationItem.theme.d.ts +10 -7
- package/lib/components/pagination/PaginationItem.theme.js +8 -0
- package/lib/components/pagination/PaginationItem.vue.d.ts +17 -2
- package/lib/components/pagination/PaginationItem.vue.js +48 -0
- package/lib/components/pagination/PaginationItem.vue2.js +4 -0
- package/lib/components/pagination/index.d.ts +6 -0
- package/lib/components/popover/Popover.theme.d.ts +10 -7
- package/lib/components/popover/Popover.theme.js +9 -0
- package/lib/components/popover/Popover.vue.d.ts +48 -10
- package/lib/components/popover/Popover.vue.js +9 -0
- package/lib/components/popover/Popover.vue2.js +106 -0
- package/lib/components/popover/Popover.vue3.js +15 -0
- package/lib/components/popover/PopoverContainer.theme.d.ts +10 -6
- package/lib/components/popover/PopoverContainer.theme.js +8 -0
- package/lib/components/popover/PopoverContainer.vue.d.ts +16 -1
- package/lib/components/popover/PopoverContainer.vue.js +30 -0
- package/lib/components/popover/PopoverContainer.vue2.js +4 -0
- package/lib/components/popover/index.d.ts +6 -0
- package/lib/components/progress/Progress.theme.d.ts +10 -10
- package/lib/components/progress/Progress.theme.js +18 -0
- package/lib/components/progress/Progress.vue.d.ts +21 -2
- package/lib/components/progress/Progress.vue.js +51 -0
- package/lib/components/progress/Progress.vue2.js +4 -0
- package/lib/components/progress/index.d.ts +3 -0
- package/lib/components/radio/Radio.theme.d.ts +13 -11
- package/lib/components/radio/Radio.theme.js +67 -0
- package/lib/components/radio/Radio.vue.d.ts +48 -9
- package/lib/components/radio/Radio.vue.js +9 -0
- package/lib/components/radio/Radio.vue2.js +117 -0
- package/lib/components/radio/Radio.vue3.js +10 -0
- package/lib/components/radio/index.d.ts +3 -0
- package/lib/components/scroll/Scroll.theme.d.ts +10 -6
- package/lib/components/scroll/Scroll.theme.js +8 -0
- package/lib/components/scroll/Scroll.vue.d.ts +20 -2
- package/lib/components/scroll/Scroll.vue.js +9 -0
- package/lib/components/scroll/Scroll.vue2.js +64 -0
- package/lib/components/scroll/Scroll.vue3.js +17 -0
- package/lib/components/scroll/index.d.ts +3 -0
- package/lib/components/select/Select.theme.d.ts +13 -12
- package/lib/components/select/Select.theme.js +23 -0
- package/lib/components/select/Select.vue.d.ts +44 -8
- package/lib/components/select/Select.vue.js +269 -0
- package/lib/components/select/Select.vue2.js +4 -0
- package/lib/components/select/index.d.ts +3 -0
- package/lib/components/skeleton/Skeleton.theme.d.ts +10 -6
- package/lib/components/skeleton/Skeleton.theme.js +8 -0
- package/lib/components/skeleton/Skeleton.vue.d.ts +9 -1
- package/lib/components/skeleton/Skeleton.vue.js +30 -0
- package/lib/components/skeleton/Skeleton.vue2.js +4 -0
- package/lib/components/skeleton/index.d.ts +3 -0
- package/lib/components/slider/Slider.theme.d.ts +10 -10
- package/lib/components/slider/Slider.theme.js +20 -0
- package/lib/components/slider/Slider.vue.d.ts +55 -7
- package/lib/components/slider/Slider.vue.js +148 -0
- package/lib/components/slider/Slider.vue2.js +4 -0
- package/lib/components/slider/index.d.ts +2 -0
- package/lib/components/spacer/Spacer.d.ts +1 -1
- package/lib/components/spacer/Spacer.js +12 -0
- package/lib/components/spacer/index.d.ts +1 -0
- package/lib/components/spinner/Spinner.vue.d.ts +14 -1
- package/lib/components/spinner/Spinner.vue.js +28 -0
- package/lib/components/spinner/Spinner.vue2.js +4 -0
- package/lib/components/spinner/index.d.ts +2 -0
- package/lib/components/tab/Tab.theme.d.ts +12 -9
- package/lib/components/tab/Tab.theme.js +13 -0
- package/lib/components/tab/Tab.vue.d.ts +44 -9
- package/lib/components/tab/Tab.vue.js +129 -0
- package/lib/components/tab/Tab.vue2.js +4 -0
- package/lib/components/tab/TabGroup.theme.d.ts +10 -10
- package/lib/components/tab/TabGroup.theme.js +27 -0
- package/lib/components/tab/TabGroup.vue.d.ts +61 -9
- package/lib/components/tab/TabGroup.vue.js +133 -0
- package/lib/components/tab/TabGroup.vue2.js +4 -0
- package/lib/components/tab/index.d.ts +4 -0
- package/lib/components/table/Table.theme.d.ts +10 -8
- package/lib/components/table/Table.theme.js +12 -0
- package/lib/components/table/Table.vue.d.ts +269 -51
- package/lib/components/table/Table.vue.js +147 -0
- package/lib/components/table/Table.vue2.js +4 -0
- package/lib/components/table/TableBody.d.ts +1 -1
- package/lib/components/table/TableBody.js +15 -0
- package/lib/components/table/TableCell.theme.d.ts +10 -7
- package/lib/components/table/TableCell.theme.js +11 -0
- package/lib/components/table/TableCell.vue.d.ts +35 -6
- package/lib/components/table/TableCell.vue.js +43 -0
- package/lib/components/table/TableCell.vue2.js +4 -0
- package/lib/components/table/TableHead.d.ts +1 -1
- package/lib/components/table/TableHead.js +19 -0
- package/lib/components/table/TableHeader.vue.d.ts +34 -9
- package/lib/components/table/TableHeader.vue.js +78 -0
- package/lib/components/table/TableHeader.vue2.js +4 -0
- package/lib/components/table/TableRow.vue.d.ts +8 -1
- package/lib/components/table/TableRow.vue.js +32 -0
- package/lib/components/table/TableRow.vue2.js +4 -0
- package/lib/components/table/index.d.ts +9 -0
- package/lib/components/tag/Tag.theme.d.ts +10 -9
- package/lib/components/tag/Tag.theme.js +23 -0
- package/lib/components/tag/Tag.vue.d.ts +31 -4
- package/lib/components/tag/Tag.vue.js +61 -0
- package/lib/components/tag/Tag.vue2.js +4 -0
- package/lib/components/tag/index.d.ts +2 -0
- package/lib/components/textarea/Textarea.theme.d.ts +13 -9
- package/lib/components/textarea/Textarea.theme.js +16 -0
- package/lib/components/textarea/Textarea.vue.d.ts +59 -17
- package/lib/components/textarea/Textarea.vue.js +110 -0
- package/lib/components/textarea/Textarea.vue2.js +4 -0
- package/lib/components/textarea/index.d.ts +2 -0
- package/lib/components/toggle/Toggle.theme.d.ts +10 -11
- package/lib/components/toggle/Toggle.theme.js +29 -0
- package/lib/components/toggle/Toggle.vue.d.ts +39 -7
- package/lib/components/toggle/Toggle.vue.js +110 -0
- package/lib/components/toggle/Toggle.vue2.js +4 -0
- package/lib/components/toggle/index.d.ts +2 -0
- package/lib/components/tooltip/Tooltip.vue.d.ts +12 -1
- package/lib/components/tooltip/Tooltip.vue.js +27 -0
- package/lib/components/tooltip/Tooltip.vue2.js +4 -0
- package/lib/components/tooltip/index.d.ts +2 -0
- package/lib/composables/colors-utils.js +19 -0
- package/lib/composables/colors.d.ts +6 -4
- package/lib/composables/colors.js +52 -0
- package/lib/composables/common.d.ts +1 -1
- package/lib/composables/common.js +17 -0
- package/lib/composables/css.d.ts +1 -1
- package/lib/composables/css.js +26 -0
- package/lib/composables/inputtable.d.ts +4 -4
- package/lib/composables/inputtable.js +78 -0
- package/lib/composables/interactive.js +17 -0
- package/lib/composables/keys.d.ts +6 -3
- package/lib/composables/keys.js +10 -0
- package/lib/composables/notifications.d.ts +1 -1
- package/lib/composables/notifications.js +9 -0
- package/lib/composables/theme.d.ts +13 -7
- package/lib/composables/theme.js +59 -0
- package/lib/create.d.ts +1 -1
- package/lib/create.js +19 -0
- package/lib/index.js +121 -0
- package/lib/index.umd.js +1 -0
- package/lib/install.js +10 -0
- package/lib/node_modules/.pnpm/@vueuse_core@10.2.0_vue@3.3.4/node_modules/@vueuse/core/index.js +379 -0
- package/lib/node_modules/.pnpm/@vueuse_shared@10.2.0_vue@3.3.4/node_modules/@vueuse/shared/index.js +90 -0
- package/lib/version.d.ts +1 -1
- package/lib/version.js +4 -0
- package/package.json +54 -54
- package/src/common/utils.ts +25 -2
- package/src/components/alert/Alert.theme.ts +15 -6
- package/src/components/alert/Alert.vue +26 -13
- package/src/components/alert/index.ts +3 -0
- package/src/components/avatar/Avatar.theme.ts +16 -4
- package/src/components/avatar/Avatar.vue +20 -15
- package/src/components/avatar/index.ts +3 -0
- package/src/components/badge/Badge.theme.ts +13 -3
- package/src/components/badge/Badge.vue +30 -15
- package/src/components/badge/index.ts +3 -0
- package/src/components/breadcrumbs/Breadcrumbs.theme.ts +12 -2
- package/src/components/breadcrumbs/Breadcrumbs.vue +24 -21
- package/src/components/breadcrumbs/index.ts +3 -0
- package/src/components/button/Button.theme.ts +23 -19
- package/src/components/button/Button.vue +30 -19
- package/src/components/button/ButtonGroup.theme.ts +14 -1
- package/src/components/button/ButtonGroup.vue +33 -19
- package/src/components/button/index.ts +7 -0
- package/src/components/card/Card.theme.ts +13 -3
- package/src/components/card/Card.vue +12 -7
- package/src/components/card/index.ts +3 -0
- package/src/components/checkbox/Checkbox.theme.ts +19 -7
- package/src/components/checkbox/Checkbox.vue +21 -12
- package/src/components/checkbox/index.ts +3 -0
- package/src/components/collapse/Collapse.theme.ts +13 -3
- package/src/components/collapse/Collapse.vue +28 -24
- package/src/components/collapse/index.ts +3 -0
- package/src/components/container/Container.theme.ts +12 -2
- package/src/components/container/Container.vue +11 -6
- package/src/components/container/index.ts +3 -0
- package/src/components/divider/Divider.theme.ts +13 -3
- package/src/components/divider/Divider.vue +9 -4
- package/src/components/divider/index.ts +3 -0
- package/src/components/drawer/Drawer.theme.ts +12 -2
- package/src/components/drawer/Drawer.vue +50 -41
- package/src/components/drawer/index.ts +3 -0
- package/src/components/form/Form.theme.ts +12 -2
- package/src/components/form/Form.vue +40 -31
- package/src/components/form/index.ts +3 -0
- package/src/components/helpers/InputError.tsx +2 -2
- package/src/components/icon/Icon.theme.ts +13 -3
- package/src/components/icon/Icon.vue +24 -15
- package/src/components/icon/__tests__/Icon.spec.ts +5 -1
- package/src/components/icon/index.ts +3 -0
- package/src/components/image/Image.theme.ts +12 -2
- package/src/components/image/Image.vue +8 -4
- package/src/components/image/index.ts +3 -0
- package/src/components/index.ts +35 -45
- package/src/components/input/Input.theme.ts +17 -6
- package/src/components/input/Input.vue +33 -22
- package/src/components/input/index.ts +3 -0
- package/src/components/link/Link.theme.ts +13 -3
- package/src/components/link/Link.vue +20 -12
- package/src/components/link/index.ts +3 -0
- package/src/components/menu/Menu.theme.ts +12 -2
- package/src/components/menu/Menu.vue +59 -23
- package/src/components/menu/MenuItem.theme.ts +17 -5
- package/src/components/menu/MenuItem.vue +65 -52
- package/src/components/menu/index.ts +7 -0
- package/src/components/modal/Modal.theme.ts +13 -3
- package/src/components/modal/Modal.vue +23 -12
- package/src/components/modal/index.ts +3 -0
- package/src/components/notifications/Notifications.theme.ts +12 -2
- package/src/components/notifications/Notifications.vue +53 -49
- package/src/components/notifications/index.ts +9 -0
- package/src/components/pagination/Pagination.theme.ts +15 -5
- package/src/components/pagination/Pagination.vue +24 -18
- package/src/components/pagination/PaginationItem.theme.ts +13 -3
- package/src/components/pagination/PaginationItem.vue +14 -10
- package/src/components/pagination/index.ts +7 -0
- package/src/components/popover/Popover.theme.ts +12 -2
- package/src/components/popover/Popover.vue +56 -46
- package/src/components/popover/PopoverContainer.theme.ts +12 -2
- package/src/components/popover/PopoverContainer.vue +11 -6
- package/src/components/popover/index.ts +7 -0
- package/src/components/progress/Progress.theme.ts +14 -4
- package/src/components/progress/Progress.vue +16 -16
- package/src/components/progress/index.ts +3 -0
- package/src/components/radio/Radio.theme.ts +19 -7
- package/src/components/radio/Radio.vue +24 -14
- package/src/components/radio/index.ts +3 -0
- package/src/components/scroll/Scroll.theme.ts +12 -2
- package/src/components/scroll/Scroll.vue +37 -26
- package/src/components/scroll/index.ts +3 -0
- package/src/components/select/Select.theme.ts +20 -6
- package/src/components/select/Select.vue +28 -20
- package/src/components/select/index.ts +3 -0
- package/src/components/skeleton/Skeleton.theme.ts +12 -2
- package/src/components/skeleton/Skeleton.vue +11 -6
- package/src/components/skeleton/index.ts +3 -0
- package/src/components/slider/Slider.theme.ts +14 -4
- package/src/components/slider/Slider.vue +24 -16
- package/src/components/slider/index.ts +2 -0
- package/src/components/spacer/index.ts +1 -0
- package/src/components/spinner/Spinner.vue +18 -8
- package/src/components/spinner/index.ts +2 -0
- package/src/components/tab/Tab.theme.ts +15 -3
- package/src/components/tab/Tab.vue +85 -68
- package/src/components/tab/TabGroup.theme.ts +15 -5
- package/src/components/tab/TabGroup.vue +67 -22
- package/src/components/tab/index.ts +5 -0
- package/src/components/table/Table.theme.ts +14 -4
- package/src/components/table/Table.vue +41 -31
- package/src/components/table/TableCell.theme.ts +13 -3
- package/src/components/table/TableCell.vue +22 -16
- package/src/components/table/TableHeader.vue +20 -17
- package/src/components/table/TableRow.vue +1 -1
- package/src/components/table/index.ts +10 -0
- package/src/components/tag/Tag.theme.ts +14 -4
- package/src/components/tag/Tag.vue +22 -13
- package/src/components/tag/index.ts +2 -0
- package/src/components/textarea/Textarea.theme.ts +18 -30
- package/src/components/textarea/Textarea.vue +28 -19
- package/src/components/textarea/index.ts +2 -0
- package/src/components/toggle/Toggle.theme.ts +16 -6
- package/src/components/toggle/Toggle.vue +21 -12
- package/src/components/toggle/index.ts +2 -0
- package/src/components/tooltip/Tooltip.vue +5 -0
- package/src/components/tooltip/index.ts +2 -0
- package/src/composables/colors-utils.ts +4 -346
- package/src/composables/colors.ts +21 -17
- package/src/composables/common.ts +1 -1
- package/src/composables/css.ts +4 -4
- package/src/composables/inputtable.ts +8 -8
- package/src/composables/interactive.ts +2 -2
- package/src/composables/keys.ts +6 -3
- package/src/composables/theme.ts +30 -27
- package/src/create.ts +6 -7
- package/src/version.ts +1 -1
- package/volar.d.ts +0 -2
- package/lib/components/tooltip/Tooltip.theme.d.ts +0 -11
- package/lib/index.cjs.js +0 -1
- package/lib/index.es.js +0 -7184
- package/lib/nuxt.js +0 -33
- package/src/components/tooltip/Tooltip.theme.ts +0 -51
- package/src/exports/nuxt.plugin.js +0 -8
- package/src/exports/tailwind.preset.js +0 -55
- /package/{lib → exports}/tailwind.preset.js +0 -0
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
input: ({ props, data }: ThemeParams) => string[];
|
|
7
|
-
icon: string;
|
|
8
|
-
};
|
|
9
|
-
styles: ({ colors, props, css }: ThemeParams) => string;
|
|
1
|
+
import type { ThemeClasses, ThemeComponent } from '../../composables/theme';
|
|
2
|
+
import type { InputProps } from './Input.vue';
|
|
3
|
+
type InternalClasses = 'wrapper' | 'label' | 'input' | 'icon';
|
|
4
|
+
type InternalExtraData = {
|
|
5
|
+
errorInternal: any;
|
|
10
6
|
};
|
|
11
|
-
|
|
7
|
+
interface InternalTheme extends ThemeComponent<InputProps, InternalClasses, InternalExtraData> {
|
|
8
|
+
}
|
|
9
|
+
export interface InputTheme extends Omit<InternalTheme, 'classes'> {
|
|
10
|
+
classes?: Partial<ThemeClasses<InputProps, InternalClasses, InternalExtraData>>;
|
|
11
|
+
}
|
|
12
|
+
declare const theme: InternalTheme;
|
|
13
|
+
export default theme;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
const s = {
|
|
2
|
+
classes: {
|
|
3
|
+
wrapper: "inline-block align-bottom text-left",
|
|
4
|
+
label: ({ props: e }) => {
|
|
5
|
+
const r = "font-medium text-gray-800 dark:text-gray-200 mb-1";
|
|
6
|
+
return e.size === "xs" ? r + " text-xs" : e.size === "sm" ? r + " text-sm" : e.size === "lg" ? r + " text-lg" : e.size === "xl" ? r + " text-xl" : r;
|
|
7
|
+
},
|
|
8
|
+
input: ({ props: e, data: r }) => {
|
|
9
|
+
const t = ["appearance-none block w-full placeholder-gray-400 dark:placeholder-gray-500 outline-transparent outline outline-2 outline-offset-[-1px] transition-all duration-150 ease-in-out border-gray-300 dark:border-gray-700 border shadow-sm rounded-md"];
|
|
10
|
+
return !r.errorInternal && !e.disabled && t.push("hover:border-gray-400 dark:hover:border-gray-500"), e.size === "xs" ? t.push("px-2 py-1 text-xs") : e.size === "sm" ? t.push("px-2 py-2 text-sm") : e.size === "lg" ? t.push("px-4 py-3 text-lg") : e.size === "xl" ? t.push("px-5 py-4 text-xl") : t.push("px-3 py-2"), t.push(e.disabled ? "bg-gray-100 dark:bg-gray-900 text-gray-500 cursor-not-allowed" : "bg-white dark:bg-gray-800 text-gray-700 dark:text-gray-200"), t;
|
|
11
|
+
},
|
|
12
|
+
icon: "text-gray-600 dark:text-gray-300 absolute my-auto inset-y-0"
|
|
13
|
+
},
|
|
14
|
+
styles: ({ colors: e, props: r, css: t }) => {
|
|
15
|
+
const a = e.getPalette(r.color);
|
|
16
|
+
return t.get("border", a[400]);
|
|
17
|
+
}
|
|
18
|
+
}, l = s;
|
|
19
|
+
export {
|
|
20
|
+
l as default
|
|
21
|
+
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
import { type PropType, type ExtractPublicPropTypes } from 'vue';
|
|
2
|
+
declare const inputProps: {
|
|
2
3
|
showPasswordToggle: {
|
|
3
4
|
type: BooleanConstructor;
|
|
4
5
|
default: boolean;
|
|
@@ -6,23 +7,73 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
6
7
|
helper: StringConstructor;
|
|
7
8
|
label: StringConstructor;
|
|
8
9
|
dir: {
|
|
10
|
+
type: PropType<"ltr" | "rtl">;
|
|
11
|
+
default: string;
|
|
12
|
+
};
|
|
13
|
+
icon: StringConstructor;
|
|
14
|
+
iconLeft: StringConstructor;
|
|
15
|
+
iconRight: StringConstructor;
|
|
16
|
+
max: (StringConstructor | NumberConstructor)[];
|
|
17
|
+
maxlength: (StringConstructor | NumberConstructor)[];
|
|
18
|
+
min: (StringConstructor | NumberConstructor)[];
|
|
19
|
+
minlength: (StringConstructor | NumberConstructor)[];
|
|
20
|
+
placeholder: StringConstructor;
|
|
21
|
+
type: {
|
|
9
22
|
type: StringConstructor;
|
|
10
23
|
default: string;
|
|
11
24
|
};
|
|
25
|
+
block: BooleanConstructor;
|
|
26
|
+
modelValue: PropType<string | number | boolean | object | any[] | undefined>;
|
|
27
|
+
name: StringConstructor;
|
|
28
|
+
readonly: BooleanConstructor;
|
|
29
|
+
required: BooleanConstructor;
|
|
30
|
+
validateOnInput: {
|
|
31
|
+
readonly type: BooleanConstructor;
|
|
32
|
+
readonly default: true;
|
|
33
|
+
};
|
|
34
|
+
error: StringConstructor;
|
|
35
|
+
rules: {
|
|
36
|
+
readonly type: ArrayConstructor;
|
|
37
|
+
readonly default: () => never[];
|
|
38
|
+
};
|
|
39
|
+
disabled: BooleanConstructor;
|
|
40
|
+
loading: BooleanConstructor;
|
|
41
|
+
color: {
|
|
42
|
+
readonly type: StringConstructor;
|
|
43
|
+
readonly default: string | undefined;
|
|
44
|
+
};
|
|
45
|
+
size: {
|
|
46
|
+
readonly type: PropType<import("../../composables/common").Size>;
|
|
47
|
+
readonly default: "md";
|
|
48
|
+
readonly validator: (value: string) => boolean;
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
export type InputProps = ExtractPublicPropTypes<typeof inputProps>;
|
|
52
|
+
declare const _default: import("vue").DefineComponent<{
|
|
53
|
+
showPasswordToggle: {
|
|
54
|
+
type: BooleanConstructor;
|
|
55
|
+
default: boolean;
|
|
56
|
+
};
|
|
57
|
+
helper: StringConstructor;
|
|
58
|
+
label: StringConstructor;
|
|
59
|
+
dir: {
|
|
60
|
+
type: PropType<"ltr" | "rtl">;
|
|
61
|
+
default: string;
|
|
62
|
+
};
|
|
12
63
|
icon: StringConstructor;
|
|
13
64
|
iconLeft: StringConstructor;
|
|
14
65
|
iconRight: StringConstructor;
|
|
15
|
-
max: (
|
|
16
|
-
maxlength: (
|
|
17
|
-
min: (
|
|
18
|
-
minlength: (
|
|
66
|
+
max: (StringConstructor | NumberConstructor)[];
|
|
67
|
+
maxlength: (StringConstructor | NumberConstructor)[];
|
|
68
|
+
min: (StringConstructor | NumberConstructor)[];
|
|
69
|
+
minlength: (StringConstructor | NumberConstructor)[];
|
|
19
70
|
placeholder: StringConstructor;
|
|
20
71
|
type: {
|
|
21
72
|
type: StringConstructor;
|
|
22
73
|
default: string;
|
|
23
74
|
};
|
|
24
75
|
block: BooleanConstructor;
|
|
25
|
-
modelValue:
|
|
76
|
+
modelValue: PropType<string | number | boolean | object | any[] | undefined>;
|
|
26
77
|
name: StringConstructor;
|
|
27
78
|
readonly: BooleanConstructor;
|
|
28
79
|
required: BooleanConstructor;
|
|
@@ -42,7 +93,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
42
93
|
readonly default: string | undefined;
|
|
43
94
|
};
|
|
44
95
|
size: {
|
|
45
|
-
readonly type:
|
|
96
|
+
readonly type: PropType<import("../../composables/common").Size>;
|
|
46
97
|
readonly default: "md";
|
|
47
98
|
readonly validator: (value: string) => boolean;
|
|
48
99
|
};
|
|
@@ -50,7 +101,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
50
101
|
focus: () => void | undefined;
|
|
51
102
|
blur: () => void | undefined;
|
|
52
103
|
reset: () => void;
|
|
53
|
-
validate: (val
|
|
104
|
+
validate: (val?: any) => boolean;
|
|
54
105
|
setError: (val: string) => void;
|
|
55
106
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, string[], string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
56
107
|
showPasswordToggle: {
|
|
@@ -60,23 +111,23 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
60
111
|
helper: StringConstructor;
|
|
61
112
|
label: StringConstructor;
|
|
62
113
|
dir: {
|
|
63
|
-
type:
|
|
114
|
+
type: PropType<"ltr" | "rtl">;
|
|
64
115
|
default: string;
|
|
65
116
|
};
|
|
66
117
|
icon: StringConstructor;
|
|
67
118
|
iconLeft: StringConstructor;
|
|
68
119
|
iconRight: StringConstructor;
|
|
69
|
-
max: (
|
|
70
|
-
maxlength: (
|
|
71
|
-
min: (
|
|
72
|
-
minlength: (
|
|
120
|
+
max: (StringConstructor | NumberConstructor)[];
|
|
121
|
+
maxlength: (StringConstructor | NumberConstructor)[];
|
|
122
|
+
min: (StringConstructor | NumberConstructor)[];
|
|
123
|
+
minlength: (StringConstructor | NumberConstructor)[];
|
|
73
124
|
placeholder: StringConstructor;
|
|
74
125
|
type: {
|
|
75
126
|
type: StringConstructor;
|
|
76
127
|
default: string;
|
|
77
128
|
};
|
|
78
129
|
block: BooleanConstructor;
|
|
79
|
-
modelValue:
|
|
130
|
+
modelValue: PropType<string | number | boolean | object | any[] | undefined>;
|
|
80
131
|
name: StringConstructor;
|
|
81
132
|
readonly: BooleanConstructor;
|
|
82
133
|
required: BooleanConstructor;
|
|
@@ -96,24 +147,24 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
96
147
|
readonly default: string | undefined;
|
|
97
148
|
};
|
|
98
149
|
size: {
|
|
99
|
-
readonly type:
|
|
150
|
+
readonly type: PropType<import("../../composables/common").Size>;
|
|
100
151
|
readonly default: "md";
|
|
101
152
|
readonly validator: (value: string) => boolean;
|
|
102
153
|
};
|
|
103
154
|
}>> & {
|
|
104
|
-
[x:
|
|
155
|
+
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
105
156
|
}, {
|
|
106
|
-
|
|
107
|
-
size: import("../../composables/common").Size;
|
|
108
|
-
required: boolean;
|
|
157
|
+
disabled: boolean;
|
|
109
158
|
type: string;
|
|
159
|
+
dir: "ltr" | "rtl";
|
|
110
160
|
color: string;
|
|
111
|
-
|
|
161
|
+
size: import("../../composables/common").Size;
|
|
112
162
|
block: boolean;
|
|
113
|
-
|
|
163
|
+
required: boolean;
|
|
114
164
|
loading: boolean;
|
|
165
|
+
readonly: boolean;
|
|
115
166
|
validateOnInput: boolean;
|
|
116
167
|
rules: unknown[];
|
|
117
168
|
showPasswordToggle: boolean;
|
|
118
|
-
}>;
|
|
169
|
+
}, {}>;
|
|
119
170
|
export default _default;
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import { defineComponent as $, ref as h, watch as X, openBlock as l, createElementBlock as y, normalizeStyle as D, unref as r, normalizeClass as s, toDisplayString as F, createCommentVNode as p, createElementVNode as b, createBlock as u, mergeProps as H, toHandlers as j, createVNode as q } from "vue";
|
|
2
|
+
import { useTheme as A } from "../../composables/theme.js";
|
|
3
|
+
import { useColors as G } from "../../composables/colors.js";
|
|
4
|
+
import { useCommon as v } from "../../composables/common.js";
|
|
5
|
+
import { useInputtable as c } from "../../composables/inputtable.js";
|
|
6
|
+
import { useInteractive as S } from "../../composables/interactive.js";
|
|
7
|
+
import { eyeIcon as J, eyeVisibleIcon as K } from "../../common/icons.js";
|
|
8
|
+
import d from "../icon/Icon.vue.js";
|
|
9
|
+
import M from "../helpers/InputError.js";
|
|
10
|
+
import O from "./Input.theme.js";
|
|
11
|
+
const Q = ["textContent"], U = { class: "relative" }, W = ["disabled", "min", "max", "minlength", "maxlength", "dir", "name", "placeholder", "readonly", "type", "value"], Y = {
|
|
12
|
+
...v.props(),
|
|
13
|
+
...G.props("primary"),
|
|
14
|
+
...S.props(),
|
|
15
|
+
...c.props(),
|
|
16
|
+
showPasswordToggle: {
|
|
17
|
+
type: Boolean,
|
|
18
|
+
default: !0
|
|
19
|
+
},
|
|
20
|
+
helper: String,
|
|
21
|
+
label: String,
|
|
22
|
+
dir: {
|
|
23
|
+
type: String,
|
|
24
|
+
default: "ltr"
|
|
25
|
+
},
|
|
26
|
+
icon: String,
|
|
27
|
+
iconLeft: String,
|
|
28
|
+
iconRight: String,
|
|
29
|
+
max: [Number, String],
|
|
30
|
+
maxlength: [Number, String],
|
|
31
|
+
min: [Number, String],
|
|
32
|
+
minlength: [Number, String],
|
|
33
|
+
placeholder: String,
|
|
34
|
+
type: {
|
|
35
|
+
type: String,
|
|
36
|
+
default: "text"
|
|
37
|
+
},
|
|
38
|
+
block: Boolean
|
|
39
|
+
}, Z = {
|
|
40
|
+
name: "XInput",
|
|
41
|
+
validators: {
|
|
42
|
+
...v.validators()
|
|
43
|
+
}
|
|
44
|
+
}, ae = /* @__PURE__ */ $({
|
|
45
|
+
...Z,
|
|
46
|
+
props: Y,
|
|
47
|
+
emits: c.emits(),
|
|
48
|
+
setup(w, { expose: k, emit: z }) {
|
|
49
|
+
const o = w, f = h(null), i = h(o.type);
|
|
50
|
+
X(() => o.type, (e) => {
|
|
51
|
+
i.value = e;
|
|
52
|
+
});
|
|
53
|
+
function N(e) {
|
|
54
|
+
if (!e.target)
|
|
55
|
+
return;
|
|
56
|
+
const t = e.target;
|
|
57
|
+
if (o.type === "number") {
|
|
58
|
+
const m = Number(t.value);
|
|
59
|
+
typeof o.min < "u" && m < Number(o.min) && (t.value = o.min.toString()), typeof o.max < "u" && m > Number(o.max) && (t.value = o.max.toString());
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
function C() {
|
|
63
|
+
i.value = i.value === "password" ? "text" : "password";
|
|
64
|
+
}
|
|
65
|
+
const { focus: g, blur: I } = S(f), {
|
|
66
|
+
errorInternal: a,
|
|
67
|
+
isInsideForm: R,
|
|
68
|
+
inputListeners: V,
|
|
69
|
+
reset: B,
|
|
70
|
+
validate: L,
|
|
71
|
+
setError: P
|
|
72
|
+
} = c(o, { focus: g, emit: z }), { styles: E, classes: n, className: T } = A("input", O, o, { errorInternal: a });
|
|
73
|
+
return k({ focus: g, blur: I, reset: B, validate: L, setError: P }), (e, t) => (l(), y("label", {
|
|
74
|
+
style: D(r(E)),
|
|
75
|
+
class: s(["relative", [
|
|
76
|
+
r(T),
|
|
77
|
+
r(n).wrapper,
|
|
78
|
+
{ "mb-3": r(R), "w-full": e.block }
|
|
79
|
+
]])
|
|
80
|
+
}, [
|
|
81
|
+
e.label ? (l(), y("p", {
|
|
82
|
+
key: 0,
|
|
83
|
+
class: s(r(n).label),
|
|
84
|
+
textContent: F(e.label)
|
|
85
|
+
}, null, 10, Q)) : p("", !0),
|
|
86
|
+
b("div", U, [
|
|
87
|
+
e.iconLeft ? (l(), u(d, {
|
|
88
|
+
key: 0,
|
|
89
|
+
size: e.size,
|
|
90
|
+
icon: e.iconLeft,
|
|
91
|
+
class: s(["ml-2 left-1", r(n).icon])
|
|
92
|
+
}, null, 8, ["size", "icon", "class"])) : p("", !0),
|
|
93
|
+
b("input", H({
|
|
94
|
+
ref_key: "elRef",
|
|
95
|
+
ref: f,
|
|
96
|
+
class: [
|
|
97
|
+
r(n).input,
|
|
98
|
+
e.type === "password" ? "pr-10" : "",
|
|
99
|
+
// error
|
|
100
|
+
r(a) ? "border-red-500 dark:border-red-400 focus:outline-red-500" : "focus:outline-[color:var(--x-input-border)]",
|
|
101
|
+
{
|
|
102
|
+
"!pl-10": e.iconLeft,
|
|
103
|
+
"!pr-10": e.iconRight
|
|
104
|
+
}
|
|
105
|
+
],
|
|
106
|
+
disabled: e.disabled,
|
|
107
|
+
min: e.min,
|
|
108
|
+
max: e.max,
|
|
109
|
+
minlength: e.minlength,
|
|
110
|
+
maxlength: e.maxlength,
|
|
111
|
+
dir: e.dir,
|
|
112
|
+
name: e.name,
|
|
113
|
+
placeholder: e.placeholder,
|
|
114
|
+
readonly: e.readonly,
|
|
115
|
+
type: i.value,
|
|
116
|
+
value: e.modelValue || ""
|
|
117
|
+
}, e.$attrs, j(r(V), !0), { onChange: N }), null, 16, W),
|
|
118
|
+
e.iconRight ? (l(), u(d, {
|
|
119
|
+
key: 1,
|
|
120
|
+
size: e.size,
|
|
121
|
+
icon: e.iconRight,
|
|
122
|
+
class: s(["mr-2 right-1", r(n).icon])
|
|
123
|
+
}, null, 8, ["size", "icon", "class"])) : e.type === "password" && e.showPasswordToggle ? (l(), u(d, {
|
|
124
|
+
key: 2,
|
|
125
|
+
size: e.size,
|
|
126
|
+
icon: i.value === "password" ? r(J) : r(K),
|
|
127
|
+
class: s(["mr-2 right-1 cursor-pointer", r(n).icon]),
|
|
128
|
+
onClick: t[0] || (t[0] = (m) => C())
|
|
129
|
+
}, null, 8, ["size", "icon", "class"])) : p("", !0)
|
|
130
|
+
]),
|
|
131
|
+
q(r(M), {
|
|
132
|
+
error: r(a),
|
|
133
|
+
helper: e.helper
|
|
134
|
+
}, null, 8, ["error", "helper"])
|
|
135
|
+
], 6));
|
|
136
|
+
}
|
|
137
|
+
});
|
|
138
|
+
export {
|
|
139
|
+
ae as default
|
|
140
|
+
};
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
import type { ThemeClasses, ThemeComponent } from '../../composables/theme';
|
|
2
|
+
import type { LinkProps } from './Link.vue';
|
|
3
|
+
type InternalClasses = 'wrapper';
|
|
4
|
+
interface InternalTheme extends ThemeComponent<LinkProps, InternalClasses> {
|
|
5
|
+
}
|
|
6
|
+
export interface LinkTheme extends Omit<InternalTheme, 'classes'> {
|
|
7
|
+
classes?: Partial<ThemeClasses<LinkProps, InternalClasses>>;
|
|
8
|
+
}
|
|
9
|
+
declare const theme: InternalTheme;
|
|
10
|
+
export default theme;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
const a = {
|
|
2
|
+
classes: {
|
|
3
|
+
wrapper: "transition duration-300 ease-in-out cursor-pointer inline-flex"
|
|
4
|
+
},
|
|
5
|
+
styles: ({ colors: o, props: t, css: r }) => {
|
|
6
|
+
const e = o.getPalette(t.color || "gray");
|
|
7
|
+
return r.variables({
|
|
8
|
+
text: t.color ? e[600] : "",
|
|
9
|
+
hover: {
|
|
10
|
+
text: t.shadow ? "" : e[700]
|
|
11
|
+
},
|
|
12
|
+
shadow: e[100],
|
|
13
|
+
dark: {
|
|
14
|
+
text: t.color ? e[400] : "",
|
|
15
|
+
hover: {
|
|
16
|
+
text: e[300]
|
|
17
|
+
},
|
|
18
|
+
shadow: e[900]
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
}, s = a;
|
|
23
|
+
export {
|
|
24
|
+
s as default
|
|
25
|
+
};
|
|
@@ -1,4 +1,20 @@
|
|
|
1
|
-
|
|
1
|
+
import type { ExtractPublicPropTypes } from 'vue';
|
|
2
|
+
declare const linkProps: {
|
|
3
|
+
tag: {
|
|
4
|
+
type: StringConstructor;
|
|
5
|
+
default: string;
|
|
6
|
+
};
|
|
7
|
+
to: (ObjectConstructor | StringConstructor)[];
|
|
8
|
+
shadow: BooleanConstructor;
|
|
9
|
+
external: BooleanConstructor;
|
|
10
|
+
underline: BooleanConstructor;
|
|
11
|
+
color: {
|
|
12
|
+
readonly type: StringConstructor;
|
|
13
|
+
readonly default: string | undefined;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
export type LinkProps = ExtractPublicPropTypes<typeof linkProps>;
|
|
17
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
2
18
|
tag: {
|
|
3
19
|
type: StringConstructor;
|
|
4
20
|
default: string;
|
|
@@ -26,9 +42,16 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
26
42
|
};
|
|
27
43
|
}>>, {
|
|
28
44
|
color: string;
|
|
29
|
-
tag: string;
|
|
30
45
|
shadow: boolean;
|
|
46
|
+
tag: string;
|
|
31
47
|
external: boolean;
|
|
32
48
|
underline: boolean;
|
|
49
|
+
}, {}>, {
|
|
50
|
+
default?(_: {}): any;
|
|
33
51
|
}>;
|
|
34
52
|
export default _default;
|
|
53
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
54
|
+
new (): {
|
|
55
|
+
$slots: S;
|
|
56
|
+
};
|
|
57
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import s from "./Link.vue2.js";
|
|
2
|
+
import o from "./Link.vue3.js";
|
|
3
|
+
import t from "../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const e = {
|
|
5
|
+
$style: o
|
|
6
|
+
}, m = /* @__PURE__ */ t(s, [["__cssModules", e], ["__scopeId", "data-v-ea737659"]]);
|
|
7
|
+
export {
|
|
8
|
+
m as default
|
|
9
|
+
};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { defineComponent as m, openBlock as n, createBlock as p, resolveDynamicComponent as u, normalizeStyle as d, unref as o, normalizeClass as f, withCtx as c, createElementBlock as k, renderSlot as t, createVNode as y } from "vue";
|
|
2
|
+
import { useColors as h } from "../../composables/colors.js";
|
|
3
|
+
import { useTheme as g } from "../../composables/theme.js";
|
|
4
|
+
import { externalIcon as B } from "../../common/icons.js";
|
|
5
|
+
import w from "../icon/Icon.vue.js";
|
|
6
|
+
import C from "./Link.theme.js";
|
|
7
|
+
const $ = {
|
|
8
|
+
key: 0,
|
|
9
|
+
class: "inline-flex items-center"
|
|
10
|
+
}, S = {
|
|
11
|
+
...h.props(),
|
|
12
|
+
tag: {
|
|
13
|
+
type: String,
|
|
14
|
+
default: "a"
|
|
15
|
+
},
|
|
16
|
+
to: [String, Object],
|
|
17
|
+
shadow: Boolean,
|
|
18
|
+
external: Boolean,
|
|
19
|
+
underline: Boolean
|
|
20
|
+
}, v = { name: "XLink" }, L = /* @__PURE__ */ m({
|
|
21
|
+
...v,
|
|
22
|
+
props: S,
|
|
23
|
+
setup(l) {
|
|
24
|
+
const s = l, { styles: r, classes: a, className: i } = g("link", C, s);
|
|
25
|
+
return (e, z) => (n(), p(u(e.to ? e.tag !== "a" ? e.tag : "router-link" : e.tag), {
|
|
26
|
+
to: e.to,
|
|
27
|
+
style: d(o(r)),
|
|
28
|
+
class: f([
|
|
29
|
+
o(i),
|
|
30
|
+
e.$style.link,
|
|
31
|
+
o(a).wrapper,
|
|
32
|
+
[e.shadow ? e.$style["link--shadow"] : ""],
|
|
33
|
+
{ underline: e.underline }
|
|
34
|
+
])
|
|
35
|
+
}, {
|
|
36
|
+
default: c(() => [
|
|
37
|
+
e.external ? (n(), k("span", $, [
|
|
38
|
+
t(e.$slots, "default", {}, void 0, !0),
|
|
39
|
+
y(w, { icon: o(B) }, null, 8, ["icon"])
|
|
40
|
+
])) : t(e.$slots, "default", { key: 1 }, void 0, !0)
|
|
41
|
+
]),
|
|
42
|
+
_: 3
|
|
43
|
+
}, 8, ["to", "style", "class"]));
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
export {
|
|
47
|
+
L as default
|
|
48
|
+
};
|
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
}
|
|
6
|
-
export
|
|
1
|
+
import type { ThemeClasses, ThemeComponent } from '../../composables/theme';
|
|
2
|
+
import type { MenuProps } from './Menu.vue';
|
|
3
|
+
type InternalClasses = 'wrapper';
|
|
4
|
+
interface InternalTheme extends ThemeComponent<MenuProps, InternalClasses> {
|
|
5
|
+
}
|
|
6
|
+
export interface MenuTheme extends Omit<InternalTheme, 'classes'> {
|
|
7
|
+
classes?: Partial<ThemeClasses<MenuProps, InternalClasses>>;
|
|
8
|
+
}
|
|
9
|
+
declare const theme: InternalTheme;
|
|
10
|
+
export default theme;
|
|
@@ -1,6 +1,59 @@
|
|
|
1
|
-
import type { PropType } from 'vue';
|
|
1
|
+
import type { ExtractPublicPropTypes, PropType } from 'vue';
|
|
2
|
+
import { type Size } from '../../composables/common';
|
|
3
|
+
declare const menuProps: {
|
|
4
|
+
items: PropType<MenuArrayItem[]>;
|
|
5
|
+
collapsible: {
|
|
6
|
+
type: BooleanConstructor;
|
|
7
|
+
default: boolean;
|
|
8
|
+
};
|
|
9
|
+
collapseIcon: StringConstructor;
|
|
10
|
+
expanded: BooleanConstructor;
|
|
11
|
+
disabled: BooleanConstructor;
|
|
12
|
+
rounded: {
|
|
13
|
+
type: BooleanConstructor;
|
|
14
|
+
default: boolean;
|
|
15
|
+
};
|
|
16
|
+
filled: {
|
|
17
|
+
type: BooleanConstructor;
|
|
18
|
+
default: boolean;
|
|
19
|
+
};
|
|
20
|
+
color: {
|
|
21
|
+
readonly type: StringConstructor;
|
|
22
|
+
readonly default: string | undefined;
|
|
23
|
+
};
|
|
24
|
+
size: {
|
|
25
|
+
readonly type: PropType<Size>;
|
|
26
|
+
readonly default: "md";
|
|
27
|
+
readonly validator: (value: string) => boolean;
|
|
28
|
+
};
|
|
29
|
+
};
|
|
30
|
+
export type MenuArrayItem = {
|
|
31
|
+
collapsible?: boolean;
|
|
32
|
+
collapseIcon?: string;
|
|
33
|
+
expanded?: boolean;
|
|
34
|
+
divider?: boolean;
|
|
35
|
+
items?: MenuArrayItem[];
|
|
36
|
+
value?: string | number;
|
|
37
|
+
to?: string | object;
|
|
38
|
+
href?: string;
|
|
39
|
+
target?: string;
|
|
40
|
+
exact?: boolean;
|
|
41
|
+
color?: string;
|
|
42
|
+
size?: Size;
|
|
43
|
+
label?: string;
|
|
44
|
+
icon?: string;
|
|
45
|
+
iconRight?: string;
|
|
46
|
+
loading?: boolean;
|
|
47
|
+
rounded?: boolean;
|
|
48
|
+
filled?: boolean;
|
|
49
|
+
disabled?: boolean;
|
|
50
|
+
active?: boolean;
|
|
51
|
+
attrs?: Record<string, unknown>;
|
|
52
|
+
onClick?: (e: MouseEvent) => void;
|
|
53
|
+
};
|
|
54
|
+
export type MenuProps = ExtractPublicPropTypes<typeof menuProps>;
|
|
2
55
|
declare const _default: import("vue").DefineComponent<{
|
|
3
|
-
items: PropType<
|
|
56
|
+
items: PropType<MenuArrayItem[]>;
|
|
4
57
|
collapsible: {
|
|
5
58
|
type: BooleanConstructor;
|
|
6
59
|
default: boolean;
|
|
@@ -21,12 +74,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
21
74
|
readonly default: string | undefined;
|
|
22
75
|
};
|
|
23
76
|
size: {
|
|
24
|
-
readonly type: PropType<
|
|
77
|
+
readonly type: PropType<Size>;
|
|
25
78
|
readonly default: "md";
|
|
26
79
|
readonly validator: (value: string) => boolean;
|
|
27
80
|
};
|
|
28
81
|
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "expand"[], "expand", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
29
|
-
items: PropType<
|
|
82
|
+
items: PropType<MenuArrayItem[]>;
|
|
30
83
|
collapsible: {
|
|
31
84
|
type: BooleanConstructor;
|
|
32
85
|
default: boolean;
|
|
@@ -47,19 +100,19 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
47
100
|
readonly default: string | undefined;
|
|
48
101
|
};
|
|
49
102
|
size: {
|
|
50
|
-
readonly type: PropType<
|
|
103
|
+
readonly type: PropType<Size>;
|
|
51
104
|
readonly default: "md";
|
|
52
105
|
readonly validator: (value: string) => boolean;
|
|
53
106
|
};
|
|
54
107
|
}>> & {
|
|
55
108
|
onExpand?: ((...args: any[]) => any) | undefined;
|
|
56
109
|
}, {
|
|
57
|
-
|
|
58
|
-
filled: boolean;
|
|
110
|
+
disabled: boolean;
|
|
59
111
|
color: string;
|
|
112
|
+
size: Size;
|
|
60
113
|
rounded: boolean;
|
|
61
|
-
|
|
114
|
+
filled: boolean;
|
|
62
115
|
expanded: boolean;
|
|
63
116
|
collapsible: boolean;
|
|
64
|
-
}>;
|
|
117
|
+
}, {}>;
|
|
65
118
|
export default _default;
|