import { EditorState } from 'draft-js'; import * as React from 'react'; import { AnnotatedText, Annotation } from '../models'; export interface AnnotationEditorAttributes { document: AnnotatedText[]; } export interface AnnotationEditorActions { insert(text: AnnotatedText): any; remove(text: AnnotatedText): any; update(text: AnnotatedText, newText: string): any; tag(text: AnnotatedText, tag: Annotation): any; unTag(text: AnnotatedText, tag: Annotation): any; } export declare type AnnotationEditorProps = AnnotationEditorAttributes & AnnotationEditorActions; export interface AnnotationEditorState { editorState: EditorState; } /** * document editor for annotation */ export declare class AnnotationEditor extends React.Component { constructor(props: AnnotationEditorProps); render(): JSX.Element; private readonly onEditorStateChange; private findNewTexts; }