mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Validate new user username
Show a descriptive message when the username input doesn't match a modified version of the regex used by the backend
This commit is contained in:
parent
a88349f8d3
commit
918399e0ca
3 changed files with 23 additions and 3 deletions
|
@ -205,6 +205,7 @@ const UserNew = () => {
|
|||
type='text'
|
||||
id='txtUsername'
|
||||
label='LabelName'
|
||||
validator={{ pattern: '^([\\w \\-\'._@+]*)([\\w\\-\'._@+])([\\w \\-\'._@+]*)$', errMessage: 'Username must not be empty and contain only numbers, letters, spaces, or the following symbols -\'._@+' }}
|
||||
options={'required'}
|
||||
/>
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue