import type { ReactElement } from 'react';
export interface Color {
    r: number;
    g: number;
    b: number;
    a: number;
}
export interface EdgeValues<T> {
    top: T;
    right: T;
    bottom: T;
    left: T;
}
export interface CornerValues {
    top_left: number;
    top_right: number;
    bottom_right: number;
    bottom_left: number;
}
export interface ElementStyleInfo {
    margin: EdgeValues<number>;
    padding: EdgeValues<number>;
    borderWidth: EdgeValues<number>;
    flexDirection: string;
    justifyContent: string;
    alignItems: string;
    flexWrap: string;
    gap: number;
    fontFamily: string;
    fontSize: number;
    fontWeight: number;
    fontStyle: string;
    lineHeight: number;
    textAlign: string;
    color: Color;
    backgroundColor: Color | null;
    borderColor: EdgeValues<Color>;
    borderRadius: CornerValues;
    opacity: number;
}
export interface ElementInfo {
    x: number;
    y: number;
    width: number;
    height: number;
    kind: string;
    nodeType: string;
    style: ElementStyleInfo;
    children: ElementInfo[];
    sourceLocation?: {
        file: string;
        line: number;
        column: number;
    };
    textContent?: string;
}
export interface PageInfo {
    width: number;
    height: number;
    contentX: number;
    contentY: number;
    contentWidth: number;
    contentHeight: number;
    elements: ElementInfo[];
}
export interface LayoutInfo {
    pages: PageInfo[];
}
export interface RenderWithLayoutResult {
    pdf: Uint8Array;
    layout: LayoutInfo;
}
export declare function renderPdf(json: string): Promise<Uint8Array>;
export declare function renderPdfWithLayout(json: string): Promise<RenderWithLayoutResult>;
export interface RenderDocumentOptions {
    /** Data to embed as a hidden JSON attachment in the PDF. */
    embedData?: unknown;
}
export declare function renderDocument(element: ReactElement, options?: RenderDocumentOptions): Promise<Uint8Array>;
export declare function renderDocumentWithLayout(element: ReactElement, options?: RenderDocumentOptions): Promise<RenderWithLayoutResult>;
export declare function renderTemplate(templateJson: string, dataJson: string): Promise<Uint8Array>;
export declare function renderTemplateWithLayout(templateJson: string, dataJson: string): Promise<RenderWithLayoutResult>;
export { extractData } from './extract.js';
