mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-02-16 16:32:34 +08:00
easy way to exclude json from dynamic prompt manipulation
This commit is contained in:
parent
4eab00e14b
commit
922540947c
@ -17,7 +17,7 @@ app.registerExtension({
|
||||
// Locate dynamic prompt text widgets
|
||||
// Include any widgets with dynamicPrompts set to true, and customtext
|
||||
const widgets = node.widgets.filter(
|
||||
(n) => (n.type === "customtext" && n.dynamicPrompts !== false) || n.dynamicPrompts
|
||||
widget => widget.dynamicPrompts || (widget.customtext && !widget.widgets.some(subWidget => subWidget.name.toLowerCase().includes("json")))
|
||||
);
|
||||
for (const widget of widgets) {
|
||||
// Override the serialization of the value to resolve dynamic prompts for all widgets supporting it in this node
|
||||
|
||||
Loading…
Reference in New Issue
Block a user