-//= require leaflet.locate
+//= require leaflet.locatecontrol/src/L.Control.Locate
$(document).ready(function () {
if ($("#map").length) {
iconLoading: "icon geolocate",
strings: {
title: I18n.t("javascripts.map.locate.title"),
- popup: I18n.t("javascripts.map.locate.popup")
+ popup: function (options) {
+ return I18n.t("javascripts.map.locate." + options.unit + "Popup", { count: options.distance });
+ }
}
}).addTo(map);