improve image component styles

This commit is contained in:
Franco Arza
2020-10-26 21:01:00 -03:00
parent 037de93e65
commit 695a446314
4 changed files with 25 additions and 18 deletions

View File

@@ -122,9 +122,3 @@
.wishlistButton {
@apply w-10 h-10 flex ml-auto items-center justify-center bg-primary text-primary font-semibold text-xs leading-6 cursor-pointer;
}
.product-image {
position: absolute;
width: 100%;
height: 100%;
}

View File

@@ -70,17 +70,15 @@ const ProductCard: FC<Props> = ({
variant={p.variants.edges?.[0]!}
/>
</div>
<div className={cn(s.imageContainer)}>
<EnhancedImage
alt={p.name}
className={cn('w-full object-cover', s['product-image'])}
src={src}
width={imgWidth}
height={imgHeight}
priority={priority}
quality="90"
/>
</div>
<EnhancedImage
alt={p.name}
className="w-full object-cover"
src={src}
width={imgWidth}
height={imgHeight}
priority={priority}
quality="90"
/>
</a>
</Link>
)