PageSourceSearch

https://plim.co.uk/_next/static/chunks/pages/customer/dashboard/bn…/[uuid]-69969414517f717f.js

js plim.co.uk collected 2026-10-07 05:48:56 UTC 61,396 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2375],{13379:function(e,t,n){"use strict";var r=n(64836);t.Z=void 0;var i=r(n(64938)),o=n(85893),s=(0,i.default)((0,o.jsx)("path",{d:"M6.23 20.23 8 22l10-10L8 2 6.23 3.77 14.46 12z"}),"ArrowForwardIos");t.Z=s},37958:function(e,t,n){"use strict";var r=n(64836);t.Z=void 0;var i=r(n(64938)),o=n(85893),s=(0,i.default)((0,o.jsx)("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"NavigateNext");t.Z=s},64489:function(e,t,n){"use strict";n.d(t,{Z:function(){return O}});var r=n(87462),i=n(63366),o=n(67294),s=(n(76607),n(86010)),a=n(94780),l=n(81719),c=n(78884),d=n(29630),u=n(41796),p=n(54235),x=n(85893),m=(0,p.Z)((0,x.jsx)("path",{d:"M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}),"MoreHoriz"),f=n(50522);const h=(0,l.ZP)(f.Z)((({theme:e})=>(0,r.Z)({display:"flex",marginLeft:`calc(${e.spacing(1)} * 0.5)`,marginRight:`calc(${e.spacing(1)} * 0.5)`},"light"===e.palette.mode?{backgroundColor:e.palette.grey[100],color:e.palette.grey[700]}:{backgroundColor:e.palette.grey[700],color:e.palette.grey[100]},{borderRadius:2,"&:hover, &:focus":(0,r.Z)({},"light"===e.palette.mode?{backgroundColor:e.palette.grey[200]}:{backgroundColor:e.palette.grey[600]}),"&:active":(0,r.Z)({boxShadow:e.shadows[0]},"light"===e.palette.mode?{backgroundColor:(0,u._4)(e.palette.grey[200],.12)}:{backgroundColor:(0,u._4)(e.palette.grey[600],.12)})}))),g=(0,l.ZP)(m)({width:24,height:16});var v=function(e){const t=e;return(0,x.jsx)("li",{children:(0,x.jsx)(h,(0,r.Z)({focusRipple:!0},e,{ownerState:t,children:(0,x.jsx)(g,{ownerState:t})}))})},y=n(34867);function b(e){return(0,y.Z)("MuiBreadcrumbs",e)}var j=(0,n(1588).Z)("MuiBreadcrumbs",["root","ol","li","separator"]);const _=["children","className","component","expandText","itemsAfterCollapse","itemsBeforeCollapse","maxItems","separator"],w=(0,l.ZP)(d.Z,{name:"MuiBreadcrumbs",slot:"Root",overridesResolver:(e,t)=>[{[`& .${j.li}`]:t.li},t.root]})({}),Z=(0,l.ZP)("ol",{name:"MuiBreadcrumbs",slot:"Ol",overridesResolver:(e,t)=>t.ol})({display:"flex",flexWrap:"wrap",alignItems:"center",padding:0,margin:0,listStyle:"none"}),C=(0,l.ZP)("li",{name:"MuiBreadcrumbs",slot:"Separator",overridesResolver:(e,t)=>t.separator})({display:"flex",userSelect:"none",marginLeft:8,marginRight:8});function k(e,t,n,r){return e.reduce(((i,o,s)=>(s<e.length-1?i=i.concat(o,(0,x.jsx)(C,{"aria-hidden":!0,className:t,ownerState:r,children:n},`separator-${s}`)):i.push(o),i)),[])}var O=o.forwardRef((function(e,t){const n=(0,c.Z)({props:e,name:"MuiBreadcrumbs"}),{children:l,className:d,component:u="nav",expandText:p="Show path",itemsAfterCollapse:m=1,itemsBeforeCollapse:f=1,maxItems:h=8,separator:g="/"}=n,y=(0,i.Z)(n,_),[j,C]=o.useState(!1),O=(0,r.Z)({},n,{component:u,expanded:j,expandText:p,itemsAfterCollapse:m,itemsBeforeCollapse:f,maxItems:h,separator:g}),S=(e=>{const{classes:t}=e;return(0,a.Z)({root:["root"],li:["li"],ol:["ol"],separator:["separator"]},b,t)})(O),P=o.useRef(null),E=o.Children.toArray(l).filter((e=>o.isValidElement(e))).map(((e,t)=>(0,x.jsx)("li",{className:S.li,children:e},`child-${t}`)));return(0,x.jsx)(w,(0,r.Z)({ref:t,component:u,color:"text.secondary",className:(0,s.Z)(S.root,d),ownerState:O},y,{children:(0,x.jsx)(Z,{className:S.ol,ref:P,ownerState:O,children:k(j||h&&E.length<=h?E:(e=>f+m>=e.length?e:[...e.slice(0,f),(0,x.jsx)(v,{"aria-label":p,onClick:()=>{C(!0);const e=P.current.querySelector("a[href],button,[tabindex]");e&&e.focus()}},"ellipsis"),...e.slice(e.length-m,e.length)])(E),S.separator,g,O)})}))}))},83879:function(e,t,n){"use strict";var r=n(59499),i=n(4730),o=n(55343),s=n(58316),a=n(87536),l=(n(67294),n(20120)),c=n(25237),d=n(85893),u=["label","labelColor","control","name","defaultValue","endAdornment","rules","errors","serverError","sx","sxTextField","labelClassName"];function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?p(Object(n),!0).forEach((function(t){(0,r.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}t.Z=function(e){var t=e.label,n=e.labelColor,r=e.control,p=e.name,m=e.defaultValue,f=(e.endAdornment,e.rules),h=e.errors,g=e.serverError,v=e.sx,y=e.sxTextField,b=e.labelClassName,j=(0,i.Z)(e,u),_=x(x({},h),g),w=p,Z=x({},v),C={"& input":{color:n}},k=x(x({},y),C),O=p.split(".");return O.length>1&&(w=O[O.length-1]),(0,d.jsxs)(o.Z,{className:"form-control-hook",sx:Z,children:[t&&(0,d.jsx)(s.Z,{shrink:!0,sx:{color:n},className:b,children:t}),(0,d.jsx)(a.Qr,{name:p,rules:f,control:r,defaultValue:m||null,render:function(e){var t=e.field;return(0,d.jsx)(c.N,x(x(x({},t),j),{},{sx:k}))}}),(0,d.jsx)(l.Z,{main_name:w,final_error:_})]})}},75849:function(e,t,n){"use strict";var r=n(59499),i=n(5714),o=n(19604),s=n(29630),a=(n(67294),n(60577)),l=n.n(a),c=n(85893);function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function u(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(Object(n),!0).forEach((function(t){(0,r.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}t.Z=function(e){var t=e.children,n=e.type,r=e.hasIcon,a=void 0===r||r,d=e.className,p=e.textColor,x=e.sx,m={info:l().sb_300,warning:l().sy_500,error:l().sr_300,success:l().sg_400};return(0,c.jsx)(o.Z,{className:n?{info:"bg--sb_400",warning:"bg--sy_200",error:"bg--sr_100",success:"bg--sg_200"}[n]:d,icon:a?(0,c.jsx)(i.mPI,{className:n?{info:"fill--sb_500",warning:"fill--sy_700",error:"fill--sr_500",success:"fill--sg_600"}[n]:""}):(0,c.jsx)(c.Fragment,{}),sx:u({p:"8px",borderRadius:"2px",border:n?"1px solid ".concat(m[n]):"none","& .MuiAlert-message":{padding:{xs:0,md:"5px 0"}},alignItems:"center"},x),children:(0,c.jsx)(s.Z,{sx:{typography:{xs:"plim-R-link-2",md:"plim-R-link-1"}},color:p||"black",children:t})})}},77566:function(e,t,n){"use strict";n.d(t,{e:function(){return r}});var r,i=n(59499),o=n(4361),s=n(68346),a=n(29630),l=n(9144),c=n(64489),d=n(18377),u=(n(67294),n(37958)),p=n(20845),x=n(85893);function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(Object(n),!0).forEach((function(t){(0,i.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}!function(e){e[e.INVITE_DETAIL=0]="INVITE_DETAIL",e[e.SELECT_PLAN=1]="SELECT_PLAN",e[e.CHECK_ELIGIBILITY=2]="CHECK_ELIGIBILITY"}(r||(r={}));t.Z=function(e){var t=e.stage,n=e.children,i=e.uuid,m=function(){return t==r.SELECT_PLAN||t==r.CHECK_ELIGIBILITY},h=[(0,x.jsx)(s.Z,{href:m()?"/customer/dashboard/bnpl/invite-detail/".concat(i):void 0,sx:f({textDecoration:"none",cursor:"auto"},m()&&{cursor:"pointer!important"}),children:(0,x.jsx)(a.Z,{className:t==r.INVITE_DETAIL?"text--black":"text--G_600",sx:{typography:{md:"plim-R-link-1",xs:"plim-R-link-2"}},children:(0,x.jsx)(o.cC,{id:"p/Gc5S"})})},"1"),(0,x.jsx)(s.Z,{href:t==r.CHECK_ELIGIBILITY?"/customer/dashboard/bnpl/select-plan/".concat(i):void 0,sx:f({textDecoration:"none",cursor:"auto"},t==r.CHECK_ELIGIBILITY&&{cursor:"pointer!important"}),children:(0,x.jsx)(a.Z,{className:t==r.SELECT_PLAN?"text--black":"text--G_600",sx:{typography:{md:"plim-R-link-1",xs:"plim-R-link-2"}},children:(0,x.jsx)(o.cC,{id:"AUwkyI"})})},"2"),(0,x.jsx)(a.Z,{className:t==r.CHECK_ELIGIBILITY?"text--black":"text--G_600",sx:{typography:{md:"plim-R-link-1",xs:"plim-R-link-2"}},children:(0,x.jsx)(o.cC,{id:"Eus1Wo"})},"3")],g=(0,p.Z)();return(0,x.jsxs)(d.Z,{children:[(0,x.jsx)(d.Z,{component:"div",display:"flex",flexDirection:"row",justifyContent:"flex-start",alignItems:"center",sx:{mt:"3px",width:"100%",mb:{md:"64px",xs:"32px"}},children:(0,x.jsx)(l.Z,{spacing:2,children:(0,x.jsx)(c.Z,{sx:{"& .MuiBreadcrumbs-separator":{mx:{xs:"0",md:"8px"}}},separator:(0,x.jsx)(u.Z,{fontSize:g?"small":"medium"}),"aria-label":"breadcrumb",children:h})})}),n]})}},44884:function(e,t,n){"use strict";var r=n(59499),i=(n(73935),n(20745)),o=n(92096),s=n(49837),a=n(59742),l=n(91359),c=n(29630),d=n(80562),u=n(67294),p=n(5714),x=n(32845),m=n(31950),f=n(60577),h=n.n(f),g=n(11163),v=n(85893);function y(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function b(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?y(Object(n),!0).forEach((function(t){(0,r.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):y(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var j=function(e){var t,n=e.title,r=e.message,i=e.onClose,f=e.acceptButtonTitle,y=e.cancelButtonTitle,j=e.acceptButtonOnClick,_=e.cancelButtonOnClick,w=e.acceptButtonVariant,Z=e.cancelButtonVariant,C=e.buttonsSx,k=e.cardButtonsSx,O=(0,u.useState)(!0),S=O[0],P=O[1],E=(0,m.Z)(),I=(0,g.useRouter)(),N={width:E?"90%":"unset",position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",minWidth:E?"unset":300,borderColor:h().whiteP1,boxShadow:24,borderRadius:4,"& .MuiCardContent-root":{paddingX:"56px"}},R=!(null!==I&&void 0!==I&&null!==(t=I.pathname)&&void 0!==t&&t.includes("/clinic/")),D=R?{fontSize:"16px!important",fontWeight:"400!important",width:"185px!important",height:"48px",borderColor:h().G_400,"&:hover":{backgroundColor:h().G_000,boxShadow:"none"},"&:focus":{border:"2px solid ".concat(h().S_700,"!important"),backgroundColor:h().G_000,boxShadow:"none"},"&:active":{backgroundColor:h().G_000,border:"none",boxShadow:"none"},"&:disabled":{backgroundColor:h().G_000,color:h().black,border:"none",opacity:.5,boxShadow:"none"}}:{},A=R?{color:h().black,fontSize:"16px!important",fontWeight:"400!important",width:"185px!important",height:"48px","&:hover":{boxShadow:"none",backgroundColor:h().secondary},"&:focus":{boxShadow:"none",backgroundColor:h().main,border:"2px solid ".concat(h().P_600)},"&:active":{boxShadow:"none",border:"none"},"&:disabled":{boxShadow:"none",backgroundColor:h().P_23,opacity:.5}}:{},B=R?{backgroundColor:h().G_400,fontSize:"16px!important",fontWeight:"400!important",width:"185px!important",height:"48px","&:hover":{backgroundColor:h().G_500},"&:focus":{border:"2px solid ".concat(h().P_500)},"&:active":{backgroundColor:h().G_500},"&:disabled":{backgroundColor:h().G_900,color:h().black,opacity:.5}}:{};return(0,v.jsx)(o.Z,{open:S,onClose:function(){return P(!0)},"aria-labelledby":"modal-modal-title","aria-describedby":"modal-modal-description",children:(0,v.jsxs)(s.Z,{sx:N,children:[(0,v.jsx)(a.Z,{sx:{paddingBottom:0},action:(0,v.jsx)(d.Z,{"aria-label":"settings",onClick:function(){i&&i(),P(!1)},children:(0,v.jsx)(p.Pb8,{})})}),(0,v.jsx)(l.Z,{sx:{display:"flex",justifyContent:"center"},children:(0,v.jsx)(c.Z,{id:"modal-modal-title",className:"popup-modal-title",textAlign:"center",children:n})}),r&&(0,v.jsx)(l.Z,{sx:{display:"flex",justifyContent:"center",paddingX:E?"0px":"61px"},children:(0,v.jsx)(c.Z,{textAlign:"center",className:"popup-modal-description",id:"modal-modal-description",children:r})}),(0,v.jsxs)(l.Z,{sx:b({display:"flex",justifyContent:"center",mb:"32px",px:E?"5px":"16px"},k),children:["gray"===Z?(0,v.jsx)(x.Z,{sx:b(b({mr:"18px",width:"177px",boxShadow:"none",fontSize:"14px",fontWeight:600,textTransform:"none",backgroundColor:h().secondaryP0_2,color:h().black,"&:hover":{boxShadow:"none",color:h().black,backgroundColor:h().secondaryP0_2}},B),C),onClick:function(){P(!1),_&&_()},children:null!==y&&void 0!==y?y:""}):(0,v.jsx)(x.Z,{sx:b(b({mr:"18px",width:"177px",boxShadow:"none",fontSize:"14px",fontWeight:600,backgroundColor:"#ffffff",border:"1px solid",borderColor:h().black,color:h().black,"&:hover":{boxShadow:"none",backgroundColor:"#ffffff",color:h().black,border:"1px solid",borderColor:h().main},textTransform:"none"},D),C),onClick:function(){P(!1),_&&_()},children:null!==y&&void 0!==y?y:""}),"black"===w?(0,v.jsx)(x.Z,{id:"popup-confirm-button",variant:w,sx:b({width:"177px",boxShadow:"none",fontSize:"14px",fontWeight:600,backgroundColor:h().black,"&:hover":{backgroundColor:h().black8,color:h().white,boxShadow:"none"},"&:disabled":{backgroundColor:h().main,color:h().white,opacity:.5},color:h().white,textTransform:"none"},C),onClick:function(){P(!1),j&&j()},children:null!==f&&void 0!==f?f:""}):(0,v.jsx)(x.Z,{id:"popup-confirm-button",sx:b(b({width:"177px",boxShadow:"none",fontSize:"14px",fontWeight:600,backgroundColor:h().main,"&:hover":{backgroundColor:h().secondaryP4,color:h().black,border:"1px solid",borderColor:h().secondaryP4,boxShadow:"none"},"&:disabled":{backgroundColor:h().main,color:h().white,opacity:.5},color:h().white,textTransform:"none"},A),C),onClick:function(){P(!1),j&&j()},children:null!==f&&void 0!==f?f:""})]})]})})};t.Z=function(e,t,n,r,o,s,a,l,c,d,u){var p=document.createElement("div");document.body.appendChild(p);var x=function(){return(0,v.jsx)(j,{title:e,message:t,onClose:n,acceptButtonTitle:r,cancelButtonTitle:o,acceptButtonOnClick:s,cancelButtonOnClick:a,cancelButtonVariant:c,acceptButtonVariant:l,buttonsSx:d,cardButtonsSx:u})};i.createRoot(p).render((0,v.jsx)(x,{}))}},70428:function(e,t,n){"use strict";var r=n(59499),i=n(4361),o=n(89555),s=n(67294),a=n(29620),l=n(77745),c=n(30120),d=n(29630),u=n(95398),p=n(9942),x=n(76779),m=n(20845),f=n(5714),h=n(32845),g=n(42708),v=n(60985),y=n(85893);t.Z=function(e){var t,n,b=e.open,j=e.setOpen,_=e.onSubmit,w=e.steps,Z=(0,m.Z)(),C=(0,s.useRef)(null),k=(0,s.use
1State)(0),O=k[0],S=k[1],P=(0,s.useState)(!1),E=P[0],I=P[1],N=(0,g.YD)({threshold:.1}),R=N.ref,D=N.inView;!function(e,t){(0,s.useEffect)((function(){var n=function(e){t.current&&!t.current.contains(e.target)&&e.preventDefault()};return e?setTimeout((function(){document.body.style.overflow="hidden!important",document.addEventListener("touchmove",n,{passive:!1})}),100):(document.body.style.overflow="auto",document.removeEventListener("touchmove",n)),function(){document.body.style.overflow="auto",document.removeEventListener("touchmove",n)}}),[e,t])}(b,C),function(e,t,n,r,i){var o=(0,s.useRef)(!1);(0,s.useEffect)((function(){e&&n(!0)}),[e,n]),(0,s.useEffect)((function(){e&&(n(!0),o.current=!0)}),[e,i,n]),(0,s.useEffect)((function(){var e=function(){t&&n(!1)};return window.addEventListener("wheel",e),window.addEventListener("touchmove",e),function(){window.removeEventListener("wheel",e),window.removeEventListener("touchmove",e)}}),[t,n]),(0,s.useEffect)((function(){var e=function(e){o.current?o.current=!1:r.current&&t&&n(!1)},i=r.current;return i&&i.addEventListener("scroll",e),function(){i&&i.removeEventListener("scroll",e)}}),[r,t,n])}(b,E,I,C,O),(0,s.useEffect)((function(){b&&S(0)}),[b]),(0,s.useEffect)((function(){C.current&&C.current.scrollTo(0,0)}),[O]);var A=function(e,t){"backdropClick"===t&&E||(j(!1),I(!1))};return(0,y.jsx)(y.Fragment,{children:(0,y.jsxs)(a.Z,{fullWidth:!0,maxWidth:"md",open:b,onClose:A,disableEscapeKeyDown:!0,sx:{".MuiPaper-root":{maxHeight:"70%"}},children:[(0,y.jsxs)(l.Z,{id:"step-modal-title",className:"d-flex justify-between full-width",sx:{gap:"24px",p:"24px"},children:[(0,y.jsxs)(c.Z,{className:"d-flex justify-start",sx:{gap:{xs:"10px",md:"24px"}},children:[0!==O&&(0,y.jsx)(f.b_e,{onClick:function(){O>0?S(O-1):j(!1)},style:{cursor:"pointer"},className:"svg--black",role:"button"}),(0,y.jsxs)(d.Z,{sx:function(e){return(0,r.Z)({letterSpacing:"-0.325px",lineHeight:"40px",typography:{xs:"plim-R-link-1",md:"plim-H3B-temp"},color:"main"},e.breakpoints.down(412),{typography:"plim-p3R"})},children:[O+1,". ",null===(t=w[O])||void 0===t?void 0:t.title]})]}),(0,y.jsx)(f.x8P,{onClick:A,style:{cursor:"pointer"}})]}),(0,y.jsxs)(u.Z,{className:"d-flex flex-column justify-start align-start step-modal-dialog-content",sx:{mx:"24px",p:"0",pr:"16px",pb:"5px",userSelect:"none"},ref:C,children:[(0,y.jsx)(p.Z,{in:E,timeout:400,unmountOnExit:!0,children:(0,y.jsx)(c.Z,{sx:{mb:"24px"},className:"guide-message-step-modal-tooltip-container",children:(0,y.jsxs)(c.Z,{sx:{display:"flex",alignItems:"center",justifyContent:"center",gap:"12px",borderRadius:"4px"},className:"bg--black",children:[(0,y.jsx)(d.Z,{sx:{typography:{xs:"plim-p3R",md:"plim-R-link-2"},width:{sm:"auto"}},className:"bg--black justify-center text-center guide-message-step-modal-text",children:(0,y.jsx)(i.cC,{id:"Lb/G0+"})}),(0,y.jsx)(c.Z,{sx:{display:"flex",pr:"4px"},children:(0,y.jsx)(f.QBC,{width:Z?"24px":"32px",height:Z?"24px":"32px"})})]})})}),(0,y.jsx)(c.Z,{dangerouslySetInnerHTML:{__html:(0,v.Lw)(null===(n=w[O])||void 0===n?void 0:n.content)||o.ag._({id:"Kav4av"})},sx:{typography:"plim-R-link-1",lineHeight:"150%"}}),(0,y.jsx)(c.Z,{ref:R})]}),(0,y.jsx)(x.Z,{sx:{height:"97px",p:"24px"},children:(0,y.jsx)(h.Z,{variant:"marketplace-black",sx:function(e){return(0,r.Z)({alignSelf:"flex-end",height:"50px",visibility:D?"visible":"hidden"},e.breakpoints.down(412),{typography:"plim-p4R"})},onClick:function(){O<w.length-1?S(O+1):(_(),j(!1))},disabled:!D,children:(0,y.jsx)(i.cC,{id:"tImWq0"})})})]})})}},43548:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Se}});var r=n(16835),i=n(59499),o=n(67294),s=n(87536),a=n(7426),l=n(66376),c=n(27484),d=n.n(c),u=n(89555),p=n(50029),x=n(87794),m=n.n(x),f=n(4361),h=n(77566),g=n(30120),v=n(29630),y=n(79072),b=n(81811),j=n(32845),_=n(15204),w=n(38687),Z=n(91703),C=n(78918),k=n(19458),O=n(60985),S=n(68346),P=n(5714),E=n(75849),I=n(84250),N=n(85893),R=function(e){var t=e.planInfo,n=e.bnplUuid,r=(0,a.ZP)(),i=(0,I.Fc)();return(0,N.jsxs)(g.Z,{className:"marketplace-customer-bnpl-invite-detail bg--G_000",sx:{mb:"14px",mt:{md:"64px",xs:"24px"}},children:[(0,N.jsxs)(g.Z,{className:"d-flex justify-between ",sx:{mb:"10px"},children:[(0,N.jsx)(g.Z,{className:"d-flex align-center",children:(0,N.jsxs)(g.Z,{children:[(0,N.jsx)(v.Z,{sx:{typography:{md:"plim-H3B",xs:"plim-H4R"}},component:"h1",children:null===t||void 0===t?void 0:t.plan_name}),(0,N.jsxs)(g.Z,{className:"d-flex",sx:{mt:"5px"},children:[(0,N.jsx)(P.Uig,{}),(0,N.jsx)(v.Z,{variant:"plim-R-link-1",color:"black",sx:{mx:"8px"},children:(0,N.jsx)(f.cC,{id:"nmmCcL",values:{0:null===t||void 0===t?void 0:t.interest_percent}})})]})]})}),(0,N.jsxs)(g.Z,{className:"text-right",children:[(0,N.jsx)(S.Z,{className:"link no-underline",onClick:function(e){e.preventDefault(),r.customPush("/customer/dashboard/bnpl/select-plan/".concat(n))},children:(0,N.jsx)(v.Z,{variant:"plim-R-link-1",color:"main",children:(0,N.jsx)(f.cC,{id:"wRtBJP"})})}),(0,N.jsxs)(g.Z,{className:"d-flex",children:[(0,N.jsxs)(v.Z,{sx:{typography:{md:"plim-H3B",xs:"plim-R-link-1"}},color:"black",component:"h1",children:[i.currency_acronym,null===t||void 0===t?void 0:t.per_month]}),(0,N.jsxs)(v.Z,{color:"G_800",sx:{ml:"5px",typography:{md:"plim-H4R",xs:"plim-R-link-1"}},children:["/",(0,N.jsx)(f.cC,{id:"HajiZl"})]})]})]})]}),(0,N.jsx)(E.Z,{type:"info",children:(0,N.jsx)(f.cC,{id:"KIUykw",values:{0:i.currency_acronym,1:null===t||void 0===t?void 0:t.deposit_amount}})})]})},D=n(83879),A=n(44884),B=n(39860),L=n(31950),T=n(20543);function Y(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function V(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];
1if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"===typeof e)return M(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return M(e,t)}(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw o}}}}function M(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var F=function(e){var t=e.control,n=e.setValue,c=e.watch,u=e.errors,p=e.getValues,x=e.resetField,m=e.serverError,h=(0,a.ZP)(),y=h.query.uuid?h.query.uuid:void 0,b=(0,o.useState)(!0),j=(b[0],b[1]),w=(0,o.useState)(!0),Z=w[0],C=w[1],k=(0,o.useState)(0),S=k[0],P=k[1],E=(0,o.useState)(!0),I=E[0],R=E[1],D=(0,s.Dq)({control:t,name:"addresses"}),A=D.fields,B=D.append,L=D.remove;(0,o.useEffect)((function(){return function(){return M()}}),[]),(0,o.useEffect)((function(){for(var e=A.length,t=e;t<S;t++)F(t);for(var n=e-1;n>=S;n--)U(n)}),[S,I]),(0,o.useEffect)((function(){c((function(e,t){var n=t.name,r=t.type;if("addresses[0].living_time_is_long"===n&&"change"===r&&(1==(0,O.GR)(e,n)?P(1):P(2)),null!==n&&void 0!==n&&n.includes("start_living_date")&&"change"===r){var i,o,s=(0,O.GR)(e,n),a=parseInt(null===(i=n.split("["))||void 0===i||null===(o=i[1].split("]"))||void 0===o?void 0:o[0]),l=d()().diff(s,"month");0!=a&&l>0&&l<=12?P(a+2):0!=a&&l>12&&P(a+1)}e.agree?j(!1):j(!0)}))}),[c]);var M=function(){x("addresses",{defaultValue:[]}),P(0)},F=function(e){if(A.length>e)return{};B({address_line1:"",address_line2:"",building_number:"",town_city:"",post_code:"",start_living_date:null,living_time_is_long:"",uuid:"",canton:void 0})},U=function(e){A.length>1&&A.length>e&&L(e)},H=function(){if(C(!0),y){(0,l.ZP)(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Y(Object(n),!0).forEach((function(t){(0,i.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Y(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({url:"/api/bnpl-addresses/?bnplloan__uuid=".concat(y)},{method:"GET",headers:{"Content-Type":"application/json"}})).then((function(e){!function(e){M();var t,n=V(e.entries());try{for(n.s();!(t=n.n()).done;){var i=(0,r.Z)(t.value,2),o=(i[0],i[1]);B({address_line1:o.address_line1,address_line2:o.address_line2,building_number:o.building_number,town_city:o.town_city,post_code:o.post_code,start_living_date:o.start_living_date?d()(o.start_living_date,"YYYY-MM"):null,living_time_is_long:1==o.living_time_is_long?"1":"2",uuid:o.uuid,canton:{name:o.canton},address_line_with_house_number:o.address_line1})}}catch(s){n.e(s)}finally{n.f()}P(0==e.length?1:e.length),0==e.length&&R((function(e){return!e}))}(e.data)})).finally((function(){return C(!1)}))}};return(0,o.useEffect)((function(){H()}),[h.isReady,null===h||void 0===h?void 0:h.locale]),(0,N.jsx)(g.Z,{children:Z?(0,N.jsx)(_.Z,{skeletonList:[[{type:"rectangular",height:150}],[{type:"rectangular",height:300}],[{type:"rectangular",height:200}]]}):(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(v.Z,{variant:"plim-H4R",color:"black",sx:{mt:"31px"},component:"h1",children:(0,N.jsx)(f.cC,{id:"YYaKLa"})}),(0,N.jsx)(v.Z,{variant:"plim-p1",color:"black_stroke",sx:{mt:"5px"},children:(0,N.jsx)(f.cC,{id:"jrJEln"})}),(0,N.jsx)(g.Z,{sx:{mt:"20px"},children:A.map((function(e,r){return(0,N.jsx)(T.yw,{errors:u,serverError:m,control:t,setValue:n,getValues:p,showLivingLongTime:0==r,name_prefix:"addresses[".concat(r,"]"),index:r},e.id)}))})]})})},U=n(49837),H=n(48091),q=n(25108),W=n(20120),G=n(25675),z=n.n(G),X=n(60577),K=n.n(X),J=n(78298),Q=n(13379),$=n(80562),ee=n(20845),te=function(e){var t=e.finishCallback,n=e.type,r=[{image:"/assets/images/credit-assesment-amico-1.png",width:"209px",height:"174px",title:u.ag._({i
1d:"mE9CeC"}),description:u.ag._({id:"rsxDGx"})},{image:"/assets/images/freepik-character-inject-2.png",width:"177px",height:"156px",title:u.ag._({id:"kcrQkj"}),description:u.ag._({id:"4Yiuln"})},{image:"/assets/images/security-pana-1.png",width:"255px",height:"179px",title:u.ag._({id:"AKMRv2"}),description:u.ag._({id:"Cy7y5w"})}],i=(0,o.useState)(0),s=i[0],a=i[1],l=(0,ee.Z)();return(0,N.jsxs)(N.Fragment,{children:["dialog"==n&&(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[(0,N.jsx)(z(),{src:r[s].image,width:350,height:260,alt:r[s].title}),(0,N.jsx)(v.Z,{color:"whiteP10",sx:{mt:"27px",mb:"12px",typography:{md:"font-21-600",xs:"font-18-600"}},textAlign:"center",children:r[s].title}),(0,N.jsx)(v.Z,{component:"p",color:"whiteP5",sx:{mb:"33px",typography:{md:"font-15-400",xs:"font-14-400"}},textAlign:"center",children:r[s].description}),(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",children:[(0,N.jsx)(g.Z,{className:"stepper-rectangle "+(0==s?"active":""),component:"div",sx:{mr:"3px"}}),(0,N.jsx)(g.Z,{className:"stepper-rectangle "+(1==s?"active":""),component:"div",sx:{mr:"3px"}}),(0,N.jsx)(g.Z,{className:"stepper-rectangle "+(2==s?"active":""),component:"div"})]}),(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"row",justifyContent:"flex-end",alignItems:"center",sx:{width:"100%",mt:{md:0,sm:"2px",xs:"15px"}},children:[0!=s&&(0,N.jsx)(j.Z,{variant:"text",sx:{color:K().whiteP6,typography:"font-15-600",height:{md:"44px!important",sm:"32px!important",xs:"24px!important"},minWidth:{md:"64px!important",sm:"44px!important",xs:"20px!important"}},onClick:function(){return a((function(e){return e-1}))},children:(0,N.jsx)(f.cC,{id:"iH8pgl"})}),s<2&&(0,N.jsx)(j.Z,{variant:"text",onClick:function(){return a((function(e){return e+1}))},sx:{typography:"font-15-600",height:{md:"44px!important",sm:"32px!important",xs:"24px!important"},minWidth:{md:"64px!important",sm:"44px!important",xs:"20px!important"}},children:(0,N.jsx)(f.cC,{id:"hXzOVo"})}),2==s&&(0,N.jsx)(j.Z,{variant:"text",onClick:t,sx:{typography:"font-15-600",height:{md:"44px!important",sm:"32px!important",xs:"24px!important"},minWidth:{md:"64px!important",sm:"44px!important",xs:"20px!important"}},children:(0,N.jsx)(f.cC,{id:"JmZ/+d"})})]})]}),"slider"==n&&(0,N.jsxs)(N.Fragment,{children:[(0,N.jsxs)(y.ZP,{container:!0,alignItems:"start",children:[(0,N.jsx)(y.ZP,{item:!0,md:2,sm:3,xs:4,children:(0,N.jsx)("img",{src:r[s].image,style:{width:"100%",height:l?"100%":"200px"},alt:r[s].title})}),(0,N.jsx)(y.ZP,{item:!0,md:10,sm:9,xs:8,children:(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"flex-start",sx:{ml:{md:"52px",sm:"10px",xs:"10px"},mt:"25px"},children:[(0,N.jsx)(v.Z,{color:"whiteP10",sx:{mb:"12px",typography:{md:"font-24-600",xs:"font-18-600"}},children:r[s].title}),(0,N.jsx)(v.Z,{color:"whiteP5",sx:{maxWidth:{md:"85%",sm:"85%",xs:"100%"},typography:{md:"font-15-400",xs:"font-14-400"}},textAlign:"justify",children:r[s].description})]})})]}),(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"row",justifyContent:"flex-end",alignItems:"center",sx:{width:"100%",mt:{md:"-20px",sm:"10px",xs:"5px"}},children:[(0,N.jsx)($.Z,{className:"stepper-arrow",sx:{mr:"10px",padding:"5px"},onClick:function(){return a((function(e){return e-1}))},disabled:0==s,children:(0,N.jsx)(J.Z,{sx:{color:K().mainContainerBackground,fontSize:{md:"1.25rem",sm:"0.7rem",xs:"0.5rem"}}})}),(0,N.jsx)($.Z,{className:"stepper-arrow",sx:{padding:"5px"},onClick:function(){return a((function(e){return e+1}))},disabled:2==s,children:(0,N.jsx)(Q.Z,{sx:{color:K().mainContainerBackground,fontSize:{md:"1.25rem",sm:"0.7rem",xs:"0.5rem"}}})})]})]})]})},ne=n(29620),re=function(e){var t=e.finishCallback,n=e.type,r=[{image:"/assets/images/credit-assesment-amico-1.png",width:"209px",height:"174px",title:u.ag._({id:"mE9CeC"}),description:u.ag._({id:"rsxDGx"})},{image:"/assets/images/freepik-character-inject-2.png",width:"177px",height:"156px",title:u.ag._({id:"kcrQkj"}),description:u.ag._({id:"4Yiuln"})},{image:"/assets/images/security-pana-1.png",width:"255px",height:"179px",title:u.ag._({i
1d:"AKMRv2"}),description:u.ag._({id:"Cy7y5w"})}],i=(0,o.useState)(0),s=i[0],a=i[1];return(0,N.jsxs)(N.Fragment,{children:["dialog"==n&&(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[(0,N.jsx)(z(),{src:r[s].image,width:350,height:260,alt:r[s].title}),(0,N.jsx)(v.Z,{color:"whiteP10",sx:{mt:"27px",mb:"12px",typography:{md:"font-21-600",xs:"font-18-600"}},textAlign:"center",children:r[s].title}),(0,N.jsx)(v.Z,{color:"whiteP5",sx:{mb:"33px",typography:{md:"font-15-400",xs:"font-14-400"}},textAlign:"center",children:r[s].description}),(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",children:[(0,N.jsx)(g.Z,{className:"stepper-rectangle "+(0==s?"active":""),component:"div",sx:{mr:"3px"}}),(0,N.jsx)(g.Z,{className:"stepper-rectangle "+(1==s?"active":""),component:"div",sx:{mr:"3px"}}),(0,N.jsx)(g.Z,{className:"stepper-rectangle "+(2==s?"active":""),component:"div"})]}),(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"row",justifyContent:"flex-end",alignItems:"center",sx:{width:"100%",mt:{md:0,sm:"2px",xs:"15px"}},children:[0!=s&&(0,N.jsx)(j.Z,{variant:"text",sx:{color:K().whiteP6,typography:"font-15-600",height:{md:"4px!important",sm:"32px!important",xs:"24px!important"},minWidth:{md:"64px!important",sm:"44px!important",xs:"20px!important"}},onClick:function(){return a((function(e){return e-1}))},children:(0,N.jsx)(f.cC,{id:"iH8pgl"})}),s<2&&(0,N.jsx)(j.Z,{variant:"text",onClick:function(){return a((function(e){return e+1}))},sx:{typography:"font-15-600",height:{md:"44px!important",sm:"32px!important",xs:"24px!important"},minWidth:{md:"64px!important",sm:"44px!important",xs:"20px!important"}},children:(0,N.jsx)(f.cC,{id:"hXzOVo"})}),2==s&&(0,N.jsx)(j.Z,{variant:"text",onClick:t,sx:{typography:"font-15-600",height:{md:"44px!important",sm:"32px!important",xs:"24px!important"},minWidth:{md:"64px!important",sm:"44px!important",xs:"20px!important"}},children:(0,N.jsx)(f.cC,{id:"JmZ/+d"})})]})]}),"slider"==n&&(0,N.jsxs)(N.Fragment,{children:[(0,N.jsxs)(y.ZP,{container:!0,alignItems:"center",children:[(0,N.jsx)(y.ZP,{item:!0,md:2,sm:3,xs:4,children:(0,N.jsx)("img",{src:r[s].image,style:{width:"100%",height:"100%"},alt:r[s].title})}),(0,N.jsx)(y.ZP,{item:!0,md:10,sm:9,xs:8,children:(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"flex-start",sx:{ml:{md:"52px",sm:"10px",xs:"10px"}},children:[(0,N.jsx)(v.Z,{color:"whiteP10",sx:{mb:"12px",typography:{md:"font-24-600",xs:"font-18-600"}},children:r[s].title}),(0,N.jsx)(v.Z,{variant:"medium-light",color:"whiteP5",sx:{maxWidth:{md:"85%",sm:"85%",xs:"100%"},typography:{md:"font-15-400",xs:"font-14-400"}},textAlign:"justify",children:r[s].description})]})})]}),(0,N.jsxs)(g.Z,{display:"flex",flexDirection:"row",justifyContent:"flex-end",alignItems:"center",sx:{width:"100%",mt:{md:"-20px",sm:"10px",xs:"5px"}},children:[(0,N.jsx)($.Z,{className:"stepper-arrow",sx:{mr:"10px",padding:"5px"},onClick:function(){return a((function(e){return e-1}))},disabled:0==s,children:(0,N.jsx)(J.Z,{sx:{color:K().mainContainerBackground,fontSize:{md:"1.25rem",sm:"0.7rem",xs:"0.5rem"}}})}),(0,N.jsx)($.Z,{className:"stepper-arrow",sx:{padding:"5px"},onClick:function(){return a((function(e){return e+1}))},disabled:2==s,children:(0,N.jsx)(Q.Z,{sx:{color:K().mainContainerBackground,fontSize:{md:"1.25rem",sm:"0.7rem",xs:"0.5rem"}}})})]})]})]})},ie=function(){var e=(0,o.useState)(!1),t=e[0],n=e[1];return(0,o.useEffect)((function(){setTimeout((function(){n(!0)}),5e3)}),[]),(0,N.jsx)(N.Fragment,{children:(0,N.jsx)(ne.Z,{open:t,maxWidth:"md",children:(0,N.jsx)(g.Z,{sx:{padding:"41px 31px 22px 31px"},children:(0,N.jsx)(re,{finishCallback:function(){return n(!1)},type:"dialog"})})})})},oe=n(47395),se=function(e){var t=e.control,n=e.watch,r=e.errors,i=e.planInfo,s=e.setting,c=e.children,d=e.bankError,u=e.consentForm,p=(e.setBankError,(0,a.ZP)()),x=p.query.uuid?p.query.uuid:void 0,m=(p.query.consent_status&&p.query.consent_status,p.query.error&&p.query.error,(0,o.useState)(null)),h=m[0],b=(m[1],(0,o.useRef)(null)),j=(0,o.useState)(!0),_=(j[0],j[1]),Z=(0,o.useState)(!1),C=(Z[0],Z[1],(0,o.useRef)()),P=(0,o.useState)(!1),E=(P[0],P[1],(0,o.useState)(!1)),I=E[0],R=E[1],D=(0,o.useState)([]),A=D[0],B=D[1];(0,o.useEffect)((function(){n((function(e,t){t.name,t.type;e.agree?_(!1):_(!0)}))}),[n]);return(0,o.useEffect)((function(){l.ZP.get("/api/open-banks/").then((function(e){B(null===e||void 0===e?void 0:e.data)}))}),[p.isReady]),(0,o.useEffect)((function(){var e;u.client&&(null===(e=C.current)||void 0===e||e.submit())}),[u]),(0,N.jsxs)(g.Z,{children:[(0,N.jsx)(ie,{}),(0,N.jsx)(k.Z,{open:I,setOpen:R,bnplUuid:x,bnplInviteNo:null===i||void 0===i?void 0:i.invite_number,type:"customer"}),(0,N.jsxs)(g.Z,{className:"d-flex justify-between",sx:{mt:{md:"42px",sm:"42px",xs:"32px"}},children:[(0,N.jsx)(v.Z,{sx:{typography:{md:"font-16-600",xs:"font-12-500"}},children:"Consent Confirmation"}),(0,N.jsx)(S.Z,{className:"link no-underline",onClick:function(e){var t;e.preventDefault(),null===(t=b.current)||void 0===t||t.scrollIntoView({behavior:"smooth"})},children:(0,N.jsx)(v.Z,{sx:{typography:{md:"font-16-600",xs:"font-12-500"}},children:(0,N.jsx)(f.cC,{id:"EJi5oB"})})})]}),(0,N.jsx)(v.Z,{variant:"medium-semi-bold",sx:{mt:"8px",typography:{md:"font-16-500",xs:"font-12-500"}},color:"whiteP6",component:"p",children:(0,N.jsx)(f.cC,{id:"LK6ahA"})}),(0,N.jsx)(q.Z,{transparentColor:!0,sx:{pt:{md:"18px",xs:0},px:{md:"28px",xs:"20px"},mt:"10px",pb:"0"},className:"bg--whiteP0",children:(0,N.jsx)(g.Z,{component:"div",sx:{mt:{md:0,sm:0,xs:"30px"}},children:(0,N.jsxs)(y.ZP,{container:!0,columnSpacing:"34px",rowSpacing:{md:"20px",sm:"20px",xs:0},children:[(0,N.jsx)(y.ZP,{md:8,sm:6,xs:12,item:!0,children:(0,N.jsx)(w.Z,{values:A,title:"verbose_name",name:"open_bank",control:t,label:"Bank name",errors:r,serverError:h,disableClearable:!0,rules:O.jN,
1className:"bg--white"})}),(0,N.jsx)(y.ZP,{md:4,sm:6,xs:12,item:!0,children:(0,N.jsx)(H.Z,{placeholder:"XXXX - XXX",name:"postal_code",control:t,label:"Postal Code",errors:r,serverError:h,sx:{mb:2},rules:O.jN,className:"bg--white"})})]})})}),(0,N.jsxs)(g.Z,{sx:{mt:"24px"},children:[(0,N.jsx)(oe.Z,{errors:r,control:t,setting:s}),(0,N.jsx)(W.Z,{main_name:"bank_issue",final_error:d})]}),c,(0,N.jsxs)(g.Z,{sx:{mt:"45px",mb:"26px"},ref:b,children:[(0,N.jsx)(v.Z,{component:"div",sx:{mb:"6px",typography:{md:"font-24-600",xs:"font-14-700"}},children:(0,N.jsx)(f.cC,{id:"o6+r5U"})}),(0,N.jsxs)(y.ZP,{container:!0,flexDirection:{md:"row",sm:"column",xs:"column"},spacing:{md:"42px",sm:"17px",xs:"17px"},children:[(0,N.jsx)(y.ZP,{item:!0,xs:!0,children:(0,N.jsxs)(U.Z,{sx:{paddingTop:"26px"},className:"marketplace-dashboard-card card-shadow",children:[(0,N.jsx)(v.Z,{variant:"large-semi-bold",component:"h5",sx:{mb:"14px",typography:{md:"font-18-500",xs:"font-14-500"}},children:(0,N.jsx)(f.cC,{id:"BHTD5F"})}),(0,N.jsx)(v.Z,{component:"h4",sx:{typography:{md:"font-14-400",xs:"font-10-400"}},color:"whiteP8_1",children:(0,N.jsx)(f.cC,{id:"VJM+Kv"})}),(0,N.jsxs)(v.Z,{sx:{typography:{md:"font-14-400",xs:"font-10-400"}},component:"h4",color:"whiteP8_1",children:["\u2022 ",(0,N.jsx)(f.cC,{id:"SJoWeb"})]}),(0,N.jsxs)(v.Z,{sx:{typography:{md:"font-14-400",xs:"font-10-400"}},component:"h4",color:"whiteP8_1",children:["\u2022"," ",(0,N.jsx)(f.cC,{id:"5hS+cc"})]}),(0,N.jsxs)(v.Z,{sx:{typography:{md:"font-14-400",xs:"font-10-400"}},component:"h4",color:"whiteP8_1",children:["\u2022"," ",(0,N.jsx)(f.cC,{id:"wdYttO"})]})]})}),(0,N.jsx)(y.ZP,{item:!0,xs:!0,children:(0,N.jsxs)(U.Z,{sx:{paddingTop:"26px"},className:"marketplace-dashboard-card card-shadow",children:[(0,N.jsx)(v.Z,{component:"h5",sx:{mb:"14px",typography:{md:"font-14-400",xs:"font-10-400"}},children:(0,N.jsx)(f.cC,{id:"vgU9TW"})}),(0,N.jsx)(v.Z,{sx:{typography:{md:"font-14-400",xs:"font-10-400"}},component:"h4",color:"whiteP8_1",children:(0,N.jsx)(f.cC,{id:"CzdygP"})}),(0,N.jsxs)(v.Z,{sx:{typography:{md:"font-14-400",xs:"font-10-400"}},component:"h4",color:"whiteP8_1",children:["\u2022 ",(0,N.jsx)(f.cC,{id:"PNFqgz"})]}),(0,N.jsxs)(v.Z,{sx:{typography:{md:"font-14-400",xs:"font-10-400"}},component:"h4",color:"whiteP8_1",children:["\u2022 ",(0,N.jsx)(f.cC,{id:"zmrzSe"})]}),(0,N.jsxs)(v.Z,{sx:{typography:{md:"font-14-400",xs:"font-10-400"}},component:"h4",color:"whiteP8_1",children:["\u2022 ",(0,N.jsx)(f.cC,{id:"lqXTuO"})]})]})})]}),(0,N.jsxs)(g.Z,{sx:{display:"none"},component:"form",method:"POST",ref:C,noValidate:!0,action:u.consentFormLink,children:[(0,N.jsx)("input",{readOnly:!0,name:"client",value:u.client}),(0,N.jsx)("input",{readOnly:!0,name:"externalRef",value:u.externalRef}),(0,N.jsx)("input",{readOnly:!0,name:"firstname",value:u.firstname}),(0,N.jsx)("input",{readOnly:!0,name:"lastName",value:u.lastName}),(0,N.jsx)("input",{readOnly:!0,name:"email",value:u.email}),(0,N.jsx)("input",{readOnly:!0,name:"telephone",value:u.telephone}),(0,N.jsx)("input",{readOnly:!0,name:"postcode",value:u.postcode}),null!==u&&void 0!==u&&u.completeUrl?(0,N.jsx)("input",{readOnly:!0,name:"completeUrl",value:u.completeUrl}):(0,N.jsx)(N.Fragment,{}),(0,N.jsx)("input",{readOnly:!0,name:"cancelUrl",value:u.cancelUrl}),(0,N.jsx)("input",{readOnly:!0,name:"startBank",value:u.startBank}),(0,N.jsx)("button",{id:"consent-submit",type:"submit",children:(0,N.jsx)(f.cC,{id:"dA0P1i"})})]})]}),(0,N.jsx)(U.Z,{className:"marketplace-dashboard-card card-shadow",sx:{paddingX:{md:"56px",sm:"11px",xs:"11px"},paddingY:{md:"27px",sm:"27px",xs:"17px"},mb:"120px",border:{md:"1px solid ".concat(K().whiteP1),sm:"1px solid ".concat(K().whiteP1),xs:"0.5px solid ".concat(K().secondary)}},children:(0,N.jsx)(te,{type:"slider"})})]})},ae=n(33732),le=n(54774),ce=n(95493),de=Math.pow;function ue(e){var t,n,r,i=e.targetPosition,o=e.initialPosition,s=e.duration,a=window.requestAnimationFrame,l=window.cancelAnimationFrame,c=document.documentElement.scrollHeight-document.documentElement.clientHeight,d=o-i;r=a((function e(i){void 0===t&&(t=i);var u=i-t,p=1-de(1-u/s,4);n=o-d*Math.min(p,1),window.scrollTo(0,n),o===c||window.scrollY!==c?u<s&&(r=a(e)):l(r)}))}var pe,xe,me=function(e){return e.getBoundingClientRect().y},fe=function(e){var t=e.element,n=e.duration,r=void 0===n?3e3:n,i=e.offset,o=window.scrollY;console.log("element",t),t?ue({targetPosition:window.scrollY+me(t)-i,initialPosition:o,duration:r}):console.error("Invalid element, are you sure you've provided element id or react ref?")},he=n(31812),ge=n(70428);function ve(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ye(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};
1t%2?ve(Object(n),!0).forEach((function(t){(0,i.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ve(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function be(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"===typeof e)return je(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return je(e,t)}(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}((function(e){throw e})),f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}((function(e){a=!0,o=e})),f:function(){try{s||null==n.return||n.return()}finally{if(a)throw o}}}}function je(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function _e(e){return e===pe.TRUE_VISION||e===pe.TRUE_VISION_PLUS_AFFORDABILITY||e===pe.MANUAL_CHECK||e===pe.CRIF}!function(e){e[e.TARYA=1]="TARYA",e[e.TRUE_VISION=2]="TRUE_VISION",e[e.TRUE_VISION_PLUS_AFFORDABILITY=3]="TRUE_VISION_PLUS_AFFORDABILITY",e[e.MANUAL_CHECK=4]="MANUAL_CHECK",e[e.CRIF=5]="CRIF"}(pe||(pe={})),function(e){e[e.Employed=1]="Employed",e[e.Self_Employed=2]="Self_Employed",e[e.Student=3]="Student",e[e.Unemployed=4]="Unemployed",e[e.Retired=5]="Retired"}(xe||(xe={}));var we=function(e){var t=e.control,n=e.handleSubmit,r=e.setValue,c=e.watch,x=e.errors,S=e.planInfo,P=e.setting,I=e.fetchLoading,Y=e.getValues,V=e.resetField,M=e.nonOpenBanking,U=e.setNonOpenBanking,H=e.genderList,q=e.clearErrors,W=e.setError,G=e.trigger,z=e.creditCheckSystem,X=e.titleList,J=(0,a.ZP)(),Q=J.query.uuid?J.query.uuid:void 0,$=(0,o.useState)(null),ee=$[0],te=$[1],ne=((0,o.useRef)(null),(0,o.useState)(!0)),re=(ne[0],ne[1],(0,o.useState)(!1)),ie=re[0],oe=re[1],de=(0,o.useState)(!1),ue=de[0],me=(de[1],(0,o.useState)(!1)),ve=me[0],je=me[1],we=(0,o.useState)({client:"",externalRef:"",firstname:"",lastName:"",email:"",telephone:"",postcode:"",completeUrl:"",cancelUrl:"",startBank:"",consentFormLink:""}),Ze=we[0],Ce=we[1],ke=(0,o.useState)(null),Oe=ke[0],Se=ke[1],Pe=(0,o.useState)(!0),Ee=Pe[0],Ie=Pe[1],Ne=(0,o.useState)({first_name:"",last_name:"",email:""}),Re=Ne[0],De=Ne[1],Ae=(0,o.useState)(0),Be=Ae[0],Le=Ae[1],Te=(0,o.useState)(!1),Ye=Te[0],Ve=Te[1],Me=(0,o.useState)([]),Fe=Me[0],Ue=Me[1];(0,o.useEffect)((function(){Ue([{title:(0,N.jsx)(f.cC,{id:"LcET2C"}),content:(null===P||void 0===P?void 0:P.privacy_policy)||""},{title:(0,N.jsx)(f.cC,{id:"nQdOSp"}),content:(null===P||void 0===P?void 0:P.terms_of_use)||""},{title:(0,N.jsx)(f.cC,{id:"5Opx8v"}),content:(null===P||void 0===P?void 0:P.release_and_waiver)||""}])}),[P]);var He=(0,s.Dq)({control:t,name:"addresses"}),qe=(He.fields,He.append,He.remove,(0,ae.U5)().today_date);(0,o.useEffect)((function(){c((function(e,t){var n,r,o=t.name,s=t.type;if("employment_type"===o){var a,l,c=(a={},(0,i.Z)(a,xe.Employed,xe.Employed),(0,i.Z)(a,xe.Self_Employed,xe.Self_Employed),(0,i.Z)(a,xe.Student,xe.Student),(0,i.Z)(a,xe.Unemployed,xe.Unemployed),(0,i.Z)(a,xe.Retired,xe.Retired),a)[null===(l=e.employment_type)||void 0===l?void 0:l.id];c&&Le(c)}"have_address_history"==o&&"1"==e.have_address_history?U(!0):"have_address_history"==o&&"2"==e.have_address_history&&U(!1),"gender"==o&&(null===e||void 0===e||null===(n=e.gender)||void 0===n?void 0:n.id)==(null===(r=H[2])||void 0===r?void 0:r.id)&&"change"==s&&(0,C.Z)(u.ag._({i
1d:"VjHRWM"}),u.ag._({id:"GY0Mot"}))}))}),[c]);var We=function(){je(!0)},Ge=function(){var e=(0,p.Z)(m().mark((function e(){return m().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,G("soft_credit_check_acknowledged");case 2:if(e.sent){e.next=5;break}return e.abrupt("return");case 5:G().then((function(){if(x&&0!==Object.keys(x).length||ze(Y("addresses")),x&&0!==Object.keys(x).length){var e=Object.keys(x).map((function(e){return document.getElementsByName(e)[0]})).filter((function(e){return!!e})),t=[];if(Object.keys(x).includes("addresses")&&function(){var e,n=0,r=be(null===x||void 0===x?void 0:x.addresses);try{for(r.s();!(e=r.n()).done;){var i=e.value;if(i&&0!==(t=Object.keys(i).map((function(e){return document.getElementsByName("addresses[".concat(n,"].").concat(e))[0]})).filter((function(e){return!!e}))).length)break;n++}}catch(o){r.e(o)}finally{r.f()}}(),(e=e.concat(t)).sort((function(e,t){return e.getBoundingClientRect().top-t.getBoundingClientRect().top})),e.length>0){var n=e[0];fe({element:n,duration:1e3,offset:100})}}else{var r=u.ag._({id:"dpVg1+"});_e(z)&&!0!==M&&(r=u.ag._({id:"+AR67A"})),(0,A.Z)(u.ag._({id:"OeHCJJ"}),r,(function(){}
1),u.ag._({id:"EMXiZP"}),u.ag._({id:"hoaavJ"}),(function(){Ve(!0)}),(function(){}),void 0,void 0,{width:{sm:"231px",xs:"100%"},whiteSpace:"nowrap"},{flexDirection:{sm:"row",xs:"column-reverse"},gap:{sm:"unset",xs:"10px"}})}}));case 6:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),ze=function(e){var t,n=null,r=0,i=d()(qe,"YYYY-MM-DD"),o=be(e);try{for(o.s();!(t=o.n()).done;){var s=t.value;if(s.start_living_date>i)return W("addresses[".concat(r,"].start_living_date"),{type:"manual",message:u.ag._({id:"B/BAOp"})}),!1;if(n&&n<=s.start_living_date)return W("addresses[".concat(r,"].start_living_date"),{type:"manual",message:u.ag._({id:"AQ6rSN"})}),!1;r++,n=s.start_living_date}}catch(a){o.e(a)}finally{o.f()}return!0},Xe=function(e){if(void 0==e)return W("birthdate",{type:"manual",message:u.ag._({id:"UwqoLj"})}),Ie(!1),!1;if(!e.isValid())return W("birthdate",{type:"manual",message:u.ag._({id:"A2sQmA"})}),Ie(!1),!1;var t=d()(qe,"YYYY-MM-DD");return e>t?(W("birthdate",{type:"manual",message:u.ag._({id:"B/BAOp"})}),Ie(!1),!1):t.diff(e,"year",!0)<18?(W("birthdate",{type:"manual",message:u.ag._({id:"PlV9n1"})}),Ie(!1),!1):(q("birthdate"),Ie(!0),!0)},Ke=function(e){var t,n,r,i;if(Xe(null===e||void 0===e?void 0:e.birthdate)&&ze(null===e||void 0===e?void 0:e.addresses)){delete e.soft_credit_check_acknowledged,oe(!0),e.open_bank=null===e||void 0===e||null===(t=e.open_bank)||void 0===t?void 0:t.id,1==(null===e||void 0===e||null===(n=e.gender)||void 0===n?void 0:n.id)?e.gender=1:2==(null===e||void 0===e||null===(r=e.gender)||void 0===r?void 0:r.id)?e.gender=2:e.gender=3,e.title=X.filter((function(t){return t.id===e.title.id}))[0].id,e.employment_type=null===e||void 0===e||null===(i=e.employment_type)||void 0===i?void 0:i.id,e.birthdate=null===e||void 0===e?void 0:e.birthdate.format("DD/MM/YYYY"),e.have_address_history="1"==(null===e||void 0===e?void 0:e.have_address_history);var o,s=be(null===e||void 0===e?void 0:e.addresses);try{for(s.s();!(o=s.n()).done;){var a,c=o.value;null!==c&&void 0!==c&&c.start_living_date?c.start_living_date=c.start_living_date.format("YYYY-MM"):c.start_living_date=void 0,c.living_time_is_long="1"==(null===c||void 0===c?void 0:c.living_time_is_long),c.canton=null===c||void 0===c||null===(a=c.canton)||void 0===a?void 0:a.name}}catch(x){s.e(x)}finally{s.f()}try{var d;e.annual_income=Number(null===e||void 0===e||null===(d=e.annual_income)||void 0===d?void 0:d.replace(/,/g,""))}catch(m){e.annual_income=0}var p={method:"PUT",headers:{"Content-Type":"application/json"},data:e};(0,l.ZP)(ye({url:"/api/update-personal-info/".concat(Q,"/")},p)).then((function(e){var t,n,r,i,o;if(te(null),oe(!1),null!==e&&void 0!==e&&null!==(t=e.data)&&void 0!==t&&t.bank_is_down)return Se({bank_issue:{message:u.ag._({id:"ET+fRe"})}}),void(0,C.Z)(u.ag._({id:"rXZkrC"}
1),u.ag._({id:"3O8wof"}),"error",void 0,(function(){}),void 0,void 0);if(null!==e&&void 0!==e&&null!==(n=e.data)&&void 0!==n&&n.consent_is_down)return Se({bank_issue:{message:u.ag._({id:"UTQqXM"})}}),void(0,C.Z)(u.ag._({id:"s+2r07"}),u.ag._({id:"yQBrlx"}),"error",{url:"/assets/images/credit-score-checking-error.png",width:"300px",height:"200px"},(function(){}),void 0,void 0);null!==e&&void 0!==e&&null!==(r=e.data)&&void 0!==r&&r.link?J.customPush(null===e||void 0===e||null===(o=e.data)||void 0===o?void 0:o.link):(Se(null),Ce(null===(i=e.data)||void 0===i?void 0:i.consent_data))})).catch((function(e){var t,n,r;if(oe(!1),e&&null!==e&&void 0!==e&&e.response&&null!==e&&void 0!==e&&null!==(t=e.response)&&void 0!==t&&t.data&&Array.isArray(null===e||void 0===e||null===(n=e.response)||void 0===n?void 0:n.data)){var i,o=[],s=be(null===e||void 0===e||null===(r=e.response)||void 0===r?void 0:r.data);try{for(s.s();!(i=s.n()).done;){var a=i.value,l={},c=null===a||void 0===a?void 0:a.messages;for(var d in c)l[c[d].field]={message:c[d].message};o.push(l)}}catch(x){s.e(x)}finally{s.f()}te(o)}else te(e.errorList)}))}},Je=(0,L.Z)();(0,o.useEffect)((function(){I||(Xe(Y("birthdate")),De((function(e){return ye(ye({},e),{},{first_name:Y("first_name"),last_name:Y("last_name"),email:Y("email")})})))}),[I]),(0,o.useEffect)((function(){var e=J.query.loan_status?J.query.loan_status:void 0,t=J.query.error?J.query.error:void 0;if(e&&J.isReady){var n=J.pathname,r=J.query;if("general_error"==e&&(0,C.Z)(u.ag._({id:"s+2r07"}
1),u.ag._({id:"yQBrlx"}),"error",{url:"/assets/images/credit-score-checking-error.png",width:"300px",height:"200px"},(function(){}),void 0,void 0),"canceled_consent"==e&&(0,C.Z)(u.ag._({id:"41OZN+"}),u.ag._({id:"8RxJoT"}),"error",{url:"/assets/images/credit-score-checking-error.png",width:"300px",height:"200px"},(function(){})),"tarya_error"===e&&("phone"===t?(Z.Z.error("Phone number is not valid"),te({phone_number:{message:u.ag._({id:"Ij8NHY"})}})):Z.Z.error(u.ag._({id:"OKXjnF",values:{errorDetail:t}}))),"true_vision_error"===e&&t){var i,o;if(null!==(i=J.query)&&void 0!==i&&i.message)Z.Z.error(null===(o=J.query)||void 0===o?void 0:o.message);if(t&&Array.isArray(t)){var s,a=be(t);try{for(a.s();!(s=a.n()).done;){var l=s.value;Qe(l)}}catch(l){a.e(l)}finally{a.f()}}else t&&Qe(t);delete J.query.message}delete J.query.loan_status,delete J.query.error,J.replace({pathname:n,query:r},void 0,{shallow:!0})}}),[J.isReady]);var Qe=function(e){var t=e.split(",");if(4==t.length){var n=t[0],r=t[1],i=t[2],o=t[3];"address"==n?W("addresses[".concat(r,"].").concat(i),{type:"manual",message:o}):"names"==n&&W(i,{type:"manual",message:o})}};return(0,N.jsxs)(h.Z,{stage:h.e.CHECK_ELIGIBILITY,uuid:Q,children:[(0,N.jsx)(k.Z,{open:ve,setOpen:je,bnplUuid:Q,bnplInviteNo:null===S||void 0===S?void 0:S.invite_number,type:"customer",marketplace:!0}),(0,N.jsxs)(g.Z,{component:"form",noValidate:!0,onSubmit:n(Ke),id:"check-eligibility-form",children:[(0,N.jsx)(v.Z,{component:"div",color:"black",sx:{typography:{md:"plim-H4R",xs:"plim-R-link-1"},mb:"24px"},className:"show-in-desktop",children:(0,N.jsx)(f.cC,{id:"Eus1Wo"})}),I?(0,N.jsx)(_.Z,{skeletonList:[[{type:"rectangular",height:150}],[{type:"rectangular",height:300}],[{type:"rectangular",height:200}],[{type:"rounded",width:"100%"}]]}):(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(E.Z,{type:"info",children:(0,N.jsx)(f.cC,{id:"6nGWHa"})}),(0,N.jsxs)(g.Z,{sx:{mt:"24px"},children:[(0,N.jsx)(le.Z,{images:(null===S||void 0===S?void 0:S.treatments_images)||[],treatmentName:(null===S||void 0===S?void 0:S.treatments_name)||"",invitationNumber:(null===S||void 0===S?void 0:S.invite_number)||"",expireDate:(null===S||void 0===S?void 0:S.expire_date)||"",status:(null===S||void 0===S?void 0:S.status)||0,approveStatus:null===S||void 0===S?void 0:S.approve_status}),(0,N.jsx)(R,{planInfo:S,bnplUuid:Q})]}),(0,N.jsx)(v.Z,{variant:"plim-H4R",sx:{mt:"64px"},color:"black",component:"h1",children:(0,N.jsx)(f.cC,{id:"sJYPeP"})}),(0,N.jsx)(v.Z,{variant:"plim-p1",sx:{mt:"5px"},color:"black_stroke",children:(0,N.jsx)(f.cC,{id:"uJC3LJ"})}),(0,N.jsxs)(ce.Z,{header:u.ag._({id:"Ni5Hpi"}),sx:{mt:"24px"},children:[(0,N.jsxs)(g.Z,{sx:{mb:"24px"},display:"flex",justifyContent:"space-between",alignItems:"center",children:[(0,N.jsxs)(v.Z,{variant:"plim-R-link-1",color:"black",component:"p",sx:{opacity:.8,wordBreak:"break-all"},children:[Re.first_name," ",Re.last_name," : ",Re.email]}),(0,N.jsx)(he.Z,{loading:ue,onClick:We,sx:{minWidth:"unset",textAlign:"center",textWrap:"nowrap","&:hover":{backgroundColor:"unset!important"}},children:(0,N.jsx)(v.Z,{variant:"plim-R-link-1",color:"main",children:(0,N.jsx)(f.cC,{id:"OzM2hR"})})})]}),(0,N.jsxs)(y.ZP,{container:!0,columnSpacing:"16px",rowSpacing:{md:"5px",sm:"20px",xs:0},children:[(0,N.jsx)(y.ZP,{lg:4,md:4,sm:6,xs:12,item:!0,children:(0,N.jsx)(b.Z,{name_text:"phone_number",name_select:"country_code",label:u.ag._({id:"M88jla"}),control:t,errors:x,serverError:ee,name:"phone",setValue:r,labelColor:"black",getValues:Y})}),(0,N.jsx)(y.ZP,{lg:3,md:4,sm:6,xs:12,item:!0,children:(0,N.jsx)(D.Z,{format:"DD/MM/YYYY",placeholder:"DD/MM/YYYY",name:"birthdate",control:t,label:u.ag._({id:"7uHWR+"}),errors:x,serverError:ee,sx:{mb:2},rules:ye(ye({},O.jN),O.RL),onBlur:function(e){Ee&&Xe(d()(e.target.value,"DD/MM/YYYY"))},onError:function(e,t){Xe(t)},labelColor:"black"})}),(0,N.jsx)(y.ZP,{lg:2.5,md:2,sm:6,xs:12,item:!0,children:(0,N.jsx)(w.Z,{values:X,title:"title",name:"title",control:t,label:u.ag._({id:"MHrjPM"}),errors:x,serverError:ee,disableClearable:!0,rules:O.jN,labelColor:"black"})}),(0,N.jsx)(y.ZP,{lg:2.5,md:2,sm:6,xs:12,item:!0,children:(0,N.jsx)(w.Z,{values:H,title:"title",name:"gender",control:t,label:u.ag._({i
1d:"5iyJje"}),errors:x,serverError:ee,disableClearable:!0,rules:O.jN,labelColor:"black"})}),_e(z)&&(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(y.ZP,{item:!0,md:4,sm:4,xs:12,children:(0,N.jsx)(T.Fb,{})}),(0,N.jsx)(y.ZP,{item:!0,md:8,sm:8,xs:12,sx:{mt:{xs:"42px",sm:0}},children:(0,N.jsx)(B.Z,{name:"have_address_history",control:t,label:"",options:[{uuid:"1",title:u.ag._({id:"S8n5XH"})},{uuid:"2",title:u.ag._({id:"b3ZSfv"})}],sxRadioOption:{typography:"plim-p3",color:K().G_800},errors:x,serverError:ee,flexDirection:"row",justifyContent:Je?"space-between":"flex-start",rules:O.jN,sx:{px:{xs:"33px",sm:0},"& .MuiButtonBase-root":{padding:"4px"}},filledIcon:!0})})]})]})]}),!0===M&&_e(z)&&Ee&&(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(F,{setValue:r,getValues:Y,watch:c,errors:x,resetField:V,control:t,serverError:ee}),(0,N.jsx)(T.Qc,{control:t,errors:x,serverError:ee,employmentType:Be,watch:c,setValue:r,getValues:Y,setServerError:te})]}),z==pe.TARYA?(0,N.jsxs)(se,{control:t,watch:c,errors:x,bankError:Oe,consentForm:Ze,setBankError:Se,setting:P,children:[(0,N.jsx)(T.nI,{name:"soft_credit_check_acknowledged",control:t,errors:x,className:"main-icon-svg",label:(0,N.jsx)(f.cC,{id:"E1rsTf"}),rules:{validate:function(e){return e||u.ag._({id:"UwqoLj"})}},sx:{mt:"24px"}}),(0,N.jsx)(g.Z,{sx:{mt:"52px",mb:{md:"48px",sm:"48px",xs:0}},children:(0,N.jsxs)(y.ZP,{container:!0,justifyContent:"flex-end",flexDirection:{md:"row",sm:"row",xs:"column-reverse"},spacing:{md:"30px",sm:"20px",xs:"20px"},children:[(0,N.jsx)(y.ZP,{item:!0,lg:3,xl:1.75,md:3,sm:6,xs:12,children:(0,N.jsx)(j.Z,{sx:{width:"100%",whiteSpace:"nowrap"},variant:"marketplace-gray",onClick:We,loading:ue,children:(0,N.jsx)(f.cC,{id:"E+WSHC"})})}),(0,N.jsx)(y.ZP,{item:!0,lg:3,xl:1.5,md:3,sm:6,xs:12,children:(0,N.jsx)(j.Z,{sx:{width:"100%"},onClick:Ge,loading:ie,variant:"marketplace-black",children:(0,N.jsx)(f.cC,{id:"xGVfLh"})})})]})})]}):(0,N.jsx)(N.Fragment,{}),_e(z)&&(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(ge.Z,{open:Ye,setOpen:Ve,onSubmit:n(Ke),steps:Fe}),(0,N.jsx)(T.nI,{name:"soft_credit_check_acknowledged",control:t,errors:x,className:"main-icon-svg",label:(0,N.jsx)(f.cC,{id:"E1rsTf"}),rules:{validate:function(e){return e||u.ag._({id:"UwqoLj"})}},sx:{mt:"24px"}}),(0,N.jsx)(g.Z,{sx:{mt:"52px",mb:{md:"48px",sm:"48px",xs:0}},children:(0,N.jsxs)(y.ZP,{container:!0,justifyContent:"flex-end",flexDirection:{md:"row",sm:"row",xs:"column-reverse"},gap:{md:"30px",sm:"20px",xs:"20px"},children:[(0,N.jsx)(j.Z,{sx:{width:{xs:"100%",sm:"fit-content"},whiteSpace:"nowrap"},variant:"marketplace-gray",onClick:We,loading:ue,children:(0,N.jsx)(f.cC,{id:"E+WSHC"})}),(0,N.jsx)(j.Z,{sx:{minWidth:"165px"},variant:"marketplace-black",onClick:Ge,loading:ie,disabled:!Ee,children:(0,N.jsx)(f.cC,{id:"xGVfLh"})})]})})]})]})]})]})},Ze=n(41314),Ce=n(86559);function ke(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Oe(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ke(Object(n),!0).forEach((function(t){(0,i.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ke(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Se=function(){var e=(0,a.ZP)(),t=e.query.uuid?e.query.uuid:void 0,n=(0,o.useState)(),i=n[0],c=n[1],p=(0,o.useState)(),x=p[0],m=p[1],f=(0,o.useState)(!0),h=f[0],g=f[1],v=(0,o.useState)(null),y=v[0],b=v[1],j=(0,o.useState)(),_=j[0],w=j[1],Z=(0,T.qe)().map((function(e){return Oe(Oe({},e),{},{title:u.ag._(e.title)})}));(0,o.useEffect)((function(){t&&C()}),[e.isReady,null===e||void 0===e?void 0:e.locale]);var C=function(){l.ZP.get("/api/customer/".concat(t,"/info/")).then((function(t){if(null!==t&&void 0!==t&&t.data){var n,r,i,o;if(null!==t&&void 0!==t&&null!==(n=t.data)&&void 0!==n&&n.bnpl_last_redirect_url&&(null===t||void 0===t||null===(r=t.data)||void 0===r||!r.bnpl_last_redirect_url.includes(e.asPath.split("?")[0])))return e.customPush(null===t||void 0===t||null===(o=t.data)||void 0===o?void 0:o.bnpl_last_redirect_url);c(t.data.bnplloan_data),m(t.data.setting),M(t.data.personal_data),w(null===(i=t.data)||void 0===i?void 0:i.credit_check_system),g(!1)}}))}
1,k=(0,s.cI)(),S=k.control,P=k.handleSubmit,E=k.setValue,I=k.getValues,R=k.watch,D=k.resetField,A=k.setError,B=k.clearErrors,L=k.trigger,Y=k.formState.errors,V=[{title:u.ag._({id:"CvCWBI"}),id:1},{title:u.ag._({id:"M9iqFS"}),id:2},{title:u.ag._({id:"pxzhEt"}),id:3}],M=function(e){for(var t=function(){var e=(0,r.Z)(i[n],2),t=e[0],o=e[1],s=(0,O.C)(o);if(s&&"open_bank"==t)1==o.active&&E(t,o||"");else if(s&&"gender"==t)1!=o&&2!=o&&3!=o||E(t,V[o-1]);else if(s&&"employment_type"==t)1!=o&&2!=o&&3!=o&&4!=o||E(t,Ce.F[o-1]);else if(s&&"title"==t){if([1,2,3,4,5,6].includes(o)){var a=Z.find((function(e){return e.id===o}));a&&E(t,a)}}else s&&"birthdate"==t?E(t,d()(o,"DD/MM/YYYY")):null!=s&&"have_address_history"==t?!0===o?E(t,"1"):!1===o&&E(t,"2"):s&&E(t,o||"")},n=0,i=Object.entries(e);n<i.length;n++)t()};return(0,N.jsx)(Ze.Z,{children:(0,N.jsx)(we,{creditCheckSystem:_,trigger:L,genderList:V,titleList:Z,watch:R,control:S,handleSubmit:P,fetchLoading:h,setValue:E,errors:Y,planInfo:i,setting:x,getValues:I,resetField:D,nonOpenBanking:y,setNonOpenBanking:b,setError:A,clearErrors:B})})}},17880:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/customer/dashboard/bnpl/check-eligibility/[uuid]",function(){return n(43548)}])},42708:function(e,t,n){"use strict";n.d(t,{YD:function(){return d}});var r=n(67294),i=new Map,o=new WeakMap,s=0,a=void 0;function l(e){return Object.keys(e).sort().filter((t=>void 0!==e[t])).map((t=>{return`${t}_${"root"===t?(n=e.root,n?(o.has(n)||(s+=1,o.set(n,s.toString())),o.get(n)):"0"):e[t]}`;var n})).toString()}function c(e,t,n={},r=a){if("undefined"===typeof window.IntersectionObserver&&void 0!==r){const i=e.getBoundingClientRect();return t(r,{isIntersecting:r,target:e,intersectionRatio:"number"===typeof n.threshold?n.threshold:0,time:0,boundingClientRect:i,intersectionRect:i,rootBounds:i}),()=>{}}const{id:o,observer:s,elements:c}=function(e){let t=l(e),n=i.get(t);if(!n){const r=new Map;let o;const s=new IntersectionObserver((t=>{t.forEach((t=>{const n=t.isIntersecting&&o.some((e=>t.intersectionRatio>=e));e.trackVisibility&&"undefined"===typeof t.isVisible&&(t.isVisible=n),r.get(t.target)?.forEach((e=>{e(n,t)}))}))}),e);o=s.thresholds||(Array.isArray(e.threshold)?e.threshold:[e.threshold||0]),n={id:t,observer:s,elements:r},i.set(t,n)}return n}(n);let d=c.get(e)||[];return c.has(e)||c.set(e,d),d.push(t),s.observe(e),function(){d.splice(d.indexOf(t),1),0===d.length&&(c.delete(e),s.unobserve(e)),0===c.size&&(s.disconnect(),i.delete(o))}}r.Component;function d({threshold:e,delay:t,trackVisibility:n,rootMargin:i,root:o,triggerOnce:s,skip:a,initialInView:l,fallbackInView:d,onChange:u}={}){const[p,x]=r.useState(null),m=r.useRef(),[f,h]=r.useState({inView:!!l,entry:void 0});m.current=u,r.useEffect((()=>{if(a||!p)return;let r;return r=c(p,((e,t)=>{h({inView:e,entry:t}),m.current&&m.current(e,t),t.isIntersecting&&s&&r&&(r(),r=void 0)}),{root:o,rootMargin:i,threshold:e,trackVisibility:n,delay:t},d),()=>{r&&r()}}),[Array.isArray(e)?e.toString():e,p,o,i,s,a,n,d,t]);const g=f.entry?.target,v=r.useRef();p||!g||s||a||v.current===g||(v.current=g,h({inView:!!l,entry:void 0}));const y=[x,f.inView,f.entry];return y.ref=y[0],y.inView=y[1],y.entry=y[2],y}}},function(e){e.O(0,[7337,8426,9774,2888,179],(function(){return t=17880,e(e.s=t);var t}));var t=e.O();_N_E=t}]);

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.