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

[Modal] Nested modal demo wrong scroll #37330

Closed
2 tasks done
PatrykKuniczak opened this issue May 19, 2023 · 8 comments · Fixed by #37506
Closed
2 tasks done

[Modal] Nested modal demo wrong scroll #37330

PatrykKuniczak opened this issue May 19, 2023 · 8 comments · Fixed by #37506
Labels
bug 🐛 Something doesn't work component: modal This is the name of the generic UI component, not the React module! docs Improvements or additions to the documentation regression A bug, but worse

Comments

@PatrykKuniczak
Copy link

Duplicates

  • I have searched the existing issues

Latest version

  • I have tested the latest version

Steps to reproduce 🕹

Link to live example:
https://mui.com/base/react-modal/#nested-modal

Steps:

  1. Click "Open modal"
  2. Try to scroll ;)

Current behavior 😯

When i try to scroll or click outside on this modal(link above) nothing happend.

I can't close it on other way, than refresh page.

And as you can see on this screen:

ss

I see only a half of this modal, cause navbar cut it, you have wrong positioning.

The same case is here:

https://mui.com/base/react-focus-trap/#basics

When i click "Open" and the focus trap is displaying:
ss3

Then i scroll down, then click anywhere, and the similiar bug occure, i see only this:
ss2

i think a if this slide a height of navbar above i can see properly this input.

When i scroll up and click everywhere it work properly i see input bar on the bottom of the page.

Expected behavior 🤔

Work properly :) 🥇

Context 🔦

Windows 7 x64
Firefox 113.0.1

Your environment 🌎

npx @mui/envinfo
  Don't forget to mention which browser you used.
  Output from `npx @mui/envinfo` goes here.
@PatrykKuniczak PatrykKuniczak added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label May 19, 2023
@zannager zannager added component: modal This is the name of the generic UI component, not the React module! component: FocusTrap The React component. labels May 19, 2023
@michaldudak
Copy link
Member

Thanks for reporting this. Therse are actually two separate issues - the inability to close the modal with a mouse (it's still possible to close it with the Esc key). I was able to reproduce the positioning issue on Firefox as well.

@michaldudak michaldudak added bug 🐛 Something doesn't work and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels May 22, 2023
@michaldudak michaldudak removed their assignment May 22, 2023
@PatrykKuniczak
Copy link
Author

@michaldudak If nobody take it in this week, i can try to fix it, but i must read CONTRIBUTION and gain knowledge how to do it, cause the repo is huge :)

Now i know only, the components are located in 'packages' :)

@michaldudak
Copy link
Member

Sure, go ahead. Feel free to ask if you need clarification. I'll be unavailable for two weeks starting this Thursday, but another maintainer should be able to help you.

@gitstart
Copy link
Contributor

@michaldudak I would like to pick this up if it's still available.

@PatrykKuniczak
Copy link
Author

@michaldudak I would like to pick this up if it's still available.

Go ahead, with not hesitate 😁

I don't have time now, maybe i can start next week, start coding, and maybe i can help you if u have trouble 😁

@PatrykKuniczak
Copy link
Author

@michaldudak I would like to pick this up if it's still available.

You're right? :)

@oliviertassinari
Copy link
Member

oliviertassinari commented Jun 5, 2023

Link to live example: https://mui.com/base/react-modal/#nested-modal

This looks like a regression from #36873, https://deploy-preview-36873--material-ui.netlify.app/base/react-modal/#nested-modal doesn't work anymore. To figure out what happened.

The same case is here react-focus-trap

This looks off-topic to the first bug and the normal behavior.

@oliviertassinari oliviertassinari added regression A bug, but worse and removed component: FocusTrap The React component. labels Jun 5, 2023
@oliviertassinari oliviertassinari changed the title [Modal, Focus Trap] Nested modal and Focus trap, wrong sliding [Modal] Nested modal demo wrong scroll Jun 5, 2023
@oliviertassinari oliviertassinari added the docs Improvements or additions to the documentation label Jun 5, 2023
@ZeeshanTamboli
Copy link
Member

I created a separate issue #37866 for the second issue reported here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something doesn't work component: modal This is the name of the generic UI component, not the React module! docs Improvements or additions to the documentation regression A bug, but worse
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants