import { type Observable } from 'rxjs'; import type { LogLevel } from '../../../_exports/index.js'; import type { ConnectReplOptions, ReplSession } from '../session.js'; import { type ReplHandle } from './replStateMachine.js'; export interface InkReplDriverContext { session: ReplSession; repl: ReplHandle; devicePath: string; } export interface InkReplDriverResult { /** Observable to subscribe to for the session's lifetime. Used by `dev` * to keep `createDevSession.state$` alive. */ run$?: Observable; /** Cleanup ran when the component unmounts. */ dispose?: () => void; } export interface InkReplModeProps { devicePath: string; /** Connected device's USB serial, forwarded so the header can show its alias. */ serialNumber?: string; /** Trigger safe-mode after opening the session. Used by * `console --recover` / `deploy --recover`. */ recover?: boolean; logLevel?: LogLevel; /** Per-command work that runs alongside the REPL. When a driver is * supplied, Ctrl+S is wired up (callers typically subscribe to * `repl.deploys$`). Without a driver, the deploy keybind is a no-op. */ driver?: (ctx: InkReplDriverContext) => InkReplDriverResult; /** Forwarded to the rendered `ReplConsole` header badge. Typically set * by `dev` to reflect `--no-watch`. */ watch?: boolean; /** Firmware-version policy for the session connect. FirmwareGate passes * 'best-effort' when the user declined a reflash and chose to continue. */ compat?: ConnectReplOptions['compat']; } /** * Shared Ink-mode orchestrator for `dev`, `console`, and any command * that wants "connect + attach REPL". Opens the serial, brings up a * `ReplSession`, creates a `ReplHandle`, runs the optional `driver` * for the session's lifetime, and renders `InkReplConsole`. */ export declare function InkReplMode(props: InkReplModeProps): import("react/jsx-runtime").JSX.Element; //# sourceMappingURL=InkReplMode.d.ts.map