Skip to content

Add tinted8 support#24

Merged
JamyGolden merged 1 commit intomainfrom
jamy/feature/tinted8
Feb 19, 2026
Merged

Add tinted8 support#24
JamyGolden merged 1 commit intomainfrom
jamy/feature/tinted8

Conversation

@JamyGolden
Copy link
Member

I've been working on this for a while and I was slowly creating the spec as I was creating the builder. https://github.com/tinted-theming/home/blob/main/specs/tinted8/builder.md. This PR doesn't fully match the spec, but I'm going to update the spec since I think this PR introduces good changes to the spec.

Added

  • Library: Initial Tinted8 support (tinted_builder::tinted8) with Scheme
    type and spec version constants (SUPPORTED_BUILDER_SPEC_VERSION,
    SUPPORTED_STYLING_SPEC_VERSION).
  • Library: Tinted8 template rendering with nested scheme, palette, ui,
    and syntax contexts; color objects expose hex, hex-r/g/b, hex-bgr,
    rgb, rgb16, and dec fields.
  • Library: Tinted8 palette expansion and derivation rules (normal/dim/bright
    variants; derive orange/brown; auto-generate gray when missing).
  • CLI: Build support for Tinted8 schemes, including semver validation of
    supports.tinted8-styling and supports.tinted8-builder in
    templates/config.yaml.
  • CLI: List generation for Base16/Base24 and Tinted8 via yaml template config
    options.list with schemes array provided to mustache.
  • Docs: Add specs/builder.md and specs/styling.md references; expand
    READMEs with Tinted8 usage and template variables.
  • Tests: Add Tinted8 unit tests in library and build-flow tests in CLI

Changed

  • BREAKING: Library: Color API updated — Color::new now takes (hex, Option<ColorName>, Option<ColorVariant>); Color struct gained
    name and variant fields. Pass None for backward-compatible behavior.
    Also enhances color handling to accept 3‑digit hex, adds hex-bgr, and
    provides 16‑bit rgb16 plus normalized dec channel serialization.
  • BREAKING: Using the CLI to sync with a custom --schemes-dir is not
    supported anymore. sync only syncs to the default
    $XDG_DATA_DIR/tinted-theming/tinted-builder-rust/schemes directory.
  • Library: Extend Template to render Tinted8 schemes; update Base16/Base24
    code paths for consistency.
  • CLI: Improve errors and messages around missing/invalid template config and
    tinted8 compatibility.

Fixed

  • CLI: Add explicit error codes and validations for Tinted8 flows:
    E300/E301/E302 (missing supports entries), E303 (missing mustache),
    E305 (missing/invalid config), E400 (no schemes), plus E110/E111 for
    unknown systems/invalid files.

Removed

  • BREAKING: Library: Remove list, listbase16, and listbase24 scheme
    systems and their SchemeSystem enum variants. SchemeSystem::from_str no
    longer accepts these values. Use the yaml config options.list flow for list
    generation instead.

- BREAKING: Update `Color` API
- BREAKING: Using CLI `sync` with a custom `--schemes-dir` is not
  supported anymore. `sync` only syncs to the default data-path
  schemes-dir
- BREAKING: Remove list, listbase16 and listbase24 scheme systems
  in place of using the yaml template config `options.list`
  property
@JamyGolden JamyGolden requested a review from a team as a code owner February 19, 2026 01:00
@JamyGolden JamyGolden merged commit b228f48 into main Feb 19, 2026
12 checks passed
@JamyGolden JamyGolden deleted the jamy/feature/tinted8 branch February 19, 2026 02:24
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.

1 participant