Make admin light/dark mode follow real palettes end-to-end.

Light admin derives from the public light theme; dark keeps HK overrides. Remap inputs, cards, muted text, and kill the public wallpaper on admin so fonts and boxes stay readable in both modes.

Co-authored-by: Cursor <[email protected]>
This commit is contained in:
simoleo89
2026-07-15 21:37:25 +02:00
co-authored by Cursor
parent 94904f2ddb
commit 7b6c02c07d
7 changed files with 154 additions and 19 deletions
+6 -1
View File
@@ -74,8 +74,13 @@ export function themePaletteCss(
palette: ThemePalette,
adminOverrides?: Partial<AdminPalette>,
): string {
const mode: "light" | "dark" = selector.includes("dark") ? "dark" : "light";
const semantic = derivePublicForegrounds(palette);
const admin = deriveAdminPalette(palette, adminOverrides);
const admin = deriveAdminPalette(
palette,
mode === "dark" ? adminOverrides : undefined,
mode,
);
const declarations = Object.entries(CSS_VARIABLES).map(
([key, cssName]) => `--${cssName}:${palette[key as keyof ThemePalette]};`,
);