Closed Bug 1736142 Opened 4 years ago Closed 4 years ago

Default prefers-color-scheme does not seem to be consistently applied

Categories

(Core :: CSS Parsing and Computation, defect)

defect

Tracking

()

RESOLVED WORKSFORME

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:

  1. Open up GitHub, and it uses the dark theme
  2. 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:

  1. Open up a Google search tab, and it uses the dark theme
  2. 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.

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.

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.

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.

Ok, let's reopen if it happens again.

Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → WORKSFORME
Has Regression Range: --- → yes
You need to log in before you can comment on or make changes to this bug.