[ Index ]

PHP Cross Reference of WordPress

title

Body

[close]

/wp-includes/js/dist/ -> block-library.js (source)

   1  this["wp"] = this["wp"] || {}; this["wp"]["blockLibrary"] =
   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 = "K51g");
  86  /******/ })
  87  /************************************************************************/
  88  /******/ ({
  89  
  90  /***/ "1CF3":
  91  /***/ (function(module, exports) {
  92  
  93  (function() { module.exports = window["wp"]["dom"]; }());
  94  
  95  /***/ }),
  96  
  97  /***/ "1K8p":
  98  /***/ (function(module, exports, __webpack_require__) {
  99  
 100  "use strict";
 101  /**
 102   * Copyright (c) 2015, Facebook, Inc.
 103   * All rights reserved.
 104   *
 105   * This source code is licensed under the BSD-style license found in the
 106   * LICENSE file in the root directory of this source tree. An additional grant
 107   * of patent rights can be found in the PATENTS file in the same directory.
 108   *
 109   * @providesModule normalizeWheel
 110   * @typechecks
 111   */
 112  
 113  
 114  
 115  var UserAgent_DEPRECATED = __webpack_require__("jrfk");
 116  
 117  var isEventSupported = __webpack_require__("ez49");
 118  
 119  
 120  // Reasonable defaults
 121  var PIXEL_STEP  = 10;
 122  var LINE_HEIGHT = 40;
 123  var PAGE_HEIGHT = 800;
 124  
 125  /**
 126   * Mouse wheel (and 2-finger trackpad) support on the web sucks.  It is
 127   * complicated, thus this doc is long and (hopefully) detailed enough to answer
 128   * your questions.
 129   *
 130   * If you need to react to the mouse wheel in a predictable way, this code is
 131   * like your bestest friend. * hugs *
 132   *
 133   * As of today, there are 4 DOM event types you can listen to:
 134   *
 135   *   'wheel'                -- Chrome(31+), FF(17+), IE(9+)
 136   *   'mousewheel'           -- Chrome, IE(6+), Opera, Safari
 137   *   'MozMousePixelScroll'  -- FF(3.5 only!) (2010-2013) -- don't bother!
 138   *   'DOMMouseScroll'       -- FF(0.9.7+) since 2003
 139   *
 140   * So what to do?  The is the best:
 141   *
 142   *   normalizeWheel.getEventType();
 143   *
 144   * In your event callback, use this code to get sane interpretation of the
 145   * deltas.  This code will return an object with properties:
 146   *
 147   *   spinX   -- normalized spin speed (use for zoom) - x plane
 148   *   spinY   -- " - y plane
 149   *   pixelX  -- normalized distance (to pixels) - x plane
 150   *   pixelY  -- " - y plane
 151   *
 152   * Wheel values are provided by the browser assuming you are using the wheel to
 153   * scroll a web page by a number of lines or pixels (or pages).  Values can vary
 154   * significantly on different platforms and browsers, forgetting that you can
 155   * scroll at different speeds.  Some devices (like trackpads) emit more events
 156   * at smaller increments with fine granularity, and some emit massive jumps with
 157   * linear speed or acceleration.
 158   *
 159   * This code does its best to normalize the deltas for you:
 160   *
 161   *   - spin is trying to normalize how far the wheel was spun (or trackpad
 162   *     dragged).  This is super useful for zoom support where you want to
 163   *     throw away the chunky scroll steps on the PC and make those equal to
 164   *     the slow and smooth tiny steps on the Mac. Key data: This code tries to
 165   *     resolve a single slow step on a wheel to 1.
 166   *
 167   *   - pixel is normalizing the desired scroll delta in pixel units.  You'll
 168   *     get the crazy differences between browsers, but at least it'll be in
 169   *     pixels!
 170   *
 171   *   - positive value indicates scrolling DOWN/RIGHT, negative UP/LEFT.  This
 172   *     should translate to positive value zooming IN, negative zooming OUT.
 173   *     This matches the newer 'wheel' event.
 174   *
 175   * Why are there spinX, spinY (or pixels)?
 176   *
 177   *   - spinX is a 2-finger side drag on the trackpad, and a shift + wheel turn
 178   *     with a mouse.  It results in side-scrolling in the browser by default.
 179   *
 180   *   - spinY is what you expect -- it's the classic axis of a mouse wheel.
 181   *
 182   *   - I dropped spinZ/pixelZ.  It is supported by the DOM 3 'wheel' event and
 183   *     probably is by browsers in conjunction with fancy 3D controllers .. but
 184   *     you know.
 185   *
 186   * Implementation info:
 187   *
 188   * Examples of 'wheel' event if you scroll slowly (down) by one step with an
 189   * average mouse:
 190   *
 191   *   OS X + Chrome  (mouse)     -    4   pixel delta  (wheelDelta -120)
 192   *   OS X + Safari  (mouse)     -  N/A   pixel delta  (wheelDelta  -12)
 193   *   OS X + Firefox (mouse)     -    0.1 line  delta  (wheelDelta  N/A)
 194   *   Win8 + Chrome  (mouse)     -  100   pixel delta  (wheelDelta -120)
 195   *   Win8 + Firefox (mouse)     -    3   line  delta  (wheelDelta -120)
 196   *
 197   * On the trackpad:
 198   *
 199   *   OS X + Chrome  (trackpad)  -    2   pixel delta  (wheelDelta   -6)
 200   *   OS X + Firefox (trackpad)  -    1   pixel delta  (wheelDelta  N/A)
 201   *
 202   * On other/older browsers.. it's more complicated as there can be multiple and
 203   * also missing delta values.
 204   *
 205   * The 'wheel' event is more standard:
 206   *
 207   * http://www.w3.org/TR/DOM-Level-3-Events/#events-wheelevents
 208   *
 209   * The basics is that it includes a unit, deltaMode (pixels, lines, pages), and
 210   * deltaX, deltaY and deltaZ.  Some browsers provide other values to maintain
 211   * backward compatibility with older events.  Those other values help us
 212   * better normalize spin speed.  Example of what the browsers provide:
 213   *
 214   *                          | event.wheelDelta | event.detail
 215   *        ------------------+------------------+--------------
 216   *          Safari v5/OS X  |       -120       |       0
 217   *          Safari v5/Win7  |       -120       |       0
 218   *         Chrome v17/OS X  |       -120       |       0
 219   *         Chrome v17/Win7  |       -120       |       0
 220   *                IE9/Win7  |       -120       |   undefined
 221   *         Firefox v4/OS X  |     undefined    |       1
 222   *         Firefox v4/Win7  |     undefined    |       3
 223   *
 224   */
 225  function normalizeWheel(/*object*/ event) /*object*/ {
 226    var sX = 0, sY = 0,       // spinX, spinY
 227        pX = 0, pY = 0;       // pixelX, pixelY
 228  
 229    // Legacy
 230    if ('detail'      in event) { sY = event.detail; }
 231    if ('wheelDelta'  in event) { sY = -event.wheelDelta / 120; }
 232    if ('wheelDeltaY' in event) { sY = -event.wheelDeltaY / 120; }
 233    if ('wheelDeltaX' in event) { sX = -event.wheelDeltaX / 120; }
 234  
 235    // side scrolling on FF with DOMMouseScroll
 236    if ( 'axis' in event && event.axis === event.HORIZONTAL_AXIS ) {
 237      sX = sY;
 238      sY = 0;
 239    }
 240  
 241    pX = sX * PIXEL_STEP;
 242    pY = sY * PIXEL_STEP;
 243  
 244    if ('deltaY' in event) { pY = event.deltaY; }
 245    if ('deltaX' in event) { pX = event.deltaX; }
 246  
 247    if ((pX || pY) && event.deltaMode) {
 248      if (event.deltaMode == 1) {          // delta in LINE units
 249        pX *= LINE_HEIGHT;
 250        pY *= LINE_HEIGHT;
 251      } else {                             // delta in PAGE units
 252        pX *= PAGE_HEIGHT;
 253        pY *= PAGE_HEIGHT;
 254      }
 255    }
 256  
 257    // Fall-back if spin cannot be determined
 258    if (pX && !sX) { sX = (pX < 1) ? -1 : 1; }
 259    if (pY && !sY) { sY = (pY < 1) ? -1 : 1; }
 260  
 261    return { spinX  : sX,
 262             spinY  : sY,
 263             pixelX : pX,
 264             pixelY : pY };
 265  }
 266  
 267  
 268  /**
 269   * The best combination if you prefer spinX + spinY normalization.  It favors
 270   * the older DOMMouseScroll for Firefox, as FF does not include wheelDelta with
 271   * 'wheel' event, making spin speed determination impossible.
 272   */
 273  normalizeWheel.getEventType = function() /*string*/ {
 274    return (UserAgent_DEPRECATED.firefox())
 275             ? 'DOMMouseScroll'
 276             : (isEventSupported('wheel'))
 277                 ? 'wheel'
 278                 : 'mousewheel';
 279  };
 280  
 281  module.exports = normalizeWheel;
 282  
 283  
 284  /***/ }),
 285  
 286  /***/ "1Yn1":
 287  /***/ (function(module, __webpack_exports__, __webpack_require__) {
 288  
 289  "use strict";
 290  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
 291  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
 292  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
 293  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
 294  
 295  
 296  /**
 297   * WordPress dependencies
 298   */
 299  
 300  const code = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
 301    viewBox: "0 0 24 24",
 302    xmlns: "http://www.w3.org/2000/svg"
 303  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
 304    d: "M20.8 10.7l-4.3-4.3-1.1 1.1 4.3 4.3c.1.1.1.3 0 .4l-4.3 4.3 1.1 1.1 4.3-4.3c.7-.8.7-1.9 0-2.6zM4.2 11.8l4.3-4.3-1-1-4.3 4.3c-.7.7-.7 1.8 0 2.5l4.3 4.3 1.1-1.1-4.3-4.3c-.2-.1-.2-.3-.1-.4z"
 305  }));
 306  /* harmony default export */ __webpack_exports__["a"] = (code);
 307  
 308  
 309  /***/ }),
 310  
 311  /***/ "1ZqX":
 312  /***/ (function(module, exports) {
 313  
 314  (function() { module.exports = window["wp"]["data"]; }());
 315  
 316  /***/ }),
 317  
 318  /***/ "1iEr":
 319  /***/ (function(module, __webpack_exports__, __webpack_require__) {
 320  
 321  "use strict";
 322  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
 323  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
 324  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
 325  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
 326  
 327  
 328  /**
 329   * WordPress dependencies
 330   */
 331  
 332  const chevronRight = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
 333    xmlns: "http://www.w3.org/2000/svg",
 334    viewBox: "0 0 24 24"
 335  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
 336    d: "M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"
 337  }));
 338  /* harmony default export */ __webpack_exports__["a"] = (chevronRight);
 339  
 340  
 341  /***/ }),
 342  
 343  /***/ "2gm7":
 344  /***/ (function(module, __webpack_exports__, __webpack_require__) {
 345  
 346  "use strict";
 347  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
 348  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
 349  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
 350  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
 351  
 352  
 353  /**
 354   * WordPress dependencies
 355   */
 356  
 357  const chevronLeft = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
 358    xmlns: "http://www.w3.org/2000/svg",
 359    viewBox: "0 0 24 24"
 360  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
 361    d: "M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"
 362  }));
 363  /* harmony default export */ __webpack_exports__["a"] = (chevronLeft);
 364  
 365  
 366  /***/ }),
 367  
 368  /***/ "4eJC":
 369  /***/ (function(module, exports, __webpack_require__) {
 370  
 371  /**
 372   * Memize options object.
 373   *
 374   * @typedef MemizeOptions
 375   *
 376   * @property {number} [maxSize] Maximum size of the cache.
 377   */
 378  
 379  /**
 380   * Internal cache entry.
 381   *
 382   * @typedef MemizeCacheNode
 383   *
 384   * @property {?MemizeCacheNode|undefined} [prev] Previous node.
 385   * @property {?MemizeCacheNode|undefined} [next] Next node.
 386   * @property {Array<*>}                   args   Function arguments for cache
 387   *                                               entry.
 388   * @property {*}                          val    Function result.
 389   */
 390  
 391  /**
 392   * Properties of the enhanced function for controlling cache.
 393   *
 394   * @typedef MemizeMemoizedFunction
 395   *
 396   * @property {()=>void} clear Clear the cache.
 397   */
 398  
 399  /**
 400   * Accepts a function to be memoized, and returns a new memoized function, with
 401   * optional options.
 402   *
 403   * @template {Function} F
 404   *
 405   * @param {F}             fn        Function to memoize.
 406   * @param {MemizeOptions} [options] Options object.
 407   *
 408   * @return {F & MemizeMemoizedFunction} Memoized function.
 409   */
 410  function memize( fn, options ) {
 411      var size = 0;
 412  
 413      /** @type {?MemizeCacheNode|undefined} */
 414      var head;
 415  
 416      /** @type {?MemizeCacheNode|undefined} */
 417      var tail;
 418  
 419      options = options || {};
 420  
 421  	function memoized( /* ...args */ ) {
 422          var node = head,
 423              len = arguments.length,
 424              args, i;
 425  
 426          searchCache: while ( node ) {
 427              // Perform a shallow equality test to confirm that whether the node
 428              // under test is a candidate for the arguments passed. Two arrays
 429              // are shallowly equal if their length matches and each entry is
 430              // strictly equal between the two sets. Avoid abstracting to a
 431              // function which could incur an arguments leaking deoptimization.
 432  
 433              // Check whether node arguments match arguments length
 434              if ( node.args.length !== arguments.length ) {
 435                  node = node.next;
 436                  continue;
 437              }
 438  
 439              // Check whether node arguments match arguments values
 440              for ( i = 0; i < len; i++ ) {
 441                  if ( node.args[ i ] !== arguments[ i ] ) {
 442                      node = node.next;
 443                      continue searchCache;
 444                  }
 445              }
 446  
 447              // At this point we can assume we've found a match
 448  
 449              // Surface matched node to head if not already
 450              if ( node !== head ) {
 451                  // As tail, shift to previous. Must only shift if not also
 452                  // head, since if both head and tail, there is no previous.
 453                  if ( node === tail ) {
 454                      tail = node.prev;
 455                  }
 456  
 457                  // Adjust siblings to point to each other. If node was tail,
 458                  // this also handles new tail's empty `next` assignment.
 459                  /** @type {MemizeCacheNode} */ ( node.prev ).next = node.next;
 460                  if ( node.next ) {
 461                      node.next.prev = node.prev;
 462                  }
 463  
 464                  node.next = head;
 465                  node.prev = null;
 466                  /** @type {MemizeCacheNode} */ ( head ).prev = node;
 467                  head = node;
 468              }
 469  
 470              // Return immediately
 471              return node.val;
 472          }
 473  
 474          // No cached value found. Continue to insertion phase:
 475  
 476          // Create a copy of arguments (avoid leaking deoptimization)
 477          args = new Array( len );
 478          for ( i = 0; i < len; i++ ) {
 479              args[ i ] = arguments[ i ];
 480          }
 481  
 482          node = {
 483              args: args,
 484  
 485              // Generate the result from original function
 486              val: fn.apply( null, args ),
 487          };
 488  
 489          // Don't need to check whether node is already head, since it would
 490          // have been returned above already if it was
 491  
 492          // Shift existing head down list
 493          if ( head ) {
 494              head.prev = node;
 495              node.next = head;
 496          } else {
 497              // If no head, follows that there's no tail (at initial or reset)
 498              tail = node;
 499          }
 500  
 501          // Trim tail if we're reached max size and are pending cache insertion
 502          if ( size === /** @type {MemizeOptions} */ ( options ).maxSize ) {
 503              tail = /** @type {MemizeCacheNode} */ ( tail ).prev;
 504              /** @type {MemizeCacheNode} */ ( tail ).next = null;
 505          } else {
 506              size++;
 507          }
 508  
 509          head = node;
 510  
 511          return node.val;
 512      }
 513  
 514      memoized.clear = function() {
 515          head = null;
 516          tail = null;
 517          size = 0;
 518      };
 519  
 520      if ( false ) {}
 521  
 522      // Ignore reason: There's not a clear solution to create an intersection of
 523      // the function with additional properties, where the goal is to retain the
 524      // function signature of the incoming argument and add control properties
 525      // on the return value.
 526  
 527      // @ts-ignore
 528      return memoized;
 529  }
 530  
 531  module.exports = memize;
 532  
 533  
 534  /***/ }),
 535  
 536  /***/ "A/WM":
 537  /***/ (function(module, exports, __webpack_require__) {
 538  
 539  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
 540    Copyright (c) 2018 Jed Watson.
 541    Licensed under the MIT License (MIT), see
 542    http://jedwatson.github.io/classnames
 543  */
 544  /* global define */
 545  
 546  (function () {
 547      'use strict';
 548  
 549      var classNames = (function () {
 550          // don't inherit from Object so we can skip hasOwnProperty check later
 551          // http://stackoverflow.com/questions/15518328/creating-js-object-with-object-createnull#answer-21079232
 552  		function StorageObject() {}
 553          StorageObject.prototype = Object.create(null);
 554  
 555  		function _parseArray (resultSet, array) {
 556              var length = array.length;
 557  
 558              for (var i = 0; i < length; ++i) {
 559                  _parse(resultSet, array[i]);
 560              }
 561          }
 562  
 563          var hasOwn = {}.hasOwnProperty;
 564  
 565  		function _parseNumber (resultSet, num) {
 566              resultSet[num] = true;
 567          }
 568  
 569  		function _parseObject (resultSet, object) {
 570              if (object.toString === Object.prototype.toString) {
 571                  for (var k in object) {
 572                      if (hasOwn.call(object, k)) {
 573                          // set value to false instead of deleting it to avoid changing object structure
 574                          // https://www.smashingmagazine.com/2012/11/writing-fast-memory-efficient-javascript/#de-referencing-misconceptions
 575                          resultSet[k] = !!object[k];
 576                      }
 577                  }
 578              } else {
 579                  resultSet[object.toString()] = true;
 580              }
 581          }
 582  
 583          var SPACE = /\s+/;
 584  		function _parseString (resultSet, str) {
 585              var array = str.split(SPACE);
 586              var length = array.length;
 587  
 588              for (var i = 0; i < length; ++i) {
 589                  resultSet[array[i]] = true;
 590              }
 591          }
 592  
 593  		function _parse (resultSet, arg) {
 594              if (!arg) return;
 595              var argType = typeof arg;
 596  
 597              // 'foo bar'
 598              if (argType === 'string') {
 599                  _parseString(resultSet, arg);
 600  
 601              // ['foo', 'bar', ...]
 602              } else if (Array.isArray(arg)) {
 603                  _parseArray(resultSet, arg);
 604  
 605              // { 'foo': true, ... }
 606              } else if (argType === 'object') {
 607                  _parseObject(resultSet, arg);
 608  
 609              // '130'
 610              } else if (argType === 'number') {
 611                  _parseNumber(resultSet, arg);
 612              }
 613          }
 614  
 615  		function _classNames () {
 616              // don't leak arguments
 617              // https://github.com/petkaantonov/bluebird/wiki/Optimization-killers#32-leaking-arguments
 618              var len = arguments.length;
 619              var args = Array(len);
 620              for (var i = 0; i < len; i++) {
 621                  args[i] = arguments[i];
 622              }
 623  
 624              var classSet = new StorageObject();
 625              _parseArray(classSet, args);
 626  
 627              var list = [];
 628  
 629              for (var k in classSet) {
 630                  if (classSet[k]) {
 631                      list.push(k)
 632                  }
 633              }
 634  
 635              return list.join(' ');
 636          }
 637  
 638          return _classNames;
 639      })();
 640  
 641      if ( true && module.exports) {
 642          classNames.default = classNames;
 643          module.exports = classNames;
 644      } else if (true) {
 645          // register as 'classnames', consistent with npm package name
 646          !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = (function () {
 647              return classNames;
 648          }).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),
 649                  __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
 650      } else {}
 651  }());
 652  
 653  
 654  /***/ }),
 655  
 656  /***/ "B9Az":
 657  /***/ (function(module, __webpack_exports__, __webpack_require__) {
 658  
 659  "use strict";
 660  
 661  // EXTERNAL MODULE: external ["wp","element"]
 662  var external_wp_element_ = __webpack_require__("GRId");
 663  
 664  // EXTERNAL MODULE: external ["wp","primitives"]
 665  var external_wp_primitives_ = __webpack_require__("Tqx9");
 666  
 667  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/pencil.js
 668  
 669  
 670  /**
 671   * WordPress dependencies
 672   */
 673  
 674  const pencil = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
 675    xmlns: "http://www.w3.org/2000/svg",
 676    viewBox: "0 0 24 24"
 677  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
 678    d: "M20.1 5.1L16.9 2 6.2 12.7l-1.3 4.4 4.5-1.3L20.1 5.1zM4 20.8h8v-1.5H4v1.5z"
 679  }));
 680  /* harmony default export */ var library_pencil = (pencil);
 681  
 682  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/edit.js
 683  /**
 684   * Internal dependencies
 685   */
 686  
 687  /* harmony default export */ var edit = __webpack_exports__["a"] = (library_pencil);
 688  
 689  
 690  /***/ }),
 691  
 692  /***/ "Bpkj":
 693  /***/ (function(module, __webpack_exports__, __webpack_require__) {
 694  
 695  "use strict";
 696  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("GRId");
 697  /* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
 698  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("Tqx9");
 699  /* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
 700  
 701  
 702  /**
 703   * WordPress dependencies
 704   */
 705  
 706  const link = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
 707    xmlns: "http://www.w3.org/2000/svg",
 708    viewBox: "0 0 24 24"
 709  }, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
 710    d: "M15.6 7.2H14v1.5h1.6c2 0 3.7 1.7 3.7 3.7s-1.7 3.7-3.7 3.7H14v1.5h1.6c2.8 0 5.2-2.3 5.2-5.2 0-2.9-2.3-5.2-5.2-5.2zM4.7 12.4c0-2 1.7-3.7 3.7-3.7H10V7.2H8.4c-2.9 0-5.2 2.3-5.2 5.2 0 2.9 2.3 5.2 5.2 5.2H10v-1.5H8.4c-2 0-3.7-1.7-3.7-3.7zm4.6.9h5.3v-1.5H9.3v1.5z"
 711  }));
 712  /* harmony default export */ __webpack_exports__["a"] = (link);
 713  
 714  
 715  /***/ }),
 716  
 717  /***/ "FEKF":
 718  /***/ (function(module, exports, __webpack_require__) {
 719  
 720  /*! Fast Average Color | © 2019 Denis Seleznev | MIT License | https://github.com/hcodes/fast-average-color/ */
 721  (function (global, factory) {
 722       true ? module.exports = factory() :
 723      undefined;
 724  }(this, (function () { 'use strict';
 725  
 726  function _classCallCheck(instance, Constructor) {
 727    if (!(instance instanceof Constructor)) {
 728      throw new TypeError("Cannot call a class as a function");
 729    }
 730  }
 731  
 732  function _defineProperties(target, props) {
 733    for (var i = 0; i < props.length; i++) {
 734      var descriptor = props[i];
 735      descriptor.enumerable = descriptor.enumerable || false;
 736      descriptor.configurable = true;
 737      if ("value" in descriptor) descriptor.writable = true;
 738      Object.defineProperty(target, descriptor.key, descriptor);
 739    }
 740  }
 741  
 742  function _createClass(Constructor, protoProps, staticProps) {
 743    if (protoProps) _defineProperties(Constructor.prototype, protoProps);
 744    if (staticProps) _defineProperties(Constructor, staticProps);
 745    return Constructor;
 746  }
 747  
 748  function _slicedToArray(arr, i) {
 749    return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest();
 750  }
 751  
 752  function _arrayWithHoles(arr) {
 753    if (Array.isArray(arr)) return arr;
 754  }
 755  
 756  function _iterableToArrayLimit(arr, i) {
 757    var _arr = [];
 758    var _n = true;
 759    var _d = false;
 760    var _e = undefined;
 761  
 762    try {
 763      for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
 764        _arr.push(_s.value);
 765  
 766        if (i && _arr.length === i) break;
 767      }
 768    } catch (err) {
 769      _d = true;
 770      _e = err;
 771    } finally {
 772      try {
 773        if (!_n && _i["return"] != null) _i["return"]();
 774      } finally {
 775        if (_d) throw _e;
 776      }
 777    }
 778  
 779    return _arr;
 780  }
 781  
 782  function _nonIterableRest() {
 783    throw new TypeError("Invalid attempt to destructure non-iterable instance");
 784  }
 785  
 786  var FastAverageColor =
 787  /*#__PURE__*/
 788  function () {
 789    function FastAverageColor() {
 790      _classCallCheck(this, FastAverageColor);
 791    }
 792  
 793    _createClass(FastAverageColor, [{
 794      key: "getColorAsync",
 795  
 796      /**
 797       * Get asynchronously the average color from not loaded image.
 798       *
 799       * @param {HTMLImageElement} resource
 800       * @param {Function} callback
 801       * @param {Object|null} [options]
 802       * @param {Array}  [options.defaultColor=[255, 255, 255, 255]]
 803       * @param {*}      [options.data]
 804       * @param {string} [options.mode="speed"] "precision" or "speed"
 805       * @param {string} [options.algorithm="sqrt"] "simple", "sqrt" or "dominant"
 806       * @param {number} [options.step=1]
 807       * @param {number} [options.left=0]
 808       * @param {number} [options.top=0]
 809       * @param {number} [options.width=width of resource]
 810       * @param {number} [options.height=height of resource]
 811       */
 812      value: function getColorAsync(resource, callback, options) {
 813        if (resource.complete) {
 814          callback.call(resource, this.getColor(resource, options), options && options.data);
 815        } else {
 816          this._bindImageEvents(resource, callback, options);
 817        }
 818      }
 819      /**
 820       * Get the average color from images, videos and canvas.
 821       *
 822       * @param {HTMLImageElement|HTMLVideoElement|HTMLCanvasElement} resource
 823       * @param {Object|null} [options]
 824       * @param {Array}  [options.defaultColor=[255, 255, 255, 255]]
 825       * @param {*}      [options.data]
 826       * @param {string} [options.mode="speed"] "precision" or "speed"
 827       * @param {string} [options.algorithm="sqrt"] "simple", "sqrt" or "dominant"
 828       * @param {number} [options.step=1]
 829       * @param {number} [options.left=0]
 830       * @param {number} [options.top=0]
 831       * @param {number} [options.width=width of resource]
 832       * @param {number} [options.height=height of resource]
 833       *
 834       * @returns {Object}
 835       */
 836  
 837    }, {
 838      key: "getColor",
 839      value: function getColor(resource, options) {
 840        options = options || {};
 841  
 842        var defaultColor = this._getDefaultColor(options),
 843            originalSize = this._getOriginalSize(resource),
 844            size = this._prepareSizeAndPosition(originalSize, options);
 845  
 846        var error = null,
 847            value = defaultColor;
 848  
 849        if (!size.srcWidth || !size.srcHeight || !size.destWidth || !size.destHeight) {
 850          return this._prepareResult(defaultColor, new Error('FastAverageColor: Incorrect sizes.'));
 851        }
 852  
 853        if (!this._ctx) {
 854          this._canvas = this._makeCanvas();
 855          this._ctx = this._canvas.getContext && this._canvas.getContext('2d');
 856  
 857          if (!this._ctx) {
 858            return this._prepareResult(defaultColor, new Error('FastAverageColor: Canvas Context 2D is not supported in this browser.'));
 859          }
 860        }
 861  
 862        this._canvas.width = size.destWidth;
 863        this._canvas.height = size.destHeight;
 864  
 865        try {
 866          this._ctx.clearRect(0, 0, size.destWidth, size.destHeight);
 867  
 868          this._ctx.drawImage(resource, size.srcLeft, size.srcTop, size.srcWidth, size.srcHeight, 0, 0, size.destWidth, size.destHeight);
 869  
 870          var bitmapData = this._ctx.getImageData(0, 0, size.destWidth, size.destHeight).data;
 871  
 872          value = this.getColorFromArray4(bitmapData, options);
 873        } catch (e) {
 874          // Security error, CORS
 875          // https://developer.mozilla.org/en/docs/Web/HTML/CORS_enabled_image
 876          error = e;
 877        }
 878  
 879        return this._prepareResult(value, error);
 880      }
 881      /**
 882       * Get the average color from a array when 1 pixel is 4 bytes.
 883       *
 884       * @param {Array|Uint8Array} arr
 885       * @param {Object} [options]
 886       * @param {string} [options.algorithm="sqrt"] "simple", "sqrt" or "dominant"
 887       * @param {Array}  [options.defaultColor=[255, 255, 255, 255]]
 888       * @param {number} [options.step=1]
 889       *
 890       * @returns {Array} [red (0-255), green (0-255), blue (0-255), alpha (0-255)]
 891       */
 892  
 893    }, {
 894      key: "getColorFromArray4",
 895      value: function getColorFromArray4(arr, options) {
 896        options = options || {};
 897        var bytesPerPixel = 4,
 898            arrLength = arr.length;
 899  
 900        if (arrLength < bytesPerPixel) {
 901          return this._getDefaultColor(options);
 902        }
 903  
 904        var len = arrLength - arrLength % bytesPerPixel,
 905            preparedStep = (options.step || 1) * bytesPerPixel,
 906            algorithm = '_' + (options.algorithm || 'sqrt') + 'Algorithm';
 907  
 908        if (typeof this[algorithm] !== 'function') {
 909          throw new Error("FastAverageColor: ".concat(options.algorithm, " is unknown algorithm."));
 910        }
 911  
 912        return this[algorithm](arr, len, preparedStep);
 913      }
 914      /**
 915       * Destroy the instance.
 916       */
 917  
 918    }, {
 919      key: "destroy",
 920      value: function destroy() {
 921        delete this._canvas;
 922        delete this._ctx;
 923      }
 924    }, {
 925      key: "_getDefaultColor",
 926      value: function _getDefaultColor(options) {
 927        return this._getOption(options, 'defaultColor', [255, 255, 255, 255]);
 928      }
 929    }, {
 930      key: "_getOption",
 931      value: function _getOption(options, name, defaultValue) {
 932        return typeof options[name] === 'undefined' ? defaultValue : options[name];
 933      }
 934    }, {
 935      key: "_prepareSizeAndPosition",
 936      value: function _prepareSizeAndPosition(originalSize, options) {
 937        var srcLeft = this._getOption(options, 'left', 0),
 938            srcTop = this._getOption(options, 'top', 0),
 939            srcWidth = this._getOption(options, 'width', originalSize.width),
 940            srcHeight = this._getOption(options, 'height', originalSize.height),
 941            destWidth = srcWidth,
 942            destHeight = srcHeight;
 943  
 944        if (options.mode === 'precision') {
 945          return {
 946            srcLeft: srcLeft,
 947            srcTop: srcTop,
 948            srcWidth: srcWidth,
 949            srcHeight: srcHeight,
 950            destWidth: destWidth,
 951            destHeight: destHeight
 952          };
 953        }
 954  
 955        var maxSize = 100,
 956            minSize = 10;
 957        var factor;
 958  
 959        if (srcWidth > srcHeight) {
 960          factor = srcWidth / srcHeight;
 961          destWidth = maxSize;
 962          destHeight = Math.round(destWidth / factor);
 963        } else {
 964          factor = srcHeight / srcWidth;
 965          destHeight = maxSize;
 966          destWidth = Math.round(destHeight / factor);
 967        }
 968  
 969        if (destWidth > srcWidth || destHeight > srcHeight || destWidth < minSize || destHeight < minSize) {
 970          destWidth = srcWidth;
 971          destHeight = srcHeight;
 972        }
 973  
 974        return {
 975          srcLeft: srcLeft,
 976          srcTop: srcTop,
 977          srcWidth: srcWidth,
 978          srcHeight: srcHeight,
 979          destWidth: destWidth,
 980          destHeight: destHeight
 981        };
 982      }
 983    }, {
 984      key: "_simpleAlgorithm",
 985      value: function _simpleAlgorithm(arr, len, preparedStep) {
 986        var redTotal = 0,
 987            greenTotal = 0,
 988            blueTotal = 0,
 989            alphaTotal = 0,
 990            count = 0;
 991  
 992        for (var i = 0; i < len; i += preparedStep) {
 993          var alpha = arr[i + 3],
 994              red = arr[i] * alpha,
 995              green = arr[i + 1] * alpha,
 996              blue = arr[i + 2] * alpha;
 997          redTotal += red;
 998          greenTotal += green;
 999          blueTotal += blue;
1000          alphaTotal += alpha;
1001          count++;
1002        }
1003  
1004        return alphaTotal ? [Math.round(redTotal / alphaTotal), Math.round(greenTotal / alphaTotal), Math.round(blueTotal / alphaTotal), Math.round(alphaTotal / count)] : [0, 0, 0, 0];
1005      }
1006    }, {
1007      key: "_sqrtAlgorithm",
1008      value: function _sqrtAlgorithm(arr, len, preparedStep) {
1009        var redTotal = 0,
1010            greenTotal = 0,
1011            blueTotal = 0,
1012            alphaTotal = 0,
1013            count = 0;
1014  
1015        for (var i = 0; i < len; i += preparedStep) {
1016          var red = arr[i],
1017              green = arr[i + 1],
1018              blue = arr[i + 2],
1019              alpha = arr[i + 3];
1020          redTotal += red * red * alpha;
1021          greenTotal += green * green * alpha;
1022          blueTotal += blue * blue * alpha;
1023          alphaTotal += alpha;
1024          count++;
1025        }
1026  
1027        return alphaTotal ? [Math.round(Math.sqrt(redTotal / alphaTotal)), Math.round(Math.sqrt(greenTotal / alphaTotal)), Math.round(Math.sqrt(blueTotal / alphaTotal)), Math.round(alphaTotal / count)] : [0, 0, 0, 0];
1028      }
1029    }, {
1030      key: "_dominantAlgorithm",
1031      value: function _dominantAlgorithm(arr, len, preparedStep) {
1032        var colorHash = {},
1033            divider = 24;
1034  
1035        for (var i = 0; i < len; i += preparedStep) {
1036          var red = arr[i],
1037              green = arr[i + 1],
1038              blue = arr[i + 2],
1039              alpha = arr[i + 3],
1040              key = Math.round(red / divider) + ',' + Math.round(green / divider) + ',' + Math.round(blue / divider);
1041  
1042          if (colorHash[key]) {
1043            colorHash[key] = [colorHash[key][0] + red * alpha, colorHash[key][1] + green * alpha, colorHash[key][2] + blue * alpha, colorHash[key][3] + alpha, colorHash[key][4] + 1];
1044          } else {
1045            colorHash[key] = [red * alpha, green * alpha, blue * alpha, alpha, 1];
1046          }
1047        }
1048  
1049        var buffer = Object.keys(colorHash).map(function (key) {
1050          return colorHash[key];
1051        }).sort(function (a, b) {
1052          var countA = a[4],
1053              countB = b[4];
1054          return countA > countB ? -1 : countA === countB ? 0 : 1;
1055        });
1056  
1057        var _buffer$ = _slicedToArray(buffer[0], 5),
1058            redTotal = _buffer$[0],
1059            greenTotal = _buffer$[1],
1060            blueTotal = _buffer$[2],
1061            alphaTotal = _buffer$[3],
1062            count = _buffer$[4];
1063  
1064        return alphaTotal ? [Math.round(redTotal / alphaTotal), Math.round(greenTotal / alphaTotal), Math.round(blueTotal / alphaTotal), Math.round(alphaTotal / count)] : [0, 0, 0, 0];
1065      }
1066    }, {
1067      key: "_bindImageEvents",
1068      value: function _bindImageEvents(resource, callback, options) {
1069        var _this = this;
1070  
1071        options = options || {};
1072  
1073        var data = options && options.data,
1074            defaultColor = this._getDefaultColor(options),
1075            onload = function onload() {
1076          unbindEvents();
1077          callback.call(resource, _this.getColor(resource, options), data);
1078        },
1079            onerror = function onerror() {
1080          unbindEvents();
1081          callback.call(resource, _this._prepareResult(defaultColor, new Error('Image error')), data);
1082        },
1083            onabort = function onabort() {
1084          unbindEvents();
1085          callback.call(resource, _this._prepareResult(defaultColor, new Error('Image abort')), data);
1086        },
1087            unbindEvents = function unbindEvents() {
1088          resource.removeEventListener('load', onload);
1089          resource.removeEventListener('error', onerror);
1090          resource.removeEventListener('abort', onabort);
1091        };
1092  
1093        resource.addEventListener('load', onload);
1094        resource.addEventListener('error', onerror);
1095        resource.addEventListener('abort', onabort);
1096      }
1097    }, {
1098      key: "_prepareResult",
1099      value: function _prepareResult(value, error) {
1100        var rgb = value.slice(0, 3),
1101            rgba = [].concat(rgb, value[3] / 255),
1102            isDark = this._isDark(value);
1103  
1104        return {
1105          error: error,
1106          value: value,
1107          rgb: 'rgb(' + rgb.join(',') + ')',
1108          rgba: 'rgba(' + rgba.join(',') + ')',
1109          hex: this._arrayToHex(rgb),
1110          hexa: this._arrayToHex(value),
1111          isDark: isDark,
1112          isLight: !isDark
1113        };
1114      }
1115    }, {
1116      key: "_getOriginalSize",
1117      value: function _getOriginalSize(resource) {
1118        if (resource instanceof HTMLImageElement) {
1119          return {
1120            width: resource.naturalWidth,
1121            height: resource.naturalHeight
1122          };
1123        }
1124  
1125        if (resource instanceof HTMLVideoElement) {
1126          return {
1127            width: resource.videoWidth,
1128            height: resource.videoHeight
1129          };
1130        }
1131  
1132        return {
1133          width: resource.width,
1134          height: resource.height
1135        };
1136      }
1137    }, {
1138      key: "_toHex",
1139      value: function _toHex(num) {
1140        var str = num.toString(16);
1141        return str.length === 1 ? '0' + str : str;
1142      }
1143    }, {
1144      key: "_arrayToHex",
1145      value: function _arrayToHex(arr) {
1146        return '#' + arr.map(this._toHex).join('');
1147      }
1148    }, {
1149      key: "_isDark",
1150      value: function _isDark(color) {
1151        // http://www.w3.org/TR/AERT#color-contrast
1152        var result = (color[0] * 299 + color[1] * 587 + color[2] * 114) / 1000;
1153        return result < 128;
1154      }
1155    }, {
1156      key: "_makeCanvas",
1157      value: function _makeCanvas() {
1158        return typeof window === 'undefined' ? new OffscreenCanvas(1, 1) : document.createElement('canvas');
1159      }
1160    }]);
1161  
1162    return FastAverageColor;
1163  }();
1164  
1165  return FastAverageColor;
1166  
1167  })));
1168  
1169  
1170  /***/ }),
1171  
1172  /***/ "FqII":
1173  /***/ (function(module, exports) {
1174  
1175  (function() { module.exports = window["wp"]["date"]; }());
1176  
1177  /***/ }),
1178  
1179  /***/ "GRId":
1180  /***/ (function(module, exports) {
1181  
1182  (function() { module.exports = window["wp"]["element"]; }());
1183  
1184  /***/ }),
1185  
1186  /***/ "HSyU":
1187  /***/ (function(module, exports) {
1188  
1189  (function() { module.exports = window["wp"]["blocks"]; }());
1190  
1191  /***/ }),
1192  
1193  /***/ "JREk":
1194  /***/ (function(module, exports) {
1195  
1196  (function() { module.exports = window["wp"]["serverSideRender"]; }());
1197  
1198  /***/ }),
1199  
1200  /***/ "K51g":
1201  /***/ (function(module, __webpack_exports__, __webpack_require__) {
1202  
1203  "use strict";
1204  // ESM COMPAT FLAG
1205  __webpack_require__.r(__webpack_exports__);
1206  
1207  // EXPORTS
1208  __webpack_require__.d(__webpack_exports__, "__experimentalGetCoreBlocks", function() { return /* binding */ __experimentalGetCoreBlocks; });
1209  __webpack_require__.d(__webpack_exports__, "registerCoreBlocks", function() { return /* binding */ registerCoreBlocks; });
1210  __webpack_require__.d(__webpack_exports__, "__experimentalRegisterExperimentalCoreBlocks", function() { return /* binding */ __experimentalRegisterExperimentalCoreBlocks; });
1211  
1212  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/paragraph/index.js
1213  var build_module_paragraph_namespaceObject = {};
1214  __webpack_require__.r(build_module_paragraph_namespaceObject);
1215  __webpack_require__.d(build_module_paragraph_namespaceObject, "metadata", function() { return paragraph_metadata; });
1216  __webpack_require__.d(build_module_paragraph_namespaceObject, "name", function() { return paragraph_name; });
1217  __webpack_require__.d(build_module_paragraph_namespaceObject, "settings", function() { return paragraph_settings; });
1218  
1219  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/image/index.js
1220  var build_module_image_namespaceObject = {};
1221  __webpack_require__.r(build_module_image_namespaceObject);
1222  __webpack_require__.d(build_module_image_namespaceObject, "metadata", function() { return image_metadata; });
1223  __webpack_require__.d(build_module_image_namespaceObject, "name", function() { return image_name; });
1224  __webpack_require__.d(build_module_image_namespaceObject, "settings", function() { return image_settings; });
1225  
1226  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/heading/index.js
1227  var build_module_heading_namespaceObject = {};
1228  __webpack_require__.r(build_module_heading_namespaceObject);
1229  __webpack_require__.d(build_module_heading_namespaceObject, "metadata", function() { return heading_metadata; });
1230  __webpack_require__.d(build_module_heading_namespaceObject, "name", function() { return heading_name; });
1231  __webpack_require__.d(build_module_heading_namespaceObject, "settings", function() { return heading_settings; });
1232  
1233  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/quote/index.js
1234  var build_module_quote_namespaceObject = {};
1235  __webpack_require__.r(build_module_quote_namespaceObject);
1236  __webpack_require__.d(build_module_quote_namespaceObject, "metadata", function() { return quote_metadata; });
1237  __webpack_require__.d(build_module_quote_namespaceObject, "name", function() { return quote_name; });
1238  __webpack_require__.d(build_module_quote_namespaceObject, "settings", function() { return quote_settings; });
1239  
1240  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/gallery/index.js
1241  var build_module_gallery_namespaceObject = {};
1242  __webpack_require__.r(build_module_gallery_namespaceObject);
1243  __webpack_require__.d(build_module_gallery_namespaceObject, "metadata", function() { return gallery_metadata; });
1244  __webpack_require__.d(build_module_gallery_namespaceObject, "name", function() { return gallery_name; });
1245  __webpack_require__.d(build_module_gallery_namespaceObject, "settings", function() { return gallery_settings; });
1246  
1247  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/archives/index.js
1248  var archives_namespaceObject = {};
1249  __webpack_require__.r(archives_namespaceObject);
1250  __webpack_require__.d(archives_namespaceObject, "metadata", function() { return archives_metadata; });
1251  __webpack_require__.d(archives_namespaceObject, "name", function() { return archives_name; });
1252  __webpack_require__.d(archives_namespaceObject, "settings", function() { return archives_settings; });
1253  
1254  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/audio/index.js
1255  var build_module_audio_namespaceObject = {};
1256  __webpack_require__.r(build_module_audio_namespaceObject);
1257  __webpack_require__.d(build_module_audio_namespaceObject, "metadata", function() { return audio_metadata; });
1258  __webpack_require__.d(build_module_audio_namespaceObject, "name", function() { return audio_name; });
1259  __webpack_require__.d(build_module_audio_namespaceObject, "settings", function() { return audio_settings; });
1260  
1261  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/button/index.js
1262  var button_namespaceObject = {};
1263  __webpack_require__.r(button_namespaceObject);
1264  __webpack_require__.d(button_namespaceObject, "metadata", function() { return button_metadata; });
1265  __webpack_require__.d(button_namespaceObject, "name", function() { return button_name; });
1266  __webpack_require__.d(button_namespaceObject, "settings", function() { return button_settings; });
1267  
1268  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/buttons/index.js
1269  var build_module_buttons_namespaceObject = {};
1270  __webpack_require__.r(build_module_buttons_namespaceObject);
1271  __webpack_require__.d(build_module_buttons_namespaceObject, "metadata", function() { return buttons_metadata; });
1272  __webpack_require__.d(build_module_buttons_namespaceObject, "name", function() { return buttons_name; });
1273  __webpack_require__.d(build_module_buttons_namespaceObject, "settings", function() { return buttons_settings; });
1274  
1275  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/calendar/index.js
1276  var build_module_calendar_namespaceObject = {};
1277  __webpack_require__.r(build_module_calendar_namespaceObject);
1278  __webpack_require__.d(build_module_calendar_namespaceObject, "metadata", function() { return calendar_metadata; });
1279  __webpack_require__.d(build_module_calendar_namespaceObject, "name", function() { return calendar_name; });
1280  __webpack_require__.d(build_module_calendar_namespaceObject, "settings", function() { return calendar_settings; });
1281  
1282  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/categories/index.js
1283  var categories_namespaceObject = {};
1284  __webpack_require__.r(categories_namespaceObject);
1285  __webpack_require__.d(categories_namespaceObject, "metadata", function() { return categories_metadata; });
1286  __webpack_require__.d(categories_namespaceObject, "name", function() { return categories_name; });
1287  __webpack_require__.d(categories_namespaceObject, "settings", function() { return categories_settings; });
1288  
1289  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/code/index.js
1290  var code_namespaceObject = {};
1291  __webpack_require__.r(code_namespaceObject);
1292  __webpack_require__.d(code_namespaceObject, "metadata", function() { return code_metadata; });
1293  __webpack_require__.d(code_namespaceObject, "name", function() { return code_name; });
1294  __webpack_require__.d(code_namespaceObject, "settings", function() { return code_settings; });
1295  
1296  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/columns/index.js
1297  var build_module_columns_namespaceObject = {};
1298  __webpack_require__.r(build_module_columns_namespaceObject);
1299  __webpack_require__.d(build_module_columns_namespaceObject, "metadata", function() { return columns_metadata; });
1300  __webpack_require__.d(build_module_columns_namespaceObject, "name", function() { return columns_name; });
1301  __webpack_require__.d(build_module_columns_namespaceObject, "settings", function() { return columns_settings; });
1302  
1303  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/column/index.js
1304  var build_module_column_namespaceObject = {};
1305  __webpack_require__.r(build_module_column_namespaceObject);
1306  __webpack_require__.d(build_module_column_namespaceObject, "metadata", function() { return column_metadata; });
1307  __webpack_require__.d(build_module_column_namespaceObject, "name", function() { return column_name; });
1308  __webpack_require__.d(build_module_column_namespaceObject, "settings", function() { return column_settings; });
1309  
1310  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/cover/index.js
1311  var build_module_cover_namespaceObject = {};
1312  __webpack_require__.r(build_module_cover_namespaceObject);
1313  __webpack_require__.d(build_module_cover_namespaceObject, "metadata", function() { return cover_metadata; });
1314  __webpack_require__.d(build_module_cover_namespaceObject, "name", function() { return cover_name; });
1315  __webpack_require__.d(build_module_cover_namespaceObject, "settings", function() { return cover_settings; });
1316  
1317  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/embed/index.js
1318  var embed_namespaceObject = {};
1319  __webpack_require__.r(embed_namespaceObject);
1320  __webpack_require__.d(embed_namespaceObject, "metadata", function() { return embed_metadata; });
1321  __webpack_require__.d(embed_namespaceObject, "name", function() { return embed_name; });
1322  __webpack_require__.d(embed_namespaceObject, "settings", function() { return embed_settings; });
1323  
1324  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/file/index.js
1325  var build_module_file_namespaceObject = {};
1326  __webpack_require__.r(build_module_file_namespaceObject);
1327  __webpack_require__.d(build_module_file_namespaceObject, "metadata", function() { return file_metadata; });
1328  __webpack_require__.d(build_module_file_namespaceObject, "name", function() { return file_name; });
1329  __webpack_require__.d(build_module_file_namespaceObject, "settings", function() { return file_settings; });
1330  
1331  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/html/index.js
1332  var build_module_html_namespaceObject = {};
1333  __webpack_require__.r(build_module_html_namespaceObject);
1334  __webpack_require__.d(build_module_html_namespaceObject, "metadata", function() { return html_metadata; });
1335  __webpack_require__.d(build_module_html_namespaceObject, "name", function() { return html_name; });
1336  __webpack_require__.d(build_module_html_namespaceObject, "settings", function() { return html_settings; });
1337  
1338  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/media-text/index.js
1339  var media_text_namespaceObject = {};
1340  __webpack_require__.r(media_text_namespaceObject);
1341  __webpack_require__.d(media_text_namespaceObject, "metadata", function() { return media_text_metadata; });
1342  __webpack_require__.d(media_text_namespaceObject, "name", function() { return media_text_name; });
1343  __webpack_require__.d(media_text_namespaceObject, "settings", function() { return media_text_settings; });
1344  
1345  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/latest-comments/index.js
1346  var latest_comments_namespaceObject = {};
1347  __webpack_require__.r(latest_comments_namespaceObject);
1348  __webpack_require__.d(latest_comments_namespaceObject, "metadata", function() { return latest_comments_metadata; });
1349  __webpack_require__.d(latest_comments_namespaceObject, "name", function() { return latest_comments_name; });
1350  __webpack_require__.d(latest_comments_namespaceObject, "settings", function() { return latest_comments_settings; });
1351  
1352  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/latest-posts/index.js
1353  var latest_posts_namespaceObject = {};
1354  __webpack_require__.r(latest_posts_namespaceObject);
1355  __webpack_require__.d(latest_posts_namespaceObject, "metadata", function() { return latest_posts_metadata; });
1356  __webpack_require__.d(latest_posts_namespaceObject, "name", function() { return latest_posts_name; });
1357  __webpack_require__.d(latest_posts_namespaceObject, "settings", function() { return latest_posts_settings; });
1358  
1359  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/loginout/index.js
1360  var loginout_namespaceObject = {};
1361  __webpack_require__.r(loginout_namespaceObject);
1362  __webpack_require__.d(loginout_namespaceObject, "metadata", function() { return loginout_metadata; });
1363  __webpack_require__.d(loginout_namespaceObject, "name", function() { return loginout_name; });
1364  __webpack_require__.d(loginout_namespaceObject, "settings", function() { return loginout_settings; });
1365  
1366  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/list/index.js
1367  var build_module_list_namespaceObject = {};
1368  __webpack_require__.r(build_module_list_namespaceObject);
1369  __webpack_require__.d(build_module_list_namespaceObject, "metadata", function() { return list_metadata; });
1370  __webpack_require__.d(build_module_list_namespaceObject, "name", function() { return list_name; });
1371  __webpack_require__.d(build_module_list_namespaceObject, "settings", function() { return list_settings; });
1372  
1373  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/missing/index.js
1374  var missing_namespaceObject = {};
1375  __webpack_require__.r(missing_namespaceObject);
1376  __webpack_require__.d(missing_namespaceObject, "metadata", function() { return missing_metadata; });
1377  __webpack_require__.d(missing_namespaceObject, "name", function() { return missing_name; });
1378  __webpack_require__.d(missing_namespaceObject, "settings", function() { return missing_settings; });
1379  
1380  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/more/index.js
1381  var build_module_more_namespaceObject = {};
1382  __webpack_require__.r(build_module_more_namespaceObject);
1383  __webpack_require__.d(build_module_more_namespaceObject, "metadata", function() { return more_metadata; });
1384  __webpack_require__.d(build_module_more_namespaceObject, "name", function() { return more_name; });
1385  __webpack_require__.d(build_module_more_namespaceObject, "settings", function() { return more_settings; });
1386  
1387  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/nextpage/index.js
1388  var nextpage_namespaceObject = {};
1389  __webpack_require__.r(nextpage_namespaceObject);
1390  __webpack_require__.d(nextpage_namespaceObject, "metadata", function() { return nextpage_metadata; });
1391  __webpack_require__.d(nextpage_namespaceObject, "name", function() { return nextpage_name; });
1392  __webpack_require__.d(nextpage_namespaceObject, "settings", function() { return nextpage_settings; });
1393  
1394  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/page-list/index.js
1395  var page_list_namespaceObject = {};
1396  __webpack_require__.r(page_list_namespaceObject);
1397  __webpack_require__.d(page_list_namespaceObject, "metadata", function() { return page_list_metadata; });
1398  __webpack_require__.d(page_list_namespaceObject, "name", function() { return page_list_name; });
1399  __webpack_require__.d(page_list_namespaceObject, "settings", function() { return page_list_settings; });
1400  
1401  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/preformatted/index.js
1402  var build_module_preformatted_namespaceObject = {};
1403  __webpack_require__.r(build_module_preformatted_namespaceObject);
1404  __webpack_require__.d(build_module_preformatted_namespaceObject, "metadata", function() { return preformatted_metadata; });
1405  __webpack_require__.d(build_module_preformatted_namespaceObject, "name", function() { return preformatted_name; });
1406  __webpack_require__.d(build_module_preformatted_namespaceObject, "settings", function() { return preformatted_settings; });
1407  
1408  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/pullquote/index.js
1409  var build_module_pullquote_namespaceObject = {};
1410  __webpack_require__.r(build_module_pullquote_namespaceObject);
1411  __webpack_require__.d(build_module_pullquote_namespaceObject, "metadata", function() { return pullquote_metadata; });
1412  __webpack_require__.d(build_module_pullquote_namespaceObject, "name", function() { return pullquote_name; });
1413  __webpack_require__.d(build_module_pullquote_namespaceObject, "settings", function() { return pullquote_settings; });
1414  
1415  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/block/index.js
1416  var block_namespaceObject = {};
1417  __webpack_require__.r(block_namespaceObject);
1418  __webpack_require__.d(block_namespaceObject, "metadata", function() { return block_metadata; });
1419  __webpack_require__.d(block_namespaceObject, "name", function() { return block_name; });
1420  __webpack_require__.d(block_namespaceObject, "settings", function() { return block_settings; });
1421  
1422  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/rss/index.js
1423  var build_module_rss_namespaceObject = {};
1424  __webpack_require__.r(build_module_rss_namespaceObject);
1425  __webpack_require__.d(build_module_rss_namespaceObject, "metadata", function() { return rss_metadata; });
1426  __webpack_require__.d(build_module_rss_namespaceObject, "name", function() { return rss_name; });
1427  __webpack_require__.d(build_module_rss_namespaceObject, "settings", function() { return rss_settings; });
1428  
1429  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/search/index.js
1430  var search_namespaceObject = {};
1431  __webpack_require__.r(search_namespaceObject);
1432  __webpack_require__.d(search_namespaceObject, "metadata", function() { return search_metadata; });
1433  __webpack_require__.d(search_namespaceObject, "name", function() { return search_name; });
1434  __webpack_require__.d(search_namespaceObject, "settings", function() { return search_settings; });
1435  
1436  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/group/index.js
1437  var build_module_group_namespaceObject = {};
1438  __webpack_require__.r(build_module_group_namespaceObject);
1439  __webpack_require__.d(build_module_group_namespaceObject, "metadata", function() { return group_metadata; });
1440  __webpack_require__.d(build_module_group_namespaceObject, "name", function() { return group_name; });
1441  __webpack_require__.d(build_module_group_namespaceObject, "settings", function() { return group_settings; });
1442  
1443  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/separator/index.js
1444  var build_module_separator_namespaceObject = {};
1445  __webpack_require__.r(build_module_separator_namespaceObject);
1446  __webpack_require__.d(build_module_separator_namespaceObject, "metadata", function() { return separator_metadata; });
1447  __webpack_require__.d(build_module_separator_namespaceObject, "name", function() { return separator_name; });
1448  __webpack_require__.d(build_module_separator_namespaceObject, "settings", function() { return build_module_separator_settings; });
1449  
1450  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/shortcode/index.js
1451  var build_module_shortcode_namespaceObject = {};
1452  __webpack_require__.r(build_module_shortcode_namespaceObject);
1453  __webpack_require__.d(build_module_shortcode_namespaceObject, "metadata", function() { return shortcode_metadata; });
1454  __webpack_require__.d(build_module_shortcode_namespaceObject, "name", function() { return shortcode_name; });
1455  __webpack_require__.d(build_module_shortcode_namespaceObject, "settings", function() { return shortcode_settings; });
1456  
1457  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/spacer/index.js
1458  var spacer_namespaceObject = {};
1459  __webpack_require__.r(spacer_namespaceObject);
1460  __webpack_require__.d(spacer_namespaceObject, "metadata", function() { return spacer_metadata; });
1461  __webpack_require__.d(spacer_namespaceObject, "name", function() { return spacer_name; });
1462  __webpack_require__.d(spacer_namespaceObject, "settings", function() { return spacer_settings; });
1463  
1464  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/table/index.js
1465  var build_module_table_namespaceObject = {};
1466  __webpack_require__.r(build_module_table_namespaceObject);
1467  __webpack_require__.d(build_module_table_namespaceObject, "metadata", function() { return table_metadata; });
1468  __webpack_require__.d(build_module_table_namespaceObject, "name", function() { return table_name; });
1469  __webpack_require__.d(build_module_table_namespaceObject, "settings", function() { return table_settings; });
1470  
1471  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/text-columns/index.js
1472  var text_columns_namespaceObject = {};
1473  __webpack_require__.r(text_columns_namespaceObject);
1474  __webpack_require__.d(text_columns_namespaceObject, "metadata", function() { return text_columns_metadata; });
1475  __webpack_require__.d(text_columns_namespaceObject, "name", function() { return text_columns_name; });
1476  __webpack_require__.d(text_columns_namespaceObject, "settings", function() { return text_columns_settings; });
1477  
1478  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/verse/index.js
1479  var build_module_verse_namespaceObject = {};
1480  __webpack_require__.r(build_module_verse_namespaceObject);
1481  __webpack_require__.d(build_module_verse_namespaceObject, "metadata", function() { return verse_metadata; });
1482  __webpack_require__.d(build_module_verse_namespaceObject, "name", function() { return verse_name; });
1483  __webpack_require__.d(build_module_verse_namespaceObject, "settings", function() { return verse_settings; });
1484  
1485  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/video/index.js
1486  var build_module_video_namespaceObject = {};
1487  __webpack_require__.r(build_module_video_namespaceObject);
1488  __webpack_require__.d(build_module_video_namespaceObject, "metadata", function() { return video_metadata; });
1489  __webpack_require__.d(build_module_video_namespaceObject, "name", function() { return video_name; });
1490  __webpack_require__.d(build_module_video_namespaceObject, "settings", function() { return video_settings; });
1491  
1492  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/tag-cloud/index.js
1493  var tag_cloud_namespaceObject = {};
1494  __webpack_require__.r(tag_cloud_namespaceObject);
1495  __webpack_require__.d(tag_cloud_namespaceObject, "metadata", function() { return tag_cloud_metadata; });
1496  __webpack_require__.d(tag_cloud_namespaceObject, "name", function() { return tag_cloud_name; });
1497  __webpack_require__.d(tag_cloud_namespaceObject, "settings", function() { return tag_cloud_settings; });
1498  
1499  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/freeform/index.js
1500  var freeform_namespaceObject = {};
1501  __webpack_require__.r(freeform_namespaceObject);
1502  __webpack_require__.d(freeform_namespaceObject, "metadata", function() { return freeform_metadata; });
1503  __webpack_require__.d(freeform_namespaceObject, "name", function() { return freeform_name; });
1504  __webpack_require__.d(freeform_namespaceObject, "settings", function() { return freeform_settings; });
1505  
1506  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/social-links/index.js
1507  var social_links_namespaceObject = {};
1508  __webpack_require__.r(social_links_namespaceObject);
1509  __webpack_require__.d(social_links_namespaceObject, "metadata", function() { return social_links_metadata; });
1510  __webpack_require__.d(social_links_namespaceObject, "name", function() { return social_links_name; });
1511  __webpack_require__.d(social_links_namespaceObject, "settings", function() { return social_links_settings; });
1512  
1513  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/social-link/index.js
1514  var social_link_namespaceObject = {};
1515  __webpack_require__.r(social_link_namespaceObject);
1516  __webpack_require__.d(social_link_namespaceObject, "metadata", function() { return social_link_metadata; });
1517  __webpack_require__.d(social_link_namespaceObject, "name", function() { return social_link_name; });
1518  __webpack_require__.d(social_link_namespaceObject, "settings", function() { return social_link_settings; });
1519  
1520  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/site-logo/index.js
1521  var build_module_site_logo_namespaceObject = {};
1522  __webpack_require__.r(build_module_site_logo_namespaceObject);
1523  __webpack_require__.d(build_module_site_logo_namespaceObject, "metadata", function() { return site_logo_metadata; });
1524  __webpack_require__.d(build_module_site_logo_namespaceObject, "name", function() { return site_logo_name; });
1525  __webpack_require__.d(build_module_site_logo_namespaceObject, "settings", function() { return site_logo_settings; });
1526  
1527  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/site-tagline/index.js
1528  var site_tagline_namespaceObject = {};
1529  __webpack_require__.r(site_tagline_namespaceObject);
1530  __webpack_require__.d(site_tagline_namespaceObject, "metadata", function() { return site_tagline_metadata; });
1531  __webpack_require__.d(site_tagline_namespaceObject, "name", function() { return site_tagline_name; });
1532  __webpack_require__.d(site_tagline_namespaceObject, "settings", function() { return site_tagline_settings; });
1533  
1534  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/site-title/index.js
1535  var site_title_namespaceObject = {};
1536  __webpack_require__.r(site_title_namespaceObject);
1537  __webpack_require__.d(site_title_namespaceObject, "metadata", function() { return site_title_metadata; });
1538  __webpack_require__.d(site_title_namespaceObject, "name", function() { return site_title_name; });
1539  __webpack_require__.d(site_title_namespaceObject, "settings", function() { return site_title_settings; });
1540  
1541  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/query/index.js
1542  var query_namespaceObject = {};
1543  __webpack_require__.r(query_namespaceObject);
1544  __webpack_require__.d(query_namespaceObject, "metadata", function() { return query_metadata; });
1545  __webpack_require__.d(query_namespaceObject, "name", function() { return query_name; });
1546  __webpack_require__.d(query_namespaceObject, "settings", function() { return query_settings; });
1547  
1548  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/post-template/index.js
1549  var post_template_namespaceObject = {};
1550  __webpack_require__.r(post_template_namespaceObject);
1551  __webpack_require__.d(post_template_namespaceObject, "metadata", function() { return post_template_metadata; });
1552  __webpack_require__.d(post_template_namespaceObject, "name", function() { return post_template_name; });
1553  __webpack_require__.d(post_template_namespaceObject, "settings", function() { return post_template_settings; });
1554  
1555  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/query-title/index.js
1556  var query_title_namespaceObject = {};
1557  __webpack_require__.r(query_title_namespaceObject);
1558  __webpack_require__.d(query_title_namespaceObject, "metadata", function() { return query_title_metadata; });
1559  __webpack_require__.d(query_title_namespaceObject, "name", function() { return query_title_name; });
1560  __webpack_require__.d(query_title_namespaceObject, "settings", function() { return query_title_settings; });
1561  
1562  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/query-pagination/index.js
1563  var build_module_query_pagination_namespaceObject = {};
1564  __webpack_require__.r(build_module_query_pagination_namespaceObject);
1565  __webpack_require__.d(build_module_query_pagination_namespaceObject, "metadata", function() { return query_pagination_metadata; });
1566  __webpack_require__.d(build_module_query_pagination_namespaceObject, "name", function() { return query_pagination_name; });
1567  __webpack_require__.d(build_module_query_pagination_namespaceObject, "settings", function() { return query_pagination_settings; });
1568  
1569  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/query-pagination-next/index.js
1570  var build_module_query_pagination_next_namespaceObject = {};
1571  __webpack_require__.r(build_module_query_pagination_next_namespaceObject);
1572  __webpack_require__.d(build_module_query_pagination_next_namespaceObject, "metadata", function() { return query_pagination_next_metadata; });
1573  __webpack_require__.d(build_module_query_pagination_next_namespaceObject, "name", function() { return query_pagination_next_name; });
1574  __webpack_require__.d(build_module_query_pagination_next_namespaceObject, "settings", function() { return query_pagination_next_settings; });
1575  
1576  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/query-pagination-numbers/index.js
1577  var build_module_query_pagination_numbers_namespaceObject = {};
1578  __webpack_require__.r(build_module_query_pagination_numbers_namespaceObject);
1579  __webpack_require__.d(build_module_query_pagination_numbers_namespaceObject, "metadata", function() { return query_pagination_numbers_metadata; });
1580  __webpack_require__.d(build_module_query_pagination_numbers_namespaceObject, "name", function() { return query_pagination_numbers_name; });
1581  __webpack_require__.d(build_module_query_pagination_numbers_namespaceObject, "settings", function() { return query_pagination_numbers_settings; });
1582  
1583  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/query-pagination-previous/index.js
1584  var build_module_query_pagination_previous_namespaceObject = {};
1585  __webpack_require__.r(build_module_query_pagination_previous_namespaceObject);
1586  __webpack_require__.d(build_module_query_pagination_previous_namespaceObject, "metadata", function() { return query_pagination_previous_metadata; });
1587  __webpack_require__.d(build_module_query_pagination_previous_namespaceObject, "name", function() { return query_pagination_previous_name; });
1588  __webpack_require__.d(build_module_query_pagination_previous_namespaceObject, "settings", function() { return query_pagination_previous_settings; });
1589  
1590  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/post-title/index.js
1591  var build_module_post_title_namespaceObject = {};
1592  __webpack_require__.r(build_module_post_title_namespaceObject);
1593  __webpack_require__.d(build_module_post_title_namespaceObject, "metadata", function() { return post_title_metadata; });
1594  __webpack_require__.d(build_module_post_title_namespaceObject, "name", function() { return post_title_name; });
1595  __webpack_require__.d(build_module_post_title_namespaceObject, "settings", function() { return post_title_settings; });
1596  
1597  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/post-content/index.js
1598  var build_module_post_content_namespaceObject = {};
1599  __webpack_require__.r(build_module_post_content_namespaceObject);
1600  __webpack_require__.d(build_module_post_content_namespaceObject, "metadata", function() { return post_content_metadata; });
1601  __webpack_require__.d(build_module_post_content_namespaceObject, "name", function() { return post_content_name; });
1602  __webpack_require__.d(build_module_post_content_namespaceObject, "settings", function() { return post_content_settings; });
1603  
1604  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/post-date/index.js
1605  var build_module_post_date_namespaceObject = {};
1606  __webpack_require__.r(build_module_post_date_namespaceObject);
1607  __webpack_require__.d(build_module_post_date_namespaceObject, "metadata", function() { return post_date_metadata; });
1608  __webpack_require__.d(build_module_post_date_namespaceObject, "name", function() { return post_date_name; });
1609  __webpack_require__.d(build_module_post_date_namespaceObject, "settings", function() { return post_date_settings; });
1610  
1611  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/post-excerpt/index.js
1612  var build_module_post_excerpt_namespaceObject = {};
1613  __webpack_require__.r(build_module_post_excerpt_namespaceObject);
1614  __webpack_require__.d(build_module_post_excerpt_namespaceObject, "metadata", function() { return post_excerpt_metadata; });
1615  __webpack_require__.d(build_module_post_excerpt_namespaceObject, "name", function() { return post_excerpt_name; });
1616  __webpack_require__.d(build_module_post_excerpt_namespaceObject, "settings", function() { return post_excerpt_settings; });
1617  
1618  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/post-featured-image/index.js
1619  var build_module_post_featured_image_namespaceObject = {};
1620  __webpack_require__.r(build_module_post_featured_image_namespaceObject);
1621  __webpack_require__.d(build_module_post_featured_image_namespaceObject, "metadata", function() { return post_featured_image_metadata; });
1622  __webpack_require__.d(build_module_post_featured_image_namespaceObject, "name", function() { return post_featured_image_name; });
1623  __webpack_require__.d(build_module_post_featured_image_namespaceObject, "settings", function() { return post_featured_image_settings; });
1624  
1625  // NAMESPACE OBJECT: ./node_modules/@wordpress/block-library/build-module/post-terms/index.js
1626  var post_terms_namespaceObject = {};
1627  __webpack_require__.r(post_terms_namespaceObject);
1628  __webpack_require__.d(post_terms_namespaceObject, "metadata", function() { return post_terms_metadata; });
1629  __webpack_require__.d(post_terms_namespaceObject, "name", function() { return post_terms_name; });
1630  __webpack_require__.d(post_terms_namespaceObject, "settings", function() { return post_terms_settings; });
1631  
1632  // EXTERNAL MODULE: external ["wp","coreData"]
1633  var external_wp_coreData_ = __webpack_require__("jZUy");
1634  
1635  // EXTERNAL MODULE: external ["wp","blockEditor"]
1636  var external_wp_blockEditor_ = __webpack_require__("axFQ");
1637  
1638  // EXTERNAL MODULE: external ["wp","blocks"]
1639  var external_wp_blocks_ = __webpack_require__("HSyU");
1640  
1641  // EXTERNAL MODULE: external "lodash"
1642  var external_lodash_ = __webpack_require__("YLtl");
1643  
1644  // EXTERNAL MODULE: external ["wp","i18n"]
1645  var external_wp_i18n_ = __webpack_require__("l3Sj");
1646  
1647  // EXTERNAL MODULE: external ["wp","element"]
1648  var external_wp_element_ = __webpack_require__("GRId");
1649  
1650  // EXTERNAL MODULE: external ["wp","primitives"]
1651  var external_wp_primitives_ = __webpack_require__("Tqx9");
1652  
1653  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/paragraph.js
1654  
1655  
1656  /**
1657   * WordPress dependencies
1658   */
1659  
1660  const paragraph = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
1661    xmlns: "http://www.w3.org/2000/svg",
1662    viewBox: "0 0 24 24"
1663  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
1664    d: "M18.3 4H9.9v-.1l-.9.2c-2.3.4-4 2.4-4 4.8s1.7 4.4 4 4.8l.7.1V20h1.5V5.5h2.9V20h1.5V5.5h2.7V4z"
1665  }));
1666  /* harmony default export */ var library_paragraph = (paragraph);
1667  
1668  // EXTERNAL MODULE: ./node_modules/classnames/index.js
1669  var classnames = __webpack_require__("TSYQ");
1670  var classnames_default = /*#__PURE__*/__webpack_require__.n(classnames);
1671  
1672  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/paragraph/deprecated.js
1673  
1674  
1675  /**
1676   * External dependencies
1677   */
1678  
1679  
1680  /**
1681   * WordPress dependencies
1682   */
1683  
1684  
1685  
1686  const supports = {
1687    className: false
1688  };
1689  const deprecated_blockAttributes = {
1690    align: {
1691      type: 'string'
1692    },
1693    content: {
1694      type: 'string',
1695      source: 'html',
1696      selector: 'p',
1697      default: ''
1698    },
1699    dropCap: {
1700      type: 'boolean',
1701      default: false
1702    },
1703    placeholder: {
1704      type: 'string'
1705    },
1706    textColor: {
1707      type: 'string'
1708    },
1709    backgroundColor: {
1710      type: 'string'
1711    },
1712    fontSize: {
1713      type: 'string'
1714    },
1715    direction: {
1716      type: 'string',
1717      enum: ['ltr', 'rtl']
1718    },
1719    style: {
1720      type: 'object'
1721    }
1722  };
1723  
1724  const migrateCustomColorsAndFontSizes = attributes => {
1725    if (!attributes.customTextColor && !attributes.customBackgroundColor && !attributes.customFontSize) {
1726      return attributes;
1727    }
1728  
1729    const style = {};
1730  
1731    if (attributes.customTextColor || attributes.customBackgroundColor) {
1732      style.color = {};
1733    }
1734  
1735    if (attributes.customTextColor) {
1736      style.color.text = attributes.customTextColor;
1737    }
1738  
1739    if (attributes.customBackgroundColor) {
1740      style.color.background = attributes.customBackgroundColor;
1741    }
1742  
1743    if (attributes.customFontSize) {
1744      style.typography = {
1745        fontSize: attributes.customFontSize
1746      };
1747    }
1748  
1749    return { ...Object(external_lodash_["omit"])(attributes, ['customTextColor', 'customBackgroundColor', 'customFontSize']),
1750      style
1751    };
1752  };
1753  
1754  const deprecated = [{
1755    supports,
1756    attributes: { ...Object(external_lodash_["omit"])(deprecated_blockAttributes, ['style']),
1757      customTextColor: {
1758        type: 'string'
1759      },
1760      customBackgroundColor: {
1761        type: 'string'
1762      },
1763      customFontSize: {
1764        type: 'number'
1765      }
1766    },
1767    migrate: migrateCustomColorsAndFontSizes,
1768  
1769    save({
1770      attributes
1771    }) {
1772      const {
1773        align,
1774        content,
1775        dropCap,
1776        backgroundColor,
1777        textColor,
1778        customBackgroundColor,
1779        customTextColor,
1780        fontSize,
1781        customFontSize,
1782        direction
1783      } = attributes;
1784      const textClass = Object(external_wp_blockEditor_["getColorClassName"])('color', textColor);
1785      const backgroundClass = Object(external_wp_blockEditor_["getColorClassName"])('background-color', backgroundColor);
1786      const fontSizeClass = Object(external_wp_blockEditor_["getFontSizeClass"])(fontSize);
1787      const className = classnames_default()({
1788        'has-text-color': textColor || customTextColor,
1789        'has-background': backgroundColor || customBackgroundColor,
1790        'has-drop-cap': dropCap,
1791        [`has-text-align-$align}`]: align,
1792        [fontSizeClass]: fontSizeClass,
1793        [textClass]: textClass,
1794        [backgroundClass]: backgroundClass
1795      });
1796      const styles = {
1797        backgroundColor: backgroundClass ? undefined : customBackgroundColor,
1798        color: textClass ? undefined : customTextColor,
1799        fontSize: fontSizeClass ? undefined : customFontSize
1800      };
1801      return Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
1802        tagName: "p",
1803        style: styles,
1804        className: className ? className : undefined,
1805        value: content,
1806        dir: direction
1807      });
1808    }
1809  
1810  }, {
1811    supports,
1812    attributes: { ...Object(external_lodash_["omit"])(deprecated_blockAttributes, ['style']),
1813      customTextColor: {
1814        type: 'string'
1815      },
1816      customBackgroundColor: {
1817        type: 'string'
1818      },
1819      customFontSize: {
1820        type: 'number'
1821      }
1822    },
1823    migrate: migrateCustomColorsAndFontSizes,
1824  
1825    save({
1826      attributes
1827    }) {
1828      const {
1829        align,
1830        content,
1831        dropCap,
1832        backgroundColor,
1833        textColor,
1834        customBackgroundColor,
1835        customTextColor,
1836        fontSize,
1837        customFontSize,
1838        direction
1839      } = attributes;
1840      const textClass = Object(external_wp_blockEditor_["getColorClassName"])('color', textColor);
1841      const backgroundClass = Object(external_wp_blockEditor_["getColorClassName"])('background-color', backgroundColor);
1842      const fontSizeClass = Object(external_wp_blockEditor_["getFontSizeClass"])(fontSize);
1843      const className = classnames_default()({
1844        'has-text-color': textColor || customTextColor,
1845        'has-background': backgroundColor || customBackgroundColor,
1846        'has-drop-cap': dropCap,
1847        [fontSizeClass]: fontSizeClass,
1848        [textClass]: textClass,
1849        [backgroundClass]: backgroundClass
1850      });
1851      const styles = {
1852        backgroundColor: backgroundClass ? undefined : customBackgroundColor,
1853        color: textClass ? undefined : customTextColor,
1854        fontSize: fontSizeClass ? undefined : customFontSize,
1855        textAlign: align
1856      };
1857      return Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
1858        tagName: "p",
1859        style: styles,
1860        className: className ? className : undefined,
1861        value: content,
1862        dir: direction
1863      });
1864    }
1865  
1866  }, {
1867    supports,
1868    attributes: { ...Object(external_lodash_["omit"])(deprecated_blockAttributes, ['style']),
1869      customTextColor: {
1870        type: 'string'
1871      },
1872      customBackgroundColor: {
1873        type: 'string'
1874      },
1875      customFontSize: {
1876        type: 'number'
1877      },
1878      width: {
1879        type: 'string'
1880      }
1881    },
1882    migrate: migrateCustomColorsAndFontSizes,
1883  
1884    save({
1885      attributes
1886    }) {
1887      const {
1888        width,
1889        align,
1890        content,
1891        dropCap,
1892        backgroundColor,
1893        textColor,
1894        customBackgroundColor,
1895        customTextColor,
1896        fontSize,
1897        customFontSize
1898      } = attributes;
1899      const textClass = Object(external_wp_blockEditor_["getColorClassName"])('color', textColor);
1900      const backgroundClass = Object(external_wp_blockEditor_["getColorClassName"])('background-color', backgroundColor);
1901      const fontSizeClass = fontSize && `is-$fontSize}-text`;
1902      const className = classnames_default()({
1903        [`align$width}`]: width,
1904        'has-background': backgroundColor || customBackgroundColor,
1905        'has-drop-cap': dropCap,
1906        [fontSizeClass]: fontSizeClass,
1907        [textClass]: textClass,
1908        [backgroundClass]: backgroundClass
1909      });
1910      const styles = {
1911        backgroundColor: backgroundClass ? undefined : customBackgroundColor,
1912        color: textClass ? undefined : customTextColor,
1913        fontSize: fontSizeClass ? undefined : customFontSize,
1914        textAlign: align
1915      };
1916      return Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
1917        tagName: "p",
1918        style: styles,
1919        className: className ? className : undefined,
1920        value: content
1921      });
1922    }
1923  
1924  }, {
1925    supports,
1926    attributes: Object(external_lodash_["omit"])({ ...deprecated_blockAttributes,
1927      fontSize: {
1928        type: 'number'
1929      }
1930    }, ['style']),
1931  
1932    save({
1933      attributes
1934    }) {
1935      const {
1936        width,
1937        align,
1938        content,
1939        dropCap,
1940        backgroundColor,
1941        textColor,
1942        fontSize
1943      } = attributes;
1944      const className = classnames_default()({
1945        [`align$width}`]: width,
1946        'has-background': backgroundColor,
1947        'has-drop-cap': dropCap
1948      });
1949      const styles = {
1950        backgroundColor,
1951        color: textColor,
1952        fontSize,
1953        textAlign: align
1954      };
1955      return Object(external_wp_element_["createElement"])("p", {
1956        style: styles,
1957        className: className ? className : undefined
1958      }, content);
1959    },
1960  
1961    migrate(attributes) {
1962      return migrateCustomColorsAndFontSizes(Object(external_lodash_["omit"])({ ...attributes,
1963        customFontSize: Object(external_lodash_["isFinite"])(attributes.fontSize) ? attributes.fontSize : undefined,
1964        customTextColor: attributes.textColor && '#' === attributes.textColor[0] ? attributes.textColor : undefined,
1965        customBackgroundColor: attributes.backgroundColor && '#' === attributes.backgroundColor[0] ? attributes.backgroundColor : undefined
1966      }), ['fontSize', 'textColor', 'backgroundColor', 'style']);
1967    }
1968  
1969  }, {
1970    supports,
1971    attributes: { ...deprecated_blockAttributes,
1972      content: {
1973        type: 'string',
1974        source: 'html',
1975        default: ''
1976      }
1977    },
1978  
1979    save({
1980      attributes
1981    }) {
1982      return Object(external_wp_element_["createElement"])(external_wp_element_["RawHTML"], null, attributes.content);
1983    },
1984  
1985    migrate(attributes) {
1986      return attributes;
1987    }
1988  
1989  }];
1990  /* harmony default export */ var paragraph_deprecated = (deprecated);
1991  
1992  // EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/extends.js
1993  var esm_extends = __webpack_require__("wx14");
1994  
1995  // EXTERNAL MODULE: external ["wp","components"]
1996  var external_wp_components_ = __webpack_require__("tI+e");
1997  
1998  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/format-ltr.js
1999  
2000  
2001  /**
2002   * WordPress dependencies
2003   */
2004  
2005  const formatLtr = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
2006    xmlns: "http://www.w3.org/2000/svg",
2007    viewBox: "-2 -2 24 24"
2008  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
2009    d: "M5.52 2h7.43c.55 0 1 .45 1 1s-.45 1-1 1h-1v13c0 .55-.45 1-1 1s-1-.45-1-1V5c0-.55-.45-1-1-1s-1 .45-1 1v12c0 .55-.45 1-1 1s-1-.45-1-1v-5.96h-.43C3.02 11.04 1 9.02 1 6.52S3.02 2 5.52 2zM14 14l5-4-5-4v8z"
2010  }));
2011  /* harmony default export */ var format_ltr = (formatLtr);
2012  
2013  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/paragraph/edit.js
2014  
2015  
2016  
2017  /**
2018   * External dependencies
2019   */
2020  
2021  /**
2022   * WordPress dependencies
2023   */
2024  
2025  
2026  
2027  
2028  
2029  
2030  const edit_name = 'core/paragraph';
2031  
2032  function ParagraphRTLControl({
2033    direction,
2034    setDirection
2035  }) {
2036    return Object(external_wp_i18n_["isRTL"])() && Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarDropdownMenu"], {
2037      controls: [{
2038        icon: format_ltr,
2039        title: Object(external_wp_i18n_["_x"])('Left to right', 'editor button'),
2040        isActive: direction === 'ltr',
2041  
2042        onClick() {
2043          setDirection(direction === 'ltr' ? undefined : 'ltr');
2044        }
2045  
2046      }]
2047    });
2048  }
2049  
2050  function ParagraphBlock({
2051    attributes,
2052    mergeBlocks,
2053    onReplace,
2054    onRemove,
2055    setAttributes,
2056    clientId
2057  }) {
2058    const {
2059      align,
2060      content,
2061      direction,
2062      dropCap,
2063      placeholder
2064    } = attributes;
2065    const isDropCapFeatureEnabled = Object(external_wp_blockEditor_["useSetting"])('typography.dropCap');
2066    const blockProps = Object(external_wp_blockEditor_["useBlockProps"])({
2067      className: classnames_default()({
2068        'has-drop-cap': dropCap,
2069        [`has-text-align-$align}`]: align
2070      }),
2071      style: {
2072        direction
2073      }
2074    });
2075    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockControls"], {
2076      group: "block"
2077    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["AlignmentControl"], {
2078      value: align,
2079      onChange: newAlign => setAttributes({
2080        align: newAlign
2081      })
2082    }), Object(external_wp_element_["createElement"])(ParagraphRTLControl, {
2083      direction: direction,
2084      setDirection: newDirection => setAttributes({
2085        direction: newDirection
2086      })
2087    })), isDropCapFeatureEnabled && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["InspectorControls"], null, Object(external_wp_element_["createElement"])(external_wp_components_["PanelBody"], {
2088      title: Object(external_wp_i18n_["__"])('Text settings')
2089    }, Object(external_wp_element_["createElement"])(external_wp_components_["ToggleControl"], {
2090      label: Object(external_wp_i18n_["__"])('Drop cap'),
2091      checked: !!dropCap,
2092      onChange: () => setAttributes({
2093        dropCap: !dropCap
2094      }),
2095      help: dropCap ? Object(external_wp_i18n_["__"])('Showing large initial letter.') : Object(external_wp_i18n_["__"])('Toggle to show a large initial letter.')
2096    }))), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"], Object(esm_extends["a" /* default */])({
2097      identifier: "content",
2098      tagName: "p"
2099    }, blockProps, {
2100      value: content,
2101      onChange: newContent => setAttributes({
2102        content: newContent
2103      }),
2104      onSplit: (value, isOriginal) => {
2105        let newAttributes;
2106  
2107        if (isOriginal || value) {
2108          newAttributes = { ...attributes,
2109            content: value
2110          };
2111        }
2112  
2113        const block = Object(external_wp_blocks_["createBlock"])(edit_name, newAttributes);
2114  
2115        if (isOriginal) {
2116          block.clientId = clientId;
2117        }
2118  
2119        return block;
2120      },
2121      onMerge: mergeBlocks,
2122      onReplace: onReplace,
2123      onRemove: onRemove,
2124      "aria-label": content ? Object(external_wp_i18n_["__"])('Paragraph block') : Object(external_wp_i18n_["__"])('Empty block; start writing or type forward slash to choose a block'),
2125      "data-empty": content ? false : true,
2126      placeholder: placeholder || Object(external_wp_i18n_["__"])('Type / to choose a block'),
2127      __unstableEmbedURLOnPaste: true,
2128      __unstableAllowPrefixTransformations: true
2129    })));
2130  }
2131  
2132  /* harmony default export */ var edit = (ParagraphBlock);
2133  
2134  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/paragraph/save.js
2135  
2136  
2137  /**
2138   * External dependencies
2139   */
2140  
2141  /**
2142   * WordPress dependencies
2143   */
2144  
2145  
2146  function save({
2147    attributes
2148  }) {
2149    const {
2150      align,
2151      content,
2152      dropCap,
2153      direction
2154    } = attributes;
2155    const className = classnames_default()({
2156      'has-drop-cap': dropCap,
2157      [`has-text-align-$align}`]: align
2158    });
2159    return Object(external_wp_element_["createElement"])("p", external_wp_blockEditor_["useBlockProps"].save({
2160      className,
2161      dir: direction
2162    }), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
2163      value: content
2164    }));
2165  }
2166  
2167  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/paragraph/transforms.js
2168  /**
2169   * WordPress dependencies
2170   */
2171  
2172  /**
2173   * Internal dependencies
2174   */
2175  
2176  const {
2177    name: transforms_name
2178  } = {
2179    apiVersion: 2,
2180    name: "core/paragraph",
2181    title: "Paragraph",
2182    category: "text",
2183    description: "Start with the building block of all narrative.",
2184    keywords: ["text"],
2185    textdomain: "default",
2186    attributes: {
2187      align: {
2188        type: "string"
2189      },
2190      content: {
2191        type: "string",
2192        source: "html",
2193        selector: "p",
2194        "default": "",
2195        __experimentalRole: "content"
2196      },
2197      dropCap: {
2198        type: "boolean",
2199        "default": false
2200      },
2201      placeholder: {
2202        type: "string"
2203      },
2204      direction: {
2205        type: "string",
2206        "enum": ["ltr", "rtl"]
2207      }
2208    },
2209    supports: {
2210      anchor: true,
2211      className: false,
2212      color: {
2213        link: true
2214      },
2215      typography: {
2216        fontSize: true,
2217        lineHeight: true
2218      },
2219      __experimentalSelector: "p",
2220      __unstablePasteTextInline: true
2221    },
2222    editorStyle: "wp-block-paragraph-editor",
2223    style: "wp-block-paragraph"
2224  };
2225  const transforms = {
2226    from: [{
2227      type: 'raw',
2228      // Paragraph is a fallback and should be matched last.
2229      priority: 20,
2230      selector: 'p',
2231      schema: ({
2232        phrasingContentSchema,
2233        isPaste
2234      }) => ({
2235        p: {
2236          children: phrasingContentSchema,
2237          attributes: isPaste ? [] : ['style', 'id']
2238        }
2239      }),
2240  
2241      transform(node) {
2242        const attributes = Object(external_wp_blocks_["getBlockAttributes"])(transforms_name, node.outerHTML);
2243        const {
2244          textAlign
2245        } = node.style || {};
2246  
2247        if (textAlign === 'left' || textAlign === 'center' || textAlign === 'right') {
2248          attributes.align = textAlign;
2249        }
2250  
2251        return Object(external_wp_blocks_["createBlock"])(transforms_name, attributes);
2252      }
2253  
2254    }]
2255  };
2256  /* harmony default export */ var paragraph_transforms = (transforms);
2257  
2258  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/paragraph/index.js
2259  /**
2260   * External dependencies
2261   */
2262  
2263  /**
2264   * WordPress dependencies
2265   */
2266  
2267  
2268  
2269  /**
2270   * Internal dependencies
2271   */
2272  
2273  
2274  
2275  const paragraph_metadata = {
2276    apiVersion: 2,
2277    name: "core/paragraph",
2278    title: "Paragraph",
2279    category: "text",
2280    description: "Start with the building block of all narrative.",
2281    keywords: ["text"],
2282    textdomain: "default",
2283    attributes: {
2284      align: {
2285        type: "string"
2286      },
2287      content: {
2288        type: "string",
2289        source: "html",
2290        selector: "p",
2291        "default": "",
2292        __experimentalRole: "content"
2293      },
2294      dropCap: {
2295        type: "boolean",
2296        "default": false
2297      },
2298      placeholder: {
2299        type: "string"
2300      },
2301      direction: {
2302        type: "string",
2303        "enum": ["ltr", "rtl"]
2304      }
2305    },
2306    supports: {
2307      anchor: true,
2308      className: false,
2309      color: {
2310        link: true
2311      },
2312      typography: {
2313        fontSize: true,
2314        lineHeight: true
2315      },
2316      __experimentalSelector: "p",
2317      __unstablePasteTextInline: true
2318    },
2319    editorStyle: "wp-block-paragraph-editor",
2320    style: "wp-block-paragraph"
2321  };
2322  
2323  
2324  const {
2325    name: paragraph_name
2326  } = paragraph_metadata;
2327  
2328  const paragraph_settings = {
2329    icon: library_paragraph,
2330    example: {
2331      attributes: {
2332        content: Object(external_wp_i18n_["__"])('In a village of La Mancha, the name of which I have no desire to call to mind, there lived not long since one of those gentlemen that keep a lance in the lance-rack, an old buckler, a lean hack, and a greyhound for coursing.'),
2333        style: {
2334          typography: {
2335            fontSize: 28
2336          }
2337        },
2338        dropCap: true
2339      }
2340    },
2341  
2342    __experimentalLabel(attributes, {
2343      context
2344    }) {
2345      if (context === 'accessibility') {
2346        const {
2347          content
2348        } = attributes;
2349        return Object(external_lodash_["isEmpty"])(content) ? Object(external_wp_i18n_["__"])('Empty') : content;
2350      }
2351    },
2352  
2353    transforms: paragraph_transforms,
2354    deprecated: paragraph_deprecated,
2355  
2356    merge(attributes, attributesToMerge) {
2357      return {
2358        content: (attributes.content || '') + (attributesToMerge.content || '')
2359      };
2360    },
2361  
2362    edit: edit,
2363    save: save
2364  };
2365  
2366  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/image.js
2367  
2368  
2369  /**
2370   * WordPress dependencies
2371   */
2372  
2373  const image_image = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
2374    viewBox: "0 0 24 24",
2375    xmlns: "http://www.w3.org/2000/svg"
2376  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
2377    d: "M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM5 4.5h14c.3 0 .5.2.5.5v8.4l-3-2.9c-.3-.3-.8-.3-1 0L11.9 14 9 12c-.3-.2-.6-.2-.8 0l-3.6 2.6V5c-.1-.3.1-.5.4-.5zm14 15H5c-.3 0-.5-.2-.5-.5v-2.4l4.1-3 3 1.9c.3.2.7.2.9-.1L16 12l3.5 3.4V19c0 .3-.2.5-.5.5z"
2378  }));
2379  /* harmony default export */ var library_image = (image_image);
2380  
2381  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/deprecated.js
2382  
2383  
2384  
2385  /**
2386   * External dependencies
2387   */
2388  
2389  /**
2390   * WordPress dependencies
2391   */
2392  
2393  
2394  const image_deprecated_blockAttributes = {
2395    align: {
2396      type: 'string'
2397    },
2398    url: {
2399      type: 'string',
2400      source: 'attribute',
2401      selector: 'img',
2402      attribute: 'src'
2403    },
2404    alt: {
2405      type: 'string',
2406      source: 'attribute',
2407      selector: 'img',
2408      attribute: 'alt',
2409      default: ''
2410    },
2411    caption: {
2412      type: 'string',
2413      source: 'html',
2414      selector: 'figcaption'
2415    },
2416    href: {
2417      type: 'string',
2418      source: 'attribute',
2419      selector: 'figure > a',
2420      attribute: 'href'
2421    },
2422    rel: {
2423      type: 'string',
2424      source: 'attribute',
2425      selector: 'figure > a',
2426      attribute: 'rel'
2427    },
2428    linkClass: {
2429      type: 'string',
2430      source: 'attribute',
2431      selector: 'figure > a',
2432      attribute: 'class'
2433    },
2434    id: {
2435      type: 'number'
2436    },
2437    width: {
2438      type: 'number'
2439    },
2440    height: {
2441      type: 'number'
2442    },
2443    linkDestination: {
2444      type: 'string'
2445    },
2446    linkTarget: {
2447      type: 'string',
2448      source: 'attribute',
2449      selector: 'figure > a',
2450      attribute: 'target'
2451    }
2452  };
2453  const deprecated_deprecated = [{
2454    attributes: image_deprecated_blockAttributes,
2455  
2456    save({
2457      attributes
2458    }) {
2459      const {
2460        url,
2461        alt,
2462        caption,
2463        align,
2464        href,
2465        width,
2466        height,
2467        id
2468      } = attributes;
2469      const classes = classnames_default()({
2470        [`align$align}`]: align,
2471        'is-resized': width || height
2472      });
2473      const image = Object(external_wp_element_["createElement"])("img", {
2474        src: url,
2475        alt: alt,
2476        className: id ? `wp-image-$id}` : null,
2477        width: width,
2478        height: height
2479      });
2480      return Object(external_wp_element_["createElement"])("figure", {
2481        className: classes
2482      }, href ? Object(external_wp_element_["createElement"])("a", {
2483        href: href
2484      }, image) : image, !external_wp_blockEditor_["RichText"].isEmpty(caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
2485        tagName: "figcaption",
2486        value: caption
2487      }));
2488    }
2489  
2490  }, {
2491    attributes: image_deprecated_blockAttributes,
2492  
2493    save({
2494      attributes
2495    }) {
2496      const {
2497        url,
2498        alt,
2499        caption,
2500        align,
2501        href,
2502        width,
2503        height,
2504        id
2505      } = attributes;
2506      const image = Object(external_wp_element_["createElement"])("img", {
2507        src: url,
2508        alt: alt,
2509        className: id ? `wp-image-$id}` : null,
2510        width: width,
2511        height: height
2512      });
2513      return Object(external_wp_element_["createElement"])("figure", {
2514        className: align ? `align$align}` : null
2515      }, href ? Object(external_wp_element_["createElement"])("a", {
2516        href: href
2517      }, image) : image, !external_wp_blockEditor_["RichText"].isEmpty(caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
2518        tagName: "figcaption",
2519        value: caption
2520      }));
2521    }
2522  
2523  }, {
2524    attributes: image_deprecated_blockAttributes,
2525  
2526    save({
2527      attributes
2528    }) {
2529      const {
2530        url,
2531        alt,
2532        caption,
2533        align,
2534        href,
2535        width,
2536        height
2537      } = attributes;
2538      const extraImageProps = width || height ? {
2539        width,
2540        height
2541      } : {};
2542      const image = Object(external_wp_element_["createElement"])("img", Object(esm_extends["a" /* default */])({
2543        src: url,
2544        alt: alt
2545      }, extraImageProps));
2546      let figureStyle = {};
2547  
2548      if (width) {
2549        figureStyle = {
2550          width
2551        };
2552      } else if (align === 'left' || align === 'right') {
2553        figureStyle = {
2554          maxWidth: '50%'
2555        };
2556      }
2557  
2558      return Object(external_wp_element_["createElement"])("figure", {
2559        className: align ? `align$align}` : null,
2560        style: figureStyle
2561      }, href ? Object(external_wp_element_["createElement"])("a", {
2562        href: href
2563      }, image) : image, !external_wp_blockEditor_["RichText"].isEmpty(caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
2564        tagName: "figcaption",
2565        value: caption
2566      }));
2567    }
2568  
2569  }];
2570  /* harmony default export */ var image_deprecated = (deprecated_deprecated);
2571  
2572  // EXTERNAL MODULE: external ["wp","blob"]
2573  var external_wp_blob_ = __webpack_require__("xTGt");
2574  
2575  // EXTERNAL MODULE: external ["wp","data"]
2576  var external_wp_data_ = __webpack_require__("1ZqX");
2577  
2578  // EXTERNAL MODULE: external ["wp","compose"]
2579  var external_wp_compose_ = __webpack_require__("K9lf");
2580  
2581  // EXTERNAL MODULE: external ["wp","url"]
2582  var external_wp_url_ = __webpack_require__("Mmq9");
2583  
2584  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/crop.js
2585  
2586  
2587  /**
2588   * WordPress dependencies
2589   */
2590  
2591  const crop_crop = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
2592    xmlns: "http://www.w3.org/2000/svg",
2593    viewBox: "0 0 24 24"
2594  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
2595    d: "M16.5 7.8v7H18v-7c0-1-.8-1.8-1.8-1.8h-7v1.5h7c.2 0 .3.1.3.3zm-8.7 8.7c-.1 0-.2-.1-.2-.2V2H6v4H2v1.5h4v8.8c0 1 .8 1.8 1.8 1.8h8.8v4H18v-4h4v-1.5H7.8z"
2596  }));
2597  /* harmony default export */ var library_crop = (crop_crop);
2598  
2599  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/upload.js
2600  var upload = __webpack_require__("NTP4");
2601  
2602  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/overlay-text.js
2603  
2604  
2605  /**
2606   * WordPress dependencies
2607   */
2608  
2609  const overlayText = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
2610    xmlns: "http://www.w3.org/2000/svg",
2611    viewBox: "0 0 24 24"
2612  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
2613    d: "M18 4H6c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12-9.8c.4 0 .8-.3.9-.7l1.1-3h3.6l.5 1.7h1.9L13 9h-2.2l-3.4 9.5H6c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v12H20V6c0-1.1-.9-2-2-2zm-6 7l1.4 3.9h-2.7L12 11z"
2614  }));
2615  /* harmony default export */ var overlay_text = (overlayText);
2616  
2617  // EXTERNAL MODULE: external ["wp","notices"]
2618  var external_wp_notices_ = __webpack_require__("onLe");
2619  
2620  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/embed/constants.js
2621  const ASPECT_RATIOS = [// Common video resolutions.
2622  {
2623    ratio: '2.33',
2624    className: 'wp-embed-aspect-21-9'
2625  }, {
2626    ratio: '2.00',
2627    className: 'wp-embed-aspect-18-9'
2628  }, {
2629    ratio: '1.78',
2630    className: 'wp-embed-aspect-16-9'
2631  }, {
2632    ratio: '1.33',
2633    className: 'wp-embed-aspect-4-3'
2634  }, // Vertical video and instagram square video support.
2635  {
2636    ratio: '1.00',
2637    className: 'wp-embed-aspect-1-1'
2638  }, {
2639    ratio: '0.56',
2640    className: 'wp-embed-aspect-9-16'
2641  }, {
2642    ratio: '0.50',
2643    className: 'wp-embed-aspect-1-2'
2644  }];
2645  const WP_EMBED_TYPE = 'wp-embed';
2646  
2647  // EXTERNAL MODULE: ./node_modules/classnames/dedupe.js
2648  var dedupe = __webpack_require__("A/WM");
2649  var dedupe_default = /*#__PURE__*/__webpack_require__.n(dedupe);
2650  
2651  // EXTERNAL MODULE: ./node_modules/memize/index.js
2652  var memize = __webpack_require__("4eJC");
2653  var memize_default = /*#__PURE__*/__webpack_require__.n(memize);
2654  
2655  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/embed/util.js
2656  
2657  
2658  /**
2659   * Internal dependencies
2660   */
2661  
2662  /**
2663   * External dependencies
2664   */
2665  
2666  
2667  
2668  
2669  /**
2670   * WordPress dependencies
2671   */
2672  
2673  
2674  
2675  /**
2676   * Internal dependencies
2677   */
2678  
2679  const util_metadata = {
2680    apiVersion: 2,
2681    name: "core/embed",
2682    title: "Embed",
2683    category: "embed",
2684    description: "Add a block that displays content pulled from other sites, like Twitter, Instagram or YouTube.",
2685    textdomain: "default",
2686    attributes: {
2687      url: {
2688        type: "string"
2689      },
2690      caption: {
2691        type: "string",
2692        source: "html",
2693        selector: "figcaption"
2694      },
2695      type: {
2696        type: "string"
2697      },
2698      providerNameSlug: {
2699        type: "string"
2700      },
2701      allowResponsive: {
2702        type: "boolean",
2703        "default": true
2704      },
2705      responsive: {
2706        type: "boolean",
2707        "default": false
2708      },
2709      previewable: {
2710        type: "boolean",
2711        "default": true
2712      }
2713    },
2714    supports: {
2715      align: true
2716    },
2717    editorStyle: "wp-block-embed-editor",
2718    style: "wp-block-embed"
2719  };
2720  const {
2721    name: DEFAULT_EMBED_BLOCK
2722  } = util_metadata;
2723  /** @typedef {import('@wordpress/blocks').WPBlockVariation} WPBlockVariation */
2724  
2725  /**
2726   * Returns the embed block's information by matching the provided service provider
2727   *
2728   * @param {string} provider The embed block's provider
2729   * @return {WPBlockVariation} The embed block's information
2730   */
2731  
2732  const getEmbedInfoByProvider = provider => {
2733    var _getBlockVariations;
2734  
2735    return (_getBlockVariations = Object(external_wp_blocks_["getBlockVariations"])(DEFAULT_EMBED_BLOCK)) === null || _getBlockVariations === void 0 ? void 0 : _getBlockVariations.find(({
2736      name
2737    }) => name === provider);
2738  };
2739  /**
2740   * Returns true if any of the regular expressions match the URL.
2741   *
2742   * @param {string}   url      The URL to test.
2743   * @param {Array}    patterns The list of regular expressions to test agains.
2744   * @return {boolean} True if any of the regular expressions match the URL.
2745   */
2746  
2747  const matchesPatterns = (url, patterns = []) => patterns.some(pattern => url.match(pattern));
2748  /**
2749   * Finds the block variation that should be used for the URL,
2750   * based on the provided URL and the variation's patterns.
2751   *
2752   * @param {string}  url The URL to test.
2753   * @return {WPBlockVariation} The block variation that should be used for this URL
2754   */
2755  
2756  const findMoreSuitableBlock = url => {
2757    var _getBlockVariations2;
2758  
2759    return (_getBlockVariations2 = Object(external_wp_blocks_["getBlockVariations"])(DEFAULT_EMBED_BLOCK)) === null || _getBlockVariations2 === void 0 ? void 0 : _getBlockVariations2.find(({
2760      patterns
2761    }) => matchesPatterns(url, patterns));
2762  };
2763  const isFromWordPress = html => html && html.includes('class="wp-embedded-content"');
2764  const getPhotoHtml = photo => {
2765    // 100% width for the preview so it fits nicely into the document, some "thumbnails" are
2766    // actually the full size photo. If thumbnails not found, use full image.
2767    const imageUrl = photo.thumbnail_url || photo.url;
2768    const photoPreview = Object(external_wp_element_["createElement"])("p", null, Object(external_wp_element_["createElement"])("img", {
2769      src: imageUrl,
2770      alt: photo.title,
2771      width: "100%"
2772    }));
2773    return Object(external_wp_element_["renderToString"])(photoPreview);
2774  };
2775  /**
2776   * Creates a more suitable embed block based on the passed in props
2777   * and attributes generated from an embed block's preview.
2778   *
2779   * We require `attributesFromPreview` to be generated from the latest attributes
2780   * and preview, and because of the way the react lifecycle operates, we can't
2781   * guarantee that the attributes contained in the block's props are the latest
2782   * versions, so we require that these are generated separately.
2783   * See `getAttributesFromPreview` in the generated embed edit component.
2784   *
2785   * @param {Object} props                  The block's props.
2786   * @param {Object} [attributesFromPreview]  Attributes generated from the block's most up to date preview.
2787   * @return {Object|undefined} A more suitable embed block if one exists.
2788   */
2789  
2790  const createUpgradedEmbedBlock = (props, attributesFromPreview = {}) => {
2791    var _getBlockVariations3;
2792  
2793    const {
2794      preview,
2795      attributes: {
2796        url,
2797        providerNameSlug,
2798        type
2799      } = {}
2800    } = props;
2801    if (!url || !Object(external_wp_blocks_["getBlockType"])(DEFAULT_EMBED_BLOCK)) return;
2802    const matchedBlock = findMoreSuitableBlock(url); // WordPress blocks can work on multiple sites, and so don't have patterns,
2803    // so if we're in a WordPress block, assume the user has chosen it for a WordPress URL.
2804  
2805    const isCurrentBlockWP = providerNameSlug === 'wordpress' || type === WP_EMBED_TYPE; // if current block is not WordPress and a more suitable block found
2806    // that is different from the current one, create the new matched block
2807  
2808    const shouldCreateNewBlock = !isCurrentBlockWP && matchedBlock && (matchedBlock.attributes.providerNameSlug !== providerNameSlug || !providerNameSlug);
2809  
2810    if (shouldCreateNewBlock) {
2811      return Object(external_wp_blocks_["createBlock"])(DEFAULT_EMBED_BLOCK, {
2812        url,
2813        ...matchedBlock.attributes
2814      });
2815    }
2816  
2817    const wpVariation = (_getBlockVariations3 = Object(external_wp_blocks_["getBlockVariations"])(DEFAULT_EMBED_BLOCK)) === null || _getBlockVariations3 === void 0 ? void 0 : _getBlockVariations3.find(({
2818      name
2819    }) => name === 'wordpress'); // We can't match the URL for WordPress embeds, we have to check the HTML instead.
2820  
2821    if (!wpVariation || !preview || !isFromWordPress(preview.html) || isCurrentBlockWP) {
2822      return;
2823    } // This is not the WordPress embed block so transform it into one.
2824  
2825  
2826    return Object(external_wp_blocks_["createBlock"])(DEFAULT_EMBED_BLOCK, {
2827      url,
2828      ...wpVariation.attributes,
2829      // By now we have the preview, but when the new block first renders, it
2830      // won't have had all the attributes set, and so won't get the correct
2831      // type and it won't render correctly. So, we pass through the current attributes
2832      // here so that the initial render works when we switch to the WordPress
2833      // block. This only affects the WordPress block because it can't be
2834      // rendered in the usual Sandbox (it has a sandbox of its own) and it
2835      // relies on the preview to set the correct render type.
2836      ...attributesFromPreview
2837    });
2838  };
2839  /**
2840   * Removes all previously set aspect ratio related classes and return the rest
2841   * existing class names.
2842   *
2843   * @param {string} existingClassNames Any existing class names.
2844   * @return {string} The class names without any aspect ratio related class.
2845   */
2846  
2847  const removeAspectRatioClasses = existingClassNames => {
2848    if (!existingClassNames) {
2849      // Avoids extraneous work and also, by returning the same value as
2850      // received, ensures the post is not dirtied by a change of the block
2851      // attribute from `undefined` to an emtpy string.
2852      return existingClassNames;
2853    }
2854  
2855    const aspectRatioClassNames = ASPECT_RATIOS.reduce((accumulator, {
2856      className
2857    }) => {
2858      accumulator[className] = false;
2859      return accumulator;
2860    }, {
2861      'wp-has-aspect-ratio': false
2862    });
2863    return dedupe_default()(existingClassNames, aspectRatioClassNames);
2864  };
2865  /**
2866   * Returns class names with any relevant responsive aspect ratio names.
2867   *
2868   * @param {string}  html               The preview HTML that possibly contains an iframe with width and height set.
2869   * @param {string}  existingClassNames Any existing class names.
2870   * @param {boolean} allowResponsive    If the responsive class names should be added, or removed.
2871   * @return {string} Deduped class names.
2872   */
2873  
2874  function getClassNames(html, existingClassNames, allowResponsive = true) {
2875    if (!allowResponsive) {
2876      return removeAspectRatioClasses(existingClassNames);
2877    }
2878  
2879    const previewDocument = document.implementation.createHTMLDocument('');
2880    previewDocument.body.innerHTML = html;
2881    const iframe = previewDocument.body.querySelector('iframe'); // If we have a fixed aspect iframe, and it's a responsive embed block.
2882  
2883    if (iframe && iframe.height && iframe.width) {
2884      const aspectRatio = (iframe.width / iframe.height).toFixed(2); // Given the actual aspect ratio, find the widest ratio to support it.
2885  
2886      for (let ratioIndex = 0; ratioIndex < ASPECT_RATIOS.length; ratioIndex++) {
2887        const potentialRatio = ASPECT_RATIOS[ratioIndex];
2888  
2889        if (aspectRatio >= potentialRatio.ratio) {
2890          // Evaluate the difference between actual aspect ratio and closest match.
2891          // If the difference is too big, do not scale the embed according to aspect ratio.
2892          const ratioDiff = aspectRatio - potentialRatio.ratio;
2893  
2894          if (ratioDiff > 0.1) {
2895            // No close aspect ratio match found.
2896            return removeAspectRatioClasses(existingClassNames);
2897          } // Close aspect ratio match found.
2898  
2899  
2900          return dedupe_default()(removeAspectRatioClasses(existingClassNames), potentialRatio.className, 'wp-has-aspect-ratio');
2901        }
2902      }
2903    }
2904  
2905    return existingClassNames;
2906  }
2907  /**
2908   * Fallback behaviour for unembeddable URLs.
2909   * Creates a paragraph block containing a link to the URL, and calls `onReplace`.
2910   *
2911   * @param {string}   url       The URL that could not be embedded.
2912   * @param {Function} onReplace Function to call with the created fallback block.
2913   */
2914  
2915  function util_fallback(url, onReplace) {
2916    const link = Object(external_wp_element_["createElement"])("a", {
2917      href: url
2918    }, url);
2919    onReplace(Object(external_wp_blocks_["createBlock"])('core/paragraph', {
2920      content: Object(external_wp_element_["renderToString"])(link)
2921    }));
2922  }
2923  /***
2924   * Gets block attributes based on the preview and responsive state.
2925   *
2926   * @param {Object} preview The preview data.
2927   * @param {string} title The block's title, e.g. Twitter.
2928   * @param {Object} currentClassNames The block's current class names.
2929   * @param {boolean} isResponsive Boolean indicating if the block supports responsive content.
2930   * @param {boolean} allowResponsive Apply responsive classes to fixed size content.
2931   * @return {Object} Attributes and values.
2932   */
2933  
2934  const getAttributesFromPreview = memize_default()((preview, title, currentClassNames, isResponsive, allowResponsive = true) => {
2935    if (!preview) {
2936      return {};
2937    }
2938  
2939    const attributes = {}; // Some plugins only return HTML with no type info, so default this to 'rich'.
2940  
2941    let {
2942      type = 'rich'
2943    } = preview; // If we got a provider name from the API, use it for the slug, otherwise we use the title,
2944    // because not all embed code gives us a provider name.
2945  
2946    const {
2947      html,
2948      provider_name: providerName
2949    } = preview;
2950    const providerNameSlug = Object(external_lodash_["kebabCase"])((providerName || title).toLowerCase());
2951  
2952    if (isFromWordPress(html)) {
2953      type = WP_EMBED_TYPE;
2954    }
2955  
2956    if (html || 'photo' === type) {
2957      attributes.type = type;
2958      attributes.providerNameSlug = providerNameSlug;
2959    }
2960  
2961    attributes.className = getClassNames(html, currentClassNames, isResponsive && allowResponsive);
2962    return attributes;
2963  });
2964  
2965  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/use-client-width.js
2966  /**
2967   * WordPress dependencies
2968   */
2969  
2970  function useClientWidth(ref, dependencies) {
2971    const [clientWidth, setClientWidth] = Object(external_wp_element_["useState"])();
2972  
2973    function calculateClientWidth() {
2974      setClientWidth(ref.current.clientWidth);
2975    }
2976  
2977    Object(external_wp_element_["useEffect"])(calculateClientWidth, dependencies);
2978    Object(external_wp_element_["useEffect"])(() => {
2979      const {
2980        defaultView
2981      } = ref.current.ownerDocument;
2982      defaultView.addEventListener('resize', calculateClientWidth);
2983      return () => {
2984        defaultView.removeEventListener('resize', calculateClientWidth);
2985      };
2986    }, []);
2987    return clientWidth;
2988  }
2989  
2990  // CONCATENATED MODULE: ./node_modules/react-easy-crop/node_modules/tslib/tslib.es6.js
2991  /*! *****************************************************************************

2992  Copyright (c) Microsoft Corporation.

2993  

2994  Permission to use, copy, modify, and/or distribute this software for any

2995  purpose with or without fee is hereby granted.

2996  

2997  THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH

2998  REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY

2999  AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,

3000  INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM

3001  LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR

3002  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR

3003  PERFORMANCE OF THIS SOFTWARE.

3004  ***************************************************************************** */
3005  /* global Reflect, Promise */

