fix: menu not hide when click over

This commit is contained in:
QiShaoXuan 2023-02-01 20:48:39 +08:00
parent 57f3cd652a
commit 5261ef960e

View File

@ -152,6 +152,11 @@ export const Popper = ({
onPointerLeave={onPointerLeaveHandler}
style={popoverStyle}
className={popoverClassName}
onClick={() => {
if (hasClickTrigger && !visibleControlledByParent) {
setVisible(false);
}
}}
>
{showArrow && (
// eslint-disable-next-line @typescript-eslint/ban-ts-comment