mirror of
https://github.com/invoke-ai/InvokeAI.git
synced 2026-04-23 03:00:31 -04:00
fix(ui): when changing viewer state, always clear compare image
This commit is contained in:
@@ -89,10 +89,7 @@ export const gallerySlice = createSlice({
|
|||||||
state.alwaysShowImageSizeBadge = action.payload;
|
state.alwaysShowImageSizeBadge = action.payload;
|
||||||
},
|
},
|
||||||
isImageViewerOpenChanged: (state, action: PayloadAction<boolean>) => {
|
isImageViewerOpenChanged: (state, action: PayloadAction<boolean>) => {
|
||||||
if (state.isImageViewerOpen && state.imageToCompare) {
|
state.imageToCompare = null;
|
||||||
state.imageToCompare = null;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
state.isImageViewerOpen = action.payload;
|
state.isImageViewerOpen = action.payload;
|
||||||
},
|
},
|
||||||
comparedImagesSwapped: (state) => {
|
comparedImagesSwapped: (state) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user