From cb2a2c7fb868b5775c4a620f62e90115a28b1cfd Mon Sep 17 00:00:00 2001 From: Edward Betts Date: Sat, 13 Jan 2024 18:20:02 +0000 Subject: [PATCH] Change colour of rail journey on map to blue --- templates/trip_page.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/trip_page.html b/templates/trip_page.html index b49bb6f..2924746 100644 --- a/templates/trip_page.html +++ b/templates/trip_page.html @@ -130,12 +130,12 @@ routes.forEach(function(route) { // If route is defined as GeoJSON L.geoJSON(JSON.parse(route.geojson), { style: function(feature) { - return {color: route.type === "train" ? "green" : "blue"}; // Green for trains, blue for flights + return {color: route.type === "train" ? "blue" : "blue"}; // Green for trains, blue for flights } }).addTo(map); } else { // If route is defined by 'from' and 'to' coordinates - var color = route.type === "train" ? "green" : "red"; // Green for trains, red for flights + var color = route.type === "train" ? "blue" : "red"; // Green for trains, red for flights L.polyline([route.from, route.to], {color: color}).addTo(map); } });