Skip to content

TransferList

Two filtered panes with move buttons. Check items on the left and add them to the chosen pane; remove moves them back. One hidden input per chosen value carries the form name for native submit.

Example

Tools

Pick the tools this project uses.

Available
Chosen
<TransferList
  id="tools"
  label="Tools"
  name="tools"
  available={[{ value: "git", label: "Git" }, { value: "figma", label: "Figma" }, { value: "docker", label: "Docker" }]}
  chosen={[]}
  hint="Pick the tools this project uses."
/>

Preselected

Editors

Candidates
Picked
<TransferList
  id="editors"
  label="Editors"
  name="editors"
  available={[{ value: "vim", label: "Vim" }, { value: "emacs", label: "Emacs" }]}
  chosen={[{ value: "vscode", label: "VS Code" }]}
  titles={["Candidates", "Picked"]}
/>

Props

PropTypeDefaultDescription
idstring-Required. Group label id prefix.
labelstring-Visible group title; names the move-action group.
namestringidHidden-input form name; one input per chosen value.
availableArray<string | { value; label; disabled? }>[]Items in the left pane.
chosenArray<string | { value; label; disabled? }>[]Items in the right pane; also the initial hidden inputs.
titles[string, string]["Available", "Chosen"]Pane legends; filters are named "Filter {title}".
hintstring-Help text below the title, linked via aria-describedby.
classstring-Style passthrough.

Behavior

Accessibility