# Popover with custom content

> Popover with custom content

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

- Page, with a live preview: https://shadcn.exchange/r/reui/c-popover-7
- Screenshot: https://abzjhwgwpdpz7ua5.public.blob.vercel-storage.com/shots/reui/c-popover-7-light-fc15ea13eecd04c9.png
- Registry item: https://reui.io/r/new-york-v4/c-popover-7.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-popover-7.json
```

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

## Dependencies

- Registry items: `button`, `popover`

## Files

### `c-popover-7.tsx`

```tsx
import { Button } from "@/components/ui/button"
import {
  Popover,
  PopoverContent,
  PopoverTrigger,
} from "@/components/ui/popover"
import { IconPlaceholder } from "@/app/(create)/components/icon-placeholder"

export function Pattern() {
  return (
    <div className="flex min-h-[100px] items-center justify-center">
      <Popover>
        <PopoverTrigger
          render={
            <Button variant="outline" className="gap-2">
              <IconPlaceholder
                lucide="SparklesIcon"
                tabler="IconSparkles"
                hugeicons="SparklesIcon"
                phosphor="SparkleIcon"
                remixicon="RiSparklingLine"
              />
              AI Assistant
            </Button>
          }
        />
        <PopoverContent
          className="w-80 gap-0 overflow-hidden p-0"
          align="center"
        >
          <div className="bg-primary/5 border-primary/10 border-b p-2">
            <div className="text-primary flex items-center gap-2 font-semibold">
              <IconPlaceholder
                lucide="SparklesIcon"
                tabler="IconSparkles"
                hugeicons="SparklesIcon"
                phosphor="SparkleIcon"
                remixicon="RiSparklingLine"
                className="size-4"
              />
              <span>Smart Suggestions</span>
            </div>
          </div>
          <div className="space-y-3 p-2">
            <p className="text-muted-foreground leading-relaxed">
              Our AI analyzes your workflow to provide tailored recommendations.
              It helps you automate repetitive tasks and optimizes your design
              process in real-time.
            </p>
            <div className="grid grid-cols-2 items-center gap-2">
              <Button size="sm">Enable AI</Button>
              <Button size="sm" variant="outline">
                Learn more
              </Button>
            </div>
          </div>
        </PopoverContent>
      </Popover>
    </div>
  )
}
```
