@lobehub/ui 5.15.8 → 5.15.9
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/es/CodeDiff/CodeDiff.mjs +43 -67
- package/es/CodeDiff/CodeDiff.mjs.map +1 -1
- package/es/CodeDiff/DiffPanel.mjs +118 -0
- package/es/CodeDiff/DiffPanel.mjs.map +1 -0
- package/es/CodeDiff/PatchDiff.mjs +39 -63
- package/es/CodeDiff/PatchDiff.mjs.map +1 -1
- package/es/CodeDiff/style.mjs +80 -29
- package/es/CodeDiff/style.mjs.map +1 -1
- package/es/CodeDiff/theme.mjs +45 -0
- package/es/CodeDiff/theme.mjs.map +1 -0
- package/es/CodeDiff/type.d.mts +20 -0
- package/es/EmojiPicker/AvatarUploader.mjs +1 -1
- package/es/Highlighter/Highlighter.mjs +1 -1
- package/es/Highlighter/theme/lobe-theme.d.mts +3 -0
- package/es/Highlighter/theme/lobe-theme.mjs +1 -0
- package/es/Highlighter/theme/lobe-theme.mjs.map +1 -1
- package/es/Mermaid/Mermaid.mjs +1 -1
- package/es/Tag/Tag.mjs +23 -10
- package/es/Tag/Tag.mjs.map +1 -1
- package/es/Tag/styles.mjs +44 -1
- package/es/Tag/styles.mjs.map +1 -1
- package/es/Tag/type.d.mts +2 -1
- package/es/color/colors/blue.d.mts +2 -2
- package/es/color/colors/blue.mjs +50 -50
- package/es/color/colors/blue.mjs.map +1 -1
- package/es/color/colors/index.d.mts +1 -1
- package/es/color/colors/index.mjs +2 -2
- package/es/color/colors/index.mjs.map +1 -1
- package/es/color/index.d.mts +2 -2
- package/es/color/index.mjs +2 -2
- package/es/hooks/useHighlight.mjs +1 -1
- package/es/hooks/useStreamHighlight.mjs +1 -1
- package/es/index.mjs +2 -2
- package/es/styles/customTheme.mjs +2 -2
- package/es/styles/customTheme.mjs.map +1 -1
- package/es/styles/theme/token/dark.mjs +2 -2
- package/es/styles/theme/token/dark.mjs.map +1 -1
- package/es/utils/safeReadableColor.mjs +1 -0
- package/es/utils/safeReadableColor.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import blueGeekblueMix from "./blue.mjs";
|
|
2
2
|
import cyan from "./cyan.mjs";
|
|
3
3
|
import geekblue from "./geekblue.mjs";
|
|
4
4
|
import gold from "./gold.mjs";
|
|
@@ -14,7 +14,7 @@ import volcano from "./volcano.mjs";
|
|
|
14
14
|
import yellow from "./yellow.mjs";
|
|
15
15
|
//#region src/color/colors/index.ts
|
|
16
16
|
const colorScales = {
|
|
17
|
-
blue,
|
|
17
|
+
blue: blueGeekblueMix,
|
|
18
18
|
cyan,
|
|
19
19
|
geekblue,
|
|
20
20
|
gold,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","names":[],"sources":["../../../src/color/colors/index.ts"],"sourcesContent":["import type { ColorScaleItem } from '../types';\nimport blue from './blue';\nimport cyan from './cyan';\nimport geekblue from './geekblue';\nimport gold from './gold';\nimport gray from './gray';\nimport green from './green';\nimport lime from './lime';\nimport magenta from './magenta';\nimport orange from './orange';\nimport primary from './primary';\nimport purple from './purple';\nimport red from './red';\nimport volcano from './volcano';\nimport yellow from './yellow';\n\nexport interface ColorScales {\n blue: ColorScaleItem;\n cyan: ColorScaleItem;\n geekblue: ColorScaleItem;\n gold: ColorScaleItem;\n gray: ColorScaleItem;\n green: ColorScaleItem;\n lime: ColorScaleItem;\n magenta: ColorScaleItem;\n orange: ColorScaleItem;\n primary: ColorScaleItem;\n purple: ColorScaleItem;\n red: ColorScaleItem;\n volcano: ColorScaleItem;\n yellow: ColorScaleItem;\n}\n\nexport const colorScales: ColorScales = {\n blue,\n cyan,\n geekblue,\n gold,\n gray,\n green,\n lime,\n magenta,\n orange,\n primary,\n purple,\n red,\n volcano,\n yellow,\n};\n\nexport { colorScales as colors };\n\nexport { default as blue } from './blue';\nexport { default as cyan } from './cyan';\nexport { default as geekblue } from './geekblue';\nexport { default as gold } from './gold';\nexport { default as gray } from './gray';\nexport { default as green } from './green';\nexport { default as lime } from './lime';\nexport { default as magenta } from './magenta';\nexport { default as orange } from './orange';\nexport { default as primary } from './primary';\nexport { default as purple } from './purple';\nexport { default as red } from './red';\nexport { default as volcano } from './volcano';\nexport { default as yellow } from './yellow';\n"],"mappings":";;;;;;;;;;;;;;;AAiCA,MAAa,cAA2B;CACtC;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACD"}
|
|
1
|
+
{"version":3,"file":"index.mjs","names":[],"sources":["../../../src/color/colors/index.ts"],"sourcesContent":["import type { ColorScaleItem } from '../types';\nimport blue from './blue';\nimport cyan from './cyan';\nimport geekblue from './geekblue';\nimport gold from './gold';\nimport gray from './gray';\nimport green from './green';\nimport lime from './lime';\nimport magenta from './magenta';\nimport orange from './orange';\nimport primary from './primary';\nimport purple from './purple';\nimport red from './red';\nimport volcano from './volcano';\nimport yellow from './yellow';\n\nexport interface ColorScales {\n blue: ColorScaleItem;\n cyan: ColorScaleItem;\n geekblue: ColorScaleItem;\n gold: ColorScaleItem;\n gray: ColorScaleItem;\n green: ColorScaleItem;\n lime: ColorScaleItem;\n magenta: ColorScaleItem;\n orange: ColorScaleItem;\n primary: ColorScaleItem;\n purple: ColorScaleItem;\n red: ColorScaleItem;\n volcano: ColorScaleItem;\n yellow: ColorScaleItem;\n}\n\nexport const colorScales: ColorScales = {\n blue,\n cyan,\n geekblue,\n gold,\n gray,\n green,\n lime,\n magenta,\n orange,\n primary,\n purple,\n red,\n volcano,\n yellow,\n};\n\nexport { colorScales as colors };\n\nexport { default as blue } from './blue';\nexport { default as cyan } from './cyan';\nexport { default as geekblue } from './geekblue';\nexport { default as gold } from './gold';\nexport { default as gray } from './gray';\nexport { default as green } from './green';\nexport { default as lime } from './lime';\nexport { default as magenta } from './magenta';\nexport { default as orange } from './orange';\nexport { default as primary } from './primary';\nexport { default as purple } from './purple';\nexport { default as red } from './red';\nexport { default as volcano } from './volcano';\nexport { default as yellow } from './yellow';\n"],"mappings":";;;;;;;;;;;;;;;AAiCA,MAAa,cAA2B;CACtC,MAAA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACD"}
|
package/es/color/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ColorScaleItem } from "./types.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { blueGeekblueMix } from "./colors/blue.mjs";
|
|
3
3
|
import { cyan } from "./colors/cyan.mjs";
|
|
4
4
|
import { geekblue } from "./colors/geekblue.mjs";
|
|
5
5
|
import { gold } from "./colors/gold.mjs";
|
|
@@ -22,4 +22,4 @@ import { sage } from "./neutrals/sage.mjs";
|
|
|
22
22
|
import { sand } from "./neutrals/sand.mjs";
|
|
23
23
|
import { slate } from "./neutrals/slate.mjs";
|
|
24
24
|
import { NeutralColorScales, neutralColorScales } from "./neutrals/index.mjs";
|
|
25
|
-
export { type ColorScaleItem, ColorScales, type ColorScalesProps, ColorScales$1 as CssVar, NeutralColorScales, blue, colorScales, colorScales as colors, cyan, geekblue, gold, gray, green, lime, magenta, mauve, neutralColorScales, neutralColorScales as neutrals, olive, orange, primary, purple, red, sage, sand, slate, volcano, yellow };
|
|
25
|
+
export { type ColorScaleItem, ColorScales, type ColorScalesProps, ColorScales$1 as CssVar, NeutralColorScales, blueGeekblueMix as blue, colorScales, colorScales as colors, cyan, geekblue, gold, gray, green, lime, magenta, mauve, neutralColorScales, neutralColorScales as neutrals, olive, orange, primary, purple, red, sage, sand, slate, volcano, yellow };
|
package/es/color/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import blueGeekblueMix from "./colors/blue.mjs";
|
|
2
2
|
import cyan from "./colors/cyan.mjs";
|
|
3
3
|
import geekblue from "./colors/geekblue.mjs";
|
|
4
4
|
import gold from "./colors/gold.mjs";
|
|
@@ -21,4 +21,4 @@ import slate from "./neutrals/slate.mjs";
|
|
|
21
21
|
import { neutralColorScales } from "./neutrals/index.mjs";
|
|
22
22
|
import ColorScales from "./ColorScales/index.mjs";
|
|
23
23
|
import ColorScales$1 from "./CssVar/index.mjs";
|
|
24
|
-
export { ColorScales, ColorScales$1 as CssVar, blue, colorScales, colorScales as colors, cyan, geekblue, gold, gray, green, lime, magenta, mauve, neutralColorScales, neutralColorScales as neutrals, olive, orange, primary, purple, red, sage, sand, slate, volcano, yellow };
|
|
24
|
+
export { ColorScales, ColorScales$1 as CssVar, blueGeekblueMix as blue, colorScales, colorScales as colors, cyan, geekblue, gold, gray, green, lime, magenta, mauve, neutralColorScales, neutralColorScales as neutrals, olive, orange, primary, purple, red, sage, sand, slate, volcano, yellow };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { getCodeLanguageByInput } from "../Highlighter/const.mjs";
|
|
3
2
|
import lobe_theme_default from "../Highlighter/theme/lobe-theme.mjs";
|
|
3
|
+
import { getCodeLanguageByInput } from "../Highlighter/const.mjs";
|
|
4
4
|
import { useEffect, useMemo, useState } from "react";
|
|
5
5
|
import { transformerNotationDiff, transformerNotationErrorLevel, transformerNotationFocus, transformerNotationHighlight, transformerNotationWordHighlight } from "@shikijs/transformers";
|
|
6
6
|
import { Md5 } from "ts-md5";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { getCodeLanguageByInput } from "../Highlighter/const.mjs";
|
|
3
2
|
import lobe_theme_default from "../Highlighter/theme/lobe-theme.mjs";
|
|
3
|
+
import { getCodeLanguageByInput } from "../Highlighter/const.mjs";
|
|
4
4
|
import { shikiModulePromise } from "./useHighlight.mjs";
|
|
5
5
|
import { useCallback, useEffect, useMemo, useRef, useState } from "react";
|
|
6
6
|
import { ShikiStreamTokenizer } from "shiki-stream";
|
package/es/index.mjs
CHANGED
|
@@ -46,10 +46,11 @@ import CheckboxGroup from "./Checkbox/CheckboxGroup.mjs";
|
|
|
46
46
|
import Checkbox from "./Checkbox/index.mjs";
|
|
47
47
|
import FileTypeIcon from "./FileTypeIcon/FileTypeIcon.mjs";
|
|
48
48
|
import MaterialFileTypeIcon from "./MaterialFileTypeIcon/MaterialFileTypeIcon.mjs";
|
|
49
|
+
import Tag from "./Tag/Tag.mjs";
|
|
50
|
+
import lobe_theme_default from "./Highlighter/theme/lobe-theme.mjs";
|
|
49
51
|
import CodeDiff from "./CodeDiff/CodeDiff.mjs";
|
|
50
52
|
import PatchDiff from "./CodeDiff/PatchDiff.mjs";
|
|
51
53
|
import { highlighterThemes } from "./Highlighter/const.mjs";
|
|
52
|
-
import lobe_theme_default from "./Highlighter/theme/lobe-theme.mjs";
|
|
53
54
|
import SyntaxHighlighter from "./Highlighter/SyntaxHighlighter/index.mjs";
|
|
54
55
|
import CodeEditor from "./CodeEditor/CodeEditor.mjs";
|
|
55
56
|
import Collapse from "./Collapse/Collapse.mjs";
|
|
@@ -85,7 +86,6 @@ import { PopoverProvider, usePopoverContext } from "./base-ui/Popover/context.mj
|
|
|
85
86
|
import Popover from "./base-ui/Popover/Popover.mjs";
|
|
86
87
|
import PopoverGroup from "./base-ui/Popover/PopoverGroup.mjs";
|
|
87
88
|
import Tabs from "./Tabs/Tabs.mjs";
|
|
88
|
-
import Tag from "./Tag/Tag.mjs";
|
|
89
89
|
import EmojiPicker from "./EmojiPicker/EmojiPicker.mjs";
|
|
90
90
|
import Empty from "./Empty/Empty.mjs";
|
|
91
91
|
import Footer from "./Footer/Footer.mjs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import blueGeekblueMix from "../color/colors/blue.mjs";
|
|
2
2
|
import cyan from "../color/colors/cyan.mjs";
|
|
3
3
|
import geekblue from "../color/colors/geekblue.mjs";
|
|
4
4
|
import gold from "../color/colors/gold.mjs";
|
|
@@ -17,7 +17,7 @@ import sand from "../color/neutrals/sand.mjs";
|
|
|
17
17
|
import slate from "../color/neutrals/slate.mjs";
|
|
18
18
|
//#region src/styles/customTheme.ts
|
|
19
19
|
const primaryColors = {
|
|
20
|
-
blue:
|
|
20
|
+
blue: blueGeekblueMix.dark[9],
|
|
21
21
|
cyan: cyan.dark[9],
|
|
22
22
|
geekblue: geekblue.dark[9],
|
|
23
23
|
gold: gold.dark[9],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"customTheme.mjs","names":[],"sources":["../../src/styles/customTheme.ts"],"sourcesContent":["import {\n blue,\n cyan,\n geekblue,\n gold,\n green,\n lime,\n magenta,\n orange,\n purple,\n red,\n volcano,\n yellow,\n} from '@/color/colors';\nimport { mauve, olive, sage, sand, slate } from '@/color/neutrals';\n\nexport const primaryColors = {\n blue: blue.dark[9],\n cyan: cyan.dark[9],\n geekblue: geekblue.dark[9],\n gold: gold.dark[9],\n green: green.dark[9],\n lime: lime.dark[9],\n magenta: magenta.dark[9],\n orange: orange.dark[9],\n purple: purple.dark[9],\n red: red.dark[9],\n volcano: volcano.dark[9],\n yellow: yellow.dark[9],\n};\n\nexport type PrimaryColorsObj = typeof primaryColors;\nexport type PrimaryColors = keyof PrimaryColorsObj;\nexport const primaryColorsSwatches = [\n primaryColors.red,\n primaryColors.orange,\n primaryColors.gold,\n primaryColors.yellow,\n primaryColors.lime,\n primaryColors.green,\n primaryColors.cyan,\n primaryColors.blue,\n primaryColors.geekblue,\n primaryColors.purple,\n primaryColors.magenta,\n primaryColors.volcano,\n];\nexport const neutralColors = {\n mauve: mauve.dark[9],\n olive: olive.dark[9],\n sage: sage.dark[9],\n sand: sand.dark[9],\n slate: slate.dark[9],\n};\nexport const neutralColorsSwatches = [\n neutralColors.mauve,\n neutralColors.slate,\n neutralColors.sage,\n neutralColors.olive,\n neutralColors.sand,\n];\n\nexport type NeutralColorsObj = typeof neutralColors;\nexport type NeutralColors = keyof NeutralColorsObj;\n\nexport const findCustomThemeName = (type: 'primary' | 'neutral', value: string) => {\n const res = type === 'primary' ? primaryColors : neutralColors;\n const result = Object.entries(res).find((item) => item[1] === value);\n return result?.[0];\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;AAgBA,MAAa,gBAAgB;CAC3B,
|
|
1
|
+
{"version":3,"file":"customTheme.mjs","names":["blue"],"sources":["../../src/styles/customTheme.ts"],"sourcesContent":["import {\n blue,\n cyan,\n geekblue,\n gold,\n green,\n lime,\n magenta,\n orange,\n purple,\n red,\n volcano,\n yellow,\n} from '@/color/colors';\nimport { mauve, olive, sage, sand, slate } from '@/color/neutrals';\n\nexport const primaryColors = {\n blue: blue.dark[9],\n cyan: cyan.dark[9],\n geekblue: geekblue.dark[9],\n gold: gold.dark[9],\n green: green.dark[9],\n lime: lime.dark[9],\n magenta: magenta.dark[9],\n orange: orange.dark[9],\n purple: purple.dark[9],\n red: red.dark[9],\n volcano: volcano.dark[9],\n yellow: yellow.dark[9],\n};\n\nexport type PrimaryColorsObj = typeof primaryColors;\nexport type PrimaryColors = keyof PrimaryColorsObj;\nexport const primaryColorsSwatches = [\n primaryColors.red,\n primaryColors.orange,\n primaryColors.gold,\n primaryColors.yellow,\n primaryColors.lime,\n primaryColors.green,\n primaryColors.cyan,\n primaryColors.blue,\n primaryColors.geekblue,\n primaryColors.purple,\n primaryColors.magenta,\n primaryColors.volcano,\n];\nexport const neutralColors = {\n mauve: mauve.dark[9],\n olive: olive.dark[9],\n sage: sage.dark[9],\n sand: sand.dark[9],\n slate: slate.dark[9],\n};\nexport const neutralColorsSwatches = [\n neutralColors.mauve,\n neutralColors.slate,\n neutralColors.sage,\n neutralColors.olive,\n neutralColors.sand,\n];\n\nexport type NeutralColorsObj = typeof neutralColors;\nexport type NeutralColors = keyof NeutralColorsObj;\n\nexport const findCustomThemeName = (type: 'primary' | 'neutral', value: string) => {\n const res = type === 'primary' ? primaryColors : neutralColors;\n const result = Object.entries(res).find((item) => item[1] === value);\n return result?.[0];\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;AAgBA,MAAa,gBAAgB;CAC3B,MAAMA,gBAAK,KAAK;CAChB,MAAM,KAAK,KAAK;CAChB,UAAU,SAAS,KAAK;CACxB,MAAM,KAAK,KAAK;CAChB,OAAO,MAAM,KAAK;CAClB,MAAM,KAAK,KAAK;CAChB,SAAS,QAAQ,KAAK;CACtB,QAAQ,OAAO,KAAK;CACpB,QAAQ,OAAO,KAAK;CACpB,KAAK,IAAI,KAAK;CACd,SAAS,QAAQ,KAAK;CACtB,QAAQ,OAAO,KAAK;CACrB;AAID,MAAa,wBAAwB;CACnC,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACf;AACD,MAAa,gBAAgB;CAC3B,OAAO,MAAM,KAAK;CAClB,OAAO,MAAM,KAAK;CAClB,MAAM,KAAK,KAAK;CAChB,MAAM,KAAK,KAAK;CAChB,OAAO,MAAM,KAAK;CACnB;AACD,MAAa,wBAAwB;CACnC,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACd,cAAc;CACf;AAKD,MAAa,uBAAuB,MAA6B,UAAkB;AAGjF,QADe,OAAO,QADV,SAAS,YAAY,gBAAgB,cACf,CAAC,MAAM,SAAS,KAAK,OAAO,MACjD,GAAG"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import blueGeekblueMix from "../../../color/colors/blue.mjs";
|
|
2
2
|
import gold from "../../../color/colors/gold.mjs";
|
|
3
3
|
import gray from "../../../color/colors/gray.mjs";
|
|
4
4
|
import lime from "../../../color/colors/lime.mjs";
|
|
@@ -32,7 +32,7 @@ const errorToken = generateColorPalette({
|
|
|
32
32
|
});
|
|
33
33
|
const infoToken = generateColorPalette({
|
|
34
34
|
appearance: "dark",
|
|
35
|
-
scale:
|
|
35
|
+
scale: blueGeekblueMix,
|
|
36
36
|
type: "Info"
|
|
37
37
|
});
|
|
38
38
|
const darkBaseToken = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dark.mjs","names":[],"sources":["../../../../src/styles/theme/token/dark.ts"],"sourcesContent":["import type { AliasToken } from 'antd/es/theme/interface';\n\nimport { blue, gold, gray, lime, primary, red } from '@/color/colors';\n\nimport { generateColorNeutralPalette, generateColorPalette } from '../generateColorPalette';\n\nconst primaryToken = generateColorPalette({\n appearance: 'dark',\n scale: primary,\n type: 'Primary',\n});\n\nconst neutralToken = generateColorNeutralPalette({\n appearance: 'dark',\n scale: gray,\n});\n\nconst successToken = generateColorPalette({\n appearance: 'dark',\n scale: lime,\n type: 'Success',\n});\n\nconst warningToken = generateColorPalette({\n appearance: 'dark',\n scale: gold,\n type: 'Warning',\n});\n\nconst errorToken = generateColorPalette({\n appearance: 'dark',\n scale: red,\n type: 'Error',\n});\n\nconst infoToken = generateColorPalette({\n appearance: 'dark',\n scale: blue,\n type: 'Info',\n});\n\nconst darkBaseToken: Partial<AliasToken> = {\n ...primaryToken,\n ...neutralToken,\n ...successToken,\n ...warningToken,\n ...errorToken,\n ...infoToken,\n\n boxShadow: '0 20px 20px -8px rgba(0, 0, 0, 0.24)',\n boxShadowSecondary: '0 8px 16px -4px rgba(0, 0, 0, 0.2)',\n boxShadowTertiary: '0 3px 1px -1px rgba(26, 26, 26, 0.06)',\n colorLink: infoToken.colorInfoText,\n colorLinkActive: infoToken.colorInfoTextActive,\n\n colorLinkHover: infoToken.colorInfoTextHover,\n colorTextLightSolid: neutralToken.colorBgLayout,\n};\n\nexport default darkBaseToken;\n"],"mappings":";;;;;;;;AAMA,MAAM,eAAe,qBAAqB;CACxC,YAAY;CACZ,OAAO;CACP,MAAM;CACP,CAAC;AAEF,MAAM,eAAe,4BAA4B;CAC/C,YAAY;CACZ,OAAO;CACR,CAAC;AAEF,MAAM,eAAe,qBAAqB;CACxC,YAAY;CACZ,OAAO;CACP,MAAM;CACP,CAAC;AAEF,MAAM,eAAe,qBAAqB;CACxC,YAAY;CACZ,OAAO;CACP,MAAM;CACP,CAAC;AAEF,MAAM,aAAa,qBAAqB;CACtC,YAAY;CACZ,OAAO;CACP,MAAM;CACP,CAAC;AAEF,MAAM,YAAY,qBAAqB;CACrC,YAAY;CACZ,
|
|
1
|
+
{"version":3,"file":"dark.mjs","names":["blue"],"sources":["../../../../src/styles/theme/token/dark.ts"],"sourcesContent":["import type { AliasToken } from 'antd/es/theme/interface';\n\nimport { blue, gold, gray, lime, primary, red } from '@/color/colors';\n\nimport { generateColorNeutralPalette, generateColorPalette } from '../generateColorPalette';\n\nconst primaryToken = generateColorPalette({\n appearance: 'dark',\n scale: primary,\n type: 'Primary',\n});\n\nconst neutralToken = generateColorNeutralPalette({\n appearance: 'dark',\n scale: gray,\n});\n\nconst successToken = generateColorPalette({\n appearance: 'dark',\n scale: lime,\n type: 'Success',\n});\n\nconst warningToken = generateColorPalette({\n appearance: 'dark',\n scale: gold,\n type: 'Warning',\n});\n\nconst errorToken = generateColorPalette({\n appearance: 'dark',\n scale: red,\n type: 'Error',\n});\n\nconst infoToken = generateColorPalette({\n appearance: 'dark',\n scale: blue,\n type: 'Info',\n});\n\nconst darkBaseToken: Partial<AliasToken> = {\n ...primaryToken,\n ...neutralToken,\n ...successToken,\n ...warningToken,\n ...errorToken,\n ...infoToken,\n\n boxShadow: '0 20px 20px -8px rgba(0, 0, 0, 0.24)',\n boxShadowSecondary: '0 8px 16px -4px rgba(0, 0, 0, 0.2)',\n boxShadowTertiary: '0 3px 1px -1px rgba(26, 26, 26, 0.06)',\n colorLink: infoToken.colorInfoText,\n colorLinkActive: infoToken.colorInfoTextActive,\n\n colorLinkHover: infoToken.colorInfoTextHover,\n colorTextLightSolid: neutralToken.colorBgLayout,\n};\n\nexport default darkBaseToken;\n"],"mappings":";;;;;;;;AAMA,MAAM,eAAe,qBAAqB;CACxC,YAAY;CACZ,OAAO;CACP,MAAM;CACP,CAAC;AAEF,MAAM,eAAe,4BAA4B;CAC/C,YAAY;CACZ,OAAO;CACR,CAAC;AAEF,MAAM,eAAe,qBAAqB;CACxC,YAAY;CACZ,OAAO;CACP,MAAM;CACP,CAAC;AAEF,MAAM,eAAe,qBAAqB;CACxC,YAAY;CACZ,OAAO;CACP,MAAM;CACP,CAAC;AAEF,MAAM,aAAa,qBAAqB;CACtC,YAAY;CACZ,OAAO;CACP,MAAM;CACP,CAAC;AAEF,MAAM,YAAY,qBAAqB;CACrC,YAAY;CACZ,OAAOA;CACP,MAAM;CACP,CAAC;AAEF,MAAM,gBAAqC;CACzC,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CAEH,WAAW;CACX,oBAAoB;CACpB,mBAAmB;CACnB,WAAW,UAAU;CACrB,iBAAiB,UAAU;CAE3B,gBAAgB,UAAU;CAC1B,qBAAqB,aAAa;CACnC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"safeReadableColor.mjs","names":[],"sources":["../../src/utils/safeReadableColor.ts"],"sourcesContent":["import { cssVar } from 'antd-style';\nimport { readableColor } from 'polished';\n\nexport const safeReadableColor = (bgColor: string, fallbackColor?: string): string => {\n try {\n return readableColor(bgColor);\n } catch {\n return fallbackColor || cssVar.colorText;\n }\n};\n"],"mappings":";;;AAGA,MAAa,qBAAqB,SAAiB,kBAAmC;AACpF,KAAI;AACF,SAAO,cAAc,QAAQ;SACvB;AACN,SAAO,iBAAiB,OAAO"}
|
|
1
|
+
{"version":3,"file":"safeReadableColor.mjs","names":[],"sources":["../../src/utils/safeReadableColor.ts"],"sourcesContent":["import { cssVar } from 'antd-style';\nimport { readableColor } from 'polished';\n\nexport const safeReadableColor = (bgColor: string, fallbackColor?: string): string => {\n try {\n return readableColor(bgColor);\n } catch {\n if (bgColor.startsWith('var(')) return `contrast-color(${bgColor})`;\n return fallbackColor || cssVar.colorText;\n }\n};\n"],"mappings":";;;AAGA,MAAa,qBAAqB,SAAiB,kBAAmC;AACpF,KAAI;AACF,SAAO,cAAc,QAAQ;SACvB;AACN,MAAI,QAAQ,WAAW,OAAO,CAAE,QAAO,kBAAkB,QAAQ;AACjE,SAAO,iBAAiB,OAAO"}
|