mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-09-13 21:16:09 +00:00
Changed to upload to input dir
Fixed jpg Added dupe support Changed to use existing nodes
This commit is contained in:
@@ -1,9 +1,11 @@
|
||||
import { app } from "/scripts/app.js";
|
||||
|
||||
// Adds an upload button to the nodes
|
||||
|
||||
app.registerExtension({
|
||||
name: "Comfy.UploadImage",
|
||||
async beforeRegisterNodeDef(nodeType, nodeData, app) {
|
||||
if (nodeData.name === "UploadImage" || nodeData.name === "UploadImageMask") {
|
||||
if (nodeData.name === "LoadImage" || nodeData.name === "LoadImageMask") {
|
||||
nodeData.input.required.upload = ["IMAGEUPLOAD"];
|
||||
}
|
||||
},
|
||||
|
@@ -141,7 +141,7 @@ export const ComfyWidgets = {
|
||||
node.imgs = [img];
|
||||
app.graph.setDirtyCanvas(true);
|
||||
};
|
||||
img.src = `/view/${name}?type=uploads`;
|
||||
img.src = `/view/${name}?type=input`;
|
||||
}
|
||||
|
||||
// Add our own callback to the combo widget to render an image when it changes
|
||||
|
Reference in New Issue
Block a user