From 0675c5f71614fc9498c18be38e28a0b194a1901c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=9D=9E=E6=B3=95=E6=93=8D=E4=BD=9C?= Date: Tue, 30 Jul 2024 16:18:58 +0800 Subject: [PATCH] chore: add shortcut keys and hints for the shortcuts (#6779) --- web/app/components/workflow/header/undo-redo.tsx | 4 ++-- web/app/components/workflow/operator/control.tsx | 13 +++++++++---- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/web/app/components/workflow/header/undo-redo.tsx b/web/app/components/workflow/header/undo-redo.tsx index bd27e09173..796038ce98 100644 --- a/web/app/components/workflow/header/undo-redo.tsx +++ b/web/app/components/workflow/header/undo-redo.tsx @@ -30,7 +30,7 @@ const UndoRedo: FC = ({ handleUndo, handleRedo }) => { return (
- +
= ({ handleUndo, handleRedo }) => {
- +
{ handleLayout() } + useKeyPress(`${getKeyboardKeyCodeBySystem('ctrl')}.o`, (e) => { + e.preventDefault() + goLayout() + }, { exactMatch: true, useCapture: true }) + const addNote = (e: MouseEvent) => { if (getNodesReadOnly()) return @@ -101,7 +106,7 @@ const Control = () => {
- +
{
- +
{
- +