From 75b0ee3dafe81b1c2c5d05758f4204e900c38a1d Mon Sep 17 00:00:00 2001 From: Sidharth Vinod Date: Tue, 21 May 2024 17:56:50 +0530 Subject: [PATCH] Remove unused code --- packages/mermaid-layout-elk/src/index.ts | 27 ------------------------ 1 file changed, 27 deletions(-) diff --git a/packages/mermaid-layout-elk/src/index.ts b/packages/mermaid-layout-elk/src/index.ts index eb860436e..fe8733293 100644 --- a/packages/mermaid-layout-elk/src/index.ts +++ b/packages/mermaid-layout-elk/src/index.ts @@ -214,25 +214,6 @@ const addSubGraphs = function (nodeArr) { return parentLookupDb; }; -const insertChildren = (nodeArray, parentLookupDb) => { - nodeArray.forEach((node) => { - // Check if we have reached the end of the tree - if (!node.children) { - node.children = []; - } - // Check if the node has children - const childIds = parentLookupDb.childrenById[node.id]; - // If the node has children, add them to the node - if (childIds) { - childIds.forEach((childId) => { - node.children.push(nodeDb[childId]); - }); - } - // Recursive call - insertChildren(node.children, parentLookupDb); - }); -}; - const getEdgeStartEndPoint = (edge, dir) => { let source = edge.start; let target = edge.end; @@ -272,14 +253,6 @@ const calcOffset = function (src, dest, parentLookupDb) { /** * Add edges to graph based on parsed graph definition - * - * @param {object} edges The edges to add to the graph - * @param {object} g The graph object - * @param cy - * @param diagObj - * @param dataForLayout - * @param graph - * @param svg */ export const addEdges = function (dataForLayout, graph, svg) { log.info('abc78 DAGA edges = ', dataForLayout);