From 5bf66662a9bdd62c5bccab15e607cd95cfb8fcab Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Mon, 27 Jul 2020 10:05:23 +0200 Subject: Removed wordpress and phpmyadmin, my server doesn't handle it well and it brings shame on my familly --- srcs/wordpress/wp-includes/js/dist/edit-post.js | 7440 ----------------------- 1 file changed, 7440 deletions(-) delete mode 100644 srcs/wordpress/wp-includes/js/dist/edit-post.js (limited to 'srcs/wordpress/wp-includes/js/dist/edit-post.js') diff --git a/srcs/wordpress/wp-includes/js/dist/edit-post.js b/srcs/wordpress/wp-includes/js/dist/edit-post.js deleted file mode 100644 index 7f8669f..0000000 --- a/srcs/wordpress/wp-includes/js/dist/edit-post.js +++ /dev/null @@ -1,7440 +0,0 @@ -this["wp"] = this["wp"] || {}; this["wp"]["editPost"] = -/******/ (function(modules) { // webpackBootstrap -/******/ // The module cache -/******/ var installedModules = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ -/******/ // Check if module is in cache -/******/ if(installedModules[moduleId]) { -/******/ return installedModules[moduleId].exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = installedModules[moduleId] = { -/******/ i: moduleId, -/******/ l: false, -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); -/******/ -/******/ // Flag the module as loaded -/******/ module.l = true; -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = modules; -/******/ -/******/ // expose the module cache -/******/ __webpack_require__.c = installedModules; -/******/ -/******/ // define getter function for harmony exports -/******/ __webpack_require__.d = function(exports, name, getter) { -/******/ if(!__webpack_require__.o(exports, name)) { -/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); -/******/ } -/******/ }; -/******/ -/******/ // define __esModule on exports -/******/ __webpack_require__.r = function(exports) { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ -/******/ // create a fake namespace object -/******/ // mode & 1: value is a module id, require it -/******/ // mode & 2: merge all properties of value into the ns -/******/ // mode & 4: return value when already ns object -/******/ // mode & 8|1: behave like require -/******/ __webpack_require__.t = function(value, mode) { -/******/ if(mode & 1) value = __webpack_require__(value); -/******/ if(mode & 8) return value; -/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; -/******/ var ns = Object.create(null); -/******/ __webpack_require__.r(ns); -/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); -/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); -/******/ return ns; -/******/ }; -/******/ -/******/ // getDefaultExport function for compatibility with non-harmony modules -/******/ __webpack_require__.n = function(module) { -/******/ var getter = module && module.__esModule ? -/******/ function getDefault() { return module['default']; } : -/******/ function getModuleExports() { return module; }; -/******/ __webpack_require__.d(getter, 'a', getter); -/******/ return getter; -/******/ }; -/******/ -/******/ // Object.prototype.hasOwnProperty.call -/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; -/******/ -/******/ // __webpack_public_path__ -/******/ __webpack_require__.p = ""; -/******/ -/******/ -/******/ // Load entry module and return exports -/******/ return __webpack_require__(__webpack_require__.s = 345); -/******/ }) -/************************************************************************/ -/******/ ({ - -/***/ 0: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["element"]; }()); - -/***/ }), - -/***/ 1: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["i18n"]; }()); - -/***/ }), - -/***/ 10: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _defineProperty; }); -function _defineProperty(obj, key, value) { - if (key in obj) { - Object.defineProperty(obj, key, { - value: value, - enumerable: true, - configurable: true, - writable: true - }); - } else { - obj[key] = value; - } - - return obj; -} - -/***/ }), - -/***/ 11: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _createClass; }); -function _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); - } -} - -function _createClass(Constructor, protoProps, staticProps) { - if (protoProps) _defineProperties(Constructor.prototype, protoProps); - if (staticProps) _defineProperties(Constructor, staticProps); - return Constructor; -} - -/***/ }), - -/***/ 12: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _classCallCheck; }); -function _classCallCheck(instance, Constructor) { - if (!(instance instanceof Constructor)) { - throw new TypeError("Cannot call a class as a function"); - } -} - -/***/ }), - -/***/ 13: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _possibleConstructorReturn; }); -/* harmony import */ var _helpers_esm_typeof__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31); -/* harmony import */ var _assertThisInitialized__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5); - - -function _possibleConstructorReturn(self, call) { - if (call && (Object(_helpers_esm_typeof__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"])(call) === "object" || typeof call === "function")) { - return call; - } - - return Object(_assertThisInitialized__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"])(self); -} - -/***/ }), - -/***/ 14: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _getPrototypeOf; }); -function _getPrototypeOf(o) { - _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { - return o.__proto__ || Object.getPrototypeOf(o); - }; - return _getPrototypeOf(o); -} - -/***/ }), - -/***/ 142: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["notices"]; }()); - -/***/ }), - -/***/ 15: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; - -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js -function _setPrototypeOf(o, p) { - _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { - o.__proto__ = p; - return o; - }; - - return _setPrototypeOf(o, p); -} -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/inherits.js -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _inherits; }); - -function _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); -} - -/***/ }), - -/***/ 16: -/***/ (function(module, exports, __webpack_require__) { - -var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! - Copyright (c) 2017 Jed Watson. - Licensed under the MIT License (MIT), see - http://jedwatson.github.io/classnames -*/ -/* global define */ - -(function () { - 'use strict'; - - var hasOwn = {}.hasOwnProperty; - - function classNames () { - var classes = []; - - for (var i = 0; i < arguments.length; i++) { - var arg = arguments[i]; - if (!arg) continue; - - var argType = typeof arg; - - if (argType === 'string' || argType === 'number') { - classes.push(arg); - } else if (Array.isArray(arg) && arg.length) { - var inner = classNames.apply(null, arg); - if (inner) { - classes.push(inner); - } - } else if (argType === 'object') { - for (var key in arg) { - if (hasOwn.call(arg, key) && arg[key]) { - classes.push(key); - } - } - } - } - - return classes.join(' '); - } - - if ( true && module.exports) { - classNames.default = classNames; - module.exports = classNames; - } else if (true) { - // register as 'classnames', consistent with npm package name - !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = (function () { - return classNames; - }).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), - __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); - } else {} -}()); - - -/***/ }), - -/***/ 17: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; - -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js -function _arrayWithoutHoles(arr) { - if (Array.isArray(arr)) { - for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) { - arr2[i] = arr[i]; - } - - return arr2; - } -} -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/iterableToArray.js -var iterableToArray = __webpack_require__(30); - -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js -function _nonIterableSpread() { - throw new TypeError("Invalid attempt to spread non-iterable instance"); -} -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _toConsumableArray; }); - - - -function _toConsumableArray(arr) { - return _arrayWithoutHoles(arr) || Object(iterableToArray["a" /* default */])(arr) || _nonIterableSpread(); -} - -/***/ }), - -/***/ 18: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _extends; }); -function _extends() { - _extends = Object.assign || function (target) { - for (var i = 1; i < arguments.length; i++) { - var source = arguments[i]; - - for (var key in source) { - if (Object.prototype.hasOwnProperty.call(source, key)) { - target[key] = source[key]; - } - } - } - - return target; - }; - - return _extends.apply(this, arguments); -} - -/***/ }), - -/***/ 19: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["keycodes"]; }()); - -/***/ }), - -/***/ 2: -/***/ (function(module, exports) { - -(function() { module.exports = this["lodash"]; }()); - -/***/ }), - -/***/ 21: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; - -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js -function _objectWithoutPropertiesLoose(source, excluded) { - if (source == null) return {}; - var target = {}; - var sourceKeys = Object.keys(source); - var key, i; - - for (i = 0; i < sourceKeys.length; i++) { - key = sourceKeys[i]; - if (excluded.indexOf(key) >= 0) continue; - target[key] = source[key]; - } - - return target; -} -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _objectWithoutProperties; }); - -function _objectWithoutProperties(source, excluded) { - if (source == null) return {}; - var target = _objectWithoutPropertiesLoose(source, excluded); - var key, i; - - if (Object.getOwnPropertySymbols) { - var sourceSymbolKeys = Object.getOwnPropertySymbols(source); - - for (i = 0; i < sourceSymbolKeys.length; i++) { - key = sourceSymbolKeys[i]; - if (excluded.indexOf(key) >= 0) continue; - if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; - target[key] = source[key]; - } - } - - return target; -} - -/***/ }), - -/***/ 23: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; - -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js -var arrayWithHoles = __webpack_require__(38); - -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js -function _iterableToArrayLimit(arr, i) { - var _arr = []; - var _n = true; - var _d = false; - var _e = undefined; - - try { - for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { - _arr.push(_s.value); - - if (i && _arr.length === i) break; - } - } catch (err) { - _d = true; - _e = err; - } finally { - try { - if (!_n && _i["return"] != null) _i["return"](); - } finally { - if (_d) throw _e; - } - } - - return _arr; -} -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/nonIterableRest.js -var nonIterableRest = __webpack_require__(39); - -// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _slicedToArray; }); - - - -function _slicedToArray(arr, i) { - return Object(arrayWithHoles["a" /* default */])(arr) || _iterableToArrayLimit(arr, i) || Object(nonIterableRest["a" /* default */])(); -} - -/***/ }), - -/***/ 231: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["blockLibrary"]; }()); - -/***/ }), - -/***/ 24: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["editor"]; }()); - -/***/ }), - -/***/ 26: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["url"]; }()); - -/***/ }), - -/***/ 27: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["hooks"]; }()); - -/***/ }), - -/***/ 3: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["components"]; }()); - -/***/ }), - -/***/ 30: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _iterableToArray; }); -function _iterableToArray(iter) { - if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); -} - -/***/ }), - -/***/ 31: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _typeof; }); -function _typeof2(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof2 = function _typeof2(obj) { return typeof obj; }; } else { _typeof2 = function _typeof2(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof2(obj); } - -function _typeof(obj) { - if (typeof Symbol === "function" && _typeof2(Symbol.iterator) === "symbol") { - _typeof = function _typeof(obj) { - return _typeof2(obj); - }; - } else { - _typeof = function _typeof(obj) { - return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : _typeof2(obj); - }; - } - - return _typeof(obj); -} - -/***/ }), - -/***/ 34: -/***/ (function(module, exports) { - -(function() { module.exports = this["wp"]["apiFetch"]; }()); - -/***/ }), - -/***/ 345: -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -var actions_namespaceObject = {}; -__webpack_require__.r(actions_namespaceObject); -__webpack_require__.d(actions_namespaceObject, "openGeneralSidebar", function() { return actions_openGeneralSidebar; }); -__webpack_require__.d(actions_namespaceObject, "closeGeneralSidebar", function() { return actions_closeGeneralSidebar; }); -__webpack_require__.d(actions_namespaceObject, "openModal", function() { return actions_openModal; }); -__webpack_require__.d(actions_namespaceObject, "closeModal", function() { return actions_closeModal; }); -__webpack_require__.d(actions_namespaceObject, "openPublishSidebar", function() { return openPublishSidebar; }); -__webpack_require__.d(actions_namespaceObject, "closePublishSidebar", function() { return actions_closePublishSidebar; }); -__webpack_require__.d(actions_namespaceObject, "togglePublishSidebar", function() { return actions_togglePublishSidebar; }); -__webpack_require__.d(actions_namespaceObject, "toggleEditorPanelEnabled", function() { return toggleEditorPanelEnabled; }); -__webpack_require__.d(actions_namespaceObject, "toggleEditorPanelOpened", function() { return actions_toggleEditorPanelOpened; }); -__webpack_require__.d(actions_namespaceObject, "removeEditorPanel", function() { return removeEditorPanel; }); -__webpack_require__.d(actions_namespaceObject, "toggleFeature", function() { return toggleFeature; }); -__webpack_require__.d(actions_namespaceObject, "switchEditorMode", function() { return switchEditorMode; }); -__webpack_require__.d(actions_namespaceObject, "togglePinnedPluginItem", function() { return togglePinnedPluginItem; }); -__webpack_require__.d(actions_namespaceObject, "hideBlockTypes", function() { return actions_hideBlockTypes; }); -__webpack_require__.d(actions_namespaceObject, "updatePreferredStyleVariations", function() { return actions_updatePreferredStyleVariations; }); -__webpack_require__.d(actions_namespaceObject, "__experimentalUpdateLocalAutosaveInterval", function() { return __experimentalUpdateLocalAutosaveInterval; }); -__webpack_require__.d(actions_namespaceObject, "showBlockTypes", function() { return actions_showBlockTypes; }); -__webpack_require__.d(actions_namespaceObject, "setAvailableMetaBoxesPerLocation", function() { return setAvailableMetaBoxesPerLocation; }); -__webpack_require__.d(actions_namespaceObject, "requestMetaBoxUpdates", function() { return requestMetaBoxUpdates; }); -__webpack_require__.d(actions_namespaceObject, "metaBoxUpdatesSuccess", function() { return metaBoxUpdatesSuccess; }); -var selectors_namespaceObject = {}; -__webpack_require__.r(selectors_namespaceObject); -__webpack_require__.d(selectors_namespaceObject, "getEditorMode", function() { return getEditorMode; }); -__webpack_require__.d(selectors_namespaceObject, "isEditorSidebarOpened", function() { return selectors_isEditorSidebarOpened; }); -__webpack_require__.d(selectors_namespaceObject, "isPluginSidebarOpened", function() { return isPluginSidebarOpened; }); -__webpack_require__.d(selectors_namespaceObject, "getActiveGeneralSidebarName", function() { return getActiveGeneralSidebarName; }); -__webpack_require__.d(selectors_namespaceObject, "getPreferences", function() { return getPreferences; }); -__webpack_require__.d(selectors_namespaceObject, "getPreference", function() { return selectors_getPreference; }); -__webpack_require__.d(selectors_namespaceObject, "isPublishSidebarOpened", function() { return selectors_isPublishSidebarOpened; }); -__webpack_require__.d(selectors_namespaceObject, "isEditorPanelRemoved", function() { return isEditorPanelRemoved; }); -__webpack_require__.d(selectors_namespaceObject, "isEditorPanelEnabled", function() { return selectors_isEditorPanelEnabled; }); -__webpack_require__.d(selectors_namespaceObject, "isEditorPanelOpened", function() { return selectors_isEditorPanelOpened; }); -__webpack_require__.d(selectors_namespaceObject, "isModalActive", function() { return selectors_isModalActive; }); -__webpack_require__.d(selectors_namespaceObject, "isFeatureActive", function() { return isFeatureActive; }); -__webpack_require__.d(selectors_namespaceObject, "isPluginItemPinned", function() { return isPluginItemPinned; }); -__webpack_require__.d(selectors_namespaceObject, "getActiveMetaBoxLocations", function() { return getActiveMetaBoxLocations; }); -__webpack_require__.d(selectors_namespaceObject, "isMetaBoxLocationVisible", function() { return isMetaBoxLocationVisible; }); -__webpack_require__.d(selectors_namespaceObject, "isMetaBoxLocationActive", function() { return isMetaBoxLocationActive; }); -__webpack_require__.d(selectors_namespaceObject, "getMetaBoxesPerLocation", function() { return getMetaBoxesPerLocation; }); -__webpack_require__.d(selectors_namespaceObject, "getAllMetaBoxes", function() { return getAllMetaBoxes; }); -__webpack_require__.d(selectors_namespaceObject, "hasMetaBoxes", function() { return hasMetaBoxes; }); -__webpack_require__.d(selectors_namespaceObject, "isSavingMetaBoxes", function() { return selectors_isSavingMetaBoxes; }); - -// EXTERNAL MODULE: external {"this":["wp","element"]} -var external_this_wp_element_ = __webpack_require__(0); - -// EXTERNAL MODULE: external {"this":["wp","coreData"]} -var external_this_wp_coreData_ = __webpack_require__(89); - -// EXTERNAL MODULE: external {"this":["wp","blockEditor"]} -var external_this_wp_blockEditor_ = __webpack_require__(6); - -// EXTERNAL MODULE: external {"this":["wp","editor"]} -var external_this_wp_editor_ = __webpack_require__(24); - -// EXTERNAL MODULE: external {"this":["wp","nux"]} -var external_this_wp_nux_ = __webpack_require__(61); - -// EXTERNAL MODULE: external {"this":["wp","viewport"]} -var external_this_wp_viewport_ = __webpack_require__(42); - -// EXTERNAL MODULE: external {"this":["wp","notices"]} -var external_this_wp_notices_ = __webpack_require__(142); - -// EXTERNAL MODULE: external {"this":["wp","blockLibrary"]} -var external_this_wp_blockLibrary_ = __webpack_require__(231); - -// EXTERNAL MODULE: external {"this":["wp","hooks"]} -var external_this_wp_hooks_ = __webpack_require__(27); - -// EXTERNAL MODULE: external {"this":["wp","mediaUtils"]} -var external_this_wp_mediaUtils_ = __webpack_require__(99); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/hooks/components/index.js -/** - * WordPress dependencies - */ - - - -var components_replaceMediaUpload = function replaceMediaUpload() { - return external_this_wp_mediaUtils_["MediaUpload"]; -}; - -Object(external_this_wp_hooks_["addFilter"])('editor.MediaUpload', 'core/edit-post/replace-media-upload', components_replaceMediaUpload); - -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/extends.js -var esm_extends = __webpack_require__(18); - -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js + 1 modules -var objectWithoutProperties = __webpack_require__(21); - -// EXTERNAL MODULE: external "lodash" -var external_lodash_ = __webpack_require__(2); - -// EXTERNAL MODULE: external {"this":["wp","blocks"]} -var external_this_wp_blocks_ = __webpack_require__(9); - -// EXTERNAL MODULE: external {"this":["wp","components"]} -var external_this_wp_components_ = __webpack_require__(3); - -// EXTERNAL MODULE: external {"this":["wp","data"]} -var external_this_wp_data_ = __webpack_require__(4); - -// EXTERNAL MODULE: external {"this":["wp","i18n"]} -var external_this_wp_i18n_ = __webpack_require__(1); - -// EXTERNAL MODULE: external {"this":["wp","compose"]} -var external_this_wp_compose_ = __webpack_require__(8); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/hooks/validate-multiple-use/index.js - - - - -/** - * External dependencies - */ - -/** - * WordPress dependencies - */ - - - - - - - - -var enhance = Object(external_this_wp_compose_["compose"])( -/** - * For blocks whose block type doesn't support `multiple`, provides the - * wrapped component with `originalBlockClientId` -- a reference to the - * first block of the same type in the content -- if and only if that - * "original" block is not the current one. Thus, an inexisting - * `originalBlockClientId` prop signals that the block is valid. - * - * @param {Component} WrappedBlockEdit A filtered BlockEdit instance. - * - * @return {Component} Enhanced component with merged state data props. - */ -Object(external_this_wp_data_["withSelect"])(function (select, block) { - var multiple = Object(external_this_wp_blocks_["hasBlockSupport"])(block.name, 'multiple', true); // For block types with `multiple` support, there is no "original - // block" to be found in the content, as the block itself is valid. - - if (multiple) { - return {}; - } // Otherwise, only pass `originalBlockClientId` if it refers to a different - // block from the current one. - - - var blocks = select('core/block-editor').getBlocks(); - var firstOfSameType = Object(external_lodash_["find"])(blocks, function (_ref) { - var name = _ref.name; - return block.name === name; - }); - var isInvalid = firstOfSameType && firstOfSameType.clientId !== block.clientId; - return { - originalBlockClientId: isInvalid && firstOfSameType.clientId - }; -}), Object(external_this_wp_data_["withDispatch"])(function (dispatch, _ref2) { - var originalBlockClientId = _ref2.originalBlockClientId; - return { - selectFirst: function selectFirst() { - return dispatch('core/block-editor').selectBlock(originalBlockClientId); - } - }; -})); -var withMultipleValidation = Object(external_this_wp_compose_["createHigherOrderComponent"])(function (BlockEdit) { - return enhance(function (_ref3) { - var originalBlockClientId = _ref3.originalBlockClientId, - selectFirst = _ref3.selectFirst, - props = Object(objectWithoutProperties["a" /* default */])(_ref3, ["originalBlockClientId", "selectFirst"]); - - if (!originalBlockClientId) { - return Object(external_this_wp_element_["createElement"])(BlockEdit, props); - } - - var blockType = Object(external_this_wp_blocks_["getBlockType"])(props.name); - var outboundType = getOutboundType(props.name); - return [Object(external_this_wp_element_["createElement"])("div", { - key: "invalid-preview", - style: { - minHeight: '60px' - } - }, Object(external_this_wp_element_["createElement"])(BlockEdit, Object(esm_extends["a" /* default */])({ - key: "block-edit" - }, props))), Object(external_this_wp_element_["createElement"])(external_this_wp_blockEditor_["Warning"], { - key: "multiple-use-warning", - actions: [Object(external_this_wp_element_["createElement"])(external_this_wp_components_["Button"], { - key: "find-original", - isLarge: true, - onClick: selectFirst - }, Object(external_this_wp_i18n_["__"])('Find original')), Object(external_this_wp_element_["createElement"])(external_this_wp_components_["Button"], { - key: "remove", - isLarge: true, - onClick: function onClick() { - return props.onReplace([]); - } - }, Object(external_this_wp_i18n_["__"])('Remove')), outboundType && Object(external_this_wp_element_["createElement"])(external_this_wp_components_["Button"], { - key: "transform", - isLarge: true, - onClick: function onClick() { - return props.onReplace(Object(external_this_wp_blocks_["createBlock"])(outboundType.name, props.attributes)); - } - }, Object(external_this_wp_i18n_["__"])('Transform into:'), ' ', outboundType.title)] - }, Object(external_this_wp_element_["createElement"])("strong", null, blockType.title, ": "), Object(external_this_wp_i18n_["__"])('This block can only be used once.'))]; - }); -}, 'withMultipleValidation'); -/** - * Given a base block name, returns the default block type to which to offer - * transforms. - * - * @param {string} blockName Base block name. - * - * @return {?Object} The chosen default block type. - */ - -function getOutboundType(blockName) { - // Grab the first outbound transform - var transform = Object(external_this_wp_blocks_["findTransform"])(Object(external_this_wp_blocks_["getBlockTransforms"])('to', blockName), function (_ref4) { - var type = _ref4.type, - blocks = _ref4.blocks; - return type === 'block' && blocks.length === 1; - } // What about when .length > 1? - ); - - if (!transform) { - return null; - } - - return Object(external_this_wp_blocks_["getBlockType"])(transform.blocks[0]); -} - -Object(external_this_wp_hooks_["addFilter"])('editor.BlockEdit', 'core/edit-post/validate-multiple-use/with-multiple-validation', withMultipleValidation); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/hooks/index.js -/** - * Internal dependencies - */ - - - -// EXTERNAL MODULE: external {"this":["wp","plugins"]} -var external_this_wp_plugins_ = __webpack_require__(51); - -// EXTERNAL MODULE: external {"this":["wp","url"]} -var external_this_wp_url_ = __webpack_require__(26); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/plugins/copy-content-menu-item/index.js - - -/** - * WordPress dependencies - */ - - - - - -function CopyContentMenuItem(_ref) { - var createNotice = _ref.createNotice, - editedPostContent = _ref.editedPostContent, - hasCopied = _ref.hasCopied, - setState = _ref.setState; - return editedPostContent.length > 0 && Object(external_this_wp_element_["createElement"])(external_this_wp_components_["ClipboardButton"], { - text: editedPostContent, - role: "menuitem", - className: "components-menu-item__button", - onCopy: function onCopy() { - setState({ - hasCopied: true - }); - createNotice('info', Object(external_this_wp_i18n_["__"])('All content copied.'), { - isDismissible: true, - type: 'snackbar' - }); - }, - onFinishCopy: function onFinishCopy() { - return setState({ - hasCopied: false - }); - } - }, hasCopied ? Object(external_this_wp_i18n_["__"])('Copied!') : Object(external_this_wp_i18n_["__"])('Copy All Content')); -} - -/* harmony default export */ var copy_content_menu_item = (Object(external_this_wp_compose_["compose"])(Object(external_this_wp_data_["withSelect"])(function (select) { - return { - editedPostContent: select('core/editor').getEditedPostAttribute('content') - }; -}), Object(external_this_wp_data_["withDispatch"])(function (dispatch) { - var _dispatch = dispatch('core/notices'), - createNotice = _dispatch.createNotice; - - return { - createNotice: createNotice - }; -}), Object(external_this_wp_compose_["withState"])({ - hasCopied: false -}))(CopyContentMenuItem)); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/plugins/manage-blocks-menu-item/index.js - - -/** - * WordPress dependencies - */ - - - -function ManageBlocksMenuItem(_ref) { - var openModal = _ref.openModal; - return Object(external_this_wp_element_["createElement"])(external_this_wp_components_["MenuItem"], { - onClick: function onClick() { - openModal('edit-post/manage-blocks'); - } - }, Object(external_this_wp_i18n_["__"])('Block Manager')); -} -/* harmony default export */ var manage_blocks_menu_item = (Object(external_this_wp_data_["withDispatch"])(function (dispatch) { - var _dispatch = dispatch('core/edit-post'), - openModal = _dispatch.openModal; - - return { - openModal: openModal - }; -})(ManageBlocksMenuItem)); - -// EXTERNAL MODULE: external {"this":["wp","keycodes"]} -var external_this_wp_keycodes_ = __webpack_require__(19); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/plugins/keyboard-shortcuts-help-menu-item/index.js - - -/** - * WordPress dependencies - */ - - - - -function KeyboardShortcutsHelpMenuItem(_ref) { - var openModal = _ref.openModal; - return Object(external_this_wp_element_["createElement"])(external_this_wp_components_["MenuItem"], { - onClick: function onClick() { - openModal('edit-post/keyboard-shortcut-help'); - }, - shortcut: external_this_wp_keycodes_["displayShortcut"].access('h') - }, Object(external_this_wp_i18n_["__"])('Keyboard Shortcuts')); -} -/* harmony default export */ var keyboard_shortcuts_help_menu_item = (Object(external_this_wp_data_["withDispatch"])(function (dispatch) { - var _dispatch = dispatch('core/edit-post'), - openModal = _dispatch.openModal; - - return { - openModal: openModal - }; -})(KeyboardShortcutsHelpMenuItem)); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/components/header/tools-more-menu-group/index.js - - -/** - * External dependencies - */ - -/** - * WordPress dependencies - */ - - - - -var _createSlotFill = Object(external_this_wp_components_["createSlotFill"])('ToolsMoreMenuGroup'), - ToolsMoreMenuGroup = _createSlotFill.Fill, - Slot = _createSlotFill.Slot; - -ToolsMoreMenuGroup.Slot = function (_ref) { - var fillProps = _ref.fillProps; - return Object(external_this_wp_element_["createElement"])(Slot, { - fillProps: fillProps - }, function (fills) { - return !Object(external_lodash_["isEmpty"])(fills) && Object(external_this_wp_element_["createElement"])(external_this_wp_components_["MenuGroup"], { - label: Object(external_this_wp_i18n_["__"])('Tools') - }, fills); - }); -}; - -/* harmony default export */ var tools_more_menu_group = (ToolsMoreMenuGroup); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/plugins/index.js - - -/** - * WordPress dependencies - */ - - - - -/** - * Internal dependencies - */ - - - - - -Object(external_this_wp_plugins_["registerPlugin"])('edit-post', { - render: function render() { - return Object(external_this_wp_element_["createElement"])(external_this_wp_element_["Fragment"], null, Object(external_this_wp_element_["createElement"])(tools_more_menu_group, null, function (_ref) { - var onClose = _ref.onClose; - return Object(external_this_wp_element_["createElement"])(external_this_wp_element_["Fragment"], null, Object(external_this_wp_element_["createElement"])(manage_blocks_menu_item, { - onSelect: onClose - }), Object(external_this_wp_element_["createElement"])(external_this_wp_components_["MenuItem"], { - role: "menuitem", - href: Object(external_this_wp_url_["addQueryArgs"])('edit.php', { - post_type: 'wp_block' - }) - }, Object(external_this_wp_i18n_["__"])('Manage All Reusable Blocks')), Object(external_this_wp_element_["createElement"])(keyboard_shortcuts_help_menu_item, { - onSelect: onClose - }), Object(external_this_wp_element_["createElement"])(copy_content_menu_item, null)); - })); - } -}); - -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js + 2 modules -var toConsumableArray = __webpack_require__(17); - -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/defineProperty.js -var defineProperty = __webpack_require__(10); - -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/objectSpread.js -var objectSpread = __webpack_require__(7); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/store/defaults.js -var PREFERENCES_DEFAULTS = { - editorMode: 'visual', - isGeneralSidebarDismissed: false, - panels: { - 'post-status': { - opened: true - } - }, - features: { - fixedToolbar: false, - showInserterHelpPanel: true - }, - pinnedPluginItems: {}, - hiddenBlockTypes: [], - preferredStyleVariations: {}, - localAutosaveInterval: 15 -}; - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/store/reducer.js - - - - -/** - * External dependencies - */ - -/** - * WordPress dependencies - */ - - -/** - * Internal dependencies - */ - - -/** - * The default active general sidebar: The "Document" tab. - * - * @type {string} - */ - -var DEFAULT_ACTIVE_GENERAL_SIDEBAR = 'edit-post/document'; -/** - * Higher-order reducer creator which provides the given initial state for the - * original reducer. - * - * @param {*} initialState Initial state to provide to reducer. - * - * @return {Function} Higher-order reducer. - */ - -var createWithInitialState = function createWithInitialState(initialState) { - return function (reducer) { - return function () { - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : initialState; - var action = arguments.length > 1 ? arguments[1] : undefined; - return reducer(state, action); - }; - }; -}; -/** - * Reducer returning the user preferences. - * - * @param {Object} state Current state. - * @param {string} state.mode Current editor mode, either - * "visual" or "text". - * @param {boolean} state.isGeneralSidebarDismissed Whether general sidebar is - * dismissed. False by default - * or when closing general - * sidebar, true when opening - * sidebar. - * @param {boolean} state.isSidebarOpened Whether the sidebar is - * opened or closed. - * @param {Object} state.panels The state of the different - * sidebar panels. - * @param {Object} action Dispatched action. - * - * @return {Object} Updated state. - */ - - -var preferences = Object(external_lodash_["flow"])([external_this_wp_data_["combineReducers"], createWithInitialState(PREFERENCES_DEFAULTS)])({ - isGeneralSidebarDismissed: function isGeneralSidebarDismissed(state, action) { - switch (action.type) { - case 'OPEN_GENERAL_SIDEBAR': - case 'CLOSE_GENERAL_SIDEBAR': - return action.type === 'CLOSE_GENERAL_SIDEBAR'; - } - - return state; - }, - panels: function panels(state, action) { - switch (action.type) { - case 'TOGGLE_PANEL_ENABLED': - { - var panelName = action.panelName; - return Object(objectSpread["a" /* default */])({}, state, Object(defineProperty["a" /* default */])({}, panelName, Object(objectSpread["a" /* default */])({}, state[panelName], { - enabled: !Object(external_lodash_["get"])(state, [panelName, 'enabled'], true) - }))); - } - - case 'TOGGLE_PANEL_OPENED': - { - var _panelName = action.panelName; - var isOpen = state[_panelName] === true || Object(external_lodash_["get"])(state, [_panelName, 'opened'], false); - return Object(objectSpread["a" /* default */])({}, state, Object(defineProperty["a" /* default */])({}, _panelName, Object(objectSpread["a" /* default */])({}, state[_panelName], { - opened: !isOpen - }))); - } - } - - return state; - }, - features: function features(state, action) { - if (action.type === 'TOGGLE_FEATURE') { - return Object(objectSpread["a" /* default */])({}, state, Object(defineProperty["a" /* default */])({}, action.feature, !state[action.feature])); - } - - return state; - }, - editorMode: function editorMode(state, action) { - if (action.type === 'SWITCH_MODE') { - return action.mode; - } - - return state; - }, - pinnedPluginItems: function pinnedPluginItems(state, action) { - if (action.type === 'TOGGLE_PINNED_PLUGIN_ITEM') { - return Object(objectSpread["a" /* default */])({}, state, Object(defineProperty["a" /* default */])({}, action.pluginName, !Object(external_lodash_["get"])(state, [action.pluginName], true))); - } - - return state; - }, - hiddenBlockTypes: function hiddenBlockTypes(state, action) { - switch (action.type) { - case 'SHOW_BLOCK_TYPES': - return external_lodash_["without"].apply(void 0, [state].concat(Object(toConsumableArray["a" /* default */])(action.blockNames))); - - case 'HIDE_BLOCK_TYPES': - return Object(external_lodash_["union"])(state, action.blockNames); - } - - return state; - }, - preferredStyleVariations: function preferredStyleVariations(state, action) { - switch (action.type) { - case 'UPDATE_PREFERRED_STYLE_VARIATIONS': - { - if (!action.blockName) { - return state; - } - - if (!action.blockStyle) { - return Object(external_lodash_["omit"])(state, [action.blockName]); - } - - return Object(objectSpread["a" /* default */])({}, state, Object(defineProperty["a" /* default */])({}, action.blockName, action.blockStyle)); - } - } - - return state; - }, - localAutosaveInterval: function localAutosaveInterval(state, action) { - switch (action.type) { - case 'UPDATE_LOCAL_AUTOSAVE_INTERVAL': - return action.interval; - } - - return state; - } -}); -/** - * Reducer storing the list of all programmatically removed panels. - * - * @param {Array} state Current state. - * @param {Object} action Action object. - * - * @return {Array} Updated state. - */ - -function removedPanels() { - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : []; - var action = arguments.length > 1 ? arguments[1] : undefined; - - switch (action.type) { - case 'REMOVE_PANEL': - if (!Object(external_lodash_["includes"])(state, action.panelName)) { - return [].concat(Object(toConsumableArray["a" /* default */])(state), [action.panelName]); - } - - } - - return state; -} -/** - * Reducer returning the next active general sidebar state. The active general - * sidebar is a unique name to identify either an editor or plugin sidebar. - * - * @param {?string} state Current state. - * @param {Object} action Action object. - * - * @return {?string} Updated state. - */ - -function reducer_activeGeneralSidebar() { - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : DEFAULT_ACTIVE_GENERAL_SIDEBAR; - var action = arguments.length > 1 ? arguments[1] : undefined; - - switch (action.type) { - case 'OPEN_GENERAL_SIDEBAR': - return action.name; - } - - return state; -} -/** - * Reducer for storing the name of the open modal, or null if no modal is open. - * - * @param {Object} state Previous state. - * @param {Object} action Action object containing the `name` of the modal - * - * @return {Object} Updated state - */ - -function activeModal() { - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null; - var action = arguments.length > 1 ? arguments[1] : undefined; - - switch (action.type) { - case 'OPEN_MODAL': - return action.name; - - case 'CLOSE_MODAL': - return null; - } - - return state; -} -function publishSidebarActive() { - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false; - var action = arguments.length > 1 ? arguments[1] : undefined; - - switch (action.type) { - case 'OPEN_PUBLISH_SIDEBAR': - return true; - - case 'CLOSE_PUBLISH_SIDEBAR': - return false; - - case 'TOGGLE_PUBLISH_SIDEBAR': - return !state; - } - - return state; -} -/** - * Reducer keeping track of the meta boxes isSaving state. - * A "true" value means the meta boxes saving request is in-flight. - * - * - * @param {boolean} state Previous state. - * @param {Object} action Action Object. - * - * @return {Object} Updated state. - */ - -function isSavingMetaBoxes() { - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false; - var action = arguments.length > 1 ? arguments[1] : undefined; - - switch (action.type) { - case 'REQUEST_META_BOX_UPDATES': - return true; - - case 'META_BOX_UPDATES_SUCCESS': - return false; - - default: - return state; - } -} -/** - * Reducer keeping track of the meta boxes per location. - * - * @param {boolean} state Previous state. - * @param {Object} action Action Object. - * - * @return {Object} Updated state. - */ - -function metaBoxLocations() { - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; - var action = arguments.length > 1 ? arguments[1] : undefined; - - switch (action.type) { - case 'SET_META_BOXES_PER_LOCATIONS': - return action.metaBoxesPerLocation; - } - - return state; -} -var reducer_metaBoxes = Object(external_this_wp_data_["combineReducers"])({ - isSaving: isSavingMetaBoxes, - locations: metaBoxLocations -}); -/* harmony default export */ var reducer = (Object(external_this_wp_data_["combineReducers"])({ - activeGeneralSidebar: reducer_activeGeneralSidebar, - activeModal: activeModal, - metaBoxes: reducer_metaBoxes, - preferences: preferences, - publishSidebarActive: publishSidebarActive, - removedPanels: removedPanels -})); - -// EXTERNAL MODULE: ./node_modules/refx/refx.js -var refx = __webpack_require__(72); -var refx_default = /*#__PURE__*/__webpack_require__.n(refx); - -// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js + 1 modules -var slicedToArray = __webpack_require__(23); - -// EXTERNAL MODULE: external {"this":["wp","a11y"]} -var external_this_wp_a11y_ = __webpack_require__(45); - -// EXTERNAL MODULE: external {"this":["wp","apiFetch"]} -var external_this_wp_apiFetch_ = __webpack_require__(34); -var external_this_wp_apiFetch_default = /*#__PURE__*/__webpack_require__.n(external_this_wp_apiFetch_); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/store/actions.js -/** - * External dependencies - */ - -/** - * Returns an action object used in signalling that the user opened an editor sidebar. - * - * @param {string} name Sidebar name to be opened. - * - * @return {Object} Action object. - */ - -function actions_openGeneralSidebar(name) { - return { - type: 'OPEN_GENERAL_SIDEBAR', - name: name - }; -} -/** - * Returns an action object signalling that the user closed the sidebar. - * - * @return {Object} Action object. - */ - -function actions_closeGeneralSidebar() { - return { - type: 'CLOSE_GENERAL_SIDEBAR' - }; -} -/** - * Returns an action object used in signalling that the user opened a modal. - * - * @param {string} name A string that uniquely identifies the modal. - * - * @return {Object} Action object. - */ - -function actions_openModal(name) { - return { - type: 'OPEN_MODAL', - name: name - }; -} -/** - * Returns an action object signalling that the user closed a modal. - * - * @return {Object} Action object. - */ - -function actions_closeModal() { - return { - type: 'CLOSE_MODAL' - }; -} -/** - * Returns an action object used in signalling that the user opened the publish - * sidebar. - * - * @return {Object} Action object - */ - -function openPublishSidebar() { - return { - type: 'OPEN_PUBLISH_SIDEBAR' - }; -} -/** - * Returns an action object used in signalling that the user closed the - * publish sidebar. - * - * @return {Object} Action object. - */ - -function actions_closePublishSidebar() { - return { - type: 'CLOSE_PUBLISH_SIDEBAR' - }; -} -/** - * Returns an action object used in signalling that the user toggles the publish sidebar. - * - * @return {Object} Action object - */ - -function actions_togglePublishSidebar() { - return { - type: 'TOGGLE_PUBLISH_SIDEBAR' - }; -} -/** - * Returns an action object used to enable or disable a panel in the editor. - * - * @param {string} panelName A string that identifies the panel to enable or disable. - * - * @return {Object} Action object. - */ - -function toggleEditorPanelEnabled(panelName) { - return { - type: 'TOGGLE_PANEL_ENABLED', - panelName: panelName - }; -} -/** - * Returns an action object used to open or close a panel in the editor. - * - * @param {string} panelName A string that identifies the panel to open or close. - * - * @return {Object} Action object. - */ - -function actions_toggleEditorPanelOpened(panelName) { - return { - type: 'TOGGLE_PANEL_OPENED', - panelName: panelName - }; -} -/** - * Returns an action object used to remove a panel from the editor. - * - * @param {string} panelName A string that identifies the panel to remove. - * - * @return {Object} Action object. - */ - -function removeEditorPanel(panelName) { - return { - type: 'REMOVE_PANEL', - panelName: panelName - }; -} -/** - * Returns an action object used to toggle a feature flag. - * - * @param {string} feature Feature name. - * - * @return {Object} Action object. - */ - -function toggleFeature(feature) { - return { - type: 'TOGGLE_FEATURE', - feature: feature - }; -} -function switchEditorMode(mode) { - return { - type: 'SWITCH_MODE', - mode: mode - }; -} -/** - * Returns an action object used to toggle a plugin name flag. - * - * @param {string} pluginName Plugin name. - * - * @return {Object} Action object. - */ - -function togglePinnedPluginItem(pluginName) { - return { - type: 'TOGGLE_PINNED_PLUGIN_ITEM', - pluginName: pluginName - }; -} -/** - * Returns an action object used in signalling that block types by the given - * name(s) should be hidden. - * - * @param {string[]} blockNames Names of block types to hide. - * - * @return {Object} Action object. - */ - -function actions_hideBlockTypes(blockNames) { - return { - type: 'HIDE_BLOCK_TYPES', - blockNames: Object(external_lodash_["castArray"])(blockNames) - }; -} -/** - * Returns an action object used in signaling that a style should be auto-applied when a block is created. - * - * @param {string} blockName Name of the block. - * @param {?string} blockStyle Name of the style that should be auto applied. If undefined, the "auto apply" setting of the block is removed. - * - * @return {Object} Action object. - */ - -function actions_updatePreferredStyleVariations(blockName, blockStyle) { - return { - type: 'UPDATE_PREFERRED_STYLE_VARIATIONS', - blockName: blockName, - blockStyle: blockStyle - }; -} -function __experimentalUpdateLocalAutosaveInterval(interval) { - return { - type: 'UPDATE_LOCAL_AUTOSAVE_INTERVAL', - interval: interval - }; -} -/** - * Returns an action object used in signalling that block types by the given - * name(s) should be shown. - * - * @param {string[]} blockNames Names of block types to show. - * - * @return {Object} Action object. - */ - -function actions_showBlockTypes(blockNames) { - return { - type: 'SHOW_BLOCK_TYPES', - blockNames: Object(external_lodash_["castArray"])(blockNames) - }; -} -/** - * Returns an action object used in signaling - * what Meta boxes are available in which location. - * - * @param {Object} metaBoxesPerLocation Meta boxes per location. - * - * @return {Object} Action object. - */ - -function setAvailableMetaBoxesPerLocation(metaBoxesPerLocation) { - return { - type: 'SET_META_BOXES_PER_LOCATIONS', - metaBoxesPerLocation: metaBoxesPerLocation - }; -} -/** - * Returns an action object used to request meta box update. - * - * @return {Object} Action object. - */ - -function requestMetaBoxUpdates() { - return { - type: 'REQUEST_META_BOX_UPDATES' - }; -} -/** - * Returns an action object used signal a successful meta box update. - * - * @return {Object} Action object. - */ - -function metaBoxUpdatesSuccess() { - return { - type: 'META_BOX_UPDATES_SUCCESS' - }; -} - -// EXTERNAL MODULE: ./node_modules/rememo/es/rememo.js -var rememo = __webpack_require__(36); - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/store/selectors.js -/** - * External dependencies - */ - - -/** - * Returns the current editing mode. - * - * @param {Object} state Global application state. - * - * @return {string} Editing mode. - */ - -function getEditorMode(state) { - return selectors_getPreference(state, 'editorMode', 'visual'); -} -/** - * Returns true if the editor sidebar is opened. - * - * @param {Object} state Global application state - * - * @return {boolean} Whether the editor sidebar is opened. - */ - -function selectors_isEditorSidebarOpened(state) { - var activeGeneralSidebar = getActiveGeneralSidebarName(state); - return Object(external_lodash_["includes"])(['edit-post/document', 'edit-post/block'], activeGeneralSidebar); -} -/** - * Returns true if the plugin sidebar is opened. - * - * @param {Object} state Global application state - * @return {boolean} Whether the plugin sidebar is opened. - */ - -function isPluginSidebarOpened(state) { - var activeGeneralSidebar = getActiveGeneralSidebarName(state); - return !!activeGeneralSidebar && !selectors_isEditorSidebarOpened(state); -} -/** - * Returns the current active general sidebar name, or null if there is no - * general sidebar active. The active general sidebar is a unique name to - * identify either an editor or plugin sidebar. - * - * Examples: - * - * - `edit-post/document` - * - `my-plugin/insert-image-sidebar` - * - * @param {Object} state Global application state. - * - * @return {?string} Active general sidebar name. - */ - -function getActiveGeneralSidebarName(state) { - // Dismissal takes precedent. - var isDismissed = selectors_getPreference(state, 'isGeneralSidebarDismissed', false); - - if (isDismissed) { - return null; - } - - return state.activeGeneralSidebar; -} -/** - * Returns the preferences (these preferences are persisted locally). - * - * @param {Object} state Global application state. - * - * @return {Object} Preferences Object. - */ - -function getPreferences(state) { - return state.preferences; -} -/** - * - * @param {Object} state Global application state. - * @param {string} preferenceKey Preference Key. - * @param {Mixed} defaultValue Default Value. - * - * @return {Mixed} Preference Value. - */ - -function selectors_getPreference(state, preferenceKey, defaultValue) { - var preferences = getPreferences(state); - var value = preferences[preferenceKey]; - return value === undefined ? defaultValue : value; -} -/** - * Returns true if the publish sidebar is opened. - * - * @param {Object} state Global application state - * - * @return {boolean} Whether the publish sidebar is open. - */ - -function selectors_isPublishSidebarOpened(state) { - return state.publishSidebarActive; -} -/** - * Returns true if the given panel was programmatically removed, or false otherwise. - * All panels are not removed by default. - * - * @param {Object} state Global application state. - * @param {string} panelName A string that identifies the panel. - * - * @return {boolean} Whether or not the panel is removed. - */ - -function isEditorPanelRemoved(state, panelName) { - return Object(external_lodash_["includes"])(state.removedPanels, panelName); -} -/** - * Returns true if the given panel is enabled, or false otherwise. Panels are - * enabled by default. - * - * @param {Object} state Global application state. - * @param {string} panelName A string that identifies the panel. - * - * @return {boolean} Whether or not the panel is enabled. - */ - -function selectors_isEditorPanelEnabled(state, panelName) { - var panels = selectors_getPreference(state, 'panels'); - return !isEditorPanelRemoved(state, panelName) && Object(external_lodash_["get"])(panels, [panelName, 'enabled'], true); -} -/** - * Returns true if the given panel is open, or false otherwise. Panels are - * closed by default. - * - * @param {Object} state Global application state. - * @param {string} panelName A string that identifies the panel. - * - * @return {boolean} Whether or not the panel is open. - */ - -function selectors_isEditorPanelOpened(state, panelName) { - var panels = selectors_getPreference(state, 'panels'); - return Object(external_lodash_["get"])(panels, [panelName]) === true || Object(external_lodash_["get"])(panels, [panelName, 'opened']) === true; -} -/** - * Returns true if a modal is active, or false otherwise. - * - * @param {Object} state Global application state. - * @param {string} modalName A string that uniquely identifies the modal. - * - * @return {boolean} Whether the modal is active. - */ - -function selectors_isModalActive(state, modalName) { - return state.activeModal === modalName; -} -/** - * Returns whether the given feature is enabled or not. - * - * @param {Object} state Global application state. - * @param {string} feature Feature slug. - * - * @return {boolean} Is active. - */ - -function isFeatureActive(state, feature) { - return Object(external_lodash_["get"])(state.preferences.features, [feature], false); -} -/** - * Returns true if the plugin item is pinned to the header. - * When the value is not set it defaults to true. - * - * @param {Object} state Global application state. - * @param {string} pluginName Plugin item name. - * - * @return {boolean} Whether the plugin item is pinned. - */ - -function isPluginItemPinned(state, pluginName) { - var pinnedPluginItems = selectors_getPreference(state, 'pinnedPluginItems', {}); - return Object(external_lodash_["get"])(pinnedPluginItems, [pluginName], true); -} -/** - * Returns an array of active meta box locations. - * - * @param {Object} state Post editor state. - * - * @return {string[]} Active meta box locations. - */ - -var getActiveMetaBoxLocations = Object(rememo["a" /* default */])(function (state) { - return Object.keys(state.metaBoxes.locations).filter(function (location) { - return isMetaBoxLocationActive(state, location); - }); -}, function (state) { - return [state.metaBoxes.locations]; -}); -/** - * Returns true if a metabox location is active and visible - * - * @param {Object} state Post editor state. - * @param {string} location Meta box location to test. - * - * @return {boolean} Whether the meta box location is active and visible. - */ - -function isMetaBoxLocationVisible(state, location) { - return isMetaBoxLocationActive(state, location) && Object(external_lodash_["some"])(getMetaBoxesPerLocation(state, location), function (_ref) { - var id = _ref.id; - return selectors_isEditorPanelEnabled(state, "meta-box-".concat(id)); - }); -} -/** - * Returns true if there is an active meta box in the given location, or false - * otherwise. - * - * @param {Object} state Post editor state. - * @param {string} location Meta box location to test. - * - * @return {boolean} Whether the meta box location is active. - */ - -function isMetaBoxLocationActive(state, location) { - var metaBoxes = getMetaBoxesPerLocation(state, location); - return !!metaBoxes && metaBoxes.length !== 0; -} -/** - * Returns the list of all the available meta boxes for a given location. - * - * @param {Object} state Global application state. - * @param {string} location Meta box location to test. - * - * @return {?Array} List of meta boxes. - */ - -function getMetaBoxesPerLocation(state, location) { - return state.metaBoxes.locations[location]; -} -/** - * Returns the list of all the available meta boxes. - * - * @param {Object} state Global application state. - * - * @return {Array} List of meta boxes. - */ - -var getAllMetaBoxes = Object(rememo["a" /* default */])(function (state) { - return Object(external_lodash_["flatten"])(Object(external_lodash_["values"])(state.metaBoxes.locations)); -}, function (state) { - return [state.metaBoxes.locations]; -}); -/** - * Returns true if the post is using Meta Boxes - * - * @param {Object} state Global application state - * - * @return {boolean} Whether there are metaboxes or not. - */ - -function hasMetaBoxes(state) { - return getActiveMetaBoxLocations(state).length > 0; -} -/** - * Returns true if the Meta Boxes are being saved. - * - * @param {Object} state Global application state. - * - * @return {boolean} Whether the metaboxes are being saved. - */ - -function selectors_isSavingMetaBoxes(state) { - return state.metaBoxes.isSaving; -} - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/utils/meta-boxes.js -/** - * Function returning the current Meta Boxes DOM Node in the editor - * whether the meta box area is opened or not. - * If the MetaBox Area is visible returns it, and returns the original container instead. - * - * @param {string} location Meta Box location. - * @return {string} HTML content. - */ -var getMetaBoxContainer = function getMetaBoxContainer(location) { - var area = document.querySelector(".edit-post-meta-boxes-area.is-".concat(location, " .metabox-location-").concat(location)); - - if (area) { - return area; - } - - return document.querySelector('#metaboxes .metabox-location-' + location); -}; - -// CONCATENATED MODULE: ./node_modules/@wordpress/edit-post/build-module/store/effects.js - - - -/** - * External dependencies - */ - -/** - * WordPress dependencies - */ - - - - - -/** - * Internal dependencies - */ - - - - -var saveMetaboxUnsubscribe; -var effects = { - SET_META_BOXES_PER_LOCATIONS: function SET_META_BOXES_PER_LOCATIONS(action, store) { - // Allow toggling metaboxes panels - // We need to wait for all scripts to load - // If the meta box loads the post script, it will already trigger this. - // After merge in Core, make sure to drop the timeout and update the postboxes script - // to avoid the double binding. - setTimeout(function () { - var postType = Object(external_this_wp_data_["select"])('core/editor').getCurrentPostType(); - - if (window.postboxes.page !== postType) { - window.postboxes.add_postbox_toggles(postType); - } - }); - var wasSavingPost = Object(external_this_wp_data_["select"])('core/editor').isSavingPost(); - var wasAutosavingPost = Object(external_this_wp_data_["select"])('core/editor').isAutosavingPost(); // Meta boxes are initialized once at page load. It is not necessary to - // account for updates on each state change. - // - // See: https://github.com/WordPress/WordPress/blob/5.1.1/wp-admin/includes/post.php#L2307-L2309 - - var hasActiveMetaBoxes = Object(external_this_wp_data_["select"])('core/edit-post').hasMetaBoxes(); // First remove any existing subscription in order to prevent multiple saves - - if (!!saveMetaboxUnsubscribe) { - saveMetaboxUnsubscribe(); - } // Save metaboxes when performing a full save on the post. - - - saveMetaboxUnsubscribe = Object(external_this_wp_data_["subscribe"])(function () { - var isSavingPost = Object(external_this_wp_data_["select"])('core/editor').isSavingPost(); - var isAutosavingPost = Object(external_this_wp_data_["select"])('core/editor').isAutosavingPost(); // Save metaboxes on save completion, except for autosaves that are not a post preview. - - var shouldTriggerMetaboxesSave = hasActiveMetaBoxes && wasSavingPost && !isSavingPost && !wasAutosavingPost; // Save current state for next inspection. - - wasSavingPost = isSavingPost; - wasAutosavingPost = isAutosavingPost; - - if (shouldTriggerMetaboxesSave) { - store.dispatch(requestMetaBoxUpdates()); - } - }); - }, - REQUEST_META_BOX_UPDATES: function REQUEST_META_BOX_UPDATES(action, store) { - // Saves the wp_editor fields - if (window.tinyMCE) { - window.tinyMCE.triggerSave(); - } - - var state = store.getState(); // Additional data needed for backward compatibility. - // If we do not provide this data, the post will be overridden with the default values. - - var post = Object(external_this_wp_data_["select"])('core/editor').getCurrentPost(state); - var additionalData = [post.comment_status ? ['comment_status', post.comment_status] : false, post.ping_status ? ['ping_status', post.ping_status] : false, post.sticky ? ['sticky', post.sticky] : false, post.author ? ['post_author', post.author] : false].filter(Boolean); // We gather