mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-15 05:19:58 +02:00
updated halfRoundedRectangle shape
This commit is contained in:
@@ -52,7 +52,7 @@ export const halfRoundedRectangle = async (parent: SVGAElement, node: Node) => {
|
|||||||
polygon.attr('transform', `translate(${-w / 2 - h / 4}, ${-h / 2})`);
|
polygon.attr('transform', `translate(${-w / 2 - h / 4}, ${-h / 2})`);
|
||||||
label.attr(
|
label.attr(
|
||||||
'transform',
|
'transform',
|
||||||
`translate(${-w / 2 + (node.padding ?? 0) - h / 4 - (bbox.x - (bbox.left ?? 0))}, ${-h / 2 + (node.padding ?? 0) - (bbox.y - (bbox.top ?? 0))})`
|
`translate(${-w / 2 + (node.padding ?? 0) - (bbox.x - (bbox.left ?? 0))}, ${-h / 2 + (node.padding ?? 0) - (bbox.y - (bbox.top ?? 0))})`
|
||||||
);
|
);
|
||||||
|
|
||||||
updateNodeBounds(node, polygon);
|
updateNodeBounds(node, polygon);
|
||||||
|
Reference in New Issue
Block a user