diff --git a/src/components/SpotMap.tsx b/src/components/SpotMap.tsx index 13d8027..c72bc86 100644 --- a/src/components/SpotMap.tsx +++ b/src/components/SpotMap.tsx @@ -662,11 +662,18 @@ export function SpotMap({ center, zoom, scrollWheelZoom: true, - attributionControl: false, // Remove attribution control + attributionControl: false, + // Prevent zooming out past a single world view (no grey space, no tile duplication) + minZoom: 2, + // Clamp panning so the world fills the viewport — no grey bands above/below + maxBounds: [[-90, -Infinity], [90, Infinity]], + maxBoundsViscosity: 1.0, }); L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', { - attribution: '', // Remove attribution text + attribution: '', + // Match minZoom so tiles are always available at the minimum zoom level + minZoom: 2, }).addTo(map); // Add click handler if enabled