diff --git a/src/App.jsx b/src/App.jsx index 5e020a82d..4a1802a83 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -1,58 +1,62 @@ import React from "react"; import { Route, Routes, Navigate } from "react-router-dom"; import { AuthProvider } from "./context/AuthContext"; +import { Helmet } from "react-helmet-async"; + +import Home from "./User/pages/Home"; +import UserAuth from "./User/pages/UserAuth"; +import Privacy from "./User/pages/Privacy-Policy"; +import TermsAndConditions from "./User/pages/TermsAndCondition"; + + +// User pages (FIXED IMPORTS) +import UserAuth from "./User/pages/UserAuth"; +import AboutUs from "./User/pages/AboutUs"; +import Contributors from "./User/pages/Contributors"; +import Contact from "./User/pages/Contacts"; +import Dashboard from "./User/pages/Dashboard"; +import Home from "./User/pages/Home"; +import Privacy from "./User/pages/Privacy-Policy"; +import TermsAndConditions from "./User/pages/TermsAndCondition"; +import Help from "./User/pages/Help"; +import MeetTheMakers from "./User/pages/MeetTheMakers"; +import FAQ from "./User/pages/FAQ"; +import CareerPage from "./User/pages/Career-Page"; +import ServicePage from "./User/pages/Service-Page"; +import Shipping from "./User/pages/Shipping"; +import GiftCard from "./User/pages/Gift-Card"; +import Payment_Policy from "./User/pages/Payment-Policy"; +import Certification from "./User/pages/Certification"; +import ReturnAndCancellation from "./User/pages/ReturnAndCancellation"; +import EPR_Page from "./User/pages/EPRPage"; -// User components -import UserAuth from "./User/pages/UserAuth/UserAuth"; -import AboutUs from "./User/pages/AboutUs/Aboutus.jsx"; -import Contributors from "./User/pages/Contributors/Contributors.jsx"; -import Contact from "./User/pages/Contacts/Contact"; -import Dashboard from "./User/pages/Dashboard/Dashboard"; -import Home from "./User/pages/Home/Home"; +// Layouts & shared import UserLayout from "./User/UserLayout"; import Team from "./User/components/Team/Team"; -import Confirmation from "./User/pages/Confirmation/Confirmation"; -import Cancellation from "./User/pages/Cancellation/Cancellation"; +import Error from "./User/pages/404-Page/Error"; +import PrivateRoute from "./PrivateRoute"; + +// Orders import OrderDetails from "./User/pages/Order/Orderdetails"; import MyOrders from "./User/pages/Order/MyOrders"; -import DashboardOrders from "./User/pages/Dashboard/dashboard-order"; -import DashboardCart from "./User/pages/Dashboard/dashboard-cart"; -import DashboardWishlist from "./User/pages/Dashboard/dashboard-wishlist"; import Checkout from "./User/pages/Order/Checkout"; import Cart from "./User/pages/Order/Cart"; import Wishlist from "./User/pages/Order/Wishlist"; -import Error from "./User/pages/404-Page/Error"; -import ProductDetails from "./User/components/Products/ProductDetails"; -import Help from "./User/pages/Help/Help"; -import Privacy from "./User/pages/Privacy-Policy/Privacy"; -import Payment from "./User/pages/Payment/Payment"; -import MeetTheMakers from "./User/pages/MeetTheMakers/MeetTheMakers.jsx"; +import Confirmation from "./User/pages/Confirmation"; +import Cancellation from "./User/pages/Cancellation"; -import ReturnAndCancellation from "./User/pages/ReturnAndCancellation/returnAndCancellation"; -import EPR_Page from "./User/pages/EPRPage/EPR_Page"; -import FAQ from "./User/pages/FAQ/Faq"; -import PrivateRoute from "./PrivateRoute"; -import TermsAndConditions from "./User/pages/TermsAndCondition/TermsAndCondition"; -// import FeedbackButton from "./User/components/FeedbackForm/FeedBtn"; -import FeedbackModal from "./User/components/FeedbackForm/Feedback"; +// Dashboard extras +import DashboardOrders from "./User/pages/Dashboard/dashboard-order"; +import DashboardCart from "./User/pages/Dashboard/dashboard-cart"; +import DashboardWishlist from "./User/pages/Dashboard/dashboard-wishlist"; import NotificationPage from "./User/pages/Dashboard/NotificationPage"; import ProfilePage from "./User/pages/Dashboard/ProfilePage"; -import CareerPage from "./User/pages/Career-Page/careerPage.jsx"; -import ServicePage from "./User/pages/Service-Page/service.jsx"; -import Shipping from "./User/pages/Shipping/shipping"; -import GiftCard from "./User/pages/Gift-Card/gift-card.jsx"; -import Payment_Policy from "./User/pages/Payment-Policy/payment-policy.jsx"; -import Certification from "./User/pages/Certification/Certification.jsx"; -// Admin components -import AdminVerificationPage from "./User/pages/Admin-Verification/Admin.jsx"; -import AdminLayout from "./Admin/AdminLayout"; -import AdminLogin from "./Admin/Pages/AdminLogin"; -import VigyForm from "./Admin/Pages/VigyForm"; -import AdminPanel from "./Admin/Pages/AdminPanel"; -import ProductForm from "./Admin/Pages/ProductForm"; -// Latest In Market -import LatestInMarket from "./User/pages/Latest_in_the_Market/LatestInMarket"; +// Products +import ProductDetails from "./User/components/Products/ProductDetails"; + +// Latest in Market +import LatestInMarket from "./User/pages/Latest_in_the_Market"; import HandMadeSoaps from "./User/pages/Latest_in_the_Market/HandMadeSoaps"; import ArtSupplies from "./User/pages/Latest_in_the_Market/ArtSupplies"; import CeramicDinnerware from "./User/pages/Latest_in_the_Market/CeramicDinnerware"; @@ -61,10 +65,9 @@ import StorageBaskets from "./User/pages/Latest_in_the_Market/StorageBaskets"; import OrganicSoaps from "./User/pages/Latest_in_the_Market/OrganicSoaps"; import OrganicTea from "./User/pages/Latest_in_the_Market/OrganicTea"; import NaturalCosmetics from "./User/pages/Latest_in_the_Market/NaturalCosmetics"; -import ForgotPasswordForm from "./User/pages/ForgotPasswordForm"; // Popular Categories -import PopularCategories from "./User/pages/Popular_Categories/Popular_Categories"; +import PopularCategories from "./User/pages/Popular_Categories"; import BeautyWellness from "./User/pages/Popular_Categories/Beauty-Wellness"; import BodyCare from "./User/pages/Popular_Categories/Body-Care"; import CustomizedGifts from "./User/pages/Popular_Categories/Customized-Gifts"; @@ -74,217 +77,99 @@ import FurnitureDecor from "./User/pages/Popular_Categories/Furniture-Decor"; import HealthSupplements from "./User/pages/Popular_Categories/Health-Supplements"; import PrintingStationery from "./User/pages/Popular_Categories/Printing-Stationery"; -import { Helmet } from "react-helmet-async"; - -// Additional pages -import Blog from "./User/pages/Blog/Blog.jsx"; -import GiftcardPage from "./User/pages/AdditionalPages/GiftCardPage"; -import Sponsorships from "./User/pages/Sponsorships/Sponsorships"; -import Warranty from "./User/pages/Warranty/Warranty"; -import ProductCare from "./User/pages/ProductCare/ProductCare"; -import Subscription from "./User/pages/Subscription/Subscription"; -import Events from "./User/pages/Events/Events"; +// Admin +import AdminVerificationPage from "./User/pages/Admin-Verification"; +import AdminLayout from "./Admin/AdminLayout"; +import AdminLogin from "./Admin/Pages/AdminLogin"; +import VigyForm from "./Admin/Pages/VigyForm"; +import AdminPanel from "./Admin/Pages/AdminPanel"; +import ProductForm from "./Admin/Pages/ProductForm"; export default function App() { return ( - {/* Botpress chatbot script */} + - {/* User routes */} }> - } /> {/* Home page route */} - {/* Latest in the Market routes */} + } /> + + {/* Latest in Market */} } /> - } - /> + } /> } /> - } - /> - } - /> - } - /> - } - /> - } - /> + } /> + } /> + } /> + } /> } /> - } - /> - {/* Popular Categories routes */} + } /> + + {/* Popular Categories */} } /> - } - /> + } /> } /> - } - /> - } - /> - } - /> - } - /> - } - /> - } - /> - {/* Other user routes */} - } /> + } /> + } /> + } /> + } /> + } /> + } /> + + {/* Static pages */} } /> - } /> - } /> {/* Help page route */} - } /> - {/* Privacy policy page route */} - } /> - } - />{" "} - {/* Product details route */} - } /> - {/* Wishlist page route */} + } /> } /> - {/* Contact page route */} - } /> - {/* Forgot password page route */} - } /> {/* Team page route */} - } /> - {/* User authentication page route */} - } /> - } /> {/* FAQ page route */} + } /> + } /> } /> - {/* Terms and Conditions page route */} - } /> - {/* Feedback page route */} - } - /> - } /> - {/* Return and Cancellation page route */} - } />{" "} - {/* EPR page route */} - {/* Backward-compat: legacy URL */} - } - /> + } /> + } /> } /> } /> } /> } /> - {/* EPR page route */} - {/* Private routes requiring authentication */} + } /> + } /> + } /> + } /> + + {/* Auth & orders */} + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + + {/* Private */} }> - }> - } /> {/* Admin panel route */} - } /> - {/* Admin Vigy form route */} - } /> - {/* Admin product form route */} - } /> - {/* User dashboard route */} - } /> - {/* Order confirmation route */} - } /> - {/* Order cancellation route */} - } /> - {/* Order details route */} - } /> - {/* Backward-compatibility redirects */} - } - /> - } - /> - {/* My orders route */} - } /> - {/* Checkout route */} - } /> - {/* Product details route */} - } /> {/* Payment route */} } /> - {/* Dashboard orders route */} } /> - {/* Dashboard cart route */} } /> - {/* Dashboard wishlist route */} - } - /> - {/* Dashboard notifications route */} - {/* Not in use routes */} - } /> - {/* additional routes */} - } /> - } /> - } /> - } /> - } /> - } /> + } /> } /> - {/* Dashboard Profile route */} - {/* Certification page route */} - } /> - {/* Backward-compat: legacy URL */} - } - /> - {/* 404 Error page route */} + + } /> - {/* Admin routes */} + {/* Admin */} }> - } /> {/* Admin panel route */} + } /> } /> - {/* Admin Vigy form route */} } /> - {/* Admin product form route */} - {/* Admin verification and login routes */} - } /> } /> + } /> ); diff --git a/src/User/pages/Privacy-Policy/index.jsx b/src/User/pages/Privacy-Policy/index.jsx new file mode 100644 index 000000000..af2cd4b59 --- /dev/null +++ b/src/User/pages/Privacy-Policy/index.jsx @@ -0,0 +1,161 @@ +import React, { useEffect } from "react"; +import "./privacy.css"; + +// Lightweight loader for html2pdf.js via CDN +const loadHtml2Pdf = () => { + return new Promise((resolve, reject) => { + if (typeof window !== "undefined" && window.html2pdf) { + resolve(window.html2pdf); + return; + } + const script = document.createElement("script"); + script.src = + "https://cdn.jsdelivr.net/npm/html2pdf.js@0.12.0/dist/html2pdf.bundle.min.js"; + script.async = true; + script.crossOrigin = "anonymous"; + script.onload = () => resolve(window.html2pdf); + script.onerror = () => + reject(new Error("Failed to load html2pdf.js")); + document.body.appendChild(script); + }); +}; + +const Privacy = () => { + useEffect(() => { + document.title = "VigyBag | Privacy Policy"; + }, []); + + const generatePdf = async () => { + const element = document.getElementById("pdf-content"); + if (!element) return; + + const html2pdf = await loadHtml2Pdf(); + + const opt = { + margin: [20, 30, 30, 30], + filename: "privacy_policy.pdf", + image: { type: "jpeg", quality: 0.98 }, + html2canvas: { + scale: 2, + useCORS: true, + }, + jsPDF: { unit: "pt", format: "a4", orientation: "portrait" }, + pagebreak: { mode: ["css", "legacy"] }, + }; + + html2pdf().set(opt).from(element).save(); + }; + + return ( +
+
+
+ + {/* Header */} +

