Skip to content
ComponentsAll componentsMenu

Components

170 components for agent and chat interfaces, from a single streaming caret to a complete coding agent. Each page has live examples, the props and every state.

Blocks7

  • Chatbot2 examples

    A complete chat app surface

  • A landing hero for an agent product

  • AI pricing1 example

    Pricing for an agent product

  • Coding agent1 example

    A Claude Code and Cursor style coding agent in one block

  • A deep research surface: the conversation with a live progress card, search results streaming in, every source found, read and cited, and the finished report with citations

  • Agent ops1 example

    Mission control for background agents

  • App builder1 example

    Describe an app and watch it build

Primitives3

  • Menu2 examples

    Dropdown menu on Base UI

  • Popover1 example

    Floating panel on Base UI with the kit's surface, origin-aware motion and no animation when opened from the keyboard

  • Dialog2 examples

    A Base UI dialog on the chatcn surface

Conversation15

Composer14

  • Prompt input6 examples

    The composer: a growing textarea with slots for context, attachments and tools, IME-safe Enter to send, Escape to stop, and paste and drop that turn into files

  • Send button2 examples

    Send that becomes Stop in the same footprint

  • Attachment2 examples

    Files in the composer as chips or cards

  • Drop zone2 examples

    Composer-sized and full-page drop targets that say before the drop whether files will be accepted, and why not

  • Model picker2 examples

    Model menu for the composer footer, grouped by provider, with search, capability glyphs, a New tag and your own provider marks

  • How hard the model thinks

  • Mode switcher1 example

    The tools menu: web search, deep research, canvas and image

  • Microphone button with permission, listening with live level bars, transcribing and a blocked state that says how to fix it

  • Context chips1 example

    The context the agent will read with the next message

  • Character or token budget for the composer, with soft and hard limits, a ring variant and announcements only at thresholds

  • The composer with a rich editor

  • Mention menu2 examples

    The @ popup for files, folders, symbols, people, agents and connectors

  • Slash menu2 examples

    The / popup for commands and skills, with categories, descriptions, shortcuts, the active command's arguments, and a ghost argument hint after insertion

  • Inline chip1 example

    A token inside text for a mention, file, URL, command or prompt variable

Content13

  • Markdown5 examples

    Streaming Markdown for assistant answers

  • Streaming text2 examples

    Plain text that streams in with the signature caret, an optional cadence buffer and one announcement on completion

  • Code block5 examples

    Restrained syntax highlighting that keeps up with streaming, with copy, wrap, line numbers, highlighted lines, long-block collapse and multi-file tabs

  • Inline code1 example

    Mono at 0.9em on a quiet fill

  • Table2 examples

    Tables that stay readable at any width

  • Math2 examples

    KaTeX math, inline and display, loaded on first use

  • Mermaid2 examples

    Mermaid diagrams in the chatcn palette, with source view, zoom, pan and fullscreen

  • Image2 examples

    An image inside a message

  • Image grid2 examples

    One to four images in a fixed-shape grid, with a +N tile for the rest and a shared lightbox you can page through

  • File card2 examples

    A file the agent made: type icon, a name that never hides its extension, size, preview and download, with generating and error states

  • Link preview2 examples

    An unfurled link: a compact row or an expanded card with image, title and description, with a skeleton in the final layout and a plain-link fallback

  • JSON viewer2 examples

    A collapsible, searchable tree for tool inputs and outputs, with copy path and copy value on every row and full keyboard navigation

  • ANSI output2 examples

    Terminal output with ANSI colors mapped onto the kit palette for both themes, carriage-return progress bars collapsed and incremental parsing for streams

Agents19

  • Tool call6 examples

    Shows an agent tool call through its whole life

  • Trace3 examples

    One line primitive for every agent step on a vertical rail

  • Trace group2 examples

    Folds consecutive steps into one line, Read 6 files, with a live line that shows what the agent is doing right now

  • Reasoning3 examples

    Model reasoning behind one quiet line

  • Step timer1 example

    Elapsed and final duration for an agent step, in tabular figures that tick once per second

  • Run status1 example

    The state of a whole agent run for a header or thread row

  • Sources1 example

    The sources behind an answer

  • Citation1 example

    An inline numbered source with a hover card

  • A web search tool call: the query and result count in the header, results as a quiet list with letter tiles, titles, domains and snippets

  • A page fetch: the address, the page title and an excerpt of what the agent read

  • A file read: path and line range in the header, a numbered preview of what the agent saw

  • File edit tool2 examples

    A file edit: path and +12 -3 in the header, a unified mini diff that reads without color

  • A new file: the path in the header, then a file card with its name, size and first lines

  • A grep or glob: the pattern and match count in the header, matches grouped by file with file:line and the match highlighted

  • Shell tool2 examples

    A shell command: a monochrome terminal that streams output and stays pinned to the bottom, the exit code, and Stop while it runs

  • Code run in a sandbox: the code with line numbers, then output, errors and the result

  • MCP tool1 example

    A call to a tool on an MCP server or connector

  • Tool fallback2 examples

    The renderer for tools nobody wrote a renderer for

  • Browser tool2 examples

    A browser agent at work: the steps it takes (open, click, type, scroll) with the running one live, and a screenshot thumbnail with the cursor where it last acted

