Step 2: Adjust styles with the prefers-color-scheme media query The color-scheme property and meta tag were renamed from supported-color-schemes in Safari Technology Preview 81 and macOS Catalina. The old name is supported by WebKit, Safari, and Mail in macOS 10.14.4. This is a developing standard that could change in the future. … We can use color-scheme to ensure that our squares prefer a light or dark style. This alone would enable both the light and dark themes, which you can then target with CSS selectors.

Alternatively, we can implement it using a meta tag in our HTML: > > This will display the index page in dark colors if the user has > > requested a dark color scheme in their system UI or browser, and > > display the same as the previous version if not.

This can even enable you to hide or display certain elements, like images, in … Thanks for reporting this. We would like to show you a description here but the site won’t allow us. The first one that matches will be picked. It works with the following values: light: Indicates that the user has notified the system that they prefer a page that has a light theme (dark text on light background). It works with the following values: light: Indicates that the user has notified the system that they prefer a page that has a light theme (dark text on light background). Step 1: Adjust the 2 proper meta tags up in the HEAD of your HTML. Now, you can include the below dark mode media query in a