We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 985f9fe commit 0160bdeCopy full SHA for 0160bde
1 file changed
js/moq-boy/src/ui/components/GameCard.tsx
@@ -32,13 +32,13 @@ function GameCardInner() {
32
33
const onKeyDown = (e: KeyboardEvent) => {
34
if (!isActive()) return;
35
- if (e.repeat) return;
36
37
const button = KEY_MAP[e.key];
38
if (button) {
+ e.preventDefault();
39
+ if (e.repeat) return;
40
game.heldButtons.add(button);
41
game.sendButtons();
- e.preventDefault();
42
} else if (e.key === "Escape" && ctx.expanded()) {
43
game.expanded.set(undefined);
44
e.preventDefault();
0 commit comments