feat(ui): clean up state, add mutex for image loading, add thumbnail loading

This commit is contained in:
psychedelicious
2024-08-07 17:20:18 +10:00
parent 57f3107dba
commit 02ddfc5aac
15 changed files with 96 additions and 96 deletions

View File

@@ -129,12 +129,12 @@ const buildControlImage = (
if (processedImage && processorConfig) {
// We've processed the image in the app - use it for the control image.
return {
image_name: processedImage.name,
image_name: processedImage.image_name,
};
} else if (image) {
// No processor selected, and we have an image - the user provided a processed image, use it for the control image.
return {
image_name: image.name,
image_name: image.image_name,
};
}
assert(false, 'Attempted to add unprocessed control image');

View File

@@ -49,7 +49,7 @@ const addIPAdapter = (ipa: CanvasIPAdapterState, g: Graph, denoise: Invocation<'
begin_step_percent: beginEndStepPct[0],
end_step_percent: beginEndStepPct[1],
image: {
image_name: imageObject.image.name,
image_name: imageObject.image.image_name,
},
});
g.addEdge(ipAdapter, 'ip_adapter', ipAdapterCollect, 'item');

View File

@@ -191,7 +191,7 @@ export const addRegions = async (
begin_step_percent: beginEndStepPct[0],
end_step_percent: beginEndStepPct[1],
image: {
image_name: imageObject.image.name,
image_name: imageObject.image.image_name,
},
});