Skip to content

stewards: use bb theme tokens for the sidebar glyph and phrase (BB-99) - #129

Merged
trotterdylan merged 2 commits into
mainfrom
bb/bb-99-sidebar-glyph-phrase-theme-tokens-thr_zdi8mhm8y9
Oct 28, 2026
Merged

trotterdylan merged 2 commits into
mainfrom
bb/bb-99-sidebar-glyph-phrase-theme-tokens-thr_zdi8mhm8y9

Conversation

@trotterdylan

Copy link
Copy Markdown
Collaborator

Implements BB-99. The stewards sidebar glyph and phrase built their class lists as template literals with the transition classes glued onto the last class, so Tailwind never extracted dark:text-blue-400 or bg-amber-400; the raw dark: palette pairs also followed the OS theme rather than bb's. Replace them with bb's semantic theme tokens, which carry their own light and dark values, and put a space before every interpolation so each token is scannable.

Merging moves the bb-plugins pin, builds a new bb-server image and stages a restart of every developer's server (Restart now in Settings → Plugins → Team setup, or the 03:00–05:00 ET quiet window).

Classification

no-review: a narrow bug fix and colour tweak with no change in behaviour, and no owner-reviewed trigger (no cross-repo contract, identity/access, production infrastructure, store migration, secret, new dependency or bigDecisions entry).

What changes

  • phraseClass: running → text-timeline-accent, needs-you → text-attention, blocked stays text-destructive, quiet stays text-muted-foreground.
  • StewardGlyph: needs-you dot bg-attention, blocked ring border-destructive, running ring border-timeline-accent, quiet ring border-muted-foreground/50 (unchanged).
  • Replaced the remaining seven text-amber-600 dark:text-amber-500 uses (badge, two pause icons, project health icon, two "on hold" lines, not-actionable note) with text-attention.
  • Every class list now has a space before ${transition}; no class is glued to an interpolation. The border-amber-500/40 badge border is out of scope and unchanged.

Testing

  • npm run typecheck in plugins/stewards: pass.
  • npm test in plugins/stewards: pass (737 tests, 21 files), including the new paints the four glyphs and phrases with bb theme tokens case asserting the glyph and phrase classes for running, you, blocked and quiet.
  • bb plugin build . then grepped dist/app.css; each class has a rule:
    • text-attention → {color:var(--attention)}
    • text-destructive → {color:var(--destructive)}
    • text-timeline-accent → {color:var(--timeline-accent)}
    • text-muted-foreground → {color:var(--muted-foreground)}
    • bg-attention → {background-color:var(--attention)}
    • border-destructive → {border-color:var(--destructive)}
    • border-timeline-accent → {border-color:var(--timeline-accent)}
    • border-muted-foreground/50 → {border-color:var(--muted-foreground)} plus the color-mix 50% fallback
      No dark:text-blue-*/dark:text-amber-* rules remain.
  • Not tested: a rendered browser dark-mode toggle; the colours are semantic tokens whose dark values bb supplies at runtime.

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Independent review running in bb thread @thread:thr_8ejxyht8y4.

— from bb thread thr_zdi8mhm8y9

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Review round 1 (GLM 5.3, at c6780c3)

Owner review required: no — none of the owner-reviewed triggers apply. This is a narrow colour bug fix plus tweaks in a live plugin's UI (no cross-repo contract, no identity/access, no production infrastructure, no store migration, no secret, no new dependency — package.json and lockfiles are untouched, and the diff touches only plugins/stewards/app.tsx and plugins/stewards/sidebar-app.test.tsx, which match no bigDecisions path).

Suggestions

  • The StewardGlyph doc comment still spells the states as "a solid yellow dot … an empty red ring, a blue ring," and oneOffGlyph's as "yellow when unread, blue animated." The code now paints with attention/destructive/timeline-accent, and the phraseClass comment was updated in that spirit. Optional: align those two comments so a future reader does not go looking for text-amber-* again.

