Discussion 議論
For example, this is how a custom action to compose a new email could be added to a view.
var body: some View {
ContentView()
.accessibilityAction(named: Text("New Message")) {
// Handle action
}
}
Availability 有効性
Technology
func accessibilityAction(named name: Text
, _ handler: @escaping () -> Void
) -> ModifiedContent
<Self, AccessibilityAttachmentModifier
>
For example, this is how a custom action to compose a new email could be added to a view.
var body: some View {
ContentView()
.accessibilityAction(named: Text("New Message")) {
// Handle action
}
}