Planning9

  • Plan5 examples

    The agent's proposed plan, from the first streamed step to the last one done

  • Todo list4 examples

    The agent's checklist with a live 3 of 7 count, a hairline progress rail and a check that draws itself when a todo finishes

  • Task1 example

    A single task row: status, title, mono detail, a live timer that becomes a duration, and details on demand

  • Subagent3 examples

    A subagent folded to one line that says what it is doing right now

  • Handoff1 example

    The marker between two agents in a transcript, with the reason in plain words so nobody wonders why the voice changed

  • Queued messages2 examples

    Messages typed while the agent works, in a visible queue

  • Context meter2 examples

    How full the context window is, as a ring or a bar, with a breakdown on click and a warning before compaction

  • Agent card2 examples

    Who an agent is: name, what it does, the model behind it, the tools it may call and what it is doing now

  • Workflow2 examples

    A node graph of an agent workflow with live status, rounded SVG edges and keyboard-focusable nodes

Runs10

  • Computer view3 examples

    A live view of the agent's screen

  • Approval mode2 examples

    Manual, Auto or Skip, each with one sentence that says what the agent will do without you, a list of saved grants per site and per tool, and calm notices for actions that stay blocked in every mode

  • Approval inbox2 examples

    Every pending approval across runs in one list

  • Questionnaire2 examples

    Clarifying questions from the agent, one at a time

  • Permission mode2 examples

    A compact selector for the composer

  • Background run2 examples

    A card for a detached agent task

  • Run inbox2 examples

    Background runs in one list, with a Needs input filter and static unread dots

  • Toasts for needs your input, done and failed that stack, fan out on hover and swipe away, plus a hook for desktop notifications while the tab is hidden

  • Takeover banner2 examples

    The agent is controlling the browser, with Take over, Pause and Stop, and the reverse

  • Agent lanes2 examples

    Parallel agents side by side, each with its status, current step and streaming output

Code10

  • Diff viewer6 examples

    Review an agent's code changes

  • Changed files2 examples

    The files an agent changed, with status letters, dimmed directories, +/- counts and a five-cell bar

  • Commit card2 examples

    A commit or pull request the agent made

  • File tree4 examples

    The files an agent touched, as a real WAI-ARIA tree

  • Terminal3 examples

    Streaming command output with ANSI colors in the kit palette, a command header, exit code and duration, copy, clear, wrap and follow toggles, and an optional input line

  • Test results2 examples

    A test run as the agent sees it

  • Sandbox2 examples

    The machine an agent works in

  • A floating toolbar over a live preview for pointing at what to change

  • Stack trace2 examples

    An error stack that leads with your code

  • Environment variables an agent needs or has set

Research8

  • A deep research run from plan to report

  • Research report2 examples

    A long report built for reading

  • Search results3 examples

    Web results from a search tool in three views

  • Source document2 examples

    A document source with its cited page

  • Document viewer2 examples

    Page sheets with the cited passage highlighted, a rule in the margin and page navigation that follows your scroll

  • Canvas1 example

    A document canvas for writing with an agent

  • A floating toolbar over selected text with Ask, Rewrite, Explain and Copy

  • Ghost text completion after the caret in a plain textarea

Workspace7

  • Resizable2 examples

    Split panes with pointer and keyboard resizing, pixel or percent limits, collapsible panels and a hairline handle

  • Artifact2 examples

    The inline card that stands for an artifact in a message

  • Artifact panel3 examples

    The side panel for artifacts

  • Step through artifact versions or pick one from a list, with edit times and line diff counts to the previous version

  • Web preview3 examples

    An iframe preview for apps an agent builds

  • JSX preview3 examples

    Renders JSX written by a model without running it

  • Bind useChat from AI SDK 7 to chatcn actions, and run it with a scripted transport when there is no server

