Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/i18n.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
jobs:
update-locales:
# Branch detection: Only run for manual dispatch or version-bump-* branches from main repo
if: github.event_name == 'workflow_dispatch' || (github.event.pull_request.head.repo.full_name == github.repository && startsWith(github.head_ref, 'version-bump-'))
if: github.event_name == 'workflow_dispatch' || (github.event.pull_request.head.repo.full_name == github.repository && startsWith(github.head_ref, 'version-bump-')) || startsWith(github.head_ref, 'sno-fix-locale')
runs-on: ubuntu-latest
steps:
- uses: Comfy-Org/ComfyUI_frontend_setup_action@v3
Expand Down
1 change: 1 addition & 0 deletions playwright.i18n.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export default defineConfig({
headless: true
},
reporter: 'list',
workers: 1,
timeout: 60000,
testMatch: /collect-i18n-.*\.ts/
})
31 changes: 17 additions & 14 deletions scripts/collect-i18n-node-defs.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
import * as fs from 'fs'

import { comfyPageFixture as test } from '../browser_tests/fixtures/ComfyPage'
import type { ComfyNodeDef } from '../src/schemas/nodeDefSchema'
import type { ComfyApi } from '../src/scripts/api'
import { ComfyNodeDefImpl } from '../src/stores/nodeDefStore'
import type { ComfyNodeDefImpl } from '../src/stores/nodeDefStore'
import { normalizeI18nKey } from '../src/utils/formatUtil'

const localePath = './src/locales/en/main.json'
Expand All @@ -26,18 +24,23 @@ test('collect-i18n-node-defs', async ({ comfyPage }) => {
})
})

