diff --git a/frontend/public/images/aboutimage.png b/frontend/public/images/aboutimage.png index 91a5a49..3c55862 100644 Binary files a/frontend/public/images/aboutimage.png and b/frontend/public/images/aboutimage.png differ diff --git a/frontend/public/images/b.jpg b/frontend/public/images/b.jpg index a1895f0..84c3b7c 100644 Binary files a/frontend/public/images/b.jpg and b/frontend/public/images/b.jpg differ diff --git a/frontend/public/images/b14.png b/frontend/public/images/b14.png index ed9625d..7a564ab 100644 Binary files a/frontend/public/images/b14.png and b/frontend/public/images/b14.png differ diff --git a/frontend/public/images/b2.jpg b/frontend/public/images/b2.jpg index 62a1a16..85f4dfe 100644 Binary files a/frontend/public/images/b2.jpg and b/frontend/public/images/b2.jpg differ diff --git a/frontend/public/images/b5.jpg b/frontend/public/images/b5.jpg index d09432f..fd31c57 100644 Binary files a/frontend/public/images/b5.jpg and b/frontend/public/images/b5.jpg differ diff --git a/frontend/public/images/b6.jpg b/frontend/public/images/b6.jpg index 72383f7..d27f747 100644 Binary files a/frontend/public/images/b6.jpg and b/frontend/public/images/b6.jpg differ diff --git a/frontend/public/images/b8.png b/frontend/public/images/b8.png index ed73f26..68ff13f 100644 Binary files a/frontend/public/images/b8.png and b/frontend/public/images/b8.png differ diff --git a/frontend/public/images/c.png b/frontend/public/images/c.png index aa79ec5..cb6940f 100644 Binary files a/frontend/public/images/c.png and b/frontend/public/images/c.png differ diff --git a/frontend/public/images/contact.jpg b/frontend/public/images/contact.jpg index 3a9c2b7..67c0691 100644 Binary files a/frontend/public/images/contact.jpg and b/frontend/public/images/contact.jpg differ diff --git a/frontend/public/images/d.jpg b/frontend/public/images/d.jpg index c4a47a0..1931ca3 100644 Binary files a/frontend/public/images/d.jpg and b/frontend/public/images/d.jpg differ diff --git a/frontend/public/images/e.jpg b/frontend/public/images/e.jpg index 5a2120f..334e587 100644 Binary files a/frontend/public/images/e.jpg and b/frontend/public/images/e.jpg differ diff --git a/frontend/public/images/e1.png b/frontend/public/images/e1.png index c2d361a..de49d94 100644 Binary files a/frontend/public/images/e1.png and b/frontend/public/images/e1.png differ diff --git a/frontend/public/images/e11.jpg b/frontend/public/images/e11.jpg index 8a1cb5c..f3aec46 100644 Binary files a/frontend/public/images/e11.jpg and b/frontend/public/images/e11.jpg differ diff --git a/frontend/public/images/e13.jpg b/frontend/public/images/e13.jpg index 6b270dd..75c8fd3 100644 Binary files a/frontend/public/images/e13.jpg and b/frontend/public/images/e13.jpg differ diff --git a/frontend/public/images/e14.jpg b/frontend/public/images/e14.jpg index f0fdfb0..ba5700b 100644 Binary files a/frontend/public/images/e14.jpg and b/frontend/public/images/e14.jpg differ diff --git a/frontend/public/images/e15.png b/frontend/public/images/e15.png index 866f33d..93a00b5 100644 Binary files a/frontend/public/images/e15.png and b/frontend/public/images/e15.png differ diff --git a/frontend/public/images/e16.png b/frontend/public/images/e16.png index 5411cea..c00a67c 100644 Binary files a/frontend/public/images/e16.png and b/frontend/public/images/e16.png differ diff --git a/frontend/public/images/e17.jpg b/frontend/public/images/e17.jpg index 1695eb2..ed3eff0 100644 Binary files a/frontend/public/images/e17.jpg and b/frontend/public/images/e17.jpg differ diff --git a/frontend/public/images/e18pg.jpg b/frontend/public/images/e18pg.jpg index 7947c4c..abc86e3 100644 Binary files a/frontend/public/images/e18pg.jpg and b/frontend/public/images/e18pg.jpg differ diff --git a/frontend/public/images/e2.png b/frontend/public/images/e2.png index 11dad3d..6d8e4ff 100644 Binary files a/frontend/public/images/e2.png and b/frontend/public/images/e2.png differ diff --git a/frontend/public/images/e20.jpg b/frontend/public/images/e20.jpg index 4d8760c..b21157c 100644 Binary files a/frontend/public/images/e20.jpg and b/frontend/public/images/e20.jpg differ diff --git a/frontend/public/images/e21.jpg b/frontend/public/images/e21.jpg index 4973d39..785cb0a 100644 Binary files a/frontend/public/images/e21.jpg and b/frontend/public/images/e21.jpg differ diff --git a/frontend/public/images/e22.jpg b/frontend/public/images/e22.jpg index 329bfd6..07a613a 100644 Binary files a/frontend/public/images/e22.jpg and b/frontend/public/images/e22.jpg differ diff --git a/frontend/public/images/e23.jpg b/frontend/public/images/e23.jpg index a6519d5..612b3a4 100644 Binary files a/frontend/public/images/e23.jpg and b/frontend/public/images/e23.jpg differ diff --git a/frontend/public/images/e23jpg.jpg b/frontend/public/images/e23jpg.jpg index f42a06a..5c43b6c 100644 Binary files a/frontend/public/images/e23jpg.jpg and b/frontend/public/images/e23jpg.jpg differ diff --git a/frontend/public/images/e3.png b/frontend/public/images/e3.png index 362eaed..eb85f84 100644 Binary files a/frontend/public/images/e3.png and b/frontend/public/images/e3.png differ diff --git a/frontend/public/images/e4.png b/frontend/public/images/e4.png index d416378..701f666 100644 Binary files a/frontend/public/images/e4.png and b/frontend/public/images/e4.png differ diff --git a/frontend/public/images/e5.png b/frontend/public/images/e5.png index 52b29dd..7839b7f 100644 Binary files a/frontend/public/images/e5.png and b/frontend/public/images/e5.png differ diff --git a/frontend/public/images/e6.png b/frontend/public/images/e6.png index d2d5895..dd66bd0 100644 Binary files a/frontend/public/images/e6.png and b/frontend/public/images/e6.png differ diff --git a/frontend/public/images/e7.png b/frontend/public/images/e7.png index 4286096..61c94dd 100644 Binary files a/frontend/public/images/e7.png and b/frontend/public/images/e7.png differ diff --git a/frontend/public/images/e8.png b/frontend/public/images/e8.png index 9764a4a..ac8ce63 100644 Binary files a/frontend/public/images/e8.png and b/frontend/public/images/e8.png differ diff --git a/frontend/public/images/e9.png b/frontend/public/images/e9.png index 1be8b50..6665d13 100644 Binary files a/frontend/public/images/e9.png and b/frontend/public/images/e9.png differ diff --git a/frontend/public/images/f1.png b/frontend/public/images/f1.png index 552522e..f4f5f21 100644 Binary files a/frontend/public/images/f1.png and b/frontend/public/images/f1.png differ diff --git a/frontend/public/images/f2.png b/frontend/public/images/f2.png index 002eb84..29f9c8c 100644 Binary files a/frontend/public/images/f2.png and b/frontend/public/images/f2.png differ diff --git a/frontend/public/images/f3.png b/frontend/public/images/f3.png index a4f03a6..5d99ab0 100644 Binary files a/frontend/public/images/f3.png and b/frontend/public/images/f3.png differ diff --git a/frontend/public/images/g1.png b/frontend/public/images/g1.png index 6e1fe8d..94909a4 100644 Binary files a/frontend/public/images/g1.png and b/frontend/public/images/g1.png differ diff --git a/frontend/public/images/g2.png b/frontend/public/images/g2.png index f2a9ee6..e0e784a 100644 Binary files a/frontend/public/images/g2.png and b/frontend/public/images/g2.png differ diff --git a/frontend/public/images/g3.png b/frontend/public/images/g3.png index 3ca5750..a5828a6 100644 Binary files a/frontend/public/images/g3.png and b/frontend/public/images/g3.png differ diff --git a/frontend/public/images/l.jpg b/frontend/public/images/l.jpg index cfcfa1b..eefafb7 100644 Binary files a/frontend/public/images/l.jpg and b/frontend/public/images/l.jpg differ diff --git a/frontend/public/images/l.png b/frontend/public/images/l.png index fbe4d10..a34dadb 100644 Binary files a/frontend/public/images/l.png and b/frontend/public/images/l.png differ diff --git a/frontend/public/images/log.jpg b/frontend/public/images/log.jpg index 37ecc3a..e2b9022 100644 Binary files a/frontend/public/images/log.jpg and b/frontend/public/images/log.jpg differ diff --git a/frontend/public/images/login.jpg b/frontend/public/images/login.jpg index 2fd18af..0b63f04 100644 Binary files a/frontend/public/images/login.jpg and b/frontend/public/images/login.jpg differ diff --git a/frontend/public/images/m.png b/frontend/public/images/m.png index 2a44483..09176c3 100644 Binary files a/frontend/public/images/m.png and b/frontend/public/images/m.png differ diff --git a/frontend/public/images/moon.png b/frontend/public/images/moon.png index 136ffd9..eb9c0ac 100644 Binary files a/frontend/public/images/moon.png and b/frontend/public/images/moon.png differ diff --git a/frontend/public/images/r.jpg b/frontend/public/images/r.jpg index 993040d..a491209 100644 Binary files a/frontend/public/images/r.jpg and b/frontend/public/images/r.jpg differ diff --git a/frontend/public/images/r.png b/frontend/public/images/r.png index f896356..b6bedd8 100644 Binary files a/frontend/public/images/r.png and b/frontend/public/images/r.png differ diff --git a/frontend/public/images/sun.png b/frontend/public/images/sun.png index 6c35e41..fdf3922 100644 Binary files a/frontend/public/images/sun.png and b/frontend/public/images/sun.png differ diff --git a/frontend/public/images/w.jpg b/frontend/public/images/w.jpg index b32608c..fe0ebdd 100644 Binary files a/frontend/public/images/w.jpg and b/frontend/public/images/w.jpg differ diff --git a/frontend/public/images/y.png b/frontend/public/images/y.png index d4ab4ee..04f2a9a 100644 Binary files a/frontend/public/images/y.png and b/frontend/public/images/y.png differ diff --git a/frontend/src/App.js b/frontend/src/App.js index c6d094d..79eb2cb 100644 --- a/frontend/src/App.js +++ b/frontend/src/App.js @@ -1,74 +1,3 @@ -import React, { useState, useEffect } from "react"; -import { Routes, Route, Navigate } from "react-router-dom"; -import { useLocation } from "react-router-dom"; -import Navbar from "./components/Navbar/Navbar.js"; -import Hom from "./pages/Home/Hom.js"; -import Educ from "./components/Education/Educ.js"; -import Quiz from "./components/Quiz/Quiz.js"; -import Craft from "./components/Craft/Craft.js"; -import Sef from "./components/Sef/Sef.js"; -import Act from "./components/Act/Act.js"; -import Login from "./components/Login/Login.js"; -import Signup from "./components/Signup/Signup.js"; -import ForgotPassword from "./components/ForgotPassword/ForgotPassword.js"; -import Footer from "./components/Footer/Footer.js"; -import About from "./pages/About/About.js"; -import Loan from "./pages/Loan/Loan.js"; -import Dashboard from "./pages/Dashboard/Dashboard.js"; -import Contact from "./pages/Contact/Contact.js"; -import Error from "./pages/Error/index.js"; -import ContributorsPage from "./pages/Contributor/ContributorsPage.jsx"; -import Preloader from "./pages/Preloader/Preloader.jsx"; - -function App() { - const location = useLocation(); - - // Preloader logic - const [isPreloaderVisible, setIsPreloaderVisible] = useState(true); - - useEffect(() => { - const timer = setTimeout(() => { - setIsPreloaderVisible(false); - }, 5000); // Preloader visible for 5 seconds - - return () => clearTimeout(timer); - }, []); - - return ( - <> - {isPreloaderVisible ? ( - - ) : ( -
- {location.pathname !== "/page-not-found" && } -
- - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - -
- {(location.pathname !== "/login" && - location.pathname.toLowerCase() !== "/signup" && - location.pathname.toLowerCase() !== "/forgot-password" && - location.pathname.toLowerCase() !== "/page-not-found") &&
} -
- )} - - ); -} - -export default App; +version https://git-lfs.github.com/spec/v1 +oid sha256:6ad0afe06cfce969e1b2bbfce598784cf5a5b4a54e1c8c901a83422afe074e90 +size 2969 diff --git a/frontend/src/components/Act/Act.js b/frontend/src/components/Act/Act.js index 9781939..9aac86b 100644 --- a/frontend/src/components/Act/Act.js +++ b/frontend/src/components/Act/Act.js @@ -1,123 +1,3 @@ -import React from 'react' -import {useNavigate } from 'react-router-dom' -import { - MDBCard, - MDBCardTitle, - MDBCardText, - MDBCardBody, - MDBCardImage, - MDBRow, - MDBCol -} from 'mdb-react-ui-kit'; -function Act () { - - const navigate = useNavigate(); - const [goToSef, setGoToQuiz] = React.useState(false); - const [goToAct, setGoToCraft] = React.useState(false); - - if (goToSef) { - return navigate('/quiz'); - } - - if (goToAct) { - return navigate('/craft'); - } - return ( - - -
-
- - -
-
-
-
-

