[Glitch] Fix scroll position in thread view reseting when closing a modal
Port 9d1c3d06783b9f7707e7e57d3d75553a02e8a9f5 to glitch-soc Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
parent
3735e6f79d
commit
99c72830bc
@ -653,7 +653,7 @@ class Status extends ImmutablePureComponent {
|
|||||||
|
|
||||||
shouldUpdateScroll = (prevRouterProps, { location }) => {
|
shouldUpdateScroll = (prevRouterProps, { location }) => {
|
||||||
// Do not change scroll when opening a modal
|
// Do not change scroll when opening a modal
|
||||||
if (location.state?.mastodonModalKey && location.state?.mastodonModalKey !== prevRouterProps?.location?.state?.mastodonModalKey) {
|
if (location.state?.mastodonModalKey !== prevRouterProps?.location?.state?.mastodonModalKey) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user