From 218db0771fae0754a50cadc1891a042112b58699 Mon Sep 17 00:00:00 2001 From: Alex Yatskov Date: Sat, 25 Mar 2017 16:45:43 -0700 Subject: cleanup, firefox scrolling --- ext/mixed/js/display.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'ext/mixed') diff --git a/ext/mixed/js/display.js b/ext/mixed/js/display.js index 140185cc..50940e58 100644 --- a/ext/mixed/js/display.js +++ b/ext/mixed/js/display.js @@ -149,14 +149,14 @@ class Display { $('.current').hide().eq(index).show(); - const body = $('body').stop(); + const container = $('html,body').stop(); const entry = $('.entry').eq(index); const target = index === 0 ? 0 : entry.offset().top; if (smooth) { - body.animate({scrollTop: target}, 200); + container.animate({scrollTop: target}, 200); } else { - body.scrollTop(target); + container.scrollTop(target); } this.index = index; -- cgit v1.2.3