Bei 0 gespielten Matches keine Stats anzeigen #111

Merged
sneeex merged 3 commits from enhancement/109-bei-0-gespielten-matches-keine-stats-anzeigen into development 2025-12-31 23:30:27 +00:00
Showing only changes of commit 175a9cb349 - Show all commits

View File

@@ -66,6 +66,7 @@ class _StatisticsViewState extends State<StatisticsView> {
winRates.isEmpty, winRates.isEmpty,
replacement: Column( replacement: Column(
children: [ children: [
if (winCounts.isNotEmpty) ...[
StatisticsTile( StatisticsTile(
icon: Icons.sports_score, icon: Icons.sports_score,
title: 'Wins', title: 'Wins',
@@ -75,6 +76,8 @@ class _StatisticsViewState extends State<StatisticsView> {
barColor: Colors.blue, barColor: Colors.blue,
), ),
SizedBox(height: constraints.maxHeight * 0.02), SizedBox(height: constraints.maxHeight * 0.02),
],
if (winRates.isNotEmpty) ...[
StatisticsTile( StatisticsTile(
icon: Icons.percent, icon: Icons.percent,
title: 'Winrate', title: 'Winrate',
@@ -84,6 +87,8 @@ class _StatisticsViewState extends State<StatisticsView> {
barColor: Colors.orange[700]!, barColor: Colors.orange[700]!,
), ),
SizedBox(height: constraints.maxHeight * 0.02), SizedBox(height: constraints.maxHeight * 0.02),
],
if (matchCounts.isNotEmpty) ...[
StatisticsTile( StatisticsTile(
icon: Icons.casino, icon: Icons.casino,
title: 'Amount of Matches', title: 'Amount of Matches',
@@ -93,6 +98,7 @@ class _StatisticsViewState extends State<StatisticsView> {
barColor: Colors.green, barColor: Colors.green,
), ),
], ],
],
), ),
child: const TopCenteredMessage( child: const TopCenteredMessage(
icon: Icons.info, icon: Icons.info,