Conditional Property Types within Custom Widget Definitions

Hi,   I noticed in the new Combo box widget Mendix are somehow using conditional visibility on the input types depending on what you select, it will show different results.   I have looked through the mendix documentation and cannot see how they have done this.   Notice how the clearable hides when switched from Enumeration -> Boolean.     Additionally I converted the combox into a zip, looked at their source definition xml file and can not see anything here either.     Anyone know how its done? I feel like I'm missing something simple   Thanks Adam
1 answers

Hi Adam,

to conditionally show/hide properties, you need to define a getProperties function inside the editorConfig file.

You can find docs here:

And here how it's used for the Combo box:

web-widgets/packages/pluggableWidgets/combobox-web/src/Combobox.editorConfig.ts at main · mendix/web-widgets · GitHub


Hope this helps!