Activity Based Learning

-
- -
- -
- - - - - - - -
- General Knowledge Quiz -
-
- - Solve interesting quizes, test your knowledge and enjoy learning. - -
-
- -
- -
-
-
-
- - - - -
-
- - - - - - - -
- Art and Craft -
-
- - Outshine with your creativity and learn arand craft frrom best out of waste. - -
-
- -
-
- -
-
-
-
-
- - - - -
- - - - -
-
-
-
- - -
- -
-

© Edu@enyanjyoti. All rights reserved.

-
-
- - - - ); -}; - -export default Act; \ No newline at end of file +version https://git-lfs.github.com/spec/v1 +oid sha256:d61206153b88d51837580169669dffa09eaaf907b297aad23cb4e5b8dc3974ef +size 3329 diff --git a/frontend/src/components/Car/Car.js b/frontend/src/components/Car/Car.js index 8b13789..fd481aa 100644 --- a/frontend/src/components/Car/Car.js +++ b/frontend/src/components/Car/Car.js @@ -1 +1,3 @@ - +version https://git-lfs.github.com/spec/v1 +oid sha256:01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b +size 1 diff --git a/frontend/src/components/Concept/Concep.js b/frontend/src/components/Concept/Concep.js index c15a449..75711f5 100644 --- a/frontend/src/components/Concept/Concep.js +++ b/frontend/src/components/Concept/Concep.js @@ -1,23 +1,3 @@ -import React from 'react' -function Concep () { - return ( - <> -
-

Conceptual Learning

-
- -
- - -

Hindi Rhymes for Kids

-
-
- -

Mathematics basic Maths

-
- - - - ) -} -export default Concep \ No newline at end of file +version https://git-lfs.github.com/spec/v1 +oid sha256:88329d66dd7d7974a7d93c08013b729e867ebf864e4e9b313c6832605eed493f +size 897 diff --git a/frontend/src/components/Craft/Craft.js b/frontend/src/components/Craft/Craft.js index 3bfc622..0add857 100644 --- a/frontend/src/components/Craft/Craft.js +++ b/frontend/src/components/Craft/Craft.js @@ -1,116 +1,3 @@ -import React from 'react'; -import '../../pages/Home/Hom.css'; - - -function Craft() { - - return ( - -
-
-
-
-
-
-
-

Art and Craft

-

- Learn creative , become creative . -

-
-
-
-
-
-
-

1. Wall Hanging - Bamboo Sticks

-
-
- -
-
-
-
-
-

2.Home Decor- Old Diya DIY

-
-
- -
-
-
-
-
-

3.Ganesh Idol - Paper Clay

-
-
- -
-
-
-
-
-

4. Pen-Pencil holder - Waste Plastic bottles

-
-
- -
-
-
-
-
-

5. Wall paintings - Broken Bangles

-
-
- -
-
-
-
-
-

6. Beautiful Lantern - Waste items

-
-
- -
-
-
-
-
-

7. Garden Planters - Coconut shells

-
-
- -
-
-
-
-
-

8. Table Decor's - Waste LED Bulbs

-
-
- -
-
-
-
-
-

9.Flower Vase - Plastic Spoons

-
-
- -
-
-
-
-
-
-
-
-

© Edu@enyanjyoti. All rights reserved.

