Atoms
Menu command
Command rows for a menu popup: icon · label · description · trailing status. MenuCommand wires a trigger to the popup; MenuCommandList uses the shared Command components for searchable, keyboard-accessible rows.
Usage
import { MenuCommand } from "@exegia/corpora-ui"
<MenuCommand
items={[
{
id: "web",
label: "Web search",
description: "Real-time news",
icon: <Globe />,
trailing: "Connected",
},
]}
onSelect={run}
>
<Button size="icon-lg" aria-label="Attach">
+
</Button>
</MenuCommand>API reference
| Prop | Type | Default | Description |
|---|---|---|---|
| items (required) | IMenuCommandItem[] | — | { id, label, description?, icon?, trailing?, href?, disabled?, onSelect? }. |
| onSelect | (item) => void | — | Fires after the row's own onSelect. |
| side / align | Positioner side / align | "top" / "start" | MenuCommand only. |
Last updated on