Designing a Dark Mode Is Harder Than It Looks

Eusebio Walker
|
February 6, 2024

Dark mode style sheets are all the rage, but they aren’t just a black-and-white matter. Scannability and readability are important aspects of proper design too. In this episode of Tangled Web Services, Clarissa tries her hand at creating a dark mode style sheet, and finds out that it’s a bit trickier than it looks.

Clarissa, the design and marketing pro behind TWS, has honed her CSS design skills around modern typography and classic color theory. But with dark mode schemes suddenly all the rage, she wanted to try her hand at something a bit different.

Using a proven light mode style sheet as a starting point, Clarissa began work on its transition to dark mode.

Thankfully, all of the color rules had been declared using CSS variables like var(--blue). So most of the work ahead of her would simply be to declare new color values for the variables. Or so she thought.

The first challenge was a black-and-white matter… er, var(--black) and var(--white). What’s the best background color for the page? She knew what paper makers, fine art printers, and book designers have known for ages — that pure white paper is hard on the eyes. So she suspected that the inverse would also be true, that a pure black background would not be suitable for reading text.

After trial and error, Clarissa settled on a standard black background color value of #333. It had just enough luminosity to get away from the starry midnight effect and to instead cast an early evening glow. This choice also had the benefit of allowing for several darker shades of black to be used on background accents for block elements like blockquote, pre, and figcaption, and for inline elements like code.

written by
Eusebio Walker
Est hic voluptatem odit similique quia voluptatem hic. Dicta nobis sint. Tenetur numquam corrupti quia tempore eum. Doloremque voluptas eum similique non alias et. Qui voluptatem et iure eum saepe. Eum aut nisi. Harum consequatur impedit qui voluptas esse consequatur qui soluta. Nihil sequi qui eligendi dicta sed voluptas. Beatae sed quia consequuntur nulla animi maiores minima. Rerum sit dolor expedita dolore et asperiores sunt facere et. Quod rep