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 you click on a custom trigger that launches a Popover, it is treated as a "click outside" and closes the popover, even when the target is passed as a positioning prop.
The root cause is in usePostioning.ts where targetRef and setTarget are not initialized to point to the passed in target.
Component
Popover
Package version
9.59.0
React version
18.2.0
Environment
Current Behavior
When you click on a custom trigger that launches a Popover, it is treated as a "click outside" and closes the popover, even when the target is passed as a positioning prop.
The root cause is in usePostioning.ts where
targetRef
andsetTarget
are not initialized to point to the passed intarget
.I believe the fix is to update these two lines:
Expected Behavior
When passing a
target
to thepositioning
prop to thepopover
component, clicking on the target shouldn't count as clicking outside.Reproduction
https://stackblitz.com/edit/u5pgjqno
Steps to reproduce
Are you reporting an Accessibility issue?
None
Suggested severity
High - No workaround
Products/sites affected
No response
Are you willing to submit a PR to fix?
no
Validations
The text was updated successfully, but these errors were encountered: