From 4bd77be082948068b5ac374c0152a5779853d3bb Mon Sep 17 00:00:00 2001 From: tritant Date: Tue, 23 Sep 2025 07:53:21 +0200 Subject: [PATCH] Add files via upload --- __init__.py | 8 ++++++++ orchestrator.py | 21 +++++++++++++++++++++ 2 files changed, 29 insertions(+) create mode 100644 __init__.py create mode 100644 orchestrator.py diff --git a/__init__.py b/__init__.py new file mode 100644 index 0000000..08b355f --- /dev/null +++ b/__init__.py @@ -0,0 +1,8 @@ +# Importe les dictionnaires nécessaires depuis notre fichier de logique +from .orchestrator import NODE_CLASS_MAPPINGS, NODE_DISPLAY_NAME_MAPPINGS + +# Spécifie que les fichiers web (JS, CSS) se trouvent dans le sous-dossier "js" +WEB_DIRECTORY = "./js" + +# Rend les mappings accessibles à ComfyUI +__all__ = ["NODE_CLASS_MAPPINGS", "NODE_DISPLAY_NAME_MAPPINGS"] \ No newline at end of file diff --git a/orchestrator.py b/orchestrator.py new file mode 100644 index 0000000..200fa72 --- /dev/null +++ b/orchestrator.py @@ -0,0 +1,21 @@ +class OrchestratorNode: + NAME = "OrchestratorNode" + DISPLAY_NAME = "Orchestrator (Workflow Switch)" + FUNCTION = "do_nothing" + CATEGORY = "Logic" + + @classmethod + def INPUT_TYPES(cls): + # Le widget est maintenant 100% géré par le JavaScript. + return { "required": {} } + + RETURN_TYPES = () + OUTPUT_NODE = True + + # La fonction n'a plus besoin d'argument. + def do_nothing(self): + return () + +# Ces dictionnaires restent inchangés +NODE_CLASS_MAPPINGS = { OrchestratorNode.NAME: OrchestratorNode } +NODE_DISPLAY_NAME_MAPPINGS = { OrchestratorNode.NAME: OrchestratorNode.DISPLAY_NAME } \ No newline at end of file