diff --git a/packages/strapi-plugin-graphql/package.json b/packages/strapi-plugin-graphql/package.json
index 301b5783f4..99005652a3 100644
--- a/packages/strapi-plugin-graphql/package.json
+++ b/packages/strapi-plugin-graphql/package.json
@@ -48,4 +48,4 @@
"npm": ">= 5.3.0"
},
"license": "MIT"
-}
+}
\ No newline at end of file
diff --git a/packages/strapi-plugin-users-permissions/admin/src/containers/AuthPage/index.js b/packages/strapi-plugin-users-permissions/admin/src/containers/AuthPage/index.js
index b8db60d175..4c165782e2 100644
--- a/packages/strapi-plugin-users-permissions/admin/src/containers/AuthPage/index.js
+++ b/packages/strapi-plugin-users-permissions/admin/src/containers/AuthPage/index.js
@@ -92,6 +92,8 @@ export class AuthPage extends React.Component { // eslint-disable-line react/pre
}
renderButton = () => {
+ const { match: { params: { authType } }, submitSuccess } = this.props;
+
if (this.props.match.params.authType === 'login') {
return (
@@ -99,13 +101,16 @@ export class AuthPage extends React.Component { // eslint-disable-line react/pre
);
}
- const label = this.props.match.params.authType === 'forgot-password' && this.props.submitSuccess ? 'users-permissions.Auth.form.button.forgot-password.success' : `users-permissions.Auth.form.button.${this.props.match.params.authType}`;
+ const isEmailForgotSent = authType === 'forgot-password' && submitSuccess;
+ const label = isEmailForgotSent ? 'users-permissions.Auth.form.button.forgot-password.success' : `users-permissions.Auth.form.button.${this.props.match.params.authType}`;
+
return (
@@ -133,15 +138,36 @@ export class AuthPage extends React.Component { // eslint-disable-line react/pre
return ;
}
+ renderInputs = () => {
+ const { match: { params: { authType } } } = this.props;
+ const inputs = get(form, ['form', authType]);
+
+ return map(inputs, (input, key) => (
+
+ ));
+ }
+
render() {
- const inputs = get(form, ['form', this.props.match.params.authType]);
- const divStyle = this.props.match.params.authType === 'register' ? { marginTop: '3.2rem' } : { marginTop: '.9rem' };
- const withLogo = this.props.match.params.authType === 'register' ? (
-
- ) : '';
- const headerDescription = this.props.match.params.authType === 'register' ?
-
- : ;
+ const { match: { params: { authType } }, modifiedData, submitSuccess } = this.props;
+ let divStyle = authType === 'register' ? { marginTop: '3.2rem' } : { marginTop: '.9rem' };
+
+ if (authType === 'forgot-password' && submitSuccess) {
+ divStyle = { marginTop: '.9rem', minHeight: '18.2rem' };
+ }
return (
@@ -154,10 +180,16 @@ export class AuthPage extends React.Component { // eslint-disable-line react/pre
)}
- {headerDescription}
+ {authType === 'register' && }
-
+
@@ -192,7 +215,7 @@ export class AuthPage extends React.Component { // eslint-disable-line react/pre
{this.renderLink()}
- {withLogo}
+ {authType === 'register' && }
);
}
diff --git a/packages/strapi-plugin-users-permissions/admin/src/containers/AuthPage/styles.scss b/packages/strapi-plugin-users-permissions/admin/src/containers/AuthPage/styles.scss
index 3c790dfea9..ccf7b004a7 100644
--- a/packages/strapi-plugin-users-permissions/admin/src/containers/AuthPage/styles.scss
+++ b/packages/strapi-plugin-users-permissions/admin/src/containers/AuthPage/styles.scss
@@ -51,7 +51,6 @@
margin-bottom: 0;
padding: 3.9rem 1.5rem 1.5rem 1.5rem;
border-radius: 2px;
- border-top: 2px solid #1C5DE7;
background-color: #FFFFFF;
box-shadow: 0 2px 4px 0 #E3E9F3;
}
@@ -82,6 +81,13 @@
}
}
+.bordered {
+ border-top: 2px solid #1C5DE7;
+}
+
+.borderedSuccess {
+ border-top: 2px solid #5A9E06;
+}
.logoContainer {
position: absolute;
@@ -91,3 +97,22 @@
height: 34px;
}
}
+
+.buttonForgotSuccess {
+ border: 1px solid #5A9E06;
+ color: #5A9E06;
+}
+
+.forgotSuccess {
+ width: 100%;
+ // margin-top: -2px;
+ text-align: center;
+ color: #5A9E06;
+ font-size: 13px;
+ font-weight: 500;
+ > p {
+ margin-top: 17px;
+ margin-bottom: 18px;
+ color: #333740;
+ }
+}
\ No newline at end of file