Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 68 additions & 0 deletions docs/admin/nodes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# Admin Node Management Dashboard

## Overview

Administrative interface for managing nodes in the ComfyUI Registry.

## Implementation Tasks

### Completed

- [x] Created documentation structure
- [x] Set up project development environment
- [x] Create /admin/nodes page structure
- [x] Implement node listing table with pagination
- [x] Add node filtering capabilities by status
- [x] Create node edit modal
- [x] Add table columns:
- Node (Name + @nodeId)
- Publisher (name + publisherId)
- Categories
- Tags
- Node status
- Actions (edit button)
- [x] Implement node admin edit modal
- [x] Add save functionality with ctrl+enter
- [x] Test pagination and filters
- [x] Validate edit operations
- [x] Add search functionality by node ID or name
- [x] Add status filtering (All, Active, Banned, Deleted)

### Implementation Details

- Built following the pattern from `/admin/nodeversions` page
- Uses `useListAllNodes` API for fetching nodes with pagination
- Uses `useUpdateNode` API for updating node tags and categories
- Includes client-side filtering for status and search
- Responsive table layout with proper styling
- Modal edit interface with keyboard shortcuts (Ctrl+Enter to save)

## API Endpoints Used

- `useListAllNodes` - Fetch nodes with pagination and filters
- `useUpdateNode` - Update node tags and categories (requires publisherId)

## Technical Notes

- Following pattern from `/admin/nodeversions` page
- Using Flowbite React components for UI consistency
- Node interface includes: id, category, tags, status, publisher, etc.
- NodeStatus enum: Active, Deleted, Banned
- Client-side filtering for better user experience
- Proper error handling and loading states

## Files Modified

- `/pages/admin/nodes.tsx` - Main admin node management page
- `/pages/admin/index.tsx` - Added link to new admin nodes page
- `/docs/admin/nodes.md` - This documentation file

## Screenshots

The implementation includes:

