import type { PhrasingContent, Root } from 'mdast'; /** * Injects a Markdown segment under a specified heading in a Markdown document. * Optionally, the injected segment can be made foldable for better readability. * @param document The original Markdown document. * @param segment The Markdown segment to be injected. * @param heading The heading under which the segment is to be injected. * @param foldable If true, makes the segment foldable. * @returns The modified Markdown document. */ export declare function injectMarkdown(document: string, segment: string, heading: string, foldable?: boolean): string; /** * Updates the Table of Contents (TOC) of a Markdown document. * The TOC is rebuilt based on the headings present in the document. * @param main The main Markdown document. * @param heading The heading under which the TOC is to be updated. * @returns The Markdown document with an updated TOC. */ export declare function updateTOC(main: string, heading: string): string; /** * Converts a PhrasingContent node to its HTML representation. * Handles all PhrasingContent types defined in mdast. * * @param node The phrasing content node to convert. * @returns The HTML string representation. * @throws {VrtError} For reference types that require resolution (footnote, image, link references). */ export declare function nodeToHtml(node: PhrasingContent): string; export declare function parseMarkdown(document: string): Root;