Skip to content

feat(cockpit): wire the dark design tokens into the example apps - #868

Merged
blove merged 1 commit into
mainfrom
blove/cockpit-tokens-dark-wiring
Aug 30, 2026
Merged

feat(cockpit): wire the dark design tokens into the example apps#868
blove merged 1 commit into
mainfrom
blove/cockpit-tokens-dark-wiring

Conversation

@blove

@blove blove commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

What

The wiring half of the last arc follow-up (#867 built the file): the 14 dark-designed cockpit example apps import tokens-dark.css, so their var(--ds-*) references finally resolve to real tokens.

bucket uses effect
fallback == dark token 216 zero change
no fallback — silently invalid until now 32 fixed — client-tools' weather/confirm cards rendered transparent with unset text; they now get their intended dark surfaces
drifted fallbacks (accentBorder .25→.2, white-alpha surfaceTinted→solid, radius-xl 18→20) 6 micro-shifts, tokens adopted
dark-tuned 0.3-alpha shadows 6 kept as literals — the --ds-shadow tokens are light-tuned and vanish on dark surfaces (commented at each site)

One token improvement riding along

fontMono becomes "JetBrains Mono", ui-monospace, monospace in typography.ts. Without it, wiring would have regressed these apps' mono text from SF Mono to Courier (none load JetBrains Mono). The website is unaffected — it loads JetBrains Mono via next/font so the first entry always wins; its 40 verbatim CSS literals keep the old stack with zero rendering difference.

Verified

All 14 apps build with the import resolving; the built element-rendering app renders its dark design pixel-for-pixel with tokens live (--ds-canvas rgb(17,17,17), SF Mono via the new chain); client-tools' bundle carries the tokens; 6 affected projects' unit tests green; design-tokens suite green (regenerated files under the byte-drift guard).

This closes the last follow-up from the docs-review arc.

🤖 Generated with Claude Code

…apps

The wiring half of the tokens follow-up. Each app's styles.css imports the
generated tokens-dark.css, so var(--ds-*) finally resolves:

- 216 uses whose fallbacks were byte-copies of darkOverrides: unchanged.
- 32 uses had NO fallback and were silently invalid - client-tools' weather
  and confirm cards rendered transparent with unset text on the dark canvas.
  They now get their intended dark surfaces and text.
- The drifted fallbacks (accentBorder .25 vs .2, three white-alpha
  surfaceTinted values, one 18px radius-xl) adopt the tokens: micro-shifts.

Two deliberate divergences, verified before choosing them:

- The six 0.3-alpha shadows stay as literals with a comment: the --ds-shadow
  tokens are light-tuned (0.06-0.10 alpha) and vanish on dark surfaces.
- fontMono gains ui-monospace before the generic keyword in typography.ts
  itself - consumers without JetBrains Mono (all 14 of these apps) get the
  platform mono instead of Courier. The website is unaffected: it loads
  JetBrains Mono via next/font, so the first entry always wins; its 40
  verbatim CSS literals keep the old two-entry stack with zero rendering
  difference.

Verified: all 14 apps build; the built element-rendering app renders its dark
design pixel-for-pixel with tokens live (--ds-canvas rgb(17,17,17), body dark,
SF Mono); client-tools' bundle carries the tokens; 6 affected projects' unit
tests green.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@blove
blove enabled auto-merge (squash) August 30, 2026 14:25
@vercel

vercel Bot commented Aug 30, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
threadplane Ready Ready Preview Aug 30, 2026 2:30pm

Request Review

@github-actions

github-actions Bot commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

Claude finished @blove's task in 0s —— View job


I'll analyze this and get back to you.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated approval: this PR received an intelligent (AI) code review. See the review comments on this PR.

@blove
blove merged commit 3bda04a into main Aug 30, 2026
59 of 60 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.

1 participant