components

CommandInput

A terminal-style prompt row: a → caret, one text field, and a footer for session context on the left and key hints on the right. It is a single-line field that submits on Enter — for multi-line or labelled form input use Input or Textarea.

tsx
<CommandInput label="Follow-up" placeholder="Add a follow-up" />
label
placeholder

Accessibility

There is no visible label, so label is required and becomes the field's accessible name. The → glyph is decorative. Enter submits; Shift+Enter and IME composition do not.

Examples

tsx
<CommandInput
  label="Follow-up"
  placeholder="Add a follow-up"
  status="amelia · 23% context used"
  hint="/ for commands"
  onSubmit={(text) => send(text)}
/>

Props

PropTypeDefaultDescription
defaultValuetext——
disabledboolean——
hintreadonly—Right footer line — key hints, e.g. `"/ for commands"`.
label *text—Required: the field has no visible label, so it needs an accessible name.
onChangereadonly——
onSubmitreadonly—Fired on Enter (not Shift+Enter) with the current text.
placeholdertext——
promptreadonly—Leading glyph before the caret. Defaults to `→`.
statusreadonly—Left footer line — session context, e.g. `"amelia · 23% context used"`.
valuetext——