Files
LexAI/src/lib/theme.ts
john kevin asprec 47d9152bda refactor: single source for writing styles + action labels; add theme module
- src/lib/actions.ts: canonical ACTIONS/ACTION_LABELS/WRITING_STYLES;
  context-menu styles derived (WRITING_STYLES minus Default). Replaces
  the three duplicated style arrays in popup, content, and background.
- src/lib/theme.ts: canonical palette. Existing hex literals in the
  entrypoints are swapped wholesale when light/dark theming lands, so
  the color plumbing is only rewritten once.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-14 21:35:54 +08:00

33 lines
995 B
TypeScript

// Canonical LexAI palette (Catppuccin Mocha-derived). This is the single
// source of truth for UI colors; a light variant can be added here later.
//
// NOTE: the entrypoints still contain literal hex values from before this
// module existed. New/edited styles should reference THEME; the wholesale
// swap of existing literals happens together with light/dark theming so the
// color plumbing is only rewritten once.
export const THEME = {
// Surfaces
base: '#1e1e2e',
mantle: '#181825',
surface: '#313244',
surfaceGradient: 'linear-gradient(135deg, #1e1e2e 0%, #181825 100%)',
// Text
text: '#cdd6f4',
subtext: '#a6adc8',
muted: '#6c7086',
// Accents
accent: '#89b4fa', // blue — primary actions, links
success: '#a6e3a1', // green — success toasts
danger: '#f38ba8', // red — errors
warning: '#f9e2af', // yellow
// Borders
border: 'rgba(205,214,244,0.12)',
borderStrong: 'rgba(205,214,244,0.15)',
} as const;
export type Theme = typeof THEME;