@@ -221,7 +221,7 @@ const AddStep = React.memo(({ onClose }) => {
|
||||
ref={handleUsernameFieldRef}
|
||||
name="username"
|
||||
value={data.username}
|
||||
maxLength={16}
|
||||
maxLength={32}
|
||||
readOnly={isSubmitting}
|
||||
className={styles.field}
|
||||
onChange={handleFieldChange}
|
||||
|
||||
@@ -172,7 +172,7 @@ const EditUserUsernameStep = React.memo(({ id, onBack, onClose }) => {
|
||||
name="username"
|
||||
value={data.username}
|
||||
placeholder={username}
|
||||
maxLength={16}
|
||||
maxLength={32}
|
||||
className={styles.field}
|
||||
onChange={handleFieldChange}
|
||||
/>
|
||||
|
||||
@@ -18,4 +18,4 @@ export const isUrl = (string) =>
|
||||
export const isPassword = (string) => zxcvbn(string).score >= 2; // TODO: move to config
|
||||
|
||||
export const isUsername = (string) =>
|
||||
string.length >= 3 && string.length <= 16 && USERNAME_REGEX.test(string);
|
||||
string.length >= 3 && string.length <= 32 && USERNAME_REGEX.test(string);
|
||||
|
||||
Reference in New Issue
Block a user