lbry-desktop/ui/component/common/tooltip.jsx
jessopb 618ab5e195
More header refactors (#7441)
* Refactor notificationHeaderButton

* Add Tooltips to header buttons and replace reach/ui

* Decrease --header-height by 20%

* more header cherry-pick

Co-authored-by: Rafael <rafael.saes@odysee.com>
2022-01-26 21:14:36 -05:00

30 lines
636 B
JavaScript

// @flow
import React from 'react';
import MUITooltip from '@mui/material/Tooltip';
import type { Node } from 'react';
type Props = {
arrow?: boolean,
children: Node,
disableInteractive?: boolean,
enterDelay?: number,
title?: string | Node,
};
function Tooltip(props: Props) {
const { arrow = true, children, disableInteractive = true, enterDelay = 300, title } = props;
return (
<MUITooltip
arrow={arrow}
disableInteractive={disableInteractive}
enterDelay={enterDelay}
enterNextDelay={enterDelay}
title={title}
>
{children}
</MUITooltip>
);
}
export default Tooltip;