{"version":3,"file":"SnapScrollCSS.AlV8C2V2.mjs","names":["useRef"],"sources":["https:/framerusercontent.com/modules/naQv9vEl1YuLwFEaQLZc/qKAy5l00KBfduUQ3vLvi/SnapScrollCSS.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect,useRef}from\"react\";// Apply to Desktop (the page container)\nexport function withScrollSnapContainer(Component){return props=>{useEffect(()=>{document.documentElement.style.scrollSnapType=\"y mandatory\";window.scrollTo(0,0);let timeout;const handleScroll=()=>{document.documentElement.style.pointerEvents=\"none\";clearTimeout(timeout);timeout=window.setTimeout(()=>{document.documentElement.style.pointerEvents=\"auto\";},150);};window.addEventListener(\"scroll\",handleScroll,{passive:true});return()=>{window.removeEventListener(\"scroll\",handleScroll);clearTimeout(timeout);};},[]);return /*#__PURE__*/_jsx(Component,{...props});};}// Apply to each Stack (full-page sections)\nexport function withScrollSnapStartItem(Component){return props=>{const ref=useRef(null);useEffect(()=>{const el=ref.current;if(!el)return;el.style.scrollSnapAlign=\"start\";el.style.height=\"100vh\";},[]);return /*#__PURE__*/_jsx(Component,{...props,ref:ref});};}// Apply to each Stack (full-page sections)\nexport function withScrollSnapEndItem(Component){return props=>{const ref=useRef(null);useEffect(()=>{const el=ref.current;if(!el)return;el.style.scrollSnapAlign=\"end\";},[]);return /*#__PURE__*/_jsx(Component,{...props,ref:ref});};}// Apply to each Stack (full-page sections)\nexport function withScrollSnapFooter(Component){return props=>{const ref=useRef(null);useEffect(()=>{const el=ref.current;if(!el)return;el.style.scrollSnapAlign=\"start\";},[]);return /*#__PURE__*/_jsx(Component,{...props,ref:ref});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withScrollSnapStartItem\":{\"type\":\"reactHoc\",\"name\":\"withScrollSnapStartItem\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withScrollSnapContainer\":{\"type\":\"reactHoc\",\"name\":\"withScrollSnapContainer\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withScrollSnapFooter\":{\"type\":\"reactHoc\",\"name\":\"withScrollSnapFooter\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withScrollSnapEndItem\":{\"type\":\"reactHoc\",\"name\":\"withScrollSnapEndItem\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./SnapScrollCSS.map"],"mappings":"kIACA,SAAgB,EAAwB,EAAU,CAAC,MAAO,KAAQ,MAAc,CAAC,SAAS,gBAAgB,MAAM,eAAe,cAAc,EAAO,SAAS,EAAE,EAAE,CAAC,IAAI,EAAc,MAAiB,CAAC,SAAS,gBAAgB,MAAM,cAAc,OAAO,aAAa,EAAQ,CAAC,EAAQ,EAAO,eAAe,CAAC,SAAS,gBAAgB,MAAM,cAAc,QAAS,IAAI,EAAiE,OAA9D,EAAO,iBAAiB,SAAS,EAAa,CAAC,QAAQ,GAAK,CAAC,KAAW,CAAC,EAAO,oBAAoB,SAAS,EAAa,CAAC,aAAa,EAAQ,GAAK,EAAE,CAAC,CAAqB,EAAK,EAAU,CAAC,GAAG,EAAM,CAAC,EACnjB,SAAgB,EAAwB,EAAU,CAAC,MAAO,IAAO,CAAC,IAAM,EAAIA,EAAO,KAAK,CAAkH,OAAjH,MAAc,CAAC,IAAM,EAAG,EAAI,QAAY,IAAU,EAAG,MAAM,gBAAgB,QAAQ,EAAG,MAAM,OAAO,UAAU,EAAE,CAAC,CAAqB,EAAK,EAAU,CAAC,GAAG,EAAU,MAAI,CAAC,EAChQ,SAAgB,EAAsB,EAAU,CAAC,MAAO,IAAO,CAAC,IAAM,EAAIA,EAAO,KAAK,CAAwF,OAAvF,MAAc,CAAC,IAAM,EAAG,EAAI,QAAY,IAAU,EAAG,MAAM,gBAAgB,QAAQ,EAAE,CAAC,CAAqB,EAAK,EAAU,CAAC,GAAG,EAAU,MAAI,CAAC,EACpO,SAAgB,EAAqB,EAAU,CAAC,MAAO,IAAO,CAAC,IAAM,EAAIA,EAAO,KAAK,CAA0F,OAAzF,MAAc,CAAC,IAAM,EAAG,EAAI,QAAY,IAAU,EAAG,MAAM,gBAAgB,UAAU,EAAE,CAAC,CAAqB,EAAK,EAAU,CAAC,GAAG,EAAU,MAAI,CAAC,uBAJ1L,IAAoC"}