import type { editor as MonacoEditor } from 'monaco-editor'

// Module-level ref so TreeEditorPage can trigger Monaco undo/redo from toolbar buttons
let _monacoEditor: MonacoEditor.IStandaloneCodeEditor | null = null

export function getMonacoEditor() { return _monacoEditor }
export function setMonacoEditor(editor: MonacoEditor.IStandaloneCodeEditor | null) { _monacoEditor = editor }
