collapsible-demo.tsx — ui Source File
Architecture documentation for collapsible-demo.tsx, a tsx file in the ui codebase. 4 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR cf364445_347d_76bf_3e8b_21987f399745["collapsible-demo.tsx"] 1d141819_425e_b5fd_4c8e_32f7c6a42cf2["react"] cf364445_347d_76bf_3e8b_21987f399745 --> 1d141819_425e_b5fd_4c8e_32f7c6a42cf2 4b1d2128_46d9_46f0_b915_b6e1925b7876["button"] cf364445_347d_76bf_3e8b_21987f399745 --> 4b1d2128_46d9_46f0_b915_b6e1925b7876 a519b2f3_5e0e_a053_b4d5_e1f3786d0de2["collapsible"] cf364445_347d_76bf_3e8b_21987f399745 --> a519b2f3_5e0e_a053_b4d5_e1f3786d0de2 d39cd1e4_1b2d_9aa2_1d29_fd0b4bfb61c3["lucide-react"] cf364445_347d_76bf_3e8b_21987f399745 --> d39cd1e4_1b2d_9aa2_1d29_fd0b4bfb61c3 style cf364445_347d_76bf_3e8b_21987f399745 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
"use client"
import * as React from "react"
import { Button } from "@/examples/radix/ui/button"
import {
Collapsible,
CollapsibleContent,
CollapsibleTrigger,
} from "@/examples/radix/ui/collapsible"
import { ChevronsUpDown } from "lucide-react"
export default function CollapsibleDemo() {
const [isOpen, setIsOpen] = React.useState(false)
return (
<Collapsible
open={isOpen}
onOpenChange={setIsOpen}
className="flex w-[350px] flex-col gap-2"
>
<div className="flex items-center justify-between gap-4 px-4">
<h4 className="text-sm font-semibold">Order #4189</h4>
<CollapsibleTrigger asChild>
<Button variant="ghost" size="icon" className="size-8">
<ChevronsUpDown />
<span className="sr-only">Toggle details</span>
</Button>
</CollapsibleTrigger>
</div>
<div className="flex items-center justify-between rounded-md border px-4 py-2 text-sm">
<span className="text-muted-foreground">Status</span>
<span className="font-medium">Shipped</span>
</div>
<CollapsibleContent className="flex flex-col gap-2">
<div className="rounded-md border px-4 py-2 text-sm">
<p className="font-medium">Shipping address</p>
<p className="text-muted-foreground">100 Market St, San Francisco</p>
</div>
<div className="rounded-md border px-4 py-2 text-sm">
<p className="font-medium">Items</p>
<p className="text-muted-foreground">2x Studio Headphones</p>
</div>
</CollapsibleContent>
</Collapsible>
)
}
Domain
Subdomains
Functions
Dependencies
- button
- collapsible
- lucide-react
- react
Source
Frequently Asked Questions
What does collapsible-demo.tsx do?
collapsible-demo.tsx is a source file in the ui codebase, written in tsx. It belongs to the DocumentationAtlas domain, Changelog subdomain.
What functions are defined in collapsible-demo.tsx?
collapsible-demo.tsx defines 1 function(s): CollapsibleDemo.
What does collapsible-demo.tsx depend on?
collapsible-demo.tsx imports 4 module(s): button, collapsible, lucide-react, react.
Where is collapsible-demo.tsx in the architecture?
collapsible-demo.tsx is located at apps/v4/examples/radix/collapsible-demo.tsx (domain: DocumentationAtlas, subdomain: Changelog, directory: apps/v4/examples/radix).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free