# UploadItem

A host-controlled upload row with explicit progress and applicable actions.

Connect Flood once using [the installation guide](https://flood.md/docs/installation). Then import the components you use; no per-component add command is needed.

## Example

```tsx
"use client";

import { FloodRoot, UploadList, UploadItem } from "@flood-md/react";
import "@flood-md/react/styles.css";

export function Example() {
  return (
    <FloodRoot>
      <UploadList label="Uploads">
        <UploadItem name="Brand guidelines.pdf" size={2400000} state="uploading" progress={45} />
      </UploadList>
    </FloodRoot>
  );
}
```

## Design notes

- Queued/uploading can expose cancel; error/cancelled can expose retry; settled rows can expose remove.
- Unknown progress is indeterminate. StatusIndicator and Progress remain distinct reused primitives; their row can wrap when the list container is constrained. No network or upload queue is built in.

## API reference

| Prop | Values | Default |
| --- | --- | --- |
| `name` | `string` | `Required` |
| `size` | `number` | `—` |
| `mimeType` | `string` | `—` |
| `format` | `string \| null` | `—` |
| `thumbnail` | `ReactNode` | `—` |
| `href` | `string` | `—` |
| `download` | `boolean` | `—` |
| `onPreview` | `() => void` | `—` |
| `onRemove` | `() => void` | `—` |
| `disabled` | `boolean` | `—` |
| `labels` | `FileActionLabels` | `—` |
| `formatSize` | `(bytes: number) => string` | `—` |
| `state` | `"queued" \| "uploading" \| "success" \| "error" \| "cancelled"` | `Required` |
| `progress` | `number` | `—` |
| `error` | `string` | `—` |
| `onCancel` | `() => void` | `—` |
| `onRetry` | `() => void` | `—` |
| `Native HTML props` | `Omit<Omit<HTMLAttributes<HTMLLIElement>, "children" \| "title">, "description">` | `Forwarded` |
