Hacker News new | ask | show | jobs
by dsego 1848 days ago
Cute, can I have tabs with equal widths based on the longest tab, without knowing the exact number of tabs?
2 comments

Yes you can: https://wt5hp.csb.app/ (implemented in pure CSS, with some JS to demonstrate that it works)
Thanks! And darn, I forgot about css grid. I think this example wasn't possible with flexbox a few years ago.
No. Ut I’d tell a designer that’s a stupid design and we can get pretty close to it if they really wanted it but overflows will make it look ugly depending on where they want this magic unlimited tab box.