Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix a11y issue on InfoBadge sample #1310

Merged
merged 3 commits into from
Jul 12, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions WinUIGallery/ControlPages/InfoBadgePage.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@

<local:ControlExample x:Name="Example3" HeaderText="Placing an InfoBadge Inside Another Control" HorizontalContentAlignment="Stretch" >
<local:ControlExample.Example>
<Button Padding="0" Width="200" Height="60" HorizontalAlignment="Center" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch">
<Button Padding="0" Width="200" Height="60" ToolTipService.ToolTip="Refresh required"
HorizontalAlignment="Center" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch">
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="Auto" Height="Auto">
<SymbolIcon Symbol="Sync" HorizontalAlignment="Center"/>
<InfoBadge Background="#C42B1C" HorizontalAlignment="Right" VerticalAlignment="Top">
Expand All @@ -114,7 +115,8 @@

<local:ControlExample.Xaml>
<x:String xml:space="preserve">
&lt;Button Padding="0" Width="200" Height="60" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"&gt;
&lt;Button Padding="0" Width="200" Height="60" ToolTipService.ToolTip="Refresh required"
HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"&gt;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

HorizontalAlignment="Center" that is present above is missing from the text.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch, fixed.

&lt;Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="Auto" Height="Auto"&gt;
&lt;SymbolIcon Symbol="Sync" HorizontalAlignment="Center"/&gt;
&lt;InfoBadge Background="#C42B1C" HorizontalAlignment="Right" VerticalAlignment="Top"&gt;
Expand Down