Skip to content
This repository was archived by the owner on Apr 16, 2026. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions audino/frontend/src/pages/data.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import axios from 'axios';
import React from 'react';
import { Helmet } from 'react-helmet';
import { withRouter } from 'react-router-dom';

import { Button } from '../components/button';
import Loader from '../components/loader';

const datas = [];
Expand Down Expand Up @@ -102,7 +102,7 @@ class Data extends React.Component {
isBottom() {
// https://stackoverflow.com/questions/3898130/check-if-a-user-has-scrolled-to-the-bottom/3898152
const element = document.body;
return element.scrollHeight - element.scrollTop === element.clientHeight;
return element.scrollHeight - element.scrollTop > element.clientHeight * 0.8;
}

prepareUrl(projectId, page, active) {
Expand Down Expand Up @@ -200,7 +200,14 @@ class Data extends React.Component {
}}
>
{nextPage ? (
<Loader />
/*<Button
type="primary"
text="load more data"
onClick={() => {
this.getData(true);
}}
/>*/
<Loader/>
) : (
<text>
<b>End Of Data</b>
Expand Down