import type { FullItem, ItemDescriptor } from "../pageModel";
export type RenderedField = {
    descriptor: {
        item: ItemDescriptor;
        fieldId: string;
    };
    currentText: string;
};
export type DiffTarget = RenderedField & {
    baselineText: string;
    hasDeletionOnlyChange: boolean;
    ranges: Array<[number, number]>;
};
export type ComponentDiffTarget = {
    id: string;
    visualId: string;
    dataItemId?: string | null;
    dataTypeId?: string | null;
    dataLayoutId?: string | null;
    dataPlaceholderKey?: string | null;
    providerPlaceholder?: string;
    providerRenderingItemId?: string;
};
type BaselineMode = {
    type: "compare";
    compareTo?: ItemDescriptor;
} | {
    type: "previous";
};
export type VersionDiffTargetsResult = {
    fieldTargets: DiffTarget[];
    componentTargets: ComponentDiffTarget[];
};
export declare function resolveVersionDiffTargets({ iframe, pageItem, getItem, baseline, previousVersionCache, }: {
    iframe: HTMLIFrameElement;
    pageItem: ItemDescriptor;
    getItem: (descriptor: ItemDescriptor) => Promise<FullItem | undefined>;
    baseline: BaselineMode;
    previousVersionCache: Map<string, number | null>;
}): Promise<VersionDiffTargetsResult>;
export declare function findFieldElements(iframe: HTMLIFrameElement, descriptor: RenderedField["descriptor"]): HTMLElement[];
export declare function getTextNodeAtOffset(root: Element, offset: number): {
    node: Text;
    offset: number;
} | null;
export declare function findComponentRectById(iframe: HTMLIFrameElement, componentId: string): DOMRect | null;
export declare function fieldKey(descriptor: RenderedField["descriptor"]): string;
export {};
