1import{d as Xt}from"./chunk-NG5EQK6W.js";import{b as Be,d as vt,e as Ce,f as Ne}from"./chunk-5W4PR66R.js";import{$a as ue,A as oe,B as Ut,Db as Kt,E as xe,Eb as Jt,F as $,G as M,Ga as Yt,Ha as J,Ia as vi,J as Ot,Ja as Pe,K as Ge,L as Ze,Ma as Qt,O as Gt,P as jt,Pa as zt,Q as ut,Qa as me,Sa as _i,Va as xi,_a as se,a as mt,b as Q,c as F,da as hi,db as ke,e as z,eb as et,f as K,fb as L,gb as W,h as Oe,i as ui,k as j,kb as je,kc as N,l as gi,lc as ht,m as ie,mb as tt,o as fi,qa as Ht,r as qt,s as Lt,sa as gt,t as ne,u as re,va as Wt,vd as Ci,wa as ft,xa as Ie}from"./chunk-I75ST7ZI.js";import{$ as St,$b as Ke,$f as Rt,Aa as w,Ac as s,Bc as Nt,Bh as O,Cg as Le,Ch as de,Eb as l,Ec as Te,Fb as d,Ga as Et,Gb as a,Hb as p,I as fe,Ib as Pt,Ig as Ue,Jb as kt,Jg as dt,Lb as D,Mb as R,Nb as li,Ob as P,Pa as It,Qf as Je,Rc as Vt,Rf as $e,Sf as mi,Tb as b,U as De,Ub as Bt,Vb as u,Vf as Fe,Wf as Dt,Yf as pe,Zb as ot,_a as r,_b as ze,a as We,ad as ci,ba as Tt,cd as Ae,ci as $t,d as yt,dc as be,dd as G,e as X,ea as At,fc as di,ha as Qe,hb as E,hd as pi,ib as ai,ic as m,id as H,ie as st,jc as I,ka as he,kb as U,kc as f,ke as ce,ki as Xe,lb as ee,lc as Re,ma as Ft,mh as ct,nc as ye,ng as q,o as wt,oc as we,og as qe,pb as v,pc as Se,qa as ve,qc as x,qd as le,qg as Ee,ra as Z,rg as lt,sa as rt,sh as pt,ta as B,tc as Y,te,th as _e,ua as S,uc as C,ue as at,v as ge,vg as V,w as Ye,wg as k,xb as A,za as y,zc as o,ze as Mt}from"./chunk-ZV6XJHCK.js";import{a as oi,b as si}from"./chunk-NAIKXHWT.js";function Gi(t,h){t&1&&(d(0,"div")(1,"div",10),p(2,"cx-spinner"),a()())}function ji(t,h){if(t&1){let e=P();d(0,"div",11)(1,"p",12),m(2),o(3,"cxTranslate"),a()(),d(4,"div",13)(5,"button",14),b("click",function(){y(e);let i=u(2);return w(i.closeAccount())}),m(6),o(7,"cxTranslate"),a(),d(8,"button",15),b("click",function(){y(e);let i=u(2);return w(i.dismissModal("Cancel"))}),m(9),o(10,"cxTranslate"),a()()}t&2&&(r(2),f(" ",s(3,3,"closeAccount.confirmAccountClosureMessage")," "),r(4),f(" ",s(7,5,"closeAccount.closeMyAccount")," "),r(3),f(" ",s(10,7,"common.cancel")," "))}function Hi(t,h){if(t&1){let e=P();D(0),d(1,"div",2),b("esc",function(){y(e);let i=u();return w(i.dismissModal("Escape click"))}),d(2,"div",3)(3,"div",4)(4,"h3",5),m(5),o(6,"cxTranslate"),a(),d(7,"button",6),o(8,"cxTranslate"),o(9,"cxTranslate"),b("click",function(){y(e);let i=u();return w(i.dismissModal("Cross click"))}),d(10,"span",7),p(11,"cx-icon",8),a()()(),v(12,Gi,3,0,"div",9),o(13,"async"),v(14,ji,11,9,"ng-template",null,0,Te),a()(),R()}if(t&2){let e=be(15),n=u();r(),l("cxFocus",n.focusConfig),r(4),f(" ",s(6,8,"closeAccount.confirmAccountClosure")," "),r(2),l("title",x(s(8,10,"common.close"))),A("aria-label",s(9,12,"common.close")),r(4),l("type",n.iconTypes.CLOSE),r(),l("ngIf",s(13,14,n.isLoading$))("ngIfElse",e)}}var Wi=["element"],T=t=>({label:t});function Yi(t,h){t&1&&p(0,"cx-spinner",7)}var ki=()=>[],ii=()=>({}),Bi=()=>({cxRoute:"termsAndConditions"}),Ni=()=>({cxRoute:"login"});function Qi(t,h){if(t&1&&(d(0,"label"),p(1,"input",33),d(2,"span",25),m(3),a()()),t&2){let e=u().ngIf,n=u(2);r(),l("checked",n.isConsentGiven(e.consent)),r(2),f(" ",e.template," ")}}function zi(t,h){if(t&1&&(D(0),v(1,Qi,4,2,"label",22),R()),t&2){let e=h.ngIf;r(),l("ngIf",e.template)}}function Ki(t,h){t&1&&(D(0),p(1,"cx-form-required-asterisks"),R())}function Ji(t,h){if(t&1){let e=P();d(0,"div")(1,"label")(2,"input",37),b("change",function(i){y(e);let c=u().index,g=u(3);return w(g.updateAdditionalConsents(i,c))}),a(),d(3,"span",25),m(4),v(5,Ki,2,0,"ng-container",22),a(),p(6,"cx-form-errors",30),a()()}if(t&2){let e=h.ngIf,n=u(),i=n.$implicit,c=n.index,g=u().ngIf;r(2),l("required",g[c].required)("name",e),r(2),f(" ",g[c].template.description," "),r(),l("ngIf",g[c].required),r(),l("control",i.get("isConsentGranted"))}}function Xi(t,h){if(t&1&&(d(0,"div",36),v(1,Ji,7,5,"div",22),a()),t&2){let e=h.index,n=u().ngIf;l("formGroupName",e),r(),l("ngIf",n[e]==null||n[e].template==null?null:n[e].template.id)}}function Zi(t,h){if(t&1&&(d(0,"div",34),v(1,Xi,2,2,"div",35),a()),t&2){let e=u(2);r(),l("ngForOf",e.additionalConsents.controls)}}function en(t,h){if(t&1){let e=P();d(0,"section",2)(1,"div",3)(2,"div",4)(3,"div",5),p(4,"cx-form-required-legend"),d(5,"form",6),b("ngSubmit",function(){y(e);let i=u();
1return w(i.submitForm())}),d(6,"div",7)(7,"label")(8,"span",8),m(9),o(10,"cxTranslate"),a(),p(11,"ng-select",9),o(12,"cxTranslate"),o(13,"async"),o(14,"cxTranslate"),a()(),d(15,"div",7)(16,"label")(17,"span",8),m(18),o(19,"cxTranslate"),p(20,"cx-form-required-asterisks"),a(),p(21,"input",10),o(22,"cxTranslate"),p(23,"cx-form-errors",11),o(24,"cxTranslate"),a()(),d(25,"div",7)(26,"label")(27,"span",8),m(28),o(29,"cxTranslate"),p(30,"cx-form-required-asterisks"),a(),p(31,"input",12),o(32,"cxTranslate"),p(33,"cx-form-errors",13),o(34,"cxTranslate"),a()(),d(35,"div",7)(36,"label")(37,"span",8),m(38),o(39,"cxTranslate"),p(40,"cx-form-required-asterisks"),a(),p(41,"input",14),o(42,"cxTranslate"),p(43,"cx-form-errors",15),o(44,"cxTranslate"),a()(),d(45,"div",7)(46,"label")(47,"span",8),m(48),o(49,"cxTranslate"),p(50,"cx-form-required-asterisks"),a(),p(51,"input",16),o(52,"cxTranslate"),o(53,"cxTranslate"),d(54,"p",17),m(55),o(56,"cxTranslate"),a(),p(57,"cx-form-errors",18),o(58,"cxTranslate"),a()(),d(59,"div",7)(60,"label")(61,"span",8),m(62),o(63,"cxTranslate"),p(64,"cx-form-required-asterisks"),a(),p(65,"input",19),o(66,"cxTranslate"),o(67,"cxTranslate"),p(68,"cx-form-errors",20),o(69,"cxTranslate"),a()(),d(70,"div",7)(71,"div",21),v(72,zi,2,1,"ng-container",22),o(73,"async"),a()(),v(74,Zi,2,1,"div",23),d(75,"div",7)(76,"div",21)(77,"label"),p(78,"input",24),d(79,"span",25)(80,"span",26),m(81),o(82,"cxTranslate"),a(),d(83,"a",27),o(84,"cxUrl"),m(85),o(86,"cxTranslate"),a(),p(87,"cx-form-required-asterisks"),a(),p(88,"cx-form-errors",28),o(89,"cxTranslate"),a()()(),d(90,"cx-captcha",29),b("confirmed",function(){y(e);let i=u();return w(i.captchaConfirmed())}),a(),p(91,"cx-form-errors",30),d(92,"button",31),m(93),o(94,"cxTranslate"),a(),d(95,"a",32),o(96,"cxUrl"),m(97),o(98,"cxTranslate"),a()()()()()()}if(t&2){let e,n,i,c,g,_=u();r(5),l("formGroup",_.registerForm),r(4),I(s(10,58,"register.titleOptional")),r(2),l("ariaLabelDropdown",x(s(12,60,"common.ngSelectDropdownOptionsList")))("clearable",!1)("items",s(13,62,_.titles$)??Y(118,ki))("placeholder",s(14,64,"register.selectTitle"))("searchable",!1)("cxNgSelectA11y",Y(119,ii)),r(7),f("",s(19,66,"register.firstName.label")," "),r(3),l("placeholder",x(s(22,68,"register.firstName.placeholder"))),A("aria-invalid",((e=_.registerForm.get("firstName"))==null?null:e.touched)&&((e=_.registerForm.get("firstName"))==null?null:e.invalid))("aria-errormessage","firstNameError"),r(2),l("translationParams",C(120,T,s(24,70,"register.firstName.label")))("control",_.registerForm.get("firstName")),r(5),f("",s(29,72,"register.lastName.label")," "),r(3),l("placeholder",x(s(32,74,"register.lastName.placeholder"))),A("aria-invalid",((n=_.registerForm.get("lastName"))==null?null:n.touched)&&((n=_.registerForm.get("lastName"))==null?null:n.invalid))("aria-errormessage","lastNameError"),r(2),l("translationParams",C(122,T,s(34,76,"register.lastName.label")))("control",_.registerForm.get("lastName")),r(5),f("",s(39,78,"register.emailAddress.label")," "),r(3),l("placeholder",x(s(42,80,"register.emailAddress.placeholder"))),A("aria-invalid",((i=_.registerForm.get("email"))==null?null:i.touched)&&((i=_.registerForm.get("email"))==null?null:i.invalid))("aria-errormessage","emailError"),r(2),l("translationParams",C(124,T,s(44,82,"register.emailAddress.label")))("control",_.registerForm.get("email")),r(5),f("",s(49,84,"register.password.label")," "),r(3),l("placeholder",x(s(52,86,"register.password.placeholder"))),A("aria-label",s(53,88,"register.password.placeholder")),r(4),f(" ",s(56,90,"register.passwordMinRequirements")," "),r(2),l("translationParams",C(126,T,s(58,92,"register.password.label")))("control",_.registerForm.get("password")),r(5),f("",s(63,94,"register.confirmPassword.label")," "),r(3),l("placeholder",x(s(66,96,"register.confirmPassword.placeholder"))),A("aria-label",s(67,98,"register.confirmPassword.placeholder"))("aria-invalid",((c=_.registerForm.get("passwordconf"))==null?null:c.touched)&&((c=_.registerForm.get("passwordconf"))==null?null:c.invalid))("aria-errormessage","passwordconfError"),r(3),l("translationParams",C(128,T,s(69,100,"register.confirmPassword.label")))("control",_.registerForm.get("passwordconf")),r(4),l("ngIf",s(73,102,_.anonymousConsent$)),r(2),l("ngIf",_.additionalRegistrationConsents),r(4),A("aria-invalid",((g=_.registerForm.get("termsandconditions"))==null?null:g.touched)&&((g=_.registerForm.get("termsandconditions"))==null?null:g.invali
1d))("aria-errormessage","termsandconditionsError"),r(3),f(" ",s(82,104,"register.confirmThatRead")," "),r(2),l("routerLink",s(84,106,Y(130,Bi))),r(2),f(" ",s(86,108,"register.termsAndConditions")," "),r(3),l("translationParams",C(131,T,s(89,110,"register.termsAndConditions")))("control",_.registerForm.get("termsandconditions")),r(3),l("control",_.registerForm.get("captcha")),r(2),f(" ",s(94,112,"register.register")," "),r(2),l("routerLink",s(96,114,Y(133,Ni))),r(2),I(s(98,116,"register.signIn"))}}function tn(t,h){t&1&&(d(0,"div",38),p(1,"cx-spinner"),a())}function nn(t,h){t&1&&p(0,"cx-spinner",2)}function rn(t,h){if(t&1){let e=P();d(0,"form",3),b("ngSubmit",function(){let i=y(e).ngIf,c=u();return w(c.onSubmit(i))}),p(1,"cx-form-required-legend"),d(2,"label")(3,"span",4),m(4),o(5,"cxTranslate"),p(6,"cx-form-required-asterisks"),a(),p(7,"input",5),o(8,"cxTranslate"),o(9,"cxTranslate"),p(10,"cx-form-errors",6),o(11,"cxTranslate"),a(),d(12,"label")(13,"span",4),m(14),o(15,"cxTranslate"),p(16,"cx-form-required-asterisks"),a(),p(17,"input",7),o(18,"cxTranslate"),o(19,"cxTranslate"),p(20,"cx-form-errors",8),o(21,"cxTranslate"),a(),d(22,"button",9),m(23),o(24,"cxTranslate"),a()()}if(t&2){let e,n,i=u();l("formGroup",i.form),r(4),f("",s(5,19,"register.newPassword")," "),r(3),l("placeholder",x(s(8,21,"register.password.placeholder"))),A("aria-label",s(9,23,"register.password.placeholder"))("aria-invalid",((e=i.form.get("password"))==null?null:e.touched)&&((e=i.form.get("password"))==null?null:e.invalid))("aria-errormessage","passwordError"),r(3),l("translationParams",C(37,T,s(11,25,"register.newPassword")))("control",i.form.get("password")),r(4),f("",s(15,27,"register.passwordMinRequirements")," "),r(3),l("placeholder",x(s(18,29,"register.confirmPassword.placeholder"))),A("aria-label",s(19,31,"register.confirmPassword.placeholder"))("aria-invalid",((n=i.form.get("passwordConfirm"))==null?null:n.touched)&&((n=i.form.get("passwordConfirm"))==null?null:n.invalid))("aria-errormessage","passwordConfirmError"),r(3),l("translationParams",C(39,T,s(21,33,"register.passwordMinRequirements")))("control",i.form.get("passwordConfirm")),r(2),l("disabled",i.form.disabled),r(),f(" ",s(24,35,"register.resetPassword")," ")}}var on=()=>({cxRoute:"home"});function sn(t,h){t&1&&p(0,"cx-spinner",11)}function an(t,h){t&1&&p(0,"cx-spinner",7)}function ln(t,h){if(t&1){let e=P();d(0,"button",8),b("click",function(){y(e);let i=u();return w(i.onEdit())}),m(1),o(2,"cxTranslate"),a()}t&2&&(r(),f(" ",s(2,1,"common.edit")," "))}function dn(t,h){if(t&1&&(d(0,"div")(1,"div",1)(2,"label",9),m(3),o(4,"cxTranslate"),a(),d(5,"label",10),m(6),o(7,"async"),a()()()),t&2){let e,n=u();r(3),f(" ",s(4,2,"myAccountV2Email.email")," "),r(3),f(" ",(e=s(7,4,n.user$))==null?null:e.uid," ")}}function cn(t,h){if(t&1){let e=P();d(0,"cx-message",11),o(1,"cxTranslate"),b("closeMessage",function(){y(e);let i=u();return w(i.closeDialogConfirmationAlert())}),a()}if(t&2){let e=u();l("text",s(1,2,"myAccountV2Email.reloginIndicator"))("type",e.globalMessageType.MSG_TYPE_INFO)}}function pn(t,h){if(t&1){let e=P();d(0,"div",12)(1,"form",13),b("ngSubmit",function(){y(e);let i=u();return w(i.onSubmit())}),d(2,"label")(3,"span",9),m(4),o(5,"cxTranslate"),a(),p(6,"input",14),o(7,"async"),a(),d(8,"label")(9,"span",9),m(10),o(11,"cxTranslate"),a(),p(12,"input",15),o(13,"cxTranslate"),p(14,"cx-form-errors",16),o(15,"cxTranslate"),a(),d(16,"label")(17,"span",9),m(18),o(19,"cxTranslate"),a(),p(20,"input",17),o(21,"cxTranslate"),p(22,"cx-form-errors",18),o(23,"cxTranslate"),a(),d(24,"label")(25,"span",19),m(26),o(27,"cxTranslate"),a(),p(28,"input",20),o(29,"cxTranslate"),o(30,"cxTranslate"),p(31,"cx-form-errors",21),o(32,"cxTranslate"),a(),d(33,"div",22)(34,"button",23),b("click",function(){y(e);let i=u();return w(i.cancelEdit())}),m(35),o(36,"cxTranslate"),a(),d(37,"button",24),b("click",function(){y(e);let i=u();return w(i.onSubmit())}),m(38),o(39,"cxTranslate"),a()()()()}if(t&2){let e,n,i,c,g=u();r(),l("formGroup",g.form),r(3),I(s(5,28,"myAccountV2Email.emailAddress")),r(2),l("value",(e=s(7,30,g.user$))==null?null:e.uid),r(4),I(s(11,32,"myAccountV2Email.newEmailAddress")),r(2),l("placeholder",x(s(13,34,"myAccountV2Email.emailPlaceHolder"))),A("aria-invalid",((n=g.form.get("email"))==null?null:n.touched)&&((n=g.form.get("email"))==null?null:n.invalid))("aria-errormessage","emailError"),r(2),l("translationParams",C(56,T,s(15,36,"updateEmailForm.newEmailAddress.label")))("control",g.form.get("email")),r(4),I(s(19,38,"myAccountV2Email.confirmNewEmailAddress")),r(2),l("placeholder",x(s(21,40,"myAccountV2Email.emailPlaceHolder"))),A("aria-invalid",((i=g.form.get("confirmEmail"))==null?null:i.touched)&&((i=g.form.get("confirmEmail"))==null?null:i.invalid))("aria-errormessage","confirmEmailError"),r(2),l("translationParams",C(58,T,s(23,42,"updateEmailForm.confirmNewEmailAddress.label")))("control",g.form.get("confirmEmail")),r(4),I(s(27,44,"myAccountV2Email.password")),r(2),l("placeholder",x(s(29,46,"myAccountV2Email.passwordPlaceHolder"))),A("aria-label",s(30,48,"myAccountV2Email.passwordPlaceHolder"))("aria-invalid",((c=g.form.get("password"))==null?null:c.touched)&&((c=g.form.get("password"))==null?null:c.invalid))("aria-errormessage","passwordError"),r(3),l("translationParams",C(60,T,s(32,50,"updateEmailForm.password.label")))("control",g.form.get("password")),r(4),f(" ",s(36,52,"common.cancel")," "),r(2),l("disabled",g.form.disabled),r(),f(" ",s(39,54,"common.save")," ")}}function mn(t,h){t&1&&p(0,"cx-spinner",11)}function un(t,h){t&1&&p(0,"cx-spinner",15)}function gn(t,h){if(t&1){let e=P();d(0,"cx-message",16),o(1,"cxTranslate"),b("closeMessage",function(){y(e);let i=u();return w(i.closeDialogConfirmationAlert())}),a()}if(t&2){let e=u();l("text",s(1,2,"myAccountV2PasswordForm.reloginIndicator"))("type",e.globalMessageType.MSG_TYPE_INFO)}}var Ve=t=>({ariaLabel:t});function fn(t,h){t&1&&p(0,"cx-spinner",14)}function hn(t,h){if(t&1&&(d(0,"ng-option",15),m(1),a()),t&2){let e=h.$implicit;l("value",e.code),r(),I(e.name)}}function vn(t,h){t&1&&p(0,"cx-form-required-asterisks")}function _n(t,h){t&1&&p(0,"cx-spinner",6)}function xn(t,h){if(t&1){let e=P();d(0,"button",7),b("click",function(){y(e);let i=u();return w(i.onEdit())}),m(1),o(2,"cxTranslate"),a()}t&2&&(r(),f(" ",s(2,1,"common.edit")," "))}function Cn(t,h){if(t&1&&(d(0,"div")(1,"div",1)(2,"label",8),m(3),o(4,"cxTranslate"),a(),d(5,"label",9),m(6),o(7,"async"),a()(),d(8,"div",1)(9,"label",8),m(10),o(11,"cxTranslate"),a(),d(12,"label",9),m(13),o(14,"async"),o(15,"async"),a()(),d(16,"div",1)(17,"label",8),m(18),o(19,"cxTranslate"),a(),d(20,"label",9),m(21),o(22,"async"),a()()()),t&2){let e,n,i,c=u();r(3),f(" ",s(4,7,"myAccountV2UserProfile.title")," "),r(3),f(" ",(e=s(7,9,c.user$))==null?null:e.title," "),r(4),f(" ",s(11,11,"myAccountV2UserProfile.name")," "),r(3),Re(" ",(n=s(14,13,c.user$))==null?null:n.firstName," ",(n=s(15,15,c.user$))==null?null:n.lastName," "),r(5),f(" ",s(19,17,"myAccountV2UserProfile.customerId")," "),r(3),f(" ",(i=s(22,19,c.user$))==null?null:i.customerId," ")}}function bn(t,h){if(t&1&&(d(0,"ng-option",24),m(1),a()),t&2){let e=h.$implicit;l("value",e.code),r(),I(e.name)}}function yn(t,h){if(t&1){let e=P();d(0,"div",10)(1,"form",11),b("ngSubmit",function(){y(e);let i=u();return w(i.onSubmit())}),d(2,"label")(3,"span",12),m(4),o(5,"cxTranslate"),a(),d(6,"ng-select",13),o(7,"cxTranslate"),o(8,"c
1xTranslate"),v(9,bn,2,2,"ng-option",14),o(10,"async"),a()(),d(11,"label")(12,"span",12),m(13),o(14,"cxTranslate"),a(),p(15,"input",15)(16,"cx-form-errors",16),o(17,"cxTranslate"),a(),d(18,"label")(19,"span",12),m(20),o(21,"cxTranslate"),a(),p(22,"input",17)(23,"cx-form-errors",18),o(24,"cxTranslate"),a(),d(25,"label")(26,"span",12),m(27),o(28,"cxTranslate"),a(),p(29,"input",19)(30,"cx-form-errors",20),o(31,"cxTranslate"),a()(),d(32,"div",21)(33,"button",22),b("click",function(){y(e);let i=u();return w(i.cancelEdit())}),m(34),o(35,"cxTranslate"),a(),d(36,"button",23),b("click",function(){y(e);let i=u();return w(i.onSubmit())}),m(37),o(38,"cxTranslate"),a()()()}if(t&2){let e,n,i,c=u();r(),l("formGroup",c.form),r(3),I(s(5,26,"myAccountV2UserProfile.title")),r(2),l("ariaLabelDropdown",x(s(7,28,"common.ngSelectDropdownOptionsList")))("clearable",!1)("searchable",!1)("cxNgSelectA11y",C(50,Ve,s(8,30,"myAccountV2UserProfile.title"))),r(3),l("ngForOf",s(10,32,c.titles$)),r(4),I(s(14,34,"myAccountV2UserProfile.firstName")),r(2),A("aria-invalid",((e=c.form.get("firstName"))==null?null:e.touched)&&((e=c.form.get("firstName"))==null?null:e.invalid))("aria-errormessage","firstNameError"),r(),l("translationParams",C(52,T,s(17,36,"updateProfileForm.firstName.label")))("control",c.form.get("firstName")),r(4),I(s(21,38,"myAccountV2UserProfile.lastName")),r(2),A("aria-invalid",((n=c.form.get("lastName"))==null?null:n.touched)&&((n=c.form.get("lastName"))==null?null:n.invalid))("aria-errormessage","lastNameError"),r(),l("translationParams",C(54,T,s(24,40,"updateProfileForm.lastName.label")))("control",c.form.get("lastName")),r(4),I(s(28,42,"myAccountV2UserProfile.customerId")),r(2),A("aria-invalid",((i=c.form.get("customerId"))==null?null:i.touched)&&((i=c.form.get("customerId"))==null?null:i.invalid))("aria-errormessage","customerIdError"),r(),l("translationParams",C(56,T,s(31,44,"updateProfileForm.customerId")))("control",c.form.get("customerId")),r(4),f(" ",s(35,46,"common.cancel")," "),r(2),l("disabled",c.form.disabled),r(),f(" ",s(38,48,"common.save")," ")}}var wn=["submit"],ni=()=>({required:"true"});function Sn(t,h){if(t&1){let e=P();d(0,"div")(1,"label")(2,"span",7),m(3),o(4,"cxTranslate"),p(5,"cx-form-required-asterisks"),a(),d(6,"ng-select",29),o(7,"cxTranslate"),o(8,"c
1xTranslate"),b("change",function(i){y(e);let c=u(2);return w(c.countrySelected(i))}),a(),p(9,"cx-form-errors",30),o(10,"cxTranslate"),a()()}if(t&2){let e=u().ngIf,n=u();r(3),f("",s(4,12,"addressForm.country")," "),r(3),l("placeholder",x(s(7,14,"addressForm.selectOne")))("ariaLabelDropdown",x(s(8,16,"common.ngSelectDropdownOptionsList")))("inputAttrs",Y(20,ni))("searchable",!0)("clearable",!1)("items",e)("cxNgSelectA11y",Y(21,ii)),r(3),l("translationParams",C(22,T,s(10,18,"addressForm.country")))("control",n.addressForm.get("country.isocode"))}}function Tn(t,h){if(t&1&&(D(0),v(1,Sn,11,24,"div",4),R()),t&2){let e=h.ngIf;r(),l("ngIf",e.length!==0)}}function An(t,h){if(t&1&&(d(0,"div")(1,"label")(2,"span",7),m(3),o(4,"cxTranslate"),a(),p(5,"ng-select",31),o(6,"cxTranslate"),o(7,"cxTranslate"),o(8,"cxTranslate"),a()()),t&2){let e=u().ngIf;r(3),I(s(4,8,"addressForm.titleOptional")),r(2),l("ariaLabelDropdown",x(s(6,10,"common.ngSelectDropdownOptionsList")))("searchable",!0)("clearable",!1)("items",e)("placeholder",s(7,12,"addressForm.title"))("cxNgSelectA11y",C(16,Ve,s(8,14,"addressForm.titleOptional")))}}function Fn(t,h){if(t&1&&(D(0),v(1,An,9,18,"div",4),R()),t&2){let e=h.ngIf;r(),l("ngIf",e.length!==0)}}function En(t,h){if(t&1&&(d(0,"div",6),v(1,Fn,2,1,"ng-container",4),o(2,"async"),a()),t&2){let e=u();r(),l("ngIf",s(2,1,e.titles$))}}function In(t,h){if(t&1){let e=P();D(0),d(1,"div",23)(2,"label")(3,"span",7),m(4),o(5,"cxTranslate"),p(6,"cx-form-required-asterisks"),a(),d(7,"ng-select",33),o(8,"cxTranslate"),o(9,"cxTranslate"),o(10,"cxTranslate"),b("change",function(i){y(e);let c=u(4);return w(c.regionSelected(i))}),a(),p(11,"cx-form-errors",30),o(12,"cxTranslate"),a()(),R()}if(t&2){let e=u().ngIf,n=u(3);r(4),f("",s(5,16,"addressForm.province")," "),r(3),l("bindLabel",x(e[0].name?"name":"isocode"))("bindValue",x(e[0].name?"isocode":"region"))("placeholder",x(s(8,18,"addressForm.selectOne")))("ariaLabelDropdown",x(s(9,20,"common.ngSelectDropdownOptionsList")))("inputAttrs",Y(26,ni))("searchable",!0)("clearable",!1)("items",e)("cxNgSelectA11y",C(27,Ve,s(10,22,"addressForm.province"))),r(4),l("translationParams",C(29,T,s(12,24,"addressForm.province")))("control",n.addressForm.get("region.isocode"))}}function Pn(t,h){if(t&1&&(D(0,32),v(1,In,13,31,"ng-container",4),R()),t&2){let e=h.ngIf;r(),l("ngIf",e.length!==0)}}function kn(t,h){if(t&1&&(D(0),v(1,Pn,2,1,"ng-container",22),o(2,"async"),R()),t&2){let e=u(2);r(),l("ngIf",s(2,1,e.regions$))}}function Bn(t,h){if(t&1&&(D(0),v(1,kn,3,3,"ng-container",4),R()),t&2){let e=u();r(),l("ngIf",e.isHierarchicalAddressFormat)}}function Nn(t,h){if(t&1){let e=P();d(0,"ng-select",35),o(1,"cxTranslate"),o(2,"cxTranslate"),o(3,"cxTranslate"),b("change",function(i){y(e);let c=u(2);return w(c.citySelected(i))}),a()}if(t&2){let e=u(2);l("placeholder",x(e.selectedRegion$.value?s(1,6,"addressForm.selectOne"):s(2,8,"addressForm.selectProvinceFirst")))("searchable",!0)("clearable",!1)("items",e.cities)("cxNgSelectA11y",C(12,Ve,s(3,10,"addressForm.city.label")))}}function Vn(t,h){if(t&1&&(D(0),v(1,Nn,4,14,"ng-select",34),R()),t&2){let e=u(),n=be(54);r(),l("ngIf",e.isHierarchicalAddressFormat)("ngIfElse",n)}}function Mn(t,h){t&1&&li(0)}function Dn(t,h){if(t&1&&(D(0),v(1,Mn,1,0,"ng-container",36),R()),t&2){u();let e=be(54);r(),l("ngTemplateOutlet",e)}}function Rn(t,h){if(t&1&&(p(0,"input",37),o(1,"cxTranslate")),t&2){let e,n=u();l("placeholder",x(s(1,4,"addressForm.city.placeholder"))),A("aria-invalid",((e=n.addressForm.get("town"))==null?null:e.touched)&&((e=n.addressForm.get("town"))==null?null:e.invalid))("aria-errormessage","townError")}}function $n(t,h){if(t&1&&(d(0,"div",23)(1,"label")(2,"span",7),m(3),o(4,"cxTranslate"),p(5,"cx-form-required-asterisks"),a(),p(6,"ng-select",39),o(7,"cxTranslate"),o(8,"c
1xTranslate"),o(9,"cxTranslate"),p(10,"cx-form-errors",30),o(11,"cxTranslate"),a()()),t&2){let e=u(2);r(3),f("",s(4,9,"addressForm.district")," "),r(3),l("placeholder",x(e.selectedCity$.value?s(7,11,"addressForm.selectOne"):s(8,13,"addressForm.selectCityFirst")))("searchable",!0)("clearable",!1)("items",e.districts)("cxNgSelectA11y",C(19,Ve,s(9,15,"addressForm.district"))),r(4),l("translationParams",C(21,T,s(11,17,"addressForm.district")))("control",e.addressForm.get("district"))}}function qn(t,h){if(t&1&&(D(0),v(1,$n,12,23,"div",38),R()),t&2){let e=u();r(),l("ngIf",e.isHierarchicalAddressFormat)}}function Ln(t,h){if(t&1&&(D(0),d(1,"div",23)(2,"label")(3,"span",7),m(4),o(5,"cxTranslate"),p(6,"cx-form-required-asterisks"),a(),p(7,"ng-select",40),o(8,"cxTranslate"),o(9,"cxTranslate"),o(10,"cxTranslate"),p(11,"cx-form-errors",41),a()(),R()),t&2){let e=u().ngIf,n=u();r(4),f("",s(5,15,"addressForm.state")," "),r(3),l("bindLabel",x(e[0].name?"name":"isocode"))("bindValue",x(e[0].name?"isocode":"region"))("placeholder",x(s(8,17,"addressForm.selectOne")))("ariaLabelDropdown",x(s(9,19,"common.ngSelectDropdownOptionsList")))("inputAttrs",Y(23,ni))("searchable",!0)("clearable",!1)("items",e)("cxNgSelectA11y",C(24,Ve,s(10,21,"addressForm.state"))),r(4),l("control",n.addressForm.get("region.isocode"))}}
1function Un(t,h){if(t&1&&(D(0,32),v(1,Ln,12,26,"ng-container",4),R()),t&2){let e=h.ngIf;r(),l("ngIf",e.length!==0)}}function On(t,h){t&1&&p(0,"cx-form-required-asterisks")}function Gn(t,h){if(t&1&&(p(0,"cx-form-errors",30),o(1,"cxTranslate")),t&2){let e=u(2);l("translationParams",C(4,T,s(1,2,"addressForm.cellphone.requiredLabel")))("control",e.addressForm.get("cellphone"))}}function jn(t,h){if(t&1&&(D(0),d(1,"div",23)(2,"label")(3,"span",14),m(4),o(5,"cxTranslate"),v(6,On,1,0,"cx-form-required-asterisks",4),a(),p(7,"input",42),o(8,"cxTranslate"),v(9,Gn,2,6,"cx-form-errors",43),a()(),R()),t&2){let e=u();r(3),di("required",e.isHierarchicalAddressFormat),r(),f("",s(5,7,e.isHierarchicalAddressFormat?"addressForm.cellphone.requiredLabel":"addressForm.cellphone.label")," "),r(2),l("ngIf",e.isHierarchicalAddressFormat),r(),l("placeholder",x(s(8,9,"addressForm.cellphone.placeholder"))),r(2),l("ngIf",e.isHierarchicalAddressFormat)}}function Hn(t,h){t&1&&(D(0),d(1,"div",23)(2,"label")(3,"span",14),m(4),o(5,"cxTranslate"),a(),p(6,"input",42),o(7,"cxTranslate"),a()(),R()),t&2&&(r(4),I(s(5,3,"addressForm.cellphone.label")),r(2),l("placeholder",x(s(7,5,"addressForm.cellphone.placeholder"))))}function Wn(t,h){if(t&1){let e=P();d(0,"div",6)(1,"div",44)(2,"label")(3,"input",45),b("change",function(){y(e);let i=u();return w(i.toggleDefaultAddress())}),a(),d(4,"span",46),m(5),o(6,"cxTranslate"),a()()()()}t&2&&(r(5),I(s(6,1,"addressForm.setAsDefault")))}function Yn(t,h){if(t&1){let e=P();d(0,"div",27)(1,"button",47),b("click",function(){y(e);let i=u();return w(i.back())}),m(2),o(3,"cxTranslate"),a()()}if(t&2){let e=u();r(2),f(" ",e.cancelBtnLabel||s(3,1,"addressForm.chooseAddress")," ")}}function Qn(t,h){if(t&1){let e=P();d(0,"div",9)(1,"cx-card",10),o(2,"async"),b("editCard",function(){let i=y(e).$implicit,c=u(3);return w(c.editAddressButtonHandle(i))})("setDefaultCard",function(){let i=y(e).$implicit,c=u(3);return w(c.setAddressAsDefault(i))})("deleteCard",function(){let i=y(e).$implicit,c=u(3);return w(c.setEdit(i.id??""))})("cancelCard",function(){y(e);let i=u(3);return w(i.cancelCard())}),a()()}if(t&2){let e=h.$implicit,n=h.index,i=u(3);r(),l("index",n)("border",!0)("fitToContainer",!0)("content",s(2,5,i.getCardContent(e)))("editMode",e.id===i.editCard)}}function zn(t,h){if(t&1&&(d(0,"div",7),v(1,Qn,3,7,"div",8),o(2,"async"),a()),t&2){let e=u(2);r(),l("ngForOf",s(2,1,e.addresses$))}}function Kn(t,h){if(t&1){let e=P();D(0),d(1,"div",3)(2,"div",4)(3,"button",5),b("click",function(){y(e);let i=u();return w(i.addAddressButtonHandle())}),m(4),o(5,"cxTranslate"),a()()(),v(6,zn,3,3,"div",6),o(7,"async"),R()}if(t&2){let e=u(),n=be(7);r(4),f(" ",s(5,3,"addressBook.addNewAddress")," "),r(2),l("ngIf",!s(7,5,e.addressesStateLoading$))("ngIfElse",n)}}function Jn(t,h){if(t&1){let e=P();D(0),d(1,"section")(2,"h2",11),m(3),o(4,"cxTranslate"),a(),d(5,"cx-address-form",12),o(6,"cxTranslate"),o(7,"cxTranslate"),o(8,"async"),o(9,"async"),b("submitAddress",function(i){y(e);let c=u();return w(c.addAddressSubmit(i))})("backToAddress",function(){y(e);let i=u();return w(i.addAddressCancel())})("cancelCard",function(){y(e);let i=u();return w(i.cancelCard())}),a()(),R()}if(t&2){let e,n,i=u();r(3),f(" ",s(4,8,"addressBook.addNewDeliveryAddress")," "),r(2),l("actionBtnLabel",x(s(6,10,"addressBook.addAddress")))("cancelBtnLabel",x(s(7,12,"addressBook.backToAddressList")))("showTitleCode",!0)("showCancelBtn",((e=s(8,14,i.addresses$))==null?null:e.length)!==0)("setAsDefaultField",((n=s(9,16,i.addresses$))==null?null:n.length)!==0)}}function Xn(t,h){if(t&1){let e=P();D(0),d(1,"section")(2,"h2",11),m(3),o(4,"cxTranslate"),a(),d(5,"cx-address-form",13),o(6,"cxTranslate"),o(7,"cxTranslate"),b("submitAddress",function(i){y(e);let c=u();return w(c.editAddressSubmit(i))})("backToAddress",function(){y(e);let i=u();return w(i.editAddressCancel())}),a()(),R()}if(t&2){let e=u();r(3),f(" ",s(4,7,"addressBook.editDeliveryAddress")," "),r(2),l("actionBtnLabel",x(s(6,9,"addressBook.updateAddress")))("cancelBtnLabel",x(s(7,11,"addressBook.backToAddressList")))("showTitleCode",!0)("addressData",e.currentAddress)}}function Zn(t,h){t&1&&(d(0,"div",14),p(1,"cx-spinner"),a())}function er(t,h){if(t&1){let e=P();d(0,"div",12)(1,"input",23),Se("ngModelChange",function(i){y(e);let c=u(2);return we(c.selectedAddress,i)||(c.selectedAddress=i),w(i)}),a(),d(2,"label",24),m(3),o(4,"cxTranslate"),a(),d(5,"div",25)(6,"div",16)(7,"div",17),m(8),a(),d(9,"div",17),m(10),a(),d(11,"div",17),m(12),a(),d(13,"div",17)(14,"span"),m(15),a()(),d(16,"div",17),m(17),a(),d(18,"div",17),m(19),a(),d(20,"div",17),m(21),a()()()()}if(t&2){let e=h.$implicit,n=h.index,i=u().ngIf,c=u();r(),ye("ngModel",c.selectedAddress),l("value",e)("id","suggested-addresses--suggested-"+n),r(),l("for","suggested-addresses--suggested-"+n),r(),Re(" ",s(4,13,"addressSuggestion.suggestedAddress")," ",i.suggestedAddresses.length>1?n+1:null," "),r(5),I(e==null?null:e.firstName),r(2),I(e==null?null:e.lastName),r(2),I(e==null?null:e.line1),r(3),I(e==null?null:e.line2),r(2),I(e==null?null:e.town),r(2),f(" ",e==null||e.regi
1on==null?null:e.region.isocode," "),r(2),f(" ",e==null?null:e.postalCode," ")}}function tr(t,h){if(t&1){let e=P();d(0,"div",2)(1,"div",3)(2,"h3",4),m(3),o(4,"cxTranslate"),a(),d(5,"button",5),o(6,"cxTranslate"),o(7,"cxTranslate"),b("click",function(){y(e);let i=u();return w(i.closeModal("Cross click"))}),d(8,"span",6),p(9,"cx-icon",7),a()()(),d(10,"div",8)(11,"div",9)(12,"p"),m(13),o(14,"cxTranslate"),o(15,"cxTranslate"),a()(),d(16,"div",10),v(17,er,22,15,"div",11),d(18,"div",12)(19,"input",13),Se("ngModelChange",function(i){y(e);let c=u();return we(c.selectedAddress,i)||(c.selectedAddress=i),w(i)}),a(),d(20,"label",14),m(21),o(22,"cxTranslate"),a(),d(23,"div",15)(24,"div",16)(25,"div",17),m(26),a(),d(27,"div",17),m(28),a(),d(29,"div",17)(30,"span"),m(31),a()(),d(32,"div",17),m(33),a(),d(34,"div",17),m(35),a()()()()()(),d(36,"div",18)(37,"div",19)(38,"div",20)(39,"button",21),b("click",function(){y(e);let i=u();return w(i.closeModal("Edit address"))}),m(40),o(41,"cxTranslate"),a(),d(42,"button",22),b("click",function(){y(e);let i=u();return w(i.closeModal(i.selectedAddress))}),m(43),o(44,"cxTranslate"),a()()()()()}if(t&2){let e=h.ngIf,n=u();r(3),f(" ",s(4,20,"addressSuggestion.verifyYourAddress")," "),r(2),l("title",x(s(6,22,"common.close"))),A("aria-label",s(7,24,"common.close")),r(4),l("type",n.iconTypes.CLOSE),r(4),Re(" ",s(14,26,"addressSuggestion.ensureAccuracySuggestChange")," ",s(15,28,"addressSuggestion.chooseAddressToUse")," "),r(4),l("ngForOf",e.suggestedAddresses),r(2),ye("ngModel",n.selectedAddress),l("value",e.enteredAddress),r(2),f(" ",s(22,30,"addressSuggestion.enteredAddress")," "),r(5),Re(" ",e.enteredAddress==null?null:e.enteredAddress.firstName," ",e.enteredAddress==null?null:e.enteredAddress.lastName," "),r(2),I(e.enteredAddress==null?null:e.enteredAddress.line1),r(3),I(e.enteredAddress==null?null:e.enteredAddress.line2),r(2),Re(" ",e.enteredAddress==null?null:e.enteredAddress.town," ",e.enteredAddress==null||e.enteredAddress.region==null?null:e.enteredAddress.region.isocode," "),r(2),f(" ",e.enteredAddress==null?null:e.enteredAddress.postalCode," "),r(5),f(" ",s(41,32,"addressSuggestion.editAddress")," "),r(3),f(" ",s(44,34,"addressSuggestion.saveAddress")," ")}}function ir(t,h){if(t&1&&(d(0,"label"),p(1,"input",24),d(2,"span",18),m(3),a()()),t&2){let e=h.ngIf,n=u(2);r(),l("checked",n.isConsentGiven(e.consent)),r(2),f(" ",e.template," ")}}function nr(t,h){if(t&1){let e=P();d(0,"div")(1,"label")(2,"input",27),b("change",function(i){y(e);let c=u().index,g=u(3);return w(g.updateAdditionalConsents(i,c))}),a(),d(3,"span",18),m(4),a(),p(5,"cx-form-errors",21),a()()}if(t&2){let e=h.ngIf,n=u(),i=n.$implicit,c=n.index,g=u().ngIf;r(2),l("required",g[c].required)("name",e)("formControlName",c),r(2),f(" ",g[c].template.description," "),r(),l("control",i)}}function rr(t,h){if(t&1&&(d(0,"div",14),v(1,nr,6,5,"div",15),a()),t&2){let e=h.index,n=u().ngIf;r(),l("ngIf",n[e]==null||n[e].template==null?null:n[e].template.id)}}function or(t,h){if(t&1&&(d(0,"div",25),v(1,rr,2,1,"div",26),a()),t&2){let e=u(2);r(),l("ngForOf",e.additionalConsents.controls)}}function sr(t,h){if(t&1){let e=P();d(0,"section",2)(1,"div",3)(2,"div",4)(3,"div",5)(4,"form",6),b("ngSubmit",function(){y(e);let i=u();return w(i.submitForm())}),d(5,"div",7)(6,"label")(7,"span",8),m(8),o(9,"cxTranslate"),a(),p(10,"ng-select",9),o(11,"cxTranslate"),o(12,"async"),o(13,"cxTranslate"),a()(),d(14,"div",7)(15,"label")(16,"span",8),m(17),o(18,"cxTranslate"),p(19,"cx-form-required-asterisks"),a(),p(20,"input",10),o(21,"cxTranslate"),p(22,"cx-form-errors",11),o(23,"cxTranslate"),a()(),d(24,"div",7)(25,"label")(26,"span",8),m(27),o(28,"cxTranslate"),p(29,"cx-form-required-asterisks"),a(),p(30,"input",12),o(31,"cxTranslate"),p(32,"cx-form-errors",11),o(33,"cxTranslate"),a()(),d(34,"div",7)(35,"label")(36,"span",8),m(37),o(38,"cxTranslate"),p(39,"cx-form-required-asterisks"),a(),p(40,"input",13),o(41,"cxTranslate"),p(42,"cx-form-errors",11),o(43,"cxTranslate"),a()(),d(44,"div",7)(45,"div",14),v(46,ir,4,2,"label",15),o(47,"async"),a()(),v(48,or,2,1,"div",16),d(49,"div",7)(50,"div",14)(51,"label"),p(52,"input",17),d(53,"span",18),m(54),o(55,"cxTranslate"),d(56,"a",19),o(57,"cxUrl"),m(58),o(59,"cxTranslate"),a(),p(60,"cx-form-required-asterisks"),a(),p(61,"cx-form-errors",11),o(62,"cxTranslate"),a()()(),d(63,"cx-captcha",20),b("confirmed",function(){y(e);let i=u();return w(i.captchaConfirmed())}),a(),p(64,"cx-form-errors",21),d(65,"button",22),m(66),o(67,"cxTranslate"),a(),d(68,"a",23),o(69,"cxUrl"),m(70),o(71,"cxTranslate"),a()()()()()()}if(t&2){let e=u();r(4),l("formGroup",e.registerForm),r(4),I(s(9,35,"register.title")),r(2),l("ariaLabelDropdown",x(s(11,37,"common.ngSelectDropdownOptionsList")))("clearable",!1)("items",s(12,39,e.titles$)??Y(77,ki))("placeholder",s(13,41,"register.selectTitle"))("searchable",!1)("cxNgSelectA11y",Y(78,ii)),r(7),f("",s(18,43,"register.firstName.label")," "),r(3),l("placeholder",x(s(21,45,"register.firstName.placeholder"))),r(2),l("translationParams",C(79,T,s(23,47,"register.firstName.label")))("control",e.registerForm.get("firstName")),r(5),f("",s(28,49,"register.lastName.label")," "),r(3),l("placeholder",x(s(31,51,"register.lastName.placeholder"))),r(2),l("translationParams",C(81,T,s(33,53,"register.lastName.label")))("control",e.registerForm.get("lastName")),r(5),f("",s(38,55,"register.emailAddress.label")," "),r(3),l("placeholder",x(s(41,57,"register.emailAddress.placeholder"))),r(2),l("translationParams",C(83,T,s(43,59,"register.emailAddress.label")))("control",e.registerForm.get("email")),r(4),l("ngIf",s(47,61,e.anonymousConsent$)),r(2),l("ngIf",e.additionalRegistrationConsents),r(6),f(" ",s(55,63,"register.confirmThatRead")," "),r(2),l("routerLink",s(57,65,Y(85,Bi))),r(2),f(" ",s(59,67,"register.termsAndConditions")," "),r(3),l("translationParams",C(86,T,
1s(62,69,"register.termsAndConditions")))("control",e.registerForm.get("termsandconditions")),r(3),l("control",e.registerForm.get("captcha")),r(2),f(" ",s(67,71,"register.furtherRegistration")," "),r(2),l("routerLink",s(69,73,Y(88,Ni))),r(2),I(s(71,75,"register.signIn"))}}function ar(t,h){t&1&&(d(0,"div",28),p(1,"cx-spinner"),a())}var lr=["noReceiveCodeLink"],dr=["resendLink"],cr=t=>({seconds:t}),pr=t=>({"disabled-link":t}),mr=t=>({waitTime:t});function ur(t,h){if(t&1&&(d(0,"div",18),m(1),o(2,"cxTranslate"),a()),t&2){let e=u();r(),f(" ",Nt(2,1,"register.rateLimitForRegistrationMessage",C(4,cr,e.waitTimeForRateLimit))," ")}}function gr(t,h){if(t&1&&(D(0),m(1),o(2,"cxTranslate"),R()),t&2){let e=u(2);r(),f(" ",Nt(2,1,"verificationTokenForm.sendRateLime",C(4,mr,e.waitTime))," ")}}function fr(t,h){if(t&1){let e=P();d(0,"div",19)(1,"div",20)(2,"span",21)(3,"a",22,1),b("keydown.enter",function(){y(e);let i=u();return w(i.resendOTP())})("keydown.space",function(){y(e);let i=u();return w(i.resendOTP())})("click",function(){y(e);let i=u();return w(i.resendOTP())}),m(5),o(6,"cxTranslate"),a(),v(7,gr,3,6,"ng-container",23),a()(),d(8,"div",24)(9,"a",25,2),b("keydown",function(i){y(e);let c=u();return w(c.onOpenInfoDailogKeyDown(i))})("click",function(){y(e);let i=u();return w(i.openInfoDailog())}),m(11),o(12,"cxTranslate"),a()()()}if(t&2){let e=u();r(3),l("ngClass",C(8,pr,e.isResendDisabled)),r(2),f(" ",s(6,4,"verificationTokenForm.resend")," "),r(2),l("ngIf",e.isResendDisabled),r(4),f(" ",s(12,6,"verificationTokenForm.noReceiveCode")," ")}}function hr(t,h){t&1&&(d(0,"div",26),p(1,"cx-spinner"),a())}var Vi=(()=>{class t{handleClick(e){e.target.tagName===this.el.nativeElement.tagName&&this.dismissModal("Cross click")}constructor(e,n,i,c,g,_,ae){this.authService=e,this.globalMessageService=n,this.routingService=i,this.translationService=c,this.userProfile=g,this.launchDialogService=_,this.el=ae,this.iconTypes=Gt,this.focusConfig={trap:!0,block:!0,autofocus:"button",focusOnEscape:!0},this.loading$=new X(!1)}get isLoading$(){return this.loading$.asObservable()}ngOnInit(){this.isLoggedIn$=this.authService.isUserLoggedIn()}onSuccess(){this.dismissModal("Success"),this.translationService.translate("closeAccount.accountClosedSuccessfully").pipe(St()).subscribe(e=>{this.globalMessageService.add(e,k.MSG_TYPE_CONFIRMATION)}),this.authService.coreLogout().then(()=>{this.routingService.go({cxRoute:"home"})})}onError(){this.dismissModal("Error"),this.translationService.translate("closeAccount.accountClosedFailure").pipe(St()).subscribe(e=>{this.globalMessageService.add(e,k.MSG_TYPE_ERROR)})}dismissModal(e){this.launchDialogService.closeDialog(e)}closeAccount(){this.loading$.next(!0),this.userProfile.close().subscribe({next:()=>{this.onSuccess(),this.loading$.next(!1)},error:()=>{this.onError(),this.loading$.next(!1)}})}static{this.\u0275fac=function(n){return new(n||t)(E(Ee),E(V),E(q),E(ct),E(Be),E(Ie),E(It))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-close-account-modal"]],hostBindings:function(n,i){n&1&&b("click",function(g){return i.handleClick(g)})},decls:2,vars:3,consts:[["loaded",""],[4,"ngIf"],[1,"modal-dialog","modal
1-dialog-centered","cx-close-account-modal",3,"esc","cxFocus"],[1,"modal-content","cx-close-account-modal-container"],[1,"cx-close-account-modal-header","cx-modal-header"],[1,"cx-close-account-modal-title"],["type","button",1,"close",3,"click","title"],["aria-hidden","true"],[3,"type"],[4,"ngIf","ngIfElse"],[1,"cx-spinner"],[1,"modal-body"],[1,"cx-confirmation"],[1,"cx-close-account-modal-footer","cx-modal-footer"],[1,"btn","btn-primary",3,"click"],[1,"btn","btn-block","btn-secondary",3,"click"]],template:function(n,i){n&1&&(v(0,Hi,16,16,"ng-container",1),o(1,"async")),n&2&&l("ngIf",s(1,1,i.isLoggedIn$))},dependencies:[G,Ht,jt,J,H,O],encapsulation:2,changeDetection:0})}}return t})(),vr={launch:{CLOSE_ACCOUNT:{inline:!0,component:Vi,dialogType:Wt.DIALOG}}},_r=(()=>{class t{constructor(e,n){this.launchDialogService=e,this.vcr=n,this.routingService=S(q,{optional:!0})}openModal(){this.launchDialogService.openDialog(ft.CLOSE_ACCOUNT,this.element,this.vcr)?.pipe(De(1)).subscribe()}navigateTo(e){this.routingService?.go({cxRoute:e})}static{this.\u0275fac=function(n){return new(n||t)(E(Ie),E(ai))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-close-account"]],viewQuery:function(n,i){if(n&1&&ot(Wi,5),n&2){let c;ze(c=Ke())&&(i.element=c.first)}},decls:11,vars:6,consts:[["element",""],[1,"col-lg-8","col-md-9"],[1,"row","cx-btn-group"],[1,"col-sm-6"],[1,"btn","btn-block","btn-secondary",3,"click"],[1,"btn","btn-block","btn-primary",3,"click"]],template:function(n,i){n&1&&(Pt(0,"div",1)(1,"div",2)(2,"div",3)(3,"button",4),Bt("click",function(){return i.navigateTo("home")}),m(4),o(5,"cxTranslate"),kt()(),Pt(6,"div",3)(7,"button",5,0),Bt("click",function(){return i.openModal()}),m(9),o(10,"cxTranslate"),kt()()()()),n&2&&(r(4),f(" ",s(5,2,"common.cancel")," "),r(5),f(" ",s(10,4,"closeAccount.closeMyAccount")," "))},dependencies:[O],encapsulation:2,changeDetection:0})}}return t})(),xr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{CloseAccountComponent:{component:_r,guards:[Le]}}}),te(vr)],imports:[le,ce,_e,de,ut,me,gt,Pe,Vi]})}}return t})(),Zt=(()=>{class t{constructor(e,n,i,c){this.userPasswordService=e,this.routingService=n,this.authConfigService=i,this.globalMessage=c,this.busy$=new X(!1),this.isUpdating$=this.busy$.pipe(he(g=>g===!0?this.form.disable():this.form.enable())),this.form=new Oe({userEmail:new j("",[F.required,N.emailValidator])})}requestEmail(){if(!this.form.valid){this.form.markAllAsTouched();return}this.busy$.next(!0),this.userPasswordService.requestForgotPasswordEmail(this.form.value.userEmail).subscribe({next:()=>this.onSuccess(),error:e=>this.onError(e)})}onSuccess(){this.globalMessage.add({key:"forgottenPassword.passwordResetEmailSent"},k.MSG_TYPE_CONFIRMATION),this.busy$.next(!1),this.form.reset(),this.redirect()}onError(e){this.busy$.next(!1)}redirect(){this.authConfigService.getOAuthFlow()===Je.ResourceOwnerPasswordFlow&&this.routingService.go({cxRoute:"login"})}static{this.\u0275fac=function(n){return new(n||t)(B(Ce),B(q),B($e),B(V))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})(),bi=(()=>{class t{constructor(e){this.service=e,this.routingService=S(q,{optional:!0}),this.form=this.service.form,this.isUpdating$=this.service.isUpdating$}onSubmit(){this.service.requestEmail()}navigateTo(e){this.routingService?.go({cxRoute:e})}static{this.\u0275fac=function(n){return new(n||t)(E(Zt))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-forgot-password"]],decls:19,vars:26,consts:[["class","overlay",4,"ngIf"],[3,"ngSubmit","formGroup"],[1,"label-content"],["required","true","type","email","formControlName","userEmail",1,"form-control",3,"placeholder"],["id","userEmailError",3,"translationParams","control"],[1,"btn","btn-block","btn-secondary",3,"click"],[1,"btn","btn-block","btn-primary",3,"disabled"],[1,"overlay"]],template:function(n,i){if(n&1&&(v(0,Yi,1,0,"cx-spinner",0),o(1,"async"),p(2,"cx-form-required-legend"),d(3,"form",1),b("ngSubmit",function(){return i.onSubmit()}),d(4,"label")(5,"span",2),m(6),o(7,"cxTranslate"),p(8,"cx-form-required-asterisks"),a(),p(9,"input",3),o(10,"cxTranslate"),p(11,"cx-form-errors",4),o(12,"cxTranslate"),a(),d(13,"button",5),b("click",function(){return i.navigateTo("login")}),m(14),o(15,"cxTranslate"),a(),d(16,"button",6),m(17),o(18,"cxTranslate"),a()()),n&2){let c;l("ngIf",s(1,12,i.isUpdating$)),r(3),l("formGroup",i.form),r(3),f("",s(7,14,"forgottenPassword.emailAddress.label")," "),r(3),l("placeholder",x(s(10,16,"forgottenPassword.emailAddress.placeholder"))),A("aria-invalid",((c=i.form.get("userEmail"))==null?null:c.touched)&&((c=i.form.get("userEmail"))==null?null:c.invalid))("aria-errormessage","userEmailError"),r(2),l("translationParams",C(24,T,s(12,18,"forgottenPassword.emailAddress.label")))("control",i.form.get("userEmail")),r(3),f(" ",s(15,20,"common.cancel")," "),r(2),l("disabled",i.form.disabled),r(),f(" ",s(18,22,"common.submit")," ")}},dependencies:[G,J,W,$,ie,Q,z,K,oe,M,re,ne,L,se,H,O],encapsulation:2,changeDetection:0})}}return t})(),Cr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{ForgotPasswordComponent:{component:bi,guards:[Ue],providers:[{provide:Zt,useClass:Zt,deps:[Ce,q,$e,V]}]}}})],imports:[le,M,ce,_e,de,ue,me,pe,Pe,L,W,bi]})}}return t})(),He=(()=>{class t{constructor(e,n,i){this.userRegisterFacade=e,this.globalMessageService=n,this.fb=i}register(e){return this.userRegisterFacade.register(e)}getTitles(){return this.userRegisterFacade.getTitles()}postRegisterMessage(){this.globalMessageService.add({key:"register.postRegisterSuccessMessage"},k.MSG_TYPE_CONFIRMATION)}getAdditionalConsents(){return[]}generateAdditionalConsentsFormControl(){return this.fb?.array([])??void 0}collectDataFromRegisterForm(e){let{firstName:n,lastName:i,email:c,password:g,titleCode:_}=e;return{firstName:n,lastName:i,password:g,titleCode:_,uid:c.toLowerCase()}}static{this.\u0275fac=function(n){return new(n||t)(B(Ne),B(V),B(xe))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})(),yi=(()=>{class t{get additionalConsents(){return this.registerForm?.get("additionalConsents")}updateAdditionalConsents(e,n){let{checked:i}=e.target;this.registerForm.value.additionalConsents[n].isConsentGranted=i}constructor(e,n,i,c,g,_,ae){this.globalMessageService=e,this.fb=n,this.router=i,this.anonymousConsentsService=c,this.anonymousConsentsConfig=g,this.authConfigService=_,this.registerComponentService=ae,this.featureConfigService=S(Fe),this.passwordValidators=this.featureConfigService.isEnabled("useEnhancedSecurePasswordValidators")?[...N.securePasswordValidators,N.mustEndWithLegalCharacter]:N.securePasswordValidators,this.isLoading$=new X(!1),this.subscription=new We,this.registerForm=this.fb.group({titleCode:[null],firstName:["",F.required],lastName:["",F.required],email:["",[F.required,N.emailValidator]],password:["",[F.required,...this.passwordValidators]],passwordconf:["",F.required],newsletter:new j({value:!1,disabled:this.isConsentRequired()}),additionalConsents:this.registerComponentService.generateAdditionalConsentsFormControl?.()??this.fb.array([]),termsandconditions:[!1,F.requiredTrue],captcha:[!1,F.requiredTrue]},{validators:N.passwordsMustMatch("password","passwordconf")})}ngOnInit(){this.titles$=this.registerComponentService.getTitles().pipe(ge(n=>n.sort(ht))),this.subscription.add(this.globalMessageService.get().pipe(fe(n=>!!Object.keys(n).length)).subscribe(n=>{(n&&n[k.MSG_TYPE_ERROR])?.some(c=>
1c.raw==="This field is required.")&&(this.globalMessageService.remove(k.MSG_TYPE_ERROR),this.globalMessageService.add({key:"register.titleRequired"},k.MSG_TYPE_ERROR))}));let e=this.anonymousConsentsConfig?.anonymousConsents?.registerConsent??"";this.anonymousConsent$=Ye([this.anonymousConsentsService.getConsent(e),this.anonymousConsentsService.getTemplate(e)]).pipe(ge(([n,i])=>({consent:n,template:i?.description?i.description:""}))),this.additionalRegistrationConsents=this.registerComponentService?.getAdditionalConsents()||[],this.subscription.add(this.registerForm.get("newsletter").valueChanges.subscribe(()=>{this.toggleAnonymousConsent()}))}submitForm(){this.registerForm.valid?this.registerUser():this.registerForm.markAllAsTouched()}registerUser(){this.isLoading$.next(!0),this.registerComponentService.register(this.collectDataFromRegisterForm(this.registerForm.value)).subscribe({next:()=>this.onRegisterUserSuccess(),complete:()=>this.isLoading$.next(this.authConfigService.getOAuthFlow()===Je.AuthorizationCode),error:()=>this.isLoading$.next(!1)})}titleSelected(e){this.registerForm.controls.titleCode.setValue(e.code)}collectDataFromRegisterForm(e){return this.registerComponentService.collectDataFromRegisterForm(e)}isConsentGiven(e){return this.anonymousConsentsService.isConsentGiven(e)}isConsentRequired(){let e=this.anonymousConsentsConfig?.anonymousConsents?.requiredConsents,n=this.anonymousConsentsConfig?.anonymousConsents?.registerConsent;return e&&n?e.includes(n):!1}onRegisterUserSuccess(){this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")?this.router.go({cxRoute:"login"}):this.authConfigService.getOAuthFlow()===Je.ResourceOwnerPasswordFlow&&this.router.go("login"),this.registerComponentService.postRegisterMessage()}toggleAnonymousConsent(){let e=this.anonymousConsentsConfig?.anonymousConsents?.registerConsent;e&&(this.registerForm.get("newsletter").value?this.anonymousConsentsService.giveConsent(e):this.anonymousConsentsService.withdrawConsent(e))}captchaConfirmed(){this.registerForm.get("captcha")?.setValue(!0)}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(n){return new(n||t)(E(V),E(xe),E(q),E(lt),E(dt),E($e),E(He))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-register"]],hostAttrs:["ngSkipHydration","true"],decls:4,vars:4,consts:[["loading",""],["class","cx-page-section container",4,"ngIf","ngIfElse"],[1,"cx-page-section","container"],[1,"row","justify-content-center"],[1,"col-md-6"],[1,"cx-section"],[3,"ngSubmit","formGroup"],[1,"form-group"],[1,"label-content"],["bindLabel","name","bindValue","code","formControlName","titleCode","id","title-select",3,"clearable","items","placeholder","searchable","ariaLabelDropdown","cxNgSelectA11y"],["required","true","type","text","name","firstname","formControlName","firstName",1,"form-control",3,"placeholder"],["id","firstNameError",3,"translationParams","control"],["required","true","type","text","name","lastname","formControlName","lastName",1,"form-control",3,"placeholder"],["id","lastNameError",3,"translationParams","control"],["required","true","type","email","name","email","formControlName","email",1,"form-control",3,"placeholder"],["id","emailError",3,"translationParams","control"],["required","true","type","password","name","password","formControlName","password","aria-describedby","password-input-hint","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","password-input-hint",1,"input-hint"],[3,"translationParams","control"],["required","true","type","password","name","confirmpassword","formControlName","passwordconf","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","passwordconfError",3,"translationParams","control"],[1,"form-check"],[4,"ngIf"],["formArrayName","additionalConsents","class","form-group",4,"ngIf"],["required","true","type","checkbox","name","termsandconditions","formControlName","termsandconditions"],[1,"form-check-label"],["id","confirm-read-label"],["target","_blank","rel","noopener noreferrer","aria-describedby","confirm-read-label",3,"routerLink"],["id","termsandconditionsError",3,"translationParams","control"],[3,"confirmed"],[3,"control"],["type","submit",1,"btn","btn-block","btn-primary"],[1,"cx-login-link","btn-link",3,"routerLink"],["type","checkbox","name","newsletter","formControlName","newsletter",1,"form-check-input",3,"checked"],["formArrayName","additionalConsents",1,"form-group"],["class","form-check",3,"formGroupName",4,"ngFor","ngForOf"],[1,"form-check",3,"formGroupName"],["type","checkbox","formControlName","isConsentGranted",3,"change","required","name"],[1,"cx-spinner"]],template:function(n,i){if
1(n&1&&(v(0,en,99,134,"section",1),o(1,"async"),v(2,tn,2,0,"ng-template",null,0,Te)),n&2){let c=be(3);l("ngIf",!s(1,2,i.isLoading$))("ngIfElse",c)}},dependencies:[G,W,$,ie,Q,mt,z,K,oe,Ut,M,re,ne,qt,Lt,Ge,je,L,se,ke,Ae,st,Kt,J,H,pt,O],encapsulation:2})}}return t})(),br=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{RegisterCustomerComponent:{component:yi,guards:[Ue],providers:[{provide:He,useClass:He,deps:[Ne,V,xe]}]}}})],imports:[Jt,le,M,ce,_e,de,me,ue,L,W,tt,Ze,et,pe,yi]})}}return t})(),ei=(()=>{class t{constructor(e,n,i){this.userPasswordService=e,this.routingService=n,this.globalMessage=i,this.featureConfigService=S(Fe),this.passwordValidators=this.featureConfigService.isEnabled("useEnhancedSecurePasswordValidators")?[...N.securePasswordValidators,N.mustEndWithLegalCharacter]:N.securePasswordValidators,this.busy$=new X(!1),this.isUpdating$=this.busy$.pipe(he(c=>c===!0?this.form.disable():this.form.enable())),this.resetToken$=this.routingService.getRouterState().pipe(ge(c=>c.state.queryParams.token)),this.form=new Oe({password:new j("",[F.required,...this.passwordValidators]),passwordConfirm:new j("",F.required)},{validators:N.passwordsMustMatch("password","passwordConfirm")})}resetPassword(e){if(!this.form.valid){this.form.markAllAsTouched();return}this.busy$.next(!0);let n=this.form.get("password").value;this.userPasswordService.reset(e,n).subscribe({next:()=>this.onSuccess(),error:i=>this.onError(i)})}onSuccess(){this.globalMessage.add({key:"forgottenPassword.passwordResetSuccess"},k.MSG_TYPE_CONFIRMATION),this.busy$.next(!1),this.form.reset(),this.redirect()}onError(e){this.busy$.next(!1),e instanceof Mt&&(e.details??[]).forEach(n=>{n.message&&this.globalMessage.add({raw:n.message},k.MSG_TYPE_ERROR)})}redirect(){this.routingService.go({cxRoute:"login"})}static{this.\u0275fac=function(n){return new(n||t)(B(Ce),B(q),B(V))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})(),wi=(()=>{class t{constructor(e){this.service=e,this.form=this.service.form,this.isUpdating$=this.service.isUpdating$,this.token$=this.service.resetToken$}onSubmit(e){this.service.resetPassword(e)}static{this.\u0275fac=function(n){return new(n||t)(E(ei))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-reset-password"]],hostAttrs:["ngSkipHydration","true",1,"user-form"],decls:4,vars:6,consts:[["class","overlay",4,"ngIf"],[3,"formGroup","ngSubmit",4,"ngIf"],[1,"overlay"],[3,"ngSubmit","formGroup"],[1,"label-content"],["required","true","type","password","formControlName","password","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","passwordError",3,"translationParams","control"],["required","true","type","password","formControlName","passwordConfirm","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","passwordConfirmError",3,"translationParams","control"],[1,"btn","btn-block","btn-primary",3,"disabled"]],template:function(n,i){n&1&&(v(0,nn,1,0,"cx-spinner",0),o(1,"async"),v(2,rn,25,41,"form",1),o(3,"async")),n&2&&(l("ngIf",s(1,2,i.isUpdating$)),r(2),l("ngIf",s(3,4,i.token$)))},dependencies:[G,J,$,ie,Q,z,K,oe,M,re,ne,W,L,ke,se,H,O],encapsulation:2,changeDetection:0})}}return t})(),yr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{ResetPasswordComponent:{component:wi,guards:[Ue],providers:[{provide:ei,useClass:ei,deps:[Ce,q,V]}]}}})],imports:[le,$,M,ce,de,ue,me,et,pe,L,W,wi]})}}return t})(),_t=(()=>{class t{constructor(e,n,i,c,g){this.userEmail=e,this.routingService=n,this.globalMessageService=i,this.authService=c,this.authRedirectService=g,this.busy$=new X(!1),this.updateSucceed$=new yt,this.isUpdating$=this.busy$.pipe(he(_=>_===!0?this.form.disable():this.form.enable())),this.form=new Oe({email:new j("",[F.required,N.emailValidator]),confirmEmail:new j("",[F.required]),password:new j("",[F.required])},{validators:N.emailsMustMatch("email","confirmEmail")})}save(){if(!this.form.valid){this.form.markAllAsTouched();return}this.busy$.next(!0);let e=this.form.get("confirmEmail")?.value,n=this.form.get("password")?.value;this.userEmail.update(n,e).subscribe({next:()=>this.onSuccess(e),error:i=>this.onError(i)})}onSuccess(e){this.globalMessageService.add({key:"updateEmailForm.emailUpdateSuccess",params:{newUid:e}},k.MSG_TYPE_CONFIRMATION),this.busy$.next(!1),this.form.reset(),this.updateSucceed$.next(!0),this.authRedirectService.setRedirectUrl(this.routingService.getUrl({cxRoute:"home"})),this.authService.coreLogout().then(()=>{this.routingService.go({cxRoute:"login"},{state:{newUid:e}})})}onError(e){this.busy$.next(!1),this.updateSucceed$.next(!1)}static{this.\u0275fac=function(n){return new(n||t)(B(vt),B(q),B(V),B(Ee),B(qe))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})(),Si=(()=>{class t{constructor(e){this.service=e,this.form=this.service.form,this.isUpdating$=this.service.isUpdating$}onSubmit(){this.service.save()}static{this.\u0275fac=function(n){return new(n||t)(E(_t))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-update-email"]],hostAttrs:["ngSkipHydration","true",1,"user-form"],decls:39,vars:62,consts:[["class","overlay",4,"ngIf"],[3,"ngSubmit","formGroup"],[1,"label-content"],["required","true","type","email","name","email","formControlName","email",1,"form-control",3,"placeholder"],["id","emailError",3,"translationParams","control"],["required","true","type","email","name","confirmEmail","formControlName","confirmEmail",1,"form-control",3,"placeholder"],["id","confirmEmailError",3,"translationParams","control"],["required","true","type","password","name","password","formControlName","password","autocomplete","new-password","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","passwordError",3,"translationParams","control"],["cxBtnLikeLink","",1,"btn","btn-block","btn-secondary",3,"routerLink"],[1,"btn","btn-block","btn-primary",3,"disabled"],[1,"overlay"]],template:function(n,i){if
1(n&1&&(v(0,sn,1,0,"cx-spinner",0),o(1,"async"),p(2,"cx-form-required-legend"),d(3,"form",1),b("ngSubmit",function(){return i.onSubmit()}),d(4,"label")(5,"span",2),m(6),o(7,"cxTranslate"),p(8,"cx-form-required-asterisks"),a(),p(9,"input",3),o(10,"cxTranslate"),p(11,"cx-form-errors",4),o(12,"cxTranslate"),a(),d(13,"label")(14,"span",2),m(15),o(16,"cxTranslate"),p(17,"cx-form-required-asterisks"),a(),p(18,"input",5),o(19,"cxTranslate"),p(20,"cx-form-errors",6),o(21,"cxTranslate"),a(),d(22,"label")(23,"span",2),m(24),o(25,"cxTranslate"),p(26,"cx-form-required-asterisks"),a(),p(27,"input",7),o(28,"cxTranslate"),o(29,"cxTranslate"),p(30,"cx-form-errors",8),o(31,"cxTranslate"),a(),d(32,"a",9),o(33,"cxUrl"),m(34),o(35,"cxTranslate"),a(),d(36,"button",10),m(37),o(38,"cxTranslate"),a()()),n&2){let c,g;l("ngIf",s(1,27,i.isUpdating$)),r(3),l("formGroup",i.form),r(3),f("",s(7,29,"updateEmailForm.newEmailAddress.label")," "),r(3),l("placeholder",x(s(10,31,"updateEmailForm.newEmailAddress.placeholder"))),A("aria-invalid",((c=i.form.get("email"))==null?null:c.touched)&&((c=i.form.get("email"))==null?null:c.invalid))("aria-errormessage","emailError"),r(2),l("translationParams",C(55,T,s(12,33,"updateEmailForm.newEmailAddress.label")))("control",i.form.get("email")),r(4),f("",s(16,35,"updateEmailForm.confirmNewEmailAddress.label")," "),r(3),l("placeholder",x(s(19,37,"updateEmailForm.confirmNewEmailAddress.placeholder"))),A("aria-invalid",((g=i.form.get("confirmEmail"))==null?null:g.touched)&&((g=i.form.get("confirmEmail"))==null?null:g.invalid))("aria-errormessage","confirmEmailError"),r(2),l("translationParams",C(57,T,s(21,39,"updateEmailForm.confirmNewEmailAddress.label")))("control",i.form.get("confirmEmail")),r(4),f("",s(25,41,"updateEmailForm.password.label")," "),r(3),l("placeholder",x(s(28,43,"updateEmailForm.password.placeholder"))),A("aria-label",s(29,45,"updateEmailForm.password.placeholder"))("aria-describedby","passwordError"),r(3),l("translationParams",C(59,T,s(31,47,"updateEmailForm.password.label")))("control",i.form.get("password")),r(2),l("routerLink",s(33,49,Y(61,on))),r(2),f(" ",s(35,51,"common.cancel")," "),r(2),l("disabled",i.form.disabled),r(),f(" ",s(38,53,"common.save")," ")}},dependencies:[G,J,W,$,ie,Q,z,K,oe,M,re,ne,L,se,ke,vi,st,H,pt,O],encapsulation:2,changeDetection:0})}}return t})(),Mi=(()=>{class t{constructor(){this.emailComponentService=S(_t),this.userProfile=S(Be),this.form=this.emailComponentService.form,this.isUpdating$=this.emailComponentService.isUpdating$,this.user$=this.userProfile.get().pipe(fe(e=>!!e)),this.globalMessageType=k}ngOnInit(){this.isEditing=!1}onSubmit(){this.emailComponentService.save(),this.emailComponentService.updateSucceed$.subscribe(e=>{this.isEditing=!e})}onEdit(){this.isEditing=!0,this.showingAlert=!0,this.form.reset()}cancelEdit(){this.isEditing=!1}closeDialogConfirmationAlert(){this.showingAlert=!1}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=U({type:t,selectors:[["cx-my-account-v2-email"]],hostAttrs:["ngSkipHydration","true"],decls:13,vars:12,consts:[["class","overlay",4,"ngIf$","ngIf"],[1,"flex-line"],[1,"headertext"],["class","editButton",3,"click",4,"ngIf"],[4,"ngIf"],[3,"text","type","closeMessage",4,"ngIf"],["class","email-editing-area",4,"ngIf"],[1,"overlay"],[1,"editButton",3,"click"],[1,"text-head"],[1,"value"],[3,"closeMessage","text","type"],[1,"email-editing-area"],[3,"ngSubmit","formGroup"],["type","text","readonly","",1,"form-control",3,"value"],["required","true","type","email","name","email","formControlName","email",1,"form-control",3,"placeholder"],["id","emailError",3,"translationParams","control"],["required","true","type","email","name","confirmEmail","formControlName","confirmEmail",1,"form-control",3,"placeholder"],["id","confirmEmailError",3,"translationParams","control"],[1,"label-content,","text-head"],["required","true","type","password","name","password","formControlName","password","autocomplete","new-password","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","passwordError",3,"translationParams","control"],[1,"btn-group"],[1,"btn","button-cancel","button",3,"click"],[1,"btn","btn-primary","button",3,"click","disabled"]],template:function(n,i){n&1&&(v(0,an,1,0,"cx-spinner",0),o(1,"async"),o(2,"async"),d(3,"div")(4,"div",1)(5,"label",2),m(6),o(7,"cxTranslate"),a(),v(8,ln,3,3,"button",3),a(),d(9,"div"),v(10,dn,8,6,"div",4),a(),v(11,cn,2,4,"cx-message",5)(12,pn,40,62,"div",6),a()),n&2&&(l("ngIf",s(1,6,i.isUpdating$)||!s(2,8,i.user$)),r(6),f("",s(7,10,"myAccountV2Email.myEmailAddress")," "),r(2),l("ngIf",!i.isEditing),r(2),l("ngIf",!i.isEditing),r(),l("ngIf",i.isEditing&&i.showingAlert),r(),l("ngIf",i.isEditing))},dependencies:[G,J,Yt,$,ie,Q,z,K,oe,M,re,ne,se,ke,H,O],encapsulation:2,changeDetection:0})}}return t})(),wr=new rt("feature flag to enable enhanced UI for email related pages under My-Account",{providedIn:"root",factory:()=>!1}),Sr={cmsComponents:{UpdateEmailComponent:{component:Mi}}},Tr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{UpdateEmailComponent:{component:Si,guards:[Le],providers:[{provide:_t,useClass:_t,deps:[vt,q,V,Ee,qe]}]}}}),at(()=>S(wr)?Sr:{})],imports:[le,$,M,me,_e,ce,de,ue,et,pe,zt,Pe,L,W,Si,Mi]})}}return t})(),Di=new rt("feature flag to enable enhanced UI for Update Password related pages under My-Account",{providedIn:"root",factory:()=>!1}),xt=(()=>{class t{constructor(e,n,i,c,g){this.userPasswordService=e,this.routingService=n,this.globalMessageService=i,this.authRedirectService=c,this.authService=g,this.featureConfigService=S(Fe),this.passwordValidators=this.featureConfigService.isEnabled("useEnhancedSecurePasswordValidators")?[...N.securePasswordValidators,N.mustEndWithLegalCharacter]:N.securePasswordValidators,this.busy$=new X(!1),this.usingV2=S(Di),this.isUpdating$=this.busy$.pipe(he(_=>_===!0?this.form.disable():this.form.enable())),this.form=new Oe({oldPassword:new j("",F.required),newPassword:new j("",[F.required,...this.passwordValidators]),newPasswordConfirm:new j("",F.required)},{validators:this.getPasswordValidators()})}updatePassword(){if(!this.form.valid){this.form.markAllAsTouched();return}this.busy$.next(!0);let e=this.form.get("oldPassword")?.value,n=this.form.get("newPassword")?.value;this.userPasswordService.update(e,n).subscribe({next:()=>this.onSuccess(),error:i=>this.onError(i)})}onSuccess(){this.globalMessageService.add({key:this.usingV2?"myAccountV2PasswordForm.passwordUpdateSuccess":"updatePasswordForm.passwordUpdateSuccess"},k.MSG_TYPE_CONFIRMATION),this.busy$.next(!1),this.form.reset(),this.authRedirectService?.setRedirectUrl(this.routingService.getUrl({cxRoute:"home"})),this.authService?.coreLogout().then(()=>{this.routingService.go({cxRoute:"login"})})}onError(e){e instanceof Mt&&e.details?.[0].type==="AccessDeniedError"&&this.globalMessageService.add({key:this.usingV2?"myAccountV2PasswordForm.accessDeniedError":"updatePasswordForm.accessDeniedError"},k.MSG_TYPE_ERROR),this.busy$.next(!1),this.form.reset()}getPasswordValidators(){return[N.passwordsMustMatch("newPassword","newPasswordConfirm"),N.passwordsCannotMatch("oldPassword","newPassword")]}static{this.\u0275fac=function(n){return new(n||t)(B(Ce),B(q),B(V),B(qe),B(Ee))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})(),Ti=(()=>{class t{constructor(e){this.service=e,this.routingService=S(q,{optional:!0}),this.form=this.service.form,this.isUpdating$=this.service.isUpdating$}onSubmit(){this.service.updatePassword()}navigateTo(e){this.routingService?.go({cxRoute:e})}static{this.\u0275fac=function(n){return new(n||t)(E(xt))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-update-password"]],hostAttrs:["ngSkipHydration","true",1,"user-form"],decls:40,vars:65,consts:[["class","overlay",4,"ngIf"],[3,"ngSubmit","formGroup"],[1,"label-content"],["required","true","type","password","name","oldPassword","formControlName","oldPassword","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","oldPasswordError",3,"translationParams","control"],["required","true","type","password","name","newPassword","formControlName","newPassword","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","newPasswordError",3,"translationParams","control"],["required","true","type","password","name","newPasswordConfirm","formControlName","newPasswordConfirm","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","newPasswordConfirmError",3,"translationParams","control"],[1,"btn","btn-block","btn-secondary",3,"click"],[1,"btn","btn-block","btn-primary",3,"disabled"],[1,"overlay"]],template:function(n,i){if
1(n&1&&(v(0,mn,1,0,"cx-spinner",0),o(1,"async"),p(2,"cx-form-required-legend"),d(3,"form",1),b("ngSubmit",function(){return i.onSubmit()}),d(4,"label")(5,"span",2),m(6),o(7,"cxTranslate"),p(8,"cx-form-required-asterisks"),a(),p(9,"input",3),o(10,"cxTranslate"),o(11,"cxTranslate"),p(12,"cx-form-errors",4),o(13,"cxTranslate"),a(),d(14,"label")(15,"span",2),m(16),o(17,"cxTranslate"),p(18,"cx-form-required-asterisks"),a(),p(19,"input",5),o(20,"cxTranslate"),o(21,"cxTranslate"),p(22,"cx-form-errors",6),o(23,"cxTranslate"),a(),d(24,"label")(25,"span",2),m(26),o(27,"cxTranslate"),p(28,"cx-form-required-asterisks"),a(),p(29,"input",7),o(30,"cxTranslate"),o(31,"cxTranslate"),p(32,"cx-form-errors",8),o(33,"cxTranslate"),a(),d(34,"button",9),b("click",function(){return i.navigateTo("home")}),m(35),o(36,"cxTranslate"),a(),d(37,"button",10),m(38),o(39,"cxTranslate"),a()()),n&2){let c,g,_;l("ngIf",s(1,29,i.isUpdating$)),r(3),l("formGroup",i.form),r(3),f("",s(7,31,"updatePasswordForm.oldPassword.label")," "),r(3),l("placeholder",x(s(10,33,"updatePasswordForm.oldPassword.placeholder"))),A("aria-label",s(11,35,"updatePasswordForm.oldPassword.placeholder"))("aria-invalid",((c=i.form.get("oldPassword"))==null?null:c.touched)&&((c=i.form.get("oldPassword"))==null?null:c.invalid))("aria-errormessage","oldPasswordError"),r(3),l("translationParams",C(59,T,s(13,37,"updatePasswordForm.oldPassword.label")))("control",i.form.get("oldPassword")),r(4),f("",s(17,39,"updatePasswordForm.newPassword.label")," "),r(3),l("placeholder",x(s(20,41,"updatePasswordForm.newPassword.placeholder"))),A("aria-label",s(21,43,"updatePasswordForm.newPassword.placeholder"))("aria-invalid",((g=i.form.get("newPassword"))==null?null:g.touched)&&((g=i.form.get("newPassword"))==null?null:g.invalid))("aria-errormessage","newPasswordError"),r(3),l("translationParams",C(61,T,s(23,45,"updatePasswordForm.newPassword.label")))("control",i.form.get("newPassword")),r(4),f("",s(27,47,"updatePasswordForm.confirmPassword.label")," "),r(3),l("placeholder",x(s(30,49,"updatePasswordForm.confirmPassword.placeholder"))),A("aria-label",s(31,51,"updatePasswordForm.confirmPassword.placeholder"))("aria-invalid",((_=i.form.get("newPasswordConfirm"))==null?null:_.touched)&&((_=i.form.get("newPasswordConfirm"))==null?null:_.invalid))("aria-errormessage","newPasswordConfirmError"),r(3),l("translationParams",C(63,T,s(33,53,"updatePasswordForm.confirmPassword.label")))("control",i.form.get("newPasswordConfirm")),r(3),f(" ",s(36,55,"common.cancel")," "),r(2),l("disabled",i.form.disabled),r(),f(" ",s(39,57,"common.save")," ")}},dependencies:[G,J,W,$,ie,Q,z,K,oe,M,re,ne,L,ke,se,H,O],encapsulation:2,changeDetection:0})}}return t})(),Ri=(()=>{class t{constructor(){this.service=S(xt),this.showingAlert=!0,this.globalMessageType=k,this.form=this.service.form,this.isUpdating$=this.service.isUpdating$}onSubmit(){this.service.updatePassword()}onCancel(){this.oldPassword="",this.newPassword="",this.newPasswordConfirm=""}closeDialogConfirmationAlert(){this.showingAlert=!1}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=U({type:t,selectors:[["cx-my-account-v2-password"]],hostAttrs:["ngSkipHydration","true"],decls:41,vars:72,consts:[["class","overlay",4,"ngIf"],[3,"ngSubmit","formGroup"],[1,"myaccount-password-header"],[3,"text","type","closeMessage",4,"ngIf"],[1,"myaccount-label-padding"],[1,"label-content","myaccount-password-label"],["required","true","type","password","name","oldPassword","formControlName","oldPassword","cxPasswordVisibilitySwitch","",1,"form-control",3,"ngModelChange","ngModel","placeholder"],["id","oldPasswordError",3,"translationParams","control"],["required","true","type","password","name","newPassword","formControlName","newPassword","cxPasswordVisibilitySwitch","",1,"form-control",3,"ngModelChange","ngModel","placeholder"],["id","newPasswordError",3,"translationParams","control"],["required","true","type","password","name","newPasswordConfirm","formControlName","newPasswordConfirm","cxPasswordVisibilitySwitch","",1,"form-control",3,"ngModelChange","ngModel","placeholder"],["id","newPasswordConfirmError",3,"translationParams","control"],[1,"password-btn-group"],[1,"btn","myaccount-password-button","myaccount-password-button-cancel",3,"click"],[1,"btn","btn-primary","myaccount-password-button",3,"disabled"],[1,"overlay"],[3,"closeMessage","text","type"]],template:function(n,i){if
1(n&1&&(v(0,un,1,0,"cx-spinner",0),o(1,"async"),d(2,"form",1),b("ngSubmit",function(){return i.onSubmit()}),d(3,"label",2),m(4),o(5,"cxTranslate"),a(),v(6,gn,2,4,"cx-message",3),d(7,"label",4)(8,"span",5),m(9),o(10,"cxTranslate"),a(),d(11,"input",6),o(12,"cxTranslate"),o(13,"cxTranslate"),Se("ngModelChange",function(g){return we(i.oldPassword,g)||(i.oldPassword=g),g}),a(),p(14,"cx-form-errors",7),o(15,"cxTranslate"),a(),d(16,"label",4)(17,"span",5),m(18),o(19,"cxTranslate"),a(),d(20,"input",8),o(21,"cxTranslate"),o(22,"cxTranslate"),Se("ngModelChange",function(g){return we(i.newPassword,g)||(i.newPassword=g),g}),a(),p(23,"cx-form-errors",9),o(24,"cxTranslate"),a(),d(25,"label",4)(26,"span",5),m(27),o(28,"cxTranslate"),a(),d(29,"input",10),o(30,"cxTranslate"),o(31,"cxTranslate"),Se("ngModelChange",function(g){return we(i.newPasswordConfirm,g)||(i.newPasswordConfirm=g),g}),a(),p(32,"cx-form-errors",11),o(33,"cxTranslate"),a(),d(34,"div",12)(35,"button",13),b("click",function(){return i.onCancel()}),m(36),o(37,"cxTranslate"),a(),d(38,"button",14),m(39),o(40,"cxTranslate"),a()()()),n&2){let c,g,_;l("ngIf",s(1,34,i.isUpdating$)),r(2),l("formGroup",i.form),r(2),f("",s(5,36,"myAccountV2PasswordForm.newPasswordTitle")," "),r(2),l("ngIf",i.showingAlert),r(3),I(s(10,38,"myAccountV2PasswordForm.oldPassword.label")),r(2),l("placeholder",x(s(12,40,"myAccountV2PasswordForm.oldPassword.placeholder"))),ye("ngModel",i.oldPassword),A("aria-label",s(13,42,"myAccountV2PasswordForm.oldPassword.placeholder"))("aria-invalid",((c=i.form.get("oldPassword"))==null?null:c.touched)&&((c=i.form.get("oldPassword"))==null?null:c.invalid))("aria-errormessage","oldPasswordError"),r(3),l("translationParams",C(66,T,s(15,44,"updatePasswordForm.oldPassword.label")))("control",i.form.get("oldPassword")),r(4),I(s(19,46,"myAccountV2PasswordForm.newPassword.label")),r(2),l("placeholder",x(s(21,48,"myAccountV2PasswordForm.newPassword.placeholder"))),ye("ngModel",i.newPassword),A("aria-label",s(22,50,"myAccountV2PasswordForm.newPassword.placeholder"))("aria-invalid",((g=i.form.get("newPassword"))==null?null:g.touched)&&((g=i.form.get("newPassword"))==null?null:g.invalid))("aria-errormessage","newPasswordError"),r(3),l("translationParams",C(68,T,s(24,52,"updatePasswordForm.newPassword.label")))("control",i.form.get("newPassword")),r(4),I(s(28,54,"myAccountV2PasswordForm.confirmPassword.label")),r(2),l("placeholder",x(s(30,56,"myAccountV2PasswordForm.confirmPassword.placeholder"))),ye("ngModel",i.newPasswordConfirm),A("aria-label",s(31,58,"myAccountV2PasswordForm.confirmPassword.placeholder"))("aria-invalid",((_=i.form.get("newPasswordConfirm"))==null?null:_.touched)&&((_=i.form.get("newPasswordConfirm"))==null?null:_.invalid))("aria-errormessage","newPasswordConfirmError"),r(3),l("translationParams",C(70,T,s(33,60,"updatePasswordForm.confirmPassword.label")))("control",i.form.get("newPasswordConfirm")),r(4),f(" ",s(37,62,"common.cancel")," "),r(2),l("disabled",i.form.disabled),r(),f(" ",s(40,64,"common.save")," ")}},dependencies:[G,J,$,ie,Q,z,K,oe,M,re,ne,Yt,ke,se,H,O],encapsulation:2,changeDetection:0})}}return t})(),Ar={cmsComponents:{UpdatePasswordComponent:{component:Ri}}},Fr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{UpdatePasswordComponent:{component:Ti,guards:[Le],providers:[{provide:xt,useClass:xt,deps:[Ce,q,V,qe,Ee]}]}}}),at(()=>S(Di)?Ar:{})],imports:[le,$,M,me,de,ue,_e,ce,et,pe,zt,Pe,L,W,Ti,Ri]})}}return t})(),Ct=(()=>{class t{constructor(e,n){this.userProfile=e,this.globalMessageService=n,this.user$=this.userProfile.get().pipe(fe(i=>!!i)),this.busy$=new X(!1),this.updateSucceed$=new yt,this.isUpdating$=this.user$.pipe(he(i=>this.form.patchValue(i)),Qe(i=>this.busy$),he(i=>i===!0?this.form.disable():this.form.enable())),this.titles$=this.userProfile.getTitles(),this.form=new Oe({customerId:new j(""),titleCode:new j(""),firstName:new j("",F.required),lastName:new j("",F.required)})}updateProfile(){if(!this.form.valid){this.form.markAllAsTouched();return}this.busy$.next(!0),this.userProfile.update(this.form.value).subscribe({next:()=>this.onSuccess(),error:e=>this.onError(e)})}onSuccess(){this.globalMessageService.add({key:"updateProfileForm.profileUpdateSuccess"},k.MSG_TYPE_CONFIRMATION),this.busy$.next(!1),this.form.reset(),this.updateSucceed$.next(!0)}onError(e){this.busy$.next(!1),this.updateSucceed$.next(!1)}static{this.\u0275fac=function(n){return new(n||t)(B(Be),B(V))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})(),Ai=(()=>{class t{constructor(e){this.service=e,this.routingService=S(q,{optional:!0}),this.form=this.service.form,this.isUpdating$=this.service.isUpdating$,this.titles$=this.service.titles$}onSubmit(){this.service.updateProfile()}navigateTo(e){this.routingService?.go({cxRoute:e})}static{this.\u0275fac=function(n){return new(n||t)(E(Ct))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-update-profile"]],hostAttrs:[1,"user-form"],decls:45,vars:70,consts:[["class","overlay",4,"ngIf"],[3,"ngSubmit","formGroup"],[1,"label-content"],["formControlName","titleCode","id","title-select",3,"clearable","searchable","ariaLabelDropdown","cxNgSelectA11y"],[3,"value",4,"ngFor","ngForOf"],["required","true","type","text","name","firstName","formControlName","firstName",1,"form-control",3,"placeholder"],["id","firstNameError",3,"translationParams","control"],["required","true","type","text","name","lastName","formControlName","lastName",1,"form-control",3,"placeholder"],["id","lastNameError",3,"translationParams","control"],[4,"cxFeature"],["required","true","type","text","name","customerId","formControlName","customerId","cxTruncationTooltip","","readonly","",1,"form-control"],["id","customerIdError",3,"translationParams","control"],["type","button",1,"btn","btn-block","btn-secondary",3,"click"],[1,"btn","btn-block","btn-primary",3,"disabled"],[1,"overlay"],[3,"value"]],template:function(n,i){if
1(n&1&&(v(0,fn,1,0,"cx-spinner",0),o(1,"async"),p(2,"cx-form-required-legend"),d(3,"form",1),b("ngSubmit",function(){return i.onSubmit()}),d(4,"label")(5,"span",2),m(6),o(7,"cxTranslate"),a(),d(8,"ng-select",3),o(9,"cxTranslate"),o(10,"cxTranslate"),v(11,hn,2,2,"ng-option",4),o(12,"async"),a()(),d(13,"label")(14,"span",2),m(15),o(16,"cxTranslate"),p(17,"cx-form-required-asterisks"),a(),p(18,"input",5),o(19,"cxTranslate"),p(20,"cx-form-errors",6),o(21,"cxTranslate"),a(),d(22,"label")(23,"span",2),m(24),o(25,"cxTranslate"),p(26,"cx-form-required-asterisks"),a(),p(27,"input",7),o(28,"cxTranslate"),p(29,"cx-form-errors",8),o(30,"cxTranslate"),a(),d(31,"label")(32,"span",2),m(33),o(34,"cxTranslate"),v(35,vn,1,0,"cx-form-required-asterisks",9),a(),p(36,"input",10)(37,"cx-form-errors",11),o(38,"cxTranslate"),a(),d(39,"button",12),b("click",function(){return i.navigateTo("home")}),m(40),o(41,"cxTranslate"),a(),d(42,"button",13),m(43),o(44,"cxTranslate"),a()()),n&2){let c,g,_;l("ngIf",s(1,32,i.isUpdating$)),r(3),l("formGroup",i.form),r(3),I(s(7,34,"updateProfileForm.title")),r(2),l("ariaLabelDropdown",x(s(9,36,"common.ngSelectDropdownOptionsList")))("clearable",!1)("searchable",!1)("cxNgSelectA11y",C(62,Ve,s(10,38,"updateProfileForm.title"))),r(3),l("ngForOf",s(12,40,i.titles$)),r(4),f("",s(16,42,"updateProfileForm.firstName.label")," "),r(3),l("placeholder",x(s(19,44,"updateProfileForm.firstName.placeholder"))),A("aria-invalid",((c=i.form.get("firstName"))==null?null:c.touched)&&((c=i.form.get("firstName"))==null?null:c.invalid))("aria-errormessage","firstNameError"),r(2),l("translationParams",C(64,T,s(21,46,"updateProfileForm.firstName.label")))("control",i.form.get("firstName")),r(4),f("",s(25,48,"updateProfileForm.lastName.label")," "),r(3),l("placeholder",x(s(28,50,"updateProfileForm.lastName.placeholder"))),A("aria-invalid",((g=i.form.get("lastName"))==null?null:g.touched)&&((g=i.form.get("lastName"))==null?null:g.invalid))("aria-errormessage","lastNameError"),r(2),l("translationParams",C(66,T,s(30,52,"updateProfileForm.lastName.label")))("control",i.form.get("lastName")),r(4),f("",s(34,54,"updateProfileForm.customerId")," "),r(2),l("cxFeature","showRequiredAsterisks"),r(),A("aria-invalid",((_=i.form.get("customerId"))==null?null:_.touched)&&((_=i.form.get("customerId"))==null?null:_.invalid))("aria-errormessage","customerIdError"),r(),l("translationParams",C(68,T,s(38,56,"updateProfileForm.customerId")))("control",i.form.get("customerId")),r(3),f(" ",s(41,58,"common.cancel")," "),r(2),l("disabled",i.form.disabled),r(),f(" ",s(44,60,"common.save")," ")}},dependencies:[G,J,W,$,ie,Q,z,K,oe,M,re,ne,Ge,je,Ae,Ot,L,se,Dt,Qt,H,O],encapsulation:2,changeDetection:0})}}return t})(),$i=(()=>{class t{constructor(){this.service=S(Ct),this.form=this.service.form,this.isUpdating$=this.service.isUpdating$,this.titles$=this.service.titles$,this.user$=this.service.user$}ngOnInit(){this.isEditing=!1}onSubmit(){this.service.updateProfile(),this.service.updateSucceed$.subscribe(e=>{this.isEditing=!e})}cancelEdit(){this.isEditing=!1,this.form.setValue(this.originalEditValue)}onEdit(){this.isEditing=!0,this.originalEditValue=this.form.value}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=U({type:t,selectors:[["cx-my-account-v2-profile"]],decls:12,vars:11,consts:[["class","overlay",4,"ngIf"],[1,"flex-line"],[1,"headertext"],["class","editButton",3,"click",4,"ngIf"],[4,"ngIf"],["class","myaccount-editing-area",4,"ngIf"],[1,"overlay"],[1,"editButton",3,"click"],[1,"text-head"],[1,"value"],[1,"myaccount-editing-area"],[3,"ngSubmit","formGroup"],[1,"label-content,","text-head"],["formControlName","titleCode","id","title-select",3,"clearable","searchable","ariaLabelDropdown","cxNgSelectA11y"],[3,"value",4,"ngFor","ngForOf"],["required","true","type","text","name","firstName","formControlName","firstName",1,"form-control"],["id","firstNameError",3,"translationParams","control"],["required","true","type","text","name","lastName","formControlName","lastName",1,"form-control"],["id","lastNameError",3,"translationParams","control"],["required","true","type","text","name","customerId","formControlName","customerId","cxTruncationTooltip","","readonly","",1,"form-control"],["id","customerIdError",3,"translationParams","control"],[1,"btn-group"],[1,"btn","button-cancel","button",3,"click"],[1,"btn","btn-primary","button",3,"click","disabled"],[3,"value"]],template:function(n,i){n&1&&(v(0,_n,1,0,"cx-spinner",0),o(1,"async"),o(2,"async"),d(3,"div")(4,"div")(5,"div",1)(6,"label",2),m(7),o(8,"cxTranslate"),a(),v(9,xn,3,3,"button",3),a()(),v(10,Cn,23,21,"div",4)(11,yn,39,58,"div",5),a()),n&2&&(l("ngIf",s(1,5,i.isUpdating$)||!s(2,7,i.user$)),r(7),f("",s(8,9,"myAccountV2UserProfile.myInformation")," "),r(2),l("ngIf",!i.isEditing),r(),l("ngIf",!i.isEditing),r(),l("ngIf",i.isEditing))},dependencies:[G,J,$,ie,Q,z,K,oe,M,re,ne,Ge,je,Ae,Ot,se,Qt,H,O],encapsulation:2,changeDetection:0})}}return t})(),Er=new rt("feature flag to enable enhanced UI for profile related pages under My-Account",{providedIn:"root",factory:()=>!1}),Ir={cmsComponents:{UpdateProfileComponent:{component:$i}}},Pr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{UpdateProfileComponent:{component:Ai,guards:[Le],providers:[{provide:Ct,useClass:Ct,deps:[Be,V]}]}}}),at(()=>S(Er)?Ir:{})],imports:[le,$,M,me,de,ue,ce,_e,Ze,tt,pe,Pe,L,W,Ai,$i]})}}return t})(),qi=(()=>{class t{constructor(e,n,i,c,g,_){this.fb=e,this.userAddressService=n,this.globalMessageService=i,this.translation=c,this.launchDialogService=g,this.userProfileFacade=_,this.languageService=S(Rt),this.cdr=S(Vt),this.featureConfigService=S(Fe),this.hierarchicalAddressConfig=S($t),this.selectedCountry$=new X(""),this.selectedRegion$=new X(""),this.selectedCity$=ne
1w X(""),this.isHierarchicalAddressFormat=!1,this.cities=[],this.districts=[],this.setAsDefaultField=!0,this.showCancelBtn=!0,this.submitAddress=new Et,this.backToAddress=new Et,this.subscription=new We,this.addressForm=this.fb.group({country:this.fb.group({isocode:[null,F.required]}),titleCode:[""],firstName:["",F.required],lastName:["",F.required],line1:["",F.required],line2:[""],town:["",F.required],region:this.fb.group({isocode:[null,F.required]}),district:[null],postalCode:["",F.required],phone:"",cellphone:"",defaultAddress:[!1]})}ngOnInit(){this.countries$=this.countries||this.userAddressService.getDeliveryCountries().pipe(he(e=>{Object.keys(e).length===0&&this.userAddressService.loadDeliveryCountries()})),this.titles$=this.getTitles(),this.regions$=this.selectedCountry$.pipe(Qe(e=>this.userAddressService.getRegions(e)),he(e=>{let n=this.addressForm.get("region.isocode");e&&e.length>0?n?.enable():n?.disable()})),this.addressData&&Object.keys(this.addressData).length!==0&&(this.featureConfigService.isEnabled("enableHierarchicalAddressFormat")?(this.countrySelected(this.addressData.country),this.addressForm.patchValue(this.addressData)):(this.addressForm.patchValue(this.addressData),this.countrySelected(this.addressData.country)),this.addressData.region&&this.regionSelected(this.addressData.region)),this.addresses$=this.userAddressService.getAddresses(),this.featureConfigService.isEnabled("enableHierarchicalAddressFormat")&&(this.initCitiesSubscription(),this.initDistrictsSubscription(),this.initLanguageSubscription())}initCitiesSubscription(){this.subscription.add(this.selectedRegion$.pipe(Qe(e=>!this.isHierarchicalAddressFormat||!e?wt([]):this.userAddressService.getCities(e))).subscribe(e=>{this.cities=e;let n=this.addressForm.get("town");this.isHierarchicalAddressFormat&&!this.selectedRegion$.value?n?.disable():n?.enable(),this.addressData?.city?.isocode&&!this.selectedCity$.value&&this.selectedRegion$.value===this.addressData.region?.isocode&&(this.selectedCity$.next(this.addressData.city.isocode),this.addressForm.get("town")?.setValue(this.addressData.city.isocode)),this.cdr.markForCheck()}))}initDistrictsSubscription(){this.subscription.add(this.selectedCity$.pipe(Qe(e=>this.isHierarchicalAddressFormat?this.userAddressService.getDistricts(e):wt([]))).subscribe(e=>
1{this.districts=e,this.addressData?.cityDistrict?.isocode&&this.selectedCity$.value===this.addressData.city?.isocode&&this.addressForm.get("district")?.setValue(this.addressData.cityDistrict.isocode),this.cdr.markForCheck()}))}initLanguageSubscription(){this.subscription.add(this.languageService.getActive().pipe(At(1)).subscribe(()=>{this.isHierarchicalAddressFormat&&(this.userAddressService.clearRegions(),this.selectedRegion$.value&&this.userAddressService.clearCities(),this.selectedCity$.value&&this.userAddressService.clearDistricts())}))}getTitles(){return Ye([this.translation.translate("addressForm.defaultTitle"),this.userProfileFacade.getTitles()]).pipe(ge(([e,n])=>{let i={code:"",name:e};return n.sort(ht),[i,...n]}))}handleAddressVerificationResults(e){e.decision==="ACCEPT"?this.submitAddress.emit(this.addressForm.value):e.decision==="REJECT"?e.errors?.errors.some(n=>n.subject==="titleCode")?this.globalMessageService.add({key:"addressForm.titleRequired"},k.MSG_TYPE_ERROR):this.globalMessageService.add({key:"addressForm.invalidAddress"},k.MSG_TYPE_ERROR):e.decision==="REVIEW"&&this.openSuggestedAddress(e)}countrySelected(e){if(this.addressForm.get("country")?.get("isocode")?.setValue(e?.isocode),this.selectedCountry$.next(e?.isocode??""),!this.featureConfigService.isEnabled("enableHierarchicalAddressFormat"))return;this.isHierarchicalAddressFormat=(this.hierarchicalAddressConfig.hierarchicalAddress?.countriesUsingHierarchicalAddressFormat??[]).includes(e?.isocode??"");let n=this.addressForm.get("cellphone"),i=this.addressForm.get("district"),c=this.addressForm.get("town");this.addressForm.get("region")?.get("isocode")?.reset(),c?.reset(),i?.reset(),this.selectedRegion$.next(""),this.selectedCity$.next(""),this.isHierarchicalAddressFormat?(n?.setValidators([F.required]),i?.setValidators([F.required])):(n?.clearValidators(),i?.clearValidators(),c?.enable(),i?.enable()),n?.updateValueAndValidity(),i?.updateValueAndValidity()}regionSelected(e){this.addressForm.get("region")?.get("isocode")?.setValue(e.isocode),this.featureConfigService.isEnabled("enableHierarchicalAddressFormat")&&this.isHierarchicalAddressFormat&&(this.selectedRegion$.next(e.isocode??""),this.addressForm.get("town")?.reset(),this.selectedCity$.next(""),this.addressForm.get("district")?.reset())}citySelected(e){e?.isocode&&(this.selectedCity$.next(e.isocode),this.addressForm.get("district")?.reset())}toggleDefaultAddress(){this.addressForm.controls.defaultAddress.setValue(this.addressForm.value.defaultAddress)}back(){this.backToAddress.emit()}verifyAddress(){if(this.addressForm.valid){let e=this.addressForm.get("region"),n=e?.value?.isocode;n&&this.regions$.pipe(De(1)).subscribe(i=>{if(i.length){let c=i.find(g=>g.isocode===n);e?.patchValue({isocodeShort:c?.isocodeShort})}else e?.reset()}),this.addressForm.dirty?this.featureConfigService.isEnabled("enableHierarchicalAddressFormat")&&this.isHierarchicalAddressFormat?this.submitAddress.emit(this.addressForm.value):this.subscription.add(this.userAddressService.verifyAddress(this.addressForm.value).subscribe(i=>{this.handleAddressVerificationResults(i)})):this.submitAddress.emit(void 0)}else this.addressForm.markAllAsTouched(),this.globalMessageService.add({key:"formErrors.globalMessage"},k.MSG_TYPE_ASSISTIVE)}openSuggestedAddress(e){this.launchDialogService.openDialogAndSubscribe(ft.SUGGESTED_ADDRESSES,this.element,{enteredAddress:this.addressForm.value,suggestedAddresses:e.suggestedAddresses}),this.subscription.add(this.launchDialogService.dialogClose.pipe(fe(n=>!!n)).subscribe(n=>{if(typeof n=="object"){let i=si(oi({},n),{titleCode:this.addressForm.value.titleCode,phone:this.addressForm.value.phone,selected:!0});this.submitAddress.emit(i)}}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(n){return new(n||t)(E(xe),E(Xe),E(V),E(ct),E(Ie),E(Be))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-address-form"]],viewQuery:function(n,i){if(n&1&&ot(wn,5),n&2){let c;ze(c=Ke())&&(i.element=c.first)}},inputs:{addressData:"addressData",actionBtnLabel:"actionBtnLabel",cancelBtnLabel:"cancelBtnLabel",setAsDefaultField:"setAsDefaultField",showTitleCode:"showTitleCode",showCancelBtn:"showCancelBtn",countries:"countries"},outputs:{submitAddress:"submitAddress",backToAddress:"backToAddress"},decls:90,vars:104,consts:[["cityTextInput",""],["submit",""],[3,"ngSubmit","formGroup"],["formGroupName","country",1,"form-group"],[4,"ngIf"],["class","form-group",4,"ngIf"],[1,"form-group"],[1,"label-content","required"],["required","true","type","text","formControlName","firstName",1,"form-control",3,"placeholder"],["id","firstNameError",3,"translationParams","control"],["required","true","type","text","formControlName","lastName",1,"form-control",3,"placeholder"],["id","lastNameError",3,"translationParams","control"],["required","true","type","text","formControlName","line1",1,"form-control",3,"placeholder"],["id","line1Error",3,"translationParams","control"],[1,"label-content"],["type","text","formControlName","line2",1,"form-control",3,"placeholder"],[1,"row"],[4,"cxFeature"],[1,"form-group","col-sm-6"],["
1id","townError",3,"translationParams","control"],["required","true","type","text","formControlName","postalCode",1,"form-control",3,"placeholder"],["id","postalCodeError",3,"translationParams","control"],["formGroupName","region",4,"ngIf"],[1,"form-group","col-md-6"],["type","tel","formControlName","phone",1,"form-control",3,"placeholder"],[1,"cx-address-form-btns"],["class","col-md-13 col-lg-6",4,"ngIf"],[1,"col-md-13","col-lg-6"],["type","submit",1,"btn","btn-block","btn-primary"],["id","country-select","formControlName","isocode","bindLabel","name","bindValue","isocode",1,"country-select",3,"change","inputAttrs","searchable","clearable","items","placeholder","ariaLabelDropdown","cxNgSelectA11y"],[3,"translationParams","control"],["id","title-select","formControlName","titleCode","bindLabel","name","bindValue","code",3,"searchable","clearable","items","placeholder","ariaLabelDropdown","cxNgSelectA11y"],["formGroupName","region"],["formControlName","isocode","id","region-select",1,"region-select",3,"change","inputAttrs","searchable","clearable","items","bindLabel","bindValue","placeholder","ariaLabelDropdown","cxNgSelectA11y"],["class","city-select","id","city-select","formControlName","town","bindLabel","name","bindValue","isocode",3,"searchable","clearable","items","placeholder","cxNgSelectA11y","change",4,"ngIf","ngIfElse"],["id","city-select","formControlName","town","bindLabel","name","bindValue","isocode",1,"city-select",3,"change","searchable","clearable","items","placeholder","cxNgSelectA11y"],[4,"ngTemplateOutlet"],["required","true","type","text","formControlName","town",1,"form-control",3,"placeholder"],["class","form-group col-md-6",4,"ngIf"],["id","district-select","formControlName","district","bindLabel","name","bindValue","isocode",1,"district-select",3,"searchable","clearable","items","placeholder","cxNgSelectA11y"],["formControlName","isocode","id","region-select",1,"region-select",3,"inputAttrs","searchable","clearable","items","bindLabel","bindValue","placeholder","ariaLabelDropdown","cxNgSelectA11y"],[3,"control"],["type","tel","formControlName","cellphone",1,"form-control",3,"placeholder"],[3,"translationParams","control",4,"ngIf"],[1,"form-check"],["type","checkbox","formControlName","defaultAddress",1,"form-check-input",3,"change"],[1,"form-check-label"],[1,"btn","btn-block","btn-secondary",3,"click"]],template:function(n,i){if(n&1&&(p(0,"cx-form-required-legend"),d(1,"form",2),b("ngSubmit",function(){return i.verifyAddress()}),d(2,"div",3),v(3,Tn,2,1,"ng-container",4),o(4,"async"),a(),v(5,En,3,3,"div",5),d(6,"div",6)(7,"label")(8,"span",7),m(9),o(10,"cxTranslate"),p(11,"cx-form-required-asterisks"),a(),p(12,"input",8),o(13,"cxTranslate"),p(14,"cx-form-errors",9),o(15,"cxTranslate"),a()(),d(16,"div",6)(17,"label")(18,"span",7),m(19),o(20,"cxTranslate"),p(21,"cx-form-required-asterisks"),a(),p(22,"input",10),o(23,"cxTranslate"),p(24,"cx-form-errors",11),o(25,"cxTranslate"),a()(),d(26,"div",6)(27,"label")(28,"span",7),m(29),o(30,"cxTranslate"),p(31,"cx-form-required-asterisks"),a(),p(32,"input",12),o(33,"cxTranslate"),p(34,"cx-form-errors",13),o(35,"cxTranslate"),a()(),d(36,"div",6)(37,"label")(38,"span",14),m(39),o(40,"cxTranslate"),a(),p(41,"input",15),o(42,"cxTranslate"),a()(),d(43,"div",16),v(44,Bn,2,1,"ng-container",17),d(45,"div",18)(46,"label")(47,"span",7),m(48),o(49,"cxTranslate"),p(50,"cx-form-required-asterisks"),a(),v(51,Vn,2,2,"ng-container",17)(52,Dn,2,1,"ng-container",17)(53,Rn,2,6,"ng-template",null,0,Te),p(55,"cx-form-errors",19),o(56,"cxTranslate"),a()(),v(57,qn,2,1,"ng-container",17),d(58,"div",18)(59,"label")(60,"span",7),m(61),o(62,"cxTranslate"),p(63,"cx-form-required-asterisks"),a(),p(64,"input",20),o(65,"cxTranslate"),p(66,"cx-form-errors",21),o(67,"cxTranslate"),a()(),v(68,Un,2,1,"ng-container",22),o(69,"async"),a(),d(70,"div",16)(71,"div",23)(72,"label")(73,"span",14),m(74),o(75,"cxTranslate"),a(),p(76,"input",24),o(77,"cxTranslate"),a()(),v(78,jn,10,11,"ng-container",17)(79,Hn,8,7,"ng-container",17),a(),v(80,Wn,7,3,"div",5),o(81,"async"),d(82,"div",25)(83,"div",16),v(84,Yn,4,3,"div",26),d(85,"div",27)(86,"button",28,1),m(88),o(89,"cxTranslate"),a()()()()()),n&2){let c,g,_,ae,Me;r(),l("formGroup",i.addressForm),r(2),l("ngIf",s(4,50,i.countries$)),r(2),l("ngIf",i.showTitleCode),r(4),f("",s(10,52,"addressForm.firstName.label")," "),r(3),l("placeholder",x(s(13,54,"addressForm.firstName.placeholder"))),A("aria-invalid",((c=i.addressForm.get("firstName"))==null?null:c.touched)&&((c=i.addressForm.get("firstName"))==null?null:c.invalid))("aria-errormessage","firstNameError"),r(2),l("translationParams",C(94,T,s(15,56,"addressForm.firstName.label")))("control",i.addressForm.get("firstName")),r(5),f("",s(20,58,"addressForm.lastName.label")," "),r(3),l("placeholder",x(s(23,60,"addressForm.lastName.placeholder"))),A("aria-invalid",((g=i.addressForm.get("lastName"))==null?null:g.touched)&&((g=i.addressForm.get("lastName"))==null?null:g.invali
1d))("aria-errormessage","lastNameError"),r(2),l("translationParams",C(96,T,s(25,62,"addressForm.lastName.label")))("control",i.addressForm.get("lastName")),r(5),f("",s(30,64,"addressForm.address1")," "),r(3),l("placeholder",x(s(33,66,"addressForm.streetAddress"))),A("aria-invalid",((_=i.addressForm.get("line1"))==null?null:_.touched)&&((_=i.addressForm.get("line1"))==null?null:_.invalid))("aria-errormessage","line1Error"),r(2),l("translationParams",C(98,T,s(35,68,"addressForm.address1")))("control",i.addressForm.get("line1")),r(5),I(s(40,70,"addressForm.address2")),r(2),l("placeholder",x(s(42,72,"addressForm.aptSuite"))),r(3),l("cxFeature","enableHierarchicalAddressFormat"),r(4),f("",s(49,74,"addressForm.city.label")," "),r(3),l("cxFeature","enableHierarchicalAddressFormat"),r(),l("cxFeature","!enableHierarchicalAddressFormat"),r(3),l("translationParams",C(100,T,s(56,76,"addressForm.city.label")))("control",i.addressForm.get("town")),r(2),l("cxFeature","enableHierarchicalAddressFormat"),r(4),f("",s(62,78,"addressForm.zipCode.label")," "),r(3),l("placeholder",x(s(65,80,"addressForm.zipCode.placeholder"))),A("aria-invalid",((ae=i.addressForm.get("postalCode"))==null?null:ae.touched)&&((ae=i.addressForm.get("postalCode"))==null?null:ae.invalid))("aria-errormessage","postalCodeError"),r(2),l("translationParams",C(102,T,s(67,82,"addressForm.zipCode.label")))("control",i.addressForm.get("postalCode")),r(2),l("ngIf",!i.isHierarchicalAddressFormat&&s(69,84,i.regions$)),r(6),I(s(75,86,"addressForm.phoneNumber.label")),r(2),l("placeholder",x(s(77,88,"addressForm.phoneNumber.placeholder"))),r(2),l("cxFeature","enableHierarchicalAddressFormat"),r(),l("cxFeature","!enableHierarchicalAddressFormat"),r(),l("ngIf",((Me=s(81,90,i.addresses$))==null?null:Me.length)&&i.setAsDefaultField),r(4),l("ngIf",i.showCancelBtn),r(4),f(" ",i.actionBtnLabel||s(89,92,"common.continue")," ")}},dependencies:[W,$,ie,Q,mt,z,K,oe,M,re,ne,qt,G,pi,L,Ge,je,se,Dt,H,O],encapsulation:2,changeDetection:0})}}return t})(),kr=(()=>{class t{constructor(e){this.userAddressService=e}getAddresses(){return this.userAddressService.getAddresses()}getAddressesStateLoading(){return this.userAddressService.getAddressesLoading()}getAddressesError(){return this.userAddressService.getAddressesError()}loadAddresses(){this.userAddressService.loadAddresses()}addUserAddress(e){this.userAddressService.addUserAddress(e)}updateUserAddress(e,n){this.userAddressService.updateUserAddress(e,n)}setAddressAsDefault(e){this.userAddressService.setAddressAsDefault(e)}deleteUserAddress(e){this.userAddressService.deleteUserAddress(e)}static{this.\u0275fac=function(n){return new(n||t)(B(Xe))}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),Fi=(()=>{class t{constructor(e,n,i){this.service=e,this.translation=n,this.globalMessageService=i,this.showAddAddressForm=!1,this.showEditAddressForm=!1,this.subscription=new We,this.languageService=S(Rt),this.featureConfigService=S(Fe),this.hierarchicalAddressConfig=S($t)}ngOnInit(){this.addresses$=this.service.getAddresses(),this.addressesStateLoading$=this.service.getAddressesStateLoading(),this.service.loadAddresses(),this.featureConfigService.isEnabled("enableHierarchicalAddressFormat")&&this.subscription.add(this.languageService.getActive().pipe(At(1)).subscribe(()=>this.service.loadAddresses()))}ngOnDestroy(){this.subscription.unsubscribe()}addAddressButtonHandle(){this.showEditAddressForm=!1,this.showAddAddressForm=!0}editAddressButtonHandle(e){this.showAddAddressForm=!1,this.showEditAddressForm=!0,this.currentAddress=e}addAddressSubmit(e){if(!this.featureConfigService.isEnabled("enableHierarchicalAddressFormat")){this.showAddAddressForm=!1,this.service.addUserAddress(e);return}if(!e){this.showAddAddressForm=!1;return}this.service.addUserAddress(e),this.subscription.add(this.service.getAddressesStateLoading().pipe(Tt(),fe(([n,i])=>n===!0&&i===!1),De(1),Ft(this.service.getAddressesError())).subscribe(([n,i])=>{i||(this.showAddAddressForm=!1)}))}addAddressCancel(){this.showAddAddressForm=!1}editAddressSubmit(e){if(!this.featureConfigService.isEnabled("enableHierarchicalAddressFormat")){this.showEditAddressForm=!1,e&&this.currentAddress.id&&this.service.updateUserAddress(this.currentAddress.id,e);return}if(!e){this.showEditAddressForm=!1;return}this.currentAddress.id&&(this.service.updateUserAddress(this.currentAddress.id,e),this.subscription.add(this.service.getAddressesStateLoading().pipe(Tt(),fe(([n,i])=>n===!0&&i===!1),De(1),Ft(this.service.getAddressesError())).subscribe(([n,i])=>{i||(this.showEditAddressForm=!1)})))}editAddressCancel(){this.showEditAddressForm=!1}getCardContent(e){return Ye([this.translation.translate("addressCard.default"),this.translation.translate("addressCard.setAs
1Default"),this.translation.translate("common.delete"),this.translation.translate("common.edit"),this.translation.translate("addressBook.areYouSureToDeleteAddress"),this.translation.translate("addressCard.phoneNumber"),this.translation.translate("addressCard.mobileNumber")]).pipe(ge(([n,i,c,g,_,ae,Me])=>{let it=[];e.defaultAddress||it.push({name:i,event:"default"}),it.push({name:g,event:"edit"}),it.push({name:c,event:"delete"});let ri=Ci(e,ae,Me),bt;if(this.featureConfigService.isEnabled("enableHierarchicalAddressFormat")){let nt=this.buildLocationLine(e),Oi=this.isHierarchicalAddressFormat(e)&&(e.cityDistrict?.name||e.district)||"";bt=[e.line1,e.line2,nt,Oi,e.postalCode,ri].filter(Boolean)}else{let nt="";e.region&&e.region.isocode&&(nt=e.region.isocode+", "),bt=[e.line1,e.line2,e.town+", "+nt+e.country?.isocode,e.postalCode,ri]}return{role:"application",textBold:e.firstName+" "+e.lastName,text:bt,actions:it,header:e.defaultAddress?`\u2713 ${n}`:"",deleteMsg:_,label:e.defaultAddress?"addressBook.defaultDeliveryAddress":"addressBook.additionalDeliveryAddress"}}))}buildLocationLine(e){if(this.isHierarchicalAddressFormat(e)){let i=e.region?.name||e.region?.isocode||"",c=e.city?.name||e.town||"",g=e.country?.name||e.country?.isocode||"";return[c,i,g].filter(Boolean).join(", ")}let n="";return e.region&&e.region.isocode&&(n=e.region.isocode+", "),e.town+", "+n+e.country?.isocode}isHierarchicalAddressFormat(e){return(this.hierarchicalAddressConfig.hierarchicalAddress?.countriesUsingHierarchicalAddressFormat??[]).includes(e.country?.isocode??"")}setAddressAsDefault(e){this.service.setAddressAsDefault(e.id??""),this.globalMessageService.add({key:"addressMessages.setAsDefaultSuccessfully",params:{streetAddress:e.line1}},k.MSG_TYPE_CONFIRMATION)}deleteAddress(e){this.service.deleteUserAddress(e)}setEdit(e){this.editCard!==e?this.editCard=e:this.deleteAddress(e)}cancelCard(){this.editCard=null}static{this.\u0275fac=function(n){return new(n||t)(E(kr),E(ct),E(V))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-address-book"]],decls:8,vars:7,consts:[["loading",""],[1,"cx-section"],[4,"ngIf"],[1,"row"],[1,"col-md-6"],[1,"btn","btn-block","btn-secondary",3,"click"],["class","row cx-address-deck",4,"ngIf","ngIfElse"],[1,"row","cx-address-deck"],["class","col-md-6 cx-address-card",4,"ngFor","ngForOf"],[1,"col-md-6","cx-address-card"],[3,"editCard","setDefaultCard","deleteCard","cancelCard","index","border","fitToContainer","content","editMode"],[1,"cx-section-msg"],[1,"cx-form",3,"submitAddress","backToAddress","cancelCard","showTitleCode","showCancelBtn","actionBtnLabel","cancelBtnLabel","setAsDefaultField"],[3,"submitAddress","backToAddress","showTitleCode","actionBtnLabel","cancelBtnLabel","addressData"],[1,"col-md-12","cx-address-spinner"]],template:function(n,i){if(n&1&&(d(0,"div",1),v(1,Kn,8,7,"ng-container",2),o(2,"async"),v(3,Jn,10,18,"ng-container",2),o(4,"async"),v(5,Xn,8,13,"ng-container",2),a(),v(6,Zn,2,0,"ng-template",null,0,Te)),n&2){let c,g;r(),l("ngIf",((c=s(2,3,i.addresses$))==null?null:c.length)&&!(i.showAddAddressForm||i.showEditAddressForm)),r(2),l("ngIf",(!((g=s(4,5,i.addresses$))!=null&&g.length)||i.showAddAddressForm)&&!i.showEditAddressForm),r(2),l("ngIf",i.showEditAddressForm)}},dependencies:[G,Ae,_i,qi,J,H,O],encapsulation:2})}}return t})(),Li=(()=>{class t{handleClick(e){e.target.tagName===this.el.nativeElement.tagName&&this.closeModal("Cross click")}constructor(e,n){this.launchDialogService=e,this.el=n,this.iconTypes=Gt,this.focusConfig={trap:!0,block:!0,autofocus:"button",focusOnEscape:!0},this.data$=this.launchDialogService.data$}ngOnInit(){this.data$.pipe(De(1)).subscribe(e=>this.setSelectedAddress(e))}closeModal(e){this.launchDialogService.closeDialog(e)}setSelectedAddress(e){this.selectedAddress=e.suggestedAddresses?.length?e.suggestedAddresses[0]:e.enteredAddress}static{this.\u0275fac=function(n){return new(n||t)(E(Ie),E(It))}}static{this.\u0275cmp=U({type:t,selectors:[["cx-suggested-addresses-dialog"]],hostBindings:function(n,i){n&1&&b("click",function(g){return i.handleClick(g)})},decls:3,vars:4,consts:[["role","dialog","aria-labelledby","dialogTitle",1,"modal-dialog","modal
1-dialog-centered","modal-lg","cx-suggested-addresses-dialog",3,"esc","cxFocus"],["class","modal-content cx-suggested-addresses-container",4,"ngIf"],[1,"modal-content","cx-suggested-addresses-container"],[1,"cx-suggested-addresses-header","cx-modal-header"],["id","dialogTitle",1,"cx-suggested-addresses-title"],["type","button",1,"close",3,"click","title"],["aria-hidden","true"],[3,"type"],["ngForm","",1,"modal-body"],[1,"cx-dialog-info"],[1,"cx-dialog-options"],["class","form-check",4,"ngFor","ngForOf"],[1,"form-check"],["type","radio","name","selectedAddress","id","suggested-addresses--entered",1,"form-check-input",3,"ngModelChange","ngModel","value"],["for","suggested-addresses--entered",1,"form-check-label","cx-dialog-label"],[1,"cx-dialog-entered"],[1,"cx-card-container"],[1,"cx-card-label"],[1,"cx-suggested-addresses-footer","cx-modal-footer"],[1,"row"],[1,"cx-dialog-actions","col-sm-12","col-md-12","col-lg-6","offset-lg-6"],[1,"btn","btn-secondary","cx-dialog-buttons",3,"click"],["cxAutoFocus","",1,"btn","btn-primary","cx-dialog-buttons",3,"click"],["type","radio","name","selectedAddress",1,"form-check-input",3,"ngModelChange","ngModel","value","id"],[1,"form-check-label","cx-dialog-label",3,"for"],[1,"cx-dialog-suggested"]],template:function(n,i){n&1&&(d(0,"div",0),b("esc",function(){return i.closeModal("Escape clicked")}),v(1,tr,45,36,"div",1),o(2,"async"),a()),n&2&&(l("cxFocus",i.focusConfig),r(),l("ngIf",s(2,2,i.data$)))},dependencies:[Ht,G,jt,$,Q,fi,z,K,gi,ui,Ae,H,O],encapsulation:2,changeDetection:0})}}return t})(),Br=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({imports:[tt,le,M,$,ce,Ze,ut,de,ue,gt,pe,L,W,qi,Li]})}}return t})(),Nr={launch:{SUGGESTED_ADDRESSES:{inlineRoot:!0,component:Li,dialogType:Wt.DIALOG}}},Vr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{AccountAddressBookComponent:{component:Fi,guards:[Le]}}}),te(Nr),Xe],imports:[le,xi,Br,me,de,pe,Fi]})}}return t})(),Ui="REGISTRATION",Ei=(()=>{class t{constructor(){this.globalMessageService=S(V),this.fb=S(xe),this.router=S(q),this.anonymousConsentsService=S(lt),this.anonymousConsentsConfig=S(dt),this.clientAuthenticationTokenService=S(mi),this.registerComponentService=S(He),this.routingService=S(q),this.registrationVerificationTokenFacade=S(Xt),this.isLoading$=new X(!1),this.subscription=new We,this.registerForm=this.fb.group({titleCode:[null],firstName:["",F.required],lastName:["",F.required],email:["",[F.required,N.emailValidator]],newsletter:new j({value:!1,disabled:this.isConsentRequired()}),additionalConsents:this.registerComponentService.generateAdditionalConsentsFormControl?.()??this.fb.array([]),termsandconditions:[!1,F.requiredTrue],captcha:[!1,F.requiredTrue]})}get additionalConsents(){return this.registerForm?.get("additionalConsents")}updateAdditionalConsents(e,n){let{checked:i}=e.target;this.registerForm.value.additionalConsents[n]=i}ngOnInit(){this.titles$=this.registerComponentService.getTitles().pipe(ge(i=>i.sort(ht)));let e=history.state;e?.email&&(this.registerForm.patchValue({titleCode:e.titleCode??null,firstName:e.firstName??"",lastName:e.lastName??"",email:e.email??""}),history.replaceState({titleCode:"",firstName:"",lastName:"",email:""},"")),this.subscription.add(this.globalMessageService.get().pipe(fe(i=>!!Object.keys(i).length)).subscribe(i=>{let c=i&&i[k.MSG_TYPE_ERROR];c&&c.some(g=>g.raw==="This field is required.")&&(this.globalMessageService.remove(k.MSG_TYPE_ERROR),this.globalMessageService.add({key:"register.titleRequired"},k.MSG_TYPE_ERROR))}));let n=this.anonymousConsentsConfig?.anonymousConsents?.registerConsent??"";this.anonymousConsent$=Ye([this.anonymousConsentsService.getConsent(n),this.anonymousConsentsService.getTemplate(n)]).pipe(ge(([i,c])=>({consent:i,template:c?.description?c.description:""}))),this.additionalRegistrationConsents=this.registerComponentService?.getAdditionalConsents()||[],this.subscription.add(this.registerForm.get("newsletter")?.valueChanges.subscribe(()=>{this.toggleAnonymousConsent()}))}
1submitForm(){this.registerForm.valid?this.sendRegistrationVerificationToken():this.registerForm.markAllAsTouched()}sendRegistrationVerificationToken(){this.isLoading$.next(!0),this.clientAuthenticationTokenService.loadClientAuthenticationToken();let e=this.collectDataFromRegisterForm();this.registrationVerificationTokenFacade.createVerificationToken(e).subscribe({next:n=>this.goToVerificationTokenForm(n),error:n=>{this.routingService.go({cxRoute:"verifyTokenForRegistration"},{state:{errorStatus:n.status,titleCode:this.registerForm.value.titleCode,firstName:this.registerForm.value.firstName,lastName:this.registerForm.value.lastName,loginId:this.registerForm.value.email.toLowerCase()}}),this.isLoading$.next(!1)},complete:()=>this.onCreateRegistrationVerificationTokenComplete()})}onCreateRegistrationVerificationTokenComplete(){this.isLoading$.next(!1)}collectDataFromRegisterForm(){return{loginId:this.registerForm.value.email.toLowerCase(),purpose:Ui}}goToVerificationTokenForm(e){this.routingService.go({cxRoute:"verifyTokenForRegistration"},{state:{loginId:this.registerForm.value.email.toLowerCase(),tokenId:e.tokenId,expiresIn:e.expiresIn,titleCode:this.registerForm.value.titleCode,firstName:this.registerForm.value.firstName,lastName:this.registerForm.value.lastName}})}isConsentGiven(e){return this.anonymousConsentsService.isConsentGiven(e)}isConsentRequired(){let e=this.anonymousConsentsConfig?.anonymousConsents?.requiredConsents,n=this.anonymousConsentsConfig?.anonymousConsents?.registerConsent;return e&&n?e.includes(n):!1}toggleAnonymousConsent(){let e=this.anonymousConsentsConfig?.anonymousConsents?.registerConsent;e&&(this.registerForm.get("newsletter")?.value?this.anonymousConsentsService.giveConsent(e):this.anonymousConsentsService.withdrawConsent(e))}captchaConfirmed(){this.registerForm.get("captcha")?.setValue(!0)}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=U({type:t,selectors:[["cx-otp-register-form"]],decls:4,vars:4,consts:[["loading",""],["class","cx-page-section container",4,"ngIf","ngIfElse"],[1,"cx-page-section","container"],[1,"row","justify-content-center"],[1,"col-md-6"],[1,"cx-section"],[3,"ngSubmit","formGroup"],[1,"form-group"],[1,"label-content"],["bindLabel","name","bindValue","code","formControlName","titleCode","id","title-select",3,"clearable","items","placeholder","searchable","ariaLabelDropdown","cxNgSelectA11y"],["required","true","type","text","name","firstname","formControlName","firstName",1,"form-control",3,"placeholder"],[3,"translationParams","control"],["required","true","type","text","name","lastname","formControlName","lastName",1,"form-control",3,"placeholder"],["required","true","type","email","name","email","formControlName","email",1,"form-control",3,"placeholder"],[1,"form-check"],[4,"ngIf"],["formArrayName","additionalConsents","class","form-group",4,"ngIf"],["required","true","type","checkbox","name","termsandconditions","formControlName","termsandconditions"],[1,"form-check-label"],["target","_blank","rel","noopener noreferrer",3,"routerLink"],[3,"confirmed"],[3,"control"],["type","submit",1,"btn","btn-block","btn-primary"],[1,"cx-login-link","btn-link",3,"routerLink"],["type","checkbox","name","newsletter","formControlName","newsletter",1,"form-check-input",3,"checked"],["formArrayName","additionalConsents",1,"form-group"],["class","form-check",4,"ngFor","ngForOf"],["type","checkbox",3,"change","required","name","formControlName"],[1,"cx-spinner"]],template:function(n,i){if(n&1&&(v(0,sr,72,89,"section",1),o(1,"async"),v(2,ar,2,0,"ng-template",null,0,Te)),n&2){let c=be(3);l("ngIf",!s(1,2,i.isLoading$))("ngIfElse",c)}},dependencies:[G,$,ie,Q,mt,z,K,oe,Ut,M,re,ne,Lt,Ge,je,L,se,Ae,st,Kt,J,H,pt,O],encapsulation:2})}}return t})(),Mr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{RegisterCustomerWithOTPComponent:{component:Ei,guards:[Ue],providers:[{provide:He,useClass:He,deps:[Ne,xe]}]}}})],imports:[le,ce,_e,hi,de,pe,Pe,M,Ze,tt,Jt,me,ue,L,Ei]})}}return t})(),Ii=1e4,ti=(()=>{class t{constructor(){this.globalMessageService=S(V),this.userRegisterFacade=S(Ne)}displayMessage(e,n){this.globalMessageService.add({key:e,params:n},k.MSG_TYPE_CONFIRMATION,Ii)}register(e){return this.userRegisterFacade.register(e)}postRegisterMessage(){this.displayMessage("register.postRegisterSuccessMessage",Ii)}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275prov=ve({token:t,factory:t.\u0275fac})}}return t})(),Pi=(()=>{class t{constructor(){this.fb=S(xe),this.router=S(q),this.authConfigService=S($e),this.registrationVerificationTokenFacade=S(Xt),this.service=S(ti),this.globalMessage=S(V),this.launchDialogService=S(Ie),this.featureConfigService=S(Fe),this.passwordValidators=this.getPasswordValidators(),this.cdr=S(Vt),this.waitTime=60,this.waitTimeForRateLimit=300,this.registerForm=this.fb.group({password:["",[F.required,...this.passwordValidators]],passwordconf:["",F.required],tokenCode:["",F.required],titleCode:[""],firstName:[""],lastName:[""],email:[""],tokenId:[""]},{validators:N.passwordsMustMatch("password","passwordconf")}),this.isLoading$=new X(!1),this.isResendDisabled=!0}getPasswordValidators(){return this.featureConfigService.isEnabled("useEnhancedSecurePasswordValidators")?[...N.securePasswordValidators,N.mustEndWithLegalCharacter]:N.securePasswordValidators}ngOnInit(){history.state&&(this.tokenId=history.state.tokenId,this.target=history.state.loginId,this.titleCode=history.state.titleCode,this.firstName=history.state.firstName,this.lastName=history.state.lastName,this.errorStatus=history.state.errorStatus,history.pushState({tokenId:"",loginId:"",titleCode:"",firstName:"",lastName:"",errorStatus:""},"verifyTokenForRegistration")),this.errorStatus===400?(this.upToRateLimit=!0,this.tokenId="invalidTokenId",this.startRateLimitWaitTimeInterval()):!this.target||!this.tokenId||!this.firstName||!this.lastName?this.router.go(this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")?{cxRoute:"register"}:["/login/register"]):(this.startWaitTimeInterval(),this.service.displayMessage("verificationTokenForm.createVerificationToken",{target:this.target}))}onSubmit(){this.registerForm.valid?this.registerUserWithVerificationToken():this.registerForm.markAllAsTouched()}registerUserWithVerificationToken(){this.isLoading$.next(!0),this.registerForm.setValue({titleCode:this.titleCode,firstName:this.firstName,lastName:this.lastName,email:this.target,tokenId:this.tokenId,password:this.registerForm.value.password,tokenCode:this.registerForm.value.tokenCode,passwordconf:this.registerForm.value.passwordconf}),this.service.register(this.collectDataFromRegisterForm(this.registerForm.value)).subscribe({next:()=>this.onRegisterUserSuccess(),complete:()=>this.isLoading$.next(!1),error:e=>{e.status===400&&(this.registerForm.get("tokenCode")?.setErrors({invalidTokenCodeError:e.message}),this.globalMessage.remove(k.MSG_TYPE_ERROR)),this.isLoading$.next(!1)}})}collectDataFromRegisterForm(e){let{email:n,firstName:i,lastName:c,password:g,titleCode:_,tokenId:ae,tokenCode:Me}=e;return{uid:n.toLowerCase(),firstName:i,lastName:c,password:g,titleCode:_,verificationTokenId:ae,verificationTokenCode:Me}}onRegisterUserSuccess(){this.authConfigService.getOAuthFlow()===Je.ResourceOwnerPasswordFlow&&this.router.go("login"),this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")&&this.router.go({cxRoute:"login"}),this.service.postRegisterMessage()}resendOTP(){this.isResendDisabled=!0,this.resendLink.nativeElement.tabIndex=-1,this.waitTime=60,this.startWaitTimeInterval(),this.createRegistrationVerificationToken(this.target,Ui).subscribe({next:e=>this.tokenId=e.tokenId,complete:()=>this.service.displayMessage("verificationTokenForm.createVerificationToken",{target:this.target})})}createRegistrationVerificationToken(e,n){return this.registrationVerificationTokenFacade.createVerificationToken({loginId:e,purpose:n})}startWaitTimeInterval(){let e=setInterval(()=>{this.waitTime--,this.cdr.detectChanges(),this.waitTime<=0&&(clearInterval(e),this.isResendDisabled=!1,this.resendLink.nativeElement.tabIndex=0,this.cdr.detectChanges())},1e3)}startRateLimitWaitTimeInterval(){let e=setInterval(()=>{this.waitTimeForRateLimit--,this.cdr.detectChanges(),this.waitTimeForRateLimit<=0&&(clearInterval(e),this.upToRateLimit=!1,this.isResendDisabled=!1,this.cdr.detectChanges())},1e3)}openInfoDailog(){this.launchDialogService.openDialogAndSubscribe(ft.ACCOUNT_VERIFICATION_TOKEN,this.element)}onOpenInfoDailogKeyDown(e){(e.key==="Enter"||e.key===" ")&&(e.preventDefault(),this.openInfoDailog())}goBack(){this.router.go({cxRoute:"register"}
1,{state:{titleCode:this.titleCode,firstName:this.firstName,lastName:this.lastName,email:this.target}})}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=U({type:t,selectors:[["cx-registration-verification-token-form"]],viewQuery:function(n,i){if(n&1&&ot(lr,5)(dr,5),n&2){let c;ze(c=Ke())&&(i.element=c.first),ze(c=Ke())&&(i.resendLink=c.first)}},hostAttrs:["ngSkipHydration","true"],decls:46,vars:54,consts:[["loading",""],["resendLink",""],["noReceiveCodeLink",""],[3,"ngSubmit","formGroup"],[1,"label-content"],["required","true","formControlName","tokenCode",1,"form-control",3,"placeholder"],[3,"control"],["class","rate-limit-error-display",4,"ngIf"],["type","hidden","formControlName","tokenId",3,"ngModelChange","ngModel"],["class","resend-link-text",4,"ngIf"],[1,"form-group"],["required","true","type","password","name","password","formControlName","password","aria-describedby","password-input-hint","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","password-input-hint",1,"input-hint"],[3,"translationParams","control"],["required","true","type","password","name","confirmpassword","formControlName","passwordconf","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],[1,"verify-container"],["type","submit",1,"btn","btn-block","btn-primary",3,"disabled"],["type","button",1,"btn","btn-block","btn-secondary","btn-register",3,"click"],[1,"rate-limit-error-display"],[1,"resend-link-text"],[1,"left-text"],["role","timer","aria-live","polite","aria-atomic","true"],["role","button","tabindex","-1",1,"btn-link",3,"keydown.enter","keydown.space","click","ngClass"],[4,"ngIf"],[1,"right-text"],["role","button","tabindex","0",1,"btn-link",3,"keydown","click"],[1,"cx-spinner"]],template:function(n,i){if(n&1){let c=P();d(0,"form",3),b("ngSubmit",function(){return i.onSubmit()}),d(1,"label")(2,"span",4),m(3),o(4,"cxTranslate"),p(5,"cx-form-required-asterisks"),a(),p(6,"input",5),o(7,"cxTranslate"),p(8,"cx-form-errors",6),v(9,ur,3,6,"div",7),a(),d(10,"input",8),Se("ngModelChange",function(_){return y(c),we(i.tokenId,_)||(i.tokenId=_),w(_)}),a(),v(11,fr,13,10,"div",9),d(12,"div",10)(13,"label")(14,"span",4),m(15),o(16,"cxTranslate"),p(17,"cx-form-required-asterisks"),a(),p(18,"input",11),o(19,"cxTranslate"),o(20,"cxTranslate"),d(21,"p",12),m(22),o(23,"cxTranslate"),a(),p(24,"cx-form-errors",13),o(25,"cxTranslate"),a()(),d(26,"div",10)(27,"label")(28,"span",4),m(29),o(30,"cxTranslate"),p(31,"cx-form-required-asterisks"),a(),p(32,"input",14),o(33,"cxTranslate"),o(34,"cxTranslate"),p(35,"cx-form-errors",13),o(36,"cxTranslate"),a()(),d(37,"div",15)(38,"button",16),m(39),o(40,"cxTranslate"),a(),d(41,"button",17),b("click",function(){return i.goBack()}),m(42),o(43,"cxTranslate"),a()()(),v(44,hr,2,0,"ng-template",null,0,Te)}n&2&&(l("formGroup",i.registerForm),r(3),f(" ",s(4,24,"verificationTokenForm.verificationCode.label")," "),r(3),l("placeholder",x(s(7,26,"verificationTokenForm.verificationCode.placeholder"))),r(2),l("control",i.registerForm.get("tokenCode")),r(),l("ngIf",i.upToRateLimit),r(),ye("ngModel",i.tokenId),r(),l("ngIf",!i.upToRateLimit),r(4),f("",s(16,28,"register.password.label")," "),r(3),l("placeholder",x(s(19,30,"register.password.placeholder"))),A("aria-label",s(20,32,"register.password.placeholder")),r(4),f(" ",s(23,34,"register.passwordMinRequirements")," "),r(2),l("translationParams",C(50,T,s(25,36,"register.password.label")))("control",i.registerForm.get("password")),r(5),f("",s(30,38,"register.confirmPassword.label")," "),r(3),l("placeholder",x(s(33,40,"register.confirmPassword.placeholder"))),A("aria-label",s(34,42,"register.confirmPassword.placeholder")),r(3),l("translationParams",C(52,T,s(36,44,"register.confirmPassword.label")))("control",i.registerForm.get("passwordconf")),r(3),l("disabled",i.registerForm.disabled),r(),f(" ",s(40,46,"register.register")," "),r(3),f(" ",s(43,48,"verificationTokenForm.back")," "))},dependencies:[$,ie,Q,z,K,oe,M,re,ne,L,se,G,ci,J,O],encapsulation:2,changeDetection:0})}}return t})(),Dr=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({providers:[te({cmsComponents:{VerifyOTPForRegistrationComponent:{component:Pi,guards:[Ue],providers:[{provide:ti,useClass:ti,deps:[V,Ne]}]}}})],imports:[le,$,gt,M,ce,_e,ut,de,ue,me,pe,L,Pi]})}}return t})(),lo=(()=>{class t{static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275mod=ee({type:t})}static{this.\u0275inj=Z({imports:[br,Pr,Tr,Fr,Cr,yr,xr,Vr,Mr,Dr]})}}return t})();export{Zt as a,bi as b,ei as c,wi as d,xt as e,Ti as f,Ct as g,Ai as h,qi as i,Fi as j,Br as k,ti as l,Pi as m,lo as n};
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.