@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
|
@@ -23,36 +23,30 @@ function useSelect(props) {
|
|
|
23
23
|
const [searchValue, setSearchValue] = useState("");
|
|
24
24
|
const [currentValue, setCurrentValue] = useState(getDefaultCurrentValue(props.getItemValue, props.value));
|
|
25
25
|
const items = useMemo(() => {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
return (_a2 = props.getItemLabel) == null ? void 0 : _a2.call(props, item).toLowerCase().includes(searchValue.toLowerCase());
|
|
30
|
-
})) ?? [];
|
|
26
|
+
return props.items?.filter((item) => {
|
|
27
|
+
return props.getItemLabel?.(item).toLowerCase().includes(searchValue.toLowerCase());
|
|
28
|
+
}) ?? [];
|
|
31
29
|
}, [props.items, searchValue]);
|
|
32
30
|
function handleChange(value) {
|
|
33
|
-
var _a, _b, _c, _d;
|
|
34
31
|
if (props.multi && Array.isArray(value)) {
|
|
35
32
|
const multiProps = props;
|
|
36
33
|
if (props.onChangeReturnValue === "value") {
|
|
37
|
-
|
|
34
|
+
props.onChange?.(value);
|
|
38
35
|
}
|
|
39
36
|
if (props.onChangeReturnValue === "item") {
|
|
40
37
|
const items2 = value.map(
|
|
41
38
|
(v) => props.items.find((i) => props.getItemValue(i) === v)
|
|
42
39
|
);
|
|
43
|
-
|
|
40
|
+
multiProps.onChange?.(items2);
|
|
44
41
|
}
|
|
45
42
|
setCurrentValue(value || null);
|
|
46
43
|
} else {
|
|
47
44
|
const singleProps = props;
|
|
48
|
-
const item = props.items.find((i) =>
|
|
49
|
-
var _a2;
|
|
50
|
-
return ((_a2 = props.getItemValue) == null ? void 0 : _a2.call(props, i)) === value;
|
|
51
|
-
}) ?? null;
|
|
45
|
+
const item = props.items.find((i) => props.getItemValue?.(i) === value) ?? null;
|
|
52
46
|
if (props.onChangeReturnValue === "item") {
|
|
53
|
-
|
|
47
|
+
singleProps.onChange?.(item || null);
|
|
54
48
|
} else {
|
|
55
|
-
|
|
49
|
+
singleProps.onChange?.(value);
|
|
56
50
|
}
|
|
57
51
|
setCurrentValue(value || null);
|
|
58
52
|
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const styles = require("./styles.cjs.js");
|
|
4
|
+
const Flex = require("../Flex/Flex.cjs.js");
|
|
5
|
+
const Skeleton = ({
|
|
6
|
+
width = "100%",
|
|
7
|
+
animation,
|
|
8
|
+
children,
|
|
9
|
+
variant = "rect",
|
|
10
|
+
style,
|
|
11
|
+
className,
|
|
12
|
+
lines = 1,
|
|
13
|
+
loading = true,
|
|
14
|
+
height = "100%"
|
|
15
|
+
}) => {
|
|
16
|
+
if (!loading) {
|
|
17
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children });
|
|
18
|
+
}
|
|
19
|
+
if (variant === "text" && lines > 1) {
|
|
20
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Flex, { direction: "column", gap: "m", style, className, children: Array.from({ length: lines }).map((_, i) => /* @__PURE__ */ jsxRuntime.jsx(styles.SkeletonLineStyled, { width: width || "100%", variant: "text", animation, "data-testid": "skeleton-line" }, i)) });
|
|
21
|
+
}
|
|
22
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
23
|
+
styles.SkeletonStyled,
|
|
24
|
+
{
|
|
25
|
+
"data-testid": "skeleton",
|
|
26
|
+
width,
|
|
27
|
+
height,
|
|
28
|
+
variant,
|
|
29
|
+
animation,
|
|
30
|
+
style,
|
|
31
|
+
className
|
|
32
|
+
}
|
|
33
|
+
);
|
|
34
|
+
};
|
|
35
|
+
module.exports = Skeleton;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { SkeletonLineStyled, SkeletonStyled } from "./styles.es.js";
|
|
3
|
+
import Flex from "../Flex/Flex.es.js";
|
|
4
|
+
const Skeleton = ({
|
|
5
|
+
width = "100%",
|
|
6
|
+
animation,
|
|
7
|
+
children,
|
|
8
|
+
variant = "rect",
|
|
9
|
+
style,
|
|
10
|
+
className,
|
|
11
|
+
lines = 1,
|
|
12
|
+
loading = true,
|
|
13
|
+
height = "100%"
|
|
14
|
+
}) => {
|
|
15
|
+
if (!loading) {
|
|
16
|
+
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
17
|
+
}
|
|
18
|
+
if (variant === "text" && lines > 1) {
|
|
19
|
+
return /* @__PURE__ */ jsx(Flex, { direction: "column", gap: "m", style, className, children: Array.from({ length: lines }).map((_, i) => /* @__PURE__ */ jsx(SkeletonLineStyled, { width: width || "100%", variant: "text", animation, "data-testid": "skeleton-line" }, i)) });
|
|
20
|
+
}
|
|
21
|
+
return /* @__PURE__ */ jsx(
|
|
22
|
+
SkeletonStyled,
|
|
23
|
+
{
|
|
24
|
+
"data-testid": "skeleton",
|
|
25
|
+
width,
|
|
26
|
+
height,
|
|
27
|
+
variant,
|
|
28
|
+
animation,
|
|
29
|
+
style,
|
|
30
|
+
className
|
|
31
|
+
}
|
|
32
|
+
);
|
|
33
|
+
};
|
|
34
|
+
export {
|
|
35
|
+
Skeleton as default
|
|
36
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const theme = require("@quen-ui/theme");
|
|
4
|
+
const Skeleton = require("./Skeleton.cjs.js");
|
|
5
|
+
const SkeletonAvatar = ({ size = "m", ...props }) => {
|
|
6
|
+
const theme$1 = theme.useTheme();
|
|
7
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8
|
+
Skeleton,
|
|
9
|
+
{
|
|
10
|
+
width: theme$1.control.height[size],
|
|
11
|
+
height: theme$1.control.height[size],
|
|
12
|
+
variant: "rounded",
|
|
13
|
+
...props
|
|
14
|
+
}
|
|
15
|
+
);
|
|
16
|
+
};
|
|
17
|
+
module.exports = SkeletonAvatar;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useTheme } from "@quen-ui/theme";
|
|
3
|
+
import Skeleton from "./Skeleton.es.js";
|
|
4
|
+
const SkeletonAvatar = ({ size = "m", ...props }) => {
|
|
5
|
+
const theme = useTheme();
|
|
6
|
+
return /* @__PURE__ */ jsx(
|
|
7
|
+
Skeleton,
|
|
8
|
+
{
|
|
9
|
+
width: theme.control.height[size],
|
|
10
|
+
height: theme.control.height[size],
|
|
11
|
+
variant: "rounded",
|
|
12
|
+
...props
|
|
13
|
+
}
|
|
14
|
+
);
|
|
15
|
+
};
|
|
16
|
+
export {
|
|
17
|
+
SkeletonAvatar as default
|
|
18
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const theme = require("@quen-ui/theme");
|
|
4
|
+
const Skeleton = require("./Skeleton.cjs.js");
|
|
5
|
+
const SkeletonButton = ({
|
|
6
|
+
width = "100%",
|
|
7
|
+
size = "m",
|
|
8
|
+
...props
|
|
9
|
+
}) => {
|
|
10
|
+
const theme$1 = theme.useTheme();
|
|
11
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
12
|
+
Skeleton,
|
|
13
|
+
{
|
|
14
|
+
width,
|
|
15
|
+
height: theme$1.control.height[size],
|
|
16
|
+
variant: "rounded",
|
|
17
|
+
...props
|
|
18
|
+
}
|
|
19
|
+
);
|
|
20
|
+
};
|
|
21
|
+
module.exports = SkeletonButton;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useTheme } from "@quen-ui/theme";
|
|
3
|
+
import Skeleton from "./Skeleton.es.js";
|
|
4
|
+
const SkeletonButton = ({
|
|
5
|
+
width = "100%",
|
|
6
|
+
size = "m",
|
|
7
|
+
...props
|
|
8
|
+
}) => {
|
|
9
|
+
const theme = useTheme();
|
|
10
|
+
return /* @__PURE__ */ jsx(
|
|
11
|
+
Skeleton,
|
|
12
|
+
{
|
|
13
|
+
width,
|
|
14
|
+
height: theme.control.height[size],
|
|
15
|
+
variant: "rounded",
|
|
16
|
+
...props
|
|
17
|
+
}
|
|
18
|
+
);
|
|
19
|
+
};
|
|
20
|
+
export {
|
|
21
|
+
SkeletonButton as default
|
|
22
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const Skeleton = require("./Skeleton.cjs.js");
|
|
4
|
+
const SkeletonTextBlock = require("./SkeletonTextBlock.cjs.js");
|
|
5
|
+
const Flex = require("../Flex/Flex.cjs.js");
|
|
6
|
+
const SkeletonCard = ({ loading, children, ...props }) => {
|
|
7
|
+
if (!loading) {
|
|
8
|
+
return children;
|
|
9
|
+
}
|
|
10
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Flex, { direction: "column", gap: "m", children: [
|
|
11
|
+
/* @__PURE__ */ jsxRuntime.jsx(Skeleton, { width: "100%", height: 160, variant: "rounded", ...props, loading }),
|
|
12
|
+
/* @__PURE__ */ jsxRuntime.jsx(SkeletonTextBlock, { lines: 3, ...props, loading })
|
|
13
|
+
] });
|
|
14
|
+
};
|
|
15
|
+
module.exports = SkeletonCard;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ISkeletonProps } from './types';
|
|
2
|
+
declare const SkeletonCard: ({ loading, children, ...props }: Partial<ISkeletonProps>) => string | number | bigint | boolean | Iterable<import('react').ReactNode> | Promise<string | number | bigint | boolean | import('react').ReactPortal | import('react').ReactElement<unknown, string | import('react').JSXElementConstructor<any>> | Iterable<import('react').ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
3
|
+
export default SkeletonCard;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import Skeleton from "./Skeleton.es.js";
|
|
3
|
+
import SkeletonTextBlock from "./SkeletonTextBlock.es.js";
|
|
4
|
+
import Flex from "../Flex/Flex.es.js";
|
|
5
|
+
const SkeletonCard = ({ loading, children, ...props }) => {
|
|
6
|
+
if (!loading) {
|
|
7
|
+
return children;
|
|
8
|
+
}
|
|
9
|
+
return /* @__PURE__ */ jsxs(Flex, { direction: "column", gap: "m", children: [
|
|
10
|
+
/* @__PURE__ */ jsx(Skeleton, { width: "100%", height: 160, variant: "rounded", ...props, loading }),
|
|
11
|
+
/* @__PURE__ */ jsx(SkeletonTextBlock, { lines: 3, ...props, loading })
|
|
12
|
+
] });
|
|
13
|
+
};
|
|
14
|
+
export {
|
|
15
|
+
SkeletonCard as default
|
|
16
|
+
};
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const SkeletonAvatar = require("./SkeletonAvatar.cjs.js");
|
|
4
|
+
const SkeletonTextBlock = require("./SkeletonTextBlock.cjs.js");
|
|
5
|
+
const SkeletonButton = require("./SkeletonButton.cjs.js");
|
|
6
|
+
const Flex = require("../Flex/Flex.cjs.js");
|
|
7
|
+
const SkeletonLayout = ({
|
|
8
|
+
loading,
|
|
9
|
+
children,
|
|
10
|
+
schema,
|
|
11
|
+
direction,
|
|
12
|
+
gap = "m",
|
|
13
|
+
style,
|
|
14
|
+
className,
|
|
15
|
+
animation
|
|
16
|
+
}) => {
|
|
17
|
+
if (!loading) {
|
|
18
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children });
|
|
19
|
+
}
|
|
20
|
+
if (!schema) {
|
|
21
|
+
return null;
|
|
22
|
+
}
|
|
23
|
+
const layout = [];
|
|
24
|
+
if (schema.avatar) {
|
|
25
|
+
const size = typeof schema.avatar === "object" ? schema.avatar.size : "m";
|
|
26
|
+
layout.push(
|
|
27
|
+
/* @__PURE__ */ jsxRuntime.jsx(SkeletonAvatar, { size, animation }, "avatar")
|
|
28
|
+
);
|
|
29
|
+
}
|
|
30
|
+
if (schema.title) {
|
|
31
|
+
const lines = typeof schema.title === "number" ? schema.title : 1;
|
|
32
|
+
layout.push(
|
|
33
|
+
/* @__PURE__ */ jsxRuntime.jsx(SkeletonTextBlock, { lines, animation }, "title")
|
|
34
|
+
);
|
|
35
|
+
}
|
|
36
|
+
if (schema.text) {
|
|
37
|
+
layout.push(
|
|
38
|
+
/* @__PURE__ */ jsxRuntime.jsx(SkeletonTextBlock, { lines: schema.text, animation }, "text")
|
|
39
|
+
);
|
|
40
|
+
}
|
|
41
|
+
if (schema.button) {
|
|
42
|
+
const option = typeof schema.button === "object" ? schema.button : { width: "100%", size: "m" };
|
|
43
|
+
layout.push(
|
|
44
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
45
|
+
SkeletonButton,
|
|
46
|
+
{
|
|
47
|
+
width: option.width,
|
|
48
|
+
size: option.size,
|
|
49
|
+
animation
|
|
50
|
+
},
|
|
51
|
+
"button"
|
|
52
|
+
)
|
|
53
|
+
);
|
|
54
|
+
}
|
|
55
|
+
if (schema.custom) {
|
|
56
|
+
layout.push(schema.custom);
|
|
57
|
+
}
|
|
58
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Flex, { direction, gap, style, className, children: layout });
|
|
59
|
+
};
|
|
60
|
+
module.exports = SkeletonLayout;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
+
import SkeletonAvatar from "./SkeletonAvatar.es.js";
|
|
3
|
+
import SkeletonTextBlock from "./SkeletonTextBlock.es.js";
|
|
4
|
+
import SkeletonButton from "./SkeletonButton.es.js";
|
|
5
|
+
import Flex from "../Flex/Flex.es.js";
|
|
6
|
+
const SkeletonLayout = ({
|
|
7
|
+
loading,
|
|
8
|
+
children,
|
|
9
|
+
schema,
|
|
10
|
+
direction,
|
|
11
|
+
gap = "m",
|
|
12
|
+
style,
|
|
13
|
+
className,
|
|
14
|
+
animation
|
|
15
|
+
}) => {
|
|
16
|
+
if (!loading) {
|
|
17
|
+
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
18
|
+
}
|
|
19
|
+
if (!schema) {
|
|
20
|
+
return null;
|
|
21
|
+
}
|
|
22
|
+
const layout = [];
|
|
23
|
+
if (schema.avatar) {
|
|
24
|
+
const size = typeof schema.avatar === "object" ? schema.avatar.size : "m";
|
|
25
|
+
layout.push(
|
|
26
|
+
/* @__PURE__ */ jsx(SkeletonAvatar, { size, animation }, "avatar")
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
if (schema.title) {
|
|
30
|
+
const lines = typeof schema.title === "number" ? schema.title : 1;
|
|
31
|
+
layout.push(
|
|
32
|
+
/* @__PURE__ */ jsx(SkeletonTextBlock, { lines, animation }, "title")
|
|
33
|
+
);
|
|
34
|
+
}
|
|
35
|
+
if (schema.text) {
|
|
36
|
+
layout.push(
|
|
37
|
+
/* @__PURE__ */ jsx(SkeletonTextBlock, { lines: schema.text, animation }, "text")
|
|
38
|
+
);
|
|
39
|
+
}
|
|
40
|
+
if (schema.button) {
|
|
41
|
+
const option = typeof schema.button === "object" ? schema.button : { width: "100%", size: "m" };
|
|
42
|
+
layout.push(
|
|
43
|
+
/* @__PURE__ */ jsx(
|
|
44
|
+
SkeletonButton,
|
|
45
|
+
{
|
|
46
|
+
width: option.width,
|
|
47
|
+
size: option.size,
|
|
48
|
+
animation
|
|
49
|
+
},
|
|
50
|
+
"button"
|
|
51
|
+
)
|
|
52
|
+
);
|
|
53
|
+
}
|
|
54
|
+
if (schema.custom) {
|
|
55
|
+
layout.push(schema.custom);
|
|
56
|
+
}
|
|
57
|
+
return /* @__PURE__ */ jsx(Flex, { direction, gap, style, className, children: layout });
|
|
58
|
+
};
|
|
59
|
+
export {
|
|
60
|
+
SkeletonLayout as default
|
|
61
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const React = require("react");
|
|
4
|
+
const Flex = require("../Flex/Flex.cjs.js");
|
|
5
|
+
const SkeletonList = ({
|
|
6
|
+
gap = "m",
|
|
7
|
+
rowGap,
|
|
8
|
+
columnGap,
|
|
9
|
+
direction = "column",
|
|
10
|
+
count,
|
|
11
|
+
align,
|
|
12
|
+
justify,
|
|
13
|
+
wrap,
|
|
14
|
+
style,
|
|
15
|
+
className,
|
|
16
|
+
children,
|
|
17
|
+
loading,
|
|
18
|
+
skeleton
|
|
19
|
+
}) => {
|
|
20
|
+
if (!loading) {
|
|
21
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children });
|
|
22
|
+
}
|
|
23
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
24
|
+
Flex,
|
|
25
|
+
{
|
|
26
|
+
direction,
|
|
27
|
+
gap,
|
|
28
|
+
rowGap,
|
|
29
|
+
columnGap,
|
|
30
|
+
align,
|
|
31
|
+
justify,
|
|
32
|
+
wrap,
|
|
33
|
+
style,
|
|
34
|
+
className,
|
|
35
|
+
children: Array.from({ length: count }).map((_, i) => React.cloneElement(skeleton, { key: i }))
|
|
36
|
+
}
|
|
37
|
+
);
|
|
38
|
+
};
|
|
39
|
+
module.exports = SkeletonList;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { TSkeletonListProps } from './types';
|
|
2
|
+
declare const SkeletonList: ({ gap, rowGap, columnGap, direction, count, align, justify, wrap, style, className, children, loading, skeleton, }: TSkeletonListProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
export default SkeletonList;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { cloneElement } from "react";
|
|
3
|
+
import Flex from "../Flex/Flex.es.js";
|
|
4
|
+
const SkeletonList = ({
|
|
5
|
+
gap = "m",
|
|
6
|
+
rowGap,
|
|
7
|
+
columnGap,
|
|
8
|
+
direction = "column",
|
|
9
|
+
count,
|
|
10
|
+
align,
|
|
11
|
+
justify,
|
|
12
|
+
wrap,
|
|
13
|
+
style,
|
|
14
|
+
className,
|
|
15
|
+
children,
|
|
16
|
+
loading,
|
|
17
|
+
skeleton
|
|
18
|
+
}) => {
|
|
19
|
+
if (!loading) {
|
|
20
|
+
return /* @__PURE__ */ jsx(Fragment, { children });
|
|
21
|
+
}
|
|
22
|
+
return /* @__PURE__ */ jsx(
|
|
23
|
+
Flex,
|
|
24
|
+
{
|
|
25
|
+
direction,
|
|
26
|
+
gap,
|
|
27
|
+
rowGap,
|
|
28
|
+
columnGap,
|
|
29
|
+
align,
|
|
30
|
+
justify,
|
|
31
|
+
wrap,
|
|
32
|
+
style,
|
|
33
|
+
className,
|
|
34
|
+
children: Array.from({ length: count }).map((_, i) => cloneElement(skeleton, { key: i }))
|
|
35
|
+
}
|
|
36
|
+
);
|
|
37
|
+
};
|
|
38
|
+
export {
|
|
39
|
+
SkeletonList as default
|
|
40
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
3
|
+
const Skeleton = require("./Skeleton.cjs.js");
|
|
4
|
+
const SkeletonTextBlock = ({ lines = 3, ...rest }) => {
|
|
5
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Skeleton, { variant: "text", lines, ...rest });
|
|
6
|
+
};
|
|
7
|
+
module.exports = SkeletonTextBlock;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import Skeleton from "./Skeleton.es.js";
|
|
3
|
+
const SkeletonTextBlock = ({ lines = 3, ...rest }) => {
|
|
4
|
+
return /* @__PURE__ */ jsx(Skeleton, { variant: "text", lines, ...rest });
|
|
5
|
+
};
|
|
6
|
+
export {
|
|
7
|
+
SkeletonTextBlock as default
|
|
8
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const Skeleton$1 = require("./Skeleton.cjs.js");
|
|
4
|
+
const SkeletonAvatar = require("./SkeletonAvatar.cjs.js");
|
|
5
|
+
const SkeletonButton = require("./SkeletonButton.cjs.js");
|
|
6
|
+
const SkeletonCard = require("./SkeletonCard.cjs.js");
|
|
7
|
+
const SkeletonLayout = require("./SkeletonLayout.cjs.js");
|
|
8
|
+
const SkeletonList = require("./SkeletonList.cjs.js");
|
|
9
|
+
const SkeletonTextBlock = require("./SkeletonTextBlock.cjs.js");
|
|
10
|
+
const Skeleton = Skeleton$1;
|
|
11
|
+
Skeleton.Avatar = SkeletonAvatar;
|
|
12
|
+
Skeleton.Button = SkeletonButton;
|
|
13
|
+
Skeleton.Card = SkeletonCard;
|
|
14
|
+
Skeleton.List = SkeletonList;
|
|
15
|
+
Skeleton.TextBlock = SkeletonTextBlock;
|
|
16
|
+
Skeleton.Layout = SkeletonLayout;
|
|
17
|
+
exports.Skeleton = Skeleton;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { default as SkeletonComponent } from './Skeleton';
|
|
2
|
+
import { default as SkeletonAvatar } from './SkeletonAvatar';
|
|
3
|
+
import { default as SkeletonButton } from './SkeletonButton';
|
|
4
|
+
import { default as SkeletonCard } from './SkeletonCard';
|
|
5
|
+
import { default as SkeletonLayout } from './SkeletonLayout';
|
|
6
|
+
import { default as SkeletonList } from './SkeletonList';
|
|
7
|
+
import { default as SkeletonTextBlock } from './SkeletonTextBlock';
|
|
8
|
+
type TSkeleton = typeof SkeletonComponent & {
|
|
9
|
+
Avatar: typeof SkeletonAvatar;
|
|
10
|
+
Button: typeof SkeletonButton;
|
|
11
|
+
Card: typeof SkeletonCard;
|
|
12
|
+
List: typeof SkeletonList;
|
|
13
|
+
Layout: typeof SkeletonLayout;
|
|
14
|
+
TextBlock: typeof SkeletonTextBlock;
|
|
15
|
+
};
|
|
16
|
+
declare const Skeleton: TSkeleton;
|
|
17
|
+
export { Skeleton };
|
|
18
|
+
export type { ISkeletonProps, ISkeletonAvatarProps, ISkeletonLayoutProps, ISkeletonLayoutSchema, TSkeletonListProps, ISkeletonButtonProps } from './types';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import Skeleton$1 from "./Skeleton.es.js";
|
|
2
|
+
import SkeletonAvatar from "./SkeletonAvatar.es.js";
|
|
3
|
+
import SkeletonButton from "./SkeletonButton.es.js";
|
|
4
|
+
import SkeletonCard from "./SkeletonCard.es.js";
|
|
5
|
+
import SkeletonLayout from "./SkeletonLayout.es.js";
|
|
6
|
+
import SkeletonList from "./SkeletonList.es.js";
|
|
7
|
+
import SkeletonTextBlock from "./SkeletonTextBlock.es.js";
|
|
8
|
+
const Skeleton = Skeleton$1;
|
|
9
|
+
Skeleton.Avatar = SkeletonAvatar;
|
|
10
|
+
Skeleton.Button = SkeletonButton;
|
|
11
|
+
Skeleton.Card = SkeletonCard;
|
|
12
|
+
Skeleton.List = SkeletonList;
|
|
13
|
+
Skeleton.TextBlock = SkeletonTextBlock;
|
|
14
|
+
Skeleton.Layout = SkeletonLayout;
|
|
15
|
+
export {
|
|
16
|
+
Skeleton
|
|
17
|
+
};
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const styled = require("styled-components");
|
|
4
|
+
const polished = require("polished");
|
|
5
|
+
const pulse = styled.keyframes`
|
|
6
|
+
0% { opacity: 1; }
|
|
7
|
+
50% { opacity: 0.4; }
|
|
8
|
+
100% { opacity: 1; }
|
|
9
|
+
`;
|
|
10
|
+
const shimmer = styled.keyframes`
|
|
11
|
+
0% { background-position: 200% 0; }
|
|
12
|
+
100% { background-position: -200% 0; }
|
|
13
|
+
`;
|
|
14
|
+
const SkeletonStyled = styled.div.withConfig({
|
|
15
|
+
shouldForwardProp: (prop) => !["animation", "variant", "width", "height"].includes(prop)
|
|
16
|
+
})`
|
|
17
|
+
position: relative;
|
|
18
|
+
overflow: hidden;
|
|
19
|
+
background: ${({ theme }) => theme.components.Skeleton.background};
|
|
20
|
+
border-radius: 4px;
|
|
21
|
+
${({ width }) => width && styled.css`
|
|
22
|
+
width: ${typeof width === "number" ? `${width}px` : width};
|
|
23
|
+
`}
|
|
24
|
+
${({ height }) => height && styled.css`
|
|
25
|
+
height: ${typeof height === "number" ? `${height}px` : height};
|
|
26
|
+
`}
|
|
27
|
+
|
|
28
|
+
${({ variant }) => variant === "circle" && styled.css`
|
|
29
|
+
border-radius: 50%;
|
|
30
|
+
`};
|
|
31
|
+
|
|
32
|
+
${({ variant }) => variant === "text" && styled.css`
|
|
33
|
+
height: 1em;
|
|
34
|
+
border-radius: 4px;
|
|
35
|
+
`};
|
|
36
|
+
|
|
37
|
+
${({ variant }) => variant === "rounded" && styled.css`
|
|
38
|
+
border-radius: 12px;
|
|
39
|
+
`};
|
|
40
|
+
${({ animation }) => animation === "pulse" && styled.css`
|
|
41
|
+
animation: ${pulse} 1.5s ease-in-out infinite;
|
|
42
|
+
`};
|
|
43
|
+
|
|
44
|
+
${({ animation }) => animation === "shimmer" && styled.css`
|
|
45
|
+
background: ${({ theme }) => styled.css`linear-gradient(
|
|
46
|
+
90deg,
|
|
47
|
+
${theme.components.Skeleton.background} 0%,
|
|
48
|
+
${polished.rgba(theme.components.Skeleton.background, 0.3)} 50%,
|
|
49
|
+
${theme.components.Skeleton.background} 100%
|
|
50
|
+
)`};
|
|
51
|
+
background-size: 200% 100%;
|
|
52
|
+
animation: ${shimmer} 1.6s linear infinite;
|
|
53
|
+
`}
|
|
54
|
+
`;
|
|
55
|
+
const SkeletonLineStyled = styled(SkeletonStyled)`
|
|
56
|
+
height: 1em;
|
|
57
|
+
`;
|
|
58
|
+
exports.SkeletonLineStyled = SkeletonLineStyled;
|
|
59
|
+
exports.SkeletonStyled = SkeletonStyled;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ISkeletonProps } from './types';
|
|
2
|
+
export declare const SkeletonStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, Required<Pick<ISkeletonProps, "variant">> & ISkeletonProps>> & string;
|
|
3
|
+
export declare const SkeletonLineStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof ISkeletonProps> & Required<Pick<ISkeletonProps, "variant">> & ISkeletonProps, never>> & string;
|