Files
expo-popcore-app/locales/zh-CN.json
imeepos e1340fa101 feat: 实现 API 接口对接功能 (删除作品、作品搜索、修改密码)
按照 TDD 规范完成三个核心功能的接口对接:

## 新增功能

### 1. 删除作品功能 (app/generationRecord.tsx)
- 新增 use-template-generation-actions.ts hook
- 支持单个删除和批量删除作品
- 删除确认对话框
- 删除成功后自动刷新列表
- 完整的错误处理和加载状态

### 2. 作品搜索功能 (app/searchWorksResults.tsx)
- 新增 use-works-search.ts hook
- 替换模拟数据为真实 SDK 接口
- 支持关键词搜索和分类筛选
- 支持分页加载
- 完整的加载、错误、空结果状态处理

### 3. 修改密码功能 (app/changePassword.tsx)
- 新增 use-change-password.ts hook
- 使用 Better Auth 的 changePassword API
- 客户端表单验证(密码长度、确认密码匹配等)
- 成功后自动返回并提示

## 技术实现
- 严格遵循 TDD 规范(先写测试,后写实现)
- 新增 3 个 hooks 和对应的单元测试
- 更新中英文翻译文件
- 更新 jest.setup.js 添加必要的 mock

## 文档
- 新增 api_integration_report.md - API 对接分析报告
- 新增 api_integration_development_plan.md - 开发计划和完成汇总

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-23 19:15:24 +08:00

