Skip to content
This repository has been archived by the owner on Feb 17, 2021. It is now read-only.

Fix scroll animation callback called twice #255 #286

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/js/hopscotch.js
Original file line number Diff line number Diff line change
Expand Up @@ -1464,7 +1464,7 @@

// Use jQuery if it exists
else if (hasJquery) {
jQuery('body, html').animate({ scrollTop: scrollToVal }, getOption('scrollDuration'), cb);
jQuery('body').animate({ scrollTop: scrollToVal }, getOption('scrollDuration'), cb);
}

// Use my crummy setInterval scroll solution if we're using plain, vanilla Javascript.
Expand Down Expand Up @@ -2435,4 +2435,4 @@

return winHopscotch;

})));
})));