Repository navigation
Conversation
|
No actionable comments were generated in the recent review.
|
There was a problem hiding this comment.
Actionable comments posted: 1

Review info
-
Run configuration-
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
2bd309fd-993d-4853-8b67-45953cd31ad0
Files selected for processing: 2-
docs/styleguide/color.mdsrc/renderer/src/assets/main.css
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.
-
| Diff hunks (added/removed line, word and gutter tints in chat diffs and Monaco's diff editor) use `--diff-added` / `--diff-removed` and their `-ground`, `-gutter` and `-emphasis` tints instead: the muted decoration hues wash out once tinted onto a row. | ||
|
|
There was a problem hiding this comment.
Document the chat-specific diff text tokens.
main.css derives --chat-diff-added and --chat-diff-removed for chat text, while Monaco uses the raw diff ground, gutter, and emphasis tokens. (raw.githubusercontent.com)
Update this sentence to name --chat-diff-added and --chat-diff-removed for chat text. Keep --diff-* and its variants for Monaco backgrounds and gutters. Otherwise, a future chat style can bypass the contrast-safe mix.
[Low impact] This PR appears safe to merge; no actionable issues were found. SummaryThis PR gives chat and Monaco diffs shared green and red colors while leaving Git status colors unchanged.
Reviews (1) · Last reviewed commit: "docs(styleguide): name the chat diff tex..." · Reviewed by Greptile |
…ws, links Adds 29 public app theme tokens (diff, git decorations, tab bar, split divider, current workspace row, host badge, chat bubble, text link), each falling back to today's built-in color or CSS chain so existing themes and built-ins render the same. Monaco's diff editor now paints from the diff tokens, with sharper default diff tints (from #34698) and a readable dark ignored-file color. The contrast gate learns one-sided drops, translucent surfaces checked over their base, and main.css chains for half-set pairs. Co-Authored-By: Claude <[email protected]>
…ws, links Adds 29 public app theme tokens (diff, git decorations, tab bar, split divider, current workspace row, host badge, chat bubble, text link), each falling back to today's built-in color or CSS chain so existing themes and built-ins render the same. Monaco's diff editor now paints from the diff tokens, with sharper default diff tints (from #34698) and a readable dark ignored-file color. The contrast gate learns one-sided drops, translucent surfaces checked over their base, and main.css chains for half-set pairs. Co-Authored-By: Claude <[email protected]>
…ws, links Adds 29 public app theme tokens (diff, git decorations, tab bar, split divider, current workspace row, host badge, chat bubble, text link), each falling back to today's built-in color or CSS chain so existing themes and built-ins render the same. Monaco's diff editor now paints from the diff tokens, with sharper default diff tints (from #34698) and a readable dark ignored-file color. The contrast gate learns one-sided drops, translucent surfaces checked over their base, and main.css chains for half-set pairs. Co-Authored-By: Claude <[email protected]>
…ws, links (#36578) * feat(themes): public tokens for diffs, git status, tabs, dividers, rows, links Adds 29 public app theme tokens (diff, git decorations, tab bar, split divider, current workspace row, host badge, chat bubble, text link), each falling back to today's built-in color or CSS chain so existing themes and built-ins render the same. Monaco's diff editor now paints from the diff tokens, with sharper default diff tints (from #34698) and a readable dark ignored-file color. The contrast gate learns one-sided drops, translucent surfaces checked over their base, and main.css chains for half-set pairs. Co-Authored-By: Claude <[email protected]> * fix(themes): check omitted diff tints, chat bubbles and dark host badges as painted The contrast gate now derives an omitted diff tint from the theme's hue (and drops the hue when its tint hides code), checks chat bubbles against chat's mixed foreground on the chat canvas, and models the dark host badge at 80% accent. The main.css fallback table moves to plugin-theme-css-fallbacks.ts. Co-Authored-By: Claude <[email protected]> * fix(themes): blame a diff hue only for tints it painted, and check chat diff rows A diff tint the theme set itself no longer drops the theme's hue when it fails, and chat diff rows (hue-mixed text on the line tint over the chat canvas) are now checked too. Co-Authored-By: Claude <[email protected]> * fix(themes): new theme tokens only expose colors; unthemed surfaces paint exactly as before Every new token now falls back to the exact value its surface used before: - Diff hues default to the git decoration colors at the previous per-side percentages, and chat diff text keeps its 70% mix. - Monaco's diff view, overview ruler and links keep Monaco's stock colors unless the theme painted a diff or link token. The colors go through the derived Monaco theme instead of a global CSS override. - --text-link has no :root default; each link rule keeps its old literal as the fallback, including the markdown-light/-dark preview split and the always-#58a6ff Monaco doc link. - Tab bar, tab text and indicator fall back per element (bg-card, text-foreground, ...) instead of through :root aliases. - Dark --git-decoration-ignored goes back to #6e6e6e (#35910 ships separately). The contrast gate skips checks that have no theme token to drop, so themes that set only older tokens pay no extra probes. * perf(themes): contrast check skips ring checks the theme didn't set and precomputes drop lists --------- Co-authored-by: Claude <[email protected]>
|
Thanks for this! The change already landed on main in daa11df, so I'm closing this PR. We appreciate the contribution. |
ELI5
Added and removed lines in diffs now use clear green and red instead of pale olive or lime, so changes are easier to spot.
What Changed
--diff-added/--diff-removedhue tokens (light and dark) inmain.css, with-ground,-gutterand-emphasistints derived from them. Chat diff cards already read--diff-*-ground/-gutter; they now come from these hues instead of--git-decoration-*.--vscode-diffEditor*line, text and gutter variables now come from the same tokens, following the existing--vscode-*override pattern.div.monaco-diff-editoroutranks Monaco's injected theme rule.--chat-diff-added/-removedtext now mixes 60% of the diff hue (was 70% of the git-decoration hue), keeping text-on-row contrast ≥ 5.1:1 in both schemes. At 70%, light-mode added text dropped to 4.08:1.--git-decoration-*is unchanged, so the file tree and source-control status colors are unaffected.docs/styleguide/color.mddocuments the new tokens.Why
The muted decoration hues wash out once tinted onto a row background. A separate diff hue keeps git status colors conventional while making diff hunks readable. The CSS-variable approach covers every Monaco diff editor without registering custom Monaco themes.
Known limitation: Monaco paints the overview-ruler change markers on a canvas from its theme service, so those keep Monaco's defaults.
Linked Issue
Fixes #34696
Visual Proof
Source-control diff, dark theme. (The after shot was taken with the QML highlighting PR also applied; this PR changes only the add/remove tints.)
Testing
pnpm check:changedpasses (24 checks).AI Disclosure
Implemented with Claude Opus 5.5 (Claude Code); reviewed and tested by me.
Review
Agent skill upstream boundary
Notes
Ensure no issues in: Security, Cross-platform support (Linux, Windows, Mac), Remote SSH, Mobile, general backwards compatibility, performance
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)🤖 Generated with Claude Code