Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions app/javascript/maplibre/map.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ export async function initializeMap (divId = 'maplibre-map') {
interactive: (window.gon.map_mode !== 'static') // can move/zoom map
// style: {} // style/map is getting loaded by 'setBackgroundMapLayer'
})
if (!functions.isTestEnvironment()) { map.setZoom(map.getZoom() - 1) } // will zoom in on map:load
// if (!functions.isTestEnvironment()) { map.setZoom(map.getZoom() - 1) } // will zoom in on map:load

// for console debugging
window.map = map
Expand Down Expand Up @@ -115,7 +115,7 @@ export async function initializeMap (divId = 'maplibre-map') {
dom.initTooltips()
functions.e('#preloader', e => { e.classList.add('hidden') })
functions.e('.map', e => { e.setAttribute('data-map-loaded', true) })
if (!functions.isTestEnvironment()) { map.easeTo({ zoom: map.getZoom() + 1, duration: 1000 }) }
// if (!functions.isTestEnvironment()) { map.easeTo({ zoom: map.getZoom() + 1, duration: 1000 }) }
console.log("Map loaded ('load')")

const urlFeatureId = new URLSearchParams(window.location.search).get('f')
Expand Down
Loading