From df9955c16cc4c418de2b89b0521e60680e8e2115 Mon Sep 17 00:00:00 2001 From: vjrj <vjrj@comunes.org> Date: Wed, 26 Apr 2023 19:55:22 +0200 Subject: [PATCH] Add missing jar --- lib/custom_feedback_localization.dart | 36 +++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 lib/custom_feedback_localization.dart diff --git a/lib/custom_feedback_localization.dart b/lib/custom_feedback_localization.dart new file mode 100644 index 00000000..2ab37e04 --- /dev/null +++ b/lib/custom_feedback_localization.dart @@ -0,0 +1,36 @@ +import 'dart:ui'; + +import 'package:easy_localization/easy_localization.dart'; +import 'package:feedback/feedback.dart'; + +class CustomFeedbackLocalizations implements FeedbackLocalizations { + @override + String get submitButtonText => tr('feedback_submit'); + + @override + String get feedbackDescriptionText => tr('feedback_whats_wrong'); + + @override + String get draw => tr('feedback_draw'); + + @override + String get navigate => tr('feedback_navigate'); +} + +class CustomFeedbackLocalizationsDelegate + extends GlobalFeedbackLocalizationsDelegate { + @override + // ignore: overridden_fields + final Map<Locale, FeedbackLocalizations> supportedLocales = + <Locale, FeedbackLocalizations>{ + const Locale('es', 'AST'): CustomFeedbackLocalizations(), + const Locale('ca'): CustomFeedbackLocalizations(), + const Locale('de'): CustomFeedbackLocalizations(), + const Locale('en'): CustomFeedbackLocalizations(), + const Locale('es'): CustomFeedbackLocalizations(), + const Locale('fr'): CustomFeedbackLocalizations(), + const Locale('gl'): CustomFeedbackLocalizations(), + const Locale('nl'): CustomFeedbackLocalizations(), + const Locale('pt'): CustomFeedbackLocalizations(), + }; +} -- GitLab