@react-fabric/core 1.0.0-beta.4 → 1.0.0-beta.41
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} +49 -44
- package/{src/components/button/Button.module.css → css/components/_button.css} +68 -78
- package/{src/components/card/Card.module.css → css/components/_card.css} +32 -28
- package/{src/components/chip/Chip.module.css → css/components/_chip.css} +15 -11
- package/{src/components/collapsable/Collapsable.module.css → css/components/_collapsable.css} +3 -3
- package/css/components/_divider.css +32 -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} +8 -5
- package/{src/components/media/Media.module.css → css/components/_media.css} +17 -17
- package/{src/components/menu/Menu.module.css → css/components/_menu.css} +15 -16
- 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} +6 -6
- 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/{src/components/tabpanel/TabPanel.module.css → css/components/_tabPanel.css} +73 -84
- 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} +25 -18
- package/{src/core/aside/Aside.module.css → css/core/_aside.css} +42 -42
- 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 +41 -223
- package/css/reset/_text.css +14 -29
- package/css/reset/_theme.css +315 -32
- 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 +530 -0
- package/css/theme/index.css +44 -0
- package/dist/cjs/components/actionLabel/ActionLabel.js +3 -3
- package/dist/cjs/components/animations/Animations.js +29 -18
- package/dist/cjs/components/avatar/Avatar.js +10 -13
- package/dist/cjs/components/avatar/AvatarGroup.js +3 -3
- package/dist/cjs/components/badge/Badge.js +5 -5
- package/dist/cjs/components/breadcrumbs/Breadcrumbs.js +10 -8
- package/dist/cjs/components/button/Button.js +18 -14
- package/dist/cjs/components/button/ButtonGroup.js +4 -3
- package/dist/cjs/components/button/ConfirmButton.js +7 -2
- package/dist/cjs/components/button/ToggleButtonGroup.js +3 -3
- package/dist/cjs/components/callout/Callout.js +15 -4
- package/dist/cjs/components/card/Card.js +8 -7
- package/dist/cjs/components/card/CardCover.js +10 -5
- package/dist/cjs/components/chip/Chip.js +11 -7
- package/dist/cjs/components/collapsable/Collapsable.js +5 -5
- package/dist/cjs/components/divider/Divider.js +10 -7
- package/dist/cjs/components/dropdown/Dropdown.js +5 -4
- package/dist/cjs/components/dropdown/DropdownTool.js +4 -3
- package/dist/cjs/components/empty/EmptyContent.js +6 -3
- package/dist/cjs/components/icon/Icon.js +15 -14
- package/dist/cjs/components/media/Media.js +116 -75
- package/dist/cjs/components/menu/ContextMenu.js +30 -10
- package/dist/cjs/components/menu/Menu.js +39 -20
- package/dist/cjs/components/menu/MenuItem.js +30 -16
- package/dist/cjs/components/meter/Meter.js +2 -3
- package/dist/cjs/components/navigator/Navigator.js +16 -9
- package/dist/cjs/components/panel/Panel.js +10 -9
- package/dist/cjs/components/panel/PanelGroup.js +1 -2
- package/dist/cjs/components/progress/ProgressBar.js +6 -5
- package/dist/cjs/components/progress/ProgressCircle.js +6 -4
- package/dist/cjs/components/tabpanel/Tab.js +58 -38
- package/dist/cjs/components/tabpanel/TabPanel.js +20 -16
- package/dist/cjs/core/aside/Aside.js +11 -10
- package/dist/cjs/core/boundary/ErrorBoundary.js +6 -7
- package/dist/cjs/core/boundary/ErrorIcon.js +1 -2
- package/dist/cjs/core/content/Content.js +9 -7
- package/dist/cjs/core/headfoot/HeadFoot.js +2 -20
- package/dist/cjs/core/page/Page.js +3 -3
- package/dist/cjs/core/responsive/Responsive.js +3 -4
- package/dist/cjs/core/section/Section.js +1 -2
- package/dist/cjs/core/theme/ThemeProvider.js +7 -8
- package/dist/cjs/core/viewport/Viewport.js +4 -2
- package/dist/cjs/hooks/useNavigator.js +6 -4
- package/dist/cjs/hotkeys/HotKeyLabel.js +1 -1
- package/dist/cjs/hotkeys/HotKeyWrapper.js +3 -1
- package/dist/cjs/index.js +6 -2
- package/dist/cjs/overlays/alert/Alert.js +19 -13
- package/dist/cjs/overlays/flyout/Flyout.js +49 -60
- package/dist/cjs/overlays/message/Message.js +6 -3
- package/dist/cjs/overlays/modal/Modal.js +11 -11
- package/dist/cjs/overlays/toast/Toast.js +17 -9
- package/dist/cjs/overlays/tooltip/Tooltip.js +20 -8
- package/dist/cjs/types/icons.js +4 -0
- package/dist/cjs/typography/Abbr.js +2 -3
- package/dist/cjs/typography/{Link.js → Anchor.js} +5 -4
- package/dist/cjs/typography/Mark.js +2 -3
- package/dist/cjs/typography/Text.js +3 -4
- package/dist/cjs/typography/Title.js +3 -3
- package/dist/cjs/utils/cloneElement.js +44 -0
- package/dist/cjs/utils/getColor.js +1 -18
- package/dist/esm/components/actionLabel/ActionLabel.js +3 -3
- package/dist/esm/components/animations/Animations.js +30 -19
- package/dist/esm/components/avatar/Avatar.js +11 -14
- package/dist/esm/components/avatar/AvatarGroup.js +3 -3
- package/dist/esm/components/badge/Badge.js +5 -5
- package/dist/esm/components/breadcrumbs/Breadcrumbs.js +10 -8
- package/dist/esm/components/button/Button.js +18 -14
- package/dist/esm/components/button/ButtonGroup.js +5 -4
- package/dist/esm/components/button/ConfirmButton.js +7 -2
- package/dist/esm/components/button/ToggleButtonGroup.js +4 -4
- package/dist/esm/components/callout/Callout.js +15 -4
- package/dist/esm/components/card/Card.js +8 -7
- package/dist/esm/components/card/CardCover.js +10 -5
- package/dist/esm/components/chip/Chip.js +12 -8
- package/dist/esm/components/collapsable/Collapsable.js +5 -5
- package/dist/esm/components/divider/Divider.js +11 -8
- package/dist/esm/components/dropdown/Dropdown.js +5 -4
- package/dist/esm/components/dropdown/DropdownTool.js +4 -3
- package/dist/esm/components/empty/EmptyContent.js +6 -3
- package/dist/esm/components/icon/Icon.js +15 -14
- package/dist/esm/components/media/Media.js +117 -76
- package/dist/esm/components/menu/ContextMenu.js +32 -12
- package/dist/esm/components/menu/Menu.js +41 -22
- package/dist/esm/components/menu/MenuItem.js +24 -10
- package/dist/esm/components/meter/Meter.js +2 -3
- package/dist/esm/components/navigator/Navigator.js +16 -9
- package/dist/esm/components/panel/Panel.js +10 -9
- package/dist/esm/components/panel/PanelGroup.js +1 -2
- package/dist/esm/components/progress/ProgressBar.js +6 -5
- package/dist/esm/components/progress/ProgressCircle.js +6 -4
- package/dist/esm/components/tabpanel/Tab.js +59 -39
- package/dist/esm/components/tabpanel/TabPanel.js +20 -16
- package/dist/esm/core/aside/Aside.js +11 -10
- package/dist/esm/core/boundary/ErrorBoundary.js +6 -7
- package/dist/esm/core/boundary/ErrorIcon.js +1 -2
- package/dist/esm/core/content/Content.js +9 -7
- package/dist/esm/core/headfoot/HeadFoot.js +2 -20
- package/dist/esm/core/page/Page.js +3 -3
- package/dist/esm/core/responsive/Responsive.js +3 -4
- package/dist/esm/core/section/Section.js +1 -2
- package/dist/esm/core/theme/ThemeProvider.js +7 -8
- package/dist/esm/core/viewport/Viewport.js +4 -2
- package/dist/esm/hooks/useNavigator.js +7 -5
- package/dist/esm/hotkeys/HotKeyLabel.js +1 -1
- package/dist/esm/hotkeys/HotKeyWrapper.js +3 -1
- package/dist/esm/index.js +3 -1
- package/dist/esm/overlays/alert/Alert.js +20 -14
- package/dist/esm/overlays/flyout/Flyout.js +52 -63
- package/dist/esm/overlays/message/Message.js +7 -4
- package/dist/esm/overlays/modal/Modal.js +12 -12
- package/dist/esm/overlays/toast/Toast.js +18 -10
- package/dist/esm/overlays/tooltip/Tooltip.js +20 -8
- package/dist/esm/types/icons.js +4 -0
- package/dist/esm/typography/Abbr.js +2 -3
- package/dist/esm/typography/{Link.js → Anchor.js} +6 -5
- package/dist/esm/typography/Mark.js +2 -3
- package/dist/esm/typography/Text.js +4 -5
- package/dist/esm/typography/Title.js +4 -4
- package/dist/esm/utils/cloneElement.js +44 -0
- package/dist/esm/utils/getColor.js +2 -16
- package/dist/types/components/actionLabel/ActionLabel.d.ts +2 -2
- package/dist/types/components/animations/Animations.d.ts +5 -5
- package/dist/types/components/avatar/Avatar.d.ts +3 -3
- package/dist/types/components/badge/Badge.d.ts +5 -1
- package/dist/types/components/breadcrumbs/Breadcrumbs.d.ts +2 -2
- package/dist/types/components/button/Button.d.ts +7 -5
- package/dist/types/components/button/ButtonGroup.d.ts +2 -2
- package/dist/types/components/button/ConfirmButton.d.ts +6 -1
- package/dist/types/components/callout/Callout.d.ts +2 -2
- package/dist/types/components/card/Card.d.ts +3 -3
- package/dist/types/components/chip/Chip.d.ts +3 -3
- package/dist/types/components/collapsable/Collapsable.d.ts +5 -1
- package/dist/types/components/divider/Divider.d.ts +7 -3
- package/dist/types/components/dropdown/DropdownTool.d.ts +2 -1
- package/dist/types/components/empty/EmptyContent.d.ts +6 -2
- package/dist/types/components/icon/Icon.d.ts +3 -3
- package/dist/types/components/media/Media.d.ts +2 -2
- package/dist/types/components/menu/ContextMenu.d.ts +2 -1
- package/dist/types/components/menu/MenuItem.d.ts +1 -1
- package/dist/types/components/menu/types.d.ts +2 -2
- package/dist/types/components/navigator/Navigator.d.ts +4 -4
- package/dist/types/components/progress/ProgressBar.d.ts +2 -2
- package/dist/types/components/progress/ProgressCircle.d.ts +2 -2
- package/dist/types/components/tabpanel/Tab.d.ts +5 -5
- package/dist/types/components/tabpanel/TabPanel.d.ts +10 -1
- package/dist/types/core/content/Content.d.ts +3 -2
- package/dist/types/core/headfoot/HeadFoot.d.ts +1 -9
- package/dist/types/core/responsive/Responsive.d.ts +1 -1
- package/dist/types/core/theme/ThemeProvider.d.ts +4 -4
- package/dist/types/hooks/useOverlayService.d.ts +3 -5
- package/dist/types/index.d.ts +3 -0
- package/dist/types/overlays/alert/Alert.d.ts +2 -2
- package/dist/types/overlays/flyout/Flyout.d.ts +3 -2
- package/dist/types/overlays/message/Message.d.ts +2 -2
- package/dist/types/overlays/modal/Modal.d.ts +4 -3
- package/dist/types/overlays/toast/Toast.d.ts +2 -2
- package/dist/types/overlays/tooltip/Tooltip.d.ts +1 -1
- package/dist/types/types/icons.d.ts +4 -0
- package/dist/types/types/index.d.ts +18 -6
- package/dist/types/typography/Abbr.d.ts +6 -2
- package/dist/types/typography/Anchor.d.ts +25 -0
- package/dist/types/typography/Mark.d.ts +2 -2
- package/dist/types/typography/index.d.ts +1 -1
- package/dist/types/utils/cloneElement.d.ts +2 -0
- package/dist/types/utils/getColor.d.ts +1 -4
- package/dist/types/utils/index.d.ts +1 -0
- package/package.json +7 -9
- package/src/components/actionLabel/ActionLabel.tsx +15 -6
- package/src/components/animations/Animations.tsx +29 -23
- package/src/components/avatar/Avatar.tsx +74 -88
- package/src/components/avatar/AvatarGroup.tsx +4 -4
- package/src/components/badge/Badge.tsx +11 -7
- package/src/components/breadcrumbs/Breadcrumbs.tsx +13 -9
- package/src/components/button/Button.tsx +27 -22
- package/src/components/button/ButtonGroup.tsx +7 -7
- package/src/components/button/ConfirmButton.tsx +15 -5
- package/src/components/button/ToggleButtonGroup.tsx +5 -5
- package/src/components/callout/Callout.tsx +26 -11
- package/src/components/card/Card.tsx +10 -7
- package/src/components/card/CardCover.tsx +11 -6
- package/src/components/chip/Chip.tsx +17 -13
- package/src/components/collapsable/Collapsable.tsx +9 -4
- package/src/components/divider/Divider.tsx +15 -10
- package/src/components/dropdown/Dropdown.tsx +5 -5
- package/src/components/dropdown/DropdownTool.tsx +5 -3
- package/src/components/empty/EmptyContent.tsx +17 -2
- package/src/components/icon/Icon.tsx +55 -67
- package/src/components/media/Media.tsx +141 -106
- package/src/components/menu/ContextMenu.tsx +36 -11
- package/src/components/menu/Menu.tsx +51 -30
- package/src/components/menu/MenuItem.tsx +19 -9
- package/src/components/menu/types.ts +2 -2
- package/src/components/meter/Meter.tsx +2 -3
- package/src/components/navigator/Navigator.tsx +19 -5
- package/src/components/panel/Panel.tsx +10 -9
- package/src/components/panel/PanelGroup.tsx +1 -2
- package/src/components/progress/ProgressBar.tsx +8 -9
- package/src/components/progress/ProgressCircle.tsx +6 -9
- package/src/components/tabpanel/Tab.tsx +81 -64
- package/src/components/tabpanel/TabPanel.tsx +34 -12
- package/src/core/aside/Aside.tsx +11 -10
- package/src/core/boundary/ErrorBoundary.tsx +8 -7
- package/src/core/boundary/ErrorIcon.tsx +1 -2
- package/src/core/content/Content.tsx +17 -12
- package/src/core/headfoot/HeadFoot.tsx +2 -35
- package/src/core/page/Page.tsx +3 -3
- package/src/core/responsive/Responsive.tsx +8 -7
- package/src/core/section/Section.tsx +1 -2
- package/src/core/theme/ThemeProvider.tsx +11 -12
- package/src/core/viewport/Viewport.tsx +1 -2
- package/src/hooks/useNavigator.tsx +10 -5
- package/src/hooks/useOverlayService.tsx +12 -6
- package/src/hotkeys/HotKeyLabel.tsx +1 -1
- package/src/hotkeys/HotKeyWrapper.tsx +3 -1
- package/src/index.ts +4 -0
- package/src/overlays/alert/Alert.tsx +25 -31
- package/src/overlays/flyout/Flyout.tsx +71 -84
- package/src/overlays/message/Message.tsx +10 -7
- package/src/overlays/modal/Modal.tsx +20 -15
- package/src/overlays/toast/Toast.tsx +18 -27
- package/src/overlays/tooltip/Tooltip.tsx +30 -9
- package/src/types/icons.ts +9 -0
- package/src/types/index.ts +251 -27
- package/src/typography/Abbr.tsx +15 -9
- package/src/typography/{Link.tsx → Anchor.tsx} +8 -13
- package/src/typography/Mark.tsx +4 -9
- package/src/typography/Text.tsx +4 -12
- package/src/typography/Title.tsx +2 -6
- package/src/typography/index.ts +1 -1
- package/src/utils/cloneElement.ts +44 -0
- 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
- package/src/overlays/tooltip/Tooltip.module.css +0 -53
|
@@ -10,10 +10,9 @@ import { useTranslation } from 'react-i18next';
|
|
|
10
10
|
import { useLayoutEffectDebugger, useMemoDebugger } from '../hooks/useEffectDebugger.js';
|
|
11
11
|
import { usePropToggle } from '../hooks/usePropToggle.js';
|
|
12
12
|
import { calculateTextHeight } from '../utils/calculateDimensions.js';
|
|
13
|
-
import { getColor, getBgClass, getColorClass } from '../utils/getColor.js';
|
|
14
|
-
import classes from './Typography.module.css';
|
|
15
|
-
import { TextSizeMap } from './types.js';
|
|
16
13
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
14
|
+
import { getColor } from '../utils/getColor.js';
|
|
15
|
+
import { TextSizeMap } from './types.js';
|
|
17
16
|
|
|
18
17
|
var _excluded = ["children", "className", "inline", "bg", "color", "family", "size", "clamp", "align"];
|
|
19
18
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
@@ -98,13 +97,13 @@ var Text = function Text(_ref) {
|
|
|
98
97
|
"--text-clamp": showMore ? "unset" : clamp !== null && clamp !== void 0 ? clamp : "unset"
|
|
99
98
|
},
|
|
100
99
|
children: /*#__PURE__*/jsx("div", _objectSpread(_objectSpread({
|
|
101
|
-
className: classNames(
|
|
100
|
+
className: classNames("fabric-text", "mixed-lang px-[2px] whitespace-pre-wrap", family && "font-".concat(family), clamp && "line-clamp-1"),
|
|
102
101
|
style: styles
|
|
103
102
|
}, aria), {}, {
|
|
104
103
|
children: children
|
|
105
104
|
}))
|
|
106
105
|
}), clipped && /*#__PURE__*/jsx("div", {
|
|
107
|
-
className:
|
|
106
|
+
className: "fabric-moreLink",
|
|
108
107
|
children: /*#__PURE__*/jsxs("span", {
|
|
109
108
|
role: "link",
|
|
110
109
|
tabIndex: 0,
|
|
@@ -4,11 +4,11 @@ import _defineProperty from '@babel/runtime/helpers/defineProperty';
|
|
|
4
4
|
import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
|
|
5
5
|
import classNames from 'classnames';
|
|
6
6
|
import { useMemoDebugger } from '../hooks/useEffectDebugger.js';
|
|
7
|
-
import
|
|
7
|
+
import 'react';
|
|
8
|
+
import { jsx } from 'react/jsx-runtime';
|
|
9
|
+
import { getColor } from '../utils/getColor.js';
|
|
8
10
|
import '@react-fabric/utilities';
|
|
9
11
|
import { TitleSizeMap } from './types.js';
|
|
10
|
-
import classes from './Typography.module.css';
|
|
11
|
-
import { jsx } from 'react/jsx-runtime';
|
|
12
12
|
|
|
13
13
|
var _excluded = ["children", "className", "as", "bg", "color", "size", "align", "family"];
|
|
14
14
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
@@ -48,7 +48,7 @@ var Title = function Title(_ref) {
|
|
|
48
48
|
}, [bg, color, size, align], "Title styles");
|
|
49
49
|
var E = as !== null && as !== void 0 ? as : "p";
|
|
50
50
|
return /*#__PURE__*/jsx(E, _objectSpread(_objectSpread({
|
|
51
|
-
className: classNames(
|
|
51
|
+
className: classNames("fabric-title", className, family && "font-".concat(family), !as && "text-lg"),
|
|
52
52
|
style: styles
|
|
53
53
|
}, aria), {}, {
|
|
54
54
|
children: children
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { Children, isValidElement } from 'react';
|
|
4
|
+
import { Fragment } from 'react/jsx-runtime';
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* React Fabric
|
|
8
|
+
* @version: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* The MIT License (MIT)
|
|
12
|
+
* Copyright (c) 2024 Adarsh Pastakia
|
|
13
|
+
*
|
|
14
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software
|
|
15
|
+
* and associated documentation files (the "Software"), to deal in the Software without restriction,
|
|
16
|
+
* including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
|
17
|
+
* and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so,
|
|
18
|
+
* subject to the following conditions:
|
|
19
|
+
*
|
|
20
|
+
* The above copyright notice and this permission notice shall be included in all copies or substantial
|
|
21
|
+
* portions of the Software.
|
|
22
|
+
*
|
|
23
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
|
|
24
|
+
* TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
|
25
|
+
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
|
26
|
+
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
27
|
+
*/
|
|
28
|
+
|
|
29
|
+
var cloneChildren = function cloneChildren(children, callback) {
|
|
30
|
+
var _Children$map;
|
|
31
|
+
return (_Children$map = Children.map(children, function (c) {
|
|
32
|
+
if ( /*#__PURE__*/isValidElement(c)) {
|
|
33
|
+
if (c.type === Fragment) {
|
|
34
|
+
var _c$props;
|
|
35
|
+
// just compare to `Fragment`
|
|
36
|
+
return cloneChildren((_c$props = c.props) === null || _c$props === void 0 ? void 0 : _c$props.children, callback);
|
|
37
|
+
}
|
|
38
|
+
return c;
|
|
39
|
+
}
|
|
40
|
+
return c;
|
|
41
|
+
})) === null || _Children$map === void 0 ? void 0 : _Children$map.flat().filter(Boolean).map(callback);
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
export { cloneChildren };
|
|
@@ -29,21 +29,7 @@ var getColor = function getColor(color) {
|
|
|
29
29
|
if (color && isColor(color)) {
|
|
30
30
|
return color;
|
|
31
31
|
}
|
|
32
|
-
|
|
33
|
-
var getBgClass = function getBgClass(bg) {
|
|
34
|
-
if (bg && !isColor(bg)) {
|
|
35
|
-
return "bg-".concat(bg);
|
|
36
|
-
}
|
|
37
|
-
};
|
|
38
|
-
var getColorClass = function getColorClass(color) {
|
|
39
|
-
if (color && !isColor(color)) {
|
|
40
|
-
return "text-".concat(color);
|
|
41
|
-
}
|
|
42
|
-
};
|
|
43
|
-
var getBorderClass = function getBorderClass(color) {
|
|
44
|
-
if (color && !isColor(color)) {
|
|
45
|
-
return "border-".concat(color);
|
|
46
|
-
}
|
|
32
|
+
return "var(--color-".concat(color, ")");
|
|
47
33
|
};
|
|
48
34
|
|
|
49
|
-
export {
|
|
35
|
+
export { getColor };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type ReactElement } from "react";
|
|
2
|
-
import { type AriaProps, type ChildProp, type CssProp } from "../../types";
|
|
3
|
-
export interface ActionLabelProps extends AriaProps, CssProp, ChildProp {
|
|
2
|
+
import { type AriaProps, type ChildProp, type CssProp, type TestProps } from "../../types";
|
|
3
|
+
export interface ActionLabelProps extends AriaProps, CssProp, ChildProp, TestProps {
|
|
4
4
|
/**
|
|
5
5
|
* action buttons aligment
|
|
6
6
|
*/
|
|
@@ -4,20 +4,20 @@ export interface AnimationProps extends CssProp, AriaProps {
|
|
|
4
4
|
/**
|
|
5
5
|
* icon color
|
|
6
6
|
*/
|
|
7
|
-
color?: ColorType | PaletteType;
|
|
7
|
+
color?: ColorType | PaletteType | string;
|
|
8
8
|
/**
|
|
9
9
|
* icon mark color
|
|
10
10
|
*/
|
|
11
|
-
strokeColor?: ColorType | PaletteType;
|
|
11
|
+
strokeColor?: ColorType | PaletteType | string;
|
|
12
12
|
}
|
|
13
13
|
export declare const AnimationIndicator: ({ className, color, strokeColor, type, ...aria }: AnimationProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
14
|
export declare const AnimationBars: ({ color, size, }: {
|
|
15
|
-
color?: ColorType | string;
|
|
15
|
+
color?: ColorType | PaletteType | string;
|
|
16
16
|
size?: number | string;
|
|
17
17
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
18
18
|
export declare const AnimationSpinner: ({ color, size, }: {
|
|
19
|
-
color?: ColorType | string;
|
|
19
|
+
color?: ColorType | PaletteType | string;
|
|
20
20
|
size?: number | string;
|
|
21
21
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
22
22
|
export declare const Loading: () => import("react/jsx-runtime").JSX.Element;
|
|
23
|
-
export declare const Skeleton: () => import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
export declare const Skeleton: ({ className, ...rest }: CssProp) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { type AriaProps, type ColorType, type CssProp, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
2
|
+
import { type PaletteType, type AriaProps, type ColorType, type CssProp, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
3
|
export interface AvatarProps extends CssProp, AriaProps, TestProps, RefProp {
|
|
4
4
|
/**
|
|
5
5
|
* avatar name for generated fallback
|
|
@@ -20,11 +20,11 @@ export interface AvatarProps extends CssProp, AriaProps, TestProps, RefProp {
|
|
|
20
20
|
/**
|
|
21
21
|
* background color (CSS color / tailwind color)
|
|
22
22
|
*/
|
|
23
|
-
bg?: ColorType | string;
|
|
23
|
+
bg?: ColorType | PaletteType | string;
|
|
24
24
|
/**
|
|
25
25
|
* icon color (CSS color / tailwind color)
|
|
26
26
|
*/
|
|
27
|
-
color?: ColorType | string;
|
|
27
|
+
color?: ColorType | PaletteType | string;
|
|
28
28
|
/**
|
|
29
29
|
* icon size
|
|
30
30
|
*/
|
|
@@ -4,6 +4,10 @@ export interface BadgeProps extends CssProp, RefProp, IconProps, Partial<ChildPr
|
|
|
4
4
|
* make wrapper a block element
|
|
5
5
|
*/
|
|
6
6
|
block?: boolean;
|
|
7
|
+
/**
|
|
8
|
+
* inline badge
|
|
9
|
+
*/
|
|
10
|
+
inline?: boolean;
|
|
7
11
|
/**
|
|
8
12
|
* badge value
|
|
9
13
|
*/
|
|
@@ -22,4 +26,4 @@ export interface BadgeProps extends CssProp, RefProp, IconProps, Partial<ChildPr
|
|
|
22
26
|
placement?: "top-start" | "top-end" | "bottom-start" | "bottom-end" | "top" | "bottom" | "start" | "end";
|
|
23
27
|
}
|
|
24
28
|
export declare const getBadgeProps: (badge?: string | number | BadgeType) => AnyObject;
|
|
25
|
-
export declare const Badge: ({ ref, className, value, max, ping, block, placement, children, forButton, icon, iconBg, iconColor, rtlFlip, ...rest }: BadgeProps) => import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
export declare const Badge: ({ ref, className, value, max, ping, block, inline, placement, children, forButton, icon, iconBg, iconColor, rtlFlip, ...rest }: BadgeProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type AriaProps, type ChildrenProp, type CssProp } from "../../types";
|
|
2
|
-
import {
|
|
3
|
-
export interface BreadcrumbProps extends CssProp, AriaProps, ChildrenProp<typeof
|
|
2
|
+
import { Anchor } from "../../typography/Anchor";
|
|
3
|
+
export interface BreadcrumbProps extends CssProp, AriaProps, ChildrenProp<typeof Anchor> {
|
|
4
4
|
/**
|
|
5
5
|
* breadcrumb styling
|
|
6
6
|
*/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type MouseEventHandler, type WheelEventHandler } from "react";
|
|
2
|
-
import { type
|
|
2
|
+
import { type ColorState, type AriaProps, type BadgeType, type CallbackReturn, type CssProp, type IconProps, type PolymorphicProps, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
3
|
export interface BaseProps extends CssProp, AriaProps, IconProps, RefProp, TestProps {
|
|
4
4
|
/**
|
|
5
5
|
* primary icon alignment
|
|
@@ -16,7 +16,7 @@ export interface BaseProps extends CssProp, AriaProps, IconProps, RefProp, TestP
|
|
|
16
16
|
/**
|
|
17
17
|
* button color
|
|
18
18
|
*/
|
|
19
|
-
color?:
|
|
19
|
+
color?: ColorState;
|
|
20
20
|
/**
|
|
21
21
|
* button type
|
|
22
22
|
*/
|
|
@@ -24,7 +24,7 @@ export interface BaseProps extends CssProp, AriaProps, IconProps, RefProp, TestP
|
|
|
24
24
|
/**
|
|
25
25
|
* button styling
|
|
26
26
|
*/
|
|
27
|
-
variant?: "outline" | "solid" | "link";
|
|
27
|
+
variant?: "outline" | "soft" | "solid" | "link";
|
|
28
28
|
/**
|
|
29
29
|
* active state with click disabled
|
|
30
30
|
*/
|
|
@@ -82,14 +82,16 @@ export interface BaseProps extends CssProp, AriaProps, IconProps, RefProp, TestP
|
|
|
82
82
|
onMouseLeave?: MouseEventHandler;
|
|
83
83
|
onWheel?: WheelEventHandler;
|
|
84
84
|
}
|
|
85
|
-
|
|
85
|
+
type ButtonTypeProps = {
|
|
86
86
|
children: string | React.ReactElement;
|
|
87
87
|
"aria-label"?: string;
|
|
88
88
|
} | {
|
|
89
89
|
children?: never;
|
|
90
90
|
"aria-label": string;
|
|
91
91
|
};
|
|
92
|
+
export type ButtonProps<Tag extends React.ElementType = "button"> = BaseProps & ButtonTypeProps & PolymorphicProps<Tag>;
|
|
92
93
|
/**
|
|
93
94
|
* Clickable action button
|
|
94
95
|
*/
|
|
95
|
-
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, stopPropagation, type, hotKey, showActionDone, showActionDoneEvent, tabIndex, "data-ref": dataRef, ...aria }:
|
|
96
|
+
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, stopPropagation, type, hotKey, showActionDone, showActionDoneEvent, tabIndex, "data-ref": dataRef, ...aria }: ButtonProps<Tag>) => import("react/jsx-runtime").JSX.Element;
|
|
97
|
+
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { type AriaProps, type ChildrenProp, type
|
|
2
|
+
import { type AriaProps, type ChildrenProp, type ColorState, type CssProp, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
3
|
import { type Button } from "./Button";
|
|
4
4
|
export interface ButtonGroupProps extends CssProp, AriaProps, TestProps, RefProp<HTMLDivElement>, ChildrenProp<React.ReactElement<typeof Button>> {
|
|
5
5
|
/**
|
|
@@ -17,7 +17,7 @@ export interface ButtonGroupProps extends CssProp, AriaProps, TestProps, RefProp
|
|
|
17
17
|
/**
|
|
18
18
|
* button color
|
|
19
19
|
*/
|
|
20
|
-
color?:
|
|
20
|
+
color?: ColorState;
|
|
21
21
|
/**
|
|
22
22
|
* full rounded edges
|
|
23
23
|
*/
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import { type Placement } from "@floating-ui/react";
|
|
2
3
|
import { type CallbackReturn, type PolymorphicProps, type RefProp } from "../../types";
|
|
3
4
|
import { type BaseProps, type ButtonProps } from "./Button";
|
|
4
5
|
interface ExtendedProps extends Omit<BaseProps, "onClick">, RefProp {
|
|
@@ -14,6 +15,10 @@ interface ExtendedProps extends Omit<BaseProps, "onClick">, RefProp {
|
|
|
14
15
|
* ok label
|
|
15
16
|
*/
|
|
16
17
|
cancelLabel?: string;
|
|
18
|
+
/**
|
|
19
|
+
* dropdown placement
|
|
20
|
+
*/
|
|
21
|
+
placement?: Placement;
|
|
17
22
|
/**
|
|
18
23
|
* click handler, return Promise to autoset loading state
|
|
19
24
|
*/
|
|
@@ -23,5 +28,5 @@ export type ConfirmButtonProps = ExtendedProps & ButtonProps;
|
|
|
23
28
|
/**
|
|
24
29
|
* Button with confirmation dropdown
|
|
25
30
|
*/
|
|
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;
|
|
31
|
+
export declare const ConfirmButton: <Tag extends import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> = "button">({ ref, message, color, okLabel, cancelLabel, onClick, loading, placement, actionMessage, showActionDone, showActionDoneEvent, ...props }: ConfirmButtonProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
|
|
27
32
|
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { type AriaProps, type ChildrenProp, type
|
|
1
|
+
import { type AriaProps, type ChildrenProp, type ColorState, type CssProp, type TestProps } from "../../types";
|
|
2
2
|
export interface CalloutProps extends AriaProps, ChildrenProp, CssProp, TestProps {
|
|
3
3
|
/**
|
|
4
4
|
* callout color
|
|
5
5
|
*/
|
|
6
|
-
color?:
|
|
6
|
+
color?: ColorState;
|
|
7
7
|
/**
|
|
8
8
|
* legend title
|
|
9
9
|
*/
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type MouseEventHandler } from "react";
|
|
2
2
|
import { type ContentProps } from "../../core/content/Content";
|
|
3
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>> {
|
|
4
|
+
import { type AriaProps, type ChildrenProp, type CssProp, type RefProp, type TestProps } from "../../types";
|
|
5
|
+
export interface CardProps extends CssProp, AriaProps, TestProps, RefProp<HTMLDivElement>, ChildrenProp<React.ReactElement<HeadFootProps | ContentProps>> {
|
|
6
6
|
/**
|
|
7
7
|
* apply flex fill styling
|
|
8
8
|
*/
|
|
@@ -36,4 +36,4 @@ export interface CardProps extends CssProp, AriaProps, TestProps, ChildrenProp<R
|
|
|
36
36
|
*/
|
|
37
37
|
dragData?: KeyValue;
|
|
38
38
|
}
|
|
39
|
-
export declare const Card: ({ children, className, bodyClassName, selected, selectedRibbon, onClick, flex, draggable, dragKey, dragData, ...aria }: CardProps) => import("react/jsx-runtime").JSX.Element;
|
|
39
|
+
export declare const Card: ({ children, className, bodyClassName, selected, selectedRibbon, onClick, flex, draggable, dragKey, dragData, ref, ...aria }: CardProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
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";
|
|
2
|
+
import { type AriaProps, type ChildProp, type ColorType, type CssProp, type IconProps, type PaletteType, type PolymorphicProps, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
3
|
export interface ChipProps extends CssProp, AriaProps, IconProps, TestProps, ChildProp<string | ReactElement>, RefProp<HTMLDivElement> {
|
|
4
4
|
/**
|
|
5
5
|
* chip size
|
|
6
6
|
*/
|
|
7
|
-
size?: SizeType;
|
|
7
|
+
size?: SizeType | number | string;
|
|
8
8
|
/**
|
|
9
9
|
* chip color (CSS color / tailwind color)
|
|
10
10
|
*/
|
|
11
|
-
color?: ColorType | string;
|
|
11
|
+
color?: ColorType | PaletteType | string;
|
|
12
12
|
/**
|
|
13
13
|
* chip styling
|
|
14
14
|
*/
|
|
@@ -18,6 +18,10 @@ export interface CollapsableProps extends CssProp, AriaProps, TestProps, RefProp
|
|
|
18
18
|
* header button className
|
|
19
19
|
*/
|
|
20
20
|
headerClassName?: string;
|
|
21
|
+
/**
|
|
22
|
+
* Header position sticky
|
|
23
|
+
*/
|
|
24
|
+
stickyHeader?: boolean;
|
|
21
25
|
/**
|
|
22
26
|
* open state icon
|
|
23
27
|
*/
|
|
@@ -43,5 +47,5 @@ export interface CollapsableProps extends CssProp, AriaProps, TestProps, RefProp
|
|
|
43
47
|
*/
|
|
44
48
|
onClose?: () => void;
|
|
45
49
|
}
|
|
46
|
-
export declare const Collapsable: ({ ref, disabled, className, bodyClassName, headerClassName, children, iconAlign, iconClosed, iconOpen, open, onClose, onOpen, ...aria }: CollapsableProps) => import("react/jsx-runtime").JSX.Element;
|
|
50
|
+
export declare const Collapsable: ({ ref, disabled, className, bodyClassName, headerClassName, children, iconAlign, stickyHeader, iconClosed, iconOpen, open, onClose, onOpen, ...aria }: CollapsableProps) => import("react/jsx-runtime").JSX.Element;
|
|
47
51
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type ChildProp, type ColorType, type CssProp, type PaletteType } from "../../types";
|
|
2
2
|
export interface DividerProps extends CssProp, Partial<ChildProp> {
|
|
3
3
|
/**
|
|
4
4
|
* apply text bg
|
|
@@ -8,13 +8,17 @@ export interface DividerProps extends CssProp, Partial<ChildProp> {
|
|
|
8
8
|
* vertical rule
|
|
9
9
|
*/
|
|
10
10
|
vertical?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* divider label classname(s)
|
|
13
|
+
*/
|
|
14
|
+
labelClassName?: string;
|
|
11
15
|
/**
|
|
12
16
|
* rule color
|
|
13
17
|
*/
|
|
14
|
-
color?: ColorType | PaletteType |
|
|
18
|
+
color?: ColorType | PaletteType | string;
|
|
15
19
|
/**
|
|
16
20
|
* text alignment
|
|
17
21
|
*/
|
|
18
22
|
align?: "start" | "end" | "center";
|
|
19
23
|
}
|
|
20
|
-
export declare const Divider: ({ children, color, vertical, fill, align, className, }: DividerProps) => import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export declare const Divider: ({ children, color, vertical, labelClassName, fill, align, className, }: DividerProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type ChildProp, type CssProp } from "../../types";
|
|
2
2
|
import { type DropdownProps } from "./Dropdown";
|
|
3
|
-
export declare const DropdownTool: ({ children, className, groupHover, ...props }: ChildProp & CssProp & Omit<DropdownProps, "children"> & {
|
|
3
|
+
export declare const DropdownTool: ({ children, className, groupHover, icon, ...props }: ChildProp & CssProp & Omit<DropdownProps, "children"> & {
|
|
4
|
+
icon?: string;
|
|
4
5
|
/**
|
|
5
6
|
* hide until group hovered
|
|
6
7
|
*/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { type ChildrenProp, type CssProp, type TestProps } from "../../types";
|
|
2
|
+
import { type ChildrenProp, type ColorType, type CssProp, type PaletteType, type TestProps } from "../../types";
|
|
3
3
|
export interface EmptyContentProps extends CssProp, TestProps, Partial<ChildrenProp> {
|
|
4
4
|
/**
|
|
5
5
|
* empty title
|
|
@@ -17,5 +17,9 @@ export interface EmptyContentProps extends CssProp, TestProps, Partial<ChildrenP
|
|
|
17
17
|
* empty icon
|
|
18
18
|
*/
|
|
19
19
|
icon?: string | React.ReactElement;
|
|
20
|
+
/**
|
|
21
|
+
* icon color
|
|
22
|
+
*/
|
|
23
|
+
iconColor?: ColorType | PaletteType;
|
|
20
24
|
}
|
|
21
|
-
export declare const EmptyContent: ({ children, title, message, icon, className, size, ...test }: EmptyContentProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
export declare const EmptyContent: ({ children, title, message, icon, className, size, iconColor, ...test }: EmptyContentProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { type AriaProps, type ColorType, type CssProp, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
2
|
+
import { type PaletteType, type AriaProps, type ColorType, type CssProp, type RefProp, type SizeType, type TestProps } from "../../types";
|
|
3
3
|
export interface IconProps extends CssProp, AriaProps, RefProp, TestProps {
|
|
4
4
|
/**
|
|
5
5
|
* svg path / webfont className / 1-4 letter text
|
|
@@ -8,11 +8,11 @@ export interface IconProps extends CssProp, AriaProps, RefProp, TestProps {
|
|
|
8
8
|
/**
|
|
9
9
|
* background color (CSS color / tailwind color)
|
|
10
10
|
*/
|
|
11
|
-
bg?: ColorType | string;
|
|
11
|
+
bg?: ColorType | PaletteType | string;
|
|
12
12
|
/**
|
|
13
13
|
* icon color (CSS color / tailwind color)
|
|
14
14
|
*/
|
|
15
|
-
color?: ColorType | string;
|
|
15
|
+
color?: ColorType | PaletteType | string;
|
|
16
16
|
/**
|
|
17
17
|
* flip icon in rtl
|
|
18
18
|
*/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { type AriaProps, type CssProp } from "../../types";
|
|
2
|
-
export interface BaseProps extends CssProp, AriaProps {
|
|
1
|
+
import { type AriaProps, type CssProp, type TestProps } from "../../types";
|
|
2
|
+
export interface BaseProps extends CssProp, TestProps, AriaProps {
|
|
3
3
|
/**
|
|
4
4
|
* media source
|
|
5
5
|
*/
|
|
@@ -3,5 +3,6 @@ import { type ChildrenProp } from "../../types";
|
|
|
3
3
|
import { type Menu } from "./Menu";
|
|
4
4
|
export interface ContextMenuProps extends ChildrenProp {
|
|
5
5
|
menu: React.ReactElement<typeof Menu>;
|
|
6
|
+
disabled?: boolean;
|
|
6
7
|
}
|
|
7
|
-
export declare const ContextMenu: ({ children, menu }: ContextMenuProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare const ContextMenu: ({ children, menu, disabled }: ContextMenuProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { type PolymorphicProps } from "../../types";
|
|
3
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;
|
|
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, tabIndex, minimal, "data-open": childOpen, ref, ...aria }: MenuItemProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ElementType, type MouseEvent } from "react";
|
|
2
|
-
import { type AriaProps, type BadgeType, type CallbackReturn, type ChildrenProp, type
|
|
2
|
+
import { type AriaProps, type BadgeType, type CallbackReturn, type ChildrenProp, type ColorState, type CssProp, type IconProps, type TestProps } from "../../types";
|
|
3
3
|
export interface MenuItemProps extends CssProp, AriaProps, TestProps, IconProps {
|
|
4
4
|
/**
|
|
5
5
|
* menu id passed via menu.onClick
|
|
@@ -16,7 +16,7 @@ export interface MenuItemProps extends CssProp, AriaProps, TestProps, IconProps
|
|
|
16
16
|
/**
|
|
17
17
|
* menu color
|
|
18
18
|
*/
|
|
19
|
-
color?:
|
|
19
|
+
color?: ColorState;
|
|
20
20
|
/**
|
|
21
21
|
* item active
|
|
22
22
|
*/
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { type AriaProps, type ColorType, type CssProp, type TestProps } from "../../types";
|
|
2
|
-
export interface NavigatorProps extends CssProp, AriaProps, TestProps {
|
|
1
|
+
import { type AriaProps, type ChildProp, type ColorType, type CssProp, type PaletteType, type TestProps } from "../../types";
|
|
2
|
+
export interface NavigatorProps extends CssProp, AriaProps, TestProps, Partial<ChildProp> {
|
|
3
3
|
/**
|
|
4
4
|
* navigator button color
|
|
5
5
|
*/
|
|
6
|
-
color?: ColorType | string;
|
|
6
|
+
color?: ColorType | PaletteType | string;
|
|
7
7
|
/**
|
|
8
8
|
* navigation handler
|
|
9
9
|
*/
|
|
10
10
|
onNavigate: (dir: -1 | 1) => void;
|
|
11
11
|
}
|
|
12
|
-
export declare const Navigator: ({ className, onNavigate, color, ...aria }: NavigatorProps) => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export declare const Navigator: ({ className, onNavigate, color, children, ...aria }: NavigatorProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type ColorType } from "../../types";
|
|
1
|
+
import { type PaletteType, type ColorType } from "../../types";
|
|
2
2
|
export interface ProgressProps {
|
|
3
3
|
/**
|
|
4
4
|
* progress value (0-100)
|
|
@@ -11,7 +11,7 @@ export interface ProgressProps {
|
|
|
11
11
|
/**
|
|
12
12
|
* color
|
|
13
13
|
*/
|
|
14
|
-
color?: ColorType;
|
|
14
|
+
color?: ColorType | PaletteType;
|
|
15
15
|
/**
|
|
16
16
|
* animate
|
|
17
17
|
*/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type ColorType } from "../../types";
|
|
1
|
+
import { type PaletteType, type ColorType } from "../../types";
|
|
2
2
|
export interface ProgressProps {
|
|
3
3
|
/**
|
|
4
4
|
* progress value (0-100)
|
|
@@ -11,6 +11,6 @@ export interface ProgressProps {
|
|
|
11
11
|
/**
|
|
12
12
|
* color
|
|
13
13
|
*/
|
|
14
|
-
color?: ColorType;
|
|
14
|
+
color?: ColorType | PaletteType;
|
|
15
15
|
}
|
|
16
16
|
export declare const ProgressCircle: ({ value, size, color, }: ProgressProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type ReactElement } from "react";
|
|
2
|
-
import { type AriaProps, type BadgeType, type CallbackReturn, type ChildrenProp, type
|
|
3
|
-
export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaProps, TestProps, IconProps {
|
|
2
|
+
import { type AriaProps, type BadgeType, type CallbackReturn, type ChildrenProp, type ColorState, type CssProp, type IconProps, type PolymorphicProps, type RefProp, type TestProps, type TooltipProp } from "../../types";
|
|
3
|
+
export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaProps, TestProps, IconProps, TooltipProp {
|
|
4
4
|
/**
|
|
5
5
|
* tab id
|
|
6
6
|
*/
|
|
@@ -12,11 +12,11 @@ export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaP
|
|
|
12
12
|
/**
|
|
13
13
|
* tab color
|
|
14
14
|
*/
|
|
15
|
-
color?:
|
|
15
|
+
color?: ColorState;
|
|
16
16
|
/**
|
|
17
17
|
* tab badge
|
|
18
18
|
*/
|
|
19
|
-
badge?: BadgeType;
|
|
19
|
+
badge?: string | number | BadgeType;
|
|
20
20
|
/**
|
|
21
21
|
* disabled
|
|
22
22
|
*/
|
|
@@ -42,4 +42,4 @@ export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaP
|
|
|
42
42
|
*/
|
|
43
43
|
onClick?: (id: string) => CallbackReturn;
|
|
44
44
|
}
|
|
45
|
-
export declare const Tab: <Tag extends import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> = "button">({ ref, as, id, className, label, icon, iconBg, iconColor, rtlFlip, badge, disabled, onClose, active,
|
|
45
|
+
export declare const Tab: <Tag extends import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> = "button">({ ref, as, id, className, label, icon, iconBg, iconColor, rtlFlip, badge, disabled, onClose, active, onClick, tabFlex, color, actions, tooltip, activeClassName, ...aria }: TabProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type ReactNode } from "react";
|
|
1
2
|
import { type CallbackReturn, type ChildrenProp } from "../../types";
|
|
2
3
|
import { Tab } from "./Tab";
|
|
3
4
|
export interface TabPanelProps extends ChildrenProp<typeof Tab> {
|
|
@@ -29,6 +30,14 @@ export interface TabPanelProps extends ChildrenProp<typeof Tab> {
|
|
|
29
30
|
* tab list className
|
|
30
31
|
*/
|
|
31
32
|
headerClassName?: string;
|
|
33
|
+
/**
|
|
34
|
+
* append element
|
|
35
|
+
*/
|
|
36
|
+
append?: ReactNode;
|
|
37
|
+
/**
|
|
38
|
+
* prepend element
|
|
39
|
+
*/
|
|
40
|
+
prepend?: ReactNode;
|
|
32
41
|
/**
|
|
33
42
|
* change handler
|
|
34
43
|
*/
|
|
@@ -38,4 +47,4 @@ export interface TabPanelProps extends ChildrenProp<typeof Tab> {
|
|
|
38
47
|
*/
|
|
39
48
|
onBeforeChange?: (nextTab: string, currentTab?: string) => CallbackReturn;
|
|
40
49
|
}
|
|
41
|
-
export declare const TabPanel: ({ children, headerClassName, orientation, activeTab, justify, variant, tabFlex, gap, onBeforeChange, onChange, }: TabPanelProps) => import("react/jsx-runtime").JSX.Element;
|
|
50
|
+
export declare const TabPanel: ({ children, headerClassName, orientation, activeTab, justify, variant, tabFlex, append, prepend, gap, onBeforeChange, onChange, }: TabPanelProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type MouseEvent } from "react";
|
|
2
|
+
import { type ChildrenProp, type CssProp, type RefProp, type ScrollObject, type SizeObject, type TestProps } from "../../types";
|
|
2
3
|
export interface ContentProps extends ChildrenProp, CssProp, RefProp, TestProps {
|
|
3
4
|
/**
|
|
4
5
|
* scroll vevent handler
|
|
5
6
|
*/
|
|
6
|
-
onScroll?: (event:
|
|
7
|
+
onScroll?: (scroll: ScrollObject, event: MouseEvent<HTMLDivElement>) => void;
|
|
7
8
|
/**
|
|
8
9
|
* scroll vevent handler
|
|
9
10
|
*/
|
|
@@ -1,14 +1,6 @@
|
|
|
1
|
-
import { type AriaProps, type ChildrenProp, type
|
|
1
|
+
import { type AriaProps, type ChildrenProp, type CssProp, type TestProps } from "../../types";
|
|
2
2
|
interface BaseProps extends CssProp, AriaProps, ChildrenProp, TestProps {
|
|
3
3
|
dir?: "ltr" | "rtl";
|
|
4
|
-
/**
|
|
5
|
-
* background color
|
|
6
|
-
*/
|
|
7
|
-
bg?: ColorWithGrays | string;
|
|
8
|
-
/**
|
|
9
|
-
* background color
|
|
10
|
-
*/
|
|
11
|
-
color?: ColorWithGrays | string;
|
|
12
4
|
}
|
|
13
5
|
type DefaultProps = BaseProps & {
|
|
14
6
|
flex?: false;
|