HACKER Q&A
📣 GalenErso

Why does Chrome's Dark Mode extension not work on HN?


The extension in question: https://chrome.google.com/webstore/detail/dark-mode/dmghijelimhndkbmpgbldicpogfkceaj

It works on 99% of websites, but not on HN. The white background turns dark, but the HN box in the middle remains the same color. Why is that?


  👤 battles Accepted Answer ✓
It looks like hn uses the deprecated 'bgcolor' attribute for that part of the page which overrides the css for the extension. https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tr...

👤 dredmorbius
As an alternative, you can hack HN's CSS directly using Stylus.

My "Madhackery" theme isn't dark, but could be with reasonable ease:

<https://pastebin.com/gLXiqKyd>

And here's something I've hacked together quickly based on the previous style, for an HN dark mode:

<https://pastebin.com/HmHBWwjE>