Skip to content

Cascader

Drill through nested levels to pick one value. Top-level items expand a column to the right; picking a leaf shows the joined path on the trigger and stores the leaf value in a hidden input.

Example

<Cascader
  id="location"
  label="Location"
  name="location"
  options={[
    { value: "europe", label: "Europe", children: [
      { value: "berlin", label: "Berlin" },
      { value: "paris", label: "Paris" },
    ] },
    { value: "asia", label: "Asia", children: [
      { value: "tokyo", label: "Tokyo" },
    ] },
  ]}
/>

Preselected path

<Cascader
  id="hq"
  label="Headquarters"
  name="hq"
  options={…}
  value={["asia", "tokyo"]}
/>

Select any level

By default only leaves select (selectAny isfalse): activating a branch expands it. WithselectAny, any node picks its own value instead.

<Cascader
  id="region"
  label="Region"
  name="region"
  options={…}
  selectAny
/>

Error state

Choose an office location.

<Cascader
  id="office"
  label="Office"
  name="office"
  options={…}
  error="Choose an office location."
/>

Props

PropTypeDefaultDescription
idstring-Required. Names Field/panel/message ids (trigger itself carries no id).
labelstring-Visible label; kept in the trigger name and panel name.
namestringidHidden-input form name; carries the leaf value.
optionsCascadeOption[] ({ value; label; disabled?; children? })-Nested levels; branches expand, leaves select.
valuestring[][]Preselected value path; unknown values select nothing.
selectAnybooleanfalseAny node selects; otherwise only leaves select.
placeholderstring"Select …"Empty-state trigger text; defaults to the lowercased label.
hintstring-Help text below the trigger.
errorstring-Error message; sets aria-invalid on the trigger.
requiredbooleanfalseMarks the label required.
disabledbooleanfalseNon-interactive; trigger cannot open.
classstring-Style passthrough.

Accessibility