refine popover close timing

This commit is contained in:
k00b 2024-09-02 18:25:02 -05:00
parent 67799a508a
commit 69916117b1
1 changed files with 2 additions and 3 deletions

View File

@ -13,7 +13,7 @@ export default function HoverablePopover ({ trigger, body, onShow }) {
onShow?.()
timeoutId.current = setTimeout(() => setShow(true), 500)
} else {
timeoutId.current = setTimeout(() => setShow(!!popRef.current?.matches(':hover')), 500)
timeoutId.current = setTimeout(() => setShow(!!popRef.current?.matches(':hover')), 300)
}
}
@ -23,8 +23,7 @@ export default function HoverablePopover ({ trigger, body, onShow }) {
trigger={['hover', 'focus']}
show={show}
onToggle={onToggle}
delay={1}
transition={false}
transition
rootClose
overlay={
<Popover style={{ position: 'fixed' }} onPointerLeave={() => onToggle(false)}>