Commit b667e64
fix(tabs): stop scrollable tabs from shrinking/clipping labels on resize
Tabs are flex children of `.tab-wrap`. In a `.tab-wrap.scrollable` bar the
container has `overflow-x: scroll`, but the tabs still default to
`flex: 0 1 auto`, so when the bar is too narrow (resize / browser zoom /
reflow) the browser shrinks each tab below its content width — squashing and
clipping the labels instead of scrolling.
Set `flex: 0 0 auto` on `.tab` ONLY inside `.tab-wrap.scrollable`, so tabs keep
their content width and the bar scrolls. Scoping to `.scrollable` leaves
non-scrollable variants untouched — notably the stat `full-width` variant,
which sets `--width: 100%` and relies on the default `flex-shrink: 1` to share
the row and would otherwise overflow.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 5875504 commit b667e64
1 file changed
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
7 | 15 | | |
8 | 16 | | |
9 | 17 | | |
| |||
0 commit comments