Hotfix infinite scroll (need to apply a real fix)
This commit is contained in:
parent
ee4c13a91b
commit
2faa2c26d3
@ -184,9 +184,9 @@ export class TransactionsListComponent implements OnInit, OnChanges {
|
|||||||
onScroll(): void {
|
onScroll(): void {
|
||||||
const scrollHeight = document.body.scrollHeight;
|
const scrollHeight = document.body.scrollHeight;
|
||||||
const scrollTop = document.documentElement.scrollTop;
|
const scrollTop = document.documentElement.scrollTop;
|
||||||
if (scrollHeight > 0){
|
if (scrollHeight > 0) {
|
||||||
const percentageScrolled = scrollTop * 100 / scrollHeight;
|
const percentageScrolled = scrollTop * 100 / scrollHeight;
|
||||||
if (percentageScrolled > 70){
|
if (percentageScrolled > 50) {
|
||||||
this.loadMore.emit();
|
this.loadMore.emit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user