import _get from "lodash/fp/get";
import React from 'react';
import PropTypes from 'prop-types';
import { NovaCompositionCoorpacademyPictures as PicturesIcon } from '@coorpacademy/nova-icons';
import Provider from '../provider';
import style from './style.css';
const CardImagePreview = ({
  image
}, {
  skin
}) => {
  const whiteColor = _get('common.white', skin);
  const emptyIcon = !image ? /*#__PURE__*/React.createElement(PicturesIcon, {
    className: style.emptyIcon,
    style: {
      color: whiteColor
    }
  }) : null;
  return /*#__PURE__*/React.createElement("div", {
    className: style.image,
    style: {
      backgroundImage: image ? `url('${image}')` : 'none'
    },
    "data-name": "card-image-preview"
  }, emptyIcon);
};
CardImagePreview.contextTypes = {
  skin: Provider.childContextTypes.skin
};
CardImagePreview.propTypes = process.env.NODE_ENV !== "production" ? {
  image: PropTypes.string
} : {};
export default CardImagePreview;
//# sourceMappingURL=index.js.map