From 967cf95eee27e3c04e9f7c2c8c0e1efb3284e2a2 Mon Sep 17 00:00:00 2001 From: Liam Date: Sat, 28 Oct 2023 11:47:00 +0100 Subject: [PATCH] cleanup and fix hover text on misses --- src/components/player/Score.tsx | 21 +++------------------ 1 file changed, 3 insertions(+), 18 deletions(-) diff --git a/src/components/player/Score.tsx b/src/components/player/Score.tsx index d4976c6..721e5c7 100644 --- a/src/components/player/Score.tsx +++ b/src/components/player/Score.tsx @@ -31,9 +31,9 @@ export default function Score({ score, player, leaderboard }: ScoreProps) { ); const diffColor = songDifficultyToColor(diffName); const accuracy = ((score.baseScore / leaderboard.maxScore) * 100).toFixed(2); + const totalMissedNotes = score.missedNotes + score.badCuts; return ( - //
@@ -85,15 +85,6 @@ export default function Score({ score, player, leaderboard }: ScoreProps) {
- {/* Score Buttons */} - {/*
- -
*/} -
{/* Score rank */} @@ -142,9 +133,7 @@ export default function Score({ score, player, leaderboard }: ScoreProps) { isFullCombo ? "bg-green-500" : "bg-red-500", )} title={ - isFullCombo - ? "Full Combo" - : `${score.missedNotes}x Missed Notes` + isFullCombo ? "Full Combo" : `${totalMissedNotes}x Missed Notes` } icon={ isFullCombo ? ( @@ -153,11 +142,7 @@ export default function Score({ score, player, leaderboard }: ScoreProps) { ) } - value={ - isFullCombo - ? "FC" - : formatNumber(score.missedNotes + score.badCuts) + "x" - } + value={isFullCombo ? "FC" : formatNumber(totalMissedNotes) + "x"} />