From 9351fa46e539c93a6edc1cf7f3b519b40cffa98f Mon Sep 17 00:00:00 2001 From: Tim Waters Date: Sun, 11 Oct 2020 18:05:09 +0100 Subject: [PATCH] add ne urban areas to low zooms. Add mid and major roads as lines to mid zooms --- mbgl-antique-style.json | 31 ++++++++++++++++++++++++++++++- mbgl-map.js | 2 ++ 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/mbgl-antique-style.json b/mbgl-antique-style.json index 3d4d597..a5295b0 100644 --- a/mbgl-antique-style.json +++ b/mbgl-antique-style.json @@ -44,6 +44,13 @@ "source-layer":"country_lines", "type":"line" }, + { + "paint":{"fill-color":"#aeada9", "fill-opacity":{"stops":[[2,0.6],[9,0.1]]}}, + "id":"urban_areas", + "source":"antique", + "source-layer":"urban_areas", + "type":"fill" + }, { "paint":{"line-color":"#aeada9","line-width":{"stops":[[14,1],[21,3]]}}, "id":"state_lines", @@ -87,7 +94,29 @@ "maxzoom":20 }, { - "paint":{"line-color":"#444444","line-width":{"stops":[[14,6],[19,29]]}}, + "paint":{"line-color":"#8f9998","line-width":{"stops":[[10,1],[13,3]]}}, + "source-layer":"roads", + "id":"major_roads_line", + "source":"antique", + "type":"line", + "filter": ["in", ["get", "type"], ["literal", ["motorway","trunk","primary","secondary"]]], + "minzoom":10, + "maxzoom":13 + }, + { + "paint":{"line-color":"#8f9998","line-width":1}, + "source-layer":"roads", + "id":"mid_roads_line", + "source":"antique", + "type":"line", + "filter": [ "match", ["get", "type"], ["trunk","primary","secondary" ],false,true ], + "minzoom":10, + "maxzoom":13 + }, + + + { + "paint":{"line-color":"#444444","line-width":{"stops":[[14,8],[19,29]]}}, "source-layer":"roads", "id":"roads_casing_major", "source":"antique", diff --git a/mbgl-map.js b/mbgl-map.js index 396fd2d..ea582e1 100644 --- a/mbgl-map.js +++ b/mbgl-map.js @@ -142,6 +142,8 @@ document.addEventListener("DOMContentLoaded", function(){ "landuse", "road_names", "minor_roads", + "major_roads_line", + "mid_roads_line", "roads_casing_major", "roads_casing_mid", "roads_casing_major",