From a0a3997af2f40ffde9dfb69d4c29f079a8cdb239 Mon Sep 17 00:00:00 2001 From: zhaoying Date: Fri, 26 Dec 2025 12:11:39 +0800 Subject: [PATCH] fix(web): Conversation add initialValue --- web/src/i18n/en.ts | 2 +- web/src/i18n/zh.ts | 4 +++- web/src/views/Conversation/index.tsx | 6 +++--- web/src/views/ToolManagement/Custom.tsx | 9 +++++++-- .../ToolManagement/components/CustomToolModal.tsx | 13 ++++++++++--- .../ToolManagement/components/McpServiceModal.tsx | 2 +- 6 files changed, 25 insertions(+), 11 deletions(-) diff --git a/web/src/i18n/en.ts b/web/src/i18n/en.ts index 229636d5..35465661 100644 --- a/web/src/i18n/en.ts +++ b/web/src/i18n/en.ts @@ -1374,7 +1374,7 @@ Memory Bear: After the rebellion, regional warlordism intensified for several re auth: 'Authentication', requestHeader: 'Request Headers', config: 'Configuration', - authType: 'Authentication Type', + auth_type: 'Authentication Type', none: 'No Authentication', api_key: 'API Key', basic_auth: 'Basic Auth', diff --git a/web/src/i18n/zh.ts b/web/src/i18n/zh.ts index 1573f698..52003104 100644 --- a/web/src/i18n/zh.ts +++ b/web/src/i18n/zh.ts @@ -1337,6 +1337,8 @@ export const zh = { startANewConversation: '开始新对话', normalReply: '正常回复', quickReply: '快速回复', + web_search: '联网搜索', + memory: '记忆', }, login: { title: '红熊记忆科学', @@ -1474,7 +1476,7 @@ export const zh = { auth: '认证', requestHeader: '请求头', config: '配置', - authType: '认证方式', + auth_Type: '认证方式', none: '无需认证', api_key: 'API Key', basic_auth: 'Basic Auth', diff --git a/web/src/views/Conversation/index.tsx b/web/src/views/Conversation/index.tsx index e19f4f06..d791bf2d 100644 --- a/web/src/views/Conversation/index.tsx +++ b/web/src/views/Conversation/index.tsx @@ -208,7 +208,7 @@ const Conversation: FC = () => { return ( -
+
handleChangeHistory(null)} > @@ -250,7 +250,7 @@ const Conversation: FC = () => {
} - +
@@ -264,7 +264,7 @@ const Conversation: FC = () => { onSend={handleSend} labelFormat={(item) => dayjs(item.created_at).locale('en').format('MMMM D, YYYY [at] h:mm A')} > -
+ ReactNode }> = ({ get key={key} className="rb:flex rb:gap-4 rb:justify-start rb:text-[#5B6167] rb:text-[14px] rb:leading-5 rb:mb-3" > -
{t(`tool.${key}`)}
+
{t(`tool.${key}`)}
- {key === 'created_at' && item[key] ? dayjs(item[key]).format('YYYY-MM-DD HH:mm:ss') : (item.config_data as any)?.[key] || '-'} + {key === 'created_at' && item[key] + ? dayjs(item[key]).format('YYYY-MM-DD HH:mm:ss') + : key === 'auth_type' + ? t(`tool.${(item.config_data as any)?.[key]}`) + : (item.config_data as any)?.[key] || '-' + }
))} diff --git a/web/src/views/ToolManagement/components/CustomToolModal.tsx b/web/src/views/ToolManagement/components/CustomToolModal.tsx index e51f9ddc..cb4f036c 100644 --- a/web/src/views/ToolManagement/components/CustomToolModal.tsx +++ b/web/src/views/ToolManagement/components/CustomToolModal.tsx @@ -136,8 +136,15 @@ const CustomToolModal = forwardRef(({ } }} > + + + {/* 名称和图标 */} - + {/* (({ - + */} (({ {/* 认证方式 */}