import React from "react"; import { StyledProps } from "../_type"; declare type Obj = Record; export interface MonacoDiffEditorProps extends StyledProps { /** * [monaco-editor](https://microsoft.github.io/monaco-editor/index.html) * * @docType typeof monaco */ monaco: M; /** * 原始文本 */ original: string; /** * 编辑器高度 * * @default "100%" */ height?: React.CSSProperties["height"]; /** * 编辑器宽度 * * @default "100%" */ width?: React.CSSProperties["width"]; /** * 编辑器初始语言 */ language?: string; /** * 编辑器初始设置,详见 [IDiffEditorConstructionOptions](https://microsoft.github.io/monaco-editor/api/interfaces/monaco.editor.IDiffEditorConstructionOptions.html) * * @docType monaco.editor.IDiffEditorConstructionOptions */ options?: Parameters[1]; /** * override language service, like editorService, [storageService](https://github.com/microsoft/vscode/blob/ff1e16eebb93af79fd6d7af1356c4003a120c563/src/vs/platform/storage/common/storage.ts#L37) ,详见 [IEditorOverrideServices](https://microsoft.github.io/monaco-editor/api/interfaces/monaco.editor.IEditorOverrideServices.html) * * @docType monaco.editor.IEditorOverrideServices * @since 2.7.4 */ override?: Parameters[2]; /** * 默认变更文本 */ defaultValue?: string; /** * 变更文本 */ value?: string; /** * 变更文本变化回调 */ onChange?: (value: string, context: { event: any; }) => void; } export declare const MonacoDiffEditor: (>(props: MonacoDiffEditorProps & { ref?: React.Ref<{ editor: ReturnType; }>; }) => React.ReactElement) & { displayName: string; }; export {};