Skip to content

fix(platform): restore AA contrast for Home row times - #4171

Merged
yannickmonney merged 3 commits into
mainfrom
fix/platform-home-row-time-contrast
Oct 5, 2026
Merged

yannickmonney merged 3 commits into
mainfrom
fix/platform-home-row-time-contrast

Conversation

@yannickmonney

@yannickmonney yannickmonney commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

What changed

  • Replace the Home row age's text-muted-foreground/80 class with full-opacity text-muted-foreground.
  • Add a regression test that rejects opacity modifiers on the 11px age class.

Full-opacity --muted-foreground is the existing design-system remedy and preserves AA contrast on idle, hover, highlighted, light, and dark row surfaces without changing layout or copy.

Verification

  • bunx vitest run --config vitest.config.ts --project client app/features/home/components/home-rows.test.ts — 1 passed.
  • bunx vitest run --config vitest.config.ts src/globals.test.ts from packages/ui — 2 passed (light and dark token contrast).
  • bunx oxlint --type-aware services/platform/app/features/home/components/home-rows.tsx services/platform/app/features/home/components/home-rows.test.ts — passed.
  • bunx oxfmt --check ... and git diff --check — passed.
  • Platform TypeScript check was started but exceeded the local light-run budget without output; no browser/backend/E2E run was attempted per the task permit.

Finding → test map: /80 opacity regression → home-rows.test.ts; light/dark token AA floor → packages/ui/src/globals.test.ts.

Optional sweep: the 16 existing /50–/70 uses remain unchanged because they are different contexts (icons, transient/hidden text, disabled states, or larger/stronger text) and were not measured to fail this issue's row-age acceptance criterion.

Exact head: b95b3c35d0a5933e0bafe750b5617dae13b0a403

Closes #4060

@yannickmonney

Copy link
Copy Markdown
Contributor Author

TALE-728 / TALE-452 — author CI repair receipt for #4171

  • PR: fix(platform): restore AA contrast for Home row times #4171
  • Old head: b95b3c35d0a5933e0bafe750b5617dae13b0a403 (confirmed remotely before editing and again before publication).
  • New head: 4c1ae7455c56cdca914f193f6c6fefb27471a97d.
  • Commit: fix(platform): keep home row age styling module-local. Its sole parent is the old head. Made one ordinary fast-forward push to fix/platform-home-row-time-contrast, authorized actual CI-failure repair, owner C8, reason Knip.

Read job 111285640962 once: its sole unused export was HOME_ROW_AGE_CLASS, services/platform/app/features/home/components/home-rows.tsx:57:14. Removed only export from the locally used constant and adjusted the source-reading regression to require a module-local declaration. No runtime behavior or class-string change; only those two files changed.

Scoped verification (installed tools only)

  • Oxlint on both changed files with the platform config: pass.
  • Oxfmt check on both changed files: pass.
  • File-scoped TypeScript program using the existing platform config, roots/diagnostics limited to both changed files: pass, 0 diagnostics; Node heap capped at 1536 MiB, no whole-workspace tsc.
  • Vitest client project with /opt/node/bin/node and --maxWorkers 1: 4 files / 56 tests passed, covering home-rows, home-panel, home-inbox-list and home-inbox-list.wire. Focused home-rows also passed separately (1 test).
  • knip --workspace services/platform --workspace tools/cli --include exports --no-progress: pass. Platform-only scope initially reported unrelated oidcOrganizationClaims, whose consumer is the CLI's email-attestation test; including that consumer workspace cleared the scope artifact. No unrelated code changed.
  • Regression proof: the new declaration assertion rejects the old exported source and accepts the repair; runtime source is byte-identical after removing the one export.
  • Diff check and commitlint: pass. Normal pre-commit conflict/format/local-SAST hooks completed successfully.

CI snapshot — read once, not a green verdict

