"use strict";

var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard")["default"];

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

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

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

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

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

var _omit = _interopRequireDefault(require("lodash/omit"));

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

var _Element = _interopRequireDefault(require("./Element"));

var _ConfigContext = _interopRequireDefault(require("../config-provider/ConfigContext"));

var SkeletonButton = function SkeletonButton(props) {
  var customizePrefixCls = props.prefixCls,
      className = props.className,
      active = props.active;

  var _useContext = (0, _react.useContext)(_ConfigContext["default"]),
      getPrefixCls = _useContext.getPrefixCls;

  var prefixCls = getPrefixCls('skeleton', customizePrefixCls);
  var cls = (0, _classnames["default"])(prefixCls, className, "".concat(prefixCls, "-element"), (0, _defineProperty2["default"])({}, "".concat(prefixCls, "-active"), active));
  return /*#__PURE__*/_react["default"].createElement("div", {
    className: cls
  }, /*#__PURE__*/_react["default"].createElement(_Element["default"], (0, _extends2["default"])({
    prefixCls: "".concat(prefixCls, "-button")
  }, (0, _omit["default"])(props, ['prefixCls']))));
};

SkeletonButton.displayName = 'SkeletonButton';
var MemoSkeletonButton = /*#__PURE__*/(0, _react.memo)(SkeletonButton);
MemoSkeletonButton.defaultProps = {
  size: 'default'
};
var _default = MemoSkeletonButton;
exports["default"] = _default;
//# sourceMappingURL=Button.js.map
