element-hq / element-hq/element-web

Audio files cause scroll jumps

Open
#22,221 0 comments 0 reactions 0 assignees View on GitHub
A-Media A-Timeline A-Timeline-Jumpy-Scroll O-Occasional S-Minor T-Defect
Dominant language
TypeScript
Stars
13.5k
Forks
2.8k
PR merge metrics
PR metrics pending

Description

### Steps to reproduce

1. Send or receive an audio file
2. Switch out of and back into the room a few times to observe the timeline being loaded

### Outcome

#### What did you expect?

The audio file's tile should maintain a consistent height before and after loading to avoid causing a scroll jump.

#### What happened instead?

The audio file shows only a small spinner for a couple of seconds, and then the actual final tile 'pops' into the timeline, causing a layout shift. If this were in the scrollback of a room, you'd get scroll jumps when navigating through history.

https://user-images.githubusercontent.com/48614497/168617859-a3737f5e-ec2c-4737-845a-34bc563b6dba.mp4

### Operating system

NixOS unstable

### Browser information

Firefox 100.0

### URL for webapp

develop.element.io

### Application version

Element version: f080b1fb273e-react-fcc4d62edee7-js-f44510e65f9b Olm version: 3.2.8

### Homeserver

Synapse 1.58.0

### Will you send logs?

No

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.