Skip to content
coatx
Esc
↑↓navigate↵open⌘Jpreview
On this page

Popover

Floating popover card with directional arrow, title, and description slots.

Usage

import {
  Popover,
  PopoverContent,
  PopoverTitle,
  PopoverTrigger,
} from "@ilha/ui-sdk/popover";
import { button } from "coatx/button";
import { popoverContent, popoverTitle } from "coatx/popover";

export const InfoPopover = () => (
  <Popover>
    <PopoverTrigger {...button({ variant: "outline" })}>Info</PopoverTrigger>
    <PopoverContent {...popoverContent()}>
      <PopoverTitle {...popoverTitle()}>Details</PopoverTitle>
    </PopoverContent>
  </Popover>
);

Exports (coatx/popover)

Export Description
popoverContent(options?) Floating popover panel
popoverArrow(options?) Pointer arrow tip
popoverTitle(options?) Popover heading
popoverDescription(options?) Popover body copy
popoverStyles Compiled StyleX style map

Was this page helpful?