Add layergroup for LongFast

This commit is contained in:
Anton Roslund 2025-09-28 20:26:19 +02:00
parent 9eae1d21b6
commit 998259042b

View file

@ -2745,6 +2745,7 @@
}); });
var nodesBackboneLayerGroup = new L.LayerGroup(); var nodesBackboneLayerGroup = new L.LayerGroup();
var nodesMediumFastLayerGroup = new L.LayerGroup(); var nodesMediumFastLayerGroup = new L.LayerGroup();
var nodesLongFastLayerGroup = new L.LayerGroup();
var waypointsLayerGroup = new L.LayerGroup(); var waypointsLayerGroup = new L.LayerGroup();
var nodePositionHistoryLayerGroup = new L.LayerGroup(); var nodePositionHistoryLayerGroup = new L.LayerGroup();
var traceroutesLayerGroup = new L.LayerGroup(); var traceroutesLayerGroup = new L.LayerGroup();
@ -2817,6 +2818,7 @@
"Routers": nodesRouterLayerGroup, "Routers": nodesRouterLayerGroup,
"Backbone": nodesBackboneLayerGroup, "Backbone": nodesBackboneLayerGroup,
"MediumFast": nodesMediumFastLayerGroup, "MediumFast": nodesMediumFastLayerGroup,
"LongFast": nodesLongFastLayerGroup,
"Clustered": nodesClusteredLayerGroup, "Clustered": nodesClusteredLayerGroup,
"None": new L.LayerGroup(), "None": new L.LayerGroup(),
}, },
@ -2997,6 +2999,7 @@
nodesRouterLayerGroup.clearLayers(); nodesRouterLayerGroup.clearLayers();
nodesBackboneLayerGroup.clearLayers(); nodesBackboneLayerGroup.clearLayers();
nodesMediumFastLayerGroup.clearLayers(); nodesMediumFastLayerGroup.clearLayers();
nodesLongFastLayerGroup.clearLayers();
} }
function clearAllNeighbours() { function clearAllNeighbours() {
@ -3597,6 +3600,11 @@
nodesMediumFastLayerGroup.addLayer(marker); nodesMediumFastLayerGroup.addLayer(marker);
} }
// add markers for LongFast channel to layer group
if(node.channel_id == "LongFast") {
nodesLongFastLayerGroup.addLayer(marker);
}
// show tooltip on desktop only // show tooltip on desktop only
if(!isMobile()){ if(!isMobile()){
marker.bindTooltip(getTooltipContentForNode(node), { marker.bindTooltip(getTooltipContentForNode(node), {