Skip to content

Commit

Permalink
Update main.js
Browse files Browse the repository at this point in the history
  • Loading branch information
ZsoltMONOLITE authored Nov 29, 2023
1 parent 6d5f594 commit 4258cf5
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,9 @@ function addGeoms(data) {
// This zooms the map to the clicked geometry
// Uncomment to enable
// map.fitBounds(e.target.getBounds());
//map.fitBounds(e.target.getBounds());

// if this isn't added, then map.click is also fired!
L.DomEvent.stopPropagation(e, 'click');
L.DomEvent.stopPropagation(e);

document.getElementById("sidebar-title").innerHTML =
e.target.feature.properties.name;
Expand Down Expand Up @@ -168,7 +167,7 @@ function addPoints(data) {
marker.addTo(pointGroupLayer);

// UNCOMMENT THIS LINE TO USE POPUPS
marker.bindPopup('<h2>' + data[row].name + '</h2>There's a ' + data[row].description + ' here');
//marker.bindPopup('<h2>' + data[row].name + '</h2>There's a ' + data[row].description + ' here');

// COMMENT THE NEXT GROUP OF LINES TO DISABLE SIDEBAR FOR THE MARKERS
marker.feature = {
Expand Down

0 comments on commit 4258cf5

Please sign in to comment.