feat: 密码强度校验增强,要求大写+小写+数字

- validatePassword 从"字母+数字"升级为"大写字母+小写字母+数字"
- 拆分 pwLetter 为 pwLower([a-z]) 和 pwUpper([A-Z])
- 更新 ErrWeakPassword 错误提示
- 同步更新注册页和修改密码页的前端校验及提示文案
This commit is contained in:
2026-06-02 18:56:08 +08:00
parent abe1388f8c
commit 6aacbbab1c
5 changed files with 13 additions and 12 deletions

View File

@ -23,8 +23,8 @@
</div>
<div class="form-group">
<label for="password">密码</label>
<input type="password" id="password" placeholder="至少 8 位,包含字母与数字" required minlength="8">
<span class="form-error" id="passwordError">密码至少 8 位,需包含字母与数字</span>
<input type="password" id="password" placeholder="至少 8 位,包含大小写字母与数字" required minlength="8">
<span class="form-error" id="passwordError">密码至少 8 位,需包含大小写字母与数字</span>
</div>
<div class="form-group">
<label for="confirmPassword">确认密码</label>