/* global React, Icon, Eyebrow, Reveal, Grain */ const { useState, useEffect, useRef } = React; function Testimonials() { const items = window.TB_PHOTOS.testimonials; const [idx, setIdx] = useState(0); const ref = useRef(null); // Auto-advance every 6s, pause on hover const [paused, setPaused] = useState(false); useEffect(() => { if (paused || window.matchMedia('(prefers-reduced-motion: reduce)').matches) return; const t = setInterval(() => setIdx((i) => (i + 1) % items.length), 6000); return () => clearInterval(t); }, [paused, items.length]); const item = items[idx]; return (
setPaused(true)} onMouseLeave={() => setPaused(false)} style={{ position: 'relative', background: 'transparent', color: 'var(--limestone)', padding: '140px 32px', overflow: 'hidden' }}> {/* Soft dark wash so the quote stays legible over the brick reveal */}
kind words
setIdx((idx - 1 + items.length) % items.length)} icon="chevron-left" /> setIdx((idx + 1) % items.length)} icon="chevron-right" />
{/* Two-column quote + photo */}
{item.quote}
{item.name} {item.meta}
{/* Dots */}
{items.map((_, i) => { const active = i === idx; return (
{/* Portrait paired with the current testimonial */}
{/* Frame badge */}
frame {String(idx + 12).padStart(3, '0')}
{/* Caption strip */}
{item.meta.split(' · ')[0]} kodak portra · 35mm
); } function NavBtn({ onClick, icon }) { const [hover, setHover] = useState(false); return ( ); } window.Testimonials = Testimonials;