ContextEventRow

Record something the agent pulled into its context: a file it read, a directory it listed, a memory file, an MCP resource, a skill, or diagnostics. The row shows an icon per kind, a verb (Read, Listed, Loaded memory, Attached, Loaded skill, Found diagnostics in) and the label with an optional detail. With items the row expands to show them, closed unless defaultExpanded. Override verbs per kind with labels. MessageList renders it automatically for a { type: "context-event", kind, label, detail?, items? } part, so in a chat you only emit the part. The row is one line and truncates its detail, so it works at any width.

Getting Started
$pnpm add @sinups/ai-kit @mantine/core @mantine/hooks @tabler/icons-react
Examples
All kinds
API reference
Prop
Type
Required
defaultExpanded
boolean
No
Initial expanded state when `items` are given, `false` by default
labels
Partial<ContextEventLabels>
No
Verbs per kind, for example `{ file: 'Opened' }`
className
string
No
Class name added to the root element
style
React.CSSProperties
No
Inline styles added to the root element
kind
ContextEventKind
Yes
label
string
Yes
Object of the event, for example a file path or a skill name
detail
string
No
Extra detail after the label, for example `120 lines`
items
string[]
No
Entries shown when the row is expanded, for example files of a directory