mirror of
https://github.com/ankitects/anki.git
synced 2025-11-06 12:47:11 -05:00
keyPress -> keypress
This commit is contained in:
parent
e16a49d376
commit
dae91bd1d8
3 changed files with 3 additions and 3 deletions
|
|
@ -59,7 +59,7 @@ addEventListener("message", async (e: MessageEvent<InnerReviewerRequest>) => {
|
||||||
|
|
||||||
addEventListener("keydown", (e) => {
|
addEventListener("keydown", (e) => {
|
||||||
if (e.key.length == 1 && "1234 ".includes(e.key) && !document.activeElement?.matches("#typeans")) {
|
if (e.key.length == 1 && "1234 ".includes(e.key) && !document.activeElement?.matches("#typeans")) {
|
||||||
postParentMessage({ type: "keyPress", key: e.key });
|
postParentMessage({ type: "keypress", key: e.key });
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -56,7 +56,7 @@ export class ReviewerState {
|
||||||
this.currentTypedAnswer = e.data.value;
|
this.currentTypedAnswer = e.data.value;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case "keyPress": {
|
case "keypress": {
|
||||||
this.handleKeyPress(e.data.key);
|
this.handleKeyPress(e.data.key);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ interface UpdateTypedAnswerMessage {
|
||||||
}
|
}
|
||||||
|
|
||||||
interface KeyPressMessage {
|
interface KeyPressMessage {
|
||||||
type: "keyPress";
|
type: "keypress";
|
||||||
key: string;
|
key: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue