{"version":3,"file":"AnimatedCounter.CE_ttpNt.mjs","names":["useRef","useState"],"sources":["https:/framerusercontent.com/modules/wIYdHm7FrkTZKQD56lBa/KPwgU5Huy0DQ7R97a6Xd/AnimatedCounter.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect,useRef,useState}from\"react\";import{addPropertyControls,ControlType,useInView}from\"framer\";/**\n * Animated Reveal (CMS-safe, empty by default)\n *\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n */export default function AnimatedReveal(props){const{content=\"\",font,color,duration=.6,delay=0,style}=props;const ref=useRef(null);const isInView=useInView(ref,{amount:.5,once:true});const[visible,setVisible]=useState(false);const hasContent=typeof content===\"string\"&&content.trim().length>0;useEffect(()=>{if(!isInView||!hasContent)return;const timeout=window.setTimeout(()=>{setVisible(true);},delay*1e3);return()=>clearTimeout(timeout);},[isInView,delay,hasContent]);// ✅ Render nothing if CMS has no value\nif(!hasContent)return null;return /*#__PURE__*/_jsx(\"div\",{ref:ref,style:{...style,display:\"inline-block\",width:\"max-content\",minWidth:1,minHeight:1,transform:visible?\"scale(1)\":\"scale(0.85)\",opacity:visible?1:0,transition:`transform ${duration}s cubic-bezier(0.4, 0, 0.2, 1),\n                             opacity ${duration}s cubic-bezier(0.4, 0, 0.2, 1)`,userSelect:\"none\",willChange:\"transform, opacity\"},\"aria-live\":\"polite\",children:/*#__PURE__*/_jsx(\"span\",{style:{...font,color},children:content})});}addPropertyControls(AnimatedReveal,{content:{type:ControlType.String,title:\"Content (CMS)\",defaultValue:\"\",placeholder:\"Emoji / text from CMS\"},font:{type:ControlType.Font,title:\"Text style\",controls:\"extended\",defaultFontType:\"sans-serif\",defaultValue:{fontSize:\"40px\",fontWeight:700,lineHeight:\"1em\"},useGlobalTextStyles:true},color:{type:ControlType.Color,title:\"Color\",defaultValue:\"#000000\"},duration:{type:ControlType.Number,title:\"Duration\",defaultValue:.6,min:.1,max:5,step:.1,unit:\"s\"},delay:{type:ControlType.Number,title:\"Delay\",defaultValue:0,min:0,max:5,step:.1,unit:\"s\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"AnimatedReveal\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutWidth\":\"auto\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"auto\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./AnimatedCounter.map"],"mappings":"gPAKG,SAAwB,EAAe,EAAM,CAAC,GAAK,CAAC,UAAQ,GAAG,OAAK,QAAM,WAAS,GAAG,QAAM,EAAE,SAAO,EAAY,EAAIA,EAAO,KAAK,CAAO,EAAS,EAAU,EAAI,CAAC,OAAO,GAAG,KAAK,GAAK,CAAC,CAAM,CAAC,EAAQ,GAAYC,EAAS,GAAM,CAAO,EAAW,OAAO,GAAU,UAAU,EAAQ,MAAM,CAAC,OAAO,EAC1Q,OAD4Q,MAAc,CAAC,GAAG,CAAC,GAAU,CAAC,EAAW,OAAO,IAAM,EAAQ,EAAO,eAAe,CAAC,EAAW,GAAK,EAAG,EAAM,IAAI,CAAC,UAAU,aAAa,EAAQ,EAAG,CAAC,EAAS,EAAM,EAAW,CAAC,CACpd,EAA2C,EAAK,MAAM,CAAK,MAAI,MAAM,CAAC,GAAG,EAAM,QAAQ,eAAe,MAAM,cAAc,SAAS,EAAE,UAAU,EAAE,UAAU,EAAQ,WAAW,cAAc,QAAQ,EAAQ,EAAE,EAAE,WAAW,aAAa,EAAS;uCAC9M,EAAS,gCAAgC,WAAW,OAAO,WAAW,qBAAqB,CAAC,YAAY,SAAS,SAAsB,EAAK,OAAO,CAAC,MAAM,CAAC,GAAG,EAAK,QAAM,CAAC,SAAS,EAAQ,CAAC,CAAC,CAAC,CAD/M,0BANqB,IAA6C,IAA8D,CAOiF,EAAoB,EAAe,CAAC,QAAQ,CAAC,KAAK,EAAY,OAAO,MAAM,gBAAgB,aAAa,GAAG,YAAY,wBAAwB,C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