From 9571980898f5f83db2892c40becc569984c5c136 Mon Sep 17 00:00:00 2001 From: yohlo Date: Sun, 1 Mar 2026 20:20:24 -0600 Subject: [PATCH] fix team avatars --- src/app/routes/_authed/admin/tournaments/run.$id.tsx | 2 ++ src/app/routes/_authed/tournaments/$id.groups.tsx | 1 + src/features/teams/components/team-list.tsx | 4 +++- src/features/tournaments/components/group-stage-view.tsx | 4 +++- src/features/tournaments/components/profile/index.tsx | 2 +- .../tournaments/components/started-tournament/index.tsx | 2 +- .../tournaments/components/upcoming-tournament/index.tsx | 4 ++-- .../components/upcoming-tournament/team-list-button.tsx | 5 +++-- 8 files changed, 16 insertions(+), 8 deletions(-) diff --git a/src/app/routes/_authed/admin/tournaments/run.$id.tsx b/src/app/routes/_authed/admin/tournaments/run.$id.tsx index 3572323..0635e6a 100644 --- a/src/app/routes/_authed/admin/tournaments/run.$id.tsx +++ b/src/app/routes/_authed/admin/tournaments/run.$id.tsx @@ -106,6 +106,7 @@ function RouteComponent() { showControls tournamentId={tournament.id} hasKnockoutBracket={knockoutBracketPopulated} + isRegional={tournament.regional} />
@@ -120,6 +121,7 @@ function RouteComponent() { showControls tournamentId={tournament.id} hasKnockoutBracket={knockoutBracketPopulated} + isRegional={tournament.regional} /> ) : ( diff --git a/src/app/routes/_authed/tournaments/$id.groups.tsx b/src/app/routes/_authed/tournaments/$id.groups.tsx index fe82dff..f0ea172 100644 --- a/src/app/routes/_authed/tournaments/$id.groups.tsx +++ b/src/app/routes/_authed/tournaments/$id.groups.tsx @@ -39,6 +39,7 @@ function RouteComponent() { ); diff --git a/src/features/teams/components/team-list.tsx b/src/features/teams/components/team-list.tsx index 068062c..622282d 100644 --- a/src/features/teams/components/team-list.tsx +++ b/src/features/teams/components/team-list.tsx @@ -49,9 +49,10 @@ interface TeamListProps { teams: TeamInfo[]; loading?: boolean; onTeamClick?: (teamId: string) => void; + isRegional?: boolean; } -const TeamList = ({ teams, loading = false, onTeamClick }: TeamListProps) => { +const TeamList = ({ teams, loading = false, onTeamClick, isRegional }: TeamListProps) => { const navigate = useNavigate(); const handleClick = useCallback( @@ -92,6 +93,7 @@ const TeamList = ({ teams, loading = false, onTeamClick }: TeamListProps) => { team={team} radius="sm" size={40} + isRegional={isRegional} /> } style={{ cursor: "pointer" }} diff --git a/src/features/tournaments/components/group-stage-view.tsx b/src/features/tournaments/components/group-stage-view.tsx index 2499f22..b008d61 100644 --- a/src/features/tournaments/components/group-stage-view.tsx +++ b/src/features/tournaments/components/group-stage-view.tsx @@ -16,6 +16,7 @@ interface GroupStageViewProps { showControls?: boolean; tournamentId?: string; hasKnockoutBracket?: boolean; + isRegional?: boolean; } interface TeamStanding { @@ -35,6 +36,7 @@ const GroupStageView: React.FC = ({ showControls, tournamentId, hasKnockoutBracket, + isRegional, }) => { const queryClient = useQueryClient(); const [expandedTeams, setExpandedTeams] = useState>({}); @@ -334,7 +336,7 @@ const GroupStageView: React.FC = ({ {index + 1} - + {standing.teamName} diff --git a/src/features/tournaments/components/profile/index.tsx b/src/features/tournaments/components/profile/index.tsx index a1b1553..ca38f40 100644 --- a/src/features/tournaments/components/profile/index.tsx +++ b/src/features/tournaments/components/profile/index.tsx @@ -27,7 +27,7 @@ const Profile = ({ id }: ProfileProps) => { { label: "Teams", content: <> - + } ], [tournament]); diff --git a/src/features/tournaments/components/started-tournament/index.tsx b/src/features/tournaments/components/started-tournament/index.tsx index 05113c1..7a3489a 100644 --- a/src/features/tournaments/components/started-tournament/index.tsx +++ b/src/features/tournaments/components/started-tournament/index.tsx @@ -99,7 +99,7 @@ const StartedTournament: React.FC<{ tournament: Tournament }> = ({ to={`/tournaments/${tournament.id}/bracket`} Icon={TreeStructureIcon} /> - + diff --git a/src/features/tournaments/components/upcoming-tournament/index.tsx b/src/features/tournaments/components/upcoming-tournament/index.tsx index e050fcf..98767a4 100644 --- a/src/features/tournaments/components/upcoming-tournament/index.tsx +++ b/src/features/tournaments/components/upcoming-tournament/index.tsx @@ -151,12 +151,12 @@ const UpcomingTournament: React.FC<{ tournament: Tournament }> = ({ /> {tournament.regional === true ? ( (tournament.teams && tournament.teams.length > 0) ? ( - + ) : ( ) ) : ( - + )} diff --git a/src/features/tournaments/components/upcoming-tournament/team-list-button.tsx b/src/features/tournaments/components/upcoming-tournament/team-list-button.tsx index f2da9fd..9b97fc8 100644 --- a/src/features/tournaments/components/upcoming-tournament/team-list-button.tsx +++ b/src/features/tournaments/components/upcoming-tournament/team-list-button.tsx @@ -8,9 +8,10 @@ import { useMemo } from "react" interface TeamListButtonProps { teams: TeamInfo[] + isRegional?: boolean } -const TeamListButton: React.FC = ({ teams }) => { +const TeamListButton: React.FC = ({ teams, isRegional }) => { const count = useMemo(() => teams.length, [teams]); const { open, isOpen, toggle } = useSheet(); return ( @@ -22,7 +23,7 @@ const TeamListButton: React.FC = ({ teams }) => { /> - + )