MCPcopy
hub / github.com/codeaashu/claude-code / isBareEscape

Function isBareEscape

src/utils/computerUse/executor.ts:97–101  ·  view source on GitHub ↗

* Single-element key sequence matching "escape" or "esc" (case-insensitive). * Used to hole-punch the CGEventTap abort for model-synthesized Escape — enigo * accepts both spellings, so the tap must too.

(parts: readonly string[])

Source from the content-addressed store, hash-verified

95 * accepts both spellings, so the tap must too.
96 */
97function isBareEscape(parts: readonly string[]): boolean {
98 if (parts.length !== 1) return false
99 const lower = parts[0]!.toLowerCase()
100 return lower === 'escape' || lower === 'esc'
101}
102
103/**
104 * Instant move, then 50ms — an input→HID→AppKit→NSEvent round-trip before the

Callers 2

keyFunction · 0.85
holdKeyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected