Commit 8f98d6d
Fix report.html and index.html rendering dark-on-dark with no light background pinned
Neither page ever set an explicit `background` on body — harmless as
long as the viewer's browser defaults to a white canvas, but a viewer
with a dark OS/browser theme gets the page's own dark text color
(#1a1a1a, designed assuming a light background) rendered against a
dark canvas the page never asked for. Confirmed by actually rendering
a real --html report (with real screenshots and a Fail/Warn/Pass mix)
in a browser with a dark theme: the title, check names, and detail
text were all barely visible dark-gray-on-near-black, while only the
colored PASS/WARN/FAIL badges (which set their own background) stayed
legible.
Fixed both pages the same way: an explicit `background: #fff` on body
plus `color-scheme: light` on :root, since neither page has (or needs)
a dark variant — pinning to light is simpler and more honest than
half-supporting both. Verified by rebuilding, regenerating a real
report against the same fixture, and confirming it now renders as a
normal light page regardless of the viewer's theme.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>1 parent 4050463 commit 8f98d6d
2 files changed
Lines changed: 16 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
9 | 16 | | |
10 | 17 | | |
11 | 18 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
8 | 15 | | |
9 | 16 | | |
10 | 17 | | |
| |||
0 commit comments