/** * Reactive annotation state factory. * Follows the createWidgetState() pattern — internal $state variables, * returned object with getters and action methods. */ import type { Annotation, AnnotationTool, Point } from './annotation-types.js'; export interface AnnotationState { readonly tool: AnnotationTool; readonly color: string; readonly strokeWidth: number; readonly fontSize: number; readonly annotations: readonly Annotation[]; readonly activeAnnotation: Annotation | null; readonly textInputPosition: Point | null; readonly textInputValue: string; readonly canUndo: boolean; readonly canRedo: boolean; setTool(tool: AnnotationTool): void; setColor(color: string): void; setStrokeWidth(width: number): void; setFontSize(size: number): void; startBrush(point: Point): void; continueBrush(point: Point): void; commitBrush(): void; startArrow(point: Point): void; updateArrow(end: Point): void; commitArrow(): void; startText(position: Point): void; updateTextInput(value: string): void; commitText(): void; cancelText(): void; undo(): void; redo(): void; clear(): void; } export declare function createAnnotationState(): AnnotationState; //# sourceMappingURL=annotation-state.svelte.d.ts.map