fix(geoportal): enrichment panel update + force-hide all layers + boundary filter

1. Enrichment: panel now updates immediately with returned data (was only showing message)
2. Layers: ALL data layers set to visibility:none immediately after creation,
   then only enabled ones are shown. Fixes cladiri appearing when only terenuri toggled.
3. OpenFreeMap boundaries: also filter by source-layer="boundary" (more reliable)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
AI Assistant
2026-03-24 13:45:29 +02:00
parent 48fe47d2c0
commit 19bed6724b
2 changed files with 25 additions and 11 deletions
@@ -76,7 +76,13 @@ export function FeatureInfoPanel({ feature, onClose }: FeatureInfoPanelProps) {
});
const d = await resp.json();
if (resp.ok) {
setEnrichMsg(d.message ?? "Enrichment pornit");
// Update panel with enrichment data immediately
if (d.enrichment && detail) {
setDetail({ ...detail, enrichment: d.enrichment, enrichedAt: new Date().toISOString() });
setEnrichMsg("");
} else {
setEnrichMsg(d.message ?? "Enrichment finalizat");
}
} else {
setEnrichMsg(d.error ?? "Eroare la enrichment");
}