fix(ui): custom sidebar width overflowed the mobile overlay#35
Merged
Conversation
The resizable-sidebar width is persisted and was applied inline in every layout.
In the narrow/overlay layout (< 992px) a wide desktop width (e.g. 600px) made
the sliding sidebar wider than a phone screen when opened.
Apply the custom width only on desktop (via a sidebarStyle computed that returns
{} in narrow view); the overlay width is now CSS-driven (300px, max-width 85vw)
so it never overflows the viewport.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Context
Follow-up to the resizable sidebar (#33). While checking phone responsiveness I found a rough edge it introduced.
Symptom
The resizable-sidebar width is persisted and was applied inline in every layout. In the narrow/overlay layout (< 992 px), a wide desktop width (e.g. 600 px) made the sliding sidebar wider than a phone screen when opened.
Fix
Apply the custom width only on desktop — a
sidebarStylecomputed returns{}in narrow view, so the overlay width is CSS-driven (width: 300px; max-width: 85vw) and never overflows the viewport. Desktop resizing is unchanged.Verification
npm run test:unit-ci— 1048 passed (added a narrow-view case to the AppLayout resize tests).Note on overall mobile support
The app is responsive: viewport meta is set, the sidebar collapses to a hamburger overlay below 992 px, and there's no horizontal overflow. This PR removes the one overflow case introduced by the resize feature.
🤖 Generated with Claude Code