ReferenceMenus
AudioTrackRadioGroup
A menu radio group for selecting an audio track
Creates radio items from the player audio track state and selects the enabled track.
Import
Anatomy
Behavior
The group is available when the configured media exposes more than one audio track. Labels use the track label, then language, then kind. Pass formatTrack to customize the visible labels.
AudioTrackRadioGroup.Root uses useAudioTrackOptions to own selection and renders no element. Wrap the menu’s Menu.Trigger and Menu.Content in it so the trigger inherits the group’s disabled and hidden state and exposes data-availability. AudioTrackRadioGroup.Options renders the items: its required renderItem callback renders the Menu.RadioItem root and receives item state containing the translated label and current checked value. AudioTrackRadioGroup.Value displays the selected label, typically inside the trigger. Options and Value render null when the audio track feature is not configured.
The AudioTrackRadioGroup export from the @videojs/react root is a compatibility component that composes Root and Options behind the former single-component props. Prefer the parts for new code.
Styling
Unavailable groups receive the native hidden attribute.
Accessibility
The group uses the menu radio group pattern.
AudioTrackRadioGroup.Options receives its accessible label from the label prop on AudioTrackRadioGroup.Root or defaults to Audio. Override it with aria-label or aria-labelledby on AudioTrackRadioGroup.Options.