( a: ParsedKeystroke, b: ParsedKeystroke, )
| 105 | * Super (cmd/win) is distinct — only arrives via kitty keyboard protocol. |
| 106 | */ |
| 107 | export 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. |
no outgoing calls
no test coverage detected