Add Footer component to demo-2: implement basic layout, links, and integrate into layout.tsx

This commit is contained in:
2025-06-26 10:19:50 +09:00
parent 56c0edf857
commit 06e28ad7fb
2 changed files with 35 additions and 0 deletions

View File

@@ -3,6 +3,7 @@ import {Geist, Geist_Mono} from "next/font/google";
import "./globals.css";
import Navbar from "@/components/Navbar";
import React from "react";
import Footer from "@/components/Footer";
const geistSans = Geist({
variable: "--font-geist-sans",
@@ -31,6 +32,7 @@ export default function RootLayout({
>
<Navbar/>
{children}
<Footer/>
</body>
</html>
);

View File

@@ -0,0 +1,33 @@
"use client";
import Link from "next/link";
export default function Footer() {
return (
<footer className="bg-white dark:bg-gray-950 border-t border-gray-200 dark:border-gray-800 px-4 py-8 text-sm">
<div className="max-w-6xl mx-auto flex flex-col md:flex-row items-center justify-between gap-4">
<div className="text-gray-600 dark:text-gray-400 text-center md:text-left">
© {new Date().getFullYear()} Rechtsanwalt Max Mustermann Alle Rechte vorbehalten
</div>
<div className="flex gap-4 text-gray-600 dark:text-gray-400">
<Link href="/impressum" className="hover:underline">
Impressum
</Link>
<Link href="/datenschutz" className="hover:underline">
Datenschutz
</Link>
<button
onClick={() => {
// TODO: Cookie Modal öffnen
alert("Cookie-Einstellungen öffnen (noch nicht implementiert)");
}}
className="hover:underline"
>
Cookie-Einstellungen
</button>
</div>
</div>
</footer>
);
}