import { useState } from 'react' import { Chevron } from './Icons.jsx' const PAGES = [ { title: 'Honoring the story of childhood', image: '/images/book-slide1.jpg', alt: 'Students dancing together in the school gym', body: ( <> We know the earliest chapters of a child’s life are among the most important and influential.{' '} Our PreK-8 model celebrates every formative moment, beginning with our Early School’s Montessori commitment to independent and impassioned learning. Here, students are allowed to be children a little longer and empowered to{' '} be leaders a little sooner. Then they graduate confident, compassionate, and prepared to go anywhere from here. ), }, { title: 'A community of storytellers', image: '/images/gallery1.jpg', alt: 'Athletes celebrating together after a game', body: ( <> Every Prep student belongs to a close-knit community where teachers, coaches, and classmates cheer each chapter forward. From athletics to{' '} the arts, our students discover their voices in classrooms and on stages, courts, and fields. Small classes mean every child is deeply known—and every triumph, large or small, is celebrated together. ), }, { title: 'A campus built for wonder', image: '/images/gallery2.jpg', alt: 'Aerial view of the Charlotte Prep campus in autumn', body: ( <> Tucked into a wooded corner of Charlotte, our campus invites exploration at every turn. Light-filled classrooms, modern learning spaces, gardens, and play areas give students room to imagine, build, and grow. It is a place designed for{' '} hands-on discovery—where every corner holds the beginning of a new story. ), }, ] export default function BookCarousel() { const [index, setIndex] = useState(0) const page = PAGES[index] const step = (dir) => setIndex((i) => (i + dir + PAGES.length) % PAGES.length) return (
{PAGES.map((p, i) => (
) }