aboutsummaryrefslogtreecommitdiffhomepage
path: root/frontend/app/components/GolfWatchApps/GolfWatchAppWaiting1v1.tsx
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2025-03-21 10:16:42 +0900
committernsfisis <nsfisis@gmail.com>2025-03-21 10:16:42 +0900
commite31c22dda15a665ffefc13b14a8b377062ef0351 (patch)
treea6a523d6fc822600213e8c7dd45f79a09ba6ef0b /frontend/app/components/GolfWatchApps/GolfWatchAppWaiting1v1.tsx
parente66bba3317c51b1c9d89bcef706d05b82c7148ec (diff)
downloadphperkaigi-2025-albatross-e31c22dda15a665ffefc13b14a8b377062ef0351.tar.gz
phperkaigi-2025-albatross-e31c22dda15a665ffefc13b14a8b377062ef0351.tar.zst
phperkaigi-2025-albatross-e31c22dda15a665ffefc13b14a8b377062ef0351.zip
feat(frontend): make main players optional
Diffstat (limited to 'frontend/app/components/GolfWatchApps/GolfWatchAppWaiting1v1.tsx')
-rw-r--r--frontend/app/components/GolfWatchApps/GolfWatchAppWaiting1v1.tsx16
1 files changed, 12 insertions, 4 deletions
diff --git a/frontend/app/components/GolfWatchApps/GolfWatchAppWaiting1v1.tsx b/frontend/app/components/GolfWatchApps/GolfWatchAppWaiting1v1.tsx
index 33f37be..ae88295 100644
--- a/frontend/app/components/GolfWatchApps/GolfWatchAppWaiting1v1.tsx
+++ b/frontend/app/components/GolfWatchApps/GolfWatchAppWaiting1v1.tsx
@@ -3,8 +3,8 @@ import PlayerNameAndIcon from "../PlayerNameAndIcon";
type Props = {
gameDisplayName: string;
- playerProfileA: PlayerProfile;
- playerProfileB: PlayerProfile;
+ playerProfileA: PlayerProfile | null;
+ playerProfileB: PlayerProfile | null;
};
export default function GolfWatchAppWaiting1v1({
@@ -18,9 +18,17 @@ export default function GolfWatchAppWaiting1v1({
<div className="text-4xl">{gameDisplayName}</div>
</div>
<div className="grow grid grid-cols-3 gap-10 mx-auto text-black">
- <PlayerNameAndIcon profile={playerProfileA} />
+ {playerProfileA ? (
+ <PlayerNameAndIcon profile={playerProfileA} />
+ ) : (
+ <div></div>
+ )}
<div className="text-8xl my-auto">vs.</div>
- <PlayerNameAndIcon profile={playerProfileB} />
+ {playerProfileB ? (
+ <PlayerNameAndIcon profile={playerProfileB} />
+ ) : (
+ <div></div>
+ )}
</div>
</div>
);