Add settings layout and page structure for authenticated routes

Introduce tabbed navigation for the settings page, including Profile, Password, Sessions, and Preferences sections. Add placeholders for each section with metadata and routes. Redirect `/settings` to `/settings/profile`. Integrate `AuthGuard` for settings and authenticated layouts while incorporating reusable `Header` and `Footer` components.
This commit is contained in:
2025-11-02 05:59:20 +01:00
parent bf04c98408
commit 4536c607eb
7 changed files with 224 additions and 0 deletions

View File

@@ -0,0 +1,34 @@
/**
* Authenticated Route Group Layout
* Wraps all authenticated routes with AuthGuard and provides common layout structure
*/
import type { Metadata } from 'next';
import { AuthGuard } from '@/components/auth';
import { Header } from '@/components/layout/Header';
import { Footer } from '@/components/layout/Footer';
export const metadata: Metadata = {
title: {
template: '%s | FastNext Template',
default: 'Dashboard',
},
};
export default function AuthenticatedLayout({
children,
}: {
children: React.ReactNode;
}) {
return (
<AuthGuard>
<div className="flex min-h-screen flex-col">
<Header />
<main className="flex-1">
{children}
</main>
<Footer />
</div>
</AuthGuard>
);
}