Discord sign-in and basic accounts
Discord sign-in makes a basic account (Discord's verified email, no username or password) for T5DE's other sites; it finishes setting up with a username and password to use the hub. Implicit linking by email is off; members link Discord from their account page. Better Auth 1.7.26.
This commit is contained in:
1 parent
a66a3a4b6a
commit
f0a9661f8e
24 files changed
+5214
-173
No files matched your search
@@ -4,6 +4,7 @@ import { Header } from "@/components/header";
|
||||
import { NarrowCard } from "@/components/narrow-card";
|
||||
import { StagingBanner } from "@/components/staging-banner";
|
||||
import { getMe } from "@/lib/api";
|
||||
import { FinishSetupForm } from "./account/finish-setup-form";
|
||||
import { cn } from "@/lib/utils";
|
||||
import "./globals.css";
|
||||
|
||||
@@ -23,7 +24,14 @@ export default async function RootLayout({ children }: { children: React.ReactNo
|
||||
<StagingBanner />
|
||||
<Header />
|
||||
<main className="mx-auto w-full max-w-5xl flex-1 px-4 py-10 sm:px-6 sm:py-14">
|
||||
{me && !me.approved ? (
|
||||
{me?.kind === "basic" ? (
|
||||
<NarrowCard
|
||||
title="Finish Setting Up Your Account"
|
||||
description={`You're signed in with Discord as ${me.username}. Choose a username and password to use the hub; T5DE's other sites already work with your Discord sign-in.`}
|
||||
>
|
||||
<FinishSetupForm />
|
||||
</NarrowCard>
|
||||
) : me && !me.approved ? (
|
||||
<NarrowCard
|
||||
title="Waiting for Approval"
|
||||
description={`Thanks for signing up, ${me.username}. A moderator will approve your account soon; until then you can't use the hub.`}
|
||||
|
||||
Reference in new issue
Block a user