UI: Ensure Controls panel can scroll horizontally for now#34248
Conversation
|
View your CI Pipeline Execution ↗ for commit 59350a8
☁️ Nx Cloud last updated this comment at |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✅ Files skipped from review due to trivial changes (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughAdds an optional hasHorizontalScrollbar prop to AddonPanel and updates rendering to use ScrollArea when vertical or horizontal scrolling is enabled. The manager now forwards both scrollbar props to AddonPanel. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes ✨ Finishing Touches📝 Generate docstrings
Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
code/core/src/components/components/addon-panel/addon-panel.tsx (1)
30-30: Fix JSDoc article for readability.The comment should read “a horizontal scrollbar” instead of “an horizontal scrollbar.”
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@code/core/src/components/components/addon-panel/addon-panel.tsx` at line 30, Update the JSDoc for the horizontal-scrollbar property in the addon-panel component: change the sentence that currently reads "Whether the panel has an horizontal scrollbar, `false` by default" to "Whether the panel has a horizontal scrollbar, `false` by default" so the article is grammatically correct; locate the JSDoc comment above the horizontal scrollbar prop or related member in addon-panel.tsx and replace "an" with "a".
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@code/core/src/components/components/addon-panel/addon-panel.tsx`:
- Line 30: Update the JSDoc for the horizontal-scrollbar property in the
addon-panel component: change the sentence that currently reads "Whether the
panel has an horizontal scrollbar, `false` by default" to "Whether the panel has
a horizontal scrollbar, `false` by default" so the article is grammatically
correct; locate the JSDoc comment above the horizontal scrollbar prop or related
member in addon-panel.tsx and replace "an" with "a".
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 72458e55-2f81-4ee2-ba0f-f6b88cc8db09
📒 Files selected for processing (2)
code/core/src/components/components/addon-panel/addon-panel.tsxcode/core/src/controls/manager.tsx
JReinhold
left a comment
There was a problem hiding this comment.
Format is failing, but otherwise looks good.
25736c6 to
e5c07bc
Compare
Closes #33856
What I did
There were a few stale PRs not doing exactly what we needed, and we kinda need to own the decision to introduce a WCAG Reflow violation until we have time to design a narrower controls table for vertical addon panels with @MichaelArestad.
This PR allows AddonPanel to enable bidirectional scrolling, in a non-breaking way with existing code. Then, the Controls panel uses that new prop to fix the reported issue.
Checklist for Contributors
Manual testing
🦋 Canary release
This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the
@storybookjs/coreteam here.core team members can create a canary release here or locally with
gh workflow run --repo storybookjs/storybook publish.yml --field pr=<PR_NUMBER>Summary by CodeRabbit