From da42fedab10f8dd6f3f70aaa3fd9a1d021e0e5bb Mon Sep 17 00:00:00 2001 From: zhanzhangl Date: Tue, 27 Aug 2024 15:15:33 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=AF=86=E7=A0=81=E5=A4=84?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=AA=8C=E8=AF=81=E8=A7=84=E5=88=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/web/src/components/modals/ModifyPassword.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/client/web/src/components/modals/ModifyPassword.tsx b/client/web/src/components/modals/ModifyPassword.tsx index 535c8d5b..529f8d45 100644 --- a/client/web/src/components/modals/ModifyPassword.tsx +++ b/client/web/src/components/modals/ModifyPassword.tsx @@ -45,6 +45,10 @@ const schema = createMetaFormSchema({ newPassword: metaFormFieldSchema .string() .min(6, t('密码不能低于6位')) + .matches(/[A-Z]/, '密码必须包含大写字母') + .matches(/[a-z]/, '密码必须包含小写字母') + .matches(/\d/, '密码必须包含数字') + .matches(/[`~!@#$%^&*()_+./,;':"*]/, '密码必须包含符号') .required(t('密码不能为空')), newPasswordRepeat: metaFormFieldSchema .string()