From 409f20f8cc925bfffb7375c99e2f06f3a83d7b70 Mon Sep 17 00:00:00 2001 From: gman Date: Sat, 16 Dec 2023 12:51:35 +0300 Subject: [PATCH] center popup on point --- frontend/src/components/MapComponent.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/components/MapComponent.vue b/frontend/src/components/MapComponent.vue index d3ec75c..1ab4433 100644 --- a/frontend/src/components/MapComponent.vue +++ b/frontend/src/components/MapComponent.vue @@ -154,7 +154,7 @@ export default { // Populate the popup and set its coordinates // based on the feature found. popup - .setLngLat(e.lngLat) + .setLngLat(e.features[0].geometry.coordinates) .setHTML(`Записей в точке: ${e.features.length}`) .addTo(map.value); });