We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 832714d commit 5b6b235Copy full SHA for 5b6b235
1 file changed
pcd-website/src/components/MapView.vue
@@ -431,7 +431,12 @@ onMounted(async () => {
431
}
432
});
433
434
- if (foundNode) panToKeepInView(foundNode.lat, foundNode.lng);
+ if (foundNode) {
435
+ const lat = foundNode.lat;
436
+ const lng = foundNode.lng;
437
+ // Defer past Leaflet's own focus/keyboard handlers that may pan synchronously
438
+ requestAnimationFrame(() => panToKeepInView(lat, lng));
439
+ }
440
};
441
map.getContainer().addEventListener('focusin', slidingWindowHandler);
442
0 commit comments