From cf73c37e4f40d0cdfd05e3f688e03f4896a033ff Mon Sep 17 00:00:00 2001 From: Spencer Spenst Date: Fri, 29 Sep 2023 18:23:33 -0700 Subject: [PATCH] more intuitive campaign button --- components/cards/chapterSelectCard.tsx | 13 +++++++------ components/homepage/homeLoggedIn.tsx | 12 ++---------- 2 files changed, 9 insertions(+), 16 deletions(-) diff --git a/components/cards/chapterSelectCard.tsx b/components/cards/chapterSelectCard.tsx index 14b5ac868..975c8b475 100644 --- a/components/cards/chapterSelectCard.tsx +++ b/components/cards/chapterSelectCard.tsx @@ -77,15 +77,16 @@ function ChapterSelectCardBase({ interface ChapterSelectCardProps { chapter: number; chapterUnlocked?: number; + href?: string; } -export default function ChapterSelectCard({ chapter, chapterUnlocked }: ChapterSelectCardProps) { +export default function ChapterSelectCard({ chapter, chapterUnlocked, href }: ChapterSelectCardProps) { switch (chapter) { case 1: return ( 1} - href={'/chapter1'} + href={href ?? '/chapter1'} id='chapter1' levelData={'00000000\n00000000\n00000000\n00000000'} subtitle={'Grassroots'} @@ -98,7 +99,7 @@ export default function ChapterSelectCard({ chapter, chapterUnlocked }: ChapterS complete={!!chapterUnlocked && chapterUnlocked > 2} disabled={chapterUnlocked ? chapterUnlocked < 2 : false} disabledStr={'Complete Chapter 1 to unlock Chapter 2!'} - href={'/chapter2'} + href={href ?? '/chapter2'} id='chapter2' levelData={'005E0C00\n0G070005\n10005010\n005100I0'} subtitle={'Into the Depths'} @@ -111,7 +112,7 @@ export default function ChapterSelectCard({ chapter, chapterUnlocked }: ChapterS complete={!!chapterUnlocked && chapterUnlocked > 3} disabled={chapterUnlocked ? chapterUnlocked < 3 : false} disabledStr={'Complete Chapter 2 to unlock Chapter 3!'} - href={'/chapter3'} + href={href ?? '/chapter3'} id='chapter3' levelData={'B519F0G0\n10JH5H52\n75F02J08\n02050B10'} subtitle={'Brain Busters'} @@ -121,8 +122,8 @@ export default function ChapterSelectCard({ chapter, chapterUnlocked }: ChapterS case 4: return (
- - Pathology Official Campaign - - } - tooltip='Click here to go to the chapter select screen, or continue with the chapter button below!' - > +
- +