diff --git a/web/app/components/plugins/plugin-detail-panel/multiple-tool-selector/index.tsx b/web/app/components/plugins/plugin-detail-panel/multiple-tool-selector/index.tsx index f243d30aff..7f5f22896a 100644 --- a/web/app/components/plugins/plugin-detail-panel/multiple-tool-selector/index.tsx +++ b/web/app/components/plugins/plugin-detail-panel/multiple-tool-selector/index.tsx @@ -141,7 +141,7 @@ const MultipleToolSelector = ({ } panelShowState={panelShowState} onPanelShowStateChange={setPanelShowState} - + isEdit={false} /> {value.length === 0 && (
{t('plugin.detailPanel.toolSelector.empty')}
@@ -158,6 +158,7 @@ const MultipleToolSelector = ({ onSelect={item => handleConfigure(item, index)} onDelete={() => handleDelete(index)} supportEnableSwitch + isEdit /> ))} diff --git a/web/app/components/plugins/plugin-detail-panel/tool-selector/index.tsx b/web/app/components/plugins/plugin-detail-panel/tool-selector/index.tsx index 577de19484..ca802414f3 100644 --- a/web/app/components/plugins/plugin-detail-panel/tool-selector/index.tsx +++ b/web/app/components/plugins/plugin-detail-panel/tool-selector/index.tsx @@ -54,6 +54,7 @@ type Props = { scope?: string value?: ToolValue selectedTools?: ToolValue[] + isEdit?: boolean onSelect: (tool: { provider_name: string tool_name: string @@ -77,6 +78,7 @@ type Props = { const ToolSelector: FC = ({ value, selectedTools, + isEdit, disabled, placement = 'left', offset = 4, @@ -277,7 +279,7 @@ const ToolSelector: FC = ({
{!isShowSettingAuth && ( <> -
{t('plugin.detailPanel.toolSelector.title')}
+
{t(`plugin.detailPanel.toolSelector.${isEdit ? 'toolSetting' : 'title'}`)}
{/* base form */}
diff --git a/web/i18n/en-US/plugin.ts b/web/i18n/en-US/plugin.ts index 51399d5310..1eaa0cb0a0 100644 --- a/web/i18n/en-US/plugin.ts +++ b/web/i18n/en-US/plugin.ts @@ -77,6 +77,7 @@ const translation = { modelNum: '{{num}} MODELS INCLUDED', toolSelector: { title: 'Add tool', + toolSetting: 'Tool Settings', toolLabel: 'Tool', descriptionLabel: 'Tool description', descriptionPlaceholder: 'Brief description of the tool\'s purpose, e.g., get the temperature for a specific location.', diff --git a/web/i18n/zh-Hans/plugin.ts b/web/i18n/zh-Hans/plugin.ts index 9b059ac5f4..6648e3b65a 100644 --- a/web/i18n/zh-Hans/plugin.ts +++ b/web/i18n/zh-Hans/plugin.ts @@ -77,6 +77,7 @@ const translation = { modelNum: '{{num}} 模型已包含', toolSelector: { title: '添加工具', + toolSetting: '工具设置', toolLabel: '工具', descriptionLabel: '工具描述', descriptionPlaceholder: '简要描述工具目的,例如,获取特定位置的温度。',