"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");

Object.defineProperty(exports, "__esModule", {
  value: !0
}), exports.default = StdFormRow;

var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")), _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty")), _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties")), _react = _interopRequireDefault(require("react")), _propTypes = _interopRequireDefault(require("prop-types")), _classnames = _interopRequireDefault(require("classnames"));

function StdFormRow(e) {
  var r, t = e.title, a = e.children, o = e.last, l = e.block, i = e.grid, u = (0, 
  _objectWithoutProperties2.default)(e, [ "title", "children", "last", "block", "grid" ]), d = (0, 
  _classnames.default)("standard-form-row", (r = {}, (0, _defineProperty2.default)(r, "standard-form-rowblock", l), 
  (0, _defineProperty2.default)(r, "standard-form-rowlast", o), (0, _defineProperty2.default)(r, "standard-form-rowgrid", i), 
  r));
  return _react.default.createElement("div", (0, _extends2.default)({
    className: d
  }, u), t && _react.default.createElement("div", {
    className: "row-title"
  }, _react.default.createElement("span", null, t)), _react.default.createElement("div", {
    className: "row-content"
  }, a));
}

StdFormRow.displayName = "StdFormRow", StdFormRow.propTypes = {
  title: _propTypes.default.string,
  children: _propTypes.default.node,
  last: _propTypes.default.bool,
  block: _propTypes.default.bool,
  grid: _propTypes.default.bool
};