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.

152 lines
7.5 KiB

  1. type: overpass
  2. name:
  3. ca: Infraestructura fèrria
  4. cs: Železniční infrastruktura
  5. de: Eisenbahn Infrastruktur
  6. en: Railway infrastructure
  7. es: Infraestructura ferroviaria
  8. fr: Infrastructure ferroviaire
  9. gl: Infraestrutura do ferrocarril
  10. hu: Vasúti infrastruktúra
  11. it: Infrastruttura ferroviaria
  12. ja: 鉄道インフラ
  13. nb: Jernbane-infrastruktur
  14. nl: Spoorweginfrastructuur
  15. oc: Infrastructura ferroviària
  16. pl: Infrastruktura kolejowa
  17. pt: Infraestrutura ferroviária
  18. pt-br: Infraestrutura ferroviária
  19. ru: Железнодорожная инфраструктура
  20. sr: Железничка инфраструктура
  21. tr: Demiryolu altyapısı
  22. query:
  23. 11: (way[railway=rail][usage~'^(main|branch)$'];node[railway~'^(station)$'];)
  24. 14: (way[railway];node[railway~'^(station|halt|tram_stop)$'];)
  25. 17: (node[railway];way[railway];)
  26. feature:
  27. title: '{% if tags.ref %}{{ localizedTag(tags, ''ref'') }} - {% endif %}{{ localizedTag(tags, ''name'')|default(localizedTag(tags, ''operator'')) }}'
  28. description: |-
  29. {{ tagTrans('railway', tags.railway) -}}
  30. {%- if tags.usage %}
  31. , {{ tagTrans('railway=rail usage', tags.usage) }}
  32. {% endif -%}
  33. {%- if tags.service %}
  34. , {{ tagTrans('railway=rail service', tags.service) }}
  35. {% endif -%}
  36. body: |-
  37. {% if tags.operator %}{{ keyTrans('operator') }}: {{ localizedTag(tags, 'operator') }}<br>{% endif %}
  38. {% if tags.usage %}{{ keyTrans('railway=rail usage') }}: {{ tagTrans('railway=rail usage', tags.usage)|default(trans('unknown')) }}<br/>{% endif %}
  39. {% if tags.service %}{{ keyTrans('railway=rail service') }}: {{ tagTrans('railway=rail service', tags.service ) }}<br/>{% endif %}
  40. {{ keyTrans('gauge') }}: {{ tags.gauge|default(trans('unknown')) }}<br/>
  41. {% if tags.electrified == 'no' %}{{ keyTrans('electrified') }}: {{ tagTrans('electrified', 'no') }}{% elseif tags.electrified %}{{ keyTrans('electrified') }}: {{ tagTrans('electrified', tags.electrified) }}, {{ keyTrans('voltage') }}: {{ tags.voltage|default(trans('unknown')) }}, {{ keyTrans('frequency') }}: {{ tags.frequency|default(trans('unknown')) }}<br/>{% endif %}
  42. markerSign: '{% if tags.railway in [ ''halt'', ''tram_stop'', ''station'', ''stop'', ''subway_entrance'' ] %}X{% endif %}'
  43. markerSymbol: |-
  44. {% if tags.railway == 'signal' %}
  45. <svg anchorX='5' anchorY='8' width='9' height='15'>
  46. <rect x='0.5' y='0.5' width='8' height='14' style='fill: #000000; fill-opacity: 1;' />
  47. <circle cx='4.5' cy='4.5' r='2.5' style='stroke-width: 1; stroke: #000000; fill: #7f7f7f;'/>
  48. <circle cx='4.5' cy='10.5' r='2.5' style='stroke-width: 1; stroke: #000000; fill: #ff0000;'/>
  49. </svg>
  50. {% elseif tags.railway == 'switch' %}
  51. <svg anchorX='5' anchorY='8' width='9' height='15'>
  52. <rect x='0.5' y='0.5' width='8' height='14' style='fill: #ffffff; fill-opacity: 1;' />
  53. <line x1='2' x2='2' y1='2' y2='13' style='stroke-width: 2; stroke: #000000; stroke-linecap: round;'/>
  54. <line x1='2' x2='7' y1='10' y2='2' style='stroke-width: 2; stroke: #000000; stroke-linecap: round;'/>
  55. </svg>
  56. {% elseif tags.railway == 'railway_crossing' %}
  57. <svg anchorX='5' anchorY='8' width='9' height='15'>
  58. <rect x='0.5' y='0.5' width='8' height='14' style='fill: #ffffff; fill-opacity: 1;' />
  59. <line x1='2' x2='7' y1='2' y2='13' style='stroke-width: 2; stroke: #000000; stroke-linecap: round;'/>
  60. <line x1='7' x2='2' y1='2' y2='13' style='stroke-width: 2; stroke: #000000; stroke-linecap: round;'/>
  61. </svg>
  62. {% elseif tags.railway not in [ 'rail', 'tram', 'subway', 'narrow_gauge', 'abandoned', 'disused' ] %}
  63. {{ markerPointer({})|raw }}
  64. {% endif %}
  65. listMarkerSymbol: |-
  66. {% if tags.railway in [ 'station', 'halt', 'tram_stop', 'stop', 'subway_entrance', 'signal', 'switch', 'railway_crossing' ] %}
  67. {% else %}
  68. line
  69. {% endif %}
  70. priority: |-
  71. {% if tags.railway == 'station' %}0
  72. {% elseif tags.railway in [ 'halt' ] %}1
  73. {% elseif tags.railway in [ 'tram_stop', 'stop' ] %}2
  74. {% elseif tags.railway in [ 'subway_entrance' ] %}3
  75. {% else %}5
  76. {% endif %}
  77. styles: '{% if tags.railway == ''narrow_gauge'' %}default,casing{% else %}default{% endif %}'
  78. style:
  79. width: |-
  80. {% if tags.service == 'yard' or tags.service == 'siding' or tags.service == 'spur' or tags.service == 'crossover' %}
  81. 1
  82. {% else %}
  83. {% if tags.railway == 'rail' %}
  84. {% if tags.usage == 'main' or tags.usage == 'branch' %}
  85. 3
  86. {% else %}
  87. 2
  88. {% endif %}
  89. {% elseif tags.railway == 'platform' %}
  90. 1
  91. {% elseif tags.railway in [ 'signal', 'switch', 'railway_crossing' ] %}
  92. 0
  93. {% else %}
  94. 2
  95. {% endif %}
  96. {% endif %}
  97. color: '{% if tags.railway == ''rail'' or tags.railway == ''narrow_gauge'' or tags.railway == ''disused'' %}{% if tags.usage == ''main'' %}#ff8100{% elseif tags.usage == ''branch'' %}#daca00{% else %}#000000{% endif %}{% elseif tags.railway == ''subway'' %}#0000ff{% elseif tags.railway == ''tram'' %}#ff00ff{% elseif tags.railway == ''light_rail'' %}#00BD14{% elseif tags.railway == ''platform'' %}#3f3f3f{% else %}#000000{% endif %}'
  98. opacity: '1'
  99. dashArray: '{% if tags.railway == ''rail'' %}{% elseif tags.railway == ''disused'' %}1,5{% elseif tags.railway == ''abandoned'' %}1,7{% endif %}'
  100. fill: |-
  101. {% if tags.railway == 'platform' %}
  102. 1
  103. {% elseif type == 'node' %}
  104. 1
  105. {% else %}
  106. {% endif %}
  107. fillColor: |-
  108. {% if tags.railway == 'platform' %}
  109. #3f3f3f
  110. {% elseif type == 'node' %}
  111. #ffffff
  112. {% endif %}
  113. fillOpacity: |-
  114. {% if tags.railway == 'platform' %}
  115. 0.2
  116. {% elseif type == 'node' %}
  117. 0
  118. {% endif %}
  119. style:casing:
  120. width: '{% if tags.service == ''yard'' or tags.service == ''siding'' or tags.service == ''spur'' or tags.service == ''crossover'' %}5{% else %}{% if tags.railway == ''rail'' %}{% if tags.usage == ''main'' or tags.usage == ''branch'' %}7{% else %}6{% endif %}{% elseif tags.railway == ''platform'' %}5{% else %}6{% endif %}{% endif %}'
  121. color: '{% if tags.railway == ''rail'' or tags.railway == ''narrow_gauge'' or tags.railway == ''disused'' %}{% if tags.usage == ''main'' %}#ff8100{% elseif tags.usage == ''branch'' %}#daca00{% else %}#000000{% endif %}{% elseif tags.railway == ''subway'' %}#0000ff{% elseif tags.railway == ''tram'' %}#ff00ff{% elseif tags.railway == ''light_rail'' %}#00BD14{% elseif tags.railway == ''platform'' %}#3f3f3f{% else %}#000000{% endif %}'
  122. lineCap: butt
  123. dashArray: '2,4'
  124. info: |-
  125. <table>
  126. <tr>
  127. <td>{{ markerLine(evaluate({ "railway": "rail", "usage": "main" }))|raw }}</td>
  128. <td>{{ tagTrans('railway', 'rail') }}, {{ keyTrans('usage') }}: {{ tagTrans('usage', 'main') }}</td>
  129. </tr>
  130. <tr>
  131. <td>{{ markerLine(evaluate({ "railway": "rail" }))|raw }}</td>
  132. <td>{{ tagTrans('railway', 'rail') }}</td>
  133. </tr>
  134. <tr>
  135. <td>{{ markerLine(evaluate({ "railway": "narrow_gauge" }))|raw }}</td>
  136. <td>{{ tagTrans('railway', 'narrow_gauge') }}</td>
  137. </tr>
  138. <tr>
  139. <td>{{ markerLine(evaluate({ "railway": "light_rail" }))|raw }}</td>
  140. <td>{{ tagTrans('railway', 'light_rail') }}</td>
  141. </tr>
  142. <tr>
  143. <td>{{ markerLine(evaluate({ "railway": "subway" }))|raw }}</td>
  144. <td>{{ tagTrans('railway', 'subway') }}</td>
  145. </tr>
  146. {% if map.zoom >= 14 %}
  147. <tr>
  148. <td>{{ markerLine(evaluate({ "railway": "tram" }))|raw }}</td>
  149. <td>{{ tagTrans('railway', 'tram') }}</td>
  150. </tr>
  151. {% endif %}
  152. </table>