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
Add useCapture param to useClickOutside hook #9213
I have verified that I use latest version of all @mantine/* packages
What version of @mantine/* packages do you have in package.json?
9.6.2
What package has an issue?
@mantine/hooks
What framework do you use?
Vite
In which browsers you can reproduce the issue?
None
Describe the bug
useClickOutside always listens on the document in the bubble
phase. When a child component stops the event in the capture
phase, the hook doesn't fire at all.
If possible, include a link to a codesandbox with a minimal reproduction
No response
Possible fix
Add an optional useCapture parameter (default false) that is
passed to addEventListener / removeEventListener, so callers
can opt into the capture phase.
Self-service
I would be willing to implement a fix for this issue
Activity
Jubayeromi commentedon Sep 25, 2026
#9213
i would like to work on this.
[@mantine/hooks] use-click-outside: Add capture phase support (#9213)
github-actions commentedon Sep 26, 2026
Fixed in 9.6.3