+ VigyBag Privacy Policy +

+

+ Last Updated: September 5, 2025 +

+ + {/* Sections */} +
+

+ We value the trust you place in us and recognize the importance of + secure transactions and information privacy. This Privacy Policy + describes how VigyBag Pvt. Ltd. and its affiliates (“VigyBag, we, + our, us”) collect, use, share, or otherwise process your personal + data through the VigyBag platform. +

+
+ +
+

+ Collection of Your Information +

+

+ When you use our Platform, we collect and store information + provided by you. You may choose not to provide certain data, + however some features may not be accessible. +

+
+ +
+

+ Use of Your Information +

+

+ We use your information to process orders, deliver services, + improve user experience, resolve disputes, and comply with legal + obligations. +

+
+ +
+

+ Cookies +

+

+ We use cookies to analyze traffic, personalize content, and + enhance security. You can control cookies through your browser + settings. +

+
+ +
+

+ Sharing of Personal Data +

+

+ We may share your data with partners and authorities when required + for legal, operational, or service-related reasons. +

+
+ +
+

+ Security Precautions +

+

+ We maintain reasonable safeguards to protect your personal data + from unauthorized access. +

+
+ +
+

+ Grievance Officer +

+ +
+ +
+ + {/* Download Button */} + +
+
+ ); +}; + +export default Privacy; +export { default } from "./Privacy"; diff --git a/src/User/pages/TermsAndCondition/index.jsx b/src/User/pages/TermsAndCondition/index.jsx new file mode 100644 index 000000000..22fa7a962 --- /dev/null +++ b/src/User/pages/TermsAndCondition/index.jsx @@ -0,0 +1,89 @@ +import React, { useEffect } from "react"; +import "./terms.css"; + +const TermsAndCondition = () => { + useEffect(() => { + document.title = "VigyBag | Terms & Conditions"; + }, []); + + return ( +
+
+
+ + {/* Header */} +

+ VigyBag Terms & Conditions +

+

+ Last Updated: September 5, 2025 +

+ + {/* Sections */} +
+

+ These Terms and Conditions govern your use of the VigyBag platform. + By accessing or using our services, you agree to be bound by these + terms. +

+
+ +
+

+ User Responsibilities +

+

+ Users agree to provide accurate information, comply with all + applicable laws, and refrain from misuse of the platform. +

+
+ +
+

+ Account & Security +

+

+ You are responsible for maintaining the confidentiality of your + account credentials and for all activities under your account. +

+
+ +
+

+ Orders & Payments +

+

+ All orders placed through VigyBag are subject to acceptance and + availability. Payments must be completed through approved + channels. +

+
+ +
+

+ Limitation of Liability +

+

+ VigyBag shall not be liable for any indirect, incidental, or + consequential damages arising from the use of the platform. +

+
+ +
+

+ Governing Law +

+

+ These terms shall be governed by and interpreted in accordance + with the laws of India. +

+
+ +
+
+
+ ); +}; + +export default TermsAndCondition; +export { default } from "./TermsAndCondition"; diff --git a/src/User/pages/UserAuth/index.jsx b/src/User/pages/UserAuth/index.jsx new file mode 100644 index 000000000..95af14ec4 --- /dev/null +++ b/src/User/pages/UserAuth/index.jsx @@ -0,0 +1 @@ +export { default } from "./UserAuth";