Files
LexiChain/features/home/components/Footer.tsx

142 lines
5.4 KiB
TypeScript
Raw Normal View History

2026-02-14 21:47:08 +01:00
"use client";
import { useScrollAnimation } from "@/hooks/useScrollAnimation";
2026-04-19 01:42:00 +01:00
import { Github, Twitter, Linkedin, Mail } from "lucide-react";
2026-02-17 00:14:38 +01:00
import Image from "next/image";
2026-02-14 21:47:08 +01:00
2026-04-19 01:42:00 +01:00
// ==========================================
// Composant : Icône Sociale Premium
// ==========================================
2026-02-14 21:47:08 +01:00
function SocialIcon({
icon: Icon,
href,
label,
}: {
icon: React.ElementType;
href: string;
label: string;
}) {
return (
<a
href={href}
target="_blank"
rel="noopener noreferrer"
aria-label={label}
2026-04-19 01:42:00 +01:00
className="group relative flex items-center justify-center w-10 h-10 rounded-full bg-slate-50 dark:bg-white/[0.03] border border-slate-200 dark:border-white/10 transition-all duration-300 hover:-translate-y-1 hover:border-primary/50 hover:shadow-[0_0_20px_rgba(var(--primary),0.2)]"
2026-02-14 21:47:08 +01:00
>
2026-04-19 01:42:00 +01:00
{/* Lueur d'arrière-plan au survol */}
<div className="absolute inset-0 rounded-full bg-primary/10 opacity-0 group-hover:opacity-100 blur-md transition-opacity duration-300" />
{/* Icône */}
<Icon className="w-4 h-4 text-slate-500 dark:text-slate-400 group-hover:text-primary relative z-10 transition-colors duration-300" />
2026-02-14 21:47:08 +01:00
</a>
);
}
2026-04-19 01:42:00 +01:00
// ==========================================
// Composant Principal : Footer
// ==========================================
2026-02-14 21:47:08 +01:00
export function Footer() {
const { ref, isVisible } = useScrollAnimation<HTMLElement>({
threshold: 0.1,
});
2026-02-17 00:14:38 +01:00
const navLinks = [
2026-02-14 21:47:08 +01:00
{ label: "Features", href: "#features" },
{ label: "How It Works", href: "#how-it-works" },
2026-02-17 00:14:38 +01:00
{ label: "About", href: "#about" },
2026-02-14 21:47:08 +01:00
];
return (
<footer
id="footer"
ref={ref}
2026-04-19 01:42:00 +01:00
className="relative overflow-hidden bg-background pt-20 pb-12 px-4 sm:px-6 lg:px-8"
2026-02-14 21:47:08 +01:00
>
2026-04-19 01:42:00 +01:00
{/* Effet Wow 1 : Ligne de démarcation en dégradé */}
<div className="absolute top-0 left-0 w-full h-[1px] bg-gradient-to-r from-transparent via-foreground/20 dark:via-foreground/15 to-transparent" />
{/* Effet Wow 2 : Lueur d'ambiance à la base de la page */}
<div className="absolute bottom-0 left-1/2 -translate-x-1/2 w-[800px] h-[300px] bg-[radial-gradient(ellipse_at_bottom,hsla(var(--primary),0.15)_0%,transparent_60%)] pointer-events-none" />
2026-02-14 21:47:08 +01:00
<div
2026-04-19 01:42:00 +01:00
className="relative z-10 max-w-7xl mx-auto"
2026-02-14 21:47:08 +01:00
style={{
opacity: isVisible ? 1 : 0,
2026-04-19 01:42:00 +01:00
transform: isVisible ? "translateY(0)" : "translateY(30px)",
transition: "all 0.8s cubic-bezier(0.2, 0.8, 0.2, 1)",
2026-02-14 21:47:08 +01:00
}}
>
2026-04-19 01:42:00 +01:00
<div className="flex flex-col items-center space-y-10">
{/* Logo & Nom de la marque avec Lueur */}
<a href="#" className="inline-flex flex-col items-center gap-3 group">
2026-02-17 00:14:38 +01:00
<div className="relative">
2026-04-19 01:42:00 +01:00
{/* Lueur sous le logo */}
<div className="absolute inset-0 bg-primary/20 blur-xl rounded-full opacity-0 group-hover:opacity-100 transition-opacity duration-500" />
2026-02-17 00:14:38 +01:00
<Image
src="/LexiChain.png"
alt="LexiChain Logo"
2026-04-19 01:42:00 +01:00
width={56}
height={56}
className="relative z-10 w-14 h-14 object-contain transition-transform duration-500 ease-out group-hover:scale-110"
2026-02-17 00:14:38 +01:00
/>
</div>
2026-04-19 01:42:00 +01:00
<span className="text-xl font-bold tracking-tight text-foreground/90 group-hover:text-foreground transition-colors duration-300">
LexiChain
</span>
2026-02-17 00:14:38 +01:00
</a>
2026-04-19 01:42:00 +01:00
{/* Liens de Navigation avec animation de soulignement */}
<nav className="flex items-center gap-8 md:gap-12">
2026-02-17 00:14:38 +01:00
{navLinks.map((link) => (
<a
key={link.label}
href={link.href}
2026-04-19 01:42:00 +01:00
className="relative text-sm font-medium text-muted-foreground hover:text-foreground transition-colors duration-300 group py-1"
2026-02-17 00:14:38 +01:00
>
{link.label}
2026-04-19 01:42:00 +01:00
{/* Ligne d'animation au survol */}
<span className="absolute bottom-0 left-0 w-0 h-[2px] bg-primary transition-all duration-300 ease-out group-hover:w-full rounded-full" />
2026-02-17 00:14:38 +01:00
</a>
))}
</nav>
2026-04-19 01:42:00 +01:00
{/* Séparateur minimaliste */}
<div className="w-full max-w-md h-px bg-gradient-to-r from-transparent via-border to-transparent" />
2026-02-17 00:14:38 +01:00
2026-04-19 01:42:00 +01:00
{/* Section Inférieure (Copyright & Réseaux) */}
<div className="flex flex-col md:flex-row items-center justify-between w-full max-w-4xl gap-6">
<p className="text-sm font-medium text-muted-foreground/60 flex items-center gap-2">
<span className="w-2 h-2 rounded-full bg-primary/80 animate-pulse" />
© {new Date().getFullYear()} LexiChain. All rights reserved.
2026-02-14 21:47:08 +01:00
</p>
2026-02-17 00:14:38 +01:00
<div className="flex items-center gap-4">
2026-02-14 21:47:08 +01:00
<SocialIcon
icon={Twitter}
href="https://twitter.com"
label="Twitter"
/>
<SocialIcon
icon={Linkedin}
href="https://linkedin.com"
label="LinkedIn"
/>
2026-02-17 00:14:38 +01:00
<SocialIcon
icon={Github}
href="https://github.com"
label="GitHub"
/>
2026-02-14 21:47:08 +01:00
<SocialIcon
icon={Mail}
2026-02-17 00:14:38 +01:00
href="mailto:contact@lexichain.com"
2026-02-14 21:47:08 +01:00
label="Email"
/>
</div>
</div>
</div>
</div>
</footer>
);
}