优化: P0 shell stdout修复+灵感路由+3工具新增+ai-md全局CSS+import路径统一
P0 修复:
- B-260615-37: shell.rs 补 Stdio::piped() 修复 run_command stdout/stderr 恒空
(tokio 默认 inherit 导致 wait_with_output 读不到 pipe)
P1 功能:
- B-260615-36: 路由加 /ideas/:id + Ideas.vue 接 route.params.id + watch
(修复项目详情点「来源灵感」跳空白页)
- F-260615-08: 新增 file_info 工具(元信息: exists/size/lines/binary/dir)
- F-260615-09: 新增 append_file 工具(追加写入, RiskLevel::Medium)
- F-260615-12: 新增 search_files 工具(文件名 glob 搜索,递归,限50条)
+ search_files_recursive 辅助函数 + i18n zh/en 3工具×2命名空间
DRY/重构:
- CR-260615-09: .ai-md 样式5份→全局 src/styles/ai-md.css(75行)
AiChat.vue 删71行重复 + main.ts 引入 + typo修正(.a-md→.ai-md)
- 全量 import 路径统一为 @/ 别名(stores/composables/views ~28文件)
vite.config.ts 加 resolve.alias.{ '@': '/src' }
- i18n 批量改进: store error fallback 11处中文→t() / ToolCard ARG_LABEL
/ useAiSend queue文案 / Dashboard 空态 / Ideas.vue null守卫
- cargo check 0 error / vue-tsc 0 error
This commit is contained in:
@@ -5,6 +5,14 @@ export default {
|
||||
readFile: 'Read File',
|
||||
listDirectory: 'List Directory',
|
||||
writeFile: 'Write File',
|
||||
fileInfo: 'File Info',
|
||||
appendFile: 'Append File',
|
||||
searchFiles: 'Search Files',
|
||||
},
|
||||
aiTool: {
|
||||
fileInfoDesc: 'Get file or directory metadata (exists, size, line count, modified time, is binary, is directory) without reading content',
|
||||
appendFileDesc: 'Append content to end of file. Creates file if not exists. Returns bytes written and new file size',
|
||||
searchFilesDesc: 'Search for files matching a pattern (case-insensitive substring match) in a directory. Supports recursive search, max 50 results with total count and has_more flag',
|
||||
},
|
||||
errorNotFound: 'Request failed: the endpoint or model does not exist. Please check the Provider configuration.',
|
||||
errorAuth: 'Request failed: the API key is invalid or lacks permission.',
|
||||
|
||||
@@ -13,5 +13,6 @@ export default {
|
||||
edit: 'Edit',
|
||||
close: 'Close',
|
||||
loading: 'Loading…',
|
||||
unknownError: 'Unknown error',
|
||||
},
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { createI18n } from 'vue-i18n'
|
||||
import zhCN from './zh-CN'
|
||||
import en from './en'
|
||||
import { useAppSettingsStore } from '../stores/appSettings'
|
||||
import { useAppSettingsStore } from '@/stores/appSettings'
|
||||
|
||||
// 界面语言:模块加载时 appSettings 缓存尚未填充(loadAll 在 App.vue onMounted 异步执行),
|
||||
// 故这里 get() 拿到默认 'zh-CN';真实用户偏好由 App.vue 在 loadAll 完成后回填到
|
||||
|
||||
@@ -5,6 +5,14 @@ export default {
|
||||
readFile: '读取文件',
|
||||
listDirectory: '查看目录',
|
||||
writeFile: '写入文件',
|
||||
fileInfo: '文件信息',
|
||||
appendFile: '追加写入',
|
||||
searchFiles: '搜索文件',
|
||||
},
|
||||
aiTool: {
|
||||
fileInfoDesc: '获取文件或目录的元信息(是否存在、大小、行数、修改时间、是否二进制、是否目录),不读取文件内容',
|
||||
appendFileDesc: '向文件末尾追加内容,文件不存在则自动创建。返回写入字数和新文件大小',
|
||||
searchFilesDesc: '在指定目录下搜索匹配模式(字符串包含匹配)的文件名,返回路径和大小列表。支持递归搜索,结果限 50 条',
|
||||
},
|
||||
errorNotFound: '调用失败:接口地址或模型不存在,请检查 Provider 配置',
|
||||
errorAuth: '调用失败:API Key 无效或无权限',
|
||||
|
||||
@@ -13,5 +13,6 @@ export default {
|
||||
edit: '编辑',
|
||||
close: '关闭',
|
||||
loading: '加载中…',
|
||||
unknownError: '未知错误',
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user