More refactoring

This commit is contained in:
Chi Vinh Le
2018-02-09 23:18:21 +01:00
parent f4fc8915e3
commit 4b6a3b5b9d
17 changed files with 352 additions and 28 deletions
@@ -18,9 +18,9 @@ class SignIn extends React.Component {
e.preventDefault();
this.props.onForgotPasswordLink();
};
handleRegisterLink = e => {
handleSignUpLink = e => {
e.preventDefault();
this.props.onRegisterLink();
this.props.onSignUpLink();
};
handleEmailChange = e => this.props.onEmailChange(e.target.value);
handlePasswordChange = e => this.props.onPasswordChange(e.target.value);
@@ -113,7 +113,7 @@ class SignIn extends React.Component {
</span>
<span>
{t('sign_in.need_an_account')}
<a onClick={this.handleRegisterLink} id="coralRegister">
<a onClick={this.handleSignUpLink} id="coralRegister">
{t('sign_in.register')}
</a>
</span>
@@ -130,7 +130,7 @@ SignIn.propTypes = {
onEmailChange: PropTypes.func.isRequired,
onPasswordChange: PropTypes.func.isRequired,
onForgotPasswordLink: PropTypes.func.isRequired,
onRegisterLink: PropTypes.func.isRequired,
onSignUpLink: PropTypes.func.isRequired,
onRecaptchaVerify: PropTypes.func.isRequired,
onSubmit: PropTypes.func.isRequired,
errorMessage: PropTypes.string.isRequired,