From 8d362e6d3db2a1545428fbdfdec57b173dca42e1 Mon Sep 17 00:00:00 2001 From: Jochen Sprickerhof Date: Mon, 27 May 2024 17:13:04 +0200 Subject: [PATCH 1/5] Make lat, lon and zoom configurable --- rainviewer-api-example.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/rainviewer-api-example.html b/rainviewer-api-example.html index 3e01e03..3f9fac0 100644 --- a/rainviewer-api-example.html +++ b/rainviewer-api-example.html @@ -42,7 +42,11 @@
+ - + +
FRAME TIME
From 09350f9fa864de57f353395d93b544c0f96e1ee4 Mon Sep 17 00:00:00 2001 From: Jochen Sprickerhof Date: Fri, 12 Jul 2024 13:51:11 +0200 Subject: [PATCH 4/5] Use latest leaflet version --- rainviewer-api-example.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rainviewer-api-example.html b/rainviewer-api-example.html index cb619a3..5854bca 100644 --- a/rainviewer-api-example.html +++ b/rainviewer-api-example.html @@ -6,9 +6,9 @@ - + - + From a266c68b8e6ba31d2da87294c7dd538a1f8c8aeb Mon Sep 17 00:00:00 2001 From: Jochen Sprickerhof Date: Mon, 26 Aug 2024 11:08:00 +0200 Subject: [PATCH 5/5] Add marker for urlParams --- rainviewer-api-example.html | 3 +++ 1 file changed, 3 insertions(+) diff --git a/rainviewer-api-example.html b/rainviewer-api-example.html index 5854bca..274da70 100644 --- a/rainviewer-api-example.html +++ b/rainviewer-api-example.html @@ -45,6 +45,9 @@ const lon = urlParams.has('lon') ? parseFloat(urlParams.get('lon')) : 2.3522; const zoom = urlParams.has('zoom') ? parseInt(urlParams.get('zoom')) : 6; var map = L.map('mapid').setView([lat, lon], zoom); + if (urlParams.has('lat')) { + var marker = L.marker([lat, lon]).addTo(map); + } L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', { attributions: 'Map data © OpenStreetMap contributors'