export interface EarlyInputState { text: string; submissions: string[]; pendingEscape?: string; } export interface EarlyInputSnapshot { text: string; submissions: string[]; } export interface EarlyInputCapture { consume(): EarlyInputSnapshot; } interface EarlyInputStream { isTTY?: boolean; isRaw?: boolean; setRawMode?(mode: boolean): void; setEncoding?(encoding: BufferEncoding): void; resume(): void; on(event: "data", listener: (chunk: Buffer | string) => void): void; off?(event: "data", listener: (chunk: Buffer | string) => void): void; removeListener(event: "data", listener: (chunk: Buffer | string) => void): void; } type EarlyInputProcessEvent = "exit" | "SIGINT" | "SIGTERM" | "SIGHUP" | "uncaughtException"; type EarlyInputProcessListener = (error?: Error) => void; interface EarlyInputProcess { pid: number; platform: NodeJS.Platform; on(event: EarlyInputProcessEvent, listener: EarlyInputProcessListener): void; off?(event: EarlyInputProcessEvent, listener: EarlyInputProcessListener): void; removeListener(event: EarlyInputProcessEvent, listener: EarlyInputProcessListener): void; kill(pid: number, signal: NodeJS.Signals): void; } export interface StartEarlyInputCaptureOptions { enabled: boolean; stdin?: EarlyInputStream; process?: EarlyInputProcess; } export declare function applyEarlyInputChunk(state: EarlyInputState, chunk: string): void; export declare function startEarlyInputCapture(options: StartEarlyInputCaptureOptions): EarlyInputCapture | undefined; export {}; //# sourceMappingURL=main-early-input.d.ts.map