More reasonable limitations for min zoom, remove white borders

This commit is contained in:
Tom MacWright
2012-12-03 12:48:39 -05:00
parent 71e0e9d96a
commit 40fdbb0767
2 changed files with 3 additions and 3 deletions

View File

@@ -30,8 +30,8 @@ iD.Background = function() {
Math.round((d[0] * ts) - tile_origin[0]) + ',' +
Math.round((d[1] * ts) - tile_origin[1]) + ')';
})
.attr("width", ts)
.attr("height", ts);
.attr("width", Math.ceil(ts))
.attr("height", Math.ceil(ts));
}
background.projection = function(_) {

View File

@@ -10,7 +10,7 @@ iD.Map = function() {
zoom = d3.behavior.zoom()
.translate(projection.translate())
.scale(projection.scale())
.scaleExtent([256, 256 * Math.pow(2, 20)])
.scaleExtent([1024, 256 * Math.pow(2, 20)])
.on('zoom', zoomPan),
only,
dblclickEnabled = true,