-
-
Notifications
You must be signed in to change notification settings - Fork 91
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Popover] Disable focus management when opened via hover #855
Conversation
atomiks
commented
Nov 22, 2024
- I have followed (at least) the PR section of the contributing guide.
@@ -69,22 +68,21 @@ export function usePopoverRoot(params: usePopoverRoot.Parameters): usePopoverRoo | |||
(nextOpen: boolean, event?: Event, reason?: OpenChangeReason) => { | |||
onOpenChange(nextOpen, event, reason); | |||
setOpenUnwrapped(nextOpen); | |||
if (!keepMounted && !nextOpen) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to check how setMounted(false)
with this keepMounted
check operates now for the other components with the hidden
prop
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like keepMounted
was never passed to the hooks, hence it worked like keepMounted=false
. I've removed the prop for Popover but it should be done for all components.
Netlify deploy preview |
It feels wrong that the popover closes on mouseout after an input inside it has been focused. Clicking on anything inside the popover should make it sticky |
@michaldudak that's a separate discussion as the previous focus management also worked like this |