At 2026-10-05T00:38:52Z, PR head was 4c1ae7455c56cdca914f193f6c6fefb27471a97d: 25 checks visible — 16 in progress, 2 success, 7 skipped. CI is pending/unreconciled; not claiming CI green.

No install, browser/backend stack, force push, new PR, rerun/cancel or merge. TALE-452's pending human capture d34fc53e is untouched. Next owner: the fleet manager routes a distinct interdiff confirmation; this author repair is not independent acceptance.

@yannickmonney

Copy link
Copy Markdown
Contributor Author

Interdiff confirmation (TALE-730): ACCEPT not carried. There's no independent ACCEPT to carry, so no merge.

From agent #2 (3f9fdcee), merge-lane slice TALE-730, dispatched by the fleet manager (run 1daab15b). I haven't written or pushed any commit on this PR.

  • Step 1 fails: no independent ACCEPT at any head.
  • The Knip interdiff itself is clean. It runs from b95b3c35d0a5933e0bafe750b5617dae13b0a403 to 4c1ae7455c56cdca914f193f6c6fefb27471a97d: one commit, whose parent is the old head. This note is for the reviewer and isn't an acceptance.
    • home-rows.tsx only drops export from HOME_ROW_AGE_CLASS. The class string is unchanged.
    • home-rows.test.ts now requires a module-local declaration (/^const HOME_ROW_AGE_CLASS =\s+'([^']+)'/m). It still asserts toBeDefined(), so it can't pass vacuously.
    • The commit fix(platform): keep home row age styling module-local uses an allowed type and the allowed platform scope. Lint commits passed.
  • CI at the exact head, read once at 01:07Z: 55 check runs, all completed: 36 success, 18 skipped, 1 neutral (Trivy) and none failing. All 5 workflows succeeded at attempt 1. Knip, Type check, Lint, Format and UI 1/4 to 4/4 passed. The PR is CLEAN.
    • The skips are by design: Candidate gate/source ×10, 4 container tests, 2 fork-PR jobs, Playwright (${{ matrix.service }}), and Backend integration. For the last, Integration scope reports "touches nothing the backend integration suite runs".
    • Green CI isn't acceptance.
  • Next owner: the manager routes an independent source review of fix(platform): restore AA contrast for Home row times #4171 at 4c1ae745, by an agent other than the author C8. The merge waits for that ACCEPT.

I didn't merge, push, rerun or cancel anything.

@yannickmonney

Copy link
Copy Markdown
Contributor Author

TALE-739 — REQUEST_CHANGES on PR #4171

Exact reviewed head: 4c1ae7455c56cdca914f193f6c6fefb27471a97d.
Independent reviewer: Codex #11, agent 7a7d20b9-15bf-4d0c-99bf-33e6e841a76c, run 67200f0f-e0b0-46fe-8a8d-04f3dbdb7134; distinct from author C8 (579ebc6d). Full source review, not an interdiff-only review.

B1 — highlighted Home ages remain below AA with organization branding

The patch fixes neutral Home surfaces, but not every supported highlighted row. RowText keeps text-muted-foreground at home-rows.tsx:57 / home-rows.tsx:112, while the existing SlidingHighlight at packages/ui/src/components/layout/section-nav.tsx:94 paints ${accentColor}26 instead of bg-muted when branding is configured. BrandingProvider supplies deriveAccentPalette(...).text (services/platform/app/components/branding/branding-provider.tsx:192); the age's explicit muted foreground does not inherit that branded row text color.

I calculated WCAG contrast from the exact-head stylesheet's HSL tokens and the actual installed source deriveAccentPalette, compositing the highlight's alpha byte 0x26 / 255 over --background. No browser or backend was used.

Theme Configured brand Derived text / highlight Age contrast
light #000000 #000000 / #00000026 3.468:1 — FAIL
light #056CFF #0057d1 / #0057d126 3.879:1 — FAIL
light #FF00FF #a300a3 / #a300a326 3.721:1 — FAIL
dark same three picks derived theme-specific fills 6.876 / 6.959 / 7.193:1 — PASS

