aboutsummaryrefslogtreecommitdiff
path: root/web/src/app/page.js
blob: 76e5d278bb1c50536069297cda8df25cbbfe99f0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import { redirect } from "next/navigation";
import { auth } from "@/lib/auth";

export default async function Home() {
  const session = await auth();
  if (session) redirect("/dashboard");
    return (
    <>
      <main className="flex justify-center items-center h-screen">
        <form className="flex flex-col gap-4 w-80">
          <input for='username' type='text' placeholder='Username' />
          <input for='password' type='password' placeholder='Password' />
          <input for='api' type='url' placeholder='API URL' />
          <input type="submit" value="Login" />
        </form>
      </main>
    </>
  );
}