diff --git a/web/extensions/core/contextMenuOptions.js b/web/extensions/core/contextMenuOptions.js new file mode 100644 index 000000000..f416af2dd --- /dev/null +++ b/web/extensions/core/contextMenuOptions.js @@ -0,0 +1,17 @@ +import {app} from "/scripts/app.js"; + +app.registerExtension({ + name: "Comfy.ContextMenuOptions", + init() { + const ctxMenu = LiteGraph.ContextMenu; + + LiteGraph.ContextMenu = function (values, options) { + options.autoopen = true; + const ctx = ctxMenu.call(this, values, options); + + return ctx; + } + + LiteGraph.ContextMenu.prototype = ctxMenu.prototype; + } +}); \ No newline at end of file