diff --git a/index.html b/index.html index c615b80..ea99a77 100644 --- a/index.html +++ b/index.html @@ -14,8 +14,8 @@ - +
diff --git a/package-lock.json b/package-lock.json index 2a99034..fb886d0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,6 +11,7 @@ "@reduxjs/toolkit": "^2.1.0", "aos": "^2.3.4", "bootstrap": "^5.3.2", + "gsap": "^3.12.4", "framer-motion": "^10.18.0", "react": "^18.2.0", "react-bootstrap-icons": "^1.10.3", @@ -2778,6 +2779,11 @@ "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==", "dev": true }, + "node_modules/gsap": { + "version": "3.12.4", + "resolved": "https://registry.npmjs.org/gsap/-/gsap-3.12.4.tgz", + "integrity": "sha512-1ByAq8dD0W4aBZ/JArgaQvc0gyUfkGkP8mgAQa0qZGdpOKlSOhOf+WNXjoLimKaKG3Z4Iu6DKZtnyszqQeyqWQ==" + }, "node_modules/has-bigints": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", diff --git a/package.json b/package.json index 2e12877..ab0543e 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,7 @@ "@reduxjs/toolkit": "^2.1.0", "aos": "^2.3.4", "bootstrap": "^5.3.2", + "gsap": "^3.12.4", "framer-motion": "^10.18.0", "react": "^18.2.0", "react-bootstrap-icons": "^1.10.3", diff --git a/src/App.jsx b/src/App.jsx index 57428b5..b34243e 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -1,8 +1,10 @@ -import { BrowserRouter as Router, Routes, Route } from "react-router-dom" +import React, { useEffect } from 'react'; +import gsap from 'gsap'; +import { ScrollTrigger } from 'gsap/ScrollTrigger'; +import { BrowserRouter as Router, Routes, Route } from 'react-router-dom'; import Devmate from "./Pages/Devmate"; import Aos from "aos"; import "aos/dist/aos.css" -import React from "react"; import Header from "./Components/Header"; import Hero from "./Components/Hero"; import About from "./Components/About"; @@ -13,6 +15,10 @@ import Team from "./Components/Team"; import FAQs from "./Components/FAQs"; import ContactUs from "./Components/ContactUs"; import Footer from "./Components/Footer"; +import Circle from "./Components/Circle"; + +gsap.registerPlugin(ScrollTrigger); + import useScript from "./Hooks/useScript"; import SignIn from "./Components/SignIn"; import { useDispatch, useSelector } from "react-redux"; @@ -24,6 +30,15 @@ function App() { const dispatch = useDispatch() const user = useSelector(state => state.user.user) React.useEffect(() => { + gsap.to('body', { + backgroundColor: '#E2A9FF', + scrollTrigger: { + trigger: 'body', + start: 'top top', + end: 'bottom bottom', + scrub: true, + }, + }); Aos.init() }, []) useScript("/js/main.js") @@ -58,6 +73,7 @@ function Home() { <>