react-pdf-ner-annotator
Version:
A React component to annotate named entities directly onto a PDF.
12 lines (11 loc) • 610 B
TypeScript
import { Annotation, AnnotationParams } from '../interfaces/annotation';
declare const useAnnotations: (defaultAnnotations: Array<Annotation>, readonly: boolean, shouldUpdateDefaultAnnotations: boolean) => {
annotations: Annotation[];
getAnnotationsForPage: (page: number) => Array<Annotation>;
addAnnotation: (annotation: AnnotationParams) => void;
updateAnnotation: (annotation: Annotation) => void;
updateLastAnnotationForEntity: (annotation: AnnotationParams) => void;
removeAnnotation: (id: number) => void;
lastActionHash: string;
};
export default useAnnotations;