From e00c435a929afeac1965e04b8f6585696a915e77 Mon Sep 17 00:00:00 2001 From: Michael Foiani Date: Sun, 18 Apr 2021 00:53:51 -0400 Subject: Working build that scales with the large database. We need to figure out the profit calculation on the large scale, though. --- react-frontend/src/components/Visualization.js | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'react-frontend/src/components/Visualization.js') diff --git a/react-frontend/src/components/Visualization.js b/react-frontend/src/components/Visualization.js index 91082e9..2016129 100644 --- a/react-frontend/src/components/Visualization.js +++ b/react-frontend/src/components/Visualization.js @@ -15,8 +15,7 @@ function Visualization(props) { const options = { edges: { color: "#ffffff" - }, - autoResize: true + } }; const events = { select: () => event => props.setSelected(event.nodes[0]) @@ -29,11 +28,13 @@ function Visualization(props) { const getNodes = () => { let nodes = []; props.data.forEach(hub => { - nodes.push({ - id: hub.id, - label: hub.name, - size: hub.suspicionScore * 10 - }); + if (hub.followers) { + nodes.push({ + id: hub.id, + label: hub.name, + size: hub.suspicionScore * 10 + }); + } }); return nodes; } -- cgit v1.2.3-70-g09d2