MC-1730 Fix for data-et as cluster

This commit is contained in:
Ashish Jain
2024-07-08 14:52:07 +02:00
parent df7de0e796
commit d7497c179e
6 changed files with 10184 additions and 8050 deletions

View File

@@ -57,7 +57,7 @@
</style>
</head>
<body>
<pre id="diagram" class="mermaid">
<pre id="diagram" class="mermaid2">
%%{init: {"look": "neo", "theme": "neo","fontFamily": "Arial"} }%%
flowchart
A[A really really really super long node] --> B & C
@@ -66,7 +66,7 @@ flowchart
end
</pre
>
<pre id="diagram" class="mermaid">
<pre id="diagram" class="mermaid2">
%%{init: {"look": "neo", "theme": "forest","fontFamily": "Arial", "themeVariables": {
"useGradient": true,
"gradientStart": '#fff',
@@ -94,15 +94,30 @@ flowchart LR
class C ash
style C stroke:#00f, fill:black
</pre>
<!-- Flowchart with subgraph-->
<pre id="diagram3" class="mermaid">
flowchart TB
c1-->a2
subgraph one
a1-->a2
end
subgraph two
b1-->b2
end
subgraph three
c1-->c2
end
</pre>
<pre id="diagram4" class="mermaid2">
stateDiagram
A:::foo
B:::bar --> C:::foobar
classDef foo stroke:#f00
classDef bar stroke:#0f0
style C stroke:#00f, fill:black, color:white
<pre id="diagram4" class="mermaid">
stateDiagram-v2
[*] --> First
state First {
[*] --> second
second --> [*]
}
</pre>

View File

@@ -1,7 +1,7 @@
// @ts-nocheck File not ready to check types
import { curveLinear } from 'd3';
import ELK from 'elkjs/lib/elk.bundled.js';
import mermaid, { type LayoutData } from 'mermaid';
import { type LayoutData } from 'mermaid';
import { type TreeData, findCommonAncestor } from './find-common-ancestor.js';
const {

View File

@@ -1,6 +1,6 @@
{
"name": "@mermaid-chart/mermaid",
"version": "11.0.0-b.38",
"version": "11.0.0-b.41",
"description": "Markdown-ish syntax for generating flowcharts, sequence diagrams, class diagrams, gantt charts and git graphs.",
"type": "module",
"module": "./dist/mermaid.core.mjs",
@@ -136,4 +136,4 @@
"dist/",
"README.md"
]
}
}

View File

@@ -149,7 +149,7 @@ There are ten types of arrows currently supported:
| `-->` | Dotted line without arrow |
| `->>` | Solid line with arrowhead |
| `-->>` | Dotted line with arrowhead |
| `<<->>` | Solid line with bidirectional arrowheads (v<MERMAID_RELEASE_VERSION>+) |
| `<<->>` | Solid line with bidirectional arrowheads (v11.0.0-b.41+) |
| `<<-->>` | Dotted line with bidirectional arrowheads (v<MERMAID_RELEASE_VERSION>+) |
| `-x` | Solid line with a cross at the end |
| `--x` | Dotted line with a cross at the end. |

View File

@@ -179,8 +179,7 @@ const roundedWithTitle = async (parent, node) => {
.insert('g')
.attr('class', node.cssClasses)
.attr('id', node.id)
.attr('data-et', 'node')
.attr('data-node', 'true')
.attr('data-et', 'cluster')
.attr('data-id', node.id)
.attr('data-look', node.look);

18190
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff