opacity: 0.7
});
- marker.addTo(noteLayer).bindPopup(popupContent);
+ marker.addTo(noteLayer).bindPopup(popupContent, popupOptions());
}
return marker;
});
};
+ function popupOptions() {
+ var mapSize = map.getSize();
+
+ return { maxHeight: mapSize.y * 2 / 3 };
+ }
+
function createPopupContent(marker, properties) {
var content = $(JST["templates/notes/show"]({ note: properties }));
createNote(marker, e.target.form, $(e.target).data("url"));
});
- marker.addTo(noteLayer).bindPopup(popupContent[0]).openPopup();
+ marker.addTo(noteLayer).bindPopup(popupContent[0], popupOptions()).openPopup();
$(".leaflet-popup-close-button").on("click.close", function (e) {
map.removeLayer(marker);
left: 10px !important;
}
+.leaflet-popup-scrolled {
+ padding-right: 20px;
+ border-bottom: 0px !important;
+ border-top: 0px !important;
+}
+
/* Rules for edit menu */
.menuicon {