feat: 区分左右两侧的 ShiftCtrlAlt 键 (#83)

This commit is contained in:
yyz
2025-04-24 19:15:06 +08:00
committed by GitHub
parent a3a33628cc
commit 474bc5202a
7 changed files with 1 additions and 1 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.2 KiB

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

View File

@@ -66,7 +66,7 @@ export function useDevice() {
}
const normalizeKeyValue = (key: string) => {
key = key.replace(/(Left|Right|Gr)$/, '').replace(/F(\d+)/, 'Fn')
key = key.replace(/^(Meta).*/, '$1').replace(/F(\d+)/, 'Fn')
const isInvalidArrowKey = key.endsWith('Arrow') && catStore.mode !== 'keyboard'
const isUnsupportedKey = !supportKeys.includes(key)