PageSourceSearch

https://tinypng.com/_next/static/chunks/pages/checkout/web-704153dd0e513ed5.js

js tinypng.com collected 2026-09-24 06:51:47 UTC 14,021 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[615],{8622:(e,t,r)=>{"use strict";r.d(t,{Z:()=>n});var n=function(e){return e?e.charAt(0).toUpperCase()+e.slice(1).toLowerCase():e}},23465:e=>{e.exports={s11zi3cc:"s11zi3cc",product:"product",disabled:"disabled",selected:"selected",icons:"icons",crown:"crown",icon:"icon",compress:"compress",convert:"convert"}},25850:(e,t,r)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/checkout/web",function(){return r(65337)}])},33003:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});let n={src:"/_next/static/media/compress.ede3bab2.svg",height:174,width:278,blurWidth:0,blurHeight:0}},45165:(e,t,r)=>{"use strict";r.d(t,{P:()=>a});var n=r(53764);r(54784);var a=(0,n.I)("div")({name:"ProductBlockStyles",class:"p1uid3aa",propsAsIs:!1,vars:{"p1uid3aa-0":[function(e){return e.background_color}]}})},50676:(e,t,r)=>{"use strict";r.d(t,{JG:()=>u,nU:()=>i,nd:()=>s,pQ:()=>o});var n=r(29935),a=r(82643),c=r(77248),s=function(){return(0,n._)(function(){return(0,a.YH)(this,function(e){switch(e.label){case 0:return[4,(0,c.Jt)("/backend/web/checkout/status",void 0,!1,!0)];case 1:return[2,e.sent()]}})})()},i=function(){return(0,n._)(function(){return(0,a.YH)(this,function(e){switch(e.label){case 0:return[4,(0,c.Jt)("/backend/web/tiers-details",void 0,!1,!0)];case 1:return[2,e.sent()]}})})()},u=function(){return(0,n._)(function(){return(0,a.YH)(this,function(e){switch(e.label){case 0:return[4,(0,c.bE)("/backend/web/checkout/intent",void 0,!1,!0)];case 1:return[2,e.sent()]}})})()},o=function(e){return(0,n._)(function(){return(0,a.YH)(this,function(t){switch(t.label){case 0:return[4,(0,c.bE)("/backend/web/checkout/submit",e,!1,!0)];case 1:return[2,t.sent()]}})})()}},54530:(e,t,r)=>{"use strict";r.d(t,{JS:()=>v,QN:()=>m,l3:()=>h,xo:()=>b});var n=r(29935),a=r(82643),c=r(92906),s=r(73612),i=r(67659),u=r.n(i),o=r(50676),l=r(94916),d=r(83962),h=(0,d.z)(function(){return(0,n._)(function(){var e,t;return(0,a.YH)(this,function(r){switch(r.label){case 0:t=3,r.label=1;case 1:if(!(t>0))return[3,6];r.label=2;case 2:return r.trys.push([2,4,,5]),[4,(0,l.q)()];case 3:return e=r.sent(),[3,6];case 4:return r.sent(),t--,[3,5];case 5:return[3,1];case 6:if(0===t)throw Error("Unauthorized after retries");return[2,e]}})})()}),p=(0,d.z)(function(){return(0,n._)(function(){return(0,a.YH)(this,function(e){switch(e.label){case 0:return[4,(0,o.nU)()];case 1:return[2,e.sent()]}})})()}),f=(0,c.eU)(function(e){return(0,n._)(function(){var t,r,n;return(0,a.YH)(this,function(a){switch(a.label){case 0:return[4,e(h)];case 1:if(!(t=a.sent())||!(r=t.account.ended_on))return[2,""];if((n=u()(r).diff(u()(),"days"))>30)return[2,u()(r).diff(u()(),"months")+" months"];return[2,n+" days"]}})})()}),m=(0,s.Rq)(p),b=(0,s.Rq)(h),v=(0,s.Rq)(f)},54784:e=>{e.exports={p1uid3aa:"p1uid3aa",block:"block","icon-mobile-view":"icon-mobile-view","monthly-price":"monthly-price","upgrade-limit":"upgrade-limit"}},59305:e=>{e.exports={cpacdxm:"cpacdxm","icon-wrapper":"icon-wrapper",icon:"icon",disabled:"disabled"}},62875:(e,t,r)=>{"use strict";r.d(t,{ej:()=>a,qG:()=>c});var n=function(e){return"usd"==e?"$":"€"},a=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"usd";return"".concat(n(t)).concat((e/100).toFixed(2).replace(".00",""))},c=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"usd";return"-".concat(n(t)).concat((e/100).toFixed(2).replace(".00",""))}},65337:(e,t,r)=>{"use strict";r.r(t),r.d(t,{WebCheckoutContext:()=>Z,__N_SSG:()=>J,default:()=>G});var n=r(29935),a=r(17844),c=r(93629),s=r(12694),i=r(82643),u=r(15383),o=r(14343),l=r(19844),d=r(60001),h=r(86020),p=r(45165),f=r(89267),m=r(62875),b=r(76794),v=r(73839),x=function(e){var t=e.tier,r=e.tierPrices,n=e.quantity,a=e.setQuantity,c=e.updatePaymentMethod,s=e.isUpgrading,i=(0,v.e)(),o="test"===(0,b._C)("web_checkout_monthly_price"),l=r[t].original_price,d=Math.round(l/12);return(0,u.jsx)(p.P,{background_color:f.A.colors.backgroundcolors.web,children:(0,u.jsxs)("div",{className:"block",children:[(0,u.jsxs)("div",{children:[(0,u.jsxs)("h4",{children:[(0,m.ej)(l)," per"," ","pro"===t?"Web Pro":"Web Ultra"," user"]}),(0,u.jsxs)("p",{children:[i&&o&&(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)("span",{className:"monthly-price",children:[(0,m.ej)(d)," per month"]})," \xb7 "]}),i&&(o?"billed annually":"Yearly subscription")]}),s&&(0,u.jsxs)("p",{className:"upgrade-limit",children:["pro"===t?"Extend":"Upgrade"," available only for the total number of previously purchased copies."]})," "]}),!c&&(0,u.jsx)(h.e,{min:1,color:f.A.colors.buttoncolors.green,quantity:n,setQuantity:a,disabled:s})]})})},w=r(69359),g=r(8622),y=r(73154),_=r(54530),j=function(e){var t=e.quantity,r=e.expires,n=e.tier,a=e.type,c=e.tierPrices,s=r.toLocaleDateString("en",{year:"numeric",day:"numeric",month:"long"}),i=(0,v.e)(),o=(0,b._C)("web_checkout_monthly_price"),l=(0,y.md)(_.JS),d="hasData"===l.state&&l.data,h=t*c[n].original_price,p=t*c[n].discount;return(0,u.jsxs)("div",{className:w.q,children:[(0,u.jsxs)("div",{className:"box",children:[(0,u.jsxs)("div",{children:[(0,u.jsx)("h4",{children:i&&("test"===o?(0,u.jsxs)(u.Fragment,{children:[t," year Web ",(0,g.Z)(n)," subscription",1!==t&&"s"]}):(0,u.jsxs)(u.Fragment,{children:[t,"x Web ",(0,g.Z)(n)," subscription",1!==t&&"s"]}))}),(0,u.jsx)("p",{className:"subtext",children:"Includes sales tax (if applicable)"})]}),(0,u.jsx)("h4",{children:(0,m.ej)(h)})]}),(0,u.jsx)("div",{className:"box",children:"ultra"===n&&c.ultra.discount>0?(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)("div",{children:(0,u.jsxs)("h5",{children:["Once off refund of remaining ",d," of web pro this year"]})}),(0,u.jsx)("h5",{children:(0,m.qG)(p)})]}):void 0}),a&&(0,u.jsxs)("p",{className:"subtext",children:["You’ll be a Web ",(0,g.Z)(n)," member until"," ",(0,u.jsx)("strong",{children:s}),"."," ","card"==a?(0,u.jsxs)(u.Fragment,{children:["Your subscription will automatically ",(0,u.jsx)("strong",{children:"renew"})," each year. You can change your renewal preference from your dashboard."]}):(0,u.jsx)(u.Fragment,{children:"You will be notified before your subscription expires."})]})]})},k=function(e){var t=e.tier,r=e.type;return(0,u.jsx)("div",{className:w.q,children:(0,u.jsxs)("div",{className:"box",children:[(0,u.jsxs)("div",{children:[(0,u.jsx)("h4",{children:"New payment method"}),(0,u.jsxs)("p",{className:"subtext",children:[" Web ",(0,g.Z)(t)," subscription"]})]}),(0,u.jsx)("h4",{children:r})]})})},N=r(59344),S=r(50676),C=r(6268),D=r(13968),Y=r(62759),P=r(67659),q=r.n(P),F=r(11550),E=r(85781),H=r(33003),U=r(67595);r(23465);var A=function(e){var t=e.tier,r=e.setTier,n=e.renew,a=e.isRenewing,c=e.expires,s=(0,o.useContext)(Z),i=(0,y.md)(Y.SH),l=11>=q()(c).diff(q()(),"months"),d=function(e){return!!a&&"ultra"===i&&e!==i||!!n&&e===i||!l&&!!("pro"===e&&"ultra"===i||e===i&&c&&c>W())};return(0,u.jsxs)("div",{className:I,children:[(0,u.jsxs)("div",{className:"product pro ".concat("pro"===t?"selected":""," ").concat(d("pro")?"disabled":""),onClick:function(){r("pro")},children:[(0,u.jsxs)("div",{className:"icons",children:[(0,u.jsx)("img",{className:"crown",src:F.A.src}),(0,u.jsx)("img",{className:"icon compress",src:H.A.src})]}),(0,u.jsx)(D.d6,{data:s.checkoutWeb.tierSelectionPro.value})]}),(0,u.jsxs)("div",{className:"product ultra ".concat("ultra"===t?"selected":""," ").concat(d("ultra")?"disabled":""),onClick:function(){r("ultra")},children:[(0,u.jsxs)("div",{className:"icons",children:[(0,u.jsx)("img",{className:"crown",src:E.A.src}),(0,u.jsx)("img",{className:"icon convert",src:U.A.src})]}),(0,u.jsx)(D.d6,{data:s.checkoutWeb.tierSelectionUltra.value})]})]})},W=function(){var e=new Date;return new Date(e.getFullYear()+1,e.getMonth()-1,e.getDate())},I="s11zi3cc",R=r(14155),z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new Date;return new Date(e.getFullYear()+1,e.getMonth(),e.getDate())},L=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new Date;return new Date(e.getFullYear(),e.getMonth(),e.getDate()+1)},M=r(42806),Q=r(68734),J=!0,Z=(0,o.createContext)({});function G(e){var t=e.subscription,r=e.currencyData,h=(0,C.l)(t).data,p=(0,R.useRouter)(),f=p.push,b=p.pathname,v=p.query,w=(0,s._)((0,o.useState)(new URLSearchParams(window.location.search).get("tier")||"ultra"),2),g=w[0],D=w[1],Y=(0,s._)((0,o.useState)(),2),P=Y[0],q=Y[1],F=(0,s._)((0,o.useState)(),2),E=F[
10],H=F[1],U=(0,s._)((0,o.useState)(z()),2),W=U[0],I=U[1],J=(0,s._)((0,o.useState)(),2),G=J[0],T=J[1],O=(0,s._)((0,o.useState)(),2),X=O[0],B=O[1],$=(0,s._)((0,o.useState)(),2),K=$[0],V=$[1],ee=(0,s._)((0,o.useState)(),2),et=ee[0],er=ee[1],en=(0,s._)((0,o.useState)(),2),ea=en[0],ec=en[1],es=(0,s._)((0,o.useState)(),2),ei=es[0],eu=es[1],eo=(0,s._)((0,o.useState)("usd"),2),el=eo[0],ed=eo[1],eh=(0,s._)((0,o.useState)(1),2),ep=eh[0],ef=eh[1],em=(0,s._)((0,o.useState)(!1),2),eb=em[0],ev=em[1],ex=(0,s._)((0,o.useState)(!1),2),ew=ex[0],eg=ex[1],ey="true"===new URLSearchParams(window.location.search).get("auto_renew"),e_=(0,y.md)(_.QN),ej="hasData"===e_.state&&e_.data[g].final_price,ek=(0,y.md)(Q.Hp);(0,o.useEffect)(function(){if("hasData"===e_.state&&g){var e=e_.data[g];(0,M.En)({currency:"USD",value:e.final_price/100,items:[{item_id:g,item_name:g,item_category:"web",price:e.final_price/100,discount:e.discount/100}]})}},[ej]),(0,o.useEffect)(function(){P&&"paying"==P.paying_state?(ef(P.copies),ev(!0),"ultra"===g&&"pro"===P.type?(B("Checkout"),T(!1)):!0==P.renew?(B("Change payment method"),T(!0)):ey?(B("Activate yearly renewal"),T(!0)):(B("Checkout"),T(!1),eg(!0))):(P?(ev(!0),B("Checkout")):B("Sign up"),T(!1))},[P,g]);var eN=ej&&(0,m.ej)(ej*ep,"usd"),eS=ej&&(0,m.ej)(ej*ep,el),eC=ej&&r?{price:ej/100,quantity:ep,currency:el,currencyData:r}:void 0;return(0,u.jsx)(N.P,{title:"".concat("pro"===g?"Web Pro":"Web Ultra"," checkout"),description:"Web checkout page",bare:!0,children:(0,u.jsx)(Z.Provider,{value:h,children:ej&&(0,u.jsx)(l.N,{title:(0,u.jsx)("h1",{children:X}),subtitle:(0,u.jsx)(u.Fragment,{}),productCategory:"web",product:(0,u.jsxs)(d.Y,{title:"Subscription type",children:[!G&&(0,u.jsx)(A,{renew:null==P?void 0:P.renew,isRenewing:ew,tier:g,expires:W,setTier:function(e){D(e),f({pathname:b,query:(0,c._)((0,a._)({},v),{tier:e})},void 0,{shallow:!0})}}),(0,u.jsx)(x,{tierPrices:e_.data,tier:g,isUpgrading:eb,quantity:ep,setQuantity:ef,updatePaymentMethod:G})]}),orderSummary:G?(0,u.jsx)(k,{tier:g}):(0,u.jsx)(j,{expires:eb?z(L(new Date)):W,tier:g,quantity:ep,type:K,tierPrices:e_.data}),originalAmount:eN,convertedAmount:eS,paymentTypes:["card","alipay","wechat_pay","paypal","ideal"],onInitialize:function(){return(0,n._)(function(){var e,t,r,n;return(0,i.YH)(this,function(a){switch(a.label){case 0:return[4,(0,S.JG)()];case 1:return t=(e=a.sent()).expires,r=e.account,n=e.invoice_details,q(r),H(n),t&&I(new Date(t)),[2]}})})()},account:P,invoiceDetails:E,onPaymentSelect:function(e){var t=e.type,r=e.currency,a=e.customer_id,c=e.sourceId,s=e.method;return(0,n._)(function(){return(0,i.YH)(this,function(e){return V(t),r&&ed(r),er(s),ec(c),eu(a),[2]})})()},onSubmit:function(e){return(0,n._)(function(){var t;return(0,i.YH)(this,function(r){switch(r.label){case 0:if(!K)throw Error("Internal payment error.");return t=(0,a._)({type:K,customer:ei,sourceId:ea,quantity:ep,currency:el,renew:ew,disabled:ew||G,enableAutoRenew:ey,method:et,tier:g,price:ej},e),window.endorsely_referral&&(t.endorselyReferralId=window.endorsely_referral),ek&&(t.ephemeralClientId=ek),[4,(0,S.pQ)(t)];case 1:return[2,r.sent().token]}})})()},redirect:G?"/checkout/payment-method-update-complete":"/checkout/web-complete?renew=".concat(ew,"&tier=").concat(g),captchaEnabled:!0,updatePaymentMethod:G,localCurrencyData:eC,personalInfoLabels:null==h?void 0:h.globalLanguageSetting})})})}},67595:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});let n={src:"/_next/static/media/compress_convert.f38f8e7d.svg",height:189,width:284,blurWidth:0,blurHeight:0}},73839:(e,t,r)=>{"use strict";r.d(t,{e:()=>s});var n=r(12694),a=r(76794),c=r(14343);function s(){var e=(0,a.sf)(),t=(0,n._)((0,c.useState)(function(){var t;return null!=(t=e.featureFlags.hasLoadedFlags)&&t}),2),r=t[0],s=t[1];return(0,c.useEffect)(function(){return e.featureFlags.hasLoadedFlags?void s(!0):e.onFeatureFlags(function(){return s(!0)})},[e]),r}},83962:(e,t,r)=>{"use strict";r.d(t,{z:()=>a});var n=r(92906);function a(e){var t=(0,n.eU)(0);return(0,n.eU)(function(r){return r(t),e(r)},function(e,r){return r(t,function(e){return e+1})})}},86020:(e,t,r)=>{"use strict";r.d(t,{e:()=>i});var n=r(15383),a=r(69399),c=r(11945),s=r(53764);r(59305);var i=function(e){var t=e.min,r=e.color,s=e.quantity,i=e.disabled,o=e.setQuantity;return(0,n.jsxs)(u,{color:r,children:[(0,n.jsx)("div",{className:"icon-wrapper ".concat(i?"disabled":""),onClick:function(e){e.preventDefault(),o(Math.max(s-1,t))},children:(0,n.jsx)(a.g,{className:"icon",icon:c.EZy,style:{height:"1.2rem"}})}),(0,n.jsx)("input",{type:"text",value:s,disabled:i,onChange:function(e){e.preventDefault();var r=parseInt(e.target.value);r&&o(Math.max(r,t)),""==e.target.value&&o(0)}}),(0,n.jsx)("div",{className:"icon-wrapper ".concat(i?"disabled":""),onClick:function(e){e.preventDefault(),o(s+1)},children:(0,n.jsx)(a.g,{className:"icon",icon:c.QLR,style:{height:"1.2rem"}})})]})},u=(0,s.I)("div")({name:"CounterStyles",class:"cpacdxm",propsAsIs:!1,vars:{"cpacdxm-0":[function(e){var t=e.color;return void 0===t?"#fffff":t}]}})},94916:(e,t,r)=>{"use strict";r.d(t,{q:()=>s,z:()=>i});var n=r(29935),a=r(82643),c=r(77248);function s(){return(0,n._)(function(){return(0,a.YH)(this,function(e){switch(e.label){case 0:return[4,(0,c.Jt)("/web",{},!0)];case 1:return[2,e.sent()]}})})()}function i(e){return(0,n._)(function(){return(0,a.YH)(this,function(t){switch(t.label){case 0:return[4,(0,c.F6)("/web",{renew:e})];case 1:return[2,t.sent()]}})})()}}},e=>{e.O(0,[5645,4668,2963,8551,1631,3943,2474,8816,7243,7462,6268,8572,3891,4937,4310,
16213,5379,9344,2363,3363,1843,636,6593,8792],()=>e(e.s=25850)),_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.