ConnectedHumber / Air-Quality-Web

The web interface and JSON api for the ConnectedHumber Air Quality Monitoring Project.
https://sensors.connectedhumber.org/
Mozilla Public License 2.0
9 stars 4 forks source link

When clicking sensors on the AQ Map (sometimes) the map just zooms #50

Closed BNNorman closed 4 years ago

BNNorman commented 4 years ago

I'm seeing this clicking on sensors marker and it appears intermittent or has a mind of it's own.

It's almost like the API thinks I've double-clicked the background.

Perhaps this is a default action or an unintended fall through in a case statement? The default should be do nothing if within a given radius of a marker since the user intended to click the marker but may have missed by a pixel or two.

sbrl commented 4 years ago

Hrm, this is a tricky one. It's likely to have something to do with the events in leaflet. The documentation details a few options that we can play around with.

I'm not entirely sure how to go about tackling this one. For me, it only zooms if I double-click. It's worth noting that even a significant delay of ~0.4s can result in a double click in my testing - this is a browser and operating system-specific setting that we don't have much control over as far as I know, unfortunately.

BNNorman commented 4 years ago

Hmm. I take your point.

sbrl commented 4 years ago

I'd be interested to know if this happens on multiple computers for you. Perhaps we can gain some more information that way.

BNNorman commented 4 years ago

Ok, i was using firefox. On my tablet it doesnt appear to do it with the silk browser. Ill try some other browsers later, been out all day.

BNNorman commented 4 years ago

Tried to repeat with firefox on PC - won't do it now so it's calling me a liar and I'll close the issue.