const nodeDefs: ComfyNodeDefImpl[] = (
Object.values(
await comfyPage.page.evaluate(async () => {
// @ts-expect-error - app is dynamically added to window
const api = window['app'].api as ComfyApi
return await api.getNodeDefs()
})
) as ComfyNodeDef[]
// Note: Don't mock the object_info API endpoint - let it hit the actual backend

const nodeDefs: ComfyNodeDefImpl[] = await comfyPage.page.evaluate(
async () => {
// @ts-expect-error - app is dynamically added to window
const api = window['app'].api
const rawNodeDefs = await api.getNodeDefs()
const { ComfyNodeDefImpl } = await import('../src/stores/nodeDefStore')

return (
Object.values(rawNodeDefs)
// Ignore DevTools nodes (used for internal testing)
.filter((def: any) => !def.name.startsWith('DevTools'))
.map((def: any) => new ComfyNodeDefImpl(def))
)
}
)
// Ignore DevTools nodes (used for internal testing)
.filter((def) => !def.name.startsWith('DevTools'))
.map((def) => new ComfyNodeDefImpl(def))

console.log(`Collected ${nodeDefs.length} node definitions`)

Expand Down
8 changes: 1 addition & 7 deletions src/locales/ar/commands.json
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,6 @@
"Comfy_ExportWorkflowAPI": {
"label": "تصدير سير العمل (تنسيق API)"
},
"Comfy_Feedback": {
"label": "إرسال ملاحظات"
},
"Comfy_Graph_ConvertToSubgraph": {
"label": "تحويل التحديد إلى رسم فرعي"
},
Expand Down Expand Up @@ -170,9 +167,6 @@
"Comfy_LoadDefaultWorkflow": {
"label": "تحميل سير العمل الافتراضي"
},
"Comfy_Manager_CustomNodesManager": {
"label": "تبديل مدير العقد المخصصة"
},
"Comfy_Manager_ToggleManagerProgressDialog": {
"label": "تبديل شريط تقدم مدير العقد المخصصة"
},
Expand Down Expand Up @@ -291,4 +285,4 @@
"label": "تبديل الشريط الجانبي لسير العمل",
"tooltip": "سير العمل"
}
}
}
8 changes: 1 addition & 7 deletions src/locales/ar/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,6 @@
"frontendNewer": "إصدار الواجهة الأمامية {frontendVersion} قد لا يكون متوافقاً مع الإصدار الخلفي {backendVersion}.",
"frontendOutdated": "إصدار الواجهة الأمامية {frontendVersion} قديم. يتطلب الإصدار الخلفي {requiredVersion} أو أحدث.",
"goToNode": "الانتقال إلى العقدة",
"help": "مساعدة",
"icon": "أيقونة",
"imageFailedToLoad": "فشل تحميل الصورة",
"imageUrl": "رابط الصورة",
Expand Down Expand Up @@ -778,7 +777,6 @@
"File": "ملف",
"Fit Group To Contents": "ملائمة المجموعة للمحتويات",
"Focus Mode": "وضع التركيز",
"Give Feedback": "تقديم ملاحظات",
"Group Selected Nodes": "تجميع العقد المحددة",
"Help": "مساعدة",
"Help Center": "مركز المساعدة",
Expand Down Expand Up @@ -837,7 +835,6 @@
"Toggle Terminal Bottom Panel": "تبديل لوحة الطرفية السفلية",
"Toggle Theme (Dark/Light)": "تبديل السمة (داكن/فاتح)",
"Toggle View Controls Bottom Panel": "تبديل لوحة عناصر التحكم في العرض السفلية",
"Toggle the Custom Nodes Manager": "تبديل مدير العقد المخصصة",
"Toggle the Custom Nodes Manager Progress Bar": "تبديل شريط تقدم مدير العقد المخصصة",
"Undo": "تراجع",
"Ungroup selected group nodes": "فك تجميع عقد المجموعة المحددة",
Expand Down Expand Up @@ -931,9 +928,6 @@
"upscale_diffusion": "انتشار التكبير",
"upscaling": "تكبير",
"utils": "أدوات مساعدة",
"v1": "الإصدار 1",
"v2": "الإصدار 2",
"v3": "الإصدار 3",
"video": "فيديو",
"video_models": "نماذج الفيديو"
},
Expand Down Expand Up @@ -1693,4 +1687,4 @@
"showMinimap": "إظهار الخريطة المصغرة",
"zoomToFit": "تكبير لتناسب الشاشة"
}
}
}
15 changes: 1 addition & 14 deletions src/locales/ar/nodeDefs.json
Original file line number Diff line number Diff line change
Expand Up @@ -7366,19 +7366,6 @@
}
}
},
"SaveSVG": {
"description": "يحفظ ملفات SVG على القرص.",
"display_name": "حفظ SVG",
"inputs": {
"filename_prefix": {
"name": "بادئة اسم الملف",
"tooltip": "بادئة اسم الملف للحفظ. يمكن أن تتضمن معلومات تنسيق مثل %date:yyyy-MM-dd% أو %Empty Latent Image.width% لاستخدام قيم من العقد."
},
"svg": {
"name": "ملف SVG"
}
}
},
"SaveVideo": {
"description": "يحفظ الصور المدخلة في مجلد مخرجات ComfyUI الخاص بك.",
"display_name": "حفظ الفيديو",
Expand Down Expand Up @@ -8657,4 +8644,4 @@
}
}
}
}
}
6 changes: 1 addition & 5 deletions src/locales/ar/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -388,10 +388,6 @@
"Topbar (2nd-row)": "شريط الأعلى (الصف الثاني)"
}
},
"LiteGraph_Canvas_LowQualityRenderingZoomThreshold": {
"name": "عتبة التكبير للرسم بجودة منخفضة",
"tooltip": "عرض أشكال بجودة منخفضة عند التكبير للخارج"
},
"LiteGraph_Canvas_MaximumFps": {
"name": "الحد الأقصى للإطارات في الثانية",
"tooltip": "الحد الأقصى لعدد الإطارات في الثانية التي يسمح للرسم أن يعرضها. يحد من استخدام GPU على حساب السلاسة. إذا كانت 0، يتم استخدام معدل تحديث الشاشة. الافتراضي: 0"
Expand All @@ -413,4 +409,4 @@
"pysssss_SnapToGrid": {
"name": "الالتصاق بالشبكة دائمًا"
}
}
}
6 changes: 3 additions & 3 deletions src/locales/en/commands.json
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,6 @@
"Comfy_ExportWorkflowAPI": {
"label": "Export Workflow (API Format)"
},
"Comfy_Feedback": {
"label": "Give Feedback"
},
"Comfy_Graph_ConvertToSubgraph": {
"label": "Convert Selection to Subgraph"
},
Expand Down Expand Up @@ -260,6 +257,9 @@
"Comfy_User_SignOut": {
"label": "Sign Out"
},
"Experimental_ToggleVueNodes": {
"label": "Experimental: Enable Vue Nodes"
},
"Workspace_CloseWorkflow": {
"label": "Close Current Workflow"
},
Expand Down
Loading