diff --git a/packages/mermaid-layout-elk/package.json b/packages/mermaid-layout-elk/package.json index af5cd4833..45b52d5d0 100644 --- a/packages/mermaid-layout-elk/package.json +++ b/packages/mermaid-layout-elk/package.json @@ -1,6 +1,6 @@ { "name": "@mermaid-chart/layout-elk", - "version": "0.0.15", + "version": "0.0.16", "description": "ELK layout engine for mermaid", "module": "dist/mermaid-layout-elk.core.mjs", "types": "dist/packages/mermaid-layout-elk/src/index.d.ts", diff --git a/packages/mermaid-layout-elk/src/render.ts b/packages/mermaid-layout-elk/src/render.ts index 4408f772b..10b3f6cd8 100644 --- a/packages/mermaid-layout-elk/src/render.ts +++ b/packages/mermaid-layout-elk/src/render.ts @@ -280,9 +280,9 @@ export const addEdges = async function (dataForLayout, graph, svg) { await Promise.all( edges.map(async function (edge) { - + let linkId = edge.id; if (!edge.id) { - // Identify Link + // Identify Link const linkIdBase = edge.id; // 'L-' + edge.start + '-' + edge.end; // count the links from+to the same node to give unique id if (linkIdCnt[linkIdBase] === undefined) { @@ -294,9 +294,9 @@ export const addEdges = async function (dataForLayout, graph, svg) { } const linkId = linkIdBase + '_' + linkIdCnt[linkIdBase]; edge.id = linkId; + // log.info('abc78 new link id to be used is', linkIdBase, linkId, linkIdCnt[linkIdBase]); } - - log.info('abc78 new link id to be used is', linkIdBase, linkId, linkIdCnt[linkIdBase]); + const linkNameStart = 'LS_' + edge.start; const linkNameEnd = 'LE_' + edge.end;