import React from "react"; import * as monaco from "monaco-editor/esm/vs/editor/editor.api"; declare type Editor = monaco.editor.IStandaloneCodeEditor; declare type Theme = "vs" | "vs-dark" | "hc-black"; declare type IStandaloneEditorConstructionOptions = monaco.editor.IStandaloneEditorConstructionOptions; declare type IModelDeltaDecoration = monaco.editor.IModelDeltaDecoration; declare type IPosition = monaco.IPosition; declare type Props = { id?: number; model: monaco.editor.ITextModel; onMouseDown?: () => void; onDidChangeCursorPosition?: (e: IPosition) => void; onDidFocusEditorText?: (editor: Editor) => void; onDidChangeModelContent?: () => void; onGutterMouseDown?: (lineNumber?: number) => void; options?: IStandaloneEditorConstructionOptions; }; export declare type MonacoEditorHandle = { focus(): void; setValue(newValue: string): void; setPosition(position: IPosition): void; getValue(): string; setModelLanguage(languageId: string): void; setTheme(newTheme: Theme): void; deltaDecorations(oldDecorations: string[], newDecorations: IModelDeltaDecoration[]): string[]; revealLineInCenter(lineNumber: number): void; undo(): void; redo(): void; }; export declare function createModel(value?: string): monaco.editor.ITextModel; declare const MonacoEditor: React.ForwardRefExoticComponent>; export default MonacoEditor;