@react-fabric/core 1.0.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +10 -0
- package/css/flags.rect.css +1607 -0
- package/css/flags.wavy.css +1606 -0
- package/css/index.js +250 -0
- package/css/reset/_gradients.css +51 -0
- package/css/reset/_reset.css +407 -0
- package/css/reset/_text.css +179 -0
- package/css/reset/_theme.css +110 -0
- package/css/reset/index.css +27 -0
- package/css/styles.css +31 -0
- package/css/tailwind/colors.ts +158 -0
- package/dist/cjs/components/actionLabel/ActionLabel.js +56 -0
- package/dist/cjs/components/actionLabel/ActionLabel.module.css +1 -0
- package/dist/cjs/components/animations/Animations.js +135 -0
- package/dist/cjs/components/animations/Animations.module.css +1 -0
- package/dist/cjs/components/avatar/Avatar.js +144 -0
- package/dist/cjs/components/avatar/Avatar.module.css +1 -0
- package/dist/cjs/components/avatar/AvatarGroup.js +74 -0
- package/dist/cjs/components/badge/Badge.js +82 -0
- package/dist/cjs/components/badge/Badge.module.css +1 -0
- package/dist/cjs/components/breadcrumbs/Breadcrumbs.js +71 -0
- package/dist/cjs/components/breadcrumbs/Breadcrumbs.module.css +1 -0
- package/dist/cjs/components/button/Button.js +170 -0
- package/dist/cjs/components/button/Button.module.css +1 -0
- package/dist/cjs/components/button/ButtonGroup.js +41 -0
- package/dist/cjs/components/button/ConfirmButton.js +166 -0
- package/dist/cjs/components/button/ToggleButtonGroup.js +68 -0
- package/dist/cjs/components/callout/Callout.js +54 -0
- package/dist/cjs/components/card/Card.js +62 -0
- package/dist/cjs/components/card/Card.module.css +1 -0
- package/dist/cjs/components/card/CardCover.js +48 -0
- package/dist/cjs/components/chip/Chip.js +94 -0
- package/dist/cjs/components/chip/Chip.module.css +1 -0
- package/dist/cjs/components/collapsable/Collapsable.js +84 -0
- package/dist/cjs/components/collapsable/Collapsable.module.css +1 -0
- package/dist/cjs/components/divider/Divider.js +65 -0
- package/dist/cjs/components/dropdown/Dropdown.js +180 -0
- package/dist/cjs/components/dropdown/Dropdown.module.css +1 -0
- package/dist/cjs/components/dropdown/DropdownTool.js +26 -0
- package/dist/cjs/components/empty/EmptyContent.js +92 -0
- package/dist/cjs/components/icon/Icon.js +106 -0
- package/dist/cjs/components/icon/Icon.module.css +1 -0
- package/dist/cjs/components/media/Media.js +149 -0
- package/dist/cjs/components/media/Media.module.css +1 -0
- package/dist/cjs/components/menu/ContextMenu.js +84 -0
- package/dist/cjs/components/menu/Menu.js +204 -0
- package/dist/cjs/components/menu/Menu.module.css +1 -0
- package/dist/cjs/components/menu/MenuItem.js +119 -0
- package/dist/cjs/components/meter/Meter.js +41 -0
- package/dist/cjs/components/meter/Meter.module.css +1 -0
- package/dist/cjs/components/navigator/Navigator.js +54 -0
- package/dist/cjs/components/panel/Panel.js +125 -0
- package/dist/cjs/components/panel/Panel.module.css +1 -0
- package/dist/cjs/components/panel/PanelGroup.js +50 -0
- package/dist/cjs/components/panel/PanelStack.js +85 -0
- package/dist/cjs/components/progress/Progress.module.css +1 -0
- package/dist/cjs/components/progress/ProgressBar.js +62 -0
- package/dist/cjs/components/progress/ProgressCircle.js +96 -0
- package/dist/cjs/components/tabpanel/Tab.js +78 -0
- package/dist/cjs/components/tabpanel/TabPanel.js +77 -0
- package/dist/cjs/components/tabpanel/TabPanel.module.css +1 -0
- package/dist/cjs/context/Global.js +169 -0
- package/dist/cjs/context/NotificationCenter.js +254 -0
- package/dist/cjs/core/aside/Aside.js +152 -0
- package/dist/cjs/core/aside/Aside.module.css +1 -0
- package/dist/cjs/core/boundary/ErrorBoundary.js +140 -0
- package/dist/cjs/core/boundary/ErrorBoundary.module.css +1 -0
- package/dist/cjs/core/boundary/ErrorIcon.js +51 -0
- package/dist/cjs/core/content/Content.js +70 -0
- package/dist/cjs/core/content/Content.module.css +1 -0
- package/dist/cjs/core/headfoot/HeadFoot.js +62 -0
- package/dist/cjs/core/headfoot/HeadFoot.module.css +1 -0
- package/dist/cjs/core/page/Page.js +65 -0
- package/dist/cjs/core/page/Page.module.css +1 -0
- package/dist/cjs/core/responsive/Responsive.js +64 -0
- package/dist/cjs/core/responsive/Responsive.module.css +1 -0
- package/dist/cjs/core/section/Section.js +44 -0
- package/dist/cjs/core/section/Section.module.css +1 -0
- package/dist/cjs/core/theme/Theme.module.css +1 -0
- package/dist/cjs/core/theme/ThemeProvider.js +74 -0
- package/dist/cjs/core/viewport/Viewport.js +39 -0
- package/dist/cjs/core/viewport/Viewport.module.css +1 -0
- package/dist/cjs/hooks/useClientService.js +30 -0
- package/dist/cjs/hooks/useControlledValue.js +22 -0
- package/dist/cjs/hooks/useDebounce.js +56 -0
- package/dist/cjs/hooks/useEffectDebugger.js +113 -0
- package/dist/cjs/hooks/useIsDark.js +33 -0
- package/dist/cjs/hooks/useIsRtl.js +27 -0
- package/dist/cjs/hooks/useNavigator.js +36 -0
- package/dist/cjs/hooks/useOverlayService.js +55 -0
- package/dist/cjs/hooks/usePropToggle.js +40 -0
- package/dist/cjs/hooks/useResize.js +75 -0
- package/dist/cjs/hooks/useResizeObserver.js +38 -0
- package/dist/cjs/hooks/useStorage.js +44 -0
- package/dist/cjs/hotkeys/HotKey.js +47 -0
- package/dist/cjs/hotkeys/HotKeyLabel.js +52 -0
- package/dist/cjs/hotkeys/HotKeyWrapper.js +98 -0
- package/dist/cjs/hotkeys/commons.js +56 -0
- package/dist/cjs/i18n/ar.json.js +31 -0
- package/dist/cjs/i18n/en.json.js +46 -0
- package/dist/cjs/i18n/index.js +55 -0
- package/dist/cjs/index.js +162 -0
- package/dist/cjs/overlays/alert/Alert.js +163 -0
- package/dist/cjs/overlays/alert/Alert.module.css +1 -0
- package/dist/cjs/overlays/flyout/Flyout.js +152 -0
- package/dist/cjs/overlays/flyout/Flyout.module.css +1 -0
- package/dist/cjs/overlays/message/Message.js +84 -0
- package/dist/cjs/overlays/message/Message.module.css +1 -0
- package/dist/cjs/overlays/modal/Modal.js +132 -0
- package/dist/cjs/overlays/modal/Modal.module.css +1 -0
- package/dist/cjs/overlays/toast/Toast.js +166 -0
- package/dist/cjs/overlays/toast/Toast.module.css +1 -0
- package/dist/cjs/overlays/tooltip/Tooltip.js +133 -0
- package/dist/cjs/overlays/tooltip/Tooltip.module.css +1 -0
- package/dist/cjs/types/icons.js +197 -0
- package/dist/cjs/typography/Abbr.js +108 -0
- package/dist/cjs/typography/Copy.js +59 -0
- package/dist/cjs/typography/Link.js +55 -0
- package/dist/cjs/typography/Mark.js +86 -0
- package/dist/cjs/typography/Text.js +121 -0
- package/dist/cjs/typography/Title.js +58 -0
- package/dist/cjs/typography/Typography.module.css +1 -0
- package/dist/cjs/typography/types.js +42 -0
- package/dist/cjs/utils/calculateDimensions.js +51 -0
- package/dist/cjs/utils/getColor.js +52 -0
- package/dist/cjs/utils/nodeCheck.js +35 -0
- package/dist/esm/components/actionLabel/ActionLabel.js +56 -0
- package/dist/esm/components/actionLabel/ActionLabel.module.css +1 -0
- package/dist/esm/components/animations/Animations.js +131 -0
- package/dist/esm/components/animations/Animations.module.css +1 -0
- package/dist/esm/components/avatar/Avatar.js +144 -0
- package/dist/esm/components/avatar/Avatar.module.css +1 -0
- package/dist/esm/components/avatar/AvatarGroup.js +74 -0
- package/dist/esm/components/badge/Badge.js +81 -0
- package/dist/esm/components/badge/Badge.module.css +1 -0
- package/dist/esm/components/breadcrumbs/Breadcrumbs.js +71 -0
- package/dist/esm/components/breadcrumbs/Breadcrumbs.module.css +1 -0
- package/dist/esm/components/button/Button.js +170 -0
- package/dist/esm/components/button/Button.module.css +1 -0
- package/dist/esm/components/button/ButtonGroup.js +41 -0
- package/dist/esm/components/button/ConfirmButton.js +166 -0
- package/dist/esm/components/button/ToggleButtonGroup.js +68 -0
- package/dist/esm/components/callout/Callout.js +54 -0
- package/dist/esm/components/card/Card.js +62 -0
- package/dist/esm/components/card/Card.module.css +1 -0
- package/dist/esm/components/card/CardCover.js +48 -0
- package/dist/esm/components/chip/Chip.js +94 -0
- package/dist/esm/components/chip/Chip.module.css +1 -0
- package/dist/esm/components/collapsable/Collapsable.js +84 -0
- package/dist/esm/components/collapsable/Collapsable.module.css +1 -0
- package/dist/esm/components/divider/Divider.js +65 -0
- package/dist/esm/components/dropdown/Dropdown.js +179 -0
- package/dist/esm/components/dropdown/Dropdown.module.css +1 -0
- package/dist/esm/components/dropdown/DropdownTool.js +26 -0
- package/dist/esm/components/empty/EmptyContent.js +92 -0
- package/dist/esm/components/icon/Icon.js +106 -0
- package/dist/esm/components/icon/Icon.module.css +1 -0
- package/dist/esm/components/media/Media.js +148 -0
- package/dist/esm/components/media/Media.module.css +1 -0
- package/dist/esm/components/menu/ContextMenu.js +84 -0
- package/dist/esm/components/menu/Menu.js +204 -0
- package/dist/esm/components/menu/Menu.module.css +1 -0
- package/dist/esm/components/menu/MenuItem.js +119 -0
- package/dist/esm/components/meter/Meter.js +41 -0
- package/dist/esm/components/meter/Meter.module.css +1 -0
- package/dist/esm/components/navigator/Navigator.js +54 -0
- package/dist/esm/components/panel/Panel.js +125 -0
- package/dist/esm/components/panel/Panel.module.css +1 -0
- package/dist/esm/components/panel/PanelGroup.js +50 -0
- package/dist/esm/components/panel/PanelStack.js +85 -0
- package/dist/esm/components/progress/Progress.module.css +1 -0
- package/dist/esm/components/progress/ProgressBar.js +62 -0
- package/dist/esm/components/progress/ProgressCircle.js +96 -0
- package/dist/esm/components/tabpanel/Tab.js +78 -0
- package/dist/esm/components/tabpanel/TabPanel.js +77 -0
- package/dist/esm/components/tabpanel/TabPanel.module.css +1 -0
- package/dist/esm/context/Global.js +165 -0
- package/dist/esm/context/NotificationCenter.js +254 -0
- package/dist/esm/core/aside/Aside.js +152 -0
- package/dist/esm/core/aside/Aside.module.css +1 -0
- package/dist/esm/core/boundary/ErrorBoundary.js +140 -0
- package/dist/esm/core/boundary/ErrorBoundary.module.css +1 -0
- package/dist/esm/core/boundary/ErrorIcon.js +51 -0
- package/dist/esm/core/content/Content.js +70 -0
- package/dist/esm/core/content/Content.module.css +1 -0
- package/dist/esm/core/headfoot/HeadFoot.js +61 -0
- package/dist/esm/core/headfoot/HeadFoot.module.css +1 -0
- package/dist/esm/core/page/Page.js +65 -0
- package/dist/esm/core/page/Page.module.css +1 -0
- package/dist/esm/core/responsive/Responsive.js +62 -0
- package/dist/esm/core/responsive/Responsive.module.css +1 -0
- package/dist/esm/core/section/Section.js +44 -0
- package/dist/esm/core/section/Section.module.css +1 -0
- package/dist/esm/core/theme/Theme.module.css +1 -0
- package/dist/esm/core/theme/ThemeProvider.js +74 -0
- package/dist/esm/core/viewport/Viewport.js +39 -0
- package/dist/esm/core/viewport/Viewport.module.css +1 -0
- package/dist/esm/hooks/useClientService.js +30 -0
- package/dist/esm/hooks/useControlledValue.js +22 -0
- package/dist/esm/hooks/useDebounce.js +56 -0
- package/dist/esm/hooks/useEffectDebugger.js +111 -0
- package/dist/esm/hooks/useIsDark.js +33 -0
- package/dist/esm/hooks/useIsRtl.js +27 -0
- package/dist/esm/hooks/useNavigator.js +36 -0
- package/dist/esm/hooks/useOverlayService.js +55 -0
- package/dist/esm/hooks/usePropToggle.js +40 -0
- package/dist/esm/hooks/useResize.js +75 -0
- package/dist/esm/hooks/useResizeObserver.js +38 -0
- package/dist/esm/hooks/useStorage.js +43 -0
- package/dist/esm/hotkeys/HotKey.js +47 -0
- package/dist/esm/hotkeys/HotKeyLabel.js +52 -0
- package/dist/esm/hotkeys/HotKeyWrapper.js +96 -0
- package/dist/esm/hotkeys/commons.js +56 -0
- package/dist/esm/i18n/ar.json.js +27 -0
- package/dist/esm/i18n/en.json.js +41 -0
- package/dist/esm/i18n/index.js +55 -0
- package/dist/esm/index.js +75 -0
- package/dist/esm/overlays/alert/Alert.js +163 -0
- package/dist/esm/overlays/alert/Alert.module.css +1 -0
- package/dist/esm/overlays/flyout/Flyout.js +152 -0
- package/dist/esm/overlays/flyout/Flyout.module.css +1 -0
- package/dist/esm/overlays/message/Message.js +84 -0
- package/dist/esm/overlays/message/Message.module.css +1 -0
- package/dist/esm/overlays/modal/Modal.js +132 -0
- package/dist/esm/overlays/modal/Modal.module.css +1 -0
- package/dist/esm/overlays/toast/Toast.js +166 -0
- package/dist/esm/overlays/toast/Toast.module.css +1 -0
- package/dist/esm/overlays/tooltip/Tooltip.js +132 -0
- package/dist/esm/overlays/tooltip/Tooltip.module.css +1 -0
- package/dist/esm/types/icons.js +199 -0
- package/dist/esm/typography/Abbr.js +108 -0
- package/dist/esm/typography/Copy.js +59 -0
- package/dist/esm/typography/Link.js +55 -0
- package/dist/esm/typography/Mark.js +86 -0
- package/dist/esm/typography/Text.js +121 -0
- package/dist/esm/typography/Title.js +58 -0
- package/dist/esm/typography/Typography.module.css +1 -0
- package/dist/esm/typography/types.js +41 -0
- package/dist/esm/utils/calculateDimensions.js +50 -0
- package/dist/esm/utils/getColor.js +49 -0
- package/dist/esm/utils/nodeCheck.js +35 -0
- package/dist/types/components/actionLabel/ActionLabel.d.ts +21 -0
- package/dist/types/components/animations/Animations.d.ts +23 -0
- package/dist/types/components/avatar/Avatar.d.ts +48 -0
- package/dist/types/components/avatar/AvatarGroup.d.ts +24 -0
- package/dist/types/components/badge/Badge.d.ts +25 -0
- package/dist/types/components/breadcrumbs/Breadcrumbs.d.ts +17 -0
- package/dist/types/components/button/Button.d.ts +94 -0
- package/dist/types/components/button/ButtonGroup.d.ts +34 -0
- package/dist/types/components/button/ConfirmButton.d.ts +27 -0
- package/dist/types/components/button/ToggleButtonGroup.d.ts +56 -0
- package/dist/types/components/callout/Callout.d.ts +28 -0
- package/dist/types/components/card/Card.d.ts +39 -0
- package/dist/types/components/card/CardCover.d.ts +16 -0
- package/dist/types/components/chip/Chip.d.ts +41 -0
- package/dist/types/components/collapsable/Collapsable.d.ts +43 -0
- package/dist/types/components/divider/Divider.d.ts +20 -0
- package/dist/types/components/dropdown/Dropdown.d.ts +50 -0
- package/dist/types/components/dropdown/DropdownTool.d.ts +8 -0
- package/dist/types/components/empty/EmptyContent.d.ts +21 -0
- package/dist/types/components/icon/Icon.d.ts +44 -0
- package/dist/types/components/index.d.ts +33 -0
- package/dist/types/components/media/Media.d.ts +37 -0
- package/dist/types/components/menu/ContextMenu.d.ts +7 -0
- package/dist/types/components/menu/Menu.d.ts +2 -0
- package/dist/types/components/menu/MenuItem.d.ts +4 -0
- package/dist/types/components/menu/types.d.ts +59 -0
- package/dist/types/components/meter/Meter.d.ts +12 -0
- package/dist/types/components/navigator/Navigator.d.ts +12 -0
- package/dist/types/components/panel/Panel.d.ts +59 -0
- package/dist/types/components/panel/PanelGroup.d.ts +12 -0
- package/dist/types/components/panel/PanelStack.d.ts +16 -0
- package/dist/types/components/progress/ProgressBar.d.ts +24 -0
- package/dist/types/components/progress/ProgressCircle.d.ts +16 -0
- package/dist/types/components/tabpanel/Tab.d.ts +41 -0
- package/dist/types/components/tabpanel/TabPanel.d.ts +41 -0
- package/dist/types/context/Global.d.ts +81 -0
- package/dist/types/context/NotificationCenter.d.ts +11 -0
- package/dist/types/core/aside/Aside.d.ts +52 -0
- package/dist/types/core/boundary/ErrorBoundary.d.ts +26 -0
- package/dist/types/core/boundary/ErrorIcon.d.ts +1 -0
- package/dist/types/core/content/Content.d.ts +15 -0
- package/dist/types/core/headfoot/HeadFoot.d.ts +24 -0
- package/dist/types/core/index.d.ts +9 -0
- package/dist/types/core/page/Page.d.ts +23 -0
- package/dist/types/core/responsive/Responsive.d.ts +53 -0
- package/dist/types/core/section/Section.d.ts +7 -0
- package/dist/types/core/theme/ThemeProvider.d.ts +37 -0
- package/dist/types/core/viewport/Viewport.d.ts +5 -0
- package/dist/types/hooks/useClientService.d.ts +1 -0
- package/dist/types/hooks/useControlledValue.d.ts +5 -0
- package/dist/types/hooks/useDebounce.d.ts +4 -0
- package/dist/types/hooks/useEffectDebugger.d.ts +4 -0
- package/dist/types/hooks/useIsDark.d.ts +1 -0
- package/dist/types/hooks/useIsRtl.d.ts +1 -0
- package/dist/types/hooks/useNavigator.d.ts +7 -0
- package/dist/types/hooks/useOverlayService.d.ts +10 -0
- package/dist/types/hooks/usePropToggle.d.ts +9 -0
- package/dist/types/hooks/useResize.d.ts +27 -0
- package/dist/types/hooks/useResizeObserver.d.ts +3 -0
- package/dist/types/hooks/useStorage.d.ts +2 -0
- package/dist/types/hotkeys/HotKey.d.ts +2 -0
- package/dist/types/hotkeys/HotKeyLabel.d.ts +2 -0
- package/dist/types/hotkeys/HotKeyWrapper.d.ts +11 -0
- package/dist/types/hotkeys/commons.d.ts +28 -0
- package/dist/types/i18n/index.d.ts +6 -0
- package/dist/types/index.d.ts +19 -0
- package/dist/types/overlays/alert/Alert.d.ts +33 -0
- package/dist/types/overlays/flyout/Flyout.d.ts +57 -0
- package/dist/types/overlays/index.d.ts +6 -0
- package/dist/types/overlays/message/Message.d.ts +21 -0
- package/dist/types/overlays/modal/Modal.d.ts +53 -0
- package/dist/types/overlays/toast/Toast.d.ts +33 -0
- package/dist/types/overlays/tooltip/Tooltip.d.ts +18 -0
- package/dist/types/types/icons.d.ts +194 -0
- package/dist/types/types/index.d.ts +140 -0
- package/dist/types/typography/Abbr.d.ts +22 -0
- package/dist/types/typography/Copy.d.ts +9 -0
- package/dist/types/typography/Link.d.ts +24 -0
- package/dist/types/typography/Mark.d.ts +18 -0
- package/dist/types/typography/Text.d.ts +35 -0
- package/dist/types/typography/Title.d.ts +29 -0
- package/dist/types/typography/index.d.ts +6 -0
- package/dist/types/typography/types.d.ts +2 -0
- package/dist/types/utils/calculateDimensions.d.ts +6 -0
- package/dist/types/utils/getColor.d.ts +4 -0
- package/dist/types/utils/index.d.ts +3 -0
- package/dist/types/utils/nodeCheck.d.ts +2 -0
- package/package.json +60 -0
- package/src/components/actionLabel/ActionLabel.module.css +38 -0
- package/src/components/actionLabel/ActionLabel.tsx +97 -0
- package/src/components/animations/Animations.module.css +253 -0
- package/src/components/animations/Animations.tsx +190 -0
- package/src/components/avatar/Avatar.module.css +90 -0
- package/src/components/avatar/Avatar.tsx +218 -0
- package/src/components/avatar/AvatarGroup.tsx +140 -0
- package/src/components/badge/Badge.module.css +165 -0
- package/src/components/badge/Badge.tsx +148 -0
- package/src/components/breadcrumbs/Breadcrumbs.module.css +189 -0
- package/src/components/breadcrumbs/Breadcrumbs.tsx +109 -0
- package/src/components/button/Button.module.css +375 -0
- package/src/components/button/Button.tsx +323 -0
- package/src/components/button/ButtonGroup.tsx +112 -0
- package/src/components/button/ConfirmButton.tsx +221 -0
- package/src/components/button/ToggleButtonGroup.tsx +161 -0
- package/src/components/callout/Callout.tsx +104 -0
- package/src/components/card/Card.module.css +152 -0
- package/src/components/card/Card.tsx +154 -0
- package/src/components/card/CardCover.tsx +87 -0
- package/src/components/chip/Chip.module.css +118 -0
- package/src/components/chip/Chip.tsx +201 -0
- package/src/components/collapsable/Collapsable.module.css +30 -0
- package/src/components/collapsable/Collapsable.tsx +153 -0
- package/src/components/divider/Divider.tsx +105 -0
- package/src/components/dropdown/Dropdown.module.css +39 -0
- package/src/components/dropdown/Dropdown.tsx +307 -0
- package/src/components/dropdown/DropdownTool.tsx +56 -0
- package/src/components/empty/EmptyContent.tsx +141 -0
- package/src/components/icon/Icon.module.css +71 -0
- package/src/components/icon/Icon.tsx +188 -0
- package/src/components/index.ts +61 -0
- package/src/components/media/Media.module.css +112 -0
- package/src/components/media/Media.tsx +224 -0
- package/src/components/menu/ContextMenu.tsx +116 -0
- package/src/components/menu/Menu.module.css +109 -0
- package/src/components/menu/Menu.tsx +278 -0
- package/src/components/menu/MenuItem.tsx +162 -0
- package/src/components/menu/types.ts +100 -0
- package/src/components/meter/Meter.module.css +116 -0
- package/src/components/meter/Meter.tsx +80 -0
- package/src/components/navigator/Navigator.tsx +77 -0
- package/src/components/panel/Panel.module.css +86 -0
- package/src/components/panel/Panel.tsx +254 -0
- package/src/components/panel/PanelGroup.tsx +99 -0
- package/src/components/panel/PanelStack.tsx +133 -0
- package/src/components/progress/Progress.module.css +70 -0
- package/src/components/progress/ProgressBar.tsx +122 -0
- package/src/components/progress/ProgressCircle.tsx +118 -0
- package/src/components/tabpanel/Tab.tsx +175 -0
- package/src/components/tabpanel/TabPanel.module.css +200 -0
- package/src/components/tabpanel/TabPanel.tsx +155 -0
- package/src/context/Global.tsx +241 -0
- package/src/context/NotificationCenter.tsx +223 -0
- package/src/core/aside/Aside.module.css +231 -0
- package/src/core/aside/Aside.tsx +262 -0
- package/src/core/boundary/ErrorBoundary.module.css +65 -0
- package/src/core/boundary/ErrorBoundary.tsx +146 -0
- package/src/core/boundary/ErrorIcon.tsx +50 -0
- package/src/core/content/Content.module.css +40 -0
- package/src/core/content/Content.tsx +91 -0
- package/src/core/headfoot/HeadFoot.module.css +38 -0
- package/src/core/headfoot/HeadFoot.tsx +114 -0
- package/src/core/index.ts +32 -0
- package/src/core/page/Page.module.css +46 -0
- package/src/core/page/Page.tsx +100 -0
- package/src/core/responsive/Responsive.module.css +85 -0
- package/src/core/responsive/Responsive.tsx +172 -0
- package/src/core/section/Section.module.css +28 -0
- package/src/core/section/Section.tsx +48 -0
- package/src/core/theme/Theme.module.css +30 -0
- package/src/core/theme/ThemeProvider.tsx +112 -0
- package/src/core/viewport/Viewport.module.css +32 -0
- package/src/core/viewport/Viewport.tsx +43 -0
- package/src/hooks/useClientService.tsx +29 -0
- package/src/hooks/useControlledValue.tsx +43 -0
- package/src/hooks/useDebounce.ts +52 -0
- package/src/hooks/useEffectDebugger.ts +154 -0
- package/src/hooks/useIsDark.ts +50 -0
- package/src/hooks/useIsRtl.ts +46 -0
- package/src/hooks/useNavigator.tsx +54 -0
- package/src/hooks/useOverlayService.tsx +51 -0
- package/src/hooks/usePropToggle.ts +61 -0
- package/src/hooks/useResize.ts +90 -0
- package/src/hooks/useResizeObserver.ts +55 -0
- package/src/hooks/useStorage.ts +76 -0
- package/src/hotkeys/HotKey.tsx +39 -0
- package/src/hotkeys/HotKeyLabel.tsx +61 -0
- package/src/hotkeys/HotKeyWrapper.tsx +137 -0
- package/src/hotkeys/commons.ts +74 -0
- package/src/i18n/ar.json +21 -0
- package/src/i18n/en.json +34 -0
- package/src/i18n/index.ts +50 -0
- package/src/index.ts +51 -0
- package/src/overlays/alert/Alert.module.css +44 -0
- package/src/overlays/alert/Alert.tsx +229 -0
- package/src/overlays/flyout/Flyout.module.css +52 -0
- package/src/overlays/flyout/Flyout.tsx +283 -0
- package/src/overlays/index.ts +29 -0
- package/src/overlays/message/Message.module.css +37 -0
- package/src/overlays/message/Message.tsx +107 -0
- package/src/overlays/modal/Modal.module.css +53 -0
- package/src/overlays/modal/Modal.tsx +244 -0
- package/src/overlays/toast/Toast.module.css +37 -0
- package/src/overlays/toast/Toast.tsx +216 -0
- package/src/overlays/tooltip/Tooltip.module.css +53 -0
- package/src/overlays/tooltip/Tooltip.tsx +200 -0
- package/src/types/global.d.ts +83 -0
- package/src/types/icons.ts +420 -0
- package/src/types/index.ts +238 -0
- package/src/typography/Abbr.tsx +152 -0
- package/src/typography/Copy.tsx +61 -0
- package/src/typography/Link.tsx +110 -0
- package/src/typography/Mark.tsx +122 -0
- package/src/typography/Text.tsx +194 -0
- package/src/typography/Title.tsx +126 -0
- package/src/typography/Typography.module.css +68 -0
- package/src/typography/index.ts +29 -0
- package/src/typography/types.ts +38 -0
- package/src/utils/calculateDimensions.ts +72 -0
- package/src/utils/getColor.ts +49 -0
- package/src/utils/index.ts +28 -0
- package/src/utils/nodeCheck.ts +34 -0
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { type MouseEventHandler, type WheelEventHandler } from "react";
|
|
2
|
+
import { type AriaProps, type BadgeType, type CallbackReturn, type ColorType, type CssProp, type IconProps, type PolymorphicProps, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
|
+
export interface BaseProps extends CssProp, AriaProps, IconProps, RefProp, TestProps {
|
|
4
|
+
/**
|
|
5
|
+
* primary icon alignment
|
|
6
|
+
*/
|
|
7
|
+
iconAlign?: "start" | "end";
|
|
8
|
+
/**
|
|
9
|
+
* alternate icon align end (caret, arrow)
|
|
10
|
+
*/
|
|
11
|
+
altIcon?: string;
|
|
12
|
+
/**
|
|
13
|
+
* button size
|
|
14
|
+
*/
|
|
15
|
+
size?: SizeType;
|
|
16
|
+
/**
|
|
17
|
+
* button color
|
|
18
|
+
*/
|
|
19
|
+
color?: ColorType;
|
|
20
|
+
/**
|
|
21
|
+
* button type
|
|
22
|
+
*/
|
|
23
|
+
type?: "button" | "reset" | "submit";
|
|
24
|
+
/**
|
|
25
|
+
* button styling
|
|
26
|
+
*/
|
|
27
|
+
variant?: "outline" | "solid" | "link";
|
|
28
|
+
/**
|
|
29
|
+
* active state with click disabled
|
|
30
|
+
*/
|
|
31
|
+
active?: boolean;
|
|
32
|
+
/**
|
|
33
|
+
* loading state with animation and click disabled
|
|
34
|
+
*/
|
|
35
|
+
loading?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* full rounded edges
|
|
38
|
+
*/
|
|
39
|
+
rounded?: boolean;
|
|
40
|
+
/**
|
|
41
|
+
* spin icon on hover
|
|
42
|
+
*/
|
|
43
|
+
spinOnHover?: boolean;
|
|
44
|
+
/**
|
|
45
|
+
* disabled state
|
|
46
|
+
*/
|
|
47
|
+
disabled?: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* stretch to full width
|
|
50
|
+
*/
|
|
51
|
+
fullWidth?: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* action completed message works best with `onClick` Promise return.
|
|
54
|
+
* To hide completed message onClick/Promise return should be false
|
|
55
|
+
*/
|
|
56
|
+
actionMessage?: string;
|
|
57
|
+
/**
|
|
58
|
+
* manually force show action message
|
|
59
|
+
*/
|
|
60
|
+
showActionDone?: boolean;
|
|
61
|
+
/**
|
|
62
|
+
* show action message `onClick` or manually by setting `showActionDone` true
|
|
63
|
+
*/
|
|
64
|
+
showActionDoneEvent?: "click" | "manual";
|
|
65
|
+
/**
|
|
66
|
+
* click handler, return Promise to autoset loading state
|
|
67
|
+
*/
|
|
68
|
+
onClick?: (e?: React.MouseEvent) => CallbackReturn;
|
|
69
|
+
/**
|
|
70
|
+
* badges
|
|
71
|
+
*/
|
|
72
|
+
badge?: string | number | BadgeType;
|
|
73
|
+
/**
|
|
74
|
+
* keyboard shortcut
|
|
75
|
+
*/
|
|
76
|
+
hotKey?: string;
|
|
77
|
+
onMouseOut?: MouseEventHandler;
|
|
78
|
+
onMouseOver?: MouseEventHandler;
|
|
79
|
+
onMouseMove?: MouseEventHandler;
|
|
80
|
+
onMouseEnter?: MouseEventHandler;
|
|
81
|
+
onMouseLeave?: MouseEventHandler;
|
|
82
|
+
onWheel?: WheelEventHandler;
|
|
83
|
+
}
|
|
84
|
+
export type ButtonProps = {
|
|
85
|
+
children: string | React.ReactElement;
|
|
86
|
+
"aria-label"?: string;
|
|
87
|
+
} | {
|
|
88
|
+
children?: never;
|
|
89
|
+
"aria-label": string;
|
|
90
|
+
};
|
|
91
|
+
/**
|
|
92
|
+
* Clickable action button
|
|
93
|
+
*/
|
|
94
|
+
export declare const Button: <Tag extends import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> = "button">({ as, ref, children, className, active, color, icon, iconBg, iconColor, iconAlign, altIcon, rtlFlip, rounded, size, disabled, loading, variant, badge, fullWidth, spinOnHover, onClick, actionMessage, type, hotKey, showActionDone, showActionDoneEvent, tabIndex, "data-ref": dataRef, ...aria }: BaseProps & ButtonProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type AriaProps, type ChildrenProp, type ColorType, type CssProp, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
|
+
import { type Button } from "./Button";
|
|
4
|
+
export interface ButtonGroupProps extends CssProp, AriaProps, TestProps, RefProp<HTMLDivElement>, ChildrenProp<React.ReactElement<typeof Button>> {
|
|
5
|
+
/**
|
|
6
|
+
* vertical orientation
|
|
7
|
+
*/
|
|
8
|
+
vertical?: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* button styling
|
|
11
|
+
*/
|
|
12
|
+
variant?: "outline" | "solid" | "link";
|
|
13
|
+
/**
|
|
14
|
+
* button size
|
|
15
|
+
*/
|
|
16
|
+
size?: SizeType;
|
|
17
|
+
/**
|
|
18
|
+
* button color
|
|
19
|
+
*/
|
|
20
|
+
color?: ColorType;
|
|
21
|
+
/**
|
|
22
|
+
* full rounded edges
|
|
23
|
+
*/
|
|
24
|
+
rounded?: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* disabled state
|
|
27
|
+
*/
|
|
28
|
+
disabled?: boolean;
|
|
29
|
+
/**
|
|
30
|
+
* stretch to full width
|
|
31
|
+
*/
|
|
32
|
+
fullWidth?: boolean;
|
|
33
|
+
}
|
|
34
|
+
export declare const ButtonGroup: ({ vertical, className, children, variant, rounded, disabled, fullWidth, color, size, ...aria }: ButtonGroupProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type CallbackReturn, type PolymorphicProps, type RefProp } from "../../types";
|
|
3
|
+
import { type BaseProps, type ButtonProps } from "./Button";
|
|
4
|
+
interface ExtendedProps extends Omit<BaseProps, "onClick">, RefProp {
|
|
5
|
+
/**
|
|
6
|
+
* confirm message
|
|
7
|
+
*/
|
|
8
|
+
message: string;
|
|
9
|
+
/**
|
|
10
|
+
* ok label
|
|
11
|
+
*/
|
|
12
|
+
okLabel?: string;
|
|
13
|
+
/**
|
|
14
|
+
* ok label
|
|
15
|
+
*/
|
|
16
|
+
cancelLabel?: string;
|
|
17
|
+
/**
|
|
18
|
+
* click handler, return Promise to autoset loading state
|
|
19
|
+
*/
|
|
20
|
+
onClick?: (e: boolean) => CallbackReturn;
|
|
21
|
+
}
|
|
22
|
+
export type ConfirmButtonProps = ExtendedProps & ButtonProps;
|
|
23
|
+
/**
|
|
24
|
+
* Button with confirmation dropdown
|
|
25
|
+
*/
|
|
26
|
+
export declare const ConfirmButton: <Tag extends import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> = "button">({ ref, message, color, okLabel, cancelLabel, onClick, loading, actionMessage, showActionDone, showActionDoneEvent, ...props }: ConfirmButtonProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
export {};
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type AriaProps, type ChildrenProp, type ColorType, type CssProp, type SizeType } from "../../types";
|
|
3
|
+
import { type ButtonProps } from "./Button";
|
|
4
|
+
interface BaseProps extends CssProp, AriaProps, ChildrenProp<React.ReactElement<ButtonProps & {
|
|
5
|
+
value: string;
|
|
6
|
+
}>> {
|
|
7
|
+
/**
|
|
8
|
+
* vertical orientation
|
|
9
|
+
*/
|
|
10
|
+
vertical?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* button styling
|
|
13
|
+
*/
|
|
14
|
+
variant?: "outline" | "solid" | "link";
|
|
15
|
+
/**
|
|
16
|
+
* button size
|
|
17
|
+
*/
|
|
18
|
+
size?: SizeType;
|
|
19
|
+
/**
|
|
20
|
+
* button color
|
|
21
|
+
*/
|
|
22
|
+
color?: ColorType;
|
|
23
|
+
/**
|
|
24
|
+
* full rounded edges
|
|
25
|
+
*/
|
|
26
|
+
rounded?: boolean;
|
|
27
|
+
/**
|
|
28
|
+
* disabled state
|
|
29
|
+
*/
|
|
30
|
+
disabled?: boolean;
|
|
31
|
+
/**
|
|
32
|
+
* stretch to full width
|
|
33
|
+
*/
|
|
34
|
+
fullWidth?: boolean;
|
|
35
|
+
}
|
|
36
|
+
export type ToggleButtonGroupProps = BaseProps & ({
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
*/
|
|
40
|
+
value: string;
|
|
41
|
+
/**
|
|
42
|
+
* change handler
|
|
43
|
+
*/
|
|
44
|
+
onChange?: (value: string) => void;
|
|
45
|
+
} | {
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
*/
|
|
49
|
+
value: string[];
|
|
50
|
+
/**
|
|
51
|
+
* change handler
|
|
52
|
+
*/
|
|
53
|
+
onChange?: (value: string[]) => void;
|
|
54
|
+
});
|
|
55
|
+
export declare const ToggleButtonGroup: ({ vertical, className, children, variant, rounded, disabled, fullWidth, color, size, value, onChange, ...aria }: ToggleButtonGroupProps) => import("react/jsx-runtime").JSX.Element;
|
|
56
|
+
export {};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { type AriaProps, type ChildrenProp, type ColorType, type PaletteType, type TestProps } from "../../types";
|
|
2
|
+
export interface CalloutProps extends AriaProps, ChildrenProp, TestProps {
|
|
3
|
+
/**
|
|
4
|
+
* callout color
|
|
5
|
+
*/
|
|
6
|
+
color?: ColorType | PaletteType;
|
|
7
|
+
/**
|
|
8
|
+
* legend title
|
|
9
|
+
*/
|
|
10
|
+
legend?: string;
|
|
11
|
+
/**
|
|
12
|
+
* callout icon
|
|
13
|
+
*/
|
|
14
|
+
icon?: string;
|
|
15
|
+
/**
|
|
16
|
+
* callout title
|
|
17
|
+
*/
|
|
18
|
+
title?: string;
|
|
19
|
+
/**
|
|
20
|
+
* callout border style
|
|
21
|
+
*/
|
|
22
|
+
border?: "solid" | "dotted" | "dashed";
|
|
23
|
+
/**
|
|
24
|
+
* close action handler
|
|
25
|
+
*/
|
|
26
|
+
onClose?: () => void;
|
|
27
|
+
}
|
|
28
|
+
export declare const Callout: ({ children, color, legend, title, icon, border, onClose, ...aria }: CalloutProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { type MouseEventHandler } from "react";
|
|
2
|
+
import { type ContentProps } from "../../core/content/Content";
|
|
3
|
+
import { type HeadFootProps } from "../../core/headfoot/HeadFoot";
|
|
4
|
+
import { type AriaProps, type ChildrenProp, type CssProp, type TestProps } from "../../types";
|
|
5
|
+
export interface CardProps extends CssProp, AriaProps, TestProps, ChildrenProp<React.ReactElement<HeadFootProps | ContentProps>> {
|
|
6
|
+
/**
|
|
7
|
+
* apply flex fill styling
|
|
8
|
+
*/
|
|
9
|
+
flex?: boolean;
|
|
10
|
+
/**
|
|
11
|
+
* click handler
|
|
12
|
+
*/
|
|
13
|
+
onClick?: MouseEventHandler;
|
|
14
|
+
/**
|
|
15
|
+
* body css classname(s)
|
|
16
|
+
*/
|
|
17
|
+
bodyClassName?: string;
|
|
18
|
+
/**
|
|
19
|
+
* show selected ring
|
|
20
|
+
*/
|
|
21
|
+
selected?: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* show tick mark ribbon
|
|
24
|
+
*/
|
|
25
|
+
selectedRibbon?: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* make card draggable
|
|
28
|
+
*/
|
|
29
|
+
draggable?: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* drag event data key
|
|
32
|
+
*/
|
|
33
|
+
dragKey?: string;
|
|
34
|
+
/**
|
|
35
|
+
* drag event data
|
|
36
|
+
*/
|
|
37
|
+
dragData?: KeyValue;
|
|
38
|
+
}
|
|
39
|
+
export declare const Card: ({ children, className, bodyClassName, selected, selectedRibbon, onClick, flex, draggable, dragKey, dragData, ...aria }: CardProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type AriaProps, type ChildrenProp, type CssProp } from "../../types";
|
|
2
|
+
export interface CardCoverProps extends CssProp, AriaProps, ChildrenProp {
|
|
3
|
+
/**
|
|
4
|
+
* cover height
|
|
5
|
+
*/
|
|
6
|
+
height?: string | number;
|
|
7
|
+
/**
|
|
8
|
+
* cover color scheme
|
|
9
|
+
*/
|
|
10
|
+
colorScheme?: "light" | "dark";
|
|
11
|
+
/**
|
|
12
|
+
* justify content
|
|
13
|
+
*/
|
|
14
|
+
justify?: "start" | "center" | "end";
|
|
15
|
+
}
|
|
16
|
+
export declare const CardCover: ({ className, children, height, justify, colorScheme, ...aria }: CardCoverProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { type ReactElement } from "react";
|
|
2
|
+
import { type AriaProps, type ChildProp, type ColorType, type CssProp, type IconProps, type PolymorphicProps, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
|
+
export interface ChipProps extends CssProp, AriaProps, IconProps, TestProps, ChildProp<string | ReactElement>, RefProp<HTMLDivElement> {
|
|
4
|
+
/**
|
|
5
|
+
* chip size
|
|
6
|
+
*/
|
|
7
|
+
size?: SizeType;
|
|
8
|
+
/**
|
|
9
|
+
* chip color (CSS color / tailwind color)
|
|
10
|
+
*/
|
|
11
|
+
color?: ColorType | string;
|
|
12
|
+
/**
|
|
13
|
+
* chip styling
|
|
14
|
+
*/
|
|
15
|
+
variant?: "solid" | "outline";
|
|
16
|
+
/**
|
|
17
|
+
* full rounded edges
|
|
18
|
+
*/
|
|
19
|
+
rounded?: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* disabled state
|
|
22
|
+
*/
|
|
23
|
+
disabled?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* prevent click propagation
|
|
26
|
+
*/
|
|
27
|
+
stopPropagation?: boolean;
|
|
28
|
+
/**
|
|
29
|
+
* click handler
|
|
30
|
+
*/
|
|
31
|
+
onClick?: React.MouseEventHandler;
|
|
32
|
+
/**
|
|
33
|
+
* icon click handler
|
|
34
|
+
*/
|
|
35
|
+
onIconClick?: React.MouseEventHandler;
|
|
36
|
+
/**
|
|
37
|
+
* remove handler
|
|
38
|
+
*/
|
|
39
|
+
onRemove?: React.MouseEventHandler;
|
|
40
|
+
}
|
|
41
|
+
export declare const Chip: <Tag extends import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> = "div">({ ref, children, className, size, color, variant, icon, iconBg, iconColor, rtlFlip, disabled, onClick, onIconClick, onRemove, rounded, stopPropagation, as, ...aria }: ChipProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { type RefObject } from "react";
|
|
2
|
+
import { type AriaProps, type ChildrenProp, type CssProp, type RefProp, type TestProps } from "../../types";
|
|
3
|
+
interface CollapsableRef {
|
|
4
|
+
button: RefObject<HTMLElement>;
|
|
5
|
+
body: RefObject<HTMLElement>;
|
|
6
|
+
open: boolean;
|
|
7
|
+
}
|
|
8
|
+
export interface CollapsableProps extends CssProp, AriaProps, TestProps, RefProp<CollapsableRef>, ChildrenProp {
|
|
9
|
+
/**
|
|
10
|
+
* expand icon alignment
|
|
11
|
+
*/
|
|
12
|
+
iconAlign?: "start" | "end";
|
|
13
|
+
/**
|
|
14
|
+
* panel body className
|
|
15
|
+
*/
|
|
16
|
+
bodyClassName?: string;
|
|
17
|
+
/**
|
|
18
|
+
* header button className
|
|
19
|
+
*/
|
|
20
|
+
headerClassName?: string;
|
|
21
|
+
/**
|
|
22
|
+
* open state icon
|
|
23
|
+
*/
|
|
24
|
+
iconOpen?: string;
|
|
25
|
+
/**
|
|
26
|
+
* closed state icon
|
|
27
|
+
*/
|
|
28
|
+
iconClosed?: string;
|
|
29
|
+
/**
|
|
30
|
+
* open state
|
|
31
|
+
*/
|
|
32
|
+
open?: boolean;
|
|
33
|
+
/**
|
|
34
|
+
* open handler
|
|
35
|
+
*/
|
|
36
|
+
onOpen?: () => void;
|
|
37
|
+
/**
|
|
38
|
+
* open handler
|
|
39
|
+
*/
|
|
40
|
+
onClose?: () => void;
|
|
41
|
+
}
|
|
42
|
+
export declare const Collapsable: ({ ref, className, bodyClassName, headerClassName, children, iconAlign, iconClosed, iconOpen, open, onClose, onOpen, ...aria }: CollapsableProps) => import("react/jsx-runtime").JSX.Element;
|
|
43
|
+
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { type CssProp, type ChildProp, type ColorType, type PaletteType } from "../../types";
|
|
2
|
+
export interface DividerProps extends CssProp, Partial<ChildProp> {
|
|
3
|
+
/**
|
|
4
|
+
* apply text bg
|
|
5
|
+
*/
|
|
6
|
+
fill?: boolean;
|
|
7
|
+
/**
|
|
8
|
+
* vertical rule
|
|
9
|
+
*/
|
|
10
|
+
vertical?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* rule color
|
|
13
|
+
*/
|
|
14
|
+
color?: ColorType | PaletteType | "tint";
|
|
15
|
+
/**
|
|
16
|
+
* text alignment
|
|
17
|
+
*/
|
|
18
|
+
align?: "start" | "end" | "center";
|
|
19
|
+
}
|
|
20
|
+
export declare const Divider: ({ children, color, vertical, fill, align, className, }: DividerProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type Placement } from "@floating-ui/react";
|
|
3
|
+
import { type ChildProp, type RefProp } from "../../types";
|
|
4
|
+
export interface DropdownProps extends RefProp {
|
|
5
|
+
children: [React.ReactNode, React.ReactNode];
|
|
6
|
+
/**
|
|
7
|
+
* dropdown placement
|
|
8
|
+
*/
|
|
9
|
+
placement?: Placement;
|
|
10
|
+
/**
|
|
11
|
+
* show dropdown arrow
|
|
12
|
+
*/
|
|
13
|
+
showArrow?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* fit with to anchor' parent element
|
|
16
|
+
*/
|
|
17
|
+
fitToParent?: boolean;
|
|
18
|
+
/**
|
|
19
|
+
* close dropdown on click
|
|
20
|
+
*/
|
|
21
|
+
closeOnClick?: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* disable dropdown
|
|
24
|
+
*/
|
|
25
|
+
disabled?: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* plain dropdown body
|
|
28
|
+
*/
|
|
29
|
+
plainDropdown?: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* dropdown body className
|
|
32
|
+
*/
|
|
33
|
+
dropdownClassName?: string;
|
|
34
|
+
/**
|
|
35
|
+
* dropdown event
|
|
36
|
+
*/
|
|
37
|
+
dropdownEvent?: "click" | "hover";
|
|
38
|
+
/**
|
|
39
|
+
* open handler
|
|
40
|
+
*/
|
|
41
|
+
onOpen?: () => void;
|
|
42
|
+
/**
|
|
43
|
+
* close handler
|
|
44
|
+
*/
|
|
45
|
+
onClose?: () => void;
|
|
46
|
+
}
|
|
47
|
+
export declare const Dropdown: (props: DropdownProps) => import("react/jsx-runtime").JSX.Element;
|
|
48
|
+
export declare const DropdownDismiss: ({ children, dismiss, }: ChildProp & {
|
|
49
|
+
dismiss?: boolean;
|
|
50
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { type ChildProp, type CssProp } from "../../types";
|
|
2
|
+
import { type DropdownProps } from "./Dropdown";
|
|
3
|
+
export declare const DropdownTool: ({ children, className, groupHover, ...props }: ChildProp & CssProp & Omit<DropdownProps, "children"> & {
|
|
4
|
+
/**
|
|
5
|
+
* hide until group hovered
|
|
6
|
+
*/
|
|
7
|
+
groupHover?: boolean;
|
|
8
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type ChildrenProp, type CssProp, type TestProps } from "../../types";
|
|
3
|
+
export interface EmptyContentProps extends CssProp, TestProps, Partial<ChildrenProp> {
|
|
4
|
+
/**
|
|
5
|
+
* empty title
|
|
6
|
+
*/
|
|
7
|
+
title?: string | JSX.Element;
|
|
8
|
+
/**
|
|
9
|
+
* empty message
|
|
10
|
+
*/
|
|
11
|
+
message: string | JSX.Element;
|
|
12
|
+
/**
|
|
13
|
+
* content size
|
|
14
|
+
*/
|
|
15
|
+
size?: "sm" | "md";
|
|
16
|
+
/**
|
|
17
|
+
* empty icon
|
|
18
|
+
*/
|
|
19
|
+
icon?: string | React.ReactElement;
|
|
20
|
+
}
|
|
21
|
+
export declare const EmptyContent: ({ children, title, message, icon, className, size, ...test }: EmptyContentProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type AriaProps, type ColorType, type CssProp, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
|
+
export interface IconProps extends CssProp, AriaProps, RefProp, TestProps {
|
|
4
|
+
/**
|
|
5
|
+
* svg path / webfont className / 1-4 letter text
|
|
6
|
+
*/
|
|
7
|
+
icon: string;
|
|
8
|
+
/**
|
|
9
|
+
* background color (CSS color / tailwind color)
|
|
10
|
+
*/
|
|
11
|
+
bg?: ColorType | string;
|
|
12
|
+
/**
|
|
13
|
+
* icon color (CSS color / tailwind color)
|
|
14
|
+
*/
|
|
15
|
+
color?: ColorType | string;
|
|
16
|
+
/**
|
|
17
|
+
* flip icon in rtl
|
|
18
|
+
*/
|
|
19
|
+
rtlFlip?: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* icon size
|
|
22
|
+
*/
|
|
23
|
+
size?: SizeType | number | string;
|
|
24
|
+
/**
|
|
25
|
+
* viewbox for svg path (default 24)
|
|
26
|
+
*/
|
|
27
|
+
viewBox?: string;
|
|
28
|
+
/**
|
|
29
|
+
* rounded icon
|
|
30
|
+
*/
|
|
31
|
+
rounded?: boolean;
|
|
32
|
+
/**
|
|
33
|
+
* apply animation
|
|
34
|
+
*/
|
|
35
|
+
animate?: "spin" | "pulse" | "bounce";
|
|
36
|
+
/**
|
|
37
|
+
* click handler
|
|
38
|
+
*/
|
|
39
|
+
onClick?: React.MouseEventHandler;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* An icon is a display component for svg icon path / image
|
|
43
|
+
*/
|
|
44
|
+
export declare const Icon: ({ ref, icon, bg, color, size, rtlFlip, animate, rounded, viewBox, className, onClick, ...rest }: IconProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export { ActionLabel } from "./actionLabel/ActionLabel";
|
|
2
|
+
export { AnimationBars, AnimationIndicator, AnimationSpinner, Skeleton, } from "./animations/Animations";
|
|
3
|
+
export { Avatar } from "./avatar/Avatar";
|
|
4
|
+
export { AvatarGroup } from "./avatar/AvatarGroup";
|
|
5
|
+
export { Badge, getBadgeProps } from "./badge/Badge";
|
|
6
|
+
export { Breadcrumbs } from "./breadcrumbs/Breadcrumbs";
|
|
7
|
+
export { Button } from "./button/Button";
|
|
8
|
+
export { ButtonGroup } from "./button/ButtonGroup";
|
|
9
|
+
export { ConfirmButton } from "./button/ConfirmButton";
|
|
10
|
+
export { ToggleButtonGroup } from "./button/ToggleButtonGroup";
|
|
11
|
+
export { Callout } from "./callout/Callout";
|
|
12
|
+
export { Card } from "./card/Card";
|
|
13
|
+
export { CardCover } from "./card/CardCover";
|
|
14
|
+
export { Chip } from "./chip/Chip";
|
|
15
|
+
export { Collapsable } from "./collapsable/Collapsable";
|
|
16
|
+
export { Divider } from "./divider/Divider";
|
|
17
|
+
export { Dropdown, DropdownDismiss } from "./dropdown/Dropdown";
|
|
18
|
+
export { DropdownTool } from "./dropdown/DropdownTool";
|
|
19
|
+
export { EmptyContent } from "./empty/EmptyContent";
|
|
20
|
+
export { Icon } from "./icon/Icon";
|
|
21
|
+
export { Image, Video } from "./media/Media";
|
|
22
|
+
export { ContextMenu } from "./menu/ContextMenu";
|
|
23
|
+
export { Menu } from "./menu/Menu";
|
|
24
|
+
export { MenuItem } from "./menu/MenuItem";
|
|
25
|
+
export { Meter } from "./meter/Meter";
|
|
26
|
+
export { Navigator } from "./navigator/Navigator";
|
|
27
|
+
export { Panel } from "./panel/Panel";
|
|
28
|
+
export { PanelGroup } from "./panel/PanelGroup";
|
|
29
|
+
export { PanelStack } from "./panel/PanelStack";
|
|
30
|
+
export { ProgressBar } from "./progress/ProgressBar";
|
|
31
|
+
export { ProgressCircle } from "./progress/ProgressCircle";
|
|
32
|
+
export { Tab } from "./tabpanel/Tab";
|
|
33
|
+
export { TabPanel } from "./tabpanel/TabPanel";
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { type AriaProps, type CssProp } from "../../types";
|
|
2
|
+
export interface BaseProps extends CssProp, AriaProps {
|
|
3
|
+
/**
|
|
4
|
+
* media source
|
|
5
|
+
*/
|
|
6
|
+
src: string;
|
|
7
|
+
/**
|
|
8
|
+
* show media reel decoration
|
|
9
|
+
*/
|
|
10
|
+
reel?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* media content fit
|
|
13
|
+
*/
|
|
14
|
+
fit?: "cover" | "contain" | "fill";
|
|
15
|
+
}
|
|
16
|
+
export interface ImageProps extends BaseProps {
|
|
17
|
+
/**
|
|
18
|
+
* image alt text
|
|
19
|
+
*/
|
|
20
|
+
alt?: string;
|
|
21
|
+
}
|
|
22
|
+
export interface VideoProps extends BaseProps {
|
|
23
|
+
/**
|
|
24
|
+
* video poster
|
|
25
|
+
*/
|
|
26
|
+
poster?: string;
|
|
27
|
+
/**
|
|
28
|
+
* auto play video
|
|
29
|
+
*/
|
|
30
|
+
autoPlay?: boolean;
|
|
31
|
+
/**
|
|
32
|
+
* play on mouse over
|
|
33
|
+
*/
|
|
34
|
+
playOnHover?: boolean;
|
|
35
|
+
}
|
|
36
|
+
export declare const Image: ({ src, alt, reel, fit, className, ...aria }: ImageProps) => import("react/jsx-runtime").JSX.Element;
|
|
37
|
+
export declare const Video: ({ src, poster, reel, autoPlay, playOnHover, fit, className, ...aria }: VideoProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type ChildrenProp } from "../../types";
|
|
3
|
+
import { type Menu } from "./Menu";
|
|
4
|
+
export interface ContextMenuProps extends ChildrenProp {
|
|
5
|
+
menu: React.ReactElement<typeof Menu>;
|
|
6
|
+
}
|
|
7
|
+
export declare const ContextMenu: ({ children, menu }: ContextMenuProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type PolymorphicProps } from "../../types";
|
|
3
|
+
import { type MenuItemProps } from "./types";
|
|
4
|
+
export declare const MenuItem: <Tag extends import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> = "button">({ as, label, color, className, icon, iconBg, iconColor, appendLabel, rtlFlip, altIcon, id, active, disabled, onClick, badge, hotKey, minimal, "data-open": childOpen, ref, ...aria }: MenuItemProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
|