Contents

TextInputDictationActivation

A configuration that determines what starts dictation in a search field.

Declaration

struct TextInputDictationActivation

Overview

Pass a value of this type to inline(activation:) when you want to keep the dictation microphone in a search field but choose how someone begins speaking:

NavigationStack {
    RecipeList(matching: query)
}
.searchable(text: $query)
.searchDictationBehavior(.inline(activation: .onLook))

On visionOS, onLook starts dictation as soon as someone looks at the field. Choose onSelect instead when speaking early would be disruptive.

Topics

Getting activation values

See Also

Dictating text