Strongest password policy

This commit is contained in:
Jose Alberto Hernandez
2024-05-06 21:09:31 -06:00
committed by Jose Alberto Hernandez
parent 9b17a6c4f8
commit 8fdf8fb10c
35 changed files with 283 additions and 79 deletions
@@ -0,0 +1,5 @@
<span (mouseenter)="mouseEnter()" (mouseleave)="mouseLeave()" *ngIf="!emptyValue">
<span class="m-l-3" *ngIf="isLongValue()"><fa-icon icon="eye" size="sm" [title]="textValue"></fa-icon></span>
<span class="m-l-5" *ngIf="isLongValue()">{{ textValue | truncateText:chars }}...</span>
<span class="m-l-5" *ngIf="!isLongValue()">{{ textValue }}</span>
</span>
@@ -0,0 +1,23 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { LongTextComponent } from './long-text.component';
describe('LongTextComponent', () => {
let component: LongTextComponent;
let fixture: ComponentFixture<LongTextComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ LongTextComponent ]
})
.compileComponents();
fixture = TestBed.createComponent(LongTextComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
@@ -0,0 +1,37 @@
import { Component, Input, OnInit } from '@angular/core';
@Component({
selector: 'mifosx-long-text',
templateUrl: './long-text.component.html',
styleUrls: ['./long-text.component.scss']
})
export class LongTextComponent implements OnInit {
@Input() textValue: string;
@Input() chars = 30;
iconVisible = false;
displayL = false;
displayR = true;
emptyValue = false;
constructor() { }
ngOnInit(): void {
this.emptyValue = (!this.textValue || this.textValue === '');
}
isLongValue(): boolean {
if (this.textValue == null) {
return false;
}
return (this.textValue.length > 25);
}
mouseEnter() {
this.iconVisible = true;
}
mouseLeave() {
this.iconVisible = false;
}
}