floating-ui: FloatingFocusManager does not honor outsidePointerDown from useDismiss

In some scenarios I’d like to not close my popover on outside click, but would still like to use FloatingFocusManager for other focus handling. It seemed like disabling outsidePointerDown in useDismiss should work for this as well, but no such luck - looks like the focusout event fires on outside click as well.

Sandbox: (forked from the official non-modal dialog example) https://codesandbox.io/s/laughing-resonance-n8xxnn?file=/src/Popover.tsx:1028-1046

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 20 (10 by maintainers)

Most upvoted comments

Btw your example can be fixed by using FloatingTree. It will know the tooltip is a child of the popover even though it’s portalled outside of it: https://codesandbox.io/s/happy-brahmagupta-si6nen?file=/src/Popover.tsx

That said, I can add something like closeOnFocusOut: boolean if it’s really needed.