[openstreetmap/openstreetmap-website] use JOSM/tag2link to linkify tag values (PR #6197)

Kyℓe Hensel notifications at github.com
Tue Jul 15 08:43:18 UTC 2025


Closes #986, Closes #2405, Closes #3920, Closes #5200, Partially closes openstreetmap/iD#11120, Partially closes openstreetmap/iD#9510

This supersedes #2621. cc @francois2metz and @pyrog from the old PR

### Description

OSM keys like [`mapillary`](https://osm.wiki/Key:mapillary) are now rendered as a clickable link:

<img width="200" src="https://github.com/user-attachments/assets/434df4da-76c8-40c5-a089-f2545d744d97" />

This uses the data aggregated by [JOSM/tag2link](https://github.com/JOSM/tag2link), as [suggested](https://github.com/openstreetmap/openstreetmap-website/pull/2621#issuecomment-2660925603) by Tom, so the logic in this repo is significantly simpler than #2621. It works with semicolons and full URLs in the tag value.


### How has this been tested?
Unit tests and locally with docker

You can view, comment on, or merge this pull request online at:

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

-- Commit Summary --

  * use JOSM/tag2link to linkify tag values

-- File Changes --

    M app/helpers/browse_tags_helper.rb (11)
    A config/initializers/tag2link.rb (24)
    M package.json (3)
    M test/helpers/browse_tags_helper_test.rb (4)
    M yarn.lock (5)

-- Patch Links --

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

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

Message ID: <openstreetmap/openstreetmap-website/pull/6197 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250715/2854eec3/attachment.htm>


More information about the rails-dev mailing list