diff --git a/src/locales/en/main.json b/src/locales/en/main.json index cd3671bd5a..c05b092444 100644 --- a/src/locales/en/main.json +++ b/src/locales/en/main.json @@ -2850,5 +2850,15 @@ "label": "Preview Version", "tooltip": "You are using a nightly version of ComfyUI. Please use the feedback button to share your thoughts about these features." } + }, + "nodeFilters": { + "hideDeprecated": "Hide Deprecated Nodes", + "hideDeprecatedDescription": "Hides nodes marked as deprecated unless explicitly enabled", + "hideExperimental": "Hide Experimental Nodes", + "hideExperimentalDescription": "Hides nodes marked as experimental unless explicitly enabled", + "hideDevOnly": "Hide Dev-Only Nodes", + "hideDevOnlyDescription": "Hides nodes marked as dev-only unless dev mode is enabled", + "hideSubgraph": "Hide Subgraph Nodes", + "hideSubgraphDescription": "Temporarily hides subgraph nodes from node library and search" } } diff --git a/src/stores/nodeDefStore.ts b/src/stores/nodeDefStore.ts index d8cd964736..02aa6df316 100644 --- a/src/stores/nodeDefStore.ts +++ b/src/stores/nodeDefStore.ts @@ -3,6 +3,7 @@ import _ from 'es-toolkit/compat' import { defineStore } from 'pinia' import { computed, ref, watchEffect } from 'vue' +import { t } from '@/i18n' import { isProxyWidget } from '@/core/graph/subgraph/proxyWidget' import { LiteGraph } from '@/lib/litegraph/src/litegraph' import type { LGraphNode } from '@/lib/litegraph/src/litegraph' @@ -428,25 +429,24 @@ export const useNodeDefStore = defineStore('nodeDef', () => { // Deprecated nodes filter registerNodeDefFilter({ id: 'core.deprecated', - name: 'Hide Deprecated Nodes', - description: 'Hides nodes marked as deprecated unless explicitly enabled', + name: t('nodeFilters.hideDeprecated'), + description: t('nodeFilters.hideDeprecatedDescription'), predicate: (nodeDef) => showDeprecated.value || !nodeDef.deprecated }) // Experimental nodes filter registerNodeDefFilter({ id: 'core.experimental', - name: 'Hide Experimental Nodes', - description: - 'Hides nodes marked as experimental unless explicitly enabled', + name: t('nodeFilters.hideExperimental'), + description: t('nodeFilters.hideExperimentalDescription'), predicate: (nodeDef) => showExperimental.value || !nodeDef.experimental }) // Dev-only nodes filter registerNodeDefFilter({ id: 'core.dev_only', - name: 'Hide Dev-Only Nodes', - description: 'Hides nodes marked as dev-only unless dev mode is enabled', + name: t('nodeFilters.hideDevOnly'), + description: t('nodeFilters.hideDevOnlyDescription'), predicate: (nodeDef) => showDevOnly.value || !nodeDef.dev_only }) @@ -454,9 +454,8 @@ export const useNodeDefStore = defineStore('nodeDef', () => { // Filter out litegraph typed subgraphs, saved blueprints are added in separately registerNodeDefFilter({ id: 'core.subgraph', - name: 'Hide Subgraph Nodes', - description: - 'Temporarily hides subgraph nodes from node library and search', + name: t('nodeFilters.hideSubgraph'), + description: t('nodeFilters.hideSubgraphDescription'), predicate: (nodeDef) => { // Hide subgraph nodes (identified by category='subgraph' and python_module='nodes') return !(