|
5 | 5 | </div> |
6 | 6 | <p class="text-justify max-h-[18px] truncate max-w-[60vw] md:max-w-none">{{ props.meta.actionName }}</p> |
7 | 7 | </div> |
8 | | - <Dialog |
| 8 | + <Dialog |
9 | 9 | ref="confirmDialog" |
10 | | - header="Bulk AI Generation" |
| 10 | + :header="t('Bulk AI Generation')" |
11 | 11 | class="[scrollbar-gutter:stable] max-w-full h-fit" |
12 | 12 | :beforeCancelFunction="handleBeforeCancel" |
13 | 13 | :class="popupMode === 'generation' ? 'lg:w-auto !lg:max-w-[1600px]' |
|
234 | 234 | dark:focus:border-gray-700 |
235 | 235 | focus:outline-none |
236 | 236 | focus:border-gray-200" |
237 | | - placeholder="Enter prompt instructions..." |
| 237 | + :placeholder="t('Enter prompt instructions...')" |
238 | 238 | ></Textarea> |
239 | 239 | </div> |
240 | 240 |
|
@@ -1069,17 +1069,17 @@ function applyJobResult(record: RecordState, job: any, actionType: GenerationAct |
1069 | 1069 | } |
1070 | 1070 |
|
1071 | 1071 | function applyJobFailure(record: RecordState, job: any, actionType: GenerationAction) { |
1072 | | - registerGenerationFailure(record, actionType, job?.error || 'Unknown error'); |
| 1072 | + registerGenerationFailure(record, actionType, job?.error || t('Unknown error')); |
1073 | 1073 | if (actionType === 'generate_images') { |
1074 | 1074 | record.imageGenerationFailed = true; |
1075 | | - record.imageGenerationErrorMessage = job?.error || 'Unknown error'; |
| 1075 | + record.imageGenerationErrorMessage = job?.error || t('Unknown error'); |
1076 | 1076 | } else if (actionType === 'analyze') { |
1077 | 1077 | for (const field of Object.keys(props.meta.outputFieldsForAnalizeFromImages || {})) { |
1078 | | - record.imageToTextErrorMessages[props.meta.outputFieldsForAnalizeFromImages[field]] = job?.error || 'Unknown error'; |
| 1078 | + record.imageToTextErrorMessages[props.meta.outputFieldsForAnalizeFromImages[field]] = job?.error || t('Unknown error'); |
1079 | 1079 | } |
1080 | 1080 | } else if (actionType === 'analyze_no_images') { |
1081 | 1081 | for (const field of Object.keys(props.meta.outputPlainFields || {})) { |
1082 | | - record.textToTextErrorMessages[props.meta.outputPlainFields[field]] = job?.error || 'Unknown error'; |
| 1082 | + record.textToTextErrorMessages[props.meta.outputPlainFields[field]] = job?.error || t('Unknown error'); |
1083 | 1083 | } |
1084 | 1084 | } |
1085 | 1085 | touchRecords(); |
@@ -1427,12 +1427,12 @@ async function uploadImage(imgBlob, id, fieldName) { |
1427 | 1427 | } catch (error) { |
1428 | 1428 | console.error('Error uploading file:', error); |
1429 | 1429 | adminforth.alert({ |
1430 | | - message: 'Sorry but the file was not be uploaded. Please try again.', |
| 1430 | + message: t('Sorry but the file was not be uploaded. Please try again.'), |
1431 | 1431 | variant: 'danger' |
1432 | 1432 | }); |
1433 | 1433 |
|
1434 | 1434 | isError.value = true; |
1435 | | - errorMessage.value = `Failed to upload images. Please, try to re-run the action.`; |
| 1435 | + errorMessage.value = t('Failed to upload images. Please, try to re-run the action.'); |
1436 | 1436 | return null; |
1437 | 1437 | } |
1438 | 1438 | } |
|
0 commit comments