import * as React from 'react';
import { FormattedMessage, useIntl } from 'react-intl';
import { Button as BlueprintButton } from '@box/blueprint-web';
import Button, { ButtonType } from '../../components/button';
import messages from './messages';
const OpenContentInsightsButton = ({
  isRedesignEnabled,
  onClick
}) => {
  const {
    formatMessage
  } = useIntl();
  if (isRedesignEnabled) {
    return /*#__PURE__*/React.createElement(BlueprintButton, {
      className: "OpenContentInsightsButton",
      onClick: onClick,
      type: "button",
      size: "small",
      variant: "secondary"
    }, formatMessage(messages.openContentInsightsButton));
  }
  return /*#__PURE__*/React.createElement(Button, {
    className: "OpenContentInsightsButton",
    onClick: onClick,
    type: ButtonType.BUTTON
  }, /*#__PURE__*/React.createElement(FormattedMessage, messages.openContentInsightsButton));
};
export default OpenContentInsightsButton;
//# sourceMappingURL=OpenContentInsightsButton.js.map