Closed YooSunYoung closed 3 months ago
I saw this before but didn't understand it. What is a switchable widget? When is it used?
I saw this before but didn't understand it. What is a switchable widget? When is it used?
@jokasimr
Switchable
widget is when you don't want to set the parameter at all in the workflow
and
Optional
widget is when you want to set it as None
.
It's handled by the attributes of Parameter
object, switchable
and optional
.
Maybe I should add this information in the developer's gui page...
I saw this before but didn't understand it. What is a switchable widget? When is it used?
TL;DR: When you have a parameter param: SomeType | None
(aka Optional[SomeType]
).
TL;DR: When you have a parameter param: SomeType | None (aka Optional[SomeType]).
From @YooSunYoung s explanation that sounds more like an optional widget.
I added the explanation in the developers document
Instead of making switchable widgets, maybe we should just add a long multiple-select widget containing all domain types (parameters) in the workflow. When you select some of them, they show up in the ParameterBox
widget and you can assign their values. When you select a set of outputs, the multiple select list of parameters selects the required parameters to produce the outputs.
This would help by
@jokasimr I created a separate issue regarding your suggestion. #74
Fixes #71
I don't like how it looks but it works...
Optional
Switchable & Optional
https://github.com/user-attachments/assets/0e26b649-5f4e-461e-acb7-015f65d78065