npx tool-agent "integrate the progress tracker component for real-time status feedback on multi-step operations"npx shadcn@latest add @tool-ui/progress-trackerWhen an operation takes more than a moment (build, test, deploy) the user deserves to know where things stand. ProgressTracker shows each step of a multi-step workflow with its current status: pending, in-progress, completed, or failed. If something breaks, the error is visible immediately. Once the operation finishes, the tracker collapses into a receipt with the final outcome.
Role: State. Shows internal activity and progress. See Design Guidelines for how component roles work.
Run this once from your project root.
npx tool-agent "integrate the progress tracker component for real-time status feedback on multi-step operations"npx shadcn@latest add @tool-ui/progress-trackerRender ProgressTracker in your UI with tool-compatible props.
import { ProgressTracker } from "@/components/tool-ui/progress-tracker";export function Example() { return ( <ProgressTracker id="progress-tracker-example" steps={[ { id: "build", label: "Building", description: "Compiling TypeScript and bundling assets", status: "completed", }, { id: "test", label: "Running Tests", description: "147 tests across 23 suites", status: "in-progress", }, { id: "deploy", label: "Deploy to Production", description: "Upload to edge nodes", status: "pending", }, ]} elapsedTime={43200} /> );}Register this renderer so tool results display as ProgressTracker.
"use client";import { type Toolkit } from "@assistant-ui/react";import { ProgressTracker } from "@/components/tool-ui/progress-tracker";import { safeParseSerializableProgressTracker } from "@/components/tool-ui/progress-tracker/schema";export const toolkit: Toolkit = { trackProgress: { type: "backend", render: ({ result }) => { const parsed = safeParseSerializableProgressTracker(result); if (!parsed) { return null; } return <ProgressTracker {...parsed} />; }, },};ProgressTracker is display-only and result-driven: render it from backend tool result updates. For interactive decisions or confirmations, use OptionList or ApprovalCard.
Pending, in-progress, completed, and failed with distinct icons
Auto-formatted timer badge (seconds or minutes)
Failed steps show red indicators with error details
Read-only summary of the completed operation
Each step has one of four statuses:
The component automatically highlights the current step (first in-progress, otherwise first failed, otherwise first pending) with a subtle background and aria-current="step" for accessibility.
Pass a choice prop to render this component in its receipt state. See Receipts for the pattern.
The receipt shows all steps with their final statuses, an elapsed time badge, and an outcome indicator in the top-right corner. Supports success, partial, failed, and cancelled outcomes. Read-only with no action buttons.
Pass elapsedTime in milliseconds to display a timer badge. Automatically formatted as:
3.4s2m 15sProp
Type
Prop
Type
Prop
Type
<article> with role="status" and aria-live="polite" for live updatesaria-busy indicates when an operation is in progressaria-current="step" marks the currently active step<ol> / <li>)<time> and machine-readable dateTimeprefers-reduced-motion