Files
anouma/components/Reveal.tsx
T
maro 45261a0461 Initial commit: ANOUMA website with Payload CMS, WebRTC meetings, and booking system
- Next.js 16 App Router site with the ANOUMA design system
- Payload CMS (PostgreSQL) for offers, events, posts and page content
- WebRTC video-call system with custom signaling server
- SMTP email reminders and booking-request notifications
- Customer accounts, calendar-based availability, and booking workflow
2026-08-25 16:40:51 +02:00

34 lines
803 B
TypeScript

"use client";
import { motion, type Variants } from "framer-motion";
import type { ReactNode } from "react";
const variants: Variants = {
hidden: { opacity: 0, y: 28 },
visible: { opacity: 1, y: 0 },
};
type RevealProps = {
children: ReactNode;
delay?: number;
className?: string;
as?: "div" | "li";
};
/** Fades and lifts content into place once it scrolls into view. */
export function Reveal({ children, delay = 0, className, as = "div" }: RevealProps) {
const Component = motion[as];
return (
<Component
initial="hidden"
whileInView="visible"
viewport={{ once: true, margin: "-80px" }}
variants={variants}
transition={{ duration: 0.7, delay, ease: [0.22, 1, 0.36, 1] }}
className={className}
>
{children}
</Component>
);
}