{"version":3,"file":"WithGoogleMapsLink.Z2fdkRlf.mjs","names":["useRef"],"sources":["https:/framerusercontent.com/modules/3li0z76H1jHsjrgJVzLT/2Rr2aSb3XSmkNH3gokfX/WithGoogleMapsLink.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect,useRef}from\"react\";/**\n * @framerDisableUnlink\n */export function withGoogleMapsLink(Component){return props=>{const containerRef=useRef(null);useEffect(()=>{if(containerRef.current){// Find the first link inside the container\nconst linkElement=containerRef.current.querySelector(\"a\");if(linkElement){console.log(\"Found link:\",linkElement);const text=linkElement.textContent;console.log(\"Link text:\",text);if(text){const encodedText=encodeURIComponent(text);const googleMapsHref=`http://maps.google.com/?q=${encodedText}`;console.log(\"Setting href to:\",googleMapsHref);// Update the href\nlinkElement.href=googleMapsHref;}}else{console.log(\"No link found inside container\");}}},[]);return /*#__PURE__*/_jsx(Component,{...props,ref:containerRef});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withGoogleMapsLink\":{\"type\":\"reactHoc\",\"name\":\"withGoogleMapsLink\",\"annotations\":{\"framerDisableUnlink\":\"\",\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./WithGoogleMapsLink.map"],"mappings":"yHAEG,SAAgB,EAAmB,EAAU,CAAC,MAAO,IAAO,CAAC,IAAM,EAAaA,EAAO,IAAI,EAED,OAFG,MAAc,CAAC,GAAG,EAAa,QAAQ,CACvI,IAAM,EAAY,EAAa,QAAQ,cAAc,GAAG,EAAE,GAAG,EAAY,CAAC,QAAQ,IAAI,cAAc,CAAW,EAAE,IAAM,EAAK,EAAY,YAA2C,GAA/B,QAAQ,IAAI,aAAa,CAAI,EAAK,EAAK,CAA4C,IAAM,EAAe,6BAA9C,mBAAmB,CAAkE,IAAI,QAAQ,IAAI,mBAAmB,CAAc,EACpV,EAAY,KAAK,CAAe,CAAC,MAAM,QAAQ,IAAI,gCAAgC,CAAG,CAAC,EAAE,CAAC,CAAC,EAAsB,EAAK,EAAU,CAAC,GAAG,EAAM,IAAI,CAAY,CAAC,CAAE,CAAE,iBAJrH,IAAoC"}