Skip to content

Commit

Permalink
Added img alt attribute
Browse files Browse the repository at this point in the history
  • Loading branch information
Aayush259 committed Jul 21, 2024
1 parent 4c3dcdf commit 6e11da6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/home/ProductCategoryCard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export default function ProductCategoryCard({ categoryName, categoryImg }) {
to={`/E-Commerce/products/category/${categoryName}`}
className="flex flex-col items-center justify-center gap-2 max-w-[90vw] m-auto hover:outline"
>
<img src={categoryImg} alt="earphone" className="h-60 max-w-[80%] md:max-w-fit" />
<img src={categoryImg} alt={categoryName} className="h-60 max-w-[80%] md:max-w-fit" />
<p className="text-lg md:text-2xl tracking-wider">
{categoryName}
</p>
Expand Down
2 changes: 1 addition & 1 deletion src/components/products/ProductCard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export default function ProductCard({ productDetails }) {
</button>

<Link to={`/E-Commerce/products/${productName}`}>
<img src={productImg} alt="" className="block m-auto h-60" />
<img src={productImg} alt={productName} className="block m-auto h-60" />

<div className="flex flex-row items-start justify-between my-4">
<p className="font-semibold text-slate-900">
Expand Down

0 comments on commit 6e11da6

Please sign in to comment.