update validation in signup component

This commit is contained in:
Nguyễn Đức Đạt
2023-05-01 16:47:23 +07:00
parent 7862d84168
commit f9d4a1f2eb
2 changed files with 2 additions and 2 deletions
@@ -134,7 +134,7 @@
</div>
<div class="col-xl-8 col-md-7">
<input style="font-family: Metrophobic;" formControlName="identifiedCode" class="form-control"
type="number" placeholder="CMND/CCCD" />
type="tel" placeholder="CMND/CCCD" />
<div
*ngIf="userIdentifiedCode?.invalid && (userIdentifiedCode?.dirty || userIdentifiedCode?.touched)"
class="alert alert-danger mt-1">
+1 -1
View File
@@ -1,7 +1,7 @@
export class Validation {
static Regex = {
Phone: new RegExp(/^(((\+|)84)|0)([1-9]{1})([0-9]{8})\b/),
IdentifiedCode: new RegExp(/^(\d{9}|\d{12})$/),
IdentifiedCode: new RegExp(/^0\d{8}$|^0\d{11}$|^\d{9}$|^\d{12}$/),
Password: new RegExp(/(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[@$!%*#?&^_-]).{8,}/),
};
}