3 ms·
I, too, appreciate HN's reluctance to add new features, and have zealously followed the same approach in maintaining my own tiny corner of the web for two decad
by miles 5y ago
I, too, appreciate HN's reluctance to add new features, and have zealously followed the same approach in maintaining my own tiny corner of the web for two decades.
But dark mode offers such immense retinal relief that a few lines of CSS¹ does not seem too unreasonable, especially since it means not having to trust third party extensions to do the job (though Firefox supports site-specific CSS rules natively: https://superuser.com/a/319322/38084 https://superuser.com/a/319322/38084 ).
¹ I arrived at these few lines for my simple site:
@media (prefers-color-scheme: dark) {
body {background: #222b39;color: #e1dfdc}
input,textarea {background: #333;color: #e1dfdc;border: 1px solid white}}
though HN likely requires a far more skillful and circumspect approach, e.g., https://news.ycombinator.com/item?id=23199649 https://news.ycombinator.com/item?id=23199649 .
- gpm 5y ago> prefers-color-scheme: dark How do I convince my browser (firefox, typically) to set this? Is there a way to toggle it on and off?
- ORioN63 5y ago> In Firefox you can add "ui.systemUsesDarkTheme" as an integer in about:config and set it to "0" for forced light or "1" for forced dark. This setting changes what is reported by the media query, you can still set your OS and/or browser theme independently. You will need to restart Firefox to apply the setting. [1] [1] https://news.ycombinator.com/item?id=21196903 https://news.ycombinator.com/item?id=21196903