Dark theme (read property of useragent prefers-color-scheme)
From Gentoo Wiki
Jump to:navigation
Jump to:search
Talk status
This discussion is done as of November 1, 2020.
Hi, dark theme is important for many users because of sensitive eyes, working in a low light condition, and for battery saving. All modern browsers support this property <a rel="nofollow" class="external free" href="https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme">https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme</a>
Even without JavaScript, in pure CSS, you can override some CSS variable if user prefer it.