"test/git@developer.sourcefind.cn:zhaoyu6/sglang.git" did not exist on "28c79dc84ab8d6f2a35dd00a543f7961e90c39c9"
Commit 28677342 authored by Dr.Lt.Data's avatar Dr.Lt.Data
Browse files

robust paste for image

parent 70e02b44
......@@ -165,7 +165,16 @@ export class ComfyApp {
if(ComfyApp.clipspace.widgets) {
ComfyApp.clipspace.widgets.forEach(({ type, name, value }) => {
const prop = Object.values(node.widgets).find(obj => obj.type === type && obj.name === name);
if (prop && prop.type != 'button') {
if (prop && prop.type != 'image') {
if(typeof prop.value == "string" && value.filename) {
prop.value = (value.subfolder?value.subfolder+'/':'') + value.filename + (value.type?` [${value.type}]`:'');
}
else {
prop.value = value;
prop.callback(value);
}
}
else if (prop && prop.type != 'button') {
prop.value = value;
prop.callback(value);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment