Live peat groundwater (TMAT) station overlay and risk factor integration #5
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What to build
Create an API route and UI overlay for real-time peatland groundwater table depth (TMAT / Tinggi Muka Air Tanah) monitoring stations. Match each fire cluster to the nearest TMAT sensor, enforce the -40 cm critical dryness threshold, and render station markers on the map.
Technical specifications
Target files:
src/app/api/tmat/route.ts: Telemetry proxy endpoint delivering normalized sensor stations.src/types/tmat.ts: TypeScript interfaces for sensor telemetry and thresholds.src/lib/services/tmat.ts: Upstream sensor ingest with geographic KD-Tree index.src/components/map/layers/tmat-layer.tsx: MapLibre circle/symbol layer for sensor locations.src/components/map/popups/tmat-popup.tsx: Sensor details popup showing 7-day trend sparkline.Telemetry schema:
Spatial indexing & danger score integration:
<= 50 km, injectwater_level_cminto Issue 4's danger scoring function.> 50 km, flagsensor_fallback: truein cluster metadata.Map visualization:
> -20 cm): Blue dot (#38bdf8)-40 to -20 cm): Yellow dot (#facc15)< -40 cm): Pulsing red/white beacon (#ef4444) with animated radius ring.Acceptance criteria
GET /api/tmatreturns verified station array with numeric water levels.Blocked by
Issue 5: Live peat groundwater (TMAT) station overlay and risk factor integrationto Live peat groundwater (TMAT) station overlay and risk factor integration