Files
orca/docs/reference/plugin-themes.md
T
OrcaWinandOrcaWin 06c3443ab5 fix(i18n): localize right sidebar, GitHub and PR page leftovers (#35416)
Replace sentence fragments, manual non-family plurals, item(s) copy and
hard-coded English in the right sidebar, GitHub item dialog, PR page,
GitLab item dialog and diff-comment surfaces with whole-sentence keys and
CLDR plural families, and add translations for all built-in locales.

Refs #32207

Co-authored-by: OrcaWin <293788423+OrcaWin@users.noreply.github.com>
2026-10-28 16:26:36 -07:00

1.8 KiB

Plugin themes

Plugins contribute three kinds of theme through orca-plugin.json contributes: themes (app colors), terminalThemes (an ANSI palette) and, separately, icon themes. Each entry is { "id", "label", "path" } pointing at a JSON file of at most 16 KiB.

App themes

{ "base": "dark", "tokens": { "--background": "#1b1430", "--foreground": "#e8e0ff" } }
  • base (light or dark) becomes the app's light/dark mode while the theme is selected.
  • --background and --foreground are required. Every other public token is optional; an omitted token is derived from the ones you set (cards and sidebars from --background, text from --foreground, sidebar accents from --accent, rings from --primary, and so on), so a two-token theme still colors the whole app.
  • The public tokens are PLUGIN_APP_THEME_TOKENS in src/shared/plugins/plugin-theme-artifact.ts. Other variables cannot be set.
  • Values must be colors: hex, a color function (rgb, hsl, oklch, …) or a color name. transparent, currentColor, CSS-wide keywords, lengths, calc(), var() and url() are refused.
  • Each text/surface pair (for example --background/--foreground, --primary/--primary-foreground) must be opaque with at least 4.5:1 contrast; a pair that fails is dropped and keeps Orca's built-in colors.
  • Trust and approval dialogs always use Orca's own colors, whatever theme is active.

Terminal themes

{
  "schemaVersion": 1,
  "mode": "dark",
  "terminal": { "background": "#1b1430", "foreground": "#e8e0ff", "red": "#ff6b8b" }
}

Colors are hex. A palette needs background, foreground and at least one ANSI color. When a user selects it, Orca saves a copy of the palette in settings so hosts, headless servers and relays answer terminal color queries without the plugin loaded.