From 92b610f69bd796dd37566ed9336ad523178031de Mon Sep 17 00:00:00 2001 From: lubej <9722540+lubej@users.noreply.github.com> Date: Tue, 27 Jun 2023 18:29:01 +0200 Subject: [PATCH] Disable zoom if graph not in explore state --- src/app/pages/HomePage/Graph/ParaTimeSelector/index.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/app/pages/HomePage/Graph/ParaTimeSelector/index.tsx b/src/app/pages/HomePage/Graph/ParaTimeSelector/index.tsx index 24645b506a..18f935ad3c 100644 --- a/src/app/pages/HomePage/Graph/ParaTimeSelector/index.tsx +++ b/src/app/pages/HomePage/Graph/ParaTimeSelector/index.tsx @@ -190,6 +190,10 @@ const ParaTimeSelectorCmp: FC = ({ disabled, step, setSte } const onPinchZoom = ({ x, y, scale }: UpdateAction) => { + if (step !== ParaTimeSelectorStep.Explore) { + return + } + const transformValue = make3dTransformValue({ x, y, scale }) setScale(scale) quickPinchZoomInnerRef.current?.style.setProperty('transform', transformValue)