āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā ā š shadcn/directory/ai-elements/plan ā āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā
A collapsible plan component for displaying AI-generated execution plans with streaming support and shimmer animations.
The Plan component provides a flexible system for displaying AI-generated execution plans with collapsible content. Perfect for showing multi-step workflows, task breakdowns, and implementation strategies with support for streaming content and loading states.
npx ai-elements@latest add plan
import {
Plan,
PlanAction,
PlanContent,
PlanDescription,
PlanFooter,
PlanHeader,
PlanTitle,
PlanTrigger,
} from '@/components/ai-elements/plan';
<Plan defaultOpen={false}>
<PlanHeader>
<PlanTitle>Implement new feature</PlanTitle>
<PlanDescription>
Add authentication system with JWT tokens and refresh logic.
</PlanDescription>
<PlanTrigger />
</PlanHeader>
<PlanContent>
<div className="space-y-4 text-sm">
<div>
<h3 className="mb-2 font-semibold">Overview</h3>
<p>This plan outlines the implementation strategy...</p>
</div>
</div>
</PlanContent>
<PlanFooter>
<Button>Execute Plan</Button>
</PlanFooter>
</Plan>
| Prop | Type | | isStreaming? | boolean | | defaultOpen? | boolean | | ...props? | React.ComponentProps<typeof Collapsible> |
| Prop | Type | | ...props? | React.ComponentProps<typeof CardHeader> |
| Prop | Type | | children? | string | | ...props? | Omit<React.ComponentProps<typeof CardTitle>, "children"> |
| Prop | Type | | children? | string | | ...props? | Omit<React.ComponentProps<typeof CardDescription>, "children"> |
| Prop | Type | | ...props? | React.ComponentProps<typeof CollapsibleTrigger> |
| Prop | Type | | ...props? | React.ComponentProps<typeof CardContent> |
| Prop | Type | | ...props? | React.ComponentProps<"div"> |
| Prop | Type | | ...props? | React.ComponentProps<typeof Button> |
ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā