feat: 管线四阶段进度上报 + 图片预览 + Vite 代理

后端:
- pipeline.go: ProgressReporter 回调类型 + WithProgressReporter 注入 context
- nodes.go: 各节点 pre/post handler 调用 reportProgress() 上报阶段进度
- generate.go: TaskResponse 新增 stage 字段,runPipelineBg 注入进度回调

前端:
- vite.config.ts: 添加 /generation 代理到后端静态文件服务
- generation.ts: 轮询读取 stage 字段,暴露 stage/retryCount/rejectReason
- GeneratePage.tsx: ProgressBar 接收真实管线阶段数据
This commit is contained in:
2026-05-25 14:26:26 +08:00
parent ecb74a2aed
commit 5d5fe60426
6 changed files with 78 additions and 17 deletions
+4
View File
@@ -14,6 +14,10 @@ export default defineConfig({
target: 'http://localhost:8080',
changeOrigin: true,
},
'/generation': {
target: 'http://localhost:8080',
changeOrigin: true,
},
},
},
})