Fix float dismiss in click mode.

This commit is contained in:
Madeorsk 2024-07-14 15:15:38 +02:00
parent f146dd9518
commit c2485dfb1a
Signed by: Madeorsk
SSH key fingerprint: SHA256:J9G0ofIOLKf7kyS2IfrMqtMaPdfsk1W02+oGueZzDDU

View file

@ -83,7 +83,7 @@ export const Float = React.forwardRef(({children, content, className, mode, dism
const hover = useHover(context, useMemo(() => ({ enabled: mode == "hover" }), [mode]));
const focus = useFocus(context, useMemo(() => ({ enabled: mode == "focus", visibleOnly: false }), [mode]));
const click = useClick(context, useMemo(() => ({ enabled: mode == "click" }), [mode]));
const dismiss = useDismiss(context, useMemo(() => ({ enabled: !!dismissible }), [dismissible]));
const dismiss = useDismiss(context, useMemo(() => ({ enabled: !!dismissible && mode != "click" }), [dismissible]));
const roleProps = useRole(context, {
role: role,
enabled: !!role,