优化: 前端扫描文案 i18n + parseStack 抽公共 + alert/confirm 换组件

- 扫描/目录状态文案走 $t(Projects/ProjectDetail,zh-CN+en 同步)
- parseStack 抽公共到 src/utils/project.ts(删两份本地实现)
- 8 处原生 alert/confirm 全换(confirm→ConfirmDialog / alert→Arco Message),控制流语义不变

Sprint 20 审查 ⑥⑦⑧。vue-tsc 0 error,验证 safe 0 issue
This commit is contained in:
2026-06-14 14:22:57 +08:00
parent d5a641797c
commit 02ff88fc61
8 changed files with 126 additions and 36 deletions

View File

@@ -48,6 +48,13 @@ export default {
relocateDir: 'Relocate',
bindDir: 'Bind Directory',
dirStatusLabel: 'Directory Status',
dirChecking: 'Checking…',
dirExists: '✓ Directory exists',
dirMissing: '⚠ Directory moved, recommend relocate',
dirConflict: 'This directory is already bound to project "{name}"',
relocateConfirmRelocate: 'Relocate project directory to:\n{dir}\n\nTech stack will be re-detected. Confirm?',
relocateConfirmBind: 'Bind project directory to:\n{dir}\n\nTech stack will be re-detected. Confirm?',
relocateFailed: 'Relocate failed: {msg}',
// Tech stack
techStackLabel: 'Tech Stack',
},

View File

@@ -26,9 +26,16 @@ export default {
confirmPurge: 'Permanently delete project "{name}"? Tasks/branches/releases will be physically deleted and cannot be recovered!',
// New fields
codeDirLabel: 'Code Directory',
codeDirOptionalHint: '(optional, auto-detects tech stack once bound)',
codeDirPlaceholder: 'Click the button on the right to select project directory',
selectDir: 'Select Directory',
clearDir: 'Clear',
// AI scan
aiScanning: 'AI scanning…',
aiScanFill: '🤖 AI scan & autofill',
aiScanNoDesc: 'AI could not generate a description, please fill manually',
aiScanFailed: 'AI scan failed',
dirConflict: 'This directory is already bound to project "{name}"',
// Status labels (PROJECT_STATUS_LABELS values in constants/project.ts use these keys)
status: {
planning: '📐 Planning',

View File

@@ -48,6 +48,13 @@ export default {
relocateDir: '重定位',
bindDir: '绑定目录',
dirStatusLabel: '目录状态',
dirChecking: '检测中…',
dirExists: '✓ 目录存在',
dirMissing: '⚠ 目录已移走,建议重定位',
dirConflict: '该目录已被项目「{name}」绑定',
relocateConfirmRelocate: '将项目目录重定位到:\n{dir}\n\n技术栈将重新探测。确认?',
relocateConfirmBind: '将项目目录绑定到:\n{dir}\n\n技术栈将重新探测。确认?',
relocateFailed: '重定位失败: {msg}',
// 技术栈
techStackLabel: '技术栈',
},

View File

@@ -11,10 +11,17 @@ export default {
descLabel: '项目描述',
descPlaceholder: '简要描述项目目标',
codeDirLabel: '代码目录',
codeDirOptionalHint: '(可选,绑定后自动识别技术栈)',
codeDirPlaceholder: '点击右侧选择项目所在目录',
selectDir: '选择目录',
clearDir: '清除',
confirmCreate: '确认创建',
// AI 扫描
aiScanning: 'AI 扫描中…',
aiScanFill: '🤖 AI 扫描填信息',
aiScanNoDesc: 'AI 未能生成描述,可手动填写',
aiScanFailed: 'AI 扫描失败',
dirConflict: '该目录已被项目「{name}」绑定',
// 回收站模态框
trashTitle: '🗑 回收站',
trashEmpty: '回收站为空',