diff --git a/app/src/protyle/util/compatibility.ts b/app/src/protyle/util/compatibility.ts index 004709522..290d294d5 100644 --- a/app/src/protyle/util/compatibility.ts +++ b/app/src/protyle/util/compatibility.ts @@ -138,12 +138,12 @@ export const updateHotkeyTip = (hotkey: string) => { const keys = []; - if (hotkey.indexOf("⌘") > -1) keys.push(KEY_MAP.get("⌘")); + if ((hotkey.indexOf("⌘") > -1 || hotkey.indexOf("⌃") > -1)) keys.push(KEY_MAP.get("⌘")); if (hotkey.indexOf("⇧") > -1) keys.push(KEY_MAP.get("⇧")); if (hotkey.indexOf("⌥") > -1) keys.push(KEY_MAP.get("⌥")); // 不能去最后一个,需匹配 F2 - const lastKey = hotkey.replace(/⌘|⇧|⌥/g, ""); + const lastKey = hotkey.replace(/⌘|⇧|⌥|⌃/g, ""); if (lastKey) { keys.push(KEY_MAP.get(lastKey) || lastKey); }