updated flashcards
This commit is contained in:
@@ -62,8 +62,7 @@ class HlaskovnikFrontendApp extends StatelessWidget {
|
||||
),
|
||||
useMaterial3: true,
|
||||
),
|
||||
//themeMode: ThemeMode.system, // TODO: .dark is just for testing
|
||||
themeMode: ThemeMode.dark,
|
||||
themeMode: ThemeMode.system,
|
||||
routerConfig: _router,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ class FlashcardsPage extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
mainAxisAlignment: MainAxisAlignment.end,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(Constants.edgeInset),
|
||||
|
||||
@@ -38,20 +38,6 @@ class QuoteProvider extends ChangeNotifier {
|
||||
return filtered;
|
||||
}
|
||||
|
||||
Map<String, int> get _authorCounts {
|
||||
final counts = <String, int>{};
|
||||
|
||||
for (var quote in filteredQuotes) {
|
||||
counts.update(
|
||||
quote.author,
|
||||
(value) => value + 1,
|
||||
ifAbsent: () => 1,
|
||||
);
|
||||
}
|
||||
|
||||
return counts;
|
||||
}
|
||||
|
||||
List<MapEntry<String, int>> get sortedAuthorCounts {
|
||||
final counts = <String, int>{};
|
||||
|
||||
@@ -88,7 +74,7 @@ class QuoteProvider extends ChangeNotifier {
|
||||
if (randomQuoteDeterminator) {
|
||||
return randomQuote.body;
|
||||
} else {
|
||||
return randomQuote.author;
|
||||
return " – ${randomQuote.author}";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user