perf: streamline prompt relay and guide ui

This commit is contained in:
OpenClaw Agent
2026-07-09 15:51:58 +00:00
parent a536ac5a14
commit ab7d14bd89
2 changed files with 172 additions and 152 deletions

View File

@@ -1,24 +1,30 @@
import { app } from "../../scripts/app.js";
// LTX Director Guide is a pure pass-through processor node.
// All configuration (images, insert frames, strengths) comes from
// the guide_data output of Prompt Relay Encode (Timeline).
app.registerExtension({
name: "Comfy.LTXDirectorGuideCS",
async nodeCreated(node) {
if (node.comfyClass !== "LTXDirectorGuideCS") return;
// Hide retake_mode widget on LiteGraph as it is dynamically auto-detected from the timeline data.
const w = node.widgets?.find(x => x.name === "retake_mode");
if (w) {
w.hidden = true;
if (!w.options) w.options = {};
w.options.hidden = true;
if (!window.LiteGraph || !window.LiteGraph.vueNodesMode) {
w.computeSize = () => [0, -4];
w.draw = () => { };
}
if (w.element) w.element.style.display = "none";
}
},
});
import { app } from "../../scripts/app.js";
// LTX Director Guide is a pure pass-through processor node.
// All configuration (images, insert frames, strengths) comes from
// the guide_data output of Prompt Relay Encode (Timeline).
function hideWidget(node, widgetName) {
const widget = node.widgets?.find((entry) => entry.name === widgetName);
if (!widget) return;
widget.hidden = true;
widget.options = widget.options || {};
widget.options.hidden = true;
if (!window.LiteGraph || !window.LiteGraph.vueNodesMode) {
widget.computeSize = () => [0, -4];
widget.draw = () => {};
}
if (widget.element) widget.element.style.display = "none";
}
app.registerExtension({
name: "Comfy.LTXDirectorGuideCS",
async nodeCreated(node) {
if (node.comfyClass !== "LTXDirectorGuideCS") return;
// Hide retake_mode widget on LiteGraph as it is dynamically auto-detected from the timeline data.
hideWidget(node, "retake_mode");
},
});