#2139 Applying user defined classes properly when calculating shape width

This commit is contained in:
Knut Sveidqvist
2023-08-10 13:14:39 +02:00
parent 85a988c31c
commit c55a0947be
3 changed files with 103 additions and 22 deletions

View File

@@ -13,6 +13,7 @@ export const labelHelper = async (parent, node, _classes, isNode) => {
} else {
classes = _classes;
}
// Add outer g element
const shapeSvg = parent
.insert('g')
@@ -49,7 +50,6 @@ export const labelHelper = async (parent, node, _classes, isNode) => {
)
);
}
// Get the size of the label
let bbox = text.getBBox();
const halfPadding = node.padding / 2;