-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Components: Remove unnecessary wrappers in stories #45305
Components: Remove unnecessary wrappers in stories #45305
Conversation
Size Change: 0 B Total Size: 1.28 MB ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes themselves look good to me, but while testing I noticed that ToolsPanel
and Card
appear to be stretching beyond the width of the viewport:
On Card
, this can even result in the story's CTA button to getting cut off:
I'm not sure if this is an indicator that we still need a wrapper, just to set the max to the viewport width, or if this should be addressed in the individual components themselves 🤔
Do you see anything similar @aaronrobertshaw? In case it's browser related, I'm testing in latest Chrome (107.0.5304.62)
Actually, scratch that last comment @aaronrobertshaw ...those issues do look like something local to just me. I noticed some other viewport oddities, and after fresh Storybook build this is testing well for me 👍 |
Thanks for the review @chad1008. I gave this a quick retest as well and couldn't replicate the problem you initially saw. I'll go ahead and merge this. |
Related:
What?
Removes wrappers setting max-widths that are no longer required.
Why?
A new storybook addon was added in #45134 that allows quick toggling of a wrapper that restricts the max width of components to the space available within the WP sidebar. With this we can now remove arbitrary max-width wrappers for component stories.
How?
Removes the max width wrappers in stories for:
#41860 already removes wrappers for the border controls so they aren't addressed in this PR.
Testing Instructions
max-width
ormaxWidth
within any**/stories/**
directory.