Browse Source

Fix scroll-load component

sbkwgh 7 years ago
parent
commit
670c7ae7e4
1 changed files with 1 additions and 1 deletions
  1. 1 1
      frontend/src/components/ScrollLoad.vue

+ 1 - 1
frontend/src/components/ScrollLoad.vue

@@ -16,7 +16,7 @@
 		},
 		methods: {
 			onScroll (e) {
-				if(document.body.scrollHeight - document.body.scrollTop - 300 <= document.body.clientHeight) {
+				if((window.innerHeight + window.pageYOffset) + 300 >= document.body.scrollHeight) {
 					if(!this.loading) {
 						this.$emit('loadNext')
 					}