ComfyUI/web/extensions/comfyui_exit/exit_button.js
2026-04-11 09:08:19 +10:00

25 lines
557 B
JavaScript
Vendored

import { app } from "../../scripts/app.js";
app.registerExtension({
name: "comfyui.exit",
commands: [
{
id: "Comfy.Exit",
label: "Exit",
menubarLabel: "Exit",
icon: "pi pi-power-off",
function: async () => {
if (confirm("Shut down ComfyUI?")) {
window.location.href = "/stopped";
}
}
}
],
menuCommands: [
{
path: ["File"],
commands: ["Comfy.Exit"]
}
]
});