Appearance
Rating
ERating
is an efficient way to assign a rating to content to demonstrate its quality or performance in several domains. Demo Here
Usage
vue
<template>
<ERating v-model="rating" color="warning"/>
</template>
<script setup>
const rating = ref(3);
</script>
Props
For ERating
component, the following props are available:
Prop | Type | Default | Note |
---|---|---|---|
modelValue | Number | 0 | Current page state |
length | Number | 5 | Changes the number of rating icons. |
hover | Boolean | false | Hovering over the ratings determines a rating value. |
size | String | "md" | The ERating element has three predefined sizes: sm , md , lg . |
readOnly | Boolean | false | disables the ability to interact with the symbols. Displays data about the average rating level. |
icon | Object | {name: Star1 ,size: 24 ,type: linear } | Customizes the icon of ERating element. More Info about icons here |
color | String | "primary" | The given color is applied to the ERating - utility colors are supported (e.g primary or danger ). you'll find a list of built-in classes on the src/styles/_vars.scss page. |
Emits
The ERating
component contains following emits.
Emit | Description |
---|---|
update:modelValue | Emitted when the local ref's value is mutated. |