diff --git a/app/components/sport-season/GroupStageStandings.tsx b/app/components/sport-season/GroupStageStandings.tsx index 4931914..360b0c0 100644 --- a/app/components/sport-season/GroupStageStandings.tsx +++ b/app/components/sport-season/GroupStageStandings.tsx @@ -70,7 +70,7 @@ function MatchResult({ match }: { match: GroupMatch }) { {p2} {kickoff && ( - + {kickoff.toLocaleTimeString("en-US", { hour: "numeric", minute: "2-digit" })} )} @@ -181,7 +181,7 @@ export function GroupStageStandings({
{[...byDay.entries()].map(([day, matches]) => (
-

+

{day}

{matches.map((m) => ( diff --git a/app/routes/leagues/$leagueId.sports-seasons.$sportsSeasonId.tsx b/app/routes/leagues/$leagueId.sports-seasons.$sportsSeasonId.tsx index 6093b88..d69355e 100644 --- a/app/routes/leagues/$leagueId.sports-seasons.$sportsSeasonId.tsx +++ b/app/routes/leagues/$leagueId.sports-seasons.$sportsSeasonId.tsx @@ -45,6 +45,7 @@ export default function SportSeasonDetail({ } = loaderData; const hasBracket = playoffMatches && playoffMatches.length > 0; + const bracketHasTeams = hasBracket && playoffMatches.some((m) => m.participant1 !== null || m.participant2 !== null); const hasStandings = regularSeasonStandings && regularSeasonStandings.length > 0; const showOtLosses = hasStandings && regularSeasonStandings.some((s) => s.otLosses !== null); @@ -75,7 +76,8 @@ export default function SportSeasonDetail({ const [view, setView] = useState(() => { if (showGroupStageToggle) { - return sportsSeason.status === "completed" ? "finished" : "playoffs"; + if (sportsSeason.status === "completed") return "finished"; + return bracketHasTeams ? "playoffs" : "groups"; } if (!hasBracket) return "standings"; if (sportsSeason.status === "completed") return "finished";