:after and :before only apply to container elements

This is a fun fact for all of you CSS heads out there that I didn’t realize until this morning: The :before and :after pseudo elements only can be applied to containing elements, which makes sense, but hasn’t been something I’ve come across yet.

While the button tag, which is a container and can have elements slipped inside it, an input[type=button] cannot.

Check out this long Stack here for even more information

I am Dan Griffin and you can find me on Mastodon
CSS

The Blog

Base & Elevated System (and Grouped!) Background Colors

In iOS 13, Apple introduced a slew of new colors that are also dynamic – meaning they will adjust between light and dark modes (and other scenarios, such as high contrast). Of the new colors, the various background colors are pretty pecular: iOS defines two sets of background colors—system and grouped—each of which contains primary,…

iOS iOS 13

Always Taking Inquiries

At the moment I am not taking on many new projects, but am still available for inquiry or questions.

Reach Out To Dan