feat: operationalize Flemish land and nature themes
GeoIntel CI / docs-smoke (push) Canceled after 0s
GeoIntel CI / contract-smoke (push) Canceled after 0s

This commit is contained in:
Codex
2026-07-17 22:38:25 +02:00
parent 0718d0ebba
commit c787fb2184
27 changed files with 2010 additions and 12 deletions
@@ -6,7 +6,7 @@ import { terrainSelectionToMapSelection } from '../lib/terrainSelection'
import { floodHazardSelectionToMapSelection } from '../lib/floodHazardSelection'
import { thematicRasterSelectionToMapSelection } from '../lib/thematicRaster'
export type MapThemeAcquisitionKind = 'thematic_raster' | 'dhmv' | 'flood_hazard' | 'grb'
export type MapThemeAcquisitionKind = 'thematic_raster' | 'dhmv' | 'flood_hazard' | 'grb' | 'official_vector'
export interface MapThemeAcquisition {
kind: MapThemeAcquisitionKind
@@ -92,10 +92,15 @@ export function useMapThemeSelectionInsights<TThemeId extends string>(
...commonPayload,
product_key: acquisition.productKey,
})
: await datasetsApi.acquireGrb(selectedProjectId, {
...commonPayload,
product_key: acquisition.productKey as 'buildings' | 'roads' | 'water' | 'parcels',
})
: acquisition.kind === 'grb'
? await datasetsApi.acquireGrb(selectedProjectId, {
...commonPayload,
product_key: acquisition.productKey as 'buildings' | 'roads' | 'water' | 'parcels',
})
: await datasetsApi.acquireOfficialVector(selectedProjectId, {
...commonPayload,
product_key: acquisition.productKey,
})
if (acquisitionJob.status !== 'success' || !acquisitionJob.output_dataset_id) {
throw new Error(
acquisitionJob.error_message
+6 -1
View File
@@ -5,6 +5,7 @@ import type {
DhmvProductRead,
FloodHazardProductRead,
GrbProductRead,
OfficialVectorProductRead,
ThematicRasterProductRead,
} from '../types'
@@ -13,6 +14,7 @@ interface OfficialMapProducts {
dhmv: DhmvProductRead[]
floodHazard: FloodHazardProductRead[]
grb: GrbProductRead[]
officialVector: OfficialVectorProductRead[]
}
const EMPTY_PRODUCTS: OfficialMapProducts = {
@@ -20,6 +22,7 @@ const EMPTY_PRODUCTS: OfficialMapProducts = {
dhmv: [],
floodHazard: [],
grb: [],
officialVector: [],
}
export function useOfficialMapProducts(selectedProjectId: string | null) {
@@ -45,14 +48,16 @@ export function useOfficialMapProducts(selectedProjectId: string | null) {
datasetsApi.listDhmvProducts(selectedProjectId),
datasetsApi.listFloodHazardProducts(selectedProjectId),
datasetsApi.listGrbProducts(selectedProjectId),
datasetsApi.listOfficialVectorProducts(selectedProjectId),
])
.then(([thematic, dhmv, floodHazard, grb]) => {
.then(([thematic, dhmv, floodHazard, grb, officialVector]) => {
if (!cancelled) {
setProducts({
thematic: thematic.items,
dhmv: dhmv.items,
floodHazard: floodHazard.items,
grb: grb.items,
officialVector: officialVector.items,
})
}
})