Replace Leaflet/raster tiles with MapLibre GL JS: an online OpenFreeMap style and an offline style built from a local PMTiles archive via pmtiles.js and protomaps-themes-base (no glyphs/labels offline by design, see docs/architecture.adoc). Frontend libraries are vendored locally rather than loaded from a CDN so the app keeps working with no internet access. Also add an animated RainViewer precipitation radar overlay (toggle, play/pause, scrub slider), matching the default time window of the weather-radar-card Home Assistant integration.
17 lines
509 B
ERB
17 lines
509 B
ERB
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<title>MapTool</title>
|
|
<link rel="stylesheet" href="/vendor/maplibre-gl/maplibre-gl.css">
|
|
<link rel="stylesheet" href="/css/style.css">
|
|
</head>
|
|
<body>
|
|
<%= yield %>
|
|
<script src="/vendor/pmtiles/pmtiles.js"></script>
|
|
<script src="/vendor/protomaps-themes-base/protomaps-themes-base.js"></script>
|
|
<script type="module" src="/js/map.js"></script>
|
|
</body>
|
|
</html>
|