Have you used Voice Control? It feels like magic! But it would be cool if you could have an easier time guessing the name of a button without the “Show names” command. We can do that! Meet accessibilityUserInputLabels.

https://developer.apple.com/documentation/objectivec/nsobject-swift.class/accessibilityuserinputlabels

An app with a cog button in the top-right corner. If the accessibility label is “settings”. Voice Control won’t recognise that button with the words configuration or preferences. But we can set all those concepts and others, perhaps gear, cogwheel or sprocket to the accessibilityUserInputLabels array property of the button.

You may also find interesting...

The Accessibility APIs are generic and flexible. They're not just for VoiceOver. If you implement them right, you can do it once and it will very likely work great for VoiceOver, Voice Control, Switch Control, Full Keyboard Access, and more. That's why, to start with, we tend to focus on VoiceOver, the same way you may focus on keyboard navigation for the web. A great VoiceOver experience will get you most of the way to a good experience with the other assistive technologies. We've seen one example with Custom Actions. One implementation works for: VoiceOver: https://x.com/dadederk/status/1550099327053451266 Switch Control: https://x.com/dadederk/status/1551236244088279040 Full Keyboard Access: https://x.com/dadederk/status/1551874732504629249 And Voice Control: https://x.com/dadederk/status/1552253520182640645 Of course that doesn't mean you don't have to test and check how the experience is with the other technologies. But before feeling overwhelmed, or for small teams, making sure your app works for VoiceOver is a great start.

Accessibility labels might not be the best input labels, used for example to find or interact with elements with Voice Control or Full Keyboard Access. In those cases, you can provide accessibility user input labels.

Sometimes your UI will just not scale for large text sizes. Simple changes, for large sizes, like disposing elements vertically instead of horizontally, reducing the number of columns, and allowing more lines of text, can do the trick most times.

Created in Swift with Ignite.

Supporting Swift for Swifts