-
Notifications
You must be signed in to change notification settings - Fork 1.4k
[.NET 9] Add a11y fixes to DeveloperBalance App #611
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
Conversation
…ing issues with vscode
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Apply a11y improvements and .NET 9 updates across the DeveloperBalance sample, including replacing legacy layouts with CollectionView, enhancing screen-reader semantics, and refining ViewModel navigation and repository logic.
- Swap ScrollView/BindableLayout for CollectionView and add semantic properties for accessibility
- Introduce null-safe navigation signatures and SelectedProject/SelectedTags properties in page models
- Add Windows-specific tab stops, segment descriptions, and repository association checks
Reviewed Changes
Copilot reviewed 19 out of 19 changed files in this pull request and generated no comments.
Show a summary per file
File | Description |
---|---|
nuget.config | New NuGet package source |
Platforms/MacCatalyst/Info.plist | Added app category key |
Pages/ProjectListPage.xaml.cs | Bound AppearingBehavior’s context |
Pages/ProjectListPage.xaml | Swapped to CollectionView and updated semantics |
Pages/ProjectDetailPage.xaml.cs | Added selection-changed handler |
Pages/ProjectDetailPage.xaml | Replaced tag templates with multi-select view |
Pages/MainPage.xaml | Replaced horizontal ScrollView with CollectionView |
Pages/Controls/TaskView.xaml | Adjusted layout, added automation properties |
Pages/Controls/ProjectCardView.xaml | Switched to FlexLayout for tags |
Pages/Controls/CategoryChart.xaml.cs | Enabled tab stop on Windows |
Pages/Controls/CategoryChart.xaml | Hidden shimmer from accessibility tree |
PageModels/ProjectListPageModel.cs | Added SelectedProject property, updated command |
PageModels/ProjectDetailPageModel.cs | Tracked SelectedTags, refactored ToggleTag logic |
PageModels/MainPageModel.cs | Added SelectedProject, updated navigation command |
MauiProgram.cs | Appended keyboard focus mapping for Windows |
DeveloperBalance.csproj | Bumped MauiVersion, package IDs and versions |
Data/TagRepository.cs | Prevent duplicate tag–project associations |
AppShell.xaml.cs | Added semantic description for theme selector |
AppShell.xaml | Added descriptions for light/dark mode segments |
Comments suppressed due to low confidence (4)
PageModels/ProjectListPageModel.cs:31
- The command method signature returns a nullable Task and checks
project is null
, butproject
is non-nullable. Change the return type toTask
, remove the null check, and callShell.Current.GoToAsync(...)
directly.
Task? NavigateToProject(Project project)
PageModels/MainPageModel.cs:155
- This method signature makes the Task nullable and guards against a
null
project, butproject
is non-nullable. Refactor to returnTask
, drop the null check, and callShell.Current.GoToAsync(...)
directly.
private Task? NavigateToProject(Project project)
Data/TagRepository.cs:231
- Inside
IsAssociated
, callingSaveItemAsync(item)
duplicates the initial tag save and incurs extra database overhead. Remove this call and assume the tag exists before checking the association.
await SaveItemAsync(item);
Pages/ProjectDetailPage.xaml:61
- Removing the
SemanticProperties.Hint
on the icon grid loses the guidance for screen-reader users. Consider reintroducing a concise hint so that assistive technologies convey actionable context.
SemanticProperties.Hint="Icon representing the type of task . Tap to select"
@@ -10,6 +10,9 @@ public AppShell() | |||
InitializeComponent(); | |||
var currentTheme = Application.Current!.RequestedTheme; | |||
ThemeSegmentedControl.SelectedIndex = currentTheme == AppTheme.Light ? 0 : 1; | |||
#if ANDROID || WINDOWS |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why only on Android and Windows?
@@ -21,17 +21,18 @@ | |||
<Nullable>enable</Nullable> | |||
<!-- https://github.com/CommunityToolkit/Maui/issues/2205 --> | |||
<NoWarn>XC0103</NoWarn> | |||
<MauiVersion>9.0.60</MauiVersion> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we just remove this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing it we are going to use 9.1.1 and requires to downgrade the Toolkit, but we use something from the latest versions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
aw yea :-(
Well, we will hopefully be releasing 9.0.81 here soon into workloads
BindingContext = model; | ||
} | ||
|
||
private async void CollectionView_SelectionChanged(object sender, SelectionChangedEventArgs e) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this all be moved to a RelayCommand in the ViewModel?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, moved to the ViewModel.
#if WINDOWS | ||
if (chart is Microsoft.Maui.Platform.ContentPanel contentPanel) | ||
{ | ||
contentPanel.IsTabStop = true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we move this to a mapper?
Is this an issue that's been highlighted to SF? Should they make this control a tabstop by default?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, move to a Mapper.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tj-devel709 Is this an issue that's been highlighted to SF? Should they make this control a tabstop by default?
I can follow the conversation with Sf about it.
Apply a11y fixes to DeveloperBalance App to the .NET 9 samples.