[ Index ]

PHP Cross Reference of WordPress

title

Body

[close]

/wp-includes/js/dist/ -> customize-widgets.js (source)

   1  this["wp"] = this["wp"] || {}; this["wp"]["customizeWidgets"] =
   2  /******/ (function(modules) { // webpackBootstrap
   3  /******/     // The module cache
   4  /******/     var installedModules = {};
   5  /******/
   6  /******/     // The require function
   7  /******/ 	function __webpack_require__(moduleId) {
   8  /******/
   9  /******/         // Check if module is in cache
  10  /******/         if(installedModules[moduleId]) {
  11  /******/             return installedModules[moduleId].exports;
  12  /******/         }
  13  /******/         // Create a new module (and put it into the cache)
  14  /******/         var module = installedModules[moduleId] = {
  15  /******/             i: moduleId,
  16  /******/             l: false,
  17  /******/             exports: {}
  18  /******/         };
  19  /******/
  20  /******/         // Execute the module function
  21  /******/         modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
  22  /******/
  23  /******/         // Flag the module as loaded
  24  /******/         module.l = true;
  25  /******/
  26  /******/         // Return the exports of the module
  27  /******/         return module.exports;
  28  /******/     }
  29  /******/
  30  /******/
  31  /******/     // expose the modules object (__webpack_modules__)
  32  /******/     __webpack_require__.m = modules;
  33  /******/
  34  /******/     // expose the module cache
  35  /******/     __webpack_require__.c = installedModules;
  36  /******/
  37  /******/     // define getter function for harmony exports
  38  /******/     __webpack_require__.d = function(exports, name, getter) {
  39  /******/         if(!__webpack_require__.o(exports, name)) {
  40  /******/             Object.defineProperty(exports, name, { enumerable: true, get: getter });
  41  /******/         }
  42  /******/     };
  43  /******/
  44  /******/     // define __esModule on exports
  45  /******/     __webpack_require__.r = function(exports) {
  46  /******/         if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
  47  /******/             Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
  48  /******/         }
  49  /******/         Object.defineProperty(exports, '__esModule', { value: true });
  50  /******/     };
  51  /******/
  52  /******/     // create a fake namespace object
  53  /******/     // mode & 1: value is a module id, require it
  54  /******/     // mode & 2: merge all properties of value into the ns
  55  /******/     // mode & 4: return value when already ns object
  56  /******/     // mode & 8|1: behave like require
  57  /******/     __webpack_require__.t = function(value, mode) {
  58  /******/         if(mode & 1) value = __webpack_require__(value);
  59  /******/         if(mode & 8) return value;
  60  /******/         if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
  61  /******/         var ns = Object.create(null);
  62  /******/         __webpack_require__.r(ns);
  63  /******/         Object.defineProperty(ns, 'default', { enumerable: true, value: value });
  64  /******/         if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
  65  /******/         return ns;
  66  /******/     };
  67  /******/
  68  /******/     // getDefaultExport function for compatibility with non-harmony modules
  69  /******/     __webpack_require__.n = function(module) {
  70  /******/         var getter = module && module.__esModule ?
  71  /******/ 			function getDefault() { return module['default']; } :
  72  /******/ 			function getModuleExports() { return module; };
  73  /******/         __webpack_require__.d(getter, 'a', getter);
  74  /******/         return getter;
  75  /******/     };
  76  /******/
  77  /******/     // Object.prototype.hasOwnProperty.call
  78  /******/     __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
  79  /******/
  80  /******/     // __webpack_public_path__
  81  /******/     __webpack_require__.p = "";
  82  /******/
  83  /******/
  84  /******/     // Load entry module and return exports
  85  /******/     return __webpack_require__(__webpack_require__.s = "9pbN");
  86  /******/ })
  87  /************************************************************************/
  88  /******/ ({
  89  
  90  /***/ "1CF3":
  91  /***/ (function(module, exports) {
  92  
  93  (function() { module.exports = window["wp"]["dom"]; }());
  94  
  95  /***/ }),
  96  
  97  /***/ "1ZqX":
  98  /***/ (function(module, exports) {
  99  
 100  (function() { module.exports = window["wp"]["data"]; }());
 101  
 102  /***/ }),
 103  
 104  /***/ "6aBm":
 105  /***/ (function(module, exports) {
 106  
 107  (function() { module.exports = window["wp"]["mediaUtils"]; }());
 108  
 109  /***/ }),
 110  
 111  /***/ "9pbN":
 112  /***/ (function(module, __webpack_exports__, __webpack_require__) {
 113  
 114  "use strict";
 115  // ESM COMPAT FLAG
 116  __webpack_require__.r(__webpack_exports__);
 117  
 118  // EXPORTS
 119  __webpack_require__.d(__webpack_exports__, "initialize", function() { return /* binding */ initialize; });
 120  
 121  // NAMESPACE OBJECT: ./node_modules/@wordpress/customize-widgets/build-module/store/selectors.js
 122  var selectors_namespaceObject = {};
 123  __webpack_require__.r(selectors_namespaceObject);
 124  __webpack_require__.d(selectors_namespaceObject, "__unstableIsFeatureActive", function() { return __unstableIsFeatureActive; });
 125  
 126  // NAMESPACE OBJECT: ./node_modules/@wordpress/customize-widgets/build-module/store/actions.js
 127  var actions_namespaceObject = {};
 128  __webpack_require__.r(actions_namespaceObject);
 129  __webpack_require__.d(actions_namespaceObject, "__unstableToggleFeature", function() { return __unstableToggleFeature; });
 130  
 131  // EXTERNAL MODULE: external ["wp","element"]
 132  var external_wp_element_ = __webpack_require__("GRId");
 133  
 134  // EXTERNAL MODULE: external ["wp","blockLibrary"]
 135  var external_wp_blockLibrary_ = __webpack_require__("QyPg");
 136  
 137  // EXTERNAL MODULE: external ["wp","widgets"]
 138  var external_wp_widgets_ = __webpack_require__("GLVC");
 139  
 140  // EXTERNAL MODULE: external ["wp","blocks"]
 141  var external_wp_blocks_ = __webpack_require__("HSyU");
 142  
 143  // EXTERNAL MODULE: external ["wp","components"]
 144  var external_wp_components_ = __webpack_require__("tI+e");
 145  
 146  // EXTERNAL MODULE: external "lodash"
 147  var external_lodash_ = __webpack_require__("YLtl");
 148  
 149  // EXTERNAL MODULE: external ["wp","coreData"]
 150  var external_wp_coreData_ = __webpack_require__("jZUy");
 151  
 152  // EXTERNAL MODULE: external ["wp","data"]
 153  var external_wp_data_ = __webpack_require__("1ZqX");
 154  
 155  // EXTERNAL MODULE: external ["wp","blockEditor"]
 156  var external_wp_blockEditor_ = __webpack_require__("axFQ");
 157  
 158  // EXTERNAL MODULE: external ["wp","mediaUtils"]
 159  var external_wp_mediaUtils_ = __webpack_require__("6aBm");
 160  
 161  // EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/extends.js
 162  var esm_extends = __webpack_require__("wx14");
 163  
 164  // EXTERNAL MODULE: external ["wp","i18n"]
 165  var external_wp_i18n_ = __webpack_require__("l3Sj");
 166  
 167  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/block-inspector-button/index.js
 168  
 169  
 170  
 171  /**
 172   * WordPress dependencies
 173   */
 174  
 175  
 176  
 177  
 178  
 179  
 180  function BlockInspectorButton({
 181    inspector,
 182    closeMenu,
 183    ...props
 184  }) {
 185    const selectedBlockClientId = Object(external_wp_data_["useSelect"])(select => select(external_wp_blockEditor_["store"]).getSelectedBlockClientId(), []);
 186    const selectedBlock = Object(external_wp_element_["useMemo"])(() => document.getElementById(`block-$selectedBlockClientId}`), [selectedBlockClientId]);
 187    return Object(external_wp_element_["createElement"])(external_wp_components_["MenuItem"], Object(esm_extends["a" /* default */])({
 188      onClick: () => {
 189        // Open the inspector.
 190        inspector.open({
 191          returnFocusWhenClose: selectedBlock
 192        }); // Then close the dropdown menu.
 193  
 194        closeMenu();
 195      }
 196    }, props), Object(external_wp_i18n_["__"])('Show more settings'));
 197  }
 198  
 199  /* harmony default export */ var block_inspector_button = (BlockInspectorButton);
 200  
 201  // EXTERNAL MODULE: ./node_modules/classnames/index.js
 202  var classnames = __webpack_require__("TSYQ");
 203  var classnames_default = /*#__PURE__*/__webpack_require__.n(classnames);
 204  
 205  // EXTERNAL MODULE: external ["wp","keycodes"]
 206  var external_wp_keycodes_ = __webpack_require__("RxS6");
 207  
 208  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/undo.js
 209  var library_undo = __webpack_require__("Ntru");
 210  
 211  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/redo.js
 212  var library_redo = __webpack_require__("K2cm");
 213  
 214  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/plus.js
 215  var plus = __webpack_require__("Q4Sy");
 216  
 217  // EXTERNAL MODULE: external ["wp","compose"]
 218  var external_wp_compose_ = __webpack_require__("K9lf");
 219  
 220  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/close-small.js
 221  var close_small = __webpack_require__("bWcr");
 222  
 223  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/inserter/index.js
 224  
 225  
 226  /**
 227   * WordPress dependencies
 228   */
 229  
 230  
 231  
 232  
 233  
 234  
 235  function Inserter({
 236    setIsOpened
 237  }) {
 238    const inserterTitleId = Object(external_wp_compose_["useInstanceId"])(Inserter, 'customize-widget-layout__inserter-panel-title');
 239    return Object(external_wp_element_["createElement"])("div", {
 240      className: "customize-widgets-layout__inserter-panel",
 241      "aria-labelledby": inserterTitleId
 242    }, Object(external_wp_element_["createElement"])("div", {
 243      className: "customize-widgets-layout__inserter-panel-header"
 244    }, Object(external_wp_element_["createElement"])("h2", {
 245      id: inserterTitleId,
 246      className: "customize-widgets-layout__inserter-panel-header-title"
 247    }, Object(external_wp_i18n_["__"])('Add a block')), Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
 248      className: "customize-widgets-layout__inserter-panel-header-close-button",
 249      icon: close_small["a" /* default */],
 250      onClick: () => setIsOpened(false),
 251      "aria-label": Object(external_wp_i18n_["__"])('Close inserter')
 252    })), Object(external_wp_element_["createElement"])("div", {
 253      className: "customize-widgets-layout__inserter-panel-content"
 254    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["__experimentalLibrary"], {
 255      showInserterHelpPanel: true,
 256      onSelect: () => setIsOpened(false)
 257    })));
 258  }
 259  
 260  /* harmony default export */ var components_inserter = (Inserter);
 261  
 262  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/more-vertical.js
 263  var more_vertical = __webpack_require__("VKE3");
 264  
 265  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/external.js
 266  var external = __webpack_require__("K+tz");
 267  
 268  // EXTERNAL MODULE: external ["wp","keyboardShortcuts"]
 269  var external_wp_keyboardShortcuts_ = __webpack_require__("hF7m");
 270  
 271  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/check.js
 272  var check = __webpack_require__("RMJe");
 273  
 274  // EXTERNAL MODULE: external ["wp","a11y"]
 275  var external_wp_a11y_ = __webpack_require__("gdqT");
 276  
 277  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/store/defaults.js
 278  const PREFERENCES_DEFAULTS = {
 279    features: {
 280      fixedToolbar: false,
 281      welcomeGuide: true
 282    }
 283  };
 284  
 285  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/store/reducer.js
 286  /**
 287   * External dependencies
 288   */
 289  
 290  /**
 291   * WordPress dependencies
 292   */
 293  
 294  
 295  /**
 296   * Internal dependencies
 297   */
 298  
 299  
 300  /**
 301   * Higher-order reducer creator which provides the given initial state for the
 302   * original reducer.
 303   *
 304   * @param {*} initialState Initial state to provide to reducer.
 305   *
 306   * @return {Function} Higher-order reducer.
 307   */
 308  
 309  const createWithInitialState = initialState => reducer => {
 310    return (state = initialState, action) => reducer(state, action);
 311  };
 312  /**
 313   * Reducer returning the user preferences.
 314   *
 315   * @param {Object}  state                           Current state.
 316   * @param {Object}  action                          Dispatched action.
 317   *
 318   * @return {Object} Updated state.
 319   */
 320  
 321  
 322  const preferences = Object(external_lodash_["flow"])([external_wp_data_["combineReducers"], createWithInitialState(PREFERENCES_DEFAULTS)])({
 323    features(state, action) {
 324      if (action.type === 'TOGGLE_FEATURE') {
 325        return { ...state,
 326          [action.feature]: !state[action.feature]
 327        };
 328      }
 329  
 330      return state;
 331    }
 332  
 333  });
 334  /* harmony default export */ var reducer = (Object(external_wp_data_["combineReducers"])({
 335    preferences
 336  }));
 337  
 338  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/store/selectors.js
 339  /**
 340   * External dependencies
 341   */
 342  
 343  /**
 344   * Returns whether the given feature is enabled or not.
 345   *
 346   * This function is unstable, as it is mostly copied from the edit-post
 347   * package. Editor features and preferences have a lot of scope for
 348   * being generalized and refactored.
 349   *
 350   * @param {Object} state   Global application state.
 351   * @param {string} feature Feature slug.
 352   *
 353   * @return {boolean} Is active.
 354   */
 355  
 356  function __unstableIsFeatureActive(state, feature) {
 357    return Object(external_lodash_["get"])(state.preferences.features, [feature], false);
 358  }
 359  
 360  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/store/actions.js
 361  /**
 362   * Returns an action object used to toggle a feature flag.
 363   *
 364   * This function is unstable, as it is mostly copied from the edit-post
 365   * package. Editor features and preferences have a lot of scope for
 366   * being generalized and refactored.
 367   *
 368   * @param {string} feature Feature name.
 369   *
 370   * @return {Object} Action object.
 371   */
 372  function __unstableToggleFeature(feature) {
 373    return {
 374      type: 'TOGGLE_FEATURE',
 375      feature
 376    };
 377  }
 378  
 379  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/store/constants.js
 380  /**
 381   * Module Constants
 382   */
 383  const STORE_NAME = 'core/customize-widgets';
 384  
 385  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/store/index.js
 386  /**
 387   * WordPress dependencies
 388   */
 389  
 390  /**
 391   * Internal dependencies
 392   */
 393  
 394  
 395  
 396  
 397  
 398  /**
 399   * Block editor data store configuration.
 400   *
 401   * @see https://github.com/WordPress/gutenberg/blob/HEAD/packages/data/README.md#registerStore
 402   *
 403   * @type {Object}
 404   */
 405  
 406  const storeConfig = {
 407    reducer: reducer,
 408    selectors: selectors_namespaceObject,
 409    actions: actions_namespaceObject,
 410    persist: ['preferences']
 411  };
 412  /**
 413   * Store definition for the edit widgets namespace.
 414   *
 415   * @see https://github.com/WordPress/gutenberg/blob/HEAD/packages/data/README.md#createReduxStore
 416   *
 417   * @type {Object}
 418   */
 419  
 420  const store = Object(external_wp_data_["createReduxStore"])(STORE_NAME, storeConfig); // Once we build a more generic persistence plugin that works across types of stores
 421  // we'd be able to replace this with a register call.
 422  
 423  Object(external_wp_data_["registerStore"])(STORE_NAME, storeConfig);
 424  
 425  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/more-menu/feature-toggle.js
 426  
 427  
 428  /**
 429   * WordPress dependencies
 430   */
 431  
 432  
 433  
 434  
 435  
 436  /**
 437   * Internal dependencies
 438   */
 439  
 440  
 441  function FeatureToggle({
 442    label,
 443    info,
 444    messageActivated,
 445    messageDeactivated,
 446    shortcut,
 447    feature
 448  }) {
 449    const isActive = Object(external_wp_data_["useSelect"])(select => select(store).__unstableIsFeatureActive(feature), [feature]);
 450    const {
 451      __unstableToggleFeature: toggleFeature
 452    } = Object(external_wp_data_["useDispatch"])(store);
 453  
 454    const speakMessage = () => {
 455      if (isActive) {
 456        Object(external_wp_a11y_["speak"])(messageDeactivated || Object(external_wp_i18n_["__"])('Feature deactivated'));
 457      } else {
 458        Object(external_wp_a11y_["speak"])(messageActivated || Object(external_wp_i18n_["__"])('Feature activated'));
 459      }
 460    };
 461  
 462    return Object(external_wp_element_["createElement"])(external_wp_components_["MenuItem"], {
 463      icon: isActive && check["a" /* default */],
 464      isSelected: isActive,
 465      onClick: () => {
 466        toggleFeature(feature);
 467        speakMessage();
 468      },
 469      role: "menuitemcheckbox",
 470      info: info,
 471      shortcut: shortcut
 472    }, label);
 473  }
 474  
 475  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/keyboard-shortcut-help-modal/config.js
 476  /**
 477   * WordPress dependencies
 478   */
 479  
 480  const textFormattingShortcuts = [{
 481    keyCombination: {
 482      modifier: 'primary',
 483      character: 'b'
 484    },
 485    description: Object(external_wp_i18n_["__"])('Make the selected text bold.')
 486  }, {
 487    keyCombination: {
 488      modifier: 'primary',
 489      character: 'i'
 490    },
 491    description: Object(external_wp_i18n_["__"])('Make the selected text italic.')
 492  }, {
 493    keyCombination: {
 494      modifier: 'primary',
 495      character: 'k'
 496    },
 497    description: Object(external_wp_i18n_["__"])('Convert the selected text into a link.')
 498  }, {
 499    keyCombination: {
 500      modifier: 'primaryShift',
 501      character: 'k'
 502    },
 503    description: Object(external_wp_i18n_["__"])('Remove a link.')
 504  }, {
 505    keyCombination: {
 506      modifier: 'primary',
 507      character: 'u'
 508    },
 509    description: Object(external_wp_i18n_["__"])('Underline the selected text.')
 510  }];
 511  
 512  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/keyboard-shortcut-help-modal/shortcut.js
 513  
 514  
 515  /**
 516   * External dependencies
 517   */
 518  
 519  /**
 520   * WordPress dependencies
 521   */
 522  
 523  
 524  
 525  
 526  function KeyCombination({
 527    keyCombination,
 528    forceAriaLabel
 529  }) {
 530    const shortcut = keyCombination.modifier ? external_wp_keycodes_["displayShortcutList"][keyCombination.modifier](keyCombination.character) : keyCombination.character;
 531    const ariaLabel = keyCombination.modifier ? external_wp_keycodes_["shortcutAriaLabel"][keyCombination.modifier](keyCombination.character) : keyCombination.character;
 532    return Object(external_wp_element_["createElement"])("kbd", {
 533      className: "customize-widgets-keyboard-shortcut-help-modal__shortcut-key-combination",
 534      "aria-label": forceAriaLabel || ariaLabel
 535    }, Object(external_lodash_["castArray"])(shortcut).map((character, index) => {
 536      if (character === '+') {
 537        return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], {
 538          key: index
 539        }, character);
 540      }
 541  
 542      return Object(external_wp_element_["createElement"])("kbd", {
 543        key: index,
 544        className: "customize-widgets-keyboard-shortcut-help-modal__shortcut-key"
 545      }, character);
 546    }));
 547  }
 548  
 549  function Shortcut({
 550    description,
 551    keyCombination,
 552    aliases = [],
 553    ariaLabel
 554  }) {
 555    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])("div", {
 556      className: "customize-widgets-keyboard-shortcut-help-modal__shortcut-description"
 557    }, description), Object(external_wp_element_["createElement"])("div", {
 558      className: "customize-widgets-keyboard-shortcut-help-modal__shortcut-term"
 559    }, Object(external_wp_element_["createElement"])(KeyCombination, {
 560      keyCombination: keyCombination,
 561      forceAriaLabel: ariaLabel
 562    }), aliases.map((alias, index) => Object(external_wp_element_["createElement"])(KeyCombination, {
 563      keyCombination: alias,
 564      forceAriaLabel: ariaLabel,
 565      key: index
 566    }))));
 567  }
 568  
 569  /* harmony default export */ var keyboard_shortcut_help_modal_shortcut = (Shortcut);
 570  
 571  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/keyboard-shortcut-help-modal/dynamic-shortcut.js
 572  
 573  
 574  /**
 575   * WordPress dependencies
 576   */
 577  
 578  
 579  /**
 580   * Internal dependencies
 581   */
 582  
 583  
 584  
 585  function DynamicShortcut({
 586    name
 587  }) {
 588    const {
 589      keyCombination,
 590      description,
 591      aliases
 592    } = Object(external_wp_data_["useSelect"])(select => {
 593      const {
 594        getShortcutKeyCombination,
 595        getShortcutDescription,
 596        getShortcutAliases
 597      } = select(external_wp_keyboardShortcuts_["store"]);
 598      return {
 599        keyCombination: getShortcutKeyCombination(name),
 600        aliases: getShortcutAliases(name),
 601        description: getShortcutDescription(name)
 602      };
 603    });
 604  
 605    if (!keyCombination) {
 606      return null;
 607    }
 608  
 609    return Object(external_wp_element_["createElement"])(keyboard_shortcut_help_modal_shortcut, {
 610      keyCombination: keyCombination,
 611      description: description,
 612      aliases: aliases
 613    });
 614  }
 615  
 616  /* harmony default export */ var dynamic_shortcut = (DynamicShortcut);
 617  
 618  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/keyboard-shortcut-help-modal/index.js
 619  
 620  
 621  /**
 622   * External dependencies
 623   */
 624  
 625  
 626  /**
 627   * WordPress dependencies
 628   */
 629  
 630  
 631  
 632  
 633  
 634  /**
 635   * Internal dependencies
 636   */
 637  
 638  
 639  
 640  
 641  
 642  const ShortcutList = ({
 643    shortcuts
 644  }) =>
 645  /*
 646   * Disable reason: The `list` ARIA role is redundant but
 647   * Safari+VoiceOver won't announce the list otherwise.
 648   */
 649  
 650  /* eslint-disable jsx-a11y/no-redundant-roles */
 651  Object(external_wp_element_["createElement"])("ul", {
 652    className: "customize-widgets-keyboard-shortcut-help-modal__shortcut-list",
 653    role: "list"
 654  }, shortcuts.map((shortcut, index) => Object(external_wp_element_["createElement"])("li", {
 655    className: "customize-widgets-keyboard-shortcut-help-modal__shortcut",
 656    key: index
 657  }, Object(external_lodash_["isString"])(shortcut) ? Object(external_wp_element_["createElement"])(dynamic_shortcut, {
 658    name: shortcut
 659  }) : Object(external_wp_element_["createElement"])(keyboard_shortcut_help_modal_shortcut, shortcut))))
 660  /* eslint-enable jsx-a11y/no-redundant-roles */
 661  ;
 662  
 663  const ShortcutSection = ({
 664    title,
 665    shortcuts,
 666    className
 667  }) => Object(external_wp_element_["createElement"])("section", {
 668    className: classnames_default()('customize-widgets-keyboard-shortcut-help-modal__section', className)
 669  }, !!title && Object(external_wp_element_["createElement"])("h2", {
 670    className: "customize-widgets-keyboard-shortcut-help-modal__section-title"
 671  }, title), Object(external_wp_element_["createElement"])(ShortcutList, {
 672    shortcuts: shortcuts
 673  }));
 674  
 675  const ShortcutCategorySection = ({
 676    title,
 677    categoryName,
 678    additionalShortcuts = []
 679  }) => {
 680    const categoryShortcuts = Object(external_wp_data_["useSelect"])(select => {
 681      return select(external_wp_keyboardShortcuts_["store"]).getCategoryShortcuts(categoryName);
 682    }, [categoryName]);
 683    return Object(external_wp_element_["createElement"])(ShortcutSection, {
 684      title: title,
 685      shortcuts: categoryShortcuts.concat(additionalShortcuts)
 686    });
 687  };
 688  
 689  function KeyboardShortcutHelpModal({
 690    isModalActive,
 691    toggleModal
 692  }) {
 693    const {
 694      registerShortcut
 695    } = Object(external_wp_data_["useDispatch"])(external_wp_keyboardShortcuts_["store"]);
 696    registerShortcut({
 697      name: 'core/customize-widgets/keyboard-shortcuts',
 698      category: 'main',
 699      description: Object(external_wp_i18n_["__"])('Display these keyboard shortcuts.'),
 700      keyCombination: {
 701        modifier: 'access',
 702        character: 'h'
 703      }
 704    });
 705    Object(external_wp_keyboardShortcuts_["useShortcut"])('core/customize-widgets/keyboard-shortcuts', toggleModal, {
 706      bindGlobal: true
 707    });
 708  
 709    if (!isModalActive) {
 710      return null;
 711    }
 712  
 713    return Object(external_wp_element_["createElement"])(external_wp_components_["Modal"], {
 714      className: "customize-widgets-keyboard-shortcut-help-modal",
 715      title: Object(external_wp_i18n_["__"])('Keyboard shortcuts'),
 716      closeLabel: Object(external_wp_i18n_["__"])('Close'),
 717      onRequestClose: toggleModal
 718    }, Object(external_wp_element_["createElement"])(ShortcutSection, {
 719      className: "customize-widgets-keyboard-shortcut-help-modal__main-shortcuts",
 720      shortcuts: ['core/customize-widgets/keyboard-shortcuts']
 721    }), Object(external_wp_element_["createElement"])(ShortcutCategorySection, {
 722      title: Object(external_wp_i18n_["__"])('Global shortcuts'),
 723      categoryName: "global"
 724    }), Object(external_wp_element_["createElement"])(ShortcutCategorySection, {
 725      title: Object(external_wp_i18n_["__"])('Selection shortcuts'),
 726      categoryName: "selection"
 727    }), Object(external_wp_element_["createElement"])(ShortcutCategorySection, {
 728      title: Object(external_wp_i18n_["__"])('Block shortcuts'),
 729      categoryName: "block",
 730      additionalShortcuts: [{
 731        keyCombination: {
 732          character: '/'
 733        },
 734        description: Object(external_wp_i18n_["__"])('Change the block type after adding a new paragraph.'),
 735  
 736        /* translators: The forward-slash character. e.g. '/'. */
 737        ariaLabel: Object(external_wp_i18n_["__"])('Forward-slash')
 738      }]
 739    }), Object(external_wp_element_["createElement"])(ShortcutSection, {
 740      title: Object(external_wp_i18n_["__"])('Text formatting'),
 741      shortcuts: textFormattingShortcuts
 742    }));
 743  }
 744  
 745  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/more-menu/index.js
 746  
 747  
 748  /**
 749   * WordPress dependencies
 750   */
 751  
 752  
 753  
 754  
 755  
 756  
 757  /**
 758   * Internal dependencies
 759   */
 760  
 761  
 762  
 763  const POPOVER_PROPS = {
 764    className: 'customize-widgets-more-menu__content',
 765    position: 'bottom left'
 766  };
 767  const TOGGLE_PROPS = {
 768    tooltipPosition: 'bottom'
 769  };
 770  function MoreMenu() {
 771    const [isKeyboardShortcutsModalActive, setIsKeyboardShortcutsModalVisible] = Object(external_wp_element_["useState"])(false);
 772  
 773    const toggleKeyboardShortcutsModal = () => setIsKeyboardShortcutsModalVisible(!isKeyboardShortcutsModalActive);
 774  
 775    Object(external_wp_keyboardShortcuts_["useShortcut"])('core/customize-widgets/keyboard-shortcuts', toggleKeyboardShortcutsModal, {
 776      bindGlobal: true
 777    });
 778    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarDropdownMenu"], {
 779      className: "customize-widgets-more-menu",
 780      icon: more_vertical["a" /* default */]
 781      /* translators: button label text should, if possible, be under 16 characters. */
 782      ,
 783      label: Object(external_wp_i18n_["__"])('Options'),
 784      popoverProps: POPOVER_PROPS,
 785      toggleProps: TOGGLE_PROPS
 786    }, () => Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_components_["MenuGroup"], {
 787      label: Object(external_wp_i18n_["_x"])('View', 'noun')
 788    }, Object(external_wp_element_["createElement"])(FeatureToggle, {
 789      feature: "fixedToolbar",
 790      label: Object(external_wp_i18n_["__"])('Top toolbar'),
 791      info: Object(external_wp_i18n_["__"])('Access all block and document tools in a single place'),
 792      messageActivated: Object(external_wp_i18n_["__"])('Top toolbar activated'),
 793      messageDeactivated: Object(external_wp_i18n_["__"])('Top toolbar deactivated')
 794    })), Object(external_wp_element_["createElement"])(external_wp_components_["MenuGroup"], {
 795      label: Object(external_wp_i18n_["__"])('Tools')
 796    }, Object(external_wp_element_["createElement"])(external_wp_components_["MenuItem"], {
 797      onClick: () => {
 798        setIsKeyboardShortcutsModalVisible(true);
 799      },
 800      shortcut: external_wp_keycodes_["displayShortcut"].access('h')
 801    }, Object(external_wp_i18n_["__"])('Keyboard shortcuts')), Object(external_wp_element_["createElement"])(FeatureToggle, {
 802      feature: "welcomeGuide",
 803      label: Object(external_wp_i18n_["__"])('Welcome Guide')
 804    }), Object(external_wp_element_["createElement"])(external_wp_components_["MenuItem"], {
 805      role: "menuitem",
 806      icon: external["a" /* default */],
 807      href: Object(external_wp_i18n_["__"])('https://wordpress.org/support/article/wordpress-editor/'),
 808      target: "_blank",
 809      rel: "noopener noreferrer"
 810    }, Object(external_wp_i18n_["__"])('Help'), Object(external_wp_element_["createElement"])(external_wp_components_["VisuallyHidden"], {
 811      as: "span"
 812    },
 813    /* translators: accessibility text */
 814    Object(external_wp_i18n_["__"])('(opens in a new tab)')))), Object(external_wp_element_["createElement"])(external_wp_components_["MenuGroup"], {
 815      label: Object(external_wp_i18n_["__"])('Preferences')
 816    }, Object(external_wp_element_["createElement"])(FeatureToggle, {
 817      feature: "keepCaretInsideBlock",
 818      label: Object(external_wp_i18n_["__"])('Contain text cursor inside block'),
 819      info: Object(external_wp_i18n_["__"])('Aids screen readers by stopping text caret from leaving blocks.'),
 820      messageActivated: Object(external_wp_i18n_["__"])('Contain text cursor inside block activated'),
 821      messageDeactivated: Object(external_wp_i18n_["__"])('Contain text cursor inside block deactivated')
 822    })))), Object(external_wp_element_["createElement"])(KeyboardShortcutHelpModal, {
 823      isModalActive: isKeyboardShortcutsModalActive,
 824      toggleModal: toggleKeyboardShortcutsModal
 825    }));
 826  }
 827  
 828  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/header/index.js
 829  
 830  
 831  /**
 832   * External dependencies
 833   */
 834  
 835  /**
 836   * WordPress dependencies
 837   */
 838  
 839  
 840  
 841  
 842  
 843  
 844  
 845  /**
 846   * Internal dependencies
 847   */
 848  
 849  
 850  
 851  
 852  function Header({
 853    sidebar,
 854    inserter,
 855    isInserterOpened,
 856    setIsInserterOpened,
 857    isFixedToolbarActive
 858  }) {
 859    const [[hasUndo, hasRedo], setUndoRedo] = Object(external_wp_element_["useState"])([sidebar.hasUndo(), sidebar.hasRedo()]);
 860    Object(external_wp_element_["useEffect"])(() => {
 861      return sidebar.subscribeHistory(() => {
 862        setUndoRedo([sidebar.hasUndo(), sidebar.hasRedo()]);
 863      });
 864    }, [sidebar]);
 865    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])("div", {
 866      className: classnames_default()('customize-widgets-header', {
 867        'is-fixed-toolbar-active': isFixedToolbarActive
 868      })
 869    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["NavigableToolbar"], {
 870      className: "customize-widgets-header-toolbar",
 871      "aria-label": Object(external_wp_i18n_["__"])('Document tools')
 872    }, Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
 873      icon: !Object(external_wp_i18n_["isRTL"])() ? library_undo["a" /* default */] : library_redo["a" /* default */]
 874      /* translators: button label text should, if possible, be under 16 characters. */
 875      ,
 876      label: Object(external_wp_i18n_["__"])('Undo'),
 877      shortcut: external_wp_keycodes_["displayShortcut"].primary('z') // If there are no undo levels we don't want to actually disable this
 878      // button, because it will remove focus for keyboard users.
 879      // See: https://github.com/WordPress/gutenberg/issues/3486
 880      ,
 881      "aria-disabled": !hasUndo,
 882      onClick: sidebar.undo,
 883      className: "customize-widgets-editor-history-button undo-button"
 884    }), Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
 885      icon: !Object(external_wp_i18n_["isRTL"])() ? library_redo["a" /* default */] : library_undo["a" /* default */]
 886      /* translators: button label text should, if possible, be under 16 characters. */
 887      ,
 888      label: Object(external_wp_i18n_["__"])('Redo'),
 889      shortcut: external_wp_keycodes_["displayShortcut"].primaryShift('z') // If there are no undo levels we don't want to actually disable this
 890      // button, because it will remove focus for keyboard users.
 891      // See: https://github.com/WordPress/gutenberg/issues/3486
 892      ,
 893      "aria-disabled": !hasRedo,
 894      onClick: sidebar.redo,
 895      className: "customize-widgets-editor-history-button redo-button"
 896    }), Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
 897      className: "customize-widgets-header-toolbar__inserter-toggle",
 898      isPressed: isInserterOpened,
 899      isPrimary: true,
 900      icon: plus["a" /* default */],
 901      label: Object(external_wp_i18n_["_x"])('Add block', 'Generic label for block inserter button'),
 902      onClick: () => {
 903        setIsInserterOpened(isOpen => !isOpen);
 904      }
 905    }), Object(external_wp_element_["createElement"])(MoreMenu, null))), Object(external_wp_element_["createPortal"])(Object(external_wp_element_["createElement"])(components_inserter, {
 906      setIsOpened: setIsInserterOpened
 907    }), inserter.contentContainer[0]));
 908  }
 909  
 910  /* harmony default export */ var header = (Header);
 911  
 912  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/inserter/use-inserter.js
 913  /**
 914   * WordPress dependencies
 915   */
 916  
 917  function useInserter(inserter) {
 918    const [isInserterOpened, setIsInserterOpened] = Object(external_wp_element_["useState"])(() => inserter.isOpen);
 919    Object(external_wp_element_["useEffect"])(() => {
 920      return inserter.subscribe(setIsInserterOpened);
 921    }, [inserter]);
 922    return [isInserterOpened, Object(external_wp_element_["useCallback"])(updater => {
 923      let isOpen = updater;
 924  
 925      if (typeof updater === 'function') {
 926        isOpen = updater(inserter.isOpen);
 927      }
 928  
 929      if (isOpen) {
 930        inserter.open();
 931      } else {
 932        inserter.close();
 933      }
 934    }, [inserter])];
 935  }
 936  
 937  // EXTERNAL MODULE: external ["wp","isShallowEqual"]
 938  var external_wp_isShallowEqual_ = __webpack_require__("rl8x");
 939  var external_wp_isShallowEqual_default = /*#__PURE__*/__webpack_require__.n(external_wp_isShallowEqual_);
 940  
 941  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/utils.js
 942  // @ts-check
 943  
 944  /**
 945   * WordPress dependencies
 946   */
 947  
 948  
 949  /**
 950   * External dependencies
 951   */
 952  
 953  
 954  /**
 955   * Convert settingId to widgetId.
 956   *
 957   * @param {string} settingId The setting id.
 958   * @return {string} The widget id.
 959   */
 960  
 961  function settingIdToWidgetId(settingId) {
 962    const matches = settingId.match(/^widget_(.+)(?:\[(\d+)\])$/);
 963  
 964    if (matches) {
 965      const idBase = matches[1];
 966      const number = parseInt(matches[2], 10);
 967      return `$idBase}-$number}`;
 968    }
 969  
 970    return settingId;
 971  }
 972  /**
 973   * Transform a block to a customizable widget.
 974   *
 975   * @param {WPBlock} block          The block to be transformed from.
 976   * @param {Object}  existingWidget The widget to be extended from.
 977   * @return {Object} The transformed widget.
 978   */
 979  
 980  function blockToWidget(block, existingWidget = null) {
 981    let widget;
 982    const isValidLegacyWidgetBlock = block.name === 'core/legacy-widget' && (block.attributes.id || block.attributes.instance);
 983  
 984    if (isValidLegacyWidgetBlock) {
 985      if (block.attributes.id) {
 986        // Widget that does not extend WP_Widget.
 987        widget = {
 988          id: block.attributes.id
 989        };
 990      } else {
 991        const {
 992          encoded,
 993          hash,
 994          raw,
 995          ...rest
 996        } = block.attributes.instance; // Widget that extends WP_Widget.
 997  
 998        widget = {
 999          idBase: block.attributes.idBase,
1000          instance: { ...(existingWidget === null || existingWidget === void 0 ? void 0 : existingWidget.instance),
1001            // Required only for the customizer.
1002            is_widget_customizer_js_value: true,
1003            encoded_serialized_instance: encoded,
1004            instance_hash_key: hash,
1005            raw_instance: raw,
1006            ...rest
1007          }
1008        };
1009      }
1010    } else {
1011      const instance = {
1012        content: Object(external_wp_blocks_["serialize"])(block)
1013      };
1014      widget = {
1015        idBase: 'block',
1016        widgetClass: 'WP_Widget_Block',
1017        instance: {
1018          raw_instance: instance
1019        }
1020      };
1021    }
1022  
1023    return { ...Object(external_lodash_["omit"])(existingWidget, ['form', 'rendered']),
1024      ...widget
1025    };
1026  }
1027  /**
1028   * Transform a widget to a block.
1029   *
1030   * @param {Object} widget          The widget to be transformed from.
1031   * @param {string} widget.id       The widget id.
1032   * @param {string} widget.idBase   The id base of the widget.
1033   * @param {number} widget.number   The number/index of the widget.
1034   * @param {Object} widget.instance The instance of the widget.
1035   * @return {WPBlock} The transformed block.
1036   */
1037  
1038  function widgetToBlock({
1039    id,
1040    idBase,
1041    number,
1042    instance
1043  }) {
1044    let block;
1045    const {
1046      encoded_serialized_instance: encoded,
1047      instance_hash_key: hash,
1048      raw_instance: raw,
1049      ...rest
1050    } = instance;
1051  
1052    if (idBase === 'block') {
1053      const parsedBlocks = Object(external_wp_blocks_["parse"])(raw.content);
1054      block = parsedBlocks.length ? parsedBlocks[0] : Object(external_wp_blocks_["createBlock"])('core/paragraph', {});
1055    } else if (number) {
1056      // Widget that extends WP_Widget.
1057      block = Object(external_wp_blocks_["createBlock"])('core/legacy-widget', {
1058        idBase,
1059        instance: {
1060          encoded,
1061          hash,
1062          raw,
1063          ...rest
1064        }
1065      });
1066    } else {
1067      // Widget that does not extend WP_Widget.
1068      block = Object(external_wp_blocks_["createBlock"])('core/legacy-widget', {
1069        id
1070      });
1071    }
1072  
1073    return Object(external_wp_widgets_["addWidgetIdToBlock"])(block, id);
1074  }
1075  
1076  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/sidebar-block-editor/use-sidebar-block-editor.js
1077  /**
1078   * External dependencies
1079   */
1080  
1081  /**
1082   * WordPress dependencies
1083   */
1084  
1085  
1086  
1087  
1088  /**
1089   * Internal dependencies
1090   */
1091  
1092  
1093  
1094  function widgetsToBlocks(widgets) {
1095    return widgets.map(widget => widgetToBlock(widget));
1096  }
1097  
1098  function useSidebarBlockEditor(sidebar) {
1099    const [blocks, setBlocks] = Object(external_wp_element_["useState"])(() => widgetsToBlocks(sidebar.getWidgets()));
1100    Object(external_wp_element_["useEffect"])(() => {
1101      return sidebar.subscribe((prevWidgets, nextWidgets) => {
1102        setBlocks(prevBlocks => {
1103          const prevWidgetsMap = new Map(prevWidgets.map(widget => [widget.id, widget]));
1104          const prevBlocksMap = new Map(prevBlocks.map(block => [Object(external_wp_widgets_["getWidgetIdFromBlock"])(block), block]));
1105          const nextBlocks = nextWidgets.map(nextWidget => {
1106            const prevWidget = prevWidgetsMap.get(nextWidget.id); // Bail out updates.
1107  
1108            if (prevWidget && prevWidget === nextWidget) {
1109              return prevBlocksMap.get(nextWidget.id);
1110            }
1111  
1112            return widgetToBlock(nextWidget);
1113          }); // Bail out updates.
1114  
1115          if (external_wp_isShallowEqual_default()(prevBlocks, nextBlocks)) {
1116            return prevBlocks;
1117          }
1118  
1119          return nextBlocks;
1120        });
1121      });
1122    }, [sidebar]);
1123    const onChangeBlocks = Object(external_wp_element_["useCallback"])(nextBlocks => {
1124      setBlocks(prevBlocks => {
1125        if (external_wp_isShallowEqual_default()(prevBlocks, nextBlocks)) {
1126          return prevBlocks;
1127        }
1128  
1129        const prevBlocksMap = new Map(prevBlocks.map(block => [Object(external_wp_widgets_["getWidgetIdFromBlock"])(block), block]));
1130        const nextWidgets = nextBlocks.map(nextBlock => {
1131          const widgetId = Object(external_wp_widgets_["getWidgetIdFromBlock"])(nextBlock); // Update existing widgets.
1132  
1133          if (widgetId && prevBlocksMap.has(widgetId)) {
1134            const prevBlock = prevBlocksMap.get(widgetId);
1135            const prevWidget = sidebar.getWidget(widgetId); // Bail out updates by returning the previous widgets.
1136            // Deep equality is necessary until the block editor's internals changes.
1137  
1138            if (Object(external_lodash_["isEqual"])(nextBlock, prevBlock) && prevWidget) {
1139              return prevWidget;
1140            }
1141  
1142            return blockToWidget(nextBlock, prevWidget);
1143          } // Add a new widget.
1144  
1145  
1146          return blockToWidget(nextBlock);
1147        }); // Bail out updates if the updated widgets are the same.
1148  
1149        if (external_wp_isShallowEqual_default()(sidebar.getWidgets(), nextWidgets)) {
1150          return prevBlocks;
1151        }
1152  
1153        const addedWidgetIds = sidebar.setWidgets(nextWidgets);
1154        return nextBlocks.reduce((updatedNextBlocks, nextBlock, index) => {
1155          const addedWidgetId = addedWidgetIds[index];
1156  
1157          if (addedWidgetId !== null) {
1158            // Only create a new instance if necessary to prevent
1159            // the whole editor from re-rendering on every edit.
1160            if (updatedNextBlocks === nextBlocks) {
1161              updatedNextBlocks = nextBlocks.slice();
1162            }
1163  
1164            updatedNextBlocks[index] = Object(external_wp_widgets_["addWidgetIdToBlock"])(nextBlock, addedWidgetId);
1165          }
1166  
1167          return updatedNextBlocks;
1168        }, nextBlocks);
1169      });
1170    }, [sidebar]);
1171    return [blocks, onChangeBlocks, onChangeBlocks];
1172  }
1173  
1174  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/focus-control/index.js
1175  
1176  
1177  /**
1178   * WordPress dependencies
1179   */
1180  
1181  /**
1182   * Internal dependencies
1183   */
1184  
1185  
1186  const FocusControlContext = Object(external_wp_element_["createContext"])();
1187  function FocusControl({
1188    api,
1189    sidebarControls,
1190    children
1191  }) {
1192    const [focusedWidgetIdRef, setFocusedWidgetIdRef] = Object(external_wp_element_["useState"])({
1193      current: null
1194    });
1195    const focusWidget = Object(external_wp_element_["useCallback"])(widgetId => {
1196      for (const sidebarControl of sidebarControls) {
1197        const widgets = sidebarControl.setting.get();
1198  
1199        if (widgets.includes(widgetId)) {
1200          sidebarControl.sectionInstance.expand({
1201            // Schedule it after the complete callback so that
1202            // it won't be overridden by the "Back" button focus.
1203            completeCallback() {
1204              // Create a "ref-like" object every time to ensure
1205              // the same widget id can also triggers the focus control.
1206              setFocusedWidgetIdRef({
1207                current: widgetId
1208              });
1209            }
1210  
1211          });
1212          break;
1213        }
1214      }
1215    }, [sidebarControls]);
1216    Object(external_wp_element_["useEffect"])(() => {
1217      function handleFocus(settingId) {
1218        const widgetId = settingIdToWidgetId(settingId);
1219        focusWidget(widgetId);
1220      }
1221  
1222      function handleReady() {
1223        api.previewer.preview.bind('focus-control-for-setting', handleFocus);
1224      }
1225  
1226      api.previewer.bind('ready', handleReady);
1227      return () => {
1228        api.previewer.unbind('ready', handleReady);
1229        api.previewer.preview.unbind('focus-control-for-setting', handleFocus);
1230      };
1231    }, [api, focusWidget]);
1232    const context = Object(external_wp_element_["useMemo"])(() => [focusedWidgetIdRef, focusWidget], [focusedWidgetIdRef, focusWidget]);
1233    return Object(external_wp_element_["createElement"])(FocusControlContext.Provider, {
1234      value: context
1235    }, children);
1236  }
1237  const useFocusControl = () => Object(external_wp_element_["useContext"])(FocusControlContext);
1238  
1239  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/focus-control/use-blocks-focus-control.js
1240  /**
1241   * WordPress dependencies
1242   */
1243  
1244  
1245  
1246  
1247  /**
1248   * Internal dependencies
1249   */
1250  
1251  
1252  function useBlocksFocusControl(blocks) {
1253    const {
1254      selectBlock
1255    } = Object(external_wp_data_["useDispatch"])(external_wp_blockEditor_["store"]);
1256    const [focusedWidgetIdRef] = useFocusControl();
1257    const blocksRef = Object(external_wp_element_["useRef"])(blocks);
1258    Object(external_wp_element_["useEffect"])(() => {
1259      blocksRef.current = blocks;
1260    }, [blocks]);
1261    Object(external_wp_element_["useEffect"])(() => {
1262      if (focusedWidgetIdRef.current) {
1263        const focusedBlock = blocksRef.current.find(block => Object(external_wp_widgets_["getWidgetIdFromBlock"])(block) === focusedWidgetIdRef.current);
1264  
1265        if (focusedBlock) {
1266          selectBlock(focusedBlock.clientId); // If the block is already being selected, the DOM node won't
1267          // get focused again automatically.
1268          // We select the DOM and focus it manually here.
1269  
1270          const blockNode = document.querySelector(`[data-block="$focusedBlock.clientId}"]`);
1271          blockNode === null || blockNode === void 0 ? void 0 : blockNode.focus();
1272        }
1273      }
1274    }, [focusedWidgetIdRef, selectBlock]);
1275  }
1276  
1277  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/sidebar-block-editor/sidebar-editor-provider.js
1278  
1279  
1280  /**
1281   * WordPress dependencies
1282   */
1283  
1284  /**
1285   * Internal dependencies
1286   */
1287  
1288  
1289  
1290  function SidebarEditorProvider({
1291    sidebar,
1292    settings,
1293    children
1294  }) {
1295    const [blocks, onInput, onChange] = useSidebarBlockEditor(sidebar);
1296    useBlocksFocusControl(blocks);
1297    return Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockEditorProvider"], {
1298      value: blocks,
1299      onInput: onInput,
1300      onChange: onChange,
1301      settings: settings,
1302      useSubRegistry: false
1303    }, children);
1304  }
1305  
1306  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/welcome-guide/index.js
1307  
1308  
1309  /**
1310   * WordPress dependencies
1311   */
1312  
1313  
1314  
1315  /**
1316   * Internal dependencies
1317   */
1318  
1319  
1320  function WelcomeGuide({
1321    sidebar
1322  }) {
1323    const {
1324      __unstableToggleFeature: toggleFeature
1325    } = Object(external_wp_data_["useDispatch"])(store);
1326    const isEntirelyBlockWidgets = sidebar.getWidgets().every(widget => widget.id.startsWith('block-'));
1327    return Object(external_wp_element_["createElement"])("div", {
1328      className: "customize-widgets-welcome-guide"
1329    }, Object(external_wp_element_["createElement"])("div", {
1330      className: "customize-widgets-welcome-guide__image__wrapper"
1331    }, Object(external_wp_element_["createElement"])("picture", null, Object(external_wp_element_["createElement"])("source", {
1332      srcSet: "https://s.w.org/images/block-editor/welcome-editor.svg",
1333      media: "(prefers-reduced-motion: reduce)"
1334    }), Object(external_wp_element_["createElement"])("img", {
1335      className: "customize-widgets-welcome-guide__image",
1336      src: "https://s.w.org/images/block-editor/welcome-editor.gif",
1337      width: "312",
1338      height: "240",
1339      alt: ""
1340    }))), Object(external_wp_element_["createElement"])("h1", {
1341      className: "customize-widgets-welcome-guide__heading"
1342    }, Object(external_wp_i18n_["__"])('Welcome to block Widgets')), Object(external_wp_element_["createElement"])("p", {
1343      className: "customize-widgets-welcome-guide__text"
1344    }, isEntirelyBlockWidgets ? Object(external_wp_i18n_["__"])('Your theme provides different “block” areas for you to add and edit content. Try adding a search bar, social icons, or other types of blocks here and see how they’ll look on your site.') : Object(external_wp_i18n_["__"])('You can now add any block to your site’s widget areas. Don’t worry, all of your favorite widgets still work flawlessly.')), Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
1345      className: "customize-widgets-welcome-guide__button",
1346      isPrimary: true,
1347      onClick: () => toggleFeature('welcomeGuide')
1348    }, Object(external_wp_i18n_["__"])('Got it')), Object(external_wp_element_["createElement"])("hr", {
1349      className: "customize-widgets-welcome-guide__separator"
1350    }), !isEntirelyBlockWidgets && Object(external_wp_element_["createElement"])("p", {
1351      className: "customize-widgets-welcome-guide__more-info"
1352    }, Object(external_wp_i18n_["__"])('Want to stick with the old widgets?'), Object(external_wp_element_["createElement"])("br", null), Object(external_wp_element_["createElement"])(external_wp_components_["ExternalLink"], {
1353      href: Object(external_wp_i18n_["__"])('https://wordpress.org/plugins/classic-widgets/')
1354    }, Object(external_wp_i18n_["__"])('Get the Classic Widgets plugin.'))), Object(external_wp_element_["createElement"])("p", {
1355      className: "customize-widgets-welcome-guide__more-info"
1356    }, Object(external_wp_i18n_["__"])('New to the block editor?'), Object(external_wp_element_["createElement"])("br", null), Object(external_wp_element_["createElement"])(external_wp_components_["ExternalLink"], {
1357      href: Object(external_wp_i18n_["__"])('https://wordpress.org/support/article/wordpress-editor/')
1358    }, Object(external_wp_i18n_["__"])("Here's a detailed guide."))));
1359  }
1360  
1361  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/keyboard-shortcuts/index.js
1362  /**
1363   * WordPress dependencies
1364   */
1365  
1366  
1367  
1368  
1369  
1370  function KeyboardShortcuts({
1371    undo,
1372    redo,
1373    save
1374  }) {
1375    Object(external_wp_keyboardShortcuts_["useShortcut"])('core/customize-widgets/undo', event => {
1376      undo();
1377      event.preventDefault();
1378    }, {
1379      bindGlobal: true
1380    });
1381    Object(external_wp_keyboardShortcuts_["useShortcut"])('core/customize-widgets/redo', event => {
1382      redo();
1383      event.preventDefault();
1384    }, {
1385      bindGlobal: true
1386    });
1387    Object(external_wp_keyboardShortcuts_["useShortcut"])('core/customize-widgets/save', event => {
1388      event.preventDefault();
1389      save();
1390    }, {
1391      bindGlobal: true
1392    });
1393    return null;
1394  }
1395  
1396  function KeyboardShortcutsRegister() {
1397    const {
1398      registerShortcut,
1399      unregisterShortcut
1400    } = Object(external_wp_data_["useDispatch"])(external_wp_keyboardShortcuts_["store"]);
1401    Object(external_wp_element_["useEffect"])(() => {
1402      registerShortcut({
1403        name: 'core/customize-widgets/undo',
1404        category: 'global',
1405        description: Object(external_wp_i18n_["__"])('Undo your last changes.'),
1406        keyCombination: {
1407          modifier: 'primary',
1408          character: 'z'
1409        }
1410      });
1411      registerShortcut({
1412        name: 'core/customize-widgets/redo',
1413        category: 'global',
1414        description: Object(external_wp_i18n_["__"])('Redo your last undo.'),
1415        keyCombination: {
1416          modifier: 'primaryShift',
1417          character: 'z'
1418        }
1419      });
1420      registerShortcut({
1421        name: 'core/customize-widgets/save',
1422        category: 'global',
1423        description: Object(external_wp_i18n_["__"])('Save your changes.'),
1424        keyCombination: {
1425          modifier: 'primary',
1426          character: 's'
1427        }
1428      });
1429      return () => {
1430        unregisterShortcut('core/customize-widgets/undo');
1431        unregisterShortcut('core/customize-widgets/redo');
1432        unregisterShortcut('core/customize-widgets/save');
1433      };
1434    }, [registerShortcut]);
1435    return null;
1436  }
1437  
1438  KeyboardShortcuts.Register = KeyboardShortcutsRegister;
1439  /* harmony default export */ var keyboard_shortcuts = (KeyboardShortcuts);
1440  
1441  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/block-appender/index.js
1442  
1443  
1444  
1445  /**
1446   * WordPress dependencies
1447   */
1448  
1449  
1450  
1451  function BlockAppender(props) {
1452    const ref = Object(external_wp_element_["useRef"])();
1453    const isBlocksListEmpty = Object(external_wp_data_["useSelect"])(select => select(external_wp_blockEditor_["store"]).getBlockCount() === 0); // Move the focus to the block appender to prevent focus from
1454    // being lost when emptying the widget area.
1455  
1456    Object(external_wp_element_["useEffect"])(() => {
1457      if (isBlocksListEmpty && ref.current) {
1458        const {
1459          ownerDocument
1460        } = ref.current;
1461  
1462        if (!ownerDocument.activeElement || ownerDocument.activeElement === ownerDocument.body) {
1463          ref.current.focus();
1464        }
1465      }
1466    }, [isBlocksListEmpty]);
1467    return Object(external_wp_element_["createElement"])(external_wp_blockEditor_["ButtonBlockAppender"], Object(esm_extends["a" /* default */])({}, props, {
1468      ref: ref
1469    }));
1470  }
1471  
1472  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/sidebar-block-editor/index.js
1473  
1474  
1475  /**
1476   * External dependencies
1477   */
1478  
1479  /**
1480   * WordPress dependencies
1481   */
1482  
1483  
1484  
1485  
1486  
1487  
1488  /**
1489   * Internal dependencies
1490   */
1491  
1492  
1493  
1494  
1495  
1496  
1497  
1498  
1499  
1500  function SidebarBlockEditor({
1501    blockEditorSettings,
1502    sidebar,
1503    inserter,
1504    inspector
1505  }) {
1506    const [isInserterOpened, setIsInserterOpened] = useInserter(inserter);
1507    const {
1508      hasUploadPermissions,
1509      isFixedToolbarActive,
1510      keepCaretInsideBlock,
1511      isWelcomeGuideActive
1512    } = Object(external_wp_data_["useSelect"])(select => {
1513      return {
1514        hasUploadPermissions: Object(external_lodash_["defaultTo"])(select(external_wp_coreData_["store"]).canUser('create', 'media'), true),
1515        isFixedToolbarActive: select(store).__unstableIsFeatureActive('fixedToolbar'),
1516        keepCaretInsideBlock: select(store).__unstableIsFeatureActive('keepCaretInsideBlock'),
1517        isWelcomeGuideActive: select(store).__unstableIsFeatureActive('welcomeGuide')
1518      };
1519    }, []);
1520    const settings = Object(external_wp_element_["useMemo"])(() => {
1521      let mediaUploadBlockEditor;
1522  
1523      if (hasUploadPermissions) {
1524        mediaUploadBlockEditor = ({
1525          onError,
1526          ...argumentsObject
1527        }) => {
1528          Object(external_wp_mediaUtils_["uploadMedia"])({
1529            wpAllowedMimeTypes: blockEditorSettings.allowedMimeTypes,
1530            onError: ({
1531              message
1532            }) => onError(message),
1533            ...argumentsObject
1534          });
1535        };
1536      }
1537  
1538      return { ...blockEditorSettings,
1539        __experimentalSetIsInserterOpened: setIsInserterOpened,
1540        mediaUpload: mediaUploadBlockEditor,
1541        hasFixedToolbar: isFixedToolbarActive,
1542        keepCaretInsideBlock,
1543        __unstableHasCustomAppender: true
1544      };
1545    }, [hasUploadPermissions, blockEditorSettings, isFixedToolbarActive, keepCaretInsideBlock]);
1546  
1547    if (isWelcomeGuideActive) {
1548      return Object(external_wp_element_["createElement"])(WelcomeGuide, {
1549        sidebar: sidebar
1550      });
1551    }
1552  
1553    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockEditorKeyboardShortcuts"].Register, null), Object(external_wp_element_["createElement"])(keyboard_shortcuts.Register, null), Object(external_wp_element_["createElement"])(SidebarEditorProvider, {
1554      sidebar: sidebar,
1555      settings: settings
1556    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockEditorKeyboardShortcuts"], null), Object(external_wp_element_["createElement"])(keyboard_shortcuts, {
1557      undo: sidebar.undo,
1558      redo: sidebar.redo,
1559      save: sidebar.save
1560    }), Object(external_wp_element_["createElement"])(header, {
1561      sidebar: sidebar,
1562      inserter: inserter,
1563      isInserterOpened: isInserterOpened,
1564      setIsInserterOpened: setIsInserterOpened,
1565      isFixedToolbarActive: isFixedToolbarActive
1566    }), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["CopyHandler"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockTools"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockSelectionClearer"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["WritingFlow"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["ObserveTyping"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockList"], {
1567      renderAppender: BlockAppender
1568    })))))), Object(external_wp_element_["createPortal"])( // This is a temporary hack to prevent button component inside <BlockInspector>
1569    // from submitting form when type="button" is not specified.
1570    Object(external_wp_element_["createElement"])("form", {
1571      onSubmit: event => event.preventDefault()
1572    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockInspector"], null)), inspector.contentContainer[0])), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["__unstableBlockSettingsMenuFirstItem"], null, ({
1573      onClose
1574    }) => Object(external_wp_element_["createElement"])(block_inspector_button, {
1575      inspector: inspector,
1576      closeMenu: onClose
1577    })));
1578  }
1579  
1580  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/sidebar-controls/index.js
1581  
1582  
1583  /**
1584   * WordPress dependencies
1585   */
1586  
1587  const SidebarControlsContext = Object(external_wp_element_["createContext"])();
1588  function SidebarControls({
1589    sidebarControls,
1590    activeSidebarControl,
1591    children
1592  }) {
1593    const context = Object(external_wp_element_["useMemo"])(() => ({
1594      sidebarControls,
1595      activeSidebarControl
1596    }), [sidebarControls, activeSidebarControl]);
1597    return Object(external_wp_element_["createElement"])(SidebarControlsContext.Provider, {
1598      value: context
1599    }, children);
1600  }
1601  function useSidebarControls() {
1602    const {
1603      sidebarControls
1604    } = Object(external_wp_element_["useContext"])(SidebarControlsContext);
1605    return sidebarControls;
1606  }
1607  function useActiveSidebarControl() {
1608    const {
1609      activeSidebarControl
1610    } = Object(external_wp_element_["useContext"])(SidebarControlsContext);
1611    return activeSidebarControl;
1612  }
1613  
1614  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/customize-widgets/use-clear-selected-block.js
1615  /**
1616   * WordPress dependencies
1617   */
1618  
1619  
1620  
1621  /**
1622   * We can't just use <BlockSelectionClearer> because the customizer has
1623   * many root nodes rather than just one in the post editor.
1624   * We need to listen to the focus events in all those roots, and also in
1625   * the preview iframe.
1626   * This hook will clear the selected block when focusing outside the editor,
1627   * with a few exceptions:
1628   * 1. Focusing on popovers.
1629   * 2. Focusing on the inspector.
1630   * 3. Focusing on any modals/dialogs.
1631   * These cases are normally triggered by user interactions from the editor,
1632   * not by explicitly focusing outside the editor, hence no need for clearing.
1633   *
1634   * @param {Object} sidebarControl The sidebar control instance.
1635   * @param {Object} popoverRef The ref object of the popover node container.
1636   */
1637  
1638  function useClearSelectedBlock(sidebarControl, popoverRef) {
1639    const {
1640      hasSelectedBlock,
1641      hasMultiSelection
1642    } = Object(external_wp_data_["useSelect"])(external_wp_blockEditor_["store"]);
1643    const {
1644      clearSelectedBlock
1645    } = Object(external_wp_data_["useDispatch"])(external_wp_blockEditor_["store"]);
1646    Object(external_wp_element_["useEffect"])(() => {
1647      if (popoverRef.current && sidebarControl) {
1648        const inspector = sidebarControl.inspector;
1649        const container = sidebarControl.container[0];
1650        const ownerDocument = container.ownerDocument;
1651        const ownerWindow = ownerDocument.defaultView;
1652  
1653        function handleClearSelectedBlock(element) {
1654          if ( // 1. Make sure there are blocks being selected.
1655          (hasSelectedBlock() || hasMultiSelection()) && // 2. The element should exist in the DOM (not deleted).
1656          element && ownerDocument.contains(element) && // 3. It should also not exist in the container, the popover, nor the dialog.
1657          !container.contains(element) && !popoverRef.current.contains(element) && !element.closest('[role="dialog"]') && // 4. The inspector should not be opened.
1658          !inspector.expanded()) {
1659            clearSelectedBlock();
1660          }
1661        } // Handle mouse down in the same document.
1662  
1663  
1664        function handleMouseDown(event) {
1665          handleClearSelectedBlock(event.target);
1666        } // Handle focusing outside the current document, like to iframes.
1667  
1668  
1669        function handleBlur() {
1670          handleClearSelectedBlock(ownerDocument.activeElement);
1671        }
1672  
1673        ownerDocument.addEventListener('mousedown', handleMouseDown);
1674        ownerWindow.addEventListener('blur', handleBlur);
1675        return () => {
1676          ownerDocument.removeEventListener('mousedown', handleMouseDown);
1677          ownerWindow.removeEventListener('blur', handleBlur);
1678        };
1679      }
1680    }, [popoverRef, sidebarControl, hasSelectedBlock, hasMultiSelection, clearSelectedBlock]);
1681  }
1682  
1683  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/customize-widgets/index.js
1684  
1685  
1686  /**
1687   * WordPress dependencies
1688   */
1689  
1690  
1691  /**
1692   * Internal dependencies
1693   */
1694  
1695  
1696  
1697  
1698  
1699  function CustomizeWidgets({
1700    api,
1701    sidebarControls,
1702    blockEditorSettings
1703  }) {
1704    const [activeSidebarControl, setActiveSidebarControl] = Object(external_wp_element_["useState"])(null);
1705    const parentContainer = document.getElementById('customize-theme-controls');
1706    const popoverRef = Object(external_wp_element_["useRef"])();
1707    useClearSelectedBlock(activeSidebarControl, popoverRef);
1708    Object(external_wp_element_["useEffect"])(() => {
1709      const unsubscribers = sidebarControls.map(sidebarControl => sidebarControl.subscribe(expanded => {
1710        if (expanded) {
1711          setActiveSidebarControl(sidebarControl);
1712        }
1713      }));
1714      return () => {
1715        unsubscribers.forEach(unsubscriber => unsubscriber());
1716      };
1717    }, [sidebarControls]);
1718    const activeSidebar = activeSidebarControl && Object(external_wp_element_["createPortal"])(Object(external_wp_element_["createElement"])(SidebarBlockEditor, {
1719      key: activeSidebarControl.id,
1720      blockEditorSettings: blockEditorSettings,
1721      sidebar: activeSidebarControl.sidebarAdapter,
1722      inserter: activeSidebarControl.inserter,
1723      inspector: activeSidebarControl.inspector
1724    }), activeSidebarControl.container[0]); // We have to portal this to the parent of both the editor and the inspector,
1725    // so that the popovers will appear above both of them.
1726  
1727    const popover = parentContainer && Object(external_wp_element_["createPortal"])(Object(external_wp_element_["createElement"])("div", {
1728      className: "customize-widgets-popover",
1729      ref: popoverRef
1730    }, Object(external_wp_element_["createElement"])(external_wp_components_["Popover"].Slot, null)), parentContainer);
1731    return Object(external_wp_element_["createElement"])(external_wp_components_["SlotFillProvider"], null, Object(external_wp_element_["createElement"])(SidebarControls, {
1732      sidebarControls: sidebarControls,
1733      activeSidebarControl: activeSidebarControl
1734    }, Object(external_wp_element_["createElement"])(FocusControl, {
1735      api: api,
1736      sidebarControls: sidebarControls
1737    }, activeSidebar, popover)));
1738  }
1739  
1740  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/controls/inspector-section.js
1741  function getInspectorSection() {
1742    const {
1743      wp: {
1744        customize
1745      }
1746    } = window;
1747    return class InspectorSection extends customize.Section {
1748      constructor(id, options) {
1749        super(id, options);
1750        this.parentSection = options.parentSection;
1751        this.returnFocusWhenClose = null;
1752      }
1753  
1754      ready() {
1755        this.contentContainer[0].classList.add('customize-widgets-layout__inspector');
1756      }
1757  
1758      onChangeExpanded(expanded, args) {
1759        super.onChangeExpanded(expanded, args);
1760  
1761        if (this.parentSection && !args.unchanged) {
1762          if (expanded) {
1763            this.parentSection.collapse({
1764              manualTransition: true
1765            });
1766          } else {
1767            this.parentSection.expand({
1768              manualTransition: true,
1769              completeCallback: () => {
1770                // Return focus after finishing the transition.
1771                if (this.returnFocusWhenClose && !this.contentContainer[0].contains(this.returnFocusWhenClose)) {
1772                  this.returnFocusWhenClose.focus();
1773                }
1774              }
1775            });
1776          }
1777        }
1778      }
1779  
1780      open({
1781        returnFocusWhenClose
1782      } = {}) {
1783        this.returnFocusWhenClose = returnFocusWhenClose;
1784        this.expand({
1785          allowMultiple: true
1786        });
1787      }
1788  
1789      close() {
1790        this.collapse({
1791          allowMultiple: true
1792        });
1793      }
1794  
1795    };
1796  }
1797  
1798  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/controls/sidebar-section.js
1799  /**
1800   * WordPress dependencies
1801   */
1802  
1803  /**
1804   * Internal dependencies
1805   */
1806  
1807  
1808  
1809  const getInspectorSectionId = sidebarId => `widgets-inspector-$sidebarId}`;
1810  
1811  function getSidebarSection() {
1812    const {
1813      wp: {
1814        customize
1815      }
1816    } = window;
1817    return class SidebarSection extends customize.Section {
1818      ready() {
1819        const InspectorSection = getInspectorSection();
1820        this.inspector = new InspectorSection(getInspectorSectionId(this.id), {
1821          title: Object(external_wp_i18n_["__"])('Block Settings'),
1822          parentSection: this,
1823          customizeAction: [Object(external_wp_i18n_["__"])('Customizing'), Object(external_wp_i18n_["__"])('Widgets'), this.params.title].join(' ▸ ')
1824        });
1825        customize.section.add(this.inspector);
1826        this.contentContainer[0].classList.add('customize-widgets__sidebar-section');
1827      }
1828  
1829      hasSubSectionOpened() {
1830        return this.inspector.expanded();
1831      }
1832  
1833      onChangeExpanded(expanded, _args) {
1834        const controls = this.controls();
1835        const args = { ..._args,
1836  
1837          completeCallback() {
1838            var _args$completeCallbac;
1839  
1840            controls.forEach(control => {
1841              control.onChangeSectionExpanded(expanded, args);
1842            });
1843            (_args$completeCallbac = _args.completeCallback) === null || _args$completeCallbac === void 0 ? void 0 : _args$completeCallbac.call(_args);
1844          }
1845  
1846        };
1847  
1848        if (args.manualTransition) {
1849          if (expanded) {
1850            this.contentContainer.addClass(['busy', 'open']);
1851            this.contentContainer.removeClass('is-sub-section-open');
1852            this.contentContainer.closest('.wp-full-overlay').addClass('section-open');
1853            this.contentContainer.one('transitionend', () => {
1854              this.contentContainer.removeClass('busy');
1855              args.completeCallback();
1856            });
1857          } else {
1858            this.contentContainer.addClass(['busy', 'is-sub-section-open']);
1859            this.contentContainer.closest('.wp-full-overlay').addClass('section-open');
1860            this.contentContainer.removeClass('open');
1861            this.contentContainer.one('transitionend', () => {
1862              this.contentContainer.removeClass('busy');
1863              args.completeCallback();
1864            });
1865          }
1866        } else {
1867          super.onChangeExpanded(expanded, args);
1868        }
1869      }
1870  
1871    };
1872  }
1873  
1874  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/components/sidebar-block-editor/sidebar-adapter.js
1875  /**
1876   * Internal dependencies
1877   */
1878  
1879  const {
1880    wp
1881  } = window;
1882  
1883  function parseWidgetId(widgetId) {
1884    const matches = widgetId.match(/^(.+)-(\d+)$/);
1885  
1886    if (matches) {
1887      return {
1888        idBase: matches[1],
1889        number: parseInt(matches[2], 10)
1890      };
1891    } // Likely an old single widget.
1892  
1893  
1894    return {
1895      idBase: widgetId
1896    };
1897  }
1898  
1899  function widgetIdToSettingId(widgetId) {
1900    const {
1901      idBase,
1902      number
1903    } = parseWidgetId(widgetId);
1904  
1905    if (number) {
1906      return `widget_$idBase}[$number}]`;
1907    }
1908  
1909    return `widget_$idBase}`;
1910  }
1911  /**
1912   * This is a custom debounce function to call different callbacks depending on
1913   * whether it's the _leading_ call or not.
1914   *
1915   * @param {Function} leading  The callback that gets called first.
1916   * @param {Function} callback The callback that gets called after the first time.
1917   * @param {number}   timeout  The debounced time in milliseconds.
1918   * @return {Function} The debounced function.
1919   */
1920  
1921  
1922  function debounce(leading, callback, timeout) {
1923    let isLeading = false;
1924    let timerID;
1925  
1926    function debounced(...args) {
1927      const result = (isLeading ? callback : leading).apply(this, args);
1928      isLeading = true;
1929      clearTimeout(timerID);
1930      timerID = setTimeout(() => {
1931        isLeading = false;
1932      }, timeout);
1933      return result;
1934    }
1935  
1936    debounced.cancel = () => {
1937      isLeading = false;
1938      clearTimeout(timerID);
1939    };
1940  
1941    return debounced;
1942  }
1943  
1944  class sidebar_adapter_SidebarAdapter {
1945    constructor(setting, api) {
1946      this.setting = setting;
1947      this.api = api;
1948      this.locked = false;
1949      this.widgetsCache = new WeakMap();
1950      this.subscribers = new Set();
1951      this.history = [this._getWidgetIds().map(widgetId => this.getWidget(widgetId))];
1952      this.historyIndex = 0;
1953      this.historySubscribers = new Set(); // Debounce the input for 1 second.
1954  
1955      this._debounceSetHistory = debounce(this._pushHistory, this._replaceHistory, 1000);
1956      this.setting.bind(this._handleSettingChange.bind(this));
1957      this.api.bind('change', this._handleAllSettingsChange.bind(this));
1958      this.undo = this.undo.bind(this);
1959      this.redo = this.redo.bind(this);
1960      this.save = this.save.bind(this);
1961    }
1962  
1963    subscribe(callback) {
1964      this.subscribers.add(callback);
1965      return () => {
1966        this.subscribers.delete(callback);
1967      };
1968    }
1969  
1970    getWidgets() {
1971      return this.history[this.historyIndex];
1972    }
1973  
1974    _emit(...args) {
1975      for (const callback of this.subscribers) {
1976        callback(...args);
1977      }
1978    }
1979  
1980    _getWidgetIds() {
1981      return this.setting.get();
1982    }
1983  
1984    _pushHistory() {
1985      this.history = [...this.history.slice(0, this.historyIndex + 1), this._getWidgetIds().map(widgetId => this.getWidget(widgetId))];
1986      this.historyIndex += 1;
1987      this.historySubscribers.forEach(listener => listener());
1988    }
1989  
1990    _replaceHistory() {
1991      this.history[this.historyIndex] = this._getWidgetIds().map(widgetId => this.getWidget(widgetId));
1992    }
1993  
1994    _handleSettingChange() {
1995      if (this.locked) {
1996        return;
1997      }
1998  
1999      const prevWidgets = this.getWidgets();
2000  
2001      this._pushHistory();
2002  
2003      this._emit(prevWidgets, this.getWidgets());
2004    }
2005  
2006    _handleAllSettingsChange(setting) {
2007      if (this.locked) {
2008        return;
2009      }
2010  
2011      if (!setting.id.startsWith('widget_')) {
2012        return;
2013      }
2014  
2015      const widgetId = settingIdToWidgetId(setting.id);
2016  
2017      if (!this.setting.get().includes(widgetId)) {
2018        return;
2019      }
2020  
2021      const prevWidgets = this.getWidgets();
2022  
2023      this._pushHistory();
2024  
2025      this._emit(prevWidgets, this.getWidgets());
2026    }
2027  
2028    _createWidget(widget) {
2029      const widgetModel = wp.customize.Widgets.availableWidgets.findWhere({
2030        id_base: widget.idBase
2031      });
2032      let number = widget.number;
2033  
2034      if (widgetModel.get('is_multi') && !number) {
2035        widgetModel.set('multi_number', widgetModel.get('multi_number') + 1);
2036        number = widgetModel.get('multi_number');
2037      }
2038  
2039      const settingId = number ? `widget_$widget.idBase}[$number}]` : `widget_$widget.idBase}`;
2040      const settingArgs = {
2041        transport: wp.customize.Widgets.data.selectiveRefreshableWidgets[widgetModel.get('id_base')] ? 'postMessage' : 'refresh',
2042        previewer: this.setting.previewer
2043      };
2044      const setting = this.api.create(settingId, settingId, '', settingArgs);
2045      setting.set(widget.instance);
2046      const widgetId = settingIdToWidgetId(settingId);
2047      return widgetId;
2048    }
2049  
2050    _removeWidget(widget) {
2051      const settingId = widgetIdToSettingId(widget.id);
2052      const setting = this.api(settingId);
2053  
2054      if (setting) {
2055        const instance = setting.get();
2056        this.widgetsCache.delete(instance);
2057      }
2058  
2059      this.api.remove(settingId);
2060    }
2061  
2062    _updateWidget(widget) {
2063      const prevWidget = this.getWidget(widget.id); // Bail out update if nothing changed.
2064  
2065      if (prevWidget === widget) {
2066        return widget.id;
2067      } // Update existing setting if only the widget's instance changed.
2068  
2069  
2070      if (prevWidget.idBase && widget.idBase && prevWidget.idBase === widget.idBase) {
2071        const settingId = widgetIdToSettingId(widget.id);
2072        this.api(settingId).set(widget.instance);
2073        return widget.id;
2074      } // Otherwise delete and re-create.
2075  
2076  
2077      this._removeWidget(widget);
2078  
2079      return this._createWidget(widget);
2080    }
2081  
2082    getWidget(widgetId) {
2083      if (!widgetId) {
2084        return null;
2085      }
2086  
2087      const {
2088        idBase,
2089        number
2090      } = parseWidgetId(widgetId);
2091      const settingId = widgetIdToSettingId(widgetId);
2092      const setting = this.api(settingId);
2093  
2094      if (!setting) {
2095        return null;
2096      }
2097  
2098      const instance = setting.get();
2099  
2100      if (this.widgetsCache.has(instance)) {
2101        return this.widgetsCache.get(instance);
2102      }
2103  
2104      const widget = {
2105        id: widgetId,
2106        idBase,
2107        number,
2108        instance
2109      };
2110      this.widgetsCache.set(instance, widget);
2111      return widget;
2112    }
2113  
2114    _updateWidgets(nextWidgets) {
2115      this.locked = true;
2116      const addedWidgetIds = [];
2117      const nextWidgetIds = nextWidgets.map(nextWidget => {
2118        if (nextWidget.id && this.getWidget(nextWidget.id)) {
2119          addedWidgetIds.push(null);
2120          return this._updateWidget(nextWidget);
2121        }
2122  
2123        const widgetId = this._createWidget(nextWidget);
2124  
2125        addedWidgetIds.push(widgetId);
2126        return widgetId;
2127      });
2128      const deletedWidgets = this.getWidgets().filter(widget => !nextWidgetIds.includes(widget.id));
2129      deletedWidgets.forEach(widget => this._removeWidget(widget));
2130      this.setting.set(nextWidgetIds);
2131      this.locked = false;
2132      return addedWidgetIds;
2133    }
2134  
2135    setWidgets(nextWidgets) {
2136      const addedWidgetIds = this._updateWidgets(nextWidgets);
2137  
2138      this._debounceSetHistory();
2139  
2140      return addedWidgetIds;
2141    }
2142    /**
2143     * Undo/Redo related features
2144     */
2145  
2146  
2147    hasUndo() {
2148      return this.historyIndex > 0;
2149    }
2150  
2151    hasRedo() {
2152      return this.historyIndex < this.history.length - 1;
2153    }
2154  
2155    _seek(historyIndex) {
2156      const currentWidgets = this.getWidgets();
2157      this.historyIndex = historyIndex;
2158      const widgets = this.history[this.historyIndex];
2159  
2160      this._updateWidgets(widgets);
2161  
2162      this._emit(currentWidgets, this.getWidgets());
2163  
2164      this.historySubscribers.forEach(listener => listener());
2165  
2166      this._debounceSetHistory.cancel();
2167    }
2168  
2169    undo() {
2170      if (!this.hasUndo()) {
2171        return;
2172      }
2173  
2174      this._seek(this.historyIndex - 1);
2175    }
2176  
2177    redo() {
2178      if (!this.hasRedo()) {
2179        return;
2180      }
2181  
2182      this._seek(this.historyIndex + 1);
2183    }
2184  
2185    subscribeHistory(listener) {
2186      this.historySubscribers.add(listener);
2187      return () => {
2188        this.historySubscribers.delete(listener);
2189      };
2190    }
2191  
2192    save() {
2193      this.api.previewer.save();
2194    }
2195  
2196  }
2197  
2198  // EXTERNAL MODULE: external ["wp","dom"]
2199  var external_wp_dom_ = __webpack_require__("1CF3");
2200  
2201  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/controls/inserter-outer-section.js
2202  /**
2203   * WordPress dependencies
2204   */
2205  
2206  
2207  function getInserterOuterSection() {
2208    const {
2209      wp: {
2210        customize
2211      }
2212    } = window;
2213    const OuterSection = customize.OuterSection; // Override the OuterSection class to handle multiple outer sections.
2214    // It closes all the other outer sections whenever one is opened.
2215    // The result is that at most one outer section can be opened at the same time.
2216  
2217    customize.OuterSection = class extends OuterSection {
2218      onChangeExpanded(expanded, args) {
2219        if (expanded) {
2220          customize.section.each(section => {
2221            if (section.params.type === 'outer' && section.id !== this.id) {
2222              if (section.expanded()) {
2223                section.collapse();
2224              }
2225            }
2226          });
2227        }
2228  
2229        return super.onChangeExpanded(expanded, args);
2230      }
2231  
2232    }; // Handle constructor so that "params.type" can be correctly pointed to "outer".
2233  
2234    customize.sectionConstructor.outer = customize.OuterSection;
2235    return class InserterOuterSection extends customize.OuterSection {
2236      constructor(...args) {
2237        super(...args); // This is necessary since we're creating a new class which is not identical to the original OuterSection.
2238        // @See https://github.com/WordPress/wordpress-develop/blob/42b05c397c50d9dc244083eff52991413909d4bd/src/js/_enqueues/wp/customize/controls.js#L1427-L1436
2239  
2240        this.params.type = 'outer';
2241        this.activeElementBeforeExpanded = null;
2242        const ownerWindow = this.contentContainer[0].ownerDocument.defaultView; // Handle closing the inserter when pressing the Escape key.
2243  
2244        ownerWindow.addEventListener('keydown', event => {
2245          if (this.isOpen && (event.keyCode === external_wp_keycodes_["ESCAPE"] || event.code === 'Escape')) {
2246            event.stopPropagation();
2247            this.close();
2248          }
2249        }, // Use capture mode to make this run before other event listeners.
2250        true);
2251        this.contentContainer.addClass('widgets-inserter');
2252      }
2253  
2254      get isOpen() {
2255        return this.expanded();
2256      }
2257  
2258      subscribe(handler) {
2259        this.expanded.bind(handler);
2260        return () => this.expanded.unbind(handler);
2261      }
2262  
2263      open() {
2264        if (!this.isOpen) {
2265          const contentContainer = this.contentContainer[0];
2266          this.activeElementBeforeExpanded = contentContainer.ownerDocument.activeElement;
2267          this.expand({
2268            completeCallback() {
2269              // We have to do this in a "completeCallback" or else the elements will not yet be visible/tabbable.
2270              // The first one should be the close button,
2271              // we want to skip it and choose the second one instead, which is the search box.
2272              const searchBox = external_wp_dom_["focus"].tabbable.find(contentContainer)[1];
2273  
2274              if (searchBox) {
2275                searchBox.focus();
2276              }
2277            }
2278  
2279          });
2280        }
2281      }
2282  
2283      close() {
2284        if (this.isOpen) {
2285          const contentContainer = this.contentContainer[0];
2286          const activeElement = contentContainer.ownerDocument.activeElement;
2287          this.collapse({
2288            completeCallback() {
2289              // Return back the focus when closing the inserter.
2290              // Only do this if the active element which triggers the action is inside the inserter,
2291              // (the close button for instance). In that case the focus will be lost.
2292              // Otherwise, we don't hijack the focus when the user is focusing on other elements
2293              // (like the quick inserter).
2294              if (contentContainer.contains(activeElement)) {
2295                // Return back the focus when closing the inserter.
2296                if (this.activeElementBeforeExpanded) {
2297                  this.activeElementBeforeExpanded.focus();
2298                }
2299              }
2300            }
2301  
2302          });
2303        }
2304      }
2305  
2306    };
2307  }
2308  
2309  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/controls/sidebar-control.js
2310  /**
2311   * Internal dependencies
2312   */
2313  
2314  
2315  
2316  const getInserterId = controlId => `widgets-inserter-$controlId}`;
2317  
2318  function getSidebarControl() {
2319    const {
2320      wp: {
2321        customize
2322      }
2323    } = window;
2324    return class SidebarControl extends customize.Control {
2325      constructor(...args) {
2326        super(...args);
2327        this.subscribers = new Set();
2328      }
2329  
2330      ready() {
2331        const InserterOuterSection = getInserterOuterSection();
2332        this.inserter = new InserterOuterSection(getInserterId(this.id), {});
2333        customize.section.add(this.inserter);
2334        this.sectionInstance = customize.section(this.section());
2335        this.inspector = this.sectionInstance.inspector;
2336        this.sidebarAdapter = new sidebar_adapter_SidebarAdapter(this.setting, customize);
2337      }
2338  
2339      subscribe(callback) {
2340        this.subscribers.add(callback);
2341        return () => {
2342          this.subscribers.delete(callback);
2343        };
2344      }
2345  
2346      onChangeSectionExpanded(expanded, args) {
2347        if (!args.unchanged) {
2348          // Close the inserter when the section collapses.
2349          if (!expanded) {
2350            this.inserter.close();
2351          }
2352  
2353          this.subscribers.forEach(subscriber => subscriber(expanded, args));
2354        }
2355      }
2356  
2357    };
2358  }
2359  
2360  // EXTERNAL MODULE: external ["wp","hooks"]
2361  var external_wp_hooks_ = __webpack_require__("g56x");
2362  
2363  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/filters/move-to-sidebar.js
2364  
2365  
2366  /**
2367   * External dependencies
2368   */
2369  
2370  /**
2371   * WordPress dependencies
2372   */
2373  
2374  
2375  
2376  
2377  
2378  
2379  /**
2380   * Internal dependencies
2381   */
2382  
2383  
2384  
2385  
2386  const withMoveToSidebarToolbarItem = Object(external_wp_compose_["createHigherOrderComponent"])(BlockEdit => props => {
2387    let widgetId = Object(external_wp_widgets_["getWidgetIdFromBlock"])(props);
2388    const sidebarControls = useSidebarControls();
2389    const activeSidebarControl = useActiveSidebarControl();
2390    const hasMultipleSidebars = (sidebarControls === null || sidebarControls === void 0 ? void 0 : sidebarControls.length) > 1;
2391    const blockName = props.name;
2392    const clientId = props.clientId;
2393    const canInsertBlockInSidebar = Object(external_wp_data_["useSelect"])(select => {
2394      // Use an empty string to represent the root block list, which
2395      // in the customizer editor represents a sidebar/widget area.
2396      return select(external_wp_blockEditor_["store"]).canInsertBlockType(blockName, '');
2397    }, [blockName]);
2398    const block = Object(external_wp_data_["useSelect"])(select => select(external_wp_blockEditor_["store"]).getBlock(clientId), [clientId]);
2399    const {
2400      removeBlock
2401    } = Object(external_wp_data_["useDispatch"])(external_wp_blockEditor_["store"]);
2402    const [, focusWidget] = useFocusControl();
2403  
2404    function moveToSidebar(sidebarControlId) {
2405      const newSidebarControl = sidebarControls.find(sidebarControl => sidebarControl.id === sidebarControlId);
2406  
2407      if (widgetId) {
2408        /**
2409         * If there's a widgetId, move it to the other sidebar.
2410         */
2411        const oldSetting = activeSidebarControl.setting;
2412        const newSetting = newSidebarControl.setting;
2413        oldSetting(Object(external_lodash_["without"])(oldSetting(), widgetId));
2414        newSetting([...newSetting(), widgetId]);
2415      } else {
2416        /**
2417         * If there isn't a widgetId, it's most likely a inner block.
2418         * First, remove the block in the original sidebar,
2419         * then, create a new widget in the new sidebar and get back its widgetId.
2420         */
2421        const sidebarAdapter = newSidebarControl.sidebarAdapter;
2422        removeBlock(clientId);
2423        const addedWidgetIds = sidebarAdapter.setWidgets([...sidebarAdapter.getWidgets(), blockToWidget(block)]); // The last non-null id is the added widget's id.
2424  
2425        widgetId = addedWidgetIds.reverse().find(id => !!id);
2426      } // Move focus to the moved widget and expand the sidebar.
2427  
2428  
2429      focusWidget(widgetId);
2430    }
2431  
2432    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(BlockEdit, props), hasMultipleSidebars && canInsertBlockInSidebar && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockControls"], null, Object(external_wp_element_["createElement"])(external_wp_widgets_["MoveToWidgetArea"], {
2433      widgetAreas: sidebarControls.map(sidebarControl => ({
2434        id: sidebarControl.id,
2435        name: sidebarControl.params.label,
2436        description: sidebarControl.params.description
2437      })),
2438      currentWidgetAreaId: activeSidebarControl === null || activeSidebarControl === void 0 ? void 0 : activeSidebarControl.id,
2439      onSelect: moveToSidebar
2440    })));
2441  }, 'withMoveToSidebarToolbarItem');
2442  Object(external_wp_hooks_["addFilter"])('editor.BlockEdit', 'core/customize-widgets/block-edit', withMoveToSidebarToolbarItem);
2443  
2444  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/filters/replace-media-upload.js
2445  /**
2446   * WordPress dependencies
2447   */
2448  
2449  
2450  
2451  const replaceMediaUpload = () => external_wp_mediaUtils_["MediaUpload"];
2452  
2453  Object(external_wp_hooks_["addFilter"])('editor.MediaUpload', 'core/edit-widgets/replace-media-upload', replaceMediaUpload);
2454  
2455  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/filters/wide-widget-display.js
2456  
2457  
2458  
2459  /**
2460   * WordPress dependencies
2461   */
2462  
2463  
2464  const {
2465    wp: wide_widget_display_wp
2466  } = window;
2467  const withWideWidgetDisplay = Object(external_wp_compose_["createHigherOrderComponent"])(BlockEdit => props => {
2468    var _wp$customize$Widgets, _wp$customize$Widgets2;
2469  
2470    const {
2471      idBase
2472    } = props.attributes;
2473    const isWide = (_wp$customize$Widgets = (_wp$customize$Widgets2 = wide_widget_display_wp.customize.Widgets.data.availableWidgets.find(widget => widget.id_base === idBase)) === null || _wp$customize$Widgets2 === void 0 ? void 0 : _wp$customize$Widgets2.is_wide) !== null && _wp$customize$Widgets !== void 0 ? _wp$customize$Widgets : false;
2474    return Object(external_wp_element_["createElement"])(BlockEdit, Object(esm_extends["a" /* default */])({}, props, {
2475      isWide: isWide
2476    }));
2477  }, 'withWideWidgetDisplay');
2478  Object(external_wp_hooks_["addFilter"])('editor.BlockEdit', 'core/customize-widgets/wide-widget-display', withWideWidgetDisplay);
2479  
2480  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/filters/index.js
2481  /**
2482   * Internal dependencies
2483   */
2484  
2485  
2486  
2487  
2488  // CONCATENATED MODULE: ./node_modules/@wordpress/customize-widgets/build-module/index.js
2489  
2490  
2491  /**
2492   * WordPress dependencies
2493   */
2494  
2495  
2496  
2497  
2498  /**
2499   * Internal dependencies
2500   */
2501  
2502  
2503  
2504  
2505  
2506  const {
2507    wp: build_module_wp
2508  } = window;
2509  const DISABLED_BLOCKS = ['core/more', 'core/block', 'core/freeform'];
2510  const ENABLE_EXPERIMENTAL_FSE_BLOCKS = false;
2511  /**
2512   * Initializes the widgets block editor in the customizer.
2513   *
2514   * @param {string} editorName          The editor name.
2515   * @param {Object} blockEditorSettings Block editor settings.
2516   */
2517  
2518  function initialize(editorName, blockEditorSettings) {
2519    const coreBlocks = Object(external_wp_blockLibrary_["__experimentalGetCoreBlocks"])().filter(block => {
2520      return !(DISABLED_BLOCKS.includes(block.name) || block.name.startsWith('core/post') || block.name.startsWith('core/query') || block.name.startsWith('core/site'));
2521    });
2522  
2523    Object(external_wp_blockLibrary_["registerCoreBlocks"])(coreBlocks);
2524    Object(external_wp_widgets_["registerLegacyWidgetBlock"])();
2525  
2526    if (false) {}
2527  
2528    Object(external_wp_widgets_["registerLegacyWidgetVariations"])(blockEditorSettings); // As we are unregistering `core/freeform` to avoid the Classic block, we must
2529    // replace it with something as the default freeform content handler. Failure to
2530    // do this will result in errors in the default block parser.
2531    // see: https://github.com/WordPress/gutenberg/issues/33097
2532  
2533    Object(external_wp_blocks_["setFreeformContentHandlerName"])('core/html');
2534    const SidebarControl = getSidebarControl(blockEditorSettings);
2535    build_module_wp.customize.sectionConstructor.sidebar = getSidebarSection();
2536    build_module_wp.customize.controlConstructor.sidebar_block_editor = SidebarControl;
2537    const container = document.createElement('div');
2538    document.body.appendChild(container);
2539    build_module_wp.customize.bind('ready', () => {
2540      const sidebarControls = [];
2541      build_module_wp.customize.control.each(control => {
2542        if (control instanceof SidebarControl) {
2543          sidebarControls.push(control);
2544        }
2545      });
2546      Object(external_wp_element_["render"])(Object(external_wp_element_["createElement"])(CustomizeWidgets, {
2547        api: build_module_wp.customize,
2548        sidebarControls: sidebarControls,
2549        blockEditorSettings: blockEditorSettings
2550      }), container);
2551    });
2552  }
2553  
2554  
2555  /***/ }),
2556  
2557  /***/ "GLVC":
2558  /***/ (function(module, exports) {
2559  
2560  (function() { module.exports = window["wp"]["widgets"]; }());
2561  
2562  /***/ }),
2563  
2564  /***/ "GRId":
2565  /***/ (function(module, exports) {
2566  
2567  (function() { module.exports = window["wp"]["element"]; }());
2568  
2569  /***/ }),
2570  
2571  /***/ "HSyU":
2572  /***/ (function(module, exports) {
2573  
2574  (function() { module.exports = window["wp"]["blocks"]; }());
2575  
2576  /***/ }),
2577  
2578  /***/ "K+tz":
2579  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2580  
2581  "use strict";
2582  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
2583  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
2584  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
2585  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
2586  
2587  
2588  /**
2589   * WordPress dependencies
2590   */
2591  
2592  const external = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
2593    xmlns: "http://www.w3.org/2000/svg",
2594    viewBox: "0 0 24 24"
2595  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
2596    d: "M18.2 17c0 .7-.6 1.2-1.2 1.2H7c-.7 0-1.2-.6-1.2-1.2V7c0-.7.6-1.2 1.2-1.2h3.2V4.2H7C5.5 4.2 4.2 5.5 4.2 7v10c0 1.5 1.2 2.8 2.8 2.8h10c1.5 0 2.8-1.2 2.8-2.8v-3.6h-1.5V17zM14.9 3v1.5h3.7l-6.4 6.4 1.1 1.1 6.4-6.4v3.7h1.5V3h-6.3z"
2597  }));
2598  /* harmony default export */ __webpack_exports__["a"] = (external);
2599  
2600  
2601  /***/ }),
2602  
2603  /***/ "K2cm":
2604  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2605  
2606  "use strict";
2607  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
2608  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
2609  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
2610  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
2611  
2612  
2613  /**
2614   * WordPress dependencies
2615   */
2616  
2617  const redo = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
2618    xmlns: "http://www.w3.org/2000/svg",
2619    viewBox: "0 0 24 24"
2620  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
2621    d: "M15.6 6.5l-1.1 1 2.9 3.3H8c-.9 0-1.7.3-2.3.9-1.4 1.5-1.4 4.2-1.4 5.6v.2h1.5v-.3c0-1.1 0-3.5 1-4.5.3-.3.7-.5 1.3-.5h9.2L14.5 15l1.1 1.1 4.6-4.6-4.6-5z"
2622  }));
2623  /* harmony default export */ __webpack_exports__["a"] = (redo);
2624  
2625  
2626  /***/ }),
2627  
2628  /***/ "K9lf":
2629  /***/ (function(module, exports) {
2630  
2631  (function() { module.exports = window["wp"]["compose"]; }());
2632  
2633  /***/ }),
2634  
2635  /***/ "Ntru":
2636  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2637  
2638  "use strict";
2639  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
2640  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
2641  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
2642  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
2643  
2644  
2645  /**
2646   * WordPress dependencies
2647   */
2648  
2649  const undo = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
2650    xmlns: "http://www.w3.org/2000/svg",
2651    viewBox: "0 0 24 24"
2652  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
2653    d: "M18.3 11.7c-.6-.6-1.4-.9-2.3-.9H6.7l2.9-3.3-1.1-1-4.5 5L8.5 16l1-1-2.7-2.7H16c.5 0 .9.2 1.3.5 1 1 1 3.4 1 4.5v.3h1.5v-.2c0-1.5 0-4.3-1.5-5.7z"
2654  }));
2655  /* harmony default export */ __webpack_exports__["a"] = (undo);
2656  
2657  
2658  /***/ }),
2659  
2660  /***/ "Q4Sy":
2661  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2662  
2663  "use strict";
2664  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
2665  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
2666  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
2667  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
2668  
2669  
2670  /**
2671   * WordPress dependencies
2672   */
2673  
2674  const plus = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
2675    xmlns: "http://www.w3.org/2000/svg",
2676    viewBox: "0 0 24 24"
2677  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
2678    d: "M18 11.2h-5.2V6h-1.6v5.2H6v1.6h5.2V18h1.6v-5.2H18z"
2679  }));
2680  /* harmony default export */ __webpack_exports__["a"] = (plus);
2681  
2682  
2683  /***/ }),
2684  
2685  /***/ "QyPg":
2686  /***/ (function(module, exports) {
2687  
2688  (function() { module.exports = window["wp"]["blockLibrary"]; }());
2689  
2690  /***/ }),
2691  
2692  /***/ "RMJe":
2693  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2694  
2695  "use strict";
2696  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
2697  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
2698  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
2699  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
2700  
2701  
2702  /**
2703   * WordPress dependencies
2704   */
2705  
2706  const check = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
2707    xmlns: "http://www.w3.org/2000/svg",
2708    viewBox: "0 0 24 24"
2709  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
2710    d: "M18.3 5.6L9.9 16.9l-4.6-3.4-.9 1.2 5.8 4.3 9.3-12.6z"
2711  }));
2712  /* harmony default export */ __webpack_exports__["a"] = (check);
2713  
2714  
2715  /***/ }),
2716  
2717  /***/ "RxS6":
2718  /***/ (function(module, exports) {
2719  
2720  (function() { module.exports = window["wp"]["keycodes"]; }());
2721  
2722  /***/ }),
2723  
2724  /***/ "TSYQ":
2725  /***/ (function(module, exports, __webpack_require__) {
2726  
2727  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
2728    Copyright (c) 2018 Jed Watson.
2729    Licensed under the MIT License (MIT), see
2730    http://jedwatson.github.io/classnames
2731  */
2732  /* global define */
2733  
2734  (function () {
2735      'use strict';
2736  
2737      var hasOwn = {}.hasOwnProperty;
2738  
2739  	function classNames() {
2740          var classes = [];
2741  
2742          for (var i = 0; i < arguments.length; i++) {
2743              var arg = arguments[i];
2744              if (!arg) continue;
2745  
2746              var argType = typeof arg;
2747  
2748              if (argType === 'string' || argType === 'number') {
2749                  classes.push(arg);
2750              } else if (Array.isArray(arg)) {
2751                  if (arg.length) {
2752                      var inner = classNames.apply(null, arg);
2753                      if (inner) {
2754                          classes.push(inner);
2755                      }
2756                  }
2757              } else if (argType === 'object') {
2758                  if (arg.toString === Object.prototype.toString) {
2759                      for (var key in arg) {
2760                          if (hasOwn.call(arg, key) && arg[key]) {
2761                              classes.push(key);
2762                          }
2763                      }
2764                  } else {
2765                      classes.push(arg.toString());
2766                  }
2767              }
2768          }
2769  
2770          return classes.join(' ');
2771      }
2772  
2773      if ( true && module.exports) {
2774          classNames.default = classNames;
2775          module.exports = classNames;
2776      } else if (true) {
2777          // register as 'classnames', consistent with npm package name
2778          !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = (function () {
2779              return classNames;
2780          }).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),
2781                  __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
2782      } else {}
2783  }());
2784  
2785  
2786  /***/ }),
2787  
2788  /***/ "Tqx9":
2789  /***/ (function(module, exports) {
2790  
2791  (function() { module.exports = window["wp"]["primitives"]; }());
2792  
2793  /***/ }),
2794  
2795  /***/ "VKE3":
2796  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2797  
2798  "use strict";
2799  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
2800  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
2801  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
2802  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
2803  
2804  
2805  /**
2806   * WordPress dependencies
2807   */
2808  
2809  const moreVertical = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
2810    xmlns: "http://www.w3.org/2000/svg",
2811    viewBox: "0 0 24 24"
2812  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
2813    d: "M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"
2814  }));
2815  /* harmony default export */ __webpack_exports__["a"] = (moreVertical);
2816  
2817  
2818  /***/ }),
2819  
2820  /***/ "YLtl":
2821  /***/ (function(module, exports) {
2822  
2823  (function() { module.exports = window["lodash"]; }());
2824  
2825  /***/ }),
2826  
2827  /***/ "axFQ":
2828  /***/ (function(module, exports) {
2829  
2830  (function() { module.exports = window["wp"]["blockEditor"]; }());
2831  
2832  /***/ }),
2833  
2834  /***/ "bWcr":
2835  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2836  
2837  "use strict";
2838  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
2839  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
2840  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
2841  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
2842  
2843  
2844  /**
2845   * WordPress dependencies
2846   */
2847  
2848  const closeSmall = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
2849    xmlns: "http://www.w3.org/2000/svg",
2850    viewBox: "0 0 24 24"
2851  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
2852    d: "M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"
2853  }));
2854  /* harmony default export */ __webpack_exports__["a"] = (closeSmall);
2855  
2856  
2857  /***/ }),
2858  
2859  /***/ "g56x":
2860  /***/ (function(module, exports) {
2861  
2862  (function() { module.exports = window["wp"]["hooks"]; }());
2863  
2864  /***/ }),
2865  
2866  /***/ "gdqT":
2867  /***/ (function(module, exports) {
2868  
2869  (function() { module.exports = window["wp"]["a11y"]; }());
2870  
2871  /***/ }),
2872  
2873  /***/ "hF7m":
2874  /***/ (function(module, exports) {
2875  
2876  (function() { module.exports = window["wp"]["keyboardShortcuts"]; }());
2877  
2878  /***/ }),
2879  
2880  /***/ "jZUy":
2881  /***/ (function(module, exports) {
2882  
2883  (function() { module.exports = window["wp"]["coreData"]; }());
2884  
2885  /***/ }),
2886  
2887  /***/ "l3Sj":
2888  /***/ (function(module, exports) {
2889  
2890  (function() { module.exports = window["wp"]["i18n"]; }());
2891  
2892  /***/ }),
2893  
2894  /***/ "rl8x":
2895  /***/ (function(module, exports) {
2896  
2897  (function() { module.exports = window["wp"]["isShallowEqual"]; }());
2898  
2899  /***/ }),
2900  
2901  /***/ "tI+e":
2902  /***/ (function(module, exports) {
2903  
2904  (function() { module.exports = window["wp"]["components"]; }());
2905  
2906  /***/ }),
2907  
2908  /***/ "wx14":
2909  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2910  
2911  "use strict";
2912  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _extends; });
2913  function _extends() {
2914    _extends = Object.assign || function (target) {
2915      for (var i = 1; i < arguments.length; i++) {
2916        var source = arguments[i];
2917  
2918        for (var key in source) {
2919          if (Object.prototype.hasOwnProperty.call(source, key)) {
2920            target[key] = source[key];
2921          }
2922        }
2923      }
2924  
2925      return target;
2926    };
2927  
2928    return _extends.apply(this, arguments);
2929  }
2930  
2931  /***/ })
2932  
2933  /******/ });


Generated: Sun Aug 1 01:00:05 2021 Cross-referenced by PHPXref 0.7.1