Commit d199378b authored by Volker Krause's avatar Volker Krause
Browse files

Use geo: URIs to open locations on a map rather than hardcoded OSM URLs

parent e53fde3c
Pipeline #133069 passed with stage
in 15 minutes and 54 seconds
{% if location.geo.isValid %}
<div style="display:inline-block;vertical-align:middle;">
<a href="https://www.openstreetmap.org/#map={% if location.className == "Airport" %}13{% else %}17{% endif %}/{{ location.geo.latitude }}/{{ location.geo.longitude }}">
<a href="geo:{{ location.geo.latitude }},{{ location.geo.longitude }}?z={% if location.className == "Airport" %}13{% else %}17{% endif %}">
{% icon "map-symbolic" small _("Show location on map") %}
</a>
</div>
{% elif location.address.addressLocality or location.address.streetAddress %}
<div style="display:inline-block;vertical-align:middle;">
<a href="https://www.openstreetmap.org/search?query={{ location.address.streetAddress }},{{ location.address.postalCode }} {{ location.address.addressLocality }},{{ location.address.addressCountry }}">
<a href="{{ location.geoUri }}">
{% icon "map-symbolic" small _("Search address on map") %}
</a>
</div>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment