Add AuthLayoutClient component and unit tests for authentication layout
- Implemented `AuthLayoutClient` with theme toggle and responsive layout. - Replaced legacy layout implementation in `layout.tsx` with `AuthLayoutClient` for improved modularity and styling consistency. - Added comprehensive Jest tests to verify layout structure, theme toggle placement, and responsive rendering.
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import type { Metadata } from 'next';
|
||||
import { AuthLayoutClient } from '@/components/auth/AuthLayoutClient';
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: 'Authentication',
|
||||
@@ -9,11 +10,5 @@ export default function AuthLayout({
|
||||
}: {
|
||||
children: React.ReactNode;
|
||||
}) {
|
||||
return (
|
||||
<div className="flex min-h-screen items-center justify-center bg-gray-50 dark:bg-gray-900 px-4 py-12 sm:px-6 lg:px-8">
|
||||
<div className="w-full max-w-md space-y-8">
|
||||
{children}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
return <AuthLayoutClient>{children}</AuthLayoutClient>;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user