chore(components): improve props

This commit is contained in:
Benjamin Canac
2024-06-28 18:13:03 +02:00
parent c9f9a248b7
commit 673064dee5
38 changed files with 260 additions and 137 deletions

View File

@@ -12,22 +12,22 @@ const popover = tv({ extend: tv(theme), ...(appConfig.ui?.popover || {}) })
export interface PopoverProps extends PopoverRootProps, Pick<HoverCardRootProps, 'openDelay' | 'closeDelay'> {
/**
* The display mode of the popover.
* @defaultValue `"click"`
* @defaultValue 'click'
*/
mode?: 'click' | 'hover'
/**
* The content of the popover.
* @defaultValue `{ side: 'bottom', sideOffset: 8 }`
* @defaultValue { side: 'bottom', sideOffset: 8 }
*/
content?: Omit<PopoverContentProps, 'as' | 'asChild' | 'forceMount'>
/**
* Display an arrow alongside the popover.
* @defaultValue `false`
* @defaultValue false
*/
arrow?: boolean | Omit<PopoverArrowProps, 'as' | 'asChild'>
/**
* Render the popover in a portal.
* @defaultValue `true`
* @defaultValue true
*/
portal?: boolean
class?: any