mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
feat(ui): restore reset button for init image
This commit is contained in:
parent
07c49a5726
commit
fd03c7eebe
@ -14,7 +14,7 @@ import ImageMetadataOverlay from 'common/components/ImageMetadataOverlay';
|
|||||||
import { AnimatePresence } from 'framer-motion';
|
import { AnimatePresence } from 'framer-motion';
|
||||||
import { ReactElement, SyntheticEvent, useCallback } from 'react';
|
import { ReactElement, SyntheticEvent, useCallback } from 'react';
|
||||||
import { memo, useRef } from 'react';
|
import { memo, useRef } from 'react';
|
||||||
import { FaImage, FaTimes, FaUpload } from 'react-icons/fa';
|
import { FaImage, FaTimes, FaUndo, FaUpload } from 'react-icons/fa';
|
||||||
import { ImageDTO } from 'services/api';
|
import { ImageDTO } from 'services/api';
|
||||||
import { v4 as uuidv4 } from 'uuid';
|
import { v4 as uuidv4 } from 'uuid';
|
||||||
import IAIDropOverlay from './IAIDropOverlay';
|
import IAIDropOverlay from './IAIDropOverlay';
|
||||||
@ -174,14 +174,13 @@ const IAIDndImage = (props: IAIDndImageProps) => {
|
|||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
top: 0,
|
top: 0,
|
||||||
right: 0,
|
right: 0,
|
||||||
p: 2,
|
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<IAIIconButton
|
<IAIIconButton
|
||||||
size={resetIconSize}
|
size={resetIconSize}
|
||||||
tooltip="Reset Image"
|
tooltip="Reset Image"
|
||||||
aria-label="Reset Image"
|
aria-label="Reset Image"
|
||||||
icon={<FaTimes />}
|
icon={<FaUndo />}
|
||||||
onClick={onReset}
|
onClick={onReset}
|
||||||
/>
|
/>
|
||||||
</Box>
|
</Box>
|
||||||
|
@ -58,6 +58,7 @@ const InitialImagePreview = () => {
|
|||||||
onReset={handleReset}
|
onReset={handleReset}
|
||||||
fallback={<IAIImageFallback sx={{ bg: 'none' }} />}
|
fallback={<IAIImageFallback sx={{ bg: 'none' }} />}
|
||||||
postUploadAction={{ type: 'SET_INITIAL_IMAGE' }}
|
postUploadAction={{ type: 'SET_INITIAL_IMAGE' }}
|
||||||
|
withResetIcon
|
||||||
/>
|
/>
|
||||||
</Flex>
|
</Flex>
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user