From 734bbc87ce5c0d3447dfa627b422c1461014d122 Mon Sep 17 00:00:00 2001 From: Roo Code Date: Fri, 5 Sep 2025 12:04:00 +0000 Subject: [PATCH] fix: prevent hover events from bleeding through Code Index Config popover - Added explicit pointer-events handling to PopoverContent component - Increased z-index from z-50 to z-[100] for better layering - Added onPointerDownOutside prevention to stop click-through events - Added inline style for pointer-events auto to ensure proper event blocking Fixes #7703 --- webview-ui/src/components/chat/CodeIndexPopover.tsx | 4 +++- webview-ui/src/components/ui/popover.tsx | 5 +++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/webview-ui/src/components/chat/CodeIndexPopover.tsx b/webview-ui/src/components/chat/CodeIndexPopover.tsx index 45bf4224a1..088d878dc6 100644 --- a/webview-ui/src/components/chat/CodeIndexPopover.tsx +++ b/webview-ui/src/components/chat/CodeIndexPopover.tsx @@ -558,7 +558,9 @@ export const CodeIndexPopover: React.FC = ({ sideOffset={5} collisionPadding={16} avoidCollisions={true} - container={portalContainer}> + container={portalContainer} + onPointerDownOutside={(e) => e.preventDefault()} + style={{ pointerEvents: "auto" }}>

{t("settings:codeIndex.title")}

diff --git a/webview-ui/src/components/ui/popover.tsx b/webview-ui/src/components/ui/popover.tsx index acded1d0ad..63809eaf57 100644 --- a/webview-ui/src/components/ui/popover.tsx +++ b/webview-ui/src/components/ui/popover.tsx @@ -13,19 +13,20 @@ const PopoverAnchor = PopoverPrimitive.Anchor const PopoverContent = React.forwardRef< React.ElementRef, React.ComponentPropsWithoutRef & Pick ->(({ className, align = "center", sideOffset = 4, container, ...props }, ref) => ( +>(({ className, align = "center", sideOffset = 4, container, style, ...props }, ref) => (