File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ import {
1818 TYPES ,
1919} from "@hylimo/diagram-ui" ;
2020import { Box } from "@mui/material" ;
21- import type * as monaco from "monaco-editor" ;
2221import {
2322 EditorApp ,
2423 type EditorAppConfig ,
@@ -68,10 +67,9 @@ export default function HylimoEditor({
6867 const disposablesRef = useRef < Disposable [ ] > ( [ ] ) ;
6968 const languageClientRef = useRef < Promise < LanguageClientProxy > | null > ( null ) ;
7069 const editorStartedRef = useRef ( false ) ;
70+ type MonacoEditor = NonNullable < ReturnType < EditorApp [ "getEditor" ] > > ;
7171
72- const monacoEditorRef = useRef < monaco . editor . IStandaloneCodeEditor | null > (
73- null
74- ) ;
72+ const monacoEditorRef = useRef < MonacoEditor | null > ( null ) ;
7573 const readOnlyRef = useRef ( readOnly ) ;
7674 const isUpdatingModelRef = useRef ( false ) ;
7775 const actionDispatcherRef = useRef < IActionDispatcher | null > ( null ) ;
You can’t perform that action at this time.
0 commit comments