Hide 'No Review' Badge for products with no reviews

Hi there,

We recently updated our Warehouse theme to Warehouse 2.8.2 and in the old theme, I was using the code below to hide the ‘No Review’ badge for products with no review and also for products that have reviews less than a specific amount.

.spr-badge[data-rating="0.0"] {
    visibility:hidden; display: none;
}

.spr-badge[data-rating="10.0"] {
    visibility:hidden; display: none;
}

However, in the new theme adding these codes to theme.css does not work anymore. I tried to find the right elements using Google Chrome’s inspection tool to replace them in the added code and target them properly but it does not show the new replacements for spr-badge & data-rating.

Please assist me as I need to get this fixed ASAP.

Thank you

2 Likes

Hi @arminik ,

Where are you getting the review data? Can you provide your website so we can take a look?

Hi,

We imported all the reviews in a csv file.

Here is the store’s address:

https://maestrobath.myshopify.com/

@arminik

yes, please add this code

  1. Go to Online Store->Theme->Edit code
  2. Asset->/theme.css ->paste below code at the bottom of the file.
.rating__stars[aria-label="0 out of 5 stars"], .rating__stars[aria-label="0 out of 5 stars"] + .rating__caption {display: none;}
1 Like

Thank you so much it actually worked!

How can I do the same thing, but to hide products with less than 5 reviews?

1 Like

@arminik

thanks can you please give product url which one hide?

1 Like

Yes definitely.

https://maestrobath.com/products/lucent-luxury-crystal-single-vanity-mirror-bronze

This is just one example. But I want to hide the reviews badge for products that have under 5 reviews.

Thank you

Can you share what the equivalent of the theme.css asset is for the studio theme?

1 Like

@PPUSA

yes, please share your store url so i will check and let you know

Thanks

It’s https://www.zeldaandharley.com

Thanks,

Penelope

1 Like

@PPUSA

yes, please try this code

  1. Go to Online Store->Theme->Edit code
  2. Asset->/base.css ->paste below code at the bottom of the file.
.spr-starrating.spr-summary-starrating span[aria-label="0 out of 5 stars"] {display: none !important;}

Thank you, this partially works but still leaves the test “no reviews”.

How do I remove this also for 0 reviews?

@KetanKumar mind looking at this for me please?

Thank you, this partially works but still leaves the test “no reviews”.

How do I remove this also for 0 reviews?