Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Commit

Permalink
Add label to Reviews by Product controls count
Browse files Browse the repository at this point in the history
  • Loading branch information
Aljullu committed Jul 3, 2019
1 parent fc622cb commit a97c9fa
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions assets/js/blocks/reviews-by-product/block.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,16 +125,25 @@ class ReviewsByProduct extends Component {
return (
<SearchListItem
{ ...args }
countLabel={ sprintf(
_n(
'%d Review',
'%d Reviews',
item.rating_count,
'woo-gutenberg-products-block'
),
item.rating_count
) }
showCount
aria-label={ sprintf(
_n(
'%s, has %d review',
'%s, has %d reviews',
item.count,
item.rating_count,
'woo-gutenberg-products-block'
),
item.name,
item.count
item.rating_count
) }
/>
);
Expand Down

0 comments on commit a97c9fa

Please sign in to comment.