Message

Compose role-based messages with timestamps, feedback and content slots.

Message

Default

Use content for plain text or compose richer content in the default slot. User content is a compact bubble; select the message body or its timestamp control to reveal a controlled timestamp. Feedback is controlled. Assistant actions emit intent so the consumer can regenerate or persist feedback.

Shared Agent icon

Set agent-icon once on SConfigProvider to replace the default Agent icon in both Message and Agent Editor, or configure app.use(SaxDesignVue, { agentIcon: “/assistant.svg” }). A component agent-icon overrides the shared value, and slots take precedence over URLs. PNG and SVG are supported; an empty string restores the default icon.

API

PROPS

Property
Type
Description
default
Example
More
agent-icon
String
Assistant PNG / SVG URL overriding global agentIcon; an empty string restores the default SVG.
—
role
'user' | 'assistant' | 'system' | 'tool'
Message role controlling author fallback and assistant actions.
assistant
content
String
Plain content, replaceable through the default slot.
''
author
String
Visible author name; falls back to the localized role.
—
sent-at
String
Visible timestamp text revealed by selecting the message body or timestamp control.
—
datetime
String
Machine-readable ISO timestamp for the native time element.
—
v-model:show-time
Boolean
Controlled timestamp visibility. Use v-model:show-time.
false
loading
Boolean
Show busy feedback and block normal actions. Chat Input keeps Stop available.
false
actions
Boolean
Show icon actions. Defaults to enabled for assistant and user messages and disabled for system and tool roles; explicitly set actions to override.
—
v-model:feedback
'like' | 'dislike' | null
Controlled helpfulness selection; pressing the selected action clears it.
null
disabled
Boolean
Disable component actions.
false

EVENTS

Event
Type
Description
default
Example
More
update:showTime
(value: boolean) => void
Timestamp visibility toggle requested.
—
—
copy
() => void
Clipboard write succeeded.
—
—
copy-error
(error: unknown) => void
Clipboard write failed.
—
—
update:feedback
(value: 'like' | 'dislike' | null) => void
Feedback selected or cleared.
—
—
regenerate
() => void
Regenerate the assistant response.
—
—
edit
() => void
Request editing a user message.
—
—

SLOTS

Slot
Scope
Description
default
Example
More
agent-icon
{ busy: boolean }
Customize the default assistant icon; avatar takes precedence.
—
—
default
—
Replace the default content.
—
—
avatar
—
Customize the role avatar.
—
—
header
—
Customize author and timestamp trigger.
—
—
actions
—
Customize the action row.
—
—
Last Updated: 2026-10-28, 06:17:56 UTC
Copied