{"version":3,"file":"HeroSlideshow.BOVI9irr.mjs","names":["useState","__esmMin","te","_e","p","c","init_jsx_runtime","init_npm_react_18_3_1","ce","motion","AnimatePresence","init_framer_motion_DhsWWWsN","RenderTarget","init_framer_Cb9Z_4vX","addPropertyControls","ControlType","HeroSlideshow","props","currentIndex","setCurrentIndex","shouldPause","pauseOnCanvas","images","interval","prev","cycleDuration","currentImage","zoomScale","transitionDuration","overlayOpacity","init_HeroSlideshow"],"sources":["https:/framerusercontent.com/modules/bHGXzDvj6TwNAr06WqsO/HN2deZuVjpzjwsHIlfO2/HeroSlideshow.js"],"sourcesContent":["// Full-screen hero slideshow with auto-cycling images and zoom effect\n// Images take full 1fr width and 100vh height across all breakpoints\n// Configurable cycle time and zoom animation\n// Images maintain full coverage with object-fit: cover\nimport{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{useState,useEffect,startTransition}from\"react\";import{addPropertyControls,ControlType,RenderTarget}from\"framer\";import{motion,AnimatePresence}from\"framer-motion\";/**\n * @framerSupportedLayoutWidth any\n * @framerSupportedLayoutHeight any\n */export default function HeroSlideshow(props){const{images=[{image:{src:\"https://framerusercontent.com/images/f9RiWoNpmlCMqVRIHz8l8wYfeI.jpg\",alt:\"Gradient 5 - Green\"}}],cycleDuration=5,zoomScale=1.1,transitionDuration=1,pauseOnCanvas=false,overlayOpacity=0}=props;const[currentIndex,setCurrentIndex]=useState(0);const isCanvas=RenderTarget.current()===RenderTarget.canvas;const shouldPause=isCanvas&&pauseOnCanvas;useEffect(()=>{if(images.length<=1||shouldPause)return;const interval=setInterval(()=>{startTransition(()=>{setCurrentIndex(prev=>(prev+1)%images.length);});},cycleDuration*1e3);return()=>clearInterval(interval);},[images.length,cycleDuration,shouldPause]);const currentImage=images[currentIndex]?.image||{src:\"https://framerusercontent.com/images/f9RiWoNpmlCMqVRIHz8l8wYfeI.jpg\",alt:\"Default image\"};return /*#__PURE__*/_jsxs(\"div\",{style:{width:\"100%\",height:\"100vh\",position:\"relative\",overflow:\"hidden\",...props.style},children:[/*#__PURE__*/_jsx(AnimatePresence,{initial:true,children:/*#__PURE__*/_jsx(motion.div,{initial:{opacity:1,scale:1},animate:{opacity:1,scale:zoomScale},exit:{opacity:0},transition:{opacity:{duration:transitionDuration,ease:\"easeInOut\"},scale:{duration:cycleDuration,ease:\"linear\"}},style:{position:\"absolute\",top:0,left:0,width:\"100%\",height:\"100%\"},children:/*#__PURE__*/_jsx(\"img\",{src:currentImage.src,alt:currentImage.alt,style:{width:\"100%\",height:\"100%\",objectFit:\"cover\",objectPosition:\"center\"}})},currentIndex)}),overlayOpacity>0&&/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",top:0,left:0,width:\"100%\",height:\"100%\",backgroundColor:\"#000000\",opacity:overlayOpacity,pointerEvents:\"none\"}})]});}addPropertyControls(HeroSlideshow,{images:{type:ControlType.Array,title:\"Images\",control:{type:ControlType.Object,controls:{image:{type:ControlType.ResponsiveImage,title:\"Image\"}}},defaultValue:[{image:{src:\"https://framerusercontent.com/images/f9RiWoNpmlCMqVRIHz8l8wYfeI.jpg\",alt:\"Gradient 5 - Green\"}},{image:{src:\"https://framerusercontent.com/images/2uTNEj5aTl2K3NJaEFWMbnrA.jpg\",alt:\"Gradient 4 - Yellow\"}},{image:{src:\"https://framerusercontent.com/images/BYnxEV1zjYb9bhWh1IwBZ1ZoS60.jpg\",alt:\"Gradient 3 - Orange\"}}]},cycleDuration:{type:ControlType.Number,title:\"Cycle Time\",defaultValue:5,min:2,max:30,step:.5,unit:\"s\",displayStepper:true},zoomScale:{type:ControlType.Number,title:\"Zoom Scale\",defaultValue:1.1,min:1,max:1.5,step:.05},transitionDuration:{type:ControlType.Number,title:\"Fade Duration\",defaultValue:1,min:.3,max:3,step:.1,unit:\"s\"},pauseOnCanvas:{type:ControlType.Boolean,title:\"Pause on Canvas\",defaultValue:false,enabledTitle:\"Paused\",disabledTitle:\"Playing\"},overlayOpacity:{type:ControlType.Number,title:\"Overlay Darkness\",defaultValue:0,min:0,max:.8,step:.05,displayStepper:false}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"HeroSlideshow\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutWidth\":\"any\",\"framerSupportedLayoutHeight\":\"any\",\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./HeroSlideshow.map"],"mappings":"A,+PAOG,SAAwBgB,EAAc,EAAM,CAAC,GAAK,CAAC,SAAO,CAAC,CAAC,MAAM,CAAC,IAAI,sEAAsE,IAAI,oBAAoB,CAAC,CAAC,EAAE,gBAAc,EAAE,YAAU,IAAI,qBAAmB,EAAE,gBAAc,GAAM,iBAAe,GAAGC,EAAW,CAACC,EAAaC,GAAiBnB,EAAS,CAAC,EAAoEoB,EAAnDR,EAAa,QAAQ,IAAIA,EAAa,QAAmCS,EAAcb,MAAc,CAAC,GAAGc,EAAO,QAAQ,GAAGF,EAAY,OAAO,IAAMG,EAAS,gBAAgB,CAACrB,MAAoB,CAACiB,EAAgB,IAAOK,EAAK,GAAGF,EAAO,MAAM,CAAE,CAAC,CAAE,EAAEG,EAAc,GAAG,EAAE,UAAU,cAAcF,CAAQ,CAAE,EAAE,CAACD,EAAO,OAAOG,EAAcL,CAAW,CAAC,EAAE,IAAMM,EAAaJ,EAAOJ,EAAa,EAAE,OAAO,CAAC,IAAI,sEAAsE,IAAI,eAAe,EAAE,MAAoB,gBAAM,MAAM,CAAC,MAAM,CAAC,MAAM,OAAO,OAAO,QAAQ,SAAS,WAAW,SAAS,SAAS,GAAGD,EAAM,KAAK,EAAE,SAAS,CAAc,gBAAKP,EAAgB,CAAC,QAAQ,GAAK,SAAsB,gBAAKD,EAAO,IAAI,CAAC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC,EAAE,QAAQ,CAAC,QAAQ,EAAE,MAAMkB,CAAS,EAAE,KAAK,CAAC,QAAQ,CAAC,EAAE,WAAW,CAAC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