From 7fd5bc996687a702f92c6bea1e60f0382efc94c7 Mon Sep 17 00:00:00 2001 From: Official-Prasad Date: Mon, 25 May 2026 15:11:49 +0530 Subject: [PATCH] Fix email validation in contact form --- package.json | 16 +--------------- src/pages/Contact/Contact.tsx | 18 ++++++++++++------ 2 files changed, 13 insertions(+), 21 deletions(-) diff --git a/package.json b/package.json index 43ad31cc..430408ff 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,6 @@ "private": true, "version": "0.0.0", "type": "module", - "scripts": { "dev": "vite --host", "build": "vite build", @@ -14,7 +13,6 @@ "docker:dev": "docker compose --profile dev up --build", "docker:prod": "docker compose --profile prod up -d --build" }, - "dependencies": { "@emotion/react": "^11.11.3", "@emotion/styled": "^11.11.0", @@ -37,7 +35,6 @@ "recharts": "^3.8.1", "tailwindcss": "^3.4.14" }, - "devDependencies": { "@eslint/js": "^9.13.0", "@testing-library/jest-dom": "^6.9.1", @@ -49,34 +46,23 @@ "@types/react-dom": "^18.3.7", "@types/react-redux": "^7.1.34", "@types/react-router-dom": "^5.3.3", - "@vitejs/plugin-react-swc": "^3.5.0", - "autoprefixer": "^10.4.20", "bcryptjs": "^3.0.3", - "eslint": "^9.13.0", "eslint-plugin-react": "^7.37.2", "eslint-plugin-react-hooks": "^5.0.0", "eslint-plugin-react-refresh": "^0.4.14", - "express-session": "^1.18.2", - "globals": "^15.11.0", - "jasmine": "^5.13.0", "jasmine-spec-reporter": "^7.0.0", - "jsdom": "^29.1.1", - "passport": "^0.7.0", "passport-local": "^1.0.0", - "supertest": "^7.2.2", - "typescript-eslint": "^8.59.3", - - "vite": "^5.4.10", + "vite": "^8.0.14", "vitest": "^4.1.6" } } diff --git a/src/pages/Contact/Contact.tsx b/src/pages/Contact/Contact.tsx index a0bfccbd..730b081d 100644 --- a/src/pages/Contact/Contact.tsx +++ b/src/pages/Contact/Contact.tsx @@ -203,7 +203,13 @@ function Contact() { Send us a Message -
+
{ + e.preventDefault(); + handleSubmit(); + }} +>
{/* Full Name */}
@@ -303,24 +309,24 @@ function Contact() { }`} > -
-
+ + - {/* Success Popup */} {showPopup && (