Tweak: change zoom behaviour when jumping to the current location
This commit is contained in:
parent
d8a87abbf6
commit
bc8b42d49e
1 changed files with 2 additions and 1 deletions
|
@ -138,7 +138,8 @@ export default class GeoLocationHandler {
|
||||||
lat: newLocation.latitude,
|
lat: newLocation.latitude,
|
||||||
})
|
})
|
||||||
const zoom = this.mapProperties.zoom
|
const zoom = this.mapProperties.zoom
|
||||||
zoom.setData(Math.max(zoom.data, 16))
|
zoom.setData(Math.min(Math.max(zoom.data, 14), 18))
|
||||||
|
|
||||||
this.mapHasMoved.setData(new Date())
|
this.mapHasMoved.setData(new Date())
|
||||||
this.geolocationState.requestMoment.setData(undefined)
|
this.geolocationState.requestMoment.setData(undefined)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue