import _extends from "@babel/runtime/helpers/extends";
import _defineProperty from "@babel/runtime/helpers/defineProperty";
import React, { memo, useContext } from 'react';
import omit from 'lodash/omit';
import classNames from 'classnames';
import Element from './Element';
import ConfigContext from '../config-provider/ConfigContext';

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

  var _useContext = useContext(ConfigContext),
      getPrefixCls = _useContext.getPrefixCls;

  var prefixCls = getPrefixCls('skeleton', customizePrefixCls);
  var cls = classNames(prefixCls, className, "".concat(prefixCls, "-element"), _defineProperty({}, "".concat(prefixCls, "-active"), active));
  return /*#__PURE__*/React.createElement("div", {
    className: cls
  }, /*#__PURE__*/React.createElement(Element, _extends({
    prefixCls: "".concat(prefixCls, "-avatar")
  }, omit(props, ['prefixCls']))));
};

SkeletonAvatar.displayName = 'SkeletonAvatar';
var MemoSkeletonAvatar = /*#__PURE__*/memo(SkeletonAvatar);
MemoSkeletonAvatar.defaultProps = {
  size: 'default',
  shape: 'circle'
};
export default MemoSkeletonAvatar;
//# sourceMappingURL=Avatar.js.map
