[A11y] Add SemanticProperties.Description to the Toolbar Icon#27119
Merged
tj-devel709 merged 7 commits intomainfrom Jan 23, 2025
Merged
[A11y] Add SemanticProperties.Description to the Toolbar Icon#27119tj-devel709 merged 7 commits intomainfrom
tj-devel709 merged 7 commits intomainfrom
Conversation
Contributor
There was a problem hiding this comment.
Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.
Comments suppressed due to low confidence (1)
src/Controls/src/Core/Compatibility/iOS/Extensions/AccessibilityExtensions.cs:90
- Ensure that the new behavior introduced by SemanticProperties.GetDescription is covered by tests.
Control.AccessibilityLabel = SemanticProperties.GetDescription(Element) ?? (string)Element.GetValue(AutomationProperties.NameProperty) ?? _defaultAccessibilityLabel;
PureWeen
requested changes
Jan 14, 2025
Member
There was a problem hiding this comment.
I'm thinking we should fix all of the methods in here to route the UpdateSemantics implementations.
public static string SetAccessibilityLabel(this NativeView Control, Element Element, string _defaultAccessibilityLabel = null)
{
if (Element is IView view && view.Semantics != null)
{
Control.UpdateSemantics(view);
return String.Empty;
}And then create an issue/comment to obsolete this code in NET10
PureWeen
approved these changes
Jan 21, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of Change
In the this issue: #26816, our A11y folks pointed out that Toolbar.Items with IconImageSource set do not properly have a "Label" in the accessibility inspector on Mac. This is important because that label allows the VoiceControl and VoiceOver to work properly for that button.
In the examples below you can see the accessibility inspector on the right with the label set on the After and not the Before.
Before:
After:
Issues Fixed
Partially resolves: #26816