Skip to content

Commit

Permalink
Merge pull request #2 from Sammy-T/markdown
Browse files Browse the repository at this point in the history
Create markdown editor init helper
  • Loading branch information
Sammy-T authored Jun 26, 2024
2 parents 36f8e12 + d87fbbc commit febd659
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cms/src/lib/widgets/InputMarkdown.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,10 @@
.then(onEditorCreated);
}
function initEditor(dom) {
editor(dom);
}
async function init() {
if(!$editingEntry) return;
Expand Down Expand Up @@ -270,7 +274,7 @@
<MarkdownMenu on:menutexttype={onMenuTextType} on:menuaction={onMenuAction} />
<!-- Milkdown editor container -->
<div use:editor />
<div use:initEditor />
<LinkEditor bind:this={linkEditor} on:saveurl={onSaveUrl} />
</div>
Expand Down

0 comments on commit febd659

Please sign in to comment.