diff --git a/.github/workflows/deploy_by_tag.yml b/.github/workflows/deploy_by_tag.yml index dde11e2..7cd0514 100644 --- a/.github/workflows/deploy_by_tag.yml +++ b/.github/workflows/deploy_by_tag.yml @@ -25,6 +25,8 @@ jobs: flutter pub get dart run build_runner build flutter build web --base-href "${BASE_HREF}" + - name: Copy `README.md` to the build dir + run: cp README_web.md build/web/README.md - name: Move to build dir for web run: cd build/web - name: Push directory to another repository diff --git a/.gitignore b/.gitignore index 70b4431..555efc1 100644 --- a/.gitignore +++ b/.gitignore @@ -51,3 +51,7 @@ lib/**/*.g.dart # Personal lib/example design/ + +# l10n +lib/l10n/arbs/intl_messages.arb +lib/l10n/gen/messages_messages.dart \ No newline at end of file diff --git a/README_web.md b/README_web.md new file mode 100644 index 0000000..764b98c --- /dev/null +++ b/README_web.md @@ -0,0 +1,4 @@ +# DST Helper application for web 🌈 +https://woin2ee.github.io/DST-Helper-web/ + +This repository is a dedicated one for web hosting using github pages. The source code is in [DST-Helper](https://github.com/woin2ee/DST-Helper). diff --git a/lib/cook_page/recipe_list/recipe_list.dart b/lib/cook_page/recipe_list/recipe_list.dart index e202cfa..abc8031 100644 --- a/lib/cook_page/recipe_list/recipe_list.dart +++ b/lib/cook_page/recipe_list/recipe_list.dart @@ -4,6 +4,8 @@ import 'package:dst_helper/l10n/l10ns.dart'; import 'package:dst_helper/models/v2/item/item.dart'; import 'package:dst_helper/utils/font_family.dart'; import 'package:flutter/material.dart'; +import 'package:intl/intl.dart'; +import 'package:toastification/toastification.dart'; class RecipeList extends StatefulWidget { RecipeList() : super(key: GlobalKey()); @@ -21,6 +23,11 @@ class _RecipeListState extends State { Widget build(BuildContext context) { return DragTarget( onAcceptWithDetails: (details) { + var recipe = details.data; + if (_recipeListNotifier.value.contains(recipe)) { + _showToast(context); + return; + } _recipeListNotifier.addRecipe(details.data); }, builder: (context, candidateItems, rejectedItems) { @@ -67,4 +74,27 @@ class _RecipeListState extends State { }, ); } + + void _showToast(BuildContext context) { + String message() => Intl.message( + 'The recipe is already registered.', + desc: "It's showed up when a duplicated recipe card is registered to list.", + locale: Localizations.localeOf(context).languageCode, + ); + + toastification.show( + context: context, + alignment: Alignment.bottomCenter, + icon: const Icon(Icons.warning), + style: ToastificationStyle.flatColored, + primaryColor: Colors.grey, + backgroundColor: Colors.grey.shade100, + title: Text(message()), + autoCloseDuration: const Duration(seconds: 2), + animationDuration: const Duration(milliseconds: 300), + pauseOnHover: false, + boxShadow: kElevationToShadow[3], + dragToClose: false, + ); + } } diff --git a/lib/cook_page/recipe_list/recipe_list_notifier.dart b/lib/cook_page/recipe_list/recipe_list_notifier.dart index 38f22f0..62c9222 100644 --- a/lib/cook_page/recipe_list/recipe_list_notifier.dart +++ b/lib/cook_page/recipe_list/recipe_list_notifier.dart @@ -30,7 +30,6 @@ class RecipeListNotifier extends ChangeNotifier { List get value => _value.toList(); void addRecipe(Recipe recipe) { - if (_value.contains(recipe)) return; _value.add(recipe); notifyListeners(); } diff --git a/lib/l10n/arbs/intl_en.arb b/lib/l10n/arbs/intl_en.arb index 3968eec..7158db3 100644 --- a/lib/l10n/arbs/intl_en.arb +++ b/lib/l10n/arbs/intl_en.arb @@ -1,6 +1,12 @@ { "@@last_modified": "2025-02-04T22:53:33.904153", "@@locale": "en", + "The recipe is already registered.": "The recipe is already registered.", + "@The recipe is already registered.": { + "description": "It's showed up when a duplicated recipe card is registered to list.", + "type": "text", + "placeholders": {} + }, "seasonConditionSatisfyingText": "Becomes a giant crop in the {seasonsText}!", "@seasonConditionSatisfyingText": { "type": "text", diff --git a/lib/l10n/arbs/intl_ko.arb b/lib/l10n/arbs/intl_ko.arb index e1040ba..ddaf74a 100644 --- a/lib/l10n/arbs/intl_ko.arb +++ b/lib/l10n/arbs/intl_ko.arb @@ -1,6 +1,12 @@ { "@@last_modified": "2025-02-04T22:53:33.904153", "@@locale": "ko", + "The recipe is already registered.": "이미 λ“±λ‘λ˜μ–΄ μžˆλŠ” λ ˆμ‹œν”Όμž…λ‹ˆλ‹€.", + "@The recipe is already registered.": { + "description": "It's showed up when a duplicated recipe card is registered to list.", + "type": "text", + "placeholders": {} + }, "seasonConditionSatisfyingText": "{seasonsText}에 κ±°λŒ€ μž‘λ¬Όμ΄ λ©λ‹ˆλ‹€!", "@seasonConditionSatisfyingText": { "type": "text", diff --git a/lib/l10n/arbs/intl_messages.arb b/lib/l10n/arbs/intl_messages.arb deleted file mode 100644 index 6b5b3d5..0000000 --- a/lib/l10n/arbs/intl_messages.arb +++ /dev/null @@ -1,707 +0,0 @@ -{ - "@@last_modified": "2025-02-04T22:53:33.904153", - "seasonConditionSatisfyingText": "Becomes a giant crop in the {seasonsText}!", - "@seasonConditionSatisfyingText": { - "type": "text", - "placeholders": { - "seasonsText": { - "example": "spring, fall" - } - } - }, - "recipe_list_guide_message": "recipe_list_guide_message", - "@recipe_list_guide_message": { - "type": "text", - "placeholders": {} - }, - "fertilizer_selection_tooltip": "fertilizer_selection_tooltip", - "@fertilizer_selection_tooltip": { - "type": "text", - "placeholders": {} - }, - "add": "add", - "@add": { - "type": "text", - "placeholders": {} - }, - "asparagus_seeds_assumed_name": "asparagus_seeds_assumed_name", - "@asparagus_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "autumn": "autumn", - "@autumn": { - "type": "text", - "placeholders": {} - }, - "back_dialog_message": "back_dialog_message", - "@back_dialog_message": { - "type": "text", - "placeholders": {} - }, - "back_dialog_title": "back_dialog_title", - "@back_dialog_title": { - "type": "text", - "placeholders": {} - }, - "basic": "basic", - "@basic": { - "type": "text", - "placeholders": {} - }, - "butterflymuffin": "butterflymuffin", - "@butterflymuffin": { - "type": "text", - "placeholders": {} - }, - "cancel": "cancel", - "@cancel": { - "type": "text", - "placeholders": {} - }, - "carrot_seeds_assumed_name": "carrot_seeds_assumed_name", - "@carrot_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "compost": "compost", - "@compost": { - "type": "text", - "placeholders": {} - }, - "compostwrap": "compostwrap", - "@compostwrap": { - "type": "text", - "placeholders": {} - }, - "confirm": "confirm", - "@confirm": { - "type": "text", - "placeholders": {} - }, - "corn_seeds_assumed_name": "corn_seeds_assumed_name", - "@corn_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "crops": "crops", - "@crops": { - "type": "text", - "placeholders": {} - }, - "delete": "delete", - "@delete": { - "type": "text", - "placeholders": {} - }, - "dense": "dense", - "@dense": { - "type": "text", - "placeholders": {} - }, - "done": "done", - "@done": { - "type": "text", - "placeholders": {} - }, - "dragonfruit_seeds_assumed_name": "dragonfruit_seeds_assumed_name", - "@dragonfruit_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "durian_seeds_assumed_name": "durian_seeds_assumed_name", - "@durian_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "edit": "edit", - "@edit": { - "type": "text", - "placeholders": {} - }, - "eggplant_seeds_assumed_name": "eggplant_seeds_assumed_name", - "@eggplant_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "family_condition_satisfying_text": "family_condition_satisfying_text", - "@family_condition_satisfying_text": { - "type": "text", - "placeholders": {} - }, - "family_condition_unsatisfying_first_text": "family_condition_unsatisfying_first_text", - "@family_condition_unsatisfying_first_text": { - "type": "text", - "placeholders": {} - }, - "family_condition_unsatisfying_secondary_text": "family_condition_unsatisfying_secondary_text", - "@family_condition_unsatisfying_secondary_text": { - "type": "text", - "placeholders": {} - }, - "fertilizer": "fertilizer", - "@fertilizer": { - "type": "text", - "placeholders": {} - }, - "fertilizers": "fertilizers", - "@fertilizers": { - "type": "text", - "placeholders": {} - }, - "garlic_seeds_assumed_name": "garlic_seeds_assumed_name", - "@garlic_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "giant_crop": "giant_crop", - "@giant_crop": { - "type": "text", - "placeholders": {} - }, - "glommerfuel": "glommerfuel", - "@glommerfuel": { - "type": "text", - "placeholders": {} - }, - "growthFormula": "growthFormula", - "@growthFormula": { - "type": "text", - "placeholders": {} - }, - "guano": "guano", - "@guano": { - "type": "text", - "placeholders": {} - }, - "hide": "hide", - "@hide": { - "type": "text", - "placeholders": {} - }, - "manure": "manure", - "@manure": { - "type": "text", - "placeholders": {} - }, - "menu_cook": "menu_cook", - "@menu_cook": { - "type": "text", - "placeholders": {} - }, - "menu_farm": "menu_farm", - "@menu_farm": { - "type": "text", - "placeholders": {} - }, - "mix": "mix", - "@mix": { - "type": "text", - "placeholders": {} - }, - "name": "name", - "@name": { - "type": "text", - "placeholders": {} - }, - "no_crops_message": "no_crops_message", - "@no_crops_message": { - "type": "text", - "placeholders": {} - }, - "nutrient_condition_satisfying_first_text": "nutrient_condition_satisfying_first_text", - "@nutrient_condition_satisfying_first_text": { - "type": "text", - "placeholders": {} - }, - "nutrient_condition_unsatisfying_first_text": "nutrient_condition_unsatisfying_first_text", - "@nutrient_condition_unsatisfying_first_text": { - "type": "text", - "placeholders": {} - }, - "nutrient_condition_unsatisfying_secondary_text": "nutrient_condition_unsatisfying_secondary_text", - "@nutrient_condition_unsatisfying_secondary_text": { - "type": "text", - "placeholders": {} - }, - "onion_seeds_assumed_name": "onion_seeds_assumed_name", - "@onion_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "pepper_seeds_assumed_name": "pepper_seeds_assumed_name", - "@pepper_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "pomegranate_seeds_assumed_name": "pomegranate_seeds_assumed_name", - "@pomegranate_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "poop": "poop", - "@poop": { - "type": "text", - "placeholders": {} - }, - "potato_seeds_assumed_name": "potato_seeds_assumed_name", - "@potato_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "pumpkin_seeds_assumed_name": "pumpkin_seeds_assumed_name", - "@pumpkin_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "reverse_dense": "reverse_dense", - "@reverse_dense": { - "type": "text", - "placeholders": {} - }, - "rottenegg": "rottenegg", - "@rottenegg": { - "type": "text", - "placeholders": {} - }, - "season_condition_unsatisfying_first_text": "season_condition_unsatisfying_first_text", - "@season_condition_unsatisfying_first_text": { - "type": "text", - "placeholders": {} - }, - "season_condition_unsatisfying_secondary_text": "season_condition_unsatisfying_secondary_text", - "@season_condition_unsatisfying_secondary_text": { - "type": "text", - "placeholders": {} - }, - "seeds": "seeds", - "@seeds": { - "type": "text", - "placeholders": {} - }, - "show": "show", - "@show": { - "type": "text", - "placeholders": {} - }, - "show_hidden_items": "show_hidden_items", - "@show_hidden_items": { - "type": "text", - "placeholders": {} - }, - "show_seeds_alias": "show_seeds_alias", - "@show_seeds_alias": { - "type": "text", - "placeholders": {} - }, - "soil_amender": "soil_amender", - "@soil_amender": { - "type": "text", - "placeholders": {} - }, - "spoiled_fish": "spoiled_fish", - "@spoiled_fish": { - "type": "text", - "placeholders": {} - }, - "spoiled_fish_small": "spoiled_fish_small", - "@spoiled_fish_small": { - "type": "text", - "placeholders": {} - }, - "spoiled_food": "spoiled_food", - "@spoiled_food": { - "type": "text", - "placeholders": {} - }, - "spring": "spring", - "@spring": { - "type": "text", - "placeholders": {} - }, - "suitable_seasons": "suitable_seasons", - "@suitable_seasons": { - "type": "text", - "placeholders": {} - }, - "season": "season", - "@season": { - "type": "text", - "placeholders": {} - }, - "summer": "summer", - "@summer": { - "type": "text", - "placeholders": {} - }, - "tomato_seeds_assumed_name": "tomato_seeds_assumed_name", - "@tomato_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "treegrowthsolution": "treegrowthsolution", - "@treegrowthsolution": { - "type": "text", - "placeholders": {} - }, - "watermelon_seeds_assumed_name": "watermelon_seeds_assumed_name", - "@watermelon_seeds_assumed_name": { - "type": "text", - "placeholders": {} - }, - "winter": "winter", - "@winter": { - "type": "text", - "placeholders": {} - }, - "dustmeringue_name": "dustmeringue_name", - "@dustmeringue_name": { - "type": "text", - "placeholders": {} - }, - "asparagussoup_name": "asparagussoup_name", - "@asparagussoup_name": { - "type": "text", - "placeholders": {} - }, - "baconeggs_name": "baconeggs_name", - "@baconeggs_name": { - "type": "text", - "placeholders": {} - }, - "bananapop_name": "bananapop_name", - "@bananapop_name": { - "type": "text", - "placeholders": {} - }, - "bananajuice_name": "bananajuice_name", - "@bananajuice_name": { - "type": "text", - "placeholders": {} - }, - "barnaclinguine_name": "barnaclinguine_name", - "@barnaclinguine_name": { - "type": "text", - "placeholders": {} - }, - "barnaclesushi_name": "barnaclesushi_name", - "@barnaclesushi_name": { - "type": "text", - "placeholders": {} - }, - "barnaclepita_name": "barnaclepita_name", - "@barnaclepita_name": { - "type": "text", - "placeholders": {} - }, - "beefalotreat_name": "beefalotreat_name", - "@beefalotreat_name": { - "type": "text", - "placeholders": {} - }, - "meatysalad_name": "meatysalad_name", - "@meatysalad_name": { - "type": "text", - "placeholders": {} - }, - "veggieomlet_name": "veggieomlet_name", - "@veggieomlet_name": { - "type": "text", - "placeholders": {} - }, - "bunnystew_name": "bunnystew_name", - "@bunnystew_name": { - "type": "text", - "placeholders": {} - }, - "butterflymuffin_name": "butterflymuffin_name", - "@butterflymuffin_name": { - "type": "text", - "placeholders": {} - }, - "californiaroll_name": "californiaroll_name", - "@californiaroll_name": { - "type": "text", - "placeholders": {} - }, - "ceviche_name": "ceviche_name", - "@ceviche_name": { - "type": "text", - "placeholders": {} - }, - "mashedpotatoes_name": "mashedpotatoes_name", - "@mashedpotatoes_name": { - "type": "text", - "placeholders": {} - }, - "dragonpie_name": "dragonpie_name", - "@dragonpie_name": { - "type": "text", - "placeholders": {} - }, - "potatotornado_name": "potatotornado_name", - "@potatotornado_name": { - "type": "text", - "placeholders": {} - }, - "figatoni_name": "figatoni_name", - "@figatoni_name": { - "type": "text", - "placeholders": {} - }, - "frognewton_name": "frognewton_name", - "@frognewton_name": { - "type": "text", - "placeholders": {} - }, - "figkabab_name": "figkabab_name", - "@figkabab_name": { - "type": "text", - "placeholders": {} - }, - "koalefig_trunk_name": "koalefig_trunk_name", - "@koalefig_trunk_name": { - "type": "text", - "placeholders": {} - }, - "fishtacos_name": "fishtacos_name", - "@fishtacos_name": { - "type": "text", - "placeholders": {} - }, - "fishsticks_name": "fishsticks_name", - "@fishsticks_name": { - "type": "text", - "placeholders": {} - }, - "jammypreserves_name": "jammypreserves_name", - "@jammypreserves_name": { - "type": "text", - "placeholders": {} - }, - "flowersalad_name": "flowersalad_name", - "@flowersalad_name": { - "type": "text", - "placeholders": {} - }, - "frogglebunwich_name": "frogglebunwich_name", - "@frogglebunwich_name": { - "type": "text", - "placeholders": {} - }, - "frozenbananadaiquiri_name": "frozenbananadaiquiri_name", - "@frozenbananadaiquiri_name": { - "type": "text", - "placeholders": {} - }, - "fruitmedley_name": "fruitmedley_name", - "@fruitmedley_name": { - "type": "text", - "placeholders": {} - }, - "guacamole_name": "guacamole_name", - "@guacamole_name": { - "type": "text", - "placeholders": {} - }, - "honeyham_name": "honeyham_name", - "@honeyham_name": { - "type": "text", - "placeholders": {} - }, - "honeynuggets_name": "honeynuggets_name", - "@honeynuggets_name": { - "type": "text", - "placeholders": {} - }, - "icecream_name": "icecream_name", - "@icecream_name": { - "type": "text", - "placeholders": {} - }, - "jellybean_name": "jellybean_name", - "@jellybean_name": { - "type": "text", - "placeholders": {} - }, - "leafymeatsouffle_name": "leafymeatsouffle_name", - "@leafymeatsouffle_name": { - "type": "text", - "placeholders": {} - }, - "kabobs_name": "kabobs_name", - "@kabobs_name": { - "type": "text", - "placeholders": {} - }, - "mandrakesoup_name": "mandrakesoup_name", - "@mandrakesoup_name": { - "type": "text", - "placeholders": {} - }, - "meatballs_name": "meatballs_name", - "@meatballs_name": { - "type": "text", - "placeholders": {} - }, - "bonestew_name": "bonestew_name", - "@bonestew_name": { - "type": "text", - "placeholders": {} - }, - "watermelonicle_name": "watermelonicle_name", - "@watermelonicle_name": { - "type": "text", - "placeholders": {} - }, - "batnosehat_name": "batnosehat_name", - "@batnosehat_name": { - "type": "text", - "placeholders": {} - }, - "monsterlasagna_name": "monsterlasagna_name", - "@monsterlasagna_name": { - "type": "text", - "placeholders": {} - }, - "shroomcake_name": "shroomcake_name", - "@shroomcake_name": { - "type": "text", - "placeholders": {} - }, - "leafloaf_name": "leafloaf_name", - "@leafloaf_name": { - "type": "text", - "placeholders": {} - }, - "perogies_name": "perogies_name", - "@perogies_name": { - "type": "text", - "placeholders": {} - }, - "justeggs_name": "justeggs_name", - "@justeggs_name": { - "type": "text", - "placeholders": {} - }, - "powcake_name": "powcake_name", - "@powcake_name": { - "type": "text", - "placeholders": {} - }, - "pumpkincookie_name": "pumpkincookie_name", - "@pumpkincookie_name": { - "type": "text", - "placeholders": {} - }, - "ratatouille_name": "ratatouille_name", - "@ratatouille_name": { - "type": "text", - "placeholders": {} - }, - "salsa_name": "salsa_name", - "@salsa_name": { - "type": "text", - "placeholders": {} - }, - "seafoodgumbo_name": "seafoodgumbo_name", - "@seafoodgumbo_name": { - "type": "text", - "placeholders": {} - }, - "sweettea_name": "sweettea_name", - "@sweettea_name": { - "type": "text", - "placeholders": {} - }, - "hotchili_name": "hotchili_name", - "@hotchili_name": { - "type": "text", - "placeholders": {} - }, - "beefalofeed_name": "beefalofeed_name", - "@beefalofeed_name": { - "type": "text", - "placeholders": {} - }, - "stuffedeggplant_name": "stuffedeggplant_name", - "@stuffedeggplant_name": { - "type": "text", - "placeholders": {} - }, - "barnaclestuffedfishhead_name": "barnaclestuffedfishhead_name", - "@barnaclestuffedfishhead_name": { - "type": "text", - "placeholders": {} - }, - "shroombait_name": "shroombait_name", - "@shroombait_name": { - "type": "text", - "placeholders": {} - }, - "pepperpopper_name": "pepperpopper_name", - "@pepperpopper_name": { - "type": "text", - "placeholders": {} - }, - "surfnturf_name": "surfnturf_name", - "@surfnturf_name": { - "type": "text", - "placeholders": {} - }, - "taffy_name": "taffy_name", - "@taffy_name": { - "type": "text", - "placeholders": {} - }, - "talleggs_name": "talleggs_name", - "@talleggs_name": { - "type": "text", - "placeholders": {} - }, - "trailmix_name": "trailmix_name", - "@trailmix_name": { - "type": "text", - "placeholders": {} - }, - "turkeydinner_name": "turkeydinner_name", - "@turkeydinner_name": { - "type": "text", - "placeholders": {} - }, - "unagi_name": "unagi_name", - "@unagi_name": { - "type": "text", - "placeholders": {} - }, - "leafymeatburger_name": "leafymeatburger_name", - "@leafymeatburger_name": { - "type": "text", - "placeholders": {} - }, - "vegstinger_name": "vegstinger_name", - "@vegstinger_name": { - "type": "text", - "placeholders": {} - }, - "waffles_name": "waffles_name", - "@waffles_name": { - "type": "text", - "placeholders": {} - }, - "wetgoop_name": "wetgoop_name", - "@wetgoop_name": { - "type": "text", - "placeholders": {} - }, - "lobsterbisque_name": "lobsterbisque_name", - "@lobsterbisque_name": { - "type": "text", - "placeholders": {} - }, - "lobsterdinner_name": "lobsterdinner_name", - "@lobsterdinner_name": { - "type": "text", - "placeholders": {} - } -} \ No newline at end of file diff --git a/lib/l10n/gen/messages_all_locales.dart b/lib/l10n/gen/messages_all_locales.dart index cb6f6ae..ef42614 100644 --- a/lib/l10n/gen/messages_all_locales.dart +++ b/lib/l10n/gen/messages_all_locales.dart @@ -15,13 +15,11 @@ import 'package:intl/src/intl_helpers.dart'; import 'messages_en.dart' as messages_en; import 'messages_ko.dart' as messages_ko; -import 'messages_messages.dart' as messages_messages; typedef Future LibraryLoader(); Map _deferredLibraries = { 'en': () => Future.value(null), 'ko': () => Future.value(null), - 'messages': () => Future.value(null), }; MessageLookupByLibrary? _findExact(String localeName) { @@ -30,8 +28,6 @@ MessageLookupByLibrary? _findExact(String localeName) { return messages_en.messages; case 'ko': return messages_ko.messages; - case 'messages': - return messages_messages.messages; default: return null; } @@ -39,8 +35,10 @@ MessageLookupByLibrary? _findExact(String localeName) { /// User programs should call this before using [localeName] for messages. Future initializeMessages(String? localeName) async { - var availableLocale = - Intl.verifiedLocale(localeName, (locale) => _deferredLibraries[locale] != null, onFailure: (_) => null); + var availableLocale = Intl.verifiedLocale( + localeName, + (locale) => _deferredLibraries[locale] != null, + onFailure: (_) => null); if (availableLocale == null) { return Future.value(false); } @@ -60,7 +58,8 @@ bool _messagesExistFor(String locale) { } MessageLookupByLibrary? _findGeneratedMessagesFor(String locale) { - var actualLocale = Intl.verifiedLocale(locale, _messagesExistFor, onFailure: (_) => null); + var actualLocale = Intl.verifiedLocale(locale, _messagesExistFor, + onFailure: (_) => null); if (actualLocale == null) return null; return _findExact(actualLocale); } diff --git a/lib/l10n/gen/messages_en.dart b/lib/l10n/gen/messages_en.dart index 78c8ab5..c067ec0 100644 --- a/lib/l10n/gen/messages_en.dart +++ b/lib/l10n/gen/messages_en.dart @@ -27,7 +27,8 @@ class MessageLookup extends MessageLookupByLibrary { final Map messages = _notInlinedMessages(_notInlinedMessages); static Map _notInlinedMessages(_) => { - 'add': MessageLookupByLibrary.simpleMessage('Add'), + 'The recipe is already registered.': MessageLookupByLibrary.simpleMessage('The recipe is already registered.'), + 'add': MessageLookupByLibrary.simpleMessage('Add'), 'asparagus_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('Tubular Seeds'), 'asparagussoup_name': MessageLookupByLibrary.simpleMessage('Asparagus Soup'), 'autumn': MessageLookupByLibrary.simpleMessage('Autumn'), diff --git a/lib/l10n/gen/messages_ko.dart b/lib/l10n/gen/messages_ko.dart index 1df9d9d..567f92c 100644 --- a/lib/l10n/gen/messages_ko.dart +++ b/lib/l10n/gen/messages_ko.dart @@ -27,7 +27,8 @@ class MessageLookup extends MessageLookupByLibrary { final Map messages = _notInlinedMessages(_notInlinedMessages); static Map _notInlinedMessages(_) => { - 'add': MessageLookupByLibrary.simpleMessage('μΆ”κ°€'), + 'The recipe is already registered.': MessageLookupByLibrary.simpleMessage('이미 λ“±λ‘λ˜μ–΄ μžˆλŠ” λ ˆμ‹œν”Όμž…λ‹ˆλ‹€.'), + 'add': MessageLookupByLibrary.simpleMessage('μΆ”κ°€'), 'asparagus_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('κ΄€λͺ¨μ–‘ 씨앗'), 'asparagussoup_name': MessageLookupByLibrary.simpleMessage('μ•„μŠ€νŒŒλΌκ±°μŠ€ μˆ˜ν”„'), 'autumn': MessageLookupByLibrary.simpleMessage('가을'), diff --git a/lib/l10n/gen/messages_messages.dart b/lib/l10n/gen/messages_messages.dart deleted file mode 100644 index 58f0ebe..0000000 --- a/lib/l10n/gen/messages_messages.dart +++ /dev/null @@ -1,171 +0,0 @@ -// DO NOT EDIT. This is code generated via package:intl/generate_localized.dart -// This is a library that provides messages for a messages locale. All the -// messages from the main program should be duplicated here with the same -// function name. -// @dart=2.12 -// Ignore issues from commonly used lints in this file. -// ignore_for_file:unnecessary_brace_in_string_interps -// ignore_for_file:prefer_single_quotes,comment_references, directives_ordering -// ignore_for_file:annotate_overrides,prefer_generic_function_type_aliases -// ignore_for_file:unused_import, file_names - -import 'package:intl/intl.dart'; -import 'package:intl/message_lookup_by_library.dart'; - -final messages = MessageLookup(); - -typedef String? MessageIfAbsent( - String? messageStr, List? args); - -class MessageLookup extends MessageLookupByLibrary { - @override - String get localeName => 'messages'; - - static m0(seasonsText) => "Becomes a giant crop in the ${seasonsText}!"; - - @override - final Map messages = _notInlinedMessages(_notInlinedMessages); - - static Map _notInlinedMessages(_) => { - 'add': MessageLookupByLibrary.simpleMessage('add'), - 'asparagus_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('asparagus_seeds_assumed_name'), - 'asparagussoup_name': MessageLookupByLibrary.simpleMessage('asparagussoup_name'), - 'autumn': MessageLookupByLibrary.simpleMessage('autumn'), - 'back_dialog_message': MessageLookupByLibrary.simpleMessage('back_dialog_message'), - 'back_dialog_title': MessageLookupByLibrary.simpleMessage('back_dialog_title'), - 'baconeggs_name': MessageLookupByLibrary.simpleMessage('baconeggs_name'), - 'bananajuice_name': MessageLookupByLibrary.simpleMessage('bananajuice_name'), - 'bananapop_name': MessageLookupByLibrary.simpleMessage('bananapop_name'), - 'barnaclepita_name': MessageLookupByLibrary.simpleMessage('barnaclepita_name'), - 'barnaclestuffedfishhead_name': MessageLookupByLibrary.simpleMessage('barnaclestuffedfishhead_name'), - 'barnaclesushi_name': MessageLookupByLibrary.simpleMessage('barnaclesushi_name'), - 'barnaclinguine_name': MessageLookupByLibrary.simpleMessage('barnaclinguine_name'), - 'basic': MessageLookupByLibrary.simpleMessage('basic'), - 'batnosehat_name': MessageLookupByLibrary.simpleMessage('batnosehat_name'), - 'beefalofeed_name': MessageLookupByLibrary.simpleMessage('beefalofeed_name'), - 'beefalotreat_name': MessageLookupByLibrary.simpleMessage('beefalotreat_name'), - 'bonestew_name': MessageLookupByLibrary.simpleMessage('bonestew_name'), - 'bunnystew_name': MessageLookupByLibrary.simpleMessage('bunnystew_name'), - 'butterflymuffin': MessageLookupByLibrary.simpleMessage('butterflymuffin'), - 'butterflymuffin_name': MessageLookupByLibrary.simpleMessage('butterflymuffin_name'), - 'californiaroll_name': MessageLookupByLibrary.simpleMessage('californiaroll_name'), - 'cancel': MessageLookupByLibrary.simpleMessage('cancel'), - 'carrot_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('carrot_seeds_assumed_name'), - 'ceviche_name': MessageLookupByLibrary.simpleMessage('ceviche_name'), - 'compost': MessageLookupByLibrary.simpleMessage('compost'), - 'compostwrap': MessageLookupByLibrary.simpleMessage('compostwrap'), - 'confirm': MessageLookupByLibrary.simpleMessage('confirm'), - 'corn_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('corn_seeds_assumed_name'), - 'crops': MessageLookupByLibrary.simpleMessage('crops'), - 'delete': MessageLookupByLibrary.simpleMessage('delete'), - 'dense': MessageLookupByLibrary.simpleMessage('dense'), - 'done': MessageLookupByLibrary.simpleMessage('done'), - 'dragonfruit_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('dragonfruit_seeds_assumed_name'), - 'dragonpie_name': MessageLookupByLibrary.simpleMessage('dragonpie_name'), - 'durian_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('durian_seeds_assumed_name'), - 'dustmeringue_name': MessageLookupByLibrary.simpleMessage('dustmeringue_name'), - 'edit': MessageLookupByLibrary.simpleMessage('edit'), - 'eggplant_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('eggplant_seeds_assumed_name'), - 'family_condition_satisfying_text': MessageLookupByLibrary.simpleMessage('family_condition_satisfying_text'), - 'family_condition_unsatisfying_first_text': MessageLookupByLibrary.simpleMessage('family_condition_unsatisfying_first_text'), - 'family_condition_unsatisfying_secondary_text': MessageLookupByLibrary.simpleMessage('family_condition_unsatisfying_secondary_text'), - 'fertilizer': MessageLookupByLibrary.simpleMessage('fertilizer'), - 'fertilizer_selection_tooltip': MessageLookupByLibrary.simpleMessage('fertilizer_selection_tooltip'), - 'fertilizers': MessageLookupByLibrary.simpleMessage('fertilizers'), - 'figatoni_name': MessageLookupByLibrary.simpleMessage('figatoni_name'), - 'figkabab_name': MessageLookupByLibrary.simpleMessage('figkabab_name'), - 'fishsticks_name': MessageLookupByLibrary.simpleMessage('fishsticks_name'), - 'fishtacos_name': MessageLookupByLibrary.simpleMessage('fishtacos_name'), - 'flowersalad_name': MessageLookupByLibrary.simpleMessage('flowersalad_name'), - 'frogglebunwich_name': MessageLookupByLibrary.simpleMessage('frogglebunwich_name'), - 'frognewton_name': MessageLookupByLibrary.simpleMessage('frognewton_name'), - 'frozenbananadaiquiri_name': MessageLookupByLibrary.simpleMessage('frozenbananadaiquiri_name'), - 'fruitmedley_name': MessageLookupByLibrary.simpleMessage('fruitmedley_name'), - 'garlic_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('garlic_seeds_assumed_name'), - 'giant_crop': MessageLookupByLibrary.simpleMessage('giant_crop'), - 'glommerfuel': MessageLookupByLibrary.simpleMessage('glommerfuel'), - 'growthFormula': MessageLookupByLibrary.simpleMessage('growthFormula'), - 'guacamole_name': MessageLookupByLibrary.simpleMessage('guacamole_name'), - 'guano': MessageLookupByLibrary.simpleMessage('guano'), - 'hide': MessageLookupByLibrary.simpleMessage('hide'), - 'honeyham_name': MessageLookupByLibrary.simpleMessage('honeyham_name'), - 'honeynuggets_name': MessageLookupByLibrary.simpleMessage('honeynuggets_name'), - 'hotchili_name': MessageLookupByLibrary.simpleMessage('hotchili_name'), - 'icecream_name': MessageLookupByLibrary.simpleMessage('icecream_name'), - 'jammypreserves_name': MessageLookupByLibrary.simpleMessage('jammypreserves_name'), - 'jellybean_name': MessageLookupByLibrary.simpleMessage('jellybean_name'), - 'justeggs_name': MessageLookupByLibrary.simpleMessage('justeggs_name'), - 'kabobs_name': MessageLookupByLibrary.simpleMessage('kabobs_name'), - 'koalefig_trunk_name': MessageLookupByLibrary.simpleMessage('koalefig_trunk_name'), - 'leafloaf_name': MessageLookupByLibrary.simpleMessage('leafloaf_name'), - 'leafymeatburger_name': MessageLookupByLibrary.simpleMessage('leafymeatburger_name'), - 'leafymeatsouffle_name': MessageLookupByLibrary.simpleMessage('leafymeatsouffle_name'), - 'lobsterbisque_name': MessageLookupByLibrary.simpleMessage('lobsterbisque_name'), - 'lobsterdinner_name': MessageLookupByLibrary.simpleMessage('lobsterdinner_name'), - 'mandrakesoup_name': MessageLookupByLibrary.simpleMessage('mandrakesoup_name'), - 'manure': MessageLookupByLibrary.simpleMessage('manure'), - 'mashedpotatoes_name': MessageLookupByLibrary.simpleMessage('mashedpotatoes_name'), - 'meatballs_name': MessageLookupByLibrary.simpleMessage('meatballs_name'), - 'meatysalad_name': MessageLookupByLibrary.simpleMessage('meatysalad_name'), - 'menu_cook': MessageLookupByLibrary.simpleMessage('menu_cook'), - 'menu_farm': MessageLookupByLibrary.simpleMessage('menu_farm'), - 'mix': MessageLookupByLibrary.simpleMessage('mix'), - 'monsterlasagna_name': MessageLookupByLibrary.simpleMessage('monsterlasagna_name'), - 'name': MessageLookupByLibrary.simpleMessage('name'), - 'no_crops_message': MessageLookupByLibrary.simpleMessage('no_crops_message'), - 'nutrient_condition_satisfying_first_text': MessageLookupByLibrary.simpleMessage('nutrient_condition_satisfying_first_text'), - 'nutrient_condition_unsatisfying_first_text': MessageLookupByLibrary.simpleMessage('nutrient_condition_unsatisfying_first_text'), - 'nutrient_condition_unsatisfying_secondary_text': MessageLookupByLibrary.simpleMessage('nutrient_condition_unsatisfying_secondary_text'), - 'onion_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('onion_seeds_assumed_name'), - 'pepper_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('pepper_seeds_assumed_name'), - 'pepperpopper_name': MessageLookupByLibrary.simpleMessage('pepperpopper_name'), - 'perogies_name': MessageLookupByLibrary.simpleMessage('perogies_name'), - 'pomegranate_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('pomegranate_seeds_assumed_name'), - 'poop': MessageLookupByLibrary.simpleMessage('poop'), - 'potato_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('potato_seeds_assumed_name'), - 'potatotornado_name': MessageLookupByLibrary.simpleMessage('potatotornado_name'), - 'powcake_name': MessageLookupByLibrary.simpleMessage('powcake_name'), - 'pumpkin_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('pumpkin_seeds_assumed_name'), - 'pumpkincookie_name': MessageLookupByLibrary.simpleMessage('pumpkincookie_name'), - 'ratatouille_name': MessageLookupByLibrary.simpleMessage('ratatouille_name'), - 'recipe_list_guide_message': MessageLookupByLibrary.simpleMessage('recipe_list_guide_message'), - 'reverse_dense': MessageLookupByLibrary.simpleMessage('reverse_dense'), - 'rottenegg': MessageLookupByLibrary.simpleMessage('rottenegg'), - 'salsa_name': MessageLookupByLibrary.simpleMessage('salsa_name'), - 'seafoodgumbo_name': MessageLookupByLibrary.simpleMessage('seafoodgumbo_name'), - 'season': MessageLookupByLibrary.simpleMessage('season'), - 'seasonConditionSatisfyingText': m0, - 'season_condition_unsatisfying_first_text': MessageLookupByLibrary.simpleMessage('season_condition_unsatisfying_first_text'), - 'season_condition_unsatisfying_secondary_text': MessageLookupByLibrary.simpleMessage('season_condition_unsatisfying_secondary_text'), - 'seeds': MessageLookupByLibrary.simpleMessage('seeds'), - 'show': MessageLookupByLibrary.simpleMessage('show'), - 'show_hidden_items': MessageLookupByLibrary.simpleMessage('show_hidden_items'), - 'show_seeds_alias': MessageLookupByLibrary.simpleMessage('show_seeds_alias'), - 'shroombait_name': MessageLookupByLibrary.simpleMessage('shroombait_name'), - 'shroomcake_name': MessageLookupByLibrary.simpleMessage('shroomcake_name'), - 'soil_amender': MessageLookupByLibrary.simpleMessage('soil_amender'), - 'spoiled_fish': MessageLookupByLibrary.simpleMessage('spoiled_fish'), - 'spoiled_fish_small': MessageLookupByLibrary.simpleMessage('spoiled_fish_small'), - 'spoiled_food': MessageLookupByLibrary.simpleMessage('spoiled_food'), - 'spring': MessageLookupByLibrary.simpleMessage('spring'), - 'stuffedeggplant_name': MessageLookupByLibrary.simpleMessage('stuffedeggplant_name'), - 'suitable_seasons': MessageLookupByLibrary.simpleMessage('suitable_seasons'), - 'summer': MessageLookupByLibrary.simpleMessage('summer'), - 'surfnturf_name': MessageLookupByLibrary.simpleMessage('surfnturf_name'), - 'sweettea_name': MessageLookupByLibrary.simpleMessage('sweettea_name'), - 'taffy_name': MessageLookupByLibrary.simpleMessage('taffy_name'), - 'talleggs_name': MessageLookupByLibrary.simpleMessage('talleggs_name'), - 'tomato_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('tomato_seeds_assumed_name'), - 'trailmix_name': MessageLookupByLibrary.simpleMessage('trailmix_name'), - 'treegrowthsolution': MessageLookupByLibrary.simpleMessage('treegrowthsolution'), - 'turkeydinner_name': MessageLookupByLibrary.simpleMessage('turkeydinner_name'), - 'unagi_name': MessageLookupByLibrary.simpleMessage('unagi_name'), - 'veggieomlet_name': MessageLookupByLibrary.simpleMessage('veggieomlet_name'), - 'vegstinger_name': MessageLookupByLibrary.simpleMessage('vegstinger_name'), - 'waffles_name': MessageLookupByLibrary.simpleMessage('waffles_name'), - 'watermelon_seeds_assumed_name': MessageLookupByLibrary.simpleMessage('watermelon_seeds_assumed_name'), - 'watermelonicle_name': MessageLookupByLibrary.simpleMessage('watermelonicle_name'), - 'wetgoop_name': MessageLookupByLibrary.simpleMessage('wetgoop_name'), - 'winter': MessageLookupByLibrary.simpleMessage('winter') - }; -} diff --git a/macos/Podfile.lock b/macos/Podfile.lock index 0a78730..6741893 100644 --- a/macos/Podfile.lock +++ b/macos/Podfile.lock @@ -22,7 +22,7 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24 shared_preferences_foundation: fcdcbc04712aee1108ac7fda236f363274528f78 - url_launcher_macos: 5f437abeda8c85500ceb03f5c1938a8c5a705399 + url_launcher_macos: c82c93949963e55b228a30115bd219499a6fe404 PODFILE CHECKSUM: 236401fc2c932af29a9fcf0e97baeeb2d750d367 diff --git a/pubspec.lock b/pubspec.lock index 8a2a25d..f50f261 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -182,6 +182,14 @@ packages: url: "https://pub.dev" source: hosted version: "2.3.7" + equatable: + dependency: transitive + description: + name: equatable + sha256: "567c64b3cb4cf82397aac55f4f0cbd3ca20d77c6c03bedbc4ceaddc08904aef7" + url: "https://pub.dev" + source: hosted + version: "2.0.7" fake_async: dependency: transitive description: @@ -298,6 +306,14 @@ packages: url: "https://pub.dev" source: hosted version: "4.1.2" + iconsax_flutter: + dependency: transitive + description: + name: iconsax_flutter + sha256: "95b65699da8ea98f87c5d232f06b0debaaf1ec1332b697e4d90969ec9a93037d" + url: "https://pub.dev" + source: hosted + version: "1.0.0" intersperse: dependency: "direct main" description: @@ -490,6 +506,14 @@ packages: url: "https://pub.dev" source: hosted version: "2.3.0" + pausable_timer: + dependency: transitive + description: + name: pausable_timer + sha256: "6ef1a95441ec3439de6fb63f39a011b67e693198e7dae14e20675c3c00e86074" + url: "https://pub.dev" + source: hosted + version: "3.1.0+3" platform: dependency: transitive description: @@ -711,6 +735,14 @@ packages: url: "https://pub.dev" source: hosted version: "1.0.2" + toastification: + dependency: "direct main" + description: + name: toastification + sha256: "4d97fbfa463dfe83691044cba9f37cb185a79bb9205cfecb655fa1f6be126a13" + url: "https://pub.dev" + source: hosted + version: "2.3.0" typed_data: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index 1653485..ce21866 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -53,6 +53,7 @@ dependencies: intersperse: ^2.0.0 intl_translation: ^0.20.0 styled_text: ^8.1.0 + toastification: ^2.3.0 dev_dependencies: flutter_test: