@skewedaspect/sleekspace-ui 0.2.0-beta.1 → 0.2.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Accordion/SkAccordion.vue.d.ts +65 -0
- package/dist/components/Accordion/SkAccordionItem.vue.d.ts +52 -0
- package/dist/components/Accordion/index.d.ts +3 -0
- package/dist/components/Accordion/types.d.ts +3 -0
- package/dist/components/Alert/SkAlert.vue.d.ts +39 -0
- package/dist/components/Alert/types.d.ts +4 -0
- package/dist/components/Avatar/SkAvatar.vue.d.ts +75 -0
- package/dist/components/Avatar/index.d.ts +2 -0
- package/dist/components/Avatar/types.d.ts +20 -0
- package/dist/components/Breadcrumbs/SkBreadcrumbItem.vue.d.ts +51 -0
- package/dist/components/Breadcrumbs/SkBreadcrumbSeparator.vue.d.ts +13 -0
- package/dist/components/Breadcrumbs/SkBreadcrumbs.vue.d.ts +24 -0
- package/dist/components/Breadcrumbs/index.d.ts +4 -0
- package/dist/components/Breadcrumbs/types.d.ts +18 -0
- package/dist/components/Button/SkButton.vue.d.ts +97 -0
- package/dist/components/Button/types.d.ts +5 -0
- package/dist/components/Card/SkCard.vue.d.ts +88 -0
- package/dist/components/Card/types.d.ts +2 -0
- package/dist/components/Checkbox/SkCheckbox.vue.d.ts +71 -0
- package/dist/components/Checkbox/index.d.ts +2 -0
- package/dist/components/Checkbox/types.d.ts +3 -0
- package/dist/components/Collapsible/SkCollapsible.vue.d.ts +70 -0
- package/dist/components/Collapsible/index.d.ts +2 -0
- package/dist/components/Collapsible/types.d.ts +2 -0
- package/dist/components/Divider/SkDivider.vue.d.ts +39 -0
- package/dist/components/Divider/types.d.ts +8 -0
- package/dist/components/Dropdown/SkDropdown.vue.d.ts +63 -0
- package/dist/components/Dropdown/SkDropdownMenuItem.vue.d.ts +32 -0
- package/dist/components/Dropdown/SkDropdownMenuSeparator.vue.d.ts +2 -0
- package/dist/components/Dropdown/SkDropdownSubmenu.vue.d.ts +34 -0
- package/dist/components/Dropdown/index.d.ts +5 -0
- package/dist/components/Dropdown/types.d.ts +4 -0
- package/dist/components/Field/SkField.vue.d.ts +99 -0
- package/dist/components/Field/index.d.ts +2 -0
- package/dist/components/Field/types.d.ts +1 -0
- package/dist/components/Group/SkGroup.vue.d.ts +29 -0
- package/dist/components/Group/types.d.ts +4 -0
- package/dist/components/Input/SkInput.vue.d.ts +84 -0
- package/dist/components/Input/index.d.ts +2 -0
- package/dist/components/Input/types.d.ts +4 -0
- package/dist/components/Listbox/SkListbox.vue.d.ts +62 -0
- package/dist/components/Listbox/SkListboxItem.vue.d.ts +34 -0
- package/dist/components/Listbox/SkListboxSeparator.vue.d.ts +2 -0
- package/dist/components/Listbox/index.d.ts +4 -0
- package/dist/components/Listbox/types.d.ts +3 -0
- package/dist/components/Modal/SkModal.vue.d.ts +108 -0
- package/dist/components/Modal/index.d.ts +2 -0
- package/dist/components/Modal/types.d.ts +3 -0
- package/dist/components/NavBar/SkNavBar.vue.d.ts +40 -0
- package/dist/components/NavBar/index.d.ts +2 -0
- package/dist/components/NavBar/types.d.ts +6 -0
- package/dist/components/NumberInput/SkNumberInput.vue.d.ts +93 -0
- package/dist/components/NumberInput/index.d.ts +2 -0
- package/dist/components/NumberInput/types.d.ts +3 -0
- package/dist/components/Page/SkPage.vue.d.ts +55 -0
- package/dist/components/Page/index.d.ts +2 -0
- package/dist/components/Page/types.d.ts +13 -0
- package/dist/components/Pagination/SkPagination.vue.d.ts +79 -0
- package/dist/components/Pagination/SkPaginationItem.vue.d.ts +44 -0
- package/dist/components/Pagination/index.d.ts +3 -0
- package/dist/components/Pagination/types.d.ts +24 -0
- package/dist/components/Panel/SkPanel.vue.d.ts +55 -0
- package/dist/components/Panel/types.d.ts +3 -0
- package/dist/components/Popover/SkPopover.vue.d.ts +94 -0
- package/dist/components/Popover/index.d.ts +2 -0
- package/dist/components/Popover/types.d.ts +4 -0
- package/dist/components/Progress/SkProgress.vue.d.ts +66 -0
- package/dist/components/Progress/index.d.ts +2 -0
- package/dist/components/Progress/types.d.ts +22 -0
- package/dist/components/Radio/SkRadio.vue.d.ts +59 -0
- package/dist/components/Radio/SkRadioGroup.vue.d.ts +85 -0
- package/dist/components/Radio/index.d.ts +3 -0
- package/dist/components/Radio/types.d.ts +4 -0
- package/dist/components/Sidebar/SkSidebar.vue.d.ts +38 -0
- package/dist/components/Sidebar/SkSidebarItem.vue.d.ts +37 -0
- package/dist/components/Sidebar/SkSidebarSection.vue.d.ts +44 -0
- package/dist/components/Sidebar/types.d.ts +2 -0
- package/dist/components/Skeleton/SkSkeleton.vue.d.ts +55 -0
- package/dist/components/Skeleton/index.d.ts +2 -0
- package/dist/components/Skeleton/types.d.ts +21 -0
- package/dist/components/Slider/SkSlider.vue.d.ts +100 -0
- package/dist/components/Slider/index.d.ts +2 -0
- package/dist/components/Slider/types.d.ts +32 -0
- package/dist/components/Spinner/SkSpinner.vue.d.ts +39 -0
- package/dist/components/Spinner/index.d.ts +2 -0
- package/dist/components/Spinner/types.d.ts +16 -0
- package/dist/components/Switch/SkSwitch.vue.d.ts +120 -0
- package/dist/components/Switch/index.d.ts +2 -0
- package/dist/components/Switch/types.d.ts +3 -0
- package/dist/components/Table/SkTable.vue.d.ts +86 -0
- package/dist/components/Table/index.d.ts +2 -0
- package/dist/components/Table/types.d.ts +3 -0
- package/dist/components/Tabs/SkTab.vue.d.ts +49 -0
- package/dist/components/Tabs/SkTabList.vue.d.ts +28 -0
- package/dist/components/Tabs/SkTabPanel.vue.d.ts +33 -0
- package/dist/components/Tabs/SkTabPanels.vue.d.ts +17 -0
- package/dist/components/Tabs/SkTabs.vue.d.ts +60 -0
- package/dist/components/Tabs/types.d.ts +5 -0
- package/dist/components/Tag/SkTag.vue.d.ts +58 -0
- package/dist/components/Tag/types.d.ts +8 -0
- package/dist/components/TagsInput/SkTagsInput.vue.d.ts +77 -0
- package/dist/components/TagsInput/index.d.ts +2 -0
- package/dist/components/TagsInput/types.d.ts +3 -0
- package/dist/components/Textarea/SkTextarea.vue.d.ts +85 -0
- package/dist/components/Textarea/index.d.ts +2 -0
- package/dist/components/Textarea/types.d.ts +3 -0
- package/dist/components/Theme/SkTheme.vue.d.ts +20 -0
- package/dist/components/Theme/types.d.ts +16 -0
- package/dist/components/Theme/useTheme.d.ts +84 -0
- package/dist/components/Toast/SkToast.vue.d.ts +42 -0
- package/dist/components/Toast/SkToastProvider.vue.d.ts +62 -0
- package/dist/components/Toast/index.d.ts +3 -0
- package/dist/components/Toast/types.d.ts +35 -0
- package/dist/components/Toast/useToast.d.ts +33 -0
- package/dist/components/Tooltip/SkTooltip.vue.d.ts +81 -0
- package/dist/components/Tooltip/SkTooltipProvider.vue.d.ts +70 -0
- package/dist/components/Tooltip/index.d.ts +3 -0
- package/dist/components/Tooltip/types.d.ts +4 -0
- package/dist/composables/useCustomColors.d.ts +74 -0
- package/dist/composables/useCustomColors.test.d.ts +1 -0
- package/dist/composables/usePortalContext.d.ts +75 -0
- package/dist/composables/usePortalContext.test.d.ts +1 -0
- package/dist/index.d.ts +149 -0
- package/dist/sleekspace-ui.css +2 -16
- package/dist/sleekspace-ui.es.js +43 -42
- package/dist/sleekspace-ui.umd.js +43 -42
- package/dist/tokens.css +968 -0
- package/dist/types.d.ts +29 -0
- package/docs/components/accordion/_meta.yaml +9 -0
- package/docs/components/accordion/custom-colors.md +20 -0
- package/docs/components/accordion/intro.md +8 -0
- package/docs/components/accordion/kinds.md +30 -0
- package/docs/components/accordion/multiple.md +28 -0
- package/docs/components/accordion/real-world.md +31 -0
- package/docs/components/accordion/usage.md +28 -0
- package/docs/components/alert/_meta.yaml +10 -0
- package/docs/components/alert/custom-colors.md +30 -0
- package/docs/components/alert/custom-icons.md +17 -0
- package/docs/components/alert/intro.md +8 -0
- package/docs/components/alert/kinds.md +24 -0
- package/docs/components/alert/prominent.md +16 -0
- package/docs/components/alert/rich-content.md +19 -0
- package/docs/components/alert/usage.md +12 -0
- package/docs/components/avatar/_meta.yaml +10 -0
- package/docs/components/avatar/custom-colors.md +14 -0
- package/docs/components/avatar/images.md +12 -0
- package/docs/components/avatar/intro.md +8 -0
- package/docs/components/avatar/kinds.md +16 -0
- package/docs/components/avatar/real-world.md +25 -0
- package/docs/components/avatar/sizes.md +14 -0
- package/docs/components/avatar/usage.md +15 -0
- package/docs/components/breadcrumbs/_meta.yaml +9 -0
- package/docs/components/breadcrumbs/custom-colors.md +14 -0
- package/docs/components/breadcrumbs/intro.md +8 -0
- package/docs/components/breadcrumbs/kinds.md +16 -0
- package/docs/components/breadcrumbs/real-world.md +33 -0
- package/docs/components/breadcrumbs/separators.md +13 -0
- package/docs/components/breadcrumbs/usage.md +15 -0
- package/docs/components/card/_meta.yaml +10 -0
- package/docs/components/card/intro.md +8 -0
- package/docs/components/card/kinds.md +24 -0
- package/docs/components/card/media.md +25 -0
- package/docs/components/card/neon-kinds.md +24 -0
- package/docs/components/card/no-decoration.md +15 -0
- package/docs/components/card/scrollable.md +23 -0
- package/docs/components/card/usage.md +12 -0
- package/docs/components/checkbox/_meta.yaml +11 -0
- package/docs/components/checkbox/color-kinds.md +17 -0
- package/docs/components/checkbox/custom-colors.md +21 -0
- package/docs/components/checkbox/form-example.md +24 -0
- package/docs/components/checkbox/intro.md +8 -0
- package/docs/components/checkbox/kinds.md +16 -0
- package/docs/components/checkbox/sizes.md +13 -0
- package/docs/components/checkbox/states.md +14 -0
- package/docs/components/checkbox/usage.md +17 -0
- package/docs/components/collapsible/_meta.yaml +9 -0
- package/docs/components/collapsible/accessibility.md +6 -0
- package/docs/components/collapsible/custom-colors.md +16 -0
- package/docs/components/collapsible/custom-trigger.md +35 -0
- package/docs/components/collapsible/intro.md +8 -0
- package/docs/components/collapsible/kinds.md +16 -0
- package/docs/components/collapsible/usage.md +22 -0
- package/docs/components/divider/_meta.yaml +10 -0
- package/docs/components/divider/accessibility.md +6 -0
- package/docs/components/divider/intro.md +8 -0
- package/docs/components/divider/kinds.md +16 -0
- package/docs/components/divider/orientation.md +18 -0
- package/docs/components/divider/sizes.md +24 -0
- package/docs/components/divider/usage.md +14 -0
- package/docs/components/divider/variants.md +14 -0
- package/docs/components/dropdown/_meta.yaml +11 -0
- package/docs/components/dropdown/accessibility.md +6 -0
- package/docs/components/dropdown/custom-colors.md +17 -0
- package/docs/components/dropdown/custom-trigger.md +18 -0
- package/docs/components/dropdown/intro.md +8 -0
- package/docs/components/dropdown/kinds.md +23 -0
- package/docs/components/dropdown/positioning.md +23 -0
- package/docs/components/dropdown/submenus.md +28 -0
- package/docs/components/dropdown/usage.md +24 -0
- package/docs/components/field/_meta.yaml +10 -0
- package/docs/components/field/accessibility.md +6 -0
- package/docs/components/field/description.md +15 -0
- package/docs/components/field/intro.md +8 -0
- package/docs/components/field/label-position.md +16 -0
- package/docs/components/field/required.md +12 -0
- package/docs/components/field/usage.md +19 -0
- package/docs/components/field/validation.md +32 -0
- package/docs/components/group/_meta.yaml +7 -0
- package/docs/components/group/accessibility.md +6 -0
- package/docs/components/group/intro.md +8 -0
- package/docs/components/group/orientation.md +22 -0
- package/docs/components/group/usage.md +14 -0
- package/docs/components/input/_meta.yaml +11 -0
- package/docs/components/input/accessibility.md +6 -0
- package/docs/components/input/custom-colors.md +21 -0
- package/docs/components/input/intro.md +8 -0
- package/docs/components/input/kinds.md +16 -0
- package/docs/components/input/sizes.md +13 -0
- package/docs/components/input/states.md +12 -0
- package/docs/components/input/types.md +15 -0
- package/docs/components/input/usage.md +17 -0
- package/docs/components/listbox/_meta.yaml +12 -0
- package/docs/components/listbox/color-kinds.md +27 -0
- package/docs/components/listbox/custom-colors.md +18 -0
- package/docs/components/listbox/form-example.md +36 -0
- package/docs/components/listbox/intro.md +8 -0
- package/docs/components/listbox/kinds.md +30 -0
- package/docs/components/listbox/separators.md +19 -0
- package/docs/components/listbox/sizes.md +24 -0
- package/docs/components/listbox/states.md +19 -0
- package/docs/components/listbox/usage.md +23 -0
- package/docs/components/modal/_meta.yaml +13 -0
- package/docs/components/modal/close-behaviors.md +49 -0
- package/docs/components/modal/confirmation.md +19 -0
- package/docs/components/modal/controlled-state.md +29 -0
- package/docs/components/modal/custom-colors.md +25 -0
- package/docs/components/modal/custom-trigger.md +28 -0
- package/docs/components/modal/form-modal.md +23 -0
- package/docs/components/modal/intro.md +8 -0
- package/docs/components/modal/kinds.md +30 -0
- package/docs/components/modal/sizes.md +21 -0
- package/docs/components/modal/usage.md +15 -0
- package/docs/components/navbar/_meta.yaml +11 -0
- package/docs/components/navbar/complex-layouts.md +34 -0
- package/docs/components/navbar/custom-colors.md +24 -0
- package/docs/components/navbar/icons.md +33 -0
- package/docs/components/navbar/intro.md +8 -0
- package/docs/components/navbar/kinds.md +24 -0
- package/docs/components/navbar/neon-colors.md +24 -0
- package/docs/components/navbar/sticky.md +22 -0
- package/docs/components/navbar/usage.md +25 -0
- package/docs/components/number-input/_meta.yaml +12 -0
- package/docs/components/number-input/color-kinds.md +17 -0
- package/docs/components/number-input/custom-colors.md +21 -0
- package/docs/components/number-input/form-example.md +55 -0
- package/docs/components/number-input/intro.md +8 -0
- package/docs/components/number-input/kinds.md +16 -0
- package/docs/components/number-input/min-max-step.md +11 -0
- package/docs/components/number-input/sizes.md +13 -0
- package/docs/components/number-input/states.md +12 -0
- package/docs/components/number-input/usage.md +18 -0
- package/docs/components/page/_meta.yaml +9 -0
- package/docs/components/page/custom-width.md +17 -0
- package/docs/components/page/fixed-header.md +17 -0
- package/docs/components/page/intro.md +8 -0
- package/docs/components/page/real-world.md +37 -0
- package/docs/components/page/sidebar-position.md +18 -0
- package/docs/components/page/usage.md +33 -0
- package/docs/components/pagination/_meta.yaml +12 -0
- package/docs/components/pagination/config-options.md +17 -0
- package/docs/components/pagination/custom-colors.md +15 -0
- package/docs/components/pagination/intro.md +8 -0
- package/docs/components/pagination/kinds.md +13 -0
- package/docs/components/pagination/sizes.md +14 -0
- package/docs/components/pagination/states.md +10 -0
- package/docs/components/pagination/table-example.md +28 -0
- package/docs/components/pagination/usage.md +10 -0
- package/docs/components/pagination/variants.md +13 -0
- package/docs/components/panel/_meta.yaml +10 -0
- package/docs/components/panel/custom-colors.md +18 -0
- package/docs/components/panel/decoration.md +20 -0
- package/docs/components/panel/intro.md +8 -0
- package/docs/components/panel/kinds.md +23 -0
- package/docs/components/panel/scrollable.md +18 -0
- package/docs/components/panel/sizes.md +20 -0
- package/docs/components/panel/usage.md +13 -0
- package/docs/components/popover/_meta.yaml +9 -0
- package/docs/components/popover/arrow.md +15 -0
- package/docs/components/popover/custom-colors.md +19 -0
- package/docs/components/popover/intro.md +8 -0
- package/docs/components/popover/kinds.md +24 -0
- package/docs/components/popover/positioning.md +36 -0
- package/docs/components/popover/usage.md +15 -0
- package/docs/components/progress/_meta.yaml +10 -0
- package/docs/components/progress/custom-colors.md +14 -0
- package/docs/components/progress/indeterminate.md +11 -0
- package/docs/components/progress/intro.md +8 -0
- package/docs/components/progress/kinds.md +16 -0
- package/docs/components/progress/sizes.md +14 -0
- package/docs/components/progress/usage.md +13 -0
- package/docs/components/progress/value-label.md +12 -0
- package/docs/components/radio/_meta.yaml +10 -0
- package/docs/components/radio/custom-colors.md +24 -0
- package/docs/components/radio/intro.md +8 -0
- package/docs/components/radio/kinds.md +23 -0
- package/docs/components/radio/orientation.md +22 -0
- package/docs/components/radio/sizes.md +23 -0
- package/docs/components/radio/states.md +21 -0
- package/docs/components/radio/usage.md +21 -0
- package/docs/components/sidebar/_meta.yaml +10 -0
- package/docs/components/sidebar/active-state.md +35 -0
- package/docs/components/sidebar/custom-colors.md +20 -0
- package/docs/components/sidebar/intro.md +8 -0
- package/docs/components/sidebar/kinds.md +22 -0
- package/docs/components/sidebar/router.md +24 -0
- package/docs/components/sidebar/sections.md +24 -0
- package/docs/components/sidebar/usage.md +25 -0
- package/docs/components/skeleton/_meta.yaml +8 -0
- package/docs/components/skeleton/animations.md +17 -0
- package/docs/components/skeleton/composition.md +22 -0
- package/docs/components/skeleton/intro.md +8 -0
- package/docs/components/skeleton/usage.md +12 -0
- package/docs/components/skeleton/variants.md +17 -0
- package/docs/components/slider/_meta.yaml +12 -0
- package/docs/components/slider/accessibility.md +6 -0
- package/docs/components/slider/custom-colors.md +14 -0
- package/docs/components/slider/intro.md +8 -0
- package/docs/components/slider/kinds.md +16 -0
- package/docs/components/slider/range.md +16 -0
- package/docs/components/slider/sizes.md +14 -0
- package/docs/components/slider/step.md +13 -0
- package/docs/components/slider/usage.md +16 -0
- package/docs/components/slider/vertical.md +14 -0
- package/docs/components/spinner/_meta.yaml +10 -0
- package/docs/components/spinner/accessibility.md +6 -0
- package/docs/components/spinner/custom-colors.md +13 -0
- package/docs/components/spinner/intro.md +8 -0
- package/docs/components/spinner/kinds.md +16 -0
- package/docs/components/spinner/sizes.md +14 -0
- package/docs/components/spinner/usage.md +10 -0
- package/docs/components/spinner/variants.md +12 -0
- package/docs/components/switch/_meta.yaml +12 -0
- package/docs/components/switch/accessibility.md +6 -0
- package/docs/components/switch/custom-colors.md +29 -0
- package/docs/components/switch/disabled.md +11 -0
- package/docs/components/switch/dynamic-labels.md +12 -0
- package/docs/components/switch/intro.md +8 -0
- package/docs/components/switch/kinds.md +16 -0
- package/docs/components/switch/sizes.md +14 -0
- package/docs/components/switch/thumb-color.md +16 -0
- package/docs/components/switch/usage.md +18 -0
- package/docs/components/table/_meta.yaml +12 -0
- package/docs/components/table/accessibility.md +6 -0
- package/docs/components/table/borders.md +17 -0
- package/docs/components/table/hoverable.md +26 -0
- package/docs/components/table/intro.md +8 -0
- package/docs/components/table/kinds.md +18 -0
- package/docs/components/table/striped.md +28 -0
- package/docs/components/table/subtle.md +26 -0
- package/docs/components/table/usage.md +30 -0
- package/docs/components/table/variants.md +23 -0
- package/docs/components/tabs/_meta.yaml +10 -0
- package/docs/components/tabs/accessibility.md +6 -0
- package/docs/components/tabs/custom-colors.md +23 -0
- package/docs/components/tabs/icons.md +23 -0
- package/docs/components/tabs/intro.md +8 -0
- package/docs/components/tabs/kinds.md +30 -0
- package/docs/components/tabs/usage.md +38 -0
- package/docs/components/tabs/vertical.md +23 -0
- package/docs/components/tag/_meta.yaml +11 -0
- package/docs/components/tag/accessibility.md +6 -0
- package/docs/components/tag/custom-colors.md +32 -0
- package/docs/components/tag/intro.md +8 -0
- package/docs/components/tag/kinds.md +16 -0
- package/docs/components/tag/removable.md +33 -0
- package/docs/components/tag/sizes.md +13 -0
- package/docs/components/tag/usage.md +13 -0
- package/docs/components/tag/variants.md +13 -0
- package/docs/components/tags-input/_meta.yaml +13 -0
- package/docs/components/tags-input/color-kinds.md +17 -0
- package/docs/components/tags-input/custom-colors.md +21 -0
- package/docs/components/tags-input/form-example.md +30 -0
- package/docs/components/tags-input/intro.md +8 -0
- package/docs/components/tags-input/kinds.md +16 -0
- package/docs/components/tags-input/max-tags.md +10 -0
- package/docs/components/tags-input/sizes.md +13 -0
- package/docs/components/tags-input/states.md +10 -0
- package/docs/components/tags-input/tag-customization.md +17 -0
- package/docs/components/tags-input/usage.md +17 -0
- package/docs/components/textarea/_meta.yaml +12 -0
- package/docs/components/textarea/color-kinds.md +17 -0
- package/docs/components/textarea/custom-colors.md +21 -0
- package/docs/components/textarea/form-example.md +37 -0
- package/docs/components/textarea/intro.md +8 -0
- package/docs/components/textarea/kinds.md +16 -0
- package/docs/components/textarea/rows.md +12 -0
- package/docs/components/textarea/sizes.md +13 -0
- package/docs/components/textarea/states.md +12 -0
- package/docs/components/textarea/usage.md +17 -0
- package/docs/components/theme/_meta.yaml +9 -0
- package/docs/components/theme/available-themes.md +16 -0
- package/docs/components/theme/intro.md +8 -0
- package/docs/components/theme/nested-themes.md +16 -0
- package/docs/components/theme/portal-components.md +19 -0
- package/docs/components/theme/programmatic-switching.md +19 -0
- package/docs/components/theme/usage.md +16 -0
- package/docs/components/toast/_meta.yaml +11 -0
- package/docs/components/toast/dismiss.md +15 -0
- package/docs/components/toast/duration.md +23 -0
- package/docs/components/toast/intro.md +8 -0
- package/docs/components/toast/kinds.md +13 -0
- package/docs/components/toast/real-world.md +23 -0
- package/docs/components/toast/setup.md +16 -0
- package/docs/components/toast/usage.md +18 -0
- package/docs/components/toast/with-title.md +14 -0
- package/docs/components/tooltip/_meta.yaml +14 -0
- package/docs/components/tooltip/alignment.md +24 -0
- package/docs/components/tooltip/app-level-provider.md +21 -0
- package/docs/components/tooltip/arrow.md +21 -0
- package/docs/components/tooltip/custom-colors.md +24 -0
- package/docs/components/tooltip/delay.md +27 -0
- package/docs/components/tooltip/intro.md +8 -0
- package/docs/components/tooltip/kinds.md +27 -0
- package/docs/components/tooltip/positioning.md +24 -0
- package/docs/components/tooltip/provider.md +26 -0
- package/docs/components/tooltip/real-world.md +32 -0
- package/docs/components/tooltip/usage.md +15 -0
- package/docs/guides/ai-llms.md +63 -0
- package/docs/guides/design-tokens/_meta.yaml +14 -0
- package/docs/guides/design-tokens/advanced.md +60 -0
- package/docs/guides/design-tokens/architecture.md +11 -0
- package/docs/guides/design-tokens/best-practices.md +21 -0
- package/docs/guides/design-tokens/component-tokens.md +37 -0
- package/docs/guides/design-tokens/foundation-colors.md +13 -0
- package/docs/guides/design-tokens/foundation-other.md +41 -0
- package/docs/guides/design-tokens/intro.md +19 -0
- package/docs/guides/design-tokens/semantic-kinds.md +33 -0
- package/docs/guides/design-tokens/semantic-states.md +55 -0
- package/docs/guides/design-tokens/themes.md +38 -0
- package/docs/guides/design-tokens/usage.md +55 -0
- package/package.json +3 -5
- package/src/components/Accordion/SkAccordion.vue +51 -37
- package/src/components/Accordion/SkAccordionItem.vue +40 -20
- package/src/components/Alert/SkAlert.vue +37 -27
- package/src/components/Avatar/SkAvatar.vue +69 -10
- package/src/components/Breadcrumbs/SkBreadcrumbItem.vue +63 -1
- package/src/components/Breadcrumbs/SkBreadcrumbSeparator.vue +32 -3
- package/src/components/Breadcrumbs/SkBreadcrumbs.vue +36 -0
- package/src/components/Button/SkButton.vue +83 -17
- package/src/components/Card/SkCard.vue +84 -17
- package/src/components/Checkbox/SkCheckbox.vue +52 -12
- package/src/components/Collapsible/SkCollapsible.vue +65 -27
- package/src/components/Divider/SkDivider.vue +51 -11
- package/src/components/Dropdown/SkDropdown.vue +54 -11
- package/src/components/Dropdown/SkDropdownMenuItem.vue +25 -6
- package/src/components/Dropdown/SkDropdownMenuSeparator.vue +16 -2
- package/src/components/Dropdown/SkDropdownSubmenu.vue +30 -8
- package/src/components/Field/SkField.vue +83 -15
- package/src/components/Group/SkGroup.vue +24 -9
- package/src/components/Input/SkInput.vue +77 -15
- package/src/components/Listbox/SkListbox.vue +48 -10
- package/src/components/Listbox/SkListboxItem.vue +28 -7
- package/src/components/Listbox/SkListboxSeparator.vue +16 -2
- package/src/components/Modal/SkModal.vue +85 -36
- package/src/components/NavBar/SkNavBar.vue +39 -9
- package/src/components/NumberInput/SkNumberInput.vue +85 -16
- package/src/components/Page/SkPage.vue +55 -6
- package/src/components/Pagination/SkPagination.vue +88 -0
- package/src/components/Pagination/SkPaginationItem.vue +51 -1
- package/src/components/Panel/SkPanel.vue +46 -12
- package/src/components/Popover/SkPopover.vue +91 -36
- package/src/components/Progress/SkProgress.vue +74 -10
- package/src/components/Radio/SkRadio.vue +48 -12
- package/src/components/Radio/SkRadioGroup.vue +69 -13
- package/src/components/Sidebar/SkSidebar.vue +36 -29
- package/src/components/Sidebar/SkSidebarItem.vue +34 -9
- package/src/components/Sidebar/SkSidebarSection.vue +22 -8
- package/src/components/Skeleton/SkSkeleton.vue +75 -8
- package/src/components/Slider/SkSlider.vue +91 -15
- package/src/components/Spinner/SkSpinner.vue +50 -6
- package/src/components/Switch/SkSwitch.vue +98 -35
- package/src/components/Table/SkTable.vue +79 -15
- package/src/components/Tabs/SkTab.vue +41 -11
- package/src/components/Tabs/SkTabList.vue +24 -8
- package/src/components/Tabs/SkTabPanel.vue +31 -9
- package/src/components/Tabs/SkTabPanels.vue +21 -4
- package/src/components/Tabs/SkTabs.vue +49 -37
- package/src/components/Tag/SkTag.vue +57 -32
- package/src/components/TagsInput/SkTagsInput.vue +75 -14
- package/src/components/Textarea/SkTextarea.vue +78 -15
- package/src/components/Theme/SkTheme.vue +27 -3
- package/src/components/Theme/types.ts +14 -5
- package/src/components/Toast/SkToast.vue +56 -9
- package/src/components/Toast/SkToastProvider.vue +43 -17
- package/src/components/Tooltip/SkTooltip.vue +66 -35
- package/src/components/Tooltip/SkTooltipProvider.vue +36 -36
- package/src/composables/usePortalContext.test.ts +2 -0
- package/src/styles/components/_alert.scss +0 -22
- package/web-types.json +302 -282
- package/docs/components/accordion.md +0 -92
- package/docs/components/alert.md +0 -72
- package/docs/components/avatar.md +0 -69
- package/docs/components/breadcrumbs.md +0 -65
- package/docs/components/button.md +0 -110
- package/docs/components/card.md +0 -87
- package/docs/components/checkbox.md +0 -77
- package/docs/components/collapsible.md +0 -71
- package/docs/components/divider.md +0 -62
- package/docs/components/dropdown.md +0 -88
- package/docs/components/field.md +0 -80
- package/docs/components/group.md +0 -41
- package/docs/components/input.md +0 -84
- package/docs/components/listbox.md +0 -82
- package/docs/components/modal.md +0 -101
- package/docs/components/navbar.md +0 -64
- package/docs/components/number-input.md +0 -78
- package/docs/components/page.md +0 -77
- package/docs/components/pagination.md +0 -88
- package/docs/components/panel.md +0 -74
- package/docs/components/popover.md +0 -93
- package/docs/components/progress.md +0 -76
- package/docs/components/radio.md +0 -86
- package/docs/components/sidebar.md +0 -74
- package/docs/components/skeleton.md +0 -76
- package/docs/components/slider.md +0 -94
- package/docs/components/spinner.md +0 -59
- package/docs/components/switch.md +0 -97
- package/docs/components/table.md +0 -91
- package/docs/components/tabs.md +0 -108
- package/docs/components/tag.md +0 -75
- package/docs/components/tags-input.md +0 -88
- package/docs/components/textarea.md +0 -80
- package/docs/components/theme.md +0 -65
- package/docs/components/toast.md +0 -95
- package/docs/components/tooltip.md +0 -90
- package/docs/guides/design-tokens.md +0 -105
|
@@ -26,9 +26,25 @@
|
|
|
26
26
|
|
|
27
27
|
<script setup lang="ts">
|
|
28
28
|
/**
|
|
29
|
-
* @component
|
|
30
|
-
* An individual tab trigger
|
|
31
|
-
*
|
|
29
|
+
* @component SkTab
|
|
30
|
+
* @description An individual tab trigger button used within `SkTabList` to switch between tab panels.
|
|
31
|
+
* Clicking a tab activates the corresponding `SkTabPanel` with a matching `name`. Supports keyboard
|
|
32
|
+
* navigation (arrow keys), focus management, and disabled states.
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* ```vue
|
|
36
|
+
* <SkTabList>
|
|
37
|
+
* <SkTab name="files" label="Files" />
|
|
38
|
+
* <SkTab name="settings" kind="accent">
|
|
39
|
+
* <template #icon><GearIcon /></template>
|
|
40
|
+
* Settings
|
|
41
|
+
* </SkTab>
|
|
42
|
+
* <SkTab name="help" disabled>Help</SkTab>
|
|
43
|
+
* </SkTabList>
|
|
44
|
+
* ```
|
|
45
|
+
*
|
|
46
|
+
* @slot default - Custom tab label content. Overrides the `label` prop when provided.
|
|
47
|
+
* @slot icon - Optional icon displayed before the tab label. Useful for visual indicators.
|
|
32
48
|
*/
|
|
33
49
|
|
|
34
50
|
import { type ComputedRef, computed, inject } from 'vue';
|
|
@@ -37,19 +53,33 @@
|
|
|
37
53
|
|
|
38
54
|
//------------------------------------------------------------------------------------------------------------------
|
|
39
55
|
|
|
40
|
-
/**
|
|
41
|
-
* An individual tab trigger component powered by RekaUI.
|
|
42
|
-
* Used within SkTabList to switch between tab panels.
|
|
43
|
-
*/
|
|
44
56
|
export interface SkTabComponentProps
|
|
45
57
|
{
|
|
46
|
-
/**
|
|
58
|
+
/**
|
|
59
|
+
* Unique identifier that links this tab trigger to its corresponding `SkTabPanel`. The `name`
|
|
60
|
+
* must exactly match the `name` prop on the panel you want to display when this tab is active.
|
|
61
|
+
* Can be a string or number for flexibility with dynamic tab generation.
|
|
62
|
+
*/
|
|
47
63
|
name : string | number;
|
|
48
|
-
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Text label displayed in the tab button. Can be overridden by the default slot for custom
|
|
67
|
+
* content like icons with text or formatted labels.
|
|
68
|
+
*/
|
|
49
69
|
label ?: string;
|
|
50
|
-
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* When true, the tab cannot be clicked or focused via keyboard. Disabled tabs are skipped
|
|
73
|
+
* during arrow key navigation and appear with reduced opacity.
|
|
74
|
+
* @default false
|
|
75
|
+
*/
|
|
51
76
|
disabled ?: boolean;
|
|
52
|
-
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Semantic color kind for this specific tab. When provided, overrides the `kind` set on the
|
|
80
|
+
* parent `SkTabs` component. Use this for highlighting important tabs or creating visual
|
|
81
|
+
* hierarchy within a tab bar.
|
|
82
|
+
*/
|
|
53
83
|
kind ?: ComponentKind;
|
|
54
84
|
}
|
|
55
85
|
|
|
@@ -12,9 +12,25 @@
|
|
|
12
12
|
|
|
13
13
|
<script setup lang="ts">
|
|
14
14
|
/**
|
|
15
|
-
* @component
|
|
16
|
-
* A container component
|
|
17
|
-
*
|
|
15
|
+
* @component SkTabList
|
|
16
|
+
* @description A container component that holds and arranges `SkTab` trigger buttons. Provides the visual
|
|
17
|
+
* tab bar with appropriate ARIA `tablist` role. The orientation determines whether tabs are arranged
|
|
18
|
+
* horizontally (row) or vertically (column) and affects keyboard navigation direction.
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* ```vue
|
|
22
|
+
* <SkTabs v-model="activeTab">
|
|
23
|
+
* <SkTabList>
|
|
24
|
+
* <SkTab name="tab1">First Tab</SkTab>
|
|
25
|
+
* <SkTab name="tab2">Second Tab</SkTab>
|
|
26
|
+
* </SkTabList>
|
|
27
|
+
* <SkTabPanels>
|
|
28
|
+
* <!-- Panels here -->
|
|
29
|
+
* </SkTabPanels>
|
|
30
|
+
* </SkTabs>
|
|
31
|
+
* ```
|
|
32
|
+
*
|
|
33
|
+
* @slot default - Contains `SkTab` components that make up the tab triggers.
|
|
18
34
|
*/
|
|
19
35
|
|
|
20
36
|
import { computed, inject } from 'vue';
|
|
@@ -23,13 +39,13 @@
|
|
|
23
39
|
|
|
24
40
|
//------------------------------------------------------------------------------------------------------------------
|
|
25
41
|
|
|
26
|
-
/**
|
|
27
|
-
* A container component for SkTab components powered by RekaUI.
|
|
28
|
-
* Arranges tabs in horizontal or vertical orientation.
|
|
29
|
-
*/
|
|
30
42
|
export interface SkTabListComponentProps
|
|
31
43
|
{
|
|
32
|
-
/**
|
|
44
|
+
/**
|
|
45
|
+
* Layout orientation for arranging tab triggers. When 'horizontal', tabs appear in a row
|
|
46
|
+
* with left/right arrow key navigation. When 'vertical', tabs stack in a column with
|
|
47
|
+
* up/down arrow key navigation. If not provided, inherits from the parent `SkTabs` component.
|
|
48
|
+
*/
|
|
33
49
|
orientation ?: SkTabsOrientation;
|
|
34
50
|
}
|
|
35
51
|
|
|
@@ -16,24 +16,46 @@
|
|
|
16
16
|
|
|
17
17
|
<script setup lang="ts">
|
|
18
18
|
/**
|
|
19
|
-
* @component
|
|
20
|
-
* A content
|
|
21
|
-
*
|
|
19
|
+
* @component SkTabPanel
|
|
20
|
+
* @description A content container that displays when its corresponding `SkTab` is active. The panel is
|
|
21
|
+
* automatically shown or hidden based on the active tab state in the parent `SkTabs`. By default, inactive
|
|
22
|
+
* panels are unmounted from the DOM to improve performance; use `keepAlive` to preserve state.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* ```vue
|
|
26
|
+
* <SkTabPanels>
|
|
27
|
+
* <SkTabPanel name="overview">
|
|
28
|
+
* <h2>Overview</h2>
|
|
29
|
+
* <p>Welcome to the overview section.</p>
|
|
30
|
+
* </SkTabPanel>
|
|
31
|
+
* <SkTabPanel name="form" keep-alive>
|
|
32
|
+
* <!-- Form state preserved when switching tabs -->
|
|
33
|
+
* <FormComponent />
|
|
34
|
+
* </SkTabPanel>
|
|
35
|
+
* </SkTabPanels>
|
|
36
|
+
* ```
|
|
37
|
+
*
|
|
38
|
+
* @slot default - The content to display when this panel's tab is active.
|
|
22
39
|
*/
|
|
23
40
|
|
|
24
41
|
import { TabsContent } from 'reka-ui';
|
|
25
42
|
|
|
26
43
|
//------------------------------------------------------------------------------------------------------------------
|
|
27
44
|
|
|
28
|
-
/**
|
|
29
|
-
* A content panel component for displaying tab content powered by RekaUI.
|
|
30
|
-
* Automatically shown/hidden based on the active tab in the parent SkTabs.
|
|
31
|
-
*/
|
|
32
45
|
export interface SkTabPanelComponentProps
|
|
33
46
|
{
|
|
34
|
-
/**
|
|
47
|
+
/**
|
|
48
|
+
* Unique identifier that links this panel to its corresponding `SkTab` trigger. The `name`
|
|
49
|
+
* must exactly match the `name` prop on the tab that should activate this panel.
|
|
50
|
+
*/
|
|
35
51
|
name : string | number;
|
|
36
|
-
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* When true, the panel content remains mounted in the DOM even when the tab is inactive.
|
|
55
|
+
* This is useful for preserving form state, scroll position, or expensive component state
|
|
56
|
+
* that would otherwise be lost when switching tabs. Use sparingly as it increases memory usage.
|
|
57
|
+
* @default false
|
|
58
|
+
*/
|
|
37
59
|
keepAlive ?: boolean;
|
|
38
60
|
}
|
|
39
61
|
|
|
@@ -12,12 +12,29 @@
|
|
|
12
12
|
|
|
13
13
|
<script setup lang="ts">
|
|
14
14
|
/**
|
|
15
|
-
* @component
|
|
16
|
-
* A
|
|
17
|
-
*
|
|
15
|
+
* @component SkTabPanels
|
|
16
|
+
* @description A container component that groups `SkTabPanel` components together. Provides semantic structure
|
|
17
|
+
* and consistent styling for the content area of a tabbed interface. While technically optional, using this
|
|
18
|
+
* wrapper ensures proper layout and spacing between the tab list and content panels.
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* ```vue
|
|
22
|
+
* <SkTabs v-model="activeTab">
|
|
23
|
+
* <SkTabList>
|
|
24
|
+
* <SkTab name="a">Tab A</SkTab>
|
|
25
|
+
* <SkTab name="b">Tab B</SkTab>
|
|
26
|
+
* </SkTabList>
|
|
27
|
+
* <SkTabPanels>
|
|
28
|
+
* <SkTabPanel name="a">Content for Tab A</SkTabPanel>
|
|
29
|
+
* <SkTabPanel name="b">Content for Tab B</SkTabPanel>
|
|
30
|
+
* </SkTabPanels>
|
|
31
|
+
* </SkTabs>
|
|
32
|
+
* ```
|
|
33
|
+
*
|
|
34
|
+
* @slot default - Contains `SkTabPanel` components, one for each tab in the interface.
|
|
18
35
|
*/
|
|
19
36
|
|
|
20
|
-
// No props or logic needed -
|
|
37
|
+
// No props or logic needed - provides semantic structure and styling hook
|
|
21
38
|
</script>
|
|
22
39
|
|
|
23
40
|
<!--------------------------------------------------------------------------------------------------------------------->
|
|
@@ -18,9 +18,26 @@
|
|
|
18
18
|
|
|
19
19
|
<script setup lang="ts">
|
|
20
20
|
/**
|
|
21
|
-
* @component
|
|
22
|
-
* A tabbed interface component for organizing content into switchable panels
|
|
23
|
-
*
|
|
21
|
+
* @component SkTabs
|
|
22
|
+
* @description A tabbed interface component for organizing content into switchable panels. Built on RekaUI's
|
|
23
|
+
* Tabs primitive with full keyboard navigation (arrow keys, Home, End) and ARIA tab pattern compliance.
|
|
24
|
+
* Use with `v-model` to control the active tab programmatically.
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* ```vue
|
|
28
|
+
* <SkTabs v-model="activeTab" kind="primary">
|
|
29
|
+
* <SkTabList>
|
|
30
|
+
* <SkTab name="overview">Overview</SkTab>
|
|
31
|
+
* <SkTab name="details">Details</SkTab>
|
|
32
|
+
* </SkTabList>
|
|
33
|
+
* <SkTabPanels>
|
|
34
|
+
* <SkTabPanel name="overview">Overview content here</SkTabPanel>
|
|
35
|
+
* <SkTabPanel name="details">Details content here</SkTabPanel>
|
|
36
|
+
* </SkTabPanels>
|
|
37
|
+
* </SkTabs>
|
|
38
|
+
* ```
|
|
39
|
+
*
|
|
40
|
+
* @slot default - Contains `SkTabList` and `SkTabPanels` components that make up the tabbed interface.
|
|
24
41
|
*/
|
|
25
42
|
|
|
26
43
|
import { computed, provide, toRef } from 'vue';
|
|
@@ -34,46 +51,41 @@
|
|
|
34
51
|
|
|
35
52
|
//------------------------------------------------------------------------------------------------------------------
|
|
36
53
|
|
|
37
|
-
/**
|
|
38
|
-
* A tabbed interface component for organizing content into switchable panels powered by RekaUI.
|
|
39
|
-
* Manages active tab state and provides context to child tab components.
|
|
40
|
-
*
|
|
41
|
-
* @example Basic tabs
|
|
42
|
-
* ```vue
|
|
43
|
-
* <SkTabs v-model="activeTab">
|
|
44
|
-
* <SkTabList>
|
|
45
|
-
* <SkTab name="overview">Overview</SkTab>
|
|
46
|
-
* <SkTab name="details">Details</SkTab>
|
|
47
|
-
* </SkTabList>
|
|
48
|
-
* <SkTabPanels>
|
|
49
|
-
* <SkTabPanel name="overview">Overview content</SkTabPanel>
|
|
50
|
-
* <SkTabPanel name="details">Details content</SkTabPanel>
|
|
51
|
-
* </SkTabPanels>
|
|
52
|
-
* </SkTabs>
|
|
53
|
-
* ```
|
|
54
|
-
*
|
|
55
|
-
* @example Custom colors
|
|
56
|
-
* ```vue
|
|
57
|
-
* <SkTabs
|
|
58
|
-
* v-model="activeTab"
|
|
59
|
-
* base-color="oklch(0.65 0.2 280)"
|
|
60
|
-
* text-color="white"
|
|
61
|
-
* >
|
|
62
|
-
* <!-- Tab content -->
|
|
63
|
-
* </SkTabs>
|
|
64
|
-
* ```
|
|
65
|
-
*/
|
|
66
54
|
export interface SkTabsComponentProps extends ComponentCustomColors
|
|
67
55
|
{
|
|
68
|
-
/**
|
|
56
|
+
/**
|
|
57
|
+
* The currently active tab identifier, matching the `name` prop of the corresponding `SkTab`
|
|
58
|
+
* and `SkTabPanel`. Use with `v-model` for two-way binding to control which tab is displayed.
|
|
59
|
+
*/
|
|
69
60
|
modelValue : string | number;
|
|
70
|
-
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Layout orientation for the tab list. In 'horizontal' mode, tabs are arranged in a row and
|
|
64
|
+
* arrow keys navigate left/right. In 'vertical' mode, tabs stack vertically and arrow keys
|
|
65
|
+
* navigate up/down.
|
|
66
|
+
* @default 'horizontal'
|
|
67
|
+
*/
|
|
71
68
|
orientation ?: SkTabsOrientation;
|
|
72
|
-
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
* Alignment of the tab list within its container. 'start' aligns tabs to the left (horizontal)
|
|
72
|
+
* or top (vertical), 'end' aligns to the opposite side. Useful for positioning tabs in
|
|
73
|
+
* different layout contexts.
|
|
74
|
+
* @default 'start'
|
|
75
|
+
*/
|
|
73
76
|
placement ?: SkTabsPlacement;
|
|
74
|
-
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Semantic color kind applied to all tabs in this group. Individual `SkTab` components can
|
|
80
|
+
* override this with their own `kind` prop for mixed-color tab bars.
|
|
81
|
+
*/
|
|
75
82
|
kind ?: ComponentKind;
|
|
76
|
-
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* When true, applies negative margins to align the tab list flush with the parent container's
|
|
86
|
+
* edges. Useful when the parent has padding but you want tabs to extend edge-to-edge.
|
|
87
|
+
* @default false
|
|
88
|
+
*/
|
|
77
89
|
flush ?: boolean;
|
|
78
90
|
}
|
|
79
91
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
<!----------------------------------------------------------------------------------------------------------------------
|
|
2
2
|
- Tag Component
|
|
3
|
-
|
|
3
|
+
--------------------------------------------------------------------------------------------------------------------->
|
|
4
4
|
|
|
5
5
|
<template>
|
|
6
6
|
<span :class="classes" :style="customColorStyles">
|
|
@@ -32,52 +32,73 @@
|
|
|
32
32
|
</span>
|
|
33
33
|
</template>
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
<!--------------------------------------------------------------------------------------------------------------------->
|
|
36
|
+
|
|
37
|
+
<style lang="scss" scoped>
|
|
38
|
+
// Component styles are implemented in /src/styles/components/_tag.scss
|
|
39
|
+
</style>
|
|
40
|
+
|
|
41
|
+
<!--------------------------------------------------------------------------------------------------------------------->
|
|
36
42
|
|
|
37
43
|
<script setup lang="ts">
|
|
38
44
|
/**
|
|
39
|
-
* @component
|
|
40
|
-
* A compact label component for displaying metadata, categories, or status information.
|
|
41
|
-
*
|
|
45
|
+
* @component SkTag
|
|
46
|
+
* @description A compact label component for displaying metadata, categories, or status information. Tags are
|
|
47
|
+
* ideal for showing keywords, filter chips, selected items in multi-selects, or status indicators. Supports
|
|
48
|
+
* four visual variants (solid, outline, subtle, ghost) and optional removable functionality with a dismiss button.
|
|
49
|
+
*
|
|
50
|
+
* @example
|
|
51
|
+
* ```vue
|
|
52
|
+
* <SkTag kind="primary">Featured</SkTag>
|
|
53
|
+
* <SkTag kind="success" removable @remove="handleRemove">Active</SkTag>
|
|
54
|
+
* ```
|
|
55
|
+
*
|
|
56
|
+
* @slot default - The tag label content. Can include text, icons, or any inline elements.
|
|
42
57
|
*/
|
|
43
58
|
|
|
44
59
|
import { computed, toRef } from 'vue';
|
|
60
|
+
|
|
61
|
+
// Types
|
|
45
62
|
import type { ComponentCustomColors, ComponentKind } from '@/types';
|
|
46
63
|
import type { SkTagSize, SkTagVariant } from './types';
|
|
64
|
+
|
|
65
|
+
// Composables
|
|
47
66
|
import { useCustomColors } from '@/composables/useCustomColors';
|
|
48
67
|
|
|
49
68
|
//------------------------------------------------------------------------------------------------------------------
|
|
50
69
|
|
|
51
|
-
/**
|
|
52
|
-
* A compact label component for displaying metadata, categories, or status information.
|
|
53
|
-
* Supports multiple variants, sizes, and optional remove functionality.
|
|
54
|
-
*
|
|
55
|
-
* @example Basic tags
|
|
56
|
-
* ```vue
|
|
57
|
-
* <SkTag kind="primary">Featured</SkTag>
|
|
58
|
-
* <SkTag kind="success" removable @remove="handleRemove">Active</SkTag>
|
|
59
|
-
* ```
|
|
60
|
-
*
|
|
61
|
-
* @example Custom colored tag
|
|
62
|
-
* ```vue
|
|
63
|
-
* <SkTag
|
|
64
|
-
* base-color="oklch(0.75 0.2 150)"
|
|
65
|
-
* text-color="white"
|
|
66
|
-
* variant="solid"
|
|
67
|
-
* >
|
|
68
|
-
* Custom Green Tag
|
|
69
|
-
* </SkTag>
|
|
70
|
-
* ```
|
|
71
|
-
*/
|
|
72
70
|
export interface SkTagComponentProps extends ComponentCustomColors
|
|
73
71
|
{
|
|
74
|
-
/**
|
|
72
|
+
/**
|
|
73
|
+
* Semantic color kind that controls the tag's color scheme. The kind determines both
|
|
74
|
+
* background and text colors across all variants. Use semantic kinds (primary, success,
|
|
75
|
+
* danger, etc.) to convey meaning, or use accent for decorative highlighting.
|
|
76
|
+
* @default 'neutral'
|
|
77
|
+
*/
|
|
75
78
|
kind ?: ComponentKind;
|
|
76
|
-
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* Visual variant that controls how the tag is rendered. Choose based on visual hierarchy:
|
|
82
|
+
* 'solid' for maximum emphasis with filled background, 'outline' for medium emphasis with
|
|
83
|
+
* a border, 'subtle' for low emphasis with a tinted background, 'ghost' for minimal
|
|
84
|
+
* presence with just text color.
|
|
85
|
+
* @default 'solid'
|
|
86
|
+
*/
|
|
77
87
|
variant ?: SkTagVariant;
|
|
78
|
-
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* Controls the tag dimensions including padding, font size, and remove button size.
|
|
91
|
+
* Available sizes: 'sm' (compact), 'md' (default), 'lg' (prominent), 'xl' (maximum).
|
|
92
|
+
* @default 'md'
|
|
93
|
+
*/
|
|
79
94
|
size ?: SkTagSize;
|
|
80
|
-
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* When true, displays a small X button on the right side of the tag that emits a
|
|
98
|
+
* 'remove' event when clicked. Useful for filter chips, multi-select displays, or
|
|
99
|
+
* any tags that can be dismissed by the user.
|
|
100
|
+
* @default false
|
|
101
|
+
*/
|
|
81
102
|
removable ?: boolean;
|
|
82
103
|
}
|
|
83
104
|
|
|
@@ -92,6 +113,10 @@
|
|
|
92
113
|
|
|
93
114
|
//------------------------------------------------------------------------------------------------------------------
|
|
94
115
|
|
|
116
|
+
/**
|
|
117
|
+
* @event remove - Emitted when the remove button is clicked. Only fires when `removable` is true.
|
|
118
|
+
* Use this event to remove the tag from your data model or trigger a filter update.
|
|
119
|
+
*/
|
|
95
120
|
const emit = defineEmits<{
|
|
96
121
|
remove : [];
|
|
97
122
|
}>();
|
|
@@ -126,4 +151,4 @@
|
|
|
126
151
|
);
|
|
127
152
|
</script>
|
|
128
153
|
|
|
129
|
-
|
|
154
|
+
<!--------------------------------------------------------------------------------------------------------------------->
|
|
@@ -46,9 +46,22 @@
|
|
|
46
46
|
|
|
47
47
|
<script setup lang="ts">
|
|
48
48
|
/**
|
|
49
|
-
* @component
|
|
50
|
-
* A multi-value tag input
|
|
51
|
-
*
|
|
49
|
+
* @component SkTagsInput
|
|
50
|
+
* @description A multi-value tag input for collecting lists of string values. Users add tags by typing
|
|
51
|
+
* and pressing Enter (or pasting multiple values), and remove them by clicking the delete button or
|
|
52
|
+
* pressing Backspace. Built on RekaUI's TagsInput primitive with full keyboard accessibility.
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* ```vue
|
|
56
|
+
* <SkTagsInput
|
|
57
|
+
* v-model="skills"
|
|
58
|
+
* kind="primary"
|
|
59
|
+
* placeholder="Add a skill..."
|
|
60
|
+
* :max="10"
|
|
61
|
+
* />
|
|
62
|
+
* ```
|
|
63
|
+
*
|
|
64
|
+
* @slot - Not applicable. This component does not accept slot content.
|
|
52
65
|
*/
|
|
53
66
|
|
|
54
67
|
import { type ComputedRef, computed, inject, toRef } from 'vue';
|
|
@@ -69,26 +82,68 @@
|
|
|
69
82
|
|
|
70
83
|
//------------------------------------------------------------------------------------------------------------------
|
|
71
84
|
|
|
72
|
-
/**
|
|
73
|
-
* A multi-value tag input component powered by RekaUI.
|
|
74
|
-
*/
|
|
75
85
|
export interface SkTagsInputComponentProps extends ComponentCustomColors
|
|
76
86
|
{
|
|
77
|
-
/**
|
|
87
|
+
/**
|
|
88
|
+
* Semantic color kind that controls the input border and focus ring appearance.
|
|
89
|
+
* Also sets the default color for tags unless overridden by `tagKind`. When used
|
|
90
|
+
* inside SkField, inherits the field's kind if not explicitly set.
|
|
91
|
+
* @default 'neutral' (or inherited from parent SkField)
|
|
92
|
+
*/
|
|
78
93
|
kind ?: SkTagsInputKind;
|
|
79
|
-
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Size of the input field and tags. Controls the input height, tag size, and
|
|
97
|
+
* text sizing throughout the component. Available sizes: 'sm' (small),
|
|
98
|
+
* 'md' (medium), 'lg' (large).
|
|
99
|
+
* @default 'md'
|
|
100
|
+
*/
|
|
80
101
|
size ?: SkTagsInputSize;
|
|
81
|
-
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* Placeholder text displayed in the input field when no text is being typed.
|
|
105
|
+
* Visible even when tags are present. Use to guide users on what type of
|
|
106
|
+
* values to enter.
|
|
107
|
+
* @default 'Add tag...'
|
|
108
|
+
*/
|
|
82
109
|
placeholder ?: string;
|
|
83
|
-
|
|
110
|
+
|
|
111
|
+
/**
|
|
112
|
+
* When true, the input is disabled and no tags can be added or removed.
|
|
113
|
+
* Existing tags remain visible but the delete buttons are non-functional.
|
|
114
|
+
* The entire component appears with reduced opacity.
|
|
115
|
+
* @default false
|
|
116
|
+
*/
|
|
84
117
|
disabled ?: boolean;
|
|
85
|
-
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* Maximum number of tags allowed. When the limit is reached, the input field
|
|
121
|
+
* is disabled (preventing new tags) but existing tags can still be removed.
|
|
122
|
+
* Useful for limiting selections in constrained contexts like form fields.
|
|
123
|
+
*/
|
|
86
124
|
max ?: number;
|
|
87
|
-
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* When true, pasting text containing separators (commas, semicolons, newlines)
|
|
128
|
+
* automatically creates multiple tags. When false, pasted text is inserted as
|
|
129
|
+
* a single value in the input field.
|
|
130
|
+
* @default true
|
|
131
|
+
*/
|
|
88
132
|
addOnPaste ?: boolean;
|
|
89
|
-
|
|
133
|
+
|
|
134
|
+
/**
|
|
135
|
+
* Semantic color kind specifically for the tag badges. When not set, inherits
|
|
136
|
+
* from the `kind` prop. Use to differentiate tag appearance from the input
|
|
137
|
+
* styling, such as colorful tags in a neutral-bordered input.
|
|
138
|
+
*/
|
|
90
139
|
tagKind ?: string;
|
|
91
|
-
|
|
140
|
+
|
|
141
|
+
/**
|
|
142
|
+
* Visual variant for the tag badges. 'solid' renders filled tags with colored
|
|
143
|
+
* background, 'outline' shows bordered tags with transparent background, and
|
|
144
|
+
* 'ghost' provides subtle tags with minimal styling.
|
|
145
|
+
* @default 'solid'
|
|
146
|
+
*/
|
|
92
147
|
tagVariant ?: 'solid' | 'outline' | 'ghost';
|
|
93
148
|
}
|
|
94
149
|
|
|
@@ -107,6 +162,12 @@
|
|
|
107
162
|
|
|
108
163
|
//------------------------------------------------------------------------------------------------------------------
|
|
109
164
|
|
|
165
|
+
/**
|
|
166
|
+
* The array of tag values. Use with `v-model` for two-way binding. Each string
|
|
167
|
+
* in the array represents one tag displayed in the input. Tags maintain their
|
|
168
|
+
* order as entered by the user.
|
|
169
|
+
* @default []
|
|
170
|
+
*/
|
|
110
171
|
const modelValue = defineModel<string[]>({ default: () => [] });
|
|
111
172
|
|
|
112
173
|
//------------------------------------------------------------------------------------------------------------------
|