"use strict";

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

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

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

var _Typography = _interopRequireDefault(require("@material-ui/core/Typography"));

var _classnames = _interopRequireDefault(require("classnames"));

var _styles = require("@material-ui/core/styles");

var styles = function styles(theme) {
  return {
    formSection: {
      marginTop: theme.spacing.unit * 2,
      marginBottom: theme.spacing.unit * 2
    },
    label: {
      marginBottom: theme.spacing.unit
    }
  };
};

var _default = (0, _styles.withStyles)(styles)(function (_ref) {
  var className = _ref.className,
      classes = _ref.classes,
      label = _ref.label,
      children = _ref.children,
      labelExtraStyle = _ref.labelExtraStyle;
  return /*#__PURE__*/_react["default"].createElement("div", {
    className: (0, _classnames["default"])(classes.formSection, className)
  }, /*#__PURE__*/_react["default"].createElement(_Typography["default"], {
    className: classes.label,
    type: "subheading",
    style: labelExtraStyle
  }, label), children);
});

exports["default"] = _default;
//# sourceMappingURL=form-section.js.map