fix: declare color-scheme, so navigation stops flashing white
The mark is fill="currentColor" inside an anchor, so an unstyled paint renders it in the UA link blue. That is what the flash is: the document painted before the stylesheet applies, not a theme switch. Without a color-scheme declaration the browser treats the document as light, so the canvas it paints between documents, and the scrollbar, are white. Gecko paints a pending stylesheet's document far more readily than Blink does, which is why it shows there and not in Chromium. Dark on flux and bbs, which are dark only; all three branches on raayoni. The other half of this is a Caddy change in bucur: every response currently carries no Cache-Control, no ETag and no Last-Modified, so the stylesheet is refetched on every navigation and the window keeps reopening. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
parent
8505b7e9e0
commit
c97fcb249b
3 changed files with 14 additions and 1 deletions
|
|
@ -59,6 +59,10 @@
|
|||
}
|
||||
|
||||
:root, [data-theme="dark"] {
|
||||
/* Not decoration: without color-scheme the browser treats the document as
|
||||
light, so the canvas it paints between documents, and the scrollbar, are
|
||||
white. On Gecko that is the white frame you see on every navigation. */
|
||||
color-scheme: dark;
|
||||
--ground: #111;
|
||||
--ground-alt: #191919;
|
||||
--title: #aaa;
|
||||
|
|
@ -72,6 +76,7 @@
|
|||
}
|
||||
|
||||
[data-theme="light"] {
|
||||
color-scheme: light;
|
||||
--ground: #f7f6f4;
|
||||
--ground-alt: #efeeea;
|
||||
--title: #2b2b2b;
|
||||
|
|
@ -88,6 +93,7 @@
|
|||
|
||||
@media (prefers-color-scheme: light) {
|
||||
:root:not([data-theme]) {
|
||||
color-scheme: light;
|
||||
--ground: #f7f6f4; --ground-alt: #efeeea; --title: #2b2b2b; --body: #343434;
|
||||
--sub: #6a6a6a; --meta: #5f5f5f; --rule: #dcdad4; --tile: #eceae5;
|
||||
--panel-lift: rgba(0,0,0,.22);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue