# Document Checklist (/docs/components/document-checklist)



<ComponentPreview name="document-checklist" />

## Installation [#installation]

<Tabs items="[&#x22;Command&#x22;, &#x22;Manual&#x22;]">
  <Tab value="Command">
    <CodeBlockTabs defaultValue="npm">
      <CodeBlockTabsList>
        <CodeBlockTabsTrigger value="npm">
          npm
        </CodeBlockTabsTrigger>

        <CodeBlockTabsTrigger value="pnpm">
          pnpm
        </CodeBlockTabsTrigger>

        <CodeBlockTabsTrigger value="yarn">
          yarn
        </CodeBlockTabsTrigger>

        <CodeBlockTabsTrigger value="bun">
          bun
        </CodeBlockTabsTrigger>
      </CodeBlockTabsList>

      <CodeBlockTab value="npm">
        ```bash
        npx shadcn@latest add @uploadcn/document-checklist
        ```
      </CodeBlockTab>

      <CodeBlockTab value="pnpm">
        ```bash
        pnpm dlx shadcn@latest add @uploadcn/document-checklist
        ```
      </CodeBlockTab>

      <CodeBlockTab value="yarn">
        ```bash
        yarn dlx shadcn@latest add @uploadcn/document-checklist
        ```
      </CodeBlockTab>

      <CodeBlockTab value="bun">
        ```bash
        bun x shadcn@latest add @uploadcn/document-checklist
        ```
      </CodeBlockTab>
    </CodeBlockTabs>
  </Tab>

  <Tab value="Manual">
    Install [Upload](/docs/components/upload) and the shadcn `badge` component, then copy:

    <ComponentSource name="document-checklist" />
  </Tab>
</Tabs>

## Usage [#usage]

```tsx
import { DocumentChecklist } from "@/components/document-checklist"
```

```tsx
<DocumentChecklist
  title="Onboarding documents"
  items={[
    {
      name: "contract",
      label: "Signed contract",
      accept: "application/pdf",
      required: true,
    },
    { name: "tax-form", label: "Tax form", required: true },
    { name: "photo", label: "Profile photo", accept: "image/*" },
  ]}
/>
```

Each file carries its requirement name in `item.meta.slot`, so your backend knows which document is which.

## Props [#props]

<TypeTable
  type="{
  adapter: {
    type: &#x22;UploadAdapter&#x22;,
    default: 's3Adapter({ endpoint: &#x22;/api/upload&#x22; })',
    description: &#x22;Where files go.&#x22;,
  },
  uploader: {
    type: &#x22;Uploader&#x22;,
    description: &#x22;An uploader from `useUploader`, instead of options.&#x22;,
  },
  title: { type: &#x22;string&#x22;, default: '&#x22;Supporting documents&#x22;' },
  description: { type: &#x22;string&#x22; },
  items: {
    type: &#x22;ChecklistItem[]&#x22;,
    default: &#x22;an insurance claim&#x22;,
    description: &#x22;`{ name, label, description?, accept?, required? }`&#x22;,
  },
  maxSize: { type: &#x22;number&#x22;, default: &#x22;25 MB&#x22; },
  onSuccess: { type: &#x22;(item) => void&#x22; },
  className: { type: &#x22;string&#x22; },
}"
/>
