fixed a bug where smooth scroll would cause the lines to jump after restarting

This commit is contained in:
Jack 2020-08-07 17:15:53 +01:00
parent 311f70ac4f
commit 644b292d4b

View file

@ -3289,7 +3289,7 @@ $(document).keypress(function (event) {
// console.time("offcheck1");
let newActiveTop = document.querySelector("#words .word.active").offsetTop;
if (activeWordTopBeforeJump != newActiveTop && !lineTransition) {
if (activeWordTopBeforeJump < newActiveTop && !lineTransition) {
activeWordJumped = true;
} else {
activeWordJumped = false;