3006  
3007  var extendStatics = function(d, b) {
3008      extendStatics = Object.setPrototypeOf ||
3009          ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
3010          function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
3011      return extendStatics(d, b);
3012  };
3013  
3014  function __extends(d, b) {
3015      extendStatics(d, b);
3016      function __() { this.constructor = d; }
3017      d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
3018  }
3019  
3020  var __assign = function() {
3021      __assign = Object.assign || function __assign(t) {
3022          for (var s, i = 1, n = arguments.length; i < n; i++) {
3023              s = arguments[i];
3024              for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
3025          }
3026          return t;
3027      }
3028      return __assign.apply(this, arguments);
3029  }
3030  
3031  function __rest(s, e) {
3032      var t = {};
3033      for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
3034          t[p] = s[p];
3035      if (s != null && typeof Object.getOwnPropertySymbols === "function")
3036          for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
3037              if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
3038                  t[p[i]] = s[p[i]];
3039          }
3040      return t;
3041  }
3042  
3043  function __decorate(decorators, target, key, desc) {
3044      var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3045      if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
3046      else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3047      return c > 3 && r && Object.defineProperty(target, key, r), r;
3048  }
3049  
3050  function __param(paramIndex, decorator) {
3051      return function (target, key) { decorator(target, key, paramIndex); }
3052  }
3053  
3054  function __metadata(metadataKey, metadataValue) {
3055      if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue);
3056  }
3057  
3058  function __awaiter(thisArg, _arguments, P, generator) {
3059      function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3060      return new (P || (P = Promise))(function (resolve, reject) {
3061          function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
3062          function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
3063          function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
3064          step((generator = generator.apply(thisArg, _arguments || [])).next());
3065      });
3066  }
3067  
3068  function __generator(thisArg, body) {
3069      var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
3070      return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
3071      function verb(n) { return function (v) { return step([n, v]); }; }
3072      function step(op) {
3073          if (f) throw new TypeError("Generator is already executing.");
3074          while (_) try {
3075              if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
3076              if (y = 0, t) op = [op[0] & 2, t.value];
3077              switch (op[0]) {
3078                  case 0: case 1: t = op; break;
3079                  case 4: _.label++; return { value: op[1], done: false };
3080                  case 5: _.label++; y = op[1]; op = [0]; continue;
3081                  case 7: op = _.ops.pop(); _.trys.pop(); continue;
3082                  default:
3083                      if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
3084                      if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
3085                      if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
3086                      if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
3087                      if (t[2]) _.ops.pop();
3088                      _.trys.pop(); continue;
3089              }
3090              op = body.call(thisArg, _);
3091          } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
3092          if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
3093      }
3094  }
3095  
3096  var __createBinding = Object.create ? (function(o, m, k, k2) {
3097      if (k2 === undefined) k2 = k;
3098      Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
3099  }) : (function(o, m, k, k2) {
3100      if (k2 === undefined) k2 = k;
3101      o[k2] = m[k];
3102  });
3103  
3104  function __exportStar(m, o) {
3105      for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);
3106  }
3107  
3108  function __values(o) {
3109      var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
3110      if (m) return m.call(o);
3111      if (o && typeof o.length === "number") return {
3112          next: function () {
3113              if (o && i >= o.length) o = void 0;
3114              return { value: o && o[i++], done: !o };
3115          }
3116      };
3117      throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
3118  }
3119  
3120  function __read(o, n) {
3121      var m = typeof Symbol === "function" && o[Symbol.iterator];
3122      if (!m) return o;
3123      var i = m.call(o), r, ar = [], e;
3124      try {
3125          while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
3126      }
3127      catch (error) { e = { error: error }; }
3128      finally {
3129          try {
3130              if (r && !r.done && (m = i["return"])) m.call(i);
3131          }
3132          finally { if (e) throw e.error; }
3133      }
3134      return ar;
3135  }
3136  
3137  function __spread() {
3138      for (var ar = [], i = 0; i < arguments.length; i++)
3139          ar = ar.concat(__read(arguments[i]));
3140      return ar;
3141  }
3142  
3143  function __spreadArrays() {
3144      for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
3145      for (var r = Array(s), k = 0, i = 0; i < il; i++)
3146          for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
3147              r[k] = a[j];
3148      return r;
3149  };
3150  
3151  function __await(v) {
3152      return this instanceof __await ? (this.v = v, this) : new __await(v);
3153  }
3154  
3155  function __asyncGenerator(thisArg, _arguments, generator) {
3156      if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
3157      var g = generator.apply(thisArg, _arguments || []), i, q = [];
3158      return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
3159      function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
3160      function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
3161      function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
3162      function fulfill(value) { resume("next", value); }
3163      function reject(value) { resume("throw", value); }
3164      function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
3165  }
3166  
3167  function __asyncDelegator(o) {
3168      var i, p;
3169      return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
3170      function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
3171  }
3172  
3173  function __asyncValues(o) {
3174      if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
3175      var m = o[Symbol.asyncIterator], i;
3176      return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
3177      function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
3178      function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
3179  }
3180  
3181  function __makeTemplateObject(cooked, raw) {
3182      if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
3183      return cooked;
3184  };
3185  
3186  var __setModuleDefault = Object.create ? (function(o, v) {
3187      Object.defineProperty(o, "default", { enumerable: true, value: v });
3188  }) : function(o, v) {
3189      o["default"] = v;
3190  };
3191  
3192  function __importStar(mod) {
3193      if (mod && mod.__esModule) return mod;
3194      var result = {};
3195      if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
3196      __setModuleDefault(result, mod);
3197      return result;
3198  }
3199  
3200  function __importDefault(mod) {
3201      return (mod && mod.__esModule) ? mod : { default: mod };
3202  }
3203  
3204  function __classPrivateFieldGet(receiver, privateMap) {
3205      if (!privateMap.has(receiver)) {
3206          throw new TypeError("attempted to get private field on non-instance");
3207      }
3208      return privateMap.get(receiver);
3209  }
3210  
3211  function __classPrivateFieldSet(receiver, privateMap, value) {
3212      if (!privateMap.has(receiver)) {
3213          throw new TypeError("attempted to set private field on non-instance");
3214      }
3215      privateMap.set(receiver, value);
3216      return value;
3217  }
3218  
3219  // EXTERNAL MODULE: external "React"
3220  var external_React_ = __webpack_require__("cDcd");
3221  var external_React_default = /*#__PURE__*/__webpack_require__.n(external_React_);
3222  
3223  // EXTERNAL MODULE: ./node_modules/normalize-wheel/index.js
3224  var normalize_wheel = __webpack_require__("wJiJ");
3225  var normalize_wheel_default = /*#__PURE__*/__webpack_require__.n(normalize_wheel);
3226  
3227  // CONCATENATED MODULE: ./node_modules/react-easy-crop/index.module.js
3228  
3229  
3230  
3231  
3232  /**

3233   * Compute the dimension of the crop area based on media size,

3234   * aspect ratio and optionally rotation

3235   */
3236  
3237  function getCropSize(mediaWidth, mediaHeight, containerWidth, containerHeight, aspect, rotation) {
3238    if (rotation === void 0) {
3239      rotation = 0;
3240    }
3241  
3242    var _a = translateSize(mediaWidth, mediaHeight, rotation),
3243        width = _a.width,
3244        height = _a.height;
3245  
3246    var fittingWidth = Math.min(width, containerWidth);
3247    var fittingHeight = Math.min(height, containerHeight);
3248  
3249    if (fittingWidth > fittingHeight * aspect) {
3250      return {
3251        width: fittingHeight * aspect,
3252        height: fittingHeight
3253      };
3254    }
3255  
3256    return {
3257      width: fittingWidth,
3258      height: fittingWidth / aspect
3259    };
3260  }
3261  /**

3262   * Ensure a new media position stays in the crop area.

3263   */
3264  
3265  function index_module_restrictPosition(position, mediaSize, cropSize, zoom, rotation) {
3266    if (rotation === void 0) {
3267      rotation = 0;
3268    }
3269  
3270    var _a = translateSize(mediaSize.width, mediaSize.height, rotation),
3271        width = _a.width,
3272        height = _a.height;
3273  
3274    return {
3275      x: restrictPositionCoord(position.x, width, cropSize.width, zoom),
3276      y: restrictPositionCoord(position.y, height, cropSize.height, zoom)
3277    };
3278  }
3279  
3280  function restrictPositionCoord(position, mediaSize, cropSize, zoom) {
3281    var maxPosition = mediaSize * zoom / 2 - cropSize / 2;
3282    return Math.min(maxPosition, Math.max(position, -maxPosition));
3283  }
3284  
3285  function getDistanceBetweenPoints(pointA, pointB) {
3286    return Math.sqrt(Math.pow(pointA.y - pointB.y, 2) + Math.pow(pointA.x - pointB.x, 2));
3287  }
3288  function getRotationBetweenPoints(pointA, pointB) {
3289    return Math.atan2(pointB.y - pointA.y, pointB.x - pointA.x) * 180 / Math.PI;
3290  }
3291  /**

3292   * Compute the output cropped area of the media in percentages and pixels.

3293   * x/y are the top-left coordinates on the src media

3294   */
3295  
3296  function computeCroppedArea(crop, mediaSize, cropSize, aspect, zoom, rotation, restrictPosition) {
3297    if (rotation === void 0) {
3298      rotation = 0;
3299    }
3300  
3301    if (restrictPosition === void 0) {
3302      restrictPosition = true;
3303    } // if the media is rotated by the user, we cannot limit the position anymore
3304    // as it might need to be negative.
3305  
3306  
3307    var limitAreaFn = restrictPosition && rotation === 0 ? limitArea : noOp;
3308    var croppedAreaPercentages = {
3309      x: limitAreaFn(100, ((mediaSize.width - cropSize.width / zoom) / 2 - crop.x / zoom) / mediaSize.width * 100),
3310      y: limitAreaFn(100, ((mediaSize.height - cropSize.height / zoom) / 2 - crop.y / zoom) / mediaSize.height * 100),
3311      width: limitAreaFn(100, cropSize.width / mediaSize.width * 100 / zoom),
3312      height: limitAreaFn(100, cropSize.height / mediaSize.height * 100 / zoom)
3313    }; // we compute the pixels size naively
3314  
3315    var widthInPixels = Math.round(limitAreaFn(mediaSize.naturalWidth, croppedAreaPercentages.width * mediaSize.naturalWidth / 100));
3316    var heightInPixels = Math.round(limitAreaFn(mediaSize.naturalHeight, croppedAreaPercentages.height * mediaSize.naturalHeight / 100));
3317    var isImgWiderThanHigh = mediaSize.naturalWidth >= mediaSize.naturalHeight * aspect; // then we ensure the width and height exactly match the aspect (to avoid rounding approximations)
3318    // if the media is wider than high, when zoom is 0, the crop height will be equals to iamge height
3319    // thus we want to compute the width from the height and aspect for accuracy.
3320    // Otherwise, we compute the height from width and aspect.
3321  
3322    var sizePixels = isImgWiderThanHigh ? {
3323      width: Math.round(heightInPixels * aspect),
3324      height: heightInPixels
3325    } : {
3326      width: widthInPixels,
3327      height: Math.round(widthInPixels / aspect)
3328    };
3329  
3330    var croppedAreaPixels = __assign(__assign({}, sizePixels), {
3331      x: Math.round(limitAreaFn(mediaSize.naturalWidth - sizePixels.width, croppedAreaPercentages.x * mediaSize.naturalWidth / 100)),
3332      y: Math.round(limitAreaFn(mediaSize.naturalHeight - sizePixels.height, croppedAreaPercentages.y * mediaSize.naturalHeight / 100))
3333    });
3334  
3335    return {
3336      croppedAreaPercentages: croppedAreaPercentages,
3337      croppedAreaPixels: croppedAreaPixels
3338    };
3339  }
3340  /**

3341   * Ensure the returned value is between 0 and max

3342   */
3343  
3344  function limitArea(max, value) {
3345    return Math.min(max, Math.max(0, value));
3346  }
3347  
3348  function noOp(_max, value) {
3349    return value;
3350  }
3351  /**

3352   * Compute the crop and zoom from the croppedAreaPixels

3353   */
3354  
3355  
3356  function getZoomFromCroppedAreaPixels(croppedAreaPixels, mediaSize, cropSize) {
3357    var mediaZoom = mediaSize.width / mediaSize.naturalWidth;
3358  
3359    if (cropSize) {
3360      var isHeightMaxSize_1 = cropSize.height > cropSize.width;
3361      return isHeightMaxSize_1 ? cropSize.height / mediaZoom / croppedAreaPixels.height : cropSize.width / mediaZoom / croppedAreaPixels.width;
3362    }
3363  
3364    var aspect = croppedAreaPixels.width / croppedAreaPixels.height;
3365    var isHeightMaxSize = mediaSize.naturalWidth >= mediaSize.naturalHeight * aspect;
3366    return isHeightMaxSize ? mediaSize.naturalHeight / croppedAreaPixels.height : mediaSize.naturalWidth / croppedAreaPixels.width;
3367  }
3368  /**

3369   * Compute the crop and zoom from the croppedAreaPixels

3370   */
3371  
3372  
3373  function getInitialCropFromCroppedAreaPixels(croppedAreaPixels, mediaSize, cropSize) {
3374    var mediaZoom = mediaSize.width / mediaSize.naturalWidth;
3375    var zoom = getZoomFromCroppedAreaPixels(croppedAreaPixels, mediaSize, cropSize);
3376    var cropZoom = mediaZoom * zoom;
3377    var crop = {
3378      x: ((mediaSize.naturalWidth - croppedAreaPixels.width) / 2 - croppedAreaPixels.x) * cropZoom,
3379      y: ((mediaSize.naturalHeight - croppedAreaPixels.height) / 2 - croppedAreaPixels.y) * cropZoom
3380    };
3381    return {
3382      crop: crop,
3383      zoom: zoom
3384    };
3385  }
3386  /**

3387   * Return the point that is the center of point a and b

3388   */
3389  
3390  function getCenter(a, b) {
3391    return {
3392      x: (b.x + a.x) / 2,
3393      y: (b.y + a.y) / 2
3394    };
3395  }
3396  /**

3397   *

3398   * Returns an x,y point once rotated around xMid,yMid

3399   */
3400  
3401  function rotateAroundMidPoint(x, y, xMid, yMid, degrees) {
3402    var cos = Math.cos;
3403    var sin = Math.sin;
3404    var radian = degrees * Math.PI / 180; // Convert to radians
3405    // Subtract midpoints, so that midpoint is translated to origin
3406    // and add it in the end again
3407  
3408    var xr = (x - xMid) * cos(radian) - (y - yMid) * sin(radian) + xMid;
3409    var yr = (x - xMid) * sin(radian) + (y - yMid) * cos(radian) + yMid;
3410    return [xr, yr];
3411  }
3412  /**

3413   * Returns the new bounding area of a rotated rectangle.

3414   */
3415  
3416  function translateSize(width, height, rotation) {
3417    var centerX = width / 2;
3418    var centerY = height / 2;
3419    var outerBounds = [rotateAroundMidPoint(0, 0, centerX, centerY, rotation), rotateAroundMidPoint(width, 0, centerX, centerY, rotation), rotateAroundMidPoint(width, height, centerX, centerY, rotation), rotateAroundMidPoint(0, height, centerX, centerY, rotation)];
3420    var minX = Math.min.apply(Math, outerBounds.map(function (p) {
3421      return p[0];
3422    }));
3423    var maxX = Math.max.apply(Math, outerBounds.map(function (p) {
3424      return p[0];
3425    }));
3426    var minY = Math.min.apply(Math, outerBounds.map(function (p) {
3427      return p[1];
3428    }));
3429    var maxY = Math.max.apply(Math, outerBounds.map(function (p) {
3430      return p[1];
3431    }));
3432    return {
3433      width: maxX - minX,
3434      height: maxY - minY
3435    };
3436  }
3437  /**

3438   * Combine multiple class names into a single string.

3439   */
3440  
3441  function index_module_classNames() {
3442    var args = [];
3443  
3444    for (var _i = 0; _i < arguments.length; _i++) {
3445      args[_i] = arguments[_i];
3446    }
3447  
3448    return args.filter(function (value) {
3449      if (typeof value === 'string' && value.length > 0) {
3450        return true;
3451      }
3452  
3453      return false;
3454    }).join(' ').trim();
3455  }
3456  
3457  var css_248z = ".reactEasyCrop_Container {\n  position: absolute;\n  top: 0;\n  left: 0;\n  right: 0;\n  bottom: 0;\n  overflow: hidden;\n  user-select: none;\n  touch-action: none;\n  cursor: move;\n  display: flex;\n  justify-content: center;\n  align-items: center;\n}\n\n.reactEasyCrop_Image,\n.reactEasyCrop_Video {\n  will-change: transform; /* this improves performances and prevent painting issues on iOS Chrome */\n}\n\n.reactEasyCrop_Contain {\n  max-width: 100%;\n  max-height: 100%;\n  margin: auto;\n  position: absolute;\n  top: 0;\n  bottom: 0;\n  left: 0;\n  right: 0;\n}\n.reactEasyCrop_Cover_Horizontal {\n  width: 100%;\n  height: auto;\n}\n.reactEasyCrop_Cover_Vertical {\n  width: auto;\n  height: 100%;\n}\n\n.reactEasyCrop_CropArea {\n  position: absolute;\n  left: 50%;\n  top: 50%;\n  transform: translate(-50%, -50%);\n  border: 1px solid rgba(255, 255, 255, 0.5);\n  box-sizing: border-box;\n  box-shadow: 0 0 0 9999em;\n  color: rgba(0, 0, 0, 0.5);\n  overflow: hidden;\n}\n\n.reactEasyCrop_CropAreaRound {\n  border-radius: 50%;\n}\n\n.reactEasyCrop_CropAreaGrid::before {\n  content: ' ';\n  box-sizing: border-box;\n  position: absolute;\n  border: 1px solid rgba(255, 255, 255, 0.5);\n  top: 0;\n  bottom: 0;\n  left: 33.33%;\n  right: 33.33%;\n  border-top: 0;\n  border-bottom: 0;\n}\n\n.reactEasyCrop_CropAreaGrid::after {\n  content: ' ';\n  box-sizing: border-box;\n  position: absolute;\n  border: 1px solid rgba(255, 255, 255, 0.5);\n  top: 33.33%;\n  bottom: 33.33%;\n  left: 0;\n  right: 0;\n  border-left: 0;\n  border-right: 0;\n}\n";
3458  
3459  var MIN_ZOOM = 1;
3460  var MAX_ZOOM = 3;
3461  
3462  var index_module_Cropper =
3463  /** @class */
3464  function (_super) {
3465    __extends(Cropper, _super);
3466  
3467    function Cropper() {
3468      var _this = _super !== null && _super.apply(this, arguments) || this;
3469  
3470      _this.imageRef = null;
3471      _this.videoRef = null;
3472      _this.containerRef = null;
3473      _this.styleRef = null;
3474      _this.containerRect = null;
3475      _this.mediaSize = {
3476        width: 0,
3477        height: 0,
3478        naturalWidth: 0,
3479        naturalHeight: 0
3480      };
3481      _this.dragStartPosition = {
3482        x: 0,
3483        y: 0
3484      };
3485      _this.dragStartCrop = {
3486        x: 0,
3487        y: 0
3488      };
3489      _this.lastPinchDistance = 0;
3490      _this.lastPinchRotation = 0;
3491      _this.rafDragTimeout = null;
3492      _this.rafPinchTimeout = null;
3493      _this.wheelTimer = null;
3494      _this.state = {
3495        cropSize: null,
3496        hasWheelJustStarted: false
3497      }; // this is to prevent Safari on iOS >= 10 to zoom the page
3498  
3499      _this.preventZoomSafari = function (e) {
3500        return e.preventDefault();
3501      };
3502  
3503      _this.cleanEvents = function () {
3504        document.removeEventListener('mousemove', _this.onMouseMove);
3505        document.removeEventListener('mouseup', _this.onDragStopped);
3506        document.removeEventListener('touchmove', _this.onTouchMove);
3507        document.removeEventListener('touchend', _this.onDragStopped);
3508      };
3509  
3510      _this.clearScrollEvent = function () {
3511        if (_this.containerRef) _this.containerRef.removeEventListener('wheel', _this.onWheel);
3512  
3513        if (_this.wheelTimer) {
3514          clearTimeout(_this.wheelTimer);
3515        }
3516      };
3517  
3518      _this.onMediaLoad = function () {
3519        _this.computeSizes();
3520  
3521        _this.emitCropData();
3522  
3523        _this.setInitialCrop();
3524  
3525        if (_this.props.onMediaLoaded) {
3526          _this.props.onMediaLoaded(_this.mediaSize);
3527        }
3528      };
3529  
3530      _this.setInitialCrop = function () {
3531        var _a = _this.props,
3532            initialCroppedAreaPixels = _a.initialCroppedAreaPixels,
3533            cropSize = _a.cropSize;
3534  
3535        if (!initialCroppedAreaPixels) {
3536          return;
3537        }
3538  
3539        var _b = getInitialCropFromCroppedAreaPixels(initialCroppedAreaPixels, _this.mediaSize, cropSize),
3540            crop = _b.crop,
3541            zoom = _b.zoom;
3542  
3543        _this.props.onCropChange(crop);
3544  
3545        _this.props.onZoomChange && _this.props.onZoomChange(zoom);
3546      };
3547  
3548      _this.computeSizes = function () {
3549        var _a, _b, _c, _d, _e, _f;
3550  
3551        var mediaRef = _this.imageRef || _this.videoRef;
3552  
3553        if (mediaRef && _this.containerRef) {
3554          _this.containerRect = _this.containerRef.getBoundingClientRect();
3555          _this.mediaSize = {
3556            width: mediaRef.offsetWidth,
3557            height: mediaRef.offsetHeight,
3558            naturalWidth: ((_a = _this.imageRef) === null || _a === void 0 ? void 0 : _a.naturalWidth) || ((_b = _this.videoRef) === null || _b === void 0 ? void 0 : _b.videoWidth) || 0,
3559            naturalHeight: ((_c = _this.imageRef) === null || _c === void 0 ? void 0 : _c.naturalHeight) || ((_d = _this.videoRef) === null || _d === void 0 ? void 0 : _d.videoHeight) || 0
3560          };
3561          var cropSize = _this.props.cropSize ? _this.props.cropSize : getCropSize(mediaRef.offsetWidth, mediaRef.offsetHeight, _this.containerRect.width, _this.containerRect.height, _this.props.aspect, _this.props.rotation);
3562  
3563          if (((_e = _this.state.cropSize) === null || _e === void 0 ? void 0 : _e.height) !== cropSize.height || ((_f = _this.state.cropSize) === null || _f === void 0 ? void 0 : _f.width) !== cropSize.width) {
3564            _this.props.onCropSizeChange && _this.props.onCropSizeChange(cropSize);
3565          }
3566  
3567          _this.setState({
3568            cropSize: cropSize
3569          }, _this.recomputeCropPosition);
3570        }
3571      };
3572  
3573      _this.onMouseDown = function (e) {
3574        e.preventDefault();
3575        document.addEventListener('mousemove', _this.onMouseMove);
3576        document.addEventListener('mouseup', _this.onDragStopped);
3577  
3578        _this.onDragStart(Cropper.getMousePoint(e));
3579      };
3580  
3581      _this.onMouseMove = function (e) {
3582        return _this.onDrag(Cropper.getMousePoint(e));
3583      };
3584  
3585      _this.onTouchStart = function (e) {
3586        e.preventDefault();
3587        document.addEventListener('touchmove', _this.onTouchMove, {
3588          passive: false
3589        }); // iOS 11 now defaults to passive: true
3590  
3591        document.addEventListener('touchend', _this.onDragStopped);
3592  
3593        if (e.touches.length === 2) {
3594          _this.onPinchStart(e);
3595        } else if (e.touches.length === 1) {
3596          _this.onDragStart(Cropper.getTouchPoint(e.touches[0]));
3597        }
3598      };
3599  
3600      _this.onTouchMove = function (e) {
3601        // Prevent whole page from scrolling on iOS.
3602        e.preventDefault();
3603  
3604        if (e.touches.length === 2) {
3605          _this.onPinchMove(e);
3606        } else if (e.touches.length === 1) {
3607          _this.onDrag(Cropper.getTouchPoint(e.touches[0]));
3608        }
3609      };
3610  
3611      _this.onDragStart = function (_a) {
3612        var _b, _c;
3613  
3614        var x = _a.x,
3615            y = _a.y;
3616        _this.dragStartPosition = {
3617          x: x,
3618          y: y
3619        };
3620        _this.dragStartCrop = __assign({}, _this.props.crop);
3621        (_c = (_b = _this.props).onInteractionStart) === null || _c === void 0 ? void 0 : _c.call(_b);
3622      };
3623  
3624      _this.onDrag = function (_a) {
3625        var x = _a.x,
3626            y = _a.y;
3627        if (_this.rafDragTimeout) window.cancelAnimationFrame(_this.rafDragTimeout);
3628        _this.rafDragTimeout = window.requestAnimationFrame(function () {
3629          if (!_this.state.cropSize) return;
3630          if (x === undefined || y === undefined) return;
3631          var offsetX = x - _this.dragStartPosition.x;
3632          var offsetY = y - _this.dragStartPosition.y;
3633          var requestedPosition = {
3634            x: _this.dragStartCrop.x + offsetX,
3635            y: _this.dragStartCrop.y + offsetY
3636          };
3637          var newPosition = _this.props.restrictPosition ? index_module_restrictPosition(requestedPosition, _this.mediaSize, _this.state.cropSize, _this.props.zoom, _this.props.rotation) : requestedPosition;
3638  
3639          _this.props.onCropChange(newPosition);
3640        });
3641      };
3642  
3643      _this.onDragStopped = function () {
3644        var _a, _b;
3645  
3646        _this.cleanEvents();
3647  
3648        _this.emitCropData();
3649  
3650        (_b = (_a = _this.props).onInteractionEnd) === null || _b === void 0 ? void 0 : _b.call(_a);
3651      };
3652  
3653      _this.onWheel = function (e) {
3654        e.preventDefault();
3655        var point = Cropper.getMousePoint(e);
3656        var pixelY = normalize_wheel_default()(e).pixelY;
3657        var newZoom = _this.props.zoom - pixelY * _this.props.zoomSpeed / 200;
3658  
3659        _this.setNewZoom(newZoom, point);
3660  
3661        if (!_this.state.hasWheelJustStarted) {
3662          _this.setState({
3663            hasWheelJustStarted: true
3664          }, function () {
3665            var _a, _b;
3666  
3667            return (_b = (_a = _this.props).onInteractionStart) === null || _b === void 0 ? void 0 : _b.call(_a);
3668          });
3669        }
3670  
3671        if (_this.wheelTimer) {
3672          clearTimeout(_this.wheelTimer);
3673        }
3674  
3675        _this.wheelTimer = window.setTimeout(function () {
3676          return _this.setState({
3677            hasWheelJustStarted: false
3678          }, function () {
3679            var _a, _b;
3680  
3681            return (_b = (_a = _this.props).onInteractionEnd) === null || _b === void 0 ? void 0 : _b.call(_a);
3682          });
3683        }, 250);
3684      };
3685  
3686      _this.getPointOnContainer = function (_a) {
3687        var x = _a.x,
3688            y = _a.y;
3689  
3690        if (!_this.containerRect) {
3691          throw new Error('The Cropper is not mounted');
3692        }
3693  
3694        return {
3695          x: _this.containerRect.width / 2 - (x - _this.containerRect.left),
3696          y: _this.containerRect.height / 2 - (y - _this.containerRect.top)
3697        };
3698      };
3699  
3700      _this.getPointOnMedia = function (_a) {
3701        var x = _a.x,
3702            y = _a.y;
3703        var _b = _this.props,
3704            crop = _b.crop,
3705            zoom = _b.zoom;
3706        return {
3707          x: (x + crop.x) / zoom,
3708          y: (y + crop.y) / zoom
3709        };
3710      };
3711  
3712      _this.setNewZoom = function (zoom, point) {
3713        if (!_this.state.cropSize || !_this.props.onZoomChange) return;
3714  
3715        var zoomPoint = _this.getPointOnContainer(point);
3716  
3717        var zoomTarget = _this.getPointOnMedia(zoomPoint);
3718  
3719        var newZoom = Math.min(_this.props.maxZoom, Math.max(zoom, _this.props.minZoom));
3720        var requestedPosition = {
3721          x: zoomTarget.x * newZoom - zoomPoint.x,
3722          y: zoomTarget.y * newZoom - zoomPoint.y
3723        };
3724        var newPosition = _this.props.restrictPosition ? index_module_restrictPosition(requestedPosition, _this.mediaSize, _this.state.cropSize, newZoom, _this.props.rotation) : requestedPosition;
3725  
3726        _this.props.onCropChange(newPosition);
3727  
3728        _this.props.onZoomChange(newZoom);
3729      };
3730  
3731      _this.getCropData = function () {
3732        if (!_this.state.cropSize) {
3733          return null;
3734        } // this is to ensure the crop is correctly restricted after a zoom back (https://github.com/ricardo-ch/react-easy-crop/issues/6)
3735  
3736  
3737        var restrictedPosition = _this.props.restrictPosition ? index_module_restrictPosition(_this.props.crop, _this.mediaSize, _this.state.cropSize, _this.props.zoom, _this.props.rotation) : _this.props.crop;
3738        return computeCroppedArea(restrictedPosition, _this.mediaSize, _this.state.cropSize, _this.getAspect(), _this.props.zoom, _this.props.rotation, _this.props.restrictPosition);
3739      };
3740  
3741      _this.emitCropData = function () {
3742        var cropData = _this.getCropData();
3743  
3744        if (!cropData) return;
3745        var croppedAreaPercentages = cropData.croppedAreaPercentages,
3746            croppedAreaPixels = cropData.croppedAreaPixels;
3747  
3748        if (_this.props.onCropComplete) {
3749          _this.props.onCropComplete(croppedAreaPercentages, croppedAreaPixels);
3750        }
3751  
3752        if (_this.props.onCropAreaChange) {
3753          _this.props.onCropAreaChange(croppedAreaPercentages, croppedAreaPixels);
3754        }
3755      };
3756  
3757      _this.emitCropAreaChange = function () {
3758        var cropData = _this.getCropData();
3759  
3760        if (!cropData) return;
3761        var croppedAreaPercentages = cropData.croppedAreaPercentages,
3762            croppedAreaPixels = cropData.croppedAreaPixels;
3763  
3764        if (_this.props.onCropAreaChange) {
3765          _this.props.onCropAreaChange(croppedAreaPercentages, croppedAreaPixels);
3766        }
3767      };
3768  
3769      _this.recomputeCropPosition = function () {
3770        if (!_this.state.cropSize) return;
3771        var newPosition = _this.props.restrictPosition ? index_module_restrictPosition(_this.props.crop, _this.mediaSize, _this.state.cropSize, _this.props.zoom, _this.props.rotation) : _this.props.crop;
3772  
3773        _this.props.onCropChange(newPosition);
3774  
3775        _this.emitCropData();
3776      };
3777  
3778      return _this;
3779    }
3780  
3781    Cropper.prototype.componentDidMount = function () {
3782      window.addEventListener('resize', this.computeSizes);
3783  
3784      if (this.containerRef) {
3785        this.props.zoomWithScroll && this.containerRef.addEventListener('wheel', this.onWheel, {
3786          passive: false
3787        });
3788        this.containerRef.addEventListener('gesturestart', this.preventZoomSafari);
3789        this.containerRef.addEventListener('gesturechange', this.preventZoomSafari);
3790      }
3791  
3792      if (!this.props.disableAutomaticStylesInjection) {
3793        this.styleRef = document.createElement('style');
3794        this.styleRef.setAttribute('type', 'text/css');
3795        this.styleRef.innerHTML = css_248z;
3796        document.head.appendChild(this.styleRef);
3797      } // when rendered via SSR, the image can already be loaded and its onLoad callback will never be called
3798  
3799  
3800      if (this.imageRef && this.imageRef.complete) {
3801        this.onMediaLoad();
3802      }
3803    };
3804  
3805    Cropper.prototype.componentWillUnmount = function () {
3806      var _a;
3807  
3808      window.removeEventListener('resize', this.computeSizes);
3809  
3810      if (this.containerRef) {
3811        this.containerRef.removeEventListener('gesturestart', this.preventZoomSafari);
3812        this.containerRef.removeEventListener('gesturechange', this.preventZoomSafari);
3813      }
3814  
3815      if (this.styleRef) {
3816        (_a = this.styleRef.parentNode) === null || _a === void 0 ? void 0 : _a.removeChild(this.styleRef);
3817      }
3818  
3819      this.cleanEvents();
3820      this.props.zoomWithScroll && this.clearScrollEvent();
3821    };
3822  
3823    Cropper.prototype.componentDidUpdate = function (prevProps) {
3824      var _a, _b, _c, _d, _e, _f, _g, _h, _j;
3825  
3826      if (prevProps.rotation !== this.props.rotation) {
3827        this.computeSizes();
3828        this.recomputeCropPosition();
3829      } else if (prevProps.aspect !== this.props.aspect) {
3830        this.computeSizes();
3831      } else if (prevProps.zoom !== this.props.zoom) {
3832        this.recomputeCropPosition();
3833      } else if (((_a = prevProps.cropSize) === null || _a === void 0 ? void 0 : _a.height) !== ((_b = this.props.cropSize) === null || _b === void 0 ? void 0 : _b.height) || ((_c = prevProps.cropSize) === null || _c === void 0 ? void 0 : _c.width) !== ((_d = this.props.cropSize) === null || _d === void 0 ? void 0 : _d.width)) {
3834        this.computeSizes();
3835      } else if (((_e = prevProps.crop) === null || _e === void 0 ? void 0 : _e.x) !== ((_f = this.props.crop) === null || _f === void 0 ? void 0 : _f.x) || ((_g = prevProps.crop) === null || _g === void 0 ? void 0 : _g.y) !== ((_h = this.props.crop) === null || _h === void 0 ? void 0 : _h.y)) {
3836        this.emitCropAreaChange();
3837      }
3838  
3839      if (prevProps.zoomWithScroll !== this.props.zoomWithScroll && this.containerRef) {
3840        this.props.zoomWithScroll ? this.containerRef.addEventListener('wheel', this.onWheel, {
3841          passive: false
3842        }) : this.clearScrollEvent();
3843      }
3844  
3845      if (prevProps.video !== this.props.video) {
3846        (_j = this.videoRef) === null || _j === void 0 ? void 0 : _j.load();
3847      }
3848    };
3849  
3850    Cropper.prototype.getAspect = function () {
3851      var _a = this.props,
3852          cropSize = _a.cropSize,
3853          aspect = _a.aspect;
3854  
3855      if (cropSize) {
3856        return cropSize.width / cropSize.height;
3857      }
3858  
3859      return aspect;
3860    };
3861  
3862    Cropper.prototype.onPinchStart = function (e) {
3863      var pointA = Cropper.getTouchPoint(e.touches[0]);
3864      var pointB = Cropper.getTouchPoint(e.touches[1]);
3865      this.lastPinchDistance = getDistanceBetweenPoints(pointA, pointB);
3866      this.lastPinchRotation = getRotationBetweenPoints(pointA, pointB);
3867      this.onDragStart(getCenter(pointA, pointB));
3868    };
3869  
3870    Cropper.prototype.onPinchMove = function (e) {
3871      var _this = this;
3872  
3873      var pointA = Cropper.getTouchPoint(e.touches[0]);
3874      var pointB = Cropper.getTouchPoint(e.touches[1]);
3875      var center = getCenter(pointA, pointB);
3876      this.onDrag(center);
3877      if (this.rafPinchTimeout) window.cancelAnimationFrame(this.rafPinchTimeout);
3878      this.rafPinchTimeout = window.requestAnimationFrame(function () {
3879        var distance = getDistanceBetweenPoints(pointA, pointB);
3880        var newZoom = _this.props.zoom * (distance / _this.lastPinchDistance);
3881  
3882        _this.setNewZoom(newZoom, center);
3883  
3884        _this.lastPinchDistance = distance;
3885        var rotation = getRotationBetweenPoints(pointA, pointB);
3886        var newRotation = _this.props.rotation + (rotation - _this.lastPinchRotation);
3887        _this.props.onRotationChange && _this.props.onRotationChange(newRotation);
3888        _this.lastPinchRotation = rotation;
3889      });
3890    };
3891  
3892    Cropper.prototype.render = function () {
3893      var _this = this;
3894  
3895      var _a = this.props,
3896          image = _a.image,
3897          video = _a.video,
3898          mediaProps = _a.mediaProps,
3899          transform = _a.transform,
3900          _b = _a.crop,
3901          x = _b.x,
3902          y = _b.y,
3903          rotation = _a.rotation,
3904          zoom = _a.zoom,
3905          cropShape = _a.cropShape,
3906          showGrid = _a.showGrid,
3907          _c = _a.style,
3908          containerStyle = _c.containerStyle,
3909          cropAreaStyle = _c.cropAreaStyle,
3910          mediaStyle = _c.mediaStyle,
3911          _d = _a.classes,
3912          containerClassName = _d.containerClassName,
3913          cropAreaClassName = _d.cropAreaClassName,
3914          mediaClassName = _d.mediaClassName,
3915          objectFit = _a.objectFit;
3916      return /*#__PURE__*/external_React_default.a.createElement("div", {
3917        onMouseDown: this.onMouseDown,
3918        onTouchStart: this.onTouchStart,
3919        ref: function ref(el) {
3920          return _this.containerRef = el;
3921        },
3922        "data-testid": "container",
3923        style: containerStyle,
3924        className: index_module_classNames('reactEasyCrop_Container', containerClassName)
3925      }, image ? /*#__PURE__*/external_React_default.a.createElement("img", __assign({
3926        alt: "",
3927        className: index_module_classNames('reactEasyCrop_Image', objectFit === 'contain' && 'reactEasyCrop_Contain', objectFit === 'horizontal-cover' && 'reactEasyCrop_Cover_Horizontal', objectFit === 'vertical-cover' && 'reactEasyCrop_Cover_Vertical', mediaClassName)
3928      }, mediaProps, {
3929        src: image,
3930        ref: function ref(el) {
3931          return _this.imageRef = el;
3932        },
3933        style: __assign(__assign({}, mediaStyle), {
3934          transform: transform || "translate(" + x + "px, " + y + "px) rotate(" + rotation + "deg) scale(" + zoom + ")"
3935        }),
3936        onLoad: this.onMediaLoad
3937      })) : video && /*#__PURE__*/external_React_default.a.createElement("video", __assign({
3938        autoPlay: true,
3939        loop: true,
3940        muted: true,
3941        className: index_module_classNames('reactEasyCrop_Video', objectFit === 'contain' && 'reactEasyCrop_Contain', objectFit === 'horizontal-cover' && 'reactEasyCrop_Cover_Horizontal', objectFit === 'vertical-cover' && 'reactEasyCrop_Cover_Vertical', mediaClassName)
3942      }, mediaProps, {
3943        ref: function ref(el) {
3944          return _this.videoRef = el;
3945        },
3946        onLoadedMetadata: this.onMediaLoad,
3947        style: __assign(__assign({}, mediaStyle), {
3948          transform: transform || "translate(" + x + "px, " + y + "px) rotate(" + rotation + "deg) scale(" + zoom + ")"
3949        }),
3950        controls: false
3951      }), (Array.isArray(video) ? video : [{
3952        src: video
3953      }]).map(function (item) {
3954        return /*#__PURE__*/external_React_default.a.createElement("source", __assign({
3955          key: item.src
3956        }, item));
3957      })), this.state.cropSize && /*#__PURE__*/external_React_default.a.createElement("div", {
3958        style: __assign(__assign({}, cropAreaStyle), {
3959          width: this.state.cropSize.width,
3960          height: this.state.cropSize.height
3961        }),
3962        "data-testid": "cropper",
3963        className: index_module_classNames('reactEasyCrop_CropArea', cropShape === 'round' && 'reactEasyCrop_CropAreaRound', showGrid && 'reactEasyCrop_CropAreaGrid', cropAreaClassName)
3964      }));
3965    };
3966  
3967    Cropper.defaultProps = {
3968      zoom: 1,
3969      rotation: 0,
3970      aspect: 4 / 3,
3971      maxZoom: MAX_ZOOM,
3972      minZoom: MIN_ZOOM,
3973      cropShape: 'rect',
3974      objectFit: 'contain',
3975      showGrid: true,
3976      style: {},
3977      classes: {},
3978      mediaProps: {},
3979      zoomSpeed: 1,
3980      restrictPosition: true,
3981      zoomWithScroll: true
3982    };
3983  
3984    Cropper.getMousePoint = function (e) {
3985      return {
3986        x: Number(e.clientX),
3987        y: Number(e.clientY)
3988      };
3989    };
3990  
3991    Cropper.getTouchPoint = function (touch) {
3992      return {
3993        x: Number(touch.clientX),
3994        y: Number(touch.clientY)
3995      };
3996    };
3997  
3998    return Cropper;
3999  }(external_React_default.a.Component);
4000  
4001  /* harmony default export */ var index_module = (index_module_Cropper);
4002  
4003  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/constants.js
4004  const constants_MIN_ZOOM = 100;
4005  const constants_MAX_ZOOM = 300;
4006  const constants_POPOVER_PROPS = {
4007    position: 'bottom right',
4008    isAlternate: true
4009  };
4010  
4011  // EXTERNAL MODULE: external ["wp","apiFetch"]
4012  var external_wp_apiFetch_ = __webpack_require__("ywyh");
4013  var external_wp_apiFetch_default = /*#__PURE__*/__webpack_require__.n(external_wp_apiFetch_);
4014  
4015  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/use-save-image.js
4016  /**
4017   * WordPress dependencies
4018   */
4019  
4020  
4021  
4022  
4023  
4024  function useSaveImage({
4025    crop,
4026    rotation,
4027    height,
4028    width,
4029    aspect,
4030    url,
4031    id,
4032    onSaveImage,
4033    onFinishEditing
4034  }) {
4035    const {
4036      createErrorNotice
4037    } = Object(external_wp_data_["useDispatch"])(external_wp_notices_["store"]);
4038    const [isInProgress, setIsInProgress] = Object(external_wp_element_["useState"])(false);
4039    const cancel = Object(external_wp_element_["useCallback"])(() => {
4040      setIsInProgress(false);
4041      onFinishEditing();
4042    }, [setIsInProgress, onFinishEditing]);
4043    const apply = Object(external_wp_element_["useCallback"])(() => {
4044      setIsInProgress(true);
4045      let attrs = {}; // The crop script may return some very small, sub-pixel values when the image was not cropped.
4046      // Crop only when the new size has changed by more than 0.1%.
4047  
4048      if (crop.width < 99.9 || crop.height < 99.9) {
4049        attrs = crop;
4050      }
4051  
4052      if (rotation > 0) {
4053        attrs.rotation = rotation;
4054      }
4055  
4056      attrs.src = url;
4057      external_wp_apiFetch_default()({
4058        path: `/wp/v2/media/$id}/edit`,
4059        method: 'POST',
4060        data: attrs
4061      }).then(response => {
4062        onSaveImage({
4063          id: response.id,
4064          url: response.source_url,
4065          height: height && width ? width / aspect : undefined
4066        });
4067      }).catch(error => {
4068        createErrorNotice(Object(external_wp_i18n_["sprintf"])(
4069        /* translators: 1. Error message */
4070        Object(external_wp_i18n_["__"])('Could not edit image. %s'), error.message), {
4071          id: 'image-editing-error',
4072          type: 'snackbar'
4073        });
4074      }).finally(() => {
4075        setIsInProgress(false);
4076        onFinishEditing();
4077      });
4078    }, [setIsInProgress, crop, rotation, height, width, aspect, url, onSaveImage, createErrorNotice, setIsInProgress, onFinishEditing]);
4079    return Object(external_wp_element_["useMemo"])(() => ({
4080      isInProgress,
4081      apply,
4082      cancel
4083    }), [isInProgress, apply, cancel]);
4084  }
4085  
4086  // EXTERNAL MODULE: external ["wp","hooks"]
4087  var external_wp_hooks_ = __webpack_require__("g56x");
4088  
4089  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/use-transform-image.js
4090  /**
4091   * WordPress dependencies
4092   */
4093  
4094  
4095  
4096  function useTransformState({
4097    url,
4098    naturalWidth,
4099    naturalHeight
4100  }) {
4101    const [editedUrl, setEditedUrl] = Object(external_wp_element_["useState"])();
4102    const [crop, setCrop] = Object(external_wp_element_["useState"])();
4103    const [position, setPosition] = Object(external_wp_element_["useState"])({
4104      x: 0,
4105      y: 0
4106    });
4107    const [zoom, setZoom] = Object(external_wp_element_["useState"])();
4108    const [rotation, setRotation] = Object(external_wp_element_["useState"])();
4109    const [aspect, setAspect] = Object(external_wp_element_["useState"])();
4110    const [defaultAspect, setDefaultAspect] = Object(external_wp_element_["useState"])();
4111    const initializeTransformValues = Object(external_wp_element_["useCallback"])(() => {
4112      setPosition({
4113        x: 0,
4114        y: 0
4115      });
4116      setZoom(100);
4117      setRotation(0);
4118      setAspect(naturalWidth / naturalHeight);
4119      setDefaultAspect(naturalWidth / naturalHeight);
4120    }, [naturalWidth, naturalHeight, setPosition, setZoom, setRotation, setAspect, setDefaultAspect]);
4121    const rotateClockwise = Object(external_wp_element_["useCallback"])(() => {
4122      const angle = (rotation + 90) % 360;
4123      let naturalAspectRatio = naturalWidth / naturalHeight;
4124  
4125      if (rotation % 180 === 90) {
4126        naturalAspectRatio = naturalHeight / naturalWidth;
4127      }
4128  
4129      if (angle === 0) {
4130        setEditedUrl();
4131        setRotation(angle);
4132        setAspect(1 / aspect);
4133        setPosition({
4134          x: -(position.y * naturalAspectRatio),
4135          y: position.x * naturalAspectRatio
4136        });
4137        return;
4138      }
4139  
4140      function editImage(event) {
4141        const canvas = document.createElement('canvas');
4142        let translateX = 0;
4143        let translateY = 0;
4144  
4145        if (angle % 180) {
4146          canvas.width = event.target.height;
4147          canvas.height = event.target.width;
4148        } else {
4149          canvas.width = event.target.width;
4150          canvas.height = event.target.height;
4151        }
4152  
4153        if (angle === 90 || angle === 180) {
4154          translateX = canvas.width;
4155        }
4156  
4157        if (angle === 270 || angle === 180) {
4158          translateY = canvas.height;
4159        }
4160  
4161        const context = canvas.getContext('2d');
4162        context.translate(translateX, translateY);
4163        context.rotate(angle * Math.PI / 180);
4164        context.drawImage(event.target, 0, 0);
4165        canvas.toBlob(blob => {
4166          setEditedUrl(URL.createObjectURL(blob));
4167          setRotation(angle);
4168          setAspect(1 / aspect);
4169          setPosition({
4170            x: -(position.y * naturalAspectRatio),
4171            y: position.x * naturalAspectRatio
4172          });
4173        });
4174      }
4175  
4176      const el = new window.Image();
4177      el.src = url;
4178      el.onload = editImage;
4179      const imgCrossOrigin = Object(external_wp_hooks_["applyFilters"])('media.crossOrigin', undefined, url);
4180  
4181      if (typeof imgCrossOrigin === 'string') {
4182        el.crossOrigin = imgCrossOrigin;
4183      }
4184    }, [rotation, naturalWidth, naturalHeight, setEditedUrl, setRotation, setAspect, setPosition]);
4185    return Object(external_wp_element_["useMemo"])(() => ({
4186      editedUrl,
4187      setEditedUrl,
4188      crop,
4189      setCrop,
4190      position,
4191      setPosition,
4192      zoom,
4193      setZoom,
4194      rotation,
4195      setRotation,
4196      rotateClockwise,
4197      aspect,
4198      setAspect,
4199      defaultAspect,
4200      initializeTransformValues
4201    }), [editedUrl, setEditedUrl, crop, setCrop, position, setPosition, zoom, setZoom, rotation, setRotation, rotateClockwise, aspect, setAspect, defaultAspect, initializeTransformValues]);
4202  }
4203  
4204  function useTransformImage(imageProperties, isEditing) {
4205    const transformState = useTransformState(imageProperties);
4206    const {
4207      initializeTransformValues
4208    } = transformState;
4209    Object(external_wp_element_["useEffect"])(() => {
4210      if (isEditing) {
4211        initializeTransformValues();
4212      }
4213    }, [isEditing, initializeTransformValues]);
4214    return transformState;
4215  }
4216  
4217  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/context.js
4218  
4219  
4220  /**
4221   * WordPress dependencies
4222   */
4223  
4224  /**
4225   * Internal dependencies
4226   */
4227  
4228  
4229  
4230  const ImageEditingContext = Object(external_wp_element_["createContext"])({});
4231  const useImageEditingContext = () => Object(external_wp_element_["useContext"])(ImageEditingContext);
4232  function ImageEditingProvider({
4233    id,
4234    url,
4235    naturalWidth,
4236    naturalHeight,
4237    isEditing,
4238    onFinishEditing,
4239    onSaveImage,
4240    children
4241  }) {
4242    const transformImage = useTransformImage({
4243      url,
4244      naturalWidth,
4245      naturalHeight
4246    }, isEditing);
4247    const saveImage = useSaveImage({
4248      id,
4249      url,
4250      onSaveImage,
4251      onFinishEditing,
4252      ...transformImage
4253    });
4254    const providerValue = Object(external_wp_element_["useMemo"])(() => ({ ...transformImage,
4255      ...saveImage
4256    }), [transformImage, saveImage]);
4257    return Object(external_wp_element_["createElement"])(ImageEditingContext.Provider, {
4258      value: providerValue
4259    }, children);
4260  }
4261  
4262  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/cropper.js
4263  
4264  
4265  /**
4266   * External dependencies
4267   */
4268  
4269  
4270  /**
4271   * WordPress dependencies
4272   */
4273  
4274  
4275  /**
4276   * Internal dependencies
4277   */
4278  
4279  
4280  
4281  function ImageCropper({
4282    url,
4283    width,
4284    height,
4285    clientWidth,
4286    naturalHeight,
4287    naturalWidth
4288  }) {
4289    const {
4290      isInProgress,
4291      editedUrl,
4292      position,
4293      zoom,
4294      aspect,
4295      setPosition,
4296      setCrop,
4297      setZoom,
4298      rotation
4299    } = useImageEditingContext();
4300    let editedHeight = height || clientWidth * naturalHeight / naturalWidth;
4301  
4302    if (rotation % 180 === 90) {
4303      editedHeight = clientWidth * naturalWidth / naturalHeight;
4304    }
4305  
4306    return Object(external_wp_element_["createElement"])("div", {
4307      className: classnames_default()('wp-block-image__crop-area', {
4308        'is-applying': isInProgress
4309      }),
4310      style: {
4311        width: width || clientWidth,
4312        height: editedHeight
4313      }
4314    }, Object(external_wp_element_["createElement"])(index_module, {
4315      image: editedUrl || url,
4316      disabled: isInProgress,
4317      minZoom: constants_MIN_ZOOM / 100,
4318      maxZoom: constants_MAX_ZOOM / 100,
4319      crop: position,
4320      zoom: zoom / 100,
4321      aspect: aspect,
4322      onCropChange: setPosition,
4323      onCropComplete: newCropPercent => {
4324        setCrop(newCropPercent);
4325      },
4326      onZoomChange: newZoom => {
4327        setZoom(newZoom * 100);
4328      }
4329    }), isInProgress && Object(external_wp_element_["createElement"])(external_wp_components_["Spinner"], null));
4330  }
4331  
4332  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/search.js
4333  var library_search = __webpack_require__("cGtP");
4334  
4335  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/zoom-dropdown.js
4336  
4337  
4338  /**
4339   * WordPress dependencies
4340   */
4341  
4342  
4343  
4344  /**
4345   * Internal dependencies
4346   */
4347  
4348  
4349  
4350  function ZoomDropdown() {
4351    const {
4352      isInProgress,
4353      zoom,
4354      setZoom
4355    } = useImageEditingContext();
4356    return Object(external_wp_element_["createElement"])(external_wp_components_["Dropdown"], {
4357      contentClassName: "wp-block-image__zoom",
4358      popoverProps: constants_POPOVER_PROPS,
4359      renderToggle: ({
4360        isOpen,
4361        onToggle
4362      }) => Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
4363        icon: library_search["a" /* default */],
4364        label: Object(external_wp_i18n_["__"])('Zoom'),
4365        onClick: onToggle,
4366        "aria-expanded": isOpen,
4367        disabled: isInProgress
4368      }),
4369      renderContent: () => Object(external_wp_element_["createElement"])(external_wp_components_["RangeControl"], {
4370        label: Object(external_wp_i18n_["__"])('Zoom'),
4371        min: constants_MIN_ZOOM,
4372        max: constants_MAX_ZOOM,
4373        value: Math.round(zoom),
4374        onChange: setZoom
4375      })
4376    });
4377  }
4378  
4379  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/check.js
4380  var check = __webpack_require__("RMJe");
4381  
4382  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/aspect-ratio.js
4383  
4384  
4385  /**
4386   * WordPress dependencies
4387   */
4388  
4389  const aspect_ratio_aspectRatio = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
4390    xmlns: "http://www.w3.org/2000/svg",
4391    viewBox: "0 0 24 24"
4392  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
4393    d: "M18.5 5.5h-13c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h13c1.1 0 2-.9 2-2v-9c0-1.1-.9-2-2-2zm.5 11c0 .3-.2.5-.5.5h-13c-.3 0-.5-.2-.5-.5v-9c0-.3.2-.5.5-.5h13c.3 0 .5.2.5.5v9zM6.5 12H8v-2h2V8.5H6.5V12zm9.5 2h-2v1.5h3.5V12H16v2z"
4394  }));
4395  /* harmony default export */ var aspect_ratio = (aspect_ratio_aspectRatio);
4396  
4397  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/aspect-ratio-dropdown.js
4398  
4399  
4400  /**
4401   * WordPress dependencies
4402   */
4403  
4404  
4405  
4406  /**
4407   * Internal dependencies
4408   */
4409  
4410  
4411  
4412  
4413  function AspectGroup({
4414    aspectRatios,
4415    isDisabled,
4416    label,
4417    onClick,
4418    value
4419  }) {
4420    return Object(external_wp_element_["createElement"])(external_wp_components_["MenuGroup"], {
4421      label: label
4422    }, aspectRatios.map(({
4423      title,
4424      aspect
4425    }) => Object(external_wp_element_["createElement"])(external_wp_components_["MenuItem"], {
4426      key: aspect,
4427      disabled: isDisabled,
4428      onClick: () => {
4429        onClick(aspect);
4430      },
4431      role: "menuitemradio",
4432      isSelected: aspect === value,
4433      icon: aspect === value ? check["a" /* default */] : undefined
4434    }, title)));
4435  }
4436  
4437  function AspectRatioDropdown({
4438    toggleProps
4439  }) {
4440    const {
4441      isInProgress,
4442      aspect,
4443      setAspect,
4444      defaultAspect
4445    } = useImageEditingContext();
4446    return Object(external_wp_element_["createElement"])(external_wp_components_["DropdownMenu"], {
4447      icon: aspect_ratio,
4448      label: Object(external_wp_i18n_["__"])('Aspect Ratio'),
4449      popoverProps: constants_POPOVER_PROPS,
4450      toggleProps: toggleProps,
4451      className: "wp-block-image__aspect-ratio"
4452    }, ({
4453      onClose
4454    }) => Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(AspectGroup, {
4455      isDisabled: isInProgress,
4456      onClick: newAspect => {
4457        setAspect(newAspect);
4458        onClose();
4459      },
4460      value: aspect,
4461      aspectRatios: [{
4462        title: Object(external_wp_i18n_["__"])('Original'),
4463        aspect: defaultAspect
4464      }, {
4465        title: Object(external_wp_i18n_["__"])('Square'),
4466        aspect: 1
4467      }]
4468    }), Object(external_wp_element_["createElement"])(AspectGroup, {
4469      label: Object(external_wp_i18n_["__"])('Landscape'),
4470      isDisabled: isInProgress,
4471      onClick: newAspect => {
4472        setAspect(newAspect);
4473        onClose();
4474      },
4475      value: aspect,
4476      aspectRatios: [{
4477        title: Object(external_wp_i18n_["__"])('16:10'),
4478        aspect: 16 / 10
4479      }, {
4480        title: Object(external_wp_i18n_["__"])('16:9'),
4481        aspect: 16 / 9
4482      }, {
4483        title: Object(external_wp_i18n_["__"])('4:3'),
4484        aspect: 4 / 3
4485      }, {
4486        title: Object(external_wp_i18n_["__"])('3:2'),
4487        aspect: 3 / 2
4488      }]
4489    }), Object(external_wp_element_["createElement"])(AspectGroup, {
4490      label: Object(external_wp_i18n_["__"])('Portrait'),
4491      isDisabled: isInProgress,
4492      onClick: newAspect => {
4493        setAspect(newAspect);
4494        onClose();
4495      },
4496      value: aspect,
4497      aspectRatios: [{
4498        title: Object(external_wp_i18n_["__"])('10:16'),
4499        aspect: 10 / 16
4500      }, {
4501        title: Object(external_wp_i18n_["__"])('9:16'),
4502        aspect: 9 / 16
4503      }, {
4504        title: Object(external_wp_i18n_["__"])('3:4'),
4505        aspect: 3 / 4
4506      }, {
4507        title: Object(external_wp_i18n_["__"])('2:3'),
4508        aspect: 2 / 3
4509      }]
4510    })));
4511  }
4512  
4513  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/rotate-right.js
4514  
4515  
4516  /**
4517   * WordPress dependencies
4518   */
4519  
4520  const rotateRight = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
4521    xmlns: "http://www.w3.org/2000/svg",
4522    viewBox: "0 0 24 24"
4523  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
4524    d: "M15.1 4.8l-3-2.5V4c-4.4 0-8 3.6-8 8 0 3.7 2.5 6.9 6 7.7.3.1.6.1 1 .2l.2-1.5c-.4 0-.7-.1-1.1-.2l-.1.2v-.2c-2.6-.8-4.5-3.3-4.5-6.2 0-3.6 2.9-6.5 6.5-6.5v1.8l3-2.5zM20 11c-.2-1.4-.7-2.7-1.6-3.8l-1.2.8c.7.9 1.1 2 1.3 3.1L20 11zm-1.5 1.8c-.1.5-.2 1.1-.4 1.6s-.5 1-.8 1.5l1.2.9c.4-.5.8-1.1 1-1.8s.5-1.3.5-2l-1.5-.2zm-5.6 5.6l.2 1.5c1.4-.2 2.7-.7 3.8-1.6l-.9-1.1c-.9.7-2 1.1-3.1 1.2z"
4525  }));
4526  /* harmony default export */ var rotate_right = (rotateRight);
4527  
4528  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/rotation-button.js
4529  
4530  
4531  /**
4532   * WordPress dependencies
4533   */
4534  
4535  
4536  
4537  /**
4538   * Internal dependencies
4539   */
4540  
4541  
4542  function RotationButton() {
4543    const {
4544      isInProgress,
4545      rotateClockwise
4546    } = useImageEditingContext();
4547    return Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
4548      icon: rotate_right,
4549      label: Object(external_wp_i18n_["__"])('Rotate'),
4550      onClick: rotateClockwise,
4551      disabled: isInProgress
4552    });
4553  }
4554  
4555  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/form-controls.js
4556  
4557  
4558  /**
4559   * WordPress dependencies
4560   */
4561  
4562  
4563  /**
4564   * Internal dependencies
4565   */
4566  
4567  
4568  function FormControls() {
4569    const {
4570      isInProgress,
4571      apply,
4572      cancel
4573    } = useImageEditingContext();
4574    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
4575      onClick: apply,
4576      disabled: isInProgress
4577    }, Object(external_wp_i18n_["__"])('Apply')), Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
4578      onClick: cancel
4579    }, Object(external_wp_i18n_["__"])('Cancel')));
4580  }
4581  
4582  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image-editing/index.js
4583  
4584  
4585  /**
4586   * WordPress dependencies
4587   */
4588  
4589  
4590  /**
4591   * Internal dependencies
4592   */
4593  
4594  
4595  
4596  
4597  
4598  
4599  function ImageEditor({
4600    url,
4601    width,
4602    height,
4603    clientWidth,
4604    naturalHeight,
4605    naturalWidth
4606  }) {
4607    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(ImageCropper, {
4608      url: url,
4609      width: width,
4610      height: height,
4611      clientWidth: clientWidth,
4612      naturalHeight: naturalHeight,
4613      naturalWidth: naturalWidth
4614    }), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockControls"], null, Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarGroup"], null, Object(external_wp_element_["createElement"])(ZoomDropdown, null), Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarItem"], null, toggleProps => Object(external_wp_element_["createElement"])(AspectRatioDropdown, {
4615      toggleProps: toggleProps
4616    })), Object(external_wp_element_["createElement"])(RotationButton, null)), Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarGroup"], null, Object(external_wp_element_["createElement"])(FormControls, null))));
4617  }
4618  
4619  
4620  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/constants.js
4621  const MIN_SIZE = 20;
4622  const LINK_DESTINATION_NONE = 'none';
4623  const LINK_DESTINATION_MEDIA = 'media';
4624  const LINK_DESTINATION_ATTACHMENT = 'attachment';
4625  const LINK_DESTINATION_CUSTOM = 'custom';
4626  const NEW_TAB_REL = ['noreferrer', 'noopener'];
4627  const ALLOWED_MEDIA_TYPES = ['image'];
4628  
4629  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/image.js
4630  
4631  
4632  /**
4633   * External dependencies
4634   */
4635  
4636  /**
4637   * WordPress dependencies
4638   */
4639  
4640  
4641  
4642  
4643  
4644  
4645  
4646  
4647  
4648  
4649  
4650  
4651  
4652  /**
4653   * Internal dependencies
4654   */
4655  
4656  
4657  
4658  
4659  
4660  /**
4661   * Module constants
4662   */
4663  
4664  
4665  
4666  function getFilename(url) {
4667    const path = Object(external_wp_url_["getPath"])(url);
4668  
4669    if (path) {
4670      return Object(external_lodash_["last"])(path.split('/'));
4671    }
4672  }
4673  
4674  function Image({
4675    temporaryURL,
4676    attributes: {
4677      url = '',
4678      alt,
4679      caption,
4680      align,
4681      id,
4682      href,
4683      rel,
4684      linkClass,
4685      linkDestination,
4686      title,
4687      width,
4688      height,
4689      linkTarget,
4690      sizeSlug
4691    },
4692    setAttributes,
4693    isSelected,
4694    insertBlocksAfter,
4695    onReplace,
4696    onSelectImage,
4697    onSelectURL,
4698    onUploadError,
4699    containerRef,
4700    clientId
4701  }) {
4702    const captionRef = Object(external_wp_element_["useRef"])();
4703    const prevUrl = Object(external_wp_compose_["usePrevious"])(url);
4704    const {
4705      getBlock
4706    } = Object(external_wp_data_["useSelect"])(external_wp_blockEditor_["store"]);
4707    const {
4708      image,
4709      multiImageSelection
4710    } = Object(external_wp_data_["useSelect"])(select => {
4711      const {
4712        getMedia
4713      } = select(external_wp_coreData_["store"]);
4714      const {
4715        getMultiSelectedBlockClientIds,
4716        getBlockName
4717      } = select(external_wp_blockEditor_["store"]);
4718      const multiSelectedClientIds = getMultiSelectedBlockClientIds();
4719      return {
4720        image: id && isSelected ? getMedia(id) : null,
4721        multiImageSelection: multiSelectedClientIds.length && multiSelectedClientIds.every(_clientId => getBlockName(_clientId) === 'core/image')
4722      };
4723    }, [id, isSelected]);
4724    const {
4725      imageEditing,
4726      imageSizes,
4727      maxWidth,
4728      mediaUpload
4729    } = Object(external_wp_data_["useSelect"])(select => {
4730      const {
4731        getSettings
4732      } = select(external_wp_blockEditor_["store"]);
4733      return Object(external_lodash_["pick"])(getSettings(), ['imageEditing', 'imageSizes', 'maxWidth', 'mediaUpload']);
4734    });
4735    const {
4736      replaceBlocks,
4737      toggleSelection
4738    } = Object(external_wp_data_["useDispatch"])(external_wp_blockEditor_["store"]);
4739    const {
4740      createErrorNotice,
4741      createSuccessNotice
4742    } = Object(external_wp_data_["useDispatch"])(external_wp_notices_["store"]);
4743    const isLargeViewport = Object(external_wp_compose_["useViewportMatch"])('medium');
4744    const isWideAligned = Object(external_lodash_["includes"])(['wide', 'full'], align);
4745    const [{
4746      naturalWidth,
4747      naturalHeight
4748    }, setNaturalSize] = Object(external_wp_element_["useState"])({});
4749    const [isEditingImage, setIsEditingImage] = Object(external_wp_element_["useState"])(false);
4750    const [externalBlob, setExternalBlob] = Object(external_wp_element_["useState"])();
4751    const clientWidth = useClientWidth(containerRef, [align]);
4752    const isResizable = !isWideAligned && isLargeViewport;
4753    const imageSizeOptions = Object(external_lodash_["map"])(Object(external_lodash_["filter"])(imageSizes, ({
4754      slug
4755    }) => Object(external_lodash_["get"])(image, ['media_details', 'sizes', slug, 'source_url'])), ({
4756      name,
4757      slug
4758    }) => ({
4759      value: slug,
4760      label: name
4761    })); // Check if the cover block is registered.
4762  
4763    const coverBlockExists = !!Object(external_wp_blocks_["getBlockType"])('core/cover'); // If an image is externally hosted, try to fetch the image data. This may
4764    // fail if the image host doesn't allow CORS with the domain. If it works,
4765    // we can enable a button in the toolbar to upload the image.
4766  
4767    Object(external_wp_element_["useEffect"])(() => {
4768      if (!isExternalImage(id, url) || !isSelected || externalBlob) {
4769        return;
4770      }
4771  
4772      window.fetch(url).then(response => response.blob()).then(blob => setExternalBlob(blob));
4773    }, [id, url, isSelected, externalBlob]); // Focus the caption after inserting an image from the placeholder. This is
4774    // done to preserve the behaviour of focussing the first tabbable element
4775    // when a block is mounted. Previously, the image block would remount when
4776    // the placeholder is removed. Maybe this behaviour could be removed.
4777  
4778    Object(external_wp_element_["useEffect"])(() => {
4779      if (url && !prevUrl && isSelected) {
4780        captionRef.current.focus();
4781      }
4782    }, [url, prevUrl]);
4783  
4784    function onResizeStart() {
4785      toggleSelection(false);
4786    }
4787  
4788    function onResizeStop() {
4789      toggleSelection(true);
4790    }
4791  
4792    function onImageError() {
4793      // Check if there's an embed block that handles this URL.
4794      const embedBlock = createUpgradedEmbedBlock({
4795        attributes: {
4796          url
4797        }
4798      });
4799  
4800      if (undefined !== embedBlock) {
4801        onReplace(embedBlock);
4802      }
4803    }
4804  
4805    function onSetHref(props) {
4806      setAttributes(props);
4807    }
4808  
4809    function onSetTitle(value) {
4810      // This is the HTML title attribute, separate from the media object
4811      // title.
4812      setAttributes({
4813        title: value
4814      });
4815    }
4816  
4817    function updateAlt(newAlt) {
4818      setAttributes({
4819        alt: newAlt
4820      });
4821    }
4822  
4823    function updateImage(newSizeSlug) {
4824      const newUrl = Object(external_lodash_["get"])(image, ['media_details', 'sizes', newSizeSlug, 'source_url']);
4825  
4826      if (!newUrl) {
4827        return null;
4828      }
4829  
4830      setAttributes({
4831        url: newUrl,
4832        width: undefined,
4833        height: undefined,
4834        sizeSlug: newSizeSlug
4835      });
4836    }
4837  
4838    function uploadExternal() {
4839      mediaUpload({
4840        filesList: [externalBlob],
4841  
4842        onFileChange([img]) {
4843          onSelectImage(img);
4844  
4845          if (Object(external_wp_blob_["isBlobURL"])(img.url)) {
4846            return;
4847          }
4848  
4849          setExternalBlob();
4850          createSuccessNotice(Object(external_wp_i18n_["__"])('Image uploaded.'), {
4851            type: 'snackbar'
4852          });
4853        },
4854  
4855        allowedTypes: ALLOWED_MEDIA_TYPES,
4856  
4857        onError(message) {
4858          createErrorNotice(message, {
4859            type: 'snackbar'
4860          });
4861        }
4862  
4863      });
4864    }
4865  
4866    function updateAlignment(nextAlign) {
4867      const extraUpdatedAttributes = ['wide', 'full'].includes(nextAlign) ? {
4868        width: undefined,
4869        height: undefined
4870      } : {};
4871      setAttributes({ ...extraUpdatedAttributes,
4872        align: nextAlign
4873      });
4874    }
4875  
4876    Object(external_wp_element_["useEffect"])(() => {
4877      if (!isSelected) {
4878        setIsEditingImage(false);
4879      }
4880    }, [isSelected]);
4881    const canEditImage = id && naturalWidth && naturalHeight && imageEditing;
4882    const allowCrop = !multiImageSelection && canEditImage && !isEditingImage;
4883  
4884    function switchToCover() {
4885      replaceBlocks(clientId, Object(external_wp_blocks_["switchToBlockType"])(getBlock(clientId), 'core/cover'));
4886    }
4887  
4888    const controls = Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockControls"], {
4889      group: "block"
4890    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockAlignmentControl"], {
4891      value: align,
4892      onChange: updateAlignment
4893    }), !multiImageSelection && !isEditingImage && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["__experimentalImageURLInputUI"], {
4894      url: href || '',
4895      onChangeUrl: onSetHref,
4896      linkDestination: linkDestination,
4897      mediaUrl: image && image.source_url || url,
4898      mediaLink: image && image.link,
4899      linkTarget: linkTarget,
4900      linkClass: linkClass,
4901      rel: rel
4902    }), allowCrop && Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
4903      onClick: () => setIsEditingImage(true),
4904      icon: library_crop,
4905      label: Object(external_wp_i18n_["__"])('Crop')
4906    }), externalBlob && Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
4907      onClick: uploadExternal,
4908      icon: upload["a" /* default */],
4909      label: Object(external_wp_i18n_["__"])('Upload external image')
4910    }), !multiImageSelection && coverBlockExists && Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
4911      icon: overlay_text,
4912      label: Object(external_wp_i18n_["__"])('Add text over image'),
4913      onClick: switchToCover
4914    })), !multiImageSelection && !isEditingImage && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockControls"], {
4915      group: "other"
4916    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["MediaReplaceFlow"], {
4917      mediaId: id,
4918      mediaURL: url,
4919      allowedTypes: ALLOWED_MEDIA_TYPES,
4920      accept: "image/*",
4921      onSelect: onSelectImage,
4922      onSelectURL: onSelectURL,
4923      onError: onUploadError
4924    })), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["InspectorControls"], null, Object(external_wp_element_["createElement"])(external_wp_components_["PanelBody"], {
4925      title: Object(external_wp_i18n_["__"])('Image settings')
4926    }, !multiImageSelection && Object(external_wp_element_["createElement"])(external_wp_components_["TextareaControl"], {
4927      label: Object(external_wp_i18n_["__"])('Alt text (alternative text)'),
4928      value: alt,
4929      onChange: updateAlt,
4930      help: Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_components_["ExternalLink"], {
4931        href: "https://www.w3.org/WAI/tutorials/images/decision-tree"
4932      }, Object(external_wp_i18n_["__"])('Describe the purpose of the image')), Object(external_wp_i18n_["__"])('Leave empty if the image is purely decorative.'))
4933    }), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["__experimentalImageSizeControl"], {
4934      onChangeImage: updateImage,
4935      onChange: value => setAttributes(value),
4936      slug: sizeSlug,
4937      width: width,
4938      height: height,
4939      imageSizeOptions: imageSizeOptions,
4940      isResizable: isResizable,
4941      imageWidth: naturalWidth,
4942      imageHeight: naturalHeight
4943    }))), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["InspectorAdvancedControls"], null, Object(external_wp_element_["createElement"])(external_wp_components_["TextControl"], {
4944      label: Object(external_wp_i18n_["__"])('Title attribute'),
4945      value: title || '',
4946      onChange: onSetTitle,
4947      help: Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_i18n_["__"])('Describe the role of this image on the page.'), Object(external_wp_element_["createElement"])(external_wp_components_["ExternalLink"], {
4948        href: "https://www.w3.org/TR/html52/dom.html#the-title-attribute"
4949      }, Object(external_wp_i18n_["__"])('(Note: many devices and browsers do not display this text.)')))
4950    })));
4951    const filename = getFilename(url);
4952    let defaultedAlt;
4953  
4954    if (alt) {
4955      defaultedAlt = alt;
4956    } else if (filename) {
4957      defaultedAlt = Object(external_wp_i18n_["sprintf"])(
4958      /* translators: %s: file name */
4959      Object(external_wp_i18n_["__"])('This image has an empty alt attribute; its file name is %s'), filename);
4960    } else {
4961      defaultedAlt = Object(external_wp_i18n_["__"])('This image has an empty alt attribute');
4962    }
4963  
4964    let img = // Disable reason: Image itself is not meant to be interactive, but
4965    // should direct focus to block.
4966  
4967    /* eslint-disable jsx-a11y/no-noninteractive-element-interactions, jsx-a11y/click-events-have-key-events */
4968    Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])("img", {
4969      src: temporaryURL || url,
4970      alt: defaultedAlt,
4971      onError: () => onImageError(),
4972      onLoad: event => {
4973        setNaturalSize(Object(external_lodash_["pick"])(event.target, ['naturalWidth', 'naturalHeight']));
4974      }
4975    }), temporaryURL && Object(external_wp_element_["createElement"])(external_wp_components_["Spinner"], null))
4976    /* eslint-enable jsx-a11y/no-noninteractive-element-interactions, jsx-a11y/click-events-have-key-events */
4977    ;
4978    let imageWidthWithinContainer;
4979    let imageHeightWithinContainer;
4980  
4981    if (clientWidth && naturalWidth && naturalHeight) {
4982      const exceedMaxWidth = naturalWidth > clientWidth;
4983      const ratio = naturalHeight / naturalWidth;
4984      imageWidthWithinContainer = exceedMaxWidth ? clientWidth : naturalWidth;
4985      imageHeightWithinContainer = exceedMaxWidth ? clientWidth * ratio : naturalHeight;
4986    }
4987  
4988    if (canEditImage && isEditingImage) {
4989      img = Object(external_wp_element_["createElement"])(ImageEditor, {
4990        url: url,
4991        width: width,
4992        height: height,
4993        clientWidth: clientWidth,
4994        naturalHeight: naturalHeight,
4995        naturalWidth: naturalWidth
4996      });
4997    } else if (!isResizable || !imageWidthWithinContainer) {
4998      img = Object(external_wp_element_["createElement"])("div", {
4999        style: {
5000          width,
5001          height
5002        }
5003      }, img);
5004    } else {
5005      const currentWidth = width || imageWidthWithinContainer;
5006      const currentHeight = height || imageHeightWithinContainer;
5007      const ratio = naturalWidth / naturalHeight;
5008      const minWidth = naturalWidth < naturalHeight ? MIN_SIZE : MIN_SIZE * ratio;
5009      const minHeight = naturalHeight < naturalWidth ? MIN_SIZE : MIN_SIZE / ratio; // With the current implementation of ResizableBox, an image needs an
5010      // explicit pixel value for the max-width. In absence of being able to
5011      // set the content-width, this max-width is currently dictated by the
5012      // vanilla editor style. The following variable adds a buffer to this
5013      // vanilla style, so 3rd party themes have some wiggleroom. This does,
5014      // in most cases, allow you to scale the image beyond the width of the
5015      // main column, though not infinitely.
5016      // @todo It would be good to revisit this once a content-width variable
5017      // becomes available.
5018  
5019      const maxWidthBuffer = maxWidth * 2.5;
5020      let showRightHandle = false;
5021      let showLeftHandle = false;
5022      /* eslint-disable no-lonely-if */
5023      // See https://github.com/WordPress/gutenberg/issues/7584.
5024  
5025      if (align === 'center') {
5026        // When the image is centered, show both handles.
5027        showRightHandle = true;
5028        showLeftHandle = true;
5029      } else if (Object(external_wp_i18n_["isRTL"])()) {
5030        // In RTL mode the image is on the right by default.
5031        // Show the right handle and hide the left handle only when it is
5032        // aligned left. Otherwise always show the left handle.
5033        if (align === 'left') {
5034          showRightHandle = true;
5035        } else {
5036          showLeftHandle = true;
5037        }
5038      } else {
5039        // Show the left handle and hide the right handle only when the
5040        // image is aligned right. Otherwise always show the right handle.
5041        if (align === 'right') {
5042          showLeftHandle = true;
5043        } else {
5044          showRightHandle = true;
5045        }
5046      }
5047      /* eslint-enable no-lonely-if */
5048  
5049  
5050      img = Object(external_wp_element_["createElement"])(external_wp_components_["ResizableBox"], {
5051        size: {
5052          width: width !== null && width !== void 0 ? width : 'auto',
5053          height: height !== null && height !== void 0 ? height : 'auto'
5054        },
5055        showHandle: isSelected,
5056        minWidth: minWidth,
5057        maxWidth: maxWidthBuffer,
5058        minHeight: minHeight,
5059        maxHeight: maxWidthBuffer / ratio,
5060        lockAspectRatio: true,
5061        enable: {
5062          top: false,
5063          right: showRightHandle,
5064          bottom: true,
5065          left: showLeftHandle
5066        },
5067        onResizeStart: onResizeStart,
5068        onResizeStop: (event, direction, elt, delta) => {
5069          onResizeStop();
5070          setAttributes({
5071            width: parseInt(currentWidth + delta.width, 10),
5072            height: parseInt(currentHeight + delta.height, 10)
5073          });
5074        }
5075      }, img);
5076    }
5077  
5078    return Object(external_wp_element_["createElement"])(ImageEditingProvider, {
5079      id: id,
5080      url: url,
5081      naturalWidth: naturalWidth,
5082      naturalHeight: naturalHeight,
5083      clientWidth: clientWidth,
5084      onSaveImage: imageAttributes => setAttributes(imageAttributes),
5085      isEditing: isEditingImage,
5086      onFinishEditing: () => setIsEditingImage(false)
5087    }, !temporaryURL && controls, img, (!external_wp_blockEditor_["RichText"].isEmpty(caption) || isSelected) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"], {
5088      ref: captionRef,
5089      tagName: "figcaption",
5090      "aria-label": Object(external_wp_i18n_["__"])('Image caption text'),
5091      placeholder: Object(external_wp_i18n_["__"])('Add caption'),
5092      value: caption,
5093      onChange: value => setAttributes({
5094        caption: value
5095      }),
5096      inlineToolbar: true,
5097      __unstableOnSplitAtEnd: () => insertBlocksAfter(Object(external_wp_blocks_["createBlock"])('core/paragraph'))
5098    }));
5099  }
5100  
5101  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/edit.js
5102  
5103  
5104  /**
5105   * External dependencies
5106   */
5107  
5108  
5109  /**
5110   * WordPress dependencies
5111   */
5112  
5113  
5114  
5115  
5116  
5117  
5118  
5119  
5120  /* global wp */
5121  
5122  /**
5123   * Internal dependencies
5124   */
5125  
5126  
5127  /**
5128   * Module constants
5129   */
5130  
5131  
5132  const pickRelevantMediaFiles = (image, size) => {
5133    const imageProps = Object(external_lodash_["pick"])(image, ['alt', 'id', 'link', 'caption']);
5134    imageProps.url = Object(external_lodash_["get"])(image, ['sizes', size, 'url']) || Object(external_lodash_["get"])(image, ['media_details', 'sizes', size, 'source_url']) || image.url;
5135    return imageProps;
5136  };
5137  /**
5138   * Is the URL a temporary blob URL? A blob URL is one that is used temporarily
5139   * while the image is being uploaded and will not have an id yet allocated.
5140   *
5141   * @param {number=} id The id of the image.
5142   * @param {string=} url The url of the image.
5143   *
5144   * @return {boolean} Is the URL a Blob URL
5145   */
5146  
5147  const isTemporaryImage = (id, url) => !id && Object(external_wp_blob_["isBlobURL"])(url);
5148  /**
5149   * Is the url for the image hosted externally. An externally hosted image has no
5150   * id and is not a blob url.
5151   *
5152   * @param {number=} id  The id of the image.
5153   * @param {string=} url The url of the image.
5154   *
5155   * @return {boolean} Is the url an externally hosted url?
5156   */
5157  
5158  
5159  const isExternalImage = (id, url) => url && !id && !Object(external_wp_blob_["isBlobURL"])(url);
5160  /**
5161   * Checks if WP generated default image size. Size generation is skipped
5162   * when the image is smaller than the said size.
5163   *
5164   * @param {Object} image
5165   * @param {string} defaultSize
5166   *
5167   * @return {boolean} Whether or not it has default image size.
5168   */
5169  
5170  function hasDefaultSize(image, defaultSize) {
5171    return Object(external_lodash_["has"])(image, ['sizes', defaultSize, 'url']) || Object(external_lodash_["has"])(image, ['media_details', 'sizes', defaultSize, 'source_url']);
5172  }
5173  
5174  function ImageEdit({
5175    attributes,
5176    setAttributes,
5177    isSelected,
5178    className,
5179    noticeUI,
5180    insertBlocksAfter,
5181    noticeOperations,
5182    onReplace,
5183    clientId
5184  }) {
5185    const {
5186      url = '',
5187      alt,
5188      caption,
5189      align,
5190      id,
5191      width,
5192      height,
5193      sizeSlug
5194    } = attributes;
5195    const [temporaryURL, setTemporaryURL] = Object(external_wp_element_["useState"])();
5196    const altRef = Object(external_wp_element_["useRef"])();
5197    Object(external_wp_element_["useEffect"])(() => {
5198      altRef.current = alt;
5199    }, [alt]);
5200    const captionRef = Object(external_wp_element_["useRef"])();
5201    Object(external_wp_element_["useEffect"])(() => {
5202      captionRef.current = caption;
5203    }, [caption]);
5204    const ref = Object(external_wp_element_["useRef"])();
5205    const {
5206      imageDefaultSize,
5207      mediaUpload
5208    } = Object(external_wp_data_["useSelect"])(select => {
5209      const {
5210        getSettings
5211      } = select(external_wp_blockEditor_["store"]);
5212      return Object(external_lodash_["pick"])(getSettings(), ['imageDefaultSize', 'mediaUpload']);
5213    }, []);
5214  
5215    function onUploadError(message) {
5216      noticeOperations.removeAllNotices();
5217      noticeOperations.createErrorNotice(message);
5218    }
5219  
5220    function onSelectImage(media) {
5221      var _wp, _wp$media, _wp$media$view, _wp$media$view$settin, _wp$media$view$settin2;
5222  
5223      if (!media || !media.url) {
5224        setAttributes({
5225          url: undefined,
5226          alt: undefined,
5227          id: undefined,
5228          title: undefined,
5229          caption: undefined
5230        });
5231        return;
5232      }
5233  
5234      if (Object(external_wp_blob_["isBlobURL"])(media.url)) {
5235        setTemporaryURL(media.url);
5236        return;
5237      }
5238  
5239      setTemporaryURL();
5240      let mediaAttributes = pickRelevantMediaFiles(media, imageDefaultSize); // If a caption text was meanwhile written by the user,
5241      // make sure the text is not overwritten by empty captions.
5242  
5243      if (captionRef.current && !Object(external_lodash_["get"])(mediaAttributes, ['caption'])) {
5244        mediaAttributes = Object(external_lodash_["omit"])(mediaAttributes, ['caption']);
5245      }
5246  
5247      let additionalAttributes; // Reset the dimension attributes if changing to a different image.
5248  
5249      if (!media.id || media.id !== id) {
5250        additionalAttributes = {
5251          width: undefined,
5252          height: undefined,
5253          // Fallback to size "full" if there's no default image size.
5254          // It means the image is smaller, and the block will use a full-size URL.
5255          sizeSlug: hasDefaultSize(media, imageDefaultSize) ? imageDefaultSize : 'full'
5256        };
5257      } else {
5258        // Keep the same url when selecting the same file, so "Image Size"
5259        // option is not changed.
5260        additionalAttributes = {
5261          url
5262        };
5263      } // Check if default link setting should be used.
5264  
5265  
5266      let linkDestination = attributes.linkDestination;
5267  
5268      if (!linkDestination) {
5269        // Use the WordPress option to determine the proper default.
5270        // The constants used in Gutenberg do not match WP options so a little more complicated than ideal.
5271        // TODO: fix this in a follow up PR, requires updating media-text and ui component.
5272        switch (((_wp = wp) === null || _wp === void 0 ? void 0 : (_wp$media = _wp.media) === null || _wp$media === void 0 ? void 0 : (_wp$media$view = _wp$media.view) === null || _wp$media$view === void 0 ? void 0 : (_wp$media$view$settin = _wp$media$view.settings) === null || _wp$media$view$settin === void 0 ? void 0 : (_wp$media$view$settin2 = _wp$media$view$settin.defaultProps) === null || _wp$media$view$settin2 === void 0 ? void 0 : _wp$media$view$settin2.link) || LINK_DESTINATION_NONE) {
5273          case 'file':
5274          case LINK_DESTINATION_MEDIA:
5275            linkDestination = LINK_DESTINATION_MEDIA;
5276            break;
5277  
5278          case 'post':
5279          case LINK_DESTINATION_ATTACHMENT:
5280            linkDestination = LINK_DESTINATION_ATTACHMENT;
5281            break;
5282  
5283          case LINK_DESTINATION_CUSTOM:
5284            linkDestination = LINK_DESTINATION_CUSTOM;
5285            break;
5286  
5287          case LINK_DESTINATION_NONE:
5288            linkDestination = LINK_DESTINATION_NONE;
5289            break;
5290        }
5291      } // Check if the image is linked to it's media.
5292  
5293  
5294      let href;
5295  
5296      switch (linkDestination) {
5297        case LINK_DESTINATION_MEDIA:
5298          href = media.url;
5299          break;
5300  
5301        case LINK_DESTINATION_ATTACHMENT:
5302          href = media.link;
5303          break;
5304      }
5305  
5306      mediaAttributes.href = href;
5307      setAttributes({ ...mediaAttributes,
5308        ...additionalAttributes,
5309        linkDestination
5310      });
5311    }
5312  
5313    function onSelectURL(newURL) {
5314      if (newURL !== url) {
5315        setAttributes({
5316          url: newURL,
5317          id: undefined,
5318          width: undefined,
5319          height: undefined,
5320          sizeSlug: imageDefaultSize
5321        });
5322      }
5323    }
5324  
5325    function updateAlignment(nextAlign) {
5326      const extraUpdatedAttributes = ['wide', 'full'].includes(nextAlign) ? {
5327        width: undefined,
5328        height: undefined
5329      } : {};
5330      setAttributes({ ...extraUpdatedAttributes,
5331        align: nextAlign
5332      });
5333    }
5334  
5335    const isTemp = isTemporaryImage(id, url); // Upload a temporary image on mount.
5336  
5337    Object(external_wp_element_["useEffect"])(() => {
5338      if (!isTemp) {
5339        return;
5340      }
5341  
5342      const file = Object(external_wp_blob_["getBlobByURL"])(url);
5343  
5344      if (file) {
5345        mediaUpload({
5346          filesList: [file],
5347          onFileChange: ([img]) => {
5348            onSelectImage(img);
5349          },
5350          allowedTypes: ALLOWED_MEDIA_TYPES,
5351          onError: message => {
5352            noticeOperations.createErrorNotice(message);
5353            setAttributes({
5354              src: undefined,
5355              id: undefined,
5356              url: undefined
5357            });
5358          }
5359        });
5360      }
5361    }, []); // If an image is temporary, revoke the Blob url when it is uploaded (and is
5362    // no longer temporary).
5363  
5364    Object(external_wp_element_["useEffect"])(() => {
5365      if (!temporaryURL) {
5366        return;
5367      }
5368  
5369      return () => {
5370        Object(external_wp_blob_["revokeBlobURL"])(temporaryURL);
5371      };
5372    }, [temporaryURL]);
5373    const isExternal = isExternalImage(id, url);
5374    const src = isExternal ? url : undefined;
5375    const mediaPreview = !!url && Object(external_wp_element_["createElement"])("img", {
5376      alt: Object(external_wp_i18n_["__"])('Edit image'),
5377      title: Object(external_wp_i18n_["__"])('Edit image'),
5378      className: 'edit-image-preview',
5379      src: url
5380    });
5381    const classes = classnames_default()(className, {
5382      'is-transient': temporaryURL,
5383      'is-resized': !!width || !!height,
5384      [`size-$sizeSlug}`]: sizeSlug
5385    });
5386    const blockProps = Object(external_wp_blockEditor_["useBlockProps"])({
5387      ref,
5388      className: classes
5389    });
5390    return Object(external_wp_element_["createElement"])("figure", blockProps, (temporaryURL || url) && Object(external_wp_element_["createElement"])(Image, {
5391      temporaryURL: temporaryURL,
5392      attributes: attributes,
5393      setAttributes: setAttributes,
5394      isSelected: isSelected,
5395      insertBlocksAfter: insertBlocksAfter,
5396      onReplace: onReplace,
5397      onSelectImage: onSelectImage,
5398      onSelectURL: onSelectURL,
5399      onUploadError: onUploadError,
5400      containerRef: ref,
5401      clientId: clientId
5402    }), !url && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockControls"], {
5403      group: "block"
5404    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockAlignmentControl"], {
5405      value: align,
5406      onChange: updateAlignment
5407    })), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["MediaPlaceholder"], {
5408      icon: Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockIcon"], {
5409        icon: library_image
5410      }),
5411      onSelect: onSelectImage,
5412      onSelectURL: onSelectURL,
5413      notices: noticeUI,
5414      onError: onUploadError,
5415      accept: "image/*",
5416      allowedTypes: ALLOWED_MEDIA_TYPES,
5417      value: {
5418        id,
5419        src
5420      },
5421      mediaPreview: mediaPreview,
5422      disableMediaButtons: temporaryURL || url
5423    }));
5424  }
5425  /* harmony default export */ var image_edit = (Object(external_wp_components_["withNotices"])(ImageEdit));
5426  
5427  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/save.js
5428  
5429  
5430  /**
5431   * External dependencies
5432   */
5433  
5434  
5435  /**
5436   * WordPress dependencies
5437   */
5438  
5439  
5440  function save_save({
5441    attributes
5442  }) {
5443    const {
5444      url,
5445      alt,
5446      caption,
5447      align,
5448      href,
5449      rel,
5450      linkClass,
5451      width,
5452      height,
5453      id,
5454      linkTarget,
5455      sizeSlug,
5456      title
5457    } = attributes;
5458    const newRel = Object(external_lodash_["isEmpty"])(rel) ? undefined : rel;
5459    const classes = classnames_default()({
5460      [`align$align}`]: align,
5461      [`size-$sizeSlug}`]: sizeSlug,
5462      'is-resized': width || height
5463    });
5464    const image = Object(external_wp_element_["createElement"])("img", {
5465      src: url,
5466      alt: alt,
5467      className: id ? `wp-image-$id}` : null,
5468      width: width,
5469      height: height,
5470      title: title
5471    });
5472    const figure = Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, href ? Object(external_wp_element_["createElement"])("a", {
5473      className: linkClass,
5474      href: href,
5475      target: linkTarget,
5476      rel: newRel
5477    }, image) : image, !external_wp_blockEditor_["RichText"].isEmpty(caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
5478      tagName: "figcaption",
5479      value: caption
5480    }));
5481  
5482    if ('left' === align || 'right' === align || 'center' === align) {
5483      return Object(external_wp_element_["createElement"])("div", external_wp_blockEditor_["useBlockProps"].save(), Object(external_wp_element_["createElement"])("figure", {
5484        className: classes
5485      }, figure));
5486    }
5487  
5488    return Object(external_wp_element_["createElement"])("figure", external_wp_blockEditor_["useBlockProps"].save({
5489      className: classes
5490    }), figure);
5491  }
5492  
5493  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/transforms.js
5494  /**
5495   * WordPress dependencies
5496   */
5497  
5498  
5499  function stripFirstImage(attributes, {
5500    shortcode
5501  }) {
5502    const {
5503      body
5504    } = document.implementation.createHTMLDocument('');
5505    body.innerHTML = shortcode.content;
5506    let nodeToRemove = body.querySelector('img'); // if an image has parents, find the topmost node to remove
5507  
5508    while (nodeToRemove && nodeToRemove.parentNode && nodeToRemove.parentNode !== body) {
5509      nodeToRemove = nodeToRemove.parentNode;
5510    }
5511  
5512    if (nodeToRemove) {
5513      nodeToRemove.parentNode.removeChild(nodeToRemove);
5514    }
5515  
5516    return body.innerHTML.trim();
5517  }
5518  
5519  function getFirstAnchorAttributeFormHTML(html, attributeName) {
5520    const {
5521      body
5522    } = document.implementation.createHTMLDocument('');
5523    body.innerHTML = html;
5524    const {
5525      firstElementChild
5526    } = body;
5527  
5528    if (firstElementChild && firstElementChild.nodeName === 'A') {
5529      return firstElementChild.getAttribute(attributeName) || undefined;
5530    }
5531  }
5532  
5533  const imageSchema = {
5534    img: {
5535      attributes: ['src', 'alt', 'title'],
5536      classes: ['alignleft', 'aligncenter', 'alignright', 'alignnone', /^wp-image-\d+$/]
5537    }
5538  };
5539  
5540  const schema = ({
5541    phrasingContentSchema
5542  }) => ({
5543    figure: {
5544      require: ['img'],
5545      children: { ...imageSchema,
5546        a: {
5547          attributes: ['href', 'rel', 'target'],
5548          children: imageSchema
5549        },
5550        figcaption: {
5551          children: phrasingContentSchema
5552        }
5553      }
5554    }
5555  });
5556  
5557  const transforms_transforms = {
5558    from: [{
5559      type: 'raw',
5560      isMatch: node => node.nodeName === 'FIGURE' && !!node.querySelector('img'),
5561      schema,
5562      transform: node => {
5563        // Search both figure and image classes. Alignment could be
5564        // set on either. ID is set on the image.
5565        const className = node.className + ' ' + node.querySelector('img').className;
5566        const alignMatches = /(?:^|\s)align(left|center|right)(?:$|\s)/.exec(className);
5567        const anchor = node.id === '' ? undefined : node.id;
5568        const align = alignMatches ? alignMatches[1] : undefined;
5569        const idMatches = /(?:^|\s)wp-image-(\d+)(?:$|\s)/.exec(className);
5570        const id = idMatches ? Number(idMatches[1]) : undefined;
5571        const anchorElement = node.querySelector('a');
5572        const linkDestination = anchorElement && anchorElement.href ? 'custom' : undefined;
5573        const href = anchorElement && anchorElement.href ? anchorElement.href : undefined;
5574        const rel = anchorElement && anchorElement.rel ? anchorElement.rel : undefined;
5575        const linkClass = anchorElement && anchorElement.className ? anchorElement.className : undefined;
5576        const attributes = Object(external_wp_blocks_["getBlockAttributes"])('core/image', node.outerHTML, {
5577          align,
5578          id,
5579          linkDestination,
5580          href,
5581          rel,
5582          linkClass,
5583          anchor
5584        });
5585        return Object(external_wp_blocks_["createBlock"])('core/image', attributes);
5586      }
5587    }, {
5588      type: 'files',
5589  
5590      isMatch(files) {
5591        return files.length === 1 && files[0].type.indexOf('image/') === 0;
5592      },
5593  
5594      transform(files) {
5595        const file = files[0]; // We don't need to upload the media directly here
5596        // It's already done as part of the `componentDidMount`
5597        // int the image block
5598  
5599        return Object(external_wp_blocks_["createBlock"])('core/image', {
5600          url: Object(external_wp_blob_["createBlobURL"])(file)
5601        });
5602      }
5603  
5604    }, {
5605      type: 'shortcode',
5606      tag: 'caption',
5607      attributes: {
5608        url: {
5609          type: 'string',
5610          source: 'attribute',
5611          attribute: 'src',
5612          selector: 'img'
5613        },
5614        alt: {
5615          type: 'string',
5616          source: 'attribute',
5617          attribute: 'alt',
5618          selector: 'img'
5619        },
5620        caption: {
5621          shortcode: stripFirstImage
5622        },
5623        href: {
5624          shortcode: (attributes, {
5625            shortcode
5626          }) => {
5627            return getFirstAnchorAttributeFormHTML(shortcode.content, 'href');
5628          }
5629        },
5630        rel: {
5631          shortcode: (attributes, {
5632            shortcode
5633          }) => {
5634            return getFirstAnchorAttributeFormHTML(shortcode.content, 'rel');
5635          }
5636        },
5637        linkClass: {
5638          shortcode: (attributes, {
5639            shortcode
5640          }) => {
5641            return getFirstAnchorAttributeFormHTML(shortcode.content, 'class');
5642          }
5643        },
5644        id: {
5645          type: 'number',
5646          shortcode: ({
5647            named: {
5648              id
5649            }
5650          }) => {
5651            if (!id) {
5652              return;
5653            }
5654  
5655            return parseInt(id.replace('attachment_', ''), 10);
5656          }
5657        },
5658        align: {
5659          type: 'string',
5660          shortcode: ({
5661            named: {
5662              align = 'alignnone'
5663            }
5664          }) => {
5665            return align.replace('align', '');
5666          }
5667        }
5668      }
5669    }]
5670  };
5671  /* harmony default export */ var image_transforms = (transforms_transforms);
5672  
5673  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/image/index.js
5674  /**
5675   * WordPress dependencies
5676   */
5677  
5678  
5679  /**
5680   * Internal dependencies
5681   */
5682  
5683  
5684  
5685  const image_metadata = {
5686    apiVersion: 2,
5687    name: "core/image",
5688    title: "Image",
5689    category: "media",
5690    description: "Insert an image to make a visual statement.",
5691    keywords: ["img", "photo", "picture"],
5692    textdomain: "default",
5693    attributes: {
5694      align: {
5695        type: "string"
5696      },
5697      url: {
5698        type: "string",
5699        source: "attribute",
5700        selector: "img",
5701        attribute: "src"
5702      },
5703      alt: {
5704        type: "string",
5705        source: "attribute",
5706        selector: "img",
5707        attribute: "alt",
5708        "default": ""
5709      },
5710      caption: {
5711        type: "string",
5712        source: "html",
5713        selector: "figcaption"
5714      },
5715      title: {
5716        type: "string",
5717        source: "attribute",
5718        selector: "img",
5719        attribute: "title"
5720      },
5721      href: {
5722        type: "string",
5723        source: "attribute",
5724        selector: "figure > a",
5725        attribute: "href"
5726      },
5727      rel: {
5728        type: "string",
5729        source: "attribute",
5730        selector: "figure > a",
5731        attribute: "rel"
5732      },
5733      linkClass: {
5734        type: "string",
5735        source: "attribute",
5736        selector: "figure > a",
5737        attribute: "class"
5738      },
5739      id: {
5740        type: "number"
5741      },
5742      width: {
5743        type: "number"
5744      },
5745      height: {
5746        type: "number"
5747      },
5748      sizeSlug: {
5749        type: "string"
5750      },
5751      linkDestination: {
5752        type: "string"
5753      },
5754      linkTarget: {
5755        type: "string",
5756        source: "attribute",
5757        selector: "figure > a",
5758        attribute: "target"
5759      }
5760    },
5761    supports: {
5762      anchor: true,
5763      color: {
5764        __experimentalDuotone: "img",
5765        text: false,
5766        background: false
5767      },
5768      __experimentalBorder: {
5769        radius: true
5770      }
5771    },
5772    styles: [{
5773      name: "default",
5774      label: "Default",
5775      isDefault: true
5776    }, {
5777      name: "rounded",
5778      label: "Rounded"
5779    }],
5780    editorStyle: "wp-block-image-editor",
5781    style: "wp-block-image"
5782  };
5783  
5784  
5785  const {
5786    name: image_name
5787  } = image_metadata;
5788  
5789  const image_settings = {
5790    icon: library_image,
5791    example: {
5792      attributes: {
5793        sizeSlug: 'large',
5794        url: 'https://s.w.org/images/core/5.3/MtBlanc1.jpg',
5795        // translators: Caption accompanying an image of the Mont Blanc, which serves as an example for the Image block.
5796        caption: Object(external_wp_i18n_["__"])('Mont Blanc appears—still, snowy, and serene.')
5797      }
5798    },
5799  
5800    __experimentalLabel(attributes, {
5801      context
5802    }) {
5803      if (context === 'accessibility') {
5804        const {
5805          caption,
5806          alt,
5807          url
5808        } = attributes;
5809  
5810        if (!url) {
5811          return Object(external_wp_i18n_["__"])('Empty');
5812        }
5813  
5814        if (!alt) {
5815          return caption || '';
5816        } // This is intended to be read by a screen reader.
5817        // A period simply means a pause, no need to translate it.
5818  
5819  
5820        return alt + (caption ? '. ' + caption : '');
5821      }
5822    },
5823  
5824    getEditWrapperProps(attributes) {
5825      return {
5826        'data-align': attributes.align
5827      };
5828    },
5829  
5830    transforms: image_transforms,
5831    edit: image_edit,
5832    save: save_save,
5833    deprecated: image_deprecated
5834  };
5835  
5836  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/heading.js
5837  
5838  
5839  /**
5840   * WordPress dependencies
5841   */
5842  
5843  const heading = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
5844    xmlns: "http://www.w3.org/2000/svg",
5845    viewBox: "0 0 24 24"
5846  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
5847    d: "M6.2 5.2v13.4l5.8-4.8 5.8 4.8V5.2z"
5848  }));
5849  /* harmony default export */ var library_heading = (heading);
5850  
5851  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/heading/deprecated.js
5852  
5853  
5854  /**
5855   * External dependencies
5856   */
5857  
5858  
5859  /**
5860   * WordPress dependencies
5861   */
5862  
5863  
5864  const blockSupports = {
5865    className: false,
5866    anchor: true
5867  };
5868  const heading_deprecated_blockAttributes = {
5869    align: {
5870      type: 'string'
5871    },
5872    content: {
5873      type: 'string',
5874      source: 'html',
5875      selector: 'h1,h2,h3,h4,h5,h6',
5876      default: ''
5877    },
5878    level: {
5879      type: 'number',
5880      default: 2
5881    },
5882    placeholder: {
5883      type: 'string'
5884    }
5885  };
5886  
5887  const migrateCustomColors = attributes => {
5888    if (!attributes.customTextColor) {
5889      return attributes;
5890    }
5891  
5892    const style = {
5893      color: {
5894        text: attributes.customTextColor
5895      }
5896    };
5897    return { ...Object(external_lodash_["omit"])(attributes, ['customTextColor']),
5898      style
5899    };
5900  };
5901  
5902  const TEXT_ALIGN_OPTIONS = ['left', 'right', 'center'];
5903  
5904  const migrateTextAlign = attributes => {
5905    const {
5906      align,
5907      ...rest
5908    } = attributes;
5909    return TEXT_ALIGN_OPTIONS.includes(align) ? { ...rest,
5910      textAlign: align
5911    } : attributes;
5912  };
5913  
5914  const heading_deprecated_deprecated = [{
5915    supports: {
5916      align: ['wide', 'full'],
5917      anchor: true,
5918      className: false,
5919      color: {
5920        link: true
5921      },
5922      fontSize: true,
5923      lineHeight: true,
5924      __experimentalSelector: {
5925        'core/heading/h1': 'h1',
5926        'core/heading/h2': 'h2',
5927        'core/heading/h3': 'h3',
5928        'core/heading/h4': 'h4',
5929        'core/heading/h5': 'h5',
5930        'core/heading/h6': 'h6'
5931      },
5932      __unstablePasteTextInline: true
5933    },
5934    attributes: heading_deprecated_blockAttributes,
5935    isEligible: ({
5936      align
5937    }) => TEXT_ALIGN_OPTIONS.includes(align),
5938    migrate: migrateTextAlign,
5939  
5940    save({
5941      attributes
5942    }) {
5943      const {
5944        align,
5945        content,
5946        level
5947      } = attributes;
5948      const TagName = 'h' + level;
5949      const className = classnames_default()({
5950        [`has-text-align-$align}`]: align
5951      });
5952      return Object(external_wp_element_["createElement"])(TagName, external_wp_blockEditor_["useBlockProps"].save({
5953        className
5954      }), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
5955        value: content
5956      }));
5957    }
5958  
5959  }, {
5960    supports: blockSupports,
5961    attributes: { ...heading_deprecated_blockAttributes,
5962      customTextColor: {
5963        type: 'string'
5964      },
5965      textColor: {
5966        type: 'string'
5967      }
5968    },
5969    migrate: attributes => migrateCustomColors(migrateTextAlign(attributes)),
5970  
5971    save({
5972      attributes
5973    }) {
5974      const {
5975        align,
5976        content,
5977        customTextColor,
5978        level,
5979        textColor
5980      } = attributes;
5981      const tagName = 'h' + level;
5982      const textClass = Object(external_wp_blockEditor_["getColorClassName"])('color', textColor);
5983      const className = classnames_default()({
5984        [textClass]: textClass,
5985        'has-text-color': textColor || customTextColor,
5986        [`has-text-align-$align}`]: align
5987      });
5988      return Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
5989        className: className ? className : undefined,
5990        tagName: tagName,
5991        style: {
5992          color: textClass ? undefined : customTextColor
5993        },
5994        value: content
5995      });
5996    }
5997  
5998  }, {
5999    attributes: { ...heading_deprecated_blockAttributes,
6000      customTextColor: {
6001        type: 'string'
6002      },
6003      textColor: {
6004        type: 'string'
6005      }
6006    },
6007    migrate: attributes => migrateCustomColors(migrateTextAlign(attributes)),
6008  
6009    save({
6010      attributes
6011    }) {
6012      const {
6013        align,
6014        content,
6015        customTextColor,
6016        level,
6017        textColor
6018      } = attributes;
6019      const tagName = 'h' + level;
6020      const textClass = Object(external_wp_blockEditor_["getColorClassName"])('color', textColor);
6021      const className = classnames_default()({
6022        [textClass]: textClass,
6023        [`has-text-align-$align}`]: align
6024      });
6025      return Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6026        className: className ? className : undefined,
6027        tagName: tagName,
6028        style: {
6029          color: textClass ? undefined : customTextColor
6030        },
6031        value: content
6032      });
6033    },
6034  
6035    supports: blockSupports
6036  }, {
6037    supports: blockSupports,
6038    attributes: { ...heading_deprecated_blockAttributes,
6039      customTextColor: {
6040        type: 'string'
6041      },
6042      textColor: {
6043        type: 'string'
6044      }
6045    },
6046    migrate: attributes => migrateCustomColors(migrateTextAlign(attributes)),
6047  
6048    save({
6049      attributes
6050    }) {
6051      const {
6052        align,
6053        level,
6054        content,
6055        textColor,
6056        customTextColor
6057      } = attributes;
6058      const tagName = 'h' + level;
6059      const textClass = Object(external_wp_blockEditor_["getColorClassName"])('color', textColor);
6060      const className = classnames_default()({
6061        [textClass]: textClass
6062      });
6063      return Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6064        className: className ? className : undefined,
6065        tagName: tagName,
6066        style: {
6067          textAlign: align,
6068          color: textClass ? undefined : customTextColor
6069        },
6070        value: content
6071      });
6072    }
6073  
6074  }];
6075  /* harmony default export */ var heading_deprecated = (heading_deprecated_deprecated);
6076  
6077  // EXTERNAL MODULE: external ["wp","keycodes"]
6078  var external_wp_keycodes_ = __webpack_require__("RxS6");
6079  
6080  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/heading/heading-level-icon.js
6081  
6082  
6083  /**
6084   * WordPress dependencies
6085   */
6086  
6087  /** @typedef {import('@wordpress/element').WPComponent} WPComponent */
6088  
6089  /**
6090   * HeadingLevelIcon props.
6091   *
6092   * @typedef WPHeadingLevelIconProps
6093   *
6094   * @property {number}   level     The heading level to show an icon for.
6095   * @property {?boolean} isPressed Whether or not the icon should appear pressed; default: false.
6096   */
6097  
6098  /**
6099   * Heading level icon.
6100   *
6101   * @param {WPHeadingLevelIconProps} props Component props.
6102   *
6103   * @return {?WPComponent} The icon.
6104   */
6105  
6106  function HeadingLevelIcon({
6107    level,
6108    isPressed = false
6109  }) {
6110    const levelToPath = {
6111      1: 'M9 5h2v10H9v-4H5v4H3V5h2v4h4V5zm6.6 0c-.6.9-1.5 1.7-2.6 2v1h2v7h2V5h-1.4z',
6112      2: 'M7 5h2v10H7v-4H3v4H1V5h2v4h4V5zm8 8c.5-.4.6-.6 1.1-1.1.4-.4.8-.8 1.2-1.3.3-.4.6-.8.9-1.3.2-.4.3-.8.3-1.3 0-.4-.1-.9-.3-1.3-.2-.4-.4-.7-.8-1-.3-.3-.7-.5-1.2-.6-.5-.2-1-.2-1.5-.2-.4 0-.7 0-1.1.1-.3.1-.7.2-1 .3-.3.1-.6.3-.9.5-.3.2-.6.4-.8.7l1.2 1.2c.3-.3.6-.5 1-.7.4-.2.7-.3 1.2-.3s.9.1 1.3.4c.3.3.5.7.5 1.1 0 .4-.1.8-.4 1.1-.3.5-.6.9-1 1.2-.4.4-1 .9-1.6 1.4-.6.5-1.4 1.1-2.2 1.6V15h8v-2H15z',
6113      3: 'M12.1 12.2c.4.3.8.5 1.2.7.4.2.9.3 1.4.3.5 0 1-.1 1.4-.3.3-.1.5-.5.5-.8 0-.2 0-.4-.1-.6-.1-.2-.3-.3-.5-.4-.3-.1-.7-.2-1-.3-.5-.1-1-.1-1.5-.1V9.1c.7.1 1.5-.1 2.2-.4.4-.2.6-.5.6-.9 0-.3-.1-.6-.4-.8-.3-.2-.7-.3-1.1-.3-.4 0-.8.1-1.1.3-.4.2-.7.4-1.1.6l-1.2-1.4c.5-.4 1.1-.7 1.6-.9.5-.2 1.2-.3 1.8-.3.5 0 1 .1 1.6.2.4.1.8.3 1.2.5.3.2.6.5.8.8.2.3.3.7.3 1.1 0 .5-.2.9-.5 1.3-.4.4-.9.7-1.5.9v.1c.6.1 1.2.4 1.6.8.4.4.7.9.7 1.5 0 .4-.1.8-.3 1.2-.2.4-.5.7-.9.9-.4.3-.9.4-1.3.5-.5.1-1 .2-1.6.2-.8 0-1.6-.1-2.3-.4-.6-.2-1.1-.6-1.6-1l1.1-1.4zM7 9H3V5H1v10h2v-4h4v4h2V5H7v4z',
6114      4: 'M9 15H7v-4H3v4H1V5h2v4h4V5h2v10zm10-2h-1v2h-2v-2h-5v-2l4-6h3v6h1v2zm-3-2V7l-2.8 4H16z',
6115      5: 'M12.1 12.2c.4.3.7.5 1.1.7.4.2.9.3 1.3.3.5 0 1-.1 1.4-.4.4-.3.6-.7.6-1.1 0-.4-.2-.9-.6-1.1-.4-.3-.9-.4-1.4-.4H14c-.1 0-.3 0-.4.1l-.4.1-.5.2-1-.6.3-5h6.4v1.9h-4.3L14 8.8c.2-.1.5-.1.7-.2.2 0 .5-.1.7-.1.5 0 .9.1 1.4.2.4.1.8.3 1.1.6.3.2.6.6.8.9.2.4.3.9.3 1.4 0 .5-.1 1-.3 1.4-.2.4-.5.8-.9 1.1-.4.3-.8.5-1.3.7-.5.2-1 .3-1.5.3-.8 0-1.6-.1-2.3-.4-.6-.2-1.1-.6-1.6-1-.1-.1 1-1.5 1-1.5zM9 15H7v-4H3v4H1V5h2v4h4V5h2v10z',
6116      6: 'M9 15H7v-4H3v4H1V5h2v4h4V5h2v10zm8.6-7.5c-.2-.2-.5-.4-.8-.5-.6-.2-1.3-.2-1.9 0-.3.1-.6.3-.8.5l-.6.9c-.2.5-.2.9-.2 1.4.4-.3.8-.6 1.2-.8.4-.2.8-.3 1.3-.3.4 0 .8 0 1.2.2.4.1.7.3 1 .6.3.3.5.6.7.9.2.4.3.8.3 1.3s-.1.9-.3 1.4c-.2.4-.5.7-.8 1-.4.3-.8.5-1.2.6-1 .3-2 .3-3 0-.5-.2-1-.5-1.4-.9-.4-.4-.8-.9-1-1.5-.2-.6-.3-1.3-.3-2.1s.1-1.6.4-2.3c.2-.6.6-1.2 1-1.6.4-.4.9-.7 1.4-.9.6-.3 1.1-.4 1.7-.4.7 0 1.4.1 2 .3.5.2 1 .5 1.4.8 0 .1-1.3 1.4-1.3 1.4zm-2.4 5.8c.2 0 .4 0 .6-.1.2 0 .4-.1.5-.2.1-.1.3-.3.4-.5.1-.2.1-.5.1-.7 0-.4-.1-.8-.4-1.1-.3-.2-.7-.3-1.1-.3-.3 0-.7.1-1 .2-.4.2-.7.4-1 .7 0 .3.1.7.3 1 .1.2.3.4.4.6.2.1.3.3.5.3.2.1.5.2.7.1z'
6117    };
6118  
6119    if (!levelToPath.hasOwnProperty(level)) {
6120      return null;
6121    }
6122  
6123    return Object(external_wp_element_["createElement"])(external_wp_components_["SVG"], {
6124      width: "24",
6125      height: "24",
6126      viewBox: "0 0 20 20",
6127      xmlns: "http://www.w3.org/2000/svg",
6128      isPressed: isPressed
6129    }, Object(external_wp_element_["createElement"])(external_wp_components_["Path"], {
6130      d: levelToPath[level]
6131    }));
6132  }
6133  
6134  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/heading/heading-level-dropdown.js
6135  
6136  
6137  /**
6138   * WordPress dependencies
6139   */
6140  
6141  
6142  
6143  /**
6144   * Internal dependencies
6145   */
6146  
6147  
6148  const HEADING_LEVELS = [1, 2, 3, 4, 5, 6];
6149  const heading_level_dropdown_POPOVER_PROPS = {
6150    className: 'block-library-heading-level-dropdown',
6151    isAlternate: true
6152  };
6153  /** @typedef {import('@wordpress/element').WPComponent} WPComponent */
6154  
6155  /**
6156   * HeadingLevelDropdown props.
6157   *
6158   * @typedef WPHeadingLevelDropdownProps
6159   *
6160   * @property {number}                 selectedLevel The chosen heading level.
6161   * @property {(newValue:number)=>any} onChange      Callback to run when
6162   *                                                  toolbar value is changed.
6163   */
6164  
6165  /**
6166   * Dropdown for selecting a heading level (1 through 6).
6167   *
6168   * @param {WPHeadingLevelDropdownProps} props Component props.
6169   *
6170   * @return {WPComponent} The toolbar.
6171   */
6172  
6173  function HeadingLevelDropdown({
6174    selectedLevel,
6175    onChange
6176  }) {
6177    return Object(external_wp_element_["createElement"])(external_wp_components_["Dropdown"], {
6178      popoverProps: heading_level_dropdown_POPOVER_PROPS,
6179      renderToggle: ({
6180        onToggle,
6181        isOpen
6182      }) => {
6183        const openOnArrowDown = event => {
6184          if (!isOpen && event.keyCode === external_wp_keycodes_["DOWN"]) {
6185            event.preventDefault();
6186            event.stopPropagation();
6187            onToggle();
6188          }
6189        };
6190  
6191        return Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarButton"], {
6192          "aria-expanded": isOpen,
6193          "aria-haspopup": "true",
6194          icon: Object(external_wp_element_["createElement"])(HeadingLevelIcon, {
6195            level: selectedLevel
6196          }),
6197          label: Object(external_wp_i18n_["__"])('Change heading level'),
6198          onClick: onToggle,
6199          onKeyDown: openOnArrowDown,
6200          showTooltip: true
6201        });
6202      },
6203      renderContent: () => Object(external_wp_element_["createElement"])(external_wp_components_["Toolbar"], {
6204        className: "block-library-heading-level-toolbar",
6205        label: Object(external_wp_i18n_["__"])('Change heading level')
6206      }, Object(external_wp_element_["createElement"])(external_wp_components_["ToolbarGroup"], {
6207        isCollapsed: false,
6208        controls: HEADING_LEVELS.map(targetLevel => {
6209          const isActive = targetLevel === selectedLevel;
6210          return {
6211            icon: Object(external_wp_element_["createElement"])(HeadingLevelIcon, {
6212              level: targetLevel,
6213              isPressed: isActive
6214            }),
6215            title: Object(external_wp_i18n_["sprintf"])( // translators: %s: heading level e.g: "1", "2", "3"
6216            Object(external_wp_i18n_["__"])('Heading %d'), targetLevel),
6217            isActive,
6218  
6219            onClick() {
6220              onChange(targetLevel);
6221            }
6222  
6223          };
6224        })
6225      }))
6226    });
6227  }
6228  
6229  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/heading/edit.js
6230  
6231  
6232  
6233  /**
6234   * External dependencies
6235   */
6236  
6237  /**
6238   * WordPress dependencies
6239   */
6240  
6241  
6242  
6243  
6244  /**
6245   * Internal dependencies
6246   */
6247  
6248  
6249  
6250  function HeadingEdit({
6251    attributes,
6252    setAttributes,
6253    mergeBlocks,
6254    onReplace,
6255    mergedStyle,
6256    clientId
6257  }) {
6258    const {
6259      textAlign,
6260      content,
6261      level,
6262      placeholder
6263    } = attributes;
6264    const tagName = 'h' + level;
6265    const blockProps = Object(external_wp_blockEditor_["useBlockProps"])({
6266      className: classnames_default()({
6267        [`has-text-align-$textAlign}`]: textAlign
6268      }),
6269      style: mergedStyle
6270    });
6271    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockControls"], {
6272      group: "block"
6273    }, Object(external_wp_element_["createElement"])(HeadingLevelDropdown, {
6274      selectedLevel: level,
6275      onChange: newLevel => setAttributes({
6276        level: newLevel
6277      })
6278    }), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["AlignmentControl"], {
6279      value: textAlign,
6280      onChange: nextAlign => {
6281        setAttributes({
6282          textAlign: nextAlign
6283        });
6284      }
6285    })), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"], Object(esm_extends["a" /* default */])({
6286      identifier: "content",
6287      tagName: tagName,
6288      value: content,
6289      onChange: value => setAttributes({
6290        content: value
6291      }),
6292      onMerge: mergeBlocks,
6293      onSplit: (value, isOriginal) => {
6294        let block;
6295  
6296        if (isOriginal || value) {
6297          block = Object(external_wp_blocks_["createBlock"])('core/heading', { ...attributes,
6298            content: value
6299          });
6300        } else {
6301          block = Object(external_wp_blocks_["createBlock"])('core/paragraph');
6302        }
6303  
6304        if (isOriginal) {
6305          block.clientId = clientId;
6306        }
6307  
6308        return block;
6309      },
6310      onReplace: onReplace,
6311      onRemove: () => onReplace([]),
6312      "aria-label": Object(external_wp_i18n_["__"])('Heading text'),
6313      placeholder: placeholder || Object(external_wp_i18n_["__"])('Heading'),
6314      textAlign: textAlign
6315    }, blockProps)));
6316  }
6317  
6318  /* harmony default export */ var heading_edit = (HeadingEdit);
6319  
6320  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/heading/save.js
6321  
6322  
6323  /**
6324   * External dependencies
6325   */
6326  
6327  /**
6328   * WordPress dependencies
6329   */
6330  
6331  
6332  function heading_save_save({
6333    attributes
6334  }) {
6335    const {
6336      textAlign,
6337      content,
6338      level
6339    } = attributes;
6340    const TagName = 'h' + level;
6341    const className = classnames_default()({
6342      [`has-text-align-$textAlign}`]: textAlign
6343    });
6344    return Object(external_wp_element_["createElement"])(TagName, external_wp_blockEditor_["useBlockProps"].save({
6345      className
6346    }), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6347      value: content
6348    }));
6349  }
6350  
6351  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/heading/shared.js
6352  /**
6353   * Given a node name string for a heading node, returns its numeric level.
6354   *
6355   * @param {string} nodeName Heading node name.
6356   *
6357   * @return {number} Heading level.
6358   */
6359  function getLevelFromHeadingNodeName(nodeName) {
6360    return Number(nodeName.substr(1));
6361  }
6362  
6363  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/heading/transforms.js
6364  /**
6365   * WordPress dependencies
6366   */
6367  
6368  /**
6369   * Internal dependencies
6370   */
6371  
6372  
6373  const {
6374    name: heading_transforms_name
6375  } = {
6376    apiVersion: 2,
6377    name: "core/heading",
6378    title: "Heading",
6379    category: "text",
6380    description: "Introduce new sections and organize content to help visitors (and search engines) understand the structure of your content.",
6381    keywords: ["title", "subtitle"],
6382    textdomain: "default",
6383    attributes: {
6384      textAlign: {
6385        type: "string"
6386      },
6387      content: {
6388        type: "string",
6389        source: "html",
6390        selector: "h1,h2,h3,h4,h5,h6",
6391        "default": "",
6392        __experimentalRole: "content"
6393      },
6394      level: {
6395        type: "number",
6396        "default": 2
6397      },
6398      placeholder: {
6399        type: "string"
6400      }
6401    },
6402    supports: {
6403      align: ["wide", "full"],
6404      anchor: true,
6405      className: false,
6406      color: {
6407        link: true
6408      },
6409      typography: {
6410        fontSize: true,
6411        lineHeight: true,
6412        __experimentalFontWeight: true
6413      },
6414      __experimentalSelector: "h1,h2,h3,h4,h5,h6",
6415      __unstablePasteTextInline: true
6416    },
6417    editorStyle: "wp-block-heading-editor",
6418    style: "wp-block-heading"
6419  };
6420  const heading_transforms_transforms = {
6421    from: [{
6422      type: 'block',
6423      isMultiBlock: true,
6424      blocks: ['core/paragraph'],
6425      transform: attributes => attributes.map(({
6426        content,
6427        anchor
6428      }) => Object(external_wp_blocks_["createBlock"])(heading_transforms_name, {
6429        content,
6430        anchor
6431      }))
6432    }, {
6433      type: 'raw',
6434      selector: 'h1,h2,h3,h4,h5,h6',
6435      schema: ({
6436        phrasingContentSchema,
6437        isPaste
6438      }) => {
6439        const schema = {
6440          children: phrasingContentSchema,
6441          attributes: isPaste ? [] : ['style', 'id']
6442        };
6443        return {
6444          h1: schema,
6445          h2: schema,
6446          h3: schema,
6447          h4: schema,
6448          h5: schema,
6449          h6: schema
6450        };
6451      },
6452  
6453      transform(node) {
6454        const attributes = Object(external_wp_blocks_["getBlockAttributes"])(heading_transforms_name, node.outerHTML);
6455        const {
6456          textAlign
6457        } = node.style || {};
6458        attributes.level = getLevelFromHeadingNodeName(node.nodeName);
6459  
6460        if (textAlign === 'left' || textAlign === 'center' || textAlign === 'right') {
6461          attributes.align = textAlign;
6462        }
6463  
6464        return Object(external_wp_blocks_["createBlock"])(heading_transforms_name, attributes);
6465      }
6466  
6467    }, ...[1, 2, 3, 4, 5, 6].map(level => ({
6468      type: 'prefix',
6469      prefix: Array(level + 1).join('#'),
6470  
6471      transform(content) {
6472        return Object(external_wp_blocks_["createBlock"])(heading_transforms_name, {
6473          level,
6474          content
6475        });
6476      }
6477  
6478    })), ...[1, 2, 3, 4, 5, 6].map(level => ({
6479      type: 'enter',
6480      regExp: new RegExp(`^/(h|H)$level}$`),
6481  
6482      transform(content) {
6483        return Object(external_wp_blocks_["createBlock"])(heading_transforms_name, {
6484          level,
6485          content
6486        });
6487      }
6488  
6489    }))],
6490    to: [{
6491      type: 'block',
6492      isMultiBlock: true,
6493      blocks: ['core/paragraph'],
6494      transform: attributes => attributes.map(({
6495        content,
6496        anchor
6497      }) => Object(external_wp_blocks_["createBlock"])('core/paragraph', {
6498        content,
6499        anchor
6500      }))
6501    }]
6502  };
6503  /* harmony default export */ var heading_transforms = (heading_transforms_transforms);
6504  
6505  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/heading/index.js
6506  /**
6507   * External dependencies
6508   */
6509  
6510  /**
6511   * WordPress dependencies
6512   */
6513  
6514  
6515  
6516  /**
6517   * Internal dependencies
6518   */
6519  
6520  
6521  
6522  const heading_metadata = {
6523    apiVersion: 2,
6524    name: "core/heading",
6525    title: "Heading",
6526    category: "text",
6527    description: "Introduce new sections and organize content to help visitors (and search engines) understand the structure of your content.",
6528    keywords: ["title", "subtitle"],
6529    textdomain: "default",
6530    attributes: {
6531      textAlign: {
6532        type: "string"
6533      },
6534      content: {
6535        type: "string",
6536        source: "html",
6537        selector: "h1,h2,h3,h4,h5,h6",
6538        "default": "",
6539        __experimentalRole: "content"
6540      },
6541      level: {
6542        type: "number",
6543        "default": 2
6544      },
6545      placeholder: {
6546        type: "string"
6547      }
6548    },
6549    supports: {
6550      align: ["wide", "full"],
6551      anchor: true,
6552      className: false,
6553      color: {
6554        link: true
6555      },
6556      typography: {
6557        fontSize: true,
6558        lineHeight: true,
6559        __experimentalFontWeight: true
6560      },
6561      __experimentalSelector: "h1,h2,h3,h4,h5,h6",
6562      __unstablePasteTextInline: true
6563    },
6564    editorStyle: "wp-block-heading-editor",
6565    style: "wp-block-heading"
6566  };
6567  
6568  
6569  const {
6570    name: heading_name
6571  } = heading_metadata;
6572  
6573  const heading_settings = {
6574    icon: library_heading,
6575    example: {
6576      attributes: {
6577        content: Object(external_wp_i18n_["__"])('Code is Poetry'),
6578        level: 2
6579      }
6580    },
6581  
6582    __experimentalLabel(attributes, {
6583      context
6584    }) {
6585      if (context === 'accessibility') {
6586        const {
6587          content,
6588          level
6589        } = attributes;
6590        return Object(external_lodash_["isEmpty"])(content) ? Object(external_wp_i18n_["sprintf"])(
6591        /* translators: accessibility text. %s: heading level. */
6592        Object(external_wp_i18n_["__"])('Level %s. Empty.'), level) : Object(external_wp_i18n_["sprintf"])(
6593        /* translators: accessibility text. 1: heading level. 2: heading content. */
6594        Object(external_wp_i18n_["__"])('Level %1$s. %2$s'), level, content);
6595      }
6596    },
6597  
6598    transforms: heading_transforms,
6599    deprecated: heading_deprecated,
6600  
6601    merge(attributes, attributesToMerge) {
6602      return {
6603        content: (attributes.content || '') + (attributesToMerge.content || '')
6604      };
6605    },
6606  
6607    edit: heading_edit,
6608    save: heading_save_save
6609  };
6610  
6611  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/quote.js
6612  
6613  
6614  /**
6615   * WordPress dependencies
6616   */
6617  
6618  const quote = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
6619    viewBox: "0 0 24 24",
6620    xmlns: "http://www.w3.org/2000/svg"
6621  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
6622    d: "M13 6v6h5.2v4c0 .8-.2 1.4-.5 1.7-.6.6-1.6.6-2.5.5h-.3v1.5h.5c1 0 2.3-.1 3.3-1 .6-.6 1-1.6 1-2.8V6H13zm-9 6h5.2v4c0 .8-.2 1.4-.5 1.7-.6.6-1.6.6-2.5.5h-.3v1.5h.5c1 0 2.3-.1 3.3-1 .6-.6 1-1.6 1-2.8V6H4v6z"
6623  }));
6624  /* harmony default export */ var library_quote = (quote);
6625  
6626  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/quote/deprecated.js
6627  
6628  
6629  /**
6630   * External dependencies
6631   */
6632  
6633  /**
6634   * WordPress dependencies
6635   */
6636  
6637  
6638  const quote_deprecated_blockAttributes = {
6639    value: {
6640      type: 'string',
6641      source: 'html',
6642      selector: 'blockquote',
6643      multiline: 'p',
6644      default: ''
6645    },
6646    citation: {
6647      type: 'string',
6648      source: 'html',
6649      selector: 'cite',
6650      default: ''
6651    },
6652    align: {
6653      type: 'string'
6654    }
6655  };
6656  const quote_deprecated_deprecated = [{
6657    attributes: quote_deprecated_blockAttributes,
6658  
6659    save({
6660      attributes
6661    }) {
6662      const {
6663        align,
6664        value,
6665        citation
6666      } = attributes;
6667      return Object(external_wp_element_["createElement"])("blockquote", {
6668        style: {
6669          textAlign: align ? align : null
6670        }
6671      }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6672        multiline: true,
6673        value: value
6674      }), !external_wp_blockEditor_["RichText"].isEmpty(citation) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6675        tagName: "cite",
6676        value: citation
6677      }));
6678    }
6679  
6680  }, {
6681    attributes: { ...quote_deprecated_blockAttributes,
6682      style: {
6683        type: 'number',
6684        default: 1
6685      }
6686    },
6687  
6688    migrate(attributes) {
6689      if (attributes.style === 2) {
6690        return { ...Object(external_lodash_["omit"])(attributes, ['style']),
6691          className: attributes.className ? attributes.className + ' is-style-large' : 'is-style-large'
6692        };
6693      }
6694  
6695      return attributes;
6696    },
6697  
6698    save({
6699      attributes
6700    }) {
6701      const {
6702        align,
6703        value,
6704        citation,
6705        style
6706      } = attributes;
6707      return Object(external_wp_element_["createElement"])("blockquote", {
6708        className: style === 2 ? 'is-large' : '',
6709        style: {
6710          textAlign: align ? align : null
6711        }
6712      }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6713        multiline: true,
6714        value: value
6715      }), !external_wp_blockEditor_["RichText"].isEmpty(citation) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6716        tagName: "cite",
6717        value: citation
6718      }));
6719    }
6720  
6721  }, {
6722    attributes: { ...quote_deprecated_blockAttributes,
6723      citation: {
6724        type: 'string',
6725        source: 'html',
6726        selector: 'footer',
6727        default: ''
6728      },
6729      style: {
6730        type: 'number',
6731        default: 1
6732      }
6733    },
6734  
6735    save({
6736      attributes
6737    }) {
6738      const {
6739        align,
6740        value,
6741        citation,
6742        style
6743      } = attributes;
6744      return Object(external_wp_element_["createElement"])("blockquote", {
6745        className: `blocks-quote-style-$style}`,
6746        style: {
6747          textAlign: align ? align : null
6748        }
6749      }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6750        multiline: true,
6751        value: value
6752      }), !external_wp_blockEditor_["RichText"].isEmpty(citation) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6753        tagName: "footer",
6754        value: citation
6755      }));
6756    }
6757  
6758  }];
6759  /* harmony default export */ var quote_deprecated = (quote_deprecated_deprecated);
6760  
6761  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/quote/edit.js
6762  
6763  
6764  /**
6765   * External dependencies
6766   */
6767  
6768  /**
6769   * WordPress dependencies
6770   */
6771  
6772  
6773  
6774  
6775  
6776  
6777  const isWebPlatform = external_wp_element_["Platform"].OS === 'web';
6778  function QuoteEdit({
6779    attributes,
6780    setAttributes,
6781    isSelected,
6782    mergeBlocks,
6783    onReplace,
6784    className,
6785    insertBlocksAfter,
6786    mergedStyle
6787  }) {
6788    const {
6789      align,
6790      value,
6791      citation
6792    } = attributes;
6793    const blockProps = Object(external_wp_blockEditor_["useBlockProps"])({
6794      className: classnames_default()(className, {
6795        [`has-text-align-$align}`]: align
6796      }),
6797      style: mergedStyle
6798    });
6799    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockControls"], {
6800      group: "block"
6801    }, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["AlignmentControl"], {
6802      value: align,
6803      onChange: nextAlign => {
6804        setAttributes({
6805          align: nextAlign
6806        });
6807      }
6808    })), Object(external_wp_element_["createElement"])(external_wp_components_["BlockQuotation"], blockProps, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"], {
6809      identifier: "value",
6810      multiline: true,
6811      value: value,
6812      onChange: nextValue => setAttributes({
6813        value: nextValue
6814      }),
6815      onMerge: mergeBlocks,
6816      onRemove: forward => {
6817        const hasEmptyCitation = !citation || citation.length === 0;
6818  
6819        if (!forward && hasEmptyCitation) {
6820          onReplace([]);
6821        }
6822      },
6823      "aria-label": Object(external_wp_i18n_["__"])('Quote text'),
6824      placeholder: // translators: placeholder text used for the quote
6825      Object(external_wp_i18n_["__"])('Add quote'),
6826      onReplace: onReplace,
6827      onSplit: piece => Object(external_wp_blocks_["createBlock"])('core/quote', { ...attributes,
6828        value: piece
6829      }),
6830      __unstableOnSplitMiddle: () => Object(external_wp_blocks_["createBlock"])('core/paragraph'),
6831      textAlign: align
6832    }), (!external_wp_blockEditor_["RichText"].isEmpty(citation) || isSelected) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"], {
6833      identifier: "citation",
6834      tagName: isWebPlatform ? 'cite' : undefined,
6835      style: {
6836        display: 'block'
6837      },
6838      value: citation,
6839      onChange: nextCitation => setAttributes({
6840        citation: nextCitation
6841      }),
6842      __unstableMobileNoFocusOnMount: true,
6843      "aria-label": Object(external_wp_i18n_["__"])('Quote citation text'),
6844      placeholder: // translators: placeholder text used for the citation
6845      Object(external_wp_i18n_["__"])('Add citation'),
6846      className: "wp-block-quote__citation",
6847      textAlign: align,
6848      __unstableOnSplitAtEnd: () => insertBlocksAfter(Object(external_wp_blocks_["createBlock"])('core/paragraph'))
6849    })));
6850  }
6851  
6852  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/quote/save.js
6853  
6854  
6855  /**
6856   * External dependencies
6857   */
6858  
6859  /**
6860   * WordPress dependencies
6861   */
6862  
6863  
6864  function quote_save_save({
6865    attributes
6866  }) {
6867    const {
6868      align,
6869      value,
6870      citation
6871    } = attributes;
6872    const className = classnames_default()({
6873      [`has-text-align-$align}`]: align
6874    });
6875    return Object(external_wp_element_["createElement"])("blockquote", external_wp_blockEditor_["useBlockProps"].save({
6876      className
6877    }), Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6878      multiline: true,
6879      value: value
6880    }), !external_wp_blockEditor_["RichText"].isEmpty(citation) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
6881      tagName: "cite",
6882      value: citation
6883    }));
6884  }
6885  
6886  // EXTERNAL MODULE: external ["wp","richText"]
6887  var external_wp_richText_ = __webpack_require__("qRz9");
6888  
6889  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/quote/transforms.js
6890  /**
6891   * WordPress dependencies
6892   */
6893  
6894  
6895  const quote_transforms_transforms = {
6896    from: [{
6897      type: 'block',
6898      isMultiBlock: true,
6899      blocks: ['core/paragraph'],
6900      transform: attributes => {
6901        return Object(external_wp_blocks_["createBlock"])('core/quote', {
6902          value: Object(external_wp_richText_["toHTMLString"])({
6903            value: Object(external_wp_richText_["join"])(attributes.map(({
6904              content
6905            }) => Object(external_wp_richText_["create"])({
6906              html: content
6907            })), '\u2028'),
6908            multilineTag: 'p'
6909          }),
6910          anchor: attributes.anchor
6911        });
6912      }
6913    }, {
6914      type: 'block',
6915      blocks: ['core/heading'],
6916      transform: ({
6917        content,
6918        anchor
6919      }) => {
6920        return Object(external_wp_blocks_["createBlock"])('core/quote', {
6921          value: `<p>$content}</p>`,
6922          anchor
6923        });
6924      }
6925    }, {
6926      type: 'block',
6927      blocks: ['core/pullquote'],
6928      transform: ({
6929        value,
6930        citation,
6931        anchor
6932      }) => Object(external_wp_blocks_["createBlock"])('core/quote', {
6933        value,
6934        citation,
6935        anchor
6936      })
6937    }, {
6938      type: 'prefix',
6939      prefix: '>',
6940      transform: content => {
6941        return Object(external_wp_blocks_["createBlock"])('core/quote', {
6942          value: `<p>$content}</p>`
6943        });
6944      }
6945    }, {
6946      type: 'raw',
6947      isMatch: node => {
6948        const isParagraphOrSingleCite = (() => {
6949          let hasCitation = false;
6950          return child => {
6951            // Child is a paragraph.
6952            if (child.nodeName === 'P') {
6953              return true;
6954            } // Child is a cite and no other cite child exists before it.
6955  
6956  
6957            if (!hasCitation && child.nodeName === 'CITE') {
6958              hasCitation = true;
6959              return true;
6960            }
6961          };
6962        })();
6963  
6964        return node.nodeName === 'BLOCKQUOTE' && // The quote block can only handle multiline paragraph
6965        // content with an optional cite child.
6966        Array.from(node.childNodes).every(isParagraphOrSingleCite);
6967      },
6968      schema: ({
6969        phrasingContentSchema
6970      }) => ({
6971        blockquote: {
6972          children: {
6973            p: {
6974              children: phrasingContentSchema
6975            },
6976            cite: {
6977              children: phrasingContentSchema
6978            }
6979          }
6980        }
6981      })
6982    }],
6983    to: [{
6984      type: 'block',
6985      blocks: ['core/paragraph'],
6986      transform: ({
6987        value,
6988        citation
6989      }) => {
6990        const paragraphs = [];
6991  
6992        if (value && value !== '<p></p>') {
6993          paragraphs.push(...Object(external_wp_richText_["split"])(Object(external_wp_richText_["create"])({
6994            html: value,
6995            multilineTag: 'p'
6996          }), '\u2028').map(piece => Object(external_wp_blocks_["createBlock"])('core/paragraph', {
6997            content: Object(external_wp_richText_["toHTMLString"])({
6998              value: piece
6999            })
7000          })));
7001        }
7002  
7003        if (citation && citation !== '<p></p>') {
7004          paragraphs.push(Object(external_wp_blocks_["createBlock"])('core/paragraph', {
7005            content: citation
7006          }));
7007        }
7008  
7009        if (paragraphs.length === 0) {
7010          return Object(external_wp_blocks_["createBlock"])('core/paragraph', {
7011            content: ''
7012          });
7013        }
7014  
7015        return paragraphs;
7016      }
7017    }, {
7018      type: 'block',
7019      blocks: ['core/heading'],
7020      transform: ({
7021        value,
7022        citation,
7023        ...attrs
7024      }) => {
7025        // If there is no quote content, use the citation as the
7026        // content of the resulting heading. A nonexistent citation
7027        // will result in an empty heading.
7028        if (value === '<p></p>') {
7029          return Object(external_wp_blocks_["createBlock"])('core/heading', {
7030            content: citation
7031          });
7032        }
7033  
7034        const pieces = Object(external_wp_richText_["split"])(Object(external_wp_richText_["create"])({
7035          html: value,
7036          multilineTag: 'p'
7037        }), '\u2028');
7038        const headingBlock = Object(external_wp_blocks_["createBlock"])('core/heading', {
7039          content: Object(external_wp_richText_["toHTMLString"])({
7040            value: pieces[0]
7041          })
7042        });
7043  
7044        if (!citation && pieces.length === 1) {
7045          return headingBlock;
7046        }
7047  
7048        const quotePieces = pieces.slice(1);
7049        const quoteBlock = Object(external_wp_blocks_["createBlock"])('core/quote', { ...attrs,
7050          citation,
7051          value: Object(external_wp_richText_["toHTMLString"])({
7052            value: quotePieces.length ? Object(external_wp_richText_["join"])(pieces.slice(1), '\u2028') : Object(external_wp_richText_["create"])(),
7053            multilineTag: 'p'
7054          })
7055        });
7056        return [headingBlock, quoteBlock];
7057      }
7058    }, {
7059      type: 'block',
7060      blocks: ['core/pullquote'],
7061      transform: ({
7062        value,
7063        citation,
7064        anchor
7065      }) => {
7066        return Object(external_wp_blocks_["createBlock"])('core/pullquote', {
7067          value,
7068          citation,
7069          anchor
7070        });
7071      }
7072    }]
7073  };
7074  /* harmony default export */ var quote_transforms = (quote_transforms_transforms);
7075  
7076  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/quote/index.js
7077  /**
7078   * WordPress dependencies
7079   */
7080  
7081  
7082  /**
7083   * Internal dependencies
7084   */
7085  
7086  
7087  
7088  const quote_metadata = {
7089    apiVersion: 2,
7090    name: "core/quote",
7091    title: "Quote",
7092    category: "text",
7093    description: "Give quoted text visual emphasis. \"In quoting others, we cite ourselves.\" \u2014 Julio Cort\xE1zar",
7094    keywords: ["blockquote", "cite"],
7095    textdomain: "default",
7096    attributes: {
7097      value: {
7098        type: "string",
7099        source: "html",
7100        selector: "blockquote",
7101        multiline: "p",
7102        "default": "",
7103        __experimentalRole: "content"
7104      },
7105      citation: {
7106        type: "string",
7107        source: "html",
7108        selector: "cite",
7109        "default": "",
7110        __experimentalRole: "content"
7111      },
7112      align: {
7113        type: "string"
7114      }
7115    },
7116    supports: {
7117      anchor: true
7118    },
7119    styles: [{
7120      name: "default",
7121      label: "Default",
7122      isDefault: true
7123    }, {
7124      name: "large",
7125      label: "Large"
7126    }],
7127    editorStyle: "wp-block-quote-editor",
7128    style: "wp-block-quote"
7129  };
7130  
7131  
7132  const {
7133    name: quote_name
7134  } = quote_metadata;
7135  
7136  const quote_settings = {
7137    icon: library_quote,
7138    example: {
7139      attributes: {
7140        value: '<p>' + Object(external_wp_i18n_["__"])('In quoting others, we cite ourselves.') + '</p>',
7141        citation: 'Julio Cortázar',
7142        className: 'is-style-large'
7143      }
7144    },
7145    transforms: quote_transforms,
7146    edit: QuoteEdit,
7147    save: quote_save_save,
7148  
7149    merge(attributes, {
7150      value,
7151      citation
7152    }) {
7153      // Quote citations cannot be merged. Pick the second one unless it's
7154      // empty.
7155      if (!citation) {
7156        citation = attributes.citation;
7157      }
7158  
7159      if (!value || value === '<p></p>') {
7160        return { ...attributes,
7161          citation
7162        };
7163      }
7164  
7165      return { ...attributes,
7166        value: attributes.value + value,
7167        citation
7168      };
7169    },
7170  
7171    deprecated: quote_deprecated
7172  };
7173  
7174  // CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/gallery.js
7175  
7176  
7177  /**
7178   * WordPress dependencies
7179   */
7180  
7181  const gallery = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
7182    viewBox: "0 0 24 24",
7183    xmlns: "http://www.w3.org/2000/svg"
7184  }, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
7185    d: "M20.2 8v11c0 .7-.6 1.2-1.2 1.2H6v1.5h13c1.5 0 2.7-1.2 2.7-2.8V8h-1.5zM18 16.4V4.6c0-.9-.7-1.6-1.6-1.6H4.6C3.7 3 3 3.7 3 4.6v11.8c0 .9.7 1.6 1.6 1.6h11.8c.9 0 1.6-.7 1.6-1.6zM4.5 4.6c0-.1.1-.1.1-.1h11.8c.1 0 .1.1.1.1V12l-2.3-1.7c-.3-.2-.6-.2-.9 0l-2.9 2.1L8 11.3c-.2-.1-.5-.1-.7 0l-2.9 1.5V4.6zm0 11.8v-1.8l3.2-1.7 2.4 1.2c.2.1.5.1.8-.1l2.8-2 2.8 2v2.5c0 .1-.1.1-.1.1H4.6c0-.1-.1-.2-.1-.2z"
7186  }));
7187  /* harmony default export */ var library_gallery = (gallery);
7188  
7189  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/gallery/shared.js
7190  /**
7191   * External dependencies
7192   */
7193  
7194  function defaultColumnsNumber(attributes) {
7195    return Math.min(3, attributes.images.length);
7196  }
7197  const shared_pickRelevantMediaFiles = (image, sizeSlug = 'large') => {
7198    const imageProps = Object(external_lodash_["pick"])(image, ['alt', 'id', 'link', 'caption']);
7199    imageProps.url = Object(external_lodash_["get"])(image, ['sizes', sizeSlug, 'url']) || Object(external_lodash_["get"])(image, ['media_details', 'sizes', sizeSlug, 'source_url']) || image.url;
7200    const fullUrl = Object(external_lodash_["get"])(image, ['sizes', 'full', 'url']) || Object(external_lodash_["get"])(image, ['media_details', 'sizes', 'full', 'source_url']);
7201  
7202    if (fullUrl) {
7203      imageProps.fullUrl = fullUrl;
7204    }
7205  
7206    return imageProps;
7207  };
7208  
7209  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/gallery/deprecated.js
7210  
7211  
7212  /**
7213   * External dependencies
7214   */
7215  
7216  
7217  /**
7218   * WordPress dependencies
7219   */
7220  
7221  
7222  /**
7223   * Internal dependencies
7224   */
7225  
7226  
7227  const gallery_deprecated_deprecated = [{
7228    attributes: {
7229      images: {
7230        type: 'array',
7231        default: [],
7232        source: 'query',
7233        selector: '.blocks-gallery-item',
7234        query: {
7235          url: {
7236            type: 'string',
7237            source: 'attribute',
7238            selector: 'img',
7239            attribute: 'src'
7240          },
7241          fullUrl: {
7242            type: 'string',
7243            source: 'attribute',
7244            selector: 'img',
7245            attribute: 'data-full-url'
7246          },
7247          link: {
7248            type: 'string',
7249            source: 'attribute',
7250            selector: 'img',
7251            attribute: 'data-link'
7252          },
7253          alt: {
7254            type: 'string',
7255            source: 'attribute',
7256            selector: 'img',
7257            attribute: 'alt',
7258            default: ''
7259          },
7260          id: {
7261            type: 'string',
7262            source: 'attribute',
7263            selector: 'img',
7264            attribute: 'data-id'
7265          },
7266          caption: {
7267            type: 'string',
7268            source: 'html',
7269            selector: '.blocks-gallery-item__caption'
7270          }
7271        }
7272      },
7273      ids: {
7274        type: 'array',
7275        items: {
7276          type: 'number'
7277        },
7278        default: []
7279      },
7280      columns: {
7281        type: 'number',
7282        minimum: 1,
7283        maximum: 8
7284      },
7285      caption: {
7286        type: 'string',
7287        source: 'html',
7288        selector: '.blocks-gallery-caption'
7289      },
7290      imageCrop: {
7291        type: 'boolean',
7292        default: true
7293      },
7294      linkTo: {
7295        type: 'string',
7296        default: 'none'
7297      },
7298      sizeSlug: {
7299        type: 'string',
7300        default: 'large'
7301      }
7302    },
7303    supports: {
7304      align: true
7305    },
7306  
7307    isEligible({
7308      linkTo
7309    }) {
7310      return !linkTo || linkTo === 'attachment' || linkTo === 'media';
7311    },
7312  
7313    migrate(attributes) {
7314      let linkTo = attributes.linkTo;
7315  
7316      if (!attributes.linkTo) {
7317        linkTo = 'none';
7318      } else if (attributes.linkTo === 'attachment') {
7319        linkTo = 'post';
7320      } else if (attributes.linkTo === 'media') {
7321        linkTo = 'file';
7322      }
7323  
7324      return { ...attributes,
7325        linkTo
7326      };
7327    },
7328  
7329    save({
7330      attributes
7331    }) {
7332      const {
7333        images,
7334        columns = defaultColumnsNumber(attributes),
7335        imageCrop,
7336        caption,
7337        linkTo
7338      } = attributes;
7339      return Object(external_wp_element_["createElement"])("figure", {
7340        className: `columns-$columns} $imageCrop ? 'is-cropped' : ''}`
7341      }, Object(external_wp_element_["createElement"])("ul", {
7342        className: "blocks-gallery-grid"
7343      }, images.map(image => {
7344        let href;
7345  
7346        switch (linkTo) {
7347          case 'media':
7348            href = image.fullUrl || image.url;
7349            break;
7350  
7351          case 'attachment':
7352            href = image.link;
7353            break;
7354        }
7355  
7356        const img = Object(external_wp_element_["createElement"])("img", {
7357          src: image.url,
7358          alt: image.alt,
7359          "data-id": image.id,
7360          "data-full-url": image.fullUrl,
7361          "data-link": image.link,
7362          className: image.id ? `wp-image-$image.id}` : null
7363        });
7364        return Object(external_wp_element_["createElement"])("li", {
7365          key: image.id || image.url,
7366          className: "blocks-gallery-item"
7367        }, Object(external_wp_element_["createElement"])("figure", null, href ? Object(external_wp_element_["createElement"])("a", {
7368          href: href
7369        }, img) : img, !external_wp_blockEditor_["RichText"].isEmpty(image.caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
7370          tagName: "figcaption",
7371          className: "blocks-gallery-item__caption",
7372          value: image.caption
7373        })));
7374      })), !external_wp_blockEditor_["RichText"].isEmpty(caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
7375        tagName: "figcaption",
7376        className: "blocks-gallery-caption",
7377        value: caption
7378      }));
7379    }
7380  
7381  }, {
7382    attributes: {
7383      images: {
7384        type: 'array',
7385        default: [],
7386        source: 'query',
7387        selector: '.blocks-gallery-item',
7388        query: {
7389          url: {
7390            source: 'attribute',
7391            selector: 'img',
7392            attribute: 'src'
7393          },
7394          fullUrl: {
7395            source: 'attribute',
7396            selector: 'img',
7397            attribute: 'data-full-url'
7398          },
7399          link: {
7400            source: 'attribute',
7401            selector: 'img',
7402            attribute: 'data-link'
7403          },
7404          alt: {
7405            source: 'attribute',
7406            selector: 'img',
7407            attribute: 'alt',
7408            default: ''
7409          },
7410          id: {
7411            source: 'attribute',
7412            selector: 'img',
7413            attribute: 'data-id'
7414          },
7415          caption: {
7416            type: 'string',
7417            source: 'html',
7418            selector: '.blocks-gallery-item__caption'
7419          }
7420        }
7421      },
7422      ids: {
7423        type: 'array',
7424        default: []
7425      },
7426      columns: {
7427        type: 'number'
7428      },
7429      caption: {
7430        type: 'string',
7431        source: 'html',
7432        selector: '.blocks-gallery-caption'
7433      },
7434      imageCrop: {
7435        type: 'boolean',
7436        default: true
7437      },
7438      linkTo: {
7439        type: 'string',
7440        default: 'none'
7441      }
7442    },
7443    supports: {
7444      align: true
7445    },
7446  
7447    isEligible({
7448      ids
7449    }) {
7450      return ids && ids.some(id => typeof id === 'string');
7451    },
7452  
7453    migrate(attributes) {
7454      return { ...attributes,
7455        ids: Object(external_lodash_["map"])(attributes.ids, id => {
7456          const parsedId = parseInt(id, 10);
7457          return Number.isInteger(parsedId) ? parsedId : null;
7458        })
7459      };
7460    },
7461  
7462    save({
7463      attributes
7464    }) {
7465      const {
7466        images,
7467        columns = defaultColumnsNumber(attributes),
7468        imageCrop,
7469        caption,
7470        linkTo
7471      } = attributes;
7472      return Object(external_wp_element_["createElement"])("figure", {
7473        className: `columns-$columns} $imageCrop ? 'is-cropped' : ''}`
7474      }, Object(external_wp_element_["createElement"])("ul", {
7475        className: "blocks-gallery-grid"
7476      }, images.map(image => {
7477        let href;
7478  
7479        switch (linkTo) {
7480          case 'media':
7481            href = image.fullUrl || image.url;
7482            break;
7483  
7484          case 'attachment':
7485            href = image.link;
7486            break;
7487        }
7488  
7489        const img = Object(external_wp_element_["createElement"])("img", {
7490          src: image.url,
7491          alt: image.alt,
7492          "data-id": image.id,
7493          "data-full-url": image.fullUrl,
7494          "data-link": image.link,
7495          className: image.id ? `wp-image-$image.id}` : null
7496        });
7497        return Object(external_wp_element_["createElement"])("li", {
7498          key: image.id || image.url,
7499          className: "blocks-gallery-item"
7500        }, Object(external_wp_element_["createElement"])("figure", null, href ? Object(external_wp_element_["createElement"])("a", {
7501          href: href
7502        }, img) : img, !external_wp_blockEditor_["RichText"].isEmpty(image.caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
7503          tagName: "figcaption",
7504          className: "blocks-gallery-item__caption",
7505          value: image.caption
7506        })));
7507      })), !external_wp_blockEditor_["RichText"].isEmpty(caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
7508        tagName: "figcaption",
7509        className: "blocks-gallery-caption",
7510        value: caption
7511      }));
7512    }
7513  
7514  }, {
7515    attributes: {
7516      images: {
7517        type: 'array',
7518        default: [],
7519        source: 'query',
7520        selector: 'ul.wp-block-gallery .blocks-gallery-item',
7521        query: {
7522          url: {
7523            source: 'attribute',
7524            selector: 'img',
7525            attribute: 'src'
7526          },
7527          fullUrl: {
7528            source: 'attribute',
7529            selector: 'img',
7530            attribute: 'data-full-url'
7531          },
7532          alt: {
7533            source: 'attribute',
7534            selector: 'img',
7535            attribute: 'alt',
7536            default: ''
7537          },
7538          id: {
7539            source: 'attribute',
7540            selector: 'img',
7541            attribute: 'data-id'
7542          },
7543          link: {
7544            source: 'attribute',
7545            selector: 'img',
7546            attribute: 'data-link'
7547          },
7548          caption: {
7549            type: 'array',
7550            source: 'children',
7551            selector: 'figcaption'
7552          }
7553        }
7554      },
7555      ids: {
7556        type: 'array',
7557        default: []
7558      },
7559      columns: {
7560        type: 'number'
7561      },
7562      imageCrop: {
7563        type: 'boolean',
7564        default: true
7565      },
7566      linkTo: {
7567        type: 'string',
7568        default: 'none'
7569      }
7570    },
7571    supports: {
7572      align: true
7573    },
7574  
7575    save({
7576      attributes
7577    }) {
7578      const {
7579        images,
7580        columns = defaultColumnsNumber(attributes),
7581        imageCrop,
7582        linkTo
7583      } = attributes;
7584      return Object(external_wp_element_["createElement"])("ul", {
7585        className: `columns-$columns} $imageCrop ? 'is-cropped' : ''}`
7586      }, images.map(image => {
7587        let href;
7588  
7589        switch (linkTo) {
7590          case 'media':
7591            href = image.fullUrl || image.url;
7592            break;
7593  
7594          case 'attachment':
7595            href = image.link;
7596            break;
7597        }
7598  
7599        const img = Object(external_wp_element_["createElement"])("img", {
7600          src: image.url,
7601          alt: image.alt,
7602          "data-id": image.id,
7603          "data-full-url": image.fullUrl,
7604          "data-link": image.link,
7605          className: image.id ? `wp-image-$image.id}` : null
7606        });
7607        return Object(external_wp_element_["createElement"])("li", {
7608          key: image.id || image.url,
7609          className: "blocks-gallery-item"
7610        }, Object(external_wp_element_["createElement"])("figure", null, href ? Object(external_wp_element_["createElement"])("a", {
7611          href: href
7612        }, img) : img, image.caption && image.caption.length > 0 && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
7613          tagName: "figcaption",
7614          value: image.caption
7615        })));
7616      }));
7617    }
7618  
7619  }, {
7620    attributes: {
7621      images: {
7622        type: 'array',
7623        default: [],
7624        source: 'query',
7625        selector: 'ul.wp-block-gallery .blocks-gallery-item',
7626        query: {
7627          url: {
7628            source: 'attribute',
7629            selector: 'img',
7630            attribute: 'src'
7631          },
7632          alt: {
7633            source: 'attribute',
7634            selector: 'img',
7635            attribute: 'alt',
7636            default: ''
7637          },
7638          id: {
7639            source: 'attribute',
7640            selector: 'img',
7641            attribute: 'data-id'
7642          },
7643          link: {
7644            source: 'attribute',
7645            selector: 'img',
7646            attribute: 'data-link'
7647          },
7648          caption: {
7649            type: 'array',
7650            source: 'children',
7651            selector: 'figcaption'
7652          }
7653        }
7654      },
7655      columns: {
7656        type: 'number'
7657      },
7658      imageCrop: {
7659        type: 'boolean',
7660        default: true
7661      },
7662      linkTo: {
7663        type: 'string',
7664        default: 'none'
7665      }
7666    },
7667  
7668    isEligible({
7669      images,
7670      ids
7671    }) {
7672      return images && images.length > 0 && (!ids && images || ids && images && ids.length !== images.length || Object(external_lodash_["some"])(images, (id, index) => {
7673        if (!id && ids[index] !== null) {
7674          return true;
7675        }
7676  
7677        return parseInt(id, 10) !== ids[index];
7678      }));
7679    },
7680  
7681    migrate(attributes) {
7682      return { ...attributes,
7683        ids: Object(external_lodash_["map"])(attributes.images, ({
7684          id
7685        }) => {
7686          if (!id) {
7687            return null;
7688          }
7689  
7690          return parseInt(id, 10);
7691        })
7692      };
7693    },
7694  
7695    supports: {
7696      align: true
7697    },
7698  
7699    save({
7700      attributes
7701    }) {
7702      const {
7703        images,
7704        columns = defaultColumnsNumber(attributes),
7705        imageCrop,
7706        linkTo
7707      } = attributes;
7708      return Object(external_wp_element_["createElement"])("ul", {
7709        className: `columns-$columns} $imageCrop ? 'is-cropped' : ''}`
7710      }, images.map(image => {
7711        let href;
7712  
7713        switch (linkTo) {
7714          case 'media':
7715            href = image.url;
7716            break;
7717  
7718          case 'attachment':
7719            href = image.link;
7720            break;
7721        }
7722  
7723        const img = Object(external_wp_element_["createElement"])("img", {
7724          src: image.url,
7725          alt: image.alt,
7726          "data-id": image.id,
7727          "data-link": image.link,
7728          className: image.id ? `wp-image-$image.id}` : null
7729        });
7730        return Object(external_wp_element_["createElement"])("li", {
7731          key: image.id || image.url,
7732          className: "blocks-gallery-item"
7733        }, Object(external_wp_element_["createElement"])("figure", null, href ? Object(external_wp_element_["createElement"])("a", {
7734          href: href
7735        }, img) : img, image.caption && image.caption.length > 0 && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
7736          tagName: "figcaption",
7737          value: image.caption
7738        })));
7739      }));
7740    }
7741  
7742  }, {
7743    attributes: {
7744      images: {
7745        type: 'array',
7746        default: [],
7747        source: 'query',
7748        selector: 'div.wp-block-gallery figure.blocks-gallery-image img',
7749        query: {
7750          url: {
7751            source: 'attribute',
7752            attribute: 'src'
7753          },
7754          alt: {
7755            source: 'attribute',
7756            attribute: 'alt',
7757            default: ''
7758          },
7759          id: {
7760            source: 'attribute',
7761            attribute: 'data-id'
7762          }
7763        }
7764      },
7765      columns: {
7766        type: 'number'
7767      },
7768      imageCrop: {
7769        type: 'boolean',
7770        default: true
7771      },
7772      linkTo: {
7773        type: 'string',
7774        default: 'none'
7775      },
7776      align: {
7777        type: 'string',
7778        default: 'none'
7779      }
7780    },
7781    supports: {
7782      align: true
7783    },
7784  
7785    save({
7786      attributes
7787    }) {
7788      const {
7789        images,
7790        columns = defaultColumnsNumber(attributes),
7791        align,
7792        imageCrop,
7793        linkTo
7794      } = attributes;
7795      const className = classnames_default()(`columns-$columns}`, {
7796        alignnone: align === 'none',
7797        'is-cropped': imageCrop
7798      });
7799      return Object(external_wp_element_["createElement"])("div", {
7800        className: className
7801      }, images.map(image => {
7802        let href;
7803  
7804        switch (linkTo) {
7805          case 'media':
7806            href = image.url;
7807            break;
7808  
7809          case 'attachment':
7810            href = image.link;
7811            break;
7812        }
7813  
7814        const img = Object(external_wp_element_["createElement"])("img", {
7815          src: image.url,
7816          alt: image.alt,
7817          "data-id": image.id
7818        });
7819        return Object(external_wp_element_["createElement"])("figure", {
7820          key: image.id || image.url,
7821          className: "blocks-gallery-image"
7822        }, href ? Object(external_wp_element_["createElement"])("a", {
7823          href: href
7824        }, img) : img);
7825      }));
7826    }
7827  
7828  }];
7829  /* harmony default export */ var gallery_deprecated = (gallery_deprecated_deprecated);
7830  
7831  // EXTERNAL MODULE: external ["wp","viewport"]
7832  var external_wp_viewport_ = __webpack_require__("KEfo");
7833  
7834  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/gallery/shared-icon.js
7835  
7836  
7837  /**
7838   * WordPress dependencies
7839   */
7840  
7841  
7842  const sharedIcon = Object(external_wp_element_["createElement"])(external_wp_blockEditor_["BlockIcon"], {
7843    icon: library_gallery
7844  });
7845  
7846  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/chevron-left.js
7847  var chevron_left = __webpack_require__("2gm7");
7848  
7849  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/chevron-right.js
7850  var chevron_right = __webpack_require__("1iEr");
7851  
7852  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/edit.js + 1 modules
7853  var library_edit = __webpack_require__("B9Az");
7854  
7855  // EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/close-small.js
7856  var close_small = __webpack_require__("bWcr");
7857  
7858  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/gallery/constants.js
7859  const constants_LINK_DESTINATION_NONE = 'none';
7860  const constants_LINK_DESTINATION_MEDIA = 'file';
7861  const constants_LINK_DESTINATION_ATTACHMENT = 'post';
7862  
7863  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/gallery/gallery-image.js
7864  
7865  
7866  /**
7867   * External dependencies
7868   */
7869  
7870  
7871  /**
7872   * WordPress dependencies
7873   */
7874  
7875  
7876  
7877  
7878  
7879  
7880  
7881  
7882  
7883  
7884  
7885  /**
7886   * Internal dependencies
7887   */
7888  
7889  
7890  
7891  
7892  const gallery_image_isTemporaryImage = (id, url) => !id && Object(external_wp_blob_["isBlobURL"])(url);
7893  
7894  class gallery_image_GalleryImage extends external_wp_element_["Component"] {
7895    constructor() {
7896      super(...arguments);
7897      this.onSelectImage = this.onSelectImage.bind(this);
7898      this.onRemoveImage = this.onRemoveImage.bind(this);
7899      this.bindContainer = this.bindContainer.bind(this);
7900      this.onEdit = this.onEdit.bind(this);
7901      this.onSelectImageFromLibrary = this.onSelectImageFromLibrary.bind(this);
7902      this.onSelectCustomURL = this.onSelectCustomURL.bind(this);
7903      this.state = {
7904        isEditing: false
7905      };
7906    }
7907  
7908    bindContainer(ref) {
7909      this.container = ref;
7910    }
7911  
7912    onSelectImage() {
7913      if (!this.props.isSelected) {
7914        this.props.onSelect();
7915      }
7916    }
7917  
7918    onRemoveImage(event) {
7919      if (this.container === this.container.ownerDocument.activeElement && this.props.isSelected && [external_wp_keycodes_["BACKSPACE"], external_wp_keycodes_["DELETE"]].indexOf(event.keyCode) !== -1) {
7920        event.stopPropagation();
7921        event.preventDefault();
7922        this.props.onRemove();
7923      }
7924    }
7925  
7926    onEdit() {
7927      this.setState({
7928        isEditing: true
7929      });
7930    }
7931  
7932    componentDidUpdate() {
7933      const {
7934        image,
7935        url,
7936        __unstableMarkNextChangeAsNotPersistent
7937      } = this.props;
7938  
7939      if (image && !url) {
7940        __unstableMarkNextChangeAsNotPersistent();
7941  
7942        this.props.setAttributes({
7943          url: image.source_url,
7944          alt: image.alt_text
7945        });
7946      }
7947    }
7948  
7949    deselectOnBlur() {
7950      this.props.onDeselect();
7951    }
7952  
7953    onSelectImageFromLibrary(media) {
7954      const {
7955        setAttributes,
7956        id,
7957        url,
7958        alt,
7959        caption,
7960        sizeSlug
7961      } = this.props;
7962  
7963      if (!media || !media.url) {
7964        return;
7965      }
7966  
7967      let mediaAttributes = shared_pickRelevantMediaFiles(media, sizeSlug); // If the current image is temporary but an alt text was meanwhile
7968      // written by the user, make sure the text is not overwritten.
7969  
7970      if (gallery_image_isTemporaryImage(id, url)) {
7971        if (alt) {
7972          mediaAttributes = Object(external_lodash_["omit"])(mediaAttributes, ['alt']);
7973        }
7974      } // If a caption text was meanwhile written by the user,
7975      // make sure the text is not overwritten by empty captions.
7976  
7977  
7978      if (caption && !Object(external_lodash_["get"])(mediaAttributes, ['caption'])) {
7979        mediaAttributes = Object(external_lodash_["omit"])(mediaAttributes, ['caption']);
7980      }
7981  
7982      setAttributes(mediaAttributes);
7983      this.setState({
7984        isEditing: false
7985      });
7986    }
7987  
7988    onSelectCustomURL(newURL) {
7989      const {
7990        setAttributes,
7991        url
7992      } = this.props;
7993  
7994      if (newURL !== url) {
7995        setAttributes({
7996          url: newURL,
7997          id: undefined
7998        });
7999        this.setState({
8000          isEditing: false
8001        });
8002      }
8003    }
8004  
8005    render() {
8006      const {
8007        url,
8008        alt,
8009        id,
8010        linkTo,
8011        link,
8012        isFirstItem,
8013        isLastItem,
8014        isSelected,
8015        caption,
8016        onRemove,
8017        onMoveForward,
8018        onMoveBackward,
8019        setAttributes,
8020        'aria-label': ariaLabel
8021      } = this.props;
8022      const {
8023        isEditing
8024      } = this.state;
8025      let href;
8026  
8027      switch (linkTo) {
8028        case constants_LINK_DESTINATION_MEDIA:
8029          href = url;
8030          break;
8031  
8032        case constants_LINK_DESTINATION_ATTACHMENT:
8033          href = link;
8034          break;
8035      }
8036  
8037      const img = // Disable reason: Image itself is not meant to be interactive, but should
8038      // direct image selection and unfocus caption fields.
8039  
8040      /* eslint-disable jsx-a11y/no-noninteractive-element-interactions */
8041      Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])("img", {
8042        src: url,
8043        alt: alt,
8044        "data-id": id,
8045        onKeyDown: this.onRemoveImage,
8046        tabIndex: "0",
8047        "aria-label": ariaLabel,
8048        ref: this.bindContainer
8049      }), Object(external_wp_blob_["isBlobURL"])(url) && Object(external_wp_element_["createElement"])(external_wp_components_["Spinner"], null))
8050      /* eslint-enable jsx-a11y/no-noninteractive-element-interactions */
8051      ;
8052      const className = classnames_default()({
8053        'is-selected': isSelected,
8054        'is-transient': Object(external_wp_blob_["isBlobURL"])(url)
8055      });
8056      return (// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-noninteractive-element-interactions
8057        Object(external_wp_element_["createElement"])("figure", {
8058          className: className,
8059          onClick: this.onSelectImage,
8060          onFocus: this.onSelectImage
8061        }, !isEditing && (href ? Object(external_wp_element_["createElement"])("a", {
8062          href: href
8063        }, img) : img), isEditing && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["MediaPlaceholder"], {
8064          labels: {
8065            title: Object(external_wp_i18n_["__"])('Edit gallery image')
8066          },
8067          icon: library_image,
8068          onSelect: this.onSelectImageFromLibrary,
8069          onSelectURL: this.onSelectCustomURL,
8070          accept: "image/*",
8071          allowedTypes: ['image'],
8072          value: {
8073            id,
8074            src: url
8075          }
8076        }), Object(external_wp_element_["createElement"])(external_wp_components_["ButtonGroup"], {
8077          className: "block-library-gallery-item__inline-menu is-left"
8078        }, Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
8079          icon: chevron_left["a" /* default */],
8080          onClick: isFirstItem ? undefined : onMoveBackward,
8081          label: Object(external_wp_i18n_["__"])('Move image backward'),
8082          "aria-disabled": isFirstItem,
8083          disabled: !isSelected
8084        }), Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
8085          icon: chevron_right["a" /* default */],
8086          onClick: isLastItem ? undefined : onMoveForward,
8087          label: Object(external_wp_i18n_["__"])('Move image forward'),
8088          "aria-disabled": isLastItem,
8089          disabled: !isSelected
8090        })), Object(external_wp_element_["createElement"])(external_wp_components_["ButtonGroup"], {
8091          className: "block-library-gallery-item__inline-menu is-right"
8092        }, Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
8093          icon: library_edit["a" /* default */],
8094          onClick: this.onEdit,
8095          label: Object(external_wp_i18n_["__"])('Replace image'),
8096          disabled: !isSelected
8097        }), Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
8098          icon: close_small["a" /* default */],
8099          onClick: onRemove,
8100          label: Object(external_wp_i18n_["__"])('Remove image'),
8101          disabled: !isSelected
8102        })), !isEditing && (isSelected || caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"], {
8103          tagName: "figcaption",
8104          "aria-label": Object(external_wp_i18n_["__"])('Image caption text'),
8105          placeholder: isSelected ? Object(external_wp_i18n_["__"])('Add caption') : null,
8106          value: caption,
8107          onChange: newCaption => setAttributes({
8108            caption: newCaption
8109          }),
8110          inlineToolbar: true
8111        }))
8112      );
8113    }
8114  
8115  }
8116  
8117  /* harmony default export */ var gallery_image = (Object(external_wp_compose_["compose"])([Object(external_wp_data_["withSelect"])((select, ownProps) => {
8118    const {
8119      getMedia
8120    } = select(external_wp_coreData_["store"]);
8121    const {
8122      id
8123    } = ownProps;
8124    return {
8125      image: id ? getMedia(parseInt(id, 10)) : null
8126    };
8127  }), Object(external_wp_data_["withDispatch"])(dispatch => {
8128    const {
8129      __unstableMarkNextChangeAsNotPersistent
8130    } = dispatch(external_wp_blockEditor_["store"]);
8131    return {
8132      __unstableMarkNextChangeAsNotPersistent
8133    };
8134  })])(gallery_image_GalleryImage));
8135  
8136  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/gallery/gallery.js
8137  
8138  
8139  
8140  /**
8141   * External dependencies
8142   */
8143  
8144  /**
8145   * WordPress dependencies
8146   */
8147  
8148  
8149  
8150  
8151  
8152  /**
8153   * Internal dependencies
8154   */
8155  
8156  
8157  
8158  const Gallery = props => {
8159    const {
8160      attributes,
8161      isSelected,
8162      setAttributes,
8163      selectedImage,
8164      mediaPlaceholder,
8165      onMoveBackward,
8166      onMoveForward,
8167      onRemoveImage,
8168      onSelectImage,
8169      onDeselectImage,
8170      onSetImageAttributes,
8171      insertBlocksAfter,
8172      blockProps
8173    } = props;
8174    const {
8175      align,
8176      columns = defaultColumnsNumber(attributes),
8177      caption,
8178      imageCrop,
8179      images
8180    } = attributes;
8181    return Object(external_wp_element_["createElement"])("figure", Object(esm_extends["a" /* default */])({}, blockProps, {
8182      className: classnames_default()(blockProps.className, {
8183        [`align$align}`]: align,
8184        [`columns-$columns}`]: columns,
8185        'is-cropped': imageCrop
8186      })
8187    }), Object(external_wp_element_["createElement"])("ul", {
8188      className: "blocks-gallery-grid"
8189    }, images.map((img, index) => {
8190      const ariaLabel = Object(external_wp_i18n_["sprintf"])(
8191      /* translators: 1: the order number of the image. 2: the total number of images. */
8192      Object(external_wp_i18n_["__"])('image %1$d of %2$d in gallery'), index + 1, images.length);
8193      return Object(external_wp_element_["createElement"])("li", {
8194        className: "blocks-gallery-item",
8195        key: img.id ? `$img.id}-$index}` : img.url
8196      }, Object(external_wp_element_["createElement"])(gallery_image, {
8197        url: img.url,
8198        alt: img.alt,
8199        id: img.id,
8200        isFirstItem: index === 0,
8201        isLastItem: index + 1 === images.length,
8202        isSelected: isSelected && selectedImage === index,
8203        onMoveBackward: onMoveBackward(index),
8204        onMoveForward: onMoveForward(index),
8205        onRemove: onRemoveImage(index),
8206        onSelect: onSelectImage(index),
8207        onDeselect: onDeselectImage(index),
8208        setAttributes: attrs => onSetImageAttributes(index, attrs),
8209        caption: img.caption,
8210        "aria-label": ariaLabel,
8211        sizeSlug: attributes.sizeSlug
8212      }));
8213    })), mediaPlaceholder, Object(external_wp_element_["createElement"])(RichTextVisibilityHelper, {
8214      isHidden: !isSelected && external_wp_blockEditor_["RichText"].isEmpty(caption),
8215      tagName: "figcaption",
8216      className: "blocks-gallery-caption",
8217      "aria-label": Object(external_wp_i18n_["__"])('Gallery caption text'),
8218      placeholder: Object(external_wp_i18n_["__"])('Write gallery caption…'),
8219      value: caption,
8220      onChange: value => setAttributes({
8221        caption: value
8222      }),
8223      inlineToolbar: true,
8224      __unstableOnSplitAtEnd: () => insertBlocksAfter(Object(external_wp_blocks_["createBlock"])('core/paragraph'))
8225    }));
8226  };
8227  
8228  function RichTextVisibilityHelper({
8229    isHidden,
8230    ...richTextProps
8231  }) {
8232    return isHidden ? Object(external_wp_element_["createElement"])(external_wp_components_["VisuallyHidden"], Object(esm_extends["a" /* default */])({
8233      as: external_wp_blockEditor_["RichText"]
8234    }, richTextProps)) : Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"], richTextProps);
8235  }
8236  
8237  /* harmony default export */ var gallery_gallery = (Gallery);
8238  
8239  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/gallery/edit.js
8240  
8241  
8242  
8243  /**
8244   * External dependencies
8245   */
8246  
8247  /**
8248   * WordPress dependencies
8249   */
8250  
8251  
8252  
8253  
8254  
8255  
8256  
8257  
8258  
8259  
8260  
8261  /**
8262   * Internal dependencies
8263   */
8264  
8265  
8266  
8267  
8268  
8269  const MAX_COLUMNS = 8;
8270  const linkOptions = [{
8271    value: constants_LINK_DESTINATION_ATTACHMENT,
8272    label: Object(external_wp_i18n_["__"])('Attachment Page')
8273  }, {
8274    value: constants_LINK_DESTINATION_MEDIA,
8275    label: Object(external_wp_i18n_["__"])('Media File')
8276  }, {
8277    value: constants_LINK_DESTINATION_NONE,
8278    label: Object(external_wp_i18n_["__"])('None')
8279  }];
8280  const edit_ALLOWED_MEDIA_TYPES = ['image'];
8281  const PLACEHOLDER_TEXT = external_wp_element_["Platform"].select({
8282    web: Object(external_wp_i18n_["__"])('Drag images, upload new ones or select files from your library.'),
8283    native: Object(external_wp_i18n_["__"])('ADD MEDIA')
8284  });
8285  const MOBILE_CONTROL_PROPS_RANGE_CONTROL = external_wp_element_["Platform"].select({
8286    web: {},
8287    native: {
8288      type: 'stepper'
8289    }
8290  });
8291  
8292  function GalleryEdit(props) {
8293    const {
8294      attributes,
8295      clientId,
8296      isSelected,
8297      noticeUI,
8298      noticeOperations,
8299      onFocus
8300    } = props;
8301    const {
8302      columns = defaultColumnsNumber(attributes),
8303      imageCrop,
8304      images,
8305      linkTo,
8306      sizeSlug
8307    } = attributes;
8308    const [selectedImage, setSelectedImage] = Object(external_wp_element_["useState"])();
8309    const [attachmentCaptions, setAttachmentCaptions] = Object(external_wp_element_["useState"])();
8310    const {
8311      __unstableMarkNextChangeAsNotPersistent
8312    } = Object(external_wp_data_["useDispatch"])(external_wp_blockEditor_["store"]);
8313    const {
8314      imageSizes,
8315      mediaUpload,
8316      getMedia,
8317      wasBlockJustInserted
8318    } = Object(external_wp_data_["useSelect"])(select => {
8319      const settings = select(external_wp_blockEditor_["store"]).getSettings();
8320      return {
8321        imageSizes: settings.imageSizes,
8322        mediaUpload: settings.mediaUpload,
8323        getMedia: select(external_wp_coreData_["store"]).getMedia,
8324        wasBlockJustInserted: select(external_wp_blockEditor_["store"]).wasBlockJustInserted(clientId, 'inserter_menu')
8325      };
8326    });
8327    const resizedImages = Object(external_wp_element_["useMemo"])(() => {
8328      if (isSelected) {
8329        return Object(external_lodash_["reduce"])(attributes.ids, (currentResizedImages, id) => {
8330          if (!id) {
8331            return currentResizedImages;
8332          }
8333  
8334          const image = getMedia(id);
8335          const sizes = Object(external_lodash_["reduce"])(imageSizes, (currentSizes, size) => {
8336            const defaultUrl = Object(external_lodash_["get"])(image, ['sizes', size.slug, 'url']);
8337            const mediaDetailsUrl = Object(external_lodash_["get"])(image, ['media_details', 'sizes', size.slug, 'source_url']);
8338            return { ...currentSizes,
8339              [size.slug]: defaultUrl || mediaDetailsUrl
8340            };
8341          }, {});
8342          return { ...currentResizedImages,
8343            [parseInt(id, 10)]: sizes
8344          };
8345        }, {});
8346      }
8347  
8348      return {};
8349    }, [isSelected, attributes.ids, imageSizes]);
8350  
8351    function onFocusGalleryCaption() {
8352      setSelectedImage();
8353    }
8354  
8355    function setAttributes(newAttrs) {
8356      if (newAttrs.ids) {
8357        throw new Error('The "ids" attribute should not be changed directly. It is managed automatically when "images" attribute changes');
8358      }
8359  
8360      if (newAttrs.images) {
8361        newAttrs = { ...newAttrs,
8362          // Unlike images[ n ].id which is a string, always ensure the
8363          // ids array contains numbers as per its attribute type.
8364          ids: Object(external_lodash_["map"])(newAttrs.images, ({
8365            id
8366          }) => parseInt(id, 10))
8367        };
8368      }
8369  
8370      props.setAttributes(newAttrs);
8371    }
8372  
8373    function onSelectImage(index) {
8374      return () => {
8375        setSelectedImage(index);
8376      };
8377    }
8378  
8379    function onDeselectImage() {
8380      return () => {
8381        setSelectedImage();
8382      };
8383    }
8384  
8385    function onMove(oldIndex, newIndex) {
8386      const newImages = [...images];
8387      newImages.splice(newIndex, 1, images[oldIndex]);
8388      newImages.splice(oldIndex, 1, images[newIndex]);
8389      setSelectedImage(newIndex);
8390      setAttributes({
8391        images: newImages
8392      });
8393    }
8394  
8395    function onMoveForward(oldIndex) {
8396      return () => {
8397        if (oldIndex === images.length - 1) {
8398          return;
8399        }
8400  
8401        onMove(oldIndex, oldIndex + 1);
8402      };
8403    }
8404  
8405    function onMoveBackward(oldIndex) {
8406      return () => {
8407        if (oldIndex === 0) {
8408          return;
8409        }
8410  
8411        onMove(oldIndex, oldIndex - 1);
8412      };
8413    }
8414  
8415    function onRemoveImage(index) {
8416      return () => {
8417        const newImages = Object(external_lodash_["filter"])(images, (img, i) => index !== i);
8418        setSelectedImage();
8419        setAttributes({
8420          images: newImages,
8421          columns: attributes.columns ? Math.min(newImages.length, attributes.columns) : attributes.columns
8422        });
8423      };
8424    }
8425  
8426    function selectCaption(newImage) {
8427      // The image id in both the images and attachmentCaptions arrays is a
8428      // string, so ensure comparison works correctly by converting the
8429      // newImage.id to a string.
8430      const newImageId = Object(external_lodash_["toString"])(newImage.id);
8431      const currentImage = Object(external_lodash_["find"])(images, {
8432        id: newImageId
8433      });
8434      const currentImageCaption = currentImage ? currentImage.caption : newImage.caption;
8435  
8436      if (!attachmentCaptions) {
8437        return currentImageCaption;
8438      }
8439  
8440      const attachment = Object(external_lodash_["find"])(attachmentCaptions, {
8441        id: newImageId
8442      }); // if the attachment caption is updated
8443  
8444      if (attachment && attachment.caption !== newImage.caption) {
8445        return newImage.caption;
8446      }
8447  
8448      return currentImageCaption;
8449    }
8450  
8451    function onSelectImages(newImages) {
8452      setAttachmentCaptions(newImages.map(newImage => ({
8453        // Store the attachmentCaption id as a string for consistency
8454        // with the type of the id in the images attribute.
8455        id: Object(external_lodash_["toString"])(newImage.id),
8456        caption: newImage.caption
8457      })));
8458      setAttributes({
8459        images: newImages.map(newImage => ({ ...shared_pickRelevantMediaFiles(newImage, sizeSlug),
8460          caption: selectCaption(newImage, images, attachmentCaptions),
8461          // The id value is stored in a data attribute, so when the
8462          // block is parsed it's converted to a string. Converting
8463          // to a string here ensures it's type is consistent.
8464          id: Object(external_lodash_["toString"])(newImage.id)
8465        })),
8466        columns: attributes.columns ? Math.min(newImages.length, attributes.columns) : attributes.columns
8467      });
8468    }
8469  
8470    function onUploadError(message) {
8471      noticeOperations.removeAllNotices();
8472      noticeOperations.createErrorNotice(message);
8473    }
8474  
8475    function setLinkTo(value) {
8476      setAttributes({
8477        linkTo: value
8478      });
8479    }
8480  
8481    function setColumnsNumber(value) {
8482      setAttributes({
8483        columns: value
8484      });
8485    }
8486  
8487    function toggleImageCrop() {
8488      setAttributes({
8489        imageCrop: !imageCrop
8490      });
8491    }
8492  
8493    function getImageCropHelp(checked) {
8494      return checked ? Object(external_wp_i18n_["__"])('Thumbnails are cropped to align.') : Object(external_wp_i18n_["__"])('Thumbnails are not cropped.');
8495    }
8496  
8497    function setImageAttributes(index, newAttributes) {
8498      if (!images[index]) {
8499        return;
8500      }
8501  
8502      setAttributes({
8503        images: [...images.slice(0, index), { ...images[index],
8504          ...newAttributes
8505        }, ...images.slice(index + 1)]
8506      });
8507    }
8508  
8509    function getImagesSizeOptions() {
8510      return Object(external_lodash_["map"])(Object(external_lodash_["filter"])(imageSizes, ({
8511        slug
8512      }) => Object(external_lodash_["some"])(resizedImages, sizes => sizes[slug])), ({
8513        name,
8514        slug
8515      }) => ({
8516        value: slug,
8517        label: name
8518      }));
8519    }
8520  
8521    function updateImagesSize(newSizeSlug) {
8522      const updatedImages = Object(external_lodash_["map"])(images, image => {
8523        if (!image.id) {
8524          return image;
8525        }
8526  
8527        const url = Object(external_lodash_["get"])(resizedImages, [parseInt(image.id, 10), newSizeSlug]);
8528        return { ...image,
8529          ...(url && {
8530            url
8531          })
8532        };
8533      });
8534      setAttributes({
8535        images: updatedImages,
8536        sizeSlug: newSizeSlug
8537      });
8538    }
8539  
8540    Object(external_wp_element_["useEffect"])(() => {
8541      if (external_wp_element_["Platform"].OS === 'web' && images && images.length > 0 && Object(external_lodash_["every"])(images, ({
8542        url
8543      }) => Object(external_wp_blob_["isBlobURL"])(url))) {
8544        const filesList = Object(external_lodash_["map"])(images, ({
8545          url
8546        }) => Object(external_wp_blob_["getBlobByURL"])(url));
8547        Object(external_lodash_["forEach"])(images, ({
8548          url
8549        }) => Object(external_wp_blob_["revokeBlobURL"])(url));
8550        mediaUpload({
8551          filesList,
8552          onFileChange: onSelectImages,
8553          allowedTypes: ['image']
8554        });
8555      }
8556    }, []);
8557    Object(external_wp_element_["useEffect"])(() => {
8558      // Deselect images when deselecting the block
8559      if (!isSelected) {
8560        setSelectedImage();
8561      }
8562    }, [isSelected]);
8563    Object(external_wp_element_["useEffect"])(() => {
8564      // linkTo attribute must be saved so blocks don't break when changing
8565      // image_default_link_type in options.php
8566      if (!linkTo) {
8567        var _window, _window$wp, _window$wp$media, _window$wp$media$view, _window$wp$media$view2, _window$wp$media$view3;
8568  
8569        __unstableMarkNextChangeAsNotPersistent();
8570  
8571        setAttributes({
8572          linkTo: ((_window = window) === null || _window === void 0 ? void 0 : (_window$wp = _window.wp) === null || _window$wp === void 0 ? void 0 : (_window$wp$media = _window$wp.media) === null || _window$wp$media === void 0 ? void 0 : (_window$wp$media$view = _window$wp$media.view) === null || _window$wp$media$view === void 0 ? void 0 : (_window$wp$media$view2 = _window$wp$media$view.settings) === null || _window$wp$media$view2 === void 0 ? void 0 : (_window$wp$media$view3 = _window$wp$media$view2.defaultProps) === null || _window$wp$media$view3 === void 0 ? void 0 : _window$wp$media$view3.link) || constants_LINK_DESTINATION_NONE
8573        });
8574      }
8575    }, [linkTo]);
8576    const hasImages = !!images.length;
8577    const hasImageIds = hasImages && images.some(image => !!image.id);
8578    const mediaPlaceholder = Object(external_wp_element_["createElement"])(external_wp_blockEditor_["MediaPlaceholder"], {
8579      addToGallery: hasImageIds,
8580      isAppender: hasImages,
8581      disableMediaButtons: hasImages && !isSelected,
8582      icon: !hasImages && sharedIcon,
8583      labels: {
8584        title: !hasImages && Object(external_wp_i18n_["__"])('Gallery'),
8585        instructions: !hasImages && PLACEHOLDER_TEXT
8586      },
8587      onSelect: onSelectImages,
8588      accept: "image/*",
8589      allowedTypes: edit_ALLOWED_MEDIA_TYPES,
8590      multiple: true,
8591      value: hasImageIds ? images : {},
8592      onError: onUploadError,
8593      notices: hasImages ? undefined : noticeUI,
8594      onFocus: onFocus,
8595      autoOpenMediaUpload: !hasImages && isSelected && wasBlockJustInserted
8596    });
8597    const blockProps = Object(external_wp_blockEditor_["useBlockProps"])();
8598  
8599    if (!hasImages) {
8600      return Object(external_wp_element_["createElement"])(external_wp_primitives_["View"], blockProps, mediaPlaceholder);
8601    }
8602  
8603    const imageSizeOptions = getImagesSizeOptions();
8604    const shouldShowSizeOptions = hasImages && !Object(external_lodash_["isEmpty"])(imageSizeOptions);
8605    return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_blockEditor_["InspectorControls"], null, Object(external_wp_element_["createElement"])(external_wp_components_["PanelBody"], {
8606      title: Object(external_wp_i18n_["__"])('Gallery settings')
8607    }, images.length > 1 && Object(external_wp_element_["createElement"])(external_wp_components_["RangeControl"], Object(esm_extends["a" /* default */])({
8608      label: Object(external_wp_i18n_["__"])('Columns'),
8609      value: columns,
8610      onChange: setColumnsNumber,
8611      min: 1,
8612      max: Math.min(MAX_COLUMNS, images.length)
8613    }, MOBILE_CONTROL_PROPS_RANGE_CONTROL, {
8614      required: true
8615    })), Object(external_wp_element_["createElement"])(external_wp_components_["ToggleControl"], {
8616      label: Object(external_wp_i18n_["__"])('Crop images'),
8617      checked: !!imageCrop,
8618      onChange: toggleImageCrop,
8619      help: getImageCropHelp
8620    }), Object(external_wp_element_["createElement"])(external_wp_components_["SelectControl"], {
8621      label: Object(external_wp_i18n_["__"])('Link to'),
8622      value: linkTo,
8623      onChange: setLinkTo,
8624      options: linkOptions,
8625      hideCancelButton: true
8626    }), shouldShowSizeOptions && Object(external_wp_element_["createElement"])(external_wp_components_["SelectControl"], {
8627      label: Object(external_wp_i18n_["__"])('Image size'),
8628      value: sizeSlug,
8629      options: imageSizeOptions,
8630      onChange: updateImagesSize,
8631      hideCancelButton: true
8632    }))), noticeUI, Object(external_wp_element_["createElement"])(gallery_gallery, Object(esm_extends["a" /* default */])({}, props, {
8633      selectedImage: selectedImage,
8634      mediaPlaceholder: mediaPlaceholder,
8635      onMoveBackward: onMoveBackward,
8636      onMoveForward: onMoveForward,
8637      onRemoveImage: onRemoveImage,
8638      onSelectImage: onSelectImage,
8639      onDeselectImage: onDeselectImage,
8640      onSetImageAttributes: setImageAttributes,
8641      blockProps: blockProps // This prop is used by gallery.native.js.
8642      ,
8643      onFocusGalleryCaption: onFocusGalleryCaption
8644    })));
8645  }
8646  
8647  /* harmony default export */ var gallery_edit = (Object(external_wp_compose_["compose"])([external_wp_components_["withNotices"], Object(external_wp_viewport_["withViewportMatch"])({
8648    isNarrow: '< small'
8649  })])(GalleryEdit));
8650  
8651  // CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/gallery/save.js
8652  
8653  
8654  /**
8655   * WordPress dependencies
8656   */
8657  
8658  /**
8659   * Internal dependencies
8660   */
8661  
8662  
8663  
8664  function gallery_save_save({
8665    attributes
8666  }) {
8667    const {
8668      images,
8669      columns = defaultColumnsNumber(attributes),
8670      imageCrop,
8671      caption,
8672      linkTo
8673    } = attributes;
8674    const className = `columns-$columns} $imageCrop ? 'is-cropped' : ''}`;
8675    return Object(external_wp_element_["createElement"])("figure", external_wp_blockEditor_["useBlockProps"].save({
8676      className
8677    }), Object(external_wp_element_["createElement"])("ul", {
8678      className: "blocks-gallery-grid"
8679    }, images.map(image => {
8680      let href;
8681  
8682      switch (linkTo) {
8683        case constants_LINK_DESTINATION_MEDIA:
8684          href = image.fullUrl || image.url;
8685          break;
8686  
8687        case constants_LINK_DESTINATION_ATTACHMENT:
8688          href = image.link;
8689          break;
8690      }
8691  
8692      const img = Object(external_wp_element_["createElement"])("img", {
8693        src: image.url,
8694        alt: image.alt,
8695        "data-id": image.id,
8696        "data-full-url": image.fullUrl,
8697        "data-link": image.link,
8698        className: image.id ? `wp-image-$image.id}` : null
8699      });
8700      return Object(external_wp_element_["createElement"])("li", {
8701        key: image.id || image.url,
8702        className: "blocks-gallery-item"
8703      }, Object(external_wp_element_["createElement"])("figure", null, href ? Object(external_wp_element_["createElement"])("a", {
8704        href: href
8705      }, img) : img, !external_wp_blockEditor_["RichText"].isEmpty(image.caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
8706        tagName: "figcaption",
8707        className: "blocks-gallery-item__caption",
8708        value: image.caption
8709      })));
8710    })), !external_wp_blockEditor_["RichText"].isEmpty(caption) && Object(external_wp_element_["createElement"])(external_wp_blockEditor_["RichText"].Content, {
8711      tagName: "figcaption",
8712      className: "blocks-gallery-caption",
8713      value: caption
8714</