import type { KeyEvent, Renderable } from "@opentui/core"; import { type ActiveKey, type ActiveKeyOptions, type Layer, type Keymap, type ReactiveMatcher, type KeySequencePart, type TargetMode } from "../index.js"; import { type DependencyList, type ReactNode } from "react"; type OpenTuiKeymap = Keymap; export interface KeymapProviderProps { keymap: OpenTuiKeymap; children?: ReactNode; } export declare function KeymapProvider({ keymap, children }: KeymapProviderProps): import("react").FunctionComponentElement>; export interface UseBindingsTargetRef { current: TRenderable | null; } export interface UseBindingsLayer extends Omit, "target" | "targetMode"> { targetRef?: UseBindingsTargetRef; targetMode?: TargetMode; } export declare const useKeymap: () => OpenTuiKeymap; export declare const useActiveKeys: (options?: ActiveKeyOptions) => readonly ActiveKey[]; export declare const usePendingSequence: () => readonly KeySequencePart[]; export declare function useBindings(createLayer: () => UseBindingsLayer, deps?: DependencyList): void; /** * Adapts any `subscribe` + `getSnapshot` store to * `ReactiveMatcher`. Pass `predicate` when the snapshot value is not * already boolean. */ export declare function reactiveMatcherFromStore(subscribe: (onStoreChange: () => void) => () => void, getSnapshot: () => T, predicate?: (value: T) => boolean): ReactiveMatcher; export {};