Inline action buttons for assistant and user messages.
Use ChatMessageActions for copy, retry, rating, share, or custom message actions.
import {ChatMessageActions} from "@heroui-pro/react";
<ChatMessageActions>
<ChatMessageActions.Action aria-label="Copy">{/* ... */}</ChatMessageActions.Action>
</ChatMessageActions>;Use a smaller action set when only one or two actions are needed.
Actions are composable, so you can bring your own icon set.
HeroUI follows the BEM methodology to ensure component variants and states are reusable and easy to customize.
The Chat Message Actions component uses these CSS classes:
.chat-message-actions: Root action row, also .chat-message__actions.chat-message__action: Individual icon button.chat-message-actions__icon: Action icon, default or customRoot action group, also available as ChatMessage.Actions. Supports native div props.
Individual action button. Extends HeroUI Button props.
Resources