Webkit Code References Hint Apple Could Bring System-Wide โDark Modeโ On macOSย 10.14
We had recently reported that Microsoft is looking to add a dark theme to File Explorer in Windows 10 Redstone 5. While this news brought joy to Windows users, users of Mac were left a tad disappointed.
However, there could be some good news for Mac users. According to a report fromย 9to5Macโs Guilherme Rambo, some lines were discovered in WebKitโs source code (of a nightly build posted back in March)ย that suggest Apple is working on to allow apps to set dark theme components within Safari instance.ย This hints that Mac computers might get some kindย of system-wide support for dark mode in the next update, which is macOS 10.14.
For those unfamiliar, WebKit is the open-source web browser engine used by Safari, Mail, and the App Store on both macOS and iOS. Since it is developed in the open, it indirectly hints at new features that may surface on macOS and iOS platforms.
โThe code in question is designed to adapt WebKit’s rendering of a website based on the effective appearance of the application. Appearances are the way through which macOS can change the look of UI components like buttons and lists based on assets provided by the system โฆ Having the concept of a system appearance means Apple is working on a way to change the appearance of apps globally, although there are no direct references to a dark mode (for obvious reasons), but the most likely reason for the existence of an API like this is a dark mode,โ Rambo wrote.
While a โdark modeโ feature is already present in macOS since El Capitan, it is only used when the app developer chooses to use it explicitly.
This is what happens when you build WebKit without the OS version checks and implement effectiveAppearance on NSApplication to return the dark appearance (notice the button and pop up). Dark Mode ยฎ pic.twitter.com/svWS48FCge
— Guilherme Rambo (@_inside) April 21, 2018
Although the news definitely sounds exciting, other than a reference to a new system appearance API, there is no other conclusive evidence that a dark mode will show up in macOS 10.14.
Do let us know if you want dark mode on macOS and iOS in the comments section below.
Source: 9to5mac