[openstreetmap/openstreetmap-website] Map doesn't zoom to Note if URL contains comment ID (Issue #5596)
Báthory Péter
notifications at github.com
Mon Feb 3 13:45:13 UTC 2025
### URL
https://www.openstreetmap.org/note/4574916#c10050110
### How to reproduce the issue?
If a note link contains comment id in the url hash, the map will not scroll to the note marker.
For example open this link:
https://www.openstreetmap.org/note/4574916#c10050110
Instead of showing the note marker, the map view is set to the last visited location, and the `#c…` id in the url replaced with `#map=…`
### Screenshot(s) or anything else?
It seems when [`moveToNote()`](
https://github.com/openstreetmap/openstreetmap-website/blob/55c1033c704e2187d062421626b3dfe118706c6e/app/assets/javascripts/index/note.js#L107) runs, the hash has already been replaced with `#map=`.
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/5596
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/issues/5596 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250203/d995f3a2/attachment.htm>
More information about the rails-dev
mailing list