MCPcopy Create free account
hub / github.com/continuedev/continue / handleKeyDown

Function handleKeyDown

gui/src/components/Layout.tsx:173–182  ·  view source on GitHub ↗
(event: any)

Source from the content-addressed store, hash-verified

171
172 useEffect(() => {
173 const handleKeyDown = (event: any) => {
174 if (isMetaEquivalentKeyPressed(event) && event.code === "KeyC") {
175 const selection = window.getSelection()?.toString();
176 if (selection) {
177 setTimeout(() => {
178 void navigator.clipboard.writeText(selection);
179 }, 100);
180 }
181 }
182 };
183
184 window.addEventListener("keydown", handleKeyDown);
185

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected