Update taskList.js
- fixed overlap issue - fixed scrolling issue
This commit is contained in:
parent
ffc9a983d0
commit
b0ad867e6b
1 changed files with 7 additions and 1 deletions
|
|
@ -609,6 +609,11 @@ function clearAllExceptStreamer(streamer) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function renderTaskListToDOM() {
|
function renderTaskListToDOM() {
|
||||||
|
if (scrolling) {
|
||||||
|
checkToAnimate();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const tasks = JSON.parse(localStorage.tasks);
|
const tasks = JSON.parse(localStorage.tasks);
|
||||||
|
|
||||||
const taskContainers = document.querySelectorAll(".task-container");
|
const taskContainers = document.querySelectorAll(".task-container");
|
||||||
|
|
@ -751,9 +756,10 @@ async function checkToAnimate() {
|
||||||
await sleep(scrollingSpeed);
|
await sleep(scrollingSpeed);
|
||||||
|
|
||||||
scrolling = false;
|
scrolling = false;
|
||||||
|
renderTaskListToDOM();
|
||||||
checkToAnimate();
|
checkToAnimate();
|
||||||
}
|
}
|
||||||
} else if (scrolling) {
|
} else if (!scrolling) {
|
||||||
document.querySelector(".secondary").style.display = "none";
|
document.querySelector(".secondary").style.display = "none";
|
||||||
|
|
||||||
// cancel animations
|
// cancel animations
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue