diff --git a/B04_wf1_Surface/B04_wf1_Surface_UI_MapViewer.ts b/B04_wf1_Surface/B04_wf1_Surface_UI_MapViewer.ts index 1b1aab8a..a5dac98e 100644 --- a/B04_wf1_Surface/B04_wf1_Surface_UI_MapViewer.ts +++ b/B04_wf1_Surface/B04_wf1_Surface_UI_MapViewer.ts @@ -135,8 +135,9 @@ export function createSurfaceMapViewer(): SurfaceMapViewer { let meta: VWorldMeta | null = null; const geoJsonLayers = new Map(); const activeBackgrounds = new Set(BACKGROUND_LAYERS); - const activeGisLayers = new Set(GIS_LAYERS); - let showContourLabels = false; + // gpkg 등고선은 기본 꺼짐(도엽 등고선이 기본 표기), 등고 라벨은 기본 켜짐 (2026-07-26 사용자 지시) + const activeGisLayers = new Set(GIS_LAYERS.filter((layer) => layer !== "등고선")); + let showContourLabels = true; let scale = 1; let offsetX = 0; let offsetY = 0; @@ -151,9 +152,10 @@ export function createSurfaceMapViewer(): SurfaceMapViewer { ): HTMLButtonElement { const button = document.createElement("button"); button.type = "button"; - button.className = "b04-map__layer-button is-active"; + const initialActive = activeLayers.has(layer); + button.className = "b04-map__layer-button" + (initialActive ? " is-active" : ""); button.textContent = label; - button.setAttribute("aria-pressed", "true"); + button.setAttribute("aria-pressed", String(initialActive)); if (color) { button.classList.add("b04-map__layer-button--gis"); button.style.setProperty("--b04-layer-color", color); @@ -196,12 +198,12 @@ export function createSurfaceMapViewer(): SurfaceMapViewer { ); }); - // 등고 라벨 보기/숨기기 (기본 숨김 — 등고선·도엽 등고선의 계곡선 수치 표기) + // 등고 라벨 보기/숨기기 (기본 켜짐 — 등고선·도엽 등고선의 계곡선 수치 표기) const contourLabelButton = document.createElement("button"); contourLabelButton.type = "button"; - contourLabelButton.className = "b04-map__layer-button"; + contourLabelButton.className = "b04-map__layer-button is-active"; contourLabelButton.textContent = L("B04_Surface_Map_ContourLabel"); - contourLabelButton.setAttribute("aria-pressed", "false"); + contourLabelButton.setAttribute("aria-pressed", "true"); contourLabelButton.addEventListener("click", () => { showContourLabels = !showContourLabels; contourLabelButton.classList.toggle("is-active", showContourLabels);