Tool Receipt
ProNewUnfold an itemized tool invocation with its arguments, return value and execution time.
Installation
pnpm dlx shadcn@latest add @viewport/tool-receipt
First time? Add the @viewport registry to components.json. Setup takes one minute.
Usage
The code behind the preview above comes with Truffle Pro.
Props
| Prop | Type | Default |
|---|---|---|
| tool* | stringInvoked tool name. | — |
| runId* | stringCorrelation identifier from the tool response. | — |
| elapsedMs* | numberMeasured execution time in milliseconds. | — |
| input* | Record<string, unknown>JSON-serializable arguments passed to the tool. | — |
| output* | stringFormatted result to show in the expanded receipt. | — |
| status | "success" | "error"Outcome reported by the tool. | "success" |
Accessibility
- A disclosure button reports expanded state. Hidden details leave the keyboard and accessibility trees.