For example, a black brand yields a light highlighted backdrop with RGB (214.396, 214.396, 214.396) under the unchanged age ink (110.3895, 110.3895, 119.1105). This is the same Home age and same highlighted-row acceptance criterion, not the optional wider muted-opacity sweep. The PR's claim that full opacity ensures AA on highlighted surfaces is incomplete. The supplied palette guarantees the accent ink on its own tint, not the neutral muted age ink.

Repair required: retain the house full-opacity muted-foreground remedy, but ensure the actual Home highlighted surface also clears 4.5:1 for the age when branding is configured. Add a focused regression for neutral and branded Home highlight surfaces (at least black and the shipped blue), both themes, using the actual palette and highlight composition. Avoid changing unrelated shared surfaces without explicit scope analysis. The current class-string assertion alone passes despite these failing supported states.

What passes

  • The entire PR changes only home-rows.tsx and its new source-reading regression test. No copy, locale, API, interaction, layout or infrastructure change; no additional scope creep found.
  • The full-opacity --muted-foreground remedy is used correctly for neutral surfaces.
  • Neutral token ratios, idle / bg-muted/60 hover / bg-muted highlight: light 4.892 / 4.697 / 4.570:1; dark 8.109 / 7.070 / 6.199:1, all pass AA.
  • Knip repair keeps HOME_ROW_AGE_CLASS module-local. All four original regression assertions remain; the regex is now anchored to the local declaration. Direct source inspection confirms RowText actually uses it. A small assertion probe verifies the current class passes and /80 and exported-declaration mutants are rejected. Knip repair did not weaken the original regression, but the original regression lacks branded surface coverage.
  • Existing action-triggered desktop hiding of age remains unchanged; no new keyboard/ARIA behavior or locale issue.

Run versus unrun

Run locally, installed tools only:

  • /opt/node/bin/node ../../node_modules/vitest/vitest.mjs run --project client --maxWorkers 1 with home-rows.test.ts, home-panel.test.tsx, home-inbox-list.test.tsx, home-inbox-list.wire.test.tsx: 4 files, 56 tests passed. These cover the two Home importers. Home panel's existing jsdom axe audits ran and passed.
  • UI globals.test.ts, unit project, one worker: 1 file, 2 tests passed.
  • Token and branded-highlight WCAG calculations: neutral states pass; branded light highlights fail as above.
  • Oxlint --type-aware on both changed files: exit 0. Initial invocation could not resolve node for tsgolint; rerun with /opt/node/bin in PATH passed.
  • Oxfmt --check on both changed files and git diff --check origin/main...HEAD: pass.
  • Focused TypeScript program using the existing platform config, roots and file diagnostics limited to the two changed files, no emit/incremental cache, 1536 MiB heap cap: 0 diagnostics, exit 0. Initial custom harness had config-path/incremental-option errors; corrected absolute config parsing passed. No whole-workspace tsc.

Unrun / not claimed: browser rendering, browser axe color-contrast, visual analyzer, backend, full suite and standalone Knip. The repository's jsdom axe helper explicitly disables color-contrast (services/platform/tests/utils/a11y.ts:4), because jsdom cannot evaluate rendered contrast. Passing those axe audits is not proof of the color-contrast acceptance checkbox. Token math is the permitted source-level contrast evidence here.

CI and disposition

At the pre-verdict read around 01:43Z, the remote head still matched exactly; PR was open and CLEAN. All 55 exact-head check runs completed: 36 success, 18 skipped, 1 neutral, 0 failing. Green CI does not remove B1. REQUEST_CHANGES; not merged. No push, CI rerun/cancel, install, browser or backend action. No repository source edits. TALE-452's native pending human capture d34fc53e and all task statuses remain untouched.

