From 7f4d1f788895b7b5c520f7a3c717e38c4ccaaa03 Mon Sep 17 00:00:00 2001 From: Wentao Kuang Date: Wed, 18 Dec 2024 09:08:09 +1300 Subject: [PATCH] feat(landing): Add topo-raster into layer dropdown. BM-1153 (#3382) ### Motivation We need to add topo-raster style into the layer dropdown and have the labels disabled for it. ### Modifications Add another hardcode topo-raster style for the layer dropdown. We will need to clean up all the hardcode category in BM-1154 ### Verification ![image](https://github.com/user-attachments/assets/67bd2eac-97f9-41e0-a63b-b788ac5b27e5) --- packages/landing/src/components/map.label.tsx | 2 +- packages/landing/src/config.map.ts | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/packages/landing/src/components/map.label.tsx b/packages/landing/src/components/map.label.tsx index 9a94e1711..62b033893 100644 --- a/packages/landing/src/components/map.label.tsx +++ b/packages/landing/src/components/map.label.tsx @@ -2,7 +2,7 @@ import { IControl } from 'maplibre-gl'; import { Config, GaEvent, gaEvent } from '../config.js'; -export const LabelsDisabledLayers = new Set(['topographic', 'topolite']); +export const LabelsDisabledLayers = new Set(['topographic', 'topolite', 'topo-raster']); export class MapLabelControl implements IControl { map?: maplibregl.Map; diff --git a/packages/landing/src/config.map.ts b/packages/landing/src/config.map.ts index 2d0a899fe..23c957462 100644 --- a/packages/landing/src/config.map.ts +++ b/packages/landing/src/config.map.ts @@ -404,6 +404,13 @@ function addDefaultLayers(output: Map): void { category: 'Basemaps', }, + { + id: 'topo-raster::topo-raster', + title: 'NZ Topo Gridless Maps', + projections: new Set([EpsgCode.Nztm2000, EpsgCode.Google]), + category: 'Basemaps', + }, + { id: 'elevation', title: 'Elevation',