Skip to content
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

fix: horizontal scrolling overflow #6361

Merged

Conversation

casvil
Copy link

@casvil casvil commented Apr 1, 2019

Issue: A component (In my use case a table with fixed th, td widths) does not overflow when the content of the storybook does not fit de viewport.

What I did

I added the property overflow: auto to the inner div of the centered add-on.

How to test

This should be tested by setting a viewport width smaller than the width of the component being rendered.

If your answer is yes to any of these, please make sure to include it in your PR.

@casvil casvil requested a review from kazupon as a code owner April 1, 2019 07:53
@casvil
Copy link
Author

casvil commented Apr 1, 2019

this is a feature request :)

@casvil
Copy link
Author

casvil commented Apr 2, 2019

@shilman @kazupon how to proceed from here? Is anything that can be done from my end?

@shilman
Copy link
Member

shilman commented Apr 2, 2019

Hi @casvil thanks for your contribution!!

Two requests:

  • attach a picture of before & after to the PR to make it easier to review, or better yet, add a story that demonstrates this behavior to the official-storybook
  • update the storyshots snapshots by running yarn test --core --update and committing the results?

Much appreciated 🙏

@casvil
Copy link
Author

casvil commented Apr 2, 2019

The content fits de viewport: the content fits de viewport

The content does not fit the viewport and a scrolling bar appears under the table:
the content does not fit the viewport and a scrolling bar appears under the table

The content does not fit the viewport and a scrolling bar appears under the storybook viewport:
the content does not fit the viewport and a scrolling bar appears under the storybook viewport

@casvil
Copy link
Author

casvil commented Apr 2, 2019

@shilman failed tests after running yarn test --core --update. Can't update snapshots. What can I do?
Thanks!

Screenshot from 2019-04-02 16-47-17

@shilman
Copy link
Member

shilman commented Apr 3, 2019

Ah @casvil sorry for the slow reply. Try running yarn bootstrap --core first.

@vercel
Copy link

vercel bot commented Apr 3, 2019

This pull request is automatically deployed with Now.
To access deployments, click Details below or on the icon next to each push.

Latest deployment for this branch: https://monorepo-git-fork-casvil-fix-horizontal-ov.storybook.now.sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants