Skip to content

fix(validation): Improve name and email error messages for better UX#6247

Merged
JhaSourav07 merged 1 commit into
JhaSourav07:mainfrom
Abfa41:fix/validation-name-email-error-messages
Jun 21, 2026
Merged

fix(validation): Improve name and email error messages for better UX#6247
JhaSourav07 merged 1 commit into
JhaSourav07:mainfrom
Abfa41:fix/validation-name-email-error-messages

Conversation

@Abfa41

@Abfa41 Abfa41 commented Jun 21, 2026

Copy link
Copy Markdown
Contributor

Description

Fixes #6193

This PR improves validation error messages for name and email fields in the resume confirmation schema to provide clearer and more user-friendly feedback.

The previously shared generic error message has been replaced with field-specific messages to avoid confusion during form validation.

Changes made

  • Updated name field validation to show:

    • "Name must be at least 2 characters"
  • Updated email field validation to show:

    • "A valid email address is required"
    • "Invalid email address"
  • Improved consistency and clarity in validation feedback across resume-related schema fields

  • Applied changes in the current resumeConfirmDataSchema (as the referenced lines in the issue appear to be outdated)

Benefits

  • Clearer validation feedback for users
  • Removes misleading shared error messaging
  • Improves form usability and debugging experience
  • No functional changes to validation logic, only message improvements

Note

The issue references specific lines in lib/validations.ts, but those appear to be outdated in the current codebase. Equivalent validation logic was updated in the active schema implementation.

@vercel

vercel Bot commented Jun 21, 2026

Copy link
Copy Markdown
Contributor

@Abfa41 is attempting to deploy a commit to the jhasourav07's projects Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions

Copy link
Copy Markdown
Contributor

📦 Next.js Bundle Size Report (Gzipped Sizes)

✨ No significant bundle size changes detected.

📊 Summary of Totals

Category PR Size Base Size Difference
Total JS 3697.02 KB 3697.00 KB +0.01 KB (+0.00%)
Total CSS 296.58 KB 296.58 KB 0 B

@Aamod-Dev Aamod-Dev added GSSoC 2026 mentor:Aamod007 level:beginner Small changes Usually isolated fixes or simple UI/text updates. quality:clean PR follows clean coding practices, proper formatting, documentation, and maintainability standards. bug Something isn't working labels Jun 21, 2026

@Aamod-Dev Aamod-Dev left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Splitting the shared 'Name and email are required' generic message into specific messages in lib/validations.ts greatly improves form usability. The 2-character minimum for the name field makes sense too. Approved!

@JhaSourav07 JhaSourav07 added the gssoc:approved PR has been reviewed and accepted for valid contribution points label Jun 21, 2026
@JhaSourav07 JhaSourav07 merged commit 2da8855 into JhaSourav07:main Jun 21, 2026
10 of 11 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

🎉 Congratulations @Abfa41! Your PR has been successfully merged. 🚀

Thank you for contributing to CommitPulse. Your work helps us build a better tool for the community.

⚠️ Important for GSSoC Contributors:
You are strictly advised to join our Discord Server as it is mandatory for all GSSoC participants. All important announcements, point claims, and community discussions happen there.

Keep building! 💻✨

@github-actions github-actions Bot added this to the GSSoC 2026 milestone Jun 21, 2026
@Abfa41

Abfa41 commented Jun 21, 2026

Copy link
Copy Markdown
Contributor Author

@Aamod-Dev, please check the appropriate label when adding the type labels. We need to add 'type:bug' label instead of 'bug' label, to get the appropriate points in gssoc. Please look into this. Thanks!

@JhaSourav07

Copy link
Copy Markdown
Owner

@Aamod-Dev, please check the appropriate label when adding the type labels. We need to add 'type:bug' label instead of 'bug' label, to get the appropriate points in gssoc. Please look into this. Thanks!

type label will be added automatically

@github-actions github-actions Bot added the type:bug Something isn't working as expected label Jun 21, 2026
@Abfa41 Abfa41 deleted the fix/validation-name-email-error-messages branch June 21, 2026 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working gssoc:approved PR has been reviewed and accepted for valid contribution points GSSoC 2026 level:beginner Small changes Usually isolated fixes or simple UI/text updates. mentor:Aamod007 quality:clean PR follows clean coding practices, proper formatting, documentation, and maintainability standards. type:bug Something isn't working as expected

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(validation): misleading Zod error message on name field (LOW)

3 participants