diff options
| author | Rafi Zadanly <zadanlyr@gmail.com> | 2023-02-20 13:09:22 +0700 |
|---|---|---|
| committer | Rafi Zadanly <zadanlyr@gmail.com> | 2023-02-20 13:09:22 +0700 |
| commit | fdefe7cfe899125a9bd553b542976eed0de919c1 (patch) | |
| tree | 0c3648d1e18249b42e7507847469c0ec87b933b7 | |
| parent | 58ab91f8a99a79e0dbae33cf71830e4d1646e264 (diff) | |
fix
| -rw-r--r-- | src/lib/cart/components/Cart.jsx | 5 | ||||
| -rw-r--r-- | src/pages/index.jsx | 8 |
2 files changed, 7 insertions, 6 deletions
diff --git a/src/lib/cart/components/Cart.jsx b/src/lib/cart/components/Cart.jsx index 0b6ea768..4b9dd41f 100644 --- a/src/lib/cart/components/Cart.jsx +++ b/src/lib/cart/components/Cart.jsx @@ -166,11 +166,12 @@ const Cart = () => { <div className="text-red_r-11 font-medium"> { currencyFormat(product?.price?.priceDiscount * product?.quantity) } </div> - <div className="flex gap-x-2"> + <div className="flex gap-x-1"> <button type="button" className="btn-light px-2 py-1" onClick={() => updateQuantity(1, product?.id, 'MINUS')} + disabled={product?.quantity == 1} > - </button> @@ -189,7 +190,7 @@ const Cart = () => { + </button> <button - className="btn-red p-1" + className="btn-red p-1 ml-1" onClick={() => setDeleteConfirmation(product)} > <TrashIcon className="w-4" /> diff --git a/src/pages/index.jsx b/src/pages/index.jsx index 6503ac20..4cb40adb 100644 --- a/src/pages/index.jsx +++ b/src/pages/index.jsx @@ -6,19 +6,19 @@ import PopularProductSkeleton from "@/lib/home/components/Skeleton/PopularProduc const BasicLayout = dynamic(() => import("@/core/components/layouts/BasicLayout")) const HeroBanner = dynamic(() => import("@/lib/home/components/HeroBanner"), { - loading: <ImageSkeleton /> + loading: () => <ImageSkeleton /> }) const PreferredBrand = dynamic(() => import("@/lib/home/components/PreferredBrand"), { - loading: <PopularProductSkeleton /> + loading: () => <PopularProductSkeleton /> }) const PopularProduct = dynamic(() => import("@/lib/home/components/PopularProduct"), { - loading: <PopularProductSkeleton /> + loading: () => <PopularProductSkeleton /> }) const CategoryHomeId = dynamic(() => import("@/lib/home/components/CategoryHomeId"), { - loading: <PopularProductSkeleton /> + loading: () => <PopularProductSkeleton /> }) export default function Home() { |
