stable state

This commit is contained in:
achraf
2026-04-01 00:41:31 +02:00
parent a4ee12732d
commit 8e62a0fa92
16 changed files with 779 additions and 565 deletions

View File

@@ -1,6 +1,5 @@
"use client";
import { useEffect, useRef } from "react";
import SafeImage from "./SafeImage";
interface ContactInfo {
@@ -18,21 +17,6 @@ interface ContactProps {
}
export default function Contact({ contact, fullName, image }: ContactProps) {
const ref = useRef<HTMLDivElement>(null);
useEffect(() => {
const el = ref.current;
if (!el) return;
const obs = new IntersectionObserver(
([entry]) => {
if (entry.isIntersecting) { el.classList.add("visible"); obs.disconnect(); }
},
{ threshold: 0.1 }
);
obs.observe(el);
return () => obs.disconnect();
}, []);
const links = [
{
label: "Email",
@@ -82,7 +66,7 @@ export default function Contact({ contact, fullName, image }: ContactProps) {
return (
<section id="contact" style={{ padding: "8rem 2rem" }}>
<div style={{ maxWidth: "1200px", margin: "0 auto" }}>
<div ref={ref} className="reveal">
<div>
<div className="section-label" style={{ marginBottom: "0.75rem" }}>Let&apos;s Connect</div>
<h2
className="font-display"
@@ -274,6 +258,7 @@ export default function Contact({ contact, fullName, image }: ContactProps) {
>
<div
className="font-mono"
suppressHydrationWarning
style={{
fontFamily: "var(--font-jetbrains), monospace",
fontSize: "0.62rem",