Skip to content

Commit

Permalink
fixup! add macos keyboard support
Browse files Browse the repository at this point in the history
  • Loading branch information
mzgoddard committed Feb 5, 2024
1 parent 445ab19 commit 04f3a82
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/helpers/macos/parseCodePoints.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,14 @@ exports.parseCodePoints = function (codes) {
} else if (action in KeyCode) {
keyCodes.push(action);
} else {
throw new Error(`unknown action (\\u${code.charCodeAt(0).toString(16)})`);
throw new Error(`unknown action (${code.charCodeAt(0).toString(16)})`);
}
} else if (code in KeyCode) {
keyCodes.push(code);
} else {
} else if (code.length === 1) {
throw new Error(`unknown key (\\u${code.charCodeAt(0).toString(16)})`);
} else {
throw new Error('Invalid key code specified.');
}
}
return keyCodeCommand(keyCodes, modifiers);
Expand Down

0 comments on commit 04f3a82

Please sign in to comment.