Merge branch 'password-validation' into 'dev'
fix: password validation See merge request frontend/marketplace!178
This commit is contained in:
commit
dae4e83014
File diff suppressed because it is too large
Load Diff
@ -34,7 +34,7 @@ const initialValues: Values = {
|
||||
const validationSchema = object({
|
||||
password: string()
|
||||
.min(8, "Минимум 8 символов")
|
||||
.matches(/^[.,:;-_+\d\w]+$/, "Некорректные символы")
|
||||
.matches(/^[.,:;\-_+!&()*<>\[\]\{\}`@"#$\%\^\=?\d\w]+$/, "Некорректные символы")
|
||||
.required("Поле обязательно"),
|
||||
});
|
||||
|
||||
|
@ -41,7 +41,7 @@ const validationSchema = object({
|
||||
.email("Введите корректный email"),
|
||||
password: string()
|
||||
.min(8, "Минимум 8 символов")
|
||||
.matches(/^[.,:;\-_+!&()<>\[\]\{\}`@"#$\%\^\=?\d\w]+$/, "Некорректные символы")
|
||||
.matches(/^[.,:;\-_+!&()*<>\[\]\{\}`@"#$\%\^\=?\d\w]+$/, "Некорректные символы")
|
||||
.required("Поле обязательно"),
|
||||
repeatPassword: string()
|
||||
.oneOf([ref("password"), undefined], "Пароли не совпадают")
|
||||
|
@ -310,7 +310,7 @@ const validators: Record<UserSettingsField | keyof UserName, StringSchema> = {
|
||||
.min(6, "Номер телефона должен содержать минимум 6 символов"),
|
||||
password: string()
|
||||
.min(8, "Минимум 8 символов")
|
||||
.matches(/^[.,:;-_+\d\w]+$/, "Некорректные символы в пароле")
|
||||
.matches(/^[.,:;\-_+!&()*<>\[\]\{\}`@"#$\%\^\=?\d\w]+$/, "Некорректные символы в пароле")
|
||||
.optional(),
|
||||
firstname: string(),
|
||||
secondname: string(),
|
||||
|
Loading…
Reference in New Issue
Block a user