From 117b9d0114ca2d21a4d274c9b7423874f8ec7a36 Mon Sep 17 00:00:00 2001 From: jeo young <1414294708@qq.com> Date: Fri, 16 Dec 2022 23:27:02 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E7=A9=BA=E6=A0=BC=E7=83=AD=E9=94=AE?= =?UTF-8?q?=E5=AF=BC=E8=87=B4ctrl=20=E6=97=A0=E6=B3=95=E5=A4=9A=E9=80=89?= =?UTF-8?q?=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/utils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/utils.ts b/src/utils/utils.ts index b587d854..71368a51 100644 --- a/src/utils/utils.ts +++ b/src/utils/utils.ts @@ -281,12 +281,12 @@ export const setKeyboardDressShow = (keyCode?: number) => { const dom = document.getElementById('keyboard-dress-show') if (!dom) return if (!keyCode) { - window.onKeySpacePressHold?.(false) + if (keyCode == 32) window.onKeySpacePressHold?.(false) dom.innerText = '' return } if (keyCode && code.has(keyCode)) { - window.onKeySpacePressHold?.(true) + if (keyCode == 32) window.onKeySpacePressHold?.(true) dom.innerText = `按下了「${code.get(keyCode)}」键` } }