Skip to content

@jsvision/web / KeyReclaimOptions

Interface: KeyReclaimOptions

Defined in: key-reclaim.ts:38

Options for attachKeyReclaim.

Properties

also?

readonly optional also?: readonly string[]

Defined in: key-reclaim.ts:40

Extra chords to reclaim beyond the defaults (e.g. 'Ctrl+X'), or ['*'] to reclaim every chord.


isFocused?

readonly optional isFocused?: () => boolean

Defined in: key-reclaim.ts:45

Predicate for "is the terminal focused". Defaults to a DOM check for a focused xterm textarea; a headless terminal has none, so headless runs and tests inject this predicate.

Returns

boolean


target?

readonly optional target?: KeyEventTarget

Defined in: key-reclaim.ts:50

The event target to attach the capture-phase listener to. Defaults to the global document; a test injects a hand-mocked target (the repo avoids a jsdom devDependency).