Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 409f4f4

Browse files
author
Dushyant Bhalgami
committed
changes in animation
1 parent 1316157 commit 409f4f4

File tree

3 files changed

+21
-5
lines changed

3 files changed

+21
-5
lines changed

components/FinalistTable.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,8 +267,8 @@ const table = (props) => {
267267
<React.Fragment>
268268
{ largeColumns && f2fLeaderboard && profile.hasOwnProperty('handle') && <div className='handleName animate fadeIn'>&nbsp;
269269
</div> }
270-
<div className='status'>
271-
Awaiting submission
270+
<div className='status animate flash infinite' >
271+
Processing final scores...
272272
</div>
273273
</React.Fragment>
274274
}

next.config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ module.exports = {
22
publicRuntimeConfig: {
33
host: process.env.HOST,
44
pollTimeInterval: process.env.LEADERBOARD_POLL_TIME_INTERVAL || 1000,
5-
leaderboardRevealDelay: process.env.LEADERBOARD_REVEAL_DELAY || 500,
6-
processDevRevealDelay: process.env.DEV_LEADERBOARD_REVEAL_DELAY || 7000
5+
leaderboardRevealDelay: process.env.LEADERBOARD_REVEAL_DELAY || 2000,
6+
processDevRevealDelay: process.env.DEV_LEADERBOARD_REVEAL_DELAY || 5000
77
}
88
}

pages/f2f-leaderboard.js

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,11 +125,25 @@ class F2FLeaderboard extends React.Component {
125125
.then((leaderboard) => {
126126
if (this.props.isF2f) {
127127
leaderboard.sort((a, b) => (b.points - a.points))
128+
129+
console.log(leaderboard)
128130

129131
if (this.props.showFinalScore) {
132+
// // First, take a break and build the excitement
133+
// leaderboard = leaderboard.map((l, i) => {
134+
// const member = {
135+
// handle: i,
136+
// status: 'Processing final scores...',
137+
// statusAnimationClass: 'animate flash infinite',
138+
// animationClass: 'hidden'
139+
// }
140+
// return member
141+
// })
142+
130143
leaderboard.forEach(l => { l.reveal = false })
131144
this.setState({ leaderboard })
132-
this.animateLeaderboard()
145+
this.polling = setTimeout(this.animateLeaderboard, publicRuntimeConfig.processDevRevealDelay)
146+
// this.animateLeaderboard()
133147
} else {
134148
leaderboard.forEach(l => { l.reveal = true })
135149
this.setState({ leaderboard })
@@ -177,6 +191,8 @@ class F2FLeaderboard extends React.Component {
177191

178192
this.setState({ leaderboard })
179193

194+
console.log(publicRuntimeConfig)
195+
180196
// Show time !!
181197
this.polling = setTimeout(this.displayFinalScores, publicRuntimeConfig.processDevRevealDelay)
182198
} else {

0 commit comments

Comments
 (0)