brouter-web icon indicating copy to clipboard operation
brouter-web copied to clipboard

Provide "Open in OpenStreetMap" button regardless of current tiles layer

Open sjakobi opened this issue 2 years ago • 4 comments
trafficstars

I'm used to use brouter-web with the tiles from OpenStreetMap.de. Unfortunately this deprives me of quick access to the the same map view on openstreetmap.org.

In this mode, I only get a button for "OpenStreetMap.de" which links to https://openstreetmap.de/karte/:

image

This link isn't very helpful though:

  • It doesn't show the same section of the map.
  • It doesn't give access to object queries and other useful features of openstreetmap.org.

Therefore I'd like to request some way to access the same map section on openstreetmap.org, that works independently of the current tiles layer.

sjakobi avatar Aug 21 '23 10:08 sjakobi

The following isn't the solution, but a suggestion for an ever better workflow:

What you see there is only the attribution information for the currently selected map.

There's a powerful browser extension called “OSM Smart Menu” which allows navigating between different map products with a single click and works, of course, from BRouter-Web instances. It's available for Firefox and Chromium-based Browsers.

Navigating between map products:

image

Directly jump to details for a given OSM element:

image

Jump to tools for inspecting a change set:

image

mjaschen avatar Aug 21 '23 11:08 mjaschen

OMG, that extension is great! :star_struck:

Feel free to close this issue.

sjakobi avatar Aug 21 '23 12:08 sjakobi

To save people from searching, documentation for OSM Smart Menu, with links to plugins, can be found at https://wiki.openstreetmap.org/wiki/OSM_Smart_Menu

Source code at https://github.com/jgpacker/osm-smart-menu

pbb72 avatar Aug 21 '23 13:08 pbb72

I've had the exact same issue since ages, but only with CyclOSM. I solved it this way:

  • Change the mapUrl in the respective .geojson file (note that for CyclOSM you'll actually need to edit layers/config/overrides.js). This will allow to quickly switch to https://osm.org at the correct location.
  • Later, I also added a click-to-query function by adding an Overpass query for way[highway]; and hacking its attributes (hide via opacity=0, increase click area via width=20). Unfortunately, this prevents adding new via markers.

You could also redirect links from openstreetmap.de to osm.org originating from your chosen BRouter-Web instance with a browser plugin. It's one less click than the tip by @mjaschen, although admittedly much less powerful. I'd recommend Request Control, which is quite nifty: You can also remove tracking GET parameters from email links, Google searches, YouTube videos and others, use old.reddit.com, redirect to Invidious etc.


As for the request in the title, I'd be hesitant to add yet another button for niche use cases if we can avoid it. You should open an issue with individual maps if they don't respect the location parameters or fix our map .geojson files if it turns out we use the wrong ones. That's better than adding workarounds everywhere and it will fix it for everyone.

Regarding the click-to-query feature, I'd encourage you to open another issue for that here. I'd really love to have that, ideally without having to click (e.g. in QLandkarte which I'm still using for that reason it works continuously on mouse-over, sadly QMapShack switched it to wait-for-hover-timeout). A low-latency and non-hacky implementation seems quite difficult with Overpass, though. It might be more feasible to explore a vector tile approach (provide MVT tiles with the respective data, use for queries, supply "invisible" map style).

Feel free to close this issue.

Only the maintainer and you have that power, so feel free to press that button yourself.

rkflx avatar Aug 21 '23 14:08 rkflx