Make every component and the landing page responsive (v0.3.1)
Every story and the landing page now fit from a 320px phone to a wide desktop without scrolling sideways. - Inputs in flex rows (Input, FeaturedInput, NumberInput, Combobox) shrink instead of holding their native width - Tab rows and ToggleGroup scroll within themselves on narrow screens; vertical tabs stack above their panel on phones - Positioned popups cap at Base UI's --available-width - Landing page: tablet header no longer crowds; code sample fits at 1024px - Storybook a11y panel skips page-level rules that can't apply to a story - check-stories.mjs gains --width and fails on horizontal overflow; all 423 stories pass at 320, 375, 768 and desktop widths in both modes
This commit is contained in:
1 parent
f01de83733
commit
23e67006d3
24 files changed
+136
-31
No files matched your search
@@ -83,6 +83,20 @@ comment; Storybook's docs table reads them.
|
||||
as the WAI-ARIA pattern describes. Base UI does this when used as documented.
|
||||
- Respect `motion-reduce:` for animations.
|
||||
|
||||
## Responsive
|
||||
|
||||
Every component must work from a 320px phone up without making the page
|
||||
scroll sideways:
|
||||
|
||||
- Inputs inside flex rows use `w-0 min-w-0 flex-1` so they can shrink.
|
||||
- Rows of items (tabs, segmented controls) scroll within themselves on narrow
|
||||
screens rather than widening the page.
|
||||
- Positioned popups cap at `max-w-(--available-width)`; never give them a
|
||||
`min-width` larger than that.
|
||||
- Story layouts wrap (`flex-wrap`) instead of assuming a wide canvas.
|
||||
|
||||
Check with `node scripts/check-stories.mjs --width 320` (and 375 and 768).
|
||||
|
||||
## Stories
|
||||
|
||||
- `title`: `Group/Name`. Groups: `Actions`, `Forms`, `Overlays`, `Navigation`,
|
||||
|
||||
Reference in new issue
Block a user