Rating is a useful component to judge content, or display content quality.
Overview
With Rating the user can rate content with a 1 to 5 star scale. A read
property can be applied for instances where the user is unable to add a score, but can view an aggregate of past ratings.
Usage
- Display the overall user-rated quality of content
- Vote on the quality of content
Sample
Accessibility
Rating should be accompanied by a Label, which provides context of the intent to support assistive technologies.
Keyboard navigation
Key | Function |
---|---|
Arrow left | Moves focus and selection to the previous item. If the current focus and selection is on the first item, focus and selection will cycle to the last item. |
Arrow right | Moves focus and selection to the next item. If the current focus and selection is on the last item, focus and selection will cycle to the first item. |
Arrow down | Moves focus and selection to the next item. |
Arrow up | Moves focus and selection to the previous item. |
Enter | Selects or unselects the focused item. |
Tab | Moves focus in and out of the component. |
Tab and Shift | Moves focus in and out of the component. |