diff --git a/src/app/globals.css b/src/app/globals.css index ced1e17..9667b39 100644 --- a/src/app/globals.css +++ b/src/app/globals.css @@ -1,6 +1,11 @@ @tailwind base; @tailwind components; @tailwind utilities; + +body { + scroll-behavior: smooth; +} + @keyframes scroll { 0% { transform: translateY(0); diff --git a/src/app/teams/create/page.tsx b/src/app/teams/create/page.tsx index 92638ed..edb8936 100644 --- a/src/app/teams/create/page.tsx +++ b/src/app/teams/create/page.tsx @@ -3,63 +3,82 @@ import { Button } from "@/components/ui/button"; import { Input } from "@/components/ui/input"; import Image from "next/image"; import { useRouter } from "next/navigation"; -import { useState } from "react"; +import { useState } from "react"; import { toast } from "sonner"; -import { useSelector } from 'react-redux'; -import { RootState } from '@/config/store'; +import { useSelector } from "react-redux"; +import { RootState } from "@/config/store"; import createAxiosInstance from "@/config/AxiosProtectedRoute"; import { createNewTeamUrl } from "@/lib/API-URLs"; function CreateTeam() { const [teamName, setTeamName] = useState(""); - const user = useSelector((state:RootState)=>state.auth.user) + const user = useSelector((state: RootState) => state.auth.user); const router = useRouter(); const axiosInstance = createAxiosInstance(user.accessToken); - const createNewTeam = async() => { + const createNewTeam = async () => { try { - const res = await axiosInstance.post(createNewTeamUrl,{ - teamName + const res = await axiosInstance.post(createNewTeamUrl, { + teamName, }); - if(res.status === 200){ - router.push('/dashboard'); + if (res.status === 200) { + router.push("/dashboard"); toast.success("Team created Successfully"); } } catch (err) { - console.log(err); } }; - + return ( -
- logo -
-

- What should we call your team? -

-
- - setTeamName(e.target.value)} - /> + <> +
+
+
+ logo +
+

+ What should we call your team? +

+
+ + setTeamName(e.target.value)} + /> +
+
+ + +
+
+
-
- - +
+ Image
-
+ ); } diff --git a/src/components/shared/Footer.tsx b/src/components/shared/Footer.tsx index 9181a77..0c650a2 100644 --- a/src/components/shared/Footer.tsx +++ b/src/components/shared/Footer.tsx @@ -1,29 +1,7 @@ "use client"; -import React, {useEffect} from 'react'; -import Image from 'next/image'; -import Script from 'next/script'; - -const GoogleTranslateComponent = () => { - useEffect(() => { - // Load the Google Translate script - const script = document.createElement('script'); - script.src = "https://translate.google.com/translate_a/element.js?cb=loadGoogleTranslate"; - script.async = true; - document.body.appendChild(script); - // Define the Google Translate callback function - window.loadGoogleTranslate = () => { - new window.google.translate.TranslateElement({ - pageLanguage: 'en' - }, 'google_element'); - }; - - return () => { - // Clean up by removing the script - document.body.removeChild(script); - }; - }, []); -}; +import React from 'react'; +import Image from 'next/image'; const Footer: React.FC = () => { return ( @@ -50,27 +28,6 @@ const Footer: React.FC = () => {

-
-
-