[openstreetmap/openstreetmap-website] Add links to external map legends (PR #6005)

Anton Khorev notifications at github.com
Mon May 12 09:17:41 UTC 2025


Add links to map legends on external sites:
![image](https://github.com/user-attachments/assets/a7536bb1-c196-414f-87c4-61345964754a)

The key on osm.org may not be complete and maybe it doesn't even make sense to complete it, in case there's a lot of icons. This PR adds links to pages like https://www.cyclosm.org/legend.html.

I don't add `noreferrer` etc because we're already linking to these sites without these properties in map attributions.
You can view, comment on, or merge this pull request online at:

  https://github.com/openstreetmap/openstreetmap-website/pull/6005

-- Commit Summary --

  * Target map key images for filtering by css class
  * Target shown/hidden map key entries by data attributes
  * Move map legend entries definitions into 'entries' properties
  * Add links to external map legends

-- File Changes --

    M app/assets/javascripts/leaflet.key.js (2)
    M app/assets/stylesheets/common.scss (2)
    M app/controllers/map_keys_controller.rb (4)
    M app/views/map_keys/show.html.erb (15)
    M config/key.yml (396)
    M config/locales/en.yml (1)

-- Patch Links --

https://github.com/openstreetmap/openstreetmap-website/pull/6005.patch
https://github.com/openstreetmap/openstreetmap-website/pull/6005.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6005
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/6005 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250512/280619be/attachment.htm>


More information about the rails-dev mailing list