Uh oh!
There was an error while loading. Please reload this page.
ui: brand-grounded terminal style system (truecolor + light/dark + fallback) - #367
Merged
Conversation
…llback)
Turns the CLI's ad-hoc colour into one system, built from the design-system
tokens and the tracebloc.io identity. Organising idea = the homepage gradient:
cyan orients (structure), lime moves (action).
Engine (internal/ui):
- colorMode {none,16,true} + termBg {dark,light}, detected in New: NO_COLOR /
non-TTY / TERM=dumb → none; COLORTERM=truecolor|24bit → 24-bit; else ANSI-16.
COLORFGBG picks the background; unknown → dark (the dev norm).
- A tone table maps each semantic role to its exact 24-bit hex on dark AND light
terminals (primary/secondary ramps) plus the nearest ANSI-16 fallback. hue()
is the single brand-colour chokepoint; bright shades on dark, deep shades
(primary.700 / secondary.700) on light so it stays legible on white.
- Meaning never rests on hue alone — headings/commands carry Bold, alerts carry
a distinct glyph — so output still reads under NO_COLOR / for colour-blindness.
Roles applied to the existing Printer methods (decisions A–D):
- Section / Banner / Step → cyan (structure)
- MenuRow command → lime bold; description → soft lime (a7ed6c) [A,B]
- ✔ / ✓ → brand lime ("green = go", unified with commands) [A]
- ✗ soft red, ⚠ amber, ✖ bold red, dim neutral labels
- home.go: inline "run <cmd>" now rendered in the command tone.
Truecolor exactness + light/dark shade + 16-fallback pinned by
brand_tones_test.go, so a token drift fails CI. Existing colour-matrix /
plain / NO_COLOR tests unchanged and green.
First of two surfaces; the bash installer mirrors this next.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>LukasWodka
commented
Jul 21, 2026
ContributorAuthor
@BugBot run |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 468fcb4. Configure here.
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Jul 21, 2026
Merged
LukasWodka added a commit
that referenced
this pull request
Jul 21, 2026
The e2e workflow's PR trigger was label-only (`e2e`), so PRs that break the suites' assertions merge unexercised: #363/#367/#368 reworded the `tracebloc delete` teardown copy the offboard e2e asserts on, no PR run ever executed the suite, and every develop push went red until #378 realigned the assertions post-merge. Add a ~5s dorny/paths-filter probe (`changes`, PR events only) and gate both e2e jobs on it alongside the existing label opt-in. PRs touching the union of the suites' dependency surface — the offboard flow (delete*.go, nodeboot, api, config), the rendering layer (ui — the #367 lesson), the kind-suite seams (cluster, push), the suites themselves, or the build inputs (Makefile, go.mod/sum, cmd) — now run the e2e pre-merge (~2 min, jobs in parallel). Unrelated PRs skip both jobs as before. Push / nightly / dispatch behavior is unchanged: the probe is skipped there, hence the !cancelled() guards — the implicit success() on a skipped need would otherwise skip those runs too. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
LukasWodka
commented
Jul 21, 2026
ContributorAuthor
/fr-pass — verified live: SGR tones render inside a PTY and |
saadqbal added a commit
that referenced
this pull request
Aug 21, 2026
… (backend#2314) The paths probe gates `Offboard teardown (k3d)` on the black-box run's dependency surface, and the telemetry transport was missing from it. That is the same gap the filter's own comment records for internal/ui after #367: the command-outcome event is emitted from main.go AFTER the offboard returns, and its spool lives inside the ~/.tracebloc the offboard just deleted, so a telemetry change re-created the wiped tree and broke the suite's config-dir assertion without touching delete.go. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
saadqbal added a commit
that referenced
this pull request
Aug 21, 2026
… ~/.tracebloc (backend#2314) (#548) * fix(delete): stop the exit-path telemetry write re-creating the wiped ~/.tracebloc (backend#2314) `tracebloc delete` printed "✔ Removed local tracebloc data and config." and then put the directory back before the process exited, so the offboard's central promise was not kept. main.go emits the command-outcome event AFTER the command tree returns, and the telemetry spool lives at <config.Dir()>/telemetry/pending-<env>.jsonl — inside the tree the offboard just removed. Two separate defects combined: * writeSpool called MkdirAll BEFORE its len(events) == 0 early return, so it created the directory even when it had nothing to write and was about to delete the spool file. This is why the tree came back on the DELIVERED path too, not just offline. * Nothing told the exit-path write that this invocation had deliberately removed local state, so on the undelivered path it wrote a real event file back into the wiped tree. That is the path the offboard always takes: the wipe takes the token with it, so deliver() finds no credential and spools. removeHostDataDir now returns the directory it removed and the offboard records it, so writeSpool drops any write that lands inside it. The recorded value is the PATH, not a boolean: a bare "telemetry is off" flag silences writes the offboard never touched, and is permanently sticky inside a test binary — three unrelated spool tests failed exactly that way while this was being written. Delivery over the network is untouched: an online offboard still reports its outcome. Only the on-disk fallback is suppressed, and a dropped telemetry record is the cheaper loss against silently undoing a wipe the user asked for. Regression coverage in telemetry_transport_test.go, verified load-bearing by reverting each half independently. This is the only failing assertion in the `Offboard teardown (k3d)` e2e, red on develop since c246912. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> * ci(e2e): the offboard suite depends on internal/cli/telemetry*.go too (backend#2314) The paths probe gates `Offboard teardown (k3d)` on the black-box run's dependency surface, and the telemetry transport was missing from it. That is the same gap the filter's own comment records for internal/ui after #367: the command-outcome event is emitted from main.go AFTER the offboard returns, and its spool lives inside the ~/.tracebloc the offboard just deleted, so a telemetry change re-created the wiped tree and broke the suite's config-dir assertion without touching delete.go. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Turns the CLI's ad-hoc colour into one brand-grounded style system, built from the
design-systemtokens and confirmed against tracebloc.io. Organising idea = the homepage gradient: cyan orients (structure), lime moves (action). This is surface 1 of 2 (the bash installer mirrors it next).Design spec + mock terminals (real colour): the style proposal artifact shared in the thread.
Engine (
internal/ui)colorMode {none,16,true}+termBg {dark,light}, detected inNew:NO_COLOR/ non-TTY /TERM=dumb→ none;COLORTERM=truecolor|24bit→ 24-bit; else ANSI-16.COLORFGBGpicks the background; unknown → dark (the dev norm).hue()is the single brand-colour chokepoint — bright shades on dark, deep shades (primary.700/secondary.700) on light so it stays legible on white.NO_COLOR/ for colour-blindness.Roles → the existing Printer methods (decisions A–D)
#01a5cc(structure)#91e947bold (A)#a7ed6c(B)run <cmd>(home)Light-terminal deep-shade swap (C) + truecolor-with-16-fallback (D) are both in the engine.
Test plan
brand_tones_test.gopins the exact SGR:#01a5cc/#91e947on dark,#01637a/#578c2bon light, ANSI-16 (36/32) fallback with no truecolor escape — a token drift fails CI.NO_COLOR/ spinner tests unchanged and green.go build ./...,go vet, gofmt -s, goimports -local, staticcheck (all,-ST1005), deadcode, file-budget all clean.🤖 Generated with Claude Code
Note
Low Risk
Terminal presentation only with NO_COLOR/TTY/plain fallbacks and CI-pinned tones; no changes to auth, cluster logic, or command behavior beyond how strings are colored.
Overview
Replaces ad-hoc
fatih/colorusage with a single brand tone pipeline ininternal/ui:colorMode(none / 16-color / 24-bit viaCOLORTERM),termBgfromCOLORFGBG(deep primary/secondary on light backgrounds), andhue()as the chokepoint for headings, commands, warnings, and labels across existingPrintermethods.Adds
Printer.Commandfor inline actionable text; the home screen’s “run … doctor” tails now pass one styled fragment (p.Command(inv+" "+doctorPath)) instead of separate unstyled pieces.New
brand_tones_test.golocks expected SGR (e.g.#01a5cc/#91e947on dark, deep shades on light, ANSI36/32without38;2). Spinner/UI tests followdetectMode(replacingautoColor) and honorTERM=dumbas plain output.Reviewed by Cursor Bugbot for commit 468fcb4. Bugbot is set up for automated code reviews on this repo. Configure here.