positiveButton

@Composable
fun positiveButton(text: String? = null, textStyle: TextStyle = MaterialTheme.typography.button, @StringRes res: Int? = null, disableDismiss: Boolean = false, onClick: () -> Unit = {})

Adds a positive button to the dialog

Parameters

text

the string literal text shown in the button

res

the string resource text shown in the button

disableDismiss

when true this will stop the dialog closing when the button is pressed even if autoDismissing is disabled

onClick

a callback which is called when the button is pressed