add tooltip to missed notes
All checks were successful
Deploy / deploy (push) Successful in 4m29s

This commit is contained in:
Lee 2024-10-03 18:42:22 +01:00
parent df30a4ecf0
commit 8c12b6c521

@ -88,10 +88,31 @@ const badges: ScoreBadge[] = [
name: "Full Combo",
create: (score: ScoreSaberScoreToken) => {
return (
<Tooltip
display={
<div className="flex flex-col justify-center items-center">
{!score.fullCombo ? (
<>
<p>{score.fullCombo ? <span className="text-green-400">FC</span> : formatNumberWithCommas(score.missedNotes + score.badCuts)}</p>
<XMarkIcon className={clsx("w-5 h-5", score.fullCombo ? "hidden" : "text-red-400")} />
<p>Missed Notes: {formatNumberWithCommas(score.missedNotes)}</p>
<p>Bad Cuts: {formatNumberWithCommas(score.badCuts)}</p>
</>
) : (
<p>Full Combo</p>
)}
</div>
}
>
<div className="flex gap-1">
<p>
{score.fullCombo ? (
<span className="text-green-400">FC</span>
) : (
formatNumberWithCommas(score.missedNotes + score.badCuts)
)}
</p>
<XMarkIcon className={clsx("w-5 h-5", score.fullCombo ? "hidden" : "text-red-400")} />
</div>
</Tooltip>
);
},
},