Chat
Chat is a family of components for building chat interfaces, including message alignment, colored bubbles, avatars, headers, and footers.
Chat is a family of components for building chat interfaces, including message alignment, colored bubbles, avatars, headers, and footers.
The Chat components include the following:
The main wrapper for a chat message or sequence. Controls alignment and whitespace.
| Chat Props | Type | Description |
|---|---|---|
pre | boolean | Preserves whitespace and line breaks in the chat content. |
align | string | Controls alignment of the chat message. Options: |
| start | boolean | Shortcut for |
| end | boolean | Shortcut for |
| Chat Slots | Description |
|---|---|
default | The default slot. Place ChatBubble, ChatImage, ChatHeader, ChatFooter, or other content here. |
The colored speech bubble for chat messages. Supports semantic color props or a custom color string.
| ChatBubble Props | Type | Description |
|---|---|---|
color | string | Sets the color of the chat bubble. Options: |
| neutral | boolean | Shortcut for |
| primary | boolean | Shortcut for |
| secondary | boolean | Shortcut for |
| accent | boolean | Shortcut for |
| info | boolean | Shortcut for |
| success | boolean | Shortcut for |
| warning | boolean | Shortcut for |
| error | boolean | Shortcut for |
| ChatBubble Slots | Description |
|---|---|
default | The default slot. Content to be displayed inside the chat bubble. |
| ChatImage Slots | Description |
|---|---|
default | The default slot. Content (such as an |
The header area for a chat message. Use for names, timestamps, or status.
| ChatHeader Slots | Description |
|---|---|
default | The default slot. Content to be displayed in the chat header. |
The footer area for a chat message. Use for metadata, reactions, or actions.
| ChatFooter Slots | Description |
|---|---|
default | The default slot. Content to be displayed in the chat footer. |
Demonstrates how to display avatars next to chat bubbles using the ChatImage component.
Shows how to use the color prop on ChatBubble to set semantic colors for chat messages.
Demonstrates the pre prop on Chat to preserve whitespace and line breaks in chat content.
Shows how to use ChatHeader and ChatFooter for names, timestamps, and status in chat messages.
Demonstrates how to display a stack of images sent by a user in a chat bubble.


