publiclab / leaflet-blurred-location

A Leaflet-based interface for selecting a "blurred" or low-resolution location, to preserve privacy

Home Page:https://publiclab.github.io/leaflet-blurred-location/examples/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Various interactions can result in incorrect location

jywarren opened this issue · comments

This needs to be broken out further, but is mostly due to hard-to-predict user interface sequences. One example is:

  1. open the demo:
  2. enter 577 somerville ave and click enter
  3. pan slightly, moving the map center but not changing the "box" that's highlighted
  4. turn off "blur my location" with the checkbox
  5. zoom in by double clicking 5 times or so but not exactly on the marker

So, this sequence, at steps 3 and 5, drifts off the original location, but that might not be apparent to a new user of this tool. "577 Somerville Ave" is still displayed.

There are probably other similar sequences that could cause confusion.

What can we do?

1. [ ] Reverse geocode while you drag - display textual location like "Buffalo, NY" when you pan the map over that city, using getPlacenameFromCoordinates() -- making an issue for this. That'll help a bit.

UPDATE: reverse geocoding already exists? Why isn't it working in this scenario?

OK -- reverse geocoding DOES work. It's more subtle than that.

  1. open the demo
  2. begin dragging the map, see the bottom location box fill

But then break it:

  1. type "germany" into the top input
  2. pan again, and the bottom remains "Germany"

Originally this was to ensure that the placename entered above "takes precedence" over any panning.

I think we need a different rule. Once we have a conflict -- if the map location no longer corresponds to the text location, because we:

  1. searched by text
  2. then panned

THEN we should display a notice below the map that says The map has moved away from the location you searched for. Want to _re-center on the original location_ or _update the textual description_?

With two links offering to do that with geocoding or reverse geocoding with our API.

@ebarry @mridulnagpal how does that sound? This was pretty subtle but i think this may cover a lot of possible confusing sequences!

Hi Liz, this seems like an unrelated issue, actually -- would you mind opening a new issue with this? Thank you!

@jywarren Currently it would simply take in the location from lat,lng and display it. For recenter display, we need some bounds. For instance if I search New York, after what displacement should it show recenter display? #129

@jywarren Is this still an issue?

This is done!