mirror of
https://github.com/harvard-edge/cs249r_book.git
synced 2026-05-07 18:18:42 -05:00
[PR #1557] [MERGED] fix(tinytorch/ux): coverage for accent text + light-gradient panels #8265
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/harvard-edge/cs249r_book/pull/1557
Author: @farhan523
Created: 4/26/2026
Status: ✅ Merged
Merged: 4/26/2026
Merged by: @profvjreddi
Base:
dev← Head:fix/tinytorch-dark-mode-accent-text-colors📝 Commits (1)
2b475f0fix(tinytorch/ux): dark-mode coverage for accent text + light-gradient panels📊 Changes
1 file changed (+20 additions, -0 deletions)
View changed files
📝
tinytorch/quarto/assets/styles/dark-mode.scss(+20 -0)📄 Description
Background
Two narrow extensions to the inline-style safety net in
dark-mode.scss. Found while QA'ing the tito reference pages andresources.htmlin dark mode after the previous round of fixes.Changes
tinytorch/quarto/assets/styles/dark-mode.scss(one file, +20 lines):Saturated 700-shade accent text colours used inline on h4 section headers across
tito/data.qmd,tito/modules.qmd,tito/overview.qmdwere failing WCAG AA on the#2d2d2dcard surface (~2–3.5:1 contrast). Flip each to a 400-shade variant of the same hue so semantic colour coding (blue / purple / green / amber sections) survives instead of being flattened to slate:#1976d2blue-700#60a5fablue-400#7b1fa2purple-700#c084fcpurple-400#15803dgreen-700#4ade80green-400#d97706amber-600#fbbf24amber-400Light-gradient panels weren't being caught by the existing
[style*="background: #X"]selectors because thelinear-gradient(prefix breaks substring matching. Add a selector that matches the gradient prefix and flips the soft-blue gradient onresources.qmd:13to the same#2d2d2dsurface as solid-fill panels.Test plan
cd tinytorch/quarto && quarto render --to htmlsucceeds for all 52 pagestito/modules.html— h4 section headers (Check Environment, Start Module, Resume Work, Export & Complete, Check Progress) keep their semantic blue / purple / green / amber tint but in lightened form, readable on#2d2d2dtito/overview.htmlandtito/data.htmlresources.htmlin dark mode — formerly soft-blue gradient panel now renders as#2d2d2dcard with readable textdark-mode.scssis loaded only in dark mode per_quarto.yml:251-254🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.