Skip to main content

Fields

The fields cover text entry, choices, filesystem browsing and gates. Every field of the form opens its editor in place, and the same fields also run standalone (see playground/02-fields-*). Fields pull their glyphs and colors from the theme, so each one is shown in all four display modes.

Themes names every piece a field draws in both of its modes - the label, the value, the entries, the caret - and gives the theme element behind each one.

All fields, one after anotherAll fields, one after another

Text entry

  • Calendar - a month calendar returning an ISO date.
  • Number - integer input with optional bounds and step keys.
  • Password - masked input with optional reveal and confirm.
  • Template - fill the named slots of a fixed shape.
  • Text - single-line input, with optional ghost-text autocomplete.
  • Textarea - multi-line input with optional external-editor handoff.

Choices

  • Option groups - headings, separators and disabled options.
  • Rating - a graded answer picked from a scale of points.
  • Reorder - rank a list by moving items into order.
  • Search - single or multiple choice with a filter line.
  • Select - single or multiple choice from a list.
  • Suggest - free text with autocomplete over a fixed set.

Filesystem

  • FilePicker - browse for one path, or several with ->multiple().

Toggles and gates

  • Confirm - a Yes/No toggle.
  • Pause - an acknowledgment gate.
  • Toggle - an inline switch between two labeled values.

Rows that collect nothing

Fifteen kinds of field exist, and those are all of them - every one above collects an answer. Two other blocks are declared in a panel the same way and reach no answer at all:

  • Markup - content: prose, a bordered card or an aligned table, one block drawn three ways.
  • Progress row - a row that runs work when you activate it, showing a bar or a spinner while it runs.