From 46a5619100fd85a3bd60fdcb611a50b1cfab5312 Mon Sep 17 00:00:00 2001 From: Kent Keirsey <31807370+hipsterusername@users.noreply.github.com> Date: Mon, 30 Jun 2025 15:04:02 -0400 Subject: [PATCH] Update all text to translations --- invokeai/frontend/web/public/locales/en.json | 39 ++++++++++++++++++- .../SimpleSession/UpscalingLaunchpadPanel.tsx | 37 +++++++++--------- .../SimpleSession/WorkflowsLaunchpadPanel.tsx | 33 ++++++---------- 3 files changed, 68 insertions(+), 41 deletions(-) diff --git a/invokeai/frontend/web/public/locales/en.json b/invokeai/frontend/web/public/locales/en.json index 875de24a57..bc0b194510 100644 --- a/invokeai/frontend/web/public/locales/en.json +++ b/invokeai/frontend/web/public/locales/en.json @@ -2449,7 +2449,44 @@ "workflowsTitle": "Go deep with Workflows.", "upscalingTitle": "Upscale and add detail.", "canvasTitle": "Edit and refine on Canvas.", - "generateTitle": "Generate images from text prompts." + "generateTitle": "Generate images from text prompts.", + "workflows": { + "description": "Workflows are reusable templates that automate image generation tasks, allowing you to quickly perform complex operations and get consistent results.", + "learnMoreLink": "Learn more about creating workflows", + "browseTemplates": { + "title": "Browse Workflow Templates", + "description": "Choose from pre-built workflows for common tasks" + }, + "createNew": { + "title": "Create a new Workflow", + "description": "Start a new workflow from scratch" + }, + "loadFromFile": { + "title": "Load workflow from existing image or file", + "description": "Drag or upload a workflow to start with an existing setup" + } + }, + "upscaling": { + "uploadImage": { + "title": "Upload Image to Upscale", + "description": "Click or drag an image to upscale (JPG, PNG, WebP up to 100MB)" + }, + "imageReady": { + "title": "Image Ready", + "description": "Press Invoke to begin upscaling" + }, + "readyToUpscale": { + "title": "Ready to upscale!", + "description": "Configure your settings below, then click the Invoke button to begin upscaling your image." + }, + "upscaleModel": "Upscale Model", + "model": "Model", + "scale": "Scale", + "helpText": { + "promptAdvice": "When upscaling, use a prompt that describes the medium and style. Avoid describing specific content details in the image.", + "styleAdvice": "Upscaling works best with the general style of your image." + } + } } }, "system": { diff --git a/invokeai/frontend/web/src/features/controlLayers/components/SimpleSession/UpscalingLaunchpadPanel.tsx b/invokeai/frontend/web/src/features/controlLayers/components/SimpleSession/UpscalingLaunchpadPanel.tsx index 29538fcdb8..b8c11c0d53 100644 --- a/invokeai/frontend/web/src/features/controlLayers/components/SimpleSession/UpscalingLaunchpadPanel.tsx +++ b/invokeai/frontend/web/src/features/controlLayers/components/SimpleSession/UpscalingLaunchpadPanel.tsx @@ -1,4 +1,4 @@ -import { Box, Flex, FormControl, FormLabel, Grid, Heading, Icon, Text } from '@invoke-ai/ui-library'; +import { Box, Flex, Grid, Heading, Icon, Text } from '@invoke-ai/ui-library'; import { useAppDispatch, useAppSelector } from 'app/store/storeHooks'; import { useImageUploadButton } from 'common/hooks/useImageUploadButton'; import { setUpscaleInitialImageDndTarget } from 'features/dnd/dnd'; @@ -47,8 +47,8 @@ export const UpscalingLaunchpadPanel = memo(() => { <> - Upload Image to Upscale - Click or drag an image to upscale (JPG, PNG, WebP up to 100MB) + {t('ui.launchpad.upscaling.uploadImage.title')} + {t('ui.launchpad.upscaling.uploadImage.description')} @@ -83,8 +83,8 @@ export const UpscalingLaunchpadPanel = memo(() => { >{`${upscaleInitialImage.width}x${upscaleInitialImage.height}`} - Image Ready - Press Invoke to begin upscaling + {t('ui.launchpad.upscaling.imageReady.title')} + {t('ui.launchpad.upscaling.imageReady.description')} )} @@ -97,16 +97,9 @@ export const UpscalingLaunchpadPanel = memo(() => { {/* Guidance text */} {upscaleInitialImage && ( - + - Ready to upscale! Configure your settings below, then click the Invoke button to begin upscaling your image. + {t('ui.launchpad.upscaling.readyToUpscale.title')} {t('ui.launchpad.upscaling.readyToUpscale.description')} )} @@ -117,19 +110,25 @@ export const UpscalingLaunchpadPanel = memo(() => { {/* Left Column: All parameters stacked */} - Upscale Model + + {t('ui.launchpad.upscaling.upscaleModel')} + - Model + + {t('ui.launchpad.upscaling.model')} + - Scale + + {t('ui.launchpad.upscaling.scale')} + @@ -138,10 +137,10 @@ export const UpscalingLaunchpadPanel = memo(() => { {/* Right Column: Description/help text */} - When upscaling, use a prompt that describes the medium and style. Avoid describing specific content details in the image. + {t('ui.launchpad.upscaling.helpText.promptAdvice')} - Upscaling works best with the general style of your image. + {t('ui.launchpad.upscaling.helpText.styleAdvice')} diff --git a/invokeai/frontend/web/src/features/controlLayers/components/SimpleSession/WorkflowsLaunchpadPanel.tsx b/invokeai/frontend/web/src/features/controlLayers/components/SimpleSession/WorkflowsLaunchpadPanel.tsx index e1321e468d..867c571cd1 100644 --- a/invokeai/frontend/web/src/features/controlLayers/components/SimpleSession/WorkflowsLaunchpadPanel.tsx +++ b/invokeai/frontend/web/src/features/controlLayers/components/SimpleSession/WorkflowsLaunchpadPanel.tsx @@ -1,5 +1,4 @@ -import { Button, Flex, Heading, Icon, Link, Text } from '@invoke-ai/ui-library'; -import { useImageUploadButton } from 'common/hooks/useImageUploadButton'; +import { Flex, Heading, Icon, Link, Text } from '@invoke-ai/ui-library'; import { useWorkflowLibraryModal } from 'features/nodes/store/workflowLibraryModal'; import { useNewWorkflow } from 'features/workflowLibrary/components/NewWorkflowConfirmationAlertDialog'; import { useLoadWorkflowFromFile } from 'features/workflowLibrary/hooks/useLoadWorkflowFromFile'; @@ -22,13 +21,6 @@ export const WorkflowsLaunchpadPanel = memo(() => { [loadWorkflowFromFile] ); - const uploadApi = useImageUploadButton({ - allowMultiple: false, - onUpload: (imageDTOs) => { - // Handle workflow file upload - this would need to be adapted for workflow files - } - }); - const handleBrowseTemplates = useCallback(() => { workflowLibraryModal.open(); }, [workflowLibraryModal]); @@ -58,17 +50,16 @@ export const WorkflowsLaunchpadPanel = memo(() => { {/* Description */} - Workflows are reusable templates that automate image generation tasks, - allowing you to quickly perform complex operations and get consistent results. + {t('ui.launchpad.workflows.description')} - - {t('learnMore')} about creating workflows + {t('ui.launchpad.workflows.learnMoreLink')} {/* Action Buttons */} @@ -77,8 +68,8 @@ export const WorkflowsLaunchpadPanel = memo(() => { - Browse Workflow Templates - Choose from pre-built workflows for common tasks + {t('ui.launchpad.workflows.browseTemplates.title')} + {t('ui.launchpad.workflows.browseTemplates.description')} @@ -86,8 +77,8 @@ export const WorkflowsLaunchpadPanel = memo(() => { - Create a new Workflow - Start a new workflow from scratch + {t('ui.launchpad.workflows.createNew.title')} + {t('ui.launchpad.workflows.createNew.description')} @@ -95,8 +86,8 @@ export const WorkflowsLaunchpadPanel = memo(() => { - Load workflow from existing image or file - Drag or upload a workflow to start with an existing setup + {t('ui.launchpad.workflows.loadFromFile.title')} + {t('ui.launchpad.workflows.loadFromFile.description')}