Files
heidi/scripts
CatoandClaude Opus 5.5 7f274cd0ec fix(ui): red goes back to meaning one thing (#113)
Reported: "ui/ux could be better. why so much aggressive red".

The design had already answered this, in `globals.css`: "Swiss red, and the
only colour in the product … reserving red for the isogloss is what keeps it
meaningful." It was right, and usage drifted away from it until flag red meant
button, selected, error, label AND dialect at once. One practice screen showed
three solid red blocks — the selected mode, the selected style, the question
itself — before the learner had answered anything. A colour that means five
things means none of them, and shouts all five.

So the hue stays, still the only colour, and each MEANING gets a role:

  --color-dialect   flag red -> a deep red INK (#9b1c22 / dark #ec8a8f).
                    Still the isogloss, read like a dictionary's second ink
                    rather than an alarm — and more legible: 8.1:1 on white
                    against flag red's 5.0:1, 7.9:1 in dark.
  --color-action    NEW, black. 40 filled red buttons and selected states.
  --color-danger    NEW, flag red — errors, and "this form is not Zurich".
                    Red where alarm is the right message, said by name.
  eyebrows          20 mono-caps labels at the top of pages: red -> grey.

Measured, elements rendering in flag red: /practice 4 -> 0, /vocabulary
113 -> 0, home 17 -> 6.

A CORRECT ANSWER WAS PAINTED IN THE COLOUR OF WRONG. `exercises/chrome.tsx`
rendered the verdict `right ? "text-accent" : …` — the right-answer message in
red. Now `text-ok`.

KEPT RED, deliberately: the record button (red is what recording looks like),
status dots, the active-nav underline, the focus ring, the "live" marker, and
thin 2px rules beside callouts and quotes — a restrained editorial accent,
which is the job red should be doing.

AND THE ISOGLOSS KEEPS FLAG RED, which my own guard taught me. I had moved
`correspondence-figure.tsx`'s highlight to the dialect ink; `dialect-lang.test`
(from #105) failed on it, and reading why showed the change was wrong in a way
the test did not even name: the figure marks the sound that CHANGES on both
words — Kind -> Chind — German side included. That is the isogloss itself, the
one thing the token comment reserved red for. Reverted, with the reason
written beside it.

The vocabulary trap line ("Nicht: Fussbodenbelag") also moves to its own grey
line: inline, it read as "DachbodenNicht: Fussbodenbelag" to anything that
reads text rather than pixels.

Verified: verify exit 0, 880 tests; audit:responsive 58 renders light+dark,
0 overflow; /practice and /vocabulary screenshotted before and after.

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-24 22:18:12 -07:00
..