[i18n] Translate save/export workflow dialog (#1906)

* [i18n] Translate save/export workflow dialog

* Update locales [skip ci]

---------

Co-authored-by: github-actions <github-actions@github.com>
This commit is contained in:
Chenlei Hu
2024-12-13 16:56:37 -08:00
committed by GitHub
parent 98912efeb7
commit 59b62eadf1
7 changed files with 31 additions and 6 deletions

View File

@@ -615,6 +615,11 @@
"saveAsTemplate": "Save as template",
"enterName": "Enter name"
},
"workflowService": {
"exportWorkflow": "Export Workflow",
"enterFilename": "Enter the filename",
"saveWorkflow": "Save workflow"
},
"electronFileDownload": {
"inProgress": "In Progress",
"pause": "Pause Download",

View File

@@ -949,5 +949,10 @@
"welcome": {
"getStarted": "はじめる",
"title": "ComfyUIへようこそ"
},
"workflowService": {
"enterFilename": "ファイル名を入力",
"exportWorkflow": "ワークフローをエクスポート",
"saveWorkflow": "ワークフローを保存"
}
}

View File

@@ -949,5 +949,10 @@
"welcome": {
"getStarted": "시작하기",
"title": "ComfyUI에 오신 것을 환영합니다"
},
"workflowService": {
"enterFilename": "파일 이름 입력",
"exportWorkflow": "워크플로우 내보내기",
"saveWorkflow": "워크플로우 저장"
}
}

View File

@@ -949,5 +949,10 @@
"welcome": {
"getStarted": "Начать",
"title": "Добро пожаловать в ComfyUI"
},
"workflowService": {
"enterFilename": "Введите имя файла",
"exportWorkflow": "Экспорт рабочего процесса",
"saveWorkflow": "Сохранить рабочий процесс"
}
}

View File

@@ -949,5 +949,10 @@
"welcome": {
"getStarted": "开始使用",
"title": "欢迎使用 ComfyUI"
},
"workflowService": {
"enterFilename": "输入文件名",
"exportWorkflow": "导出工作流",
"saveWorkflow": "保存工作流"
}
}

View File

@@ -11,7 +11,7 @@ import ExecutionErrorDialogContent from '@/components/dialog/content/ExecutionEr
import TemplateWorkflowsContent from '@/components/templates/TemplateWorkflowsContent.vue'
import PromptDialogContent from '@/components/dialog/content/PromptDialogContent.vue'
import ConfirmationDialogContent from '@/components/dialog/content/ConfirmationDialogContent.vue'
import { i18n } from '@/i18n'
import { t } from '@/i18n'
import type { MissingNodeType } from '@/types/comfy'
export function showLoadWorkflowWarning(props: {
@@ -60,7 +60,7 @@ export function showExecutionErrorDialog(error: ExecutionErrorWsMessage) {
export function showTemplateWorkflowsDialog() {
useDialogStore().showDialog({
key: 'global-template-workflows',
title: i18n.global.t('templateWorkflows.title'),
title: t('templateWorkflows.title'),
component: TemplateWorkflowsContent
})
}

View File

@@ -15,8 +15,8 @@ import { useToastStore } from '@/stores/toastStore'
async function getFilename(defaultName: string): Promise<string | null> {
if (useSettingStore().get('Comfy.PromptFilename')) {
let filename = await showPromptDialog({
title: 'Export Workflow',
message: 'Enter the filename:',
title: t('workflowService.exportWorkflow'),
message: t('workflowService.enterFilename') + ':',
defaultValue: defaultName
})
if (!filename) return null
@@ -56,8 +56,8 @@ export const workflowService = {
*/
async saveWorkflowAs(workflow: ComfyWorkflow) {
const newFilename = await showPromptDialog({
title: 'Save workflow',
message: 'Enter the filename:',
title: t('workflowService.saveWorkflow'),
message: t('workflowService.enterFilename') + ':',
defaultValue: workflow.filename
})
if (!newFilename) return