[openstreetmap/openstreetmap-website] Add permalinks to changeset comments (PR #4789)
Anton Khorev
notifications at github.com
Thu Jul 18 15:13:47 UTC 2024
@AntonKhorev commented on this pull request.
> @@ -33,7 +33,7 @@
<li id="c<%= comment.id %>">
<small class='text-muted'>
<%= t comment.visible ? ".comment_by_html" : ".hidden_comment_by_html",
- :time_ago => friendly_date_ago(comment.created_at),
+ :time_ago => link_to(friendly_date_ago(comment.created_at), "https://www.openstreetmap.org/changeset/#{@changeset.id}##{comment.id}"),
Url fragments are incorrect. They are `#c#{comment.id}`, not `##{comment.id}`.
```suggestion
:time_ago => link_to(friendly_date_ago(comment.created_at), :anchor => "c#{comment.id}"),
```
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/4789#discussion_r1683029330
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/pull/4789/review/2186148622 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20240718/cad60b25/attachment.htm>
More information about the rails-dev
mailing list