Improve desktop UX and accessibility

This commit is contained in:
2026-08-29 20:56:55 +02:00
parent b7a105af73
commit 89a6376fb6
17 changed files with 239 additions and 69 deletions
@@ -64,9 +64,15 @@ public partial class StudentListViewModel : ObservableObject
[ObservableProperty] private string _searchText = "";
[ObservableProperty] private bool _showInactive;
[ObservableProperty] private StudentListItem? _selectedStudent;
[ObservableProperty] private bool _isImporting;
public ObservableCollection<StudentListItem> Students { get; } = [];
public string CountSummary => $"{Students.Count} Schüler gesamt";
public bool HasNoStudents => Students.Count == 0;
public bool HasStudents => !HasNoStudents;
public string EmptyListMessage => string.IsNullOrWhiteSpace(SearchText)
? ShowInactive ? "Noch keine Schüler vorhanden." : "Noch keine aktiven Schüler vorhanden."
: "Keine Schüler passen zur aktuellen Suche.";
public StudentListViewModel(IStudentRepository students, IGroupRepository groups,
IGroupMembershipRepository memberships)
@@ -105,6 +111,9 @@ public partial class StudentListViewModel : ObservableObject
}
foreach (var s in f) Students.Add(new StudentListItem(s));
OnPropertyChanged(nameof(CountSummary));
OnPropertyChanged(nameof(HasNoStudents));
OnPropertyChanged(nameof(HasStudents));
OnPropertyChanged(nameof(EmptyListMessage));
}
public Func<Task>? OnAddStudent { get; set; }