支持管理员在3个管理聊天界面(系统总监、评估指令、收集指令)中通过 粘贴板粘贴图片,实现与管理Agent的多模态对话。 **新增文件:** - `shared/hooks/useImagePaste.ts`: 共享 hook,处理剪贴板图片粘贴、 base64 转换、待发送图片管理、多模态内容块构建 **后端改动 (conversation-service):** - 3个管理聊天服务 (system-supervisor-chat, directive-chat, collection-directive-chat): chat() 方法参数类型从 `content: string` 改为 `content: Anthropic.MessageParam['content']`,支持接收图片块 - 3个管理控制器 (admin-supervisor, admin-assessment-directive, admin-collection-directive): DTO content 类型改为 `any` 以透传 前端发送的多模态内容 **前端改动 (admin-client):** - 3个 API 类型文件: ChatMessage.content 类型扩展为 `string | ContentBlock[]` - SupervisorPage: 集成 useImagePaste hook,添加 onPaste 处理、 待发送图片预览(64x64 缩略图+删除按钮)、消息中图片渲染 - DirectiveChatDrawer: 同上,48x48 缩略图适配 Drawer 宽度 - CollectionChatDrawer: 同上 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| src | ||
| index.html | ||
| package.json | ||
| postcss.config.js | ||
| tailwind.config.js | ||
| tsconfig.json | ||
| tsconfig.node.json | ||
| vite.config.ts | ||