fix tabs on stats table

This commit is contained in:
yohlo
2025-10-11 15:34:12 -05:00
parent 2ed5ab6026
commit b59c7cd7b6
4 changed files with 30 additions and 30 deletions

View File

@@ -108,7 +108,7 @@ const PlayerHeadToHeadSheet = ({
);
}
const totalGames = stats.player1Wins + stats.player2Wins;
const totalMatches = stats.player1Wins + stats.player2Wins;
const leader =
stats.player1Wins > stats.player2Wins
? player1Name
@@ -163,7 +163,7 @@ const PlayerHeadToHeadSheet = ({
</Group>
)}
{!leader && totalGames > 0 && (
{!leader && totalMatches > 0 && (
<Text size="xs" c="dimmed" ta="center">
Series is tied
</Text>
@@ -204,8 +204,8 @@ const PlayerHeadToHeadSheet = ({
<Group justify="space-between" px="md" py="sm">
<Group gap="xs">
<Text size="sm" fw={600}>
{totalGames > 0
? (stats.player1CupsFor / totalGames).toFixed(1)
{totalMatches > 0
? (stats.player1CupsFor / totalMatches).toFixed(1)
: "0.0"}
</Text>
<Text size="xs" c="dimmed">
@@ -213,15 +213,15 @@ const PlayerHeadToHeadSheet = ({
</Text>
</Group>
<Text size="xs" fw={500}>
Avg Cups/Game
Avg Cups/Match
</Text>
<Group gap="xs">
<Text size="xs" c="dimmed">
avg
</Text>
<Text size="sm" fw={600}>
{totalGames > 0
? (stats.player2CupsFor / totalGames).toFixed(1)
{totalMatches > 0
? (stats.player2CupsFor / totalMatches).toFixed(1)
: "0.0"}
</Text>
</Group>
@@ -259,7 +259,7 @@ const PlayerHeadToHeadSheet = ({
<Stack gap="xs">
<Text size="sm" fw={600} px="md">
Match History ({totalGames} games)
Match History ({totalMatches})
</Text>
<MatchList matches={matches} hideH2H />
</Stack>