diff options
author | Jeff <jeffkleinaitis@gmail.com> | 2024-04-09 15:09:29 -0400 |
---|---|---|
committer | Jeff <jeffkleinaitis@gmail.com> | 2024-04-09 15:09:29 -0400 |
commit | 2374eae054935dd49adf3f0e29e8bea0876288f4 (patch) | |
tree | 82cb8cff09b822117b26cc512763c32eeaa75a39 /pages/index.js | |
parent | 7c2574f1985cddba1e6fa6fcc6f8e1c019aaf7ed (diff) | |
parent | ccf52d88eb60f518cc3e5bb3ce2b21bbb6858337 (diff) |
Resolve merge conflicts
Diffstat (limited to 'pages/index.js')
-rw-r--r-- | pages/index.js | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/pages/index.js b/pages/index.js new file mode 100644 index 0000000..3369175 --- /dev/null +++ b/pages/index.js @@ -0,0 +1,49 @@ +import Hero from "../components/hero";
+import SectionTitle from "../components/sectionTitle";
+import { benefitOne, benefitTwo } from "../components/data";
+import Benefits from "../components/benefits";
+import Cta from "../components/cta";
+import Faq from "../components/faq";
+import { useSession, signIn, signOut } from "next-auth/react"
+
+
+const Home = () => {
+ const { data: session, status } = useSession()
+ if (status === "authenticated") {
+ return (
+ <section className="grid h-screen place-items-center">
+ <div className="max-w-sm p-6 bg-white border border-gray-200 rounded-lg shadow dark:bg-gray-800 dark:border-gray-700">
+ <h2 className="mb-2 text-2xl font-bold tracking-tight text-gray-900 dark:text-white">Hi {session?.user?.name}</h2><br />
+ <p className="mb-3 font-normal text-gray-700 dark:text-gray-400">You are signed in as {session?.user?.email}.</p>
+ <button
+ type="button"
+ onClick={() => signOut()}
+ className="inline-flex items-center px-3 py-2 text-sm font-medium text-center text-white bg-red-700 rounded-lg hover:bg-red-800 focus:ring-4 focus:outline-none focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-800">
+ Logout
+ </button>
+ </div>
+ </section>
+ )
+ }
+
+ return (
+ <>
+ <Hero />
+ <SectionTitle
+ pretitle="How It Works"
+ title="Getting Started with Helping Hands">
+ Helping Hands simplifies the process of finding or offering volunteer opportunities. Here's a step-by-step guide:
+ </SectionTitle>
+ <Benefits data={benefitOne} />
+ <Benefits imgPos="right" data={benefitTwo} />
+ <SectionTitle pretitle="FAQ" title="Frequently Asked Questions">
+ Welcome to our FAQ section! Browse through common questions for quick answers. Your clarity and support matter to us.
+ For any unanswered queries, reach out to our support team.
+ </SectionTitle>
+ <Faq />
+ <Cta />
+ </>
+ );
+}
+
+export default Home;
\ No newline at end of file |