From e29704e89b8017ced7f76a640b740240f3792846 Mon Sep 17 00:00:00 2001 From: baiqi Date: Wed, 18 Sep 2024 17:39:26 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E8=84=91=E5=9B=BE):=20=E5=8A=9F=E8=83=BD?= =?UTF-8?q?=E7=94=A8=E4=BE=8B=E8=84=91=E5=9B=BE=E5=A4=8D=E5=88=B6=E5=BF=AB?= =?UTF-8?q?=E6=8D=B7=E9=94=AE=E4=B8=8E=E5=88=9B=E5=BB=BA=E5=90=8C=E7=BA=A7?= =?UTF-8?q?=E7=94=A8=E4=BE=8B=E9=94=AE=E5=86=B2=E7=AA=81=E8=A7=A3=E5=86=B3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/pure/ms-minder-editor/hooks/useShortCut.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/frontend/src/components/pure/ms-minder-editor/hooks/useShortCut.ts b/frontend/src/components/pure/ms-minder-editor/hooks/useShortCut.ts index 09e6ef4a57..dbff8fb0f8 100644 --- a/frontend/src/components/pure/ms-minder-editor/hooks/useShortCut.ts +++ b/frontend/src/components/pure/ms-minder-editor/hooks/useShortCut.ts @@ -77,9 +77,11 @@ export default function useShortCut(shortcuts: Shortcuts, options: MinderOperati let action; - if (isCtrlOrCmd && combinationShortcuts[key]) { + if (isCtrlOrCmd) { // 执行组合键事件 - action = combinationShortcuts[key]; + if (combinationShortcuts[key]) { + action = combinationShortcuts[key]; + } } else if (isShift && shiftCombinationShortcuts[key]) { // 执行 shift 组合键事件 action = shiftCombinationShortcuts[key];