From 9e99749de911ffc5b375bc79ee664d498e4d76d6 Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Tue, 16 Jun 2026 06:11:15 -0500 Subject: feat(theme-studio): move the contrast verdict into a hover The contrast column showed "5.4 PASS". The number's color already encodes the tier (green AAA, grey AA, red fail), so the PASS/FAIL word was redundant. I dropped it and put the WCAG meaning in the cell's hover via a pure contrastTitle helper. crHtml now renders just the colored number. verdictFor stays for the covered-overlay worst-case readout, which is unchanged. --- scripts/theme-studio/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts/theme-studio/app.js') diff --git a/scripts/theme-studio/app.js b/scripts/theme-studio/app.js index 23307edac..07ca06fe1 100644 --- a/scripts/theme-studio/app.js +++ b/scripts/theme-studio/app.js @@ -35,7 +35,7 @@ PALETTE_GENERATOR_UI_J // The contrast-cell readout shared by every table: a WCAG ratio colored by its // table verdict. Callers compute r for their own fg/bg. function verdictFor(r,target=4.5){return r>=target?'PASS':'FAIL';} -function crHtml(r,target=4.5){const v=verdictFor(r,target);return `${r.toFixed(1)} ${v}`;} +function crHtml(r){return `${r.toFixed(1)}`;} // Effective fg/bg with the standard fallback: an unset foreground reads as the // default fg (MAP['p']), an unset background as the ground (MAP['bg']). All three // tiers resolve their raw value through these before measuring or rendering. -- cgit v1.2.3