From f80ea39ba393036531ce7b4b7242a0c06c694b50 Mon Sep 17 00:00:00 2001 From: Andy Date: Mon, 10 Jun 2024 16:21:49 -0400 Subject: [PATCH] Add simple reset --- src/components/Modes/Challenge/Challenge.tsx | 21 ++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/src/components/Modes/Challenge/Challenge.tsx b/src/components/Modes/Challenge/Challenge.tsx index 0614862..7f8ac8f 100644 --- a/src/components/Modes/Challenge/Challenge.tsx +++ b/src/components/Modes/Challenge/Challenge.tsx @@ -56,15 +56,32 @@ export default function Challenge() { } } } + + function resetGame() { + setGameState(setUpGameState()); + } + return ( <> {inProgress && (

Remaining Notes: {notesLeftCount}

)} {!inProgress && !notesLeftCount && ( -

You win!

+
+

You win!

{" "} + +
)} -

Scale: {randomScale.name}

+

+ Scale:{" "} + {randomScale.name} +

{shuffledNotes.map((note) => { return (