Add automated fix workflow for AI nutritionist page
- Create .fixes/ directory structure for tracking repairs - Add FIX-001 to FIX-009 repair tasks based on Cursor review - Add automation scripts (start-fix.sh, complete-fix.sh) - Update HEARTBEAT.md with repair checklist - Create AUTOMATION_PLAN.md with workflow documentation Fixes address: - Remove fake initial data - Add clear chat button - Split oversized component - Optimize multi-image upload - Fix scroll behavior - Remove dead code - Extract hardcoded config
This commit is contained in:
32
msh_single_uniapp/.fixes/backlog/FIX-003-split-components.md
Normal file
32
msh_single_uniapp/.fixes/backlog/FIX-003-split-components.md
Normal file
@@ -0,0 +1,32 @@
|
||||
# FIX-003: 拆分单文件组件
|
||||
|
||||
**状态**: 待开始
|
||||
**创建时间**: 2026-02-28
|
||||
**优先级**: 高
|
||||
**负责人**: msh-agent
|
||||
|
||||
---
|
||||
|
||||
## 问题描述
|
||||
|
||||
`ai-nutritionist.vue` 单文件超过 550 行,包含聊天、语音、图片、状态管理等多个功能模块,可维护性差。
|
||||
|
||||
---
|
||||
|
||||
## 修复方案
|
||||
|
||||
拆分为以下组件:
|
||||
- `components/ai-chat/ChatMessage.vue` - 消息气泡
|
||||
- `components/ai-chat/ChatInput.vue` - 输入框
|
||||
- `components/ai-chat/VoiceRecorder.vue` - 语音录制
|
||||
- `components/ai-chat/ImageUploader.vue` - 图片上传
|
||||
|
||||
---
|
||||
|
||||
## 实施步骤
|
||||
|
||||
- [ ] 1. 备份原文件
|
||||
- [ ] 2. 创建 `components/ai-chat/` 目录
|
||||
- [ ] 3. 逐个提取组件
|
||||
- [ ] 4. 在主文件引入组件
|
||||
- [ ] 5. 测试所有功能正常
|
||||
Reference in New Issue
Block a user