From 31dffb9b4a3afa2c1782f869eb0cb0b55c4e18f5 Mon Sep 17 00:00:00 2001 From: Ngole Lawson Date: Sat, 2 May 2026 16:36:36 +0100 Subject: [PATCH 1/2] hotfix: add polygon map layers for 7 campaigns via local GeoJSON MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Implements Issue #207 — Add polygon/map layer for each campaign. Adds 7 GeoJSON fixture files to public/fixtures/ that are automatically discovered by the existing fixture-reader.ts (import.meta.glob pattern). No code changes required — the layer controls will show the new campaign layers as toggleable items. New fixture files: - campaign_rio_negro_conservation.geojson (18,500 acres, River Conservation) - campaign_solimoes_wetland.geojson (22,000 acres, Wetland Restoration) - campaign_taruma_corridor.geojson (9,800 acres, Wildlife Corridor) - campaign_encontro_das_aguas.geojson (31,000 acres, Ecological Reserve) - campaign_ducke_forest.geojson (10,000 acres, Research Station) - campaign_puraquequara_lake.geojson (7,500 acres, Lake Protection) - campaign_anavilhanas_archipelago.geojson (42,000 acres, Environmental Monitoring) Each GeoJSON follows the existing fixture format: - type: FeatureCollection with CRS header - name: 'Campaign: ' for layer control display - features: Polygon geometry with campaign properties (name, status, partner, acreage, watershed, projectType) All polygons are positioned around the Manaus region to be visible on the existing map view centered at -3.1319, -60.0261. --- .../campaign_anavilhanas_archipelago.geojson | 35 +++++++++++++++++++ public/fixtures/campaign_ducke_forest.geojson | 34 ++++++++++++++++++ .../campaign_encontro_das_aguas.geojson | 35 +++++++++++++++++++ .../campaign_puraquequara_lake.geojson | 34 ++++++++++++++++++ .../campaign_rio_negro_conservation.geojson | 34 ++++++++++++++++++ .../campaign_solimoes_wetland.geojson | 34 ++++++++++++++++++ .../fixtures/campaign_taruma_corridor.geojson | 34 ++++++++++++++++++ 7 files changed, 240 insertions(+) create mode 100644 public/fixtures/campaign_anavilhanas_archipelago.geojson create mode 100644 public/fixtures/campaign_ducke_forest.geojson create mode 100644 public/fixtures/campaign_encontro_das_aguas.geojson create mode 100644 public/fixtures/campaign_puraquequara_lake.geojson create mode 100644 public/fixtures/campaign_rio_negro_conservation.geojson create mode 100644 public/fixtures/campaign_solimoes_wetland.geojson create mode 100644 public/fixtures/campaign_taruma_corridor.geojson diff --git a/public/fixtures/campaign_anavilhanas_archipelago.geojson b/public/fixtures/campaign_anavilhanas_archipelago.geojson new file mode 100644 index 0000000..87f4590 --- /dev/null +++ b/public/fixtures/campaign_anavilhanas_archipelago.geojson @@ -0,0 +1,35 @@ +{ + "type": "FeatureCollection", + "name": "Campaign: Anavilhanas Archipelago Monitoring", + "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } }, + "features": [ + { + "type": "Feature", + "id": "anavilhanas-1", + "properties": { + "id": "anavilhanas-1", + "name": "Anavilhanas Archipelago Monitoring", + "campaign": "Anavilhanas Archipelago Monitoring", + "status": "active", + "partner": "ICMBio Brazil", + "acreage": 42000, + "watershed": "Rio Negro Archipelago", + "projectType": "Environmental Monitoring" + }, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [-60.1800, -2.9600], + [-60.1200, -2.9400], + [-60.0800, -2.9700], + [-60.0900, -3.0000], + [-60.1400, -3.0100], + [-60.1800, -2.9900], + [-60.1800, -2.9600] + ] + ] + } + } + ] +} diff --git a/public/fixtures/campaign_ducke_forest.geojson b/public/fixtures/campaign_ducke_forest.geojson new file mode 100644 index 0000000..2377113 --- /dev/null +++ b/public/fixtures/campaign_ducke_forest.geojson @@ -0,0 +1,34 @@ +{ + "type": "FeatureCollection", + "name": "Campaign: Ducke Forest Research", + "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } }, + "features": [ + { + "type": "Feature", + "id": "ducke-1", + "properties": { + "id": "ducke-1", + "name": "Ducke Forest Research", + "campaign": "Ducke Forest Research", + "status": "active", + "partner": "INPA Research Institute", + "acreage": 10000, + "watershed": "Upper Taruma Basin", + "projectType": "Research Station" + }, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [-59.9700, -2.9500], + [-59.9200, -2.9500], + [-59.9200, -2.9900], + [-59.9400, -3.0100], + [-59.9700, -3.0000], + [-59.9700, -2.9500] + ] + ] + } + } + ] +} diff --git a/public/fixtures/campaign_encontro_das_aguas.geojson b/public/fixtures/campaign_encontro_das_aguas.geojson new file mode 100644 index 0000000..d026bed --- /dev/null +++ b/public/fixtures/campaign_encontro_das_aguas.geojson @@ -0,0 +1,35 @@ +{ + "type": "FeatureCollection", + "name": "Campaign: Encontro das Aguas Reserve", + "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } }, + "features": [ + { + "type": "Feature", + "id": "encontro-1", + "properties": { + "id": "encontro-1", + "name": "Encontro das Aguas Reserve", + "campaign": "Encontro das Aguas Reserve", + "status": "active", + "partner": "Meeting of the Waters Foundation", + "acreage": 31000, + "watershed": "Negro-Solimoes Confluence", + "projectType": "Ecological Reserve" + }, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [-59.9800, -3.0800], + [-59.9200, -3.0800], + [-59.9000, -3.1100], + [-59.9200, -3.1400], + [-59.9600, -3.1400], + [-59.9800, -3.1200], + [-59.9800, -3.0800] + ] + ] + } + } + ] +} diff --git a/public/fixtures/campaign_puraquequara_lake.geojson b/public/fixtures/campaign_puraquequara_lake.geojson new file mode 100644 index 0000000..80d974b --- /dev/null +++ b/public/fixtures/campaign_puraquequara_lake.geojson @@ -0,0 +1,34 @@ +{ + "type": "FeatureCollection", + "name": "Campaign: Puraquequara Lake Protection", + "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } }, + "features": [ + { + "type": "Feature", + "id": "puraquequara-1", + "properties": { + "id": "puraquequara-1", + "name": "Puraquequara Lake Protection", + "campaign": "Puraquequara Lake Protection", + "status": "planning", + "partner": "Manaus Environmental Agency", + "acreage": 7500, + "watershed": "Puraquequara Lake System", + "projectType": "Lake Protection" + }, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [-59.9200, -3.0200], + [-59.8800, -3.0200], + [-59.8700, -3.0500], + [-59.8900, -3.0700], + [-59.9200, -3.0600], + [-59.9200, -3.0200] + ] + ] + } + } + ] +} diff --git a/public/fixtures/campaign_rio_negro_conservation.geojson b/public/fixtures/campaign_rio_negro_conservation.geojson new file mode 100644 index 0000000..153848d --- /dev/null +++ b/public/fixtures/campaign_rio_negro_conservation.geojson @@ -0,0 +1,34 @@ +{ + "type": "FeatureCollection", + "name": "Campaign: Rio Negro Conservation", + "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } }, + "features": [ + { + "type": "Feature", + "id": "rio-negro-1", + "properties": { + "id": "rio-negro-1", + "name": "Rio Negro Conservation", + "campaign": "Rio Negro Conservation", + "status": "active", + "partner": "Amazon River Foundation", + "acreage": 18500, + "watershed": "Rio Negro Basin", + "projectType": "River Conservation" + }, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [-60.1200, -3.0500], + [-60.0600, -3.0500], + [-60.0600, -3.0900], + [-60.0800, -3.1100], + [-60.1200, -3.1100], + [-60.1200, -3.0500] + ] + ] + } + } + ] +} diff --git a/public/fixtures/campaign_solimoes_wetland.geojson b/public/fixtures/campaign_solimoes_wetland.geojson new file mode 100644 index 0000000..63b9f97 --- /dev/null +++ b/public/fixtures/campaign_solimoes_wetland.geojson @@ -0,0 +1,34 @@ +{ + "type": "FeatureCollection", + "name": "Campaign: Solimoes Wetland Restoration", + "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } }, + "features": [ + { + "type": "Feature", + "id": "solimoes-1", + "properties": { + "id": "solimoes-1", + "name": "Solimoes Wetland Restoration", + "campaign": "Solimoes Wetland Restoration", + "status": "active", + "partner": "Wetlands International", + "acreage": 22000, + "watershed": "Solimoes Watershed", + "projectType": "Wetland Restoration" + }, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [-60.0800, -3.1400], + [-60.0200, -3.1400], + [-60.0200, -3.1800], + [-60.0500, -3.2000], + [-60.0800, -3.1900], + [-60.0800, -3.1400] + ] + ] + } + } + ] +} diff --git a/public/fixtures/campaign_taruma_corridor.geojson b/public/fixtures/campaign_taruma_corridor.geojson new file mode 100644 index 0000000..8795808 --- /dev/null +++ b/public/fixtures/campaign_taruma_corridor.geojson @@ -0,0 +1,34 @@ +{ + "type": "FeatureCollection", + "name": "Campaign: Taruma Biodiversity Corridor", + "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } }, + "features": [ + { + "type": "Feature", + "id": "taruma-1", + "properties": { + "id": "taruma-1", + "name": "Taruma Biodiversity Corridor", + "campaign": "Taruma Biodiversity Corridor", + "status": "planning", + "partner": "Biodiversity Alliance Brazil", + "acreage": 9800, + "watershed": "Taruma-Acu Basin", + "projectType": "Wildlife Corridor" + }, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [-60.1000, -3.0100], + [-60.0500, -3.0100], + [-60.0500, -3.0500], + [-60.0700, -3.0600], + [-60.1000, -3.0500], + [-60.1000, -3.0100] + ] + ] + } + } + ] +} From 56f21e4ed1265dbbc45058b4b2c9b6e1d13e0248 Mon Sep 17 00:00:00 2001 From: Ngole Lawson Date: Tue, 5 May 2026 23:13:05 +0100 Subject: [PATCH 2/2] refactor: Align GeoJSON feature properties with unified schema Standardize property names across campaign fixtures to match the shared FeatureProperties interface agreed with Glenn (DietBepis1): - name -> identifier (avoids collision with FeatureCollection name) - partner -> partners (string array, supports multiple) - acreage -> measurement + unitOfMeasure (flexible units) - watershed -> watershedRegion (more descriptive) - Add restorationServices (empty array, ready for future data) - Keep: id, campaign, status, projectType (unique to campaigns) --- .../campaign_anavilhanas_archipelago.geojson | 12 +++++++----- public/fixtures/campaign_ducke_forest.geojson | 12 +++++++----- public/fixtures/campaign_encontro_das_aguas.geojson | 12 +++++++----- public/fixtures/campaign_puraquequara_lake.geojson | 12 +++++++----- .../fixtures/campaign_rio_negro_conservation.geojson | 12 +++++++----- public/fixtures/campaign_solimoes_wetland.geojson | 12 +++++++----- public/fixtures/campaign_taruma_corridor.geojson | 12 +++++++----- 7 files changed, 49 insertions(+), 35 deletions(-) diff --git a/public/fixtures/campaign_anavilhanas_archipelago.geojson b/public/fixtures/campaign_anavilhanas_archipelago.geojson index 87f4590..cdb72c5 100644 --- a/public/fixtures/campaign_anavilhanas_archipelago.geojson +++ b/public/fixtures/campaign_anavilhanas_archipelago.geojson @@ -8,13 +8,15 @@ "id": "anavilhanas-1", "properties": { "id": "anavilhanas-1", - "name": "Anavilhanas Archipelago Monitoring", + "identifier": "Anavilhanas Archipelago Monitoring", "campaign": "Anavilhanas Archipelago Monitoring", "status": "active", - "partner": "ICMBio Brazil", - "acreage": 42000, - "watershed": "Rio Negro Archipelago", - "projectType": "Environmental Monitoring" + "partners": ["ICMBio Brazil"], + "measurement": 42000, + "unitOfMeasure": "acre", + "watershedRegion": "Rio Negro Archipelago", + "projectType": "Environmental Monitoring", + "restorationServices": [] }, "geometry": { "type": "Polygon", diff --git a/public/fixtures/campaign_ducke_forest.geojson b/public/fixtures/campaign_ducke_forest.geojson index 2377113..666234f 100644 --- a/public/fixtures/campaign_ducke_forest.geojson +++ b/public/fixtures/campaign_ducke_forest.geojson @@ -8,13 +8,15 @@ "id": "ducke-1", "properties": { "id": "ducke-1", - "name": "Ducke Forest Research", + "identifier": "Ducke Forest Research", "campaign": "Ducke Forest Research", "status": "active", - "partner": "INPA Research Institute", - "acreage": 10000, - "watershed": "Upper Taruma Basin", - "projectType": "Research Station" + "partners": ["INPA Research Institute"], + "measurement": 10000, + "unitOfMeasure": "acre", + "watershedRegion": "Upper Taruma Basin", + "projectType": "Research Station", + "restorationServices": [] }, "geometry": { "type": "Polygon", diff --git a/public/fixtures/campaign_encontro_das_aguas.geojson b/public/fixtures/campaign_encontro_das_aguas.geojson index d026bed..1ec45f5 100644 --- a/public/fixtures/campaign_encontro_das_aguas.geojson +++ b/public/fixtures/campaign_encontro_das_aguas.geojson @@ -8,13 +8,15 @@ "id": "encontro-1", "properties": { "id": "encontro-1", - "name": "Encontro das Aguas Reserve", + "identifier": "Encontro das Aguas Reserve", "campaign": "Encontro das Aguas Reserve", "status": "active", - "partner": "Meeting of the Waters Foundation", - "acreage": 31000, - "watershed": "Negro-Solimoes Confluence", - "projectType": "Ecological Reserve" + "partners": ["Meeting of the Waters Foundation"], + "measurement": 31000, + "unitOfMeasure": "acre", + "watershedRegion": "Negro-Solimoes Confluence", + "projectType": "Ecological Reserve", + "restorationServices": [] }, "geometry": { "type": "Polygon", diff --git a/public/fixtures/campaign_puraquequara_lake.geojson b/public/fixtures/campaign_puraquequara_lake.geojson index 80d974b..aa0e3cb 100644 --- a/public/fixtures/campaign_puraquequara_lake.geojson +++ b/public/fixtures/campaign_puraquequara_lake.geojson @@ -8,13 +8,15 @@ "id": "puraquequara-1", "properties": { "id": "puraquequara-1", - "name": "Puraquequara Lake Protection", + "identifier": "Puraquequara Lake Protection", "campaign": "Puraquequara Lake Protection", "status": "planning", - "partner": "Manaus Environmental Agency", - "acreage": 7500, - "watershed": "Puraquequara Lake System", - "projectType": "Lake Protection" + "partners": ["Manaus Environmental Agency"], + "measurement": 7500, + "unitOfMeasure": "acre", + "watershedRegion": "Puraquequara Lake System", + "projectType": "Lake Protection", + "restorationServices": [] }, "geometry": { "type": "Polygon", diff --git a/public/fixtures/campaign_rio_negro_conservation.geojson b/public/fixtures/campaign_rio_negro_conservation.geojson index 153848d..21da7a2 100644 --- a/public/fixtures/campaign_rio_negro_conservation.geojson +++ b/public/fixtures/campaign_rio_negro_conservation.geojson @@ -8,13 +8,15 @@ "id": "rio-negro-1", "properties": { "id": "rio-negro-1", - "name": "Rio Negro Conservation", + "identifier": "Rio Negro Conservation", "campaign": "Rio Negro Conservation", "status": "active", - "partner": "Amazon River Foundation", - "acreage": 18500, - "watershed": "Rio Negro Basin", - "projectType": "River Conservation" + "partners": ["Amazon River Foundation"], + "measurement": 18500, + "unitOfMeasure": "acre", + "watershedRegion": "Rio Negro Basin", + "projectType": "River Conservation", + "restorationServices": [] }, "geometry": { "type": "Polygon", diff --git a/public/fixtures/campaign_solimoes_wetland.geojson b/public/fixtures/campaign_solimoes_wetland.geojson index 63b9f97..a421f3e 100644 --- a/public/fixtures/campaign_solimoes_wetland.geojson +++ b/public/fixtures/campaign_solimoes_wetland.geojson @@ -8,13 +8,15 @@ "id": "solimoes-1", "properties": { "id": "solimoes-1", - "name": "Solimoes Wetland Restoration", + "identifier": "Solimoes Wetland Restoration", "campaign": "Solimoes Wetland Restoration", "status": "active", - "partner": "Wetlands International", - "acreage": 22000, - "watershed": "Solimoes Watershed", - "projectType": "Wetland Restoration" + "partners": ["Wetlands International"], + "measurement": 22000, + "unitOfMeasure": "acre", + "watershedRegion": "Solimoes Watershed", + "projectType": "Wetland Restoration", + "restorationServices": [] }, "geometry": { "type": "Polygon", diff --git a/public/fixtures/campaign_taruma_corridor.geojson b/public/fixtures/campaign_taruma_corridor.geojson index 8795808..5ffec94 100644 --- a/public/fixtures/campaign_taruma_corridor.geojson +++ b/public/fixtures/campaign_taruma_corridor.geojson @@ -8,13 +8,15 @@ "id": "taruma-1", "properties": { "id": "taruma-1", - "name": "Taruma Biodiversity Corridor", + "identifier": "Taruma Biodiversity Corridor", "campaign": "Taruma Biodiversity Corridor", "status": "planning", - "partner": "Biodiversity Alliance Brazil", - "acreage": 9800, - "watershed": "Taruma-Acu Basin", - "projectType": "Wildlife Corridor" + "partners": ["Biodiversity Alliance Brazil"], + "measurement": 9800, + "unitOfMeasure": "acre", + "watershedRegion": "Taruma-Acu Basin", + "projectType": "Wildlife Corridor", + "restorationServices": [] }, "geometry": { "type": "Polygon",