/*
 * ATTENTION: An "eval-source-map" devtool has been used.
 * This devtool is not neither made for production nor for readable output files.
 * It uses "eval()" calls to create a separate source file with attached SourceMaps in the browser devtools.
 * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
 * or disable the default devtool with "devtool: false".
 * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
 */
var Grav;Grav =
/******/ (() => { // webpackBootstrap
/******/ 	var __webpack_modules__ = ({

/***/ "./app/dashboard/backup.js":
/*!*********************************!*\
  !*** ./app/dashboard/backup.js ***!
  \*********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\n/* harmony import */ var _chart__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./chart */ \"./app/dashboard/chart.js\");\n\n\n\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-backup][data-ajax*=\"backup/\"]').on('click', function () {\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n  var url = element.data('ajax');\n  var inDropdown = element.closest('.dropdown-menu');\n  (inDropdown.length ? inDropdown : element).closest('.button-group').find('> button:first').attr('disabled', 'disabled').find('> .fa').removeClass('fa-life-ring').addClass('fa-spin fa-refresh');\n  (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, function ()\n  /* response */\n  {\n    if (_chart__WEBPACK_IMPORTED_MODULE_3__.Instances && _chart__WEBPACK_IMPORTED_MODULE_3__.Instances.backups) {\n      _chart__WEBPACK_IMPORTED_MODULE_3__.Instances.backups.updateData({\n        series: [0, 100]\n      });\n      _chart__WEBPACK_IMPORTED_MODULE_3__.Instances.backups.element.find('.numeric').html(\"0 <em>\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.DAYS.toLowerCase(), \"</em>\"));\n    }\n\n    (inDropdown.length ? inDropdown : element).closest('.button-group').find('> button:first').removeAttr('disabled').find('> .fa').removeClass('fa-spin fa-refresh').addClass('fa-life-ring');\n  });\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-backup][data-ajax*=\"backupDelete\"]').on('click', function () {\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n  var url = element.data('ajax');\n  var tr = element.closest('tr');\n  tr.addClass('deleting');\n  (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, function (response) {\n    if (response.status === 'success') {\n      tr.remove();\n    } else {\n      tr.removeClass('deleting');\n    }\n  });\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4276 characters]\n//# sourceURL=webpack-internal:///./app/dashboard/backup.js\n");

/***/ }),

/***/ "./app/dashboard/cache.js":
/*!********************************!*\
  !*** ./app/dashboard/cache.js ***!
  \********************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ Cache,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar getUrl = function getUrl() {\n  var type = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n\n  if (type) {\n    type = \"cleartype:\".concat(type, \"/\");\n  }\n\n  return \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/cache.json/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"clearCache/\").concat(type, \"admin-nonce\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep).concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.admin_nonce);\n};\n\nvar Cache = /*#__PURE__*/function () {\n  function Cache() {\n    var _this = this;\n\n    _classCallCheck(this, Cache);\n\n    this.element = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-clear-cache]');\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('click', '[data-clear-cache]', function (event) {\n      return _this.clear(event, event.target);\n    });\n  }\n\n  _createClass(Cache, [{\n    key: \"clear\",\n    value: function clear(event, element) {\n      var _this2 = this;\n\n      var type = '';\n\n      if (event && event.preventDefault) {\n        event.preventDefault();\n      }\n\n      if (typeof event === 'string') {\n        type = event;\n      }\n\n      element = element ? jquery__WEBPACK_IMPORTED_MODULE_0___default()(element) : jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-clear-cache-type=\\\"\".concat(type, \"\\\"]\"));\n      type = type || jquery__WEBPACK_IMPORTED_MODULE_0___default()(element).data('clear-cache-type') || '';\n      var url = element.data('clearCache') || getUrl(type);\n      this.disable();\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, function () {\n        return _this2.enable();\n      });\n    }\n  }, {\n    key: \"enable\",\n    value: function enable() {\n      this.element.removeAttr('disabled').find('> .fa').removeClass('fa-refresh fa-spin fa-retweet').addClass('fa-retweet');\n    }\n  }, {\n    key: \"disable\",\n    value: function disable() {\n      this.element.attr('disabled', 'disabled').find('> .fa').removeClass('fa-retweet').addClass('fa-refresh fa-spin');\n    }\n  }]);\n\n  return Cache;\n}();\n\n\nvar Instance = new Cache();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4216 characters]\n//# sourceURL=webpack-internal:///./app/dashboard/cache.js\n");

/***/ }),

/***/ "./app/dashboard/chart.js":
/*!********************************!*\
  !*** ./app/dashboard/chart.js ***!
  \********************************/
/*! namespace exports */
/*! export Instances [provided] [no usage info] [missing usage info prevents renaming] */
/*! export UpdatesChart [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! export defaults [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"defaults\": () => /* binding */ defaults,\n/* harmony export */   \"default\": () => /* binding */ Chart,\n/* harmony export */   \"UpdatesChart\": () => /* binding */ UpdatesChart,\n/* harmony export */   \"Instances\": () => /* binding */ Instances\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var chartist__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! chartist */ \"./node_modules/chartist/dist/chartist.js\");\n/* harmony import */ var chartist__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(chartist__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _utils_gpm__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../utils/gpm */ \"./app/utils/gpm.js\");\n/* harmony import */ var _updates__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../updates */ \"./app/updates/index.js\");\nfunction _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _get(target, property, receiver) { if (typeof Reflect !== \"undefined\" && Reflect.get) { _get = Reflect.get; } else { _get = function _get(target, property, receiver) { var base = _superPropBase(target, property); if (!base) return; var desc = Object.getOwnPropertyDescriptor(base, property); if (desc.get) { return desc.get.call(receiver); } return desc.value; }; } return _get(target, property, receiver || target); }\n\nfunction _superPropBase(object, property) { while (!Object.prototype.hasOwnProperty.call(object, property)) { object = _getPrototypeOf(object); if (object === null) break; } return object; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function\"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }\n\nfunction _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) { return call; } return _assertThisInitialized(self); }\n\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nfunction _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\n // let isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;\n\nvar defaults = {\n  data: {\n    series: [100, 0]\n  },\n  options: {\n    Pie: {\n      donut: true,\n      donutWidth: 10,\n      startAngle: 0,\n      total: 100,\n      showLabel: false,\n      height: 150,\n      // chartPadding: !isFirefox ? 10 : 25 // workaround for older versions of firefox\n      chartPadding: 5\n    },\n    Bar: {\n      height: 164,\n      chartPadding: 20,\n      // workaround for older versions of firefox\n      axisX: {\n        showGrid: false,\n        labelOffset: {\n          x: 0,\n          y: 0\n        }\n      },\n      axisY: {\n        offset: 15,\n        showLabel: true,\n        showGrid: true,\n        labelOffset: {\n          x: 5,\n          y: 5\n        },\n        scaleMinSpace: 25\n      }\n    }\n  }\n};\n\nvar Chart = /*#__PURE__*/function () {\n  function Chart(element) {\n    var _this = this;\n\n    var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n    var data = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n\n    _classCallCheck(this, Chart);\n\n    this.element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element) || [];\n\n    if (!this.element[0]) {\n      return;\n    }\n\n    var type = (this.element.data('chart-type') || 'pie').toLowerCase();\n    this.type = type.charAt(0).toUpperCase() + type.substr(1).toLowerCase();\n    options = Object.assign({}, defaults.options[this.type], options);\n    data = Object.assign({}, defaults.data, data);\n    Object.assign(this, {\n      options: options,\n      data: data\n    });\n    this.chart = (chartist__WEBPACK_IMPORTED_MODULE_1___default())[this.type](this.element.find('.ct-chart').empty()[0], this.data, this.options);\n    this.chart.on('created', function () {\n      _this.element.find('.hidden').removeClass('hidden'); // FIX: workaround for chartist issue not allowing HTML in labels anymore\n      // https://github.com/gionkunz/chartist-js/issues/937\n\n\n      _this.element.find('.ct-label').each(function (index, label) {\n        label = jquery__WEBPACK_IMPORTED_MODULE_0___default()(label);\n        var text = label.html().replace('&lt;', '<').replace('&gt;', '>');\n        label.html(text);\n      });\n    });\n  }\n\n  _createClass(Chart, [{\n    key: \"updateData\",\n    value: function updateData(data) {\n      Object.assign(this.data, data);\n      this.chart.update(this.data);\n    }\n  }]);\n\n  return Chart;\n}();\n\n\n;\nvar UpdatesChart = /*#__PURE__*/function (_Chart) {\n  _inherits(UpdatesChart, _Chart);\n\n  var _super = _createSuper(UpdatesChart);\n\n  function UpdatesChart(element) {\n    var _this2;\n\n    var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n    var data = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n\n    _classCallCheck(this, UpdatesChart);\n\n    _this2 = _super.call(this, element, options, data);\n\n    _this2.chart.on('draw', function (data) {\n      return _this2.draw(data);\n    });\n\n    _utils_gpm__WEBPACK_IMPORTED_MODULE_3__.Instance.on('fetched', function (response) {\n      if (!response.payload) {\n        return;\n      }\n\n      var payload = response.payload.grav;\n      var missing = (response.payload.resources.total + (payload.isUpdatable ? 1 : 0)) * 100 / (response.payload.installed + (payload.isUpdatable ? 1 : 0));\n      var updated = 100 - missing;\n\n      _this2.updateData({\n        series: [updated, missing]\n      });\n\n      if (response.payload.resources.total) {\n        _updates__WEBPACK_IMPORTED_MODULE_4__.Instance.maintenance('show');\n      }\n    });\n    return _this2;\n  }\n\n  _createClass(UpdatesChart, [{\n    key: \"draw\",\n    value: function draw(data) {\n      if (data.index) {\n        return;\n      }\n\n      var notice = grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN[data.value === 100 ? 'FULLY_UPDATED' : 'UPDATES_AVAILABLE'];\n      this.element.find('.numeric span').text(\"\".concat(Math.round(data.value), \"%\"));\n      this.element.find('.js__updates-available-description').html(notice);\n      this.element.find('.hidden').removeClass('hidden');\n    }\n  }, {\n    key: \"updateData\",\n    value: function updateData(data) {\n      _get(_getPrototypeOf(UpdatesChart.prototype), \"updateData\", this).call(this, data); // missing updates\n\n\n      if (this.data.series[0] < 100) {\n        this.element.closest('#updates').find('[data-update-packages]').fadeIn();\n      }\n    }\n  }]);\n\n  return UpdatesChart;\n}(Chart);\nvar charts = {};\njquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-chart-name]').each(function () {\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n  var name = element.data('chart-name') || '';\n  var options = element.data('chart-options') || {};\n  var data = element.data('chart-data') || {};\n\n  if (name === 'updates') {\n    charts[name] = new UpdatesChart(element, options, data);\n  } else {\n    charts[name] = new Chart(element, options, data);\n  }\n});\nvar Instances = charts;//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 12720 characters]\n//# sourceURL=webpack-internal:///./app/dashboard/chart.js\n");

/***/ }),

/***/ "./app/dashboard/index.js":
/*!********************************!*\
  !*** ./app/dashboard/index.js ***!
  \********************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var _chart__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./chart */ \"./app/dashboard/chart.js\");\n/* harmony import */ var _cache__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./cache */ \"./app/dashboard/cache.js\");\n/* harmony import */ var _backup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./backup */ \"./app/dashboard/backup.js\");\n\n\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({\n  Chart: {\n    Chart: _chart__WEBPACK_IMPORTED_MODULE_0__.default,\n    UpdatesChart: _chart__WEBPACK_IMPORTED_MODULE_0__.UpdatesChart,\n    Instances: _chart__WEBPACK_IMPORTED_MODULE_0__.Instances\n  },\n  Cache: _cache__WEBPACK_IMPORTED_MODULE_1__.Instance\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL2Rhc2hib2FyZC9pbmRleC5qcz9hMTk1Il0sIm5hbWVzIjpbIkNoYXJ0IiwiVXBkYXRlc0NoYXJ0IiwiSW5zdGFuY2VzIiwiQ2FjaGUiXSwibWFwcGluZ3MiOiI7Ozs7Ozs7QUFBQTtBQUNBO0FBQ0E7QUFFQSxpRUFBZTtBQUNYQSxPQUFLLEVBQUU7QUFDSEEsU0FBSyxFQUFMQSwyQ0FERztBQUVIQyxnQkFBWSxFQUFaQSxnREFGRztBQUdIQyxhQUFTLEVBQVRBLDZDQUFTQTtBQUhOLEdBREk7QUFNWEMsT0FBSyxFQUFMQSw0Q0FBS0E7QUFOTSxDQUFmIiwiZmlsZSI6Ii4vYXBwL2Rhc2hib2FyZC9pbmRleC5qcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBDaGFydCwgeyBVcGRhdGVzQ2hhcnQsIEluc3RhbmNlcyB9IGZyb20gJy4vY2hhcnQnO1xuaW1wb3J0IHsgSW5zdGFuY2UgYXMgQ2FjaGUgfSBmcm9tICcuL2NhY2hlJztcbmltcG9ydCAnLi9iYWNrdXAnO1xuXG5leHBvcnQgZGVmYXVsdCB7XG4gICAgQ2hhcnQ6IHtcbiAgICAgICAgQ2hhcnQsXG4gICAgICAgIFVwZGF0ZXNDaGFydCxcbiAgICAgICAgSW5zdGFuY2VzXG4gICAgfSxcbiAgICBDYWNoZVxufTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/dashboard/index.js\n");

/***/ }),

/***/ "./app/forms/fields/acl-picker.js":
/*!****************************************!*\
  !*** ./app/forms/fields/acl-picker.js ***!
  \****************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\nvar body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\nbody.on('change', '[data-acl_picker] select', function (event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var value = target.val();\n  var item = target.closest('.permissions-item');\n  var inputs = item.find('input[type=\"checkbox\"], input[type=\"radio\"]');\n  var hidden = item.find('input[type=\"hidden\"][name]');\n  var wrapper = target.closest('[data-acl_picker_id]');\n  var type = item.data('fieldType');\n\n  if (type === 'access') {\n    inputs.each(function (index, input) {\n      input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(input);\n      var name = input.prop('name');\n      input.prop('name', name.replace(/(.*)(\\[[^\\]]*\\])/, \"$1[\".concat(value, \"]\")));\n    });\n  } else if (type === 'permissions') {\n    var crudpContainer = item.find('[data-field-name]');\n    inputs.each(function (index, input) {\n      input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(input);\n      var rand = Math.round(Math.random() * 500);\n      var name = crudpContainer.data('fieldName');\n      var id = input.prop('id').split('_').slice(0, -1).join('_') + \"_\".concat(value, \"+\").concat(rand); // const key = input.data('crudpKey');\n\n      hidden.prop('name', name.replace(/(.*)(\\[[^\\]]*\\])/, \"$1[\".concat(value, \"]\")));\n      input.prop('id', id);\n      input.next('label').prop('for', id);\n    });\n  }\n\n  wrapper.find('.permissions-item .button.add-item')[!value ? 'addClass' : 'removeClass']('disabled').prop('disabled', !value ? 'disabled' : null);\n});\nbody.on('input', 'input[data-crudp-key]', function (event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var container = target.closest('.crudp-container');\n  var hidden = container.find('input[type=\"hidden\"][name]');\n  var key = target.data('crudpKey');\n  var json = JSON.parse(hidden.val() || '{}');\n  json[key] = target.val();\n  hidden.val(JSON.stringify(json));\n});\nbody.on('click', '[data-acl_picker] .remove-item', function (event) {\n  event.preventDefault();\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var container = target.closest('.permissions-item');\n  var wrapper = target.closest('[data-acl_picker_id]');\n  container.remove();\n  var empty = wrapper.find('.permissions-item').length === 1; // show the initial + button\n\n  if (empty) {\n    wrapper.find('.permissions-item.empty-list').removeClass('hidden');\n  }\n});\nbody.on('click', '[data-acl_picker] .add-item', function (event) {\n  event.preventDefault();\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var item = target.closest('.permissions-item');\n  var wrapper = target.closest('[data-acl_picker_id]');\n  var ID = wrapper.data('acl_picker_id');\n  var template = document.querySelector(\"template[data-id=\\\"acl_picker-\".concat(ID, \"\\\"]\"));\n  var clone = jquery__WEBPACK_IMPORTED_MODULE_0___default()(template.content.firstElementChild).clone();\n  clone.insertAfter(item); // randomize ids\n\n  clone.find('.switch-toggle input[type=\"radio\"]').each(function (index, input) {\n    input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(input);\n    var id = input.prop('id');\n    var label = input.next('label');\n    var rand = (Date.now().toString(36) + Math.random().toString(36).substr(2, 5)).toLowerCase();\n    input.prop('id', \"\".concat(id).concat(rand));\n    label.prop('for', \"\".concat(id).concat(rand));\n  }); // hide the initial + button\n\n  wrapper.find('.permissions-item.empty-list').addClass('hidden'); // disable all + buttons until one is selected\n\n  wrapper.find('.permissions-item .button.add-item').addClass('disabled').prop('disabled', 'disabled');\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 10924 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/acl-picker.js\n");

/***/ }),

/***/ "./app/forms/fields/array.js":
/*!***********************************!*\
  !*** ./app/forms/fields/array.js ***!
  \***********************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ ArrayField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var sortablejs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! sortablejs */ \"./node_modules/sortablejs/modular/sortable.complete.esm.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\nvar body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\n\nvar Template = /*#__PURE__*/function () {\n  function Template(container) {\n    _classCallCheck(this, Template);\n\n    this.container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(container);\n\n    if (this.getName() === undefined) {\n      this.container = this.container.closest('[data-grav-array-name]');\n    }\n  }\n\n  _createClass(Template, [{\n    key: \"getName\",\n    value: function getName() {\n      return this.container.data('grav-array-name') || '';\n    }\n  }, {\n    key: \"getKeyPlaceholder\",\n    value: function getKeyPlaceholder() {\n      return this.container.data('grav-array-keyname') || 'Key';\n    }\n  }, {\n    key: \"getValuePlaceholder\",\n    value: function getValuePlaceholder() {\n      return this.container.data('grav-array-valuename') || 'Value';\n    }\n  }, {\n    key: \"isValueOnly\",\n    value: function isValueOnly() {\n      return this.container.find('[data-grav-array-mode=\"value_only\"]:first').length || false;\n    }\n  }, {\n    key: \"isTextArea\",\n    value: function isTextArea() {\n      return this.container.data('grav-array-textarea') || false;\n    }\n  }, {\n    key: \"shouldBeDisabled\",\n    value: function shouldBeDisabled() {\n      // check for toggleables, if field is toggleable and it's not enabled, render disabled\n      var toggle = this.container.closest('.form-field').find('[data-grav-field=\"toggleable\"] input[type=\"checkbox\"]');\n      return toggle.length && toggle.is(':not(:checked)');\n    }\n  }, {\n    key: \"getNewRow\",\n    value: function getNewRow() {\n      var tpl = '';\n      var value = this.isTextArea() ? \"<textarea \".concat(this.shouldBeDisabled() ? 'disabled=\"disabled\"' : '', \" data-grav-array-type=\\\"value\\\" name=\\\"\\\" placeholder=\\\"\").concat(this.getValuePlaceholder(), \"\\\"></textarea>\") : \"<input \".concat(this.shouldBeDisabled() ? 'disabled=\"disabled\"' : '', \" data-grav-array-type=\\\"value\\\" type=\\\"text\\\" name=\\\"\\\" value=\\\"\\\"  placeholder=\\\"\").concat(this.getValuePlaceholder(), \"\\\" />\");\n\n      if (this.isValueOnly()) {\n        tpl += \"\\n            <div class=\\\"form-row array-field-value_only\\\" data-grav-array-type=\\\"row\\\">\\n                <span data-grav-array-action=\\\"sort\\\" class=\\\"fa fa-bars\\\"></span>\\n                \".concat(value, \"\\n            \");\n      } else {\n        tpl += \"\\n            <div class=\\\"form-row\\\" data-grav-array-type=\\\"row\\\">\\n                <span data-grav-array-action=\\\"sort\\\" class=\\\"fa fa-bars\\\"></span>\\n                <input \".concat(this.shouldBeDisabled() ? 'disabled=\"disabled\"' : '', \" data-grav-array-type=\\\"key\\\" type=\\\"text\\\" value=\\\"\\\" placeholder=\\\"\").concat(this.getKeyPlaceholder(), \"\\\" />\\n                \").concat(value, \"\\n            \");\n      }\n\n      tpl += \"\\n            <span data-grav-array-action=\\\"rem\\\" class=\\\"fa fa-minus\\\"></span>\\n            <span data-grav-array-action=\\\"add\\\" class=\\\"fa fa-plus\\\"></span>\\n        </div>\";\n      return tpl;\n    }\n  }]);\n\n  return Template;\n}();\n\nvar ArrayField = /*#__PURE__*/function () {\n  function ArrayField() {\n    var _this = this;\n\n    _classCallCheck(this, ArrayField);\n\n    body.on('input', '[data-grav-array-type=\"key\"], [data-grav-array-type=\"value\"]', function (event) {\n      return _this.actionInput(event);\n    });\n    body.on('click touch', '[data-grav-array-action]:not([data-grav-array-action=\"sort\"])', function (event) {\n      return _this.actionEvent(event);\n    });\n    this.arrays = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-field=\"array\"]').each(function (index, list) {\n      return _this.addArray(list);\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('mutation._grav', this._onAddedNodes.bind(this));\n  }\n\n  _createClass(ArrayField, [{\n    key: \"addArray\",\n    value: function addArray(list) {\n      var _this2 = this;\n\n      list = jquery__WEBPACK_IMPORTED_MODULE_0___default()(list);\n      list.find('[data-grav-array-type=\"container\"]').each(function (index, container) {\n        container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(container);\n\n        if (container.data('array-sort') || container[0].hasAttribute('data-array-nosort')) {\n          return;\n        }\n\n        container.data('array-sort', new sortablejs__WEBPACK_IMPORTED_MODULE_1__.default(container.get(0), {\n          handle: '.fa-bars',\n          animation: 150,\n          onUpdate: function onUpdate() {\n            var item = container.find('[data-grav-array-type=\"row\"]:first');\n\n            _this2._setTemplate(item);\n\n            var template = item.data('array-template');\n\n            _this2.refreshNames(template);\n          }\n        }));\n      });\n    }\n  }, {\n    key: \"actionInput\",\n    value: function actionInput(event) {\n      var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n      var type = element.data('grav-array-type');\n\n      this._setTemplate(element);\n\n      var template = element.data('array-template');\n      var keyElement = type === 'key' ? element : element.siblings('[data-grav-array-type=\"key\"]:first');\n      var valueElement = type === 'value' ? element : element.siblings('[data-grav-array-type=\"value\"]:first');\n      var escaped_name = !template.isValueOnly() ? keyElement.val() : this.getIndexFor(element);\n      escaped_name = escaped_name.toString().replace(/\\[/g, '%5B').replace(/]/g, '%5D');\n      var name = \"\".concat(template.getName(), \"[\").concat(escaped_name, \"]\");\n\n      if (!template.isValueOnly() && !keyElement.val() && !valueElement.val()) {\n        valueElement.attr('name', '');\n      } else {\n        // valueElement.attr('name', !valueElement.val() ? template.getName() : name);\n        valueElement.attr('name', name);\n      }\n\n      this.refreshNames(template);\n    }\n  }, {\n    key: \"actionEvent\",\n    value: function actionEvent(event) {\n      event && event.preventDefault();\n      var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n      var action = element.data('grav-array-action');\n      var container = element.parents('[data-grav-array-type=\"container\"]');\n\n      this._setTemplate(element);\n\n      this[\"\".concat(action, \"Action\")](element);\n      var siblings = container.find('> div');\n      container[siblings.length > 1 ? 'removeClass' : 'addClass']('one-child');\n    }\n  }, {\n    key: \"addAction\",\n    value: function addAction(element) {\n      var template = element.data('array-template');\n      var row = element.closest('[data-grav-array-type=\"row\"]');\n      row.after(template.getNewRow());\n    }\n  }, {\n    key: \"remAction\",\n    value: function remAction(element) {\n      var template = element.data('array-template');\n      var row = element.closest('[data-grav-array-type=\"row\"]');\n      var isLast = !row.siblings().length;\n\n      if (isLast) {\n        var newRow = jquery__WEBPACK_IMPORTED_MODULE_0___default()(template.getNewRow());\n        row.after(newRow);\n        newRow.find('[data-grav-array-type=\"value\"]:last').attr('name', template.getName());\n      }\n\n      row.remove();\n      this.refreshNames(template);\n    }\n  }, {\n    key: \"refreshNames\",\n    value: function refreshNames(template) {\n      if (!template.isValueOnly()) {\n        return;\n      }\n\n      var row = template.container.find('> div > [data-grav-array-type=\"row\"]');\n      var inputs = row.find('[name]:not([name=\"\"])');\n      inputs.each(function (index, input) {\n        input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(input);\n        var preserved_name = input.closest('[data-grav-array-name]');\n        var name = \"\".concat(preserved_name.attr('data-grav-array-name'), \"[\").concat(index, \"]\");\n        input.attr('name', name);\n      });\n\n      if (!inputs.length) {\n        row.find('[data-grav-array-type=\"value\"]').attr('name', template.getName());\n      }\n    }\n  }, {\n    key: \"getIndexFor\",\n    value: function getIndexFor(element) {\n      var template = element.data('array-template');\n      var row = element.closest('[data-grav-array-type=\"row\"]');\n      return template.container.find(\"\".concat(template.isValueOnly() ? '> div ' : '', \" > [data-grav-array-type=\\\"row\\\"]\")).index(row);\n    }\n  }, {\n    key: \"_setTemplate\",\n    value: function _setTemplate(element) {\n      if (!element.data('array-template')) {\n        element.data('array-template', new Template(element.closest('[data-grav-array-name]')));\n      }\n    }\n  }, {\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target\n    /* , record, instance */\n    ) {\n      var _this3 = this;\n\n      var arrays = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('[data-grav-field=\"array\"]');\n\n      if (!arrays.length) {\n        return;\n      }\n\n      arrays.each(function (index, list) {\n        list = jquery__WEBPACK_IMPORTED_MODULE_0___default()(list);\n\n        if (!~_this3.arrays.index(list)) {\n          _this3.addArray(list);\n        }\n      });\n    }\n  }]);\n\n  return ArrayField;\n}();\n\n\nvar Instance = new ArrayField();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 19400 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/array.js\n");

/***/ }),

/***/ "./app/forms/fields/collections.js":
/*!*****************************************!*\
  !*** ./app/forms/fields/collections.js ***!
  \*****************************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ CollectionsField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var sortablejs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! sortablejs */ \"./node_modules/sortablejs/modular/sortable.complete.esm.js\");\n/* harmony import */ var _utils_jquery_utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../utils/jquery-utils */ \"./app/utils/jquery-utils.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar CollectionsField = /*#__PURE__*/function () {\n  function CollectionsField() {\n    var _this = this;\n\n    _classCallCheck(this, CollectionsField);\n\n    this.lists = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-type=\"collection\"]').each(function (index, list) {\n      return _this.addList(list);\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('mutation._grav', this._onAddedNodes.bind(this));\n  }\n\n  _createClass(CollectionsField, [{\n    key: \"addList\",\n    value: function addList(list) {\n      var _this2 = this;\n\n      list = jquery__WEBPACK_IMPORTED_MODULE_0___default()(list);\n      this.lists = this.lists.add(list);\n      list.on('click', '> .collection-actions [data-action=\"add\"]', function (event) {\n        return _this2.addItem(event);\n      });\n      list.on('click', '> ul > li > .item-actions [data-action=\"delete\"]', function (event) {\n        return _this2.removeItem(event);\n      });\n      list.on('click', '> ul > li > .item-actions [data-action=\"collapse\"]', function (event) {\n        return _this2.collapseItem(event);\n      });\n      list.on('click', '> ul > li > .item-actions [data-action=\"expand\"]', function (event) {\n        return _this2.expandItem(event);\n      });\n      list.on('click', '> .collection-actions [data-action-sort=\"date\"]', function (event) {\n        return _this2.sortItems(event);\n      });\n      list.on('click', '> .collection-actions [data-action=\"collapse_all\"]', function (event) {\n        return _this2.collapseItems(event);\n      });\n      list.on('click', '> .collection-actions [data-action=\"expand_all\"]', function (event) {\n        return _this2.expandItems(event);\n      });\n      list.on('input change', '[data-key-observe]', function (event) {\n        return _this2.observeKey(event);\n      });\n      list.find('[data-collection-holder]').each(function (index, container) {\n        container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(container);\n\n        if (container.data('collection-sort') || container[0].hasAttribute('data-collection-nosort')) {\n          return;\n        }\n\n        container.data('collection-sort', new sortablejs__WEBPACK_IMPORTED_MODULE_1__.default(container.get(0), {\n          forceFallback: false,\n          handle: '.collection-sort',\n          animation: 150,\n          onUpdate: function onUpdate() {\n            return _this2.reindex(container);\n          }\n        }));\n      });\n\n      this._updateActionsStateBasedOnMinMax(list);\n    }\n  }, {\n    key: \"addItem\",\n    value: function addItem(event) {\n      var button = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      var position = button.data('action-add') || 'bottom';\n      var list = jquery__WEBPACK_IMPORTED_MODULE_0___default()(button.closest('[data-type=\"collection\"]'));\n      var template = jquery__WEBPACK_IMPORTED_MODULE_0___default()(list.find('> [data-collection-template=\"new\"]').data('collection-template-html'));\n\n      this._updateActionsStateBasedOnMinMax(list);\n\n      var items = list.closest('[data-type=\"collection\"]').find('> ul > [data-collection-item]');\n      var maxItems = list.data('max');\n\n      if (typeof maxItems !== 'undefined' && items.length >= maxItems) {\n        return;\n      }\n\n      list.find('> [data-collection-holder]')[position === 'top' ? 'prepend' : 'append'](template);\n      this.reindex(list);\n      items = list.closest('[data-type=\"collection\"]').find('> ul > [data-collection-item]');\n      var topAction = list.closest('[data-type=\"collection\"]').find('[data-action-add=\"top\"]');\n      var sortAction = list.closest('[data-type=\"collection\"]').find('[data-action=\"sort\"]');\n\n      if (items.length) {\n        if (topAction.length) {\n          topAction.parent().removeClass('hidden');\n        }\n\n        if (sortAction.length && items.length > 1) {\n          sortAction.removeClass('hidden');\n        }\n      } // refresh toggleables in a list\n\n\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-field=\"toggleable\"] input[type=\"checkbox\"]').trigger('change');\n    }\n  }, {\n    key: \"removeItem\",\n    value: function removeItem(event) {\n      var button = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      var item = button.closest('[data-collection-item]');\n      var list = jquery__WEBPACK_IMPORTED_MODULE_0___default()(button.closest('[data-type=\"collection\"]'));\n      var items = list.closest('[data-type=\"collection\"]').find('> ul > [data-collection-item]');\n      var minItems = list.data('min');\n\n      if (typeof minItems !== 'undefined' && items.length <= minItems) {\n        return;\n      }\n\n      item.remove();\n      this.reindex(list);\n      items = list.closest('[data-type=\"collection\"]').find('> ul > [data-collection-item]');\n      var topAction = list.closest('[data-type=\"collection\"]').find('[data-action-add=\"top\"]');\n      var sortAction = list.closest('[data-type=\"collection\"]').find('[data-action=\"sort\"]');\n\n      if (!items.length) {\n        if (topAction.length) {\n          topAction.parent().addClass('hidden');\n        }\n      }\n\n      if (sortAction.length && items.length <= 1) {\n        sortAction.addClass('hidden');\n      }\n\n      this._updateActionsStateBasedOnMinMax(list);\n    }\n  }, {\n    key: \"collapseItems\",\n    value: function collapseItems(event) {\n      var button = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      var items = jquery__WEBPACK_IMPORTED_MODULE_0___default()(button.closest('[data-type=\"collection\"]')).find('> ul > [data-collection-item] > .item-actions [data-action=\"collapse\"]');\n      items.click();\n    }\n  }, {\n    key: \"collapseItem\",\n    value: function collapseItem(event) {\n      var button = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      var item = button.closest('[data-collection-item]');\n      button.attr('data-action', 'expand').removeClass('fa-chevron-circle-down').addClass('fa-chevron-circle-right');\n      item.addClass('collection-collapsed');\n    }\n  }, {\n    key: \"expandItems\",\n    value: function expandItems(event) {\n      var button = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      var items = jquery__WEBPACK_IMPORTED_MODULE_0___default()(button.closest('[data-type=\"collection\"]')).find('> ul > [data-collection-item] > .item-actions [data-action=\"expand\"]');\n      items.click();\n    }\n  }, {\n    key: \"expandItem\",\n    value: function expandItem(event) {\n      var button = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      var item = button.closest('[data-collection-item]');\n      button.attr('data-action', 'collapse').removeClass('fa-chevron-circle-right').addClass('fa-chevron-circle-down');\n      item.removeClass('collection-collapsed');\n    }\n  }, {\n    key: \"sortItems\",\n    value: function sortItems(event) {\n      var button = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      var sortby = button.data('action-sort');\n      var sortby_dir = button.data('action-sort-dir') || 'asc';\n      var list = jquery__WEBPACK_IMPORTED_MODULE_0___default()(button.closest('[data-type=\"collection\"]'));\n      var items = list.closest('[data-type=\"collection\"]').find('> ul > [data-collection-item]');\n      items.sort(function (a, b) {\n        var A = jquery__WEBPACK_IMPORTED_MODULE_0___default()(a).find('[name$=\"[' + sortby + ']\"]');\n        var B = jquery__WEBPACK_IMPORTED_MODULE_0___default()(b).find('[name$=\"[' + sortby + ']\"]');\n        var sort;\n\n        if (sortby_dir === 'asc') {\n          sort = A.val() < B.val() ? -1 : A.val() > B.val() ? 1 : 0;\n        } else {\n          sort = A.val() > B.val() ? -1 : A.val() < B.val() ? 1 : 0;\n        }\n\n        return sort;\n      }).each(function (_, container) {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()(container).parent().append(container);\n      });\n      this.reindex(list);\n    }\n  }, {\n    key: \"observeKey\",\n    value: function observeKey(event) {\n      var input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n      var value = input.val();\n      var item = input.closest('[data-collection-key]');\n      item.data('collection-key-backup', item.data('collection-key')).data('collection-key', value);\n      this.reindex(null, item);\n    }\n  }, {\n    key: \"reindex\",\n    value: function reindex(list, items) {\n      items = items || jquery__WEBPACK_IMPORTED_MODULE_0___default()(list).closest('[data-type=\"collection\"]').find('> ul > [data-collection-item]');\n      items.each(function (index, item) {\n        item = jquery__WEBPACK_IMPORTED_MODULE_0___default()(item);\n        var observed = item.find('[data-key-observe]');\n        var observedValue = observed.val();\n        var hasCustomKey = observed.length;\n        var currentKey = item.data('collection-key-backup');\n        item.attr('data-collection-key', hasCustomKey ? observedValue : index);\n        ['name', 'data-grav-field-name', 'for', 'id', 'data-grav-file-settings', 'data-grav-array-name'].forEach(function (prop) {\n          item.find('[' + prop + '], [_' + prop + ']').each(function () {\n            var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n            var indexes = [];\n            var array_index = null;\n            var regexps = [new RegExp('\\\\[(\\\\d+|\\\\*|' + currentKey + ')\\\\]', 'g'), new RegExp('\\\\.(\\\\d+|\\\\*|' + currentKey + ')\\\\.', 'g')]; // special case to preserve array field index keys\n\n            if (prop === 'name' && element.data('gravArrayType')) {\n              var match_index = element.attr(prop).match(/\\[[0-9]{1,}\\]$/);\n              var pattern = element[0].closest('[data-grav-array-name]').dataset.gravArrayName;\n\n              if (match_index && pattern) {\n                array_index = match_index[0];\n                element.attr(prop, \"\".concat(pattern).concat(match_index[0]));\n                return;\n              }\n            }\n\n            if (hasCustomKey && !observedValue) {\n              element.attr(\"_\".concat(prop), element.attr(prop));\n              element.attr(prop, null);\n              return;\n            }\n\n            if (element.attr(\"_\".concat(prop))) {\n              element.attr(prop, element.attr(\"_\".concat(prop)));\n              element.attr(\"_\".concat(prop), null);\n            }\n\n            element.parents('[data-collection-key]').map(function (idx, parent) {\n              return indexes.push(jquery__WEBPACK_IMPORTED_MODULE_0___default()(parent).attr('data-collection-key'));\n            });\n            indexes.reverse();\n            var matchedKey = currentKey;\n            var replaced = element.attr(prop).replace(regexps[0], function ()\n            /* str, p1, offset */\n            {\n              var extras = '';\n\n              if (array_index) {\n                extras = array_index;\n                console.log(indexes, extras);\n              }\n\n              matchedKey = indexes.shift() || matchedKey;\n              return \"[\".concat(matchedKey, \"]\").concat(extras);\n            });\n            replaced = replaced.replace(regexps[1], function ()\n            /* str, p1, offset */\n            {\n              matchedKey = indexes.shift() || matchedKey;\n              return \".\".concat(matchedKey, \".\");\n            });\n            element.attr(prop, replaced);\n          });\n        });\n      });\n    }\n  }, {\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target\n    /* , record, instance */\n    ) {\n      var _this3 = this;\n\n      var collections = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('[data-type=\"collection\"]');\n\n      if (!collections.length) {\n        return;\n      }\n\n      collections.each(function (index, collection) {\n        collection = jquery__WEBPACK_IMPORTED_MODULE_0___default()(collection);\n\n        if (!~_this3.lists.index(collection)) {\n          _this3.addList(collection);\n        }\n      });\n    }\n  }, {\n    key: \"_updateActionsStateBasedOnMinMax\",\n    value: function _updateActionsStateBasedOnMinMax(list) {\n      var items = list.closest('[data-type=\"collection\"]').find('> ul > [data-collection-item]');\n      var minItems = list.data('min');\n      var maxItems = list.data('max');\n      list.find('> .collection-actions [data-action=\"add\"]').attr('disabled', false);\n      list.find('> ul > li > .item-actions [data-action=\"delete\"]').attr('disabled', false);\n\n      if (typeof minItems !== 'undefined' && items.length <= minItems) {\n        list.find('> ul > li > .item-actions [data-action=\"delete\"]').attr('disabled', true);\n      }\n\n      if (typeof maxItems !== 'undefined' && items.length >= maxItems) {\n        list.find('> .collection-actions [data-action=\"add\"]').attr('disabled', true);\n      }\n    }\n  }]);\n\n  return CollectionsField;\n}();\n\n\nvar Instance = new CollectionsField();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 30368 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/collections.js\n");

/***/ }),

/***/ "./app/forms/fields/colorpicker.js":
/*!*****************************************!*\
  !*** ./app/forms/fields/colorpicker.js ***!
  \*****************************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ ColorpickerField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var mout_math_clamp__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! mout/math/clamp */ \"./node_modules/mout/math/clamp.js\");\n/* harmony import */ var mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(mout_math_clamp__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var mout_function_bind__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! mout/function/bind */ \"./node_modules/mout/function/bind.js\");\n/* harmony import */ var mout_function_bind__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(mout_function_bind__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _utils_colors__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../utils/colors */ \"./app/utils/colors.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;\nvar body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\nvar MOUSEDOWN = 'mousedown touchstart MSPointerDown pointerdown';\nvar MOUSEMOVE = 'mousemove touchmove MSPointerMove pointermove';\nvar MOUSEUP = 'mouseup touchend MSPointerUp pointerup';\nvar FOCUSIN = isFirefox ? 'focus' : 'focusin';\n\nvar ColorpickerField = /*#__PURE__*/function () {\n  function ColorpickerField(selector) {\n    var _this = this;\n\n    _classCallCheck(this, ColorpickerField);\n\n    this.selector = selector;\n    this.field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.selector);\n    this.options = Object.assign({}, this.field.data('grav-colorpicker'));\n    this.built = false;\n    this.attach();\n\n    if (this.options.update) {\n      this.field.on('change._grav_colorpicker', function (event, field, hex, opacity) {\n        var backgroundColor = hex;\n        var rgb = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hex2rgb)(hex);\n\n        if (opacity < 1) {\n          backgroundColor = 'rgba(' + rgb.r + ', ' + rgb.g + ', ' + rgb.b + ', ' + opacity + ')';\n        }\n\n        var target = field.closest(_this.options.update);\n\n        if (!target.length) {\n          target = field.siblings(_this.options.update);\n        }\n\n        if (!target.length) {\n          target = field.parent('.g-colorpicker').find(_this.options.update);\n        }\n\n        target.css({\n          backgroundColor: backgroundColor\n        });\n      });\n    }\n  }\n\n  _createClass(ColorpickerField, [{\n    key: \"attach\",\n    value: function attach() {\n      var _this2 = this;\n\n      body.on(FOCUSIN, this.selector, function (event) {\n        return _this2.show(event, event.currentTarget);\n      });\n      body.on(MOUSEDOWN, this.selector + ' .g-colorpicker, ' + this.selector + ' .g-colorpicker i', this.bound('iconClick'));\n      body.on('keydown', this.selector, function (event) {\n        switch (event.keyCode) {\n          case 9:\n            // tab\n            _this2.hide();\n\n            break;\n\n          case 13: // enter\n\n          case 27:\n            // esc\n            _this2.hide();\n\n            event.currentTarget.blur();\n            break;\n        }\n\n        return true;\n      }); // Update on keyup\n\n      body.on('keyup', this.selector, function (event) {\n        _this2.updateFromInput(true, event.currentTarget);\n\n        return true;\n      }); // Update on paste\n\n      body.on('paste', this.selector, function (event) {\n        setTimeout(function () {\n          return _this2.updateFromInput(true, event.currentTarget);\n        }, 1);\n      });\n    }\n  }, {\n    key: \"show\",\n    value: function show(event, target) {\n      target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target);\n\n      if (!this.built) {\n        this.build();\n      }\n\n      this.element = target;\n      this.reposition();\n      this.wrapper.addClass('cp-visible');\n      this.updateFromInput();\n      this.wrapper.on(MOUSEDOWN, '.cp-grid, .cp-slider, .cp-opacity-slider', this.bound('bodyDown'));\n      body.on(MOUSEMOVE, this.bound('bodyMove'));\n      body.on(MOUSEDOWN, this.bound('bodyClick'));\n      body.on(MOUSEUP, this.bound('targetReset'));\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('#admin-main > .content-wrapper').on('scroll', this.bound('reposition'));\n    }\n  }, {\n    key: \"hide\",\n    value: function hide() {\n      if (!this.built) {\n        return;\n      }\n\n      this.wrapper.removeClass('cp-visible');\n      this.wrapper.undelegate(MOUSEDOWN, '.cp-grid, .cp-slider, .cp-opacity-slider', this.bound('bodyDown'));\n      body.off(MOUSEMOVE, this.bound('bodyMove'));\n      body.off(MOUSEDOWN, this.bound('bodyClick'));\n      body.off(MOUSEUP, this.bound('targetReset'));\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('#admin-main > .content-wrapper').on('scroll', this.bound('reposition'));\n    }\n  }, {\n    key: \"build\",\n    value: function build() {\n      var _this3 = this;\n\n      this.wrapper = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-wrapper cp-with-opacity cp-mode-hue\" />');\n      this.slider = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-slider cp-sprite\" />').appendTo(this.wrapper).append(jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-picker\" />'));\n      this.opacitySlider = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-opacity-slider cp-sprite\" />').appendTo(this.wrapper).append(jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-picker\" />'));\n      this.grid = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-grid cp-sprite\" />').appendTo(this.wrapper).append(jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-grid-inner\" />')).append(jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-picker\" />'));\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div />').appendTo(this.grid.find('.cp-picker'));\n      var tabs = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-tabs\" />').appendTo(this.wrapper);\n      this.tabs = {\n        hue: jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-tab-hue active\" />').text('HUE').appendTo(tabs),\n        brightness: jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-tab-brightness\" />').text('BRI').appendTo(tabs),\n        saturation: jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-tab-saturation\" />').text('SAT').appendTo(tabs),\n        wheel: jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-tab-wheel\" />').text('WHEEL').appendTo(tabs),\n        transparent: jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"cp-tab-transp\" />').text('TRANSPARENT').appendTo(tabs)\n      };\n      tabs.on(MOUSEDOWN, '> div', function (event) {\n        var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n\n        if (element.is(_this3.tabs.transparent)) {\n          var sliderHeight = _this3.opacitySlider.height();\n\n          _this3.opacity = 0;\n\n          _this3.opacitySlider.find('.cp-picker').css({\n            'top': mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(sliderHeight - sliderHeight * _this3.opacity, 0, sliderHeight)\n          });\n\n          _this3.move(_this3.opacitySlider, {\n            manualOpacity: true\n          });\n\n          return;\n        }\n\n        var active = tabs.find('.active');\n        var mode = active.attr('class').replace(/\\s|active|cp-tab-/g, '');\n        var newMode = element.attr('class').replace(/\\s|active|cp-tab-/g, '');\n\n        _this3.wrapper.removeClass('cp-mode-' + mode).addClass('cp-mode-' + newMode);\n\n        active.removeClass('active');\n        element.addClass('active');\n        _this3.mode = newMode;\n\n        _this3.updateFromInput();\n      });\n      this.wrapper.appendTo('.content-wrapper');\n      this.built = true;\n      this.mode = 'hue';\n    }\n  }, {\n    key: \"reposition\",\n    value: function reposition() {\n      var ct = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.content-wrapper')[0];\n      var offset = this.element[0].getBoundingClientRect();\n      var ctOffset = ct.getBoundingClientRect();\n      var delta = {\n        x: 0,\n        y: 0\n      };\n\n      if (this.options.offset) {\n        delta.x = this.options.offset.x || 0;\n        delta.y = this.options.offset.y || 0;\n      }\n\n      this.wrapper.css({\n        top: offset.top + offset.height + ct.scrollTop - ctOffset.top + delta.y,\n        left: offset.left + ct.scrollLeft - ctOffset.left + delta.x\n      });\n    }\n  }, {\n    key: \"iconClick\",\n    value: function iconClick(event) {\n      if (this.wrapper && this.wrapper.hasClass('cp-visible')) {\n        return true;\n      }\n\n      event && event.preventDefault();\n      var input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget).find('input');\n      setTimeout(function () {\n        return input.focus();\n      }, 50);\n    }\n  }, {\n    key: \"bodyMove\",\n    value: function bodyMove(event) {\n      event && event.preventDefault();\n\n      if (this.target) {\n        this.move(this.target, event);\n      }\n    }\n  }, {\n    key: \"bodyClick\",\n    value: function bodyClick(event) {\n      var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n\n      if (!target.closest('.cp-wrapper').length && !target.is(this.selector)) {\n        this.hide();\n      }\n    }\n  }, {\n    key: \"bodyDown\",\n    value: function bodyDown(event) {\n      event && event.preventDefault();\n      this.target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      this.move(this.target, event, true);\n    }\n  }, {\n    key: \"targetReset\",\n    value: function targetReset(event) {\n      event && event.preventDefault();\n      this.target = null;\n    }\n  }, {\n    key: \"move\",\n    value: function move(target, event) {\n      var input = this.element;\n      var picker = target.find('.cp-picker');\n      var clientRect = target[0].getBoundingClientRect();\n      var offsetX = clientRect.left + window.scrollX;\n      var offsetY = clientRect.top + window.scrollY;\n      var x = Math.round((event ? event.pageX : 0) - offsetX);\n      var y = Math.round((event ? event.pageY : 0) - offsetY);\n      var wx;\n      var wy;\n      var r;\n      var phi; // Touch support\n\n      var touchEvents = event.changedTouches || event.originalEvent && event.originalEvent.changedTouches;\n\n      if (event && touchEvents) {\n        x = (touchEvents ? touchEvents[0].pageX : 0) - offsetX;\n        y = (touchEvents ? touchEvents[0].pageY : 0) - offsetY;\n      }\n\n      if (event && event.manualOpacity) {\n        y = clientRect.height;\n      } // Constrain picker to its container\n\n\n      if (x < 0) x = 0;\n      if (y < 0) y = 0;\n      if (x > clientRect.width) x = clientRect.width;\n      if (y > clientRect.height) y = clientRect.height; // Constrain color wheel values to the wheel\n\n      if (target.parent('.cp-mode-wheel').length && picker.parent('.cp-grid').length) {\n        wx = 75 - x;\n        wy = 75 - y;\n        r = Math.sqrt(wx * wx + wy * wy);\n        phi = Math.atan2(wy, wx);\n        if (phi < 0) phi += Math.PI * 2;\n\n        if (r > 75) {\n          x = 75 - 75 * Math.cos(phi);\n          y = 75 - 75 * Math.sin(phi);\n        }\n\n        x = Math.round(x);\n        y = Math.round(y);\n      } // Move the picker\n\n\n      if (target.hasClass('cp-grid')) {\n        picker.css({\n          top: y,\n          left: x\n        });\n        this.updateFromPicker(input, target);\n      } else {\n        picker.css({\n          top: y\n        });\n        this.updateFromPicker(input, target);\n      }\n    }\n  }, {\n    key: \"updateFromInput\",\n    value: function updateFromInput(dontFireEvent, element) {\n      element = element ? jquery__WEBPACK_IMPORTED_MODULE_0___default()(element) : this.element;\n      var value = element.val();\n      var opacity = value.replace(/\\s/g, '').match(/^rgba?\\([0-9]{1,3},[0-9]{1,3},[0-9]{1,3},(.+)\\)/);\n      var hex;\n      var hsb;\n      value = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.rgbstr2hex)(value) || value;\n      opacity = opacity ? mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(opacity[1], 0, 1) : 1;\n\n      if (!(hex = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.parseHex)(value))) {\n        hex = '#ffffff';\n      }\n\n      hsb = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hex2hsb)(hex);\n\n      if (this.built) {\n        // opacity\n        this.opacity = opacity;\n        var sliderHeight = this.opacitySlider.height();\n        this.opacitySlider.find('.cp-picker').css({\n          'top': mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(sliderHeight - sliderHeight * this.opacity, 0, sliderHeight)\n        }); // bg color\n\n        var gridHeight = this.grid.height();\n        var gridWidth = this.grid.width();\n        var r;\n        var phi;\n        var x;\n        var y;\n        sliderHeight = this.slider.height();\n\n        switch (this.mode) {\n          case 'wheel':\n            // Set grid position\n            r = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(Math.ceil(hsb.s * 0.75), 0, gridHeight / 2);\n            phi = hsb.h * Math.PI / 180;\n            x = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(75 - Math.cos(phi) * r, 0, gridWidth);\n            y = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(75 - Math.sin(phi) * r, 0, gridHeight);\n            this.grid.css({\n              backgroundColor: 'transparent'\n            }).find('.cp-picker').css({\n              top: y,\n              left: x\n            }); // Set slider position\n\n            y = 150 - hsb.b / (100 / gridHeight);\n            if (hex === '') y = 0;\n            this.slider.find('.cp-picker').css({\n              top: y\n            }); // Update panel color\n\n            this.slider.css({\n              backgroundColor: (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n                h: hsb.h,\n                s: hsb.s,\n                b: 100\n              })\n            });\n            break;\n\n          case 'saturation':\n            // Set grid position\n            x = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(5 * hsb.h / 12, 0, 150);\n            y = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(gridHeight - Math.ceil(hsb.b / (100 / gridHeight)), 0, gridHeight);\n            this.grid.find('.cp-picker').css({\n              top: y,\n              left: x\n            }); // Set slider position\n\n            y = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(sliderHeight - hsb.s * (sliderHeight / 100), 0, sliderHeight);\n            this.slider.find('.cp-picker').css({\n              top: y\n            }); // Update UI\n\n            this.slider.css({\n              backgroundColor: (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n                h: hsb.h,\n                s: 100,\n                b: hsb.b\n              })\n            });\n            this.grid.find('.cp-grid-inner').css({\n              opacity: hsb.s / 100\n            });\n            break;\n\n          case 'brightness':\n            // Set grid position\n            x = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(5 * hsb.h / 12, 0, 150);\n            y = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(gridHeight - Math.ceil(hsb.s / (100 / gridHeight)), 0, gridHeight);\n            this.grid.find('.cp-picker').css({\n              top: y,\n              left: x\n            }); // Set slider position\n\n            y = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(sliderHeight - hsb.b * (sliderHeight / 100), 0, sliderHeight);\n            this.slider.find('.cp-picker').css({\n              top: y\n            }); // Update UI\n\n            this.slider.css({\n              backgroundColor: (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n                h: hsb.h,\n                s: hsb.s,\n                b: 100\n              })\n            });\n            this.grid.find('.cp-grid-inner').css({\n              opacity: 1 - hsb.b / 100\n            });\n            break;\n\n          case 'hue':\n          default:\n            // Set grid position\n            x = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(Math.ceil(hsb.s / (100 / gridWidth)), 0, gridWidth);\n            y = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(gridHeight - Math.ceil(hsb.b / (100 / gridHeight)), 0, gridHeight);\n            this.grid.find('.cp-picker').css({\n              top: y,\n              left: x\n            }); // Set slider position\n\n            y = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(sliderHeight - hsb.h / (360 / sliderHeight), 0, sliderHeight);\n            this.slider.find('.cp-picker').css({\n              top: y\n            }); // Update panel color\n\n            this.grid.css({\n              backgroundColor: (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n                h: hsb.h,\n                s: 100,\n                b: 100\n              })\n            });\n            break;\n        }\n      }\n\n      if (!dontFireEvent) {\n        element.val(this.getValue(hex));\n      }\n\n      (this.element || element).trigger('change._grav_colorpicker', [element, hex, opacity]);\n    }\n  }, {\n    key: \"updateFromPicker\",\n    value: function updateFromPicker(input, target) {\n      var getCoords = function getCoords(picker, container) {\n        var left, top;\n        if (!picker.length || !container) return null;\n        left = picker[0].getBoundingClientRect().left;\n        top = picker[0].getBoundingClientRect().top;\n        return {\n          x: left - container[0].getBoundingClientRect().left + picker[0].offsetWidth / 2,\n          y: top - container[0].getBoundingClientRect().top + picker[0].offsetHeight / 2\n        };\n      };\n\n      var hex;\n      var hue;\n      var saturation;\n      var brightness;\n      var x;\n      var y;\n      var r;\n      var phi; // Panel objects\n\n      var grid = this.wrapper.find('.cp-grid');\n      var slider = this.wrapper.find('.cp-slider');\n      var opacitySlider = this.wrapper.find('.cp-opacity-slider'); // Picker objects\n\n      var gridPicker = grid.find('.cp-picker');\n      var sliderPicker = slider.find('.cp-picker');\n      var opacityPicker = opacitySlider.find('.cp-picker'); // Picker positions\n\n      var gridPos = getCoords(gridPicker, grid);\n      var sliderPos = getCoords(sliderPicker, slider);\n      var opacityPos = getCoords(opacityPicker, opacitySlider); // Sizes\n\n      var gridWidth = grid[0].getBoundingClientRect().width;\n      var gridHeight = grid[0].getBoundingClientRect().height;\n      var sliderHeight = slider[0].getBoundingClientRect().height;\n      var opacitySliderHeight = opacitySlider[0].getBoundingClientRect().height;\n      var value = this.element.val();\n      value = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.rgbstr2hex)(value) || value;\n\n      if (!(hex = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.parseHex)(value))) {\n        hex = '#ffffff';\n      } // Handle colors\n\n\n      if (target.hasClass('cp-grid') || target.hasClass('cp-slider')) {\n        // Determine HSB values\n        switch (this.mode) {\n          case 'wheel':\n            // Calculate hue, saturation, and brightness\n            x = gridWidth / 2 - gridPos.x;\n            y = gridHeight / 2 - gridPos.y;\n            r = Math.sqrt(x * x + y * y);\n            phi = Math.atan2(y, x);\n            if (phi < 0) phi += Math.PI * 2;\n\n            if (r > 75) {\n              r = 75;\n              gridPos.x = 69 - 75 * Math.cos(phi);\n              gridPos.y = 69 - 75 * Math.sin(phi);\n            }\n\n            saturation = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(r / 0.75, 0, 100);\n            hue = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(phi * 180 / Math.PI, 0, 360);\n            brightness = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(100 - Math.floor(sliderPos.y * (100 / sliderHeight)), 0, 100);\n            hex = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n              h: hue,\n              s: saturation,\n              b: brightness\n            }); // Update UI\n\n            slider.css({\n              backgroundColor: (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n                h: hue,\n                s: saturation,\n                b: 100\n              })\n            });\n            break;\n\n          case 'saturation':\n            // Calculate hue, saturation, and brightness\n            hue = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(parseInt(gridPos.x * (360 / gridWidth), 10), 0, 360);\n            saturation = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(100 - Math.floor(sliderPos.y * (100 / sliderHeight)), 0, 100);\n            brightness = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(100 - Math.floor(gridPos.y * (100 / gridHeight)), 0, 100);\n            hex = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n              h: hue,\n              s: saturation,\n              b: brightness\n            }); // Update UI\n\n            slider.css({\n              backgroundColor: (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n                h: hue,\n                s: 100,\n                b: brightness\n              })\n            });\n            grid.find('.cp-grid-inner').css({\n              opacity: saturation / 100\n            });\n            break;\n\n          case 'brightness':\n            // Calculate hue, saturation, and brightness\n            hue = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(parseInt(gridPos.x * (360 / gridWidth), 10), 0, 360);\n            saturation = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(100 - Math.floor(gridPos.y * (100 / gridHeight)), 0, 100);\n            brightness = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(100 - Math.floor(sliderPos.y * (100 / sliderHeight)), 0, 100);\n            hex = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n              h: hue,\n              s: saturation,\n              b: brightness\n            }); // Update UI\n\n            slider.css({\n              backgroundColor: (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n                h: hue,\n                s: saturation,\n                b: 100\n              })\n            });\n            grid.find('.cp-grid-inner').css({\n              opacity: 1 - brightness / 100\n            });\n            break;\n\n          default:\n            // Calculate hue, saturation, and brightness\n            hue = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(360 - parseInt(sliderPos.y * (360 / sliderHeight), 10), 0, 360);\n            saturation = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(Math.floor(gridPos.x * (100 / gridWidth)), 0, 100);\n            brightness = mout_math_clamp__WEBPACK_IMPORTED_MODULE_1___default()(100 - Math.floor(gridPos.y * (100 / gridHeight)), 0, 100);\n            hex = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n              h: hue,\n              s: saturation,\n              b: brightness\n            }); // Update UI\n\n            grid.css({\n              backgroundColor: (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hsb2hex)({\n                h: hue,\n                s: 100,\n                b: 100\n              })\n            });\n            break;\n        }\n      } // Handle opacity\n\n\n      if (target.hasClass('cp-opacity-slider')) {\n        this.opacity = parseFloat(1 - opacityPos.y / opacitySliderHeight).toFixed(2);\n      } // Adjust case\n\n\n      input.val(this.getValue(hex)); // Handle change event\n\n      this.element.trigger('change._grav_colorpicker', [this.element, hex, this.opacity]);\n    }\n  }, {\n    key: \"getValue\",\n    value: function getValue(hex) {\n      if (this.opacity === 1) {\n        return hex;\n      }\n\n      var rgb = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hex2rgb)(hex);\n      return 'rgba(' + rgb.r + ', ' + rgb.g + ', ' + rgb.b + ', ' + this.opacity + ')';\n    }\n  }, {\n    key: \"bound\",\n    value: function bound(name) {\n      var bound = this._bound || (this._bound = {});\n      return bound[name] || (bound[name] = mout_function_bind__WEBPACK_IMPORTED_MODULE_2___default()(this[name], this));\n    }\n  }]);\n\n  return ColorpickerField;\n}();\n\n\nvar Instance = new ColorpickerField('[data-grav-colorpicker]');//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 59116 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/colorpicker.js\n");

/***/ }),

/***/ "./app/forms/fields/cron.js":
/*!**********************************!*\
  !*** ./app/forms/fields/cron.js ***!
  \**********************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ CronField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_cron_ui__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../utils/cron-ui */ \"./app/utils/cron-ui.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_2__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar CronField = /*#__PURE__*/function () {\n  function CronField() {\n    var _this = this;\n\n    _classCallCheck(this, CronField);\n\n    this.items = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-field=\"cron\"]').each(function (index, cron) {\n      return _this.addCron(cron);\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('mutation._grav', this._onAddedNodes.bind(this));\n  }\n\n  _createClass(CronField, [{\n    key: \"addCron\",\n    value: function addCron(cron) {\n      cron = jquery__WEBPACK_IMPORTED_MODULE_0___default()(cron);\n      this.items = this.items.add(cron);\n      cron.find('.cron-selector').each(function (index, container) {\n        container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(container);\n        var input = container.closest('[data-grav-field]').find('input');\n        container.jqCron({\n          numeric_zero_pad: true,\n          enabled_minute: true,\n          multiple_dom: true,\n          multiple_month: true,\n          multiple_mins: true,\n          multiple_dow: true,\n          multiple_time_hours: true,\n          multiple_time_minutes: true,\n          default_period: 'hour',\n          default_value: input.val() || '* * * * *',\n          no_reset_button: false,\n          bind_to: input,\n          bind_method: {\n            set: function set($element, value) {\n              $element.val(value);\n            }\n          },\n          texts: {\n            en: {\n              empty: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.EVERY\"],\n              empty_minutes: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.EVERY\"],\n              empty_time_hours: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.EVERY_HOUR\"],\n              empty_time_minutes: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.EVERY_MINUTE\"],\n              empty_day_of_week: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.EVERY_DAY_OF_WEEK\"],\n              empty_day_of_month: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.EVERY_DAY_OF_MONTH\"],\n              empty_month: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.EVERY_MONTH\"],\n              name_minute: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"NICETIME.MINUTE\"],\n              name_hour: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"NICETIME.HOUR\"],\n              name_day: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"NICETIME.DAY\"],\n              name_week: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"NICETIME.WEEK\"],\n              name_month: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"NICETIME.MONTH\"],\n              name_year: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"NICETIME.YEAR\"],\n              text_period: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.TEXT_PERIOD\"],\n              text_mins: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.TEXT_MINS\"],\n              text_time: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.TEXT_TIME\"],\n              text_dow: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.TEXT_DOW\"],\n              text_month: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.TEXT_MONTH\"],\n              text_dom: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.TEXT_DOM\"],\n              error1: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.ERROR1\"],\n              error2: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.ERROR2\"],\n              error3: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.ERROR3\"],\n              error4: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE[\"CRON.ERROR4\"],\n              weekdays: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE.DAYS_OF_THE_WEEK,\n              months: grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.GRAV_CORE.MONTHS_OF_THE_YEAR\n            }\n          }\n        });\n      });\n    }\n  }, {\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target\n    /* , record, instance */\n    ) {\n      var _this2 = this;\n\n      var crons = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('[data-grav-field=\"cron\"]');\n\n      if (!crons.length) {\n        return;\n      }\n\n      crons.each(function (index, list) {\n        list = jquery__WEBPACK_IMPORTED_MODULE_0___default()(list);\n\n        if (!~_this2.items.index(list)) {\n          _this2.addCron(list);\n        }\n      });\n    }\n  }]);\n\n  return CronField;\n}();\n\n\nvar Instance = new CronField();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 9384 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/cron.js\n");

/***/ }),

/***/ "./app/forms/fields/datetime.js":
/*!**************************************!*\
  !*** ./app/forms/fields/datetime.js ***!
  \**************************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ DateTimeField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_bootstrap_datetimepicker__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../utils/bootstrap-datetimepicker */ \"./app/utils/bootstrap-datetimepicker.js\");\n/* harmony import */ var _utils_bootstrap_datetimepicker__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_utils_bootstrap_datetimepicker__WEBPACK_IMPORTED_MODULE_2__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar DateTimeField = /*#__PURE__*/function () {\n  _createClass(DateTimeField, [{\n    key: \"defaults\",\n    get: function get() {\n      return {\n        showTodayButton: true,\n        showClear: true,\n        locale: grav_config__WEBPACK_IMPORTED_MODULE_1__.config.language || 'en',\n        icons: {\n          time: 'fa fa-clock-o',\n          date: 'fa fa-calendar-o',\n          up: 'fa fa-chevron-up',\n          down: 'fa fa-chevron-down',\n          previous: 'fa fa-chevron-left',\n          next: 'fa fa-chevron-right',\n          today: 'fa fa-bullseye',\n          clear: 'fa fa-trash-o',\n          close: 'fa fa-remove'\n        }\n      };\n    }\n  }]);\n\n  function DateTimeField(options) {\n    var _this = this;\n\n    _classCallCheck(this, DateTimeField);\n\n    this.items = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n    this.options = Object.assign({}, this.defaults, options);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-datetime]').each(function (index, field) {\n      return _this.addItem(field);\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('mutation._grav', this._onAddedNodes.bind(this));\n  }\n\n  _createClass(DateTimeField, [{\n    key: \"addItem\",\n    value: function addItem(list) {\n      list = jquery__WEBPACK_IMPORTED_MODULE_0___default()(list);\n      this.items = this.items.add(list);\n\n      if (list.data('DateTimePicker')) {\n        return;\n      }\n\n      var options = Object.assign({}, this.options, list.data('grav-datetime') || {});\n      list.datetimepicker(options).on('dp.show dp.update', this._disableDecades);\n      list.siblings('.field-icons').on('click', function () {\n        return list.mousedown().focus();\n      });\n    }\n  }, {\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target\n    /* , record, instance */\n    ) {\n      var _this2 = this;\n\n      var fields = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('[data-grav-datetime]');\n\n      if (!fields.length) {\n        return;\n      }\n\n      fields.each(function (index, field) {\n        field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(field);\n\n        if (!~_this2.items.index(field)) {\n          _this2.addItem(field);\n        }\n      });\n    }\n  }, {\n    key: \"_disableDecades\",\n    value: function _disableDecades() {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.datepicker-years .picker-switch').removeAttr('title').on('click', function (e) {\n        return e.stopPropagation();\n      });\n    }\n  }]);\n\n  return DateTimeField;\n}();\n\n\nvar Instance = new DateTimeField();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 5912 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/datetime.js\n");

/***/ }),

/***/ "./app/forms/fields/editor.js":
/*!************************************!*\
  !*** ./app/forms/fields/editor.js ***!
  \************************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export Toolbar [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ EditorField,\n/* harmony export */   \"Toolbar\": () => /* binding */ Toolbar,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _editor_buttons__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./editor/buttons */ \"./app/forms/fields/editor/buttons.js\");\n/* harmony import */ var codemirror__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! codemirror */ \"./node_modules/codemirror/lib/codemirror.js\");\n/* harmony import */ var codemirror__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(codemirror__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var watchjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! watchjs */ \"./node_modules/watchjs/src/watch.js\");\n/* harmony import */ var watchjs__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(watchjs__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var js_yaml__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! js-yaml */ \"./node_modules/js-yaml/index.js\");\n/* harmony import */ var js_yaml__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(js_yaml__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var codemirror_mode_css_css__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! codemirror/mode/css/css */ \"./node_modules/codemirror/mode/css/css.js\");\n/* harmony import */ var codemirror_mode_css_css__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_css_css__WEBPACK_IMPORTED_MODULE_5__);\n/* harmony import */ var codemirror_mode_gfm_gfm__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! codemirror/mode/gfm/gfm */ \"./node_modules/codemirror/mode/gfm/gfm.js\");\n/* harmony import */ var codemirror_mode_gfm_gfm__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_gfm_gfm__WEBPACK_IMPORTED_MODULE_6__);\n/* harmony import */ var codemirror_mode_htmlmixed_htmlmixed__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! codemirror/mode/htmlmixed/htmlmixed */ \"./node_modules/codemirror/mode/htmlmixed/htmlmixed.js\");\n/* harmony import */ var codemirror_mode_htmlmixed_htmlmixed__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_htmlmixed_htmlmixed__WEBPACK_IMPORTED_MODULE_7__);\n/* harmony import */ var codemirror_mode_javascript_javascript__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! codemirror/mode/javascript/javascript */ \"./node_modules/codemirror/mode/javascript/javascript.js\");\n/* harmony import */ var codemirror_mode_javascript_javascript__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_javascript_javascript__WEBPACK_IMPORTED_MODULE_8__);\n/* harmony import */ var codemirror_mode_markdown_markdown__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! codemirror/mode/markdown/markdown */ \"./node_modules/codemirror/mode/markdown/markdown.js\");\n/* harmony import */ var codemirror_mode_markdown_markdown__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_markdown_markdown__WEBPACK_IMPORTED_MODULE_9__);\n/* harmony import */ var codemirror_mode_php_php__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! codemirror/mode/php/php */ \"./node_modules/codemirror/mode/php/php.js\");\n/* harmony import */ var codemirror_mode_php_php__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_php_php__WEBPACK_IMPORTED_MODULE_10__);\n/* harmony import */ var codemirror_mode_sass_sass__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! codemirror/mode/sass/sass */ \"./node_modules/codemirror/mode/sass/sass.js\");\n/* harmony import */ var codemirror_mode_sass_sass__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_sass_sass__WEBPACK_IMPORTED_MODULE_11__);\n/* harmony import */ var codemirror_mode_twig_twig__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! codemirror/mode/twig/twig */ \"./node_modules/codemirror/mode/twig/twig.js\");\n/* harmony import */ var codemirror_mode_twig_twig__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_twig_twig__WEBPACK_IMPORTED_MODULE_12__);\n/* harmony import */ var codemirror_mode_xml_xml__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! codemirror/mode/xml/xml */ \"./node_modules/codemirror/mode/xml/xml.js\");\n/* harmony import */ var codemirror_mode_xml_xml__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_xml_xml__WEBPACK_IMPORTED_MODULE_13__);\n/* harmony import */ var codemirror_mode_yaml_yaml__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! codemirror/mode/yaml/yaml */ \"./node_modules/codemirror/mode/yaml/yaml.js\");\n/* harmony import */ var codemirror_mode_yaml_yaml__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(codemirror_mode_yaml_yaml__WEBPACK_IMPORTED_MODULE_14__);\n/* harmony import */ var codemirror_addon_edit_continuelist__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! codemirror/addon/edit/continuelist */ \"./node_modules/codemirror/addon/edit/continuelist.js\");\n/* harmony import */ var codemirror_addon_edit_continuelist__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(codemirror_addon_edit_continuelist__WEBPACK_IMPORTED_MODULE_15__);\n/* harmony import */ var codemirror_addon_mode_overlay__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! codemirror/addon/mode/overlay */ \"./node_modules/codemirror/addon/mode/overlay.js\");\n/* harmony import */ var codemirror_addon_mode_overlay__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(codemirror_addon_mode_overlay__WEBPACK_IMPORTED_MODULE_16__);\n/* harmony import */ var codemirror_addon_selection_active_line__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! codemirror/addon/selection/active-line */ \"./node_modules/codemirror/addon/selection/active-line.js\");\n/* harmony import */ var codemirror_addon_selection_active_line__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(codemirror_addon_selection_active_line__WEBPACK_IMPORTED_MODULE_17__);\n/* harmony import */ var codemirror_addon_lint_lint__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! codemirror/addon/lint/lint */ \"./node_modules/codemirror/addon/lint/lint.js\");\n/* harmony import */ var codemirror_addon_lint_lint__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(codemirror_addon_lint_lint__WEBPACK_IMPORTED_MODULE_18__);\n/* harmony import */ var codemirror_addon_lint_lint_css__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! codemirror/addon/lint/lint.css */ \"./node_modules/codemirror/addon/lint/lint.css\");\n/* harmony import */ var codemirror_addon_lint_css_lint__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! codemirror/addon/lint/css-lint */ \"./node_modules/codemirror/addon/lint/css-lint.js\");\n/* harmony import */ var codemirror_addon_lint_css_lint__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(codemirror_addon_lint_css_lint__WEBPACK_IMPORTED_MODULE_20__);\n/* harmony import */ var codemirror_addon_lint_javascript_lint__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! codemirror/addon/lint/javascript-lint */ \"./node_modules/codemirror/addon/lint/javascript-lint.js\");\n/* harmony import */ var codemirror_addon_lint_javascript_lint__WEBPACK_IMPORTED_MODULE_21___default = /*#__PURE__*/__webpack_require__.n(codemirror_addon_lint_javascript_lint__WEBPACK_IMPORTED_MODULE_21__);\n/* harmony import */ var codemirror_addon_lint_json_lint__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! codemirror/addon/lint/json-lint */ \"./node_modules/codemirror/addon/lint/json-lint.js\");\n/* harmony import */ var codemirror_addon_lint_json_lint__WEBPACK_IMPORTED_MODULE_22___default = /*#__PURE__*/__webpack_require__.n(codemirror_addon_lint_json_lint__WEBPACK_IMPORTED_MODULE_22__);\n/* harmony import */ var codemirror_addon_lint_yaml_lint__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! codemirror/addon/lint/yaml-lint */ \"./node_modules/codemirror/addon/lint/yaml-lint.js\");\n/* harmony import */ var codemirror_addon_lint_yaml_lint__WEBPACK_IMPORTED_MODULE_23___default = /*#__PURE__*/__webpack_require__.n(codemirror_addon_lint_yaml_lint__WEBPACK_IMPORTED_MODULE_23__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\n\n__webpack_require__.g.jsyaml = (js_yaml__WEBPACK_IMPORTED_MODULE_4___default()); // Modes\n\n\n\n\n\n\n\n\n\n\n // Add-ons\n\n\n\n\n\n\n\n\n\n\nvar IS_MOUSEDOWN = false;\nvar ThemesMap = ['paper'];\nvar Defaults = {\n  codemirror: {\n    mode: 'htmlmixed',\n    theme: 'paper',\n    lineWrapping: true,\n    dragDrop: true,\n    autoCloseTags: true,\n    matchTags: true,\n    autoCloseBrackets: true,\n    matchBrackets: true,\n    indentUnit: 4,\n    indentWithTabs: false,\n    tabSize: 4,\n    hintOptions: {\n      completionSingle: false\n    },\n    extraKeys: {\n      'Enter': 'newlineAndIndentContinueMarkdownList'\n    }\n  }\n};\n\nvar EditorField = /*#__PURE__*/function () {\n  function EditorField(options) {\n    var _this = this;\n\n    _classCallCheck(this, EditorField);\n\n    var body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\n    this.editors = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n    this.options = Object.assign({}, Defaults, options);\n    this.buttons = _editor_buttons__WEBPACK_IMPORTED_MODULE_1__.default;\n    this.buttonStrategies = _editor_buttons__WEBPACK_IMPORTED_MODULE_1__.strategies;\n    (0,watchjs__WEBPACK_IMPORTED_MODULE_3__.watch)(_editor_buttons__WEBPACK_IMPORTED_MODULE_1__.default, function ()\n    /* key, modifier, prev, next */\n    {\n      _this.editors.each(function (index, editor) {\n        return jquery__WEBPACK_IMPORTED_MODULE_0___default()(editor).data('toolbar').renderButtons();\n      });\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-editor]').each(function (index, editor) {\n      return _this.addEditor(editor);\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(function () {\n      body.trigger('grav-editor-ready');\n    });\n    body.on('mutation._grav', this._onAddedNodes.bind(this));\n    body.on('mouseup._grav', function () {\n      if (!IS_MOUSEDOWN) {\n        return true;\n      }\n\n      body.unbind('mousemove._grav');\n      IS_MOUSEDOWN = false;\n    });\n    body.on('mousedown._grav', '.grav-editor-resizer', function (event) {\n      event && event.preventDefault();\n      IS_MOUSEDOWN = true;\n      var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n      var container = target.siblings('.grav-editor-content');\n      var editor = container.find('.CodeMirror');\n      var codemirror = container.find('textarea').data('codemirror');\n      body.on('mousemove._grav', function (event) {\n        editor.css('height', Math.max(100, event.pageY - container.offset().top));\n        codemirror.refresh();\n      });\n    });\n  }\n\n  _createClass(EditorField, [{\n    key: \"addButton\",\n    value: function addButton(button, options) {\n      if (options && (options.before || options.after)) {\n        var index = this.buttons.navigation.findIndex(function (obj) {\n          var key = Object.keys(obj).shift();\n          return obj[key].identifier === (options.before || options.after);\n        });\n\n        if (!~index) {\n          options = 'end';\n        } else {\n          this.buttons.navigation.splice(options.before ? index : index + 1, 0, button);\n        }\n      }\n\n      if (options === 'start') {\n        this.buttons.navigation.splice(0, 0, button);\n      }\n\n      if (!options || options === 'end') {\n        this.buttons.navigation.push(button);\n      }\n    }\n  }, {\n    key: \"addEditor\",\n    value: function addEditor(textarea) {\n      textarea = jquery__WEBPACK_IMPORTED_MODULE_0___default()(textarea);\n      var options = Object.assign({}, this.options.codemirror, textarea.data('grav-editor').codemirror);\n      var theme = options.theme || 'paper';\n      this.editors = this.editors.add(textarea);\n\n      if (theme && !~ThemesMap.indexOf(theme)) {\n        ThemesMap.push(theme); // let themeCSS = `https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.12.0/theme/${theme}.min.css`;\n        // $('head').append($('<link rel=\"stylesheet\" type=\"text/css\" />').attr('href', themeCSS));\n      }\n\n      if (options.mode === 'yaml') {\n        Object.assign(options.extraKeys, {\n          Tab: function Tab(cm) {\n            cm.replaceSelection('    ', 'end');\n          }\n        });\n      }\n\n      var editor = codemirror__WEBPACK_IMPORTED_MODULE_2___default().fromTextArea(textarea.get(0), options);\n      textarea.data('codemirror', editor);\n      textarea.data('toolbar', new Toolbar(textarea));\n      textarea.addClass('code-mirrored');\n\n      if (options.toolbar === false) {\n        textarea.data('toolbar').ui.navigation.addClass('grav-editor-hide-toolbar');\n      }\n\n      editor.on('change', function () {\n        return editor.save();\n      });\n    }\n  }, {\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target\n    /* , record, instance */\n    ) {\n      var _this2 = this;\n\n      var editors = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('[data-grav-editor]');\n\n      if (!editors.length) {\n        return;\n      }\n\n      editors.each(function (index, editor) {\n        editor = jquery__WEBPACK_IMPORTED_MODULE_0___default()(editor);\n\n        if (!~_this2.editors.index(editor)) {\n          _this2.addEditor(editor);\n        }\n      });\n    }\n  }]);\n\n  return EditorField;\n}();\n\n\nvar Toolbar = /*#__PURE__*/function () {\n  _createClass(Toolbar, null, [{\n    key: \"templates\",\n    value: function templates() {\n      return {\n        navigation: \"\\n                <div class=\\\"grav-editor-toolbar\\\">\\n                    <div class=\\\"grav-editor-actions\\\"></div>\\n                    <div class=\\\"grav-editor-modes\\\"></div>\\n                </div>\\n            \"\n      };\n    }\n  }]);\n\n  function Toolbar(editor) {\n    _classCallCheck(this, Toolbar);\n\n    this.editor = jquery__WEBPACK_IMPORTED_MODULE_0___default()(editor);\n    this.codemirror = this.editor.data('codemirror');\n    this.buttons = _editor_buttons__WEBPACK_IMPORTED_MODULE_1__.default.navigation;\n    this.ui = {\n      navigation: jquery__WEBPACK_IMPORTED_MODULE_0___default()(Toolbar.templates().navigation)\n    };\n    this.editor.parent('.grav-editor-content').before(this.ui.navigation).after(this.ui.states);\n    this.renderButtons();\n  }\n\n  _createClass(Toolbar, [{\n    key: \"renderButtons\",\n    value: function renderButtons() {\n      var _this3 = this;\n\n      var map = {\n        'actions': 'navigation',\n        'modes': 'states'\n      };\n      ['actions', 'modes'].forEach(function (type) {\n        _this3.ui.navigation.find(\".grav-editor-\".concat(type)).empty().append('<ul />');\n\n        _editor_buttons__WEBPACK_IMPORTED_MODULE_1__.default[map[type]].forEach(function (button) {\n          return _this3.renderButton(button, type);\n        });\n      });\n    }\n  }, {\n    key: \"renderButton\",\n    value: function renderButton(button, type) {\n      var _this4 = this;\n\n      var location = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n      Object.keys(button).forEach(function (key) {\n        var obj = button[key];\n\n        if (!obj.modes) {\n          obj.modes = [];\n        }\n\n        if (!~_this4.codemirror.options.ignore.indexOf(key) && (!obj.modes.length || obj.modes.indexOf(_this4.codemirror.options.mode) > -1)) {\n          var hint = obj.title ? \"data-hint=\\\"\".concat(obj.title, \"\\\"\") : '';\n          var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"<li class=\\\"grav-editor-button-\".concat(key, \"\\\"><a class=\\\"hint--top\\\" \").concat(hint, \">\").concat(obj.label, \"</a></li>\"));\n\n          (location || _this4.ui.navigation.find(\".grav-editor-\".concat(type, \" ul:not(.dropdown-menu)\"))).append(element);\n\n          if (obj.shortcut) {\n            _this4.addShortcut(obj.identifier, obj.shortcut, element);\n          }\n\n          obj.action && obj.action.call(obj.action, {\n            codemirror: _this4.codemirror,\n            button: element,\n            textarea: _this4.editor,\n            ui: _this4.ui\n          });\n\n          if (obj.children) {\n            var childrenContainer = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<ul class=\"dropdown-menu\" />');\n            element.addClass('button-group').find('a').wrap('<div class=\"dropdown-toggle\" data-toggle=\"dropdown\"></div>');\n            element.find('a').append(' <i class=\"fa fa-caret-down\"></i>');\n            element.append(childrenContainer);\n            obj.children.forEach(function (child) {\n              return _this4.renderButton(child, type, childrenContainer);\n            });\n          }\n        }\n      });\n    }\n  }, {\n    key: \"addShortcut\",\n    value: function addShortcut(identifier, shortcut, element) {\n      var _this5 = this;\n\n      var map = {};\n\n      if (!Array.isArray(shortcut)) {\n        shortcut = [shortcut];\n      }\n\n      shortcut.forEach(function (key) {\n        map[key] = function () {\n          element.trigger(\"click.editor.\".concat(identifier), [_this5.codemirror]);\n        };\n      });\n      this.codemirror.addKeyMap(map);\n    }\n  }]);\n\n  return Toolbar;\n}();\nvar Instance = new EditorField();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 23068 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/editor.js\n");

/***/ }),

/***/ "./app/forms/fields/editor/buttons.js":
/*!********************************************!*\
  !*** ./app/forms/fields/editor/buttons.js ***!
  \********************************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! export strategies [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"strategies\": () => /* binding */ strategies,\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../utils/request */ \"./app/utils/request.js\");\n\n\n\n\nvar replacer = function replacer(_ref) {\n  var name = _ref.name,\n      replace = _ref.replace,\n      codemirror = _ref.codemirror,\n      button = _ref.button,\n      _ref$mode = _ref.mode,\n      mode = _ref$mode === void 0 ? 'replaceSelections' : _ref$mode,\n      runner = _ref.runner;\n  button.on(\"click.editor.\".concat(name), function () {\n    strategies[mode]({\n      token: '$1',\n      template: replace,\n      codemirror: codemirror,\n      runner: runner\n    });\n  });\n};\n\nvar strategies = {\n  replaceSelections: function replaceSelections(_ref2) {\n    var template = _ref2.template,\n        token = _ref2.token,\n        codemirror = _ref2.codemirror,\n        runner = _ref2.runner;\n    var replacements = [];\n    var ranges = [];\n    var selections = codemirror.getSelections();\n    var list = codemirror.listSelections();\n    var accumulator = {};\n    selections.forEach(function (selection, index) {\n      var markup = template.replace(token, selection);\n      var cursor = markup.indexOf('$cur');\n      var _list$index$anchor = list[index].anchor,\n          line = _list$index$anchor.line,\n          ch = _list$index$anchor.ch;\n      markup = markup.replace('$cur', '');\n      markup = runner ? runner(selection, markup, list) : markup;\n      replacements.push(markup);\n\n      if (!accumulator[line]) {\n        accumulator[line] = 0;\n      }\n\n      ch += accumulator[line] + (cursor === -1 ? markup.length : cursor);\n      var range = {\n        ch: ch,\n        line: line\n      };\n      ranges.push({\n        anchor: range,\n        head: range\n      });\n      accumulator[line] += markup.length - selection.length;\n    });\n    codemirror.replaceSelections(replacements);\n    codemirror.setSelections(ranges);\n    codemirror.focus();\n  },\n  replaceLine: function replaceLine(_ref3) {\n    var template = _ref3.template,\n        token = _ref3.token,\n        codemirror = _ref3.codemirror,\n        runner = _ref3.runner;\n    var list = codemirror.listSelections();\n    var range;\n    list.forEach(function (selection) {\n      var lines = {\n        min: Math.min(selection.anchor.line, selection.head.line),\n        max: Math.max(selection.anchor.line, selection.head.line)\n      };\n      codemirror.eachLine(lines.min, lines.max + 1, function (handler) {\n        var markup = template.replace(token, handler.text);\n        var line = codemirror.getLineNumber(handler);\n        markup = runner ? runner(handler, markup) : markup;\n        codemirror.replaceRange(markup, {\n          line: line,\n          ch: 0\n        }, {\n          line: line,\n          ch: markup.length\n        });\n        range = {\n          line: line,\n          ch: markup.length\n        };\n      });\n    });\n    codemirror.setSelection(range, range, 'end');\n    codemirror.focus();\n  },\n  replaceRange: function replaceRange() {}\n};\n\nvar flipDisabled = function flipDisabled(codemirror, button, type) {\n  var hasHistory = codemirror.historySize()[type];\n  var element = button.find('a');\n  button[hasHistory ? 'removeClass' : 'addClass']('button-disabled');\n\n  if (!hasHistory) {\n    element.attr('title-disabled', element.attr('title'));\n    element.attr('data-hint-disabled', element.attr('data-hint'));\n    element.removeAttr('title').removeAttr('data-hint');\n  } else {\n    element.attr('title', element.attr('title-disabled'));\n    element.attr('data-hint', element.attr('data-hint-disabled'));\n    element.removeAttr('title-disabled').removeAttr('data-hint-disabled');\n  }\n};\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({\n  navigation: [{\n    undo: {\n      identifier: 'undo',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.UNDO,\n      label: '<i class=\"fa fa-fw fa-undo\"></i>',\n      modes: [],\n      action: function action(_ref4) {\n        var codemirror = _ref4.codemirror,\n            button = _ref4.button,\n            textarea = _ref4.textarea;\n        button.addClass('button-disabled');\n        codemirror.on('change', function () {\n          return flipDisabled(codemirror, button, 'undo');\n        });\n        button.on('click.editor.undo', function () {\n          codemirror.undo();\n        });\n      }\n    }\n  }, {\n    redo: {\n      identifier: 'redo',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.REDO,\n      label: '<i class=\"fa fa-fw fa-repeat\"></i>',\n      modes: [],\n      action: function action(_ref5) {\n        var codemirror = _ref5.codemirror,\n            button = _ref5.button,\n            textarea = _ref5.textarea;\n        button.addClass('button-disabled');\n        codemirror.on('change', function () {\n          return flipDisabled(codemirror, button, 'redo');\n        });\n        button.on('click.editor.redo', function () {\n          codemirror.redo();\n        });\n      }\n    }\n  }, {\n    headers: {\n      identifier: 'headers',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.HEADERS,\n      label: '<i class=\"fa fa-fw fa-header\"></i>',\n      modes: ['gfm', 'markdown'],\n      children: [{\n        h1: {\n          identifier: 'h1',\n          label: '<i class=\"fa fa-fw fa-header\"></i>1',\n          modes: ['gfm', 'markdown'],\n          action: function action(_ref6) {\n            var codemirror = _ref6.codemirror,\n                button = _ref6.button,\n                textarea = _ref6.textarea;\n            replacer({\n              name: 'h1',\n              replace: '# $1',\n              codemirror: codemirror,\n              button: button,\n              mode: 'replaceLine'\n            });\n          }\n        }\n      }, {\n        h2: {\n          identifier: 'h2',\n          label: '<i class=\"fa fa-fw fa-header\"></i>2',\n          modes: ['gfm', 'markdown'],\n          action: function action(_ref7) {\n            var codemirror = _ref7.codemirror,\n                button = _ref7.button,\n                textarea = _ref7.textarea;\n            replacer({\n              name: 'h2',\n              replace: '## $1',\n              codemirror: codemirror,\n              button: button,\n              mode: 'replaceLine'\n            });\n          }\n        }\n      }, {\n        h3: {\n          identifier: 'h3',\n          label: '<i class=\"fa fa-fw fa-header\"></i>3',\n          modes: ['gfm', 'markdown'],\n          action: function action(_ref8) {\n            var codemirror = _ref8.codemirror,\n                button = _ref8.button,\n                textarea = _ref8.textarea;\n            replacer({\n              name: 'h3',\n              replace: '### $1',\n              codemirror: codemirror,\n              button: button,\n              mode: 'replaceLine'\n            });\n          }\n        }\n      }, {\n        h4: {\n          identifier: 'h4',\n          label: '<i class=\"fa fa-fw fa-header\"></i>4',\n          modes: ['gfm', 'markdown'],\n          action: function action(_ref9) {\n            var codemirror = _ref9.codemirror,\n                button = _ref9.button,\n                textarea = _ref9.textarea;\n            replacer({\n              name: 'h4',\n              replace: '#### $1',\n              codemirror: codemirror,\n              button: button,\n              mode: 'replaceLine'\n            });\n          }\n        }\n      }, {\n        h5: {\n          identifier: 'h5',\n          label: '<i class=\"fa fa-fw fa-header\"></i>5',\n          modes: ['gfm', 'markdown'],\n          action: function action(_ref10) {\n            var codemirror = _ref10.codemirror,\n                button = _ref10.button,\n                textarea = _ref10.textarea;\n            replacer({\n              name: 'h5',\n              replace: '##### $1',\n              codemirror: codemirror,\n              button: button,\n              mode: 'replaceLine'\n            });\n          }\n        }\n      }, {\n        h6: {\n          identifier: 'h6',\n          label: '<i class=\"fa fa-fw fa-header\"></i>6',\n          modes: ['gfm', 'markdown'],\n          action: function action(_ref11) {\n            var codemirror = _ref11.codemirror,\n                button = _ref11.button,\n                textarea = _ref11.textarea;\n            replacer({\n              name: 'h6',\n              replace: '###### $1',\n              codemirror: codemirror,\n              button: button,\n              mode: 'replaceLine'\n            });\n          }\n        }\n      }]\n    }\n  }, {\n    bold: {\n      identifier: 'bold',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.BOLD,\n      label: '<i class=\"fa fa-fw fa-bold\"></i>',\n      modes: ['gfm', 'markdown'],\n      shortcut: ['Ctrl-B', 'Cmd-B'],\n      action: function action(_ref12) {\n        var codemirror = _ref12.codemirror,\n            button = _ref12.button,\n            textarea = _ref12.textarea;\n        replacer({\n          name: 'bold',\n          replace: '**$1$cur**',\n          codemirror: codemirror,\n          button: button\n        });\n      }\n    }\n  }, {\n    italic: {\n      identifier: 'italic',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.ITALIC,\n      label: '<i class=\"fa fa-fw fa-italic\"></i>',\n      modes: ['gfm', 'markdown'],\n      shortcut: ['Ctrl-I', 'Cmd-I'],\n      action: function action(_ref13) {\n        var codemirror = _ref13.codemirror,\n            button = _ref13.button,\n            textarea = _ref13.textarea;\n        replacer({\n          name: 'italic',\n          replace: '_$1$cur_',\n          codemirror: codemirror,\n          button: button\n        });\n      }\n    }\n  }, {\n    strike: {\n      identifier: 'strike',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.STRIKETHROUGH,\n      label: '<i class=\"fa fa-fw fa-strikethrough\"></i>',\n      modes: ['gfm', 'markdown'],\n      action: function action(_ref14) {\n        var codemirror = _ref14.codemirror,\n            button = _ref14.button,\n            textarea = _ref14.textarea;\n        replacer({\n          name: 'strike',\n          replace: '~~$1$cur~~',\n          codemirror: codemirror,\n          button: button\n        });\n      }\n    }\n  }, {\n    delimiter: {\n      identifier: 'delimiter',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.SUMMARY_DELIMITER,\n      label: '<i class=\"fa fa-fw fa-minus\"></i>',\n      modes: ['gfm', 'markdown'],\n      action: function action(_ref15) {\n        var codemirror = _ref15.codemirror,\n            button = _ref15.button,\n            textarea = _ref15.textarea;\n        replacer({\n          name: 'delimiter',\n          replace: \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.site.delimiter, \"$1\"),\n          codemirror: codemirror,\n          button: button,\n          mode: 'replaceLine'\n        });\n      }\n    }\n  }, {\n    link: {\n      identifier: 'link',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.LINK,\n      label: '<i class=\"fa fa-fw fa-link\"></i>',\n      modes: ['gfm', 'markdown'],\n      shortcut: ['Ctrl-K', 'Cmd-K'],\n      action: function action(_ref16) {\n        var codemirror = _ref16.codemirror,\n            button = _ref16.button,\n            textarea = _ref16.textarea;\n        replacer({\n          name: 'link',\n          replace: '[$1]($cur)',\n          codemirror: codemirror,\n          button: button\n        });\n      }\n    }\n  }, {\n    image: {\n      identifier: 'image',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.IMAGE,\n      label: '<i class=\"fa fa-fw fa-picture-o\"></i>',\n      modes: ['gfm', 'markdown'],\n      action: function action(_ref17) {\n        var codemirror = _ref17.codemirror,\n            button = _ref17.button,\n            textarea = _ref17.textarea;\n        replacer({\n          name: 'image',\n          replace: '![$1](http://$cur)',\n          codemirror: codemirror,\n          button: button\n        });\n      }\n    }\n  }, {\n    blockquote: {\n      identifier: 'blockquote',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.BLOCKQUOTE,\n      label: '<i class=\"fa fa-fw fa-quote-right\"></i>',\n      modes: ['gfm', 'markdown'],\n      action: function action(_ref18) {\n        var codemirror = _ref18.codemirror,\n            button = _ref18.button,\n            textarea = _ref18.textarea;\n        replacer({\n          name: 'blockquote',\n          replace: '> $1',\n          codemirror: codemirror,\n          button: button,\n          mode: 'replaceLine'\n        });\n      }\n    }\n  }, {\n    listUl: {\n      identifier: 'listUl',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.UNORDERED_LIST,\n      label: '<i class=\"fa fa-fw fa-list-ul\"></i>',\n      modes: ['gfm', 'markdown'],\n      action: function action(_ref19) {\n        var codemirror = _ref19.codemirror,\n            button = _ref19.button,\n            textarea = _ref19.textarea;\n        replacer({\n          name: 'listUl',\n          replace: '* $1',\n          codemirror: codemirror,\n          button: button,\n          mode: 'replaceLine'\n        });\n      }\n    }\n  }, {\n    listOl: {\n      identifier: 'listOl',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.ORDERED_LIST,\n      label: '<i class=\"fa fa-fw fa-list-ol\"></i>',\n      modes: ['gfm', 'markdown'],\n      action: function action(_ref20) {\n        var codemirror = _ref20.codemirror,\n            button = _ref20.button,\n            textarea = _ref20.textarea;\n        replacer({\n          name: 'listOl',\n          replace: '. $1',\n          codemirror: codemirror,\n          button: button,\n          mode: 'replaceLine',\n          runner: function runner(line, markup) {\n            var lineNo = codemirror.getLineNumber(line);\n            var previousLine = codemirror.getLine(lineNo - 1) || '';\n            var match = previousLine.match(/^(\\d+)\\./);\n            var prefix = 1 + (match ? Number(match[1]) : 0);\n            return \"\".concat(prefix).concat(markup);\n          }\n        });\n      }\n    }\n  }],\n  states: [{\n    code: {\n      identifier: 'editor',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.EDITOR,\n      label: '<i class=\"fa fa-fw fa-code\"></i>',\n      action: function action(_ref21) {\n        var codemirror = _ref21.codemirror,\n            button = _ref21.button,\n            textarea = _ref21.textarea,\n            ui = _ref21.ui;\n\n        if (textarea.data('grav-editor-mode') === 'editor') {\n          button.addClass('editor-active');\n        }\n\n        button.on('click.states.editor', function () {\n          button.siblings().removeClass('editor-active');\n          button.addClass('editor-active');\n          textarea.data('grav-editor-mode', 'editor');\n          var previewContainer = textarea.data('grav-editor-preview-container');\n          var content = textarea.parent('.grav-editor-content');\n          content.addClass('is-active');\n          ui.navigation.find('.grav-editor-actions').css('visibility', 'visible');\n\n          if (previewContainer) {\n            previewContainer.removeClass('is-active');\n          }\n        });\n      }\n    }\n  }, {\n    preview: {\n      identifier: 'preview',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.PREVIEW,\n      label: '<i class=\"fa fa-fw fa-eye\"></i>',\n      modes: ['gfm', 'markdown'],\n      action: function action(_ref22) {\n        var codemirror = _ref22.codemirror,\n            button = _ref22.button,\n            textarea = _ref22.textarea,\n            ui = _ref22.ui;\n\n        if (textarea.data('grav-editor-mode') === 'preview') {\n          button.addClass('editor-active');\n        }\n\n        button.on('click.states.preview', function () {\n          var previewContainer = textarea.data('grav-editor-preview-container');\n          var content = textarea.parent('.grav-editor-content');\n          button.siblings().removeClass('editor-active');\n          button.addClass('editor-active');\n          textarea.data('grav-editor-mode', 'preview');\n\n          if (!previewContainer) {\n            previewContainer = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"grav-editor-preview\" />');\n            content.after(previewContainer);\n            textarea.data('grav-editor-preview-container', previewContainer);\n          }\n\n          previewContainer.css({\n            height: content.height()\n          });\n          previewContainer.addClass('is-active');\n          content.removeClass('is-active');\n          ui.navigation.find('.grav-editor-actions').css('visibility', 'hidden');\n          var url = \"\".concat(textarea.data('grav-urlpreview'), \"/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"processmarkdown\");\n          var params = textarea.closest('form').serializeArray();\n          var body = {};\n          params.map(function (obj) {\n            body[obj.name] = obj.value;\n          });\n          (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n            method: 'post',\n            body: body\n          }, function (response) {\n            return previewContainer.html(response.preview);\n          });\n        });\n      }\n    }\n  }, {\n    fullscreen: {\n      identifier: 'fullscreen',\n      title: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.FULLSCREEN,\n      label: '<i class=\"fa fa-fw fa-expand\"></i>',\n      action: function action(_ref23) {\n        var codemirror = _ref23.codemirror,\n            button = _ref23.button,\n            textarea = _ref23.textarea;\n        button.on('click.editor.fullscreen', function () {\n          var container = textarea.closest('.grav-editor');\n          var wrapper = codemirror.getWrapperElement();\n          var contentWrapper = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.content-wrapper');\n\n          if (!container.hasClass('grav-editor-fullscreen')) {\n            textarea.data('fullScreenRestore', {\n              scrollTop: __webpack_require__.g.pageYOffset,\n              scrollLeft: __webpack_require__.g.pageXOffset,\n              width: wrapper.style.width,\n              height: wrapper.style.height\n            });\n            wrapper.style.width = '';\n            wrapper.style.height = textarea.parent('.grav-editor-content').height() + 'px';\n            __webpack_require__.g.document.documentElement.style.overflow = 'hidden';\n            var hints = container.find('.grav-editor-toolbar .hint--top');\n\n            if (hints) {\n              hints.removeClass('hint--top').addClass('hint--bottom');\n              jquery__WEBPACK_IMPORTED_MODULE_0___default()(hints[hints.length - 1]).addClass('hint--bottom-left');\n            }\n\n            if (contentWrapper) {\n              contentWrapper.css('overflow', 'visible');\n            }\n          } else {\n            __webpack_require__.g.document.documentElement.style.overflow = '';\n            var state = textarea.data('fullScreenRestore');\n            wrapper.style.width = state.width;\n            wrapper.style.height = state.height;\n            __webpack_require__.g.scrollTo(state.scrollLeft, state.scrollTop);\n\n            var _hints = container.find('.grav-editor-toolbar .hint--bottom');\n\n            if (_hints) {\n              _hints.removeClass('hint--bottom').addClass('hint--top');\n\n              jquery__WEBPACK_IMPORTED_MODULE_0___default()(_hints[_hints.length - 1]).removeClass('hint--bottom-left');\n            }\n\n            if (contentWrapper) {\n              contentWrapper.css('overflow', 'auto');\n            }\n          }\n\n          container.toggleClass('grav-editor-fullscreen');\n          setTimeout(function () {\n            codemirror.refresh(); // this.preview.parent().css('height', this.code.height());\n\n            jquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).trigger('resize');\n          }, 5);\n        });\n      }\n    }\n  }]\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 47764 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/editor/buttons.js\n");

/***/ }),

/***/ "./app/forms/fields/filepicker.js":
/*!****************************************!*\
  !*** ./app/forms/fields/filepicker.js ***!
  \****************************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ FilePickerField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../utils/request */ \"./app/utils/request.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n // const insertTextAt = (string, index, text) => [string.slice(0, index), text, string.slice(index)].join('');\n\nvar FilePickerField = /*#__PURE__*/function () {\n  function FilePickerField(options) {\n    var _this = this;\n\n    _classCallCheck(this, FilePickerField);\n\n    this.items = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n    this.options = Object.assign({}, this.defaults, options);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-filepicker]').each(function (index, element) {\n      return _this.addItem(element);\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('mutation._grav', this._onAddedNodes.bind(this));\n  }\n\n  _createClass(FilePickerField, [{\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target\n    /* , record, instance */\n    ) {\n      var _this2 = this;\n\n      var fields = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('[data-grav-filepicker]');\n\n      if (!fields.length) {\n        return;\n      }\n\n      fields.each(function (index, field) {\n        field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(field);\n\n        if (!~_this2.items.index(field)) {\n          _this2.addItem(field);\n        }\n      });\n    }\n  }, {\n    key: \"addItem\",\n    value: function addItem(element) {\n      element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n      this.items = this.items.add(element);\n      var tag = element.prop('tagName').toLowerCase();\n      var isInput = tag === 'input' || tag === 'select';\n      var field = isInput ? element : element.find('input, select');\n      var folder = '';\n      var thumbs = {};\n      var onDemand = field.closest('[data-ondemand]').length > 0;\n\n      if (!field.length || field.get(0).selectize) {\n        return;\n      }\n\n      var getData = function getData(field, callback) {\n        var mode = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'all';\n        var url = grav_config__WEBPACK_IMPORTED_MODULE_1__.config.current_url + \".json/task\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"getFilesInFolder\");\n        var parent = field.closest('[data-grav-filepicker]');\n        var name = parent.data('name');\n        var value = parent.data('value');\n        var params = JSON.stringify(grav_config__WEBPACK_IMPORTED_MODULE_1__.uri_params || '{}');\n        (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n          method: 'post',\n          body: {\n            name: name,\n            params: params\n          }\n        }, function (response) {\n          if (typeof response.files === 'undefined') {\n            return;\n          }\n\n          var data = [];\n          thumbs = response.thumbs || {};\n\n          for (var i = 0; i < response.files.length; i++) {\n            if (mode === 'selected' && response.files[i] !== value) {\n              continue;\n            }\n\n            data.push({\n              'name': response.files[i],\n              'status': 'available',\n              thumb: thumbs[response.files[i]] || ''\n            });\n          }\n\n          for (var _i = 0; _i < response.pending.length; _i++) {\n            if (mode === 'selected' && response.pending[_i] !== value) {\n              continue;\n            }\n\n            data.push({\n              'name': response.pending[_i],\n              'status': 'pending',\n              thumb: thumbs[response.pending[_i]] || ''\n            });\n          }\n\n          folder = response.folder;\n          callback(data, value);\n        });\n      };\n\n      var imagesPreview = field.closest('[data-preview-images]').length > 0;\n      var selectedIsRendered = false;\n\n      var renderOption = function renderOption(item, escape) {\n        var image = '';\n\n        if (imagesPreview && folder && (!item.status || item.status === 'available') && item.name.match(/\\.(jpg|jpeg|png|gif)$/i)) {\n          // const fallback2x = insertTextAt(`${config.base_url_relative}/../${folder}/${item.name}`, -4, '@2x');\n          // const fallback3x = insertTextAt(`${config.base_url_relative}/../${folder}/${item.name}`, -4, '@3x');\n          var source = thumbs[item.name] || \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/../\").concat(folder, \"/\").concat(item.name); // onerror=\"if(this.src==='${fallback2x}'){this.src='${fallback3x}';}else{this.src='${fallback2x}'}\"\n\n          image = \"<img class=\\\"filepicker-field-image\\\" src=\\\"\".concat(source, \"\\\" />\");\n        }\n\n        return \"<div>\\n                        <span class=\\\"title\\\">\\n                            \".concat(image, \" <span class=\\\"name filepicker-field-name\\\">\").concat(escape(item.name), \"</span>\\n                        </span>\\n                    </div>\");\n      };\n\n      field.selectize({\n        plugins: ['required-fix'],\n        valueField: 'name',\n        labelField: 'name',\n        searchField: 'name',\n        optgroups: [{\n          $order: 1,\n          value: 'pending',\n          label: 'Pending'\n        }, {\n          $order: 2,\n          value: 'available',\n          label: 'Available'\n        }],\n        optgroupField: 'status',\n        // lockOptgroupOrder: true,\n        create: false,\n        preload: false,\n        // 'focus',\n        render: {\n          option: function option(item, escape) {\n            return renderOption(item, escape);\n          },\n          item: function item(_item, escape) {\n            return renderOption(_item, escape);\n          }\n        },\n        onInitialize: function onInitialize() {\n          if (!onDemand) {\n            this.load(function (callback) {\n              return getData(field, function (data) {\n                return callback(data);\n              }, 'selected');\n            });\n          }\n        },\n        onLoad: function onLoad()\n        /* data */\n        {\n          if (!selectedIsRendered) {\n            var name = this.getValue();\n            this.updateOption(name, {\n              name: name\n            });\n            selectedIsRendered = true;\n          }\n        },\n        onFocus: function onFocus() {\n          this.load(function (callback) {\n            return getData(field, function (data) {\n              return callback(data);\n            });\n          });\n        }\n      });\n    }\n  }]);\n\n  return FilePickerField;\n}();\n\n\nvar Instance = new FilePickerField();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 14996 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/filepicker.js\n");

/***/ }),

/***/ "./app/forms/fields/files.js":
/*!***********************************!*\
  !*** ./app/forms/fields/files.js ***!
  \***********************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export UriToMarkdown [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ FilesField,\n/* harmony export */   \"UriToMarkdown\": () => /* binding */ UriToMarkdown,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var dropzone__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! dropzone */ \"./node_modules/dropzone/dist/dropzone.js\");\n/* harmony import */ var dropzone__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(dropzone__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../utils/request */ \"./app/utils/request.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_3__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n // import EXIF from 'exif-js';\n\n\n // translations\n\nvar Dictionary = {\n  dictCancelUpload: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_CANCEL_UPLOAD,\n  dictCancelUploadConfirmation: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_CANCEL_UPLOAD_CONFIRMATION,\n  dictDefaultMessage: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_DEFAULT_MESSAGE,\n  dictFallbackMessage: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_FALLBACK_MESSAGE,\n  dictFallbackText: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_FALLBACK_TEXT,\n  dictFileTooBig: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_FILE_TOO_BIG,\n  dictInvalidFileType: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_INVALID_FILE_TYPE,\n  dictMaxFilesExceeded: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_MAX_FILES_EXCEEDED,\n  dictRemoveFile: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_REMOVE_FILE,\n  dictResponseError: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROPZONE_RESPONSE_ERROR\n};\n(dropzone__WEBPACK_IMPORTED_MODULE_1___default().autoDiscover) = false;\n(dropzone__WEBPACK_IMPORTED_MODULE_1___default().options.gravPageDropzone) = {};\n\n(dropzone__WEBPACK_IMPORTED_MODULE_1___default().confirm) = function (question, accepted, rejected) {\n  var doc = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document);\n  var modalSelector = '[data-remodal-id=\"delete-media\"]';\n\n  var removeEvents = function removeEvents() {\n    doc.off('confirmation', modalSelector, accept);\n    doc.off('cancellation', modalSelector, reject);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(modalSelector).find('.remodal-confirm').removeClass('pointer-events-disabled');\n  };\n\n  var accept = function accept() {\n    accepted && accepted();\n    removeEvents();\n  };\n\n  var reject = function reject() {\n    rejected && rejected();\n    removeEvents();\n  };\n\n  (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[jquery__WEBPACK_IMPORTED_MODULE_0___default()(modalSelector).data('remodal')].open();\n  doc.on('confirmation', modalSelector, accept);\n  doc.on('cancellation', modalSelector, reject);\n};\n\nvar DropzoneMediaConfig = {\n  timeout: 0,\n  thumbnailWidth: 200,\n  thumbnailHeight: 150,\n  addRemoveLinks: false,\n  dictDefaultMessage: grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DROP_FILES_HERE_TO_UPLOAD.replace(/&lt;/g, '<').replace(/&gt;/g, '>'),\n  dictRemoveFileConfirmation: '[placeholder]',\n  previewTemplate: \"\\n        <div class=\\\"dz-preview dz-file-preview dz-no-editor\\\">\\n          <div class=\\\"dz-details\\\">\\n            <div class=\\\"dz-filename\\\"><span data-dz-name></span></div>\\n            <div class=\\\"dz-size\\\" data-dz-size></div>\\n            <img data-dz-thumbnail />\\n          </div>\\n          <div class=\\\"dz-progress\\\"><span class=\\\"dz-upload\\\" data-dz-uploadprogress></span></div>\\n          <div class=\\\"dz-success-mark\\\"><span>\\u2714</span></div>\\n          <div class=\\\"dz-error-mark\\\"><span>\\u2718</span></div>\\n          <div class=\\\"dz-error-message\\\"><span data-dz-errormessage></span></div>\\n          <a class=\\\"dz-unset\\\" title=\\\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.UNSET, \"\\\" href=\\\"#\\\" data-dz-unset>\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.UNSET, \"</a>\\n          <a class=\\\"dz-remove\\\" title=\\\"\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DELETE, \"\\\" href=\\\"javascript:undefined;\\\" data-dz-remove>\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DELETE, \"</a>\\n          <a class=\\\"dz-metadata\\\" title=\\\"\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.METADATA, \"\\\" href=\\\"#\\\" target=\\\"_blank\\\" data-dz-metadata>\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.METADATA, \"</a>\\n          <a class=\\\"dz-view\\\" title=\\\"\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.VIEW, \"\\\" href=\\\"#\\\" target=\\\"_blank\\\" data-dz-view>\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.VIEW, \"</a>\\n        </div>\").trim()\n}; // global.EXIF = EXIF;\n\nvar ACCEPT_FUNC = function ACCEPT_FUNC(file, done, settings) {\n  var resolution = settings.resolution;\n  if (!resolution) return done();\n  var reader = new FileReader();\n  var error = '';\n  var hasMin = resolution.min && (resolution.min.width || resolution.min.height);\n  var hasMax = resolution.max && (resolution.max.width || resolution.max.height);\n\n  if (hasMin || !(settings.resizeWidth || settings.resizeHeight) && hasMax) {\n    reader.onload = function (event) {\n      var image = new Image();\n      image.src = event.target.result;\n\n      image.onload = function () {\n        var _this = this;\n\n        if (resolution.min) {\n          Object.keys(resolution.min).forEach(function (attr) {\n            if (resolution.min[attr] && _this[attr] < resolution.min[attr]) {\n              error += grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_FORM.RESOLUTION_MIN.replace(/{{attr}}/g, attr).replace(/{{min}}/g, resolution.min[attr]);\n            }\n          });\n        }\n\n        if (!(settings.resizeWidth || settings.resizeHeight)) {\n          if (resolution.max) {\n            Object.keys(resolution.max).forEach(function (attr) {\n              if (resolution.max[attr] && _this[attr] > resolution.max[attr]) {\n                error += grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_FORM.RESOLUTION_MAX.replace(/{{attr}}/g, attr).replace(/{{max}}/g, resolution.max[attr]);\n              }\n            });\n          }\n        }\n\n        return error ? done(error) : done();\n      };\n    };\n\n    reader.readAsDataURL(file);\n  } else {\n    return error ? done(error) : done();\n  }\n};\n\nvar FilesField = /*#__PURE__*/function () {\n  function FilesField() {\n    var _this2 = this;\n\n    var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},\n        _ref$container = _ref.container,\n        container = _ref$container === void 0 ? '.dropzone.files-upload' : _ref$container,\n        _ref$options = _ref.options,\n        options = _ref$options === void 0 ? {} : _ref$options;\n\n    _classCallCheck(this, FilesField);\n\n    this.container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(container);\n\n    if (!this.container.length) {\n      return;\n    }\n\n    this.urls = {};\n    this.customPost = this.container.data('filePostAdd') || {};\n    this.options = Object.assign({}, Dictionary, DropzoneMediaConfig, {\n      klass: this,\n      url: this.container.data('file-url-add') || grav_config__WEBPACK_IMPORTED_MODULE_3__.config.current_url,\n      acceptedFiles: this.container.data('media-types'),\n      init: this.initDropzone\n    }, this.container.data('dropzone-options'), options);\n    this.options = Object.assign({}, this.options, {\n      accept: function accept(file, done) {\n        ACCEPT_FUNC(file, done, this.options);\n      }\n    });\n    this.dropzone = new (dropzone__WEBPACK_IMPORTED_MODULE_1___default())(container, this.options);\n    this.dropzone.on('complete', this.onDropzoneComplete.bind(this));\n    this.dropzone.on('success', this.onDropzoneSuccess.bind(this));\n    this.dropzone.on('removedfile', this.onDropzoneRemovedFile.bind(this));\n    this.dropzone.on('sending', this.onDropzoneSending.bind(this));\n    this.dropzone.on('error', this.onDropzoneError.bind(this));\n    this.container.on('mouseenter', '[data-dz-view]', function (e) {\n      var value = JSON.parse(_this2.container.find('[name][type=\"hidden\"]').val() || '{}');\n      var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.currentTarget);\n      var file = target.parent('.dz-preview').find('.dz-filename');\n      var filename = encodeURI(file.text());\n      var URL = Object.keys(value).filter(function (key) {\n        return value[key].name === filename;\n      }).shift();\n      target.attr('href', \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.config.base_url_simple, \"/\").concat(URL));\n    });\n  }\n\n  _createClass(FilesField, [{\n    key: \"initDropzone\",\n    value: function initDropzone() {\n      var _this3 = this;\n\n      var files = this.options.klass.container.find('[data-file]');\n      var dropzone = this;\n\n      if (!files.length) {\n        return;\n      }\n\n      files.each(function (index, file) {\n        file = jquery__WEBPACK_IMPORTED_MODULE_0___default()(file);\n        var data = file.data('file');\n        var mock = {\n          name: data.name,\n          size: data.size,\n          type: data.type,\n          status: (dropzone__WEBPACK_IMPORTED_MODULE_1___default().ADDED),\n          accepted: true,\n          url: _this3.options.url,\n          removeUrl: data.remove\n        };\n        dropzone.files.push(mock);\n        dropzone.options.addedfile.call(dropzone, mock);\n\n        if (mock.type.match(/^image\\//)) {\n          dropzone.options.thumbnail.call(dropzone, mock, data.path);\n          dropzone.createThumbnailFromUrl(mock, data.path);\n        }\n\n        file.remove();\n      });\n    }\n  }, {\n    key: \"getURI\",\n    value: function getURI() {\n      return this.container.data('mediaUri') || '';\n    }\n  }, {\n    key: \"onDropzoneSending\",\n    value: function onDropzoneSending(file, xhr, formData) {\n      var _this4 = this;\n\n      if (Object.keys(this.customPost).length) {\n        Object.keys(this.customPost).forEach(function (key) {\n          formData.append(key, _this4.customPost[key]);\n        });\n      } else {\n        formData.append('name', this.options.dotNotation);\n        formData.append('task', 'filesupload');\n        formData.append('uri', this.getURI());\n      }\n\n      formData.append('admin-nonce', grav_config__WEBPACK_IMPORTED_MODULE_3__.config.admin_nonce);\n    }\n  }, {\n    key: \"onDropzoneSuccess\",\n    value: function onDropzoneSuccess(file, response, xhr) {\n      response = typeof response === 'string' ? JSON.parse(response) : response;\n\n      if (this.options.reloadPage) {\n        __webpack_require__.g.location.reload();\n      } // store params for removing file from session before it gets saved\n\n\n      if (response.session) {\n        file.sessionParams = response.session;\n        file.removeUrl = this.options.url; // Touch field value to force a mutation detection\n\n        var input = this.container.find('[name][type=\"hidden\"]');\n        var value = input.val();\n        input.val(value + ' ');\n      }\n\n      return this.handleError({\n        file: file,\n        data: response,\n        mode: 'removeFile',\n        msg: \"<p>\".concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.FILE_ERROR_UPLOAD, \" <strong>\").concat(file.name, \"</strong></p>\\n            <pre>\").concat(response.message, \"</pre>\")\n      });\n    }\n  }, {\n    key: \"onDropzoneComplete\",\n    value: function onDropzoneComplete(file) {\n      if (!file.accepted && !file.rejected) {\n        var data = {\n          status: 'error',\n          message: \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.FILE_UNSUPPORTED, \": \").concat(file.name.match(/\\..+/).join(''))\n        };\n        return this.handleError({\n          file: file,\n          data: data,\n          mode: 'removeFile',\n          msg: \"<p>\".concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.FILE_ERROR_ADD, \" <strong>\").concat(file.name, \"</strong></p>\\n                <pre>\").concat(data.message, \"</pre>\")\n        });\n      }\n\n      if (this.options.reloadPage) {\n        __webpack_require__.g.location.reload();\n      }\n    }\n  }, {\n    key: \"b64_to_utf8\",\n    value: function b64_to_utf8(str) {\n      str = str.replace(/\\s/g, '');\n      return decodeURIComponent(escape(window.atob(str)));\n    }\n  }, {\n    key: \"onDropzoneRemovedFile\",\n    value: function onDropzoneRemovedFile(file) {\n      var _this5 = this;\n\n      if (!file.accepted || file.rejected) {\n        return;\n      }\n\n      var url = file.removeUrl || this.urls[\"delete\"] || this.options.url;\n      var path = (url || '').match(/path:(.*)\\//);\n      var body = {\n        filename: file.name,\n        uri: this.getURI()\n      };\n\n      if (file.sessionParams) {\n        body.task = 'filessessionremove';\n        body.session = file.sessionParams;\n      }\n\n      var customPost = this.container.data('filePostRemove') || {};\n\n      if (Object.keys(customPost).length) {\n        body = {};\n        Object.keys(customPost).forEach(function (key) {\n          body[key] = customPost[key];\n        });\n      }\n\n      body['filename'] = file.name;\n      body['admin-nonce'] = grav_config__WEBPACK_IMPORTED_MODULE_3__.config.admin_nonce;\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n        method: 'post',\n        body: body\n      }, function () {\n        if (!path) {\n          return;\n        }\n\n        path = _this5.b64_to_utf8(path[1]);\n\n        var input = _this5.container.find('[name][type=\"hidden\"]');\n\n        var data = JSON.parse(input.val() || '{}');\n        delete data[path];\n        input.val(JSON.stringify(data));\n      });\n    }\n  }, {\n    key: \"onDropzoneError\",\n    value: function onDropzoneError(file, response, xhr) {\n      var message = xhr ? response.error.message : response;\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(file.previewElement).find('[data-dz-errormessage]').html(message);\n      return this.handleError({\n        file: file,\n        data: {\n          status: 'error'\n        },\n        msg: \"<pre>\".concat(message, \"</pre>\")\n      });\n    }\n  }, {\n    key: \"handleError\",\n    value: function handleError(options) {\n      var file = options.file,\n          data = options.data,\n          mode = options.mode,\n          msg = options.msg;\n\n      if (data.status !== 'error' && data.status !== 'unauthorized') {\n        return;\n      }\n\n      switch (mode) {\n        case 'addBack':\n          if (file instanceof File) {\n            this.dropzone.addFile.call(this.dropzone, file);\n          } else {\n            this.dropzone.files.push(file);\n            this.dropzone.options.addedfile.call(this.dropzone, file);\n            this.dropzone.options.thumbnail.call(this.dropzone, file, file.extras.url);\n          }\n\n          break;\n\n        case 'removeFile':\n        default:\n          if (~this.dropzone.files.indexOf(file)) {\n            file.rejected = true;\n            this.dropzone.removeFile.call(this.dropzone, file, {\n              silent: true\n            });\n          }\n\n          break;\n      }\n\n      var modal = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=\"generic\"]');\n      modal.find('.error-content').html(msg);\n      (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[modal.data('remodal')].open();\n    }\n  }]);\n\n  return FilesField;\n}();\n\n\nfunction UriToMarkdown(uri) {\n  uri = uri.replace(/@3x|@2x|@1x/, '');\n  uri = uri.replace(/\\(/g, '%28');\n  uri = uri.replace(/\\)/g, '%29');\n  return uri.match(/\\.(jpe?g|png|gif|svg|mp4|webm|ogv|mov)$/i) ? \"![](\".concat(uri, \")\") : \"[\".concat(decodeURI(uri), \"](\").concat(uri, \")\");\n}\nvar instances = [];\nvar cache = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n\nvar onAddedNodes = function onAddedNodes(event, target\n/* , record, instance */\n) {\n  var files = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('.dropzone.files-upload');\n\n  if (!files.length) {\n    return;\n  }\n\n  files.each(function (index, file) {\n    file = jquery__WEBPACK_IMPORTED_MODULE_0___default()(file);\n\n    if (!~cache.index(file)) {\n      addNode(file);\n    }\n  });\n};\n\nvar addNode = function addNode(container) {\n  container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(container);\n  var input = container.find('input[type=\"file\"]');\n  var settings = container.data('grav-file-settings') || {};\n\n  if (settings.accept && ~settings.accept.indexOf('*')) {\n    settings.accept = [''];\n  }\n\n  var options = {\n    url: container.data('file-url-add') || (container.closest('form').attr('action') || grav_config__WEBPACK_IMPORTED_MODULE_3__.config.current_url) + '.json',\n    paramName: settings.paramName || 'file',\n    dotNotation: settings.name || 'file',\n    acceptedFiles: settings.accept ? settings.accept.join(',') : input.attr('accept') || container.data('media-types'),\n    maxFilesize: typeof settings.filesize !== 'undefined' ? settings.filesize : 256,\n    maxFiles: settings.limit || null,\n    resizeWidth: settings.resizeWidth || null,\n    resizeHeight: settings.resizeHeight || null,\n    resizeQuality: settings.resizeQuality || null,\n    accept: function accept(file, done) {\n      ACCEPT_FUNC(file, done, settings);\n    }\n  };\n  cache = cache.add(container);\n  container = container[0];\n  instances.push(new FilesField({\n    container: container,\n    options: options\n  }));\n};\n\nvar Instance = function () {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.dropzone.files-upload').each(function (i, container) {\n    return addNode(container);\n  });\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('mutation._grav', onAddedNodes);\n  return instances;\n}();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 41004 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/files.js\n");

/***/ }),

/***/ "./app/forms/fields/iconpicker.js":
/*!****************************************!*\
  !*** ./app/forms/fields/iconpicker.js ***!
  \****************************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ IconpickerField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n/* Icon Picker by QueryLoop\n * Author: @eliorivero\n * URL: http://queryloop.com/\n * License: GPLv2\n */\n\nvar defaults = {\n  'mode': 'dialog',\n  // show overlay 'dialog' panel or slide down 'inline' panel\n  'closeOnPick': true,\n  // whether to close panel after picking or 'no'\n  'save': 'class',\n  // save icon 'class' or 'code'\n  'size': '',\n  'classes': {\n    'launcher': '',\n    // extra classes for launcher buttons\n    'clear': 'remove-times',\n    // extra classes for button that removes preview and clears field\n    'highlight': '',\n    // extra classes when highlighting an icon\n    'close': '' // extra classes for close button\n\n  },\n  'iconSets': {\n    // example data structure. Used to specify which launchers will be created\n    'genericon': 'Genericon',\n    // create a launcher to pick genericon icons\n    'fa': 'FontAwesome' // create a launcher to pick fontawesome icons\n\n  }\n};\n\nvar QL_Icon_Picker = /*#__PURE__*/function () {\n  function QL_Icon_Picker(element, options) {\n    _classCallCheck(this, QL_Icon_Picker);\n\n    this.iconSet = '';\n    this.iconSetName = '';\n    this.$field = '';\n    this.element = element;\n    this.settings = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, defaults, options);\n    this._defaults = defaults;\n    this.init();\n  }\n\n  _createClass(QL_Icon_Picker, [{\n    key: \"init\",\n    value: function init() {\n      var $brick = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.element);\n      var pickerId = $brick.data('pickerid');\n      var $preview = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class=\"icon-preview icon-preview-' + pickerId + '\" />');\n      this.$field = $brick.find('input'); // Add preview area\n\n      this.makePreview($brick, pickerId, $preview); // Make button to clear field and remove preview\n\n      this.makeClear(pickerId, $preview); // Make buttons that open the panel of icons\n\n      this.makeLaunchers($brick, pickerId); // Prepare display styles, inline and dialog\n\n      this.makeDisplay($brick);\n    }\n  }, {\n    key: \"makePreview\",\n    value: function makePreview($brick, pickerId, $preview) {\n      var $icon = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<i />');\n      var iconValue = this.$field.val();\n      $preview.prependTo($brick);\n      $icon.prependTo($preview);\n\n      if (iconValue !== '') {\n        $preview.addClass('icon-preview-on');\n        $icon.addClass(iconValue);\n      }\n    }\n  }, {\n    key: \"makeClear\",\n    value: function makeClear(pickerId, $preview) {\n      var base = this;\n      var $clear = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<a class=\"remove-icon ' + base.settings.classes.clear + '\" />'); // Hide button to remove icon and preview and append it to preview area\n\n      $clear.hide().prependTo($preview); // If there's a icon saved in the field, show remove icon button\n\n      if (base.$field.val() !== '') {\n        $clear.show();\n      }\n\n      $preview.on('click', '.remove-icon', function (e) {\n        e.preventDefault();\n        base.$field.val('');\n        $preview.removeClass('icon-preview-on').find('i').removeClass();\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).hide();\n      });\n    }\n  }, {\n    key: \"makeDisplay\",\n    value: function makeDisplay($brick) {\n      var base = this;\n      var close = base.settings.classes.close;\n      var $body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\n      var $close = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<a href=\"#\" class=\"icon-picker-close\"/>');\n\n      if (base.settings.mode === 'inline') {\n        $brick.find('.icon-set').append($close).removeClass('dialog').addClass('ip-inline ' + base.settings.size).parent().addClass('icon-set-wrap');\n      } else if (base.settings.mode === 'dialog') {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('.icon-set').addClass('dialog ' + base.settings.size);\n\n        if (jquery__WEBPACK_IMPORTED_MODULE_0___default()('.icon-picker-overlay').length <= 0) {\n          $body.append('<div class=\"icon-picker-overlay\"/>').append($close);\n        }\n      }\n\n      $body.on('click', '.icon-picker-close, .icon-picker-overlay', function (e) {\n        e.preventDefault();\n        base.closePicker($brick, jquery__WEBPACK_IMPORTED_MODULE_0___default()(base.iconSet), base.settings.mode);\n      }).on('mouseenter mouseleave', '.icon-picker-close', function (e) {\n        if (e.type === 'mouseenter') {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).addClass(close);\n        } else {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).removeClass(close);\n        }\n      });\n    }\n  }, {\n    key: \"makeLaunchers\",\n    value: function makeLaunchers($brick) {\n      var base = this;\n      var dataIconSets = $brick.data('iconsets');\n      var iconSet;\n\n      if (typeof dataIconSets === 'undefined') {\n        dataIconSets = base.settings.iconSets;\n      }\n\n      for (iconSet in dataIconSets) {\n        if (dataIconSets.hasOwnProperty(iconSet)) {\n          $brick.append('<a class=\"launch-icons button ' + base.settings.classes.launcher + '\" data-icons=\"' + iconSet + '\">' + dataIconSets[iconSet] + '</a>');\n        }\n      }\n\n      $brick.find('.launch-icons').on('click', function (e) {\n        e.preventDefault();\n        var $self = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n        var theseIcons = $self.data('icons');\n        base.iconSetName = theseIcons;\n        base.iconSet = '.' + theseIcons + '-set'; // Initialize picker\n\n        base.iconPick($brick); // Show icon picker\n\n        base.showPicker($brick, jquery__WEBPACK_IMPORTED_MODULE_0___default()(base.iconSet), base.settings.mode);\n      });\n    }\n  }, {\n    key: \"iconPick\",\n    value: function iconPick($brick) {\n      var base = this;\n      var highlight = 'icon-highlight ' + base.settings.classes.highlight;\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(base.iconSet).on('click', 'li', function (e) {\n        e.preventDefault();\n        var $icon = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n        var icon = $icon.data(base.settings.save); // Mark as selected\n\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('.icon-selected').removeClass('icon-selected');\n        $icon.addClass('icon-selected');\n\n        if (base.$field.data('format') === 'short') {\n          icon = icon.slice(6);\n        } // Save icon value to field\n\n\n        base.$field.val(icon); // Close icon picker\n\n        if (base.settings.closeOnPick) {\n          base.closePicker($brick, $icon.closest(base.iconSet), base.settings.mode);\n        } // Set preview\n\n\n        base.setPreview($icon.data('class')); // Broadcast event passing the selected icon.\n\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').trigger('iconselected.queryloop', icon);\n      });\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(base.iconSet).on('mouseenter mouseleave', 'li', function (e) {\n        if (e.type === 'mouseenter') {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).addClass(highlight);\n        } else {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).removeClass(highlight);\n        }\n      });\n    }\n  }, {\n    key: \"showPicker\",\n    value: function showPicker($brick, $icons, mode) {\n      if (mode === 'inline') {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('.icon-set').removeClass('ip-inline-open');\n        $brick.find($icons).toggleClass('ip-inline-open');\n      } else if (mode === 'dialog') {\n        $brick.find('.icon-picker-close').addClass('make-visible');\n        $brick.find('.icon-picker-overlay').addClass('make-visible');\n        $icons.addClass('dialog-open');\n      }\n\n      $icons.find('.icon-selected').removeClass('icon-selected');\n      var selectedIcon = this.$field.val().replace(' ', '.');\n\n      if (selectedIcon !== '') {\n        if (this.settings.save === 'class') {\n          $icons.find('.' + selectedIcon).addClass('icon-selected');\n        } else {\n          $icons.find('[data-code=\"' + selectedIcon + '\"]').addClass('icon-selected');\n        }\n      } // Broadcast event when the picker is shown passing the picker mode.\n\n\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').trigger('iconpickershow.queryloop', mode);\n    }\n  }, {\n    key: \"closePicker\",\n    value: function closePicker($brick, $icons, mode) {\n      // Remove event so they don't fire from a different picker\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.iconSet).off('click', 'li');\n\n      if (mode === 'inline') {\n        $brick.find($icons).removeClass('ip-inline-open');\n      } else if (mode === 'dialog') {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('.icon-picker-close, .icon-picker-overlay').removeClass('make-visible');\n      } // Broadcast event when the picker is closed passing the picker mode.\n\n\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').trigger('iconpickerclose.queryloop', mode);\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.icon-set').removeClass('dialog-open');\n    }\n  }, {\n    key: \"setPreview\",\n    value: function setPreview(preview) {\n      var $preview = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.element).find('.icon-preview');\n      $preview.addClass('icon-preview-on').find('i').removeClass().addClass(this.iconSetName).addClass(preview);\n      $preview.find('a').show();\n    }\n  }]);\n\n  return QL_Icon_Picker;\n}();\n/* Grav */\n// extend $ with 3rd party QL Icon Picker\n\n\n(jquery__WEBPACK_IMPORTED_MODULE_0___default().fn.qlIconPicker) = function (options) {\n  this.each(function () {\n    if (!jquery__WEBPACK_IMPORTED_MODULE_0___default().data(this, 'plugin_qlIconPicker')) {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default().data(this, 'plugin_qlIconPicker', new QL_Icon_Picker(this, options));\n    }\n  });\n  return this;\n};\n\nvar IconpickerField = /*#__PURE__*/function () {\n  function IconpickerField(options) {\n    var _this = this;\n\n    _classCallCheck(this, IconpickerField);\n\n    this.items = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n    this.options = Object.assign({}, this.defaults, options);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-iconpicker]').each(function (index, element) {\n      return _this.addItem(element);\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('mutation._grav', this._onAddedNodes.bind(this));\n  }\n\n  _createClass(IconpickerField, [{\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target\n    /* , record, instance */\n    ) {\n      var _this2 = this;\n\n      var fields = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('[data-grav-iconpicker]');\n\n      if (!fields.length) {\n        return;\n      }\n\n      fields.each(function (index, field) {\n        field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(field);\n\n        if (!~_this2.items.index(field)) {\n          _this2.addItem(field);\n        }\n      });\n    }\n  }, {\n    key: \"addItem\",\n    value: function addItem(element) {\n      element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n      this.items = this.items.add(element);\n      element.find('.icon-picker').qlIconPicker({\n        'save': 'class'\n      }); // hack to remove extra icon sets that are just copies\n\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.icon-set:not(:first)').remove();\n    }\n  }]);\n\n  return IconpickerField;\n}();\n\n\nvar Instance = new IconpickerField(); // Fix to close the dialog when clicking outside\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', function (event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n  var match = '.icon-set.dialog-open, .launch-icons[data-icons]';\n\n  if (!target.is(match) && !target.closest(match).length) {\n    var dialogs = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.icon-set.dialog-open'); // skip if there's no dialog open\n\n    if (dialogs.length) {\n      dialogs.each(function (index, dialog) {\n        var picker = jquery__WEBPACK_IMPORTED_MODULE_0___default()(dialog).siblings('.icon-picker');\n        var data = picker.data('plugin_qlIconPicker');\n        data.closePicker(picker, jquery__WEBPACK_IMPORTED_MODULE_0___default()(data.iconSet), data.settings.mode);\n      });\n    }\n  }\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 27576 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/iconpicker.js\n");

/***/ }),

/***/ "./app/forms/fields/indeterminate.js":
/*!*******************************************!*\
  !*** ./app/forms/fields/indeterminate.js ***!
  \*******************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\ndocument.addEventListener('click', function (event) {\n  if (document.querySelector('#pages-filters')) {\n    return true;\n  }\n\n  var wrapper = event.target.closest('.checkboxes.indeterminate');\n\n  if (wrapper) {\n    event.preventDefault();\n    var checkbox = wrapper.querySelector('input[type=\"checkbox\"]:not([disabled])');\n    var checkStatus = wrapper.dataset._checkStatus;\n    wrapper.classList.remove('status-checked', 'status-unchecked', 'status-indeterminate');\n\n    switch (checkStatus) {\n      // checked, going indeterminate\n      case '1':\n        wrapper.dataset._checkStatus = '2';\n        checkbox.indeterminate = true;\n        checkbox.checked = false;\n        checkbox.value = 0;\n        wrapper.classList.add('status-indeterminate');\n        break;\n      // indeterminate, going unchecked\n\n      case '2':\n        wrapper.dataset._checkStatus = '0';\n        checkbox.indeterminate = false;\n        checkbox.checked = false;\n        checkbox.value = '';\n        wrapper.classList.add('status-unchecked');\n        break;\n      // unchecked, going checked\n\n      case '0':\n      default:\n        wrapper.dataset._checkStatus = '1';\n        checkbox.indeterminate = false;\n        checkbox.checked = true;\n        checkbox.value = 1;\n        wrapper.classList.add('status-checked');\n        break;\n    } // const input = new CustomEvent('input', { detail: { target: checkbox }});\n    // document.dispatchEvent(input);\n\n\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(checkbox).trigger('input');\n  }\n});\n(document.querySelectorAll('input[type=\"checkbox\"][indeterminate=\"true\"]') || []).forEach(function (input) {\n  input.indeterminate = true;\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4996 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/indeterminate.js\n");

/***/ }),

/***/ "./app/forms/fields/index.js":
/*!***********************************!*\
  !*** ./app/forms/fields/index.js ***!
  \***********************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var _filepicker__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./filepicker */ \"./app/forms/fields/filepicker.js\");\n/* harmony import */ var _selectize__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./selectize */ \"./app/forms/fields/selectize.js\");\n/* harmony import */ var _array__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./array */ \"./app/forms/fields/array.js\");\n/* harmony import */ var _collections__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./collections */ \"./app/forms/fields/collections.js\");\n/* harmony import */ var _datetime__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./datetime */ \"./app/forms/fields/datetime.js\");\n/* harmony import */ var _editor__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./editor */ \"./app/forms/fields/editor.js\");\n/* harmony import */ var _colorpicker__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./colorpicker */ \"./app/forms/fields/colorpicker.js\");\n/* harmony import */ var _files__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./files */ \"./app/forms/fields/files.js\");\n/* harmony import */ var _selectunique__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./selectunique */ \"./app/forms/fields/selectunique.js\");\n/* harmony import */ var _iconpicker__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./iconpicker */ \"./app/forms/fields/iconpicker.js\");\n/* harmony import */ var _cron__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./cron */ \"./app/forms/fields/cron.js\");\n/* harmony import */ var _parents__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./parents */ \"./app/forms/fields/parents.js\");\n/* harmony import */ var _acl_picker__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./acl-picker */ \"./app/forms/fields/acl-picker.js\");\n/* harmony import */ var _permissions__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./permissions */ \"./app/forms/fields/permissions.js\");\n/* harmony import */ var _indeterminate__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./indeterminate */ \"./app/forms/fields/indeterminate.js\");\n/* harmony import */ var _mediapicker__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./mediapicker */ \"./app/forms/fields/mediapicker.js\");\n/* harmony import */ var _multilevel__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./multilevel */ \"./app/forms/fields/multilevel.js\");\n/* harmony import */ var _text__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./text */ \"./app/forms/fields/text.js\");\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({\n  FilepickerField: {\n    FilepickerField: _filepicker__WEBPACK_IMPORTED_MODULE_0__.default,\n    Instance: _filepicker__WEBPACK_IMPORTED_MODULE_0__.Instance\n  },\n  SelectizeField: {\n    SelectizeField: _selectize__WEBPACK_IMPORTED_MODULE_1__.default,\n    Instance: _selectize__WEBPACK_IMPORTED_MODULE_1__.Instance\n  },\n  ArrayField: {\n    ArrayField: _array__WEBPACK_IMPORTED_MODULE_2__.default,\n    Instance: _array__WEBPACK_IMPORTED_MODULE_2__.Instance\n  },\n  CollectionsField: {\n    CollectionsField: _collections__WEBPACK_IMPORTED_MODULE_3__.default,\n    Instance: _collections__WEBPACK_IMPORTED_MODULE_3__.Instance\n  },\n  DateTimeField: {\n    DateTimeField: _datetime__WEBPACK_IMPORTED_MODULE_4__.default,\n    Instance: _datetime__WEBPACK_IMPORTED_MODULE_4__.Instance\n  },\n  EditorField: {\n    EditorField: _editor__WEBPACK_IMPORTED_MODULE_5__.default,\n    Instance: _editor__WEBPACK_IMPORTED_MODULE_5__.Instance\n  },\n  ColorpickerField: {\n    ColorpickerField: _colorpicker__WEBPACK_IMPORTED_MODULE_6__.default,\n    Instance: _colorpicker__WEBPACK_IMPORTED_MODULE_6__.Instance\n  },\n  FilesField: {\n    FilesField: _files__WEBPACK_IMPORTED_MODULE_7__.default,\n    Instance: _files__WEBPACK_IMPORTED_MODULE_7__.Instance\n  },\n  SelectUniqueField: {\n    SelectUniqueField: _selectunique__WEBPACK_IMPORTED_MODULE_8__.default,\n    Instance: _selectunique__WEBPACK_IMPORTED_MODULE_8__.Instance\n  },\n  IconpickerField: {\n    IconpickerField: _iconpicker__WEBPACK_IMPORTED_MODULE_9__.default,\n    Instance: _iconpicker__WEBPACK_IMPORTED_MODULE_9__.Instance\n  },\n  CronField: {\n    CronField: _cron__WEBPACK_IMPORTED_MODULE_10__.default,\n    Instance: _cron__WEBPACK_IMPORTED_MODULE_10__.Instance\n  },\n  ParentsField: {\n    ParentsField: _parents__WEBPACK_IMPORTED_MODULE_11__.default,\n    Instance: _parents__WEBPACK_IMPORTED_MODULE_11__.Instances\n  }\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 5332 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/index.js\n");

/***/ }),

/***/ "./app/forms/fields/mediapicker.js":
/*!*****************************************!*\
  !*** ./app/forms/fields/mediapicker.js ***!
  \*****************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _pages_tree__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../pages/tree */ \"./app/pages/tree.js\");\n\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(function () {\n  var modal = '';\n  var body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body'); // Thumb Resizer\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('input change', '.media-container .media-range', function (event) {\n    var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n    var container = target.closest('.remodal');\n    var cards = container.find('.media-container div.card-item');\n    var width = target.val() + 'px';\n    cards.each(function () {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).css('width', width);\n    });\n  });\n  body.on('click', '[data-mediapicker-modal-trigger]', function (event) {\n    var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n    var modal_identifier = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('grav-mediapicker-unique-identifier');\n    var modal_element = body.find(\"[data-remodal-unique-identifier=\\\"\".concat(modal_identifier, \"\\\"]\"));\n    modal = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[modal_element.data('remodal')];\n\n    if (!modal) {\n      modal_element.remodal();\n      modal = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[modal_element.data('remodal')];\n    }\n\n    modal.open();\n    modal.dataField = element.find('input'); // load all media\n\n    modal_element.find('.js__files').trigger('fillView');\n    setTimeout(function () {\n      return _pages_tree__WEBPACK_IMPORTED_MODULE_1__.Instance.reload();\n    }, 100);\n  });\n  /* handle media modal click actions */\n\n  body.on('click', '[data-remodal-mediapicker] .media-container.in-modal .admin-media-details a', function (event) {\n    event.preventDefault();\n    event.stopPropagation();\n    var val = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).parents('.js__media-element').data('file-url');\n    var string = val.replace(/ /g, '%20');\n    modal.dataField.val(string);\n    modal.close();\n  });\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 5204 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/mediapicker.js\n");

/***/ }),

/***/ "./app/forms/fields/multilevel.js":
/*!****************************************!*\
  !*** ./app/forms/fields/multilevel.js ***!
  \****************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(function () {\n  var getField = function getField(level, name) {\n    var levelMargin = level * 50;\n    var top = level === 0 ? 'top' : '';\n    var the_name = 'name=\"' + name + '\"';\n\n    if (level === 0) {\n      // top\n      the_name = 'data-attr-name=\"' + name + '\"';\n    }\n\n    var field = \"\\n            <div class=\\\"element-wrapper\\\">\\n                <div class=\\\"form-row array-field-value_only js__multilevel-field \".concat(top, \"\\\"\\n                    data-grav-array-type=\\\"row\\\">\\n                    <input\\n                        type=\\\"text\\\"\\n                        \").concat(the_name, \"\\n                        placeholder=\\\"Enter value\\\"\\n                        style=\\\"margin-left: \").concat(levelMargin, \"px\\\"\\n                        value=\\\"\\\" />\\n\\n                    <span class=\\\"fa fa-minus js__remove-item\\\"></span>\\n                    <span class=\\\"fa fa-plus js__add-sibling hidden\\\" data-level=\\\"\").concat(level, \"\\\" ></span>\\n                    <span class=\\\"fa fa-plus-circle js__add-children hidden\\\" data-level=\\\"\").concat(level, \"\\\"></span>\\n                </div>\\n            </div>\\n        \");\n    return field;\n  };\n\n  var hasChildInputs = function hasChildInputs($element) {\n    if ($element.attr('name')) {\n      return false;\n    }\n\n    return true;\n  };\n\n  var getTopItems = function getTopItems(element) {\n    return jquery__WEBPACK_IMPORTED_MODULE_0___default()(element + ' .js__multilevel-field.top');\n  };\n\n  var refreshControls = function refreshControls(unique_identifier) {\n    var element = '[data-grav-multilevel-field]';\n\n    if (unique_identifier) {\n      element = '[data-grav-multilevel-field][data-id=\"' + unique_identifier + '\"]';\n    }\n\n    var hideButtons = function hideButtons() {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(element + ' .js__add-sibling').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(element + ' .js__add-children').addClass('hidden');\n    };\n\n    var restoreAddSiblingButtons = function restoreAddSiblingButtons() {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(element + ' .children-wrapper').each(function () {\n        var elements = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).children();\n        elements.last().each(function () {\n          var field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n\n          if (!jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).hasClass('js__multilevel-field')) {\n            field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).find('.js__multilevel-field').first();\n          }\n\n          field.find('.js__add-sibling').removeClass('hidden');\n        });\n      }); // add sibling to the last top element\n\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(element + ' .js__multilevel-field.top').last().find('.js__add-sibling').removeClass('hidden');\n    };\n\n    var restoreAddChildrenButtons = function restoreAddChildrenButtons() {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(element + ' .js__multilevel-field').each(function () {\n        if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).siblings('.children-wrapper').length === 0 || jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).siblings('.children-wrapper').find('.js__multilevel-field').length === 0) {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).find('.js__add-children').removeClass('hidden');\n        }\n      });\n    };\n\n    var preventRemovingLastTopItem = function preventRemovingLastTopItem() {\n      var top_items = getTopItems(element);\n\n      if (top_items.length === 1) {\n        top_items.first().find('.js__remove-item').addClass('hidden');\n      }\n    };\n\n    hideButtons();\n    restoreAddSiblingButtons();\n    restoreAddChildrenButtons();\n    preventRemovingLastTopItem();\n  };\n\n  var changeAllOccurrencesInTree = function changeAllOccurrencesInTree($el, current_name, new_name) {\n    $el.parents('[data-grav-multilevel-field]').find('input').each(function () {\n      var $input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n\n      if ($input.attr('name')) {\n        $input.attr('name', $input.attr('name').replace(current_name, new_name));\n      }\n\n      if ($input.attr('data-attr-name')) {\n        $input.attr('data-attr-name', $input.attr('data-attr-name').replace(current_name, new_name));\n      }\n    });\n  };\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).ready(function () {\n    refreshControls();\n  });\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('mouseleave', '[data-grav-multilevel-field]', function (event) {\n    var top_items = getTopItems('[data-id=\"' + jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('id') + '\"]');\n    var has_top_items_without_children = false;\n    var element_content = '';\n    top_items.each(function () {\n      var item = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n\n      if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(item).siblings('.children-wrapper').find('input').length === 0) {\n        has_top_items_without_children = true;\n        element_content = item.find('input').val();\n      }\n    });\n\n    if (has_top_items_without_children) {\n      if (element_content) {\n        alert('Warning: if you save now, the element ' + element_content + ', without children, will be removed, because it\\'s invalid YAML');\n      } else {\n        alert('Warning: if you save now, the top elements without children will be removed, because it\\'s invalid YAML');\n      }\n    }\n  });\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-grav-multilevel-field] .js__add-children', function (event) {\n    var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n    var unique_container_id = element.closest('.js__multilevel-field').data('id');\n    var level = element.data('level') + 1;\n\n    var getParentOfElement = function getParentOfElement(element) {\n      var parent = element.closest('.js__multilevel-field').parent().first();\n\n      if (parent.find('.children-wrapper').length === 0) {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()(parent).append('<div class=\"children-wrapper\"></div>');\n      }\n\n      parent = parent.find('.children-wrapper').first();\n      return parent;\n    };\n\n    var getNameFromParentInput = function getNameFromParentInput(parentInput, attr) {\n      if (parentInput.hasClass('children-wrapper')) {\n        parentInput = parentInput.siblings('.js__multilevel-field').first().find('input');\n      }\n\n      return parentInput.attr(attr) + '[' + parentInput.val() + ']';\n    };\n\n    var getInputFromChildrenWrapper = function getInputFromChildrenWrapper(parentChildrenWrapper) {\n      return parentChildrenWrapper.siblings('.js__multilevel-field').first().find('input');\n    };\n\n    var parentChildrenWrapper = getParentOfElement(element);\n    var parentInput = getInputFromChildrenWrapper(parentChildrenWrapper);\n    var attr = 'name';\n\n    if (parentInput.closest('.js__multilevel-field').hasClass('top')) {\n      attr = 'data-attr-name';\n    }\n\n    parentInput.attr(attr, parentInput.attr(attr).replace('[]', ''));\n    var name = getNameFromParentInput(parentInput, attr);\n    var field = getField(level, name);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(parentChildrenWrapper).append(field);\n    refreshControls(unique_container_id);\n  });\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-grav-multilevel-field] .js__add-sibling', function (event) {\n    var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n    var unique_container_id = element.closest('.js__multilevel-field').data('id');\n    var level = element.data('level');\n    element.closest('.children-wrapper').find('.js__add-sibling').addClass('hidden');\n    var sibling = null;\n    var is_top = false;\n\n    if (element.closest('.js__multilevel-field').hasClass('top')) {\n      is_top = true;\n    }\n\n    if (is_top) {\n      sibling = element.closest('.js__multilevel-field').first().find('input').last();\n    } else {\n      sibling = element.siblings('input').first();\n\n      if (!sibling) {\n        sibling = element.closest('.children-wrapper').first().find('input').last();\n      }\n    }\n\n    var getParentOfElement = function getParentOfElement(element) {\n      var parent = element.closest('.js__multilevel-field').parent().first();\n\n      if (!parent.hasClass('element-wrapper')) {\n        if (parent.find('.element-wrapper').length === 0) {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()(parent).append('<div class=\"element-wrapper\"></div>');\n        }\n\n        parent = parent.find('.element-wrapper').first();\n      }\n\n      return parent;\n    };\n\n    var getNameFromSibling = function getNameFromSibling(parent, sibling) {\n      var is_top = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n      var name = sibling.attr('name');\n\n      if (hasChildInputs(sibling)) {\n        var val = sibling.data('attr-name') + '[]';\n        sibling.removeAttr('name');\n        return val;\n      }\n\n      var last_index = name.lastIndexOf('[');\n      var almost_there = name.substr(last_index + 1);\n      var last_tag = almost_there.substr(0, almost_there.length - 1);\n\n      if (jquery__WEBPACK_IMPORTED_MODULE_0___default().isNumeric(last_tag)) {\n        name = name.replace('[' + last_tag + ']', '[' + (parseInt(last_tag, 10) + 1) + ']');\n      } else {\n        if (is_top) {\n          name = name.replace('[' + last_tag + ']', '');\n        } else {\n          name = name + '[1]'; // change sibling name attr if necessary\n\n          if (sibling.attr('name').slice('-2') !== '[0]') {\n            changeAllOccurrencesInTree(sibling, sibling.attr('name'), sibling.attr('name') + '[0]');\n          }\n        }\n      }\n\n      return name;\n    };\n\n    var parent = getParentOfElement(element);\n    var name = getNameFromSibling(parent, sibling, is_top);\n    var field = getField(level, name);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(field).insertAfter(parent);\n    refreshControls(unique_container_id);\n  });\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-grav-multilevel-field] .js__remove-item', function (event) {\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).parents('.element-wrapper').first().remove();\n    var unique_container_id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).closest('.js__multilevel-field').data('id');\n    refreshControls(unique_container_id);\n  }); // Store old value before editing a field\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('focusin', '[data-grav-multilevel-field] input', function (event) {\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('current-value', jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).val());\n  }); // Handle field edited event\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('change', '[data-grav-multilevel-field] input', function (event) {\n    var $el = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n    var old_value = $el.data('current-value');\n    var new_value = $el.val();\n    var full_name = $el.attr('name') || $el.attr('data-attr-name'); // first-level items have `data-attr-name` instead of `name`\n\n    var old_name_attr = full_name + '[' + old_value + ']';\n    var new_name_attr = full_name + '[' + new_value + ']';\n    changeAllOccurrencesInTree($el, old_name_attr, new_name_attr);\n  });\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 28532 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/multilevel.js\n");

/***/ }),

/***/ "./app/forms/fields/parents.js":
/*!*************************************!*\
  !*** ./app/forms/fields/parents.js ***!
  \*************************************/
/*! namespace exports */
/*! export Instances [provided] [no usage info] [missing usage info prevents renaming] */
/*! export b64_decode_unicode [provided] [no usage info] [missing usage info prevents renaming] */
/*! export b64_encode_unicode [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"Instances\": () => /* binding */ Instances,\n/* harmony export */   \"default\": () => /* binding */ Parents,\n/* harmony export */   \"b64_encode_unicode\": () => /* binding */ b64_encode_unicode,\n/* harmony export */   \"b64_decode_unicode\": () => /* binding */ b64_decode_unicode\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_finderjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../utils/finderjs */ \"./app/utils/finderjs.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_2__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\nvar XHRUUID = 0;\nvar Instances = {};\n\nvar Parents = /*#__PURE__*/function () {\n  function Parents(container, field, data) {\n    var _this = this;\n\n    _classCallCheck(this, Parents);\n\n    this.container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(container);\n    this.fieldName = field.attr('name');\n    this.field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[name=\\\"\".concat(this.fieldName, \"\\\"]\"));\n    this.data = data;\n    this.parentLabel = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-parents-field-label=\\\"\".concat(this.fieldName, \"\\\"]\"));\n    this.parentName = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-parents-field-name=\\\"\".concat(this.fieldName, \"\\\"]\"));\n    var dataLoad = this.dataLoad;\n    this.finder = new _utils_finderjs__WEBPACK_IMPORTED_MODULE_1__.default(this.container, function (parent, callback) {\n      return dataLoad.call(_this, parent, callback);\n    }, {\n      labelKey: 'name',\n      defaultPath: this.field.val(),\n      createItemContent: function createItemContent(item) {\n        return Parents.createItemContent(this.config, item);\n      }\n    });\n    /*\n    this.finder.$emitter.on('leaf-selected', (item) => {\n        console.log('selected', item);\n        this.finder.emit('create-column', () => this.createSimpleColumn(item));\n    });\n     this.finder.$emitter.on('item-selected', (selected) => {\n        console.log('selected', selected);\n        // for future use only - create column-card creation for file with details like in macOS finder\n        // this.finder.$emitter('create-column', () => this.createSimpleColumn(selected));\n    }); */\n\n    this.finder.$emitter.on('column-created', function () {\n      _this.container[0].scrollLeft = _this.container[0].scrollWidth - _this.container[0].clientWidth;\n    });\n  }\n\n  _createClass(Parents, [{\n    key: \"createSimpleColumn\",\n    value: function createSimpleColumn(item) {}\n  }, {\n    key: \"dataLoad\",\n    value: function dataLoad(parent, callback) {\n      var _this2 = this;\n\n      if (!parent) {\n        return callback(this.data);\n      }\n\n      if (parent.type !== 'dir' || !parent['has-children']) {\n        return false;\n      }\n\n      var UUID = ++XHRUUID;\n      this.startLoader();\n      jquery__WEBPACK_IMPORTED_MODULE_0___default().ajax({\n        url: \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.config.current_url),\n        method: 'post',\n        data: Object.assign({}, getExtraFormData(this.container), {\n          route: b64_encode_unicode(parent.value),\n          field: this.field.data('fieldName'),\n          action: 'getLevelListing'\n        }),\n        success: function success(response) {\n          _this2.stopLoader();\n\n          if (response.status === 'error') {\n            _this2.finder.$emitter.emit('create-column', Parents.createErrorColumn(response.message)[0]);\n\n            return false;\n          } // stale request\n\n\n          if (UUID !== XHRUUID) {\n            return false;\n          }\n\n          return callback(response.data);\n        }\n      });\n    }\n  }, {\n    key: \"startLoader\",\n    value: function startLoader() {\n      this.loadingIndicator = Parents.createLoadingColumn();\n      this.finder.$emitter.emit('create-column', this.loadingIndicator[0]);\n      return this.loadingIndicator;\n    }\n  }, {\n    key: \"stopLoader\",\n    value: function stopLoader() {\n      return this.loadingIndicator && this.loadingIndicator.remove();\n    }\n  }], [{\n    key: \"createItemContent\",\n    value: function createItemContent(config, item) {\n      var frag = document.createDocumentFragment();\n      var label = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"<span title=\\\"\".concat(item[config.labelKey], \"\\\" />\"));\n      var infoContainer = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<span class=\"info-container\" />');\n      var iconPrepend = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<i />');\n      var iconAppend = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<i />');\n      var badge = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<span class=\"badge\" />');\n      var prependClasses = ['fa'];\n      var appendClasses = ['fa']; // prepend icon\n\n      if (item.children || item.type === 'dir') {\n        prependClasses.push('fa-folder');\n      } else if (item.type === 'root') {\n        prependClasses.push('fa-sitemap');\n      } else if (item.type === 'file') {\n        prependClasses.push('fa-file-o');\n      }\n\n      iconPrepend.addClass(prependClasses.join(' ')); // text label\n\n      label.text(item[config.labelKey]).prepend(iconPrepend);\n      label.appendTo(frag); // append icon\n\n      if (item.children || item['has-children']) {\n        appendClasses.push('fa-caret-right');\n        badge.text(item.size || item.count || 0);\n        badge.appendTo(infoContainer);\n      }\n\n      iconAppend.addClass(appendClasses.join(' '));\n      iconAppend.appendTo(infoContainer);\n      infoContainer.appendTo(frag);\n      return frag;\n    }\n  }, {\n    key: \"createLoadingColumn\",\n    value: function createLoadingColumn() {\n      return jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"\\n            <div class=\\\"fjs-col leaf-col\\\" style=\\\"overflow: hidden;\\\">\\n                <div class=\\\"leaf-row\\\">\\n                    <div class=\\\"grav-loading\\\"><div class=\\\"grav-loader\\\">Loading...</div></div>\\n                </div>\\n            </div>\\n        \");\n    }\n  }, {\n    key: \"createErrorColumn\",\n    value: function createErrorColumn(error) {\n      return jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"\\n            <div class=\\\"fjs-col leaf-col\\\" style=\\\"overflow: hidden;\\\">\\n                <div class=\\\"leaf-row error\\\">\\n                    <i class=\\\"fa fa-fw fa-warning\\\"></i>\\n                    <span>\".concat(error, \"</span>\\n                </div>\\n            </div>\\n        \"));\n    }\n  }]);\n\n  return Parents;\n}();\n\n\nvar b64_encode_unicode = function b64_encode_unicode(str) {\n  return btoa(encodeURIComponent(str).replace(/%([0-9A-F]{2})/g, function toSolidBytes(match, p1) {\n    return String.fromCharCode('0x' + p1);\n  }));\n};\nvar b64_decode_unicode = function b64_decode_unicode(str) {\n  return decodeURIComponent(atob(str).split('').map(function (c) {\n    return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);\n  }).join(''));\n};\n\nvar getExtraFormData = function getExtraFormData(container) {\n  var form = container.closest('form');\n\n  if (container.closest('[data-remodal-id]').length) {\n    form = jquery__WEBPACK_IMPORTED_MODULE_0___default()('form#blueprints');\n  }\n\n  var data = {};\n  var unique_id = form.find('[name=\"__unique_form_id__\"]');\n  data['__form-name__'] = form.find('[name=\"__form-name__\"]').val();\n  data['form-nonce'] = form.find('[name=\"form-nonce\"]').val();\n\n  if (unique_id.length) {\n    data['__unique_form_id__'] = unique_id.val();\n  }\n\n  return data;\n};\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-parents]', function (event) {\n  event.preventDefault();\n  event.stopPropagation();\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var field = target.closest('.parents-wrapper').find('input[name]');\n  var fieldName = field.attr('name');\n\n  if (!field.length) {\n    fieldName = target.data('parents');\n    field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[name=\\\"\".concat(target.data('parents'), \"\\\"]\")).first();\n  }\n\n  var modal = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-remodal-id=\\\"\".concat(target.data('remodalTarget') || 'parents', \"\\\"]\"));\n  var loader = modal.find('.grav-loading');\n  var content = modal.find('.parents-content');\n  loader.css('display', 'block');\n  content.html('');\n  jquery__WEBPACK_IMPORTED_MODULE_0___default().ajax({\n    url: \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.config.current_url),\n    method: 'post',\n    data: Object.assign({}, getExtraFormData(target), {\n      route: b64_encode_unicode(field.val()),\n      field: field.data('fieldName'),\n      action: 'getLevelListing',\n      initial: true\n    }),\n    success: function success(response) {\n      loader.css('display', 'none');\n\n      if (response.status === 'error') {\n        content.html(response.message);\n        return true;\n      }\n\n      if (!Instances[\"\".concat(fieldName, \"-\").concat(modal.data('remodalId'))]) {\n        Instances[\"\".concat(fieldName, \"-\").concat(modal.data('remodalId'))] = new Parents(content, field, response.data);\n      } else {\n        Instances[\"\".concat(fieldName, \"-\").concat(modal.data('remodalId'))].finder.reload(response.data);\n      }\n\n      modal.data('parents', Instances[\"\".concat(fieldName, \"-\").concat(modal.data('remodalId'))]);\n    }\n  });\n}); // apply finder selection to field\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-remodal-id].parents-container [data-parents-select]', function (event) {\n  var modal = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget).closest('[data-remodal-id]');\n  var parents = modal.data('parents');\n  var finder = parents.finder;\n  var field = parents.field;\n  var parentLabel = parents.parentLabel;\n  var parentName = parents.parentName;\n  var selection = finder.findLastActive().item[0];\n  var value = selection._item[finder.config.valueKey];\n  var name = selection._item[finder.config.labelKey];\n  field.val(value);\n  parentLabel.text(value);\n  parentName.text(name);\n  finder.config.defaultPath = value;\n  var remodal = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-remodal-id=\\\"\".concat(modal.data('remodalId'), \"\\\"]\")).data('remodal')];\n  remodal.close();\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 23972 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/parents.js\n");

/***/ }),

/***/ "./app/forms/fields/permissions.js":
/*!*****************************************!*\
  !*** ./app/forms/fields/permissions.js ***!
  \*****************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\nvar body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\nvar radioSelector = '.permission-container.parent-section input[type=\"radio\"]';\n\nvar handleParent = function handleParent(event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var value = target.val();\n  var container = target.closest('.parent-section');\n  var fieldset = container.next('fieldset');\n  var radios = fieldset.find(\"input[type=\\\"radio\\\"][value=\\\"\".concat(value, \"\\\"]\"));\n\n  if (container.data('isLocked') !== false) {\n    container.data('isUpdating', true);\n    radios.each(function (index, radio) {\n      var ID = radio.id;\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(radio).siblings(\"[for=\\\"\".concat(ID, \"\\\"]\")).trigger('click');\n    });\n    container.data('isUpdating', false);\n  }\n};\n\nvar boundHandleParent = handleParent.bind(handleParent);\nbody.on('click', '.permission-container.parent-section label', function (event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var container = target.closest('.parent-section');\n  container.data('isLocked', true);\n});\nbody.on('input', radioSelector, boundHandleParent);\nbody.on('input', '.permissions-container input[type=\"radio\"][data-parent-id]', function (event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var parent = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[for=\\\"\".concat(target.data('parentId'), \"\\\"]\"));\n  var container = target.closest('fieldset').prev('.permission-container.parent-section');\n\n  if (container.data('isUpdating') === true) {\n    return true;\n  }\n\n  body.off('input', radioSelector, boundHandleParent);\n  container.data('isLocked', false);\n  parent.trigger('click');\n  body.on('input', radioSelector, boundHandleParent);\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 5044 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/permissions.js\n");

/***/ }),

/***/ "./app/forms/fields/selectize.js":
/*!***************************************!*\
  !*** ./app/forms/fields/selectize.js ***!
  \***************************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ SelectizeField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var selectize__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! selectize */ \"./node_modules/selectize/dist/js/selectize.js\");\n/* harmony import */ var selectize__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(selectize__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_selectize_required_fix__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../utils/selectize-required-fix */ \"./app/utils/selectize-required-fix.js\");\n/* harmony import */ var _utils_selectize_option_click__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../utils/selectize-option-click */ \"./app/utils/selectize-option-click.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar PagesRoute = {\n  option: function option(item, escape) {\n    var label = escape(item.text).split(' ');\n    var arrows = label.shift();\n    var slug = label.shift();\n    return \"<div class=\\\"selectize-route-option\\\">\\n            <span class=\\\"text-grey\\\">\".concat(arrows, \"</span>\\n            <span>\\n                <span class=\\\"text-update\\\">\").concat(slug.replace('(', '/').replace(')', ''), \"</span>\\n                <span>\").concat(label.join(' '), \"</span>\\n            </span>\\n        </div>\");\n  }\n};\n\nvar SelectizeField = /*#__PURE__*/function () {\n  function SelectizeField() {\n    var _this = this;\n\n    var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n\n    _classCallCheck(this, SelectizeField);\n\n    this.options = Object.assign({}, options);\n    this.elements = [];\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-selectize]').each(function (index, element) {\n      return _this.add(element);\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('mutation._grav', this._onAddedNodes.bind(this));\n  }\n\n  _createClass(SelectizeField, [{\n    key: \"add\",\n    value: function add(element) {\n      element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n\n      if (element.closest('template').length) {\n        return false;\n      }\n\n      var tag = element.prop('tagName').toLowerCase();\n      var isInput = tag === 'input' || tag === 'select';\n      var data = (isInput ? element.closest('[data-grav-selectize]') : element).data('grav-selectize') || {};\n      var field = isInput ? element : element.find('input, select');\n\n      if (field.attr('name') === 'data[route]') {\n        data = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, data, {\n          render: PagesRoute\n        });\n      }\n\n      if (!field.length || field.get(0).selectize) {\n        return;\n      }\n\n      var plugins = jquery__WEBPACK_IMPORTED_MODULE_0___default().merge(data.plugins ? data.plugins : [], ['required-fix']);\n      field.selectize(jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, data, {\n        plugins: plugins\n      }));\n      this.elements.push(field.data('selectize'));\n    }\n  }, {\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target\n    /* , record, instance */\n    ) {\n      var _this2 = this;\n\n      var fields = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('select.fancy, input.fancy, [data-grav-selectize]').filter(function (index, element) {\n        return !jquery__WEBPACK_IMPORTED_MODULE_0___default()(element).closest('template').length;\n      });\n\n      if (!fields.length) {\n        return;\n      }\n\n      fields.each(function (index, field) {\n        return _this2.add(field);\n      });\n    }\n  }]);\n\n  return SelectizeField;\n}();\n\n\nvar Instance = new SelectizeField();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 6784 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/selectize.js\n");

/***/ }),

/***/ "./app/forms/fields/selectunique.js":
/*!******************************************!*\
  !*** ./app/forms/fields/selectunique.js ***!
  \******************************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ SelectUniqueField,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var mout_object_forIn__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! mout/object/forIn */ \"./node_modules/mout/object/forIn.js\");\n/* harmony import */ var mout_object_forIn__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(mout_object_forIn__WEBPACK_IMPORTED_MODULE_1__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n // import { config } from 'grav-config';\n\nvar Data = {};\n\nvar SelectUniqueField = /*#__PURE__*/function () {\n  function SelectUniqueField(options) {\n    var _this = this;\n\n    _classCallCheck(this, SelectUniqueField);\n\n    var body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\n    this.items = jquery__WEBPACK_IMPORTED_MODULE_0___default()();\n    this.options = Object.assign({}, this.defaults, options);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-select-observe]').each(function (index, element) {\n      return _this.addSelect(element);\n    }).last().trigger('change', {\n      load: true\n    });\n    body.on('mutation._grav', this._onAddedNodes.bind(this));\n    body.on('mutation_removed._grav', this._onRemovedNodes.bind(this));\n  }\n\n  _createClass(SelectUniqueField, [{\n    key: \"_onAddedNodes\",\n    value: function _onAddedNodes(event, target, record, instance) {\n      var _this2 = this;\n\n      var fields = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target).find('[data-select-observe]');\n\n      if (!fields.length) {\n        return;\n      }\n\n      fields.each(function (index, field) {\n        field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(field);\n\n        if (!~_this2.items.index(field)) {\n          _this2.addSelect(field);\n        }\n      });\n    }\n  }, {\n    key: \"_onRemovedNodes\",\n    value: function _onRemovedNodes(event, data\n    /* , instance */\n    ) {\n      var _this3 = this;\n\n      var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(data.target);\n      var holder = target.data('collectionHolder');\n\n      if (!holder) {\n        return false;\n      }\n\n      var node = jquery__WEBPACK_IMPORTED_MODULE_0___default()(data.mutation.removedNodes);\n      var value = node.find('[data-select-observe]').val();\n\n      if (value) {\n        Data[holder].state[value] = value;\n      }\n\n      target.find('[data-select-observe]').each(function (index, field) {\n        field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(field);\n\n        if (field.val() !== value) {\n          _this3.updateOptions(field);\n        }\n      });\n    }\n  }, {\n    key: \"addSelect\",\n    value: function addSelect(element) {\n      var _this4 = this;\n\n      this.items = this.items.add(element);\n      element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n      var value = element.attr('value');\n      var holder = element.closest('[data-collection-holder]').data('collectionHolder');\n      var options = element.closest('[data-select-unique]').data('selectUnique');\n\n      if (!Data[holder]) {\n        var data = {};\n\n        if (Array.isArray(options)) {\n          options.slice(0).map(function (item) {\n            data[item] = item;\n          });\n        } else {\n          data = Object.assign({}, options);\n        }\n\n        Data[holder] = {\n          original: null,\n          state: null\n        };\n        Data[holder].original = Object.assign({}, data);\n        Data[holder].state = Object.assign({}, data);\n      }\n\n      this.updateOptions(element);\n      element.data('originalValue', value);\n      element.on('change', function (event, extras) {\n        var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n\n        if (target.data('dummyChange')) {\n          target.data('dummyChange', false);\n          return false;\n        }\n\n        _this4.refreshOptions(target, extras && extras.load ? null : element.data('originalValue'));\n\n        element.data('originalValue', target.val());\n      });\n    }\n  }, {\n    key: \"updateOptions\",\n    value: function updateOptions(element) {\n      element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n      var value = element.attr('value');\n      var holder = element.closest('[data-collection-holder]').data('collectionHolder');\n      mout_object_forIn__WEBPACK_IMPORTED_MODULE_1___default()(Data[holder].state, function (v, k) {\n        var selected = k === value ? 'selected=\"selected\"' : '';\n\n        if (element.get(0).selectize) {\n          var selectize = element.data('selectize');\n          selectize.removeOption(k);\n          selectize.addOption({\n            value: k,\n            text: v\n          });\n        } else {\n          element.append(\"<option value=\\\"\".concat(k, \"\\\" \").concat(selected, \">\").concat(v, \"</option>\"));\n        }\n\n        if (selected) {\n          if (element.get(0).selectize) {\n            var _selectize = element.data('selectize');\n\n            _selectize.setValue(k);\n          }\n\n          delete Data[holder].state[value];\n        }\n      });\n    }\n  }, {\n    key: \"refreshOptions\",\n    value: function refreshOptions(element, originalValue) {\n      var value = element.val();\n      var holder = element.closest('[data-collection-holder]').data('collectionHolder');\n      delete Data[holder].state[value];\n\n      if (originalValue && Data[holder].original[originalValue]) {\n        Data[holder].state[originalValue] = Data[holder].original[originalValue];\n      }\n\n      this.items.each(function (index, select) {\n        select = jquery__WEBPACK_IMPORTED_MODULE_0___default()(select);\n\n        if (select[0] === element[0]) {\n          return;\n        }\n\n        var selectedValue = select.val();\n        select.data('dummyChange', true);\n\n        if (select.get(0).selectize) {\n          var selectize = select.data('selectize');\n\n          if (selectize) {\n            selectize.clearOptions();\n\n            if (selectedValue) {\n              selectize.addOption({\n                value: selectedValue,\n                text: Data[holder].original[selectedValue] || selectedValue\n              });\n            }\n\n            mout_object_forIn__WEBPACK_IMPORTED_MODULE_1___default()(Data[holder].state, function (v, k) {\n              selectize.addOption({\n                value: k,\n                text: v\n              });\n            });\n            selectize.setValue(selectedValue, true);\n          }\n        } else {\n          select.empty();\n          mout_object_forIn__WEBPACK_IMPORTED_MODULE_1___default()(Data[holder].state, function (v, k) {\n            var selected = k === selectedValue ? 'selected=\"selected\"' : '';\n            select.append(\"<option value=\\\"\".concat(k, \"\\\" \").concat(selected, \">\").concat(v, \"</option>\"));\n          });\n        }\n\n        select.data('dummyChange', false);\n      });\n    }\n  }]);\n\n  return SelectUniqueField;\n}();\n\n\nvar Instance = new SelectUniqueField();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 16288 characters]\n//# sourceURL=webpack-internal:///./app/forms/fields/selectunique.js\n");

/***/ }),

/***/ "./app/forms/fields/text.js":
/*!**********************************!*\
  !*** ./app/forms/fields/text.js ***!
  \**********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).ready(function () {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.copy-to-clipboard').click(function (event) {\n    var $tempElement = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<input>');\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').append($tempElement);\n    $tempElement.val(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).prev('input').val()).select();\n    document.execCommand('Copy');\n    $tempElement.remove();\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).attr('data-hint', 'Copied to clipboard!').addClass('hint--left');\n  });\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL2Zvcm1zL2ZpZWxkcy90ZXh0LmpzPzhlMTciXSwibmFtZXMiOlsiJCIsImRvY3VtZW50IiwicmVhZHkiLCJjbGljayIsImV2ZW50IiwiJHRlbXBFbGVtZW50IiwiYXBwZW5kIiwidmFsIiwicHJldiIsInNlbGVjdCIsImV4ZWNDb21tYW5kIiwicmVtb3ZlIiwiYXR0ciIsImFkZENsYXNzIl0sIm1hcHBpbmdzIjoiOzs7QUFBQTtBQUVBQSw2Q0FBQyxDQUFDQyxRQUFELENBQUQsQ0FBWUMsS0FBWixDQUFrQixZQUFXO0FBQ3pCRiwrQ0FBQyxDQUFDLG9CQUFELENBQUQsQ0FBd0JHLEtBQXhCLENBQThCLFVBQVNDLEtBQVQsRUFBZ0I7QUFDMUMsUUFBSUMsWUFBWSxHQUFHTCw2Q0FBQyxDQUFDLFNBQUQsQ0FBcEI7QUFDQUEsaURBQUMsQ0FBQyxNQUFELENBQUQsQ0FBVU0sTUFBVixDQUFpQkQsWUFBakI7QUFDQUEsZ0JBQVksQ0FBQ0UsR0FBYixDQUFpQlAsNkNBQUMsQ0FBQyxJQUFELENBQUQsQ0FBUVEsSUFBUixDQUFhLE9BQWIsRUFBc0JELEdBQXRCLEVBQWpCLEVBQThDRSxNQUE5QztBQUNBUixZQUFRLENBQUNTLFdBQVQsQ0FBcUIsTUFBckI7QUFDQUwsZ0JBQVksQ0FBQ00sTUFBYjtBQUVBWCxpREFBQyxDQUFDLElBQUQsQ0FBRCxDQUFRWSxJQUFSLENBQWEsV0FBYixFQUEwQixzQkFBMUIsRUFBa0RDLFFBQWxELENBQTJELFlBQTNEO0FBQ0gsR0FSRDtBQVNILENBVkQiLCJmaWxlIjoiLi9hcHAvZm9ybXMvZmllbGRzL3RleHQuanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgJCBmcm9tICdqcXVlcnknO1xuXG4kKGRvY3VtZW50KS5yZWFkeShmdW5jdGlvbigpIHtcbiAgICAkKCcuY29weS10by1jbGlwYm9hcmQnKS5jbGljayhmdW5jdGlvbihldmVudCkge1xuICAgICAgICB2YXIgJHRlbXBFbGVtZW50ID0gJCgnPGlucHV0PicpO1xuICAgICAgICAkKCdib2R5JykuYXBwZW5kKCR0ZW1wRWxlbWVudCk7XG4gICAgICAgICR0ZW1wRWxlbWVudC52YWwoJCh0aGlzKS5wcmV2KCdpbnB1dCcpLnZhbCgpKS5zZWxlY3QoKTtcbiAgICAgICAgZG9jdW1lbnQuZXhlY0NvbW1hbmQoJ0NvcHknKTtcbiAgICAgICAgJHRlbXBFbGVtZW50LnJlbW92ZSgpO1xuXG4gICAgICAgICQodGhpcykuYXR0cignZGF0YS1oaW50JywgJ0NvcGllZCB0byBjbGlwYm9hcmQhJykuYWRkQ2xhc3MoJ2hpbnQtLWxlZnQnKTtcbiAgICB9KTtcbn0pO1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./app/forms/fields/text.js\n");

/***/ }),

/***/ "./app/forms/form.js":
/*!***************************!*\
  !*** ./app/forms/form.js ***!
  \***************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ Form,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n/* Dependencies for checking if changes happened since load on a form\nimport toastr from '../utils/toastr';\nimport { translations } from 'grav-config';\nimport { Instance as FormState } from './state';\n*/\n\nvar Form = /*#__PURE__*/function () {\n  function Form(form) {\n    var _this = this;\n\n    _classCallCheck(this, Form);\n\n    this.form = jquery__WEBPACK_IMPORTED_MODULE_0___default()(form);\n\n    if (!this.form.length || this.form.prop('tagName').toLowerCase() !== 'form') {\n      return;\n    }\n    /* Option for not saving while nothing in a form has changed\n     this.form.on('submit', (event) => {\n        if (FormState.equals()) {\n            event.preventDefault();\n            toastr.info(translations.PLUGIN_ADMIN.NOTHING_TO_SAVE);\n        }\n    }); */\n\n\n    this._attachShortcuts();\n\n    this._attachToggleables();\n\n    this._attachDisabledFields();\n\n    this._submitUncheckedFields();\n\n    this.observer = new MutationObserver(this.addedNodes);\n    this.form.each(function (index, form) {\n      return _this.observer.observe(form, {\n        subtree: true,\n        childList: true\n      });\n    });\n  }\n\n  _createClass(Form, [{\n    key: \"_attachShortcuts\",\n    value: function _attachShortcuts() {\n      // CTRL + S / CMD + S - shortcut for [Save] when available\n      var saveTask = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#titlebar [name=\"task\"][value=\"save\"][form=\"blueprints\"]');\n\n      if (saveTask.length) {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).on('keydown', function (event) {\n          var key = String.fromCharCode(event.which).toLowerCase();\n\n          if (!event.shiftKey && (event.ctrlKey && !event.altKey || event.metaKey) && key === 's') {\n            event.preventDefault();\n            saveTask.click();\n          }\n        });\n      }\n    }\n  }, {\n    key: \"_attachToggleables\",\n    value: function _attachToggleables() {\n      var query = '[data-grav-field=\"toggleable\"] input[type=\"checkbox\"]';\n      this.form.on('change', query, function (event) {\n        var toggle = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n        var enabled = toggle.is(':checked');\n        var parent = toggle.closest('.form-field');\n        var label = parent.find('label.toggleable');\n        var fields = parent.find('.form-data');\n        var inputs = fields.find('input, select, textarea, button');\n        label.add(fields).css('opacity', enabled ? '' : 0.7);\n        inputs.map(function (index, input) {\n          var isSelectize = input.selectize;\n          input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(input);\n\n          if (isSelectize) {\n            isSelectize[enabled ? 'enable' : 'disable']();\n          } else {\n            input.prop('disabled', !enabled);\n          }\n        });\n      });\n      this.form.find(query).trigger('change');\n    }\n  }, {\n    key: \"_attachDisabledFields\",\n    value: function _attachDisabledFields() {\n      var prefix = '.form-field-toggleable .form-data';\n      var query = [];\n      ['input', 'select', 'label[for]', 'textarea', '.selectize-control'].forEach(function (item) {\n        query.push(\"\".concat(prefix, \" \").concat(item));\n      });\n      this.form.on('mousedown', query.join(', '), function (event) {\n        var input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n        var isFor = input.prop('for');\n        var isSelectize = (input.hasClass('selectize-control') || input.parents('.selectize-control')).length;\n\n        if (isFor) {\n          input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[id=\\\"\".concat(isFor, \"\\\"]\"));\n        }\n\n        if (isSelectize) {\n          input = input.closest('.selectize-control').siblings('select[name]');\n        }\n\n        if (!input.prop('disabled')) {\n          return true;\n        }\n\n        var toggle = input.closest('.form-field').find('[data-grav-field=\"toggleable\"] input[type=\"checkbox\"]');\n        toggle.trigger('click');\n      });\n    }\n  }, {\n    key: \"_submitUncheckedFields\",\n    value: function _submitUncheckedFields() {\n      var submitted = false;\n      this.form.each(function (index, form) {\n        form = jquery__WEBPACK_IMPORTED_MODULE_0___default()(form);\n        form.on('submit', function () {\n          // workaround for MS Edge, submitting multiple forms at the same time\n          if (submitted) {\n            return false;\n          }\n\n          var formId = form.attr('id');\n          var unchecked = form.find('input[type=\"checkbox\"]:not(:checked):not(:disabled)');\n          var submit = form.find('[type=\"submit\"]').add(\"[form=\\\"\".concat(formId, \"\\\"][type=\\\"submit\\\"]\"));\n\n          if (!unchecked.length) {\n            return true;\n          }\n\n          submit.addClass('pointer-events-disabled');\n          unchecked.each(function (index, element) {\n            element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n            var name = element.prop('name');\n            var fake = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"<input type=\\\"hidden\\\" name=\\\"\".concat(name, \"\\\" value=\\\"0\\\" />\"));\n            form.append(fake);\n          });\n          submitted = true;\n          return true;\n        });\n      });\n    }\n  }, {\n    key: \"addedNodes\",\n    value: function addedNodes(mutations) {\n      var _this2 = this;\n\n      mutations.forEach(function (mutation) {\n        if (mutation.type !== 'childList') {\n          return;\n        }\n\n        if (mutation.addedNodes) {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').trigger('mutation._grav', mutation.target, mutation, _this2);\n        }\n\n        if (mutation.removedNodes) {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').trigger('mutation_removed._grav', {\n            target: mutation.target,\n            mutation: mutation\n          }, _this2);\n        }\n      });\n    }\n  }]);\n\n  return Form;\n}();\n\n\nvar Instance = new Form('form#blueprints');//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 13876 characters]\n//# sourceURL=webpack-internal:///./app/forms/form.js\n");

/***/ }),

/***/ "./app/forms/index.js":
/*!****************************!*\
  !*** ./app/forms/index.js ***!
  \****************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var _state__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./state */ \"./app/forms/state.js\");\n/* harmony import */ var _form__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./form */ \"./app/forms/form.js\");\n/* harmony import */ var _fields__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./fields */ \"./app/forms/fields/index.js\");\n\n\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({\n  Form: {\n    Form: _form__WEBPACK_IMPORTED_MODULE_1__.default,\n    Instance: _form__WEBPACK_IMPORTED_MODULE_1__.Instance\n  },\n  Fields: _fields__WEBPACK_IMPORTED_MODULE_2__.default,\n  FormState: {\n    FormState: _state__WEBPACK_IMPORTED_MODULE_0__.default,\n    Instance: _state__WEBPACK_IMPORTED_MODULE_0__.Instance\n  }\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL2Zvcm1zL2luZGV4LmpzPzkyNzMiXSwibmFtZXMiOlsiRm9ybSIsIkluc3RhbmNlIiwiRm9ybUluc3RhbmNlIiwiRmllbGRzIiwiRm9ybVN0YXRlIiwiRm9ybVN0YXRlSW5zdGFuY2UiXSwibWFwcGluZ3MiOiI7Ozs7Ozs7QUFBQTtBQUNBO0FBRUE7QUFFQSxpRUFBZTtBQUNYQSxNQUFJLEVBQUU7QUFDRkEsUUFBSSxFQUFKQSwwQ0FERTtBQUVGQyxZQUFRLEVBQUVDLDJDQUFZQTtBQUZwQixHQURLO0FBS1hDLFFBQU0sRUFBTkEsNENBTFc7QUFNWEMsV0FBUyxFQUFFO0FBQ1BBLGFBQVMsRUFBVEEsMkNBRE87QUFFUEgsWUFBUSxFQUFFSSw0Q0FBaUJBO0FBRnBCO0FBTkEsQ0FBZiIsImZpbGUiOiIuL2FwcC9mb3Jtcy9pbmRleC5qcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBGb3JtU3RhdGUsIHsgSW5zdGFuY2UgYXMgRm9ybVN0YXRlSW5zdGFuY2UgfSBmcm9tICcuL3N0YXRlJztcbmltcG9ydCBGb3JtLCB7IEluc3RhbmNlIGFzIEZvcm1JbnN0YW5jZSB9IGZyb20gJy4vZm9ybSc7XG5cbmltcG9ydCBGaWVsZHMgZnJvbSAnLi9maWVsZHMnO1xuXG5leHBvcnQgZGVmYXVsdCB7XG4gICAgRm9ybToge1xuICAgICAgICBGb3JtLFxuICAgICAgICBJbnN0YW5jZTogRm9ybUluc3RhbmNlXG4gICAgfSxcbiAgICBGaWVsZHMsXG4gICAgRm9ybVN0YXRlOiB7XG4gICAgICAgIEZvcm1TdGF0ZSxcbiAgICAgICAgSW5zdGFuY2U6IEZvcm1TdGF0ZUluc3RhbmNlXG4gICAgfVxufTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/forms/index.js\n");

/***/ }),

/***/ "./app/forms/state.js":
/*!****************************!*\
  !*** ./app/forms/state.js ***!
  \****************************/
/*! namespace exports */
/*! export DOMBehaviors [provided] [no usage info] [missing usage info prevents renaming] */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ FormState,\n/* harmony export */   \"Instance\": () => /* binding */ Instance,\n/* harmony export */   \"DOMBehaviors\": () => /* binding */ DOMBehaviors\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var immutable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! immutable */ \"./node_modules/immutable/dist/immutable.js\");\n/* harmony import */ var immutable__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(immutable__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var immutablediff__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! immutablediff */ \"./node_modules/immutablediff/src/diff.js\");\n/* harmony import */ var immutablediff__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(immutablediff__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _utils_jquery_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../utils/jquery-utils */ \"./app/utils/jquery-utils.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar FormLoadState = {};\nvar DOMBehaviors = {\n  attach: function attach() {\n    this.preventUnload();\n    this.preventClickAway();\n  },\n  preventUnload: function preventUnload() {\n    var selector = '[name=\"task\"][value^=\"save\"], [data-delete-action]';\n\n    if (jquery__WEBPACK_IMPORTED_MODULE_0___default()._data(window, 'events') && (jquery__WEBPACK_IMPORTED_MODULE_0___default()._data(window, 'events').beforeunload || []).filter(function (event) {\n      return event.namespace === '_grav';\n    }).length) {\n      return;\n    } // Allow some elements to leave the page without native confirmation\n\n\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(selector).on('click._grav', function (event) {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).off('beforeunload');\n    }); // Catch browser uri change / refresh attempt and stop it if the form state is dirty\n\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).on('beforeunload._grav', function () {\n      if (Instance.equals() === false) {\n        return 'You have made changes on this page that you have not yet confirmed. If you navigate away from this page you will lose your unsaved changes.';\n      }\n    });\n  },\n  preventClickAway: function preventClickAway() {\n    var selector = 'a[href]:not([href^=\"#\"]):not([target=\"_blank\"]):not([href^=\"javascript:\"])';\n\n    if (jquery__WEBPACK_IMPORTED_MODULE_0___default()._data(jquery__WEBPACK_IMPORTED_MODULE_0___default()(selector).get(0), 'events') && (jquery__WEBPACK_IMPORTED_MODULE_0___default()._data(jquery__WEBPACK_IMPORTED_MODULE_0___default()(selector).get(0), 'events').click || []).filter(function (event) {\n      return event.namespace === '_grav';\n    })) {\n      return;\n    } // Prevent clicking away if the form state is dirty\n    // instead, display a confirmation before continuing\n\n\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()(selector).on('click._grav', function (event) {\n      var isClean = Instance.equals();\n\n      if (isClean === null || isClean) {\n        return true;\n      }\n\n      event.preventDefault();\n      var destination = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).attr('href');\n      var modal = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=\"changes\"]');\n      var lookup = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[modal.data('remodal')];\n      var buttons = jquery__WEBPACK_IMPORTED_MODULE_0___default()('a.button', modal);\n\n      var handler = function handler(event) {\n        event.preventDefault();\n        var action = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('leave-action');\n        buttons.off('click', handler);\n        lookup.close();\n\n        if (action === 'continue') {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).off('beforeunload');\n          __webpack_require__.g.location.href = destination;\n        }\n      };\n\n      buttons.on('click', handler);\n      lookup.open();\n    });\n  }\n};\n\nvar FormState = /*#__PURE__*/function () {\n  function FormState() {\n    var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {\n      ignore: [],\n      form_id: 'blueprints'\n    };\n\n    _classCallCheck(this, FormState);\n\n    this.options = options;\n    this.refresh();\n\n    if (!this.form || !this.fields.length) {\n      return;\n    }\n\n    FormLoadState = this.collect();\n    this.loadState = FormLoadState;\n    DOMBehaviors.attach();\n  }\n\n  _createClass(FormState, [{\n    key: \"refresh\",\n    value: function refresh() {\n      this.form = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"form#\".concat(this.options.form_id)).filter(':noparents(.remodal)');\n      this.fields = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"form#\".concat(this.options.form_id, \" *, [form=\\\"\").concat(this.options.form_id, \"\\\"]\")).filter(':input:not(.no-form)').filter(':noparents(.remodal)');\n      return this;\n    }\n  }, {\n    key: \"collect\",\n    value: function collect() {\n      var _this = this;\n\n      if (!this.form || !this.fields.length) {\n        return;\n      }\n\n      var values = {};\n      this.refresh().fields.each(function (index, field) {\n        field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(field);\n        var name = field.prop('name');\n        var type = field.prop('type');\n        var tag = field.prop('tagName').toLowerCase();\n        var value;\n\n        if (name.startsWith('toggleable_') || name === 'data[lang]' || name === 'data[redirect]') {\n          return;\n        }\n\n        switch (type) {\n          case 'checkbox':\n            value = field.is(':checked');\n            break;\n\n          case 'radio':\n            if (!field.is(':checked')) {\n              return;\n            }\n\n            value = field.val();\n            break;\n\n          default:\n            value = field.val();\n        }\n\n        if (tag === 'select' && value === null) {\n          value = '';\n        }\n\n        if (Array.isArray(value)) {\n          value = value.join('|');\n        }\n\n        if (name && !~_this.options.ignore.indexOf(name)) {\n          values[name] = value;\n        }\n      });\n      return immutable__WEBPACK_IMPORTED_MODULE_1___default().OrderedMap(values);\n    }\n  }, {\n    key: \"diff\",\n    value: function diff() {\n      return immutablediff__WEBPACK_IMPORTED_MODULE_2___default()(FormLoadState, this.collect());\n    } // When the form doesn't exist or there are no fields, `equals` returns `null`\n    // for this reason, _NEVER_ check with !Instance.equals(), use Instance.equals() === false\n\n  }, {\n    key: \"equals\",\n    value: function equals() {\n      if (!this.form || !this.fields.length) {\n        return null;\n      }\n\n      return immutable__WEBPACK_IMPORTED_MODULE_1___default().is(FormLoadState, this.collect());\n    }\n  }]);\n\n  return FormState;\n}();\n\n\n;\nvar Instance = new FormState();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 13116 characters]\n//# sourceURL=webpack-internal:///./app/forms/state.js\n");

/***/ }),

/***/ "./app/main.js":
/*!*********************!*\
  !*** ./app/main.js ***!
  \*********************/
/*! namespace exports */
/*! export default [provided] [maybe used in app (runtime-defined)] [usage prevents renaming] */
/*! other exports [not provided] [maybe used in app (runtime-defined)] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var _babel_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @babel/polyfill */ \"./node_modules/@babel/polyfill/lib/index.js\");\n/* harmony import */ var _babel_polyfill__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_babel_polyfill__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_remodal__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./utils/remodal */ \"./app/utils/remodal.js\");\n/* harmony import */ var simplebar__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! simplebar */ \"./node_modules/simplebar/dist/simplebar.esm.js\");\n/* harmony import */ var _utils_gpm__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./utils/gpm */ \"./app/utils/gpm.js\");\n/* harmony import */ var _utils_keepalive__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./utils/keepalive */ \"./app/utils/keepalive.js\");\n/* harmony import */ var _updates__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./updates */ \"./app/updates/index.js\");\n/* harmony import */ var _dashboard__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./dashboard */ \"./app/dashboard/index.js\");\n/* harmony import */ var _pages__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./pages */ \"./app/pages/index.js\");\n/* harmony import */ var _forms__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./forms */ \"./app/forms/index.js\");\n/* harmony import */ var _plugins__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./plugins */ \"./app/plugins/index.js\");\n/* harmony import */ var _themes__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./themes */ \"./app/themes/index.js\");\n/* harmony import */ var _media__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./media */ \"./app/media/index.js\");\n/* harmony import */ var _utils_toastr__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./utils/toastr */ \"./app/utils/toastr.js\");\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./utils/request */ \"./app/utils/request.js\");\n/* harmony import */ var _utils_2fa__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./utils/2fa */ \"./app/utils/2fa.js\");\n/* harmony import */ var _tools__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./tools */ \"./app/tools/index.js\");\n/* harmony import */ var _whitelabel__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./whitelabel */ \"./app/whitelabel/index.js\");\n/* harmony import */ var _utils_bootstrap_transition__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./utils/bootstrap-transition */ \"./app/utils/bootstrap-transition.js\");\n/* harmony import */ var _utils_bootstrap_collapse__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./utils/bootstrap-collapse */ \"./app/utils/bootstrap-collapse.js\");\n/* harmony import */ var _utils_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./utils/bootstrap-dropdown */ \"./app/utils/bootstrap-dropdown.js\");\n/* harmony import */ var _utils_tabs_memory__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ./utils/tabs-memory */ \"./app/utils/tabs-memory.js\");\n/* harmony import */ var _utils_changelog__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./utils/changelog */ \"./app/utils/changelog.js\");\n/* harmony import */ var _utils_sidebar__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ./utils/sidebar */ \"./app/utils/sidebar.js\");\n// polyfills\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n // bootstrap jQuery extensions\n\n\n\n // tabs memory\n\n // changelog\n\n // Main Sidebar\n\n // starts the keep alive, auto runs every X seconds\n\n_utils_keepalive__WEBPACK_IMPORTED_MODULE_5__.default.start(); // global event to catch sidebar_state changes\n\njquery__WEBPACK_IMPORTED_MODULE_1___default()(__webpack_require__.g).on('sidebar_state._grav', function () {\n  Object.keys(_dashboard__WEBPACK_IMPORTED_MODULE_7__.default.Chart.Instances).forEach(function (chart) {\n    setTimeout(function () {\n      return _dashboard__WEBPACK_IMPORTED_MODULE_7__.default.Chart.Instances[chart].chart.update();\n    }, 10);\n  });\n});\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({\n  GPM: {\n    GPM: _utils_gpm__WEBPACK_IMPORTED_MODULE_4__.default,\n    Instance: _utils_gpm__WEBPACK_IMPORTED_MODULE_4__.Instance\n  },\n  KeepAlive: _utils_keepalive__WEBPACK_IMPORTED_MODULE_5__.default,\n  Dashboard: _dashboard__WEBPACK_IMPORTED_MODULE_7__.default,\n  Pages: _pages__WEBPACK_IMPORTED_MODULE_8__.default,\n  Forms: _forms__WEBPACK_IMPORTED_MODULE_9__.default,\n  Updates: {\n    Updates: _updates__WEBPACK_IMPORTED_MODULE_6__.default,\n    Notifications: _updates__WEBPACK_IMPORTED_MODULE_6__.Notifications,\n    Feed: _updates__WEBPACK_IMPORTED_MODULE_6__.Feed,\n    Instance: _updates__WEBPACK_IMPORTED_MODULE_6__.Instance\n  },\n  Sidebar: {\n    Sidebar: _utils_sidebar__WEBPACK_IMPORTED_MODULE_23__.default,\n    Instance: _utils_sidebar__WEBPACK_IMPORTED_MODULE_23__.Instance\n  },\n  MediaFilter: {\n    MediaFilter: _media__WEBPACK_IMPORTED_MODULE_12__.default,\n    Instance: _media__WEBPACK_IMPORTED_MODULE_12__.Instance\n  },\n  Scrollbar: {\n    Scrollbar: {\n      deprecated: true\n    },\n    Instance: {\n      deprecated: true\n    }\n  },\n  Utils: {\n    request: _utils_request__WEBPACK_IMPORTED_MODULE_14__.default,\n    toastr: _utils_toastr__WEBPACK_IMPORTED_MODULE_13__.default\n  }\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4448 characters]\n//# sourceURL=webpack-internal:///./app/main.js\n");

/***/ }),

/***/ "./app/media/index.js":
/*!****************************!*\
  !*** ./app/media/index.js ***!
  \****************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ Filter,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar Filter = /*#__PURE__*/function () {\n  function Filter() {\n    _classCallCheck(this, Filter);\n\n    this.URI = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/media-manager/\");\n  }\n\n  _createClass(Filter, [{\n    key: \"filter\",\n    value: function filter(name, value) {\n      var filtered = [];\n      var keys = Object.keys(grav_config__WEBPACK_IMPORTED_MODULE_1__.uri_params);\n\n      if (!~keys.indexOf(name)) {\n        keys.push(name);\n      }\n\n      keys.forEach(function (key) {\n        var filter = Filter.cleanValue(key === name ? value : grav_config__WEBPACK_IMPORTED_MODULE_1__.uri_params[key]);\n\n        if (filter !== '*') {\n          filtered.push(\"\".concat(key).concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep).concat(filter));\n        }\n      });\n      __webpack_require__.g.location = this.URI + filtered.join('/');\n    }\n  }], [{\n    key: \"cleanValue\",\n    value: function cleanValue(value) {\n      return encodeURIComponent(value.replace('/', '\\\\'));\n    }\n  }]);\n\n  return Filter;\n}();\n\n\nvar Instance = new Filter();\nvar isLoading = false;\nvar filters = {};\nvar global_index = 1;\nvar files_ended = false;\nvar MEDIA_PAGINATION_INTERVAL = 20;\n/* handle changing file type / date filter */\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('change', '.thumbs-list-container select.filter', function (event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var filterName = target.data('name');\n  var filterValue = target.val();\n\n  if (filterValue) {\n    filters[filterName] = filterValue;\n  } else {\n    delete filters[filterName];\n  }\n\n  filterFiles();\n});\n/* initialize media uploader */\n\nif (jquery__WEBPACK_IMPORTED_MODULE_0___default()('.thumbs-list-container .dropzone')[0]) {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.thumbs-list-container .dropzone')[0].dropzone.on('queuecomplete', function () {\n    var body = {};\n\n    if (filters.page) {\n      body.page = filters.page;\n    }\n\n    if (filters.date) {\n      body.date = filters.date;\n    }\n\n    if (filters.type) {\n      body.type = filters.type;\n    }\n\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('.dropzone')[0].dropzone.files.forEach(function (file) {\n      file.previewElement.remove();\n    });\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('.dropzone').first().removeClass('dz-started');\n    (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/media-manager.json/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"clearMediaCache\"), {\n      method: 'post',\n      body: body\n    }, function () {\n      filterFiles();\n    });\n  });\n}\n/* handle loading media */\n\n\nvar loadMedia = function loadMedia(filters, callback) {\n  var url = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/media.json/tmpl\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"media-list-content/index\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep).concat(global_index);\n\n  if (filters.page) {\n    url += \"/page\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep).concat(filters.page.split('/').join('%5C'));\n  }\n\n  if (filters.type && filters.type !== '*') {\n    url += \"/type\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep).concat(filters.type);\n  }\n\n  if (filters.date && filters.date !== '*') {\n    url += \"/date\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep).concat(filters.date);\n  }\n\n  if (!isLoading) {\n    isLoading = true;\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('.spinning-wheel').show();\n    jquery__WEBPACK_IMPORTED_MODULE_0___default().get(url, function (content) {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__files').append(content);\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.spinning-wheel').hide();\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.media-container .media-range').trigger('change');\n      isLoading = false;\n      global_index++;\n      callback(content);\n    });\n  }\n};\n\nvar cleanFilesList = function cleanFilesList() {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__files .card-item').remove();\n};\n\nvar resetActiveStateInSidebar = function resetActiveStateInSidebar() {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.pages-list-container .row').removeClass('active'); // clear active state in sidebar\n};\n\nvar showEmptyState = function showEmptyState() {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.thumbs-list-container').append('<p class=\"card-item empty-space\">No media found</p>');\n};\n\nvar filterFiles = function filterFiles() {\n  cleanFilesList();\n  global_index = 0;\n  files_ended = false;\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.empty-space').remove();\n  loadMedia(filters, function (content) {\n    if (!content.trim().length) {\n      showEmptyState();\n    } else {\n      if (!filters.page && (!filters.date || filters.date === '*') && (!filters.type || filters.type === '*')) {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__files').trigger('fillView');\n      }\n    }\n  });\n};\n/* handle changing page */\n\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('click', '.pages-list-container .js__page-link', function (event) {\n  var page = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).data('page');\n  filters['page'] = page;\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.media-list-title .page-indicator').html(page); // set indication\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__reset-pages-filter').removeClass('hidden'); // activate reset pages icon\n\n  resetActiveStateInSidebar();\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).parents('.row').addClass('active'); // set active state in sidebar\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__file-uploader').removeClass('hidden'); // customize processing URL, as the page changes dynamically\n\n  if (jquery__WEBPACK_IMPORTED_MODULE_0___default()('.dropzone')[0]) {\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('.dropzone')[0].dropzone.on('processing', function (file) {\n      this.options.url = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/media-manager\").concat(page, \".json/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"addmedia\");\n    });\n  }\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__button-clear-media-cache').addClass('hidden');\n  filterFiles();\n  disableInfiniteScrolling(); // only infinite scroll on main list, not inside single pages\n});\n/* handle clearing page filter */\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('click', '.js__reset-pages-filter', function (event) {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.media-list-title .page-indicator').html('All Pages'); // set indication\n\n  cleanFilesList();\n  resetActiveStateInSidebar();\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__reset-pages-filter').addClass('hidden'); // remove reset pages icon\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__file-uploader').addClass('hidden');\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__button-clear-media-cache').removeClass('hidden');\n  delete filters['page'];\n  filterFiles();\n});\n/* handle infinite loading */\n\nvar enableInfiniteScrolling = function enableInfiniteScrolling() {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.spinning-wheel').hide();\n  var view = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.mediapicker-scroll').last();\n\n  if (!view.length) {\n    return;\n  }\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(view).on('scroll', function () {\n    if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).scrollTop() + jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).innerHeight() + 100 >= jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)[0].scrollHeight) {\n      fillView();\n    }\n  });\n};\n\nvar loadNextBatch = function loadNextBatch(callback) {\n  if (files_ended) {\n    return;\n  }\n\n  loadMedia({}, function (content) {\n    if (!jquery__WEBPACK_IMPORTED_MODULE_0___default()(content).length || content.split('card-item').length - 1 < MEDIA_PAGINATION_INTERVAL) {\n      files_ended = true;\n    } else {\n      if (callback) {\n        callback();\n      }\n    }\n\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('.media-container .media-range').trigger('input');\n  });\n};\n\nvar fillView = function fillView() {\n  if (!jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__files').find('.card-item').last().offset()) {\n    setTimeout(function () {\n      // retry later\n      fillView();\n    }, 300);\n    return;\n  }\n\n  if (jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__files').find('.card-item').last().offset().top - 1 <= jquery__WEBPACK_IMPORTED_MODULE_0___default()('.media-container').height()) {\n    loadNextBatch(function () {\n      fillView();\n    });\n  }\n};\n/* disable infinite loading */\n\n\nvar disableInfiniteScrolling = function disableInfiniteScrolling() {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.spinning-wheel').hide();\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.content-wrapper').unbind('scroll');\n};\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__files').on('fillView', function (event) {\n  // the first batch got the max number of media files, try loading more\n  if (jquery__WEBPACK_IMPORTED_MODULE_0___default()('.js__files')[0].innerHTML.split('card-item').length - 1 === MEDIA_PAGINATION_INTERVAL) {\n    fillView();\n    enableInfiniteScrolling();\n  }\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 20476 characters]\n//# sourceURL=webpack-internal:///./app/media/index.js\n");

/***/ }),

/***/ "./app/pages/filter.js":
/*!*****************************!*\
  !*** ./app/pages/filter.js ***!
  \*****************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ PagesFilter,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\n/* harmony import */ var debounce__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! debounce */ \"./node_modules/debounce/index.js\");\n/* harmony import */ var debounce__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(debounce__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var _tree__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./tree */ \"./app/pages/tree.js\");\n/* harmony import */ var selectize__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! selectize */ \"./node_modules/selectize/dist/js/selectize.js\");\n/* harmony import */ var selectize__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(selectize__WEBPACK_IMPORTED_MODULE_5__);\n/* harmony import */ var _utils_selectize_required_fix_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../utils/selectize-required-fix.js */ \"./app/utils/selectize-required-fix.js\");\n/* harmony import */ var _utils_storage__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../utils/storage */ \"./app/utils/storage.js\");\n/* harmony import */ var _utils_storage__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_utils_storage__WEBPACK_IMPORTED_MODULE_7__);\nfunction _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\n\n\n\n\n/* @formatter:off */\n\n/* eslint-disable */\n\nvar options = [{\n  flag: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.MODULE,\n  key: 'Module',\n  cat: 'mode'\n}, {\n  flag: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.VISIBLE,\n  key: 'Visible',\n  cat: 'mode'\n}, {\n  flag: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.ROUTABLE,\n  key: 'Routable',\n  cat: 'mode'\n}, {\n  flag: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.PUBLISHED,\n  key: 'Published',\n  cat: 'mode'\n}, {\n  flag: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.NON_MODULE,\n  key: 'NonModule',\n  cat: 'mode'\n}, {\n  flag: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.NON_VISIBLE,\n  key: 'NonVisible',\n  cat: 'mode'\n}, {\n  flag: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.NON_ROUTABLE,\n  key: 'NonRoutable',\n  cat: 'mode'\n}, {\n  flag: grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.NON_PUBLISHED,\n  key: 'NonPublished',\n  cat: 'mode'\n}];\n/* @formatter:on */\n\n/* eslint-enable */\n\nvar PagesFilter = /*#__PURE__*/function () {\n  function PagesFilter(filters, search) {\n    var _this = this;\n\n    _classCallCheck(this, PagesFilter);\n\n    this.filters = jquery__WEBPACK_IMPORTED_MODULE_0___default()(filters);\n    this.search = jquery__WEBPACK_IMPORTED_MODULE_0___default()(search);\n    this.options = options;\n    this.tree = _tree__WEBPACK_IMPORTED_MODULE_4__.Instance;\n    var storage = JSON.parse(localStorage.getItem('grav:admin:pages:filter') || '{}');\n\n    if (!this.filters.length || !this.search.length) {\n      return;\n    }\n\n    this.labels = this.filters.data('filter-labels');\n    this.search.on('input', debounce__WEBPACK_IMPORTED_MODULE_3___default()(function () {\n      return _this.filter();\n    }, 250));\n    this.filters.on('change', function () {\n      return _this.filter();\n    }); // restore state\n\n    if (storage.flags || storage.query) {\n      this.setValues(storage);\n      this.filter();\n    }\n\n    this._initSelectize();\n  }\n\n  _createClass(PagesFilter, [{\n    key: \"filter\",\n    value: function filter(value) {\n      var _this2 = this;\n\n      var data = {\n        flags: '',\n        query: ''\n      };\n\n      if (_typeof(value) === 'object') {\n        Object.assign(data, value);\n      }\n\n      if (typeof value === 'string') {\n        data.query = value;\n      }\n\n      if (typeof value === 'undefined') {\n        data.flags = this.filters.val();\n        data.query = this.search.val();\n      }\n\n      if (!Object.keys(data).filter(function (key) {\n        return data[key] !== '';\n      }).length) {\n        this.resetValues();\n        return;\n      }\n\n      data.flags = data.flags.replace(/(\\s{1,})?,(\\s{1,})?/g, ',');\n      this.setValues({\n        flags: data.flags,\n        query: data.query\n      }, 'silent');\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/pages-filter.json/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"filterPages\"), {\n        method: 'post',\n        body: data\n      }, function (response) {\n        _this2.refreshDOM(response);\n      });\n    }\n  }, {\n    key: \"refreshDOM\",\n    value: function refreshDOM(response) {\n      var _this3 = this;\n\n      var items = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-nav-id]');\n\n      if (!response) {\n        items.removeClass('search-match').show();\n        this.tree.restore();\n        return;\n      }\n\n      items.removeClass('search-match').hide();\n      response.results.forEach(function (page) {\n        var match = items.filter(\"[data-nav-id=\\\"\".concat(page, \"\\\"]\")).addClass('search-match').show();\n        match.parents('[data-nav-id]').addClass('search-match').show();\n\n        _this3.tree.expand(page, 'no-store');\n      });\n    }\n  }, {\n    key: \"setValues\",\n    value: function setValues(_ref, silent) {\n      var _ref$flags = _ref.flags,\n          flags = _ref$flags === void 0 ? '' : _ref$flags,\n          _ref$query = _ref.query,\n          query = _ref$query === void 0 ? '' : _ref$query;\n      var flagsArray = flags.replace(/(\\s{1,})?,(\\s{1,})?/g, ',').split(',');\n\n      if (this.filters.val() !== flags) {\n        var selectize = this.filters.data('selectize');\n        this.filters[selectize ? 'setValue' : 'val'](flagsArray, silent);\n      }\n\n      if (this.search.val() !== query) {\n        this.search.val(query);\n      }\n\n      localStorage.setItem('grav:admin:pages:filter', JSON.stringify({\n        flags: flags,\n        query: query\n      }));\n    }\n  }, {\n    key: \"resetValues\",\n    value: function resetValues() {\n      this.setValues('', 'silent');\n      this.refreshDOM();\n    }\n  }, {\n    key: \"_initSelectize\",\n    value: function _initSelectize() {\n      var _this4 = this;\n\n      var extras = {\n        type: this.filters.data('filter-types') || {},\n        access: this.filters.data('filter-access-levels') || {}\n      };\n      Object.keys(extras).forEach(function (cat) {\n        Object.keys(extras[cat]).forEach(function (key) {\n          _this4.options.push({\n            cat: cat,\n            key: key,\n            flag: extras[cat][key]\n          });\n        });\n      });\n      this.filters.selectize({\n        maxItems: null,\n        valueField: 'key',\n        labelField: 'flag',\n        searchField: ['flag', 'key'],\n        options: this.options,\n        optgroups: this.labels,\n        optgroupField: 'cat',\n        optgroupLabelField: 'name',\n        optgroupValueField: 'id',\n        optgroupOrder: this.labels.map(function (item) {\n          return item.id;\n        }),\n        plugins: ['optgroup_columns', 'required-fix']\n      });\n    }\n  }]);\n\n  return PagesFilter;\n}();\n\n\nvar Instance = new PagesFilter('input[name=\"page-filter\"]', 'input[name=\"page-search\"]');\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 14344 characters]\n//# sourceURL=webpack-internal:///./app/pages/filter.js\n");

/***/ }),

/***/ "./app/pages/index.js":
/*!****************************!*\
  !*** ./app/pages/index.js ***!
  \****************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var sortablejs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! sortablejs */ \"./node_modules/sortablejs/modular/sortable.complete.esm.js\");\n/* harmony import */ var _filter__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./filter */ \"./app/pages/filter.js\");\n/* harmony import */ var _page__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./page */ \"./app/pages/page/index.js\");\n\n\n\n\n\nvar pad = function pad(n, s) {\n  return \"000\".concat(n).substr(-s);\n}; // Pages Ordering\n\n\nvar Ordering = null;\nvar orderingElement = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#ordering');\n\nif (orderingElement.length) {\n  Ordering = new sortablejs__WEBPACK_IMPORTED_MODULE_1__.default(orderingElement.get(0), {\n    filter: '.ignore',\n    onUpdate: function onUpdate() {\n      /* Old single page index behavior\n       let item = $(event.item);\n      let index = orderingElement.children().index(item) + 1;\n      $('[data-order]').val(index);\n      */\n      var indexes = [];\n      var children = orderingElement.children();\n      var padZero = (children.length + '').split('').length;\n      children.each(function (index, item) {\n        item = jquery__WEBPACK_IMPORTED_MODULE_0___default()(item);\n        indexes.push(item.data('id'));\n        item.find('.page-order').text(\"\".concat(pad(index + 1, padZero), \".\"));\n      });\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-order]').val(indexes.join(','));\n    }\n  });\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('input', '[name=\"data[folder]\"]', function (event) {\n    var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n    var activeOrder = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-id][data-active-id]');\n    activeOrder.data('id', target.val());\n    Ordering.options.onUpdate();\n  });\n}\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({\n  Ordering: Ordering,\n  Page: _page__WEBPACK_IMPORTED_MODULE_3__.default,\n  PageFilters: {\n    PageFilters: _filter__WEBPACK_IMPORTED_MODULE_2__.default,\n    Instance: _filter__WEBPACK_IMPORTED_MODULE_2__.Instance\n  }\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4556 characters]\n//# sourceURL=webpack-internal:///./app/pages/index.js\n");

/***/ }),

/***/ "./app/pages/page/add.js":
/*!*******************************!*\
  !*** ./app/pages/page/add.js ***!
  \*******************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_jquery_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../utils/jquery-utils */ \"./app/utils/jquery-utils.js\");\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../utils/request */ \"./app/utils/request.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_3__);\n\n\n\n\nvar custom = false;\nvar folder = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=\"modal\"] input[name=\"data[folder]\"], [data-remodal-id=\"module\"] input[name=\"data[folder]\"]');\nvar title = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=\"modal\"] input[name=\"data[title]\"], [data-remodal-id=\"module\"] input[name=\"data[title]\"]');\n\nvar getFields = function getFields(type, target) {\n  target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target);\n  var query = \"[data-remodal-id=\\\"\".concat(target.closest('[data-remodal-id]').data('remodal-id'), \"\\\"]\");\n  return {\n    title: type === 'title' ? jquery__WEBPACK_IMPORTED_MODULE_0___default()(target) : jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"\".concat(query, \" input[name=\\\"data[title]\\\"]\")),\n    folder: type === 'folder' ? jquery__WEBPACK_IMPORTED_MODULE_0___default()(target) : jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"\".concat(query, \" input[name=\\\"data[folder]\\\"]\"))\n  };\n};\n\ntitle.on('input focus blur', function (event) {\n  if (custom) {\n    return true;\n  }\n\n  var elements = getFields('title', event.currentTarget);\n  var slug = jquery__WEBPACK_IMPORTED_MODULE_0___default().slugify(elements.title.val(), {\n    custom: {\n      \"'\": ''\n    }\n  });\n  elements.folder.val(slug);\n});\nfolder.on('input', function (event) {\n  var elements = getFields('folder', event.currentTarget);\n  var input = elements.folder.get(0);\n  var value = elements.folder.val();\n  var selection = {\n    start: input.selectionStart,\n    end: input.selectionEnd\n  };\n  value = value.toLowerCase().replace(/\\s/g, '-').replace(/[^a-z0-9_\\-]/g, '');\n  elements.folder.val(value);\n  custom = !!value; // restore cursor position\n\n  input.setSelectionRange(selection.start, selection.end);\n});\nfolder.on('focus blur', function (event) {\n  return getFields('title', event.currentTarget).title.trigger('input');\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('change', '[name=\"data[route]\"]', function (event) {\n  var rawroute = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget).val();\n  var pageTemplate = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[name=\"data[name]\"]');\n  var URI = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.config.base_url_relative, \"/ajax.json/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.config.param_sep, \"getChildTypes\");\n\n  if (pageTemplate.length === 0) {\n    return;\n  }\n\n  (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(URI, {\n    method: 'post',\n    body: {\n      rawroute: rawroute\n    }\n  }, function (response) {\n    var type = response.child_type;\n\n    if (type !== '' && type !== 'default') {\n      pageTemplate.val(type);\n      pageTemplate.data('selectize').setValue(type);\n    }\n  });\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 6980 characters]\n//# sourceURL=webpack-internal:///./app/pages/page/add.js\n");

/***/ }),

/***/ "./app/pages/page/delete.js":
/*!**********************************!*\
  !*** ./app/pages/page/delete.js ***!
  \**********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-remodal-target=\"delete\"]', function () {\n  var confirm = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=\"delete\"] [data-delete-action]');\n  var link = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('delete-url');\n  confirm.data('delete-action', link);\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-delete-action]', function () {\n  var remodal = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=\"delete\"]').data('remodal')];\n  __webpack_require__.g.location.href = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('delete-action');\n  remodal.close();\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3BhZ2VzL3BhZ2UvZGVsZXRlLmpzPzEwMTciXSwibmFtZXMiOlsiJCIsImRvY3VtZW50Iiwib24iLCJjb25maXJtIiwibGluayIsImRhdGEiLCJyZW1vZGFsIiwiZ2xvYmFsIiwibG9jYXRpb24iLCJocmVmIiwiY2xvc2UiXSwibWFwcGluZ3MiOiI7OztBQUFBO0FBRUFBLDZDQUFDLENBQUNDLFFBQUQsQ0FBRCxDQUFZQyxFQUFaLENBQWUsT0FBZixFQUF3QixnQ0FBeEIsRUFBMEQsWUFBVztBQUNqRSxNQUFJQyxPQUFPLEdBQUdILDZDQUFDLENBQUMsaURBQUQsQ0FBZjtBQUNBLE1BQUlJLElBQUksR0FBR0osNkNBQUMsQ0FBQyxJQUFELENBQUQsQ0FBUUssSUFBUixDQUFhLFlBQWIsQ0FBWDtBQUVBRixTQUFPLENBQUNFLElBQVIsQ0FBYSxlQUFiLEVBQThCRCxJQUE5QjtBQUNILENBTEQ7QUFPQUosNkNBQUMsQ0FBQ0MsUUFBRCxDQUFELENBQVlDLEVBQVosQ0FBZSxPQUFmLEVBQXdCLHNCQUF4QixFQUFnRCxZQUFXO0FBQ3ZELE1BQUlJLE9BQU8sR0FBR04sOERBQUEsQ0FBaUJBLDZDQUFDLENBQUMsNEJBQUQsQ0FBRCxDQUFnQ0ssSUFBaEMsQ0FBcUMsU0FBckMsQ0FBakIsQ0FBZDtBQUVBRSx1QkFBTSxDQUFDQyxRQUFQLENBQWdCQyxJQUFoQixHQUF1QlQsNkNBQUMsQ0FBQyxJQUFELENBQUQsQ0FBUUssSUFBUixDQUFhLGVBQWIsQ0FBdkI7QUFDQUMsU0FBTyxDQUFDSSxLQUFSO0FBQ0gsQ0FMRCIsImZpbGUiOiIuL2FwcC9wYWdlcy9wYWdlL2RlbGV0ZS5qcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCAkIGZyb20gJ2pxdWVyeSc7XG5cbiQoZG9jdW1lbnQpLm9uKCdjbGljaycsICdbZGF0YS1yZW1vZGFsLXRhcmdldD1cImRlbGV0ZVwiXScsIGZ1bmN0aW9uKCkge1xuICAgIGxldCBjb25maXJtID0gJCgnW2RhdGEtcmVtb2RhbC1pZD1cImRlbGV0ZVwiXSBbZGF0YS1kZWxldGUtYWN0aW9uXScpO1xuICAgIGxldCBsaW5rID0gJCh0aGlzKS5kYXRhKCdkZWxldGUtdXJsJyk7XG5cbiAgICBjb25maXJtLmRhdGEoJ2RlbGV0ZS1hY3Rpb24nLCBsaW5rKTtcbn0pO1xuXG4kKGRvY3VtZW50KS5vbignY2xpY2snLCAnW2RhdGEtZGVsZXRlLWFjdGlvbl0nLCBmdW5jdGlvbigpIHtcbiAgICBsZXQgcmVtb2RhbCA9ICQucmVtb2RhbC5sb29rdXBbJCgnW2RhdGEtcmVtb2RhbC1pZD1cImRlbGV0ZVwiXScpLmRhdGEoJ3JlbW9kYWwnKV07XG5cbiAgICBnbG9iYWwubG9jYXRpb24uaHJlZiA9ICQodGhpcykuZGF0YSgnZGVsZXRlLWFjdGlvbicpO1xuICAgIHJlbW9kYWwuY2xvc2UoKTtcbn0pO1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./app/pages/page/delete.js\n");

/***/ }),

/***/ "./app/pages/page/disable-buttons.js":
/*!*******************************************!*\
  !*** ./app/pages/page/disable-buttons.js ***!
  \*******************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('.disable-after-click').on('click', function () {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).addClass('pointer-events-disabled');\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3BhZ2VzL3BhZ2UvZGlzYWJsZS1idXR0b25zLmpzPzZiODEiXSwibmFtZXMiOlsiJCIsIm9uIiwiYWRkQ2xhc3MiXSwibWFwcGluZ3MiOiI7OztBQUFBO0FBRUFBLDZDQUFDLENBQUMsc0JBQUQsQ0FBRCxDQUEwQkMsRUFBMUIsQ0FBNkIsT0FBN0IsRUFBc0MsWUFBVztBQUM3Q0QsK0NBQUMsQ0FBQyxJQUFELENBQUQsQ0FBUUUsUUFBUixDQUFpQix5QkFBakI7QUFDSCxDQUZEIiwiZmlsZSI6Ii4vYXBwL3BhZ2VzL3BhZ2UvZGlzYWJsZS1idXR0b25zLmpzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0ICQgZnJvbSAnanF1ZXJ5JztcblxuJCgnLmRpc2FibGUtYWZ0ZXItY2xpY2snKS5vbignY2xpY2snLCBmdW5jdGlvbigpIHtcbiAgICAkKHRoaXMpLmFkZENsYXNzKCdwb2ludGVyLWV2ZW50cy1kaXNhYmxlZCcpO1xufSk7XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./app/pages/page/disable-buttons.js\n");

/***/ }),

/***/ "./app/pages/page/index.js":
/*!*********************************!*\
  !*** ./app/pages/page/index.js ***!
  \*********************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _add__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./add */ \"./app/pages/page/add.js\");\n/* harmony import */ var _move__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./move */ \"./app/pages/page/move.js\");\n/* harmony import */ var _delete__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./delete */ \"./app/pages/page/delete.js\");\n/* harmony import */ var _unset__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./unset */ \"./app/pages/page/unset.js\");\n/* harmony import */ var _disable_buttons__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./disable-buttons */ \"./app/pages/page/disable-buttons.js\");\n/* harmony import */ var _media__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./media */ \"./app/pages/page/media.js\");\n/* harmony import */ var _multilang__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./multilang */ \"./app/pages/page/multilang.js\");\n\n\n\n\n\n\n\n\nvar switcher = jquery__WEBPACK_IMPORTED_MODULE_0___default()('input[type=\"radio\"][name=\"mode-switch\"]');\n\nif (switcher) {\n  var link = switcher.closest(':checked').data('leave-url');\n  var fakeLink = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"<a href=\\\"\".concat(link, \"\\\" />\"));\n  switcher.parent().append(fakeLink);\n  switcher.siblings('label').on('mousedown touchdown', function (event) {\n    event.preventDefault(); // let remodal = $.remodal.lookup[$('[data-remodal-id=\"changes\"]').data('remodal')];\n\n    var confirm = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=\"changes\"] [data-leave-action=\"continue\"]');\n    confirm.one('click', function () {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).on('beforeunload._grav');\n      fakeLink.off('click._grav');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).trigger('click');\n    });\n    fakeLink.trigger('click._grav');\n  });\n  switcher.on('change', function (event) {\n    var radio = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n    link = radio.data('leave-url');\n    setTimeout(function () {\n      return fakeLink.attr('href', link).get(0).click();\n    }, 5);\n  });\n}\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({\n  Media: {\n    PageMedia: _media__WEBPACK_IMPORTED_MODULE_6__.default,\n    PageMediaInstances: _media__WEBPACK_IMPORTED_MODULE_6__.Instance\n  }\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3BhZ2VzL3BhZ2UvaW5kZXguanM/YzAxYyJdLCJuYW1lcyI6WyJzd2l0Y2hlciIsIiQiLCJsaW5rIiwiY2xvc2VzdCIsImRhdGEiLCJmYWtlTGluayIsInBhcmVudCIsImFwcGVuZCIsInNpYmxpbmdzIiwib24iLCJldmVudCIsInByZXZlbnREZWZhdWx0IiwiY29uZmlybSIsIm9uZSIsImdsb2JhbCIsIm9mZiIsInRhcmdldCIsInRyaWdnZXIiLCJyYWRpbyIsInNldFRpbWVvdXQiLCJhdHRyIiwiZ2V0IiwiY2xpY2siLCJNZWRpYSIsIlBhZ2VNZWRpYSIsIlBhZ2VNZWRpYUluc3RhbmNlcyJdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7OztBQUFBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFFQSxJQUFNQSxRQUFRLEdBQUdDLDZDQUFDLENBQUMseUNBQUQsQ0FBbEI7O0FBRUEsSUFBSUQsUUFBSixFQUFjO0FBQ1YsTUFBSUUsSUFBSSxHQUFHRixRQUFRLENBQUNHLE9BQVQsQ0FBaUIsVUFBakIsRUFBNkJDLElBQTdCLENBQWtDLFdBQWxDLENBQVg7QUFDQSxNQUFJQyxRQUFRLEdBQUdKLDZDQUFDLHFCQUFhQyxJQUFiLFdBQWhCO0FBRUFGLFVBQVEsQ0FBQ00sTUFBVCxHQUFrQkMsTUFBbEIsQ0FBeUJGLFFBQXpCO0FBRUFMLFVBQVEsQ0FBQ1EsUUFBVCxDQUFrQixPQUFsQixFQUEyQkMsRUFBM0IsQ0FBOEIscUJBQTlCLEVBQXFELFVBQUNDLEtBQUQsRUFBVztBQUM1REEsU0FBSyxDQUFDQyxjQUFOLEdBRDRELENBRzVEOztBQUNBLFFBQUlDLE9BQU8sR0FBR1gsNkNBQUMsQ0FBQyw0REFBRCxDQUFmO0FBRUFXLFdBQU8sQ0FBQ0MsR0FBUixDQUFZLE9BQVosRUFBcUIsWUFBTTtBQUN2QlosbURBQUMsQ0FBQ2EscUJBQUQsQ0FBRCxDQUFVTCxFQUFWLENBQWEsb0JBQWI7QUFDQUosY0FBUSxDQUFDVSxHQUFULENBQWEsYUFBYjtBQUVBZCxtREFBQyxDQUFDUyxLQUFLLENBQUNNLE1BQVAsQ0FBRCxDQUFnQkMsT0FBaEIsQ0FBd0IsT0FBeEI7QUFDSCxLQUxEO0FBT0FaLFlBQVEsQ0FBQ1ksT0FBVCxDQUFpQixhQUFqQjtBQUNILEdBZEQ7QUFnQkFqQixVQUFRLENBQUNTLEVBQVQsQ0FBWSxRQUFaLEVBQXNCLFVBQUNDLEtBQUQsRUFBVztBQUM3QixRQUFJUSxLQUFLLEdBQUdqQiw2Q0FBQyxDQUFDUyxLQUFLLENBQUNNLE1BQVAsQ0FBYjtBQUNBZCxRQUFJLEdBQUdnQixLQUFLLENBQUNkLElBQU4sQ0FBVyxXQUFYLENBQVA7QUFFQWUsY0FBVSxDQUFDO0FBQUEsYUFBTWQsUUFBUSxDQUFDZSxJQUFULENBQWMsTUFBZCxFQUFzQmxCLElBQXRCLEVBQTRCbUIsR0FBNUIsQ0FBZ0MsQ0FBaEMsRUFBbUNDLEtBQW5DLEVBQU47QUFBQSxLQUFELEVBQW1ELENBQW5ELENBQVY7QUFDSCxHQUxEO0FBTUg7O0FBRUQsaUVBQWU7QUFDWEMsT0FBSyxFQUFFO0FBQ0hDLGFBQVMsRUFBVEEsMkNBREc7QUFFSEMsc0JBQWtCLEVBQWxCQSw0Q0FBa0JBO0FBRmY7QUFESSxDQUFmIiwiZmlsZSI6Ii4vYXBwL3BhZ2VzL3BhZ2UvaW5kZXguanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgJCBmcm9tICdqcXVlcnknO1xuaW1wb3J0ICcuL2FkZCc7XG5pbXBvcnQgJy4vbW92ZSc7XG5pbXBvcnQgJy4vZGVsZXRlJztcbmltcG9ydCAnLi91bnNldCc7XG5pbXBvcnQgJy4vZGlzYWJsZS1idXR0b25zJztcbmltcG9ydCBQYWdlTWVkaWEsIHsgSW5zdGFuY2UgYXMgUGFnZU1lZGlhSW5zdGFuY2VzIH0gZnJvbSAnLi9tZWRpYSc7XG5pbXBvcnQgJy4vbXVsdGlsYW5nJztcblxuY29uc3Qgc3dpdGNoZXIgPSAkKCdpbnB1dFt0eXBlPVwicmFkaW9cIl1bbmFtZT1cIm1vZGUtc3dpdGNoXCJdJyk7XG5cbmlmIChzd2l0Y2hlcikge1xuICAgIGxldCBsaW5rID0gc3dpdGNoZXIuY2xvc2VzdCgnOmNoZWNrZWQnKS5kYXRhKCdsZWF2ZS11cmwnKTtcbiAgICBsZXQgZmFrZUxpbmsgPSAkKGA8YSBocmVmPVwiJHtsaW5rfVwiIC8+YCk7XG5cbiAgICBzd2l0Y2hlci5wYXJlbnQoKS5hcHBlbmQoZmFrZUxpbmspO1xuXG4gICAgc3dpdGNoZXIuc2libGluZ3MoJ2xhYmVsJykub24oJ21vdXNlZG93biB0b3VjaGRvd24nLCAoZXZlbnQpID0+IHtcbiAgICAgICAgZXZlbnQucHJldmVudERlZmF1bHQoKTtcblxuICAgICAgICAvLyBsZXQgcmVtb2RhbCA9ICQucmVtb2RhbC5sb29rdXBbJCgnW2RhdGEtcmVtb2RhbC1pZD1cImNoYW5nZXNcIl0nKS5kYXRhKCdyZW1vZGFsJyldO1xuICAgICAgICBsZXQgY29uZmlybSA9ICQoJ1tkYXRhLXJlbW9kYWwtaWQ9XCJjaGFuZ2VzXCJdIFtkYXRhLWxlYXZlLWFjdGlvbj1cImNvbnRpbnVlXCJdJyk7XG5cbiAgICAgICAgY29uZmlybS5vbmUoJ2NsaWNrJywgKCkgPT4ge1xuICAgICAgICAgICAgJChnbG9iYWwpLm9uKCdiZWZvcmV1bmxvYWQuX2dyYXYnKTtcbiAgICAgICAgICAgIGZha2VMaW5rLm9mZignY2xpY2suX2dyYXYnKTtcblxuICAgICAgICAgICAgJChldmVudC50YXJnZXQpLnRyaWdnZXIoJ2NsaWNrJyk7XG4gICAgICAgIH0pO1xuXG4gICAgICAgIGZha2VMaW5rLnRyaWdnZXIoJ2NsaWNrLl9ncmF2Jyk7XG4gICAgfSk7XG5cbiAgICBzd2l0Y2hlci5vbignY2hhbmdlJywgKGV2ZW50KSA9PiB7XG4gICAgICAgIGxldCByYWRpbyA9ICQoZXZlbnQudGFyZ2V0KTtcbiAgICAgICAgbGluayA9IHJhZGlvLmRhdGEoJ2xlYXZlLXVybCcpO1xuXG4gICAgICAgIHNldFRpbWVvdXQoKCkgPT4gZmFrZUxpbmsuYXR0cignaHJlZicsIGxpbmspLmdldCgwKS5jbGljaygpLCA1KTtcbiAgICB9KTtcbn1cblxuZXhwb3J0IGRlZmF1bHQge1xuICAgIE1lZGlhOiB7XG4gICAgICAgIFBhZ2VNZWRpYSxcbiAgICAgICAgUGFnZU1lZGlhSW5zdGFuY2VzXG4gICAgfVxufTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/pages/page/index.js\n");

/***/ }),

/***/ "./app/pages/page/media.js":
/*!*********************************!*\
  !*** ./app/pages/page/media.js ***!
  \*********************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ PageMedia,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../utils/request */ \"./app/utils/request.js\");\n/* harmony import */ var _forms_fields_files__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../forms/fields/files */ \"./app/forms/fields/files.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var _forms_fields_editor__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../forms/fields/editor */ \"./app/forms/fields/editor.js\");\n/* harmony import */ var sortablejs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! sortablejs */ \"./node_modules/sortablejs/modular/sortable.complete.esm.js\");\nfunction _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\nfunction _get(target, property, receiver) { if (typeof Reflect !== \"undefined\" && Reflect.get) { _get = Reflect.get; } else { _get = function _get(target, property, receiver) { var base = _superPropBase(target, property); if (!base) return; var desc = Object.getOwnPropertyDescriptor(base, property); if (desc.get) { return desc.get.call(receiver); } return desc.value; }; } return _get(target, property, receiver || target); }\n\nfunction _superPropBase(object, property) { while (!Object.prototype.hasOwnProperty.call(object, property)) { object = _getPrototypeOf(object); if (object === null) break; } return object; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function\"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }\n\nfunction _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) { return call; } return _assertThisInitialized(self); }\n\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nfunction _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }\n\n\n\n\n\n\n\nvar previewTemplate = \"\\n    <div class=\\\"dz-preview dz-file-preview\\\">\\n      <div class=\\\"dz-details\\\">\\n        <div class=\\\"dz-filename\\\"><span data-dz-name></span></div>\\n        <div class=\\\"dz-size\\\" data-dz-size></div>\\n        <img data-dz-thumbnail />\\n      </div>\\n      <div class=\\\"dz-progress\\\"><span class=\\\"dz-upload\\\" data-dz-uploadprogress></span></div>\\n      <div class=\\\"dz-success-mark\\\"><span>\\u2714</span></div>\\n      <div class=\\\"dz-error-mark\\\"><span>\\u2718</span></div>\\n      <div class=\\\"dz-error-message\\\"><span data-dz-errormessage></span></div>\\n      <a class=\\\"dz-remove\\\" title=\\\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DELETE, \"\\\" href=\\\"javascript:undefined;\\\" data-dz-remove>\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.DELETE, \"</a>\\n      <a class=\\\"dz-metadata\\\" title=\\\"\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.METADATA, \"\\\" href=\\\"#\\\" target=\\\"_blank\\\" data-dz-metadata>\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.METADATA, \"</a>\\n      <a class=\\\"dz-view\\\" title=\\\"\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.VIEW, \"\\\" href=\\\"#\\\" target=\\\"_blank\\\" data-dz-view>\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.VIEW, \"</a>\\n      <a class=\\\"dz-insert\\\" title=\\\"\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.INSERT, \"\\\" href=\\\"javascript:undefined;\\\" data-dz-insert>\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.translations.PLUGIN_ADMIN.INSERT, \"</a>\\n    </div>\").trim();\n\nvar PageMedia = /*#__PURE__*/function (_FilesField) {\n  _inherits(PageMedia, _FilesField);\n\n  var _super = _createSuper(PageMedia);\n\n  function PageMedia() {\n    var _this;\n\n    var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},\n        _ref$container = _ref.container,\n        container = _ref$container === void 0 ? '#grav-dropzone' : _ref$container,\n        _ref$options = _ref.options,\n        options = _ref$options === void 0 ? {} : _ref$options;\n\n    _classCallCheck(this, PageMedia);\n\n    options = Object.assign(options, {\n      previewTemplate: previewTemplate\n    });\n    _this = _super.call(this, {\n      container: container,\n      options: options\n    });\n\n    if (!_this.container.length) {\n      return _possibleConstructorReturn(_this);\n    }\n\n    _this.urls = {\n      fetch: \"\".concat(_this.container.data('media-url'), \"/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.config.param_sep, \"listmedia\"),\n      add: \"\".concat(_this.container.data('media-url'), \"/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.config.param_sep, \"addmedia\"),\n      \"delete\": \"\".concat(_this.container.data('media-url'), \"/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_3__.config.param_sep, \"delmedia\")\n    };\n    _this.dropzone.options.url = _this.urls.add;\n\n    if (typeof _this.options.fetchMedia === 'undefined' || _this.options.fetchMedia) {\n      _this.fetchMedia();\n    }\n\n    if (typeof _this.options.attachDragDrop === 'undefined' || _this.options.attachDragDrop) {\n      _this.attachDragDrop();\n    }\n\n    var field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[name=\\\"\".concat(_this.container.data('dropzone-field'), \"\\\"]\"));\n\n    if (field.length) {\n      _this.sortable = new sortablejs__WEBPACK_IMPORTED_MODULE_5__.default(_this.container.get(0), {\n        animation: 150,\n        // forceFallback: true,\n        setData: function setData(dataTransfer, target) {\n          target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(target);\n          var uri = encodeURI(target.find('.dz-filename').text());\n          var shortcode = (0,_forms_fields_files__WEBPACK_IMPORTED_MODULE_2__.UriToMarkdown)(uri);\n\n          _this.dropzone.disable();\n\n          target.addClass('hide-backface');\n          dataTransfer.effectAllowed = 'copy';\n          dataTransfer.setData('text', shortcode);\n        },\n        onSort: function onSort() {\n          var names = [];\n\n          _this.container.find('[data-dz-name]').each(function (index, file) {\n            file = jquery__WEBPACK_IMPORTED_MODULE_0___default()(file);\n            var name = file.text().trim();\n            names.push(name);\n          });\n\n          field.val(names.join(','));\n        }\n      });\n    }\n\n    return _this;\n  }\n\n  _createClass(PageMedia, [{\n    key: \"fetchMedia\",\n    value: function fetchMedia() {\n      var _this2 = this;\n\n      var order = this.container.closest('.form-field').find('[name=\"data[header][media_order]\"]').val();\n      var body = {\n        uri: this.getURI(),\n        order: order\n      };\n      var url = this.urls.fetch;\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_1__.default)(url, {\n        method: 'post',\n        body: body\n      }, function (response) {\n        var results = response.results;\n        Object.keys(results).forEach(function (name) {\n          var data = results[name];\n          var mock = {\n            name: name,\n            size: data.size,\n            accepted: true,\n            extras: data\n          };\n\n          _this2.dropzone.files.push(mock);\n\n          _this2.dropzone.options.addedfile.call(_this2.dropzone, mock);\n\n          _this2.dropzone.options.thumbnail.call(_this2.dropzone, mock, data.url);\n        });\n\n        _this2.container.find('.dz-preview').prop('draggable', 'true');\n      });\n    }\n  }, {\n    key: \"onDropzoneSending\",\n    value: function onDropzoneSending(file, xhr, formData) {\n      /*\n      // Cannot call super because Safari and IE API don't implement `delete`\n      super.onDropzoneSending(file, xhr, formData);\n      formData.delete('task');\n      */\n      formData.append('name', this.options.dotNotation || file.name);\n      formData.append('admin-nonce', grav_config__WEBPACK_IMPORTED_MODULE_3__.config.admin_nonce);\n      formData.append('uri', this.getURI());\n    }\n  }, {\n    key: \"onDropzoneComplete\",\n    value: function onDropzoneComplete(file) {\n      _get(_getPrototypeOf(PageMedia.prototype), \"onDropzoneComplete\", this).call(this, file);\n\n      this.sortable.options.onSort(); // accepted\n\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.dz-preview').prop('draggable', 'true');\n    }\n  }, {\n    key: \"onDropzoneRemovedFile\",\n    value: function onDropzoneRemovedFile(file) {\n      var _get2;\n\n      for (var _len = arguments.length, extra = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n        extra[_key - 1] = arguments[_key];\n      }\n\n      (_get2 = _get(_getPrototypeOf(PageMedia.prototype), \"onDropzoneRemovedFile\", this)).call.apply(_get2, [this, file].concat(extra));\n\n      this.sortable.options.onSort();\n    }\n  }, {\n    key: \"attachDragDrop\",\n    value: function attachDragDrop() {\n      var _this3 = this;\n\n      this.container.delegate('[data-dz-insert]', 'click', function (e) {\n        var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.currentTarget).parent('.dz-preview').find('.dz-filename');\n        var editor = _forms_fields_editor__WEBPACK_IMPORTED_MODULE_4__.Instance.editors.filter(function (index, editor) {\n          return jquery__WEBPACK_IMPORTED_MODULE_0___default()(editor).attr('name') === 'data[content]';\n        });\n\n        if (editor.length) {\n          editor = editor.data('codemirror');\n          editor.focus();\n          var filename = encodeURI(target.text());\n          var shortcode = (0,_forms_fields_files__WEBPACK_IMPORTED_MODULE_2__.UriToMarkdown)(filename);\n          editor.doc.replaceSelection(shortcode);\n        }\n      });\n      this.container.delegate('[data-dz-view]', 'mouseenter', function (e) {\n        var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.currentTarget);\n        var file = target.parent('.dz-preview').find('.dz-filename');\n        var filename = encodeURI(file.text());\n        var URL = target.closest('[data-media-path]').data('media-path');\n\n        var original = _this3.dropzone.files.filter(function (file) {\n          return encodeURI(file.name) === filename;\n        }).shift();\n\n        original = original && (original.extras && original.extras.original || encodeURI(original.name));\n        target.attr('href', \"\".concat(URL, \"/\").concat(original));\n      });\n      this.container.delegate('[data-dz-metadata]', 'click', function (e) {\n        e.preventDefault();\n        var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.currentTarget);\n        var file = target.parent('.dz-preview').find('.dz-filename');\n        var filename = encodeURI(file.text());\n        var fileObj = _this3.dropzone.files.filter(function (file) {\n          return file.name === __webpack_require__.g.decodeURI(filename);\n        }).shift() || {};\n\n        if (!fileObj.extras) {\n          fileObj.extras = {\n            metadata: []\n          };\n        }\n\n        if (Array.isArray(fileObj.extras.metadata) && !fileObj.extras.metadata.length) {\n          fileObj.extras.metadata = {\n            '': \"\".concat(__webpack_require__.g.decodeURI(filename), \".meta.yaml doesn't exist\")\n          };\n        }\n\n        fileObj = fileObj.extras;\n        var modal_element = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').find('[data-remodal-id=\"metadata\"]');\n        var modal = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[modal_element.data('remodal')];\n        modal_element.find('h1 strong').html(filename);\n\n        if (fileObj.url) {\n          modal_element.find('.meta-preview').html(\"<img src=\\\"\".concat(fileObj.url, \"\\\" />\"));\n        }\n\n        var container = modal_element.find('.meta-content').html('<ul />').find('ul');\n        Object.keys(fileObj.metadata).forEach(function (meta) {\n          container.append(\"<li><strong>\".concat(meta ? meta + ':' : '', \"</strong> \").concat(fileObj.metadata[meta], \"</li>\"));\n        });\n        modal.open();\n      });\n      this.container.delegate('.dz-preview', 'dragstart', function (e) {\n        var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.currentTarget);\n        var uri = encodeURI(target.find('.dz-filename').text());\n        var shortcode = (0,_forms_fields_files__WEBPACK_IMPORTED_MODULE_2__.UriToMarkdown)(uri);\n\n        _this3.dropzone.disable();\n\n        target.addClass('hide-backface');\n        e.originalEvent.dataTransfer.effectAllowed = 'copy';\n        e.originalEvent.dataTransfer.setData('text', shortcode);\n      });\n      this.container.delegate('.dz-preview', 'dragend', function (e) {\n        var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.currentTarget);\n\n        _this3.dropzone.enable();\n\n        target.removeClass('hide-backface');\n      });\n    }\n  }]);\n\n  return PageMedia;\n}(_forms_fields_files__WEBPACK_IMPORTED_MODULE_2__.default);\n\n\nvar Instance = new PageMedia();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 22996 characters]\n//# sourceURL=webpack-internal:///./app/pages/page/media.js\n");

/***/ }),

/***/ "./app/pages/page/move.js":
/*!********************************!*\
  !*** ./app/pages/page/move.js ***!
  \********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-page-move] button[name=\"task\"][value=\"save\"]', function (event) {\n  /* let route = $('form#blueprints:first select[name=\"data[route]\"]');\n  let moveTo = $('[data-page-move] select').val();\n   if (route.length && route.val() !== moveTo) {\n      let selectize = route.data('selectize');\n      route.val(moveTo);\n       if (selectize) selectize.setValue(moveTo);\n  }*/\n  var modal = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget).closest('[data-remodal-id]');\n  var parents = modal.data('parents') || {};\n  var finder = parents.finder;\n\n  if (!parents || !finder) {\n    return true;\n  }\n\n  var field = parents.field;\n  var parentLabel = parents.parentLabel;\n  var parentName = parents.parentName;\n  var selection = finder.findLastActive().item[0];\n  var value = selection._item[finder.config.valueKey];\n  var name = selection._item[finder.config.labelKey];\n  field.val(value);\n  parentLabel.text(value);\n  parentName.text(name);\n  finder.config.defaultPath = value;\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div />').css({\n    backgroundColor: 'rgba(255, 255, 255, 0.1)',\n    position: 'fixed',\n    top: 0,\n    left: 0,\n    width: '100vw',\n    height: '100vh',\n    zIndex: 15000\n  }).appendTo(jquery__WEBPACK_IMPORTED_MODULE_0___default()('body'));\n});\n/*\n$(document).on('click', '[data-remodal-id=\"parents\"] [data-parents-select]', (event) => {\n    const modal = $(event.currentTarget).closest('[data-remodal-id]');\n    const parents = modal.data('parents');\n    const finder = parents.finder;\n    const field = parents.field;\n    const parentLabel = parents.parentLabel;\n    const parentName = parents.parentName;\n    const selection = finder.findLastActive().item[0];\n    const value = selection._item[finder.config.valueKey];\n    const name = selection._item[finder.config.labelKey];\n\n    field.val(value);\n    parentLabel.text(value);\n    parentName.text(name);\n    finder.config.defaultPath = value;\n\n    const remodal = $.remodal.lookup[$(`[data-remodal-id=\"${modal.data('remodalId')}\"]`).data('remodal')];\n    remodal.close();\n});\n*///# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 5164 characters]\n//# sourceURL=webpack-internal:///./app/pages/page/move.js\n");

/***/ }),

/***/ "./app/pages/page/multilang.js":
/*!*************************************!*\
  !*** ./app/pages/page/multilang.js ***!
  \*************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('[name=\"task\"][value=\"saveas\"], [name=\"task\"][value=\"switchlanguage\"]').on('mousedown touchstart', function (event) {\n  var fields = ['lang', 'redirect'];\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var form = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"#\".concat(element.attr('form')));\n\n  if (!form.length) {\n    return;\n  }\n\n  fields.forEach(function (field) {\n    var value = element.attr(field);\n\n    if (!value) {\n      return;\n    }\n\n    var input = form.find(\"[name=\\\"data[\".concat(field, \"]\\\"]\"));\n\n    if (!input.length) {\n      input = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"<input type=\\\"hidden\\\" name=\\\"data[\".concat(field, \"]\\\" value=\\\"\\\" />\"));\n      form.append(input);\n    }\n\n    input.val(value);\n  });\n  return true;\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3BhZ2VzL3BhZ2UvbXVsdGlsYW5nLmpzPzBjMDEiXSwibmFtZXMiOlsiJCIsIm9uIiwiZXZlbnQiLCJmaWVsZHMiLCJlbGVtZW50IiwiY3VycmVudFRhcmdldCIsImZvcm0iLCJhdHRyIiwibGVuZ3RoIiwiZm9yRWFjaCIsImZpZWxkIiwidmFsdWUiLCJpbnB1dCIsImZpbmQiLCJhcHBlbmQiLCJ2YWwiXSwibWFwcGluZ3MiOiI7OztBQUFBO0FBRUFBLDZDQUFDLENBQUMsc0VBQUQsQ0FBRCxDQUEwRUMsRUFBMUUsQ0FBNkUsc0JBQTdFLEVBQXFHLFVBQUNDLEtBQUQsRUFBVztBQUM1RyxNQUFJQyxNQUFNLEdBQUcsQ0FBQyxNQUFELEVBQVMsVUFBVCxDQUFiO0FBQ0EsTUFBSUMsT0FBTyxHQUFHSiw2Q0FBQyxDQUFDRSxLQUFLLENBQUNHLGFBQVAsQ0FBZjtBQUNBLE1BQUlDLElBQUksR0FBR04sNkNBQUMsWUFBS0ksT0FBTyxDQUFDRyxJQUFSLENBQWEsTUFBYixDQUFMLEVBQVo7O0FBRUEsTUFBSSxDQUFDRCxJQUFJLENBQUNFLE1BQVYsRUFBa0I7QUFBRTtBQUFTOztBQUM3QkwsUUFBTSxDQUFDTSxPQUFQLENBQWUsVUFBQ0MsS0FBRCxFQUFXO0FBQ3RCLFFBQUlDLEtBQUssR0FBR1AsT0FBTyxDQUFDRyxJQUFSLENBQWFHLEtBQWIsQ0FBWjs7QUFDQSxRQUFJLENBQUNDLEtBQUwsRUFBWTtBQUFFO0FBQVM7O0FBQ3ZCLFFBQUlDLEtBQUssR0FBR04sSUFBSSxDQUFDTyxJQUFMLHdCQUF5QkgsS0FBekIsVUFBWjs7QUFDQSxRQUFJLENBQUNFLEtBQUssQ0FBQ0osTUFBWCxFQUFtQjtBQUNmSSxXQUFLLEdBQUdaLDZDQUFDLDhDQUFvQ1UsS0FBcEMsdUJBQVQ7QUFDQUosVUFBSSxDQUFDUSxNQUFMLENBQVlGLEtBQVo7QUFDSDs7QUFFREEsU0FBSyxDQUFDRyxHQUFOLENBQVVKLEtBQVY7QUFDSCxHQVZEO0FBWUEsU0FBTyxJQUFQO0FBQ0gsQ0FuQkQiLCJmaWxlIjoiLi9hcHAvcGFnZXMvcGFnZS9tdWx0aWxhbmcuanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgJCBmcm9tICdqcXVlcnknO1xuXG4kKCdbbmFtZT1cInRhc2tcIl1bdmFsdWU9XCJzYXZlYXNcIl0sIFtuYW1lPVwidGFza1wiXVt2YWx1ZT1cInN3aXRjaGxhbmd1YWdlXCJdJykub24oJ21vdXNlZG93biB0b3VjaHN0YXJ0JywgKGV2ZW50KSA9PiB7XG4gICAgbGV0IGZpZWxkcyA9IFsnbGFuZycsICdyZWRpcmVjdCddO1xuICAgIGxldCBlbGVtZW50ID0gJChldmVudC5jdXJyZW50VGFyZ2V0KTtcbiAgICBsZXQgZm9ybSA9ICQoYCMke2VsZW1lbnQuYXR0cignZm9ybScpfWApO1xuXG4gICAgaWYgKCFmb3JtLmxlbmd0aCkgeyByZXR1cm47IH1cbiAgICBmaWVsZHMuZm9yRWFjaCgoZmllbGQpID0+IHtcbiAgICAgICAgbGV0IHZhbHVlID0gZWxlbWVudC5hdHRyKGZpZWxkKTtcbiAgICAgICAgaWYgKCF2YWx1ZSkgeyByZXR1cm47IH1cbiAgICAgICAgbGV0IGlucHV0ID0gZm9ybS5maW5kKGBbbmFtZT1cImRhdGFbJHtmaWVsZH1dXCJdYCk7XG4gICAgICAgIGlmICghaW5wdXQubGVuZ3RoKSB7XG4gICAgICAgICAgICBpbnB1dCA9ICQoYDxpbnB1dCB0eXBlPVwiaGlkZGVuXCIgbmFtZT1cImRhdGFbJHtmaWVsZH1dXCIgdmFsdWU9XCJcIiAvPmApO1xuICAgICAgICAgICAgZm9ybS5hcHBlbmQoaW5wdXQpO1xuICAgICAgICB9XG5cbiAgICAgICAgaW5wdXQudmFsKHZhbHVlKTtcbiAgICB9KTtcblxuICAgIHJldHVybiB0cnVlO1xufSk7XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./app/pages/page/multilang.js\n");

/***/ }),

/***/ "./app/pages/page/unset.js":
/*!*********************************!*\
  !*** ./app/pages/page/unset.js ***!
  \*********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '.dz-unset', function () {\n  var file_upload = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).closest('.files-upload');\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).closest('.dz-image-preview').remove();\n  var unset_image = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).closest('.dz-image-preview').find('[data-dz-name]').text().trim();\n  var images = JSON.parse(file_upload.find('input[data-grav-field=\"hidden\"]').val()) || {};\n  var image_array = {};\n  jquery__WEBPACK_IMPORTED_MODULE_0___default().each(images, function (ind, obj) {\n    if (!ind.endsWith(unset_image)) {\n      image_array[ind] = obj;\n    }\n  });\n  file_upload.find('input[data-grav-field=\"hidden\"]').val(JSON.stringify(image_array));\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3BhZ2VzL3BhZ2UvdW5zZXQuanM/OWZiYyJdLCJuYW1lcyI6WyIkIiwiZG9jdW1lbnQiLCJvbiIsImZpbGVfdXBsb2FkIiwiY2xvc2VzdCIsInJlbW92ZSIsInVuc2V0X2ltYWdlIiwiZmluZCIsInRleHQiLCJ0cmltIiwiaW1hZ2VzIiwiSlNPTiIsInBhcnNlIiwidmFsIiwiaW1hZ2VfYXJyYXkiLCJpbmQiLCJvYmoiLCJlbmRzV2l0aCIsInN0cmluZ2lmeSJdLCJtYXBwaW5ncyI6Ijs7O0FBQUE7QUFFQUEsNkNBQUMsQ0FBQ0MsUUFBRCxDQUFELENBQVlDLEVBQVosQ0FBZSxPQUFmLEVBQXdCLFdBQXhCLEVBQXFDLFlBQVc7QUFFNUMsTUFBTUMsV0FBVyxHQUFHSCw2Q0FBQyxDQUFDLElBQUQsQ0FBRCxDQUFRSSxPQUFSLENBQWdCLGVBQWhCLENBQXBCO0FBQ0FKLCtDQUFDLENBQUMsSUFBRCxDQUFELENBQVFJLE9BQVIsQ0FBZ0IsbUJBQWhCLEVBQXFDQyxNQUFyQztBQUNBLE1BQU1DLFdBQVcsR0FBR04sNkNBQUMsQ0FBQyxJQUFELENBQUQsQ0FBUUksT0FBUixDQUFnQixtQkFBaEIsRUFBcUNHLElBQXJDLENBQTBDLGdCQUExQyxFQUE0REMsSUFBNUQsR0FBbUVDLElBQW5FLEVBQXBCO0FBQ0EsTUFBTUMsTUFBTSxHQUFHQyxJQUFJLENBQUNDLEtBQUwsQ0FBV1QsV0FBVyxDQUFDSSxJQUFaLENBQWlCLGlDQUFqQixFQUFvRE0sR0FBcEQsRUFBWCxLQUF5RSxFQUF4RjtBQUNBLE1BQUlDLFdBQVcsR0FBRyxFQUFsQjtBQUVBZCxvREFBQSxDQUFPVSxNQUFQLEVBQWUsVUFBU0ssR0FBVCxFQUFjQyxHQUFkLEVBQW1CO0FBQzlCLFFBQUksQ0FBQ0QsR0FBRyxDQUFDRSxRQUFKLENBQWFYLFdBQWIsQ0FBTCxFQUFnQztBQUM1QlEsaUJBQVcsQ0FBQ0MsR0FBRCxDQUFYLEdBQW1CQyxHQUFuQjtBQUNIO0FBQ0osR0FKRDtBQU1BYixhQUFXLENBQUNJLElBQVosQ0FBaUIsaUNBQWpCLEVBQW9ETSxHQUFwRCxDQUF3REYsSUFBSSxDQUFDTyxTQUFMLENBQWVKLFdBQWYsQ0FBeEQ7QUFDSCxDQWZEIiwiZmlsZSI6Ii4vYXBwL3BhZ2VzL3BhZ2UvdW5zZXQuanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgJCBmcm9tICdqcXVlcnknO1xuXG4kKGRvY3VtZW50KS5vbignY2xpY2snLCAnLmR6LXVuc2V0JywgZnVuY3Rpb24oKSB7XG5cbiAgICBjb25zdCBmaWxlX3VwbG9hZCA9ICQodGhpcykuY2xvc2VzdCgnLmZpbGVzLXVwbG9hZCcpO1xuICAgICQodGhpcykuY2xvc2VzdCgnLmR6LWltYWdlLXByZXZpZXcnKS5yZW1vdmUoKTtcbiAgICBjb25zdCB1bnNldF9pbWFnZSA9ICQodGhpcykuY2xvc2VzdCgnLmR6LWltYWdlLXByZXZpZXcnKS5maW5kKCdbZGF0YS1kei1uYW1lXScpLnRleHQoKS50cmltKCk7XG4gICAgY29uc3QgaW1hZ2VzID0gSlNPTi5wYXJzZShmaWxlX3VwbG9hZC5maW5kKCdpbnB1dFtkYXRhLWdyYXYtZmllbGQ9XCJoaWRkZW5cIl0nKS52YWwoKSkgfHwge307XG4gICAgbGV0IGltYWdlX2FycmF5ID0ge307XG5cbiAgICAkLmVhY2goaW1hZ2VzLCBmdW5jdGlvbihpbmQsIG9iaikge1xuICAgICAgICBpZiAoIWluZC5lbmRzV2l0aCh1bnNldF9pbWFnZSkpIHtcbiAgICAgICAgICAgIGltYWdlX2FycmF5W2luZF0gPSBvYmo7XG4gICAgICAgIH1cbiAgICB9KTtcblxuICAgIGZpbGVfdXBsb2FkLmZpbmQoJ2lucHV0W2RhdGEtZ3Jhdi1maWVsZD1cImhpZGRlblwiXScpLnZhbChKU09OLnN0cmluZ2lmeShpbWFnZV9hcnJheSkpO1xufSk7XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./app/pages/page/unset.js\n");

/***/ }),

/***/ "./app/pages/tree.js":
/*!***************************!*\
  !*** ./app/pages/tree.js ***!
  \***************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ PagesTree,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_storage__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../utils/storage */ \"./app/utils/storage.js\");\n/* harmony import */ var _utils_storage__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_utils_storage__WEBPACK_IMPORTED_MODULE_1__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\nvar sessionKey = 'grav:admin:pages';\n\nif (!sessionStorage.getItem(sessionKey)) {\n  sessionStorage.setItem(sessionKey, '{}');\n}\n\nvar PagesTree = /*#__PURE__*/function () {\n  function PagesTree(query) {\n    var _this = this;\n\n    var elements = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;\n\n    _classCallCheck(this, PagesTree);\n\n    this.query = query;\n    this.elements = jquery__WEBPACK_IMPORTED_MODULE_0___default()(elements !== undefined ? elements : this.query);\n    this.session = JSON.parse(sessionStorage.getItem(sessionKey) || '{}');\n\n    if (!this.elements.length) {\n      return;\n    }\n\n    this.restore();\n    this.elements.find('.page-icon').on('click', function (event) {\n      return _this.toggle(event.target);\n    });\n    this.elements.data('tree_init', 1);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-page-toggleall]').on('click', function (event) {\n      var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).closest('[data-page-toggleall]');\n      var action = element.data('page-toggleall');\n\n      _this[action]();\n    });\n  }\n\n  _createClass(PagesTree, [{\n    key: \"reload\",\n    value: function reload() {\n      var elements = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.query).filter(function (index, element) {\n        return !jquery__WEBPACK_IMPORTED_MODULE_0___default()(element).data('tree_init');\n      });\n\n      if (!elements.length) {\n        return;\n      }\n\n      this.constructor(this.query, elements);\n    }\n  }, {\n    key: \"toggle\",\n    value: function toggle(elements) {\n      var _this2 = this;\n\n      var dontStore = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n      if (typeof elements === 'string') {\n        elements = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-nav-id=\\\"\".concat(elements, \"\\\"]\")).find('[data-toggle=\"children\"]');\n      }\n\n      elements = jquery__WEBPACK_IMPORTED_MODULE_0___default()(elements || this.elements);\n      elements.each(function (index, element) {\n        element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n\n        var state = _this2.getState(element.closest('[data-toggle=\"children\"]'));\n\n        _this2[state.isOpen ? 'collapse' : 'expand'](state.id, dontStore);\n      });\n    }\n  }, {\n    key: \"collapse\",\n    value: function collapse(elements) {\n      var _this3 = this;\n\n      var dontStore = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n      if (typeof elements === 'string') {\n        elements = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-nav-id=\\\"\".concat(elements, \"\\\"]\")).find('[data-toggle=\"children\"]');\n      }\n\n      elements = jquery__WEBPACK_IMPORTED_MODULE_0___default()(elements || this.elements);\n      elements.each(function (index, element) {\n        element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n\n        var state = _this3.getState(element);\n\n        if (state.isOpen) {\n          state.children.hide();\n          state.icon.removeClass('children-open').addClass('children-closed');\n\n          if (!dontStore) {\n            delete _this3.session[state.id];\n          }\n        }\n      });\n\n      if (!dontStore) {\n        this.save();\n      }\n    }\n  }, {\n    key: \"expand\",\n    value: function expand(elements) {\n      var _this4 = this;\n\n      var dontStore = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n      if (typeof elements === 'string') {\n        var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-nav-id=\\\"\".concat(elements, \"\\\"]\"));\n        var parents = element.parents('[data-nav-id]'); // loop back through parents, we don't want to expand an hidden child\n\n        if (parents.length) {\n          parents = parents.find('[data-toggle=\"children\"]:first');\n          parents = parents.add(element.find('[data-toggle=\"children\"]:first'));\n          return this.expand(parents, dontStore);\n        }\n\n        elements = element.find('[data-toggle=\"children\"]:first');\n      }\n\n      elements = jquery__WEBPACK_IMPORTED_MODULE_0___default()(elements || this.elements);\n      elements.each(function (index, element) {\n        element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n\n        var state = _this4.getState(element);\n\n        if (!state.isOpen) {\n          state.children.show();\n          state.icon.removeClass('children-closed').addClass('children-open');\n\n          if (!dontStore) {\n            _this4.session[state.id] = 1;\n          }\n        }\n      });\n\n      if (!dontStore) {\n        this.save();\n      }\n    }\n  }, {\n    key: \"restore\",\n    value: function restore() {\n      var _this5 = this;\n\n      this.collapse(null, true);\n      Object.keys(this.session).forEach(function (key) {\n        _this5.expand(key, 'no-store');\n      });\n    }\n  }, {\n    key: \"save\",\n    value: function save() {\n      return sessionStorage.setItem(sessionKey, JSON.stringify(this.session));\n    }\n  }, {\n    key: \"getState\",\n    value: function getState(element) {\n      element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n      return {\n        id: element.closest('[data-nav-id]').data('nav-id'),\n        children: element.closest('li.page-item').find('ul:first'),\n        icon: element.find('.page-icon'),\n\n        get isOpen() {\n          return this.icon.hasClass('children-open');\n        }\n\n      };\n    }\n  }]);\n\n  return PagesTree;\n}();\n\n\nvar Instance = new PagesTree('[data-toggle=\"children\"]');\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 12036 characters]\n//# sourceURL=webpack-internal:///./app/pages/tree.js\n");

/***/ }),

/***/ "./app/plugins/index.js":
/*!******************************!*\
  !*** ./app/plugins/index.js ***!
  \******************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_packages__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../utils/packages */ \"./app/utils/packages.js\");\n/* harmony import */ var mout_string_camelCase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! mout/string/camelCase */ \"./node_modules/mout/string/camelCase.js\");\n/* harmony import */ var mout_string_camelCase__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(mout_string_camelCase__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var debounce__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! debounce */ \"./node_modules/debounce/index.js\");\n/* harmony import */ var debounce__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(debounce__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var mout_string_contains__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! mout/string/contains */ \"./node_modules/mout/string/contains.js\");\n/* harmony import */ var mout_string_contains__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(mout_string_contains__WEBPACK_IMPORTED_MODULE_4__);\n\n\n\n\n // Plugins sliders details\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('.gpm-name, .gpm-actions').on('click', function (e) {\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.target);\n  var tag = target.prop('tagName').toLowerCase();\n\n  if (tag === 'a' || element.parent('a').length || target.parent('a').length) {\n    return true;\n  }\n\n  var wrapper = element.siblings('.gpm-details').find('.table-wrapper');\n  wrapper.slideToggle({\n    duration: 350,\n    complete: function complete() {\n      var visible = wrapper.is(':visible');\n      wrapper.closest('tr').find('.gpm-details-expand i').removeClass('fa-chevron-' + (visible ? 'down' : 'up')).addClass('fa-chevron-' + (visible ? 'up' : 'down'));\n    }\n  });\n}); // Removing plugin\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-plugin-action=\"remove-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleRemovingPackage('plugin', event);\n}); // Reinstall plugin\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-plugin-action=\"reinstall-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleReinstallPackage('plugin', event);\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-plugin-action=\"remove-dependency-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleRemovingDependency('plugin', event);\n}); // Trigger the add new plugin / update plugin modal\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-plugin-action=\"start-package-installation\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleGettingPackageDependencies('plugin', event, 'install');\n}); // Trigger the update all plugins modal\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-plugin-action=\"start-packages-update\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleGettingPackageDependencies('plugin', event);\n}); // Install a plugin dependencies and the plugin\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-plugin-action=\"install-dependencies-and-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleInstallingDependenciesAndPackage('plugin', event);\n}); // Install a plugin\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-plugin-action=\"install-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleInstallingPackage('plugin', event);\n}); // Sort plugins/themes dropdown\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('change', '.sort-actions select', function (event) {\n  var direction = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.sort-actions .sort-icon .fa').hasClass('fa-sort-amount-desc') ? 'desc' : 'asc';\n  var sorting = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget).val();\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.Sort[mout_string_camelCase__WEBPACK_IMPORTED_MODULE_2___default()(\"by-\".concat(sorting))](direction);\n}); // Sort plugins/themes icon\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '.sort-icon', function (event) {\n  var icon = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget).find('.fa');\n  var current = icon.hasClass('fa-sort-amount-asc') ? 'asc' : 'desc';\n  var opposite = current === 'asc' ? 'desc' : 'asc';\n  icon.removeClass(\"fa-sort-amount-\".concat(current)).addClass(\"fa-sort-amount-\".concat(opposite));\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.sort-actions select').trigger('change');\n}); // Filter plugin/theme\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('input', '[data-gpm-filter]', debounce__WEBPACK_IMPORTED_MODULE_3___default()(function (event) {\n  var value = jquery__WEBPACK_IMPORTED_MODULE_0___default()(jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget)).val();\n  var items = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-gpm-plugin], [data-gpm-theme]');\n  items.hide().filter(function (index, item) {\n    item = jquery__WEBPACK_IMPORTED_MODULE_0___default()(item);\n    return mout_string_contains__WEBPACK_IMPORTED_MODULE_4___default()(item.data('gpm-plugin'), value) || mout_string_contains__WEBPACK_IMPORTED_MODULE_4___default()(item.data('gpm-theme'), value) || mout_string_contains__WEBPACK_IMPORTED_MODULE_4___default()(item.data('gpm-name').toLowerCase(), value.toLowerCase());\n  }).show();\n}, 250));//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 9764 characters]\n//# sourceURL=webpack-internal:///./app/plugins/index.js\n");

/***/ }),

/***/ "./app/themes/index.js":
/*!*****************************!*\
  !*** ./app/themes/index.js ***!
  \*****************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_packages__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../utils/packages */ \"./app/utils/packages.js\");\n\n // Themes Switcher Warning\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('mousedown', '[data-remodal-target=\"theme-switch-warn\"]', function (event) {\n  var name = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).closest('[data-gpm-theme]').find('.gpm-name a:first').text();\n  var remodal = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.remodal.theme-switcher');\n  remodal.find('strong').text(name);\n  remodal.find('.button.continue').attr('href', jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).attr('href'));\n}); // Removing theme\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-theme-action=\"remove-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleRemovingPackage('theme', event);\n}); // Reinstall theme\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-theme-action=\"reinstall-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleReinstallPackage('theme', event);\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-theme-action=\"remove-dependency-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleRemovingDependency('theme', event);\n}); // Opened the add new theme / update theme modal\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-theme-action=\"start-package-installation\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleGettingPackageDependencies('theme', event, 'install');\n}); // Trigger the update all themes modal\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-theme-action=\"start-packages-update\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleGettingPackageDependencies('theme', event);\n}); // Install a theme dependencies and the theme\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-theme-action=\"install-dependencies-and-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleInstallingDependenciesAndPackage('theme', event);\n}); // Install a theme\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-theme-action=\"install-package\"]', function (event) {\n  _utils_packages__WEBPACK_IMPORTED_MODULE_1__.default.handleInstallingPackage('theme', event);\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4608 characters]\n//# sourceURL=webpack-internal:///./app/themes/index.js\n");

/***/ }),

/***/ "./app/tools/index.js":
/*!****************************!*\
  !*** ./app/tools/index.js ***!
  \****************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _logs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./logs */ "./app/tools/logs.js");


/***/ }),

/***/ "./app/tools/logs.js":
/*!***************************!*\
  !*** ./app/tools/logs.js ***!
  \***************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var mout_queryString__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! mout/queryString */ \"./node_modules/mout/queryString.js\");\n/* harmony import */ var mout_queryString__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(mout_queryString__WEBPACK_IMPORTED_MODULE_1__);\n\n\n\nvar prepareQuery = function prepareQuery(key, value) {\n  return (0,mout_queryString__WEBPACK_IMPORTED_MODULE_1__.setParam)(__webpack_require__.g.location.href, key, value);\n};\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('change', '.logs-content .block-select select[name]', function (event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var name = target.attr('name');\n  var value = target.val();\n  __webpack_require__.g.location.href = prepareQuery(name, value);\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3Rvb2xzL2xvZ3MuanM/N2M0YyJdLCJuYW1lcyI6WyJwcmVwYXJlUXVlcnkiLCJrZXkiLCJ2YWx1ZSIsInNldFBhcmFtIiwiZ2xvYmFsIiwibG9jYXRpb24iLCJocmVmIiwiJCIsImRvY3VtZW50Iiwib24iLCJldmVudCIsInRhcmdldCIsImN1cnJlbnRUYXJnZXQiLCJuYW1lIiwiYXR0ciIsInZhbCJdLCJtYXBwaW5ncyI6Ijs7Ozs7QUFBQTtBQUNBOztBQUVBLElBQU1BLFlBQVksR0FBRyxTQUFmQSxZQUFlLENBQUNDLEdBQUQsRUFBTUMsS0FBTixFQUFnQjtBQUNqQyxTQUFPQywwREFBUSxDQUFDQyxxQkFBTSxDQUFDQyxRQUFQLENBQWdCQyxJQUFqQixFQUF1QkwsR0FBdkIsRUFBNEJDLEtBQTVCLENBQWY7QUFDSCxDQUZEOztBQUlBSyw2Q0FBQyxDQUFDQyxRQUFELENBQUQsQ0FBWUMsRUFBWixDQUFlLFFBQWYsRUFBeUIsMENBQXpCLEVBQXFFLFVBQUNDLEtBQUQsRUFBVztBQUM1RSxNQUFNQyxNQUFNLEdBQUdKLDZDQUFDLENBQUNHLEtBQUssQ0FBQ0UsYUFBUCxDQUFoQjtBQUNBLE1BQU1DLElBQUksR0FBR0YsTUFBTSxDQUFDRyxJQUFQLENBQVksTUFBWixDQUFiO0FBQ0EsTUFBTVosS0FBSyxHQUFHUyxNQUFNLENBQUNJLEdBQVAsRUFBZDtBQUVBWCx1QkFBTSxDQUFDQyxRQUFQLENBQWdCQyxJQUFoQixHQUF1Qk4sWUFBWSxDQUFDYSxJQUFELEVBQU9YLEtBQVAsQ0FBbkM7QUFDSCxDQU5EIiwiZmlsZSI6Ii4vYXBwL3Rvb2xzL2xvZ3MuanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgJCBmcm9tICdqcXVlcnknO1xuaW1wb3J0IHsgc2V0UGFyYW0gfSBmcm9tICdtb3V0L3F1ZXJ5U3RyaW5nJztcblxuY29uc3QgcHJlcGFyZVF1ZXJ5ID0gKGtleSwgdmFsdWUpID0+IHtcbiAgICByZXR1cm4gc2V0UGFyYW0oZ2xvYmFsLmxvY2F0aW9uLmhyZWYsIGtleSwgdmFsdWUpO1xufTtcblxuJChkb2N1bWVudCkub24oJ2NoYW5nZScsICcubG9ncy1jb250ZW50IC5ibG9jay1zZWxlY3Qgc2VsZWN0W25hbWVdJywgKGV2ZW50KSA9PiB7XG4gICAgY29uc3QgdGFyZ2V0ID0gJChldmVudC5jdXJyZW50VGFyZ2V0KTtcbiAgICBjb25zdCBuYW1lID0gdGFyZ2V0LmF0dHIoJ25hbWUnKTtcbiAgICBjb25zdCB2YWx1ZSA9IHRhcmdldC52YWwoKTtcblxuICAgIGdsb2JhbC5sb2NhdGlvbi5ocmVmID0gcHJlcGFyZVF1ZXJ5KG5hbWUsIHZhbHVlKTtcbn0pO1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./app/tools/logs.js\n");

/***/ }),

/***/ "./app/updates/channel-switcher.js":
/*!*****************************************!*\
  !*** ./app/updates/channel-switcher.js ***!
  \*****************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\n\n\nvar switcher = jquery__WEBPACK_IMPORTED_MODULE_0___default()('input[type=\"radio\"][name=\"channel-switch\"]');\n\nif (switcher) {\n  switcher.on('change', function (event) {\n    var radio = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n    var url = \"\".concat(radio.parent('[data-url]').data('url'));\n    (0,_utils_request__WEBPACK_IMPORTED_MODULE_1__.default)(url, {\n      method: 'post',\n      body: {\n        task: 'gpmRelease',\n        release: radio.val()\n      }\n    }, function (response) {\n      if (response.reload) {\n        __webpack_require__.g.location.reload();\n      }\n    });\n  });\n}//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3VwZGF0ZXMvY2hhbm5lbC1zd2l0Y2hlci5qcz8zOTczIl0sIm5hbWVzIjpbInN3aXRjaGVyIiwiJCIsIm9uIiwiZXZlbnQiLCJyYWRpbyIsInRhcmdldCIsInVybCIsInBhcmVudCIsImRhdGEiLCJyZXF1ZXN0IiwibWV0aG9kIiwiYm9keSIsInRhc2siLCJyZWxlYXNlIiwidmFsIiwicmVzcG9uc2UiLCJyZWxvYWQiLCJnbG9iYWwiLCJsb2NhdGlvbiJdLCJtYXBwaW5ncyI6Ijs7OztBQUFBO0FBQ0E7QUFFQSxJQUFNQSxRQUFRLEdBQUdDLDZDQUFDLENBQUMsNENBQUQsQ0FBbEI7O0FBRUEsSUFBSUQsUUFBSixFQUFjO0FBQ1ZBLFVBQVEsQ0FBQ0UsRUFBVCxDQUFZLFFBQVosRUFBc0IsVUFBQ0MsS0FBRCxFQUFXO0FBQzdCLFFBQUlDLEtBQUssR0FBR0gsNkNBQUMsQ0FBQ0UsS0FBSyxDQUFDRSxNQUFQLENBQWI7QUFDQSxRQUFJQyxHQUFHLGFBQU1GLEtBQUssQ0FBQ0csTUFBTixDQUFhLFlBQWIsRUFBMkJDLElBQTNCLENBQWdDLEtBQWhDLENBQU4sQ0FBUDtBQUVBQywyREFBTyxDQUFDSCxHQUFELEVBQU07QUFDVEksWUFBTSxFQUFFLE1BREM7QUFFVEMsVUFBSSxFQUFFO0FBQ0ZDLFlBQUksRUFBRSxZQURKO0FBRUZDLGVBQU8sRUFBRVQsS0FBSyxDQUFDVSxHQUFOO0FBRlA7QUFGRyxLQUFOLEVBT1AsVUFBQ0MsUUFBRCxFQUFjO0FBQ1YsVUFBSUEsUUFBUSxDQUFDQyxNQUFiLEVBQXFCO0FBQ2pCQyw2QkFBTSxDQUFDQyxRQUFQLENBQWdCRixNQUFoQjtBQUNIO0FBQ0osS0FYTSxDQUFQO0FBWUgsR0FoQkQ7QUFpQkgiLCJmaWxlIjoiLi9hcHAvdXBkYXRlcy9jaGFubmVsLXN3aXRjaGVyLmpzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0ICQgZnJvbSAnanF1ZXJ5JztcbmltcG9ydCByZXF1ZXN0IGZyb20gJy4uL3V0aWxzL3JlcXVlc3QnO1xuXG5jb25zdCBzd2l0Y2hlciA9ICQoJ2lucHV0W3R5cGU9XCJyYWRpb1wiXVtuYW1lPVwiY2hhbm5lbC1zd2l0Y2hcIl0nKTtcblxuaWYgKHN3aXRjaGVyKSB7XG4gICAgc3dpdGNoZXIub24oJ2NoYW5nZScsIChldmVudCkgPT4ge1xuICAgICAgICBsZXQgcmFkaW8gPSAkKGV2ZW50LnRhcmdldCk7XG4gICAgICAgIGxldCB1cmwgPSBgJHtyYWRpby5wYXJlbnQoJ1tkYXRhLXVybF0nKS5kYXRhKCd1cmwnKX1gO1xuXG4gICAgICAgIHJlcXVlc3QodXJsLCB7XG4gICAgICAgICAgICBtZXRob2Q6ICdwb3N0JyxcbiAgICAgICAgICAgIGJvZHk6IHtcbiAgICAgICAgICAgICAgICB0YXNrOiAnZ3BtUmVsZWFzZScsXG4gICAgICAgICAgICAgICAgcmVsZWFzZTogcmFkaW8udmFsKClcbiAgICAgICAgICAgIH1cbiAgICAgICAgfSxcbiAgICAgICAgKHJlc3BvbnNlKSA9PiB7XG4gICAgICAgICAgICBpZiAocmVzcG9uc2UucmVsb2FkKSB7XG4gICAgICAgICAgICAgICAgZ2xvYmFsLmxvY2F0aW9uLnJlbG9hZCgpO1xuICAgICAgICAgICAgfVxuICAgICAgICB9KTtcbiAgICB9KTtcbn1cbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/updates/channel-switcher.js\n");

/***/ }),

/***/ "./app/updates/check.js":
/*!******************************!*\
  !*** ./app/updates/check.js ***!
  \******************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_gpm__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../utils/gpm */ \"./app/utils/gpm.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _utils_toastr__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../utils/toastr */ \"./app/utils/toastr.js\");\n\n\n\n // Check for updates trigger\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-gpm-checkupdates]').on('click', function () {\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n  element.find('i').addClass('fa-spin');\n  _utils_gpm__WEBPACK_IMPORTED_MODULE_1__.Instance.fetch(function (response) {\n    element.find('i').removeClass('fa-spin');\n    var payload = response.payload;\n\n    if (!payload) {\n      return;\n    }\n\n    if (!payload.grav.isUpdatable && !payload.resources.total) {\n      _utils_toastr__WEBPACK_IMPORTED_MODULE_3__.default.success(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.EVERYTHING_UP_TO_DATE);\n    } else {\n      var grav = payload.grav.isUpdatable ? 'Grav v' + payload.grav.available : '';\n      var resources = payload.resources.total ? payload.resources.total + ' ' + grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.UPDATES_ARE_AVAILABLE : '';\n\n      if (!resources) {\n        grav += ' ' + grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.IS_AVAILABLE_FOR_UPDATE;\n      }\n\n      _utils_toastr__WEBPACK_IMPORTED_MODULE_3__.default.info(grav + (grav && resources ? ' ' + grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.AND + ' ' : '') + resources);\n    }\n  }, true);\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3VwZGF0ZXMvY2hlY2suanM/MzQwOSJdLCJuYW1lcyI6WyIkIiwib24iLCJlbGVtZW50IiwiZmluZCIsImFkZENsYXNzIiwiZ3BtIiwicmVzcG9uc2UiLCJyZW1vdmVDbGFzcyIsInBheWxvYWQiLCJncmF2IiwiaXNVcGRhdGFibGUiLCJyZXNvdXJjZXMiLCJ0b3RhbCIsInRvYXN0ciIsInRyYW5zbGF0aW9ucyIsImF2YWlsYWJsZSJdLCJtYXBwaW5ncyI6Ijs7Ozs7OztBQUFBO0FBQ0E7QUFDQTtDQUdBOztBQUNBQSw2Q0FBQyxDQUFDLHlCQUFELENBQUQsQ0FBNkJDLEVBQTdCLENBQWdDLE9BQWhDLEVBQXlDLFlBQVc7QUFDaEQsTUFBSUMsT0FBTyxHQUFHRiw2Q0FBQyxDQUFDLElBQUQsQ0FBZjtBQUNBRSxTQUFPLENBQUNDLElBQVIsQ0FBYSxHQUFiLEVBQWtCQyxRQUFsQixDQUEyQixTQUEzQjtBQUVBQyx3REFBQSxDQUFVLFVBQUNDLFFBQUQsRUFBYztBQUNwQkosV0FBTyxDQUFDQyxJQUFSLENBQWEsR0FBYixFQUFrQkksV0FBbEIsQ0FBOEIsU0FBOUI7QUFDQSxRQUFJQyxPQUFPLEdBQUdGLFFBQVEsQ0FBQ0UsT0FBdkI7O0FBRUEsUUFBSSxDQUFDQSxPQUFMLEVBQWM7QUFBRTtBQUFTOztBQUN6QixRQUFJLENBQUNBLE9BQU8sQ0FBQ0MsSUFBUixDQUFhQyxXQUFkLElBQTZCLENBQUNGLE9BQU8sQ0FBQ0csU0FBUixDQUFrQkMsS0FBcEQsRUFBMkQ7QUFDdkRDLGdFQUFBLENBQWVDLHdGQUFmO0FBQ0gsS0FGRCxNQUVPO0FBQ0gsVUFBSUwsSUFBSSxHQUFHRCxPQUFPLENBQUNDLElBQVIsQ0FBYUMsV0FBYixHQUEyQixXQUFXRixPQUFPLENBQUNDLElBQVIsQ0FBYU0sU0FBbkQsR0FBK0QsRUFBMUU7QUFDQSxVQUFJSixTQUFTLEdBQUdILE9BQU8sQ0FBQ0csU0FBUixDQUFrQkMsS0FBbEIsR0FBMEJKLE9BQU8sQ0FBQ0csU0FBUixDQUFrQkMsS0FBbEIsR0FBMEIsR0FBMUIsR0FBZ0NFLHdGQUExRCxHQUE0RyxFQUE1SDs7QUFFQSxVQUFJLENBQUNILFNBQUwsRUFBZ0I7QUFBRUYsWUFBSSxJQUFJLE1BQU1LLDBGQUFkO0FBQWtFOztBQUNwRkQsNkRBQUEsQ0FBWUosSUFBSSxJQUFJQSxJQUFJLElBQUlFLFNBQVIsR0FBb0IsTUFBTUcsc0VBQU4sR0FBc0MsR0FBMUQsR0FBZ0UsRUFBcEUsQ0FBSixHQUE4RUgsU0FBMUY7QUFDSDtBQUNKLEdBZEQsRUFjRyxJQWRIO0FBZUgsQ0FuQkQiLCJmaWxlIjoiLi9hcHAvdXBkYXRlcy9jaGVjay5qcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCAkIGZyb20gJ2pxdWVyeSc7XG5pbXBvcnQgeyBJbnN0YW5jZSBhcyBncG0gfSBmcm9tICcuLi91dGlscy9ncG0nO1xuaW1wb3J0IHsgdHJhbnNsYXRpb25zIH0gZnJvbSAnZ3Jhdi1jb25maWcnO1xuaW1wb3J0IHRvYXN0ciBmcm9tICcuLi91dGlscy90b2FzdHInO1xuXG4vLyBDaGVjayBmb3IgdXBkYXRlcyB0cmlnZ2VyXG4kKCdbZGF0YS1ncG0tY2hlY2t1cGRhdGVzXScpLm9uKCdjbGljaycsIGZ1bmN0aW9uKCkge1xuICAgIGxldCBlbGVtZW50ID0gJCh0aGlzKTtcbiAgICBlbGVtZW50LmZpbmQoJ2knKS5hZGRDbGFzcygnZmEtc3BpbicpO1xuXG4gICAgZ3BtLmZldGNoKChyZXNwb25zZSkgPT4ge1xuICAgICAgICBlbGVtZW50LmZpbmQoJ2knKS5yZW1vdmVDbGFzcygnZmEtc3BpbicpO1xuICAgICAgICBsZXQgcGF5bG9hZCA9IHJlc3BvbnNlLnBheWxvYWQ7XG5cbiAgICAgICAgaWYgKCFwYXlsb2FkKSB7IHJldHVybjsgfVxuICAgICAgICBpZiAoIXBheWxvYWQuZ3Jhdi5pc1VwZGF0YWJsZSAmJiAhcGF5bG9hZC5yZXNvdXJjZXMudG90YWwpIHtcbiAgICAgICAgICAgIHRvYXN0ci5zdWNjZXNzKHRyYW5zbGF0aW9ucy5QTFVHSU5fQURNSU4uRVZFUllUSElOR19VUF9UT19EQVRFKTtcbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIHZhciBncmF2ID0gcGF5bG9hZC5ncmF2LmlzVXBkYXRhYmxlID8gJ0dyYXYgdicgKyBwYXlsb2FkLmdyYXYuYXZhaWxhYmxlIDogJyc7XG4gICAgICAgICAgICB2YXIgcmVzb3VyY2VzID0gcGF5bG9hZC5yZXNvdXJjZXMudG90YWwgPyBwYXlsb2FkLnJlc291cmNlcy50b3RhbCArICcgJyArIHRyYW5zbGF0aW9ucy5QTFVHSU5fQURNSU4uVVBEQVRFU19BUkVfQVZBSUxBQkxFIDogJyc7XG5cbiAgICAgICAgICAgIGlmICghcmVzb3VyY2VzKSB7IGdyYXYgKz0gJyAnICsgdHJhbnNsYXRpb25zLlBMVUdJTl9BRE1JTi5JU19BVkFJTEFCTEVfRk9SX1VQREFURTsgfVxuICAgICAgICAgICAgdG9hc3RyLmluZm8oZ3JhdiArIChncmF2ICYmIHJlc291cmNlcyA/ICcgJyArIHRyYW5zbGF0aW9ucy5QTFVHSU5fQURNSU4uQU5EICsgJyAnIDogJycpICsgcmVzb3VyY2VzKTtcbiAgICAgICAgfVxuICAgIH0sIHRydWUpO1xufSk7XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./app/updates/check.js\n");

/***/ }),

/***/ "./app/updates/feed.js":
/*!*****************************!*\
  !*** ./app/updates/feed.js ***!
  \*****************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\nvar URI = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/ajax.json/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"getNewsFeed\");\n\nvar Feed = /*#__PURE__*/function () {\n  function Feed() {\n    _classCallCheck(this, Feed);\n\n    this.data = null;\n  }\n\n  _createClass(Feed, [{\n    key: \"fetch\",\n    value: function fetch() {\n      var _this = this;\n\n      var refresh = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n      var callback = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(URI, {\n        method: 'post',\n        body: {\n          refresh: refresh\n        }\n      }, function (response) {\n        _this.data = response;\n        callback(response);\n      });\n    }\n  }, {\n    key: \"refresh\",\n    value: function refresh() {\n      var _refresh = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n\n      var feed = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#news-feed .widget-content');\n\n      if (!feed.length) {\n        return;\n      }\n\n      var loader = feed.find('.widget-loader');\n      loader.find('div').remove();\n      loader.find('.fa-warning').removeClass('fa-warning').addClass('fa-refresh fa-spin');\n      loader.show();\n      feed.find('> ul').hide();\n\n      if (!this.data || this.data.error || _refresh) {\n        this.fetch(_refresh, this.updateContent.bind(this));\n      } else {\n        this.updateContent();\n      }\n    }\n  }, {\n    key: \"updateContent\",\n    value: function updateContent() {\n      var feed = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#news-feed .widget-content');\n\n      if (!feed.length) {\n        return;\n      }\n\n      var loader = feed.find('.widget-loader').hide();\n      var content = feed.find('> ul').empty().show();\n\n      if (this.data.error || this.data.status === 'error') {\n        loader.show().find('div').remove();\n        loader.find('.fa-refresh').removeClass('fa-refresh fa-spin').addClass('fa-warning');\n        loader.append(\"<div>\".concat(this.data.error ? this.data.error.message : this.data.message || 'Unable to download news feed', \"</div>\"));\n        return;\n      }\n\n      if (this.data && this.data.feed_data) {\n        content.append(this.data.feed_data);\n      }\n    }\n  }]);\n\n  return Feed;\n}();\n\nvar feed = new Feed();\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).ready(function () {\n  return feed.refresh();\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-refresh=\"feed\"]', function (event) {\n  event.preventDefault();\n  feed.refresh(true);\n});\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (feed);//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 6112 characters]\n//# sourceURL=webpack-internal:///./app/updates/feed.js\n");

/***/ }),

/***/ "./app/updates/index.js":
/*!******************************!*\
  !*** ./app/updates/index.js ***!
  \******************************/
/*! namespace exports */
/*! export Feed [provided] [no usage info] [missing usage info prevents renaming] -> ./app/updates/feed.js .default */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export Notifications [provided] [no usage info] [missing usage info prevents renaming] -> ./app/updates/notifications.js .default */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.d, __webpack_require__.r, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ Updates,\n/* harmony export */   \"Instance\": () => /* binding */ Instance,\n/* harmony export */   \"Notifications\": () => /* reexport safe */ _notifications__WEBPACK_IMPORTED_MODULE_4__.default,\n/* harmony export */   \"Feed\": () => /* reexport safe */ _feed__WEBPACK_IMPORTED_MODULE_5__.default\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var mout_array_unique__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! mout/array/unique */ \"./node_modules/mout/array/unique.js\");\n/* harmony import */ var mout_array_unique__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(mout_array_unique__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _utils_gpm__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../utils/gpm */ \"./app/utils/gpm.js\");\n/* harmony import */ var _notifications__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./notifications */ \"./app/updates/notifications.js\");\n/* harmony import */ var _feed__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./feed */ \"./app/updates/feed.js\");\n/* harmony import */ var _check__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./check */ \"./app/updates/check.js\");\n/* harmony import */ var _update__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./update */ \"./app/updates/update.js\");\n/* harmony import */ var _channel_switcher__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./channel-switcher */ \"./app/updates/channel-switcher.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\n\n\n\n\n\n\nvar Updates = /*#__PURE__*/function () {\n  function Updates() {\n    var payload = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n\n    _classCallCheck(this, Updates);\n\n    this.setPayload(payload);\n    this.task = \"task\".concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.config.param_sep);\n    this.updateURL = '';\n  }\n\n  _createClass(Updates, [{\n    key: \"setPayload\",\n    value: function setPayload() {\n      var payload = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n      this.payload = payload;\n      return this;\n    }\n  }, {\n    key: \"fetch\",\n    value: function fetch() {\n      var _this = this;\n\n      var force = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n      _utils_gpm__WEBPACK_IMPORTED_MODULE_3__.Instance.fetch(function (response) {\n        return _this.setPayload(response);\n      }, force);\n      return this;\n    }\n  }, {\n    key: \"maintenance\",\n    value: function maintenance() {\n      var mode = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'hide';\n      var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#updates [data-update-packages]');\n      element[mode === 'show' ? 'fadeIn' : 'fadeOut']();\n\n      if (mode === 'hide') {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('.badges.with-updates').removeClass('with-updates').find('.badge.updates').remove();\n      }\n\n      return this;\n    }\n  }, {\n    key: \"grav\",\n    value: function grav() {\n      var payload = this.payload.grav;\n\n      if (payload && payload.isUpdatable) {\n        var task = this.task;\n        var bar = '';\n\n        if (!payload.isSymlink) {\n          this.updateURL = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.config.base_url_relative, \"/update.json/\").concat(task, \"updategrav/admin-nonce\").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.config.param_sep).concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.config.admin_nonce);\n          bar += \"<button data-remodal-target=\\\"update-grav\\\" class=\\\"button button-small secondary pointer-events-none\\\" id=\\\"grav-update-button\\\">\".concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.UPDATE_GRAV_NOW, \" <span class=\\\"cnt-down\\\">(5s)</span></button>\");\n        } else {\n          bar += \"<span class=\\\"hint--left\\\" style=\\\"float: right;\\\" data-hint=\\\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.GRAV_SYMBOLICALLY_LINKED, \"\\\"><i class=\\\"fa fa-fw fa-link\\\"></i></span>\");\n        }\n\n        bar += \"\\n                Grav <b>v\".concat(payload.available, \"</b> \").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.IS_NOW_AVAILABLE, \"! <span class=\\\"less\\\">(\").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.CURRENT, \" v\").concat(payload.version, \")</span>\\n            \");\n        var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-gpm-grav]').removeClass('hidden');\n\n        if (element.is(':empty')) {\n          element.hide();\n        }\n\n        element.addClass('grav').html(\"\".concat(bar)).slideDown(150, function () {\n          var c = 5;\n          var x = setInterval(function () {\n            c -= 1;\n            element.find('.pointer-events-none .cnt-down').text('(' + c + 's)');\n          }, 1000);\n          setTimeout(function () {\n            clearInterval(x);\n            element.find('.pointer-events-none .cnt-down').remove();\n            element.find('.pointer-events-none').removeClass('pointer-events-none');\n          }, 5000);\n        }).parent('#messages').addClass('default-box-shadow');\n      }\n\n      return this;\n    }\n  }, {\n    key: \"resources\",\n    value: function resources() {\n      if (!this.payload || !this.payload.resources || !this.payload.resources.total) {\n        return this.maintenance('hide');\n      }\n\n      var is_current_package_latest = true;\n      var map = ['plugins', 'themes'];\n      var singles = ['plugin', 'theme'];\n      var _this$payload$resourc = this.payload.resources,\n          plugins = _this$payload$resourc.plugins,\n          themes = _this$payload$resourc.themes;\n\n      if (!this.payload.resources.total) {\n        return this;\n      }\n\n      [plugins, themes].forEach(function (resources, index) {\n        if (!resources || Array.isArray(resources)) {\n          return;\n        }\n\n        var length = Object.keys(resources).length;\n        var type = map[index]; // sidebar\n\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"#admin-menu a[href$=\\\"/\".concat(map[index], \"\\\"]\")).find('.badges').addClass('with-updates').find('.badge.updates').text(length);\n        var type_translation = ''; // update all\n\n        if (type === 'plugins') {\n          type_translation = grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.PLUGINS;\n        } else {\n          type_translation = grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.THEMES;\n        }\n\n        var updateAll = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\".grav-update.\".concat(type));\n        updateAll.css('display', 'block').html(\"\\n            <p>\\n                <a href=\\\"#\\\" class=\\\"button button-small secondary\\\" data-remodal-target=\\\"update-packages\\\" data-packages-slugs=\\\"\".concat(Object.keys(resources).join(), \"\\\" data-\").concat(singles[index], \"-action=\\\"start-packages-update\\\">\").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.UPDATE, \" \").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.ALL, \" \").concat(type_translation, \"</a>\\n                <i class=\\\"fa fa-bullhorn\\\"></i>\\n                \").concat(length, \" \").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.OF_YOUR, \" \").concat(type_translation.toLowerCase(), \" \").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.HAVE_AN_UPDATE_AVAILABLE, \"\\n            </p>\\n            \"));\n        var existing_slugs = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-update-packages]').attr('data-packages-slugs') || '';\n\n        if (existing_slugs) {\n          existing_slugs = existing_slugs.split(',');\n        } else {\n          existing_slugs = [];\n        }\n\n        var slugs = mout_array_unique__WEBPACK_IMPORTED_MODULE_1___default()(existing_slugs.concat(Object.keys(resources))).join();\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-update-packages]').attr('data-packages-slugs', \"\".concat(slugs));\n        Object.keys(resources).forEach(function (item) {\n          // listing page\n          var container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-gpm-\".concat(singles[index], \"=\\\"\").concat(item, \"\\\"]\"));\n          var element = container.find('.gpm-name');\n          var url = element.find('a');\n          var content_wrapper = container.parents('.content-wrapper');\n\n          if (type === 'plugins' && !element.find('.badge.update').length) {\n            element.append(\"<a class=\\\"plugin-update-button\\\" href=\\\"\".concat(url.attr('href'), \"\\\"><span class=\\\"badge update\\\">\").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.UPDATE_AVAILABLE, \"!</span></a>\"));\n            content_wrapper.addClass('has-updates');\n          } else if (type === 'themes') {\n            element.append(\"<div class=\\\"gpm-ribbon\\\"><a href=\\\"\".concat(url.attr('href'), \"\\\">\").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.UPDATE.toUpperCase(), \"</a></div>\"));\n            content_wrapper.addClass('has-updates');\n          } // details page\n\n\n          if (container.length) {\n            var details = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\".grav-update.\".concat(singles[index]));\n\n            if (details.length) {\n              var releaseType = resources[item].type === 'testing' ? '<span class=\"gpm-testing\">test release</span>' : '';\n              details.html(\"\\n                            <p>\\n                                <a href=\\\"#\\\" class=\\\"button button-small secondary\\\" data-remodal-target=\\\"update-packages\\\" data-packages-slugs=\\\"\".concat(item, \"\\\" data-\").concat(singles[index], \"-action=\\\"start-package-installation\\\">\").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.UPDATE, \" \").concat(singles[index].charAt(0).toUpperCase() + singles[index].substr(1).toLowerCase(), \"</a>\\n                                <i class=\\\"fa fa-bullhorn\\\"></i>\\n                                <strong>v\").concat(resources[item].available, \"</strong> \").concat(releaseType, \" \").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.OF_THIS, \" \").concat(singles[index], \" \").concat(grav_config__WEBPACK_IMPORTED_MODULE_2__.translations.PLUGIN_ADMIN.IS_NOW_AVAILABLE, \"!\\n                            </p>\\n                        \")).css('display', 'block');\n              is_current_package_latest = false;\n            }\n          }\n        });\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-update-packages]').removeClass('hidden');\n      });\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.content-wrapper').addClass('updates-checked');\n\n      if (!is_current_package_latest) {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('.warning-reinstall-not-latest-release').removeClass('hidden');\n      }\n    }\n  }]);\n\n  return Updates;\n}();\n\n\nvar Instance = new Updates();\n // automatically refresh UI for updates (graph, sidebar, plugin/themes pages) after every fetch\n\n_utils_gpm__WEBPACK_IMPORTED_MODULE_3__.Instance.on('fetched', function (response, raw) {\n  Instance.setPayload(response.payload || {});\n  Instance.grav().resources();\n});\n\nif (grav_config__WEBPACK_IMPORTED_MODULE_2__.config.enable_auto_updates_check === '1') {\n  _utils_gpm__WEBPACK_IMPORTED_MODULE_3__.Instance.fetch();\n}//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 19564 characters]\n//# sourceURL=webpack-internal:///./app/updates/index.js\n");

/***/ }),

/***/ "./app/updates/notifications.js":
/*!**************************************!*\
  !*** ./app/updates/notifications.js ***!
  \**************************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\nvar canFetchNotifications = function canFetchNotifications() {\n  return grav_config__WEBPACK_IMPORTED_MODULE_1__.config.notifications.enabled;\n};\n\nvar notificationsFilters = function notificationsFilters() {\n  return grav_config__WEBPACK_IMPORTED_MODULE_1__.config.notifications.filters;\n};\n\nvar Notifications = /*#__PURE__*/function () {\n  function Notifications() {\n    _classCallCheck(this, Notifications);\n  }\n\n  _createClass(Notifications, [{\n    key: \"fetch\",\n    // Grav.default.Notifications.fetch()\n    value: function fetch() {\n      var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},\n          _ref$filter = _ref.filter,\n          filter = _ref$filter === void 0 ? notificationsFilters() : _ref$filter,\n          _ref$refresh = _ref.refresh,\n          refresh = _ref$refresh === void 0 ? false : _ref$refresh;\n\n      if (!canFetchNotifications()) {\n        return false;\n      }\n\n      var feed = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#notifications');\n      var loader = feed.find('.widget-loader');\n      var content = feed.find('.widget-content > ul');\n      loader.find('div').remove();\n      loader.find('.fa-warning').removeClass('fa-warning').addClass('fa-refresh fa-spin');\n      loader.show();\n      content.hide();\n\n      var processNotifications = function processNotifications(response) {\n        var notifications = response.notifications;\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('#notifications').find('.widget-content > ul').empty();\n\n        if (notifications) {\n          Object.keys(notifications).forEach(function (location) {\n            return Notifications.processLocation(location, notifications[location]);\n          });\n        }\n      };\n\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"getNotifications\"), {\n        method: 'post',\n        body: {\n          refresh: refresh,\n          filter: filter\n        }\n      }, function (response) {\n        processNotifications(response);\n      })[\"catch\"](function () {\n        var widget = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#notifications .widget-content');\n        widget.find('.widget-loader').find('div').remove();\n        widget.find('.widget-loader').append('<div>Failed to retrieve notifications</div>').find('.fa-spin').removeClass('fa-spin fa-refresh').addClass('fa-warning');\n      });\n    }\n  }], [{\n    key: \"addShowAllInFeed\",\n    value: function addShowAllInFeed() {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('#notifications ul').append('<li class=\"show-all\" data-notification-action=\"show-all-notifications\">Show all</li>');\n    }\n  }, {\n    key: \"showNotificationInFeed\",\n    value: function showNotificationInFeed(notification) {\n      var notifications = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#notifications').removeClass('hidden');\n      var loader = notifications.find('.widget-loader').hide();\n      var content = notifications.find('.widget-content > ul').show();\n      loader.find('div').remove();\n      loader.find('.fa-warning').removeClass('fa-warning').addClass('fa-refresh fa-spin');\n      content.append(notification).find('li:nth-child(n+11)').addClass('hidden'); // hide all items > 10\n\n      if (content.find('li.hidden').length) {\n        Notifications.addShowAllInFeed();\n      }\n    }\n  }, {\n    key: \"showNotificationInTop\",\n    value: function showNotificationInTop(notification) {\n      var container = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.top-notifications-container');\n      var dummy = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div />').html(notification);\n      container.removeClass('hidden').append(dummy.children());\n      dummy.children().slideDown(150);\n    }\n  }, {\n    key: \"showNotificationInDashboard\",\n    value: function showNotificationInDashboard(notification) {\n      var container = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.dashboard-notifications-container');\n      var dummy = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div />').html(notification);\n      container.removeClass('hidden').append(dummy.children());\n      dummy.children().slideDown(150);\n    }\n  }, {\n    key: \"showNotificationInPlugins\",\n    value: function showNotificationInPlugins(notification) {\n      var container = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.plugins-notifications-container');\n      var dummy = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div />').html(notification);\n      container.removeClass('hidden').append(dummy.children());\n      dummy.children().slideDown(150);\n    }\n  }, {\n    key: \"showNotificationInThemes\",\n    value: function showNotificationInThemes(notification) {\n      var container = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.themes-notifications-container');\n      var dummy = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div />').html(notification);\n      container.removeClass('hidden').append(dummy.children());\n      dummy.children().slideDown(150);\n    }\n  }, {\n    key: \"processLocation\",\n    value: function processLocation(location, notification) {\n      switch (location) {\n        case 'feed':\n          Notifications.showNotificationInFeed(notification);\n          break;\n\n        case 'top':\n          if (!notification.read) {\n            Notifications.showNotificationInTop(notification);\n          }\n\n          break;\n\n        case 'dashboard':\n          if (!notification.read) {\n            Notifications.showNotificationInDashboard(notification);\n          }\n\n          break;\n\n        case 'plugins':\n          if (!notification.read) {\n            Notifications.showNotificationInPlugins(notification);\n          }\n\n          break;\n\n        case 'themes':\n          if (!notification.read) {\n            Notifications.showNotificationInThemes(notification);\n          }\n\n          break;\n      }\n    }\n  }]);\n\n  return Notifications;\n}();\n\nvar notifications = new Notifications();\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (notifications);\n\nif (canFetchNotifications()) {\n  notifications.fetch();\n  /* Hide a notification and store it hidden\n  // <a href=\"#\" data-notification-action=\"hide-notification\" data-notification-id=\"${notification.id}\" class=\"close hide-notification\"><i class=\"fa fa-close\"></i></a>\n  $(document).on('click', '[data-notification-action=\"hide-notification\"]', (event) => {\n      let notification_id = $(event.target).parents('.hide-notification').data('notification-id');\n       let url = `${config.base_url_relative}/notifications.json/task${config.param_sep}hideNotification/notification_id${config.param_sep}${notification_id}`;\n       request(url, { method: 'post' }, () => {});\n       $(event.target).parents('.single-notification').hide();\n  });\n  */\n\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-notification-action=\"hide-notification\"]', function (event) {\n    var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n    var notification = target.parent();\n    notification.slideUp(function () {\n      return notification.remove();\n    });\n  });\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-notification-action=\"show-all-notifications\"]', function (event) {\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('#notifications .show-all').hide();\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('#notifications .hidden').removeClass('hidden');\n  });\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-refresh=\"notifications\"]', function (event) {\n    event.preventDefault();\n    notifications.fetch({\n      filter: ['feed'],\n      refresh: true\n    });\n  });\n}//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 15788 characters]\n//# sourceURL=webpack-internal:///./app/updates/notifications.js\n");

/***/ }),

/***/ "./app/updates/update.js":
/*!*******************************!*\
  !*** ./app/updates/update.js ***!
  \*******************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_formatbytes__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/formatbytes */ \"./app/utils/formatbytes.js\");\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\n/* harmony import */ var _index__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./index */ \"./app/updates/index.js\");\n\n\n\n\n // Dashboard update and Grav update\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click.remodal', '[data-remodal-id=\"update-grav\"] [data-remodal-action=\"confirm\"]', function () {\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#grav-update-button');\n  element.html(\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.UPDATING_PLEASE_WAIT, \" \").concat((0,_utils_formatbytes__WEBPACK_IMPORTED_MODULE_2__.default)(_index__WEBPACK_IMPORTED_MODULE_4__.Instance.payload.grav.assets[\"grav-update\"].size), \"..\"));\n  element.attr('disabled', 'disabled').find('> .fa').removeClass('fa-cloud-download').addClass('fa-refresh fa-spin');\n  (0,_utils_request__WEBPACK_IMPORTED_MODULE_3__.default)(_index__WEBPACK_IMPORTED_MODULE_4__.Instance.updateURL, function (response) {\n    if (response.type === 'updategrav') {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-gpm-grav]').remove();\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('#footer .grav-version').html(response.version);\n    }\n\n    element.removeAttr('disabled').find('> .fa').removeClass('fa-refresh fa-spin').addClass('fa-cloud-download');\n  });\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3VwZGF0ZXMvdXBkYXRlLmpzPzQ3NjkiXSwibmFtZXMiOlsiJCIsImRvY3VtZW50Iiwib24iLCJlbGVtZW50IiwiaHRtbCIsInRyYW5zbGF0aW9ucyIsImZvcm1hdEJ5dGVzIiwiVXBkYXRlIiwiYXR0ciIsImZpbmQiLCJyZW1vdmVDbGFzcyIsImFkZENsYXNzIiwicmVxdWVzdCIsInJlc3BvbnNlIiwidHlwZSIsInJlbW92ZSIsInZlcnNpb24iLCJyZW1vdmVBdHRyIl0sIm1hcHBpbmdzIjoiOzs7Ozs7OztBQUFBO0FBQ0E7QUFDQTtBQUNBO0NBR0E7O0FBQ0FBLDZDQUFDLENBQUNDLFFBQUQsQ0FBRCxDQUFZQyxFQUFaLENBQWUsZUFBZixFQUFnQyxpRUFBaEMsRUFBbUcsWUFBTTtBQUNyRyxNQUFNQyxPQUFPLEdBQUdILDZDQUFDLENBQUMscUJBQUQsQ0FBakI7QUFDQUcsU0FBTyxDQUFDQyxJQUFSLFdBQWdCQyx1RkFBaEIsY0FBa0VDLDJEQUFXLENBQUNDLG9GQUFELENBQTdFO0FBRUFKLFNBQU8sQ0FBQ0ssSUFBUixDQUFhLFVBQWIsRUFBeUIsVUFBekIsRUFBcUNDLElBQXJDLENBQTBDLE9BQTFDLEVBQW1EQyxXQUFuRCxDQUErRCxtQkFBL0QsRUFBb0ZDLFFBQXBGLENBQTZGLG9CQUE3RjtBQUVBQyx5REFBTyxDQUFDTCxzREFBRCxFQUFtQixVQUFDTSxRQUFELEVBQWM7QUFDcEMsUUFBSUEsUUFBUSxDQUFDQyxJQUFULEtBQWtCLFlBQXRCLEVBQW9DO0FBQ2hDZCxtREFBQyxDQUFDLGlCQUFELENBQUQsQ0FBcUJlLE1BQXJCO0FBQ0FmLG1EQUFDLENBQUMsdUJBQUQsQ0FBRCxDQUEyQkksSUFBM0IsQ0FBZ0NTLFFBQVEsQ0FBQ0csT0FBekM7QUFDSDs7QUFFRGIsV0FBTyxDQUFDYyxVQUFSLENBQW1CLFVBQW5CLEVBQStCUixJQUEvQixDQUFvQyxPQUFwQyxFQUE2Q0MsV0FBN0MsQ0FBeUQsb0JBQXpELEVBQStFQyxRQUEvRSxDQUF3RixtQkFBeEY7QUFDSCxHQVBNLENBQVA7QUFRSCxDQWREIiwiZmlsZSI6Ii4vYXBwL3VwZGF0ZXMvdXBkYXRlLmpzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0ICQgZnJvbSAnanF1ZXJ5JztcbmltcG9ydCB7IHRyYW5zbGF0aW9ucyB9IGZyb20gJ2dyYXYtY29uZmlnJztcbmltcG9ydCBmb3JtYXRCeXRlcyBmcm9tICcuLi91dGlscy9mb3JtYXRieXRlcyc7XG5pbXBvcnQgcmVxdWVzdCBmcm9tICcuLi91dGlscy9yZXF1ZXN0JztcbmltcG9ydCB7IEluc3RhbmNlIGFzIFVwZGF0ZSB9IGZyb20gJy4vaW5kZXgnO1xuXG4vLyBEYXNoYm9hcmQgdXBkYXRlIGFuZCBHcmF2IHVwZGF0ZVxuJChkb2N1bWVudCkub24oJ2NsaWNrLnJlbW9kYWwnLCAnW2RhdGEtcmVtb2RhbC1pZD1cInVwZGF0ZS1ncmF2XCJdIFtkYXRhLXJlbW9kYWwtYWN0aW9uPVwiY29uZmlybVwiXScsICgpID0+IHtcbiAgICBjb25zdCBlbGVtZW50ID0gJCgnI2dyYXYtdXBkYXRlLWJ1dHRvbicpO1xuICAgIGVsZW1lbnQuaHRtbChgJHt0cmFuc2xhdGlvbnMuUExVR0lOX0FETUlOLlVQREFUSU5HX1BMRUFTRV9XQUlUfSAke2Zvcm1hdEJ5dGVzKFVwZGF0ZS5wYXlsb2FkLmdyYXYuYXNzZXRzWydncmF2LXVwZGF0ZSddLnNpemUpfS4uYCk7XG5cbiAgICBlbGVtZW50LmF0dHIoJ2Rpc2FibGVkJywgJ2Rpc2FibGVkJykuZmluZCgnPiAuZmEnKS5yZW1vdmVDbGFzcygnZmEtY2xvdWQtZG93bmxvYWQnKS5hZGRDbGFzcygnZmEtcmVmcmVzaCBmYS1zcGluJyk7XG5cbiAgICByZXF1ZXN0KFVwZGF0ZS51cGRhdGVVUkwsIChyZXNwb25zZSkgPT4ge1xuICAgICAgICBpZiAocmVzcG9uc2UudHlwZSA9PT0gJ3VwZGF0ZWdyYXYnKSB7XG4gICAgICAgICAgICAkKCdbZGF0YS1ncG0tZ3Jhdl0nKS5yZW1vdmUoKTtcbiAgICAgICAgICAgICQoJyNmb290ZXIgLmdyYXYtdmVyc2lvbicpLmh0bWwocmVzcG9uc2UudmVyc2lvbik7XG4gICAgICAgIH1cblxuICAgICAgICBlbGVtZW50LnJlbW92ZUF0dHIoJ2Rpc2FibGVkJykuZmluZCgnPiAuZmEnKS5yZW1vdmVDbGFzcygnZmEtcmVmcmVzaCBmYS1zcGluJykuYWRkQ2xhc3MoJ2ZhLWNsb3VkLWRvd25sb2FkJyk7XG4gICAgfSk7XG59KTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/updates/update.js\n");

/***/ }),

/***/ "./app/utils/2fa.js":
/*!**************************!*\
  !*** ./app/utils/2fa.js ***!
  \**************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\n\n\n\nvar body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body'); // Dashboard update and Grav update\n\nbody.on('click', '[data-2fa-regenerate]', function (event) {\n  event.preventDefault();\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n  var url = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/ajax.json/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"regenerate2FASecret\");\n  element.attr('disabled', 'disabled').find('> .fa').addClass('fa-spin');\n  (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n    method: 'post'\n  }, function (response) {\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-2fa-image]').attr('src', response.image);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-2fa-secret]').text(response.secret);\n    jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-2fa-value]').val(response.secret.replace(' ', ''));\n    element.removeAttr('disabled').find('> .fa').removeClass('fa-spin');\n  });\n});\n\nvar toggleSecret = function toggleSecret() {\n  var toggle = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#toggle_twofa_enabled1');\n  var secret = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.twofa-secret');\n  secret[toggle.is(':checked') ? 'addClass' : 'removeClass']('show');\n};\n\nbody.on('click', '.twofa-toggle input', toggleSecret);\ntoggleSecret();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzLzJmYS5qcz80NGE4Il0sIm5hbWVzIjpbImJvZHkiLCIkIiwib24iLCJldmVudCIsInByZXZlbnREZWZhdWx0IiwiZWxlbWVudCIsInVybCIsImNvbmZpZyIsImF0dHIiLCJmaW5kIiwiYWRkQ2xhc3MiLCJyZXF1ZXN0IiwibWV0aG9kIiwicmVzcG9uc2UiLCJpbWFnZSIsInRleHQiLCJzZWNyZXQiLCJ2YWwiLCJyZXBsYWNlIiwicmVtb3ZlQXR0ciIsInJlbW92ZUNsYXNzIiwidG9nZ2xlU2VjcmV0IiwidG9nZ2xlIiwiaXMiXSwibWFwcGluZ3MiOiI7Ozs7OztBQUFBO0FBQ0E7QUFDQTtBQUVBLElBQU1BLElBQUksR0FBR0MsNkNBQUMsQ0FBQyxNQUFELENBQWQsQyxDQUVBOztBQUNBRCxJQUFJLENBQUNFLEVBQUwsQ0FBUSxPQUFSLEVBQWlCLHVCQUFqQixFQUEwQyxVQUFTQyxLQUFULEVBQWdCO0FBQ3REQSxPQUFLLENBQUNDLGNBQU47QUFDQSxNQUFJQyxPQUFPLEdBQUdKLDZDQUFDLENBQUMsSUFBRCxDQUFmO0FBQ0EsTUFBSUssR0FBRyxhQUFNQyxpRUFBTiw0QkFBZ0RBLHlEQUFoRCx3QkFBUDtBQUVBRixTQUFPLENBQUNHLElBQVIsQ0FBYSxVQUFiLEVBQXlCLFVBQXpCLEVBQXFDQyxJQUFyQyxDQUEwQyxPQUExQyxFQUFtREMsUUFBbkQsQ0FBNEQsU0FBNUQ7QUFFQUMseURBQU8sQ0FBQ0wsR0FBRCxFQUFNO0FBQUVNLFVBQU0sRUFBRTtBQUFWLEdBQU4sRUFBMEIsVUFBQ0MsUUFBRCxFQUFjO0FBQzNDWixpREFBQyxDQUFDLGtCQUFELENBQUQsQ0FBc0JPLElBQXRCLENBQTJCLEtBQTNCLEVBQWtDSyxRQUFRLENBQUNDLEtBQTNDO0FBQ0FiLGlEQUFDLENBQUMsbUJBQUQsQ0FBRCxDQUF1QmMsSUFBdkIsQ0FBNEJGLFFBQVEsQ0FBQ0csTUFBckM7QUFDQWYsaURBQUMsQ0FBQyxrQkFBRCxDQUFELENBQXNCZ0IsR0FBdEIsQ0FBMEJKLFFBQVEsQ0FBQ0csTUFBVCxDQUFnQkUsT0FBaEIsQ0FBd0IsR0FBeEIsRUFBNkIsRUFBN0IsQ0FBMUI7QUFFQWIsV0FBTyxDQUFDYyxVQUFSLENBQW1CLFVBQW5CLEVBQStCVixJQUEvQixDQUFvQyxPQUFwQyxFQUE2Q1csV0FBN0MsQ0FBeUQsU0FBekQ7QUFDSCxHQU5NLENBQVA7QUFPSCxDQWREOztBQWdCQSxJQUFNQyxZQUFZLEdBQUcsU0FBZkEsWUFBZSxHQUFNO0FBQ3ZCLE1BQU1DLE1BQU0sR0FBR3JCLDZDQUFDLENBQUMsd0JBQUQsQ0FBaEI7QUFDQSxNQUFNZSxNQUFNLEdBQUdmLDZDQUFDLENBQUMsZUFBRCxDQUFoQjtBQUVBZSxRQUFNLENBQUNNLE1BQU0sQ0FBQ0MsRUFBUCxDQUFVLFVBQVYsSUFBd0IsVUFBeEIsR0FBcUMsYUFBdEMsQ0FBTixDQUEyRCxNQUEzRDtBQUNILENBTEQ7O0FBT0F2QixJQUFJLENBQUNFLEVBQUwsQ0FBUSxPQUFSLEVBQWlCLHFCQUFqQixFQUF3Q21CLFlBQXhDO0FBQ0FBLFlBQVkiLCJmaWxlIjoiLi9hcHAvdXRpbHMvMmZhLmpzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0ICQgZnJvbSAnanF1ZXJ5JztcbmltcG9ydCB7IGNvbmZpZyB9IGZyb20gJ2dyYXYtY29uZmlnJztcbmltcG9ydCByZXF1ZXN0IGZyb20gJy4uL3V0aWxzL3JlcXVlc3QnO1xuXG5jb25zdCBib2R5ID0gJCgnYm9keScpO1xuXG4vLyBEYXNoYm9hcmQgdXBkYXRlIGFuZCBHcmF2IHVwZGF0ZVxuYm9keS5vbignY2xpY2snLCAnW2RhdGEtMmZhLXJlZ2VuZXJhdGVdJywgZnVuY3Rpb24oZXZlbnQpIHtcbiAgICBldmVudC5wcmV2ZW50RGVmYXVsdCgpO1xuICAgIGxldCBlbGVtZW50ID0gJCh0aGlzKTtcbiAgICBsZXQgdXJsID0gYCR7Y29uZmlnLmJhc2VfdXJsX3JlbGF0aXZlfS9hamF4Lmpzb24vdGFzayR7Y29uZmlnLnBhcmFtX3NlcH1yZWdlbmVyYXRlMkZBU2VjcmV0YDtcblxuICAgIGVsZW1lbnQuYXR0cignZGlzYWJsZWQnLCAnZGlzYWJsZWQnKS5maW5kKCc+IC5mYScpLmFkZENsYXNzKCdmYS1zcGluJyk7XG5cbiAgICByZXF1ZXN0KHVybCwgeyBtZXRob2Q6ICdwb3N0JyB9LCAocmVzcG9uc2UpID0+IHtcbiAgICAgICAgJCgnW2RhdGEtMmZhLWltYWdlXScpLmF0dHIoJ3NyYycsIHJlc3BvbnNlLmltYWdlKTtcbiAgICAgICAgJCgnW2RhdGEtMmZhLXNlY3JldF0nKS50ZXh0KHJlc3BvbnNlLnNlY3JldCk7XG4gICAgICAgICQoJ1tkYXRhLTJmYS12YWx1ZV0nKS52YWwocmVzcG9uc2Uuc2VjcmV0LnJlcGxhY2UoJyAnLCAnJykpO1xuXG4gICAgICAgIGVsZW1lbnQucmVtb3ZlQXR0cignZGlzYWJsZWQnKS5maW5kKCc+IC5mYScpLnJlbW92ZUNsYXNzKCdmYS1zcGluJyk7XG4gICAgfSk7XG59KTtcblxuY29uc3QgdG9nZ2xlU2VjcmV0ID0gKCkgPT4ge1xuICAgIGNvbnN0IHRvZ2dsZSA9ICQoJyN0b2dnbGVfdHdvZmFfZW5hYmxlZDEnKTtcbiAgICBjb25zdCBzZWNyZXQgPSAkKCcudHdvZmEtc2VjcmV0Jyk7XG5cbiAgICBzZWNyZXRbdG9nZ2xlLmlzKCc6Y2hlY2tlZCcpID8gJ2FkZENsYXNzJyA6ICdyZW1vdmVDbGFzcyddKCdzaG93Jyk7XG59O1xuXG5ib2R5Lm9uKCdjbGljaycsICcudHdvZmEtdG9nZ2xlIGlucHV0JywgdG9nZ2xlU2VjcmV0KTtcbnRvZ2dsZVNlY3JldCgpO1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./app/utils/2fa.js\n");

/***/ }),

/***/ "./app/utils/bootstrap-collapse.js":
/*!*****************************************!*\
  !*** ./app/utils/bootstrap-collapse.js ***!
  \*****************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\nfunction _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\n\n/* ========================================================================\n * Bootstrap: collapse.js v3.4.0\n * http://getbootstrap.com/javascript/#collapse\n * ========================================================================\n * Copyright 2011-2016 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n * ======================================================================== */\n\n/* jshint latedef: false */\n\n+function ($) {\n  'use strict'; // COLLAPSE PUBLIC CLASS DEFINITION\n  // ================================\n\n  var Collapse = function Collapse(element, options) {\n    this.$element = $(element);\n    this.options = $.extend({}, Collapse.DEFAULTS, options);\n    this.$trigger = $('[data-toggle=\"collapse\"][href=\"#' + element.id + '\"],' + '[data-toggle=\"collapse\"][data-target=\"#' + element.id + '\"]');\n    this.transitioning = null;\n\n    if (this.options.parent) {\n      this.$parent = this.getParent();\n    } else {\n      this.addAriaAndCollapsedClass(this.$element, this.$trigger);\n    }\n\n    if (this.options.toggle) this.toggle();\n  };\n\n  Collapse.VERSION = '3.4.0';\n  Collapse.TRANSITION_DURATION = 350;\n  Collapse.DEFAULTS = {\n    toggle: true\n  };\n\n  Collapse.prototype.dimension = function () {\n    var hasWidth = this.$element.hasClass('width');\n    return hasWidth ? 'width' : 'height';\n  };\n\n  Collapse.prototype.show = function () {\n    if (this.transitioning || this.$element.hasClass('in')) return;\n    var activesData;\n    var actives = this.$parent && this.$parent.children('.panel').children('.in, .collapsing');\n\n    if (actives && actives.length) {\n      activesData = actives.data('bs.collapse');\n      if (activesData && activesData.transitioning) return;\n    }\n\n    var startEvent = $.Event('show.bs.collapse');\n    this.$element.trigger(startEvent);\n    if (startEvent.isDefaultPrevented()) return;\n\n    if (actives && actives.length) {\n      Plugin.call(actives, 'hide');\n      activesData || actives.data('bs.collapse', null);\n    }\n\n    var dimension = this.dimension();\n    this.$element.removeClass('collapse').addClass('collapsing')[dimension](0).attr('aria-expanded', true);\n    this.$trigger.removeClass('collapsed').attr('aria-expanded', true);\n    this.transitioning = 1;\n\n    var complete = function complete() {\n      this.$element.removeClass('collapsing').addClass('collapse in')[dimension]('');\n      this.transitioning = 0;\n      this.$element.trigger('shown.bs.collapse');\n    };\n\n    if (!$.support.transition) return complete.call(this);\n    var scrollSize = $.camelCase(['scroll', dimension].join('-'));\n    this.$element.one('bsTransitionEnd', $.proxy(complete, this)).emulateTransitionEnd(Collapse.TRANSITION_DURATION)[dimension](this.$element[0][scrollSize]);\n  };\n\n  Collapse.prototype.hide = function () {\n    if (this.transitioning || !this.$element.hasClass('in')) return;\n    var startEvent = $.Event('hide.bs.collapse');\n    this.$element.trigger(startEvent);\n    if (startEvent.isDefaultPrevented()) return;\n    var dimension = this.dimension();\n    this.$element[dimension](this.$element[dimension]())[0].offsetHeight;\n    this.$element.addClass('collapsing').removeClass('collapse in').attr('aria-expanded', false);\n    this.$trigger.addClass('collapsed').attr('aria-expanded', false);\n    this.transitioning = 1;\n\n    var complete = function complete() {\n      this.transitioning = 0;\n      this.$element.removeClass('collapsing').addClass('collapse').trigger('hidden.bs.collapse');\n    };\n\n    if (!$.support.transition) return complete.call(this);\n    this.$element[dimension](0).one('bsTransitionEnd', $.proxy(complete, this)).emulateTransitionEnd(Collapse.TRANSITION_DURATION);\n  };\n\n  Collapse.prototype.toggle = function () {\n    this[this.$element.hasClass('in') ? 'hide' : 'show']();\n  };\n\n  Collapse.prototype.getParent = function () {\n    return $(this.options.parent).find('[data-toggle=\"collapse\"][data-parent=\"' + this.options.parent + '\"]').each($.proxy(function (i, element) {\n      var $element = $(element);\n      this.addAriaAndCollapsedClass(getTargetFromTrigger($element), $element);\n    }, this)).end();\n  };\n\n  Collapse.prototype.addAriaAndCollapsedClass = function ($element, $trigger) {\n    var isOpen = $element.hasClass('in');\n    $element.attr('aria-expanded', isOpen);\n    $trigger.toggleClass('collapsed', !isOpen).attr('aria-expanded', isOpen);\n  };\n\n  function getTargetFromTrigger($trigger) {\n    var href;\n    var target = $trigger.attr('data-target') || (href = $trigger.attr('href')) && href.replace(/.*(?=#[^\\s]+$)/, ''); // strip for ie7\n\n    return $(target);\n  } // COLLAPSE PLUGIN DEFINITION\n  // ==========================\n\n\n  function Plugin(option) {\n    return this.each(function () {\n      var $this = $(this);\n      var data = $this.data('bs.collapse');\n      var options = $.extend({}, Collapse.DEFAULTS, $this.data(), _typeof(option) === 'object' && option);\n      if (!data && options.toggle && /show|hide/.test(option)) options.toggle = false;\n      if (!data) $this.data('bs.collapse', data = new Collapse(this, options));\n      if (typeof option === 'string') data[option]();\n    });\n  }\n\n  var old = $.fn.collapse;\n  $.fn.collapse = Plugin;\n  $.fn.collapse.Constructor = Collapse; // COLLAPSE NO CONFLICT\n  // ====================\n\n  $.fn.collapse.noConflict = function () {\n    $.fn.collapse = old;\n    return this;\n  }; // COLLAPSE DATA-API\n  // =================\n\n\n  $(document).on('click.bs.collapse.data-api', '[data-toggle=\"collapse\"]', function (e) {\n    var $this = $(this);\n    if (!$this.attr('data-target')) e.preventDefault();\n    var $target = getTargetFromTrigger($this);\n    var data = $target.data('bs.collapse');\n    var option = data ? 'toggle' : $this.data();\n    Plugin.call($target, option);\n  });\n}((jquery__WEBPACK_IMPORTED_MODULE_0___default()));//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 18456 characters]\n//# sourceURL=webpack-internal:///./app/utils/bootstrap-collapse.js\n");

/***/ }),

/***/ "./app/utils/bootstrap-datetimepicker.js":
/*!***********************************************!*\
  !*** ./app/utils/bootstrap-datetimepicker.js ***!
  \***********************************************/
/*! unknown exports (runtime-defined) */
/*! runtime requirements: __webpack_require__, __webpack_exports__, module */
/***/ ((module, exports, __webpack_require__) => {

eval("var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\n/*! version : 4.17.47\n =========================================================\n bootstrap-datetimejs\n https://github.com/Eonasdan/bootstrap-datetimepicker\n Copyright (c) 2015 Jonathan Peterson\n =========================================================\n */\n\n/*\n The MIT License (MIT)\n\n Copyright (c) 2015 Jonathan Peterson\n\n Permission is hereby granted, free of charge, to any person obtaining a copy\n of this software and associated documentation files (the \"Software\"), to deal\n in the Software without restriction, including without limitation the rights\n to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n copies of the Software, and to permit persons to whom the Software is\n furnished to do so, subject to the following conditions:\n\n The above copyright notice and this permission notice shall be included in\n all copies or substantial portions of the Software.\n\n THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n THE SOFTWARE.\n */\n\n/* global define:false */\n\n/* global jQuery:false */\n\n/* global moment:false */\n(function (factory) {\n  'use strict';\n\n  if (true) {\n    // AMD is used - Register as an anonymous module.\n    !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(/*! jquery */ \"jquery\"), __webpack_require__(/*! moment */ \"./node_modules/moment/moment.js\")], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),\n\t\t__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?\n\t\t(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),\n\t\t__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));\n  } else {}\n})(function ($, moment) {\n  'use strict';\n\n  if (!moment) {\n    throw new Error('bootstrap-datetimepicker requires Moment.js to be loaded first');\n  }\n\n  var dateTimePicker = function dateTimePicker(element, options) {\n    var picker = {};\n    var date;\n    var viewDate;\n    var unset = true;\n    var input;\n    var component = false;\n    var widget = false;\n    var use24Hours;\n    var minViewModeNumber = 0;\n    var actualFormat;\n    var parseFormats;\n    var currentViewMode;\n    var datePickerModes = [{\n      clsName: 'days',\n      navFnc: 'M',\n      navStep: 1\n    }, {\n      clsName: 'months',\n      navFnc: 'y',\n      navStep: 1\n    }, {\n      clsName: 'years',\n      navFnc: 'y',\n      navStep: 10\n    }, {\n      clsName: 'decades',\n      navFnc: 'y',\n      navStep: 100\n    }];\n    var viewModes = ['days', 'months', 'years', 'decades'];\n    var verticalModes = ['top', 'bottom', 'auto'];\n    var horizontalModes = ['left', 'right', 'auto'];\n    var toolbarPlacements = ['default', 'top', 'bottom'];\n    var keyMap = {\n      'up': 38,\n      38: 'up',\n      'down': 40,\n      40: 'down',\n      'left': 37,\n      37: 'left',\n      'right': 39,\n      39: 'right',\n      'tab': 9,\n      9: 'tab',\n      'escape': 27,\n      27: 'escape',\n      'enter': 13,\n      13: 'enter',\n      'pageUp': 33,\n      33: 'pageUp',\n      'pageDown': 34,\n      34: 'pageDown',\n      'shift': 16,\n      16: 'shift',\n      'control': 17,\n      17: 'control',\n      'space': 32,\n      32: 'space',\n      't': 84,\n      84: 't',\n      'delete': 46,\n      46: 'delete'\n    };\n    var keyState = {};\n    /** ******************************************************************************\n         *\n         * Private functions\n         *\n         ********************************************************************************/\n\n    var hasTimeZone = function hasTimeZone() {\n      return moment.tz !== undefined && options.timeZone !== undefined && options.timeZone !== null && options.timeZone !== '';\n    };\n\n    var getMoment = function getMoment(d) {\n      var returnMoment;\n\n      if (d === undefined || d === null) {\n        returnMoment = moment(); // TODO should this use format? and locale?\n      } else if (moment.isDate(d) || moment.isMoment(d)) {\n        // If the date that is passed in is already a Date() or moment() object,\n        // pass it directly to moment.\n        returnMoment = moment(d);\n      } else if (hasTimeZone()) {\n        // There is a string to parse and a default time zone\n        // parse with the tz function which takes a default time zone if it is not in the format string\n        returnMoment = moment.tz(d, parseFormats, options.useStrict, options.timeZone);\n      } else {\n        returnMoment = moment(d, parseFormats, options.useStrict);\n      }\n\n      if (hasTimeZone()) {\n        returnMoment.tz(options.timeZone);\n      }\n\n      return returnMoment;\n    };\n\n    var isEnabled = function isEnabled(granularity) {\n      if (typeof granularity !== 'string' || granularity.length > 1) {\n        throw new TypeError('isEnabled expects a single character string parameter');\n      }\n\n      switch (granularity) {\n        case 'y':\n          return actualFormat.indexOf('Y') !== -1;\n\n        case 'M':\n          return actualFormat.indexOf('M') !== -1;\n\n        case 'd':\n          return actualFormat.toLowerCase().indexOf('d') !== -1;\n\n        case 'h':\n        case 'H':\n          return actualFormat.toLowerCase().indexOf('h') !== -1;\n\n        case 'm':\n          return actualFormat.indexOf('m') !== -1;\n\n        case 's':\n          return actualFormat.indexOf('s') !== -1;\n\n        default:\n          return false;\n      }\n    };\n\n    var hasTime = function hasTime() {\n      return isEnabled('h') || isEnabled('m') || isEnabled('s');\n    };\n\n    var hasDate = function hasDate() {\n      return isEnabled('y') || isEnabled('M') || isEnabled('d');\n    };\n\n    var getDatePickerTemplate = function getDatePickerTemplate() {\n      var headTemplate = $('<thead>').append($('<tr>').append($('<th>').addClass('prev').attr('data-action', 'previous').append($('<span>').addClass(options.icons.previous))).append($('<th>').addClass('picker-switch').attr('data-action', 'pickerSwitch').attr('colspan', options.calendarWeeks ? '6' : '5')).append($('<th>').addClass('next').attr('data-action', 'next').append($('<span>').addClass(options.icons.next))));\n      var contTemplate = $('<tbody>').append($('<tr>').append($('<td>').attr('colspan', options.calendarWeeks ? '8' : '7')));\n      return [$('<div>').addClass('datepicker-days').append($('<table>').addClass('table-condensed').append(headTemplate).append($('<tbody>'))), $('<div>').addClass('datepicker-months').append($('<table>').addClass('table-condensed').append(headTemplate.clone()).append(contTemplate.clone())), $('<div>').addClass('datepicker-years').append($('<table>').addClass('table-condensed').append(headTemplate.clone()).append(contTemplate.clone())), $('<div>').addClass('datepicker-decades').append($('<table>').addClass('table-condensed').append(headTemplate.clone()).append(contTemplate.clone()))];\n    };\n\n    var getTimePickerMainTemplate = function getTimePickerMainTemplate() {\n      var topRow = $('<tr>');\n      var middleRow = $('<tr>');\n      var bottomRow = $('<tr>');\n\n      if (isEnabled('h')) {\n        topRow.append($('<td>').append($('<a>').attr({\n          href: '#',\n          tabindex: '-1',\n          'title': options.tooltips.incrementHour\n        }).addClass('btn').attr('data-action', 'incrementHours').append($('<span>').addClass(options.icons.up))));\n        middleRow.append($('<td>').append($('<span>').addClass('timepicker-hour').attr({\n          'data-time-component': 'hours',\n          'title': options.tooltips.pickHour\n        }).attr('data-action', 'showHours')));\n        bottomRow.append($('<td>').append($('<a>').attr({\n          href: '#',\n          tabindex: '-1',\n          'title': options.tooltips.decrementHour\n        }).addClass('btn').attr('data-action', 'decrementHours').append($('<span>').addClass(options.icons.down))));\n      }\n\n      if (isEnabled('m')) {\n        if (isEnabled('h')) {\n          topRow.append($('<td>').addClass('separator'));\n          middleRow.append($('<td>').addClass('separator').html(':'));\n          bottomRow.append($('<td>').addClass('separator'));\n        }\n\n        topRow.append($('<td>').append($('<a>').attr({\n          href: '#',\n          tabindex: '-1',\n          'title': options.tooltips.incrementMinute\n        }).addClass('btn').attr('data-action', 'incrementMinutes').append($('<span>').addClass(options.icons.up))));\n        middleRow.append($('<td>').append($('<span>').addClass('timepicker-minute').attr({\n          'data-time-component': 'minutes',\n          'title': options.tooltips.pickMinute\n        }).attr('data-action', 'showMinutes')));\n        bottomRow.append($('<td>').append($('<a>').attr({\n          href: '#',\n          tabindex: '-1',\n          'title': options.tooltips.decrementMinute\n        }).addClass('btn').attr('data-action', 'decrementMinutes').append($('<span>').addClass(options.icons.down))));\n      }\n\n      if (isEnabled('s')) {\n        if (isEnabled('m')) {\n          topRow.append($('<td>').addClass('separator'));\n          middleRow.append($('<td>').addClass('separator').html(':'));\n          bottomRow.append($('<td>').addClass('separator'));\n        }\n\n        topRow.append($('<td>').append($('<a>').attr({\n          href: '#',\n          tabindex: '-1',\n          'title': options.tooltips.incrementSecond\n        }).addClass('btn').attr('data-action', 'incrementSeconds').append($('<span>').addClass(options.icons.up))));\n        middleRow.append($('<td>').append($('<span>').addClass('timepicker-second').attr({\n          'data-time-component': 'seconds',\n          'title': options.tooltips.pickSecond\n        }).attr('data-action', 'showSeconds')));\n        bottomRow.append($('<td>').append($('<a>').attr({\n          href: '#',\n          tabindex: '-1',\n          'title': options.tooltips.decrementSecond\n        }).addClass('btn').attr('data-action', 'decrementSeconds').append($('<span>').addClass(options.icons.down))));\n      }\n\n      if (!use24Hours) {\n        topRow.append($('<td>').addClass('separator'));\n        middleRow.append($('<td>').append($('<button>').addClass('btn btn-primary').attr({\n          'data-action': 'togglePeriod',\n          tabindex: '-1',\n          'title': options.tooltips.togglePeriod\n        })));\n        bottomRow.append($('<td>').addClass('separator'));\n      }\n\n      return $('<div>').addClass('timepicker-picker').append($('<table>').addClass('table-condensed').append([topRow, middleRow, bottomRow]));\n    };\n\n    var getTimePickerTemplate = function getTimePickerTemplate() {\n      var hoursView = $('<div>').addClass('timepicker-hours').append($('<table>').addClass('table-condensed'));\n      var minutesView = $('<div>').addClass('timepicker-minutes').append($('<table>').addClass('table-condensed'));\n      var secondsView = $('<div>').addClass('timepicker-seconds').append($('<table>').addClass('table-condensed'));\n      var ret = [getTimePickerMainTemplate()];\n\n      if (isEnabled('h')) {\n        ret.push(hoursView);\n      }\n\n      if (isEnabled('m')) {\n        ret.push(minutesView);\n      }\n\n      if (isEnabled('s')) {\n        ret.push(secondsView);\n      }\n\n      return ret;\n    };\n\n    var getToolbar = function getToolbar() {\n      var row = [];\n\n      if (options.showTodayButton) {\n        row.push($('<td>').append($('<a>').attr({\n          'data-action': 'today',\n          'title': options.tooltips.today\n        }).append($('<span>').addClass(options.icons.today))));\n      }\n\n      if (!options.sideBySide && hasDate() && hasTime()) {\n        row.push($('<td>').append($('<a>').attr({\n          'data-action': 'togglePicker',\n          'title': options.tooltips.selectTime\n        }).append($('<span>').addClass(options.icons.time))));\n      }\n\n      if (options.showClear) {\n        row.push($('<td>').append($('<a>').attr({\n          'data-action': 'clear',\n          'title': options.tooltips.clear\n        }).append($('<span>').addClass(options.icons.clear))));\n      }\n\n      if (options.showClose) {\n        row.push($('<td>').append($('<a>').attr({\n          'data-action': 'close',\n          'title': options.tooltips.close\n        }).append($('<span>').addClass(options.icons.close))));\n      }\n\n      return $('<table>').addClass('table-condensed').append($('<tbody>').append($('<tr>').append(row)));\n    };\n\n    var getTemplate = function getTemplate() {\n      var template = $('<div>').addClass('bootstrap-datetimepicker-widget dropdown-menu');\n      var dateView = $('<div>').addClass('datepicker').append(getDatePickerTemplate());\n      var timeView = $('<div>').addClass('timepicker').append(getTimePickerTemplate());\n      var content = $('<ul>').addClass('list-unstyled');\n      var toolbar = $('<li>').addClass('picker-switch' + (options.collapse ? ' accordion-toggle' : '')).append(getToolbar());\n\n      if (options.inline) {\n        template.removeClass('dropdown-menu');\n      }\n\n      if (use24Hours) {\n        template.addClass('usetwentyfour');\n      }\n\n      if (isEnabled('s') && !use24Hours) {\n        template.addClass('wider');\n      }\n\n      if (options.sideBySide && hasDate() && hasTime()) {\n        template.addClass('timepicker-sbs');\n\n        if (options.toolbarPlacement === 'top') {\n          template.append(toolbar);\n        }\n\n        template.append($('<div>').addClass('row').append(dateView.addClass('col-md-6')).append(timeView.addClass('col-md-6')));\n\n        if (options.toolbarPlacement === 'bottom') {\n          template.append(toolbar);\n        }\n\n        return template;\n      }\n\n      if (options.toolbarPlacement === 'top') {\n        content.append(toolbar);\n      }\n\n      if (hasDate()) {\n        content.append($('<li>').addClass(options.collapse && hasTime() ? 'collapse in' : '').append(dateView));\n      }\n\n      if (options.toolbarPlacement === 'default') {\n        content.append(toolbar);\n      }\n\n      if (hasTime()) {\n        content.append($('<li>').addClass(options.collapse && hasDate() ? 'collapse' : '').append(timeView));\n      }\n\n      if (options.toolbarPlacement === 'bottom') {\n        content.append(toolbar);\n      }\n\n      return template.append(content);\n    };\n\n    var dataToOptions = function dataToOptions() {\n      var eData;\n      var dataOptions = {};\n\n      if (element.is('input') || options.inline) {\n        eData = element.data();\n      } else {\n        eData = element.find('input').data();\n      }\n\n      if (eData.dateOptions && eData.dateOptions instanceof Object) {\n        dataOptions = $.extend(true, dataOptions, eData.dateOptions);\n      }\n\n      $.each(options, function (key) {\n        var attributeName = 'date' + key.charAt(0).toUpperCase() + key.slice(1);\n\n        if (eData[attributeName] !== undefined) {\n          dataOptions[key] = eData[attributeName];\n        }\n      });\n      return dataOptions;\n    };\n\n    var place = function place() {\n      var position = (component || element).position();\n      var offset = (component || element).offset();\n      var vertical = options.widgetPositioning.vertical;\n      var horizontal = options.widgetPositioning.horizontal;\n      var parent;\n\n      if (options.widgetParent) {\n        parent = options.widgetParent.append(widget);\n      } else if (element.is('input')) {\n        parent = element.after(widget).parent();\n      } else if (options.inline) {\n        parent = element.append(widget);\n        return;\n      } else {\n        parent = element;\n        element.children().first().after(widget);\n      } // Top and bottom logic\n\n\n      if (vertical === 'auto') {\n        if (offset.top + widget.height() * 1.5 >= $(window).height() + $(window).scrollTop() && widget.height() + element.outerHeight() < offset.top) {\n          vertical = 'top';\n        } else {\n          vertical = 'bottom';\n        }\n      } // Left and right logic\n\n\n      if (horizontal === 'auto') {\n        if (parent.width() < offset.left + widget.outerWidth() / 2 && offset.left + widget.outerWidth() > $(window).width()) {\n          horizontal = 'right';\n        } else {\n          horizontal = 'left';\n        }\n      }\n\n      if (vertical === 'top') {\n        widget.addClass('top').removeClass('bottom');\n      } else {\n        widget.addClass('bottom').removeClass('top');\n      }\n\n      if (horizontal === 'right') {\n        widget.addClass('pull-right');\n      } else {\n        widget.removeClass('pull-right');\n      } // find the first parent element that has a non-static css positioning\n\n\n      if (parent.css('position') === 'static') {\n        parent = parent.parents().filter(function () {\n          return $(this).css('position') !== 'static';\n        }).first();\n      }\n\n      if (parent.length === 0) {\n        throw new Error('datetimepicker component should be placed within a non-static positioned container');\n      }\n\n      widget.css({\n        top: vertical === 'top' ? 'auto' : position.top + element.outerHeight(),\n        bottom: vertical === 'top' ? parent.outerHeight() - (parent === element ? 0 : position.top) : 'auto',\n        left: horizontal === 'left' ? parent === element ? 0 : position.left : 'auto',\n        right: horizontal === 'left' ? 'auto' : parent.outerWidth() - element.outerWidth() - (parent === element ? 0 : position.left)\n      });\n    };\n\n    var notifyEvent = function notifyEvent(e) {\n      if (e.type === 'dp.change' && (e.date && e.date.isSame(e.oldDate) || !e.date && !e.oldDate)) {\n        return;\n      }\n\n      element.trigger(e);\n    };\n\n    var viewUpdate = function viewUpdate(e) {\n      if (e === 'y') {\n        e = 'YYYY';\n      }\n\n      notifyEvent({\n        type: 'dp.update',\n        change: e,\n        viewDate: viewDate.clone()\n      });\n    };\n\n    var showMode = function showMode(dir) {\n      if (!widget) {\n        return;\n      }\n\n      if (dir) {\n        currentViewMode = Math.max(minViewModeNumber, Math.min(3, currentViewMode + dir));\n      }\n\n      widget.find('.datepicker > div').hide().filter('.datepicker-' + datePickerModes[currentViewMode].clsName).show();\n    };\n\n    var fillDow = function fillDow() {\n      var row = $('<tr>');\n      var currentDate = viewDate.clone().startOf('w').startOf('d');\n\n      if (options.calendarWeeks === true) {\n        row.append($('<th>').addClass('cw').text('#'));\n      }\n\n      while (currentDate.isBefore(viewDate.clone().endOf('w'))) {\n        row.append($('<th>').addClass('dow').text(currentDate.format('dd')));\n        currentDate.add(1, 'd');\n      }\n\n      widget.find('.datepicker-days thead').append(row);\n    };\n\n    var isInDisabledDates = function isInDisabledDates(testDate) {\n      return options.disabledDates[testDate.format('YYYY-MM-DD')] === true;\n    };\n\n    var isInEnabledDates = function isInEnabledDates(testDate) {\n      return options.enabledDates[testDate.format('YYYY-MM-DD')] === true;\n    };\n\n    var isInDisabledHours = function isInDisabledHours(testDate) {\n      return options.disabledHours[testDate.format('H')] === true;\n    };\n\n    var isInEnabledHours = function isInEnabledHours(testDate) {\n      return options.enabledHours[testDate.format('H')] === true;\n    };\n\n    var isValid = function isValid(targetMoment, granularity) {\n      if (!targetMoment.isValid()) {\n        return false;\n      }\n\n      if (options.disabledDates && granularity === 'd' && isInDisabledDates(targetMoment)) {\n        return false;\n      }\n\n      if (options.enabledDates && granularity === 'd' && !isInEnabledDates(targetMoment)) {\n        return false;\n      }\n\n      if (options.minDate && targetMoment.isBefore(options.minDate, granularity)) {\n        return false;\n      }\n\n      if (options.maxDate && targetMoment.isAfter(options.maxDate, granularity)) {\n        return false;\n      }\n\n      if (options.daysOfWeekDisabled && granularity === 'd' && options.daysOfWeekDisabled.indexOf(targetMoment.day()) !== -1) {\n        return false;\n      }\n\n      if (options.disabledHours && (granularity === 'h' || granularity === 'm' || granularity === 's') && isInDisabledHours(targetMoment)) {\n        return false;\n      }\n\n      if (options.enabledHours && (granularity === 'h' || granularity === 'm' || granularity === 's') && !isInEnabledHours(targetMoment)) {\n        return false;\n      }\n\n      if (options.disabledTimeIntervals && (granularity === 'h' || granularity === 'm' || granularity === 's')) {\n        var found = false;\n        $.each(options.disabledTimeIntervals, function () {\n          if (targetMoment.isBetween(this[0], this[1])) {\n            found = true;\n            return false;\n          }\n        });\n\n        if (found) {\n          return false;\n        }\n      }\n\n      return true;\n    };\n\n    var fillMonths = function fillMonths() {\n      var spans = [];\n      var monthsShort = viewDate.clone().startOf('y').startOf('d');\n\n      while (monthsShort.isSame(viewDate, 'y')) {\n        spans.push($('<span>').attr('data-action', 'selectMonth').addClass('month').text(monthsShort.format('MMM')));\n        monthsShort.add(1, 'M');\n      }\n\n      widget.find('.datepicker-months td').empty().append(spans);\n    };\n\n    var updateMonths = function updateMonths() {\n      var monthsView = widget.find('.datepicker-months');\n      var monthsViewHeader = monthsView.find('th');\n      var months = monthsView.find('tbody').find('span');\n      monthsViewHeader.eq(0).find('span').attr('title', options.tooltips.prevYear);\n      monthsViewHeader.eq(1).attr('title', options.tooltips.selectYear);\n      monthsViewHeader.eq(2).find('span').attr('title', options.tooltips.nextYear);\n      monthsView.find('.disabled').removeClass('disabled');\n\n      if (!isValid(viewDate.clone().subtract(1, 'y'), 'y')) {\n        monthsViewHeader.eq(0).addClass('disabled');\n      }\n\n      monthsViewHeader.eq(1).text(viewDate.year());\n\n      if (!isValid(viewDate.clone().add(1, 'y'), 'y')) {\n        monthsViewHeader.eq(2).addClass('disabled');\n      }\n\n      months.removeClass('active');\n\n      if (date.isSame(viewDate, 'y') && !unset) {\n        months.eq(date.month()).addClass('active');\n      }\n\n      months.each(function (index) {\n        if (!isValid(viewDate.clone().month(index), 'M')) {\n          $(this).addClass('disabled');\n        }\n      });\n    };\n\n    var updateYears = function updateYears() {\n      var yearsView = widget.find('.datepicker-years');\n      var yearsViewHeader = yearsView.find('th');\n      var startYear = viewDate.clone().subtract(5, 'y');\n      var endYear = viewDate.clone().add(6, 'y');\n      var html = '';\n      yearsViewHeader.eq(0).find('span').attr('title', options.tooltips.prevDecade);\n      yearsViewHeader.eq(1).attr('title', options.tooltips.selectDecade);\n      yearsViewHeader.eq(2).find('span').attr('title', options.tooltips.nextDecade);\n      yearsView.find('.disabled').removeClass('disabled');\n\n      if (options.minDate && options.minDate.isAfter(startYear, 'y')) {\n        yearsViewHeader.eq(0).addClass('disabled');\n      }\n\n      yearsViewHeader.eq(1).text(startYear.year() + '-' + endYear.year());\n\n      if (options.maxDate && options.maxDate.isBefore(endYear, 'y')) {\n        yearsViewHeader.eq(2).addClass('disabled');\n      }\n\n      while (!startYear.isAfter(endYear, 'y')) {\n        html += '<span data-action=\"selectYear\" class=\"year' + (startYear.isSame(date, 'y') && !unset ? ' active' : '') + (!isValid(startYear, 'y') ? ' disabled' : '') + '\">' + startYear.year() + '</span>';\n        startYear.add(1, 'y');\n      }\n\n      yearsView.find('td').html(html);\n    };\n\n    var updateDecades = function updateDecades() {\n      var decadesView = widget.find('.datepicker-decades');\n      var decadesViewHeader = decadesView.find('th');\n      var startDecade = moment({\n        y: viewDate.year() - viewDate.year() % 100 - 1\n      });\n      var endDecade = startDecade.clone().add(100, 'y');\n      var startedAt = startDecade.clone();\n      var minDateDecade = false;\n      var maxDateDecade = false;\n      var endDecadeYear;\n      var html = '';\n      decadesViewHeader.eq(0).find('span').attr('title', options.tooltips.prevCentury);\n      decadesViewHeader.eq(2).find('span').attr('title', options.tooltips.nextCentury);\n      decadesView.find('.disabled').removeClass('disabled');\n\n      if (startDecade.isSame(moment({\n        y: 1900\n      })) || options.minDate && options.minDate.isAfter(startDecade, 'y')) {\n        decadesViewHeader.eq(0).addClass('disabled');\n      }\n\n      decadesViewHeader.eq(1).text(startDecade.year() + '-' + endDecade.year());\n\n      if (startDecade.isSame(moment({\n        y: 2000\n      })) || options.maxDate && options.maxDate.isBefore(endDecade, 'y')) {\n        decadesViewHeader.eq(2).addClass('disabled');\n      }\n\n      while (!startDecade.isAfter(endDecade, 'y')) {\n        endDecadeYear = startDecade.year() + 12;\n        minDateDecade = options.minDate && options.minDate.isAfter(startDecade, 'y') && options.minDate.year() <= endDecadeYear;\n        maxDateDecade = options.maxDate && options.maxDate.isAfter(startDecade, 'y') && options.maxDate.year() <= endDecadeYear;\n        html += '<span data-action=\"selectDecade\" class=\"decade' + (date.isAfter(startDecade) && date.year() <= endDecadeYear ? ' active' : '') + (!isValid(startDecade, 'y') && !minDateDecade && !maxDateDecade ? ' disabled' : '') + '\" data-selection=\"' + (startDecade.year() + 6) + '\">' + (startDecade.year() + 1) + ' - ' + (startDecade.year() + 12) + '</span>';\n        startDecade.add(12, 'y');\n      }\n\n      html += '<span></span><span></span><span></span>'; // push the dangling block over, at least this way it's even\n\n      decadesView.find('td').html(html);\n      decadesViewHeader.eq(1).text(startedAt.year() + 1 + '-' + startDecade.year());\n    };\n\n    var fillDate = function fillDate() {\n      var daysView = widget.find('.datepicker-days');\n      var daysViewHeader = daysView.find('th');\n      var currentDate;\n      var html = [];\n      var row;\n      var clsNames = [];\n      var i;\n\n      if (!hasDate()) {\n        return;\n      }\n\n      daysViewHeader.eq(0).find('span').attr('title', options.tooltips.prevMonth);\n      daysViewHeader.eq(1).attr('title', options.tooltips.selectMonth);\n      daysViewHeader.eq(2).find('span').attr('title', options.tooltips.nextMonth);\n      daysView.find('.disabled').removeClass('disabled');\n      daysViewHeader.eq(1).text(viewDate.format(options.dayViewHeaderFormat));\n\n      if (!isValid(viewDate.clone().subtract(1, 'M'), 'M')) {\n        daysViewHeader.eq(0).addClass('disabled');\n      }\n\n      if (!isValid(viewDate.clone().add(1, 'M'), 'M')) {\n        daysViewHeader.eq(2).addClass('disabled');\n      }\n\n      currentDate = viewDate.clone().startOf('M').startOf('w').startOf('d');\n\n      for (i = 0; i < 42; i++) {\n        // always display 42 days (should show 6 weeks)\n        if (currentDate.weekday() === 0) {\n          row = $('<tr>');\n\n          if (options.calendarWeeks) {\n            row.append('<td class=\"cw\">' + currentDate.week() + '</td>');\n          }\n\n          html.push(row);\n        }\n\n        clsNames = ['day'];\n\n        if (currentDate.isBefore(viewDate, 'M')) {\n          clsNames.push('old');\n        }\n\n        if (currentDate.isAfter(viewDate, 'M')) {\n          clsNames.push('new');\n        }\n\n        if (currentDate.isSame(date, 'd') && !unset) {\n          clsNames.push('active');\n        }\n\n        if (!isValid(currentDate, 'd')) {\n          clsNames.push('disabled');\n        }\n\n        if (currentDate.isSame(getMoment(), 'd')) {\n          clsNames.push('today');\n        }\n\n        if (currentDate.day() === 0 || currentDate.day() === 6) {\n          clsNames.push('weekend');\n        }\n\n        notifyEvent({\n          type: 'dp.classify',\n          date: currentDate,\n          classNames: clsNames\n        });\n        row.append('<td data-action=\"selectDay\" data-day=\"' + currentDate.format('L') + '\" class=\"' + clsNames.join(' ') + '\">' + currentDate.date() + '</td>');\n        currentDate.add(1, 'd');\n      }\n\n      daysView.find('tbody').empty().append(html);\n      updateMonths();\n      updateYears();\n      updateDecades();\n    };\n\n    var fillHours = function fillHours() {\n      var table = widget.find('.timepicker-hours table');\n      var currentHour = viewDate.clone().startOf('d');\n      var html = [];\n      var row = $('<tr>');\n\n      if (viewDate.hour() > 11 && !use24Hours) {\n        currentHour.hour(12);\n      }\n\n      while (currentHour.isSame(viewDate, 'd') && (use24Hours || viewDate.hour() < 12 && currentHour.hour() < 12 || viewDate.hour() > 11)) {\n        if (currentHour.hour() % 4 === 0) {\n          row = $('<tr>');\n          html.push(row);\n        }\n\n        row.append('<td data-action=\"selectHour\" class=\"hour' + (!isValid(currentHour, 'h') ? ' disabled' : '') + '\">' + currentHour.format(use24Hours ? 'HH' : 'hh') + '</td>');\n        currentHour.add(1, 'h');\n      }\n\n      table.empty().append(html);\n    };\n\n    var fillMinutes = function fillMinutes() {\n      var table = widget.find('.timepicker-minutes table');\n      var currentMinute = viewDate.clone().startOf('h');\n      var html = [];\n      var row = $('<tr>');\n      var step = options.stepping === 1 ? 5 : options.stepping;\n\n      while (viewDate.isSame(currentMinute, 'h')) {\n        if (currentMinute.minute() % (step * 4) === 0) {\n          row = $('<tr>');\n          html.push(row);\n        }\n\n        row.append('<td data-action=\"selectMinute\" class=\"minute' + (!isValid(currentMinute, 'm') ? ' disabled' : '') + '\">' + currentMinute.format('mm') + '</td>');\n        currentMinute.add(step, 'm');\n      }\n\n      table.empty().append(html);\n    };\n\n    var fillSeconds = function fillSeconds() {\n      var table = widget.find('.timepicker-seconds table');\n      var currentSecond = viewDate.clone().startOf('m');\n      var html = [];\n      var row = $('<tr>');\n\n      while (viewDate.isSame(currentSecond, 'm')) {\n        if (currentSecond.second() % 20 === 0) {\n          row = $('<tr>');\n          html.push(row);\n        }\n\n        row.append('<td data-action=\"selectSecond\" class=\"second' + (!isValid(currentSecond, 's') ? ' disabled' : '') + '\">' + currentSecond.format('ss') + '</td>');\n        currentSecond.add(5, 's');\n      }\n\n      table.empty().append(html);\n    };\n\n    var fillTime = function fillTime() {\n      var toggle;\n      var newDate;\n      var timeComponents = widget.find('.timepicker span[data-time-component]');\n\n      if (!use24Hours) {\n        toggle = widget.find('.timepicker [data-action=togglePeriod]');\n        newDate = date.clone().add(date.hours() >= 12 ? -12 : 12, 'h');\n        toggle.text(date.format('A'));\n\n        if (isValid(newDate, 'h')) {\n          toggle.removeClass('disabled');\n        } else {\n          toggle.addClass('disabled');\n        }\n      }\n\n      timeComponents.filter('[data-time-component=hours]').text(date.format(use24Hours ? 'HH' : 'hh'));\n      timeComponents.filter('[data-time-component=minutes]').text(date.format('mm'));\n      timeComponents.filter('[data-time-component=seconds]').text(date.format('ss'));\n      fillHours();\n      fillMinutes();\n      fillSeconds();\n    };\n\n    var update = function update() {\n      if (!widget) {\n        return;\n      }\n\n      fillDate();\n      fillTime();\n    };\n\n    var setValue = function setValue(targetMoment) {\n      var oldDate = unset ? null : date; // case of calling setValue(null or false)\n\n      if (!targetMoment) {\n        unset = true;\n        input.val('');\n        element.data('date', '');\n        notifyEvent({\n          type: 'dp.change',\n          date: false,\n          oldDate: oldDate\n        });\n        update();\n        return;\n      }\n\n      targetMoment = targetMoment.clone().locale(options.locale);\n\n      if (hasTimeZone()) {\n        targetMoment.tz(options.timeZone);\n      }\n\n      if (options.stepping !== 1) {\n        targetMoment.minutes(Math.round(targetMoment.minutes() / options.stepping) * options.stepping).seconds(0);\n\n        while (options.minDate && targetMoment.isBefore(options.minDate)) {\n          targetMoment.add(options.stepping, 'minutes');\n        }\n      }\n\n      if (isValid(targetMoment)) {\n        date = targetMoment;\n        viewDate = date.clone();\n        input.val(date.format(actualFormat));\n        element.data('date', date.format(actualFormat));\n        unset = false;\n        update();\n        notifyEvent({\n          type: 'dp.change',\n          date: date.clone(),\n          oldDate: oldDate\n        });\n      } else {\n        if (!options.keepInvalid) {\n          input.val(unset ? '' : date.format(actualFormat));\n        } else {\n          notifyEvent({\n            type: 'dp.change',\n            date: targetMoment,\n            oldDate: oldDate\n          });\n        }\n\n        notifyEvent({\n          type: 'dp.error',\n          date: targetMoment,\n          oldDate: oldDate\n        });\n      }\n    };\n    /**\n         * Hides the widget. Possibly will emit dp.hide\n         */\n\n\n    var hide = function hide() {\n      var transitioning = false;\n\n      if (!widget) {\n        return picker;\n      } // Ignore event if in the middle of a picker transition\n\n\n      widget.find('.collapse').each(function () {\n        var collapseData = $(this).data('collapse');\n\n        if (collapseData && collapseData.transitioning) {\n          transitioning = true;\n          return false;\n        }\n\n        return true;\n      });\n\n      if (transitioning) {\n        return picker;\n      }\n\n      if (component && component.hasClass('btn')) {\n        component.toggleClass('active');\n      }\n\n      widget.hide();\n      $(window).off('resize', place);\n      widget.off('click', '[data-action]');\n      widget.off('mousedown', false);\n      widget.remove();\n      widget = false;\n      notifyEvent({\n        type: 'dp.hide',\n        date: date.clone()\n      });\n      input.blur();\n      viewDate = date.clone();\n      return picker;\n    };\n\n    var clear = function clear() {\n      setValue(null);\n    };\n\n    var parseInputDate = function parseInputDate(inputDate) {\n      if (options.parseInputDate === undefined) {\n        if (!moment.isMoment(inputDate) || inputDate instanceof Date) {\n          inputDate = getMoment(inputDate);\n        }\n      } else {\n        inputDate = options.parseInputDate(inputDate);\n      } // inputDate.locale(options.locale);\n\n\n      return inputDate;\n    };\n    /** ******************************************************************************\n         *\n         * Widget UI interaction functions\n         *\n         ********************************************************************************/\n\n\n    var actions = {\n      next: function next() {\n        var navFnc = datePickerModes[currentViewMode].navFnc;\n        viewDate.add(datePickerModes[currentViewMode].navStep, navFnc);\n        fillDate();\n        viewUpdate(navFnc);\n      },\n      previous: function previous() {\n        var navFnc = datePickerModes[currentViewMode].navFnc;\n        viewDate.subtract(datePickerModes[currentViewMode].navStep, navFnc);\n        fillDate();\n        viewUpdate(navFnc);\n      },\n      pickerSwitch: function pickerSwitch() {\n        showMode(1);\n      },\n      selectMonth: function selectMonth(e) {\n        var month = $(e.target).closest('tbody').find('span').index($(e.target));\n        viewDate.month(month);\n\n        if (currentViewMode === minViewModeNumber) {\n          setValue(date.clone().year(viewDate.year()).month(viewDate.month()));\n\n          if (!options.inline) {\n            hide();\n          }\n        } else {\n          showMode(-1);\n          fillDate();\n        }\n\n        viewUpdate('M');\n      },\n      selectYear: function selectYear(e) {\n        var year = parseInt($(e.target).text(), 10) || 0;\n        viewDate.year(year);\n\n        if (currentViewMode === minViewModeNumber) {\n          setValue(date.clone().year(viewDate.year()));\n\n          if (!options.inline) {\n            hide();\n          }\n        } else {\n          showMode(-1);\n          fillDate();\n        }\n\n        viewUpdate('YYYY');\n      },\n      selectDecade: function selectDecade(e) {\n        var year = parseInt($(e.target).data('selection'), 10) || 0;\n        viewDate.year(year);\n\n        if (currentViewMode === minViewModeNumber) {\n          setValue(date.clone().year(viewDate.year()));\n\n          if (!options.inline) {\n            hide();\n          }\n        } else {\n          showMode(-1);\n          fillDate();\n        }\n\n        viewUpdate('YYYY');\n      },\n      selectDay: function selectDay(e) {\n        var day = viewDate.clone();\n\n        if ($(e.target).is('.old')) {\n          day.subtract(1, 'M');\n        }\n\n        if ($(e.target).is('.new')) {\n          day.add(1, 'M');\n        }\n\n        setValue(day.date(parseInt($(e.target).text(), 10)));\n\n        if (!hasTime() && !options.keepOpen && !options.inline) {\n          hide();\n        }\n      },\n      incrementHours: function incrementHours() {\n        var newDate = date.clone().add(1, 'h');\n\n        if (isValid(newDate, 'h')) {\n          setValue(newDate);\n        }\n      },\n      incrementMinutes: function incrementMinutes() {\n        var newDate = date.clone().add(options.stepping, 'm');\n\n        if (isValid(newDate, 'm')) {\n          setValue(newDate);\n        }\n      },\n      incrementSeconds: function incrementSeconds() {\n        var newDate = date.clone().add(1, 's');\n\n        if (isValid(newDate, 's')) {\n          setValue(newDate);\n        }\n      },\n      decrementHours: function decrementHours() {\n        var newDate = date.clone().subtract(1, 'h');\n\n        if (isValid(newDate, 'h')) {\n          setValue(newDate);\n        }\n      },\n      decrementMinutes: function decrementMinutes() {\n        var newDate = date.clone().subtract(options.stepping, 'm');\n\n        if (isValid(newDate, 'm')) {\n          setValue(newDate);\n        }\n      },\n      decrementSeconds: function decrementSeconds() {\n        var newDate = date.clone().subtract(1, 's');\n\n        if (isValid(newDate, 's')) {\n          setValue(newDate);\n        }\n      },\n      togglePeriod: function togglePeriod() {\n        setValue(date.clone().add(date.hours() >= 12 ? -12 : 12, 'h'));\n      },\n      togglePicker: function togglePicker(e) {\n        var $this = $(e.target);\n        var $parent = $this.closest('ul');\n        var expanded = $parent.find('.in');\n        var closed = $parent.find('.collapse:not(.in)');\n        var collapseData;\n\n        if (expanded && expanded.length) {\n          collapseData = expanded.data('collapse');\n\n          if (collapseData && collapseData.transitioning) {\n            return;\n          }\n\n          if (expanded.collapse) {\n            // if collapse plugin is available through bootstrap.js then use it\n            expanded.collapse('hide');\n            closed.collapse('show');\n          } else {\n            // otherwise just toggle in class on the two views\n            expanded.removeClass('in');\n            closed.addClass('in');\n          }\n\n          if ($this.is('span')) {\n            $this.toggleClass(options.icons.time + ' ' + options.icons.date);\n          } else {\n            $this.find('span').toggleClass(options.icons.time + ' ' + options.icons.date);\n          } // NOTE: uncomment if toggled state will be restored in show()\n          // if (component) {\n          //    component.find('span').toggleClass(options.icons.time + ' ' + options.icons.date);\n          // }\n\n        }\n      },\n      showPicker: function showPicker() {\n        widget.find('.timepicker > div:not(.timepicker-picker)').hide();\n        widget.find('.timepicker .timepicker-picker').show();\n      },\n      showHours: function showHours() {\n        widget.find('.timepicker .timepicker-picker').hide();\n        widget.find('.timepicker .timepicker-hours').show();\n      },\n      showMinutes: function showMinutes() {\n        widget.find('.timepicker .timepicker-picker').hide();\n        widget.find('.timepicker .timepicker-minutes').show();\n      },\n      showSeconds: function showSeconds() {\n        widget.find('.timepicker .timepicker-picker').hide();\n        widget.find('.timepicker .timepicker-seconds').show();\n      },\n      selectHour: function selectHour(e) {\n        var hour = parseInt($(e.target).text(), 10);\n\n        if (!use24Hours) {\n          if (date.hours() >= 12) {\n            if (hour !== 12) {\n              hour += 12;\n            }\n          } else {\n            if (hour === 12) {\n              hour = 0;\n            }\n          }\n        }\n\n        setValue(date.clone().hours(hour));\n        actions.showPicker.call(picker);\n      },\n      selectMinute: function selectMinute(e) {\n        setValue(date.clone().minutes(parseInt($(e.target).text(), 10)));\n        actions.showPicker.call(picker);\n      },\n      selectSecond: function selectSecond(e) {\n        setValue(date.clone().seconds(parseInt($(e.target).text(), 10)));\n        actions.showPicker.call(picker);\n      },\n      clear: clear,\n      today: function today() {\n        var todaysDate = getMoment();\n\n        if (isValid(todaysDate, 'd')) {\n          setValue(todaysDate);\n        }\n      },\n      close: hide\n    };\n\n    var doAction = function doAction(e) {\n      if ($(e.currentTarget).is('.disabled')) {\n        return false;\n      }\n\n      actions[$(e.currentTarget).data('action')].apply(picker, arguments);\n      return false;\n    };\n    /**\n         * Shows the widget. Possibly will emit dp.show and dp.change\n         */\n\n\n    var show = function show() {\n      var currentMoment;\n      var useCurrentGranularity = {\n        'year': function year(m) {\n          return m.month(0).date(1).hours(0).seconds(0).minutes(0);\n        },\n        'month': function month(m) {\n          return m.date(1).hours(0).seconds(0).minutes(0);\n        },\n        'day': function day(m) {\n          return m.hours(0).seconds(0).minutes(0);\n        },\n        'hour': function hour(m) {\n          return m.seconds(0).minutes(0);\n        },\n        'minute': function minute(m) {\n          return m.seconds(0);\n        }\n      };\n\n      if (input.prop('disabled') || !options.ignoreReadonly && input.prop('readonly') || widget) {\n        return picker;\n      }\n\n      if (input.val() !== undefined && input.val().trim().length !== 0) {\n        setValue(parseInputDate(input.val().trim()));\n      } else if (unset && options.useCurrent && (options.inline || input.is('input') && input.val().trim().length === 0)) {\n        currentMoment = getMoment();\n\n        if (typeof options.useCurrent === 'string') {\n          currentMoment = useCurrentGranularity[options.useCurrent](currentMoment);\n        }\n\n        setValue(currentMoment);\n      }\n\n      widget = getTemplate();\n      fillDow();\n      fillMonths();\n      widget.find('.timepicker-hours').hide();\n      widget.find('.timepicker-minutes').hide();\n      widget.find('.timepicker-seconds').hide();\n      update();\n      showMode();\n      $(window).on('resize', place);\n      widget.on('click', '[data-action]', doAction); // this handles clicks on the widget\n\n      widget.on('mousedown', false);\n\n      if (component && component.hasClass('btn')) {\n        component.toggleClass('active');\n      }\n\n      place();\n      widget.show();\n\n      if (options.focusOnShow && !input.is(':focus')) {\n        input.focus();\n      }\n\n      notifyEvent({\n        type: 'dp.show'\n      });\n      return picker;\n    };\n    /**\n         * Shows or hides the widget\n         */\n\n\n    var toggle = function toggle() {\n      return widget ? hide() : show();\n    };\n\n    var keydown = function keydown(e) {\n      var handler = null;\n      var index;\n      var index2;\n      var pressedKeys = [];\n      var pressedModifiers = {};\n      var currentKey = e.which;\n      var keyBindKeys;\n      var allModifiersPressed;\n      var pressed = 'p';\n      keyState[currentKey] = pressed;\n\n      for (index in keyState) {\n        if (keyState.hasOwnProperty(index) && keyState[index] === pressed) {\n          pressedKeys.push(index);\n\n          if (parseInt(index, 10) !== currentKey) {\n            pressedModifiers[index] = true;\n          }\n        }\n      }\n\n      for (index in options.keyBinds) {\n        if (options.keyBinds.hasOwnProperty(index) && typeof options.keyBinds[index] === 'function') {\n          keyBindKeys = index.split(' ');\n\n          if (keyBindKeys.length === pressedKeys.length && keyMap[currentKey] === keyBindKeys[keyBindKeys.length - 1]) {\n            allModifiersPressed = true;\n\n            for (index2 = keyBindKeys.length - 2; index2 >= 0; index2--) {\n              if (!(keyMap[keyBindKeys[index2]] in pressedModifiers)) {\n                allModifiersPressed = false;\n                break;\n              }\n            }\n\n            if (allModifiersPressed) {\n              handler = options.keyBinds[index];\n              break;\n            }\n          }\n        }\n      }\n\n      if (handler) {\n        handler.call(picker, widget);\n        e.stopPropagation();\n        e.preventDefault();\n      }\n    };\n\n    var keyup = function keyup(e) {\n      keyState[e.which] = 'r';\n      e.stopPropagation();\n      e.preventDefault();\n    };\n\n    var change = function change(e) {\n      var val = $(e.target).val().trim();\n      var parsedDate = val ? parseInputDate(val) : null;\n      setValue(parsedDate);\n      e.stopImmediatePropagation();\n      return false;\n    };\n\n    var attachDatePickerElementEvents = function attachDatePickerElementEvents() {\n      input.on({\n        'change': change,\n        'blur': options.debug ? '' : hide,\n        'keydown': keydown,\n        'keyup': keyup,\n        'focus': options.allowInputToggle ? show : ''\n      });\n\n      if (element.is('input')) {\n        input.on({\n          'focus': show\n        });\n      } else if (component) {\n        component.on('click', toggle);\n        component.on('mousedown', false);\n      }\n    };\n\n    var detachDatePickerElementEvents = function detachDatePickerElementEvents() {\n      input.off({\n        'change': change,\n        'blur': blur,\n        'keydown': keydown,\n        'keyup': keyup,\n        'focus': options.allowInputToggle ? hide : ''\n      });\n\n      if (element.is('input')) {\n        input.off({\n          'focus': show\n        });\n      } else if (component) {\n        component.off('click', toggle);\n        component.off('mousedown', false);\n      }\n    };\n\n    var indexGivenDates = function indexGivenDates(givenDatesArray) {\n      // Store given enabledDates and disabledDates as keys.\n      // This way we can check their existence in O(1) time instead of looping through whole array.\n      // (for example: options.enabledDates['2014-02-27'] === true)\n      var givenDatesIndexed = {};\n      $.each(givenDatesArray, function () {\n        var dDate = parseInputDate(this);\n\n        if (dDate.isValid()) {\n          givenDatesIndexed[dDate.format('YYYY-MM-DD')] = true;\n        }\n      });\n      return Object.keys(givenDatesIndexed).length ? givenDatesIndexed : false;\n    };\n\n    var indexGivenHours = function indexGivenHours(givenHoursArray) {\n      // Store given enabledHours and disabledHours as keys.\n      // This way we can check their existence in O(1) time instead of looping through whole array.\n      // (for example: options.enabledHours['2014-02-27'] === true)\n      var givenHoursIndexed = {};\n      $.each(givenHoursArray, function () {\n        givenHoursIndexed[this] = true;\n      });\n      return Object.keys(givenHoursIndexed).length ? givenHoursIndexed : false;\n    };\n\n    var initFormatting = function initFormatting() {\n      var format = options.format || 'L LT';\n      actualFormat = format.replace(/(\\[[^\\[]*\\])|(\\\\)?(LTS|LT|LL?L?L?|l{1,4})/g, function (formatInput) {\n        var newinput = date.localeData().longDateFormat(formatInput) || formatInput;\n        return newinput.replace(/(\\[[^\\[]*\\])|(\\\\)?(LTS|LT|LL?L?L?|l{1,4})/g, function (formatInput2) {\n          // temp fix for #740\n          return date.localeData().longDateFormat(formatInput2) || formatInput2;\n        });\n      });\n      parseFormats = options.extraFormats ? options.extraFormats.slice() : [];\n\n      if (parseFormats.indexOf(format) < 0 && parseFormats.indexOf(actualFormat) < 0) {\n        parseFormats.push(actualFormat);\n      }\n\n      use24Hours = actualFormat.toLowerCase().indexOf('a') < 1 && actualFormat.replace(/\\[.*?\\]/g, '').indexOf('h') < 1;\n\n      if (isEnabled('y')) {\n        minViewModeNumber = 2;\n      }\n\n      if (isEnabled('M')) {\n        minViewModeNumber = 1;\n      }\n\n      if (isEnabled('d')) {\n        minViewModeNumber = 0;\n      }\n\n      currentViewMode = Math.max(minViewModeNumber, currentViewMode);\n\n      if (!unset) {\n        setValue(date);\n      }\n    };\n    /** ******************************************************************************\n     *\n     * Public API functions\n     * =====================\n     *\n     * Important: Do not expose direct references to private objects or the options\n     * object to the outer world. Always return a clone when returning values or make\n     * a clone when setting a private variable.\n     *\n     ********************************************************************************/\n\n\n    picker.destroy = function () {\n      // /<summary>Destroys the widget and removes all attached event listeners</summary>\n      hide();\n      detachDatePickerElementEvents();\n      element.removeData('DateTimePicker');\n      element.removeData('date');\n    };\n\n    picker.toggle = toggle;\n    picker.show = show;\n    picker.hide = hide;\n\n    picker.disable = function () {\n      // /<summary>Disables the input element, the component is attached to, by adding a disabled=\"true\" attribute to it.\n      // /If the widget was visible before that call it is hidden. Possibly emits dp.hide</summary>\n      hide();\n\n      if (component && component.hasClass('btn')) {\n        component.addClass('disabled');\n      }\n\n      input.prop('disabled', true);\n      return picker;\n    };\n\n    picker.enable = function () {\n      // /<summary>Enables the input element, the component is attached to, by removing disabled attribute from it.</summary>\n      if (component && component.hasClass('btn')) {\n        component.removeClass('disabled');\n      }\n\n      input.prop('disabled', false);\n      return picker;\n    };\n\n    picker.ignoreReadonly = function (ignoreReadonly) {\n      if (arguments.length === 0) {\n        return options.ignoreReadonly;\n      }\n\n      if (typeof ignoreReadonly !== 'boolean') {\n        throw new TypeError('ignoreReadonly () expects a boolean parameter');\n      }\n\n      options.ignoreReadonly = ignoreReadonly;\n      return picker;\n    };\n\n    picker.options = function (newOptions) {\n      if (arguments.length === 0) {\n        return $.extend(true, {}, options);\n      }\n\n      if (!(newOptions instanceof Object)) {\n        throw new TypeError('options() options parameter should be an object');\n      }\n\n      $.extend(true, options, newOptions);\n      $.each(options, function (key, value) {\n        if (picker[key] !== undefined) {\n          picker[key](value);\n        } else {\n          throw new TypeError('option ' + key + ' is not recognized!');\n        }\n      });\n      return picker;\n    };\n\n    picker.date = function (newDate) {\n      // /<signature helpKeyword=\"$.fn.datetimepicker.date\">\n      // /<summary>Returns the component's model current date, a moment object or null if not set.</summary>\n      // /<returns type=\"Moment\">date.clone()</returns>\n      // /</signature>\n      // /<signature>\n      // /<summary>Sets the components model current moment to it. Passing a null value unsets the components model current moment. Parsing of the newDate parameter is made using moment library with the options.format and options.useStrict components configuration.</summary>\n      // /<param name=\"newDate\" locid=\"$.fn.datetimepicker.date_p:newDate\">Takes string, Date, moment, null parameter.</param>\n      // /</signature>\n      if (arguments.length === 0) {\n        if (unset) {\n          return null;\n        }\n\n        return date.clone();\n      }\n\n      if (newDate !== null && typeof newDate !== 'string' && !moment.isMoment(newDate) && !(newDate instanceof Date)) {\n        throw new TypeError('date() parameter must be one of [null, string, moment or Date]');\n      }\n\n      setValue(newDate === null ? null : parseInputDate(newDate));\n      return picker;\n    };\n\n    picker.format = function (newFormat) {\n      // /<summary>test su</summary>\n      // /<param name=\"newFormat\">info about para</param>\n      // /<returns type=\"string|boolean\">returns foo</returns>\n      if (arguments.length === 0) {\n        return options.format;\n      }\n\n      if (typeof newFormat !== 'string' && (typeof newFormat !== 'boolean' || newFormat !== false)) {\n        throw new TypeError('format() expects a string or boolean:false parameter ' + newFormat);\n      }\n\n      options.format = newFormat;\n\n      if (actualFormat) {\n        initFormatting(); // reinit formatting\n      }\n\n      return picker;\n    };\n\n    picker.timeZone = function (newZone) {\n      if (arguments.length === 0) {\n        return options.timeZone;\n      }\n\n      if (typeof newZone !== 'string') {\n        throw new TypeError('newZone() expects a string parameter');\n      }\n\n      options.timeZone = newZone;\n      return picker;\n    };\n\n    picker.dayViewHeaderFormat = function (newFormat) {\n      if (arguments.length === 0) {\n        return options.dayViewHeaderFormat;\n      }\n\n      if (typeof newFormat !== 'string') {\n        throw new TypeError('dayViewHeaderFormat() expects a string parameter');\n      }\n\n      options.dayViewHeaderFormat = newFormat;\n      return picker;\n    };\n\n    picker.extraFormats = function (formats) {\n      if (arguments.length === 0) {\n        return options.extraFormats;\n      }\n\n      if (formats !== false && !(formats instanceof Array)) {\n        throw new TypeError('extraFormats() expects an array or false parameter');\n      }\n\n      options.extraFormats = formats;\n\n      if (parseFormats) {\n        initFormatting(); // reinit formatting\n      }\n\n      return picker;\n    };\n\n    picker.disabledDates = function (dates) {\n      // /<signature helpKeyword=\"$.fn.datetimepicker.disabledDates\">\n      // /<summary>Returns an array with the currently set disabled dates on the component.</summary>\n      // /<returns type=\"array\">options.disabledDates</returns>\n      // /</signature>\n      // /<signature>\n      // /<summary>Setting this takes precedence over options.minDate, options.maxDate configuration. Also calling this function removes the configuration of\n      // /options.enabledDates if such exist.</summary>\n      // /<param name=\"dates\" locid=\"$.fn.datetimepicker.disabledDates_p:dates\">Takes an [ string or Date or moment ] of values and allows the user to select only from those days.</param>\n      // /</signature>\n      if (arguments.length === 0) {\n        return options.disabledDates ? $.extend({}, options.disabledDates) : options.disabledDates;\n      }\n\n      if (!dates) {\n        options.disabledDates = false;\n        update();\n        return picker;\n      }\n\n      if (!(dates instanceof Array)) {\n        throw new TypeError('disabledDates() expects an array parameter');\n      }\n\n      options.disabledDates = indexGivenDates(dates);\n      options.enabledDates = false;\n      update();\n      return picker;\n    };\n\n    picker.enabledDates = function (dates) {\n      // /<signature helpKeyword=\"$.fn.datetimepicker.enabledDates\">\n      // /<summary>Returns an array with the currently set enabled dates on the component.</summary>\n      // /<returns type=\"array\">options.enabledDates</returns>\n      // /</signature>\n      // /<signature>\n      // /<summary>Setting this takes precedence over options.minDate, options.maxDate configuration. Also calling this function removes the configuration of options.disabledDates if such exist.</summary>\n      // /<param name=\"dates\" locid=\"$.fn.datetimepicker.enabledDates_p:dates\">Takes an [ string or Date or moment ] of values and allows the user to select only from those days.</param>\n      // /</signature>\n      if (arguments.length === 0) {\n        return options.enabledDates ? $.extend({}, options.enabledDates) : options.enabledDates;\n      }\n\n      if (!dates) {\n        options.enabledDates = false;\n        update();\n        return picker;\n      }\n\n      if (!(dates instanceof Array)) {\n        throw new TypeError('enabledDates() expects an array parameter');\n      }\n\n      options.enabledDates = indexGivenDates(dates);\n      options.disabledDates = false;\n      update();\n      return picker;\n    };\n\n    picker.daysOfWeekDisabled = function (daysOfWeekDisabled) {\n      if (arguments.length === 0) {\n        return options.daysOfWeekDisabled.splice(0);\n      }\n\n      if (typeof daysOfWeekDisabled === 'boolean' && !daysOfWeekDisabled) {\n        options.daysOfWeekDisabled = false;\n        update();\n        return picker;\n      }\n\n      if (!(daysOfWeekDisabled instanceof Array)) {\n        throw new TypeError('daysOfWeekDisabled() expects an array parameter');\n      }\n\n      options.daysOfWeekDisabled = daysOfWeekDisabled.reduce(function (previousValue, currentValue) {\n        currentValue = parseInt(currentValue, 10);\n\n        if (currentValue > 6 || currentValue < 0 || isNaN(currentValue)) {\n          return previousValue;\n        }\n\n        if (previousValue.indexOf(currentValue) === -1) {\n          previousValue.push(currentValue);\n        }\n\n        return previousValue;\n      }, []).sort();\n\n      if (options.useCurrent && !options.keepInvalid) {\n        var tries = 0;\n\n        while (!isValid(date, 'd')) {\n          date.add(1, 'd');\n\n          if (tries === 31) {\n            throw new Error('Tried 31 times to find a valid date');\n          }\n\n          tries++;\n        }\n\n        setValue(date);\n      }\n\n      update();\n      return picker;\n    };\n\n    picker.maxDate = function (maxDate) {\n      if (arguments.length === 0) {\n        return options.maxDate ? options.maxDate.clone() : options.maxDate;\n      }\n\n      if (typeof maxDate === 'boolean' && maxDate === false) {\n        options.maxDate = false;\n        update();\n        return picker;\n      }\n\n      if (typeof maxDate === 'string') {\n        if (maxDate === 'now' || maxDate === 'moment') {\n          maxDate = getMoment();\n        }\n      }\n\n      var parsedDate = parseInputDate(maxDate);\n\n      if (!parsedDate.isValid()) {\n        throw new TypeError('maxDate() Could not parse date parameter: ' + maxDate);\n      }\n\n      if (options.minDate && parsedDate.isBefore(options.minDate)) {\n        throw new TypeError('maxDate() date parameter is before options.minDate: ' + parsedDate.format(actualFormat));\n      }\n\n      options.maxDate = parsedDate;\n\n      if (options.useCurrent && !options.keepInvalid && date.isAfter(maxDate)) {\n        setValue(options.maxDate);\n      }\n\n      if (viewDate.isAfter(parsedDate)) {\n        viewDate = parsedDate.clone().subtract(options.stepping, 'm');\n      }\n\n      update();\n      return picker;\n    };\n\n    picker.minDate = function (minDate) {\n      if (arguments.length === 0) {\n        return options.minDate ? options.minDate.clone() : options.minDate;\n      }\n\n      if (typeof minDate === 'boolean' && minDate === false) {\n        options.minDate = false;\n        update();\n        return picker;\n      }\n\n      if (typeof minDate === 'string') {\n        if (minDate === 'now' || minDate === 'moment') {\n          minDate = getMoment();\n        }\n      }\n\n      var parsedDate = parseInputDate(minDate);\n\n      if (!parsedDate.isValid()) {\n        throw new TypeError('minDate() Could not parse date parameter: ' + minDate);\n      }\n\n      if (options.maxDate && parsedDate.isAfter(options.maxDate)) {\n        throw new TypeError('minDate() date parameter is after options.maxDate: ' + parsedDate.format(actualFormat));\n      }\n\n      options.minDate = parsedDate;\n\n      if (options.useCurrent && !options.keepInvalid && date.isBefore(minDate)) {\n        setValue(options.minDate);\n      }\n\n      if (viewDate.isBefore(parsedDate)) {\n        viewDate = parsedDate.clone().add(options.stepping, 'm');\n      }\n\n      update();\n      return picker;\n    };\n\n    picker.defaultDate = function (defaultDate) {\n      // /<signature helpKeyword=\"$.fn.datetimepicker.defaultDate\">\n      // /<summary>Returns a moment with the options.defaultDate option configuration or false if not set</summary>\n      // /<returns type=\"Moment\">date.clone()</returns>\n      // /</signature>\n      // /<signature>\n      // /<summary>Will set the picker's inital date. If a boolean:false value is passed the options.defaultDate parameter is cleared.</summary>\n      // /<param name=\"defaultDate\" locid=\"$.fn.datetimepicker.defaultDate_p:defaultDate\">Takes a string, Date, moment, boolean:false</param>\n      // /</signature>\n      if (arguments.length === 0) {\n        return options.defaultDate ? options.defaultDate.clone() : options.defaultDate;\n      }\n\n      if (!defaultDate) {\n        options.defaultDate = false;\n        return picker;\n      }\n\n      if (typeof defaultDate === 'string') {\n        if (defaultDate === 'now' || defaultDate === 'moment') {\n          defaultDate = getMoment();\n        } else {\n          defaultDate = getMoment(defaultDate);\n        }\n      }\n\n      var parsedDate = parseInputDate(defaultDate);\n\n      if (!parsedDate.isValid()) {\n        throw new TypeError('defaultDate() Could not parse date parameter: ' + defaultDate);\n      }\n\n      if (!isValid(parsedDate)) {\n        throw new TypeError('defaultDate() date passed is invalid according to component setup validations');\n      }\n\n      options.defaultDate = parsedDate;\n\n      if (options.defaultDate && options.inline || input.val().trim() === '') {\n        setValue(options.defaultDate);\n      }\n\n      return picker;\n    };\n\n    picker.locale = function (locale) {\n      if (arguments.length === 0) {\n        return options.locale;\n      }\n\n      if (!moment.localeData(locale)) {\n        throw new TypeError('locale() locale ' + locale + ' is not loaded from moment locales!');\n      }\n\n      options.locale = locale;\n      date.locale(options.locale);\n      viewDate.locale(options.locale);\n\n      if (actualFormat) {\n        initFormatting(); // reinit formatting\n      }\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.stepping = function (stepping) {\n      if (arguments.length === 0) {\n        return options.stepping;\n      }\n\n      stepping = parseInt(stepping, 10);\n\n      if (isNaN(stepping) || stepping < 1) {\n        stepping = 1;\n      }\n\n      options.stepping = stepping;\n      return picker;\n    };\n\n    picker.useCurrent = function (useCurrent) {\n      var useCurrentOptions = ['year', 'month', 'day', 'hour', 'minute'];\n\n      if (arguments.length === 0) {\n        return options.useCurrent;\n      }\n\n      if (typeof useCurrent !== 'boolean' && typeof useCurrent !== 'string') {\n        throw new TypeError('useCurrent() expects a boolean or string parameter');\n      }\n\n      if (typeof useCurrent === 'string' && useCurrentOptions.indexOf(useCurrent.toLowerCase()) === -1) {\n        throw new TypeError('useCurrent() expects a string parameter of ' + useCurrentOptions.join(', '));\n      }\n\n      options.useCurrent = useCurrent;\n      return picker;\n    };\n\n    picker.collapse = function (collapse) {\n      if (arguments.length === 0) {\n        return options.collapse;\n      }\n\n      if (typeof collapse !== 'boolean') {\n        throw new TypeError('collapse() expects a boolean parameter');\n      }\n\n      if (options.collapse === collapse) {\n        return picker;\n      }\n\n      options.collapse = collapse;\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.icons = function (icons) {\n      if (arguments.length === 0) {\n        return $.extend({}, options.icons);\n      }\n\n      if (!(icons instanceof Object)) {\n        throw new TypeError('icons() expects parameter to be an Object');\n      }\n\n      $.extend(options.icons, icons);\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.tooltips = function (tooltips) {\n      if (arguments.length === 0) {\n        return $.extend({}, options.tooltips);\n      }\n\n      if (!(tooltips instanceof Object)) {\n        throw new TypeError('tooltips() expects parameter to be an Object');\n      }\n\n      $.extend(options.tooltips, tooltips);\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.useStrict = function (useStrict) {\n      if (arguments.length === 0) {\n        return options.useStrict;\n      }\n\n      if (typeof useStrict !== 'boolean') {\n        throw new TypeError('useStrict() expects a boolean parameter');\n      }\n\n      options.useStrict = useStrict;\n      return picker;\n    };\n\n    picker.sideBySide = function (sideBySide) {\n      if (arguments.length === 0) {\n        return options.sideBySide;\n      }\n\n      if (typeof sideBySide !== 'boolean') {\n        throw new TypeError('sideBySide() expects a boolean parameter');\n      }\n\n      options.sideBySide = sideBySide;\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.viewMode = function (viewMode) {\n      if (arguments.length === 0) {\n        return options.viewMode;\n      }\n\n      if (typeof viewMode !== 'string') {\n        throw new TypeError('viewMode() expects a string parameter');\n      }\n\n      if (viewModes.indexOf(viewMode) === -1) {\n        throw new TypeError('viewMode() parameter must be one of (' + viewModes.join(', ') + ') value');\n      }\n\n      options.viewMode = viewMode;\n      currentViewMode = Math.max(viewModes.indexOf(viewMode), minViewModeNumber);\n      showMode();\n      return picker;\n    };\n\n    picker.toolbarPlacement = function (toolbarPlacement) {\n      if (arguments.length === 0) {\n        return options.toolbarPlacement;\n      }\n\n      if (typeof toolbarPlacement !== 'string') {\n        throw new TypeError('toolbarPlacement() expects a string parameter');\n      }\n\n      if (toolbarPlacements.indexOf(toolbarPlacement) === -1) {\n        throw new TypeError('toolbarPlacement() parameter must be one of (' + toolbarPlacements.join(', ') + ') value');\n      }\n\n      options.toolbarPlacement = toolbarPlacement;\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.widgetPositioning = function (widgetPositioning) {\n      if (arguments.length === 0) {\n        return $.extend({}, options.widgetPositioning);\n      }\n\n      if ({}.toString.call(widgetPositioning) !== '[object Object]') {\n        throw new TypeError('widgetPositioning() expects an object variable');\n      }\n\n      if (widgetPositioning.horizontal) {\n        if (typeof widgetPositioning.horizontal !== 'string') {\n          throw new TypeError('widgetPositioning() horizontal variable must be a string');\n        }\n\n        widgetPositioning.horizontal = widgetPositioning.horizontal.toLowerCase();\n\n        if (horizontalModes.indexOf(widgetPositioning.horizontal) === -1) {\n          throw new TypeError('widgetPositioning() expects horizontal parameter to be one of (' + horizontalModes.join(', ') + ')');\n        }\n\n        options.widgetPositioning.horizontal = widgetPositioning.horizontal;\n      }\n\n      if (widgetPositioning.vertical) {\n        if (typeof widgetPositioning.vertical !== 'string') {\n          throw new TypeError('widgetPositioning() vertical variable must be a string');\n        }\n\n        widgetPositioning.vertical = widgetPositioning.vertical.toLowerCase();\n\n        if (verticalModes.indexOf(widgetPositioning.vertical) === -1) {\n          throw new TypeError('widgetPositioning() expects vertical parameter to be one of (' + verticalModes.join(', ') + ')');\n        }\n\n        options.widgetPositioning.vertical = widgetPositioning.vertical;\n      }\n\n      update();\n      return picker;\n    };\n\n    picker.calendarWeeks = function (calendarWeeks) {\n      if (arguments.length === 0) {\n        return options.calendarWeeks;\n      }\n\n      if (typeof calendarWeeks !== 'boolean') {\n        throw new TypeError('calendarWeeks() expects parameter to be a boolean value');\n      }\n\n      options.calendarWeeks = calendarWeeks;\n      update();\n      return picker;\n    };\n\n    picker.showTodayButton = function (showTodayButton) {\n      if (arguments.length === 0) {\n        return options.showTodayButton;\n      }\n\n      if (typeof showTodayButton !== 'boolean') {\n        throw new TypeError('showTodayButton() expects a boolean parameter');\n      }\n\n      options.showTodayButton = showTodayButton;\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.showClear = function (showClear) {\n      if (arguments.length === 0) {\n        return options.showClear;\n      }\n\n      if (typeof showClear !== 'boolean') {\n        throw new TypeError('showClear() expects a boolean parameter');\n      }\n\n      options.showClear = showClear;\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.widgetParent = function (widgetParent) {\n      if (arguments.length === 0) {\n        return options.widgetParent;\n      }\n\n      if (typeof widgetParent === 'string') {\n        widgetParent = $(widgetParent);\n      }\n\n      if (widgetParent !== null && typeof widgetParent !== 'string' && !(widgetParent instanceof $)) {\n        throw new TypeError('widgetParent() expects a string or a jQuery object parameter');\n      }\n\n      options.widgetParent = widgetParent;\n\n      if (widget) {\n        hide();\n        show();\n      }\n\n      return picker;\n    };\n\n    picker.keepOpen = function (keepOpen) {\n      if (arguments.length === 0) {\n        return options.keepOpen;\n      }\n\n      if (typeof keepOpen !== 'boolean') {\n        throw new TypeError('keepOpen() expects a boolean parameter');\n      }\n\n      options.keepOpen = keepOpen;\n      return picker;\n    };\n\n    picker.focusOnShow = function (focusOnShow) {\n      if (arguments.length === 0) {\n        return options.focusOnShow;\n      }\n\n      if (typeof focusOnShow !== 'boolean') {\n        throw new TypeError('focusOnShow() expects a boolean parameter');\n      }\n\n      options.focusOnShow = focusOnShow;\n      return picker;\n    };\n\n    picker.inline = function (inline) {\n      if (arguments.length === 0) {\n        return options.inline;\n      }\n\n      if (typeof inline !== 'boolean') {\n        throw new TypeError('inline() expects a boolean parameter');\n      }\n\n      options.inline = inline;\n      return picker;\n    };\n\n    picker.clear = function () {\n      clear();\n      return picker;\n    };\n\n    picker.keyBinds = function (keyBinds) {\n      if (arguments.length === 0) {\n        return options.keyBinds;\n      }\n\n      options.keyBinds = keyBinds;\n      return picker;\n    };\n\n    picker.getMoment = function (d) {\n      return getMoment(d);\n    };\n\n    picker.debug = function (debug) {\n      if (typeof debug !== 'boolean') {\n        throw new TypeError('debug() expects a boolean parameter');\n      }\n\n      options.debug = debug;\n      return picker;\n    };\n\n    picker.allowInputToggle = function (allowInputToggle) {\n      if (arguments.length === 0) {\n        return options.allowInputToggle;\n      }\n\n      if (typeof allowInputToggle !== 'boolean') {\n        throw new TypeError('allowInputToggle() expects a boolean parameter');\n      }\n\n      options.allowInputToggle = allowInputToggle;\n      return picker;\n    };\n\n    picker.showClose = function (showClose) {\n      if (arguments.length === 0) {\n        return options.showClose;\n      }\n\n      if (typeof showClose !== 'boolean') {\n        throw new TypeError('showClose() expects a boolean parameter');\n      }\n\n      options.showClose = showClose;\n      return picker;\n    };\n\n    picker.keepInvalid = function (keepInvalid) {\n      if (arguments.length === 0) {\n        return options.keepInvalid;\n      }\n\n      if (typeof keepInvalid !== 'boolean') {\n        throw new TypeError('keepInvalid() expects a boolean parameter');\n      }\n\n      options.keepInvalid = keepInvalid;\n      return picker;\n    };\n\n    picker.datepickerInput = function (datepickerInput) {\n      if (arguments.length === 0) {\n        return options.datepickerInput;\n      }\n\n      if (typeof datepickerInput !== 'string') {\n        throw new TypeError('datepickerInput() expects a string parameter');\n      }\n\n      options.datepickerInput = datepickerInput;\n      return picker;\n    };\n\n    picker.parseInputDate = function (parseInputDate) {\n      if (arguments.length === 0) {\n        return options.parseInputDate;\n      }\n\n      if (typeof parseInputDate !== 'function') {\n        throw new TypeError('parseInputDate() sholud be as function');\n      }\n\n      options.parseInputDate = parseInputDate;\n      return picker;\n    };\n\n    picker.disabledTimeIntervals = function (disabledTimeIntervals) {\n      // /<signature helpKeyword=\"$.fn.datetimepicker.disabledTimeIntervals\">\n      // /<summary>Returns an array with the currently set disabled dates on the component.</summary>\n      // /<returns type=\"array\">options.disabledTimeIntervals</returns>\n      // /</signature>\n      // /<signature>\n      // /<summary>Setting this takes precedence over options.minDate, options.maxDate configuration. Also calling this function removes the configuration of\n      // /options.enabledDates if such exist.</summary>\n      // /<param name=\"dates\" locid=\"$.fn.datetimepicker.disabledTimeIntervals_p:dates\">Takes an [ string or Date or moment ] of values and allows the user to select only from those days.</param>\n      // /</signature>\n      if (arguments.length === 0) {\n        return options.disabledTimeIntervals ? $.extend({}, options.disabledTimeIntervals) : options.disabledTimeIntervals;\n      }\n\n      if (!disabledTimeIntervals) {\n        options.disabledTimeIntervals = false;\n        update();\n        return picker;\n      }\n\n      if (!(disabledTimeIntervals instanceof Array)) {\n        throw new TypeError('disabledTimeIntervals() expects an array parameter');\n      }\n\n      options.disabledTimeIntervals = disabledTimeIntervals;\n      update();\n      return picker;\n    };\n\n    picker.disabledHours = function (hours) {\n      // /<signature helpKeyword=\"$.fn.datetimepicker.disabledHours\">\n      // /<summary>Returns an array with the currently set disabled hours on the component.</summary>\n      // /<returns type=\"array\">options.disabledHours</returns>\n      // /</signature>\n      // /<signature>\n      // /<summary>Setting this takes precedence over options.minDate, options.maxDate configuration. Also calling this function removes the configuration of\n      // /options.enabledHours if such exist.</summary>\n      // /<param name=\"hours\" locid=\"$.fn.datetimepicker.disabledHours_p:hours\">Takes an [ int ] of values and disallows the user to select only from those hours.</param>\n      // /</signature>\n      if (arguments.length === 0) {\n        return options.disabledHours ? $.extend({}, options.disabledHours) : options.disabledHours;\n      }\n\n      if (!hours) {\n        options.disabledHours = false;\n        update();\n        return picker;\n      }\n\n      if (!(hours instanceof Array)) {\n        throw new TypeError('disabledHours() expects an array parameter');\n      }\n\n      options.disabledHours = indexGivenHours(hours);\n      options.enabledHours = false;\n\n      if (options.useCurrent && !options.keepInvalid) {\n        var tries = 0;\n\n        while (!isValid(date, 'h')) {\n          date.add(1, 'h');\n\n          if (tries === 24) {\n            throw new Error('Tried 24 times to find a valid date');\n          }\n\n          tries++;\n        }\n\n        setValue(date);\n      }\n\n      update();\n      return picker;\n    };\n\n    picker.enabledHours = function (hours) {\n      // /<signature helpKeyword=\"$.fn.datetimepicker.enabledHours\">\n      // /<summary>Returns an array with the currently set enabled hours on the component.</summary>\n      // /<returns type=\"array\">options.enabledHours</returns>\n      // /</signature>\n      // /<signature>\n      // /<summary>Setting this takes precedence over options.minDate, options.maxDate configuration. Also calling this function removes the configuration of options.disabledHours if such exist.</summary>\n      // /<param name=\"hours\" locid=\"$.fn.datetimepicker.enabledHours_p:hours\">Takes an [ int ] of values and allows the user to select only from those hours.</param>\n      // /</signature>\n      if (arguments.length === 0) {\n        return options.enabledHours ? $.extend({}, options.enabledHours) : options.enabledHours;\n      }\n\n      if (!hours) {\n        options.enabledHours = false;\n        update();\n        return picker;\n      }\n\n      if (!(hours instanceof Array)) {\n        throw new TypeError('enabledHours() expects an array parameter');\n      }\n\n      options.enabledHours = indexGivenHours(hours);\n      options.disabledHours = false;\n\n      if (options.useCurrent && !options.keepInvalid) {\n        var tries = 0;\n\n        while (!isValid(date, 'h')) {\n          date.add(1, 'h');\n\n          if (tries === 24) {\n            throw new Error('Tried 24 times to find a valid date');\n          }\n\n          tries++;\n        }\n\n        setValue(date);\n      }\n\n      update();\n      return picker;\n    };\n    /**\n     * Returns the component's model current viewDate, a moment object or null if not set. Passing a null value unsets the components model current moment. Parsing of the newDate parameter is made using moment library with the options.format and options.useStrict components configuration.\n     * @param {Takes string, viewDate, moment, null parameter.} newDate\n     * @returns {viewDate.clone()}\n     */\n\n\n    picker.viewDate = function (newDate) {\n      if (arguments.length === 0) {\n        return viewDate.clone();\n      }\n\n      if (!newDate) {\n        viewDate = date.clone();\n        return picker;\n      }\n\n      if (typeof newDate !== 'string' && !moment.isMoment(newDate) && !(newDate instanceof Date)) {\n        throw new TypeError('viewDate() parameter must be one of [string, moment or Date]');\n      }\n\n      viewDate = parseInputDate(newDate);\n      viewUpdate();\n      return picker;\n    }; // initializing element and component attributes\n\n\n    if (element.is('input')) {\n      input = element;\n    } else {\n      input = element.find(options.datepickerInput);\n\n      if (input.length === 0) {\n        input = element.find('input');\n      } else if (!input.is('input')) {\n        throw new Error('CSS class \"' + options.datepickerInput + '\" cannot be applied to non input element');\n      }\n    }\n\n    if (element.hasClass('input-group')) {\n      // in case there is more then one 'input-group-addon' Issue #48\n      if (element.find('.datepickerbutton').length === 0) {\n        component = element.find('.input-group-addon');\n      } else {\n        component = element.find('.datepickerbutton');\n      }\n    }\n\n    if (!options.inline && !input.is('input')) {\n      throw new Error('Could not initialize DateTimePicker without an input element');\n    } // Set defaults for date here now instead of in var declaration\n\n\n    date = getMoment();\n    viewDate = date.clone();\n    $.extend(true, options, dataToOptions());\n    picker.options(options);\n    initFormatting();\n    attachDatePickerElementEvents();\n\n    if (input.prop('disabled')) {\n      picker.disable();\n    }\n\n    if (input.is('input') && input.val().trim().length !== 0) {\n      setValue(parseInputDate(input.val().trim()));\n    } else if (options.defaultDate && input.attr('placeholder') === undefined) {\n      setValue(options.defaultDate);\n    }\n\n    if (options.inline) {\n      show();\n    }\n\n    return picker;\n  };\n  /** ******************************************************************************\n   *\n   * jQuery plugin constructor and defaults object\n   *\n   ********************************************************************************/\n\n  /**\n   * See (http://jquery.com/).\n   * @name jQuery\n   * @class\n   * See the jQuery Library  (http://jquery.com/) for full details.  This just\n   * documents the function and classes that are added to jQuery by this plug-in.\n   */\n\n  /**\n   * See (http://jquery.com/)\n   * @name fn\n   * @class\n   * See the jQuery Library  (http://jquery.com/) for full details.  This just\n   * documents the function and classes that are added to jQuery by this plug-in.\n   * @memberOf jQuery\n   */\n\n  /**\n   * Show comments\n   * @class datetimepicker\n   * @memberOf jQuery.fn\n   */\n\n\n  $.fn.datetimepicker = function (options) {\n    options = options || {};\n    var args = Array.prototype.slice.call(arguments, 1);\n    var isInstance = true;\n    var thisMethods = ['destroy', 'hide', 'show', 'toggle'];\n    var returnValue;\n\n    if (_typeof(options) === 'object') {\n      return this.each(function () {\n        var $this = $(this);\n\n        var _options;\n\n        if (!$this.data('DateTimePicker')) {\n          // create a private copy of the defaults object\n          _options = $.extend(true, {}, $.fn.datetimepicker.defaults, options);\n          $this.data('DateTimePicker', dateTimePicker($this, _options));\n        }\n      });\n    } else if (typeof options === 'string') {\n      this.each(function () {\n        var $this = $(this);\n        var instance = $this.data('DateTimePicker');\n\n        if (!instance) {\n          throw new Error('bootstrap-datetimepicker(\"' + options + '\") method was called on an element that is not using DateTimePicker');\n        }\n\n        returnValue = instance[options].apply(instance, args);\n        isInstance = returnValue === instance;\n      });\n\n      if (isInstance || $.inArray(options, thisMethods) > -1) {\n        return this;\n      }\n\n      return returnValue;\n    }\n\n    throw new TypeError('Invalid arguments for DateTimePicker: ' + options);\n  };\n\n  $.fn.datetimepicker.defaults = {\n    timeZone: '',\n    format: false,\n    dayViewHeaderFormat: 'MMMM YYYY',\n    extraFormats: false,\n    stepping: 1,\n    minDate: false,\n    maxDate: false,\n    useCurrent: true,\n    collapse: true,\n    locale: moment.locale(),\n    defaultDate: false,\n    disabledDates: false,\n    enabledDates: false,\n    icons: {\n      time: 'glyphicon glyphicon-time',\n      date: 'glyphicon glyphicon-calendar',\n      up: 'glyphicon glyphicon-chevron-up',\n      down: 'glyphicon glyphicon-chevron-down',\n      previous: 'glyphicon glyphicon-chevron-left',\n      next: 'glyphicon glyphicon-chevron-right',\n      today: 'glyphicon glyphicon-screenshot',\n      clear: 'glyphicon glyphicon-trash',\n      close: 'glyphicon glyphicon-remove'\n    },\n    tooltips: {\n      today: 'Go to today',\n      clear: 'Clear selection',\n      close: 'Close the picker',\n      selectMonth: 'Select Month',\n      prevMonth: 'Previous Month',\n      nextMonth: 'Next Month',\n      selectYear: 'Select Year',\n      prevYear: 'Previous Year',\n      nextYear: 'Next Year',\n      selectDecade: 'Select Decade',\n      prevDecade: 'Previous Decade',\n      nextDecade: 'Next Decade',\n      prevCentury: 'Previous Century',\n      nextCentury: 'Next Century',\n      pickHour: 'Pick Hour',\n      incrementHour: 'Increment Hour',\n      decrementHour: 'Decrement Hour',\n      pickMinute: 'Pick Minute',\n      incrementMinute: 'Increment Minute',\n      decrementMinute: 'Decrement Minute',\n      pickSecond: 'Pick Second',\n      incrementSecond: 'Increment Second',\n      decrementSecond: 'Decrement Second',\n      togglePeriod: 'Toggle Period',\n      selectTime: 'Select Time'\n    },\n    useStrict: false,\n    sideBySide: false,\n    daysOfWeekDisabled: false,\n    calendarWeeks: false,\n    viewMode: 'days',\n    toolbarPlacement: 'default',\n    showTodayButton: false,\n    showClear: false,\n    showClose: false,\n    widgetPositioning: {\n      horizontal: 'auto',\n      vertical: 'auto'\n    },\n    widgetParent: null,\n    ignoreReadonly: false,\n    keepOpen: false,\n    focusOnShow: true,\n    inline: false,\n    keepInvalid: false,\n    datepickerInput: '.datepickerinput',\n    keyBinds: {\n      up: function up(widget) {\n        if (!widget) {\n          return;\n        }\n\n        var d = this.date() || this.getMoment();\n\n        if (widget.find('.datepicker').is(':visible')) {\n          this.date(d.clone().subtract(7, 'd'));\n        } else {\n          this.date(d.clone().add(this.stepping(), 'm'));\n        }\n      },\n      down: function down(widget) {\n        if (!widget) {\n          this.show();\n          return;\n        }\n\n        var d = this.date() || this.getMoment();\n\n        if (widget.find('.datepicker').is(':visible')) {\n          this.date(d.clone().add(7, 'd'));\n        } else {\n          this.date(d.clone().subtract(this.stepping(), 'm'));\n        }\n      },\n      'control up': function controlUp(widget) {\n        if (!widget) {\n          return;\n        }\n\n        var d = this.date() || this.getMoment();\n\n        if (widget.find('.datepicker').is(':visible')) {\n          this.date(d.clone().subtract(1, 'y'));\n        } else {\n          this.date(d.clone().add(1, 'h'));\n        }\n      },\n      'control down': function controlDown(widget) {\n        if (!widget) {\n          return;\n        }\n\n        var d = this.date() || this.getMoment();\n\n        if (widget.find('.datepicker').is(':visible')) {\n          this.date(d.clone().add(1, 'y'));\n        } else {\n          this.date(d.clone().subtract(1, 'h'));\n        }\n      },\n      left: function left(widget) {\n        if (!widget) {\n          return;\n        }\n\n        var d = this.date() || this.getMoment();\n\n        if (widget.find('.datepicker').is(':visible')) {\n          this.date(d.clone().subtract(1, 'd'));\n        }\n      },\n      right: function right(widget) {\n        if (!widget) {\n          return;\n        }\n\n        var d = this.date() || this.getMoment();\n\n        if (widget.find('.datepicker').is(':visible')) {\n          this.date(d.clone().add(1, 'd'));\n        }\n      },\n      pageUp: function pageUp(widget) {\n        if (!widget) {\n          return;\n        }\n\n        var d = this.date() || this.getMoment();\n\n        if (widget.find('.datepicker').is(':visible')) {\n          this.date(d.clone().subtract(1, 'M'));\n        }\n      },\n      pageDown: function pageDown(widget) {\n        if (!widget) {\n          return;\n        }\n\n        var d = this.date() || this.getMoment();\n\n        if (widget.find('.datepicker').is(':visible')) {\n          this.date(d.clone().add(1, 'M'));\n        }\n      },\n      enter: function enter() {\n        this.hide();\n      },\n      escape: function escape() {\n        this.hide();\n      },\n      // tab: function (widget) { //this break the flow of the form. disabling for now\n      //    var toggle = widget.find('.picker-switch a[data-action=\"togglePicker\"]');\n      //    if(toggle.length > 0) toggle.click();\n      // },\n      'control space': function controlSpace(widget) {\n        if (!widget) {\n          return;\n        }\n\n        if (widget.find('.timepicker').is(':visible')) {\n          widget.find('.btn[data-action=\"togglePeriod\"]').click();\n        }\n      },\n      t: function t() {\n        this.date(this.getMoment());\n      },\n      'delete': function _delete() {\n        this.clear();\n      }\n    },\n    debug: false,\n    allowInputToggle: false,\n    disabledTimeIntervals: false,\n    disabledHours: false,\n    enabledHours: false,\n    viewDate: false\n  };\n  return $.fn.datetimepicker;\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 254776 characters]\n//# sourceURL=webpack-internal:///./app/utils/bootstrap-datetimepicker.js\n");

/***/ }),

/***/ "./app/utils/bootstrap-dropdown.js":
/*!*****************************************!*\
  !*** ./app/utils/bootstrap-dropdown.js ***!
  \*****************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\n/* ========================================================================\n * Bootstrap: dropdown.js v3.4.1\n * https://getbootstrap.com/docs/3.4/javascript/#dropdowns\n * ========================================================================\n * Copyright 2011-2019 Twitter, Inc.\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/v3-dev/LICENSE)\n * ======================================================================== */\n\n+function ($) {\n  'use strict'; // DROPDOWN CLASS DEFINITION\n  // =========================\n\n  var backdrop = '.dropdown-backdrop';\n  var toggle = '[data-toggle=\"dropdown\"]';\n\n  var Dropdown = function Dropdown(element) {\n    $(element).on('click.bs.dropdown', this.toggle);\n  };\n\n  Dropdown.VERSION = '3.4.1';\n\n  function getParent($this) {\n    var selector = $this.attr('data-target');\n\n    if (!selector) {\n      selector = $this.attr('href');\n      selector = selector && /#[A-Za-z]/.test(selector) && selector.replace(/.*(?=#[^\\s]*$)/, ''); // strip for ie7\n    }\n\n    var $parent = selector !== '#' ? $(document).find(selector) : null;\n    return $parent && $parent.length ? $parent : $this.parent();\n  }\n\n  function clearMenus(e) {\n    if (e && e.which === 3) {\n      return;\n    }\n\n    $(backdrop).remove();\n    $(toggle).each(function () {\n      var $this = $(this);\n      var $parent = getParent($this);\n      var relatedTarget = {\n        relatedTarget: this\n      };\n\n      if (!$parent.hasClass('open')) {\n        return;\n      }\n\n      if (e && e.type === 'click' && /input|textarea/i.test(e.target.tagName) && $.contains($parent[0], e.target)) {\n        return;\n      }\n\n      $parent.trigger(e = $.Event('hide.bs.dropdown', relatedTarget));\n\n      if (e.isDefaultPrevented()) {\n        return;\n      }\n\n      $this.attr('aria-expanded', 'false');\n      $parent.removeClass('open').trigger($.Event('hidden.bs.dropdown', relatedTarget));\n    });\n  }\n\n  Dropdown.prototype.toggle = function (e) {\n    var $this = $(this);\n\n    if ($this.is('.disabled, :disabled')) {\n      return;\n    }\n\n    var $parent = getParent($this);\n    var isActive = $parent.hasClass('open');\n    clearMenus();\n\n    if (!isActive) {\n      if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) {\n        // if mobile we use a backdrop because click events don't delegate\n        $(document.createElement('div')).addClass('dropdown-backdrop').insertAfter($(this)).on('click', clearMenus);\n      }\n\n      var relatedTarget = {\n        relatedTarget: this\n      };\n      $parent.trigger(e = $.Event('show.bs.dropdown', relatedTarget));\n\n      if (e.isDefaultPrevented()) {\n        return;\n      }\n\n      $this.trigger('focus').attr('aria-expanded', 'true');\n      $parent.toggleClass('open').trigger($.Event('shown.bs.dropdown', relatedTarget));\n    }\n\n    return false;\n  };\n\n  Dropdown.prototype.keydown = function (e) {\n    if (!/(38|40|27|32)/.test(e.which) || /input|textarea/i.test(e.target.tagName)) return;\n    var $this = $(this);\n    e.preventDefault();\n    e.stopPropagation();\n\n    if ($this.is('.disabled, :disabled')) {\n      return;\n    }\n\n    var $parent = getParent($this);\n    var isActive = $parent.hasClass('open');\n\n    if (!isActive && e.which !== 27 || isActive && e.which === 27) {\n      if (e.which === 27) {\n        $parent.find(toggle).trigger('focus');\n      }\n\n      return $this.trigger('click');\n    }\n\n    var desc = ' li:not(.disabled):visible a';\n    var $items = $parent.find('.dropdown-menu' + desc);\n\n    if (!$items.length) {\n      return;\n    }\n\n    var index = $items.index(e.target);\n\n    if (e.which === 38 && index > 0) {\n      index--;\n    } // up\n\n\n    if (e.which === 40 && index < $items.length - 1) {\n      index++;\n    } // down\n\n\n    if (!~index) {\n      index = 0;\n    }\n\n    $items.eq(index).trigger('focus');\n  }; // DROPDOWN PLUGIN DEFINITION\n  // ==========================\n\n\n  function Plugin(option) {\n    return this.each(function () {\n      var $this = $(this);\n      var data = $this.data('bs.dropdown');\n      if (!data) $this.data('bs.dropdown', data = new Dropdown(this));\n      if (typeof option === 'string') data[option].call($this);\n    });\n  }\n\n  var old = $.fn.dropdown;\n  $.fn.dropdown = Plugin;\n  $.fn.dropdown.Constructor = Dropdown; // DROPDOWN NO CONFLICT\n  // ====================\n\n  $.fn.dropdown.noConflict = function () {\n    $.fn.dropdown = old;\n    return this;\n  }; // APPLY TO STANDARD DROPDOWN ELEMENTS\n  // ===================================\n\n\n  $(document).on('click.bs.dropdown.data-api', clearMenus).on('click.bs.dropdown.data-api', '.dropdown form', function (e) {\n    e.stopPropagation();\n  }).on('click.bs.dropdown.data-api', toggle, Dropdown.prototype.toggle).on('keydown.bs.dropdown.data-api', toggle, Dropdown.prototype.keydown).on('keydown.bs.dropdown.data-api', '.dropdown-menu', Dropdown.prototype.keydown);\n}((jquery__WEBPACK_IMPORTED_MODULE_0___default()));//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 15232 characters]\n//# sourceURL=webpack-internal:///./app/utils/bootstrap-dropdown.js\n");

/***/ }),

/***/ "./app/utils/bootstrap-transition.js":
/*!*******************************************!*\
  !*** ./app/utils/bootstrap-transition.js ***!
  \*******************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n\n+function ($) {\n  'use strict'; // CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/)\n  // ============================================================\n\n  function transitionEnd() {\n    var el = document.createElement('bootstrap');\n    var transEndEventNames = {\n      WebkitTransition: 'webkitTransitionEnd',\n      MozTransition: 'transitionend',\n      OTransition: 'oTransitionEnd otransitionend',\n      transition: 'transitionend'\n    };\n\n    for (var name in transEndEventNames) {\n      if (el.style[name] !== undefined) {\n        return {\n          end: transEndEventNames[name]\n        };\n      }\n    }\n\n    return false; // explicit for ie8 (  ._.)\n  } // http://blog.alexmaccaw.com/css-transitions\n\n\n  $.fn.emulateTransitionEnd = function (duration) {\n    var called = false;\n    var $el = this;\n    $(this).one('bsTransitionEnd', function () {\n      called = true;\n    });\n\n    var callback = function callback() {\n      if (!called) $($el).trigger($.support.transition.end);\n    };\n\n    setTimeout(callback, duration);\n    return this;\n  };\n\n  $(function () {\n    $.support.transition = transitionEnd();\n    if (!$.support.transition) return;\n    $.event.special.bsTransitionEnd = {\n      bindType: $.support.transition.end,\n      delegateType: $.support.transition.end,\n      handle: function handle(e) {\n        if ($(e.target).is(this)) return e.handleObj.handler.apply(this, arguments);\n      }\n    };\n  });\n}((jquery__WEBPACK_IMPORTED_MODULE_0___default()));//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4920 characters]\n//# sourceURL=webpack-internal:///./app/utils/bootstrap-transition.js\n");

/***/ }),

/***/ "./app/utils/changelog.js":
/*!********************************!*\
  !*** ./app/utils/changelog.js ***!
  \********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* eslint-disable */\n\nvar TRIGGER = null;\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('click', '[data-remodal-changelog]', function (event) {\n  TRIGGER = event.currentTarget;\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('opened', '[data-remodal-id=\"changelog\"]', function () {\n  var instance = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=changelog]').data('remodal')];\n  instance.$modal.html('<div class=\"changelog-overflow center\" style=\"padding:5rem 0;text-align:center;\"><i class=\"fa fa-spinner fa-spin fa-3x fa-fw\"></i></div>');\n\n  if (!TRIGGER) {\n    return true;\n  }\n\n  var url = jquery__WEBPACK_IMPORTED_MODULE_0___default()(TRIGGER).data('remodalChangelog');\n  jquery__WEBPACK_IMPORTED_MODULE_0___default().ajax({\n    url: url\n  }).done(function (data) {\n    instance.$modal.html(data);\n  });\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('closed', '[data-remodal-id=\"changelog\"]', function () {\n  var instance = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-remodal-id=changelog]').data('remodal')];\n  instance.$modal.html('');\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL2NoYW5nZWxvZy5qcz83NjFjIl0sIm5hbWVzIjpbIlRSSUdHRVIiLCIkIiwiZG9jdW1lbnQiLCJvbiIsImV2ZW50IiwiY3VycmVudFRhcmdldCIsImluc3RhbmNlIiwiZGF0YSIsIiRtb2RhbCIsImh0bWwiLCJ1cmwiLCJkb25lIl0sIm1hcHBpbmdzIjoiOzs7QUFBQTtBQUNBO0FBRUEsSUFBSUEsT0FBTyxHQUFHLElBQWQ7QUFFQUMsNkNBQUMsQ0FBQ0MsUUFBRCxDQUFELENBQVlDLEVBQVosQ0FBZSxPQUFmLEVBQXdCLDBCQUF4QixFQUFvRCxVQUFDQyxLQUFELEVBQVc7QUFDM0RKLFNBQU8sR0FBR0ksS0FBSyxDQUFDQyxhQUFoQjtBQUNILENBRkQ7QUFJQUosNkNBQUMsQ0FBQ0MsUUFBRCxDQUFELENBQVlDLEVBQVosQ0FBZSxRQUFmLEVBQXlCLCtCQUF6QixFQUEwRCxZQUFNO0FBQzVELE1BQU1HLFFBQVEsR0FBR0wsOERBQUEsQ0FBaUJBLDZDQUFDLENBQUMsNkJBQUQsQ0FBRCxDQUFpQ00sSUFBakMsQ0FBc0MsU0FBdEMsQ0FBakIsQ0FBakI7QUFDQUQsVUFBUSxDQUFDRSxNQUFULENBQWdCQyxJQUFoQixDQUFxQiwwSUFBckI7O0FBQ0EsTUFBSSxDQUFDVCxPQUFMLEVBQWM7QUFBRSxXQUFPLElBQVA7QUFBYzs7QUFFOUIsTUFBTVUsR0FBRyxHQUFHVCw2Q0FBQyxDQUFDRCxPQUFELENBQUQsQ0FBV08sSUFBWCxDQUFnQixrQkFBaEIsQ0FBWjtBQUVBTixvREFBQSxDQUFPO0FBQUNTLE9BQUcsRUFBRUE7QUFBTixHQUFQLEVBQW1CQyxJQUFuQixDQUF3QixVQUFTSixJQUFULEVBQWU7QUFDbkNELFlBQVEsQ0FBQ0UsTUFBVCxDQUFnQkMsSUFBaEIsQ0FBcUJGLElBQXJCO0FBQ0gsR0FGRDtBQUdILENBVkQ7QUFZQU4sNkNBQUMsQ0FBQ0MsUUFBRCxDQUFELENBQVlDLEVBQVosQ0FBZSxRQUFmLEVBQXlCLCtCQUF6QixFQUEwRCxZQUFNO0FBQzVELE1BQU1HLFFBQVEsR0FBR0wsOERBQUEsQ0FBaUJBLDZDQUFDLENBQUMsNkJBQUQsQ0FBRCxDQUFpQ00sSUFBakMsQ0FBc0MsU0FBdEMsQ0FBakIsQ0FBakI7QUFDQUQsVUFBUSxDQUFDRSxNQUFULENBQWdCQyxJQUFoQixDQUFxQixFQUFyQjtBQUNILENBSEQiLCJmaWxlIjoiLi9hcHAvdXRpbHMvY2hhbmdlbG9nLmpzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiLyogZXNsaW50LWRpc2FibGUgKi9cbmltcG9ydCAkIGZyb20gJ2pxdWVyeSc7XG5cbmxldCBUUklHR0VSID0gbnVsbDtcblxuJChkb2N1bWVudCkub24oJ2NsaWNrJywgJ1tkYXRhLXJlbW9kYWwtY2hhbmdlbG9nXScsIChldmVudCkgPT4ge1xuICAgIFRSSUdHRVIgPSBldmVudC5jdXJyZW50VGFyZ2V0O1xufSk7XG5cbiQoZG9jdW1lbnQpLm9uKCdvcGVuZWQnLCAnW2RhdGEtcmVtb2RhbC1pZD1cImNoYW5nZWxvZ1wiXScsICgpID0+IHtcbiAgICBjb25zdCBpbnN0YW5jZSA9ICQucmVtb2RhbC5sb29rdXBbJCgnW2RhdGEtcmVtb2RhbC1pZD1jaGFuZ2Vsb2ddJykuZGF0YSgncmVtb2RhbCcpXTtcbiAgICBpbnN0YW5jZS4kbW9kYWwuaHRtbCgnPGRpdiBjbGFzcz1cImNoYW5nZWxvZy1vdmVyZmxvdyBjZW50ZXJcIiBzdHlsZT1cInBhZGRpbmc6NXJlbSAwO3RleHQtYWxpZ246Y2VudGVyO1wiPjxpIGNsYXNzPVwiZmEgZmEtc3Bpbm5lciBmYS1zcGluIGZhLTN4IGZhLWZ3XCI+PC9pPjwvZGl2PicpO1xuICAgIGlmICghVFJJR0dFUikgeyByZXR1cm4gdHJ1ZTsgfVxuXG4gICAgY29uc3QgdXJsID0gJChUUklHR0VSKS5kYXRhKCdyZW1vZGFsQ2hhbmdlbG9nJyk7XG5cbiAgICAkLmFqYXgoe3VybDogdXJsfSkuZG9uZShmdW5jdGlvbihkYXRhKSB7XG4gICAgICAgIGluc3RhbmNlLiRtb2RhbC5odG1sKGRhdGEpO1xuICAgIH0pO1xufSk7XG5cbiQoZG9jdW1lbnQpLm9uKCdjbG9zZWQnLCAnW2RhdGEtcmVtb2RhbC1pZD1cImNoYW5nZWxvZ1wiXScsICgpID0+IHtcbiAgICBjb25zdCBpbnN0YW5jZSA9ICQucmVtb2RhbC5sb29rdXBbJCgnW2RhdGEtcmVtb2RhbC1pZD1jaGFuZ2Vsb2ddJykuZGF0YSgncmVtb2RhbCcpXTtcbiAgICBpbnN0YW5jZS4kbW9kYWwuaHRtbCgnJyk7XG59KTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/utils/changelog.js\n");

/***/ }),

/***/ "./app/utils/colors.js":
/*!*****************************!*\
  !*** ./app/utils/colors.js ***!
  \*****************************/
/*! namespace exports */
/*! export hex2hsb [provided] [no usage info] [missing usage info prevents renaming] */
/*! export hex2rgb [provided] [no usage info] [missing usage info prevents renaming] */
/*! export hsb2hex [provided] [no usage info] [missing usage info prevents renaming] */
/*! export hsb2rgb [provided] [no usage info] [missing usage info prevents renaming] */
/*! export parseHex [provided] [no usage info] [missing usage info prevents renaming] */
/*! export rgb2hex [provided] [no usage info] [missing usage info prevents renaming] */
/*! export rgb2hsb [provided] [no usage info] [missing usage info prevents renaming] */
/*! export rgbstr2hex [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"parseHex\": () => /* binding */ parseHex,\n/* harmony export */   \"hsb2rgb\": () => /* binding */ hsb2rgb,\n/* harmony export */   \"rgb2hex\": () => /* binding */ rgb2hex,\n/* harmony export */   \"rgbstr2hex\": () => /* binding */ rgbstr2hex,\n/* harmony export */   \"hsb2hex\": () => /* binding */ hsb2hex,\n/* harmony export */   \"hex2hsb\": () => /* binding */ hex2hsb,\n/* harmony export */   \"rgb2hsb\": () => /* binding */ rgb2hsb,\n/* harmony export */   \"hex2rgb\": () => /* binding */ hex2rgb\n/* harmony export */ });\n// Parses a string and returns a valid hex string when possible\n// parseHex('#fff') => '#ffffff'\nvar parseHex = function parseHex(string) {\n  string = string.replace(/[^A-F0-9]/ig, '');\n  if (string.length !== 3 && string.length !== 6) return '';\n\n  if (string.length === 3) {\n    string = string[0] + string[0] + string[1] + string[1] + string[2] + string[2];\n  }\n\n  return '#' + string.toLowerCase();\n}; // Converts an HSB object to an RGB object\n// hsb2rgb({h: 0, s: 0, b: 100}) => {r: 255, g: 255, b: 255}\n\nvar hsb2rgb = function hsb2rgb(hsb) {\n  var rgb = {};\n  var h = Math.round(hsb.h);\n  var s = Math.round(hsb.s * 255 / 100);\n  var v = Math.round(hsb.b * 255 / 100);\n\n  if (s === 0) {\n    rgb.r = rgb.g = rgb.b = v;\n  } else {\n    var t1 = v;\n    var t2 = (255 - s) * v / 255;\n    var t3 = (t1 - t2) * (h % 60) / 60;\n    if (h === 360) h = 0;\n\n    if (h < 60) {\n      rgb.r = t1;\n      rgb.b = t2;\n      rgb.g = t2 + t3;\n    } else if (h < 120) {\n      rgb.g = t1;\n      rgb.b = t2;\n      rgb.r = t1 - t3;\n    } else if (h < 180) {\n      rgb.g = t1;\n      rgb.r = t2;\n      rgb.b = t2 + t3;\n    } else if (h < 240) {\n      rgb.b = t1;\n      rgb.r = t2;\n      rgb.g = t1 - t3;\n    } else if (h < 300) {\n      rgb.b = t1;\n      rgb.g = t2;\n      rgb.r = t2 + t3;\n    } else if (h < 360) {\n      rgb.r = t1;\n      rgb.g = t2;\n      rgb.b = t1 - t3;\n    } else {\n      rgb.r = 0;\n      rgb.g = 0;\n      rgb.b = 0;\n    }\n  }\n\n  return {\n    r: Math.round(rgb.r),\n    g: Math.round(rgb.g),\n    b: Math.round(rgb.b)\n  };\n}; // Converts an RGB object to a HEX string\n// rgb2hex({r: 255, g: 255, b: 255}) => #ffffff\n\nvar rgb2hex = function rgb2hex(rgb) {\n  var hex = [rgb.r.toString(16), rgb.g.toString(16), rgb.b.toString(16)];\n  hex.forEach(function (val, nr) {\n    if (val.length === 1) hex[nr] = '0' + val;\n  });\n  return '#' + hex.join('');\n}; // Converts and RGB(a) string to a HEX string\n// rgbstr2hex('rgba(255, 255, 255, 0.5)') => #ffffff\n\nvar rgbstr2hex = function rgbstr2hex(rgb) {\n  rgb = rgb.match(/^rgba?[\\s+]?\\([\\s+]?(\\d+)[\\s+]?,[\\s+]?(\\d+)[\\s+]?,[\\s+]?(\\d+)[\\s+]?/i);\n  return rgb && rgb.length === 4 ? '#' + ('0' + parseInt(rgb[1], 10).toString(16)).slice(-2) + ('0' + parseInt(rgb[2], 10).toString(16)).slice(-2) + ('0' + parseInt(rgb[3], 10).toString(16)).slice(-2) : '';\n}; // Converts an HSB object to a HEX string\n// hsb2hex({h: 0, s: 0, b: 100}) => #ffffff\n\nvar hsb2hex = function hsb2hex(hsb) {\n  return rgb2hex(hsb2rgb(hsb));\n}; // Converts a HEX string to an HSB object\n// hex2hsb('#ffffff') => {h: 0, s: 0, b: 100}\n\nvar hex2hsb = function hex2hsb(hex) {\n  var hsb = rgb2hsb(hex2rgb(hex));\n  if (hsb.s === 0) hsb.h = 360;\n  return hsb;\n}; // Converts an RGB object to an HSB object\n// rgb2hsb({r: 255, g: 255, b: 255}) => {h: 0, s: 0, b: 100}\n\nvar rgb2hsb = function rgb2hsb(rgb) {\n  var hsb = {\n    h: 0,\n    s: 0,\n    b: 0\n  };\n  var min = Math.min(rgb.r, rgb.g, rgb.b);\n  var max = Math.max(rgb.r, rgb.g, rgb.b);\n  var delta = max - min;\n  hsb.b = max;\n  hsb.s = max !== 0 ? 255 * delta / max : 0;\n\n  if (hsb.s !== 0) {\n    if (rgb.r === max) {\n      hsb.h = (rgb.g - rgb.b) / delta;\n    } else if (rgb.g === max) {\n      hsb.h = 2 + (rgb.b - rgb.r) / delta;\n    } else {\n      hsb.h = 4 + (rgb.r - rgb.g) / delta;\n    }\n  } else {\n    hsb.h = -1;\n  }\n\n  hsb.h *= 60;\n\n  if (hsb.h < 0) {\n    hsb.h += 360;\n  }\n\n  hsb.s *= 100 / 255;\n  hsb.b *= 100 / 255;\n  return hsb;\n}; // Converts a HEX string to an RGB object\n// hex2rgb('#ffffff') => {r: 255, g: 255, b: 255}\n\nvar hex2rgb = function hex2rgb(hex) {\n  hex = parseInt(hex.indexOf('#') > -1 ? hex.substring(1) : hex, 16);\n  return {\n    /* jshint ignore:start */\n    r: hex >> 16,\n    g: (hex & 0x00FF00) >> 8,\n    b: hex & 0x0000FF\n    /* jshint ignore:end */\n\n  };\n};//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 13480 characters]\n//# sourceURL=webpack-internal:///./app/utils/colors.js\n");

/***/ }),

/***/ "./app/utils/cron-ui.js":
/*!******************************!*\
  !*** ./app/utils/cron-ui.js ***!
  \******************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\nfunction _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\n/* eslint-disable */\n\n/*\n * This file is part of the Arnapou jqCron package.\n *\n * (c) Arnaud Buathier <arnaud@arnapou.net>\n *\n * For the full copyright and license information, please view the LICENSE\n * file that was distributed with this source code.\n */\n\n/**\n * Default settings\n */\n\nvar jqCronDefaultSettings = {\n  texts: {},\n  monthdays: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31],\n  hours: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23],\n  hour_labels: [\"0\", \"1\", \"2\", \"3\", \"4\", \"5\", \"6\", \"7\", \"8\", \"9\", \"10\", \"11\", \"12\", \"13\", \"14\", \"15\", \"16\", \"17\", \"18\", \"19\", \"20\", \"21\", \"22\", \"23\"],\n  minutes: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59],\n  lang: 'en',\n  enabled_minute: false,\n  enabled_hour: true,\n  enabled_day: true,\n  enabled_week: true,\n  enabled_month: true,\n  enabled_year: true,\n  multiple_dom: false,\n  multiple_month: false,\n  multiple_mins: false,\n  multiple_dow: false,\n  multiple_time_hours: false,\n  multiple_time_minutes: false,\n  numeric_zero_pad: false,\n  default_period: 'day',\n  default_value: '',\n  no_reset_button: true,\n  disabled: false,\n  bind_to: null,\n  bind_method: {\n    set: function set($element, value) {\n      $element.is(':input') ? $element.val(value) : $element.data('jqCronValue', value);\n    },\n    get: function get($element) {\n      return $element.is(':input') ? $element.val() : $element.data('jqCronValue');\n    }\n  }\n};\n/**\n * Custom extend of json for jqCron settings.\n * We don't use jQuery.extend because simple extend does not fit our needs, and deep extend has a bad\n * feature for us : it replaces keys of \"Arrays\" instead of replacing the full array.\n */\n\n(function ($) {\n  var extend = function extend(dst, src) {\n    for (var i in src) {\n      if ($.isPlainObject(src[i])) {\n        dst[i] = extend(dst[i] && $.isPlainObject(dst[i]) ? dst[i] : {}, src[i]);\n      } else if ($.isArray(src[i])) {\n        dst[i] = src[i].slice(0);\n      } else if (src[i] !== undefined) {\n        dst[i] = src[i];\n      }\n    }\n\n    return dst;\n  };\n\n  this.jqCronMergeSettings = function (obj) {\n    return extend(extend({}, jqCronDefaultSettings), obj || {});\n  };\n}).call(window, (jquery__WEBPACK_IMPORTED_MODULE_0___default()));\n/**\n * Shortcut to get the instance of jqCron instance from one jquery object\n */\n\n(function ($) {\n  $.fn.jqCronGetInstance = function () {\n    return this.data('jqCron');\n  };\n}).call(window, (jquery__WEBPACK_IMPORTED_MODULE_0___default()));\n/**\n * Main plugin\n */\n\n(function ($) {\n  $.fn.jqCron = function (settings) {\n    var saved_settings = settings;\n    return this.each(function () {\n      var cron, saved;\n      var $this = $(this);\n      var settings = jqCronMergeSettings(saved_settings); // clone settings\n\n      var translations = settings.texts[settings.lang];\n\n      if (_typeof(translations) !== 'object' || $.isEmptyObject(translations)) {\n        console && console.error('Missing translations for language \"' + settings.lang + '\". ' + 'Please include jqCron.' + settings.lang + '.js or manually provide ' + 'the necessary translations when calling $.fn.jqCron().');\n        return;\n      }\n\n      if (!settings.jquery_container) {\n        if ($this.is(':container')) {\n          settings.jquery_element = $this.uniqueId('jqCron');\n        } else if ($this.is(':autoclose')) {\n          // delete already generated dom if exists\n          if ($this.next('.jqCron').length == 1) {\n            $this.next('.jqCron').remove();\n          } // generate new\n\n\n          settings.jquery_element = $('<span class=\"jqCron\"></span>').uniqueId('jqCron').insertAfter($this);\n        } else {\n          console && console.error(settings.texts[settings.lang].error1.replace('%s', this.tagName));\n          return;\n        }\n      } // autoset bind_to if it is an input\n\n\n      if ($this.is(':input')) {\n        settings.bind_to = settings.bind_to || $this;\n      } // init cron object\n\n\n      if (settings.bind_to) {\n        if (settings.bind_to.is(':input')) {\n          // auto bind from input to object if an input, textarea ...\n          settings.bind_to.blur(function () {\n            var value = settings.bind_method.get(settings.bind_to);\n            $this.jqCronGetInstance().setCron(value);\n          });\n        }\n\n        saved = settings.bind_method.get(settings.bind_to);\n        cron = new jqCron(settings);\n        cron.setCron(saved);\n      } else {\n        cron = new jqCron(settings);\n      }\n\n      $(this).data('jqCron', cron);\n    });\n  };\n}).call(window, (jquery__WEBPACK_IMPORTED_MODULE_0___default()));\n/**\n * jqCron class\n */\n\n(function ($) {\n  var jqCronInstances = [];\n\n  function jqCron(settings) {\n    var _initialized = false;\n\n    var _self = this;\n\n    var _$elt = this;\n\n    var _$obj = $('<span class=\"jqCron-container\"></span>');\n\n    var _$blocks = $('<span class=\"jqCron-blocks\"></span>');\n\n    var _$blockPERIOD = $('<span class=\"jqCron-period\"></span>');\n\n    var _$blockDOM = $('<span class=\"jqCron-dom\"></span>');\n\n    var _$blockMONTH = $('<span class=\"jqCron-month\"></span>');\n\n    var _$blockMINS = $('<span class=\"jqCron-mins\"></span>');\n\n    var _$blockDOW = $('<span class=\"jqCron-dow\"></span>');\n\n    var _$blockTIME = $('<span class=\"jqCron-time\"></span>');\n\n    var _$cross = $('<span class=\"jqCron-cross\">&#10008;</span>');\n\n    var _selectors = [];\n\n    var _selectorPeriod, _selectorMins, _selectorTimeH, _selectorTimeM, _selectorDow, _selectorDom, _selectorMonth; // instanciate a new selector\n\n\n    function newSelector($block, multiple, type) {\n      var selector = new jqCronSelector(_self, $block, multiple, type);\n      selector.$.bind('selector:open', function () {\n        // we close all opened selectors of all other jqCron\n        for (var n = jqCronInstances.length; n--;) {\n          if (jqCronInstances[n] != _self) {\n            jqCronInstances[n].closeSelectors();\n          } else {\n            // we close all other opened selectors of this jqCron\n            for (var o = _selectors.length; o--;) {\n              if (_selectors[o] != selector) {\n                _selectors[o].close();\n              }\n            }\n          }\n        }\n      });\n      selector.$.bind('selector:change', function () {\n        var boundChanged = false; // don't propagate if not initialized\n\n        if (!_initialized) return; // bind data between two minute selectors (only if they have the same multiple settings)\n\n        if (settings.multiple_mins == settings.multiple_time_minutes) {\n          if (selector == _selectorMins) {\n            boundChanged = _selectorTimeM.setValue(_selectorMins.getValue());\n          } else if (selector == _selectorTimeM) {\n            boundChanged = _selectorMins.setValue(_selectorTimeM.getValue());\n          }\n        } // we propagate the change event to the main object\n\n\n        boundChanged || _$obj.trigger('cron:change', _self.getCron());\n      });\n\n      _selectors.push(selector);\n\n      return selector;\n    } // disable the selector\n\n\n    this.disable = function () {\n      _$obj.addClass('disable');\n\n      settings.disable = true;\n\n      _self.closeSelectors();\n    }; // return if the selector is disabled\n\n\n    this.isDisabled = function () {\n      return settings.disable == true;\n    }; // enable the selector\n\n\n    this.enable = function () {\n      _$obj.removeClass('disable');\n\n      settings.disable = false;\n    }; // get cron value\n\n\n    this.getCron = function () {\n      var period = _selectorPeriod.getValue();\n\n      var items = ['*', '*', '*', '*', '*'];\n\n      if (period == 'hour') {\n        items[0] = _selectorMins.getCronValue();\n      }\n\n      if (period == 'day' || period == 'week' || period == 'month' || period == 'year') {\n        items[0] = _selectorTimeM.getCronValue();\n        items[1] = _selectorTimeH.getCronValue();\n      }\n\n      if (period == 'month' || period == 'year') {\n        items[2] = _selectorDom.getCronValue();\n      }\n\n      if (period == 'year') {\n        items[3] = _selectorMonth.getCronValue();\n      }\n\n      if (period == 'week') {\n        items[4] = _selectorDow.getCronValue();\n      }\n\n      return items.join(' ');\n    }; // set cron (string like * * * * *)\n\n\n    this.setCron = function (str) {\n      if (!str) return;\n\n      try {\n        str = str.replace(/\\s+/g, ' ').replace(/^ +/, '').replace(/ +$/, ''); // sanitize\n\n        var mask = str.replace(/[^\\* ]/g, '-').replace(/-+/g, '-').replace(/ +/g, '');\n        var items = str.split(' ');\n        if (items.length != 5) _self.error(_self.getText('error2'));\n\n        if (mask == '*****') {\n          // 1 possibility\n          _selectorPeriod.setValue('minute');\n        } else if (mask == '-****') {\n          // 1 possibility\n          _selectorPeriod.setValue('hour');\n\n          _selectorMins.setCronValue(items[0]);\n\n          _selectorTimeM.setCronValue(items[0]);\n        } else if (mask.substring(2, mask.length) == '***') {\n          // 4 possibilities\n          _selectorPeriod.setValue('day');\n\n          _selectorMins.setCronValue(items[0]);\n\n          _selectorTimeM.setCronValue(items[0]);\n\n          _selectorTimeH.setCronValue(items[1]);\n        } else if (mask.substring(2, mask.length) == '-**') {\n          // 4 possibilities\n          _selectorPeriod.setValue('month');\n\n          _selectorMins.setCronValue(items[0]);\n\n          _selectorTimeM.setCronValue(items[0]);\n\n          _selectorTimeH.setCronValue(items[1]);\n\n          _selectorDom.setCronValue(items[2]);\n        } else if (mask.substring(2, mask.length) == '**-') {\n          // 4 possibilities\n          _selectorPeriod.setValue('week');\n\n          _selectorMins.setCronValue(items[0]);\n\n          _selectorTimeM.setCronValue(items[0]);\n\n          _selectorTimeH.setCronValue(items[1]);\n\n          _selectorDow.setCronValue(items[4]);\n        } else if (mask.substring(3, mask.length) == '-*') {\n          // 8 possibilities\n          _selectorPeriod.setValue('year');\n\n          _selectorMins.setCronValue(items[0]);\n\n          _selectorTimeM.setCronValue(items[0]);\n\n          _selectorTimeH.setCronValue(items[1]);\n\n          _selectorDom.setCronValue(items[2]);\n\n          _selectorMonth.setCronValue(items[3]);\n        } else {\n          _self.error(_self.getText('error4'));\n        }\n\n        _self.clearError();\n      } catch (e) {}\n    }; // close all child selectors\n\n\n    this.closeSelectors = function () {\n      for (var n = _selectors.length; n--;) {\n        _selectors[n].close();\n      }\n    }; // get the main element id\n\n\n    this.getId = function () {\n      return _$elt.attr('id');\n    }; // get the translated text\n\n\n    this.getText = function (key) {\n      var text = settings.texts[settings.lang][key] || null;\n\n      if (typeof text == \"string\" && text.match('<b')) {\n        text = text.replace(/(<b *\\/>)/gi, '</span><b /><span class=\"jqCron-text\">');\n        text = '<span class=\"jqCron-text\">' + text + '</span>';\n      }\n\n      return text;\n    }; // get the human readable text\n\n\n    this.getHumanText = function () {\n      var texts = [];\n\n      _$obj.find('> span > span:visible').find('.jqCron-text, .jqCron-selector > span').each(function () {\n        var text = $(this).text().replace(/\\s+$/g, '').replace(/^\\s+/g, '');\n        text && texts.push(text);\n      });\n\n      return texts.join(' ').replace(/\\s:\\s/g, ':');\n    }; // get settings\n\n\n    this.getSettings = function () {\n      return settings;\n    }; // display an error\n\n\n    this.error = function (msg) {\n      console && console.error('[jqCron Error] ' + msg);\n\n      _$obj.addClass('jqCron-error').attr('title', msg);\n\n      throw msg;\n    }; // clear error\n\n\n    this.clearError = function () {\n      _$obj.attr('title', '').removeClass('jqCron-error');\n    }; // clear\n\n\n    this.clear = function () {\n      _selectorDom.setValue([]);\n\n      _selectorDow.setValue([]);\n\n      _selectorMins.setValue([]);\n\n      _selectorMonth.setValue([]);\n\n      _selectorTimeH.setValue([]);\n\n      _selectorTimeM.setValue([]);\n\n      _self.triggerChange();\n    }; // init (called in constructor)\n\n\n    this.init = function () {\n      var n, i, labelsList, list;\n      if (_initialized) return;\n      settings = jqCronMergeSettings(settings);\n      settings.jquery_element || _self.error(_self.getText('error3'));\n      _$elt = settings.jquery_element;\n\n      _$elt.append(_$obj);\n\n      _$obj.data('id', settings.id);\n\n      _$obj.data('jqCron', _self);\n\n      _$obj.append(_$blocks);\n\n      settings.no_reset_button || _$obj.append(_$cross);\n      !settings.disable || _$obj.addClass('disable');\n\n      _$blocks.append(_$blockPERIOD);\n\n      if (/^(ko)$/i.test(settings.lang)) {\n        _$blocks.append(_$blockMONTH, _$blockDOM);\n      } else {\n        _$blocks.append(_$blockDOM, _$blockMONTH);\n      }\n\n      _$blocks.append(_$blockMINS);\n\n      _$blocks.append(_$blockDOW);\n\n      _$blocks.append(_$blockTIME); // various binding\n\n\n      _$cross.click(function () {\n        _self.isDisabled() || _self.clear();\n      }); // binding from cron to target\n\n\n      _$obj.bind('cron:change', function (evt, value) {\n        if (!settings.bind_to) return;\n        settings.bind_method.set && settings.bind_method.set(settings.bind_to, value);\n\n        _self.clearError();\n      }); // PERIOD\n\n\n      _$blockPERIOD.append(_self.getText('text_period'));\n\n      _selectorPeriod = newSelector(_$blockPERIOD, false, 'period');\n      settings.enabled_minute && _selectorPeriod.add('minute', _self.getText('name_minute'));\n      settings.enabled_hour && _selectorPeriod.add('hour', _self.getText('name_hour'));\n      settings.enabled_day && _selectorPeriod.add('day', _self.getText('name_day'));\n      settings.enabled_week && _selectorPeriod.add('week', _self.getText('name_week'));\n      settings.enabled_month && _selectorPeriod.add('month', _self.getText('name_month'));\n      settings.enabled_year && _selectorPeriod.add('year', _self.getText('name_year'));\n\n      _selectorPeriod.$.bind('selector:change', function (e, value) {\n        _$blockDOM.hide();\n\n        _$blockMONTH.hide();\n\n        _$blockMINS.hide();\n\n        _$blockDOW.hide();\n\n        _$blockTIME.hide();\n\n        if (value == 'hour') {\n          _$blockMINS.show();\n        } else if (value == 'day') {\n          _$blockTIME.show();\n        } else if (value == 'week') {\n          _$blockDOW.show();\n\n          _$blockTIME.show();\n        } else if (value == 'month') {\n          _$blockDOM.show();\n\n          _$blockTIME.show();\n        } else if (value == 'year') {\n          _$blockDOM.show();\n\n          _$blockMONTH.show();\n\n          _$blockTIME.show();\n        }\n      });\n\n      _selectorPeriod.setValue(settings.default_period); // MINS  (minutes)\n\n\n      _$blockMINS.append(_self.getText('text_mins'));\n\n      _selectorMins = newSelector(_$blockMINS, settings.multiple_mins, 'minutes');\n\n      for (i = 0, list = settings.minutes; i < list.length; i++) {\n        _selectorMins.add(list[i], list[i]);\n      } // TIME  (hour:min)\n\n\n      _$blockTIME.append(_self.getText('text_time'));\n\n      _selectorTimeH = newSelector(_$blockTIME, settings.multiple_time_hours, 'time_hours');\n\n      for (i = 0, list = settings.hours, labelsList = settings.hour_labels; i < list.length; i++) {\n        _selectorTimeH.add(list[i], labelsList[i]);\n      }\n\n      _selectorTimeM = newSelector(_$blockTIME, settings.multiple_time_minutes, 'time_minutes');\n\n      for (i = 0, list = settings.minutes; i < list.length; i++) {\n        _selectorTimeM.add(list[i], list[i]);\n      } // DOW  (day of week)\n\n\n      _$blockDOW.append(_self.getText('text_dow'));\n\n      _selectorDow = newSelector(_$blockDOW, settings.multiple_dow, 'day_of_week');\n\n      for (i = 0, list = _self.getText('weekdays'); i < list.length; i++) {\n        _selectorDow.add(i + 1, list[i]);\n      } // DOM  (day of month)\n\n\n      _$blockDOM.append(_self.getText('text_dom'));\n\n      _selectorDom = newSelector(_$blockDOM, settings.multiple_dom, 'day_of_month');\n\n      for (i = 0, list = settings.monthdays; i < list.length; i++) {\n        _selectorDom.add(list[i], list[i]);\n      } // MONTH  (day of week)\n\n\n      _$blockMONTH.append(_self.getText('text_month'));\n\n      _selectorMonth = newSelector(_$blockMONTH, settings.multiple_month, 'month');\n\n      for (i = 0, list = _self.getText('months'); i < list.length; i++) {\n        _selectorMonth.add(i + 1, list[i]);\n      } // close all selectors when we click in body\n\n\n      $('body').click(function () {\n        var i,\n            n = _selectors.length;\n\n        for (i = 0; i < n; i++) {\n          _selectors[i].close();\n        }\n      });\n      _initialized = true; // default value\n\n      if (settings.default_value) {\n        _self.setCron(settings.default_value);\n      }\n    }; // trigger a change event\n\n\n    this.triggerChange = function () {\n      _$obj.trigger('cron:change', _self.getCron());\n    }; // store instance in array\n\n\n    jqCronInstances.push(this); // expose main jquery object\n\n    this.$ = _$obj; // init\n\n    try {\n      this.init();\n\n      _self.triggerChange();\n    } catch (e) {}\n  }\n\n  this.jqCron = jqCron;\n}).call(window, (jquery__WEBPACK_IMPORTED_MODULE_0___default()));\n/**\n * jqCronSelector class\n */\n\n(function ($) {\n  function jqCronSelector(_cron, _$block, _multiple, _type) {\n    var _self = this;\n\n    var _$list = $('<ul class=\"jqCron-selector-list\"></ul>');\n\n    var _$title = $('<span class=\"jqCron-selector-title\"></span>');\n\n    var _$selector = $('<span class=\"jqCron-selector\"></span>');\n\n    var _values = {};\n    var _value = [];\n    var _hasNumericTexts = true;\n\n    var _numeric_zero_pad = _cron.getSettings().numeric_zero_pad; // return an array without doublon\n\n\n    function array_unique(l) {\n      var i = 0,\n          n = l.length,\n          k = {},\n          a = [];\n\n      while (i < n) {\n        k[l[i]] || (k[l[i]] =  true && a.push(l[i]));\n        i++;\n      }\n\n      return a;\n    } // get the value (an array if multiple, else a single value)\n\n\n    this.getValue = function () {\n      return _multiple ? _value : _value[0];\n    }; // get a correct string for cron\n\n\n    this.getCronValue = function () {\n      if (_value.length == 0) return '*';\n      var cron = [_value[0]],\n          i,\n          s = _value[0],\n          c = _value[0],\n          n = _value.length;\n\n      for (i = 1; i < n; i++) {\n        if (_value[i] == c + 1) {\n          c = _value[i];\n          cron[cron.length - 1] = s + '-' + c;\n        } else {\n          s = c = _value[i];\n          cron.push(c);\n        }\n      }\n\n      return cron.join(',');\n    }; // set the cron value\n\n\n    this.setCronValue = function (str) {\n      var values = [],\n          m,\n          i,\n          n;\n\n      if (str !== '*') {\n        while (str != '') {\n          // test \"*/n\" expression\n          m = str.match(/^\\*\\/([0-9]+),?/);\n\n          if (m && m.length == 2) {\n            for (i = 0; i <= 59; i += m[1] | 0) {\n              values.push(i);\n            }\n\n            str = str.replace(m[0], '');\n            continue;\n          } // test \"a-b/n\" expression\n\n\n          m = str.match(/^([0-9]+)-([0-9]+)\\/([0-9]+),?/);\n\n          if (m && m.length == 4) {\n            for (i = m[1] | 0; i <= (m[2] | 0); i += m[3] | 0) {\n              values.push(i);\n            }\n\n            str = str.replace(m[0], '');\n            continue;\n          } // test \"a-b\" expression\n\n\n          m = str.match(/^([0-9]+)-([0-9]+),?/);\n\n          if (m && m.length == 3) {\n            for (i = m[1] | 0; i <= (m[2] | 0); i++) {\n              values.push(i);\n            }\n\n            str = str.replace(m[0], '');\n            continue;\n          } // test \"c\" expression\n\n\n          m = str.match(/^([0-9]+),?/);\n\n          if (m && m.length == 2) {\n            values.push(m[1] | 0);\n            str = str.replace(m[0], '');\n            continue;\n          } // something goes wrong in the expression\n\n\n          return;\n        }\n      }\n\n      _self.setValue(values);\n    }; // close the selector\n\n\n    this.close = function () {\n      _$selector.trigger('selector:close');\n    }; // open the selector\n\n\n    this.open = function () {\n      _$selector.trigger('selector:open');\n    }; // whether the selector is open\n\n\n    this.isOpened = function () {\n      return _$list.is(':visible');\n    }; // add a selected value to the list\n\n\n    this.addValue = function (key) {\n      var values = _multiple ? _value.slice(0) : []; // clone array\n\n      values.push(key);\n\n      _self.setValue(values);\n    }; // remove a selected value from the list\n\n\n    this.removeValue = function (key) {\n      if (_multiple) {\n        var i,\n            newValue = [];\n\n        for (i = 0; i < _value.length; i++) {\n          if (key != [_value[i]]) {\n            newValue.push(_value[i]);\n          }\n        }\n\n        _self.setValue(newValue);\n      } else {\n        _self.clear();\n      }\n    }; // set the selected value(s) of the list\n\n\n    this.setValue = function (keys) {\n      var i,\n          newKeys = [],\n          saved = _value.join(' ');\n\n      if (!$.isArray(keys)) keys = [keys];\n\n      _$list.find('li').removeClass('selected');\n\n      keys = array_unique(keys);\n      keys.sort(function (a, b) {\n        var ta = _typeof(a);\n\n        var tb = _typeof(b);\n\n        if (ta == tb && ta == \"number\") return a - b;else return String(a) == String(b) ? 0 : String(a) < String(b) ? -1 : 1;\n      });\n\n      if (_multiple) {\n        for (i = 0; i < keys.length; i++) {\n          if (keys[i] in _values) {\n            _values[keys[i]].addClass('selected');\n\n            newKeys.push(keys[i]);\n          }\n        }\n      } else {\n        if (keys[0] in _values) {\n          _values[keys[0]].addClass('selected');\n\n          newKeys.push(keys[0]);\n        }\n      } // remove unallowed values\n\n\n      _value = newKeys;\n\n      if (saved != _value.join(' ')) {\n        _$selector.trigger('selector:change', _multiple ? keys : keys[0]);\n\n        return true;\n      }\n\n      return false;\n    }; // get the title text\n\n\n    this.getTitleText = function () {\n      var getValueText = function getValueText(key) {\n        return key in _values ? _values[key].text() : key;\n      };\n\n      if (_value.length == 0) {\n        return _cron.getText('empty_' + _type) || _cron.getText('empty');\n      }\n\n      var cron = [getValueText(_value[0])],\n          i,\n          s = _value[0],\n          c = _value[0],\n          n = _value.length;\n\n      for (i = 1; i < n; i++) {\n        if (_value[i] == c + 1) {\n          c = _value[i];\n          cron[cron.length - 1] = getValueText(s) + '-' + getValueText(c);\n        } else {\n          s = c = _value[i];\n          cron.push(getValueText(c));\n        }\n      }\n\n      return cron.join(',');\n    }; // clear list\n\n\n    this.clear = function () {\n      _values = {};\n\n      _self.setValue([]);\n\n      _$list.empty();\n    }; // add a (key, value) pair\n\n\n    this.add = function (key, value) {\n      if (!(value + '').match(/^[0-9]+$/)) _hasNumericTexts = false;\n\n      if (_numeric_zero_pad && _hasNumericTexts && value < 10) {\n        value = '0' + value;\n      }\n\n      var $item = $('<li>' + value + '</li>');\n\n      _$list.append($item);\n\n      _values[key] = $item;\n      $item.click(function () {\n        if (_multiple && $(this).hasClass('selected')) {\n          _self.removeValue(key);\n        } else {\n          _self.addValue(key);\n\n          if (!_multiple) _self.close();\n        }\n      });\n    }; // expose main jquery object\n\n\n    this.$ = _$selector; // constructor\n\n    _$block.find('b:eq(0)').after(_$selector).remove();\n\n    _$selector.addClass('jqCron-selector-' + _$block.find('.jqCron-selector').length).append(_$title).append(_$list).bind('selector:open', function () {\n      if (_hasNumericTexts) {\n        var nbcols = 1,\n            n = _$list.find('li').length;\n\n        if (n > 5 && n <= 16) nbcols = 2;else if (n > 16 && n <= 23) nbcols = 3;else if (n > 23 && n <= 40) nbcols = 4;else if (n > 40) nbcols = 5;\n\n        _$list.addClass('cols' + nbcols);\n      }\n\n      _$list.show();\n    }).bind('selector:close', function () {\n      _$list.hide();\n    }).bind('selector:change', function () {\n      _$title.html(_self.getTitleText());\n    }).click(function (e) {\n      e.stopPropagation();\n    }).trigger('selector:change');\n\n    $.fn.disableSelection && _$selector.disableSelection(); // only work with jQuery UI\n\n    _$title.click(function (e) {\n      _self.isOpened() || _cron.isDisabled() ? _self.close() : _self.open();\n    });\n\n    _self.close();\n\n    _self.clear();\n  }\n\n  this.jqCronSelector = jqCronSelector;\n}).call(window, (jquery__WEBPACK_IMPORTED_MODULE_0___default()));\n/**\n * Generate unique id for each element.\n * Skip elements which have already an id.\n */\n\n(function ($) {\n  var jqUID = 0;\n\n  var jqGetUID = function jqGetUID(prefix) {\n    var id;\n\n    while (1) {\n      jqUID++;\n      id = (prefix || 'JQUID') + '' + jqUID;\n      if (!document.getElementById(id)) return id;\n    }\n  };\n\n  $.fn.uniqueId = function (prefix) {\n    return this.each(function () {\n      if ($(this).attr('id')) return;\n      var id = jqGetUID(prefix);\n      $(this).attr('id', id);\n    });\n  };\n}).call(window, (jquery__WEBPACK_IMPORTED_MODULE_0___default()));\n/**\n * Extends jQuery selectors with new block selector\n */\n\n(function ($) {\n  $.extend($.expr[':'], {\n    container: function container(a) {\n      return (a.tagName + '').toLowerCase() in {\n        a: 1,\n        abbr: 1,\n        acronym: 1,\n        address: 1,\n        b: 1,\n        big: 1,\n        blockquote: 1,\n        button: 1,\n        cite: 1,\n        code: 1,\n        dd: 1,\n        del: 1,\n        dfn: 1,\n        div: 1,\n        dt: 1,\n        em: 1,\n        fieldset: 1,\n        form: 1,\n        h1: 1,\n        h2: 1,\n        h3: 1,\n        h4: 1,\n        h5: 1,\n        h6: 1,\n        i: 1,\n        ins: 1,\n        kbd: 1,\n        label: 1,\n        li: 1,\n        p: 1,\n        pre: 1,\n        q: 1,\n        samp: 1,\n        small: 1,\n        span: 1,\n        strong: 1,\n        sub: 1,\n        sup: 1,\n        td: 1,\n        tt: 1\n      };\n    },\n    autoclose: function autoclose(a) {\n      return (a.tagName + '').toLowerCase() in {\n        area: 1,\n        base: 1,\n        basefont: 1,\n        br: 1,\n        col: 1,\n        frame: 1,\n        hr: 1,\n        img: 1,\n        input: 1,\n        link: 1,\n        meta: 1,\n        param: 1\n      };\n    }\n  });\n}).call(window, (jquery__WEBPACK_IMPORTED_MODULE_0___default()));//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 87104 characters]\n//# sourceURL=webpack-internal:///./app/utils/cron-ui.js\n");

/***/ }),

/***/ "./app/utils/finderjs.js":
/*!*******************************!*\
  !*** ./app/utils/finderjs.js ***!
  \*******************************/
/*! namespace exports */
/*! export DEFAULTS [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"DEFAULTS\": () => /* binding */ DEFAULTS,\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var eventemitter3__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! eventemitter3 */ \"./node_modules/eventemitter3/index.js\");\n/* harmony import */ var eventemitter3__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(eventemitter3__WEBPACK_IMPORTED_MODULE_1__);\nfunction _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n/**\n * (c) Trilby Media, LLC\n * Author Djamil Legato\n *\n * Based on Mark Matyas's Finderjs\n * MIT License\n */\n\n\nvar DEFAULTS = {\n  labelKey: 'name',\n  valueKey: 'value',\n  // new\n  childKey: 'children',\n  iconKey: 'icon',\n  // new\n  itemKey: 'item-key',\n  // new\n  pathBar: true,\n  className: {\n    container: 'fjs-container',\n    pathBar: 'fjs-path-bar',\n    col: 'fjs-col',\n    list: 'fjs-list',\n    item: 'fjs-item',\n    active: 'fjs-active',\n    children: 'fjs-has-children',\n    url: 'fjs-url',\n    itemPrepend: 'fjs-item-prepend',\n    itemContent: 'fjs-item-content',\n    itemAppend: 'fjs-item-append'\n  }\n};\n\nvar Finder = /*#__PURE__*/function () {\n  function Finder(container, data, options) {\n    var _this = this;\n\n    _classCallCheck(this, Finder);\n\n    this.$emitter = new (eventemitter3__WEBPACK_IMPORTED_MODULE_1___default())();\n    this.container = jquery__WEBPACK_IMPORTED_MODULE_0___default()(container);\n    this.data = data;\n    this.config = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, DEFAULTS, options); // dom events\n\n    this.container.on('click', this.clickEvent.bind(this));\n    this.container.on('keydown', this.keydownEvent.bind(this)); // internal events\n\n    this.$emitter.on('item-selected', this.itemSelected.bind(this));\n    this.$emitter.on('create-column', this.addColumn.bind(this));\n    this.$emitter.on('navigate', this.navigate.bind(this));\n    this.$emitter.on('go-to', this.goTo.bind(this, this.data));\n    this.container.addClass(this.config.className.container).attr('tabindex', 0);\n    this.createColumn(this.data);\n\n    if (this.config.pathBar) {\n      this.pathBar = this.createPathBar();\n      this.pathBar.on('click', '[data-breadcrumb-node]', function (event) {\n        event.preventDefault();\n        var location = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget).data('breadcrumbNode');\n\n        _this.goTo(_this.data, location);\n      });\n    } // '' is <Root>\n\n\n    if (this.config.defaultPath || this.config.defaultPath === '') {\n      this.goTo(this.data, this.config.defaultPath);\n    }\n  }\n\n  _createClass(Finder, [{\n    key: \"reload\",\n    value: function reload() {\n      var data = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.data;\n      this.createColumn(data); // '' is <Root>\n\n      if (this.config.defaultPath || this.config.defaultPath === '') {\n        this.goTo(data, this.config.defaultPath);\n      }\n    }\n  }, {\n    key: \"createColumn\",\n    value: function createColumn(data, parent) {\n      var _this2 = this;\n\n      var callback = function callback(data) {\n        return _this2.createColumn(data, parent);\n      };\n\n      if (typeof data === 'function') {\n        data.call(this, parent, callback);\n      } else if (Array.isArray(data) || _typeof(data) === 'object') {\n        if (_typeof(data) === 'object') {\n          data = Array.from(data);\n        }\n\n        var list = this.createList(data);\n        var div = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div />');\n        div.append(list).addClass(this.config.className.col);\n        this.$emitter.emit('create-column', div);\n        return div;\n      } else {\n        throw new Error('Unknown data type');\n      }\n    }\n  }, {\n    key: \"createPathBar\",\n    value: function createPathBar() {\n      this.container.siblings(\".\".concat(this.config.className.pathBar)).remove();\n      var pathBar = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"<div class=\\\"\".concat(this.config.className.pathBar, \"\\\" />\"));\n      pathBar.insertAfter(this.container);\n      return pathBar;\n    }\n  }, {\n    key: \"clickEvent\",\n    value: function clickEvent(event) {\n      event.stopPropagation();\n      event.preventDefault();\n      var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n      var column = target.closest(\".\".concat(this.config.className.col));\n      var item = target.closest(\".\".concat(this.config.className.item));\n\n      if (item.length) {\n        this.$emitter.emit('item-selected', {\n          column: column,\n          item: item\n        });\n      }\n    }\n  }, {\n    key: \"keydownEvent\",\n    value: function keydownEvent(event) {\n      var codes = {\n        37: 'left',\n        38: 'up',\n        39: 'right',\n        40: 'down'\n      };\n\n      if (event.keyCode in codes) {\n        event.stopPropagation();\n        event.preventDefault();\n        this.$emitter.emit('navigate', {\n          direction: codes[event.keyCode]\n        });\n      }\n    }\n  }, {\n    key: \"itemSelected\",\n    value: function itemSelected(value) {\n      var element = value.item;\n\n      if (!element.length) {\n        return false;\n      }\n\n      var item = element[0]._item;\n      var column = value.column;\n      var data = item[this.config.childKey] || this.data;\n      var active = jquery__WEBPACK_IMPORTED_MODULE_0___default()(column).find(\".\".concat(this.config.className.active));\n\n      if (active.length) {\n        active.removeClass(this.config.className.active);\n      }\n\n      element.addClass(this.config.className.active);\n      column.nextAll().remove(); // ?!?!?\n\n      this.container[0].focus();\n      window.scrollTo(window.pageXOffset, window.pageYOffset);\n      this.updatePathBar();\n      var newColumn;\n\n      if (data) {\n        newColumn = this.createColumn(data, item);\n        this.$emitter.emit('interior-selected', item);\n      } else {\n        this.$emitter.emit('leaf-selected', item);\n      }\n\n      return newColumn;\n    }\n  }, {\n    key: \"addColumn\",\n    value: function addColumn(column) {\n      this.container.append(column);\n      this.$emitter.emit('column-created', column);\n    }\n  }, {\n    key: \"navigate\",\n    value: function navigate(value) {\n      var active = this.findLastActive();\n      var direction = value.direction;\n      var column;\n      var item;\n      var target;\n\n      if (active) {\n        item = active.item;\n        column = active.column;\n\n        if (direction === 'up' && item.prev().length) {\n          target = item.prev();\n        } else if (direction === 'down' && item.next().length) {\n          target = item.next();\n        } else if (direction === 'right' && column.next().length) {\n          column = column.next();\n          target = column.find(\".\".concat(this.config.className.item)).first();\n        } else if (direction === 'left' && column.prev().length) {\n          column = column.prev();\n          target = column.find(\".\".concat(this.config.className.active)).first() || column.find(\".\".concat(this.config.className.item));\n        }\n      } else {\n        column = this.container.find(\".\".concat(this.config.className.col)).first();\n        target = column.find(\".\".concat(this.config.className.item)).first();\n      }\n\n      if (target) {\n        this.$emitter.emit('item-selected', {\n          column: column,\n          item: target\n        });\n      }\n    }\n  }, {\n    key: \"goTo\",\n    value: function goTo(data, path) {\n      var _this3 = this;\n\n      path = Array.isArray(path) ? path : path.split('/').map(function (bit) {\n        return bit.trim();\n      }).filter(Boolean);\n\n      if (path.length) {\n        this.container.children().remove();\n      }\n\n      if (typeof data === 'function') {\n        data.call(this, null, function (data) {\n          return _this3.selectPath(path, data);\n        });\n      } else {\n        this.selectPath(path, data);\n      }\n    }\n  }, {\n    key: \"selectPath\",\n    value: function selectPath(path, data, column) {\n      var _this4 = this;\n\n      column = column || (path.length ? this.createColumn(data) : this.container.find(\"> .\".concat(this.config.className.col)));\n      var current = path[0] || '';\n      var children = data.find(function (item) {\n        return item[_this4.config.itemKey] === current;\n      });\n      var newColumn = this.itemSelected({\n        column: column,\n        item: column.find(\"[data-fjs-item=\\\"\".concat(current, \"\\\"]\")).first()\n      });\n      path.shift();\n\n      if (path.length && children) {\n        this.selectPath(path, children[this.config.childKey], newColumn);\n      }\n    }\n  }, {\n    key: \"findLastActive\",\n    value: function findLastActive() {\n      var active = this.container.find(\".\".concat(this.config.className.active));\n\n      if (!active.length) {\n        return null;\n      }\n\n      var item = active.last();\n      var column = item.closest(\".\".concat(this.config.className.col));\n      return {\n        item: item,\n        column: column\n      };\n    }\n  }, {\n    key: \"createList\",\n    value: function createList(data) {\n      var _this5 = this;\n\n      var list = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<ul />');\n      var items = data.map(function (item) {\n        return _this5.createItem(item);\n      });\n      var fragments = items.reduce(function (fragment, current) {\n        fragment.appendChild(current[0] || current);\n        return fragment;\n      }, document.createDocumentFragment());\n      list.append(fragments).addClass(this.config.className.list);\n      return list;\n    }\n  }, {\n    key: \"createItem\",\n    value: function createItem(item) {\n      var listItem = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<li />');\n      var listItemClasses = [this.config.className.item];\n      var link = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<a />');\n      var createItemContent = this.config.createItemContent || this.createItemContent;\n      var fragment = createItemContent.call(this, item);\n      link.append(fragment).attr('href', '').attr('tabindex', -1);\n\n      if (item.url) {\n        link.attr('href', item.url);\n        listItemClasses.push(item.className);\n      }\n\n      if (item[this.config.childKey]) {\n        listItemClasses.push(this.config.className[this.config.childKey]);\n      }\n\n      listItemClasses.push(\"fjs-item-\".concat(item.type));\n      listItem.addClass(listItemClasses.join(' '));\n      listItem.append(link).attr('data-fjs-item', item[this.config.itemKey]);\n      listItem[0]._item = item;\n      return listItem;\n    }\n  }, {\n    key: \"updatePathBar\",\n    value: function updatePathBar() {\n      var _this6 = this;\n\n      if (!this.config.pathBar) {\n        return false;\n      }\n\n      var activeItems = this.container.find(\".\".concat(this.config.className.active));\n      var itemKeys = '';\n      this.pathBar.children().empty();\n      activeItems.each(function (index, activeItem) {\n        var item = activeItem._item;\n        var isLast = index + 1 === activeItems.length;\n        itemKeys += \"/\".concat(item[_this6.config.itemKey]);\n\n        _this6.pathBar.append(\"\\n                <span class=\\\"breadcrumb-node breadcrumb-node-\".concat(item.type, \"\\\" \").concat(item.type === 'dir' ? \"data-breadcrumb-node=\\\"\".concat(itemKeys, \"\\\"\") : '', \">\\n                    <i class=\\\"fa fa-fw \").concat(_this6.getIcon(item.type), \"\\\"></i>\\n                    <span class=\\\"breadcrumb-node-name\\\">\").concat(jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div />').text(item[_this6.config.labelKey]).html(), \"</span>\\n                    \").concat(!isLast ? '<i class=\"fa fa-fw fa-chevron-right\"></i>' : '', \"\\n                </span>\\n            \"));\n      });\n    }\n  }, {\n    key: \"getIcon\",\n    value: function getIcon(type) {\n      switch (type) {\n        case 'root':\n          return 'fa-sitemap';\n\n        case 'file':\n          return 'fa-file-o';\n\n        case 'dir':\n        default:\n          return 'fa-folder';\n      }\n    }\n  }]);\n\n  return Finder;\n}();\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Finder);//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 29944 characters]\n//# sourceURL=webpack-internal:///./app/utils/finderjs.js\n");

/***/ }),

/***/ "./app/utils/formatbytes.js":
/*!**********************************!*\
  !*** ./app/utils/formatbytes.js ***!
  \**********************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ formatBytes\n/* harmony export */ });\nvar sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'];\nfunction formatBytes(bytes, decimals) {\n  if (bytes === 0) return '0 Byte';\n  var k = 1000;\n  var value = Math.floor(Math.log(bytes) / Math.log(k));\n  var decimal = decimals + 1 || 3;\n  return (bytes / Math.pow(k, value)).toPrecision(decimal) + ' ' + sizes[value];\n}//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL2Zvcm1hdGJ5dGVzLmpzP2FhZDMiXSwibmFtZXMiOlsic2l6ZXMiLCJmb3JtYXRCeXRlcyIsImJ5dGVzIiwiZGVjaW1hbHMiLCJrIiwidmFsdWUiLCJNYXRoIiwiZmxvb3IiLCJsb2ciLCJkZWNpbWFsIiwicG93IiwidG9QcmVjaXNpb24iXSwibWFwcGluZ3MiOiI7Ozs7QUFBQSxJQUFNQSxLQUFLLEdBQUcsQ0FBQyxPQUFELEVBQVUsSUFBVixFQUFnQixJQUFoQixFQUFzQixJQUF0QixFQUE0QixJQUE1QixFQUFrQyxJQUFsQyxFQUF3QyxJQUF4QyxFQUE4QyxJQUE5QyxFQUFvRCxJQUFwRCxDQUFkO0FBRWUsU0FBU0MsV0FBVCxDQUFxQkMsS0FBckIsRUFBNEJDLFFBQTVCLEVBQXNDO0FBQ2pELE1BQUlELEtBQUssS0FBSyxDQUFkLEVBQWlCLE9BQU8sUUFBUDtBQUVqQixNQUFJRSxDQUFDLEdBQUcsSUFBUjtBQUNBLE1BQUlDLEtBQUssR0FBR0MsSUFBSSxDQUFDQyxLQUFMLENBQVdELElBQUksQ0FBQ0UsR0FBTCxDQUFTTixLQUFULElBQWtCSSxJQUFJLENBQUNFLEdBQUwsQ0FBU0osQ0FBVCxDQUE3QixDQUFaO0FBQ0EsTUFBSUssT0FBTyxHQUFHTixRQUFRLEdBQUcsQ0FBWCxJQUFnQixDQUE5QjtBQUVBLFNBQU8sQ0FBQ0QsS0FBSyxHQUFHSSxJQUFJLENBQUNJLEdBQUwsQ0FBU04sQ0FBVCxFQUFZQyxLQUFaLENBQVQsRUFBNkJNLFdBQTdCLENBQXlDRixPQUF6QyxJQUFvRCxHQUFwRCxHQUEwRFQsS0FBSyxDQUFDSyxLQUFELENBQXRFO0FBQ0giLCJmaWxlIjoiLi9hcHAvdXRpbHMvZm9ybWF0Ynl0ZXMuanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJjb25zdCBzaXplcyA9IFsnQnl0ZXMnLCAnS0InLCAnTUInLCAnR0InLCAnVEInLCAnUEInLCAnRUInLCAnWkInLCAnWUInXTtcblxuZXhwb3J0IGRlZmF1bHQgZnVuY3Rpb24gZm9ybWF0Qnl0ZXMoYnl0ZXMsIGRlY2ltYWxzKSB7XG4gICAgaWYgKGJ5dGVzID09PSAwKSByZXR1cm4gJzAgQnl0ZSc7XG5cbiAgICBsZXQgayA9IDEwMDA7XG4gICAgbGV0IHZhbHVlID0gTWF0aC5mbG9vcihNYXRoLmxvZyhieXRlcykgLyBNYXRoLmxvZyhrKSk7XG4gICAgbGV0IGRlY2ltYWwgPSBkZWNpbWFscyArIDEgfHwgMztcblxuICAgIHJldHVybiAoYnl0ZXMgLyBNYXRoLnBvdyhrLCB2YWx1ZSkpLnRvUHJlY2lzaW9uKGRlY2ltYWwpICsgJyAnICsgc2l6ZXNbdmFsdWVdO1xufVxuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./app/utils/formatbytes.js\n");

/***/ }),

/***/ "./app/utils/gpm.js":
/*!**************************!*\
  !*** ./app/utils/gpm.js ***!
  \**************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ GPM,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var _response__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./response */ \"./app/utils/response.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var events__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! events */ \"./node_modules/events/events.js\");\n/* harmony import */ var events__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(events__WEBPACK_IMPORTED_MODULE_2__);\nfunction _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\nfunction _inherits(subClass, superClass) { if (typeof superClass !== \"function\" && superClass !== null) { throw new TypeError(\"Super expression must either be null or a function\"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }\n\nfunction _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }\n\nfunction _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }\n\nfunction _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) { return call; } return _assertThisInitialized(self); }\n\nfunction _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); } return self; }\n\nfunction _isNativeReflectConstruct() { if (typeof Reflect === \"undefined\" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === \"function\") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }\n\nfunction _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }\n\n\n\n\n\nvar GPM = /*#__PURE__*/function (_EventEmitter) {\n  _inherits(GPM, _EventEmitter);\n\n  var _super = _createSuper(GPM);\n\n  function GPM() {\n    var _this;\n\n    var action = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'getUpdates';\n\n    _classCallCheck(this, GPM);\n\n    _this = _super.call(this);\n    _this.payload = {};\n    _this.raw = {};\n    _this.action = action;\n    return _this;\n  }\n\n  _createClass(GPM, [{\n    key: \"setPayload\",\n    value: function setPayload() {\n      var payload = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n      this.payload = payload;\n      this.emit('payload', payload);\n      return this;\n    }\n  }, {\n    key: \"setAction\",\n    value: function setAction() {\n      var action = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'getUpdates';\n      this.action = action;\n      this.emit('action', action);\n      return this;\n    }\n  }, {\n    key: \"fetch\",\n    value: function (_fetch) {\n      function fetch() {\n        return _fetch.apply(this, arguments);\n      }\n\n      fetch.toString = function () {\n        return _fetch.toString();\n      };\n\n      return fetch;\n    }(function () {\n      var _this2 = this;\n\n      var callback = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : function () {\n        return true;\n      };\n      var flush = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n      var data = new FormData();\n      data.append('admin-nonce', grav_config__WEBPACK_IMPORTED_MODULE_1__.config.admin_nonce);\n\n      if (flush) {\n        data.append('flush', true);\n      }\n\n      this.emit('fetching', this);\n      fetch(\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/update.json/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep, \"getUpdates\"), {\n        credentials: 'same-origin',\n        method: 'post',\n        body: data\n      }).then(function (response) {\n        _this2.raw = response;\n        return response;\n      }).then(_response__WEBPACK_IMPORTED_MODULE_0__.parseStatus).then(_response__WEBPACK_IMPORTED_MODULE_0__.parseJSON).then(function (response) {\n        return _this2.response(response);\n      }).then(function (response) {\n        return callback(response, _this2.raw);\n      }).then(function (response) {\n        return _this2.emit('fetched', _this2.payload, _this2.raw, _this2);\n      })[\"catch\"](_response__WEBPACK_IMPORTED_MODULE_0__.userFeedbackError);\n    })\n  }, {\n    key: \"response\",\n    value: function response(_response) {\n      this.payload = _response;\n      return _response;\n    }\n  }]);\n\n  return GPM;\n}((events__WEBPACK_IMPORTED_MODULE_2___default()));\n\n\nvar Instance = new GPM();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4612 characters]\n//# sourceURL=webpack-internal:///./app/utils/gpm.js\n");

/***/ }),

/***/ "./app/utils/jquery-utils.js":
/*!***********************************!*\
  !*** ./app/utils/jquery-utils.js ***!
  \***********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var speakingurl__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! speakingurl */ \"./node_modules/speakingurl/index.js\");\n/* harmony import */ var speakingurl__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(speakingurl__WEBPACK_IMPORTED_MODULE_1__);\nvar _this = undefined;\n\n\n // jQuery no parents filter\n\n(jquery__WEBPACK_IMPORTED_MODULE_0___default().expr[\":\"].noparents) = jquery__WEBPACK_IMPORTED_MODULE_0___default().expr.createPseudo(function (text) {\n  return function (element) {\n    return jquery__WEBPACK_IMPORTED_MODULE_0___default()(element).parents(text).length < 1;\n  };\n}); // Slugify\n// CommonJS and ES6 version of https://github.com/madflow/jquery-slugify\n\n(jquery__WEBPACK_IMPORTED_MODULE_0___default().fn.slugify) = function (source, options) {\n  return _this.each(function (element) {\n    var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element);\n    var source = jquery__WEBPACK_IMPORTED_MODULE_0___default()(source);\n    target.on('keyup change', function () {\n      target.data('locked', target.val() !== '' && target.val() !== undefined);\n    });\n    source.on('keyup change', function () {\n      if (target.data('locked') === true) {\n        return true;\n      }\n\n      var isInput = target.is('input') || target.is('textarea');\n      target[isInput ? 'val' : 'text'](jquery__WEBPACK_IMPORTED_MODULE_0___default().slugify(source.val(), options));\n    });\n  });\n}; // Static method.\n\n\n(jquery__WEBPACK_IMPORTED_MODULE_0___default().slugify) = function (sourceString, options) {\n  options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, (jquery__WEBPACK_IMPORTED_MODULE_0___default().slugify.options), options);\n  options.lang = options.lang || jquery__WEBPACK_IMPORTED_MODULE_0___default()('html').prop('lang');\n\n  if (typeof options.preSlug === 'function') {\n    sourceString = options.preSlug(sourceString);\n  }\n\n  sourceString = options.slugFunc(sourceString, options);\n\n  if (typeof options.postSlug === 'function') {\n    sourceString = options.postSlug(sourceString);\n  }\n\n  return sourceString;\n}; // Default plugin options\n\n\n(jquery__WEBPACK_IMPORTED_MODULE_0___default().slugify.options) = {\n  preSlug: null,\n  postSlug: null,\n  slugFunc: function slugFunc(input, opts) {\n    return speakingurl__WEBPACK_IMPORTED_MODULE_1___default()(input, opts);\n  }\n};//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4672 characters]\n//# sourceURL=webpack-internal:///./app/utils/jquery-utils.js\n");

/***/ }),

/***/ "./app/utils/keepalive.js":
/*!********************************!*\
  !*** ./app/utils/keepalive.js ***!
  \********************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _response__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./response */ \"./app/utils/response.js\");\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\nvar KeepAlive = /*#__PURE__*/function () {\n  function KeepAlive() {\n    _classCallCheck(this, KeepAlive);\n\n    this.active = false;\n  }\n\n  _createClass(KeepAlive, [{\n    key: \"start\",\n    value: function start() {\n      var _this = this;\n\n      var timeout = grav_config__WEBPACK_IMPORTED_MODULE_0__.config.admin_timeout / 1.5 * 1000;\n      this.timer = setInterval(function () {\n        return _this.fetch();\n      }, timeout);\n      this.active = true;\n    }\n  }, {\n    key: \"stop\",\n    value: function stop() {\n      clearInterval(this.timer);\n      this.active = false;\n    }\n  }, {\n    key: \"fetch\",\n    value: function (_fetch) {\n      function fetch() {\n        return _fetch.apply(this, arguments);\n      }\n\n      fetch.toString = function () {\n        return _fetch.toString();\n      };\n\n      return fetch;\n    }(function () {\n      var data = new FormData();\n      data.append('admin-nonce', grav_config__WEBPACK_IMPORTED_MODULE_0__.config.admin_nonce);\n      fetch(\"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_0__.config.base_url_relative, \"/task\").concat(grav_config__WEBPACK_IMPORTED_MODULE_0__.config.param_sep, \"keepAlive\"), {\n        credentials: 'same-origin',\n        method: 'post',\n        body: data\n      })[\"catch\"](_response__WEBPACK_IMPORTED_MODULE_1__.userFeedbackError);\n    })\n  }]);\n\n  return KeepAlive;\n}();\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (new KeepAlive());//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL2tlZXBhbGl2ZS5qcz9jNWNhIl0sIm5hbWVzIjpbIktlZXBBbGl2ZSIsImFjdGl2ZSIsInRpbWVvdXQiLCJjb25maWciLCJ0aW1lciIsInNldEludGVydmFsIiwiZmV0Y2giLCJjbGVhckludGVydmFsIiwiZGF0YSIsIkZvcm1EYXRhIiwiYXBwZW5kIiwiY3JlZGVudGlhbHMiLCJtZXRob2QiLCJib2R5IiwidXNlckZlZWRiYWNrRXJyb3IiXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7Ozs7QUFBQTtBQUNBOztJQUVNQSxTO0FBQ0YsdUJBQWM7QUFBQTs7QUFDVixTQUFLQyxNQUFMLEdBQWMsS0FBZDtBQUNIOzs7OzRCQUVPO0FBQUE7O0FBQ0osVUFBSUMsT0FBTyxHQUFHQyw2REFBQSxHQUF1QixHQUF2QixHQUE2QixJQUEzQztBQUNBLFdBQUtDLEtBQUwsR0FBYUMsV0FBVyxDQUFDO0FBQUEsZUFBTSxLQUFJLENBQUNDLEtBQUwsRUFBTjtBQUFBLE9BQUQsRUFBcUJKLE9BQXJCLENBQXhCO0FBQ0EsV0FBS0QsTUFBTCxHQUFjLElBQWQ7QUFDSDs7OzJCQUVNO0FBQ0hNLG1CQUFhLENBQUMsS0FBS0gsS0FBTixDQUFiO0FBQ0EsV0FBS0gsTUFBTCxHQUFjLEtBQWQ7QUFDSDs7Ozs7Ozs7Ozs7OztrQkFFTztBQUNKLFVBQUlPLElBQUksR0FBRyxJQUFJQyxRQUFKLEVBQVg7QUFDQUQsVUFBSSxDQUFDRSxNQUFMLENBQVksYUFBWixFQUEyQlAsMkRBQTNCO0FBRUFHLFdBQUssV0FBSUgsaUVBQUosa0JBQW9DQSx5REFBcEMsZ0JBQWlFO0FBQ2xFUSxtQkFBVyxFQUFFLGFBRHFEO0FBRWxFQyxjQUFNLEVBQUUsTUFGMEQ7QUFHbEVDLFlBQUksRUFBRUw7QUFINEQsT0FBakUsQ0FBTCxVQUlTTSx3REFKVDtBQUtILEs7Ozs7OztBQUdMLGlFQUFlLElBQUlkLFNBQUosRUFBZiIsImZpbGUiOiIuL2FwcC91dGlscy9rZWVwYWxpdmUuanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBjb25maWcgfSBmcm9tICdncmF2LWNvbmZpZyc7XG5pbXBvcnQgeyB1c2VyRmVlZGJhY2tFcnJvciB9IGZyb20gJy4vcmVzcG9uc2UnO1xuXG5jbGFzcyBLZWVwQWxpdmUge1xuICAgIGNvbnN0cnVjdG9yKCkge1xuICAgICAgICB0aGlzLmFjdGl2ZSA9IGZhbHNlO1xuICAgIH1cblxuICAgIHN0YXJ0KCkge1xuICAgICAgICBsZXQgdGltZW91dCA9IGNvbmZpZy5hZG1pbl90aW1lb3V0IC8gMS41ICogMTAwMDtcbiAgICAgICAgdGhpcy50aW1lciA9IHNldEludGVydmFsKCgpID0+IHRoaXMuZmV0Y2goKSwgdGltZW91dCk7XG4gICAgICAgIHRoaXMuYWN0aXZlID0gdHJ1ZTtcbiAgICB9XG5cbiAgICBzdG9wKCkge1xuICAgICAgICBjbGVhckludGVydmFsKHRoaXMudGltZXIpO1xuICAgICAgICB0aGlzLmFjdGl2ZSA9IGZhbHNlO1xuICAgIH1cblxuICAgIGZldGNoKCkge1xuICAgICAgICBsZXQgZGF0YSA9IG5ldyBGb3JtRGF0YSgpO1xuICAgICAgICBkYXRhLmFwcGVuZCgnYWRtaW4tbm9uY2UnLCBjb25maWcuYWRtaW5fbm9uY2UpO1xuXG4gICAgICAgIGZldGNoKGAke2NvbmZpZy5iYXNlX3VybF9yZWxhdGl2ZX0vdGFzayR7Y29uZmlnLnBhcmFtX3NlcH1rZWVwQWxpdmVgLCB7XG4gICAgICAgICAgICBjcmVkZW50aWFsczogJ3NhbWUtb3JpZ2luJyxcbiAgICAgICAgICAgIG1ldGhvZDogJ3Bvc3QnLFxuICAgICAgICAgICAgYm9keTogZGF0YVxuICAgICAgICB9KS5jYXRjaCh1c2VyRmVlZGJhY2tFcnJvcik7XG4gICAgfVxufVxuXG5leHBvcnQgZGVmYXVsdCBuZXcgS2VlcEFsaXZlKCk7XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./app/utils/keepalive.js\n");

/***/ }),

/***/ "./app/utils/offline.js":
/*!******************************!*\
  !*** ./app/utils/offline.js ***!
  \******************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_offline__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../utils/offline */ \"./app/utils/offline.js\");\n\n\nvar offlineElement = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#offline-status');\njquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('offline', function () {\n  offlineElement.slideDown();\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('online', function () {\n  offlineElement.slideUp();\n});\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).ready(function () {\n  if (!_utils_offline__WEBPACK_IMPORTED_MODULE_1__.default) {\n    offlineElement.slideDown();\n  }\n}); // assume online if can't check\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (typeof __webpack_require__.g.navigator.onLine !== 'undefined' ? __webpack_require__.g.navigator.onLine : true);//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL29mZmxpbmUuanM/ODc0ZSJdLCJuYW1lcyI6WyJvZmZsaW5lRWxlbWVudCIsIiQiLCJ3aW5kb3ciLCJvbiIsInNsaWRlRG93biIsInNsaWRlVXAiLCJkb2N1bWVudCIsInJlYWR5IiwiaXNPbmxpbmUiLCJnbG9iYWwiLCJuYXZpZ2F0b3IiLCJvbkxpbmUiXSwibWFwcGluZ3MiOiI7Ozs7Ozs7QUFBQTtBQUNBO0FBRUEsSUFBTUEsY0FBYyxHQUFHQyw2Q0FBQyxDQUFDLGlCQUFELENBQXhCO0FBRUFBLDZDQUFDLENBQUNDLE1BQUQsQ0FBRCxDQUFVQyxFQUFWLENBQWEsU0FBYixFQUF3QixZQUFNO0FBQzFCSCxnQkFBYyxDQUFDSSxTQUFmO0FBQ0gsQ0FGRDtBQUlBSCw2Q0FBQyxDQUFDQyxNQUFELENBQUQsQ0FBVUMsRUFBVixDQUFhLFFBQWIsRUFBdUIsWUFBTTtBQUN6QkgsZ0JBQWMsQ0FBQ0ssT0FBZjtBQUNILENBRkQ7QUFJQUosNkNBQUMsQ0FBQ0ssUUFBRCxDQUFELENBQVlDLEtBQVosQ0FBa0IsWUFBTTtBQUNwQixNQUFJLENBQUNDLG1EQUFMLEVBQWU7QUFDWFIsa0JBQWMsQ0FBQ0ksU0FBZjtBQUNIO0FBQ0osQ0FKRCxFLENBTUE7O0FBQ0EsaUVBQWUsT0FBT0sscUJBQU0sQ0FBQ0MsU0FBUCxDQUFpQkMsTUFBeEIsS0FBbUMsV0FBbkMsR0FBaURGLHFCQUFNLENBQUNDLFNBQVAsQ0FBaUJDLE1BQWxFLEdBQTJFLElBQTFGIiwiZmlsZSI6Ii4vYXBwL3V0aWxzL29mZmxpbmUuanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgJCBmcm9tICdqcXVlcnknO1xuaW1wb3J0IGlzT25saW5lIGZyb20gJy4uL3V0aWxzL29mZmxpbmUnO1xuXG5jb25zdCBvZmZsaW5lRWxlbWVudCA9ICQoJyNvZmZsaW5lLXN0YXR1cycpO1xuXG4kKHdpbmRvdykub24oJ29mZmxpbmUnLCAoKSA9PiB7XG4gICAgb2ZmbGluZUVsZW1lbnQuc2xpZGVEb3duKCk7XG59KTtcblxuJCh3aW5kb3cpLm9uKCdvbmxpbmUnLCAoKSA9PiB7XG4gICAgb2ZmbGluZUVsZW1lbnQuc2xpZGVVcCgpO1xufSk7XG5cbiQoZG9jdW1lbnQpLnJlYWR5KCgpID0+IHtcbiAgICBpZiAoIWlzT25saW5lKSB7XG4gICAgICAgIG9mZmxpbmVFbGVtZW50LnNsaWRlRG93bigpO1xuICAgIH1cbn0pO1xuXG4vLyBhc3N1bWUgb25saW5lIGlmIGNhbid0IGNoZWNrXG5leHBvcnQgZGVmYXVsdCB0eXBlb2YgZ2xvYmFsLm5hdmlnYXRvci5vbkxpbmUgIT09ICd1bmRlZmluZWQnID8gZ2xvYmFsLm5hdmlnYXRvci5vbkxpbmUgOiB0cnVlO1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./app/utils/offline.js\n");

/***/ }),

/***/ "./app/utils/packages.js":
/*!*******************************!*\
  !*** ./app/utils/packages.js ***!
  \*******************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\n/* harmony import */ var _utils_gpm__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../utils/gpm */ \"./app/utils/gpm.js\");\n/* harmony import */ var es6_promise__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! es6-promise */ \"./node_modules/es6-promise/dist/es6-promise.js\");\n/* harmony import */ var es6_promise__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(es6_promise__WEBPACK_IMPORTED_MODULE_4__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\n\n\n\nvar Sorter = /*#__PURE__*/function () {\n  function Sorter() {\n    _classCallCheck(this, Sorter);\n  }\n\n  _createClass(Sorter, [{\n    key: \"getElements\",\n    value: function getElements(elements, container) {\n      this.elements = elements || jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-gpm-plugin], [data-gpm-theme]');\n      this.container = container || jquery__WEBPACK_IMPORTED_MODULE_0___default()('.gpm-plugins > table > tbody, .gpm-themes > .themes.card-row');\n      return this.elements;\n    }\n  }, {\n    key: \"byCommon\",\n    value: function byCommon() {\n      var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'asc';\n      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n      var elements = this.getElements().sort(function (a, b) {\n        var A = jquery__WEBPACK_IMPORTED_MODULE_0___default()(a).data(data).toString().toLowerCase();\n        var B = jquery__WEBPACK_IMPORTED_MODULE_0___default()(b).data(data).toString().toLowerCase();\n        return Sorter.sort(A, B, direction);\n      });\n      return elements.appendTo(this.container);\n    }\n  }, {\n    key: \"byName\",\n    value: function byName() {\n      var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'asc';\n      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'gpm-name';\n      return this.byCommon(direction, data);\n    }\n  }, {\n    key: \"byAuthor\",\n    value: function byAuthor() {\n      var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'asc';\n      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'gpm-author';\n      return this.byCommon(direction, data);\n    }\n  }, {\n    key: \"byOfficial\",\n    value: function byOfficial() {\n      var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'asc';\n      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'gpm-official';\n      return this.byCommon(direction, data);\n    }\n  }, {\n    key: \"byReleaseDate\",\n    value: function byReleaseDate() {\n      var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'asc';\n      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'gpm-release-date';\n      var elements = this.getElements().sort(function (a, b) {\n        var A = new Date(jquery__WEBPACK_IMPORTED_MODULE_0___default()(a).data(data)).getTime();\n        var B = new Date(jquery__WEBPACK_IMPORTED_MODULE_0___default()(b).data(data)).getTime();\n        return Sorter.sort(A, B, direction === 'asc' ? 'desc' : 'asc');\n      });\n      elements.appendTo(this.container);\n    }\n  }, {\n    key: \"byUpdatable\",\n    value: function byUpdatable() {\n      var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'asc';\n      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'gpm-updatable';\n      return this.byCommon(direction, data);\n    }\n  }, {\n    key: \"byEnabled\",\n    value: function byEnabled() {\n      var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'asc';\n      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'gpm-enabled';\n      return this.byCommon(direction, data);\n    }\n  }, {\n    key: \"byTesting\",\n    value: function byTesting() {\n      var direction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'asc';\n      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'gpm-testing';\n      return this.byCommon(direction, data);\n    }\n  }], [{\n    key: \"sort\",\n    value: function sort(A, B) {\n      var direction = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'asc';\n\n      if (A > B) {\n        return direction === 'asc' ? 1 : -1;\n      }\n\n      if (A < B) {\n        return direction === 'asc' ? -1 : 1;\n      }\n\n      return 0;\n    }\n  }]);\n\n  return Sorter;\n}();\n\nvar Packages = /*#__PURE__*/function () {\n  function Packages() {\n    _classCallCheck(this, Packages);\n\n    this.Sort = new Sorter();\n  }\n\n  _createClass(Packages, [{\n    key: \"addDependenciesToList\",\n    value: function addDependenciesToList(dependencies) {\n      var slug = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n      dependencies.forEach(function (dependency) {\n        Packages.addDependencyToList('plugin', dependency.name || dependency, slug);\n      });\n    }\n  }, {\n    key: \"removePackage\",\n    value: function removePackage(type, slug) {\n      var _this = this;\n\n      var url = Packages.getRemovePackageUrl(type);\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n        method: 'post',\n        body: {\n          \"package\": slug\n        }\n      }, function (response) {\n        if (response.status === 'success') {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.remove-package-confirm').addClass('hidden');\n\n          if (response.dependencies && response.dependencies.length > 0) {\n            _this.addDependenciesToList(response.dependencies);\n\n            jquery__WEBPACK_IMPORTED_MODULE_0___default()('.remove-package-dependencies').removeClass('hidden');\n          } else {\n            jquery__WEBPACK_IMPORTED_MODULE_0___default()('.remove-package-done').removeClass('hidden');\n          } // The package was removed. When the modal closes, move to the packages list\n\n\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).on('closing', '[data-remodal-id=\"remove-package\"]', function () {\n            Packages.getBackToList(type);\n          });\n        } else {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.remove-package-confirm').addClass('hidden');\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.remove-package-error').removeClass('hidden');\n        }\n      });\n    }\n  }, {\n    key: \"reinstallPackage\",\n    value: function reinstallPackage(type, slug, package_name, current_version) {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.button-bar button').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.button-bar .spinning-wheel').removeClass('hidden');\n      var url = Packages.getReinstallPackageUrl(type);\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n        method: 'post',\n        body: {\n          slug: slug,\n          type: type,\n          package_name: package_name,\n          current_version: current_version\n        }\n      }, function (response) {\n        if (response.status === 'success') {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.reinstall-package-confirm').addClass('hidden');\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.reinstall-package-done').removeClass('hidden');\n        } else {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.reinstall-package-confirm').addClass('hidden');\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.reinstall-package-error').removeClass('hidden');\n        }\n\n        window.location.reload();\n      });\n    }\n  }, {\n    key: \"removeDependency\",\n    value: function removeDependency(type, slug, button) {\n      var _this2 = this;\n\n      var url = Packages.getRemovePackageUrl(type);\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n        method: 'post',\n        body: {\n          \"package\": slug\n        }\n      }, function (response) {\n        if (response.status === 'success') {\n          button.removeClass('button');\n          button.replaceWith(jquery__WEBPACK_IMPORTED_MODULE_0___default()('<span>Removed successfully</span>'));\n\n          if (response.dependencies && response.dependencies.length > 0) {\n            _this2.addDependenciesToList(response.dependencies, slug);\n          }\n        }\n      });\n    }\n  }, {\n    key: \"getPackagesDependencies\",\n    value: function getPackagesDependencies(type, slugs, finishedLoadingCallback) {\n      var url = Packages.getGetPackagesDependenciesUrl(type);\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n        method: 'post',\n        body: {\n          packages: slugs\n        }\n      }, function (response) {\n        finishedLoadingCallback();\n\n        if (response.status === 'success') {\n          if (response.dependencies) {\n            var hasDependencies = false;\n\n            for (var dependency in response.dependencies) {\n              if (response.dependencies.hasOwnProperty(dependency)) {\n                if (dependency === 'grav') {\n                  continue;\n                }\n\n                hasDependencies = true;\n                var dependencyName = dependency;\n                var action = response.dependencies[dependency];\n                Packages.addNeededDependencyToList(action, dependencyName);\n              }\n            }\n\n            if (hasDependencies) {\n              jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-dependencies-package-container').removeClass('hidden');\n            } else {\n              jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-package-container').removeClass('hidden');\n            }\n          } else {\n            jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-package-container').removeClass('hidden');\n          }\n        } else {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-package-error').removeClass('hidden');\n        }\n      });\n    }\n  }, {\n    key: \"installDependenciesOfPackages\",\n    value: function installDependenciesOfPackages(type, slugs, callbackSuccess, callbackError) {\n      var url = Packages.getInstallDependenciesOfPackagesUrl(type);\n      (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n        method: 'post',\n        body: {\n          packages: slugs\n        }\n      }, callbackSuccess);\n    }\n  }, {\n    key: \"installPackages\",\n    value: function installPackages(type, slugs, callbackSuccess) {\n      var url = Packages.getInstallPackageUrl(type);\n      es6_promise__WEBPACK_IMPORTED_MODULE_4__.Promise.all(slugs.map(function (slug) {\n        return new es6_promise__WEBPACK_IMPORTED_MODULE_4__.Promise(function (resolve, reject) {\n          (0,_utils_request__WEBPACK_IMPORTED_MODULE_2__.default)(url, {\n            method: 'post',\n            body: {\n              \"package\": slug,\n              type: type\n            }\n          }, function (response) {\n            resolve(response);\n          });\n        });\n      })).then(callbackSuccess);\n    }\n  }, {\n    key: \"handleGettingPackageDependencies\",\n    value: function handleGettingPackageDependencies(type, event) {\n      var action = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'update';\n      var slugs = Packages.getSlugsFromEvent(event);\n\n      if (!slugs) {\n        alert('No slug set');\n        return;\n      } // Cleanup\n\n\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.packages-names-list').html('');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.install-dependencies-package-container li').remove();\n      slugs.forEach(function (slug) {\n        if (action === 'update') {\n          var current_version = '';\n          var available_version = '';\n          var _name = '';\n          var resources = _utils_gpm__WEBPACK_IMPORTED_MODULE_3__.Instance.payload.payload.resources;\n\n          if (resources.plugins[slug]) {\n            available_version = resources.plugins[slug].available;\n            current_version = resources.plugins[slug].version;\n            _name = resources.plugins[slug].name;\n          } else if (resources.themes[slug]) {\n            available_version = resources.themes[slug].available;\n            current_version = resources.themes[slug].version;\n            _name = resources.themes[slug].name;\n          }\n\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.packages-names-list').append(\"<li>\".concat(_name ? _name : slug, \", \").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.FROM, \" v<strong>\").concat(current_version, \"</strong> \").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.TO, \" v<strong>\").concat(available_version, \"</strong></li>\"));\n        } else {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('.packages-names-list').append(\"<li>\".concat(name ? name : slug, \"</li>\"));\n        }\n      });\n      event.preventDefault();\n      event.stopPropagation(); // fix mismatching types when sharing install modal between plugins/themes\n\n      var query = '[data-packages-modal] [data-theme-action], [data-packages-modal] [data-plugin-action]';\n      var data = jquery__WEBPACK_IMPORTED_MODULE_0___default()(query).data('themeAction') || jquery__WEBPACK_IMPORTED_MODULE_0___default()(query).data('pluginAction');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(query).removeAttr('data-theme-action').removeAttr('data-plugin-action').attr(\"data-\".concat(type, \"-action\"), data); // Restore original state\n\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .loading').removeClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-dependencies-package-container').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-package-container').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installing-dependencies').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installing-package').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installation-complete').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-package-error').addClass('hidden');\n      this.getPackagesDependencies(type, slugs, function () {\n        var slugs_string = slugs.join();\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-packages-modal] [data-\".concat(type, \"-action=\\\"install-dependencies-and-package\\\"]\")).attr('data-packages-slugs', slugs_string);\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[data-packages-modal] [data-\".concat(type, \"-action=\\\"install-package\\\"]\")).attr('data-packages-slugs', slugs_string);\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .loading').addClass('hidden');\n      });\n    }\n  }, {\n    key: \"handleInstallingDependenciesAndPackage\",\n    value: function handleInstallingDependenciesAndPackage(type, event) {\n      var _this3 = this;\n\n      var slugs = Packages.getSlugsFromEvent(event);\n      event.preventDefault();\n      event.stopPropagation();\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-dependencies-package-container').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-package-container').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installing-dependencies').removeClass('hidden');\n      this.installDependenciesOfPackages(type, slugs, function (response) {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installing-dependencies').addClass('hidden');\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installing-package').removeClass('hidden');\n\n        _this3.installPackages(type, slugs, function () {\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installing-package').addClass('hidden');\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installation-complete').removeClass('hidden');\n\n          if (response.status === 'error') {\n            var remodal = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal]').data('remodal')];\n            remodal.close();\n            return;\n          }\n\n          setTimeout(function () {\n            if (slugs.length === 1) {\n              __webpack_require__.g.location.href = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/\").concat(type, \"s/\").concat(slugs[0]);\n            } else {\n              __webpack_require__.g.location.href = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/\").concat(type, \"s\");\n            }\n          }, 1000);\n        });\n      });\n    }\n  }, {\n    key: \"handleInstallingPackage\",\n    value: function handleInstallingPackage(type, event) {\n      var slugs = Packages.getSlugsFromEvent(event);\n      event.preventDefault();\n      event.stopPropagation();\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .install-package-container').addClass('hidden');\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installing-package').removeClass('hidden');\n      this.installPackages(type, slugs, function (response) {\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installing-package').addClass('hidden');\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal] .installation-complete').removeClass('hidden');\n        var errors = Array.from(response).filter(function (r) {\n          return r.status === 'error';\n        });\n\n        if (errors && errors.length) {\n          var remodal = (jquery__WEBPACK_IMPORTED_MODULE_0___default().remodal.lookup)[jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-packages-modal].remodal-is-opened').data('remodal')];\n          remodal.close();\n          return;\n        }\n\n        if (slugs.length === 1) {\n          __webpack_require__.g.location.href = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/\").concat(type, \"s/\").concat(slugs[0]);\n        } else {\n          __webpack_require__.g.location.href = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/\").concat(type, \"s\");\n        }\n      });\n    }\n  }, {\n    key: \"handleRemovingPackage\",\n    value: function handleRemovingPackage(type, event) {\n      var slug = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).attr('data-packages-slugs');\n      event.preventDefault();\n      event.stopPropagation();\n      this.removePackage(type, slug);\n    }\n  }, {\n    key: \"handleReinstallPackage\",\n    value: function handleReinstallPackage(type, event) {\n      var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n      var slug = target.attr('data-package-slug');\n      var package_name = target.attr('data-package-name');\n      var current_version = target.attr('data-package-current-version');\n      event.preventDefault();\n      event.stopPropagation();\n      this.reinstallPackage(type, slug, package_name, current_version);\n    }\n  }, {\n    key: \"handleRemovingDependency\",\n    value: function handleRemovingDependency(type, event) {\n      var slug = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).attr('data-dependency-slug');\n      var button = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target);\n      event.preventDefault();\n      event.stopPropagation();\n      this.removeDependency(type, slug, button);\n    }\n  }], [{\n    key: \"getBackToList\",\n    value: function getBackToList(type) {\n      __webpack_require__.g.location.href = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative, \"/\").concat(type, \"s\");\n    }\n  }, {\n    key: \"addDependencyToList\",\n    value: function addDependencyToList(type, dependency) {\n      var slug = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '';\n\n      if (['admin', 'form', 'login', 'email', 'grav'].indexOf(dependency) !== -1) {\n        return;\n      }\n\n      var container = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.package-dependencies-container');\n      var text = \"\".concat(dependency, \" <a href=\\\"#\\\" class=\\\"button\\\" data-dependency-slug=\\\"\").concat(dependency, \"\\\" data-\").concat(type, \"-action=\\\"remove-dependency-package\\\">Remove</a>\");\n\n      if (slug) {\n        text += \" (was needed by \".concat(slug, \")\");\n      }\n\n      container.append(\"<li>\".concat(text, \"</li>\"));\n    }\n  }, {\n    key: \"getTaskUrl\",\n    value: function getTaskUrl(type, task) {\n      var url = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.base_url_relative);\n      url += \"/\".concat(type, \"s.json\");\n      url += \"/task\".concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.config.param_sep).concat(task);\n      return url;\n    }\n  }, {\n    key: \"getRemovePackageUrl\",\n    value: function getRemovePackageUrl(type) {\n      return \"\".concat(Packages.getTaskUrl(type, 'removePackage'));\n    }\n  }, {\n    key: \"getReinstallPackageUrl\",\n    value: function getReinstallPackageUrl(type) {\n      return \"\".concat(Packages.getTaskUrl(type, 'reinstallPackage'));\n    }\n  }, {\n    key: \"getGetPackagesDependenciesUrl\",\n    value: function getGetPackagesDependenciesUrl(type) {\n      return \"\".concat(Packages.getTaskUrl(type, 'getPackagesDependencies'));\n    }\n  }, {\n    key: \"getInstallDependenciesOfPackagesUrl\",\n    value: function getInstallDependenciesOfPackagesUrl(type) {\n      return \"\".concat(Packages.getTaskUrl(type, 'installDependenciesOfPackages'));\n    }\n  }, {\n    key: \"getInstallPackageUrl\",\n    value: function getInstallPackageUrl(type) {\n      return \"\".concat(Packages.getTaskUrl(type, 'installPackage'));\n    }\n  }, {\n    key: \"addNeededDependencyToList\",\n    value: function addNeededDependencyToList(action, slug) {\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()('.install-dependencies-package-container .type-' + action).removeClass('hidden');\n      var list = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.install-dependencies-package-container .type-' + action + ' ul');\n\n      if (action !== 'install') {\n        var current_version = '';\n        var available_version = '';\n        var _name2 = '';\n        var resources = _utils_gpm__WEBPACK_IMPORTED_MODULE_3__.Instance.payload.payload.resources;\n\n        if (resources.plugins[slug]) {\n          available_version = resources.plugins[slug].available;\n          current_version = resources.plugins[slug].version;\n          _name2 = resources.plugins[slug].name;\n        } else if (resources.themes[slug]) {\n          available_version = resources.themes[slug].available;\n          current_version = resources.themes[slug].version;\n          _name2 = resources.themes[slug].name;\n        }\n\n        list.append(\"<li>\".concat(_name2 ? _name2 : slug, \", \").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.FROM, \" v<strong>\").concat(current_version, \"</strong> \").concat(grav_config__WEBPACK_IMPORTED_MODULE_1__.translations.PLUGIN_ADMIN.TO, \" v<strong>\").concat(available_version, \"</strong></li>\"));\n      } else {\n        list.append(\"<li>\".concat(name ? name : slug, \"</li>\"));\n      }\n    }\n  }, {\n    key: \"getSlugsFromEvent\",\n    value: function getSlugsFromEvent(event) {\n      var slugs = '';\n\n      if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).is('[data-packages-slugs]')) {\n        slugs = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).attr('data-packages-slugs');\n      } else {\n        slugs = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.target).parent('[data-packages-slugs]').attr('data-packages-slugs');\n      }\n\n      if (typeof slugs === 'undefined') {\n        return null;\n      }\n\n      slugs = slugs.split(',');\n      return typeof slugs === 'string' ? [slugs] : slugs;\n    }\n  }]);\n\n  return Packages;\n}();\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (new Packages());//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 44716 characters]\n//# sourceURL=webpack-internal:///./app/utils/packages.js\n");

/***/ }),

/***/ "./app/utils/remodal.js":
/*!******************************!*\
  !*** ./app/utils/remodal.js ***!
  \******************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* Remodal from https://github.com/vodkabears/Remodal\n * With Stackable option from https://github.com/antstorm/Remodal patch\n */\n\n!function (root, factory) {\n  return factory(root, (jquery__WEBPACK_IMPORTED_MODULE_0___default()));\n}(undefined, function (global, $) {\n  'use strict';\n  /**\n   * Name of the plugin\n   * @private\n   * @const\n   * @type {String}\n   */\n\n  var PLUGIN_NAME = 'remodal';\n  /**\n   * Namespace for CSS and events\n   * @private\n   * @const\n   * @type {String}\n   */\n\n  var NAMESPACE = window.REMODAL_GLOBALS && window.REMODAL_GLOBALS.NAMESPACE || PLUGIN_NAME;\n  /**\n   * Animationstart event with vendor prefixes\n   * @private\n   * @const\n   * @type {String}\n   */\n\n  var ANIMATIONSTART_EVENTS = $.map(['animationstart', 'webkitAnimationStart', 'MSAnimationStart', 'oAnimationStart'], function (eventName) {\n    return eventName + '.' + NAMESPACE;\n  }).join(' ');\n  /**\n   * Animationend event with vendor prefixes\n   * @private\n   * @const\n   * @type {String}\n   */\n\n  var ANIMATIONEND_EVENTS = $.map(['animationend', 'webkitAnimationEnd', 'MSAnimationEnd', 'oAnimationEnd'], function (eventName) {\n    return eventName + '.' + NAMESPACE;\n  }).join(' ');\n  /**\n   * Default settings\n   * @private\n   * @const\n   * @type {Object}\n   */\n\n  var DEFAULTS = $.extend({\n    hashTracking: true,\n    closeOnConfirm: true,\n    closeOnCancel: true,\n    closeOnEscape: true,\n    closeOnOutsideClick: true,\n    modifier: '',\n    stack: false,\n    appendTo: null\n  }, window.REMODAL_GLOBALS && window.REMODAL_GLOBALS.DEFAULTS);\n  /**\n   * States of the Remodal\n   * @private\n   * @const\n   * @enum {String}\n   */\n\n  var STATES = {\n    CLOSING: 'closing',\n    CLOSED: 'closed',\n    OPENING: 'opening',\n    OPENED: 'opened'\n  };\n  /**\n   * Reasons of the state change.\n   * @private\n   * @const\n   * @enum {String}\n   */\n\n  var STATE_CHANGE_REASONS = {\n    CONFIRMATION: 'confirmation',\n    CANCELLATION: 'cancellation'\n  };\n  /**\n   * Is animation supported?\n   * @private\n   * @const\n   * @type {Boolean}\n   */\n\n  var IS_ANIMATION = function () {\n    var style = document.createElement('div').style;\n    return style.animationName !== undefined || style.WebkitAnimationName !== undefined || style.MozAnimationName !== undefined || style.msAnimationName !== undefined || style.OAnimationName !== undefined;\n  }();\n  /**\n   * Is iOS?\n   * @private\n   * @const\n   * @type {Boolean}\n   */\n\n\n  var IS_IOS = /iPad|iPhone|iPod/.test(navigator.platform);\n  /**\n   * Current modal\n   * @private\n   * @type {Remodal}\n   */\n\n  var openModals = [];\n  /**\n   * Scrollbar position\n   * @private\n   * @type {Number}\n   */\n\n  var scrollTop;\n  /**\n   * Returns an animation duration\n   * @private\n   * @param {jQuery} $elem\n   * @returns {Number}\n   */\n\n  function getAnimationDuration($elem) {\n    if (IS_ANIMATION && $elem.css('animation-name') === 'none' && $elem.css('-webkit-animation-name') === 'none' && $elem.css('-moz-animation-name') === 'none' && $elem.css('-o-animation-name') === 'none' && $elem.css('-ms-animation-name') === 'none') {\n      return 0;\n    }\n\n    var duration = $elem.css('animation-duration') || $elem.css('-webkit-animation-duration') || $elem.css('-moz-animation-duration') || $elem.css('-o-animation-duration') || $elem.css('-ms-animation-duration') || '0s';\n    var delay = $elem.css('animation-delay') || $elem.css('-webkit-animation-delay') || $elem.css('-moz-animation-delay') || $elem.css('-o-animation-delay') || $elem.css('-ms-animation-delay') || '0s';\n    var iterationCount = $elem.css('animation-iteration-count') || $elem.css('-webkit-animation-iteration-count') || $elem.css('-moz-animation-iteration-count') || $elem.css('-o-animation-iteration-count') || $elem.css('-ms-animation-iteration-count') || '1';\n    var max;\n    var len;\n    var num;\n    var i;\n    duration = duration.split(', ');\n    delay = delay.split(', ');\n    iterationCount = iterationCount.split(', '); // The 'duration' size is the same as the 'delay' size\n\n    for (i = 0, len = duration.length, max = Number.NEGATIVE_INFINITY; i < len; i++) {\n      num = parseFloat(duration[i]) * parseInt(iterationCount[i], 10) + parseFloat(delay[i]);\n\n      if (num > max) {\n        max = num;\n      }\n    }\n\n    return max;\n  }\n  /**\n   * Returns a scrollbar width\n   * @private\n   * @returns {Number}\n   */\n\n\n  function getScrollbarWidth() {\n    if ($(document).height() <= $(window).height()) {\n      return 0;\n    }\n\n    var outer = document.createElement('div');\n    var inner = document.createElement('div');\n    var widthNoScroll;\n    var widthWithScroll;\n    outer.style.visibility = 'hidden';\n    outer.style.width = '100px';\n    document.body.appendChild(outer);\n    widthNoScroll = outer.offsetWidth; // Force scrollbars\n\n    outer.style.overflow = 'scroll'; // Add inner div\n\n    inner.style.width = '100%';\n    outer.appendChild(inner);\n    widthWithScroll = inner.offsetWidth; // Remove divs\n\n    outer.parentNode.removeChild(outer);\n    return widthNoScroll - widthWithScroll;\n  }\n  /**\n   * Locks the screen\n   * @private\n   */\n\n\n  function lockScreen() {\n    if (IS_IOS) {\n      return;\n    }\n\n    var $html = $('html');\n    var lockedClass = namespacify('is-locked');\n    var paddingRight;\n    var $body;\n\n    if (!$html.hasClass(lockedClass)) {\n      $body = $(document.body); // Zepto does not support '-=', '+=' in the `css` method\n\n      paddingRight = parseInt($body.css('padding-right'), 10) + getScrollbarWidth();\n      $body.css('padding-right', paddingRight + 'px');\n      $html.addClass(lockedClass);\n    }\n  }\n  /**\n   * Unlocks the screen\n   * @private\n   */\n\n\n  function unlockScreen() {\n    if (IS_IOS) {\n      return;\n    }\n\n    var $html = $('html');\n    var lockedClass = namespacify('is-locked');\n    var paddingRight;\n    var $body;\n\n    if ($html.hasClass(lockedClass)) {\n      $body = $(document.body); // Zepto does not support '-=', '+=' in the `css` method\n\n      paddingRight = parseInt($body.css('padding-right'), 10) - getScrollbarWidth();\n      $body.css('padding-right', paddingRight + 'px');\n      $html.removeClass(lockedClass);\n    }\n  }\n  /**\n   * Sets a state for an instance\n   * @private\n   * @param {Remodal} instance\n   * @param {STATES} state\n   * @param {Boolean} isSilent If true, Remodal does not trigger events\n   * @param {String} Reason of a state change.\n   */\n\n\n  function setState(instance, state, isSilent, reason) {\n    var newState = namespacify('is', state);\n    var allStates = [namespacify('is', STATES.CLOSING), namespacify('is', STATES.OPENING), namespacify('is', STATES.CLOSED), namespacify('is', STATES.OPENED)].join(' ');\n    instance.$bg.removeClass(allStates).addClass(newState);\n    instance.$overlay.removeClass(allStates).addClass(newState);\n    instance.$wrapper.removeClass(allStates).addClass(newState);\n    instance.$modal.removeClass(allStates).addClass(newState);\n    instance.state = state;\n    !isSilent && instance.$modal.trigger({\n      type: state,\n      reason: reason\n    }, [{\n      reason: reason\n    }]);\n  }\n  /**\n   * Synchronizes with the animation\n   * @param {Function} doBeforeAnimation\n   * @param {Function} doAfterAnimation\n   * @param {Remodal} instance\n   */\n\n\n  function syncWithAnimation(doBeforeAnimation, doAfterAnimation, instance) {\n    var runningAnimationsCount = 0;\n\n    var handleAnimationStart = function handleAnimationStart(e) {\n      if (e.target !== this) {\n        return;\n      }\n\n      runningAnimationsCount++;\n    };\n\n    var handleAnimationEnd = function handleAnimationEnd(e) {\n      if (e.target !== this) {\n        return;\n      }\n\n      if (--runningAnimationsCount === 0) {\n        // Remove event listeners\n        $.each(['$bg', '$overlay', '$wrapper', '$modal'], function (index, elemName) {\n          instance[elemName].off(ANIMATIONSTART_EVENTS + ' ' + ANIMATIONEND_EVENTS);\n        });\n        doAfterAnimation();\n      }\n    };\n\n    $.each(['$bg', '$overlay', '$wrapper', '$modal'], function (index, elemName) {\n      instance[elemName].on(ANIMATIONSTART_EVENTS, handleAnimationStart).on(ANIMATIONEND_EVENTS, handleAnimationEnd);\n    });\n    doBeforeAnimation(); // If the animation is not supported by a browser or its duration is 0\n\n    if (getAnimationDuration(instance.$bg) === 0 && getAnimationDuration(instance.$overlay) === 0 && getAnimationDuration(instance.$wrapper) === 0 && getAnimationDuration(instance.$modal) === 0) {\n      // Remove event listeners\n      $.each(['$bg', '$overlay', '$wrapper', '$modal'], function (index, elemName) {\n        instance[elemName].off(ANIMATIONSTART_EVENTS + ' ' + ANIMATIONEND_EVENTS);\n      });\n      doAfterAnimation();\n    }\n  }\n  /**\n   * Closes immediately\n   * @private\n   * @param {Remodal} instance\n   */\n\n\n  function halt(instance) {\n    if (instance.state === STATES.CLOSED) {\n      return;\n    }\n\n    $.each(['$bg', '$overlay', '$wrapper', '$modal'], function (index, elemName) {\n      instance[elemName].off(ANIMATIONSTART_EVENTS + ' ' + ANIMATIONEND_EVENTS);\n    });\n    removeModal(instance);\n    instance.$bg.removeClass(instance.settings.modifier);\n    instance.$overlay.removeClass(instance.settings.modifier).hide();\n    instance.$wrapper.hide();\n\n    if (openModals.length === 0) {\n      unlockScreen();\n    }\n\n    setState(instance, STATES.CLOSED, true);\n  }\n  /**\n   * Parses a string with options\n   * @private\n   * @param str\n   * @returns {Object}\n   */\n\n\n  function parseOptions(str) {\n    var obj = {};\n    var arr;\n    var len;\n    var val;\n    var i; // Remove spaces before and after delimiters\n\n    str = str.replace(/\\s*:\\s*/g, ':').replace(/\\s*,\\s*/g, ','); // Parse a string\n\n    arr = str.split(',');\n\n    for (i = 0, len = arr.length; i < len; i++) {\n      arr[i] = arr[i].split(':');\n      val = arr[i][1]; // Convert a string value if it is like a boolean\n\n      if (typeof val === 'string' || val instanceof String) {\n        val = val === 'true' || (val === 'false' ? false : val);\n      } // Convert a string value if it is like a number\n\n\n      if (typeof val === 'string' || val instanceof String) {\n        val = !isNaN(val) ? +val : val;\n      }\n\n      obj[arr[i][0]] = val;\n    }\n\n    return obj;\n  }\n  /**\n   * Generates a string separated by dashes and prefixed with NAMESPACE\n   * @private\n   * @param {...String}\n   * @returns {String}\n   */\n\n\n  function namespacify() {\n    var result = NAMESPACE;\n\n    for (var i = 0; i < arguments.length; ++i) {\n      result += '-' + arguments[i];\n    }\n\n    return result;\n  }\n  /**\n   * Handles the hashchange event\n   * @private\n   * @listens hashchange\n   */\n\n\n  function handleHashChangeEvent() {\n    var id = location.hash.replace('#', '');\n    var instance;\n    var $elem;\n    var current = currentModal();\n\n    if (!id) {\n      // Check if we have currently opened modal and animation was completed\n      if (current && current.state === STATES.OPENED && current.settings.hashTracking) {\n        current.close();\n      }\n    } else {\n      if (!current || current.id !== id) {\n        // Catch syntax error if your hash is bad\n        try {\n          $elem = $('[data-' + PLUGIN_NAME + '-id=\"' + id + '\"]');\n        } catch (err) {}\n\n        if ($elem && $elem.length) {\n          instance = $[PLUGIN_NAME].lookup[$elem.data(PLUGIN_NAME)];\n\n          if (instance && instance.settings.hashTracking) {\n            instance.open();\n          }\n        }\n      }\n    }\n  }\n\n  function currentModal() {\n    return openModals[openModals.length - 1];\n  }\n\n  function removeModal(remodal) {\n    var index = openModals.indexOf(remodal);\n\n    if (index >= 0) {\n      openModals.slice(index, 1);\n    }\n  }\n  /**\n   * Remodal constructor\n   * @constructor\n   * @param {jQuery} $modal\n   * @param {Object} options\n   */\n\n\n  function Remodal($modal, options) {\n    var $body = $(document.body);\n    var $appendTo = $body;\n    var remodal = this;\n    remodal.id = $modal.attr('data-' + PLUGIN_NAME + '-id');\n    remodal.settings = $.extend({}, DEFAULTS, options);\n    remodal.index = $[PLUGIN_NAME].lookup.push(remodal) - 1;\n    remodal.state = STATES.CLOSED; // remodal.$overlay = $('.' + namespacify('overlay'));\n\n    if (remodal.settings.appendTo !== null && remodal.settings.appendTo.length) {\n      $appendTo = $(remodal.settings.appendTo);\n    }\n\n    if (!remodal.$overlay) {\n      remodal.$overlay = $('<div>').addClass(namespacify('overlay') + ' ' + namespacify('is', STATES.CLOSED)).hide();\n      $appendTo.append(remodal.$overlay);\n    }\n\n    remodal.$bg = $('.' + namespacify('bg')).addClass(namespacify('is', STATES.CLOSED));\n    remodal.$modal = $modal.addClass(NAMESPACE + ' ' + namespacify('is-initialized') + ' ' + remodal.settings.modifier + ' ' + namespacify('is', STATES.CLOSED)).attr('tabindex', '-1');\n    remodal.$wrapper = $('<div>').addClass(namespacify('wrapper') + ' ' + remodal.settings.modifier + ' ' + namespacify('is', STATES.CLOSED)).hide().append(remodal.$modal);\n    $appendTo.append(remodal.$wrapper); // Add the event listener for the close button\n\n    remodal.$wrapper.on('click.' + NAMESPACE, '[data-' + PLUGIN_NAME + '-action=\"close\"]', function (e) {\n      e.preventDefault();\n      remodal.close();\n    }); // Add the event listener for the cancel button\n\n    remodal.$wrapper.on('click.' + NAMESPACE, '[data-' + PLUGIN_NAME + '-action=\"cancel\"]', function (e) {\n      e.preventDefault();\n      remodal.$modal.trigger(STATE_CHANGE_REASONS.CANCELLATION);\n\n      if (remodal.settings.closeOnCancel) {\n        remodal.close(STATE_CHANGE_REASONS.CANCELLATION);\n      }\n    }); // Add the event listener for the confirm button\n\n    remodal.$wrapper.on('click.' + NAMESPACE, '[data-' + PLUGIN_NAME + '-action=\"confirm\"]', function (e) {\n      e.preventDefault();\n      remodal.$modal.trigger(STATE_CHANGE_REASONS.CONFIRMATION);\n\n      if (remodal.settings.closeOnConfirm) {\n        remodal.close(STATE_CHANGE_REASONS.CONFIRMATION);\n      }\n    }); // Add the event listener for the overlay\n\n    remodal.$wrapper.on('click.' + NAMESPACE, function (e) {\n      var $target = $(e.target);\n      var isWrapper = $target.hasClass(namespacify('wrapper'));\n      var isWithin = $target.closest('.' + namespacify('is', STATES.OPENED)).length;\n\n      if (!isWrapper && isWithin) {\n        return;\n      }\n\n      if (remodal.settings.closeOnOutsideClick) {\n        remodal.close();\n      }\n    });\n  }\n  /**\n   * Opens a modal window\n   * @public\n   */\n\n\n  Remodal.prototype.open = function () {\n    var remodal = this;\n    var current;\n    var modalCount; // Check if the animation was completed\n\n    if (remodal.state === STATES.OPENING || remodal.state === STATES.CLOSING) {\n      return;\n    } // id = remodal.$modal.attr('data-' + PLUGIN_NAME + '-id');\n\n\n    if (remodal.id && remodal.settings.hashTracking) {\n      scrollTop = $(window).scrollTop();\n      location.hash = remodal.id;\n    }\n\n    if (!remodal.settings.stack) {\n      current = currentModal();\n\n      if (current && current !== remodal) {\n        halt(current);\n      }\n    }\n\n    modalCount = openModals.push(remodal);\n    remodal.$overlay.css('z-index', function (_, value) {\n      return parseInt(value, 10) + modalCount;\n    });\n    remodal.$wrapper.css('z-index', function (_, value) {\n      return parseInt(value, 10) + modalCount;\n    });\n    lockScreen();\n    remodal.$bg.addClass(remodal.settings.modifier);\n    remodal.$overlay.addClass(remodal.settings.modifier).show();\n    remodal.$wrapper.show().scrollTop(0);\n    remodal.$modal.focus();\n    syncWithAnimation(function () {\n      setState(remodal, STATES.OPENING);\n    }, function () {\n      setState(remodal, STATES.OPENED);\n    }, remodal);\n  };\n  /**\n   * Closes a modal window\n   * @public\n   * @param {String} reason\n   */\n\n\n  Remodal.prototype.close = function (reason) {\n    var remodal = this;\n    var current; // Check if the animation was completed\n\n    if (remodal.state === STATES.OPENING || remodal.state === STATES.CLOSING || remodal.state === STATES.CLOSED) {\n      return;\n    }\n\n    removeModal(remodal);\n\n    if (remodal.settings.hashTracking && remodal.id === location.hash.substr(1)) {\n      current = currentModal();\n\n      if (current) {\n        location.hash = current.id;\n      } else {\n        location.hash = '';\n        $(window).scrollTop(scrollTop);\n      }\n    }\n\n    syncWithAnimation(function () {\n      setState(remodal, STATES.CLOSING, false, reason);\n    }, function () {\n      remodal.$bg.removeClass(remodal.settings.modifier);\n      remodal.$overlay.removeClass(remodal.settings.modifier).hide();\n      remodal.$wrapper.hide();\n\n      if (openModals.length === 0) {\n        unlockScreen();\n      }\n\n      setState(remodal, STATES.CLOSED, false, reason);\n    }, remodal);\n  };\n  /**\n   * Returns a current state of a modal\n   * @public\n   * @returns {STATES}\n   */\n\n\n  Remodal.prototype.getState = function () {\n    return this.state;\n  };\n  /**\n   * Destroys a modal\n   * @public\n   */\n\n\n  Remodal.prototype.destroy = function () {\n    var lookup = $[PLUGIN_NAME].lookup;\n    var instanceCount;\n    halt(this);\n    this.$wrapper.remove();\n    delete lookup[this.index];\n    instanceCount = $.grep(lookup, function (instance) {\n      return !!instance;\n    }).length;\n\n    if (instanceCount === 0) {\n      this.$overlay.remove();\n      this.$bg.removeClass(namespacify('is', STATES.CLOSING) + ' ' + namespacify('is', STATES.OPENING) + ' ' + namespacify('is', STATES.CLOSED) + ' ' + namespacify('is', STATES.OPENED));\n    }\n  };\n  /**\n   * Special plugin object for instances\n   * @public\n   * @type {Object}\n   */\n\n\n  $[PLUGIN_NAME] = {\n    lookup: []\n  };\n  /**\n   * Plugin constructor\n   * @constructor\n   * @param {Object} options\n   * @returns {JQuery}\n   */\n\n  $.fn[PLUGIN_NAME] = function (opts) {\n    var instance;\n    var $elem;\n    this.each(function (index, elem) {\n      $elem = $(elem);\n\n      if ($elem.data(PLUGIN_NAME) == null) {\n        instance = new Remodal($elem, opts);\n        $elem.data(PLUGIN_NAME, instance.index);\n\n        if (instance.settings.hashTracking && instance.id === location.hash.substr(1)) {\n          instance.open();\n        }\n      } else {\n        instance = $[PLUGIN_NAME].lookup[$elem.data(PLUGIN_NAME)];\n      }\n    });\n    return instance;\n  };\n\n  $(document).ready(function () {\n    // data-remodal-target opens a modal window with the special Id\n    $(document).on('click', '[data-' + PLUGIN_NAME + '-target]', function (e) {\n      e.preventDefault();\n      var elem = e.currentTarget;\n      var id = elem.getAttribute('data-' + PLUGIN_NAME + '-target');\n      var $target = $('[data-' + PLUGIN_NAME + '-id=\"' + id + '\"]');\n      $[PLUGIN_NAME].lookup[$target.data(PLUGIN_NAME)].open();\n    }); // Auto initialization of modal windows\n    // They should have the 'remodal' class attribute\n    // Also you can write the `data-remodal-options` attribute to pass params into the modal\n\n    $(document).find('.' + NAMESPACE).each(function (i, container) {\n      var $container = $(container);\n      var options = $container.data(PLUGIN_NAME + '-options');\n\n      if (!options) {\n        options = {};\n      } else if (typeof options === 'string' || options instanceof String) {\n        options = parseOptions(options);\n      }\n\n      $container[PLUGIN_NAME](options);\n    }); // Handles the keydown event\n\n    $(document).on('keydown.' + NAMESPACE, function (e) {\n      var current = currentModal();\n\n      if (current && current.settings.closeOnEscape && current.state === STATES.OPENED && e.keyCode === 27) {\n        current.close();\n      }\n    }); // Handles the hashchange event\n\n    $(window).on('hashchange.' + NAMESPACE, handleHashChangeEvent);\n  });\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 60412 characters]\n//# sourceURL=webpack-internal:///./app/utils/remodal.js\n");

/***/ }),

/***/ "./app/utils/request.js":
/*!******************************!*\
  !*** ./app/utils/request.js ***!
  \******************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var _response__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./response */ \"./app/utils/response.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_1__);\n\n\nvar raw;\n\nvar request = function request(url) {\n  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n  var callback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : function () {\n    return true;\n  };\n\n  if (typeof options === 'function') {\n    callback = options;\n    options = {};\n  }\n\n  if (options.method && options.method === 'post') {\n    var data = new FormData();\n    options.body = Object.assign({\n      'admin-nonce': grav_config__WEBPACK_IMPORTED_MODULE_1__.config.admin_nonce\n    }, options.body || {});\n    Object.keys(options.body).map(function (key) {\n      return data.append(key, options.body[key]);\n    });\n    options.body = data;\n  }\n\n  options = Object.assign({\n    credentials: 'same-origin',\n    headers: {\n      'Accept': 'application/json'\n    }\n  }, options);\n  return fetch(url, options).then(function (response) {\n    raw = response;\n    return response;\n  }).then(_response__WEBPACK_IMPORTED_MODULE_0__.parseStatus).then(_response__WEBPACK_IMPORTED_MODULE_0__.parseJSON).then(_response__WEBPACK_IMPORTED_MODULE_0__.userFeedback).then(function (response) {\n    return callback(response, raw);\n  })[\"catch\"](_response__WEBPACK_IMPORTED_MODULE_0__.userFeedbackError);\n};\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (request);//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL3JlcXVlc3QuanM/MTc2YSJdLCJuYW1lcyI6WyJyYXciLCJyZXF1ZXN0IiwidXJsIiwib3B0aW9ucyIsImNhbGxiYWNrIiwibWV0aG9kIiwiZGF0YSIsIkZvcm1EYXRhIiwiYm9keSIsIk9iamVjdCIsImFzc2lnbiIsImNvbmZpZyIsImFkbWluX25vbmNlIiwia2V5cyIsIm1hcCIsImtleSIsImFwcGVuZCIsImNyZWRlbnRpYWxzIiwiaGVhZGVycyIsImZldGNoIiwidGhlbiIsInJlc3BvbnNlIiwicGFyc2VTdGF0dXMiLCJwYXJzZUpTT04iLCJ1c2VyRmVlZGJhY2siLCJ1c2VyRmVlZGJhY2tFcnJvciJdLCJtYXBwaW5ncyI6Ijs7Ozs7OztBQUFBO0FBQ0E7QUFFQSxJQUFJQSxHQUFKOztBQUNBLElBQUlDLE9BQU8sR0FBRyxTQUFWQSxPQUFVLENBQVNDLEdBQVQsRUFBbUQ7QUFBQSxNQUFyQ0MsT0FBcUMsdUVBQTNCLEVBQTJCO0FBQUEsTUFBdkJDLFFBQXVCLHVFQUFaO0FBQUEsV0FBTSxJQUFOO0FBQUEsR0FBWTs7QUFDN0QsTUFBSSxPQUFPRCxPQUFQLEtBQW1CLFVBQXZCLEVBQW1DO0FBQy9CQyxZQUFRLEdBQUdELE9BQVg7QUFDQUEsV0FBTyxHQUFHLEVBQVY7QUFDSDs7QUFFRCxNQUFJQSxPQUFPLENBQUNFLE1BQVIsSUFBa0JGLE9BQU8sQ0FBQ0UsTUFBUixLQUFtQixNQUF6QyxFQUFpRDtBQUM3QyxRQUFJQyxJQUFJLEdBQUcsSUFBSUMsUUFBSixFQUFYO0FBRUFKLFdBQU8sQ0FBQ0ssSUFBUixHQUFlQyxNQUFNLENBQUNDLE1BQVAsQ0FBYztBQUFFLHFCQUFlQywyREFBa0JDO0FBQW5DLEtBQWQsRUFBcURULE9BQU8sQ0FBQ0ssSUFBUixJQUFnQixFQUFyRSxDQUFmO0FBQ0FDLFVBQU0sQ0FBQ0ksSUFBUCxDQUFZVixPQUFPLENBQUNLLElBQXBCLEVBQTBCTSxHQUExQixDQUE4QixVQUFDQyxHQUFEO0FBQUEsYUFBU1QsSUFBSSxDQUFDVSxNQUFMLENBQVlELEdBQVosRUFBaUJaLE9BQU8sQ0FBQ0ssSUFBUixDQUFhTyxHQUFiLENBQWpCLENBQVQ7QUFBQSxLQUE5QjtBQUNBWixXQUFPLENBQUNLLElBQVIsR0FBZUYsSUFBZjtBQUNIOztBQUVESCxTQUFPLEdBQUdNLE1BQU0sQ0FBQ0MsTUFBUCxDQUFjO0FBQ3BCTyxlQUFXLEVBQUUsYUFETztBQUVwQkMsV0FBTyxFQUFFO0FBQ0wsZ0JBQVU7QUFETDtBQUZXLEdBQWQsRUFLUGYsT0FMTyxDQUFWO0FBT0EsU0FBT2dCLEtBQUssQ0FBQ2pCLEdBQUQsRUFBTUMsT0FBTixDQUFMLENBQ0ZpQixJQURFLENBQ0csVUFBQ0MsUUFBRCxFQUFjO0FBQ2hCckIsT0FBRyxHQUFHcUIsUUFBTjtBQUNBLFdBQU9BLFFBQVA7QUFDSCxHQUpFLEVBS0ZELElBTEUsQ0FLR0Usa0RBTEgsRUFNRkYsSUFORSxDQU1HRyxnREFOSCxFQU9GSCxJQVBFLENBT0dJLG1EQVBILEVBUUZKLElBUkUsQ0FRRyxVQUFDQyxRQUFEO0FBQUEsV0FBY2pCLFFBQVEsQ0FBQ2lCLFFBQUQsRUFBV3JCLEdBQVgsQ0FBdEI7QUFBQSxHQVJILFdBU0l5Qix3REFUSixDQUFQO0FBVUgsQ0EvQkQ7O0FBaUNBLGlFQUFleEIsT0FBZiIsImZpbGUiOiIuL2FwcC91dGlscy9yZXF1ZXN0LmpzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgcGFyc2VTdGF0dXMsIHBhcnNlSlNPTiwgdXNlckZlZWRiYWNrLCB1c2VyRmVlZGJhY2tFcnJvciB9IGZyb20gJy4vcmVzcG9uc2UnO1xuaW1wb3J0IHsgY29uZmlnIH0gZnJvbSAnZ3Jhdi1jb25maWcnO1xuXG5sZXQgcmF3O1xubGV0IHJlcXVlc3QgPSBmdW5jdGlvbih1cmwsIG9wdGlvbnMgPSB7fSwgY2FsbGJhY2sgPSAoKSA9PiB0cnVlKSB7XG4gICAgaWYgKHR5cGVvZiBvcHRpb25zID09PSAnZnVuY3Rpb24nKSB7XG4gICAgICAgIGNhbGxiYWNrID0gb3B0aW9ucztcbiAgICAgICAgb3B0aW9ucyA9IHt9O1xuICAgIH1cblxuICAgIGlmIChvcHRpb25zLm1ldGhvZCAmJiBvcHRpb25zLm1ldGhvZCA9PT0gJ3Bvc3QnKSB7XG4gICAgICAgIGxldCBkYXRhID0gbmV3IEZvcm1EYXRhKCk7XG5cbiAgICAgICAgb3B0aW9ucy5ib2R5ID0gT2JqZWN0LmFzc2lnbih7ICdhZG1pbi1ub25jZSc6IGNvbmZpZy5hZG1pbl9ub25jZSB9LCBvcHRpb25zLmJvZHkgfHwge30pO1xuICAgICAgICBPYmplY3Qua2V5cyhvcHRpb25zLmJvZHkpLm1hcCgoa2V5KSA9PiBkYXRhLmFwcGVuZChrZXksIG9wdGlvbnMuYm9keVtrZXldKSk7XG4gICAgICAgIG9wdGlvbnMuYm9keSA9IGRhdGE7XG4gICAgfVxuXG4gICAgb3B0aW9ucyA9IE9iamVjdC5hc3NpZ24oe1xuICAgICAgICBjcmVkZW50aWFsczogJ3NhbWUtb3JpZ2luJyxcbiAgICAgICAgaGVhZGVyczoge1xuICAgICAgICAgICAgJ0FjY2VwdCc6ICdhcHBsaWNhdGlvbi9qc29uJ1xuICAgICAgICB9XG4gICAgfSwgb3B0aW9ucyk7XG5cbiAgICByZXR1cm4gZmV0Y2godXJsLCBvcHRpb25zKVxuICAgICAgICAudGhlbigocmVzcG9uc2UpID0+IHtcbiAgICAgICAgICAgIHJhdyA9IHJlc3BvbnNlO1xuICAgICAgICAgICAgcmV0dXJuIHJlc3BvbnNlO1xuICAgICAgICB9KVxuICAgICAgICAudGhlbihwYXJzZVN0YXR1cylcbiAgICAgICAgLnRoZW4ocGFyc2VKU09OKVxuICAgICAgICAudGhlbih1c2VyRmVlZGJhY2spXG4gICAgICAgIC50aGVuKChyZXNwb25zZSkgPT4gY2FsbGJhY2socmVzcG9uc2UsIHJhdykpXG4gICAgICAgIC5jYXRjaCh1c2VyRmVlZGJhY2tFcnJvcik7XG59O1xuXG5leHBvcnQgZGVmYXVsdCByZXF1ZXN0O1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./app/utils/request.js\n");

/***/ }),

/***/ "./app/utils/response.js":
/*!*******************************!*\
  !*** ./app/utils/response.js ***!
  \*******************************/
/*! namespace exports */
/*! export parseJSON [provided] [no usage info] [missing usage info prevents renaming] */
/*! export parseStatus [provided] [no usage info] [missing usage info prevents renaming] */
/*! export userFeedback [provided] [no usage info] [missing usage info prevents renaming] */
/*! export userFeedbackError [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"parseStatus\": () => /* binding */ parseStatus,\n/* harmony export */   \"parseJSON\": () => /* binding */ parseJSON,\n/* harmony export */   \"userFeedback\": () => /* binding */ userFeedback,\n/* harmony export */   \"userFeedbackError\": () => /* binding */ userFeedbackError\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _toastr__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./toastr */ \"./app/utils/toastr.js\");\n/* harmony import */ var _offline__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./offline */ \"./app/utils/offline.js\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var mout_string_trim__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! mout/string/trim */ \"./node_modules/mout/string/trim.js\");\n/* harmony import */ var mout_string_trim__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(mout_string_trim__WEBPACK_IMPORTED_MODULE_4__);\n\n\n\n\n\nvar UNLOADING = false;\n\nvar error = function error(response) {\n  var error = new Error(response.statusText || response || '');\n  error.response = response;\n  return error;\n};\n\nfunction parseStatus(response) {\n  return response;\n  /* Whoops can handle JSON responses so we don't need this for now.\n      if (response.status >= 200 && response.status < 300) {\n          return response;\n      } else {\n          throw error(response);\n      }\n  */\n}\nfunction parseJSON(response) {\n  return response.text().then(function (text) {\n    var parsed = text;\n\n    try {\n      parsed = JSON.parse(text);\n    } catch (error) {\n      var content = document.createElement('div');\n      content.innerHTML = text;\n      var the_error = new Error();\n      the_error.stack = mout_string_trim__WEBPACK_IMPORTED_MODULE_4___default()(content.innerText);\n      throw the_error;\n    }\n\n    return parsed;\n  });\n}\nfunction userFeedback(response) {\n  if (UNLOADING) {\n    return true;\n  }\n\n  var status = response.status || (response.error ? 'error' : '');\n  var message = response.message || (response.error ? response.error.message : null);\n  var settings = response.toastr || null;\n  var backup;\n\n  switch (status) {\n    case 'unauthenticated':\n      document.location.href = grav_config__WEBPACK_IMPORTED_MODULE_3__.config.base_url_relative;\n      throw error('Logged out');\n\n    case 'unauthorized':\n      status = 'error';\n      message = message || 'Unauthorized.';\n      break;\n\n    case 'error':\n      status = 'error';\n      message = message || 'Unknown error.';\n      break;\n\n    case 'success':\n      status = 'success';\n      message = message || '';\n      break;\n\n    default:\n      status = 'error';\n      message = message || 'Invalid AJAX response.';\n      break;\n  }\n\n  if (settings) {\n    backup = Object.assign({}, _toastr__WEBPACK_IMPORTED_MODULE_1__.default.options);\n    Object.keys(settings).forEach(function (key) {\n      _toastr__WEBPACK_IMPORTED_MODULE_1__.default.options[key] = settings[key];\n    });\n  }\n\n  if (message && (_offline__WEBPACK_IMPORTED_MODULE_2__.default || !_offline__WEBPACK_IMPORTED_MODULE_2__.default && status !== 'error')) {\n    _toastr__WEBPACK_IMPORTED_MODULE_1__.default[status === 'success' ? 'success' : 'error'](message);\n  }\n\n  if (settings) {\n    _toastr__WEBPACK_IMPORTED_MODULE_1__.default.options = backup;\n  }\n\n  return response;\n}\nfunction userFeedbackError(error) {\n  if (UNLOADING) {\n    return true;\n  }\n\n  var stack = error.stack ? \"<pre><code>\".concat(error.stack, \"</code></pre>\") : '';\n  _toastr__WEBPACK_IMPORTED_MODULE_1__.default.error(\"Fetch Failed: <br /> \".concat(error.message, \" \").concat(stack));\n  console.error(\"\".concat(error.message, \" at \").concat(error.stack));\n}\njquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).on('beforeunload._ajax', function () {\n  UNLOADING = true;\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 7852 characters]\n//# sourceURL=webpack-internal:///./app/utils/response.js\n");

/***/ }),

/***/ "./app/utils/selectize-option-click.js":
/*!*********************************************!*\
  !*** ./app/utils/selectize-option-click.js ***!
  \*********************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var selectize__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! selectize */ \"./node_modules/selectize/dist/js/selectize.js\");\n/* harmony import */ var selectize__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(selectize__WEBPACK_IMPORTED_MODULE_1__);\n\n\nselectize__WEBPACK_IMPORTED_MODULE_1___default().define('option_click', function (options) {\n  var self = this;\n  var setup = self.setup;\n\n  this.setup = function () {\n    setup.apply(self, arguments);\n    var clicking = false; // Detect click on a .clickable\n\n    self.$dropdown_content.on('mousedown click', function (e) {\n      var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.target);\n\n      if (target.hasClass('clickable') || target.closest('.clickable').length) {\n        if (e.type === 'mousedown') {\n          clicking = true;\n          self.isFocused = false; // awful hack to defuse the document mousedown listener\n        } else {\n          self.isFocused = true;\n          setTimeout(function () {\n            clicking = false; // wait until blur has been preempted\n          });\n        }\n      } else {\n        // cleanup in case user right-clicked or dragged off the element\n        clicking = false;\n        self.isFocused = true;\n      }\n    }); // Intercept default handlers\n\n    self.$dropdown.off('mousedown click', '[data-selectable]').on('mousedown click', '[data-selectable]', function () {\n      if (!clicking) {\n        return self.onOptionSelect.apply(self, arguments);\n      }\n    });\n    self.$control_input.off('blur').on('blur', function () {\n      if (!clicking) {\n        return self.onBlur.apply(self, arguments);\n      }\n    });\n  };\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 4396 characters]\n//# sourceURL=webpack-internal:///./app/utils/selectize-option-click.js\n");

/***/ }),

/***/ "./app/utils/selectize-required-fix.js":
/*!*********************************************!*\
  !*** ./app/utils/selectize-required-fix.js ***!
  \*********************************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var selectize__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! selectize */ \"./node_modules/selectize/dist/js/selectize.js\");\n/* harmony import */ var selectize__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(selectize__WEBPACK_IMPORTED_MODULE_0__);\n/**\n * This is a plugin to override the `.refreshValidityState` method of\n * the Selectize library (https://selectize.github.io/selectize.js/).\n * The library is not maintained anymore (as of 2017-09-13) and contains\n * a bug which causes Microsoft Edge to not work with selectized [required]\n * form fields. This plugin should be removed if\n * https://github.com/selectize/selectize.js/pull/1320 is ever merged\n * and a new version of Selectize gets released.\n */\n\nselectize__WEBPACK_IMPORTED_MODULE_0___default().define('required-fix', function (options) {\n  var _this = this;\n\n  this.refreshValidityState = function () {\n    if (!_this.isRequired) return false;\n    var invalid = !_this.items.length;\n    _this.isInvalid = invalid;\n\n    if (invalid) {\n      _this.$control_input.attr('required', '');\n\n      _this.$input.removeAttr('required');\n    } else {\n      _this.$control_input.removeAttr('required');\n\n      _this.$input.attr('required');\n    }\n  };\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL3NlbGVjdGl6ZS1yZXF1aXJlZC1maXguanM/OWQ5NiJdLCJuYW1lcyI6WyJTZWxlY3RpemUiLCJvcHRpb25zIiwicmVmcmVzaFZhbGlkaXR5U3RhdGUiLCJpc1JlcXVpcmVkIiwiaW52YWxpZCIsIml0ZW1zIiwibGVuZ3RoIiwiaXNJbnZhbGlkIiwiJGNvbnRyb2xfaW5wdXQiLCJhdHRyIiwiJGlucHV0IiwicmVtb3ZlQXR0ciJdLCJtYXBwaW5ncyI6Ijs7O0FBQUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBRUE7QUFFQUEsdURBQUEsQ0FBaUIsY0FBakIsRUFBaUMsVUFBU0MsT0FBVCxFQUFrQjtBQUFBOztBQUMvQyxPQUFLQyxvQkFBTCxHQUE0QixZQUFNO0FBQzlCLFFBQUksQ0FBQyxLQUFJLENBQUNDLFVBQVYsRUFBc0IsT0FBTyxLQUFQO0FBRXRCLFFBQUlDLE9BQU8sR0FBRyxDQUFDLEtBQUksQ0FBQ0MsS0FBTCxDQUFXQyxNQUExQjtBQUNBLFNBQUksQ0FBQ0MsU0FBTCxHQUFpQkgsT0FBakI7O0FBRUEsUUFBSUEsT0FBSixFQUFhO0FBQ1QsV0FBSSxDQUFDSSxjQUFMLENBQW9CQyxJQUFwQixDQUF5QixVQUF6QixFQUFxQyxFQUFyQzs7QUFDQSxXQUFJLENBQUNDLE1BQUwsQ0FBWUMsVUFBWixDQUF1QixVQUF2QjtBQUNILEtBSEQsTUFHTztBQUNILFdBQUksQ0FBQ0gsY0FBTCxDQUFvQkcsVUFBcEIsQ0FBK0IsVUFBL0I7O0FBQ0EsV0FBSSxDQUFDRCxNQUFMLENBQVlELElBQVosQ0FBaUIsVUFBakI7QUFDSDtBQUNKLEdBYkQ7QUFjSCxDQWZEIiwiZmlsZSI6Ii4vYXBwL3V0aWxzL3NlbGVjdGl6ZS1yZXF1aXJlZC1maXguanMuanMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIFRoaXMgaXMgYSBwbHVnaW4gdG8gb3ZlcnJpZGUgdGhlIGAucmVmcmVzaFZhbGlkaXR5U3RhdGVgIG1ldGhvZCBvZlxuICogdGhlIFNlbGVjdGl6ZSBsaWJyYXJ5IChodHRwczovL3NlbGVjdGl6ZS5naXRodWIuaW8vc2VsZWN0aXplLmpzLykuXG4gKiBUaGUgbGlicmFyeSBpcyBub3QgbWFpbnRhaW5lZCBhbnltb3JlIChhcyBvZiAyMDE3LTA5LTEzKSBhbmQgY29udGFpbnNcbiAqIGEgYnVnIHdoaWNoIGNhdXNlcyBNaWNyb3NvZnQgRWRnZSB0byBub3Qgd29yayB3aXRoIHNlbGVjdGl6ZWQgW3JlcXVpcmVkXVxuICogZm9ybSBmaWVsZHMuIFRoaXMgcGx1Z2luIHNob3VsZCBiZSByZW1vdmVkIGlmXG4gKiBodHRwczovL2dpdGh1Yi5jb20vc2VsZWN0aXplL3NlbGVjdGl6ZS5qcy9wdWxsLzEzMjAgaXMgZXZlciBtZXJnZWRcbiAqIGFuZCBhIG5ldyB2ZXJzaW9uIG9mIFNlbGVjdGl6ZSBnZXRzIHJlbGVhc2VkLlxuICovXG5cbmltcG9ydCBTZWxlY3RpemUgZnJvbSAnc2VsZWN0aXplJztcblxuU2VsZWN0aXplLmRlZmluZSgncmVxdWlyZWQtZml4JywgZnVuY3Rpb24ob3B0aW9ucykge1xuICAgIHRoaXMucmVmcmVzaFZhbGlkaXR5U3RhdGUgPSAoKSA9PiB7XG4gICAgICAgIGlmICghdGhpcy5pc1JlcXVpcmVkKSByZXR1cm4gZmFsc2U7XG5cbiAgICAgICAgbGV0IGludmFsaWQgPSAhdGhpcy5pdGVtcy5sZW5ndGg7XG4gICAgICAgIHRoaXMuaXNJbnZhbGlkID0gaW52YWxpZDtcblxuICAgICAgICBpZiAoaW52YWxpZCkge1xuICAgICAgICAgICAgdGhpcy4kY29udHJvbF9pbnB1dC5hdHRyKCdyZXF1aXJlZCcsICcnKTtcbiAgICAgICAgICAgIHRoaXMuJGlucHV0LnJlbW92ZUF0dHIoJ3JlcXVpcmVkJyk7XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICB0aGlzLiRjb250cm9sX2lucHV0LnJlbW92ZUF0dHIoJ3JlcXVpcmVkJyk7XG4gICAgICAgICAgICB0aGlzLiRpbnB1dC5hdHRyKCdyZXF1aXJlZCcpO1xuICAgICAgICB9XG4gICAgfTtcbn0pO1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./app/utils/selectize-required-fix.js\n");

/***/ }),

/***/ "./app/utils/sidebar.js":
/*!******************************!*\
  !*** ./app/utils/sidebar.js ***!
  \******************************/
/*! namespace exports */
/*! export Instance [provided] [no usage info] [missing usage info prevents renaming] */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.g, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => /* binding */ Sidebar,\n/* harmony export */   \"Instance\": () => /* binding */ Instance\n/* harmony export */ });\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var es6_map__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! es6-map */ \"./node_modules/es6-map/index.js\");\n/* harmony import */ var es6_map__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(es6_map__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var cookies_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! cookies-js */ \"./node_modules/cookies-js/dist/cookies.js\");\n/* harmony import */ var cookies_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(cookies_js__WEBPACK_IMPORTED_MODULE_2__);\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }\n\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }\n\n\n\n\nvar MOBILE_BREAKPOINT = 48 - 0.062;\nvar DESKTOP_BREAKPOINT = 75 + 0.063;\nvar EVENTS = 'touchstart._grav click._grav';\nvar TARGETS = '[data-sidebar-mobile-toggle], #overlay';\nvar MOBILE_QUERY = \"(max-width: \".concat(MOBILE_BREAKPOINT, \"em)\");\nvar DESKTOP_QUERY = \"(min-width: \".concat(DESKTOP_BREAKPOINT, \"em)\");\nvar map = new (es6_map__WEBPACK_IMPORTED_MODULE_1___default())();\n\nvar Sidebar = /*#__PURE__*/function () {\n  function Sidebar() {\n    _classCallCheck(this, Sidebar);\n\n    this.timeout = null;\n    this.isOpen = false;\n    this.body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\n    this.matchMedia = __webpack_require__.g.matchMedia(MOBILE_QUERY);\n    this.enable();\n  }\n\n  _createClass(Sidebar, [{\n    key: \"enable\",\n    value: function enable() {\n      var sidebar = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#admin-sidebar');\n      this.matchMedia.addListener(this._getBound('checkMatch'));\n      this.checkMatch(this.matchMedia);\n      this.body.on(EVENTS, '[data-sidebar-toggle]', this._getBound('toggleSidebarState'));\n\n      if (sidebar.data('quickopen')) {\n        sidebar.hover(this._getBound('quickOpenIn'), this._getBound('quickOpenOut'));\n      }\n    }\n  }, {\n    key: \"disable\",\n    value: function disable() {\n      var sidebar = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#admin-sidebar');\n      this.close();\n      this.matchMedia.removeListener(this._getBound('checkMatch'));\n      this.body.off(EVENTS, '[data-sidebar-toggle]', this._getBound('toggleSidebarState'));\n\n      if (sidebar.data('quickopen')) {\n        sidebar.off('mouseenter mouseleave');\n      }\n    }\n  }, {\n    key: \"attach\",\n    value: function attach() {\n      this.body.on(EVENTS, TARGETS, this._getBound('toggle'));\n    }\n  }, {\n    key: \"detach\",\n    value: function detach() {\n      this.body.off(EVENTS, TARGETS, this._getBound('toggle'));\n    }\n  }, {\n    key: \"quickOpenIn\",\n    value: function quickOpenIn()\n    /* event */\n    {\n      var _this = this;\n\n      var isDesktop = __webpack_require__.g.matchMedia(DESKTOP_QUERY).matches;\n      var delay = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#admin-sidebar').data('quickopen-delay') || 500;\n\n      if (this.body.hasClass('sidebar-mobile-open')) {\n        return;\n      }\n\n      var shouldQuickOpen = isDesktop ? this.body.hasClass('sidebar-closed') : !this.body.hasClass('sidebar-open');\n\n      if (!shouldQuickOpen && !this.body.hasClass('sidebar-quickopen')) {\n        return this.quickOpenOut();\n      }\n\n      this.timeout = setTimeout(function () {\n        _this.body.addClass('sidebar-open sidebar-quickopen');\n\n        jquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).trigger('sidebar_state._grav', isDesktop);\n      }, delay);\n    }\n  }, {\n    key: \"quickOpenOut\",\n    value: function quickOpenOut()\n    /* event */\n    {\n      clearTimeout(this.timeout);\n\n      if (this.body.hasClass('sidebar-quickopen')) {\n        this.body.removeClass('sidebar-open sidebar-quickopen');\n      }\n\n      return true;\n    }\n  }, {\n    key: \"open\",\n    value: function open(event) {\n      var _this2 = this;\n\n      var quick = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n      if (event) {\n        event.preventDefault();\n      }\n\n      var overlay = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#overlay');\n      var sidebar = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#admin-sidebar');\n      this.body.addClass('sidebar-mobile-open');\n      overlay.css('display', 'block');\n\n      if (!quick) {\n        sidebar.css('display', 'block').animate({\n          opacity: 1\n        }, 200, function () {\n          _this2.isOpen = true;\n        });\n      } else {\n        sidebar.css({\n          display: 'block',\n          opacity: 1\n        });\n        this.isOpen = true;\n      }\n    }\n  }, {\n    key: \"close\",\n    value: function close(event) {\n      var _this3 = this;\n\n      var quick = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n\n      if (event) {\n        event.preventDefault();\n      }\n\n      var overlay = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#overlay');\n      var sidebar = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#admin-sidebar');\n      this.body.removeClass('sidebar-mobile-open');\n      overlay.css('display', 'none');\n\n      if (!quick) {\n        sidebar.animate({\n          opacity: 0\n        }, 200, function () {\n          sidebar.css('display', 'none');\n          _this3.isOpen = false;\n        });\n      } else {\n        sidebar.css({\n          opacity: 0,\n          display: 'none'\n        });\n        this.isOpen = false;\n      }\n    }\n  }, {\n    key: \"toggle\",\n    value: function toggle(event) {\n      if (event) {\n        event.preventDefault();\n      }\n\n      return this[this.isOpen ? 'close' : 'open'](event);\n    }\n  }, {\n    key: \"toggleSidebarState\",\n    value: function toggleSidebarState(event) {\n      if (event) {\n        event.preventDefault();\n      }\n\n      clearTimeout(this.timeout);\n      var isDesktop = __webpack_require__.g.matchMedia(DESKTOP_QUERY).matches;\n      var cookie = null;\n\n      if (isDesktop) {\n        this.body.removeClass('sidebar-open');\n      }\n\n      if (!isDesktop) {\n        this.body.removeClass('sidebar-closed');\n        this.body.removeClass('sidebar-mobile-open');\n      }\n\n      this.body.toggleClass(\"sidebar-\".concat(isDesktop ? 'closed' : 'open'));\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(__webpack_require__.g).trigger('sidebar_state._grav', isDesktop);\n\n      if (isDesktop) {\n        cookie = !this.body.hasClass('sidebar-closed');\n      } else {\n        cookie = this.body.hasClass('sidebar-open');\n      }\n\n      cookies_js__WEBPACK_IMPORTED_MODULE_2___default().set('grav-admin-sidebar', cookie, {\n        expires: Infinity\n      });\n    }\n  }, {\n    key: \"checkMatch\",\n    value: function checkMatch(data) {\n      var sidebar = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#admin-sidebar');\n      var overlay = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#overlay');\n      this.isOpen = false;\n      overlay.css('display', 'none');\n      sidebar.css({\n        display: data.matches ? 'none' : 'inherit',\n        opacity: data.matches ? 0 : 1\n      });\n\n      if (data.matches) {\n        this.body.removeClass('sidebar-open sidebar-closed');\n      }\n\n      this[data.matches ? 'attach' : 'detach']();\n    }\n  }, {\n    key: \"_resetMap\",\n    value: function _resetMap() {\n      return map.clear();\n    }\n  }, {\n    key: \"_getBound\",\n    value: function _getBound(fn) {\n      if (map.has(fn)) {\n        return map.get(fn);\n      }\n\n      return map.set(fn, this[fn].bind(this)).get(fn);\n    }\n  }]);\n\n  return Sidebar;\n}();\n\n\nvar Instance = new Sidebar();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 15112 characters]\n//# sourceURL=webpack-internal:///./app/utils/sidebar.js\n");

/***/ }),

/***/ "./app/utils/storage.js":
/*!******************************!*\
  !*** ./app/utils/storage.js ***!
  \******************************/
/*! unknown exports (runtime-defined) */
/*! runtime requirements:  */
/***/ (() => {

eval("// localStorage\n(function () {\n  function isSupported() {\n    var item = 'localStoragePollyfill';\n\n    try {\n      localStorage.setItem(item, item);\n      localStorage.removeItem(item);\n      sessionStorage.setItem(item, item);\n      sessionStorage.removeItem(item);\n      return true;\n    } catch (e) {\n      return false;\n    }\n  }\n\n  if (!isSupported()) {\n    try {\n      Storage.prototype._data = {};\n\n      Storage.prototype.setItem = function (id, val) {\n        this._data[id] = String(val);\n        return this._data[id];\n      };\n\n      Storage.prototype.getItem = function (id) {\n        return this._data.hasOwnProperty(id) ? this._data[id] : undefined;\n      };\n\n      Storage.prototype.removeItem = function (id) {\n        return delete this._data[id];\n      };\n\n      Storage.prototype.clear = function () {\n        this._data = {};\n        return this._data;\n      };\n    } catch (e) {\n      console.error('localStorage pollyfill error: ', e);\n    }\n  }\n})();//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL3N0b3JhZ2UuanM/YjUzNiJdLCJuYW1lcyI6WyJpc1N1cHBvcnRlZCIsIml0ZW0iLCJsb2NhbFN0b3JhZ2UiLCJzZXRJdGVtIiwicmVtb3ZlSXRlbSIsInNlc3Npb25TdG9yYWdlIiwiZSIsIlN0b3JhZ2UiLCJwcm90b3R5cGUiLCJfZGF0YSIsImlkIiwidmFsIiwiU3RyaW5nIiwiZ2V0SXRlbSIsImhhc093blByb3BlcnR5IiwidW5kZWZpbmVkIiwiY2xlYXIiLCJjb25zb2xlIiwiZXJyb3IiXSwibWFwcGluZ3MiOiJBQUFBO0FBQ0MsYUFBVztBQUNSLFdBQVNBLFdBQVQsR0FBdUI7QUFDbkIsUUFBSUMsSUFBSSxHQUFHLHVCQUFYOztBQUNBLFFBQUk7QUFDQUMsTUFBQUEsWUFBWSxDQUFDQyxPQUFiLENBQXFCRixJQUFyQixFQUEyQkEsSUFBM0I7QUFDQUMsTUFBQUEsWUFBWSxDQUFDRSxVQUFiLENBQXdCSCxJQUF4QjtBQUNBSSxNQUFBQSxjQUFjLENBQUNGLE9BQWYsQ0FBdUJGLElBQXZCLEVBQTZCQSxJQUE3QjtBQUNBSSxNQUFBQSxjQUFjLENBQUNELFVBQWYsQ0FBMEJILElBQTFCO0FBQ0EsYUFBTyxJQUFQO0FBQ0gsS0FORCxDQU1FLE9BQU9LLENBQVAsRUFBVTtBQUNSLGFBQU8sS0FBUDtBQUNIO0FBQ0o7O0FBRUQsTUFBSSxDQUFDTixXQUFXLEVBQWhCLEVBQW9CO0FBQ2hCLFFBQUk7QUFDQU8sTUFBQUEsT0FBTyxDQUFDQyxTQUFSLENBQWtCQyxLQUFsQixHQUEwQixFQUExQjs7QUFFQUYsTUFBQUEsT0FBTyxDQUFDQyxTQUFSLENBQWtCTCxPQUFsQixHQUE0QixVQUFTTyxFQUFULEVBQWFDLEdBQWIsRUFBa0I7QUFDMUMsYUFBS0YsS0FBTCxDQUFXQyxFQUFYLElBQWlCRSxNQUFNLENBQUNELEdBQUQsQ0FBdkI7QUFDQSxlQUFPLEtBQUtGLEtBQUwsQ0FBV0MsRUFBWCxDQUFQO0FBQ0gsT0FIRDs7QUFLQUgsTUFBQUEsT0FBTyxDQUFDQyxTQUFSLENBQWtCSyxPQUFsQixHQUE0QixVQUFTSCxFQUFULEVBQWE7QUFDckMsZUFBTyxLQUFLRCxLQUFMLENBQVdLLGNBQVgsQ0FBMEJKLEVBQTFCLElBQWdDLEtBQUtELEtBQUwsQ0FBV0MsRUFBWCxDQUFoQyxHQUFpREssU0FBeEQ7QUFDSCxPQUZEOztBQUlBUixNQUFBQSxPQUFPLENBQUNDLFNBQVIsQ0FBa0JKLFVBQWxCLEdBQStCLFVBQVNNLEVBQVQsRUFBYTtBQUN4QyxlQUFPLE9BQU8sS0FBS0QsS0FBTCxDQUFXQyxFQUFYLENBQWQ7QUFDSCxPQUZEOztBQUlBSCxNQUFBQSxPQUFPLENBQUNDLFNBQVIsQ0FBa0JRLEtBQWxCLEdBQTBCLFlBQVc7QUFDakMsYUFBS1AsS0FBTCxHQUFhLEVBQWI7QUFDQSxlQUFPLEtBQUtBLEtBQVo7QUFDSCxPQUhEO0FBSUgsS0FwQkQsQ0FvQkUsT0FBT0gsQ0FBUCxFQUFVO0FBQ1JXLE1BQUFBLE9BQU8sQ0FBQ0MsS0FBUixDQUFjLGdDQUFkLEVBQWdEWixDQUFoRDtBQUNIO0FBQ0o7QUFDSixDQXZDQSxHQUFEIiwic291cmNlc0NvbnRlbnQiOlsiLy8gbG9jYWxTdG9yYWdlXG4oZnVuY3Rpb24oKSB7XG4gICAgZnVuY3Rpb24gaXNTdXBwb3J0ZWQoKSB7XG4gICAgICAgIHZhciBpdGVtID0gJ2xvY2FsU3RvcmFnZVBvbGx5ZmlsbCc7XG4gICAgICAgIHRyeSB7XG4gICAgICAgICAgICBsb2NhbFN0b3JhZ2Uuc2V0SXRlbShpdGVtLCBpdGVtKTtcbiAgICAgICAgICAgIGxvY2FsU3RvcmFnZS5yZW1vdmVJdGVtKGl0ZW0pO1xuICAgICAgICAgICAgc2Vzc2lvblN0b3JhZ2Uuc2V0SXRlbShpdGVtLCBpdGVtKTtcbiAgICAgICAgICAgIHNlc3Npb25TdG9yYWdlLnJlbW92ZUl0ZW0oaXRlbSk7XG4gICAgICAgICAgICByZXR1cm4gdHJ1ZTtcbiAgICAgICAgfSBjYXRjaCAoZSkge1xuICAgICAgICAgICAgcmV0dXJuIGZhbHNlO1xuICAgICAgICB9XG4gICAgfVxuXG4gICAgaWYgKCFpc1N1cHBvcnRlZCgpKSB7XG4gICAgICAgIHRyeSB7XG4gICAgICAgICAgICBTdG9yYWdlLnByb3RvdHlwZS5fZGF0YSA9IHt9O1xuXG4gICAgICAgICAgICBTdG9yYWdlLnByb3RvdHlwZS5zZXRJdGVtID0gZnVuY3Rpb24oaWQsIHZhbCkge1xuICAgICAgICAgICAgICAgIHRoaXMuX2RhdGFbaWRdID0gU3RyaW5nKHZhbCk7XG4gICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMuX2RhdGFbaWRdO1xuICAgICAgICAgICAgfTtcblxuICAgICAgICAgICAgU3RvcmFnZS5wcm90b3R5cGUuZ2V0SXRlbSA9IGZ1bmN0aW9uKGlkKSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMuX2RhdGEuaGFzT3duUHJvcGVydHkoaWQpID8gdGhpcy5fZGF0YVtpZF0gOiB1bmRlZmluZWQ7XG4gICAgICAgICAgICB9O1xuXG4gICAgICAgICAgICBTdG9yYWdlLnByb3RvdHlwZS5yZW1vdmVJdGVtID0gZnVuY3Rpb24oaWQpIHtcbiAgICAgICAgICAgICAgICByZXR1cm4gZGVsZXRlIHRoaXMuX2RhdGFbaWRdO1xuICAgICAgICAgICAgfTtcblxuICAgICAgICAgICAgU3RvcmFnZS5wcm90b3R5cGUuY2xlYXIgPSBmdW5jdGlvbigpIHtcbiAgICAgICAgICAgICAgICB0aGlzLl9kYXRhID0ge307XG4gICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMuX2RhdGE7XG4gICAgICAgICAgICB9O1xuICAgICAgICB9IGNhdGNoIChlKSB7XG4gICAgICAgICAgICBjb25zb2xlLmVycm9yKCdsb2NhbFN0b3JhZ2UgcG9sbHlmaWxsIGVycm9yOiAnLCBlKTtcbiAgICAgICAgfVxuICAgIH1cbn0oKSk7XG4iXSwiZmlsZSI6Ii4vYXBwL3V0aWxzL3N0b3JhZ2UuanMuanMiLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/utils/storage.js\n");

/***/ }),

/***/ "./app/utils/tabs-memory.js":
/*!**********************************!*\
  !*** ./app/utils/tabs-memory.js ***!
  \**********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var cookies_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! cookies-js */ \"./node_modules/cookies-js/dist/cookies.js\");\n/* harmony import */ var cookies_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(cookies_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _forms_fields_editor__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../forms/fields/editor */ \"./app/forms/fields/editor.js\");\n\n\n\nvar Data = JSON.parse(cookies_js__WEBPACK_IMPORTED_MODULE_1___default().get('grav-tabs-state') || '{}');\njquery__WEBPACK_IMPORTED_MODULE_0___default()('body').on('touchstart click', '[data-tabid]', function (event) {\n  event && event.stopPropagation();\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  Data[target.data('tabkey')] = target.data('scope');\n  cookies_js__WEBPACK_IMPORTED_MODULE_1___default().set('grav-tabs-state', JSON.stringify(Data), {\n    expires: Infinity\n  });\n  var panel = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[id=\\\"\".concat(target.data('tabid'), \"\\\"]\"));\n  target.siblings('[data-tabid]').removeClass('active');\n  target.addClass('active');\n  panel.siblings('[id]').removeClass('active');\n  panel.addClass('active');\n  _forms_fields_editor__WEBPACK_IMPORTED_MODULE_2__.Instance.editors.each(function (index, editor) {\n    var codemirror = jquery__WEBPACK_IMPORTED_MODULE_0___default()(editor).data('codemirror');\n\n    if (!codemirror) {\n      return;\n    }\n\n    if (codemirror.display.lastWrapWidth === 0) {\n      codemirror.refresh();\n    }\n  });\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL3RhYnMtbWVtb3J5LmpzPzM5YjEiXSwibmFtZXMiOlsiRGF0YSIsIkpTT04iLCJwYXJzZSIsIkNvb2tpZXMiLCIkIiwib24iLCJldmVudCIsInN0b3BQcm9wYWdhdGlvbiIsInRhcmdldCIsImN1cnJlbnRUYXJnZXQiLCJkYXRhIiwic3RyaW5naWZ5IiwiZXhwaXJlcyIsIkluZmluaXR5IiwicGFuZWwiLCJzaWJsaW5ncyIsInJlbW92ZUNsYXNzIiwiYWRkQ2xhc3MiLCJFZGl0b3JzIiwiaW5kZXgiLCJlZGl0b3IiLCJjb2RlbWlycm9yIiwiZGlzcGxheSIsImxhc3RXcmFwV2lkdGgiLCJyZWZyZXNoIl0sIm1hcHBpbmdzIjoiOzs7Ozs7QUFBQTtBQUNBO0FBQ0E7QUFFQSxJQUFJQSxJQUFJLEdBQUdDLElBQUksQ0FBQ0MsS0FBTCxDQUFXQyxxREFBQSxDQUFZLGlCQUFaLEtBQWtDLElBQTdDLENBQVg7QUFFQUMsNkNBQUMsQ0FBQyxNQUFELENBQUQsQ0FBVUMsRUFBVixDQUFhLGtCQUFiLEVBQWlDLGNBQWpDLEVBQWlELFVBQUNDLEtBQUQsRUFBVztBQUN4REEsT0FBSyxJQUFJQSxLQUFLLENBQUNDLGVBQU4sRUFBVDtBQUNBLE1BQUlDLE1BQU0sR0FBR0osNkNBQUMsQ0FBQ0UsS0FBSyxDQUFDRyxhQUFQLENBQWQ7QUFFQVQsTUFBSSxDQUFDUSxNQUFNLENBQUNFLElBQVAsQ0FBWSxRQUFaLENBQUQsQ0FBSixHQUE4QkYsTUFBTSxDQUFDRSxJQUFQLENBQVksT0FBWixDQUE5QjtBQUNBUCx1REFBQSxDQUFZLGlCQUFaLEVBQStCRixJQUFJLENBQUNVLFNBQUwsQ0FBZVgsSUFBZixDQUEvQixFQUFxRDtBQUFFWSxXQUFPLEVBQUVDO0FBQVgsR0FBckQ7QUFFQSxNQUFNQyxLQUFLLEdBQUdWLDZDQUFDLGlCQUFTSSxNQUFNLENBQUNFLElBQVAsQ0FBWSxPQUFaLENBQVQsU0FBZjtBQUVBRixRQUFNLENBQUNPLFFBQVAsQ0FBZ0IsY0FBaEIsRUFBZ0NDLFdBQWhDLENBQTRDLFFBQTVDO0FBQ0FSLFFBQU0sQ0FBQ1MsUUFBUCxDQUFnQixRQUFoQjtBQUVBSCxPQUFLLENBQUNDLFFBQU4sQ0FBZSxNQUFmLEVBQXVCQyxXQUF2QixDQUFtQyxRQUFuQztBQUNBRixPQUFLLENBQUNHLFFBQU4sQ0FBZSxRQUFmO0FBRUFDLHlFQUFBLENBQXFCLFVBQUNDLEtBQUQsRUFBUUMsTUFBUixFQUFtQjtBQUNwQyxRQUFJQyxVQUFVLEdBQUdqQiw2Q0FBQyxDQUFDZ0IsTUFBRCxDQUFELENBQVVWLElBQVYsQ0FBZSxZQUFmLENBQWpCOztBQUNBLFFBQUksQ0FBQ1csVUFBTCxFQUFpQjtBQUFFO0FBQVM7O0FBQzVCLFFBQUlBLFVBQVUsQ0FBQ0MsT0FBWCxDQUFtQkMsYUFBbkIsS0FBcUMsQ0FBekMsRUFBNEM7QUFDeENGLGdCQUFVLENBQUNHLE9BQVg7QUFDSDtBQUNKLEdBTkQ7QUFPSCxDQXRCRCIsImZpbGUiOiIuL2FwcC91dGlscy90YWJzLW1lbW9yeS5qcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCAkIGZyb20gJ2pxdWVyeSc7XG5pbXBvcnQgQ29va2llcyBmcm9tICdjb29raWVzLWpzJztcbmltcG9ydCB7IEluc3RhbmNlIGFzIEVkaXRvcnMgfSBmcm9tICcuLi9mb3Jtcy9maWVsZHMvZWRpdG9yJztcblxubGV0IERhdGEgPSBKU09OLnBhcnNlKENvb2tpZXMuZ2V0KCdncmF2LXRhYnMtc3RhdGUnKSB8fCAne30nKTtcblxuJCgnYm9keScpLm9uKCd0b3VjaHN0YXJ0IGNsaWNrJywgJ1tkYXRhLXRhYmlkXScsIChldmVudCkgPT4ge1xuICAgIGV2ZW50ICYmIGV2ZW50LnN0b3BQcm9wYWdhdGlvbigpO1xuICAgIGxldCB0YXJnZXQgPSAkKGV2ZW50LmN1cnJlbnRUYXJnZXQpO1xuXG4gICAgRGF0YVt0YXJnZXQuZGF0YSgndGFia2V5JyldID0gdGFyZ2V0LmRhdGEoJ3Njb3BlJyk7XG4gICAgQ29va2llcy5zZXQoJ2dyYXYtdGFicy1zdGF0ZScsIEpTT04uc3RyaW5naWZ5KERhdGEpLCB7IGV4cGlyZXM6IEluZmluaXR5IH0pO1xuXG4gICAgY29uc3QgcGFuZWwgPSAkKGBbaWQ9XCIke3RhcmdldC5kYXRhKCd0YWJpZCcpfVwiXWApO1xuXG4gICAgdGFyZ2V0LnNpYmxpbmdzKCdbZGF0YS10YWJpZF0nKS5yZW1vdmVDbGFzcygnYWN0aXZlJyk7XG4gICAgdGFyZ2V0LmFkZENsYXNzKCdhY3RpdmUnKTtcblxuICAgIHBhbmVsLnNpYmxpbmdzKCdbaWRdJykucmVtb3ZlQ2xhc3MoJ2FjdGl2ZScpO1xuICAgIHBhbmVsLmFkZENsYXNzKCdhY3RpdmUnKTtcblxuICAgIEVkaXRvcnMuZWRpdG9ycy5lYWNoKChpbmRleCwgZWRpdG9yKSA9PiB7XG4gICAgICAgIGxldCBjb2RlbWlycm9yID0gJChlZGl0b3IpLmRhdGEoJ2NvZGVtaXJyb3InKTtcbiAgICAgICAgaWYgKCFjb2RlbWlycm9yKSB7IHJldHVybjsgfVxuICAgICAgICBpZiAoY29kZW1pcnJvci5kaXNwbGF5Lmxhc3RXcmFwV2lkdGggPT09IDApIHtcbiAgICAgICAgICAgIGNvZGVtaXJyb3IucmVmcmVzaCgpO1xuICAgICAgICB9XG4gICAgfSk7XG59KTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/utils/tabs-memory.js\n");

/***/ }),

/***/ "./app/utils/toastr.js":
/*!*****************************!*\
  !*** ./app/utils/toastr.js ***!
  \*****************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__\n/* harmony export */ });\n/* harmony import */ var toastr__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! toastr */ \"./node_modules/toastr/toastr.js\");\n/* harmony import */ var toastr__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(toastr__WEBPACK_IMPORTED_MODULE_0__);\n\n(toastr__WEBPACK_IMPORTED_MODULE_0___default().options.positionClass) = 'toast-top-right';\n(toastr__WEBPACK_IMPORTED_MODULE_0___default().options.preventDuplicates) = true;\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ((toastr__WEBPACK_IMPORTED_MODULE_0___default()));//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3V0aWxzL3RvYXN0ci5qcz9jZjdiIl0sIm5hbWVzIjpbInRvYXN0ciJdLCJtYXBwaW5ncyI6Ijs7Ozs7O0FBQUE7QUFFQUEscUVBQUEsR0FBK0IsaUJBQS9CO0FBQ0FBLHlFQUFBLEdBQW1DLElBQW5DO0FBRUEsaUVBQWVBLCtDQUFmIiwiZmlsZSI6Ii4vYXBwL3V0aWxzL3RvYXN0ci5qcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB0b2FzdHIgZnJvbSAndG9hc3RyJztcblxudG9hc3RyLm9wdGlvbnMucG9zaXRpb25DbGFzcyA9ICd0b2FzdC10b3AtcmlnaHQnO1xudG9hc3RyLm9wdGlvbnMucHJldmVudER1cGxpY2F0ZXMgPSB0cnVlO1xuXG5leHBvcnQgZGVmYXVsdCB0b2FzdHI7XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./app/utils/toastr.js\n");

/***/ }),

/***/ "./app/whitelabel/compile.js":
/*!***********************************!*\
  !*** ./app/whitelabel/compile.js ***!
  \***********************************/
/*! namespace exports */
/*! export default [provided] [no usage info] [missing usage info prevents renaming] */
/*! export prepareElement [provided] [no usage info] [missing usage info prevents renaming] */
/*! export resetElement [provided] [no usage info] [missing usage info prevents renaming] */
/*! other exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_exports__, __webpack_require__.r, __webpack_require__.d, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   \"default\": () => __WEBPACK_DEFAULT_EXPORT__,\n/* harmony export */   \"prepareElement\": () => /* binding */ prepareElement,\n/* harmony export */   \"resetElement\": () => /* binding */ resetElement\n/* harmony export */ });\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! grav-config */ \"grav-config\");\n/* harmony import */ var grav_config__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(grav_config__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../utils/request */ \"./app/utils/request.js\");\n\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (function () {\n  var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},\n      _ref$preview = _ref.preview,\n      preview = _ref$preview === void 0 ? false : _ref$preview,\n      _ref$exportScss = _ref.exportScss,\n      exportScss = _ref$exportScss === void 0 ? false : _ref$exportScss,\n      _ref$color_scheme = _ref.color_scheme,\n      color_scheme = _ref$color_scheme === void 0 ? {} : _ref$color_scheme,\n      _ref$fonts = _ref.fonts,\n      fonts = _ref$fonts === void 0 ? {} : _ref$fonts,\n      _ref$callback = _ref.callback,\n      callback = _ref$callback === void 0 ? function () {} : _ref$callback;\n\n  var task = exportScss ? 'exportScss' : 'compileScss'; // console.log(config);\n\n  var URI = \"\".concat(grav_config__WEBPACK_IMPORTED_MODULE_0__.config.base_url_relative, \".json/task:\").concat(task);\n  (0,_utils_request__WEBPACK_IMPORTED_MODULE_1__.default)(URI, {\n    method: 'post',\n    body: Object.assign({}, preview ? {\n      preview: preview\n    } : null, color_scheme)\n  }, callback);\n});\nvar prepareElement = function prepareElement(element) {\n  element.data('busy_right_now', true);\n\n  if (!element.data('current_icon')) {\n    element.data('current_icon', element.find('.fa').attr('class'));\n  }\n\n  element.find('.fa').attr('class', 'fa fa-fw fa-spin fa-refresh');\n};\nvar resetElement = function resetElement(element) {\n  element.data('busy_right_now', false);\n  element.find('.fa').attr('class', element.data('current_icon'));\n};//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9HcmF2Ly4vYXBwL3doaXRlbGFiZWwvY29tcGlsZS5qcz9iZjI3Il0sIm5hbWVzIjpbInByZXZpZXciLCJleHBvcnRTY3NzIiwiY29sb3Jfc2NoZW1lIiwiZm9udHMiLCJjYWxsYmFjayIsInRhc2siLCJVUkkiLCJjb25maWciLCJyZXF1ZXN0IiwibWV0aG9kIiwiYm9keSIsIk9iamVjdCIsImFzc2lnbiIsInByZXBhcmVFbGVtZW50IiwiZWxlbWVudCIsImRhdGEiLCJmaW5kIiwiYXR0ciIsInJlc2V0RWxlbWVudCJdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7O0FBQUE7QUFDQTtBQUVBLGlFQUFlLFlBQXNHO0FBQUEsaUZBQVAsRUFBTztBQUFBLDBCQUFuR0EsT0FBbUc7QUFBQSxNQUFuR0EsT0FBbUcsNkJBQXpGLEtBQXlGO0FBQUEsNkJBQWxGQyxVQUFrRjtBQUFBLE1BQWxGQSxVQUFrRixnQ0FBckUsS0FBcUU7QUFBQSwrQkFBOURDLFlBQThEO0FBQUEsTUFBOURBLFlBQThELGtDQUEvQyxFQUErQztBQUFBLHdCQUEzQ0MsS0FBMkM7QUFBQSxNQUEzQ0EsS0FBMkMsMkJBQW5DLEVBQW1DO0FBQUEsMkJBQS9CQyxRQUErQjtBQUFBLE1BQS9CQSxRQUErQiw4QkFBcEIsWUFBTSxDQUFFLENBQVk7O0FBQ2pILE1BQUlDLElBQUksR0FBR0osVUFBVSxHQUFHLFlBQUgsR0FBa0IsYUFBdkMsQ0FEaUgsQ0FFakg7O0FBQ0EsTUFBTUssR0FBRyxhQUFNQyxpRUFBTix3QkFBNENGLElBQTVDLENBQVQ7QUFDQUcseURBQU8sQ0FBQ0YsR0FBRCxFQUFNO0FBQ1RHLFVBQU0sRUFBRSxNQURDO0FBRVRDLFFBQUksRUFBRUMsTUFBTSxDQUFDQyxNQUFQLENBQWMsRUFBZCxFQUFrQlosT0FBTyxHQUFHO0FBQUVBLGFBQU8sRUFBUEE7QUFBRixLQUFILEdBQWlCLElBQTFDLEVBQWdERSxZQUFoRDtBQUZHLEdBQU4sRUFHSkUsUUFISSxDQUFQO0FBSUgsQ0FSRDtBQVVPLElBQU1TLGNBQWMsR0FBRyxTQUFqQkEsY0FBaUIsQ0FBQ0MsT0FBRCxFQUFhO0FBQ3ZDQSxTQUFPLENBQUNDLElBQVIsQ0FBYSxnQkFBYixFQUErQixJQUEvQjs7QUFDQSxNQUFJLENBQUNELE9BQU8sQ0FBQ0MsSUFBUixDQUFhLGNBQWIsQ0FBTCxFQUFtQztBQUMvQkQsV0FBTyxDQUFDQyxJQUFSLENBQWEsY0FBYixFQUE2QkQsT0FBTyxDQUFDRSxJQUFSLENBQWEsS0FBYixFQUFvQkMsSUFBcEIsQ0FBeUIsT0FBekIsQ0FBN0I7QUFDSDs7QUFDREgsU0FBTyxDQUFDRSxJQUFSLENBQWEsS0FBYixFQUFvQkMsSUFBcEIsQ0FBeUIsT0FBekIsRUFBa0MsNkJBQWxDO0FBQ0gsQ0FOTTtBQVFBLElBQU1DLFlBQVksR0FBRyxTQUFmQSxZQUFlLENBQUNKLE9BQUQsRUFBYTtBQUNyQ0EsU0FBTyxDQUFDQyxJQUFSLENBQWEsZ0JBQWIsRUFBK0IsS0FBL0I7QUFDQUQsU0FBTyxDQUFDRSxJQUFSLENBQWEsS0FBYixFQUFvQkMsSUFBcEIsQ0FBeUIsT0FBekIsRUFBa0NILE9BQU8sQ0FBQ0MsSUFBUixDQUFhLGNBQWIsQ0FBbEM7QUFDSCxDQUhNIiwiZmlsZSI6Ii4vYXBwL3doaXRlbGFiZWwvY29tcGlsZS5qcy5qcyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IGNvbmZpZyB9IGZyb20gJ2dyYXYtY29uZmlnJztcbmltcG9ydCByZXF1ZXN0IGZyb20gJy4uL3V0aWxzL3JlcXVlc3QnO1xuXG5leHBvcnQgZGVmYXVsdCAoeyBwcmV2aWV3ID0gZmFsc2UsIGV4cG9ydFNjc3MgPSBmYWxzZSwgY29sb3Jfc2NoZW1lID0ge30sIGZvbnRzID0ge30sIGNhbGxiYWNrID0gKCkgPT4ge30gfSA9IHt9KSA9PiB7XG4gICAgbGV0IHRhc2sgPSBleHBvcnRTY3NzID8gJ2V4cG9ydFNjc3MnIDogJ2NvbXBpbGVTY3NzJztcbiAgICAvLyBjb25zb2xlLmxvZyhjb25maWcpO1xuICAgIGNvbnN0IFVSSSA9IGAke2NvbmZpZy5iYXNlX3VybF9yZWxhdGl2ZX0uanNvbi90YXNrOiR7dGFza31gO1xuICAgIHJlcXVlc3QoVVJJLCB7XG4gICAgICAgIG1ldGhvZDogJ3Bvc3QnLFxuICAgICAgICBib2R5OiBPYmplY3QuYXNzaWduKHt9LCBwcmV2aWV3ID8geyBwcmV2aWV3IH0gOiBudWxsLCBjb2xvcl9zY2hlbWUpXG4gICAgfSwgY2FsbGJhY2spO1xufTtcblxuZXhwb3J0IGNvbnN0IHByZXBhcmVFbGVtZW50ID0gKGVsZW1lbnQpID0+IHtcbiAgICBlbGVtZW50LmRhdGEoJ2J1c3lfcmlnaHRfbm93JywgdHJ1ZSk7XG4gICAgaWYgKCFlbGVtZW50LmRhdGEoJ2N1cnJlbnRfaWNvbicpKSB7XG4gICAgICAgIGVsZW1lbnQuZGF0YSgnY3VycmVudF9pY29uJywgZWxlbWVudC5maW5kKCcuZmEnKS5hdHRyKCdjbGFzcycpKTtcbiAgICB9XG4gICAgZWxlbWVudC5maW5kKCcuZmEnKS5hdHRyKCdjbGFzcycsICdmYSBmYS1mdyBmYS1zcGluIGZhLXJlZnJlc2gnKTtcbn07XG5cbmV4cG9ydCBjb25zdCByZXNldEVsZW1lbnQgPSAoZWxlbWVudCkgPT4ge1xuICAgIGVsZW1lbnQuZGF0YSgnYnVzeV9yaWdodF9ub3cnLCBmYWxzZSk7XG4gICAgZWxlbWVudC5maW5kKCcuZmEnKS5hdHRyKCdjbGFzcycsIGVsZW1lbnQuZGF0YSgnY3VycmVudF9pY29uJykpO1xufTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./app/whitelabel/compile.js\n");

/***/ }),

/***/ "./app/whitelabel/index.js":
/*!*********************************!*\
  !*** ./app/whitelabel/index.js ***!
  \*********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _compile__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./compile */ \"./app/whitelabel/compile.js\");\n/* harmony import */ var _forms__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../forms */ \"./app/forms/index.js\");\n/* harmony import */ var _utils_colors__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../utils/colors */ \"./app/utils/colors.js\");\n/* harmony import */ var _presets__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./presets */ \"./app/whitelabel/presets.js\");\n\n\n\n\n\nvar body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\nvar FormState = _forms__WEBPACK_IMPORTED_MODULE_2__.default.FormState.Instance;\n\nvar compiler = function compiler(element) {\n  var preview = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n  var exportScss = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n  var _callback = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : function () {};\n\n  (0,_compile__WEBPACK_IMPORTED_MODULE_1__.prepareElement)(element);\n  var fields = FormState.collect();\n  (0,_compile__WEBPACK_IMPORTED_MODULE_1__.default)({\n    preview: preview,\n    exportScss: exportScss,\n    color_scheme: !fields ? [] : fields.filter(function (value, key) {\n      return key.match(/^data\\[whitelabel]\\[color_scheme]/);\n    }).toJS(),\n    callback: function callback(response) {\n      _callback.call(_callback, response);\n\n      (0,_compile__WEBPACK_IMPORTED_MODULE_1__.resetElement)(element);\n    }\n  });\n};\n\nbody.on('click', '[data-preview-scss]', function (event) {\n  event && event.preventDefault();\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n\n  if (element.data('busy_right_now')) {\n    return false;\n  }\n\n  compiler(element, true, false, function (response) {\n    if (response.files) {\n      Object.keys(response.files).forEach(function (key) {\n        var file = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"#admin-pro-preview-\".concat(key));\n        var timestamp = Date.now();\n\n        if (!file.length) {\n          file = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"<link id=\\\"admin-pro-preview-\".concat(key, \"\\\" type=\\\"text/css\\\" rel=\\\"stylesheet\\\" />\"));\n          jquery__WEBPACK_IMPORTED_MODULE_0___default()('head').append(file);\n\n          if (!jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-reset-scss]').length) {\n            var reset = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<button class=\"button\" data-reset-scss style=\"margin-left: 5px;\"><i class=\"fa fa-fw fa-history\"></i> Reset</button>');\n            reset.insertAfter(element);\n          }\n        }\n\n        file.attr('href', \"\".concat(response.files[key], \"?\").concat(timestamp));\n      });\n    }\n  });\n});\nbody.on('click', '[data-recompile-scss]', function (event) {\n  event && event.preventDefault();\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n\n  if (element.data('busy_right_now')) {\n    return false;\n  }\n\n  compiler(element, true, false);\n});\nbody.on('click', '[data-export-scss]', function (event) {\n  event && event.preventDefault();\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n\n  if (element.data('busy_right_now')) {\n    return false;\n  }\n\n  compiler(element, true, true, function (response) {\n    if (response.files) {\n      Object.keys(response.files).forEach(function (key) {\n        if (key === 'download') {\n          var _element = document.createElement('a');\n\n          _element.setAttribute('href', response.files[key]);\n\n          _element.setAttribute('download', '');\n\n          _element.style.display = 'none';\n          document.body.appendChild(_element);\n\n          _element.click();\n\n          document.body.removeChild(_element);\n        }\n      });\n    }\n  });\n});\nbody.on('change._grav_colorpicker', '[data-grav-colorpicker]', function (event, input, hex, opacity) {\n  var RGB = (0,_utils_colors__WEBPACK_IMPORTED_MODULE_3__.hex2rgb)(hex);\n  var YIQ = (RGB.r * 299 + RGB.g * 587 + RGB.b * 114) / 1000;\n  var contrast = YIQ >= 128 || opacity <= 0.50 ? 'dark' : 'light';\n  input.parent().removeClass('dark-text light-text').addClass(\"\".concat(contrast, \"-text\"));\n});\nbody.ready(function () {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-grav-colorpicker]').trigger('keyup');\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 9964 characters]\n//# sourceURL=webpack-internal:///./app/whitelabel/index.js\n");

/***/ }),

/***/ "./app/whitelabel/presets.js":
/*!***********************************!*\
  !*** ./app/whitelabel/presets.js ***!
  \***********************************/
/*! namespace exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: __webpack_require__, __webpack_require__.n, __webpack_require__.r, __webpack_exports__, __webpack_require__.* */
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */ \"jquery\");\n/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _forms__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../forms */ \"./app/forms/index.js\");\n\n\nvar body = jquery__WEBPACK_IMPORTED_MODULE_0___default()('body');\nvar fields = [];\nvar FormState = _forms__WEBPACK_IMPORTED_MODULE_1__.default.FormState.Instance;\n\nvar setField = function setField(field, value) {\n  var name = field.prop('name');\n  var tag = field.prop('tagName').toLowerCase();\n  var type = field.prop('type');\n  fields.push(name);\n\n  switch (tag) {\n    case 'select':\n      field.val(value);\n      field.data('selectize').setValue(value);\n      field.trigger('change');\n      break;\n\n    case 'input':\n      if (type === 'radio') {\n        var strValue = value ? '1' : '0';\n        field.filter(function (index, radio) {\n          return jquery__WEBPACK_IMPORTED_MODULE_0___default()(radio).val() === strValue;\n        }).prop('checked', true);\n        break;\n      }\n\n      if (type === 'checkbox') {\n        field.prop('checked', value);\n        break;\n      }\n\n      field.val(value);\n      field.trigger('keyup');\n  }\n};\n\nbody.on('click', '[data-preset-values]', function (event) {\n  var target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var data = target.data('preset-values');\n  Object.keys(data).forEach(function (section) {\n    if (typeof data[section] === 'string') {\n      return;\n    }\n\n    Object.keys(data[section]).forEach(function (key) {\n      var field = jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[name=\\\"data[whitelabel][color_scheme][\".concat(section, \"][\").concat(key, \"]\\\"], [name=\\\"data[\").concat(section, \"][\").concat(key, \"]\\\"]\"));\n      var value = data[section][key];\n      setField(field, value);\n    });\n  });\n});\nbody.on('click', '[data-reset-scss]', function (event) {\n  event && event.preventDefault();\n  var element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(event.currentTarget);\n  var links = jquery__WEBPACK_IMPORTED_MODULE_0___default()('link[id^=admin-pro-preview-]');\n  element.remove();\n  links.remove();\n  fields.forEach(function (field) {\n    var value = FormState.loadState.get(field);\n    setField(jquery__WEBPACK_IMPORTED_MODULE_0___default()(\"[name=\\\"\".concat(field, \"\\\"]\")), value);\n  });\n  fields = [];\n}); // Horizontal Scroll Functionality\n\n(jquery__WEBPACK_IMPORTED_MODULE_0___default().fn.hscrollarrows) = function () {\n  return this.each(function () {\n    var navNext = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<a class=\"nav-next hide\"></a>');\n    var navPrev = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<a class=\"nav-prev hide\"></a>');\n    var scrollTime = null;\n    var resizeTime = null;\n    var scrolling = false;\n    var elm_w = 0;\n    var elem_data_w = 0;\n    var max_scroll = 0;\n    var inc_scroll = 0;\n\n    var calcData = function calcData() {\n      elm_w = elem.width();\n      elem_data_w = elem_data.get(0).scrollWidth;\n      max_scroll = elem_data_w - elm_w;\n      inc_scroll = elm_w * 0.3; // 20%\n    };\n\n    var revalidate = function revalidate() {\n      calcData();\n      stateNavs();\n    };\n\n    var run = function run() {\n      calcData();\n      setupNavs();\n    };\n\n    var setupNavs = function setupNavs() {\n      elem.parent().prepend(navNext);\n      elem.parent().prepend(navPrev);\n      navNext.on('click', next);\n      navPrev.on('click', prev);\n      stateNavs();\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(elem).scroll(function () {\n        if (!scrolling) {\n          clearTimeout(scrollTime);\n          scrollTime = setTimeout(function () {\n            stateNavs();\n          }, 250);\n        }\n      });\n      jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).resize(function () {\n        clearTimeout(resizeTime);\n        resizeTime = setTimeout(function () {\n          revalidate();\n        }, 250);\n      });\n    };\n\n    var stateNavs = function stateNavs() {\n      var current_scroll = elem.scrollLeft();\n\n      if (current_scroll < max_scroll) {\n        navNext.removeClass('hide');\n      } else {\n        navNext.addClass('hide');\n      }\n\n      if (current_scroll > 0) {\n        navPrev.removeClass('hide');\n      } else {\n        navPrev.addClass('hide');\n      }\n\n      scrolling = false;\n    };\n\n    var next = function next() {\n      var current_scroll = elem.scrollLeft();\n\n      if (current_scroll < max_scroll) {\n        scrolling = true;\n        elem.stop().animate({\n          scrollLeft: current_scroll + inc_scroll\n        }, stateNavs);\n      }\n    };\n\n    var prev = function prev() {\n      var current_scroll = elem.scrollLeft();\n\n      if (current_scroll > 0) {\n        scrolling = true;\n        elem.stop().animate({\n          scrollLeft: current_scroll - inc_scroll\n        }, stateNavs);\n      }\n    };\n\n    var elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this);\n    var elem_data = jquery__WEBPACK_IMPORTED_MODULE_0___default()(':first-child', elem);\n    run();\n  });\n};\n\njquery__WEBPACK_IMPORTED_MODULE_0___default()(document).ready(function () {\n  jquery__WEBPACK_IMPORTED_MODULE_0___default()('.jquery-horizontal-scroll').hscrollarrows();\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 13812 characters]\n//# sourceURL=webpack-internal:///./app/whitelabel/presets.js\n");

/***/ }),

/***/ "./node_modules/moment/locale sync recursive ^\\.\\/.*$":
/*!***************************************************!*\
  !*** ./node_modules/moment/locale/ sync ^\.\/.*$ ***!
  \***************************************************/
/*! default exports */
/*! exports [not provided] [no usage info] */
/*! runtime requirements: module, __webpack_require__.o, __webpack_require__ */
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

var map = {
	"./af": "./node_modules/moment/locale/af.js",
	"./af.js": "./node_modules/moment/locale/af.js",
	"./ar": "./node_modules/moment/locale/ar.js",
	"./ar-dz": "./node_modules/moment/locale/ar-dz.js",
	"./ar-dz.js": "./node_modules/moment/locale/ar-dz.js",
	"./ar-kw": "./node_modules/moment/locale/ar-kw.js",
	"./ar-kw.js": "./node_modules/moment/locale/ar-kw.js",
	"./ar-ly": "./node_modules/moment/locale/ar-ly.js",
	"./ar-ly.js": "./node_modules/moment/locale/ar-ly.js",
	"./ar-ma": "./node_modules/moment/locale/ar-ma.js",
	"./ar-ma.js": "./node_modules/moment/locale/ar-ma.js",
	"./ar-sa": "./node_modules/moment/locale/ar-sa.js",
	"./ar-sa.js": "./node_modules/moment/locale/ar-sa.js",
	"./ar-tn": "./node_modules/moment/locale/ar-tn.js",
	"./ar-tn.js": "./node_modules/moment/locale/ar-tn.js",
	"./ar.js": "./node_modules/moment/locale/ar.js",
	"./az": "./node_modules/moment/locale/az.js",
	"./az.js": "./node_modules/moment/locale/az.js",
	"./be": "./node_modules/moment/locale/be.js",
	"./be.js": "./node_modules/moment/locale/be.js",
	"./bg": "./node_modules/moment/locale/bg.js",
	"./bg.js": "./node_modules/moment/locale/bg.js",
	"./bm": "./node_modules/moment/locale/bm.js",
	"./bm.js": "./node_modules/moment/locale/bm.js",
	"./bn": "./node_modules/moment/locale/bn.js",
	"./bn-bd": "./node_modules/moment/locale/bn-bd.js",
	"./bn-bd.js": "./node_modules/moment/locale/bn-bd.js",
	"./bn.js": "./node_modules/moment/locale/bn.js",
	"./bo": "./node_modules/moment/locale/bo.js",
	"./bo.js": "./node_modules/moment/locale/bo.js",
	"./br": "./node_modules/moment/locale/br.js",
	"./br.js": "./node_modules/moment/locale/br.js",
	"./bs": "./node_modules/moment/locale/bs.js",
	"./bs.js": "./node_modules/moment/locale/bs.js",
	"./ca": "./node_modules/moment/locale/ca.js",
	"./ca.js": "./node_modules/moment/locale/ca.js",
	"./cs": "./node_modules/moment/locale/cs.js",
	"./cs.js": "./node_modules/moment/locale/cs.js",
	"./cv": "./node_modules/moment/locale/cv.js",
	"./cv.js": "./node_modules/moment/locale/cv.js",
	"./cy": "./node_modules/moment/locale/cy.js",
	"./cy.js": "./node_modules/moment/locale/cy.js",
	"./da": "./node_modules/moment/locale/da.js",
	"./da.js": "./node_modules/moment/locale/da.js",
	"./de": "./node_modules/moment/locale/de.js",
	"./de-at": "./node_modules/moment/locale/de-at.js",
	"./de-at.js": "./node_modules/moment/locale/de-at.js",
	"./de-ch": "./node_modules/moment/locale/de-ch.js",
	"./de-ch.js": "./node_modules/moment/locale/de-ch.js",
	"./de.js": "./node_modules/moment/locale/de.js",
	"./dv": "./node_modules/moment/locale/dv.js",
	"./dv.js": "./node_modules/moment/locale/dv.js",
	"./el": "./node_modules/moment/locale/el.js",
	"./el.js": "./node_modules/moment/locale/el.js",
	"./en-au": "./node_modules/moment/locale/en-au.js",
	"./en-au.js": "./node_modules/moment/locale/en-au.js",
	"./en-ca": "./node_modules/moment/locale/en-ca.js",
	"./en-ca.js": "./node_modules/moment/locale/en-ca.js",
	"./en-gb": "./node_modules/moment/locale/en-gb.js",
	"./en-gb.js": "./node_modules/moment/locale/en-gb.js",
	"./en-ie": "./node_modules/moment/locale/en-ie.js",
	"./en-ie.js": "./node_modules/moment/locale/en-ie.js",
	"./en-il": "./node_modules/moment/locale/en-il.js",
	"./en-il.js": "./node_modules/moment/locale/en-il.js",
	"./en-in": "./node_modules/moment/locale/en-in.js",
	"./en-in.js": "./node_modules/moment/locale/en-in.js",
	"./en-nz": "./node_modules/moment/locale/en-nz.js",
	"./en-nz.js": "./node_modules/moment/locale/en-nz.js",
	"./en-sg": "./node_modules/moment/locale/en-sg.js",
	"./en-sg.js": "./node_modules/moment/locale/en-sg.js",
	"./eo": "./node_modules/moment/locale/eo.js",
	"./eo.js": "./node_modules/moment/locale/eo.js",
	"./es": "./node_modules/moment/locale/es.js",
	"./es-do": "./node_modules/moment/locale/es-do.js",
	"./es-do.js": "./node_modules/moment/locale/es-do.js",
	"./es-mx": "./node_modules/moment/locale/es-mx.js",
	"./es-mx.js": "./node_modules/moment/locale/es-mx.js",
	"./es-us": "./node_modules/moment/locale/es-us.js",
	"./es-us.js": "./node_modules/moment/locale/es-us.js",
	"./es.js": "./node_modules/moment/locale/es.js",
	"./et": "./node_modules/moment/locale/et.js",
	"./et.js": "./node_modules/moment/locale/et.js",
	"./eu": "./node_modules/moment/locale/eu.js",
	"./eu.js": "./node_modules/moment/locale/eu.js",
	"./fa": "./node_modules/moment/locale/fa.js",
	"./fa.js": "./node_modules/moment/locale/fa.js",
	"./fi": "./node_modules/moment/locale/fi.js",
	"./fi.js": "./node_modules/moment/locale/fi.js",
	"./fil": "./node_modules/moment/locale/fil.js",
	"./fil.js": "./node_modules/moment/locale/fil.js",
	"./fo": "./node_modules/moment/locale/fo.js",
	"./fo.js": "./node_modules/moment/locale/fo.js",
	"./fr": "./node_modules/moment/locale/fr.js",
	"./fr-ca": "./node_modules/moment/locale/fr-ca.js",
	"./fr-ca.js": "./node_modules/moment/locale/fr-ca.js",
	"./fr-ch": "./node_modules/moment/locale/fr-ch.js",
	"./fr-ch.js": "./node_modules/moment/locale/fr-ch.js",
	"./fr.js": "./node_modules/moment/locale/fr.js",
	"./fy": "./node_modules/moment/locale/fy.js",
	"./fy.js": "./node_modules/moment/locale/fy.js",
	"./ga": "./node_modules/moment/locale/ga.js",
	"./ga.js": "./node_modules/moment/locale/ga.js",
	"./gd": "./node_modules/moment/locale/gd.js",
	"./gd.js": "./node_modules/moment/locale/gd.js",
	"./gl": "./node_modules/moment/locale/gl.js",
	"./gl.js": "./node_modules/moment/locale/gl.js",
	"./gom-deva": "./node_modules/moment/locale/gom-deva.js",
	"./gom-deva.js": "./node_modules/moment/locale/gom-deva.js",
	"./gom-latn": "./node_modules/moment/locale/gom-latn.js",
	"./gom-latn.js": "./node_modules/moment/locale/gom-latn.js",
	"./gu": "./node_modules/moment/locale/gu.js",
	"./gu.js": "./node_modules/moment/locale/gu.js",
	"./he": "./node_modules/moment/locale/he.js",
	"./he.js": "./node_modules/moment/locale/he.js",
	"./hi": "./node_modules/moment/locale/hi.js",
	"./hi.js": "./node_modules/moment/locale/hi.js",
	"./hr": "./node_modules/moment/locale/hr.js",
	"./hr.js": "./node_modules/moment/locale/hr.js",
	"./hu": "./node_modules/moment/locale/hu.js",
	"./hu.js": "./node_modules/moment/locale/hu.js",
	"./hy-am": "./node_modules/moment/locale/hy-am.js",
	"./hy-am.js": "./node_modules/moment/locale/hy-am.js",
	"./id": "./node_modules/moment/locale/id.js",
	"./id.js": "./node_modules/moment/locale/id.js",
	"./is": "./node_modules/moment/locale/is.js",
	"./is.js": "./node_modules/moment/locale/is.js",
	"./it": "./node_modules/moment/locale/it.js",
	"./it-ch": "./node_modules/moment/locale/it-ch.js",
	"./it-ch.js": "./node_modules/moment/locale/it-ch.js",
	"./it.js": "./node_modules/moment/locale/it.js",
	"./ja": "./node_modules/moment/locale/ja.js",
	"./ja.js": "./node_modules/moment/locale/ja.js",
	"./jv": "./node_modules/moment/locale/jv.js",
	"./jv.js": "./node_modules/moment/locale/jv.js",
	"./ka": "./node_modules/moment/locale/ka.js",
	"./ka.js": "./node_modules/moment/locale/ka.js",
	"./kk": "./node_modules/moment/locale/kk.js",
	"./kk.js": "./node_modules/moment/locale/kk.js",
	"./km": "./node_modules/moment/locale/km.js",
	"./km.js": "./node_modules/moment/locale/km.js",
	"./kn": "./node_modules/moment/locale/kn.js",
	"./kn.js": "./node_modules/moment/locale/kn.js",
	"./ko": "./node_modules/moment/locale/ko.js",
	"./ko.js": "./node_modules/moment/locale/ko.js",
	"./ku": "./node_modules/moment/locale/ku.js",
	"./ku.js": "./node_modules/moment/locale/ku.js",
	"./ky": "./node_modules/moment/locale/ky.js",
	"./ky.js": "./node_modules/moment/locale/ky.js",
	"./lb": "./node_modules/moment/locale/lb.js",
	"./lb.js": "./node_modules/moment/locale/lb.js",
	"./lo": "./node_modules/moment/locale/lo.js",
	"./lo.js": "./node_modules/moment/locale/lo.js",
	"./lt": "./node_modules/moment/locale/lt.js",
	"./lt.js": "./node_modules/moment/locale/lt.js",
	"./lv": "./node_modules/moment/locale/lv.js",
	"./lv.js": "./node_modules/moment/locale/lv.js",
	"./me": "./node_modules/moment/locale/me.js",
	"./me.js": "./node_modules/moment/locale/me.js",
	"./mi": "./node_modules/moment/locale/mi.js",
	"./mi.js": "./node_modules/moment/locale/mi.js",
	"./mk": "./node_modules/moment/locale/mk.js",
	"./mk.js": "./node_modules/moment/locale/mk.js",
	"./ml": "./node_modules/moment/locale/ml.js",
	"./ml.js": "./node_modules/moment/locale/ml.js",
	"./mn": "./node_modules/moment/locale/mn.js",
	"./mn.js": "./node_modules/moment/locale/mn.js",
	"./mr": "./node_modules/moment/locale/mr.js",
	"./mr.js": "./node_modules/moment/locale/mr.js",
	"./ms": "./node_modules/moment/locale/ms.js",
	"./ms-my": "./node_modules/moment/locale/ms-my.js",
	"./ms-my.js": "./node_modules/moment/locale/ms-my.js",
	"./ms.js": "./node_modules/moment/locale/ms.js",
	"./mt": "./node_modules/moment/locale/mt.js",
	"./mt.js": "./node_modules/moment/locale/mt.js",
	"./my": "./node_modules/moment/locale/my.js",
	"./my.js": "./node_modules/moment/locale/my.js",
	"./nb": "./node_modules/moment/locale/nb.js",
	"./nb.js": "./node_modules/moment/locale/nb.js",
	"./ne": "./node_modules/moment/locale/ne.js",
	"./ne.js": "./node_modules/moment/locale/ne.js",
	"./nl": "./node_modules/moment/locale/nl.js",
	"./nl-be": "./node_modules/moment/locale/nl-be.js",
	"./nl-be.js": "./node_modules/moment/locale/nl-be.js",
	"./nl.js": "./node_modules/moment/locale/nl.js",
	"./nn": "./node_modules/moment/locale/nn.js",
	"./nn.js": "./node_modules/moment/locale/nn.js",
	"./oc-lnc": "./node_modules/moment/locale/oc-lnc.js",
	"./oc-lnc.js": "./node_modules/moment/locale/oc-lnc.js",
	"./pa-in": "./node_modules/moment/locale/pa-in.js",
	"./pa-in.js": "./node_modules/moment/locale/pa-in.js",
	"./pl": "./node_modules/moment/locale/pl.js",
	"./pl.js": "./node_modules/moment/locale/pl.js",
	"./pt": "./node_modules/moment/locale/pt.js",
	"./pt-br": "./node_modules/moment/locale/pt-br.js",
	"./pt-br.js": "./node_modules/moment/locale/pt-br.js",
	"./pt.js": "./node_modules/moment/locale/pt.js",
	"./ro": "./node_modules/moment/locale/ro.js",
	"./ro.js": "./node_modules/moment/locale/ro.js",
	"./ru": "./node_modules/moment/locale/ru.js",
	"./ru.js": "./node_modules/moment/locale/ru.js",
	"./sd": "./node_modules/moment/locale/sd.js",
	"./sd.js": "./node_modules/moment/locale/sd.js",
	"./se": "./node_modules/moment/locale/se.js",
	"./se.js": "./node_modules/moment/locale/se.js",
	"./si": "./node_modules/moment/locale/si.js",
	"./si.js": "./node_modules/moment/locale/si.js",
	"./sk": "./node_modules/moment/locale/sk.js",
	"./sk.js": "./node_modules/moment/locale/sk.js",
	"./sl": "./node_modules/moment/locale/sl.js",
	"./sl.js": "./node_modules/moment/locale/sl.js",
	"./sq": "./node_modules/moment/locale/sq.js",
	"./sq.js": "./node_modules/moment/locale/sq.js",
	"./sr": "./node_modules/moment/locale/sr.js",
	"./sr-cyrl": "./node_modules/moment/locale/sr-cyrl.js",
	"./sr-cyrl.js": "./node_modules/moment/locale/sr-cyrl.js",
	"./sr.js": "./node_modules/moment/locale/sr.js",
	"./ss": "./node_modules/moment/locale/ss.js",
	"./ss.js": "./node_modules/moment/locale/ss.js",
	"./sv": "./node_modules/moment/locale/sv.js",
	"./sv.js": "./node_modules/moment/locale/sv.js",
	"./sw": "./node_modules/moment/locale/sw.js",
	"./sw.js": "./node_modules/moment/locale/sw.js",
	"./ta": "./node_modules/moment/locale/ta.js",
	"./ta.js": "./node_modules/moment/locale/ta.js",
	"./te": "./node_modules/moment/locale/te.js",
	"./te.js": "./node_modules/moment/locale/te.js",
	"./tet": "./node_modules/moment/locale/tet.js",
	"./tet.js": "./node_modules/moment/locale/tet.js",
	"./tg": "./node_modules/moment/locale/tg.js",
	"./tg.js": "./node_modules/moment/locale/tg.js",
	"./th": "./node_modules/moment/locale/th.js",
	"./th.js": "./node_modules/moment/locale/th.js",
	"./tk": "./node_modules/moment/locale/tk.js",
	"./tk.js": "./node_modules/moment/locale/tk.js",
	"./tl-ph": "./node_modules/moment/locale/tl-ph.js",
	"./tl-ph.js": "./node_modules/moment/locale/tl-ph.js",
	"./tlh": "./node_modules/moment/locale/tlh.js",
	"./tlh.js": "./node_modules/moment/locale/tlh.js",
	"./tr": "./node_modules/moment/locale/tr.js",
	"./tr.js": "./node_modules/moment/locale/tr.js",
	"./tzl": "./node_modules/moment/locale/tzl.js",
	"./tzl.js": "./node_modules/moment/locale/tzl.js",
	"./tzm": "./node_modules/moment/locale/tzm.js",
	"./tzm-latn": "./node_modules/moment/locale/tzm-latn.js",
	"./tzm-latn.js": "./node_modules/moment/locale/tzm-latn.js",
	"./tzm.js": "./node_modules/moment/locale/tzm.js",
	"./ug-cn": "./node_modules/moment/locale/ug-cn.js",
	"./ug-cn.js": "./node_modules/moment/locale/ug-cn.js",
	"./uk": "./node_modules/moment/locale/uk.js",
	"./uk.js": "./node_modules/moment/locale/uk.js",
	"./ur": "./node_modules/moment/locale/ur.js",
	"./ur.js": "./node_modules/moment/locale/ur.js",
	"./uz": "./node_modules/moment/locale/uz.js",
	"./uz-latn": "./node_modules/moment/locale/uz-latn.js",
	"./uz-latn.js": "./node_modules/moment/locale/uz-latn.js",
	"./uz.js": "./node_modules/moment/locale/uz.js",
	"./vi": "./node_modules/moment/locale/vi.js",
	"./vi.js": "./node_modules/moment/locale/vi.js",
	"./x-pseudo": "./node_modules/moment/locale/x-pseudo.js",
	"./x-pseudo.js": "./node_modules/moment/locale/x-pseudo.js",
	"./yo": "./node_modules/moment/locale/yo.js",
	"./yo.js": "./node_modules/moment/locale/yo.js",
	"./zh-cn": "./node_modules/moment/locale/zh-cn.js",
	"./zh-cn.js": "./node_modules/moment/locale/zh-cn.js",
	"./zh-hk": "./node_modules/moment/locale/zh-hk.js",
	"./zh-hk.js": "./node_modules/moment/locale/zh-hk.js",
	"./zh-mo": "./node_modules/moment/locale/zh-mo.js",
	"./zh-mo.js": "./node_modules/moment/locale/zh-mo.js",
	"./zh-tw": "./node_modules/moment/locale/zh-tw.js",
	"./zh-tw.js": "./node_modules/moment/locale/zh-tw.js"
};


function webpackContext(req) {
	var id = webpackContextResolve(req);
	return __webpack_require__(id);
}
function webpackContextResolve(req) {
	if(!__webpack_require__.o(map, req)) {
		var e = new Error("Cannot find module '" + req + "'");
		e.code = 'MODULE_NOT_FOUND';
		throw e;
	}
	return map[req];
}
webpackContext.keys = function webpackContextKeys() {
	return Object.keys(map);
};
webpackContext.resolve = webpackContextResolve;
module.exports = webpackContext;
webpackContext.id = "./node_modules/moment/locale sync recursive ^\\.\\/.*$";

/***/ }),

/***/ "grav-config":
/*!****************************!*\
  !*** external "GravAdmin" ***!
  \****************************/
/*! dynamic exports */
/*! export __esModule [maybe provided (runtime-defined)] [no usage info] [provision prevents renaming (no use info)] */
/*! other exports [maybe provided (runtime-defined)] [no usage info] */
/*! runtime requirements: module */
/***/ ((module) => {

"use strict";
module.exports = GravAdmin;

/***/ }),

/***/ "jquery":
/*!*************************!*\
  !*** external "jQuery" ***!
  \*************************/
/*! dynamic exports */
/*! export __esModule [maybe provided (runtime-defined)] [no usage info] [provision prevents renaming (no use info)] */
/*! other exports [maybe provided (runtime-defined)] [no usage info] */
/*! runtime requirements: module */
/***/ ((module) => {

"use strict";
module.exports = jQuery;

/***/ })

/******/ 	});
/************************************************************************/
/******/ 	// The module cache
/******/ 	var __webpack_module_cache__ = {};
/******/ 	
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/ 		// Check if module is in cache
/******/ 		if(__webpack_module_cache__[moduleId]) {
/******/ 			return __webpack_module_cache__[moduleId].exports;
/******/ 		}
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = __webpack_module_cache__[moduleId] = {
/******/ 			id: moduleId,
/******/ 			loaded: false,
/******/ 			exports: {}
/******/ 		};
/******/ 	
/******/ 		// Execute the module function
/******/ 		__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/ 	
/******/ 		// Flag the module as loaded
/******/ 		module.loaded = true;
/******/ 	
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/ 	
/******/ 	// expose the modules object (__webpack_modules__)
/******/ 	__webpack_require__.m = __webpack_modules__;
/******/ 	
/************************************************************************/
/******/ 	/* webpack/runtime/amd define */
/******/ 	(() => {
/******/ 		__webpack_require__.amdD = function () {
/******/ 			throw new Error('define cannot be used indirect');
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/compat get default export */
/******/ 	(() => {
/******/ 		// getDefaultExport function for compatibility with non-harmony modules
/******/ 		__webpack_require__.n = (module) => {
/******/ 			var getter = module && module.__esModule ?
/******/ 				() => module['default'] :
/******/ 				() => module;
/******/ 			__webpack_require__.d(getter, { a: getter });
/******/ 			return getter;
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/define property getters */
/******/ 	(() => {
/******/ 		// define getter functions for harmony exports
/******/ 		__webpack_require__.d = (exports, definition) => {
/******/ 			for(var key in definition) {
/******/ 				if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
/******/ 					Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
/******/ 				}
/******/ 			}
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/global */
/******/ 	(() => {
/******/ 		__webpack_require__.g = (function() {
/******/ 			if (typeof globalThis === 'object') return globalThis;
/******/ 			try {
/******/ 				return this || new Function('return this')();
/******/ 			} catch (e) {
/******/ 				if (typeof window === 'object') return window;
/******/ 			}
/******/ 		})();
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/hasOwnProperty shorthand */
/******/ 	(() => {
/******/ 		__webpack_require__.o = (obj, prop) => Object.prototype.hasOwnProperty.call(obj, prop)
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/make namespace object */
/******/ 	(() => {
/******/ 		// define __esModule on exports
/******/ 		__webpack_require__.r = (exports) => {
/******/ 			if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ 				Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ 			}
/******/ 			Object.defineProperty(exports, '__esModule', { value: true });
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/node module decorator */
/******/ 	(() => {
/******/ 		__webpack_require__.nmd = (module) => {
/******/ 			module.paths = [];
/******/ 			if (!module.children) module.children = [];
/******/ 			return module;
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/jsonp chunk loading */
/******/ 	(() => {
/******/ 		// no baseURI
/******/ 		
/******/ 		// object to store loaded and loading chunks
/******/ 		// undefined = chunk not loaded, null = chunk preloaded/prefetched
/******/ 		// Promise = chunk loading, 0 = chunk loaded
/******/ 		var installedChunks = {
/******/ 			"app": 0
/******/ 		};
/******/ 		
/******/ 		var deferredModules = [
/******/ 			["./app/main.js","vendor"]
/******/ 		];
/******/ 		// no chunk on demand loading
/******/ 		
/******/ 		// no prefetching
/******/ 		
/******/ 		// no preloaded
/******/ 		
/******/ 		// no HMR
/******/ 		
/******/ 		// no HMR manifest
/******/ 		
/******/ 		var checkDeferredModules = () => {
/******/ 		
/******/ 		};
/******/ 		function checkDeferredModulesImpl() {
/******/ 			var result;
/******/ 			for(var i = 0; i < deferredModules.length; i++) {
/******/ 				var deferredModule = deferredModules[i];
/******/ 				var fulfilled = true;
/******/ 				for(var j = 1; j < deferredModule.length; j++) {
/******/ 					var depId = deferredModule[j];
/******/ 					if(installedChunks[depId] !== 0) fulfilled = false;
/******/ 				}
/******/ 				if(fulfilled) {
/******/ 					deferredModules.splice(i--, 1);
/******/ 					result = __webpack_require__(__webpack_require__.s = deferredModule[0]);
/******/ 				}
/******/ 			}
/******/ 			if(deferredModules.length === 0) {
/******/ 				__webpack_require__.x();
/******/ 				__webpack_require__.x = () => {
/******/ 		
/******/ 				}
/******/ 			}
/******/ 			return result;
/******/ 		}
/******/ 		__webpack_require__.x = () => {
/******/ 			// reset startup function so it can be called again when more startup code is added
/******/ 			__webpack_require__.x = () => {
/******/ 		
/******/ 			}
/******/ 			chunkLoadingGlobal = chunkLoadingGlobal.slice();
/******/ 			for(var i = 0; i < chunkLoadingGlobal.length; i++) webpackJsonpCallback(chunkLoadingGlobal[i]);
/******/ 			return (checkDeferredModules = checkDeferredModulesImpl)();
/******/ 		};
/******/ 		
/******/ 		// install a JSONP callback for chunk loading
/******/ 		var webpackJsonpCallback = (data) => {
/******/ 			var [chunkIds, moreModules, runtime, executeModules] = data;
/******/ 			// add "moreModules" to the modules object,
/******/ 			// then flag all "chunkIds" as loaded and fire callback
/******/ 			var moduleId, chunkId, i = 0, resolves = [];
/******/ 			for(;i < chunkIds.length; i++) {
/******/ 				chunkId = chunkIds[i];
/******/ 				if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {
/******/ 					resolves.push(installedChunks[chunkId][0]);
/******/ 				}
/******/ 				installedChunks[chunkId] = 0;
/******/ 			}
/******/ 			for(moduleId in moreModules) {
/******/ 				if(__webpack_require__.o(moreModules, moduleId)) {
/******/ 					__webpack_require__.m[moduleId] = moreModules[moduleId];
/******/ 				}
/******/ 			}
/******/ 			if(runtime) runtime(__webpack_require__);
/******/ 			parentChunkLoadingFunction(data);
/******/ 			while(resolves.length) {
/******/ 				resolves.shift()();
/******/ 			}
/******/ 		
/******/ 			// add entry modules from loaded chunk to deferred list
/******/ 			if(executeModules) deferredModules.push.apply(deferredModules, executeModules);
/******/ 		
/******/ 			// run deferred modules when all chunks ready
/******/ 			return checkDeferredModules();
/******/ 		}
/******/ 		
/******/ 		var chunkLoadingGlobal = self["webpackChunkGrav"] = self["webpackChunkGrav"] || [];
/******/ 		var parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);
/******/ 		chunkLoadingGlobal.push = webpackJsonpCallback;
/******/ 	})();
/******/ 	
/************************************************************************/
/******/ 	// module exports must be returned from runtime so entry inlining is disabled
/******/ 	// run startup
/******/ 	return __webpack_require__.x();
/******/ })()
;