Implement Auth.

This commit is contained in:
2024-07-19 12:08:09 -05:00
parent 3c9a23481e
commit 6414307462
9 changed files with 105 additions and 98 deletions

View File

@ -0,0 +1,10 @@
import Sign_In from "./Sign_In";
export default function No_Session() {
return (
<div className="w-2/3 mx-auto text-center pt-10">
<h1 className="text-2xl font-semibold">Unauthorized. Please sign in first.</h1>
< Sign_In />
</div>
);
};

View File

@ -0,0 +1,13 @@
import { signIn } from "~/auth";
export default async function Sign_In() {
return (
<form className="w-full"
action={async () => {
"use server";
await signIn("microsoft-entra-id");
}}>
<button type="submit" className="w-full">Sign In</button>
</form>
);
}