ChatMessageSource API
API reference docs for the React ChatMessageSource component. Learn about the props, CSS, and other APIs of this exported module.
Demos
Import
import { ChatMessageSource } from '@mui/x-chat/ChatMessageSources';
// or
import { ChatMessageSource } from '@mui/x-chat';Learn about the difference by reading this guide on minimizing bundle size.
| Name | Type | Description |
|---|---|---|
| href* | string | The URL this source links to. |
| index | number | 1-based position number displayed as a muted badge. |
| title | string | Display title for the source. Falls back to |
The component cannot hold a ref.
| Slot name | Class name | Default component | Description |
|---|---|---|---|
| root | .MuiChatMessageSource-root | 'li' | The root list item element. |
| index | .MuiChatMessageSource-index | 'span' | The numeric index badge. |
| link | .MuiChatMessageSource-link | 'a' | The anchor link. |
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.