X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/15b104f4ff4614aa78c01180b6a9b89dd5a1400f..b10e0c46de55a97f8d44953a178ff41af07c8221:/app/assets/javascripts/leaflet.query.js?ds=sidebyside
diff --git a/app/assets/javascripts/leaflet.query.js b/app/assets/javascripts/leaflet.query.js
index 906487274..5f449c214 100644
--- a/app/assets/javascripts/leaflet.query.js
+++ b/app/assets/javascripts/leaflet.query.js
@@ -2,32 +2,32 @@ L.OSM.query = function (options) {
var control = L.control(options);
control.onAdd = function (map) {
- var $container = $('
')
- .attr('class', 'control-query');
+ var $container = $("
")
+ .attr("class", "control-query");
- var link = $('
')
- .attr('class', 'control-button')
- .attr('href', '#')
- .html('')
+ var link = $("")
+ .attr("class", "control-button")
+ .attr("href", "#")
+ .html("")
.appendTo($container);
- map.on('zoomend', update);
+ map.on("zoomend", update);
update();
function update() {
- var wasDisabled = link.hasClass('disabled'),
- isDisabled = map.getZoom() < 14;
+ var wasDisabled = link.hasClass("disabled"),
+ isDisabled = map.getZoom() < 14;
link
- .toggleClass('disabled', isDisabled)
- .attr('data-original-title', I18n.t(isDisabled ?
- 'javascripts.site.queryfeature_disabled_tooltip' :
- 'javascripts.site.queryfeature_tooltip'));
+ .toggleClass("disabled", isDisabled)
+ .attr("data-original-title", I18n.t(isDisabled ?
+ "javascripts.site.queryfeature_disabled_tooltip" :
+ "javascripts.site.queryfeature_tooltip"));
if (isDisabled && !wasDisabled) {
- link.trigger('disabled');
+ link.trigger("disabled");
} else if (wasDisabled && !isDisabled) {
- link.trigger('enabled');
+ link.trigger("enabled");
}
}