mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
change selectedWorkflow to selectedWorkflowId
This commit is contained in:
parent
8840df2b00
commit
88648dca1a
@ -38,11 +38,11 @@ interface Props {
|
|||||||
imageName: string;
|
imageName: string;
|
||||||
action: 'sendToImg2Img' | 'sendToCanvas' | 'useAllParameters';
|
action: 'sendToImg2Img' | 'sendToCanvas' | 'useAllParameters';
|
||||||
};
|
};
|
||||||
selectedWorkflow?: string;
|
selectedWorkflowId?: string;
|
||||||
destination?: InvokeTabName | undefined;
|
destination?: InvokeTabName | undefined;
|
||||||
}
|
}
|
||||||
|
|
||||||
const App = ({ config = DEFAULT_CONFIG, selectedImage, selectedWorkflow, destination }: Props) => {
|
const App = ({ config = DEFAULT_CONFIG, selectedImage, selectedWorkflowId, destination }: Props) => {
|
||||||
const language = useAppSelector(languageSelector);
|
const language = useAppSelector(languageSelector);
|
||||||
const logger = useLogger('system');
|
const logger = useLogger('system');
|
||||||
const dispatch = useAppDispatch();
|
const dispatch = useAppDispatch();
|
||||||
@ -81,11 +81,11 @@ const App = ({ config = DEFAULT_CONFIG, selectedImage, selectedWorkflow, destina
|
|||||||
});
|
});
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (selectedWorkflow && !hasLoadedRef.current) {
|
if (selectedWorkflowId && !hasLoadedRef.current) {
|
||||||
getAndLoadWorkflow(selectedWorkflow);
|
getAndLoadWorkflow(selectedWorkflowId);
|
||||||
hasLoadedRef.current = true;
|
hasLoadedRef.current = true;
|
||||||
}
|
}
|
||||||
}, [selectedWorkflow, getAndLoadWorkflow]);
|
}, [selectedWorkflowId, getAndLoadWorkflow]);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (destination) {
|
if (destination) {
|
||||||
|
@ -44,7 +44,7 @@ interface Props extends PropsWithChildren {
|
|||||||
imageName: string;
|
imageName: string;
|
||||||
action: 'sendToImg2Img' | 'sendToCanvas' | 'useAllParameters';
|
action: 'sendToImg2Img' | 'sendToCanvas' | 'useAllParameters';
|
||||||
};
|
};
|
||||||
selectedWorkflow?: string;
|
selectedWorkflowId?: string;
|
||||||
destination?: InvokeTabName;
|
destination?: InvokeTabName;
|
||||||
customStarUi?: CustomStarUi;
|
customStarUi?: CustomStarUi;
|
||||||
socketOptions?: Partial<ManagerOptions & SocketOptions>;
|
socketOptions?: Partial<ManagerOptions & SocketOptions>;
|
||||||
@ -65,7 +65,7 @@ const InvokeAIUI = ({
|
|||||||
projectUrl,
|
projectUrl,
|
||||||
queueId,
|
queueId,
|
||||||
selectedImage,
|
selectedImage,
|
||||||
selectedWorkflow,
|
selectedWorkflowId,
|
||||||
destination,
|
destination,
|
||||||
customStarUi,
|
customStarUi,
|
||||||
socketOptions,
|
socketOptions,
|
||||||
@ -226,7 +226,7 @@ const InvokeAIUI = ({
|
|||||||
<App
|
<App
|
||||||
config={config}
|
config={config}
|
||||||
selectedImage={selectedImage}
|
selectedImage={selectedImage}
|
||||||
selectedWorkflow={selectedWorkflow}
|
selectedWorkflowId={selectedWorkflowId}
|
||||||
destination={destination}
|
destination={destination}
|
||||||
/>
|
/>
|
||||||
</AppDndContext>
|
</AppDndContext>
|
||||||
|
Loading…
Reference in New Issue
Block a user