Tweet by @jh3yy
CSS Trick 🤙
You can create these tab bar controls by using :has() to count the number of tabs ⭐️
.tabs:has(input:nth-of-type(3)){--count: 3;}
.tabs:has(:checked:nth-of-type(3)){--active: 200%;}
.tabs::after{ translate:var(--active) 0;}
Let's break it down in this noscript!… https://t.co/mD9CbvKd6W https://t.co/PqMUkQln6l https://t.co/Nls5wq6jlt
— jhey ▲🐻🎈 (@jh3yy)
Jan 25, 2024