-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
34c4337
commit b7176fb
Showing
24 changed files
with
940 additions
and
140 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import { ClerkProvider, RedirectToSignUp } from "@clerk/nextjs"; | ||
import { Inter } from "next/font/google"; | ||
import "../globals.css"; | ||
|
||
const inter = Inter({ | ||
subsets: ["latin"], | ||
}); | ||
|
||
export const metadata = { | ||
title: "Nextjs Social", | ||
description: "Generated by Next.js", | ||
}; | ||
|
||
export default function RootLayout({ | ||
children, | ||
}: { | ||
children: React.ReactNode; | ||
}) { | ||
return ( | ||
<html lang="en"> | ||
<ClerkProvider> | ||
|
||
<body className={inter.className}>{children}</body> | ||
</ClerkProvider> | ||
</html> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import AccountProfile from "@/components/forms/AccountProfile"; | ||
import { currentUser } from "@clerk/nextjs/server"; | ||
import { useEffect } from "react"; | ||
|
||
|
||
export default async function Onboarding(){ | ||
const user = await currentUser(); | ||
|
||
const userInfo = { | ||
|
||
} | ||
|
||
// come from database | ||
const userData = { | ||
id: user?.id, | ||
objectId : user?._id, | ||
username : user?.username, | ||
name : user?.firstName || "", | ||
bio : "", | ||
image : user?.imageUrl | ||
} | ||
|
||
|
||
return ( | ||
<main> | ||
<h1>Onboarding</h1> | ||
<section> | ||
<AccountProfile user={userData} btnTitle={"Continue"}></AccountProfile> | ||
</section> | ||
</main> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import { SignIn } from '@clerk/nextjs' | ||
|
||
export default function Page() { | ||
return <div className='w-screen h-screen flex justify-center items-center'> | ||
<SignIn fallbackRedirectUrl="/onboarding"/> | ||
</div> | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { RedirectToSignIn, SignUp } from "@clerk/nextjs"; | ||
|
||
export default function Page() { | ||
return ( | ||
<div className="w-screen h-screen flex justify-center items-center"> | ||
<SignUp fallbackRedirectUrl="/onboarding"> | ||
</SignUp> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import type { Metadata } from "next"; | ||
import "../globals.css"; | ||
import { ClerkProvider } from "@clerk/nextjs"; | ||
import TopBar from "@/components/shared/TopBar"; | ||
import RightBar from "@/components/shared/RightBar"; | ||
import LeftBar from "@/components/shared/LeftBar"; | ||
|
||
export const metadata: Metadata = { | ||
title: "Create Next App", | ||
description: "Generated by create next app", | ||
}; | ||
|
||
export default function RootLayout({ | ||
children, | ||
}: Readonly<{ | ||
children: React.ReactNode; | ||
}>) { | ||
return ( | ||
<html lang="en"> | ||
<ClerkProvider> | ||
<body> | ||
<TopBar></TopBar> | ||
<main className="flex flex-row w-screen h-screen"> | ||
<LeftBar></LeftBar> | ||
<section className="flex-[3] bg-blue-500">{children}</section> | ||
<RightBar></RightBar> | ||
|
||
</main> | ||
</body> | ||
</ClerkProvider> | ||
</html> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
|
||
export default function Home() { | ||
return ( | ||
<div className="bg-blue-500"> | ||
home page!!! | ||
</div> | ||
); | ||
} |
Binary file not shown.
Binary file not shown.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.