Main categories of OpenStreetBrowser with public transport zoom level
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

142 lines
4.4 KiB

  1. <ul>
  2. {% set address = tagsPrefix(tags, 'addr:') %}
  3. {% if address %}
  4. <li class='hasSymbol'>
  5. <i class="fa fa-map-marker" aria-hidden="true"></i>
  6. <span class='key'>{{ keyTrans('address') }}:</span>
  7. <span class='value'>
  8. {{ attribute(tags, 'addr:street') }}
  9. {{ attribute(tags, 'addr:housenumber') }},
  10. {{ attribute(tags, 'addr:postcode') }}
  11. {{ attribute(tags, 'addr:city') }}
  12. </span>
  13. </li>
  14. {% endif %}
  15. {% if tags.website %}
  16. <li class='hasSymbol'>
  17. <i class="fa fa-globe" aria-hidden="true"></i>
  18. <span class='key'>{{ keyTrans('website') }}:</span>
  19. <span class='value'>
  20. <a target='_blank' href='{{ tags.website|websiteUrl }}'>{{ tags.website }}</a>
  21. </span>
  22. </li>
  23. {% endif %}
  24. {% if attribute(tags, 'contact:website') %}
  25. <li class='hasSymbol'>
  26. <i class="fa fa-globe" aria-hidden="true"></i>
  27. <span class='key'>{{ keyTrans('website') }}:</span>
  28. <span class='value'>
  29. <a target='_blank' href='{{ attribute(tags, 'contact:website')|websiteUrl }}'>{{ attribute(tags, 'contact:website') }}</a>
  30. </span>
  31. </li>
  32. {% endif %}
  33. {% if tags.phone %}
  34. <li class='hasSymbol'>
  35. <i class="fa fa-phone" aria-hidden="true"></i>
  36. <span class='key'>{{ keyTrans('phone') }}:</span>
  37. <span class='value'>
  38. <a target='_blank' href='tel:{{ tags.phone }}'>{{ tags.phone }}</a>
  39. </span>
  40. </li>
  41. {% endif %}
  42. {% if attribute(tags, 'contact:phone') %}
  43. <li class='hasSymbol'>
  44. <i class="fa fa-phone" aria-hidden="true"></i>
  45. <span class='key'>{{ keyTrans('phone') }}:</span>
  46. <span class='value'>
  47. <a target='_blank' href='tel:{{ attribute(tags, 'contact:phone') }}'>{{ attribute(tags, 'contact:phone') }}</a>
  48. </span>
  49. </li>
  50. {% endif %}
  51. {% if attribute(tags, 'contact:email') or tags.email %}
  52. <li class='hasSymbol'>
  53. <i class="fa fa-user-circle" aria-hidden="true"></i>
  54. <span class='key'>{{ keyTrans('contact') }}:</span>
  55. <span class='value'>
  56. {% if attribute(tags, 'contact:email') %}
  57. <a target='_blank' href='mailto:{{ attribute(tags, 'contact:email') }}'>
  58. <i class="fa fa-envelope" aria-hidden="true"></i>
  59. </a>
  60. {% endif %}
  61. {% if attribute(tags, 'email') %}
  62. <a target='_blank' href='mailto:{{ attribute(tags, 'email') }}'>
  63. <i class="fa fa-envelope" aria-hidden="true"></i>
  64. </a>
  65. {% endif %}
  66. </span>
  67. </li>
  68. {% endif %}
  69. {% if tags.opening_hours %}
  70. <li class='hasSymbol'>
  71. <i class="fa fa-clock-o" aria-hidden="true"></i>
  72. <span class='key'>{{ keyTrans('opening_hours') }}:</span>
  73. <span class='value'>
  74. {{ tags.opening_hours }}
  75. </span>
  76. </li>
  77. {% endif %}
  78. {% set payment = tagsPrefix(tags, 'payment:') %}
  79. {% if payment %}
  80. <li class='hasSymbol'>
  81. <i class="fa fa-money" aria-hidden="true"></i>
  82. <span class='key'>{{ keyTrans('payment') }}:</span>
  83. <span class='value'>
  84. {% set i = 0 %}
  85. {% for k, tag in payment %}
  86. {%- if i > 0 %},{% endif %}
  87. <span title="{{ tagTrans(k, tags[tag]) }}">{% if tags[tag] == 'no' %}<s>{{ keyTrans(tag, { default: k }) }}</s>{% else %}{{ keyTrans(tag, { default: k }) }}{% endif -%}</span>
  88. {% set i = i + 1 -%}
  89. {% endfor %}
  90. </span>
  91. </li>
  92. {% endif %}
  93. {% if attribute(tags, 'wheelchair') %}
  94. <li class='hasSymbol'>
  95. <i class="fa fa-info-circle" aria-hidden="true"></i>
  96. <span class='key'>{{ trans('facilities') }}:</span>
  97. <span class='value'>
  98. {% if attribute(tags, 'wheelchair') %}
  99. <i class="fa fa-wheelchair-alt {{ tags.wheelchair }}" aria-hidden="true" title='{{ keyTrans('wheelchair') }}: {{ tagTrans('wheelchair', tags.wheelchair) }}'></i>
  100. {% if attribute(tags, 'toilets:wheelchair') %}
  101. (<span class='{{ attribute(tags, 'toilets:wheelchair') }}' title='{{ keyTrans('toilets:wheelchair') }}: {{ tagTrans('toilets:wheelchair', attribute(tags, 'toilets:wheelchair')) }}'>&#128701;</span>)
  102. {% endif %}
  103. {% endif %}
  104. </span>
  105. </li>
  106. {% endif %}
  107. {% set wikipedia = null %}
  108. {% if attribute(tags, 'wikipedia') %}
  109. {% set wikipedia = tags.wikipedia|matches("^([^:]+):(.*)$") %}
  110. {% endif %}
  111. {% if not wikipedia %}
  112. {% for k, v in tags %}
  113. {% set m = k|matches("^wikipedia:(.*)$") %}
  114. {% if m %}
  115. {% set wikipedia = [ 0, m[1], v ] %}
  116. {% endif %}
  117. {% endfor %}
  118. {% endif %}
  119. {% if wikipedia %}
  120. <li class='hasSymbol'>
  121. <i class="fa fa-wikipedia-w" aria-hidden="true"></i>
  122. <span class='key'>{{ keyTrans('wikipedia') }}:</span>
  123. <span class='value'><a href="https://{{ wikipedia[1] }}.wikipedia.org/wiki/{{ wikipedia[2]|replace({ ' ': '_' }) }}">{{ wikipedia[2] }}</a></span>
  124. {% endif %}
  125. </ul>