{"version":3,"file":"Progress.CPWDa4Mn.mjs","names":["useRef"],"sources":["https:/framerusercontent.com/modules/D9O5nu2ySgSPt7CvrW3q/xvzyM0q4apnEBcsQOpMG/Progress.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{motion,useAnimation}from\"framer-motion\";import{useEffect,useRef}from\"react\";import{addPropertyControls,ControlType}from\"framer\";// ProgressBar component\nexport default function ProgressBar({percent,duration,easing,color}){const controls=useAnimation();const progressRef=useRef();// This triggers the animation when the component scrolls into view\nuseEffect(()=>{const observer=new IntersectionObserver(([entry])=>{if(entry.isIntersecting){controls.start({width:`${percent}%`});}},{threshold:.5});if(progressRef.current){observer.observe(progressRef.current);}return()=>{if(progressRef.current){observer.unobserve(progressRef.current);}};},[controls,percent]);return /*#__PURE__*/_jsx(\"div\",{style:containerStyle,children:/*#__PURE__*/_jsx(motion.div,{ref:progressRef,initial:{width:\"0%\"},animate:controls,transition:{duration:duration,ease:easing},style:{...progressBarStyle,backgroundColor:color}})});}// Add property controls to edit percent, duration, easing, and color in Framer\naddPropertyControls(ProgressBar,{percent:{type:ControlType.Number,title:\"Percent\",defaultValue:50,min:0,max:100},duration:{type:ControlType.Number,title:\"Duration\",defaultValue:1.5,min:.1,max:10,unit:\"s\"},easing:{type:ControlType.Enum,title:\"Easing\",options:[\"easeIn\",\"easeOut\",\"easeInOut\",\"linear\",\"easeInCirc\",\"easeOutCirc\"],optionTitles:[\"Ease In\",\"Ease Out\",\"Ease In Out\",\"Linear\",\"Ease In Circ\",\"Ease Out Circ\"],defaultValue:\"easeInOut\"},color:{type:ControlType.Color,title:\"Color\",defaultValue:\"#3b82f6\"}});// Styles\nconst containerStyle={width:\"100%\",height:\"30px\",backgroundColor:\"#e0e0df\",borderRadius:\"15px\",overflow:\"hidden\"};const progressBarStyle={height:\"100%\",borderRadius:\"15px\"};\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ProgressBar\",\"slots\":[],\"ann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