| 1 |
import styles from '@patternfly/react-styles/css/components/ClipboardCopy/clipboard-copy'; |
| 2 |
import { css } from '@patternfly/react-styles'; |
| 3 |
|
| 4 |
export interface ClipboardCopyActionProps extends React.HTMLProps<HTMLLIElement> { |
| 5 |
/** Content rendered inside the clipboard copy action. */ |
| 6 |
children?: React.ReactNode; |
| 7 |
/** Additional classes added to the clipboard copy action. */ |
| 8 |
className?: string; |
| 9 |
} |
| 10 |
|
| 11 |
export const ClipboardCopyAction: React.FunctionComponent<ClipboardCopyActionProps> = ({ |
| 12 |
children = null, |
| 13 |
className = '', |
| 14 |
...props |
| 15 |
}: ClipboardCopyActionProps) => ( |
| 16 |
<span className={css(styles.clipboardCopyActionsItem, className)} {...props}> |
| 17 |
{children} |
| 18 |
</span> |
| 19 |
); |
| 20 |
ClipboardCopyAction.displayName = 'ClipboardCopyAction'; |