@quen-ui/components 0.0.14 → 1.0.1
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 +2 -2
- package/dist/Accordion/Accordion.cjs.js +88 -0
- package/dist/Accordion/Accordion.d.ts +3 -0
- package/dist/Accordion/Accordion.es.js +89 -0
- package/dist/Accordion/AccordionGroup.cjs.js +82 -0
- package/dist/Accordion/AccordionGroup.d.ts +12 -0
- package/dist/Accordion/AccordionGroup.es.js +82 -0
- package/dist/Accordion/AccordionItem.cjs.js +71 -0
- package/dist/Accordion/AccordionItem.d.ts +3 -0
- package/dist/Accordion/AccordionItem.es.js +72 -0
- package/dist/Accordion/helpers.cjs.js +24 -0
- package/dist/Accordion/helpers.d.ts +25 -0
- package/dist/Accordion/helpers.es.js +24 -0
- package/dist/Accordion/index.cjs.js +7 -0
- package/dist/Accordion/index.d.ts +8 -0
- package/dist/Accordion/index.es.js +7 -0
- package/dist/Accordion/styles.cjs.js +97 -0
- package/dist/Accordion/styles.d.ts +23 -0
- package/dist/Accordion/styles.es.js +97 -0
- package/dist/Accordion/types.d.ts +142 -0
- package/dist/Accordion/useAccordionState.cjs.js +34 -0
- package/dist/Accordion/useAccordionState.d.ts +12 -0
- package/dist/Accordion/useAccordionState.es.js +34 -0
- package/dist/Alert/Alert.cjs.js +1 -1
- package/dist/Alert/Alert.es.js +1 -1
- package/dist/Alert/styles.cjs.js +14 -10
- package/dist/Alert/styles.es.js +14 -10
- package/dist/Avatar/styles.cjs.js +16 -11
- package/dist/Avatar/styles.es.js +16 -11
- package/dist/Badge/styles.cjs.js +7 -7
- package/dist/Badge/styles.es.js +7 -7
- package/dist/Breadcrumbs/BreadcrumbItem.cjs.js +6 -6
- package/dist/Breadcrumbs/BreadcrumbItem.es.js +6 -6
- package/dist/Breadcrumbs/Breadcrumbs.cjs.js +2 -3
- package/dist/Breadcrumbs/Breadcrumbs.es.js +2 -3
- package/dist/Breadcrumbs/styles.cjs.js +15 -15
- package/dist/Breadcrumbs/styles.es.js +15 -15
- package/dist/Button/Button.cjs.js +3 -3
- package/dist/Button/Button.es.js +6 -6
- package/dist/Button/index.d.ts +1 -1
- package/dist/Button/styles.cjs.js +49 -54
- package/dist/Button/styles.es.js +50 -55
- package/dist/Button/types.d.ts +2 -3
- package/dist/Calendar/Calendar.cjs.js +200 -0
- package/dist/Calendar/Calendar.d.ts +4 -0
- package/dist/Calendar/Calendar.es.js +201 -0
- package/dist/Calendar/DaysLevel.cjs.js +93 -0
- package/dist/Calendar/DaysLevel.d.ts +3 -0
- package/dist/Calendar/DaysLevel.es.js +94 -0
- package/dist/Calendar/MonthLevel.cjs.js +23 -0
- package/dist/Calendar/MonthLevel.d.ts +3 -0
- package/dist/Calendar/MonthLevel.es.js +24 -0
- package/dist/Calendar/YearsLevel.cjs.js +24 -0
- package/dist/Calendar/YearsLevel.d.ts +3 -0
- package/dist/Calendar/YearsLevel.es.js +25 -0
- package/dist/Calendar/helpers.cjs.js +60 -0
- package/dist/Calendar/helpers.d.ts +9 -0
- package/dist/Calendar/helpers.es.js +60 -0
- package/dist/Calendar/index.d.ts +2 -0
- package/dist/Calendar/styles.cjs.js +116 -0
- package/dist/Calendar/styles.d.ts +16 -0
- package/dist/Calendar/styles.es.js +116 -0
- package/dist/Calendar/types.d.ts +115 -0
- package/dist/Card/Card.cjs.js +4 -2
- package/dist/Card/Card.d.ts +1 -1
- package/dist/Card/Card.es.js +4 -2
- package/dist/Card/styles.cjs.js +2 -2
- package/dist/Card/styles.es.js +2 -2
- package/dist/Card/types.d.ts +2 -0
- package/dist/Checkbox/Checkbox.cjs.js +1 -1
- package/dist/Checkbox/Checkbox.es.js +1 -1
- package/dist/Checkbox/CheckboxGroup.cjs.js +22 -25
- package/dist/Checkbox/CheckboxGroup.es.js +22 -25
- package/dist/Checkbox/styles.cjs.js +24 -23
- package/dist/Checkbox/styles.es.js +24 -23
- package/dist/ColorPicker/ColorPicker.cjs.js +404 -0
- package/dist/ColorPicker/ColorPicker.d.ts +3 -0
- package/dist/ColorPicker/ColorPicker.es.js +405 -0
- package/dist/ColorPicker/InputColor.cjs.js +94 -0
- package/dist/ColorPicker/InputColor.d.ts +3 -0
- package/dist/ColorPicker/InputColor.es.js +95 -0
- package/dist/ColorPicker/InputsColor.cjs.js +177 -0
- package/dist/ColorPicker/InputsColor.d.ts +3 -0
- package/dist/ColorPicker/InputsColor.es.js +178 -0
- package/dist/ColorPicker/helpers.cjs.js +32 -0
- package/dist/ColorPicker/helpers.d.ts +4 -0
- package/dist/ColorPicker/helpers.es.js +32 -0
- package/dist/ColorPicker/index.cjs.js +7 -0
- package/dist/ColorPicker/index.d.ts +8 -0
- package/dist/ColorPicker/index.es.js +7 -0
- package/dist/ColorPicker/styles.cjs.js +234 -0
- package/dist/ColorPicker/styles.d.ts +43 -0
- package/dist/ColorPicker/styles.es.js +234 -0
- package/dist/ColorPicker/types.d.ts +56 -0
- package/dist/Divider/styles.cjs.js +12 -10
- package/dist/Divider/styles.es.js +12 -10
- package/dist/Drawer/Drawer.cjs.js +5 -1
- package/dist/Drawer/Drawer.es.js +5 -1
- package/dist/Drawer/styles.cjs.js +4 -5
- package/dist/Drawer/styles.es.js +4 -5
- package/dist/Dropdown/Dropdown.cjs.js +31 -2
- package/dist/Dropdown/Dropdown.d.ts +2 -2
- package/dist/Dropdown/Dropdown.es.js +32 -3
- package/dist/Dropdown/DropdownItem.cjs.js +4 -5
- package/dist/Dropdown/DropdownItem.es.js +4 -5
- package/dist/Dropdown/DropdownList.cjs.js +3 -2
- package/dist/Dropdown/DropdownList.es.js +6 -5
- package/dist/Dropdown/DropdownPortal.cjs.js +8 -5
- package/dist/Dropdown/DropdownPortal.d.ts +5 -3
- package/dist/Dropdown/DropdownPortal.es.js +9 -6
- package/dist/Dropdown/helpers.cjs.js +1 -1
- package/dist/Dropdown/helpers.es.js +1 -1
- package/dist/Dropdown/styles.cjs.js +28 -27
- package/dist/Dropdown/styles.d.ts +2 -0
- package/dist/Dropdown/styles.es.js +28 -27
- package/dist/EmptyState/EmptyState.cjs.js +51 -0
- package/dist/EmptyState/EmptyState.d.ts +3 -0
- package/dist/EmptyState/EmptyState.es.js +52 -0
- package/dist/EmptyState/index.d.ts +2 -0
- package/dist/EmptyState/types.d.ts +10 -0
- package/dist/Flex/Flex.d.ts +1 -1
- package/dist/Flex/types.d.ts +1 -0
- package/dist/Form/Field.cjs.js +175 -0
- package/dist/Form/Field.d.ts +3 -0
- package/dist/Form/Field.es.js +176 -0
- package/dist/Form/FieldArray.cjs.js +24 -0
- package/dist/Form/FieldArray.d.ts +3 -0
- package/dist/Form/FieldArray.es.js +25 -0
- package/dist/Form/Form.cjs.js +69 -0
- package/dist/Form/Form.d.ts +3 -0
- package/dist/Form/Form.es.js +69 -0
- package/dist/Form/defaultValidateMessages.cjs.js +51 -0
- package/dist/Form/defaultValidateMessages.d.ts +47 -0
- package/dist/Form/defaultValidateMessages.es.js +51 -0
- package/dist/Form/helpers.cjs.js +8 -0
- package/dist/Form/helpers.d.ts +1 -0
- package/dist/Form/helpers.es.js +8 -0
- package/dist/Form/index.cjs.js +13 -0
- package/dist/Form/index.d.ts +14 -0
- package/dist/Form/index.es.js +13 -0
- package/dist/Form/types.d.ts +147 -0
- package/dist/Form/useForm.cjs.js +230 -0
- package/dist/Form/useForm.d.ts +2 -0
- package/dist/Form/useForm.es.js +230 -0
- package/dist/Form/useWatch.cjs.js +14 -0
- package/dist/Form/useWatch.d.ts +3 -0
- package/dist/Form/useWatch.es.js +14 -0
- package/dist/Highlight/Highlight.cjs.js +113 -0
- package/dist/Highlight/Highlight.d.ts +3 -0
- package/dist/Highlight/Highlight.es.js +114 -0
- package/dist/Highlight/helpers.cjs.js +147 -0
- package/dist/Highlight/helpers.d.ts +27 -0
- package/dist/Highlight/helpers.es.js +147 -0
- package/dist/Highlight/index.d.ts +2 -0
- package/dist/Highlight/styles.cjs.js +11 -0
- package/dist/Highlight/styles.d.ts +4 -0
- package/dist/Highlight/styles.es.js +11 -0
- package/dist/Highlight/types.d.ts +53 -0
- package/dist/Image/styles.cjs.js +4 -5
- package/dist/Image/styles.es.js +4 -5
- package/dist/InputBase/InputBase.cjs.js +32 -0
- package/dist/InputBase/InputBase.d.ts +4 -0
- package/dist/InputBase/InputBase.es.js +33 -0
- package/dist/InputBase/index.d.ts +2 -0
- package/dist/InputBase/styles.cjs.js +61 -0
- package/dist/InputBase/styles.d.ts +7 -0
- package/dist/InputBase/styles.es.js +61 -0
- package/dist/InputBase/types.d.ts +25 -0
- package/dist/InputDate/InputDate.cjs.js +344 -0
- package/dist/InputDate/InputDate.d.ts +4 -0
- package/dist/InputDate/InputDate.es.js +345 -0
- package/dist/InputDate/helpers.cjs.js +78 -0
- package/dist/InputDate/helpers.d.ts +5 -0
- package/dist/InputDate/helpers.es.js +78 -0
- package/dist/InputDate/index.d.ts +2 -0
- package/dist/InputDate/styles.cjs.js +35 -0
- package/dist/InputDate/styles.d.ts +5 -0
- package/dist/InputDate/styles.es.js +35 -0
- package/dist/InputDate/types.d.ts +23 -0
- package/dist/InputNumber/InputNumber.cjs.js +70 -73
- package/dist/InputNumber/InputNumber.d.ts +1 -1
- package/dist/InputNumber/InputNumber.es.js +72 -75
- package/dist/InputNumber/styles.cjs.js +20 -60
- package/dist/InputNumber/styles.d.ts +4 -8
- package/dist/InputNumber/styles.es.js +21 -61
- package/dist/InputNumber/types.d.ts +2 -18
- package/dist/Layout/Header.cjs.js +27 -23
- package/dist/Layout/Header.d.ts +1 -1
- package/dist/Layout/Header.es.js +28 -24
- package/dist/Layout/Sidebar.cjs.js +24 -25
- package/dist/Layout/Sidebar.d.ts +1 -1
- package/dist/Layout/Sidebar.es.js +25 -26
- package/dist/Layout/index.d.ts +2 -2
- package/dist/Layout/styles.cjs.js +16 -52
- package/dist/Layout/styles.d.ts +2 -15
- package/dist/Layout/styles.es.js +16 -52
- package/dist/Layout/types.d.ts +7 -22
- package/dist/Loader/styles.cjs.js +5 -4
- package/dist/Loader/styles.es.js +5 -4
- package/dist/LoadingOverlay/LoadingOverlay.cjs.js +22 -0
- package/dist/LoadingOverlay/LoadingOverlay.d.ts +3 -0
- package/dist/LoadingOverlay/LoadingOverlay.es.js +23 -0
- package/dist/LoadingOverlay/index.d.ts +2 -0
- package/dist/LoadingOverlay/styles.cjs.js +28 -0
- package/dist/LoadingOverlay/styles.d.ts +5 -0
- package/dist/LoadingOverlay/styles.es.js +28 -0
- package/dist/LoadingOverlay/types.d.ts +16 -0
- package/dist/Menu/Menu.cjs.js +42 -0
- package/dist/Menu/Menu.d.ts +3 -0
- package/dist/Menu/Menu.es.js +43 -0
- package/dist/Menu/MenuItem.cjs.js +112 -0
- package/dist/Menu/MenuItem.d.ts +3 -0
- package/dist/Menu/MenuItem.es.js +113 -0
- package/dist/Menu/helpers.cjs.js +20 -0
- package/dist/Menu/helpers.d.ts +17 -0
- package/dist/Menu/helpers.es.js +20 -0
- package/dist/Menu/index.d.ts +2 -0
- package/dist/Menu/styles.cjs.js +98 -0
- package/dist/Menu/styles.d.ts +16 -0
- package/dist/Menu/styles.es.js +98 -0
- package/dist/Menu/types.d.ts +85 -0
- package/dist/Modal/Modal.cjs.js +15 -5
- package/dist/Modal/Modal.d.ts +1 -1
- package/dist/Modal/Modal.es.js +16 -6
- package/dist/Modal/styles.cjs.js +39 -9
- package/dist/Modal/styles.d.ts +4 -0
- package/dist/Modal/styles.es.js +40 -10
- package/dist/Modal/types.d.ts +2 -0
- package/dist/Notification/Notification.cjs.js +3 -3
- package/dist/Notification/Notification.es.js +3 -3
- package/dist/Notification/NotificationInstance.cjs.js +8 -15
- package/dist/Notification/NotificationInstance.es.js +8 -15
- package/dist/Notification/NotificationsStore.cjs.js +2 -7
- package/dist/Notification/NotificationsStore.es.js +2 -7
- package/dist/Notification/styles.cjs.js +6 -6
- package/dist/Notification/styles.es.js +6 -6
- package/dist/Pagination/Pagination.cjs.js +114 -0
- package/dist/Pagination/Pagination.d.ts +3 -0
- package/dist/Pagination/Pagination.es.js +115 -0
- package/dist/Pagination/index.d.ts +2 -0
- package/dist/Pagination/styles.cjs.js +54 -0
- package/dist/Pagination/styles.d.ts +2 -0
- package/dist/Pagination/styles.es.js +54 -0
- package/dist/Pagination/types.d.ts +49 -0
- package/dist/Progress/Progress.cjs.js +1 -1
- package/dist/Progress/Progress.es.js +1 -1
- package/dist/Progress/styles.cjs.js +5 -50
- package/dist/Progress/styles.es.js +5 -50
- package/dist/Progress/types.d.ts +1 -0
- package/dist/RadioButton/RadioButton.cjs.js +1 -1
- package/dist/RadioButton/RadioButton.es.js +1 -1
- package/dist/RadioButton/RadioButtonGroup.cjs.js +19 -22
- package/dist/RadioButton/RadioButtonGroup.es.js +19 -22
- package/dist/RadioButton/styles.cjs.js +11 -13
- package/dist/RadioButton/styles.es.js +11 -13
- package/dist/RichTextEditor/RichTextEditor.cjs.js +289 -0
- package/dist/RichTextEditor/RichTextEditor.d.ts +4 -0
- package/dist/RichTextEditor/RichTextEditor.es.js +290 -0
- package/dist/RichTextEditor/RichTextEditorColorControl.cjs.js +38 -0
- package/dist/RichTextEditor/RichTextEditorColorControl.d.ts +3 -0
- package/dist/RichTextEditor/RichTextEditorColorControl.es.js +39 -0
- package/dist/RichTextEditor/RichTextEditorTableControl.cjs.js +62 -0
- package/dist/RichTextEditor/RichTextEditorTableControl.d.ts +3 -0
- package/dist/RichTextEditor/RichTextEditorTableControl.es.js +63 -0
- package/dist/RichTextEditor/helpers.cjs.js +151 -0
- package/dist/RichTextEditor/helpers.d.ts +10 -0
- package/dist/RichTextEditor/helpers.es.js +151 -0
- package/dist/RichTextEditor/index.d.ts +2 -0
- package/dist/RichTextEditor/plugins.cjs.js +548 -0
- package/dist/RichTextEditor/plugins.d.ts +2 -0
- package/dist/RichTextEditor/plugins.es.js +548 -0
- package/dist/RichTextEditor/styles.cjs.js +60 -0
- package/dist/RichTextEditor/styles.d.ts +7 -0
- package/dist/RichTextEditor/styles.es.js +60 -0
- package/dist/RichTextEditor/types.d.ts +79 -0
- package/dist/Select/Select.cjs.js +30 -18
- package/dist/Select/Select.es.js +30 -18
- package/dist/Select/helpers.cjs.js +1 -1
- package/dist/Select/helpers.d.ts +24 -24
- package/dist/Select/helpers.es.js +1 -1
- package/dist/Select/styles.cjs.js +91 -118
- package/dist/Select/styles.d.ts +4 -5
- package/dist/Select/styles.es.js +91 -118
- package/dist/Select/types.d.ts +3 -23
- package/dist/Select/useSelect.cjs.js +8 -14
- package/dist/Select/useSelect.d.ts +20 -20
- package/dist/Select/useSelect.es.js +8 -14
- package/dist/Skeleton/Skeleton.cjs.js +35 -0
- package/dist/Skeleton/Skeleton.d.ts +3 -0
- package/dist/Skeleton/Skeleton.es.js +36 -0
- package/dist/Skeleton/SkeletonAvatar.cjs.js +17 -0
- package/dist/Skeleton/SkeletonAvatar.d.ts +3 -0
- package/dist/Skeleton/SkeletonAvatar.es.js +18 -0
- package/dist/Skeleton/SkeletonButton.cjs.js +21 -0
- package/dist/Skeleton/SkeletonButton.d.ts +3 -0
- package/dist/Skeleton/SkeletonButton.es.js +22 -0
- package/dist/Skeleton/SkeletonCard.cjs.js +15 -0
- package/dist/Skeleton/SkeletonCard.d.ts +3 -0
- package/dist/Skeleton/SkeletonCard.es.js +16 -0
- package/dist/Skeleton/SkeletonLayout.cjs.js +60 -0
- package/dist/Skeleton/SkeletonLayout.d.ts +3 -0
- package/dist/Skeleton/SkeletonLayout.es.js +61 -0
- package/dist/Skeleton/SkeletonList.cjs.js +39 -0
- package/dist/Skeleton/SkeletonList.d.ts +3 -0
- package/dist/Skeleton/SkeletonList.es.js +40 -0
- package/dist/Skeleton/SkeletonTextBlock.cjs.js +7 -0
- package/dist/Skeleton/SkeletonTextBlock.d.ts +5 -0
- package/dist/Skeleton/SkeletonTextBlock.es.js +8 -0
- package/dist/Skeleton/index.cjs.js +17 -0
- package/dist/Skeleton/index.d.ts +18 -0
- package/dist/Skeleton/index.es.js +17 -0
- package/dist/Skeleton/styles.cjs.js +59 -0
- package/dist/Skeleton/styles.d.ts +3 -0
- package/dist/Skeleton/styles.es.js +59 -0
- package/dist/Skeleton/types.d.ts +74 -0
- package/dist/Slider/Slider.cjs.js +282 -0
- package/dist/Slider/Slider.d.ts +3 -0
- package/dist/Slider/Slider.es.js +283 -0
- package/dist/Slider/index.d.ts +2 -0
- package/dist/Slider/styles.cjs.js +156 -0
- package/dist/Slider/styles.d.ts +35 -0
- package/dist/Slider/styles.es.js +156 -0
- package/dist/Slider/types.d.ts +53 -0
- package/dist/Spoiler/Spoiler.cjs.js +62 -0
- package/dist/Spoiler/Spoiler.d.ts +3 -0
- package/dist/Spoiler/Spoiler.es.js +63 -0
- package/dist/Spoiler/index.d.ts +2 -0
- package/dist/Spoiler/styles.cjs.js +15 -0
- package/dist/Spoiler/styles.d.ts +4 -0
- package/dist/Spoiler/styles.es.js +15 -0
- package/dist/Spoiler/types.d.ts +23 -0
- package/dist/Switch/Switch.cjs.js +32 -6
- package/dist/Switch/Switch.d.ts +2 -2
- package/dist/Switch/Switch.es.js +33 -7
- package/dist/Switch/styles.cjs.js +24 -7
- package/dist/Switch/styles.d.ts +4 -0
- package/dist/Switch/styles.es.js +24 -7
- package/dist/Switch/types.d.ts +3 -0
- package/dist/Tabs/Tab.cjs.js +8 -8
- package/dist/Tabs/Tab.es.js +8 -8
- package/dist/Tabs/TabPanel.cjs.js +3 -3
- package/dist/Tabs/TabPanel.es.js +3 -3
- package/dist/Tabs/Tabs.cjs.js +5 -4
- package/dist/Tabs/Tabs.d.ts +1 -1
- package/dist/Tabs/Tabs.es.js +5 -4
- package/dist/Tabs/TabsList.cjs.js +25 -1
- package/dist/Tabs/TabsList.d.ts +2 -2
- package/dist/Tabs/TabsList.es.js +25 -1
- package/dist/Tabs/styles.cjs.js +104 -34
- package/dist/Tabs/styles.d.ts +2 -0
- package/dist/Tabs/styles.es.js +104 -34
- package/dist/Tabs/types.d.ts +7 -3
- package/dist/Tag/Tag.cjs.js +4 -1
- package/dist/Tag/Tag.d.ts +1 -1
- package/dist/Tag/Tag.es.js +4 -1
- package/dist/Tag/styles.cjs.js +14 -9
- package/dist/Tag/styles.d.ts +2 -0
- package/dist/Tag/styles.es.js +14 -9
- package/dist/Tag/types.d.ts +6 -0
- package/dist/TextField/TextField.cjs.js +57 -56
- package/dist/TextField/TextField.d.ts +1 -1
- package/dist/TextField/TextField.es.js +58 -57
- package/dist/TextField/styles.cjs.js +9 -50
- package/dist/TextField/styles.d.ts +3 -8
- package/dist/TextField/styles.es.js +10 -51
- package/dist/TextField/types.d.ts +2 -20
- package/dist/Textarea/Textarea.cjs.js +57 -56
- package/dist/Textarea/Textarea.d.ts +1 -1
- package/dist/Textarea/Textarea.es.js +58 -57
- package/dist/Textarea/styles.cjs.js +10 -62
- package/dist/Textarea/styles.d.ts +3 -8
- package/dist/Textarea/styles.es.js +12 -64
- package/dist/Textarea/types.d.ts +2 -21
- package/dist/Tooltip/Tooltip.cjs.js +3 -1
- package/dist/Tooltip/Tooltip.d.ts +1 -1
- package/dist/Tooltip/Tooltip.es.js +3 -1
- package/dist/Tooltip/types.d.ts +3 -0
- package/dist/assets/box.svg.cjs.js +21 -0
- package/dist/assets/box.svg.es.js +5 -0
- package/dist/index.cjs.js +30 -0
- package/dist/index.d.ts +17 -2
- package/dist/index.es.js +30 -0
- package/dist/message/Message.cjs.js +42 -0
- package/dist/message/Message.d.ts +3 -0
- package/dist/message/Message.es.js +43 -0
- package/dist/message/MessageContext.cjs.js +101 -0
- package/dist/message/MessageContext.d.ts +4 -0
- package/dist/message/MessageContext.es.js +101 -0
- package/dist/message/index.cjs.js +8 -0
- package/dist/message/index.d.ts +6 -0
- package/dist/message/index.es.js +8 -0
- package/dist/message/styles.cjs.js +79 -0
- package/dist/message/styles.d.ts +11 -0
- package/dist/message/styles.es.js +79 -0
- package/dist/message/types.d.ts +42 -0
- package/dist/typography/Text/Text.es.js +3 -3
- package/dist/typography/Title/Title.cjs.js +2 -0
- package/dist/typography/Title/Title.d.ts +1 -1
- package/dist/typography/Title/Title.es.js +2 -0
- package/dist/typography/Title/styles.cjs.js +3 -0
- package/dist/typography/Title/styles.es.js +3 -0
- package/dist/typography/Title/types.d.ts +1 -0
- package/package.json +17 -13
package/dist/Layout/index.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { default as Header } from './Header';
|
|
|
3
3
|
import { default as Content } from './Content';
|
|
4
4
|
import { default as Footer } from './Footer';
|
|
5
5
|
import { default as Sidebar } from './Sidebar';
|
|
6
|
-
import { ILayoutSidebarProps, ILayoutProps, ILayoutHeaderProps
|
|
6
|
+
import { ILayoutSidebarProps, ILayoutProps, ILayoutHeaderProps } from './types';
|
|
7
7
|
type TLayout = typeof LayoutComponent & {
|
|
8
8
|
Header: typeof Header;
|
|
9
9
|
Content: typeof Content;
|
|
@@ -11,4 +11,4 @@ type TLayout = typeof LayoutComponent & {
|
|
|
11
11
|
Sidebar: typeof Sidebar;
|
|
12
12
|
};
|
|
13
13
|
declare const Layout: TLayout;
|
|
14
|
-
export { Layout, ILayoutHeaderProps,
|
|
14
|
+
export { Layout, ILayoutHeaderProps, ILayoutProps, ILayoutSidebarProps };
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const styled = require("styled-components");
|
|
4
|
+
const Menu = require("../Menu/Menu.cjs.js");
|
|
4
5
|
const HeaderStyled = styled.styled.header.withConfig({
|
|
5
6
|
shouldForwardProp: (prop) => prop !== "height"
|
|
6
7
|
})`
|
|
@@ -9,7 +10,7 @@ const HeaderStyled = styled.styled.header.withConfig({
|
|
|
9
10
|
padding-top: ${({ theme }) => theme.space.xs};
|
|
10
11
|
padding-bottom: ${({ theme }) => theme.space.xs};
|
|
11
12
|
svg {
|
|
12
|
-
color: ${({ theme }) => theme.
|
|
13
|
+
color: ${({ theme }) => theme.components.Layout.iconColor};
|
|
13
14
|
}
|
|
14
15
|
position: sticky;
|
|
15
16
|
top: 0;
|
|
@@ -18,65 +19,26 @@ const HeaderStyled = styled.styled.header.withConfig({
|
|
|
18
19
|
display: flex;
|
|
19
20
|
flex-wrap: wrap;
|
|
20
21
|
|
|
21
|
-
background: ${({ theme }) => theme.
|
|
22
|
+
background: ${({ theme }) => theme.components.Layout.headerBackground};
|
|
22
23
|
|
|
23
24
|
border-bottom: ${({ theme }) => theme.control.borderWidth} solid
|
|
24
|
-
${({ theme }) => theme.
|
|
25
|
+
${({ theme }) => theme.components.Layout.borderColor};
|
|
25
26
|
|
|
26
27
|
${({ height }) => `height: ${height};`};
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
}).attrs((props) => ({
|
|
31
|
-
className: props.active ? "quen-ui__layout-menu-item--active" : "quen-ui__layout-menu-item"
|
|
32
|
-
}))`
|
|
33
|
-
outline: none;
|
|
34
|
-
border: none;
|
|
35
|
-
display: flex;
|
|
36
|
-
align-items: center;
|
|
37
|
-
padding: 0.5rem 1rem;
|
|
38
|
-
cursor: pointer;
|
|
39
|
-
border-radius: 4px;
|
|
40
|
-
transition: background 0.2s ease;
|
|
41
|
-
background: transparent;
|
|
42
|
-
justify-content: ${({ collapsed }) => collapsed ? "center" : "flex-start"};
|
|
43
|
-
|
|
44
|
-
color: ${({ theme }) => theme.textColor};
|
|
45
|
-
|
|
46
|
-
a {
|
|
47
|
-
text-decoration: none;
|
|
48
|
-
color: ${({ theme }) => theme.textColor};
|
|
49
|
-
display: flex;
|
|
50
|
-
width: 100%;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
.menu-label {
|
|
54
|
-
width: 100%;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
&:hover {
|
|
58
|
-
background: ${({ theme, disabled, active }) => !disabled && !active && theme.colors.grayViolet["5"]};
|
|
28
|
+
|
|
29
|
+
.quen-ui__layout-header__content__menu-items {
|
|
30
|
+
flex-wrap: wrap;
|
|
59
31
|
}
|
|
60
|
-
|
|
61
|
-
${({ theme, disabled, active }) => active && !disabled && styled.css`
|
|
62
|
-
background-color: ${theme.colors.violet["5"]};
|
|
63
|
-
`}
|
|
64
|
-
`;
|
|
65
|
-
const SidebarMenuItem = styled.styled(LayoutMenuItem)`
|
|
66
|
-
a {
|
|
67
|
-
color: inherit;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
32
|
`;
|
|
71
33
|
const FooterStyled = styled.styled.footer`
|
|
72
34
|
grid-area: footer;
|
|
73
35
|
`;
|
|
74
|
-
const
|
|
36
|
+
const SidebarStyled = styled.styled.aside.withConfig({
|
|
75
37
|
shouldForwardProp: (prop) => !["isMobile", "isOpen", "isCollapsed", "collapsedWidth"].includes(prop)
|
|
76
38
|
})`
|
|
77
39
|
grid-area: slider;
|
|
78
40
|
min-width: ${({ collapsible, collapsed, collapsedWidth }) => collapsible && collapsed ? collapsedWidth : "250px"};
|
|
79
|
-
background: ${({ theme }) => theme.
|
|
41
|
+
background: ${({ theme }) => theme.components.Layout.sidebarBackground};
|
|
80
42
|
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
81
43
|
position: relative;
|
|
82
44
|
overflow: auto;
|
|
@@ -118,7 +80,7 @@ const LayoutStyled = styled.styled.div.withConfig({
|
|
|
118
80
|
grid-template-areas: "header" "content" "footer";
|
|
119
81
|
grid-template-columns: 1fr;
|
|
120
82
|
|
|
121
|
-
${
|
|
83
|
+
${SidebarStyled} {
|
|
122
84
|
display: none;
|
|
123
85
|
}
|
|
124
86
|
}
|
|
@@ -135,16 +97,18 @@ styled.styled.div`
|
|
|
135
97
|
left: 0;
|
|
136
98
|
right: 0;
|
|
137
99
|
bottom: 0;
|
|
138
|
-
background: ${({ theme }) => theme.
|
|
100
|
+
background: ${({ theme }) => theme.components.Layout.sidebarBackground};
|
|
139
101
|
z-index: 100;
|
|
140
102
|
opacity: 1;
|
|
141
103
|
pointer-events: all;
|
|
142
104
|
transition: opacity 0.3s ease;
|
|
143
105
|
`;
|
|
106
|
+
const SidebarMenuStyled = styled.styled(Menu)`
|
|
107
|
+
gap: 0;
|
|
108
|
+
`;
|
|
144
109
|
exports.ContentStyled = ContentStyled;
|
|
145
110
|
exports.FooterStyled = FooterStyled;
|
|
146
111
|
exports.HeaderStyled = HeaderStyled;
|
|
147
|
-
exports.LayoutMenuItem = LayoutMenuItem;
|
|
148
112
|
exports.LayoutStyled = LayoutStyled;
|
|
149
|
-
exports.
|
|
150
|
-
exports.
|
|
113
|
+
exports.SidebarMenuStyled = SidebarMenuStyled;
|
|
114
|
+
exports.SidebarStyled = SidebarStyled;
|
package/dist/Layout/styles.d.ts
CHANGED
|
@@ -1,24 +1,10 @@
|
|
|
1
1
|
export declare const HeaderStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>, {
|
|
2
2
|
height?: string;
|
|
3
3
|
}>> & string;
|
|
4
|
-
export declare const LayoutMenuItem: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('styled-components/dist/types').Substitute<import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>>, {
|
|
5
|
-
active?: boolean;
|
|
6
|
-
}>, {
|
|
7
|
-
disabled?: boolean;
|
|
8
|
-
active?: boolean;
|
|
9
|
-
collapsed?: boolean;
|
|
10
|
-
}>> & string;
|
|
11
|
-
export declare const SidebarMenuItem: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('styled-components/dist/types').Substitute<import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>>, {
|
|
12
|
-
active?: boolean;
|
|
13
|
-
}>, "disabled" | "active" | "collapsed"> & {
|
|
14
|
-
disabled?: boolean;
|
|
15
|
-
active?: boolean;
|
|
16
|
-
collapsed?: boolean;
|
|
17
|
-
}, never>> & string;
|
|
18
4
|
export declare const FooterStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>, {
|
|
19
5
|
height?: string;
|
|
20
6
|
}>> & string;
|
|
21
|
-
export declare const
|
|
7
|
+
export declare const SidebarStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLElement>, HTMLElement>, {
|
|
22
8
|
mobile?: boolean;
|
|
23
9
|
open?: boolean;
|
|
24
10
|
collapsible?: boolean;
|
|
@@ -30,3 +16,4 @@ export declare const LayoutStyled: import('styled-components/dist/types').IStyle
|
|
|
30
16
|
breakpoint: number;
|
|
31
17
|
}>> & string;
|
|
32
18
|
export declare const OverlayStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
19
|
+
export declare const SidebarMenuStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('..').IMenuProps<Record<string, any>>, never>> & string & Omit<(<Item extends Record<string, any> = import('..').IMenuDefaultItem>(props: import('..').IMenuProps<Item>) => import("react/jsx-runtime").JSX.Element), keyof import('react').Component<any, {}, any>>;
|
package/dist/Layout/styles.es.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { styled, css } from "styled-components";
|
|
2
|
+
import Menu from "../Menu/Menu.es.js";
|
|
2
3
|
const HeaderStyled = styled.header.withConfig({
|
|
3
4
|
shouldForwardProp: (prop) => prop !== "height"
|
|
4
5
|
})`
|
|
@@ -7,7 +8,7 @@ const HeaderStyled = styled.header.withConfig({
|
|
|
7
8
|
padding-top: ${({ theme }) => theme.space.xs};
|
|
8
9
|
padding-bottom: ${({ theme }) => theme.space.xs};
|
|
9
10
|
svg {
|
|
10
|
-
color: ${({ theme }) => theme.
|
|
11
|
+
color: ${({ theme }) => theme.components.Layout.iconColor};
|
|
11
12
|
}
|
|
12
13
|
position: sticky;
|
|
13
14
|
top: 0;
|
|
@@ -16,65 +17,26 @@ const HeaderStyled = styled.header.withConfig({
|
|
|
16
17
|
display: flex;
|
|
17
18
|
flex-wrap: wrap;
|
|
18
19
|
|
|
19
|
-
background: ${({ theme }) => theme.
|
|
20
|
+
background: ${({ theme }) => theme.components.Layout.headerBackground};
|
|
20
21
|
|
|
21
22
|
border-bottom: ${({ theme }) => theme.control.borderWidth} solid
|
|
22
|
-
${({ theme }) => theme.
|
|
23
|
+
${({ theme }) => theme.components.Layout.borderColor};
|
|
23
24
|
|
|
24
25
|
${({ height }) => `height: ${height};`};
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
}).attrs((props) => ({
|
|
29
|
-
className: props.active ? "quen-ui__layout-menu-item--active" : "quen-ui__layout-menu-item"
|
|
30
|
-
}))`
|
|
31
|
-
outline: none;
|
|
32
|
-
border: none;
|
|
33
|
-
display: flex;
|
|
34
|
-
align-items: center;
|
|
35
|
-
padding: 0.5rem 1rem;
|
|
36
|
-
cursor: pointer;
|
|
37
|
-
border-radius: 4px;
|
|
38
|
-
transition: background 0.2s ease;
|
|
39
|
-
background: transparent;
|
|
40
|
-
justify-content: ${({ collapsed }) => collapsed ? "center" : "flex-start"};
|
|
41
|
-
|
|
42
|
-
color: ${({ theme }) => theme.textColor};
|
|
43
|
-
|
|
44
|
-
a {
|
|
45
|
-
text-decoration: none;
|
|
46
|
-
color: ${({ theme }) => theme.textColor};
|
|
47
|
-
display: flex;
|
|
48
|
-
width: 100%;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
.menu-label {
|
|
52
|
-
width: 100%;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
&:hover {
|
|
56
|
-
background: ${({ theme, disabled, active }) => !disabled && !active && theme.colors.grayViolet["5"]};
|
|
26
|
+
|
|
27
|
+
.quen-ui__layout-header__content__menu-items {
|
|
28
|
+
flex-wrap: wrap;
|
|
57
29
|
}
|
|
58
|
-
|
|
59
|
-
${({ theme, disabled, active }) => active && !disabled && css`
|
|
60
|
-
background-color: ${theme.colors.violet["5"]};
|
|
61
|
-
`}
|
|
62
|
-
`;
|
|
63
|
-
const SidebarMenuItem = styled(LayoutMenuItem)`
|
|
64
|
-
a {
|
|
65
|
-
color: inherit;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
30
|
`;
|
|
69
31
|
const FooterStyled = styled.footer`
|
|
70
32
|
grid-area: footer;
|
|
71
33
|
`;
|
|
72
|
-
const
|
|
34
|
+
const SidebarStyled = styled.aside.withConfig({
|
|
73
35
|
shouldForwardProp: (prop) => !["isMobile", "isOpen", "isCollapsed", "collapsedWidth"].includes(prop)
|
|
74
36
|
})`
|
|
75
37
|
grid-area: slider;
|
|
76
38
|
min-width: ${({ collapsible, collapsed, collapsedWidth }) => collapsible && collapsed ? collapsedWidth : "250px"};
|
|
77
|
-
background: ${({ theme }) => theme.
|
|
39
|
+
background: ${({ theme }) => theme.components.Layout.sidebarBackground};
|
|
78
40
|
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
79
41
|
position: relative;
|
|
80
42
|
overflow: auto;
|
|
@@ -116,7 +78,7 @@ const LayoutStyled = styled.div.withConfig({
|
|
|
116
78
|
grid-template-areas: "header" "content" "footer";
|
|
117
79
|
grid-template-columns: 1fr;
|
|
118
80
|
|
|
119
|
-
${
|
|
81
|
+
${SidebarStyled} {
|
|
120
82
|
display: none;
|
|
121
83
|
}
|
|
122
84
|
}
|
|
@@ -133,18 +95,20 @@ styled.div`
|
|
|
133
95
|
left: 0;
|
|
134
96
|
right: 0;
|
|
135
97
|
bottom: 0;
|
|
136
|
-
background: ${({ theme }) => theme.
|
|
98
|
+
background: ${({ theme }) => theme.components.Layout.sidebarBackground};
|
|
137
99
|
z-index: 100;
|
|
138
100
|
opacity: 1;
|
|
139
101
|
pointer-events: all;
|
|
140
102
|
transition: opacity 0.3s ease;
|
|
141
103
|
`;
|
|
104
|
+
const SidebarMenuStyled = styled(Menu)`
|
|
105
|
+
gap: 0;
|
|
106
|
+
`;
|
|
142
107
|
export {
|
|
143
108
|
ContentStyled,
|
|
144
109
|
FooterStyled,
|
|
145
110
|
HeaderStyled,
|
|
146
|
-
LayoutMenuItem,
|
|
147
111
|
LayoutStyled,
|
|
148
|
-
|
|
149
|
-
|
|
112
|
+
SidebarMenuStyled,
|
|
113
|
+
SidebarStyled
|
|
150
114
|
};
|
package/dist/Layout/types.d.ts
CHANGED
|
@@ -1,20 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
|
|
3
|
-
/** Unique item identifier */
|
|
4
|
-
key: string;
|
|
5
|
-
/** Icon displayed before label */
|
|
6
|
-
icon?: React.ReactNode;
|
|
7
|
-
/** Menu item content */
|
|
8
|
-
label: React.ReactNode;
|
|
9
|
-
/** Click handler */
|
|
10
|
-
onClick?: () => void;
|
|
11
|
-
/** Visual active state (highlighting) */
|
|
12
|
-
active?: boolean;
|
|
13
|
-
/** Disables interaction */
|
|
14
|
-
disabled?: boolean;
|
|
15
|
-
/** Custom CSS classes */
|
|
16
|
-
className?: string;
|
|
17
|
-
}
|
|
2
|
+
import { IMenuDefaultItem } from '../Menu';
|
|
18
3
|
export interface ILayoutContextProps {
|
|
19
4
|
/** Mobile layout detection (based on breakpoint) */
|
|
20
5
|
mobile: boolean;
|
|
@@ -35,13 +20,12 @@ export interface ILayoutHeaderProps {
|
|
|
35
20
|
/** Header height */
|
|
36
21
|
height?: string;
|
|
37
22
|
/** Navigation menu items */
|
|
38
|
-
menuItems?:
|
|
39
|
-
/** Custom menu item renderer (overrides default) */
|
|
40
|
-
renderMenuItem?: (item: ILayoutMenuItem) => React.ReactNode;
|
|
23
|
+
menuItems?: IMenuDefaultItem[];
|
|
41
24
|
/** Brand logo/content */
|
|
42
25
|
logo?: React.ReactNode;
|
|
43
26
|
/** Custom CSS classes for menu item */
|
|
44
27
|
classNameMenuItem?: string;
|
|
28
|
+
activeMenuKeys?: string[];
|
|
45
29
|
}
|
|
46
30
|
export interface ILayoutProps {
|
|
47
31
|
/** Viewport width (px) for mobile/desktop switch */
|
|
@@ -57,11 +41,12 @@ export interface ILayoutSidebarProps {
|
|
|
57
41
|
/** Custom CSS classes */
|
|
58
42
|
className?: string;
|
|
59
43
|
/** Navigation items in sidebar */
|
|
60
|
-
menuItems?:
|
|
61
|
-
/** Custom menu item renderer */
|
|
62
|
-
renderMenuItem?: (item: ILayoutMenuItem) => React.ReactNode;
|
|
44
|
+
menuItems?: IMenuDefaultItem[];
|
|
63
45
|
/** Title menu in mobile version */
|
|
64
46
|
titleDrawer?: string;
|
|
47
|
+
/** Custom CSS classes for menu item */
|
|
48
|
+
classNameMenuItem?: string;
|
|
49
|
+
activeMenuKeys?: string[];
|
|
65
50
|
}
|
|
66
51
|
export interface ILayoutFooterProps {
|
|
67
52
|
/** Content */
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const styled = require("styled-components");
|
|
4
|
+
const polished = require("polished");
|
|
4
5
|
const BarsLoaderStyled = styled.div.withConfig({
|
|
5
6
|
shouldForwardProp: (prop) => prop !== "height"
|
|
6
7
|
})`
|
|
@@ -13,7 +14,7 @@ const BarsLoaderStyled = styled.div.withConfig({
|
|
|
13
14
|
.bar {
|
|
14
15
|
width: 10px;
|
|
15
16
|
height: 30px;
|
|
16
|
-
background-color: ${({ theme }) => theme.
|
|
17
|
+
background-color: ${({ theme }) => theme.components.Loader.color};
|
|
17
18
|
margin: 0 5px;
|
|
18
19
|
animation: bar-animation 1.4s infinite ease-in-out;
|
|
19
20
|
}
|
|
@@ -42,8 +43,8 @@ const OvalLoaderStyled = styled.div.withConfig({
|
|
|
42
43
|
})`
|
|
43
44
|
width: ${({ height }) => height}rem;
|
|
44
45
|
height: ${({ height }) => height}rem;
|
|
45
|
-
border: 5px solid ${({ theme }) => theme.
|
|
46
|
-
border-top: 5px solid ${({ theme }) => theme.
|
|
46
|
+
border: 5px solid ${({ theme }) => polished.rgba(theme.components.Loader.color, 0.3)};
|
|
47
|
+
border-top: 5px solid ${({ theme }) => theme.components.Loader.color};
|
|
47
48
|
border-radius: 50%;
|
|
48
49
|
animation: spin 1s linear infinite;
|
|
49
50
|
}
|
|
@@ -68,7 +69,7 @@ const DotsLoaderStyled = styled.div.withConfig({
|
|
|
68
69
|
.dot {
|
|
69
70
|
width: ${({ height }) => height / 2}rem;
|
|
70
71
|
height: ${({ height }) => height / 2}rem;
|
|
71
|
-
background-color: ${({ theme }) => theme.
|
|
72
|
+
background-color: ${({ theme }) => theme.components.Loader.color};
|
|
72
73
|
border-radius: 50%;
|
|
73
74
|
margin: 0 5px;
|
|
74
75
|
animation: dot-animation 1.4s infinite ease-in-out;
|
package/dist/Loader/styles.es.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import styled from "styled-components";
|
|
2
|
+
import { rgba } from "polished";
|
|
2
3
|
const BarsLoaderStyled = styled.div.withConfig({
|
|
3
4
|
shouldForwardProp: (prop) => prop !== "height"
|
|
4
5
|
})`
|
|
@@ -11,7 +12,7 @@ const BarsLoaderStyled = styled.div.withConfig({
|
|
|
11
12
|
.bar {
|
|
12
13
|
width: 10px;
|
|
13
14
|
height: 30px;
|
|
14
|
-
background-color: ${({ theme }) => theme.
|
|
15
|
+
background-color: ${({ theme }) => theme.components.Loader.color};
|
|
15
16
|
margin: 0 5px;
|
|
16
17
|
animation: bar-animation 1.4s infinite ease-in-out;
|
|
17
18
|
}
|
|
@@ -40,8 +41,8 @@ const OvalLoaderStyled = styled.div.withConfig({
|
|
|
40
41
|
})`
|
|
41
42
|
width: ${({ height }) => height}rem;
|
|
42
43
|
height: ${({ height }) => height}rem;
|
|
43
|
-
border: 5px solid ${({ theme }) => theme.
|
|
44
|
-
border-top: 5px solid ${({ theme }) => theme.
|
|
44
|
+
border: 5px solid ${({ theme }) => rgba(theme.components.Loader.color, 0.3)};
|
|
45
|
+
border-top: 5px solid ${({ theme }) => theme.components.Loader.color};
|
|
45
46
|
border-radius: 50%;
|
|
46
47
|
animation: spin 1s linear infinite;
|
|
47
48
|
}
|
|
@@ -66,7 +67,7 @@ const DotsLoaderStyled = styled.div.withConfig({
|
|
|
66
67
|
.dot {
|
|
67
68
|
width: ${({ height }) => height / 2}rem;
|
|
68
69
|
height: ${({ height }) => height / 2}rem;
|
|
69
|
-
background-color: ${({ theme }) => theme.
|
|
70
|
+
background-color: ${({ theme }) => theme.components.Loader.color};
|
|
70
71
|
border-radius: 50%;
|
|
71
72
|
margin: 0 5px;
|
|
72
73
|
animation: dot-animation 1.4s infinite ease-in-out;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const styles = require("./styles.cjs.js");
|
|
4
|
+
const Loader = require("../Loader/Loader.cjs.js");
|
|
5
|
+
const Text = require("../typography/Text/Text.cjs.js");
|
|
6
|
+
const LoadingOverlay = ({
|
|
7
|
+
children,
|
|
8
|
+
loading,
|
|
9
|
+
backdrop = true,
|
|
10
|
+
label,
|
|
11
|
+
loaderVariant,
|
|
12
|
+
zIndex = 1e3
|
|
13
|
+
}) => {
|
|
14
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(styles.LoadingOverlayWrapper, { children: [
|
|
15
|
+
children,
|
|
16
|
+
loading && /* @__PURE__ */ jsxRuntime.jsxs(styles.LoadingOverlayStyled, { backdrop, zIndex, children: [
|
|
17
|
+
/* @__PURE__ */ jsxRuntime.jsx(Loader, { view: loaderVariant, size: "l" }),
|
|
18
|
+
label && /* @__PURE__ */ jsxRuntime.jsx(Text, { size: "s", children: label })
|
|
19
|
+
] })
|
|
20
|
+
] });
|
|
21
|
+
};
|
|
22
|
+
module.exports = LoadingOverlay;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { LoadingOverlayWrapper, LoadingOverlayStyled } from "./styles.es.js";
|
|
3
|
+
import Loader from "../Loader/Loader.es.js";
|
|
4
|
+
import Text from "../typography/Text/Text.es.js";
|
|
5
|
+
const LoadingOverlay = ({
|
|
6
|
+
children,
|
|
7
|
+
loading,
|
|
8
|
+
backdrop = true,
|
|
9
|
+
label,
|
|
10
|
+
loaderVariant,
|
|
11
|
+
zIndex = 1e3
|
|
12
|
+
}) => {
|
|
13
|
+
return /* @__PURE__ */ jsxs(LoadingOverlayWrapper, { children: [
|
|
14
|
+
children,
|
|
15
|
+
loading && /* @__PURE__ */ jsxs(LoadingOverlayStyled, { backdrop, zIndex, children: [
|
|
16
|
+
/* @__PURE__ */ jsx(Loader, { view: loaderVariant, size: "l" }),
|
|
17
|
+
label && /* @__PURE__ */ jsx(Text, { size: "s", children: label })
|
|
18
|
+
] })
|
|
19
|
+
] });
|
|
20
|
+
};
|
|
21
|
+
export {
|
|
22
|
+
LoadingOverlay as default
|
|
23
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const styled = require("styled-components");
|
|
4
|
+
const LoadingOverlayWrapper = styled.div`
|
|
5
|
+
position: relative;
|
|
6
|
+
`;
|
|
7
|
+
const fadeIn = styled.keyframes`
|
|
8
|
+
from { opacity: 0; }
|
|
9
|
+
to { opacity: 1; }
|
|
10
|
+
`;
|
|
11
|
+
const LoadingOverlayStyled = styled.div`
|
|
12
|
+
position: absolute;
|
|
13
|
+
inset: 0;
|
|
14
|
+
display: flex;
|
|
15
|
+
flex-direction: column;
|
|
16
|
+
justify-content: center;
|
|
17
|
+
align-items: center;
|
|
18
|
+
z-index: ${({ zIndex }) => zIndex};
|
|
19
|
+
pointer-events: all;
|
|
20
|
+
animation: ${fadeIn} 0.2s ease;
|
|
21
|
+
|
|
22
|
+
${({ backdrop, theme }) => backdrop && styled.css`
|
|
23
|
+
background: ${theme.components.LoadingOverlay.background};
|
|
24
|
+
backdrop-filter: ${theme.components.LoadingOverlay.blur};
|
|
25
|
+
`}
|
|
26
|
+
`;
|
|
27
|
+
exports.LoadingOverlayStyled = LoadingOverlayStyled;
|
|
28
|
+
exports.LoadingOverlayWrapper = LoadingOverlayWrapper;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const LoadingOverlayWrapper: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
2
|
+
export declare const LoadingOverlayStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
|
|
3
|
+
backdrop?: boolean;
|
|
4
|
+
zIndex: number;
|
|
5
|
+
}>> & string;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import styled, { keyframes, css } from "styled-components";
|
|
2
|
+
const LoadingOverlayWrapper = styled.div`
|
|
3
|
+
position: relative;
|
|
4
|
+
`;
|
|
5
|
+
const fadeIn = keyframes`
|
|
6
|
+
from { opacity: 0; }
|
|
7
|
+
to { opacity: 1; }
|
|
8
|
+
`;
|
|
9
|
+
const LoadingOverlayStyled = styled.div`
|
|
10
|
+
position: absolute;
|
|
11
|
+
inset: 0;
|
|
12
|
+
display: flex;
|
|
13
|
+
flex-direction: column;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
align-items: center;
|
|
16
|
+
z-index: ${({ zIndex }) => zIndex};
|
|
17
|
+
pointer-events: all;
|
|
18
|
+
animation: ${fadeIn} 0.2s ease;
|
|
19
|
+
|
|
20
|
+
${({ backdrop, theme }) => backdrop && css`
|
|
21
|
+
background: ${theme.components.LoadingOverlay.background};
|
|
22
|
+
backdrop-filter: ${theme.components.LoadingOverlay.blur};
|
|
23
|
+
`}
|
|
24
|
+
`;
|
|
25
|
+
export {
|
|
26
|
+
LoadingOverlayStyled,
|
|
27
|
+
LoadingOverlayWrapper
|
|
28
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ILoaderProps } from '../Loader';
|
|
3
|
+
export interface ILoadingOverlayProps {
|
|
4
|
+
/** Whether to show overlay */
|
|
5
|
+
loading?: boolean;
|
|
6
|
+
/** Text under the spinner */
|
|
7
|
+
label?: string;
|
|
8
|
+
/** Should I darken the background */
|
|
9
|
+
backdrop?: boolean;
|
|
10
|
+
/** Control rendering via children */
|
|
11
|
+
children?: ReactNode;
|
|
12
|
+
/** Visual style of the loading indicator */
|
|
13
|
+
loaderVariant?: ILoaderProps["view"];
|
|
14
|
+
/** Controls overlay */
|
|
15
|
+
zIndex?: number;
|
|
16
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const React = require("react");
|
|
4
|
+
const helpers = require("./helpers.cjs.js");
|
|
5
|
+
const MenuItem = require("./MenuItem.cjs.js");
|
|
6
|
+
const styles = require("./styles.cjs.js");
|
|
7
|
+
const Menu = (props) => {
|
|
8
|
+
const direction = React.useMemo(() => {
|
|
9
|
+
return props.direction === "vertical" ? "column" : "row";
|
|
10
|
+
}, [props.direction]);
|
|
11
|
+
const {
|
|
12
|
+
items,
|
|
13
|
+
getItemRightContent,
|
|
14
|
+
getItemDisabled,
|
|
15
|
+
getItemLeftContent,
|
|
16
|
+
getItemKey,
|
|
17
|
+
getItemLabel,
|
|
18
|
+
getItemClassName,
|
|
19
|
+
className,
|
|
20
|
+
getItemOnClick,
|
|
21
|
+
style
|
|
22
|
+
} = helpers.withDefaultGetters(props);
|
|
23
|
+
return /* @__PURE__ */ jsxRuntime.jsx(styles.MenuStyled, { gap: "xs", direction, className, style, children: (items ?? []).map((item) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
24
|
+
MenuItem,
|
|
25
|
+
{
|
|
26
|
+
className: props.classNameMenuItem,
|
|
27
|
+
item,
|
|
28
|
+
getItemKey,
|
|
29
|
+
getItemLabel,
|
|
30
|
+
getItemOnClick,
|
|
31
|
+
getItemDisabled,
|
|
32
|
+
getItemClassName,
|
|
33
|
+
getItemLeftContent,
|
|
34
|
+
getItemRightContent,
|
|
35
|
+
size: props.size,
|
|
36
|
+
activeKeys: props.activeKeys,
|
|
37
|
+
direction: props.direction || "horizontal"
|
|
38
|
+
},
|
|
39
|
+
getItemKey(item)
|
|
40
|
+
)) });
|
|
41
|
+
};
|
|
42
|
+
module.exports = Menu;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo } from "react";
|
|
3
|
+
import { withDefaultGetters } from "./helpers.es.js";
|
|
4
|
+
import MenuItem from "./MenuItem.es.js";
|
|
5
|
+
import { MenuStyled } from "./styles.es.js";
|
|
6
|
+
const Menu = (props) => {
|
|
7
|
+
const direction = useMemo(() => {
|
|
8
|
+
return props.direction === "vertical" ? "column" : "row";
|
|
9
|
+
}, [props.direction]);
|
|
10
|
+
const {
|
|
11
|
+
items,
|
|
12
|
+
getItemRightContent,
|
|
13
|
+
getItemDisabled,
|
|
14
|
+
getItemLeftContent,
|
|
15
|
+
getItemKey,
|
|
16
|
+
getItemLabel,
|
|
17
|
+
getItemClassName,
|
|
18
|
+
className,
|
|
19
|
+
getItemOnClick,
|
|
20
|
+
style
|
|
21
|
+
} = withDefaultGetters(props);
|
|
22
|
+
return /* @__PURE__ */ jsx(MenuStyled, { gap: "xs", direction, className, style, children: (items ?? []).map((item) => /* @__PURE__ */ jsx(
|
|
23
|
+
MenuItem,
|
|
24
|
+
{
|
|
25
|
+
className: props.classNameMenuItem,
|
|
26
|
+
item,
|
|
27
|
+
getItemKey,
|
|
28
|
+
getItemLabel,
|
|
29
|
+
getItemOnClick,
|
|
30
|
+
getItemDisabled,
|
|
31
|
+
getItemClassName,
|
|
32
|
+
getItemLeftContent,
|
|
33
|
+
getItemRightContent,
|
|
34
|
+
size: props.size,
|
|
35
|
+
activeKeys: props.activeKeys,
|
|
36
|
+
direction: props.direction || "horizontal"
|
|
37
|
+
},
|
|
38
|
+
getItemKey(item)
|
|
39
|
+
)) });
|
|
40
|
+
};
|
|
41
|
+
export {
|
|
42
|
+
Menu as default
|
|
43
|
+
};
|