mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-03-13 17:10:06 +00:00
filter out templates that have custom nodes when not on cloud (temporary) (#6690)
Templates are being added that have custom nodes. As a temporary measure, filter these out on local. In a followup, add a UX to allow local users to do something like opt-in to use these or to show these on the condition that the user has these custom nodes installed. ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-6690-filter-out-templates-that-have-custom-nodes-when-not-on-cloud-temporary-2ab6d73d3650819981c0e9b26d34acff) by [Unito](https://www.unito.io) --------- Co-authored-by: Alexander Brown <drjkl@comfy.org> Co-authored-by: GitHub Action <action@github.com>
This commit is contained in:
@@ -237,7 +237,17 @@ export const useWorkflowTemplatesStore = defineStore(
|
||||
}
|
||||
)
|
||||
|
||||
return allTemplates
|
||||
// TODO: Temporary filtering of custom node templates on local installations
|
||||
// Future: Add UX that allows local users to opt-in to templates with custom nodes,
|
||||
// potentially conditional on whether they have those specific custom nodes installed.
|
||||
// This would provide better template discovery while respecting local user workflows.
|
||||
const filteredTemplates = isCloud
|
||||
? allTemplates
|
||||
: allTemplates.filter(
|
||||
(template) => !template.requiresCustomNodes?.length
|
||||
)
|
||||
|
||||
return filteredTemplates
|
||||
})
|
||||
|
||||
/**
|
||||
|
||||
@@ -27,6 +27,11 @@ export interface TemplateInfo {
|
||||
* Whether this template uses open source models. When false, indicates partner/API node templates.
|
||||
*/
|
||||
openSource?: boolean
|
||||
/**
|
||||
* Array of custom node package IDs required for this template (from Custom Node Registry).
|
||||
* Templates with this field will be hidden on local installations temporarily.
|
||||
*/
|
||||
requiresCustomNodes?: string[]
|
||||
}
|
||||
|
||||
export interface WorkflowTemplates {
|
||||
|
||||
Reference in New Issue
Block a user