Skip to content

gui.inputs reference

Every input shortcut takes a path string and an optional props object. The props object inherits the widget’s typed WidgetProps, plus the DX-specific props (label, disabled, readonly, validator, defaultValue, uid, tags, size, states, include, exclude, onChange, onLoad, onFilter, onBlur).

When label (and placeholder, for inputs that accept one) is omitted, the engine derives one from pathgui.inputs.textInput('firstName') renders with the label First Name. See Sensible defaults / Auto-label for the exact transform, how to override, and how to suppress.

gui.inputs.<shortcut>(path: string, props?: Props, tags?: string[]): GuiInputsShortcut;

A fully-populated example, exercising most fields you’ll reach for:

gui.inputs.textInput(
'user.email', // path — where the value lives in the form data
{
// props — the widget's typed props + DX fields
label: 'Email',
placeholder: 'you@example.com',
hint: 'We never share your email.',
disabled: false,
readonly: false,
autocomplete: 'email',
defaultValue: '',
validator: {
required: true,
format: 'email',
messages: {
required: 'Email is required',
format: 'Enter a valid email',
},
},
onChange: 'emailChanged', // wire a named event the form's `formEvent` callback receives
states: {
// per-state prop overrides — see /form-definition/states/
registerMode: { label: 'Choose a sign-up email' },
},
include: { in: ['needsEmail'] },
},
['identity'], // tags — addressable groups for selectors
);

Most shortcuts also accept a runtime-function variant for any individual prop — see Runtime Functions. For per-widget required props (e.g. dropdown’s items, repeater’s template), see the matching page in the Widgets Reference.

ShortcutRendersReference
gui.inputs.textInputtext inputTextinput
gui.inputs.numberInputnumber inputNumber Input
gui.inputs.booleanInputtoggleToggle
gui.inputs.passwordpassword inputPassword
gui.inputs.currencycurrency inputCurrency
gui.inputs.checkboxcheckboxCheckbox
gui.inputs.radiogroupradio groupRadio Group
gui.inputs.selectselectSelect
gui.inputs.dropdowndropdown (autocomplete)Dropdown
gui.inputs.listscrolling listList
gui.inputs.tagstags input (removable chips)Tags
gui.inputs.textareamulti-line textTextarea
gui.inputs.markdownmarkdown editorMarkdown
gui.inputs.calendarinline calendarCalendar
gui.inputs.dateInputdate input (typed)Date Input
gui.inputs.datePickerdate picker (popover calendar)Date Picker
gui.inputs.rangeCalendarrange calendarRange Calendar
gui.inputs.rangeDateInputtyped date rangeRange Date Input
gui.inputs.rangeDatePickerpopover date rangeRange Date Picker
gui.inputs.repeaterrepeaterRepeater
gui.inputs.customyour custom inputCustom Widgets

For each widget, refer to the matching reference page for the full prop list and live demos.