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;
|
||||
action: 'sendToImg2Img' | 'sendToCanvas' | 'useAllParameters';
|
||||
};
|
||||
selectedWorkflow?: string;
|
||||
selectedWorkflowId?: string;
|
||||
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 logger = useLogger('system');
|
||||
const dispatch = useAppDispatch();
|
||||
@ -81,11 +81,11 @@ const App = ({ config = DEFAULT_CONFIG, selectedImage, selectedWorkflow, destina
|
||||
});
|
||||
|
||||
useEffect(() => {
|
||||
if (selectedWorkflow && !hasLoadedRef.current) {
|
||||
getAndLoadWorkflow(selectedWorkflow);
|
||||
if (selectedWorkflowId && !hasLoadedRef.current) {
|
||||
getAndLoadWorkflow(selectedWorkflowId);
|
||||
hasLoadedRef.current = true;
|
||||
}
|
||||
}, [selectedWorkflow, getAndLoadWorkflow]);
|
||||
}, [selectedWorkflowId, getAndLoadWorkflow]);
|
||||
|
||||
useEffect(() => {
|
||||
if (destination) {
|
||||
|
@ -44,7 +44,7 @@ interface Props extends PropsWithChildren {
|
||||
imageName: string;
|
||||
action: 'sendToImg2Img' | 'sendToCanvas' | 'useAllParameters';
|
||||
};
|
||||
selectedWorkflow?: string;
|
||||
selectedWorkflowId?: string;
|
||||
destination?: InvokeTabName;
|
||||
customStarUi?: CustomStarUi;
|
||||
socketOptions?: Partial<ManagerOptions & SocketOptions>;
|
||||
@ -65,7 +65,7 @@ const InvokeAIUI = ({
|
||||
projectUrl,
|
||||
queueId,
|
||||
selectedImage,
|
||||
selectedWorkflow,
|
||||
selectedWorkflowId,
|
||||
destination,
|
||||
customStarUi,
|
||||
socketOptions,
|
||||
@ -226,7 +226,7 @@ const InvokeAIUI = ({
|
||||
<App
|
||||
config={config}
|
||||
selectedImage={selectedImage}
|
||||
selectedWorkflow={selectedWorkflow}
|
||||
selectedWorkflowId={selectedWorkflowId}
|
||||
destination={destination}
|
||||
/>
|
||||
</AppDndContext>
|
||||
|
Loading…
Reference in New Issue
Block a user