{"version":3,"file":"NavButton.6IIi2Ho9.mjs","names":["useCallback"],"sources":["https:/framerusercontent.com/modules/pFsyKCgmBNt7Nt85fNCD/MYOKnKFffIadul0bXYqR/NavButton.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{motion}from\"framer-motion\";import{addPropertyControls,ControlType}from\"framer\";import{useCallback}from\"react\";/**\n * @framerDisableUnlink\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n * @framerIntrinsicWidth 100\n * @framerIntrinsicHeight 40\n */export default function NavButton(props){const{text,fontSize,fontFamily,fontWeight,color,lineThickness,lineGap,showArrow,link,newTab,smoothScroll,scrollOffset,style}=props;const handleClick=useCallback(e=>{if(!link)return;// Check if the link points to a section on the same page\nif(smoothScroll&&link.includes(\"#\")){e.preventDefault();const hash=link.split(\"#\").pop();if(!hash)return;// Framer renders scroll sections with data-framer-name\n// or as standard IDs — try multiple selectors\nconst element=document.getElementById(hash)||document.querySelector(`[id=\"${hash}\"]`)||document.querySelector(`[data-framer-name=\"${hash}\"]`);if(element){const top=element.getBoundingClientRect().top+window.scrollY-scrollOffset;window.scrollTo({top,behavior:\"smooth\"});}}else if(newTab){e.preventDefault();window.open(link,\"_blank\",\"noopener,noreferrer\");}},[link,newTab,smoothScroll,scrollOffset]);return /*#__PURE__*/_jsxs(motion.a,{href:link||undefined,onClick:handleClick,style:{...style,display:\"inline-flex\",flexDirection:\"column\",alignItems:\"flex-start\",gap:lineGap,cursor:\"pointer\",background:\"transparent\",textDecoration:\"none\"},initial:\"idle\",whileHover:\"hover\",children:[/*#__PURE__*/_jsxs(\"span\",{style:{fontFamily:fontFamily,fontWeight:fontWeight,fontSize:fontSize,color:color,lineHeight:1.2,letterSpacing:\"0.02em\",textTransform:\"uppercase\",whiteSpace:\"nowrap\"},children:[text,showArrow?\"  →\":\"\"]}),/*#__PURE__*/_jsx(motion.div,{style:{height:lineThickness,backgroundColor:color,borderRadius:lineThickness/2,originX:0,width:\"100%\"},variants:{idle:{scaleX:0},hover:{scaleX:1}},transition:{duration:.25,ease:[.25,.1,.25,1]}})]});}NavButton.defaultProps={text:\"HOME\",fontSize:24,fontFamily:\"Helvetica Neue, Helvetica, Arial, sans-serif\",fontWeight:400,color:\"#FFFFFF\",lineThickness:2,lineGap:6,showArrow:false,newTab:false,smoothScroll:true,scrollOffset:0};addPropertyControls(NavButton,{text:{type:ControlType.String,title:\"Text\",defaultValue:\"HOME\"},showArrow:{type:ControlType.Boolean,title:\"Arrow\",defaultValue:false,enabledTitle:\"Show\",disabledTitle:\"Hide\"},link:{type:ControlType.Link,title:\"Link\"},smoothScroll:{type:ControlType.Boolean,title:\"Smooth Scroll\",defaultValue:true,enabledTitle:\"On\",disabledTitle:\"Off\",description:\"Enable smooth scrolling for same-page section links.\"},scrollOffset:{type:ControlType.Number,title:\"Scroll Offset\",defaultValue:0,min:-500,max:500,step:10,unit:\"px\",description:\"Offset from the top of the section (useful for fixed headers).\",hidden:props=>!props.smoothScroll},newTab:{type:ControlType.Boolean,title:\"New Tab\",defaultValue:false,enabledTitle:\"Yes\",disabledTitle:\"No\"},fontSize:{type:ControlType.Number,title:\"Font Size\",defaultValue:24,min:10,max:120,step:1,unit:\"px\",displayStepper:true},fontFamily:{type:ControlType.String,title:\"Font Family\",defaultValue:\"Helvetica Neue, Helvetica, Arial, sans-serif\"},fontWeight:{type:ControlType.Enum,title:\"Font Weight\",options:[100,200,300,400,500,600,700,800,900],optionTitles:[\"Thin\",\"Extra Light\",\"Light\",\"Regular\",\"Medium\",\"Semi Bold\",\"Bold\",\"Extra Bold\",\"Black\"],defaultValue:400},color:{type:ControlType.Color,title:\"Color\",defaultValue:\"#FFFFFF\"},lineThickness:{type:ControlType.Number,title:\"Line Thickness\",defaultValue:2,min:1,max:10,step:.5,unit:\"px\"},lineGap:{type:ControlType.Number,title:\"Line Gap\",defaultValue:6,min:0,max:30,step:1,unit:\"px\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"NavButton\",\"slots\":[],\"annotations\":{\"framerIntrinsicWidth\":\"100\",\"framerIntrinsicHeight\":\"40\",\"framerSupportedLayoutHeight\":\"auto\",\"framerDisableUnlink\":\"* @framerSupportedLayoutWidth auto\",\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./NavButton.map"],"mappings":"gPAMG,SAAwB,EAAU,EAAM,CAAC,GAAK,CAAC,OAAK,WAAS,aAAW,aAAW,QAAM,gBAAc,UAAQ,YAAU,OAAK,SAAO,eAAa,eAAa,SAAO,EAAY,EAAYA,EAAY,GAAG,CAAK,KACrN,GAAG,GAAc,EAAK,SAAS,IAAI,CAAC,CAAC,EAAE,gBAAgB,CAAC,IAAM,EAAK,EAAK,MAAM,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,EAAK,OAElG,IAAM,EAAQ,SAAS,eAAe,EAAK,EAAE,SAAS,cAAc,QAAQ,EAAK,IAAI,EAAE,SAAS,cAAc,sBAAsB,EAAK,IAAI,CAAC,GAAG,EAAQ,CAAC,IAAM,EAAI,EAAQ,uBAAuB,CAAC,IAAI,EAAO,QAAQ,EAAa,EAAO,SAAS,CAAC,MAAI,SAAS,SAAS,CAAC,OAAW,IAAQ,EAAE,gBAAgB,CAAC,EAAO,KAAK,EAAK,SAAS,sBAAsB,GAAI,CAAC,EAAK,EAAO,EAAa,EAAa,CAAC,CAAC,OAAoB,EAAM,EAAO,EAAE,CAAC,KAAK,GAAM,IAAA,GAAU,QAAQ,EAAY,MAAM,CAAC,GAAG,EAAM,QAAQ,cAAc,cAAc,SAAS,WAAW,aAAa,IAAI,EAAQ,OAAO,UAAU,WAAW,cAAc,eAAe,OAAO,CAAC,QAAQ,OAAO,WAAW,QAAQ,SAAS,CAAc,EAAM,OAAO,CAAC,MAAM,CAAY,aAAsB,aAAoB,WAAe,QAAM,WAAW,IAAI,cAAc,SAAS,cAAc,YAAY,WAAW,SA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