From 09e7913d754eda8ebf3deaa5de09849c0f907262 Mon Sep 17 00:00:00 2001 From: hamed musallam Date: Wed, 27 Sep 2023 15:43:57 +0200 Subject: [PATCH] feat: touch with two fingers to close the splitte --- src/components/split-pane/SplitPane.tsx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/components/split-pane/SplitPane.tsx b/src/components/split-pane/SplitPane.tsx index 012b6f3f..06b25ec0 100644 --- a/src/components/split-pane/SplitPane.tsx +++ b/src/components/split-pane/SplitPane.tsx @@ -210,12 +210,19 @@ function Splitter(props: SplitterProps) { isFinalClosed, splitterRef, } = props; + + function handleTouch(event: React.TouchEvent) { + if (event.targetTouches.length === 2) { + onDoubleClick(); + } + } return (
{direction === 'horizontal' ? : }