diff --git a/app/soapbox/components/scrollable_list.tsx b/app/soapbox/components/scrollable_list.tsx index caad06dfe7..e546f2a454 100644 --- a/app/soapbox/components/scrollable_list.tsx +++ b/app/soapbox/components/scrollable_list.tsx @@ -170,7 +170,9 @@ const ScrollableList = React.forwardRef(({ }; const handleRangeChange = (range: ListRange) => { - topIndex.current = range.startIndex; + // HACK: using the first index can be buggy. + // Track the second item instead, unless the endIndex comes before it (eg one 1 item in view). + topIndex.current = Math.min(range.startIndex + 1, range.endIndex); handleScroll(); };