Close always on blur

This commit is contained in:
Adria Navarro 2025-02-10 16:47:49 +01:00
parent 18b296a850
commit 12ae35c16d
1 changed files with 3 additions and 5 deletions

View File

@ -93,11 +93,9 @@ const handleMouseDown = (e: MouseEvent) => {
// Handle iframe clicks by detecting a loss of focus on the main window // Handle iframe clicks by detecting a loss of focus on the main window
const handleBlur = () => { const handleBlur = () => {
if (document.activeElement?.tagName === "IFRAME") { handleClick(
handleClick( new MouseEvent("click", { relatedTarget: document.activeElement })
new MouseEvent("click", { relatedTarget: document.activeElement }) )
)
}
} }
// Global singleton listeners for our events // Global singleton listeners for our events