#
global:
+ # Sign up for a Mapzen API key to enjoy higher rate limits
+ # https://mapzen.com/documentation/overview/#developer-accounts-and-api-keys
+ sdk_mapzen_api_key: '' # set this value to your Mapzen API key
+
#ux/ui
ux_language: false # l10n language code, trusting OSM in v0.10 tiles, fixed in v1.0 tiles
ux_language_fallback: false # l10n language code, trusting OSM in v0.10 tiles, fixed in v1.0 tiles
sdk_shield_text_color: white
#
# enable interactivity for key features
- interactive: true
+ interactive: false
#
# default order for basemap features
feature_order: function() { return feature.sort_rank; }
- building_extrude: true
+ sdk_building_extrude: true # building extrusion toggle
#
- # TODO: YAML based globals below will move into this Tangram globals block
-
-labels-global:
- - &text_visible_continent true
- - &text_visible_island true
- - &text_visible_admin true
- - &text_visible_populated_places true
- - &icon_visible_populated_places true
- - &text_visible_neighbourhoods true
- - &text_visible_neighbourhoods_e true
- - &text_visible_building true
- - &text_visible_address true
- - &text_visible_water_labels true
- - &label_visible_landuse_green true
- - &icon_visible_landuse_green true #this needs work
- - &text_visible_landuse_green true
- - &label_visible_poi_landuse true
- - &icon_visible_poi_landuse true #false for default
- - &text_visible_poi_landuse true #false for default
- - &label_visible_poi_landuse_e true
- - &icon_visible_poi_landuse_e true #false for default
- - &text_visible_poi_landuse_e true
- - &label_visible_station true #false for default
- - &icon_visible_station true #false for default
- - &text_visible_station true #false for default
- - &text_visible_highway true
- - &text_visible_highway_e true #false for default
- - &text_visible_trunk_primary true
- - &text_visible_trunk_primary_e2 true #false for default
- - &text_visible_trunk_primary_e true #false for default
- - &text_visible_secondary true
- - &text_visible_secondary_e true #false for default
- - &text_visible_tertiary true
- - &text_visible_tertiary_e true #false for default
- - &text_visible_minor_road true
- - &text_visible_minor_road_e true
- - &text_visible_service_road true
- - &text_visible_path true
- - &text_visible_piste true
- - &text_visible_steps true
- - &text_visible_aerialway true
- - &text_visible_shields false
- - &text_visible_exits true
- - &text_visible_exits_e true #false for default
- - &text_visible_airport_gate true
-
-settings:
- cameras:
- - &camera_settings { type: isometric, axis: [-.2, .2] }
-
- lights:
- - &light_settings { type: directional, direction: [1, 1, -.9], diffuse: 0.5, ambient: 0.85 }
-
- roads:
- - &highway1 [1.00,1.00,1.00]
- - &highway_link1 [0.00, 0.00, 0.00]
- - &highway_casing1 [0.894,0.906,0.914]
- - &highway_tunnel1 [0.930,0.930,0.930]
- - &highway_tunnel_casing1 [0.894,0.906,0.914]
- - &highway_link_tunnel_casing1 [0.350,0.350,0.350]
- - &ferry1 [0.410,0.750,0.833]
- - &rail1 '#999'
- - &rail1_e '#bbb'
- - &rail2 '#777' # less important rail (service, sidings)
- - &major_road1 [1.0, 1.0, 1.0]
- - &major_road1b [0.935, 0.935, 0.935]
- - &major_road1c white #15%
- - &major_road2 [0.935, 0.935, 0.935]
- - &major_road2a [0.935, 0.935, 0.935]
- - &major_road2b [0.935, 0.935, 0.935]
- - &major_road3 [0.935, 0.935, 0.935]
- - &major_road4 [0.00, 0.00, 0.00]
- - &major_road5 white
- - &major_casing1 [0.40, 0.40, 0.40] # same as highway_casing1
- - &major_casing2 [0.40, 0.40, 0.40] # zoomed out
- - &major_tunnel1 [0.930,0.930,0.930]
- - &major_tunnel_casing1 [1.00, 1.00, 1.00]
- - &major_route1 [0.0, 0.0, 0.0]
- - &major_route2 [0.2, 0.2, 0.2] # zoomed out
- - &minor_route [0.97, 0.97, 0.97] # same as major_route
- - &minor_road1 [0.935, 0.935, 0.935] # natural earth
- - &minor_road2 [1.00,1.00,1.00] # natural earth, same as major_road2
- - &minor_road3 [0.935, 0.935, 0.935]
- - &minor_road4 [0.935, 0.935, 0.935] # zoomed out
- - &minor_road5 [0.935, 0.935, 0.935] # zoomed out, again
- - &minor_casing1 white # same as highway_casing1
- - &minor_casing2 white # zoomed out
- - &minor_tunnel1 [0.930,0.930,0.930]
- - &minor_tunnel_casing1 [1.00, 1.00, 1.00]
- - &service_road1 [0.935, 0.935, 0.935]
- - &service_road2 white
- - &service_road_casing1 [0.40, 0.40, 0.40]
- - &service_road_casing2 white
- - &path1 [0.97, 0.97, 0.97]
- - &path2 [0.97, 0.97, 0.97] # zoomed out
- - &path_casing1 [0.40, 0.40, 0.40]
- - &path_bridge_casing1 [0.40, 0.40, 0.40]
- - &path_bridge_casing2 [0.40, 0.40, 0.40] # zoomed out
- - &path_steps1 red
- - &path_steps1_b '#ccc'
- - &piste_easy [0.367,0.750,0.622]
- - &piste_intermediate [0.420,0.678,0.863]
- - &piste_advanced [0.450,0.450,0.450]
- - &piste_expert [0.450,0.450,0.450]
-
- boundaries:
- - &country_boundary [1.00,1.00,1.00]
- - ®ion_boundary [1.00,1.00,1.00]
- - &subregion_boundary [1.00,1.00,1.00]
- - &city_wall [0.682,0.682,0.682]
- - &retaining_wall [0.827,0.808,0.780]
- - &snow_fence [0.827,0.808,0.780]
- - &fence [0.827,0.808,0.780]
- - &dam [0.827,0.808,0.780]
-
- areas:
- - &scene1 white # map background
- - &water1 [0.870, 0.870, 0.870] # water wave
- - &water2 [0.760, 0.760, 0.760] # water wave
- - &water3 [0.5, 0.5, 0.5] # playa texture
- - &water1_o '#fff' # water stroke (ocean coastline)
- - &water2_o '#d1d1d1' # water stroke 2 (streams, lake outlines)
- - &earth1 white # land color
- - &earth2 '#e9e4e0' # urban
- - &earth2_v false # urban
- - &green1 [0.50,0.50,0.50] # park
- - &green1_r '#bbbbbb' # park roads
- - &green1_b [.65, .65, .65] # park buildings
- - &green1_bo [.8, .8, .8] # park building outlines
- - &green2 [0.90,0.90,0.90] # cemetery
- - &green3 '#9a9a9a' # golf course
- - &green4 [0.90,0.90,0.90] # farm faint
- - &green4_v false # farm faint
- - &green5 [0.75,0.75,0.75] # farm
- - &green6 [0.40,0.40,0.40] # nature reserve
- - &green7 [0.85,0.85,0.85] # forest
- - &green8 [0.80,0.80,0.80] # conservation
- - &green9 [0.85,0.85,0.85] # forest (landcover)
- - &green9_e [0.90,0.90,0.90] # forest (landcover) early
- - &green9_v true # forest (landcover) visibility
- - &green10 [0.85,0.85,0.85] # sports_centre
- - &green11 [0.85,0.85,0.85] # minor zoo related AOIs
- - &green11_o [0.85,0.85,0.85] # minor zoo related AOIs outline
- - &orange1 '#aaaaaa' # stadium
- - &orange2 [0.40,0.40,0.40] # pitch (play field)
- - &brown1 '#7b7b7b' # university
- - &brown1_r '#bbbbbb' # university roads
- - &brown1_b [.65, .65, .65] # university buildings
- - &brown1_bo [.8, .8, .8] # university building outlines
- - &brown2 '#aaaaaa' # school
- - &brown3 [0.40,0.40,0.40] # playground
- - &red1 '#a2a2a2' # hospital
- - &red1_r '#bbbbbb' # hospital roads
- - &red1_b [.65, .65, .65] # hospital buildings
- - &red1_bo [.8, .8, .8] # hospital building outlines
- - &gray-all [0.935,0.960,0.970] # default gray for landuse outdoor style
- - &grey1 '#cccccc' # pedestrian, retail, airport apron, parking, church
- - &grey1_e '#dad6d4' # pedestrian, retail, airport apron, parking, church early zoom 14
- - &grey1_v true # pedestrian, retail, airport apron, parking, church
- - &grey2 [0.5, 0.5, 0.5] # airport runway
- - &grey3 '#bbbbbb' # railway
- - &grey4 '#ffc52a' # airport taxiway
- - &grey5 '#ffc52a' # airport taxiway
- - &grey6 '#dddddd' # industrial
- - &grey6_b [.65, .65, .65] # industrial buildings
- - &grey6_bo [.8, .8, .8] # industrial building outlines
- - &grey7 '#ecebe9' # pedestrian, match minor road / path color
- - &grey7_v true # pedestrian visibility
- - &grey8 '#ecebe9' # winter sports
- - &grey8_v true # winter sports visibility
- - &grey9 [.7, .0, .0, 0.5] #[.7, .7, .7] # transit platform
- - &grey9_o [.5, .5, .5] # transit platform outline
- - &grey9_v true # transit platform visibility
- - &grey10 '#d4cce6' # generic major landuse (theme park, resort, aquarium, winery)
- - &grey10_o '#bcb9c5' # generic major landuse outline
- - &grey11 '#d7d7d7' # generic minor landuse (attraction, artwork)
- - &grey11_o '#cccccc' # generic minor landuse outline
- - &grey12 '#cfcfcf' # generic minor amusements (roller coasters, rides, slide, carousel)
- - &grey12_o '#c5c5c5' # generic minor amusements
- - &purple '#f0e1e1' # airport
- - &purple_v true # airport
- - &mystry1 '#aaaaaa' # recreation ground (type of park, sometimes around reservoirs)
- - &building1 white # building
- - &building2 white # building stroke
- - &building_o 25 # building stroke order
- - &building_e true # building stroke order
-
- labels:
- - &text_fill '#000' # WHITE
- - &text_fill2 '#000' # WHITE
- - &text_fill_road_e '#555' # WHITE
- - &text_fill_exits [0.40,0.40,0.40] # motorway junctions, highway_casing1
- - &text_fill_building '#000' # tan
- - &text_fill_address [0.60,0.60,0.60] # HUH
- - &text_fill_water [0.354,0.531,0.620] # blue
- - &text_fill_park [0.175,0.175,0.175] # green
- - &text_fill_beach [0.35,0.35,0.35] # black
- - &text_fill_piste [0.350,0.350,0.350] # dark gray
- - &text_fill_piste_e [0.350,0.350,0.350] # dark gray early
- - &text_stroke [0.913,0.925,0.933] # land color
- - &text_stroke_park [0.913,0.925,0.933] # land color
- - &text_stroke_water [0.913,0.925,0.933]
- - &text_stroke_address [0.913,0.925,0.933] # address stroke color
- - &townspot_sprite townspot-m-rev # depends on land color and text settings
- - &text_font_family 'Open Sans' # branding in asperational Unicode, yo (or Helvetica)
+ #labels-global:
+ text_visible_continent: true
+ text_visible_island: true
+ text_visible_admin: true
+ text_visible_populated_places: true
+ icon_visible_populated_places: true
+ text_visible_neighbourhoods: true
+ text_visible_neighbourhoods_e: true
+ text_visible_building: true # false for default
+ text_visible_address: true # false for default
+ text_visible_water_labels: true
+ label_visible_landuse_green: true #this needs work
+ icon_visible_landuse_green: true #this needs work
+ icon_size_green: [[13, '14px'], [16, '18px'], [18, '19px']] # 0px for no, default, more [[13, '14px'], [16, '18px'], [18, '19px']]
+ icon_size_green_l: [[14, '24px'], [16, '32px']] # 0px for no, default, more [[14, '24px'], [16, '32px']]
+ text_visible_landuse_green: true
+ label_visible_poi_landuse: true
+ icon_visible_poi_landuse: true #false for default
+ text_visible_poi_landuse: true #false for default
+ label_visible_poi_landuse_e: true
+ icon_visible_poi_landuse_e: true #false for default
+ text_visible_poi_landuse_e: true
+ text_visible_landuse_generic: true
+ label_visible_station: true #false for default
+ icon_visible_station: true #false for default
+ text_visible_station: true #false for default
+ text_visible_highway: true
+ text_visible_highway_e: true #false for default
+ text_visible_trunk_primary: true
+ text_visible_trunk_primary_e2: true #false for default
+ text_visible_trunk_primary_e: true #false for default
+ text_visible_secondary: true
+ text_visible_secondary_e: true #false for default
+ text_visible_tertiary: true
+ text_visible_tertiary_e: true #false for default
+ text_visible_minor_road: true
+ text_visible_minor_road_e: true
+ text_visible_service_road: true
+ text_visible_path: true
+ text_visible_piste: true
+ text_visible_steps: true
+ text_visible_aerialway: true
+ sdk_road_shields: true
+ text_visible_exits: true
+ text_visible_exits_e: true #false for default
+ text_visible_airport_gate: true
+
+ #cameras:
+ camera_settings: { type: isometric, axis: [-.2, .2] }
+
+ #lights:
+ light_settings: { type: directional, direction: [1, 1, -.9], diffuse: 0.5, ambient: 0.85 }
+
+ #roads:
+ highway1: [1.00,1.00,1.00]
+ highway_link1: [0.00, 0.00, 0.00]
+ highway_casing1: [0.894,0.906,0.914]
+ highway_tunnel1: [0.930,0.930,0.930]
+ highway_tunnel_casing1: [0.894,0.906,0.914]
+ highway_link_tunnel_casing1: [0.350,0.350,0.350]
+ ferry1: [0.410,0.750,0.833]
+ rail1: '#999'
+ rail1_e: '#bbb'
+ rail2: '#777' # less important rail (service, sidings)
+ major_road1: [1.0, 1.0, 1.0]
+ major_road1b: [0.935, 0.935, 0.935]
+ major_road1c: white #15%
+ major_road2: [0.935, 0.935, 0.935]
+ major_road2a: [0.935, 0.935, 0.935]
+ major_road2b: [0.935, 0.935, 0.935]
+ major_road3: [0.935, 0.935, 0.935]
+ major_road4: [0.00, 0.00, 0.00]
+ major_road5: white
+ major_casing1: [0.40, 0.40, 0.40] # same as highway_casing1
+ major_casing2: [0.40, 0.40, 0.40] # zoomed out
+ major_tunnel1: [0.930,0.930,0.930]
+ major_tunnel_casing1: [0.695,0.739,0.790]
+ major_route1: [0.0, 0.0, 0.0]
+ major_route2: [0.2, 0.2, 0.2] # zoomed out
+ minor_route: [0.97, 0.97, 0.97] # same as major_route
+ minor_road1: [0.935, 0.935, 0.935] # natural earth
+ minor_road2: [1.00,1.00,1.00] # natural earth, same as major_road2
+ minor_road3: [0.935, 0.935, 0.935]
+ minor_road4: [0.935, 0.935, 0.935] # zoomed out
+ minor_road5: [0.935, 0.935, 0.935] # zoomed out, again
+ minor_casing1: white # same as highway_casing1
+ minor_casing2: white # zoomed out
+ minor_tunnel1: [0.929,0.929,0.929]
+ minor_tunnel_casing1: [1.00, 1.00, 1.00]
+ service_road1: [0.935, 0.935, 0.935]
+ service_road2: white
+ service_road_casing1: [0.40, 0.40, 0.40]
+ service_road_casing2: white
+ path1: [0.97, 0.97, 0.97]
+ path2: [0.97, 0.97, 0.97] # zoomed out
+ path_casing1: [0.40, 0.40, 0.40]
+ path_bridge_casing1: [0.40, 0.40, 0.40]
+ path_bridge_casing2: [0.40, 0.40, 0.40] # zoomed out
+ path_steps1: red
+ path_steps1_b: '#ccc'
+ piste_easy: [0.367,0.750,0.622]
+ piste_intermediate: [0.420,0.678,0.863]
+ piste_advanced: [0.450,0.450,0.450]
+ piste_expert: [0.450,0.450,0.450]
+
+ #boundaries:
+ country_boundary: [1.00,1.00,1.00]
+ region_boundary: [1.00,1.00,1.00]
+ subregion_boundary: [1.00,1.00,1.00]
+ city_wall: [0.682,0.682,0.682]
+ retaining_wall: [0.827,0.808,0.780]
+ snow_fence: [0.827,0.808,0.780]
+ fence: [0.827,0.808,0.780]
+ dam: [0.827,0.808,0.780]
+
+ #areas:
+ scene1: white # map background
+ water1: [0.870, 0.870, 0.870] # water wave
+ water2: [0.760, 0.760, 0.760] # water wave
+ water3: [0.5, 0.5, 0.5] # playa texture
+ water1_o: '#fff' # water stroke (ocean coastline)
+ water2_o: '#d1d1d1' # water stroke 2 (streams, lake outlines)
+ earth1: white # land color
+ earth2: '#e9e4e0' # urban
+ earth2_v: false # urban
+ green1: [0.50,0.50,0.50] # park
+ green1_r: '#bbbbbb' # park roads
+ green1_b: [.65, .65, .65] # park buildings
+ green1_bo: [.8, .8, .8] # park building outlines
+ green2: [0.90,0.90,0.90] # cemetery
+ green3: '#9a9a9a' # golf course
+ green4: [0.90,0.90,0.90] # farm faint
+ green4_v: false # farm faint
+ green5: [0.75,0.75,0.75] # farm
+ green6: [0.40,0.40,0.40] # nature reserve
+ green7: [0.85,0.85,0.85] # forest
+ green8: [0.80,0.80,0.80] # conservation
+ green9: [0.85,0.85,0.85] # forest (landcover)
+ green9_e: [0.90,0.90,0.90] # forest (landcover) early
+ green9_v: true # forest (landcover) visibility
+ green10: [0.85,0.85,0.85] # sports_centre
+ green11: [0.85,0.85,0.85] # minor zoo related AOIs
+ green11_o: [0.85,0.85,0.85] # minor zoo related AOIs outline
+ orange1: '#aaaaaa' # stadium
+ orange2: [0.40,0.40,0.40] # pitch (play field)
+ brown1: '#7b7b7b' # university
+ brown1_r: '#bbbbbb' # university roads
+ brown1_b: [.65, .65, .65] # university buildings
+ brown1_bo: [.8, .8, .8] # university building outlines
+ brown2: '#aaaaaa' # school
+ brown3: [0.40,0.40,0.40] # playground
+ red1: '#a2a2a2' # hospital
+ red1_r: '#bbbbbb' # hospital roads
+ red1_b: [.65, .65, .65] # hospital buildings
+ red1_bo: [.8, .8, .8] # hospital building outlines
+ gray-all: [0.935,0.960,0.970] # default gray for landuse outdoor style
+ grey1: '#cccccc' # pedestrian, retail, airport apron, parking, church
+ grey1_e: '#dad6d4' # pedestrian, retail, airport apron, parking, church early zoom 14
+ grey1_v: true # pedestrian, retail, airport apron, parking, church
+ grey2: [0.5, 0.5, 0.5] # airport runway
+ grey3: '#bbbbbb' # railway
+ grey4: '#ffc52a' # airport taxiway
+ grey5: '#ffc52a' # airport taxiway
+ grey6: '#dddddd' # industrial
+ grey6_b: [.65, .65, .65] # industrial buildings
+ grey6_bo: [.8, .8, .8] # industrial building outlines
+ grey7: '#ecebe9' # pedestrian, match minor road / path color
+ grey7_v: true # pedestrian visibility
+ grey8: '#ecebe9' # winter sports
+ grey8_v: true # winter sports visibility
+ grey9: [.7, .0, .0, 0.5] #[.7, .7, .7] # transit platform
+ grey9_o: [.5, .5, .5] # transit platform outline
+ grey9_v: true # transit platform visibility
+ grey10: '#d4cce6' # generic major landuse (theme park, resort, aquarium, winery)
+ grey10_o: '#bcb9c5' # generic major landuse outline
+ grey11: '#d7d7d7' # generic minor landuse (attraction, artwork)
+ grey11_o: '#cccccc' # generic minor landuse outline
+ grey12: '#cfcfcf' # generic minor amusements (roller coasters, rides, slide, carousel)
+ grey12_o: '#c5c5c5' # generic minor amusements
+ purple: '#f0e1e1' # airport
+ purple_v: true # airport
+ mystry1: '#aaaaaa' # recreation ground (type of park, sometimes around reservoirs)
+ building1: white # building
+ building2: white # building stroke
+ building_o: 25 # building stroke order
+ building_e: true # building stroke order
+
+ #labels:
+ text_fill: '#000' # WHITE
+ text_fill2: '#000' # WHITE
+ text_fill_road_e: '#555' # WHITE
+ text_fill_exits: [0.40,0.40,0.40] # motorway junctions, highway_casing1
+ text_fill_building: '#000' # tan
+ text_fill_address: [0.60,0.60,0.60] # HUH
+ text_fill_water: [0.354,0.531,0.620] # blue
+ text_fill_park: [0.175,0.175,0.175] # green
+ text_fill_beach: [0.35,0.35,0.35] # black
+ text_fill_piste: [0.350,0.350,0.350] # dark gray
+ text_fill_piste_e: [0.350,0.350,0.350] # dark gray early
+ text_stroke: [0.913,0.925,0.933] # land color
+ text_stroke_park: [0.913,0.925,0.933] # land color
+ text_stroke_water: [0.913,0.925,0.933]
+ text_stroke_address: [0.913,0.925,0.933] # address stroke color
+ townspot_sprite: townspot-m-rev # depends on land color and text settings
+ text_font_family: 'Open Sans' # branding in asperational Unicode, yo (or Helvetica)
cameras:
- camera1: *camera_settings
+ camera1: global.camera_settings
scene:
background:
textures:
pois:
url: images/walkabout@2x.png
+ #url: https://raw.githubusercontent.com/tangrams/walkabout-style/gh-pages/images/walkabout%402x.png
filtering: mipmap
sprites:
# define sprites: [x origin, y origin, width, height]
outdoor: [736, 252, 38, 38]
park: [322, 126, 38, 38]
national_park: [322, 126, 38, 38]
- battlefield: [322, 126, 38, 38]
protected_area: [322, 126, 38, 38]
category-predicate-nature: [322, 126, 38, 38]
parking: [782, 126, 38, 38]
building-grid:
url: images/building-grid.gif
+ #url: https://raw.githubusercontent.com/tangrams/walkabout-style/gh-pages/images/building-grid.png
filtering: mipmap
sources:
mapzen:
type: TopoJSON
# prod
- url: https://tile.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.topojson?api_key=vector-tiles-VyYjZGS
+ url: https://tile.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.topojson
# dev
#url: https://tile.dev.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.topojson
+ url_params:
+ api_key: global.sdk_mapzen_api_key
rasters: [normals]
max_zoom: 16
normals: # normals
type: Raster
url: https://tile.mapzen.com/mapzen/terrain/v1/normal/{z}/{x}/{y}.png
+ url_params:
+ api_key: global.sdk_mapzen_api_key
max_zoom: 15
# # Only enable this for local debug, should not be enabled for prod (app inserts these at runtime)
base: lines
dash: [1.25, 1.25]
dash_background_color: [0.808,0.860,0.851]
+ dashed_small:
+ base: lines
+ dash: [0.5, 0.5]
+ dash_background_color: [0.867, 0.867, 0.867]
dashed_big:
base: lines
dash: [2.0, 1.0]
dash_background_color: [0.808,0.860,0.851]
- dashedTunnel:
+ dashed_tunnel:
base: lines
dash: [5, 3]
#dash_background_color: red
- dashedline:
- base: lines
- texcoords: true
- shaders:
- defines:
- background: vec3(0.867, 0.867, 0.867)
- blocks:
- color: |
- // blend line 50/50 between two colors
- float t = fract(v_texcoord.y*.5);
- float e = 0.1; // edge feather
- vec3 v = vec3(
- smoothstep(.0, e, t) *
- (1. - smoothstep(.5, .5 + e, t))
- );
- color.rgb = mix(color.rgb, background, v);
-
- functions-map:
- shaders:
- defines:
- EPSILON: 0.0000001
- blocks:
- global: |
- float map (in float value, in float inputMin, in float inputMax, in float outputMin, in float outputMax, bool clamp) {
- if (abs(inputMin - inputMax) < EPSILON){
- return outputMin;
- } else {
- float outVal = ((value - inputMin) / (inputMax - inputMin) * (outputMax - outputMin) + outputMin);
-
- if( clamp ){
- if(outputMax < outputMin){
- if( outVal < outputMax ) outVal = outputMax;
- else if( outVal > outputMin ) outVal = outputMin;
- } else {
- if( outVal > outputMax ) outVal = outputMax;
- else if( outVal < outputMin ) outVal = outputMin;
- }
- }
- return outVal;
- }
- }
-
- float map (in float value, in float inputMin, in float inputMax, in float outputMin, in float outputMax) {
- return map(value, inputMin, inputMax, outputMin, outputMax, true);
- }
- space-tile:
- shaders:
- blocks:
- global: |
- // Variant to be add to both vertex and fragments shaders
- varying vec3 v_pos;
- //
- // Get the coordinates in tile space
- // ================================
- vec2 getTileCoords () {
- return fract(v_pos.xy);
- }
- position: |
- // Normalize the attribute position of a vertex
- v_pos = modelPosition().xyz;
-
- grids-grid:
- shaders:
- blocks:
- global: |
- // Draw a grid in the space a specific resolution and pressition
- bool grid(vec2 st, float res, float press){
- vec2 grid = fract(st*res);
- return grid.x < res*press || grid.y < res*press;
- }
- //
- // Draw a grid in the space a specific resolution
- bool grid(vec2 st, float res){
- return grid(st, res, 1.0);
- }
-
- grids-tile:
- mix: [space-tile,grids-grid]
- shaders:
- blocks:
- global: |
- // Draw a grid using tile coordenates in a specific resolution
- float tileGrid(float res){
- vec2 st = getTileCoords()*100.*res;
- float pct = 0.0;
- float press = .4+(1.0-fract(u_map_position.z))*0.1; //0.4
- if (grid(st,0.01,press)) pct += .5; //.5
- return pct;
- }
- // Draw two grid that smoothly interpolates acording to zooms
- float tileGrid(){
- return mix(tileGrid(1.),tileGrid(2.),fract(u_map_position.z));
- }
-
- grid:
- base: polygons
- mix: [grids-tile]
- shaders:
- blocks:
- color: |
- color = v_color*tileGrid();
- // color = vec4(v_color.r, v_color.g, v_color.b, 1.0);
- // color.rgba
-
- shapes-rect:
- shaders:
- blocks:
- global: |
- // get distance field of a rectangle in the center
- // ================================
- float rectDF(vec2 st, vec2 size) {
- //float aspect = u_resolution.x/u_resolution.y;
- st = st*2.-1.;
- //st.x *= aspect;
- return length(max(abs(st)-size,.0));
- }
- float rectDF(vec2 st, float size) {
- //float aspect = u_resolution.x/u_resolution.y;
- st = st*2.-1.;
- //st.x *= aspect;
- return length(max(abs(st)-size,.0));
- }
-
- // Draw a round corners rectangle in the center
- // ================================
- float rect(vec2 st, vec2 size, float radio) {
- radio = max(.000001, radio);
- return 1.0-step(radio, rectDF(st, size-radio));
- }
-
- float rect(vec2 st, float size, float radio) {
- return rect(st,vec2(size),radio);
- }
-
- // Draw a rectangle in the center
- // ================================
- float rect(vec2 st, vec2 size){
- size = .25-size*.125;
- vec2 uv = step(size,st*(1.0-st));
- return (uv.x*uv.y);
- }
-
- float rect(vec2 st, float size){
- return rect(st,vec2(size));
- }
- shapes-cross:
- mix: shapes-rect
- shaders:
- blocks:
- global: |
- // Draw a Cross in the middle of the ST space
- float cross (vec2 st, float size, float width) {
- return clamp( rect(st, vec2(size*0.5,width*0.125)) +
- rect(st, vec2(width*0.125,size*0.5)),0.,1.);
- }
- float cross(in vec2 st, float _size){
- return rect(st, vec2(_size*0.5,_size*0.125)) +
- rect(st, vec2(_size*0.125,_size*0.5));
- }
- float cross(in vec2 st, vec2 _size){
- return rect(st, vec2(_size.x*0.5,_size.y*0.125)) +
- rect(st, vec2(_size.y*0.125,_size.x*0.5));
- }
-
terrain:
base: polygons
lighting: false
- raster: normal
+ raster: custom
shaders:
uniforms:
# u_envmap: images/relief-shading-environment-map.jpg
- u_envmap: images/draw-test9.jpg
+ u_envmap: images/draw-test10.jpg
+ # u_envmap: https://raw.githubusercontent.com/tangrams/walkabout-style/gh-pages/images/draw-test10.jpg
u_contrast: 1.
u_brightness: 1.
blocks:
global: |
+ varying vec2 v_tex_coord;
+ #ifdef TANGRAM_VERTEX_SHADER
+ uniform vec3 u_raster_offsets[TANGRAM_NUM_RASTER_SOURCES];
+ #endif
// Simplified view-independent environment map
vec4 terrainEnvmap (in sampler2D _tex, in vec3 _normal) {
const vec3 eye = vec3(0.,0.,-1.);
return texture2D(_tex, uv);
}
const float e = 2.71828;
+ setup: |
+ #ifdef TANGRAM_VERTEX_SHADER
+ v_tex_coord = modelPositionBaseZoom().xy * u_raster_offsets[0].z + u_raster_offsets[0].xy;
+ #endif
color: |
// scale up normals with a function
// https://www.desmos.com/calculator/bv4mzh8erz
//float scale = 10./(u_map_position.z-.7) + 1.8;
float scale1 = 20./(u_map_position.z) + 1.5;
- normal.z /= scale1; // turn terrain exaggeration up/down
+
+ vec3 tex_normal = normalize(texture2D(u_rasters[0], v_tex_coord).xyz * 2.0 - 1.0);
+ tex_normal.z /= scale1; // turn terrain exaggeration up/down
+
// fade out spheremap normals with a function
// https://www.desmos.com/calculator/ptgkzcnfyc
float m = 3.5 * (u_map_position.z - 0.8) * pow(e, u_map_position.z * -.29);
m = clamp(m, 0., 1.5);
- color = terrainEnvmap(u_envmap, normal);
+ color = terrainEnvmap(u_envmap, tex_normal);
// Apply contrast
float contrast = m;
color *= v_color; // apply layer color
- water-grid:
- mix: grid
- shaders:
- blocks:
- color: |
- color = v_color;
- color.rgb -= vec3(tileGrid());
- vec4 linecolor = vec4(0.489,0.776,0.820,1.0);
- vec4 colorlines = linecolor * tileGrid();
- color += colorlines;
-
# HSV/RGB functions
hsv:
shaders:
base: lines
mix: scale-buildings
texcoords: true
-
-
- terrain-muted:
- mix: grid-on-terrain
- shaders:
- uniforms:
- u_scale: 1 # turn down the terrain
-
- terrain-grid:
- mix: grid-on-terrain
- shaders:
- uniforms:
- u_scale: 2
-
- grid-on-terrain:
- mix: [grids-tile, terrain]
- shaders:
- blocks:
- color: |
- color -= v_color*tileGrid();
- vec4 linecolor = vec4(0.489,0.776,0.820,1.0);
- color += linecolor * tileGrid();
- dots-terrain:
- mix: [space-tile, functions-map, terrain, shapes-cross]
- shaders:
- blocks:
- color: |
- // Brightness
- float brightness2 = dot(normal, vec3(-0.838,-1.010,0.805));
-
- brightness2 = 1.-brightness2;
-
- // Scale
- float scale2 = map(floor(u_map_position.z), 8., 22., 0.0000001, .1, true);
- vec2 st = worldPosition().xy*scale2;
-
-
- // PATERNS
- float pct = 0.0;
-
- // Stripes
- // pct = step(brightness2*4.556,cos((st.x+st.y)));
-
-
- // Cell patterns
- st.x += step(1., mod(st.y,2.0)) *.5;
- vec2 f_st = fract(st);
- f_st -= .5;
-
- // Dots
- pct = step(brightness2*2.056,1.-dot(f_st,f_st)*10.400);
-
- // Lines
- // pct = rect(f_st+0.5,vec2(0.704,brightness2*0.472));
-
- // Cross
- //pct = cross(f_st+0.5,brightness2*6.128,brightness2*2.604);
-
- // Use this if you tint
- // if (pct < .5) {
- // discard;
- // }
-
- color.rgb = mix(color.rgb, v_color.rgb ,pct);
-
icons:
base: points
texture: pois
sprite: ux-current-location
size: 36px
collide: false
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
mz_route_location:
data: { source: mz_route_location }
draw:
sprite: ux-route-arrow
size: [60px,60px]
collide: false
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
mz_route_start:
data: { source: mz_route_start }
draw:
size: [36px,46px]
collide: false
anchor: top
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
mz_route_destination:
data: { source: mz_route_destination }
draw:
size: [36px,46px]
collide: false
anchor: top
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
mz_route_transit_stop:
data: { source: mz_route_transit_stop }
draw:
sprite: ux-transit-stop
size: [15px,15px]
collide: false
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
mz_search_result:
data: { source: mz_search_result }
draw:
size: [36px,54px]
collide: false
anchor: top
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
inactive:
filter: { state: inactive }
draw:
size: [36px,54px]
collide: false
anchor: top
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
# Used by the SDK to place point, line, and polygon overlays on the map
mz_default_point:
size: [36px,54px]
collide: false
anchor: top
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
mz_default_shield:
data: { source: mz_default_shield }
draw:
sprite_default: sdk_shield-1char
color: global.sdk_shield_color
collide: false
- transition:
- [show, hide]:
- time: 0s
+ transition: { show: { time: 0s }, hide: { time: 0s } }
text:
# offset: [0px, -1px]
text_source: |
playas:
filter: { kind: playa, $zoom: {min: 6} }
draw:
- dashedline:
+ dashed_small:
order: function() { return feature.sort_rank; }
color: grey
width: 1px
water-line-labels:
data: { source: mapzen, layer: water }
- visible: *text_visible_water_labels
+ visible: global.text_visible_water_labels
filter:
all:
- name: true
text-blend-order:
text_source: global.ux_language_text_source
font:
- fill: *text_fill_water
- family: *text_font_family
+ fill: global.text_fill_water
+ family: global.text_font_family
style: italic
weight: normal
size: [[12,10px],[17,14px]]
visible: false # labels are enabled by each layer below
text_source: global.ux_language_text_source
font:
- family: *text_font_family
+ family: global.text_font_family
weight: 500
- fill: *text_fill
+ fill: global.text_fill
early:
- filter: { $zoom: { max: 15 } }
+ filter: { $zoom: { max: 14 } }
draw:
lines:
outline:
filter: { source: 'naturalearthdata.com', $zoom: { max: 8 } }
draw:
lines:
- color: [[5, [0.5,0.5,0.5]],[6, [0.350,0.350,0.350]]]
- width: [[5, 0.5px], [6, 0.5px], [7, 0.75px], [9, 1.5px], [14, 1.5px], [16, 4px], [17, 10m]]
+ color: [[5, [0.50,0.50,0.50]], [6, [0.350,0.350,0.350]]]
+ width: [[5, 0.5px], [8, 1.25px]]
outline:
- color: *highway_casing1
- width: [[9, 0px], [10, 0px], [12, 1px], [16, 2px]]
+ color: global.highway_casing1
+ width: 0px
major_road:
filter: { kind: major_road }
draw:
lines:
- color: [[5, [0.75,0.75,0.75]], [8, [0.4,0.4,0.4]], [13, [0.4,0.4,0.4]], [17, *major_road1]]
- #color: red
- width: [[5, 0.25px], [7, 0.5px], [7, 0.75px], [9, 1px], [10, 9px], [11, 9px], [13, 1px], [16, 2.5px], [19, 6m]]
+ color: [[5, [0.75,0.75,0.75]], [8, [0.40,0.40,0.40]]]
+ width: [[5, 0.25px], [9, 0.75px]]
outline:
width: [[8, 0.0px], [9, 0.0px], [11, .5px], [16, .75px]]
minor_road:
filter: { kind: minor_road }
draw:
lines:
- color: [[12, *minor_road1], [17, *minor_road2]]
- width: [[12, 1.0px], [14, 1.5px], [15, 3px], [16, 5m]]
- # outline:
- # width: [[12, 0px], [14, .5px], [17, 1px]]
+ color: global.minor_road1
+ width: 0.5px
ferry:
filter: { kind: ferry }
draw:
lines:
- color: *ferry1
- width: [[12, 0.5px], [13, 0.75px], [15, 1.0px]]
+ color: global.ferry1
+ width: 0.5px
outline:
width: 0px
highway:
filter: { kind: highway, $zoom: { min: 8 } }
draw:
lines:
- color: [[8, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[8, 1px], [12, 1.25px], [13, 1.5px], [14, 0px], [15, 1px], [16, 5px], [17, 10px], [18, 10m]]
+ color: [[8, [0.457,0.438,0.457]], [10, [0.548,0.483,0.491]], [11, [1.00,1.00,1.00]]]
+ width: [[8, 1.25px], [12, 1.5px], [14, 2.5px], [16, 5.5px], [17, 10px], [18, 10m]]
outline:
- color: [[8, [0.894,0.906,0.914]], [13, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [16, [0.408,0.430,0.461]]]
- width: [[8,0px], [13,0px], [14,1px], [15,2px], [16, 3px], [17, 4px], [18, 5px]]
- #dashedTunnel:
- # width: [[8, 1px], [12, 1.25px], [13, 1.5px], [14, 0px], [15, 1px], [16, 5px], [17, 10px], [18, 10m]]
+ color: [[8, [0.969,0.969,0.969]], [10, [0.969,0.969,0.969]], [11, [0.548,0.483,0.491]]]
+ width: [[8, 1px], [10, 1px], [12, 1.5px], [14, 1.75px], [16, 2.5px], [18, 4px]]
+ early:
+ filter: { $zoom: { max: 15 } } # was max: 15 (11)
+ draw:
+ lines:
+ outline:
+ order: function() { return feature.sort_rank; }
link:
filter: { is_link: true } # on- and off-ramps, etc
draw:
lines:
- #color: *highway_link1
- color: [[9, [0.50,0.50,0.50]], [13, [0.408,0.430,0.461]], [14, [1.0,1.0,1.0]], [15, [1.0,1.0,1.0]]]
- width: [[9, 0px], [11, 0.15px], [12, 0.5px], [13, 0.75px], [14, 0px], [15, 1px], [16, 2.5px], [17, 4px], [18, 8px], [19, 8px]]
+ color: [[11, [0.627,0.612,0.616]], [13, [0.627,0.612,0.616]], [14, [1.00,1.00,1.00]]]
+ width: [[8, 0px], [11, 0.4px], [12, 0.6px], [14, 1.25px], [16, 3px], [18, 5m]]
outline:
- color: [[9,[0.894,0.906,0.914]], [13, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [15, [0.408,0.430,0.461]]]
- width: [[9, 0px], [13, 0px], [14, 0.5px], [15, 1px], [16, 2px], [17, 2px], [18, 2px]]
+ color: [[11, [0.969,0.969,0.969]], [13, [0.969,0.969,0.969]], [14, [0.548,0.483,0.491]]]
+ width: [[8, 0px], [9, 0px], [13, 0px], [14, 0.6px], [16, 1.25px], [18, 2px]]
early_link:
- filter: { $zoom: {min: 13, max: 15} }
+ filter: { $zoom: { max: 15 } }
draw:
lines:
order: 352
+ z12-13:
+ filter: { $zoom: { max: 14 } }
+ draw:
+ lines:
+ order: 351
tunnel-link:
- filter: {is_tunnel: true, $zoom: {min: 13} }
+ filter: { is_tunnel: true, $zoom: { min: 13 } }
draw:
lines:
- color: [[13,[0.790,0.790,0.790]], [14,[0.820,0.820,0.820]], [15,[0.950,0.950,0.950]], [16,[0.950,0.950,0.950]]]
+ color: [0.929,0.929,0.929]
outline:
- color: [0.900,0.900,0.900]
+ color: [0.695,0.739,0.790]
tunnel:
- filter: {is_tunnel: true, $zoom: {min: 13} }
+ filter: { is_tunnel: true, $zoom: { min: 13 } }
draw:
- #dashedTunnel:
- # color: blue
- # order: function() { return (feature.sort_rank - 1); }
lines:
- #visible: false
- color: [[13,[0.710,0.710,0.710]], [14,[0.779,0.802,0.828]], [15,[0.950,0.950,0.950]], [16,[0.950,0.950,0.950]]]
+ color: [0.929,0.929,0.929]
outline:
- color: [[13, [0.720,0.720,0.720]], [14, [0.770,0.770,0.770]], [15, [0.80,0.80,0.80]], [16, [0.825,0.825,0.825]]]
+ color: [0.695,0.739,0.790]
highway_bridge:
- filter: {is_bridge: true}
+ filter: { is_bridge: true }
draw:
lines:
cap: round
outline:
cap: butt
- labels-highway-z13:
- filter:
- $zoom: 13
- draw:
- text-blend-order:
- priority: 50
- visible: *text_visible_highway
- font:
- fill: [0.408,0.427,0.459]
- weight: 600
- size: 11px
- stroke: { color: [0.898,0.906,0.910], width: 4 }
- labels-highway-z14:
- filter:
- $zoom: 14
- draw:
- text-blend-order:
- priority: 50
- visible: *text_visible_highway
- font:
- fill: [0.408,0.427,0.459]
- weight: 600
- size: 11px
- stroke: { color: [0.898,0.906,0.910], width: 4 }
- labels-highway-z15:
+ labels-highway:
filter:
- $zoom: 15
- draw:
- text-blend-order:
- visible: *text_visible_highway
- font:
- fill: [1.0,1.0,1.0]
- weight: 600
- size: 12px
- stroke: { color: [0.408,0.427,0.459], width: 4 }
- labels-highway-z16:
- filter: { $zoom: { min: 16, max: 18 } }
- draw:
- text-blend-order:
- priority: 50
- visible: *text_visible_highway
- font:
- fill: [1.0,1.0,1.0]
- weight: 600
- size: 13px
- stroke: { color: [0.408,0.427,0.459], width: 4 }
- labels-highway-z17:
- filter: { $zoom: { min: 17 } }
- draw:
- text-blend-order:
- priority: 50
- visible: *text_visible_highway
- font:
- fill: [0.408,0.427,0.459]
- weight: 600
- size: 15px
- stroke: { color: [1.000,1.000,1.000], width: 4 }
- labels-highway-z18:
- filter: { $zoom: { min: 18 } }
- draw:
- text-blend-order:
- priority: 50
- visible: *text_visible_highway
- font:
- fill: [0.408,0.427,0.459]
- weight: 600
- size: 16px
- stroke: { color: [1.000,1.000,1.000], width: 4 }
- labels-highway-z19:
- filter: { $zoom: { min: 19 } }
+ $zoom: { min: 13 }
draw:
text-blend-order:
priority: 50
- visible: *text_visible_highway
+ visible: global.text_visible_highway
font:
fill: [0.408,0.427,0.459]
weight: 600
- size: 16px
- stroke: { color: [1.000,1.000,1.000], width: 4 }
+ size: [[13, 11px], [15, 12px], [17, 15px], [19, 16px]]
+ stroke: { color: [[13, [0.898,0.906,0.910]], [16,[1.000,1.000,1.000]]], width: 4px }
major_road:
filter: { kind: major_road }
# default style
draw:
lines:
- color: [[8, *major_road4], [13, major_road2], [17, [1.0,1.0,1.0]]]
- width: [[13, 1px], [14, 1px], [16, 2.5px], [17,3px]]
- outline:
- width: [[12, 0px], [13, .5px], [15, 1px], [17, 2px]]
+ color: [[8, [0.529,0.556,0.592]], [13, [0.529,0.556,0.592]], [15, [1.00,1.00,1.00]]]
+ width: [[10, 0px], [13, 0.5px], [16, 2.5px], [18,3px]]
trunk_primary:
filter: { kind_detail: [trunk, primary] }
draw:
lines:
- color: [[8, [0.529,0.556,0.592]], [11, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[8, 0px], [11, 0.65px], [12, 0.75px], [13, 1px], [14, 1.5px], [15, 0px], [16, 3px], [17, 6px], [18, 9m]]
+ color: [[10, [0.603,0.620,0.642]], [11, [1.00,1.00,1.00]]]
+ width: [[8, 0.5px], [10, 1px], [12, 1px], [14, 2.5px], [16, 4px], [17, 6px], [18, 9m]]
outline:
- color: [[8,[0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- width: [[8,0px], [11,0px], [14,0px], [15, 1px], [16, 1.5px], [17, 2px], [18, 4px]]
+ color: [[8, [0.969,0.969,0.969]], [10, [0.969,0.969,0.969]], [11, [0.629,0.612,0.615]], [14, [0.714,0.694,0.706]]]
+ width: [[8, 0.5px], [10, 1px], [14, 1px], [16, 2.25px], [17, 2px], [18, 4px]]
early:
- filter: { $zoom: { max: 16 } }
+ filter: { $zoom: { max: 14 } }
draw:
lines:
order: 352
routes:
filter: { ref: true }
draw:
- #dashedTunnel:
- # width: [[9, 0.5px], [10, 0.5px], [11, 0.75px], [12, 1.25px], [13, 1.25px], [14, 0px], [15, 1px], [16, 4px], [17, 8px], [18, 9m]]
- # outline:
- # color: green
- # width: [[8,0px], [13,0px], [14,0.75px], [15,2px], [16, 3px], [17, 4px], [18, 4px]]
lines:
- color: [[10, [0.508,0.530,0.561]], [11, [0.408,0.430,0.461]], [13, [0.408,0.430,0.461]], [14,[1.0,1.0,1.0]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[9, 0.6px], [10, 0.75px], [11, 1.0px], [12, 1.1px], [13, 0.8px], [14, 0.5px], [15, 1px], [16, 4px], [17, 8px], [18, 9m]]
+ color: [[8, [0.603,0.620,0.642]], [10, [0.603,0.620,0.642]], [11, [1.00,1.00,1.00]]]
+ width: [[8, 1px], [12, 1px], [14, 2.5px], [16, 5px], [17, 8px], [18, 9m]]
outline:
- color: [[8,[0.894,0.906,0.914]], [13, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- width: [[8,0px], [13,0px], [14,0.75px], [15,2px], [16, 3px], [17, 4px], [18, 4px]]
+ color: [[8, [0.969,0.969,0.969]], [10, [0.969,0.969,0.969]], [11, [0.629,0.612,0.615]], [14, [0.670,0.623,0.654]]]
+ width: [[9, 1px], [10, 1px], [12, 1.25px], [16, 2.25px], [17, 4px]]
early:
- filter: { $zoom: { max: 16 } }
+ filter: { $zoom: { max: 13 } }
draw:
lines:
order: function() { return feature.sort_rank + 2; }
outline:
order: 353
- primary-route-in-green:
- filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield] }
+ earlyz-13:
+ filter: { $zoom: [13] }
draw:
lines:
- color: [[8, [0.408,0.430,0.461]], [11, [0.408,0.430,0.461]], [14,[0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[9, 0.6px], [10, 0.75px], [11, 1.0px], [12, 1.1px], [13, 1.2px], [14, 0.5px], [15, 1px], [16, 4px], [17, 8px], [18, 9m]]
+ order: 352
outline:
- color: [[8,[0.894,0.906,0.914]], [13, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- # national-routes:
- # filter: { network: [US:US, US:I] }
- # draw:
- # lines:
- # color: *major_route1
- # #color: [[8,*major_route2],[9,major_route2],[10,*major_route1]]
- # width: [[8, 1px], [10, 1.15px], [11, 1px], [12, 1px], [14, 1.75px], [15, 3px], [16, 4px], [17, 4px]]
- # outline:
- # color: [1.0,1.0,1.0]
- # width: 2px
+ order: function() { return feature.sort_rank + 1; }
tunnel:
- filter: {is_tunnel: true, $zoom: {min: 13} }
+ filter: { is_tunnel: true, $zoom: { min: 13 } }
draw:
- #dashedTunnel:
- # color: blue
- # order: function() { return (feature.sort_rank - 1); }
lines:
- #visible: false
- color: [[13,[0.710,0.710,0.710]], [14,[0.779,0.802,0.828]], [15,[0.950,0.950,0.950]]] #[15,[0.744,0.764,0.792]]
+ color: [0.883,0.904,0.930]
outline:
- color: [[13, [0.720,0.720,0.720]], [14, [0.770,0.770,0.770]], [15, [0.80,0.80,0.80]], [16, [0.825,0.825,0.825]]] #[15, [0.894,0.906,0.914]]
- labels-trunk_primary-route-z14:
- filter: { $zoom: [14] }
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary_e2
- font:
- fill: [0.495,0.511,0.532]
- size: 11px
- stroke: { color: *text_stroke, width: 3 }
- labels-trunk_primary-route-z15:
- filter: { $zoom: [15] }
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary
- font:
- fill: [0.495,0.511,0.532]
- weight: 600
- size: 12px
- stroke: { color: [0.969,0.973,0.973], width: 3 }
- labels-trunk_primary-route-z16:
- filter: { $zoom: { min: 16 } }
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary
- font:
- fill: [0.495,0.511,0.532]
- weight: 600
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-trunk_primary-route-z17-z18:
- filter: { $zoom: [17,18] }
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary
- font:
- fill: [0.495,0.511,0.532]
- weight: 600
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 6 }
- labels-trunk_primary-route-z19:
- filter: { $zoom: { min: 19 } }
+ color: [0.640,0.703,0.780]
+ labels-trunk_primary-route:
+ filter: { $zoom: { min: 14 } }
draw:
text-blend-order:
priority: 51
- visible: *text_visible_trunk_primary
+ visible: global.text_visible_trunk_primary
font:
fill: [0.495,0.511,0.532]
weight: 600
- size: 16px
- stroke: { color: [0.969,0.973,0.973], width: 6 }
- primary-in-green:
- filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield] }
- draw:
- lines:
- color: [[8, [0.408,0.430,0.461]], [11, [0.408,0.430,0.461]], [14,[0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[9, 0.6px], [10, 0.75px], [11, 1.0px], [12, 1.1px], [13, 1.0px], [14, 0.5px], [15, 1.2px], [16, 4px], [17, 8px], [18, 9m]]
- outline:
- color: [[8,[0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- width: [[8,0px], [13,0px], [14,0.75px], [15,1.5px], [16, 3px], [17, 4px], [18, 4px]]
- tunnel:
- filter: {is_tunnel: true, $zoom: {min: 13} }
- draw:
- lines:
- color: [[13,[0.670,0.670,0.670]], [14,[0.720,0.720,0.720]], [15,[0.920,0.920,0.920]], [16,[0.920,0.920,0.920]]]
- outline:
- color: [[13,[0.894,0.906,0.914]],[14,[0.894,0.906,0.914]],[15,[0.744,0.764,0.792]]]
- width: [[13, 0px], [14, 0px], [15, 1px], [16, 1.5px], [17, 2px], [18, 4px]]
- # golf_course:
- # filter: { landuse_kind: golf_course }
- # draw:
- # lines:
- # outline:
- # color: [[10, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
- # zoo:
- # filter: { landuse_kind: zoo }
- # draw:
- # lines:
- # outline:
- # color: [[10, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
- labels-trunk_primary-z11:
- filter:
- $zoom: [11]
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary_e
- font:
- fill: [0.495,0.511,0.532]
- size: 9px
- stroke: { color: *text_stroke, width: 2 }
- labels-trunk_primary-z12:
- filter:
- $zoom: [12]
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary_e
- font:
- fill: [0.495,0.511,0.532]
- size: 10px
- stroke: { color: *text_stroke, width: 3 }
- labels-trunk_primary-z13:
- filter:
- $zoom: [13]
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary
- font:
- fill: [0.495,0.511,0.532]
- size: 11px
- stroke: { color: *text_stroke, width: 3 }
- labels-trunk_primary-z14:
+ size: [[14, 11px],[15, 12px], [18, 16px]]
+ stroke: { color: [[14, global.text_stroke], [15,[0.969,0.973,0.973]]], width: [[15, 3px], [16, 4px]] }
+ z14:
+ filter: { $zoom: [14] }
+ draw:
+ text-blend-order:
+ visible: global.text_visible_trunk_primary_e2
+ font:
+ weight: normal # or 500 or 400?
+ labels-trunk_primary-z11-up:
filter:
- $zoom: [14]
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary
- font:
- fill: [0.495,0.511,0.532]
- size: 11px
- stroke: { color: *text_stroke, width: 4 }
- labels-trunk_primary-z15:
- filter: { $zoom: [15] }
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary
- font:
- fill: [0.495,0.511,0.532]
- size: 12px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-trunk_primary-z16:
- filter: { $zoom: [16] }
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary
- font:
- fill: [0.495,0.511,0.532]
- weight: 600
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-trunk_primary-z17:
- filter: { $zoom: [17] }
- draw:
- text-blend-order:
- priority: 51
- visible: *text_visible_trunk_primary
- font:
- fill: [0.495,0.511,0.532]
- weight: 600
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 6 }
- labels-trunk_primary-z18:
- filter: { $zoom: { min: 18 } }
+ $zoom: { min: 11 }
draw:
text-blend-order:
priority: 51
- visible: *text_visible_trunk_primary
+ visible: global.text_visible_trunk_primary_e
font:
fill: [0.495,0.511,0.532]
- weight: 600
- size: [[18,13px],[19,16px]]
- stroke: { color: [0.969,0.973,0.973], width: 6 }
+ size: [[11, 9px], [12, 10px], [13, 11px], [14, 11px], [15, 12px], [16, 13px],[ 18, 13px],[19, 16px]]
+ stroke: { color: [[11, global.text_stroke], [15, [0.969,0.973,0.973]]], width: [[11, 2px], [15, 4px], [16, 4px], [17, 6px]] }
+ z16:
+ filter: { $zoom: [16] }
+ draw:
+ text-blend-order:
+ visible: global.text_visible_trunk_primary
+ font:
+ weight: 600
link:
filter: { is_link: true } # on- and off-ramps, etc
draw:
lines:
- color: [[8, [0.529,0.556,0.592]], [11, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[10, 0.5px], [13, 0.5px], [14, 1px], [15, 0px], [16, 1.75px], [17, 2px], [18, 3px], [19, 8px]]
+ color: [[11, [0.627,0.612,0.616]], [13, [0.627,0.612,0.616]], [14, [1.00,1.00,1.00]]]
+ width: [[8, 0px], [11, 0.4px], [12, 0.6px], [14, 1.25px], [16, 3px], [18, 5m]]
outline:
- color: [[8,[0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- width: [[10, 0px], [14, 0px], [15, 0.5px], [16, 1px], [17, 1px], [18, 1px]]
+ color: [[11, [0.969,0.969,0.969]], [13, [0.969,0.969,0.969]], [14, [0.670,0.623,0.654]]]
+ width: [[8, 0px], [9, 0px], [13, 0px], [14, 0.6px], [16, 1.25px], [18, 2px]]
+ early_link:
+ filter: { $zoom: { max: 14 } }
+ draw:
+ lines:
+ order: 351
tunnel:
- filter: {is_tunnel: true, $zoom: {min: 13} }
+ filter: { is_tunnel: true, $zoom: { min: 13 } }
draw:
lines:
- color: [[13,[0.779,0.802,0.828]], [14,[0.779,0.802,0.828]], [15,[0.744,0.764,0.792]], [16,[0.950,0.950,0.950]]]
+ color: [0.883,0.904,0.930]
outline:
- color: [[13, [0.894,0.906,0.914]], [15, [0.894,0.906,0.914]], [16, [0.85,0.85,0.85]]]
- width: [[8,0px], [11,0px], [14,0px], [16,1.5px], [17, 3px], [18, 3px]]
+ color: [0.640,0.703,0.780]
secondary:
filter: { kind_detail: secondary }
draw:
lines:
- color: [[10, [0.714,0.733,0.760]], [11, [0.714,0.733,0.760]], [12, [0.533,0.555,0.586]], [13, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[10, 0.5px], [12, 0.5px], [13, 0.65px], [14, 1px], [15, 0px], [16, 3px], [17, 6px], [18, 9m]]
+ color: [1.00,1.00,1.00]
+ width: [[10, 0px], [11, 0px], [12, 1px], [14, 2px], [16, 4px], [17, 6px], [18, 9m]]
outline:
- color: [[10, [0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- width: [[10,0px], [14,0px], [15,1px], [16, 1.5px], [17, 2px], [18, 4px]]
+ color: [[9, [0.906,0.906,0.906]], [10, [0.788,0.780,0.800]], [11, [0.787,0.763,0.767]], [14, [0.700,0.665,0.688]]]
+ width: [[10, 0px], [11, 0.5px], [12, 1px], [14, 1px], [16, 2.25px], [18, 4px]]
early:
- filter: { $zoom: { max: 16 } }
+ filter: { $zoom: { max: 14 } }
draw:
lines:
order: 352
outline:
order: 353 #function() { return feature.sort_rank + 2; }
+ earlyz-13:
+ filter: { $zoom: [13] }
+ draw:
+ lines:
+ outline:
+ order: function() { return feature.sort_rank + 1; }
routes:
- filter: { ref: true, $zoom: { min: 10} }
+ filter: { ref: true, $zoom: { min: 8 } }
draw:
lines:
- color: [[11, [0.508,0.530,0.561]], [13, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[11, 0.4px], [12, 0.75px], [13, 0.75px], [14, 1px], [15, 0px], [16, 1.5px], [17, 6px], [18, 9m]]
+ color: [[10, [0.584,0.604,0.624]], [11, [1.00, 1.00, 1.00]]]
+ width: [[8, 0px], [10, 0.7px], [11, 1px], [12, 1px], [14, 2px], [16, 4px], [18, 9m]]
outline:
- color: [[10, [0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- width: [[10,0.4px], [14,0.5px], [15,0.65px], [16,1.5px], [17, 2px], [18, 4px]]
+ color: [[9, [0.906,0.906,0.906]], [10, [0.906,0.906,0.906]], [11, [0.787,0.763,0.767]], [14, [0.700,0.665,0.688]]]
+ width: [[9, 0.25px], [10, 0.75px], [11, 0.75px], [12, 1px], [14, 1px], [16, 2.25px], [18, 4px]]
early:
- filter: { $zoom: { max: 15 } }
+ filter: { $zoom: { max: 14 } }
draw:
lines:
order: function() { return feature.sort_rank + 2; }
outline:
order: 353
- secondary-route-in-green:
- filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield] }
- draw:
- lines:
- color: [[11, [0.408,0.430,0.461]], [13, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[11, 0.6px], [12, 0.75px], [13, 0.75px], [14, 1px], [15, 0px], [16, 1.5px], [17, 6px], [18, 9m]]
- outline:
- width: [[10,0.5px], [14,0.5px], [15,0.65px], [16,1.5px], [17, 2px], [18, 4px]]
+ # earlyz-13:
+ # filter: { $zoom: [13] }
+ # draw:
+ # lines:
+ # order: 352
+ # outline:
+ # order: function() { return feature.sort_rank + 1; }
tunnel:
- filter: {is_tunnel: true, $zoom: {min: 13} }
+ filter: { is_tunnel: true, $zoom: { min: 13 } }
draw:
lines:
- color: [[13,[0.779,0.802,0.828]], [14,[0.779,0.802,0.828]], [15,[0.8,0.8,0.8]], [16,[0.85,0.85,0.85]], [17,[0.950,0.950,0.950]]]
+ color: [0.929,0.929,0.929]
outline:
- color: [[13, [0.350,0.350,0.350]], [16, [0.350,0.350,0.350]], [17, [0.85,0.85,0.85]]]
- width: [[10,0px], [17, 2px], [18, 2px]]
- labels-secondary-routes:
- filter: { $zoom: [13] }
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary_e
- font:
- fill: [0.536,0.556,0.581]
- size: 11px
- stroke: { color: *text_stroke, width: 4 }
- labels-secondary-routes-z14:
- filter: { $zoom: [14] }
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary_e
- font:
- fill: [0.536,0.556,0.581]
- size: 11px
- stroke: { color: *text_stroke, width: 4 }
- labels-secondary-routes-z15:
- filter: { $zoom: { min: 15 } }
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary_e
- font:
- fill: [0.536,0.556,0.581]
- weight: 600
- size: 11px
- stroke: { color: *text_stroke, width: 4 }
- labels-secondary-routes-z16:
- filter: { $zoom: { min: 16 } }
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary_e
- font:
- fill: [0.536,0.556,0.581]
- weight: 600
- size: 12px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- secondary-in-green:
- filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield] }
- draw:
- lines:
- color: [[10, [0.714,0.733,0.760]], [11, [0.714,0.733,0.760]], [12, [0.533,0.555,0.586]], [13, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- outline:
- color: [[10, [0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- labels-secondary-in-green-z13:
+ color: [0.695,0.739,0.790]
+ labels-secondary-routes-z13-up:
filter: { $zoom: { min: 13 } }
draw:
text-blend-order:
priority: 56
- visible: *text_visible_secondary_e
- font:
- fill: [0.536,0.556,0.581]
- stroke: { color: [0.843,0.961,0.914], width: 4 }
- labels-secondary-in-green-z17:
- filter: { $zoom: { min: 17 } }
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary_e
+ visible: global.text_visible_secondary_e
font:
fill: [0.536,0.556,0.581]
- stroke: { color: [1.00,1.00,1.00], width: 4 }
- # golf_course:
- # filter: { landuse_kind: golf_course }
- # draw:
- # lines:
- # outline:
- # color: [[10, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
- # zoo:
- # filter: { landuse_kind: zoo }
- # draw:
- # lines:
- # outline:
- # color: [[10, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
- labels-secondary-z13:
- filter:
- $zoom: [13]
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary_e
- font:
- fill: [0.536,0.556,0.581]
- size: 9px
- stroke: { color: *text_stroke, width: 4 }
- labels-secondary-z14:
- filter:
- $zoom: [14]
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary_e
- font:
- fill: [0.536,0.556,0.581]
- size: 9px
- stroke: { color: *text_stroke, width: 4 }
- labels-secondary-z15:
+ size: [[13, 11px], [15, 11px], [16, 12px]]
+ stroke: { color: [[13, global.text_stroke], [16, [0.969,0.973,0.973]]], width: 4px }
+ z15-up:
+ filter: { $zoom: { min: 15 } }
+ draw:
+ text-blend-order:
+ visible: global.text_visible_secondary
+ font:
+ weight: 600
+ labels-secondary:
filter:
- $zoom: [15]
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary
- font:
- fill: [0.536,0.556,0.581]
- size: 10px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-secondary-z16:
- filter: { $zoom: { min: 16, max: 18 } }
- draw:
- text-blend-order:
- priority: 56
- visible: *text_visible_secondary
- font:
- fill: [0.536,0.556,0.581]
- size: 12px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-secondary-z17:
- filter: { $zoom: { min: 17 } }
+ $zoom: { min: 13 }
draw:
text-blend-order:
priority: 56
- visible: *text_visible_secondary
+ visible: global.text_visible_secondary_e
font:
fill: [0.536,0.556,0.581]
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
+ size: [[13, 9px], [14, 9px], [15, 10px], [16, 12px], [17, 13px]]
+ stroke: { color: [[13, global.text_stroke], [15, [0.969,0.973,0.973]]], width: 4px }
tertiary:
filter: { kind_detail: [tertiary, tertiary_link] }
draw:
lines:
- color: [[11, [0.714,0.733,0.760]], [12, [0.633,0.655,0.686]], [13, [0.529,0.556,0.592]], [14,[0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[11, 0.5px], [12, 0.65px], [13, 0.65px], [14, 1px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
+ color: [1.00, 1.00, 1.00]
+ width: [[11, 0px], [12, 0px], [13, 1px], [14, 2px], [16, 3.5px], [17, 6px], [18, 9m]]
outline:
- color: [0.529,0.556,0.592]
- width: [[11, 0px], [14, 0px], [15, 0.75px], [16, 1.5px], [17, 2px], [18, 3px]]
+ color: [[11, [0.847,0.822,0.826]], [12, [0.797,0.770,0.775]], [14, [0.714,0.694,0.706]]]
+ width: [[10, 0px], [11, 0px], [12, 0.3px], [14, 1px], [16, 2px], [17, 2px], [18, 4px]]
early:
- filter: { $zoom: { max: 15 } }
+ filter: { $zoom: { max: 14 } }
draw:
lines:
order: 352
outline:
order: function() { return feature.sort_rank + 3; }
routes:
- filter: { ref: true, $zoom: { min: 12} }
+ filter: { ref: true, $zoom: { min: 12 } }
draw:
lines:
- color: [[11, [0.408,0.430,0.461]], [13, [0.408,0.430,0.461]], [14,[0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[11, 0.3px], [12, 0.4px], [13, .6px], [14, 1px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
+ color: [1.00,1.00,1.00]
+ width: [[11, 0px], [12, 1px], [14, 2px], [16, 3.5px], [17, 6px], [18, 9m]]
outline:
- color: [[11, [0.894,0.906,0.914]], [14,[0.779,0.802,0.828]], [15, [0.529,0.556,0.592]]]
- width: [[11, 0px], [14, 0px], [15, 0.75px], [16, 1.5px], [17, 2px], [18, 3px]]
+ color: [[11, [0.788,0.780,0.800]], [12, [0.797,0.770,0.775]]]
+ width: [[11, 0.4px], [12, 1px], [14, 1px], [16, 2px], [17, 2px], [18, 4px]]
early:
- filter: { $zoom: { max: 15 } }
+ filter: { $zoom: { max: 14 } }
draw:
lines:
order: function() { return feature.sort_rank + 3; }
outline:
order: 353
tunnel:
- filter: {is_tunnel: true, $zoom: {min: 13} }
+ filter: {is_tunnel: true, $zoom: { min: 13 } }
draw:
lines:
- color: *major_tunnel1
+ color: [0.929,0.929,0.929]
outline:
- color: *major_tunnel_casing1
- link:
- filter: { is_link: true } # on- and off-ramps, etc
- draw:
- lines:
- color: [[14, [0.714,0.733,0.760]], [15, [0.578,0.608,0.650]], [16, [0.533,0.555,0.586]], [17, [1.00,1.00,1.00]]]
- width: [[11, 0.0px], [12, 0.15px], [14, 0.15px], [15, 0.75px], [16, 1.25px], [17, 2px], [18, 2px], [19, 4px]]
- outline:
- color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17,[0.578,0.608,0.650]]]
- width: [[11, 0px], [16, 0px], [17, 1px], [18, 1px]]
- tertiary-in-green:
- filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield,forest] }
- draw:
- lines:
- color: [[11, [0.408,0.430,0.461]], [13, [0.408,0.430,0.461]], [14,[0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[11, 0.4px], [12, 0.5px], [13, 0.6px], [14, .8px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
- outline:
- color: [[11, [0.894,0.906,0.914]], [14,[0.779,0.802,0.828]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
- width: [[10,0.5px], [14,0.5px], [15,0.65px], [16,1.5px], [17, 2px], [18, 4px]]
- green-routes:
- filter: { ref: true, $zoom: { min: 12} }
- draw:
- lines:
- width: [[11, 0.5px], [12, 0.6px], [13, 0.7px], [14, .9px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
- labels-tertiary-in-green-z13:
- filter: { $zoom: { min: 13 } }
- draw:
- text-blend-order:
- priority: 57
- visible: *text_visible_tertiary_e
- font:
- fill: [0.536,0.556,0.581]
- stroke: { color: [0.843,0.961,0.914], width: 4 }
- labels-tertiary-in-green-z17:
- filter: { $zoom: { min: 17 } }
- draw:
- text-blend-order:
- priority: 57
- visible: *text_visible_tertiary_e
- font:
- fill: [0.536,0.556,0.581]
- stroke: { color: [1.00,1.00,1.00], width: 4 }
- # golf_course:
- # filter: { landuse_kind: golf_course }
- # draw:
- # lines:
- # outline:
- # color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
- # zoo:
- # filter: { landuse_kind: zoo }
- # draw:
- # lines:
- # outline:
- # color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
- labels-tertiary-z13:
- filter: { $zoom: [13] }
- draw:
- text-blend-order:
- priority: 57
- visible: *text_visible_tertiary_e
- font:
- fill: [0.536,0.556,0.581]
- size: 9px
- stroke: { color: *text_stroke, width: 4 }
- labels-tertiary-z14:
- filter: { $zoom: [14] }
- draw:
- text-blend-order:
- priority: 57
- visible: *text_visible_tertiary_e
- font:
- fill: [0.536,0.556,0.581]
- size: 9px
- stroke: { color: *text_stroke, width: 4 }
- labels-tertiary-z15:
- filter: { $zoom: [15] }
- draw:
- text-blend-order:
- priority: 57
- visible: *text_visible_tertiary
- font:
- fill: [0.536,0.556,0.581]
- size: 10px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-tertiary-z16:
- filter: { $zoom: [16] }
- draw:
- text-blend-order:
- priority: 57
- visible: *text_visible_tertiary
- font:
- fill: [0.536,0.556,0.581]
- size: 12px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-tertiary-z17:
- filter: { $zoom: { min: 17, max: 18 } }
- draw:
- text-blend-order:
- priority: 57
- visible: *text_visible_tertiary
- font:
- fill: [0.536,0.556,0.581]
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-tertiary-z18:
- filter: { $zoom: { min: 18 } }
+ color: global.major_tunnel_casing1
+ # this was needed in the past, but where is an example map location to debug now? hmm.
+ # link:
+ # filter: { is_link: true } # on- and off-ramps, etc
+ # draw:
+ # lines:
+ # color: [[14, [0.714,0.733,0.760]], [15, [0.578,0.608,0.650]], [16, [0.533,0.555,0.586]], [17, [1.00,1.00,1.00]]]
+ # width: [[11, 0.0px], [12, 0.15px], [14, 0.15px], [15, 0.75px], [16, 1.25px], [17, 2px], [18, 2px], [19, 4px]]
+ # outline:
+ # color: [[11, [1.00,1.00,1.00]], [16, [1.00,1.00,1.00]], [17,[0.578,0.608,0.650]]]
+ # width: [[11, 0px], [16, 0px], [17, 1px], [18, 1px]]
+ labels-tertiary:
+ filter:
+ $zoom: { min: 13 }
draw:
text-blend-order:
priority: 57
- visible: *text_visible_tertiary
+ visible: global.text_visible_tertiary
font:
fill: [0.536,0.556,0.581]
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
+ size: [[13, 9px], [15, 10px], [16, 12px], [17, 13px]]
+ stroke: { color: [[13, global.text_stroke], [15, [0.969,0.973,0.973]]], width: 4px }
minor_road:
filter: { kind: minor_road, not: { kind_detail: service } }
draw:
lines:
- color: [[11, [0.885,0.885,0.885]], [12, [0.714,0.733,0.760]], [13, [0.779,0.802,0.828]], [14, [0.779,0.802,0.828]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- width: [[11, 0.25px], [12, 0.35px], [13, 0.55px], [14, 1px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
+ color: [1.00,1.00,1.00] #[[12, [0.850,0.850,0.850]], [13, [0.714,0.733,0.760]], [16, [1.00,1.00,1.00]]]
+ width: [[11, 0px], [12, 0.5px], [13, 0.5px], [14, 1px], [16, 3px], [18, 9m]]
outline:
- color: [[11, [0.894,0.906,0.914]], [14, [0.779,0.802,0.828]], [15, [0.714,0.733,0.760]], [16, [0.714,0.733,0.760]], [17, [0.744,0.764,0.792]]]
- width: [[11, 0px], [14, 0px], [15, 0.75px], [16, 1.5px], [17, 2px], [18, 3px]]
+ color: [[12, [0.900,0.900,0.900]], [13, [0.774,0.797,0.823]], [14, [0.798,0.823,0.847]]]
+ width: [[11, 0px], [12, 0px], [13, 0px], [14, 1px], [16, 1.5px], [17, 2px], [18, 3px]]
early:
- filter: { $zoom: { max: 16 } }
+ filter: { $zoom: { max: 14 } }
draw:
lines:
order: 350
lines:
cap: round
join: round
-
- minor-in-green:
- filter: { landuse_kind: [park,protected_area,nature_reserve,conservation,golf_course,garden,wood,farmland,farm,national_park,protected_area,battlefield] }
- draw:
- lines:
- color: [[11, [0.885,0.885,0.885]], [12, [0.662,0.681,0.704]], [13, [0.662,0.681,0.704]], [14, [0.662,0.681,0.704]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
- outline:
- color: [[11, [0.894,0.906,0.914]], [14, [0.662,0.681,0.704]], [15, [0.662,0.681,0.704]], [16, [0.662,0.681,0.704]]]
- labels-minor-in-green-z15:
- filter: { $zoom: { min: 15 } }
- draw:
- text-blend-order:
- priority: 59
- visible: *text_visible_minor_road_e
- font:
- fill: [0.536,0.556,0.581]
- stroke: { color: [0.843,0.961,0.914], width: 4 }
- labels-minor-in-green-z17:
- filter: { $zoom: { min: 17 } }
- draw:
- text-blend-order:
- priority: 59
- visible: *text_visible_minor_road_e
- font:
- fill: [0.536,0.556,0.581]
- stroke: { color: [1.00,1.00,1.00], width: 4 }
- # golf_course:
- # filter: { landuse_kind: golf_course }
- # draw:
- # lines:
- # outline:
- # color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.30,0.30,0.30]], [18, [0.00,0.00,0.00]]]
- # zoo:
- # filter: { landuse_kind: zoo }
- # draw:
- # lines:
- # outline:
- # color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.30,0.30,0.30]], [18, [0.00,0.00,0.00]]]
- # in_university:
- # filter: { landuse_kind: university }
- # draw:
- # lines:
- # color: [[11, [0.885,0.885,0.885]], [13, [0.75,0.75,0.75]], [14, [0.70,0.70,0.70]], [15, [0.6,0.6,0.6]], [16, [0.3,0.3,0.3]], [17, [1.0,1.0,1.0]]]
- # outline:
- # color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
- # width: [[11, 1px], [16, 0px], [17, 1.5px]]
- # in_hospital:
- # filter: { landuse_kind: hospital }
- # draw:
- # lines:
- # color: [[11, [0.885,0.885,0.885]], [13, [0.75,0.75,0.75]], [14, [0.70,0.70,0.70]], [15, [0.6,0.6,0.6]], [16, [0.3,0.3,0.3]], [17, [1.0,1.0,1.0]]]
- # outline:
- # color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
- # width: [[11, 1px], [16, 0px], [17, 1.5px]]
-
tunnel:
- filter: {is_tunnel: true, $zoom: {min: 13} }
+ filter: { is_tunnel: true, $zoom: { min: 13 } }
draw:
lines:
- color: *minor_tunnel1
+ color: global.minor_tunnel1
outline:
- color: *minor_tunnel_casing1
+ color: global.minor_tunnel_casing1
minor_road_bridge:
filter: { is_bridge: true }
draw:
cap: round
outline:
cap: butt
- labels-minor_road-z15:
- filter: { $zoom: 15 }
- draw:
- text-blend-order:
- priority: 59
- visible: *text_visible_minor_road_e
- font:
- fill: [0.536,0.556,0.581]
- size: 9px
- stroke: { color: *text_stroke, width: 4 }
- labels-minor_road-z16:
- filter: { $zoom: 16 }
- draw:
- text-blend-order:
- priority: 59
- visible: *text_visible_minor_road_e
- font:
- fill: [0.536,0.556,0.581]
- size: 12px
- stroke: { color: *text_stroke, width: 4 }
- labels-minor_road-z17:
- filter: { $zoom: { min: 17, max: 18 } }
+ labels-minor_road:
+ filter:
+ $zoom: { min: 15 }
draw:
text-blend-order:
priority: 59
- visible: *text_visible_minor_road_e
+ visible: global.text_visible_minor_road_e
font:
- fill: [0.40,0.40,0.40]
- size: 12px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-minor_road-z18:
- filter: { $zoom: { min: 18 } }
+ fill: [[15, [0.536,0.556,0.581]], [17, [0.40,0.40,0.40]]]
+ size: [[15, 9px], [16, 12px], [17, 12px], [18, 13px]]
+ stroke: { color: [[15, global.text_stroke], [17,[0.969,0.973,0.973]]], width: 4px }
+ early-residential:
+ filter: { kind_detail: residential, $zoom: { max: 15 } }
draw:
- text-blend-order:
- priority: 59
- visible: *text_visible_minor_road
- font:
- fill: [0.40,0.40,0.40]
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
+ lines:
+ order: 350
+ outline:
+ order: 351
service_road:
filter: { kind: minor_road, kind_detail: service }
draw:
lines:
- color: [[14, [0.714,0.733,0.760]], [15, [0.714,0.733,0.760]], [16, [1.0,1.0,1.0]], [17, [1.0,1.0,1.0]]]
- width: [[14, 0.25px], [15, 0.5px], [16, 0px], [17, 2px], [18, 6px], [19, 6px]]
+ color: [1.00,1.00,1.00]
+ width: [[14, 1px], [16, 2px], [18, 4m]]
outline:
- color: [[14,[0.894,0.906,0.914]], [15,[0.714,0.733,0.760]], [16,[0.714,0.733,0.760]], [17, [0.791,0.812,0.842]]]
- width: [[13, 0px], [15, 0px], [16, 0.5px], [17, 2px], [18, 2px]]
- service-in-green:
- filter: { landuse_kind: [park,protected_area,nature_reserve,conservation,golf_course,garden,wood,farmland,farm,national_park,battlefield] }
- draw:
- lines:
- color: [[14, [0.779,0.802,0.828]], [15, [0.779,0.802,0.828]], [16, [1.0,1.0,1.0]], [17, [1.0,1.0,1.0]]]
- outline:
- color: [[14,[0.894,0.906,0.914]], [15,[0.714,0.733,0.760]], [17,[0.714,0.733,0.760]]]
- labels-service-in-green:
- draw:
- text-blend-order:
- priority: 60
- visible: *text_visible_service_road
- font:
- fill: [0.536,0.556,0.581]
- stroke: { color: [0.843,0.961,0.914], width: 4 }
- # golf_course:
- # filter: { landuse_kind: golf_course }
- # draw:
- # lines:
- # outline:
- # color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
- # width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
- # nature_reserve:
- # filter: { landuse_kind: nature_reserve }
- # draw:
- # lines:
- # outline:
- # color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
- # width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
- # conservation:
- # filter: { landuse_kind: conservation }
- # draw:
- # lines:
- # outline:
- # color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
- # width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
- # zoo:
- # filter: { landuse_kind: zoo }
- # draw:
- # lines:
- # outline:
- # color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
- # width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
- in_cemetery_garden:
- filter: { landuse_kind: [cemetery,garden] }
+ color: [[12, [0.900,0.900,0.900]], [14, [0.791,0.816,0.840]]]
+ width: [[13, 0px], [14, 0.5px], [16, 1px], [18, 2px]]
+ early:
+ filter: { $zoom: { max: 15 } }
draw:
lines:
- color: [[14, [0.779,0.802,0.828]], [15, [0.779,0.802,0.828]], [16, [1.0,1.0,1.0]], [17, [1.0,1.0,1.0]]]
- width: [[14, 0.4px], [15, 0.5px], [16, 0px], [17, 2px], [18, 6px], [19, 6px]]
+ order: 350
outline:
- color: [[14,[0.894,0.906,0.914]], [15,[0.714,0.733,0.760]], [17,[0.714,0.733,0.760]]]
- # in_university:
- # filter: { landuse_kind: university }
- # draw:
- # lines:
- # outline:
- # color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
- # width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
- # in_hospital:
- # filter: { landuse_kind: hospital }
- # draw:
- # lines:
- # outline:
- # color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
- # width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
+ order: 351
labels-service_road:
- filter: { $zoom: 17 }
- draw:
- text-blend-order:
- priority: 60
- visible: *text_visible_service_road
- font:
- # need fill color?
- fill: [0.536,0.556,0.581]
- size: 12px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
- labels-service_road-z18:
- filter: { $zoom: { min: 18 } }
+ filter:
+ $zoom: { min: 17 }
draw:
text-blend-order:
priority: 60
- visible: *text_visible_service_road
+ visible: global.text_visible_service_road
font:
fill: [0.536,0.556,0.581]
- size: 13px
- stroke: { color: [0.969,0.973,0.973], width: 4 }
+ size: [[17, 12px], [18, 13px]]
+ stroke: { color: [0.969,0.973,0.973], width: 4px }
- path:
+
+ shields:
filter:
- all:
- - kind: [path, portage_way]
- not:
- - kind_detail: [footway, steps, track, cycleway]
- - kind_detail: [pier]
+ $zoom: { min: 6 }
+ #
+ # United State looks great with shield_text alone, but...
+ #
+ #shield_text: true # some roads don't have shield text, deal with that later
+ #
+ # Europe doesn't have many network relations set, so we could look for either
+ # shield_text or ref (with no shield_text) but...
+ # that makes United States look a bit funky with `(xxx)` and generic shields
+ # showing up in fields of custom state shields like US:CA and US:NY
+ #
+ any:
+ - shield_text: true # some roads don't have shield text, deal with that later
+ - all:
+ - shield_text: false # some roads don't have shield text, deal with that later
+ - ref: true
+ - kind_detail: [motorway, trunk, primary, secondary, tertiary]
+ # default
draw:
- dashedline:
- order: function() { return feature.sort_rank; }
+ icons:
+ # you need to match any custom shield to the vector tile `network` values
+ sprite: |
+ function() {
+ if( feature.shield_text ) {
+ return ('generic_shield-' + feature.shield_text.length + 'char');
+ } else {
+ return ('generic_shield-' + feature.ref.length + 'char');
+ }
+ }
+ sprite_default: generic_shield_5char
+ priority: 58
+ repeat_group: shields
+ repeat_distance: [[8,90px],[10,40px],[13,30px]]
+ placement: midpoint
+ placement_min_length_ratio:
+ - [8, 0.1]
+ - [9, 0.25]
+ - [10, 0.25]
+ - [11, 0.15]
+ - [12, 1]
+ - [13, 1.50]
+ - [14, 2.0]
+ cull_from_tile: true
visible: false
- color: [0.350,0.350,0.350]
- width: [[14, 0.35px], [15, 0.5px], [16, 1px], [17, 2px], [18, 3px], [19, 4px]]
- # outline:
- # color: [0.790,0.790,0.790]
- # width: [[14, 0.0px], [15, 0.35px], [16, 0.45px], [17, 0.85px], [18, 1px]]
- early:
+ text:
+ offset: [0px, -0.5px]
+ repeat_distance: 200px
+ anchor: center
+ text_source: |
+ function() {
+ if( feature.shield_text ) {
+ return feature.shield_text;
+ } else {
+ return feature.ref;
+ }
+ }
+ font:
+ family: Montserrat
+ #fill: [0.308,0.308,0.308]
+ fill: [0.320,0.320,0.320]
+ size: [[7,7px],[12,8px],[16,11px]]
+
+ default_priority_highway:
filter:
- $zoom: { max: 17 }
+ all:
+ - kind_detail: motorway
+ - $zoom: { min: 9 }
+ draw:
+ icons:
+ priority: 47
+ #color: yellow
+ visible: global.sdk_road_shields
+
+ default_priority_trunk:
+ filter:
+ all:
+ - kind_detail: [trunk]
+ - $zoom: { min: 10 }
+ draw:
+ icons:
+ priority: 48
+ #color: red
+ visible: global.sdk_road_shields
+ default_priority_primary:
+ filter:
+ all:
+ - kind_detail: [primary]
+ - $zoom: { min: 12 }
+ draw:
+ icons:
+ priority: 49
+ #color: aqua
+ visible: global.sdk_road_shields
+ default_priority_trunk_secondary:
+ filter:
+ all:
+ - kind_detail: [secondary]
+ - $zoom: { min: 12 }
+ draw:
+ icons:
+ priority: 53
+ #color: blue
+ visible: global.sdk_road_shields
+ default_priority_trunk_tertiary:
+ filter:
+ all:
+ - kind_detail: tertiary
+ - $zoom: { min: 13 }
+ draw:
+ icons:
+ priority: 55
+ #color: green
+ visible: global.sdk_road_shields
+ # not-special:
+ # filter:
+ # not: { network: ['US:I','US:US'] }
+ # $zoom: { max: 9 }
+ # draw:
+ # icons:
+ # visible: false
+ width_1char:
+ filter: |
+ function() {
+ if( feature.shield_text ) {
+ return (feature.shield_text.length === 1)
+ } else {
+ return (feature.ref.length === 1)
+ }
+ }
+ draw:
+ icons:
+ size: [[6,[14px,14px]],[13,[16px,16px]],[16,[18px,18px]]]
+ width_2char:
+ filter: |
+ function() {
+ if( feature.shield_text ) {
+ return (feature.shield_text.length === 2)
+ } else {
+ return (feature.ref.length === 2)
+ }
+ }
+ draw:
+ icons:
+ size: [[6,[18px,14px]],[13,[20px,15px]],[16,[24px,18px]]]
+ width_3char:
+ filter: |
+ function() {
+ if( feature.shield_text ) {
+ return (feature.shield_text.length === 3)
+ } else {
+ return (feature.ref.length === 3)
+ }
+ }
+ draw:
+ icons:
+ size: [[6,[25px,14px]],[13,[27px,15px]],[16,[33px,18px]]]
+ width_4char:
+ filter: |
+ function() {
+ if( feature.shield_text ) {
+ return (feature.shield_text.length === 4)
+ } else {
+ return (feature.ref.length === 4)
+ }
+ }
+ draw:
+ icons:
+ size: [[6,[29px,14px]],[13,[31px,15px]],[16,[38px,18px]]]
+ # London sucks
+ early:
+ filter: { $zoom: { max: 14 } }
+ draw:
+ icons:
+ visible: false
+ width_5char:
+ filter: |
+ function() {
+ if( feature.shield_text ) {
+ return (feature.shield_text.length === 5)
+ } else {
+ return (feature.ref.length === 5)
+ }
+ }
+ draw:
+ icons:
+ size: [[6,[34px,14px]],[13,[37px,15px]],[16,[45px,18px]]]
+ # London sucks
+ early:
+ filter: { $zoom: { max: 14 } }
+ draw:
+ icons:
+ visible: false
+ # this is kinda a hack
+ width_longggggg:
+ filter: |
+ function() {
+ if( feature.shield_text ) {
+ return (feature.shield_text.length > 5)
+ } else {
+ return (feature.ref.length > 5)
+ }
+ }
+ draw:
+ icons:
+ visible: false
+ # missing-route-relations:
+ # filter: { shield_text: false }
+ # draw:
+ # lines:
+ # order: 1000
+ # color: red
+ # width: 2px
+ #
+ # Now for the good stuff
+ #
+ legit-shields:
+ filter: { shield_text: true }
+ # draw:
+ # icons:
+ # color: red
+ # US Interstate roads
+ US-I:
+ filter:
+ network: 'US:I'
+ draw:
+ icons:
+ # you need to match any custom shield to the vector tile `network` values
+ sprite: function() { return (feature.network + '-' + feature.shield_text.length + 'char'); }
+ priority: 46
+ visible: global.sdk_road_shields
+ text:
+ offset: [0px, 0.5px]
+ font:
+ fill: [1.0,1.0,1.0]
+ size: [[7,8px],[13,9px],[15,11px]]
+ width_1char:
+ filter: function() { return (feature.shield_text.length === 1) }
+ draw:
+ icons:
+ size: [[6,[15px,18px]],[13,[17px,20px]],[15,[22px,25px]]]
+ width_2char:
+ filter: function() { return (feature.shield_text.length === 2) }
+ draw:
+ icons:
+ size: [[6,[18px,18px]],[13,[20px,20px]],[15,[25px,25px]]]
+ width_3char:
+ filter: function() { return (feature.shield_text.length === 3) }
+ draw:
+ icons:
+ size: [[6,[23px,18px]],[13,[26px,20px]],[15,[33px,25px]]]
+ width_4char:
+ filter: function() { return (feature.shield_text.length === 4) }
+ draw:
+ icons:
+ size: [[6,[25px,18px]],[13,[27px,20px]],[15,[35px,25px]]]
+ width_5char:
+ filter: function() { return (feature.shield_text.length === 5) }
+ draw:
+ icons:
+ size: [[6,[26px,18px]],[13,[30px,20px]],[15,[38px,25px]]]
+ # US Federal Routes
+ US-US:
+ filter:
+ network: ['US:US','US:US:Business', 'US:US:Truck', 'US:US:Alternate']
+ $zoom: { min: 7 }
+ draw:
+ icons:
+ # you need to match any custom shield to the vector tile `network` values
+ sprite: |
+ function() { return ('US:US-' + feature.shield_text.length + 'char'); }
+ priority: 47
+ cull_from_tile: true
+ visible: global.sdk_road_shields
+ text:
+ offset: [0px, -0.7px]
+ font:
+ fill: [0.0,0.0,0.0]
+ size: [[7,8px],[13,9px],[15,11px]]
+ # early:
+ # filter: { $zoom: [7] }
+ # icons:
+ # visible: false
+ width_1char:
+ filter: function() { return (feature.shield_text.length === 1) }
+ draw:
+ icons:
+ size: [[6,[15px,17px]],[13,[17px,19px]],[15,[22px,24px]]]
+ width_2char:
+ filter: function() { return (feature.shield_text.length === 2) }
+ draw:
+ icons:
+ size: [[6,[18px,17px]],[13,[20px,19px]],[15,[26px,24px]]]
+ width_3char:
+ filter: function() { return (feature.shield_text.length === 3) }
+ draw:
+ icons:
+ size: [[6,[22px,17px]],[13,[25px,19px]],[15,[34px,25px]]]
+ width_4char:
+ filter: function() { return (feature.shield_text.length === 4) }
+ draw:
+ icons:
+ size: [[6,[25px,17px]],[13,[29px,19px]],[15,[39px,25px]]]
+ width_5char:
+ filter: function() { return (feature.shield_text.length === 5) }
+ draw:
+ icons:
+ size: [[6,[27px,17px]],[13,[30px,19px]],[15,[41px,25px]]]
+ # US State Routes
+ # US-states:
+ # # Match state highways: `US:??`
+ # filter: |
+ # function() {
+ # return feature.shield_text &&
+ # /^US:(?!US)\w\w$/.test(feature.network)
+ # }
+ # draw:
+ # icons:
+ # # you need to match any custom shield to the vector tile `network` values
+ # priority: 18
+ # early:
+ # filter: { $zoom: [7,8,9] }
+ # icons:
+ # visible: false
+ US-CA:
+ # Match California state highways: `US:CA`
+ filter: |
+ function() {
+ return feature.shield_text &&
+ /^US:CA$/.test(feature.network)
+ }
+ draw:
+ icons:
+ sprite: function() { return (feature.network + '-' + feature.shield_text.length + 'char'); }
+ text:
+ offset: [0px, 1px]
+ font:
+ fill: [1.0,1.0,1.0]
+ size: [[7,7px],[13,9px],[15,10px]]
+ motorway:
+ filter: { kind_detail: [motorway], $zoom: [7,8] }
+ draw:
+ icons:
+ visible: global.sdk_road_shields
+ trunk:
+ filter: { kind_detail: [trunk], $zoom: [8,9] }
+ draw:
+ icons:
+ visible: global.sdk_road_shields
+ primary:
+ filter: { kind_detail: primary, $zoom: [10,11] }
+ draw:
+ icons:
+ visible: global.sdk_road_shields
+ width_1char:
+ filter: function() { return (feature.shield_text.length === 1) }
+ draw:
+ icons:
+ size: [[6,[14px,16px]],[13,[15px,18px]],[15,[18px,21px]]]
+ width_2char:
+ filter: function() { return (feature.shield_text.length === 2) }
+ draw:
+ icons:
+ size: [[6,[18px,18px]],[13,[20px,20px]],[15,[23px,23px]]]
+ width_3char:
+ filter: function() { return (feature.shield_text.length === 3) }
+ draw:
+ icons:
+ size: [[6,[21px,18px]],[13,[24px,20px]],[15,[28px,23px]]]
+ width_4char:
+ filter: function() { return (feature.shield_text.length === 4) }
+ draw:
+ icons:
+ size: [[6,[24px,18px]],[13,[26px,20px]],[15,[31px,23px]]]
+ width_5char:
+ filter: function() { return (feature.shield_text.length === 5) }
+ draw:
+ icons:
+ size: [[6,[25px,18px]],[13,[27px,20px]],[15,[32px,23px]]]
+ US-NY:
+ # Match New York state highways: `US:NY`
+ filter: |
+ function() {
+ return feature.shield_text &&
+ /^US:NY$/.test(feature.network)
+ /* (/^US:NY$/.test(feature.network) || /^NY:US$/.test(feature.network)) */
+ }
+ draw:
+ icons:
+ sprite: |
+ function() { return ( 'US:NY-' + feature.shield_text.length + 'char'); }
+ text:
+ # offset: [0px, 1px]
+ font:
+ fill: [0.0,0.0,0.0]
+ size: [[7,7px],[13,9px],[15,10px]]
+ width_1char:
+ filter: function() { return (feature.shield_text.length === 1) }
+ draw:
+ icons:
+ size: [[6,[13px,17px]],[13,[15px,19px]],[15,[18px,22px]]]
+ width_2char:
+ filter: function() { return (feature.shield_text.length === 2) }
+ draw:
+ icons:
+ size: [[6,[17px,17px]],[13,[19px,19px]],[15,[22px,22px]]]
+ width_3char:
+ filter: function() { return (feature.shield_text.length === 3) }
+ draw:
+ icons:
+ size: [[6,[20px,17px]],[13,[22px,19px]],[15,[27px,22px]]]
+ width_4char:
+ filter: function() { return (feature.shield_text.length === 4) }
+ draw:
+ icons:
+ size: [[6,[21px,17px]],[13,[24px,19px]],[15,[29px,22px]]]
+ width_5char:
+ filter: function() { return (feature.shield_text.length === 5) }
+ draw:
+ icons:
+ size: [[6,[22px,17px]],[13,[25px,19px]],[15,[30px,22px]]]
+ US-PA:
+ # Match Pennsylvania state highways
+ filter: |
+ function() {
+ return feature.shield_text &&
+ /^US:PA$/.test(feature.network)
+ }
+ draw:
+ icons:
+ sprite: |
+ function() { return ( 'US:PA-' + feature.shield_text.length + 'char'); }
+ text:
+ offset: [0px, 1px]
+ font:
+ fill: [0.0,0.0,0.0]
+ size: [[7,7px],[13,9px],[15,10px]]
+ width_1char:
+ filter: function() { return (feature.shield_text.length === 1) }
+ draw:
+ icons:
+ size: [[6,[13px,17px]],[13,[15px,19px]],[15,[18px,22px]]]
+ width_2char:
+ filter: function() { return (feature.shield_text.length === 2) }
+ draw:
+ icons:
+ size: [[6,[17px,17px]],[13,[19px,19px]],[15,[22px,22px]]]
+ width_3char:
+ filter: function() { return (feature.shield_text.length === 3) }
+ draw:
+ icons:
+ size: [[6,[21px,17px]],[13,[24px,19px]],[15,[28px,22px]]]
+ width_4char:
+ filter: function() { return (feature.shield_text.length === 4) }
+ draw:
+ icons:
+ size: [[6,[22px,17px]],[13,[25px,19px]],[15,[30x,22px]]]
+ width_5char:
+ filter: function() { return (feature.shield_text.length === 5) }
+ draw:
+ icons:
+ size: [[6,[24px,17px]],[13,[27px,19px]],[15,[32px,22px]]]
+ # USA County Routes
+ US-counties:
+ # Match state highways: `US:??:*`
+ #
+ # this is very USA specific
+ #
+ # filter: |
+ # function() {
+ # return feature.shield_text &&
+ # /^US:(?!US)\w\w:.*$/.test(feature.network)
+ # }
+ #
+ # this generic for any country with 3rd level networks (like county routes in USA)
+ # BEWARE:
+ # US:US:Business about 150
+ # US:US:Truck
+ # US:US:Alternate
+ #
+ # STATE ROUTE
+ # ??:??:Loop about 200
+ # ??:??:Spur about 200
+ # ??:??:Business about 100
+ #
+ # STATE TEXAS SPECIAL ROUTE
+ # US:TX:FM -- probably just state? there are 3k of these
+ #
+ #
+ filter: |
+ function() {
+ return feature.shield_text &&
+ /^\w+:\w+:(!Alternate).+$/.test(feature.network) &&
+ $zoom > 10
+ }
+ draw:
+ icons:
+ # you need to match any custom shield to the vector tile `network` values
+ sprite: function() { return ('county_shield-' + feature.shield_text.length + 'char'); }
+ # priority: 19
+ visible: global.sdk_road_shields
+ text:
+ font:
+ fill: [0.320,0.320,0.320]
+ #size: [[11,7px],[15,10px]]
+ # early:
+ # filter: { $zoom: { max: 11 } }
+ # draw:
+ # icons:
+ # visible: false
+ width_1char:
+ filter: function() { return (feature.shield_text.length === 1) }
+ draw:
+ icons:
+ size: [[6,[14px,14px]],[13,[16px,16px]],[15,[18px,18px]]]
+ width_2char:
+ filter: function() { return (feature.shield_text.length === 2) }
+ draw:
+ icons:
+ size: [[6,[16px,14px]],[13,[18px,15px]],[15,[22px,18px]]]
+ width_3char:
+ filter: function() { return (feature.shield_text.length === 3) }
+ draw:
+ icons:
+ size: [[6,[20px,14px]],[13,[21px,15px]],[15,[26px,18px]]]
+ width_4char:
+ filter: function() { return (feature.shield_text.length === 4) }
+ draw:
+ icons:
+ size: [[6,[25px,14px]],[13,[28px,15px]],[15,[34px,18px]]]
+ width_5char:
+ filter: function() { return (feature.shield_text.length === 5) }
+ draw:
+ icons:
+ size: [[6,[30px,14px]],[13,[33px,15px]],[15,[40px,18px]]]
+ path:
+ filter:
+ all:
+ - kind: [path, portage_way]
+ not:
+ - kind_detail: [footway, steps, track, cycleway]
+ - kind_detail: [pier]
+ draw:
+ dashed_small:
+ order: function() { return feature.sort_rank; }
+ visible: false
+ color: [0.350,0.350,0.350]
+ width: [[14, 0.35px], [15, 0.5px], [16, 1px], [17, 2px], [18, 3px], [19, 4px]]
+ # outline:
+ # color: [0.790,0.790,0.790]
+ # width: [[14, 0.0px], [15, 0.35px], [16, 0.45px], [17, 0.85px], [18, 1px]]
+ early:
+ filter:
+ $zoom: { max: 17 }
draw:
lines:
order: 351
width: [[14, 0.35px], [15, 0px], [16, 0.25px], [17, 3px], [18, 3px], [19, 4px]]
cap: round
outline:
- color: [[15,*path_bridge_casing2],[16,*path_bridge_casing1]]
+ color: [[15, global.path_bridge_casing2],[16, global.path_bridge_casing1]]
width: [[14, 0.0px], [15, 0.35px], [16, 0.45px], [17, 0.85px], [18, 1px]]
cap: butt
in_park:
filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden] }
draw:
- dashedline:
+ dashed_small:
color: [0.350,0.350,0.350]
# outline:
# color: [0.790,0.790,0.790]
draw:
text-blend-order:
priority: 61
- visible: *text_visible_path
+ visible: global.text_visible_path
font:
fill: [0.536,0.556,0.581]
size: 12px
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
track:
filter: { kind: path, kind_detail: track }
draw:
# filter: { landuse_kind: university }
# draw:
# dashed:
- # color: *path_steps1_b
+ # color: global.path_steps1_b
# outline:
# color: [1.0,1.0,1.0]
# in_hospital:
# filter: { landuse_kind: hospital }
# draw:
# dashed:
- # color: *path_steps1_b
+ # color: global.path_steps1_b
# outline:
# color: [1.0,1.0,1.0]
labels-steps:
draw:
text-blend-order:
priority: 63
- visible: *text_visible_steps
+ visible: global.text_visible_steps
font:
fill: [0.45,0.45,0.45]
size: 11px
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
winter_sport_pistes:
filter: { kind: piste }
draw:
width: [[13,0px],[14,1px],[15, 1.25px], [16, 2px], [18, 3m]]
text-blend-order:
priority: 18
- visible: *text_visible_piste
+ visible: global.text_visible_piste
font:
- fill: *text_fill_piste
+ fill: global.text_fill_piste
size: 12px
stroke: { color: [0.913,0.925,0.933], width: 4 }
early:
draw:
text-blend-order:
font:
- fill: *text_fill_piste_e
+ fill: global.text_fill_piste_e
size: 11px
easy:
filter: { piste_difficulty: easy }
draw:
text-blend-order:
priority: 63
- visible: *text_visible_aerialway
+ visible: global.text_visible_aerialway
text_source: global.ux_language_text_source
font:
- fill: *text_fill
+ fill: global.text_fill
size: 10px
- stroke: { color: *text_stroke_park, width: 4 }
+ stroke: { color: global.text_stroke_park, width: 4 }
minor:
filter: { not: { kind_detail: [gondola,cable_car,chair_lift] }, $zoom: { max: 17 } }
draw:
extrude:
filter:
all:
- - function() { return global.building_extrude; }
+ - function() { return global.sdk_building_extrude; }
- any:
# for the buildings that were visible at zoom 15, extrude those all up a bit at z17
- { $zoom: [16], area: { min: 20000 }, name: true }
lines:
extrude: 100
-
- # landuse-specific rules
- # in_park:
- # filter: { landuse_kind: [park,forest,nature_reserve,conservation,golf_course,garden] }
- # draw:
- # polygons:
- # color: [0.864,0.910,0.905]
-
- # # golf_course:
- # # filter: { landuse_kind: golf_course }
- # # draw:
- # # polygons:
- # # color: *building2
- # # nature_reserve:
- # # filter: { landuse_kind: nature_reserve }
- # # draw:
- # # polygons:
- # # color: *building2
- # # conservation:
- # # filter: { landuse_kind: conservation }
- # # draw:
- # # polygons:
- # # color: *building2
- # # zoo:
- # # filter: { landuse_kind: zoo }
- # # draw:
- # # polygons:
- # # color: *building2
- # in_university:
- # filter: { landuse_kind: [university,school] }
- # draw:
- # polygons:
- # color: [0.950,0.917,0.883]
- # lines:
- # color: *brown1_bo
- # in_hospital:
- # filter: { landuse_kind: hospital }
- # draw:
- # polygons:
- # color: [0.976,0.908,0.913]
- # in_airport:
- # filter: { landuse_kind: [aerodrome, runway, taxiway] }
- # draw:
- # polygons:
- # color: *purple_b
- # lines:
- # color: *purple_bo
- # width: [[14,0.5px],[15,0.5px],[17,0.5px],[18,0.75px],[19,0.25m]]
- # in_retail:
- # filter: { landuse_kind: retail }
- # draw:
- # polygons:
- # color: [0.945, 0.898, 0.878]
-
transit-overlay-station-buildings:
filter:
- any:
+ all:
- landuse_kind: [station]
+ - function() { return global.sdk_transit_overlay; }
draw:
polygons:
- visible: global.sdk_transit_overlay
color: '#bdadbf'
order: 500
#extrude: function() { return feature.height || 20; }
outline:
- visible: global.sdk_transit_overlay
style: lines
order: 501
color: '#d534df'
- $geometry: point
- not: { location: underground, kind: address }
- name: true
+ - function() { return global.text_visible_building; }
any:
- { $zoom: [16], area: { min: 5000 } }
- { $zoom: [16], area: { min: 5000 } }
draw:
text-blend-order:
text_source: global.ux_language_text_source
- interactive: global.interactive
+ #interactive: global.interactive
move_into_tile: true
priority: 70
- visible: *text_visible_building
order: 7
font:
fill: '#666'
- family: *text_font_family
+ family: global.text_font_family
style: italic
size: 11px
- stroke: { color: *text_stroke_address, width: 1 }
+ stroke: { color: global.text_stroke_address, width: 1 }
building_labels-z15-z16-z17:
filter: { $zoom: [15,16,17] }
draw: { text-blend-order: { font: { size: 12px, stroke: { width: 2 } } } }
text_source: global.ux_language_text_source_building_and_address
address-labels:
filter:
- $zoom: { min: 20 }
+ all:
+ - $zoom: { min: 20 }
+ - function() { return global.text_visible_address; }
any:
- kind: address
- { label_position: true, addr_housenumber: true, name: false }
draw:
text-blend-order:
- interactive: global.interactive
+ #interactive: global.interactive
order: 7
- visible: *text_visible_address
text_source: addr_housenumber
font:
- fill: *text_fill_address
- family: *text_font_family
+ fill: global.text_fill_address
+ family: global.text_font_family
style: italic
size: 10px
- stroke: { color: *text_stroke_address, width: 4 }
+ stroke: { color: global.text_stroke_address, width: 4 }
boundaries:
data: { source: mapzen, layer: boundaries }
- admin_level: 2
draw:
lines:
- color: *country_boundary
+ color: global.country_boundary
width: [[1, 0.5px], [2, 1.0px], [4, 1.5px], [9, 2.5px], [14, 3.5px], [16, 4.5px], [17, 14m]]
water:
filter: { maritime_boundary: true }
draw:
text-blend-order:
priority: 2
- visible: *text_visible_admin
+ visible: global.text_visible_admin
text_source: global.ux_language_text_source_boundary_lines
text_wrap: 100
font:
- family: *text_font_family
+ family: global.text_font_family
size: 9px
fill: [0.00,0.00,0.00]
transform: uppercase
draw:
dashed:
order: function() { return (feature.sort_rank + 100); }
- color: *country_boundary
+ color: global.country_boundary
width: [[1,0.2px],[9,1.5px],[17,10m]]
disputed:
filter: { kind: [disputed, line_of_control] }
visible: false
dashed_big:
order: function() { return (feature.sort_rank + 100); }
- color: *country_boundary
+ color: global.country_boundary
width: [[1,0.5px],[9,2.5px],[17,14m]]
region:
- kind_detail: [3,4]
draw:
lines:
- color: *region_boundary
+ color: global.region_boundary
width: [[0, 0.5px], [2, 1.0px], [5, 1.25px], [6, 1.5px], [7, 1.75px], [9, 2.0px], [14, 4.0px], [16, 5.0px], [17, 10m]]
water:
filter: { maritime_boundary: true }
draw:
text-blend-order:
priority: 3
- visible: *text_visible_admin
+ visible: global.text_visible_admin
text_source: global.ux_language_text_source_boundary_lines
text_wrap: 100
#offset: [0px, -7px]
anchor: top
font:
- family: *text_font_family
+ family: global.text_font_family
size: 9px
fill: [0.35,0.35,0.35]
transform: uppercase
filter: { kind: city_wall }
draw:
lines:
- color: *city_wall
+ color: global.city_wall
width: [[12, 0.75px], [13, 1.0px], [14, 1.2px], [15, 2.0px], [16, 2.5px], [19, 6m]]
retaining_wall:
filter: { kind: retaining_wall }
draw:
lines:
- color: *retaining_wall
+ color: global.retaining_wall
width: [[14, 0.5px], [15, 1.0px], [16, 1.5px], [17, 2.0px], [19, 4m]]
snow_fence:
filter: { kind: snow_fence }
draw:
lines:
- color: *snow_fence
+ color: global.snow_fence
width: [[14, 0.5px], [15, 1.0px], [16, 1.5px], [17, 2.0px], [19, 1.5m]]
fence:
filter: { kind: fence }
filter: { kind: dam }
draw:
lines:
- color: *dam
+ color: global.dam
width: [[14, 0.5px], [15, 1.0px], [16, 1.5px], [17, 2.0px], [19, 1.5m]]
places:
visible: false
buffer: 3px
font:
- family: *text_font_family
- fill: *text_fill
+ family: global.text_font_family
+ fill: global.text_fill
# NOTE: This is a hack for localities because of an icon & text bug, see note below
text-blend-order:
text_source: global.ux_language_text_source
visible: false # labels are enabled by each layer below
buffer: 3px
font:
- family: *text_font_family
- fill: *text_fill
+ family: global.text_font_family
+ fill: global.text_fill
# END NOTE
country:
draw:
text-blend-order:
priority: 3
- visible: *text_visible_admin
+ visible: global.text_visible_admin
font:
- fill: *text_fill
+ fill: global.text_fill
weight: 600
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
country-z2-3:
filter:
$zoom: [2,3]
draw:
text-blend-order:
+ priority: 10
+ buffer: 10px
font:
- priority: 10
- buffer: 10px
weight: 200
size: 11px
early-ones-z2:
not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
draw:
text-blend-order:
- visible: *text_visible_admin
+ visible: global.text_visible_admin
text_source: global.ux_language_text_source_short
font:
fill: [0.70,0.70,0.70]
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
region-z5:
filter:
$zoom: [5]
not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
draw:
text-blend-order:
- visible: *text_visible_admin
+ visible: global.text_visible_admin
text_source: global.ux_language_text_source_short
font:
size: 18px
weight: 200
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
region-z6:
filter:
$zoom: [6]
not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
draw:
text-blend-order:
- visible: *text_visible_admin
+ visible: global.text_visible_admin
text_source: global.ux_language_text_source_short
font:
size: 21px
transform: uppercase
region-z7-z8:
- filter: { $zoom: [7,8] }
+ filter: { $zoom: [7] }
draw:
text-blend-order:
- visible: *text_visible_admin
+ visible: global.text_visible_admin
text_source: global.ux_language_text_source_short_proxy_name
font:
size: 30px
kind: locality
draw:
icons:
- visible: *icon_visible_populated_places
+ visible: global.icon_visible_populated_places
size: [[10,4px],[11,0px]]
sprite: townspot-xs-rev
buffer: 8px
priority: 30
text:
- visible: *text_visible_populated_places
+ visible: global.text_visible_populated_places
buffer: 3px
font:
size: [[5,9px],[8,10px],[12,11px]]
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
text-blend-order:
- visible: *text_visible_populated_places
+ visible: global.text_visible_populated_places
buffer: 10px
font:
size: [[5,9px],[8,10px],[12,11px]]
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
#
# NOTE: you'd think no-townspot would be the way to go, but icons with size 0px seems to have a bug to also hide the text :(
icons:
visible: false
text-blend-order:
- visible: *text_visible_populated_places
+ visible: global.text_visible_populated_places
_text_early:
filter: { $zoom: { max: 11 } }
text-blend-order:
priority: 6
font:
- size: [[2,11px],[6,17px],[8,19px],[12,21x],[13,0px]]
+ size: [[2,11px],[6,17px],[8,19px],[12,21px],[13,0px]]
capital:
filter: { country_capital: true, $zoom: { min: 5 } }
draw:
size: [[8,6px],[9,6px],[10,6px],[11,0px]]
sprite: townspot-m-rev
priority: 13
- collide: false #debug
text:
font:
size: [[6,10px],[8,14px],[10,15px],[12,16px],[13,0px]]
draw:
text-blend-order:
text_wrap: 10
- visible: *text_visible_neighbourhoods_e
+ visible: global.text_visible_neighbourhoods_e
font:
size: 9px
neighborhood-z12:
draw:
text-blend-order:
text_wrap: 10
- visible: *text_visible_neighbourhoods_e
+ visible: global.text_visible_neighbourhoods_e
font:
size: 10px
neighborhood-z13:
draw:
text-blend-order:
text_wrap: 10
- visible: *text_visible_neighbourhoods_e
+ visible: global.text_visible_neighbourhoods_e
font:
size: 12px
weight: 300
draw:
text-blend-order:
text_wrap: 12
- visible: *text_visible_neighbourhoods
+ visible: global.text_visible_neighbourhoods
font:
size: 16px
weight: 300
draw:
text-blend-order:
text_wrap: 12
- visible: *text_visible_neighbourhoods
+ visible: global.text_visible_neighbourhoods
font:
size: 21px
weight: 300
kind_tile_rank: { max: 8 }
draw:
text-blend-order:
- visible: *text_visible_neighbourhoods
+ visible: global.text_visible_neighbourhoods
font:
size: 24px
weight: 300
icons:
visible: false
text-blend-order:
- visible: *text_visible_exits
+ visible: global.text_visible_exits
interactive: global.interactive
text_source: ref
priority: 52
font:
- fill: *text_fill_exits
+ fill: global.text_fill_exits
size: [[12,9px],[15,12px],[17,14px]]
- stroke: { color: *text_stroke, width: [[12,2px],[14,3px],[15,3px]] }
+ stroke: { color: global.text_stroke, width: [[12,2px],[14,3px],[15,3px]] }
later:
filter: { $zoom: { min: 16 } }
draw:
icons:
visible: false
text-blend-order:
- visible: *text_visible_airport_gate
+ visible: global.text_visible_airport_gate
interactive: global.interactive
text_source: ref
font:
- fill: *text_fill_exits
+ fill: global.text_fill_exits
size: [[16,9px],[17,10px],[20,12px]]
- #stroke: { color: *highway1, width: [[12,2px],[14,3px],[15,3px]] }
+ #stroke: { color: global.highway1, width: [[12,2px],[14,3px],[15,3px]] }
later:
filter: { $zoom: { min: 19 } }
draw:
font:
weight: 600
- pois_and_landuse_labels:
- data: { source: mapzen, layer: [pois,landuse] }
- visible: *label_visible_poi_landuse
+ pois:
+ data: { source: mapzen, layer: pois }
+ #visible: global.label_visible_poi_landuse
filter:
all:
- - not: { kind: [building,address,apron,residential] }
+ - not: { kind: [building,address,farm,apron,residential,commercial,industrial] }
- $geometry: point
# White list a few kinds to "always" show per the tile zoom inclusion, else test feature's min_zoom
- - function() { if( feature.kind == 'attraction' || feature.kind == 'landmark' || feature.kind == 'playground' || feature.kind == 'toilets' ) { return true } else { return feature.min_zoom <= $zoom } }
- - any:
- - area: false
- all:
- - $zoom: { min: 12 }
- - area: false
- elevation: true
- all:
- - $zoom: { min: 11 }
- - area: true
- all:
- - kind: true
+ #- function() { return feature.min_zoom <= $zoom }
+ - function() { if( feature.kind == 'attraction' || feature.kind == 'landmark' || feature.kind == 'hunting' || feature.kind == 'dive_centre' || feature.kind == 'gas_canister' || feature.kind == 'hunting' || feature.kind == 'fishing_area' || feature.kind == 'playground' || feature.kind == 'toilets' ) { return true } else { return feature.min_zoom <= $zoom } }
draw:
icons:
+ visible: global.icon_visible_poi_landuse
size: [[13, 18px], [16, 18px], [18, 22px]]
+ sprite: function() { return feature.kind; }
+ sprite_default: generic
interactive: global.interactive
- visible: false
- priority: 65
+ priority: 65 #function() { return (feature.min_zoom && Math.floor(feature.min_zoom * 1000)) || 65; }
repeat_group: abc
+ buffer: 7px
text:
- visible: false # labels are enabled by each layer below
+ visible: global.text_visible_poi_landuse
text_source: global.ux_language_text_source
- move_into_tile: false # preserves text alignment w/icons in JS
- buffer: 7px
+ text_wrap: 18
+ max_lines: 3
font:
- family: *text_font_family
+ family: global.text_font_family
weight: 600
fill: [0.10,0.10,0.10]
- size: 10px
- stroke: { color: *text_stroke, width: 3 }
+ size: [[13,10px],[14,10px],[18,11px]]
+ stroke: { color: global.text_stroke, width: 3 }
text:
visible: false # labels are enabled by each layer below, and these are only for special cases like enclosures
move_into_tile: false # preserves text alignment w/icons in JS
interactive: global.interactive
text_source: global.ux_language_text_source
font:
- family: *text_font_family
+ family: global.text_font_family
weight: 600
fill: [0.10,0.10,0.10]
- size: 10px
- stroke: { color: *text_stroke, width: 3 }
- poi_labels-z14:
- filter: { $zoom: [14] }
- draw: { icons: { text: { font: { size: 10px } } } }
- poi_labels-z15:
- filter: { $zoom: [15,16,17] }
- draw: { icons: { text: { font: { size: 10px, stroke: { width: 2 } } } } }
+ size: [[13,10px],[14,10px],[18,11px]]
+ stroke: { color: global.text_stroke, width: 3 }
+ # improve legibility at high zooms
poi_labels-z18:
- filter: { $zoom: [18,19] }
- draw: { icons: { text: { font: { size: 11px, weight: 600, stroke: { width: 3 } } } } }
- poi_labels-z20-up:
- filter: { $zoom: { min: 20 } }
- draw: { icons: { text: { font: { size: 11px, weight: 600, stroke: { width: 3 } } } } }
+ filter: { $zoom: { min: 18 } }
+ draw:
+ icons:
+ text:
+ # some pois have really long names
+ max_lines: 5
- # since the blocks below are filtering by area and by name, we need a block here
- # that adjusts the color by kind first
text-colours:
greens:
- filter: { kind: [park, national_park, "park or protected land", conservation, protected_area, nature_reserve, forest, grass, beach, battlefield] }
+ filter:
+ kind: [park, national_park, conservation, protected_area, nature_reserve, forest, grass, beach, battlefield]
draw:
icons:
text:
font:
fill: [0.032,0.522,0.530]
- weight: 600
- stroke:
- color: *text_stroke_park
- no-name:
- filter: { name: false }
- sports-pitch:
- filter: { kind: [grass, pitch], $geometry: point, area: true, $zoom: { min: 16 } }
- draw:
- icons:
- sprite: function() { return feature.kind_detail; }
- visible: *icon_visible_poi_landuse_e
- priority: 49
- baseball:
- filter: { kind_detail: baseball }
- draw: { icons: { sprite: baseball } }
- basketball:
- filter: { kind_detail: basketball }
- draw: { icons: { sprite: basketball } }
- football:
- filter: { kind_detail: football }
- draw: { icons: { sprite: football } }
- hockey:
- filter: { kind_detail: hockey }
- draw: { icons: { sprite: hockey } }
- soccer:
- filter: { kind_detail: soccer }
- draw: { icons: { sprite: soccer } }
- tennis:
- filter: { kind_detail: tennis }
- draw: { icons: { sprite: tennis } }
- tree:
- filter: { kind: tree, $zoom: { min: 18 } }
- draw:
- icons:
- # TODO: put tree icons behind the buildings
- # See SF State University #20/37.72314/-122.47772
- sprite: tree
- color: [0.145,0.745,0.643]
- visible: *icon_visible_poi_landuse_e
- z18:
- filter: { $zoom: [18] }
- draw:
- icons:
- color: [0.459,0.765,0.722]
- sprite: tree-s
- z19:
- filter: { $zoom: [19] }
- draw:
- icons:
- sprite: tree
- gate:
- filter: { kind: gate, $zoom: { min: 19 } }
- draw:
- icons:
- # to circle black generic
- sprite: gate
- visible: *icon_visible_poi_landuse_e
- text:
- text_source: function() { return 'gate'; }
- toilets:
- filter: { kind: toilets, $zoom: { min: 16 } }
- draw: { icons: { sprite: toilets, visible: *icon_visible_poi_landuse_e } }
- toilets:
- filter: { kind: toilets, $zoom: { min: 16 } }
- draw: { icons: { sprite: toilets, visible: *icon_visible_poi_landuse_e } }
- playground:
- filter: { kind: playground, $zoom: { min: 18 } }
- draw: { icons: { sprite: playground, visible: *icon_visible_poi_landuse_e } }
- picnic_site:
- filter: { kind: [picnic_site, picnic_table], $zoom: { min: 15 } }
- draw: { icons: { sprite: picnic_site, visible: *icon_visible_poi_landuse_e } }
- information:
- filter: { kind: information, $zoom: { min: 18 } }
- draw: { icons: { sprite: information, visible: *icon_visible_poi_landuse_e } }
- drinking_water:
- filter: { kind: drinking_water, $zoom: { min: 18 } }
- draw: { icons: { sprite: drinking_water, visible: *icon_visible_poi_landuse_e } }
- traffic_signals:
- filter: { kind: traffic_signals, $zoom: { min: 18 } }
- draw: { icons: { sprite: traffic_signals, visible: *icon_visible_poi_landuse_e } }
- bicycle_parking:
- filter: { kind: [bicycle_parking], $zoom: { min: 19 } }
- draw: { icons: { sprite: bicycle_parking, visible: *icon_visible_poi_landuse_e } }
- parking:
- filter: { kind: parking, $zoom: { min: 17 } }
- draw:
- icons:
- sprite: parking
- visible: *icon_visible_poi_landuse_e
- power_tower:
- filter: { kind: [power_tower], $zoom: { max: 16 } }
- draw: { icons: { visible: false } }
- power_pole:
- filter: { kind: [power_pole], $zoom: { max: 17 } }
- draw: { icons: { visible: false } }
- playgrounds:
- filter:
- all:
- - kind: [playground, allotments, attraction, landmark]
- any:
- - { $zoom: [15], area: { min: 600 } }
- - { $zoom: [16], area: { min: 300 } }
- - { $zoom: { min: 17 } }
+ style: italic
+ size: [[13,11px],[14,11px],[18,12px]]
+
+ has-name:
+ filter: { name: true }
+ # match 1:1 correlations between data and sprite name
+ # draw:
+ # icons:
+ # visible: false
+ direct-match:
+ filter:
+ area: false
draw:
icons:
+ # sprite_source: kind
sprite: function() { return feature.kind; }
- pylon:
- filter: { kind: [pylon], $zoom: { max: 17 } }
- draw: { icons: { visible: false }}
- bbq:
- filter: { kind: [bbq], $zoom: { min: 17 } }
+ visible: global.icon_visible_poi_landuse
+ # add generic icon at high zoom, if direct match fails
+ generic-icons:
+ filter: { $zoom: { min: 18 }, area: false }
draw:
icons:
- sprite: bbq
- visible: *icon_visible_poi_landuse_e
- ranger_station:
- filter: { kind: [ranger_station], $zoom: { min: 15 } }
- draw: { icons: { sprite: ranger_station, visible: *icon_visible_poi_landuse_e } }
- trailhead:
- filter: { kind: [trailhead], $zoom: { min: 15 } }
- draw: { icons: { sprite: trailhead, visible: *icon_visible_poi_landuse_e } }
- firepit:
- filter: { kind: [firepit], $zoom: { min: 15 } }
- draw: { icons: { sprite: firepit, visible: *icon_visible_poi_landuse_e } }
- swimming_area:
- filter: { kind: [swimming_area], $zoom: { min: 15 } }
- draw: { icons: { sprite: swimming_area, visible: *icon_visible_poi_landuse_e } }
- fishing_area:
- filter: { kind: [fishing_area], $zoom: { min: 15 } }
- draw: { icons: { sprite: fishing_area, visible: *icon_visible_poi_landuse_e } }
- slipway:
- filter: { kind: [slipway], $zoom: { min: 15 } }
- draw: { icons: { sprite: slipway, visible: *icon_visible_poi_landuse_e } }
- hot_spring:
- filter: { kind: [hot_spring], $zoom: { min: 15 } }
- draw: { icons: { sprite: hot_spring, visible: *icon_visible_poi_landuse_e } }
- spring:
- filter: { kind: [spring], $zoom: { min: 15 } }
- draw: { icons: { sprite: spring, visible: *icon_visible_poi_landuse_e } }
- shower:
- filter: { kind: [shower], $zoom: { min: 15 } }
- draw: { icons: { sprite: shower, visible: *icon_visible_poi_landuse_e } }
- geyser:
- filter: { kind: [geyser], $zoom: { min: 15 } }
- draw: { icons: { sprite: geyser, visible: *icon_visible_poi_landuse_e } }
- observatory:
- filter: { kind: [observatory], $zoom: { min: 14 } }
- draw: { icons: { sprite: observatory, visible: *icon_visible_poi_landuse_e } }
- water_tower:
- filter: { kind: [water_tower], $zoom: { min: 15 } }
- draw: { icons: { sprite: water_tower, visible: *icon_visible_poi_landuse_e } }
- battlefield:
- filter: { kind: [battlefield] }
- draw: { icons: { sprite: battlefield, visible: *icon_visible_poi_landuse_e } }
- walking-or-bicycle_junction:
- filter: { kind: [bicycle_junction, walking_junction] }
+ priority: 47
+ sprite_default: generic
+ visible: global.icon_visible_poi_landuse
+
+ # add generic icon at high zoom
+ default-label-names:
+ filter: { $zoom: { min: 13 }, area: false }
draw:
icons:
- sprite: generic
- visible: *icon_visible_poi_landuse_e
text:
- visible: true
- text_source: ref
- outdoor-needing-icons:
- filter: { kind: [boat_rental, bicycle_repair_station, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, communications_tower, silo, putin, egress, hazard, put_in_egress, rapid, beacon, cross, water_well, saddle, dune, sinkhole, rock, stone, bicycle_junction, walking_junction, dam, boat_storage, windmill, horse, fire_lookout, fee_station, rest_area] }
+ visible: global.text_visible_poi_landuse
+ peak:
+ filter: { kind: [peak, volcano] }
draw:
icons:
+ visible: global.icon_visible_poi_landuse
priority: 43
- sprite: generic
- hide-early:
- filter: { kind: [recreation_track, dam] }
+ text: { visible: global.text_visible_poi_landuse }
+ low-priority-early-z11:
+ filter: { kind_tile_rank: { min: 3 }, $zoom: [11,12] }
draw:
icons:
- priority: 50
- early:
- filter: { $zoom: { max: 15 } }
- draw:
- icons:
- visible: false
- has-name:
- filter: { name: true }
- # match 1:1 correlations between data and sprite name
- direct-match:
- filter:
- all:
- - area: false
- draw:
- icons:
- # sprite_source: kind
- sprite: function() { return feature.kind; }
- visible: *icon_visible_poi_landuse
- # add generic icon at high zoom, if direct match fails
- generic-icons:
- filter: { $zoom: { min: 18 }, area: false }
- draw:
- icons:
- priority: 47
- sprite_default: generic
- visible: *icon_visible_poi_landuse
-
- # add generic icon at high zoom
- default-label-names:
- filter: { $zoom: { min: 13 }, area: false }
- draw:
- icons:
- text:
- visible: *text_visible_poi_landuse
- landuse-labels-green-areas-national-park:
- filter:
- all:
- - area: true
- - $geometry: point
- - kind: [national_park]
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [4], area: { min: 3000000000 } }
- - { $zoom: [5], area: { min: 3000000000 } }
- - { $zoom: [6], area: { min: 500000000 } }
- - { $zoom: [7,8,9], area: { min: 100000000 } }
- - { $zoom: [10], area: { min: 50000000 } }
- - { $zoom: [11], area: { min: 25000000 } }
- - { $zoom: [12], area: { min: 5000000 } }
- - { $zoom: [13], area: { min: 200000 } }
- - { $zoom: [14], area: { min: 50000 } }
- - { $zoom: { min: 15 } }
- national-park:
- # yosemite national park, joshua tree national park
- filter: function() { return feature.name && ((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
- visible: *label_visible_landuse_green
+ visible: false
+ text: { visible: false }
+ low-priority-early-z13:
+ filter: { kind_tile_rank: { min: 4 }, $zoom: [13] }
draw:
icons:
- visible: *icon_visible_landuse_green
- sprite: park
- priority: 41
- text:
- visible: *text_visible_landuse_green
- text_source: global.ux_language_text_source
- font:
- style: italic
- stroke: { color: *text_stroke_park, width: 4 }
- natl-park-labels-z4-z5:
- filter: { $zoom: [4,5] }
- draw:
- icons:
- visible: false
- text: { font: { size: 9px, stroke: { width: 2px } } }
- natl-park-labels-z6:
- filter: { $zoom: [6] }
- draw:
- icons:
- text: { font: { size: 9px, stroke: { width: 2px } } }
- natl-park-labels-z7:
- filter: { $zoom: [7] }
- draw:
- icons:
- text: { font: { size: 10px, stroke: { width: 2px } } }
- natl-park-labels-z8:
- filter: { $zoom: [8,9] }
- draw:
- icons:
- text: { font: { size: 11px, stroke: { width: 2px } } }
- natl-park-labels-z10:
- filter: { $zoom: {min: 10, max: 14 } }
- draw:
- icons:
- text: { font: { size: 12px } }
- poi_labels-z14:
- filter: { $zoom: [14] }
- draw: { icons: { text: { font: { size: 11px } } } }
- poi_labels-z15:
- filter: { $zoom: [15,16,17] }
- draw: { icons: { text: { font: { size: 11px } } } }
- poi_labels-z18:
- filter: { $zoom: [18,19] }
- draw: { icons: { text: { font: { size: 11px } } } }
- poi_labels-z20-up:
- filter: { $zoom: { min: 20 } }
- draw: { icons: { text: { font: { size: 11px } } } }
- landuse-labels-green-areas-not-national-park:
- filter:
- all:
- - area: true
- - $geometry: point
- - kind: [park, national_park, "park or protected land", conservation, protected_area, nature_reserve, forest, grass]
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [5], area: { min: 10000000000 } }
- - { $zoom: [6,7], area: { min: 5000000000 } }
- - { $zoom: [8], area: { min: 1000000000 } }
- - { $zoom: [9], area: { min: 100000000 } }
- - { $zoom: [10], area: { min: 50000000 } }
- - { $zoom: [11], area: { min: 10000000 } }
- - { $zoom: [12], area: { min: 5000000 } }
- - { $zoom: [13], area: { min: 200000 } }
- - { $zoom: [14], area: { min: 50000 } }
- - { $zoom: [15], area: { min: 10000 } }
- - { $zoom: [16], area: { min: 1000 } }
- - { $zoom: { min: 17 } }
- not-national-park:
- filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
+ visible: false
+ text: { visible: false }
+ peak-labels-later:
+ filter: { kind: [peak, volcano], $zoom: { min: 14 } }
draw:
icons:
- visible: *icon_visible_landuse_green
- sprite: park
- priority: 41
text:
- visible: *text_visible_landuse_green
- font:
- #fill: [0.032,0.522,0.530]
- # fill: [0.093,0.473,0.408]
- size: 11px
- style: italic
- stroke: { color: *text_stroke_park, width: 3 }
- green-areas-z6:
- # mojave national preserve
- filter: { $zoom: [6] }
- draw:
- icons:
- visible: false
- text: { font: { size: 10px, stroke: { width: 2px } } }
- green-areas-z7:
- filter: { $zoom: [7] }
- draw:
- icons:
- visible: false
- text: { font: { size: 10px, stroke: { width: 2px } } }
- green-areas-z17-up:
- filter: { $zoom: { min: 17 } }
- draw:
- icons:
- text:
- font:
- size: 11px
- stroke: { color: *text_stroke, width: 4 }
-
- wilderness-areas:
- filter: function() { return feature.name && (feature.name.indexOf("Wilderness") > -1 || feature.name.indexOf("BLM") > -1) }
- draw:
- icons:
- sprite: forest
- early:
- filter: { $zoom: { max: 8 } }
- draw:
- icons:
- visible: false
- text: { visible: false }
- early-not-national-park:
- filter: { not: { kind: [national_park] }, $zoom: { max: 6 } }
- draw:
- icons:
- visible: false
- text: { visible: false }
- not-national-park:
- filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
- # draw:
- # icons:
- # sprite: park
- early:
- filter: { $zoom: { max: 8 } }
- draw:
- icons:
- visible: false
- text: { visible: false }
- forest:
- filter: function() { return ( (feature.name && feature.name.indexOf("Forest") > -1) || (feature.protect_class >=6 && feature.name.indexOf("Park") < 0) ) }
- draw:
- icons:
- sprite: forest
- early:
- filter: { $zoom: { max: 8 } }
- draw:
- icons:
- visible: false
- text: { visible: false }
- hide-till-later:
- filter: { kind: [grass], $zoom: { max: 16 } }
- draw:
- icons:
- visible: false
- text: { visible: false }
- only-text-later:
- filter: { kind: [grass], $zoom: { min: 16 } }
- draw:
- icons:
- visible: false
- text: { font: { style: italic } }
- battlefield:
- filter:
- all:
- - area: true
- - $geometry: point
- - kind: [battlefield]
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [4], area: { min: 3000000000 } }
- - { $zoom: [5], area: { min: 3000000000 } }
- - { $zoom: [6], area: { min: 500000000 } }
- - { $zoom: [7,8,9], area: { min: 10000000 } }
- - { $zoom: [10], area: { min: 5000000 } }
- - { $zoom: [11], area: { min: 5000000 } }
- - { $zoom: [12], area: { min: 5000000 } }
- - { $zoom: [13], area: { min: 200000 } }
- - { $zoom: [14], area: { min: 50000 } }
- - { $zoom: { min: 15 } }
- draw:
- icons:
- visible: *icon_visible_landuse_green
- sprite: battlefield
- priority: 41
- text:
- visible: *text_visible_landuse_green
- font:
- #fill: [0.058,0.605,0.615]
- # fill: [0.093,0.473,0.408]
- style: italic
- stroke: { color: *text_stroke_park, width: 4 }
- beach:
- filter:
- all:
- - area: true
- - $geometry: point
- - kind: [beach]
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [10], area: { min: 300000 } }
- - { $zoom: [11], area: { min: 100000 } }
- - { $zoom: [12], area: { min: 50000 } }
- - { $zoom: [13], area: { min: 50000 } }
- - { $zoom: [14], area: { min: 20000 } }
- - { $zoom: [15], area: { min: 10000 } }
- - { $zoom: [16], area: { min: 1000 } }
- - { $zoom: { min: 17 } }
- draw:
- icons:
- visible: *icon_visible_landuse_green
- sprite: beach
- text:
- visible: *text_visible_landuse_green
- airport:
- filter:
- all:
- - kind: [airport, aerodrome]
- - area: true
- - $geometry: point
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [9], area: { min: 10000000 } }
- - { $zoom: [10], area: { min: 10000000 } }
- - { $zoom: [11], area: { min: 5000000 } }
- - { $zoom: [12], area: { min: 5000000 } }
- - { $zoom: [13], area: { min: 500000 } }
- - { $zoom: [14], area: { min: 20000 } }
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [15], area: { min: 10000 } }
- - { $zoom: [16], area: { min: 5000 } }
- - { $zoom: [17], area: { min: 2000 } }
- - { $zoom: { min: 18 } }
- draw:
- icons:
- sprite: airport
- visible: *icon_visible_landuse_green
- priority: 42
- text:
- visible: *text_visible_landuse_green
- text_source: global.ux_language_text_source_iata
- font:
- #fill: [0.10,0.10,0.10]
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
- early:
- filter: { $zoom: [9,10,11] }
- # todo: huh?
- draw: { icons: { text: { text_source: iata, font: { size: 11px } } } }
- early2:
- filter: { $zoom: { min: 12, max: 14 } }
- draw: { icons: { text: { font: { size: 11px } } } }
- university:
- filter:
- all:
- - kind: [university, college]
- - area: true
- - $geometry: point
- - not: { $layer: buildings }
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [9], area: { min: 10000000 } }
- - { $zoom: [10], area: { min: 5000000 } }
- - { $zoom: [11], area: { min: 2000000 } }
- - { $zoom: [12], area: { min: 500000 } }
- - { $zoom: [13], area: { min: 100000 } }
- - { $zoom: [14], area: { min: 100000 } }
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [15], area: { min: 40000 } }
- - { $zoom: [16], area: { min: 5000 } }
- - { $zoom: [17], area: { min: 2000 } }
- - { $zoom: { min: 18 } }
- visible: *label_visible_landuse_green
+ text_source: function() { if( feature.name && feature.elevation ) { return feature.name + "\n" + feature.elevation + "m"; } else { if( feature.name ) { return feature.name; } else { return feature.elevation; } } }
+ waterfall-early:
+ filter: { kind: [waterfall], $zoom: { max: 14 } }
draw:
icons:
- sprite: college
- visible: *icon_visible_landuse_green
- priority: 41
- text:
- visible: *text_visible_landuse_green
- font:
- #fill: [0.10,0.10,0.10]
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
- # early:
- # filter: { $zoom: { max: 12 } }
- # draw: { icons: { text: { visible: false } } }
- early2:
- filter: { $zoom: { max: 14 } }
- draw: { icons: { text: { font: { size: 10px } } } }
- school:
- filter:
- all:
- - kind: [school, kindergarten]
- - area: true
- - $geometry: point
- - not: { $layer: buildings }
- any:
- # show labels for smaller landuse areas at higher zooms
- #- { $zoom: [13], area: { min: 100000 } }
- #- { $zoom: [14], area: { min: 50000 } }
- # show labels for smaller landuse areas at higher zooms
- #- { $zoom: [15], area: { min: 10000 } }
- - { $zoom: [16], area: { min: 5000 } }
- - { $zoom: [17], area: { min: 2000 } }
- - { $zoom: { min: 18 } }
+ visible: global.icon_visible_poi_landuse
+ text: { visible: global.text_visible_poi_landuse }
+ low-priority-early-z11:
+ filter: { kind_tile_rank: { min: 3 }, $zoom: [11,12] }
+ draw:
+ icons:
+ visible: false
+ text: { visible: false }
+ low-priority-early-z13:
+ filter: { kind_tile_rank: { min: 4 }, $zoom: [13] }
+ draw:
+ icons:
+ visible: false
+ text: { visible: false }
+ waterfall-labels:
+ filter: { kind: [waterfall], $zoom: { min: 14 } }
draw:
icons:
- sprite: school
- visible: *icon_visible_landuse_green
- priority: 41
text:
- visible: *text_visible_landuse_green
- font:
- #fill: [0.10,0.10,0.10]
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
- early:
- filter: { $zoom: { max: 14 } }
- draw: { icons: { text: { font: { size: 11px } } } }
- winter_sports:
+ text_source: function() { if( feature.name && feature.height ) { return feature.name + "\n" + feature.height + "m"; } else { if( feature.name ) { return feature.name; } else { return feature.height; } } }
+ playgrounds_allotments_attraction_landmark_supermarket:
filter:
all:
- - kind: winter_sports
+ - kind: [playground, allotments, attraction, landmark, supermarket]
- area: true
- $geometry: point
any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [10], area: { min: 5000000 } }
- - { $zoom: [11], area: { min: 2000000 } }
- - { $zoom: [12], area: { min: 500000 } }
- - { $zoom: [13], area: { min: 100000 } }
- - { $zoom: [14], area: { min: 100000 } }
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [15], area: { min: 40000 } }
- - { $zoom: [16], area: { min: 5000 } }
- - { $zoom: [17], area: { min: 2000 } }
- - { $zoom: { min: 18 } }
+ - { $zoom: [15], area: { min: 600 } }
+ - { $zoom: [16], area: { min: 300 } }
+ - { $zoom: { min: 17 }, area: true }
draw:
icons:
- sprite: ski
- visible: *icon_visible_landuse_green
+ visible: global.icon_visible_poi_landuse
priority: 41
text:
- visible: *text_visible_landuse_green
- font:
- #fill: [0.10,0.10,0.10]
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
-# early:
-# filter: { $zoom: { max: 14 } }
-# draw: { icons: { text: { font: { size: 10px } } } }
+ visible: global.text_visible_poi_landuse
+ # font:
+ # size: 10px
+ # stroke: { color: global.text_stroke, width: 4 }
tourism-related:
filter:
all:
icons:
sprite: function() { return feature.kind; }
sprite_default: generic
- visible: *icon_visible_poi_landuse
+ visible: global.icon_visible_poi_landuse
priority: 43
text:
- visible: *text_visible_poi_landuse
- font:
- #fill: [0.10,0.10,0.10]
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
- enclosure:
- filter: { kind: [enclosure, animal] }
- draw:
- icons:
- visible: false
- sprite_default: enclosure
- text:
- text_wrap: 10
- font:
- style: italic
- weight: 400
- #early-sizing:
-# filter: { $zoom: { max: 14 } }
-# draw: { icons: { text: { font: { size: 10px } } } }
- playgrounds_allotments_attraction_landmark_supermarket:
+ visible: global.text_visible_poi_landuse
+ # font:
+ # size: 10px
+ # stroke: { color: global.text_stroke, width: 4 }
+ outdoor-needing-icons:
+ filter: { kind: [bicycle_repair_station, cycle_barrier, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, communications_tower, putin, egress, hazard, put_in_egress, rapid, beacon, cross, mineshaft, adit, water_well, saddle, dune, sinkhole, rock, stone, bicycle_junction, walking_junction, dam, boat_storage, windmill, fishing, recreation_track, horse, fire_lookout, fee_station, rest_area] }
+ draw:
+ icons:
+ order: 41
+ sprite: generic
+ outdoor-has-icons:
+ filter: { kind: [outdoor, lighthouse, saddle, picnic_area, picnic_table, camp_site, ski, mine, zoo, museum, gas, gas_canister, slipway, mineshaft, adit, recreation_track, playground, allotments, attraction, landmark] }
+ draw:
+ icons:
+ order: 41
+ not-outdoor-not-landuse:
+ filter: { area: false, not: { kind: [park, national_park, outdoor, bicycle_repair_station, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, bicycle_junction, walking_junction, dam, boat_storage, windmill, playground, allotments, attraction, landmark] } }
+ draw:
+ icons:
+ order: 45
+
+ # source icon sprite from something other than kind
+ sports-pitch:
+ filter: { kind: [grass, pitch] }
+ draw:
+ icons:
+ sprite: function() { return feature.kind_detail; }
+ # needs a better recreation icon, so just use generic (default) for now
+ #sprite_default: sports
+ #visible: global.icon_visible_poi_landuse_e
+ priority: 69
+ place_of_worship:
+ filter:
+ kind: [place_of_worship, wayside_chapel]
+ draw:
+ icons:
+ sprite: function() { return feature.religion; }
+ sprite_default: place_of_worship
+ # TODO: some or all of this may be unnecessary for the sprite, but is necessary for the early filter
+ building-icon:
+ filter:
+ kind: [apartments, auditorium, building, hangar, manor, recreation_center, retirement_home, terminal]
+ draw:
+ icons:
+ sprite: building
+ early:
+ filter:
+ any:
+ # show labels for smaller landuse areas at higher zooms
+ - { $zoom: [14], area: { max: 200000 } }
+ - { $zoom: [15], area: { max: 20000 } }
+ - { $zoom: [16], area: { max: 5000 } }
+ - { $zoom: [17], area: { max: 1000 } }
+ draw:
+ icons:
+ visible: false
+ #end different icon sprites
+
+ #most POI icons without name should be hidden, except these
+ no-name:
+ filter: { name: false }
+ draw:
+ icons:
+ visible: false
+ # eg park polygons in SF that have area but no name, sigh
+ no-name-no-area:
+ filter:
+ kind: true
+ name: false
+ draw:
+ icons:
+ visible: false
+ # we agree with server value, always show
+ always-show:
+ filter:
+ kind: [bbq,bicycle_junction,firepit,fishing_area,geyser,hot_spring,observatory,picnic_site,picnic_table,playground,power_pole,power_tower,pylon,shower,slipway,swimming_area,toilets,trailhead,walking_junction,water_tower]
+ draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
+
+ # probaly difference with server, selectively show by zoom
+ z15-always-show-but-server-show-later-z15-server-14:
+ filter: { kind: [ranger_station, spring], $zoom: { min: 15 } } # server says min_zoom: 14
+ draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
+ z17:
+ filter:
+ $zoom: { min: 17 }
+ kind: [parking]
+ draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
+ z18:
+ # for different styles, different sets
+ # since [picnic_site] doesn't have bubble-wrap icon, it's omitted here
+ filter:
+ $zoom: { min: 18 } # same as BW, server at 17 now (information is 16)
+ kind: [drinking_water, information, playground, toilets, traffic_signals, picnic_site]
+ draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
+ z19:
+ filter:
+ $zoom: { min: 19 } # same as BW, server at 17 now
+ kind: [bicycle_parking, gate]
+ draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
+
+
+ # area based show / hide
+ playgrounds:
filter:
all:
- - kind: [playground, allotments, attraction, landmark, supermarket]
- - area: true
- - $geometry: point
+ - kind: [playground, allotments, attraction, landmark]
any:
- { $zoom: [15], area: { min: 600 } }
- { $zoom: [16], area: { min: 300 } }
- - { $zoom: { min: 17 } }
+ - { $zoom: { min: 17, area: true } }
+ draw:
+ icons:
+ visible: global.icon_visible_poi_landuse_e
+
+ # special icon and text stuff
+ sports-pitch:
+ filter:
+ $zoom: { min: 17 }
+ kind: [grass, pitch]
+ kind_detail: [baseball, basketball, football, hockey, soccer, tennis]
+ draw:
+ icons:
+ visible: global.icon_visible_poi_landuse_e
+ priority: 69
+ tree:
+ filter: { kind: tree, $zoom: { min: 18 } }
draw:
icons:
- visible: *icon_visible_landuse_green
- priority: 41
- text:
- visible: *text_visible_landuse_green
- font:
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
- attraction:
- filter: { kind: [attraction] }
- draw:
- icons:
- sprite: attraction
- landmark:
- filter: { kind: [landmark] }
+ # TODO: put tree icons behind the buildings
+ # See SF State University #20/37.72314/-122.47772
+ color: [0.145,0.745,0.643]
+ visible: global.icon_visible_poi_landuse_e
+ z18:
+ filter: { $zoom: [18] }
draw:
icons:
- sprite: landmark
- glacier:
- filter:
- all:
- - kind: glacier
- - area: true
- - $geometry: point
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [10], area: { min: 20000000 } }
- - { $zoom: [11], area: { min: 5000000 } }
- - { $zoom: [12], area: { min: 2000000 } }
- - { $zoom: [13], area: { min: 500000 } }
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: { min: 14 } }
+ color: [0.459,0.765,0.722]
+ sprite: tree-s
+ gate:
+ filter: { kind: gate, $zoom: { min: 19 } }
draw:
icons:
- visible: false
- text:
- visible: true
- priority: 44
- text_wrap: 10
- font:
- weight: 400
- style: italic
- fill: '#4ba3c5'
- landuse-labels-not-any-above:
+ text:
+ text_source: function() { return 'gate'; }
+ walking-or-bicycle_junction:
+ filter: { kind: [bicycle_junction, walking_junction] }
+ draw:
+ icons:
+ text:
+ text_source: ref
+
+ z-hide-z15:
filter:
- all:
- - $zoom: { min: 6 }
- - area: true
- - $geometry: point
- - not: { kind: [park, national_park, "park or protected land", battlefield, conservation, protected_area, nature_reserve, forest, grass, beach, airport, aerodrome, university, college, school, kindergarten, winter_sports, zoo, theme_park, resort, aquarium, winery, maze, stadium, playground, allotments, attraction, landmark, glacier] }
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [5,6,7], area: { min: 5000000000 } }
- - { $zoom: [8], area: { min: 1600000000 } }
- - { $zoom: [9], area: { min: 400000000 } }
- - { $zoom: [10], area: { min: 100000000 } }
- - { $zoom: [11], area: { min: 25000000 } }
- - { $zoom: [12], area: { min: 5000000 } }
- - { $zoom: [13], area: { min: 1000000 } }
- - { $zoom: [14], area: { min: 50000 } }
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [15], area: { min: 5000 } }
- - { $zoom: [16], area: { min: 2000 } }
- - { $zoom: { min: 17 } }
+ $zoom: { max: 15 }
+ kind: [rest_area]
+ draw: { icons: { visible: false } }
+
+ outdoor-special-priority:
+ filter: { kind: [beacon,bicycle_junction,bicycle_repair_station,boat_storage,communications_tower,cross,dam,dune,egress,fee_station,fire_lookout,hazard,horse,life_ring,lifeguard_tower,petroleum_well,power_pole,power_tower,put_in_egress,putin,rapid,rest_area,rock,saddle,silo,sinkhole,stone,walking_junction,waste_disposal,water_point,water_well,watering_place,windmill] }
draw:
icons:
- sprite: function() { return feature.kind; }
- sprite_default: generic
- visible: *icon_visible_poi_landuse
priority: 43
- text:
- visible: *text_visible_poi_landuse
- font:
- weight: 600
- size: 10px
- stroke: { color: *text_stroke, width: 3 }
- landuse-z18:
- filter: { $zoom: { min: 18 } }
- draw:
- icons:
- text:
- font:
- size: 11px
- stroke: { color: *text_stroke, width: 4 }
- # building-like:
- # filter: { kind: [commercial,residential,warehouse,public,dormitory], osm_relation: false }
- # draw:
- # icons:
- # sprite: building
- residential-relations-paris-wtf-early:
- filter: { kind: [residential], osm_relation: true, $zoom: { max: 13 } }
- draw:
- icons:
- visible: false
- text: { visible: false }
- residential-relations-paris-wtf:
- filter: { kind: [residential], osm_relation: true, $zoom: { min: 13 } }
- draw:
- icons:
- visible: false
- text:
- visible: true
- text_source: short_name
- hide-till-later:
- filter: { kind: [pedestrian,common,railway,ship,houseboat,common,grass,wetland,pitch], $zoom: { max: 17 } }
- draw:
- icons:
- visible: false
- text: { visible: false }
- only-text-later:
- filter: { kind: [pedestrian,common,railway,ship,houseboat,common,grass,wetland,pitch], $zoom: { min: 17 } }
+ visible: global.icon_visible_poi_landuse_e
+ hide-early:
+ filter: { kind: [dam,recreation_track] }
draw:
icons:
- visible: false
- text: { font: { style: italic } }
- # burial_vault-early:
- # filter: { kind: [burial_vault], $zoom: { max: 19 } }
- # draw:
- # icons:
- # visible: false
- # text: { visible: false }
- garden-area-early:
- filter:
- all:
- - kind: [garden, allotments]
- any:
- # limit show smaller landuse areas to higher zooms
- - { $zoom: [12], area: { max: 500000 } }
- - { $zoom: [13], area: { max: 100000 } }
- - { $zoom: [14], area: { max: 10000 } }
- - { $zoom: [15], area: { max: 5000 } }
- draw:
- icons:
- visible: false
- university-poi:
- filter: { kind: [university, college], area: false, $zoom: { max: 16 } }
+ priority: 50
+ early:
+ filter: { $zoom: { max: 15 } }
+ draw:
+ icons:
+ visible: false
+
+
+ # NOTE: all natural_* should only be in landuse layer
+ suppress-icon-always:
+ filter:
+ kind: [natural_forest, natural_park, natural_wood]
+ draw:
+ icons:
+ size: 0px
+ priority: 100
+ text:
+ font:
+ fill: '#666'
+ family: global.text_font_family
+ style: italic
+ size: 11px
+ # This should work, but doesn't. hmmm
+ no-area:
+ filter:
+ area: false
+ $zoom: { max: 16 }
draw:
icons:
visible: false
- text: { visible: false }
- office-early:
+
+ # server problem: this should probably only have landuse layer label placements (not appear in pois layer)
+ suppress-icon-z17:
+ filter:
+ $zoom: { min: 17 }
+ kind: [common, grass, houseboat, pedestrian, railway, ship, wetland]
+ draw:
+ icons:
+ size: 0px
+ #visible: false
+ text: { font: { style: italic } }
+
+ # the server should be setting better values here
+ z-server-friend:
+ hide-until-z12-any:
filter:
- any:
- - { kind: [insurance, office, company], $zoom: [15], area: { max: 10000 } }
- - { kind: [insurance, office, company], $zoom: [16], area: { max: 5000 } }
+ kind: [landmark, museum, prison]
+ $zoom: { max: 12 }
draw:
icons:
visible: false
- text: { visible: false }
- bank-early:
- filter: { kind: [bank], $zoom: { max: 17 } }
+ hide-until-z14-any:
+ filter:
+ kind: [natural_forest, natural_park, natural_wood]
+ $zoom: { max: 14 }
draw:
icons:
visible: false
- text: { visible: false }
- garden-no-area-early2:
- filter: { kind: [garden, allotments], $zoom: { max: 16 }, area: false }
+ hide-until-z15-any:
+ filter:
+ kind: [motorway_junction]
+ $zoom: { max: 15 }
draw:
icons:
visible: false
- garden-no-area-early:
- filter: { kind: [garden, allotments], $zoom: [16], area: false }
+ hide-until-z15-no-area:
+ filter:
+ area: false
+ $zoom: { max: 15 }
+ kind: [park]
draw:
icons:
- priority: 45
- size: 14px
- text: { font: { size: 10px, style: italic } }
- garden-no-area-later:
- filter: { kind: [garden, allotments], $zoom: { min: 17 }, area: false }
+ visible: false
+ hide-until-z15-with-area:
+ filter:
+ area: true
+ $zoom: { max: 15 }
+ kind: [nursing_home]
draw:
icons:
- priority: 45
- size: 16px
- text: { font: { size: 11px, style: italic } }
- post-office-early:
- filter: { kind: [post_office], $zoom: { max: 14 } }
+ visible: false
+ hide-until-z16-any:
+ filter:
+ kind: [fire_station, grass, tram_stop, post_office]
+ $zoom: { max: 16 }
draw:
icons:
visible: false
- text: { visible: false }
- pylon-early:
- filter: { kind: [pylon], name: true, $zoom: { max: 18 } }
- draw: { icons: { text: { visible: false } } }
- school-early:
- filter: { kind: [school, kindergarten], $zoom: { max: 16 } }
+ hide-until-z16-no-area:
+ filter:
+ area: false
+ kind: [allotments, college, garden, university]
+ $zoom: { max: 16 }
draw:
icons:
visible: false
- text: { visible: false }
- atm-early:
- filter: { kind: [atm], $zoom: { max: 18 } }
+ # no POIs for commercial, residential
+ hide-until-z17-any:
+ filter:
+ $zoom: { max: 17 }
+ kind: [bank, bus_stop, car_sharing, wood, platform, cafe, restaurant, fast_food, bar, place_of_worship, police]
draw:
icons:
visible: false
- text: { visible: false }
- bicycle-parking-early:
- filter: { kind: [bicycle_parking], $zoom: { max: 19 } }
+ hide-until-z17-with-area:
+ filter:
+ area: true
+ $zoom: { max: 17 }
+ kind: [common, grass, houseboat, pedestrian, pitch, railway, ship, wetland]
draw:
icons:
visible: false
- text: { visible: false }
- true-early:
- filter: { kind: [true], $zoom: { max: 18 } }
+ hide-until-z17-no-area:
+ filter:
+ area: false
+ $zoom: { max: 17 }
+ # note: atm and drinking_water appear hear and in area versions
+ kind: [accountant, administrative, advertising_agency, animal, architect, association, atm, bakery, bed_and_breakfast, bicycle, bicycle_parking, bicycle_rental_station, books, butcher, car, car_repair, chalet, clothes, company, computer, consulting, convenience, doityourself, drinking_water, dry_cleaning, educational_institution, emergency_phone, employment_agency, estate_agent, fashion, financial, florist, foundation, gift, government, greengrocer, guest_house, hairdresser, hostel, hotel, insurance, it, jewelry, lawyer, mast, memorial, mobile_phone, motel, newspaper, ngo, notary, optician, parking, pet, physician, political_party, post_box, religion, research, subway_entrance, tax_advisor, telecommunication, telephone, theatre, therapist, toilets, traffic_signals, travel_agent, water_tower]
draw:
icons:
visible: false
- text: { visible: false }
- peak-early:
- filter: { kind: [peak, volcano] }
+ hide-until-z18-any:
+ filter:
+ kind: [atm, bus_stop, drinking_water]
+ $zoom: { max: 18 }
draw:
icons:
- visible: *icon_visible_landuse_green
- priority: 43
- text: { visible: *text_visible_landuse_green }
- low-priority-early-z11:
- filter: { kind_tile_rank: { min: 3 }, $zoom: [11,12] }
- draw:
- icons:
- visible: false
- text: { visible: false }
- low-priority-early-z13:
- filter: { kind_tile_rank: { min: 4 }, $zoom: [13] }
- draw:
- icons:
- visible: false
- text: { visible: false }
- peak-labels-later:
- filter: { kind: [peak, volcano], $zoom: { min: 14 } }
- draw:
- icons:
- text:
- text_source: function() { if( feature.name && feature.elevation ) { return feature.name + "\n" + feature.elevation + "m"; } else { if( feature.name ) { return feature.name; } else { return feature.elevation; } } }
- waterfall-early:
- filter: { kind: [waterfall], $zoom: { max: 14 } }
+ visible: false
+ hide-until-z18-no-area:
+ filter:
+ $zoom: { max: 18 }
+ area: false
+ kind: [bench, parking, waste_basket]
draw:
icons:
- visible: *icon_visible_landuse_green
- text: { visible: *text_visible_landuse_green }
- low-priority-early-z11:
- filter: { kind_tile_rank: { min: 3 }, $zoom: [11,12] }
- draw:
- icons:
- visible: false
- text: { visible: false }
- low-priority-early-z13:
- filter: { kind_tile_rank: { min: 4 }, $zoom: [13] }
- draw:
- icons:
- visible: false
- text: { visible: false }
- waterfall-labels:
- filter: { kind: [waterfall], $zoom: { min: 14 } }
+ visible: false
+ hide-until-z19-any:
+ filter:
+ $zoom: { max: 19 }
+ kind: [bicycle_parking, burial_vault, car_sharing]
draw:
icons:
- text:
- text_source: function() { if( feature.name && feature.height ) { return feature.name + "\n" + feature.height; } else { if( feature.name ) { return feature.name; } else { return feature.height; } } }
- drinking-water-early:
- filter: { kind: [drinking_water], $zoom: { max: 18 } }
+ visible: false
+
+ # hide based on kind and area filters
+ military-early:
+ filter:
+ kind: [military]
+ any:
+ # show labels for smaller landuse areas at higher zooms
+ - { $zoom: [8], area: { max: 50000000 } }
draw:
icons:
visible: false
- text: { visible: false }
- memorial-early:
- filter: { kind: [memorial], $zoom: { max: 13 } }
+ university-early:
+ filter:
+ kind: [university, college]
+ any:
+ # show labels for smaller landuse areas at higher zooms
+ - { $zoom: [11], area: { max: 2000000 } }
+ - { $zoom: [12], area: { max: 500000 } }
draw:
icons:
visible: false
- text: { visible: false }
- animal-points-early:
- filter: { kind: [animal], area: false, $zoom: { max: 18 } }
+ school-early:
+ filter:
+ kind: [school, kindergarten]
+ any:
+ # show labels for smaller landuse areas at higher zooms
+ - { $zoom: [13], area: { max: 100000 } }
+ - { $zoom: [14], area: { max: 50000 } }
+ - { $zoom: [15], area: { max: 10000 } }
+ - { $zoom: [16], area: { max: 5000 } }
+ - { $zoom: [17], area: { max: 2000 } }
draw:
icons:
visible: false
- text: { visible: false }
-# animal-areas-early:
-# filter: { kind: [animal], area: { min: 500 }, $zoom: { max: 18 } }
-# draw:
-# icons:
-# visible: false
-# text: { visible: false }
- parking-labels-early:
+ garden-area-early:
filter:
- kind: [parking]
- $zoom: { max: 18 }
+ kind: [garden, allotments]
+ any:
+ # limit show smaller landuse areas to higher zooms
+ - { $zoom: [12], area: { max: 500000 } }
+ - { $zoom: [13], area: { max: 100000 } }
+ - { $zoom: [14], area: { max: 10000 } }
+ - { $zoom: [15], area: { max: 5000 } }
draw:
icons:
visible: false
- text:
- visible: false
- parking-labels:
+ cemetery-early:
filter:
- kind: [parking]
- $zoom: { min: 18 }
+ kind: [cemetery]
+ # limit show smaller landuse areas to higher zooms
+ any:
+ - { $zoom: [12], area: { max: 3000000 } }
draw:
icons:
- text:
- visible: *text_visible_poi_landuse
- font:
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
- landuse-funky:
- filter: { kind: [commercial, residential, wood], $zoom: { max: 17 } }
+ visible: false
+ golf_course-early:
+ filter:
+ kind: golf_course
+ any:
+ - { $zoom: [12], area: { max: 2500000 } }
draw:
icons:
visible: false
- text:
- visible: false
- car-sharing:
- filter: { kind: car_sharing }
- icons-early:
- filter: { $zoom: { max: 17 } }
- draw:
- icons:
- visible: false
- text-labels-early:
- filter: { $zoom: { max: 19 } }
- draw:
- icons:
- text:
- visible: false
- bicycle_rental_station-early:
- filter: { kind: bicycle_rental_station }
- icons-early:
- filter: { $zoom: { max: 17 } }
- draw:
- icons:
- size: [[16, 14px], [17, 16px], [18, 20px]]
- early-names:
- filter: { $zoom: { max: 17 } }
- draw:
- icons:
- text:
- visible: false
- tower:
- filter: { kind: [tower], label_placement: true }
+ office-early:
+ filter:
+ - { kind: [insurance, office, company], $zoom: [15], area: { max: 10000 } }
+ - { kind: [insurance, office, company], $zoom: [16], area: { max: 5000 } }
draw:
icons:
visible: false
- text:
- font:
- style: italic
- station-train-subway:
- filter: { kind: [station, train_station], $zoom: { min: 11 } }
- visible: *label_visible_station
+ landuse-labels-green-areas-not-national-park:
+ filter:
+ kind: [park, conservation, protected_area, nature_reserve, forest, grass]
+ any:
+ # show labels for smaller landuse areas at higher zooms
+ - { $zoom: { max: 6 }, area: true }
+ - { $zoom: [6], area: { max: 5000000000 } }
+ - { $zoom: [7], area: { max: 5000000000 } }
+ - { $zoom: [8], area: { max: 1000000000 } }
+ - { $zoom: [9], area: { max: 100000000 } }
+ - { $zoom: [10], area: { max: 50000000 } }
+ - { $zoom: [11], area: { max: 20000000 } }
+ - { $zoom: [12], area: { max: 5000000 } }
+ - { $zoom: [13], area: { max: 200000 } }
+ - { $zoom: [14], area: { max: 50000 } }
+ - { $zoom: [15], area: { max: 5000 } }
+ - { $zoom: [16], area: { max: 1000 } }
draw:
icons:
- visible: *icon_visible_station
- sprite: train_station
- size: [[13, 12px], [14, 12px], [15, 16px], [17, 18px], [18, 20px]]
- priority: 41
- text:
- visible: *text_visible_station
- font:
- weight: 600
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
- low-priority-early:
- filter: { kind_tile_rank: { min: 5 }, $zoom: { min: 0, max: 13 } }
- draw:
- icons:
- visible: false
- #size: [[12, 10px], [14, 10px], [15, 16px]]
- text: { visible: false }
- low-priority-early-z13:
- filter: { kind_tile_rank: { min: 5 }, $zoom: [13] }
+ visible: false
+ wilderness-areas-early:
+ filter: function() { return $zoom < 9 && feature.name && (feature.name.indexOf("Wilderness") > -1 || feature.name.indexOf("BLM") > -1 || feature.protect_class == '1' || feature.protect_class == '1a' || feature.protect_class == '1b' ); }
draw:
icons:
visible: false
- #size: [[12, 10px], [14, 10px], [15, 16px]]
- text: { visible: false }
- low-priority-early-z14:
- filter: { kind_tile_rank: { min: 7 }, $zoom: [14] }
- draw:
- icons:
- #size: [[14, 11px], [15, 16px], [17, 18px], [18, 20px]]
- #visible: false
- text: { visible: false }
- stations-later:
- filter: { $zoom: { min: 18 } }
- draw:
- icons:
- text:
- font:
- size: 11px
- tram-stop-early:
- filter: { kind: tram_stop, $zoom: { max: 15 } }
+ not-national-park:
+ filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
+ early:
+ filter: { $zoom: { max: 8 } }
+ draw:
+ icons:
+ visible: false
+ landuse-labels-not-any-above:
+ filter:
+ $zoom: { max: 6 }
+ not: { kind: [aerodrome, airport, allotments, aquarium, attraction, battlefield, beach, cemetery, college, conservation, forest, garden, glacier, golf_course, grass, kindergarten, landmark, maze, national_park, nature_reserve, park, playground, protected_area, resort, school, stadium, station, theme_park, university, winery, winter_sports, zoo] }
draw:
icons:
visible: false
- text:
- visible: false
- tram-stop-early-z15:
- filter: { kind: tram_stop, $zoom: [15] }
- draw:
- icons:
- text:
- visible: false
- tram-stop:
- filter: { kind: tram_stop, $zoom: { min: 15 } }
- draw:
- icons:
- size: [[16, 12px], [17, 18px]]
- glaciers-pois:
- filter: { $zoom: { min: 14 }, kind: glacier, area: false }
+ glacier:
+ filter: { $zoom: { max: 14 }, kind: glacier, area: false }
draw:
icons:
visible: false
- text:
- visible: false
- text:
- visible: false
- priority: 45
- text_wrap: 10
+
+
+ # set special priority, sprite, and text styles per kind
+ # has-area:
+ # filter: { area: true }
+ # draw:
+ # icons:
+ # priority: 41
+
+ national-park-protected-areas:
+ filter:
+ kind: national_park
+ draw:
+ icons:
+ visible: global.icon_visible_landuse_green
+ size: global.icon_size_green
+ sprite: park
+ priority: 41
+ text:
+ visible: global.text_visible_landuse_green
font:
- weight: 400
+ fill: global.text_fill_park
style: italic
- fill: '#4ba3c5'
- bus-stop-bus-station-labels:
- filter:
- kind: [bus_stop, bus_station]
- $zoom: { min: 18 }
+ # large park icon
+ # z14-parks:
+ # filter: { $zoom: { min: 14 } }
+ # draw:
+ # icons:
+ # sprite: park-l
+ # size: [[14,24px],[16,32px]]
+ parks:
+ filter:
+ - kind: [park, conservation, grass]
+ - { kind: protected_area, not: { protect_class: [6, '6'] } }
+ draw:
+ icons:
+ visible: global.icon_visible_landuse_green
+ size: global.icon_size_green
+ sprite: park
+ priority: 41
+ text:
+ visible: global.text_visible_landuse_green
+ font:
+ fill: global.text_fill_park
+ style: italic
+
+ only-text-later:
+ filter: { kind: [grass], $zoom: { min: 16 } }
draw:
icons:
- size: [[17, 8px], [19, 18px]]
+ size: 0px
text:
- visible: *text_visible_poi_landuse
font:
- size: 10px
- stroke: { color: *text_stroke, width: 4 }
- bus_stop-early:
+ style: italic
+ forest:
+ filter:
+ - kind: forest
+ - { kind: protected_area, protect_class: [6, '6'] }
+ draw:
+ icons:
+ visible: global.icon_visible_landuse_green
+ size: global.icon_size_green
+ sprite: forest
+ priority: 41
+ text:
+ visible: global.text_visible_landuse_green
+ font:
+ fill: global.text_fill_park
+ style: italic
+# wilderness-nature_reserve:
+# filter:
+# - kind: nature_reserve
+# draw:
+# icons:
+# visible: global.icon_visible_landuse_green
+# size: global.icon_size_green
+# sprite: forest
+# priority: 41
+# text:
+# visible: global.text_visible_landuse_green
+# font:
+# fill: global.text_fill_park
+# style: italic
+
+ beach:
+ filter:
+ kind: [beach]
+ draw:
+ icons:
+ visible: global.icon_visible_landuse_green
+ size: global.icon_size_green
+ text:
+ visible: global.text_visible_landuse_green
+ font:
+ fill: global.text_fill_beach
+ airport:
+ filter:
+ kind: [airport, aerodrome]
+ draw:
+ icons:
+ visible: global.icon_visible_landuse_green
+ size: global.icon_size_green
+ priority: 42
+ text:
+ visible: global.text_visible_landuse_green
+ text_source: global.ux_language_text_source_iata
+ early:
+ filter: { $zoom: [9,10,11] }
+ draw: { icons: { text: { text_source: iata } } }
+ early2:
+ filter: { $zoom: { min: 12 } }
+ draw: { icons: { text: { font: { size: 11px } } } }
+ enclosure-related:
+ filter:
+ kind: [enclosure, animal]
+ draw:
+ icons:
+ priority: 43
+ size: 0px
+ #: dot-black
+ text:
+ text_wrap: 10
+ font:
+ style: italic
+ weight: normal
+ glacier:
+ filter:
+ kind: glacier
+ draw:
+ icons:
+ size: 0px
+ #visible: false
+ text:
+ visible: true
+ priority: 44
+ text_wrap: 10
+ font:
+ weight: normal
+ style: italic
+ fill: global.text_fill_park
+
+ # landuse-labels-not-any-above:
+ # filter:
+ # not: { kind: [aerodrome, airport, allotments, aquarium, attraction, battlefield, beach, cemetery, college, conservation, forest, garden, glacier, golf_course, grass, kindergarten, landmark, maze, national_park, nature_reserve, park, playground, protected_area, resort, school, stadium, station, theme_park, university, winery, winter_sports, zoo] }
+ # draw:
+ # icons:
+ # priority: 43
+
+ building-like:
+ filter: { kind: [commercial,residential,warehouse,public,dormitory], osm_relation: false }
+ draw:
+ icons:
+ sprite: building
+
+ station-train-subway:
+ filter: { kind: [station, train_station] }
+ draw:
+ icons:
+ visible: global.icon_visible_station
+ size: [[13, 12px], [14, 12px], [15, 16px], [17, 18px], [18, 20px]]
+ priority: 44
+ text:
+ visible: global.text_visible_station
+ station-early:
filter:
- kind: [bus_stop]
- $zoom: { max: 17 }
+ $zoom: { max: 11 }
draw:
icons:
visible: false
- text:
- visible: false
- bus_stop-early-z17:
- filter:
- kind: [bus_stop]
- $zoom: [17,18]
- draw:
- icons:
- size: [[17, 16px], [19, 18px]]
- text:
- visible: false
- minor-z17-early:
- filter:
- kind: [accountant, administrative, advertising_agency, architect, association, atm, bakery, bed_and_breakfast, bicycle, bicycle_parking, bicycle_rental_station, books, bus_stop, butcher, car, car_repair, chalet, clothes, company, computer, consulting, convenience, doityourself, drinking_water, dry_cleaning, educational_institution, emergency_phone, employment_agency, estate_agent, fashion, financial, florist, foundation, gate, gift, government, greengrocer, guest_house, hairdresser, hostel, hotel, insurance, it, jewelry, lawyer, mast, memorial, mobile_phone, motel, newspaper, ngo, notary, optician, parking, pet, physician, playground, political_party, post_box, religion, research, subway_entrance, tax_advisor, telecommunication, telephone, theatre, therapist, toilets, traffic_signals, travel_agent, water_tower, true]
- area: false
- $zoom: { max: 17 }
+ # for a transit style we'd want to see **all**, so don't move this above (it's special to this style)
+ low-priority-early:
+ filter: { kind_tile_rank: { min: 5 }, $zoom: { min: 0, max: 13 } }
draw:
icons:
visible: false
- text: { visible: false }
- minor-z18-early:
- filter:
- kind: [bench, waste_basket]
- area: false
- $zoom: { max: 18 }
+ low-priority-early-z13:
+ filter: { kind_tile_rank: { min: 5 }, $zoom: [13] }
draw:
icons:
visible: false
- text: { visible: false }
- outdoor-needing-icons:
- filter: { kind: [boat_rental,bicycle_repair_station, cycle_barrier, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, communications_tower, putin, egress, hazard, put_in_egress, rapid, beacon, cross, mineshaft, adit, water_well, saddle, dune, sinkhole, rock, stone, bicycle_junction, walking_junction, dam, boat_storage, windmill, fishing, recreation_track, horse, fire_lookout, fee_station, rest_area] }
+ low-priority-early-z14:
+ filter: { kind_tile_rank: { min: 7 }, $zoom: [14] }
draw:
icons:
- order: 41
- sprite: generic
- text:
- order: 42
- outdoor-has-icons:
- filter: { kind: [outdoor, lighthouse, saddle, picnic_area, picnic_table, camp_site, ski, mine, zoo, museum, gas, gas_canister, slipway, mineshaft, adit, recreation_track, playground, allotments, attraction, landmark] }
+ text: { visible: false }
+
+ tram-stop-early:
+ filter: { kind: tram_stop, $zoom: { max: 15 } }
+ draw:
+ icons:
+ visible: false
+ text:
+ visible: false
+ tram-stop:
+ filter: { kind: tram_stop, $zoom: { min: 15 } }
+ draw:
+ icons:
+ size: [[16, 12px], [17, 18px]]
+
+ garden-no-area-early:
+ filter: { kind: [garden, allotments], $zoom: [16], area: false }
+ draw:
+ icons:
+ priority: 45
+ size: 14px
+ text: { font: { size: 10px, style: italic } }
+ garden-no-area-later:
+ filter: { kind: [garden, allotments], $zoom: { min: 17 }, area: false }
+ draw:
+ icons:
+ priority: 45
+ size: 16px
+ text: { font: { size: 11px, style: italic } }
+ gate:
+ filter: { kind: gate, name: true }
+ draw: { icons: { sprite: generic } }
+
+ parking-labels:
+ filter:
+ kind: [parking]
+ $zoom: { min: 18 }
+ draw:
+ icons:
+ text:
+ visible: global.text_visible_poi_landuse
+ font:
+ size: 10px
+ tower:
+ filter: { kind: [tower], label_placement: true }
+ draw:
+ icons:
+ size: 0px
+ #visible: false
+ text:
+ font:
+ style: italic
+
+ # TODO: this isn't working, should see small icons near the transbay terminal in SF
+ bus_stop:
+ filter:
+ kind: [bus_stop]
+ draw:
+ icons:
+ size: 14px
+ text:
+ font:
+ size: 11px
+ weight: normal
+ later:
+ filter: { $zoom: { max: 19 } }
draw:
icons:
- order: 41
text:
- order: 42
- not-outdoor-not-landuse:
- filter: { area: false, not: { kind: [park, national_park, outdoor, bicycle_repair_station, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, bicycle_junction, walking_junction, dam, boat_storage, windmill, playground, allotments, attraction, landmark] } }
+ visible: false
+
+ airport-gate:
+ filter: { kind: aeroway_gate }
+ draw:
+ icons:
+ visible: false
+ text-blend-order:
+ visible: global.text_visible_airport_gate
+ text_source: ref
+ priority: 63
+ font:
+ fill: global.text_fill_exits
+ size: [[16,9px],[17,12px],[20,14px]]
+ later:
+ filter: { $zoom: { min: 19 } }
draw:
icons:
- order: 45
text:
- order: 46
- suppress-early:
- filter: { $zoom: { max: 15 }, kind: [scrub, wetland, scree, meadow, grass, farmyard, farmland, wood, pier, breakwater, groyne, dike, cutline, residential, retail, commercial, industrial] }
+ font:
+ weight: 600
+
+ highway-exit:
+ filter: { kind: motorway_junction, $zoom: { min: 16 } }
+ draw:
+ icons:
+ visible: false
+ text-blend-order:
+ visible: global.text_visible_exits
+ text_source: ref
+ priority: 63
+ font:
+ fill: global.text_fill_exits
+ size: [[12,9px],[15,12px],[17,14px]]
+ stroke: { color: global.text_stroke, width: [[12,2px],[14,3px],[15,3px]] }
+ later:
+ filter: { $zoom: { min: 16 } }
draw:
icons:
- visible: false
- text:
- visible: false
- meadow:
- filter: { kind: [meadow], $zoom: [14] }
- draw:
text:
- visible: true
- text_wrap: 10
font:
- style: italic
- suppress-the-icon-text-label-only:
- filter: { $zoom: { min: 15 }, kind: [scrub, wetland, scree, meadow, village_green, common, grass, farmyard, farmland, wood, enclosure, animal, pier, breakwater, groyne, dike, cutline, residential, retail, commercial, industrial] }
- draw:
- icons:
- visible: false
- text:
- visible: true
- text_wrap: 10
- font:
- style: italic
- icons:
- building-icon:
- filter: { kind: [building, auditorium, terminal, hangar, retirement_home, manor, recreation_center, apartments] }
- draw: { icons: { sprite: building } }
- early:
- filter:
- any:
- # show labels for smaller landuse areas at higher zooms
- - { $zoom: [14], area: { max: 200000 } }
- - { $zoom: [15], area: { max: 20000 } }
- - { $zoom: [16], area: { max: 5000 } }
- - { $zoom: [17], area: { max: 1000 } }
- draw:
- icons:
- visible: false
- text:
- visible: false
- college:
- filter: { kind: [university, college], area: false }
- draw: { icons: { sprite: college } }
- dam:
- filter: { kind: [dam] }
- draw: { icons: { sprite: dam } }
- hardware-store:
- filter: { kind: [hardware, hardware-store, doityourself, paint] }
- draw: { icons: { sprite: hardware-store } }
- hotel:
- filter: { kind: [hotel, motel, hostel] }
- draw: { icons: { sprite: hotel } }
- landmark:
- filter: { kind: [landmark, memorial, monument, wayside_shrine, beacon] }
- draw: { icons: { sprite: landmark } }
- tower:
- filter: { kind: [tower], label_placement: false }
- draw: { icons: { sprite: landmark } }
- # prefix with "a-" here to allow Tangram to sort the generic style 1st, allowing more specific religion tags to win later
- place_of_worship:
- filter:
- all:
- - kind: [place_of_worship, wayside_chapel]
- draw:
- icons:
- sprite: function() { return feature.religion; }
- sprite_default: place_of_worship
+ weight: 600
+
+
water-area-labels:
data: { source: mapzen, layer: [water] }
- visible: *text_visible_water_labels
+ visible: global.text_visible_water_labels
filter:
all:
- name: true
text-blend-order:
text_source: global.ux_language_text_source
font:
- fill: *text_fill_water
- family: *text_font_family
+ fill: global.text_fill_water
+ family: global.text_font_family
style: italic
weight: 400
size: 12px
ocean-sea-labels:
data: { source: mapzen, layer: water }
- visible: *text_visible_water_labels
+ visible: global.text_visible_water_labels
filter: { name: true, kind: [sea, ocean] }
draw:
text-blend-order:
text_source: global.ux_language_text_source
font:
- fill: *text_fill_water
- family: *text_font_family
+ fill: global.text_fill_water
+ family: global.text_font_family
weight: normal
size: 12px
transform: uppercase
filter: { kind: [continent], $zoom: {max: 5} }
draw:
text-blend-order:
- visible: *text_visible_continent
+ visible: global.text_visible_continent
text_source: global.ux_language_text_source_continent_stacked_only
text_wrap: false
font:
- family: *text_font_family
+ family: global.text_font_family
size: [[1,11px],[3,14px]]
style: italic
- fill: *text_fill
+ fill: global.text_fill
weight: normal
transform: uppercase
continent-spacer:
filter: { kind: [archipelago, island, islet] }
draw:
text-blend-order:
- visible: *text_visible_island
+ visible: global.text_visible_island
text_wrap: 10
font:
- family: *text_font_family
+ family: global.text_font_family
size: 12px
style: italic
- fill: *text_fill
+ fill: global.text_fill
weight: normal
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
#transform: uppercase
landuse:
- data: { source: mapzen }
+ data: { source: mapzen, layer: landuse }
draw:
terrain:
order: function() { return feature.sort_rank; }
visible: false
+
+ landuse-labels:
+ filter:
+ all:
+ - label_placement: true
+ - name: true
+ draw:
+ text-blend-order:
+ text_source: global.ux_language_text_source
+ interactive: global.interactive
+ move_into_tile: true
+ priority: 100
+ visible: global.text_visible_landuse_generic
+ font:
+ fill: '#666'
+ family: global.text_font_family
+ style: italic
+ size: 11px
+ stroke: { color: global.text_stroke_address, width: 1 }
+
+ show-with-icon:
+ filter: { kind: [allotments] }
+ draw:
+ text-blend-order:
+ visible: false
+ icons:
+ visible: global.icon_visible_poi_landuse
+ size: [[13, 18px], [16, 18px], [18, 22px]]
+ sprite: function() { return feature.kind; }
+ sprite_default: generic
+ interactive: global.interactive
+ priority: 65 #function() { return (feature.min_zoom && Math.floor(feature.min_zoom * 1000)) || 65; }
+ repeat_group: abc
+ buffer: 7px
+ text:
+ visible: global.text_visible_poi_landuse
+ text_source: global.ux_language_text_source
+ text_wrap: 18
+ max_lines: 3
+ font:
+ family: global.text_font_family
+ weight: 600
+ fill: [0.10,0.10,0.10]
+ size: [[13,10px],[14,10px],[18,11px]]
+ stroke: { color: global.text_stroke, width: 3 }
tier1:
# filter:
# any:
visible: true
# outline:
# style: lines
- # color: *green6
+ # color: global.green6
# width: [[9,0px],[10,2px],[12,4px]]
national_forest_level_6:
- operator: ['United States Forest Service']
draw:
terrain:
- color: [0.945,0.995,0.945] #*green7
+ color: [0.945,0.995,0.945] #global.green7
visible: true
parks-and-national-forests-not-national-park:
draw:
polygons:
color: [1.00,1.00,1.00]
- visible: *green4_v
+ visible: global.green4_v
forest:
filter: { kind: [forest, wood, natural_wood, natural_forest, natural_park], $zoom: { min: 10 }, not: { operator: [ "United States Forest Service"] } }
draw:
# urban:
# filter: { kind: [urban, rural, residential] }
- # visible: *earth2_v
+ # visible: global.earth2_v
# draw:
# polygons:
# color: [1.00,1.00,1.00]
- # visible: *earth2_v
+ # visible: global.earth2_v
tier3:
# filter:
# any:
kind: aerodrome
draw:
terrain:
- color: *gray-all
- visible: *purple_v
+ color: global.gray-all
+ visible: global.purple_v
military:
filter:
kind: military
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
university:
filter:
kind: [university, college]
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
tier4:
# filter:
kind: industrial
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
power:
filter: { kind: [plant, generator, substation] }
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
railway:
filter:
kind: railway
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
# IGNORE THIS FOR NOW
# sports_centre:
kind: stadium
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
zoo:
filter:
draw:
terrain:
color: [1.0,1.0,1.0]
- visible: *grey8_v
+ visible: global.grey8_v
man-made:
filter: { kind: [pier,wastewater_plant,works,bridge,tower,breakwater,water_works,groyne,dike,cutline] }
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
pier:
filter: { kind: [pier,bridge,breakwater,groyne,dike,cutline] }
filter: { kind: camp_site }
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
tier5:
- maze
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
beach:
filter:
- { $zoom: { min: 15 }, area: { min: 5000 } }
draw:
terrain:
- color: *gray-all
- visible: *grey1_v
+ color: global.gray-all
+ visible: global.grey1_v
early:
filter: { $zoom: { max: 15 } }
draw:
draw:
terrain:
color: [0.945,0.995,0.945]
- visible: *grey1_v
+ visible: global.grey1_v
green-stuff:
filter:
surface: [grass]
draw:
terrain:
color: [0.808,0.962,0.951]
- # color: [0.702,0.949,0.932]
- # color: [0.975,0.975,0.828]
visible: true
farmland_friends:
filter: { kind: [farmland] }
draw:
terrain:
color: [0.930,0.973,0.980]
- # color: [0.975,0.975,0.828]
visible: true
scrub:
filter:
draw:
terrain:
color: [1.000,0.953,0.900]
- # color: [0.975,0.975,0.828]
visible: true
later:
filter: { $zoom: { min: 15 } }
kind: place_of_worship
draw:
terrain:
- color: *gray-all
- visible: *grey1_v
+ color: global.gray-all
+ visible: global.grey1_v
playground:
filter:
kind: playground
kind: school
draw:
terrain:
- color: *gray-all
+ color: global.gray-all
visible: true
minor-landuse:
draw:
lines:
color: [[11,[0.408,0.741,0.690]],[15,[0.131,0.667,0.575]]] #[11,[0.252,0.509,0.60]],[12,[0.120,0.600,0.520]]
- dashedline:
+ dashed_small:
color: [0.120,0.600,0.520]
dots-lines:
color: [0.120,0.600,0.520]
draw:
text-blend-order:
priority: 58
- visible: *text_visible_path
+ visible: global.text_visible_path
font:
fill: [0.143,0.544,0.481]
# fill: [0.256,0.570,0.565]
size: 12px
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
in_zoo_golf_course:
filter: { landuse_kind: [zoo, golf_course, garden, university, cemetery, allotments], $zoom: { max: 15 } }
draw:
width: [[13, 0.75px], [14, 0.6px], [15, 1px], [16, 2px], [17, 3px], [18, 4px], [19, 4px]]
visible: true
#color: purple
- dashedline:
+ dashed_small:
order: 1005
early-show-as-lines-z14:
filter: { $zoom: { max: 15 } }
order: 350 # function() { return feature.sort_rank; }
dots-lines:
order: 351 # function() { return (feature.sort_rank + 1); }
- dashedline:
+ dashed_small:
visible: false
early-z17:
filter: { $zoom: { max: 18 } }
draw:
text-blend-order:
priority: 58
- visible: *text_visible_path
+ visible: global.text_visible_path
font:
fill: [0.143,0.544,0.481]
size: 12px
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
in_zoo_golf_course:
filter: { landuse_kind: [zoo, golf_course, garden, university, cemetery, allotments], $zoom: { max: 15 } }
draw:
draw:
text-blend-order:
priority: 58
- visible: *text_visible_path
+ visible: global.text_visible_path
font:
fill: [0.120,0.600,0.520]
size: 12px
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
track-overlay:
data: { source: mapzen, layer: roads }
draw:
text-blend-order:
priority: 58
- visible: *text_visible_path
+ visible: global.text_visible_path
font:
fill: [0.536,0.451,0.378]
size: 12px
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
in_zoo_golf_course-early:
filter: { landuse_kind: [zoo, golf_course, garden, university, cemetery, allotments], $zoom: { max: 15 } }
draw:
draw:
text-blend-order:
priority: 58
- visible: *text_visible_path
+ visible: global.text_visible_path
font:
fill: [0.536,0.451,0.378]
size: 12px
- stroke: { color: *text_stroke, width: 4 }
+ stroke: { color: global.text_stroke, width: 4 }
other-roads-walking-network-only:
outline:
color: [0.120,0.600,0.520]
width: [[15, 0.5px],[16, 1.5px],[17, 1.5px],[18, 2.5px],[19, 1m]]
- casing_left:
- visible: false
- order: 486
- color: [0.120,0.600,0.520]
- width: [[15, 0.5px],[16, 5.5px],[17, 10px],[18, 9m],[19, 8m]]
- casing_right:
- visible: false
- order: 486
- color: white
- width: [[15, 0.5px],[16, 6px],[17, 10px],[18, 9m],[19, 8m]]
the_network:
draw:
lines:
transit-overlay-rail-lines:
data: { source: mapzen, layer: transit }
filter:
- not: { kind: [platform, railway] }
+ all:
+ - not: { kind: [platform, railway] }
+ - function() { return global.sdk_transit_overlay; }
draw:
lines:
order: 499
- visible: global.sdk_transit_overlay
color: purple
width: [[5,1.5px],[6,2px],[11,3px],[18,4px]]
outline:
draw:
lines:
order: 504
- labels-transit-lines-early:
- filter: { $zoom: [13,14], ref: true }
- draw:
- text:
- visible: global.sdk_transit_overlay
- priority: 20
- text_source: function() { if( feature.ref.length < 4 ) { return feature.ref; } else { return ''; } }
- font:
- fill: black
- size: 12px
- weight: bold
- stroke: { color: white, width: 2 }
labels-transit-lines:
- filter: { $zoom: { min: 15 } }
+ filter:
+ all:
+ - function() { return global.sdk_transit_overlay; }
+ - all:
+ - $zoom: { min: 13 }
+ - ref: true
draw:
- text:
- visible: global.sdk_transit_overlay
+ icons:
priority: 20
- text_source: ref
- font:
- fill: black
- size: 14px
- weight: bold
- stroke: { color: white, width: 2 }
- z19-show-long-route-name:
- filter: { $zoom: { min: 19 } }
+ # you need to match any custom shield to the vector tile `network` values
+ sprite: function() { return ('sdk_shield-' + feature.ref.length + 'char'); }
+ sprite_default: sdk_shield_5char
+ color: function() { if ( feature.kind === 'train') { return 'purple' } else { return feature.colour || 'purple'; } }
+ # Size is specified below, and limited to 5 char in another filter
+ repeat_group: shields
+ repeat_distance: [[8,90px],[10,40px],[13,30px]]
+ placement: midpoint
+ placement_min_length_ratio:
+ - [8, 0.1]
+ - [9, 0.25]
+ - [10, 0.25]
+ - [11, 0.15]
+ - [12, 1]
+ - [13, 1.50]
+ - [14, 2.0]
+ cull_from_tile: true
+# visible: false
+ text:
+ offset: [0px, -0.5px]
+ repeat_distance: 200px
+ anchor: center
+ text_source: function() { if( feature.ref.length < 6 ) { return feature.ref; } else { return ''; } }
+ font:
+ family: Montserrat
+ fill: function() { if(feature.colour == 'yellow') { return '#555'; } else { return 'white'; } }
+ style: bold
+ size: [[7,7px],[12,8px],[16,11px]]
+
+ width_1char:
+ filter: function() { return (feature.ref.length === 1); }
+ draw:
+ icons:
+ size: [[6,[16px,16px]],[13,[18px,18px]],[16,[21px,21px]]]
+ width_2char:
+ filter: function() { return (feature.ref.length === 2); }
+ draw:
+ icons:
+ size: [[6,[21px,16px]],[13,[24px,18px]],[16,[28px,21px]]]
+ width_3char:
+ filter: function() { return (feature.ref.length === 3); }
+ draw:
+ icons:
+ size: [[6,[27px,16px]],[13,[31px,18px]],[16,[36px,21px]]]
+ width_4char:
+ filter: function() { return (feature.ref.length === 4); }
+ draw:
+ icons:
+ size: [[6,[32px,16px]],[13,[36px,18px]],[16,[41px,21px]]]
+ # London sucks
+ early:
+ filter: { $zoom: { max: 14 } }
+ draw:
+ icons:
+ visible: false
+ width_5char:
+ filter: function() { return (feature.ref.length === 5); }
+ draw:
+ icons:
+ size: [[6,[37px,16px]],[13,[41px,18px]],[16,[48px,21px]]]
+ # London sucks
+ early:
+ filter: { $zoom: { max: 14 } }
+ draw:
+ icons:
+ visible: false
+ # this is kinda a hack
+ width_longggggg:
+ filter: function() { return (feature.ref.length > 5); }
+ draw:
+ icons:
+ visible: false
+
+ z19-show-long-route-name:
+ filter:
+ all:
+ - function() { return global.sdk_transit_overlay; }
+ - $zoom: { min: 19 }
draw:
text:
- text_source: function() { return feature.route_name || feature.ref; }
font:
+ fill: black
+ style: italic
stroke: { color: white, width: 3px }
# transit-bus-roads:
# color: '#bc8f96'
# width: [[15,0px],[16,0.5px],[17,1px],[19,2px]]
# lines:
-# visible: false
\ No newline at end of file
+# visible: false