1!function(){try{var e="u">typeof window?window:"u">typeof global?global:"u">typeof globalThis?globalThis:"u">typeof self?self:{};e._sentryModuleMetadata=e._sentryModuleMetadata||{},e._sentryModuleMetadata[(new e.Error).stack]=function(e){for(var t=1;t<arguments.length;t++){var a=arguments[t];if(null!=a)for(var s in a)a.hasOwnProperty(s)&&(e[s]=a[s])}return e}({},e._sentryModuleMetadata[(new e.Error).stack],{"_sentryBundlerPluginAppKey:dpg-media-services-csa":!0});var t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="3c90632b-36ac-4e2a-b6b3-57f965fe810e",e._sentryDebugIdIdentifier="sentry-dbid-3c90632b-36ac-4e2a-b6b3-57f965fe810e")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4445],{2869:(e,t,a)=>{a.d(t,{r:()=>o});var s=a(6029),n=a(55729),r=a(57490),i=a(89456),d=a(82203),l=a.n(d),c=a(59036);function o({className:e,routes:t}){let a=(0,c.U)(),d=function(e=[]){return(0,n.useMemo)(()=>e.map((e,t,a)=>t===a.length-1?{label:e.label??"-"}:{label:e.label??"-",...e.route?{path:e.route}:{}}),[e])}(t??[]);return!d.length||a.hasWebviewLimitation?null:(0,s.jsx)(i.rX,{className:(0,r.cx)("container mx-auto desktop:pt-6 tablet:pt-4 pt-3 flex items-baseline space-x-[0.25rem]",e),items:d,as:(0,s.jsx)(l(),{href:""})})}},4445:(e,t,a)=>{a.r(t),a.d(t,{ChangeCreditCardPaymentStatusPollingPage:()=>D});var s=a(6029),n=a(55729),r=a(89456),i=a(71024),d=a.n(i),l=a(81278),c=a(2869),o=a(50189),u=a(78504),m=a(15615),g=a(79478),p=a(43343),h=a(18654),x=a(23723),y=a(1699),b=a(50092);let C=(0,b.UG)(` 2 query GetChangePaymentStatusCreditCard($changePaymentRequestId: String!) { 3 getChangePaymentStatusCreditCard( 4 changePaymentRequestId: $changePaymentRequestId 5 ) { 6 ...ChangePaymentCreditCardResult 7 paymentStatus 8 subscriptionId 9 lowerCaseBrandId 10 failureReason 11 } 12 } 13`);var f=a(33669);let P={maxAttempts:10,pollUntil:(e,t)=>!!t||!!e?.getChangePaymentStatusCreditCard&&e?.getChangePaymentStatusCreditCard.paymentStatus!=="ORDERED",delay:6e3};var _=a(64952),N=a(77344),S=a(79132),E=a(823),j=a(50197),v=a(42397),I=a(85872),w=a(237);let A=(0,b.UG)(` 14 query ChangeCreditCardPaymentStatusPollingSubscription( 15 $brandId: String! 16 $subscriptionId: String! 17 ) { 18 changeCreditCardPaymentStatusPollingSubscription: getLinkedSubscription( 19 brandId: $brandId 20 subscriptionId: $subscriptionId 21 ) { 22 ...StatusListSubscription 23 pcsProduct { 24 descriptor { 25 name 26 } 27 } 28 } 29 } 30 `),M=(0,b.UG)(` 31 fragment ChangePaymentCreditCardResult on ChangePaymentStatusCreditCardResponse { 32 ...CreditCardSubscriptionStatusList 33 lowerCaseBrandId 34 maskedCreditCard 35 subscriptionId 36 creditCardProvider 37 changePaymentStatus 38 subscriptionKey 39 } 40`),T=({result:e})=>{let t=(0,b.ni)(M,e),{lowerCaseBrandId:a,maskedCreditCard:n,subscriptionId:i,creditCardProvider:d,changePaymentStatus:l,subscriptionKey:c}=t,o=(0,S.PB)(),u=(0,S.Ek)(),{getTranslation:g,getPortableText:h}=(0,p.c3)(),[{fetching:x,error:y,data:C}]=(0,j.IT)({query:A,variables:{brandId:a,subscriptionId:i}}),f=x||"SUCCESS"!==l,P=!g("changeCreditcardPaymentPageNoMailTitle",{optional:!0}),_=[{subscriptionKey:c,title:C?.changeCreditCardPaymentStatusPollingSubscription?.pcsProduct?.descriptor.name||u[a].seoTitle}];return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(v.J,{subscriptions:[C?.changeCreditCardPaymentStatusPollingSubscription],subscriptionStatus:t,fetching:x,error:y}),!f&&(0,s.jsxs)(s.Fragment,{children:[!P&&g("changeCreditcardPaymentPageMailMessage",{optional:!0})&&(0,s.jsx)("p",{className:"text-center",children:g("changeCreditcardPaymentPageMailMessage")}),h("changeCreditcardPaymentPageDelayedProcessingMessage",{optional:!0})&&(0,s.jsx)(r.Eg,{variant:"info",shouldAnnounce:!1,children:(0,s.jsx)(m.A,{message:h("changeCreditcardPaymentPageDelayedProcessingMessage")})}),d&&n&&(0,s.jsx)(I.E,{items:_,paymentInfo:{paymentMethod:d,maskedPayment:n}})]}),(0,s.jsxs)("div",{className:"w-full flex flex-col gap-4 text-center text-sm",children:[!P&&(0,s.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,s.jsx)("strong",{children:g("changeCreditcardPaymentPageNoMailTitle")}),(0,s.jsx)("br",{}),(0,s.jsx)(m.A,{message:h("changeCreditcardPaymentPageNoMailMessage")})]}),(0,s.jsx)("hr",{className:"border-gray-medium"}),o.host&&(0,s.jsxs)("div",{children:[(0,s.jsx)("h2",{className:"heading-6 font-bold mb-4",children:g("changeCreditcardPaymentPageCallToActionTitle")}),(0,s.jsx)(w.N,{href:(0,E.H)(o),passHref:!0,children:(0,s.jsx)(r.$n,{as:"span",variant:"primary",className:"cursor-pointer","data-testid":"change-payment-brand-link",children:(0,s.jsx)(m.A,{message:h("changeCreditcardPaymentPageCallToActionBrandLink"),values:{host:o.host}})})})]}),(0,s.jsx)(w.N,{href:"/abonnementen",className:"font-semibold text-anchor hover:text-anchor-dark text-center underline mt-2",children:(0,s.jsx)("span",{children:g("changeCreditcardPaymentPageCallToActionOverviewLink")})})]})]})},R=d()(()=>Promise.all([a.e(3957),a.e(5330)]).then(a.bind(a,95330)),{loadableGenerated:{webpack:()=>[95330]},loading:()=>(0,s.jsx)("div",{style:{width:"300px",height:"250px"}}),ssr:!1}),L=["MO__SUBMIT_CHANGE_PAYMENT__AUTHENTICATION_FAILED","MO__SUBMIT_CHANGE_PAYMENT__CARD_DECLINED","MO__SUBMIT_CHANGE_PAYMENT__CARD_EXPIRED","MO__SUBMIT_CHANGE_PAYMENT__INACTIVE_CARD","MO__SUBMIT_CHANGE_PAYMENT__INSUFFICIENT_FUNDS","MO__SUBMIT_CHANGE_PAYMENT__INVALID_CVV","MO__SUBMIT_CHANGE_PAYMENT__INVALID_CARD_HOLDER_NAME","MO__SUBMIT_CHANGE_PAYMENT__INVALID_CARD_NUMBER","MO__SUBMIT_CHANGE_PAYMENT__INVALID_CARD_TYPE","MO__SUBMIT_CHANGE_PAYMENT__REFUSED_BY_ISSUER"],D=({changePaymentRequestId:e})=>{let{push:t}
40=(0,l.useRouter)(),[a,i]=(0,n.useState)([]),{getPortableText:d,getTranslation:b,translations:S}=(0,p.c3)(),{errorCodes:E}=(0,g.s)(),{pushAnalyticsEvent:j}=(0,h.iK)(),{data:v,fetching:I,timedOut:w,error:A}=((e,t=!0)=>{let[{data:a,error:s,fetching:r},{timedOut:i}]=(0,f.A)({query:C,variables:{changePaymentRequestId:e},pause:!t,requestPolicy:"network-only"},P);return(0,n.useEffect)(()=>{i&&(0,y.OG)(`[use-change-payment-status/useCreditCardStatusFetch]: Timed out trying to retrieve status of "${e}"`,{logLevel:"info"})},[e,i]),{data:a?.getChangePaymentStatusCreditCard,error:s,fetching:r,timedOut:i}})(e),M=(I||v?.paymentStatus==="ORDERED")&&!w,D=!I&&!A&&v?.paymentStatus==="SUCCEEDED",k=!I&&!A&&v?.paymentStatus==="FAILED";return((0,n.useEffect)(()=>{j({event:"screenview",step_description:"polling status",screen_name:window.location.pathname,steps:3,funnel_name:"change creditcard payment"})},[]),(0,n.useEffect)(()=>{(D||k)&&j({event:"screenview",step_description:"change payment result",screen_name:window.location.pathname,steps:3,funnel_name:"change creditcard payment",successful_change_payment:D})},[D,k]),(0,n.useEffect)(()=>{if(v?.paymentStatus==="CANCELED"||v?.paymentStatus==="FAILED"){let{subscriptionId:e,lowerCaseBrandId:a}=v;if(!(v?.paymentStatus==="CANCELED"||L.some(e=>e===v.failureReason)))return;let s="CHANGE_PAYMENT_GENERIC_ERROR";(v?.paymentStatus==="CANCELED"||v?.paymentStatus==="FAILED"&&v.failureReason?.includes("AUTHENTICATION_FAILED"))&&(s="CHANGE_PAYMENT_CANCELED"),v.failureReason&&v.failureReason in E&&(s=v.failureReason),t(`/betaalservice/wijzigen/${a}/${e}?retryReason=${s}`)}},[v?.paymentStatus]),(0,n.useEffect)(()=>{S.changeCreditcardPaymentPageStatusLoadingMessages&&i((0,x.k)(S.changeCreditcardPaymentPageStatusLoadingMessages))},[]),A)?A instanceof _.C&&A.networkError?.message==="Not Found"?(0,s.jsx)(o.A,{}):(0,s.jsx)(u.A,{error:A}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(c.r,{routes:S.changecreditcardpaymentpageBreadCrumbs}),(0,s.jsxs)("div",{className:"max-w-md w-full mx-auto pt-5 tablet:pt-4 px-3 mb-4 flex flex-col text-center gap-6",children:[(0,s.jsx)(r.gj,{variant:"row",steps:[{id:"step-1",label:b("changeCreditcardPaymentPageStep1Label"),status:"completed"},{id:"step-2",label:b("changeCreditcardPaymentPageStep2Label"),status:M?"loading":w?"active":k?"error":"completed"}]}),(0,s.jsx)("div",{children:(0,s.jsxs)("h2",{className:"heading-4 font-bold mb-1","data-testid":"payment-status",children:[w&&b("changeCreditcardPaymentPageStatusTimedOutTitle"),M&&b("changeCreditcardPaymentPageStatusLoadingTitle"),D&&b("changeCreditcardPaymentPageResultTitle"),k&&b("changeCreditcardPaymentPageFailedTitle")]})})]}),(0,s.jsxs)("div",{className:"bg-white",children:[w&&(0,s.jsx)("div",{className:"bg-white flex flex-col items-center justify-center pt-4 pb-8","data-testid":"timed-out-message",children:(0,s.jsx)(m.A,{className:"max-w-md",message:d("changeCreditcardPaymentPageStatusTimedOutMessage")})}),M&&(0,s.jsxs)("div",{className:"bg-white w-full flex flex-col items-center justify-center pt-4 pb-8","data-testid":"loading-subscription-details",children:[(0,s.jsx)("p",{className:"font-semibold",children:b("changeCreditcardPaymentPageStatusLoadingWindowCloseWarning")}),(0,s.jsx)(R,{src:"/animations/payment-polling.lottie",autoplay:!0,loop:!0,style:{width:"300px",height:"250px"}}),a.length>0&&(0,s.jsx)(N.M,{messages:a})]}),(D||k)&&(0,s.jsx)("div",{className:"max-w-md w-full mx-auto pb-6 tablet:pb-10 pt-2 tablet:pt-4 px-3 flex flex-col gap-4 items-center",children:(0,s.jsx)(T,{result:v})})]})]})}},15857:(e,t,a)=>{a.d(t,{Y:()=>c});var s=a(6029),n=a(79132),r=a(95618),i=a(89456);a(55729);var d=a(57490),l=a(25802);function c({brandId:e,status:t,children:a,testId:o}){let u=(0,n.tA)(e),{dpgConfig:m}=(0,l.G)(),g=(0,r.d)(u?u.subscriptionLogo:m.dpgHeaderLogo)?.height(50).url();return(0,s.jsx)(i.Eg,{variant:"SUCCESS"===t?"success":"PENDING"===t?"info":"error",showIcon:!g,className:"mt-2","data-testid":o,shouldAnnounce:!1,children:(0,s.jsxs)("div",{className:"gap-3 grid grid-flow-col rounded-sm items-center",children:[g&&(0,s.jsx)("div",{className:(0,d.cx)("overflow-hidden rounded-xl w-10 h-10 border border-gray-medium bg-white",!u&&"p-1"),children:(0,s.jsx)("img",{src:g,className:"w-full h-full",title:u?u.seoTitle:m.dpgTitle})}),a]})})}},23723:(e,t,a)=>{a.d(t,{k:()=>s});let s=([...e])=>{let t=e.length;for(;t;){let a=Math.floor(Math.random()*t--);[e[t],e[a]]=[e[a],e[t]]}return e}},33669:(e,t,a)=>{a.d(t,{A:()=>r});var s=a(55729),n=a(50197);let r=(e,{delay:t,maxAttempts:a,pollUntil:r})=>
40{let[i,d]=(0,n.IT)(e),[l,c]=(0,s.useState)(1),o=l>=("number"==typeof a?a:1/0),u=o||r?.(i?.data,i?.error)||!1;return(0,s.useEffect)(()=>{if(!u&&!i.fetching){let e=setTimeout(()=>{d({requestPolicy:"network-only"}),c(e=>e+1)},t);return()=>clearTimeout(e)}},[u,i.fetching,d,e.variables,t]),[i,{timedOut:o}]}},42397:(e,t,a)=>{a.d(t,{J:()=>g});var s=a(6029);a(55729);var n=a(89456),r=a(15615),i=a(79132),d=a(43343),l=a(50092),c=a(15857);let o=(0,l.UG)(` 41 fragment StatusListSubscription on S2LinkedSubscription { 42 brand 43 subscriptionKey 44 lowerCaseBrandId 45 } 46`),u=(0,l.UG)(` 47 fragment SubscriptionStatusList on ChangePaymentSubscriptionStatus { 48 subscriptionKey 49 changePaymentStatus 50 } 51`),m=(0,l.UG)(` 52 fragment CreditCardSubscriptionStatusList on ChangePaymentStatusCreditCardResponse { 53 subscriptionKey 54 changePaymentStatus 55 } 56`),g=({subscriptions:e,fetching:t,error:a,...g})=>{let p="subscriptionStatusList"in g?(0,l.ni)(u,g.subscriptionStatusList):[(0,l.ni)(m,g.subscriptionStatus)],h=e.map(e=>(0,l.ni)(o,e)),{getErrorTranslation:x}=(0,d.YY)(),{getTranslation:y,getPortableText:b}=(0,d.c3)(),C=(0,i.Ek)();if(t)return(0,s.jsx)("div",{className:"text-center py-12","data-testid":"loader",children:(0,s.jsx)(n.fV,{"aria-label":y("changeCreditcardPaymentPageLoadingStatusAriaLabel")})});let f=h.filter(e=>p.some(({subscriptionKey:t,changePaymentStatus:a})=>t===e.subscriptionKey&&"IN_PROGRESS"===a)),P=h.filter(e=>p.some(({subscriptionKey:t,changePaymentStatus:a})=>t===e.subscriptionKey&&"SUCCESS"===a)),_=h.filter(e=>p.some(({subscriptionKey:t,changePaymentStatus:a})=>t===e.subscriptionKey&&"FAILURE"===a));return(0,s.jsxs)("div",{"data-testid":"change-payment-status-list",className:"flex flex-col gap-2 text-sm",children:[a&&(0,s.jsx)(n.Eg,{variant:"error",className:"mt-2",children:x("GENERIC-ERROR")}),f.map(e=>(0,s.jsx)(c.Y,{status:"PENDING",brandId:e.lowerCaseBrandId,testId:"subscription-status-item-pending",children:(0,s.jsx)(r.A,{message:b("changeCreditcardPaymentPagePendingUpdateMessage"),values:{brand_name:C[e?.lowerCaseBrandId].seoTitle,brand_id:C[e?.lowerCaseBrandId].id}})},e.subscriptionKey)),_.map(e=>(0,s.jsx)(c.Y,{status:"FAILURE",brandId:e.lowerCaseBrandId,testId:"subscription-status-item-failure",children:(0,s.jsx)(r.A,{message:b("changeCreditcardPaymentPageFailedUpdateMessage"),values:{brand_name:C[e?.lowerCaseBrandId].seoTitle,brand_id:C[e?.lowerCaseBrandId].id}})},e.subscriptionKey)),P.map(e=>(0,s.jsx)(c.Y,{status:"SUCCESS",brandId:e.lowerCaseBrandId,testId:"subscription-status-item-success",children:(0,s.jsx)(r.A,{message:b("changeCreditcardPaymentPageSuccessfulUpdateMessage"),values:{brand_name:C[e?.lowerCaseBrandId].seoTitle,brand_id:C[e?.lowerCaseBrandId].id}})},e.subscriptionKey))]})}},50189:(e,t,a)=>{a.d(t,{A:()=>u});var s=a(6029);a(55729);var n=a(89456),r=a(71024),i=a.n(r),d=a(81278),l=a(15615),c=a(43343);let o=i()(()=>Promise.all([a.e(3957),a.e(5330)]).then(a.bind(a,95330)),{loadableGenerated:{webpack:()=>[95330]},loading:()=>(0,s.jsx)("div",{style:{width:"300px",height:"250px"}}),ssr:!1});function u(){let{getTranslation:e,getPortableText:t}=(0,c.c3)(),{push:a}=(0,d.useRouter)();return(0,s.jsxs)("div",{className:"text-center","data-testid":"error-page-404",children:[(0,s.jsx)("div",{className:"mt-8 inline-block","data-testid":"error-text-404",children:(0,s.jsx)(o,{src:"/animations/404.lottie",autoplay:!0,loop:!0,style:{width:"300px",height:"250px"}})}),(0,s.jsx)("div",{className:"flex flex-col text-center bg-white py-8 px-4",children:(0,s.jsxs)("div",{className:"max-w-xl mx-auto space-y-4 tablet:space-y-6",children:[(0,s.jsx)(l.A,{className:"text-xl font-bold",message:t("errorDescription404")}),(0,s.jsx)(n.$n,{variant:"primary",onClick:()=>{a("/account")},"data-testid":"back-to-account",children:e("errorBackButtonLabel404")})]})})]})}},77344:(e,t,a)=>{a.d(t,{M:()=>i});var s=a(6029),n=a(55729),r=a(57490);let i=({messages:e,transitionDuration:t=6e3})=>{let[a,i]=(0,n.useState)(0);return(0,n.useEffect)(()=>{let a=setInterval(()=>{i(t=>(t+1)%e.length)},t);return()=>clearInterval(a)},[e.length,t]),(0,s.jsx)("div",{className:"relative w-full flex justify-center items-center",children:e.map((e,t)=>(0,s.jsx)("div",{className:(0,r.cx)("absolute ease-in-out duration-300 opacity-0",t===a&&"opacity-100"),children:e},t))})}},78504:(e,t,a)=>{a.d(t,{A:()=>g});var s=a(6029),n=a(55729),r=a(1699),i=a(89456),d=a(71024),l=a.n(d),c=a(81278),o=a(15615),u=a(43343);let m=l()(()=>Promise.all([a.e(3957),a.e(5330)]).then(a.bind(a,95330)),{loadableGenerated:{webpack:()=>[95330]},loading:()=>(0,s.jsx)("div",{style:{width:"300px",height:"250px"}}),ssr:!1});function g({error:e,traceId:t}){let{getTranslation:a,getPortableText:d}=(0,u.c3)(),{pathname:l,push:p,reload:h}=(0,c.useRouter)();return(0,n.useEffect)(()=>
56{if(window.location){let a=new URLSearchParams(window.location.search);"forbidden"===a.get("error")&&a.has("reason")||(0,r.c_)(e||Error("[500] Internal server error"),{extra:{traceId:t,href:window.location.href}})}},[t,e]),(0,s.jsxs)("div",{className:"text-center","data-testid":"error-page-500",children:[(0,s.jsx)("div",{className:"mt-8 inline-block",children:(0,s.jsx)(m,{src:"/animations/500.lottie",autoplay:!0,loop:!0,style:{width:"300px",height:"250px"}})}),(0,s.jsx)("div",{className:"flex flex-col text-center bg-white py-8 px-4",children:(0,s.jsxs)("div",{className:"max-w-xl mx-auto space-y-4 tablet:space-y-6",children:[(0,s.jsx)(o.A,{className:"text-xl font-bold",message:d("errorDescription")}),"/500"===l?(0,s.jsx)(i.$n,{variant:"primary",onClick:()=>{p("/account")},children:a("errorBackButtonLabel404")}):(0,s.jsx)(i.$n,{variant:"primary",onClick:()=>{h()},children:a("errorRetryButtonLabel")}),t&&(0,s.jsxs)("span",{"data-testid":"error-trace-id",className:"pt-4 font-monospace block text-gray-dark",children:[a("errorTraceIdLabel")," ",t]})]})})]})}},85872:(e,t,a)=>{a.d(t,{E:()=>i});var s=a(6029);a(55729);var n=a(57490),r=a(43343);let i=({paymentInfo:{maskedPayment:e,paymentMethod:t},items:a})=>{let{getTranslation:n}=(0,r.c3)();return(0,s.jsxs)("div",{className:"w-full bg-gray-light p-3 rounded-sm text-left","data-testid":"change-payment-recap-list",children:[(0,s.jsx)("h3",{className:"font-semibold mb-2",children:n("changeCreditcardPaymentPageRecapHeading")}),(0,s.jsxs)("div",{className:"flex flex-col gap-4 text-sm",children:[(0,s.jsx)(d,{"data-testid":"change-payment-subscription-title",label:n("changeCreditcardPaymentRecapListSubscriptionLabel"),value:(0,s.jsx)("div",{className:"flex flex-col",children:a.map(({subscriptionKey:e,title:t})=>(0,s.jsx)("span",{children:t},e))})}),(0,s.jsx)(d,{"data-testid":"change-payment-new-payment-info",label:n("changeCreditcardPaymentRecapListNewPaymentInfoLabel"),value:(0,s.jsxs)("div",{className:"flex flex-col",children:[(0,s.jsx)("span",{"data-testid":"updated-payment-method",children:t}),(0,s.jsx)("span",{"data-testid":"updated-payment-detail",children:e})]})})]})]})};function d({className:e,label:t,value:a,...r}){return(0,s.jsxs)("div",{className:(0,n.cx)("grid grid-cols-[minmax(7rem,30%)_1fr]",e),...r,children:[(0,s.jsx)("span",{className:"pt-[3px] text-xs font-medium",children:t}),a]})}}}]);
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.