Widgets/Storage

Field Value

Field Value

A "Storage" type widget. Field Value Widget allows widgets to read or set the value of a Custom Widget's setting field from within the custom widget. This enables dynamic interaction with Custom Widget settings during recipe editing, making it possible to create reactive workflows that respond to field changes or programmatically update field values.

The Field Value Widget must be placed inside a Custom Widget (widgetGroup) to function. It automatically finds the immediate parent Custom Widget and provides access to all available setting fields defined in that Custom Widget.

 

Inputs

  • read (DataType: Anything) When triggered, reads the current value of the selected field from the parent Custom Widget's settings and transmits it to the output port. The value transmitted will be the custom value if set, otherwise the default value of the field.

  • setValue (DataType: Anything) When triggered, sets the value of the selected field in the parent Custom Widget's settings. The incoming data value will be stored as the field's custom value, updating both the widget state and the associated variable in the Variables Manager.


Outputs

  • value (DataType: Anything) Outputs the current value of the selected field. The data type matches the field's type (which can be any type). When reading via the read input, this port transmits the field's current value. When reactive mode is enabled, this port automatically transmits whenever the field value changes.

Custom Settings

  • Field Name — Select which field from the parent Custom Widget to read or set. The dropdown displays all available setting fields defined in the parent Custom Widget. If no field is selected, the widget will not function.

  • Reactive Switch — When enabled, the widget automatically subscribes to changes in the selected field's value. Whenever the field value changes (for example, when a user updates it through the Custom Widget's settings UI), the widget will automatically transmit the new value to the value output port without requiring a trigger on the read input.


Configuration

 

Examples

Reactive Field Value from a Slider Setting

This example shows how the Field Value Widget reads a slider setting and updates the output automatically when that value changes.


Drag the example onto the workspace to explore and experiment!



In this example:

  1. The Slider Custom Widget defines a Range slider setting (Slider.slider1) with a current numeric value.

  2. The Field Value Widget inside the Slider Custom Widget is configured with Field Name set to Slider.slider1.

  3. With Reactive mode enabled, the Field Value Widget automatically transmits the updated value whenever the slider setting changes in the Slider Custom Widget.

  4. The Slider Custom Widget passes that value through its internal value output port.

  5. The Display Widget on the main canvas shows the current value coming from the slider field.

 

Set a Welcome Message from a Field Value

This example shows how the Field Value Widget can read one setting on a Custom Widget and set another field on that same widget, updating stored values from the internal recipe.


Drag the example onto the workspace to explore and experiment!



In this example:

  1. On the main canvas, the Welcome Message Custom Widget exposes two setting fields. Their variable names are name (single-line) and textarea (multiline welcome message).

  2. The name field can be edited directly in the Welcome Message Custom Widget UI. In this example, its current value is John.

  3. The Button Widget on the main canvas triggers the Welcome Message Custom Widget through its init input.

  4. Inside the Welcome Message Custom Widget, init triggers read on the Field Value Widget whose Field Name is name. That Field Name selection points to the Custom Widget setting with variable name name, so the widget reads the same stored value entered in the settings UI. The value output feeds the Template String Widget (template uses {{input.value}}), which generates a welcome message that includes the entered name.

  5. The second Field Value Widget with Field Name set to textarea receives the generated text through setValue. Because Field Name is textarea, it writes back to that configured setting field, updating the welcome message shown in the Welcome Message Custom Widget UI.

 

Reactive Field Monitoring

This example demonstrates how to read multiple setting fields from a Custom Widget and display them as a single combined object.


Drag the example onto the workspace to explore and experiment!



In this example:

  1. The Button Widget triggers the Font settings Custom Widget through its get input.

  2. The Font settings Custom Widget defines three setting fields with variable names name, size, and color (for example: Raleway, 16, #333).

  3. Inside the Font settings Custom Widget, the Sequence Widget triggers three Field Value Widgets to run read for name, size, and color (each selected via Field Name).

  4. The Object Widget combines the three read values into a single object, which is transmitted through the Font settings Custom Widget outer output.

  5. Back on the main canvas, the Object to Text Widget converts the object to JSON and the Text Widget displays it.

 

📌 Notes

  • The Field Value Widget must be placed inside a Custom Widget (widgetGroup) to function. If placed outside a Custom Widget, it will display a message indicating it's not inside a Custom Widget.
  • The Field Value Widget only has access to the immediate parent Custom Widget's fields, not fields from nested Custom Widgets.
  • When a field is not found (for example, if it was deleted from the Custom Widget), the widget will not produce any output.
  • The reactive mode subscribes to variable changes and will automatically transmit values when the field is updated by the parent Custom Widget.
  • When setting a field value, both the widget state and the variables manager are updated to keep them in sync.
  • The widget re-initializes when the field name changes to properly set up or update subscriptions.

 

Glossary

  • Custom Widget

    A user-defined widget created using the Widget Group that encapsulates complex workflows into reusable components. Access it by clicking on the workspace and selecting "Create Widget Group" to build custom widgets.

  • Setting Field

    A configurable input field defined in a Custom Widget that allows users to customize the widget's behavior. These fields can be of various types (text, number, boolean, etc.) and can have default values.

  • Reactive Mode

    A mode in the Field Value Widget that automatically transmits the field value whenever it changes, without requiring an explicit trigger on the read input port.

  • Variables Manager

    A system component that manages variable values across the recipe, ensuring consistency between widget states and variable references.