Rating component not visible.

1 Answer 65 Views
Rating
Aaron
Top achievements
Rank 1
Aaron asked on 17 Apr 2023, 09:45 PM

I've tried to use the Rating component with the below code. But the icons aren't rendering.

import { Rating } from "@progress/kendo-react-inputs";

function RatingExample() {
  return <Rating />
}

export default RatingExample;

Taking a quick peak into the html shows a list of span - which makes sense.

<span dir="ltr" data-half="false" title="1" class="k-rating-item"><span class="k-icon k-i-star-outline-icon" role="presentation"></span></span>

The Icon is different from the one listed here. To check it I made a quick change:

<span class="k-icon k-i-star-outline" role="presentation"></span>

And it shows up.

It seems like there a small bug here, if I'm using the component wrong please advise.

1 Answer, 1 is accepted

Sort by
1
Wissam
Telerik team
answered on 19 Apr 2023, 07:01 AM

Hi, Aaron,

The span should show the `k-icon k-i-star-outline` class instead of `k-icon k-i-star-outline-icon` which does not exist as a font-icon.

I tested the Rating component but I was not able to reproduce the issue. Therefore, could you please send me a runnable example where the faced issue is present? You can use this test sample as a base:

Could you also tell me the version of the component that you are using as well as the version of `kendo-themes`?

Regards,
Wissam
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Aaron
Top achievements
Rank 1
commented on 19 Apr 2023, 05:15 PM

I followed your stackblitz link. Turns out I needed to use the latest version of `kendo-svg-icons`. Thanks!
Wissam
Telerik team
commented on 20 Apr 2023, 11:39 AM

You are welcome, Aaron! I am glad that my reply was helpful to you.
Tags
Rating
Asked by
Aaron
Top achievements
Rank 1
Answers by
Wissam
Telerik team
Share this question
or