This commit is contained in:
syuilo
2021-02-15 17:17:19 +09:00
parent 80eefa92ce
commit 0336d640ec
7 changed files with 155 additions and 56 deletions

View File

@@ -13,12 +13,10 @@ export default {
const viewHeight = container.clientHeight;
const height = container.scrollHeight;
isBottom = (pos + viewHeight > height - 32);
console.log(isBottom);
}, { passive: true });
container.scrollTop = container.scrollHeight;
const ro = new ResizeObserver((entries, observer) => {
console.log(isBottom);
if (isBottom) {
const height = container.scrollHeight;
container.scrollTop = height;