-
-
Notifications
You must be signed in to change notification settings - Fork 32.5k
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
[Select] Add an option to not lock the body scrollbar #9595
Comments
I'm not sure if this issue is [Select] specific. It looks like it's related to all modals: This overflow hidden is from |
I'm closing for #13922. |
I am facing the same issue in the latest version of Material ui |
I'm facing the same issue, is there any solution/workaround for this? |
@brianperera You should use the <Select
MenuProps={{
disableScrollLock: true
}}
/> |
I know probably nobody is going to read this :) (but since this is the issue google pops up all the time), But is there any workaround for earlier versions? OFF: |
Sorry, we don't support older versions. |
It didn't work for me |
@oliviertassinari I think this is still an issue. Why select dropdown is hooked with the modal implementation. Select dropdown is not a pop up dialog. Its position should be relative to the select field. The whole modal body overflow:hidden is wrong for select. What if my select dropdown contains 200 items. I cannot even scroll the page with overflow: hidden. BTW, datepicker has the same issue. I think not everything is a modal :) Dropdown != Modal |
@peterlu-hinter This depends on your perspective, a native select on macOS behaves like a modal. We have moved the discussion to #17353.
This is fixed in v5: https://next.material-ui-pickers.dev/demo/datepicker |
Expected Behavior
To not hide overflow of body & make things shift when scrollbar disappears.
Current Behavior
Hides overflow of body.
Steps to Reproduce (for bugs)
<body>
tag that causes it to overflow or<body>
has style ofoverflow: visible
Context
It messes with styling that relies on body having overflow content. Below is a sample of what's happening on the demo site. Notice the scroll bar vanishing as soon as the menu pops up.
Your Environment
The text was updated successfully, but these errors were encountered: