about summary refs log tree commit diff
path: root/app/javascript/flavours/glitch/features/notifications/components/notification.js
diff options
context:
space:
mode:
authorThibaut Girka <thib@sitedethib.com>2018-04-15 21:29:03 +0200
committerThibaut Girka <thib@sitedethib.com>2018-04-19 11:30:42 +0200
commit694337d9bbaa2505f659d9b9980d393bd317679a (patch)
tree346f1041851d60cbd3ec1e0286600892756c63d9 /app/javascript/flavours/glitch/features/notifications/components/notification.js
parent931a4d1ebf24c3f2b92782f2ee26558ead866f16 (diff)
Fix auto-collapsed toots making the TL jump (fixes #417)
Diffstat (limited to 'app/javascript/flavours/glitch/features/notifications/components/notification.js')
-rw-r--r--app/javascript/flavours/glitch/features/notifications/components/notification.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/app/javascript/flavours/glitch/features/notifications/components/notification.js b/app/javascript/flavours/glitch/features/notifications/components/notification.js
index cc77426d3..6fc7173ed 100644
--- a/app/javascript/flavours/glitch/features/notifications/components/notification.js
+++ b/app/javascript/flavours/glitch/features/notifications/components/notification.js
@@ -16,6 +16,8 @@ export default class Notification extends ImmutablePureComponent {
     onMoveUp: PropTypes.func.isRequired,
     onMoveDown: PropTypes.func.isRequired,
     onMention: PropTypes.func.isRequired,
+    getScrollPosition: PropTypes.func,
+    updateScrollBottom: PropTypes.func,
   };
 
   render () {
@@ -25,6 +27,8 @@ export default class Notification extends ImmutablePureComponent {
       onMoveDown,
       onMoveUp,
       onMention,
+      getScrollPosition,
+      updateScrollBottom,
     } = this.props;
 
     switch(notification.get('type')) {
@@ -50,6 +54,8 @@ export default class Notification extends ImmutablePureComponent {
           onMoveDown={onMoveDown}
           onMoveUp={onMoveUp}
           onMention={onMention}
+          getScrollPosition={getScrollPosition}
+          updateScrollBottom={updateScrollBottom}
           withDismiss
         />
       );
@@ -66,6 +72,8 @@ export default class Notification extends ImmutablePureComponent {
           onMoveDown={onMoveDown}
           onMoveUp={onMoveUp}
           onMention={onMention}
+          getScrollPosition={getScrollPosition}
+          updateScrollBottom={updateScrollBottom}
           withDismiss
         />
       );
@@ -82,6 +90,8 @@ export default class Notification extends ImmutablePureComponent {
           onMoveDown={onMoveDown}
           onMoveUp={onMoveUp}
           onMention={onMention}
+          getScrollPosition={getScrollPosition}
+          updateScrollBottom={updateScrollBottom}
           withDismiss
         />
       );