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

Issue with Email Validation and API Call Trigger on Login #7510

Closed
Karankhatik opened this issue Oct 8, 2024 · 34 comments
Closed

Issue with Email Validation and API Call Trigger on Login #7510

Karankhatik opened this issue Oct 8, 2024 · 34 comments
Labels
prio: low scope: front Issues that are affecting the frontend side only size: short type: design improvement

Comments

@Karankhatik
Copy link
Contributor

Bug Description

Explanation:

  1. Email Validation Not Strict Enough: The current system allows invalid email formats, causing the API to be triggered unnecessarily. The system should only send API requests when the email input matches a valid email format.
  2. Password Field Displayed Even for Non-existent Users: After the API returns a "user not found" message, the password input field still appears, which is misleading.
  3. Sign-up Button Disabled Despite Invalid State: Even though the user doesn't exist, the sign-up button remains disabled, which should be enabled to encourage user registration.

The issue was tested across Brave, Chrome, and Firefox, indicating it is system-specific and not related to browser differences.

twentylogin-bug.webm
@Karankhatik
Copy link
Contributor Author

@Bonapara Please give me the green flag to work on this issue. Thank you!

@Bonapara
Copy link
Member

Bonapara commented Oct 8, 2024

Hi @Karankhatik, thanks for raising this issue! I understand points 1 and 2, but not point 3. The button is expected to remain disabled while the fields are incomplete. What would you suggest?

@Karankhatik
Copy link
Contributor Author

Karankhatik commented Oct 8, 2024

@Bonapara Thanks for the reply, Even when the fields are filled, like with an invalid email and a password, it can be misleading.

The correct flow should be:

  1. Strictly validate the email format then go to the second step.
  2. Call the API to check if the input email corresponds to a registered user. If the user exists, display the password field; otherwise, show a toaster notification that the user or email does not exist.
  3. Finally, show the "Sign In" button, which should remain disabled until the user enters a valid password.

Please let me know your thoughts!

@Bonapara
Copy link
Member

Bonapara commented Oct 9, 2024

The behavior we have today is that if the email entered in step 1 is not recognized as a user, the flow redirects to the sign-up page. We use the same process for both sign-in and sign-up use cases. So we should not implement 2) & 3)

But we can implement 1) -> Strictly validate the email format then go to the second step that sounds like a great idea!

@Karankhatik
Copy link
Contributor Author

sure I will work on this.

@Bonapara
Copy link
Member

Bonapara commented Oct 9, 2024

/oss.gg 150

Copy link

oss-gg bot commented Oct 9, 2024

Thanks for opening an issue! It's live on oss.gg!

@vamsi-duvvana
Copy link

/assign

Copy link

oss-gg bot commented Oct 10, 2024

This issue is already assigned to another person. Please find more issues here.

@aryanbansal73
Copy link

/assign

Copy link

oss-gg bot commented Oct 10, 2024

This issue is already assigned to another person. Please find more issues here.

@HarshBytesCode
Copy link

/assign

Copy link

oss-gg bot commented Oct 11, 2024

This issue is already assigned to another person. Please find more issues here.

@no-naame
Copy link

/assign

Copy link

oss-gg bot commented Oct 11, 2024

This issue is already assigned to another person. Please find more issues here.

@vamsi4845
Copy link

/assign

Copy link

oss-gg bot commented Oct 12, 2024

This issue is already assigned to another person. Please find more issues here.

charlesBochet added a commit that referenced this issue Oct 13, 2024
… (#7596)

Purpose: Enhance email validation in the SignInUpForm component.

Changes:
- Implemented strict email format validation.
- Disabled the "Continue" button until email validation is complete.
- Displayed error messages for invalid email formats.


![image](https://github.com/user-attachments/assets/62f3c114-002e-4f9f-b18f-5309dfc43587)

---------

Co-authored-by: karankhatik <[email protected]>
Co-authored-by: Charles Bochet <[email protected]>
@Rajan3208
Copy link

/assign

Copy link

oss-gg bot commented Oct 14, 2024

This issue is already assigned to another person. Please find more issues here.

@Vishwa1011IIITM
Copy link

/assign

Copy link

oss-gg bot commented Oct 16, 2024

This issue is already assigned to another person. Please find more issues here.

@charlesBochet
Copy link
Member

/unassign

Copy link

oss-gg bot commented Oct 16, 2024

Issue unassigned.

@Sahil873
Copy link

/assign

Copy link

oss-gg bot commented Oct 16, 2024

Assigned to @Sahil873! Please open a draft PR linking this issue within 48h ⚠️ If we can't detect a PR from you linking this issue in 48h, you'll be unassigned automatically 🕹️ Excited to have you ship this 🚀

@HarshBytesCode
Copy link

/assign

Copy link

oss-gg bot commented Oct 22, 2024

This issue is already assigned to another person. Please find more issues here.

@charlesBochet
Copy link
Member

/unassign

Copy link

oss-gg bot commented Oct 22, 2024

Issue unassigned.

@oss-gg oss-gg bot unassigned Sahil873 Oct 22, 2024
@Khaan25
Copy link
Contributor

Khaan25 commented Oct 22, 2024

/assign

Copy link

oss-gg bot commented Oct 22, 2024

You already have an open issue assigned to you here. Once that's closed or unassigned, only then we recommend you to take up more.

@Khaan25
Copy link
Contributor

Khaan25 commented Oct 22, 2024

@charlesBochet Can I work on this please?

@Khaan25
Copy link
Contributor

Khaan25 commented Oct 22, 2024

@FelixMalfait Can I work on this please?

@Bonapara
Copy link
Member

Replacing this issue by #7967 to clear the discussion output. Thanks @Karankhatik for opening it. @Khaan25 comment the issue if you still want to handle it.

@github-project-automation github-project-automation bot moved this from 🆕 New to ✅ Done in Product development ✅ Oct 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
prio: low scope: front Issues that are affecting the frontend side only size: short type: design improvement
Projects
Status: ✅ Done
Development

No branches or pull requests