1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3689],{8349:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});let n=(e,t,a)=>{var n;let r="annual"===t||"one-time"===t?e.annualPrice:e.monthlyPrice;return{item_id:(null==e||null==(n=e.id)?void 0:n.toString())||null,item_name:null==e?void 0:e.name,item_variant:t,currency:a,price:parseFloat(r),quantity:1}}},22179:e=>{e.exports={pageWrapper:"donate_pageWrapper__8O6eV",pageTitle:"donate_pageTitle__lBzQk",pageSubtitle:"donate_pageSubtitle__rdsYG",priceWrapper:"donate_priceWrapper__LX3sR",link:"donate_link__iqk2B",productDetails:"donate_productDetails__fmZ2o",productDetailsHeading:"donate_productDetailsHeading__O0Rv_",paymentBtn:"donate_paymentBtn__jtX5z",utilityBtn:"donate_utilityBtn__Oei2c",loadingWrapper:"donate_loadingWrapper__SQFSx",savedCard:"donate_savedCard__fcLb0",cardDetails:"donate_cardDetails__t9MD7",separator:"donate_separator__e_m0N",contentWrapper:"donate_contentWrapper__ZYcd2",subtitle:"donate_subtitle__M2xyw",icon:"donate_icon__IbiGx"}},50447:(e,t,a)=>{"use strict";a.r(t),a.d(t,{__N_SSP:()=>g,default:()=>S});var n=a(37876),r=a(8349),i=a(79757),s=a(40880),o=a(14232),c=a(89099),l=a(33939),_=a(88876),u=a(77585),d=a(12277),p=a(20884),m=a(54734),h=a(22179),f=a.n(h);let y=async(e,t)=>{try{let a=new URLSearchParams({siteSlug:e,sessionId:t});return(await fetch("/api/checkout/verify?".concat(a.toString()))).json()}catch(t){(0,s.v)(t,{siteSlug:e})}return null};var g=!0;let S=e=>{let{globalData:t}=e,{siteTitle:a,publisherCurrency:s,metaPixelId:h}=t,{query:{siteSlug:g,session_id:S}}=(0,c.useRouter)(),{userData:{hydrated:v,productCart:N}}=(0,l.u)(),x=(0,u.A)(),k=(0,_.A)("add_payment_info"),D=(0,_.A)("purchase"),[j,w]=(0,o.useState)(!1),[b,P]=(0,o.useState)(!1);return(0,o.useEffect)(()=>{v&&S&&g&&!b&&y(g,S).then(e=>{if((null==e?void 0:e.status)==="success"&&(null==e?void 0:e.isDonation)){P(!0);let t=e.amount||0,a={currency:(s||"USD").toLowerCase(),value:t,items:[],customer_id:e.customerId,customer_email:e.customerEmail};k(a),D({...a,transaction_id:S}),h&&!j&&(w(!0),i.f("Purchase",{content_ids:["donation"],contents:[{id:"donation",quantity:1}],currency:s||"USD",value:t}))}})},[v,S,g,b,k,D,s,h,j]),(0,o.useEffect)(()=>{v&&N&&!S&&(D({currency:s.toLowerCase(),value:parseFloat(N.annualPrice.toString()),transaction_id:N.id.toString(),items:[(0,r.A)(N,"one-time",s)]}),h&&!j&&(w(!0),i.f("Purchase",{content_ids:[N.name],contents:[{id:N.name,quantity:1}],currency:s,value:parseFloat(N.annualPrice.toString())})))},[v,S,N,D,s,h,j]),(0,o.useEffect)(()=>{v&&x(null)},[v,x]),(0,n.jsx)(d.A,{...t,title:"".concat(a," | Donation Complete"),headerTheme:"simple",footerTheme:"simple",hideAds:!0,children:(0,n.jsxs)("div",{className:f().pageWrapper,children:[(0,n.jsxs)("h1",{className:f().pageTitle,children:[(0,n.jsx)("span",{className:f().icon,children:(0,n.jsx)(m.A,{})}),"Success"]}),(0,n.jsxs)("div",{className:f().inner,children:[(0,n.jsx)("h2",{className:f().pageSubtitle,children:"Your contribution to ".concat(a," is complete - thank you for your support!")}),(0,n.jsx)("div",{className:f().contentWrapper,children:(0,n.jsx)(p.A,{href:"/",className:f().link,children:"Check out the homepage"})})]})]})})}},74977:(e,t,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/_sites/[siteSlug]/donate/payment/complete",function(){return a(50447)}])}},e=>{e.O(0,[1596,6511,2277,636,6593,8792],()=>e(e.s=74977)),_N_E=e.O()}]);
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.