fix: 快捷键无法绑定空格

This commit is contained in:
美兰十三 2025-02-10 17:01:16 +08:00 committed by 亢奋猫
parent 04cfe5019e
commit 0eead315d8

View File

@ -113,7 +113,11 @@ const ShortcutSettings: FC = () => {
const key = e.key
if (key.length === 1 && !['Control', 'Alt', 'Shift', 'Meta'].includes(key)) {
keys.push(key.toUpperCase())
if (key === ' ') {
keys.push('Space')
} else {
keys.push(key.toUpperCase())
}
}
if (!isValidShortcut(keys)) {