import type { BlendMode, LayerId } from "./layers"; /** * Strongly-typed identifier for persistent canvas documents. */ export type DocumentId = string; /** * The current document schema version. */ export declare const CURRENT_DOCUMENT_VERSION = 1; export type BitmapFormat = "png" | "jpeg" | "webp"; export interface SerializedLayer { id: LayerId; name: string; visible: boolean; opacity: number; blendMode: BlendMode; alphaLock?: boolean; locked?: boolean; dataUrl: string; } export interface FuderuDocument { id?: DocumentId; version: number; width: number; height: number; layers: SerializedLayer[]; activeLayerId?: LayerId; } export interface ExportDocumentOptions { bitmap?: BitmapFormat; quality?: number; } export interface ExportPNGOptions { includeBackground?: boolean; quality?: number; } /** * Pipeline that validates and migrates any document schema version * forward to CURRENT_DOCUMENT_VERSION. */ export declare function migrateDocument(rawDoc: unknown): FuderuDocument; //# sourceMappingURL=document.d.ts.map