Squads include a dedicated team of designers, a project manager, and a senior creative director — all working together on your brand.
npx shadcn@latest add https://sdk-components.thesqd.com/r/collapsible.jsonimport { CollapsibleSection } from "@/components/ui/collapsible";import { CollapsibleSection } from "@/components/ui/collapsible";
export function Example() {
return (
<CollapsibleSection
variant="default"
title="What's included in the squad?"
description="Click to expand and read the details."
defaultOpen
>
<p className="pt-2 text-muted-foreground">
Squads include a dedicated team of designers, a project manager, and a
senior creative director — all working together on your brand.
</p>
</CollapsibleSection>
);
}CollapsibleSection (flat one-liner — pass everything as props)
├── variant="default | outline | ghost"
├── size="sm | default | lg"
├── title={<ReactNode>} (heading row, required)
├── description={<ReactNode>} (muted secondary line, optional)
├── icon={<ReactNode>} (override the chevron, optional)
├── defaultOpen / open / onOpenChange (uncontrolled or controlled)
├── disabled?: boolean
└── children (body content)
— or use the primitives directly —
Collapsible (Base UI Collapsible.Root with data-slot)
├── CollapsibleTrigger (button that toggles the panel)
└── CollapsibleContent (animated panel; uses --collapsible-panel-height)Squads include a dedicated team of designers, a project manager, and a senior creative director — all working together on your brand.
Manage profile, billing, and team settings.
| Prop | Type | Default | Description |
|---|---|---|---|
title | ReactNode | — | Heading rendered in the trigger row. |
description | ReactNode | — | Optional muted secondary line below the title. |
variant | "default" | "outline" | "ghost" | "default" | Surface treatment — bordered card, outline, or ghost. |
size | "sm" | "default" | "lg" | "default" | Padding scale applied to the trigger row and body. |
icon | ReactNode | — | Indicator icon. Defaults to ChevronDown that rotates 180° when open. |
hideIcon | boolean | false | Hide the indicator icon entirely. |
defaultOpen | boolean | false | Initial open state when uncontrolled. |
open | boolean | — | Controlled open state. Pair with onOpenChange. |
onOpenChange | (open: boolean) => void | — | Fires when the user toggles the section. |
disabled | boolean | false | Disable the trigger and grey out the section. |
children | ReactNode | — | Body content rendered inside the animated panel. |
| Prop | Type | Default | Description |
|---|---|---|---|
Collapsible | Base UI Collapsible.Root | — | Root container. Accepts open / defaultOpen / onOpenChange / disabled. |
CollapsibleTrigger | Base UI Collapsible.Trigger | — | Button that toggles the panel. Use render={<Button … />} to swap the element. |
CollapsibleContent | Base UI Collapsible.Panel | — | Animated panel. Reads --collapsible-panel-height for height transitions. |