Main categories of OpenStreetBrowser with support for whitewater
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.

239 lines
7.0 KiB

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