Fix Hyperlink UIA Name including control type on Text page#779
Open
mmanolova-msft wants to merge 1 commit into
Open
Fix Hyperlink UIA Name including control type on Text page#779mmanolova-msft wants to merge 1 commit into
mmanolova-msft wants to merge 1 commit into
Conversation
The Hyperlink sample on the Text > Hyperlink page used 'Hyperlink' as its visible text, so its UI Automation Name matched its LocalizedControlType, violating WCAG/MAS 4.1.2 (Name, Role, Value). Change the link text to 'Microsoft' (its navigation target) so the Name is meaningful and no longer repeats the control type. Also update the displayed XamlCode snippet to match. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Fixes an accessibility issue on the Text → Hyperlink page in WPF Gallery. The sample
Hyperlinkused the visible textHyperlink, so its UI Automation Name matched its LocalizedControlType (hyperlink). This violates WCAG/MAS 4.1.2 (Name, Role, Value) and is flagged by Accessibility Insights as "The Name property must not include the element's control type."Change
Sample Applications/WPFGallery/Views/Text/HyperlinkPage.xaml: change the link text fromHyperlinktoMicrosoft(its navigation target), so the Name is meaningful and no longer repeats the control type. The displayedXamlCodesnippet is updated to match the live control.Result
Testing
WPFGallery.csproj(0 errors).Microsoft Reviewers: Open in CodeFlow