{"version":3,"file":"URL_CODE.CsL2Os-a.mjs","names":["useState","useRef"],"sources":["https:/framerusercontent.com/modules/p9vEBwLhfZlPpVIZ48wB/P4VEmEktoPGcDC9lnMSg/Currency_Selector.js","https:/framerusercontent.com/modules/TqTlc6xpN9mhtu3zQVly/ciA9DkBD2L2LkGeuYMld/URL_CODE.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useState,useRef,useEffect}from\"react\";/**\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n */export default function PriceCurrency(props){const{priceGBP,priceEUR,priceUSD,priceAUS,priceCAD,priceSize,priceColor,fontFamily,style}=props;const[currency,setCurrency]=useState(\"GBP\");const[isOpen,setIsOpen]=useState(false);const dropdownRef=useRef(null);const currencies={GBP:{symbol:\"\\xa3\",price:priceGBP,code:\"GBP\"},EUR:{symbol:\"€\",price:priceEUR,code:\"EUR\"},USD:{symbol:\"$\",price:priceUSD,code:\"USD\"},AUS:{symbol:\"$\",price:priceAUS,code:\"AUS\"},CAD:{symbol:\"$\",price:priceCAD,code:\"CAD\"}};const current=currencies[currency];// Close on outside click + Escape key\nuseEffect(()=>{function handleClickOutside(e){if(dropdownRef.current&&!dropdownRef.current.contains(e.target)){setIsOpen(false);}}function handleEscape(e){if(e.key===\"Escape\")setIsOpen(false);}document.addEventListener(\"mousedown\",handleClickOutside);document.addEventListener(\"keydown\",handleEscape);return()=>{document.removeEventListener(\"mousedown\",handleClickOutside);document.removeEventListener(\"keydown\",handleEscape);};},[]);return /*#__PURE__*/_jsxs(\"div\",{style:{display:\"inline-flex\",alignItems:\"center\",gap:14,fontFamily,...style},children:[/*#__PURE__*/_jsxs(\"div\",{style:{fontSize:priceSize,fontWeight:700,color:priceColor,lineHeight:1,letterSpacing:\"-0.02em\",fontVariantNumeric:\"tabular-nums\"},children:[current.symbol,current.price.toFixed(2)]}),/*#__PURE__*/_jsxs(\"div\",{ref:dropdownRef,style:{position:\"relative\",userSelect:\"none\"},children:[/*#__PURE__*/_jsxs(\"button\",{onClick:()=>setIsOpen(!isOpen),style:{display:\"flex\",alignItems:\"center\",gap:6,padding:\"8px 12px\",background:isOpen?\"rgba(0,0,0,0.08)\":\"rgba(0,0,0,0.04)\",border:\"none\",borderRadius:10,fontSize:14,fontWeight:500,fontFamily:\"inherit\",color:\"#242626\",cursor:\"pointer\",transition:\"background 0.15s ease\"},onMouseEnter:e=>{if(!isOpen)e.currentTarget.style.background=\"rgba(0,0,0,0.06)\";},onMouseLeave:e=>{if(!isOpen)e.currentTarget.style.background=\"rgba(0,0,0,0.04)\";},children:[/*#__PURE__*/_jsxs(\"span\",{children:[current.symbol,\" \",current.code]}),/*#__PURE__*/_jsx(\"svg\",{width:\"10\",height:\"6\",viewBox:\"0 0 10 6\",fill:\"none\",style:{transform:isOpen?\"rotate(180deg)\":\"rotate(0deg)\",transition:\"transform 0.2s ease\",opacity:.6},children:/*#__PURE__*/_jsx(\"path\",{d:\"M1 1L5 5L9 1\",stroke:\"currentColor\",strokeWidth:\"1.5\",strokeLinecap:\"round\",strokeLinejoin:\"round\"})})]}),isOpen&&/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",top:\"calc(100% + 6px)\",left:0,minWidth:140,background:\"rgba(255,255,255,0.82)\",backdropFilter:\"blur(20px) saturate(180%)\",WebkitBackdropFilter:\"blur(20px) saturate(180%)\",border:\"0.5px solid rgba(0,0,0,0.08)\",borderRadius:12,boxShadow:\"0 10px 30px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.04)\",overflow:\"hidden\",padding:4,zIndex:1e3,animation:\"fadeSlide 0.15s ease-out\"},children:Object.keys(currencies).map(code=>{const isActive=currency===code;return /*#__PURE__*/_jsxs(\"button\",{onClick:()=>{setCurrency(code);setIsOpen(false);},style:{display:\"flex\",alignItems:\"center\",width:\"100%\",padding:\"9px 12px\",background:isActive?\"rgba(0,0,0,0.05)\":\"transparent\",border:\"none\",borderRadius:8,fontSize:14,fontWeight:500,fontFamily:\"inherit\",color:\"#242626\",cursor:\"pointer\",textAlign:\"left\",transition:\"background 0.1s ease\"},onMouseEnter:e=>{if(!isActive)e.currentTarget.style.background=\"rgba(0,0,0,0.04)\";},onMouseLeave:e=>{if(!isActive)e.currentTarget.style.background=\"transparent\";},children:[currencies[code].symbol,\" \",currencies[code].code]},code);})})]}),/*#__PURE__*/_jsx(\"style\",{children:`\n                @keyframes fadeSlide {\n                    from { opacity: 0; transform: translateY(-4px); }\n                    to { opacity: 1; transform: translateY(0); }\n                }\n            `})]});}PriceCurrency.defaultProps={priceGBP:25,priceEUR:29,priceUSD:32,priceAUS:49,priceCAD:43,priceSize:56,priceColor:\"#000000\",fontFamily:\"DM Sans, -apple-system, BlinkMacSystemFont, sans-serif\"};addPropertyControls(PriceCurrency,{priceGBP:{type:ControlType.Number,title:\"\\xa3 GBP\",defaultValue:25,min:0,step:.01,displayStepper:true},priceEUR:{type:ControlType.Number,title:\"€ EUR\",defaultValue:29,min:0,step:.01,displayStepper:true},priceUSD:{type:ControlType.Number,title:\"$ USD\",defaultValue:32,min:0,step:.01,displayStepper:true},priceAUS:{type:ControlType.Number,title:\"$ AUS\",defaultValue:49,min:0,step:.01,displayStepper:true},priceCAD:{type:ControlType.Number,title:\"$ CAD\",defaultValue:43,min:0,step:.01,displayStepper:true},priceSize:{type:ControlType.Number,title:\"Price size\",defaultValue:56,min:12,max:120},priceColor:{type:ControlType.Color,title:\"Price color\",defaultValue:\"#000000\"},fontFamily:{type:ControlType.String,title:\"Font\",defaultValue:\"DM Sans, -apple-system, sans-serif\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"PriceCurrency\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutHeight\":\"auto\",\"framerSupportedLayoutWidth\":\"auto\",\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Currency_Selector.map","import{jsx as _jsx}from\"react/jsx-runtime\";// Attach this override to your CTA button in Framer.\n// Generates a fresh event ID per click, fires Meta Pixel InitiateCheckout\n// with that event ID, and forwards it (plus fbclid + UTMs) to the checkout URL\n// so server-side CAPI Purchase can deduplicate against the same eid.\nconst CHECKOUT_URL=\"https://join.gleanapp.com/yearly-offer\";const OFFER=\"birthday_2026\";// Pulls the fbclid back out of Meta's _fbc cookie.\n// Cookie format: fb.1.<timestamp>.<fbclid>\nfunction getFbclidFromCookie(){if(typeof document===\"undefined\")return null;const match=document.cookie.match(/_fbc=([^;]+)/);if(!match)return null;const parts=match[1].split(\".\");return parts.length>=4?parts.slice(3).join(\".\"):null;}export function withCheckoutCTA(Component){return props=>{const handleClick=e=>{e.preventDefault();// 1. Fresh event ID for this click\nconst eid=typeof crypto!==\"undefined\"&&crypto.randomUUID?crypto.randomUUID():`${Date.now()}-${Math.random().toString(36).slice(2)}`;// 2. Fire Meta Pixel InitiateCheckout with the event ID\nif(typeof window!==\"undefined\"&&window.fbq){window.fbq(\"track\",\"InitiateCheckout\",{},{eventID:eid});}// 3. Read tracking params from the current page URL\nconst current=new URLSearchParams(window.location.search);const utms=[\"utm_source\",\"utm_medium\",\"utm_campaign\",\"utm_content\",\"utm_term\"];// 4. Build the destination URL\nconst destination=new URL(CHECKOUT_URL);destination.searchParams.set(\"type\",\"new\");destination.searchParams.set(\"offer\",OFFER);destination.searchParams.set(\"eid\",eid);// UTMs from URL\nutms.forEach(key=>{const value=current.get(key);if(value)destination.searchParams.set(key,value);});// fbclid: prefer URL (fresh click), fall back to _fbc cookie\nconst fbclid=current.get(\"fbclid\")||getFbclidFromCookie();if(fbclid)destination.searchParams.set(\"fbclid\",fbclid);// 5. Small delay so fbq can flush before navigation\nsetTimeout(()=>{window.location.href=destination.toString();},150);};return /*#__PURE__*/_jsx(Component,{...props,onClick:handleClick});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withCheckoutCTA\":{\"type\":\"reactHoc\",\"name\":\"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