import { useRef } from 'react'; import styles from '@patternfly/react-styles/css/components/Compass/compass'; import { css } from '@patternfly/react-styles'; import { Button } from '../Button'; import { Tooltip } from '../Tooltip'; const CompassHomeIcon = () => ( ); export interface CompassNavHomeProps extends Omit, 'onClick'> { /** Content to display in the tooltip. Defaults to "Home". */ tooltipContent?: React.ReactNode; /** Click handler for the home button. */ onClick?: React.MouseEventHandler; /** Additional classes added to the nav home wrapper. */ className?: string; /** Accessible label for the nav home. */ 'aria-label'?: string; } export const CompassNavHome: React.FunctionComponent = ({ 'aria-label': ariaLabel = 'Home', tooltipContent = 'Home', className, onClick, ...props }: CompassNavHomeProps) => { const buttonRef = useRef(null); return ( } aria-label={ariaLabel} onClick={onClick} ref={buttonRef} /> ); }; CompassNavHome.displayName = 'CompassNavHome';