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

Function keystrokesEqual

src/keybindings/resolver.ts:107–118  ·  view source on GitHub ↗
(
  a: ParsedKeystroke,
  b: ParsedKeystroke,
)

Source from the content-addressed store, hash-verified

105 * Super (cmd/win) is distinct — only arrives via kitty keyboard protocol.
106 */
107export function keystrokesEqual(
108 a: ParsedKeystroke,
109 b: ParsedKeystroke,
110): boolean {
111 return (
112 a.key === b.key &&
113 a.ctrl === b.ctrl &&
114 a.shift === b.shift &&
115 (a.alt || a.meta) === (b.alt || b.meta) &&
116 a.super === b.super
117 )
118}
119
120/**
121 * Check if a chord prefix matches the beginning of a binding's chord.

Callers 3

chordPrefixMatchesFunction · 0.85
chordExactlyMatchesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected