This commit is contained in:
2025-10-26 07:49:26 +04:00
parent 3fc8329303
commit 12b4685457
9 changed files with 457 additions and 110 deletions

View File

@@ -143,7 +143,7 @@ class MarkdownEditor {
this.currentFile = null;
this.filenameInput.value = '';
this.filenameInput.focus();
this.editor.setValue('');
this.editor.setValue('# New File\n\nStart typing...\n');
this.updatePreview();
if (window.showNotification) {
@@ -192,7 +192,7 @@ class MarkdownEditor {
*/
updatePreview() {
const markdown = this.editor.getValue();
let html = this.marked.parse(markdown);
let html = window.marked.parse(markdown);
// Process mermaid diagrams
html = html.replace(/<pre><code class="language-mermaid">([\s\S]*?)<\/code><\/pre>/g, (match, code) => {