From 89277853082e2d4be2b07565b714f2587f873e93 Mon Sep 17 00:00:00 2001 From: huchenlei Date: Mon, 30 Sep 2024 15:41:09 -0400 Subject: [PATCH] Add setting --- src/components/graph/GraphCanvas.vue | 5 ++++- src/stores/coreSettings.ts | 7 ++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/components/graph/GraphCanvas.vue b/src/components/graph/GraphCanvas.vue index 8003547dc..731e132be 100644 --- a/src/components/graph/GraphCanvas.vue +++ b/src/components/graph/GraphCanvas.vue @@ -5,7 +5,7 @@ @@ -59,6 +59,9 @@ const modelToNodeStore = useModelToNodeStore() const betaMenuEnabled = computed( () => settingStore.get('Comfy.UseNewMenu') !== 'Disabled' ) +const canvasMenuEnabled = computed(() => + settingStore.get('Comfy.Graph.CanvasMenu') +) watchEffect(() => { const canvasInfoEnabled = settingStore.get('Comfy.Graph.CanvasInfo') diff --git a/src/stores/coreSettings.ts b/src/stores/coreSettings.ts index ef4e1ae25..acdc4bd13 100644 --- a/src/stores/coreSettings.ts +++ b/src/stores/coreSettings.ts @@ -12,7 +12,6 @@ export const CORE_SETTINGS: SettingParams[] = [ type: 'boolean', defaultValue: true }, - { id: 'Comfy.NodeSearchBoxImpl', category: ['Comfy', 'Node Search Box', 'Implementation'], @@ -381,5 +380,11 @@ export const CORE_SETTINGS: SettingParams[] = [ type: 'hidden', options: ['Sidebar', 'Topbar'], defaultValue: 'Sidebar' + }, + { + id: 'Comfy.Graph.CanvasMenu', + name: 'Show graph canvas menu', + type: 'boolean', + defaultValue: true } ]