From ce9a1e2f3838f90e00524648d7530f69095eda9c Mon Sep 17 00:00:00 2001 From: Lyoko <519052532@qq.com> Date: Sat, 7 May 2022 17:06:23 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=9C=B0=E5=9B=BE=E6=8B=96=E6=8B=BD?= =?UTF-8?q?=E5=86=92=E6=B3=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/utils/fix.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/packages/utils/fix.ts b/packages/utils/fix.ts index 900b73af..44b0053f 100644 --- a/packages/utils/fix.ts +++ b/packages/utils/fix.ts @@ -10,6 +10,13 @@ export function fixMapPropagation(map: T.Map | null) { map?.disableDoubleClickZoom(); setTimeout(() => map?.enableDoubleClickZoom(), 300); } + }, + mousemove: (e: Event) => { + e.stopPropagation(); + if (map?.isDrag()) { + map?.disableDrag(); + setTimeout(() => map?.enableDrag(), 300); + } } }; }