Chat History

Gather user prompts and navigate to a selected message with a brief highlight.

Chat History

Default

Select a past user message to return to it with a brief highlight. Match transcript data-message-id values to message ids, or use message-target for an external list. Reduced motion uses a static highlight.

Bind visibility and use select to update active-id. History renders only user prompts and closes after selection. The example combines Message and Message Scroller.

API

PROPS

Property
Type
Description
default
Example
More
message-target
(message: ) => HTMLElement | null | undefined
Resolve a message element. By default, matches data-message-id inside the transcript; selection scrolls its owning viewport and briefly highlights the message.
—
messages
[]
Conversation entries. Only user messages are included in the history list.
[]
v-model
Boolean
Controlled visibility.
false
active-id
String
Id of the currently located prompt.
—
label
String
Accessible name, with a localized default.
—

EVENTS

Event
Type
Description
default
Example
More
update:modelValue
(value: boolean) => void
Controlled model update requested.
—
—
select
(message: ) => void
Prompt selected for consumer-owned navigation.
—
—

SLOTS

Slot
Description
default
Example
More
default
Transcript content; dimmed and made inert while history is open.
—
—
trigger
Customize content inside the built-in accessible trigger.
—
—
item
Customize a history prompt.
—
—
Last Updated: 2026-10-28, 06:17:56 UTC
Copied