Skip to content

Commit 9e4ef8f

Browse files
committed
fix: prevent converting empty primary and neutral config key values to string
1 parent 8aaf7f9 commit 9e4ef8f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/utils/theme.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -324,8 +324,8 @@ export function normalizeThemeConfig(theme: any): MergedThemeConfig {
324324
return {
325325
colorMode: String(theme.colorMode ?? "") as ColorMode,
326326
isColorModeAuto: !!toNumber(theme.isColorModeAuto),
327-
primary: String(theme.primary ?? ""),
328-
neutral: String(theme.neutral ?? ""),
327+
primary: theme.primary || null,
328+
neutral: theme.neutral || null,
329329
text: {
330330
xs: toNumber(theme.text?.xs),
331331
sm: toNumber(theme.text?.sm),

0 commit comments

Comments
 (0)