import _inheritsLoose from "@babel/runtime/helpers/inheritsLoose";
import * as React from 'react';
import { Component } from 'react';
import "./index.scss";
var ImageSetter = /*#__PURE__*/function (_Component) {
  _inheritsLoose(ImageSetter, _Component);
  function ImageSetter() {
    return _Component.apply(this, arguments) || this;
  }
  var _proto = ImageSetter.prototype;
  _proto.render = function render() {
    var _this$props = this.props,
      options = _this$props.options,
      onChange = _this$props.onChange;
    var imgfun = function imgfun(item) {
      onChange(item);
    };
    return /*#__PURE__*/React.createElement("div", {
      className: "containers"
    }, /*#__PURE__*/React.createElement("div", {
      className: "box"
    }, options.map(function (item, key) {
      return /*#__PURE__*/React.createElement("div", {
        className: "img",
        key: key,
        onClick: function onClick() {
          return imgfun(item.src);
        }
      }, /*#__PURE__*/React.createElement("img", {
        src: item.src
      }));
    })));
  };
  return ImageSetter;
}(Component);
ImageSetter.displayName = 'ImageSetter';
export { ImageSetter as default };