diff --git a/src/core/client/embed/WindowEvents.ts b/src/core/client/embed/WindowEvents.ts index a1d84ad856e..91e2834ecf5 100644 --- a/src/core/client/embed/WindowEvents.ts +++ b/src/core/client/embed/WindowEvents.ts @@ -1,7 +1,7 @@ import PymControl from "./PymControl"; export default function hookUpWindowEvents(pym: PymControl) { - window.addEventListener("keypress", (e) => { + window.addEventListener("keypress", (e: KeyboardEvent) => { const payload = { event: "keypress", data: { diff --git a/src/core/client/stream/common/KeyboardShortcuts/KeyboardShortcuts.tsx b/src/core/client/stream/common/KeyboardShortcuts/KeyboardShortcuts.tsx index 22160f4247a..c810b0dc79f 100644 --- a/src/core/client/stream/common/KeyboardShortcuts/KeyboardShortcuts.tsx +++ b/src/core/client/stream/common/KeyboardShortcuts/KeyboardShortcuts.tsx @@ -132,7 +132,7 @@ const KeyboardShortcuts: FunctionComponent = () => { }, [findPreviousElement, scrollToElement]); const handleKeyMessage = useCallback( - (e: any) => { + (e) => { try { if (!e.data) { return; @@ -161,7 +161,7 @@ const KeyboardShortcuts: FunctionComponent = () => { ); const handleKeyPress = useCallback( - (e: any) => { + (e: KeyboardEvent) => { try { if (e.shiftKey && e.key === "C") { jumpToPreviousElement();