aboutsummaryrefslogtreecommitdiff
path: root/ext/mixed/js/display.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/mixed/js/display.js')
-rw-r--r--ext/mixed/js/display.js6
1 files changed, 3 insertions, 3 deletions
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;