Re:A call to minimize distraction and respect users’ attenti...
by epivosism on Wednesday July 07, 2021 @02:17PM
(#27764164)
The enforced ~500ms loading time between slides is a killer. Why not preload and display them immediately?
[ Parent
| on HN ]
Re:A call to minimize distraction and respect users’ attenti...
by anonydsfsfs on Wednesday July 07, 2021 @03:26PM
(#27764858)
There isn't a fixed 500ms loading time. It advances slides by changing the background image of the central "pic" element. This is the JS to advance the slide:
function increment(){
if(imgNum < 141){
imgNum++;
}else{
imgNum = 1;
}
url = "url('img/vrg_google_doc_final_vrs03-"+imgNum+".jpg')";
document.getElementById('pic').style.backgroundImage=url;
}
The reason you see a flicker is because it takes time to load the next image, and until it loads you're going to see the black background. As you mentioned, the preloading images would solve this.
Re:A call to minimize distraction and respect users’ attenti...
by waterhouse on Wednesday July 07, 2021 @05:31PM
(#27765947)
I resorted to holding the up-arrow key to trigger loading of a bunch of slides, then holding down-arrow to get back to where I was, and finally getting a smooth transition experience.
Re:A call to minimize distraction and respect users’ attenti...
by emaro on Wednesday July 07, 2021 @02:18PM
(#27764183)
On mobile, the slides switched instantly. On Firefox Desktop it's like from hell.
Re:A call to minimize distraction and respect users’ attenti...
by epivosism on Wednesday July 07, 2021 @02:27PM
(#27764275)
Weird, how does that work? Is the mobile browser simulating the click and then noticing the next image to be loaded? Maybe the js is simple enough to prove that it's safe to do so, but wow.
Re:A call to minimize distraction and respect users’ attenti...
by leereeves on Wednesday July 07, 2021 @02:57PM
(#27764592)
For me, using Firefox on a Mac, the slides also switched instantly.
Re:A call to minimize distraction and respect users’ attenti...
by neogodless on Wednesday July 07, 2021 @04:07PM
(#27765221)
On Firefox for Windows 10 - instant slide transitions.
Ryzen 7 2700X, 32GB, 300/300 mbps connection.