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

[Drawer] Allow clicks under closed persistent Drawer #30015

Conversation

gla3dr
Copy link

@gla3dr gla3dr commented Dec 2, 2021

Stops right-anchored persistent drawers from intercepting the mouse when
they are closed.

Tested fix in docs:

persistent-drawer-bug-fixed.mp4

Fixes #29997

Stops right-anchored persistent drawers from intercepting the mouse when
they are closed.
@mnajdova
Copy link
Member

mnajdova commented Dec 3, 2021

As I was the one suggesting the changes, I would wait someone else to review the PR :)

@mnajdova mnajdova requested a review from a team December 3, 2021 09:23
@mnajdova mnajdova added bug 🐛 Something doesn't work component: drawer This is the name of the generic UI component, not the React module! labels Dec 3, 2021
Copy link
Member

@michaldudak michaldudak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This solution looks ok to me.

Side note:
It's a bit weird that the Drawer renders a wide element even when it's closed. Perhaps we can change it to collapse entirely in the future, so the problem solved by this PR would not exist at all (this would be a breaking change, though).

@mnajdova
Copy link
Member

mnajdova commented Dec 3, 2021

this would be a breaking change, though

This was my biggest worry, but I agree. Should we add it to our v6 milestone?

@mui-pr-bot
Copy link

mui-pr-bot commented Dec 6, 2021

Details of bundle changes

@material-ui/core: parsed: +Infinity% , gzip: +Infinity%
@material-ui/lab: parsed: +Infinity% , gzip: +Infinity%
@material-ui/styles: parsed: +Infinity% , gzip: +Infinity%
@material-ui/private-theming: parsed: +Infinity% , gzip: +Infinity%
@material-ui/system: parsed: +Infinity% , gzip: +Infinity%
@material-ui/unstyled: parsed: +Infinity% , gzip: +Infinity%
@material-ui/utils: parsed: +Infinity% , gzip: +Infinity%

Generated by 🚫 dangerJS against ba5d81f

Copy link
Member

@mnajdova mnajdova left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are broken screenshot tests, looks like this is not the most ideal solution to the problem. We will need to investigate more and see what would be the best fix for it.

@mnajdova
Copy link
Member

I am closing the PR, we can re-start the effort once we find a better solution to the problem

@mnajdova mnajdova closed this Mar 23, 2022
@gla3dr gla3dr deleted the right-persistent-drawer-intercept-clicks-while-closed branch April 27, 2022 17:29
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: drawer This is the name of the generic UI component, not the React module!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[docs][Drawer] Right-anchored persistent drawer intercepts click while closed
4 participants