From 0f410a278efaec36562d87c6f63f7b341df0dccb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20B=C3=B6sch-Plepelits?= Date: Sun, 1 Dec 2024 08:16:07 +0100 Subject: [PATCH] cycleway_types: add const for 'hiddenTypes' (e.g. 'no', 'separate') --- cycleway_types.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/cycleway_types.yaml b/cycleway_types.yaml index f7682b2..c3a664e 100644 --- a/cycleway_types.yaml +++ b/cycleway_types.yaml @@ -55,7 +55,7 @@ feature: {% set leftCycle1 = attribute(tags, 'cycleway:left')|default(attribute(tags, 'cycleway:both')) %} {% if leftCycle1 %}{% set leftCycle = leftCycle1 %}{% endif %} - {% if leftCycle in ['no', 'separate'] %} + {% if const.hiddenTypes[leftCycle] %} {% set leftCycle = '' %} {% endif %} @@ -68,7 +68,7 @@ feature: {% set rightCycle1 = attribute(tags, 'cycleway:right')|default(attribute(tags, 'cycleway:both')) %} {% if rightCycle1 %}{% set rightCycle = rightCycle1 %}{% endif %} - {% if rightCycle in ['no', 'separate'] %} + {% if const.hiddenTypes[rightCycle] %} {% set rightCycle = '' %} {% endif %} @@ -455,3 +455,6 @@ const: opposite_track: color: '#ff0000' warning: 'Deprecated tag! Use oneway:bicycle=no and cycleway:%other_driving_side%=track, cycleway:%other_driving_side%:oneway=-1 instead.' + hiddenTypes: + 'no': true + separate: true