From addfddd3ac0342497e6215373eb773c0903fdf0f Mon Sep 17 00:00:00 2001 From: hippoz <10706925-hippoz@users.noreply.gitlab.com> Date: Wed, 20 Apr 2022 17:53:20 +0300 Subject: [PATCH] frontend: fix autoscroll breaking message loading --- frontend/src/components/pages/main/Messages.svelte | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/frontend/src/components/pages/main/Messages.svelte b/frontend/src/components/pages/main/Messages.svelte index 212e602..653b45b 100644 --- a/frontend/src/components/pages/main/Messages.svelte +++ b/frontend/src/components/pages/main/Messages.svelte @@ -14,7 +14,7 @@ afterUpdate(() => { if (shouldAutoscroll && scrollTarget) { - scrollTarget.scrollIntoView(); + scrollTarget.scrollTo(0, scrollTarget.scrollHeight); } }); @@ -43,12 +43,11 @@ } -