Comfy-Org / Comfy-Org/ComfyUI_frontend
[Feature Request]: Allow for primitive types to be widgets on subgraph nodes
- Dominant language
- TypeScript
- Stars
- 2k
- Forks
- 699
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 490
Description
### Current Progress (close when all are ticked)
- [x] Widgets are added and fully functional (solved with #4429)
- [x] #4399
- [x] #4431 (solved with #4433)
- [ ] Seed widgets spawn the `control_after_generate` widget
### Is there an existing issue for this?
- [x] I have searched the existing issues and checked the recent builds/commits
### What would your feature do ?
Subgraphs are intended to be the successor to Group Nodes, but let's take a look back at group nodes for a second:

From this combination of a KSampler and a VAE decode, we can see that we have all the widgets we need for the KSampler, giving us a convenient node that outputs an image after taking in a latent and sampling it.
However, let's take a look at how this same thing would look in a subgraph:

Well, now if we want to modify the parameters of the KSampler, we would have to go into the subgraph. Even if we were to tie one of the inputs to the subgraph's input:

The int input for the step count is forced to be an input. We can see here that we have a problem: subgraphs are in some ways less convenient than group nodes because they lack these widgets. And in order to make them just as convenient, and more convenient due to easier node modification, we should allow for the user to choose which values to be a widget.
### Proposed workflow
1. Detect which input parameters on a subgraph are the five primitive types (bool, int, float, string, combo)
2. Allow the user to right click on the subgraph and choose which one of these inputs to turn into a widget on the subgraph node
### Additional information
_No response_
┆Issue is synchronized with this [Notion page](https://www.notion.so/Issue-4189-Feature-Request-Allow-for-primitive-types-to-be-widgets-on-subgraph-nodes-2136d73d365081228209c4d4bacf7da7) by [Unito](https://www.unito.io)
Contributor guide
Assessment
This issue has not been assessed yet.