diff options
| author | Miqdad <ahmadmiqdad27@gmail.com> | 2025-10-15 23:27:23 +0700 |
|---|---|---|
| committer | Miqdad <ahmadmiqdad27@gmail.com> | 2025-10-15 23:27:23 +0700 |
| commit | dd1007165103e82f5d21ef9cb89f015be2310fb5 (patch) | |
| tree | e6b0e9344436c042c06a8dc96c11033342e25c1b | |
| parent | d690ac813611fbb4c275cad0aa586e59f9d93ffc (diff) | |
<Miqdad> line clamp product card desktop
| -rw-r--r-- | src/lib/product/components/ProductCard.jsx | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/lib/product/components/ProductCard.jsx b/src/lib/product/components/ProductCard.jsx index 14da22f3..34137482 100644 --- a/src/lib/product/components/ProductCard.jsx +++ b/src/lib/product/components/ProductCard.jsx @@ -195,7 +195,13 @@ const ProductCard = ({ product, simpleTitle, variant = 'vertical' }) => { <Link href={URL.product} aria-label={product?.name} - className={`mb-2 !text-gray_r-12 leading-6 block line-clamp-3 h-[64px]`} + className={`mb-2 !text-gray_r-12 leading-6 block`} + style={{ + WebkitLineClamp: 2, + display: '-webkit-box', + WebkitBoxOrient: 'vertical', + overflow: 'hidden', + }} title={product?.name} > {product?.name} @@ -494,7 +500,9 @@ const ProductCard = ({ product, simpleTitle, variant = 'vertical' }) => { {(product?.stockTotal > 0 || product?.qtySold > 0) && ( <div className='flex w-full items-center gap-x-2'> {product?.stockTotal > 0 && ( - <div className='badge-solid-red text-center'>Ready Stock</div> + <div className='badge-solid-red text-center'> + Ready Stock + </div> )} {product?.qtySold > 0 && ( |
