Repository navigation
feat(radar): rain radar tab with FMI observed + forecast overlay - #982
Merged
Merged
Conversation
New "Sade" tab: a Leaflet map centred on the saved location with pinch-zoom/pan, an animated timeline, and a recenter button. Backend (radar module): - GET /api/radar/frames — last-hour observed radar frames from FMI WMS capabilities (5-min steps). - GET /api/radar/wms — transparent proxy for FMI WMS GetMap tiles. - GET /api/radar/forecast — FMI HARMONIE precip forecast: fetch the EPSG:4326 GRIB2 grid, decode with the `grib` crate (no native deps), read grid geometry from the GDS, orient north-up, block-max downsample, convert metres→mm, return a compact JSON grid. Retries transient FMI drops; cached. Frontend (RainMap, lazy-loaded): - Observed WMS frames + forecast heat overlays merged into one timeline with a "now" divider, play/pause, frame slider, long-press swipe scrub, relative-time labels, and a precipitation legend. FMI WMS/WFS need no API key; new FMI_WMS_BASE_URL / FMI_DOWNLOAD_BASE_URL settings default to the public endpoints.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
New Sade tab: a Leaflet map centred on the saved location with pinch-zoom/pan, an animated timeline, and a recenter button.
Backend (
radarmodule)GET /api/radar/frames— last-hour observed radar frames, derived from FMI WMS GetCapabilities (5-min steps).GET /api/radar/wms— transparent proxy for FMI WMSGetMaptiles (single fixed upstream, streams bytes).GET /api/radar/forecast— FMI HARMONIE precipitation forecast: fetches the EPSG:4326 GRIB2 grid, decodes it with thegribcrate (default-features = false, no native C deps), reads grid geometry straight from the GDS (no PROJ), orients north-up, block-max downsamples, converts metres→mm, returns a compact JSON grid. Retries transient FMI connection drops; cached 30 min.Frontend (
RainMap, lazy-loaded)−30 min→nyt→+5 h), and a precipitation legend.Notes
FMI_WMS_BASE_URL/FMI_DOWNLOAD_BASE_URLdefault to the public endpoints.Test plan
cargo test— 20 unit + 18 integration pass (incl. GRIB orientation/resampling)yarn validate(typecheck + lint + format) clean;yarn buildsucceeds