-
-
- ); -} - -export default Craft; +version https://git-lfs.github.com/spec/v1 +oid sha256:2b80ab5f95ed9973bace654f83de17928a4d7f6bc4c277a1454963d30d9a2197 +size 5543 diff --git a/frontend/src/components/Education/Educ.js b/frontend/src/components/Education/Educ.js index b6d1ef7..4c6f511 100644 --- a/frontend/src/components/Education/Educ.js +++ b/frontend/src/components/Education/Educ.js @@ -1,154 +1,3 @@ -import React from 'react' - -import { useNavigate } from 'react-router-dom'; -import { - MDBCard, - MDBCardTitle, - MDBCardText, - MDBCardBody, - MDBCardImage, - MDBRow, - MDBCol -} from 'mdb-react-ui-kit'; -function Educ () { - const navigate = useNavigate(); - const [goToSef, setGoToSef] = React.useState(false); - const [goToAct, setGoToAct] = React.useState(false); - - if (goToSef) { - return navigate('/sef'); - } - - if (goToAct) { - return navigate('/act'); - } - - return ( - <> -
- - -
-
-
-
-

“Education is the most powerful weapon which you can use to change the world.”

-
- -
- -
- - - - - - - -
- Conceptual Learning -
-
- - Building a foundation of brilliance through deep conceptual understanding. -Elevate your thinking, embrace conceptual learning's power and -See beyond the surface where concepts become the keys to wisdom. - -
-
- -
- -
-
-
-
- - - - -
-
- - - - - - - -
- Life Skills -
-
- - Empower yourself with life skills that last a lifetime by - Unlocking the secrets to a successful and fulfilling life.Craft a meaningful life with essential life skills. - -
-
- -
-
- -
-
-
-
-
- - - - -
-
- - - - - - - -
- Activity Based Learning -
-
- - Engage, explore, excel the magic of activity-based learning and -Hands-on learning for a head-start in life's journey. -Turn lessons into adventures with activity-based discovery. - -
-
- -
-
-
-
-
- -
- - - - - - - - -
-
-
-
- - -
- - - - - - - - ) -} -export default Educ; \ No newline at end of file +version https://git-lfs.github.com/spec/v1 +oid sha256:aae1eef29476fea4168f78a602494421c0d05511988f2a720cf456e856a0c46a +size 4586 diff --git a/frontend/src/components/Firebase/firebase.js b/frontend/src/components/Firebase/firebase.js index 4713e00..55ec3f7 100644 --- a/frontend/src/components/Firebase/firebase.js +++ b/frontend/src/components/Firebase/firebase.js @@ -1,32 +1,3 @@ -import { getAuth, GoogleAuthProvider, signInWithPopup } from 'firebase/auth'; -import firebase from 'firebase/compat/app'; -import 'firebase/compat/firestore'; - -const firebaseConfig = { - apiKey: "AIzaSyDifM4s528CHfhVV6pVbbjlLGtj3Nno5Lk", - authDomain: "final-fc5c7.firebaseapp.com", - projectId: "final-fc5c7", - storageBucket: "final-fc5c7.appspot.com", - messagingSenderId: "240345534935", - appId: "1:240345534935:web:f8790c2cd95f662777bb92", - measurementId: "G-588PM66RF7" //please add the measurement id here, current one is from another Firebase project -}; - -const app = firebase.initializeApp(firebaseConfig); -export const auth = getAuth(app); -export const db = firebase.firestore(app); - -// Google Authentication Function -export const signInWithGoogle = async () => { - const provider = new GoogleAuthProvider(); - try { - const result = await signInWithPopup(auth, provider); - // You can access the Google Access Token and User info here - const user = result.user; - console.log('User Info:', user); - return user; - } catch (error) { - console.error('Error signing in with Google:', error); - throw error; // Rethrow the error to handle it in the calling component - } -}; +version https://git-lfs.github.com/spec/v1 +oid sha256:0e8db5f9b2f02db4f92193f3c58bbeb5e5c65dd532185d29588a3a9fa96029cd +size 1196 diff --git a/frontend/src/components/Firebase/logout.js b/frontend/src/components/Firebase/logout.js index 7341053..1c3ab62 100644 --- a/frontend/src/components/Firebase/logout.js +++ b/frontend/src/components/Firebase/logout.js @@ -1,23 +1,3 @@ -// useLogout.js -import { useCallback } from 'react'; -import { useNavigate } from 'react-router-dom'; -import { auth } from './firebase'; // Ensure this path is correct - -const useLogout = () => { - const navigate = useNavigate(); - - const logoutUser = useCallback(async () => { - try { - await auth.signOut(); - console.log("User logged out successfully"); - navigate('/', { replace: true }); // Navigate to home after logging out - } catch (error) { - console.error("Error logging out:", error); - // Optional: Add user feedback here (e.g., a toast notification) - } - }, [navigate]); - - return logoutUser; // Return the logout function -}; - -export default useLogout; +version https://git-lfs.github.com/spec/v1 +oid sha256:f43b35c8dbcb405565d292aadebe1b408894962949d0b090db5f3805bb4b26df +size 742 diff --git a/frontend/src/components/Firebase/useAuth.js b/frontend/src/components/Firebase/useAuth.js index 2701a20..b903f05 100644 --- a/frontend/src/components/Firebase/useAuth.js +++ b/frontend/src/components/Firebase/useAuth.js @@ -1,21 +1,3 @@ -// useAuth.js -import { useEffect } from 'react'; -import { useNavigate } from 'react-router-dom'; -import { auth } from './firebase'; // Ensure this path is correct - -const useAuth = () => { - const navigate = useNavigate(); - - useEffect(() => { - const unsubscribe = auth.onAuthStateChanged((user) => { - if (!user) { - navigate('/', { replace: true }); // Redirect to home if no user is found - } - }); - - // Cleanup subscription on unmount - return () => unsubscribe(); - }, [navigate]); -}; - -export default useAuth; +version https://git-lfs.github.com/spec/v1 +oid sha256:93697673b84c2dacc1c90a7c170fac03094f1302386337163ad18b80de296b5c +size 580 diff --git a/frontend/src/components/Footer/Footer.js b/frontend/src/components/Footer/Footer.js index 3ecc91f..83b92c1 100644 --- a/frontend/src/components/Footer/Footer.js +++ b/frontend/src/components/Footer/Footer.js @@ -1,84 +1,3 @@ -import React from "react"; -import "./footer.css"; -import { FaInstagram, FaLinkedin, FaGithub } from "react-icons/fa"; -import { FaXTwitter } from "react-icons/fa6"; -import { Link } from 'react-router-dom'; - -function Footer() { - return ( - - ); -} - -export default Footer; +version https://git-lfs.github.com/spec/v1 +oid sha256:ebf1a4cf16aa8ffaab3991a7f6515fcc65729bf9ea6c3169e7f65b821ca7b3f4 +size 2395 diff --git a/frontend/src/components/ForgotPassword/ForgotPassword.js b/frontend/src/components/ForgotPassword/ForgotPassword.js index dd733d1..e02428e 100644 --- a/frontend/src/components/ForgotPassword/ForgotPassword.js +++ b/frontend/src/components/ForgotPassword/ForgotPassword.js @@ -1,82 +1,3 @@ -import React, { useState, useEffect } from "react"; -import { useNavigate } from "react-router-dom"; -import { auth } from "../Firebase/firebase"; -import { sendPasswordResetEmail } from "firebase/auth"; - -function Login() { - const [email, setEmail] = useState(""); - const [loading, setLoading] = useState(false); - const [message, setMessage] = useState(""); - const [error, setError] = useState(null); - const navigate = useNavigate(); - - const handleResetPassword = async (e) => { - e.preventDefault(); - setError(null); - setLoading(true); - try { - await sendPasswordResetEmail(auth, email); - setLoading(false); - setMessage("Password reset email sent! Please check your inbox."); - } catch (error) { - setLoading(false); - setError(error.message); - } - }; - - return ( -
-
-
-
-
-

Forgot Password

- {error &&
{error}
} - {message && ( -
{message}
- )} -
-
- - setEmail(e.target.value)} - required - /> -
- -
-

- Remember you password {" "} - navigate("/login")} - > - Login - -

