From 05cab85579da038990f296524fefc21ac9cbb3d1 Mon Sep 17 00:00:00 2001 From: zxhlyh Date: Tue, 30 Apr 2024 13:35:49 +0800 Subject: [PATCH] fix: workflow disable shortcuts when feature panel occured (#4001) --- .../components/workflow/hooks/use-nodes-interactions.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/web/app/components/workflow/hooks/use-nodes-interactions.ts b/web/app/components/workflow/hooks/use-nodes-interactions.ts index 2244bdb43c..d1ae373adf 100644 --- a/web/app/components/workflow/hooks/use-nodes-interactions.ts +++ b/web/app/components/workflow/hooks/use-nodes-interactions.ts @@ -712,9 +712,10 @@ export const useNodesInteractions = () => { const { setClipboardElements, shortcutsDisabled, + showFeaturesPanel, } = workflowStore.getState() - if (shortcutsDisabled) + if (shortcutsDisabled || showFeaturesPanel) return const { @@ -736,9 +737,10 @@ export const useNodesInteractions = () => { const { clipboardElements, shortcutsDisabled, + showFeaturesPanel, } = workflowStore.getState() - if (shortcutsDisabled) + if (shortcutsDisabled || showFeaturesPanel) return const { @@ -803,9 +805,10 @@ export const useNodesInteractions = () => { const { shortcutsDisabled, + showFeaturesPanel, } = workflowStore.getState() - if (shortcutsDisabled) + if (shortcutsDisabled || showFeaturesPanel) return const {