feat: client-side distribution filtering for blueprint subgraphs (#8686)

Adds client-side filtering of blueprint subgraphs by distribution.

**Changes:**
- Added `includeOnDistributions` typed field to `GlobalSubgraphData` in
`api.ts`
- Distribution detection: `isCloud → 'cloud'`, `isDesktop → 'desktop'`,
else `'localhost'`
- Filters subgraphs before loading — excluded blueprints are never
fetched

**Depends on:** Comfy-Org/workflow_templates schema update (merge first)

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-8686-feat-client-side-distribution-filtering-for-blueprint-subgraphs-2ff6d73d365081d29f79c4e3cab174ac)
by [Unito](https://www.unito.io)
This commit is contained in:
Christian Byrne
2026-02-20 17:02:54 -08:00
committed by GitHub
parent b27eb5861a
commit 337e0486ea
3 changed files with 113 additions and 6 deletions

View File

@@ -11,9 +11,10 @@ import type {
import { isCloud } from '@/platform/distribution/types'
import { useToastStore } from '@/platform/updates/common/toastStore'
import type { IFuseOptions } from 'fuse.js'
import {
type TemplateInfo,
type WorkflowTemplates
import type {
TemplateIncludeOnDistributionEnum,
TemplateInfo,
WorkflowTemplates
} from '@/platform/workflow/templates/types/template'
import type {
ComfyApiWorkflow,
@@ -241,6 +242,8 @@ export type GlobalSubgraphData = {
node_pack: string
category?: string
search_aliases?: string[]
requiresCustomNodes?: string[]
includeOnDistributions?: TemplateIncludeOnDistributionEnum[]
}
data: string | Promise<string>
essentials_category?: string