Add 'canEmbed' layer option

This commit is contained in:
Anton Khorev 2024-12-18 18:36:44 +03:00
parent 2c84465cc2
commit 8a8c2517f2
2 changed files with 7 additions and 1 deletions

View file

@ -337,7 +337,8 @@ L.OSM.share = function (options) {
}
function update() {
var canEmbed = map.getMapBaseLayerId() !== "tracestracktopo";
const layer = map.getMapBaseLayer();
var canEmbed = layer && layer.options.canEmbed;
var bounds = map.getBounds();
$("#link_marker")