import type { JournalEntry } from './types.mts'; import { type AuditRender } from './audit-fit.mts'; import { type AuditRedactor } from './text.mts'; /** Returns the paste-safe block, or null when the markdown is not exactly one conforming block. */ export declare function matchAuditBlock(markdown: string, patterns: readonly RegExp[], prefixes: readonly string[], render: AuditRender & { shrinkOrder: readonly number[]; }): string | null; /** What counts as an audit block that failed to parse, and how to report that many of them. */ export type UnparsedReport = { marker: RegExp; note: (count: number) => string; }; /** How many blocks in the entries conform to the grammar `match` checks. */ export declare function countConformingBlocks(entries: Iterable, match: (markdown: string, render: AuditRender) => string | null): number; /** * Matches every journal block whole while together they fit `totalBudgetBytes`. Otherwise it keeps * the leading blocks that fit an equal share of the total and appends `omission(count)` — itself a * conforming block — so dropped groups are always reported, never silent. Blocks that name an * audit type but do not match the grammar are counted and reported by `unparsed`, never ignored. */ export declare function conformingBlocks(entries: Iterable, match: (markdown: string, render: AuditRender) => string | null, totalBudgetBytes: number, redact: AuditRedactor | undefined, omission: (count: number) => string, unparsed?: UnparsedReport): string[];