Skip to content
This repository was archived by the owner on Sep 11, 2024. It is now read-only.

Conversation

dbkr
Copy link
Member

@dbkr dbkr commented Oct 31, 2019

We need to reset the scroll offset otherwise the component may be
scrolled past the only content it has (Chrome just corrected the
scroll offset but Firefox scrolled it anyway).

NB. Introducing the new deriveStateFromProps method seems to
means that react no longer calls componentWillMount so I've
had to change it to componentDidMount (which it should have
been anyway).

Fixes element-hq/element-web#11263

We need to reset the scroll offset otherwise the component may be scrolled past the only content it has (Chrome just corrected the scroll offset but Firefox scrolled it anyway). NB. Introducing the new deriveStateFromProps method seems to means that react no longer calls componentWillMount so I've had to change it to componentDidMount (which it should have been anyway). Fixes element-hq/element-web#11263
@dbkr dbkr requested a review from a team October 31, 2019 19:45
Copy link
Member

@turt2live turt2live left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awkward, but looks like the right thing

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

2 participants