From b0e53c86bbd012e5bf45f93a0466acee64a41514 Mon Sep 17 00:00:00 2001 From: liamcottle Date: Wed, 13 Mar 2024 15:33:35 +1300 Subject: [PATCH] rename connections layer group --- src/public/index.html | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/public/index.html b/src/public/index.html index 2d472f0..8b03ec5 100644 --- a/src/public/index.html +++ b/src/public/index.html @@ -267,7 +267,7 @@ // create layer groups var nodesLayerGroup = new L.LayerGroup(); - var connectionsLayerGroup = new L.LayerGroup(); + var neighboursLayerGroup = new L.LayerGroup(); // create icons var iconOnline = L.divIcon({ className: 'icon-online'}); @@ -289,7 +289,7 @@ var overlays = { "Nodes": nodesLayerGroup, - "Connections": connectionsLayerGroup, + "Neighbours": neighboursLayerGroup, }; // add layers to control ui @@ -297,7 +297,7 @@ // add layers to map that should be enabled by default nodesLayerGroup.addTo(map); - connectionsLayerGroup.addTo(map); + neighboursLayerGroup.addTo(map); legend.addTo(map); // remove outline when map clicked @@ -432,8 +432,8 @@ nodesLayerGroup.clearLayers(); } - function clearAllConnections() { - connectionsLayerGroup.clearLayers(); + function clearAllNeighbours() { + neighboursLayerGroup.clearLayers(); } function closeAllPopups() { @@ -481,7 +481,7 @@ closeAllPopups(); closeAllTooltips(); clearAllNodes(); - clearAllConnections(); + clearAllNeighbours(); clearNodeOutline(); } @@ -581,7 +581,7 @@ continue; } - // add node connections + // add node neighbours const neighbours = node.neighbour_info?.neighbours ?? []; console.log(neighbours); for(const neighbour of neighbours){ @@ -605,7 +605,7 @@ ], { color: '#2563eb', opacity: 0.5, - }).addTo(connectionsLayerGroup); + }).addTo(neighboursLayerGroup); const tooltip = `${node.long_name} heard ${neighbourNode.long_name}` + `
SNR: ${neighbour.snr}dB`