summaryrefslogtreecommitdiff
path: root/src/lib/brand
diff options
context:
space:
mode:
authorRafi Zadanly <zadanlyr@gmail.com>2023-03-13 16:20:18 +0700
committerRafi Zadanly <zadanlyr@gmail.com>2023-03-13 16:20:18 +0700
commit1ef538546c0bdd9351baaed90b837f399584b460 (patch)
tree9e0c6c1ab34adecdfcdccf70e2159f219ed217b8 /src/lib/brand
parentd26133d39e7d9cd510fdc72d239303f4ba918bdd (diff)
category, brand, product popular, product category in desktop home page
Diffstat (limited to 'src/lib/brand')
-rw-r--r--src/lib/brand/components/BrandCard.jsx6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lib/brand/components/BrandCard.jsx b/src/lib/brand/components/BrandCard.jsx
index 1bcdb5ab..984a9fa6 100644
--- a/src/lib/brand/components/BrandCard.jsx
+++ b/src/lib/brand/components/BrandCard.jsx
@@ -1,18 +1,20 @@
import Image from '@/core/components/elements/Image/Image'
import Link from '@/core/components/elements/Link/Link'
+import useDevice from '@/core/hooks/useDevice'
import { createSlug } from '@/core/utils/slug'
const BrandCard = ({ brand }) => {
+ const { isMobile } = useDevice()
return (
<Link
href={createSlug('/shop/brands/', brand.name, brand.id)}
- className='py-1 px-2 rounded border border-gray_r-6 h-12 flex justify-center items-center'
+ className={`py-1 px-2 rounded border border-gray_r-6 flex justify-center items-center ${isMobile ? 'h-16' : 'h-24'}`}
>
{brand.logo && (
<Image
src={brand.logo}
alt={brand.name}
- className='h-full object-contain object-center'
+ className='h-full w-full object-contain object-center'
/>
)}
{!brand.logo && (