Skip to content

Commit

Permalink
fix: some demo elk plugin imports
Browse files Browse the repository at this point in the history
  • Loading branch information
kairi003 committed Nov 10, 2024
1 parent c8ce416 commit 56f7bfb
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions demos/dev/example.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@

<script type="module">
import mermaid from '/mermaid.esm.mjs';
import flowchartELK from '/mermaid-flowchart-elk.esm.mjs';
await mermaid.registerExternalDiagrams([flowchartELK]);
import layouts from '/mermaid-layout-elk.esm.mjs';
mermaid.registerLayoutLoaders(layouts);
async function render(str) {
const { svg } = await mermaid.render('dynamic', str);
document.getElementById('dynamicDiagram').innerHTML = svg;
Expand Down
4 changes: 2 additions & 2 deletions demos/flowchart-elk.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ <h1>Flowchart ELK</h1>

<script type="module">
import mermaid from './mermaid.esm.mjs';
import flowchartELK from './mermaid-flowchart-elk.esm.mjs';
await mermaid.registerExternalDiagrams([flowchartELK]);
import layouts from './mermaid-layout-elk.esm.mjs';
mermaid.registerLayoutLoaders(layouts);
mermaid.initialize({
logLevel: 3,
});
Expand Down
3 changes: 3 additions & 0 deletions demos/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ <h2><a href="./er.html">Entity Relation diagram</a></h2>
<li>
<h2><a href="./flowchart.html">Flow charts</a></h2>
</li>
<li>
<h2><a href="./flowchart-elk.html">Flow charts ELK</a></h2>
</li>
<li>
<h2><a href="./gantt.html">Gantt</a></h2>
</li>
Expand Down

0 comments on commit 56f7bfb

Please sign in to comment.