The Wear Material SplitRadioButton offers two slots and shows the current selection state via a radio control.
@Sampled
@Composable
@WearPreviewDevices
@PreviewWrapper(RemoteComponentPreviewWrapper::class)
fun RemoteSplitRadioButtonSample(modifier: RemoteModifier = RemoteModifier) {
val selected = rememberMutableRemoteBoolean(true)
RemoteSplitRadioButton(
selected = selected,
onSelectionClick = valueChange(selected, !selected),
selectionContentDescription = "Split Radio".rs,
onContainerClick = valueChange(selected, !selected),
modifier = modifier,
label = { RemoteText("Split Radio".rs) },
)
}