@skewedaspect/sleekspace-ui 0.2.0-beta.1 → 0.2.0-beta.2
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 -2
- 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 +2 -4
- 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/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
|
@@ -16,8 +16,39 @@
|
|
|
16
16
|
<script setup lang="ts">
|
|
17
17
|
/**
|
|
18
18
|
* @component SkSkeleton
|
|
19
|
-
* A loading placeholder component
|
|
20
|
-
*
|
|
19
|
+
* @description A loading placeholder component that displays animated shapes to indicate content is being fetched.
|
|
20
|
+
* Skeletons improve perceived performance by showing users the expected layout before data arrives. Supports
|
|
21
|
+
* multiple shape variants (text, rectangular, circular, square) with customizable dimensions and beveled corners
|
|
22
|
+
* to match the design system aesthetic.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* ```vue
|
|
26
|
+
* <!-- Text placeholder -->
|
|
27
|
+
* <SkSkeleton variant="text" width="200px" />
|
|
28
|
+
*
|
|
29
|
+
* <!-- Avatar placeholder -->
|
|
30
|
+
* <SkSkeleton variant="circular" width="48px" />
|
|
31
|
+
*
|
|
32
|
+
* <!-- Card image placeholder with beveled corners -->
|
|
33
|
+
* <SkSkeleton
|
|
34
|
+
* variant="rectangular"
|
|
35
|
+
* width="100%"
|
|
36
|
+
* height="200px"
|
|
37
|
+
* :corners="['top-left', 'top-right']"
|
|
38
|
+
* />
|
|
39
|
+
* ```
|
|
40
|
+
*
|
|
41
|
+
* @example Loading card skeleton
|
|
42
|
+
* ```vue
|
|
43
|
+
* <SkCard>
|
|
44
|
+
* <template #media>
|
|
45
|
+
* <SkSkeleton variant="rectangular" height="180px" />
|
|
46
|
+
* </template>
|
|
47
|
+
* <SkSkeleton variant="text" width="70%" />
|
|
48
|
+
* <SkSkeleton variant="text" width="100%" />
|
|
49
|
+
* <SkSkeleton variant="text" width="40%" />
|
|
50
|
+
* </SkCard>
|
|
51
|
+
* ```
|
|
21
52
|
*/
|
|
22
53
|
|
|
23
54
|
import { computed } from 'vue';
|
|
@@ -29,17 +60,53 @@
|
|
|
29
60
|
|
|
30
61
|
export interface SkSkeletonComponentProps
|
|
31
62
|
{
|
|
32
|
-
/**
|
|
63
|
+
/**
|
|
64
|
+
* The shape variant that determines the skeleton's default proportions and styling.
|
|
65
|
+
* 'text' creates a short-height line suitable for text placeholders. 'rectangular'
|
|
66
|
+
* creates a flexible rectangle for images or content blocks. 'circular' creates a
|
|
67
|
+
* round shape for avatars. 'square' creates equal width/height with beveled corners.
|
|
68
|
+
* @default 'text'
|
|
69
|
+
*/
|
|
33
70
|
variant ?: SkSkeletonVariant;
|
|
34
|
-
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* The width of the skeleton. Accepts any valid CSS width value (px, rem, %, etc.).
|
|
74
|
+
* For responsive layouts, use percentage values. For fixed-size elements like avatars,
|
|
75
|
+
* use pixel or rem values.
|
|
76
|
+
* @default '100%'
|
|
77
|
+
*/
|
|
35
78
|
width ?: string;
|
|
36
|
-
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* The height of the skeleton. Accepts any valid CSS height value. When not specified,
|
|
82
|
+
* the height is determined by the variant (text has a small fixed height, circular and
|
|
83
|
+
* square match their width). Required for rectangular variant to have visible height.
|
|
84
|
+
* @default undefined (varies by variant)
|
|
85
|
+
*/
|
|
37
86
|
height ?: string;
|
|
38
|
-
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* The loading animation style. 'shimmer' creates a moving gradient highlight effect
|
|
90
|
+
* that sweeps across the skeleton. 'pulse' creates a fading opacity animation.
|
|
91
|
+
* 'none' disables animation for static placeholders.
|
|
92
|
+
* @default 'shimmer'
|
|
93
|
+
*/
|
|
39
94
|
animation ?: SkSkeletonAnimation;
|
|
40
|
-
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Array of corner positions to bevel, overriding the variant's default corner styling.
|
|
98
|
+
* Use this for skeletons that need to match specific card or panel layouts where only
|
|
99
|
+
* certain corners are beveled. Options: 'top-left', 'top-right', 'bottom-right', 'bottom-left'.
|
|
100
|
+
* @default undefined (uses variant default)
|
|
101
|
+
*/
|
|
41
102
|
corners ?: SkSkeletonCorner[];
|
|
42
|
-
|
|
103
|
+
|
|
104
|
+
/**
|
|
105
|
+
* Custom bevel size for beveled corners. Accepts any valid CSS length value.
|
|
106
|
+
* Only applies when `corners` prop is provided. Use this to match the bevel size
|
|
107
|
+
* of the component the skeleton is replacing.
|
|
108
|
+
* @default '0.5rem'
|
|
109
|
+
*/
|
|
43
110
|
bevel ?: string;
|
|
44
111
|
}
|
|
45
112
|
|
|
@@ -34,9 +34,20 @@
|
|
|
34
34
|
<script setup lang="ts">
|
|
35
35
|
/**
|
|
36
36
|
* @component SkSlider
|
|
37
|
-
* A range slider component for selecting numeric values.
|
|
38
|
-
*
|
|
39
|
-
*
|
|
37
|
+
* @description A range slider component for selecting numeric values within a defined range. Supports both
|
|
38
|
+
* single-value selection and multi-thumb range selection modes. Built on RekaUI's Slider primitive with
|
|
39
|
+
* full keyboard accessibility, beveled styling, and horizontal or vertical orientation.
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* ```vue
|
|
43
|
+
* <!-- Single value slider -->
|
|
44
|
+
* <SkSlider v-model="volume" :min="0" :max="100" kind="primary" />
|
|
45
|
+
*
|
|
46
|
+
* <!-- Range slider with two thumbs -->
|
|
47
|
+
* <SkSlider v-model="priceRange" :min="0" :max="1000" :step="10" />
|
|
48
|
+
* ```
|
|
49
|
+
*
|
|
50
|
+
* @slot - Not applicable. This component does not accept slot content.
|
|
40
51
|
*/
|
|
41
52
|
|
|
42
53
|
import { computed } from 'vue';
|
|
@@ -50,29 +61,94 @@
|
|
|
50
61
|
|
|
51
62
|
export interface SkSliderComponentProps
|
|
52
63
|
{
|
|
53
|
-
/**
|
|
64
|
+
/**
|
|
65
|
+
* The current value(s) of the slider. Pass a single number for a standard slider,
|
|
66
|
+
* or an array of numbers to create a range slider with multiple thumbs. The number
|
|
67
|
+
* of thumbs automatically matches the length of the array.
|
|
68
|
+
*/
|
|
54
69
|
modelValue : number | number[];
|
|
55
|
-
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* The minimum allowed value for the slider. The leftmost (or bottommost for vertical)
|
|
73
|
+
* position of the thumb corresponds to this value. Values outside the min/max range
|
|
74
|
+
* are clamped automatically.
|
|
75
|
+
* @default 0
|
|
76
|
+
*/
|
|
56
77
|
min ?: number;
|
|
57
|
-
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* The maximum allowed value for the slider. The rightmost (or topmost for vertical)
|
|
81
|
+
* position of the thumb corresponds to this value. Values outside the min/max range
|
|
82
|
+
* are clamped automatically.
|
|
83
|
+
* @default 100
|
|
84
|
+
*/
|
|
58
85
|
max ?: number;
|
|
59
|
-
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* The granularity of the slider. The value will snap to multiples of this step.
|
|
89
|
+
* For example, a step of 5 on a 0-100 slider allows values 0, 5, 10, ..., 100.
|
|
90
|
+
* Use smaller steps for fine-grained control or larger steps for discrete selections.
|
|
91
|
+
* @default 1
|
|
92
|
+
*/
|
|
60
93
|
step ?: number;
|
|
61
|
-
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Semantic color kind that controls the filled track and thumb appearance. Semantic
|
|
97
|
+
* kinds (neutral, primary, accent, etc.) adapt to your theme. Use custom colors via
|
|
98
|
+
* `baseColor` and `thumbColor` props for branding-specific styling.
|
|
99
|
+
* @default 'primary'
|
|
100
|
+
*/
|
|
62
101
|
kind ?: ComponentKind;
|
|
63
|
-
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* Size of the slider track and thumb. Controls the visual thickness of the track
|
|
105
|
+
* and diameter of the thumb. Available sizes: 'sm' (small), 'md' (medium), 'lg' (large).
|
|
106
|
+
* @default 'md'
|
|
107
|
+
*/
|
|
64
108
|
size ?: SkSliderSize;
|
|
65
|
-
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* Orientation of the slider layout. Use 'horizontal' for left-to-right value increase,
|
|
112
|
+
* or 'vertical' for bottom-to-top value increase. Keyboard navigation arrows adapt
|
|
113
|
+
* automatically based on orientation.
|
|
114
|
+
* @default 'horizontal'
|
|
115
|
+
*/
|
|
66
116
|
orientation ?: SkSliderOrientation;
|
|
67
|
-
|
|
117
|
+
|
|
118
|
+
/**
|
|
119
|
+
* When true, the slider is disabled and cannot be interacted with. The slider
|
|
120
|
+
* appears with reduced opacity and the cursor changes to not-allowed. Thumb
|
|
121
|
+
* positions remain visible but cannot be moved.
|
|
122
|
+
* @default false
|
|
123
|
+
*/
|
|
68
124
|
disabled ?: boolean;
|
|
69
|
-
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* The form field name used when submitting the slider value in a form.
|
|
128
|
+
* Required for native form submission. Each thumb value is submitted separately.
|
|
129
|
+
*/
|
|
70
130
|
name ?: string;
|
|
71
|
-
|
|
131
|
+
|
|
132
|
+
/**
|
|
133
|
+
* For range sliders (multiple thumbs), the minimum number of steps that must
|
|
134
|
+
* separate adjacent thumbs. Prevents thumbs from overlapping or crossing each
|
|
135
|
+
* other. A value of 0 allows thumbs to touch but not cross.
|
|
136
|
+
* @default 0
|
|
137
|
+
*/
|
|
72
138
|
minStepsBetweenThumbs ?: number;
|
|
73
|
-
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* Custom color for the filled portion of the track. Overrides the `kind` prop
|
|
142
|
+
* color when set. Use any valid CSS color value (hex, rgb, oklch, etc.).
|
|
143
|
+
* For complete customization, combine with `thumbColor`.
|
|
144
|
+
*/
|
|
74
145
|
baseColor ?: string;
|
|
75
|
-
|
|
146
|
+
|
|
147
|
+
/**
|
|
148
|
+
* Custom color for the slider thumb(s). Independent of the track color, allowing
|
|
149
|
+
* two-tone designs. Use any valid CSS color value. If not set, the thumb inherits
|
|
150
|
+
* styling from the current theme.
|
|
151
|
+
*/
|
|
76
152
|
thumbColor ?: string;
|
|
77
153
|
}
|
|
78
154
|
|
|
@@ -41,8 +41,29 @@
|
|
|
41
41
|
<script setup lang="ts">
|
|
42
42
|
/**
|
|
43
43
|
* @component SkSpinner
|
|
44
|
-
* An animated loading
|
|
45
|
-
*
|
|
44
|
+
* @description An animated loading indicator component with multiple visual variants. Use spinners to indicate
|
|
45
|
+
* that content is loading or an action is in progress. The component includes appropriate ARIA attributes
|
|
46
|
+
* (role="status", aria-live="polite") for screen reader accessibility.
|
|
47
|
+
*
|
|
48
|
+
* @example
|
|
49
|
+
* ```vue
|
|
50
|
+
* <SkSpinner kind="primary" />
|
|
51
|
+
* ```
|
|
52
|
+
*
|
|
53
|
+
* @example Different variants
|
|
54
|
+
* ```vue
|
|
55
|
+
* <SkSpinner variant="circular" />
|
|
56
|
+
* <SkSpinner variant="dots" />
|
|
57
|
+
* <SkSpinner variant="crosshair" />
|
|
58
|
+
* ```
|
|
59
|
+
*
|
|
60
|
+
* @example Loading button state
|
|
61
|
+
* ```vue
|
|
62
|
+
* <SkButton :disabled="loading">
|
|
63
|
+
* <SkSpinner v-if="loading" size="sm" color="currentColor" />
|
|
64
|
+
* <span v-else>Submit</span>
|
|
65
|
+
* </SkButton>
|
|
66
|
+
* ```
|
|
46
67
|
*/
|
|
47
68
|
|
|
48
69
|
import { computed } from 'vue';
|
|
@@ -55,13 +76,36 @@
|
|
|
55
76
|
|
|
56
77
|
export interface SkSpinnerComponentProps
|
|
57
78
|
{
|
|
58
|
-
/**
|
|
79
|
+
/**
|
|
80
|
+
* Semantic color kind that controls the spinner color. Semantic kinds (neutral, primary,
|
|
81
|
+
* accent, etc.) adapt to your theme. Use 'primary' for general loading states, or match
|
|
82
|
+
* the kind to the context (e.g., 'danger' when loading after an error action).
|
|
83
|
+
* @default 'primary'
|
|
84
|
+
*/
|
|
59
85
|
kind ?: ComponentKind;
|
|
60
|
-
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* Size of the spinner. Controls both the spinner dimensions and animation scale.
|
|
89
|
+
* Use 'sm' for inline loading indicators (e.g., inside buttons), 'md' for standard
|
|
90
|
+
* loading states, and 'lg' or 'xl' for full-page or section loading overlays.
|
|
91
|
+
* @default 'md'
|
|
92
|
+
*/
|
|
61
93
|
size ?: SkSpinnerSize;
|
|
62
|
-
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Animation variant that determines the spinner's visual style:
|
|
97
|
+
* - 'circular': Two concentric spinning arcs (default, most common)
|
|
98
|
+
* - 'dots': Three bouncing dots in sequence
|
|
99
|
+
* - 'crosshair': Rotating crosshair pattern (fits cyberpunk aesthetic)
|
|
100
|
+
* @default 'circular'
|
|
101
|
+
*/
|
|
63
102
|
variant ?: SkSpinnerVariant;
|
|
64
|
-
|
|
103
|
+
|
|
104
|
+
/**
|
|
105
|
+
* Custom color for the spinner, overriding the `kind` color. Accepts any valid CSS
|
|
106
|
+
* color value. Use "currentColor" to inherit the text color from the parent element,
|
|
107
|
+
* which is useful for spinners inside buttons or other colored containers.
|
|
108
|
+
*/
|
|
65
109
|
color ?: string;
|
|
66
110
|
}
|
|
67
111
|
|
|
@@ -61,63 +61,126 @@
|
|
|
61
61
|
|
|
62
62
|
<script setup lang="ts">
|
|
63
63
|
/**
|
|
64
|
-
* @component
|
|
65
|
-
* A toggle switch component for binary choices
|
|
66
|
-
* Supports dynamic labels that
|
|
64
|
+
* @component SkSwitch
|
|
65
|
+
* @description A toggle switch component for binary on/off choices. Built on RekaUI's Switch primitive with
|
|
66
|
+
* full keyboard accessibility (Space/Enter to toggle). Supports dynamic labels that animate when the state
|
|
67
|
+
* changes and separate theming for the track and thumb. Use with `v-model` for two-way binding.
|
|
68
|
+
*
|
|
69
|
+
* @example
|
|
70
|
+
* ```vue
|
|
71
|
+
* <SkSwitch v-model="enabled" label="Enable notifications" />
|
|
72
|
+
* <SkSwitch v-model="darkMode" label-on="Dark" label-off="Light" kind="primary" />
|
|
73
|
+
* <SkSwitch v-model="premium" base-color="oklch(0.7 0.25 45)" label="Premium" />
|
|
74
|
+
* ```
|
|
75
|
+
*
|
|
76
|
+
* @slot default - Custom label content that overrides all label props. Use for complex labels with icons.
|
|
77
|
+
* @slot label-on - Custom content for the "on" state label. Overrides `labelOn` prop when provided.
|
|
78
|
+
* @slot label-off - Custom content for the "off" state label. Overrides `labelOff` prop when provided.
|
|
67
79
|
*/
|
|
68
80
|
|
|
69
81
|
import { computed, toRef, useSlots } from 'vue';
|
|
70
82
|
import { SwitchRoot, SwitchThumb } from 'reka-ui';
|
|
71
|
-
|
|
83
|
+
|
|
84
|
+
// Types
|
|
72
85
|
import type { ComponentCustomColors } from '@/types';
|
|
86
|
+
import type { SkSwitchKind, SkSwitchSize } from './types';
|
|
87
|
+
|
|
88
|
+
// Composables
|
|
73
89
|
import { useCustomColors } from '@/composables/useCustomColors';
|
|
74
90
|
|
|
75
91
|
//------------------------------------------------------------------------------------------------------------------
|
|
76
92
|
|
|
77
|
-
/**
|
|
78
|
-
* A toggle switch component for binary choices powered by RekaUI.
|
|
79
|
-
* Supports dynamic labels that change based on state and flexible styling options.
|
|
80
|
-
*
|
|
81
|
-
* @example Basic switch
|
|
82
|
-
* ```vue
|
|
83
|
-
* <SkSwitch v-model="enabled" label="Enable notifications" />
|
|
84
|
-
* ```
|
|
85
|
-
*
|
|
86
|
-
* @example Custom colors
|
|
87
|
-
* ```vue
|
|
88
|
-
* <SkSwitch
|
|
89
|
-
* v-model="premium"
|
|
90
|
-
* base-color="oklch(0.7 0.25 45)"
|
|
91
|
-
* text-color="white"
|
|
92
|
-
* label="Premium Features"
|
|
93
|
-
* />
|
|
94
|
-
* ```
|
|
95
|
-
*/
|
|
96
93
|
export interface SkSwitchComponentProps extends ComponentCustomColors
|
|
97
94
|
{
|
|
98
|
-
/**
|
|
95
|
+
/**
|
|
96
|
+
* The current state of the switch. `true` means on (checked), `false` means off (unchecked).
|
|
97
|
+
* Use with `v-model` for two-way binding. Required prop that must be explicitly provided.
|
|
98
|
+
*/
|
|
99
99
|
modelValue : boolean;
|
|
100
|
-
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* Static label text displayed next to the switch. When `labelOn` or `labelOff` are not
|
|
103
|
+
* provided, this label remains constant regardless of switch state. Can be overridden
|
|
104
|
+
* by the default slot for custom label content.
|
|
105
|
+
* @default undefined
|
|
106
|
+
*/
|
|
101
107
|
label ?: string;
|
|
102
|
-
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* Label text displayed when the switch is in the "on" (true) state. When provided along
|
|
111
|
+
* with `labelOff`, the label animates between the two values as the switch toggles.
|
|
112
|
+
* Falls back to `label` prop if not provided.
|
|
113
|
+
* @default undefined
|
|
114
|
+
*/
|
|
103
115
|
labelOn ?: string;
|
|
104
|
-
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Label text displayed when the switch is in the "off" (false) state. When provided along
|
|
119
|
+
* with `labelOn`, the label animates between the two values as the switch toggles.
|
|
120
|
+
* Falls back to `label` prop if not provided.
|
|
121
|
+
* @default undefined
|
|
122
|
+
*/
|
|
105
123
|
labelOff ?: string;
|
|
106
|
-
|
|
124
|
+
|
|
125
|
+
/**
|
|
126
|
+
* Semantic color kind for the switch track (background). Controls the color when the
|
|
127
|
+
* switch is in the "on" state. The "off" state uses a neutral muted color by default.
|
|
128
|
+
* @default 'neutral'
|
|
129
|
+
*/
|
|
107
130
|
kind ?: SkSwitchKind;
|
|
108
|
-
|
|
131
|
+
|
|
132
|
+
/**
|
|
133
|
+
* Semantic color kind for the switch thumb (the sliding circle). When provided, overrides
|
|
134
|
+
* the default thumb color derived from the main `kind`. Use for two-tone switch designs
|
|
135
|
+
* where the thumb should be a different color than the track.
|
|
136
|
+
* @default undefined
|
|
137
|
+
*/
|
|
109
138
|
thumbKind ?: SkSwitchKind;
|
|
110
|
-
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* Switch size controlling the track dimensions, thumb size, and label text size.
|
|
142
|
+
* Available sizes: 'sm' (small), 'md' (medium, default), 'lg' (large), 'xl' (extra large).
|
|
143
|
+
* @default 'md'
|
|
144
|
+
*/
|
|
111
145
|
size ?: SkSwitchSize;
|
|
112
|
-
|
|
146
|
+
|
|
147
|
+
/**
|
|
148
|
+
* When true, disables the switch preventing all user interaction. The switch appears
|
|
149
|
+
* with reduced opacity and the cursor changes to not-allowed. Disabled switches are
|
|
150
|
+
* excluded from form submission.
|
|
151
|
+
* @default false
|
|
152
|
+
*/
|
|
113
153
|
disabled ?: boolean;
|
|
114
|
-
|
|
154
|
+
|
|
155
|
+
/**
|
|
156
|
+
* When true, disables the fade animation when switching between `labelOn` and `labelOff`
|
|
157
|
+
* labels. The label will change instantly instead of cross-fading. Has no effect if
|
|
158
|
+
* only a static `label` is provided.
|
|
159
|
+
* @default false
|
|
160
|
+
*/
|
|
115
161
|
disableLabelAnimation ?: boolean;
|
|
116
|
-
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
* The form field name used when submitting the switch value. When the switch is on,
|
|
165
|
+
* the `value` prop is submitted under this name. When off, nothing is submitted
|
|
166
|
+
* (standard checkbox behavior).
|
|
167
|
+
* @default undefined
|
|
168
|
+
*/
|
|
117
169
|
name ?: string;
|
|
118
|
-
|
|
170
|
+
|
|
171
|
+
/**
|
|
172
|
+
* The value submitted with the form when the switch is on. Combined with the `name`
|
|
173
|
+
* prop for form submission. When the switch is off, this value is not submitted.
|
|
174
|
+
* @default 'on'
|
|
175
|
+
*/
|
|
119
176
|
value ?: string;
|
|
120
|
-
|
|
177
|
+
|
|
178
|
+
/**
|
|
179
|
+
* When true, marks the switch as required for form validation. The browser will prevent
|
|
180
|
+
* form submission if the switch is not in the "on" state. Use for mandatory agreements
|
|
181
|
+
* or confirmations.
|
|
182
|
+
* @default false
|
|
183
|
+
*/
|
|
121
184
|
required ?: boolean;
|
|
122
185
|
}
|
|
123
186
|
|
|
@@ -21,39 +21,103 @@
|
|
|
21
21
|
|
|
22
22
|
<script setup lang="ts">
|
|
23
23
|
/**
|
|
24
|
-
* @component
|
|
25
|
-
* A flexible table component with
|
|
26
|
-
*
|
|
24
|
+
* @component SkTable
|
|
25
|
+
* @description A flexible data table component with beveled corner styling and extensive visual customization.
|
|
26
|
+
* Use SkTable as a wrapper around standard HTML table elements (`<thead>`, `<tbody>`, `<tr>`, `<th>`, `<td>`).
|
|
27
|
+
* Supports row striping, hover highlighting, configurable borders, and adapts to both light and dark backgrounds.
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```vue
|
|
31
|
+
* <SkTable striped hoverable>
|
|
32
|
+
* <thead>
|
|
33
|
+
* <tr><th>Name</th><th>Status</th></tr>
|
|
34
|
+
* </thead>
|
|
35
|
+
* <tbody>
|
|
36
|
+
* <tr><td>Item 1</td><td>Active</td></tr>
|
|
37
|
+
* <tr><td>Item 2</td><td>Pending</td></tr>
|
|
38
|
+
* </tbody>
|
|
39
|
+
* </SkTable>
|
|
40
|
+
* ```
|
|
41
|
+
*
|
|
42
|
+
* @slot default - Standard HTML table content including `<thead>`, `<tbody>`, `<tfoot>`, `<tr>`, `<th>`,
|
|
43
|
+
* and `<td>` elements.
|
|
27
44
|
*/
|
|
28
45
|
|
|
29
46
|
import { computed, toRef } from 'vue';
|
|
47
|
+
|
|
48
|
+
// Types
|
|
30
49
|
import type { SkTableKind, SkTableVariant } from './types';
|
|
31
50
|
import type { ComponentCustomColors } from '@/types';
|
|
51
|
+
|
|
52
|
+
// Composables
|
|
32
53
|
import { useCustomColors } from '@/composables/useCustomColors';
|
|
33
54
|
|
|
34
55
|
//------------------------------------------------------------------------------------------------------------------
|
|
35
56
|
|
|
36
|
-
/**
|
|
37
|
-
* A flexible table component with clean, rounded styling.
|
|
38
|
-
* Supports various visual styles including striping, hover effects, and custom borders.
|
|
39
|
-
*/
|
|
40
57
|
export interface SkTableComponentProps extends ComponentCustomColors
|
|
41
58
|
{
|
|
42
|
-
/**
|
|
59
|
+
/**
|
|
60
|
+
* Semantic color kind that controls header backgrounds and accent colors. The kind
|
|
61
|
+
* affects the table header row styling and can subtly influence row hover colors.
|
|
62
|
+
* Use semantic kinds to match your application's color language.
|
|
63
|
+
* @default 'neutral'
|
|
64
|
+
*/
|
|
43
65
|
kind ?: SkTableKind;
|
|
44
|
-
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* Controls the table's density and spacing. 'default' provides comfortable spacing
|
|
69
|
+
* for most use cases, 'compact' reduces padding for dense data displays, and
|
|
70
|
+
* 'comfortable' increases spacing for enhanced readability.
|
|
71
|
+
* @default 'default'
|
|
72
|
+
*/
|
|
45
73
|
variant ?: SkTableVariant;
|
|
46
|
-
|
|
74
|
+
|
|
75
|
+
/**
|
|
76
|
+
* When true, alternates row background colors (zebra striping) to improve
|
|
77
|
+
* readability of wide tables. The striping color adapts to the table's kind
|
|
78
|
+
* and background context.
|
|
79
|
+
* @default false
|
|
80
|
+
*/
|
|
47
81
|
striped ?: boolean;
|
|
48
|
-
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* When true, rows highlight on mouse hover to help users track which row
|
|
85
|
+
* they're viewing. Particularly useful for tables with many columns where
|
|
86
|
+
* the eye can lose track across the row.
|
|
87
|
+
* @default true
|
|
88
|
+
*/
|
|
49
89
|
hoverable ?: boolean;
|
|
50
|
-
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* When true, displays a beveled border around the entire table. Disable for
|
|
93
|
+
* a more minimal appearance or when embedding the table in a card that already
|
|
94
|
+
* provides visual containment.
|
|
95
|
+
* @default true
|
|
96
|
+
*/
|
|
51
97
|
bordered ?: boolean;
|
|
52
|
-
|
|
98
|
+
|
|
99
|
+
/**
|
|
100
|
+
* When true, shows borders between individual cells and rows. Enable for
|
|
101
|
+
* grid-like data where cell boundaries need clear visual separation. Disable
|
|
102
|
+
* for a cleaner, more modern appearance.
|
|
103
|
+
* @default false
|
|
104
|
+
*/
|
|
53
105
|
innerBorders ?: boolean;
|
|
54
|
-
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* When true, adjusts the table colors for display on dark backgrounds. This
|
|
109
|
+
* ensures proper contrast and visibility when the table is placed on dark
|
|
110
|
+
* surfaces outside of the normal theme context.
|
|
111
|
+
* @default false
|
|
112
|
+
*/
|
|
55
113
|
darkBackground ?: boolean;
|
|
56
|
-
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* When true, uses lighter, more subdued colors for the table styling. Useful
|
|
117
|
+
* when the table should not dominate the visual hierarchy or when displaying
|
|
118
|
+
* secondary data alongside more prominent content.
|
|
119
|
+
* @default false
|
|
120
|
+
*/
|
|
57
121
|
subtle ?: boolean;
|
|
58
122
|
}
|
|
59
123
|
|
|
@@ -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
|
|