Add UIA element grouping to SettingsContainer (#15756)

Adds an `AutomationProperty.Name` to the main grid in the `SettingContainer`. Doing so makes it so that the group of elements is considered a "group \<header\>".

Now, when navigating with a screen reader, when you enter the group of elements, the "group \<header\>" will be presented. Thus, if the user navigates to the "reset" button, it'll be prefaced with a "group \<header\>" announcement first. If the user navigates to it from the other direction (the setting control), this announcement isn't made, but the user already has an understanding of what group of settings they're in, which is standard practice.

Closes #15158

(cherry picked from commit d70794a246)
Service-Card-Id: 89990838
Service-Version: 1.17
This commit is contained in:
Carlos Zamora 2023-07-25 13:42:47 -07:00 committed by Dustin L. Howett
parent ef81022c17
commit 3edbcf9331
1 changed files with 2 additions and 1 deletions

View File

@ -106,7 +106,8 @@
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="local:SettingContainer">
<Grid Style="{StaticResource NonExpanderGrid}">
<Grid AutomationProperties.Name="{TemplateBinding Header}"
Style="{StaticResource NonExpanderGrid}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />