mirror of https://github.com/kortix-ai/suna.git
fix: auth screen
This commit is contained in:
parent
7498c9fa1b
commit
f8f3afe5f1
|
@ -16,7 +16,6 @@ import { useInitiateAgentMutation } from '@/hooks/react-query/dashboard/use-init
|
||||||
import { useThreadQuery } from '@/hooks/react-query/threads/use-threads';
|
import { useThreadQuery } from '@/hooks/react-query/threads/use-threads';
|
||||||
import { generateThreadName } from '@/lib/actions/threads';
|
import { generateThreadName } from '@/lib/actions/threads';
|
||||||
import GoogleSignIn from '@/components/GoogleSignIn';
|
import GoogleSignIn from '@/components/GoogleSignIn';
|
||||||
import { Input } from '@/components/ui/input';
|
|
||||||
import {
|
import {
|
||||||
Dialog,
|
Dialog,
|
||||||
DialogContent,
|
DialogContent,
|
||||||
|
@ -365,7 +364,7 @@ export function HeroSection() {
|
||||||
{/* Auth Dialog */}
|
{/* Auth Dialog */}
|
||||||
<Dialog open={authDialogOpen} onOpenChange={setAuthDialogOpen}>
|
<Dialog open={authDialogOpen} onOpenChange={setAuthDialogOpen}>
|
||||||
<BlurredDialogOverlay />
|
<BlurredDialogOverlay />
|
||||||
<DialogContent className="sm:max-w-md rounded-xl bg-[#F3F4F6] dark:bg-[#F9FAFB]/[0.02] border border-border">
|
<DialogContent className="sm:max-w-md rounded-xl bg-background border border-border">
|
||||||
<DialogHeader>
|
<DialogHeader>
|
||||||
<div className="flex items-center justify-between">
|
<div className="flex items-center justify-between">
|
||||||
<DialogTitle className="text-xl font-medium">
|
<DialogTitle className="text-xl font-medium">
|
||||||
|
@ -402,58 +401,24 @@ export function HeroSection() {
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Sign in form */}
|
{/* Sign in options */}
|
||||||
<form className="space-y-4">
|
<div className="space-y-4 pt-4">
|
||||||
<div>
|
<Link
|
||||||
<Input
|
href={`/auth?returnUrl=${encodeURIComponent('/dashboard')}`}
|
||||||
id="email"
|
className="flex h-12 items-center justify-center w-full text-center rounded-full bg-primary text-primary-foreground hover:bg-primary/90 transition-all shadow-md"
|
||||||
name="email"
|
onClick={() => setAuthDialogOpen(false)}
|
||||||
type="email"
|
>
|
||||||
placeholder="Email address"
|
Sign in with email
|
||||||
className="h-12 rounded-full bg-background border-border"
|
</Link>
|
||||||
required
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div>
|
<Link
|
||||||
<Input
|
href={`/auth?mode=signup&returnUrl=${encodeURIComponent('/dashboard')}`}
|
||||||
id="password"
|
className="flex h-12 items-center justify-center w-full text-center rounded-full border border-border bg-background hover:bg-accent/20 transition-all"
|
||||||
name="password"
|
onClick={() => setAuthDialogOpen(false)}
|
||||||
type="password"
|
>
|
||||||
placeholder="Password"
|
Create new account
|
||||||
className="h-12 rounded-full bg-background border-border"
|
</Link>
|
||||||
required
|
</div>
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="space-y-4 pt-4">
|
|
||||||
<Link
|
|
||||||
href={`/auth?returnUrl=${encodeURIComponent('/dashboard')}`}
|
|
||||||
className="flex h-12 items-center justify-center w-full text-center rounded-full bg-primary text-primary-foreground hover:bg-primary/90 transition-all shadow-md"
|
|
||||||
onClick={() => setAuthDialogOpen(false)}
|
|
||||||
>
|
|
||||||
Sign in
|
|
||||||
</Link>
|
|
||||||
|
|
||||||
<Link
|
|
||||||
href={`/auth?mode=signup&returnUrl=${encodeURIComponent('/dashboard')}`}
|
|
||||||
className="flex h-12 items-center justify-center w-full text-center rounded-full border border-border bg-background hover:bg-accent/20 transition-all"
|
|
||||||
onClick={() => setAuthDialogOpen(false)}
|
|
||||||
>
|
|
||||||
Create new account
|
|
||||||
</Link>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="text-center pt-2">
|
|
||||||
<Link
|
|
||||||
href={`/auth?returnUrl=${encodeURIComponent('/dashboard')}`}
|
|
||||||
className="text-sm text-primary hover:underline"
|
|
||||||
onClick={() => setAuthDialogOpen(false)}
|
|
||||||
>
|
|
||||||
More sign in options
|
|
||||||
</Link>
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
|
|
||||||
<div className="mt-4 text-center text-xs text-muted-foreground">
|
<div className="mt-4 text-center text-xs text-muted-foreground">
|
||||||
By continuing, you agree to our{' '}
|
By continuing, you agree to our{' '}
|
||||||
|
|
Loading…
Reference in New Issue