Images without metadata about their dimensions cause scroll jumps #22222
Labels
A-Media
A-Timeline
A-Timeline-Jumpy-Scroll
Stable timeline dream ✨
O-Uncommon
Most users are unlikely to come across this or unexpected workflow
S-Minor
Impairs non-critical functionality or suitable workarounds exist
T-Defect
Z-Chronic
Steps to reproduce
info
field) (some bridges do this)Outcome
What did you expect?
The tile should maintain a consistent size before and after loading to avoid scroll jumps. Element Android achieves this by giving the image an arbitrary constant height, though we could also consider somehow preloading the image before paginating the event into our ScrollPanel.
What happened instead?
Because there's no way to know what dimensions the image will have before loading, it causes a layout shift. If this happens in the scrollback of a room, it will cause scroll jumps when navigating through history.
Operating system
NixOS unstable
Browser information
Firefox 100.0
URL for webapp
develop.element.io
Application version
Element version: 6c87e29-react-fcc4d62edee7-js-f44510e65f9b Olm version: 3.2.8
Homeserver
Synapse 1.58.0
Will you send logs?
No
The text was updated successfully, but these errors were encountered: