Skip to content

Commit

Permalink
add documentation for radio button input
Browse files Browse the repository at this point in the history
  • Loading branch information
Siddharth Agarwal committed Sep 14, 2023
1 parent d6c99e1 commit 8930914
Showing 1 changed file with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,31 @@ package org.hisp.dhis.mobile.ui.designsystem.component
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.outlined.Cancel
import androidx.compose.material3.Icon
import androidx.compose.material3.RadioButton
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.platform.testTag
import org.hisp.dhis.mobile.ui.designsystem.component.InputShellState.DISABLED
import org.hisp.dhis.mobile.ui.designsystem.component.InputShellState.UNFOCUSED
import org.hisp.dhis.mobile.ui.designsystem.component.Orientation.VERTICAL

/**
* DHIS2 Radio Button Input. Wraps DHIS · [RadioButton].
* @param title controls the text to be shown for the title
* @param radioButtonData Contains all the data that will be displayed, the list type is RadioButtonData,
* It's parameters are uid for identifying the component, selected for controlling which option is selected,
* enabled controls if the component is clickable and textInput displaying the option text.
* @param modifier allows a modifier to be passed externally
* @param orientation Controls how the radio buttons will be displayed, HORIZONTAL for rows or
* VERTICAL for columns.
* @param state Manages the InputShell state
* @param supportingText is a list of SupportingTextData that
* manages all the messages to be shown
* @param legendData manages the legendComponent
* @param isRequired controls whether the field is mandatory or not
* @param itemSelected controls which item is selected.
* @param onItemChange is a callback to notify which item has changed into the block.
*/
@Composable
fun RadioButtonInput(
title: String,
Expand Down

0 comments on commit 8930914

Please sign in to comment.