PageSourceSearch

https://hisense.com.au/chunk-BRPJSRA6.js

js hisense.com.au collected 2026-10-02 16:56:04 UTC 29,852 bytes, 1 lines download raw bytes

1import{c as Me,d as Z,e as Ot,f as Bt}from"./chunk-ULKMX75Z.js";import{$ as Rt,$a as We,Da as Vt,E as xe,Ea as At,F as ke,Fa as Nt,Ha as we,M as St,N as Et,O as Mt,P as Ke,R as be,Tc as Ze,Wa as Se,Xa as Ee,aa as Lt,ab as Qe,ba as Fe,bb as V,c as ge,cb as A,d as w,e as he,f as ve,h as ye,ic as Ye,j as He,k as q,la as Dt,m as Ce,q as Te,ra as ze,t as _e,x as Ie}from"./chunk-DZGLL7NB.js";import{$a as S,Bb as ee,Cf as U,Db as b,Dg as Y,Eb as h,Ec as z,Ee as Ct,Ef as kt,Eg as $,Ff as bt,Hb as te,Hf as ae,Ie as Tt,If as Q,Kb as ie,L as De,Lb as ne,Lf as qe,Mb as oe,Me as _t,Mf as Ft,Mg as D,Na as Ae,Nb as rt,Nc as B,Ng as j,Ob as m,Pb as at,Pd as F,Pf as Ge,Qb as u,Qf as se,Rb as st,Sa as o,Tc as ut,Ub as ct,Vb as lt,Wb as dt,Yb as G,Za as O,Zb as H,Zc as ft,ab as T,cc as r,ce as re,d as le,db as ot,dc as a,ea as J,eb as y,ec as Ne,ff as Pe,ha as N,hc as pt,he as L,hf as It,ie as gt,ja as Ve,jc as mt,kb as E,lb as l,le as ht,lf as Ue,m as Le,md as me,n as de,na as I,nb as pe,oa as C,oe as vt,of as $e,pa as X,pd as Be,qa as _,qd as W,ra as p,rf as ue,sd as P,tf as je,vb as d,vc as Oe,wa as x,wb as c,xa as k,xb as f,xf as xt,yb as M,yc as K,ye as yt,yg as wt,za as nt,zb as R,zf as fe}from"./chunk-7OF2HBWK.js";import{a as it}from"./chunk-GON3DZPO.js";var Xt=["loginForm"],Pt=e=>({label:e}),$t=()=>({cxRoute:"forgotPassword"});function ei(e,v){e&1&&f(0,"cx-spinner",11)}function ti(e,v){if(e&1&&f(0,"input",13),e&2){let t=h(2);l("name",t.csrf.parameterName)}}function ii(e,v){if(e&1&&(M(0),y(1,ti,1,1,"input",12),R()),e&2){let t=h();o(),l("ngIf",t.csrf)}}var jt=()=>({cxRoute:"login"});function ni(e,v){if(e&1){let t=ee();M(0),d(1,"div",3),m(2),r(3,"async"),c(),d(4,"cx-page-slot",4),b("cxDomChange",function(n){let s=x(t).ngIf,g=h(2);return k(g.onRootNavBtnAdded(n,s))}),c(),R()}if(e&2){let t=h(2);o(2),u(" ",a(3,1,t.greeting$)," ")}}function oi(e,v){if(e&1&&(M(0),y(1,ni,5,3,"ng-container",2),r(2,"async"),R()),e&2){let t=h();o(),l("ngIf",a(2,1,t.greeting$))}}function ri(e,v){e&1&&(M(0),d(1,"a",5),r(2,"cxUrl"),m(3),r(4,"cxTranslate"),c(),R()),e&2&&(o(),l("routerLink",a(2,2,G(6,jt))),o(2),at(a(4,4,"miniLogin.signInRegister")))}function ai(e,v){if(e&1&&(y(0,ri,5,7,"ng-container",2),r(1,"async")),e&2){let t=h();l("ngIf",!a(1,1,t.usingASMClient$))}}var si=()=>({cxRoute:"logout"});function ci(e,v){if(e&1&&(M(0),d(1,"div",2),m(2),c(),d(3,"a",3),r(4,"cxUrl"),m(5),r(6,"cxTranslate"),c(),R()),e&2){let t=v.ngIf;o(2),st("",t.title,"",t.name,""),o(),l("routerLink",a(4,4,G(8,si))),o(2),u("",a(6,6,"myAccountV2User.signOut")," ")}}function li(e,v){e&1&&f(0,"cx-spinner",9)}var di=["noReceiveCodeLink"],pi=["resendLink"],mi=["verificationTokenForm"],ui=e=>({seconds:e}),fi=e=>({"disabled-link":e}),gi=e=>({waitTime:e});function hi(e,v){e&1&&f(0,"cx-spinner",16)}function vi(e,v){if(e&1&&(d(0,"div",17),m(1),r(2,"cxTranslate"),c()),e&2){let t=h();o(),u(" ",Ne(2,1,"register.rateLimitForRegistrationMessage",H(4,ui,t.waitTimeForRateLimit))," ")}}function yi(e,v){if(e&1&&f(0,"input",19),e&2){let t=h(2);l("name",t.csrf.parameterName)}}function Ci(e,v){if(e&1&&(M(0),y(1,yi,1,1,"input",18),R()),e&2){let t=h();o(),l("ngIf",t.csrf)}}function Ti(e,v){if(e&1&&(M(0),m(1),r(2,"cxTranslate"),R()),e&2){let t=h(2);o(),u(" ",Ne(2,1,"verificationTokenForm.sendRateLime",H(4,gi,t.waitTime))," ")}}function _i(e,v){if(e&1){let t=ee();d(0,"div",20)(1,"div",21)(2,"span",22)(3,"a",23,1),b("keydown.enter",function(){x(t);let n=h();return k(n.resendOTP())})("keydown.space",function(){x(t);let n=h();return k(n.resendOTP())})("click",function(){x(t);let n=h();return k(n.resendOTP())}),m(5),r(6,"cxTranslate"),c(),y(7,Ti,3,6,"ng-container",24),c()(),d(8,"div",25)(9,"a",26,2),b("keydown",function(n){x(t);let s=h();return k(s.onOpenInfoDailogKeyDown(n))})("click",function(){x(t);let n=h();return k(n.openInfoDailog())}),m(11),r(12,"cxTranslate"),c()()()}if(e&2){let t=h();o(3),l("ngClass",H(8,fi,t.isResendDisabled)),o(2),u(" ",a(6,4,"verificationTokenForm.resend")," "),o(2),l("ngIf",t.isResendDisabled),o(4),u(" ",a(12,6,"verificationTokenForm.noReceiveCode")," ")}}var Ii=(()=>{class e{constructor(){this.featureConfigService=p(re),this.windowRef=p(L),this.router=p(Be),this.semanticPathService=p(xt)}getPath(){return this.semanticPathService.get("loginForm")}canActivate(){return this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")&&this.windowRef.localStorage?.getItem(Ze)==="true"?(this.windowRef.localStorage.removeItem(Ze),de(this.router.createUrlTree([this.getPath()],{queryParams:{forced:!0}}))):de(!0)}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),Je=(()=>{class e{get csrf(){return this.csrfStateService.get()}constructor(t,i,n){this.auth=t,this.globalMessage=i,this.winRef=n,this.authConfigService=p(Ue),this.featureConfigService=p(re),this.csrfStateService=p(qe),this.router=p(Be),this.activatedRoute=p(me),this.customFormValidErrors=["bad_credentials","account_disabled"],this.busy$=new le(!1),this.isUpdating$=this.busy$.pipe(N(s=>{let g=this.winRef.nativeWindow?.history?.state?.newUid;g&&this.form.patchValue({userId:g}),s===!0?this.form.disable():this.form.enable()})),this.form=new ye({userId:new q("",[w.required,Ye.emailValidator]),password:new q("",w.required)}),this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")&&this.initCustomLogin()}login(t){if(!this.form.valid){this.form.markAllAsTouched();return}this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")&&t?(this.winRef.localStorage?.setItem(je,"true"),t.submit(),this.busy$.next(!0)):(this.busy$.next(!0),Le(this.auth.loginWithCredentials(this.form.value.userId.toLowerCase(),this.form.value.password)).pipe(Ve(this.auth.isUserLoggedIn()),N(([i,n])=>this.onSuccess(n))).subscribe())}handleCustomLoginError(){if(!this.featureConfigService.isEnabled("authorizationCodeFlowByDefault"))return;let t=this.activatedRoute.snapshot.queryParams.error;t&&(this.globalMessage.add({key:this.customFormValidErrors.includes(t)?`customLoginPage.badRequest.${t}`:"customLoginPage.badRequest.unknown_error"},ae.MSG_TYPE_ERROR),this.router.navigate([],{queryParams:{error:null}}))}onSuccess(t){t&&(this.globalMessage.remove(ae.MSG_TYPE_ERROR),this.form.reset()),this.busy$.next(!1)}initCustomLogin(){this.method="POST",this.action=this.authConfigService?.getCustomLoginFormEndpoint(),this.form.addControl("csrf",new He("",w.required)),this.form.get("csrf")?.setValue(this.csrf?.token)}static{this.\u0275fac=function(i){return new(i||e)(_(U),_(Q),_(L))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),xi=(()=>{class e{constructor(t){this.service=t,this.style=!0,this.form=this.service.form,this.isUpdating$=this.service.isUpdating$,this.csrf=this.service.csrf,this.action=this.service.action,this.method=this.service.method,this.service.handleCustomLoginError()}onSubmit(){this.service.login(this.loginForm?.nativeElement)}static{this.\u0275fac=function(i){return new(i||e)(O(Je))}}static{this.\u0275cmp=S({type:e,selectors:[["cx-login-form"]],viewQuery:function(i,n){if(i&1&&ie(Xt,5),i&2){let s;ne(s=oe())&&(n.loginForm=s.first)}},hostAttrs:["ngSkipHydration","true"],hostVars:2,hostBindings:function(i,n){i&2&&pe("user-form",n.style)},standalone:!1,decls:33,vars:52,consts:[["loginForm",""],["class","overlay",4,"ngIf"],[3,"ngSubmit","formGroup"],[1,"label-content"],["required","true","type","email","formControlName","userId","name","username",1,"form-control",3,"placeholder"],["id","userIdError",3,"translationParams","control"],["required","true","type","password","formControlName","password","name","password","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","passwordError",3,"translationParams","control"],[4,"cxFeature"],[1,"btn-link",3,"routerLink"],["type","submit",1,"btn","btn-block","btn-primary",3,"disabled"],[1,"overlay"],["formControlName","csrf","type","hidden",3,"name",4,"ngIf"],["formControlName","csrf","type","hidden",3,"name"]],template:function(i,n){if(i&1){let s=ee();y(0,ei,1,0,"cx-spinner",1),r(1,"async"),d(2,"form",2,0),b("ngSubmit",function(){return x(s),k(n.onSubmit())}),f(4,"cx-form-required-legend"),d(5,"label")(6,"span",3),m(7),r(8,"cxTranslate"),f(9,"cx-form-required-asterisks"),c(),f(10,"input",4),r(11,"cxTranslate"),r(12,"cxTranslate"),f(13,"cx-form-errors",5),r(14,"cxTranslate"),c(),d(15,"label")(16,"span",3),m(17),r(18,"cxTranslate"),f(19,"cx-form-required-asterisks"),c(),f(20,"input",6),r(21,"cxTranslate"),r(22,"cxTranslate"),f(23,"cx-form-errors",7),r(24,"cxTranslate"),c(),y(25,ii,2,1,"ng-container",8),d(26,"a",9),r(27,"cxUrl"),m(28),r(29,"cxTranslate"),c(),d(30,"button",10),m(31),r(32,"cxTranslate"),c()()}if(i&2){let s,g;l("ngIf",a(1,23,n.isUpdating$)),o(2),l("formGroup",n.form),E("method",n.method)("action",n.action,Ae),o(5),u(" ",a(8,25,"loginForm.emailAddress.label")," "),o(3),te("placeholder",a(11,27,"loginForm.emailAddress.placeholder")),E("aria-label",a(12,29,"loginForm.emailAddress.label"))("aria-invalid",((s=n.form.get("userId"))==null?null:s.touched)&&((s=n.form.get("userId"))==null?null:s.invalid))("aria-errormessage","userIdError"),o(3),l("translationParams",H(47,Pt,a(14,31,"loginForm.emailAddress.label")))("control",n.form.get("userId")),o(4),u(" ",a(18,33,"loginForm.password.label")," "),o(3),te("placeholder",a(21,35,"loginForm.password.placeholder")),E("aria-label",a(22,37,"loginForm.password.placeholder"))("aria-invalid",((g=n.form.get("password"))==null?null:g.touched)&&((g=n.form.get("password"))==null?null:g.invali
1d))("aria-errormessage","passwordError"),o(3),l("translationParams",H(49,Pt,a(24,39,"loginForm.password.label")))("control",n.form.get("password")),o(2),l("cxFeature","authorizationCodeFlowByDefault"),o(),l("routerLink",a(27,41,G(51,$t))),o(2),u(" ",a(29,43,"loginForm.forgotPassword")," "),o(2),l("disabled",n.form.disabled),o(),u(" ",a(32,45,"loginForm.signIn")," ")}},dependencies:[K,Ce,ge,he,ve,Ie,Te,_e,W,Se,Fe,We,$e,V,A,z,Y,D],encapsulation:2,changeDetection:0})}}return e})(),ki=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({providers:[F({cmsComponents:{ReturningCustomerLoginComponent:{component:xi,guards:[se,Ge],providers:[{provide:Je,useClass:Je,deps:[U,Q,L]}]}}})],imports:[B,xe,ke,P,$,j,Ee,we,Qe,ue,V,A]})}}return e})(),bi=(()=>{class e{constructor(t){this.activatedRoute=t,this.loginAsGuest=!1,this.routingService=p(fe,{optional:!0})}ngOnInit(){this.loginAsGuest=this.activatedRoute.snapshot.queryParams.forced}navigateTo(t){this.routingService?.go({cxRoute:t})}static{this.\u0275fac=function(i){return new(i||e)(O(me))}}static{this.\u0275cmp=S({type:e,selectors:[["cx-login-register"]],standalone:!1,decls:7,vars:7,consts:[[1,"register"],[1,"cx-section-title"],[1,"btn","btn-block","btn-secondary",3,"click","ngClass"]],template:function(i,n){i&1&&(d(0,"div",0)(1,"p",1),m(2),r(3,"cxTranslate"),c(),d(4,"button",2),b("click",function(){return n.navigateTo(n.loginAsGuest?"checkoutLogin":"register")}),m(5),r(6,"cxTranslate"),c()()),i&2&&(o(2),u(" ",a(3,3,"loginForm.dontHaveAccount")," "),o(2),l("ngClass",n.loginAsGuest?"btn-guest":"btn-register"),o(),u(" ",a(6,5,n.loginAsGuest?"loginForm.guestCheckout":"loginForm.register")," "))},dependencies:[Oe,D],encapsulation:2})}}return e})(),Fi=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({providers:[F({cmsComponents:{ReturningCustomerRegisterComponent:{component:bi,guards:[se,Ii]}}})],imports:[B,P,$,ze,j,Vt]})}}return e})(),qt=(()=>{class e{constructor(t,i,n){this.auth=t,this.userAccount=i,this.translation=n}ngOnInit(){this.user$=this.auth.isUserLoggedIn().pipe(J(t=>t?this.userAccount.get():de(void 0))),this.greeting$=this.user$.pipe(J(t=>this.translation.translate("miniLogin.userGreeting",{name:t?.name}))),this.usingASMClient$=this.auth.isUsingASMClient()}onRootNavBtnAdded(t,i){t.target.setAttribute("aria-label",i)}static{this.\u0275fac=function(i){return new(i||e)(O(U),O(Me),O(wt))}}static{this.\u0275cmp=S({type:e,selectors:[["cx-login"]],standalone:!1,decls:4,vars:4,consts:[["login",""],[4,"ngIf","ngIfElse"],[4,"ngIf"],[1,"cx-login-greet"],["cxDomChangeTargetSelector","nav ul li:first-child button","id","account-nav","position","HeaderLinks",3,"cxDomChange"],["role","link",3,"routerLink"]],template:function(i,n){if(i&1&&(y(0,oi,3,3,"ng-container",1),r(1,"async"),y(2,ai,2,3,"ng-template",null,0,pt)),i&2){let s=rt(3);l("ngIf",a(1,2,n.user$))("ngIfElse",s)}},dependencies:[K,W,Dt,At,z,Y,D],encapsulation:2})}}return e})(),wi=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({providers:[F({cmsComponents:{LoginComponent:{component:qt}}})],imports:[B,P,$,ze,j,Nt]})}}return e})(),Si=(()=>{class e extends qt{static{this.\u0275fac=(()=>{let t;return function(n){return(t||(t=nt(e)))(n||e)}})()}static{this.\u0275cmp=S({type:e,selectors:[["cx-my-account-v2-user"]],standalone:!1,features:[ot],decls:3,vars:3,consts:[[1,"cx-my-account-v2-user"],[4,"ngIf"],[1,"cx-name"],[1,"cx-sign-out",3,"routerLink"]],template:function(i,n){i&1&&(d(0,"div",0),y(1,ci,7,9,"ng-container",1),r(2,"async"),c()),i&2&&(o(),l("ngIf",a(2,1,n.user$)))},dependencies:[K,W,z,Y,D],encapsulation:2})}}return e})(),Ei=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({providers:[F({cmsComponents:{MyAccountViewUserComponent:{component:Si,guards:[Ft]}}})],imports:[B,P,$,j]})}}return e})(),Gt="LOGIN",Mi=(()=>{class e{constructor(){this.routingService=p(fe),this.verificationTokenFacade=p(Z),this.winRef=p(L),this.busy$=new le(!1),this.isUpdating$=this.busy$.pipe(N(t=>{let i=this.winRef.nativeWindow?.history?.state?.newUid;i&&this.form.patchValue({userId:i}),t===!0?this.form.disable():this.form.enable()})),this.form=new ye({userId:new q("",[w.required,Ye.emailValidator]),password:new q("",w.required)}),this.style=!0}onSubmit(){if(!this.form.valid){this.form.markAllAsTouched();return}this.busy$.next(!0);let t=this.collectDataFromLoginForm();this.verificationTokenFacade.createVerificationToken(t).subscribe({next:i=>this.goToVerificationTokenForm(i,t),error:i=>{this.routingService.go({cxRoute:"verifyToken"},{state:{loginId:t.loginId,password:t.password,errorStatus:i.status}}),this.busy$.next(!1)},complete:()=>this.onCreateVerificationTokenComplete()})}goToVerificationTokenForm(t,i){this.routingService.go({cxRoute:"verifyToken"},{state:{loginId:i.loginId,password:i.password,tokenId:t.tokenId,expiresIn:t.expires
1In}})}onCreateVerificationTokenComplete(){this.form.reset(),this.busy$.next(!1)}collectDataFromLoginForm(){return{loginId:this.form.value.userId.toLowerCase(),password:this.form.value.password,purpose:Gt}}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275cmp=S({type:e,selectors:[["cx-otp-login-form"]],hostAttrs:["ngSkipHydration","true"],hostVars:2,hostBindings:function(i,n){i&2&&pe("user-form",n.style)},standalone:!1,decls:28,vars:36,consts:[["class","overlay",4,"ngIf"],[3,"ngSubmit","formGroup"],[1,"label-content"],["required","true","type","email","formControlName","userId",1,"form-control",3,"placeholder"],["id","userIdError",3,"control"],["required","true","type","password","formControlName","password","cxPasswordVisibilitySwitch","",1,"form-control",3,"placeholder"],["id","passwordError",3,"control"],[1,"btn-link",3,"routerLink"],["type","submit",1,"btn","btn-block","btn-primary",3,"disabled"],[1,"overlay"]],template:function(i,n){if(i&1&&(y(0,li,1,0,"cx-spinner",0),r(1,"async"),d(2,"form",1),b("ngSubmit",function(){return n.onSubmit()}),f(3,"cx-form-required-legend"),d(4,"label")(5,"span",2),m(6),r(7,"cxTranslate"),f(8,"cx-form-required-asterisks"),c(),f(9,"input",3),r(10,"cxTranslate"),f(11,"cx-form-errors",4),c(),d(12,"label")(13,"span",2),m(14),r(15,"cxTranslate"),f(16,"cx-form-required-asterisks"),c(),f(17,"input",5),r(18,"cxTranslate"),r(19,"cxTranslate"),f(20,"cx-form-errors",6),c(),d(21,"a",7),r(22,"cxUrl"),m(23),r(24,"cxTranslate"),c(),d(25,"button",8),m(26),r(27,"cxTranslate"),c()()),i&2){let s,g;l("ngIf",a(1,17,n.isUpdating$)),o(2),l("formGroup",n.form),o(4),u(" ",a(7,19,"loginForm.emailAddress.label")," "),o(3),te("placeholder",a(10,21,"loginForm.emailAddress.placeholder")),E("aria-invalid",((s=n.form.get("userId"))==null?null:s.touched)&&((s=n.form.get("userId"))==null?null:s.invalid))("aria-errormessage","userIdError"),o(2),l("control",n.form.get("userId")),o(3),u(" ",a(15,23,"loginForm.password.label")," "),o(3),te("placeholder",a(18,25,"loginForm.password.placeholder")),E("aria-label",a(19,27,"loginForm.password.placeholder"))("aria-invalid",((g=n.form.get("password"))==null?null:g.touched)&&((g=n.form.get("password"))==null?null:g.invalid))("aria-errormessage","passwordError"),o(3),l("control",n.form.get("password")),o(),l("routerLink",a(22,29,G(35,$t))),o(2),u(" ",a(24,31,"loginForm.forgotPassword")," "),o(2),l("disabled",n.form.disabled),o(),u(" ",a(27,33,"loginForm.signIn")," ")}},dependencies:[K,Ce,ge,he,ve,Ie,Te,_e,W,Se,Fe,We,V,A,z,Y,D],encapsulation:2,changeDetection:0})}}return e})(),Ri=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({providers:[F({cmsComponents:{ReturningCustomerOTPLoginComponent:{component:Mi,guards:[se]}}})],imports:[B,xe,ke,P,$,j,Ee,we,Qe,ue,V,A]})}}return e})(),Li=(()=>{class e{constructor(t){this.launchDialogService=t,this.VERIFICATION_TOKEN_DIALOG_ACTION=Ot,this.focusConfig={trap:!0,block:!0,autofocus:!0,focusOnEscape:!0}}closeModal(t){this.launchDialogService.closeDialog(t)}static{this.\u0275fac=function(i){return new(i||e)(O(be))}}static{this.\u0275cmp=S({type:e,selectors:[["cx-verification-token-dialog"]],standalone:!1,decls:29,vars:22,consts:[["role","dialog","aria-labelledby","verification-token-dialog-title",1,"cx-verification-token-dialog","cx-modal-container","cx-asm-dialog",3,"esc","cxFocus"],[1,"cx-modal-content"],[1,"cx-dialog-header","modal-header"],[1,"info-icon"],["type","INFO"],["id","verification-token-dialog-title",1,"title","modal
1-title"],[1,"spliter"],[1,"cx-dialog-body","modal-body"],[1,"cx-dialog-row"],[1,"cx-dialog-item"],[1,"cx-dialog-footer","modal-footer"],["type","button",1,"btn","btn-primary",3,"click"]],template:function(i,n){i&1&&(d(0,"div",0),b("esc",function(){return n.closeModal(n.VERIFICATION_TOKEN_DIALOG_ACTION.OK)}),d(1,"div",1)(2,"div",2)(3,"div")(4,"span",3),f(5,"cx-icon",4),c(),d(6,"h3",5),m(7),r(8,"cxTranslate"),c()()(),f(9,"hr",6),d(10,"div",7)(11,"div",8)(12,"div",9),m(13),r(14,"cxTranslate"),c(),d(15,"div",9),m(16),r(17,"cxTranslate"),c(),d(18,"div",9),m(19),r(20,"cxTranslate"),c(),d(21,"div",9),m(22),r(23,"cxTranslate"),c()()(),d(24,"div",10)(25,"button",11),r(26,"cxTranslate"),b("click",function(){return n.closeModal(n.VERIFICATION_TOKEN_DIALOG_ACTION.OK)}),m(27),r(28,"cxTranslate"),c()()()()),i&2&&(l("cxFocus",n.focusConfig),o(7),u(" ",a(8,8,"verificationTokenDialog.title")," "),o(6),u(" ",a(14,10,"verificationTokenDialog.noReceiveCode")," "),o(3),u(" ",a(17,12,"verificationTokenDialog.contentLine1")," "),o(3),u(" ",a(20,14,"verificationTokenDialog.contentLine2")," "),o(3),u(" ",a(23,16,"verificationTokenDialog.contentLine3")," "),o(3),E("aria-label",a(26,18,"verificationTokenDialog.ok")),o(2),u(" ",a(28,20,"verificationTokenDialog.close")," "))},dependencies:[St,Rt,D],encapsulation:2})}}return e})(),Di={launch:{[Ke.ACCOUNT_VERIFICATION_TOKEN]:{inlineRoot:!0,component:Li,dialogType:Mt.DIALOG}}},Vi=1e4,Xe=(()=>{class e{get csrf(){return this.csrfStateService.get()}constructor(){this.authConfigService=p(Ue),this.featureConfigService=p(re),this.auth=p(U),this.csrfStateService=p(qe),this.winRef=p(L),this.globalMessage=p(Q),this.verificationTokenFacade=p(Z),this.busy$=new le(!1),this.isUpdating$=this.busy$.pipe(N(t=>{t===!0?this.form.disable():this.form.enable()})),this.form=new ye({tokenId:new q("",[w.required]),tokenCode:new q("",[w.required])}),this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")&&this.initCustomLogin()}login(t){if(!this.form.valid){this.form.markAllAsTouched();return}this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")&&t?(this.winRef.localStorage?.setItem(je,"true"),t.submit(),this.busy$.next(!0)):(this.busy$.next(!0),Le(this.auth.otpLoginWithCredentials(this.form.value.tokenId,this.form.value.tokenCode)).pipe(Ve(this.auth.isUserLoggedIn()),N(([i,n])=>this.onSuccess(n))).subscribe())}displayMessage(t,i){this.globalMessage.add({key:t,params:i},ae.MSG_TYPE_CONFIRMATION,Vi)}createVerificationToken(t,i,n){return this.verificationTokenFacade.createVerificationToken({loginId:t,password:i,purpose:n})}onSuccess(t){t&&(this.globalMessage.remove(ae.MSG_TYPE_ERROR),this.form.reset()),this.busy$.next(!1)}initCustomLogin(){this.method="POST",this.action=this.authConfigService?.getCustomLoginFormEndpoint(),this.form.addControl("csrf",new He("",w.required)),this.form.get("csrf")?.setValue(this.csrf?.token)}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),Ai=(()=>{class e{constructor(){this.featureConfigService=p(re),this.service=p(Xe),this.launchDialogService=p(be),this.cdr=p(mt),this.routingService=p(fe),this.waitTime=60,this.form=this.service.form,this.isUpdating$=this.service.isUpdating$,this.style=!0,this.isResendDisabled=!0,this.waitTimeForRateLimit=300,this.csrf=this.service.csrf,this.action=this.service.action,this.method=this.service.method}ngOnInit(){history.state&&(this.tokenId=history.state.tokenId,this.password=history.state.password,this.target=history.state.loginId,this.errorStatus=history.state.errorStatus,history.pushState({tokenId:"",password:"",loginId:"",errorStatus:""},"verifyToken"),this.errorStatus===400?(this.upToRateLimit=!0,this.tokenId="invalidTokenId",this.startRateLimitWaitTimeInterval()):!this.target||!this.password||!this.tokenId?(this.service.displayMessage("verificationTokenForm.needInputCredentials",{}),this.routingService.go(this.featureConfigService.isEnabled("authorizationCodeFlowByDefault")?{cxRoute:"login"}:["/login"])):(this.startWaitTimeInterval(),this.service.displayMessage("verificationTokenForm.createVerificationToken",{target:this.target})))}onSubmit(){this.service.login(this.verificationTokenForm?.nativeElement)}resendOTP(){this.isResendDisabled=!0,this.resendLink.nativeElement.tabIndex=-1,this.resendLink.nativeElement.blur(),this.waitTime=60,this.startWaitTimeInterval(),this.service.createVerificationToken(this.target,this.password,Gt).subscribe({next:t=>this.tokenId=t.tokenId,complete:()=>this.service.displayMessage("verificationTokenForm.createVerificationToken",{target:this.target})})}startWaitTimeInterval(){let t=setInterval(()=>{this.waitTime--,this.cdr.detectChanges(),this.waitTime<=0&&(clearInterval(t),this.isResendDisabled=!1,this.resendLink.nativeElement.tabIndex=0,this.cdr.detectChanges())},1e3)}openInfoDailog(){this.launchDialogService.openDialogAndSubscribe(Ke.ACCOUNT_VERIFICATION_TOKEN,this.element)}onOpenInfoDailogKeyDown(t){(t.key==="Enter"||t.key===" ")&&(t.preventDefault(),this.openInfoDailog())}startRateLimitWaitTimeInterval(){let t=setInterval(()=>{this.waitTimeForRateLimit--,this.cdr.detectChanges(),this.waitTimeForRateLimit<=0&&(clearInterval(t),this.upToRateLimit=!1,this.isResendDisabled=!1,this.cdr.detectChanges())},1e3)}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275cmp=S({type:e,selectors:[["cx-verification-token-form"]],viewQuery:function(i,n){if(i&1&&(ie(di,5),ie(pi,5),ie(mi,5)),i&2){let s;ne(s=oe())&&(n.element=s.first),ne(s=oe())&&(n.resendLink=s.first),ne(s=oe())&&(n.verificationTokenForm=s.first)}},hostVars:2,hostBindings:function(i,n){i&2&&pe("user-form",n.style)},standalone:!1,decls:28,vars:31,consts:[["verificationTokenForm",""],["resendLink",""],["noReceiveCodeLink",""],["class","overlay",4,"ngIf"],[3,"ngSubmit","formGroup"],[1,"label-content"],["required","true","formControlName","tokenCode","name","password","aria-describedby","tokenInputHint",1,"form-control",3,"placeholder"],[3,"control"],["class","rate-limit-error-display",4,"ngIf"],["id","tokenInputHint",1,"cx-visually-hidden"],["type","hidden","formControlName","tokenId","name","username",3,"ngModelChange","ngModel"],[4,"cxFeature"],["class","resend-link-text",4,"ngIf"],[1,"verify-container"],["type","submit",1,"btn","btn-block","btn-primary",3,"disabled"],[1,"btn","btn-block","btn-secondary","btn-register",3,"routerLink"],[1,"overlay"],[1,"rate-limit-error-display"],["formControlName","csrf","type","hidden",3,"name",4,"ngIf"],["formControlName","csrf","type","hidden",3,"name"],[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"]],template:function(i,n){if(i&1){let s=ee();y(0,hi,1,0,"cx-spinner",3),r(1,"async"),d(2,"form",4,0),b("ngSubmit",function(){return x(s),k(n.onSubmit())}),f(4,"cx-form-required-legend"),d(5,"label")(6,"span",5),m(7),r(8,"cxTranslate"),f(9,"cx-form-required-asterisks"),c(),f(10,"input",6),r(11,"cxTranslate"),f(12,"cx-form-errors",7),y(13,vi,3,6,"div",8),c(),d(14,"span",9),m(15),r(16,"cxTranslate"),c(),d(17,"input",10),dt("ngModelChange",function(Re){return x(s),lt(n.tokenId,Re)||(n.tokenId=Re),k(Re)}),c(),y(18,Ci,2,1,"ng-container",11)(19,_i,13,10,"div",12),d(20,"div",13)(21,"button",14),m(22),r(23,"cxTranslate"),c(),d(24,"button",15),r(25,"cxUrl"),m(26),r(27,"cxTranslate"),c()()()}i&2&&(l("ngIf",a(1,16,n.isUpdating$)),o(2),l("formGroup",n.form),E("method",n.method)("action",n.action,Ae),o(5),u(" ",a(8,18,"verificationTokenForm.verificationCode.label")," "),o(3),l("placeholder",a(11,20,"verificationTokenForm.verificationCode.placeholder")),o(2),l("control",n.form.get("tokenCode")),o(),l("ngIf",n.upToRateLimit),o(2),u(" ",a(16,22,"verificationTokenForm.tokenInputHint")," "),o(2),ct("ngModel",n.tokenId),o(),l("cxFeature","authorizationCodeFlowByDefault"),o(),l("ngIf",!n.upToRateLimit),o(2),l("disabled",n.form.disabled),o(),u(" ",a(23,24,"verificationTokenForm.verify")," "),o(2),l("routerLink",a(25,26,G(30,jt))),o(2),u(" ",a(27,28,"verificationTokenForm.back")," "))}
1,dependencies:[Oe,K,Ce,ge,he,ve,Ie,Te,_e,W,Se,Fe,$e,V,A,z,Y,D],encapsulation:2,changeDetection:0})}}return e})(),Ni=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({providers:[F({cmsComponents:{VerifyOTPTokenComponent:{component:Ai,guards:[se,Ge],providers:[{provide:Xe,useClass:Xe,deps:[U,Q,Z,L]}]}}}),F(Di)],imports:[B,xe,Et,ke,P,$,Lt,j,Ee,we,ue,V,A]})}}return e})(),Ht=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({imports:[wi,ki,Ni,Fi,Ei,Ri]})}}return e})();var Wt=new X("UserAccountNormalizer"),hn=new X("UserAccountSerializer"),Qt=new X("VerificationTokenNormalizer"),Yt=new X("LoginFormSerializer"),ce=class{},tt=(()=>{class e{constructor(t){this.adapter=t}get(t){return this.adapter.load(t)}createVerificationToken(t){return this.adapter.createVerificationToken(t)}static{this.\u0275fac=function(i){return new(i||e)(_(ce))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),Kt=(()=>{class e{constructor(t,i,n){this.userAccountConnector=t,this.userIdService=i,this.query=n,this.userQuery=this.query.create(()=>this.userIdService.takeUserId(!0).pipe(J(s=>this.userAccountConnector.get(s))),{reloadOn:[Bt],resetOn:[bt,kt]})}getById(t){return this.userAccountConnector.get(t)}get(){return this.userQuery.get()}static{this.\u0275fac=function(i){return new(i||e)(_(tt),_(It),_(Tt))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),zt=(()=>{class e{constructor(){this.connector=p(tt),this.command=p(Ct),this.createVerificationTokenCommand=this.command.create(({verificationTokenCreation:t})=>this.connector.createVerificationToken(t))}createVerificationToken(t){return this.createVerificationTokenCommand.execute({verificationTokenCreation:t})}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),Oi=[Kt,{provide:Me,useExisting:Kt},zt,{provide:Z,useExisting:zt}],Zt=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({providers:[tt,...Oi]})}}return e})();var Bi={backend:{occ:{endpoints:{user:"users/${userId}",createVerificationToken:"users/anonymous/verificationToken"}}}},Pi={"Content-Type":"application/json"},Ui=(()=>{class e{constructor(t,i,n){this.http=t,this.occEndpoints=i,this.converter=n,this.logger=p(vt)}load(t){let i=this.occEndpoints.buildUrl("user",{urlParams:{userId:t}});return this.http.get(i).pipe(De(n=>{throw Pe(n,this.logger)}),this.converter.pipeable(Wt))}createVerificationToken(t){let i=this.occEndpoints.buildUrl("createVerificationToken"),n=ht.createHeader(gt,!0,new ut(it({},Pi)));return t=this.converter.convert(t,Yt),this.http.post(i,t,{headers:n}).pipe(De(s=>{throw Pe(s,this.logger)}),this.converter.pipeable(Qt))}static{this.\u0275fac=function(i){return new(i||e)(_(ft),_(yt),_(_t))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),Jt=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({providers:[F(Bi),{provide:ce,useClass:Ui}]})}}return e})();var Rn=(()=>{class e{static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275mod=T({type:e})}static{this.\u0275inj=C({imports:[Zt,Jt,Ht]})}}return e})();export{Rn as UserAccountModule};

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.