Default prefers-color-scheme does not seem to be consistently applied
Categories
(Core :: CSS Parsing and Computation, defect)
Tracking
()
People
(Reporter: birtles, Unassigned)
References
(Regression)
Details
(Keywords: regression)
I'm afraid I don't have a reliable STR for this yet, but since bug 1529323 landed I've seen the following:
- Open up GitHub, and it uses the dark theme
- Open up another GitHub tab in a different container and it uses the light theme.
That might suggest logged-in state or containers have something to do with it but both containers were logged-in with the same account (where I have never manually changed the dark-mode setting).
Furthermore, some time later I experienced the following:
- Open up a Google search tab, and it uses the dark theme
- Open up another Google search tab along side it in the same container and it uses the light theme.
If it happens again I'll try to look for a pattern.
Note that the GitHub icon for me switches from black to white at some point during the load which is a bit odd. It looks like GitHub is doing some thing as part of its load but that doesn't explain the Google search case.
Comment 1•4 years ago
|
||
Google search was A/B testing automatic dark mode recently... Maybe you got unlucky and got the "A" and the "B" in different containers?
If it happens, the way to check whether it is a site problem or an ff problem would be to call matchMedia("(prefers-color-scheme:dark)").matches
in devtools in both tabs and see if they report different things.
Reporter | ||
Comment 2•4 years ago
|
||
The Google one was the same container so I'm not sure what was going on there.
Curious I currently get dark mode on Google search and light mode in GitHub but running matchMedia("(prefers-color-scheme:dark)").matches
in returns true in both cases.
Reporter | ||
Comment 3•4 years ago
|
||
Actually, never mind, I think GitHub might have been dark mode in a not logged-in container after all. Or at least that's my best guess now that I can't seem to reproduce it.
Maybe the Google search case was a cache thing. If I see this anywhere else I'll update this bug otherwise I think we can close it.
Comment 4•4 years ago
|
||
Ok, let's reopen if it happens again.
Updated•4 years ago
|
Updated•4 years ago
|
Description
•