with one click
daintree-theme-creator
// Guide for creating or modifying Daintree themes. Use when working on theme palettes, semantic tokens, component extensions, or built-in theme definitions.
// Guide for creating or modifying Daintree themes. Use when working on theme palettes, semantic tokens, component extensions, or built-in theme definitions.
| name | daintree-theme-creator |
| description | Guide for creating or modifying Daintree themes. Use when working on theme palettes, semantic tokens, component extensions, or built-in theme definitions. |
Before starting, read the architecture documentation for full context:
docs/themes/theme-system.md — Three-layer pipeline, core model, component override pattern, runtime application, import flowdocs/themes/theme-tokens.md — Complete token reference (142 tokens), authoring vs resolved contracts, derivation defaults, contrast rulesDaintree themes flow through three layers. Each layer has a specific role:
createSemanticTokens(). These become --theme-* CSS variables. ~140 tokens covering every app-wide visual concern.| Purpose | Path |
|---|---|
| Palette type definition | shared/theme/palette.ts |
| Semantic token compiler | shared/theme/semantic.ts |
| Token key contract | shared/theme/types.ts |
| Contrast validation | shared/theme/contrast.ts |
| Theme compilation | shared/theme/themes.ts |
| Built-in theme interface | shared/theme/builtInThemeSources.ts |
| Built-in theme index | shared/theme/builtInThemes/index.ts |
| DOM application | src/theme/applyAppTheme.ts |
| CSS aliases & root vars | src/index.css (lines 360-560) |
| Theme system doc | docs/themes/theme-system.md |
| Token reference doc | docs/themes/theme-tokens.md |
| Component | File | Variable prefix |
|---|---|---|
| Toolbar | src/styles/components/toolbar.css | --toolbar-* |
| Sidebar / Worktree | src/styles/components/sidebar.css | --sidebar-*, --worktree-* |
| Settings dialog | src/styles/components/settings.css | --settings-* |
| Project Pulse | src/styles/components/pulse.css | --pulse-* |
| Panel chrome | src/styles/components/panels.css | --chrome-*, --dialog-*, --floating-surface-* |
A ThemePalette has these sections:
type: "dark" or "light"surfaces (5 tiers, darkest to lightest for light themes, opposite for dark):
grid — Panel grid background, the structural basesidebar — Left sidebar, toolbar surfacecanvas — General content canvaspanel — Panel backgrounds, cards, dialogselevated — Tooltips, popovers, elevated cardstext: primary, secondary, muted, inverseborder: Single base border coloraccent: Primary accent color (optional accentSecondary)status: success, warning, danger, infoactivity: active, idle, working, waitingterminal: Full ANSI palette — background, foreground, muted, cursor, selection, 8 base colors, 8 bright variantssyntax: comment, punctuation, number, string, operator, keyword, function, link, quote, chipstrategy (optional):
shadowStyle: "none" | "crisp" | "soft" | "atmospheric"materialBlur: backdrop blur in px (0 = disabled)materialSaturation: backdrop saturation percentageradiusScale: global border-radius multipliernoiseOpacity: texture noise overlay opacitypanelStateEdge: colored edge indicator on panelsBuilt-in themes are authored as BuiltInThemeSource:
{
id: string; // kebab-case identifier
name: string; // Display name
type: "dark" | "light";
builtin: true;
palette: ThemePalette;
tokens?: Partial<AppColorSchemeTokens>; // Semantic token overrides
extensions?: Record<string, string>; // Component variable overrides
location?: string; // Geographic inspiration
heroImage?: string; // Theme preview image path
}
palette — Always required. Defines the visual identity.tokens — Use sparingly to override specific semantic values that createSemanticTokens() doesn't derive well from the palette alone (e.g., fine-tuning overlay opacities, shadow composites, accent-muted values).extensions — Use for component-specific styling. These become bare CSS custom properties on :root (e.g., "toolbar-project-bg": "..." → --toolbar-project-bg).Component CSS files define fallback chains:
.toolbar-project-pill {
--_bg: var(--toolbar-project-bg, var(--theme-wash-medium));
--_border: var(--toolbar-project-border, var(--theme-border-subtle));
}
The component checks for its own override first, then falls back to a semantic token. Themes that don't need custom component styling can omit extensions entirely — the fallbacks provide sensible defaults.
The grid background uses a similar pattern:
--color-grid-bg: var(--panel-grid-bg, var(--terminal-grid-bg, var(--theme-surface-grid)));
So a theme can override just the grid area without changing the structural surface hierarchy.
Themes must pass WCAG 2.1 contrast checks. Use getThemeContrastWarnings() from shared/theme/contrast.ts to validate:
Built-in themes are named after natural locations worldwide. Each theme evokes the colors, light, and atmosphere of its place:
createSemanticTokens() mentally or in a test to see what it derivestokensgetThemeContrastWarnings()shared/theme/builtInThemes/ and register in index.tsshared/theme/builtInThemes/tokens overrides only if the derived values aren't rightextensions for component-specific refinements$ARGUMENTS
[HINT] Download the complete skill directory including SKILL.md and all related files