add artificial delay to loadPlayerList for skeleton loading
All checks were successful
Pull Request Pipeline / test (pull_request) Successful in 2m8s
Pull Request Pipeline / lint (pull_request) Successful in 2m9s

This commit is contained in:
2025-11-23 15:22:59 +01:00
parent 9e8bab1a60
commit 26fadf5093

View File

@@ -54,7 +54,11 @@ class _CreateGroupViewState extends State<CreateGroupView> {
}
void loadPlayerList() {
_allPlayersFuture = db.playerDao.getAllPlayers();
_allPlayersFuture = Future.delayed(
const Duration(milliseconds: 400),
() => db.playerDao.getAllPlayers(),
);
suggestedPlayers = skeletonData;
_allPlayersFuture.then((loadedPlayers) {
setState(() {
loadedPlayers.sort((a, b) => a.name.compareTo(b.name));