--- ## CommandPalette Keyboard-driven command palette with search, grouped results, and arrow-key navigation. Composes Dialog + search input into a ready-to-use overlay. Open via bind:open or the built-in Cmd+K shortcut. A row is a command, or with `kind: 'info'` a line of information the keyboard passes over; the footer's key hints are drawn with `Kbd` and can be replaced through the `footer` snippet. **Import:** `import { CommandPalette } from '@urbicon-ui/blocks';` ### Examples ```svelte handleCommand(item)} placeholder="Type a command..." /> ``` ```svelte runAction(item.id)} size="md" showFooter /> ``` ### Variants - size: lg, md, sm (default: md) ### Api | Prop | Type | Required | Default | Description | | --- | --- | :---: | --- | --- | | items | `CommandPaletteItem[]` | yes | | Items to display. Grouped automatically by `category`. | | ...HTMLDialogAttributes | `HTMLAttributes` | no | | HTML attributes (excluding: 'children' | 'open' | 'title' | 'draggable') | | class | `string` | no | | Additional CSS classes on the root wrapper. In the same Tailwind bucket `class` wins over the `slotClasses` entry for the element it lands on. Presets and provider defaults sit below both. | | customEmpty | `Snippet<[query: string]>` | no | | Custom empty-state renderer. Receives the current query string. | | customItem | `Snippet<[item: CommandPaletteItem, highlighted: boolean, index: number, select: () => void]>` | no | | Replace the default per-row rendering. Receives the item, whether its row is highlighted, the item's flat index into the filtered list, and a `select` callback (call it to run the same selection the row's click runs; it is a no-op on a disabled item and on an `info` row). It draws `info` rows too: `highlighted` is always `false` for them. **Render visible content only — nothing focusable, nothing interactive.** A `