From 9845a35c6e121814956d1bb64598a6d3d4a1c06d Mon Sep 17 00:00:00 2001 From: Pearoo Date: Thu, 28 Sep 2023 18:17:24 +0200 Subject: [PATCH] Fix english absence error + comment bugreports --- filcnaplo/lib/helpers/notification_helper.dart | 4 ++-- filcnaplo_desktop_ui/lib/pages/grades/grades_page.dart | 4 ++-- .../lib/common/widgets/absence/absence_view.dart | 2 +- .../lib/common/widgets/lesson/changed_lesson_tile.dart | 2 +- .../lib/pages/absences/absence_subject_view.dart | 2 +- .../lib/pages/absences/absences_page.i18n.dart | 3 +++ filcnaplo_premium/lib/ui/mobile/settings/theme.dart | 2 +- 7 files changed, 11 insertions(+), 8 deletions(-) diff --git a/filcnaplo/lib/helpers/notification_helper.dart b/filcnaplo/lib/helpers/notification_helper.dart index fd70e10..6f6f9a4 100644 --- a/filcnaplo/lib/helpers/notification_helper.dart +++ b/filcnaplo/lib/helpers/notification_helper.dart @@ -195,7 +195,7 @@ class NotificationsHelper { if (userProvider.getUsers().length == 1) { await flutterLocalNotificationsPlugin.show( absence.id.hashCode, - "title_absence".i18n, + "title_absence".i18n, // https://discord.com/channels/1111649116020285532/1153273625206591528 "body_absence".i18n.fill( [ DateFormat("yyyy-MM-dd").format(absence.date), @@ -210,7 +210,7 @@ class NotificationsHelper { } else { await flutterLocalNotificationsPlugin.show( absence.id.hashCode, - "title_absence".i18n, + "title_absence".i18n, // https://discord.com/channels/1111649116020285532/1153273625206591528 "body_absence_multiuser".i18n.fill( [ userProvider.displayName!, diff --git a/filcnaplo_desktop_ui/lib/pages/grades/grades_page.dart b/filcnaplo_desktop_ui/lib/pages/grades/grades_page.dart index 619756a..0a2099b 100644 --- a/filcnaplo_desktop_ui/lib/pages/grades/grades_page.dart +++ b/filcnaplo_desktop_ui/lib/pages/grades/grades_page.dart @@ -144,8 +144,8 @@ class _GradesPageState extends State { Expanded( child: StatisticsTile( outline: true, - title: AutoSizeText( - "classavg".i18n, + title: AutoSizeText( // https://discord.com/channels/1111649116020285532/1153397476578050130 + "classavg".i18n, textAlign: TextAlign.center, maxLines: 2, wrapWords: false, diff --git a/filcnaplo_mobile_ui/lib/common/widgets/absence/absence_view.dart b/filcnaplo_mobile_ui/lib/common/widgets/absence/absence_view.dart index 23ec169..1ffac65 100755 --- a/filcnaplo_mobile_ui/lib/common/widgets/absence/absence_view.dart +++ b/filcnaplo_mobile_ui/lib/common/widgets/absence/absence_view.dart @@ -127,7 +127,7 @@ class AbsenceView extends StatelessWidget { maxLines: 2, overflow: TextOverflow.ellipsis, ), - onPressed: () { + onPressed: () { // https://discord.com/channels/1111649116020285532/1149964760130002945 Navigator.of(context).pop(); if (outsideContext != null) { diff --git a/filcnaplo_mobile_ui/lib/common/widgets/lesson/changed_lesson_tile.dart b/filcnaplo_mobile_ui/lib/common/widgets/lesson/changed_lesson_tile.dart index 68540ab..7125d2b 100755 --- a/filcnaplo_mobile_ui/lib/common/widgets/lesson/changed_lesson_tile.dart +++ b/filcnaplo_mobile_ui/lib/common/widgets/lesson/changed_lesson_tile.dart @@ -57,7 +57,7 @@ class ChangedLessonTile extends StatelessWidget { ), ), title: Text( - lesson.substituteTeacher?.name != "" + lesson.substituteTeacher?.name != "" || lesson.substituteTeacher?.name != null ? "substituted".i18n : "cancelled".i18n, maxLines: 2, diff --git a/filcnaplo_mobile_ui/lib/pages/absences/absence_subject_view.dart b/filcnaplo_mobile_ui/lib/pages/absences/absence_subject_view.dart index dcf162f..dc184e7 100755 --- a/filcnaplo_mobile_ui/lib/pages/absences/absence_subject_view.dart +++ b/filcnaplo_mobile_ui/lib/pages/absences/absence_subject_view.dart @@ -40,7 +40,7 @@ class AbsenceSubjectView extends StatelessWidget { TimetablePage.jump(context, lesson: lesson); } else { ScaffoldMessenger.of(context).showSnackBar(CustomSnackBar( - content: Text("Cannot find lesson".i18n, + content: Text("lesson_not_found".i18n, style: const TextStyle(color: Colors.white)), backgroundColor: AppColors.of(context).red, context: context, diff --git a/filcnaplo_mobile_ui/lib/pages/absences/absences_page.i18n.dart b/filcnaplo_mobile_ui/lib/pages/absences/absences_page.i18n.dart index 91b7621..61c971a 100755 --- a/filcnaplo_mobile_ui/lib/pages/absences/absences_page.i18n.dart +++ b/filcnaplo_mobile_ui/lib/pages/absences/absences_page.i18n.dart @@ -17,6 +17,7 @@ extension ScreensLocalization on String { "Subjects": "Subjects", "attention": "Attention!", "attention_body": "Percentage calculations are only an approximation so they may not be accurate.", + "lesson_not_found": "Cannot find lesson", }, "hu_hu": { "Absences": "Hiányzások", @@ -32,6 +33,7 @@ extension ScreensLocalization on String { "Subjects": "Tantárgyak", "attention": "Figyelem!", "attention_body": "A százalékos számítások csak közelítések, ezért előfordulhat, hogy nem pontosak.", + "lesson_not_found": "Nem található óra", }, "de_de": { "Absences": "Fehlen", @@ -47,6 +49,7 @@ extension ScreensLocalization on String { "Subjects": "Fächer", "attention": "Achtung!", "attention_body": "Prozentberechnungen sind nur eine Annäherung und können daher ungenau sein.", + "lesson_not_found": "Lektion kann nicht gefunden werden", }, }; diff --git a/filcnaplo_premium/lib/ui/mobile/settings/theme.dart b/filcnaplo_premium/lib/ui/mobile/settings/theme.dart index cbe4d40..1d2b3b1 100644 --- a/filcnaplo_premium/lib/ui/mobile/settings/theme.dart +++ b/filcnaplo_premium/lib/ui/mobile/settings/theme.dart @@ -329,7 +329,7 @@ class _PremiumCustomAccentColorSettingState width: double.infinity, decoration: BoxDecoration( borderRadius: BorderRadius.circular(24), - gradient: LinearGradient( + gradient: LinearGradient( // https://discord.com/channels/1111649116020285532/1153619667848548452 begin: Alignment.topCenter, end: Alignment.bottomCenter, stops: const [