import React from 'react';
import { IconButton } from '@atlaskit/button/new';
import Tooltip from '@atlaskit/tooltip';
import { useMouseDownEvent } from '../../../../../state/analytics/useLinkClicked';
const LinkInfoButton = ({
  content,
  icon,
  label,
  onClick,
  testId,
  role
}) => {
  const onMouseDown = useMouseDownEvent();
  return /*#__PURE__*/React.createElement(Tooltip, {
    content: content,
    hideTooltipOnClick: true,
    tag: "span",
    testId: `${testId}-tooltip`
  }, /*#__PURE__*/React.createElement(IconButton, {
    appearance: "subtle",
    icon: icon,
    label: label,
    onClick: onClick,
    onMouseDown: onMouseDown,
    testId: `${testId}-button`,
    role: role
  }));
};
export default LinkInfoButton;