mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-02 06:19:58 +00:00
[feat] Hide subgraph nodes from node library and search (#4498)
This commit is contained in:
@@ -374,6 +374,21 @@ export const useNodeDefStore = defineStore('nodeDef', () => {
|
||||
'Hides nodes marked as experimental unless explicitly enabled',
|
||||
predicate: (nodeDef) => showExperimental.value || !nodeDef.experimental
|
||||
})
|
||||
|
||||
// Subgraph nodes filter
|
||||
// @todo Remove this filter when subgraph v2 is released
|
||||
registerNodeDefFilter({
|
||||
id: 'core.subgraph',
|
||||
name: 'Hide Subgraph Nodes',
|
||||
description:
|
||||
'Temporarily hides subgraph nodes from node library and search',
|
||||
predicate: (nodeDef) => {
|
||||
// Hide subgraph nodes (identified by category='subgraph' and python_module='nodes')
|
||||
return !(
|
||||
nodeDef.category === 'subgraph' && nodeDef.python_module === 'nodes'
|
||||
)
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
// Register core filters on store initialization
|
||||
|
||||
Reference in New Issue
Block a user