Main categories of OpenStreetBrowser
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.

125 lines
4.0 KiB

  1. {
  2. "type": "overpass",
  3. "name": {
  4. "en": "Amenities",
  5. "de": "Einrichtungen"
  6. },
  7. "query": {
  8. "13": [
  9. "(",
  10. "node[amenity~\"^(bicycle_rental)$\"];",
  11. "way[amenity~\"^(bicycle_rental)$\"];",
  12. "relation[amenity~\"^(bicycle_rental)$\"];",
  13. "node[shop~\"^(bicycle)$\"];",
  14. "way[shop~\"^(bicycle)$\"];",
  15. "relation[shop~\"^(bicycle)$\"];",
  16. ")"
  17. ],
  18. "16": [
  19. "(",
  20. "node[amenity~\"^(bicycle_.*|compressed_air)$\"];",
  21. "way[amenity~\"^(bicycle_.*|compressed_air)$\"];",
  22. "relation[amenity~\"^(bicycle_.*|compressed_air)$\"];",
  23. "node[shop~\"^(bicycle)$\"];",
  24. "way[shop~\"^(bicycle)$\"];",
  25. "relation[shop~\"^(bicycle)$\"];",
  26. "node[\"monitoring:bicycle\"];",
  27. "way[\"monitoring:bicycle\"];",
  28. "relation[\"monitoring:bicycle\"];",
  29. "node[vending~\"^(bicycle_tube)$\"];",
  30. "way[vending~\"^(bicycle_tube)$\"];",
  31. "relation[vending~\"^(bicycle_tube)$\"];",
  32. ")"
  33. ]
  34. },
  35. "feature": {
  36. "pre": [
  37. "{% if tags.shop in [ 'bicycle' ] %}",
  38. " {% set key = 'shop' %}",
  39. " {% set value = tags.shop %}",
  40. "{% elseif attribute(tags, \"monitoring:bicycle\") %}",
  41. " {% set key = 'man_made' %}",
  42. " {% set value = 'monitoring_station' %}",
  43. "{% elseif tags.vending in [ 'bicycle_tube' ] %}",
  44. " {% set key = 'vending' %}",
  45. " {% set value = tags.vending %}",
  46. "{% else %}",
  47. " {% set key = 'amenity' %}",
  48. " {% set value = tags.amenity %}",
  49. "{% endif %}",
  50. "",
  51. "{% set constIndex = (key ~ \"=\" ~ value) %}"
  52. ],
  53. "title": [
  54. "{{ localizedTag(tags, 'name') |default(localizedTag(tags, 'operator')) | default(localizedTag(tags, 'ref')) | default(trans('unnamed')) }}",
  55. "",
  56. "{% if tags.capacity %}({{ tags.capacity }}){% endif %}"
  57. ],
  58. "description": "{{ tagTrans(key, value) }}",
  59. "body": [
  60. "{% if tags.capacity %}",
  61. " {{ keyTrans('capacity') }}: {{ tags.capacity }}",
  62. "{% endif %}"
  63. ],
  64. "markerSign": "{{ const[constIndex]['sign'] }}",
  65. "priority": [
  66. "{% if const[constIndex] and const[constIndex]['priority']['capacity'] %}",
  67. " {% set max=const[constIndex]['priority']['default'] %}",
  68. " {% for v in const[constIndex]['priority']['capacity'] %}",
  69. " {% if tags.capacity >= v[0] %}{% set max=v[1] %}{% endif %}",
  70. " {% endfor %}",
  71. " {{ max }}",
  72. "{% elseif const[constIndex] is defined %}",
  73. "{{ const[constIndex]['priority'] }}",
  74. "{% else %}",
  75. "10",
  76. "{% endif %}"
  77. ]
  78. },
  79. "const": {
  80. "shop=bicycle": {
  81. "sign": "🚲",
  82. "priority": 0
  83. },
  84. "amenity=bicycle_repair_station": {
  85. "sign": "🔧",
  86. "priority": 2
  87. },
  88. "amenity=bicycle_parking": {
  89. "sign": "🅿",
  90. "priority": {
  91. "capacity": [
  92. [
  93. 0,
  94. 3
  95. ],
  96. [
  97. 20,
  98. 2
  99. ],
  100. [
  101. 100,
  102. 0
  103. ]
  104. ],
  105. "default": 3
  106. }
  107. },
  108. "amenity=bicycle_rental": {
  109. "sign": "R",
  110. "priority": 1
  111. },
  112. "man_made=monitoring_station": {
  113. "sign": "#",
  114. "priority": 4
  115. },
  116. "vending=bicycle_tube": {
  117. "sign": "T",
  118. "priority": 2
  119. },
  120. "amenity=compressed_air": {
  121. "sign": "A",
  122. "priority": 2
  123. }
  124. }
  125. }