sdfxai / sdfx

The ultimate no-code platform to build and share AI apps with beautiful UI.
https://sdfx.ai
GNU Affero General Public License v3.0
396 stars 25 forks source link

Issues with widgetNames in UI #16

Open morgan55555 opened 5 months ago

morgan55555 commented 5 months ago

There is too much cloned defaults in widgetDefaults.ts, but it always will be not enough for endless custom nodes for ComfyUI. And if we change widgetNames to another (not from our node widget) - this will break correct widget loading in UI (tried with KSampler Config (rgthree), which has field "steps_total", if widgetNames is just "steps" - widget will show default value instead of real node value. If widgetNames is "steps_total" - there is no default/step/min/max values.)

Better solution will be using only widgetIdxs, remove all widgetNames and change it to widgetTypes (e.g. steps, cfg, etc...), which can be used for any selected widgetIdxs.

Also, sometimes may be need to set custom widget parameters instead of its type (min/max/step).

morgan55555 commented 4 months ago

Also, another problem with widgetNames: if childrin using same nodeId and widgetNames, it's values will be same.