diff --git a/static/index.html b/static/index.html index b865419..636ec06 100644 --- a/static/index.html +++ b/static/index.html @@ -1,6 +1,6 @@ - + @@ -49,12 +49,38 @@ margin-left: -7px; margin-top: -7px; } + + #banner { + grid-column-start: 1; + grid-column-end: 3; + background-color: #ef4444; + color: white; + display: flex; + align-items: center; + justify-content: center; + } + + #banner.hidden { + display: none; + } -
-
+
+ + +
-
+

There are...

  • - bus(es)
  • - TRAX train(s)
  • -
  • - FrontRunner train(s)
  • +
  • + - FrontRunner train(s) +

...out and about

-
+
-
- last updated: - -
+
last updated: -
diff --git a/static/js/main.js b/static/js/main.js index 96d580c..1b6fb4b 100644 --- a/static/js/main.js +++ b/static/js/main.js @@ -95,6 +95,12 @@ protobuf.load("/schema.proto").then((root) => { displayLastUpdated() populateTotals(vehicles) + if (vehicles.length == 0) { + document.getElementById("banner").classList.remove("hidden") + map.invalidateSize() + } else { + document.getElementById("banner").classList.add("hidden") + } // render vehicles on map clearMap();