In dark mode (via Dark Reader extension), a white flash appears when loading a new page
Categories
(WebExtensions :: Developer Outreach, defect, P5)
Tracking
(firefox119 affected)
| Tracking | Status | |
|---|---|---|
| firefox119 | --- | affected |
People
(Reporter: DeepChirp, Unassigned)
References
Details
Attachments
(2 files)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/119.0
Steps to reproduce:
- Launch Firefox and enable Dark Mode
- Open a webpage
Actual results:
Before the page loads, a white flash appears
Expected results:
The white flash should not appear until the page loads
Updated•2 years ago
|
Comment 1•2 years ago
|
||
I was able to reproduce the white flash on Win10x64 using FF build 119.0.
Mark issue as new.
Comment 2•2 years ago
|
||
We suspect there are a few issues here:
- In non-China-region Bing (at least in Canada and Italy), the search result page for Github doesn't directly link to Github, but to an intermediary that redirects to the actual Github page, and that intermediary is a page with a white background.
- In China-region Bing (which the screencapture appears to be on), the user is redirected to https://github.com/login, before going to https://github.com, and we suspect that this page for the user / their region is also one with a white background.
Ideally, these sites should be using the CSS properties for detecting user preference for light and dark themes to set their background colours.
| Reporter | ||
Comment 3•2 years ago
|
||
(In reply to Mike Conley (:mconley) (:⚙️) from comment #2)
We suspect there are a few issues here:
- In non-China-region Bing (at least in Canada and Italy), the search result page for Github doesn't directly link to Github, but to an intermediary that redirects to the actual Github page, and that intermediary is a page with a white background.
- In China-region Bing (which the screencapture appears to be on), the user is redirected to https://github.com/login, before going to https://github.com, and we suspect that this page for the user / their region is also one with a white background.
Ideally, these sites should be using the CSS properties for detecting user preference for light and dark themes to set their background colours.
In fact, this is not related to Bing, nor is it related to GitHub. I casually searched for a webpage and changed the direction of a hyperlink inside to github. com or another website. As long as it opens in a new tab, the screen will still be blank at the beginning. Please see my newly uploaded attachment.
link: https://zhidao.baidu.com/question/297091740.html
| Reporter | ||
Comment 4•2 years ago
|
||
Comment 6•2 years ago
|
||
The same thing seems to be happening with brave.com according to bug 1864444.
Updated•2 years ago
|
Comment 7•1 year ago
|
||
This seems to be an add-on issue. Perhaps it is still initializing or something like that. The DarkReader extension author should investigate this issue first.
A potential way to address this issue is through the browserSettings.overrideContentColorScheme extension API* that enables extensions to set the default theme for content. If set to dark, then the issue reported here would not happen, regardless of content script access (there are more ways for extensions to not be able to run scripts, e.g. bug 1411641).
| Reporter | ||
Comment 8•1 year ago
|
||
(In reply to Rob Wu [:robwu] from comment #7)
This seems to be an add-on issue. Perhaps it is still initializing or something like that. The DarkReader extension author should investigate this issue first.
A potential way to address this issue is through the
browserSettings.overrideContentColorSchemeextension API* that enables extensions to set the default theme for content. If set todark, then the issue reported here would not happen, regardless of content script access (there are more ways for extensions to not be able to run scripts, e.g. bug 1411641).
But the problem is that if Firefox is applied to a dark mode, the background color before loading the page should be black, not white. The white here is not caused by the lack of loading speed of Dark Reader. For example, I am now in mainland China and cannot access the BBC webpage. At this time, if I open the BBC page, the page has always been white.
Comment 9•1 year ago
|
||
What you're describing is when your system and/or browser is using the light theme.
Is your issue fixed when you enable Dark theme at "Website appearance", as documented at the following page?
https://support.mozilla.org/en-US/kb/change-website-appearance-settings-firefox
| Reporter | ||
Comment 10•1 year ago
|
||
(In reply to Rob Wu [:robwu] from comment #9)
What you're describing is when your system and/or browser is using the light theme.
Is your issue fixed when you enable Dark theme at "Website appearance", as documented at the following page?
https://support.mozilla.org/en-US/kb/change-website-appearance-settings-firefox
I did select the dark mode, but the white color before the page loads is still there
| Reporter | ||
Comment 11•1 year ago
|
||
This issue seems to be alleviated in Firefox 120.
Comment 12•1 year ago
|
||
(In reply to 1434323966 from comment #11)
This issue seems to be alleviated in Firefox 120.
Will go ahead and close this then.
Description
•