Files
food-ai/client/lib/l10n/app_zh.arb
dbastrikin 78f1c8bf76 feat: food search sheet with FTS+trgm, dish/recent endpoints, multilingual aliases
Backend:
- GET /dishes/search — hybrid FTS (english + simple) + trgm + ILIKE search
- GET /diary/recent — recently used dishes and products for the current user
- product search upgraded: FTS on canonical_name and product_aliases, ranked by GREATEST(ts_rank, similarity)
- importoff: collect product_name_ru/de/fr/... as product_aliases for multilingual search (e.g. "сникерс" → "Snickers")
- migrations: FTS + trgm indexes merged into 001_initial_schema.sql (002 removed)

Flutter:
- FoodSearchSheet: debounced search field, recently-used section, product/dish results, scan-photo and barcode chips
- DishPortionSheet: quick ½/1/1½/2 buttons + custom input
- + button in meal card now opens FoodSearchSheet instead of going directly to AI scan
- 7 new l10n keys across all 12 languages

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-21 15:28:29 +02:00

128 lines
3.8 KiB
Plaintext

{
"@@locale": "zh",
"appTitle": "FoodAI",
"greetingMorning": "早上好",
"greetingAfternoon": "下午好",
"greetingEvening": "晚上好",
"caloriesUnit": "千卡",
"gramsUnit": "克",
"goalLabel": "目标:",
"consumed": "已摄入",
"remaining": "剩余",
"exceeded": "超出",
"proteinLabel": "蛋白质",
"fatLabel": "脂肪",
"carbsLabel": "碳水化合物",
"today": "今天",
"yesterday": "昨天",
"mealsSection": "餐食",
"addDish": "添加菜品",
"scanDish": "扫描",
"menu": "菜单",
"dishHistory": "菜品历史",
"recommendCook": "推荐烹饪",
"camera": "相机",
"gallery": "相册",
"analyzingPhoto": "正在分析照片...",
"inQueue": "您在队列中",
"queuePosition": "位置 {position}",
"@queuePosition": {
"placeholders": {
"position": {
"type": "int"
}
}
},
"processing": "处理中...",
"upgradePrompt": "跳过队列?升级 →",
"recognitionFailed": "识别失败。请重试。",
"dishRecognition": "菜品识别",
"all": "全部",
"dishRecognized": "菜品已识别",
"recognizing": "识别中…",
"recognitionError": "识别错误",
"dishResultTitle": "菜品已识别",
"selectDish": "选择菜品",
"dishNotRecognized": "未识别到菜品",
"tryAgain": "重试",
"nutritionApproximate": "营养值为近似值 — 根据照片估算。",
"portion": "份量",
"mealType": "餐食类型",
"dateLabel": "日期",
"addToJournal": "添加到日记",
"addFailed": "添加失败。请重试。",
"historyTitle": "识别历史",
"historyLoadError": "加载历史失败",
"retry": "重试",
"noHistory": "暂无识别记录",
"profileTitle": "个人资料",
"edit": "编辑",
"bodyParams": "身体参数",
"goalActivity": "目标与活动",
"nutrition": "营养",
"settings": "设置",
"height": "身高",
"weight": "体重",
"age": "年龄",
"gender": "性别",
"genderMale": "男",
"genderFemale": "女",
"goalLoss": "减重",
"goalMaintain": "保持",
"goalGain": "增肌",
"activityLow": "低",
"activityMedium": "中",
"activityHigh": "高",
"calorieGoal": "卡路里目标",
"mealTypes": "餐食类型",
"formulaNote": "使用米夫林-圣热尔公式计算",
"language": "语言",
"notSet": "未设置",
"calorieHint": "输入身体参数以计算卡路里目标",
"logout": "退出登录",
"editProfile": "编辑资料",
"cancel": "取消",
"save": "保存",
"nameLabel": "姓名",
"heightCm": "身高(厘米)",
"weightKg": "体重(千克)",
"birthDate": "出生日期",
"nameRequired": "请输入姓名",
"profileUpdated": "资料已更新",
"profileSaveFailed": "保存失败",
"mealTypeBreakfast": "早餐",
"mealTypeSecondBreakfast": "第二早餐",
"mealTypeLunch": "午餐",
"mealTypeAfternoonSnack": "下午茶",
"mealTypeDinner": "晚餐",
"mealTypeSnack": "零食",
"navHome": "首页",
"navProducts": "食品",
"navRecipes": "食谱",
"addFromReceiptOrPhoto": "从收据或照片添加",
"chooseMethod": "选择方式",
"photoReceipt": "拍摄收据",
"photoReceiptSubtitle": "识别收据中的所有商品",
"photoProducts": "拍摄食品",
"photoProductsSubtitle": "冰箱、桌子、货架 — 最多3张照片",
"addPackagedFood": "添加包装食品",
"scanBarcode": "扫描条形码",
"portionWeightG": "份量(克)",
"productNotFound": "未找到产品",
"enterManually": "手动输入",
"perHundredG": "每100克",
"searchFoodHint": "搜索产品和菜肴...",
"recentlyUsedLabel": "最近使用",
"productsSection": "产品",
"dishesSection": "菜肴",
"noResultsForQuery": "未找到 \"{query}\" 的结果",
"@noResultsForQuery": {
"placeholders": {
"query": { "type": "String" }
}
},
"servingsLabel": "份数",
"addToDiary": "添加到日记",
"scanDishPhoto": "扫描照片"
}