Files
food-ai/client/lib/l10n/app_en.arb
dbastrikin 9580bff54e feat: flexible meal planning wizard — plan 1 meal, 1 day, several days, or a week
Backend:
- migration 005: expand menu_items.meal_type CHECK to all 6 types (second_breakfast, afternoon_snack, snack)
- ai/types.go: add Days and MealTypes to MenuRequest for partial generation
- openai/menu.go: parametrize GenerateMenu — use requested meal types and day count; add caloric fractions for all 6 meal types
- menu/repository.go: add UpsertItemsInTx for partial upsert (preserves existing slots); fix meal_type sort order in GetByWeek
- menu/handler.go: add dates+meal_types path to POST /ai/generate-menu; extract fetchImages/saveRecipes helpers; returns {"plans":[...]} for dates mode; backward-compatible with week mode

Client:
- PlanMenuSheet: bottom sheet with 4 planning horizon options
- PlanDatePickerSheet: adaptive sheet with date strip (single day/meal) or custom CalendarRangePicker (multi-day/week); sliding 7-day window for week mode
- menu_service.dart: add generateForDates
- menu_provider.dart: add PlanMenuService (generates + invalidates week providers), lastPlannedDateProvider
- home_screen.dart: add _PlanMenuButton card below quick actions; opens planning wizard
- l10n: 16 new keys for planning UI across all 12 languages

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-22 12:10:52 +02:00

155 lines
4.9 KiB
Plaintext

{
"@@locale": "en",
"appTitle": "FoodAI",
"greetingMorning": "Good morning",
"greetingAfternoon": "Good afternoon",
"greetingEvening": "Good evening",
"caloriesUnit": "kcal",
"gramsUnit": "g",
"goalLabel": "goal:",
"consumed": "Consumed",
"remaining": "Remaining",
"exceeded": "Exceeded",
"proteinLabel": "Protein",
"fatLabel": "Fat",
"carbsLabel": "Carbs",
"today": "Today",
"yesterday": "Yesterday",
"mealsSection": "Meals",
"addDish": "Add dish",
"scanDish": "Scan",
"menu": "Menu",
"dishHistory": "Dish history",
"recommendCook": "We recommend cooking",
"camera": "Camera",
"gallery": "Gallery",
"analyzingPhoto": "Analyzing photo...",
"inQueue": "You are in queue",
"queuePosition": "Position {position}",
"@queuePosition": {
"placeholders": {
"position": { "type": "int" }
}
},
"processing": "Processing...",
"upgradePrompt": "Skip the queue? Upgrade →",
"recognitionFailed": "Recognition failed. Try again.",
"dishRecognition": "Dish recognition",
"all": "All",
"dishRecognized": "Dish recognized",
"recognizing": "Recognizing…",
"recognitionError": "Recognition error",
"dishResultTitle": "Dish recognized",
"selectDish": "Select dish",
"dishNotRecognized": "Dish not recognized",
"tryAgain": "Try again",
"nutritionApproximate": "Nutrition is approximate — estimated from photo.",
"portion": "Portion",
"mealType": "Meal type",
"dateLabel": "Date",
"addToJournal": "Add to journal",
"addFailed": "Failed to add. Try again.",
"historyTitle": "Recognition history",
"historyLoadError": "Failed to load history",
"retry": "Retry",
"noHistory": "No recognitions yet",
"profileTitle": "Profile",
"edit": "Edit",
"bodyParams": "BODY PARAMS",
"goalActivity": "GOAL & ACTIVITY",
"nutrition": "NUTRITION",
"settings": "SETTINGS",
"height": "Height",
"weight": "Weight",
"age": "Age",
"gender": "Gender",
"genderMale": "Male",
"genderFemale": "Female",
"goalLoss": "Weight loss",
"goalMaintain": "Maintenance",
"goalGain": "Muscle gain",
"activityLow": "Low",
"activityMedium": "Medium",
"activityHigh": "High",
"calorieGoal": "Calorie goal",
"mealTypes": "Meal types",
"formulaNote": "Calculated using the Mifflin-St Jeor formula",
"language": "Language",
"notSet": "Not set",
"calorieHint": "Enter body params to calculate calorie goal",
"logout": "Log out",
"editProfile": "Edit profile",
"cancel": "Cancel",
"save": "Save",
"nameLabel": "Name",
"heightCm": "Height (cm)",
"weightKg": "Weight (kg)",
"birthDate": "Date of birth",
"nameRequired": "Enter name",
"profileUpdated": "Profile updated",
"profileSaveFailed": "Failed to save",
"mealTypeBreakfast": "Breakfast",
"mealTypeSecondBreakfast": "Second breakfast",
"mealTypeLunch": "Lunch",
"mealTypeAfternoonSnack": "Afternoon snack",
"mealTypeDinner": "Dinner",
"mealTypeSnack": "Snack",
"navHome": "Home",
"navProducts": "Products",
"navRecipes": "Recipes",
"addFromReceiptOrPhoto": "Add from receipt or photo",
"chooseMethod": "Choose method",
"photoReceipt": "Photo of receipt",
"photoReceiptSubtitle": "Recognize all items from a receipt",
"photoProducts": "Photo of products",
"photoProductsSubtitle": "Fridge, table, shelf — up to 3 photos",
"addPackagedFood": "Add packaged food",
"scanBarcode": "Scan barcode",
"portionWeightG": "Portion weight (g)",
"productNotFound": "Product not found",
"enterManually": "Enter manually",
"perHundredG": "per 100 g",
"searchFoodHint": "Search products and dishes...",
"recentlyUsedLabel": "Recently used",
"productsSection": "Products",
"dishesSection": "Dishes",
"noResultsForQuery": "Nothing found for \"{query}\"",
"@noResultsForQuery": {
"placeholders": {
"query": { "type": "String" }
}
},
"servingsLabel": "Servings",
"addToDiary": "Add to diary",
"scanDishPhoto": "Scan photo",
"planningForDate": "Planning for {date}",
"@planningForDate": {
"placeholders": {
"date": { "type": "String" }
}
},
"markAsEaten": "Mark as eaten",
"plannedMealLabel": "Planned",
"generateWeekLabel": "Plan the week",
"generateWeekSubtitle": "AI will create a menu with breakfast, lunch and dinner for the whole week",
"generatingMenu": "Generating menu...",
"weekPlannedLabel": "Week planned",
"planMenuButton": "Plan meals",
"planMenuTitle": "What to plan?",
"planOptionSingleMeal": "Single meal",
"planOptionSingleMealDesc": "Choose a day and meal type",
"planOptionDay": "One day",
"planOptionDayDesc": "All meals for one day",
"planOptionDays": "Several days",
"planOptionDaysDesc": "Custom date range",
"planOptionWeek": "A week",
"planOptionWeekDesc": "7 days at once",
"planSelectDate": "Select date",
"planSelectMealType": "Meal type",
"planSelectRange": "Select period",
"planGenerateButton": "Plan",
"planGenerating": "Generating plan\u2026",
"planSuccess": "Menu planned!"
}