aboutsummaryrefslogtreecommitdiff
path: root/lib/views
diff options
context:
space:
mode:
Diffstat (limited to 'lib/views')
-rw-r--r--lib/views/info_view.dart3
-rw-r--r--lib/views/recipe_view.dart6
2 files changed, 3 insertions, 6 deletions
diff --git a/lib/views/info_view.dart b/lib/views/info_view.dart
index fbe522a..2f164b8 100644
--- a/lib/views/info_view.dart
+++ b/lib/views/info_view.dart
@@ -93,8 +93,7 @@ class InfoViewState extends State<InfoView> {
}
cantOpenLink(var why, BuildContext context) {
- // TODO: translation
- ToastBar.showToastBar(context, "Could not open link", actionLabel: "");
+ ToastBar.showToastBar(context, AppLocalizations.of(context)!.linkError, actionLabel: "");
debugPrint("Could not open $why");
}
diff --git a/lib/views/recipe_view.dart b/lib/views/recipe_view.dart
index c22ea2b..3aaa160 100644
--- a/lib/views/recipe_view.dart
+++ b/lib/views/recipe_view.dart
@@ -292,8 +292,7 @@ class RecipeViewState extends State<RecipeView> {
final _ingredients = _unsavedRecipe.description!.split("\n")..retainWhere((element) => element.startsWith("- "));
if (_ingredients.isEmpty) {
- // TODO: translation
- widget.showToastCallback!("No ingredients found", "", () {});
+ widget.showToastCallback!(AppLocalizations.of(context)!.ingredientsError, "", () {});
return;
}
@@ -308,8 +307,7 @@ class RecipeViewState extends State<RecipeView> {
ShoplistData.save();
if (widget.showToastCallback != null) {
- // TODO: translation
- widget.showToastCallback!("Added to Shoplist", "", () {});
+ widget.showToastCallback!(AppLocalizations.of(context)!.ingredientsAdded, "", () {});
}
}