ButtonInputPopover()function
ButtonInputPopover({
children: [buttonChildren, ...popoverChildren], //
...props
}: ButtonInputPopoverProps): ReactElement| Param | Type | |
|---|---|---|
props | ButtonInputPopoverProps | Props for ButtonInputPopover, an input button that toggles an adjacent popover. required |
.children | PopoverChildren | Children tuple for Popover: a leading trigger node followed by the popover's contents. required |
| Return | |
|---|---|
ReactElement | A Popover wrapping a ButtonInput that toggles it open and closed. |
An input button that, when clicked, shows a popover next to it when clicked or focused.
- The first element passed to
childrenis used as the content for the button, the rest is the content of the popover.
DH: Would love to use new HTML popover="auto" functionality for this but the anchor positioning it needs is not supported everywhere yet.
Examples
<ButtonInputPopover name="filter">{label}{panel}</ButtonInputPopover>