Components
- Accordion
- Alert
- Alert Dialog
- Aspect Ratio
- Attachment
- Autocomplete
- Avatar
- Badge
- Breadcrumb
- Bubble
- Button
- Calendar
- Card
- Carousel
- Chart
- Checkbox
- Checkbox Group
- Collapsible
- Combobox
- Command
- Context Menu
- Date Picker
- Dialog
- Drawer
- Dropdown Menu
- Empty
- Field
- Fieldset
- Form
- Frame
- Group
- Input
- Input Group
- Kbd
- Label
- Menu
- Menubar
- Message
- Meter
- Number Field
- OTP Field
- Pagination
- Popover
- Preview Card
- Progress
- Questionnaire
- Radio Group
- Scroll Area
- Select
- Separator
- Sheet
- Sidebar
- Skeleton
- Slider
- Spinner
- Switch
- Table
- Tabs
- Textarea
- Toggle
- Toggle Group
- Toolbar
- Tooltip
Shared
- Artifact
- Audio Player
- Canvas
- Chain of Thought
- Checkpoint
- Code Block
- Commit
- Connection
- Context
- Controls
- Edge
- Environment Variables
- Mic Selector
- Model Selector
- Node
- Node Toolbar
- Open in Chat
- Panel
- Plan
- Prompt Input
- Queue
- Reasoning
- Sandbox
- Schema Display
- Shimmer
- Snippet
- Sources
- Speech Input
- Stack Trace
- Suggestion
- Tool
- Transcription
- Web Preview
Hooks
Resources
Chain of Thought
A collapsible trace of an agent's reasoning steps.
Searching the documentation
Looked through the component documentation
base-ui.comreact.dev
Comparing the available options
Writing the answer
import {
ChainOfThought,
ChainOfThoughtContent,
ChainOfThoughtHeader,
ChainOfThoughtSearchResult,
ChainOfThoughtSearchResults,
ChainOfThoughtStep,
} from "@/registry/default/shared/chain-of-thought";
export default function Particle() {
return (
<div className="w-full max-w-lg">
<ChainOfThought defaultOpen>
<ChainOfThoughtHeader>Chain of thought</ChainOfThoughtHeader>
<ChainOfThoughtContent>
<ChainOfThoughtStep
description="Looked through the component documentation"
label="Searching the documentation"
status="complete"
>
<ChainOfThoughtSearchResults>
<ChainOfThoughtSearchResult>base-ui.com</ChainOfThoughtSearchResult>
<ChainOfThoughtSearchResult>react.dev</ChainOfThoughtSearchResult>
</ChainOfThoughtSearchResults>
</ChainOfThoughtStep>
<ChainOfThoughtStep label="Comparing the available options" status="active" />
<ChainOfThoughtStep label="Writing the answer" status="pending" />
</ChainOfThoughtContent>
</ChainOfThought>
</div>
);
}
Installation
pnpm dlx shadcn@latest add @frontal-labs/chain-of-thought
Usage
import {
ChainOfThought,
ChainOfThoughtHeader,
ChainOfThoughtStep,
ChainOfThoughtSearchResults,
ChainOfThoughtSearchResult,
ChainOfThoughtContent,
ChainOfThoughtImage,
} from "@/components/chain-of-thought";API Reference
| Export | Props |
|---|---|
ChainOfThought | <div> attributes, plus its own options |
ChainOfThoughtHeader | CollapsibleTrigger props |
ChainOfThoughtStep | <div> attributes, plus its own options |
ChainOfThoughtSearchResults | <div> attributes |
ChainOfThoughtSearchResult | Badge props |
ChainOfThoughtContent | CollapsibleContent props |
ChainOfThoughtImage | <div> attributes, plus its own options |
Open the source under Manual above for the exact prop types.
On This Page