Skip to content

Commit c5fcf7d

Browse files
D-K-Pmatt-aitken
authored andcommitted
Improved page UI and layout
1 parent f42d810 commit c5fcf7d

2 files changed

Lines changed: 3 additions & 19 deletions

File tree

product-image-generator/app/ProductImageGenerator.tsx

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,6 @@ export default function ProductImageGenerator({
224224

225225
return (
226226
<div className="min-h-screen bg-gray-100/20 ">
227-
{/* Fixed Header */}
228227
<header className="sticky top-0 z-50 w-full border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60">
229228
<div className="container mx-auto px-4">
230229
<div className="flex h-14 items-center justify-between">
@@ -253,11 +252,9 @@ export default function ProductImageGenerator({
253252
</div>
254253
</header>
255254

256-
{/* Main Content */}
257255
<main className="container px-4 py-16 w-full mx-auto ">
258256
<div className="max-w-7xl mx-auto w">
259-
{/* Page Title */}
260-
<div className="mb-8 flex justify-between items-end">
257+
<div className="mb-8 flex justify-between items-end gap-8">
261258
<div>
262259
<h2 className="text-3xl font-bold text-foreground mb-2">
263260
Product Image Generator
@@ -288,9 +285,7 @@ export default function ProductImageGenerator({
288285
</div>
289286
</div>
290287

291-
{/* Top Row - Upload + 3 Generated Images */}
292288
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6 mb-8">
293-
{/* Upload card stays square */}
294289
<UploadCard
295290
triggerToken={triggerToken}
296291
onUploadComplete={handleUploadComplete}
@@ -318,10 +313,8 @@ export default function ProductImageGenerator({
318313
/>
319314
</div>
320315

321-
{/* Bottom Row - Sequential Custom Cards */}
322316
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6">
323317
{Array.from({ length: 4 }).map((_, index) => {
324-
// Always show CustomPromptCard, let it handle its own states
325318
return (
326319
<CustomPromptCard
327320
key={`custom-prompt-${index}`}
@@ -339,15 +332,6 @@ export default function ProductImageGenerator({
339332
);
340333
})}
341334
</div>
342-
343-
{/* Footer */}
344-
<div className="mt-12 text-center">
345-
{/* <p className="text-sm text-muted-foreground">
346-
Powered by{" "}
347-
<span className="font-medium text-primary">Trigger.dev</span> and{" "}
348-
349-
</p> */}
350-
</div>
351335
</div>
352336
</main>
353337
</div>

product-image-generator/app/components/GeneratedCard.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,9 +248,9 @@ export default function GeneratedCard({
248248
) : (
249249
// Show loading/waiting state
250250
<div className="h-full flex flex-col items-center justify-center p-6 text-center">
251-
<div className="w-12 h-12 rounded-lg flex items-center justify-center mb-4">
251+
<div className="w-12 h-12 rounded-lg bg-gray-300/20 flex items-center justify-center mb-4">
252252
{isTaskRunning && generationProgress === "generating" ? (
253-
<div className="animate-spin rounded-full h-6 w-6 border-b-2 border-primary">
253+
<div className="animate-spin h-6 w-6">
254254
<Loader2 className="h-6 w-6 text-gray-500" />
255255
</div>
256256
) : baseImageUrl && productAnalysis && !hasTriggered ? (

0 commit comments

Comments
 (0)