made statistics_view.dart use localization and fix merge error
This commit is contained in:
@@ -67,40 +67,6 @@ class _StatisticsViewState extends State<StatisticsView> {
|
|||||||
winRates.isEmpty,
|
winRates.isEmpty,
|
||||||
replacement: Column(
|
replacement: Column(
|
||||||
children: [
|
children: [
|
||||||
StatisticsTile(
|
|
||||||
icon: Icons.sports_score,
|
|
||||||
title: 'Wins',
|
|
||||||
width: constraints.maxWidth * 0.95,
|
|
||||||
values: winCounts,
|
|
||||||
itemCount: 3,
|
|
||||||
barColor: Colors.blue,
|
|
||||||
),
|
|
||||||
SizedBox(height: constraints.maxHeight * 0.02),
|
|
||||||
StatisticsTile(
|
|
||||||
icon: Icons.percent,
|
|
||||||
title: 'Winrate',
|
|
||||||
width: constraints.maxWidth * 0.95,
|
|
||||||
values: winRates,
|
|
||||||
itemCount: 5,
|
|
||||||
barColor: Colors.orange[700]!,
|
|
||||||
),
|
|
||||||
SizedBox(height: constraints.maxHeight * 0.02),
|
|
||||||
StatisticsTile(
|
|
||||||
icon: Icons.casino,
|
|
||||||
title: 'Amount of Matches',
|
|
||||||
width: constraints.maxWidth * 0.95,
|
|
||||||
values: matchCounts,
|
|
||||||
itemCount: 10,
|
|
||||||
barColor: Colors.green,
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
child: const TopCenteredMessage(
|
|
||||||
icon: Icons.info,
|
|
||||||
title: 'Info',
|
|
||||||
message: 'No statistics available',
|
|
||||||
),
|
|
||||||
),
|
|
||||||
StatisticsTile(
|
StatisticsTile(
|
||||||
icon: Icons.sports_score,
|
icon: Icons.sports_score,
|
||||||
title: AppLocalizations.of(context)!.wins,
|
title: AppLocalizations.of(context)!.wins,
|
||||||
@@ -121,12 +87,22 @@ class _StatisticsViewState extends State<StatisticsView> {
|
|||||||
SizedBox(height: constraints.maxHeight * 0.02),
|
SizedBox(height: constraints.maxHeight * 0.02),
|
||||||
StatisticsTile(
|
StatisticsTile(
|
||||||
icon: Icons.casino,
|
icon: Icons.casino,
|
||||||
title: AppLocalizations.of(context)!.amount_of_matches,
|
title: AppLocalizations.of(
|
||||||
|
context,
|
||||||
|
)!.amount_of_matches,
|
||||||
width: constraints.maxWidth * 0.95,
|
width: constraints.maxWidth * 0.95,
|
||||||
values: matchCounts,
|
values: matchCounts,
|
||||||
itemCount: 10,
|
itemCount: 10,
|
||||||
barColor: Colors.green,
|
barColor: Colors.green,
|
||||||
),
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
child: TopCenteredMessage(
|
||||||
|
icon: Icons.info,
|
||||||
|
title: AppLocalizations.of(context)!.info,
|
||||||
|
message: AppLocalizations.of(context)!.no_data_available,
|
||||||
|
),
|
||||||
|
),
|
||||||
SizedBox(height: MediaQuery.paddingOf(context).bottom),
|
SizedBox(height: MediaQuery.paddingOf(context).bottom),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user