summaryrefslogtreecommitdiffstats
path: root/web/react/components/posts_view.jsx
diff options
context:
space:
mode:
Diffstat (limited to 'web/react/components/posts_view.jsx')
-rw-r--r--web/react/components/posts_view.jsx3
1 files changed, 2 insertions, 1 deletions
diff --git a/web/react/components/posts_view.jsx b/web/react/components/posts_view.jsx
index b7ac92672..cc4f5e138 100644
--- a/web/react/components/posts_view.jsx
+++ b/web/react/components/posts_view.jsx
@@ -233,7 +233,8 @@ export default class PostsView extends React.Component {
window.requestAnimationFrame(() => {
// If separator exists scroll to it. Otherwise scroll to bottom.
if (this.refs.newMessageSeparator) {
- this.refs.newMessageSeparator.scrollIntoView();
+ var objDiv = this.refs.postlist;
+ objDiv.scrollTop = this.refs.newMessageSeparator.offsetTop; //scrolls node to top of Div
} else {
this.refs.postlist.scrollTop = this.refs.postlist.scrollHeight;
}