4

If this can be detected - is there a possibility to influence colors by CSS classes or JavaScript?

With the dark reader extension, it is also possible to submit adjustments. Hope that it is also possible here, if nothing else could change it.

still
  • 73
  • 1
  • 5
  • Maybe that thread can help you :https://stackoverflow.com/questions/50840168/how-to-detect-if-the-os-is-in-dark-mode-in-browsers – Flo Oct 31 '19 at 15:44
  • 1
    Thanks for the hint. Unfortunately, none of the methods of this post work. So I would have expected it to be able to react with JavaScript or CSS. Unfortunately, it seems that it works with similar code as the "Dark Reader" Extension. – still Nov 04 '19 at 07:40
  • 1
    My guess is that Samsung Internet Browser needs to upgrade their embedded Chromium to 76 or greater: https://caniuse.com/#search=prefers-color-scheme – AWhitford Feb 15 '20 at 00:06

1 Answers1

7

Samsung Internet does strange things with colors in night mode. If you’re aware of them, you can sort of workaround any issues. I’ve not found a way to detect it, though. The color filtering takes place late in the rendering process so APIs aren’t updated. The obvious methods (such as window.getComputedStyle) returns original colors.

Daniel
  • 4,525
  • 3
  • 38
  • 52