[stable16] Fix window scroll container (#16016)

[stable16] Fix window scroll container
This commit is contained in:
John Molakvoæ 2019-06-21 10:29:30 +02:00 committed by GitHub
commit 5055d63f37
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -3525,9 +3525,9 @@
var _this = this;
var $scrollContainer = this.$container;
if ($scrollContainer[0] === window) {
// need to use "body" to animate scrolling
// need to use "html" to animate scrolling
// when the scroll container is the window
$scrollContainer = $('body');
$scrollContainer = $('html');
}
$scrollContainer.animate({
// Scrolling to the top of the new element