From 5d7585c575923cc91d27d437d69b77d38776e477 Mon Sep 17 00:00:00 2001 From: ikramBagban <107988060+IkramBagban@users.noreply.github.com> Date: Thu, 27 Feb 2025 20:54:03 +0530 Subject: [PATCH] design: update style of footer and appbar. and minimal but cool transition & animations --- apps/web/components/Appbar.tsx | 217 ++++++++++++++++------------ apps/web/components/Footer.tsx | 252 +++++++++++++++------------------ 2 files changed, 244 insertions(+), 225 deletions(-) diff --git a/apps/web/components/Appbar.tsx b/apps/web/components/Appbar.tsx index 0da92c93..1ab952d2 100644 --- a/apps/web/components/Appbar.tsx +++ b/apps/web/components/Appbar.tsx @@ -1,5 +1,6 @@ "use client"; +import { useState, useEffect } from "react"; import { SignInButton, SignedIn, SignedOut, UserButton } from "@clerk/nextjs"; import { Button } from "./ui/button"; import { Credits } from "./navbar/Credits"; @@ -7,105 +8,141 @@ import Link from "next/link"; import { motion } from "framer-motion"; export function Appbar() { + const [isScrolled, setIsScrolled] = useState(false); + + useEffect(() => { + const handleScroll = () => { + if (window.scrollY > 0) { + setIsScrolled(true); + } else { + setIsScrolled(false); + } + }; + + window.addEventListener("scroll", handleScroll); + return () => window.removeEventListener("scroll", handleScroll); + }, []); + return ( -
- + - -
- {/* Logo */} - - + + + - - - - - 100xPhoto - - - + + + + 100xPhoto + + + - {/* Auth & Pricing */} -
- - - - - - - + {/* Auth & Pricing */} +
+ + + + + + + + + - - - - -
+ +
- - -
+
+ + ); } diff --git a/apps/web/components/Footer.tsx b/apps/web/components/Footer.tsx index 06a5f209..d26977cf 100644 --- a/apps/web/components/Footer.tsx +++ b/apps/web/components/Footer.tsx @@ -3,12 +3,12 @@ import { Button } from "./ui/button"; export function Footer() { return ( -