mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
added translation where needed
This commit is contained in:
parent
fafe8ccc59
commit
ea1d2d6a4c
@ -4,7 +4,7 @@ import { motion } from 'framer-motion';
|
||||
import type { ReactNode } from 'react';
|
||||
import { memo, useRef } from 'react';
|
||||
import { v4 as uuidv4 } from 'uuid';
|
||||
|
||||
import { useTranslation } from 'react-i18next';
|
||||
type Props = {
|
||||
isOver: boolean;
|
||||
label?: ReactNode;
|
||||
@ -23,7 +23,8 @@ const exit: AnimationProps['exit'] = {
|
||||
};
|
||||
|
||||
const IAIDropOverlay = (props: Props) => {
|
||||
const { isOver, label = 'Drop' } = props;
|
||||
const { t } = useTranslation();
|
||||
const { isOver, label = t('gallery.drop') } = props;
|
||||
const motionId = useRef(uuidv4());
|
||||
return (
|
||||
<motion.div
|
||||
|
@ -3,6 +3,7 @@ import { createMemoizedSelector } from 'app/store/createMemoizedSelector';
|
||||
import { useAppDispatch, useAppSelector } from 'app/store/storeHooks';
|
||||
import IAIDndImage from 'common/components/IAIDndImage';
|
||||
import { IAINoContentFallback } from 'common/components/IAIImageFallback';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import type {
|
||||
TypesafeDraggableData,
|
||||
TypesafeDroppableData,
|
||||
@ -20,6 +21,7 @@ const selectInitialImage = createMemoizedSelector(
|
||||
);
|
||||
|
||||
const InitialImage = () => {
|
||||
const { t } = useTranslation();
|
||||
const dispatch = useAppDispatch();
|
||||
const initialImage = useAppSelector(selectInitialImage);
|
||||
const isConnected = useAppSelector((s) => s.system.isConnected);
|
||||
@ -62,7 +64,7 @@ const InitialImage = () => {
|
||||
fitContainer
|
||||
dropLabel="Set as Initial Image"
|
||||
noContentFallback={
|
||||
<IAINoContentFallback label="No initial image selected" />
|
||||
<IAINoContentFallback label={t('parameters.invoke.noInitialImageSelected')} />
|
||||
}
|
||||
dataTestId="initial-image"
|
||||
/>
|
||||
|
Loading…
Reference in New Issue
Block a user