diff --git a/cycleway_types.yaml b/cycleway_types.yaml index 08dcd6f..e995ada 100644 --- a/cycleway_types.yaml +++ b/cycleway_types.yaml @@ -3,6 +3,7 @@ query: way[highway=cycleway]; way[cyclestreet=yes]; way[bicycle_road=yes]; + way[highway=path][bicycle][bicycle!=no]; way["cycleway"]["cycleway"!~"(no|separate)"]; way["cycleway:left"]["cycleway:left"!~"(no|separate)"]; way["cycleway:right"]["cycleway:right"!~"(no|separate)"]; @@ -12,6 +13,10 @@ feature: pre: | {% set type = tags.highway %} + {% if tags.highway == 'path' and tags.bicycle and tags.bicycle != 'no' %} + {% set type = 'cycleway' %} + {% endif %} + {% if tags.cyclestreet == 'yes' %} {% set type = 'cyclestreet' %} {% elseif tags.bicycle_road in ['yes', 'designated'] %} diff --git a/cycleway_width.yaml b/cycleway_width.yaml index 956c58a..868a465 100644 --- a/cycleway_width.yaml +++ b/cycleway_width.yaml @@ -1,6 +1,7 @@ query: | ( way[highway=cycleway]; + way[highway=path][bicycle][bicycle!=no]; way["cycleway:width"]; way["cycleway:left"]["cycleway:left"!~"(no|separate)"]; way["cycleway:right"]["cycleway:right"!~"(no|separate)"]; @@ -10,6 +11,12 @@ feature: pre: | {% set driving_side = 'right' %} + {% set type = tags.highway %} + + {% if tags.highway == 'path' and tags.bicycle and tags.bicycle != 'no' %} + {% set type = 'cycleway' %} + {% endif %} + {% set width = attribute(tags, 'cycleway:width') %} {% if width matches "/'$/" %} {% set width = (width|slice(0, -1)) * 0.3048 %} @@ -49,7 +56,7 @@ feature: style: width: 4 opacity: | - {{ tags.highway == 'cycleway' or attribute(tags, 'cycleway:width') ? 1 : 0 }} + {{ type == 'cycleway' or attribute(tags, 'cycleway:width') ? 1 : 0 }} color: | {% set minWidth = tags.oneway in ['yes', 1, -1] ? const.minWidthOneway : const.minWidthBoth %} {% set optWidth = tags.oneway in ['yes', 1, -1] ? const.optWidthOneway : const.optWidthBoth %} @@ -67,7 +74,7 @@ feature: noClip: | {{ tags.oneway in ['yes', 1, -1] }} pattern: | - {% if tags.highway == 'cycleway' or attribute(tags, 'cycleway:width') %} + {% if type == 'cycleway' or attribute(tags, 'cycleway:width') %} {% if tags.oneway in ['yes', 1, -1] %}arrowHead{% endif %} {% endif %} pattern-offset: | @@ -161,7 +168,7 @@ feature: markerSymbol: false listMarkerSymbol: line description: | - {{ tagTrans('highway', tags.highway) }} + {{ tagTrans('highway', type) }} details: | {% if not attribute(tags, 'cycleway:width') %} {% elseif attribute(tags, 'cycleway:width') matches "/'$/" %} @@ -171,7 +178,7 @@ feature: {% endif %} body: |