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.

201 lines
4.7 KiB

  1. query:
  2. 16: nwr[building][building!=no];
  3. feature:
  4. pre: |-
  5. {% set type = tags.building|split(';')[0] %}
  6. {% if tags.military %}{% set type = 'military' %}{% endif %}
  7. {% set color = const.other.color %}
  8. {% for cat, data in const %}
  9. {% if type in data.types %}
  10. {% set color = data.color %}
  11. {% endif %}
  12. {% endfor %}
  13. description: |-
  14. {% if tags.building == 'yes' and tags.military %}
  15. {{ tagTrans('building', 'military') }}
  16. {% elseif tags.building == 'yes' %}
  17. {{ keyTrans('building') }}
  18. {% else %}
  19. {{ tagTransList('building', tags.building) }}
  20. {% endif %}
  21. {% if tags.building == 'construction' and tags.construction %}
  22. ({{ tagTransList('building', tags.construction) }})
  23. {% endif %}
  24. {% if tags.building in [ 'yes', 'military' ] and tags.military %}
  25. ({{ tagTransList('military', tags.military) }})
  26. {% endif %}
  27. markerSymbol: ''
  28. listMarkerSymbol: |-
  29. {{ markerPolygon({"fillColor": color, "fillOpacity": 0.8, "width": 1, "color": "#000000" })|raw }}
  30. priority: |-
  31. {% set p = 100 %}
  32. {% if tags.name %}{% set p = p - 10 %}{% endif %}
  33. {% if tags.amenity %}{% set p = p - 1 %}{% endif %}
  34. {% if tags.historic %}{% set p = p - 1 %}{% endif %}
  35. {% if tags.culture %}{% set p = p - 1 %}{% endif %}
  36. {% if tags.highway %}{% set p = p - 1 %}{% endif %}
  37. {% if tags.railway %}{% set p = p - 1 %}{% endif %}
  38. {% if tags.aeroway %}{% set p = p - 1 %}{% endif %}
  39. {% if tags.amenity %}{% set p = p - 1 %}{% endif %}
  40. {% if tags.tourism %}{% set p = p - 1 %}{% endif %}
  41. {{ p }}
  42. style:
  43. width: 1
  44. color: '#000000'
  45. fillColor: |-
  46. {{ color }}
  47. fillOpacity: 0.8
  48. info: |-
  49. <table>
  50. {% for cat, data in const %}
  51. <tr>
  52. <td valign='top'>{{ markerPolygon({ "fillColor": data.color, "fillOpacity": "0.8", "width": 1, "color": "#000000" })|raw }}</td>
  53. <td onclick='this.classList.toggle("infoShowDetails")'><b>{{ trans(data.name) }}</b><span class='details'>:
  54. {% for i, type in data.types %}<span title='building={{ type }}'>{% if i > 0 %}, {% endif %}{{ tagTrans('building', type) }}</span>{% endfor %}
  55. </span>
  56. <span class='summary'><i class="fa fa-info-circle" aria-hidden="true"></i></span>
  57. </td>
  58. </tr>
  59. {% endfor %}
  60. </table>
  61. const:
  62. residential:
  63. name: tag:building=residential
  64. color: '#25a000'
  65. types:
  66. - house
  67. - apartments
  68. - block
  69. - flats
  70. - farm
  71. - detached
  72. - dormitory
  73. - terrace
  74. - houseboat
  75. - bungalow
  76. - static_caravan
  77. - residential
  78. - semidetached_house
  79. - ger
  80. - trullo
  81. tourism:
  82. name: tag:tourism
  83. color: '#814ce2'
  84. types:
  85. - hotel
  86. - ruins
  87. - conservatory
  88. commercial:
  89. name: tag:building=commercial
  90. color: '#ec5bcf'
  91. types:
  92. - commercial
  93. - office
  94. - industrial
  95. - retail
  96. - supermarket
  97. - warehouse
  98. - kiosk
  99. - mall
  100. - shop
  101. religious:
  102. name: tag:building=religious
  103. color: '#af29cc'
  104. types:
  105. - religious
  106. - cathedral
  107. - chapel
  108. - church
  109. - mosque
  110. - temple
  111. - synagogue
  112. - shrine
  113. - monastery
  114. amenity:
  115. name: tag:amenity
  116. color: '#2935cc'
  117. types:
  118. - kindergarten
  119. - civic
  120. - government
  121. - hospital
  122. - school
  123. - university
  124. - grandstand
  125. - public
  126. - toilets
  127. - college
  128. agriculture:
  129. name: tag:building=agriculture
  130. color: '#92e934'
  131. types:
  132. - bakehouse
  133. - barn
  134. - cowshed
  135. - farm_auxiliary
  136. - greenhouse
  137. - stable
  138. - sty
  139. - kitchen
  140. - slurry_tank
  141. - silo
  142. industrial:
  143. name: tag:landuse=industrial
  144. color: '#e2da1b'
  145. types:
  146. - construction
  147. - garbage_shed
  148. - transformer_tower
  149. - service
  150. - water_tower
  151. - industrial
  152. - warehouse
  153. - storage_tank
  154. transportation:
  155. name: tag:building=transportation
  156. color: '#1bb5e2'
  157. types:
  158. - carport
  159. - garage
  160. - garages
  161. - bridge
  162. - hangar
  163. - parking
  164. - train_station
  165. - transportation
  166. sport:
  167. name: tag:sport
  168. color: '#e21b66'
  169. types:
  170. - pavilion
  171. - riding_hall
  172. - stadium
  173. - sports_hall
  174. roof:
  175. name: tag:building=roof
  176. color: '#afafaf7f'
  177. types:
  178. - roof
  179. shelter:
  180. name: tag:amenity=shelter
  181. color: '#cc8725'
  182. types:
  183. - cabin
  184. - hut
  185. - shed
  186. military:
  187. name: tag:building=military
  188. color: '#4a7300'
  189. types:
  190. - bunker
  191. - military
  192. unspecified:
  193. name: tag:building=generic
  194. color: '#7f7f7f'
  195. types:
  196. - 'yes'
  197. - generic
  198. other:
  199. name: other
  200. color: '#ff0000'
  201. types: []