Skip to main content
U.S. Flag

An official website of the United States government

Stars (M.gov)

Alert:

This component is only used for Medicare. Please use the theme switcher to view the component with Medicare styles.

Examples

Loading

Code

React

React Properties Documentation
NameTypeDefaultDescription
numberrequirednumberDescribes the number of stars to be filled in (in .5 increments)
totalnumberDescribes the total number of stars to be displayed.
ariaHiddenbooleanfalseDescribes if the stars should be hidden from a screen reader.

Component maturity

For more information about how we tested and validated our work for each checklist item, read our component maturity documentation.

Accessibility

  • Color

    Meets AA color contrast standards for accessibility and color blindness.
    Complete
  • Forced Colors Mode (FCM)

    While using FCM the components text is legible and improves readability.
    Incomplete
  • WCAG 2.1 Level AA Conformance

    All Axe checks for WCAG AA compliance have passed.
    Complete
  • Screen readers

    VoiceOver, NVDA, and JAWS screen readers provide concise communication and interaction.
    Incomplete
  • Keyboard navigation

    Component is fully navigable with a keyboard.
    Not applicable

Code

  • Storybook

    Component has stories to cover all defined props.
    Complete
  • Responsive

    Component designed to work in all responsive breakpoints.
    Complete
  • Spanish translations

    Includes Spanish translations for default text content.
    Incomplete

Tokens

  • Code

    Tokens implemented in code.
    Complete
  • Design

    Tokens implemented in the Sketch.
    Complete