/** * remark: render a single newline inside prose as a line break. * * CommonMark folds a lone line ending inside a paragraph into a space, so an * agent writing `1\n2\n3` shows "1 2 3". Chat surfaces (ChatGPT, GitHub * comments) keep the line, which is what message authors expect. This plugin * turns every line ending inside an mdast `text` node into a `break` node — the * same result as `remark-breaks` — while leaving code (`code` / `inlineCode` * carry `value`, not `text` children), raw HTML, and block structure (lists, * tables, blockquotes, headings, blank-line paragraphs) untouched. * * Unlike `remark-breaks` (built on `mdast-util-find-and-replace`, which drops * positions on the split nodes), every split text node keeps a source position. * Streaming tip ink (`rehypeStreamReveal`) keys fade-in on those offsets, so a * positionless line would render without ink and snap in at the stream tail. * * Structural local types keep the module dependency-free, like * `stream-reveal.ts`; the renderer casts once at the plugin seam. */ type MdPoint = { line?: number | undefined; column?: number | undefined; offset?: number | undefined; }; type MdPosition = { start?: MdPoint | undefined; end?: MdPoint | undefined; }; type MdNode = { type: string; value?: string | undefined; position?: MdPosition | undefined; children?: MdNode[] | undefined; }; export declare function remarkSoftLineBreaks(): (tree: MdNode, file?: { value?: unknown; } | undefined) => void; export {};