CommandPalette API
import { CommandPalette } from '@editora/ui-react';
Props
| Prop | Type | Description |
|---|---|---|
emptyText | string | |
headless | boolean | |
onClose | () => void | |
onOpen | () => void | |
onOpenChange | (detail: CommandPaletteOpenChangeDetail) => void | |
onQueryChange | (detail: CommandPaletteQueryChangeDetail) => void | |
onSelect | (detail: CommandPaletteSelectDetail) => void | |
open | boolean | |
placeholder | string | |
query | string |
Also accepts the standard HTML and React props of the element it renders (className, style, id, aria-*, data-*, event handlers).
CommandPalette.Item props
| Prop | Type | Description |
|---|---|---|
keywords | string | |
label | string | |
value | string |
Also accepts the standard HTML and React props of the element it renders (className, style, id, aria-*, data-*, event handlers).
Element: <ui-command-palette>
CommandPalette renders the ui-command-palette custom element from @editora/ui-core, which can also be used without React.
Attributes: empty-text, headless, open, placeholder, query