theme redux

This commit is contained in:
2026-02-05 01:07:22 -05:00
parent 6950deaa88
commit ea9ab4d3f9
25 changed files with 1339 additions and 131 deletions

26
src/types/theme-schema.ts Normal file
View File

@@ -0,0 +1,26 @@
import type { RGBA } from "@opentui/core"
export type HexColor = `#${string}`
export type RefName = string
export type Variant = {
dark: HexColor | RefName
light: HexColor | RefName
}
export type ColorValue = HexColor | RefName | Variant | RGBA | number
export type ThemeJson = {
$schema?: string
defs?: Record<string, HexColor | RefName>
theme: Record<string, ColorValue> & {
selectedListItemText?: ColorValue
backgroundMenu?: ColorValue
thinkingOpacity?: number
}
}
export type ThemeColors = Record<string, RGBA> & {
_hasSelectedListItemText: boolean
thinkingOpacity: number
}