mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-09 18:39:41 +02:00
fix for label positioning triangle and flipped triangle
This commit is contained in:
@@ -31,7 +31,7 @@ export const flippedTriangle = async (parent: SVGAElement, node: Node): Promise<
|
||||
const w = (node?.width ? node?.width : bbox.width) + (labelPaddingX ?? 0);
|
||||
const h = node?.height ? node?.height : w + bbox.height;
|
||||
|
||||
const tw = w + bbox.height;
|
||||
const tw = h;
|
||||
|
||||
const points = [
|
||||
{ x: 0, y: -h },
|
||||
|
@@ -31,7 +31,7 @@ export const triangle = async (parent: SVGAElement, node: Node): Promise<SVGAEle
|
||||
const useHtmlLabels = evaluate(getConfig().flowchart?.htmlLabels);
|
||||
const w = (node?.width ? node?.width : bbox.width) + labelPaddingX;
|
||||
const h = node?.height ? node?.height : w + bbox.height;
|
||||
const tw = w + bbox.height;
|
||||
const tw = h;
|
||||
const points = [
|
||||
{ x: 0, y: 0 },
|
||||
{ x: tw, y: 0 },
|
||||
|
Reference in New Issue
Block a user