On Secondary Photos Picker Action
Sets the secondary action handler for the Photos picker.
Platform Compatibility
Tags
SwiftUI Code
@State private var selectedPhoto: PhotosPickerItem?
var body: some View {
PhotosPicker("FooBar", selection: $selectedPhoto)
.photosPickerOnSecondaryAction {
print("selection canceled")
}
}