]> git.openstreetmap.org Git - rails.git/commitdiff
Fix marker paths for embedded map
authorTom Hughes <tom@compton.nu>
Mon, 10 Aug 2020 17:20:23 +0000 (18:20 +0100)
committerTom Hughes <tom@compton.nu>
Mon, 10 Aug 2020 17:20:23 +0000 (18:20 +0100)
Fixes #2763

app/assets/javascripts/embed.js.erb

index e76b6c356661761fdcd7837b4d4e2d0a8bde8bf0..947c377be7ee41c214e1d787f4e130606080cc50 100644 (file)
@@ -43,10 +43,10 @@ window.onload = function () {
 
   if (args.marker) {
     L.marker(args.marker.split(','), {icon: L.icon({
 
   if (args.marker) {
     L.marker(args.marker.split(','), {icon: L.icon({
-      iconUrl: <%= asset_path('images/marker-icon.png').to_json %>,
+      iconUrl: <%= asset_path('leaflet/dist/images/marker-icon.png').to_json %>,
       iconSize: new L.Point(25, 41),
       iconAnchor: new L.Point(12, 41),
       iconSize: new L.Point(25, 41),
       iconAnchor: new L.Point(12, 41),
-      shadowUrl: <%= asset_path('images/marker-shadow.png').to_json %>,
+      shadowUrl: <%= asset_path('leaflet/dist/images/marker-shadow.png').to_json %>,
       shadowSize: new L.Point(41, 41)
     })}).addTo(map);
   }
       shadowSize: new L.Point(41, 41)
     })}).addTo(map);
   }