Co-authored-by: lbm21 <313338264@qq.com>tags/0.6.2
| <div className={cn('px-[10px] py-1', hideInfo && '!px-2 !py-0.5')}> | <div className={cn('px-[10px] py-1', hideInfo && '!px-2 !py-0.5')}> | ||||
| <CodeEditor | <CodeEditor | ||||
| readOnly | readOnly | ||||
| title={<div>INPUT</div>} | |||||
| title={<div>{t('workflow.common.input').toLocaleUpperCase()}</div>} | |||||
| language={CodeLanguage.json} | language={CodeLanguage.json} | ||||
| value={nodeInfo.inputs} | value={nodeInfo.inputs} | ||||
| isJSONStringifyBeauty | isJSONStringifyBeauty | ||||
| <div className={cn('px-[10px] py-1', hideInfo && '!px-2 !py-0.5')}> | <div className={cn('px-[10px] py-1', hideInfo && '!px-2 !py-0.5')}> | ||||
| <CodeEditor | <CodeEditor | ||||
| readOnly | readOnly | ||||
| title={<div>PROCESS DATA</div>} | |||||
| title={<div>{t('workflow.common.processData').toLocaleUpperCase()}</div>} | |||||
| language={CodeLanguage.json} | language={CodeLanguage.json} | ||||
| value={nodeInfo.process_data} | value={nodeInfo.process_data} | ||||
| isJSONStringifyBeauty | isJSONStringifyBeauty | ||||
| <div className={cn('px-[10px] py-1', hideInfo && '!px-2 !py-0.5')}> | <div className={cn('px-[10px] py-1', hideInfo && '!px-2 !py-0.5')}> | ||||
| <CodeEditor | <CodeEditor | ||||
| readOnly | readOnly | ||||
| title={<div>OUTPUT</div>} | |||||
| title={<div>{t('workflow.common.output').toLocaleUpperCase()}</div>} | |||||
| language={CodeLanguage.json} | language={CodeLanguage.json} | ||||
| value={nodeInfo.outputs} | value={nodeInfo.outputs} | ||||
| isJSONStringifyBeauty | isJSONStringifyBeauty |
| 'use client' | 'use client' | ||||
| import type { FC } from 'react' | import type { FC } from 'react' | ||||
| import { useTranslation } from 'react-i18next' | |||||
| import StatusPanel from './status' | import StatusPanel from './status' | ||||
| import MetaData from './meta' | import MetaData from './meta' | ||||
| import CodeEditor from '@/app/components/workflow/nodes/_base/components/editor/code-editor' | import CodeEditor from '@/app/components/workflow/nodes/_base/components/editor/code-editor' | ||||
| steps, | steps, | ||||
| showSteps, | showSteps, | ||||
| }) => { | }) => { | ||||
| const { t } = useTranslation() | |||||
| return ( | return ( | ||||
| <div className='bg-white py-2'> | <div className='bg-white py-2'> | ||||
| <div className='px-4 py-2'> | <div className='px-4 py-2'> | ||||
| <div className='px-4 py-2 flex flex-col gap-2'> | <div className='px-4 py-2 flex flex-col gap-2'> | ||||
| <CodeEditor | <CodeEditor | ||||
| readOnly | readOnly | ||||
| title={<div>INPUT</div>} | |||||
| title={<div>{t('workflow.common.input').toLocaleUpperCase()}</div>} | |||||
| language={CodeLanguage.json} | language={CodeLanguage.json} | ||||
| value={inputs} | value={inputs} | ||||
| isJSONStringifyBeauty | isJSONStringifyBeauty | ||||
| {process_data && ( | {process_data && ( | ||||
| <CodeEditor | <CodeEditor | ||||
| readOnly | readOnly | ||||
| title={<div>PROCESS DATA</div>} | |||||
| title={<div>{t('workflow.common.processData').toLocaleUpperCase()}</div>} | |||||
| language={CodeLanguage.json} | language={CodeLanguage.json} | ||||
| value={process_data} | value={process_data} | ||||
| isJSONStringifyBeauty | isJSONStringifyBeauty | ||||
| {(outputs || status === 'running') && ( | {(outputs || status === 'running') && ( | ||||
| <CodeEditor | <CodeEditor | ||||
| readOnly | readOnly | ||||
| title={<div>OUTPUT</div>} | |||||
| title={<div>{t('workflow.common.output').toLocaleUpperCase()}</div>} | |||||
| language={CodeLanguage.json} | language={CodeLanguage.json} | ||||
| value={outputs} | value={outputs} | ||||
| isJSONStringifyBeauty | isJSONStringifyBeauty |
| content: 'The variable is used in other nodes. Do you still want to remove it?', | content: 'The variable is used in other nodes. Do you still want to remove it?', | ||||
| }, | }, | ||||
| insertVarTip: 'Press the \'/\' key to insert quickly', | insertVarTip: 'Press the \'/\' key to insert quickly', | ||||
| processData: 'Process Data', | |||||
| input: 'Input', | |||||
| output: 'Output', | |||||
| }, | }, | ||||
| errorMsg: { | errorMsg: { | ||||
| fieldRequired: '{{field}} is required', | fieldRequired: '{{field}} is required', |
| content: 'La variable est utilisée dans d\'autres nœuds. Voulez-vous toujours la supprimer ?', | content: 'La variable est utilisée dans d\'autres nœuds. Voulez-vous toujours la supprimer ?', | ||||
| }, | }, | ||||
| insertVarTip: 'Appuyez sur la touche \'/\' pour insérer rapidement', | insertVarTip: 'Appuyez sur la touche \'/\' pour insérer rapidement', | ||||
| processData: 'Traiter les données', | |||||
| input: 'Entrée', | |||||
| output: 'Sortie', | |||||
| }, | }, | ||||
| errorMsg: { | errorMsg: { | ||||
| fieldRequired: '{{field}} est requis', | fieldRequired: '{{field}} est requis', |
| content: '他のノードで変数が使用されています。それでも削除しますか?', | content: '他のノードで変数が使用されています。それでも削除しますか?', | ||||
| }, | }, | ||||
| insertVarTip: 'クイック挿入のために\'/\'キーを押します', | insertVarTip: 'クイック挿入のために\'/\'キーを押します', | ||||
| processData: 'データ処理', | |||||
| input: '入力', | |||||
| output: '出力', | |||||
| }, | }, | ||||
| errorMsg: { | errorMsg: { | ||||
| fieldRequired: '{{field}}は必須です', | fieldRequired: '{{field}}は必須です', |
| content: 'A variável está sendo usada em outros nós. Deseja removê-la mesmo assim?', | content: 'A variável está sendo usada em outros nós. Deseja removê-la mesmo assim?', | ||||
| }, | }, | ||||
| insertVarTip: 'Pressione a tecla \'/\' para inserir rapidamente', | insertVarTip: 'Pressione a tecla \'/\' para inserir rapidamente', | ||||
| processData: 'Processar dados', | |||||
| input: 'Entrada', | |||||
| output: 'Saída', | |||||
| }, | }, | ||||
| errorMsg: { | errorMsg: { | ||||
| fieldRequired: '{{field}} é obrigatório', | fieldRequired: '{{field}} é obrigatório', |
| content: 'Цю змінну використовується в інших вузлах. Ви все ще хочете її видалити?', | content: 'Цю змінну використовується в інших вузлах. Ви все ще хочете її видалити?', | ||||
| }, | }, | ||||
| insertVarTip: 'Натисніть клавішу "/" для швидкого вставлення', | insertVarTip: 'Натисніть клавішу "/" для швидкого вставлення', | ||||
| processData: 'Обробка даних', | |||||
| input: 'Вхід', | |||||
| output: 'Вихід', | |||||
| }, | }, | ||||
| errorMsg: { | errorMsg: { | ||||
| fieldRequired: '{{field}} є обов\'язковим', | fieldRequired: '{{field}} є обов\'язковим', |
| content: 'Biến được sử dụng trong các nút khác. Bạn vẫn muốn xóa nó?', | content: 'Biến được sử dụng trong các nút khác. Bạn vẫn muốn xóa nó?', | ||||
| }, | }, | ||||
| insertVarTip: 'Nhấn phím \'/\' để chèn nhanh', | insertVarTip: 'Nhấn phím \'/\' để chèn nhanh', | ||||
| processData: 'Xử lý dữ liệu', | |||||
| input: 'Nhập', | |||||
| output: 'Đầu ra', | |||||
| }, | }, | ||||
| errorMsg: { | errorMsg: { | ||||
| fieldRequired: '{{field}} là bắt buộc', | fieldRequired: '{{field}} là bắt buộc', |
| content: '该变量在其他节点中使用。您是否仍要删除它?', | content: '该变量在其他节点中使用。您是否仍要删除它?', | ||||
| }, | }, | ||||
| insertVarTip: '按 \'/\' 键快速插入', | insertVarTip: '按 \'/\' 键快速插入', | ||||
| processData: '数据处理', | |||||
| input: '输入', | |||||
| output: '输出', | |||||
| }, | }, | ||||
| errorMsg: { | errorMsg: { | ||||
| fieldRequired: '{{field}} 不能为空', | fieldRequired: '{{field}} 不能为空', |