From fa502e6d72a9bef56dd3e619357417bafc56d2f8 Mon Sep 17 00:00:00 2001 From: Amritanshu Date: Sat, 26 Oct 2024 16:14:44 +0530 Subject: [PATCH] Made background white cart page updated --- src/app/(storefront)/cart/page.tsx | 110 +++++++++++-------------- src/app/(storefront)/products/page.tsx | 2 +- src/app/globals.css | 8 +- 3 files changed, 55 insertions(+), 65 deletions(-) diff --git a/src/app/(storefront)/cart/page.tsx b/src/app/(storefront)/cart/page.tsx index a11e923..444f873 100644 --- a/src/app/(storefront)/cart/page.tsx +++ b/src/app/(storefront)/cart/page.tsx @@ -3,7 +3,6 @@ import { Minus, Plus, Trash2 } from 'lucide-react'; import { Button } from '@/components/ui/button'; -import { Card, CardContent, CardFooter, CardHeader, CardTitle } from '@/components/ui/card'; import { Separator } from '@/components/ui/separator'; import { useCart } from '@/providers/cart'; @@ -11,69 +10,56 @@ export default function MyCartComponent() { const { cart, updateQuantity, removeItem } = useCart(); return ( -
-

My Cart

-
-
- {cart?.items?.map((item) => ( - - -
- {/* {item.name} */} -
-

- {item.product_title} ({item.variant_title}) -

-

₹{item.unit_price}

-
-
- - {item.quantity} - -
- -
-
-
- ))} +
+

My Cart

+
+ {cart?.items?.map((item) => ( +
+ {item.thumbnail && ( + {item.title} + )} +
+

+ {item.product_title} ({item.variant_title}) +

+

₹{item.unit_price}

+
+
+ + {item.quantity} + +
+ +
+ ))} +
+
+

Summary

+
+
+ Subtotal + ₹{cart?.subtotal?.toFixed(2)} +
+
+ Tax + ₹{cart?.tax_total?.toFixed(2)} +
-
- - - Order Summary - - -
-
- Subtotal - ₹{cart?.subtotal?.toFixed(2)} -
-
- Tax - ₹{cart?.tax_total?.toFixed(2)} -
-
-
- - - Total - ₹{cart?.total?.toFixed(2)} - -
- + +
+ Total + ₹{cart?.total?.toFixed(2)}
+ + Need Help? Call us at 9915020200
); diff --git a/src/app/(storefront)/products/page.tsx b/src/app/(storefront)/products/page.tsx index 57fb88d..684b32e 100644 --- a/src/app/(storefront)/products/page.tsx +++ b/src/app/(storefront)/products/page.tsx @@ -32,7 +32,7 @@ async function fetchProducts() { export default async function ProductsPage() { const products: HttpTypes.StoreProduct[] = await fetchProducts(); return ( -
+
{/* Products Grid */}