style(web): translate the comments in the src/views directory into English
This commit is contained in:
@@ -255,7 +255,7 @@ const Agent = forwardRef<AgentRef>((_props, ref) => {
|
||||
const { memory, knowledge_retrieval, tools, ...rest } = values
|
||||
const { knowledge_bases = [], ...knowledgeRest } = knowledge_retrieval || {}
|
||||
const { memory_content } = memory || {}
|
||||
// 从原数据中获取memory的其他必要属性
|
||||
// Get other necessary properties of memory from original data
|
||||
const originalMemory = data.memory || ({} as MemoryConfig)
|
||||
|
||||
const params: Config = {
|
||||
@@ -425,7 +425,7 @@ const Agent = forwardRef<AgentRef>((_props, ref) => {
|
||||
<Knowledge />
|
||||
</Form.Item>
|
||||
|
||||
{/* 记忆配置 */}
|
||||
{/* Memory Configuration */}
|
||||
<Card title={t('application.memoryConfiguration')}>
|
||||
<Space size={24} direction='vertical' style={{ width: '100%' }}>
|
||||
<SwitchWrapper title="dialogueHistoricalMemory" desc="dialogueHistoricalMemoryDesc" name={['memory', 'enabled']} />
|
||||
@@ -442,7 +442,7 @@ const Agent = forwardRef<AgentRef>((_props, ref) => {
|
||||
<VariableList />
|
||||
</Form.Item>
|
||||
|
||||
{/* 工具配置 */}
|
||||
{/* Tool Configuration */}
|
||||
<Form.Item name="tools">
|
||||
<ToolList />
|
||||
</Form.Item>
|
||||
|
||||
@@ -162,7 +162,7 @@ const Api: FC<{ application: Application | null }> = ({ application }) => {
|
||||
}
|
||||
>
|
||||
<div className="rb:text-[#5B6167] rb:text-[12px] rb:mb-2">{t('application.apiKeySubTitle')}</div>
|
||||
{/* 总览数据 */}
|
||||
{/* Overview Data */}
|
||||
<Row>
|
||||
<Col span={6}>
|
||||
<Statistic title={t('application.apiKeyTotal')} value={apiKeyList.length} />
|
||||
@@ -171,7 +171,7 @@ const Api: FC<{ application: Application | null }> = ({ application }) => {
|
||||
<Statistic title={t('application.apiKeyRequestTotal')} value={totalRequests} />
|
||||
</Col>
|
||||
</Row>
|
||||
{/* API Key 列表 */}
|
||||
{/* API Key List */}
|
||||
{apiKeyList.sort((a, b) => b.created_at - a.created_at).map(item => (
|
||||
<div key={item.id} className="rb:mt-4 rb:p-[10px_12px] rb:bg-[#F0F3F8] rb:border rb:border-[#DFE4ED] rb:rounded-lg">
|
||||
<div className="rb:flex rb:items-center rb:justify-between">
|
||||
|
||||
@@ -146,7 +146,7 @@ const ReleasePage: FC<{data: Application; refresh: () => void}> = ({data, refres
|
||||
</div>
|
||||
</RbCard>
|
||||
|
||||
{/* 日志 */}
|
||||
{/* Logs */}
|
||||
<RbCard title={t('application.changeLog')} headerType="borderless">
|
||||
<Space size={16} direction="vertical" style={{ width: '100%' }}>
|
||||
{selectedVersion && (
|
||||
|
||||
@@ -69,7 +69,7 @@ const theme = {
|
||||
const EditorContent = forwardRef<EditorRef, LexicalEditorProps>(({
|
||||
className = '',
|
||||
value,
|
||||
placeholder = "请输入内容...",
|
||||
placeholder = "Please enter content...",
|
||||
onChange,
|
||||
}, ref) => {
|
||||
const [editor] = useLexicalComposerContext();
|
||||
|
||||
@@ -137,7 +137,7 @@ const VariableEditModal = forwardRef<VariableEditModalRef, VariableEditModalProp
|
||||
layout="vertical"
|
||||
scrollToFirstError={{ behavior: 'instant', block: 'end', focus: true }}
|
||||
>
|
||||
{/* 变量类型 */}
|
||||
{/* Variable Type */}
|
||||
<FormItem
|
||||
name="type"
|
||||
label={t('application.variableType')}
|
||||
@@ -154,7 +154,7 @@ const VariableEditModal = forwardRef<VariableEditModalRef, VariableEditModalProp
|
||||
optionRender={(props) => <div className="rb:flex rb:justify-between rb:items-center">{props.label} <Tag color="blue">{variableType[props.value as keyof typeof variableType]}</Tag></div>}
|
||||
/>
|
||||
</FormItem>
|
||||
{/* 变量名称 */}
|
||||
{/* Variable Name */}
|
||||
<FormItem
|
||||
name="name"
|
||||
label={t('application.variableName')}
|
||||
@@ -172,7 +172,7 @@ const VariableEditModal = forwardRef<VariableEditModalRef, VariableEditModalProp
|
||||
}}
|
||||
/>
|
||||
</FormItem>
|
||||
{/* 显示名称 */}
|
||||
{/* Display Name */}
|
||||
<FormItem
|
||||
name="display_name"
|
||||
label={t('application.displayName')}
|
||||
@@ -180,14 +180,14 @@ const VariableEditModal = forwardRef<VariableEditModalRef, VariableEditModalProp
|
||||
>
|
||||
<Input placeholder={t('common.enter')} />
|
||||
</FormItem>
|
||||
{/* 描述 */}
|
||||
{/* Description */}
|
||||
<FormItem
|
||||
name="description"
|
||||
label={t('application.description')}
|
||||
>
|
||||
<Input placeholder={t('common.enter')} />
|
||||
</FormItem>
|
||||
{/* 最大长度 */}
|
||||
{/* Max Length */}
|
||||
{['text', 'paragraph'].includes(values?.type) && (
|
||||
<FormItem
|
||||
name="max_length"
|
||||
@@ -196,7 +196,7 @@ const VariableEditModal = forwardRef<VariableEditModalRef, VariableEditModalProp
|
||||
<InputNumber placeholder={t('common.enter')} style={{ width: '100%' }} />
|
||||
</FormItem>
|
||||
)}
|
||||
{/* 默认值 */}
|
||||
{/* Default Value */}
|
||||
{/* {['text', 'paragraph', 'number', 'checkbox'].includes(values?.type) && (
|
||||
<FormItem
|
||||
name="default_value"
|
||||
@@ -208,7 +208,7 @@ const VariableEditModal = forwardRef<VariableEditModalRef, VariableEditModalProp
|
||||
{['checkbox'].includes(values.type) && <Select options={[{ value: true, label: t('application.defaultChecked') }, { value: false, label: t('application.notDefaultChecked') }]} />}
|
||||
</FormItem>
|
||||
)} */}
|
||||
{/* 选项 */}
|
||||
{/* Options */}
|
||||
{['dropdownOptions'].includes(values?.type) && (
|
||||
<FormItem
|
||||
name="options"
|
||||
@@ -217,7 +217,7 @@ const VariableEditModal = forwardRef<VariableEditModalRef, VariableEditModalProp
|
||||
<SortableList />
|
||||
</FormItem>
|
||||
)}
|
||||
{/* API 扩展 */}
|
||||
{/* API Extension */}
|
||||
{['apiVariable'].includes(values?.type) && (
|
||||
<FormItem
|
||||
name="api_extension"
|
||||
@@ -237,14 +237,14 @@ const VariableEditModal = forwardRef<VariableEditModalRef, VariableEditModalProp
|
||||
/>
|
||||
</FormItem>
|
||||
)}
|
||||
{/* 是否必填 */}
|
||||
{/* Required */}
|
||||
<FormItem
|
||||
name="required"
|
||||
valuePropName="checked"
|
||||
>
|
||||
<Checkbox>{t('application.required')}</Checkbox>
|
||||
</FormItem>
|
||||
{/* 是否隐藏 */}
|
||||
{/* Hidden */}
|
||||
{/* <FormItem
|
||||
name="hidden"
|
||||
valuePropName="checked"
|
||||
|
||||
Reference in New Issue
Block a user