Hide and Debug Empty Elements with CSS
A quick CSS tip on using the :empty pseudo-class to hide and debug empty elements in layouts, especially useful for user-generated content.
A quick CSS tip on using the :empty pseudo-class to hide and debug empty elements in layouts, especially useful for user-generated content.
Explains how to use the CSS :has() pseudo-class to select and style previous sibling elements, a previously impossible task in CSS.
Safari now supports the CSS :has() pseudo-class, enabling powerful parent and relational element styling.
Explores creative uses of the CSS :target pseudo-class to create interactive elements like modals and navigation drawers without JavaScript.
A developer explores the CSS :visited pseudo-class, its privacy limitations, and attempts to creatively style unread links on a blog.