Star Rating

A star rating you set as a single score. Supports half stars, custom icons and an optional wrapper element. It is shown in the block inserter as Star Rating and registered as canvas-core/star-rating.

Select the block on a page and its own settings open in the sidebar, in the panels below:

The Star Rating settings in the block editor sidebar

Settings

Each setting is named exactly as the block editor names it, followed by what it does and what it starts as. Where a setting carries a Shown when line, it stays hidden until that condition is met, which is the usual reason a setting looks missing from the sidebar:

Content

  • RatingDefault5

    The score to show. Half values (e.g. 4.5) render a half icon.

  • Out OfDefault5

    How many icons are drawn in total.

  • Screen-Reader LabelDefaultEmpty

    Announced to screen readers in place of the icons. Leave empty to omit.

Settings

  • Full IconDefaultbi-star-fill

    Glyph drawn for each whole point of the score.

  • Half IconDefaultbi-star-half

    Glyph drawn for a trailing half point. Scores are rounded to the nearest half, so a 4.3 draws four whole icons and one half.

  • Empty IconDefaultbi-star

    Leave empty to draw nothing for the remaining score.

  • Icon ClassesDefaultEmpty

    Class names added to every icon, most often to colour the row.

  • Space Between IconsDefaultOn

    Separate the icons with a space. Turn off for a tightly packed run.

Layout

  • Wrapper Element

    None emits just the icons, for a design that places them directly inside its own box. Add wrapper classes in the Advanced panel.

    Choices: None (icons only).

Every Canvas block also carries the Animation, Scroll Effects and Advanced panels, which are described in Controls every Canvas block has.

Other blocks in Content: Background Video / Audio, Cascading Images, Charts, Circle Stack, Clients, Data Tables.

Was this page helpful?