From 78e6318c711aa1864e2e54688bca6c8670193779 Mon Sep 17 00:00:00 2001 From: shiva raj badu Date: Tue, 24 Mar 2026 16:08:32 +0545 Subject: [PATCH] refactor: enhance loading components with improved skeleton structure and styling --- .../(dashboard)/templates/loading.tsx | 103 ++++++++++-------- .../(dashboard)/theme/loading.tsx | 29 ++--- 2 files changed, 71 insertions(+), 61 deletions(-) diff --git a/electron/servers/nextjs/app/(presentation-generator)/(dashboard)/templates/loading.tsx b/electron/servers/nextjs/app/(presentation-generator)/(dashboard)/templates/loading.tsx index a6a5d2ca..7b41b3fd 100644 --- a/electron/servers/nextjs/app/(presentation-generator)/(dashboard)/templates/loading.tsx +++ b/electron/servers/nextjs/app/(presentation-generator)/(dashboard)/templates/loading.tsx @@ -1,58 +1,67 @@ import { Skeleton } from '@/components/ui/skeleton' import { Card } from '@/components/ui/card' -const Loading = () => { - return ( -
-
- {/* Header */} -
- - +const TemplateCardSkeleton = () => ( + + + +
+
+ {Array.from({ length: 4 }).map((_, i) => ( + + ))} +
+
+
+ + + +
+ +
+
+) - {/* Inbuilt Templates Section */} -
- -
- {Array.from({ length: 4 }).map((_, idx) => ( - -
-
- -
- - +const Loading = () => { + return ( +
+
+
+
+ +
+
-
- - -
- {Array.from({ length: 4 }).map((_, i) => ( - - ))} -
- - ))} -
-
+
- {/* Custom Templates Section */} -
-
- - -
-
- - -
-
-
-
- ) +
+
+ + + + + +
+ +
+
+ {Array.from({ length: 4 }).map((_, idx) => ( + + ))} +
+
+
+ + ) } export default Loading - diff --git a/electron/servers/nextjs/app/(presentation-generator)/(dashboard)/theme/loading.tsx b/electron/servers/nextjs/app/(presentation-generator)/(dashboard)/theme/loading.tsx index 39a7bb57..4b7e0cff 100644 --- a/electron/servers/nextjs/app/(presentation-generator)/(dashboard)/theme/loading.tsx +++ b/electron/servers/nextjs/app/(presentation-generator)/(dashboard)/theme/loading.tsx @@ -1,23 +1,20 @@ import { Skeleton } from '@/components/ui/skeleton' const ThemeCardSkeleton = () => ( -
- {/* Preview area */} -
- {/* Top badges */} -
+
+
+ +
- {/* Card preview */} -
+
- {/* Bottom info */} -
+
@@ -32,15 +29,20 @@ const ThemeCardSkeleton = () => ( const Loading = () => { return ( -
- {/* Tabs skeleton */} +
+
+ + +
+
-
+ + +
- {/* Theme cards grid */}
{Array.from({ length: 4 }).map((_, idx) => ( @@ -51,4 +53,3 @@ const Loading = () => { } export default Loading -