/** * tones.ts, the canonical UI tone-token table, hoisted from `goodvibes-tui` * src/renderer/ui-primitives.ts (UI_TONES + DIFF_TONES + SPINNER_FRAMES) and * src/renderer/theme.ts (resolveUiTones / UI_TONES_LIGHT). * * TONE_TOKENS mirrors the TUI's UI_TONES shape byte-for-byte (the TUI is the * reference, and its dark values are the accepted baseline, this keeps a * future TUI swap onto this module a no-op). resolveTones(mode) is the single * mode-resolved read path: 'dark' returns TONE_TOKENS itself (so a byte-identity * check against the constant is trivially true), 'light' returns the inverted * chrome/accent variant tuned for legibility on a light terminal background. * * This module is PURE data, no fs, no terminal I/O, no process globals. * Painting stays renderer-owned; this module owns only the token values and * the mode-resolution function. */ /** Background mode, dark is the safe default until a caller's own bg-probe lands. */ export type ThemeMode = 'dark' | 'light'; /** The dark-mode (reference) tone-token table. */ export declare const TONE_TOKENS: { readonly fg: { readonly primary: "#e2e8f0"; readonly secondary: "#cbd5e1"; readonly muted: "#94a3b8"; readonly dim: "#475569"; readonly inverse: "#0f172a"; /** Empty-state / placeholder foreground. */ readonly empty: "#334155"; }; readonly bg: { readonly base: "#11131a"; readonly surface: "#161a22"; readonly title: "#0f172a"; readonly section: "#18202b"; readonly summary: "#1b2430"; readonly selected: "#223049"; readonly input: "#1e293b"; readonly warning: "#2b2116"; readonly error: "#2a161b"; readonly success: "#14241b"; /** Fullscreen/shell footer background. */ readonly footer: "#111827"; }; readonly state: { readonly info: "#38bdf8"; readonly good: "#22c55e"; readonly warn: "#f59e0b"; readonly bad: "#ef4444"; readonly blocked: "#f97316"; readonly active: "#60a5fa"; /** Canonical reasoning/thinking purple. */ readonly reasoning: "#a855f7"; }; readonly accent: { readonly browser: "#7dd3fc"; readonly control: "#22d3ee"; readonly inspector: "#c4b5fd"; readonly workflow: "#fbbf24"; readonly conversation: "#93c5fd"; /** Neon brand accent, header/splash/thinking gradient only. */ readonly brand: "#00ffff"; readonly gradientStart: "#00ffff"; readonly gradientEnd: "#d000ff"; }; /** Canonical border stroke color for fullscreen/panel chrome. */ readonly border: "#64748b"; /** * Persistent-chrome foregrounds, header / footer / live-thinking rows that * paint onto the TRANSPARENT terminal background (bg:''), NOT onto the * opaque dark modal/panel surfaces that fg.* and state.* serve. In light * mode this chrome sits on a light terminal and must invert toward dark to * stay legible, which is why it carries its own role instead of reusing * fg.muted/fg.dim (tuned light-on-dark for the opaque boxes). Dark values * here are byte-identical to the tokens they mirror (fg.muted, fg.dim, * state.warn, state.bad), so dark-mode chrome is unchanged by this table * existing. */ readonly chrome: { /** Secondary chrome text (header conversation title). == fg.muted (dark). */ readonly label: "#94a3b8"; /** Faint chrome text (version, provider, header rule, clean git). == fg.dim (dark). */ readonly faint: "#475569"; /** Warn accent on terminal bg (dirty git, pending risk). == state.warn (dark). */ readonly warn: "#f59e0b"; /** Alert accent on terminal bg (DANGER banner, shell risk). == state.bad (dark). */ readonly bad: "#ef4444"; /** Success accent on terminal bg (tool-call checkmark status). == state.good (dark). */ readonly good: "#22c55e"; /** Remote-risk accent on terminal bg (risk:remote marker, plain status). */ readonly remote: "#a78bfa"; }; }; /** * Diff surface accent color shared across diff-rendering surfaces (conversation * diff view, file diff panel, git panel inline diff). */ export declare const DIFF_TONES: { readonly add: "#00ff88"; readonly del: "#ff4444"; readonly hunk: "#88aaff"; }; /** Single spinner-frame source. */ export declare const SPINNER_FRAMES: readonly ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"]; /** Recursively widen the `as const` literal leaves of TONE_TOKENS to `string` * so the light variant can assign different colour values without fighting * TypeScript's literal-type inference. */ type DeepWidenToString = T extends string ? string : { [K in keyof T]: DeepWidenToString; }; /** The mode-resolved shape returned by resolveTones, same keys as TONE_TOKENS, * widened from literal string types to `string` so light values can differ. */ export type ToneTokens = DeepWidenToString; /** * resolveTones, return the tone-token table for the given background mode. * 'dark' returns TONE_TOKENS itself (byte-identical, same object reference) so * a consumer that has not wired mode detection can call resolveTones('dark') * as the safe default with zero behavior change. */ export declare function resolveTones(mode: ThemeMode): Readonly; export {}; //# sourceMappingURL=tones.d.ts.map