Skip to content

Command Palette Item

@astryxdesign/core v0.7.1 · CommandPaletteItem

Props ​

PropTypeDefaultDescription
valuestring—Identity of the row. Keep it unique in the list: highlight, active-descendant, and selection all resolve through it. Required.
isDisabledbooleanfalseBlocks selection and drops the row out of the keyboard order. Sets aria-disabled.
isHighlightedbooleanfalseWhether this row is the active keyboard result. When omitted, the row reads the state of the surrounding CommandPalette. Pass it explicitly for a standalone preview.
isSelectedbooleanfalseWhether this row holds the selected value in picker mode. When omitted, the row compares value with the palette's v-model:value. Sets aria-selected.

Events ​

  • select(value: string): the row was activated by pointer, Enter, or Space. Inside a CommandPalette the palette then writes the value and closes.

Slots ​

  • default: the row content. Keep it non-interactive; put icons, text, and shortcut hints here, not buttons or links.