mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-01-11 18:35:17 +00:00
Fix large workflow pnginfo import
This commit is contained in:
parent
1718730e80
commit
e76890dcb4
@ -32,8 +32,9 @@ export function getPngMetadata(file) {
|
|||||||
}
|
}
|
||||||
const keyword = String.fromCharCode(...pngData.slice(offset + 8, keyword_end));
|
const keyword = String.fromCharCode(...pngData.slice(offset + 8, keyword_end));
|
||||||
// Get the text
|
// Get the text
|
||||||
const text = String.fromCharCode(...pngData.slice(keyword_end + 1, offset + 8 + length));
|
const contentArraySegment = pngData.slice(keyword_end + 1, offset + 8 + length);
|
||||||
txt_chunks[keyword] = text;
|
const contentJson = Array.from(contentArraySegment).map(s=>String.fromCharCode(s)).join('')
|
||||||
|
txt_chunks[keyword] = contentJson;
|
||||||
}
|
}
|
||||||
|
|
||||||
offset += 12 + length;
|
offset += 12 + length;
|
||||||
|
Loading…
Reference in New Issue
Block a user