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
{{ message }}
Repository navigation
Spam clicking an EuiPopover anchor will cause it to sometimes not close on outside click #8879
If you spam click a button (or any anchor, we had it happen with divs too) with an EuiPopover attached to it, it will sometimes get stuck open. Outside clicks do not close the popover anymore, the only way to close it is by clicking the button again.
I replicated this on multiple of the popovers on the "popover" page of the documentation
Impact and severity
Very Low
Environment and versions
EUI version 106.0.0, but seen on 55.x
To Reproduce
Go to the "How it works" button on the popover documentation page, spam click it. Ensure that when you are done spam-clicking, the popover is not closed. Now, click outside of the popover. The popover will not close. Now, click the "How it works" button one more time. The popover closes.
Note that I can only get it with about 75% success rate.
Expected behavior
The popover always closes on outside clicks if configured to do so.
Thanks @BryceRyan for reporting this!
I can confirm this unexpected behavior. Clicking the popover too fast results in the popover not closing on outside click nor on Escape keypress, only on click of the trigger element.
The internal states for isOpening and isClosing are not exclusive in rapid interactions due to them using timeouts. The code causing this is here.
Activity
mgadewoll commentedon Jul 18, 2025
Thanks @BryceRyan for reporting this!
I can confirm this unexpected behavior. Clicking the popover too fast results in the popover not closing on outside click nor on
Escapekeypress, only on click of the trigger element.The internal states for
isOpeningandisClosingare not exclusive in rapid interactions due to them using timeouts. The code causing this is here.