Manual auth
This commit is contained in:
+18
-2
@@ -2,7 +2,8 @@
|
||||
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
|
||||
import redirectAuth from "@/lib/dockship/redirect";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { redirectAuth, manualAuth } from "@/lib/dockship/auth";
|
||||
import { GithubIcon } from "lucide-react";
|
||||
import Image from "next/image";
|
||||
|
||||
@@ -24,10 +25,25 @@ export default function LogIn() {
|
||||
/>
|
||||
</CardTitle>
|
||||
</CardHeader>
|
||||
<CardContent>
|
||||
<CardContent className="flex max-w-sm flex-col gap-4">
|
||||
<Button className="w-full" onClick={withGithub}>
|
||||
<GithubIcon /> Continue with GitHub
|
||||
</Button>
|
||||
<div className="relative">
|
||||
<div className="absolute inset-0 flex items-center">
|
||||
<span className="w-full border-t" />
|
||||
</div>
|
||||
<div className="relative flex justify-center text-xs uppercase">
|
||||
<span className="bg-card px-2 text-muted-foreground">OR</span>
|
||||
</div>
|
||||
</div>
|
||||
<Input
|
||||
placeholder="Access token"
|
||||
onKeyUp={(e) => {
|
||||
if (e.key === "Enter")
|
||||
manualAuth((e.target as HTMLInputElement).value);
|
||||
}}
|
||||
/>
|
||||
</CardContent>
|
||||
</Card>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user