Merge branch '5237-unified-layout-common-renderer' of github.com:mermaid-js/mermaid into 5237-unified-layout-common-renderer

This commit is contained in:
Knut Sveidqvist
2024-06-13 14:27:16 +02:00
8 changed files with 812 additions and 722 deletions

View File

@@ -1,19 +1,33 @@
<html>
<head>
<link href="https://fonts.googleapis.com/css?family=Montserrat&display=swap" rel="stylesheet" />
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" />
<link href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css" rel="stylesheet" />
<link href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"
rel="stylesheet"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"
rel="stylesheet"
/>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&display=swap" rel="stylesheet" />
<link
href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&display=swap"
rel="stylesheet"
/>
<link
href="https://fonts.googleapis.com/css2?family=Caveat:wght@400..700&family=Kalam:wght@300;400;700&family=Rubik+Mono+One&display=swap"
rel="stylesheet" />
<link href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&family=Rubik+Mono+One&display=swap"
rel="stylesheet" />
rel="stylesheet"
/>
<link
href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&family=Rubik+Mono+One&display=swap"
rel="stylesheet"
/>
<style>
body {
@@ -69,7 +83,7 @@
}
.active:after {
content: "\2212";
content: '\2212';
}
.content {
@@ -90,7 +104,8 @@
<body>
<table>
<tr>
<th></th> <!-- Placeholder for the top left corner -->
<th></th>
<!-- Placeholder for the top left corner -->
<th>Dagre</th>
<th>Dagre with rough</th>
<th>ELK</th>
@@ -104,8 +119,9 @@
<pre>
flowchart LR
id1([This is the text in the box])
</pre>
</pre
>
</div>
</div>
</th>
<td>
@@ -113,39 +129,38 @@
flowchart LR
id1([This is the text in the box])
</pre>
</pre
>
</td>
<td>
<pre id="diagram2" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1([This is the text in the box])
</pre>
</pre
>
</td>
<td>
<pre id="diagram3" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1([This is the text in the box])
</pre>
</pre
>
</td>
<td>
<pre id="diagram4" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1([This is the text in the box])
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -156,40 +171,47 @@ flowchart LR
<pre>
flowchart LR
id1[[This is the text in the box]]
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram5" class="mermaid">
flowchart LR
id1[[This is the text in the box]]
</pre>
</pre
>
</td>
<td>
<pre id="diagram6" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1[[This is the text in the box]]
</pre>
</pre
>
</td>
<td>
<pre id="diagram7" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1[[This is the text in the box]]
</pre>
</pre
>
</td>
<td>
<pre id="diagram8" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1[[This is the text in the box]]
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -200,40 +222,47 @@ flowchart LR
<pre>
flowchart LR
id1[(Database)]
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram9" class="mermaid">
flowchart LR
id1[(Database)]
</pre>
</pre
>
</td>
<td>
<pre id="diagram10" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1[(Database)]
</pre>
</pre
>
</td>
<td>
<pre id="diagram11" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1[(Database)]
</pre>
</pre
>
</td>
<td>
<pre id="diagram12" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1[(Database)]
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -244,40 +273,47 @@ flowchart LR
<pre>
flowchart LR
id1((This is the text in the circle))
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram13" class="mermaid">
flowchart LR
id1((This is the text in the circle))
</pre>
</pre
>
</td>
<td>
<pre id="diagram14" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1((This is the text in the circle))
</pre>
</pre
>
</td>
<td>
<pre id="diagram15" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1((This is the text in the circle))
</pre>
</pre
>
</td>
<td>
<pre id="diagram16" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1((This is the text in the circle))
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -288,40 +324,47 @@ flowchart LR
<pre>
flowchart TD
id1(((This is the text in the circle)))
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram17" class="mermaid">
flowchart TD
id1(((This is the text in the circle)))
</pre>
</pre
>
</td>
<td>
<pre id="diagram18" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart TD
id1(((This is the text in the circle)))
</pre>
</pre
>
</td>
<td>
<pre id="diagram19" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart TD
id1(((This is the text in the circle)))
</pre>
</pre
>
</td>
<td>
<pre id="diagram20" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart TD
id1(((This is the text in the circle)))
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -332,40 +375,47 @@ flowchart LR
<pre>
flowchart LR
id1>This is the text in the box]
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram21" class="mermaid">
flowchart LR
id1>This is the text in the box]
</pre>
</pre
>
</td>
<td>
<pre id="diagram22" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1>This is the text in the box]
</pre>
</pre
>
</td>
<td>
<pre id="diagram23" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1>This is the text in the box]
</pre>
</pre
>
</td>
<td>
<pre id="diagram24" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1>This is the text in the box]
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -376,40 +426,47 @@ flowchart LR
<pre>
flowchart LR
id1{This is the text in the box}
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram25" class="mermaid">
flowchart LR
id1{This is the text in the box}
</pre>
</pre
>
</td>
<td>
<pre id="diagram26" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1{This is the text in the box}
</pre>
</pre
>
</td>
<td>
<pre id="diagram27" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1{This is the text in the box}
</pre>
</pre
>
</td>
<td>
<pre id="diagram28" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1{This is the text in the box}
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -420,40 +477,39 @@ flowchart LR
<pre>
flowchart LR
id1{{This is the text in the box}}
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram29" class="mermaid">
flowchart LR
id1{{This is the text in the box}}
</pre>
</td>
<td>
<pre id="diagram30" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1{{This is the text in the box}}
</pre>
</pre
>
</td>
<td>
<pre id="diagram31" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1{{This is the text in the box}}
</pre>
</pre
>
</td>
<td>
<pre id="diagram32" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1{{This is the text in the box}}
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -464,40 +520,47 @@ flowchart LR
<pre>
flowchart TD
id1[/This is the text in the box/]
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram33" class="mermaid">
flowchart TD
id1[/This is the text in the box/]
</pre>
</pre
>
</td>
<td>
<pre id="diagram34" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart TD
id1[/This is the text in the box/]
</pre>
</pre
>
</td>
<td>
<pre id="diagram35" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart TD
id1[/This is the text in the box/]
</pre>
</pre
>
</td>
<td>
<pre id="diagram36" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart TD
id1[/This is the text in the box/]
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -508,28 +571,33 @@ flowchart LR
<pre>
flowchart TD
id1[\This is the text in the box\]
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram37" class="mermaid">
flowchart TD
id1[\This is the text in the box\]
</pre>
</pre
>
</td>
<td>
<pre id="diagram38" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart TD
id1[\This is the text in the box\]
</pre>
</pre
>
</td>
<td>
<pre id="diagram39" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart TD
id1[\This is the text in the box\]
</pre>
</pre
>
</td>
<td>
<pre id="diagram40" class="mermaid">
@@ -537,12 +605,14 @@ flowchart LR
flowchart TD
id1[\This is the text in the box\]
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -553,40 +623,47 @@ flowchart LR
<pre>
flowchart TD
A[/Christmas\]
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram41" class="mermaid">
flowchart TD
A[/Christmas\]
</pre>
</pre
>
</td>
<td>
<pre id="diagram42" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart TD
A[/Christmas\]
</pre>
</pre
>
</td>
<td>
<pre id="diagram43" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart TD
A[/Christmas\]
</pre>
</pre
>
</td>
<td>
<pre id="diagram44" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart TD
A[/Christmas\]
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -597,40 +674,47 @@ flowchart LR
<pre>
flowchart TD
A[\Christmas/]
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram45" class="mermaid">
flowchart TD
A[\Christmas/]
</pre>
</pre
>
</td>
<td>
<pre id="diagram46" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart TD
A[\Christmas/]
</pre>
</pre
>
</td>
<td>
<pre id="diagram47" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart TD
A[\Christmas/]
</pre>
</pre
>
</td>
<td>
<pre id="diagram48" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart TD
A[\Christmas/]
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -641,40 +725,47 @@ flowchart LR
<pre>
flowchart LR
id1(This is the text in the box)
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram49" class="mermaid">
flowchart LR
id1(This is the text in the box)
</pre>
</pre
>
</td>
<td>
<pre id="diagram50" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1(This is the text in the box)
</pre>
</pre
>
</td>
<td>
<pre id="diagram51" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1(This is the text in the box)
</pre>
</pre
>
</td>
<td>
<pre id="diagram52" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1(This is the text in the box)
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
<tr>
@@ -685,52 +776,55 @@ flowchart LR
<pre>
flowchart LR
id1[This is the text in the box]
</pre>
</pre
>
</div>
</div>
</th>
<td>
<pre id="diagram53" class="mermaid">
flowchart LR
id1[This is the text in the box]
</pre>
</pre
>
</td>
<td>
<pre id="diagram54" class="mermaid">
%%{init: {"look": "handdrawn"} }%%
flowchart LR
id1[This is the text in the box]
</pre>
</pre
>
</td>
<td>
<pre id="diagram55" class="mermaid">
%%{init: {"handdrawn": false, "layout": "elk"} }%%
flowchart LR
id1[This is the text in the box]
</pre>
</pre
>
</td>
<td>
<pre id="diagram56" class="mermaid">
%%{init: {"look": "handdrawn", "layout": "elk"} }%%
flowchart LR
id1[This is the text in the box]
</pre>
</pre
>
</td>
</tr>
<!-- Separator row -->
<tr class="separator">
<td colspan="5"></td> <!-- This cell spans all columns including the vertical header -->
<td colspan="5"></td>
<!-- This cell spans all columns including the vertical header -->
</tr>
</table>
<script type="module">
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) {};
mermaid.initialize({
handdrawn: false,
@@ -755,21 +849,18 @@ flowchart LR
console.error(err);
};
let coll = document.getElementsByClassName("collapsible");
let coll = document.getElementsByClassName('collapsible');
for (const element of coll) {
element.addEventListener("click", function () {
this.classList.toggle("active");
element.addEventListener('click', function () {
this.classList.toggle('active');
let content = this.nextElementSibling;
if (content.style.maxHeight) {
content.style.maxHeight = null;
} else {
content.style.maxHeight = content.scrollHeight + "px";
content.style.maxHeight = content.scrollHeight + 'px';
}
});
}
</script>
</body>
</html>

View File

@@ -1,19 +1,33 @@
<html>
<head>
<link href="https://fonts.googleapis.com/css?family=Montserrat&display=swap" rel="stylesheet" />
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" />
<link href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css" rel="stylesheet" />
<link href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"
rel="stylesheet"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"
rel="stylesheet"
/>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&display=swap" rel="stylesheet" />
<link
href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&display=swap"
rel="stylesheet"
/>
<link
href="https://fonts.googleapis.com/css2?family=Caveat:wght@400..700&family=Kalam:wght@300;400;700&family=Rubik+Mono+One&display=swap"
rel="stylesheet" />
<link href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&family=Rubik+Mono+One&display=swap"
rel="stylesheet" />
rel="stylesheet"
/>
<link
href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&family=Rubik+Mono+One&display=swap"
rel="stylesheet"
/>
<style>
body {
@@ -69,7 +83,7 @@
}
.active:after {
content: "\2212";
content: '\2212';
}
.content {
@@ -90,7 +104,8 @@
<body>
<table>
<tr>
<th></th> <!-- Placeholder for the top left corner -->
<th></th>
<!-- Placeholder for the top left corner -->
<th>State rough</th>
<th>Flowchart rough</th>
</tr>
@@ -103,7 +118,9 @@
flowchart LR
id1([This is the text in the box])
</pre>
</pre
>
</div>
</div>
</th>
<td>
@@ -112,7 +129,8 @@
stateDiagram-v2
stateA
</pre>
</pre
>
</td>
<td>
<pre id="diagram2" class="mermaid">
@@ -121,22 +139,17 @@ flowchart LR
id1[[This is the text in the box]]
</pre>
</pre
>
</td>
</tr>
</table>
<script type="module">
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) {};
mermaid.initialize({
handdrawn: false,
@@ -161,21 +174,18 @@ flowchart LR
console.error(err);
};
let coll = document.getElementsByClassName("collapsible");
let coll = document.getElementsByClassName('collapsible');
for (const element of coll) {
element.addEventListener("click", function () {
this.classList.toggle("active");
element.addEventListener('click', function () {
this.classList.toggle('active');
let content = this.nextElementSibling;
if (content.style.maxHeight) {
content.style.maxHeight = null;
} else {
content.style.maxHeight = content.scrollHeight + "px";
content.style.maxHeight = content.scrollHeight + 'px';
}
});
}
</script>
</body>
</html>

View File

@@ -150,6 +150,7 @@ flowchart LR
end
Apa --- C
A --x C
</pre>
<pre id="diagram" class="mermaid2">
---

View File

@@ -105,6 +105,7 @@
stateId
</pre>
</div>
</div>
</th>
<td>
<pre id="diagram1" class="mermaid">

View File

@@ -795,10 +795,10 @@ const addNodeFromVertex = (
config: any,
look: string
) => {
let parentId = parentDB.get(vertex.id);
let isGroup = subGraphDB.get(vertex.id) || false;
const parentId = parentDB.get(vertex.id);
const isGroup = subGraphDB.get(vertex.id) || false;
let node = findNode(nodes, vertex.id);
const node = findNode(nodes, vertex.id);
if (!node) {
nodes.push({
id: vertex.id,
@@ -852,7 +852,7 @@ export const getData = () => {
const n = getVertices();
n.forEach((vertex) => {
const node = addNodeFromVertex(vertex, nodes, parentDB, subGraphDB, config, config.look);
addNodeFromVertex(vertex, nodes, parentDB, subGraphDB, config, config.look);
});
const e = getEdges();
@@ -874,7 +874,6 @@ export const getData = () => {
pattern: rawEdge.stroke,
look: config.look,
};
console.log('rawEdge SPLIT', rawEdge, index);
edges.push(edge);
});

View File

@@ -188,17 +188,6 @@ const recursiveRender = async (_elem, graph, diagramType, id, parentCluster, sit
insertCluster(clusters, node);
// A cluster in the non-recursive way
console.log(
'A tainted cluster node with children XBX',
v,
node.id,
node.width,
node.height,
node.x,
node.y,
'offset',
parent?.offsetY
);
clusterDb[node.id].node = node;
} else {
const parent = graph.node(node.parentId);

View File

@@ -287,7 +287,7 @@ const roundedWithTitle = (parent, node) => {
const rectBox = rect.node().getBBox();
node.height = rectBox.height;
node.offsetX = 0;
// Used by payout engone to position subgraph in parent
// Used by layout engine to position subgraph in parent
node.offsetY = bbox.height - node.padding / 2;
node.labelBBox = bbox;

View File

@@ -37,8 +37,7 @@ export const trapezoid = async (parent: SVGAElement, node: Node): Promise<SVGAEl
const { cssStyles } = node;
if (node.look === 'handdrawn') {
console.log('Trapezoid: Inside handdrawn block');
// @ts-ignore
// @ts-ignore - rough is not typed
const rc = rough.svg(shapeSvg);
const options = userNodeOverrides(node, {});
const pathData = createTrapezoidPathD(0, 0, w, h);