chore: add the static field to the new renderer

This commit is contained in:
Xavier Stouder 2021-08-27 09:14:20 +02:00
parent 186fb03048
commit 5997227997
1 changed files with 10 additions and 2 deletions

View File

@ -672,13 +672,21 @@ const class_box = (parent, node) => {
}
const classAttributes = [];
node.classData.members.forEach((str) => {
let parsedText = parseMember(str).displayText;
const parsedInfo = parseMember(str);
let parsedText = parsedInfo.displayText;
if (getConfig().flowchart.htmlLabels) {
parsedText = parsedText.replace(/</g, '&lt;').replace(/>/g, '&gt;');
}
const lbl = labelContainer
.node()
.appendChild(createLabel(parsedText, node.labelStyle, true, true));
.appendChild(
createLabel(
parsedText,
parsedInfo.cssStyle ? parsedInfo.cssStyle : node.labelStyle,
true,
true
)
);
let bbox = lbl.getBBox();
if (evaluate(getConfig().flowchart.htmlLabels)) {
const div = lbl.children[0];