Skip to content

Skins: built-in and user skins, adjustments, skin editor and guide - #42

Merged
bobnautic merged 1 commit into
mainfrom
claude/awesome-turing-suykit
Nov 19, 2026
Merged

bobnautic merged 1 commit into
mainfrom
claude/awesome-turing-suykit

Conversation

@bobnautic

Copy link
Copy Markdown
Owner

What

Rust Commander gets skins. A skin controls the whole look: every color (surfaces, text, accent, selection, status, file icons, terminal, syntax highlighting), plus shadows, fonts, corner radii, row height and striped rows. A skin can have a light variant, a dark variant, or both.

Built-in skins

Ten built-in skins

  • Rust Commander: the default. Its look is unchanged.
  • Ember, Graphite, Retro Blue (DOS-era blue panels with a cyan cursor bar), High Contrast.
  • Skins based on popular palettes: Nord, Solarized, Catppuccin, Gruvbox, Dracula.

Every variant of every skin passes the contrast checks.

Customization

  • Preferences → Appearance has:
    • the theme setting (system, light or dark)
    • a gallery of skins with live thumbnails; clicking one previews it in the whole window
    • adjustments that apply on top of any skin: accent color, row height, list font size, corner radius, striped rows, interface and monospace fonts
    • import and export of skin files, and the skins folder
  • A skin editor:
    • tokens grouped by area, with color pickers
    • a live preview of panels, editor, terminal and controls; it can also preview in the whole window
    • contrast warnings and a JSON view
  • View → Skin menu.
  • The terminal (xterm) and the editor and diff view (CodeMirror) take their colors from the skin.

How it works

  • ui/src/lib/skins/
    • defines 117 tokens as CSS custom properties
    • supports inheritance through extends
    • derives tokens a skin leaves out: one accent color, or a palette of nine hues, gives consistent hover, selection, cursor, file icon, terminal and syntax colors
    • validates every value: only colors, box-shadows, fonts and numbers in range are accepted; url(), var() and raw CSS are rejected
  • Built-in skins are plain JSON files in ui/src/skins/, so they also serve as examples. skin.schema.json lets editors autocomplete skin files.
  • User skins are JSON files in <config dir>/skins/:
    • backend: crates/rc-api/src/skins.rs, with the RPC methods skins.list, skins.save, skins.delete and the skins.changed event
    • they reload when the window regains focus, so skin authors can work in any editor
  • Settings: a new appearance object (skin id and adjustments). Older settings.json files load with the default skin.
  • theme-init.js applies the cached look before the bundle loads, so there is no flash of the default colors.

Docs

  • Skins and appearance
  • Creating skins: a quick start, the format, inheritance and derivation, a step-by-step tutorial, recipes, tools, and how to contribute a built-in skin.
  • Skin tokens: a reference generated from the token list.
  • README, configuration, interface, architecture and testing pages updated; new screenshots.

Tests

  • cargo test -p rc-api:
    • skin storage tests: ids cannot leave the folder, hand-written files, invalid skins
    • an RPC contract test for skins and appearance
  • cargo fmt --check and cargo clippy -p rc-api --all-targets are clean.
  • npm --prefix ui test:
    • 26 unit tests, 7 of them new for skins. They cover color parsing, validation, derivation, inheritance and cycles, built-in skins being complete and readable, base.css staying in sync with the default skin, the schema and docs matching the tokens.
    • every smoke check passes, including a new step: skin menu, live preview and revert in Preferences, creating a skin in the editor, compact rows.
  • node ui/scripts/skins.mjs check: contrast is ok for all 18 variants.

Generated by Claude Code

A skin decides the whole look: every color (surfaces, text, accent, selection,
status, file icons, terminal, syntax highlighting), shadows, fonts, corner
radii, row height and striped rows, in a light and/or a dark variant.

- Skin engine (ui/src/lib/skins): 117 design tokens as CSS custom properties,
  inheritance via "extends", automatic derivation of tokens a skin leaves out
  (one accent or a nine-hue palette gives a consistent result), strict value
  validation (colors, box-shadows, fonts, numbers only), contrast checks.
- Ten built-in skins: Rust Commander (default, unchanged look), Ember,
  Graphite, Retro Blue, High Contrast, Nord, Solarized, Catppuccin, Gruvbox,
  Dracula. All pass the contrast checks in every variant.
- User skins are JSON files in <config dir>/skins/ (rc-api: skins.list,
  skins.save, skins.delete, event skins.changed); they reload when the window
  regains focus, so skins can be written in any editor.
- Preferences → Appearance: theme, skin gallery with live previews,
  adjustments on top of any skin (accent, row height, list font size, corner
  radius, striped rows, fonts), import/export, skins folder.
- Skin editor with grouped tokens, color pickers, live preview of panels,
  editor, terminal and controls, contrast warnings and a JSON view.
- View → Skin menu; terminal and editor (CodeMirror) follow the skin; the
  last look is cached so theme-init.js applies it before the bundle loads.
- Docs: Skins and appearance, Creating skins (tutorial, recipes, tools),
  generated token reference, JSON schema, screenshots.
- Tests: Rust unit/dispatch tests, UI unit tests (colors, validation,
  derivation, inheritance, built-in skins, base.css/schema/docs in sync),
  smoke test step; scripts/skins.mjs (check, format, schema, docs).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017w9FQiSrVuuoxVYUhih6uc
@bobnautic
bobnautic merged commit 6ab8bf3 into main Nov 19, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants