orbit-swiftui
orbit-swiftui copied to clipboard
Use identifiers and labels for `Tabs` and `SegmentedSwitch` buttons
To enable proper accessibility of content inside these components, we should:
Solution 1 (simpler, not accurate):
- mark content with
isButton
trait - hide button layer from accessibility
- Blocker: The trait
isSelected
needs to be propagated to correct content
Solution 2 (complicated, accurate):
- add preference keys for content that include accessibilityIdentifier and textLabel
- use these keys when creating buttons to assign them IDs and labels
- hide content layer from accessibility
- active button keeps
isSelected
trait