fix hand acc
All checks were successful
Deploy Website / docker (ubuntu-latest) (push) Successful in 2m23s

This commit is contained in:
Lee 2024-10-23 07:40:11 +01:00
parent ff9ff5b96b
commit 299cf20cb9
2 changed files with 7 additions and 1 deletions

@ -22,8 +22,8 @@ export function HandAccuracy({ score, hand }: HandAccuracyProps) {
const { handAccuracy } = score.additionalData;
const scoreImprovement = score.additionalData.scoreImprovement;
const previousHandAccuracy = scoreImprovement ? handAccuracy[hand] - scoreImprovement.handAccuracy[hand] : undefined;
const formattedHand = capitalizeFirstLetter(hand);
return (
<div className="flex flex-col items-center justify-center">
<Tooltip display={`${formattedHand} Hand Accuracy`}>

@ -125,6 +125,9 @@ const badges: ScoreBadge[] = [
name: "Left Hand Accuracy",
color: () => "bg-hands-left",
create: (score: ScoreSaberScore) => {
if (!score.additionalData) {
return undefined;
}
return <HandAccuracy score={score} hand="left" />;
},
},
@ -132,6 +135,9 @@ const badges: ScoreBadge[] = [
name: "Right Hand Accuracy",
color: () => "bg-hands-right",
create: (score: ScoreSaberScore) => {
if (!score.additionalData) {
return undefined;
}
return <HandAccuracy score={score} hand="right" />;
},
},