Scroll to bottom on tab change

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
Alex Andreev committed 2022-09-05 13:15:13 +03:00
1 parent c4538e928b
commit 1679ba14e1
1 file changed
+4
@@ -80,6 +80,10 @@ export const LogList = observer(({ model }: LogListProps) => {
}, 200)
}, [model.logTabData.get()?.selectedPodId])
useEffect(() => {
rowVirtualizer.scrollToIndex(visibleLogs.get().length - 1, { align: 'end', smoothScroll: false });
}, [model.logTabData.get()]);
return (
<div
ref={parentRef}