Cartesiandocs

Android · cartesian-ui

CartesianComponents

The built-in composables, public so that your slots can wrap or reuse them.

public object CartesianComponents
kotlin

Each function draws the default version of a slot. Calling one inside your own slot gives you the stock behaviour plus whatever you add around it.

FunctionParameters
Theme(theme, content)Provides a CartesianTheme to Cartesian composables you use outside a chat surface
Orb(activity, size = 20.dp, modifier, paused = false)The agent orb. OrbActivity: Thinking, Searching, Comparing, Remembering, Planning, Composing, Listening, Waiting.
Header(controller, onClose)Title, status pill, new chat, saved and cart buttons, close
ConnectionStatus(controller)Connecting/offline pill
OfflineBanner(controller)Inline banner while offline
Offline(controller)Full offline state with retry
ErrorRecovery(controller)Error card with retry and dismiss
EmptyState(controller)Welcome heading and starters
Loading(controller)Loading orb
UserMessage(message, controller)User bubble
AssistantMessage(message, controller)Full answer block
Trace(message, controller)Activity steps
AssistantText(message, controller)Markdown text
ProductList(products, controller)Product carousel
ProductCard(product, controller)One product card
Comparison(comparison, controller)Comparison
CartUpdate(update, controller)Cart confirmation card
MessageActions(message, controller)Copy and feedback
Suggestions(suggestions, controller)Follow-up chips
Composer(controller)Input with voice and send/stop
Footer(controller)Disclaimer
PoweredBy(controller, modifier)Attribution line (hidden with a white-label licence)
Drawer(controller)Cart and saved drawer

The orb is also handy for your own loading states:

CartesianComponents.Theme(Cartesian.options.theme) {
    CartesianComponents.Orb(OrbActivity.Searching, size = 32.dp)
}
kotlin