StarRatingInteractive

fun StarRatingInteractive(rating: Float, numberOfUsers: Int, onClick: () -> Unit, modifier: Modifier = Modifier, isCompressed: Boolean = false, translations: StarRating.Translations = StarRating.Translations(), interactionSource: MutableInteractionSource = remember { MutableInteractionSource() })

Displays the current rating of an item with an interactive number of users.

Star Rating Interactive

Star Rating Interactive Sample

Star Rating Interactive Compressed

Star Rating Interactive Compressed Sample

Parameters

rating

the rating of the item.

numberOfUsers

the number of users that have provided a ranking.

onClick

called when clicked.

modifier

the Modifier applied to the star rating. Note that star size is static.

isCompressed

if true a compressed view with only a single star is rendered.

translations

the StarRating.Translations semantics of the star rating. If null or empty, no semantics will be set.

interactionSource

the MutableInteractionSource representing the stream of Interactions.