feat(theme): add Solarized Light theme#2270
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces a new "Solarized Light" theme to the TUI, adding its corresponding palette colors, UI theme definition, and integration into the theme selection and adaptation logic. The review feedback highlights a regression where existing "Whale Light" theme constants (LIGHT_TEXT_*) were modified to use Solarized Light values. Reverting these constants is recommended to preserve the original theme. Consequently, dedicated helper functions (adapt_fg_for_solarized_light_palette and adapt_bg_for_solarized_light_palette) should be implemented for the Solarized Light palette mode instead of delegating to the default light palette adaptation helpers.
bba6d13 to
c4a2f40
Compare
|
Pushed one more maintainer follow-up in Local verification:
Thanks again @AiurArtanis - this keeps the feature narrow and makes the validation/picker tests future-proof for the release candidate pass. |
Hmbown
left a comment
There was a problem hiding this comment.
Approved for the v0.8.48 candidate queue. CI and Greptile are clean after the Solarized validation-test follow-up in e7b79c331; the theme surface, settings aliases, and picker wraparound tests now line up. Thanks @AiurArtanis for the Solarized Light contribution.
|
Independent review: Merged onto Palette accuracy: all 16 canonical Solarized values are correct — Wiring complete: WCAG (informational, not blocking): body text on v0.8.48 (#2256) compatibility: clean — #2256 does not touch palette.rs, theme_picker.rs, settings.rs, or deepseek_theme.rs. / sibling-PR conflict: textual conflict guaranteed with #2267 (Claude), #2276 (terminal-transparent), and #2129 (Matrix) — all four PRs append to the same |
|
Theme cluster coordination — this PR is one of 4 in flight that all add to
All 4 hard-conflict at the Cross-pinging the cluster: @AiurArtanis @HUQIANTAO @Hmbown @malsony — see same coordination note on each PR. |
Summary
#1605

配色=情绪价值
Testing
cargo fmt --all -- --checkcargo clippy --workspace --all-targets --all-featurescargo test --workspace --all-featuresChecklist
Greptile Summary
Adds a Solarized Light theme to the TUI — a well-known warm-ivory-background palette often praised for readability. The implementation follows the existing theme extension pattern: new palette constants, a
PaletteMode::SolarizedLightvariant,ThemeId::SolarizedLight, aTheme::solarized_light()token set, and fg/bg adaptation functions that mirror the existing light-palette adapters.SOLARIZED_*constants are self-contained and do not modify existingLIGHT_TEXT_*constants; the newsolarized_light_does_not_mutate_whale_light_texttest verifies this explicitly.GruvboxDarkwrap-around sentinel withSELECTABLE_THEMES.last().SURFACE_REASONING*toSOLARIZED_PANEL(same as tool panels), giving up the visual cue that distinguishes model-reasoning blocks from regular content areas in all other light/grayscale themes.Confidence Score: 5/5
Safe to merge — the change is purely additive, touching only palette constants, a new PaletteMode variant, and a new ThemeId; existing themes are unaffected.
All new Solarized constants are independent from existing LIGHT_TEXT_* constants (confirmed by test), all enum match arms are exhaustive, and the feature integrates cleanly with the existing theme extension pattern. The only notable gap is that reasoning surfaces are rendered with the same background as regular panels, which slightly reduces visual feedback during model-reasoning steps, but this does not break any functionality.
crates/tui/src/palette.rs — specifically the adapt_bg_for_solarized_light_palette reasoning-surface mapping and the SOLARIZED_COMPOSER duplicate.
Important Files Changed
Flowchart
%%{init: {'theme': 'neutral'}}%% flowchart TD A[User selects solarized-light] --> B[normalize_theme_name] B --> C[ThemeId::SolarizedLight] C --> D[SOLARIZED_LIGHT_UI_THEME] C --> F[Theme::solarized_light] H[render fg color] --> J[adapt_fg_for_solarized_light_palette] J --> K{color match} K -->|TEXT_BODY| L[SOLARIZED_TEXT_BODY] K -->|TEXT_MUTED| M[SOLARIZED_TEXT_MUTED] K -->|TEXT_HINT| N[SOLARIZED_TEXT_HINT] I[render bg color] --> U[adapt_bg_for_solarized_light_palette] U --> V{color match} V -->|DEEPSEEK_INK| W[SOLARIZED_SURFACE] V -->|SURFACE_PANEL| X[SOLARIZED_PANEL] V -->|SURFACE_REASONING| XReviews (5): Last reviewed commit: "test(theme): include solarized in valida..." | Re-trigger Greptile