From e36c1e1c0e5a89f316149b37f5a2f271b9b9bbaf Mon Sep 17 00:00:00 2001
From: Zac
Date: Wed, 6 Dec 2023 11:37:53 +0800
Subject: [PATCH] implement cover page for challenge
---
app/page.tsx | 6 +-
.../landing/challenge/challenge-intro.tsx | 63 +++++++++++++++++++
.../landing/challenge/challenge-main.tsx | 28 +++++++++
3 files changed, 94 insertions(+), 3 deletions(-)
create mode 100644 components/landing/challenge/challenge-intro.tsx
create mode 100644 components/landing/challenge/challenge-main.tsx
diff --git a/app/page.tsx b/app/page.tsx
index a26ba92..657f276 100644
--- a/app/page.tsx
+++ b/app/page.tsx
@@ -11,7 +11,7 @@ import GrowOnScroll from "@/components/ui/grow-on-scroll";
import Footer from "@/components/landing/footer";
import ComponentCarousel from "@/components/ui/component-carousel";
import { Separator } from "@/components/ui/separator";
-import StepperCard from "@/components/landing/challenge/stepper-pages/StepperCard";
+import ChallengeMain from "@/components/landing/challenge/challenge-main";
export default function Home() {
return (
@@ -47,7 +47,7 @@ export default function Home() {
-
+
@@ -61,7 +61,7 @@ export default function Home() {
/>
-
+
diff --git a/components/landing/challenge/challenge-intro.tsx b/components/landing/challenge/challenge-intro.tsx
new file mode 100644
index 0000000..1e10f1d
--- /dev/null
+++ b/components/landing/challenge/challenge-intro.tsx
@@ -0,0 +1,63 @@
+import { Badge } from "@/components/ui/badge";
+import Link from "next/link";
+import {
+ Card,
+ CardContent,
+ CardDescription,
+ CardHeader,
+ CardTitle,
+ CardFooter,
+} from "@/components/ui/card";
+import { Separator } from "@/components/ui/separator";
+
+interface ChallengeIntroProps {
+ button: () => React.ReactNode;
+}
+
+const ChallengeIntro: React.FC = ({ button }) => {
+ return (
+
+
+
+ We're glad you're here!
+
+
+
+ Alpha
+
+
+
+
+
+
+ It's simple. We'll provide you a coding
+ environment and a target image. Your job is to recreate that
+ image using{" "}
+ HTML {" "}
+ and{" "}
+
+ TailwindCSS
+
+ . After you submit, we'll send your scores via Email
+ 📧.
+
+
+
+
+ At this stage, we're presenting a bare bones look at
+ what's to come for Tailspin and looking for{" "}
+
+ feedback
+
+ !
+
+
+
+
+ {button()}
+
+
+ );
+};
+
+export default ChallengeIntro;
diff --git a/components/landing/challenge/challenge-main.tsx b/components/landing/challenge/challenge-main.tsx
new file mode 100644
index 0000000..c089107
--- /dev/null
+++ b/components/landing/challenge/challenge-main.tsx
@@ -0,0 +1,28 @@
+"use client";
+
+import { useState } from "react";
+import ChallengeIntro from "./challenge-intro";
+import StepperCard from "./stepper-pages/StepperCard";
+import { Button } from "@/components/ui/button";
+import { Code } from "lucide-react";
+
+const ChallengeMain = () => {
+ const [goToStepper, setGoToStepper] = useState(false);
+
+ const readyToCodeButton = () => {
+ return (
+ setGoToStepper(true)}>
+ Ready to code
+
+
+ );
+ };
+ return (
+ <>
+ {!goToStepper && }
+ {goToStepper && }
+ >
+ );
+};
+
+export default ChallengeMain;