From 080c758cda19288039de6941876dbdf6f3f9d357 Mon Sep 17 00:00:00 2001 From: City <125218114+city96@users.noreply.github.com> Date: Tue, 4 Apr 2023 18:16:23 +0200 Subject: [PATCH] Ask for confirmation before clearing nodes --- web/scripts/ui.js | 1 + 1 file changed, 1 insertion(+) diff --git a/web/scripts/ui.js b/web/scripts/ui.js index 679f10b2..68bfc792 100644 --- a/web/scripts/ui.js +++ b/web/scripts/ui.js @@ -510,6 +510,7 @@ export class ComfyUI { $el("button", { textContent: "Load", onclick: () => fileInput.click() }), $el("button", { textContent: "Refresh", onclick: () => app.refreshComboInNodes() }), $el("button", { textContent: "Clear", onclick: () => { + if (!confirm("Are you sure you want to remove all nodes?")) return; app.clean(); app.graph.clear(); }}),