Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: design login form #4

Merged
merged 1 commit into from
Apr 2, 2024
Merged

feat: design login form #4

merged 1 commit into from
Apr 2, 2024

Conversation

ahtesham-quraish
Copy link
Contributor

@ahtesham-quraish ahtesham-quraish commented Apr 1, 2024

Description

In this PR following things are done:

  • Design the login form
  • Include the social Auth buttons in login form
  • Add forgot password link
  • There is no hi-fi designs are available so we use approximation

JIRA

VAN-1882

How Has This Been Tested?

Mention any tests you've added or updated to ensure the changes work as expected.

Screenshots/sandbox (optional):

After
image

Merge Checklist

  • If your update includes visual changes, have they been reviewed by a designer? Send them a link to the Sandbox, if applicable.
  • Is there adequate test coverage for your changes?

Copy link
Contributor

@syedsajjadkazmii syedsajjadkazmii left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we create a forms dir inside src and move login inside forms dir.

Let me know if you think we should have an another directory structure.

src/login/index.jsx Outdated Show resolved Hide resolved
src/login/index.jsx Outdated Show resolved Hide resolved
src/login/index.jsx Outdated Show resolved Hide resolved
src/login/index.scss Outdated Show resolved Hide resolved
src/login/index.jsx Outdated Show resolved Hide resolved
@ahtesham-quraish ahtesham-quraish force-pushed the ahtesham/van-1882 branch 4 times, most recently from 66e07b2 to cc4b51c Compare April 1, 2024 07:38
src/forms/login/index.jsx Outdated Show resolved Hide resolved
src/login/index.scss Outdated Show resolved Hide resolved
Copy link
Contributor

@syedsajjadkazmii syedsajjadkazmii left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor comments. thankyou

@ahtesham-quraish
Copy link
Contributor Author

@syedsajjadkazmii we need to keep padding because this is taken from registration design so we are sure that this padding is needed around the form that is why we will keep it

Copy link
Contributor

@syedsajjadkazmii syedsajjadkazmii left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thankyou

@ahtesham-quraish ahtesham-quraish force-pushed the ahtesham/van-1882 branch 3 times, most recently from 24808ff to f3b61c7 Compare April 1, 2024 08:53
} from '@openedx/paragon';

import messages from './messages';
import SocialAuthButton from '../../common-ui/SocialAuthButtons';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
import SocialAuthButton from '../../common-ui/SocialAuthButtons';
import SocialAuthButtons from '../../common-ui/SocialAuthButtons';

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

src/authn-component/index.jsx Outdated Show resolved Hide resolved
src/forms/login/index.jsx Outdated Show resolved Hide resolved
Comment on lines 11 to 6
text-decoration: underline;
cursor: pointer;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where is this coming from? I don't see underline in the registration designs?
Screenshot 2024-04-02 at 10 27 47 AM

Copy link
Contributor Author

@ahtesham-quraish ahtesham-quraish Apr 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I saw this from lo-fi designs of login i can remove it if you want?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are following hi-fi of registration for design decisions on other things, we should use that here too.

src/forms/login/index.jsx Outdated Show resolved Hide resolved
src/forms/login/index.jsx Outdated Show resolved Hide resolved
@ahtesham-quraish ahtesham-quraish force-pushed the ahtesham/van-1882 branch 2 times, most recently from 0fa8cf3 to 0b01a2e Compare April 2, 2024 06:22
Copy link
Contributor

@zainab-amir zainab-amir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we get rid of "Text" from the messages id?
loginFormSignInButtonText -> loginFormSignInButton
loginFormForgotPasswordButtonText -> loginFormForgotPasswordButton

I have mentioned a few updates to messages file. Please use it to update other instances too.

*
* @returns {JSX.Element} The rendered login component along with social auth buttons.
*/

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: remove extra line

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

Comment on lines 1 to 12
.form-layout {
padding: 3.5rem 2.5rem 3.5rem 2.5rem;
}

.hyper-link {
cursor: pointer;
}

.pgn__form-control-floating-label-text:after {
content:"*";
color: #AB0D02;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Spacing inconsistencies

Suggested change
.form-layout {
padding: 3.5rem 2.5rem 3.5rem 2.5rem;
}
.hyper-link {
cursor: pointer;
}
.pgn__form-control-floating-label-text:after {
content:"*";
color: #AB0D02;
}
.form-layout {
padding: 3.5rem 2.5rem 3.5rem 2.5rem;
}
.hyper-link {
cursor: pointer;
}
.pgn__form-control-floating-label-text:after {
content:"*";
color: #AB0D02;
}

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

loginFormHeadingText: {
id: 'login.form.heading.text',
defaultMessage: 'Login',
description: 'Text of heading',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
description: 'Text of heading',
description: 'Login form main heading',

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

loginFormSignUpHelpingText: {
id: 'login.form.sign.up.helping.text',
defaultMessage: 'Don’t have an account yet?',
description: 'Description of sign up link helping text',
Copy link
Contributor

@zainab-amir zainab-amir Apr 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
description: 'Description of sign up link helping text',
description: 'A title that appears before "Create an account" button on login form',

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

loginFormSignUpLink: {
id: 'login.form.sign.up.link.text',
defaultMessage: 'Create an account',
description: 'Description of sign up link',
Copy link
Contributor

@zainab-amir zainab-amir Apr 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
description: 'Description of sign up link',
description: 'Registration button label that appears on login page',

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

defaultMessage: 'Email',
description: 'Email field label',
},
loginFormPasswordText: {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
loginFormPasswordText: {
loginFormPasswordFieldLabel: {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

defaultMessage: 'Password',
description: 'Password field label',
},
loginFormOrTxt: {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
loginFormOrTxt: {
loginFormHeading2: {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

loginFormOrTxt: {
id: 'login.form.or.message',
defaultMessage: 'or',
description: 'Text of or',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
description: 'Text of or',
description: 'Heading that appears between social auth and basic login form',

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

import { defineMessages } from '@edx/frontend-platform/i18n';

const messages = defineMessages({
loginFormHeadingText: {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
loginFormHeadingText: {
loginFormHeading1: {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

loginFormSignInButtonText: {
id: 'login.form.signin.button.text',
defaultMessage: 'Sign in',
description: 'Text of sign in button',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
description: 'Text of sign in button',
description: 'Sign in button label that appears on login page',

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed

Copy link
Contributor

@zainab-amir zainab-amir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please address the comments before merging.

content:"*";
color: #AB0D02;
}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: remove extra line


const messages = defineMessages({
loginFormHeading1: {
id: 'login.form.heading.text',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please update id based on the key (update for all other messages too).

Suggested change
id: 'login.form.heading.text',
id: 'login.form.heading.1',

Description:
Create login form using paragon form fields
VAN-1882
@ahtesham-quraish ahtesham-quraish merged commit 52cee8b into master Apr 2, 2024
5 checks passed
@ahtesham-quraish ahtesham-quraish deleted the ahtesham/van-1882 branch April 2, 2024 09:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants