Input - Radio Group

Use radio buttons to make a selection from a list of mutually exclusive options

Default

Healthy
Show details
Healthy
Published: February 05, 2024
Updated: February 21, 2024
Healthy
Show details
Healthy
Published: February 05, 2024
Updated: February 21, 2024

Bordered

Healthy
Show details
Healthy
Published: February 05, 2024
Updated: February 21, 2024
Healthy
Show details
Healthy
Published: February 05, 2024
Updated: February 21, 2024

 

Overview

The Radio Input component enables marketers to make single selections from a list of options, facilitating data input and configuration processes. This component enhances user experience by providing a clear and intuitive way to choose from mutually exclusive options.

Design

Structure

Group label: A label that provides the description for the for the list of items

Description (optional): This can be included below the label if there is additional context or information that should be provided to the marketer

Indicator: Used to indicate whether the item in the list is selected or not

Item label: A label that follows the indicator to describe the item

 

Radio item

The radio item is an individual selection within a radio group.

Default

🟢 Radio Item / :checked=False, :disabled=False, :hover=False, :focused=False

🟢 Radio Item / :checked=False, :disabled=False, :hover=False, :focused=False

🟢 Radio Item / :checked=True, :disabled=False, :hover=False, :focused=False

🟢 Radio Item / :checked=True, :disabled=False, :hover=False, :focused=False

🟢 Radio Item / :checked=False, :disabled=False, :hover=True, :focused=False

🟢 Radio Item / :checked=False, :disabled=False, :hover=True, :focused=False

🟢 Radio Item / :checked=True, :disabled=False, :hover=True, :focused=False

🟢 Radio Item / :checked=True, :disabled=False, :hover=True, :focused=False

🟢 Radio Item / :checked=False, :disabled=False, :hover=False, :focused=True

🟢 Radio Item / :checked=False, :disabled=False, :hover=False, :focused=True

🟢 Radio Item / :checked=True, :disabled=False, :hover=False, :focused=True

🟢 Radio Item / :checked=True, :disabled=False, :hover=False, :focused=True

🟢 Radio Item / :checked=False, :disabled=True, :hover=False, :focused=False

🟢 Radio Item / :checked=False, :disabled=True, :hover=False, :focused=False

🟢 Radio Item / :checked=True, :disabled=True, :hover=False, :focused=False

🟢 Radio Item / :checked=True, :disabled=True, :hover=False, :focused=False

 

Bordered

Inactive

Inactive

Hover

Hover

Selected

Selected

Focus

Focus

Disabled

Disabled

 

Additional properties

Description

Description

A brief supporting description for a radio item

Leading icon

Leading icon

An icon that follows the indicator but proceeds the label

Trailing icon

Trailing icon

A badge that follows the indicator and label, and is generally used to indicate a preferred or recommended option

Badge

Badge

A badge that follows the indicator and label, and is generally used to indicate a preferred or recommended option

Slot

Slot

A container that allows child elements to be included inside. This should be used sparingly, because of the way it could get implemented in code, default component styles might be overridden, meaning that the component might not stay in sync with the parent variant.

 

Radio group

Variants

Radio groups are collection of radio items that stack vertically by default. Stacking horizontally should be avoided when possible. At least one item in the group should always be selected by default.

Default

Default

Default

Bordered

Bordered

If you want to present the options with more visual emphasis, consider using the bordered variant.

 

Orientation

Depending on the number of options and structure of the form, the input group can structured vertically (preferred) or horizontally.

Vertical

Vertical

Horizontal

Horizontal

Vertical (bordered)

Vertical (bordered)

Horizontal (bordered)

Horizontal (bordered)

Guidelines

Limit options

The base component includes 4 radio button options. If more than 4 options are allowed, a select is preferred over a radio group.

Frame 13
Frame 136

 

 

Avoid more than 3 horizontally

While it is preferred to stack the radio group vertically, if there is a scenario where space is a concern and there are three options or less—it is acceptable to stack the radio group horizontally.

Frame 136
Frame 13

 

 

Radio group orientation

Radio group should stack items vertically by default. In cases where options may need to stacked horizontally, the options should be limited to 2 radio items per row. If there are more than 4 options, an input select is preferred.

Vertical bordered checkbox variants should flex on smaller displays.

🟢 Radio Group / Horizontal=True

🟢 Radio Group / Horizontal=True

🟢 Bordered Radio Group / Horizontal=True

🟢 Bordered Radio Group / Horizontal=True

 

Miscellaneous

  • Make the the safest, lowest risk option the default selection. If risk is not a concern, make the most likely selection the default.
  • Prefer radio buttons to select menus when there are fewer than ~5 options to choose from.
  • Prefer aligning items vertically, rather than horizontally, to make them more scannable.
  • To emphasize the significance and impact of a radio option within a form, use a the bordered variant.​
  • A badge should be used sparingly between options and should be used in a way to indicate a preferred or recommended option.

 

  • Make the the safest, lowest risk option the default selection. If risk is not a concern, make the most likely selection the default.
  • Radio lists should stack horizontally if more than 3 options
  • When bordered, the width of the radio items should be 100% of the radio list’s width
  • If using icons or descriptions, all radio items in the radio group should also have them enabled.

 

  • Radio items should not contain a nested child instance of a radio group.
  • Don’t create custom configurations of Radio items, use the built-in component properties or reach out in #design-system if the current structure doesn’t fit your needs.

 

Content

  • Sentence case the radio button group’s title, and the options within the radio button list.​
  • Radio item description should be a brief sentence. If additional explanation is needed, consider using a help tip, popover, or link to external support documentation.

Accessibility

  • Clicking the label should check its input.
  • The label should have a for attribute matching the input’s id, to work with assistive technologies.
  • Radio button groups should be focusable by tabbing, and the selection should be changeable with arrow keys. (This is native behavior with correct markup.)
  • Use semantic HTML elements and appropriate ARIA attributes to enhance screen reader compatibility and provide context for the Radio Input component.
  • Provide sufficient color contrast and visual indicators to highlight selected options and improve visibility for users with low vision or color vision deficiencies.

Health

Default

Component checklist

Is documented

The component is fully documented

Accessibile

Tested against WCAG 2.1 AAA accessibility guidelines

Tokens

This component uses tokens in both Figma and code

Figma component

Includes a link to a Figma component that has been imported to Supernova

Storybook

Includes a link to an external code repository

-

Status

The component has a health status indicated

Healthy

Is documented

The component is fully documented

Accessibile

Tested against WCAG 2.1 AAA accessibility guidelines

Tokens

This component uses tokens in both Figma and code

Figma component

Includes a link to a Figma component that has been imported to Supernova

Storybook

Includes a link to an external code repository

-

Status

The component has a health status indicated

Healthy

 

Bordered

Is documented

The component is fully documented

Accessibile

Tested against WCAG 2.1 AAA accessibility guidelines

Tokens

This component uses tokens in both Figma and code

Figma component

Includes a link to a Figma component that has been imported to Supernova

Storybook

Includes a link to an external code repository

-

Status

The component has a health status indicated

Healthy

Component checklist