mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-10-19 22:19:45 +02:00
Updated logic for vertex label
This commit is contained in:
@@ -63,7 +63,7 @@
|
|||||||
<body>
|
<body>
|
||||||
<pre id="diagram4" class="mermaid">
|
<pre id="diagram4" class="mermaid">
|
||||||
flowchart LR
|
flowchart LR
|
||||||
A --> B2@{ icon: "fa:bell", form: "square", label: "test augfuyfavf ydvaubfuac", pos: "t", h: 400, w: 50 }@ --> C
|
A --> B2@{ icon: "fa:bell", form: "square", label: "B2", pos: "t", h: 400, w: 50 }@ --> C
|
||||||
</pre
|
</pre
|
||||||
>
|
>
|
||||||
<pre id="diagram5" class="mermaid2">
|
<pre id="diagram5" class="mermaid2">
|
||||||
|
@@ -146,7 +146,7 @@ export const addVertex = function (
|
|||||||
}
|
}
|
||||||
if (doc?.icon) {
|
if (doc?.icon) {
|
||||||
vertex.icon = doc?.icon;
|
vertex.icon = doc?.icon;
|
||||||
if (vertex.text === id) {
|
if (!doc.label) {
|
||||||
vertex.text = '';
|
vertex.text = '';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -158,7 +158,7 @@ export const addVertex = function (
|
|||||||
}
|
}
|
||||||
if (doc?.img) {
|
if (doc?.img) {
|
||||||
vertex.img = doc?.img;
|
vertex.img = doc?.img;
|
||||||
if (vertex.text === id) {
|
if (!doc.label) {
|
||||||
vertex.text = '';
|
vertex.text = '';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user