feat(themes): apply OpenCode color themes app-wide with a settings picker (#364)

- Vendor the 36 OpenCode theme palettes into the shared package, synced
  from the pinned OpenCode release tag via pnpm themes:sync.
- Add a colorTheme user preference across the settings schema, defaults,
  and the assistant internal API.
- Extend palettes with success, warning, info, and diff colors, and add a
  resolver that maps palettes to CSS tokens and applies them to the DOM.
- Apply the theme app-wide through a ThemeProvider context, adopting the
  tokens in message, repo, session, and settings components, agent
  colors, git status styles, and diff viewers.
- Add a theme picker to General settings and make model quick-select
  follow the active theme (fixes #355).
This commit is contained in:
Chris Scott authored and GitHub committed 2026-09-28 00:19:32 -04:00
1 parent 702e3c4e13
commit 5bd688de4b
116 files changed
+2702 -760

No files matched your search

@@ -84,7 +84,7 @@ export function VersionSelectDialog({ open, onOpenChange }: VersionSelectDialogP
)}
{error && (
<div className="text-center py-8 text-red-500">
<div className="text-center py-8 text-destructive">
Failed to fetch versions
</div>
)}
@@ -106,7 +106,7 @@ export function VersionSelectDialog({ open, onOpenChange }: VersionSelectDialogP
isSelected
? 'border-primary bg-primary/10'
: isCurrent
? 'border-green-500/50 bg-green-500/10 cursor-default'
? 'border-success/50 bg-success/10 cursor-default'
: 'border-border hover:border-primary/50 hover:bg-muted/50'
}`}
>
@@ -115,7 +115,7 @@ export function VersionSelectDialog({ open, onOpenChange }: VersionSelectDialogP
<div className="font-medium flex items-center gap-2">
v{release.version}
{isCurrent && (
<span className="text-xs px-1.5 py-0.5 rounded bg-green-500/20 text-green-600 dark:text-green-400">
<span className="text-xs px-1.5 py-0.5 rounded bg-success/20 text-success">
Current
</span>
)}