Checked

  • Ran: npm install + npm run typecheck + npm test in plugins/stewards — typecheck pass, 737 tests / 21 files pass. The stewards plugin is in the plugins workflow matrix, so this is not one of the suites CI skips; the run on this head was still in progress when I reviewed, so I ran it myself.
  • Ran bb plugin build . in plugins/stewards and grepped the built dist/app.css myself (criterion 1): every class has a rule — text-attention, text-destructive, text-timeline-accent, text-muted-foreground → color:var(--...); bg-attention → background-color:var(--attention); border-timeline-accent → border-color:var(--timeline-accent); border-destructive is present in a shared selector list with border-destructive/40 → border-color:var(--destructive); border-muted-foreground/50 → border-color:var(--muted-foreground) with the 50% color-mix fallback. No dark:text-blue-* or dark:text-amber-* rule remains in the built CSS.
  • Verified the tokens really are bb's theme tokens: the plugin build's Tailwind theme maps --color-attention: var(--attention) and --color-timeline-accent: var(--timeline-accent), and the runtime light/dark values are bb's, so dark mode (criterion 2) follows bb's theme rather than the OS. Not browser-rendered in this review; the token wiring is what the criteria can be checked against, and it is correct.
  • Criterion 3: grepped app.tsx — the only raw palette class left anywhere in the file is border-amber-500/40 on the badge, which the ticket explicitly keeps out of scope; no text-blue-*, text-amber-*, bg-amber-*, border-blue-* or border-red-* remains.
  • Criterion 4: the existing sidebar tests pass, and the new paints the four glyphs and phrases with bb theme tokens case asserts the glyph and phrase classes for all four states (you/blocked/running/quiet) and that no raw palette class appears on any of the four rows. It would fail if the change were reverted.
  • Note, not a blocker: the PR also replaces seven text-amber-600 dark:text-amber-500 uses outside the sidebar rows (badge text, two pause icons, project health icon, two "On hold" lines, the not-actionable note). This goes beyond the letter of the acceptance criteria but stays inside the ticket's file scope and its intent (drop raw OS-following dark: pairs for bb's tokens), is documented in the PR body, and each is a like-for-like semantic swap. I checked each of those lines in the built CSS as well; all resolve to var(--attention).

_— from bb thread thr_8ejxyht8y4

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Round 1: verdict approved, lane no-review, no blockers.

  • Suggestion (taken): the StewardGlyph and oneOffGlyph doc comments still spelled the colours as yellow/red/blue/grey. Renamed them to the theme tokens they now paint with (attention / destructive / timeline-accent / muted) in 221a836. Comment-only, no behaviour change.

— from bb thread thr_zdi8mhm8y9

@trotterdylan
trotterdylan merged commit 2a23d9a into main Oct 28, 2026
20 checks passed
@trotterdylan
trotterdylan deleted the bb/bb-99-sidebar-glyph-phrase-theme-tokens-thr_zdi8mhm8y9 branch October 28, 2026 13:41
@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Review round 2 (GLM 5.3, at 221a836)

Owner review required: no — none of the owner-reviewed triggers apply (comment-only fix on top of round 1's approved change; only plugins/stewards/app.tsx and its test differ from main, matching no bigDecisions path).

Resolved since round 1

  • Suggestion (stale colour wording in the StewardGlyph and oneOffGlyph doc comments): resolved by 221a836 — both comments now name the theme tokens (attention / destructive / timeline-accent / muted), matching the phraseClass comment.

Checked

  • git diff c6780c3..221a836: two doc comments in app.tsx, no code change — exactly what the round-2 note claimed.
  • Ran: typecheck and the full suite in plugins/stewards (737 tests / 21 files, pass), including sidebar-app.test.tsx (63 tests, pass).
  • Verdict carries over: the change since the approved head is comments only, so the round-1 approval stands on this head; criteria 1–4 remain met as verified in round 1.

_— from bb thread thr_8ejxyht8y4

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Merged: no-review lane, reviewer approved c6780c3, checks green; since then: renamed the StewardGlyph/oneOffGlyph doc-comment colours to the theme tokens (comment-only, no behaviour change). merge commit 2a23d9a.

Merging moves the bb-plugins pin, builds a new bb-server image and stages a restart of every developer's server (Restart now in Settings → Plugins → Team setup, or the 03:00–05:00 ET quiet window).

— from bb thread thr_zdi8mhm8y9

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