-
-
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
Joy Select : Menu is not opening if you click on the Avatar. #34490
Comments
Thanks for reporting! It's a bug. |
We should re-use the same logic as in the Basic menu demo, by introducing a I noticed the same issue in the introduction demo - https://mui.com/base/react-menu/#introduction We may as well fix this with the same iteration. Would be worth double-checking the other menu demos. I want to emphasize that this would be fixed automatically when we introduce the MenuButton component, but till then we should fix the demos. @ZeeshanTamboli do you want to handle this? |
@mnajdova This issue seems different to me from what you are saying. Here the Joy's select menu is closing after opening, so we want to instead prevent closing of menu automatically if it's opened. Also I couldn't reproduce it on Base's Menu demos you pointed out towards, but rather in Joy's Select demos:
And yes, I will take a look. |
Hi, can I try this one? |
@jesrodri Yes, please go ahead. Thanks! |
Hii, can this issue be assigned to me? I think I know how to fix this bug, Thanks! |
Hi @ZeeshanTamboli I have created PR #34648 with the fix. Could you please take a look when you get some time. Thanks. |
I think we have to weigh the trade-offs between these options:
Which one is a better DX? I'm also open to other solution if it works better for interactive, non-interactive decorators. |
@siriwatknp In current implementation, we are using |
Thanks for your opinion! I will keep this open for a few weeks to see what others think. |
I came up with a workaround solution only for the avatar case, but I agree with @shivam1646! |
Duplicates
Latest version
Steps to reproduce 🕹
Steps:
Current behavior 😯
When clicking on the Option's avatar, the menu opens and closes almost instantly. It works fine if you click elsewhere.
Expected behavior 🤔
The menu should open and should stay open.
Context 🔦
No response
Your environment 🌎
``` System: OS: macOS 12.6 Binaries: Node: 16.13.0 - /usr/local/bin/node Yarn: 1.22.4 - /usr/local/bin/yarn npm: 8.1.0 - /usr/local/bin/npm Browsers: Chrome: 105.0.5195.125 Edge: Not Found Firefox: 90.0.2 Safari: 16.0 ```npx @mui/envinfo
The text was updated successfully, but these errors were encountered: