diff --git a/ElectronClient/app/gui/ItemList.jsx b/ElectronClient/app/gui/ItemList.jsx index a2098830ae..48b390c4e8 100644 --- a/ElectronClient/app/gui/ItemList.jsx +++ b/ElectronClient/app/gui/ItemList.jsx @@ -60,9 +60,11 @@ class ItemList extends React.Component { if (itemIndex < top) { scrollTop = this.props.itemHeight * itemIndex; } else { - scrollTop = this.props.itemHeight * itemIndex - this.visibleItemCount(); + scrollTop = this.props.itemHeight * itemIndex - (this.visibleItemCount() - 1) * this.props.itemHeight; } + if (scrollTop < 0) scrollTop = 0; + this.scrollTop_ = scrollTop; this.listRef.current.scrollTop = scrollTop;