"use strict";

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

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

var _propTypes = _interopRequireDefault(require("prop-types"));

var _SelectModule = _interopRequireDefault(require("./Select.module.css"));

var _componentCategories = _interopRequireDefault(require("../../docs-utils/componentCategories"));

var _componentGroups = _interopRequireDefault(require("../../docs-utils/componentGroups"));

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }

function Select(props) {
  var size = props.size,
      style = props.style,
      variant = props.variant,
      fieldStyle = props.fieldStyle,
      disabled = props.disabled,
      optionvalues = props.optionvalues,
      placeholder = props.placeholder;
  return /*#__PURE__*/_react["default"].createElement("div", {
    className: _SelectModule["default"].container
  }, /*#__PURE__*/_react["default"].createElement("div", {
    className: _SelectModule["default"].field + ' ' + _SelectModule["default"][fieldStyle] + ' ' + _SelectModule["default"][variant] + ' ' + "".concat(disabled ? _SelectModule["default"].disabled : null) + ' ' + _SelectModule["default"][size],
    "data-placeholder": placeholder
  }), /*#__PURE__*/_react["default"].createElement("span", {
    className: _SelectModule["default"].arrow + ' ' + "".concat(size === 'lg' ? _SelectModule["default"].arrowlg : null)
  }, "\u25E2"), /*#__PURE__*/_react["default"].createElement("ul", {
    className: _SelectModule["default"].optionContainer
  }, optionvalues && optionvalues.map(function (optionvalue) {
    return /*#__PURE__*/_react["default"].createElement("li", {
      className: _SelectModule["default"].option,
      key: optionvalue
    }, optionvalue);
  })));
}

Select.defaultProps = {
  size: "md",
  variant: "",
  placeholder: "placeholder",
  fieldStyle: ""
};

if (false) {
  Select.docs = {
    componentGroup: _componentGroups["default"].Atom,
    folderName: _componentCategories["default"].Form
  };
}