import type { MdBlockExecutionResult, MdTableCell } from './types.js';
export interface MarkdownBlockRenderer {
    canRender(result: MdBlockExecutionResult): boolean;
    render(result: MdBlockExecutionResult): HTMLElement;
}
export declare function setIriLabelSnapshot(snapshot?: ReadonlyMap<string, string> | Record<string, string>): void;
export declare function runWithIriLabelSnapshot<T>(snapshot: ReadonlyMap<string, string> | Record<string, string> | undefined, action: () => T): T;
export declare function displayLabelFromIri(iri: string): string;
export type TableBlockKind = 'table' | 'table-editor' | 'matrix' | 'tree';
export type CanvasBlockKind = 'graph' | 'diagram';
export declare abstract class BaseMarkdownBlockRenderer implements MarkdownBlockRenderer {
    abstract canRender(result: MdBlockExecutionResult): boolean;
    abstract render(result: MdBlockExecutionResult): HTMLElement;
    protected createResultContainer(status: MdBlockExecutionResult['status']): HTMLElement;
    protected createMessageContainer(text: string): HTMLElement;
    protected requestTextFileDownload(content: string, fallbackName?: string, fileExtension?: string): void;
    private buildDownloadFileName;
}
export declare abstract class QueryMarkdownBlockRenderer extends BaseMarkdownBlockRenderer {
    protected renderCellValue(raw: string, typedValue?: MdTableCell): HTMLElement;
    protected formatCellDisplayText(raw: string, typedValue?: MdTableCell): string;
    protected getBlockSource(result: MdBlockExecutionResult): string | undefined;
    protected getBlockMeta(result: MdBlockExecutionResult): string | undefined;
    protected getBlockRange(result: MdBlockExecutionResult): {
        start?: number;
        end?: number;
    };
    private renderValueToken;
}
export declare abstract class CanvasMarkdownBlockRenderer extends QueryMarkdownBlockRenderer {
    protected abstract readonly canvasKinds: ReadonlyArray<CanvasBlockKind>;
    canRender(result: MdBlockExecutionResult): boolean;
    protected renderNotImplemented(result: MdBlockExecutionResult): HTMLElement;
}
