mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-22 09:30:14 +01:00
🐛 update Hotkey
This commit is contained in:
parent
7b0326e2a2
commit
fea6cf3a11
1 changed files with 2 additions and 1 deletions
|
|
@ -99,7 +99,8 @@ export const updateHotkeyTip = (hotkey: string) => {
|
||||||
if (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("⌥"));
|
if (hotkey.indexOf("⌥") > -1) keys.push(KEY_MAP.get("⌥"));
|
||||||
|
|
||||||
const lastKey = hotkey.charAt(hotkey.length - 1);
|
// 不能去最后一个,需匹配 F2
|
||||||
|
const lastKey = hotkey.replace(/⌘|⇧|⌥/g, "");
|
||||||
if ("⌘⇧⌥".indexOf(lastKey) < 0) {
|
if ("⌘⇧⌥".indexOf(lastKey) < 0) {
|
||||||
keys.push(
|
keys.push(
|
||||||
KEY_MAP.get(lastKey)
|
KEY_MAP.get(lastKey)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue