27 lines
758 B
TypeScript
27 lines
758 B
TypeScript
import { redirect } from 'next/navigation'
|
||
import { getSession } from '@/lib/auth'
|
||
import LoginForm from './LoginForm'
|
||
|
||
export const metadata = {
|
||
title: 'Admin Login - Moy Beach',
|
||
}
|
||
|
||
export default async function LoginPage() {
|
||
const session = await getSession()
|
||
if (session) {
|
||
redirect('/admin')
|
||
}
|
||
|
||
return (
|
||
<div className="min-h-screen flex items-center justify-center bg-gray-50">
|
||
<div className="max-w-md w-full p-8 bg-white rounded-xl shadow-lg">
|
||
<div className="text-center mb-8">
|
||
<h1 className="text-2xl font-bold text-gray-900">Admin Girişi</h1>
|
||
<p className="text-gray-500 mt-2">Yönetim paneline erişmek için giriş yapın</p>
|
||
</div>
|
||
<LoginForm />
|
||
</div>
|
||
</div>
|
||
)
|
||
}
|