/** * VisualVersionCompare Component * * Side-by-side visual comparison of two Puck page versions with diff highlighting. * Uses Puck's Render component to display actual rendered content. */ import React from 'react'; import type { ComponentDiffWithPosition } from '../../../core/types.js'; /** * Puck Data structure (flexible to accept various sources) */ interface PuckData { content: { type: string; props: Record & { id: string; }; }[]; root: { props?: Record; }; } /** * Puck Config structure (flexible to accept Puck's Config type) * Uses a loose type to accept any Puck config */ type PuckConfig = Record; export interface VisualVersionCompareProps { /** * The before version number. */ beforeVersion: number; /** * The after version number. */ afterVersion: number; /** * The Puck data from the before version. */ beforeData: PuckData; /** * The Puck data from the after version. */ afterData: PuckData; /** * The Puck configuration for rendering components. */ config: PuckConfig; /** * Array of component diffs with position information. */ diffs: ComponentDiffWithPosition[]; /** * Callback when the comparison is closed. */ onClose: () => void; /** * Additional CSS class name. */ className?: string; } /** * Renders a side-by-side visual comparison of two Puck page versions. */ export declare function VisualVersionCompare({ beforeVersion, afterVersion, beforeData, afterData, config, diffs, onClose, className, }: VisualVersionCompareProps): React.ReactElement; export {};