docs: add composition section

This commit is contained in:
shadcn
2026-04-07 15:23:27 +04:00
parent 62f6df75f2
commit f00a94d9e5
78 changed files with 1534 additions and 52 deletions

View File

@@ -96,6 +96,24 @@ import {
</Command>
```
## Composition
Use the following composition to build a `Command`:
```text
Command
├── CommandInput
└── CommandList
├── CommandEmpty
├── CommandGroup
│ ├── CommandItem
│ └── CommandItem
├── CommandSeparator
└── CommandGroup
├── CommandItem
└── CommandItem
```
## Examples
### Basic