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.

121 lines
4.5 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. "priority": [
  36. "{% set p = 100 %}",
  37. "{% if tags.name %}{% set p = p - 10 %}{% endif %}",
  38. "{% if tags.amenity %}{% set p = p - 1 %}{% endif %}",
  39. "{% if tags.historic %}{% set p = p - 1 %}{% endif %}",
  40. "{% if tags.culture %}{% set p = p - 1 %}{% endif %}",
  41. "{% if tags.highway %}{% set p = p - 1 %}{% endif %}",
  42. "{% if tags.railway %}{% set p = p - 1 %}{% endif %}",
  43. "{% if tags.aeroway %}{% set p = p - 1 %}{% endif %}",
  44. "{% if tags.amenity %}{% set p = p - 1 %}{% endif %}",
  45. "{% if tags.tourism %}{% set p = p - 1 %}{% endif %}",
  46. "{{ p }}"
  47. ],
  48. "markerSymbol": null,
  49. "listMarkerSymbol": "{{ markerPolygon({\"fillColor\": color, \"fillOpacity\": 0.8, \"width\": 1, \"color\": \"#000000\" })|raw }}",
  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>{{ markerPolygon({ \"fillColor\": data.color, \"fillOpacity\": \"0.8\", \"width\": 1, \"color\": \"#000000\" })|raw }}</td>",
  62. " <td>{{ cat }}</td>",
  63. " </tr>",
  64. "{% endfor %}",
  65. "</table>"
  66. ],
  67. "const": {
  68. "residential": {
  69. "color": "#25a000",
  70. "types": [ "house", "apartments", "block", "flats", "farm", "detached", "dormitory", "terrace", "houseboat", "bungalow", "static_caravan", "cabin", "residential", "semidetached_house", "ger", "trullo" ]
  71. },
  72. "tourism": {
  73. "color": "#814ce2",
  74. "types": [ "hotel", "ruins", "conservatory" ]
  75. },
  76. "commercial": {
  77. "color": "#ec5bcf",
  78. "types": [ "commercial", "office", "industrial", "retail", "supermarket", "warehouse", "kiosk", "mall", "shop" ]
  79. },
  80. "religious": {
  81. "color": "#af29cc",
  82. "types": [ "religious", "cathedral", "chapel", "church", "mosque", "temple", "synagogue", "shrine", "monastery" ]
  83. },
  84. "amenity": {
  85. "color": "#2935cc",
  86. "types": [ "kindergarten", "civic", "government", "hospital", "school", "university", "grandstand", "public", "toilets", "college" ]
  87. },
  88. "farm": {
  89. "color": "#92e934",
  90. "types": [ "bakehouse", "barn", "cowshed", "farm_auxiliary", "greenhouse", "stable", "sty", "kitchen", "slurry_tank", "silo" ]
  91. },
  92. "industrial": {
  93. "color": "#e2da1b",
  94. "types": [ "construction", "garbage_shed", "transformer_tower", "service", "water_tower", "industrial", "warehouse", "storage_tank" ]
  95. },
  96. "transport": {
  97. "color": "#1bb5e2",
  98. "types": [ "carport", "garage", "garages", "bridge", "hangar", "parking", "train_station", "transportation" ]
  99. },
  100. "sport": {
  101. "color": "#e21b66",
  102. "types": [ "pavilion", "riding_hall", "stadium", "sports_hall" ]
  103. },
  104. "simple": {
  105. "color": "#cc8725",
  106. "types": [ "hut", "roof", "shed" ]
  107. },
  108. "military": {
  109. "color": "#4a7300",
  110. "types": [ "bunker", "riding_hall", "sports_hall" ]
  111. },
  112. "other": {
  113. "color": "#ff0000",
  114. "types": []
  115. },
  116. "unspecified": {
  117. "color": "#7f7f7f",
  118. "types": [ "yes" ]
  119. }
  120. }
  121. }