@react-fabric/core 1.0.0-beta.35 → 1.0.0-beta.37
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} +2 -2
- 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} +63 -80
- package/{src/components/card/Card.module.css → css/components/_card.css} +32 -28
- package/{src/components/chip/Chip.module.css → css/components/_chip.css} +11 -10
- package/{src/components/collapsable/Collapsable.module.css → css/components/_collapsable.css} +3 -3
- package/{src/components/divider/Divider.module.css → css/components/_divider.css} +3 -3
- 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 -4
- 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} +43 -43
- package/{src/overlays/toast/Toast.module.css → css/components/_toast.css} +2 -2
- package/css/components/_tooltip.css +29 -0
- package/css/components/index.css +47 -0
- package/{src/core/aside/Aside.module.css → css/core/_aside.css} +42 -42
- package/{src/core/content/Content.module.css → css/core/_content.css} +9 -5
- 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 -4
- package/{src/core/page/Page.module.css → css/core/_page.css} +12 -8
- package/{src/core/responsive/Responsive.module.css → css/core/_responsive.css} +10 -10
- package/{src/core/section/Section.module.css → css/core/_section.css} +2 -2
- package/{src/core/theme/Theme.module.css → css/core/_theme.css} +3 -3
- package/{src/typography/Typography.module.css → css/core/_typography.css} +12 -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 +314 -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 +512 -0
- package/css/theme/index.css +44 -0
- package/dist/cjs/components/actionLabel/ActionLabel.js +2 -3
- package/dist/cjs/components/animations/Animations.js +14 -10
- package/dist/cjs/components/avatar/Avatar.js +2 -3
- package/dist/cjs/components/avatar/AvatarGroup.js +2 -3
- package/dist/cjs/components/badge/Badge.js +2 -3
- package/dist/cjs/components/breadcrumbs/Breadcrumbs.js +5 -6
- package/dist/cjs/components/button/Button.js +13 -10
- package/dist/cjs/components/button/ButtonGroup.js +1 -2
- package/dist/cjs/components/button/ToggleButtonGroup.js +1 -2
- package/dist/cjs/components/callout/Callout.js +11 -5
- package/dist/cjs/components/card/Card.js +3 -4
- package/dist/cjs/components/card/CardCover.js +9 -4
- package/dist/cjs/components/chip/Chip.js +4 -5
- package/dist/cjs/components/collapsable/Collapsable.js +3 -4
- package/dist/cjs/components/divider/Divider.js +9 -7
- package/dist/cjs/components/dropdown/Dropdown.js +2 -3
- package/dist/cjs/components/dropdown/DropdownTool.js +1 -1
- package/dist/cjs/components/icon/Icon.js +1 -2
- package/dist/cjs/components/media/Media.js +15 -11
- package/dist/cjs/components/menu/Menu.js +1 -1
- package/dist/cjs/components/menu/MenuItem.js +2 -3
- package/dist/cjs/components/meter/Meter.js +2 -3
- package/dist/cjs/components/navigator/Navigator.js +1 -1
- package/dist/cjs/components/panel/Panel.js +7 -8
- package/dist/cjs/components/panel/PanelGroup.js +1 -2
- package/dist/cjs/components/progress/ProgressBar.js +4 -4
- package/dist/cjs/components/progress/ProgressCircle.js +4 -3
- package/dist/cjs/components/tabpanel/Tab.js +1 -2
- package/dist/cjs/components/tabpanel/TabPanel.js +3 -4
- package/dist/cjs/core/aside/Aside.js +9 -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 +1 -2
- package/dist/cjs/core/headfoot/HeadFoot.js +2 -21
- package/dist/cjs/core/page/Page.js +2 -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/overlays/alert/Alert.js +14 -8
- package/dist/cjs/overlays/flyout/Flyout.js +4 -5
- package/dist/cjs/overlays/message/Message.js +5 -2
- package/dist/cjs/overlays/modal/Modal.js +4 -5
- package/dist/cjs/overlays/toast/Toast.js +16 -8
- package/dist/cjs/overlays/tooltip/Tooltip.js +19 -7
- package/dist/cjs/typography/Abbr.js +1 -2
- package/dist/cjs/typography/Anchor.js +1 -1
- package/dist/cjs/typography/Mark.js +1 -2
- package/dist/cjs/typography/Text.js +2 -3
- package/dist/cjs/typography/Title.js +1 -2
- package/dist/cjs/utils/getColor.js +1 -18
- package/dist/esm/components/actionLabel/ActionLabel.js +2 -3
- package/dist/esm/components/animations/Animations.js +15 -11
- package/dist/esm/components/avatar/Avatar.js +3 -4
- package/dist/esm/components/avatar/AvatarGroup.js +2 -3
- package/dist/esm/components/badge/Badge.js +2 -3
- package/dist/esm/components/breadcrumbs/Breadcrumbs.js +5 -6
- package/dist/esm/components/button/Button.js +13 -10
- package/dist/esm/components/button/ButtonGroup.js +1 -2
- package/dist/esm/components/button/ToggleButtonGroup.js +1 -2
- package/dist/esm/components/callout/Callout.js +11 -5
- package/dist/esm/components/card/Card.js +3 -4
- package/dist/esm/components/card/CardCover.js +9 -4
- package/dist/esm/components/chip/Chip.js +5 -6
- package/dist/esm/components/collapsable/Collapsable.js +3 -4
- package/dist/esm/components/divider/Divider.js +10 -8
- package/dist/esm/components/dropdown/Dropdown.js +2 -3
- package/dist/esm/components/dropdown/DropdownTool.js +1 -1
- package/dist/esm/components/icon/Icon.js +2 -3
- package/dist/esm/components/media/Media.js +15 -11
- package/dist/esm/components/menu/Menu.js +1 -1
- package/dist/esm/components/menu/MenuItem.js +2 -3
- package/dist/esm/components/meter/Meter.js +2 -3
- package/dist/esm/components/navigator/Navigator.js +1 -1
- package/dist/esm/components/panel/Panel.js +7 -8
- package/dist/esm/components/panel/PanelGroup.js +1 -2
- package/dist/esm/components/progress/ProgressBar.js +5 -5
- package/dist/esm/components/progress/ProgressCircle.js +5 -4
- package/dist/esm/components/tabpanel/Tab.js +1 -2
- package/dist/esm/components/tabpanel/TabPanel.js +3 -4
- package/dist/esm/core/aside/Aside.js +9 -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 +1 -2
- package/dist/esm/core/headfoot/HeadFoot.js +2 -21
- package/dist/esm/core/page/Page.js +2 -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/overlays/alert/Alert.js +15 -9
- package/dist/esm/overlays/flyout/Flyout.js +4 -5
- package/dist/esm/overlays/message/Message.js +6 -3
- package/dist/esm/overlays/modal/Modal.js +4 -5
- package/dist/esm/overlays/toast/Toast.js +17 -9
- package/dist/esm/overlays/tooltip/Tooltip.js +19 -7
- package/dist/esm/typography/Abbr.js +2 -3
- package/dist/esm/typography/Anchor.js +2 -2
- package/dist/esm/typography/Mark.js +2 -3
- package/dist/esm/typography/Text.js +3 -4
- package/dist/esm/typography/Title.js +2 -3
- package/dist/esm/utils/getColor.js +2 -16
- package/dist/types/components/animations/Animations.d.ts +4 -4
- package/dist/types/components/avatar/Avatar.d.ts +3 -3
- package/dist/types/components/button/Button.d.ts +2 -2
- package/dist/types/components/button/ButtonGroup.d.ts +2 -2
- package/dist/types/components/callout/Callout.d.ts +2 -2
- package/dist/types/components/chip/Chip.d.ts +2 -2
- package/dist/types/components/divider/Divider.d.ts +7 -3
- package/dist/types/components/icon/Icon.d.ts +3 -3
- package/dist/types/components/menu/types.d.ts +2 -2
- package/dist/types/components/navigator/Navigator.d.ts +2 -2
- 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 +2 -2
- package/dist/types/core/headfoot/HeadFoot.d.ts +1 -9
- package/dist/types/core/theme/ThemeProvider.d.ts +3 -3
- package/dist/types/overlays/alert/Alert.d.ts +2 -2
- package/dist/types/overlays/message/Message.d.ts +2 -2
- package/dist/types/overlays/toast/Toast.d.ts +2 -2
- package/dist/types/overlays/tooltip/Tooltip.d.ts +1 -1
- package/dist/types/types/index.d.ts +10 -5
- package/dist/types/typography/Abbr.d.ts +6 -2
- package/dist/types/typography/Anchor.d.ts +3 -3
- package/dist/types/typography/Mark.d.ts +2 -2
- package/dist/types/utils/getColor.d.ts +1 -4
- package/package.json +16 -7
- package/src/components/actionLabel/ActionLabel.tsx +2 -3
- package/src/components/animations/Animations.tsx +19 -19
- package/src/components/avatar/Avatar.tsx +6 -8
- package/src/components/avatar/AvatarGroup.tsx +3 -4
- package/src/components/badge/Badge.tsx +3 -4
- package/src/components/breadcrumbs/Breadcrumbs.tsx +5 -6
- package/src/components/button/Button.tsx +15 -13
- package/src/components/button/ButtonGroup.tsx +4 -5
- package/src/components/button/ToggleButtonGroup.tsx +2 -3
- package/src/components/callout/Callout.tsx +14 -8
- package/src/components/card/Card.tsx +6 -7
- package/src/components/card/CardCover.tsx +11 -6
- package/src/components/chip/Chip.tsx +9 -10
- package/src/components/collapsable/Collapsable.tsx +3 -4
- package/src/components/divider/Divider.tsx +15 -11
- package/src/components/dropdown/Dropdown.tsx +2 -3
- package/src/components/dropdown/DropdownTool.tsx +1 -1
- package/src/components/icon/Icon.tsx +7 -9
- package/src/components/media/Media.tsx +19 -14
- package/src/components/menu/Menu.tsx +1 -1
- package/src/components/menu/MenuItem.tsx +5 -6
- package/src/components/menu/types.ts +2 -2
- package/src/components/meter/Meter.tsx +2 -3
- package/src/components/navigator/Navigator.tsx +4 -3
- package/src/components/panel/Panel.tsx +7 -8
- 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 +3 -4
- package/src/components/tabpanel/TabPanel.tsx +3 -4
- package/src/core/aside/Aside.tsx +9 -10
- package/src/core/boundary/ErrorBoundary.tsx +8 -7
- package/src/core/boundary/ErrorIcon.tsx +1 -2
- package/src/core/content/Content.tsx +1 -2
- package/src/core/headfoot/HeadFoot.tsx +1 -34
- package/src/core/page/Page.tsx +2 -3
- package/src/core/responsive/Responsive.tsx +4 -5
- package/src/core/section/Section.tsx +1 -2
- package/src/core/theme/ThemeProvider.tsx +10 -11
- package/src/core/viewport/Viewport.tsx +1 -2
- package/src/overlays/alert/Alert.tsx +19 -27
- package/src/overlays/flyout/Flyout.tsx +4 -5
- package/src/overlays/message/Message.tsx +10 -7
- package/src/overlays/modal/Modal.tsx +4 -5
- package/src/overlays/toast/Toast.tsx +18 -27
- package/src/overlays/tooltip/Tooltip.tsx +28 -7
- package/src/types/index.ts +230 -18
- package/src/typography/Abbr.tsx +15 -9
- package/src/typography/Anchor.tsx +5 -10
- package/src/typography/Mark.tsx +4 -9
- package/src/typography/Text.tsx +3 -11
- package/src/typography/Title.tsx +2 -5
- package/src/utils/getColor.ts +1 -17
- 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/divider/Divider.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/divider/Divider.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/src/overlays/tooltip/Tooltip.module.css +0 -53
|
@@ -11,7 +11,6 @@ import { Icon } from '../../components/icon/Icon.js';
|
|
|
11
11
|
import { Header } from '../../core/headfoot/HeadFoot.js';
|
|
12
12
|
import { HotKeyWrapper } from '../../hotkeys/HotKeyWrapper.js';
|
|
13
13
|
import { CoreIcons } from '../../types/icons.js';
|
|
14
|
-
import classes from './Flyout.module.css';
|
|
15
14
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
16
15
|
|
|
17
16
|
var _excluded = ["icon", "iconBg", "iconColor", "iconClassName", "rtlFlip", "title", "actions", "closeOnClick", "headerClassName", "onClose", "onBeforeClose", "children", "loading", "size", "width", "minWidth", "hideMask", "align"];
|
|
@@ -105,7 +104,7 @@ var Flyout = function Flyout(_ref) {
|
|
|
105
104
|
context: context,
|
|
106
105
|
children: /*#__PURE__*/jsx("div", _objectSpread(_objectSpread(_objectSpread(_objectSpread({
|
|
107
106
|
"data-align": align,
|
|
108
|
-
className: classNames(
|
|
107
|
+
className: classNames("fabric-flyout", "fixed inset-y-0 overflow-hidden flex flex-col flex-nowrap pointer-events-auto shadow-xl", align === "start" ? "start-0" : "end-0", size === "sm" && "w-[20rem]", size === "md" && "w-[40rem]", size === "lg" && "w-[60vw]", size === "xl" && "w-[80vw]"),
|
|
109
108
|
style: {
|
|
110
109
|
width: width,
|
|
111
110
|
minWidth: minWidth
|
|
@@ -116,7 +115,7 @@ var Flyout = function Flyout(_ref) {
|
|
|
116
115
|
children: /*#__PURE__*/jsxs(HotKeyWrapper, {
|
|
117
116
|
children: [/*#__PURE__*/jsxs(Header, {
|
|
118
117
|
flex: true,
|
|
119
|
-
className: classNames(
|
|
118
|
+
className: classNames("fabric-flyoutHeader", headerClassName),
|
|
120
119
|
children: [isString(icon) && /*#__PURE__*/jsx(Icon, {
|
|
121
120
|
icon: icon,
|
|
122
121
|
bg: iconBg,
|
|
@@ -128,7 +127,7 @@ var Flyout = function Flyout(_ref) {
|
|
|
128
127
|
children: title
|
|
129
128
|
}), actions, /*#__PURE__*/jsx(Icon, {
|
|
130
129
|
"data-ref": "panelClose",
|
|
131
|
-
className: classNames(
|
|
130
|
+
className: classNames("fabric-panelAction", "cursor-pointer p-1 text-xl self-stretch"),
|
|
132
131
|
icon: CoreIcons.close,
|
|
133
132
|
onClick: function onClick() {
|
|
134
133
|
return handleClose(false);
|
|
@@ -136,7 +135,7 @@ var Flyout = function Flyout(_ref) {
|
|
|
136
135
|
})]
|
|
137
136
|
}), loading && /*#__PURE__*/jsx(Loading, {}), /*#__PURE__*/jsx("div", {
|
|
138
137
|
role: "dialog",
|
|
139
|
-
className: classNames(
|
|
138
|
+
className: classNames("fabric-flyoutBody", "flex-1 grid overflow-hidden"),
|
|
140
139
|
tabIndex: 0,
|
|
141
140
|
children: children
|
|
142
141
|
})]
|
|
@@ -4,9 +4,8 @@ import classNames from 'classnames';
|
|
|
4
4
|
import { useRef, useCallback, useLayoutEffect } from 'react';
|
|
5
5
|
import { Icon } from '../../components/icon/Icon.js';
|
|
6
6
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
7
|
-
import {
|
|
7
|
+
import { getColor } from '../../utils/getColor.js';
|
|
8
8
|
import '@react-fabric/utilities';
|
|
9
|
-
import classes from './Message.module.css';
|
|
10
9
|
|
|
11
10
|
/*
|
|
12
11
|
* React Fabric
|
|
@@ -52,7 +51,11 @@ var Message = function Message(_ref) {
|
|
|
52
51
|
}, 100);
|
|
53
52
|
}, []);
|
|
54
53
|
return /*#__PURE__*/jsxs("div", {
|
|
55
|
-
className: classNames(
|
|
54
|
+
className: classNames("fabric-message", "flex flex-nowrap gap-1 px-8 relative justify-center max-w-md pointer-events-auto rounded mb-2 select-none"),
|
|
55
|
+
style: {
|
|
56
|
+
backgroundColor: color ? getColor(color + "-300") : "var(--bg-color-invert)",
|
|
57
|
+
color: color ? getColor(color + "-900") : "var(--text-color-invert)"
|
|
58
|
+
},
|
|
56
59
|
ref: elRef,
|
|
57
60
|
children: [icon && /*#__PURE__*/jsx(Icon, {
|
|
58
61
|
icon: icon,
|
|
@@ -11,7 +11,6 @@ import { Icon } from '../../components/icon/Icon.js';
|
|
|
11
11
|
import { Header } from '../../core/headfoot/HeadFoot.js';
|
|
12
12
|
import { HotKeyWrapper } from '../../hotkeys/HotKeyWrapper.js';
|
|
13
13
|
import { CoreIcons } from '../../types/icons.js';
|
|
14
|
-
import classes from './Modal.module.css';
|
|
15
14
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
16
15
|
|
|
17
16
|
var _excluded = ["icon", "iconBg", "iconColor", "iconClassName", "rtlFlip", "title", "actions", "headerClassName", "onClose", "onBeforeClose", "children", "loading", "size", "width", "height", "minHeight", "minWidth"];
|
|
@@ -85,7 +84,7 @@ var Modal = function Modal(_ref) {
|
|
|
85
84
|
children: /*#__PURE__*/jsx(FloatingFocusManager, {
|
|
86
85
|
context: context,
|
|
87
86
|
children: /*#__PURE__*/jsx("dialog", _objectSpread(_objectSpread(_objectSpread({
|
|
88
|
-
className: classNames(
|
|
87
|
+
className: classNames("fabric-modal", "rounded-capped relative overflow-hidden flex flex-col flex-nowrap", "ring-1 ring-tint-100 ring-offset-1 focus-within:ring-primary-300 shadow-xl", size === "sm" && "w-[20rem]", size === "md" && "w-[40rem]", size === "lg" && "w-[60vw]", size === "xl" && "w-[80vw]", size === "screen" && "w-screen h-screen"),
|
|
89
88
|
style: {
|
|
90
89
|
width: width,
|
|
91
90
|
height: height,
|
|
@@ -97,7 +96,7 @@ var Modal = function Modal(_ref) {
|
|
|
97
96
|
children: /*#__PURE__*/jsxs(HotKeyWrapper, {
|
|
98
97
|
children: [/*#__PURE__*/jsxs(Header, {
|
|
99
98
|
flex: true,
|
|
100
|
-
className: classNames(
|
|
99
|
+
className: classNames("fabric-modalHeader", headerClassName),
|
|
101
100
|
children: [isString(icon) && /*#__PURE__*/jsx(Icon, {
|
|
102
101
|
icon: icon,
|
|
103
102
|
bg: iconBg,
|
|
@@ -109,7 +108,7 @@ var Modal = function Modal(_ref) {
|
|
|
109
108
|
children: title
|
|
110
109
|
}), actions, /*#__PURE__*/jsx(Icon, {
|
|
111
110
|
"data-ref": "panelClose",
|
|
112
|
-
className: classNames(
|
|
111
|
+
className: classNames("fabric-panelAction", "cursor-pointer p-1 text-xl self-stretch"),
|
|
113
112
|
icon: CoreIcons.close,
|
|
114
113
|
onClick: function onClick() {
|
|
115
114
|
return handleClose(false);
|
|
@@ -117,7 +116,7 @@ var Modal = function Modal(_ref) {
|
|
|
117
116
|
})]
|
|
118
117
|
}), loading && /*#__PURE__*/jsx(Loading, {}), /*#__PURE__*/jsx("div", {
|
|
119
118
|
role: "dialog",
|
|
120
|
-
className: classNames(
|
|
119
|
+
className: classNames("fabric-modalBody", "flex-1 grid overflow-hidden"),
|
|
121
120
|
tabIndex: 0,
|
|
122
121
|
children: children
|
|
123
122
|
})]
|
|
@@ -8,9 +8,8 @@ import { Button } from '../../components/button/Button.js';
|
|
|
8
8
|
import { Icon } from '../../components/icon/Icon.js';
|
|
9
9
|
import { CoreIcons } from '../../types/icons.js';
|
|
10
10
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
11
|
-
import {
|
|
11
|
+
import { getColor } from '../../utils/getColor.js';
|
|
12
12
|
import '@react-fabric/utilities';
|
|
13
|
-
import classes from './Toast.module.css';
|
|
14
13
|
|
|
15
14
|
/*
|
|
16
15
|
* React Fabric
|
|
@@ -61,22 +60,22 @@ var Toast = function Toast(_ref) {
|
|
|
61
60
|
case "danger":
|
|
62
61
|
return /*#__PURE__*/jsx(AnimationIndicator, {
|
|
63
62
|
type: "cross",
|
|
64
|
-
|
|
63
|
+
color: "danger-600"
|
|
65
64
|
});
|
|
66
65
|
case "success":
|
|
67
66
|
return /*#__PURE__*/jsx(AnimationIndicator, {
|
|
68
67
|
type: "check",
|
|
69
|
-
|
|
68
|
+
color: "success-600"
|
|
70
69
|
});
|
|
71
70
|
case "warning":
|
|
72
71
|
return /*#__PURE__*/jsx(AnimationIndicator, {
|
|
73
72
|
type: "exclaim",
|
|
74
|
-
|
|
73
|
+
color: "warning-600"
|
|
75
74
|
});
|
|
76
75
|
default:
|
|
77
76
|
return /*#__PURE__*/jsx(AnimationIndicator, {
|
|
78
77
|
type: type === "confirm" ? "question" : "info",
|
|
79
|
-
|
|
78
|
+
color: "".concat(color, "-600")
|
|
80
79
|
});
|
|
81
80
|
}
|
|
82
81
|
}, [color, type, icon]);
|
|
@@ -94,13 +93,22 @@ var Toast = function Toast(_ref) {
|
|
|
94
93
|
}, []);
|
|
95
94
|
return /*#__PURE__*/jsxs("div", {
|
|
96
95
|
role: "alert",
|
|
97
|
-
className: classNames(
|
|
96
|
+
className: classNames("fabric-toast", "flex flex-nowrap max-w-sm bg-base min-w-72 border pointer-events-auto relative overflow-hidden rounded-capped mt-4 select-none"),
|
|
97
|
+
style: {
|
|
98
|
+
borderColor: getColor(color + "-300")
|
|
99
|
+
},
|
|
98
100
|
ref: elRef,
|
|
99
101
|
children: [/*#__PURE__*/jsx("div", {
|
|
100
|
-
className: classNames("flex-initial p-2"
|
|
102
|
+
className: classNames("flex-initial p-2"),
|
|
103
|
+
style: {
|
|
104
|
+
backgroundColor: getColor(color + "-300")
|
|
105
|
+
},
|
|
101
106
|
children: iconType
|
|
102
107
|
}), /*#__PURE__*/jsxs("div", {
|
|
103
|
-
className: classNames(
|
|
108
|
+
className: classNames("flex flex-col flex-1 flex-nowrap overflow-hidden p-2"),
|
|
109
|
+
style: {
|
|
110
|
+
backgroundColor: getColor(color + "-50")
|
|
111
|
+
},
|
|
104
112
|
children: [/*#__PURE__*/jsxs("div", {
|
|
105
113
|
className: "flex flex-nowrap gap-2 items-start",
|
|
106
114
|
children: [/*#__PURE__*/jsx("div", {
|
|
@@ -10,10 +10,10 @@ import { useRef, useState, useEffect, useMemo, Fragment, cloneElement, isValidEl
|
|
|
10
10
|
import { Icon } from '../../components/icon/Icon.js';
|
|
11
11
|
import { useIsRtl } from '../../hooks/useIsRtl.js';
|
|
12
12
|
import { CoreIcons } from '../../types/icons.js';
|
|
13
|
-
import classes from './Tooltip.module.css';
|
|
14
13
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
14
|
+
import { getColor } from '../../utils/getColor.js';
|
|
15
15
|
|
|
16
|
-
var _excluded = ["ref", "children", "color", "content", "open", "copyContent", "disabled", "placement"];
|
|
16
|
+
var _excluded = ["ref", "children", "color", "textColor", "content", "open", "copyContent", "disabled", "placement"];
|
|
17
17
|
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; }
|
|
18
18
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
19
19
|
var getTooltipProps = function getTooltipProps(tooltip, innerRef) {
|
|
@@ -35,6 +35,7 @@ var Tooltip = function Tooltip(_ref) {
|
|
|
35
35
|
var ref = _ref.ref,
|
|
36
36
|
children = _ref.children,
|
|
37
37
|
color = _ref.color,
|
|
38
|
+
textColor = _ref.textColor,
|
|
38
39
|
content = _ref.content,
|
|
39
40
|
open = _ref.open,
|
|
40
41
|
copyContent = _ref.copyContent,
|
|
@@ -112,17 +113,28 @@ var Tooltip = function Tooltip(_ref) {
|
|
|
112
113
|
}, open ? {} : getReferenceProps(rest))), isOpen && content && /*#__PURE__*/jsx(FloatingPortal, {
|
|
113
114
|
children: /*#__PURE__*/jsxs("dfn", _objectSpread(_objectSpread({
|
|
114
115
|
"data-ref": "tooltip",
|
|
115
|
-
"
|
|
116
|
-
className: classNames(classes.tooltip, "select-none text-sm not-italic flex py-1 px-2 !max-w-lg rounded shadow-md bg-current"),
|
|
116
|
+
className: classNames("fabric-tooltip z-(--z-tooltip)", "select-none text-sm not-italic flex py-1 px-2 !max-w-lg rounded shadow-md bg-muted"),
|
|
117
117
|
ref: refs.setFloating,
|
|
118
|
-
style:
|
|
118
|
+
style: _objectSpread({
|
|
119
|
+
color: textColor ? getColor(textColor) : undefined,
|
|
120
|
+
backgroundColor: color ? getColor(color) : undefined
|
|
121
|
+
}, floatingStyles)
|
|
119
122
|
}, getFloatingProps()), {}, {
|
|
120
123
|
children: [/*#__PURE__*/jsx("span", {
|
|
121
|
-
className: classNames("font-medium
|
|
124
|
+
className: classNames("font-medium flex-1 break-all", !textColor && "contrast", isString(content) && "whitespace-pre-wrap mixed-lang"),
|
|
125
|
+
style: {
|
|
126
|
+
color: textColor ? undefined : color ? getColor(color) : "var(--bg-color-muted)"
|
|
127
|
+
},
|
|
122
128
|
children: content
|
|
123
129
|
}), copyEl, /*#__PURE__*/jsx(FloatingArrow, {
|
|
124
130
|
ref: arrowRef,
|
|
125
|
-
context: context
|
|
131
|
+
context: context,
|
|
132
|
+
strokeWidth: 0.5,
|
|
133
|
+
className: "fill-muted stroke-dimmed",
|
|
134
|
+
style: {
|
|
135
|
+
stroke: color ? getColor(color) : undefined,
|
|
136
|
+
fill: color ? getColor(color) : undefined
|
|
137
|
+
}
|
|
126
138
|
})]
|
|
127
139
|
}))
|
|
128
140
|
})]
|
|
@@ -8,8 +8,7 @@ import { useCallback, Fragment, useMemo } from 'react';
|
|
|
8
8
|
import { useMemoDebugger } from '../hooks/useEffectDebugger.js';
|
|
9
9
|
import { Tooltip, getTooltipProps } from '../overlays/tooltip/Tooltip.js';
|
|
10
10
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
11
|
-
import {
|
|
12
|
-
import classes from './Typography.module.css';
|
|
11
|
+
import { getColor } from '../utils/getColor.js';
|
|
13
12
|
|
|
14
13
|
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; }
|
|
15
14
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
@@ -28,7 +27,7 @@ var AbbrText = function AbbrText(_ref) {
|
|
|
28
27
|
}, [tooltip, content]);
|
|
29
28
|
return /*#__PURE__*/jsx(TooltipWrapper, _objectSpread(_objectSpread({}, tooltipProps), {}, {
|
|
30
29
|
children: /*#__PURE__*/jsx("abbr", {
|
|
31
|
-
className: classNames(
|
|
30
|
+
className: classNames("fabric-abbr", "whitespace-nowrap"),
|
|
32
31
|
style: color ? {
|
|
33
32
|
"--abbr-color": getColor(color)
|
|
34
33
|
} : undefined,
|
|
@@ -6,7 +6,7 @@ import classNames from 'classnames';
|
|
|
6
6
|
import { useMemoDebugger } from '../hooks/useEffectDebugger.js';
|
|
7
7
|
import 'react';
|
|
8
8
|
import { jsx } from 'react/jsx-runtime';
|
|
9
|
-
import { getColor
|
|
9
|
+
import { getColor } from '../utils/getColor.js';
|
|
10
10
|
import '@react-fabric/utilities';
|
|
11
11
|
import { TextSizeMap } from './types.js';
|
|
12
12
|
|
|
@@ -45,7 +45,7 @@ var Anchor = function Anchor(_ref) {
|
|
|
45
45
|
}, [bg, color, size, family], "Link styles");
|
|
46
46
|
var E = as !== null && as !== void 0 ? as : "a";
|
|
47
47
|
return /*#__PURE__*/jsx(E, _objectSpread(_objectSpread({
|
|
48
|
-
className: classNames("link", className, family && "font-".concat(family)
|
|
48
|
+
className: classNames("link", className, family && "font-".concat(family)),
|
|
49
49
|
style: styles,
|
|
50
50
|
ref: ref
|
|
51
51
|
}, aria), {}, {
|
|
@@ -7,8 +7,7 @@ import classNames from 'classnames';
|
|
|
7
7
|
import { useCallback, Fragment } from 'react';
|
|
8
8
|
import { useMemoDebugger } from '../hooks/useEffectDebugger.js';
|
|
9
9
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
10
|
-
import {
|
|
11
|
-
import classes from './Typography.module.css';
|
|
10
|
+
import { getColor } from '../utils/getColor.js';
|
|
12
11
|
|
|
13
12
|
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; }
|
|
14
13
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
@@ -16,7 +15,7 @@ var MarkText = function MarkText(_ref) {
|
|
|
16
15
|
var color = _ref.color,
|
|
17
16
|
children = _ref.children;
|
|
18
17
|
return /*#__PURE__*/jsx("mark", {
|
|
19
|
-
className: classNames(
|
|
18
|
+
className: classNames("fabric-mark", "whitespace-nowrap"),
|
|
20
19
|
style: color ? {
|
|
21
20
|
"--mark-color": getColor(color)
|
|
22
21
|
} : undefined,
|
|
@@ -11,8 +11,7 @@ import { useLayoutEffectDebugger, useMemoDebugger } from '../hooks/useEffectDebu
|
|
|
11
11
|
import { usePropToggle } from '../hooks/usePropToggle.js';
|
|
12
12
|
import { calculateTextHeight } from '../utils/calculateDimensions.js';
|
|
13
13
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
14
|
-
import { getColor
|
|
15
|
-
import classes from './Typography.module.css';
|
|
14
|
+
import { getColor } from '../utils/getColor.js';
|
|
16
15
|
import { TextSizeMap } from './types.js';
|
|
17
16
|
|
|
18
17
|
var _excluded = ["children", "className", "inline", "bg", "color", "family", "size", "clamp", "align"];
|
|
@@ -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,
|
|
@@ -6,10 +6,9 @@ import classNames from 'classnames';
|
|
|
6
6
|
import { useMemoDebugger } from '../hooks/useEffectDebugger.js';
|
|
7
7
|
import 'react';
|
|
8
8
|
import { jsx } from 'react/jsx-runtime';
|
|
9
|
-
import { getColor
|
|
9
|
+
import { getColor } from '../utils/getColor.js';
|
|
10
10
|
import '@react-fabric/utilities';
|
|
11
11
|
import { TitleSizeMap } from './types.js';
|
|
12
|
-
import classes from './Typography.module.css';
|
|
13
12
|
|
|
14
13
|
var _excluded = ["children", "className", "as", "bg", "color", "size", "align", "family"];
|
|
15
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; }
|
|
@@ -49,7 +48,7 @@ var Title = function Title(_ref) {
|
|
|
49
48
|
}, [bg, color, size, align], "Title styles");
|
|
50
49
|
var E = as !== null && as !== void 0 ? as : "p";
|
|
51
50
|
return /*#__PURE__*/jsx(E, _objectSpread(_objectSpread({
|
|
52
|
-
className: classNames(
|
|
51
|
+
className: classNames("fabric-title", className, family && "font-".concat(family), !as && "text-lg"),
|
|
53
52
|
style: styles
|
|
54
53
|
}, aria), {}, {
|
|
55
54
|
children: children
|
|
@@ -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 };
|
|
@@ -4,19 +4,19 @@ 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;
|
|
@@ -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
|
*/
|
|
@@ -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
|
*/
|
|
@@ -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,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,5 +1,5 @@
|
|
|
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
|
|
@@ -8,7 +8,7 @@ export interface ChipProps extends CssProp, AriaProps, IconProps, TestProps, Chi
|
|
|
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
|
*/
|
|
@@ -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,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
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,9 +1,9 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type AriaProps, type ChildProp, type ColorType, type CssProp, type PaletteType, type TestProps } from "../../types";
|
|
2
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
|
*/
|
|
@@ -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,5 +1,5 @@
|
|
|
1
1
|
import { type ReactElement } 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 PolymorphicProps, type RefProp, type TestProps, type TooltipProp } from "../../types";
|
|
3
3
|
export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaProps, TestProps, IconProps, TooltipProp {
|
|
4
4
|
/**
|
|
5
5
|
* tab id
|
|
@@ -12,7 +12,7 @@ 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
|
*/
|
|
@@ -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;
|
|
@@ -8,9 +8,9 @@ export interface ThemeProps {
|
|
|
8
8
|
* branding css className
|
|
9
9
|
*
|
|
10
10
|
* .branding {
|
|
11
|
-
* --primary: #color;
|
|
12
|
-
* --accent: #color;
|
|
13
|
-
* --tint: #color;
|
|
11
|
+
* --color-primary: #color;
|
|
12
|
+
* --color-accent: #color;
|
|
13
|
+
* --color-tint: #color;
|
|
14
14
|
* }
|
|
15
15
|
*/
|
|
16
16
|
branding?: string;
|