]> git.openstreetmap.org Git - rails.git/commit
Build export download links from locale keys (#7271)
authorLee Kindness <lee@leekindness.com>
Tue, 4 Aug 2026 06:21:34 +0000 (07:21 +0100)
committerGitHub <noreply@github.com>
Tue, 4 Aug 2026 06:21:34 +0000 (08:21 +0200)
commit2bde4911ce4f47712579a5f51b3c0ea626b47ff1
tree3920ea680ce8240459845de033dc734e547d83c4
parent9436c698921b387546033fcd15bca68af7ed150a
Build export download links from locale keys (#7271)

The four bulk download links on the export page had their URLs
hardcoded in the view, with the Overpass one spelt out a second
time in export.js so the bbox could be appended on each map move.

Follow the pattern already used by the help page and drive the list
from locale keys, adding a URL key alongside the existing title and
description for each source. This removes the duplication between
the view and the JS, and allows the URLs to be localised or pointed
elsewhere by deployments that are not openstreetmap.org.

export.js no longer needs to know the Overpass URL: it sets the
search component of the link's existing href rather than rebuilding
the whole thing.

The wiki link now points to Downloading_data, the target of the
redirect that the previous /wiki/Download URL followed.

settings.overpass_url is deliberately untouched: it is the query
server's interpreter endpoint, a separate concern from the export
download link.
app/assets/javascripts/index_modules/export.js
app/views/site/export.html.erb
config/locales/en.yml
test/controllers/site_controller_test.rb