onAutofillText

Function

Common
fun SemanticsPropertyReceiver.onAutofillText(
    label: String? = null,
    action: ((AnnotatedString) -> Boolean)?,
)

Action to autofill a TextField.

Expected to be used in conjunction with contentType and contentDataType properties.

Parameters

labelOptional label for this action.
actionAction to be performed when the SemanticsActions.OnAutofillText is called.