Browse Source

Replace parameter 'weight' by 'width'

heritage
parent
commit
88a4290be7
  1. 2
      buildings.json
  2. 2
      car_maxspeed.json
  3. 2
      cycle_routes.json
  4. 22
      railway-electrification.json
  5. 4
      railway-infrastructure.json
  6. 2
      water.json

2
buildings.json

@ -28,7 +28,7 @@
"{{ p }}"
],
"style": {
"weight": "1",
"width": "1",
"color": "#000000",
"fillColor": "#000000"
}

2
car_maxspeed.json

@ -51,7 +51,7 @@
"markerSign": null,
"listMarkerSymbol": "line",
"style": {
"weight": "3",
"width": "3",
"color": "{{ color }}"
}
},

2
cycle_routes.json

@ -13,7 +13,7 @@
"feature": {
"priority": "{% if tags.network=='icn' %}0{% elseif tags.network=='ncn' %}1{% elseif tags.network=='rcn' %}2{% else %}3{% endif %}",
"style": {
"weight": 4,
"width": 4,
"color": "{% if tags.network=='icn' %}#ff0000{% elseif tags.network=='ncn' %}#ff007f{% elseif tags.network=='rcn' %}#7f00ff{% else %}#0000ff{% endif %}",
"opacity": 1
}

22
railway-electrification.json

@ -21,16 +21,16 @@
"{%endif %}",
"",
"{% if tags.service == 'yard' or tags.service == 'siding' or tags.service == 'spur' or tags.service == 'crossover' %}",
" {% set weight=2 %}",
" {% set width=2 %}",
" {% else %}",
" {% if tags.railway == 'rail' %}",
" {% if tags.usage == 'main' or tags.usage == 'branch' %}",
" {% set weight=3 %}",
" {% set width=3 %}",
" {% else %}",
" {% set weight=2.5 %}",
" {% set width=2.5 %}",
" {% endif %}",
" {% else %}",
" {% set weight=2 %}",
" {% set width=2 %}",
" {% endif %}",
"{% endif %}"
],
@ -57,7 +57,7 @@
"styles": "casing,default",
"priority": "{% if tags.railway == 'station' %}0{% elseif tags.railway in [ 'halt', 'tram_stop' ] %}1{% else %}5{% endif %}",
"style": {
"weight": "{{ weight }}",
"width": "{{ width }}",
"lineCap": "butt",
"color": "{{ color }}",
"opacity": "1",
@ -71,7 +71,7 @@
]
},
"style:casing": {
"weight": "{{ weight }}",
"width": "{{ width }}",
"color": "white",
"opacity": "1",
"fill": null
@ -81,13 +81,13 @@
"<table>",
" {% set color = '#000000' %}",
" <tr>",
" <td>{{ markerLine({ 'weight': 3, 'color': color })|raw }}</td>",
" <td>{{ markerLine({ 'width': 3, 'color': color })|raw }}</td>",
" <td>{{ trans('not electrified') }}</td>",
" </tr>",
"{% for i in range(0, 1000, 200) %}",
" {% set color = colorInterpolate([ '#00ff00', 'blue' ], i / 1000) %}",
" <tr>",
" <td>{{ markerLine({ 'weight': 3, 'color': color })|raw }}</td>",
" <td>{{ markerLine({ 'width': 3, 'color': color })|raw }}</td>",
" <td>{{ i }}V</td>",
" </tr>",
"{% endfor %}",
@ -95,18 +95,18 @@
"{% for i in range(3000, 25000, 2000) %}",
" {% set color = colorInterpolate([ 'blue', 'red' ], (i - 1000) / 24000) %}",
" <tr>",
" <td>{{ markerLine({ 'weight': 3, 'color': color })|raw }}</td>",
" <td>{{ markerLine({ 'width': 3, 'color': color })|raw }}</td>",
" <td>{{ i }}V</td>",
" </tr>",
"{% endfor %}",
"",
" <tr>",
" <td>{{ markerLine({ 'weight': 3, 'color': color })|raw }}</td>",
" <td>{{ markerLine({ 'width': 3, 'color': color })|raw }}</td>",
" <td>{{ trans('direct current') }}</td>",
" </tr>",
"",
" <tr>",
" <td>{{ markerLine({ 'styles': [ 'casing', 'default' ], 'style:casing': { 'weight': 3, 'color': 'white' }, 'style': { 'weight': '3', 'dashArray': '5,2', 'lineCap': 'butt', 'color': color } })|raw }}</td>",
" <td>{{ markerLine({ 'styles': [ 'casing', 'default' ], 'style:casing': { 'width': 3, 'color': 'white' }, 'style': { 'width': '3', 'dashArray': '5,2', 'lineCap': 'butt', 'color': color } })|raw }}</td>",
" <td>{{ trans('alternating current') }}</td>",
" </tr>",
"</table>"

4
railway-infrastructure.json

@ -60,7 +60,7 @@
],
"styles": "{% if tags.railway == 'narrow_gauge' %}default,casing{% else %}default{% endif %}",
"style": {
"weight": [
"width": [
"{% if tags.service == 'yard' or tags.service == 'siding' or tags.service == 'spur' or tags.service == 'crossover' %}",
"1",
"{% else %}",
@ -106,7 +106,7 @@
]
},
"style:casing": {
"weight": "{% 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 %}",
"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 %}",
"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 %}",
"lineCap": "butt",
"dashArray": "2,4"

2
water.json

@ -57,7 +57,7 @@
"{% endif %}"
],
"style": {
"weight": [
"width": [
"{% if tags.waterway == 'river' %}",
"4",
"{% elseif tags.waterway == 'stream' %}",

Loading…
Cancel
Save