'use client' import { useEffect, useMemo, useState } from 'react' import { useResponsiveCarousel } from '@/hooks/useResponsiveCarousel'; import Image from 'next/image' import { motion, AnimatePresence } from 'framer-motion' import { wrap } from 'popmotion' import { Button } from '@/components/Button'; import { H2, P, CT } from '@/components/Texts'; import { TypeAnimation } from 'react-type-animation' import { FadeIn } from './FadeIn'; const galleryItems = [ { text: 'Navigate and interact with any web interface', image: '/images/gallery/interface.jpg', width: 448, height: 277 }, { text: 'Process documents across all formats', image: '/images/gallery/docs.jpg', width: 448, height: 277 }, { text: 'Execute multi-step workflows autonomously', image: '/images/gallery/flow.jpg', width: 448, height: 277 }, { text: 'Manage calendars, emails, and tasks', image: '/images/gallery/calendar.jpg', width: 448, height: 277 }, { text: 'Perform deep semantic search across all data sources', image: '/images/gallery/data.jpg', width: 448, height: 277 }, { text: 'Identify patterns in complex datasets', image: '/images/gallery/datasets.jpg', width: 448, height: 277 }, { text: 'Provide real-time market intelligence', image: '/images/gallery/market.jpg', width: 448, height: 277 }, { text: 'Generate and debug code in multiple languages', image: '/images/gallery/code.jpg', width: 448, height: 277 }, { text: 'Create consistent branded content', image: '/images/gallery/branding.jpg', width: 448, height: 277 }, { text: 'Translate and localize materials', image: '/images/gallery/translate.jpg', width: 448, height: 277 }, { text: 'Transform and migrate data structures', image: '/images/gallery/structure.jpg', width: 448, height: 277 }, ] // đź”§ Carousel Config const VISIBLE = 4; const AUTOPLAY_MS = 3200; export function ClickableGallery() { const [active, setActive] = useState(0); const [hovering, setHovering] = useState(false); const { GAP, ROT_Y, DEPTH, SCALE_DROP } = useResponsiveCarousel(); // autoplay useEffect(() => { if (hovering) return const id = setInterval(() => setActive((i) => wrap(0, galleryItems.length, i + 1)), AUTOPLAY_MS) return () => clearInterval(id) }, [hovering]) const indices = useMemo( () => [...Array(VISIBLE * 2 + 1)].map((_, i) => wrap(0, galleryItems.length, active + i - VISIBLE)), [active] ) const next = () => setActive((i) => wrap(0, galleryItems.length, i + 1)) const prev = () => setActive((i) => wrap(0, galleryItems.length, i - 1)) return (
Your private agent coordinates a team of specialists that spin up on demand, collaborate across your world, and deliver end-to-end results. Many agents, one intelligence—yours.