import { EditorState, Transaction } from "@tiptap/pm/state"; import { DecorationSet } from "@tiptap/pm/view"; import { AddAnnotationAction, RenderStyles, UpdateAnnotationAction } from "../annotation-magic"; import { Annotation } from "../../contracts"; interface AnnotationStateOptions { styles: RenderStyles; map: Map>; instance: string; onAnnotationListChange: (items: Annotation[]) => void; onSelectionChange: (items: Annotation[]) => void; } export declare class AnnotationState { options: AnnotationStateOptions; decorations: DecorationSet; constructor(options: AnnotationStateOptions); randomId(): string; addAnnotation(action: AddAnnotationAction): void; updateAnnotation(action: UpdateAnnotationAction): void; deleteAnnotation(id: string): void; termsAt(position: number, to?: number): Annotation[]; allAnnotations(): Annotation[]; createDecorations(state: EditorState): void; apply(transaction: Transaction, state: EditorState): this; } export {};