import type { BackgroundElementTemplateInstance } from '../background/instance.js';
import type { ElementTemplateUpdateCommandStream } from '../protocol/types.js';
export type FormattedElementTemplateUpdateCommand = {
    op: 'createTemplate';
    handleId: number;
    templateKey: string;
    bundleUrl: string | null | undefined;
    attributeSlots: unknown;
    elementSlots: unknown;
} | {
    op: 'setAttribute';
    targetId: number;
    attrSlotIndex: number;
    value: unknown;
} | {
    op: 'insertNode';
    targetId: number;
    elementSlotIndex: number;
    childId: number;
    referenceId: number;
} | {
    op: 'removeNode';
    targetId: number;
    elementSlotIndex: number;
    childId: number;
    removedSubtreeHandleIds: number[];
} | {
    op: 'unknown';
    opcode: unknown;
    index: number;
    remaining: unknown[];
};
export declare function formatElementTemplateUpdateCommands(stream: ElementTemplateUpdateCommandStream | undefined): FormattedElementTemplateUpdateCommand[];
export declare function printElementTemplateTreeToString(root: BackgroundElementTemplateInstance | null | undefined): string;
