From cd7cb997a1b930bd6c659db54190b2cb86e2dc34 Mon Sep 17 00:00:00 2001 From: Nikhil Rajput Date: Mon, 28 Oct 2024 00:58:45 +0530 Subject: [PATCH] UI Updates and Fixes --- bun.lockb | Bin 300868 -> 300868 bytes package.json | 2 +- .../home/ui/AnimatedServiceCard.tsx | 12 +-- src/components/navbar/FloatingNavbar.tsx | 2 +- src/components/projects/Section1.tsx | 72 ------------------ src/components/projects/Section2.tsx | 21 ----- .../projects/components/ScreenshotGallery.tsx | 48 ------------ 7 files changed, 8 insertions(+), 149 deletions(-) delete mode 100644 src/components/projects/Section1.tsx delete mode 100644 src/components/projects/Section2.tsx delete mode 100644 src/components/projects/components/ScreenshotGallery.tsx diff --git a/bun.lockb b/bun.lockb index aec467c2d6fe71e7a4766c1123d76d261c2e4eab..83b7c67a9665300199a1e3cc9cb0bfc976cb0881 100755 GIT binary patch delta 345 zcmX@IPUy%wp@tU5ElltJGMng`PyhIrNs`fcI`=;&V@A{I_Wzh9>P_@4A{ZDLco-NO zq(oH(8do{lBN!MMco-NO zq(oH(8d-SZF32w~NiHsCh)Fzm>WvRaBT&YI z6=<4?`SjcWm<*XM^^B+U|7Vh5GBlp9`Jc(a+)U4ifnh(;JVl^+zh16-V%!05fQM>gc^IU;zxRN9PnG9Ks zjr0trH*zpbPZeR-XEdGa!tBRl0W^8)G-e;5Bc?uKP6h{C0SmK8dmJP4_BckCXHx-% Ckz=?3 diff --git a/package.json b/package.json index ebdd158..36aeebc 100644 --- a/package.json +++ b/package.json @@ -47,4 +47,4 @@ "tailwindcss-debug-screens": "^2.2.1", "typescript": "^5.6.3" } -} \ No newline at end of file +} diff --git a/src/components/home/ui/AnimatedServiceCard.tsx b/src/components/home/ui/AnimatedServiceCard.tsx index 08d5c27..c5e8489 100644 --- a/src/components/home/ui/AnimatedServiceCard.tsx +++ b/src/components/home/ui/AnimatedServiceCard.tsx @@ -66,12 +66,12 @@ const IconSkeleton = ({ item }: Readonly<{ item: IServiceItem }>) => { ], ]; - useEffect(() => { - animate(sequence, { - repeat: Infinity, - repeatDelay: 1, - }); - }, []); + // useEffect(() => { + // animate(sequence, { + // repeat: Infinity, + // repeatDelay: 1, + // }); + // }, []); return (
diff --git a/src/components/navbar/FloatingNavbar.tsx b/src/components/navbar/FloatingNavbar.tsx index 1882650..ffaeaf3 100644 --- a/src/components/navbar/FloatingNavbar.tsx +++ b/src/components/navbar/FloatingNavbar.tsx @@ -52,7 +52,7 @@ const FloatingNavbar = ({ {navItem.name} - + {navItem.name} diff --git a/src/components/projects/Section1.tsx b/src/components/projects/Section1.tsx deleted file mode 100644 index 7843491..0000000 --- a/src/components/projects/Section1.tsx +++ /dev/null @@ -1,72 +0,0 @@ -"use client"; - -import { useSearchParams } from "next/navigation"; -import Image from "next/image"; -import ResponsiveBox from "@/components/core/ResponsiveBox"; -import ConstraintedBox from "@/components/core/ConstraintedBox"; -import Row from "@/components/core/Row"; -import Column from "@/components/core/Column"; -import AppBar from "@/components/common/AppBar"; -import ScreenshotGallery from "./components/ScreenshotGallery"; -import { getProjectDetails } from "@/data/projects"; -import { ProjectType } from "@/types"; - -const ProjectsSection1 = ({ id }: Readonly<{ id?: string }>) => { - const searchParams = useSearchParams(); - const project = getProjectDetails(searchParams.get("id")!); - - const renderProjectType = (type?: ProjectType) => { - switch (type) { - case ProjectType.Personal: - return "Personal Project"; - - case ProjectType.JobWork: - return "Job Work"; - - case ProjectType.Freelance: - return "Freelance Project"; - - default: - return null; - } - }; - - return ( - - - - {project ? ( - - - {`project-${project.title}`} - - - -

{project?.title}

-

- {renderProjectType(project.projectType)} -

-
-
- ) : null} -
- - {project && project.screenshots && project.screenshots.length > 0 ? ( - - ) : null} -
-
- ); -}; - -export default ProjectsSection1; diff --git a/src/components/projects/Section2.tsx b/src/components/projects/Section2.tsx deleted file mode 100644 index 9d438f0..0000000 --- a/src/components/projects/Section2.tsx +++ /dev/null @@ -1,21 +0,0 @@ -"use client"; - -import { useSearchParams } from "next/navigation"; -import ResponsiveBox from "@/components/core/ResponsiveBox"; -import ConstraintedBox from "@/components/core/ConstraintedBox"; -import { getProjectDetails } from "@/data/projects"; - -const ProjectsSection2 = ({ id }: Readonly<{ id?: string }>) => { - const searchParams = useSearchParams(); - const description = getProjectDetails(searchParams.get("id")!)?.description; - - return ( - - -

{description}

-
-
- ); -}; - -export default ProjectsSection2; diff --git a/src/components/projects/components/ScreenshotGallery.tsx b/src/components/projects/components/ScreenshotGallery.tsx deleted file mode 100644 index 359edb5..0000000 --- a/src/components/projects/components/ScreenshotGallery.tsx +++ /dev/null @@ -1,48 +0,0 @@ -"use client"; - -import { usePathname, useSearchParams } from "next/navigation"; -import Link from "next/link"; -import Image from "next/image"; -import Row from "@/components/core/Row"; -import Column from "@/components/core/Column"; - -const ScreenshotGallery = ({ - imageList, -}: Readonly<{ imageList: string[] }>) => { - const pathname = usePathname(); - const searchParams = useSearchParams(); - - return ( - - - {imageList.map((img, index) => { - return ( - - {`screenshot-${index}`} - - ); - })} - - - ); -}; - -export default ScreenshotGallery;