import SectionContainer from '~/components/Layouts/SectionContainer' import { getAnimation, INITIAL_BOTTOM } from '~/lib/animations' import { domAnimation, LazyMotion, m, useInView } from 'framer-motion' import { ArrowUpRight } from 'lucide-react' import Link from 'next/link' import { ReactNode, useRef } from 'react' import ReactMarkdown from 'react-markdown' import { Button, cn } from 'ui' interface Feature { icon: string title: string text: string } interface Props { id?: string title: string | ReactNode paragraph: string cta?: { label?: string link: string } features?: Feature[] className?: string hasStickyTitle?: boolean } const FeaturesSection = ({ id, title, paragraph, cta, features, className, hasStickyTitle, }: Props) => { const ref = useRef(null) const isInView = useInView(ref, { margin: '-5%', once: true }) return (

{title}

{paragraph}

{cta && ( )}
{features && (
{features.map((feature: Feature, i: number) => ( ))}
)}
) } const Feature = ({ feature, index, isInView, }: { feature: Feature index: number isInView: boolean }) => { const initial = INITIAL_BOTTOM const animate = getAnimation({ delay: index * 0.1 }) return ( {feature.icon && (
)}

{feature.title}

{feature.text}
) } export default FeaturesSection