mirror of
https://github.com/wassname/talk.git
synced 2026-08-12 12:30:39 +08:00
Enabling signup.
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-z0-9_]+$/.test(displayName))
|
||||
};
|
||||
|
||||
@@ -56,7 +56,7 @@ const SignUpContent = ({handleChange, formData, ...props}) => (
|
||||
onChange={handleChange}
|
||||
minLength="8"
|
||||
/>
|
||||
{ !props.errors.password && <span className={styles.hint}> Password must be at least 8 characters. </span> }
|
||||
{ props.errors.password && <span className={styles.hint}> Password must be at least 8 characters. </span> }
|
||||
<FormField
|
||||
id="confirmPassword"
|
||||
type="password"
|
||||
|
||||
Reference in New Issue
Block a user