UNPKG

@accelint/design-toolkit

Version:

An open-source component library to serve as part of the entire ecosystem of UX for Accelint.

4 lines (3 loc) 1.12 kB
'use client'; import {jsx}from'react/jsx-runtime';import'client-only';import {DialogTrigger,Popover,Dialog,Heading,Pressable}from'react-aria-components';import {PopoverStyles}from'./styles.js';const {content:c,body:y,title:N,footer:T}=PopoverStyles(),e=({placement:r="bottom",children:o,...p})=>jsx(DialogTrigger,{...p,children:o});e.displayName="Popover";const A=({children:r,...o})=>jsx(Pressable,{...o,children:r});e.displayName="Popover.Trigger";const i=({children:r,className:o,...p})=>jsx(Popover,{className:c({className:o}),...p,children:jsx(Dialog,{children:r})});i.displayName="Popover.Content";const a=({children:r,className:o,...p})=>jsx(Heading,{slot:"title",className:N({className:o}),...p,children:r});a.displayName="Popover.Title";const s=({children:r,className:o})=>jsx("div",{className:y({className:o}),children:r});s.displayName="Popover.Body";const P=({children:r,className:o})=>jsx("div",{className:T({className:o}),children:r});P.displayName="Popover.Footer",e.Title=a,e.Content=i,e.Body=s,e.Footer=P,e.Trigger=A;export{e as Popover};//# sourceMappingURL=index.js.map //# sourceMappingURL=index.js.map