M3.1 token alignment — the palette to Design's exact package values

Reconcile finding: the live tokens had DRIFTED from Design's package (HANDOFF
"Tokens (exact)"). Per the standing conflict rule (Design specified exact hexes
→ rejected the drift → Design wins), aligned the whole palette:
- Surfaces: --bg-1 #0E0E16→#0E0E14, --bg-2 #15151F→#14141E; added --bg-deep
  #0A0A10 + --hairline #101018 (Design's ramp).
- Text: --text-0 #E8E8F0→#F0F0F0, --text-1 #7A7A8E→#B8BCC8 (Design's secondary
  is far brighter), --text-2 #4A4A5E→#707080, added --text-3 #4a4a58 micro.
- Borders: #1E1E2E→#1E1E2A, #2A2A3E→#2A2A38.
- GRADES (the big one): B blue #4A9EFF → neutral-bright WHITE #F0F0F0; C amber
  #FFB347 → muted GREY #B8BCC8; D #FF5252 → #FF4757. The old blue/amber actually
  violated DESIGN-SPEC v2's OWN "B neutral-bright, C muted" — this fixes a
  long-standing drift, confirmed by Design's package. Amber stays its own token
  (--amber); --warning decoupled to --amber; --miss → #FF4757.
- vyndrTokens.js GRADE_HEX mirror + the design-system test updated to match.

Big VISUAL change (grade color language), VISUALLY UNVERIFIED at 390px/desktop
— on the Chrome-audit list. Every surface inherits it, so it lands first.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Kev
2026-07-16 16:19:30 -04:00
parent 63511485ed
commit e0a26a8055
3 changed files with 38 additions and 29 deletions
+5 -3
View File
@@ -13,10 +13,12 @@ const GRADE_COLORS = {
};
/* Grade → raw hex (for SVG fills / contexts where a var won't resolve). */
// Design package exact grades (HANDOFF): A green · B neutral-bright white ·
// C muted grey · D/F red #FF4757 (was blue/amber/#ff5252 — aligned 2026-07-16).
const GRADE_HEX = {
'A+': '#00ffb8', A: '#00d4a0', 'A-': '#00d4a0',
'B+': '#4a9eff', B: '#4a9eff', 'B-': '#4a9eff',
C: '#ffb347', D: '#ff5252',
'B+': '#f0f0f0', B: '#f0f0f0', 'B-': '#f0f0f0',
C: '#b8bcc8', D: '#ff4757',
};
/* Sport config map. */
@@ -38,7 +40,7 @@ function gradeColor(g) {
return GRADE_COLORS[g] || 'var(--text-0)';
}
function gradeHex(g) {
return GRADE_HEX[g] || '#e8e8f0';
return GRADE_HEX[g] || '#f0f0f0';
}
function gradeBadgeSize(size) {
if (typeof size === 'number') return size;