fix: skip save during initial handleScrollFocus call
Wrap the initial handleScrollFocus call with isInitializing flag to prevent handleScrollSave from incorrectly updating selected_task_id
This commit is contained in:
parent
fd92c6fe96
commit
14ebbda585
@ -162,8 +162,10 @@ function initScrollFocus() {
|
||||
scrollView.addEventListener("scroll", handleScrollFocus);
|
||||
scrollView.addEventListener("scroll", handleScrollSave);
|
||||
|
||||
// Initial call to set in-focus class
|
||||
// Initial call to set in-focus class (skip saving during init)
|
||||
isInitializing = true;
|
||||
handleScrollFocus();
|
||||
isInitializing = false;
|
||||
}
|
||||
|
||||
function handleScrollFocus() {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user