import _extends from "@babel/runtime/helpers/extends";
import _defineProperty from "@babel/runtime/helpers/defineProperty";
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
var _excluded = ["className", "children", "invalid", "inline"];
import PropTypes from 'prop-types';
import React from 'react';
import classnames from 'classnames';
import { settings } from '../../globals/js';
var prefix = settings.prefix;

var FormItem = function FormItem(_ref) {
  var _classnames;

  var className = _ref.className,
      children = _ref.children,
      invalid = _ref.invalid,
      inline = _ref.inline,
      other = _objectWithoutProperties(_ref, _excluded);

  var classNames = classnames("".concat(prefix, "--form-item"), (_classnames = {}, _defineProperty(_classnames, "".concat(prefix, "--form-item--inline"), inline), _defineProperty(_classnames, "".concat(prefix, "--form-item--invalid"), invalid), _classnames), className);
  return /*#__PURE__*/React.createElement("div", _extends({
    className: classNames
  }, other), children);
};

FormItem.propTypes = {
  children: PropTypes.node,
  className: PropTypes.string
};
export default FormItem;