SuggestionItem API
API reference docs for the React SuggestionItem component. Learn about the props, CSS, and other APIs of this exported module.
Demos
Import
import { SuggestionItem } from '@mui/x-chat-headless/suggestions';
// or
import { SuggestionItem } from '@mui/x-chat-headless';
// or
import { SuggestionItem } from '@mui/x-chat';Learn about the difference by reading this guide on minimizing bundle size.
| Name | Type | Description |
|---|---|---|
| value* | string | The value to pre-fill into the composer when the suggestion is clicked. |
| index | number | The index of this item within the suggestions list. |
| label | string | Display label. Falls back to |
| slotProps | SuggestionItemSlotProps | |
| slots | Partial | See Slots API below for more details. |
The component cannot hold a ref.
| Slot name | Class name | Default component | Description |
|---|---|---|---|
| root |
Source code
If you did not find the information in this page, consider having a look at the implementation of the component for more detail.