From cbf64042a2cc95f1544c1c98933f3f179eaf59cc Mon Sep 17 00:00:00 2001 From: Komal Agarwal Date: Fri, 26 Jul 2024 21:52:41 +0530 Subject: [PATCH] skeleton loader --- components/new-resume.tsx | 23 +++++++++++++++++------ components/ui/skeleton.tsx | 8 ++++---- 2 files changed, 21 insertions(+), 10 deletions(-) diff --git a/components/new-resume.tsx b/components/new-resume.tsx index 3b10b67..cfb99b8 100644 --- a/components/new-resume.tsx +++ b/components/new-resume.tsx @@ -38,6 +38,7 @@ import { getRankSuffix } from "@/utils/format"; import CustomisationDrawer from "./CustomisationDrawer"; import ProfileTracking from "./ProfileTracking"; import ShareBtn from "./ShareBtn"; +import { Skeleton } from "./ui/skeleton"; interface GitHubProfile { name: string; bio: string; @@ -197,13 +198,23 @@ export function NewResume() { }; if (loading) { return ( -
-
-
-
-
+
+
+
+ +
+ + +
+
+
+ +
+ + +
+
-

We are fetching your data...

); } diff --git a/components/ui/skeleton.tsx b/components/ui/skeleton.tsx index d7e45f7..279daae 100644 --- a/components/ui/skeleton.tsx +++ b/components/ui/skeleton.tsx @@ -1,4 +1,4 @@ -import { cn } from "@/lib/utils" +import { cn } from "@/lib/utils"; function Skeleton({ className, @@ -6,10 +6,10 @@ function Skeleton({ }: React.HTMLAttributes) { return (
- ) + ); } -export { Skeleton } +export { Skeleton };