From 130c6a82cb1a6ead944b838baa7e453c81488e61 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20B=C3=B6sch-Plepelits?= Date: Sat, 10 Dec 2022 20:59:33 +0100 Subject: [PATCH] footways: show area:highway=* (foot related) --- footways.yaml | 37 ++++++++++++++++++++++++++++++++++--- 1 file changed, 34 insertions(+), 3 deletions(-) diff --git a/footways.yaml b/footways.yaml index 77ae078..355542e 100644 --- a/footways.yaml +++ b/footways.yaml @@ -4,6 +4,8 @@ query: way[highway~"^(footway|pedestrian|steps|path|platform)$"]; way[highway=cycleway][foot~"^(yes|designated)$"]; way[footway]; + way["area:highway"~"^(footway|pedestrian|steps|path|platform|sidewalk)$"]; + relation["area:highway"~"^(footway|pedestrian|steps|path|platform|sidewalk)$"]; way[sidewalk~"^(yes|both|left|right|no|none)$"]; way["sidewalk:left"~"(yes|no|separate)$"]; way["sidewalk:right"~"(yes|no|separate)$"]; @@ -25,6 +27,11 @@ feature: {% set sides = sides|merge(['main']) %} {% endif %} + {% if attribute(tags, 'area:highway') in ['footway'] %} + {% set sides = sides|merge(['main']) %} + {% set category = attribute(tags, 'area:highway') %} + {% endif %} + {% if tags.railway in ['platform'] %} {% set sides = sides|merge(['main']) %} {% set category = 'platform' %} @@ -85,6 +92,8 @@ feature: {% endif %} {% elseif tags.railway %} {{ tagTrans('railway', tags.railway) }} + {% elseif attribute(tags, 'area:highway') %} + {{ tagTrans('highway', attribute(tags, 'area:highway')) }} {% endif %} body: | markerSymbol: "" listMarkerSymbol: | - {% if tags.area == 'yes' %} + {% if tags.area == 'yes' or attribute(tags, 'area:highway') %} polygon {% elseif 'node' in sides %} {{ markerCircle({ width: 0, radius: 5, fillOpacity: 1, fill: true, color: const.categories[category].color }) }} @@ -248,9 +257,11 @@ feature: {{ const.categories[category].color }} style:main: fill: | - {% if tags.area == 'yes' %}true{% else %}false{% endif %} + {% if tags.area == 'yes' or attribute(tags, 'area:highway') %}true{% else %}false{% endif %} width: | - {% if tags.area == 'yes' %} + {% if attribute(tags, 'area:highway') %} + 0 + {% elseif tags.area == 'yes' %} 1 {% elseif foot and tags.segregated == 'yes' %} 2 @@ -335,6 +346,26 @@ info: | {{ tagTrans(d.key|default('highway'), k) }} {% endfor %} + + {{ markerPolygon({ + styles: 'default', + style: { + width: 1, + color: const.categories.footway.color, + fillColor: const.categories.footway.color + } + }) }} + {{ tagTrans('highway', 'footway') }} ({{ keyTrans('area') }}) + + + + + + + + + {{ tagTrans('highway', 'footway') }} ({{ keyTrans('area:highway') }}) + {{ markerCircle({ width: 0,