mapbox.js icon indicating copy to clipboard operation
mapbox.js copied to clipboard

Tiles need to update on range slider action

Open peterqliu opened this issue 10 years ago • 14 comments

From the demo:

range slider

They do update when I zoom, of course, but I also need it when the slider moves, to maintain the desired illusion.

peterqliu avatar Nov 11 '14 00:11 peterqliu

Just ran into a similar issue with the slider while building an Atlas demo, though I'm only seeing intermittent updates when I zoom. I'm running Chrome on Yosemite, and the issue is replicable whether hitting the Mapbox.com API w/ online mapids or the Atlas API with offline mapids.

brokenfade

@mourner this old issue is the only thing I found referencing trouble with the Leaflet slider. Any sense of what @peterqliu and I are encountering?

mtirwin avatar Nov 22 '14 02:11 mtirwin

@mtirwin @peterqliu what are your browsers? The mapbox.js example is working fine for me in Chrome & Firefox under OS X.

mourner avatar Nov 23 '14 17:11 mourner

@mourner, I'm using Chrome version 38.0.2125.122 (current) on OSX Yosemite. The issue doesn't replicate on Safari.

mtirwin avatar Nov 23 '14 18:11 mtirwin

OK, managed to reproduce this, although it's happening sporadically... My guess is that it's a Chrome bug.

mourner avatar Nov 23 '14 18:11 mourner

@mourner yes, I just updated my Chrome and the problem disappeared for me. Should we close?

peterqliu avatar Nov 23 '14 21:11 peterqliu

Yeah, lets close — should go away with a Chrome update hopefully.

mourner avatar Nov 24 '14 13:11 mourner

FWIW, this is still happening for me in latest Chrome (38.0.2125.122).

jfirebaugh avatar Nov 24 '14 18:11 jfirebaugh

Yup, I'm seeing it again-- seems entirely sporadic. Reopened.

peterqliu avatar Nov 24 '14 18:11 peterqliu

@peterqliu Can you make a self contained example and submit an issue on https://code.google.com/p/chromium/issues/list?

jfirebaugh avatar Nov 24 '14 22:11 jfirebaugh

@peterqliu did you submit an issue on Chromium? Noticing our slider's still broken on the latest version of Chrome (39.0.2171.95).

mtirwin avatar Jan 08 '15 22:01 mtirwin

@mtirwin I actually haven't submitted (my bad), but the bug has disappeared for me again. Would you mind submitting, since you are still experiencing this?

peterqliu avatar Jan 08 '15 22:01 peterqliu

I confirm this bug on Mac OSX, Chrome version 43.0.2357.124 (64-bit)

lxbarth avatar Jul 10 '15 20:07 lxbarth

@peterqliu Can you make a self contained example and submit an issue on https://code.google.com/p/chromium/issues/list?

@peterqliu - would love to see this happen. Here's an animated gif from my 43.0.2357.124

swipe

lxbarth avatar Jul 10 '15 20:07 lxbarth

I filed a bug w/ the Chrome project: https://code.google.com/p/chromium/issues/detail?id=509126&thanks=509126&ts=1436570972

The issue is that setting the clip style attribute does not force a repaint. Not sure why this only occurs after zooming once.

And here is a workaround that fixes the issue for me on Chrome 43.0.2357.132 (64-bit) (from stackoverflow #3485365):

elem.style.display='none';
elem.offsetHeight;
elem.style.display='';

Workaround in action: http://bl.ocks.org/lxbarth/bcd0d1ab3c69085e2dad

@tmcw - worthwhile getting the workaround into the example code?

lxbarth avatar Jul 10 '15 23:07 lxbarth