How can I help you?
Accessibility in Angular Rating component
26 Feb 20264 minutes to read
The Rating component conforms to accessibility standards and guidelines, including ADA, Section 508, WCAG 2.2 standards, and WCAG roles commonly used to evaluate accessibility.
The accessibility compliance for the Rating component is outlined below.
| Accessibility Criteria | Compatibility |
|---|---|
| WCAG 2.2 Support | ![]() |
| Section 508 Support | ![]() |
| Screen Reader Support | ![]() |
| Right-To-Left Support | ![]() |
| Color Contrast | ![]() |
| Mobile Device Support | ![]() |
| Keyboard Navigation Support | ![]() |
| Accessibility Checker Validation | ![]() |
| Axe-core Accessibility Validation | ![]() |
- All features of the component meet the requirement.
- Some features of the component do not meet the requirement.
- The component does not meet the requirement.WAI-ARIA attributes
The Rating component followed the WAI-ARIA patterns to meet the accessibility. The following ARIA attributes are used in the Rating component:
| Attributes | Purpose |
|---|---|
role=slider |
Defines an interactive input where users select values within a specified range. |
role=button |
Identifies the reset button as a clickable element that resets the rating to its minimum value. |
aria-label |
Provides an accessible name for the Rating component. |
aria-valuemin |
Indicates the minimum value of the rating. |
aria-valuemax |
Indicates the maximum value of the rating. |
aria-valuenow |
Indicates the current value of the rating. |
aria-hidden |
Specifies whether the reset button is interactive. |
Keyboard interaction
The Rating component follows keyboard interaction guidelines to support users of assistive technologies and keyboard-only navigation. The following keyboard shortcuts enable efficient rating control.
| Keyboard shortcuts | Actions |
|---|---|
| Space | When Reset Button is focused, resets to min value. |
| Arrow Up | Increases the value. |
| Arrow Left | Decreases the value; in RTL mode, increases the value. |
| Arrow Down | Decreases the value. |
| Arrow Right | Increases the value; in RTL mode, decreases the value. |
Ensuring accessibility
The Rating component’s accessibility standards compliance is verified using the accessibility-checker and axe-core tools during automated testing. The following sample demonstrates the accessibility features of the Rating component. Open the sample in a new window to evaluate component accessibility with accessibility validation tools.