Skip to content

Commit

Permalink
zoom out on search
Browse files Browse the repository at this point in the history
  • Loading branch information
nin-jin committed Nov 14, 2023
1 parent b9572b7 commit 7ab3c0c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion map.view.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ namespace $.$$ {

const offset = this.center_offset()
const pane = this.Pane()
const zoom = 180 * this.zoom_limit().min / res.box.transponed().map( p => pane.geo_to_tile(p) ).distance()
const zoom = 90 * this.zoom_limit().min / res.box.transponed().map( p => pane.geo_to_tile(p) ).distance()
const center = pane.geo_to_tile( res.coord ).multed0( -zoom ).added1( offset )

this.zoom( zoom )
Expand Down

0 comments on commit 7ab3c0c

Please sign in to comment.