Since I went over to the dark side and set dark mode as my display preference in Windows, I have noticed that a few (not many) websites recognise my preference and display in dark mode.
I have since been playing around with @media (prefers-color-scheme: dark) on some of my own sites, but does anyone use this for their websites?
Are you coding the colors directly onto CSS properties? That’s the only way I can get it to work, which would be seriously cumbersome in a large site, it seems.
It does work, but he doesn’t have a connection to the media query method that Gandalf mentioned above, getting the light/dark from the Windows setting. He just does it via a user button selection of light or dark, setting the data attribute via JS. His method would conceptually require a user to click a light/dark button on every browser tab, and every time a page was brought up. That is, unless I’m reading it wrong.