Popover
A small box that opens next to a button when you click it.
Add it to your project
Or install the packages yourselfTerminal
npm install @heroui/react
First time with HeroUI? Set it up once.
The code
*/
import {Button, Popover} from "@heroui/react";
export default function PopoverDemo() {
return (
<div className="flex items-center gap-4">
<Popover>
<Button>Click me</Button>
<Popover.Content className="max-w-64">
<Popover.Dialog>
<Popover.Heading>Popover Title</Popover.Heading>
<p className="mt-2 text-sm text-muted">This comes with paid plans
The code for every component comes with paid plans, along with the rest of the AI toolkit. The first component under each heading is free.
Changed for this site: A default export (HeroUI's docs use named ones).