"use strict";

exports.__esModule = true;
exports.default = exports.Legend = exports.FieldsetBox = void 0;

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

var _styledComponents = _interopRequireDefault(require("styled-components"));

var _utils = require("../../utils");

var _Text = _interopRequireDefault(require("../Text"));

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

(function () {
  var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
  enterModule && enterModule(module);
})();

(function () {
  var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
  enterModule && enterModule(module);
})();

var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
  return a;
};

var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
  return a;
};

var FieldsetBox = _styledComponents.default.fieldset.withConfig({
  displayName: "Fieldset__FieldsetBox",
  componentId: "sc-g5pm1u-0"
})(["position:relative;box-sizing:border-box;display:flex;align-self:stretch;flex-direction:column;flex-wrap:wrap;border:1px solid ", ";border-radius:5px;margin-top:45px;margin-left:0;margin-bottom:0;padding:20px;padding-top:0;background-color:#fafafa;"], (0, _utils.getThemeProp)(["colors", "borderLight"], "#cccccc"));

exports.FieldsetBox = FieldsetBox;

var Legend = _styledComponents.default.legend.withConfig({
  displayName: "Fieldset__Legend",
  componentId: "sc-g5pm1u-1"
})(["position:absolute;top:-2em;left:-4px;font-family:", ";font-style:italic;font-size:13px;text-transform:uppercase;color:", ";"], (0, _utils.getThemeProp)(["fonts", "header"], "sans-serif"), (0, _utils.getThemeProp)(["colors", "application", "base"], "#333333"));

exports.Legend = Legend;

var Fieldset = function Fieldset(_ref) {
  var label = _ref.label,
      children = _ref.children;
  return /*#__PURE__*/_react.default.createElement(FieldsetBox, null, /*#__PURE__*/_react.default.createElement(Legend, null, /*#__PURE__*/_react.default.createElement(_Text.default, {
    message: label
  })), children);
};

var _default = Fieldset;
var _default2 = _default;
var _default3 = _default2;
exports.default = _default3;
;

(function () {
  var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;

  if (!reactHotLoader) {
    return;
  }

  reactHotLoader.register(FieldsetBox, "FieldsetBox", "/home/vsts/work/1/s/src/components/Form/Fieldset.js");
  reactHotLoader.register(Legend, "Legend", "/home/vsts/work/1/s/src/components/Form/Fieldset.js");
  reactHotLoader.register(Fieldset, "Fieldset", "/home/vsts/work/1/s/src/components/Form/Fieldset.js");
  reactHotLoader.register(_default, "default", "/home/vsts/work/1/s/src/components/Form/Fieldset.js");
})();

;

(function () {
  var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
  leaveModule && leaveModule(module);
})();

;

(function () {
  var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;

  if (!reactHotLoader) {
    return;
  }

  reactHotLoader.register(FieldsetBox, "FieldsetBox", "/home/vsts/work/1/s/src/components/Form/Fieldset.js");
  reactHotLoader.register(Legend, "Legend", "/home/vsts/work/1/s/src/components/Form/Fieldset.js");
  reactHotLoader.register(Fieldset, "Fieldset", "/home/vsts/work/1/s/src/components/Form/Fieldset.js");
  reactHotLoader.register(_default2, "default", "/home/vsts/work/1/s/src/components/Form/Fieldset.js");
})();

;

(function () {
  var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
  leaveModule && leaveModule(module);
})();