-
-
-
-
-
- ); -} - -export default Login; +version https://git-lfs.github.com/spec/v1 +oid sha256:187f2d3caac4f8a3641c9c9ac6289793a6ac6014130c887c9f2281114a9eb36b +size 3470 diff --git a/frontend/src/components/GoogleButton/GoogleButton.js b/frontend/src/components/GoogleButton/GoogleButton.js index ac06266..f702602 100644 --- a/frontend/src/components/GoogleButton/GoogleButton.js +++ b/frontend/src/components/GoogleButton/GoogleButton.js @@ -1,36 +1,3 @@ -// src/components/GoogleButton/GoogleButton.js -import { GoogleAuthProvider, signInWithPopup } from 'firebase/auth'; -import React from 'react'; -import { FaGoogle } from 'react-icons/fa'; // Importing Google icon -import { auth } from '../Firebase/firebase'; - -const GoogleButton = () => { - const handleGoogleSignIn = async () => { - const provider = new GoogleAuthProvider(); - try { - const result = await signInWithPopup(auth, provider); - console.log('User signed in: ', result.user); // You can handle the user info as needed - } catch (error) { - console.error('Error during Google sign-in: ', error.message); - } - }; - - return ( -
- -
- ); -}; - -export default GoogleButton; +version https://git-lfs.github.com/spec/v1 +oid sha256:5786bacee7e4141b09911c2e48bca0d00f5dffafddbfee58635e654a874dad40 +size 1029 diff --git a/frontend/src/components/Login/Login.js b/frontend/src/components/Login/Login.js index 2a2aa39..3a8284c 100644 --- a/frontend/src/components/Login/Login.js +++ b/frontend/src/components/Login/Login.js @@ -1,136 +1,3 @@ -import React, { useEffect, useState } from "react"; -import { useSignInWithEmailAndPassword } from "react-firebase-hooks/auth"; -import { Link, useNavigate } from "react-router-dom"; -import { auth } from "../Firebase/firebase"; - -import GoogleButton from '../GoogleButton/GoogleButton'; // Import the GoogleButton - -import toast from "react-hot-toast"; -import Footer from "../Footer/Footer"; - - - -// LoginHeader Component -const LoginHeader = () => ( -

Login

-); - -// LoginForm Component -const LoginForm = ({ email, setEmail, password, setPassword, showPassword, setShowPassword, handleLogin, loading, error }) => ( -
- {error &&
{error.message}
} -
- - setEmail(e.target.value)} - required - /> -
-
- - setPassword(e.target.value)} - required - /> - setShowPassword(!showPassword)} - > - {showPassword ? "visibility_off" : "visibility"} - -
- -
-

Or

- -
-
-); - -// LoginFooter Component -const LoginFooter = ({ navigate }) => ( - <> -

- Don't have an account?{" "} - navigate("/signup")}> - Sign Up - -

-

- Forgot Password? -

