MCPcopy Index your code
hub / github.com/codeaashu/claude-code / isTypingTarget

Function isTypingTarget

web/hooks/useKeyboardShortcuts.ts:12–17  ·  view source on GitHub ↗
(el: EventTarget | null)

Source from the content-addressed store, hash-verified

10const INPUT_TAGS = new Set(["INPUT", "TEXTAREA", "SELECT"]);
11
12function isTypingTarget(el: EventTarget | null): boolean {
13 if (!(el instanceof HTMLElement)) return false;
14 if (INPUT_TAGS.has(el.tagName)) return true;
15 if (el.isContentEditable) return true;
16 return false;
17}
18
19/**
20 * Attaches a global keydown listener that fires registered commands.

Callers 1

handlerFunction · 0.85

Calls 1

hasMethod · 0.45

Tested by

no test coverage detected