Skip to content

Command Palette Input

@astryxdesign/core v0.7.1 · CommandPaletteInput

Props ​

PropTypeDefaultDescription
placeholderstringSearch…Grey placeholder in the field.
labelstringLocalized "Search commands"Accessible name of the field. Defaults to a localized "Search commands" (not the placeholder); pass it when the palette searches something else.
hasAutoFocusbooleantrueFocus the field when it mounts. A palette that renders inline skips this, so opening a docs preview does not steal focus.
valuestring—Search text. Bind with v-model:value. When omitted, the field reads and writes the search text of the surrounding CommandPalette.

Events ​

  • update:value(value: string): the next search text. Fired only while value is bound.
  • valueChange(value: string): the same value under the original callback name, for code ported from React.

Slots ​

  • end: content after the field, such as a clear button or a Kbd shortcut hint. The spinner sits in front of it.
  • endContent: the same slot under the original name. end wins when both are passed.