From 17042cebdc0006931b5b835ca6227ba56ee6f946 Mon Sep 17 00:00:00 2001 From: Teppo Kurki Date: Wed, 23 Oct 2024 13:06:17 +0300 Subject: [PATCH] fix: use capture for dragLeave (#20291) --- .../main/resources/META-INF/resources/frontend/dndConnector.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/flow-dnd/src/main/resources/META-INF/resources/frontend/dndConnector.js b/flow-dnd/src/main/resources/META-INF/resources/frontend/dndConnector.js index 3cb3d0387ac..853dec45483 100644 --- a/flow-dnd/src/main/resources/META-INF/resources/frontend/dndConnector.js +++ b/flow-dnd/src/main/resources/META-INF/resources/frontend/dndConnector.js @@ -68,7 +68,7 @@ window.Vaadin.Flow.dndConnector = { if (element['__active']) { element.addEventListener('dragenter', this.__ondragenterListener, false); element.addEventListener('dragover', this.__ondragoverListener, false); - element.addEventListener('dragleave', this.__ondragleaveListener, false); + element.addEventListener('dragleave', this.__ondragleaveListener, true); element.addEventListener('drop', this.__ondropListener, false); } else { element.removeEventListener('dragenter', this.__ondragenterListener, false);