Message Scroller

A bounded conversation viewport that follows streamed replies while preserving the reader’s position.

New chat

How can I help you today?
What are we building?
Press send to start a conversation, then scroll while the reply arrives.
Local demo

Installation

Install the shared package once in your Exact app. This version is a beta.
bun add --exact @rightui/ui@0.4.0-beta.4
The Exact compiler requires Bun 1.4.2, regardless of which package manager installs the package.
Complete the font, app metadata and root provider setup (required for both installation methods).
Import
use ContentMessage, MessageScroller, MessageScrollerTranscript, MessageScrollerTranscriptStart, MessageScrollerRichViewport, MessageScrollerViewport, MessageScrollerButton from "@rightui/ui"

Usage

Use MessageScroller for its legacy composer, MessageScrollerTranscript or MessageScrollerTranscriptStart for a virtualized transcript with an external composer, or MessageScrollerRichViewport for caller-owned rich rows. Provide a bounded height and handle send and history in the caller.

API Reference

Properties from the component source. State lives in your component; actions receive the updated value.
MessageScroller.id
string
MessageScroller.messages
ContentMessage[]
MessageScroller.historyLoaded
bool
MessageScroller.loadHistory
action
MessageScroller.send
action
MessageScroller.latest
action
MessageScrollerTranscript.id
string
MessageScrollerTranscript.messages
ContentMessage[]
MessageScrollerTranscript.height
string
MessageScrollerTranscript.latest
action
MessageScrollerTranscriptStart.id
string
MessageScrollerTranscriptStart.messages
ContentMessage[]
MessageScrollerTranscriptStart.height
string
MessageScrollerTranscriptStart.latest
action
MessageScrollerRichViewport.id
string
MessageScrollerRichViewport.height
string
MessageScrollerViewport.id
string
MessageScrollerViewport.messages
ContentMessage[]
MessageScrollerViewport.height
string
MessageScrollerViewport.busy
bool
MessageScrollerViewport.reduced
bool
MessageScrollerViewport.latest
action
MessageScrollerButton.id
string
MessageScrollerButton.press
action