From e5a86e8714aa54f307f6aae4b78b2d46737566fc Mon Sep 17 00:00:00 2001 From: xiften <108333567+not-ani@users.noreply.github.com> Date: Mon, 14 Oct 2024 15:57:10 -0600 Subject: [PATCH] feat(nextjs): verified status reflected on page --- apps/nextjs/public/veri.svg | 34 ++++++++++++ .../nextjs/src/app/(auth)/unverified/page.tsx | 55 +++++++++++++++---- 2 files changed, 78 insertions(+), 11 deletions(-) create mode 100644 apps/nextjs/public/veri.svg diff --git a/apps/nextjs/public/veri.svg b/apps/nextjs/public/veri.svg new file mode 100644 index 0000000..680bc37 --- /dev/null +++ b/apps/nextjs/public/veri.svg @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/apps/nextjs/src/app/(auth)/unverified/page.tsx b/apps/nextjs/src/app/(auth)/unverified/page.tsx index efe55b3..7c591e9 100644 --- a/apps/nextjs/src/app/(auth)/unverified/page.tsx +++ b/apps/nextjs/src/app/(auth)/unverified/page.tsx @@ -1,25 +1,58 @@ /** eslint-disable @next/next/no-img-element */ +import Link from "next/link"; import { Loader2 } from "lucide-react"; -export default function Component() { +import { Button, buttonVariants } from "@amaxa/ui/button"; + +import { checkAuth } from "~/lib/auth"; + +export default async function Component() { + const auth = await checkAuth(); + + if (auth?.user.status === "Unverified" || auth?.user.status === "Pending") { + return ( +
+
+ Pending Approval Illustration +

+ Hang tight! +

+ {/* j */} +

+ Your account is currently under review. We'll notify you once it's + approved. +

+
+ + Estimated wait time: 24-48 hours +
+
+
+ ); + } + return (
Pending Approval Illustration -

- Hang tight! +

+ Your account is approved!

-

- Your account is currently under review. We'll notify you once it's - approved. +

+ Your account is now approved and you can start using Amaxa.

-
- - Estimated wait time: 24-48 hours +
+ + Go to Home +