From 21e93814bf86da953680a9d8b10635a438aa8518 Mon Sep 17 00:00:00 2001 From: Nate Date: Tue, 19 Nov 2024 14:33:05 -0800 Subject: [PATCH] remove listener --- gui/src/pages/gui/ToolCallDiv/index.tsx | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/gui/src/pages/gui/ToolCallDiv/index.tsx b/gui/src/pages/gui/ToolCallDiv/index.tsx index c9c242b9d..73b615fbc 100644 --- a/gui/src/pages/gui/ToolCallDiv/index.tsx +++ b/gui/src/pages/gui/ToolCallDiv/index.tsx @@ -114,22 +114,6 @@ export function ToolCallDiv(props: ToolCallDivProps) { } }, [props.toolCall.function.arguments]); - useEffect(() => { - function handleKeyDown(e: KeyboardEvent) { - if (e.key === "Tab") { - e.preventDefault(); - callTool(); - } - if (e.key === "Backspace" && e.metaKey) { - e.preventDefault(); - cancelTool(); - } - } - - window.addEventListener("keydown", handleKeyDown); - return () => window.removeEventListener("keydown", handleKeyDown); - }, []); - async function cancelTool() { setState("canceled"); }