Parcourir la source

fix: handle `0` in ANSI theme color definitions (#5009)

Jason Cheatham il y a 2 mois
Parent
commit
f2fd0f8f00
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      packages/opencode/src/cli/cmd/tui/context/theme.tsx

+ 1 - 1
packages/opencode/src/cli/cmd/tui/context/theme.tsx

@@ -161,7 +161,7 @@ function resolveTheme(theme: ThemeJson, mode: "dark" | "light") {
 
       if (c.startsWith("#")) return RGBA.fromHex(c)
 
-      if (defs[c]) {
+      if (defs[c] != null) {
         return resolveColor(defs[c])
       } else if (theme.theme[c as keyof ThemeColors] !== undefined) {
         return resolveColor(theme.theme[c as keyof ThemeColors]!)