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

Multiple dropdown menus (with trigger=context) remain open #43202

Closed
manivsh opened this issue Jun 26, 2023 · 3 comments · Fixed by react-component/trigger#407
Closed

Multiple dropdown menus (with trigger=context) remain open #43202

manivsh opened this issue Jun 26, 2023 · 3 comments · Fixed by react-component/trigger#407
Labels
🐛 Bug Ant Design Team had proved that this is a bug.

Comments

@manivsh
Copy link

manivsh commented Jun 26, 2023

Reproduction link

Edit on CodeSandbox

Steps to reproduce

when using dropdown as right-click menu for multiple elements.
with un-controlled open status, the open status is contextual only for the single element, resulting in multiple drop-down menus open at once.

the trigger must be "contextMenu".

What is expected?

On open of a different dropdown, all other menus should autoclose.

What is actually happening?

multiple dropdowns remain open.

Environment Info
antd 5.6.3
React 18.x
System windows 10
Browser latest chrome/edge

In [email protected] the behavior was as expected.

@zombieJ zombieJ added 🐛 Bug Ant Design Team had proved that this is a bug. and removed unconfirmed labels Jun 27, 2023
@MadCcc
Copy link
Member

MadCcc commented Jun 27, 2023

Seems to be related with trigger update. Dropdown with legacy rc-trigger acts good: https://codesandbox.io/s/antd-reproduction-template-forked-xvwf94

@linxianxi
Copy link
Contributor

这两个有点像 #43093

@MadCcc
Copy link
Member

MadCcc commented Jun 28, 2023

这两个有点像 #43093

应该不是同一个问题,trigger 不同

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 Bug Ant Design Team had proved that this is a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants