"use strict";

exports.__esModule = true;
exports.default = exports.PlaceholderTitle = exports.PlaceholderSubtitle = exports.PlaceholderIcon = exports.PlaceholderBox = void 0;
var _react = _interopRequireDefault(require("react"));
var _propTypes = _interopRequireDefault(require("prop-types"));
var _styledComponents = _interopRequireWildcard(require("styled-components"));
var _Text = _interopRequireWildcard(require("./Text"));
var _Icon = _interopRequireDefault(require("./Icon"));
var _utils = require("../utils");
var _excluded = ["icon", "title", "subtitle", "animate", "warn"];
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
(function () {
  var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
  enterModule && enterModule(module);
})();
(function () {
  var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
  enterModule && enterModule(module);
})();
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var s = Object.getOwnPropertySymbols(e); for (r = 0; r < s.length; r++) o = s[r], t.includes(o) || {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (e.includes(n)) continue; t[n] = r[n]; } return t; }
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 rotate = (0, _styledComponents.keyframes)(["to{transform:rotate(1turn);}"]);
var PlaceholderBox = exports.PlaceholderBox = _styledComponents.default.div.withConfig({
  displayName: "Placeholder__PlaceholderBox",
  componentId: "sc-1luw4x-0"
})(["display:flex;flex-direction:column;align-items:center;margin:auto;", ""], (0, _utils.ifFlag)("warn", "color: #ed2e0b; width: 33%; max-width:540px; text-align:center;", "color: #ababab;"));
var PlaceholderIcon = exports.PlaceholderIcon = (0, _styledComponents.default)(_Icon.default).withConfig({
  displayName: "Placeholder__PlaceholderIcon",
  componentId: "sc-1luw4x-1"
})(["font-size:140px;", ";"], (0, _utils.ifFlag)("animate", (0, _styledComponents.css)(["animation:", " 4s linear infinite;"], rotate)));
var PlaceholderTitle = exports.PlaceholderTitle = _styledComponents.default.div.withConfig({
  displayName: "Placeholder__PlaceholderTitle",
  componentId: "sc-1luw4x-2"
})(["margin-top:5px;font-size:2em;"]);
var PlaceholderSubtitle = exports.PlaceholderSubtitle = _styledComponents.default.div.withConfig({
  displayName: "Placeholder__PlaceholderSubtitle",
  componentId: "sc-1luw4x-3"
})(["font-size:1.3em;"]);
var Placeholder = function Placeholder(_ref) {
  var icon = _ref.icon,
    title = _ref.title,
    subtitle = _ref.subtitle,
    animate = _ref.animate,
    warn = _ref.warn,
    props = _objectWithoutProperties(_ref, _excluded);
  return /*#__PURE__*/_react.default.createElement(PlaceholderBox, _extends({
    warn: warn
  }, props), icon ? /*#__PURE__*/_react.default.createElement(PlaceholderIcon, {
    id: icon,
    animate: animate
  }) : null, title ? /*#__PURE__*/_react.default.createElement(PlaceholderTitle, null, /*#__PURE__*/_react.default.createElement(_Text.default, {
    message: title
  })) : null, subtitle ? /*#__PURE__*/_react.default.createElement(PlaceholderSubtitle, null, /*#__PURE__*/_react.default.createElement(_Text.default, {
    message: subtitle
  })) : null);
};
Placeholder.propTypes = {
  icon: _propTypes.default.string,
  title: _Text.ptLabel,
  subtitle: _Text.ptLabel,
  animate: _propTypes.default.bool,
  warn: _propTypes.default.bool
};
var _default = Placeholder;
var _default2 = _default;
var _default3 = exports.default = _default2;
;
(function () {
  var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;
  if (!reactHotLoader) {
    return;
  }
  reactHotLoader.register(rotate, "rotate", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(PlaceholderBox, "PlaceholderBox", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(PlaceholderIcon, "PlaceholderIcon", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(PlaceholderTitle, "PlaceholderTitle", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(PlaceholderSubtitle, "PlaceholderSubtitle", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(Placeholder, "Placeholder", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(_default, "default", "/home/vsts/work/1/s/src/components/Placeholder.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(rotate, "rotate", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(PlaceholderBox, "PlaceholderBox", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(PlaceholderIcon, "PlaceholderIcon", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(PlaceholderTitle, "PlaceholderTitle", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(PlaceholderSubtitle, "PlaceholderSubtitle", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(Placeholder, "Placeholder", "/home/vsts/work/1/s/src/components/Placeholder.js");
  reactHotLoader.register(_default2, "default", "/home/vsts/work/1/s/src/components/Placeholder.js");
})();
;
(function () {
  var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
  leaveModule && leaveModule(module);
})();