{"version":3,"file":"ScrollDown.nBAFgF48.mjs","names":["useRef","__esmMin","init_npm_react_18_3_1","init_ssg_sandbox_shims","window","p","c","init_jsx_runtime","de","init_framer_DKtAEkcX","ControlType","addPropertyControls","ScrollDown","props","ref","el","target","fullWidth","tallEnough","top","style","fontSize","label","init_ScrollDown"],"sources":["https:/framerusercontent.com/modules/8Z9hiBZ82AVvONOvJeRg/W8VRt0mCy4jOhwh7QMX1/ScrollDown.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{useRef}from\"react\";import{addPropertyControls,ControlType}from\"framer\";/**\n * \"↓ SCROLL\" button. On click it smoothly scrolls to the section below the one it sits in.\n * Works for sections of any height (full-screen or shorter heroes).\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n */export default function ScrollDown(props){const{label,color,fontSize,gap,style}=props;const ref=useRef(null);const onClick=()=>{if(typeof window===\"undefined\")return;let el=ref.current;let target=null;// Find the surrounding section: the nearest full-width ancestor\n// that has a section after it and is reasonably tall.\nwhile(el&&el!==document.body){const fullWidth=el.offsetWidth>=window.innerWidth*.9;const tallEnough=el.offsetHeight>=window.innerHeight*.3;if(fullWidth&&tallEnough&&el.nextElementSibling){target=el;break;}el=el.parentElement;}const top=target?target.getBoundingClientRect().bottom+window.scrollY:window.scrollY+window.innerHeight;window.scrollTo({top,behavior:\"smooth\"});};return /*#__PURE__*/_jsxs(\"button\",{ref:ref,onClick:onClick,\"aria-label\":\"Scroll to next section\",style:{display:\"inline-flex\",alignItems:\"center\",gap,background:\"none\",border:\"none\",padding:0,margin:0,cursor:\"pointer\",color,fontFamily:\"Inter, sans-serif\",fontWeight:600,fontSize,lineHeight:1.2,letterSpacing:\"0.12em\",textTransform:\"uppercase\",whiteSpace:\"nowrap\",...style},children:[/*#__PURE__*/_jsxs(\"svg\",{width:fontSize*1.25,height:fontSize*1.25,viewBox:\"0 0 24 24\",fill:\"none\",stroke:\"currentColor\",strokeWidth:\"2\",strokeLinecap:\"round\",strokeLinejoin:\"round\",\"aria-hidden\":\"true\",children:[/*#__PURE__*/_jsx(\"path\",{d:\"M12 4v16\"}),/*#__PURE__*/_jsx(\"path\",{d:\"M5 13l7 7 7-7\"})]}),/*#__PURE__*/_jsx(\"span\",{children:label})]});}ScrollDown.defaultProps={label:\"Scroll\",color:\"#FFFFFF\",fontSize:16,gap:12};addPropertyControls(ScrollDown,{label:{type:ControlType.String,title:\"Label\",defaultValue:\"Scroll\"},color:{type:ControlType.Color,title:\"Color\",defaultValue:\"#FFFFFF\"},fontSize:{type:ControlType.Number,title:\"Size\",defaultValue:16,min:10,max:40,unit:\"px\"},gap:{type:ControlType.Number,title:\"Gap\",defaultValue:12,min:0,max:40,unit:\"px\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ScrollDown\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"auto\",\"framerSupportedLayoutWidth\":\"auto\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./ScrollDown.map"],"mappings":"A,+LAKG,SAAwBY,EAAW,EAAM,CAAC,GAAK,CAAC,QAAM,QAAM,WAAS,MAAI,SAAOC,EAAYC,EAAId,EAAO,IAAI,EAEuQ,MAAoB,gBAAM,SAAS,CAAK,MAAY,YAFvS,CAAC,GAAUI,IAAS,OAAY,OAAO,IAAIW,EAAGD,EAAI,QAAYE,EAAO,KAEvM,KAAMD,GAAIA,IAAK,SAAS,MAAK,CAAC,IAAME,EAAUF,EAAG,aAAaX,EAAO,WAAW,GAASc,EAAWH,EAAG,cAAcX,EAAO,YAAY,GAAG,GAAGa,GAAWC,GAAYH,EAAG,mBAAmB,CAAC,EAAOA,EAAG,KAAM,CAAC,EAAGA,EAAG,aAAc,CAAC,IAAMI,EAAIH,EAAOA,EAAO,sBAAsB,CAAC,CAAC,OAAOZ,EAAO,QAAQA,EAAO,QAAQA,EAAO,YA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