-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
List virtualization and lazy thumbnails #2161
Conversation
Great-great work, Renée! 👍 🥇 Tested in Chrome, Firefox and Safari on Mac, Chrome is the slowest for some reason. Thumbnail generation, even delayed, seems to be the bottleneck — text files render much snappier. |
@lakesare you reviewed this last time and found important bugs, could you take a look again, please? :) |
@arturi, sure, I can review it on Tuesday if it can wait 👌 |
This comment has been minimized.
This comment has been minimized.
thanks for the feedback @lakesare! gonna look into the mobile view issue now, that's not very good 😬 |
This comment has been minimized.
This comment has been minimized.
The `focusout` event could be fired before `componentDidUpdate` is called, and then we'd lose focus anyway, so it basically didn't work. I wanted to avoid `componentWillUpdate` but it seems like the most reliable option right now. I guess it's only discouraged in React proper anyway, and fine in Preact!
2b7bd91
to
d3c1179
Compare
🎉🚀🥇💯🎉🚀🥇💯🎉🚀🥇💯 |
🎉 🎉 🎉 🚀 🚀 🚀 |
This patch changes the Dashboard to only render those files that are actually in view, and to only generate thumbnails for files that are in view.
When a FileItem mounts, a thumbnail is requested. There is a case where you might scroll to one place A, and then scroll to another place B before all the thumbnails were ready. Then, you might have to wait until Uppy has generated thumbnails for the files visible at A before any of the files at B start getting thumbnails. So, if a FileItem unmounts before a thumbnail is generated, we cancel the thumbnail request, which reduces that delay.
Issues: