From 4cb2677f453e0b61738a1d645d380c8da707f592 Mon Sep 17 00:00:00 2001 From: Emmy D'Anello Date: Fri, 13 Dec 2024 00:02:58 +0100 Subject: [PATCH] =?UTF-8?q?P=C3=A9nalit=C3=A9=20lorsqu'on=20=C3=A9choue=20?= =?UTF-8?q?un=20d=C3=A9fi?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/app/(tabs)/challenges.tsx | 2 +- client/components/ChallengeCard.tsx | 2 +- client/components/GameProvider.tsx | 19 ++++++++++++++++--- client/components/PenalyBanner.tsx | 2 +- client/hooks/useGame.ts | 6 +++++- client/utils/features/game/gameSlice.ts | 12 ++++++++++-- 6 files changed, 34 insertions(+), 9 deletions(-) diff --git a/client/app/(tabs)/challenges.tsx b/client/app/(tabs)/challenges.tsx index 127f0c1..f6db360 100644 --- a/client/app/(tabs)/challenges.tsx +++ b/client/app/(tabs)/challenges.tsx @@ -70,7 +70,7 @@ function ChallengeScreenBody() { challenge={currentChallenge} onSuccess={() => { setLoading(true); endChallenge.mutate({ success: true }) }} onFail={() => endChallenge.mutate({ success: false })} />} - {!loading && !currentChallenge && game.currentRunner && <> + {!loading && !game.penaltyEnd && !currentChallenge && game.currentRunner && <> {onFail && } {onSuccess &&