import type { CellStyle } from "./types.js"; export interface StyledSegment { text: string; style: CellStyle; } export interface StyledLine { segments: StyledSegment[]; } export declare function hasAnsi(text: string): boolean; /** * Parse a block of text that may contain ANSI SGR escape codes into a sequence of * logical lines split on "\n". Each line is a list of styled segments: contiguous * printable runs of characters sharing the same style. * * Common cursor-affecting line controls are rendered into their visible result. * `baseStyle` is used as the initial style and as the restore target for SGR reset / default color. */ export declare function parseAnsi(text: string, baseStyle?: CellStyle): StyledLine[];