Skip to content
nexubDesign System
v2.4.0

Patterns · AI

Conversation

Since v1.8.0

Chat layout: a scrolling message list that follows new content, with a sticky composer underneath.

import { Conversation } from '@nexub/patterns';

Usage

Use it for
  • A full chat or assistant view: messages above, composer below.

Use something else for
  • A single question and answer: a PromptInput and a MessageBubble in normal flow are enough.

  • Comment threads that don’t follow new content: use ActivityFeed.

Examples

Mini chat

Send a message: it shows Thinking, then streams a cited reply. Stop or Escape ends the reply early.

Props

Props
PropTypeDefaultDescription
childrenReactNode—The messages, usually MessageBubbles.
composerReactNode—Sticky slot under the list, usually a PromptInput.
autoScrollbooleantrueFollow new content while the reader is at the bottom. Scrolling up stops following and shows "Jump to latest".
announcebooleanfalseMake the list a polite role="log". Only for whole-message updates: with token streaming it announces every chunk.
messagesPartial<ConversationMessages>—Overrides for jumpToLatest and conversation.