Main Objective:
To ensure the visible text label of a user interface component matches its accessible name or its prefix.
The accessible name refers to the programmatically determined name assigned to a control, which can be specified using <label>, aria-label, aria-labelledby, alt, or the title attribute, with varying levels of specificity (e.g., aria-label being the most specific). It is crucial for users of speech-to-text assistive technology, who rely on matching visible labels to operate controls without interruption. Failure to match the visible label with the accessible name or its prefix prevents users from effectively interacting with controls.
Authors may provide additional text or hints for users with cognitive or visual disabilities, which are hidden from sighted users (e.g., using a hidden <span>, aria-labelledby, or aria-label that overrides the accessible name but should still match the label's prefix). It is essential that the label at least matches the prefix of the accessible name. For example, if the label is 'Search', the accessible name could be extended to 'Search for shoes' by adding aria-label attribute, to provide additional information for visually impaired users while still matching the prefix 'Search'. Notably, there is no requirement for uppercase letters to match for this criterion.
Choosing a different accessible name such as 'Shoes could be searched here' would fail to meet this criterion, as speech-to-text assistive technologies would not correctly identify the control.