From 021ad78513de0f0d810e7ecd32415a411f27be8e Mon Sep 17 00:00:00 2001 From: Bryan Housel Date: Tue, 1 Mar 2016 12:22:23 -0500 Subject: [PATCH] Update imagery blacklist/whitelists to match editor_layer_index (revert of aaaf830, closes #2941) --- data/update_imagery.js | 72 +++++++++++++++++++++++------------------- 1 file changed, 39 insertions(+), 33 deletions(-) diff --git a/data/update_imagery.js b/data/update_imagery.js index 05fb04e23..40b36272d 100644 --- a/data/update_imagery.js +++ b/data/update_imagery.js @@ -3,45 +3,52 @@ var sources = require('editor-layer-index/imagery.json'); var imagery = []; var blacklist = { - "TIGER 2012 Roads Overlay": true + "2u": true, + "Hike & Bike": true, + "OpenCycleMap": true, + "OpenStreetMap (German Language)": true, + "OpenStreetMap (German Style)": true, + "OpenStreetMap (Sorbian Language)": true, + "MapQuest OSM": true, + "OpenStreetMap (Standard Black & White)": true, + "Skobbler": true, + + "Stadtplan Z\u00fcrich": true, // https://github.com/osmlab/editor-imagery-index/issues/14 + "Public Transport (\u00d6PNV)": true, // https://github.com/osmlab/editor-imagery-index/issues/15 + + "TIGER 2012 Roads Overlay": true, // https://github.com/openstreetmap/iD/pull/2010, + + "Waymarked Trails: Cycling": true, + "Waymarked Trails: Hiking": true, + "Waymarked Trails: MTB": true, + "Waymarked Trails: Skating": true, + "Waymarked Trails: Winter Sports": true, + + "OSM Inspector: Geometry": true, + "OSM Inspector: Highways": true, + "OSM Inspector: Multipolygon": true, + "OSM Inspector: Places": true, + "OSM Inspector: Tagging": true, + "OSM Inspector: Addresses (EU)": true, + "OSM Inspector: Boundaries (EU)": true, + "OSM Inspector: Routing (EU)": true, + + "QA No Address": true }; -var whitelist = [{ - "name": "Locator Overlay", - "url": "http://{switch:a,b,c}.tiles.mapbox.com/v4/openstreetmap.map-inh76ba2/{zoom}/{x}/{y}.png?access_token=pk.eyJ1Ijoib3BlbnN0cmVldG1hcCIsImEiOiJncjlmd0t3In0.DmZsIeOW-3x-C5eX-wAqTw", - "description": "Shows major features to help orient you.", - "overlay": true, - "default": true, - "extent": { "max_zoom": 16 }, - "type": "tms", - "attribution": { - "url": "http://www.mapbox.com/about/maps/", - "text": "Terms & Feedback" - } -},{ - "id": "MAPNIK", - "name": "OpenStreetMap (Standard)", - "url": "http://{switch:a,b,c}.tile.openstreetmap.org/{zoom}/{x}/{y}.png", - "description": "The default OpenStreetMap layer.", - "default": true, - "extent": { "max_zoom": 19 }, - "type": "tms", - "attribution": { - "url": "http://openstreetmap.org/", - "text": "\u00a9 OpenStreetMap contributors, CC-BY-SA" - } -}]; +var whitelist = [ + // Add custom sources here if needed. +]; var descriptions = { 'Mapbox Satellite': 'Satellite and aerial imagery.', - 'Bing aerial imagery': 'Satellite and aerial imagery.' + 'Bing aerial imagery': 'Satellite and aerial imagery.', + 'OpenStreetMap (Standard)': 'The default OpenStreetMap layer.' }; sources.concat(whitelist).forEach(function(source) { - if (source.type !== 'tms' && source.type !== 'bing') - return; - if (source.name in blacklist) - return; + if (source.type !== 'tms' && source.type !== 'bing') return; + if (source.name in blacklist) return; var im = { name: source.name, @@ -54,7 +61,6 @@ sources.concat(whitelist).forEach(function(source) { im.template = source.url; var extent = source.extent || {}; - if (extent.min_zoom || extent.max_zoom) { im.scaleExtent = [ extent.min_zoom || 0, @@ -74,7 +80,7 @@ sources.concat(whitelist).forEach(function(source) { ]]; } - if (source.name == 'Locator Overlay') { + if (source.name === 'Locator Overlay') { im.overzoom = false; }