mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-29 02:32:18 +00:00
[i18n] Translate node input label (#1880)
This commit is contained in:
@@ -5,6 +5,7 @@ const { defineConfig } = require('@lobehub/i18n-cli');
|
|||||||
|
|
||||||
module.exports = defineConfig({
|
module.exports = defineConfig({
|
||||||
modelName: 'gpt-4',
|
modelName: 'gpt-4',
|
||||||
|
splitToken: 1024,
|
||||||
entry: 'src/locales/en',
|
entry: 'src/locales/en',
|
||||||
entryLocale: 'en',
|
entryLocale: 'en',
|
||||||
output: 'src/locales',
|
output: 'src/locales',
|
||||||
|
|||||||
@@ -143,10 +143,7 @@ test('collect-i18n', async ({ comfyPage }) => {
|
|||||||
function extractInputs(nodeDef: ComfyNodeDefImpl) {
|
function extractInputs(nodeDef: ComfyNodeDefImpl) {
|
||||||
const inputs = Object.fromEntries(
|
const inputs = Object.fromEntries(
|
||||||
nodeDef.inputs.all.flatMap((input) => {
|
nodeDef.inputs.all.flatMap((input) => {
|
||||||
// TODO(huchenlei): translate input name. Somehow `CLIPAttentionMultiply` will
|
const name = input.name
|
||||||
// cause all subsequent translations to fail (Raw english values
|
|
||||||
// are generated).
|
|
||||||
const name = undefined
|
|
||||||
const tooltip = input.tooltip
|
const tooltip = input.tooltip
|
||||||
|
|
||||||
if (name === undefined && tooltip === undefined) {
|
if (name === undefined && tooltip === undefined) {
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user