From 5baa778901640d02e266dc247c903dcfbeb64a81 Mon Sep 17 00:00:00 2001 From: Aaron Delasy Date: Wed, 23 Oct 2024 00:30:36 +0300 Subject: [PATCH] Congratulations message on beating all levels --- app/play/page.tsx | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/app/play/page.tsx b/app/play/page.tsx index 1d9b0d6..ff62acc 100644 --- a/app/play/page.tsx +++ b/app/play/page.tsx @@ -77,7 +77,7 @@ export default function PlayPage() { return true; }); - if (!filteredMaps) { + if (filteredMaps === undefined) { return (

Choose a Night

@@ -125,6 +125,23 @@ export default function PlayPage() { + {filteredMaps.length === 0 && ( +
+
+
+

Congratulations!

+

+ You completed all maps, consider creating and publishing your + own map. +

+
+ +
+
+ )} +
{filteredMaps.map((map) => (