40+ landing page components for ReactBrowse now

Primitives

Radio Group

Radio button group for selecting a single option from a list. Supports descriptions, multiple sizes, and horizontal/vertical orientation.

Installation

npm install @trinkui/react

Import

import { RadioGroup } from "@trinkui/react";

Usage

Select a plan

Sizes

Small
Medium
Large

Horizontal Orientation

Orientation

Disabled

Disabled group

RadioGroup Props

PropTypeDefaultDescription
optionsrequired
RadioOption[]—Array of radio options to render
value
string—Controlled selected value
defaultValue
string—Initial uncontrolled value
onChange
(value: string) => void—Callback when selection changes
label
string—Group label rendered as a fieldset legend
orientation
"vertical" | "horizontal""vertical"Layout direction of the radio items
size
"sm" | "md" | "lg""md"Size of the radio indicators and text
disabled
booleanfalseDisable all radio options
className
string—Additional CSS classes

RadioOption Props

PropTypeDefaultDescription
labelrequired
string—Display label for the option
valuerequired
string—Unique value for the option
description
string—Secondary description text
disabled
booleanfalseDisable this individual option

Accessibility

  • Wraps options in a <fieldset> with a <legend> for the group label.
  • Uses native <input type="radio"> elements for full keyboard and screen reader support.
  • Arrow keys navigate between options within the group.
  • The checked state is conveyed via the native checked attribute.
  • Disabled options are excluded from the tab order.