Switch
fun Switch(modifier: Modifier = Modifier, isChecked: Boolean = false, enabled: Boolean = true, onCheckedChange: (Boolean) -> Unit)
DHIS2 Switch wraps Material 3 Switch.
Parameters
modifier
: optional modifier.
is Checked
: whether switch is selected or not
enabled
: controls the enabled state of the button. When false
, this button will not be clickable and will appear disabled to accessibility services.
on Checked Change
: access to the on checked changed event.