local graph zoom fix

This commit is contained in:
Utsob Roy 2023-02-01 15:05:39 +06:00
parent ce494682cf
commit 24d7bdce5b

View File

@ -93,9 +93,11 @@
.onNodeClick(node => { .onNodeClick(node => {
window.location = node.url; window.location = node.url;
}); });
setTimeout(() => { if (delay != null) {
Graph.zoomToFit(5, 75); setTimeout(() => {
}, delay); Graph.zoomToFit(5, 75);
}, delay);
}
return Graph; return Graph;
} }
@ -117,7 +119,7 @@
Graph._destructor(); Graph._destructor();
Graph = null; Graph = null;
} }
renderGraph(filterToDepth(JSON.parse(JSON.stringify(window.graphData))), "link-graph", 330, 330, 1); renderGraph(filterToDepth(JSON.parse(JSON.stringify(window.graphData))), "link-graph", 330, 330, null);
}) })
window.fullGraph = null; window.fullGraph = null;