nuxt-x-app-admin
Ai Chat
AI chat interface with markdown rendering, suggestion chips, and streaming-friendly message handling.
Ai Chat
AI chat interface with markdown rendering, suggestion chips, and streaming-friendly message handling.
Components
<XAdminAIChat />
Props, events, and behaviour reflect the actual <script setup> of XAdmin/AI/Chat.vue in @xenterprises/nuxt-x-app-admin.
<XAdminAIChat />
Props
| Prop | Type | Default | Description |
|---|---|---|---|
endpoint | String | 'admin/ai/chat' | API endpoint for chat messages (POST { message, sessionId, systemPrompt }). |
agentName | String | 'AI Assistant' | Display name for the assistant. |
agentDescription | String | 'Powered by AI' | Subtitle shown beneath the assistant name. |
userName | String | 'You' | Display name for the human user. |
userImage | String | null | Optional avatar URL for the user. |
systemPrompt | String | null | Override the default system prompt for the conversation. |
suggestions | Array | 'Show me today's metrics','List recent support tickets','Summarize user signups this week','What are the top selling products?' | Suggestion chip labels rendered above the input. |
Emits
| Event | Payload | Description |
|---|---|---|
settings | varies | Fired when 'Settings' is clicked in the chat header. |
attach | varies | Fired when 'Attach' is clicked in the chat input. |
action | varies | Fired when a chat-side action button is invoked. |
AI Context
component: XAdminAIChat
package: "@xenterprises/nuxt-x-app-admin"
category: AI
source: app/components/XAdmin/AI/Chat.vue
use-when: AI chat interface with markdown rendering, suggestion chips, and streaming-friendly message handling.
