Compare commits

...

7 Commits

  1. 5
      detailsBody.html
  2. 92
      fitness_trail.json
  3. 3
      outdoor.json
  4. 5
      popupBody.html

5
detailsBody.html

@ -93,8 +93,11 @@
<i class="fa fa-money" aria-hidden="true"></i>
<span class='key'>{{ keyTrans('payment') }}:</span>
<span class='value'>
{% set i = 0 %}
{% for k, tag in payment %}
{% if tags[tag] == 'no' %}<s>{{ k }}</s> {% else %}{{ k }} {% endif %}
{%- if i > 0 %},{% endif %}
<span title="{{ tagTrans(k, tags[tag]) }}">{% if tags[tag] == 'no' %}<s>{{ keyTrans(tag, { default: k }) }}</s>{% else %}{{ keyTrans(tag, { default: k }) }}{% endif -%}</span>
{% set i = i + 1 -%}
{% endfor %}
</span>
</li>

92
fitness_trail.json

@ -0,0 +1,92 @@
{
"type": "overpass",
"name": {
"en": "Fitness trails"
},
"query": {
"14": "relation[type=route][route=fitness_trail]"
},
"members": true,
"feature": {
"body": [
"{% set countMembers = 0 %}",
"{% for member in members %}",
"{% if const.roles[member.role] %}",
"{% if countMembers == 0 %}<h4>Route</h4><ul class='overpass-layer-list'>{% endif %}",
"{% set countMembers = countMembers + 1 %}",
"<li data-object='{{ member.id }}' data-sublayer='member'>",
" <span class='markerParent'><div class='marker'>{{ markerCircle({})|raw }}</div><div class='icon'>{{ const.roles[member.role].sign|raw }}</div></span>",
" <span class='title'>{{ member.tags.name|default(trans('loading')) }}</span>",
"</li>",
"{% endif %}",
"{% endfor %}",
"{% if countMembers > 0 %}</ul>{% endif %}"
],
"description": "{{ tagTrans('route', 'fitness_trail') }}",
"listMarkerSymbol": "{{ markerLine({ 'width': 4, 'color': '#007fff' })|raw }}",
"markerSymbol": "",
"style": {
"opacity": 0,
"z-index": 1,
"width": 4
},
"style:hover": {
"width": "4",
"color": "#000000",
"radius": "4"
}
},
"memberFeature": {
"pre": [
"{% set master0 = masters[0] %}"
],
"title": "{{ tags.name }}",
"body": [
"<h4>Routes</h4>",
"<ul class='overpass-layer-list'>",
"{% for master in masters %}",
" <li data-object=\"{{ master.id }}\">",
" <span class='markerParent'><div class='marker'>{{ markerLine({ width: 4, color: '#007fff' })|raw }}</div></span>",
" <span class='title'>{{ master.tags.name }}</span>",
" <span class='description'>{{ tagTrans('route', master.tags.route) }}</span>",
" </li>",
"{% endfor %}",
"</ul>"
],
"listExclude": "1",
"style": {
"color": "{{ '#007fff' }}",
"width": 4,
"opacity": 1,
"textRepeat": "1",
"textOffset": "12",
"textFontWeight": "bold",
"radius": "3"
},
"style:hover": {
"radius": "4"
},
"markerSymbol": "{% if const.roles[master0.role] %}{{ markerPointer({})|raw }}{% endif %}",
"markerSign": "{% if const.roles[master0.role] %}{{ const.roles[master0.role].sign|raw }}{% endif %} ",
"popupReplace": "{% if masters|length == 1 %}{{ master0.id }}{% endif %}"
},
"const": {
"roles": {
"station": {
"sign": "<img src='maki:pitch'>"
},
"information": {
"sign": "🛈"
},
"start": {
"sign": "⚐"
},
"stop": {
"sign": "🏁"
},
"start_stop": {
"sign": "⚐"
}
}
}
}

3
outdoor.json

@ -9,6 +9,9 @@
"subCategories": [
{
"id": "mtb-routes"
},
{
"id": "fitness_trail"
}
]
}

5
popupBody.html

@ -91,8 +91,11 @@
<i class="fa fa-money" aria-hidden="true"></i>
<span class='key'>{{ keyTrans('payment') }}:</span>
<span class='value'>
{% set i = 0 %}
{% for k, tag in payment %}
{% if tags[tag] == 'no' %}<s>{{ k }}</s> {% else %}{{ k }} {% endif %}
{%- if i > 0 %},{% endif %}
<span title="{{ tagTrans(k, tags[tag]) }}">{% if tags[tag] == 'no' %}<s>{{ keyTrans(tag, { default: k }) }}</s>{% else %}{{ keyTrans(tag, { default: k }) }}{% endif -%}</span>
{% set i = i + 1 -%}
{% endfor %}
</span>
</li>

Loading…
Cancel
Save