1"use strict";(self.webpackChunkweb_front_end_angular_cli=self.webpackChunkweb_front_end_angular_cli||[]).push([[484],{60484:(S,m,o)=>{o.r(m),o.d(m,{ConfirmDataComponent:()=>L});var a=o(85240),n=o(12481),l=o(93683),C=o(52971),x=o(52575),d=o(89475),M=o(85663),b=o(98509),v=o(97887),f=o(79864),_=o(48503),E=o(25004),i=o(34456),O=o(26368),P=o(19838),g=o(97024),D=o(1522),I=o(49074),R=o(26751),T=o(60247),u=o(90031),k=o(11753),j=o(78013),p=o(46679),y=o(86521);function B(s,c){if(1&s){const r=n.RV6();n.j41(0,"div",19),n.nI1(1,"safeHtml"),n.bIt("click",function(){a.eBV(r);const e=n.XpG(2);return a.Njj(e.removeError())}),n.k0s()}if(2&s){const r=n.XpG(2);n.Y8G("innerHtml",n.bMT(1,1,r.error.message),n.npT)}}function F(s,c){if(1&s){const r=n.RV6();n.j41(0,"section",2),n.nrm(1,"app-product-info",3),n.j41(2,"div",4)(3,"div")(4,"button",5),n.bIt("click",function(){a.eBV(r);const e=n.XpG();return a.Njj(e.showPopUp())}),n.EFF(5),n.nI1(6,"translate"),n.k0s()(),n.j41(7,"div",6,0),n.DNE(9,B,2,3,"div",7),n.nI1(10,"async"),n.k0s(),n.j41(11,"div",8)(12,"div",9),n.EFF(13),n.nI1(14,"translate"),n.k0s(),n.j41(15,"div",10),n.EFF(16),n.k0s(),n.j41(17,"div",9),n.EFF(18),n.nI1(19,"translate"),n.k0s(),n.j41(20,"div",10),n.EFF(21),n.k0s(),n.j41(22,"div",9),n.EFF(23),n.nI1(24,"translate"),n.k0s(),n.j41(25,"div",10),n.EFF(26),n.k0s(),n.j41(27,"div",9),n.EFF(28),n.nI1(29,"translate"),n.k0s(),n.j41(30,"div",10),n.EFF(31),n.nI1(32,"date"),n.nI1(33,"date"),n.k0s()(),n.j41(34,"form",11),n.bIt("ngSubmit",function(){a.eBV(r);const e=n.XpG();return a.Njj(e.submit())}),n.j41(35,"mat-form-field",12)(36,"mat-label"),n.EFF(37),n.nI1(38,"translate"),n.k0s(),n.j41(39,"input",13),n.bIt("blur",function(){a.eBV(r);const e=n.XpG();return a.Njj(e.clearEmptyFieldError(null==e.form?null:e.form.get("email")))}),n.k0s(),n.j41(40,"mat-error"),n.nrm(41,"app-control-validation-messages",14),n.k0s()(),n.j41(42,"mat-checkbox",15)(43,"div",16),n.EFF(44),n.nI1(45,"translate"),n.j41(46,"a",17),n.nI1(47,"translate"),n.nI1(48,"safeUrl"),n.EFF(49),n.nI1(50,"translate"),n.k0s(),n.EFF(51,". "),n.k0s()(),n.j41(52,"button",18),n.EFF(53),n.nI1(54,"translate"),n.k0s()()()()}if(2&s){let r;const t=c.ngLet,e=n.XpG();n.R7$(),n.Y8G("contextInfo",t),n.R7$(4),n.JRh(n.bMT(6,25,"shared.buttons.back")),n.R7$(4),n.Y8G("ngIf",!1===n.bMT(10,27,null==e.error?null:e.error.$isNoErrors)),n.R7$(4),n.JRh(n.bMT(14,29,"oscpv.confirm-data.customer-title")),n.R7$(3),n.E5c("",null==t||null==t.customer?null:t.customer.lastName," ",null==t||null==t.customer?null:t.customer.firstName," ",null==t||null==t.customer?null:t.customer.middleName),n.R7$(2),n.JRh(n.bMT(19,31,"oscpv.confirm-data.insurance-object-number")),n.R7$(3),n.JRh(null==t||null==t.insuranceObject?null:t.insuranceObject.registrationNumber),n.R7$(2),n.JRh(n.bMT(24,33,"oscpv.confirm-data.brand-model")),n.R7$(3),n.Lme("",null==t||null==t.insuranceObject?null:t.insuranceObject.brand,", ",null==t||null==t.insuranceObject?null:t.insuranceObject.model),n.R7$(2),n.JRh(n.bMT(29,35,"oscpv.confirm-data.period")),n.R7$(3),n.Lme(" ",n.i5U(32,37,null==t||null==t.insuranceContract?null:t.insuranceContract.dateFrom,"dd.MM.yyyy")," \u2014 ",n.i5U(33,40,null==t||null==t.insuranceContract?null:t.insuranceContract.dateTo,"dd.MM.yyyy")," "),n.R7$(3),n.Y8G("formGroup",e.form),n.R7$(3),n.JRh(n.bMT(38,43,"oscpv.confirm-data.email-label")),n.R7$(4),n.Y8G("mainForm",e.form)("fieldName","email")("formErrors",e.formErrors),n.R7$(3),n.SpI(" ",n.bMT(45,45,"oscpv.confirm-data.confirm-label")," "),n.R7$(2),n.Y8G("href",n.bMT(48,49,n.bMT(47,47,"oscpv.confirm-data.confirm-link")),n.B4B),n.R7$(3),n.JRh(n.bMT(50,51,"oscpv.confirm-data.confirm-link-text")),n.R7$(3),n.Y8G("disabled",!(null!=e.form&&e.form.valid&&null!=e.form&&null!=(r=e.form.get("confirm"))&&r.value)),n.R7$(),n.JRh(n.bMT(54,53,"oscpv.shared.next"))}}const h="confirm";let L=(()=>{var s;class c extends O.I{constructor(t,e,w){super(t),this.platformId=t,this.fb=e,this.translateService=w,this.insuranceService=(0,a.WQX)(C.m),this.destroyRef=(0,a.WQX)(a.abz),this.loaderService=(0,a.WQX)(R.Z),this.router=(0,a.WQX)(b.Ix),this.insuranceDialogService=(0,a.WQX)(k.u),this.contextInfo$=this.insuranceService.contextInfo$}ngOnInit(){this.initForm(),this.initFormErrors(),this.getBaseValidationMessages(),this.initFormSubscription()}initForm(){this.form=this.fb.group({email:[this.insuranceService.getStepData(h),i.k0.compose([i.k0.required,i.k0.pattern(P.D5.EMAIL_VALIDATION_PATTERN)])],confirm:[!1,i.k0.required]})}initFormErrors(){this.formErrors.email=new D.b}getBaseValidationMessages(){this.translateService.get("validate-messages.required").subscribe(t=>{this.setBaseValidationMessages(t,"required")}),this.translateService.get("validate-messages.pattern").subscribe(t=>{this.setBaseValidationMessages(t,"pattern")})}initFormSubscription(){this.form.valueChanges.pipe((0,I.pQ)(this.destroyRef),(0,x.B)(300)).subscribe({next:()=>{this.updateStepData(),this.onValueChanged(this.form)}})}submit(){const t=this.form.value.email;this.loaderService.startManual(),this.insuranceService.contract(t).pipe((0,d.j)(()=>this.loaderService.finishManual())).subscribe({next:e=>this.handleContractResponse(e?.insuranceContract),error:e=>{if(this.setError(e),"CONTRACT_ALREADY_CREATED"===e?.error?.errorCode){if("confirmed"===this.insuranceService.contextInfoSource?.insuranceContract?.state)return void this.router.navigate(["/car-insurance/pay"]);if(this.insuranceService.contextInfoSource?.isInsuranceContractCreated&&["waitconfirm","needconfirm"].includes(this.insuranceService.contextInfoSource?.insuranceContract?.state?.toLowerCase()))return void this.router.navigate(["/car-insurance/accept"])}}})}handleContractResponse(t){switch(t?.state?.toLowerCase()){case u.s?.WaitConfirm?.toLowerCase():this.router.navigate(["/car-insurance/accept"]);break;case u.s.NeedConfirm?.toLowerCase():this.initializeContract()}}initializeContract(){this.loaderService.startManual(),this.updateStepData(),this.insuranceService.initialize().pipe((0,d.j)(()=>this.loaderService.finishManual())).subscribe({next:t=>{t?.insuranceContract?.state?.toLowerCase()===u.s?.WaitConfirm?.toLowerCase()&&this.router.navigate(["/car-insurance/accept"])},error:t=>this.setError(t)})}updateStepData(){this.insuranceService.updateStepData(h,this.form?.value?.email)}showPopUp(){this.insuranceDialogService.showDocumentReady()}}return(s=c).\u0275fac=function(t){return new(t||s)(n.rXU(n.Agw),n.rXU(i.ze),n.rXU(_.c$))},s.\u0275cmp=n.VBU({type:s,selectors:[["app-confirm-data"]],features:[n.Vt3],decls:2,vars:3,consts:[["errorBlock",""],["class","confirm-data page-with-product",4,"ngLet"],[1,"confirm-data","page-with-product"],[1,"selected-product-info",3,"contextInfo"],[1,"inner-info-container"],["type","button",1,"insurance-back","show-ins-dialog",3,"click"],[1,"scroll-offset"],["class","insurance-error",3,"innerHtml","click",4,"ngIf"],[1,"confirm-data__info"],[1,"confirm-data__info-label"],[1,"confirm-data__info-value","regular"],[1,"confirm-data__form",3,"ngSubmit","formGroup"],["appearance","outline",1,"confirm-data__email"],["matInput","","type","email","autocomplete","email","formControlName","email","placeholder","[email protected]",3,"blur"],[3,"mainForm","fieldName","formErrors"],["color","primary","formControlName","confirm",1,"insurance-checkbox","ep-checkbox","absolute-checkbox"],[1,"insurance-checkbox__label"],["target","_blank",3,"href"],[1,"button","light-blue","button--wide-405","mt-24",3,"disabled"],[1,"insurance-error",3,"click","innerHtml"]],template:function(t,e){1&t&&(n.DNE(0,F,55,55,"section",1),n.nI1(1,"async")),2&t&&n.Y8G("ngLet",n.bMT(1,1,e.contextInfo$))},dependencies:[l.MD,l.bT,M.n,v.N,f.fS,f.fg,p.j,p.M,p.b,_.h,E.d,y.g,i.X1,i.qT,i.me,i.BC,i.cb,i.j4,i.JD,g.g7,g.So,l.Jj,l.vh,_.D9,T.$,j.d],styles:['.insurance-error[_ngcontent-%COMP%]{border-radius:5px;background-color:#fff8d080;padding:12px 12px 12px 38px;background-image:url(https://cdn.easypay.ua/images/svg/oscpv/attention-orange.svg);background-repeat:no-repeat;background-size:14px;background-position:12px 12px;margin-top:16px;margin-bottom:24px}.mt-24[_ngcontent-%COMP%]{margin-top:24px}.mt-8[_ngcontent-%COMP%]{margin-top:8px}.button--wide-405[_ngcontent-%COMP%]{height:44px;line-height:44px;box-shadow:0 8px 20px #1f83fe4d;max-width:405px}.control-wide-405[_ngcontent-%COMP%]{max-width:405px}.insurance-checkbox.mat-mdc-checkbox.mat-primary[_ngcontent-%COMP%]{--mdc-checkbox-unselected-icon-color: #CCCCCC;--mdc-checkbox-unselected-hover-icon-color: #CCCCCC}.insurance-checkbox__label[_ngcontent-%COMP%]{font-size:12px;line-height:16px;font-weight:400;color:#202020}.insurance-back[_ngcontent-%COMP%]{display:inline-block;background-image:url(https://cdn.easypay.ua/images/svg/arrows/arrow-brand-blue.svg);background-repeat:no-repeat;background-size:17px 16px;background-position:4px center;padding:4px 0 4px 28px;font-size:16px;line-height:16px;font-weight:400}.insurance-back.show-ins-dialog[_ngcontent-%COMP%]{color:#1f83fe;cursor:pointer}.insurance-back.show-ins-dialog[_ngcontent-%COMP%]:focus, .insurance-back.show-ins-dialog[_ngcontent-%COMP%]:hover{color:#055b9d}.ins__tooltip[_ngcontent-%COMP%]{display:inline-block;width:14px;
1height:14px;position:relative;top:2px;transition:.15s}.ins__tooltip[_ngcontent-%COMP%]:before{content:"";position:absolute;width:40px;height:40px;left:-13px;top:-13px;background-image:url(https://cdn.easypay.ua/images/svg/info-new.svg);background-repeat:no-repeat;background-size:14px;background-position:center;transition:.15s}.insurance-toggle[_ngcontent-%COMP%]{align-self:flex-end;position:relative;margin:12px 0 0 auto;color:#1f83fe;font-size:16px;cursor:pointer}@media only screen and (min-width: 640px){.insurance-toggle[_ngcontent-%COMP%]{margin-top:24px}}.insurance-toggle[_ngcontent-%COMP%]:before{position:absolute;content:"";top:-8px;bottom:-8px;left:-8px;right:-8px}.insurance-toggle[_ngcontent-%COMP%]:after{content:url(\'data:image/svg+xml;utf8,<svg width="13" height="8" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="none"><path d="M12.54.55c.25.25.25.65 0 .9l-5.9 5.91-5.92-5.9a.64.64 0 0 1 .91-.91l5 5 5-5a.64.64 0 0 1 .91 0Z" fill="dodgerBlue"/></svg>\');display:inline-block;transition:transform .5s;margin-left:10px}@media only screen and (max-width: 639.8px){.insurance-toggle.extended[_ngcontent-%COMP%]{position:absolute;bottom:16px;right:16px;z-index:1}}.insurance-toggle.extended[_ngcontent-%COMP%]:after{transform:rotateX(180deg)}.insurance-toggle[_ngcontent-%COMP%]:focus-visible{box-shadow:#fff 0 0 0 4px,#dff1ff 0 0 2px 6px}.page-with-product[_ngcontent-%COMP%]{display:flex;flex-direction:column}@media only screen and (min-width: 1024px){.page-with-product[_ngcontent-%COMP%]{flex-direction:row;column-gap:24px}}.page-with-product[_ngcontent-%COMP%] .inner-info-container[_ngcontent-%COMP%]{padding:16px 12px;background-color:#fff;margin-top:8px;border-radius:5px}@media only screen and (min-width: 640px){.page-with-product[_ngcontent-%COMP%] .inner-info-container[_ngcontent-%COMP%]{margin-top:12px}}@media only screen and (min-width: 1024px){.page-with-product[_ngcontent-%COMP%] .inner-info-container[_ngcontent-%COMP%]{flex:1 1 auto;margin-top:0}}@media only screen and (min-width: 1024px){.page-with-product[_ngcontent-%COMP%] .selected-product-info[_ngcontent-%COMP%]{order:1;flex:0 0 320px}}.flag-ua[_ngcontent-%COMP%]{position:relative;height:10px;width:16px;margin-bottom:7px}.flag-ua[_ngcontent-%COMP%]:before, .flag-ua[_ngcontent-%COMP%]:after{content:"";position:absolute;left:0;height:5px;width:16px}.flag-ua[_ngcontent-%COMP%]:before{background-color:#007ef6;top:0}.flag-ua[_ngcontent-%COMP%]:after{background-color:#f8d347;top:5px}.customer-info__flag[_ngcontent-%COMP%]{position:absolute;left:0;top:5px;margin-bottom:0}.confirm-data__info[_ngcontent-%COMP%]{padding:12px;background-color:#e5f1ff;display:grid;grid-auto-rows:auto;grid-template-columns:max-content auto;gap:16px 28px;border-radius:8px;margin-top:24px;margin-bottom:33px}.confirm-data__info-label[_ngcontent-%COMP%], .confirm-data__info-value[_ngcontent-%COMP%]{font-size:16px;line-height:1.3}.confirm-data__info-value[_ngcontent-%COMP%]{color:#202020}.confirm-data__email[_ngcontent-%COMP%]{max-width:405px}'],changeDetection:0}),c})()}}]); 2//# sourceMappingURL=484.01999ac8ffa1c1be.js.map
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.