Amit Sheen demonstrates using :has()
to apply styles conditionally when a certain <option>
in a <select>
element is chosen by the user and how we gain even more conditional styling capabilities when chaining :has()
with other pseudo-classes, such as :not()
— no JavaScript necessary.
https://smashingmagazine.com/2024/05/combining-css-has-html-select-conditional-styling/
Connectez-vous pour ajouter un commentaire
Autres messages de ce groupe
Juan Diego Rodriguez explains why media queries still occupy a vital role in responsive layouts; only they are now one tool in a larger toolbox with modern techniques that are best when used together.
Is there such a thing as harmony between designers and developers in the workplace, and if so, how can it be achieved? In this article, Chris Day explores the challenges of effective collaboration, ou
How do we conduct UX research when there is no or only limited access to users? Here are some workarounds to run UX research or make a strong case for it. An upcoming part of [Smart Interface Design P
Preethi Sam walks through an example that demonstrates where custom properties are more suitable than variables while showcasing the greater freedom and flexibility that custom properties provide for
In this comprehensive guide, Temani Afif explores different techniques for creating common shapes with the smallest and most flexible code possible. https://smashingmagazine.com/2024/05/modern-guide-m
React Server Components (RSCs) combine the best of client-side rendering, and author Lazar Nikolov thoroughly examines how we got here with a deep look at the impact that RSCs have on the page load ti
How do we conduct UX research when there is no or only limited access to users? Here are some workarounds to run UX research or make a strong case for it. An upcoming part of <a href='https://smart-in