I have SwiftUI List in edit mode (editMode == .active) and with onDelete modifier on some of list rows. I would like to make onDelete action available with Accessibility (VoiceOver). How do I do that?
Without any additional code, delete accessory (red circle with minus sign) on list element is not visible for Accessibility (swiping through accessibility elements just skips over this accessory).
I assume that
onDeleteis specifically for swipe actions.Therefore, for
accessibilityAction, I needed to add an additional function for removal.Example: