diff options
Diffstat (limited to 'pages')
-rw-r--r-- | pages/index.tsx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/pages/index.tsx b/pages/index.tsx index 69885e7..c4cc011 100644 --- a/pages/index.tsx +++ b/pages/index.tsx @@ -342,7 +342,9 @@ export const Graph = function (props: GraphProps) { // zoomToFit off a little bit setTimeout(() => { const fg = threeDim ? graph3dRef.current : graph2dRef.current - fg?.zoomToFit(0, numbereWithinRange(20, 200, windowWidth / 8)) + fg?.zoomToFit(1000, numbereWithinRange(20, 200, windowWidth / 8), (node: NodeObject) => + scopedNodeIds.some((n) => n === node.id), + ) }, 1) }, [JSON.stringify(scopedNodeIds)]) |