Select

Dropdown select field.

Usage

{{ partial "admin/widgets/select.js" $args }}

Parameters

ParameterTypeRequiredDescription
labelstringyesField label
namestringyesField name
optionsarray or objectyesAvailable options
defaultstringnoDefault selected value
dropdown_thresholdnumbernoUp to this number of options, Sveltia CMS shows radio buttons or checkboxes instead of a dropdown (default: 1)
hiddenbooleannoHide from the editor
hintstringnoHelp text
i18nboolean or stringnoi18n mode
label_optionsstring or mapnoi18n key prefix for option labels, or the labels themselves, keyed by option
multiplebooleannoAllow multiple selections
nameOverridestringnoOverride the name in output
requiredbooleannoMark as required
togglemapnoOption value → names of the sibling fields shown with it, the others being hidden (Decap and Sveltia CMS, single select only), see Fields that depend on another