mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-06-23 19:08:26 +00:00
Add a load-more button to item list
This commit is contained in:
@ -30,3 +30,18 @@ elmApp.ports.setAllProgress.subscribe(function(input) {
|
||||
$("."+id).progress({percent: percent});
|
||||
}, 100);
|
||||
});
|
||||
|
||||
elmApp.ports.scrollToElem.subscribe(function(id) {
|
||||
if (id && id != "") {
|
||||
window.setTimeout(function() {
|
||||
var el = document.getElementById(id);
|
||||
if (el) {
|
||||
if (el["scrollIntoViewIfNeeded"]) {
|
||||
el.scrollIntoViewIfNeeded();
|
||||
} else {
|
||||
el.scrollIntoView();
|
||||
}
|
||||
}
|
||||
}, 20);
|
||||
}
|
||||
});
|
||||
|
Reference in New Issue
Block a user