@livestorm/ui-vue 1.1.3 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +164 -32
- package/components-vite.js +5 -5
- package/components.d.ts +3 -3
- package/dist/UiTimelineItem.vue_vue_type_style_index_0_lang-DOLFRKcb.mjs +5565 -0
- package/dist/a11y-DIdrv5Mn.mjs +66 -0
- package/dist/breakpoints.mjs +9 -0
- package/dist/bus.mjs +5 -0
- package/dist/components.mjs +214 -1663
- package/dist/index.mjs +84 -166
- package/dist/integrations.mjs +8 -0
- package/dist/layouts.mjs +236 -0
- package/dist/responsive.mjs +25 -0
- package/dist/slot.mjs +21 -0
- package/dist/toastDSV2-wMh-UMzW.mjs +74 -0
- package/dist/types/index.d.ts +84 -0
- package/dist/types/src/components/Toast/LayoutToasts.vue.d.ts +3 -0
- package/dist/types/src/components/Toast/ToastMessage.vue.d.ts +21 -0
- package/dist/types/src/components/Toast/toastDSV2.d.ts +102 -0
- package/dist/types/src/components/UiActionBar/UiActionBar.vue.d.ts +44 -0
- package/dist/types/src/components/UiActionBar/UiActionBarItem.vue.d.ts +47 -0
- package/dist/types/src/components/UiActionBar/UiActionBarSeparator.vue.d.ts +3 -0
- package/dist/types/src/components/UiActionBar/index.d.ts +4 -0
- package/dist/types/src/components/UiActionBar/types.d.ts +14 -0
- package/dist/types/src/components/UiAnimatedLogo/UiAnimatedLogo.vue.d.ts +10 -0
- package/dist/types/src/components/UiAnimatedLogo/animations-links.d.ts +3 -0
- package/dist/types/src/components/UiAvatar/UiAvatar.vue.d.ts +55 -0
- package/dist/types/src/components/UiAvatar/index.d.ts +1 -0
- package/dist/types/src/components/UiAvatarList/UiAvatarList.vue.d.ts +28 -0
- package/dist/types/src/components/UiAvatarList/index.d.ts +1 -0
- package/dist/types/src/components/UiBadge/UiBadge.vue.d.ts +47 -0
- package/dist/types/src/components/UiBadge/index.d.ts +1 -0
- package/dist/types/src/components/UiBanner/UiBanner.vue.d.ts +96 -0
- package/dist/types/src/components/UiBanner/index.d.ts +2 -0
- package/dist/types/src/components/UiBreadcrumb/UiBreadcrumb.vue.d.ts +15 -0
- package/dist/types/src/components/UiBreadcrumb/index.d.ts +2 -0
- package/dist/types/src/components/UiButton/UiButton.vue.d.ts +249 -0
- package/dist/types/src/components/UiButtonGroup/UiButtonGroup.vue.d.ts +42 -0
- package/dist/types/src/components/UiButtonGroup/UiButtonGroupItem.vue.d.ts +21 -0
- package/dist/types/src/components/UiButtonGroup/index.d.ts +3 -0
- package/dist/types/src/components/UiButtonGroup/types.d.ts +10 -0
- package/dist/types/src/components/UiCard/UiCard.vue.d.ts +31 -0
- package/dist/types/src/components/UiCarousel/UiCarousel.vue.d.ts +63 -0
- package/dist/types/src/components/UiCarousel/index.d.ts +2 -0
- package/dist/types/src/components/UiColorField/UiColorField.vue.d.ts +19 -0
- package/dist/types/src/components/UiColorField/index.d.ts +2 -0
- package/dist/types/src/components/UiColorField/types.d.ts +29 -0
- package/dist/types/src/components/UiColorPicker/UiColorPicker.vue.d.ts +35 -0
- package/dist/types/src/components/UiColorPicker/index.d.ts +2 -0
- package/dist/types/src/components/UiColorPicker/types.d.ts +97 -0
- package/dist/types/src/components/UiDialog/MarketplaceHeaderExample.vue.d.ts +28 -0
- package/dist/types/src/components/UiDialog/UiDialog.vue.d.ts +18 -0
- package/dist/types/src/components/UiDialog/UiDialogClose.vue.d.ts +10 -0
- package/dist/types/src/components/UiDialog/UiDialogContent.vue.d.ts +54 -0
- package/dist/types/src/components/UiDialog/UiDialogFooter.vue.d.ts +13 -0
- package/dist/types/src/components/UiDialog/UiDialogTrigger.vue.d.ts +14 -0
- package/dist/types/src/components/UiDialog/index.d.ts +7 -0
- package/dist/types/src/components/UiDropdown/UiDropdown.vue.d.ts +42 -0
- package/dist/types/src/components/UiDropdown/UiDropdownContent.vue.d.ts +32 -0
- package/dist/types/src/components/UiDropdown/UiDropdownItem.vue.d.ts +27 -0
- package/dist/types/src/components/UiDropdown/UiDropdownSeparator.vue.d.ts +3 -0
- package/dist/types/src/components/UiDropdown/UiDropdownTrigger.vue.d.ts +45 -0
- package/dist/types/src/components/UiDropdown/context.d.ts +7 -0
- package/dist/types/src/components/UiDropdown/index.d.ts +6 -0
- package/dist/types/src/components/UiEmptyState/UiEmptyState.vue.d.ts +29 -0
- package/dist/types/src/components/UiFieldWrapper/UiFieldWrapper.vue.d.ts +36 -0
- package/dist/types/src/components/UiFieldWrapper/index.d.ts +1 -0
- package/dist/types/src/components/UiForm/UiFormField.types.d.ts +22 -0
- package/dist/types/src/components/UiForm/UiFormField.vue.d.ts +34 -0
- package/dist/types/src/components/UiForm/index.d.ts +3 -0
- package/dist/types/src/components/UiHorizontalSeparator/UiHorizontalSeparator.vue.d.ts +6 -0
- package/dist/types/src/components/UiInputCheckbox/UiInputCheckbox.vue.d.ts +108 -0
- package/dist/types/src/components/UiInputCheckbox/index.d.ts +2 -0
- package/dist/types/src/components/UiInputCheckbox/types.d.ts +1 -0
- package/dist/types/src/components/UiInputSelect/UiInputSelect.vue.d.ts +66 -0
- package/dist/types/src/components/UiInputSelect/index.d.ts +2 -0
- package/dist/types/src/components/UiInputSelect/types.d.ts +1 -0
- package/dist/types/src/components/UiInputTextarea/UiInputTextarea.vue.d.ts +49 -0
- package/dist/types/src/components/UiInputTextarea/index.d.ts +2 -0
- package/dist/types/src/components/UiInputTextarea/types.d.ts +1 -0
- package/dist/types/src/components/UiLabel/UiLabel.vue.d.ts +17 -0
- package/dist/types/src/components/UiList/UiList.vue.d.ts +27 -0
- package/dist/types/src/components/UiListItem/UiListItem.vue.d.ts +35 -0
- package/dist/types/src/components/UiLoader/UiLoader.vue.d.ts +17 -0
- package/dist/types/src/components/UiLogo/UiLogo.vue.d.ts +20 -0
- package/dist/types/src/components/UiLogo/variants/PulseVariant.vue.d.ts +3 -0
- package/dist/types/src/components/UiLogo/variants/TornadoVariant.vue.d.ts +3 -0
- package/dist/types/src/components/UiMenu/UiMenu.vue.d.ts +18 -0
- package/dist/types/src/components/UiMenu/UiMenuContent.vue.d.ts +30 -0
- package/dist/types/src/components/UiMenu/UiMenuGroup.vue.d.ts +16 -0
- package/dist/types/src/components/UiMenu/UiMenuItem.vue.d.ts +18 -0
- package/dist/types/src/components/UiMenu/UiMenuLabel.vue.d.ts +13 -0
- package/dist/types/src/components/UiMenu/UiMenuSeparator.vue.d.ts +13 -0
- package/dist/types/src/components/UiMenu/UiMenuSub.vue.d.ts +18 -0
- package/dist/types/src/components/UiMenu/UiMenuSubContent.vue.d.ts +32 -0
- package/dist/types/src/components/UiMenu/UiMenuSubTrigger.vue.d.ts +14 -0
- package/dist/types/src/components/UiMenu/UiMenuTrigger.vue.d.ts +14 -0
- package/dist/types/src/components/UiMenu/index.d.ts +10 -0
- package/dist/types/src/components/UiPage/UiPage.vue.d.ts +37 -0
- package/dist/types/src/components/UiPageHeader/UiPageHeader.vue.d.ts +33 -0
- package/dist/types/src/components/UiPopover/UiPopover.vue.d.ts +18 -0
- package/dist/types/src/components/UiPopover/UiPopoverAnchor.vue.d.ts +14 -0
- package/dist/types/src/components/UiPopover/UiPopoverContent.vue.d.ts +28 -0
- package/dist/types/src/components/UiPopover/UiPopoverTrigger.vue.d.ts +14 -0
- package/dist/types/src/components/UiProgress/UiProgress.vue.d.ts +15 -0
- package/dist/types/src/components/UiProgress/index.d.ts +2 -0
- package/dist/types/src/components/UiProgress/types.d.ts +4 -0
- package/dist/types/src/components/UiRoomButton/UiRoomButton.vue.d.ts +29 -0
- package/dist/types/src/components/UiShell/UiShell.vue.d.ts +24 -0
- package/dist/types/src/components/UiSideMenu/UiSideMenu.vue.d.ts +64 -0
- package/dist/types/src/components/UiSideMenu/UiSideMenuBottom.vue.d.ts +7 -0
- package/dist/types/src/components/UiSideMenu/UiSideMenuItem.vue.d.ts +53 -0
- package/dist/types/src/components/UiSideMenu/UiSideMenuItemContent.vue.d.ts +43 -0
- package/dist/types/src/components/UiSideMenu/UiSideMenuTop.vue.d.ts +7 -0
- package/dist/types/src/components/UiSideMenu/injection.d.ts +7 -0
- package/dist/types/src/components/UiSideMenu/types.d.ts +39 -0
- package/dist/types/src/components/UiSideMenu/useLabelHidden.d.ts +2 -0
- package/dist/types/src/components/UiSideMenu/useSideMenuLayout.d.ts +7 -0
- package/dist/types/src/components/UiStepper/UiStepper.vue.d.ts +18 -0
- package/dist/types/src/components/UiStepper/UiStepperDescription.vue.d.ts +14 -0
- package/dist/types/src/components/UiStepper/UiStepperIndicator.vue.d.ts +20 -0
- package/dist/types/src/components/UiStepper/UiStepperItem.vue.d.ts +19 -0
- package/dist/types/src/components/UiStepper/UiStepperSeparator.vue.d.ts +10 -0
- package/dist/types/src/components/UiStepper/UiStepperTitle.vue.d.ts +14 -0
- package/dist/types/src/components/UiStepper/index.d.ts +7 -0
- package/dist/types/src/components/UiTable/UiTable.vue.d.ts +20 -0
- package/dist/types/src/components/UiTable/UiTableBody.vue.d.ts +13 -0
- package/dist/types/src/components/UiTable/UiTableCell.vue.d.ts +13 -0
- package/dist/types/src/components/UiTable/UiTableHeader.vue.d.ts +13 -0
- package/dist/types/src/components/UiTable/UiTableHeaderCell.vue.d.ts +13 -0
- package/dist/types/src/components/UiTable/UiTableRow.vue.d.ts +16 -0
- package/dist/types/src/components/UiTable/index.d.ts +6 -0
- package/dist/types/src/components/UiTabs/UiTabs.vue.d.ts +37 -0
- package/dist/types/src/components/UiTabs/index.d.ts +2 -0
- package/dist/types/src/components/UiTag/UiTag.vue.d.ts +43 -0
- package/dist/types/src/components/UiTag/index.d.ts +1 -0
- package/dist/types/src/components/UiTextField/UiTextField.vue.d.ts +65 -0
- package/dist/types/src/components/UiTextField/index.d.ts +2 -0
- package/dist/types/src/components/UiTextField/types.d.ts +2 -0
- package/dist/types/src/components/UiTimeline/UiTimeline.vue.d.ts +19 -0
- package/dist/types/src/components/UiTimeline/UiTimelineItem.vue.d.ts +28 -0
- package/dist/types/src/components/UiTimeline/index.d.ts +2 -0
- package/dist/types/src/components/UiTooltip/UiTooltip.vue.d.ts +18 -0
- package/dist/types/src/components/UiTooltip/UiTooltipContent.vue.d.ts +54 -0
- package/dist/types/src/components/UiTooltip/UiTooltipProvider.vue.d.ts +17 -0
- package/dist/types/src/components/UiTooltip/UiTooltipTrigger.vue.d.ts +14 -0
- package/dist/types/src/components/UiTooltip/index.d.ts +4 -0
- package/dist/types/src/composables/useButtonStyles.d.ts +20 -0
- package/dist/types/src/composables/useMobileMenu.d.ts +11 -0
- package/dist/types/src/composables/useThemeAndModes.d.ts +34 -0
- package/dist/types/src/constants/index.d.ts +2 -0
- package/dist/types/src/constants/sizes.d.ts +2 -0
- package/dist/types/src/constants/themes.d.ts +22 -0
- package/dist/types/src/integrations/index.d.ts +1 -0
- package/dist/types/src/layouts/index.d.ts +2 -0
- package/dist/types/src/mixins/DynamicAction.d.ts +30 -0
- package/dist/types/src/primitives.d.ts +6 -0
- package/dist/types/src/theme.d.ts +1 -0
- package/dist/types/src/utils/a11y.d.ts +2 -0
- package/dist/types/src/utils/breakpoints.d.ts +9 -0
- package/dist/types/src/utils/bus.d.ts +2 -0
- package/dist/types/src/utils/clipboard.d.ts +4 -0
- package/dist/types/src/utils/devices.d.ts +19 -0
- package/dist/types/src/utils/elements.d.ts +1 -0
- package/dist/types/src/utils/index.d.ts +9 -0
- package/dist/types/src/utils/numbers.d.ts +30 -0
- package/dist/types/src/utils/responsive.d.ts +5 -0
- package/dist/types/src/utils/responsive.types.d.ts +12 -0
- package/dist/types/src/utils/router.d.ts +1 -0
- package/dist/types/src/utils/slot.d.ts +8 -0
- package/dist/types/src/utils/stack-view.d.ts +10 -0
- package/dist/types/src/utils/uid.d.ts +1 -0
- package/dist/types/style.d.ts +1 -0
- package/dist/ui-vue.css +1 -0
- package/dist/useThemeAndModes-DY5SDC0a.mjs +109 -0
- package/dist/utils.mjs +111 -0
- package/index.d.ts +88 -2
- package/index.js +169 -16
- package/integrations.d.ts +10 -0
- package/package.json +131 -63
- package/src/components/Toast/LayoutToasts.vue +63 -0
- package/src/components/Toast/ToastMessage.vue +208 -0
- package/src/components/Toast/toastDSV2.ts +151 -0
- package/src/components/UiActionBar/UiActionBar.vue +86 -0
- package/src/components/UiActionBar/UiActionBarItem.vue +179 -0
- package/src/components/UiActionBar/UiActionBarSeparator.vue +18 -0
- package/src/components/UiActionBar/index.ts +4 -0
- package/src/components/UiActionBar/types.ts +24 -0
- package/src/components/UiAnimatedLogo/UiAnimatedLogo.vue +47 -0
- package/src/components/UiAnimatedLogo/animations-links.ts +6 -0
- package/src/components/UiAvatar/UiAvatar.vue +186 -0
- package/src/components/UiAvatar/index.js +1 -0
- package/src/components/UiAvatarList/UiAvatarList.vue +109 -0
- package/src/components/UiAvatarList/index.js +1 -0
- package/src/components/UiBadge/UiBadge.vue +161 -0
- package/src/components/UiBadge/index.ts +2 -0
- package/src/components/UiBanner/UiBanner.vue +363 -0
- package/src/components/UiBanner/index.ts +2 -0
- package/src/components/UiBreadcrumb/UiBreadcrumb.vue +93 -0
- package/src/components/UiBreadcrumb/index.ts +2 -0
- package/src/components/UiButton/UiButton.vue +319 -0
- package/src/components/UiButtonGroup/UiButtonGroup.vue +198 -0
- package/src/components/UiButtonGroup/UiButtonGroupItem.vue +123 -0
- package/src/components/UiButtonGroup/index.ts +3 -0
- package/src/components/UiButtonGroup/types.ts +24 -0
- package/src/components/UiCard/UiCard.vue +112 -0
- package/src/components/UiCarousel/UiCarousel.vue +215 -0
- package/src/components/UiCarousel/index.ts +2 -0
- package/src/components/UiColorField/UiColorField.vue +158 -0
- package/src/components/UiColorField/index.ts +2 -0
- package/src/components/UiColorField/types.ts +30 -0
- package/src/components/UiColorPicker/UiColorPicker.vue +487 -0
- package/src/components/UiColorPicker/index.ts +2 -0
- package/src/components/UiColorPicker/types.ts +103 -0
- package/src/components/UiDialog/MarketplaceHeaderExample.vue +217 -0
- package/src/components/UiDialog/UiDialog.md +97 -0
- package/src/components/UiDialog/UiDialog.vue +16 -0
- package/src/components/UiDialog/UiDialogClose.vue +29 -0
- package/src/components/UiDialog/UiDialogContent.vue +238 -0
- package/src/components/UiDialog/UiDialogFooter.vue +9 -0
- package/src/components/UiDialog/UiDialogTrigger.vue +12 -0
- package/src/components/UiDialog/index.ts +18 -0
- package/src/components/UiDropdown/UiDropdown.vue +48 -0
- package/src/components/UiDropdown/UiDropdownContent.vue +72 -0
- package/src/components/UiDropdown/UiDropdownItem.vue +75 -0
- package/src/components/UiDropdown/UiDropdownSeparator.vue +7 -0
- package/src/components/UiDropdown/UiDropdownTrigger.vue +239 -0
- package/src/components/UiDropdown/context.ts +9 -0
- package/src/components/UiDropdown/index.ts +21 -0
- package/src/components/UiEmptyState/UiEmptyState.vue +80 -0
- package/src/components/UiFieldWrapper/UiFieldWrapper.vue +79 -0
- package/src/components/UiFieldWrapper/index.ts +1 -0
- package/src/components/UiForm/UiFormField.types.ts +24 -0
- package/src/components/UiForm/UiFormField.vue +66 -0
- package/src/components/UiForm/index.ts +3 -0
- package/src/components/UiHorizontalSeparator/UiHorizontalSeparator.vue +28 -0
- package/src/components/UiInputCheckbox/UiInputCheckbox.vue +477 -0
- package/src/components/UiInputCheckbox/index.ts +2 -0
- package/src/components/UiInputCheckbox/types.ts +1 -0
- package/src/components/UiInputSelect/UiInputSelect.vue +166 -0
- package/src/components/UiInputSelect/index.ts +2 -0
- package/src/components/UiInputSelect/types.ts +1 -0
- package/src/components/UiInputTextarea/UiInputTextarea.vue +219 -0
- package/src/components/UiInputTextarea/index.ts +2 -0
- package/src/components/UiInputTextarea/types.ts +1 -0
- package/src/components/UiLabel/UiLabel.vue +34 -0
- package/src/components/UiList/UiList.vue +45 -0
- package/src/components/UiListItem/UiListItem.vue +108 -0
- package/src/components/UiLoader/UiLoader.vue +45 -0
- package/src/components/UiLogo/UiLogo.vue +99 -0
- package/src/components/UiLogo/variants/PulseVariant.vue +51 -0
- package/src/components/UiLogo/variants/TornadoVariant.vue +147 -0
- package/src/components/UiMenu/UiMenu.vue +15 -0
- package/src/components/UiMenu/UiMenuContent.vue +25 -0
- package/src/components/UiMenu/UiMenuGroup.vue +19 -0
- package/src/components/UiMenu/UiMenuItem.vue +18 -0
- package/src/components/UiMenu/UiMenuLabel.vue +9 -0
- package/src/components/UiMenu/UiMenuSeparator.vue +9 -0
- package/src/components/UiMenu/UiMenuSub.vue +15 -0
- package/src/components/UiMenu/UiMenuSubContent.vue +23 -0
- package/src/components/UiMenu/UiMenuSubTrigger.vue +17 -0
- package/src/components/UiMenu/UiMenuTrigger.vue +13 -0
- package/src/components/UiMenu/index.ts +10 -0
- package/src/components/UiPage/UiPage.vue +201 -0
- package/src/components/UiPageHeader/UiPageHeader.vue +128 -0
- package/src/components/UiPopover/UiPopover.vue +16 -0
- package/src/components/UiPopover/UiPopoverAnchor.vue +12 -0
- package/src/components/UiPopover/UiPopoverContent.vue +26 -0
- package/src/components/UiPopover/UiPopoverTrigger.vue +19 -0
- package/src/components/UiProgress/UiProgress.vue +92 -0
- package/src/components/UiProgress/index.ts +2 -0
- package/src/components/UiProgress/types.ts +5 -0
- package/src/components/UiRoomButton/UiRoomButton.vue +240 -0
- package/src/components/UiShell/UiShell.vue +88 -0
- package/src/components/UiSideMenu/UiSideMenu.vue +513 -0
- package/src/components/UiSideMenu/UiSideMenuBottom.vue +27 -0
- package/src/components/UiSideMenu/UiSideMenuItem.vue +102 -0
- package/src/components/UiSideMenu/UiSideMenuItemContent.vue +172 -0
- package/src/components/UiSideMenu/UiSideMenuTop.vue +29 -0
- package/src/components/UiSideMenu/injection.ts +9 -0
- package/src/components/UiSideMenu/types.ts +41 -0
- package/src/components/UiSideMenu/useLabelHidden.ts +33 -0
- package/src/components/UiSideMenu/useSideMenuLayout.ts +12 -0
- package/src/components/UiStepper/UiStepper.vue +40 -0
- package/src/components/UiStepper/UiStepperDescription.vue +27 -0
- package/src/components/UiStepper/UiStepperIndicator.vue +93 -0
- package/src/components/UiStepper/UiStepperItem.vue +30 -0
- package/src/components/UiStepper/UiStepperSeparator.vue +49 -0
- package/src/components/UiStepper/UiStepperTitle.vue +24 -0
- package/src/components/UiStepper/index.ts +17 -0
- package/src/components/UiTable/UiTable.vue +24 -0
- package/src/components/UiTable/UiTableBody.vue +5 -0
- package/src/components/UiTable/UiTableCell.vue +26 -0
- package/src/components/UiTable/UiTableHeader.vue +17 -0
- package/src/components/UiTable/UiTableHeaderCell.vue +19 -0
- package/src/components/UiTable/UiTableRow.vue +27 -0
- package/src/components/UiTable/index.ts +6 -0
- package/src/components/UiTabs/UiTabs.vue +218 -0
- package/src/components/UiTabs/index.ts +5 -0
- package/src/components/UiTag/UiTag.vue +187 -0
- package/src/components/UiTag/index.js +1 -0
- package/src/components/UiTextField/UiTextField.vue +370 -0
- package/src/components/UiTextField/index.ts +2 -0
- package/src/components/UiTextField/types.ts +2 -0
- package/src/components/UiTimeline/README.md +169 -0
- package/src/components/UiTimeline/UiTimeline.vue +58 -0
- package/src/components/UiTimeline/UiTimelineItem.vue +141 -0
- package/src/components/UiTimeline/index.ts +2 -0
- package/src/components/UiTooltip/UiTooltip.vue +16 -0
- package/src/components/UiTooltip/UiTooltipContent.vue +86 -0
- package/src/components/UiTooltip/UiTooltipProvider.vue +15 -0
- package/src/components/UiTooltip/UiTooltipTrigger.vue +19 -0
- package/src/components/UiTooltip/index.js +4 -0
- package/src/composables/useButtonStyles.ts +242 -0
- package/src/composables/useMobileMenu.ts +57 -0
- package/src/composables/useThemeAndModes.ts +225 -0
- package/src/constants/index.ts +2 -0
- package/src/constants/sizes.ts +2 -0
- package/src/constants/themes.ts +34 -0
- package/src/css/{body.postcss → body.css} +3 -2
- package/src/css/reka-animations.css +209 -0
- package/src/css/{transitions.postcss → transitions.css} +12 -5
- package/src/global.d.ts +181 -0
- package/src/integrations/index.js +1 -0
- package/src/layouts/index.js +5 -0
- package/src/mixins/DynamicAction.js +5 -3
- package/src/primitives.ts +6 -0
- package/src/theme.ts +1 -0
- package/src/utils/a11y.ts +8 -0
- package/src/utils/{breakpoints.js → breakpoints.ts} +1 -0
- package/src/utils/clipboard.js +2 -2
- package/src/utils/devices.js +0 -3
- package/src/utils/index.js +2 -1
- package/src/utils/numbers.ts +61 -0
- package/src/utils/responsive.types.ts +12 -0
- package/src/utils/{slot.js → slot.ts} +18 -1
- package/style.js +3 -12
- package/theme.d.ts +1 -0
- package/.env +0 -1
- package/.eslintignore +0 -4
- package/.eslintrc.js +0 -49
- package/.pkg +0 -11
- package/babel.config.js +0 -5
- package/build/Dockerfile +0 -31
- package/ci/ci.yml +0 -54
- package/components-webpack.js +0 -29
- package/dist/environment-da321c85.mjs +0 -1656
- package/dist/style.css +0 -1
- package/plugins.js +0 -17
- package/postcss.config.js +0 -1
- package/src/components/BaseAutocomplete/BaseAutocomplete.spec.js +0 -506
- package/src/components/BaseAutocomplete/BaseAutocomplete.stories.js +0 -184
- package/src/components/BaseAutocomplete/BaseAutocomplete.vue +0 -431
- package/src/components/BaseBanner/BaseBanner.spec.js +0 -32
- package/src/components/BaseBanner/BaseBanner.stories.js +0 -133
- package/src/components/BaseBanner/BaseBanner.vue +0 -229
- package/src/components/BaseButton/BaseButton.spec.js +0 -98
- package/src/components/BaseButton/BaseButton.stories.js +0 -300
- package/src/components/BaseButton/BaseButton.vue +0 -193
- package/src/components/BaseButton/__snapshots__/BaseButton.spec.js.snap +0 -37
- package/src/components/BaseButton/__snapshots__/BaseButton.spec.js.snap.old +0 -31
- package/src/components/BaseCheckbox/BaseCheckbox.stories.js +0 -157
- package/src/components/BaseCheckbox/BaseCheckbox.vue +0 -180
- package/src/components/BaseDropdownMenu/BaseDropdownMenu.stories.js +0 -84
- package/src/components/BaseDropdownMenu/BaseDropdownMenu.vue +0 -251
- package/src/components/BaseDropdownMenu/BaseDropdownMenuButton.vue +0 -26
- package/src/components/BaseDropdownMenu/BaseDropdownMenuDivider.vue +0 -10
- package/src/components/BaseDropdownMenu/BaseDropdownMenuItem.vue +0 -206
- package/src/components/BaseDropdownMenu/BaseDropdownMenuSearch.vue +0 -49
- package/src/components/BaseDropdownMenu/BaseDropdownMenuTitle.vue +0 -26
- package/src/components/BaseModal/BaseModal.stories.js +0 -155
- package/src/components/BaseModal/BaseModal.vue +0 -187
- package/src/components/BaseModal/BaseModalContent.vue +0 -166
- package/src/components/BaseModal/BaseModalContentOld.vue +0 -242
- package/src/components/BaseRadio/BaseRadio.stories.js +0 -164
- package/src/components/BaseRadio/BaseRadio.vue +0 -153
- package/src/components/BaseRating/BaseRating.spec.js +0 -46
- package/src/components/BaseRating/BaseRating.stories.js +0 -46
- package/src/components/BaseRating/BaseRating.vue +0 -119
- package/src/components/BaseSelect/BaseSelect.stories.js +0 -177
- package/src/components/BaseSelect/BaseSelect.vue +0 -443
- package/src/components/BaseSelect/BaseSelectGroup.vue +0 -34
- package/src/components/BaseSelect/BaseSelectOption.vue +0 -219
- package/src/components/BaseSwitch/BaseSwitch.stories.js +0 -44
- package/src/components/BaseSwitch/BaseSwitch.vue +0 -114
- package/src/components/BaseTag/BaseTag.stories.js +0 -123
- package/src/components/BaseTag/BaseTag.vue +0 -244
- package/src/css/button.postcss +0 -363
- package/src/css/checkbox-radio.postcss +0 -188
- package/src/css/icon.postcss +0 -9
- package/src/css/loader.postcss +0 -120
- package/src/css/popper.postcss +0 -161
- package/src/css/tailwind-utilities.postcss +0 -1
- package/src/css/tailwind.postcss +0 -2
- package/style-postcss.d.ts +0 -3
- package/style-postcss.js +0 -2
- package/tailwind.config.base.cjs +0 -88
- package/tailwind.config.js +0 -9
- package/tsconfig.check.json +0 -13
- package/tsconfig.json +0 -66
- package/vite.config.js +0 -43
- package/vitest.setup.js +0 -26
|
@@ -1,229 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div
|
|
3
|
-
v-if="!isClosed"
|
|
4
|
-
class="base-banner flex justify-between text-grey-700 text-14-regular px-6 py-4"
|
|
5
|
-
:class="[
|
|
6
|
-
{
|
|
7
|
-
'rounded-8': borderRounded && !bannerMode,
|
|
8
|
-
'items-center': !isDisplayBlock,
|
|
9
|
-
'fixed z-[10000] w-full left-0': bannerMode,
|
|
10
|
-
'bottom-0 md:bottom-auto md:top-0': bannerMode && bannerBottomOnSmallScreen,
|
|
11
|
-
'top-0': bannerMode && !bannerBottomOnSmallScreen,
|
|
12
|
-
},
|
|
13
|
-
`type-${type}`,
|
|
14
|
-
bgColor,
|
|
15
|
-
]"
|
|
16
|
-
data-testid="base-banner"
|
|
17
|
-
:data-type="type"
|
|
18
|
-
>
|
|
19
|
-
<div
|
|
20
|
-
class="flex w-full"
|
|
21
|
-
:class="isDisplayBlock ? 'flex-col items-center' : 'justify-between items-center'"
|
|
22
|
-
>
|
|
23
|
-
<div
|
|
24
|
-
class="flex items-center"
|
|
25
|
-
:class="{
|
|
26
|
-
'flex-col': isDisplayBlock
|
|
27
|
-
}"
|
|
28
|
-
>
|
|
29
|
-
<div
|
|
30
|
-
class="shrink-0 w-6 h-6 flex justify-center items-center"
|
|
31
|
-
:class="icon"
|
|
32
|
-
/>
|
|
33
|
-
<div
|
|
34
|
-
:class="{
|
|
35
|
-
'text-center mt-4': isDisplayBlock,
|
|
36
|
-
'mr-3': !isDisplayBlock && (buttonLabel || buttonsSlot),
|
|
37
|
-
'ml-3': !isDisplayBlock,
|
|
38
|
-
}"
|
|
39
|
-
>
|
|
40
|
-
<div
|
|
41
|
-
v-if="defaultSlot"
|
|
42
|
-
:class="{ 'text-14-semibold': descriptionSlot }"
|
|
43
|
-
>
|
|
44
|
-
<RenderSlot :vnodes="defaultSlot" />
|
|
45
|
-
</div>
|
|
46
|
-
<RenderSlot :vnodes="descriptionSlot" />
|
|
47
|
-
</div>
|
|
48
|
-
</div>
|
|
49
|
-
<div
|
|
50
|
-
v-if="buttonsSlot"
|
|
51
|
-
:class="{ 'mt-4': isDisplayBlock }"
|
|
52
|
-
>
|
|
53
|
-
<RenderSlot :vnodes="buttonsSlot" />
|
|
54
|
-
</div>
|
|
55
|
-
<template v-if="!buttonsSlot">
|
|
56
|
-
<BaseButton
|
|
57
|
-
v-if="buttonLabel"
|
|
58
|
-
type="button"
|
|
59
|
-
:class="[
|
|
60
|
-
{ 'mt-4': isDisplayBlock },
|
|
61
|
-
buttonClass,
|
|
62
|
-
]"
|
|
63
|
-
:icon="buttonIcon"
|
|
64
|
-
:href="buttonHref"
|
|
65
|
-
:disabled="disabledButton"
|
|
66
|
-
:target="buttonHref ? '_blank' : null"
|
|
67
|
-
data-testid="warning-message-button"
|
|
68
|
-
@click="$emit('handleClick')"
|
|
69
|
-
>
|
|
70
|
-
{{ buttonLabel }}
|
|
71
|
-
</BaseButton>
|
|
72
|
-
</template>
|
|
73
|
-
</div>
|
|
74
|
-
<div
|
|
75
|
-
v-if="closable"
|
|
76
|
-
class="i-ls-x shrink-0 w-5 h-5 text-grey-600 cursor-pointer hover:text-livestorm-800"
|
|
77
|
-
:class="{ 'ml-2': !isDisplayBlock }"
|
|
78
|
-
@click="close"
|
|
79
|
-
/>
|
|
80
|
-
</div>
|
|
81
|
-
</template>
|
|
82
|
-
|
|
83
|
-
<script>
|
|
84
|
-
import { computed } from 'vue'
|
|
85
|
-
import { useSlotsAsComponents } from '../../utils/slot'
|
|
86
|
-
import BaseButton from '../BaseButton/BaseButton.vue'
|
|
87
|
-
|
|
88
|
-
export default {
|
|
89
|
-
components: {
|
|
90
|
-
BaseButton,
|
|
91
|
-
},
|
|
92
|
-
|
|
93
|
-
props: {
|
|
94
|
-
type: {
|
|
95
|
-
type: String,
|
|
96
|
-
default: 'alert',
|
|
97
|
-
validator (value) {
|
|
98
|
-
return ['info', 'success', 'warning', 'alert'].includes(value)
|
|
99
|
-
},
|
|
100
|
-
},
|
|
101
|
-
display: {
|
|
102
|
-
type: String,
|
|
103
|
-
default: 'inline',
|
|
104
|
-
validator (value) {
|
|
105
|
-
return ['inline', 'block'].includes(value)
|
|
106
|
-
},
|
|
107
|
-
},
|
|
108
|
-
buttonLabel: {
|
|
109
|
-
type: String,
|
|
110
|
-
default: '',
|
|
111
|
-
},
|
|
112
|
-
buttonHref: {
|
|
113
|
-
type: String,
|
|
114
|
-
default: null,
|
|
115
|
-
},
|
|
116
|
-
buttonIcon: {
|
|
117
|
-
type: String,
|
|
118
|
-
default: null,
|
|
119
|
-
},
|
|
120
|
-
closable: {
|
|
121
|
-
type: Boolean,
|
|
122
|
-
default: false,
|
|
123
|
-
},
|
|
124
|
-
bannerMode: {
|
|
125
|
-
type: Boolean,
|
|
126
|
-
default: false,
|
|
127
|
-
},
|
|
128
|
-
borderRounded: {
|
|
129
|
-
type: Boolean,
|
|
130
|
-
default: true,
|
|
131
|
-
},
|
|
132
|
-
bannerBottomOnSmallScreen: {
|
|
133
|
-
type: Boolean,
|
|
134
|
-
default: true,
|
|
135
|
-
},
|
|
136
|
-
forceInlineDisplayOnSmallScreen: {
|
|
137
|
-
type: Boolean,
|
|
138
|
-
default: true,
|
|
139
|
-
},
|
|
140
|
-
disabledButton: {
|
|
141
|
-
type: Boolean,
|
|
142
|
-
default: false,
|
|
143
|
-
},
|
|
144
|
-
},
|
|
145
|
-
|
|
146
|
-
emits: ['handleClick', 'close'],
|
|
147
|
-
|
|
148
|
-
setup () {
|
|
149
|
-
const slots = useSlotsAsComponents()
|
|
150
|
-
const defaultSlot = computed(() => slots.default())
|
|
151
|
-
const descriptionSlot = computed(() => slots.description())
|
|
152
|
-
const buttonsSlot = computed(() => slots.buttons())
|
|
153
|
-
|
|
154
|
-
return {
|
|
155
|
-
descriptionSlot,
|
|
156
|
-
buttonsSlot,
|
|
157
|
-
defaultSlot,
|
|
158
|
-
}
|
|
159
|
-
},
|
|
160
|
-
|
|
161
|
-
data () {
|
|
162
|
-
return {
|
|
163
|
-
isClosed: false,
|
|
164
|
-
}
|
|
165
|
-
},
|
|
166
|
-
|
|
167
|
-
computed: {
|
|
168
|
-
icon () {
|
|
169
|
-
switch (this.type) {
|
|
170
|
-
case 'alert':
|
|
171
|
-
return 'i-ls-alert-circle text-red-600'
|
|
172
|
-
case 'warning':
|
|
173
|
-
return 'i-ls-alert-triangle text-orange-600'
|
|
174
|
-
case 'info':
|
|
175
|
-
return 'i-ls-info text-livestorm-600'
|
|
176
|
-
case 'success':
|
|
177
|
-
return 'i-ls-check-circle text-green-600'
|
|
178
|
-
default:
|
|
179
|
-
return 'i-ls-alert-circle text-livestorm-600'
|
|
180
|
-
}
|
|
181
|
-
},
|
|
182
|
-
|
|
183
|
-
bgColor () {
|
|
184
|
-
switch (this.type) {
|
|
185
|
-
case 'alert':
|
|
186
|
-
return 'bg-red-100'
|
|
187
|
-
case 'warning':
|
|
188
|
-
return 'bg-orange-100'
|
|
189
|
-
case 'success':
|
|
190
|
-
return 'bg-green-100'
|
|
191
|
-
case 'info':
|
|
192
|
-
default:
|
|
193
|
-
return 'bg-livestorm-100'
|
|
194
|
-
}
|
|
195
|
-
},
|
|
196
|
-
|
|
197
|
-
buttonClass () {
|
|
198
|
-
switch (this.type) {
|
|
199
|
-
case 'alert':
|
|
200
|
-
return 'base-button-red-secondary'
|
|
201
|
-
case 'warning':
|
|
202
|
-
return 'base-button-orange-secondary'
|
|
203
|
-
case 'success':
|
|
204
|
-
return 'base-button-green-secondary'
|
|
205
|
-
case 'info':
|
|
206
|
-
default:
|
|
207
|
-
return 'base-button-secondary'
|
|
208
|
-
}
|
|
209
|
-
},
|
|
210
|
-
|
|
211
|
-
isDisplayBlock () {
|
|
212
|
-
return this.display === 'block' || (this.display === 'inline' && this.$responsive.mobile && this.forceInlineDisplayOnSmallScreen)
|
|
213
|
-
},
|
|
214
|
-
},
|
|
215
|
-
|
|
216
|
-
methods: {
|
|
217
|
-
close () {
|
|
218
|
-
this.isClosed = true
|
|
219
|
-
this.$emit('close')
|
|
220
|
-
},
|
|
221
|
-
},
|
|
222
|
-
}
|
|
223
|
-
</script>
|
|
224
|
-
|
|
225
|
-
<style lang="postcss" scoped>
|
|
226
|
-
.base-banner :deep(a:not(.base-button)) {
|
|
227
|
-
@apply text-grey-700 hover:text-grey-900 underline;
|
|
228
|
-
}
|
|
229
|
-
</style>
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
import { mount } from '@vue/test-utils'
|
|
2
|
-
import BaseButton from './BaseButton.vue'
|
|
3
|
-
|
|
4
|
-
describe('BaseButton', () => {
|
|
5
|
-
test('snapshot: button', () => {
|
|
6
|
-
const wrapper = mount(BaseButton, {
|
|
7
|
-
props: {
|
|
8
|
-
type: 'submit',
|
|
9
|
-
},
|
|
10
|
-
slots: {
|
|
11
|
-
default: '<span>Hello</span>',
|
|
12
|
-
},
|
|
13
|
-
})
|
|
14
|
-
expect(wrapper.html()).toMatchSnapshot()
|
|
15
|
-
})
|
|
16
|
-
|
|
17
|
-
test('snapshot: router-link', () => {
|
|
18
|
-
const wrapper = mount(BaseButton, {
|
|
19
|
-
props: {
|
|
20
|
-
to: { name: 'foo' },
|
|
21
|
-
},
|
|
22
|
-
slots: {
|
|
23
|
-
default: '<span>My Page</span>',
|
|
24
|
-
},
|
|
25
|
-
})
|
|
26
|
-
expect(wrapper.html()).toMatchSnapshot()
|
|
27
|
-
})
|
|
28
|
-
|
|
29
|
-
test('snapshot: a', () => {
|
|
30
|
-
const wrapper = mount(BaseButton, {
|
|
31
|
-
props: {
|
|
32
|
-
href: 'https://google.com/',
|
|
33
|
-
},
|
|
34
|
-
slots: {
|
|
35
|
-
default: '<span>Google</span>',
|
|
36
|
-
},
|
|
37
|
-
})
|
|
38
|
-
expect(wrapper.html()).toMatchSnapshot()
|
|
39
|
-
})
|
|
40
|
-
|
|
41
|
-
test('event: click', async () => {
|
|
42
|
-
const wrapper = mount(BaseButton)
|
|
43
|
-
await wrapper.trigger('click')
|
|
44
|
-
expect(wrapper.emitted().click).toBeTruthy()
|
|
45
|
-
})
|
|
46
|
-
|
|
47
|
-
test('icon left', () => {
|
|
48
|
-
const wrapper = mount(BaseButton, {
|
|
49
|
-
props: {
|
|
50
|
-
icon: 'foo',
|
|
51
|
-
},
|
|
52
|
-
slots: {
|
|
53
|
-
default: '<span>My Page</span>',
|
|
54
|
-
},
|
|
55
|
-
})
|
|
56
|
-
const selector = '.left-icon'
|
|
57
|
-
expect(wrapper.get(selector))
|
|
58
|
-
const icon = wrapper.find(selector)
|
|
59
|
-
expect(icon.classes()).toContain('foo')
|
|
60
|
-
})
|
|
61
|
-
|
|
62
|
-
test('icon right', () => {
|
|
63
|
-
const wrapper = mount(BaseButton, {
|
|
64
|
-
props: {
|
|
65
|
-
iconRight: 'foo',
|
|
66
|
-
},
|
|
67
|
-
slots: {
|
|
68
|
-
default: '<span>My Page</span>',
|
|
69
|
-
},
|
|
70
|
-
})
|
|
71
|
-
const selector = '.right-icon'
|
|
72
|
-
expect(wrapper.get(selector))
|
|
73
|
-
const icon = wrapper.find(selector)
|
|
74
|
-
expect(icon.classes()).toContain('foo')
|
|
75
|
-
})
|
|
76
|
-
|
|
77
|
-
test('loading state', () => {
|
|
78
|
-
const wrapper = mount(BaseButton, {
|
|
79
|
-
props: {
|
|
80
|
-
loading: true,
|
|
81
|
-
},
|
|
82
|
-
slots: {
|
|
83
|
-
default: '<span class="foo">Send message</span>',
|
|
84
|
-
},
|
|
85
|
-
})
|
|
86
|
-
expect(wrapper.get('.loader'))
|
|
87
|
-
expect(wrapper.get('.foo'))
|
|
88
|
-
})
|
|
89
|
-
|
|
90
|
-
test('disabled', () => {
|
|
91
|
-
const wrapper = mount(BaseButton, {
|
|
92
|
-
props: {
|
|
93
|
-
disabled: true,
|
|
94
|
-
},
|
|
95
|
-
})
|
|
96
|
-
expect(wrapper.attributes().disabled).toBe('')
|
|
97
|
-
})
|
|
98
|
-
})
|
|
@@ -1,300 +0,0 @@
|
|
|
1
|
-
import BaseButton from './BaseButton.vue'
|
|
2
|
-
import { icons } from '@/../../frontend/.storybook/icons'
|
|
3
|
-
import { action } from '@storybook/addon-actions'
|
|
4
|
-
import { withDesign } from 'storybook-addon-designs'
|
|
5
|
-
|
|
6
|
-
const actions = {
|
|
7
|
-
onClick: action('clicked'),
|
|
8
|
-
onClose: action('closed'),
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export default {
|
|
12
|
-
title: 'common/vue/components/BaseButton',
|
|
13
|
-
component: BaseButton,
|
|
14
|
-
argTypes: {
|
|
15
|
-
icon: {
|
|
16
|
-
control: {
|
|
17
|
-
type: 'select',
|
|
18
|
-
},
|
|
19
|
-
options: icons,
|
|
20
|
-
},
|
|
21
|
-
class: {
|
|
22
|
-
control: {
|
|
23
|
-
type: 'select',
|
|
24
|
-
},
|
|
25
|
-
options: [
|
|
26
|
-
'base-button-extra-small',
|
|
27
|
-
'base-button-small',
|
|
28
|
-
'base-button-medium',
|
|
29
|
-
'base-button-large',
|
|
30
|
-
'base-button-extra-large',
|
|
31
|
-
],
|
|
32
|
-
},
|
|
33
|
-
},
|
|
34
|
-
args: {
|
|
35
|
-
class: 'base-button-medium',
|
|
36
|
-
},
|
|
37
|
-
decorators: [withDesign],
|
|
38
|
-
parameters: {
|
|
39
|
-
design: {
|
|
40
|
-
type: 'figma',
|
|
41
|
-
url: 'https://www.figma.com/file/JY03TRyhauKw0jjoHFFtmMHV/0.-Design-system---Fondation?node-id=7760%3A2',
|
|
42
|
-
},
|
|
43
|
-
},
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
/** Colors */
|
|
47
|
-
|
|
48
|
-
const PrimaryTemplate = (args) => ({
|
|
49
|
-
setup: () => ({ args, ...actions }),
|
|
50
|
-
template: '<BaseButton v-bind="args" class="base-button-primary" @click="onClick">Primary</BaseButton>',
|
|
51
|
-
})
|
|
52
|
-
|
|
53
|
-
const SecondaryTemplate = (args) => ({
|
|
54
|
-
setup: () => ({ args, ...actions }),
|
|
55
|
-
template: '<BaseButton v-bind="args" class="base-button-secondary" @click="onClick">Secondary</BaseButton>',
|
|
56
|
-
})
|
|
57
|
-
|
|
58
|
-
const RedPrimaryTemplate = (args) => {
|
|
59
|
-
return {
|
|
60
|
-
setup: () => ({ args, ...actions }),
|
|
61
|
-
methods: actions,
|
|
62
|
-
template: '<BaseButton v-bind="args" class="base-button-red-primary" @click="onClick">Red Primary</BaseButton>',
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
const RedSecondaryTemplate = (args) => {
|
|
67
|
-
return {
|
|
68
|
-
setup: () => ({ args, ...actions }),
|
|
69
|
-
methods: actions,
|
|
70
|
-
template: '<BaseButton v-bind="args" class="base-button-red-secondary" @click="onClick">Red Secondary</BaseButton>',
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
const GreenPrimaryTemplate = (args) => {
|
|
75
|
-
return {
|
|
76
|
-
setup: () => ({ args, ...actions }),
|
|
77
|
-
methods: actions,
|
|
78
|
-
template: '<BaseButton v-bind="args" class="base-button-green-primary" @click="onClick">Green Primary</BaseButton>',
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
const GreenSecondaryTemplate = (args) => {
|
|
83
|
-
return {
|
|
84
|
-
setup: () => ({ args, ...actions }),
|
|
85
|
-
methods: actions,
|
|
86
|
-
template: '<BaseButton v-bind="args" class="base-button-green-secondary" @click="onClick">Green Secondary</BaseButton>',
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
const OrangePrimaryTemplate = (args) => {
|
|
91
|
-
return {
|
|
92
|
-
setup: () => ({ args, ...actions }),
|
|
93
|
-
methods: actions,
|
|
94
|
-
template: '<BaseButton v-bind="args" class="base-button-orange-primary" @click="onClick">Orange Primary</BaseButton>',
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
const OrangeSecondaryTemplate = (args) => {
|
|
99
|
-
return {
|
|
100
|
-
setup: () => ({ args, ...actions }),
|
|
101
|
-
methods: actions,
|
|
102
|
-
template: '<BaseButton v-bind="args" class="base-button-orange-secondary" @click="onClick">Orange Secondary</BaseButton>',
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
const AntiPrimaryTemplate = (args) => {
|
|
107
|
-
return {
|
|
108
|
-
setup: () => ({ args, ...actions }),
|
|
109
|
-
methods: actions,
|
|
110
|
-
template: '<BaseButton v-bind="args" class="base-button-anti-primary" @click="onClick">Anti Primary</BaseButton>',
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
const TertiaryTemplate = (args) => {
|
|
115
|
-
return {
|
|
116
|
-
setup: () => ({ args, ...actions }),
|
|
117
|
-
methods: actions,
|
|
118
|
-
template: '<BaseButton v-bind="args" class="base-button-tertiary" @click="onClick">Tertiary</BaseButton>',
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
const QuaternaryTemplate = (args) => {
|
|
123
|
-
return {
|
|
124
|
-
setup: () => ({ args, ...actions }),
|
|
125
|
-
methods: actions,
|
|
126
|
-
template: '<BaseButton v-bind="args" class="base-button-quaternary" @click="onClick">Quaternary</BaseButton>',
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
const QuaternaryBgTemplate = (args) => {
|
|
131
|
-
return {
|
|
132
|
-
setup: () => ({ args, ...actions }),
|
|
133
|
-
methods: actions,
|
|
134
|
-
template: '<BaseButton v-bind="args" class="base-button-quaternary-bg" @click="onClick"></BaseButton>',
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
const AlphaWhiteTemplate = (args) => {
|
|
139
|
-
return {
|
|
140
|
-
setup: () => ({ args, ...actions }),
|
|
141
|
-
methods: actions,
|
|
142
|
-
template: '<BaseButton v-bind="args" class="base-button-alpha-white" @click="onClick">Alpha White</BaseButton>',
|
|
143
|
-
}
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
const AlphaBlackTemplate = (args) => {
|
|
147
|
-
return {
|
|
148
|
-
setup: () => ({ args, ...actions }),
|
|
149
|
-
methods: actions,
|
|
150
|
-
template: '<BaseButton v-bind="args" class="base-button-alpha-black" @click="onClick">Alpha Black</BaseButton>',
|
|
151
|
-
}
|
|
152
|
-
}
|
|
153
|
-
|
|
154
|
-
const AlphaWhiteBgTemplate = (args) => {
|
|
155
|
-
return {
|
|
156
|
-
setup: () => ({ args, ...actions }),
|
|
157
|
-
methods: actions,
|
|
158
|
-
template: '<BaseButton v-bind="args" class="base-button-alpha-white-bg" @click="onClick">Alpha White Bg</BaseButton>',
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
/** Size */
|
|
163
|
-
|
|
164
|
-
const ExtraSmallTemplate = (args) => ({
|
|
165
|
-
setup: () => ({ args, ...actions }),
|
|
166
|
-
template: '<BaseButton v-bind="args" class="base-button-primary" @click="onClick">Extra small</BaseButton>',
|
|
167
|
-
})
|
|
168
|
-
|
|
169
|
-
const SmallTemplate = (args) => ({
|
|
170
|
-
setup: () => ({ args, ...actions }),
|
|
171
|
-
template: '<BaseButton v-bind="args" class="base-button-primary" @click="onClick">Small</BaseButton>',
|
|
172
|
-
})
|
|
173
|
-
|
|
174
|
-
const MediumTemplate = (args) => ({
|
|
175
|
-
setup: () => ({ args, ...actions }),
|
|
176
|
-
template: '<BaseButton v-bind="args" class="base-button-primary" @click="onClick">Medium</BaseButton>',
|
|
177
|
-
})
|
|
178
|
-
|
|
179
|
-
const LargeTemplate = (args) => ({
|
|
180
|
-
setup: () => ({ args, ...actions }),
|
|
181
|
-
template: '<BaseButton v-bind="args" class="base-button-primary" @click="onClick">Large</BaseButton>',
|
|
182
|
-
})
|
|
183
|
-
|
|
184
|
-
const ExtraLargeTemplate = (args) => ({
|
|
185
|
-
setup: () => ({ args, ...actions }),
|
|
186
|
-
template: '<BaseButton v-bind="args" class="base-button-primary" @click="onClick">Extra large</BaseButton>',
|
|
187
|
-
})
|
|
188
|
-
|
|
189
|
-
/** Layout */
|
|
190
|
-
|
|
191
|
-
const IconOnlyTemplate = (args) => ({
|
|
192
|
-
setup: () => ({ args, ...actions }),
|
|
193
|
-
template: '<BaseButton v-bind="args" class="base-button-primary base-button-square" @click="onClick"/>',
|
|
194
|
-
})
|
|
195
|
-
|
|
196
|
-
const AlignCenterTemplate = (args) => ({
|
|
197
|
-
setup: () => ({ args, ...actions }),
|
|
198
|
-
template: '<BaseButton v-bind="args" class="base-button-primary" @click="onClick" style="width: 200px">Align content</BaseButton>',
|
|
199
|
-
})
|
|
200
|
-
|
|
201
|
-
const ClosableTemplate = (args) => ({
|
|
202
|
-
setup: () => ({ args, ...actions }),
|
|
203
|
-
template: '<BaseButton v-bind="args" class="base-button-primary" @click="onClick" @close="onClose">Closable</BaseButton>',
|
|
204
|
-
})
|
|
205
|
-
|
|
206
|
-
const FullWidthTemplate = (args) => ({
|
|
207
|
-
setup: () => ({ args, ...actions }),
|
|
208
|
-
template: '<BaseButton v-bind="args" class="base-button-primary w-full" @click="onClick">Full Width</BaseButton>',
|
|
209
|
-
})
|
|
210
|
-
|
|
211
|
-
const ClosableFullWidthTemplate = (args) => ({
|
|
212
|
-
setup: () => ({ args, ...actions }),
|
|
213
|
-
template: '<BaseButton v-bind="args" class="base-button-primary w-full" @click="onClick" @close="onClose">Closable</BaseButton>',
|
|
214
|
-
})
|
|
215
|
-
|
|
216
|
-
/** Colors */
|
|
217
|
-
export const Primary = PrimaryTemplate.bind({})
|
|
218
|
-
export const Secondary = SecondaryTemplate.bind({})
|
|
219
|
-
export const RedPrimary = RedPrimaryTemplate.bind({})
|
|
220
|
-
export const RedSecondary = RedSecondaryTemplate.bind({})
|
|
221
|
-
export const GreenPrimary = GreenPrimaryTemplate.bind({})
|
|
222
|
-
export const GreenSecondary = GreenSecondaryTemplate.bind({})
|
|
223
|
-
export const OrangePrimary = OrangePrimaryTemplate.bind({})
|
|
224
|
-
export const OrangeSecondary = OrangeSecondaryTemplate.bind({})
|
|
225
|
-
export const AntiPrimary = AntiPrimaryTemplate.bind({})
|
|
226
|
-
export const Tertiary = TertiaryTemplate.bind({})
|
|
227
|
-
export const Quaternary = QuaternaryTemplate.bind({})
|
|
228
|
-
export const QuaternaryBg = QuaternaryBgTemplate.bind({})
|
|
229
|
-
export const AlphaWhite = AlphaWhiteTemplate.bind({})
|
|
230
|
-
export const AlphaWhiteBg = AlphaWhiteBgTemplate.bind({})
|
|
231
|
-
export const AlphaDark = AlphaBlackTemplate.bind({})
|
|
232
|
-
|
|
233
|
-
/** Size */
|
|
234
|
-
export const ExtraSmall = ExtraSmallTemplate.bind({})
|
|
235
|
-
export const Small = SmallTemplate.bind({})
|
|
236
|
-
export const Medium = MediumTemplate.bind({})
|
|
237
|
-
export const Large = LargeTemplate.bind({})
|
|
238
|
-
export const ExtraLarge = ExtraLargeTemplate.bind({})
|
|
239
|
-
|
|
240
|
-
/** Layout */
|
|
241
|
-
export const IconOnly = IconOnlyTemplate.bind({})
|
|
242
|
-
export const AlignCenter = AlignCenterTemplate.bind({})
|
|
243
|
-
export const Closable = ClosableTemplate.bind({})
|
|
244
|
-
export const FullWidth = FullWidthTemplate.bind({})
|
|
245
|
-
export const ClosableFullWidth = ClosableFullWidthTemplate.bind({})
|
|
246
|
-
|
|
247
|
-
QuaternaryBg.args = {
|
|
248
|
-
icon: 'i-ls-chevron-left',
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
AlphaWhite.args = {
|
|
252
|
-
icon: 'i-ls-download-cloud',
|
|
253
|
-
}
|
|
254
|
-
|
|
255
|
-
AlphaWhite.parameters = {
|
|
256
|
-
backgrounds: {
|
|
257
|
-
default: 'grey-dark',
|
|
258
|
-
},
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
AlphaWhiteBg.parameters = {
|
|
262
|
-
backgrounds: { default: 'grey-dark' },
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
ExtraSmall.args = {
|
|
266
|
-
class: 'base-button-extra-small',
|
|
267
|
-
}
|
|
268
|
-
|
|
269
|
-
Small.args = {
|
|
270
|
-
class: 'base-button-small',
|
|
271
|
-
}
|
|
272
|
-
|
|
273
|
-
Medium.args = {
|
|
274
|
-
class: 'base-button-medium',
|
|
275
|
-
}
|
|
276
|
-
|
|
277
|
-
Large.args = {
|
|
278
|
-
class: 'base-button-large',
|
|
279
|
-
}
|
|
280
|
-
|
|
281
|
-
ExtraLarge.args = {
|
|
282
|
-
class: 'base-button-extra-large',
|
|
283
|
-
}
|
|
284
|
-
|
|
285
|
-
IconOnly.args = {
|
|
286
|
-
icon: 'i-ls-mail',
|
|
287
|
-
}
|
|
288
|
-
|
|
289
|
-
AlignCenter.args = {
|
|
290
|
-
icon: 'i-ls-zap',
|
|
291
|
-
alignCenter: true,
|
|
292
|
-
}
|
|
293
|
-
|
|
294
|
-
Closable.args = {
|
|
295
|
-
closable: true,
|
|
296
|
-
}
|
|
297
|
-
|
|
298
|
-
ClosableFullWidth.args = {
|
|
299
|
-
closable: true,
|
|
300
|
-
}
|