X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/0a046673d630a4618c27559875ce613465d85d3c..7f611b295f39b8c42219a5ce6c84582db74ce8f7:/app/assets/javascripts/leaflet.share.js diff --git a/app/assets/javascripts/leaflet.share.js b/app/assets/javascripts/leaflet.share.js index c096a92fc..40ba020e6 100644 --- a/app/assets/javascripts/leaflet.share.js +++ b/app/assets/javascripts/leaflet.share.js @@ -8,9 +8,10 @@ L.OSM.share = function (options) { control.onAddPane = function (map, button, $ui) { // Link / Embed + $("#content").addClass("overlay-right-sidebar"); var $linkSection = $("
") - .attr("class", "section share-link") + .attr("class", "share-link p-3 border-bottom border-secondary-subtle") .appendTo($ui); $("

") @@ -46,10 +47,13 @@ L.OSM.share = function (options) { .text(I18n.t("javascripts.share.short_link"))) .append($("") .attr("for", "embed_html") + .attr("id", "embed_link") + .attr("data-bs-title", I18n.t("javascripts.site.embed_html_disabled")) .attr("href", "#") .text(I18n.t("javascripts.share.embed"))) .on("click", "a", function (e) { e.preventDefault(); + if (!$(this).hasClass("btn-primary")) return; var id = "#" + $(this).attr("for"); $(this).siblings("a") .removeClass("active"); @@ -95,13 +99,13 @@ L.OSM.share = function (options) { .on("click", select)) .append( $("

") - .attr("class", "text-muted") + .attr("class", "text-body-secondary") .text(I18n.t("javascripts.share.paste_html"))); // Geo URI var $geoUriSection = $("

") - .attr("class", "section share-geo-uri") + .attr("class", "share-geo-uri p-3 border-bottom border-secondary-subtle") .appendTo($ui); $("

") @@ -116,7 +120,7 @@ L.OSM.share = function (options) { // Image var $imageSection = $("
") - .attr("class", "section share-image") + .attr("class", "share-image p-3") .appendTo($ui); $("

") @@ -125,7 +129,7 @@ L.OSM.share = function (options) { $("
") .attr("id", "export-warning") - .attr("class", "text-muted") + .attr("class", "text-body-secondary") .text(I18n.t("javascripts.share.only_standard_layer")) .appendTo($imageSection); @@ -156,6 +160,7 @@ L.OSM.share = function (options) { $("
") .appendTo($form) .attr("class", "row mb-3") + .attr("id", "mapnik_scale_row") .append($("