| 1 |
import { Popover, Button } from '@patternfly/react-core'; |
| 2 |
import RhUiAttentionBellFillIcon from '@patternfly/react-icons/dist/esm/icons/rh-ui-attention-bell-fill-icon'; |
| 3 |
|
| 4 |
export const PopoverWithIconInTheTitle: React.FunctionComponent = () => ( |
| 5 |
<div style={{ margin: '50px' }}> |
| 6 |
<Popover |
| 7 |
aria-label="Popover with icon in the title example" |
| 8 |
headerContent="Popover with icon" |
| 9 |
headerIcon={<RhUiAttentionBellFillIcon />} |
| 10 |
bodyContent={<div>Popovers are triggered by click rather than hover.</div>} |
| 11 |
footerContent="Popover footer" |
| 12 |
appendTo={() => document.body} |
| 13 |
> |
| 14 |
<Button>Toggle popover</Button> |
| 15 |
</Popover> |
| 16 |
</div> |
| 17 |
); |