Skip to content

Commit

Permalink
Bug fix: map not being shown after a fresh install, only after a zoom…
Browse files Browse the repository at this point in the history
… change.
  • Loading branch information
mcastillof committed Feb 6, 2021
1 parent 8dec566 commit 77cdfa9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions app/src/main/assets/map.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,17 @@

<script>
var map = L.map('map').fitWorld();
map.panTo(new L.LatLng(47, 15));
map.panTo(new L.LatLng(12, 15));
map.zoomIn(1);
var popup = L.popup();
var alreadyRunning = false;


L.tileLayer('https://api.mapbox.com/styles/v1/{id}/tiles/{z}/{x}/{y}?access_token=pk.eyJ1IjoibWFwYm94IiwiYSI6ImNpejY4NXVycTA2emYycXBndHRqcmZ3N3gifQ.rJcFIG214AriISLbB6B5aw', {
attribution: '© <a href="https://www.mapbox.com/about/maps/">Mapbox</a> © <a href="http://www.openstreetmap.org/copyright">OpenStreetMap</a> <strong><a href="https://www.mapbox.com/map-feedback/" target="_blank">Improve this map</a></strong>',
tileSize: 512,
maxZoom: 18,
minZoom: 1,
maxZoom: 17,
zoomOffset: -1,
id: 'mapbox/streets-v11',
accessToken: 'pk.eyJ1IjoibWFwYm94IiwiYSI6ImNpejY4NXVycTA2emYycXBndHRqcmZ3N3gifQ.rJcFIG214AriISLbB6B5aw'
Expand Down

0 comments on commit 77cdfa9

Please sign in to comment.