Popover components (dropdown menu, combobox, etc) don't always close on outside click · Issue #1259 · melt-ui/melt-ui · GitHub
More Web Proxy on the site http://driver.im/
You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a popper component is open and an outside button is clicked, there are scenarios where the popper stays open. I've been trying to narrow down what causes the issue, and it seems to be related to the conditional rendering of the button being clicked.
I've noticed it also happens in certain scenarios when clicking another Melt control. In my sample below, you can see this when clicking the Combo Box and then the Dropdown Menu.
Reproduction
Expand a popper control
While it's open, click on a button somewhere else on the page
a. This button must then trigger some change to the state, which then causes said button to be removed from the DOM
This happens for me as well, but specifically when clicking a canvas while the combobox is open. If I click a different non-canvas div it closes as expected. When I click the canvas the input field is losing focus so it's definitely recording the click happened, just not closing the dropdown.
Describe the bug
When a popper component is open and an outside button is clicked, there are scenarios where the popper stays open. I've been trying to narrow down what causes the issue, and it seems to be related to the conditional rendering of the button being clicked.
I've noticed it also happens in certain scenarios when clicking another Melt control. In my sample below, you can see this when clicking the Combo Box and then the Dropdown Menu.
Reproduction
a. This button must then trigger some change to the state, which then causes said button to be removed from the DOM
I've put together a sample demonstrating the problem here: https://www.sveltelab.dev/gsi5tthvo4231ts
(Note: It can take a few seconds before the components become responsive in this Sveltelab)
Logs
No response
System Info
Severity
annoyance
The text was updated successfully, but these errors were encountered: