@react-fabric/core 1.0.0-beta.6 → 1.0.0-beta.60
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/{src/components/actionLabel/ActionLabel.module.css → css/components/_actionLabel.css} +4 -4
- package/{src/overlays/alert/Alert.module.css → css/components/_alert.css} +3 -3
- package/{src/components/animations/Animations.module.css → css/components/_animations.css} +9 -9
- package/{src/components/avatar/Avatar.module.css → css/components/_avatar.css} +11 -11
- package/{src/components/badge/Badge.module.css → css/components/_badge.css} +19 -17
- package/{src/components/breadcrumbs/Breadcrumbs.module.css → css/components/_breadcrumbs.css} +52 -47
- package/{src/components/button/Button.module.css → css/components/_button.css} +77 -83
- package/{src/components/card/Card.module.css → css/components/_card.css} +54 -28
- package/{src/components/chip/Chip.module.css → css/components/_chip.css} +14 -10
- package/{src/components/collapsable/Collapsable.module.css → css/components/_collapsable.css} +3 -3
- package/css/components/_divider.css +38 -0
- package/{src/components/dropdown/Dropdown.module.css → css/components/_dropdown.css} +2 -2
- package/{src/overlays/flyout/Flyout.module.css → css/components/_flyout.css} +6 -6
- package/{src/components/icon/Icon.module.css → css/components/_icon.css} +11 -8
- package/{src/components/media/Media.module.css → css/components/_media.css} +17 -17
- package/{src/components/menu/Menu.module.css → css/components/_menu.css} +21 -20
- package/{src/overlays/message/Message.module.css → css/components/_message.css} +2 -2
- package/{src/components/meter/Meter.module.css → css/components/_meter.css} +10 -10
- package/{src/overlays/modal/Modal.module.css → css/components/_modal.css} +8 -8
- package/{src/components/panel/Panel.module.css → css/components/_panel.css} +17 -17
- package/{src/components/progress/Progress.module.css → css/components/_progress.css} +7 -10
- package/css/components/_stepper.css +86 -0
- package/{src/components/tabpanel/TabPanel.module.css → css/components/_tabPanel.css} +130 -85
- package/{src/overlays/toast/Toast.module.css → css/components/_toast.css} +2 -2
- package/css/components/_tooltip.css +29 -0
- package/{src/core/content/Content.module.css → css/components/index.css} +26 -18
- package/{src/core/aside/Aside.module.css → css/core/_aside.css} +60 -48
- package/{src/core/section/Section.module.css → css/core/_content.css} +5 -3
- package/{src/core/boundary/ErrorBoundary.module.css → css/core/_errorboundary.css} +9 -9
- package/{src/core/headfoot/HeadFoot.module.css → css/core/_headfoot.css} +4 -10
- package/{src/core/page/Page.module.css → css/core/_page.css} +10 -14
- package/{src/core/responsive/Responsive.module.css → css/core/_responsive.css} +10 -10
- package/css/core/_section.css +28 -0
- package/{src/core/theme/Theme.module.css → css/core/_theme.css} +3 -3
- package/{src/typography/Typography.module.css → css/core/_typography.css} +14 -12
- package/{src/core/viewport/Viewport.module.css → css/core/_viewport.css} +7 -3
- package/css/core/index.css +33 -0
- package/css/reset/_gradients.css +8 -8
- package/css/reset/_reset.css +56 -224
- package/css/reset/_text.css +14 -29
- package/css/reset/_theme.css +331 -52
- package/css/reset/index.css +4 -4
- package/css/styles.css +7 -6
- package/css/theme/_colors.css +320 -0
- package/css/theme/_utilities.css +541 -0
- package/css/theme/index.css +45 -0
- package/dist/cjs/components/actionLabel/ActionLabel.js +26 -8
- package/dist/cjs/components/animations/Animations.js +110 -23
- package/dist/cjs/components/avatar/Avatar.js +46 -13
- package/dist/cjs/components/avatar/AvatarGroup.js +22 -4
- package/dist/cjs/components/badge/Badge.js +36 -15
- package/dist/cjs/components/breadcrumbs/Breadcrumbs.js +40 -9
- package/dist/cjs/components/button/Button.js +50 -28
- package/dist/cjs/components/button/ButtonGroup.js +30 -3
- package/dist/cjs/components/button/ConfirmButton.js +28 -2
- package/dist/cjs/components/button/ToggleButtonGroup.js +41 -15
- package/dist/cjs/components/callout/Callout.js +44 -4
- package/dist/cjs/components/card/Card.js +60 -18
- package/dist/cjs/components/card/CardCover.js +36 -5
- package/dist/cjs/components/card/FlipContent.js +56 -0
- package/dist/cjs/components/chip/Chip.js +40 -20
- package/dist/cjs/components/collapsable/Collapsable.js +30 -5
- package/dist/cjs/components/divider/Divider.js +30 -7
- package/dist/cjs/components/dropdown/Dropdown.js +48 -9
- package/dist/cjs/components/dropdown/DropdownTool.js +1 -1
- package/dist/cjs/components/empty/EmptyContent.js +37 -7
- package/dist/cjs/components/icon/Icon.js +76 -13
- package/dist/cjs/components/media/Media.js +172 -75
- package/dist/cjs/components/menu/ContextMenu.js +19 -0
- package/dist/cjs/components/menu/Menu.js +76 -21
- package/dist/cjs/components/menu/MenuItem.js +54 -26
- package/dist/cjs/components/meter/Meter.js +26 -3
- package/dist/cjs/components/navigator/Navigator.js +48 -15
- package/dist/cjs/components/panel/Panel.js +53 -22
- package/dist/cjs/components/panel/PanelGroup.js +25 -2
- package/dist/cjs/components/panel/PanelStack.js +31 -2
- package/dist/cjs/components/progress/ProgressBar.js +31 -9
- package/dist/cjs/components/progress/ProgressCircle.js +29 -7
- package/dist/cjs/components/tabpanel/Tab.js +39 -15
- package/dist/cjs/components/tabpanel/TabPanel.js +56 -16
- package/dist/cjs/context/Global.js +28 -1
- package/dist/cjs/context/NotificationCenter.js +3 -3
- package/dist/cjs/core/aside/Aside.js +48 -22
- package/dist/cjs/core/boundary/ErrorBoundary.js +25 -8
- package/dist/cjs/core/boundary/ErrorIcon.js +1 -2
- package/dist/cjs/core/content/Content.js +7 -3
- package/dist/cjs/core/headfoot/HeadFoot.js +48 -22
- package/dist/cjs/core/page/Page.js +40 -39
- package/dist/cjs/core/responsive/Responsive.js +59 -6
- package/dist/cjs/core/section/Section.js +12 -29
- package/dist/cjs/core/theme/ThemeProvider.js +32 -10
- package/dist/cjs/core/viewport/Viewport.js +18 -2
- package/dist/cjs/hooks/useControlledValue.js +12 -0
- package/dist/cjs/hooks/useDebounce.js +14 -1
- package/dist/cjs/hooks/useEffectDebugger.js +54 -2
- package/dist/cjs/hooks/useIsDark.js +8 -0
- package/dist/cjs/hooks/useIsRtl.js +12 -0
- package/dist/cjs/hooks/useNavigator.js +6 -4
- package/dist/cjs/hooks/useOverlayService.js +24 -0
- package/dist/cjs/hooks/usePropToggle.js +16 -5
- package/dist/cjs/hooks/useResize.js +18 -0
- package/dist/cjs/hooks/useResizeObserver.js +20 -1
- package/dist/cjs/hooks/useStepper.js +75 -0
- package/dist/cjs/hooks/useStorage.js +39 -0
- package/dist/cjs/hotkeys/HotKeyLabel.js +1 -1
- package/dist/cjs/hotkeys/HotKeyWrapper.js +3 -1
- package/dist/cjs/index.js +11 -2
- package/dist/cjs/overlays/alert/Alert.js +23 -15
- package/dist/cjs/overlays/flyout/Flyout.js +48 -64
- package/dist/cjs/overlays/message/Message.js +8 -3
- package/dist/cjs/overlays/modal/Modal.js +17 -20
- package/dist/cjs/overlays/toast/Toast.js +20 -10
- package/dist/cjs/overlays/tooltip/Tooltip.js +24 -11
- package/dist/cjs/types/icons.js +17 -4
- package/dist/cjs/typography/Abbr.js +35 -7
- package/dist/cjs/typography/{Link.js → Anchor.js} +23 -5
- package/dist/cjs/typography/Mark.js +25 -5
- package/dist/cjs/typography/Text.js +30 -5
- package/dist/cjs/typography/Title.js +19 -4
- package/dist/cjs/utils/cloneElement.js +47 -0
- package/dist/cjs/utils/getColor.js +1 -18
- package/dist/esm/components/actionLabel/ActionLabel.js +26 -8
- package/dist/esm/components/animations/Animations.js +111 -24
- package/dist/esm/components/avatar/Avatar.js +46 -13
- package/dist/esm/components/avatar/AvatarGroup.js +22 -4
- package/dist/esm/components/badge/Badge.js +38 -17
- package/dist/esm/components/breadcrumbs/Breadcrumbs.js +40 -9
- package/dist/esm/components/button/Button.js +52 -30
- package/dist/esm/components/button/ButtonGroup.js +31 -4
- package/dist/esm/components/button/ConfirmButton.js +28 -2
- package/dist/esm/components/button/ToggleButtonGroup.js +42 -16
- package/dist/esm/components/callout/Callout.js +44 -4
- package/dist/esm/components/card/Card.js +61 -19
- package/dist/esm/components/card/CardCover.js +36 -5
- package/dist/esm/components/card/FlipContent.js +56 -0
- package/dist/esm/components/chip/Chip.js +42 -22
- package/dist/esm/components/collapsable/Collapsable.js +30 -5
- package/dist/esm/components/divider/Divider.js +31 -8
- package/dist/esm/components/dropdown/Dropdown.js +48 -9
- package/dist/esm/components/dropdown/DropdownTool.js +1 -1
- package/dist/esm/components/empty/EmptyContent.js +37 -7
- package/dist/esm/components/icon/Icon.js +78 -16
- package/dist/esm/components/media/Media.js +173 -76
- package/dist/esm/components/menu/ContextMenu.js +19 -0
- package/dist/esm/components/menu/Menu.js +78 -23
- package/dist/esm/components/menu/MenuItem.js +49 -21
- package/dist/esm/components/meter/Meter.js +26 -3
- package/dist/esm/components/navigator/Navigator.js +48 -15
- package/dist/esm/components/panel/Panel.js +54 -23
- package/dist/esm/components/panel/PanelGroup.js +25 -2
- package/dist/esm/components/panel/PanelStack.js +31 -2
- package/dist/esm/components/progress/ProgressBar.js +31 -9
- package/dist/esm/components/progress/ProgressCircle.js +29 -7
- package/dist/esm/components/tabpanel/Tab.js +40 -16
- package/dist/esm/components/tabpanel/TabPanel.js +56 -16
- package/dist/esm/context/Global.js +28 -1
- package/dist/esm/context/NotificationCenter.js +3 -3
- package/dist/esm/core/aside/Aside.js +49 -23
- package/dist/esm/core/boundary/ErrorBoundary.js +25 -8
- package/dist/esm/core/boundary/ErrorIcon.js +1 -2
- package/dist/esm/core/content/Content.js +7 -3
- package/dist/esm/core/headfoot/HeadFoot.js +48 -22
- package/dist/esm/core/page/Page.js +41 -40
- package/dist/esm/core/responsive/Responsive.js +59 -6
- package/dist/esm/core/section/Section.js +12 -29
- package/dist/esm/core/theme/ThemeProvider.js +32 -10
- package/dist/esm/core/viewport/Viewport.js +18 -2
- package/dist/esm/hooks/useControlledValue.js +12 -0
- package/dist/esm/hooks/useDebounce.js +14 -1
- package/dist/esm/hooks/useEffectDebugger.js +54 -2
- package/dist/esm/hooks/useIsDark.js +8 -0
- package/dist/esm/hooks/useIsRtl.js +12 -0
- package/dist/esm/hooks/useNavigator.js +7 -5
- package/dist/esm/hooks/useOverlayService.js +24 -0
- package/dist/esm/hooks/usePropToggle.js +16 -5
- package/dist/esm/hooks/useResize.js +18 -0
- package/dist/esm/hooks/useResizeObserver.js +20 -1
- package/dist/esm/hooks/useStepper.js +75 -0
- package/dist/esm/hooks/useStorage.js +39 -0
- package/dist/esm/hotkeys/HotKeyLabel.js +1 -1
- package/dist/esm/hotkeys/HotKeyWrapper.js +3 -1
- package/dist/esm/index.js +6 -2
- package/dist/esm/overlays/alert/Alert.js +24 -16
- package/dist/esm/overlays/flyout/Flyout.js +52 -68
- package/dist/esm/overlays/message/Message.js +9 -4
- package/dist/esm/overlays/modal/Modal.js +19 -22
- package/dist/esm/overlays/toast/Toast.js +21 -11
- package/dist/esm/overlays/tooltip/Tooltip.js +24 -11
- package/dist/esm/types/icons.js +17 -4
- package/dist/esm/typography/Abbr.js +35 -7
- package/dist/esm/typography/{Link.js → Anchor.js} +24 -6
- package/dist/esm/typography/Mark.js +25 -5
- package/dist/esm/typography/Text.js +31 -6
- package/dist/esm/typography/Title.js +20 -5
- package/dist/esm/utils/cloneElement.js +47 -0
- package/dist/esm/utils/getColor.js +2 -16
- package/dist/types/components/actionLabel/ActionLabel.d.ts +21 -2
- package/dist/types/components/animations/Animations.d.ts +84 -5
- package/dist/types/components/avatar/Avatar.d.ts +34 -6
- package/dist/types/components/avatar/AvatarGroup.d.ts +19 -1
- package/dist/types/components/badge/Badge.d.ts +37 -3
- package/dist/types/components/breadcrumbs/Breadcrumbs.d.ts +31 -2
- package/dist/types/components/button/Button.d.ts +39 -7
- package/dist/types/components/button/ButtonGroup.d.ts +28 -3
- package/dist/types/components/button/ConfirmButton.d.ts +23 -3
- package/dist/types/components/button/ToggleButtonGroup.d.ts +39 -11
- package/dist/types/components/callout/Callout.d.ts +29 -3
- package/dist/types/components/card/Card.d.ts +44 -4
- package/dist/types/components/card/CardCover.d.ts +25 -0
- package/dist/types/components/card/FlipContent.d.ts +28 -0
- package/dist/types/components/chip/Chip.d.ts +34 -5
- package/dist/types/components/collapsable/Collapsable.d.ts +28 -2
- package/dist/types/components/divider/Divider.d.ts +30 -7
- package/dist/types/components/dropdown/Dropdown.d.ts +40 -1
- package/dist/types/components/dropdown/DropdownTool.d.ts +25 -0
- package/dist/types/components/empty/EmptyContent.d.ts +32 -3
- package/dist/types/components/icon/Icon.d.ts +40 -8
- package/dist/types/components/index.d.ts +3 -2
- package/dist/types/components/media/Media.d.ts +54 -0
- package/dist/types/components/menu/ContextMenu.d.ts +19 -1
- package/dist/types/components/menu/Menu.d.ts +29 -0
- package/dist/types/components/menu/MenuItem.d.ts +22 -2
- package/dist/types/components/menu/types.d.ts +9 -3
- package/dist/types/components/meter/Meter.d.ts +24 -0
- package/dist/types/components/navigator/Navigator.d.ts +29 -4
- package/dist/types/components/panel/Panel.d.ts +43 -4
- package/dist/types/components/panel/PanelGroup.d.ts +24 -0
- package/dist/types/components/panel/PanelStack.d.ts +31 -0
- package/dist/types/components/progress/ProgressBar.d.ts +23 -3
- package/dist/types/components/progress/ProgressCircle.d.ts +22 -3
- package/dist/types/components/tabpanel/Tab.d.ts +38 -4
- package/dist/types/components/tabpanel/TabPanel.d.ts +51 -2
- package/dist/types/context/Global.d.ts +24 -1
- package/dist/types/core/aside/Aside.d.ts +45 -6
- package/dist/types/core/boundary/ErrorBoundary.d.ts +18 -2
- package/dist/types/core/content/Content.d.ts +6 -1
- package/dist/types/core/headfoot/HeadFoot.d.ts +41 -9
- package/dist/types/core/page/Page.d.ts +32 -4
- package/dist/types/core/responsive/Responsive.d.ts +58 -3
- package/dist/types/core/section/Section.d.ts +18 -3
- package/dist/types/core/theme/ThemeProvider.d.ts +25 -5
- package/dist/types/core/viewport/Viewport.d.ts +15 -1
- package/dist/types/hooks/useControlledValue.d.ts +13 -2
- package/dist/types/hooks/useDebounce.d.ts +12 -0
- package/dist/types/hooks/useEffectDebugger.d.ts +49 -0
- package/dist/types/hooks/useIsDark.d.ts +8 -0
- package/dist/types/hooks/useIsRtl.d.ts +12 -0
- package/dist/types/hooks/useNavigator.d.ts +18 -1
- package/dist/types/hooks/useOverlayService.d.ts +28 -9
- package/dist/types/hooks/usePropToggle.d.ts +16 -5
- package/dist/types/hooks/useResize.d.ts +19 -1
- package/dist/types/hooks/useResizeObserver.d.ts +20 -1
- package/dist/types/hooks/useStepper.d.ts +14 -0
- package/dist/types/hooks/useStorage.d.ts +38 -0
- package/dist/types/index.d.ts +4 -0
- package/dist/types/overlays/alert/Alert.d.ts +16 -5
- package/dist/types/overlays/flyout/Flyout.d.ts +9 -4
- package/dist/types/overlays/message/Message.d.ts +16 -5
- package/dist/types/overlays/modal/Modal.d.ts +13 -4
- package/dist/types/overlays/toast/Toast.d.ts +16 -5
- package/dist/types/overlays/tooltip/Tooltip.d.ts +2 -2
- package/dist/types/types/icons.d.ts +17 -3
- package/dist/types/types/index.d.ts +20 -22
- package/dist/types/typography/Abbr.d.ts +34 -4
- package/dist/types/typography/Anchor.d.ts +42 -0
- package/dist/types/typography/Copy.d.ts +15 -0
- package/dist/types/typography/Mark.d.ts +22 -4
- package/dist/types/typography/Text.d.ts +27 -1
- package/dist/types/typography/Title.d.ts +16 -1
- package/dist/types/typography/index.d.ts +1 -1
- package/dist/types/utils/cloneElement.d.ts +1 -0
- package/dist/types/utils/getColor.d.ts +1 -4
- package/dist/types/utils/index.d.ts +1 -0
- package/package.json +14 -16
- package/src/components/actionLabel/ActionLabel.tsx +26 -8
- package/src/components/animations/Animations.tsx +115 -36
- package/src/components/avatar/Avatar.tsx +51 -15
- package/src/components/avatar/AvatarGroup.tsx +23 -5
- package/src/components/badge/Badge.tsx +50 -22
- package/src/components/breadcrumbs/Breadcrumbs.tsx +43 -10
- package/src/components/button/Button.tsx +74 -42
- package/src/components/button/ButtonGroup.tsx +33 -7
- package/src/components/button/ConfirmButton.tsx +31 -3
- package/src/components/button/ToggleButtonGroup.tsx +74 -47
- package/src/components/callout/Callout.tsx +55 -12
- package/src/components/card/Card.tsx +84 -25
- package/src/components/card/CardCover.tsx +36 -6
- package/src/components/card/FlipContent.tsx +90 -0
- package/src/components/chip/Chip.tsx +53 -25
- package/src/components/collapsable/Collapsable.tsx +33 -8
- package/src/components/divider/Divider.tsx +42 -16
- package/src/components/dropdown/Dropdown.tsx +47 -12
- package/src/components/dropdown/DropdownTool.tsx +27 -2
- package/src/components/empty/EmptyContent.tsx +49 -8
- package/src/components/icon/Icon.tsx +96 -18
- package/src/components/index.ts +3 -2
- package/src/components/media/Media.tsx +193 -104
- package/src/components/menu/ContextMenu.tsx +19 -0
- package/src/components/menu/Menu.tsx +87 -30
- package/src/components/menu/MenuItem.tsx +44 -19
- package/src/components/menu/types.ts +9 -8
- package/src/components/meter/Meter.tsx +27 -4
- package/src/components/navigator/Navigator.tsx +58 -9
- package/src/components/panel/Panel.tsx +53 -21
- package/src/components/panel/PanelGroup.tsx +25 -2
- package/src/components/panel/PanelStack.tsx +33 -2
- package/src/components/progress/ProgressBar.tsx +33 -14
- package/src/components/progress/ProgressCircle.tsx +29 -13
- package/src/components/tabpanel/Tab.tsx +47 -24
- package/src/components/tabpanel/TabPanel.tsx +79 -13
- package/src/context/Global.tsx +28 -1
- package/src/context/NotificationCenter.tsx +3 -3
- package/src/core/aside/Aside.tsx +56 -34
- package/src/core/boundary/ErrorBoundary.tsx +26 -8
- package/src/core/boundary/ErrorIcon.tsx +1 -2
- package/src/core/content/Content.tsx +7 -3
- package/src/core/headfoot/HeadFoot.tsx +44 -37
- package/src/core/page/Page.tsx +42 -20
- package/src/core/responsive/Responsive.tsx +66 -8
- package/src/core/section/Section.tsx +26 -4
- package/src/core/theme/ThemeProvider.tsx +35 -14
- package/src/core/viewport/Viewport.tsx +16 -3
- package/src/hooks/useControlledValue.tsx +12 -0
- package/src/hooks/useDebounce.ts +13 -1
- package/src/hooks/useEffectDebugger.ts +50 -2
- package/src/hooks/useIsDark.ts +8 -0
- package/src/hooks/useIsRtl.ts +12 -0
- package/src/hooks/useNavigator.tsx +28 -5
- package/src/hooks/useOverlayService.tsx +33 -8
- package/src/hooks/usePropToggle.ts +16 -5
- package/src/hooks/useResize.ts +19 -1
- package/src/hooks/useResizeObserver.ts +32 -9
- package/src/hooks/useStepper.tsx +68 -0
- package/src/hooks/useStorage.ts +38 -0
- package/src/hotkeys/HotKeyLabel.tsx +1 -1
- package/src/hotkeys/HotKeyWrapper.tsx +3 -1
- package/src/index.ts +5 -0
- package/src/overlays/alert/Alert.tsx +50 -34
- package/src/overlays/flyout/Flyout.tsx +73 -97
- package/src/overlays/message/Message.tsx +28 -9
- package/src/overlays/modal/Modal.tsx +36 -30
- package/src/overlays/toast/Toast.tsx +42 -30
- package/src/overlays/tooltip/Tooltip.tsx +43 -18
- package/src/types/global.d.ts +8 -0
- package/src/types/icons.ts +32 -6
- package/src/types/index.ts +261 -45
- package/src/typography/Abbr.tsx +45 -11
- package/src/typography/{Link.tsx → Anchor.tsx} +26 -14
- package/src/typography/Copy.tsx +15 -0
- package/src/typography/Mark.tsx +25 -10
- package/src/typography/Text.tsx +31 -13
- package/src/typography/Title.tsx +18 -7
- package/src/typography/index.ts +1 -1
- package/src/{overlays/tooltip/Tooltip.module.css → utils/cloneElement.ts} +21 -27
- package/src/utils/getColor.ts +1 -17
- package/src/utils/index.ts +1 -0
- package/css/index.js +0 -250
- package/css/tailwind/colors.ts +0 -158
- package/dist/cjs/components/actionLabel/ActionLabel.module.css +0 -1
- package/dist/cjs/components/animations/Animations.module.css +0 -1
- package/dist/cjs/components/avatar/Avatar.module.css +0 -1
- package/dist/cjs/components/badge/Badge.module.css +0 -1
- package/dist/cjs/components/breadcrumbs/Breadcrumbs.module.css +0 -1
- package/dist/cjs/components/button/Button.module.css +0 -1
- package/dist/cjs/components/card/Card.module.css +0 -1
- package/dist/cjs/components/chip/Chip.module.css +0 -1
- package/dist/cjs/components/collapsable/Collapsable.module.css +0 -1
- package/dist/cjs/components/dropdown/Dropdown.module.css +0 -1
- package/dist/cjs/components/icon/Icon.module.css +0 -1
- package/dist/cjs/components/media/Media.module.css +0 -1
- package/dist/cjs/components/menu/Menu.module.css +0 -1
- package/dist/cjs/components/meter/Meter.module.css +0 -1
- package/dist/cjs/components/panel/Panel.module.css +0 -1
- package/dist/cjs/components/progress/Progress.module.css +0 -1
- package/dist/cjs/components/tabpanel/TabPanel.module.css +0 -1
- package/dist/cjs/core/aside/Aside.module.css +0 -1
- package/dist/cjs/core/boundary/ErrorBoundary.module.css +0 -1
- package/dist/cjs/core/content/Content.module.css +0 -1
- package/dist/cjs/core/headfoot/HeadFoot.module.css +0 -1
- package/dist/cjs/core/page/Page.module.css +0 -1
- package/dist/cjs/core/responsive/Responsive.module.css +0 -1
- package/dist/cjs/core/section/Section.module.css +0 -1
- package/dist/cjs/core/theme/Theme.module.css +0 -1
- package/dist/cjs/core/viewport/Viewport.module.css +0 -1
- package/dist/cjs/overlays/alert/Alert.module.css +0 -1
- package/dist/cjs/overlays/flyout/Flyout.module.css +0 -1
- package/dist/cjs/overlays/message/Message.module.css +0 -1
- package/dist/cjs/overlays/modal/Modal.module.css +0 -1
- package/dist/cjs/overlays/toast/Toast.module.css +0 -1
- package/dist/cjs/overlays/tooltip/Tooltip.module.css +0 -1
- package/dist/cjs/typography/Typography.module.css +0 -1
- package/dist/esm/components/actionLabel/ActionLabel.module.css +0 -1
- package/dist/esm/components/animations/Animations.module.css +0 -1
- package/dist/esm/components/avatar/Avatar.module.css +0 -1
- package/dist/esm/components/badge/Badge.module.css +0 -1
- package/dist/esm/components/breadcrumbs/Breadcrumbs.module.css +0 -1
- package/dist/esm/components/button/Button.module.css +0 -1
- package/dist/esm/components/card/Card.module.css +0 -1
- package/dist/esm/components/chip/Chip.module.css +0 -1
- package/dist/esm/components/collapsable/Collapsable.module.css +0 -1
- package/dist/esm/components/dropdown/Dropdown.module.css +0 -1
- package/dist/esm/components/icon/Icon.module.css +0 -1
- package/dist/esm/components/media/Media.module.css +0 -1
- package/dist/esm/components/menu/Menu.module.css +0 -1
- package/dist/esm/components/meter/Meter.module.css +0 -1
- package/dist/esm/components/panel/Panel.module.css +0 -1
- package/dist/esm/components/progress/Progress.module.css +0 -1
- package/dist/esm/components/tabpanel/TabPanel.module.css +0 -1
- package/dist/esm/core/aside/Aside.module.css +0 -1
- package/dist/esm/core/boundary/ErrorBoundary.module.css +0 -1
- package/dist/esm/core/content/Content.module.css +0 -1
- package/dist/esm/core/headfoot/HeadFoot.module.css +0 -1
- package/dist/esm/core/page/Page.module.css +0 -1
- package/dist/esm/core/responsive/Responsive.module.css +0 -1
- package/dist/esm/core/section/Section.module.css +0 -1
- package/dist/esm/core/theme/Theme.module.css +0 -1
- package/dist/esm/core/viewport/Viewport.module.css +0 -1
- package/dist/esm/overlays/alert/Alert.module.css +0 -1
- package/dist/esm/overlays/flyout/Flyout.module.css +0 -1
- package/dist/esm/overlays/message/Message.module.css +0 -1
- package/dist/esm/overlays/modal/Modal.module.css +0 -1
- package/dist/esm/overlays/toast/Toast.module.css +0 -1
- package/dist/esm/overlays/tooltip/Tooltip.module.css +0 -1
- package/dist/esm/typography/Typography.module.css +0 -1
- package/dist/types/typography/Link.d.ts +0 -25
|
@@ -45,13 +45,14 @@ import {
|
|
|
45
45
|
useMemo,
|
|
46
46
|
useRef,
|
|
47
47
|
useState,
|
|
48
|
+
type MouseEvent,
|
|
48
49
|
type ReactElement,
|
|
49
50
|
} from "react";
|
|
50
51
|
import { Icon } from "../../components/icon/Icon";
|
|
51
52
|
import { useIsRtl } from "../../hooks/useIsRtl";
|
|
52
53
|
import { type RefProp, type TooltipType } from "../../types";
|
|
53
54
|
import { CoreIcons } from "../../types/icons";
|
|
54
|
-
import
|
|
55
|
+
import { getColor } from "../../utils";
|
|
55
56
|
|
|
56
57
|
export interface TooltipProps extends TooltipType, RefProp {
|
|
57
58
|
/**
|
|
@@ -63,7 +64,7 @@ export interface TooltipProps extends TooltipType, RefProp {
|
|
|
63
64
|
*/
|
|
64
65
|
copyContent?: boolean | string;
|
|
65
66
|
disabled?: boolean;
|
|
66
|
-
children: ReactElement
|
|
67
|
+
children: ReactElement<KeyValue>;
|
|
67
68
|
}
|
|
68
69
|
|
|
69
70
|
export const getTooltipProps = (
|
|
@@ -82,6 +83,7 @@ export const Tooltip = ({
|
|
|
82
83
|
ref,
|
|
83
84
|
children,
|
|
84
85
|
color,
|
|
86
|
+
textColor,
|
|
85
87
|
content,
|
|
86
88
|
open,
|
|
87
89
|
copyContent,
|
|
@@ -125,7 +127,7 @@ export const Tooltip = ({
|
|
|
125
127
|
});
|
|
126
128
|
|
|
127
129
|
const hover = useHover(context, {
|
|
128
|
-
restMs:
|
|
130
|
+
restMs: 500,
|
|
129
131
|
delay: { open: 1000 },
|
|
130
132
|
handleClose: copyContent ? safePolygon({ buffer: 1 }) : undefined,
|
|
131
133
|
});
|
|
@@ -146,14 +148,15 @@ export const Tooltip = ({
|
|
|
146
148
|
const copyEl = useMemo(() => {
|
|
147
149
|
if (copyContent) {
|
|
148
150
|
const copyText: AnyObject = isString(copyContent) ? copyContent : content;
|
|
149
|
-
const handler = () => {
|
|
151
|
+
const handler = (e: MouseEvent) => {
|
|
150
152
|
setIsOpen(false);
|
|
153
|
+
e.stopPropagation();
|
|
151
154
|
void navigator.clipboard.writeText(copyText.toString());
|
|
152
155
|
};
|
|
153
156
|
return (
|
|
154
157
|
<span
|
|
155
158
|
role="none"
|
|
156
|
-
className="ms-2 cursor-pointer text-
|
|
159
|
+
className="ms-2 cursor-pointer text-dimmed flex-content opacity-75 hover:opacity-90 active:opacity-60"
|
|
157
160
|
onClick={handler}
|
|
158
161
|
>
|
|
159
162
|
<Icon icon={CoreIcons.copy} />
|
|
@@ -173,25 +176,47 @@ export const Tooltip = ({
|
|
|
173
176
|
<FloatingPortal>
|
|
174
177
|
<dfn
|
|
175
178
|
data-ref="tooltip"
|
|
176
|
-
data-color={color}
|
|
177
179
|
className={classNames(
|
|
178
|
-
|
|
179
|
-
"select-none text-sm not-italic flex py-1 px-2 rounded shadow-md bg-
|
|
180
|
+
"fabric-tooltip z-(--z-tooltip)",
|
|
181
|
+
"select-none text-sm not-italic flex py-1 px-2 max-w-lg! rounded shadow-md bg-muted",
|
|
180
182
|
)}
|
|
181
183
|
ref={refs.setFloating}
|
|
182
|
-
style={
|
|
184
|
+
style={{
|
|
185
|
+
color: textColor ? getColor(textColor) : undefined,
|
|
186
|
+
backgroundColor: color ? getColor(color) : undefined,
|
|
187
|
+
...floatingStyles,
|
|
188
|
+
}}
|
|
183
189
|
{...getFloatingProps()}
|
|
184
190
|
>
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
191
|
+
{isValidElement(content) && content}
|
|
192
|
+
{isString(content) && (
|
|
193
|
+
<span
|
|
194
|
+
className={classNames(
|
|
195
|
+
"font-medium flex-1 break-all whitespace-pre-wrap mixed-lang",
|
|
196
|
+
!textColor && "contrast",
|
|
197
|
+
)}
|
|
198
|
+
style={{
|
|
199
|
+
color: textColor
|
|
200
|
+
? undefined
|
|
201
|
+
: color
|
|
202
|
+
? getColor(color)
|
|
203
|
+
: "var(--bg-color-muted)",
|
|
204
|
+
}}
|
|
205
|
+
>
|
|
206
|
+
{content}
|
|
207
|
+
</span>
|
|
208
|
+
)}
|
|
193
209
|
{copyEl}
|
|
194
|
-
<FloatingArrow
|
|
210
|
+
<FloatingArrow
|
|
211
|
+
ref={arrowRef}
|
|
212
|
+
context={context}
|
|
213
|
+
strokeWidth={0.5}
|
|
214
|
+
className="fill-muted stroke-dimmed"
|
|
215
|
+
style={{
|
|
216
|
+
stroke: color ? getColor(color) : undefined,
|
|
217
|
+
fill: color ? getColor(color) : undefined,
|
|
218
|
+
}}
|
|
219
|
+
/>
|
|
195
220
|
</dfn>
|
|
196
221
|
</FloatingPortal>
|
|
197
222
|
)}
|
package/src/types/global.d.ts
CHANGED
|
@@ -45,6 +45,14 @@ declare module "*.png" {
|
|
|
45
45
|
const content: any;
|
|
46
46
|
export default content;
|
|
47
47
|
}
|
|
48
|
+
declare module "*.jpg" {
|
|
49
|
+
const content: any;
|
|
50
|
+
export default content;
|
|
51
|
+
}
|
|
52
|
+
declare module "*.jpeg" {
|
|
53
|
+
const content: any;
|
|
54
|
+
export default content;
|
|
55
|
+
}
|
|
48
56
|
declare module "*.svg" {
|
|
49
57
|
const content: any;
|
|
50
58
|
export default content;
|
package/src/types/icons.ts
CHANGED
|
@@ -22,9 +22,13 @@
|
|
|
22
22
|
*/
|
|
23
23
|
|
|
24
24
|
/* istanbul ignore file */
|
|
25
|
-
|
|
25
|
+
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
/**
|
|
28
|
+
* Core icons used in the application.
|
|
29
|
+
* These icons are typically used for navigation, actions, and other UI elements.
|
|
30
|
+
*/
|
|
31
|
+
export namespace CoreIcons {
|
|
28
32
|
/**
|
|
29
33
|
* carets
|
|
30
34
|
*/
|
|
@@ -100,6 +104,11 @@ export module CoreIcons {
|
|
|
100
104
|
export const colapseAll =
|
|
101
105
|
"M18.707 21.293l-6-6c-0.391-0.391-1.024-0.391-1.414 0l-6 6c-0.391 0.391-0.391 1.024 0 1.414s1.024 0.391 1.414 0l5.293-5.293 5.293 5.293c0.391 0.391 1.024 0.391 1.414 0s0.391-1.024 0-1.414zM5.293 2.707l6 6c0.391 0.391 1.024 0.391 1.414 0l6-6c0.391-0.391 0.391-1.024 0-1.414s-1.024-0.391-1.414 0l-5.293 5.293-5.293-5.293c-0.391-0.391-1.024-0.391-1.414 0s-0.391 1.024 0 1.414z";
|
|
102
106
|
|
|
107
|
+
export const expandAllVar =
|
|
108
|
+
"M13,9V15H16L12,19L8,15H11V9H8L12,5L16,9H13M4,2H20V4H4V2M4,20H20V22H4V20Z";
|
|
109
|
+
export const colapseAllVar =
|
|
110
|
+
"M4,12H20V14H4V12M4,9H20V11H4V9M16,4L12,8L8,4H11V1H13V4H16M8,19L12,15L16,19H13V22H11V19H8Z";
|
|
111
|
+
|
|
103
112
|
export const folderClosed =
|
|
104
113
|
"M20,18H4V8H20M20,6H12L10,4H4C2.89,4 2,4.89 2,6V18A2,2 0 0,0 4,20H20A2,2 0 0,0 22,18V8C22,6.89 21.1,6 20,6Z";
|
|
105
114
|
export const folderOpen =
|
|
@@ -119,11 +128,13 @@ export module CoreIcons {
|
|
|
119
128
|
"M19.547 14.667c-0.736 2.083-2.245 3.67-4.094 4.553s-4.031 1.061-6.114 0.325-3.67-2.245-4.553-4.094-1.061-4.031-0.325-6.114 2.245-3.67 4.094-4.553 4.031-1.061 6.114-0.325c1.188 0.42 2.209 1.088 2.987 1.882l2.824 2.659h-3.48c-0.552 0-1 0.448-1 1s0.448 1 1 1h5.997c0.004 0 0.009 0 0.013 0 0.137-0.001 0.267-0.030 0.386-0.082 0.119-0.051 0.229-0.126 0.324-0.225 0.012-0.012 0.023-0.025 0.034-0.038 0.076-0.087 0.134-0.184 0.175-0.287s0.065-0.213 0.069-0.328c0.002-0.014 0.002-0.028 0.002-0.042v-5.998c0-0.552-0.448-1-1-1s-1 0.448-1 1v3.685l-2.916-2.745c-0.993-1.012-2.274-1.846-3.748-2.366-2.604-0.921-5.336-0.698-7.644 0.405s-4.197 3.088-5.117 5.692-0.696 5.335 0.406 7.643 3.088 4.197 5.692 5.117 5.335 0.697 7.643-0.406 4.197-3.088 5.117-5.692c0.184-0.521-0.089-1.092-0.61-1.276s-1.092 0.089-1.276 0.61z";
|
|
120
129
|
export const search =
|
|
121
130
|
"M16.041 15.856c-0.034 0.026-0.067 0.055-0.099 0.087s-0.060 0.064-0.087 0.099c-1.258 1.213-2.969 1.958-4.855 1.958-1.933 0-3.682-0.782-4.95-2.050s-2.050-3.017-2.050-4.95 0.782-3.682 2.050-4.95 3.017-2.050 4.95-2.050 3.682 0.782 4.95 2.050 2.050 3.017 2.050 4.95c0 1.886-0.745 3.597-1.959 4.856zM21.707 20.293l-3.675-3.675c1.231-1.54 1.968-3.493 1.968-5.618 0-2.485-1.008-4.736-2.636-6.364s-3.879-2.636-6.364-2.636-4.736 1.008-6.364 2.636-2.636 3.879-2.636 6.364 1.008 4.736 2.636 6.364 3.879 2.636 6.364 2.636c2.125 0 4.078-0.737 5.618-1.968l3.675 3.675c0.391 0.391 1.024 0.391 1.414 0s0.391-1.024 0-1.414z";
|
|
131
|
+
export const ellipsis =
|
|
132
|
+
"M14 12c0-0.552-0.225-1.053-0.586-1.414s-0.862-0.586-1.414-0.586-1.053 0.225-1.414 0.586-0.586 0.862-0.586 1.414 0.225 1.053 0.586 1.414 0.862 0.586 1.414 0.586 1.053-0.225 1.414-0.586 0.586-0.862 0.586-1.414zM14 5c0-0.552-0.225-1.053-0.586-1.414s-0.862-0.586-1.414-0.586-1.053 0.225-1.414 0.586-0.586 0.862-0.586 1.414 0.225 1.053 0.586 1.414 0.862 0.586 1.414 0.586 1.053-0.225 1.414-0.586 0.586-0.862 0.586-1.414zM14 19c0-0.552-0.225-1.053-0.586-1.414s-0.862-0.586-1.414-0.586-1.053 0.225-1.414 0.586-0.586 0.862-0.586 1.414 0.225 1.053 0.586 1.414 0.862 0.586 1.414 0.586 1.053-0.225 1.414-0.586 0.586-0.862 0.586-1.414z";
|
|
122
133
|
export const filter = "M6,13H18V11H6M3,6V8H21V6M10,18H14V16H10V18Z";
|
|
123
134
|
export const funnel =
|
|
124
135
|
"M19.845 4l-6.609 7.814c-0.147 0.173-0.236 0.399-0.236 0.646v6.922l-2-1v-5.922c0.001-0.227-0.077-0.457-0.236-0.646l-6.609-7.814zM22 2h-20c-0.552 0-1 0.448-1 1 0 0.247 0.089 0.473 0.236 0.646l7.764 9.18v6.174c0 0.389 0.222 0.727 0.553 0.894l4 2c0.494 0.247 1.095 0.047 1.342-0.447 0.072-0.146 0.106-0.301 0.105-0.447v-8.174l7.764-9.18c0.357-0.422 0.304-1.053-0.118-1.409-0.189-0.16-0.419-0.238-0.646-0.237z";
|
|
125
|
-
export const
|
|
126
|
-
"M14
|
|
136
|
+
export const funnelFull =
|
|
137
|
+
"M14,12V19.88C14.04,20.18 13.94,20.5 13.71,20.71C13.32,21.1 12.69,21.1 12.3,20.71L10.29,18.7C10.06,18.47 9.96,18.16 10,17.87V12H9.97L4.21,4.62C3.87,4.19 3.95,3.56 4.38,3.22C4.57,3.08 4.78,3 5,3V3H19V3C19.22,3 19.43,3.08 19.62,3.22C20.05,3.56 20.13,4.19 19.79,4.62L14.03,12H14Z";
|
|
127
138
|
export const funnelPlus =
|
|
128
139
|
"M15 17H18V14H20V17H23V19H20V22H18V19H15V17M13 19.88C13.04 20.18 12.94 20.5 12.72 20.71C12.32 21.1 11.69 21.1 11.3 20.71L7.29 16.7C7.06 16.47 6.96 16.16 7 15.87V10.75L2.21 4.62C1.87 4.19 1.95 3.56 2.38 3.22C2.57 3.08 2.78 3 3 3V3H17V3C17.22 3 17.43 3.08 17.62 3.22C18.05 3.56 18.13 4.19 17.79 4.62L13 10.75V19.88M5.04 5L9 10.07V15.58L11 17.58V10.05L14.96 5H5.04Z";
|
|
129
140
|
export const funnelRemove =
|
|
@@ -249,6 +260,7 @@ export module CoreIcons {
|
|
|
249
260
|
"M5.541 2.159c-0.153-0.1-0.34-0.159-0.541-0.159-0.552 0-1 0.448-1 1v18c-0.001 0.182 0.050 0.372 0.159 0.541 0.299 0.465 0.917 0.599 1.382 0.3l14-9c0.114-0.072 0.219-0.174 0.3-0.3 0.299-0.465 0.164-1.083-0.3-1.382zM6 4.832l11.151 7.168-11.151 7.168z";
|
|
250
261
|
export const pause =
|
|
251
262
|
"M6 3c-0.552 0-1 0.448-1 1v16c0 0.552 0.448 1 1 1h4c0.552 0 1-0.448 1-1v-16c0-0.552-0.448-1-1-1zM7 5h2v14h-2zM14 3c-0.552 0-1 0.448-1 1v16c0 0.552 0.448 1 1 1h4c0.552 0 1-0.448 1-1v-16c0-0.552-0.448-1-1-1zM15 5h2v14h-2z";
|
|
263
|
+
export const stop = "M18,18H6V6H18V18Z";
|
|
252
264
|
export const volumeOn =
|
|
253
265
|
"M10 7.081v9.839l-3.375-2.7c-0.17-0.137-0.388-0.22-0.625-0.22h-3v-4h3c0.218 0.001 0.439-0.071 0.625-0.219zM10.375 4.219l-4.726 3.781h-3.649c-0.552 0-1 0.448-1 1v6c0 0.552 0.448 1 1 1h3.649l4.726 3.781c0.431 0.345 1.061 0.275 1.406-0.156 0.148-0.185 0.22-0.407 0.219-0.625v-14c0-0.552-0.448-1-1-1-0.237 0-0.455 0.083-0.625 0.219zM18.363 5.637c1.757 1.758 2.635 4.059 2.635 6.364 0 2.304-0.878 4.605-2.635 6.362-0.39 0.391-0.39 1.024 0 1.414s1.024 0.39 1.414 0c2.147-2.147 3.22-4.963 3.221-7.776s-1.074-5.63-3.221-7.778c-0.39-0.391-1.024-0.391-1.414 0s-0.391 1.024 0 1.414zM14.833 9.167c0.781 0.781 1.171 1.803 1.171 2.828s-0.39 2.047-1.171 2.828c-0.39 0.391-0.39 1.024 0 1.414s1.024 0.39 1.414 0c1.171-1.171 1.757-2.708 1.757-4.242s-0.586-3.071-1.757-4.242c-0.39-0.391-1.024-0.391-1.414 0s-0.391 1.024 0 1.414z";
|
|
254
266
|
export const volumeOff =
|
|
@@ -348,6 +360,9 @@ export module CoreIcons {
|
|
|
348
360
|
export const colorPicker =
|
|
349
361
|
"M19.35,11.72L17.22,13.85L15.81,12.43L8.1,20.14L3.5,22L2,20.5L3.86,15.9L11.57,8.19L10.15,6.78L12.28,4.65L19.35,11.72M16.76,3C17.93,1.83 19.83,1.83 21,3C22.17,4.17 22.17,6.07 21,7.24L19.08,9.16L14.84,4.92L16.76,3M5.56,17.03L4.5,19.5L6.97,18.44L14.4,11L13,9.6L5.56,17.03Z";
|
|
350
362
|
|
|
363
|
+
export const list =
|
|
364
|
+
"M11 15H17V17H11V15M9 7H7V9H9V7M11 13H17V11H11V13M11 9H17V7H11V9M9 11H7V13H9V11M21 5V19C21 20.1 20.1 21 19 21H5C3.9 21 3 20.1 3 19V5C3 3.9 3.9 3 5 3H19C20.1 3 21 3.9 21 5M19 5H5V19H19V5M9 15H7V17H9V15Z";
|
|
365
|
+
|
|
351
366
|
/**
|
|
352
367
|
* alert icons
|
|
353
368
|
*/
|
|
@@ -382,7 +397,7 @@ export module CoreIcons {
|
|
|
382
397
|
export const mediaOrient =
|
|
383
398
|
"M7.34,6.41L0.86,12.9L7.35,19.38L13.84,12.9L7.34,6.41M3.69,12.9L7.35,9.24L11,12.9L7.34,16.56L3.69,12.9M19.36,6.64C17.61,4.88 15.3,4 13,4V0.76L8.76,5L13,9.24V6C14.79,6 16.58,6.68 17.95,8.05C20.68,10.78 20.68,15.22 17.95,17.95C16.58,19.32 14.79,20 13,20C12.03,20 11.06,19.79 10.16,19.39L8.67,20.88C10,21.62 11.5,22 13,22C15.3,22 17.61,21.12 19.36,19.36C22.88,15.85 22.88,10.15 19.36,6.64Z";
|
|
384
399
|
export const mediaCrop =
|
|
385
|
-
"
|
|
400
|
+
"M13,17H17V13H19V17H23V19H19V23H17V19H13V17M11,17V19H9V17H11M7,17V19H5V17H7M19,9V11H17V9H19M19,5V7H17V5H19M15,5V7H13V5H15M11,5V7H9V5H11M7,5V7H5V5H7M7,13V15H5V13H7M7,9V11H5V9H7Z";
|
|
386
401
|
export const mediaImage =
|
|
387
402
|
"M19,19H5V5H19M19,3H5A2,2 0 0,0 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5A2,2 0 0,0 19,3M13.96,12.29L11.21,15.83L9.25,13.47L6.5,17H17.5L13.96,12.29Z";
|
|
388
403
|
export const mediaVideo =
|
|
@@ -402,7 +417,7 @@ export module CoreIcons {
|
|
|
402
417
|
export const mediaPlay = "M8,5.14V19.14L19,12.14L8,5.14Z";
|
|
403
418
|
export const mediaPause = "M14,19H18V5H14M6,19H10V5H6V19Z";
|
|
404
419
|
export const mediaContrast =
|
|
405
|
-
"M12
|
|
420
|
+
"M12,20C9.79,20 7.79,19.1 6.34,17.66L17.66,6.34C19.1,7.79 20,9.79 20,12A8,8 0 0,1 12,20M6,8H8V6H9.5V8H11.5V9.5H9.5V11.5H8V9.5H6M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,16H17V14.5H12V16Z";
|
|
406
421
|
export const mediaEqs =
|
|
407
422
|
"M7 3H5V9H7V3M19 3H17V13H19V3M3 13H5V21H7V13H9V11H3V13M15 7H13V3H11V7H9V9H15V7M11 21H13V11H11V21M15 15V17H17V21H19V17H21V15H15Z";
|
|
408
423
|
export const mediaCaptionOff =
|
|
@@ -422,4 +437,15 @@ export module CoreIcons {
|
|
|
422
437
|
"M9,22A1,1 0 0,1 8,21V18H4A2,2 0 0,1 2,16V4C2,2.89 2.9,2 4,2H20A2,2 0 0,1 22,4V16A2,2 0 0,1 20,18H13.9L10.2,21.71C10,21.9 9.75,22 9.5,22V22H9M10,16V19.08L13.08,16H20V4H4V16H10M6,7H18V9H6V7M6,11H15V13H6V11Z";
|
|
423
438
|
export const mediaCommentAdd =
|
|
424
439
|
"M9,22A1,1 0 0,1 8,21V18H4A2,2 0 0,1 2,16V4C2,2.89 2.9,2 4,2H20A2,2 0 0,1 22,4V16A2,2 0 0,1 20,18H13.9L10.2,21.71C10,21.9 9.75,22 9.5,22V22H9M10,16V19.08L13.08,16H20V4H4V16H10M11,6H13V9H16V11H13V14H11V11H8V9H11V6Z";
|
|
440
|
+
export const mediaCapture =
|
|
441
|
+
"M12,10L11.06,12.06L9,13L11.06,13.94L12,16L12.94,13.94L15,13L12.94,12.06L12,10M20,5H16.83L15,3H9L7.17,5H4A2,2 0 0,0 2,7V19A2,2 0 0,0 4,21H20A2,2 0 0,0 22,19V7A2,2 0 0,0 20,5M20,19H4V7H8.05L8.64,6.35L9.88,5H14.12L15.36,6.35L15.95,7H20V19M12,8A5,5 0 0,0 7,13A5,5 0 0,0 12,18A5,5 0 0,0 17,13A5,5 0 0,0 12,8M12,16A3,3 0 0,1 9,13A3,3 0 0,1 12,10A3,3 0 0,1 15,13A3,3 0 0,1 12,16Z";
|
|
442
|
+
|
|
443
|
+
export const mediaLightness =
|
|
444
|
+
"M12,18A6,6 0 0,1 6,12A6,6 0 0,1 12,6A6,6 0 0,1 18,12A6,6 0 0,1 12,18M20,15.31L23.31,12L20,8.69V4H15.31L12,0.69L8.69,4H4V8.69L0.69,12L4,15.31V20H8.69L12,23.31L15.31,20H20V15.31Z";
|
|
445
|
+
export const mediaColor =
|
|
446
|
+
"M19,11.5C19,11.5 17,13.67 17,15A2,2 0 0,0 19,17A2,2 0 0,0 21,15C21,13.67 19,11.5 19,11.5M5.21,10L10,5.21L14.79,10M16.56,8.94L7.62,0L6.21,1.41L8.59,3.79L3.44,8.94C2.85,9.5 2.85,10.47 3.44,11.06L8.94,16.56C9.23,16.85 9.62,17 10,17C10.38,17 10.77,16.85 11.06,16.56L16.56,11.06C17.15,10.47 17.15,9.5 16.56,8.94Z";
|
|
447
|
+
export const mediaInvert =
|
|
448
|
+
"M12,19.58V19.58C10.4,19.58 8.89,18.96 7.76,17.83C6.62,16.69 6,15.19 6,13.58C6,12 6.62,10.47 7.76,9.34L12,5.1M17.66,7.93L12,2.27V2.27L6.34,7.93C3.22,11.05 3.22,16.12 6.34,19.24C7.9,20.8 9.95,21.58 12,21.58C14.05,21.58 16.1,20.8 17.66,19.24C20.78,16.12 20.78,11.05 17.66,7.93Z";
|
|
449
|
+
export const mediaSaturate =
|
|
450
|
+
"M12 2A10 10 0 0 0 2 12A10 10 0 0 0 12 22A10 10 0 0 0 22 12A10 10 0 0 0 12 2M12 4A8 8 0 0 1 20 12A8 8 0 0 1 12 20V4Z";
|
|
425
451
|
}
|
package/src/types/index.ts
CHANGED
|
@@ -25,11 +25,15 @@
|
|
|
25
25
|
import { type Placement } from "@floating-ui/react";
|
|
26
26
|
import { type JSXElementConstructor, type Ref } from "react";
|
|
27
27
|
|
|
28
|
+
export type ModalProps<P = unknown> = P & {
|
|
29
|
+
onClose: (...args: AnyObject) => void;
|
|
30
|
+
};
|
|
31
|
+
|
|
28
32
|
export type SizeType = "xs" | "sm" | "md" | "lg" | "xl";
|
|
29
33
|
|
|
30
34
|
export type SizeTypeWithZero = "xs" | "sm" | "md" | "lg" | "xl" | 0;
|
|
31
35
|
|
|
32
|
-
export type
|
|
36
|
+
export type ColorState =
|
|
33
37
|
| "primary"
|
|
34
38
|
| "accent"
|
|
35
39
|
| "info"
|
|
@@ -37,21 +41,240 @@ export type ColorType =
|
|
|
37
41
|
| "success"
|
|
38
42
|
| "warning";
|
|
39
43
|
|
|
44
|
+
export type ColorType =
|
|
45
|
+
| "primary-50"
|
|
46
|
+
| "primary-100"
|
|
47
|
+
| "primary-200"
|
|
48
|
+
| "primary-300"
|
|
49
|
+
| "primary-400"
|
|
50
|
+
| "primary-500"
|
|
51
|
+
| "primary-600"
|
|
52
|
+
| "primary-700"
|
|
53
|
+
| "primary-800"
|
|
54
|
+
| "primary-900"
|
|
55
|
+
| "primary-950"
|
|
56
|
+
| "accent-50"
|
|
57
|
+
| "accent-100"
|
|
58
|
+
| "accent-200"
|
|
59
|
+
| "accent-300"
|
|
60
|
+
| "accent-400"
|
|
61
|
+
| "accent-500"
|
|
62
|
+
| "accent-600"
|
|
63
|
+
| "accent-700"
|
|
64
|
+
| "accent-800"
|
|
65
|
+
| "accent-900"
|
|
66
|
+
| "accent-950"
|
|
67
|
+
| "info-50"
|
|
68
|
+
| "info-100"
|
|
69
|
+
| "info-200"
|
|
70
|
+
| "info-300"
|
|
71
|
+
| "info-400"
|
|
72
|
+
| "info-500"
|
|
73
|
+
| "info-600"
|
|
74
|
+
| "info-700"
|
|
75
|
+
| "info-800"
|
|
76
|
+
| "info-900"
|
|
77
|
+
| "info-950"
|
|
78
|
+
| "danger-50"
|
|
79
|
+
| "danger-100"
|
|
80
|
+
| "danger-200"
|
|
81
|
+
| "danger-300"
|
|
82
|
+
| "danger-400"
|
|
83
|
+
| "danger-500"
|
|
84
|
+
| "danger-600"
|
|
85
|
+
| "danger-700"
|
|
86
|
+
| "danger-800"
|
|
87
|
+
| "danger-900"
|
|
88
|
+
| "danger-950"
|
|
89
|
+
| "success-50"
|
|
90
|
+
| "success-100"
|
|
91
|
+
| "success-200"
|
|
92
|
+
| "success-300"
|
|
93
|
+
| "success-400"
|
|
94
|
+
| "success-500"
|
|
95
|
+
| "success-600"
|
|
96
|
+
| "success-700"
|
|
97
|
+
| "success-800"
|
|
98
|
+
| "success-900"
|
|
99
|
+
| "success-950"
|
|
100
|
+
| "warning-50"
|
|
101
|
+
| "warning-100"
|
|
102
|
+
| "warning-200"
|
|
103
|
+
| "warning-300"
|
|
104
|
+
| "warning-400"
|
|
105
|
+
| "warning-500"
|
|
106
|
+
| "warning-600"
|
|
107
|
+
| "warning-700"
|
|
108
|
+
| "warning-800"
|
|
109
|
+
| "warning-900"
|
|
110
|
+
| "warning-950";
|
|
111
|
+
|
|
40
112
|
export type PaletteType =
|
|
41
|
-
| "scarlet"
|
|
42
|
-
| "
|
|
43
|
-
| "
|
|
44
|
-
| "
|
|
45
|
-
| "
|
|
46
|
-
| "
|
|
47
|
-
| "
|
|
48
|
-
| "
|
|
49
|
-
| "
|
|
50
|
-
| "
|
|
51
|
-
| "
|
|
52
|
-
| "
|
|
53
|
-
| "
|
|
54
|
-
| "
|
|
113
|
+
| "scarlet-50"
|
|
114
|
+
| "scarlet-100"
|
|
115
|
+
| "scarlet-200"
|
|
116
|
+
| "scarlet-300"
|
|
117
|
+
| "scarlet-400"
|
|
118
|
+
| "scarlet-500"
|
|
119
|
+
| "scarlet-600"
|
|
120
|
+
| "scarlet-700"
|
|
121
|
+
| "scarlet-800"
|
|
122
|
+
| "scarlet-900"
|
|
123
|
+
| "scarlet-950"
|
|
124
|
+
| "pumpkin-50"
|
|
125
|
+
| "pumpkin-100"
|
|
126
|
+
| "pumpkin-200"
|
|
127
|
+
| "pumpkin-300"
|
|
128
|
+
| "pumpkin-400"
|
|
129
|
+
| "pumpkin-500"
|
|
130
|
+
| "pumpkin-600"
|
|
131
|
+
| "pumpkin-700"
|
|
132
|
+
| "pumpkin-800"
|
|
133
|
+
| "pumpkin-900"
|
|
134
|
+
| "pumpkin-950"
|
|
135
|
+
| "marigold-50"
|
|
136
|
+
| "marigold-100"
|
|
137
|
+
| "marigold-200"
|
|
138
|
+
| "marigold-300"
|
|
139
|
+
| "marigold-400"
|
|
140
|
+
| "marigold-500"
|
|
141
|
+
| "marigold-600"
|
|
142
|
+
| "marigold-700"
|
|
143
|
+
| "marigold-800"
|
|
144
|
+
| "marigold-900"
|
|
145
|
+
| "marigold-950"
|
|
146
|
+
| "avacado-50"
|
|
147
|
+
| "avacado-100"
|
|
148
|
+
| "avacado-200"
|
|
149
|
+
| "avacado-300"
|
|
150
|
+
| "avacado-400"
|
|
151
|
+
| "avacado-500"
|
|
152
|
+
| "avacado-600"
|
|
153
|
+
| "avacado-700"
|
|
154
|
+
| "avacado-800"
|
|
155
|
+
| "avacado-900"
|
|
156
|
+
| "avacado-950"
|
|
157
|
+
| "jade-50"
|
|
158
|
+
| "jade-100"
|
|
159
|
+
| "jade-200"
|
|
160
|
+
| "jade-300"
|
|
161
|
+
| "jade-400"
|
|
162
|
+
| "jade-500"
|
|
163
|
+
| "jade-600"
|
|
164
|
+
| "jade-700"
|
|
165
|
+
| "jade-800"
|
|
166
|
+
| "jade-900"
|
|
167
|
+
| "jade-950"
|
|
168
|
+
| "denim-50"
|
|
169
|
+
| "denim-100"
|
|
170
|
+
| "denim-200"
|
|
171
|
+
| "denim-300"
|
|
172
|
+
| "denim-400"
|
|
173
|
+
| "denim-500"
|
|
174
|
+
| "denim-600"
|
|
175
|
+
| "denim-700"
|
|
176
|
+
| "denim-800"
|
|
177
|
+
| "denim-900"
|
|
178
|
+
| "denim-950"
|
|
179
|
+
| "iris-50"
|
|
180
|
+
| "iris-100"
|
|
181
|
+
| "iris-200"
|
|
182
|
+
| "iris-300"
|
|
183
|
+
| "iris-400"
|
|
184
|
+
| "iris-500"
|
|
185
|
+
| "iris-600"
|
|
186
|
+
| "iris-700"
|
|
187
|
+
| "iris-800"
|
|
188
|
+
| "iris-900"
|
|
189
|
+
| "iris-950"
|
|
190
|
+
| "lilac-50"
|
|
191
|
+
| "lilac-100"
|
|
192
|
+
| "lilac-200"
|
|
193
|
+
| "lilac-300"
|
|
194
|
+
| "lilac-400"
|
|
195
|
+
| "lilac-500"
|
|
196
|
+
| "lilac-600"
|
|
197
|
+
| "lilac-700"
|
|
198
|
+
| "lilac-800"
|
|
199
|
+
| "lilac-900"
|
|
200
|
+
| "lilac-950"
|
|
201
|
+
| "coral-50"
|
|
202
|
+
| "coral-100"
|
|
203
|
+
| "coral-200"
|
|
204
|
+
| "coral-300"
|
|
205
|
+
| "coral-400"
|
|
206
|
+
| "coral-500"
|
|
207
|
+
| "coral-600"
|
|
208
|
+
| "coral-700"
|
|
209
|
+
| "coral-800"
|
|
210
|
+
| "coral-900"
|
|
211
|
+
| "coral-950"
|
|
212
|
+
| "wood-50"
|
|
213
|
+
| "wood-100"
|
|
214
|
+
| "wood-200"
|
|
215
|
+
| "wood-300"
|
|
216
|
+
| "wood-400"
|
|
217
|
+
| "wood-500"
|
|
218
|
+
| "wood-600"
|
|
219
|
+
| "wood-700"
|
|
220
|
+
| "wood-800"
|
|
221
|
+
| "wood-900"
|
|
222
|
+
| "wood-950"
|
|
223
|
+
| "silver-50"
|
|
224
|
+
| "silver-100"
|
|
225
|
+
| "silver-200"
|
|
226
|
+
| "silver-300"
|
|
227
|
+
| "silver-400"
|
|
228
|
+
| "silver-500"
|
|
229
|
+
| "silver-600"
|
|
230
|
+
| "silver-700"
|
|
231
|
+
| "silver-800"
|
|
232
|
+
| "silver-900"
|
|
233
|
+
| "silver-950"
|
|
234
|
+
| "steel-50"
|
|
235
|
+
| "steel-100"
|
|
236
|
+
| "steel-200"
|
|
237
|
+
| "steel-300"
|
|
238
|
+
| "steel-400"
|
|
239
|
+
| "steel-500"
|
|
240
|
+
| "steel-600"
|
|
241
|
+
| "steel-700"
|
|
242
|
+
| "steel-800"
|
|
243
|
+
| "steel-900"
|
|
244
|
+
| "steel-950"
|
|
245
|
+
| "olive-50"
|
|
246
|
+
| "olive-100"
|
|
247
|
+
| "olive-200"
|
|
248
|
+
| "olive-300"
|
|
249
|
+
| "olive-400"
|
|
250
|
+
| "olive-500"
|
|
251
|
+
| "olive-600"
|
|
252
|
+
| "olive-700"
|
|
253
|
+
| "olive-800"
|
|
254
|
+
| "olive-900"
|
|
255
|
+
| "olive-950"
|
|
256
|
+
| "sand-50"
|
|
257
|
+
| "sand-100"
|
|
258
|
+
| "sand-200"
|
|
259
|
+
| "sand-300"
|
|
260
|
+
| "sand-400"
|
|
261
|
+
| "sand-500"
|
|
262
|
+
| "sand-600"
|
|
263
|
+
| "sand-700"
|
|
264
|
+
| "sand-800"
|
|
265
|
+
| "sand-900"
|
|
266
|
+
| "sand-950"
|
|
267
|
+
| "tint-50"
|
|
268
|
+
| "tint-100"
|
|
269
|
+
| "tint-200"
|
|
270
|
+
| "tint-300"
|
|
271
|
+
| "tint-400"
|
|
272
|
+
| "tint-500"
|
|
273
|
+
| "tint-600"
|
|
274
|
+
| "tint-700"
|
|
275
|
+
| "tint-800"
|
|
276
|
+
| "tint-900"
|
|
277
|
+
| "tint-950";
|
|
55
278
|
|
|
56
279
|
export type ColorWithGrays = ColorType | "invert" | "dimmed" | "muted";
|
|
57
280
|
|
|
@@ -78,7 +301,11 @@ export interface TooltipType {
|
|
|
78
301
|
/**
|
|
79
302
|
* tooltip color
|
|
80
303
|
*/
|
|
81
|
-
color?: ColorType;
|
|
304
|
+
color?: ColorType | PaletteType | string;
|
|
305
|
+
/**
|
|
306
|
+
* text color
|
|
307
|
+
*/
|
|
308
|
+
textColor?: ColorType | PaletteType | string;
|
|
82
309
|
/**
|
|
83
310
|
* tooltip placement
|
|
84
311
|
*/
|
|
@@ -109,6 +336,10 @@ export interface CssProp {
|
|
|
109
336
|
* css classname(s)
|
|
110
337
|
*/
|
|
111
338
|
className?: string;
|
|
339
|
+
/**
|
|
340
|
+
* direction
|
|
341
|
+
*/
|
|
342
|
+
dir?: "ltr" | "rtl";
|
|
112
343
|
}
|
|
113
344
|
|
|
114
345
|
export interface TestProps {
|
|
@@ -122,15 +353,7 @@ export interface TestProps {
|
|
|
122
353
|
"data-test-value"?: AnyObject;
|
|
123
354
|
}
|
|
124
355
|
|
|
125
|
-
export type Elements<T> =
|
|
126
|
-
| React.ReactElement<T>
|
|
127
|
-
| React.ReactPortal
|
|
128
|
-
| React.ReactNode
|
|
129
|
-
| string
|
|
130
|
-
| number
|
|
131
|
-
| boolean
|
|
132
|
-
| null
|
|
133
|
-
| undefined;
|
|
356
|
+
export type Elements<T> = React.ReactElement<T> | React.ReactNode;
|
|
134
357
|
|
|
135
358
|
export type AriaProps = React.AriaAttributes;
|
|
136
359
|
|
|
@@ -144,7 +367,6 @@ export interface RefProp<T = HTMLElement> {
|
|
|
144
367
|
|
|
145
368
|
/* *********** */
|
|
146
369
|
|
|
147
|
-
// eslint-disable-next-line @typescript-eslint/no-invalid-void-type
|
|
148
370
|
export type CallbackReturn<T = unknown> =
|
|
149
371
|
| undefined
|
|
150
372
|
| T
|
|
@@ -167,25 +389,6 @@ export type PolymorphicProps<AsTag extends ReactTag> = Omit<
|
|
|
167
389
|
as?: AsTag;
|
|
168
390
|
};
|
|
169
391
|
|
|
170
|
-
export interface IconProps {
|
|
171
|
-
/**
|
|
172
|
-
* svg path / image url
|
|
173
|
-
*/
|
|
174
|
-
icon?: string;
|
|
175
|
-
/**
|
|
176
|
-
* flip icon in rtl
|
|
177
|
-
*/
|
|
178
|
-
rtlFlip?: boolean;
|
|
179
|
-
/**
|
|
180
|
-
* icon background color
|
|
181
|
-
*/
|
|
182
|
-
iconBg?: ColorType | string;
|
|
183
|
-
/**
|
|
184
|
-
* icon color
|
|
185
|
-
*/
|
|
186
|
-
iconColor?: ColorType | string;
|
|
187
|
-
}
|
|
188
|
-
|
|
189
392
|
export interface CollapseProps {
|
|
190
393
|
/**
|
|
191
394
|
* Allow collapsing
|
|
@@ -244,3 +447,16 @@ export interface ScrollObject extends PositionObject, SizeObject {
|
|
|
244
447
|
scrollWidth?: number;
|
|
245
448
|
scrollHeight: number;
|
|
246
449
|
}
|
|
450
|
+
|
|
451
|
+
export type ArrayType<T extends readonly any[] | ArrayLike<any> | undefined> =
|
|
452
|
+
T extends readonly any[]
|
|
453
|
+
? T[number]
|
|
454
|
+
: T extends ArrayLike<any>
|
|
455
|
+
? T[number]
|
|
456
|
+
: undefined;
|
|
457
|
+
|
|
458
|
+
export type Complete<T> = {
|
|
459
|
+
[P in keyof Required<T>]: Pick<T, P> extends Required<Pick<T, P>>
|
|
460
|
+
? T[P]
|
|
461
|
+
: T[P] | undefined;
|
|
462
|
+
};
|