mdazfar2 / Ezyshop

EzyShop is a user-friendly platform that connects you to local stores, offering a seamless shopping experience. Compare prices, access exclusive deals, and enjoy hassle-free deliveries for groceries, essentials, and organic products—all in one app.
https://ezyshopz.vercel.app
Apache License 2.0
15 stars 31 forks source link

[BUG] I would like to create form validation for "Leave a comment" in Blog Details page #45

Open clownfish1805 opened 7 hours ago

clownfish1805 commented 7 hours ago

Description

I would like to work on implementing form validation for the "Leave a Comment" form. Here’s my approach:

Field Validation:

  1. Ensure the "Name" and "Comment" fields are not left empty before submission.
  2. Validate the "Email" field to ensure the input follows a proper email format (e.g., name@example.com).
  3. Set a character limit for the "Comment" field to avoid excessively long comments (e.g., 500 characters).

Error Messages:

  1. Provide clear error messages below the fields if validation fails (e.g., "Please enter your name" or "Invalid email address").
  2. Highlight fields with errors by using red borders or labels to make it easy for users to identify the problem.

Submit button : Submit button will only work when all the required fields are filled and follows validation.

Screenshots

image image

Any additional information?

The form is submitted eventhough the mandatory fields are not filled. The email id is not checked properly it just shows @ and anyother character after that. It doesn't properly checks the email id.

What browser are you seeing the problem on?

Chrome

Checklist

github-actions[bot] commented 7 hours ago

Hello clownfish1805! Thanks for opening an issue in Ezyshop! 🚀

We'll get back to you as soon as possible.

Hope you star our Repo.

Join our Discord Server to collaborate and discuss further.

clownfish1805 commented 7 hours ago

@mdazfar2 I would like to work on this issue. Please assign me this issue.

thakuratul2 commented 7 hours ago

@clownfish1805 assigned