mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-23 01:09:42 +02:00
#2951 Fix for styling issue on labes when using htmlLabels in legacy flowcharts
This commit is contained in:
@@ -241,7 +241,9 @@ export const addEdges = function (edges, g) {
|
|||||||
|
|
||||||
if (evaluate(getConfig().flowchart.htmlLabels)) {
|
if (evaluate(getConfig().flowchart.htmlLabels)) {
|
||||||
edgeData.labelType = 'html';
|
edgeData.labelType = 'html';
|
||||||
edgeData.label = `<span id="L-${linkId}" class="edgeLabel L-${linkNameStart}' L-${linkNameEnd}">${edge.text.replace(
|
edgeData.label = `<span id="L-${linkId}" class="edgeLabel L-${linkNameStart}' L-${linkNameEnd}" style="${
|
||||||
|
edgeData.labelStyle
|
||||||
|
}">${edge.text.replace(
|
||||||
/fa[lrsb]?:fa-[\w-]+/g,
|
/fa[lrsb]?:fa-[\w-]+/g,
|
||||||
(s) => `<i class='${s.replace(':', ' ')}'></i>`
|
(s) => `<i class='${s.replace(':', ' ')}'></i>`
|
||||||
)}</span>`;
|
)}</span>`;
|
||||||
|
Reference in New Issue
Block a user