v4: Dark Reader is kept off the pages, which lost every background under it — on a phone in dark mode with the extension on, the avatar menu, the cards and the tabs were transparent over Dark Reader's own page colour, in every style. The build gives each light-dark() a fallback for the browsers without it, two custom properties of which one is empty, and Dark Reader's rewrite of the stylesheet drops the empty one under a dark system theme: both halves of every colour then apply at once, which is no colour, so nothing paints a background or a border. index.html now carries <meta name="darkreader-lock">, which the extension obeys by generating nothing; the site has dark palettes of its own, following the system or the user's choice. The dev server never showed it, serving light-dark() as written.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
khannurien
2026-10-10 09:26:21 +00:00
parent de223baaa4
commit 1bd5c924b0

View File

@@ -9,6 +9,11 @@
<link rel="icon" type="image/png" sizes="96x96" href="/favicon-96x96.png?v=__ICON_VERSION__" />
<link rel="icon" type="image/png" sizes="192x192" href="/favicon-192x192.png?v=__ICON_VERSION__" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<!-- Keeps the Dark Reader extension off the page, which has dark palettes
of its own: it rewrites the stylesheet's colors, and its rewrite of
the fallback the build gives every light-dark() leaves them all
invalid under a dark system theme, so no background is painted. -->
<meta name="darkreader-lock" />
<meta name="theme-color" media="(prefers-color-scheme: dark)" content="#01152a" />
<meta name="theme-color" media="(prefers-color-scheme: light)" content="#faf5e9" />
<meta name="site-name" content="__SITE_NAME__" />