@bioturing/components 0.15.0 → 0.15.2
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/dist/components/Badge/component.js +21 -0
- package/dist/components/Badge/component.js.map +1 -0
- package/dist/components/Badge/style.css +1 -0
- package/dist/components/Breadcrumb/component.js +46 -0
- package/dist/components/Breadcrumb/component.js.map +1 -0
- package/dist/components/Breadcrumb/style.css +1 -0
- package/dist/components/Breadcrumb/useItemRender.js +27 -0
- package/dist/components/Breadcrumb/useItemRender.js.map +1 -0
- package/dist/components/Button/component.js +9 -0
- package/dist/components/Button/component.js.map +1 -0
- package/dist/components/Button/style.css +1 -0
- package/dist/components/Checkbox/component.js +11 -0
- package/dist/components/Checkbox/component.js.map +1 -0
- package/dist/components/Checkbox/style.css +1 -0
- package/dist/components/CodeBlock/component.js +127 -0
- package/dist/components/CodeBlock/component.js.map +1 -0
- package/dist/components/CodeBlock/style.css +1 -0
- package/dist/components/DSRoot/component.js +21 -0
- package/dist/components/DSRoot/component.js.map +1 -0
- package/dist/components/DSRoot/context.js +9 -0
- package/dist/components/DSRoot/context.js.map +1 -0
- package/dist/components/DSRoot/style.css +1 -0
- package/dist/components/DropdownMenu/component.js +103 -0
- package/dist/components/DropdownMenu/component.js.map +1 -0
- package/dist/components/DropdownMenu/style.css +1 -0
- package/dist/components/Empty/component.js +48 -0
- package/dist/components/Empty/component.js.map +1 -0
- package/dist/components/Empty/style.css +1 -0
- package/dist/components/Field/component.js +30 -0
- package/dist/components/Field/component.js.map +1 -0
- package/dist/components/Field/style.css +1 -0
- package/dist/components/Form/component.js +23 -0
- package/dist/components/Form/component.js.map +1 -0
- package/dist/components/Form/item.js +30 -0
- package/dist/components/Form/item.js.map +1 -0
- package/dist/components/Form/style.css +1 -0
- package/dist/components/IconButton/component.js +49 -0
- package/dist/components/IconButton/component.js.map +1 -0
- package/dist/components/IconButton/style.css +1 -0
- package/dist/components/Input/component.js +25 -0
- package/dist/components/Input/component.js.map +1 -0
- package/dist/components/Modal/Modal.js +161 -0
- package/dist/components/Modal/Modal.js.map +1 -0
- package/dist/components/Modal/ModalProvider.js +70 -0
- package/dist/components/Modal/ModalProvider.js.map +1 -0
- package/dist/components/Modal/ModalService.js +25 -0
- package/dist/components/Modal/ModalService.js.map +1 -0
- package/dist/components/Modal/constants.js +5 -0
- package/dist/components/Modal/constants.js.map +1 -0
- package/dist/components/Modal/functions.js +27 -0
- package/dist/components/Modal/functions.js.map +1 -0
- package/dist/components/Modal/index.js +20 -0
- package/dist/components/Modal/index.js.map +1 -0
- package/dist/components/Modal/style.css +1 -0
- package/dist/components/Popover/component.js +12 -0
- package/dist/components/Popover/component.js.map +1 -0
- package/dist/components/PopupPanel/component.js +190 -0
- package/dist/components/PopupPanel/component.js.map +1 -0
- package/dist/components/PopupPanel/constants.js +5 -0
- package/dist/components/PopupPanel/constants.js.map +1 -0
- package/dist/components/PopupPanel/style.css +1 -0
- package/dist/components/Radio/component.js +22 -0
- package/dist/components/Radio/component.js.map +1 -0
- package/dist/components/Radio/style.css +1 -0
- package/dist/components/ScrollArea/component.js +40 -0
- package/dist/components/ScrollArea/component.js.map +1 -0
- package/dist/components/ScrollArea/style.css +1 -0
- package/dist/components/Segmented/component.js +9 -0
- package/dist/components/Segmented/component.js.map +1 -0
- package/dist/components/Segmented/style.css +1 -0
- package/dist/components/Select/component.js +135 -0
- package/dist/components/Select/component.js.map +1 -0
- package/dist/components/Select/style.css +1 -0
- package/dist/components/Slider/component.js +23 -0
- package/dist/components/Slider/component.js.map +1 -0
- package/dist/components/Spin/component.js +12 -0
- package/dist/components/Spin/component.js.map +1 -0
- package/dist/components/Spin/style.css +1 -0
- package/dist/components/Splitter/component.js +40 -0
- package/dist/components/Splitter/component.js.map +1 -0
- package/dist/components/Splitter/style.css +1 -0
- package/dist/components/Stack/Stack.js +37 -0
- package/dist/components/Stack/Stack.js.map +1 -0
- package/dist/components/Stack/StackChild.js +57 -0
- package/dist/components/Stack/StackChild.js.map +1 -0
- package/dist/components/Stack/index.js +9 -0
- package/dist/components/Stack/index.js.map +1 -0
- package/dist/components/Stack/style.css +1 -0
- package/dist/components/Switch/component.js +9 -0
- package/dist/components/Switch/component.js.map +1 -0
- package/dist/components/Switch/style.css +1 -0
- package/dist/components/Table/component.js +68 -0
- package/dist/components/Table/component.js.map +1 -0
- package/dist/components/Table/style.css +1 -0
- package/dist/components/Tag/component.js +30 -0
- package/dist/components/Tag/component.js.map +1 -0
- package/dist/components/Tag/style.css +1 -0
- package/dist/components/ThemeProvider/component.js +41 -0
- package/dist/components/ThemeProvider/component.js.map +1 -0
- package/dist/components/ThemeProvider/style.css +1 -0
- package/dist/components/Toast/component.js +101 -0
- package/dist/components/Toast/component.js.map +1 -0
- package/dist/components/Toast/function.js +25 -0
- package/dist/components/Toast/function.js.map +1 -0
- package/dist/components/Toast/style.css +1 -0
- package/dist/components/Tooltip/component.js +26 -0
- package/dist/components/Tooltip/component.js.map +1 -0
- package/dist/components/Tooltip/style.css +1 -0
- package/dist/components/Tour/component.js +35 -0
- package/dist/components/Tour/component.js.map +1 -0
- package/dist/components/Tour/style.css +1 -0
- package/dist/components/Transition/component.js +44 -0
- package/dist/components/Transition/component.js.map +1 -0
- package/dist/components/Tree/components.js +68 -0
- package/dist/components/Tree/components.js.map +1 -0
- package/dist/components/Tree/helpers.js +53 -0
- package/dist/components/Tree/helpers.js.map +1 -0
- package/dist/components/Tree/style.css +1 -0
- package/dist/components/Tree/useTreeCommon.js +86 -0
- package/dist/components/Tree/useTreeCommon.js.map +1 -0
- package/dist/components/Tree/useUniqueKeysTree.js +142 -0
- package/dist/components/Tree/useUniqueKeysTree.js.map +1 -0
- package/dist/components/Truncate/component.js +93 -0
- package/dist/components/Truncate/component.js.map +1 -0
- package/dist/components/Truncate/helpers.js +36 -0
- package/dist/components/Truncate/helpers.js.map +1 -0
- package/dist/components/Truncate/style.css +1 -0
- package/dist/components/Upload/component.js +39 -0
- package/dist/components/Upload/component.js.map +1 -0
- package/dist/components/Upload/dragger.js +23 -0
- package/dist/components/Upload/dragger.js.map +1 -0
- package/dist/components/Upload/hooks.js +18 -0
- package/dist/components/Upload/hooks.js.map +1 -0
- package/dist/components/Upload/item.js +84 -0
- package/dist/components/Upload/item.js.map +1 -0
- package/dist/components/Upload/utils.js +7 -0
- package/dist/components/Upload/utils.js.map +1 -0
- package/dist/components/VerticalCollapsiblePanel/component.js +125 -0
- package/dist/components/VerticalCollapsiblePanel/component.js.map +1 -0
- package/dist/components/VerticalCollapsiblePanel/style.css +1 -0
- package/dist/components/hooks/antd.js +22 -0
- package/dist/components/hooks/antd.js.map +1 -0
- package/dist/components/hooks/base-ui.js +47 -0
- package/dist/components/hooks/base-ui.js.map +1 -0
- package/dist/components/hooks/useCharts.js +28 -0
- package/dist/components/hooks/useCharts.js.map +1 -0
- package/dist/components/hooks/useControlledState.js +15 -0
- package/dist/components/hooks/useControlledState.js.map +1 -0
- package/dist/components/utils/WithAntdTokens.js +24 -0
- package/dist/components/utils/WithAntdTokens.js.map +1 -0
- package/dist/components/utils/antdUtils.js +58 -0
- package/dist/components/utils/antdUtils.js.map +1 -0
- package/dist/components/utils/cn.js +27 -0
- package/dist/components/utils/cn.js.map +1 -0
- package/dist/components/utils/isTracebackError.js +10 -0
- package/dist/components/utils/isTracebackError.js.map +1 -0
- package/dist/components/utils/reactToString.js +23 -0
- package/dist/components/utils/reactToString.js.map +1 -0
- package/dist/index.d.ts +2497 -3
- package/dist/index.js +188 -4004
- package/dist/index.js.map +1 -0
- package/dist/metadata.js +513 -0
- package/dist/metadata.js.map +1 -0
- package/dist/tailwind.css +1 -121
- package/dist/tailwind.d.ts +1 -0
- package/dist/tokens/and-theme/tokens.js +351 -0
- package/dist/tokens/and-theme/tokens.js.map +1 -0
- package/dist/tokens/charts/index.js +18 -0
- package/dist/tokens/charts/index.js.map +1 -0
- package/dist/tokens/charts/tokens.js +208 -0
- package/dist/tokens/charts/tokens.js.map +1 -0
- package/dist/tokens/utils.js +37 -0
- package/dist/tokens/utils.js.map +1 -0
- package/package.json +10 -108
- package/dist/Badge.css +0 -6
- package/dist/Badge.js +0 -41
- package/dist/Breadcrumb.css +0 -83
- package/dist/Breadcrumb.js +0 -92
- package/dist/Checkbox.css +0 -13
- package/dist/Checkbox.js +0 -12
- package/dist/CodeBlock.css +0 -213
- package/dist/CodeBlock.js +0 -644
- package/dist/Collapse.css +0 -21
- package/dist/Collapse.js +0 -49
- package/dist/DSRoot.css +0 -667
- package/dist/DSRoot.js +0 -1428
- package/dist/DropdownMenu.css +0 -95
- package/dist/DropdownMenu.js +0 -211
- package/dist/Empty.css +0 -19
- package/dist/Empty.js +0 -53
- package/dist/Field.css +0 -14
- package/dist/Field.js +0 -66
- package/dist/Form.css +0 -64
- package/dist/Form.js +0 -125
- package/dist/IconButton.css +0 -52
- package/dist/IconButton.js +0 -82
- package/dist/Input.js +0 -48
- package/dist/Modal.css +0 -317
- package/dist/Modal.js +0 -677
- package/dist/Popover.js +0 -10
- package/dist/PopupPanel.css +0 -170
- package/dist/PopupPanel.js +0 -333
- package/dist/Radio.css +0 -14
- package/dist/Radio.js +0 -24
- package/dist/ScrollArea.css +0 -64
- package/dist/ScrollArea.js +0 -50
- package/dist/Segmented.css +0 -16
- package/dist/Segmented.js +0 -10
- package/dist/Select.css +0 -24
- package/dist/Select.js +0 -157
- package/dist/Slider.js +0 -39
- package/dist/Spin.css +0 -36
- package/dist/Spin.js +0 -33
- package/dist/Splitter.css +0 -6
- package/dist/Splitter.js +0 -47
- package/dist/Switch.css +0 -7
- package/dist/Switch.js +0 -10
- package/dist/Table.css +0 -116
- package/dist/Table.js +0 -126
- package/dist/Tag.css +0 -17
- package/dist/Tag.js +0 -24
- package/dist/ThemeProvider.css +0 -39
- package/dist/ThemeProvider.js +0 -403
- package/dist/Toast.css +0 -622
- package/dist/Toast.js +0 -1401
- package/dist/Tooltip.css +0 -6
- package/dist/Tooltip.js +0 -36
- package/dist/Tour.css +0 -73
- package/dist/Tour.js +0 -54
- package/dist/Tree.js +0 -318
- package/dist/Truncate.css +0 -31
- package/dist/Truncate.js +0 -216
- package/dist/Upload.css +0 -144
- package/dist/Upload.js +0 -516
- package/dist/VerticalCollapsiblePanel.css +0 -193
- package/dist/VerticalCollapsiblePanel.js +0 -469
- package/dist/components/Badge/component.d.ts +0 -4
- package/dist/components/Badge/index.d.ts +0 -1
- package/dist/components/Breadcrumb/component.d.ts +0 -6
- package/dist/components/Breadcrumb/index.d.ts +0 -2
- package/dist/components/Breadcrumb/types.d.ts +0 -18
- package/dist/components/Breadcrumb/useItemRender.d.ts +0 -6
- package/dist/components/Button/component.d.ts +0 -8
- package/dist/components/Button/index.d.ts +0 -1
- package/dist/components/Checkbox/component.d.ts +0 -11
- package/dist/components/Checkbox/index.d.ts +0 -1
- package/dist/components/CodeBlock/component.d.ts +0 -3
- package/dist/components/CodeBlock/index.d.ts +0 -2
- package/dist/components/CodeBlock/types.d.ts +0 -59
- package/dist/components/Collapse/component.d.ts +0 -14
- package/dist/components/Collapse/index.d.ts +0 -1
- package/dist/components/DSRoot/component.d.ts +0 -14
- package/dist/components/DSRoot/context.d.ts +0 -7
- package/dist/components/DSRoot/index.d.ts +0 -1
- package/dist/components/DropdownMenu/component.d.ts +0 -31
- package/dist/components/DropdownMenu/index.d.ts +0 -2
- package/dist/components/Empty/component.d.ts +0 -13
- package/dist/components/Empty/index.d.ts +0 -1
- package/dist/components/Field/component.d.ts +0 -42
- package/dist/components/Field/index.d.ts +0 -1
- package/dist/components/Form/component.d.ts +0 -19
- package/dist/components/Form/index.d.ts +0 -1
- package/dist/components/Form/item.d.ts +0 -5
- package/dist/components/IconButton/component.d.ts +0 -30
- package/dist/components/IconButton/index.d.ts +0 -1
- package/dist/components/Input/component.d.ts +0 -30
- package/dist/components/Input/index.d.ts +0 -1
- package/dist/components/Modal/Modal.d.ts +0 -84
- package/dist/components/Modal/ModalProvider.d.ts +0 -5
- package/dist/components/Modal/ModalService.d.ts +0 -33
- package/dist/components/Modal/constants.d.ts +0 -9
- package/dist/components/Modal/functions.d.ts +0 -27
- package/dist/components/Modal/index.d.ts +0 -15
- package/dist/components/Popover/component.d.ts +0 -9
- package/dist/components/Popover/index.d.ts +0 -1
- package/dist/components/PopupPanel/component.d.ts +0 -61
- package/dist/components/PopupPanel/constants.d.ts +0 -7
- package/dist/components/PopupPanel/index.d.ts +0 -1
- package/dist/components/Radio/component.d.ts +0 -8
- package/dist/components/Radio/index.d.ts +0 -2
- package/dist/components/Radio/interface.d.ts +0 -5
- package/dist/components/ScrollArea/component.d.ts +0 -32
- package/dist/components/ScrollArea/index.d.ts +0 -1
- package/dist/components/Segmented/component.d.ts +0 -10
- package/dist/components/Segmented/index.d.ts +0 -1
- package/dist/components/Select/component.d.ts +0 -24
- package/dist/components/Select/index.d.ts +0 -1
- package/dist/components/Slider/component.d.ts +0 -5
- package/dist/components/Slider/index.d.ts +0 -1
- package/dist/components/Spin/component.d.ts +0 -4
- package/dist/components/Spin/index.d.ts +0 -1
- package/dist/components/Splitter/component.d.ts +0 -13
- package/dist/components/Splitter/index.d.ts +0 -1
- package/dist/components/Stack/Stack.d.ts +0 -39
- package/dist/components/Stack/StackChild.d.ts +0 -30
- package/dist/components/Stack/index.d.ts +0 -8
- package/dist/components/Switch/component.d.ts +0 -9
- package/dist/components/Switch/index.d.ts +0 -1
- package/dist/components/Table/component.d.ts +0 -20
- package/dist/components/Table/index.d.ts +0 -1
- package/dist/components/Tag/component.d.ts +0 -12
- package/dist/components/Tag/index.d.ts +0 -1
- package/dist/components/ThemeProvider/component.d.ts +0 -7
- package/dist/components/ThemeProvider/index.d.ts +0 -1
- package/dist/components/Toast/component.d.ts +0 -15
- package/dist/components/Toast/function.d.ts +0 -10
- package/dist/components/Toast/index.d.ts +0 -3
- package/dist/components/Toast/types.d.ts +0 -3
- package/dist/components/Tooltip/component.d.ts +0 -10
- package/dist/components/Tooltip/index.d.ts +0 -1
- package/dist/components/Tour/component.d.ts +0 -8
- package/dist/components/Tour/index.d.ts +0 -1
- package/dist/components/Transition/component.d.ts +0 -17
- package/dist/components/Transition/index.d.ts +0 -1
- package/dist/components/Tree/components.d.ts +0 -13
- package/dist/components/Tree/helpers.d.ts +0 -4
- package/dist/components/Tree/index.d.ts +0 -4
- package/dist/components/Tree/types.d.ts +0 -55
- package/dist/components/Tree/useTreeCommon.d.ts +0 -178
- package/dist/components/Tree/useUniqueKeysTree.d.ts +0 -33
- package/dist/components/Truncate/component.d.ts +0 -15
- package/dist/components/Truncate/helpers.d.ts +0 -5
- package/dist/components/Truncate/index.d.ts +0 -1
- package/dist/components/Upload/component.d.ts +0 -16
- package/dist/components/Upload/dragger.d.ts +0 -13
- package/dist/components/Upload/hooks.d.ts +0 -5
- package/dist/components/Upload/index.d.ts +0 -4
- package/dist/components/Upload/item.d.ts +0 -11
- package/dist/components/Upload/utils.d.ts +0 -1
- package/dist/components/VerticalCollapsiblePanel/component.d.ts +0 -65
- package/dist/components/VerticalCollapsiblePanel/index.d.ts +0 -1
- package/dist/components/hooks/antd.d.ts +0 -11
- package/dist/components/hooks/base-ui.d.ts +0 -7
- package/dist/components/hooks/index.d.ts +0 -4
- package/dist/components/hooks/useCharts.d.ts +0 -22
- package/dist/components/hooks/useControlledState.d.ts +0 -1
- package/dist/components/index.d.ts +0 -41
- package/dist/components/utils/WithAntdTokens.d.ts +0 -7
- package/dist/components/utils/antdUtils.d.ts +0 -15
- package/dist/components/utils/client.d.ts +0 -2
- package/dist/components/utils/cn.d.ts +0 -4
- package/dist/components/utils/index.d.ts +0 -3
- package/dist/components/utils/isTracebackError.d.ts +0 -1
- package/dist/components/utils/main.d.ts +0 -3
- package/dist/components/utils/reactToString.d.ts +0 -2
- package/dist/components/utils/types.d.ts +0 -9
- package/dist/hooks.js +0 -961
- package/dist/index.css +0 -1471
- package/dist/metadata.d.ts +0 -363
- package/dist/tokens/and-theme/index.d.ts +0 -1
- package/dist/tokens/and-theme/tokens.d.ts +0 -5
- package/dist/tokens/charts/index.d.ts +0 -6
- package/dist/tokens/charts/tokens.d.ts +0 -455
- package/dist/tokens/index.d.ts +0 -2
- package/dist/tokens/utils.d.ts +0 -16
- package/dist/utils.js +0 -120
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
import { resolveColorTokens as a } from "../utils.js";
|
|
2
|
+
import { antdColorTokens as r } from "../and-theme/tokens.js";
|
|
3
|
+
const o = {
|
|
4
|
+
colorChartsRed300: { light: "#ea7158", dark: "#d63f38" },
|
|
5
|
+
colorChartsRed400: { light: "#dc5032", dark: "#ed5958" },
|
|
6
|
+
colorChartsRed500: { light: "#d13313", dark: "#fe6e73" },
|
|
7
|
+
colorChartsRed600: { light: "#ba2e0f", dark: "#ff8a8a" },
|
|
8
|
+
colorChartsRed700: { light: "#a82a0c", dark: "#ffa09e" },
|
|
9
|
+
colorChartsRed800: { light: "#972709", dark: "#ffb3b0" },
|
|
10
|
+
colorChartsRed900: { light: "#892407", dark: "#ffc4c0" },
|
|
11
|
+
colorChartsRed1000: { light: "#7d2105", dark: "#ffd2cf" },
|
|
12
|
+
colorChartsRed1100: { light: "#721e03", dark: "#ffe0dd" },
|
|
13
|
+
colorChartsRed1200: { light: "#671c00", dark: "#ffecea" },
|
|
14
|
+
colorChartsOrange300: { light: "#e07941", dark: "#c55305" },
|
|
15
|
+
colorChartsOrange400: { light: "#cc5f21", dark: "#de6923" },
|
|
16
|
+
colorChartsOrange500: { light: "#bc4d01", dark: "#f27c36" },
|
|
17
|
+
colorChartsOrange600: { light: "#a84401", dark: "#f89256" },
|
|
18
|
+
colorChartsOrange700: { light: "#983c02", dark: "#fca572" },
|
|
19
|
+
colorChartsOrange800: { light: "#8a3603", dark: "#ffb68b" },
|
|
20
|
+
colorChartsOrange900: { light: "#7e3103", dark: "#ffc6a4" },
|
|
21
|
+
colorChartsOrange1000: { light: "#732c02", dark: "#ffd4bb" },
|
|
22
|
+
colorChartsOrange1100: { light: "#692801", dark: "#ffe1cf" },
|
|
23
|
+
colorChartsOrange1200: { light: "#602400", dark: "#ffede2" },
|
|
24
|
+
colorChartsYellow300: { light: "#b2911c", dark: "#977001" },
|
|
25
|
+
colorChartsYellow400: { light: "#9c7b0b", dark: "#b08400" },
|
|
26
|
+
colorChartsYellow500: { light: "#8a6b05", dark: "#c59600" },
|
|
27
|
+
colorChartsYellow600: { light: "#7b5f04", dark: "#d3a61c" },
|
|
28
|
+
colorChartsYellow700: { light: "#6f5504", dark: "#dfb52c" },
|
|
29
|
+
colorChartsYellow800: { light: "#654d03", dark: "#eac33a" },
|
|
30
|
+
colorChartsYellow900: { light: "#5d4503", dark: "#f1cf65" },
|
|
31
|
+
colorChartsYellow1000: { light: "#553f03", dark: "#f7db8a" },
|
|
32
|
+
colorChartsYellow1100: { light: "#4d3901", dark: "#fce5a8" },
|
|
33
|
+
colorChartsYellow1200: { light: "#483300", dark: "#ffefc9" },
|
|
34
|
+
colorChartsGreen300: { light: "#67a353", dark: "#48851a" },
|
|
35
|
+
colorChartsGreen400: { light: "#41902c", dark: "#5a9b29" },
|
|
36
|
+
colorChartsGreen500: { light: "#1f8104", dark: "#69ae34" },
|
|
37
|
+
colorChartsGreen600: { light: "#1a7302", dark: "#7dbd4c" },
|
|
38
|
+
colorChartsGreen700: { light: "#176702", dark: "#8fca61" },
|
|
39
|
+
colorChartsGreen800: { light: "#145d02", dark: "#9fd673" },
|
|
40
|
+
colorChartsGreen900: { light: "#125502", dark: "#b2df8d" },
|
|
41
|
+
colorChartsGreen1000: { light: "#104d01", dark: "#c5e7a8" },
|
|
42
|
+
colorChartsGreen1100: { light: "#0f4601", dark: "#d5efbe" },
|
|
43
|
+
colorChartsGreen1200: { light: "#0d4000", dark: "#e4f7d5" },
|
|
44
|
+
colorChartsTeal300: { light: "#2ea597", dark: "#018977" },
|
|
45
|
+
colorChartsTeal400: { light: "#1c8e81", dark: "#009d89" },
|
|
46
|
+
colorChartsTeal500: { light: "#0d7d70", dark: "#00b09b" },
|
|
47
|
+
colorChartsTeal600: { light: "#096f64", dark: "#40bfa9" },
|
|
48
|
+
colorChartsTeal700: { light: "#06645a", dark: "#5fccb7" },
|
|
49
|
+
colorChartsTeal800: { light: "#045b52", dark: "#77d7c3" },
|
|
50
|
+
colorChartsTeal900: { light: "#03524a", dark: "#94e0d0" },
|
|
51
|
+
colorChartsTeal1000: { light: "#014b44", dark: "#ace9db" },
|
|
52
|
+
colorChartsTeal1100: { light: "#01443e", dark: "#c2f0e6" },
|
|
53
|
+
colorChartsTeal1200: { light: "#003e38", dark: "#d7f7f0" },
|
|
54
|
+
colorChartsBlue1300: { light: "#529ccb", dark: "#00819c" },
|
|
55
|
+
colorChartsBlue1400: { light: "#3184c2", dark: "#0497ba" },
|
|
56
|
+
colorChartsBlue1500: { light: "#0273bb", dark: "#08aad2" },
|
|
57
|
+
colorChartsBlue1600: { light: "#0166ab", dark: "#44b9dd" },
|
|
58
|
+
colorChartsBlue1700: { light: "#015b9d", dark: "#63c6e7" },
|
|
59
|
+
colorChartsBlue1800: { light: "#015292", dark: "#79d2f0" },
|
|
60
|
+
colorChartsBlue1900: { light: "#014a87", dark: "#98dcf5" },
|
|
61
|
+
colorChartsBlue11000: { light: "#01437d", dark: "#b3e4f8" },
|
|
62
|
+
colorChartsBlue11100: { light: "#003c75", dark: "#caedfc" },
|
|
63
|
+
colorChartsBlue11200: { light: "#00366d", dark: "#ddf4ff" },
|
|
64
|
+
colorChartsBlue2300: { light: "#688ae8", dark: "#486de8" },
|
|
65
|
+
colorChartsBlue2400: { light: "#5978e3", dark: "#6384f5" },
|
|
66
|
+
colorChartsBlue2500: { light: "#4066df", dark: "#7698fe" },
|
|
67
|
+
colorChartsBlue2600: { light: "#3759ce", dark: "#8ea9ff" },
|
|
68
|
+
colorChartsBlue2700: { light: "#314fbf", dark: "#a2b8ff" },
|
|
69
|
+
colorChartsBlue2800: { light: "#2c46b1", dark: "#b1c5ff" },
|
|
70
|
+
colorChartsBlue2900: { light: "#273ea5", dark: "#c3d1ff" },
|
|
71
|
+
colorChartsBlue21000: { light: "#23379b", dark: "#d2dcff" },
|
|
72
|
+
colorChartsBlue21100: { light: "#1f3191", dark: "#dfe6ff" },
|
|
73
|
+
colorChartsBlue21200: { light: "#1b2b88", dark: "#ecf0ff" },
|
|
74
|
+
colorChartsPurple300: { light: "#a783e1", dark: "#8d59de" },
|
|
75
|
+
colorChartsPurple400: { light: "#9469d6", dark: "#a173ea" },
|
|
76
|
+
colorChartsPurple500: { light: "#8456ce", dark: "#b088f5" },
|
|
77
|
+
colorChartsPurple600: { light: "#7749bf", dark: "#bf9bf9" },
|
|
78
|
+
colorChartsPurple700: { light: "#6b40b2", dark: "#cbabfc" },
|
|
79
|
+
colorChartsPurple800: { light: "#6237a7", dark: "#d6baff" },
|
|
80
|
+
colorChartsPurple900: { light: "#59309d", dark: "#dfc8ff" },
|
|
81
|
+
colorChartsPurple1000: { light: "#512994", dark: "#e8d5ff" },
|
|
82
|
+
colorChartsPurple1100: { light: "#4a238b", dark: "#efe2ff" },
|
|
83
|
+
colorChartsPurple1200: { light: "#431d84", dark: "#f5edff" },
|
|
84
|
+
colorChartsPink300: { light: "#da7596", dark: "#c64a70" },
|
|
85
|
+
colorChartsPink400: { light: "#ce567c", dark: "#d56889" },
|
|
86
|
+
colorChartsPink500: { light: "#c33d69", dark: "#e07f9d" },
|
|
87
|
+
colorChartsPink600: { light: "#b1325c", dark: "#eb92ad" },
|
|
88
|
+
colorChartsPink700: { light: "#a32952", dark: "#f5a2bb" },
|
|
89
|
+
colorChartsPink800: { light: "#962249", dark: "#ffb0c8" },
|
|
90
|
+
colorChartsPink900: { light: "#8b1b42", dark: "#ffc1d4" },
|
|
91
|
+
colorChartsPink1000: { light: "#81143b", dark: "#ffd1de" },
|
|
92
|
+
colorChartsPink1100: { light: "#780d35", dark: "#ffdfe8" },
|
|
93
|
+
colorChartsPink1200: { light: "#6f062f", dark: "#ffecf1" },
|
|
94
|
+
colorChartsStatusCritical: {
|
|
95
|
+
light: "{colorChartsRed1000}",
|
|
96
|
+
dark: "{colorChartsRed300}"
|
|
97
|
+
},
|
|
98
|
+
colorChartsStatusHigh: {
|
|
99
|
+
light: "{colorChartsRed600}",
|
|
100
|
+
dark: "{colorChartsRed500}"
|
|
101
|
+
},
|
|
102
|
+
colorChartsStatusMedium: {
|
|
103
|
+
light: "{colorChartsOrange400}",
|
|
104
|
+
dark: "{colorChartsOrange600}"
|
|
105
|
+
},
|
|
106
|
+
colorChartsStatusLow: {
|
|
107
|
+
light: "{colorChartsYellow300}",
|
|
108
|
+
dark: "{colorChartsYellow700}"
|
|
109
|
+
},
|
|
110
|
+
colorChartsStatusPositive: {
|
|
111
|
+
light: "{colorChartsGreen300}",
|
|
112
|
+
dark: "{colorChartsGreen500}"
|
|
113
|
+
},
|
|
114
|
+
colorChartsStatusInfo: {
|
|
115
|
+
light: "{colorChartsBlue1400}",
|
|
116
|
+
dark: "{colorChartsBlue1500}"
|
|
117
|
+
},
|
|
118
|
+
// colorChartsStatusNeutral: "{colorGrey500}",
|
|
119
|
+
// colorChartsThresholdNegative: {
|
|
120
|
+
// light: "{colorRed600}",
|
|
121
|
+
// dark: "{colorRed500}",
|
|
122
|
+
// },
|
|
123
|
+
// colorChartsThresholdPositive: {
|
|
124
|
+
// light: "{colorGreen600}",
|
|
125
|
+
// dark: "{colorGreen500}",
|
|
126
|
+
// },
|
|
127
|
+
// colorChartsThresholdInfo: { light: "{colorBlue600}", dark: "{colorBlue400}" },
|
|
128
|
+
// colorChartsThresholdNeutral: {
|
|
129
|
+
// light: "{colorGrey550}",
|
|
130
|
+
// dark: "{colorGrey450}",
|
|
131
|
+
// },
|
|
132
|
+
// colorChartsLineGrid: { light: "{colorGrey300}", dark: "{colorGrey600}" },
|
|
133
|
+
// colorChartsLineTick: { light: "{colorGrey300}", dark: "{colorGrey600}" },
|
|
134
|
+
// colorChartsLineAxis: { light: "{colorGrey300}", dark: "{colorGrey600}" },
|
|
135
|
+
colorChartsStatusNeutral: r.colorTextSecondary,
|
|
136
|
+
colorChartsThresholdNegative: r.colorError,
|
|
137
|
+
colorChartsThresholdPositive: r.colorSuccess,
|
|
138
|
+
colorChartsThresholdInfo: r.colorInfo,
|
|
139
|
+
colorChartsThresholdNeutral: r.colorTextTertiary,
|
|
140
|
+
colorChartsLineGrid: {
|
|
141
|
+
light: "#DADADC",
|
|
142
|
+
dark: "#434347"
|
|
143
|
+
},
|
|
144
|
+
colorChartsLineTick: "{colorChartsLineGrid}",
|
|
145
|
+
colorChartsLineAxis: {
|
|
146
|
+
light: "#C8C8CB",
|
|
147
|
+
dark: "#73737A"
|
|
148
|
+
},
|
|
149
|
+
colorChartsLabelAxis: {
|
|
150
|
+
light: "#7C7C83",
|
|
151
|
+
dark: "#898990"
|
|
152
|
+
},
|
|
153
|
+
colorChartsPaletteCategorical1: "{colorChartsBlue2300}",
|
|
154
|
+
colorChartsPaletteCategorical2: "{colorChartsPink500}",
|
|
155
|
+
colorChartsPaletteCategorical3: "{colorChartsTeal300}",
|
|
156
|
+
colorChartsPaletteCategorical4: "{colorChartsPurple500}",
|
|
157
|
+
colorChartsPaletteCategorical5: "{colorChartsOrange300}",
|
|
158
|
+
colorChartsPaletteCategorical6: "{colorChartsBlue2600}",
|
|
159
|
+
colorChartsPaletteCategorical7: "{colorChartsPink800}",
|
|
160
|
+
colorChartsPaletteCategorical8: "{colorChartsTeal600}",
|
|
161
|
+
colorChartsPaletteCategorical9: "{colorChartsPurple800}",
|
|
162
|
+
colorChartsPaletteCategorical10: "{colorChartsOrange600}",
|
|
163
|
+
colorChartsPaletteCategorical11: "{colorChartsBlue2900}",
|
|
164
|
+
colorChartsPaletteCategorical12: "{colorChartsPink1100}",
|
|
165
|
+
colorChartsPaletteCategorical13: "{colorChartsTeal900}",
|
|
166
|
+
colorChartsPaletteCategorical14: "{colorChartsPurple1100}",
|
|
167
|
+
colorChartsPaletteCategorical15: "{colorChartsOrange900}",
|
|
168
|
+
colorChartsPaletteCategorical16: "{colorChartsBlue21200}",
|
|
169
|
+
colorChartsPaletteCategorical17: "{colorChartsPink400}",
|
|
170
|
+
colorChartsPaletteCategorical18: "{colorChartsTeal1200}",
|
|
171
|
+
colorChartsPaletteCategorical19: "{colorChartsPurple400}",
|
|
172
|
+
colorChartsPaletteCategorical20: "{colorChartsOrange1200}",
|
|
173
|
+
colorChartsPaletteCategorical21: "{colorChartsBlue2500}",
|
|
174
|
+
colorChartsPaletteCategorical22: "{colorChartsPink700}",
|
|
175
|
+
colorChartsPaletteCategorical23: "{colorChartsTeal500}",
|
|
176
|
+
colorChartsPaletteCategorical24: "{colorChartsPurple700}",
|
|
177
|
+
colorChartsPaletteCategorical25: "{colorChartsOrange500}",
|
|
178
|
+
colorChartsPaletteCategorical26: "{colorChartsBlue2800}",
|
|
179
|
+
colorChartsPaletteCategorical27: "{colorChartsPink1000}",
|
|
180
|
+
colorChartsPaletteCategorical28: "{colorChartsTeal800}",
|
|
181
|
+
colorChartsPaletteCategorical29: "{colorChartsPurple1000}",
|
|
182
|
+
colorChartsPaletteCategorical30: "{colorChartsOrange800}",
|
|
183
|
+
colorChartsPaletteCategorical31: "{colorChartsBlue21100}",
|
|
184
|
+
colorChartsPaletteCategorical32: "{colorChartsPink300}",
|
|
185
|
+
colorChartsPaletteCategorical33: "{colorChartsTeal1100}",
|
|
186
|
+
colorChartsPaletteCategorical34: "{colorChartsPurple300}",
|
|
187
|
+
colorChartsPaletteCategorical35: "{colorChartsOrange1100}",
|
|
188
|
+
colorChartsPaletteCategorical36: "{colorChartsBlue2400}",
|
|
189
|
+
colorChartsPaletteCategorical37: "{colorChartsPink600}",
|
|
190
|
+
colorChartsPaletteCategorical38: "{colorChartsTeal400}",
|
|
191
|
+
colorChartsPaletteCategorical39: "{colorChartsPurple600}",
|
|
192
|
+
colorChartsPaletteCategorical40: "{colorChartsOrange400}",
|
|
193
|
+
colorChartsPaletteCategorical41: "{colorChartsBlue2700}",
|
|
194
|
+
colorChartsPaletteCategorical42: "{colorChartsPink900}",
|
|
195
|
+
colorChartsPaletteCategorical43: "{colorChartsTeal700}",
|
|
196
|
+
colorChartsPaletteCategorical44: "{colorChartsPurple900}",
|
|
197
|
+
colorChartsPaletteCategorical45: "{colorChartsOrange700}",
|
|
198
|
+
colorChartsPaletteCategorical46: "{colorChartsBlue21000}",
|
|
199
|
+
colorChartsPaletteCategorical47: "{colorChartsPink1200}",
|
|
200
|
+
colorChartsPaletteCategorical48: "{colorChartsTeal1000}",
|
|
201
|
+
colorChartsPaletteCategorical49: "{colorChartsPurple1200}",
|
|
202
|
+
colorChartsPaletteCategorical50: "{colorChartsOrange1000}"
|
|
203
|
+
}, e = a(o);
|
|
204
|
+
export {
|
|
205
|
+
e as chartColorTokens,
|
|
206
|
+
o as rawChartColorTokens
|
|
207
|
+
};
|
|
208
|
+
//# sourceMappingURL=tokens.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tokens.js","sources":["../../../src/tokens/charts/tokens.ts"],"sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { resolveColorTokens } from \"../utils\";\nimport { antdColorTokens } from \"../and-theme\";\n\nexport const rawChartColorTokens = {\n colorChartsRed300: { light: \"#ea7158\", dark: \"#d63f38\" },\n colorChartsRed400: { light: \"#dc5032\", dark: \"#ed5958\" },\n colorChartsRed500: { light: \"#d13313\", dark: \"#fe6e73\" },\n colorChartsRed600: { light: \"#ba2e0f\", dark: \"#ff8a8a\" },\n colorChartsRed700: { light: \"#a82a0c\", dark: \"#ffa09e\" },\n colorChartsRed800: { light: \"#972709\", dark: \"#ffb3b0\" },\n colorChartsRed900: { light: \"#892407\", dark: \"#ffc4c0\" },\n colorChartsRed1000: { light: \"#7d2105\", dark: \"#ffd2cf\" },\n colorChartsRed1100: { light: \"#721e03\", dark: \"#ffe0dd\" },\n colorChartsRed1200: { light: \"#671c00\", dark: \"#ffecea\" },\n colorChartsOrange300: { light: \"#e07941\", dark: \"#c55305\" },\n colorChartsOrange400: { light: \"#cc5f21\", dark: \"#de6923\" },\n colorChartsOrange500: { light: \"#bc4d01\", dark: \"#f27c36\" },\n colorChartsOrange600: { light: \"#a84401\", dark: \"#f89256\" },\n colorChartsOrange700: { light: \"#983c02\", dark: \"#fca572\" },\n colorChartsOrange800: { light: \"#8a3603\", dark: \"#ffb68b\" },\n colorChartsOrange900: { light: \"#7e3103\", dark: \"#ffc6a4\" },\n colorChartsOrange1000: { light: \"#732c02\", dark: \"#ffd4bb\" },\n colorChartsOrange1100: { light: \"#692801\", dark: \"#ffe1cf\" },\n colorChartsOrange1200: { light: \"#602400\", dark: \"#ffede2\" },\n colorChartsYellow300: { light: \"#b2911c\", dark: \"#977001\" },\n colorChartsYellow400: { light: \"#9c7b0b\", dark: \"#b08400\" },\n colorChartsYellow500: { light: \"#8a6b05\", dark: \"#c59600\" },\n colorChartsYellow600: { light: \"#7b5f04\", dark: \"#d3a61c\" },\n colorChartsYellow700: { light: \"#6f5504\", dark: \"#dfb52c\" },\n colorChartsYellow800: { light: \"#654d03\", dark: \"#eac33a\" },\n colorChartsYellow900: { light: \"#5d4503\", dark: \"#f1cf65\" },\n colorChartsYellow1000: { light: \"#553f03\", dark: \"#f7db8a\" },\n colorChartsYellow1100: { light: \"#4d3901\", dark: \"#fce5a8\" },\n colorChartsYellow1200: { light: \"#483300\", dark: \"#ffefc9\" },\n colorChartsGreen300: { light: \"#67a353\", dark: \"#48851a\" },\n colorChartsGreen400: { light: \"#41902c\", dark: \"#5a9b29\" },\n colorChartsGreen500: { light: \"#1f8104\", dark: \"#69ae34\" },\n colorChartsGreen600: { light: \"#1a7302\", dark: \"#7dbd4c\" },\n colorChartsGreen700: { light: \"#176702\", dark: \"#8fca61\" },\n colorChartsGreen800: { light: \"#145d02\", dark: \"#9fd673\" },\n colorChartsGreen900: { light: \"#125502\", dark: \"#b2df8d\" },\n colorChartsGreen1000: { light: \"#104d01\", dark: \"#c5e7a8\" },\n colorChartsGreen1100: { light: \"#0f4601\", dark: \"#d5efbe\" },\n colorChartsGreen1200: { light: \"#0d4000\", dark: \"#e4f7d5\" },\n colorChartsTeal300: { light: \"#2ea597\", dark: \"#018977\" },\n colorChartsTeal400: { light: \"#1c8e81\", dark: \"#009d89\" },\n colorChartsTeal500: { light: \"#0d7d70\", dark: \"#00b09b\" },\n colorChartsTeal600: { light: \"#096f64\", dark: \"#40bfa9\" },\n colorChartsTeal700: { light: \"#06645a\", dark: \"#5fccb7\" },\n colorChartsTeal800: { light: \"#045b52\", dark: \"#77d7c3\" },\n colorChartsTeal900: { light: \"#03524a\", dark: \"#94e0d0\" },\n colorChartsTeal1000: { light: \"#014b44\", dark: \"#ace9db\" },\n colorChartsTeal1100: { light: \"#01443e\", dark: \"#c2f0e6\" },\n colorChartsTeal1200: { light: \"#003e38\", dark: \"#d7f7f0\" },\n colorChartsBlue1300: { light: \"#529ccb\", dark: \"#00819c\" },\n colorChartsBlue1400: { light: \"#3184c2\", dark: \"#0497ba\" },\n colorChartsBlue1500: { light: \"#0273bb\", dark: \"#08aad2\" },\n colorChartsBlue1600: { light: \"#0166ab\", dark: \"#44b9dd\" },\n colorChartsBlue1700: { light: \"#015b9d\", dark: \"#63c6e7\" },\n colorChartsBlue1800: { light: \"#015292\", dark: \"#79d2f0\" },\n colorChartsBlue1900: { light: \"#014a87\", dark: \"#98dcf5\" },\n colorChartsBlue11000: { light: \"#01437d\", dark: \"#b3e4f8\" },\n colorChartsBlue11100: { light: \"#003c75\", dark: \"#caedfc\" },\n colorChartsBlue11200: { light: \"#00366d\", dark: \"#ddf4ff\" },\n colorChartsBlue2300: { light: \"#688ae8\", dark: \"#486de8\" },\n colorChartsBlue2400: { light: \"#5978e3\", dark: \"#6384f5\" },\n colorChartsBlue2500: { light: \"#4066df\", dark: \"#7698fe\" },\n colorChartsBlue2600: { light: \"#3759ce\", dark: \"#8ea9ff\" },\n colorChartsBlue2700: { light: \"#314fbf\", dark: \"#a2b8ff\" },\n colorChartsBlue2800: { light: \"#2c46b1\", dark: \"#b1c5ff\" },\n colorChartsBlue2900: { light: \"#273ea5\", dark: \"#c3d1ff\" },\n colorChartsBlue21000: { light: \"#23379b\", dark: \"#d2dcff\" },\n colorChartsBlue21100: { light: \"#1f3191\", dark: \"#dfe6ff\" },\n colorChartsBlue21200: { light: \"#1b2b88\", dark: \"#ecf0ff\" },\n colorChartsPurple300: { light: \"#a783e1\", dark: \"#8d59de\" },\n colorChartsPurple400: { light: \"#9469d6\", dark: \"#a173ea\" },\n colorChartsPurple500: { light: \"#8456ce\", dark: \"#b088f5\" },\n colorChartsPurple600: { light: \"#7749bf\", dark: \"#bf9bf9\" },\n colorChartsPurple700: { light: \"#6b40b2\", dark: \"#cbabfc\" },\n colorChartsPurple800: { light: \"#6237a7\", dark: \"#d6baff\" },\n colorChartsPurple900: { light: \"#59309d\", dark: \"#dfc8ff\" },\n colorChartsPurple1000: { light: \"#512994\", dark: \"#e8d5ff\" },\n colorChartsPurple1100: { light: \"#4a238b\", dark: \"#efe2ff\" },\n colorChartsPurple1200: { light: \"#431d84\", dark: \"#f5edff\" },\n colorChartsPink300: { light: \"#da7596\", dark: \"#c64a70\" },\n colorChartsPink400: { light: \"#ce567c\", dark: \"#d56889\" },\n colorChartsPink500: { light: \"#c33d69\", dark: \"#e07f9d\" },\n colorChartsPink600: { light: \"#b1325c\", dark: \"#eb92ad\" },\n colorChartsPink700: { light: \"#a32952\", dark: \"#f5a2bb\" },\n colorChartsPink800: { light: \"#962249\", dark: \"#ffb0c8\" },\n colorChartsPink900: { light: \"#8b1b42\", dark: \"#ffc1d4\" },\n colorChartsPink1000: { light: \"#81143b\", dark: \"#ffd1de\" },\n colorChartsPink1100: { light: \"#780d35\", dark: \"#ffdfe8\" },\n colorChartsPink1200: { light: \"#6f062f\", dark: \"#ffecf1\" },\n colorChartsStatusCritical: {\n light: \"{colorChartsRed1000}\",\n dark: \"{colorChartsRed300}\",\n },\n colorChartsStatusHigh: {\n light: \"{colorChartsRed600}\",\n dark: \"{colorChartsRed500}\",\n },\n colorChartsStatusMedium: {\n light: \"{colorChartsOrange400}\",\n dark: \"{colorChartsOrange600}\",\n },\n colorChartsStatusLow: {\n light: \"{colorChartsYellow300}\",\n dark: \"{colorChartsYellow700}\",\n },\n colorChartsStatusPositive: {\n light: \"{colorChartsGreen300}\",\n dark: \"{colorChartsGreen500}\",\n },\n colorChartsStatusInfo: {\n light: \"{colorChartsBlue1400}\",\n dark: \"{colorChartsBlue1500}\",\n },\n // colorChartsStatusNeutral: \"{colorGrey500}\",\n // colorChartsThresholdNegative: {\n // light: \"{colorRed600}\",\n // dark: \"{colorRed500}\",\n // },\n // colorChartsThresholdPositive: {\n // light: \"{colorGreen600}\",\n // dark: \"{colorGreen500}\",\n // },\n // colorChartsThresholdInfo: { light: \"{colorBlue600}\", dark: \"{colorBlue400}\" },\n // colorChartsThresholdNeutral: {\n // light: \"{colorGrey550}\",\n // dark: \"{colorGrey450}\",\n // },\n // colorChartsLineGrid: { light: \"{colorGrey300}\", dark: \"{colorGrey600}\" },\n // colorChartsLineTick: { light: \"{colorGrey300}\", dark: \"{colorGrey600}\" },\n // colorChartsLineAxis: { light: \"{colorGrey300}\", dark: \"{colorGrey600}\" },\n colorChartsStatusNeutral: antdColorTokens.colorTextSecondary,\n colorChartsThresholdNegative: antdColorTokens.colorError,\n colorChartsThresholdPositive: antdColorTokens.colorSuccess,\n colorChartsThresholdInfo: antdColorTokens.colorInfo,\n colorChartsThresholdNeutral: antdColorTokens.colorTextTertiary,\n colorChartsLineGrid: {\n light: \"#DADADC\",\n dark: \"#434347\",\n },\n colorChartsLineTick: \"{colorChartsLineGrid}\",\n colorChartsLineAxis: {\n light: \"#C8C8CB\",\n dark: \"#73737A\",\n },\n colorChartsLabelAxis: {\n light: \"#7C7C83\",\n dark: \"#898990\",\n },\n colorChartsPaletteCategorical1: \"{colorChartsBlue2300}\",\n colorChartsPaletteCategorical2: \"{colorChartsPink500}\",\n colorChartsPaletteCategorical3: \"{colorChartsTeal300}\",\n colorChartsPaletteCategorical4: \"{colorChartsPurple500}\",\n colorChartsPaletteCategorical5: \"{colorChartsOrange300}\",\n colorChartsPaletteCategorical6: \"{colorChartsBlue2600}\",\n colorChartsPaletteCategorical7: \"{colorChartsPink800}\",\n colorChartsPaletteCategorical8: \"{colorChartsTeal600}\",\n colorChartsPaletteCategorical9: \"{colorChartsPurple800}\",\n colorChartsPaletteCategorical10: \"{colorChartsOrange600}\",\n colorChartsPaletteCategorical11: \"{colorChartsBlue2900}\",\n colorChartsPaletteCategorical12: \"{colorChartsPink1100}\",\n colorChartsPaletteCategorical13: \"{colorChartsTeal900}\",\n colorChartsPaletteCategorical14: \"{colorChartsPurple1100}\",\n colorChartsPaletteCategorical15: \"{colorChartsOrange900}\",\n colorChartsPaletteCategorical16: \"{colorChartsBlue21200}\",\n colorChartsPaletteCategorical17: \"{colorChartsPink400}\",\n colorChartsPaletteCategorical18: \"{colorChartsTeal1200}\",\n colorChartsPaletteCategorical19: \"{colorChartsPurple400}\",\n colorChartsPaletteCategorical20: \"{colorChartsOrange1200}\",\n colorChartsPaletteCategorical21: \"{colorChartsBlue2500}\",\n colorChartsPaletteCategorical22: \"{colorChartsPink700}\",\n colorChartsPaletteCategorical23: \"{colorChartsTeal500}\",\n colorChartsPaletteCategorical24: \"{colorChartsPurple700}\",\n colorChartsPaletteCategorical25: \"{colorChartsOrange500}\",\n colorChartsPaletteCategorical26: \"{colorChartsBlue2800}\",\n colorChartsPaletteCategorical27: \"{colorChartsPink1000}\",\n colorChartsPaletteCategorical28: \"{colorChartsTeal800}\",\n colorChartsPaletteCategorical29: \"{colorChartsPurple1000}\",\n colorChartsPaletteCategorical30: \"{colorChartsOrange800}\",\n colorChartsPaletteCategorical31: \"{colorChartsBlue21100}\",\n colorChartsPaletteCategorical32: \"{colorChartsPink300}\",\n colorChartsPaletteCategorical33: \"{colorChartsTeal1100}\",\n colorChartsPaletteCategorical34: \"{colorChartsPurple300}\",\n colorChartsPaletteCategorical35: \"{colorChartsOrange1100}\",\n colorChartsPaletteCategorical36: \"{colorChartsBlue2400}\",\n colorChartsPaletteCategorical37: \"{colorChartsPink600}\",\n colorChartsPaletteCategorical38: \"{colorChartsTeal400}\",\n colorChartsPaletteCategorical39: \"{colorChartsPurple600}\",\n colorChartsPaletteCategorical40: \"{colorChartsOrange400}\",\n colorChartsPaletteCategorical41: \"{colorChartsBlue2700}\",\n colorChartsPaletteCategorical42: \"{colorChartsPink900}\",\n colorChartsPaletteCategorical43: \"{colorChartsTeal700}\",\n colorChartsPaletteCategorical44: \"{colorChartsPurple900}\",\n colorChartsPaletteCategorical45: \"{colorChartsOrange700}\",\n colorChartsPaletteCategorical46: \"{colorChartsBlue21000}\",\n colorChartsPaletteCategorical47: \"{colorChartsPink1200}\",\n colorChartsPaletteCategorical48: \"{colorChartsTeal1000}\",\n colorChartsPaletteCategorical49: \"{colorChartsPurple1200}\",\n colorChartsPaletteCategorical50: \"{colorChartsOrange1000}\",\n};\n\nexport const chartColorTokens = resolveColorTokens(rawChartColorTokens);\n"],"names":["rawChartColorTokens","antdColorTokens","chartColorTokens","resolveColorTokens"],"mappings":";;AAMO,MAAMA,IAAsB;AAAA,EACjC,mBAAmB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACvD,mBAAmB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACvD,mBAAmB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACvD,mBAAmB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACvD,mBAAmB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACvD,mBAAmB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACvD,mBAAmB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACvD,oBAAoB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACxD,oBAAoB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACxD,oBAAoB,EAAE,OAAO,WAAW,MAAM,UAAU;AAAA,EACxD,sBAAsB,EAAE,OAAO,WAA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AAgC;AAAA,EAChC,gCAAgC;AAAA,EAChC,gCAAgC;AAAA,EAChC,gCAAgC;AAAA,EAChC,gCAAgC;AAAA,EAChC,gCAAgC;AAAA,EAChC,gCAAgC;AAAA,EAChC,gCAAgC;AAAA,EAChC,gCAAgC;AAAA,EAChC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AAAA,EACjC,iCAAiC;AACnC,GAEaC,IAAmBC,EAAmBH,CAAmB;"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
const h = (i, e) => {
|
|
2
|
+
const n = {};
|
|
3
|
+
return Object.entries(i).forEach(([o, t]) => {
|
|
4
|
+
if (t && typeof t == "object" && "light" in t && "dark" in t) {
|
|
5
|
+
const r = t;
|
|
6
|
+
n[o] = r[e];
|
|
7
|
+
} else typeof t == "string" && (n[o] = t);
|
|
8
|
+
}), n;
|
|
9
|
+
}, a = (i, e) => Array.isArray(i) ? i.map((n) => n[e]) : Object.values(h(i, e));
|
|
10
|
+
function l(i) {
|
|
11
|
+
const e = {}, n = i, o = (t) => {
|
|
12
|
+
if (e[t]) return e[t];
|
|
13
|
+
const r = n[t];
|
|
14
|
+
if (!r) return { light: "", dark: "" };
|
|
15
|
+
if (typeof r == "string") {
|
|
16
|
+
const s = r.match(/^\{(.+)\}$/);
|
|
17
|
+
if (!s) throw new Error(`Invalid reference token: ${String(t)}`);
|
|
18
|
+
const c = o(s[1]);
|
|
19
|
+
return e[t] = c, c;
|
|
20
|
+
}
|
|
21
|
+
const f = typeof r.light == "string" && /^\{.+\}$/.test(r.light) ? o(r.light.slice(1, -1)).light : r.light, g = typeof r.dark == "string" && /^\{.+\}$/.test(r.dark) ? o(r.dark.slice(1, -1)).dark : r.dark;
|
|
22
|
+
return e[t] = { light: f, dark: g }, e[t];
|
|
23
|
+
};
|
|
24
|
+
return Object.keys(n).forEach((t) => {
|
|
25
|
+
o(t);
|
|
26
|
+
}), Object.fromEntries(
|
|
27
|
+
Object.entries(e).filter(
|
|
28
|
+
([t, r]) => r && r.light && r.dark
|
|
29
|
+
)
|
|
30
|
+
);
|
|
31
|
+
}
|
|
32
|
+
export {
|
|
33
|
+
a as getColorsByTheme,
|
|
34
|
+
h as getTokensByTheme,
|
|
35
|
+
l as resolveColorTokens
|
|
36
|
+
};
|
|
37
|
+
//# sourceMappingURL=utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.js","sources":["../../src/tokens/utils.ts"],"sourcesContent":["export type ColorTokenValue = {\n light: string;\n dark: string;\n};\n\ntype RawColorTokenValue = string | ColorTokenValue;\n\nexport type ColorTokens = {\n [key: string]: RawColorTokenValue;\n};\n\n// Helper function to extract theme tokens for a specific mode\nexport const getTokensByTheme = <T extends ColorTokens>(\n originTokens: T,\n theme: \"light\" | \"dark\"\n) => {\n const tokens: Partial<Record<keyof T, string>> = {};\n\n Object.entries(originTokens).forEach(([key, value]) => {\n if (\n value &&\n typeof value === \"object\" &&\n \"light\" in value &&\n \"dark\" in value\n ) {\n // Handle ThemeTokenValue\n const tokenValue = value as ColorTokenValue;\n tokens[key as keyof T] = tokenValue[theme];\n } else if (typeof value === \"string\") {\n // Handle direct string values\n tokens[key as keyof T] = value;\n }\n });\n\n return tokens;\n};\n\nexport const getColorsByTheme = <T extends ColorTokens>(\n colorsOrTokens: T | ColorTokenValue[],\n theme: \"light\" | \"dark\"\n) => {\n if (Array.isArray(colorsOrTokens)) {\n return colorsOrTokens.map((color) => color[theme]);\n }\n return Object.values(getTokensByTheme(colorsOrTokens, theme));\n};\n\n/**\n * Resolves chart color tokens by replacing reference strings with actual values.\n * @returns Record of token names to resolved light/dark color objects\n */\nexport function resolveColorTokens<T extends ColorTokens>(\n colors: T\n): Record<keyof T, ColorTokenValue> {\n const resolved: Partial<Record<keyof T, ColorTokenValue>> = {};\n const raw = colors;\n\n const resolve = (key: keyof T): ColorTokenValue => {\n // Return from cache if already resolved\n if (resolved[key]) return resolved[key];\n\n const value = raw[key];\n if (!value) return { light: \"\", dark: \"\" };\n\n // Handle string references like \"{colorChartsBlue2300}\"\n if (typeof value === \"string\") {\n const match = value.match(/^\\{(.+)\\}$/);\n if (!match) throw new Error(`Invalid reference token: ${String(key)}`);\n const resolvedValue = resolve(match[1]); // Recursively resolve the referenced token\n resolved[key] = resolvedValue; // Store the resolved value for this key\n return resolvedValue;\n }\n\n // Handle object with light/dark properties that might contain references\n const light =\n typeof value.light === \"string\" && /^\\{.+\\}$/.test(value.light)\n ? resolve(value.light.slice(1, -1)).light // Resolve nested reference in light property\n : value.light;\n\n const dark =\n typeof value.dark === \"string\" && /^\\{.+\\}$/.test(value.dark)\n ? resolve(value.dark.slice(1, -1)).dark // Resolve nested reference in dark property\n : value.dark;\n\n // Cache the resolved value\n resolved[key] = { light, dark };\n return resolved[key];\n };\n\n // Process all keys to ensure references are resolved\n Object.keys(raw).forEach((key) => {\n resolve(key);\n });\n\n // Return all resolved entries with valid values\n return Object.fromEntries(\n Object.entries(resolved).filter(\n ([_, value]) => value && value.light && value.dark\n )\n ) as Record<keyof T, ColorTokenValue>;\n}\n"],"names":["getTokensByTheme","originTokens","theme","tokens","key","value","tokenValue","getColorsByTheme","colorsOrTokens","color","resolveColorTokens","colors","resolved","raw","resolve","match","resolvedValue","light","dark","_"],"mappings":"AAYa,MAAAA,IAAmB,CAC9BC,GACAC,MACG;AACH,QAAMC,IAA2C,CAAC;AAE3C,gBAAA,QAAQF,CAAY,EAAE,QAAQ,CAAC,CAACG,GAAKC,CAAK,MAAM;AACrD,QACEA,KACA,OAAOA,KAAU,YACjB,WAAWA,KACX,UAAUA,GACV;AAEA,YAAMC,IAAaD;AACZ,MAAAF,EAAAC,CAAc,IAAIE,EAAWJ,CAAK;AAAA,IAAA,MAC3C,CAAW,OAAOG,KAAU,aAE1BF,EAAOC,CAAc,IAAIC;AAAA,EAC3B,CACD,GAEMF;AACT,GAEaI,IAAmB,CAC9BC,GACAN,MAEI,MAAM,QAAQM,CAAc,IACvBA,EAAe,IAAI,CAACC,MAAUA,EAAMP,CAAK,CAAC,IAE5C,OAAO,OAAOF,EAAiBQ,GAAgBN,CAAK,CAAC;AAOvD,SAASQ,EACdC,GACkC;AAClC,QAAMC,IAAsD,CAAC,GACvDC,IAAMF,GAENG,IAAU,CAACV,MAAkC;AAEjD,QAAIQ,EAASR,CAAG,EAAG,QAAOQ,EAASR,CAAG;AAEhC,UAAAC,IAAQQ,EAAIT,CAAG;AACrB,QAAI,CAACC,EAAO,QAAO,EAAE,OAAO,IAAI,MAAM,GAAG;AAGrC,QAAA,OAAOA,KAAU,UAAU;AACvB,YAAAU,IAAQV,EAAM,MAAM,YAAY;AAClC,UAAA,CAACU,EAAa,OAAA,IAAI,MAAM,4BAA4B,OAAOX,CAAG,CAAC,EAAE;AACrE,YAAMY,IAAgBF,EAAQC,EAAM,CAAC,CAAC;AACtC,aAAAH,EAASR,CAAG,IAAIY,GACTA;AAAA,IAAA;AAIT,UAAMC,IACJ,OAAOZ,EAAM,SAAU,YAAY,WAAW,KAAKA,EAAM,KAAK,IAC1DS,EAAQT,EAAM,MAAM,MAAM,GAAG,EAAE,CAAC,EAAE,QAClCA,EAAM,OAENa,IACJ,OAAOb,EAAM,QAAS,YAAY,WAAW,KAAKA,EAAM,IAAI,IACxDS,EAAQT,EAAM,KAAK,MAAM,GAAG,EAAE,CAAC,EAAE,OACjCA,EAAM;AAGZ,WAAAO,EAASR,CAAG,IAAI,EAAE,OAAAa,GAAO,MAAAC,EAAK,GACvBN,EAASR,CAAG;AAAA,EACrB;AAGA,gBAAO,KAAKS,CAAG,EAAE,QAAQ,CAACT,MAAQ;AAChC,IAAAU,EAAQV,CAAG;AAAA,EAAA,CACZ,GAGM,OAAO;AAAA,IACZ,OAAO,QAAQQ,CAAQ,EAAE;AAAA,MACvB,CAAC,CAACO,GAAGd,CAAK,MAAMA,KAASA,EAAM,SAASA,EAAM;AAAA,IAAA;AAAA,EAElD;AACF;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bioturing/components",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -8,105 +8,8 @@
|
|
|
8
8
|
"exports": {
|
|
9
9
|
".": {
|
|
10
10
|
"import": "./dist/index.js",
|
|
11
|
-
"types": "./dist/
|
|
11
|
+
"types": "./dist/index.d.ts"
|
|
12
12
|
},
|
|
13
|
-
"./Badge": {
|
|
14
|
-
"import": "./dist/Badge.js",
|
|
15
|
-
"types": "./dist/components/src/components/Badge/index.d.ts"
|
|
16
|
-
},
|
|
17
|
-
"./Breadcrumb": {
|
|
18
|
-
"import": "./dist/Breadcrumb.js",
|
|
19
|
-
"types": "./dist/components/src/components/Breadcrumb/index.d.ts"
|
|
20
|
-
},
|
|
21
|
-
"./Button": {
|
|
22
|
-
"import": "./dist/Button.js",
|
|
23
|
-
"types": "./dist/components/src/components/Button/index.d.ts"
|
|
24
|
-
},
|
|
25
|
-
"./Checkbox": {
|
|
26
|
-
"import": "./dist/Checkbox.js",
|
|
27
|
-
"types": "./dist/components/src/components/Checkbox/index.d.ts"
|
|
28
|
-
},
|
|
29
|
-
"./CodeBlock": {
|
|
30
|
-
"import": "./dist/CodeBlock.js",
|
|
31
|
-
"types": "./dist/components/src/components/CodeBlock/index.d.ts"
|
|
32
|
-
},
|
|
33
|
-
"./Collapse": {
|
|
34
|
-
"import": "./dist/Collapse.js",
|
|
35
|
-
"types": "./dist/components/src/components/Collapse/index.d.ts"
|
|
36
|
-
},
|
|
37
|
-
"./DropdownMenu": {
|
|
38
|
-
"import": "./dist/DropdownMenu.js",
|
|
39
|
-
"types": "./dist/components/src/components/DropdownMenu/index.d.ts"
|
|
40
|
-
},
|
|
41
|
-
"./Empty": {
|
|
42
|
-
"import": "./dist/Empty.js",
|
|
43
|
-
"types": "./dist/components/src/components/Empty/index.d.ts"
|
|
44
|
-
},
|
|
45
|
-
"./Field": {
|
|
46
|
-
"import": "./dist/Field.js",
|
|
47
|
-
"types": "./dist/components/src/components/Field/index.d.ts"
|
|
48
|
-
},
|
|
49
|
-
"./Form": {
|
|
50
|
-
"import": "./dist/Form.js",
|
|
51
|
-
"types": "./dist/components/src/components/Form/index.d.ts"
|
|
52
|
-
},
|
|
53
|
-
"./Input": {
|
|
54
|
-
"import": "./dist/Input.js",
|
|
55
|
-
"types": "./dist/components/src/components/Input/index.d.ts"
|
|
56
|
-
},
|
|
57
|
-
"./Popover": {
|
|
58
|
-
"import": "./dist/Popover.js",
|
|
59
|
-
"types": "./dist/components/src/components/Popover/index.d.ts"
|
|
60
|
-
},
|
|
61
|
-
"./Radio": {
|
|
62
|
-
"import": "./dist/Radio.js",
|
|
63
|
-
"types": "./dist/components/src/components/Radio/index.d.ts"
|
|
64
|
-
},
|
|
65
|
-
"./ScrollArea": {
|
|
66
|
-
"import": "./dist/ScrollArea.js",
|
|
67
|
-
"types": "./dist/components/src/components/ScrollArea/index.d.ts"
|
|
68
|
-
},
|
|
69
|
-
"./Slider": {
|
|
70
|
-
"import": "./dist/Slider.js",
|
|
71
|
-
"types": "./dist/components/src/components/Slider/index.d.ts"
|
|
72
|
-
},
|
|
73
|
-
"./Spin": {
|
|
74
|
-
"import": "./dist/Spin.js",
|
|
75
|
-
"types": "./dist/components/src/components/Spin/index.d.ts"
|
|
76
|
-
},
|
|
77
|
-
"./Switch": {
|
|
78
|
-
"import": "./dist/Switch.js",
|
|
79
|
-
"types": "./dist/components/src/components/Switch/index.d.ts"
|
|
80
|
-
},
|
|
81
|
-
"./Tag": {
|
|
82
|
-
"import": "./dist/Tag.js",
|
|
83
|
-
"types": "./dist/components/src/components/Tag/index.d.ts"
|
|
84
|
-
},
|
|
85
|
-
"./Tooltip": {
|
|
86
|
-
"import": "./dist/Tooltip.js",
|
|
87
|
-
"types": "./dist/components/src/components/Tooltip/index.d.ts"
|
|
88
|
-
},
|
|
89
|
-
"./Upload": {
|
|
90
|
-
"import": "./dist/Upload.js",
|
|
91
|
-
"types": "./dist/components/src/components/Upload/index.d.ts"
|
|
92
|
-
},
|
|
93
|
-
"./VerticalCollapsiblePanel": {
|
|
94
|
-
"import": "./dist/VerticalCollapsiblePanel.js",
|
|
95
|
-
"types": "./dist/components/src/components/VerticalCollapsiblePanel/index.d.ts"
|
|
96
|
-
},
|
|
97
|
-
"./PopupPanel": {
|
|
98
|
-
"import": "./dist/PopupPanel.js",
|
|
99
|
-
"types": "./dist/components/src/components/PopupPanel/index.d.ts"
|
|
100
|
-
},
|
|
101
|
-
"./utils": {
|
|
102
|
-
"import": "./dist/utils.js",
|
|
103
|
-
"types": "./dist/components/src/components/utils/index.d.ts"
|
|
104
|
-
},
|
|
105
|
-
"./hooks": {
|
|
106
|
-
"import": "./dist/hooks.js",
|
|
107
|
-
"types": "./dist/components/src/components/hooks/index.d.ts"
|
|
108
|
-
},
|
|
109
|
-
"./style.css": "./dist/style.css",
|
|
110
13
|
"./tailwind.css": "./dist/tailwind.css"
|
|
111
14
|
},
|
|
112
15
|
"files": [
|
|
@@ -123,7 +26,7 @@
|
|
|
123
26
|
"rc-tree": "^5.13.1",
|
|
124
27
|
"react-use-resizable": "^0.2.0",
|
|
125
28
|
"tailwind-merge": "^3.2.0",
|
|
126
|
-
"@bioturing/assets": "0.15.
|
|
29
|
+
"@bioturing/assets": "0.15.1"
|
|
127
30
|
},
|
|
128
31
|
"peerDependencies": {
|
|
129
32
|
"antd": "^5.25.0",
|
|
@@ -131,12 +34,8 @@
|
|
|
131
34
|
"react-dom": "^18.0.0 || ^19.0.0"
|
|
132
35
|
},
|
|
133
36
|
"devDependencies": {
|
|
134
|
-
"@rslib/core": "^0.6.8",
|
|
135
|
-
"@rspack/core": "^1.3.9",
|
|
136
37
|
"@types/react": "^19.1.3",
|
|
137
|
-
"@types/react-dom": "^19.1.3"
|
|
138
|
-
"css-loader": "^7.1.2",
|
|
139
|
-
"style-loader": "^4.0.0"
|
|
38
|
+
"@types/react-dom": "^19.1.3"
|
|
140
39
|
},
|
|
141
40
|
"repository": {
|
|
142
41
|
"type": "git",
|
|
@@ -155,10 +54,13 @@
|
|
|
155
54
|
"ui",
|
|
156
55
|
"design-system"
|
|
157
56
|
],
|
|
158
|
-
"sideEffects":
|
|
57
|
+
"sideEffects": [
|
|
58
|
+
"**/*.css",
|
|
59
|
+
"**/*.scss"
|
|
60
|
+
],
|
|
159
61
|
"description": "BioTuring Design system React component library",
|
|
160
62
|
"scripts": {
|
|
161
|
-
"build": "
|
|
162
|
-
"dev": "
|
|
63
|
+
"build": "vite build",
|
|
64
|
+
"dev": "vite build --watch"
|
|
163
65
|
}
|
|
164
66
|
}
|
package/dist/Badge.css
DELETED
package/dist/Badge.js
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import * as __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__ from "react/jsx-runtime";
|
|
2
|
-
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_config_provider_6a57beb3__ from "antd/es/config-provider";
|
|
3
|
-
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_theme_useToken_e8911485__ from "antd/es/theme/useToken";
|
|
4
|
-
import * as __WEBPACK_EXTERNAL_MODULE_react__ from "react";
|
|
5
|
-
import "tailwind-merge";
|
|
6
|
-
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_badge_f5f828f9__ from "antd/es/badge";
|
|
7
|
-
function cx(...args) {
|
|
8
|
-
const classes = [];
|
|
9
|
-
for (const arg of args)if (arg) {
|
|
10
|
-
if ("string" == typeof arg || "number" == typeof arg) classes.push(String(arg));
|
|
11
|
-
else if (Array.isArray(arg)) classes.push(...cx(...arg));
|
|
12
|
-
else if ("object" == typeof arg) {
|
|
13
|
-
for (const [key, value] of Object.entries(arg))if (value) classes.push(key);
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
return classes;
|
|
17
|
-
}
|
|
18
|
-
function clsx(...args) {
|
|
19
|
-
return cx(...args).join(" ");
|
|
20
|
-
}
|
|
21
|
-
"use client";
|
|
22
|
-
const useAntdCssVarClassname = ()=>{
|
|
23
|
-
var _token_;
|
|
24
|
-
const token = (0, __WEBPACK_EXTERNAL_MODULE_antd_es_theme_useToken_e8911485__["default"])();
|
|
25
|
-
return null == (_token_ = token[4]) ? void 0 : _token_.key;
|
|
26
|
-
};
|
|
27
|
-
const useCls = ()=>{
|
|
28
|
-
const { getPrefixCls } = (0, __WEBPACK_EXTERNAL_MODULE_react__.useContext)(__WEBPACK_EXTERNAL_MODULE_antd_es_config_provider_6a57beb3__["default"].ConfigContext);
|
|
29
|
-
return (...args)=>cx(...args).map((cls)=>getPrefixCls(cls)).join(" ");
|
|
30
|
-
};
|
|
31
|
-
const Badge = ({ count, showZero, ...rest })=>{
|
|
32
|
-
const cls = useCls();
|
|
33
|
-
const antdCssVar = useAntdCssVarClassname();
|
|
34
|
-
return /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(__WEBPACK_EXTERNAL_MODULE_antd_es_badge_f5f828f9__["default"], {
|
|
35
|
-
count: count,
|
|
36
|
-
showZero: showZero,
|
|
37
|
-
className: clsx(cls("badge"), antdCssVar),
|
|
38
|
-
...rest
|
|
39
|
-
});
|
|
40
|
-
};
|
|
41
|
-
export { Badge };
|
package/dist/Breadcrumb.css
DELETED
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
@layer components {
|
|
2
|
-
.ds-breadcrumb {
|
|
3
|
-
display: flex;
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
.ds-breadcrumb ol {
|
|
7
|
-
flex: 1;
|
|
8
|
-
gap: .25rem 0;
|
|
9
|
-
min-width: 0;
|
|
10
|
-
display: inline-flex;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.ds-breadcrumb > ol > li {
|
|
14
|
-
flex: 0 1 0;
|
|
15
|
-
align-items: center;
|
|
16
|
-
max-width: 100%;
|
|
17
|
-
display: inline-flex;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.ds-breadcrumb > ol > li.ds-breadcrumb-separator {
|
|
21
|
-
flex: 0;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.ds-breadcrumb > ol > li .ds-breadcrumb-link {
|
|
25
|
-
white-space: nowrap;
|
|
26
|
-
flex: 0 auto;
|
|
27
|
-
align-items: center;
|
|
28
|
-
gap: .5rem;
|
|
29
|
-
min-width: 0;
|
|
30
|
-
display: inline-flex;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
.ds-breadcrumb .ds-breadcrumb-item-name {
|
|
34
|
-
flex: auto;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
.ds-breadcrumb .ds-breadcrumb-item-icon {
|
|
38
|
-
flex: none;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
.ds-breadcrumb.ds-breadcrumb-nowrap {
|
|
42
|
-
flex-grow: 1;
|
|
43
|
-
align-items: center;
|
|
44
|
-
min-width: 0;
|
|
45
|
-
display: flex;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
.ds-breadcrumb.ds-breadcrumb-nowrap ol {
|
|
49
|
-
flex-wrap: nowrap;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
:is(.ds-breadcrumb.ds-breadcrumb-nowrap ol) li:not(.ds-breadcrumb-separator) {
|
|
53
|
-
flex: 0 auto;
|
|
54
|
-
min-width: 0;
|
|
55
|
-
transition: all .2s;
|
|
56
|
-
display: flex;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
:is(:is(.ds-breadcrumb.ds-breadcrumb-nowrap ol) li:not(.ds-breadcrumb-separator)) span.ds-breadcrumb-link {
|
|
60
|
-
text-overflow: ellipsis;
|
|
61
|
-
white-space: nowrap;
|
|
62
|
-
max-width: 100%;
|
|
63
|
-
display: block;
|
|
64
|
-
overflow: hidden;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
:is(.ds-breadcrumb.ds-breadcrumb-nowrap ol) li:not(.ds-breadcrumb-separator) {
|
|
68
|
-
max-width: 100%;
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
:is(.ds-breadcrumb.ds-breadcrumb-nowrap ol) li:last-child {
|
|
72
|
-
flex: none;
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
:is(.ds-breadcrumb.ds-breadcrumb-nowrap ol):hover li:last-child {
|
|
76
|
-
flex-shrink: 1;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
:is(.ds-breadcrumb.ds-breadcrumb-nowrap ol) li:hover {
|
|
80
|
-
flex-shrink: 0;
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
|