244 lines
8.2 KiB
JSON
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{
"common": {
"noData": "暂无数据",
"error": "错误",
"success": "成功",
"confirm": "确认",
"cancel": "取消"
},
"my": {
"editProfile": "编辑资料",
"generatedWorks": "生成作品",
"generating": "生成中...",
"queuing": "排队中...",
"changePassword": "修改密码",
"language": "语言",
"languageSwitch": "语言: 中文",
"languageSwitchEn": "Language: English",
"logout": "退出登录",
"noWorks": "暂无作品"
},
"changePassword": {
"title": "修改密码",
"currentPassword": "当前密码",
"newPassword": "新密码",
"confirmPassword": "确认新密码",
"currentPasswordPlaceholder": "请输入当前密码",
"newPasswordPlaceholder": "请输入新密码至少6位",
"confirmPasswordPlaceholder": "请再次输入新密码",
"currentPasswordRequired": "请填写当前密码",
"newPasswordRequired": "请填写新密码",
"newPasswordTooShort": "新密码长度至少为6位",
"newPasswordSame": "新密码不能与当前密码相同",
"confirmPasswordRequired": "请确认新密码",
"confirmPasswordMismatch": "两次输入的新密码不一致",
"submit": "确认修改",
"submitting": "修改中...",
"success": "密码修改成功",
"apiError": "密码修改失败,请检查旧密码是否正确"
},
"editProfile": {
"namePlaceholder": "请输入昵称",
"save": "保存"
},
"terms": {
"title": "服务条款"
},
"privacy": {
"title": "隐私协议"
},
"membership": {
"terms": "服务条款",
"privacy": "隐私协议",
"agreementText": "我已阅读并同意",
"agreementAnd": "与",
"myPoints": "我的积分",
"subscriptionPlan": "订阅计划",
"mostRecommended": "最推荐",
"perMonth": "/月",
"pointsPerMonth": "积分每月",
"pointsAutoRenew": "积分每月自动续期",
"subscribeNow": "立即开通",
"features": {
"points750": "750点每次可以使用150次Sora2",
"points1080": "1,080点每次可以使用150次Sora2",
"points1500": "1,500点每次可以使用150次Sora2",
"textToVideo": "支持文生视频/图生视频",
"superClearImage": "超清图像生成",
"superDiscount": "享受Sora2、Veo3.1超级折扣",
"sora2ProTemplate": "可以使用Sora2 Pro模板",
"removeWatermark": "生成作品去除品牌水印",
"allTemplates": "全部模板",
"higherQuality": "视频更高清",
"prioritySupport": "优先客服支持"
}
},
"home": {
"hotTemplate": "热门模板",
"peopleUsed": "人用过",
"tabs": {
"featured": "精选推荐",
"christmas": "圣诞限定",
"pets": "萌宠",
"avatar": "分身趣玩场",
"theater1": "图趣小剧场",
"theater2": "图趣小剧场2"
}
},
"message": {
"all": "全部",
"notice": "活动通知",
"other": "其他",
"noMessages": "暂无消息"
},
"video": {
"makeSame": "做同款"
},
"worksList": {
"title": "生成作品",
"all": "全部",
"pets": "萌宠",
"portrait": "写真",
"together": "合拍"
},
"channels": {
"title": "全部频道",
"channelName": "频道名称",
"noCategories": "暂无分类",
"retry": "重新加载"
},
"notFound": {
"title": "页面未找到",
"goBack": "返回首页"
},
"generateVideo": {
"uploadReference": "上传参考图",
"descriptionPlaceholder": "描述你想要的视频效果",
"generate": "生成视频",
"startGenerating": "开始生成视频",
"generatingMessage": "视频正在生成中,请稍候..."
},
"generationRecord": {
"title": "生成记录",
"aiVideo": "AI 视频",
"originalImage": "原图",
"reEdit": "重新编辑",
"regenerate": "再次生成",
"deleteSuccess": "删除成功",
"deleteError": "删除失败",
"deleteConfirm": "确认删除该记录?",
"deleting": "删除中..."
},
"search": {
"history": "搜索历史",
"clearAll": "全部清除",
"done": "完成",
"exploreMore": "探索更多",
"refresh": "换一换",
"searchWorks": "搜索生成的作品",
"searchWorksPlaceholder": "请输入关键词搜索生成的作品",
"noTags": "暂无推荐标签",
"loading": "加载中...",
"noResults": "未找到相关作品",
"errorOccurred": "搜索出错,请稍后重试"
},
"templateDetail": {
"title": "模板详情",
"subtitle": "填写表单以生成您的作品",
"fillForm": "填写表单",
"startCreating": "开始创作",
"generations": "作品列表",
"generationStarted": "生成已开始"
},
"dynamicForm": {
"uploadFailed": "上传失败,请重试",
"field": "字段",
"required": "不能为空",
"fillRequiredFields": "请填写所有必填项",
"submitFailed": "提交失败",
"enterText": "请输入文本",
"image": "图片",
"uploadImage": "点击上传图片",
"video": "视频",
"videoUploaded": "视频已上传",
"uploadVideo": "点击上传视频",
"select": "选择",
"selectPlaceholder": "请选择",
"noFields": "暂无可填写的表单项",
"submit": "生成视频"
},
"pointsDrawer": {
"title": "我的积分",
"all": "全部",
"consume": "消耗",
"obtain": "获得",
"subscriptionPoints": "订阅积分",
"topUpPoints": "额外充值积分",
"subscribeForPoints": "订阅得积分",
"topUpPointsButton": "充值积分",
"dailyFreePoints": "每日免费积分"
},
"aiGenerationRecord": {
"title": "AI 生成记录",
"recentUsed": "最近用过",
"projectAll": "全部项目",
"projectFace": "人脸项目"
},
"searchBar": {
"placeholder": "搜索",
"button": "搜索"
},
"searchResults": {
"makeSame": "做同款",
"noResults": "暂无您的结果"
},
"uploadReference": {
"selectImage": "选择图片",
"generateAIVideo": "生成 AI 视频",
"aiRecord": "AI 生成记录",
"recentUsed": "最近用过",
"recentProject": "最近项目",
"all": "全部",
"face": "人脸"
},
"topUp": {
"title": "充值积分",
"confirm": "确认充值",
"agreementText": "我已阅读并同意",
"terms": "服务条款",
"privacy": "隐私协议",
"agreementAnd": "与"
},
"tabs": {
"home": "首页",
"video": "视频",
"message": "消息",
"my": "我的"
},
"authForm": {
"login": "登录",
"register": "注册",
"username": "用户名",
"email": "邮箱",
"password": "密码",
"fillCompleteInfo": "请填写完整信息",
"fillEmail": "请填写邮箱",
"loginFailed": "登录失败",
"registerFailed": "注册失败",
"noAccountRegister": "没有账号?去注册",
"haveAccountLogin": "已有账号?去登录",
"errors": {
"INVALID_USERNAME_OR_PASSWORD": "用户名或密码错误",
"USER_NOT_FOUND": "用户不存在",
"EMAIL_ALREADY_EXISTS": "邮箱已被注册",
"USERNAME_ALREADY_EXISTS": "用户名已被占用",
"WEAK_PASSWORD": "密码强度不够",
"INVALID_EMAIL": "邮箱格式不正确",
"VALIDATION_ERROR": "输入信息格式错误",
"NETWORK_ERROR": "网络连接失败",
"UNKNOWN_ERROR": "未知错误,请稍后重试"
}
}
}