1
0
mirror of https://github.com/SomboChea/ui synced 2024-11-05 06:04:28 +07:00
verdaccio-ui/src/components/Header/HeaderToolTip.tsx

19 lines
511 B
TypeScript
Raw Normal View History

import React from 'react';
import Tooltip from '@material-ui/core/Tooltip';
import HeaderToolTipIcon, { TooltipIconType } from './HeaderToolTipIcon';
interface Props {
title: string;
tooltipIconType: TooltipIconType;
onClick?: () => void;
}
const HeaderToolTip: React.FC<Props> = ({ tooltipIconType, title, onClick }) => (
<Tooltip disableFocusListener={true} title={title}>
<HeaderToolTipIcon onClick={onClick} tooltipIconType={tooltipIconType} />
</Tooltip>
);
export default HeaderToolTip;