Links
Modern CSS Round-Out Tabs
I’m so hyped on
shape(). It’s an amazing addition to CSS, giving us a primitive that can draw, well, anything you could draw with a pen tool. In our case we’re going to use theshape()primitive withclip-pathto carve a tab shape out of a rectangle. No extra elements!
Custom CSS Functions in the Browser
There’s been a lot of progress in the CSS Working Group lately, but I want to draw your attention to a prototype that landed in Chromium ‘Canary’ (v136+) browsers with the experimental platform features flag enabled. Author-defined Functions are coming to CSS, and you can start to experiment with them now!
CSS :is() :where() the Magic Happens
Both
:is()and:where()come with many advantages beyond just reducing the complexity of your code and provide a lot of ways to write more flexible, useful, and maybe even a bit magical CSS. There are a lot of reasons to include them in your arsenal of modern CSS tools today.
Transition to the Other Side with Container Query Units
How container queries help move an element to the opposite side of its parent container when both have dynamic responsive dimensions.
forced-color-adjust: none is an unavoidable foot gun
The problem with adding
forced-color-adjust: noneis that it allows all CSS-styled colors to come through on that element, not just system colors. So even if you (a responsible developer who cares enough about accessibility to have stumbled on this blog) craft beautifully accessible forced-colors CSS using only system color keywords, someone else may come along and unintentionally screw it up. Usually without ever knowing that they affected high contrast mode styles at all.
Videos
Light mode versus Dark mode, why not both?
It doesn’t have to be this way. Some people have very real physical reasons to need one mode over another. The rest of us are also allowed to have our favourites, or might prefer light mode in some situations and dark in others. What if Sara said it was super easy to code up both dark and light modes at the same time? Despite Sara’s evangelising efforts, not enough people know of the CSS property
color-schemeand how powerful it is.
Sponsor
Sponsored by Cloud Four
Thanks to Cloud Four for sponsoring this week’s newsletter! They solve complex responsive web design and development challenges for ecommerce, healthcare, fashion, B2B, SaaS, and nonprofit organizations.
If you’d like to help with the costs of running Friday Front-End, you can back our Patreon for as little as a dollar a month.