@cartridge-engine/keyboard-engine
    Preparing search index...

    Interface PendingSequence

    Internal representation of a sequence that is currently being matched.

    Created when the first key of a registered SequenceBinding is pressed and stored on the layer's ScreenKeyboardLayer.pendingSequence. Tracked by a timer that cancels the pending state if the next key does not arrive within timeout milliseconds.

    interface PendingSequence {
        candidates?: BaseSequenceBinding[];
        handler: KeyHandler;
        nextIndex: number;
        options?: SequenceOptions;
        sequences: string[];
        timeout: number;
        timer: Timeout;
        when?: string | (() => boolean);
    }
    Index
    candidates?: BaseSequenceBinding[]

    When multiple sequences share the same first key (non-exclusive mode), stores all eligible BaseSequenceBinding candidates so that subsequent keys can disambiguate. Set to undefined once the pending sequence resolves to a single binding, or in exclusive mode where only the first candidate is kept.

    handler: KeyHandler

    Callback to invoke when the full sequence is matched.

    nextIndex: number

    Index of the next key to match within sequences. Starts at 1 after the first key is consumed.

    options?: SequenceOptions

    Options from the original SequenceBinding.

    sequences: string[]

    The full key sequence to match (copied from SequenceBinding.keys).

    timeout: number

    Timeout duration in milliseconds.

    timer: Timeout

    The timeout timer handle; cleared on match, mismatch, or cancellation.

    when?: string | (() => boolean)

    Optional condition callback (copied from SequenceBinding at start). Checked at each key press; if it returns false, the sequence is cancelled.