From 4983e0ad91dc0d8dea6e79754e83f0c52e7ed5d2 Mon Sep 17 00:00:00 2001 From: Code WvS Date: Mon, 23 Mar 2015 19:36:24 +0100 Subject: use maxZoom and maxNativeZoom (experimental) --- snap.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/snap.html b/snap.html index f5741a4..8b2e2e1 100755 --- a/snap.html +++ b/snap.html @@ -83,6 +83,7 @@ // initialize leaflet map = L.map('map', { + maxZoom: 21, keyboard: false, closePopupOnClick: false }); @@ -107,6 +108,7 @@ layer = L.tileLayer('http://api.tiles.mapbox.com/v4/mapbox.streets/{z}/{x}/{y}@2x.png?access_token=pk.eyJ1IjoiY29kZS13dnMiLCJhIjoielU1N2dQayJ9.miUjtJaW7Y_Xx46dC6m0LA', { useCache: true, cacheMaxAge: 604800000, // one week + maxNativeZoom: 19, attribution: '© OpenStreetMap contributors' }); new OSMBuildings(map).load(); @@ -116,6 +118,7 @@ layer = L.tileLayer('http://api.tiles.mapbox.com/v4/mapbox.streets/{z}/{x}/{y}.jpg70?access_token=pk.eyJ1IjoiY29kZS13dnMiLCJhIjoielU1N2dQayJ9.miUjtJaW7Y_Xx46dC6m0LA', { useCache: true, cacheMaxAge: 604800000, // one week + maxNativeZoom: 19, attribution: '© OpenStreetMap contributors' }); // shit, we're offline - let's hope there is something cached @@ -125,6 +128,7 @@ useCache: true, useOnlyCache: true, cacheMaxAge: 604800000, // one week + maxNativeZoom: 19, attribution: '© OpenStreetMap contributors' }); } -- cgit v1.3.1