"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.HypothesisBlockHeader = void 0;

var _react = _interopRequireDefault(require("react"));

var _propTypes = _interopRequireDefault(require("prop-types"));

var _all = require("react-icons/all");

var _clsx = _interopRequireDefault(require("clsx"));

var _jsxRuntime = require("react/jsx-runtime");

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

var HypothesisBlockHeader = function HypothesisBlockHeader(_ref) {
  var title = _ref.title,
      noResults = _ref.noResults,
      noResultsTitle = _ref.noResultsTitle,
      onButtonClick = _ref.onButtonClick,
      className = _ref.className;
  return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
    className: (0, _clsx.default)("flex align-baseline text-sm font-medium", className),
    children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("p", {
      className: "text-dark-gray mr-2.5 mt-0.5 font-medium",
      children: noResults && noResultsTitle ? noResultsTitle : title
    }), /*#__PURE__*/(0, _jsxRuntime.jsx)("button", {
      type: "button",
      className: "btn-round btn-round-primary btn-round-xs",
      onClick: onButtonClick,
      children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_all.BsPlusLg, {})
    })]
  });
};

exports.HypothesisBlockHeader = HypothesisBlockHeader;
HypothesisBlockHeader.propTypes = {
  title: _propTypes.default.string.isRequired,
  noResults: _propTypes.default.bool,
  noResultsTitle: _propTypes.default.string,
  className: _propTypes.default.string,
  onButtonClick: _propTypes.default.func.isRequired
};
HypothesisBlockHeader.defaultProps = {
  noResults: false,
  noResultsTitle: "",
  className: ""
};