fix(frontend): add Company Website field with URL validation in Conta… - #4037
fix(frontend): add Company Website field with URL validation in Conta…#4037Nancy-3012 wants to merge 1 commit into
Conversation
|
@Nancy-3012 is attempting to deploy a commit to the ritesh Team on Vercel. A member of the Team first needs to authorize it. |
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🎯 Summary
Resolves #4033 by adding a Company Website field to the ContactSales form with URL format validation, rejecting invalid inputs like
abc123A!1that are not valid website URLs.🛠️ Changes Made
Frontend/src/pages/ContactSales.tsxAdded
websitefield toformDatastate:Added URL validation in
handleSubmit():/^(https?:\/\/)?([\da-z.-]+)\.([a-z.]{2,6})([/\w .-]*)*\/?$/ihttps://company.com,http://acme.org,company.comabc123A!1Added Company Website input field in the form:
urlfor browser-level validationhttps://company.com✅ Fixes
abc123A!1rejected with clear alert messagehttps://company.com,company.com)Closes #4033