Generative UI12

  • Renders a JSON spec from the model as chatcn widgets

  • Chart4 examples

    Bar, line, area and proportion charts in a color-blind aware categorical palette, with dashes and end markers on lines, direct labels, a tooltip on hover and focus, and a table for screen readers

  • Stat card2 examples

    A figure with its delta and a sparkline

  • Options side by side with the best value in each row marked, the recommended option tinted, and a choose button per column

  • Form widget2 examples

    A form the agent asks the user to fill in

  • A small interactive tool inside an answer

  • Card carousel2 examples

    Horizontal results such as places, products or events

  • Map placeholder2 examples

    A location card with a monochrome street pattern seeded from the coordinates, so the same place always looks the same and nothing waits on a map provider

  • Weather card2 examples

    The reference generative widget

  • Events or steps on a vertical rail

  • The safe pattern for actions an agent takes on the user's behalf

  • MCP app frame2 examples

    Hosts an MCP App (a ui:// resource, text/html;profile=mcp-app) in a sandboxed iframe through the official app bridge

Voice9

  • Voice session3 examples

    One surface for voice and text

  • Voice orb5 examples

    A monochrome sphere of fine contour lines that carries the whole voice state machine through form and motion

  • Waveform2 examples

    Live input and output levels as a scrolling history, in bars or one continuous line, or a recorded waveform with its played portion

  • Agent audio in five monochrome forms

  • Voice controls2 examples

    The call bar: mute with a live input level and a microphone menu, speaker, captions, your own controls and End

  • Transcript3 examples

    Live voice transcript with speaker labels, unsettled words in a lighter gray, timestamps that seek, typed turns and a clean cut where the user interrupted

  • Audio player2 examples

    Read-aloud and audio output player

  • Voice picker2 examples

    Choose a voice after hearing it

  • Audio level1 example

    A Web Audio level meter for a microphone stream or a media element

Media5

Shell11

  • Chat layout3 examples

    The app shell: sidebar, thread and an optional side panel on the shared Resizable

  • Chat sidebar2 examples

    The thread sidebar: New chat, a filter, threads grouped by date with Pinned on top, inline rename, delete with undo, live status per thread, a 52 px rail and a resizable edge

  • Thread list1 example

    The rows and groups the sidebar is built from

  • Switches the project a sidebar shows

  • A segmented control for product modes like Chat, Work and Code

  • Chat header1 example

    The bar above a thread: a title you rename in place, the model, a Temporary badge, Share and a More menu, plus the sidebar toggle on mobile

  • Command palette2 examples

    Cmd/Ctrl+K: one field that finds chats, runs actions and switches models, with fuzzy matching, groups, shortcut hints and no open animation from the keyboard

  • Chat search2 examples

    Full-text search across chats with the matched words marked in titles and snippets, role filters, recent chats and full keyboard control

  • A dialog with every shortcut grouped by area, a filter and platform-aware keys, plus a ShortcutKeys renderer for tooltips and menus

  • Composer mobile3 examples

    A bottom-anchored phone composer that rides the on-screen keyboard, with attach sources and tools in a bottom sheet

  • Onboarding4 examples

    First-run UI that stays calm

Settings14

  • Settings panel2 examples

    The settings layout for an AI app

  • Memory chip2 examples

    The quiet line under an assistant turn that says memory changed, with View to read exactly what was saved and Undo to take it back

  • Memory manager2 examples

    Everything the assistant remembers, searchable and editable in place

  • Temporary chat2 examples

    A header toggle for chats that stay out of history and memory, and the banner that says plainly what that means

  • The personalization editor

  • Connectors2 examples

    A connector directory with connect and disconnect states and per-tool permissions

  • Knowledge base2 examples

    Project files the assistant reads in every chat, each with its indexing state

  • Usage meter2 examples

    Plan usage with tabular numbers and live reset times

  • Docks above the composer when a limit is near or reached

  • Cost display2 examples

    What a message or an agent run cost, in tabular figures, with the breakdown one click away

  • Model status2 examples

    Degraded, outage or maintenance notice for a model or provider, with when it started, a link to the status page and a switch to a model that works

  • Share dialog2 examples

    Share a chat as a snapshot

  • Safety notice2 examples

    Refusal and warning messaging with a calm, non-judgmental tone and a next step every time

  • Tool memory2 examples

    Tool renderer for memory saved, updated or forgotten, built on Tool call, with the exact text so people can see what the assistant now knows

Adapters4

  • Adapters1 example

    chatcn components take plain props

  • AG-UI adapter2 examples

    Render any AG-UI agent with chatcn

  • Render LangGraph agents with chatcn

  • Keep your assistant-ui runtime and render its messages with chatcn text, reasoning and tool components, approvals included