[openstreetmap/openstreetmap-website] Move History and Export buttons to secondary nav (PR #5151)
David Tsiklauri
notifications at github.com
Fri Sep 13 12:32:40 UTC 2024
@nertc commented on this pull request.
> @@ -412,6 +412,9 @@ $(document).ready(function () {
if (OSM.router.route(this.pathname + this.search + this.hash)) {
e.preventDefault();
+ if (this.pathname !== "/directions") {
app\assets\javascripts\index\search.js:13:5 sets "prevent default" to the directions button `e.preventDefault()` and app\assets\javascripts\index.js:399:9 checks if the `<a>` tag is "prevent default" `e.isDefaultPrevented()`. Therefore, returns empty value and never reaches `this.pathname !== "/directions"` if statement.
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/5151#discussion_r1758783672
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/pull/5151/review/2303004640 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20240913/458cd4ce/attachment.htm>
More information about the rails-dev
mailing list