conceptualspace / nightlight

🌘 Inverted display mode for better viewing ergonomics in dark lighting
https://addons.mozilla.org/addon/night-light-mode
Mozilla Public License 2.0
12 stars 0 forks source link

Just inverts color space? #6

Closed 211217613 closed 5 years ago

211217613 commented 5 years ago

Does this addon only invert color already on the screen?

While the dark background is nice, it distorts the look of the top bar.

Github example:

Normal: image

With addon enabled: image

dsego commented 5 years ago

I've noticed this problem on youtube. Youtube has its own dark theme, which night light just inverts back to white.

conceptualspace commented 5 years ago

thanks for the feedback.

nightlight uses some heuristics to decide what to invert. generally only the background is inverted and colored elements are subdued to maintain the contrast and aesthetic of the page. in the case of github, that means the top bar is lightened (if it were merely inverted it would be pink).

i suppose we could add some specific rules for fringe cases like this but the risk is that (1) they would be subject to change and (2) we want to keep the plugin as efficient as possible; adding a lot of rules to the process could make sites slower and less responsive.

in the case of youtube, videos should be played normally, but see (1) above. will look to fix that for the next update

conceptualspace commented 5 years ago

@dsego if you use the dark theme on youtube you could add it to nightlight's whitelist so it doesn't invert it on you. and we'll see if we can get nightlight to detect the dark theme automatically in the next update

dsego commented 5 years ago

@conceptualspace I didn't know about the whitelist, it's actually good enough for me. Thank you! :blush: