Skip to content

feat(home): render warning values as legible chips on filled surfaces - #117

Merged
Inakitajes merged 1 commit into
mainfrom
feat/improve-color-palette-contrasts
Sep 15, 2026
Merged

Inakitajes merged 1 commit into
mainfrom
feat/improve-color-palette-contrasts

Conversation

@Inakitajes

Copy link
Copy Markdown
Owner

Why

Home's selected-row fold and the worktree detail's identity zone paint a solid accent fill behind every fact. Warning values — the managed writer's live/uncertain liveness, an unknown dirt or changes observation, and an unavailable PR — kept their yellow ink on that fill, where yellow-on-accent measures about 1.26:1 in the dark palette and 1.21:1 in the light palette. The warning was signalled at the cost of the text being effectively unreadable: an operator could see that something needed attention but could not read what it said.

What

Ship the attached OpenSpec change accent-fill-warning-chips.

  • A warning value on a filled surface (the selected row's fold and the detail's filled zone) now renders as a filled chip: the warning color becomes the background and a contrasting ink carries the text, preserving the warning signal and legibility.
  • A warning value on a plain surface (the detail's remaining facts) keeps its yellow ink, already legible against the terminal background. Warnings are now context-sensitive: ink on plain surfaces, fill on filled surfaces.
  • Adds a dedicated warning-chip color pair (warning / warningInk) to the dark, light, and neutral palettes, rather than reusing yellow, which is tuned as ink on a light canvas and too dark to serve as a fill there. The chip clears WCAG AA (≥ 4.5:1) against its ink in every palette and stays separable from the accent it rides.
  • filledLines now preserves a chunk's own background the way highlighted already does, via the shared withFill helper.
  • Reverses the prior deliberate contract that a warning "stays yellow on the accent fill".

Impact

  • src/tui-theme.ts — warning-chip fill/ink pair added to all three palettes.
  • src/home-tui.ts — warning values render as chips in the selected-row fold (inlineDetailLines) and the detail zone (detailLines); filledLines preserves existing backgrounds.
  • test/home-tui.test.ts — chip contract replaces the "stays yellow on the accent fill" expectation; covers filled-chip vs plain-yellow-ink contexts across palettes.
  • test/tui-theme.test.ts — WCAG contrast coverage for the warning-chip pair per palette.

How tested

  • bun run typecheck — clean.
  • bun test — 3268 pass / 0 fail.
  • Delta specs for home-launcher updated in the archived change and synced to main specs.

@Inakitajes
Inakitajes merged commit b5bc82c into main Sep 15, 2026
2 checks passed
@Inakitajes
Inakitajes deleted the feat/improve-color-palette-contrasts branch September 15, 2026 12:05
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