/** * Markdown Status Table Parser and Updater * * Parses and updates status tables in epic markdown bodies. * Supports GitHub issue reference format (org/repo#number or repo#number). */ export interface IssueRef { org?: string; repo: string; number: number; fullRef: string; } export interface StatusTableRow { issueRef: IssueRef; title: string; status: "open" | "closed"; rawLine: string; } export interface StatusTable { rows: StatusTableRow[]; waveId?: string; startLine: number; endLine: number; rawContent: string; } /** * Parse issue reference from markdown table cell * Supports: "lexsona#111", "lex#647", "Guffawaffle/lex#647" */ export declare function parseIssueRef(ref: string): IssueRef | null; /** * Parse status emoji/text from markdown table cell * Supports: "🔵 Open", "✅ Closed", "Open", "Closed" */ export declare function parseStatus(statusCell: string): "open" | "closed" | null; /** * Format status for markdown table cell */ export declare function formatStatus(status: "open" | "closed"): string; /** * Extract all status tables from markdown content */ export declare function extractStatusTables(markdown: string): StatusTable[]; /** * Update status table rows with actual issue states */ export declare function updateTableRows(rows: StatusTableRow[], issueStates: Map): { row: StatusTableRow; updated: boolean; }[]; /** * Replace status table in markdown with updated version */ export declare function replaceStatusTable(markdown: string, table: StatusTable, updatedRows: StatusTableRow[]): string; /** * Update all status tables in markdown with actual issue states */ export declare function updateMarkdownTables(markdown: string, issueStates: Map): { updatedMarkdown: string; changes: Array<{ issueRef: string; was: string; now: string; }>; };