Update to test elk layout

This commit is contained in:
yari-dewalt
2024-10-17 17:58:19 -07:00
parent df22fb5e00
commit 1d68c4f075

View File

@@ -55,7 +55,7 @@
--- ---
config: config:
htmlLabels: false htmlLabels: false
look: layout: elk
--- ---
erDiagram erDiagram
"hi" }o..o{ ORDER : places "hi" }o..o{ ORDER : places
@@ -129,6 +129,24 @@
<div class="test"> <div class="test">
<h2>Basic Relationship</h2> <h2>Basic Relationship</h2>
<pre class="mermaid"> <pre class="mermaid">
---
config:
layout: elk
---
erDiagram
CUSTOMER }|..|{ DELIVERY-ADDRESS : has
CUSTOMER ||--o{ ORDER : places
CUSTOMER ||--o{ INVOICE : "liable for"
DELIVERY-ADDRESS ||--o{ ORDER : receives
INVOICE ||--|{ ORDER : covers
ORDER ||--|{ ORDER-ITEM : includes
PRODUCT-CATEGORY ||--|{ PRODUCT : contains
PRODUCT ||--o{ ORDER-ITEM : "ordered in"
</pre>
</div>
<div class="test">
<h2>Basic Relationship</h2>
<pre class="mermaid">
--- ---
config: config:
layout: elk layout: elk
@@ -267,7 +285,9 @@
</div> </div>
<script type="module"> <script type="module">
import mermaid from '/mermaid.esm.mjs'; import mermaid from './mermaid.esm.mjs';
import layouts from './mermaid-layout-elk.esm.mjs';
mermaid.registerLayoutLoaders(layouts);
mermaid.parseError = function (err, hash) { mermaid.parseError = function (err, hash) {
console.error('Mermaid error: ', err); console.error('Mermaid error: ', err);
}; };