summaryrefslogtreecommitdiffstats
path: root/web/react/components/rhs_thread.jsx
diff options
context:
space:
mode:
authorStas Vovk <stas@vovk.me>2015-10-16 14:21:51 +0300
committerStas Vovk <stas@vovk.me>2015-10-16 14:21:51 +0300
commit79fcb9808421dd93342a9538d05dd2259f5dd14b (patch)
tree33a1a865144f280e37fde07a7c91ed8825c53801 /web/react/components/rhs_thread.jsx
parent2bd81ff379acb347534e4d6a1a27624e0262deb0 (diff)
parent50a8e2bd4fa53c6bb2f12a03237be4fbaf259617 (diff)
downloadchat-79fcb9808421dd93342a9538d05dd2259f5dd14b.tar.gz
chat-79fcb9808421dd93342a9538d05dd2259f5dd14b.tar.bz2
chat-79fcb9808421dd93342a9538d05dd2259f5dd14b.zip
Merge remote-tracking branch 'upstream/master' into PLT-637
Conflicts: web/react/utils/constants.jsx
Diffstat (limited to 'web/react/components/rhs_thread.jsx')
-rw-r--r--web/react/components/rhs_thread.jsx8
1 files changed, 4 insertions, 4 deletions
diff --git a/web/react/components/rhs_thread.jsx b/web/react/components/rhs_thread.jsx
index 748cb16a8..467d74681 100644
--- a/web/react/components/rhs_thread.jsx
+++ b/web/react/components/rhs_thread.jsx
@@ -55,8 +55,6 @@ export default class RhsThread extends React.Component {
if ($('.post-right__scroll')[0]) {
$('.post-right__scroll').scrollTop($('.post-right__scroll')[0].scrollHeight);
}
-
- $('.post-right__scroll').perfectScrollbar('update');
this.resize();
}
componentWillUnmount() {
@@ -113,8 +111,10 @@ export default class RhsThread extends React.Component {
var height = $(window).height() - $('#error_bar').outerHeight() - 100;
$('.post-right__scroll').css('height', height + 'px');
$('.post-right__scroll').scrollTop(100000);
- $('.post-right__scroll').perfectScrollbar();
- $('.post-right__scroll').perfectScrollbar('update');
+ if ($(window).width() > 768) {
+ $('.post-right__scroll').perfectScrollbar();
+ $('.post-right__scroll').perfectScrollbar('update');
+ }
}
render() {
var postList = this.state.postList;