- -); - -function Login() { - const regex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; - const [email, setEmail] = useState(""); - const [password, setPassword] = useState(""); - const [showPassword, setShowPassword] = useState(false); - const navigate = useNavigate(); - const [signInWithEmailAndPassword, user, loading, error] = useSignInWithEmailAndPassword(auth); - - const handleLogin = async (e) => { - e.preventDefault(); - if (!regex.test(email)) { - toast.error("Invalid Email"); - return; - } - await signInWithEmailAndPassword(email, password); - }; - - useEffect(() => { - const unsubscribe = auth.onAuthStateChanged((currentUser) => { - if (currentUser) { - navigate("/dashboard", { replace: true }); - } - }); - return () => unsubscribe(); - }, [navigate]); - - return ( -
-
-
-
-
- - - -
-
-
-
-
-
- ); -} - -export default Login; +version https://git-lfs.github.com/spec/v1 +oid sha256:8219151c9534f10d6403ffbcbfcc10af4ff36c8730330b7afa622f826654b2b5 +size 4343 diff --git a/frontend/src/components/Navbar/Navbar.js b/frontend/src/components/Navbar/Navbar.js index 85a49a4..db5ed7d 100644 --- a/frontend/src/components/Navbar/Navbar.js +++ b/frontend/src/components/Navbar/Navbar.js @@ -1,84 +1,3 @@ -import React, { useState } from "react"; -import { useNavigate, NavLink, Link } from "react-router-dom"; // Import NavLink for active links -import "./Navbar.css"; -import { IoIosMoon } from "react-icons/io"; -import { HiOutlineSun } from "react-icons/hi"; - -const navItems = [ - { path: "/", label: "Home" }, - { path: "/about", label: "About Us" }, - { path: "/contact", label: "Contact Us" }, - { path: "/loan", label: "Loan" }, - { path: "/contributors", label: "Contributors" }, -]; - -function Navbar() { - const [isDarkMode, setIsDarkMode] = useState(false); - const [isActive, setIsActive] = useState(false); - const navigate = useNavigate(); - - const handleModeToggle = () => { - setIsDarkMode(!isDarkMode); - }; - - const toggleNavbar = () => setIsActive((prev) => !prev); - const closeNavbar = () => setIsActive(false); - const handleLogoClick = () => { - navigate('/'); - closeNavbar(); - }; - - const renderNavLink = ({ path, label }) => ( -
  • - (isActive ? "nav-links active" : "nav-links")} - onClick={closeNavbar} - > - {label} - -
  • - ); - - return ( - - ); -} - -export default Navbar; +version https://git-lfs.github.com/spec/v1 +oid sha256:a618f2a3dca49325c2606c834fffd5a03d3fc184b0a7ce21acd7c44b854baa79 +size 2488 diff --git a/frontend/src/components/Quiz/Quiz.js b/frontend/src/components/Quiz/Quiz.js index f8765db..c4c41cb 100644 --- a/frontend/src/components/Quiz/Quiz.js +++ b/frontend/src/components/Quiz/Quiz.js @@ -1,145 +1,3 @@ -import React, { useState } from 'react'; -import './Quiz.css'; -function Quiz() { - const questions = [ - { - questionText: "What is the capital of France", - answerOptions: [ - { answerText: 'New York', isCorrect: false }, - { answerText: 'London', isCorrect: false }, - { answerText: 'Paris', isCorrect: true }, - { answerText: 'Dublin', isCorrect: false }, - ], - }, - { - questionText: "Who is the CEO of Tesla", - answerOptions: [ - { answerText: 'Elon Musk', isCorrect: true }, - { answerText: 'Jack Ma', isCorrect: false }, - { answerText: 'Bill Gates', isCorrect: false }, - { answerText: 'Steve Jobs', isCorrect: false }, - ], - }, - { - questionText: "When is India's Independence Day", - answerOptions: [ - { answerText: '11 Aug', isCorrect: false }, - { answerText: '16 Jun', isCorrect: false }, - { answerText: '12 Dec', isCorrect: false }, - { answerText: '15 Aug', isCorrect: true }, - ], - }, - { - questionText: "Who is the Prime Minister of India", - answerOptions: [ - { answerText: 'Manmohan Singh', isCorrect: false }, - { answerText: 'Narendra Modi', isCorrect: true }, - { answerText: 'Rahul Gandhi', isCorrect: false }, - { answerText: 'Amit Shah', isCorrect: false }, - ], - }, - { - questionText : "What is full form of WHO", - answerOptions : [ - {answerText : "World Hail Organization", isCorrect : false}, - {answerText : "Work Health Organization", isCorrect: false}, - {answerText : "World Health Organization", isCorrect : true}, - {answerText : "Work Health Organization", isCorrect :false}, - - ], - }, - { - questionText : "Who is the Iron Lady of India", - answerOptions : [ - {answerText : "Priyanka Gandhi", isCorrect : false}, - {answerText : "Sonia Gandhi", isCorrect: false}, - {answerText : "Pratiba Patil", isCorrect : true}, - {answerText : "Indira Gandhi", isCorrect :false}, - - ], - }, - { - questionText : "Name the largest ocean in the World", - answerOptions : [ - {answerText : "Indian Ocean", isCorrect : false}, - {answerText : "Pacific ocean", isCorrect: true}, - {answerText : "Atlantic Ocean", isCorrect : false}, - {answerText : "Artic Ocean", isCorrect :false}, - - ], - }, - { - questionText : "Who created Bitcoin", - answerOptions : [ - {answerText : "Satoshi Nakamoto", isCorrect : true}, - {answerText : " Kim Nakamoto", isCorrect: false}, - {answerText : "Bill Gates", isCorrect : false}, - {answerText : "Steve Jobs", isCorrect :false}, - - ], - }, - { - questionText : "Which continent is known as the 'Dark' continent", - answerOptions : [ - {answerText : "Asia", isCorrect : false}, - {answerText : "Africa", isCorrect: true}, - {answerText : "Australia", isCorrect : false}, - {answerText : "Europe", isCorrect :false}, - - ], - }, - { - questionText : "Which palnet is known as Red Planet", - answerOptions : [ - {answerText : "Earth", isCorrect : false}, - {answerText : "Saturn", isCorrect: false}, - {answerText : "Venus", isCorrect : false}, - {answerText : "Mars", isCorrect :true}, - - ], - }, - ]; - - const [currentQuestion, setCurrentQuestion] = useState(0); - const [showScore, setShowScore] = useState(false); - const [score, setScore] = useState(0); - - const handleAnswerButtonClick = (isCorrect) => { - if (isCorrect) { - - setScore(score + 1); - } - const nextQuestion = currentQuestion + 1; - if (nextQuestion < questions.length) { - setCurrentQuestion(nextQuestion); - } else { - setShowScore(true); - } - }; - - return ( -
    - {showScore ? ( -
    You scored {score} out of {questions.length}
    - - - ) : ( - <> -
    -
    - Question {currentQuestion + 1}/{questions.length} -
    -
    {questions[currentQuestion].questionText}
    -
    - {questions[currentQuestion].answerOptions.map((answerOption, index) => ( - - ))} -
    -
    - - )} -
    - ); -} - -export default Quiz; +version https://git-lfs.github.com/spec/v1 +oid sha256:6dd6e766999928d11a1760fd6da6be5cd23005fad34e58b4562209284bda8390 +size 4557 diff --git a/frontend/src/components/Register/Register.js b/frontend/src/components/Register/Register.js index ee8e0f4..c2c36bd 100644 --- a/frontend/src/components/Register/Register.js +++ b/frontend/src/components/Register/Register.js @@ -1,58 +1,3 @@ -import React, { useState } from 'react'; - -function Register() { - const [details, setDetails] = useState({ - fName: '', - email: '', - password: '' - }); - - const PostData = async (e) => { - e.preventDefault(); - - const { fName, email, password } = details; - - // Check if any of the fields are empty - if (!fName || !email || !password) { - alert("Please fill in all fields"); - return; - } - - const res = await fetch("https://vini-d981a-default-rtdb.firebaseio.com/vinform.json", { - method: 'POST', - headers: { - 'Content-Type': 'application/json' - }, - body: JSON.stringify({ - fName, - email, - password, - }) - }); - - // You can add further handling of the response here if needed - } - - return ( -
    - setDetails({ ...details, fName: e.target.value })} - /> - setDetails({ ...details, email: e.target.value })} - /> - setDetails({ ...details, password: e.target.value })} - /> - -
    - ); -} - -export default Register; +version https://git-lfs.github.com/spec/v1 +oid sha256:12856aba73a979528a5cbaca6855b9d58e0ebb6a3703138d67bb58ec36ace3d7 +size 1646 diff --git a/frontend/src/components/Sef/Sef.js b/frontend/src/components/Sef/Sef.js index 4f6dcb1..2bf12fe 100644 --- a/frontend/src/components/Sef/Sef.js +++ b/frontend/src/components/Sef/Sef.js @@ -1,112 +1,3 @@ -import React from 'react'; - -function Sef() { - return ( -
    -
    -
    -
    -
    -
    -
    -

    LIFE SKILLS

    -

    - Life isn't about finding yourself. Life is about creating yourself. -

    -
    -
    -
    -
    -
    -
    -

    1. LEADERSHIP - Lead the Future

    -
    -
    - -
    -
    -
    -
    -
    -

    2.STRESS MANAGEMENT-Be stress Free

    -
    -
    - -
    -
    -
    -
    -
    -

    3. CRITICAL THINKING - Think and grow

    -
    -
    - -
    -
    -
    -
    -
    -

    4. SELF-AWARENESS- Know about yourself

    -
    -
    - -
    -
    -
    -
    -
    -

    5. TIME MANAGEMENT- An aspect of life

    -
    -
    - -
    -
    -
    -
    -
    -

    6.SELF DEFENCE- Protect Yourself

    -
    -
    - -
    -
    -
    -
    -
    -

    7. SOFT SKILLS - Essential in today's era

    -
    -
    - -
    -
    -
    -
    -
    -

    8.FINANCIAL LITERACY- For financial development

    -
    -
    - -
    -
    -
    -
    -
    -

    9.INTERPERSONAL RELATIONSHIP -Connect

    -
    -
    - -
    -
    -
    -
    -
    -
    -
    -
    -

    © Edu@enyanjyoti. All rights reserved.

    -
    -
    - ); -} - -export default Sef; +version https://git-lfs.github.com/spec/v1 +oid sha256:4780af326871998e1b8f6d65092b9496975d310d8cdade7fb63142bee8103f89 +size 5342 diff --git a/frontend/src/components/Signup/Signup.js b/frontend/src/components/Signup/Signup.js index 8d2c37c..2b3bce9 100644 --- a/frontend/src/components/Signup/Signup.js +++ b/frontend/src/components/Signup/Signup.js @@ -1,236 +1,3 @@ -import React, { useEffect, useState } from "react"; -import { useCreateUserWithEmailAndPassword } from "react-firebase-hooks/auth"; -import { useNavigate } from "react-router-dom"; -import { registerValidation } from "../../validations/validation"; -import { auth, signInWithGoogle } from "../Firebase/firebase"; // Import Firebase auth and Google sign-in -import GoogleButton from '../GoogleButton/GoogleButton'; -import toast from "react-hot-toast"; -import Footer from "../Footer/Footer.js"; - -function Signup() { - const trustedDomains = ["gmail.com", "yahoo.com", "outlook.com", "icloud.com", "hotmail.com"]; - const regex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; - const [email, setEmail] = useState(""); - const [password, setPassword] = useState(""); - const [confirmPassword, setConfirmPassword] = useState(""); - const [error, setError] = useState(""); - const [successMessage, setSuccessMessage] = useState(""); - const [showPassword, setShowPassword] = useState(false); - const [showConfirmPassword, setShowConfirmPassword] = useState(false); - const [errors, setErrors] = useState({}); - const [emailError, setEmailError] = useState(""); // State for email validation feedback - const navigate = useNavigate(); - - const [createUserWithEmailAndPassword, user, loading, firebaseError] = - useCreateUserWithEmailAndPassword(auth); - - const handlePasswordVisibility = () => { - setShowPassword(!showPassword); - }; - - const handleConfirmPasswordVisibility = () => { - setShowConfirmPassword(!showConfirmPassword); - }; - - useEffect(() => { - const unsubscribe = auth.onAuthStateChanged((currentUser) => { - if (currentUser) { - navigate("/dashboard", { replace: true }); - } - }); - return () => unsubscribe(); - }, [navigate]); - - const handleSignup = async (e) => { - e.preventDefault(); - - // Check email format - if (!regex.test(email)) { - toast.error("Invalid email"); - return; - } - - // Check email domain - const emailDomain = email.split("@")[1]; - if (!trustedDomains.includes(emailDomain)) { - setEmailError("Please use a trusted email provider (Gmail, Yahoo, Outlook, iCloud, Hotmail)."); - return; - } else { - setEmailError(""); // Clear error if valid - } - - try { - await registerValidation.validate( - { email, password, confirmPassword }, - { abortEarly: false } - ); - setErrors({}); - } catch (error) { - const newErrors = {}; - error.inner.forEach((err) => { - newErrors[err.path] = err.message; - }); - - setErrors(newErrors); - return; - } - - // Firebase signup - try { - await createUserWithEmailAndPassword(email, password); - setSuccessMessage("Signup successful! Redirecting to login..."); - setEmail(""); - setPassword(""); - setConfirmPassword(""); - setTimeout(() => { - navigate("/login"); - }, 2000); // Redirect after 2 seconds - } catch (firebaseError) { - setError(firebaseError?.message || "Error signing up."); - } - }; - - const handleGoogleSignup = async () => { - try { - await signInWithGoogle(); - navigate("/dashboard"); // Redirect after successful Google sign-in - } catch (error) { - setError("Error signing in with Google."); - } - }; - - return ( - <> - -
    -
    -
    -
    -
    -

    Sign Up

    - {error &&
    {error}
    } - {successMessage && ( -
    {successMessage}
    - )} - {emailError &&
    {emailError}
    } {/* Email error message */} -
    -
    - - { - setEmail(e.target.value); - setEmailError(""); // Clear email error on change - }} - /> - {errors.email &&
    {errors.email}
    } -
    -
    - - setPassword(e.target.value)} - pattern="^(?=.*\d)(?=.*[a-zA-Z])(?=.*[^a-zA-Z0-9])\S{8,}$" - title="Password must contain at least one number, one alphabet, one symbol, and be at least 8 characters long" - required - /> - {errors.password &&
    {errors.password}
    } - - {showPassword ? "visibility_off" : "visibility"} - -
    - -
    - - setConfirmPassword(e.target.value)} - pattern="^(?=.*\d)(?=.*[a-zA-Z])(?=.*[^a-zA-Z0-9])\S{8,}$" - title="Password must contain at least one number, one alphabet, one symbol, and be at least 8 characters long" - required - /> - {errors.confirmPassword &&
    {errors.confirmPassword}
    } - - {showConfirmPassword ? "visibility_off" : "visibility"} - -
    - -
    -
    - -
    -

    - Already have an account?{" "} - navigate("/login")} - > - Login - -

    -
    -
    -
    -
    -
    -
    - - ); -} - -export default Signup; +version https://git-lfs.github.com/spec/v1 +oid sha256:b37e2222c62e929449f9defbbc0dc9dfc58b3212844f15d5d9f961c77a85218d +size 7705 diff --git a/frontend/src/components/profileCard/ProfileCard.js b/frontend/src/components/profileCard/ProfileCard.js index 55cd34f..7bbb457 100644 --- a/frontend/src/components/profileCard/ProfileCard.js +++ b/frontend/src/components/profileCard/ProfileCard.js @@ -1,46 +1,3 @@ -import React from 'react'; -import { useUser } from '../../UserContext'; - -const ProfileCard = () => { - const { user } = useUser(); - const [isEditing, setIsEditing] = useState(false); - - const handleEditToggle = () => { - setIsEditing(!isEditing); - }; - - const handleSave = () => { - setIsEditing(false); - } - - return ( -
    -

    Profile Information

    -

    Name: {user.name}

    -

    Role: {user.role}

    - -
    - ); -}; - -const styles = { - card: { - padding: '20px', - border: '1px solid #ddd', - borderRadius: '5px', - width: '300px', - margin: '10px auto', - textAlign: 'center', - boxShadow: '0 4px 8px rgba(0, 0, 0, 0.1)', - }, - button: { - padding: '10px 15px', - backgroundColor: '#6200ea', - color: '#fff', - border: 'none', - borderRadius: '5px', - cursor: 'pointer', - } -}; - -export default ProfileCard; +version https://git-lfs.github.com/spec/v1 +oid sha256:d91a986b1fbd2e533b2980c7dc6aefdd8d1ca2fae0fdb629a04a8ae8b27d4718 +size 985 diff --git a/frontend/src/index.js b/frontend/src/index.js index 63478bf..b0c0e2d 100644 --- a/frontend/src/index.js +++ b/frontend/src/index.js @@ -1,22 +1,3 @@ -import React from 'react'; -import 'bootstrap/dist/css/bootstrap.css'; -import 'bootstrap/dist/css/bootstrap.min.css'; -import ReactDOM from 'react-dom'; -import App from './App'; -import reportWebVitals from './reportWebVitals'; -import { BrowserRouter } from 'react-router-dom'; -import { Toaster } from "react-hot-toast"; - - -const root = document.getElementById('root'); -ReactDOM.render( - - - - - - , - root -); -reportWebVitals(); - +version https://git-lfs.github.com/spec/v1 +oid sha256:2b22625dbec47608e73d98fdccab125f1d08248f8198d04e8661c9abbe778bcd +size 530 diff --git a/frontend/src/pages/About/About.js b/frontend/src/pages/About/About.js index 4f6e452..28244fe 100644 --- a/frontend/src/pages/About/About.js +++ b/frontend/src/pages/About/About.js @@ -1,117 +1,3 @@ -import React from 'react'; -import { Swiper, SwiperSlide } from 'swiper/react'; -import { EffectCoverflow, Pagination, Navigation } from 'swiper/modules'; -import 'swiper/css'; -import 'swiper/css/effect-coverflow'; -import 'swiper/css/pagination'; -import 'swiper/css/navigation'; -import './About.css'; - -const About = () => { - const galleryData = [ - { - title: 'Introduction to Algebra', - subtitle: 'Master the basics of algebraic expressions and equations', - img: './images/1.jpg', - link: 'https://example.com/courses/introduction-to-algebra', - }, - { - title: 'Shakespearean Literature', - subtitle: 'Explore the works of William Shakespeare in depth', - img: './images/2.jpg', - link: 'https://example.com/courses/shakespearean-literature', - }, - { - title: 'World History', - subtitle: 'Understand key events that shaped our modern world', - img: './images/3.jpg', - link: 'https://example.com/courses/world-history', - }, - { - title: 'Introduction to Biology', - subtitle: 'Learn the fundamentals of life sciences', - img: './images/4.jpg', - link: 'https://example.com/courses/introduction-to-biology', - }, - { - title: 'Art History and Appreciation', - subtitle: - 'Explore the evolution of art through various cultures and eras', - img: './images/5.jpg', - link: 'https://example.com/courses/art-history-appreciation', - }, - { - title: 'Financial Literacy', - subtitle: 'Learn how to manage personal finances and investments', - img: './images/8.jpg', - link: 'https://example.com/courses/financial-literacy', - }, - { - title: 'Public Speaking Essentials', - subtitle: 'Develop confidence and skill in delivering speeches', - img: './images/11.jpg', - link: 'https://example.com/courses/public-speaking-essentials', - }, - ]; - - return ( -
    -
    -
    - About Us -
    -

    About Us

    -

    - Our platform offers a wide array of courses tailored to develop - your skills across diverse areas. In addition to this, we provide - professional career guidance and valuable insights into loans and - grants, ensuring you have the support needed to thrive in your - educational and career pursuits. -

    -
    -
    -
    - -
    -

    Our Gallery

    - - {galleryData.map((item, index) => ( - -
    - {item.title} -
    -
    -

    {item.title}

    - {item.subtitle} -
    -
    - ))} -
    -
    -
    - ); -}; - -export default About; +version https://git-lfs.github.com/spec/v1 +oid sha256:adacd84b27c31633b83ab23db33962c565eb1f57f9693a2fcc1cdcbdc9e60703 +size 3435 diff --git a/frontend/src/pages/Contact/Contact.js b/frontend/src/pages/Contact/Contact.js index e26da85..fb6665a 100644 --- a/frontend/src/pages/Contact/Contact.js +++ b/frontend/src/pages/Contact/Contact.js @@ -1,83 +1,3 @@ -import React, { useState } from "react"; -import { BsPerson, BsEnvelope } from "react-icons/bs"; - // Importing Bootstrap Icons for person and envelope icons -import './Contact.css' -function Contact() { - const [isSubmitted, setIsSubmitted] = useState(false); - - const handleSubmit = (event) => { - event.preventDefault(); - // Here you would typically handle the form submission, - // e.g., sending data to a server - setIsSubmitted(true); - }; - - return ( -
    -
    -
    Contact
    -
    -
    -

    We'd love to help

    -
    - - {isSubmitted ? ( -
    -

    Thank you for your message!

    -

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

    -
    - ) : ( -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    -
    - )} -
    -
    -
    - - ); -} - -export default Contact; +version https://git-lfs.github.com/spec/v1 +oid sha256:1bdc9711e33e719263e853f736225fba8e557ffcf1d9c7bcd1586a89d466ef91 +size 2939 diff --git a/frontend/src/pages/Contributor/ContributorsPage.jsx b/frontend/src/pages/Contributor/ContributorsPage.jsx index 8ca8267..002194b 100644 --- a/frontend/src/pages/Contributor/ContributorsPage.jsx +++ b/frontend/src/pages/Contributor/ContributorsPage.jsx @@ -1,239 +1,3 @@ -import React, { useEffect, useState } from 'react'; -import { motion, AnimatePresence } from 'framer-motion'; - -const ContributorCard = ({ login, avatar_url, html_url, contributions, type: initialType }) => { - const [type, setType] = useState(initialType); - - useEffect(() => { - if (login === 'skmirajulislam') { - setType('Admin'); - } else { - setType(initialType); - } - }, [login, initialType]); - - return ( - -
    - {login} -

    {login}

    -

    {type}

    -
    - {contributions} contributions -
    -
    -
    - - - - - - View Profile - - - - -
    -
    - ) -}; - - -const StatCard = ({ label, value, icon }) => ( - -
    - {icon} -
    -
    -

    {value}

    -

    {label}

    -
    -
    -); - -const ContributorsPage = () => { - const [contributors, setContributors] = useState([]); - const [repoStats, setRepoStats] = useState({}); - const [loading, setLoading] = useState(true); - const [email, setEmail] = useState(''); - - useEffect(() => { - const fetchData = async () => { - try { - const contributorsResponse = await fetch('https://api.github.com/repos/Vin205/Enyanjyoti/contributors'); - const contributorsData = await contributorsResponse.json(); - setContributors(contributorsData); - - const repoResponse = await fetch('https://api.github.com/repos/Vin205/Enyanjyoti'); - const repoData = await repoResponse.json(); - setRepoStats({ - stars: repoData.stargazers_count, - forks: repoData.forks_count, - openIssues: repoData.open_issues_count, - }); - } catch (error) { - console.error('Error fetching data:', error); - } finally { - setLoading(false); - } - }; - - fetchData(); - }, []); - - const handleSubmit = (e) => { - e.preventDefault(); - console.log('Submitted email:', email); - setEmail(''); - }; - - return ( - <> -
    - {/* Hero Section */} -
    -
    -
    - - Our Amazing Contributors - - - Shaping the future of Enyanjyoti, one commit at a time - - - - Become a Contributor - - -
    -
    - - {/* Stats Section */} -
    -
    -

    Project Statistics

    -
    - - - } - /> - sum + contributor.contributions, 0)} - icon={ - - } - /> - - - } - /> - - - } - /> -
    -
    -
    - - {/* Contributors Grid */} -
    -
    -

    Meet Our Contributors

    - - {loading ? ( - -
    -
    - ) : ( - - {contributors.map((contributor) => ( - - ))} - - )} -
    -
    -
    - - {/* Call to Action */} -
    -
    -

    Join Our Contributors

    -

    - Be a part of something great! Whether you're fixing bugs, adding features, or creating new ideas, your contributions matter. -

    -
    - setEmail(e.target.value)} - placeholder="Enter your email" - className="w-full max-w-md px-4 py-2 text-gray-800 border border-gray-300 rounded-lg focus:ring focus:ring-blue-500" - required - /> - -
    -
    -
    -
    - - ); -} - -export default ContributorsPage; \ No newline at end of file +version https://git-lfs.github.com/spec/v1 +oid sha256:4816026ca73fee7339c01c0bff28d36d566e2fe1aa565101ea5eef5c3aaaad13 +size 10710 diff --git a/frontend/src/pages/Dashboard/Dashboard.js b/frontend/src/pages/Dashboard/Dashboard.js index fdf7647..d5edd92 100644 --- a/frontend/src/pages/Dashboard/Dashboard.js +++ b/frontend/src/pages/Dashboard/Dashboard.js @@ -1,21 +1,3 @@ -import React from 'react'; -import useLogout from '../../components/Firebase/logout'; -import useAuth from '../../components/Firebase/useAuth'; - -const ExampleComponent = () => { - useAuth(); - const logout = useLogout(); - - const handleLogout = () => { - logout(); - }; - - return ( -
    -

    Welcome to the Example Component

    - -
    - ); -}; - -export default ExampleComponent; +version https://git-lfs.github.com/spec/v1 +oid sha256:525dcf5ec31dc3991b59a1ec6cb7dcd45ee3b0b360898158f9c244baab0b9a21 +size 484 diff --git a/frontend/src/pages/Error/index.js b/frontend/src/pages/Error/index.js index 3a13856..f1bb139 100644 --- a/frontend/src/pages/Error/index.js +++ b/frontend/src/pages/Error/index.js @@ -1,41 +1,3 @@ -/** @format */ - -import React from "react"; -import { Link } from "react-router-dom"; - -const Error = () => { - return ( -
    -
    -
    -
    -
    -
    -

    - Looks like you're lost -

    - -

    - The page you are looking for is not available! -

    - - - Home - -
    -
    -
    -
    - ); -}; - -export default Error; +version https://git-lfs.github.com/spec/v1 +oid sha256:f29129c31994dfc156e064b68d291d0c5d63bb943eb90d1b326709861a8cff62 +size 968 diff --git a/frontend/src/pages/Home/Faqs.jsx b/frontend/src/pages/Home/Faqs.jsx index 0eb6483..fa7fb78 100644 --- a/frontend/src/pages/Home/Faqs.jsx +++ b/frontend/src/pages/Home/Faqs.jsx @@ -1,82 +1,3 @@ -import React, { useState } from "react"; -import "./Faqs.css"; -import { Link } from "react-router-dom"; - -export default function Faqs() { - const [activeIndex, setActiveIndex] = useState(null); - - const faqs = [ - { - question: "What is the platform all about?", - answer: ( - - Our platform offers a wide range of courses, career advice, and - information about loans and grants to help you succeed. For more - details, visit our{" "} - - About Us - {" "} - page. - - ), - }, - { - question: "How can I sign up for a course?", - answer: ( - - To sign up, click on the{" "} - - Sign Up - {" "} - button at the top of the page, create an account, and explore - available courses. - - ), - }, - { - question: "What are the benefits of enrolling?", - answer: - "By enrolling, you gain access to exclusive learning materials, career guidance, and personalized support.", - }, - { - question: "How do I apply for loans and grants?", - answer: ( - - Visit the{" "} - - Loans and Grants - {" "} - section of our platform for a detailed guide on how to apply easily. - - ), - }, - ]; - - const toggleAnswer = (index) => { - setActiveIndex(activeIndex === index ? null : index); - }; - - return ( -
    -

    FAQs

    -
    - {faqs.map((faq, index) => ( -
    setActiveIndex(index)} - onMouseLeave={() => setActiveIndex(null)} - > -
    toggleAnswer(index)}> -

    {faq.question}

    - {activeIndex === index ? "-" : "+"} -
    - {activeIndex === index && ( -

    {faq.answer}

    - )} -
    - ))} -
    -
    - ); -} +version https://git-lfs.github.com/spec/v1 +oid sha256:986bea77dcc842e1d2e4c3491637d478262823c7e4207695d52e9fda05581f1d +size 2339 diff --git a/frontend/src/pages/Home/Hom.js b/frontend/src/pages/Home/Hom.js index 053ff78..ea4c6f6 100644 --- a/frontend/src/pages/Home/Hom.js +++ b/frontend/src/pages/Home/Hom.js @@ -1,122 +1,3 @@ -import React, { useEffect, useState } from "react"; -import { Link } from "react-router-dom"; -import "./Hom.css"; -import Faqs from "./Faqs"; - -export default function Hom() { - useEffect(() => { - const script = document.createElement("script"); - script.src = - "https://unpkg.com/@dotlottie/player-component@latest/dist/dotlottie-player.mjs"; - script.type = "module"; - document.body.appendChild(script); - - return () => { - document.body.removeChild(script); - }; - }, []); - - const [showScrollTop, setShowScrollTop] = useState(false); - - useEffect(() => { - const handleScroll = () => { - setShowScrollTop(window.scrollY > 120); - }; - - window.addEventListener("scroll", handleScroll); - return () => { - window.removeEventListener("scroll", handleScroll); - }; - }, []); - - const cardDetails = [ - { - title: "Education", - description: - "Get complete understanding of concepts. Adapt life skills. Gain general knowledge and enjoy activity-based learning.", - image: "./images/e3.png", - action: "Learn Now", - link: "https://wikiedu.org/" - }, - { - title: "Career", - description: - "Explore career opportunities and make yourself ready for employment in various fields. Learn how to build your own startup and become a successful entrepreneur.", - image: "./images/e4.png", - action: "Explore Now", - link: "https://en.wikipedia.org/wiki/Career" - }, - { - title: "Loans and Grants", - description: - "Complete information about loans, grants, and scholarships. Simple procedure and steps to apply easily.", - image: "./images/e5.png", - action: "Check Now", - link: "https://enyanjyoti.vercel.app/loan" - }, - ]; - - return ( -
    -
    - {showScrollTop && ( - - )} - -
    -
    - -
    -
    -

    - Dive into the World of Knowledge, Skills and Wisdom -

    -

    - Empower yourself with our comprehensive learning platform -

    -
    - - Sign Up - - - Login - -
    -
    -
    - -
    - {cardDetails.map((item, index) => ( -
    -
    -

    {item.title}

    -
    -
    - {item.title} -

    {item.description}

    - - - -
    -
    - ))} -
    - -
    - -
    -
    -
    - ); -} +version https://git-lfs.github.com/spec/v1 +oid sha256:15c06f319606630ba61e9a0978056288bc7d04d0695c6733c59373505487fd2d +size 4020 diff --git a/frontend/src/pages/Loan/Loan.js b/frontend/src/pages/Loan/Loan.js index 72caffe..8f34d4b 100644 --- a/frontend/src/pages/Loan/Loan.js +++ b/frontend/src/pages/Loan/Loan.js @@ -1,163 +1,3 @@ -import React, { useState } from 'react'; -import './Loan.css'; // Import your custom CSS file - -const Loan = () => { - const [loanAmount, setLoanAmount] = useState(''); - const [interestRate, setInterestRate] = useState(''); - const [loanTerm, setLoanTerm] = useState(''); - const [paymentFrequency, setPaymentFrequency] = useState('monthly'); - const [calculationResult, setCalculationResult] = useState(null); - - const calculateLoan = () => { - const principal = parseFloat(loanAmount); - const annualRate = parseFloat(interestRate) / 100; - const termInYears = parseFloat(loanTerm); - - if (isNaN(principal) || isNaN(annualRate) || isNaN(termInYears)) { - alert('Please enter valid numbers for all fields.'); - return; - } - - // Determine the number of payments per year and the interest rate per payment based on frequency - let paymentsPerYear; - if (paymentFrequency === 'monthly') { - paymentsPerYear = 12; - } else if (paymentFrequency === 'biweekly') { - paymentsPerYear = 26; - } else { - paymentsPerYear = 52; - } - - const ratePerPeriod = annualRate / paymentsPerYear; - const totalPayments = termInYears * paymentsPerYear; - - // Calculate the payment per period using the amortization formula - const paymentPerPeriod = (principal * ratePerPeriod * Math.pow(1 + ratePerPeriod, totalPayments)) / - (Math.pow(1 + ratePerPeriod, totalPayments) - 1); - - const totalPayment = paymentPerPeriod * totalPayments; - const totalInterest = totalPayment - principal; - - setCalculationResult({ - paymentPerPeriod: paymentPerPeriod.toFixed(2), - totalPayment: totalPayment.toFixed(2), - totalInterest: totalInterest.toFixed(2), - frequency: paymentFrequency.charAt(0).toUpperCase() + paymentFrequency.slice(1) - }); - }; - - return ( -
    -

    Understanding Loans and Grants

    - -
    -
    -

    What is a Loan?

    -

    - A loan is a sum of money that is borrowed and is expected to be paid back with interest. - Loans can be secured (backed by collateral) or unsecured (not backed by collateral). -

    - - - -
    - -
    -

    What is a Grant?

    -

    - A grant is a financial award given by a government agency, organization, or individual for a specific purpose, - and it does not need to be paid back. -

    - - - -
    - -
    -

    Types of Loans

    -
      -
    • Personal Loans
    • -
    • Student Loans
    • -
    • Mortgage Loans
    • -
    • Auto Loans
    • -
    - - - -
    -
    - -
    -

    Tips for Applying for Loans and Grants

    -
      -
    • Check your credit score before applying.
    • -
    • Research various options to find the best terms.
    • -
    • Gather necessary documentation in advance.
    • -
    • Be clear about your purpose and how you plan to use the funds.
    • -
    -
    - -
    -

    Loan Calculator

    -
    e.preventDefault()}> - - - - - -
    - {calculationResult && ( -
    -

    Loan Summary:

    -

    {calculationResult.frequency} Payment: ${calculationResult.paymentPerPeriod}

    -

    Total Payment: ${calculationResult.totalPayment}

    -

    Total Interest: ${calculationResult.totalInterest}

    -
    - )} -
    -
    - ); -}; - -export default Loan; +version https://git-lfs.github.com/spec/v1 +oid sha256:bf5322c2ecfbc917f57fe7ce3a5fa72907bbe7ad020f7498061e7e7c5a90efcc +size 7404 diff --git a/frontend/src/pages/Preloader/Preloader.jsx b/frontend/src/pages/Preloader/Preloader.jsx index a2966d4..7b78499 100644 --- a/frontend/src/pages/Preloader/Preloader.jsx +++ b/frontend/src/pages/Preloader/Preloader.jsx @@ -1,22 +1,3 @@ -import "./Preloader.css"; - -const Preloader = () => { - return ( -
    - - - E-NYANJYOTI - - -
    - ); -}; - -export default Preloader; +version https://git-lfs.github.com/spec/v1 +oid sha256:310959c16bc85e9f772d7b3e1ad31edd23e1398244592a186658fe41a7185948 +size 417 diff --git a/frontend/src/pages/career/career.js b/frontend/src/pages/career/career.js index e53e4ff..d370328 100644 --- a/frontend/src/pages/career/career.js +++ b/frontend/src/pages/career/career.js @@ -1,84 +1,3 @@ -import React, { useState } from "react"; -import "./Career.css"; // Add this line to import the CSS - -const Career = () => { - const [activeTab, setActiveTab] = useState("explore"); - - const careerSections = [ - { - id: "explore", - title: "Explore Careers", - content: - "Discover a wide range of career paths across various industries. Our comprehensive guides provide insights into job roles, required skills, and growth opportunities.", - }, - { - id: "prepare", - title: "Career Preparation", - content: - "Get ready for your dream job with our career preparation resources. Learn about resume writing, interview techniques, and professional development strategies.", - }, - { - id: "entrepreneurship", - title: "Entrepreneurship", - content: - "Interested in starting your own business? Explore our entrepreneurship resources to learn about business planning, funding options, and startup strategies.", - }, - ]; - - const careerTips = [ - "Network actively in your industry", - "Continuously update your skills", - "Seek mentorship opportunities", - "Build a strong online presence", - "Stay informed about industry trends", - ]; - - return ( -
    -

    Shape Your Future Career

    - -
    - {careerSections.map((section) => ( - - ))} -
    - -
    - {careerSections.map((section) => ( -
    -

    {section.title}

    -

    {section.content}

    -
    - ))} -
    - -
    -

    Career Success Tips

    -
      - {careerTips.map((tip, index) => ( -
    • {tip}
    • - ))} -
    -
    - -
    -

    Ready to Take the Next Step?

    -

    Explore our resources and start building your dream career today!

    - -
    -
    - ); -}; - -export default Career; +version https://git-lfs.github.com/spec/v1 +oid sha256:a2ab8a2d8c631c368810b82a5d2c1cb01ed22bb68acfcd9d968d90354342f878 +size 2527 diff --git a/frontend/src/reportWebVitals.js b/frontend/src/reportWebVitals.js index 5253d3a..4cbfd61 100644 --- a/frontend/src/reportWebVitals.js +++ b/frontend/src/reportWebVitals.js @@ -1,13 +1,3 @@ -const reportWebVitals = onPerfEntry => { - if (onPerfEntry && onPerfEntry instanceof Function) { - import('web-vitals').then(({ getCLS, getFID, getFCP, getLCP, getTTFB }) => { - getCLS(onPerfEntry); - getFID(onPerfEntry); - getFCP(onPerfEntry); - getLCP(onPerfEntry); - getTTFB(onPerfEntry); - }); - } -}; - -export default reportWebVitals; +version https://git-lfs.github.com/spec/v1 +oid sha256:714851669856152806c289f9aac6240b414bbac50c60ee4f7e6247f31eac0c1c +size 362 diff --git a/frontend/src/setupTests.js b/frontend/src/setupTests.js index 8f2609b..7caaab3 100644 --- a/frontend/src/setupTests.js +++ b/frontend/src/setupTests.js @@ -1,5 +1,3 @@ -// jest-dom adds custom jest matchers for asserting on DOM nodes. -// allows you to do things like: -// expect(element).toHaveTextContent(/react/i) -// learn more: https://github.com/testing-library/jest-dom -import '@testing-library/jest-dom'; +version https://git-lfs.github.com/spec/v1 +oid sha256:22583759d0045fdf8d62c9db0aacba9fd8bddde79c671aa08c97dcfd4e930cc6 +size 241 diff --git a/frontend/src/validations/validation.js b/frontend/src/validations/validation.js index df45b27..bcd9796 100644 --- a/frontend/src/validations/validation.js +++ b/frontend/src/validations/validation.js @@ -1,24 +1,3 @@ -import * as yup from "yup"; - -export const loginValidation = yup.object().shape({ - email: yup - .string() - .email("Email format invalid") - .required("Email is required"), - password: yup.string().required("Password is required"), -}); - -export const registerValidation = yup.object().shape({ - email: yup - .string() - .email("Invalid email format") - .required("Email is required"), - password: yup - .string() - .min(6, "Password should be at least 6 characters") - .required("Password is required"), - confirmPassword: yup - .string() - .oneOf([yup.ref("password"), null], "Passwords must match") - .required("Confirm password is required"), -}); +version https://git-lfs.github.com/spec/v1 +oid sha256:8b8535bd6b3f069f04df38d2fa2f2d75ab32c8416df828bb9fe5e51b439ebc26 +size 673