Merge pull request #3557 from mempool/nymkappa/hotfix-infinite-scroll

Hotfix infinite scroll (need to apply a real fix for 2.5.1)
This commit is contained in:
wiz 2023-03-23 17:36:08 +09:00 committed by GitHub
commit 6180837636
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -184,9 +184,9 @@ export class TransactionsListComponent implements OnInit, OnChanges {
onScroll(): void {
const scrollHeight = document.body.scrollHeight;
const scrollTop = document.documentElement.scrollTop;
if (scrollHeight > 0){
if (scrollHeight > 0) {
const percentageScrolled = scrollTop * 100 / scrollHeight;
if (percentageScrolled > 70){
if (percentageScrolled > 50) {
this.loadMore.emit();
}
}