1"use strict";(self.webpackChunkaccount_settings=self.webpackChunkaccount_settings||[]).push([[2474],{44687:(_,m,n)=>{n.d(m,{g:()=>h});var t=n(19212),d=n(24438),a=n(96814);function g(e,v){if(1&e&&(t.TgZ(0,"div",1)(1,"div",2)(2,"div",3),t._uU(3),t.qZA()()()),2&e){const i=t.oxw();t.xp6(3),t.Oqu(i.errorMsg)}}let h=(()=>{class e{constructor(i){this.csrfTokenService=i,this.isUnauthorized=!1,this.isUnauthorizedFormName=null,this.errorMsg="This session has expired. Please refresh and try again.",this.formName=null}ngOnInit(){this.csrfTokenService.isUnauthorized$.subscribe(i=>{"boolean"==typeof i?this.isUnauthorized=i:"object"==typeof i&&i&&(this.isUnauthorized=i.isUnauthorized,this.isUnauthorizedFormName=i.isUnauthorizedFormName)})}static{this.\u0275fac=function(l){return new(l||e)(t.Y36(d.A))}}static{this.\u0275cmp=t.Xpm({type:e,selectors:[["account-csrf-error-message"]],inputs:{errorMsg:"errorMsg",formName:"formName"},decls:1,vars:1,consts:[["class","csrf-error-message-container site-alert-danger alert alert-info","role","alert",4,"ngIf"],["role","alert",1,"csrf-error-message-container","site-alert-danger","alert","alert-info"],[1,"alert-content"],[1,"alert-description"]],template:function(l,u){1&l&&t.YNc(0,g,4,1,"div",0),2&l&&t.Q6J("ngIf",u.isUnauthorized&&!u.formName||u.isUnauthorized&&u.formName&&u.formName==u.isUnauthorizedFormName)},dependencies:[a.O5],encapsulation:2})}}return e})()},41384:(_,m,n)=>{n.d(m,{T:()=>h});var t=n(19212),d=n(87163),a=n(96814);function g(e,v){if(1&e&&(t.TgZ(0,"div"),t._uU(1),t.qZA()),2&e){const i=t.oxw();t.xp6(),t.hij(" ",i.errorMessage," ")}}let h=(()=>{class e{constructor(i){this.ValidationService=i,this.errorDefs={},this.errorMessage=""}ngOnChanges(i){const l=i.inputErrors.currentValue;this.errorMessage="",l&&Object.keys(l).some(u=>{if(l[u])return this.errorMessage=this.errorDefs[u]?this.errorDefs[u]:this.ValidationService.getValidatorErrorMessage(u),!0})}static{this.\u0275fac=function(l){return new(l||e)(t.Y36(d.R))}}static{this.\u0275cmp=t.Xpm({type:e,selectors:[["input-error-message"]],inputs:{errorDefs:"errorDefs",inputErrors:"inputErrors"},features:[t.TTD],decls:1,vars:1,consts:[[4,"ngIf"]],template:function(l,u){1&l&&t.YNc(0,g,2,1,"div",0),2&l&&t.Q6J("ngIf",u.errorMessage)},dependencies:[a.O5],encapsulation:2})}}return e})()},10802:(_,m,n)=>{function t(){return d=>0!==("string"==typeof d.value?d.value:"").trim().length?null:{whitespace:!0}}n.d(m,{o:()=>t})},42474:(_,m,n)=>{n.r(m),n.d(m,{LoginInformationModule:()=>O});var t=n(96814),d=n(3609),a=n(40285),g=n(10802),h=n(29851),e=n(19212),v=n(33727),i=n(39346),l=n(24438),u=n(70923),I=n(41384),C=n(44687);const T=["currentPassword"],M=s=>({"account-alert-success":s}),E=s=>({"account-i-check":s});function U(s,f){if(1&s&&(e.TgZ(0,"div",17)(1,"span",18),e._UZ(2,"div",19),e.qZA(),e.TgZ(3,"span",20),e._uU(4),e.qZA()()),2&s){const r=e.oxw();e.Q6J("ngClass",e.VKq(3,M,r.storedPassword)),e.xp6(2),e.Q6J("ngClass",e.VKq(5,E,r.storedPassword)),e.xp6(2),e.hij(" ",r.updateMessage," ")}}function L(s,f){if(1&s&&e._UZ(0,"input-error-message",21),2&s){const r=e.oxw();e.Q6J("inputErrors",r.loginInfoForm.get("current_password").errors)("errorDefs",r.validationMessages.current_password)}}function Z(s,f){if(1&s&&e._UZ(0,"input-error-message",21),2&s){const r=e.oxw();e.Q6J("inputErrors",r.loginInfoForm.get("new_password").errors)("errorDefs",r.validationMessages.new_password)}}function F(s,f){if(1&s&&(e.TgZ(0,"div",22)(1,"span",23),e._uU(2),e.qZA()()),2&s){const r=e.oxw();e.xp6(2),e.Oqu(r.validationMessages.confirm_password.passwordMismatch)}}function P(s,f){1&s&&(e.TgZ(0,"span"),e._uU(1,"UPDATE"),e.qZA())}function N(s,f){1&s&&(e.TgZ(0,"span"),e._UZ(1,"i",24),e._uU(2," UPDATING... "),e.TgZ(3,"span",25),e._uU(4,"Updating. Please wait."),e.qZA()())}const w=(s,f)=>({error:s,valid:f}),A=(s,f)=>({error:s,value:f}),D=[{path:"",component:(()=>{class s{constructor(r,c,o,p){this.customerService=r,this.ConfigManagerService=c,this.csrfTokenService=o,this.DataLayerService=p,this.processingRequest=!1,this.storedPassword=!1,this.isLoading=!1,this.validationMessages={current_password:{required:"Current password is required.",notMatch:"Password does not match current password."},new_password:{required:"New password is required.",scripts:"Invalid Character",minlength:"New password should be at least 8 characters long."}
1,confirm_password:{required:"Confirm password is required.",passwordMismatch:"Password and Confirm Password does not match."}},this.csrfToken=null,this.csrfTokenFormName="settings-update-password",this.settingsConfig=this.ConfigManagerService.getConfig("settings")}ngOnInit(){this.buildForm(),this.loginInfoLabel=this.settingsConfig.login_information.label,this.csrfTokenService.emitUnauthorized(!1),this.csrfTokenService.getToken(this.csrfTokenFormName).subscribe(r=>{this.csrfToken=r})}buildForm(){this.loginInfoForm=new a.cw({current_password:new a.NI("",[a.kI.required,(0,g.o)()]),new_password:new a.NI("",[a.kI.required,a.kI.minLength(this.settingsConfig.login_information.min_password_length),(0,g.o)(),(0,h.X)()]),confirm_password:new a.NI("",[a.kI.required,(0,g.o)(),(0,h.X)()])},{validators:this.checkPasswords})}showControlError(r){return this.loginInfoForm.get(r).invalid&&this.loginInfoForm.get(r).touched}hasValue(r){return this.loginInfoForm.get(r).value}checkPasswords(r){const c=r.get("new_password").value,o=r.get("confirm_password").value;return o?c===o?null:{passwordMismatch:!0}:{passwordMismatch:!1}}updateLoginInformation(){if(this.processingRequest=!0,this.updateMessage="",this.isLoading=!0,this.storedPassword=!1,this.loginInfoForm.valid){if(this.csrfTokenService.emitUnauthorized(!1),!this.csrfToken)return this.csrfTokenService.emitUnauthorized(!0),!1;const r={csrfToken:this.csrfToken,csrfTokenFormName:this.csrfTokenFormName,currentPassword:this.loginInfoForm.get("current_password").value,newPassword:this.loginInfoForm.get("new_password").value,confirmPassword:this.loginInfoForm.get("confirm_password").value};this.DataLayerService.logDataLayerEvent({event:"Update_preferences_initiated",event_category:"Update_preferences",event_action:"Update_preferences",event_label:"Login Information"}),this.customerService.updatePassword(r).subscribe(c=>{c.status?(this.updateMessage="Your Login Information has been updated!",this.storedPassword=!0,this.loginInfoForm.reset(),this.DataLayerService.logDataLayerEvent({event:"Update_preferences_completed",event_category:"Update_preferences",event_action:"Update_preferences_completed",event_label:"Login Information"})):(this.loginInfoForm.get("current_password").setErrors({notMatch:!0}),typeof this.currentPassword<"u"&&this.currentPassword.nativeElement.focus()),this.processingRequest=!1,this.isLoading=!1},c=>{this.processingRequest=!1,this.isLoading=!1,400==c.status&&(this.loginInfoForm.get("current_password").setErrors({notMatch:!0}),typeof this.currentPassword<"u"&&this.currentPassword.nativeElement.focus()),403==c.status&&this.csrfTokenService.emitUnauthorized(!0)})}}static{this.\u0275fac=function(c){return new(c||s)(e.Y36(v.v),e.Y36(i.Q),e.Y36(l.A),e.Y36(u.n))}}static{this.\u0275cmp=e.Xpm({type:s,selectors:[["login-information"]],viewQuery:function(c,o){if(1&c&&e.Gf(T,5),2&c){let p;e.iGM(p=e.CRH())&&(o.currentPassword=p.first)}},decls:27,vars:29,consts:[[1,"page-login-info-container"],["class","account-login-info-alert","tabindex","0","role","alert",3,"ngClass",4,"ngIf"],["tabindex","0",1,"login-info-label","first-focus-element"],["autocomplete","off",1,"login-info-form-container",3,"formGroup","submit"],[1,"account-input",3,"ngClass"],["for","current_password",1,"account-input-label"],["type","password","formControlName","current_password","maxlength","50","name","current_password","id","current_password"],[1,"account-input-message",3,"ngClass"],["tabindex","0","role","alert",3,"inputErrors","errorDefs",4,"ngIf"],["for","new_password",1,"account-input-label"],["type","password","formControlName","new_password","name","new_password","maxlength","50","id","new_password"],["for","confirm_password",1,"account-input-label"],["type","password","formControlName","confirm_password","name","confirm_password","maxlength","50","id","confirm_password"],["class","account-input-message",4,"ngIf"],["type","submit",1,"login-info-form-submit-btn","account-btn-primary",3,"disabled"],[4,"ngIf","ngIfElse"],["processing",""],["tabindex","0","role","alert",1,"account-login-info-alert",3,"ngClass"],[1,"account-alert-icon"],[3,"ngClass"],[1,"account-alert-title"],["tabindex","0","role","alert",3,"inputErrors","errorDefs"],[1,"account-input-message"],["tabindex","0","role","alert",1,"input-error-message"],[1,"fa","fa-spinner","fa-spin"],["role","alert",1,"accessibility-hidden"]],template:function(c,o){if(1&c&&(e.TgZ(0,"div",0),e.YNc(1,U,5,7,"div",1),e.TgZ(2,"h3",2),e._uU(3),e.qZA(),e.TgZ(4,"form",3),e.NdJ("submit",function(){return o.updateLoginInformation()}),e._UZ(5,"account-csrf-error-message"),e.TgZ(6,"div",4)(7,"label",5),e._uU(8,"Current password"),e.qZA(),e._UZ(9,"
1input",6),e.TgZ(10,"div",7),e.YNc(11,L,1,2,"input-error-message",8),e.qZA()(),e.TgZ(12,"div",4)(13,"label",9),e._uU(14,"New password"),e.qZA(),e._UZ(15,"input",10),e.TgZ(16,"div",7),e.YNc(17,Z,1,2,"input-error-message",8),e.qZA()(),e.TgZ(18,"div",4)(19,"label",11),e._uU(20,"Confirm New Password"),e.qZA(),e._UZ(21,"input",12),e.YNc(22,F,3,1,"div",13),e.qZA(),e.TgZ(23,"button",14),e.YNc(24,P,2,0,"span",15)(25,N,5,0,"ng-template",null,16,e.W1O),e.qZA()()()),2&c){const p=e.MAs(26);e.xp6(),e.Q6J("ngIf",o.updateMessage),e.xp6(2),e.Oqu(o.loginInfoLabel),e.xp6(),e.Q6J("formGroup",o.loginInfoForm),e.xp6(2),e.Q6J("ngClass",e.WLB(14,w,o.showControlError("current_password"),o.hasValue("current_password"))),e.xp6(4),e.Q6J("ngClass",e.WLB(17,w,o.showControlError("current_password"),o.hasValue("current_password"))),e.xp6(),e.Q6J("ngIf",o.loginInfoForm.get("current_password").invalid&&o.loginInfoForm.get("current_password").touched),e.xp6(),e.Q6J("ngClass",e.WLB(20,w,o.showControlError("new_password"),o.hasValue("new_password"))),e.xp6(4),e.Q6J("ngClass",e.WLB(23,w,o.showControlError("new_password"),o.hasValue("new_password"))),e.xp6(),e.Q6J("ngIf",o.loginInfoForm.get("new_password").invalid&&o.loginInfoForm.get("new_password").touched),e.xp6(),e.Q6J("ngClass",e.WLB(26,A,o.loginInfoForm.hasError("passwordMismatch"),o.loginInfoForm.hasError("passwordMismatch"))),e.xp6(4),e.Q6J("ngIf",o.loginInfoForm.hasError("passwordMismatch")),e.xp6(),e.Q6J("disabled",!o.loginInfoForm.valid||o.processingRequest),e.xp6(),e.Q6J("ngIf",!o.processingRequest)("ngIfElse",p)}},dependencies:[t.mk,t.O5,a._Y,a.Fj,a.JJ,a.JL,a.nD,a.sg,a.u,I.T,C.g],encapsulation:2})}}return s})()}];let y=(()=>{class s{static{this.\u0275fac=function(c){return new(c||s)}}static{this.\u0275mod=e.oAB({type:s})}static{this.\u0275inj=e.cJS({imports:[d.Bz.forChild(D),d.Bz]})}}return s})();var b=n(20434),J=n(38168);let O=(()=>{class s{static{this.\u0275fac=function(c){return new(c||s)}}static{this.\u0275mod=e.oAB({type:s})}static{this.\u0275inj=e.cJS({imports:[t.ez,y,a.u5,a.UX,b.b,J.r]})}}return s})()}}]);
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.