"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
exports.__esModule = true;
exports["default"] = void 0;
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
var _inheritsLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/inheritsLoose"));
var _react = _interopRequireDefault(require("react"));
var _variables = require("../../variables");
require("./index.scss");
//按钮栏
var CommonButtonBox = /*#__PURE__*/function (_React$Component) {
  (0, _inheritsLoose2["default"])(CommonButtonBox, _React$Component);
  function CommonButtonBox(props) {
    var _this;
    _this = _React$Component.call(this, props) || this;
    _this._renderChildren = function () {
      var children = _this.props.children;
      return _react["default"].Children.map(children, function (child) {
        return /*#__PURE__*/_react["default"].createElement("div", {
          className: "button-item"
        }, " ", /*#__PURE__*/_react["default"].cloneElement(child));
      });
    };
    return _this;
  }
  var _proto = CommonButtonBox.prototype;
  _proto.render = function render() {
    var _this$props = this.props,
      justifyContent = _this$props.justifyContent,
      style = _this$props.style;
    // console.log(children)
    return /*#__PURE__*/_react["default"].createElement("div", {
      className: _variables.bizCssPrefix + '-common-button-box',
      style: (0, _extends2["default"])({
        justifyContent: justifyContent
      }, style)
    }, this._renderChildren());
  };
  return CommonButtonBox;
}(_react["default"].Component);
CommonButtonBox.displayName = 'CommonButtonBox';
var _default = CommonButtonBox;
exports["default"] = _default;