Live data from Hacker News

Using Dark Mode in CSS with MacOS Mojave

paulmillr.com

121–128 of 128 posts

Re: Using Dark Mode in CSS with MacOS Mojave

#122
post #61

I, for one, am tired of web pages being able to know things about the environment in which I view them outside of their sandbox. Orientation, battery, point:pixel ratio, user-agent, referer- now UI display preferences. I should be able to turn all of these off and make my browser indistinguishable from any other save for IP address if I so choose. This stuff just keeps rolling down the fingerprinting hill. Pretty soo…

Canvas fingerprinting along with most of these issues were solved with Safari 12 on both Mac OS and iOS. If you don't want to be fingerprinted, consider switching to it. Obviously there are some things that aren't yet anonymized in Safari 12, but it's good enough.

Safari’s code exec history (compared to Chrome) is enough to keep me from switching back, even if it is better at privacy in the not-execing-malicious-code typical use case.

Of course, on iOS, I don’t have a choice.

Re: Using Dark Mode in CSS with MacOS Mojave

#123

Earlier quoted context omitted.

I'd assume this is intended for web pages/apps to allow their in-page controls/navigation to fade into the background, revealing the content. E.g. in a crud app with top/side nav, and then a form in the main section, the nav bars can be rendered as pale/dark to suit the user selection, while the main content area retains the focus.

Yes, I definitely see the appeal for web apps. Just personally don't want to read 2,000+ word articles of white text on a dark background just because I like the browser UI to be dark. Others might, though — hopefully browsers will offer a setting for dark mode independent of the OS-level setting.

I think it'll be a while before most sites even consider adopting this (it's not even listed to check support on caniuse.com), and even if it does become widespread, reader mode has style-override controls to make the page more suitable for long-form reading just as it does now.

Re: Using Dark Mode in CSS with MacOS Mojave

#124

Earlier quoted context omitted.

It's really a matter of preference. I personally would be happy if my PDFs would automatically display in "dark mode" (not that I expect that to be implemented). Perhaps browsers just need a setting to toggle this.

Ctrl+I on Evince/Atril doc viewers. Then set as default: Ctrl+T

On Linux I use MuPDF which can also invert. (Although this isn't really "dark mode", since most PDF documents are black text on white, it gets the job done.)

Re: Using Dark Mode in CSS with MacOS Mojave

#126
post #87

As usual Apple has set off a major change in the way we do business. Newspapers, Apps, Slack, everything is going to start supporting dark mode. I think the original way we tackled "custom color schemes" of the OS was too much - we allowed people to set individual colors for everything. Once again apple has simplified that to just light mode and dark mode. And that's how the rest of the industry will finally tackle c…

Actually Mac OS was always pretty restrictive in what you could customize - in some ways they've actually doubled the number of choices you now have :)

Re: Using Dark Mode in CSS with MacOS Mojave

#127
post #87

As usual Apple has set off a major change in the way we do business. Newspapers, Apps, Slack, everything is going to start supporting dark mode. I think the original way we tackled "custom color schemes" of the OS was too much - we allowed people to set individual colors for everything. Once again apple has simplified that to just light mode and dark mode. And that's how the rest of the industry will finally tackle c…

Yea and this is purely driven by Apple needs. For e.g on Apple the UI is desturated so dark mode just means go darker. But for e.g on Linux with Arc theme, dark theme has a blueish tint, so the website using dark theme will look bad on Arc theme desktop. We should at least add the option hue & saturation to light/dark setting. Then the app/website would at least fit color-wise with the theme of the OS. But only dark/light is assuming all themes are desaturated which is true for Apple but not necessarily for other platforms

Re: Using Dark Mode in CSS with MacOS Mojave

#128
post #90

Cmd+F5, "Invert colors" (smart invert) This will turn everything into dark mode, except images and video. And you don't have to care if site has that line in CSS. Also, when you switch back - everything is in "light mode" again, including OS UI.

By default the keyboard shortcut is disabled in Mojave, and when turned on is actually Control+Option+Command+8.

Reenable the Control-Option-Command-8 keyboard shortcut to invert colors via: System Preferences > Keyboard > Shortcuts > Accessibility > check "Invert colors".
Post reply on HN