The ValueList Option Modifier lets you hide, rename or disable individual options of a dropdown based on logic in the Grasshopper definition. You can use it to keep the dropdown limited to options that fit the rest of the configuration. A disabled option stays in the list with a message that tells the user why it can't be selected.

select-option-modifiers.gif

Example of option modifiers. In compact mode, Small is renamed to Tiny, Medium is disabled and Large is hidden.

👉 Try the example configurator live here: LINK

👉 Download the example Grasshopper definition at the bottom of the page, under Download the example definition.

How option modifiers work

Option modifiers are set up in three steps:

  1. Create an option modifier for each option you want to change.
  2. Connect the modifiers to an Update ValueList State component.
  3. Connect the update to a Modelup Output component.

Step 1: Create the option modifiers

Use the ValueList Option Modifier component (Modelup › Output). Options are addressed by their position in the ValueList: 0 is the first option, 1 the second, and so on.

Input Description
Indices (I) The positions of the options to change.
Visible (V) True shows the option, false hides it from the list.
Names (N) New display names for the options. Empty names are ignored.
Disabled (D) True keeps the option in the list but makes it impossible to select. False enables it again.
Disabled Reasons (R) The message shown to the user explaining why the option is disabled. Only used when Disabled is true.

All inputs except Indices are optional. Each one takes a single value, applied to every index, or one value per index. An input you leave empty doesn't change that property.

The Option Modifiers (O) output goes to Update ValueList State.

Step 2: Connect the modifiers to Update ValueList State

Step 3: Connect the update to the output