mirror of
https://github.com/wassname/talk.git
synced 2026-07-22 13:00:29 +08:00
allow uppercase displaynames at creation
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
export default {
|
||||
email: email => (/^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,4})$/.test(email)),
|
||||
password: pass => !(/^(?=.{8,}).*$/.test(pass)),
|
||||
password: pass => (/^(?=.{8,}).*$/.test(pass)),
|
||||
confirmPassword: () => true,
|
||||
displayName: displayName => (/^[a-zA-Z0-9_]+$/.test(displayName))
|
||||
};
|
||||
|
||||
@@ -54,7 +54,6 @@ const SignUpContent = ({handleChange, formData, ...props}) => (
|
||||
showErrors={props.showErrors}
|
||||
errorMsg={props.errors.password}
|
||||
onChange={handleChange}
|
||||
minLength="8"
|
||||
/>
|
||||
{ !props.errors.password && <span className={styles.hint}> Password must be at least 8 characters. </span> }
|
||||
<FormField
|
||||
@@ -65,7 +64,6 @@ const SignUpContent = ({handleChange, formData, ...props}) => (
|
||||
showErrors={props.showErrors}
|
||||
errorMsg={props.errors.confirmPassword}
|
||||
onChange={handleChange}
|
||||
minLength="8"
|
||||
/>
|
||||
<div className={styles.action}>
|
||||
{ !props.auth.isLoading && !props.auth.successSignUp && (
|
||||
|
||||
Reference in New Issue
Block a user