fix: MkPullToRefresh not work

This commit is contained in:
Lhcfl 2024-04-27 20:25:49 +08:00
parent cc560811cf
commit fe1efed369
2 changed files with 3 additions and 1 deletions

View file

@ -242,6 +242,8 @@ const reload = (): Promise<void> => {
appended.value = [];
prepended.value = [];
idMap.clear();
offset.value = 0;
nextPagingBy = {};
return init();
};

View file

@ -203,7 +203,7 @@ function unregisterEventListenersForReadyToPull() {
onMounted(() => {
if (rootEl.value == null) return;
scrollEl = getScrollContainer(rootEl.value);
scrollEl = getScrollContainer(rootEl.value) ?? document.querySelector("HTML");
if (scrollEl == null) return;
scrollEl.addEventListener("scroll", onScrollContainerScroll, {