HEX
Server: nginx/1.24.0
System: Linux DGT-WORDPRESS-VM-SERVER 6.14.0-1014-azure #14~24.04.1-Ubuntu SMP Fri Oct 3 20:52:11 UTC 2025 x86_64
User: ubuntu (1000)
PHP: 8.4.12
Disabled: NONE
Upload Files
File: /mnt/data/smarthr-co-in/demo/angular/template/chunk-5T7ZHU2R.js
import{a as f}from"./chunk-ILLDEPHH.js";import{d as k,e as E}from"./chunk-K3YFDFGL.js";import"./chunk-WA2UGD5L.js";import"./chunk-BT37DHWM.js";import{Gc as m,Hd as L,Jc as C,Sb as r,Tb as t,Ub as s,Vb as g,cc as v,fb as n,rb as y,sb as w,tc as p,ud as _,yb as b}from"./chunk-AQ27DSQO.js";import"./chunk-EQDQRRRY.js";var I=(l,o,i,e)=>({"poor-active":l,"avg-active":o,"strong-active":i,"heavy-active":e}),h=l=>({active:l}),R=class l{constructor(o,i){this.router=o;this.renderer=i}routes=f;navigation(){this.router.navigate([f.success])}password=[!1,!1];togglePassword(o){this.password[o]=!this.password[o]}ngOnInit(){this.renderer.addClass(document.body,"bg-white")}ngOnDestroy(){this.renderer.removeClass(document.body,"bg-white")}passwordValue="";strengthLevel="";passwordInfoMessage=null;passwordInfoColor="";poorRegExp=/[a-z]/;weakRegExp=/(?=.*?[0-9])/;strongRegExp=/(?=.*?[#?!@$%^&*-])/;whitespaceRegExp=/^$|\s+/;checkPasswordStrength(o){let e=o.target.value;this.passwordValue=e;let a=e.length,d=this.poorRegExp.test(e),u=this.weakRegExp.test(e),c=this.strongRegExp.test(e),S=this.whitespaceRegExp.test(e);if(e===""){this.resetStrength();return}if(S){this.passwordInfoMessage="Whitespaces are not allowed",this.passwordInfoColor="red",this.strengthLevel="";return}a<8?(this.strengthLevel="poor",this.passwordInfoMessage="Weak. Must contain at least 8 characters.",this.passwordInfoColor="red"):(d||u||c)&&(this.strengthLevel="weak",this.passwordInfoMessage="Average. Must contain at least 1 letter or number.",this.passwordInfoColor="#FFB54A"),a>=8&&d&&(u||c)&&(this.strengthLevel="strong",this.passwordInfoMessage="Almost strong. Must contain a special symbol.",this.passwordInfoColor="#1D9CFD"),a>=8&&d&&u&&c&&(this.strengthLevel="heavy",this.passwordInfoMessage="Awesome! You have a secure password.",this.passwordInfoColor="#159F46")}resetStrength(){this.strengthLevel="",this.passwordInfoMessage=null}static \u0275fac=function(i){return new(i||l)(w(k),w(y))};static \u0275cmp=b({type:l,selectors:[["app-reset-password-2"]],decls:48,vars:23,consts:[[1,"container-fuild"],[1,"w-100","overflow-hidden","position-relative","flex-wrap","d-block","vh-100"],[1,"row"],[1,"col-lg-5"],[1,"d-lg-flex","align-items-center","justify-content-center","d-none","flex-wrap","vh-100","bg-primary-transparent"],["src","assets/img/bg/authentication-bg-06.svg","alt","Img"],[1,"col-lg-7","col-md-12","col-sm-12"],[1,"row","justify-content-center","align-items-center","vh-100","overflow-auto","flex-wrap"],[1,"col-md-7","mx-auto","vh-100"],[1,"vh-100"],[1,"vh-100","d-flex","flex-column","justify-content-between","p-4","pb-0"],[1,"mx-auto","mb-5","text-center"],["src","assets/img/logo.svg","alt","Logo",1,"img-fluid"],[1,""],[1,"text-center","mb-3"],[1,"mb-2"],[1,"mb-0"],[1,"input-block","mb-3"],[1,"mb-3"],["for","password"],["id","passwordInput",1,"form-group"],[1,"pass-group","mb-3"],["id","password",1,"pass-input","form-control",3,"input","type"],["tabindex","0",1,"ti","toggle-password",3,"click","keydown.enter","ngClass"],["id","passwordStrength",1,"strength-meter",3,"ngClass"],["id","poor",3,"ngClass"],["id","weak",3,"ngClass"],["id","strong",3,"ngClass"],["id","heavy",3,"ngClass"],["id","passwordInfo",1,"fs-12"],[1,"form-label"],[1,"pass-group"],[1,"pass-input","form-control",3,"type"],[1,"btn","btn-primary","w-100",3,"routerLink"],[1,"mt-5","pb-4","text-center"],[1,"mb-0","text-gray-9"]],template:function(i,e){i&1&&(t(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4)(5,"div"),g(6,"img",5),s()()(),t(7,"div",6)(8,"div",7)(9,"div",8)(10,"form",9)(11,"div",10)(12,"div",11),g(13,"img",12),s(),t(14,"div",13)(15,"div",14)(16,"h2",15),p(17,"Reset Password"),s(),t(18,"p",16),p(19,"Your new password must be different from previous used passwords."),s()(),t(20,"div")(21,"div",17)(22,"div",18)(23,"label",19),p(24,"Password"),s(),t(25,"div",20)(26,"div",21)(27,"input",22),v("input",function(d){return e.checkPasswordStrength(d)}),s(),t(28,"span",23),v("click",function(){return e.togglePassword(0)})("keydown.enter",function(){return e.togglePassword(0)}),s()(),t(29,"div",24),g(30,"span",25)(31,"span",26)(32,"span",27)(33,"span",28),s()()(),t(34,"p",29),p(35," Use 8 or more characters with a mix of letters, numbers & symbols. "),s()(),t(36,"div",18)(37,"label",30),p(38,"Confirm Password"),s(),t(39,"div",31),g(40,"input",32),t(41,"span",23),v("click",function(){return e.togglePassword(1)})("keydown.enter",function(){return e.togglePassword(1)}),s()()(),t(42,"div",18)(43,"a",33),p(44,"Submit"),s()()()(),t(45,"div",34)(46,"p",35),p(47,"Copyright \xA9 2024 - Smarthr"),s()()()()()()()()()()),i&2&&(n(27),r("type",e.password[0]?"text":"password"),n(),r("ngClass",e.password[0]?"ti-eye":"ti-eye-off"),n(),r("ngClass",C(10,I,e.strengthLevel==="poor",e.strengthLevel==="weak",e.strengthLevel==="strong",e.strengthLevel==="heavy")),n(),r("ngClass",m(15,h,e.strengthLevel==="poor"||e.strengthLevel==="weak"||e.strengthLevel==="strong"||e.strengthLevel==="heavy")),n(),r("ngClass",m(17,h,e.strengthLevel==="weak"||e.strengthLevel==="strong"||e.strengthLevel==="heavy")),n(),r("ngClass",m(19,h,e.strengthLevel==="strong"||e.strengthLevel==="heavy")),n(),r("ngClass",m(21,h,e.strengthLevel==="heavy")),n(7),r("type",e.password[1]?"text":"password"),n(),r("ngClass",e.password[1]?"ti-eye":"ti-eye-off"),n(2),r("routerLink",e.routes.success2))},dependencies:[L,_,E],encapsulation:2})};export{R as ResetPassword2Component};