/** * Dependency-free ANSI/SGR (`CSI … m`) parser for rendering streamed console/terminal output as * styled text segments — shared by any component that needs to turn raw ANSI-colored text into * styled segments, rather than re-implementing this per consumer. Handles only SGR color/style * codes; every other CSI final byte and every OSC sequence is stripped and never interpreted. * Cursor/line-buffer control characters (`\r`/`\b`/`\t`/`\n`) are deliberately out of scope here — * they are a terminal-emulation concern owned by the consuming component, not this parser. */ export interface AnsiStyles{bold:boolean;dim:boolean;italic:boolean;underline:boolean;inverse:boolean; /** A CSS color value: `var(--lr-terminal-color-*)` for the 16 named colors (including the * 16-named subset of 256-color mode), or a literal `rgb()` for 256-color indices 16-255 and * truecolor. These colors are driven by arbitrary terminal output content, not the design-token * palette, so a literal CSS color value here is intentional rather than a hardcoded default. */ fg?:string;bg?:string;}export interface AnsiSegment{text:string;styles:AnsiStyles;}export interface AnsiParser{ /** Feeds `chunk` through the parser, returning the styled text segments it produced. A partial * escape sequence at the end of `chunk` is buffered internally and completed by a later `push()` * call rather than emitted as literal text. An unterminated sequence longer than the bounded * carry ceiling is dropped so later output resumes from a clean parser boundary. */ push(chunk:string):AnsiSegment[]; /** Clears style state and any buffered partial sequence — call alongside a full scrollback reset. */ reset():void;}export declare function createAnsiParser():AnsiParser;