AI Components / Action Receipt
Action Receipt
Receipt for an agent action that already executed: what ran, what it touched, and the specific compensating affordance for this action (not a global undo). Status is labelled with text, never color alone (WCAG 1.4.1).
ai-workflowv0.6.0
Playground
Examples
Executed action
<ai-action-receipt summary="Sent invoice #1042 to Acme Corp" compensationLabel="Void invoice" style="max-width:400px;"></ai-action-receipt>Import
import { AiActionReceipt } from '@cognivo/components';// Or tree-shake: import '@cognivo/components/ai-action-receipt';Per-component imports ship only that component (~8 kB gzip).
API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
summary | string | — | What the action did |
touched | string[] | — | Resources the action touched |
status | "executed" | "failed" | "executed" | Action outcome |
error | string | — | Error message when status is failed |
compensationLabel | string | — | When set, a compensation button with this label is shown |
Events
| Event | Detail | Description |
|---|---|---|
ai-action-compensate | void | User asked to run the compensating action |