# Custom integration toast

> Custom integration toast

A shadcn/ui block from the [@reui](https://reui.io) registry, listed on [shadcn.exchange](https://shadcn.exchange/r/reui/c-sonner-20).

- Page, with a live preview: https://shadcn.exchange/r/reui/c-sonner-20
- Screenshot: https://abzjhwgwpdpz7ua5.public.blob.vercel-storage.com/shots/reui/c-sonner-20-light-5093d6af8ae89b4b.png
- Registry item: https://reui.io/r/new-york-v4/c-sonner-20.json
- Listed: 2026-10-13, source last changed 2026-10-13

## Install

```bash
npx shadcn@latest add https://reui.io/r/new-york-v4/c-sonner-20.json
```

Run it in a project that has shadcn/ui set up. It adds the files below and installs what they depend on.

## Dependencies

- npm packages: `sonner`
- Registry items: `button`, `separator`

## Files

### `c-sonner-20.tsx`

```tsx
import { toast } from "sonner"

import { Button } from "@/components/ui/button"
import { Separator } from "@/components/ui/separator"
import { IconPlaceholder } from "@/app/(create)/components/icon-placeholder"

export function Pattern() {
  const showToast = () => {
    toast.custom(() => (
      <div className="bg-popover text-popover-foreground border-border rounded-md flex w-[356px] flex-col gap-3 border p-4 shadow-lg">
        <div className="flex items-center gap-3">
          <div className="rounded-lg flex size-10 shrink-0 items-center justify-center bg-linear-to-br from-violet-500 to-purple-600 text-white shadow-sm">
            <IconPlaceholder
              lucide="LinkIcon"
              tabler="IconLink"
              hugeicons="Link01Icon"
              phosphor="LinkIcon"
              remixicon="RiLinkM"
              className="size-5"
              aria-hidden="true"
            />
          </div>
          <div className="flex flex-1 flex-col gap-0.5">
            <p className="text-sm font-semibold">Integration Connected</p>
            <p className="text-muted-foreground text-xs">workspace.slack.com</p>
          </div>
          <span className="flex items-center gap-1 text-xs text-green-600">
            <span className="size-1.5 rounded-full bg-green-500" />
            Active
          </span>
        </div>
        <Separator />
        <div className="text-muted-foreground flex items-center justify-between text-xs">
          <span>Syncing 3 channels</span>
          <span>Last sync: just now</span>
        </div>
        <div className="flex gap-2">
          <Button
            size="xs"
            variant="outline"
            className="flex-1"
            onClick={() => toast.dismiss()}
          >
            <IconPlaceholder
              lucide="SettingsIcon"
              tabler="IconSettings"
              hugeicons="SettingsIcon"
              phosphor="GearIcon"
              remixicon="RiSettings3Line"
              className="size-3"
              aria-hidden="true"
            />
            Configure
          </Button>
          <Button size="xs" className="flex-1" onClick={() => toast.dismiss()}>
            Open Dashboard
          </Button>
        </div>
      </div>
    ))
  }

  return (
    <div className="flex items-center justify-center">
      <Button onClick={showToast} variant="outline" className="w-fit">
        Integration Toast
      </Button>
    </div>
  )
}
```