1. A comprehensive table view showing all nodes with their details
2. Status filtering buttons (All, Active, Banned, Deleted)
3. Search functionality by node ID or name
4. Edit modal for modifying tags and categories
5. Keyboard shortcuts for efficient editing
16 changes: 16 additions & 0 deletions locales/en/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,21 +108,26 @@
"Edit Publisher": "Edit Publisher",
"Edit Search Ranking": "Edit Search Ranking",
"Edit details": "Edit details",
"Edit node": "Edit node",
"Edit secret key": "Edit secret key",
"Edit unclaimed node": "Edit unclaimed node",
"Enter category": "Enter category",
"Enter one OS per line": "Enter one OS per line",
"Enter one accelerator per line": "Enter one accelerator per line",
"Enter supported ComfyUI frontend version": "Enter supported ComfyUI frontend version",
"Enter supported ComfyUI version": "Enter supported ComfyUI version",
"Enter tags separated by commas": "Enter tags separated by commas",
"Error": "Error",
"Error Loading Unclaimed Nodes": "Error Loading Unclaimed Nodes",
"Error getting node versions": "Error getting node versions",
"Error getting node {{id}} repository": "Error getting node {{id}} repository",
"Error getting nodes": "Error getting nodes",
"Error loading node details": "Error loading node details",
"Error loading node versions": "Error loading node versions",
"Error loading nodes. Please try again later.": "Error loading nodes. Please try again later.",
"Error reviewing node version": "Error reviewing node version",
"Error undoing node version": "Error undoing node version",
"Error updating node": "Error updating node",
"Failed to claim node. {{error}}": "Failed to claim node. {{error}}",
"Failed to create node": "Failed to create node",
"Failed to create node. {{message}}": "Failed to create node. {{message}}",
Expand Down Expand Up @@ -168,6 +173,7 @@
"Login": "Login",
"Logout": "Logout",
"MEMBERS": "MEMBERS",
"Manage Nodes": "Manage Nodes",
"Manage Unclaimed Nodes": "Manage Unclaimed Nodes",
"More": "More",
"Most recent version": "Most recent version",
Expand All @@ -178,6 +184,7 @@
"No batch ID found for {{id}}@{{version}}": "No batch ID found for {{id}}@{{version}}",
"No nodes found": "No nodes found",
"No preempted comfy node names added yet": "No preempted comfy node names added yet",
"No publisher information available": "No publisher information available",
"No publishers found": "No publishers found",
"No repository URL available for this node": "No repository URL available for this node",
"No status history found for {{id}}@{{version}}": "No status history found for {{id}}@{{version}}",
Expand All @@ -189,6 +196,7 @@
"Node ID is required": "Node ID is required",
"Node ID is required for claiming.": "Node ID is required for claiming.",
"Node Information": "Node Information",
"Node Management": "Node Management",
"Node Version": "Node Version",
"Node Version Compatibility": "Node Version Compatibility",
"Node Version Compatibility Admin": "Node Version Compatibility Admin",
Expand All @@ -203,6 +211,7 @@
"Node updated successfully": "Node updated successfully",
"Node version {{key}} not found": "Node version {{key}} not found",
"Node {{name}} successfully claimed by {{publisherName}}": "Node {{name}} successfully claimed by {{publisherName}}",
"Nodes": "Nodes",
"Nodes List": "Nodes List",
"None": "None",
"Note": "Note",
Expand All @@ -224,6 +233,7 @@
"Preempted Comfy Node Names: List of names that should be treated as the same comfy-node. This helps maintain consistent search results across differently named nodes.": "Preempted Comfy Node Names: List of names that should be treated as the same comfy-node. This helps maintain consistent search results across differently named nodes.",
"Preempted Names": "Preempted Names",
"Preempted comfy node names updated successfully": "Preempted comfy node names updated successfully",
"Press Ctrl+Enter to save": "Press Ctrl+Enter to save",
"Previous": "Previous",
"Processing verification result...": "Processing verification result...",
"Publisher": "Publisher",
Expand All @@ -247,6 +257,7 @@
"Repository {{owner}}/{{repo}} not found or you do not have access to it.": "Repository {{owner}}/{{repo}} not found or you do not have access to it.",
"Review Node Versions": "Review Node Versions",
"SVG, PNG, JPG or GIF (MAX. 800x400px)": "SVG, PNG, JPG or GIF (MAX. 800x400px)",
"Save": "Save",
"Save Changes": "Save Changes",
"Save your key": "Save your key",
"Saving...": "Saving...",
Expand All @@ -257,6 +268,7 @@
"Search Ranking Table": "Search Ranking Table",
"Search Ranking: integer from 1 to 10. Lower number means higher search ranking, all else equal.": "Search Ranking: integer from 1 to 10. Lower number means higher search ranking, all else equal.",
"Search by Reason": "Search by Reason",
"Search by node ID or name": "Search by node ID or name",
"Search by nodes or publisher": "Search by nodes or publisher",
"Search nodes by name or ID": "Search nodes by name or ID",
"Search publishers...": "Search publishers...",
Expand All @@ -273,13 +285,15 @@
"Signup": "Signup",
"Sort by popularity": "Sort by popularity",
"Specification Reference:": "Specification Reference:",
"Status": "Status",
"Step 1: Confirm Node Information": "Step 1: Confirm Node Information",
"Step 2: GitHub Authentication": "Step 2: GitHub Authentication",
"Step 3: Verifying Repository Admin Access": "Step 3: Verifying Repository Admin Access",
"Step 4: Claim Your Node": "Step 4: Claim Your Node",
"Step 5: Claim Successful": "Step 5: Claim Successful",
"Supported Accelerators": "Supported Accelerators",
"Supported Operating Systems": "Supported Operating Systems",
"Tags": "Tags",
"There was an error loading the nodes. Please try again later.": "There was an error loading the nodes. Please try again later.",
"There was an unexpected error verifying your repository permissions. Please try again.": "There was an unexpected error verifying your repository permissions. Please try again.",
"These nodes are not claimed by any publisher. They can be claimed by publishers or edited by administrators.": "These nodes are not claimed by any publisher. They can be claimed by publishers or edited by administrators.",
Expand All @@ -301,6 +315,7 @@
"Type": "Type",
"Unable to claim the node. Please verify your GitHub repository ownership and try again.": "Unable to claim the node. Please verify your GitHub repository ownership and try again.",
"Unable to get user email, please reload and try again": "Unable to get user email, please reload and try again",
"Unable to save: missing node or publisher information": "Unable to save: missing node or publisher information",
"Unable to verify repository permissions. Please try again.": "Unable to verify repository permissions. Please try again.",
"Unclaimed": "Unclaimed",
"Unclaimed Nodes": "Unclaimed Nodes",
Expand Down Expand Up @@ -346,6 +361,7 @@
"Your nodes": "Your nodes",
"approve": "approve",
"at": "at",
"comma separated": "comma separated",
"downloads": "downloads",
"e.g.\\nCUDA\\nROCm\\nMetal\\nCPU": "e.g.\\nCUDA\\nROCm\\nMetal\\nCPU",
"e.g.\\nWindows\\nmacOS\\nLinux": "e.g.\\nWindows\\nmacOS\\nLinux",
Expand Down
16 changes: 16 additions & 0 deletions locales/es/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,21 +108,26 @@
"Edit Publisher": "Editar Editor",
"Edit Search Ranking": "Editar Clasificación de Búsqueda",
"Edit details": "Editar detalles",
"Edit node": "Editar nodo",
"Edit secret key": "Editar clave secreta",
"Edit unclaimed node": "Editar nodo no reclamado",
"Enter category": "Ingrese categoría",
"Enter one OS per line": "Ingrese un sistema operativo por línea",
"Enter one accelerator per line": "Ingrese un acelerador por línea",
"Enter supported ComfyUI frontend version": "Ingrese la versión del frontend de ComfyUI compatible",
"Enter supported ComfyUI version": "Ingrese la versión de ComfyUI compatible",
"Enter tags separated by commas": "Ingrese etiquetas separadas por comas",
"Error": "Error",
"Error Loading Unclaimed Nodes": "Error al cargar los nodos no reclamados",
"Error getting node versions": "Error al obtener las versiones del nodo",
"Error getting node {{id}} repository": "Error al obtener el repositorio del nodo {{id}}",
"Error getting nodes": "Error al obtener los nodos",
"Error loading node details": "Error al cargar los detalles del nodo",
"Error loading node versions": "Error al cargar las versiones de nodos",
"Error loading nodes. Please try again later.": "Error al cargar los nodos. Por favor, inténtelo de nuevo más tarde.",
"Error reviewing node version": "Error al revisar la versión del nodo",
"Error undoing node version": "Error al deshacer la versión del nodo",
"Error updating node": "Error al actualizar el nodo",
"Failed to claim node. {{error}}": "No se pudo reclamar el nodo. {{error}}",
"Failed to create node": "Error al crear el nodo",
"Failed to create node. {{message}}": "No se pudo crear el nodo. {{message}}",
Expand Down Expand Up @@ -168,6 +173,7 @@
"Login": "Iniciar sesión",
"Logout": "Cerrar sesión",
"MEMBERS": "MIEMBROS",
"Manage Nodes": "Gestionar nodos",
"Manage Unclaimed Nodes": "Gestionar nodos no reclamados",
"More": "Más",
"Most recent version": "Versión más reciente",
Expand All @@ -178,6 +184,7 @@
"No batch ID found for {{id}}@{{version}}": "No se encontró ID de lote para {{id}}@{{version}}",
"No nodes found": "No se encontraron nodos",
"No preempted comfy node names added yet": "Aún no se han agregado nombres de nodos cómodos anticipados",
"No publisher information available": "No hay información de editor disponible",
"No publishers found": "No se encontraron editores",
"No repository URL available for this node": "No hay URL de repositorio disponible para este nodo",
"No status history found for {{id}}@{{version}}": "No se encontró el historial de estado para {{id}}@{{version}}",
Expand All @@ -189,6 +196,7 @@
"Node ID is required": "Se requiere ID de nodo",
"Node ID is required for claiming.": "需要节点ID进行认领。",
"Node Information": "Información del Nodo",
"Node Management": "Gestión de nodos",
"Node Version": "Versión de Nodo",
"Node Version Compatibility": "Compatibilidad de Versión de Nodo",
"Node Version Compatibility Admin": "Administrador de Compatibilidad de Versión de Nodo",
Expand All @@ -203,6 +211,7 @@
"Node updated successfully": "Nodo actualizado con éxito",
"Node version {{key}} not found": "No se encontró la versión del nodo {{key}}",
"Node {{name}} successfully claimed by {{publisherName}}": "Nodo {{name}} reclamado exitosamente por {{publisherName}}",
"Nodes": "Nodos",
"Nodes List": "Lista de Nodos",
"None": "Ninguno",
"Note": "Nota",
Expand All @@ -224,6 +233,7 @@
"Preempted Comfy Node Names: List of names that should be treated as the same comfy-node. This helps maintain consistent search results across differently named nodes.": "Nombres de nodos Comfy preemtidos: lista de nombres que deben tratarse como el mismo nodo cómodo. Esto ayuda a mantener resultados de búsqueda consistentes en nodos con diferentes nombres.",
"Preempted Names": "Nombres Preemptivos",
"Preempted comfy node names updated successfully": "Los nombres de los nodos cómodos preasignados se han actualizado correctamente",
"Press Ctrl+Enter to save": "Presione Ctrl+Enter para guardar",
"Previous": "Anterior",
"Processing verification result...": "Procesando el resultado de la verificación...",
"Publisher": "Editor",
Expand All @@ -247,6 +257,7 @@
"Repository {{owner}}/{{repo}} not found or you do not have access to it.": "Repositorio {{owner}}/{{repo}} no encontrado o no tienes acceso a él.",
"Review Node Versions": "Revisar versiones de nodos",
"SVG, PNG, JPG or GIF (MAX. 800x400px)": "SVG, PNG, JPG o GIF (MÁX. 800x400px)",
"Save": "Guardar",
"Save Changes": "Guardar Cambios",
"Save your key": "Guarda tu clave",
"Saving...": "Guardando...",
Expand All @@ -257,6 +268,7 @@
"Search Ranking Table": "Tabla de Clasificación de Búsqueda",
"Search Ranking: integer from 1 to 10. Lower number means higher search ranking, all else equal.": "Clasificación de búsqueda: entero de 1 a 10. Un número más bajo significa una clasificación de búsqueda más alta, todo lo demás igual.",
"Search by Reason": "Buscar por motivo",
"Search by node ID or name": "Buscar por ID de nodo o nombre",
"Search by nodes or publisher": "Buscar por nodos o editor",
"Search nodes by name or ID": "Busca nodos por nombre o ID",
"Search publishers...": "Buscar editores...",
Expand All @@ -273,13 +285,15 @@
"Signup": "Registrarse",
"Sort by popularity": "Ordenar por popularidad",
"Specification Reference:": "Especificación de referencia:",
"Status": "Estado",
"Step 1: Confirm Node Information": "Paso 1: Confirmar Información del Nodo",
"Step 2: GitHub Authentication": "Paso 2: Autenticación de GitHub",
"Step 3: Verifying Repository Admin Access": "Paso 3: Verificación del Acceso de Administrador del Repositorio",
"Step 4: Claim Your Node": "Paso 4: Reclama tu nodo",
"Step 5: Claim Successful": "Paso 5: Reclamo exitoso",
"Supported Accelerators": "Aceleradores compatibles",
"Supported Operating Systems": "Sistemas Operativos Compatibles",
"Tags": "Etiquetas",
"There was an error loading the nodes. Please try again later.": "Hubo un error al cargar los nodos. Por favor, inténtelo de nuevo más tarde.",
"There was an unexpected error verifying your repository permissions. Please try again.": "Hubo un error inesperado al verificar los permisos de su repositorio. Por favor, inténtelo de nuevo.",
"These nodes are not claimed by any publisher. They can be claimed by publishers or edited by administrators.": "Estos nodos no han sido reclamados por ningún editor. Pueden ser reclamados por los editores o editados por los administradores.",
Expand All @@ -301,6 +315,7 @@
"Type": "Tipo",
"Unable to claim the node. Please verify your GitHub repository ownership and try again.": "No se puede reclamar el nodo. Por favor verifique la propiedad de su repositorio de GitHub y vuelva a intentarlo.",
"Unable to get user email, please reload and try again": "No se puede obtener el correo electrónico del usuario, por favor recargue e intente de nuevo",
"Unable to save: missing node or publisher information": "No se puede guardar: falta información del nodo o del editor",
"Unable to verify repository permissions. Please try again.": "无法验证仓库权限。请再试一次。",
"Unclaimed": "No reclamado",
"Unclaimed Nodes": "Nodos no reclamados",
Expand Down Expand Up @@ -346,6 +361,7 @@
"Your nodes": "Tus nodos",
"approve": "aprobar",
"at": "en",
"comma separated": "separado por comas",
"downloads": "descargas",
"e.g.\\nCUDA\\nROCm\\nMetal\\nCPU": "p. ej.\\nCUDA\\nROCm\\nMetal\\nCPU",
"e.g.\\nWindows\\nmacOS\\nLinux": "p. ej.\\nWindows\\nmacOS\\nLinux",
Expand Down
Loading