{"version":3,"file":"SmartText.CSl1q9wt.mjs","names":["useRef","useState","__esmMin","init_ssg_sandbox_shims","window","init_npm_react_18_3_1","_e","de","init_jsx_runtime","p","ce","createStore","init_store_js__1_0","parseMoneyAmount","n","value","saveCustomerBalancesToStorage","balances","magbucks","vouchers","getCustomerFirstName","data","getCustomerOptionalFirstName","loadData","store","setStore","useStore","dataFetched","urlSpotId","storedSpotId","spotId","prev","endpoint","ENDPOINT_CUSTOMER_DATA","result","getCustomerData","person","firstName","optionalFirstName","orders","error","Component","props","SmartText","customerData","loadingState","LoadingIndicator","processText","replacePlaceholders","text","SmartTextWrapper","containerRef","processTextNode","originalText","node","newText","observer","mutation","mutations","processNode","useSpotIdPresence","hasSpotId","setHasSpotId","showIfNoSpot","showIfMagbucksExists","showIfNoMagbucks","showIfVouchersExists","showIfMagbucksOrVouchersExists","init_SmartText","response","template","stringTemplate","key","defaultValue","dotStyle"],"sources":["https:/framerusercontent.com/modules/s8ym47Kwt5SrymkUQeT3/4gX9LirfV9wrWaI7Frsg/SmartText.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs,Fragment as _Fragment}from\"react/jsx-runtime\";import{useState,useEffect,useRef}from\"react\";import{createStore}from\"https://framer.com/m/framer/store.js@^1.0.0\";const orderHeaderRow={background:\"#C9C9C9\"};const table_td_th={padding:\".75rem\",\"vertical-align\":\"top\",\"border-top\":\"0px solid #dee2e6\"};const orderHeaderText={padding:\"10px 10px\",fontWeight:\"bold\"};const tableHeaderColumns={background:\"#F9F9F9\"};const colPproduct={width:\"25%\"};const colPaid={width:\"25%\"};const colRetail={width:\"25%\"};const colMagbucks={width:\"25%\"};const colVouchers={width:\"25%\"};const formatCurrencyValue=value=>`$${value??0}`;const getSkuVoucherValue=sku=>sku?.vouchers??0;const useStore=createStore({customerData:{person:{first_name:\"\",first_name_optional:\"\",last_name:\"\",email:\"\",phone_number:\"\",magbucks:\"0.00\",vouchers:\"0.00\",person_id:\"\"},orders:[]},loadingState:\"LOADING\"});const ENDPOINT_CUSTOMER_DATA=\"https://cjcnsf3en5.us-east-1.awsapprunner.com/getCustomerPIInfoBySpotId\";function parseMoneyAmount(value){const n=Number.parseFloat(String(value??\"\").replace(/[$,]/g,\"\"));return Number.isFinite(n)?n:0;}function saveCustomerBalancesToStorage(spotId,magbucks,vouchers){const balances={spotId,magbucks:parseMoneyAmount(magbucks),invVoucherAmount:parseMoneyAmount(vouchers),updatedAt:Date.now()};window.__magfastCustomerBalances=balances;window.dispatchEvent(new CustomEvent(\"magfast:customer-balances\",{detail:balances}));}function getCustomerFirstName(data){return data?.person_details?.first_name??data?.person?.first_name??data?.customer?.first_name??data?.first_name??\"\";}function getCustomerOptionalFirstName(data){return data?.person_details?.first_name_optional??data?.person_details?.first_name??data?.person?.first_name_optional??data?.person?.first_name??data?.customer?.first_name_optional??data?.customer?.first_name??data?.first_name_optional??data?.first_name??\"\";}const getCustomerData=async endpoint=>{try{const response=await fetch(endpoint,{method:\"GET\",headers:{\"Content-Type\":\"application/json; charset=UTF-8\",Accept:\"*/*\"}});if(!response.ok){throw new Error(`HTTP error! status: ${response.status}`);}return response.json();}catch(error){console.error(\"Error fetching data: \",error);return null;}};const replacePlaceholders=(template,data)=>{if(template==null)return\"\";const stringTemplate=String(template);try{return stringTemplate.replace(/\\{\\{(\\w+)(?:\\|([^}]*))?}}/g,(_,key,defaultValue)=>{const value=data[key];return value!=null&&value!==\"\"?String(value):defaultValue??`{{${key}}}`;});}catch(error){console.error(\"replacePlaceholders error:\",error);return stringTemplate;}};export function loadData(Component){localStorage.removeItem(\"mos017state\");return function WrappedComponent(props){const[store,setStore]=useStore();const dataFetched=useRef(false);useEffect(()=>{const fetchData=async()=>{const urlParams=new URLSearchParams(window.location.search);const urlSpotId=urlParams.get(\"spot_id\");const storedSpotId=localStorage.getItem(\"spot_id\");const spotId=urlSpotId||storedSpotId;if(!spotId){console.warn(\"No spot_id found\");setStore(prev=>({...prev,customerData:{person:{first_name:\"Friend\",first_name_optional:\"Friend\",last_name:\"\",email:\"example@example.com\",phone_number:\"\",magbucks:\"0.00\",vouchers:\"0.00\",person_id:\"\"}},loadingState:\"LOADED\"}));return;}if(urlSpotId)localStorage.setItem(\"spot_id\",urlSpotId);if(!dataFetched.current){dataFetched.current=true;try{const endpoint=`${ENDPOINT_CUSTOMER_DATA}/${spotId}`;setTimeout(async()=>{const result=await getCustomerData(endpoint);if(result?.person_details){const person=result.person_details;const firstName=getCustomerFirstName(result).trim()||\"Friend\";const optionalFirstName=getCustomerOptionalFirstName(result).trim()||\"Friend\";const magbucks=result.magbucks;const vouchers=result.inv_voucher_balance??result.vouchers??person.vouchers;const orders=result.order_details;saveCustomerBalancesToStorage(spotId,magbucks,vouchers);setStore(prev=>({...prev,customerData:{person:{first_name:firstName,first_name_optional:optionalFirstName,last_name:person.last_name||\"\",email:person.primary_email||\"example@example.com\",phone_number:person.phone||\"\",magbucks:parseMoneyAmount(magbucks).toFixed(2),vouchers:parseMoneyAmount(vouchers).toFixed(2),person_id:person.person_id||\"\"},orders:orders||[]},loadingState:\"LOADED\"}));}else{throw new Error(\"Invalid person structure\");}},1500);}catch(error){console.error(\"Fetch failed:\",error);setStore(prev=>({...prev,customerData:{person:{first_name:\"Friend\",first_name_optional:\"Friend\",last_name:\"\",email:\"example@example.com\",phone_number:\"\",magbucks:\"0.00\",vouchers:\"0.00\",person_id:\"\"},orders:[]},loadingState:\"ERROR\"}));}}};fetchData();},[]);return /*#__PURE__*/_jsx(Component,{...props});};}export function SmartText(Component){return function WrappedSmartText(props){const[store]=useStore();const{customerData,loadingState}=store;const{person}=customerData;const processComponent=()=>{const processText=text=>replacePlaceholders(text,person);if(props.text){return /*#__PURE__*/_jsx(Component,{...props,text:processText(props.text)});}if(typeof props.children===\"string\"){return /*#__PURE__*/_jsx(Component,{...props,children:processText(props.children)});}return /*#__PURE__*/_jsx(SmartTextWrapper,{...props,customerData:person,Component:Component});};if(loadingState===\"LOADING\"){return /*#__PURE__*/_jsx(Component,{...props,style:{...props.style,visibility:\"hidden\",position:\"relative\"},children:/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",top:0,left:0,right:0,bottom:0,display:\"flex\",alignItems:\"center\",justifyContent:\"center\"},children:/*#__PURE__*/_jsx(LoadingIndicator,{})})});}return processComponent();};}const LoadingIndicator=()=>{const dotStyle={width:\"8px\",height:\"8px\",margin:\"0 4px\",borderRadius:\"50%\",backgroundColor:\"#ccc\",animation:\"pulse 1.5s infinite ease-in-out\"};return /*#__PURE__*/_jsxs(\"div\",{style:{display:\"flex\",alignItems:\"center\",justifyContent:\"center\"},children:[/*#__PURE__*/_jsx(\"style\",{children:`\n                @keyframes pulse {\n                    0%, 100% { opacity: 0.3; transform: scale(0.8); }\n                    50% { opacity: 1; transform: scale(1); }\n                }\n            `}),/*#__PURE__*/_jsx(\"div\",{style:{...dotStyle,animationDelay:\"0s\"}}),/*#__PURE__*/_jsx(\"div\",{style:{...dotStyle,animationDelay:\"0.3s\"}}),/*#__PURE__*/_jsx(\"div\",{style:{...dotStyle,animationDelay:\"0.6s\"}})]});};function SmartTextWrapper({Component,customerData,...props}){const containerRef=useRef(null);useEffect(()=>{if(!containerRef.current)return;const processTextNode=node=>{const originalText=node.nodeValue||\"\";if(originalText.match(/\\{\\{(\\w+)(?:\\|([^}]*))?}}/)){const newText=replacePlaceholders(originalText,customerData);if(newText!==originalText){node.nodeValue=newText;}}};const observer=new MutationObserver(mutations=>{for(const mutation of mutations){if(mutation.type===\"childList\"){mutation.addedNodes.forEach(processNode);}else if(mutation.type===\"characterData\"){if(mutation.target.nodeType===Node.TEXT_NODE){processTextNode(mutation.target);}}}});const processNode=node=>{if(node.nodeType===Node.TEXT_NODE){processTextNode(node);}else{node.childNodes.forEach(processNode);}};processNode(containerRef.current);observer.observe(containerRef.current,{childList:true,subtree:true,characterData:true,characterDataOldValue:true});return()=>observer.disconnect();},[customerData]);return /*#__PURE__*/_jsx(\"div\",{ref:containerRef,style:{display:\"contents\"},children:/*#__PURE__*/_jsx(Component,{...props})});}function useSpotIdPresence(){const[hasSpotId,setHasSpotId]=useState(null);useEffect(()=>{const urlParams=new URLSearchParams(window.location.search);const urlSpotId=urlParams.get(\"spot_id\");const storedSpotId=localStorage.getItem(\"spot_id\");if(urlSpotId){localStorage.setItem(\"spot_id\",urlSpotId);}setHasSpotId(Boolean(urlSpotId||storedSpotId));},[]);return hasSpotId;}export function showIfSpotExists(Component){return function WrappedComponent(props){const hasSpotId=useSpotIdPresence();if(hasSpotId===null)return null;return hasSpotId?/*#__PURE__*/_jsx(Component,{...props}):null;};}export function showIfNoSpot(Component){return function WrappedComponent(props){const hasSpotId=useSpotIdPresence();if(hasSpotId===null)return null;return!hasSpotId?/*#__PURE__*/_jsx(Component,{...props}):null;};}export function showIfMagbucksExists(Component){return function WrappedComponent(props){const[store]=useStore();const{customerData,loadingState}=store;const{person}=customerData;const magbucks=!isNaN(person.magbucks)?parseInt(person?.magbucks):0;return magbucks>0?/*#__PURE__*/_jsx(Component,{...props}):null;};}export function showIfNoMagbucks(Component){return function WrappedComponent(props){const[store]=useStore();const{customerData,loadingState}=store;const{person}=customerData;const magbucks=!isNaN(person.magbucks)?parseInt(person?.magbucks):0;return magbucks<=0?/*#__PURE__*/_jsx(Component,{...props}):null;};}export function showIfVouchersExists(Component){return function WrappedComponent(props){const[store]=useStore();const{customerData,loadingState}=store;const{person}=customerData;const vouchers=!isNaN(person.vouchers)?parseInt(person?.vouchers):0;return vouchers>0?/*#__PURE__*/_jsx(Component,{...props}):null;};}export function showIfMagbucksOrVouchersExists(Component){return function WrappedComponent(props){const[store]=useStore();const{customerData,loadingState}=store;const{person}=customerData;const magbucks=!isNaN(person.magbucks)?parseInt(person?.magbucks):0;const vouchers=!isNaN(person.vouchers)?parseInt(person?.vouchers):0;return magbucks>0||vouchers>0?/*#__PURE__*/_jsx(Component,{...props}):null;};}export function showIfNoVouchers(Component){return function WrappedComponent(props){const[store]=useStore();const{customerData,loadingState}=store;const{person}=customerData;const vouchers=!isNaN(person.vouchers)?parseInt(person?.vouchers):0;return vouchers<=0?/*#__PURE__*/_jsx(Component,{...props}):null;};}export function Orders(Component){return props=>{const[store,setStore]=useStore();useEffect(()=>{const link=document.createElement(\"link\");link.rel=\"stylesheet\";link.href=\"https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css\";document.head.appendChild(link);return()=>{document.head.removeChild(link);};},[store]);if(!store.customerData){return /*#__PURE__*/_jsx(\"div\",{children:\"Loading...\"})// Placeholder for loading state\n;}return /*#__PURE__*/_jsxs(\"div\",{style:{width:\"100%\",height:\"100%\",marginTop:\"-30px\"},children:[/*#__PURE__*/_jsx(Component,{...props}),/*#__PURE__*/_jsx(\"div\",{className:\"row\",style:{marginTop:\"0px\",fontFamily:\"Gotham Book\"},children:/*#__PURE__*/_jsx(\"div\",{className:\"col-sm-12\",children:store.customerData.orders.map(order=>/*#__PURE__*/_jsx(OrderDetails,{order:order},order.order_id))})})]});};}const OrderDetails=({order})=>{const partially_paid=order.financial_status==\"partially_paid_plan\"?true:false;const colWidths={colTitle:{width:\"35%\"},colQty:{width:\"10%\"},colRetail:{width:\"20%\"},colMagbucks:{width:\"17.5%\"},colVouchers:{width:\"17.5%\"},colPayments:{width:\"0%\"}};if(partially_paid){colWidths[\"colTitle\"]={width:\"35%\"};colWidths[\"colQty\"]={width:\"10%\"};colWidths[\"colRetail\"]={width:\"15%\"};colWidths[\"colMagbucks\"]={width:\"12.5%\"};colWidths[\"colVouchers\"]={width:\"12.5%\"};colWidths[\"colPayments\"]={width:\"15%\"};}return /*#__PURE__*/_jsxs(\"div\",{style:{marginTop:\"70px\"},children:[/*#__PURE__*/_jsxs(\"h3\",{children:[\"Order ID: \",order.order_name]}),/*#__PURE__*/_jsx(\"div\",{className:\"table-responsive\",children:/*#__PURE__*/_jsxs(\"table\",{className:\"table\",style:{borderCollapse:\"collapse\",borderTop:\"none\",borderBottom:\"none\"},children:[/*#__PURE__*/_jsx(\"thead\",{children:/*#__PURE__*/_jsxs(\"tr\",{children:[/*#__PURE__*/_jsx(\"th\",{style:colWidths.colTitle,children:\"Product\"}),/*#__PURE__*/_jsx(\"th\",{style:colWidths.colQty,children:\"Qty\"}),/*#__PURE__*/_jsx(\"th\",{style:colWidths.colRetail,children:\"Full retail\"}),order.financial_status==\"partially_paid_plan\"&&/*#__PURE__*/_jsx(\"th\",{style:colWidths.colPayments,children:\"Payments Completed\"}),/*#__PURE__*/_jsx(\"th\",{style:colWidths.colMagbucks,children:\"Your MAGBucks\"}),/*#__PURE__*/_jsx(\"th\",{style:colWidths.colVouchers,children:\"Vouchers\"})]})}),/*#__PURE__*/_jsx(\"tbody\",{children:order.lineItems.length>0?order.lineItems.map((line_item,index)=>/*#__PURE__*/_jsx(LineItemRow,{line_item:line_item,isLastItem:index===order.lineItems.length-1,partiallyPaidPlan:order.financial_status==\"partially_paid_plan\"?true:false,paymentCount:order.payment_count},index)):/*#__PURE__*/_jsx(\"tr\",{children:/*#__PURE__*/_jsx(\"td\",{colSpan:order.financial_status==\"partially_paid_plan\"?\"6\":\"5\",style:{textAlign:\"center\"},children:\"No line items available\"})})})]})})]});};const LineItemRow=({line_item,isLastItem,partiallyPaidPlan,paymentCount})=>/*#__PURE__*/_jsxs(_Fragment,{children:[/*#__PURE__*/_jsxs(\"tr\",{style:{background:isLastItem?\"#C9C9C9\":\"transparent\",height:\"40px\",border:\"none\"},children:[/*#__PURE__*/_jsx(\"td\",{colSpan:line_item.type===\"combo\"?partiallyPaidPlan?\"6\":\"5\":undefined,className:line_item.type===\"combo\"?\"\":\"col-product\",style:{fontWeight:line_item.type===\"combo\"?\"bold\":\"normal\"},children:line_item.type===\"combo\"?line_item.title:line_item.skus[0].sku}),line_item.type!==\"combo\"&&/*#__PURE__*/_jsxs(_Fragment,{children:[/*#__PURE__*/_jsx(\"td\",{className:\"\",children:line_item.skus[0].quantity_unfulfilled}),/*#__PURE__*/_jsx(\"td\",{className:\"\",children:isLastItem?\"\":formatCurrencyValue(line_item.skus[0].retail_price)}),partiallyPaidPlan&&/*#__PURE__*/_jsx(\"td\",{className:\"\",children:!isLastItem?`${paymentCount}/6`:\"\"}),/*#__PURE__*/_jsx(\"td\",{className:\"\",children:isLastItem?/*#__PURE__*/_jsx(\"b\",{children:formatCurrencyValue(line_item.skus[0].magbucks)}):formatCurrencyValue(line_item.skus[0].magbucks)}),/*#__PURE__*/_jsx(\"td\",{className:\"\",children:isLastItem?/*#__PURE__*/_jsx(\"b\",{children:formatCurrencyValue(getSkuVoucherValue(line_item.skus[0]))}):formatCurrencyValue(getSkuVoucherValue(line_item.skus[0]))})]})]}),line_item.type===\"combo\"&&line_item.skus.map((sku,skuIndex)=>/*#__PURE__*/_jsxs(\"tr\",{style:{height:\"40px\",border:\"none\"},children:[/*#__PURE__*/_jsx(\"td\",{className:\"\",style:{paddingLeft:\"30px\"},children:sku.sku}),/*#__PURE__*/_jsx(\"td\",{className:\"\",children:sku.quantity_unfulfilled}),/*#__PURE__*/_jsx(\"td\",{className:\"\",children:formatCurrencyValue(sku.retail_price)}),partiallyPaidPlan&&/*#__PURE__*/_jsx(\"td\",{className:\"\",children:!isLastItem?`${paymentCount}/6`:\"\"}),/*#__PURE__*/_jsx(\"td\",{className:\"\",children:formatCurrencyValue(sku.magbucks)}),/*#__PURE__*/_jsx(\"td\",{className:\"\",children:formatCurrencyValue(getSkuVoucherValue(sku))})]}))]});\nexport const __FramerMetadata__ = {\"exports\":{\"showIfNoVouchers\":{\"type\":\"reactHoc\",\"name\":\"showIfNoVouchers\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"Orders\":{\"type\":\"reactHoc\",\"name\":\"Orders\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"showIfSpotExists\":{\"type\":\"reactHoc\",\"name\":\"showIfSpotExists\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"SmartText\":{\"type\":\"reactHoc\",\"name\":\"SmartText\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"showIfMagbucksExists\":{\"type\":\"reactHoc\",\"name\":\"showIfMagbucksExists\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"showIfVouchersExists\":{\"type\":\"reactHoc\",\"name\":\"showIfVouchersExists\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"showIfMagbucksOrVouchersExists\":{\"type\":\"reactHoc\",\"name\":\"showIfMagbucksOrVouchersExists\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"showIfNoMagbucks\":{\"type\":\"reactHoc\",\"name\":\"showIfNoMagbucks\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"loadData\":{\"type\":\"reactHoc\",\"name\":\"loadData\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"showIfNoSpot\":{\"type\":\"reactHoc\",\"name\":\"showIfNoSpot\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./SmartText.map"],"mappings":"A,oMAAu+B,SAASa,EAAiB,EAAM,CAAC,IAAMC,EAAE,OAAO,WAAW,OAAOC,GAAO,EAAE,CAAC,CAAC,QAAQ,QAAQ,EAAE,CAAC,EAAE,OAAO,OAAO,SAASD,CAAC,EAAEA,EAAE,CAAE,CAAC,SAASE,EAA8B,EAAO,EAAS,EAAS,CAAC,IAAMC,EAAS,CAAC,SAAO,SAASJ,EAAiBK,CAAQ,EAAE,iBAAiBL,EAAiBM,CAAQ,EAAE,UAAU,KAAK,IAAI,CAAC,EAAE,EAAO,0BAA0BF,EAASb,EAAO,cAAc,IAAI,YAAY,4BAA4B,CAAC,OAAOa,CAAQ,CAAC,CAAC,CAAE,CAAC,SAASG,EAAqB,EAAK,CAAC,OAAOC,GAAM,gBAAgB,YAAYA,GAAM,QAAQ,YAAYA,GAAM,UAAU,YAAYA,GAAM,YAAY,EAAG,CAAC,SAASC,EAA6B,EAAK,CAAC,OAAOD,GAAM,gBAAgB,qBAAqBA,GAAM,gBAAgB,YAAYA,GAAM,QAAQ,qBAAqBA,GAAM,QAAQ,YAAYA,GAAM,U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