Skip to content

Commit

Permalink
Replace Mapbox-based MakiMarkers with local book icon (#637)
Browse files Browse the repository at this point in the history
Mapbox is no longer free, new free icon is from https://mappity.org
  • Loading branch information
fsteeg committed Jan 23, 2024
1 parent a69b8e2 commit 211782e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions app/views/tags/items_map.scala.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@

<link rel="stylesheet" href="@controllers.routes.Assets.at("stylesheets/leaflet.css")" />
<script src="@controllers.routes.Assets.at("javascripts/leaflet.js")"></script>
<script src="@controllers.routes.Assets.at("javascripts/Leaflet.MakiMarkers.js")"></script>
@*<script type="text/javascript" src="http://maps.stamen.com/js/tile.stamen.js?v1.2.4"></script>*@
<table class="table table-striped table-condensed">
<tr>
Expand Down Expand Up @@ -90,7 +89,11 @@
var lat = @string((json \\ "lat").head)
var lon = @string((json \\ "lon").head)
var latlng@(id) = L.latLng(lat, lon);
var icon@(id) = L.MakiMarkers.icon({icon: "library", color: "#FF333B", size: "m"});
var icon@(id) = L.icon({
iconUrl: '@controllers.routes.Assets.at("javascripts/images/marker-icon-book.png")',
iconSize: [30, 30],
popupAnchor: [0, -15]
});
var marker@(id) = L.marker([lat, lon],{
title: "@ownerName (@key)",
icon: icon@(id)
Expand Down
Binary file added public/javascripts/images/marker-icon-book.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 211782e

Please sign in to comment.