1import{d as N,r as H,aI as q,N as m,P as V,o,c as r,f as t,j as s,t as x,g as f,G as p,a3 as F,F as _,l as O,ae as j,af as Q,s as C,p as S}from"./27Oh8GQO.js";const G={class:"cart-order-item"},W={class:"image"},Y=["src"],z={class:"product truncate"},J={class:"!text-small block truncate text-sm text-black/50"},K={class:"!text-large truncate text-lg font-medium"},X={class:"!text-small flex flex-wrap gap-x-2 text-sm"},Z={key:0,class:"font-medium"},tt={key:1,class:"font-light text-black/50"},et={class:"flex items-center gap-x-1 font-medium"},st={key:0,class:"font-normal text-black/50 line-through"},at=["innerHTML"],lt={class:"quantity"},nt={class:"qty-select flex items-center rounded-md border border-black/25 px-2 py-[2px]"},it=["disabled"],ot=["readonly"],rt=["disabled"],ct={class:"price text-right tabular-nums"},ut=["innerHTML"],dt=["innerHTML"],mt={key:1,class:"facts pl-7"},pt={class:"!text-small text-sm"},xt={key:0,class:"mb-1 flex gap-x-1 text-green-700 last:mb-0"},I=50,ft=N({__name:"CartOrderItem",props:{view:{},item:{},pppRate:{},showFacts:{type:Boolean}},emits:["set:qty","delete"],setup(w,{emit:u}){const l=w,b=u,P=H(),T=l.item.product.node,n=l.item.variation,a=q(l.item.quantity),k=H(l.item.product.node.pppEnabled),$=m(()=>` ${l.item.singlePrice} ${a.value>1?`<span class="text-black">x ${a.value}</span>`:""}`),g=m(()=>["CERTIFICATE_PRODUCT","VARIABLE_SUBSCRIPTION"].includes(l.item.product.node.type)||l.item.product.node.soldIndividually),d=m(()=>{const{type:c,name:e}=l.item.product.node;if(e.toLowerCase().includes("mindset")||e.toLowerCase().includes("businessmap"))return"Flight Levels Live Workshop";switch(c){case"TICKET":return"Flight Levels® Event";case"CERTIFICATE_PRODUCT":return"Flight Levels® Graduate Certification Fee";case"VARIABLE_SUBSCRIPTION":case"SUBSCRIPTION":return"Flight Levels® Membership";case"FLPP":return"Start elevate your professional career";default:return"Flight Levels® Self-Paced Online Workshop"}}),i=m(()=>{var c;return n&&((c=n.node)!=null&&c.image.sourceUrl)?n.node.image.sourceUrl:T.image.sourceUrl}),L=m(()=>{if(k.value&&l.pppRate<1){const c=Number.parseFloat(l.item.product.node.rawPrice||"0")*l.item.quantity,e=Number.parseFloat(l.item.subtotalRaw||"0");return(c-e).toFixed(2).replace(".",",")}return null}),M=m(()=>{var y;const c=[],{extraData:e}=l.item;if(l.item.variation){if(e!=null&&e.length){const v=e.find(D=>D.key==="email");v&&c.push(`Graduate Email: ${v.value}`)}const{attributes:h}=l.item.variation;h.forEach(v=>{c.push(`${v.label==="Ppp"?"PPP-Variation":v.label}: ${v.value}`)})}if(l.item.product.node.type==="FLPP"&&(e!=null&&e.length)){const h=e.find(v=>v.key==="flpp_title");h&&c.push(`Your seat for ${h.value}`)}if(l.showFacts){const h=(y=l.item.product.node.facts)==null?void 0:y.find(v=>v.key==="fla_cart_facts");h&&h.value.split(";").forEach(v=>c.push(v))}return c}),R=c=>{clearTimeout(P.value),!g.value&&(P.value=setTimeout(()=>{b("set:qty",{qty:a.value,key:l.item.key,event:c})},750))},U=()=>{a.value!==0&&(a.value--,R("remove_from_cart"))},B=()=>{a.value!==I&&(a.value++,R("add_to_cart"))},A=m(()=>{const c=Number.parseFloat(l.item.totalRaw),e=Number.parseFloat(l.item.subtotalRaw);return c<e}),E=m(()=>{if(l.item.extraData){const c=l.item.extraData.find(e=>e.key==="thwdpf_discounts");if(c){const{initial_price:e}=JSON.parse(c.value),y=Number.parseFloat(e||"0"),h=Number.parseFloat(l.item.singlePrice.replace(".","").replace(",","."));if(y>h)return`${y.toFixed(2)} â¬`}}return null});return V(()=>l.item.quantity,c=>{a.value=c}),(c,e)=>(o(),r("div",G,[t("div",W,[t("img",{src:s(i),height:"100",width:"100",class:"object-contain"},null,8,Y)]),t("div",z,[t("span",J,x(s(d)),1),t("div",K,x(s(T).name),1),t("div",X,[s(k)?(o(),r("div",Z,[e[3]||(e[3]=t("span",{class:"font-normal text-black/50"},"PPP-Rate:",-1)),f(" "+x(`${l.pppRate*100}%`),1)])):(o(),r("div",tt,"PPP not applicable")),e[5]||(e[5]=t("div",{class:"text-black/50"},"|",-1)),t("div",et,[e[4]||(e[4]=t("span",{class:"font-normal text-black/50"},"Price:",-1)),s(E)?(o(),r("span",st,x(s(E)),1)):p("",!0),t("span",{class:F({"text-green-700":s(k)&&s(L)}),innerHTML:s($)},null,10,at)])])]),c.view==="cart"?(o(),r(_,{key:0},[t("div",lt,[e[9]||(e[9]=t("span",{class:"!text-small-x text-xs text-black/50"}," Quantity ",-1)),t("div",nt,[t("button",{type:"button",class:F(["text-black transition-colors",{"hover:text-blue":s(a)>1&&!s(g),"opacity-25":s(a)===1||s(g)}]),title:"Decrease Quantity",disabled:s(a)===1||s(g),onClick:U},e[6]||(e[6]=[t("i",{class:"fla-icon fla-icon--remove"},null,-1)]),10,it),O(t("input",{"onUpdate:modelValue":e[0]||(e[0]=y=>Q(a)?a.value=y:null),type:"number",max:I,min:"1",class:F(["!text-small border-none bg-white/0 text-center text-sm outline-none",{"cursor-default":s(g)}]),readonly:s(g),onBlur:e[1]||(e[1]=y=>R(s(a)>c.item.quantity?"add_to_cart":"remove_from_cart"))},null,42,ot),[[j,s(a)]]),t("button",{type:"button",class:F(["text-black transition-colors",{"hover:text-blue":s(a)<I&&!s(g),"opacity-25":s(a)>I||s(g)}]),title:"Decrease Quantity",disabled:s(a)===I||s(g),onClick:B},e[7]||(e[7]=[t("i",{class:"fla-icon fla-icon--add"},null,-1)]),10,rt)]),t("button",{class:"!text-small-x text-xs text-black/50 transition-colors hover:text-black active:text-black",onClick:e[2]||(e[2]=y=>b("delete"))}
1,e[8]||(e[8]=[t("i",{class:"fla-icon fla-icon--trash-bin"},null,-1),f(" delete ")]))]),t("div",ct,[e[10]||(e[10]=t("span",{class:"!text-small-x text-xs text-black/50"}," Total ",-1)),s(A)?(o(),r("span",{key:0,class:"!text-small-x text-xs text-black/50 line-through",innerHTML:c.item.subtotal},null,8,ut)):p("",!0),t("div",{class:"!text-large text-lg font-medium",style:{"line-height":"30px"},innerHTML:c.item.total},null,8,dt)])],64)):p("",!0),s(M)||s(L)?(o(),r("div",mt,[t("ul",pt,[s(L)?(o(),r("li",xt,[e[11]||(e[11]=t("i",{class:"fla-icon fla-icon--checkbox-circle-line mt-[3px]"},null,-1)),f(" Price PPP adjusted ("+x(`${l.pppRate*100}%`)+"), ",1),t("strong",null,"you save "+x(s(L))+" â¬",1)])):p("",!0),s(M)?(o(!0),r(_,{key:1},C(s(M),(y,h)=>(o(),r("li",{key:`cartItemfact_${h}`,class:"mb-1 flex gap-x-1 last:mb-0"},[e[12]||(e[12]=t("i",{class:"fla-icon fla-icon--checkbox-circle-line mt-[3px]"},null,-1)),f(" "+x(y),1)]))),128)):p("",!0)])])):p("",!0)]))}}),Yt=S(ft,[["__scopeId","data-v-2a88133d"]]),bt={class:"cart-order-item"},gt={class:"image"},vt=["src"],yt={class:"product truncate"},ht={class:"text-lg !text-large font-medium truncate"},_t={class:"flex flex-wrap gap-x-2 text-sm !text-small"},kt={key:0,class:"font-medium"},Pt={key:1,class:"text-black/50 font-light"},Tt={class:"font-medium flex items-center gap-x-1"},$t={class:"price text-right tabular-nums"},Lt=["innerHTML"],Ft=["innerHTML"],wt={class:"facts pl-7"},Mt={class:"text-sm !text-small"},It={key:0,class:"text-green-700 mb-1 last:mb-0 flex gap-x-1"},Rt={key:1,class:"mb-1 mt-3 flex gap-x-1 text-green-700"},Ht=["innerHTML"],Nt={key:3,class:"mb-1 mt-3 flex gap-x-1"},Ct=N({__name:"CartSubscriptionItem",props:{view:{},item:{},pppRate:{},showFacts:{type:Boolean}},setup(w){const u=w,l=u.item.product.node,b=u.item.variation,P=H(u.item.product.node.pppEnabled),T=`${u.item.singlePrice} <span class="font-normal text-black/50">/year</span>`,n=m(()=>{var d;return b&&((d=b.node)!=null&&d.image.sourceUrl)?b.node.image.sourceUrl:l.image.sourceUrl}),a=m(()=>{if(P.value&&u.pppRate<1){const d=Number.parseFloat(u.item.product.node.rawPrice||"0")*u.item.quantity,i=Number.parseFloat(u.item.subtotalRaw||"0");return(d-i).toFixed(2).replace(".",",")}return null}),k=m(()=>b==null?void 0:b.attributes.map(d=>`<i class="fla-icon fla-icon--checkbox-circle-line mt-[3px]"></i>${d.name==="pa_payment-interval"?d.label:"Package"}: ${d.value}`)),$=m(()=>{var d;if((d=u.item.extraData)!=null&&d.length)return u.item.extraData.find(i=>i.key==="subscription_switch")}),g=m(()=>{const d=Number.parseFloat(u.item.totalRaw),i=Number.parseFloat(u.item.subtotalRaw);return d<i});return(d,i)=>(o(),r("div",bt,[t("div",gt,[t("img",{src:s(n),height:"80",width:"80",class:"object-contain"},null,8,vt)]),t("div",yt,[i[3]||(i[3]=t("span",{class:"block text-black/50 text-sm !text-small truncate"},"Flight Levels Membership",-1)),t("div",ht,x(s(l).name),1),t("div",_t,[s(P)?(o(),r("div",kt,[i[0]||(i[0]=t("span",{class:"text-black/50 font-normal"},"PPP-Rate:",-1)),f(" "+x(`${u.pppRate*100}%`),1)])):(o(),r("div",Pt," PPP not applicable ")),i[2]||(i[2]=t("div",{class:"text-black/50"}," | ",-1)),t("div",Tt,[i[1]||(i[1]=t("span",{class:"text-black/50 font-normal"},"Price:",-1)),t("span",{class:F({"text-green-700":s(P)&&s(a)}),innerHTML:T},null,2)])])]),t("div",$t,[i[4]||(i[4]=t("span",{class:"text-xs !text-small-x text-black/50"}," Total ",-1)),s(g)?(o(),r("span",{key:0,class:"line-through text-black/50 text-xs !text-small-x",innerHTML:d.item.subtotal},null,8,Lt)):p("",!0),t("div",{class:"text-lg !text-large font-medium",style:{"line-height":"30px"},innerHTML:d.item.total},null,8,Ft)]),t("div",wt,[t("ul",Mt,[s(a)?(o(),r("li",It,[i[5]||(i[5]=t("i",{class:"fla-icon fla-icon--checkbox-circle-line mt-[3px]"},null,-1)),f(" Price PPP adjusted ("+x(`${u.pppRate*100}%`)+"), ",1),t("strong",null,"you save "+x(s(a))+" â¬",1)])):p("",!0),s($)?(o(),r("li",Rt,i[6]||(i[6]=[t("i",{class:"fla-icon fla-icon--checkbox-circle-line mt-[3px]"},null,-1),f(" Membership Upgrade ")]))):p("",!0),s(k)?(o(!0),r(_,{key:2},C(s(k),(L,M)=>(o(),r("li",{key:`cartItemfact_${M}`,class:"mb-1 flex gap-x-1 text-green-700",innerHTML:L},null,8,Ht))),128)):p("",!0),d.view==="cart"?(o(),r("li",Nt,i[7]||(i[7]=[t("i",{class:"fla-icon fla-icon--checkbox-circle-line mt-[3px]"},null,-1),f(" Active directly after payment ")]))):p("",!0),i[8]||(i[8]=t("li",{class:"mb-1 flex gap-x-1"},[t("i",{class:"fla-icon fla-icon--checkbox-circle-line mt-[3px]"}),f(" Unlimited Access to workshop materials ")],-1)),i[9]||(i[9]=t("li",{class:"mb-1 flex gap-x-1"},[t("i",{class:"fla-icon fla-icon--checkbox-circle-line mt-[3px]"}),f(" Unlimited Access to all your self-paced workshops ")],-1))])])]))}}),zt=S(Ct,[["__scopeId","data-v-479edc54"]]),Et={key:0,class:"fla-notice fla-notice--note"},St={class:"grid grid-cols-2"},Ut={key:0,class:"text-green-700 text-xs !text-small-x"},Bt=["innerHTML"],At=["innerHTML"],Dt=["innerHTML"],qt=["innerHTML"],Vt={class:"text-lg !text-large font-medium py-2"},Ot={class:"text-right py-2"},jt={class:"font-medium mb-0 text-lg !text-large"},Qt=["innerHTML"],Gt=["innerHTML"],Jt=N({__name:"PriceSummary",props:{summary:{},taxLines:{},hasPPP:{type:Boolean},vatExemptMessage:{},hasSubscriptionProducts:{type:Boolean},isPaid:{type:Boolean}},setup(w){const u=w,l=m(()=>Number.parseFloat(u.summary.discountTotal||"0")>0),b=m(()=>{var n;return(n=u.taxLines)==null?void 0:n.filter(a=>Number.parseFloat(a.amount||"0")>0)}),P=m(()=>{var n;return(n=b.value)!=null&&n.length&&b.value.length===1?b.value[0].label.replace("VAT","Taxes "):"Taxes"}),T=n=>(n||(n="0"),n.includes(" â¬")?`${Number.parseFloat(n.replace(".","").replace(",",".")).toFixed(2).replace(".",",")} â¬`:`${Number.parseFloat(n.replace(",",".")).toFixed(2).replace(".",",")} â¬`);return(n,a)=>{var k;return o(),r(_,null,[n.vatExemptMessage?(o(),r("div",Et,[a[0]||(a[0]=t("b",null,"Note:",-1)),f(" "+x(n.vatExemptMessage),1)])):p("",!0),t("dl",St,[t("dt",null,[a[1]||(a[1]=f(" Subtotal: ")),n.hasPPP?
1(o(),r("span",Ut," (PPP adjusted) ")):p("",!0)]),t("dd",{class:"text-right",innerHTML:n.summary.subtotal},null,8,Bt),s(l)?(o(),r(_,{key:0},[a[2]||(a[2]=t("dt",{class:"text-flg"}," Discount: ",-1)),t("dd",{class:"text-right text-flg",innerHTML:`-${n.summary.discountTotal}`},null,8,At)],64)):p("",!0),(k=n.taxLines)!=null&&k.length?(o(!0),r(_,{key:1},C(n.taxLines,($,g)=>(o(),r(_,{key:`taxLine_${g}`},[t("dt",null,x($.label.replace("VAT","Taxes "))+":",1),t("dd",{class:"text-right",innerHTML:T($.amount)},null,8,Dt)],64))),128)):(o(),r(_,{key:2},[t("dt",null,x(s(P))+":",1),t("dd",{class:"text-right",innerHTML:n.summary.totalTax},null,8,qt)],64)),t("dt",Vt,[n.hasSubscriptionProducts?(o(),r(_,{key:0},[f(" To pay now: ")],64)):(o(),r(_,{key:1},[f(" Total: ")],64))]),t("dd",Ot,[t("h6",jt,[t("span",{class:F({"marker-highlight--green":n.isPaid===!0,"marker-highlight--yellow":n.isPaid===!1}),innerHTML:n.summary.total},null,10,Qt)])]),n.summary.refund?(o(),r(_,{key:3},[a[3]||(a[3]=t("dt",{class:"text-red-700"}," Refunded: ",-1)),t("dd",{class:"text-red-700 text-right",innerHTML:n.summary.refund},null,8,Gt)],64)):p("",!0)])],64)}}});export{Jt as _,zt as a,Yt as b};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.