[openstreetmap/openstreetmap-website] Set directions starting point to "Show My Location" (PR #5671)
Anton Khorev
notifications at github.com
Thu Feb 13 23:44:42 UTC 2025
Answers the question https://github.com/openstreetmap/openstreetmap-website/pull/5635#issuecomment-2646420820.
If the location was already acquired with *Show My Location*, it is used as a starting location in *Directions* if
- the starting location is empty AND
- no `route` param was provided (this is to support *Reverse Directions*; points are reversed using the `route` parameter; we want to suppress substituting the location when empty value is swapped into the starting point)
If *Show My Location* wasn't activated before opening the *Directions* page, the activation will use the acquired location as soon as it's available, again if the starting location is empty.
You can view, comment on, or merge this pull request online at:
https://github.com/openstreetmap/openstreetmap-website/pull/5671
-- Commit Summary --
* Set directions starting point to "Show My Location"
-- File Changes --
M app/assets/javascripts/index/directions.js (23)
-- Patch Links --
https://github.com/openstreetmap/openstreetmap-website/pull/5671.patch
https://github.com/openstreetmap/openstreetmap-website/pull/5671.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/5671
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/pull/5671 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250213/142c78d9/attachment.htm>
More information about the rails-dev
mailing list