mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-26 09:44:06 +00:00
Add command to switch opened workflow tabs (#1109)
This commit is contained in:
@@ -16,6 +16,7 @@ import { useWorkspaceStore } from './workspaceStateStore'
|
||||
import { LGraphGroup } from '@comfyorg/litegraph'
|
||||
import { useTitleEditorStore } from './graphStore'
|
||||
import { useErrorHandling } from '@/hooks/errorHooks'
|
||||
import { useWorkflowStore } from './workflowStore'
|
||||
|
||||
export interface ComfyCommand {
|
||||
id: string
|
||||
@@ -296,6 +297,22 @@ export const useCommandStore = defineStore('command', () => {
|
||||
app.canvas.graph.add(group)
|
||||
useTitleEditorStore().titleEditorTarget = group
|
||||
}
|
||||
},
|
||||
{
|
||||
id: 'Workspace.NextOpenedWorkflow',
|
||||
icon: 'pi pi-step-forward',
|
||||
label: 'Next Opened Workflow',
|
||||
function: () => {
|
||||
useWorkflowStore().loadNextOpenedWorkflow()
|
||||
}
|
||||
},
|
||||
{
|
||||
id: 'Workspace.PreviousOpenedWorkflow',
|
||||
icon: 'pi pi-step-backward',
|
||||
label: 'Previous Opened Workflow',
|
||||
function: () => {
|
||||
useWorkflowStore().loadPreviousOpenedWorkflow()
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user