mirror of
https://github.com/luxfi/explore.git
synced 2026-09-24 00:28:18 +00:00
light mode: every heading and address was white-on-white
The gui provider pins `t_dark` on <body> client-side in BOTH schemes (the
server sends a bare <body>), and its theme block maps
.t_dark { --color: var(--c-color-background) } /* #ffffff */
against scheme-INVARIANT sources (--c-color-background #ffffff,
--c-color-text #000000). So every Tamagui text component resolved --color
to #ffffff unconditionally — correct by accident on dark, invisible on
light. Measured 1.00:1 at all four widths on /address/*, /validators and
the landing page: "Address details", the ADDRESS ITSELF, "Validators",
and six section headings. Pixel ground truth on the 1440 light heading
band: 135,034 of 136,000 pixels pure white, no glyphs at all.
A user clicking a Safe from lux.cloud landed on a page that never showed
which address they were looking at.
Only --color is corrected: the background already tracks html.light via
the Tailwind --lux-* layer. Not the earlier suspect — the circular
`--color-x: var(--color-x)` tokens are inert, because unlayered :root
beats @layer theme regardless of order.
Tamagui goes in cspell.jsonc words[], which is the real dictionary —
.cspell-words.txt is listed in ignorePaths, so it is a file cspell skips,
not a word source.
Co-Authored-By: Hanzo Dev <[email protected]>
This commit is contained in:
@@ -4,5 +4,6 @@ khtml
|
||||
parsdao
|
||||
platformvm
|
||||
reqs
|
||||
Tamagui
|
||||
ttfb
|
||||
unlayered
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
],
|
||||
// words - list of words to be always considered correct
|
||||
"words": [
|
||||
"Tamagui",
|
||||
"KHTML",
|
||||
"reqs",
|
||||
"ttfb",
|
||||
|
||||
@@ -278,3 +278,31 @@ html, body {
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
|
||||
/* ── light mode: Tamagui text was painting white on white ──────────────────
|
||||
The gui provider pins `t_dark` on <body> CLIENT-SIDE in BOTH schemes (the
|
||||
server sends a bare <body>), and its theme block reads:
|
||||
|
||||
.t_dark { --color: var(--c-color-background) } /* #ffffff */
|
||||
.t_light { --color: var(--c-color-text) } /* #000000 */
|
||||
:root { --c-color-background:#ffffff; --c-color-text:#000000 } /* invariant */
|
||||
|
||||
so every Tamagui text component (is_H1 / is_H3 / is_Text) resolved --color to
|
||||
#ffffff unconditionally — right by accident on dark, invisible on light.
|
||||
Measured at 1.00:1 across all four widths on /address/*, /validators and the
|
||||
landing page: "Address details", the ADDRESS ITSELF, "Validators", and six
|
||||
section headings. A user clicking a Safe link from lux.cloud landed on a page
|
||||
that never showed which address they were looking at.
|
||||
|
||||
The page BACKGROUND is not affected — that follows the Tailwind --lux-* layer,
|
||||
which already tracks html.light/html.dark correctly. Only the text colour is
|
||||
wrong, so only --color is corrected here. Both selectors are covered because
|
||||
the class is applied by script: html.light is the explicit signal, and the
|
||||
media query catches the pre-hydration frame.
|
||||
|
||||
Remove this the day the provider stops hard-pinning t_dark. */
|
||||
html.light body.t_dark { --color: var(--c-color-text); }
|
||||
@media (prefers-color-scheme: light) {
|
||||
html:not(.dark) body.t_dark { --color: var(--c-color-text); }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user