forked from HoloTech/twitch-subathon-timer
-decimals
- round decimals on leaderboard
This commit is contained in:
6
timer.js
6
timer.js
@@ -314,7 +314,7 @@ class TimerRenderer {
|
|||||||
this.topusers_user1_num.textContent = "1";
|
this.topusers_user1_num.textContent = "1";
|
||||||
this.topusers_user1_name.textContent = users[0].user_name;
|
this.topusers_user1_name.textContent = users[0].user_name;
|
||||||
this.topusers_userdupe1_name.textContent = users[0].user_name;
|
this.topusers_userdupe1_name.textContent = users[0].user_name;
|
||||||
this.topusers_user1_score.textContent = users[0].amount;
|
this.topusers_user1_score.textContent = Math.round(users[0].amount);
|
||||||
//this.topusers_user1_name.style.animationDuration = `${this.topusers_user1_name.getBoundingClientRect().width / 50}s`;
|
//this.topusers_user1_name.style.animationDuration = `${this.topusers_user1_name.getBoundingClientRect().width / 50}s`;
|
||||||
} else {
|
} else {
|
||||||
this.topusers_user1_num.textContent = "1";
|
this.topusers_user1_num.textContent = "1";
|
||||||
@@ -327,7 +327,7 @@ class TimerRenderer {
|
|||||||
this.topusers_user2_num.textContent = "2";
|
this.topusers_user2_num.textContent = "2";
|
||||||
this.topusers_user2_name.textContent = users[1].user_name;
|
this.topusers_user2_name.textContent = users[1].user_name;
|
||||||
this.topusers_userdupe2_name.textContent = users[1].user_name;
|
this.topusers_userdupe2_name.textContent = users[1].user_name;
|
||||||
this.topusers_user2_score.textContent = users[1].amount;
|
this.topusers_user2_score.textContent = Math.round(users[1].amount);
|
||||||
//this.topusers_user2_name.style.animationDuration = `${this.topusers_user2_name.getBoundingClientRect().width / 50}s`;
|
//this.topusers_user2_name.style.animationDuration = `${this.topusers_user2_name.getBoundingClientRect().width / 50}s`;
|
||||||
} else {
|
} else {
|
||||||
this.topusers_user2_num.textContent = "2";
|
this.topusers_user2_num.textContent = "2";
|
||||||
@@ -340,7 +340,7 @@ class TimerRenderer {
|
|||||||
this.topusers_user3_num.textContent = "3";
|
this.topusers_user3_num.textContent = "3";
|
||||||
this.topusers_user3_name.textContent = users[2].user_name;
|
this.topusers_user3_name.textContent = users[2].user_name;
|
||||||
this.topusers_userdupe3_name.textContent = users[2].user_name;
|
this.topusers_userdupe3_name.textContent = users[2].user_name;
|
||||||
this.topusers_user3_score.textContent = users[2].amount;
|
this.topusers_user3_score.textContent = Math.round(users[2].amount);
|
||||||
//this.topusers_user3_name.style.animationDuration = `${this.topusers_user3_name.getBoundingClientRect().width / 50}s`;
|
//this.topusers_user3_name.style.animationDuration = `${this.topusers_user3_name.getBoundingClientRect().width / 50}s`;
|
||||||
} else {
|
} else {
|
||||||
this.topusers_user3_num.textContent = "3";
|
this.topusers_user3_num.textContent = "3";
|
||||||
|
|||||||
Reference in New Issue
Block a user