"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");

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

var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));

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

var _classnames = _interopRequireDefault(require("classnames"));

var _context = require("../config-provider/context");

var Group = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
  var _cx;

  var className = props.className,
      style = props.style;

  var _React$useContext = _react.default.useContext(_context.ConfigContext),
      getPrefixClassName = _React$useContext.getPrefixClassName;

  var inputCls = getPrefixClassName('input-group-cl');
  var cls = (0, _classnames.default)(inputCls, (_cx = {}, (0, _defineProperty2.default)(_cx, "".concat(inputCls, "-lg"), props.size === 'large'), (0, _defineProperty2.default)(_cx, "".concat(inputCls, "-sm"), props.size === 'small'), (0, _defineProperty2.default)(_cx, "".concat(inputCls, "-compact"), props.compact), _cx), className);
  return /*#__PURE__*/_react.default.createElement("div", {
    className: cls,
    style: style,
    onMouseEnter: props.onMouseEnter,
    onMouseLeave: props.onMouseLeave,
    onFocus: props.onFocus,
    onBlur: props.onBlur
  }, props.children);
});

Group.displayName = 'Group';
Group.defaultProps = {
  compact: false,
  size: 'default'
};
var _default = Group;
exports.default = _default;