fix(configurator): keep preview toolbar to a single row on mobile - #466
Conversation
The toolbar used flex-wrap below md, so on narrow viewports its template tabs, width/theme controls, motion select, and refresh/ external-link buttons wrapped onto 2-3 lines — eating a large chunk of a short mobile screen before any preview content was visible. Switch to a fixed-height single row that scrolls horizontally instead of wrapping (h-10, flex-nowrap, overflow-x-auto), with shrink-0 on every control group so none of them get squeezed to near-invisibility competing for space in the nowrap row. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SQXr34nocCi1jrGcp5TPVm
|
Warning Review limit reached
Next review available in: 3 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Pulls in the PreviewPanel.svelte change from codeslash-dev/SLASHED#466: the preview toolbar (template tabs, width/theme controls, motion select, refresh/external-link) no longer wraps onto 2-3 lines on narrow viewports, eating a large chunk of the WP admin Tokens page on mobile. It's now a fixed-height single row that scrolls horizontally. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SQXr34nocCi1jrGcp5TPVm
PR Summary by QodoFix preview toolbar to stay single-row on mobile
AI Description
Diagram
High-Level Assessment
Files changed (1)
|
Code Review by Qodo
Context used✅ Compliance rules (platform):
6 rules 1.
|
A hard h-10 could clip a control that renders taller than 40px (OS text-size scaling, browser zoom, platform-native <select> styling) — only horizontal overflow was handled, so anything taller than the fixed height would be cut off. min-h-10 keeps the same 40px height in the normal case (verified) but lets the row grow if a child genuinely needs more, while flex-nowrap + overflow-x-auto still keep it a single non-wrapping row. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SQXr34nocCi1jrGcp5TPVm
Pulls in the PreviewPanel.svelte change from codeslash-dev/SLASHED#466: switch the preview toolbar from a hard h-10 to min-h-10 so it can't clip a control that renders taller than 40px (OS text scaling, browser zoom, platform-native <select> styling) while keeping the same single-row, non-wrapping behavior in the normal case. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SQXr34nocCi1jrGcp5TPVm
Summary
flex-wrapbelow themd:breakpoint, so on narrow viewports it wrapped onto 2-3 lines.hidden md:flexreliably reasserts visibility atmd:and above regardless of the mobile fold-toggle state, no bug there.h-10) single row that scrolls horizontally (overflow-x-auto) instead of wrapping vertically. Had to addshrink-0to every control group (template tabs, width controls, theme controls, motion select, refresh, external-link) — without it, switching toflex-nowrapcaused the first group (template tabs) to be squeezed to near-invisibility since it was the only child without an explicit no-shrink, while everything else held its size.Test plan
npx svelte-check— 0 errors.npm run build— builds cleanly.🤖 Generated with Claude Code
https://claude.ai/code/session_01SQXr34nocCi1jrGcp5TPVm
Generated by Claude Code