Next owner: fleet manager routes B1 to author C8 for focused repair, then a distinct exact-new-head review. PR: #4171. Evidence is retained beside this report in TALE-739's delivery box.

@yannickmonney

Copy link
Copy Markdown
Contributor Author

TALE-749 publication receipt — one ordinary fast-forward

Published only the TALE-742 branded-highlight contrast repair: 4c1ae7455c56cdca914f193f6c6fefb27471a97d → 02bb9fd9503e38155d24fc671ca52c791684db83, tree 6d0f930d1b11d5482300d76c9529a5a946925955.

The saved local SHA bf6ffb05c63315b14d6bfc17349107c268e53530 and clean worktree matched the handoff. Per its explicit publication instruction, cherry-picked only that repair onto the existing PR branch; did NOT publish the merged-main ancestry (784-file broader diff). The two changed blobs exactly match the handoff, and the publication interdiff is byte-identical to its saved two-file patch (94 insertions / 1 deletion; stable patch ID af6bfe3f835d403e488666d2998cb7b991253cb4). Commitlint and clean-worktree/ancestry/remote guards passed immediately before the single push.

Reverified on the publication checkout: 120 scoped tests pass (Home rows/importers 74, colour utilities 44, tokens 2), type-aware oxlint and oxfmt pass, scoped TypeScript 4 roots / 3353 dependency files / 0 diagnostics, diff whitespace check pass. Initial importer collection hit an external-worktree font-path restriction; rerun passed with an output-only Vite fs.allow wrapper, without repository/config edits or installs.

One CI snapshot, at the new exact head: 0 checks reported yet. Not a green claim. Git push and direct remote readback confirm the new head; the immediate first PR metadata read still showed the old head due to GitHub propagation, while the single subsequent CI snapshot identified the new head.

No force push, new PR, rerun/cancel, merge, self-review or protected capture/status changes. Next: manager routes C11 distinct re-review limited to the contrast fix and regression, plus applicable hosted gates. Evidence retained in TALE-749 delivery box. Publication allowance consumed.

@yannickmonney

Copy link
Copy Markdown
Contributor Author

TALE-757 exact-head verdict — ACCEPT, merge held

Reviewed exact head 02bb9fd9503e38155d24fc671ca52c791684db83 against 4c1ae7455c56cdca914f193c6f6fefb27471a97d.

  • Interdiff is limited to home-rows.tsx and home-rows.test.ts; no hard-coded colours or unrelated changes.
  • HOME_ROW_AGE_CLASS now inherits the active row ink, covering idle, hover, neutral highlight, and branded highlight surfaces.
  • The regression computes WCAG contrast from shipped theme tokens and deriveAccentPalette output for branded colours in both themes. Overlaying it on 4c1ae745 fails the inherited-ink assertion and five light branded-highlight AA cases (3.47, 3.89, 3.73, 3.99, 3.55:1); the exact head passes.
  • Scoped tests with one worker and installed tools: Home/importers 74 passed; colour utility/token tests 44 passed; UI token tests 2 passed.
  • Hosted CI read once at this exact head: no failures, but Validate images and Smoke test remain pending (skips are expected). Therefore ACCEPT is recorded, but merge is held until every check is complete.

No push, rerun, cancel, browser, or install performed.

@yannickmonney
yannickmonney merged commit 1530843 into main Oct 5, 2026
@yannickmonney
yannickmonney deleted the fix/platform-home-row-time-contrast branch October 5, 2026 04:50
@yannickmonney

Copy link
Copy Markdown
Contributor Author

Merged as 15308438b055a3d8b74f2ea949f4c0d12cd92f73 (squash, 04:50:10Z) from exact head 02bb9fd9503e38155d24fc671ca52c791684db83, by agent #2's TALE-359 06:45 run f6f587d8.

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.

bug(platform): Home row times read 3.2:1 contrast, under the 4.5:1 AA floor

1 participant