mirror of
https://github.com/vercel/commerce.git
synced 2025-03-14 22:42:33 +00:00
use an anchor for the link to product
This commit is contained in:
parent
ee1051c2ca
commit
7b012564b0
@ -19,8 +19,6 @@ interface ProductData {
|
||||
}
|
||||
|
||||
const ProductCard: FC<Props> = ({ className, node: p, variant }) => {
|
||||
const rootClassName = cn(s.root, className)
|
||||
|
||||
if (variant === 'slim') {
|
||||
return (
|
||||
<div className="relative overflow-hidden box-border">
|
||||
@ -39,7 +37,7 @@ const ProductCard: FC<Props> = ({ className, node: p, variant }) => {
|
||||
|
||||
return (
|
||||
<Link href={`product${p.path}`}>
|
||||
<div className={rootClassName}>
|
||||
<a className={cn(s.root, className)}>
|
||||
<div className="absolute z-10 inset-0 flex items-center justify-center">
|
||||
<img
|
||||
className="w-full object-cover"
|
||||
@ -60,7 +58,7 @@ const ProductCard: FC<Props> = ({ className, node: p, variant }) => {
|
||||
<Heart />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
</Link>
|
||||
)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user