From 364111a7fe696b3d20b3c1b618e86d11b201c391 Mon Sep 17 00:00:00 2001 From: moklick Date: Wed, 10 Mar 2021 12:50:54 +0100 Subject: [PATCH] fix(interaction): panemoveable prop on touch devices --- src/container/ZoomPane/index.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/container/ZoomPane/index.tsx b/src/container/ZoomPane/index.tsx index dc3c7dd2..99e72806 100644 --- a/src/container/ZoomPane/index.tsx +++ b/src/container/ZoomPane/index.tsx @@ -234,8 +234,8 @@ const ZoomPane = ({ return false; } - // if the pane is not movable, we prevent dragging it with the mouse - if (!paneMoveable && event.type === 'mousedown') { + // if the pane is not movable, we prevent dragging it with mousestart or touchstart + if (!paneMoveable && (event.type === 'mousedown' || event.type === 'touchstart')) { return false; }