mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-19 17:15:16 +01:00
1d738052b1
The following package versions were changed: @wordpress/block-directory: 1.17.2 -> 1.17.3 @wordpress/block-editor: 5.1.2 -> 5.1.3 @wordpress/block-library: 2.26.2 -> 2.26.3 @wordpress/edit-post: 3.25.2 -> 3.25.3 @wordpress/editor: 9.24.2 -> 9.24.3 @wordpress/format-library: 1.25.2 -> 1.25.3 @wordpress/reusable-blocks: 1.0.2 -> 1.0.3 See https://github.com/WordPress/gutenberg/pull/26874 for the list of fixed bugs. Props isabel_brison. Fixes #51696. Built from https://develop.svn.wordpress.org/trunk@49579 git-svn-id: http://core.svn.wordpress.org/trunk@49317 1a063a9b-81f0-0310-95a4-ce76da25c4cd
12 lines
479 KiB
JavaScript
12 lines
479 KiB
JavaScript
/*! This file is auto-generated */
|
||
this.wp=this.wp||{},this.wp.blockEditor=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=455)}([function(e,t){!function(){e.exports=this.wp.element}()},function(e,t){!function(){e.exports=this.wp.i18n}()},function(e,t){!function(){e.exports=this.lodash}()},function(e,t){!function(){e.exports=this.wp.components}()},function(e,t){!function(){e.exports=this.wp.data}()},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.d(t,"a",(function(){return r}))},,function(e,t){!function(){e.exports=this.wp.primitives}()},function(e,t,n){"use strict";function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,"a",(function(){return r}))},function(e,t,n){var r;
|
||
/*!
|
||
Copyright (c) 2017 Jed Watson.
|
||
Licensed under the MIT License (MIT), see
|
||
http://jedwatson.github.io/classnames
|
||
*/!function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var r=arguments[t];if(r){var c=typeof r;if("string"===c||"number"===c)e.push(r);else if(Array.isArray(r)&&r.length){var i=o.apply(null,r);i&&e.push(i)}else if("object"===c)for(var a in r)n.call(r,a)&&r[a]&&e.push(a)}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(r=function(){return o}.apply(t,[]))||(e.exports=r)}()},function(e,t){!function(){e.exports=this.wp.compose}()},function(e,t){!function(){e.exports=this.wp.blocks}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(38);var o=n(30),c=n(39);function i(e,t){return Object(r.a)(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,c=void 0;try{for(var i,a=e[Symbol.iterator]();!(r=(i=a.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,c=e}finally{try{r||null==a.return||a.return()}finally{if(o)throw c}}return n}}(e,t)||Object(o.a)(e,t)||Object(c.a)()}},function(e,t){!function(){e.exports=this.React}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(43);function o(e,t){if(null==e)return{};var n,o,c=Object(r.a)(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)n=i[o],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(c[n]=e[n])}return c}},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function l(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return c})),n.d(t,"c",(function(){return l}))},function(e,t,n){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(27);var o=n(37),c=n(30);function i(e){return function(e){if(Array.isArray(e))return Object(r.a)(e)}(e)||Object(o.a)(e)||Object(c.a)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},function(e,t){!function(){e.exports=this.wp.keycodes}()},function(e,t,n){"use strict";function r(e){return(r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n.d(t,"a",(function(){return r}))},function(e,t){!function(){e.exports=this.regeneratorRuntime}()},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function o(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}n.d(t,"a",(function(){return o}))},function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}n.d(t,"a",(function(){return o}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(40),o=n(16);function c(e,t){return!t||"object"!==Object(r.a)(t)&&"function"!=typeof t?Object(o.a)(e):t}},function(e,t){!function(){e.exports=this.wp.richText}()},,function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}n.d(t,"a",(function(){return r}))},function(e,t,n){e.exports=n(142)()},function(e,t){!function(){e.exports=this.wp.dom}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(27);function o(e,t){if(e){if("string"==typeof e)return Object(r.a)(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Object(r.a)(e,t):void 0}}},function(e,t){!function(){e.exports=this.wp.url}()},,function(e,t){!function(){e.exports=this.wp.hooks}()},,,function(e,t){!function(){e.exports=this.wp.deprecated}()},function(e,t,n){"use strict";function r(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(e){if(Array.isArray(e))return e}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}n.d(t,"a",(function(){return r}))},function(e,t){!function(){e.exports=this.wp.blob}()},function(e,t,n){"use strict";var r,o;function c(e){return[e]}function i(){var e={clear:function(){e.head=null}};return e}function a(e,t,n){var r;if(e.length!==t.length)return!1;for(r=n;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}r={},o="undefined"!=typeof WeakMap,t.a=function(e,t){var n,l;function s(){n=o?new WeakMap:i()}function u(){var n,r,o,c,i,s=arguments.length;for(c=new Array(s),o=0;o<s;o++)c[o]=arguments[o];for(i=t.apply(null,c),(n=l(i)).isUniqueByDependants||(n.lastDependants&&!a(i,n.lastDependants,0)&&n.clear(),n.lastDependants=i),r=n.head;r;){if(a(r.args,c,1))return r!==n.head&&(r.prev.next=r.next,r.next&&(r.next.prev=r.prev),r.next=n.head,r.prev=null,n.head.prev=r,n.head=r),r.val;r=r.next}return r={val:e.apply(null,c)},c[0]=null,r.args=c,n.head&&(n.head.prev=r,r.next=n.head),n.head=r,r.val}return t||(t=c),l=o?function(e){var t,o,c,a,l,s=n,u=!0;for(t=0;t<e.length;t++){if(o=e[t],!(l=o)||"object"!=typeof l){u=!1;break}s.has(o)?s=s.get(o):(c=new WeakMap,s.set(o,c),s=c)}return s.has(r)||((a=i()).isUniqueByDependants=u,s.set(r,a)),s.get(r)}:function(){return n},u.getDependants=t,u.clear=s,s(),u}},function(e,t,n){"use strict";function r(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}n.d(t,"a",(function(){return r}))},,function(e,t,n){"use strict";function r(e,t,n,r,o,c,i){try{var a=e[c](i),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(o,c){var i=e.apply(t,n);function a(e){r(i,o,c,a,l,"next",e)}function l(e){r(i,o,c,a,l,"throw",e)}a(void 0)}))}}n.d(t,"a",(function(){return o}))},function(e,t){!function(){e.exports=this.wp.a11y}()},,function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(13),o=n(59);function c(e){var t=Object(r.useRef)(e);return Object(o.a)((function(){t.current=e})),t}},function(e,t,n){"use strict";function r(e){return e?e.ownerDocument||e:window.document}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return l}));var r=n(13),o=n(76);function c(e,t){Object(r.useDebugValue)(e);var n=Object(r.useContext)(o.a);return null!=n[e]?n[e]:t}var i=n(55);var a=n(56);function l(e){var t,n,o,l=(o=e.compose,Array.isArray(o)?o:void 0!==o?[o]:[]),s=function(t,n){if(e.useOptions&&(t=e.useOptions(t,n)),e.name&&(t=function(e,t,n){void 0===t&&(t={}),void 0===n&&(n={});var o="use"+e+"Options";Object(r.useDebugValue)(o);var a=c(o);return a?Object(i.a)(Object(i.a)({},t),a(t,n)):t}(e.name,t,n)),e.compose)for(var o,a=Object(i.c)(l);!(o=a()).done;){t=o.value.__useOptions(t,n)}return t},u=function(t,n,o){if(void 0===t&&(t={}),void 0===n&&(n={}),void 0===o&&(o=!1),o||(t=s(t,n)),e.useProps&&(n=e.useProps(t,n)),e.name&&(n=function(e,t,n){void 0===t&&(t={}),void 0===n&&(n={});var o="use"+e+"Props";Object(r.useDebugValue)(o);var i=c(o);return i?i(t,n):n}(e.name,t,n)),e.compose)if(e.useComposeOptions&&(t=e.useComposeOptions(t,n)),e.useComposeProps)n=e.useComposeProps(t,n);else for(var a,u=Object(i.c)(l);!(a=u()).done;){n=(0,a.value)(t,n,!0)}var d={},b=n||{};for(var f in b)void 0!==b[f]&&(d[f]=b[f]);return d};u.__useOptions=s;var d=l.reduce((function(e,t){return e.push.apply(e,t.__keys||[]),e}),[]);return u.__keys=[].concat(d,(null===(t=e.useState)||void 0===t?void 0:t.__keys)||[],e.keys||[]),u.unstable_propsAreEqual=e.propsAreEqual||(null===(n=l[0])||void 0===n?void 0:n.unstable_propsAreEqual)||a.a,u}},function(e,t,n){"use strict";n.d(t,"a",(function(){return l}));var r=n(13),o=n(55),c=n(79);function i(e,t){for(var n={},r={},o=0,c=Object.keys(e);o<c.length;o++){var i=c[o];t.indexOf(i)>=0?n[i]=e[i]:r[i]=e[i]}return[n,r]}var a=n(56);function l(e){var t,n=e.as,l=e.useHook,s=e.memo,u=e.propsAreEqual,d=void 0===u?null==l?void 0:l.unstable_propsAreEqual:u,b=e.keys,f=void 0===b?(null==l?void 0:l.__keys)||[]:b,p=e.useCreateElement,m=void 0===p?c.a:p,v=function(e,t){var r=e.as,c=void 0===r?n:r,a=Object(o.b)(e,["as"]);if(l){var s,u=i(a,f),d=u[0],b=u[1],p=l(d,Object(o.a)({ref:t},b)),v=p.wrapElement,O=Object(o.b)(p,["wrapElement"]),g=(null===(s=c.render)||void 0===s?void 0:s.__keys)||c.__keys,h=g&&i(a,g)[0],j=h?Object(o.a)(Object(o.a)({},O),h):O,k=m(c,j);return v?v(k):k}return m(c,Object(o.a)({ref:t},a))};return t=v,v=Object(r.forwardRef)(t),s&&(v=function(e,t){return Object(r.memo)(e,t)}(v,d)),v.__keys=f,v.unstable_propsAreEqual=d||a.a,v}},function(e,t,n){"use strict";n.d(t,"a",(function(){return b})),n.d(t,"b",(function(){return O})),n.d(t,"c",(function(){return p})),n.d(t,"d",(function(){return f})),n.d(t,"e",(function(){return h})),n.d(t,"f",(function(){return s})),n.d(t,"g",(function(){return w}));var r=n(15),o=n(13),c=n(59),i=n(62),a=n(61),l=n(65);function s(e){return e.slice().reverse()}function u(e,t){return Boolean(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_PRECEDING)}function d(e,t){return e.findIndex((function(e){return!(!e.ref.current||!t.ref.current)&&u(t.ref.current,e.ref.current)}))}function b(e,t){return t?e.find((function(e){return!e.disabled&&e.id!==t})):e.find((function(e){return!e.disabled}))}function f(e,t){if(t)return null==e?void 0:e.find((function(e){return e.id===t&&!e.disabled}))}function p(e){for(var t,n=[[]],o=function(){var e=t.value,r=n.find((function(t){return!t[0]||t[0].groupId===e.groupId}));r?r.push(e):n.push([e])},c=Object(r.c)(e);!(t=c()).done;)o();return n}function m(e){for(var t,n=0,o=Object(r.c)(e);!(t=o()).done;){var c=t.value.length;c>n&&(n=c)}return n}function v(e){for(var t=p(e),n=m(t),o=[],c=0;c<n;c+=1)for(var i,a=Object(r.c)(t);!(i=a()).done;){var l=i.value;l[c]&&o.push(Object(r.b)(Object(r.b)({},l[c]),{},{groupId:l[c].groupId?""+c:void 0}))}return o}function O(e){for(var t,n=[],o=Object(r.c)(e);!(t=o()).done;){var c=t.value;n.push.apply(n,c)}return n}function g(e){for(var t,n=m(e),o=Object(r.c)(e);!(t=o()).done;){var c=t.value;if(c.length<n)for(var i=0;i<n;i+=1)c[i]||(c[i]={id:"__EMPTY_ITEM__",disabled:!0,ref:{current:null},groupId:c[i-1].groupId})}return e}function h(e,t){var n;return t||null===t?t:e.currentId||null===e.currentId?e.currentId:null===(n=b(e.items||[]))||void 0===n?void 0:n.id}var j={id:null,ref:{current:null}};function k(e,t){return e.filter((function(e){return e.groupId===t}))}var y={horizontal:"vertical",vertical:"horizontal"};function _(e,t,n){return n in e?[].concat(e.slice(0,n),[t],e.slice(n)):[].concat(e,[t])}function E(e){var t=e.slice(),n=!1;return t.sort((function(e,t){var r=e.ref.current,o=t.ref.current;return r&&o&&u(r,o)?(n=!0,-1):0})),n?t:e}function C(e,t){var n=e.unstable_virtual,o=e.rtl,c=e.orientation,i=e.items,l=e.groups,u=e.currentId,m=e.loop,S=e.wrap,w=e.pastIds,I=e.unstable_moves,B=e.initialVirtual,x=e.initialRTL,P=e.initialOrientation,T=e.initialCurrentId,N=e.initialLoop,D=e.initialWrap,R=e.hasSetCurrentId;switch(t.type){case"registerGroup":var A=t.group;if(0===l.length)return Object(r.b)(Object(r.b)({},e),{},{groups:[A]});var M=d(l,A);return Object(r.b)(Object(r.b)({},e),{},{groups:_(l,A,M)});case"unregisterGroup":var L=t.id,F=l.filter((function(e){return e.id!==L}));return F.length===l.length?e:Object(r.b)(Object(r.b)({},e),{},{groups:F});case"registerItem":var V,H=t.item,z=l.find((function(e){var t;return null===(t=e.ref.current)||void 0===t?void 0:t.contains(H.ref.current)})),U=Object(r.b)({groupId:null==z?void 0:z.id},H),G=d(i,U),K=Object(r.b)(Object(r.b)({},e),{},{items:_(i,U,G)});return R||I||void 0!==T?K:Object(r.b)(Object(r.b)({},K),{},{currentId:null===(V=b(K.items))||void 0===V?void 0:V.id});case"unregisterItem":var W=t.id,q=i.filter((function(e){return e.id!==W}));if(q.length===i.length)return e;var $=w.filter((function(e){return e!==W})),Y=Object(r.b)(Object(r.b)({},e),{},{pastIds:$,items:q});if(u&&u===W){var X=h(Object(r.b)(Object(r.b)({},Y),{},{currentId:$[0]}));return Object(r.b)(Object(r.b)({},Y),{},{currentId:X})}return Y;case"move":var Q=t.id;if(void 0===Q)return e;var Z=w.filter((function(e){return e!==u&&e!==Q})),J=u?[u].concat(Z):Z,ee=Object(r.b)(Object(r.b)({},e),{},{pastIds:J});if(null===Q)return Object(r.b)(Object(r.b)({},ee),{},{unstable_moves:I+1,currentId:h(ee,Q)});var te=f(i,Q);return Object(r.b)(Object(r.b)({},ee),{},{unstable_moves:te?I+1:I,currentId:h(ee,null==te?void 0:te.id)});case"next":if(null==u)return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"first"}));var ne=o&&"vertical"!==c,re=ne?s(i):i,oe=re.find((function(e){return e.id===u}));if(!oe)return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"first"}));var ce=!!oe.groupId,ie=re.indexOf(oe),ae=re.slice(ie+1),le=k(ae,oe.groupId);if(t.allTheWay){var se=b(ne?k(re,oe.groupId):s(le));return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==se?void 0:se.id}))}var ue=function(e){return e&&y[e]}(ce?c||"horizontal":c),de=m&&m!==ue,be=ce&&S&&S!==ue,fe=t.hasNullItem||!ce&&de&&null===T;if(de){var pe=b(function(e,t,n){var r=e.findIndex((function(e){return e.id===t}));return[].concat(e.slice(r+1),n?[j]:[],e.slice(0,r))}(be&&!fe?re:k(re,oe.groupId),u,fe),u);return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==pe?void 0:pe.id}))}if(be){var me=b(fe?le:ae,u),ve=fe?(null==me?void 0:me.id)||null:null==me?void 0:me.id;return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"move",id:ve}))}var Oe=b(le,u);return C(e,!Oe&&fe?Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null}):Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==Oe?void 0:Oe.id}));case"previous":var ge=!!!l.length&&null===T,he=C(Object(r.b)(Object(r.b)({},e),{},{items:s(i)}),Object(r.b)(Object(r.b)({},t),{},{type:"next",hasNullItem:ge}));return Object(r.b)(Object(r.b)({},he),{},{items:i});case"down":var je=v(O(g(p(i)))),ke=m&&"horizontal"!==m&&null===T,ye=C(Object(r.b)(Object(r.b)({},e),{},{orientation:"vertical",items:je}),Object(r.b)(Object(r.b)({},t),{},{type:"next",hasNullItem:ke}));return Object(r.b)(Object(r.b)({},ye),{},{orientation:c,items:i});case"up":var _e=v(s(O(g(p(i))))),Ee=null===T,Ce=C(Object(r.b)(Object(r.b)({},e),{},{orientation:"vertical",items:_e}),Object(r.b)(Object(r.b)({},t),{},{type:"next",hasNullItem:Ee}));return Object(r.b)(Object(r.b)({},Ce),{},{orientation:c,items:i});case"first":var Se=b(i);return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==Se?void 0:Se.id}));case"last":var we=C(Object(r.b)(Object(r.b)({},e),{},{items:s(i)}),Object(r.b)(Object(r.b)({},t),{},{type:"first"}));return Object(r.b)(Object(r.b)({},we),{},{items:i});case"sort":return Object(r.b)(Object(r.b)({},e),{},{items:E(i),groups:E(l)});case"setVirtual":return Object(r.b)(Object(r.b)({},e),{},{unstable_virtual:Object(a.a)(t.virtual,n)});case"setRTL":return Object(r.b)(Object(r.b)({},e),{},{rtl:Object(a.a)(t.rtl,o)});case"setOrientation":return Object(r.b)(Object(r.b)({},e),{},{orientation:Object(a.a)(t.orientation,c)});case"setCurrentId":var Ie=h(Object(r.b)(Object(r.b)({},e),{},{currentId:Object(a.a)(t.currentId,u)}));return Object(r.b)(Object(r.b)({},e),{},{currentId:Ie,hasSetCurrentId:!0});case"setLoop":return Object(r.b)(Object(r.b)({},e),{},{loop:Object(a.a)(t.loop,m)});case"setWrap":return Object(r.b)(Object(r.b)({},e),{},{wrap:Object(a.a)(t.wrap,S)});case"reset":return Object(r.b)(Object(r.b)({},e),{},{unstable_virtual:B,rtl:x,orientation:P,currentId:h(Object(r.b)(Object(r.b)({},e),{},{currentId:T})),loop:N,wrap:D,unstable_moves:0,pastIds:[]});default:throw new Error}}function S(e){return Object(o.useCallback)(e,[])}function w(e){void 0===e&&(e={});var t=Object(i.a)(e),n=t.unstable_virtual,a=void 0!==n&&n,s=t.rtl,u=void 0!==s&&s,d=t.orientation,b=t.currentId,f=t.loop,p=void 0!==f&&f,m=t.wrap,v=void 0!==m&&m,O=Object(r.a)(t,["unstable_virtual","rtl","orientation","currentId","loop","wrap"]),g=Object(o.useReducer)(C,{unstable_virtual:a,rtl:u,orientation:d,items:[],groups:[],currentId:b,loop:p,wrap:v,unstable_moves:0,pastIds:[],initialVirtual:a,initialRTL:u,initialOrientation:d,initialCurrentId:b,initialLoop:p,initialWrap:v}),h=g[0],j=(h.pastIds,h.initialVirtual,h.initialRTL,h.initialOrientation,h.initialCurrentId,h.initialLoop,h.initialWrap,h.hasSetCurrentId,Object(r.a)(h,["pastIds","initialVirtual","initialRTL","initialOrientation","initialCurrentId","initialLoop","initialWrap","hasSetCurrentId"])),k=g[1],y=Object(o.useState)(!1),_=y[0],E=y[1],w=Object(l.a)(O),I=function(){var e=Object(o.useRef)(!1);return Object(c.a)((function(){return function(){e.current=!0}}),[]),e}();return Object(r.b)(Object(r.b)(Object(r.b)({},w),j),{},{unstable_hasActiveWidget:_,unstable_setHasActiveWidget:E,registerItem:S((function(e){I.current||k({type:"registerItem",item:e})})),unregisterItem:S((function(e){I.current||k({type:"unregisterItem",id:e})})),registerGroup:S((function(e){I.current||k({type:"registerGroup",group:e})})),unregisterGroup:S((function(e){I.current||k({type:"unregisterGroup",id:e})})),move:S((function(e){return k({type:"move",id:e})})),next:S((function(e){return k({type:"next",allTheWay:e})})),previous:S((function(e){return k({type:"previous",allTheWay:e})})),up:S((function(e){return k({type:"up",allTheWay:e})})),down:S((function(e){return k({type:"down",allTheWay:e})})),first:S((function(){return k({type:"first"})})),last:S((function(){return k({type:"last"})})),unstable_sort:S((function(){return k({type:"sort"})})),unstable_setVirtual:S((function(e){return k({type:"setVirtual",virtual:e})})),setRTL:S((function(e){return k({type:"setRTL",rtl:e})})),setOrientation:S((function(e){return k({type:"setOrientation",orientation:e})})),setCurrentId:S((function(e){return k({type:"setCurrentId",currentId:e})})),setLoop:S((function(e){return k({type:"setLoop",loop:e})})),setWrap:S((function(e){return k({type:"setWrap",wrap:e})})),reset:S((function(){return k({type:"reset"})}))})}var I=[].concat(l.a.__keys,["unstable_virtual","rtl","orientation","items","groups","currentId","loop","wrap","unstable_moves","unstable_hasActiveWidget","registerItem","unregisterItem","registerGroup","unregisterGroup","move","next","previous","up","down","first","last","unstable_sort","unstable_setVirtual","setRTL","setOrientation","setCurrentId","setLoop","setWrap","reset","unstable_setHasActiveWidget"]);w.__keys=I},function(e,t){!function(){e.exports=this.wp.keyboardShortcuts}()},function(e,t,n){"use strict";function r(e){return e.target===e.currentTarget}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function l(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return l}))},function(e,t,n){"use strict";function r(e,t){if(e===t)return!0;if(!e)return!1;if(!t)return!1;if("object"!=typeof e)return!1;if("object"!=typeof t)return!1;var n=Object.keys(e),r=Object.keys(t),o=n.length;if(r.length!==o)return!1;for(var c=0,i=n;c<i.length;c++){var a=i[c];if(e[a]!==t[a])return!1}return!0}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(49);function o(e){return Object(r.a)(e).activeElement}},,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(13),o="undefined"==typeof window?r.useEffect:r.useLayoutEffect},function(e,t,n){e.exports=function(e,t){var n,r,o=0;function c(){var c,i,a=n,l=arguments.length;e:for(;a;){if(a.args.length===arguments.length){for(i=0;i<l;i++)if(a.args[i]!==arguments[i]){a=a.next;continue e}return a!==n&&(a===r&&(r=a.prev),a.prev.next=a.next,a.next&&(a.next.prev=a.prev),a.next=n,a.prev=null,n.prev=a,n=a),a.val}a=a.next}for(c=new Array(l),i=0;i<l;i++)c[i]=arguments[i];return a={args:c,val:e.apply(null,c)},n?(n.prev=a,a.next=n):r=a,o===t.maxSize?(r=r.prev).next=null:o++,n=a,a.val}return t=t||{},c.clear=function(){n=null,r=null,o=0},c}},function(e,t,n){"use strict";function r(e,t){return function(e){return"function"==typeof e}(e)?e(t):e}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(13);function o(e){return Object(r.useState)(e)[0]}},function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(13);function o(e,t){void 0===t&&(t=null),e&&("function"==typeof e?e(t):e.current=t)}function c(e,t){return Object(r.useMemo)((function(){return null==e&&null==t?null:function(n){o(e,n),o(t,n)}}),[e,t])}},function(e,t){!function(){e.exports=this.wp.isShallowEqual}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(13),o=n(62),c=n(68);function i(e){void 0===e&&(e={});var t=Object(o.a)(e).baseId,n=Object(r.useContext)(c.a),i=Object(r.useRef)(0),a=Object(r.useState)((function(){return t||n()}));return{baseId:a[0],unstable_setBaseId:a[1],unstable_idCountRef:i}}i.__keys=["baseId","unstable_setBaseId","unstable_idCountRef"]},function(e,t,n){var r;!function(o){var c=/^\s+/,i=/\s+$/,a=0,l=o.round,s=o.min,u=o.max,d=o.random;function b(e,t){if(t=t||{},(e=e||"")instanceof b)return e;if(!(this instanceof b))return new b(e,t);var n=function(e){var t={r:0,g:0,b:0},n=1,r=null,a=null,l=null,d=!1,b=!1;"string"==typeof e&&(e=function(e){e=e.replace(c,"").replace(i,"").toLowerCase();var t,n=!1;if(x[e])e=x[e],n=!0;else if("transparent"==e)return{r:0,g:0,b:0,a:0,format:"name"};if(t=U.rgb.exec(e))return{r:t[1],g:t[2],b:t[3]};if(t=U.rgba.exec(e))return{r:t[1],g:t[2],b:t[3],a:t[4]};if(t=U.hsl.exec(e))return{h:t[1],s:t[2],l:t[3]};if(t=U.hsla.exec(e))return{h:t[1],s:t[2],l:t[3],a:t[4]};if(t=U.hsv.exec(e))return{h:t[1],s:t[2],v:t[3]};if(t=U.hsva.exec(e))return{h:t[1],s:t[2],v:t[3],a:t[4]};if(t=U.hex8.exec(e))return{r:R(t[1]),g:R(t[2]),b:R(t[3]),a:F(t[4]),format:n?"name":"hex8"};if(t=U.hex6.exec(e))return{r:R(t[1]),g:R(t[2]),b:R(t[3]),format:n?"name":"hex"};if(t=U.hex4.exec(e))return{r:R(t[1]+""+t[1]),g:R(t[2]+""+t[2]),b:R(t[3]+""+t[3]),a:F(t[4]+""+t[4]),format:n?"name":"hex8"};if(t=U.hex3.exec(e))return{r:R(t[1]+""+t[1]),g:R(t[2]+""+t[2]),b:R(t[3]+""+t[3]),format:n?"name":"hex"};return!1}(e));"object"==typeof e&&(G(e.r)&&G(e.g)&&G(e.b)?(f=e.r,p=e.g,m=e.b,t={r:255*N(f,255),g:255*N(p,255),b:255*N(m,255)},d=!0,b="%"===String(e.r).substr(-1)?"prgb":"rgb"):G(e.h)&&G(e.s)&&G(e.v)?(r=M(e.s),a=M(e.v),t=function(e,t,n){e=6*N(e,360),t=N(t,100),n=N(n,100);var r=o.floor(e),c=e-r,i=n*(1-t),a=n*(1-c*t),l=n*(1-(1-c)*t),s=r%6;return{r:255*[n,a,i,i,l,n][s],g:255*[l,n,n,a,i,i][s],b:255*[i,i,l,n,n,a][s]}}(e.h,r,a),d=!0,b="hsv"):G(e.h)&&G(e.s)&&G(e.l)&&(r=M(e.s),l=M(e.l),t=function(e,t,n){var r,o,c;function i(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}if(e=N(e,360),t=N(t,100),n=N(n,100),0===t)r=o=c=n;else{var a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;r=i(l,a,e+1/3),o=i(l,a,e),c=i(l,a,e-1/3)}return{r:255*r,g:255*o,b:255*c}}(e.h,r,l),d=!0,b="hsl"),e.hasOwnProperty("a")&&(n=e.a));var f,p,m;return n=T(n),{ok:d,format:e.format||b,r:s(255,u(t.r,0)),g:s(255,u(t.g,0)),b:s(255,u(t.b,0)),a:n}}(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=l(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.gradientType,this._r<1&&(this._r=l(this._r)),this._g<1&&(this._g=l(this._g)),this._b<1&&(this._b=l(this._b)),this._ok=n.ok,this._tc_id=a++}function f(e,t,n){e=N(e,255),t=N(t,255),n=N(n,255);var r,o,c=u(e,t,n),i=s(e,t,n),a=(c+i)/2;if(c==i)r=o=0;else{var l=c-i;switch(o=a>.5?l/(2-c-i):l/(c+i),c){case e:r=(t-n)/l+(t<n?6:0);break;case t:r=(n-e)/l+2;break;case n:r=(e-t)/l+4}r/=6}return{h:r,s:o,l:a}}function p(e,t,n){e=N(e,255),t=N(t,255),n=N(n,255);var r,o,c=u(e,t,n),i=s(e,t,n),a=c,l=c-i;if(o=0===c?0:l/c,c==i)r=0;else{switch(c){case e:r=(t-n)/l+(t<n?6:0);break;case t:r=(n-e)/l+2;break;case n:r=(e-t)/l+4}r/=6}return{h:r,s:o,v:a}}function m(e,t,n,r){var o=[A(l(e).toString(16)),A(l(t).toString(16)),A(l(n).toString(16))];return r&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)?o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0):o.join("")}function v(e,t,n,r){return[A(L(r)),A(l(e).toString(16)),A(l(t).toString(16)),A(l(n).toString(16))].join("")}function O(e,t){t=0===t?0:t||10;var n=b(e).toHsl();return n.s-=t/100,n.s=D(n.s),b(n)}function g(e,t){t=0===t?0:t||10;var n=b(e).toHsl();return n.s+=t/100,n.s=D(n.s),b(n)}function h(e){return b(e).desaturate(100)}function j(e,t){t=0===t?0:t||10;var n=b(e).toHsl();return n.l+=t/100,n.l=D(n.l),b(n)}function k(e,t){t=0===t?0:t||10;var n=b(e).toRgb();return n.r=u(0,s(255,n.r-l(-t/100*255))),n.g=u(0,s(255,n.g-l(-t/100*255))),n.b=u(0,s(255,n.b-l(-t/100*255))),b(n)}function y(e,t){t=0===t?0:t||10;var n=b(e).toHsl();return n.l-=t/100,n.l=D(n.l),b(n)}function _(e,t){var n=b(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,b(n)}function E(e){var t=b(e).toHsl();return t.h=(t.h+180)%360,b(t)}function C(e){var t=b(e).toHsl(),n=t.h;return[b(e),b({h:(n+120)%360,s:t.s,l:t.l}),b({h:(n+240)%360,s:t.s,l:t.l})]}function S(e){var t=b(e).toHsl(),n=t.h;return[b(e),b({h:(n+90)%360,s:t.s,l:t.l}),b({h:(n+180)%360,s:t.s,l:t.l}),b({h:(n+270)%360,s:t.s,l:t.l})]}function w(e){var t=b(e).toHsl(),n=t.h;return[b(e),b({h:(n+72)%360,s:t.s,l:t.l}),b({h:(n+216)%360,s:t.s,l:t.l})]}function I(e,t,n){t=t||6,n=n||30;var r=b(e).toHsl(),o=360/n,c=[b(e)];for(r.h=(r.h-(o*t>>1)+720)%360;--t;)r.h=(r.h+o)%360,c.push(b(r));return c}function B(e,t){t=t||6;for(var n=b(e).toHsv(),r=n.h,o=n.s,c=n.v,i=[],a=1/t;t--;)i.push(b({h:r,s:o,v:c})),c=(c+a)%1;return i}b.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var e=this.toRgb();return(299*e.r+587*e.g+114*e.b)/1e3},getLuminance:function(){var e,t,n,r=this.toRgb();return e=r.r/255,t=r.g/255,n=r.b/255,.2126*(e<=.03928?e/12.92:o.pow((e+.055)/1.055,2.4))+.7152*(t<=.03928?t/12.92:o.pow((t+.055)/1.055,2.4))+.0722*(n<=.03928?n/12.92:o.pow((n+.055)/1.055,2.4))},setAlpha:function(e){return this._a=T(e),this._roundA=l(100*this._a)/100,this},toHsv:function(){var e=p(this._r,this._g,this._b);return{h:360*e.h,s:e.s,v:e.v,a:this._a}},toHsvString:function(){var e=p(this._r,this._g,this._b),t=l(360*e.h),n=l(100*e.s),r=l(100*e.v);return 1==this._a?"hsv("+t+", "+n+"%, "+r+"%)":"hsva("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHsl:function(){var e=f(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=f(this._r,this._g,this._b),t=l(360*e.h),n=l(100*e.s),r=l(100*e.l);return 1==this._a?"hsl("+t+", "+n+"%, "+r+"%)":"hsla("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHex:function(e){return m(this._r,this._g,this._b,e)},toHexString:function(e){return"#"+this.toHex(e)},toHex8:function(e){return function(e,t,n,r,o){var c=[A(l(e).toString(16)),A(l(t).toString(16)),A(l(n).toString(16)),A(L(r))];if(o&&c[0].charAt(0)==c[0].charAt(1)&&c[1].charAt(0)==c[1].charAt(1)&&c[2].charAt(0)==c[2].charAt(1)&&c[3].charAt(0)==c[3].charAt(1))return c[0].charAt(0)+c[1].charAt(0)+c[2].charAt(0)+c[3].charAt(0);return c.join("")}(this._r,this._g,this._b,this._a,e)},toHex8String:function(e){return"#"+this.toHex8(e)},toRgb:function(){return{r:l(this._r),g:l(this._g),b:l(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+l(this._r)+", "+l(this._g)+", "+l(this._b)+")":"rgba("+l(this._r)+", "+l(this._g)+", "+l(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:l(100*N(this._r,255))+"%",g:l(100*N(this._g,255))+"%",b:l(100*N(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+l(100*N(this._r,255))+"%, "+l(100*N(this._g,255))+"%, "+l(100*N(this._b,255))+"%)":"rgba("+l(100*N(this._r,255))+"%, "+l(100*N(this._g,255))+"%, "+l(100*N(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(P[m(this._r,this._g,this._b,!0)]||!1)},toFilter:function(e){var t="#"+v(this._r,this._g,this._b,this._a),n=t,r=this._gradientType?"GradientType = 1, ":"";if(e){var o=b(e);n="#"+v(o._r,o._g,o._b,o._a)}return"progid:DXImageTransform.Microsoft.gradient("+r+"startColorstr="+t+",endColorstr="+n+")"},toString:function(e){var t=!!e;e=e||this._format;var n=!1,r=this._a<1&&this._a>=0;return t||!r||"hex"!==e&&"hex6"!==e&&"hex3"!==e&&"hex4"!==e&&"hex8"!==e&&"name"!==e?("rgb"===e&&(n=this.toRgbString()),"prgb"===e&&(n=this.toPercentageRgbString()),"hex"!==e&&"hex6"!==e||(n=this.toHexString()),"hex3"===e&&(n=this.toHexString(!0)),"hex4"===e&&(n=this.toHex8String(!0)),"hex8"===e&&(n=this.toHex8String()),"name"===e&&(n=this.toName()),"hsl"===e&&(n=this.toHslString()),"hsv"===e&&(n=this.toHsvString()),n||this.toHexString()):"name"===e&&0===this._a?this.toName():this.toRgbString()},clone:function(){return b(this.toString())},_applyModification:function(e,t){var n=e.apply(null,[this].concat([].slice.call(t)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(j,arguments)},brighten:function(){return this._applyModification(k,arguments)},darken:function(){return this._applyModification(y,arguments)},desaturate:function(){return this._applyModification(O,arguments)},saturate:function(){return this._applyModification(g,arguments)},greyscale:function(){return this._applyModification(h,arguments)},spin:function(){return this._applyModification(_,arguments)},_applyCombination:function(e,t){return e.apply(null,[this].concat([].slice.call(t)))},analogous:function(){return this._applyCombination(I,arguments)},complement:function(){return this._applyCombination(E,arguments)},monochromatic:function(){return this._applyCombination(B,arguments)},splitcomplement:function(){return this._applyCombination(w,arguments)},triad:function(){return this._applyCombination(C,arguments)},tetrad:function(){return this._applyCombination(S,arguments)}},b.fromRatio=function(e,t){if("object"==typeof e){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]="a"===r?e[r]:M(e[r]));e=n}return b(e,t)},b.equals=function(e,t){return!(!e||!t)&&b(e).toRgbString()==b(t).toRgbString()},b.random=function(){return b.fromRatio({r:d(),g:d(),b:d()})},b.mix=function(e,t,n){n=0===n?0:n||50;var r=b(e).toRgb(),o=b(t).toRgb(),c=n/100;return b({r:(o.r-r.r)*c+r.r,g:(o.g-r.g)*c+r.g,b:(o.b-r.b)*c+r.b,a:(o.a-r.a)*c+r.a})},b.readability=function(e,t){var n=b(e),r=b(t);return(o.max(n.getLuminance(),r.getLuminance())+.05)/(o.min(n.getLuminance(),r.getLuminance())+.05)},b.isReadable=function(e,t,n){var r,o,c=b.readability(e,t);switch(o=!1,(r=function(e){var t,n;t=((e=e||{level:"AA",size:"small"}).level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),"AA"!==t&&"AAA"!==t&&(t="AA");"small"!==n&&"large"!==n&&(n="small");return{level:t,size:n}}(n)).level+r.size){case"AAsmall":case"AAAlarge":o=c>=4.5;break;case"AAlarge":o=c>=3;break;case"AAAsmall":o=c>=7}return o},b.mostReadable=function(e,t,n){var r,o,c,i,a=null,l=0;o=(n=n||{}).includeFallbackColors,c=n.level,i=n.size;for(var s=0;s<t.length;s++)(r=b.readability(e,t[s]))>l&&(l=r,a=b(t[s]));return b.isReadable(e,a,{level:c,size:i})||!o?a:(n.includeFallbackColors=!1,b.mostReadable(e,["#fff","#000"],n))};var x=b.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},P=b.hexNames=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}(x);function T(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function N(e,t){(function(e){return"string"==typeof e&&-1!=e.indexOf(".")&&1===parseFloat(e)})(e)&&(e="100%");var n=function(e){return"string"==typeof e&&-1!=e.indexOf("%")}(e);return e=s(t,u(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),o.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function D(e){return s(1,u(0,e))}function R(e){return parseInt(e,16)}function A(e){return 1==e.length?"0"+e:""+e}function M(e){return e<=1&&(e=100*e+"%"),e}function L(e){return o.round(255*parseFloat(e)).toString(16)}function F(e){return R(e)/255}var V,H,z,U=(H="[\\s|\\(]+("+(V="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)")+")[,|\\s]+("+V+")[,|\\s]+("+V+")\\s*\\)?",z="[\\s|\\(]+("+V+")[,|\\s]+("+V+")[,|\\s]+("+V+")[,|\\s]+("+V+")\\s*\\)?",{CSS_UNIT:new RegExp(V),rgb:new RegExp("rgb"+H),rgba:new RegExp("rgba"+z),hsl:new RegExp("hsl"+H),hsla:new RegExp("hsla"+z),hsv:new RegExp("hsv"+H),hsva:new RegExp("hsva"+z),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/});function G(e){return!!U.CSS_UNIT.exec(e)}e.exports?e.exports=b:void 0===(r=function(){return b}.call(t,n,t,e))||(e.exports=r)}(Math)},function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(15),o=n(51),c=n(50),i=n(56),a=Object(c.a)({name:"Box",keys:["unstable_system"],propsAreEqual:function(e,t){var n=e.unstable_system,o=Object(r.a)(e,["unstable_system"]),c=t.unstable_system,a=Object(r.a)(t,["unstable_system"]);return!(n!==c&&!Object(i.a)(n,c))&&Object(i.a)(o,a)}});Object(o.a)({as:"div",useHook:a})},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(13);var o=Object(r.createContext)((function(e){return void 0===e&&(e="id"),(e?e+"-":"")+Math.random().toString(32).substr(2,6)}))},function(e,t){!function(){e.exports=this.wp.htmlEntities}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(57);function o(e){var t=Object(r.a)(e);if(!t)return!1;if(e.contains(t))return!0;var n=t.getAttribute("aria-activedescendant");return!!n&&(n===e.id||!!e.querySelector("#"+n))}},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=["button","color","file","image","reset","submit"];function o(e){if("BUTTON"===e.tagName)return!0;if("INPUT"===e.tagName){var t=e;return-1!==r.indexOf(t.type)}return!1}},function(e,t,n){"use strict";function r(e,t){return"matches"in e?e.matches(t):"msMatchesSelector"in e?e.msMatchesSelector(t):e.webkitMatchesSelector(t)}function o(e,t){if("closest"in e)return e.closest(t);do{if(r(e,t))return e;e=e.parentElement||e.parentNode}while(null!==e&&1===e.nodeType);return null}n.d(t,"a",(function(){return u})),n.d(t,"b",(function(){return l}));var c=n(57),i="input:not([type='hidden']):not([disabled]), select:not([disabled]), textarea:not([disabled]), a[href], button:not([disabled]), [tabindex], iframe, object, embed, area[href], audio[controls], video[controls], [contenteditable]:not([contenteditable='false'])";function a(e){return r(e,i)&&function(e){return e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0}(e)}function l(e){for(;e&&!a(e);)e=o(e,i);return e}function s(e){return Object(c.a)(e)===e}function u(e,t){var n=void 0===t?{}:t,r=n.isActive,o=void 0===r?s:r,c=n.preventScroll;return o(e)?-1:(e.focus({preventScroll:c}),o(e)?-1:requestAnimationFrame((function(){e.focus({preventScroll:c})})))}},function(e,t,n){"use strict";function r(e){return t=e.currentTarget,n=e.target,!(t===n||t.contains(n));var t,n}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var r=n(15),o=n(51),c=n(50),i=n(67),a=n(13),l=n(63),s=n(71),u=(n(81),n(48)),d=n(59),b=n(70),f=n(73),p=n(57),m=n(72);function v(e){return"undefined"!=typeof window&&-1!==window.navigator.userAgent.indexOf(e)}var O=v("Mac")&&!v("Chrome")&&(v("Safari")||v("Firefox"));function g(e){Object(b.a)(e)||e.focus()}var h=Object(c.a)({name:"Tabbable",compose:i.a,keys:["disabled","focusable"],useOptions:function(e,t){var n=t.disabled;return Object(r.b)({disabled:n},e)},useProps:function(e,t){var n=t.ref,o=t.tabIndex,c=t.onClick,i=t.onMouseDown,b=t.style,v=Object(r.a)(t,["ref","tabIndex","onClick","onMouseDown","style"]),h=Object(a.useRef)(null),j=Object(u.a)(c),k=Object(u.a)(i),y=e.disabled&&!e.focusable,_=Object(a.useState)(!0),E=_[0],C=_[1],S=E?o:o||0,w=e.disabled?Object(r.b)({pointerEvents:"none"},b):b,I=function(){if(O){var e=Object(a.useState)(null),t=e[0],n=e[1];return Object(a.useEffect)((function(){t&&(g(t),n(null))}),[t]),Object(a.useCallback)((function(e){var t=e.currentTarget;if(!Object(f.a)(e)&&Object(s.a)(t)){var r=Object(p.a)(t);if(r){var o="BODY"===r.tagName,c=Object(m.b)(t.parentElement);if(r===c||o&&!c)n(t);else if(c){c.addEventListener("focusin",(function(){return n(t)}),{once:!0})}else{r.addEventListener("blur",(function(){return g(t)}),{once:!0})}}}}),[])}}();Object(d.a)((function(){var e,t=h.current;t&&("BUTTON"!==(e=t).tagName&&"INPUT"!==e.tagName&&"SELECT"!==e.tagName&&"TEXTAREA"!==e.tagName&&"A"!==e.tagName&&"AUDIO"!==e.tagName&&"VIDEO"!==e.tagName&&C(!1))}),[]);var B=Object(a.useCallback)((function(t){var n;if(e.disabled)return t.stopPropagation(),void t.preventDefault();null===(n=j.current)||void 0===n||n.call(j,t)}),[e.disabled]),x=Object(a.useCallback)((function(t){var n;if(e.disabled)return t.stopPropagation(),void t.preventDefault();null===(n=k.current)||void 0===n||n.call(k,t),t.defaultPrevented||null==I||I(t)}),[e.disabled,I]);return Object(r.b)({ref:Object(l.a)(h,n),style:w,tabIndex:y?void 0:S,disabled:!(!y||!E)||void 0,"aria-disabled":!!e.disabled||void 0,onClick:B,onMouseDown:x},v)}});Object(o.a)({as:"div",useHook:h})},,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(13),o=Object(r.createContext)({})},,,function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(13),o=n(76),c=n(55);var i=function(e,t,n){void 0===n&&(n=t.children);var i=Object(r.useContext)(o.a);if(i.useCreateElement)return i.useCreateElement(e,t,n);if("string"==typeof e&&function(e){return"function"==typeof e}(n)){t.children;return n(Object(c.b)(t,["children"]))}return Object(r.createElement)(e,t,n)}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a}));var r=n(2),o=n(0),c=Object(o.createContext)({name:"",isSelected:!1,focusedElement:null,setFocusedElement:r.noop,clientId:null}),i=c.Provider;function a(){return Object(o.useContext)(c)}},function(e,t,n){"use strict";n(108),n(13)},function(e,t,n){"use strict";function r(e){var t=void 0===e?{}:e,n=t.keyMap,r=t.onKey,o=t.stopPropagation,c=t.onKeyDown,i=t.shouldKeyDown,a=void 0===i?function(){return!0}:i,l=t.preventDefault,s=void 0===l||l;return function(e){if(n){var t,i="function"==typeof n?n(e):n,l="function"==typeof s?s(e):s,u="function"==typeof o?o(e):o;if(e.key in i){var d=i[e.key];if("function"==typeof d&&a(e))return l&&e.preventDefault(),u&&e.stopPropagation(),r&&r(e),void d(e)}if(c&&"current"in c)null===(t=c.current)||void 0===t||t.call(c,e);else null==c||c(e)}}}n.d(t,"a",(function(){return r}))},,,,,,function(e,t,n){"use strict";n.d(t,"a",(function(){return d}));var r=n(15),o=n(51),c=n(50),i=n(13),a=n(71),l=(n(81),n(48)),s=n(54),u=n(74);var d=Object(c.a)({name:"Clickable",compose:u.a,keys:["unstable_clickOnEnter","unstable_clickOnSpace"],useOptions:function(e){var t=e.unstable_clickOnEnter,n=void 0===t||t,o=e.unstable_clickOnSpace,c=void 0===o||o,i=Object(r.a)(e,["unstable_clickOnEnter","unstable_clickOnSpace"]);return Object(r.b)({unstable_clickOnEnter:n,unstable_clickOnSpace:c},i)},useProps:function(e,t){var n=t.onKeyDown,o=t.onKeyUp,c=Object(r.a)(t,["onKeyDown","onKeyUp"]),u=Object(i.useState)(!1),d=u[0],b=u[1],f=Object(l.a)(n),p=Object(l.a)(o),m=Object(i.useCallback)((function(t){var n;if(null===(n=f.current)||void 0===n||n.call(f,t),!t.defaultPrevented&&!e.disabled&&!t.metaKey&&Object(s.a)(t)){var r=e.unstable_clickOnEnter&&"Enter"===t.key,o=e.unstable_clickOnSpace&&" "===t.key;if(r||o){if(function(e){var t=e.currentTarget;return!!e.isTrusted&&(Object(a.a)(t)||"INPUT"===t.tagName||"TEXTAREA"===t.tagName||"A"===t.tagName||"SELECT"===t.tagName)}(t))return;t.preventDefault(),r?t.currentTarget.click():o&&b(!0)}}}),[e.disabled,e.unstable_clickOnEnter,e.unstable_clickOnSpace]),v=Object(i.useCallback)((function(t){var n;if(null===(n=p.current)||void 0===n||n.call(p,t),!t.defaultPrevented&&!e.disabled&&!t.metaKey){var r=e.unstable_clickOnSpace&&" "===t.key;d&&r&&(b(!1),t.currentTarget.click())}}),[e.disabled,e.unstable_clickOnSpace,d]);return Object(r.b)({"data-active":d||void 0,onKeyDown:m,onKeyUp:v},c)}});Object(o.a)({as:"button",memo:!0,useHook:d})},,function(e,t){!function(){e.exports=this.wp.warning}()},,function(e,t){!function(){e.exports=this.wp.notices}()},,,,function(e,t,n){"use strict";n.d(t,"a",(function(){return s}));var r=n(15),o=n(51),c=n(50),i=n(13),a=n(68),l=n(65),s=Object(c.a)({useState:l.a,keys:["id"],useOptions:function(e,t){var n=Object(i.useContext)(a.a),o=Object(i.useState)((function(){return e.unstable_idCountRef?(e.unstable_idCountRef.current+=1,"-"+e.unstable_idCountRef.current):e.baseId?"-"+n(""):""}))[0],c=Object(i.useMemo)((function(){return e.baseId||n()}),[e.baseId,n]),l=t.id||e.id||""+c+o;return Object(r.b)(Object(r.b)({},e),{},{id:l})},useProps:function(e,t){return Object(r.b)({id:e.id},t)}});Object(o.a)({as:"div",useHook:s})},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(126);function o(e,t,n){return e.dispatchEvent(Object(r.a)(e,t,n))}},function(e,t,n){"use strict";function r(e){try{var t=e instanceof HTMLInputElement&&null!==e.selectionStart,n="TEXTAREA"===e.tagName,r="true"===e.contentEditable;return t||n||r||!1}catch(e){return!1}}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";function r(e,t){e.value=t}n.d(t,"a",(function(){return r}))},function(e,t,n){"use strict";t.__esModule=!0;var r=n(180);t.default=r.default},function(e,t){!function(){e.exports=this.wp.viewport}()},function(e,t){var n,r,o=e.exports={};function c(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function a(e){if(n===setTimeout)return setTimeout(e,0);if((n===c||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:c}catch(e){n=c}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(e){r=i}}();var l,s=[],u=!1,d=-1;function b(){u&&l&&(u=!1,l.length?s=l.concat(s):d=-1,s.length&&f())}function f(){if(!u){var e=a(b);u=!0;for(var t=s.length;t;){for(l=s,s=[];++d<t;)l&&l[d].run();d=-1,t=s.length}l=null,u=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===i||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function m(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];s.push(new p(e,t)),1!==s.length||u||a(f)},p.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=m,o.addListener=m,o.once=m,o.off=m,o.removeListener=m,o.removeAllListeners=m,o.emit=m,o.prependListener=m,o.prependOnceListener=m,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},,function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(49);function o(e,t,n){if(void 0===n&&(n={}),"function"==typeof KeyboardEvent)return new KeyboardEvent(t,n);var o=Object(r.a)(e).createEvent("KeyboardEvent");return o.initKeyboardEvent(t,n.bubbles,n.cancelable,function(e){return Object(r.a)(e).defaultView||window}(e),n.key,n.location,n.ctrlKey,n.altKey,n.shiftKey,n.metaKey),o}function c(e,t,n){return e.dispatchEvent(o(e,t,n))}},,,,function(e,t,n){"use strict"},function(e,t){!function(){e.exports=this.ReactDOM}()},,,,,,function(e,t,n){"use strict";function r(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(177)),c=r(n(178)),i=n(13),a=r(i),l=r(n(148)),s=r(n(179)),u={arr:Array.isArray,obj:function(e){return"[object Object]"===Object.prototype.toString.call(e)},fun:function(e){return"function"==typeof e},str:function(e){return"string"==typeof e},num:function(e){return"number"==typeof e},und:function(e){return void 0===e},nul:function(e){return null===e},set:function(e){return e instanceof Set},map:function(e){return e instanceof Map},equ:function(e,t){if(typeof e!=typeof t)return!1;if(u.str(e)||u.num(e))return e===t;if(u.obj(e)&&u.obj(t)&&Object.keys(e).length+Object.keys(t).length===0)return!0;var n;for(n in e)if(!(n in t))return!1;for(n in t)if(e[n]!==t[n])return!1;return!u.und(n)||e===t}};function d(){var e=i.useState(!1)[1];return i.useCallback((function(){return e((function(e){return!e}))}),[])}function b(e,t){return u.und(e)||u.nul(e)?t:e}function f(e){return u.und(e)?[]:u.arr(e)?e:[e]}function p(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return u.fun(e)?e.apply(void 0,n):e}function m(e){var t=function(e){return e.to,e.from,e.config,e.onStart,e.onRest,e.onFrame,e.children,e.reset,e.reverse,e.force,e.immediate,e.delay,e.attach,e.destroyed,e.interpolateTo,e.ref,e.lazy,c(e,["to","from","config","onStart","onRest","onFrame","children","reset","reverse","force","immediate","delay","attach","destroyed","interpolateTo","ref","lazy"])}(e);if(u.und(t))return o({to:t},e);var n=Object.keys(e).reduce((function(n,r){var c;return u.und(t[r])?o({},n,((c={})[r]=e[r],c)):n}),{});return o({to:t},n)}var v,O,g=function(){function e(){this.payload=void 0,this.children=[]}var t=e.prototype;return t.getAnimatedValue=function(){return this.getValue()},t.getPayload=function(){return this.payload||this},t.attach=function(){},t.detach=function(){},t.getChildren=function(){return this.children},t.addChild=function(e){0===this.children.length&&this.attach(),this.children.push(e)},t.removeChild=function(e){var t=this.children.indexOf(e);this.children.splice(t,1),0===this.children.length&&this.detach()},e}(),h=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).payload=[],t.attach=function(){return t.payload.forEach((function(e){return e instanceof g&&e.addChild(s(t))}))},t.detach=function(){return t.payload.forEach((function(e){return e instanceof g&&e.removeChild(s(t))}))},t}return l(t,e),t}(g),j=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).payload={},t.attach=function(){return Object.values(t.payload).forEach((function(e){return e instanceof g&&e.addChild(s(t))}))},t.detach=function(){return Object.values(t.payload).forEach((function(e){return e instanceof g&&e.removeChild(s(t))}))},t}l(t,e);var n=t.prototype;return n.getValue=function(e){void 0===e&&(e=!1);var t={};for(var n in this.payload){var r=this.payload[n];(!e||r instanceof g)&&(t[n]=r instanceof g?r[e?"getAnimatedValue":"getValue"]():r)}return t},n.getAnimatedValue=function(){return this.getValue(!0)},t}(g);function k(e,t){v={fn:e,transform:t}}function y(e){O=e}var _,E=function(e){return"undefined"!=typeof window?window.requestAnimationFrame(e):-1},C=function(e){"undefined"!=typeof window&&window.cancelAnimationFrame(e)};function S(e){_=e}var w,I=function(){return Date.now()};function B(e){w=e}var x,P,T=function(e){return e.current};function N(e){x=e}var D=Object.freeze({get applyAnimatedValues(){return v},injectApplyAnimatedValues:k,get colorNames(){return O},injectColorNames:y,get requestFrame(){return E},get cancelFrame(){return C},injectFrame:function(e,t){E=e,C=t},get interpolation(){return _},injectStringInterpolator:S,get now(){return I},injectNow:function(e){I=e},get defaultElement(){return w},injectDefaultElement:B,get animatedApi(){return T},injectAnimatedApi:function(e){T=e},get createAnimatedStyle(){return x},injectCreateAnimatedStyle:N,get manualFrameloop(){return P},injectManualFrameloop:function(e){P=e}}),R=function(e){function t(t,n){var r;return(r=e.call(this)||this).update=void 0,r.payload=t.style?o({},t,{style:x(t.style)}):t,r.update=n,r.attach(),r}return l(t,e),t}(j),A=!1,M=new Set,L=function e(){if(!A)return!1;var t=I(),n=M,r=Array.isArray(n),o=0;for(n=r?n:n[Symbol.iterator]();;){var c;if(r){if(o>=n.length)break;c=n[o++]}else{if((o=n.next()).done)break;c=o.value}for(var i=c,a=!1,l=0;l<i.configs.length;l++){for(var s=i.configs[l],u=void 0,d=void 0,b=0;b<s.animatedValues.length;b++){var f=s.animatedValues[b];if(!f.done){var p=s.fromValues[b],m=s.toValues[b],v=f.lastPosition,O=m instanceof g,h=Array.isArray(s.initialVelocity)?s.initialVelocity[b]:s.initialVelocity;if(O&&(m=m.getValue()),s.immediate)f.setValue(m),f.done=!0;else if("string"!=typeof p&&"string"!=typeof m){if(void 0!==s.duration)v=p+s.easing((t-f.startTime)/s.duration)*(m-p),u=t>=f.startTime+s.duration;else if(s.decay)v=p+h/(1-.998)*(1-Math.exp(-(1-.998)*(t-f.startTime))),(u=Math.abs(f.lastPosition-v)<.1)&&(m=v);else{d=void 0!==f.lastTime?f.lastTime:t,h=void 0!==f.lastVelocity?f.lastVelocity:s.initialVelocity,t>d+64&&(d=t);for(var j=Math.floor(t-d),k=0;k<j;++k){v+=1*(h+=1*((-s.tension*(v-m)+-s.friction*h)/s.mass)/1e3)/1e3}var y=!(!s.clamp||0===s.tension)&&(p<m?v>m:v<m),_=Math.abs(h)<=s.precision,C=0===s.tension||Math.abs(m-v)<=s.precision;u=y||_&&C,f.lastVelocity=h,f.lastTime=t}O&&!s.toValues[b].done&&(u=!1),u?(f.value!==m&&(v=m),f.done=!0):a=!0,f.setValue(v),f.lastPosition=v}else f.setValue(m),f.done=!0}}i.props.onFrame&&(i.values[s.name]=s.interpolation.getValue())}i.props.onFrame&&i.props.onFrame(i.values),a||(M.delete(i),i.stop(!0))}return M.size?P?P():E(e):A=!1,A};function F(e,t,n){if("function"==typeof e)return e;if(Array.isArray(e))return F({range:e,output:t,extrapolate:n});if(_&&"string"==typeof e.output[0])return _(e);var r=e,o=r.output,c=r.range||[0,1],i=r.extrapolateLeft||r.extrapolate||"extend",a=r.extrapolateRight||r.extrapolate||"extend",l=r.easing||function(e){return e};return function(e){var t=function(e,t){for(var n=1;n<t.length-1&&!(t[n]>=e);++n);return n-1}(e,c);return function(e,t,n,r,o,c,i,a,l){var s=l?l(e):e;if(s<t){if("identity"===i)return s;"clamp"===i&&(s=t)}if(s>n){if("identity"===a)return s;"clamp"===a&&(s=n)}if(r===o)return r;if(t===n)return e<=t?r:o;t===-1/0?s=-s:n===1/0?s-=t:s=(s-t)/(n-t);s=c(s),r===-1/0?s=-s:o===1/0?s+=r:s=s*(o-r)+r;return s}(e,c[t],c[t+1],o[t],o[t+1],l,i,a,r.map)}}var V=function(e){function t(n,r,o,c){var i;return(i=e.call(this)||this).calc=void 0,i.payload=n instanceof h&&!(n instanceof t)?n.getPayload():Array.isArray(n)?n:[n],i.calc=F(r,o,c),i}l(t,e);var n=t.prototype;return n.getValue=function(){return this.calc.apply(this,this.payload.map((function(e){return e.getValue()})))},n.updateConfig=function(e,t,n){this.calc=F(e,t,n)},n.interpolate=function(e,n,r){return new t(this,e,n,r)},t}(h);var H=function(e){function t(t){var n;return(n=e.call(this)||this).animatedStyles=new Set,n.value=void 0,n.startPosition=void 0,n.lastPosition=void 0,n.lastVelocity=void 0,n.startTime=void 0,n.lastTime=void 0,n.done=!1,n.setValue=function(e,t){void 0===t&&(t=!0),n.value=e,t&&n.flush()},n.value=t,n.startPosition=t,n.lastPosition=t,n}l(t,e);var n=t.prototype;return n.flush=function(){0===this.animatedStyles.size&&function e(t,n){"update"in t?n.add(t):t.getChildren().forEach((function(t){return e(t,n)}))}(this,this.animatedStyles),this.animatedStyles.forEach((function(e){return e.update()}))},n.clearStyles=function(){this.animatedStyles.clear()},n.getValue=function(){return this.value},n.interpolate=function(e,t,n){return new V(this,e,t,n)},t}(g),z=function(e){function t(t){var n;return(n=e.call(this)||this).payload=t.map((function(e){return new H(e)})),n}l(t,e);var n=t.prototype;return n.setValue=function(e,t){var n=this;void 0===t&&(t=!0),Array.isArray(e)?e.length===this.payload.length&&e.forEach((function(e,r){return n.payload[r].setValue(e,t)})):this.payload.forEach((function(n){return n.setValue(e,t)}))},n.getValue=function(){return this.payload.map((function(e){return e.getValue()}))},n.interpolate=function(e,t){return new V(this,e,t)},t}(h),U=0,G=function(){function e(){var e=this;this.id=void 0,this.idle=!0,this.hasChanged=!1,this.guid=0,this.local=0,this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.listeners=[],this.queue=[],this.localQueue=void 0,this.getValues=function(){return e.interpolations},this.id=U++}var t=e.prototype;return t.update=function(e){if(!e)return this;var t=m(e),n=t.delay,r=void 0===n?0:n,i=t.to,a=c(t,["delay","to"]);if(u.arr(i)||u.fun(i))this.queue.push(o({},a,{delay:r,to:i}));else if(i){var l={};Object.entries(i).forEach((function(e){var t,n=e[0],c=e[1],i=o({to:(t={},t[n]=c,t),delay:p(r,n)},a),s=l[i.delay]&&l[i.delay].to;l[i.delay]=o({},l[i.delay],i,{to:o({},s,i.to)})})),this.queue=Object.values(l)}return this.queue=this.queue.sort((function(e,t){return e.delay-t.delay})),this.diff(a),this},t.start=function(e){var t,n=this;if(this.queue.length){this.idle=!1,this.localQueue&&this.localQueue.forEach((function(e){var t=e.from,r=void 0===t?{}:t,c=e.to,i=void 0===c?{}:c;u.obj(r)&&(n.merged=o({},r,n.merged)),u.obj(i)&&(n.merged=o({},n.merged,i))}));var r=this.local=++this.guid,i=this.localQueue=this.queue;this.queue=[],i.forEach((function(t,o){var a=t.delay,l=c(t,["delay"]),s=function(t){o===i.length-1&&r===n.guid&&t&&(n.idle=!0,n.props.onRest&&n.props.onRest(n.merged)),e&&e()},d=u.arr(l.to)||u.fun(l.to);a?setTimeout((function(){r===n.guid&&(d?n.runAsync(l,s):n.diff(l).start(s))}),a):d?n.runAsync(l,s):n.diff(l).start(s)}))}else u.fun(e)&&this.listeners.push(e),this.props.onStart&&this.props.onStart(),t=this,M.has(t)||M.add(t),A||(A=!0,E(P||L));return this},t.stop=function(e){return this.listeners.forEach((function(t){return t(e)})),this.listeners=[],this},t.pause=function(e){var t;return this.stop(!0),e&&(t=this,M.has(t)&&M.delete(t)),this},t.runAsync=function(e,t){var n=this,r=(e.delay,c(e,["delay"])),i=this.local,a=Promise.resolve(void 0);if(u.arr(r.to))for(var l=function(e){var t=e,c=o({},r,m(r.to[t]));u.arr(c.config)&&(c.config=c.config[t]),a=a.then((function(){if(i===n.guid)return new Promise((function(e){return n.diff(c).start(e)}))}))},s=0;s<r.to.length;s++)l(s);else if(u.fun(r.to)){var d,b=0;a=a.then((function(){return r.to((function(e){var t=o({},r,m(e));if(u.arr(t.config)&&(t.config=t.config[b]),b++,i===n.guid)return d=new Promise((function(e){return n.diff(t).start(e)}))}),(function(e){return void 0===e&&(e=!0),n.stop(e)})).then((function(){return d}))}))}a.then(t)},t.diff=function(e){var t=this;this.props=o({},this.props,e);var n=this.props,r=n.from,c=void 0===r?{}:r,i=n.to,a=void 0===i?{}:i,l=n.config,s=void 0===l?{}:l,d=n.reverse,m=n.attach,v=n.reset,g=n.immediate;if(d){var h=[a,c];c=h[0],a=h[1]}this.merged=o({},c,this.merged,a),this.hasChanged=!1;var j=m&&m(this);if(this.animations=Object.entries(this.merged).reduce((function(e,n){var r=n[0],i=n[1],a=e[r]||{},l=u.num(i),d=u.str(i)&&!i.startsWith("#")&&!/\d/.test(i)&&!O[i],m=u.arr(i),h=!l&&!m&&!d,k=u.und(c[r])?i:c[r],y=l||m||d?i:1,E=p(s,r);j&&(y=j.animations[r].parent);var C,S=a.parent,w=a.interpolation,B=f(j?y.getPayload():y),x=i;h&&(x=_({range:[0,1],output:[i,i]})(1));var P,T=w&&w.getValue(),N=!u.und(S)&&a.animatedValues.some((function(e){return!e.done})),D=!u.equ(x,T),R=!u.equ(x,a.previous),A=!u.equ(E,a.config);if(v||R&&D||A){var M;if(l||d)S=w=a.parent||new H(k);else if(m)S=w=a.parent||new z(k);else if(h){var L=a.interpolation&&a.interpolation.calc(a.parent.value);L=void 0===L||v?k:L,a.parent?(S=a.parent).setValue(0,!1):S=new H(0);var F={output:[L,i]};a.interpolation?(w=a.interpolation,a.interpolation.updateConfig(F)):w=S.interpolate(F)}return B=f(j?y.getPayload():y),C=f(S.getPayload()),v&&!h&&S.setValue(k,!1),t.hasChanged=!0,C.forEach((function(e){e.startPosition=e.value,e.lastPosition=e.value,e.lastVelocity=N?e.lastVelocity:void 0,e.lastTime=N?e.lastTime:void 0,e.startTime=I(),e.done=!1,e.animatedStyles.clear()})),p(g,r)&&S.setValue(h?y:i,!1),o({},e,((M={})[r]=o({},a,{name:r,parent:S,interpolation:w,animatedValues:C,toValues:B,previous:x,config:E,fromValues:f(S.getValue()),immediate:p(g,r),initialVelocity:b(E.velocity,0),clamp:b(E.clamp,!1),precision:b(E.precision,.01),tension:b(E.tension,170),friction:b(E.friction,26),mass:b(E.mass,1),duration:E.duration,easing:b(E.easing,(function(e){return e})),decay:E.decay}),M))}return D?e:(h&&(S.setValue(1,!1),w.updateConfig({output:[x,x]})),S.done=!0,t.hasChanged=!0,o({},e,((P={})[r]=o({},e[r],{previous:x}),P)))}),this.animations),this.hasChanged)for(var k in this.configs=Object.values(this.animations),this.values={},this.interpolations={},this.animations)this.interpolations[k]=this.animations[k].interpolation,this.values[k]=this.animations[k].interpolation.getValue();return this},t.destroy=function(){this.stop(),this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.local=0},e}(),K=function(e,t){var n=i.useRef(!1),r=i.useRef(),o=u.fun(t),c=i.useMemo((function(){var n;return r.current&&(r.current.map((function(e){return e.destroy()})),r.current=void 0),[new Array(e).fill().map((function(e,r){var c=new G,i=o?p(t,r,c):t[r];return 0===r&&(n=i.ref),c.update(i),n||c.start(),c})),n]}),[e]),a=c[0],l=c[1];r.current=a;i.useImperativeHandle(l,(function(){return{start:function(){return Promise.all(r.current.map((function(e){return new Promise((function(t){return e.start(t)}))})))},stop:function(e){return r.current.forEach((function(t){return t.stop(e)}))},get controllers(){return r.current}}}));var s=i.useMemo((function(){return function(e){return r.current.map((function(t,n){t.update(o?p(e,n,t):e[n]),l||t.start()}))}}),[e]);i.useEffect((function(){n.current?o||s(t):l||r.current.forEach((function(e){return e.start()}))})),i.useEffect((function(){return n.current=!0,function(){return r.current.forEach((function(e){return e.destroy()}))}}),[]);var d=r.current.map((function(e){return e.getValues()}));return o?[d,s,function(e){return r.current.forEach((function(t){return t.pause(e)}))}]:d},W=0,q=function(e,t){return("function"==typeof t?e.map(t):f(t)).map(String)},$=function(e){var t=e.items,n=e.keys,r=void 0===n?function(e){return e}:n,i=c(e,["items","keys"]);return t=f(void 0!==t?t:null),o({items:t,keys:q(t,r)},i)};function Y(e,t){var n=function(){if(o){if(c>=r.length)return"break";i=r[c++]}else{if((c=r.next()).done)return"break";i=c.value}var n=i.key,a=function(e){return e.key!==n};(u.und(t)||t===n)&&(e.current.instances.delete(n),e.current.transitions=e.current.transitions.filter(a),e.current.deleted=e.current.deleted.filter(a))},r=e.current.deleted,o=Array.isArray(r),c=0;for(r=o?r:r[Symbol.iterator]();;){var i;if("break"===n())break}e.current.forceUpdate()}var X=function(e){function t(t){var n;return void 0===t&&(t={}),n=e.call(this)||this,!t.transform||t.transform instanceof g||(t=v.transform(t)),n.payload=t,n}return l(t,e),t}(j),Q={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},Z="[-+]?\\d*\\.?\\d+";function J(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return"\\(\\s*("+t.join(")\\s*,\\s*(")+")\\s*\\)"}var ee=new RegExp("rgb"+J(Z,Z,Z)),te=new RegExp("rgba"+J(Z,Z,Z,Z)),ne=new RegExp("hsl"+J(Z,"[-+]?\\d*\\.?\\d+%","[-+]?\\d*\\.?\\d+%")),re=new RegExp("hsla"+J(Z,"[-+]?\\d*\\.?\\d+%","[-+]?\\d*\\.?\\d+%",Z)),oe=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,ce=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,ie=/^#([0-9a-fA-F]{6})$/,ae=/^#([0-9a-fA-F]{8})$/;function le(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function se(e,t,n){var r=n<.5?n*(1+t):n+t-n*t,o=2*n-r,c=le(o,r,e+1/3),i=le(o,r,e),a=le(o,r,e-1/3);return Math.round(255*c)<<24|Math.round(255*i)<<16|Math.round(255*a)<<8}function ue(e){var t=parseInt(e,10);return t<0?0:t>255?255:t}function de(e){return(parseFloat(e)%360+360)%360/360}function be(e){var t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function fe(e){var t=parseFloat(e);return t<0?0:t>100?1:t/100}function pe(e){var t,n,r="number"==typeof(t=e)?t>>>0===t&&t>=0&&t<=4294967295?t:null:(n=ie.exec(t))?parseInt(n[1]+"ff",16)>>>0:Q.hasOwnProperty(t)?Q[t]:(n=ee.exec(t))?(ue(n[1])<<24|ue(n[2])<<16|ue(n[3])<<8|255)>>>0:(n=te.exec(t))?(ue(n[1])<<24|ue(n[2])<<16|ue(n[3])<<8|be(n[4]))>>>0:(n=oe.exec(t))?parseInt(n[1]+n[1]+n[2]+n[2]+n[3]+n[3]+"ff",16)>>>0:(n=ae.exec(t))?parseInt(n[1],16)>>>0:(n=ce.exec(t))?parseInt(n[1]+n[1]+n[2]+n[2]+n[3]+n[3]+n[4]+n[4],16)>>>0:(n=ne.exec(t))?(255|se(de(n[1]),fe(n[2]),fe(n[3])))>>>0:(n=re.exec(t))?(se(de(n[1]),fe(n[2]),fe(n[3]))|be(n[4]))>>>0:null;return null===r?e:"rgba("+((4278190080&(r=r||0))>>>24)+", "+((16711680&r)>>>16)+", "+((65280&r)>>>8)+", "+(255&r)/255+")"}var me=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,ve=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,Oe=new RegExp("("+Object.keys(Q).join("|")+")","g"),ge={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},he=["Webkit","Ms","Moz","O"];function je(e,t,n){return null==t||"boolean"==typeof t||""===t?"":n||"number"!=typeof t||0===t||ge.hasOwnProperty(e)&&ge[e]?(""+t).trim():t+"px"}ge=Object.keys(ge).reduce((function(e,t){return he.forEach((function(n){return e[function(e,t){return e+t.charAt(0).toUpperCase()+t.substring(1)}(n,t)]=e[t]})),e}),ge);var ke={};N((function(e){return new X(e)})),B("div"),S((function(e){var t=e.output.map((function(e){return e.replace(ve,pe)})).map((function(e){return e.replace(Oe,pe)})),n=t[0].match(me).map((function(){return[]}));t.forEach((function(e){e.match(me).forEach((function(e,t){return n[t].push(+e)}))}));var r=t[0].match(me).map((function(t,r){return F(o({},e,{output:n[r]}))}));return function(e){var n=0;return t[0].replace(me,(function(){return r[n++](e)})).replace(/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,(function(e,t,n,r,o){return"rgba("+Math.round(t)+", "+Math.round(n)+", "+Math.round(r)+", "+o+")"}))}})),y(Q),k((function(e,t){if(!e.nodeType||void 0===e.setAttribute)return!1;var n=t.style,r=t.children,o=t.scrollTop,i=t.scrollLeft,a=c(t,["style","children","scrollTop","scrollLeft"]),l="filter"===e.nodeName||e.parentNode&&"filter"===e.parentNode.nodeName;for(var s in void 0!==o&&(e.scrollTop=o),void 0!==i&&(e.scrollLeft=i),void 0!==r&&(e.textContent=r),n)if(n.hasOwnProperty(s)){var u=0===s.indexOf("--"),d=je(s,n[s],u);"float"===s&&(s="cssFloat"),u?e.style.setProperty(s,d):e.style[s]=d}for(var b in a){var f=l?b:ke[b]||(ke[b]=b.replace(/([A-Z])/g,(function(e){return"-"+e.toLowerCase()})));void 0!==e.getAttribute(f)&&e.setAttribute(f,a[b])}}),(function(e){return e}));var ye,_e,Ee=(ye=function(e){return i.forwardRef((function(t,n){var r=d(),l=i.useRef(!0),s=i.useRef(null),b=i.useRef(null),f=i.useCallback((function(e){var t=s.current;s.current=new R(e,(function(){var e=!1;b.current&&(e=v.fn(b.current,s.current.getAnimatedValue())),b.current&&!1!==e||r()})),t&&t.detach()}),[]);i.useEffect((function(){return function(){l.current=!1,s.current&&s.current.detach()}}),[]),i.useImperativeHandle(n,(function(){return T(b,l,r)})),f(t);var p,m=s.current.getValue(),O=(m.scrollTop,m.scrollLeft,c(m,["scrollTop","scrollLeft"])),g=(p=e,!u.fun(p)||p.prototype instanceof a.Component?function(e){return b.current=function(e,t){return t&&(u.fun(t)?t(e):u.obj(t)&&(t.current=e)),e}(e,n)}:void 0);return a.createElement(e,o({},O,{ref:g}))}))},void 0===(_e=!1)&&(_e=!0),function(e){return(u.arr(e)?e:Object.keys(e)).reduce((function(e,t){var n=_e?t[0].toLowerCase()+t.substring(1):t;return e[n]=ye(n),e}),ye)}),Ce=Ee(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]);t.apply=Ee,t.config={default:{tension:170,friction:26},gentle:{tension:120,friction:14},wobbly:{tension:180,friction:12},stiff:{tension:210,friction:20},slow:{tension:280,friction:60},molasses:{tension:280,friction:120}},t.update=L,t.animated=Ce,t.a=Ce,t.interpolate=function(e,t,n){return e&&new V(e,t,n)},t.Globals=D,t.useSpring=function(e){var t=u.fun(e),n=K(1,t?e:[e]),r=n[0],o=n[1],c=n[2];return t?[r[0],o,c]:r},t.useTrail=function(e,t){var n=i.useRef(!1),r=u.fun(t),c=p(t),a=i.useRef(),l=K(e,(function(e,t){return 0===e&&(a.current=[]),a.current.push(t),o({},c,{config:p(c.config,e),attach:e>0&&function(){return a.current[e-1]}})})),s=l[0],d=l[1],b=l[2],f=i.useMemo((function(){return function(e){return d((function(t,n){e.reverse;var r=e.reverse?t+1:t-1,i=a.current[r];return o({},e,{config:p(e.config||c.config,t),attach:i&&function(){return i}})}))}}),[e,c.reverse]);return i.useEffect((function(){n.current&&!r&&f(t)})),i.useEffect((function(){n.current=!0}),[]),r?[s,f,b]:s},t.useTransition=function(e,t,n){var r=o({items:e,keys:t||function(e){return e}},n),a=$(r),l=a.lazy,s=void 0!==l&&l,u=(a.unique,a.reset),b=void 0!==u&&u,f=(a.enter,a.leave,a.update,a.onDestroyed),m=(a.keys,a.items,a.onFrame),v=a.onRest,O=a.onStart,g=a.ref,h=c(a,["lazy","unique","reset","enter","leave","update","onDestroyed","keys","items","onFrame","onRest","onStart","ref"]),j=d(),k=i.useRef(!1),y=i.useRef({mounted:!1,first:!0,deleted:[],current:{},transitions:[],prevProps:{},paused:!!r.ref,instances:!k.current&&new Map,forceUpdate:j});return i.useImperativeHandle(r.ref,(function(){return{start:function(){return Promise.all(Array.from(y.current.instances).map((function(e){var t=e[1];return new Promise((function(e){return t.start(e)}))})))},stop:function(e){return Array.from(y.current.instances).forEach((function(t){return t[1].stop(e)}))},get controllers(){return Array.from(y.current.instances).map((function(e){return e[1]}))}}})),y.current=function(e,t){var n=e.first,r=e.prevProps,i=c(e,["first","prevProps"]),a=$(t),l=a.items,s=a.keys,u=a.initial,d=a.from,b=a.enter,f=a.leave,m=a.update,v=a.trail,O=void 0===v?0:v,g=a.unique,h=a.config,j=a.order,k=void 0===j?["enter","leave","update"]:j,y=$(r),_=y.keys,E=y.items,C=o({},i.current),S=[].concat(i.deleted),w=Object.keys(C),I=new Set(w),B=new Set(s),x=s.filter((function(e){return!I.has(e)})),P=i.transitions.filter((function(e){return!e.destroyed&&!B.has(e.originalKey)})).map((function(e){return e.originalKey})),T=s.filter((function(e){return I.has(e)})),N=-O;for(;k.length;){switch(k.shift()){case"enter":x.forEach((function(e,t){g&&S.find((function(t){return t.originalKey===e}))&&(S=S.filter((function(t){return t.originalKey!==e})));var r=s.indexOf(e),o=l[r],c=n&&void 0!==u?"initial":"enter";C[e]={slot:c,originalKey:e,key:g?String(e):W++,item:o,trail:N+=O,config:p(h,o,c),from:p(n&&void 0!==u?u||{}:d,o),to:p(b,o)}}));break;case"leave":P.forEach((function(e){var t=_.indexOf(e),n=E[t];S.unshift(o({},C[e],{slot:"leave",destroyed:!0,left:_[Math.max(0,t-1)],right:_[Math.min(_.length,t+1)],trail:N+=O,config:p(h,n,"leave"),to:p(f,n)})),delete C[e]}));break;case"update":T.forEach((function(e){var t=s.indexOf(e),n=l[t];C[e]=o({},C[e],{item:n,slot:"update",trail:N+=O,config:p(h,n,"update"),to:p(m,n)})}))}}var D=s.map((function(e){return C[e]}));return S.forEach((function(e){var t,n=e.left,r=(e.right,c(e,["left","right"]));-1!==(t=D.findIndex((function(e){return e.originalKey===n})))&&(t+=1),t=Math.max(0,t),D=[].concat(D.slice(0,t),[r],D.slice(t))})),o({},i,{changed:x.length||P.length||T.length,first:n&&0===x.length,transitions:D,current:C,deleted:S,prevProps:t})}(y.current,r),y.current.changed&&y.current.transitions.forEach((function(e){var t=e.slot,n=e.from,r=e.to,c=e.config,i=e.trail,a=e.key,l=e.item;y.current.instances.has(a)||y.current.instances.set(a,new G);var u=y.current.instances.get(a),d=o({},h,{to:r,from:n,config:c,ref:g,onRest:function(n){y.current.mounted&&(e.destroyed&&(g||s||Y(y,a),f&&f(l)),!Array.from(y.current.instances).some((function(e){return!e[1].idle}))&&(g||s)&&y.current.deleted.length>0&&Y(y),v&&v(l,t,n))},onStart:O&&function(){return O(l,t)},onFrame:m&&function(e){return m(l,t,e)},delay:i,reset:b&&"enter"===t});u.update(d),y.current.paused||u.start()})),i.useEffect((function(){return y.current.mounted=k.current=!0,function(){y.current.mounted=k.current=!1,Array.from(y.current.instances).map((function(e){return e[1].destroy()})),y.current.instances.clear()}}),[]),y.current.transitions.map((function(e){var t=e.item,n=e.slot,r=e.key;return{item:t,key:r,state:n,props:y.current.instances.get(r).getValues()}}))},t.useChain=function(e,t,n){void 0===n&&(n=1e3);var r=i.useRef();i.useEffect((function(){u.equ(e,r.current)?e.forEach((function(e){var t=e.current;return t&&t.start()})):t?e.forEach((function(e,r){var c=e.current;if(c){var i=c.controllers;if(i.length){var a=n*t[r];i.forEach((function(e){e.queue=e.queue.map((function(e){return o({},e,{delay:e.delay+a})})),e.start()}))}}})):e.reduce((function(e,t,n){var r=t.current;return e.then((function(){return r.start()}))}),Promise.resolve()),r.current=e}))},t.useSprings=K},,,,,,,function(e,t,n){"use strict";n.d(t,"a",(function(){return E})),n.d(t,"b",(function(){return _}));var r=n(15),o=n(51),c=n(50),i=n(67),a=n(13),l=n(63),s=(n(81),n(48)),u=n(54),d=n(57),b=n(74),f=n(79),p=n(82),m=n(49),v=n(97),O=n(104),g=n(52),h="undefined"!=typeof window&&"msCrypto"in window;var j="undefined"!=typeof window&&"msCrypto"in window;function k(e,t,n){var r=Object(s.a)(n);return Object(a.useCallback)((function(n){var o;if(e&&function(e){return!!Object(u.a)(e)&&(!e.metaKey&&"Tab"!==e.key)}(n)){var c=null==t?void 0:t.ref.current;if(c&&(Object(O.a)(c,n.type,n),n.currentTarget.contains(c)))return n.stopPropagation(),void n.preventDefault()}null===(o=r.current)||void 0===o||o.call(r,n)}),[e,t])}function y(e,t){return null==e?void 0:e.some((function(e){return!!t&&e.ref.current===t}))}var _=Object(c.a)({name:"Composite",compose:[b.a],useState:g.g,useOptions:function(e){return Object(r.b)(Object(r.b)({},e),{},{currentId:Object(g.e)(e)})},useProps:function(e,t){var n=t.ref,o=t.onFocus,c=t.onBlur,i=t.onKeyDown,b=t.onKeyUp,f=Object(r.a)(t,["ref","onFocus","onBlur","onKeyDown","onKeyUp"]),O=Object(a.useRef)(null),_=Object(g.d)(e.items,e.currentId),E=Object(a.useRef)(void 0),C=Object(s.a)(o),S=Object(s.a)(c),w=j?function(e){var t=Object(a.useRef)(null);return Object(a.useEffect)((function(){var n=Object(m.a)(e.current),r=function(e){var n=e.target;t.current=n};return n.addEventListener("focus",r,!0),function(){n.removeEventListener("focus",r,!0)}}),[]),t}(O):void 0;Object(a.useEffect)((function(){var t=O.current;t&&e.unstable_moves&&!_&&t.focus()}),[e.unstable_moves,_]);var I=k(e.unstable_virtual,_,i),B=k(e.unstable_virtual,_,b),x=Object(a.useCallback)((function(t){var n;if(e.unstable_virtual){var r,o,c=(null==w?void 0:w.current)||t.relatedTarget,i=y(e.items,c);if(Object(u.a)(t)&&!i)return null===(r=C.current)||void 0===r||r.call(C,t),void(null==_||null===(o=_.ref.current)||void 0===o||o.focus());if(i)return void t.stopPropagation()}else if(Object(u.a)(t)){var a;null===(a=e.setCurrentId)||void 0===a||a.call(e,null)}null===(n=C.current)||void 0===n||n.call(C,t)}),[e.unstable_virtual,e.items,_,e.setCurrentId]),P=Object(a.useCallback)((function(t){var n;if(e.unstable_virtual){var r,o=y(e.items,t.target),c=function(e){return h?Object(d.a)(e.target):e.relatedTarget}(t),i=y(e.items,c);if(Object(u.a)(t)&&i)return(null===(r=E.current)||void 0===r?void 0:r.ref.current)&&Object(v.a)(E.current.ref.current,"blur",t),E.current=_,void t.stopPropagation();o?E.current=_:((null==_?void 0:_.ref.current)&&Object(v.a)(_.ref.current,"blur",t),E.current=void 0)}null===(n=S.current)||void 0===n||n.call(S,t)}),[e.unstable_virtual,e.items,_]),T=Object(a.useMemo)((function(){return Object(p.a)({onKeyDown:I,stopPropagation:!0,shouldKeyDown:function(t){return Object(u.a)(t)&&null===e.currentId},keyMap:function(){var t,n="horizontal"!==e.orientation,r="vertical"!==e.orientation,o=!!(null===(t=e.groups)||void 0===t?void 0:t.length),c=e.first&&function(){return e.first()},i=e.last&&function(){return e.last()};return{ArrowUp:(o||n)&&function(){if(o){var t,n=(c=e.items,Object(g.a)(Object(g.b)(Object(g.f)(Object(g.c)(c)))));if(null==n?void 0:n.id)null===(t=e.move)||void 0===t||t.call(e,n.id)}else{var r;null===(r=e.last)||void 0===r||r.call(e)}var c},ArrowRight:(o||r)&&c,ArrowDown:(o||n)&&c,ArrowLeft:(o||r)&&i,Home:c,End:i,PageUp:c,PageDown:i}}})}),[I,e.currentId,e.orientation,e.groups,e.items,e.move,e.last,e.first]);return Object(r.b)({ref:Object(l.a)(O,n),id:e.baseId,onFocus:x,onBlur:P,onKeyDown:T,onKeyUp:B,"aria-activedescendant":e.unstable_virtual&&(null==_?void 0:_.id)||void 0},f)},useComposeProps:function(e,t){t=Object(i.a)(e,t,!0);var n=Object(b.a)(e,t,!0);return e.unstable_virtual||null===e.currentId?n:Object(r.b)(Object(r.b)({},t),{},{ref:n.ref})}}),E=Object(o.a)({as:"div",useHook:_,useCreateElement:function(e,t,n){return Object(f.a)(e,t,n)}})},function(e,t,n){"use strict";n.d(t,"a",(function(){return y})),n.d(t,"b",(function(){return k}));var r=n(15),o=n(51),c=n(50),i=n(13),a=n(63),l=(n(81),n(48)),s=n(54),u=n(70),d=n(73),b=n(72),f=n(88),p=n(82),m=n(49),v=n(52),O=n(96),g=n(98),h=n(99);function j(e){return e.querySelector("[data-composite-item-widget]")}var k=Object(c.a)({name:"CompositeItem",compose:[f.a,O.a],useState:v.g,propsAreEqual:function(e,t){if(!t.id||e.id!==t.id)return f.a.unstable_propsAreEqual(e,t);var n=e.currentId,o=e.unstable_moves,c=Object(r.a)(e,["currentId","unstable_moves"]),i=t.currentId,a=t.unstable_moves,l=Object(r.a)(t,["currentId","unstable_moves"]);if(i!==n){if(t.id===i||t.id===n)return!1}else if(o!==a)return!1;return f.a.unstable_propsAreEqual(c,l)},useOptions:function(e){return Object(r.b)(Object(r.b)({},e),{},{id:e.id,currentId:Object(v.e)(e),unstable_clickOnSpace:!e.unstable_hasActiveWidget&&e.unstable_clickOnSpace})},useProps:function(e,t){var n,o=t.ref,c=t.tabIndex,f=void 0===c?0:c,v=t.onFocus,O=t.onBlur,k=t.onKeyDown,y=t.onClick,_=Object(r.a)(t,["ref","tabIndex","onFocus","onBlur","onKeyDown","onClick"]),E=Object(i.useRef)(null),C=e.id,S=e.disabled&&!e.focusable,w=e.currentId===C,I=Object(l.a)(w),B=Object(i.useRef)(!1),x=function(e){return Object(i.useMemo)((function(){var t;return null===(t=e.items)||void 0===t?void 0:t.find((function(t){return e.id&&t.id===e.id}))}),[e.items,e.id])}(e),P=Object(l.a)(v),T=Object(l.a)(O),N=Object(l.a)(k),D=Object(l.a)(y),R=!e.unstable_virtual&&!e.unstable_hasActiveWidget&&w||!(null===(n=e.items)||void 0===n?void 0:n.length);Object(i.useEffect)((function(){var t;if(C)return null===(t=e.registerItem)||void 0===t||t.call(e,{id:C,ref:E,disabled:!!S}),function(){var t;null===(t=e.unregisterItem)||void 0===t||t.call(e,C)}}),[C,S,e.registerItem,e.unregisterItem]),Object(i.useEffect)((function(){var t=E.current;t&&e.unstable_moves&&I.current&&t.focus()}),[e.unstable_moves]);var A=Object(i.useCallback)((function(t){var n,o;if(null===(n=P.current)||void 0===n||n.call(P,t),!t.defaultPrevented&&!Object(d.a)(t)&&C&&!function(e,t){if(Object(s.a)(e))return!1;for(var n,o=Object(r.c)(t);!(n=o()).done;){if(n.value.ref.current===e.target)return!0}return!1}(t,e.items)&&(null===(o=e.setCurrentId)||void 0===o||o.call(e,C),e.unstable_virtual&&e.baseId&&Object(s.a)(t))){var c=t.target,i=Object(m.a)(c).getElementById(e.baseId);i&&(B.current=!0,Object(b.a)(i))}}),[C,e.items,e.setCurrentId,e.unstable_virtual,e.baseId]),M=Object(i.useCallback)((function(t){var n;if(e.unstable_virtual&&B.current)return B.current=!1,t.preventDefault(),void t.stopPropagation();null===(n=T.current)||void 0===n||n.call(T,t)}),[e.unstable_virtual]),L=Object(i.useCallback)((function(e){var t;if(null===(t=N.current)||void 0===t||t.call(N,e),Object(s.a)(e)&&1===e.key.length&&" "!==e.key){var n=j(e.currentTarget);if(n&&Object(g.a)(n)){n.focus();var r=e.key;window.requestAnimationFrame((function(){Object(h.a)(n,r)}))}}}),[]),F=Object(i.useMemo)((function(){return Object(p.a)({onKeyDown:L,stopPropagation:!0,shouldKeyDown:s.a,keyMap:function(){var t="horizontal"!==e.orientation,n="vertical"!==e.orientation,r=!!(null==x?void 0:x.groupId),o=function(e){var t=j(e.currentTarget);t&&Object(g.a)(t)&&Object(h.a)(t,"")},c=e.up&&function(){return e.up()},i=e.next&&function(){return e.next()},a=e.down&&function(){return e.down()},l=e.previous&&function(){return e.previous()};return{Delete:o,Backspace:o,ArrowUp:(r||t)&&c,ArrowRight:(r||n)&&i,ArrowDown:(r||t)&&a,ArrowLeft:(r||n)&&l,Home:function(t){var n,o;!r||t.ctrlKey?null===(n=e.first)||void 0===n||n.call(e):null===(o=e.previous)||void 0===o||o.call(e,!0)},End:function(t){var n,o;!r||t.ctrlKey?null===(n=e.last)||void 0===n||n.call(e):null===(o=e.next)||void 0===o||o.call(e,!0)},PageUp:function(){var t,n;r?null===(t=e.up)||void 0===t||t.call(e,!0):null===(n=e.first)||void 0===n||n.call(e)},PageDown:function(){var t,n;r?null===(t=e.down)||void 0===t||t.call(e,!0):null===(n=e.last)||void 0===n||n.call(e)}}}})}),[L,e.orientation,x,e.up,e.next,e.down,e.previous,e.first,e.last]),V=Object(i.useCallback)((function(e){var t;if(null===(t=D.current)||void 0===t||t.call(D,e),!e.defaultPrevented){var n=j(e.currentTarget);n&&!Object(u.a)(n)&&n.focus()}}),[]);return Object(r.b)({ref:Object(a.a)(E,o),id:C,tabIndex:R?f:-1,"aria-selected":!(!e.unstable_virtual||!w)||void 0,onFocus:A,onBlur:M,onKeyDown:F,onClick:V},_)}}),y=Object(o.a)({as:"button",memo:!0,useHook:k})},,,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(49);function o(e,t,n){var o,c;if(void 0===n&&(n={}),"function"==typeof Event)return new Event(t,n);var i=Object(r.a)(e).createEvent("Event");return i.initEvent(t,null===(o=n)||void 0===o?void 0:o.bubbles,null===(c=n)||void 0===c?void 0:c.cancelable),i}},function(e,t,n){"use strict";e.exports=n(184)},function(e,t){!function(){e.exports=this.wp.wordcount}()},,function(e,t){!function(){e.exports=this.wp.shortcode}()},,,function(e,t,n){"use strict";var r=n(8),o=n(14),c=n(0),i=n(2),a=n(3),l=n(170),s=Object(a.createSlotFill)("BlockControls"),u=s.Fill,d=s.Slot;var b=function(e){return"BlockControls".concat(e?"-expanded":"")},f=function(e){var t=e.controls,n=e.__experimentalIsExpanded,r=e.children;return Object(l.a)()?Object(c.createElement)(u,{name:b(n)},(function(e){var n=Object(i.isEmpty)(e)?null:e;return Object(c.createElement)(a.__experimentalToolbarContext.Provider,{value:n},Object(c.createElement)(a.ToolbarGroup,{controls:t}),r)})):null};f.Slot=function(e){var t=e.__experimentalIsExpanded,n=void 0!==t&&t,i=Object(o.a)(e,["__experimentalIsExpanded"]),l=Object(c.useContext)(a.__experimentalToolbarContext);return Object(c.createElement)(d,Object(r.a)({name:b(n)},i,{fillProps:l}))},t.a=f},,,,,,,,function(e,t,n){"use strict";var r=n(5),o=n(14),c=n(0);function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}t.a=function(e){var t=e.icon,n=e.size,a=void 0===n?24:n,l=Object(o.a)(e,["icon","size"]);return Object(c.cloneElement)(t,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){Object(r.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({width:a,height:a},l))}},function(e,t,n){"use strict";var r=n(143);function o(){}function c(){}c.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,c,i){if(i!==r){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:c,resetWarningCache:o};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},,,,,function(e,t){e.exports=function(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}},function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(38),o=n(37),c=n(30),i=n(39);function a(e){return Object(r.a)(e)||Object(o.a)(e)||Object(c.a)(e)||Object(i.a)()}},function(e,t,n){"use strict";e.exports=function(e){var t,n={};return function e(t,n){var r;if(Array.isArray(n))for(r=0;r<n.length;r++)e(t,n[r]);else for(r in n)t[r]=(t[r]||[]).concat(n[r])}(n,e),(t=function(e){return function(t){return function(r){var o,c,i=n[r.type],a=t(r);if(i)for(o=0;o<i.length;o++)(c=i[o](r,e))&&e.dispatch(c);return a}}}).effects=n,t}},,,,,,,function(e,t){!function(){e.exports=this.wp.tokenList}()},,function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M13 11.9l3.3-3.4-1.1-1-3.2 3.3-3.2-3.3-1.1 1 3.3 3.4-3.5 3.6 1 1L12 13l3.5 3.5 1-1z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M18.3 5.6L9.9 16.9l-4.6-3.4-.9 1.2 5.8 4.3 9.3-12.6z"}));t.a=c},,,,,,,,,function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(4),o=n(80);function c(){var e=Object(o.b)(),t=e.isSelected,n=e.clientId,c=e.name,i=Object(r.useSelect)((function(e){if(!t){var r=e("core/block-editor"),o=r.getBlockName,i=r.isFirstMultiSelectedBlock,a=r.getMultiSelectedBlockClientIds;return!!i(n)&&a().every((function(e){return o(e)===c}))}}),[n,t,c]);return t||i}},function(e,t){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}}},,,function(e,t,n){"use strict";var r=a(n(307)),o=a(n(312)),c=a(n(213)),i=a(n(210));function a(e){return e&&e.__esModule?e:{default:e}}e.exports={Transition:i.default,TransitionGroup:c.default,ReplaceTransition:o.default,CSSTransition:r.default}},,,function(e,t){function n(){return e.exports=n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},n.apply(this,arguments)}e.exports=n},function(e,t){e.exports=function(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),c=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&(n[r[o]]=e[r[o]])}return n};t.__esModule=!0;var a=n(13),l=n(28),s=n(181),u=n(182),d=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={lineHeight:null},t.dispatchEvent=function(e){var n=document.createEvent("Event");n.initEvent(e,!0,!1),t.textarea.dispatchEvent(n)},t.updateLineHeight=function(){t.setState({lineHeight:u(t.textarea)})},t.onChange=function(e){var n=t.props.onChange;t.currentValue=e.currentTarget.value,n&&n(e)},t.saveDOMNodeRef=function(e){var n=t.props.innerRef;n&&n(e),t.textarea=e},t.getLocals=function(){var e=t,n=e.props,r=(n.onResize,n.maxRows),o=(n.onChange,n.style),a=(n.innerRef,i(n,["onResize","maxRows","onChange","style","innerRef"])),l=e.state.lineHeight,s=e.saveDOMNodeRef,u=r&&l?l*r:null;return c({},a,{saveDOMNodeRef:s,style:u?c({},o,{maxHeight:u}):o,onChange:t.onChange})},t}return o(t,e),t.prototype.componentDidMount=function(){var e=this,t=this.props,n=t.onResize;"number"==typeof t.maxRows&&this.updateLineHeight(),setTimeout((function(){return s(e.textarea)})),n&&this.textarea.addEventListener("autosize:resized",n)},t.prototype.componentWillUnmount=function(){var e=this.props.onResize;e&&this.textarea.removeEventListener("autosize:resized",e),this.dispatchEvent("autosize:destroy")},t.prototype.render=function(){var e=this.getLocals(),t=e.children,n=e.saveDOMNodeRef,r=i(e,["children","saveDOMNodeRef"]);return a.createElement("textarea",c({},r,{ref:n}),t)},t.prototype.componentDidUpdate=function(e){this.props.value===this.currentValue&&this.props.rows===e.rows||this.dispatchEvent("autosize:update")},t.defaultProps={rows:1},t.propTypes={rows:l.number,maxRows:l.number,onResize:l.func,innerRef:l.func},t}(a.Component);t.default=d},function(e,t,n){var r,o,c;
|
||
/*!
|
||
autosize 4.0.2
|
||
license: MIT
|
||
http://www.jacklmoore.com/autosize
|
||
*/o=[e,t],void 0===(c="function"==typeof(r=function(e,t){"use strict";var n,r,o="function"==typeof Map?new Map:(n=[],r=[],{has:function(e){return n.indexOf(e)>-1},get:function(e){return r[n.indexOf(e)]},set:function(e,t){-1===n.indexOf(e)&&(n.push(e),r.push(t))},delete:function(e){var t=n.indexOf(e);t>-1&&(n.splice(t,1),r.splice(t,1))}}),c=function(e){return new Event(e,{bubbles:!0})};try{new Event("test")}catch(e){c=function(e){var t=document.createEvent("Event");return t.initEvent(e,!0,!1),t}}function i(e){if(e&&e.nodeName&&"TEXTAREA"===e.nodeName&&!o.has(e)){var t,n=null,r=null,i=null,a=function(){e.clientWidth!==r&&d()},l=function(t){window.removeEventListener("resize",a,!1),e.removeEventListener("input",d,!1),e.removeEventListener("keyup",d,!1),e.removeEventListener("autosize:destroy",l,!1),e.removeEventListener("autosize:update",d,!1),Object.keys(t).forEach((function(n){e.style[n]=t[n]})),o.delete(e)}.bind(e,{height:e.style.height,resize:e.style.resize,overflowY:e.style.overflowY,overflowX:e.style.overflowX,wordWrap:e.style.wordWrap});e.addEventListener("autosize:destroy",l,!1),"onpropertychange"in e&&"oninput"in e&&e.addEventListener("keyup",d,!1),window.addEventListener("resize",a,!1),e.addEventListener("input",d,!1),e.addEventListener("autosize:update",d,!1),e.style.overflowX="hidden",e.style.wordWrap="break-word",o.set(e,{destroy:l,update:d}),"vertical"===(t=window.getComputedStyle(e,null)).resize?e.style.resize="none":"both"===t.resize&&(e.style.resize="horizontal"),n="content-box"===t.boxSizing?-(parseFloat(t.paddingTop)+parseFloat(t.paddingBottom)):parseFloat(t.borderTopWidth)+parseFloat(t.borderBottomWidth),isNaN(n)&&(n=0),d()}function s(t){var n=e.style.width;e.style.width="0px",e.offsetWidth,e.style.width=n,e.style.overflowY=t}function u(){if(0!==e.scrollHeight){var t=function(e){for(var t=[];e&&e.parentNode&&e.parentNode instanceof Element;)e.parentNode.scrollTop&&t.push({node:e.parentNode,scrollTop:e.parentNode.scrollTop}),e=e.parentNode;return t}(e),o=document.documentElement&&document.documentElement.scrollTop;e.style.height="",e.style.height=e.scrollHeight+n+"px",r=e.clientWidth,t.forEach((function(e){e.node.scrollTop=e.scrollTop})),o&&(document.documentElement.scrollTop=o)}}function d(){u();var t=Math.round(parseFloat(e.style.height)),n=window.getComputedStyle(e,null),r="content-box"===n.boxSizing?Math.round(parseFloat(n.height)):e.offsetHeight;if(r<t?"hidden"===n.overflowY&&(s("scroll"),u(),r="content-box"===n.boxSizing?Math.round(parseFloat(window.getComputedStyle(e,null).height)):e.offsetHeight):"hidden"!==n.overflowY&&(s("hidden"),u(),r="content-box"===n.boxSizing?Math.round(parseFloat(window.getComputedStyle(e,null).height)):e.offsetHeight),i!==r){i=r;var o=c("autosize:resized");try{e.dispatchEvent(o)}catch(e){}}}}function a(e){var t=o.get(e);t&&t.destroy()}function l(e){var t=o.get(e);t&&t.update()}var s=null;"undefined"==typeof window||"function"!=typeof window.getComputedStyle?((s=function(e){return e}).destroy=function(e){return e},s.update=function(e){return e}):((s=function(e,t){return e&&Array.prototype.forEach.call(e.length?e:[e],(function(e){return i(e)})),e}).destroy=function(e){return e&&Array.prototype.forEach.call(e.length?e:[e],a),e},s.update=function(e){return e&&Array.prototype.forEach.call(e.length?e:[e],l),e}),t.default=s,e.exports=t.default})?r.apply(t,o):r)||(e.exports=c)},function(e,t,n){var r=n(183);e.exports=function(e){var t=r(e,"line-height"),n=parseFloat(t,10);if(t===n+""){var o=e.style.lineHeight;e.style.lineHeight=t+"em",t=r(e,"line-height"),n=parseFloat(t,10),o?e.style.lineHeight=o:delete e.style.lineHeight}if(-1!==t.indexOf("pt")?(n*=4,n/=3):-1!==t.indexOf("mm")?(n*=96,n/=25.4):-1!==t.indexOf("cm")?(n*=96,n/=2.54):-1!==t.indexOf("in")?n*=96:-1!==t.indexOf("pc")&&(n*=16),n=Math.round(n),"normal"===t){var c=e.nodeName,i=document.createElement(c);i.innerHTML=" ","TEXTAREA"===c.toUpperCase()&&i.setAttribute("rows","1");var a=r(e,"font-size");i.style.fontSize=a,i.style.padding="0px",i.style.border="0px";var l=document.body;l.appendChild(i),n=i.offsetHeight,l.removeChild(i)}return n}},function(e,t){e.exports=function(e,t,n){return((n=window.getComputedStyle)?n(e):e.currentStyle)[t.replace(/-(\w)/gi,(function(e,t){return t.toUpperCase()}))]}},function(e,t,n){"use strict";var r=n(185);e.exports=function(e,t,n){n=n||{},9===t.nodeType&&(t=r.getWindow(t));var o=n.allowHorizontalScroll,c=n.onlyScrollIfNeeded,i=n.alignWithTop,a=n.alignWithLeft,l=n.offsetTop||0,s=n.offsetLeft||0,u=n.offsetBottom||0,d=n.offsetRight||0;o=void 0===o||o;var b=r.isWindow(t),f=r.offset(e),p=r.outerHeight(e),m=r.outerWidth(e),v=void 0,O=void 0,g=void 0,h=void 0,j=void 0,k=void 0,y=void 0,_=void 0,E=void 0,C=void 0;b?(y=t,C=r.height(y),E=r.width(y),_={left:r.scrollLeft(y),top:r.scrollTop(y)},j={left:f.left-_.left-s,top:f.top-_.top-l},k={left:f.left+m-(_.left+E)+d,top:f.top+p-(_.top+C)+u},h=_):(v=r.offset(t),O=t.clientHeight,g=t.clientWidth,h={left:t.scrollLeft,top:t.scrollTop},j={left:f.left-(v.left+(parseFloat(r.css(t,"borderLeftWidth"))||0))-s,top:f.top-(v.top+(parseFloat(r.css(t,"borderTopWidth"))||0))-l},k={left:f.left+m-(v.left+g+(parseFloat(r.css(t,"borderRightWidth"))||0))+d,top:f.top+p-(v.top+O+(parseFloat(r.css(t,"borderBottomWidth"))||0))+u}),j.top<0||k.top>0?!0===i?r.scrollTop(t,h.top+j.top):!1===i?r.scrollTop(t,h.top+k.top):j.top<0?r.scrollTop(t,h.top+j.top):r.scrollTop(t,h.top+k.top):c||((i=void 0===i||!!i)?r.scrollTop(t,h.top+j.top):r.scrollTop(t,h.top+k.top)),o&&(j.left<0||k.left>0?!0===a?r.scrollLeft(t,h.left+j.left):!1===a?r.scrollLeft(t,h.left+k.left):j.left<0?r.scrollLeft(t,h.left+j.left):r.scrollLeft(t,h.left+k.left):c||((a=void 0===a||!!a)?r.scrollLeft(t,h.left+j.left):r.scrollLeft(t,h.left+k.left)))}},function(e,t,n){"use strict";var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};function c(e,t){var n=e["page"+(t?"Y":"X")+"Offset"],r="scroll"+(t?"Top":"Left");if("number"!=typeof n){var o=e.document;"number"!=typeof(n=o.documentElement[r])&&(n=o.body[r])}return n}function i(e){return c(e)}function a(e){return c(e,!0)}function l(e){var t=function(e){var t,n=void 0,r=void 0,o=e.ownerDocument,c=o.body,i=o&&o.documentElement;return n=(t=e.getBoundingClientRect()).left,r=t.top,{left:n-=i.clientLeft||c.clientLeft||0,top:r-=i.clientTop||c.clientTop||0}}(e),n=e.ownerDocument,r=n.defaultView||n.parentWindow;return t.left+=i(r),t.top+=a(r),t}var s=new RegExp("^("+/[\-+]?(?:\d*\.|)\d+(?:[eE][\-+]?\d+|)/.source+")(?!px)[a-z%]+$","i"),u=/^(top|right|bottom|left)$/,d="left";var b=void 0;function f(e,t){for(var n=0;n<e.length;n++)t(e[n])}function p(e){return"border-box"===b(e,"boxSizing")}"undefined"!=typeof window&&(b=window.getComputedStyle?function(e,t,n){var r="",o=e.ownerDocument,c=n||o.defaultView.getComputedStyle(e,null);return c&&(r=c.getPropertyValue(t)||c[t]),r}:function(e,t){var n=e.currentStyle&&e.currentStyle[t];if(s.test(n)&&!u.test(t)){var r=e.style,o=r[d],c=e.runtimeStyle[d];e.runtimeStyle[d]=e.currentStyle[d],r[d]="fontSize"===t?"1em":n||0,n=r.pixelLeft+"px",r[d]=o,e.runtimeStyle[d]=c}return""===n?"auto":n});var m=["margin","border","padding"];function v(e,t,n){var r={},o=e.style,c=void 0;for(c in t)t.hasOwnProperty(c)&&(r[c]=o[c],o[c]=t[c]);for(c in n.call(e),t)t.hasOwnProperty(c)&&(o[c]=r[c])}function O(e,t,n){var r=0,o=void 0,c=void 0,i=void 0;for(c=0;c<t.length;c++)if(o=t[c])for(i=0;i<n.length;i++){var a=void 0;a="border"===o?o+n[i]+"Width":o+n[i],r+=parseFloat(b(e,a))||0}return r}function g(e){return null!=e&&e==e.window}var h={};function j(e,t,n){if(g(e))return"width"===t?h.viewportWidth(e):h.viewportHeight(e);if(9===e.nodeType)return"width"===t?h.docWidth(e):h.docHeight(e);var r="width"===t?["Left","Right"]:["Top","Bottom"],o="width"===t?e.offsetWidth:e.offsetHeight,c=(b(e),p(e)),i=0;(null==o||o<=0)&&(o=void 0,(null==(i=b(e,t))||Number(i)<0)&&(i=e.style[t]||0),i=parseFloat(i)||0),void 0===n&&(n=c?1:-1);var a=void 0!==o||c,l=o||i;if(-1===n)return a?l-O(e,["border","padding"],r):i;if(a){var s=2===n?-O(e,["border"],r):O(e,["margin"],r);return l+(1===n?0:s)}return i+O(e,m.slice(n),r)}f(["Width","Height"],(function(e){h["doc"+e]=function(t){var n=t.document;return Math.max(n.documentElement["scroll"+e],n.body["scroll"+e],h["viewport"+e](n))},h["viewport"+e]=function(t){var n="client"+e,r=t.document,o=r.body,c=r.documentElement[n];return"CSS1Compat"===r.compatMode&&c||o&&o[n]||c}}));var k={position:"absolute",visibility:"hidden",display:"block"};function y(e){var t=void 0,n=arguments;return 0!==e.offsetWidth?t=j.apply(void 0,n):v(e,k,(function(){t=j.apply(void 0,n)})),t}function _(e,t,n){var r=n;if("object"!==(void 0===t?"undefined":o(t)))return void 0!==r?("number"==typeof r&&(r+="px"),void(e.style[t]=r)):b(e,t);for(var c in t)t.hasOwnProperty(c)&&_(e,c,t[c])}f(["width","height"],(function(e){var t=e.charAt(0).toUpperCase()+e.slice(1);h["outer"+t]=function(t,n){return t&&y(t,e,n?0:1)};var n="width"===e?["Left","Right"]:["Top","Bottom"];h[e]=function(t,r){if(void 0===r)return t&&y(t,e,-1);if(t){b(t);return p(t)&&(r+=O(t,["padding","border"],n)),_(t,e,r)}}})),e.exports=r({getWindow:function(e){var t=e.ownerDocument||e;return t.defaultView||t.parentWindow},offset:function(e,t){if(void 0===t)return l(e);!function(e,t){"static"===_(e,"position")&&(e.style.position="relative");var n=l(e),r={},o=void 0,c=void 0;for(c in t)t.hasOwnProperty(c)&&(o=parseFloat(_(e,c))||0,r[c]=o+t[c]-n[c]);_(e,r)}(e,t)},isWindow:g,each:f,css:_,clone:function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);if(e.overflow)for(var n in e)e.hasOwnProperty(n)&&(t.overflow[n]=e.overflow[n]);return t},scrollLeft:function(e,t){if(g(e)){if(void 0===t)return i(e);window.scrollTo(t,a(e))}else{if(void 0===t)return e.scrollLeft;e.scrollLeft=t}},scrollTop:function(e,t){if(g(e)){if(void 0===t)return a(e);window.scrollTo(i(e),t)}else{if(void 0===t)return e.scrollTop;e.scrollTop=t}},viewportWidth:0,viewportHeight:0},h)},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{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"}));t.a=c},,,,,,,,,,,,,,,,,,,,,,function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M19 8h-1V6h-5v2h-2V6H6v2H5c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-8c0-1.1-.9-2-2-2zm.5 10c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5v-8c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v8z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M18 11.2h-5.2V6h-1.6v5.2H6v1.6h5.2V18h1.6v-5.2H18z"}));t.a=c},function(e,t,n){"use strict";t.__esModule=!0,t.default=t.EXITING=t.ENTERED=t.ENTERING=t.EXITED=t.UNMOUNTED=void 0;var r=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}(n(28)),o=a(n(13)),c=a(n(109)),i=n(211);n(212);function a(e){return e&&e.__esModule?e:{default:e}}t.UNMOUNTED="unmounted";t.EXITED="exited";t.ENTERING="entering";t.ENTERED="entered";t.EXITING="exiting";var l=function(e){var t,n;function r(t,n){var r;r=e.call(this,t,n)||this;var o,c=n.transitionGroup,i=c&&!c.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?i?(o="exited",r.appearStatus="entering"):o="entered":o=t.unmountOnExit||t.mountOnEnter?"unmounted":"exited",r.state={status:o},r.nextCallback=null,r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var i=r.prototype;return i.getChildContext=function(){return{transitionGroup:null}},r.getDerivedStateFromProps=function(e,t){return e.in&&"unmounted"===t.status?{status:"exited"}:null},i.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},i.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?"entering"!==n&&"entered"!==n&&(t="entering"):"entering"!==n&&"entered"!==n||(t="exiting")}this.updateStatus(!1,t)},i.componentWillUnmount=function(){this.cancelNextCallback()},i.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=void 0!==r.appear?r.appear:t),{exit:e,enter:t,appear:n}},i.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var n=c.default.findDOMNode(this);"entering"===t?this.performEnter(n,e):this.performExit(n)}else this.props.unmountOnExit&&"exited"===this.state.status&&this.setState({status:"unmounted"})},i.performEnter=function(e,t){var n=this,r=this.props.enter,o=this.context.transitionGroup?this.context.transitionGroup.isMounting:t,c=this.getTimeouts(),i=o?c.appear:c.enter;t||r?(this.props.onEnter(e,o),this.safeSetState({status:"entering"},(function(){n.props.onEntering(e,o),n.onTransitionEnd(e,i,(function(){n.safeSetState({status:"entered"},(function(){n.props.onEntered(e,o)}))}))}))):this.safeSetState({status:"entered"},(function(){n.props.onEntered(e)}))},i.performExit=function(e){var t=this,n=this.props.exit,r=this.getTimeouts();n?(this.props.onExit(e),this.safeSetState({status:"exiting"},(function(){t.props.onExiting(e),t.onTransitionEnd(e,r.exit,(function(){t.safeSetState({status:"exited"},(function(){t.props.onExited(e)}))}))}))):this.safeSetState({status:"exited"},(function(){t.props.onExited(e)}))},i.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},i.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},i.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},i.onTransitionEnd=function(e,t,n){this.setNextCallback(n);var r=null==t&&!this.props.addEndListener;e&&!r?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},i.render=function(){var e=this.state.status;if("unmounted"===e)return null;var t=this.props,n=t.children,r=function(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(t,["children"]);if(delete r.in,delete r.mountOnEnter,delete r.unmountOnExit,delete r.appear,delete r.enter,delete r.exit,delete r.timeout,delete r.addEndListener,delete r.onEnter,delete r.onEntering,delete r.onEntered,delete r.onExit,delete r.onExiting,delete r.onExited,"function"==typeof n)return n(e,r);var c=o.default.Children.only(n);return o.default.cloneElement(c,r)},r}(o.default.Component);function s(){}l.contextTypes={transitionGroup:r.object},l.childContextTypes={transitionGroup:function(){}},l.propTypes={},l.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:s,onEntering:s,onEntered:s,onExit:s,onExiting:s,onExited:s},l.UNMOUNTED=0,l.EXITED=1,l.ENTERING=2,l.ENTERED=3,l.EXITING=4;var u=(0,i.polyfill)(l);t.default=u},function(e,t,n){"use strict";function r(){var e=this.constructor.getDerivedStateFromProps(this.props,this.state);null!=e&&this.setState(e)}function o(e){this.setState(function(t){var n=this.constructor.getDerivedStateFromProps(e,t);return null!=n?n:null}.bind(this))}function c(e,t){try{var n=this.props,r=this.state;this.props=e,this.state=t,this.__reactInternalSnapshotFlag=!0,this.__reactInternalSnapshot=this.getSnapshotBeforeUpdate(n,r)}finally{this.props=n,this.state=r}}function i(e){var t=e.prototype;if(!t||!t.isReactComponent)throw new Error("Can only polyfill class components");if("function"!=typeof e.getDerivedStateFromProps&&"function"!=typeof t.getSnapshotBeforeUpdate)return e;var n=null,i=null,a=null;if("function"==typeof t.componentWillMount?n="componentWillMount":"function"==typeof t.UNSAFE_componentWillMount&&(n="UNSAFE_componentWillMount"),"function"==typeof t.componentWillReceiveProps?i="componentWillReceiveProps":"function"==typeof t.UNSAFE_componentWillReceiveProps&&(i="UNSAFE_componentWillReceiveProps"),"function"==typeof t.componentWillUpdate?a="componentWillUpdate":"function"==typeof t.UNSAFE_componentWillUpdate&&(a="UNSAFE_componentWillUpdate"),null!==n||null!==i||null!==a){var l=e.displayName||e.name,s="function"==typeof e.getDerivedStateFromProps?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";throw Error("Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n"+l+" uses "+s+" but also contains the following legacy lifecycles:"+(null!==n?"\n "+n:"")+(null!==i?"\n "+i:"")+(null!==a?"\n "+a:"")+"\n\nThe above lifecycles should be removed. Learn more about this warning here:\nhttps://fb.me/react-async-component-lifecycle-hooks")}if("function"==typeof e.getDerivedStateFromProps&&(t.componentWillMount=r,t.componentWillReceiveProps=o),"function"==typeof t.getSnapshotBeforeUpdate){if("function"!=typeof t.componentDidUpdate)throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");t.componentWillUpdate=c;var u=t.componentDidUpdate;t.componentDidUpdate=function(e,t,n){var r=this.__reactInternalSnapshotFlag?this.__reactInternalSnapshot:n;u.call(this,e,t,r)}}return e}n.r(t),n.d(t,"polyfill",(function(){return i})),r.__suppressDeprecationWarning=!0,o.__suppressDeprecationWarning=!0,c.__suppressDeprecationWarning=!0},function(e,t,n){"use strict";t.__esModule=!0,t.classNamesShape=t.timeoutsShape=void 0;var r;(r=n(28))&&r.__esModule;t.timeoutsShape=null;t.classNamesShape=null},function(e,t,n){"use strict";t.__esModule=!0,t.default=void 0;var r=a(n(28)),o=a(n(13)),c=n(211),i=n(313);function a(e){return e&&e.__esModule?e:{default:e}}function l(){return(l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function s(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var u=Object.values||function(e){return Object.keys(e).map((function(t){return e[t]}))},d=function(e){var t,n;function r(t,n){var r,o=(r=e.call(this,t,n)||this).handleExited.bind(s(s(r)));return r.state={handleExited:o,firstRender:!0},r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var c=r.prototype;return c.getChildContext=function(){return{transitionGroup:{isMounting:!this.appeared}}},c.componentDidMount=function(){this.appeared=!0,this.mounted=!0},c.componentWillUnmount=function(){this.mounted=!1},r.getDerivedStateFromProps=function(e,t){var n=t.children,r=t.handleExited;return{children:t.firstRender?(0,i.getInitialChildMapping)(e,r):(0,i.getNextChildMapping)(e,n,r),firstRender:!1}},c.handleExited=function(e,t){var n=(0,i.getChildMapping)(this.props.children);e.key in n||(e.props.onExited&&e.props.onExited(t),this.mounted&&this.setState((function(t){var n=l({},t.children);return delete n[e.key],{children:n}})))},c.render=function(){var e=this.props,t=e.component,n=e.childFactory,r=function(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,["component","childFactory"]),c=u(this.state.children).map(n);return delete r.appear,delete r.enter,delete r.exit,null===t?c:o.default.createElement(t,r,c)},r}(o.default.Component);d.childContextTypes={transitionGroup:r.default.object.isRequired},d.propTypes={},d.defaultProps={component:"div",childFactory:function(e){return e}};var b=(0,c.polyfill)(d);t.default=b,e.exports=t.default},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(r.createElement)(o.Path,{d:"M16 4h2v9H7v3l-5-4 5-4v3h9V4z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M18.5 15v3.5H13V6.7l4.5 4.1 1-1.1-6.2-5.8-5.8 5.8 1 1.1 4-4v11.7h-6V15H4v5h16v-5z"}));t.a=c},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{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"}));t.a=c},,,function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.dispatch;return function(e){return function(n){return Array.isArray(n)?n.filter(Boolean).map(t):e(n)}}}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r=n(12),o=n(0),c=n(174),i=n(2),a=(n(90),n(133));function l(e){var t=e.children,n=e.className;return Object(o.createElement)(a.a.Slot,{__experimentalIsExpanded:!0},(function(e){return Object(o.createElement)(s,{className:n,fills:e},t)}))}function s(t){var n=t.fills,a=t.className,l=void 0===a?"":a,s=t.children,u=Object(o.useRef)(),d=Object(o.useRef)(),b=Object(o.useRef)(),f=Object(o.useState)({}),p=Object(r.a)(f,2),m=p[0],v=p[1],O=Object(o.useRef)();O.current=n;var g=Object(o.useCallback)(Object(i.throttle)((function(){var e=O.current.length?d.current:b.current;if(e){e.style.position="absolute",e.style.width="auto";var t,n=(t=e).ownerDocument.defaultView.getComputedStyle(t);v({width:n.getPropertyValue("width"),height:n.getPropertyValue("height")}),e.style.position="",e.style.width=""}}),100),[]);Object(o.useEffect)((function(){var e=new window.MutationObserver((function(e){e.find((function(e){return"childList"===e.type}))&&g()}));return e.observe(u.current,{childList:!0,subtree:!0}),function(){return e.disconnect()}}),[]),Object(o.useEffect)((function(){n.length>1&&void 0!==e&&e.env}),[n.length]);var h=n[0];return Object(o.createElement)("div",{className:"block-editor-block-toolbar-animated-width-container",ref:u,style:m},Object(o.createElement)(c.TransitionGroup,null,h?Object(o.createElement)(c.CSSTransition,{key:"fills",timeout:300,classNames:"block-editor-block-toolbar-content"},Object(o.createElement)("div",{className:l,ref:d},h)):Object(o.createElement)(c.CSSTransition,{key:"default",timeout:300,classNames:"block-editor-block-toolbar-content"},Object(o.createElement)("div",{className:l,ref:b},s))))}}).call(this,n(102))},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.diffChars=function(e,t,n){return o.diff(e,t,n)},t.characterDiff=void 0;var o=new(((r=n(317))&&r.__esModule?r:{default:r}).default);t.characterDiff=o},function(e,t,n){"use strict";t.match=function(e,t){return l(e).some((function(e){var n=e.inverse,r="all"===e.type||t.type===e.type;if(r&&n||!r&&!n)return!1;var o=e.expressions.every((function(e){var n=e.feature,r=e.modifier,o=e.value,c=t[n];if(!c)return!1;switch(n){case"orientation":case"scan":return c.toLowerCase()===o.toLowerCase();case"width":case"height":case"device-width":case"device-height":o=d(o),c=d(c);break;case"resolution":o=u(o),c=u(c);break;case"aspect-ratio":case"device-aspect-ratio":case"device-pixel-ratio":o=s(o),c=s(c);break;case"grid":case"color":case"color-index":case"monochrome":o=parseInt(o,10)||1,c=parseInt(c,10)||0}switch(r){case"min":return c>=o;case"max":return c<=o;default:return c===o}}));return o&&!n||!o&&n}))},t.parse=l;var r=/(?:(only|not)?\s*([^\s\(\)]+)(?:\s*and)?\s*)?(.+)?/i,o=/\(\s*([^\s\:\)]+)\s*(?:\:\s*([^\s\)]+))?\s*\)/,c=/^(?:(min|max)-)?(.+)/,i=/(em|rem|px|cm|mm|in|pt|pc)?$/,a=/(dpi|dpcm|dppx)?$/;function l(e){return e.split(",").map((function(e){var t=(e=e.trim()).match(r),n=t[1],i=t[2],a=t[3]||"",l={};return l.inverse=!!n&&"not"===n.toLowerCase(),l.type=i?i.toLowerCase():"all",a=a.match(/\([^\)]+\)/g)||[],l.expressions=a.map((function(e){var t=e.match(o),n=t[1].toLowerCase().match(c);return{modifier:n[1],feature:n[2],value:t[2]}})),l}))}function s(e){var t,n=Number(e);return n||(n=(t=e.match(/^(\d+)\s*\/\s*(\d+)$/))[1]/t[2]),n}function u(e){var t=parseFloat(e);switch(String(e).match(a)[1]){case"dpcm":return t/2.54;case"dppx":return 96*t;default:return t}}function d(e){var t=parseFloat(e);switch(String(e).match(i)[1]){case"em":case"rem":return 16*t;case"cm":return 96*t/2.54;case"mm":return 96*t/2.54/10;case"in":return 96*t;case"pt":return 72*t;case"pc":return 72*t/12;default:return t}}},function(e,t){var n=e.exports=function(e){return new r(e)};function r(e){this.value=e}function o(e,t,n){var r=[],o=[],a=!0;return function e(d){var b=n?c(d):d,f={},p=!0,m={node:b,node_:d,path:[].concat(r),parent:o[o.length-1],parents:o,key:r.slice(-1)[0],isRoot:0===r.length,level:r.length,circular:null,update:function(e,t){m.isRoot||(m.parent.node[m.key]=e),m.node=e,t&&(p=!1)},delete:function(e){delete m.parent.node[m.key],e&&(p=!1)},remove:function(e){l(m.parent.node)?m.parent.node.splice(m.key,1):delete m.parent.node[m.key],e&&(p=!1)},keys:null,before:function(e){f.before=e},after:function(e){f.after=e},pre:function(e){f.pre=e},post:function(e){f.post=e},stop:function(){a=!1},block:function(){p=!1}};if(!a)return m;function v(){if("object"==typeof m.node&&null!==m.node){m.keys&&m.node_===m.node||(m.keys=i(m.node)),m.isLeaf=0==m.keys.length;for(var e=0;e<o.length;e++)if(o[e].node_===d){m.circular=o[e];break}}else m.isLeaf=!0,m.keys=null;m.notLeaf=!m.isLeaf,m.notRoot=!m.isRoot}v();var O=t.call(m,m.node);return void 0!==O&&m.update&&m.update(O),f.before&&f.before.call(m,m.node),p?("object"!=typeof m.node||null===m.node||m.circular||(o.push(m),v(),s(m.keys,(function(t,o){r.push(t),f.pre&&f.pre.call(m,m.node[t],t);var c=e(m.node[t]);n&&u.call(m.node,t)&&(m.node[t]=c.node),c.isLast=o==m.keys.length-1,c.isFirst=0==o,f.post&&f.post.call(m,c),r.pop()})),o.pop()),f.after&&f.after.call(m,m.node),m):m}(e).node}function c(e){if("object"==typeof e&&null!==e){var t;if(l(e))t=[];else if("[object Date]"===a(e))t=new Date(e.getTime?e.getTime():e);else if(function(e){return"[object RegExp]"===a(e)}(e))t=new RegExp(e);else if(function(e){return"[object Error]"===a(e)}(e))t={message:e.message};else if(function(e){return"[object Boolean]"===a(e)}(e))t=new Boolean(e);else if(function(e){return"[object Number]"===a(e)}(e))t=new Number(e);else if(function(e){return"[object String]"===a(e)}(e))t=new String(e);else if(Object.create&&Object.getPrototypeOf)t=Object.create(Object.getPrototypeOf(e));else if(e.constructor===Object)t={};else{var n=e.constructor&&e.constructor.prototype||e.__proto__||{},r=function(){};r.prototype=n,t=new r}return s(i(e),(function(n){t[n]=e[n]})),t}return e}r.prototype.get=function(e){for(var t=this.value,n=0;n<e.length;n++){var r=e[n];if(!t||!u.call(t,r)){t=void 0;break}t=t[r]}return t},r.prototype.has=function(e){for(var t=this.value,n=0;n<e.length;n++){var r=e[n];if(!t||!u.call(t,r))return!1;t=t[r]}return!0},r.prototype.set=function(e,t){for(var n=this.value,r=0;r<e.length-1;r++){var o=e[r];u.call(n,o)||(n[o]={}),n=n[o]}return n[e[r]]=t,t},r.prototype.map=function(e){return o(this.value,e,!0)},r.prototype.forEach=function(e){return this.value=o(this.value,e,!1),this.value},r.prototype.reduce=function(e,t){var n=1===arguments.length,r=n?this.value:t;return this.forEach((function(t){this.isRoot&&n||(r=e.call(this,r,t))})),r},r.prototype.paths=function(){var e=[];return this.forEach((function(t){e.push(this.path)})),e},r.prototype.nodes=function(){var e=[];return this.forEach((function(t){e.push(this.node)})),e},r.prototype.clone=function(){var e=[],t=[];return function n(r){for(var o=0;o<e.length;o++)if(e[o]===r)return t[o];if("object"==typeof r&&null!==r){var a=c(r);return e.push(r),t.push(a),s(i(r),(function(e){a[e]=n(r[e])})),e.pop(),t.pop(),a}return r}(this.value)};var i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};function a(e){return Object.prototype.toString.call(e)}var l=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},s=function(e,t){if(e.forEach)return e.forEach(t);for(var n=0;n<e.length;n++)t(e[n],n,e)};s(i(r.prototype),(function(e){n[e]=function(t){var n=[].slice.call(arguments,1),o=new r(t);return o[e].apply(o,n)}}));var u=Object.hasOwnProperty||function(e,t){return t in e}},,,,,,,,,,,,,,,,,,,,,,function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M4 19.8h8.9v-1.5H4v1.5zm8.9-15.6H4v1.5h8.9V4.2zm-8.9 7v1.5h16v-1.5H4z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M16.4 4.2H7.6v1.5h8.9V4.2zM4 11.2v1.5h16v-1.5H4zm3.6 8.6h8.9v-1.5H7.6v1.5z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M11.1 19.8H20v-1.5h-8.9v1.5zm0-15.6v1.5H20V4.2h-8.9zM4 12.8h16v-1.5H4v1.5z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M13.5 6C10.5 6 8 8.5 8 11.5c0 1.1.3 2.1.9 3l-3.4 3 1 1.1 3.4-2.9c1 .9 2.2 1.4 3.6 1.4 3 0 5.5-2.5 5.5-5.5C19 8.5 16.5 6 13.5 6zm0 9.5c-2.2 0-4-1.8-4-4s1.8-4 4-4 4 1.8 4 4-1.8 4-4 4z"}));t.a=c},function(e,t,n){"use strict";t.__esModule=!0,t.default=void 0;!function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}t.default=e}(n(28));var r=a(n(308)),o=a(n(311)),c=a(n(13)),i=a(n(210));n(212);function a(e){return e&&e.__esModule?e:{default:e}}function l(){return(l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}var s=function(e,t){return e&&t&&t.split(" ").forEach((function(t){return(0,r.default)(e,t)}))},u=function(e,t){return e&&t&&t.split(" ").forEach((function(t){return(0,o.default)(e,t)}))},d=function(e){var t,n;function r(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).onEnter=function(e,n){var r=t.getClassNames(n?"appear":"enter").className;t.removeClasses(e,"exit"),s(e,r),t.props.onEnter&&t.props.onEnter(e,n)},t.onEntering=function(e,n){var r=t.getClassNames(n?"appear":"enter").activeClassName;t.reflowAndAddClass(e,r),t.props.onEntering&&t.props.onEntering(e,n)},t.onEntered=function(e,n){var r=t.getClassNames("appear").doneClassName,o=t.getClassNames("enter").doneClassName,c=n?r+" "+o:o;t.removeClasses(e,n?"appear":"enter"),s(e,c),t.props.onEntered&&t.props.onEntered(e,n)},t.onExit=function(e){var n=t.getClassNames("exit").className;t.removeClasses(e,"appear"),t.removeClasses(e,"enter"),s(e,n),t.props.onExit&&t.props.onExit(e)},t.onExiting=function(e){var n=t.getClassNames("exit").activeClassName;t.reflowAndAddClass(e,n),t.props.onExiting&&t.props.onExiting(e)},t.onExited=function(e){var n=t.getClassNames("exit").doneClassName;t.removeClasses(e,"exit"),s(e,n),t.props.onExited&&t.props.onExited(e)},t.getClassNames=function(e){var n=t.props.classNames,r="string"==typeof n,o=r?(r&&n?n+"-":"")+e:n[e];return{className:o,activeClassName:r?o+"-active":n[e+"Active"],doneClassName:r?o+"-done":n[e+"Done"]}},t}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=r.prototype;return o.removeClasses=function(e,t){var n=this.getClassNames(t),r=n.className,o=n.activeClassName,c=n.doneClassName;r&&u(e,r),o&&u(e,o),c&&u(e,c)},o.reflowAndAddClass=function(e,t){t&&(e&&e.scrollTop,s(e,t))},o.render=function(){var e=l({},this.props);return delete e.classNames,c.default.createElement(i.default,l({},e,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},r}(c.default.Component);d.defaultProps={classNames:""},d.propTypes={};var b=d;t.default=b,e.exports=t.default},function(e,t,n){"use strict";var r=n(309);t.__esModule=!0,t.default=function(e,t){e.classList?e.classList.add(t):(0,o.default)(e,t)||("string"==typeof e.className?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))};var o=r(n(310));e.exports=t.default},function(e,t){e.exports=function(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t){return e.classList?!!t&&e.classList.contains(t):-1!==(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")},e.exports=t.default},function(e,t,n){"use strict";function r(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}e.exports=function(e,t){e.classList?e.classList.remove(t):"string"==typeof e.className?e.className=r(e.className,t):e.setAttribute("class",r(e.className&&e.className.baseVal||"",t))}},function(e,t,n){"use strict";t.__esModule=!0,t.default=void 0;i(n(28));var r=i(n(13)),o=n(109),c=i(n(213));function i(e){return e&&e.__esModule?e:{default:e}}var a=function(e){var t,n;function i(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).handleEnter=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onEnter",0,n)},t.handleEntering=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onEntering",0,n)},t.handleEntered=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onEntered",0,n)},t.handleExit=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onExit",1,n)},t.handleExiting=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onExiting",1,n)},t.handleExited=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.handleLifecycle("onExited",1,n)},t}n=e,(t=i).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var a=i.prototype;return a.handleLifecycle=function(e,t,n){var c,i=this.props.children,a=r.default.Children.toArray(i)[t];a.props[e]&&(c=a.props)[e].apply(c,n),this.props[e]&&this.props[e]((0,o.findDOMNode)(this))},a.render=function(){var e=this.props,t=e.children,n=e.in,o=function(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,["children","in"]),i=r.default.Children.toArray(t),a=i[0],l=i[1];return delete o.onEnter,delete o.onEntering,delete o.onEntered,delete o.onExit,delete o.onExiting,delete o.onExited,r.default.createElement(c.default,o,n?r.default.cloneElement(a,{key:"first",onEnter:this.handleEnter,onEntering:this.handleEntering,onEntered:this.handleEntered}):r.default.cloneElement(l,{key:"second",onEnter:this.handleExit,onEntering:this.handleExiting,onEntered:this.handleExited}))},i}(r.default.Component);a.propTypes={};var l=a;t.default=l,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.getChildMapping=o,t.mergeChildMappings=c,t.getInitialChildMapping=function(e,t){return o(e.children,(function(n){return(0,r.cloneElement)(n,{onExited:t.bind(null,n),in:!0,appear:i(n,"appear",e),enter:i(n,"enter",e),exit:i(n,"exit",e)})}))},t.getNextChildMapping=function(e,t,n){var a=o(e.children),l=c(t,a);return Object.keys(l).forEach((function(o){var c=l[o];if((0,r.isValidElement)(c)){var s=o in t,u=o in a,d=t[o],b=(0,r.isValidElement)(d)&&!d.props.in;!u||s&&!b?u||!s||b?u&&s&&(0,r.isValidElement)(d)&&(l[o]=(0,r.cloneElement)(c,{onExited:n.bind(null,c),in:d.props.in,exit:i(c,"exit",e),enter:i(c,"enter",e)})):l[o]=(0,r.cloneElement)(c,{in:!1}):l[o]=(0,r.cloneElement)(c,{onExited:n.bind(null,c),in:!0,exit:i(c,"exit",e),enter:i(c,"enter",e)})}})),l};var r=n(13);function o(e,t){var n=Object.create(null);return e&&r.Children.map(e,(function(e){return e})).forEach((function(e){n[e.key]=function(e){return t&&(0,r.isValidElement)(e)?t(e):e}(e)})),n}function c(e,t){function n(n){return n in t?t[n]:e[n]}e=e||{},t=t||{};var r,o=Object.create(null),c=[];for(var i in e)i in t?c.length&&(o[i]=c,c=[]):c.push(i);var a={};for(var l in t){if(o[l])for(r=0;r<o[l].length;r++){var s=o[l][r];a[o[l][r]]=n(s)}a[l]=n(l)}for(r=0;r<c.length;r++)a[c[r]]=n(c[r]);return a}function i(e,t,n){return null!=n[t]?n[t]:e.props[t]}},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)(o.Path,{d:"M6.5 12.4L12 8l5.5 4.4-.9 1.2L12 10l-4.5 3.6-1-1.2z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)(o.Path,{d:"M17.5 11.6L12 16l-5.5-4.4.9-1.2L12 14l4.5-3.6 1 1.2z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"}));t.a=c},function(e,t,n){"use strict";function r(){}function o(e,t,n,r,o){for(var c=0,i=t.length,a=0,l=0;c<i;c++){var s=t[c];if(s.removed){if(s.value=e.join(r.slice(l,l+s.count)),l+=s.count,c&&t[c-1].added){var u=t[c-1];t[c-1]=t[c],t[c]=u}}else{if(!s.added&&o){var d=n.slice(a,a+s.count);d=d.map((function(e,t){var n=r[l+t];return n.length>e.length?n:e})),s.value=e.join(d)}else s.value=e.join(n.slice(a,a+s.count));a+=s.count,s.added||(l+=s.count)}}var b=t[i-1];return i>1&&"string"==typeof b.value&&(b.added||b.removed)&&e.equals("",b.value)&&(t[i-2].value+=b.value,t.pop()),t}function c(e){return{newPos:e.newPos,components:e.components.slice(0)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,r.prototype={diff:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.callback;"function"==typeof n&&(r=n,n={}),this.options=n;var i=this;function a(e){return r?(setTimeout((function(){r(void 0,e)}),0),!0):e}e=this.castInput(e),t=this.castInput(t),e=this.removeEmpty(this.tokenize(e));var l=(t=this.removeEmpty(this.tokenize(t))).length,s=e.length,u=1,d=l+s,b=[{newPos:-1,components:[]}],f=this.extractCommon(b[0],t,e,0);if(b[0].newPos+1>=l&&f+1>=s)return a([{value:this.join(t),count:t.length}]);function p(){for(var n=-1*u;n<=u;n+=2){var r=void 0,d=b[n-1],f=b[n+1],p=(f?f.newPos:0)-n;d&&(b[n-1]=void 0);var m=d&&d.newPos+1<l,v=f&&0<=p&&p<s;if(m||v){if(!m||v&&d.newPos<f.newPos?(r=c(f),i.pushComponent(r.components,void 0,!0)):((r=d).newPos++,i.pushComponent(r.components,!0,void 0)),p=i.extractCommon(r,t,e,n),r.newPos+1>=l&&p+1>=s)return a(o(i,r.components,t,e,i.useLongestToken));b[n]=r}else b[n]=void 0}u++}if(r)!function e(){setTimeout((function(){if(u>d)return r();p()||e()}),0)}();else for(;u<=d;){var m=p();if(m)return m}},pushComponent:function(e,t,n){var r=e[e.length-1];r&&r.added===t&&r.removed===n?e[e.length-1]={count:r.count+1,added:t,removed:n}:e.push({count:1,added:t,removed:n})},extractCommon:function(e,t,n,r){for(var o=t.length,c=n.length,i=e.newPos,a=i-r,l=0;i+1<o&&a+1<c&&this.equals(t[i+1],n[a+1]);)i++,a++,l++;return l&&e.components.push({count:l}),e.newPos=i,a},equals:function(e,t){return this.options.comparator?this.options.comparator(e,t):e===t||this.options.ignoreCase&&e.toLowerCase()===t.toLowerCase()},removeEmpty:function(e){for(var t=[],n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t},castInput:function(e){return e},tokenize:function(e){return e.split("")},join:function(e){return e.join("")}}},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(r.createElement)(o.Path,{d:"M2 2h5v11H2V2zm6 0h5v5H8V2zm6 0h4v16h-4V2zM8 8h5v5H8V8zm-6 6h11v4H2v-4z"}));t.a=c},function(e,t,n){"use strict";var r=n(0),o=n(7),c=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M18.7 3H5.3C4 3 3 4 3 5.3v13.4C3 20 4 21 5.3 21h13.4c1.3 0 2.3-1 2.3-2.3V5.3C21 4 20 3 18.7 3zm.8 15.7c0 .4-.4.8-.8.8H5.3c-.4 0-.8-.4-.8-.8V5.3c0-.4.4-.8.8-.8h13.4c.4 0 .8.4.8.8v13.4zM10 15l5-3-5-3v6z"}));t.a=c},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){"use strict";n.r(t),n.d(t,"__experimentalAlignmentHookSettingsProvider",(function(){return F})),n.d(t,"getColorClassName",(function(){return se})),n.d(t,"getColorObjectByAttributeValues",(function(){return ae})),n.d(t,"getColorObjectByColorValue",(function(){return le})),n.d(t,"createCustomColorsHOC",(function(){return nn})),n.d(t,"withColors",(function(){return rn})),n.d(t,"__experimentalUseColors",(function(){return jn})),n.d(t,"__experimentalGetGradientClass",(function(){return fe})),n.d(t,"getGradientValueBySlug",(function(){return pe})),n.d(t,"__experimentalGetGradientObjectByGradientValue",(function(){return me})),n.d(t,"getGradientSlugByValue",(function(){return ve})),n.d(t,"__experimentalUseGradient",(function(){return Oe})),n.d(t,"getFontSize",(function(){return Ot})),n.d(t,"getFontSizeClass",(function(){return ht})),n.d(t,"getFontSizeObjectByValue",(function(){return gt})),n.d(t,"FontSizePicker",(function(){return jt})),n.d(t,"withFontSizes",(function(){return Cn})),n.d(t,"AlignmentToolbar",(function(){return Nn})),n.d(t,"Autocomplete",(function(){return Xn})),n.d(t,"BlockAlignmentToolbar",(function(){return T})),n.d(t,"__experimentalBlockAlignmentMatrixToolbar",(function(){return Qn})),n.d(t,"BlockBreadcrumb",(function(){return Jn})),n.d(t,"BlockContextProvider",(function(){return rr})),n.d(t,"BlockControls",(function(){return O.a})),n.d(t,"BlockColorsStyleSelector",(function(){return ar})),n.d(t,"BlockEdit",(function(){return ur})),n.d(t,"useBlockEditContext",(function(){return z.b})),n.d(t,"BlockFormatControls",(function(){return mr})),n.d(t,"BlockIcon",(function(){return qn})),n.d(t,"BlockNavigationDropdown",(function(){return Zu})),n.d(t,"__experimentalBlockNavigationBlockFill",(function(){return Mu})),n.d(t,"__experimentalBlockNavigationEditor",(function(){return fd})),n.d(t,"__experimentalBlockNavigationTree",(function(){return $u})),n.d(t,"__experimentalBlockVariationPicker",(function(){return md})),n.d(t,"BlockVerticalAlignmentToolbar",(function(){return _d})),n.d(t,"ButtonBlockerAppender",(function(){return Qa})),n.d(t,"ColorPalette",(function(){return wd})),n.d(t,"ColorPaletteControl",(function(){return Id})),n.d(t,"ContrastChecker",(function(){return Ve})),n.d(t,"__experimentalGradientPicker",(function(){return Pd})),n.d(t,"__experimentalGradientPickerControl",(function(){return Td})),n.d(t,"__experimentalGradientPickerPanel",(function(){return Nd})),n.d(t,"__experimentalColorGradientControl",(function(){return Ie})),n.d(t,"__experimentalPanelColorGradientSettings",(function(){return Me})),n.d(t,"__experimentalImageSizeControl",(function(){return Rd})),n.d(t,"InnerBlocks",(function(){return $d})),n.d(t,"__experimentalUseInnerBlocksProps",(function(){return qd})),n.d(t,"InspectorAdvancedControls",(function(){return q})),n.d(t,"InspectorControls",(function(){return We})),n.d(t,"__experimentalLinkControl",(function(){return Ib})),n.d(t,"__experimentalLinkControlSearchInput",(function(){return kb})),n.d(t,"__experimentalLinkControlSearchResults",(function(){return ub})),n.d(t,"__experimentalLinkControlSearchItem",(function(){return sb})),n.d(t,"LineHeightControl",(function(){return ut})),n.d(t,"MediaReplaceFlow",(function(){return Nb})),n.d(t,"MediaPlaceholder",(function(){return Fb})),n.d(t,"MediaUpload",(function(){return Pb})),n.d(t,"MediaUploadCheck",(function(){return Tb})),n.d(t,"PanelColorSettings",(function(){return sn})),n.d(t,"PlainText",(function(){return zb})),n.d(t,"__experimentalResponsiveBlockControl",(function(){return Gb})),n.d(t,"RichText",(function(){return bd})),n.d(t,"RichTextShortcut",(function(){return Kb})),n.d(t,"RichTextToolbarButton",(function(){return Wb})),n.d(t,"__unstableRichTextInputEvent",(function(){return $b})),n.d(t,"ToolSelector",(function(){return Xb})),n.d(t,"__experimentalUnitControl",(function(){return xt})),n.d(t,"URLInput",(function(){return cb})),n.d(t,"URLInputButton",(function(){return ef})),n.d(t,"URLPopover",(function(){return Mb})),n.d(t,"__experimentalImageURLInputUI",(function(){return of})),n.d(t,"withColorContext",(function(){return Sd})),n.d(t,"__experimentalBlockSettingsMenuFirstItem",(function(){return Ks})),n.d(t,"__experimentalInserterMenuExtension",(function(){return Bl})),n.d(t,"__experimentalPreviewOptions",(function(){return af})),n.d(t,"__experimentalUseResizeCanvas",(function(){return pf})),n.d(t,"BlockInspector",(function(){return jf})),n.d(t,"BlockList",(function(){return fl})),n.d(t,"__experimentalBlock",(function(){return _u})),n.d(t,"useBlockProps",(function(){return ku})),n.d(t,"BlockMover",(function(){return js})),n.d(t,"BlockPreview",(function(){return vl})),n.d(t,"BlockSelectionClearer",(function(){return kf})),n.d(t,"BlockSettingsMenu",(function(){return eu})),n.d(t,"BlockSettingsMenuControls",(function(){return Qs})),n.d(t,"BlockTitle",(function(){return Zn})),n.d(t,"BlockToolbar",(function(){return iu})),n.d(t,"CopyHandler",(function(){return Ls})),n.d(t,"DefaultBlockAppender",(function(){return Xa})),n.d(t,"__unstableEditorStyles",(function(){return Wf})),n.d(t,"Inserter",(function(){return cs})),n.d(t,"__experimentalLibrary",(function(){return qf})),n.d(t,"__experimentalSearchForm",(function(){return bo})),n.d(t,"BlockEditorKeyboardShortcuts",(function(){return Yf})),n.d(t,"MultiSelectScrollIntoView",(function(){return Xf})),n.d(t,"NavigableToolbar",(function(){return vs})),n.d(t,"ObserveTyping",(function(){return Zf})),n.d(t,"PreserveScrollInReorder",(function(){return Jf})),n.d(t,"SkipToSelectedBlock",(function(){return mf})),n.d(t,"Typewriter",(function(){return op})),n.d(t,"Warning",(function(){return Hr})),n.d(t,"WritingFlow",(function(){return us})),n.d(t,"BlockEditorProvider",(function(){return $a})),n.d(t,"__experimentalUseSimulatedMediaQuery",(function(){return ff})),n.d(t,"__experimentalUseEditorFeature",(function(){return de})),n.d(t,"transformStyles",(function(){return Kf})),n.d(t,"validateThemeColors",(function(){return cp})),n.d(t,"validateThemeGradients",(function(){return ip})),n.d(t,"storeConfig",(function(){return Ka})),n.d(t,"SETTINGS_DEFAULTS",(function(){return mo}));var r={};n.r(r),n.d(r,"resetBlocks",(function(){return nc})),n.d(r,"resetSelection",(function(){return rc})),n.d(r,"receiveBlocks",(function(){return oc})),n.d(r,"updateBlockAttributes",(function(){return cc})),n.d(r,"updateBlock",(function(){return ic})),n.d(r,"selectBlock",(function(){return ac})),n.d(r,"selectPreviousBlock",(function(){return lc})),n.d(r,"selectNextBlock",(function(){return sc})),n.d(r,"startMultiSelect",(function(){return uc})),n.d(r,"stopMultiSelect",(function(){return dc})),n.d(r,"multiSelect",(function(){return bc})),n.d(r,"clearSelectedBlock",(function(){return fc})),n.d(r,"toggleSelection",(function(){return pc})),n.d(r,"replaceBlocks",(function(){return vc})),n.d(r,"replaceBlock",(function(){return Oc})),n.d(r,"moveBlocksDown",(function(){return hc})),n.d(r,"moveBlocksUp",(function(){return jc})),n.d(r,"moveBlocksToPosition",(function(){return kc})),n.d(r,"moveBlockToPosition",(function(){return yc})),n.d(r,"insertBlock",(function(){return _c})),n.d(r,"insertBlocks",(function(){return Ec})),n.d(r,"__unstableSetInsertionPoint",(function(){return Cc})),n.d(r,"showInsertionPoint",(function(){return Sc})),n.d(r,"hideInsertionPoint",(function(){return wc})),n.d(r,"setTemplateValidity",(function(){return Ic})),n.d(r,"synchronizeTemplate",(function(){return Bc})),n.d(r,"mergeBlocks",(function(){return xc})),n.d(r,"removeBlocks",(function(){return Pc})),n.d(r,"removeBlock",(function(){return Tc})),n.d(r,"replaceInnerBlocks",(function(){return Nc})),n.d(r,"toggleBlockMode",(function(){return Dc})),n.d(r,"startTyping",(function(){return Rc})),n.d(r,"stopTyping",(function(){return Ac})),n.d(r,"startDraggingBlocks",(function(){return Mc})),n.d(r,"stopDraggingBlocks",(function(){return Lc})),n.d(r,"enterFormattedText",(function(){return Fc})),n.d(r,"exitFormattedText",(function(){return Vc})),n.d(r,"selectionChange",(function(){return Hc})),n.d(r,"insertDefaultBlock",(function(){return zc})),n.d(r,"updateBlockListSettings",(function(){return Uc})),n.d(r,"updateSettings",(function(){return Gc})),n.d(r,"__unstableSaveReusableBlock",(function(){return Kc})),n.d(r,"__unstableMarkLastChangeAsPersistent",(function(){return Wc})),n.d(r,"__unstableMarkNextChangeAsNotPersistent",(function(){return qc})),n.d(r,"__unstableMarkAutomaticChange",(function(){return $c})),n.d(r,"setNavigationMode",(function(){return Yc})),n.d(r,"setBlockMovingClientId",(function(){return Xc})),n.d(r,"duplicateBlocks",(function(){return Qc})),n.d(r,"insertBeforeBlock",(function(){return Zc})),n.d(r,"insertAfterBlock",(function(){return Jc})),n.d(r,"toggleBlockHighlight",(function(){return ei})),n.d(r,"flashBlock",(function(){return ti})),n.d(r,"setHasControlledInnerBlocks",(function(){return ni}));var o={};n.r(o),n.d(o,"getBlockName",(function(){return ui})),n.d(o,"isBlockValid",(function(){return di})),n.d(o,"getBlockAttributes",(function(){return bi})),n.d(o,"getBlock",(function(){return fi})),n.d(o,"__unstableGetBlockWithoutInnerBlocks",(function(){return pi})),n.d(o,"getBlocks",(function(){return mi})),n.d(o,"__unstableGetBlockWithBlockTree",(function(){return vi})),n.d(o,"__unstableGetBlockTree",(function(){return Oi})),n.d(o,"getClientIdsOfDescendants",(function(){return gi})),n.d(o,"getClientIdsWithDescendants",(function(){return hi})),n.d(o,"getGlobalBlockCount",(function(){return ji})),n.d(o,"getBlocksByClientId",(function(){return ki})),n.d(o,"getBlockCount",(function(){return yi})),n.d(o,"getSelectionStart",(function(){return _i})),n.d(o,"getSelectionEnd",(function(){return Ei})),n.d(o,"getBlockSelectionStart",(function(){return Ci})),n.d(o,"getBlockSelectionEnd",(function(){return Si})),n.d(o,"getSelectedBlockCount",(function(){return wi})),n.d(o,"hasSelectedBlock",(function(){return Ii})),n.d(o,"getSelectedBlockClientId",(function(){return Bi})),n.d(o,"getSelectedBlock",(function(){return xi})),n.d(o,"getBlockRootClientId",(function(){return Pi})),n.d(o,"getBlockParents",(function(){return Ti})),n.d(o,"getBlockParentsByBlockName",(function(){return Ni})),n.d(o,"getBlockHierarchyRootClientId",(function(){return Di})),n.d(o,"getLowestCommonAncestorWithSelectedBlock",(function(){return Ri})),n.d(o,"getAdjacentBlockClientId",(function(){return Ai})),n.d(o,"getPreviousBlockClientId",(function(){return Mi})),n.d(o,"getNextBlockClientId",(function(){return Li})),n.d(o,"getSelectedBlocksInitialCaretPosition",(function(){return Fi})),n.d(o,"getSelectedBlockClientIds",(function(){return Vi})),n.d(o,"getMultiSelectedBlockClientIds",(function(){return Hi})),n.d(o,"getMultiSelectedBlocks",(function(){return zi})),n.d(o,"getFirstMultiSelectedBlockClientId",(function(){return Ui})),n.d(o,"getLastMultiSelectedBlockClientId",(function(){return Gi})),n.d(o,"isFirstMultiSelectedBlock",(function(){return Ki})),n.d(o,"isBlockMultiSelected",(function(){return Wi})),n.d(o,"isAncestorMultiSelected",(function(){return qi})),n.d(o,"getMultiSelectedBlocksStartClientId",(function(){return $i})),n.d(o,"getMultiSelectedBlocksEndClientId",(function(){return Yi})),n.d(o,"getBlockOrder",(function(){return Xi})),n.d(o,"getBlockIndex",(function(){return Qi})),n.d(o,"isBlockSelected",(function(){return Zi})),n.d(o,"hasSelectedInnerBlock",(function(){return Ji})),n.d(o,"isBlockWithinSelection",(function(){return ea})),n.d(o,"hasMultiSelection",(function(){return ta})),n.d(o,"isMultiSelecting",(function(){return na})),n.d(o,"isSelectionEnabled",(function(){return ra})),n.d(o,"getBlockMode",(function(){return oa})),n.d(o,"isTyping",(function(){return ca})),n.d(o,"isDraggingBlocks",(function(){return ia})),n.d(o,"getDraggedBlockClientIds",(function(){return aa})),n.d(o,"isBlockBeingDragged",(function(){return la})),n.d(o,"isAncestorBeingDragged",(function(){return sa})),n.d(o,"isCaretWithinFormattedText",(function(){return ua})),n.d(o,"getBlockInsertionPoint",(function(){return da})),n.d(o,"isBlockInsertionPointVisible",(function(){return ba})),n.d(o,"isValidTemplate",(function(){return fa})),n.d(o,"getTemplate",(function(){return pa})),n.d(o,"getTemplateLock",(function(){return ma})),n.d(o,"canInsertBlockType",(function(){return Oa})),n.d(o,"canInsertBlocks",(function(){return ga})),n.d(o,"getInserterItems",(function(){return ya})),n.d(o,"hasInserterItems",(function(){return _a})),n.d(o,"__experimentalGetAllowedBlocks",(function(){return Ea})),n.d(o,"getBlockListSettings",(function(){return Ca})),n.d(o,"getSettings",(function(){return Sa})),n.d(o,"isLastBlockChangePersistent",(function(){return wa})),n.d(o,"__experimentalGetBlockListSettingsForBlocks",(function(){return Ia})),n.d(o,"__experimentalGetParsedReusableBlock",(function(){return Ba})),n.d(o,"__unstableIsLastBlockChangeIgnored",(function(){return xa})),n.d(o,"__experimentalGetLastBlockAttributeChanges",(function(){return Pa})),n.d(o,"isNavigationMode",(function(){return Na})),n.d(o,"hasBlockMovingClientId",(function(){return Da})),n.d(o,"didAutomaticChange",(function(){return Ra})),n.d(o,"isBlockHighlighted",(function(){return Aa})),n.d(o,"areInnerBlocksControlled",(function(){return Ma})),n.d(o,"__experimentalGetActiveBlockIdByBlockNames",(function(){return La}));var c=n(11),i=n(25),a=(n(101),n(53)),l=(n(92),n(8)),s=n(5),u=n(0),d=n(9),b=n.n(d),f=n(2),p=n(10),m=n(33),v=n(4),O=n(133),g=n(1),h=n(3),j=n(7),k=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(j.Path,{d:"M4 9v6h14V9H4zm8-4.8H4v1.5h8V4.2zM4 19.8h8v-1.5H4v1.5z"})),y=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(j.Path,{d:"M5 15h14V9H5v6zm0 4.8h14v-1.5H5v1.5zM5 4.2v1.5h14V4.2H5z"})),_=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(j.Path,{d:"M6 15h14V9H6v6zm6-10.8v1.5h8V4.2h-8zm0 15.6h8v-1.5h-8v1.5z"})),E=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(j.Path,{d:"M5 9v6h14V9H5zm11-4.8H8v1.5h8V4.2zM8 19.8h8v-1.5H8v1.5z"})),C=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(j.Path,{d:"M5 4v11h14V4H5zm3 15.8h8v-1.5H8v1.5z"}));function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?S(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var I={left:{icon:k,title:Object(g.__)("Align left")},center:{icon:y,title:Object(g.__)("Align center")},right:{icon:_,title:Object(g.__)("Align right")},wide:{icon:E,title:Object(g.__)("Wide width")},full:{icon:C,title:Object(g.__)("Full width")}},B=["left","center","right","wide","full"],x=["wide","full"],P={isAlternate:!0};var T=Object(p.compose)(Object(v.withSelect)((function(e){return{wideControlsEnabled:(0,e("core/block-editor").getSettings)().alignWide}})))((function(e){var t=e.value,n=e.onChange,r=e.controls,o=void 0===r?B:r,c=e.isCollapsed,i=void 0===c||c,a=e.wideControlsEnabled,l=void 0!==a&&a?o:o.filter((function(e){return-1===x.indexOf(e)})),s=I[t],d=I.center;return Object(u.createElement)(h.ToolbarGroup,{popoverProps:P,isCollapsed:i,icon:s?s.icon:d.icon,label:Object(g.__)("Change alignment"),controls:l.map((function(e){return w(w({},I[e]),{},{isActive:t===e,role:i?"menuitemradio":void 0,onClick:(r=e,function(){return n(t===r?void 0:r)})});var r}))})}));function N(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function D(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?N(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):N(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var R=["left","center","right","wide","full"],A=["wide","full"];function M(e){var t,n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return t=Array.isArray(e)?e:!0===e?R:[],!r||!0===e&&!n?f.without.apply(void 0,[t].concat(A)):t}var L=Object(u.createContext)({}),F=L.Provider,V=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=Object(u.useContext)(L).isEmbedButton,r=t.name,o=n?[]:M(Object(c.getBlockSupport)(r,"align"),Object(c.hasBlockSupport)(r,"alignWide",!0));return[o.length>0&&t.isSelected&&Object(u.createElement)(O.a,{key:"align-controls"},Object(u.createElement)(T,{value:t.attributes.align,onChange:function(e){var n,r;e||(null===(n=Object(c.getBlockType)(t.name).attributes)||void 0===n||null===(r=n.align)||void 0===r?void 0:r.default)&&(e="");t.setAttributes({align:e})},controls:o})),Object(u.createElement)(e,Object(l.a)({key:"edit"},t))]}}),"withToolbarControls"),H=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=t.name,r=t.attributes.align,o=Object(v.useSelect)((function(e){return!!e("core/block-editor").getSettings().alignWide}),[]);if(void 0===r)return Object(u.createElement)(e,t);var i=M(Object(c.getBlockSupport)(n,"align"),Object(c.hasBlockSupport)(n,"alignWide",!0),o),a=t.wrapperProps;return i.includes(r)&&(a=D(D({},a),{},{"data-align":r})),Object(u.createElement)(e,Object(l.a)({},t,{wrapperProps:a}))}}));Object(m.addFilter)("blocks.registerBlockType","core/align/addAttribute",(function(e){return Object(f.has)(e.attributes,["align","type"])||Object(c.hasBlockSupport)(e,"align")&&(e.attributes=D(D({},e.attributes),{},{align:{type:"string",enum:[].concat(R,[""])}})),e})),Object(m.addFilter)("editor.BlockListBlock","core/editor/align/with-data-align",H),Object(m.addFilter)("editor.BlockEdit","core/editor/align/with-toolbar-controls",V),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/align/addAssignedAlign",(function(e,t,n){var r=n.align;return M(Object(c.getBlockSupport)(t,"align"),Object(c.hasBlockSupport)(t,"alignWide",!0)).includes(r)&&(e.className=b()("align".concat(r),e.className)),e}));var z=n(80),U=Object(h.createSlotFill)("InspectorAdvancedControls"),G=U.Fill,K=U.Slot;function W(e){var t=e.children;return Object(z.b)().isSelected?Object(u.createElement)(G,null,t):null}W.slotName="InspectorAdvancedControls",W.Slot=K;var q=W;function $(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Y(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var X=/[\s#]/g;var Q=Object(p.createHigherOrderComponent)((function(e){return function(t){return Object(c.hasBlockSupport)(t.name,"anchor")&&t.isSelected?Object(u.createElement)(u.Fragment,null,Object(u.createElement)(e,t),Object(u.createElement)(q,null,Object(u.createElement)(h.TextControl,{className:"html-anchor-control",label:Object(g.__)("HTML anchor"),help:Object(u.createElement)(u.Fragment,null,Object(g.__)("Enter a word or two — without spaces — to make a unique web address just for this heading, called an “anchor.” Then, you’ll be able to link directly to this section of your page."),Object(u.createElement)(h.ExternalLink,{href:"https://wordpress.org/support/article/page-jumps/"},Object(g.__)("Learn more about anchors"))),value:t.attributes.anchor||"",onChange:function(e){e=e.replace(X,"-"),t.setAttributes({anchor:e})},autoComplete:"off"}))):Object(u.createElement)(e,t)}}),"withInspectorControl");function Z(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function J(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Z(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Z(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}Object(m.addFilter)("blocks.registerBlockType","core/anchor/attribute",(function(e){return Object(f.has)(e.attributes,["anchor","type"])||Object(c.hasBlockSupport)(e,"anchor")&&(e.attributes=Y(Y({},e.attributes),{},{anchor:{type:"string",source:"attribute",attribute:"id",selector:"*"}})),e})),Object(m.addFilter)("editor.BlockEdit","core/editor/anchor/with-inspector-control",Q),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/anchor/save-props",(function(e,t,n){return Object(c.hasBlockSupport)(t,"anchor")&&(e.id=""===n.anchor?null:n.anchor),e}));var ee=Object(p.createHigherOrderComponent)((function(e){return function(t){return Object(c.hasBlockSupport)(t.name,"customClassName",!0)&&t.isSelected?Object(u.createElement)(u.Fragment,null,Object(u.createElement)(e,t),Object(u.createElement)(q,null,Object(u.createElement)(h.TextControl,{autoComplete:"off",label:Object(g.__)("Additional CSS class(es)"),value:t.attributes.className||"",onChange:function(e){t.setAttributes({className:""!==e?e:void 0})},help:Object(g.__)("Separate multiple classes with spaces.")}))):Object(u.createElement)(e,t)}}),"withInspectorControl");function te(e){e="<div data-custom-class-name>".concat(e,"</div>");var t=Object(c.parseWithAttributeSchema)(e,{type:"string",source:"attribute",selector:"[data-custom-class-name] > *",attribute:"class"});return t?t.trim().split(/\s+/):[]}Object(m.addFilter)("blocks.registerBlockType","core/custom-class-name/attribute",(function(e){return Object(c.hasBlockSupport)(e,"customClassName",!0)&&(e.attributes=J(J({},e.attributes),{},{className:{type:"string"}})),e})),Object(m.addFilter)("editor.BlockEdit","core/editor/custom-class-name/with-inspector-control",ee),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/custom-class-name/save-props",(function(e,t,n){return Object(c.hasBlockSupport)(t,"customClassName",!0)&&n.className&&(e.className=b()(e.className,n.className)),e})),Object(m.addFilter)("blocks.getBlockAttributes","core/custom-class-name/addParsedDifference",(function(e,t,n){if(Object(c.hasBlockSupport)(t,"customClassName",!0)){var r=Object(f.omit)(e,["className"]),o=Object(c.getSaveContent)(t,r),i=te(o),a=te(n),l=Object(f.difference)(a,i);l.length?e.className=l.join(" "):o&&delete e.className}return e}));var ne=n(17);Object(m.addFilter)("blocks.getSaveContent.extraProps","core/generated-class-name/save-props",(function(e,t){return Object(c.hasBlockSupport)(t,"className",!0)&&("string"==typeof e.className?e.className=Object(f.uniq)([Object(c.getBlockDefaultClassName)(t.name)].concat(Object(ne.a)(e.className.split(" ")))).join(" ").trim():e.className=Object(c.getBlockDefaultClassName)(t.name)),e}));var re=n(12),oe=n(149),ce=n(66),ie=n.n(ce),ae=function(e,t,n){if(t){var r=Object(f.find)(e,{slug:t});if(r)return r}return{color:n}},le=function(e,t){return Object(f.find)(e,{color:t})};function se(e,t){if(e&&t)return"has-".concat(Object(f.kebabCase)(t),"-").concat(e)}var ue={"color.palette":function(e){return void 0===e.colors?void 0:e.colors},"color.gradients":function(e){return void 0===e.gradients?void 0:e.gradients},"color.custom":function(e){return void 0===e.disableCustomColors?void 0:!e.disableCustomColors},"color.customGradient":function(e){return void 0===e.disableCustomGradients?void 0:!e.disableCustomGradients},"typography.fontSizes":function(e){return void 0===e.fontSizes?void 0:e.fontSizes},"typography.customFontSize":function(e){return void 0===e.disableCustomFontSizes?void 0:!e.disableCustomFontSizes},"typography.customLineHeight":function(e){return e.enableCustomLineHeight},"spacing.units":function(e){if(void 0!==e.enableCustomUnits)return!0===e.enableCustomUnits?["px","em","rem","vh","vw"]:e.enableCustomUnits}};function de(e){var t=Object(z.b)().name;return Object(v.useSelect)((function(n){var r,o=n("core/block-editor").getSettings(),c="__experimentalFeatures.global.".concat(e),i="__experimentalFeatures.".concat(t,".").concat(e),a=null!==(r=Object(f.get)(o,i))&&void 0!==r?r:Object(f.get)(o,c);if(void 0!==a)return a;var l=ue[e]?ue[e](o):void 0;return void 0!==l?l:"typography.dropCap"===e||void 0}),[t,e])}var be=[];function fe(e){if(e)return"has-".concat(e,"-gradient-background")}function pe(e,t){var n=Object(f.find)(e,["slug",t]);return n&&n.gradient}function me(e,t){return Object(f.find)(e,["gradient",t])}function ve(e,t){var n=me(e,t);return n&&n.slug}function Oe(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.gradientAttribute,n=void 0===t?"gradient":t,r=e.customGradientAttribute,o=void 0===r?"customGradient":r,c=Object(z.b)(),i=c.clientId,a=de("color.gradients")||be,l=Object(v.useSelect)((function(e){var t=(0,e("core/block-editor").getBlockAttributes)(i);return{customGradient:t[o],gradient:t[n]}}),[i,n,o]),d=l.gradient,b=l.customGradient,f=Object(v.useDispatch)("core/block-editor"),p=f.updateBlockAttributes,m=Object(u.useCallback)((function(e){var t,r,c=ve(a,e);c?p(i,(r={},Object(s.a)(r,n,c),Object(s.a)(r,o,void 0),r)):p(i,(t={},Object(s.a)(t,n,void 0),Object(s.a)(t,o,e),t))}),[a,i,p]),O=fe(d);return{gradientClass:O,gradientValue:d?pe(a,d):b,setGradient:m}}var ge=function e(t){if(!Object(f.isObject)(t))return t;var n=Object(f.pickBy)(Object(f.mapValues)(t,e),f.identity);return Object(f.isEqual)(n,{})?void 0:n},he=n(14);function je(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ke(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?je(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):je(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ye=Object(g.__)("(Color: %s)"),_e=Object(g.__)("(Gradient: %s)"),Ee=["colors","disableCustomColors","gradients","disableCustomGradients"];function Ce(e){var t,n,r=e.colors,o=e.gradients,c=e.label,i=e.currentTab,a=e.colorValue,l=e.gradientValue;if("color"===i){if(a){var s=le(r,t=a),d=s&&s.name;n=Object(g.sprintf)(ye,d||t)}}else if("gradient"===i&&l){var b=me(o,t=l),f=b&&b.name;n=Object(g.sprintf)(_e,f||t)}return Object(u.createElement)(u.Fragment,null,c,!!t&&Object(u.createElement)(h.ColorIndicator,{colorValue:t,"aria-label":n}))}function Se(e){var t=e.colors,n=e.gradients,r=e.disableCustomColors,o=e.disableCustomGradients,c=e.className,i=e.label,a=e.onColorChange,s=e.onGradientChange,d=e.colorValue,p=e.gradientValue,m=a&&(!Object(f.isEmpty)(t)||!r),v=s&&(!Object(f.isEmpty)(n)||!o),O=Object(u.useState)(p?"gradient":!!m&&"color"),j=Object(re.a)(O,2),k=j[0],y=j[1];return m||v?Object(u.createElement)(h.BaseControl,{className:b()("block-editor-color-gradient-control",c)},Object(u.createElement)("fieldset",null,Object(u.createElement)("legend",null,Object(u.createElement)("div",{className:"block-editor-color-gradient-control__color-indicator"},Object(u.createElement)(h.BaseControl.VisualLabel,null,Object(u.createElement)(Ce,{currentTab:k,label:i,colorValue:d,gradientValue:p})))),m&&v&&Object(u.createElement)(h.ButtonGroup,{className:"block-editor-color-gradient-control__button-tabs"},Object(u.createElement)(h.Button,{isSmall:!0,isPressed:"color"===k,onClick:function(){return y("color")}},Object(g.__)("Solid")),Object(u.createElement)(h.Button,{isSmall:!0,isPressed:"gradient"===k,onClick:function(){return y("gradient")}},Object(g.__)("Gradient"))),("color"===k||!v)&&Object(u.createElement)(h.ColorPalette,Object(l.a)({value:d,onChange:v?function(e){a(e),s()}:a},{colors:t,disableCustomColors:r})),("gradient"===k||!m)&&Object(u.createElement)(h.__experimentalGradientPicker,Object(l.a)({value:p,onChange:m?function(e){s(e),a()}:s},{gradients:n,disableCustomGradients:o})))):null}function we(e){var t={};return t.colors=de("color.palette"),t.gradients=de("color.gradients"),t.disableCustomColors=!de("color.custom"),t.disableCustomGradients=!de("color.customGradient"),Object(u.createElement)(Se,ke(ke({},t),e))}var Ie=function(e){return Object(f.every)(Ee,(function(t){return e.hasOwnProperty(t)}))?Object(u.createElement)(Se,e):Object(u.createElement)(we,e)};function Be(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function xe(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Be(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Be(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Pe=Object(g.__)("(%s: color %s)"),Te=Object(g.__)("(%s: gradient %s)"),Ne=["colors","disableCustomColors","gradients","disableCustomGradients"],De=function(e){var t=e.colors,n=e.gradients;return e.settings.map((function(e,r){var o,c=e.colorValue,i=e.gradientValue,a=e.label,l=e.colors,s=e.gradients;if(!c&&!i)return null;if(c){var d=le(l||t,c);o=Object(g.sprintf)(Pe,a.toLowerCase(),d&&d.name||c)}else{var b=me(s||n,c);o=Object(g.sprintf)(Te,a.toLowerCase(),b&&b.name||i)}return Object(u.createElement)(h.ColorIndicator,{key:r,colorValue:c||i,"aria-label":o})}))},Re=function(e){var t=e.className,n=e.colors,r=e.gradients,o=e.disableCustomColors,c=e.disableCustomGradients,i=e.children,a=e.settings,s=e.title,d=Object(he.a)(e,["className","colors","gradients","disableCustomColors","disableCustomGradients","children","settings","title"]);if(Object(f.isEmpty)(n)&&Object(f.isEmpty)(r)&&o&&c&&Object(f.every)(a,(function(e){return Object(f.isEmpty)(e.colors)&&Object(f.isEmpty)(e.gradients)&&(void 0===e.disableCustomColors||e.disableCustomColors)&&(void 0===e.disableCustomGradients||e.disableCustomGradients)})))return null;var p=Object(u.createElement)("span",{className:"block-editor-panel-color-gradient-settings__panel-title"},s,Object(u.createElement)(De,{colors:n,gradients:r,settings:a}));return Object(u.createElement)(h.PanelBody,Object(l.a)({className:b()("block-editor-panel-color-gradient-settings",t),title:p},d),a.map((function(e,t){return Object(u.createElement)(Ie,Object(l.a)({key:t},xe({colors:n,gradients:r,disableCustomColors:o,disableCustomGradients:c},e)))})),i)},Ae=function(e){var t={};return t.colors=de("color.palette"),t.gradients=de("color.gradients"),t.disableCustomColors=!de("color.custom"),t.disableCustomGradients=!de("color.customGradient"),Object(u.createElement)(Re,xe(xe({},t),e))},Me=function(e){return Object(f.every)(Ne,(function(t){return e.hasOwnProperty(t)}))?Object(u.createElement)(Re,e):Object(u.createElement)(Ae,e)},Le=n(46);function Fe(e){var t=e.tinyBackgroundColor,n=e.tinyTextColor,r=e.backgroundColor,o=e.textColor,c=t.getBrightness()<n.getBrightness()?Object(g.__)("This color combination may be hard for people to read. Try using a darker background color and/or a brighter text color."):Object(g.__)("This color combination may be hard for people to read. Try using a brighter background color and/or a darker text color.");return Object(u.useEffect)((function(){Object(Le.speak)(Object(g.__)("This color combination may be hard for people to read."))}),[r,o]),Object(u.createElement)("div",{className:"block-editor-contrast-checker"},Object(u.createElement)(h.Notice,{spokenMessage:null,status:"warning",isDismissible:!1},c))}var Ve=function(e){var t=e.backgroundColor,n=e.fallbackBackgroundColor,r=e.fallbackTextColor,o=e.fontSize,c=e.isLargeText,i=e.textColor;if(!t&&!n||!i&&!r)return null;var a=ie()(t||n),l=ie()(i||r);return 1!==a.getAlpha()||1!==l.getAlpha()||ie.a.isReadable(a,l,{level:"AA",size:c||!1!==c&&o>=24?"large":"small"})?null:Object(u.createElement)(Fe,{backgroundColor:t,textColor:i,tinyBackgroundColor:a,tinyTextColor:l})},He=n(170),ze=Object(h.createSlotFill)("InspectorControls"),Ue=ze.Fill,Ge=ze.Slot;function Ke(e){var t=e.children;return Object(He.a)()?Object(u.createElement)(Ue,null,t):null}Ke.Slot=Ge;var We=Ke;function qe(e){return document.getElementById("block-"+e)}function $e(e,t){return t.closest(".block-editor-block-list__block")===e}function Ye(e){for(;e&&e.nodeType!==e.ELEMENT_NODE;)e=e.parentNode;if(e){var t=e.closest(".block-editor-block-list__block");if(t)return t.id.slice("block-".length)}}function Xe(e){return e.ownerDocument.defaultView.getComputedStyle(e)}function Qe(e){var t=e.settings,n=e.clientId,r=e.enableContrastChecking,o=void 0===r||r,c=Object(u.useState)(),i=Object(re.a)(c,2),a=i[0],l=i[1],s=Object(u.useState)(),d=Object(re.a)(s,2),b=d[0],f=d[1];return Object(u.useEffect)((function(){if(o){var e=qe(n);if(e){f(Xe(e).color);for(var t=e,r=Xe(t).backgroundColor;"rgba(0, 0, 0, 0)"===r&&t.parentNode&&t.parentNode.nodeType===t.parentNode.ELEMENT_NODE;)r=Xe(t=t.parentNode).backgroundColor;l(r)}}})),Object(u.createElement)(We,null,Object(u.createElement)(Me,{title:Object(g.__)("Color settings"),initialOpen:!1,settings:t},o&&Object(u.createElement)(Ve,{backgroundColor:a,textColor:b})))}function Ze(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Je(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ze(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ze(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var et=[],tt=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return t&&(!0===t.link||!0===t.gradient||!1!==t.background||!1!==t.text)},nt=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return Object(f.isObject)(t)&&!!t.link},rt=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return Object(f.isObject)(t)&&!!t.gradients},ot=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return t&&!1!==t.text};function ct(e,t,n){var r,o,c,i,a,l;if(!tt(t))return e;var u=rt(t),d=n.backgroundColor,f=n.textColor,p=n.gradient,m=n.style,v=se("background-color",d),O=fe(p),g=se("color",f),h=b()(e.className,g,O,(l={},Object(s.a)(l,v,!(u&&(null==m||null===(r=m.color)||void 0===r?void 0:r.gradient)||!v)),Object(s.a)(l,"has-text-color",f||(null==m||null===(o=m.color)||void 0===o?void 0:o.text)),Object(s.a)(l,"has-background",d||(null==m||null===(c=m.color)||void 0===c?void 0:c.background)||u&&(p||(null==m||null===(i=m.color)||void 0===i?void 0:i.gradient))),Object(s.a)(l,"has-link-color",null==m||null===(a=m.color)||void 0===a?void 0:a.link),l));return e.className=h||void 0,e}var it=function(e,t){var n=/var:preset\|color\|(.+)/.exec(t);return n&&n[1]?ae(e,n[1]).color:t};function at(e){var t,n,r,o,i,a,l=e.name,d=e.attributes,b=de("color.link"),f=de("color.palette")||et,p=de("color.gradients")||et,m=Object(u.useRef)(d);if(Object(u.useEffect)((function(){m.current=d}),[d]),!tt(l))return null;var v,O=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return t&&!1!==t.background}(l),h=rt(l),j=d.style,k=d.textColor,y=d.backgroundColor,_=d.gradient;if(h&&_)v=pe(p,_);else if(h){var E;v=null==j||null===(E=j.color)||void 0===E?void 0:E.gradient}var C=function(t){return function(n){var r,o,c=le(f,n),i=t+"Color",a=Je(Je({},m.current.style),{},{color:Je(Je({},null===(r=m.current)||void 0===r||null===(o=r.style)||void 0===o?void 0:o.color),{},Object(s.a)({},t,(null==c?void 0:c.slug)?void 0:n))}),l=(null==c?void 0:c.slug)?c.slug:void 0,u=Object(s.a)({style:ge(a)},i,l);e.setAttributes(u),m.current=Je(Je({},m.current),u)}};return Object(u.createElement)(Qe,{enableContrastChecking:"web"===u.Platform.OS&&!_&&!(null==j||null===(t=j.color)||void 0===t?void 0:t.gradient),clientId:e.clientId,settings:[].concat(Object(ne.a)(ot(l)?[{label:Object(g.__)("Text Color"),onColorChange:C("text"),colorValue:ae(f,k,null==j||null===(n=j.color)||void 0===n?void 0:n.text).color}]:[]),Object(ne.a)(O||h?[{label:Object(g.__)("Background Color"),onColorChange:O?C("background"):void 0,colorValue:ae(f,y,null==j||null===(r=j.color)||void 0===r?void 0:r.background).color,gradientValue:v,onGradientChange:h?function(t){var n,r=ve(p,t);if(r){var o,c,i,a=Je(Je({},null===(o=m.current)||void 0===o?void 0:o.style),{},{color:Je(Je({},null===(c=m.current)||void 0===c||null===(i=c.style)||void 0===i?void 0:i.color),{},{gradient:void 0})});n={style:ge(a),gradient:r}}else{var l,s,u,d=Je(Je({},null===(l=m.current)||void 0===l?void 0:l.style),{},{color:Je(Je({},null===(s=m.current)||void 0===s||null===(u=s.style)||void 0===u?void 0:u.color),{},{gradient:t})});n={style:ge(d),gradient:void 0}}e.setAttributes(n),m.current=Je(Je({},m.current),n)}:void 0}]:[]),Object(ne.a)(b&&nt(l)?[{label:Object(g.__)("Link Color"),onColorChange:function(t){var n,r=le(f,t);e.setAttributes({style:Je(Je({},e.attributes.style),{},{color:Je(Je({},null===(n=e.attributes.style)||void 0===n?void 0:n.color),{},{link:(null==r?void 0:r.slug)?"var:preset|color|".concat(r.slug):t})})})},colorValue:it(f,null==j||null===(o=j.color)||void 0===o?void 0:o.link),clearable:!!(null===(i=e.attributes.style)||void 0===i||null===(a=i.color)||void 0===a?void 0:a.link)}]:[]))})}var lt=Object(p.createHigherOrderComponent)((function(e){return function(t){var n,r,o,c=t.name,i=t.attributes,a=i.backgroundColor,s=i.textColor,d=de("color.palette")||et;if(!tt(c))return Object(u.createElement)(e,t);var b={color:s?null===(n=ae(d,s))||void 0===n?void 0:n.color:void 0,backgroundColor:a?null===(r=ae(d,a))||void 0===r?void 0:r.color:void 0},f=t.wrapperProps;return f=Je(Je({},t.wrapperProps),{},{style:Je(Je({},b),null===(o=t.wrapperProps)||void 0===o?void 0:o.style)}),Object(u.createElement)(e,Object(l.a)({},t,{wrapperProps:f}))}}));Object(m.addFilter)("blocks.registerBlockType","core/color/addAttribute",(function(e){return tt(e)?(e.attributes.backgroundColor||Object.assign(e.attributes,{backgroundColor:{type:"string"}}),e.attributes.textColor||Object.assign(e.attributes,{textColor:{type:"string"}}),rt(e)&&!e.attributes.gradient&&Object.assign(e.attributes,{gradient:{type:"string"}}),e):e})),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/color/addSaveProps",ct),Object(m.addFilter)("blocks.registerBlockType","core/color/addEditProps",(function(e){if(!tt(e))return e;var t=e.getEditWrapperProps;return e.getEditWrapperProps=function(n){var r={};return t&&(r=t(n)),ct(r,e,n)},e})),Object(m.addFilter)("editor.BlockListBlock","core/color/with-color-palette-styles",lt);var st=n(18);function ut(e){var t=e.value,n=e.onChange,r=function(e){return void 0!==e&&""!==e}(t),o=r?t:"";return Object(u.createElement)("div",{className:"block-editor-line-height-control"},Object(u.createElement)(h.TextControl,{autoComplete:"off",onKeyDown:function(e){e.keyCode!==st.ZERO||r||(e.preventDefault(),n("0"))},onChange:function(e){if(r)n(e);else{var t=e;switch(e){case"".concat(.1):t=1.6;break;case"0":t=1.4}n(t)}},label:Object(g.__)("Line height"),placeholder:1.5,step:.1,type:"number",value:o,min:0}))}function dt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function bt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?dt(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ft(e){var t,n=e.attributes.style;if(pt(e))return null;return Object(u.createElement)(ut,{value:null==n||null===(t=n.typography)||void 0===t?void 0:t.lineHeight,onChange:function(t){var r=bt(bt({},n),{},{typography:bt(bt({},null==n?void 0:n.typography),{},{lineHeight:t})});e.setAttributes({style:ge(r)})}})}function pt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=!de("typography.customLineHeight");return!Object(c.hasBlockSupport)(t,"lineHeight")||n}var mt=n(157),vt=n.n(mt),Ot=function(e,t,n){if(t){var r=Object(f.find)(e,{slug:t});if(r)return r}return{size:n}};function gt(e,t){var n=Object(f.find)(e,{size:t});return n||{size:t}}function ht(e){if(e)return"has-".concat(Object(f.kebabCase)(e),"-font-size")}var jt=function(e){var t=de("typography.fontSizes"),n=!de("typography.customFontSize");return Object(u.createElement)(h.FontSizePicker,Object(l.a)({},e,{fontSizes:t,disableCustomFontSizes:n}))};function kt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function yt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?kt(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function _t(e,t,n){if(!Object(c.hasBlockSupport)(t,"fontSize"))return e;var r=new vt.a(e.className);r.add(ht(n.fontSize));var o=r.value;return e.className=o||void 0,e}function Et(e){var t,n=e.attributes,r=n.fontSize,o=n.style,c=e.setAttributes,i=Ct(e),a=de("typography.fontSizes");if(i)return null;var l=Ot(a,r,null==o||null===(t=o.typography)||void 0===t?void 0:t.fontSize);return Object(u.createElement)(jt,{value:l.size,onChange:function(e){var t=gt(a,e).slug;c({style:ge(yt(yt({},o),{},{typography:yt(yt({},null==o?void 0:o.typography),{},{fontSize:t?void 0:e})})),fontSize:t})}})}function Ct(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=de("typography.fontSizes"),r=!!(null==n?void 0:n.length);return!Object(c.hasBlockSupport)(t,"fontSize")||!r}var St=Object(p.createHigherOrderComponent)((function(e){return function(t){var n,r=de("typography.fontSizes"),o=t.name,i=t.attributes,a=i.fontSize,l=i.style,s=t.wrapperProps,d=yt({},t);if(Object(c.hasBlockSupport)(o,"fontSize")&&a&&!(null==l||null===(n=l.typography)||void 0===n?void 0:n.fontSize)){var b,f=Ot(r,a,null==l||null===(b=l.typography)||void 0===b?void 0:b.fontSize).size;d.wrapperProps=yt(yt({},s),{},{style:yt({fontSize:f},null==s?void 0:s.style)})}return Object(u.createElement)(e,d)}}),"withFontSizeInlineStyles");Object(m.addFilter)("blocks.registerBlockType","core/font/addAttribute",(function(e){return Object(c.hasBlockSupport)(e,"fontSize")?(e.attributes.fontSize||Object.assign(e.attributes,{fontSize:{type:"string"}}),e):e})),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/font/addSaveProps",_t),Object(m.addFilter)("blocks.registerBlockType","core/font/addEditProps",(function(e){if(!Object(c.hasBlockSupport)(e,"fontSize"))return e;var t=e.getEditWrapperProps;return e.getEditWrapperProps=function(n){var r={};return t&&(r=t(n)),_t(r,e,n)},e})),Object(m.addFilter)("editor.BlockListBlock","core/font-size/with-font-size-inline-styles",St);var wt=["lineHeight","fontSize"];function It(e){var t=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=[Ct(e),pt(e)];return t.filter(Boolean).length===t.length}(e),n=Bt(e.name);return t||!n?null:Object(u.createElement)(We,null,Object(u.createElement)(h.PanelBody,{title:Object(g.__)("Typography")},Object(u.createElement)(Et,e),Object(u.createElement)(ft,e)))}var Bt=function(e){return"web"===u.Platform.OS&&wt.some((function(t){return Object(c.hasBlockSupport)(e,t)}))};function xt(e){var t=e.units,n=Object(he.a)(e,["units"]),r=Pt(t);return Object(u.createElement)(h.__experimentalUnitControl,Object(l.a)({units:r},n))}function Pt(e){var t=de("spacing.units"),n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return t.filter((function(t){return e.includes(t.value)}))}(t||[],e);return 0!==n.length&&n}function Tt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Nt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Tt(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Tt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Dt(e){var t,n=e.name,r=e.attributes.style,o=e.setAttributes,i=Pt();if(!function(e){var t=Object(c.getBlockSupport)(e,"spacing");return t&&!1!==t.padding}(n))return null;return u.Platform.select({web:Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.__experimentalBoxControl,{values:null==r||null===(t=r.spacing)||void 0===t?void 0:t.padding,onChange:function(e){var t=Nt(Nt({},r),{},{spacing:{padding:e}});o({style:ge(t)})},onChangeShowVisualizer:function(e){var t=Nt(Nt({},r),{},{visualizers:{padding:e}});o({style:ge(t)})},label:Object(g.__)("Padding"),units:i})),native:null})}function Rt(e){var t=e.children,n=Object(he.a)(e,["children"]);return de("spacing.customPadding")?Object(u.createElement)(We,n,Object(u.createElement)(h.PanelBody,{title:Object(g.__)("Spacing")},t)):null}function At(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Mt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?At(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):At(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Lt=[].concat(Object(ne.a)(wt),["color","spacing"]),Ft=function(e){return Lt.some((function(t){return Object(c.hasBlockSupport)(e,t)}))};function Vt(e){if(Object(f.startsWith)(e,"var:")){var t=e.slice("var:".length).split("|").join("--");return"var(--wp--".concat(t,")")}return e}function Ht(e,t,n){if(!Ft(t))return e;var r=n.style;return e.style=Mt(Mt({},function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={};return Object.entries(c.__EXPERIMENTAL_STYLE_PROPERTY).forEach((function(n){var r=Object(oe.a)(n),o=r[0],c=r.slice(1),i=Object(re.a)(c,1)[0];Object(f.has)(e,i)&&(t[o]=Vt(Object(f.get)(e,i)))})),t}(r)),e.style),e}var zt=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=t.name,r=Object(c.hasBlockSupport)(n,"spacing");return[Object(u.createElement)(It,Object(l.a)({key:"typography"},t)),Object(u.createElement)(at,Object(l.a)({key:"colors"},t)),Object(u.createElement)(e,Object(l.a)({key:"edit"},t)),r&&Object(u.createElement)(Rt,{key:"spacing"},Object(u.createElement)(Dt,t))]}}),"withToolbarControls");Object(m.addFilter)("blocks.registerBlockType","core/style/addAttribute",(function(e){return Ft(e)?(e.attributes.style||Object.assign(e.attributes,{style:{type:"object"}}),e):e})),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/style/addSaveProps",Ht),Object(m.addFilter)("blocks.registerBlockType","core/style/addEditProps",(function(e){if(!Ft(e))return e;var t=e.getEditWrapperProps;return e.getEditWrapperProps=function(n){var r={};return t&&(r=t(n)),Ht(r,e,n)},e})),Object(m.addFilter)("editor.BlockEdit","core/style/with-block-controls",zt);var Ut=n(21),Gt=n(22),Kt=n(16),Wt=n(23),qt=n(24),$t=n(19);function Yt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}function Xt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Qt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Xt(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Zt=[],Jt=function(e){return Object(p.createHigherOrderComponent)((function(t){return function(n){return Object(u.createElement)(t,Object(l.a)({},n,{colors:e}))}}),"withCustomColorPalette")},en=function(){return Object(p.createHigherOrderComponent)((function(e){return function(t){var n=de("color.palette")||Zt;return Object(u.createElement)(e,Object(l.a)({},t,{colors:n}))}}),"withEditorColorPalette")};function tn(e,t){var n=Object(f.reduce)(e,(function(e,t){return Qt(Qt({},e),Object(f.isString)(t)?Object(s.a)({},t,Object(f.kebabCase)(t)):t)}),{});return Object(p.compose)([t,function(e){return function(t){Object(Wt.a)(o,t);var r=Yt(o);function o(e){var t;return Object(Ut.a)(this,o),(t=r.call(this,e)).setters=t.createSetters(),t.colorUtils={getMostReadableColor:t.getMostReadableColor.bind(Object(Kt.a)(t))},t.state={},t}return Object(Gt.a)(o,[{key:"getMostReadableColor",value:function(e){return function(e,t){return ie.a.mostReadable(t,Object(f.map)(e,"color")).toHexString()}(this.props.colors,e)}},{key:"createSetters",value:function(){var e=this;return Object(f.reduce)(n,(function(t,n,r){var o=Object(f.upperFirst)(r),c="custom".concat(o);return t["set".concat(o)]=e.createSetColor(r,c),t}),{})}},{key:"createSetColor",value:function(e,t){var n=this;return function(r){var o,c=le(n.props.colors,r);n.props.setAttributes((o={},Object(s.a)(o,e,c&&c.slug?c.slug:void 0),Object(s.a)(o,t,c&&c.slug?void 0:r),o))}}},{key:"render",value:function(){return Object(u.createElement)(e,Qt(Qt(Qt(Qt({},this.props),{},{colors:void 0},this.state),this.setters),{},{colorUtils:this.colorUtils}))}}],[{key:"getDerivedStateFromProps",value:function(e,t){var r=e.attributes,o=e.colors;return Object(f.reduce)(n,(function(e,n,c){var i=ae(o,r[c],r["custom".concat(Object(f.upperFirst)(c))]),a=t[c];return(null==a?void 0:a.color)===i.color&&a?e[c]=a:e[c]=Qt(Qt({},i),{},{class:se(n,i.slug)}),e}),{})}}]),o}(u.Component)}])}function nn(e){return function(){for(var t=Jt(e),n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return Object(p.createHigherOrderComponent)(tn(r,t),"withCustomColors")}}function rn(){for(var e=en(),t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return Object(p.createHigherOrderComponent)(tn(n,e),"withColors")}var on=n(60),cn=n.n(on);function an(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ln(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?an(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):an(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var sn=function(e){var t=e.colorSettings,n=Object(he.a)(e,["colorSettings"]),r=t.map((function(e){var t=e.value,n=e.onChange;return ln(ln({},Object(he.a)(e,["value","onChange"])),{},{colorValue:t,onColorChange:n})}));return Object(u.createElement)(Me,Object(l.a)({settings:r,gradients:[],disableCustomGradients:!0},n))},un=function(e,t,n){return"function"==typeof e?e(t):!0===e?n:e};function dn(e){var t=e.title,n=e.colorSettings,r=e.colorPanelProps,o=e.contrastCheckers,c=e.detectedBackgroundColor,i=e.detectedColor,a=e.panelChildren,s=e.initialOpen;return Object(u.createElement)(sn,Object(l.a)({title:t,initialOpen:s,colorSettings:Object.values(n)},r),o&&(Array.isArray(o)?o.map((function(e){var t=e.backgroundColor,r=e.textColor,o=Object(he.a)(e,["backgroundColor","textColor"]);return t=un(t,n,c),r=un(r,n,i),Object(u.createElement)(Ve,Object(l.a)({key:"".concat(t,"-").concat(r),backgroundColor:t,textColor:r},o))})):Object(f.map)(n,(function(e){var t=e.value,r=o.backgroundColor,a=o.textColor;return r=un(r||t,n,c),a=un(a||t,n,i),Object(u.createElement)(Ve,Object(l.a)({},o,{key:"".concat(r,"-").concat(a),backgroundColor:r,textColor:a}))}))),"function"==typeof a?a(n):a)}function bn(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return fn(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return fn(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,i=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return i=e.done,e},e:function(e){a=!0,c=e},f:function(){try{i||null==n.return||n.return()}finally{if(a)throw c}}}}function fn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function pn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function mn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?pn(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function vn(e){return e.ownerDocument.defaultView.getComputedStyle(e)}var On=[],gn={textColor:Object(g.__)("Text Color"),backgroundColor:Object(g.__)("Background Color")},hn=function(e){return Object(u.createElement)(We,null,Object(u.createElement)(dn,e))};function jn(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{panelTitle:Object(g.__)("Color settings")},n=t.panelTitle,r=void 0===n?Object(g.__)("Color settings"):n,o=t.colorPanelProps,c=t.contrastCheckers,i=t.panelChildren,a=t.colorDetector,l=(a=void 0===a?{}:a).targetRef,d=a.backgroundColorTargetRef,p=void 0===d?l:d,m=a.textColorTargetRef,O=void 0===m?l:m,h=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],j=Object(z.b)(),k=j.clientId,y=de("color.palette")||On,_=Object(v.useSelect)((function(e){return{attributes:(0,e("core/block-editor").getBlockAttributes)(k)}}),[k]),E=_.attributes,C=Object(v.useDispatch)("core/block-editor"),S=C.updateBlockAttributes,w=Object(u.useCallback)((function(e){return S(k,e)}),[S,k]),I=Object(u.useMemo)((function(){return cn()((function(e,t,n,r,o,c){return function(i){var a,l=i.children,d=i.className,p=void 0===d?"":d,m=i.style,v=void 0===m?{}:m,O={};r?O=Object(s.a)({},t,o):c&&(O=Object(s.a)({},t,c));var g={className:b()(p,(a={},Object(s.a)(a,"has-".concat(Object(f.kebabCase)(r),"-").concat(Object(f.kebabCase)(t)),r),Object(s.a)(a,n||"has-".concat(Object(f.kebabCase)(e)),r||c),a)),style:mn(mn({},O),v)};return Object(f.isFunction)(l)?l(g):u.Children.map(l,(function(e){return Object(u.cloneElement)(e,{className:b()(e.props.className,g.className),style:mn(mn({},g.style),e.props.style||{})})}))}}),{maxSize:e.length})}),[e.length]),B=Object(u.useMemo)((function(){return cn()((function(e,t){return function(n){var r=t.find((function(e){return e.color===n}));w(Object(s.a)({},r?Object(f.camelCase)("custom ".concat(e)):e,void 0)),w(Object(s.a)({},r?e:Object(f.camelCase)("custom ".concat(e)),r?r.slug:n))}}),{maxSize:e.length})}),[w,e.length]),x=Object(u.useState)(),P=Object(re.a)(x,2),T=P[0],N=P[1],D=Object(u.useState)(),R=Object(re.a)(D,2),A=R[0],M=R[1];return Object(u.useEffect)((function(){if(c){var e,t=!1,n=!1,r=bn(Object(f.castArray)(c));try{for(r.s();!(e=r.n()).done;){var o=e.value,i=o.backgroundColor,a=o.textColor;if(t||(t=!0===i),n||(n=!0===a),t&&n)break}}catch(e){r.e(e)}finally{r.f()}if(n&&M(vn(O.current).color),t){for(var l=p.current,s=vn(l).backgroundColor;"rgba(0, 0, 0, 0)"===s&&l.parentNode&&l.parentNode.nodeType===l.parentNode.ELEMENT_NODE;)s=vn(l=l.parentNode).backgroundColor;N(s)}}}),[e.reduce((function(e,t){return"".concat(e," | ").concat(E[t.name]," | ").concat(E[Object(f.camelCase)("custom ".concat(t.name))])}),"")].concat(Object(ne.a)(h))),Object(u.useMemo)((function(){var t={},n=e.reduce((function(e,n){"string"==typeof n&&(n={name:n});var r=mn(mn({},n),{},{color:E[n.name]}),o=r.name,c=r.property,i=void 0===c?o:c,a=r.className,l=r.panelLabel,s=void 0===l?n.label||gn[o]||Object(f.startCase)(o):l,u=r.componentName,d=void 0===u?Object(f.startCase)(o).replace(/\s/g,""):u,b=r.color,p=void 0===b?n.color:b,m=r.colors,v=void 0===m?y:m,O=E[Object(f.camelCase)("custom ".concat(o))],g=O?void 0:v.find((function(e){return e.slug===p}));return e[d]=I(o,i,a,p,g&&g.color,O),e[d].displayName=d,e[d].color=O||g&&g.color,e[d].slug=p,e[d].setColor=B(o,v),t[d]={value:g?g.color:E[Object(f.camelCase)("custom ".concat(o))],onChange:e[d].setColor,label:s,colors:v},v||delete t[d].colors,e}),{}),a={title:r,initialOpen:!1,colorSettings:t,colorPanelProps:o,contrastCheckers:c,detectedBackgroundColor:T,detectedColor:A,panelChildren:i};return mn(mn({},n),{},{ColorPanel:Object(u.createElement)(dn,a),InspectorControlsColorPanel:Object(u.createElement)(hn,a)})}),[E,w,A,T].concat(Object(ne.a)(h)))}function kn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function yn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?kn(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function _n(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}var En=[],Cn=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=Object(f.reduce)(t,(function(e,t){return e[t]="custom".concat(Object(f.upperFirst)(t)),e}),{});return Object(p.createHigherOrderComponent)(Object(p.compose)([Object(p.createHigherOrderComponent)((function(e){return function(t){var n=de("typography.fontSizes")||En;return Object(u.createElement)(e,Object(l.a)({},t,{fontSizes:n}))}}),"withFontSizes"),function(e){return function(t){Object(Wt.a)(o,t);var n=_n(o);function o(e){var t;return Object(Ut.a)(this,o),(t=n.call(this,e)).setters=t.createSetters(),t.state={},t}return Object(Gt.a)(o,[{key:"createSetters",value:function(){var e=this;return Object(f.reduce)(r,(function(t,n,r){var o=Object(f.upperFirst)(r);return t["set".concat(o)]=e.createSetFontSize(r,n),t}),{})}},{key:"createSetFontSize",value:function(e,t){var n=this;return function(r){var o,c=Object(f.find)(n.props.fontSizes,{size:Number(r)});n.props.setAttributes((o={},Object(s.a)(o,e,c&&c.slug?c.slug:void 0),Object(s.a)(o,t,c&&c.slug?void 0:r),o))}}},{key:"render",value:function(){return Object(u.createElement)(e,yn(yn(yn({},this.props),{},{fontSizes:void 0},this.state),this.setters))}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n=e.attributes,o=e.fontSizes,c=function(e,r){return!t[r]||(n[r]?n[r]!==t[r].slug:t[r].size!==n[e])};if(!Object(f.some)(r,c))return null;var i=Object(f.reduce)(Object(f.pickBy)(r,c),(function(e,t,r){var c=n[r],i=Ot(o,c,n[t]);return e[r]=yn(yn({},i),{},{class:ht(c)}),e}),{});return yn(yn({},t),i)}}]),o}(u.Component)}]),"withFontSizes")},Sn=n(303),wn=n(304),In=n(305);function Bn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function xn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Bn(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Pn=[{icon:Sn.a,title:Object(g.__)("Align text left"),align:"left"},{icon:wn.a,title:Object(g.__)("Align text center"),align:"center"},{icon:In.a,title:Object(g.__)("Align text right"),align:"right"}],Tn={position:"bottom right",isAlternate:!0};var Nn=function(e){var t=e.value,n=e.onChange,r=e.alignmentControls,o=void 0===r?Pn:r,c=e.label,i=void 0===c?Object(g.__)("Change text alignment"):c,a=e.isCollapsed,l=void 0===a||a,s=e.isRTL;function d(e){return function(){return n(t===e?void 0:e)}}var b=Object(f.find)(o,(function(e){return e.align===t}));return Object(u.createElement)(h.ToolbarGroup,{isCollapsed:l,icon:b?b.icon:s?In.a:Sn.a,label:i,popoverProps:Tn,controls:o.map((function(e){var n=e.align,r=t===n;return xn(xn({},e),{},{isActive:r,role:l?"menuitemradio":void 0,onClick:d(n)})}))})},Dn=function(e){return e.name||""},Rn=function(e){return e.title},An=function(e){return e.keywords||[]},Mn=function(e){return e.category},Ln=function(){return null};function Fn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e=(e=(e=Object(f.deburr)(e)).replace(/^\//,"")).toLowerCase()}var Vn=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return Object(f.words)(Fn(e))},Hn=function(e,t){return Object(f.differenceWith)(e,Vn(t),(function(e,t){return t.includes(e)}))},zn=function(e,t,n,r){return 0===Vn(r).length?e:Un(e,r,{getCategory:function(e){var n;return null===(n=Object(f.find)(t,{slug:e.category}))||void 0===n?void 0:n.title},getCollection:function(e){var t;return null===(t=n[e.name.split("/")[0]])||void 0===t?void 0:t.title},getVariations:function(e){var t=e.variations,n=void 0===t?[]:t;return Array.from(n.reduce((function(e,t){var n=t.title,r=t.keywords,o=void 0===r?[]:r;return e.add(n),o.forEach((function(t){return e.add(t)})),e}),new Set))}})},Un=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=Vn(t);if(0===r.length)return e;var o=e.map((function(e){return[e,Gn(e,t,n)]})).filter((function(e){return Object(re.a)(e,2)[1]>0}));return o.sort((function(e,t){var n=Object(re.a)(e,2)[1];return Object(re.a)(t,2)[1]-n})),o.map((function(e){return Object(re.a)(e,1)[0]}))};function Gn(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.getName,o=void 0===r?Dn:r,c=n.getTitle,i=void 0===c?Rn:c,a=n.getKeywords,l=void 0===a?An:a,s=n.getCategory,u=void 0===s?Mn:s,d=n.getCollection,b=void 0===d?Ln:d,p=o(e),m=i(e),v=l(e),O=u(e),g=b(e),h=Fn(t),j=Fn(m),k=0;if(h===j)k+=30;else if(j.startsWith(h))k+=20;else{var y=[p,m].concat(Object(ne.a)(v),[O,g]).join(" "),_=Object(f.words)(h),E=Hn(_,y);0===E.length&&(k+=10)}return 0!==k&&p.startsWith("core/")&&k++,k}var Kn=function(e,t){var n=Object(v.useSelect)((function(t){var n=t("core/block-editor").getInserterItems,r=t("core/blocks"),o=r.getCategories,c=r.getCollections;return{categories:o(),collections:c(),items:n(e)}}),[e]),r=n.categories,o=n.collections;return[n.items,r,o,function(e){var n=e.name,r=e.initialAttributes,o=e.innerBlocks,i=Object(c.createBlock)(n,r,Object(c.createBlocksFromInnerBlocksTemplate)(o));t(i)}]},Wn=n(208);function qn(e){var t,n=e.icon,r=e.showColors,o=void 0!==r&&r,c=e.className;"block-default"===(null===(t=n)||void 0===t?void 0:t.src)&&(n={src:Wn.a});var i=Object(u.createElement)(h.Icon,{icon:n&&n.src?n.src:n}),a=o?{backgroundColor:n&&n.background,color:n&&n.foreground}:{};return Object(u.createElement)("span",{style:a,className:b()("block-editor-block-icon",c,{"has-colors":o})},i)}var $n={name:"blocks",className:"block-editor-autocompleters__block",triggerPrefix:"/",useItems:function(e){var t=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientId,r=t.getBlockName,o=t.getBlockInsertionPoint,c=n();return{selectedBlockName:c?r(c):null,rootClientId:o().rootClientId}}),[]),n=t.rootClientId,r=t.selectedBlockName,o=Kn(n,f.noop),c=Object(re.a)(o,3),i=c[0],a=c[1],l=c[2],s=Object(u.useMemo)((function(){return(e.trim()?zn(i,a,l,e):Object(f.orderBy)(i,["frecency"],["desc"])).filter((function(e){return e.name!==r})).slice(0,9)}),[e,r,i,a,l]);return[Object(u.useMemo)((function(){return s.map((function(e){var t=e.title,n=e.icon,r=e.isDisabled;return{key:"block-".concat(e.id),value:e,label:Object(u.createElement)(u.Fragment,null,Object(u.createElement)(qn,{key:"icon",icon:n,showColors:!0}),t),isDisabled:r}}))}),[s])]},allowContext:function(e,t){return!(/\S/.test(e)||/\S/.test(t))},getOptionCompletion:function(e){var t=e.name,n=e.initialAttributes,r=e.innerBlocks;return{action:"replace",value:Object(c.createBlock)(t,n,Object(c.createBlocksFromInnerBlocksTemplate)(r))}}},Yn=[];var Xn=function(e){var t=Object(z.b)().name,n=e.completers,r=void 0===n?Yn:n;return r=Object(u.useMemo)((function(){var e=r;return t===Object(c.getDefaultBlockName)()&&(e=e.concat([$n])),Object(m.hasFilter)("editor.Autocomplete.completers")&&(e===r&&(e=e.map(f.clone)),e=Object(m.applyFilters)("editor.Autocomplete.completers",e,t)),e}),[r,t]),Object(u.createElement)(h.Autocomplete,Object(l.a)({},e,{completers:r}))};var Qn=function(e){var t=e.label,n=void 0===t?Object(g.__)("Change matrix alignment"):t,r=e.onChange,o=void 0===r?f.noop:r,c=e.value,i=void 0===c?"center":c,a=Object(u.createElement)(h.__experimentalAlignmentMatrixControl.Icon,{value:i}),l="block-editor-block-alignment-matrix-toolbar",s="".concat(l,"__popover");return Object(u.createElement)(h.Dropdown,{position:"bottom right",className:l,popoverProps:{className:s,isAlternate:!0},renderToggle:function(e){var t=e.onToggle,r=e.isOpen;return Object(u.createElement)(h.ToolbarGroup,null,Object(u.createElement)(h.ToolbarButton,{onClick:t,"aria-haspopup":"true","aria-expanded":r,onKeyDown:function(e){r||e.keyCode!==st.DOWN||(e.preventDefault(),e.stopPropagation(),t())},label:n,icon:a,showTooltip:!0}))},renderContent:function(){return Object(u.createElement)(h.__experimentalAlignmentMatrixControl,{hasFocusBorder:!1,onChange:o,value:i})}})};function Zn(e){var t=e.clientId,n=Object(v.useSelect)((function(e){if(!t)return{};var n=e("core/block-editor"),r=n.getBlockName;return{attributes:(0,n.getBlockAttributes)(t),name:r(t)}}),[t]),r=n.attributes,o=n.name;if(!o)return null;var i=Object(c.getBlockType)(o);if(!i)return null;var a=i.title,l=Object(c.__experimentalGetBlockLabel)(i,r);return l!==a?"".concat(a,": ").concat(Object(f.truncate)(l,{length:15})):a}var Jn=function(){var e=Object(v.useDispatch)("core/block-editor"),t=e.selectBlock,n=e.clearSelectedBlock,r=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getSelectionStart,r=t.getSelectedBlockClientId,o=t.getBlockParents,c=r();return{parents:o(c),clientId:c,hasSelection:!!n().clientId}}),[]),o=r.clientId,c=r.parents,i=r.hasSelection;return Object(u.createElement)("ul",{className:"block-editor-block-breadcrumb",role:"list","aria-label":Object(g.__)("Block breadcrumb")},Object(u.createElement)("li",{className:i?void 0:"block-editor-block-breadcrumb__current","aria-current":i?void 0:"true"},i&&Object(u.createElement)(h.Button,{className:"block-editor-block-breadcrumb__button",isTertiary:!0,onClick:n},Object(g.__)("Document")),!i&&Object(g.__)("Document")),c.map((function(e){return Object(u.createElement)("li",{key:e},Object(u.createElement)(h.Button,{className:"block-editor-block-breadcrumb__button",isTertiary:!0,onClick:function(){return t(e)}},Object(u.createElement)(Zn,{clientId:e})))})),!!o&&Object(u.createElement)("li",{className:"block-editor-block-breadcrumb__current","aria-current":"true"},Object(u.createElement)(Zn,{clientId:o})))};function er(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function tr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?er(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):er(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var nr=Object(u.createContext)({});function rr(e){var t=e.value,n=e.children,r=Object(u.useContext)(nr),o=Object(u.useMemo)((function(){return tr(tr({},r),t)}),[r,t]);return Object(u.createElement)(nr.Provider,{value:o,children:n})}var or=nr,cr=function(){return Object(u.createElement)(h.SVG,{xmlns:"https://www.w3.org/2000/svg",viewBox:"0 0 20 20"},Object(u.createElement)(h.Path,{d:"M7.434 5l3.18 9.16H8.538l-.692-2.184H4.628l-.705 2.184H2L5.18 5h2.254zm-1.13 1.904h-.115l-1.148 3.593H7.44L6.304 6.904zM14.348 7.006c1.853 0 2.9.876 2.9 2.374v4.78h-1.79v-.914h-.114c-.362.64-1.123 1.022-2.031 1.022-1.346 0-2.292-.826-2.292-2.108 0-1.27.972-2.006 2.71-2.107l1.696-.102V9.38c0-.584-.42-.914-1.18-.914-.667 0-1.112.228-1.264.647h-1.701c.12-1.295 1.307-2.107 3.066-2.107zm1.079 4.1l-1.416.09c-.793.056-1.18.342-1.18.844 0 .52.45.837 1.091.837.857 0 1.505-.545 1.505-1.256v-.515z"}))},ir=function(e){var t=e.style,n=e.className;return Object(u.createElement)("div",{className:"block-library-colors-selector__icon-container"},Object(u.createElement)("div",{className:"".concat(n," block-library-colors-selector__state-selection"),style:t},Object(u.createElement)(cr,null)))},ar=function(e){var t,n,r,o=e.children,c=Object(he.a)(e,["children"]);return Object(u.createElement)(h.Dropdown,{position:"bottom right",className:"block-library-colors-selector",contentClassName:"block-library-colors-selector__popover",renderToggle:(t=c,n=t.TextColor,r=t.BackgroundColor,function(e){var t=e.onToggle,o=e.isOpen;return Object(u.createElement)(h.ToolbarGroup,null,Object(u.createElement)(h.ToolbarButton,{className:"components-toolbar__control block-library-colors-selector__toggle",label:Object(g.__)("Open Colors Selector"),onClick:t,onKeyDown:function(e){o||e.keyCode!==st.DOWN||(e.preventDefault(),e.stopPropagation(),t())},icon:Object(u.createElement)(r,null,Object(u.createElement)(n,null,Object(u.createElement)(ir,null)))}))}),renderContent:function(){return o}})},lr={},sr=Object(h.withFilters)("editor.BlockEdit")((function(e){var t=e.attributes,n=void 0===t?{}:t,r=e.name,o=Object(c.getBlockType)(r),i=Object(u.useContext)(or),a=Object(u.useMemo)((function(){return o&&o.usesContext?Object(f.pick)(i,o.usesContext):lr}),[o,i]);if(!o)return null;var s=o.edit||o.save;if(o.apiVersion>1||Object(c.hasBlockSupport)(o,"lightBlockWrapper",!1))return Object(u.createElement)(s,Object(l.a)({},e,{context:a}));var d=Object(c.hasBlockSupport)(o,"className",!0)?Object(c.getBlockDefaultClassName)(r):null,p=b()(d,n.className);return Object(u.createElement)(s,Object(l.a)({},e,{context:a,className:p}))}));function ur(e){var t={name:e.name,isSelected:e.isSelected,clientId:e.clientId,onFocus:e.onFocus,onCaretVerticalPositionChange:e.onCaretVerticalPositionChange};return Object(u.createElement)(z.a,{value:Object(u.useMemo)((function(){return t}),Object.values(t))},Object(u.createElement)(sr,e))}var dr=Object(h.createSlotFill)("BlockFormatControls"),br=dr.Fill,fr=dr.Slot;var pr=function(e){return Object(z.b)().isSelected?Object(u.createElement)(br,null,(function(t){var n=Object(f.isEmpty)(t)?null:t;return Object(u.createElement)(h.__experimentalToolbarContext.Provider,{value:n},e.children)})):null};pr.Slot=function(e){var t=Object(u.useContext)(h.__experimentalToolbarContext);return Object(u.createElement)(fr,Object(l.a)({},e,{fillProps:t}))};var mr=pr,vr=n(20),Or=n.n(vr),gr=n(45),hr=n(316),jr=n(115),kr=n(29),yr=function(e){return e+1},_r=function(e){return{top:e.offsetTop,left:e.offsetLeft}};var Er=function(e,t,n,r,o){var c=Object(p.useReducedMotion)()||!r,i=Object(u.useReducer)(yr,0),a=Object(re.a)(i,2),l=a[0],s=a[1],d=Object(u.useReducer)(yr,0),b=Object(re.a)(d,2),f=b[0],m=b[1],v=Object(u.useState)({x:0,y:0}),O=Object(re.a)(v,2),g=O[0],h=O[1],j=Object(u.useMemo)((function(){return e.current?_r(e.current):null}),[o]),k=Object(u.useMemo)((function(){if(!n||!e.current)return function(){};var t=Object(kr.getScrollContainer)(e.current);if(!t)return function(){};var r=e.current.getBoundingClientRect();return function(){var n=e.current.getBoundingClientRect().top-r.top;n&&(t.scrollTop+=n)}}),[o,n]);function y(n){var r=n.x,o=n.y;r=Math.round(r),o=Math.round(o),r===y.x&&o===y.y||(!function(n){var r=n.x,o=n.y;if(e.current){var c=0===r&&0===o;e.current.style.transformOrigin=c?"":"center",e.current.style.transform=c?"":"translate3d(".concat(r,"px,").concat(o,"px,0)"),e.current.style.zIndex=!t||c?"":"1",k()}}({x:r,y:o}),y.x=r,y.y=o)}Object(u.useLayoutEffect)((function(){l&&m()}),[l]),Object(u.useLayoutEffect)((function(){if(j)if(c)k();else{e.current.style.transform="";var t=_r(e.current);s(),h({x:Math.round(j.left-t.left),y:Math.round(j.top-t.top)})}}),[o]),y.x=0,y.y=0,Object(jr.useSpring)({from:{x:g.x,y:g.y},to:{x:0,y:0},reset:l!==f,config:{mass:5,tension:2e3,friction:200},immediate:c,onFrame:y})},Cr=Object(jr.animated)(h.__experimentalTreeGridRow);function Sr(e){var t=e.isSelected,n=e.position,r=e.level,o=e.rowCount,c=e.children,i=e.className,a=e.path,s=Object(he.a)(e,["isSelected","position","level","rowCount","children","className","path"]),d=Object(u.useRef)(null),f=a.join("_"),p=Er(d,t,!1,!0,f);return Object(u.createElement)(Cr,Object(l.a)({ref:d,style:p,className:b()("block-editor-block-navigation-leaf",i),level:r,positionInSet:n,setSize:o},s),c)}var wr=n(214),Ir=n(215),Br=n(314),xr=n(315);function Pr(e,t,n,r,o,c,i,a){var l=n+1,s=function(e){return"up"===e?"horizontal"===i?a?"right":"left":"up":"down"===e?"horizontal"===i?a?"left":"right":"down":null};if(e>1)return function(e,t,n,r,o){var c=t+1;if(o<0&&n)return Object(g.__)("Blocks cannot be moved up as they are already at the top");if(o>0&&r)return Object(g.__)("Blocks cannot be moved down as they are already at the bottom");if(o<0&&!n)return Object(g.sprintf)(Object(g._n)("Move %1$d block from position %2$d up by one place","Move %1$d blocks from position %2$d up by one place",e),e,c);if(o>0&&!r)return Object(g.sprintf)(Object(g._n)("Move %1$d block from position %2$d down by one place","Move %1$d blocks from position %2$d down by one place",e),e,c)}(e,n,r,o,c);if(r&&o)return Object(g.sprintf)(Object(g.__)("Block %s is the only block, and cannot be moved"),t);if(c>0&&!o){var u=s("down");if("down"===u)return Object(g.sprintf)(Object(g.__)("Move %1$s block from position %2$d down to position %3$d"),t,l,l+1);if("left"===u)return Object(g.sprintf)(Object(g.__)("Move %1$s block from position %2$d left to position %3$d"),t,l,l+1);if("right"===u)return Object(g.sprintf)(Object(g.__)("Move %1$s block from position %2$d right to position %3$d"),t,l,l+1)}if(c>0&&o){var d=s("down");if("down"===d)return Object(g.sprintf)(Object(g.__)("Block %1$s is at the end of the content and can’t be moved down"),t);if("left"===d)return Object(g.sprintf)(Object(g.__)("Block %1$s is at the end of the content and can’t be moved left"),t);if("right"===d)return Object(g.sprintf)(Object(g.__)("Block %1$s is at the end of the content and can’t be moved right"),t)}if(c<0&&!r){var b=s("up");if("up"===b)return Object(g.sprintf)(Object(g.__)("Move %1$s block from position %2$d up to position %3$d"),t,l,l-1);if("left"===b)return Object(g.sprintf)(Object(g.__)("Move %1$s block from position %2$d left to position %3$d"),t,l,l-1);if("right"===b)return Object(g.sprintf)(Object(g.__)("Move %1$s block from position %2$d right to position %3$d"),t,l,l-1)}if(c<0&&r){var f=s("up");if("up"===f)return Object(g.sprintf)(Object(g.__)("Block %1$s is at the beginning of the content and can’t be moved up"),t);if("left"===f)return Object(g.sprintf)(Object(g.__)("Block %1$s is at the beginning of the content and can’t be moved left"),t);if("right"===f)return Object(g.sprintf)(Object(g.__)("Block %1$s is at the beginning of the content and can’t be moved right"),t)}}var Tr=function(e,t,n){return"up"===e?"horizontal"===t?n?wr.a:Ir.a:Br.a:"down"===e?"horizontal"===t?n?Ir.a:wr.a:xr.a:null},Nr=function(e,t,n){return"up"===e?"horizontal"===t?n?Object(g.__)("Move right"):Object(g.__)("Move left"):Object(g.__)("Move up"):"down"===e?"horizontal"===t?n?Object(g.__)("Move left"):Object(g.__)("Move right"):Object(g.__)("Move down"):null},Dr=Object(u.forwardRef)((function(e,t){var n=e.clientIds,r=e.direction,o=e.orientation,i=Object(he.a)(e,["clientIds","direction","orientation"]),a=Object(p.useInstanceId)(Dr),s=Object(f.castArray)(n).length,d=Object(v.useSelect)((function(e){var t=e("core/block-editor"),i=t.getBlockIndex,a=t.getBlockRootClientId,l=t.getBlockOrder,s=t.getBlock,u=t.getSettings,d=t.getBlockListSettings,b=Object(f.castArray)(n),p=Object(f.first)(b),m=a(p),v=i(p,m),O=i(Object(f.last)(b),m),g=l(m),h=s(p),j=0===v,k=O===g.length-1,y=(d(m)||{}).orientation;return{blockType:h?Object(c.getBlockType)(h.name):null,isDisabled:"up"===r?j:k,rootClientId:m,firstIndex:v,isFirst:j,isLast:k,isRTL:u().isRTL,orientation:o||y}}),[n,r]),m=d.blockType,O=d.isDisabled,g=d.rootClientId,j=d.isFirst,k=d.isLast,y=d.firstIndex,_=d.isRTL,E=d.orientation,C=void 0===E?"vertical":E,S=Object(v.useDispatch)("core/block-editor"),w=S.moveBlocksDown,I=S.moveBlocksUp,B="up"===r?I:w,x="block-editor-block-mover-button__description-".concat(a);return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.Button,Object(l.a)({ref:t,className:b()("block-editor-block-mover-button","is-".concat(r,"-button")),icon:Tr(r,C,_),label:Nr(r,C,_),"aria-describedby":x},i,{onClick:O?null:function(e){B(n,g),i.onClick&&i.onClick(e)},"aria-disabled":O})),Object(u.createElement)("span",{id:x,className:"block-editor-block-mover-button__description"},Pr(s,m&&m.title,y,j,k,"up"===r?-1:1,C,_)))})),Rr=Object(u.forwardRef)((function(e,t){return Object(u.createElement)(Dr,Object(l.a)({direction:"up",ref:t},e))})),Ar=Object(u.forwardRef)((function(e,t){return Object(u.createElement)(Dr,Object(l.a)({direction:"down",ref:t},e))}));function Mr(e){var t=e.level,n=e.isLastRow,r=e.terminatedLevels;return Object(f.times)(t-1,(function(e){var o=e+2,c=o===t;return Object(u.createElement)("div",{key:e,"aria-hidden":"true",className:b()("block-editor-block-navigator-descender-line",{"has-item":c,"is-last-row":n,"is-terminated":r.includes(o)})})}))}var Lr=Object(u.createContext)({__experimentalFeatures:!1}),Fr=function(){return Object(u.useContext)(Lr)},Vr=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(j.Path,{d:"M11 13h2v-2h-2v2zm-6 0h2v-2H5v2zm12-2v2h2v-2h-2z"}));var Hr=function(e){var t=e.className,n=e.actions,r=e.children,o=e.secondaryActions;return Object(u.createElement)("div",{className:b()(t,"block-editor-warning")},Object(u.createElement)("div",{className:"block-editor-warning__contents"},Object(u.createElement)("p",{className:"block-editor-warning__message"},r),(u.Children.count(n)>0||o)&&Object(u.createElement)("div",{className:"block-editor-warning__actions"},u.Children.count(n)>0&&u.Children.map(n,(function(e,t){return Object(u.createElement)("span",{key:t,className:"block-editor-warning__action"},e)})),o&&Object(u.createElement)(h.DropdownMenu,{className:"block-editor-warning__secondary",icon:Vr,label:Object(g.__)("More options"),popoverProps:{position:"bottom left",className:"block-editor-warning__dropdown"},noIcons:!0},(function(){return Object(u.createElement)(h.MenuGroup,null,o.map((function(e,t){return Object(u.createElement)(h.MenuItem,{onClick:e.onClick,key:t},e.title)})))})))))},zr=n(279),Ur=function(e){var t=e.title,n=e.rawContent,r=e.renderedContent,o=e.action,c=e.actionText,i=e.className;return Object(u.createElement)("div",{className:i},Object(u.createElement)("div",{className:"block-editor-block-compare__content"},Object(u.createElement)("h2",{className:"block-editor-block-compare__heading"},t),Object(u.createElement)("div",{className:"block-editor-block-compare__html"},n),Object(u.createElement)("div",{className:"block-editor-block-compare__preview edit-post-visual-editor"},r)),Object(u.createElement)("div",{className:"block-editor-block-compare__action"},Object(u.createElement)(h.Button,{isSecondary:!0,tabIndex:"0",onClick:o},c)))};var Gr=function(e){var t,n,r,o,i=e.block,a=e.onKeep,l=e.onConvert,s=e.convertor,d=e.convertButtonText,p={rawContent:i.originalContent,renderedContent:Object(c.getSaveElement)(i.name,i.attributes)},m=(t=s(i),n=Object(f.castArray)(t),r=n.map((function(e){return Object(c.getSaveContent)(e.name,e.attributes,e.innerBlocks)})),o=n.map((function(e){return Object(c.getSaveElement)(e.name,e.attributes,e.innerBlocks)})),{rawContent:r.join(""),renderedContent:o}),v=function(e,t){return Object(zr.diffChars)(e,t).map((function(e,t){var n=b()({"block-editor-block-compare__added":e.added,"block-editor-block-compare__removed":e.removed});return Object(u.createElement)("span",{key:t,className:n},e.value)}))}(p.rawContent,m.rawContent);return Object(u.createElement)("div",{className:"block-editor-block-compare__wrapper"},Object(u.createElement)(Ur,{title:Object(g.__)("Current"),className:"block-editor-block-compare__current",action:a,actionText:Object(g.__)("Convert to HTML"),rawContent:p.rawContent,renderedContent:p.renderedContent}),Object(u.createElement)(Ur,{title:Object(g.__)("After Conversion"),className:"block-editor-block-compare__converted",action:l,actionText:d,rawContent:v,renderedContent:m.renderedContent}))};var Kr=function(e){return Object(c.rawHandler)({HTML:e.originalContent})},Wr=Object(p.compose)([Object(v.withSelect)((function(e,t){var n=t.clientId;return{block:e("core/block-editor").getBlock(n)}})),Object(v.withDispatch)((function(e,t){var n=t.block,r=e("core/block-editor").replaceBlock;return{convertToClassic:function(){r(n.clientId,function(e){return Object(c.createBlock)("core/freeform",{content:e.originalContent})}(n))},convertToHTML:function(){r(n.clientId,function(e){return Object(c.createBlock)("core/html",{content:e.originalContent})}(n))},convertToBlocks:function(){r(n.clientId,Kr(n))},attemptBlockRecovery:function(){var e,t,o,i;r(n.clientId,(t=(e=n).name,o=e.attributes,i=e.innerBlocks,Object(c.createBlock)(t,o,i)))}}}))])((function(e){var t=e.convertToHTML,n=e.convertToBlocks,r=e.convertToClassic,o=e.attemptBlockRecovery,i=e.block,a=!!Object(c.getBlockType)("core/html"),l=Object(u.useState)(!1),s=Object(re.a)(l,2),d=s[0],b=s[1],f=Object(u.useCallback)((function(){return b(!0)}),[]),p=Object(u.useCallback)((function(){return b(!1)}),[]),m=Object(u.useMemo)((function(){return[{title:Object(g._x)("Resolve","imperative verb"),onClick:f},a&&{title:Object(g.__)("Convert to HTML"),onClick:t},{title:Object(g.__)("Convert to Classic Block"),onClick:r}].filter(Boolean)}),[f,t,r]);return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(Hr,{actions:[Object(u.createElement)(h.Button,{key:"recover",onClick:o,isPrimary:!0},Object(g.__)("Attempt Block Recovery"))],secondaryActions:m},Object(g.__)("This block contains unexpected or invalid content.")),d&&Object(u.createElement)(h.Modal,{title:Object(g.__)("Resolve Block"),onRequestClose:p,className:"block-editor-block-compare"},Object(u.createElement)(Gr,{block:i,onKeep:t,onConvert:n,convertor:Kr,convertButtonText:Object(g.__)("Convert to Blocks")})))})),qr=Object(u.createElement)(Hr,{className:"block-editor-block-list__block-crash-warning"},Object(g.__)("This block has encountered an error and cannot be previewed.")),$r=function(){return qr};function Yr(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}var Xr=function(e){Object(Wt.a)(n,e);var t=Yr(n);function n(){var e;return Object(Ut.a)(this,n),(e=t.apply(this,arguments)).state={hasError:!1},e}return Object(Gt.a)(n,[{key:"componentDidCatch",value:function(e){this.props.onError(e),this.setState({hasError:!0})}},{key:"render",value:function(){return this.state.hasError?null:this.props.children}}]),n}(u.Component),Qr=n(100),Zr=n.n(Qr);var Jr=function(e){var t=e.clientId,n=Object(u.useState)(""),r=Object(re.a)(n,2),o=r[0],i=r[1],a=Object(v.useSelect)((function(e){return e("core/block-editor").getBlock(t)}),[t]),l=Object(v.useDispatch)("core/block-editor").updateBlock;return Object(u.useEffect)((function(){i(Object(c.getBlockContent)(a))}),[a]),Object(u.createElement)(Zr.a,{className:"block-editor-block-list__block-html-textarea",value:o,onBlur:function(){var e=Object(c.getBlockType)(a.name),n=Object(c.getBlockAttributes)(e,o,a.attributes),r=o||Object(c.getSaveContent)(e,n),s=!o||Object(c.isValidBlockContent)(e,n,r);l(t,{attributes:n,originalContent:r,isValid:s}),o||i({content:r})},onChange:function(e){return i(e.target.value)}})},eo=n(36),to=n.n(eo);function no(e,t){for(var n="start"===t?"firstChild":"lastChild",r="start"===t?"nextSibling":"previousSibling";e[n];)for(e=e[n];e.nodeType===e.TEXT_NODE&&/^[ \t\n]*$/.test(e.data)&&e[r];)e=e[r];return e}function ro(e){var t=e("core/block-editor"),n=t.isSelectionEnabled,r=t.isMultiSelecting,o=t.getMultiSelectedBlockClientIds,c=t.hasMultiSelection,i=t.getBlockParents,a=t.getSelectedBlockClientId;return{isSelectionEnabled:n(),isMultiSelecting:r(),multiSelectedBlockClientIds:o(),hasMultiSelection:c(),getBlockParents:i,selectedBlockClientId:a()}}function oo(e,t){Array.from(e.querySelectorAll(".rich-text")).forEach((function(e){t?e.setAttribute("contenteditable",!0):e.removeAttribute("contenteditable")}))}var co=n(209),io=[Object(u.createInterpolateElement)(Object(g.__)("While writing, you can press <kbd>/</kbd> to quickly insert new blocks."),{kbd:Object(u.createElement)("kbd",null)}),Object(u.createInterpolateElement)(Object(g.__)("Indent a list by pressing <kbd>space</kbd> at the beginning of a line."),{kbd:Object(u.createElement)("kbd",null)}),Object(u.createInterpolateElement)(Object(g.__)("Outdent a list by pressing <kbd>backspace</kbd> at the beginning of a line."),{kbd:Object(u.createElement)("kbd",null)}),Object(g.__)("Drag files into the editor to automatically insert media blocks."),Object(g.__)("Change a block's type by pressing the block icon on the toolbar.")];var ao=function(){var e=Object(u.useState)(Math.floor(Math.random()*io.length)),t=Object(re.a)(e,1)[0];return Object(u.createElement)(h.Tip,null,io[t])},lo=n(159),so=n(141),uo=n(306);var bo=function e(t){var n=t.className,r=t.onChange,o=t.value,c=t.placeholder,i=Object(p.useInstanceId)(e),a=Object(u.useRef)();return Object(u.createElement)("div",{className:b()("block-editor-inserter__search",n)},Object(u.createElement)(h.VisuallyHidden,{as:"label",htmlFor:"block-editor-inserter__search-".concat(i)},c),Object(u.createElement)("input",{ref:a,className:"block-editor-inserter__search-input",id:"block-editor-inserter__search-".concat(i),type:"search",placeholder:c,autoFocus:!0,onChange:function(e){return r(e.target.value)},autoComplete:"off",value:o||""}),Object(u.createElement)("div",{className:"block-editor-inserter__search-icon"},!!o&&Object(u.createElement)(h.Button,{icon:lo.a,label:Object(g.__)("Reset search"),onClick:function(){r(""),a.current.focus()}}),!o&&Object(u.createElement)(so.a,{icon:uo.a})))};var fo=function(e){var t=e.blockType;return Object(u.createElement)("div",{className:"block-editor-block-card"},Object(u.createElement)(qn,{icon:t.icon,showColors:!0}),Object(u.createElement)("div",{className:"block-editor-block-card__content"},Object(u.createElement)("h2",{className:"block-editor-block-card__title"},t.title),Object(u.createElement)("span",{className:"block-editor-block-card__description"},t.description)))},po={insertUsage:{}},mo={alignWide:!1,colors:[{name:Object(g.__)("Black"),slug:"black",color:"#000000"},{name:Object(g.__)("Cyan bluish gray"),slug:"cyan-bluish-gray",color:"#abb8c3"},{name:Object(g.__)("White"),slug:"white",color:"#ffffff"},{name:Object(g.__)("Pale pink"),slug:"pale-pink",color:"#f78da7"},{name:Object(g.__)("Vivid red"),slug:"vivid-red",color:"#cf2e2e"},{name:Object(g.__)("Luminous vivid orange"),slug:"luminous-vivid-orange",color:"#ff6900"},{name:Object(g.__)("Luminous vivid amber"),slug:"luminous-vivid-amber",color:"#fcb900"},{name:Object(g.__)("Light green cyan"),slug:"light-green-cyan",color:"#7bdcb5"},{name:Object(g.__)("Vivid green cyan"),slug:"vivid-green-cyan",color:"#00d084"},{name:Object(g.__)("Pale cyan blue"),slug:"pale-cyan-blue",color:"#8ed1fc"},{name:Object(g.__)("Vivid cyan blue"),slug:"vivid-cyan-blue",color:"#0693e3"},{name:Object(g.__)("Vivid purple"),slug:"vivid-purple",color:"#9b51e0"}],fontSizes:[{name:Object(g._x)("Small","font size name"),size:13,slug:"small"},{name:Object(g._x)("Normal","font size name"),size:16,slug:"normal"},{name:Object(g._x)("Medium","font size name"),size:20,slug:"medium"},{name:Object(g._x)("Large","font size name"),size:36,slug:"large"},{name:Object(g._x)("Huge","font size name"),size:42,slug:"huge"}],imageSizes:[{slug:"thumbnail",name:Object(g.__)("Thumbnail")},{slug:"medium",name:Object(g.__)("Medium")},{slug:"large",name:Object(g.__)("Large")},{slug:"full",name:Object(g.__)("Full Size")}],imageEditing:!0,maxWidth:580,allowedBlockTypes:!0,maxUploadFileSize:0,allowedMimeTypes:null,availableLegacyWidgets:{},__experimentalCanUserUseUnfilteredHTML:!1,__experimentalBlockDirectory:!1,__experimentalEnableFullSiteEditing:!1,__experimentalEnableFullSiteEditingDemo:!1,__mobileEnablePageTemplates:!1,__experimentalBlockPatterns:[],__experimentalBlockPatternCategories:[],__experimentalSpotlightEntityBlocks:[],gradients:[{name:Object(g.__)("Vivid cyan blue to vivid purple"),gradient:"linear-gradient(135deg,rgba(6,147,227,1) 0%,rgb(155,81,224) 100%)",slug:"vivid-cyan-blue-to-vivid-purple"},{name:Object(g.__)("Light green cyan to vivid green cyan"),gradient:"linear-gradient(135deg,rgb(122,220,180) 0%,rgb(0,208,130) 100%)",slug:"light-green-cyan-to-vivid-green-cyan"},{name:Object(g.__)("Luminous vivid amber to luminous vivid orange"),gradient:"linear-gradient(135deg,rgba(252,185,0,1) 0%,rgba(255,105,0,1) 100%)",slug:"luminous-vivid-amber-to-luminous-vivid-orange"},{name:Object(g.__)("Luminous vivid orange to vivid red"),gradient:"linear-gradient(135deg,rgba(255,105,0,1) 0%,rgb(207,46,46) 100%)",slug:"luminous-vivid-orange-to-vivid-red"},{name:Object(g.__)("Very light gray to cyan bluish gray"),gradient:"linear-gradient(135deg,rgb(238,238,238) 0%,rgb(169,184,195) 100%)",slug:"very-light-gray-to-cyan-bluish-gray"},{name:Object(g.__)("Cool to warm spectrum"),gradient:"linear-gradient(135deg,rgb(74,234,220) 0%,rgb(151,120,209) 20%,rgb(207,42,186) 40%,rgb(238,44,130) 60%,rgb(251,105,98) 80%,rgb(254,248,76) 100%)",slug:"cool-to-warm-spectrum"},{name:Object(g.__)("Blush light purple"),gradient:"linear-gradient(135deg,rgb(255,206,236) 0%,rgb(152,150,240) 100%)",slug:"blush-light-purple"},{name:Object(g.__)("Blush bordeaux"),gradient:"linear-gradient(135deg,rgb(254,205,165) 0%,rgb(254,45,45) 50%,rgb(107,0,62) 100%)",slug:"blush-bordeaux"},{name:Object(g.__)("Luminous dusk"),gradient:"linear-gradient(135deg,rgb(255,203,112) 0%,rgb(199,81,192) 50%,rgb(65,88,208) 100%)",slug:"luminous-dusk"},{name:Object(g.__)("Pale ocean"),gradient:"linear-gradient(135deg,rgb(255,245,203) 0%,rgb(182,227,212) 50%,rgb(51,167,181) 100%)",slug:"pale-ocean"},{name:Object(g.__)("Electric grass"),gradient:"linear-gradient(135deg,rgb(202,248,128) 0%,rgb(113,206,126) 100%)",slug:"electric-grass"},{name:Object(g.__)("Midnight"),gradient:"linear-gradient(135deg,rgb(2,3,129) 0%,rgb(40,116,252) 100%)",slug:"midnight"}]};function vo(e,t,n){return[].concat(Object(ne.a)(e.slice(0,n)),Object(ne.a)(Object(f.castArray)(t)),Object(ne.a)(e.slice(n)))}function Oo(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,o=Object(ne.a)(e);return o.splice(t,r),vo(o,e.slice(t,t+r),n)}function go(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ho(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?go(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):go(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function jo(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=Object(s.a)({},t,[]);return e.forEach((function(e){var r=e.clientId,o=e.innerBlocks;n[t].push(r),Object.assign(n,jo(o,r))})),n}function ko(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return e.reduce((function(e,n){return Object.assign(e,Object(s.a)({},n.clientId,t),ko(n.innerBlocks,n.clientId))}),{})}function yo(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:f.identity,n={},r=Object(ne.a)(e);r.length;){var o=r.shift(),c=o.innerBlocks,i=Object(he.a)(o,["innerBlocks"]);r.push.apply(r,Object(ne.a)(c)),n[i.clientId]=t(i)}return n}function _o(e){return yo(e,(function(e){return Object(f.omit)(e,"attributes")}))}function Eo(e){return yo(e,(function(e){return e.attributes}))}function Co(e,t){return e===t?ho({},e):t}function So(e,t){return"UPDATE_BLOCK_ATTRIBUTES"===e.type&&void 0!==t&&"UPDATE_BLOCK_ATTRIBUTES"===t.type&&Object(f.isEqual)(e.clientIds,t.clientIds)&&(n=e.attributes,r=t.attributes,Object(f.isEqual)(Object(f.keys)(n),Object(f.keys)(r)));var n,r}var wo=function(e){return e.reduce((function(e,t){return e[t]={},e}),{})};var Io=Object(f.flow)(v.combineReducers,(function(e){return function(t,n){if(t&&"SAVE_REUSABLE_BLOCK_SUCCESS"===n.type){var r=n.id,o=n.updatedId;if(r===o)return t;(t=ho({},t)).attributes=Object(f.mapValues)(t.attributes,(function(e,n){return"core/block"===t.byClientId[n].name&&e.ref===r?ho(ho({},e),{},{ref:o}):e}))}return e(t,n)}}),(function(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0,r=e(t,n);if(r===t)return t;r.cache=t.cache?t.cache:{};var o=function(e){return e.reduce((function(e,n){var r=n;do{e.push(r),r=t.parents[r]}while(r&&!t.controlledInnerBlocks[r]);return e}),[])};switch(n.type){case"RESET_BLOCKS":r.cache=Object(f.mapValues)(yo(n.blocks),(function(){return{}}));break;case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":var c=Object(f.keys)(yo(n.blocks));n.rootClientId&&!t.controlledInnerBlocks[n.rootClientId]&&c.push(n.rootClientId),r.cache=ho(ho({},r.cache),wo(o(c)));break;case"UPDATE_BLOCK":r.cache=ho(ho({},r.cache),wo(o([n.clientId])));break;case"UPDATE_BLOCK_ATTRIBUTES":r.cache=ho(ho({},r.cache),wo(o(n.clientIds)));break;case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":var i=wo(o(n.replacedClientIds));r.cache=ho(ho(ho({},Object(f.omit)(r.cache,n.replacedClientIds)),Object(f.omit)(i,n.replacedClientIds)),wo(Object(f.keys)(yo(n.blocks))));break;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":r.cache=ho(ho({},Object(f.omit)(r.cache,n.removedClientIds)),wo(Object(f.difference)(o(n.clientIds),n.clientIds)));break;case"MOVE_BLOCKS_TO_POSITION":var a=Object(ne.a)(n.clientIds);n.fromRootClientId&&a.push(n.fromRootClientId),n.toRootClientId&&a.push(n.toRootClientId),r.cache=ho(ho({},r.cache),wo(o(a)));break;case"MOVE_BLOCKS_UP":case"MOVE_BLOCKS_DOWN":var l=[];n.rootClientId&&l.push(n.rootClientId),r.cache=ho(ho({},r.cache),wo(o(l)));break;case"SAVE_REUSABLE_BLOCK_SUCCESS":var s=Object(f.keys)(Object(f.omitBy)(r.attributes,(function(e,t){return"core/block"!==r.byClientId[t].name||e.ref!==n.updatedId})));r.cache=ho(ho({},r.cache),wo(o(s)))}return r}}),(function(e){return function(t,n){var r=function(e){for(var r=e,o=0;o<r.length;o++){var c;!t.order[r[o]]||n.keepControlledInnerBlocks&&n.keepControlledInnerBlocks[r[o]]||(r===e&&(r=Object(ne.a)(r)),(c=r).push.apply(c,Object(ne.a)(t.order[r[o]])))}return r};if(t)switch(n.type){case"REMOVE_BLOCKS":n=ho(ho({},n),{},{type:"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN",removedClientIds:r(n.clientIds)});break;case"REPLACE_BLOCKS":n=ho(ho({},n),{},{type:"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN",replacedClientIds:r(n.clientIds)})}return e(t,n)}}),(function(e){return function(t,n){if("REPLACE_INNER_BLOCKS"!==n.type)return e(t,n);var r={};if(Object.keys(t.controlledInnerBlocks).length)for(var o=Object(ne.a)(n.blocks);o.length;){var c=o.shift(),i=c.innerBlocks,a=Object(he.a)(c,["innerBlocks"]);o.push.apply(o,Object(ne.a)(i)),t.controlledInnerBlocks[a.clientId]&&(r[a.clientId]=!0)}var l=t;t.order[n.rootClientId]&&(l=e(l,{type:"REMOVE_BLOCKS",keepControlledInnerBlocks:r,clientIds:t.order[n.rootClientId]}));var s=l;return n.blocks.length&&((s=e(s,ho(ho({},n),{},{type:"INSERT_BLOCKS",index:0}))).order=ho(ho({},s.order),Object(f.reduce)(r,(function(e,n,r){return t.order[r]&&(e[r]=t.order[r]),e}),{}))),s}}),(function(e){return function(t,n){if(t&&"RESET_BLOCKS"===n.type){var r=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return Object(f.reduce)(t[n],(function(n,o){return r[o]?n:[].concat(Object(ne.a)(n),[o],Object(ne.a)(e(t,o)))}),[])}(t.order,"",t.controlledInnerBlocks),o=Object.keys(Object(f.pickBy)(t.controlledInnerBlocks));return ho(ho({},t),{},{byClientId:ho(ho({},Object(f.omit)(t.byClientId,r)),_o(n.blocks)),attributes:ho(ho({},Object(f.omit)(t.attributes,r)),Eo(n.blocks)),order:ho(ho({},Object(f.omit)(t.order,r)),Object(f.omit)(jo(n.blocks),o)),parents:ho(ho({},Object(f.omit)(t.parents,r)),ko(n.blocks)),cache:ho(ho({},Object(f.omit)(t.cache,r)),Object(f.omit)(Object(f.mapValues)(yo(n.blocks),(function(){return{}})),o))})}return e(t,n)}}),(function(e){var t,n=!1;return function(r,o){var c=e(r,o),i="MARK_LAST_CHANGE_AS_PERSISTENT"===o.type||n;if(r===c&&!i){var a;n="MARK_NEXT_CHANGE_AS_NOT_PERSISTENT"===o.type;var l=null===(a=null==r?void 0:r.isPersistentChange)||void 0===a||a;return r.isPersistentChange===l?r:ho(ho({},c),{},{isPersistentChange:l})}return c=ho(ho({},c),{},{isPersistentChange:i?!n:!So(o,t)}),t=o,n="MARK_NEXT_CHANGE_AS_NOT_PERSISTENT"===o.type,c}}),(function(e){var t=new Set(["RECEIVE_BLOCKS"]);return function(n,r){var o=e(n,r);return o!==n&&(o.isIgnoredChange=t.has(r.type)),o}}))({byClientId:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"RESET_BLOCKS":return _o(t.blocks);case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":return ho(ho({},e),_o(t.blocks));case"UPDATE_BLOCK":if(!e[t.clientId])return e;var n=Object(f.omit)(t.updates,"attributes");return Object(f.isEmpty)(n)?e:ho(ho({},e),{},Object(s.a)({},t.clientId,ho(ho({},e[t.clientId]),n)));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return t.blocks?ho(ho({},Object(f.omit)(e,t.replacedClientIds)),_o(t.blocks)):e;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(f.omit)(e,t.removedClientIds)}return e},attributes:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"RESET_BLOCKS":return Eo(t.blocks);case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":return ho(ho({},e),Eo(t.blocks));case"UPDATE_BLOCK":return e[t.clientId]&&t.updates.attributes?ho(ho({},e),{},Object(s.a)({},t.clientId,ho(ho({},e[t.clientId]),t.updates.attributes))):e;case"UPDATE_BLOCK_ATTRIBUTES":if(t.clientIds.every((function(t){return!e[t]})))return e;var n=t.clientIds.reduce((function(n,r){return ho(ho({},n),{},Object(s.a)({},r,Object(f.reduce)(t.attributes,(function(t,n,o){return n!==t[o]&&((t=Co(e[r],t))[o]=n),t}),e[r])))}),{});return t.clientIds.every((function(t){return n[t]===e[t]}))?e:ho(ho({},e),n);case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return t.blocks?ho(ho({},Object(f.omit)(e,t.replacedClientIds)),Eo(t.blocks)):e;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(f.omit)(e,t.removedClientIds)}return e},order:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"RESET_BLOCKS":return jo(t.blocks);case"RECEIVE_BLOCKS":return ho(ho({},e),Object(f.omit)(jo(t.blocks),""));case"INSERT_BLOCKS":var n=t.rootClientId,r=void 0===n?"":n,o=e[r]||[],c=jo(t.blocks,r),i=t.index,a=void 0===i?o.length:i;return ho(ho(ho({},e),c),{},Object(s.a)({},r,vo(o,c[r],a)));case"MOVE_BLOCKS_TO_POSITION":var l,u=t.fromRootClientId,d=void 0===u?"":u,b=t.toRootClientId,p=void 0===b?"":b,m=t.clientIds,v=t.index,O=void 0===v?e[p].length:v;if(d===p){var g=e[p],h=g.indexOf(m[0]);return ho(ho({},e),{},Object(s.a)({},p,Oo(e[p],h,O,m.length)))}return ho(ho({},e),{},(l={},Object(s.a)(l,d,f.without.apply(void 0,[e[d]].concat(Object(ne.a)(m)))),Object(s.a)(l,p,vo(e[p],m,O)),l));case"MOVE_BLOCKS_UP":var j=t.clientIds,k=t.rootClientId,y=void 0===k?"":k,_=Object(f.first)(j),E=e[y];if(!E.length||_===Object(f.first)(E))return e;var C=E.indexOf(_);return ho(ho({},e),{},Object(s.a)({},y,Oo(E,C,C-1,j.length)));case"MOVE_BLOCKS_DOWN":var S=t.clientIds,w=t.rootClientId,I=void 0===w?"":w,B=Object(f.first)(S),x=Object(f.last)(S),P=e[I];if(!P.length||x===Object(f.last)(P))return e;var T=P.indexOf(B);return ho(ho({},e),{},Object(s.a)({},I,Oo(P,T,T+1,S.length)));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":var N=t.clientIds;if(!t.blocks)return e;var D=jo(t.blocks);return Object(f.flow)([function(e){return Object(f.omit)(e,t.replacedClientIds)},function(e){return ho(ho({},e),Object(f.omit)(D,""))},function(e){return Object(f.mapValues)(e,(function(e){return Object(f.reduce)(e,(function(e,t){return t===N[0]?[].concat(Object(ne.a)(e),Object(ne.a)(D[""])):(-1===N.indexOf(t)&&e.push(t),e)}),[])}))}])(e);case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(f.flow)([function(e){return Object(f.omit)(e,t.removedClientIds)},function(e){return Object(f.mapValues)(e,(function(e){return f.without.apply(void 0,[e].concat(Object(ne.a)(t.removedClientIds)))}))}])(e)}return e},parents:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"RESET_BLOCKS":return ko(t.blocks);case"RECEIVE_BLOCKS":return ho(ho({},e),ko(t.blocks));case"INSERT_BLOCKS":return ho(ho({},e),ko(t.blocks,t.rootClientId||""));case"MOVE_BLOCKS_TO_POSITION":return ho(ho({},e),t.clientIds.reduce((function(e,n){return e[n]=t.toRootClientId||"",e}),{}));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return ho(ho({},Object(f.omit)(e,t.replacedClientIds)),ko(t.blocks,e[t.clientIds[0]]));case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(f.omit)(e,t.removedClientIds)}return e},controlledInnerBlocks:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=t.type,r=t.clientId,o=t.hasControlledInnerBlocks;return"SET_HAS_CONTROLLED_INNER_BLOCKS"===n?ho(ho({},e),{},Object(s.a)({},r,o)):e}});function Bo(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"CLEAR_SELECTED_BLOCK":return e.clientId?{}:e;case"SELECT_BLOCK":return t.clientId===e.clientId?e:{clientId:t.clientId};case"REPLACE_INNER_BLOCKS":case"INSERT_BLOCKS":return t.updateSelection&&t.blocks.length?{clientId:t.blocks[0].clientId}:e;case"REMOVE_BLOCKS":return t.clientIds&&t.clientIds.length&&-1!==t.clientIds.indexOf(e.clientId)?{}:e;case"REPLACE_BLOCKS":if(-1===t.clientIds.indexOf(e.clientId))return e;var n=t.indexToSelect||t.blocks.length-1,r=t.blocks[n];if(!r)return{};if(r.clientId===e.clientId)return e;var o={clientId:r.clientId};return"number"==typeof t.initialPosition&&(o.initialPosition=t.initialPosition),o}return e}function xo(e,t,n){switch(t.type){case"CLEAR_SELECTED_BLOCK":case"SELECT_BLOCK":case"REPLACE_INNER_BLOCKS":case"INSERT_BLOCKS":case"REMOVE_BLOCKS":case"REPLACE_BLOCKS":return n}return e}var Po=Object(v.combineReducers)({blocks:Io,isTyping:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"START_TYPING":return!0;case"STOP_TYPING":return!1}return e},draggedBlocks:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"START_DRAGGING_BLOCKS":return t.clientIds;case"STOP_DRAGGING_BLOCKS":return[]}return e},isCaretWithinFormattedText:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"ENTER_FORMATTED_TEXT":return!0;case"EXIT_FORMATTED_TEXT":return!1}return e},selectionStart:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SELECTION_CHANGE":return{clientId:t.clientId,attributeKey:t.attributeKey,offset:t.startOffset};case"RESET_SELECTION":return t.selectionStart;case"MULTI_SELECT":return{clientId:t.start}}return Bo(e,t)},selectionEnd:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SELECTION_CHANGE":return{clientId:t.clientId,attributeKey:t.attributeKey,offset:t.endOffset};case"RESET_SELECTION":return t.selectionEnd;case"MULTI_SELECT":return{clientId:t.end}}return Bo(e,t)},isMultiSelecting:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"START_MULTI_SELECT":return!0;case"STOP_MULTI_SELECT":return!1}return e},isSelectionEnabled:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"TOGGLE_SELECTION":return t.isSelectionEnabled}return e},initialPosition:function(e,t){return"REPLACE_BLOCKS"===t.type&&"number"==typeof t.initialPosition||"SELECT_BLOCK"===t.type?t.initialPosition:"REMOVE_BLOCKS"===t.type||"START_TYPING"===t.type?e:void 0},blocksMode:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;if("TOGGLE_BLOCK_MODE"===t.type){var n=t.clientId;return ho(ho({},e),{},Object(s.a)({},n,e[n]&&"html"===e[n]?"visual":"html"))}return e},blockListSettings:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"REPLACE_BLOCKS":case"REMOVE_BLOCKS":return Object(f.omit)(e,t.clientIds);case"UPDATE_BLOCK_LIST_SETTINGS":var n=t.clientId;return t.settings?Object(f.isEqual)(e[n],t.settings)?e:ho(ho({},e),{},Object(s.a)({},n,t.settings)):e.hasOwnProperty(n)?Object(f.omit)(e,n):e}return e},insertionPoint:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_INSERTION_POINT":case"SHOW_INSERTION_POINT":var n=t.rootClientId,r=t.index;return{rootClientId:n,index:r}}return xo(e,t,null)},insertionPointVisibility:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SHOW_INSERTION_POINT":return!0;case"HIDE_INSERTION_POINT":return!1}return xo(e,t,!1)},template:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{isValid:!0},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_TEMPLATE_VALIDITY":return ho(ho({},e),{},{isValid:t.isValid})}return e},settings:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:mo,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"UPDATE_SETTINGS":return ho(ho({},e),t.settings)}return e},preferences:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:po,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"INSERT_BLOCKS":case"REPLACE_BLOCKS":return t.blocks.reduce((function(e,n){var r=n.name,o={name:n.name};return Object(c.isReusableBlock)(n)&&(o.ref=n.attributes.ref,r+="/"+n.attributes.ref),ho(ho({},e),{},{insertUsage:ho(ho({},e.insertUsage),{},Object(s.a)({},r,{time:t.time,count:e.insertUsage[r]?e.insertUsage[r].count+1:1,insert:o}))})}),e)}return e},lastBlockAttributesChange:function(e,t){switch(t.type){case"UPDATE_BLOCK":if(!t.updates.attributes)break;return Object(s.a)({},t.clientId,t.updates.attributes);case"UPDATE_BLOCK_ATTRIBUTES":return t.clientIds.reduce((function(e,n){return ho(ho({},e),{},Object(s.a)({},n,t.attributes))}),{})}return null},isNavigationMode:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return"INSERT_BLOCKS"!==t.type&&("SET_NAVIGATION_MODE"===t.type?t.isNavigationMode:e)},hasBlockMovingClientId:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0;return"SET_BLOCK_MOVING_MODE"===t.type?t.hasBlockMovingClientId:e},automaticChangeStatus:function(e,t){switch(t.type){case"MARK_AUTOMATIC_CHANGE":return"pending";case"MARK_AUTOMATIC_CHANGE_FINAL":return"pending"===e?"final":void 0;case"SELECTION_CHANGE":return"final"!==e?e:void 0;case"STOP_TYPING":return e}},highlightedBlock:function(e,t){switch(t.type){case"TOGGLE_BLOCK_HIGHLIGHT":var n=t.clientId;return t.isHighlighted?n:e===n?null:e;case"SELECT_BLOCK":if(t.clientId!==e)return null}return e}}),To=n(150),No=n.n(To),Do=n(277),Ro=n.n(Do),Ao=n(40);function Mo(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return Lo(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Lo(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,i=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return i=e.done,e},e:function(e){a=!0,c=e},f:function(){try{i||null==n.return||n.return()}finally{if(a)throw c}}}}function Lo(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Fo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Vo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fo(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ho=Or.a.mark(tc),zo=Or.a.mark(lc),Uo=Or.a.mark(sc),Go=Or.a.mark(vc),Ko=Or.a.mark(kc),Wo=Or.a.mark(yc),qo=Or.a.mark(Ec),$o=Or.a.mark(Pc),Yo=Or.a.mark(Yc),Xo=Or.a.mark(Xc),Qo=Or.a.mark(Qc),Zo=Or.a.mark(Zc),Jo=Or.a.mark(Jc),ec=Or.a.mark(ti);function tc(){return Or.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,v.controls.select("core/block-editor","getBlockCount");case 2:if(0!==e.sent){e.next=7;break}return e.next=6,zc();case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}}),Ho)}function nc(e){return{type:"RESET_BLOCKS",blocks:e}}function rc(e,t){return{type:"RESET_SELECTION",selectionStart:e,selectionEnd:t}}function oc(e){return{type:"RECEIVE_BLOCKS",blocks:e}}function cc(e,t){return{type:"UPDATE_BLOCK_ATTRIBUTES",clientIds:Object(f.castArray)(e),attributes:t}}function ic(e,t){return{type:"UPDATE_BLOCK",clientId:e,updates:t}}function ac(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return{type:"SELECT_BLOCK",initialPosition:t,clientId:e}}function lc(e){var t;return Or.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,v.controls.select("core/block-editor","getPreviousBlockClientId",e);case 2:if(!(t=n.sent)){n.next=7;break}return n.next=6,ac(t,-1);case 6:return n.abrupt("return",[t]);case 7:case"end":return n.stop()}}),zo)}function sc(e){var t;return Or.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,v.controls.select("core/block-editor","getNextBlockClientId",e);case 2:if(!(t=n.sent)){n.next=7;break}return n.next=6,ac(t);case 6:return n.abrupt("return",[t]);case 7:case"end":return n.stop()}}),Uo)}function uc(){return{type:"START_MULTI_SELECT"}}function dc(){return{type:"STOP_MULTI_SELECT"}}function bc(e,t){return{type:"MULTI_SELECT",start:e,end:t}}function fc(){return{type:"CLEAR_SELECTED_BLOCK"}}function pc(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return{type:"TOGGLE_SELECTION",isSelectionEnabled:e}}function mc(e,t){var n,r,o=null!==(n=null==t||null===(r=t.__experimentalPreferredStyleVariations)||void 0===r?void 0:r.value)&&void 0!==n?n:{};return e.map((function(e){var t,n=e.name;if(!Object(c.hasBlockSupport)(n,"defaultStylePicker",!0))return e;if(!o[n])return e;var r=null===(t=e.attributes)||void 0===t?void 0:t.className;if(null==r?void 0:r.includes("is-style-"))return e;var i=e.attributes,a=void 0===i?{}:i,l=o[n];return Vo(Vo({},e),{},{attributes:Vo(Vo({},a),{},{className:"".concat(r||""," is-style-").concat(l).trim()})})}))}function vc(e,t,n,r,o){var c,i,a;return Or.a.wrap((function(l){for(;;)switch(l.prev=l.next){case 0:return e=Object(f.castArray)(e),l.t0=mc,l.t1=Object(f.castArray)(t),l.next=5,v.controls.select("core/block-editor","getSettings");case 5:return l.t2=l.sent,t=(0,l.t0)(l.t1,l.t2),l.next=9,v.controls.select("core/block-editor","getBlockRootClientId",Object(f.first)(e));case 9:c=l.sent,i=0;case 11:if(!(i<t.length)){l.next=21;break}return a=t[i],l.next=15,v.controls.select("core/block-editor","canInsertBlockType",a.name,c);case 15:if(l.sent){l.next=18;break}return l.abrupt("return");case 18:i++,l.next=11;break;case 21:return l.next=23,{type:"REPLACE_BLOCKS",clientIds:e,blocks:t,time:Date.now(),indexToSelect:n,initialPosition:r,meta:o};case 23:return l.delegateYield(tc(),"t3",24);case 24:case"end":return l.stop()}}),Go)}function Oc(e,t){return vc(e,t)}function gc(e){return function(t,n){return{clientIds:Object(f.castArray)(t),type:e,rootClientId:n}}}var hc=gc("MOVE_BLOCKS_DOWN"),jc=gc("MOVE_BLOCKS_UP");function kc(e){var t,n,r,o,c,i=arguments;return Or.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:return t=i.length>1&&void 0!==i[1]?i[1]:"",n=i.length>2&&void 0!==i[2]?i[2]:"",r=i.length>3?i[3]:void 0,a.next=5,v.controls.select("core/block-editor","getTemplateLock",t);case 5:if("all"!==(o=a.sent)){a.next=8;break}return a.abrupt("return");case 8:if(c={type:"MOVE_BLOCKS_TO_POSITION",fromRootClientId:t,toRootClientId:n,clientIds:e,index:r},t!==n){a.next=13;break}return a.next=12,c;case 12:return a.abrupt("return");case 13:if("insert"!==o){a.next=15;break}return a.abrupt("return");case 15:return a.next=17,v.controls.select("core/block-editor","canInsertBlocks",e,n);case 17:if(!a.sent){a.next=21;break}return a.next=21,c;case 21:case"end":return a.stop()}}),Ko)}function yc(e){var t,n,r,o=arguments;return Or.a.wrap((function(c){for(;;)switch(c.prev=c.next){case 0:return t=o.length>1&&void 0!==o[1]?o[1]:"",n=o.length>2&&void 0!==o[2]?o[2]:"",r=o.length>3?o[3]:void 0,c.next=5,kc([e],t,n,r);case 5:case"end":return c.stop()}}),Wo)}function _c(e,t,n){var r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];return Ec([e],t,n,r)}function Ec(e,t,n){var r,o,c,i,a,l,s=arguments;return Or.a.wrap((function(u){for(;;)switch(u.prev=u.next){case 0:return r=!(s.length>3&&void 0!==s[3])||s[3],o=s.length>4?s[4]:void 0,u.t0=mc,u.t1=Object(f.castArray)(e),u.next=6,v.controls.select("core/block-editor","getSettings");case 6:u.t2=u.sent,e=(0,u.t0)(u.t1,u.t2),c=[],i=Mo(e),u.prev=10,i.s();case 12:if((a=i.n()).done){u.next=20;break}return l=a.value,u.next=16,v.controls.select("core/block-editor","canInsertBlockType",l.name,n);case 16:u.sent&&c.push(l);case 18:u.next=12;break;case 20:u.next=25;break;case 22:u.prev=22,u.t3=u.catch(10),i.e(u.t3);case 25:return u.prev=25,i.f(),u.finish(25);case 28:if(!c.length){u.next=30;break}return u.abrupt("return",{type:"INSERT_BLOCKS",blocks:c,index:t,rootClientId:n,time:Date.now(),updateSelection:r,meta:o});case 30:case"end":return u.stop()}}),qo,null,[[10,22,25,28]])}function Cc(e,t){return{type:"SET_INSERTION_POINT",rootClientId:e,index:t}}function Sc(e,t){return{type:"SHOW_INSERTION_POINT",rootClientId:e,index:t}}function wc(){return{type:"HIDE_INSERTION_POINT"}}function Ic(e){return{type:"SET_TEMPLATE_VALIDITY",isValid:e}}function Bc(){return{type:"SYNCHRONIZE_TEMPLATE"}}function xc(e,t){return{type:"MERGE_BLOCKS",blocks:[e,t]}}function Pc(e){var t,n,r,o,c=arguments;return Or.a.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:if(t=!(c.length>1&&void 0!==c[1])||c[1],e&&e.length){i.next=3;break}return i.abrupt("return");case 3:return e=Object(f.castArray)(e),i.next=6,v.controls.select("core/block-editor","getBlockRootClientId",e[0]);case 6:return n=i.sent,i.next=9,v.controls.select("core/block-editor","getTemplateLock",n);case 9:if(!i.sent){i.next=12;break}return i.abrupt("return");case 12:if(!t){i.next=18;break}return i.next=15,lc(e[0]);case 15:r=i.sent,i.next=21;break;case 18:return i.next=20,v.controls.select("core/block-editor","getPreviousBlockClientId",e[0]);case 20:r=i.sent;case 21:return i.next=23,{type:"REMOVE_BLOCKS",clientIds:e};case 23:return i.delegateYield(tc(),"t0",24);case 24:return o=i.t0,i.abrupt("return",[r||o]);case 26:case"end":return i.stop()}}),$o)}function Tc(e,t){return Pc([e],t)}function Nc(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return{type:"REPLACE_INNER_BLOCKS",rootClientId:e,blocks:t,updateSelection:n,time:Date.now()}}function Dc(e){return{type:"TOGGLE_BLOCK_MODE",clientId:e}}function Rc(){return{type:"START_TYPING"}}function Ac(){return{type:"STOP_TYPING"}}function Mc(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return{type:"START_DRAGGING_BLOCKS",clientIds:e}}function Lc(){return{type:"STOP_DRAGGING_BLOCKS"}}function Fc(){return{type:"ENTER_FORMATTED_TEXT"}}function Vc(){return{type:"EXIT_FORMATTED_TEXT"}}function Hc(e,t,n,r){return{type:"SELECTION_CHANGE",clientId:e,attributeKey:t,startOffset:n,endOffset:r}}function zc(e,t,n){var r=Object(c.getDefaultBlockName)();if(r)return _c(Object(c.createBlock)(r,e),n,t)}function Uc(e,t){return{type:"UPDATE_BLOCK_LIST_SETTINGS",clientId:e,settings:t}}function Gc(e){return{type:"UPDATE_SETTINGS",settings:e}}function Kc(e,t){return{type:"SAVE_REUSABLE_BLOCK_SUCCESS",id:e,updatedId:t}}function Wc(){return{type:"MARK_LAST_CHANGE_AS_PERSISTENT"}}function qc(){return{type:"MARK_NEXT_CHANGE_AS_NOT_PERSISTENT"}}function $c(){return{type:"MARK_AUTOMATIC_CHANGE"}}function Yc(){var e,t=arguments;return Or.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return e=!(t.length>0&&void 0!==t[0])||t[0],n.next=3,{type:"SET_NAVIGATION_MODE",isNavigationMode:e};case 3:e?Object(Le.speak)(Object(g.__)("You are currently in navigation mode. Navigate blocks using the Tab key and Arrow keys. Use Left and Right Arrow keys to move between nesting levels. To exit navigation mode and edit the selected block, press Enter.")):Object(Le.speak)(Object(g.__)("You are currently in edit mode. To return to the navigation mode, press Escape."));case 4:case"end":return n.stop()}}),Yo)}function Xc(){var e,t=arguments;return Or.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return e=t.length>0&&void 0!==t[0]?t[0]:null,n.next=3,{type:"SET_BLOCK_MOVING_MODE",hasBlockMovingClientId:e};case 3:e&&Object(Le.speak)(Object(g.__)("Use the Tab key and Arrow keys to choose new block location. Use Left and Right Arrow keys to move between nesting levels. Once location is selected press Enter or Space to move the block."));case 4:case"end":return n.stop()}}),Xo)}function Qc(e){var t,n,r,o,i,a,l=arguments;return Or.a.wrap((function(s){for(;;)switch(s.prev=s.next){case 0:if(t=!(l.length>1&&void 0!==l[1])||l[1],e||e.length){s.next=3;break}return s.abrupt("return");case 3:return s.next=5,v.controls.select("core/block-editor","getBlocksByClientId",e);case 5:return n=s.sent,s.next=8,v.controls.select("core/block-editor","getBlockRootClientId",e[0]);case 8:if(r=s.sent,!Object(f.some)(n,(function(e){return!e}))){s.next=11;break}return s.abrupt("return");case 11:if(o=n.map((function(e){return e.name})),!Object(f.some)(o,(function(e){return!Object(c.hasBlockSupport)(e,"multiple",!0)}))){s.next=14;break}return s.abrupt("return");case 14:return s.next=16,v.controls.select("core/block-editor","getBlockIndex",Object(f.last)(Object(f.castArray)(e)),r);case 16:return i=s.sent,a=n.map((function(e){return Object(c.cloneBlock)(e)})),s.next=20,Ec(a,i+1,r,t);case 20:if(!(a.length>1&&t)){s.next=23;break}return s.next=23,bc(Object(f.first)(a).clientId,Object(f.last)(a).clientId);case 23:return s.abrupt("return",a.map((function(e){return e.clientId})));case 24:case"end":return s.stop()}}),Qo)}function Zc(e){var t,n;return Or.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(e){r.next=2;break}return r.abrupt("return");case 2:return r.next=4,v.controls.select("core/block-editor","getBlockRootClientId",e);case 4:return t=r.sent,r.next=7,v.controls.select("core/block-editor","getTemplateLock",t);case 7:if(!r.sent){r.next=10;break}return r.abrupt("return");case 10:return r.next=12,v.controls.select("core/block-editor","getBlockIndex",e,t);case 12:return n=r.sent,r.next=15,zc({},t,n);case 15:return r.abrupt("return",r.sent);case 16:case"end":return r.stop()}}),Zo)}function Jc(e){var t,n;return Or.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(e){r.next=2;break}return r.abrupt("return");case 2:return r.next=4,v.controls.select("core/block-editor","getBlockRootClientId",e);case 4:return t=r.sent,r.next=7,v.controls.select("core/block-editor","getTemplateLock",t);case 7:if(!r.sent){r.next=10;break}return r.abrupt("return");case 10:return r.next=12,v.controls.select("core/block-editor","getBlockIndex",e,t);case 12:return n=r.sent,r.next=15,zc({},t,n+1);case 15:return r.abrupt("return",r.sent);case 16:case"end":return r.stop()}}),Jo)}function ei(e,t){return{type:"TOGGLE_BLOCK_HIGHLIGHT",clientId:e,isHighlighted:t}}function ti(e){return Or.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ei(e,!0);case 2:return t.next=4,{type:"SLEEP",duration:150};case 4:return t.next=6,ei(e,!1);case 6:case"end":return t.stop()}}),ec)}function ni(e,t){return{type:"SET_HAS_CONTROLLED_INNER_BLOCKS",hasControlledInnerBlocks:t,clientId:e}}var ri=n(42);function oi(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return ci(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ci(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,i=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return i=e.done,e},e:function(e){a=!0,c=e},f:function(){try{i||null==n.return||n.return()}finally{if(a)throw c}}}}function ci(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function ii(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ai(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ii(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ii(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var li=Object(u.createElement)(h.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(h.Rect,{x:"0",fill:"none",width:"24",height:"24"}),Object(u.createElement)(h.G,null,Object(u.createElement)(h.Path,{d:"M19 3H5c-1.105 0-2 .895-2 2v14c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V5c0-1.105-.895-2-2-2zM6 6h5v5H6V6zm4.5 13C9.12 19 8 17.88 8 16.5S9.12 14 10.5 14s2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5zm3-6l3-5 3 5h-6z"}))),si=[];function ui(e,t){var n=e.blocks.byClientId[t];if("web"!==u.Platform.OS&&"core/social-link"===(null==n?void 0:n.name)){var r=e.blocks.attributes[t].service;return r?"".concat("core/social-link","-").concat(r):"core/social-link"}return n?n.name:null}function di(e,t){var n=e.blocks.byClientId[t];return!!n&&n.isValid}function bi(e,t){return e.blocks.byClientId[t]?e.blocks.attributes[t]:null}var fi=Object(ri.a)((function(e,t){var n=e.blocks.byClientId[t];return n?ai(ai({},n),{},{attributes:bi(e,t),innerBlocks:Ma(e,t)?si:mi(e,t)}):null}),(function(e,t){return[e.blocks.cache[t]]})),pi=Object(ri.a)((function(e,t){var n=e.blocks.byClientId[t];return n?ai(ai({},n),{},{attributes:bi(e,t)}):null}),(function(e,t){return[e.blocks.byClientId[t],e.blocks.attributes[t]]})),mi=Object(ri.a)((function(e,t){return Object(f.map)(Xi(e,t),(function(t){return fi(e,t)}))}),(function(e,t){return Object(f.map)(e.blocks.order[t||""],(function(t){return e.blocks.cache[t]}))})),vi=Object(ri.a)((function(e,t){var n=e.blocks.byClientId[t];return n?ai(ai({},n),{},{attributes:bi(e,t),innerBlocks:Oi(e,t)}):null}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]})),Oi=Object(ri.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Object(f.map)(Xi(e,t),(function(t){return vi(e,t)}))}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]})),gi=function e(t,n){return Object(f.flatMap)(n,(function(n){var r=Xi(t,n);return[].concat(Object(ne.a)(r),Object(ne.a)(e(t,r)))}))},hi=Object(ri.a)((function(e){var t=Xi(e);return[].concat(Object(ne.a)(t),Object(ne.a)(gi(e,t)))}),(function(e){return[e.blocks.order]})),ji=Object(ri.a)((function(e,t){var n=hi(e);return t?Object(f.reduce)(n,(function(n,r){return e.blocks.byClientId[r].name===t?n+1:n}),0):n.length}),(function(e){return[e.blocks.order,e.blocks.byClientId]})),ki=Object(ri.a)((function(e,t){return Object(f.map)(Object(f.castArray)(t),(function(t){return fi(e,t)}))}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]}));function yi(e,t){return Xi(e,t).length}function _i(e){return e.selectionStart}function Ei(e){return e.selectionEnd}function Ci(e){return e.selectionStart.clientId}function Si(e){return e.selectionEnd.clientId}function wi(e){var t=Hi(e).length;return t||(e.selectionStart.clientId?1:0)}function Ii(e){var t=e.selectionStart,n=e.selectionEnd;return!!t.clientId&&t.clientId===n.clientId}function Bi(e){var t=e.selectionStart,n=e.selectionEnd,r=t.clientId;return r&&r===n.clientId?r:null}function xi(e){var t=Bi(e);return t?fi(e,t):null}function Pi(e,t){return void 0!==e.blocks.parents[t]?e.blocks.parents[t]:null}var Ti=Object(ri.a)((function(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=[],o=t;e.blocks.parents[o];)o=e.blocks.parents[o],r.push(o);return n?r:r.reverse()}),(function(e){return[e.blocks.parents]})),Ni=Object(ri.a)((function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=Ti(e,t,r);return Object(f.map)(Object(f.filter)(Object(f.map)(o,(function(t){return{id:t,name:ui(e,t)}})),(function(e){var t=e.name;return Array.isArray(n)?n.includes(t):t===n})),(function(e){return e.id}))}),(function(e){return[e.blocks.parents]}));function Di(e,t){var n,r=t;do{n=r,r=e.blocks.parents[r]}while(r);return n}function Ri(e,t){for(var n,r=Bi(e),o=[].concat(Object(ne.a)(Ti(e,t)),[t]),c=[].concat(Object(ne.a)(Ti(e,r)),[r]),i=Math.min(o.length,c.length),a=0;a<i&&o[a]===c[a];a++)n=o[a];return n}function Ai(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;if(void 0===t&&(t=Bi(e)),void 0===t&&(t=n<0?Ui(e):Gi(e)),!t)return null;var r=Pi(e,t);if(null===r)return null;var o=e.blocks.order,c=o[r],i=c.indexOf(t),a=i+1*n;return a<0||a===c.length?null:c[a]}function Mi(e,t){return Ai(e,t,-1)}function Li(e,t){return Ai(e,t,1)}function Fi(e){return e.initialPosition}var Vi=Object(ri.a)((function(e){var t=e.selectionStart,n=e.selectionEnd;if(void 0===t.clientId||void 0===n.clientId)return si;if(t.clientId===n.clientId)return[t.clientId];var r=Pi(e,t.clientId);if(null===r)return si;var o=Xi(e,r),c=o.indexOf(t.clientId),i=o.indexOf(n.clientId);return c>i?o.slice(i,c+1):o.slice(c,i+1)}),(function(e){return[e.blocks.order,e.selectionStart.clientId,e.selectionEnd.clientId]}));function Hi(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?si:Vi(e)}var zi=Object(ri.a)((function(e){var t=Hi(e);return t.length?t.map((function(t){return fi(e,t)})):si}),(function(e){return[].concat(Object(ne.a)(Vi.getDependants(e)),[e.blocks.byClientId,e.blocks.order,e.blocks.attributes])}));function Ui(e){return Object(f.first)(Hi(e))||null}function Gi(e){return Object(f.last)(Hi(e))||null}function Ki(e,t){return Ui(e)===t}function Wi(e,t){return-1!==Hi(e).indexOf(t)}var qi=Object(ri.a)((function(e,t){for(var n=t,r=!1;n&&!r;)r=Wi(e,n=Pi(e,n));return r}),(function(e){return[e.blocks.order,e.selectionStart.clientId,e.selectionEnd.clientId]}));function $i(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?null:t.clientId||null}function Yi(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?null:n.clientId||null}function Xi(e,t){return e.blocks.order[t||""]||si}function Qi(e,t,n){return Xi(e,n).indexOf(t)}function Zi(e,t){var n=e.selectionStart,r=e.selectionEnd;return n.clientId===r.clientId&&n.clientId===t}function Ji(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return Object(f.some)(Xi(e,t),(function(t){return Zi(e,t)||Wi(e,t)||n&&Ji(e,t,n)}))}function ea(e,t){if(!t)return!1;var n=Hi(e),r=n.indexOf(t);return r>-1&&r<n.length-1}function ta(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId!==n.clientId}function na(e){return e.isMultiSelecting}function ra(e){return e.isSelectionEnabled}function oa(e,t){return e.blocksMode[t]||"visual"}function ca(e){return e.isTyping}function ia(e){return!!e.draggedBlocks.length}function aa(e){return e.draggedBlocks}function la(e,t){return e.draggedBlocks.includes(t)}function sa(e,t){if(!ia(e))return!1;var n=Ti(e,t);return Object(f.some)(n,(function(t){return la(e,t)}))}function ua(e){return e.isCaretWithinFormattedText}function da(e){var t,n,r=e.insertionPoint,o=e.selectionEnd;if(null!==r)return r;var c=o.clientId;return c?(t=Pi(e,c)||void 0,n=Qi(e,o.clientId,t)+1):n=Xi(e).length,{rootClientId:t,index:n}}function ba(e){return e.insertionPointVisibility}function fa(e){return e.template.isValid}function pa(e){return e.settings.template}function ma(e,t){if(!t)return e.settings.templateLock;var n=Ca(e,t);return n?n.templateLock:null}var va=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return Object(f.isBoolean)(e)?e:Object(f.isArray)(e)?!(!e.includes("core/post-content")||null!==t)||e.includes(t):n},o=Object(c.getBlockType)(t);if(!o)return!1;var i=Sa(e),a=i.allowedBlockTypes,l=r(a,t,!0);if(!l)return!1;var s=!!ma(e,n);if(s)return!1;var u=Ca(e,n);if(n&&void 0===u)return!1;var d=null==u?void 0:u.allowedBlocks,b=r(d,t),p=o.parent,m=ui(e,n),v=r(p,m);return null!==b&&null!==v?b||v:null!==b?b:null===v||v},Oa=Object(ri.a)(va,(function(e,t,n){return[e.blockListSettings[n],e.blocks.byClientId[n],e.settings.allowedBlockTypes,e.settings.templateLock]}));function ga(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return t.every((function(t){return Oa(e,ui(e,t),n)}))}function ha(e,t){var n,r;return null!==(n=null===(r=e.preferences.insertUsage)||void 0===r?void 0:r[t])&&void 0!==n?n:null}var ja=function(e,t,n){return!!Object(c.hasBlockSupport)(t,"inserter",!0)&&va(e,t.name,n)},ka=function(e){return function(t){return ai(ai({},e),{},{id:"".concat(e.id,"-").concat(t.name),icon:t.icon||e.icon,title:t.title||e.title,description:t.description||e.description,example:t.hasOwnProperty("example")?t.example:e.example,initialAttributes:ai(ai({},e.initialAttributes),t.attributes),innerBlocks:t.innerBlocks,keywords:t.keywords||e.keywords})}},ya=Object(ri.a)((function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,r=function(e,t){if(!e)return t;var n=Date.now()-e;switch(!0){case n<36e5:return 4*t;case n<864e5:return 2*t;case n<6048e5:return t/2;default:return t/4}},o=function(t){var n=t.name,o=!1;Object(c.hasBlockSupport)(t.name,"multiple",!0)||(o=Object(f.some)(ki(e,hi(e)),{name:t.name}));var i=ha(e,n)||{},a=i.time,l=i.count,s=void 0===l?0:l,u=t.variations.filter((function(e){var t=e.scope;return!t||t.includes("inserter")}));return{id:n,name:t.name,initialAttributes:{},title:t.title,description:t.description,icon:t.icon,category:t.category,keywords:t.keywords,variations:u,example:t.example,isDisabled:o,utility:1,frecency:r(a,s)}},i=function(t){var n,o="core/block/".concat(t.id),i=Ba(e,t.id);1===i.length&&(n=Object(c.getBlockType)(i[0].name));var a=ha(e,o)||{},l=a.time,s=a.count,u=r(l,void 0===s?0:s);return{id:o,name:"core/block",initialAttributes:{ref:t.id},title:t.title.raw,icon:n?n.icon:li,category:"reusable",keywords:[],isDisabled:!1,utility:1,frecency:u}},a=Object(c.getBlockTypes)().filter((function(t){return ja(e,t,n)})).map(o),l=va(e,"core/block",n)?Ta(e).map(i):[],s=a.filter((function(e){var t=e.variations;return!(void 0===t?[]:t).some((function(e){return e.isDefault}))})),u=[],d=oi(a);try{for(d.s();!(t=d.n()).done;){var b=t.value,p=b.variations,m=void 0===p?[]:p;if(m.length){var v=ka(b);u.push.apply(u,Object(ne.a)(m.map(v)))}}}catch(e){d.e(e)}finally{d.f()}return[].concat(Object(ne.a)(s),u,Object(ne.a)(l))}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.blocks.order,e.preferences.insertUsage,e.settings.allowedBlockTypes,e.settings.templateLock,Ta(e),Object(c.getBlockTypes)()]})),_a=Object(ri.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=Object(f.some)(Object(c.getBlockTypes)(),(function(n){return ja(e,n,t)}));if(n)return!0;var r=va(e,"core/block",t)&&Ta(e).length>0;return r}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.settings.allowedBlockTypes,e.settings.templateLock,Ta(e),Object(c.getBlockTypes)()]})),Ea=Object(ri.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(t)return Object(f.filter)(Object(c.getBlockTypes)(),(function(n){return ja(e,n,t)}))}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.settings.allowedBlockTypes,e.settings.templateLock,Object(c.getBlockTypes)()]}));function Ca(e,t){return e.blockListSettings[t]}function Sa(e){return e.settings}function wa(e){return e.blocks.isPersistentChange}var Ia=Object(ri.a)((function(e,t){return Object(f.filter)(e.blockListSettings,(function(e,n){return t.includes(n)}))}),(function(e){return[e.blockListSettings]})),Ba=Object(ri.a)((function(e,t){var n=Object(f.find)(Ta(e),(function(e){return e.id===t}));return n?Object(c.parse)("string"==typeof n.content.raw?n.content.raw:n.content):null}),(function(e){return[Ta(e)]}));function xa(e){return e.blocks.isIgnoredChange}function Pa(e){return e.lastBlockAttributesChange}function Ta(e){var t,n;return null!==(t=null==e||null===(n=e.settings)||void 0===n?void 0:n.__experimentalReusableBlocks)&&void 0!==t?t:si}function Na(e){return e.isNavigationMode}function Da(e){return e.hasBlockMovingClientId}function Ra(e){return!!e.automaticChangeStatus}function Aa(e,t){return e.highlightedBlock===t}function Ma(e,t){return!!e.blocks.controlledInnerBlocks[t]}var La=Object(ri.a)((function(e,t){if(!t.length)return null;var n=Bi(e);if(t.includes(ui(e,n)))return n;var r=Hi(e),o=Ni(e,n||r[0],t);return o?Object(f.last)(o):null}),(function(e,t){return[e.selectionStart.clientId,e.selectionEnd.clientId,t]}));function Fa(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Va(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fa(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fa(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ha={MERGE_BLOCKS:function(e,t){var n=t.dispatch,r=t.getState(),o=Object(re.a)(e.blocks,2),a=o[0],l=o[1],s=fi(r,a),u=Object(c.getBlockType)(s.name);if(u.merge){var d=fi(r,l),b=Object(c.getBlockType)(d.name),p=_i(r),m=p.clientId,v=p.attributeKey,O=p.offset,g=(m===a?u:b).attributes[v],h=(m===a||m===l)&&void 0!==v&&void 0!==O&&!!g;g||("number"==typeof v?window.console.error("RichText needs an identifier prop that is the block attribute key of the attribute it controls. Its type is expected to be a string, but was ".concat(Object(Ao.a)(v))):window.console.error("The RichText identifier prop does not match any attributes defined by the block."));var j=Object(c.cloneBlock)(s),k=Object(c.cloneBlock)(d);if(h){var y=m===a?j:k,_=y.attributes[v],E=g.multiline,C=g.__unstableMultilineWrapperTags,S=g.__unstablePreserveWhiteSpace,w=Object(i.insert)(Object(i.create)({html:_,multilineTag:E,multilineWrapperTags:C,preserveWhiteSpace:S}),"",O,O);y.attributes[v]=Object(i.toHTMLString)({value:w,multilineTag:E,preserveWhiteSpace:S})}var I=s.name===d.name?[k]:Object(c.switchToBlockType)(k,s.name);if(I&&I.length){var B=u.merge(j.attributes,I[0].attributes);if(h){var x=Object(f.findKey)(B,(function(e){return"string"==typeof e&&-1!==e.indexOf("")})),P=B[x],T=u.attributes[x],N=T.multiline,D=T.__unstableMultilineWrapperTags,R=T.__unstablePreserveWhiteSpace,A=Object(i.create)({html:P,multilineTag:N,multilineWrapperTags:D,preserveWhiteSpace:R}),M=A.text.indexOf(""),L=Object(i.remove)(A,M,M+1),F=Object(i.toHTMLString)({value:L,multilineTag:N,preserveWhiteSpace:R});B[x]=F,n(Hc(s.clientId,x,M,M))}n(vc([s.clientId,d.clientId],[Va(Va({},s),{},{attributes:Va(Va({},s.attributes),B)})].concat(Object(ne.a)(I.slice(1)))))}}else n(ac(s.clientId))},RESET_BLOCKS:[function(e,t){var n=t.getState(),r=pa(n),o=ma(n),i=!r||"all"!==o||Object(c.doBlocksMatchTemplate)(e.blocks,r);if(i!==fa(n))return Ic(i)}],MULTI_SELECT:function(e,t){var n=wi((0,t.getState)());Object(Le.speak)(Object(g.sprintf)(Object(g._n)("%s block selected.","%s blocks selected.",n),n),"assertive")},SYNCHRONIZE_TEMPLATE:function(e,t){var n=(0,t.getState)(),r=mi(n),o=pa(n);return nc(Object(c.synchronizeBlocksWithTemplate)(r,o))},MARK_AUTOMATIC_CHANGE:function(e,t){var n=window,r=n.setTimeout,o=n.requestIdleCallback;(void 0===o?function(e){return r(e,100)}:o)((function(){t.dispatch({type:"MARK_AUTOMATIC_CHANGE_FINAL"})}))}};var za=function(e){var t,n=[No()(Ha),Ro.a],r=function(){throw new Error("Dispatching while constructing your middleware is not allowed. Other middleware would not be applied to this dispatch.")},o={getState:e.getState,dispatch:function(){return r.apply(void 0,arguments)}};return t=n.map((function(e){return e(o)})),r=f.flowRight.apply(void 0,Object(ne.a)(t))(e.dispatch),e.dispatch=r,e};function Ua(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ga(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ua(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ua(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ka={reducer:Po,selectors:o,actions:r,controls:{SLEEP:function(e){var t=e.duration;return new Promise((function(e){setTimeout(e,t)}))}}},Wa=Object(v.registerStore)("core/block-editor",Ga(Ga({},Ka),{},{persist:["preferences"]}));za(Wa);function qa(e){var t=e.clientId,n=void 0===t?null:t,r=e.value,o=e.selectionStart,c=e.selectionEnd,i=e.onChange,a=void 0===i?f.noop:i,l=e.onInput,s=void 0===l?f.noop:l,d=Object(v.useRegistry)(),b=d.dispatch("core/block-editor"),p=b.resetBlocks,m=b.resetSelection,O=b.replaceInnerBlocks,g=b.setHasControlledInnerBlocks,h=b.__unstableMarkNextChangeAsNotPersistent,j=d.select("core/block-editor"),k=j.getBlockName,y=j.getBlocks,_=Object(u.useRef)({incoming:null,outgoing:[]}),E=Object(u.useRef)(s),C=Object(u.useRef)(a);Object(u.useEffect)((function(){E.current=s,C.current=a}),[s,a]),Object(u.useEffect)((function(){var e,t=d.select("core/block-editor"),r=t.getSelectionStart,o=t.getSelectionEnd,c=t.isLastBlockChangePersistent,i=t.__unstableIsLastBlockChangeIgnored,a=c(),l=!1,s=d.subscribe((function(){if(null===n||null!==k(n)){var t=c(),s=y(n),u=s!==e;if(e=s,u&&(_.current.incoming||i()))return _.current.incoming=null,void(a=t);if(u||l&&!u&&t&&!a)a=t,_.current.outgoing.push(e),(a?C.current:E.current)(e,{selectionStart:r(),selectionEnd:o()});l=u}}));return function(){return s()}}),[d,n]),Object(u.useEffect)((function(){_.current.outgoing.includes(r)?Object(f.last)(_.current.outgoing)===r&&(_.current.outgoing=[]):y(n)!==r&&(_.current.outgoing=[],_.current.incoming=r,r&&(h(),n?(g(n,!0),h(),O(n,r,!1)):p(r)),o&&c&&m(o,c))}),[r,n])}var $a=Object(p.createHigherOrderComponent)((function(e){return Object(v.withRegistry)((function(t){var n=t.useSubRegistry,r=void 0===n||n,o=t.registry,c=Object(he.a)(t,["useSubRegistry","registry"]);if(!r)return Object(u.createElement)(e,Object(l.a)({registry:o},c));var i=Object(u.useState)(null),a=Object(re.a)(i,2),s=a[0],d=a[1];return Object(u.useEffect)((function(){var e=Object(v.createRegistry)({},o),t=e.registerStore("core/block-editor",Ka);za(t),d(e)}),[o]),s?Object(u.createElement)(v.RegistryProvider,{value:s},Object(u.createElement)(e,Object(l.a)({registry:s},c))):null}))}),"withRegistryProvider")((function(e){var t=e.children,n=e.settings,r=Object(v.useDispatch)("core/block-editor").updateSettings;return Object(u.useEffect)((function(){r(n)}),[n]),qa(e),t})),Ya=n(69);var Xa=Object(p.compose)(Object(v.withSelect)((function(e,t){var n=e("core/block-editor"),r=n.getBlockCount,o=n.getBlockName,i=n.isBlockValid,a=n.getSettings,l=n.getTemplateLock,s=!r(t.rootClientId),u=o(t.lastBlockClientId)===Object(c.getDefaultBlockName)(),d=i(t.lastBlockClientId),b=a().bodyPlaceholder;return{isVisible:s||!u||!d,showPrompt:s,isLocked:!!l(t.rootClientId),placeholder:b}})),Object(v.withDispatch)((function(e,t){var n=e("core/block-editor"),r=n.insertDefaultBlock,o=n.startTyping;return{onAppend:function(){var e=t.rootClientId;r(void 0,e),o()}}})))((function(e){var t=e.isLocked,n=e.isVisible,r=e.onAppend,o=e.showPrompt,c=e.placeholder,i=e.rootClientId;if(t||!n)return null;var a=Object(Ya.decodeEntities)(c)||Object(g.__)("Start writing or type / to choose a block");return Object(u.createElement)("div",{"data-root-client-id":i||"",className:"wp-block block-editor-default-block-appender"},Object(u.createElement)(Zr.a,{role:"button","aria-label":Object(g.__)("Add block"),className:"block-editor-default-block-appender__content",readOnly:!0,onFocus:r,value:o?a:""}),Object(u.createElement)(cs,{rootClientId:i,position:"bottom right",isAppender:!0,__experimentalIsQuick:!0}))}));var Qa=Object(u.forwardRef)((function(e,t){var n=e.rootClientId,r=e.className,o=e.__experimentalSelectBlockOnInsert,c=e.onFocus,i=e.tabIndex;return Object(u.createElement)(cs,{position:"bottom center",rootClientId:n,__experimentalSelectBlockOnInsert:o,__experimentalIsQuick:!0,renderToggle:function(e){var n,o=e.onToggle,a=e.disabled,l=e.isOpen,s=e.blockTitle,d=e.hasSingleBlockType;n=d?Object(g.sprintf)(Object(g._x)("Add %s","directly add the only allowed block"),s):Object(g._x)("Add block","Generic label for block inserter button");var f=!d,p=Object(u.createElement)(h.Button,{ref:t,onFocus:c,tabIndex:i,className:b()(r,"block-editor-button-block-appender"),onClick:o,"aria-haspopup":f?"true":void 0,"aria-expanded":f?l:void 0,disabled:a,label:n},!d&&Object(u.createElement)(h.VisuallyHidden,{as:"span"},n),Object(u.createElement)(so.a,{icon:co.a}));return(f||d)&&(p=Object(u.createElement)(h.Tooltip,{text:n},p)),p},isAppender:!0})})),Za=Object(u.createContext)();function Ja(e){e.stopPropagation()}var el=Object(v.withSelect)((function(e,t){var n=t.rootClientId,r=e("core/block-editor"),o=r.getBlockOrder,i=r.canInsertBlockType,a=r.getTemplateLock,l=r.getSelectedBlockClientId;return{isLocked:!!a(n),blockClientIds:o(n),canInsertDefaultBlock:i(Object(c.getDefaultBlockName)(),n),selectedBlockClientId:l()}}))((function(e){var t,n=e.blockClientIds,r=e.rootClientId,o=e.canInsertDefaultBlock,c=e.isLocked,i=e.renderAppender,a=e.className,l=e.selectedBlockClientId,s=e.tagName,d=void 0===s?"div":s,p=Object(u.useContext)(Za);if(c||!1===i)return null;if(i)t=Object(u.createElement)(i,null);else{var m=!r,v=l===r,O=l&&!n.includes(l);if(!m&&!v&&(!l||O))return null;t=o?Object(u.createElement)(Xa,{rootClientId:r,lastBlockClientId:Object(f.last)(n)}):Object(u.createElement)(Qa,{rootClientId:r,className:"block-list-appender__toggle"})}return Object(u.createElement)(d,{tabIndex:-1,onFocus:Ja,className:b()("block-list-appender","wp-block",a),ref:function(e){e?p.set(r||"",e):p.delete(r||"")}},t)}));function tl(e,t,n,r,o){return function(c){var i=function(e){var t={srcRootClientId:null,srcClientIds:null,srcIndex:null,type:null};if(!e.dataTransfer)return t;try{t=Object.assign(t,JSON.parse(e.dataTransfer.getData("text")))}catch(e){return t}return t}(c),a=i.srcRootClientId,l=i.srcClientIds;if("block"===i.type){var s=n(l[0],a);if(!(a===e&&s===t||l.includes(e)||r(l).some((function(t){return t===e})))){var u=a===e,d=l.length;o(l,a,e,u&&s<t?t-d:t)}}}}function nl(e,t,n,r,o){return function(i){if(n){var a=Object(c.findTransform)(Object(c.getBlockTransforms)("from"),(function(e){return"files"===e.type&&e.isMatch(i)}));if(a){var l=a.transform(i,r);o(l,t,e)}}}}function rl(e,t,n){return function(r){var o=Object(c.pasteHandler)({HTML:r,mode:"BLOCKS"});o.length&&n(o,t,e)}}function ol(e,t){var n=Object(v.useSelect)((function(e){var t=e("core/block-editor");return{getBlockIndex:t.getBlockIndex,getClientIdsOfDescendants:t.getClientIdsOfDescendants,hasUploadPermissions:(0,t.getSettings)().mediaUpload}}),[]),r=n.getBlockIndex,o=n.getClientIdsOfDescendants,c=n.hasUploadPermissions,i=Object(v.useDispatch)("core/block-editor"),a=i.insertBlocks,l=i.moveBlocksToPosition,s=i.updateBlockAttributes;return{onDrop:tl(e,t,r,o,l),onFilesDrop:nl(e,t,c,s,a),onHTMLDrop:rl(e,t,a)}}function cl(e,t,n){var r,o="top"===n||"bottom"===n,c=e.x,i=e.y,a=o?c:i,l=o?i:c,s=o?t.left:t.top,u=o?t.right:t.bottom,d=t[n];return r=a>=s&&a<=u?a:a<u?s:u,Math.sqrt(Math.pow(a-r,2)+Math.pow(l-d,2))}function il(e,t){var n,r,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:["top","bottom","left","right"];return o.forEach((function(o){var c=cl(e,t,o);(void 0===n||c<n)&&(n=c,r=o)})),[n,r]}function al(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ll(e){var t=e.element,n=e.rootClientId,r=void 0===n?"":n,o=Object(u.useState)(null),c=Object(re.a)(o,2),i=c[0],a=c[1],l=Object(v.useSelect)((function(e){var t,n=e("core/block-editor"),o=n.getBlockListSettings;return{isLockedAll:"all"===(0,n.getTemplateLock)(r),orientation:null===(t=o(r))||void 0===t?void 0:t.orientation}}),[r]),d=l.isLockedAll,b=l.orientation,f=ol(r,i),p=Object(h.__unstableUseDropZone)(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?al(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):al(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({element:t,isDisabled:d,withPosition:!0},f)).position;if(Object(u.useEffect)((function(){if(p){var e=function(e,t,n){var r,o,c="horizontal"===n?["left","right"]:["top","bottom"];return e.forEach((function(n,i){if(n.classList.contains("wp-block")){var a=n.getBoundingClientRect(),l=il(t,a,c),s=Object(re.a)(l,2),u=s[0],d=s[1];if(void 0===o||u<o){var b="bottom"===d||"right"===d,f=b?1:0,p=b&&e[i+1]&&e[i+1].classList.contains("is-dragging");o=u,r=i+(f+=p?1:0)}}})),r}(Array.from(t.current.children),p,b);a(void 0===e?0:e)}}),[p]),p)return i}var sl=new Map;function ul(e){var t=e.placeholder,n=e.rootClientId,r=e.renderAppender,o=e.__experimentalAppenderTagName,c=e.wrapperRef;var i=Object(v.useSelect)((function(e){var t,r=e("core/block-editor"),o=r.getBlockOrder,c=r.getBlockListSettings,i=r.getSettings,a=r.getSelectedBlockClientId,l=r.getMultiSelectedBlockClientIds,s=r.hasMultiSelection,u=r.getGlobalBlockCount,d=r.isTyping,b=(0,r.__experimentalGetActiveBlockIdByBlockNames)(i().__experimentalSpotlightEntityBlocks);return{blockClientIds:o(n),selectedBlockClientId:a(),multiSelectedBlockClientIds:l(),orientation:null===(t=c(n))||void 0===t?void 0:t.orientation,hasMultiSelection:s(),enableAnimation:!d()&&u()<=200,activeEntityBlockId:b}}),[n]),a=i.blockClientIds,l=i.selectedBlockClientId,s=i.multiSelectedBlockClientIds,d=i.orientation,f=i.hasMultiSelection,p=i.enableAnimation,m=i.activeEntityBlockId,O=ll({element:c,rootClientId:n}),g=O===a.length;return Object(u.createElement)(u.Fragment,null,a.map((function(e,t){var r=f?s.includes(e):l===e,o=O===t;return Object(u.createElement)(v.AsyncModeProvider,{key:e,value:!r},Object(u.createElement)(xu,{rootClientId:n,clientId:e,index:t,enableAnimation:p,className:b()({"is-drop-target":o,"is-dropping-horizontally":o&&"horizontal"===d,"has-active-entity":m}),activeEntityBlockId:m}))})),a.length<1&&t,Object(u.createElement)(el,{tagName:o,rootClientId:n,renderAppender:r,className:b()({"is-drop-target":g,"is-dropping-horizontally":g&&"horizontal"===d})}))}function dl(e){return Object(u.createElement)(v.AsyncModeProvider,{value:!1},Object(u.createElement)(ul,e))}var bl,fl=Object(u.forwardRef)((function(e,t){var n=e.className,r=e.placeholder,o=e.rootClientId,c=e.renderAppender,i=o?"div":Ou,a=Object(u.useRef)(),l=t||a;return Object(u.createElement)(Za.Provider,{value:sl},Object(u.createElement)(i,{ref:l,className:b()("block-editor-block-list__layout",n)},Object(u.createElement)(dl,{placeholder:r,rootClientId:o,renderAppender:c,wrapperRef:l})))}));function pl(e){var t=e.onClick;return Object(u.createElement)("div",{tabIndex:0,role:"button",onClick:t,onKeyPress:t},Object(u.createElement)(h.Disabled,null,Object(u.createElement)(fl,null)))}var ml=function(e){var t=e.viewportWidth,n=e.__experimentalPadding,r=Object(p.useResizeObserver)(),o=Object(re.a)(r,2),c=o[0],i=o[1].width,a=Object(p.useResizeObserver)(),l=Object(re.a)(a,2),s=l[0],d=l[1].height;bl=bl||Object(p.pure)(fl);var b=(i-2*n)/t;return Object(u.createElement)("div",{className:"block-editor-block-preview__container editor-styles-wrapper","aria-hidden":!0,style:{height:d*b+2*n}},c,Object(u.createElement)(h.Disabled,{style:{transform:"scale(".concat(b,")"),width:t,left:n,right:n,top:n},className:"block-editor-block-preview__content"},s,Object(u.createElement)(bl,null)))};var vl=Object(u.memo)((function(e){var t=e.blocks,n=e.__experimentalPadding,r=void 0===n?0:n,o=e.viewportWidth,c=void 0===o?700:o,i=e.__experimentalLive,a=void 0!==i&&i,l=e.__experimentalOnClick,s=Object(v.useSelect)((function(e){return e("core/block-editor").getSettings()}),[]),d=Object(u.useMemo)((function(){return Object(f.castArray)(t)}),[t]);return t&&0!==t.length?Object(u.createElement)($a,{value:d,settings:s},a?Object(u.createElement)(pl,{onClick:l}):Object(u.createElement)(ml,{viewportWidth:c,__experimentalPadding:r})):null}));function Ol(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function gl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ol(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ol(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var hl=function(e){var t=e.item,n=Object(c.getBlockType)(t.name);return Object(u.createElement)("div",{className:"block-editor-inserter__preview-container"},Object(u.createElement)("div",{className:"block-editor-inserter__preview"},Object(c.isReusableBlock)(t)||n.example?Object(u.createElement)("div",{className:"block-editor-inserter__preview-content"},Object(u.createElement)(vl,{__experimentalPadding:16,viewportWidth:500,blocks:n.example?Object(c.getBlockFromExample)(t.name,{attributes:gl(gl({},n.example.attributes),t.initialAttributes),innerBlocks:n.example.innerBlocks}):Object(c.createBlock)(t.name,t.initialAttributes)})):Object(u.createElement)("div",{className:"block-editor-inserter__preview-content-missing"},Object(g.__)("No Preview Available."))),!Object(c.isReusableBlock)(t)&&Object(u.createElement)(fo,{blockType:t}))},jl=n(52),kl=n(122),yl=n(123);var _l=function(e){var t=e.icon,n=e.onClick,r=e.isDisabled,o=e.title,c=e.className,i=e.composite,a=Object(he.a)(e,["icon","onClick","isDisabled","title","className","composite"]),s=t?{backgroundColor:t.background,color:t.foreground}:{};return Object(u.createElement)("div",{className:"block-editor-block-types-list__list-item"},Object(u.createElement)(yl.a,Object(l.a)({role:"option",as:h.Button},i,{className:b()("block-editor-block-types-list__item",c),onClick:function(e){e.preventDefault(),n()},disabled:r},a),Object(u.createElement)("span",{className:"block-editor-block-types-list__item-icon",style:s},Object(u.createElement)(qn,{icon:t,showColors:!0})),Object(u.createElement)("span",{className:"block-editor-block-types-list__item-title"},o)))};var El=function(e){var t=e.items,n=void 0===t?[]:t,r=e.onSelect,o=e.onHover,i=void 0===o?function(){}:o,a=e.children,s=e.label,d=Object(jl.g)(),b=n.reduce((function(e,t){return e+"--"+t.id}),"");return Object(u.useEffect)((function(){d.unstable_sort()}),[d.unstable_sort,b]),Object(u.createElement)(kl.a,Object(l.a)({},d,{role:"listbox",className:"block-editor-block-types-list","aria-label":s}),n.map((function(e){return Object(u.createElement)(_l,{key:e.id,className:Object(c.getBlockMenuDefaultClassName)(e.id),icon:e.icon,onClick:function(){r(e),i(null)},onFocus:function(){return i(e)},onMouseEnter:function(){return i(e)},onMouseLeave:function(){return i(null)},onBlur:function(){return i(null)},isDisabled:e.isDisabled,title:e.title,composite:d})})),a)};function Cl(e){var t=e.rootClientId,n=e.children,r=Object(v.useSelect)((function(e){var n=(0,e("core/blocks").getBlockType)((0,e("core/block-editor").getBlockName)(t));return{rootBlockTitle:n&&n.title,rootBlockIcon:n&&n.icon}})),o=r.rootBlockTitle,c=r.rootBlockIcon;return Object(u.createElement)("div",{className:"block-editor-inserter__child-blocks"},(c||o)&&Object(u.createElement)("div",{className:"block-editor-inserter__parent-block-header"},Object(u.createElement)(qn,{icon:c,showColors:!0}),o&&Object(u.createElement)("h2",null,o)),n)}var Sl=Object(h.createSlotFill)("__experimentalInserterMenuExtension"),wl=Sl.Fill,Il=Sl.Slot;wl.Slot=Il;var Bl=wl;var xl=function(e){var t=e.title,n=e.icon,r=e.children;return Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{className:"block-editor-inserter__panel-header"},Object(u.createElement)("h2",{className:"block-editor-inserter__panel-title"},t),Object(u.createElement)(h.Icon,{icon:n})),Object(u.createElement)("div",{className:"block-editor-inserter__panel-content"},r))};var Pl=function(){return Object(u.createElement)("div",{className:"block-editor-inserter__no-results"},Object(u.createElement)(so.a,{className:"block-editor-inserter__no-results-icon",icon:Wn.a}),Object(u.createElement)("p",null,Object(g.__)("No results found.")))};function Tl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var Nl=Object(h.withSpokenMessages)((function(e){var t=e.rootClientId,n=e.onInsert,r=e.onHover,o=e.filterValue,c=e.debouncedSpeak,i=e.showMostUsedBlocks,a=Kn(t,n),l=Object(re.a)(a,4),d=l[0],b=l[1],p=l[2],m=l[3],O=Object(v.useSelect)((function(e){var n=e("core/block-editor").getBlockName;return!!(0,e("core/blocks").getChildBlockNames)(n(t)).length}),[t]),h=Object(u.useMemo)((function(){return zn(d,b,p,o)}),[o,d,b,p]),j=Object(u.useMemo)((function(){return Object(f.orderBy)(d,["frecency"],["desc"]).slice(0,6)}),[d]),k=Object(u.useMemo)((function(){return h.filter((function(e){return!e.category}))}),[h]),y=Object(u.useMemo)((function(){var e=function(e){return Object(f.findIndex)(b,(function(t){return t.slug===e.category}))};return Object(f.flow)((function(e){return e.filter((function(e){return e.category&&"reusable"!==e.category}))}),(function(t){return Object(f.sortBy)(t,e)}),(function(e){return Object(f.groupBy)(e,"category")}))(h)}),[h,b]),_=Object(u.useMemo)((function(){var e=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Tl(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Tl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},p);return Object.keys(p).forEach((function(t){e[t]=h.filter((function(e){return function(e){return e.name.split("/")[0]}(e)===t})),0===e[t].length&&delete e[t]})),e}),[h,p]);Object(u.useEffect)((function(){return function(){return r(null)}}),[]),Object(u.useEffect)((function(){var e=Object(g.sprintf)(Object(g._n)("%d result found.","%d results found.",h.length),h.length);c(e)}),[o,c]);var E=!Object(f.isEmpty)(h);return Object(u.createElement)("div",null,O&&Object(u.createElement)(Cl,{rootClientId:t},Object(u.createElement)(El,{items:h,onSelect:m,onHover:r,label:Object(g.__)("Child Blocks")})),i&&!O&&!!j.length&&!o&&Object(u.createElement)(xl,{title:Object(g._x)("Most used","blocks")},Object(u.createElement)(El,{items:j,onSelect:m,onHover:r,label:Object(g._x)("Most used","blocks")})),!O&&Object(f.map)(b,(function(e){var t=y[e.slug];return t&&t.length?Object(u.createElement)(xl,{key:e.slug,title:e.title,icon:e.icon},Object(u.createElement)(El,{items:t,onSelect:m,onHover:r,label:e.title})):null})),!O&&!!k.length&&Object(u.createElement)(xl,{className:"block-editor-inserter__uncategorized-blocks-panel",title:Object(g.__)("Uncategorized")},Object(u.createElement)(El,{items:k,onSelect:m,onHover:r,label:Object(g.__)("Uncategorized")})),!O&&Object(f.map)(p,(function(e,t){var n=_[t];return n&&n.length?Object(u.createElement)(xl,{key:t,title:e.title,icon:e.icon},Object(u.createElement)(El,{items:n,onSelect:m,onHover:r,label:e.title})):null})),Object(u.createElement)(Bl.Slot,{fillProps:{onSelect:m,onHover:r,filterValue:o,hasItems:E}},(function(e){return e.length?e:E?null:Object(u.createElement)(Pl,null)})))}));var Dl=function(e){var t,n=e.selectedCategory,r=e.patternCategories,o=e.onClickCategory,c=e.children;return Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{className:b()("block-editor-inserter__panel-header","block-editor-inserter__panel-header-patterns")},Object(u.createElement)(h.SelectControl,{className:"block-editor-inserter__panel-dropdown",label:Object(g.__)("Filter patterns"),hideLabelFromVision:!0,value:n.name,onChange:function(e){o(r.find((function(t){return e===t.name})))},options:(t=[],r.map((function(e){return t.push({value:e.name,label:e.label})})),t)})),Object(u.createElement)("div",{className:"block-editor-inserter__panel-content"},c))},Rl=function(e){var t=Object(v.useSelect)((function(e){var t=e("core/block-editor").getSettings();return{patterns:t.__experimentalBlockPatterns,patternCategories:t.__experimentalBlockPatternCategories}}),[]),n=t.patternCategories,r=t.patterns,o=Object(v.useDispatch)("core/notices").createSuccessNotice;return[r,n,Object(u.useCallback)((function(t,n){e(Object(f.map)(n,(function(e){return Object(c.cloneBlock)(e)})),t.name),o(Object(g.sprintf)(Object(g.__)('Block pattern "%s" inserted.'),t.title),{type:"snackbar"})}),[])]};function Al(e){var t=e.pattern,n=e.onClick,r=t.content,o=t.viewportWidth,i=Object(u.useMemo)((function(){return Object(c.parse)(r)}),[r]),a=Object(p.useInstanceId)(Al),l="block-editor-block-patterns-list__item-description-".concat(a);return Object(u.createElement)("div",{className:"block-editor-block-patterns-list__item",role:"button",onClick:function(){return n(t,i)},onKeyDown:function(e){st.ENTER!==e.keyCode&&st.SPACE!==e.keyCode||n(t,i)},tabIndex:0,"aria-label":t.title,"aria-describedby":t.description?l:void 0},Object(u.createElement)(vl,{blocks:i,viewportWidth:o}),Object(u.createElement)("div",{className:"block-editor-block-patterns-list__item-title"},t.title),!!t.description&&Object(u.createElement)(h.VisuallyHidden,{id:l},t.description))}function Ml(){return Object(u.createElement)("div",{className:"block-editor-block-patterns-list__item is-placeholder"})}var Ll=function(e){var t=e.blockPatterns,n=e.shownPatterns,r=e.onClickPattern;return t.map((function(e){return n.includes(e)?Object(u.createElement)(Al,{key:e.name,pattern:e,onClick:r}):Object(u.createElement)(Ml,{key:e.name})}))};function Fl(e){var t=e.filterValue,n=e.onInsert,r=Rl(n),o=Object(re.a)(r,3),c=o[0],i=o[2],a=Object(u.useMemo)((function(){return Un(c,t)}),[t,c]),l=Object(p.useAsyncList)(a);if(t)return a.length?Object(u.createElement)(xl,{title:Object(g.__)("Search Results")},Object(u.createElement)(Ll,{shownPatterns:l,blockPatterns:a,onClickPattern:i})):Object(u.createElement)(Pl,null)}function Vl(e){var t=e.onInsert,n=e.selectedCategory,r=e.onClickCategory,o=Rl(t),c=Object(re.a)(o,3),i=c[0],a=c[1],l=c[2],s=Object(u.useMemo)((function(){return a.filter((function(e){return i.some((function(t){return t.categories.includes(e.name)}))}))}),[i,a]),d=n||s[0];Object(u.useEffect)((function(){i.some((function(e){return b(e)===1/0}))&&!s.find((function(e){return"uncategorized"===e.name}))&&s.push({name:"uncategorized",label:Object(g._x)("Uncategorized")})}),[s,i]);var b=Object(u.useCallback)((function(e){if(!e.categories||!e.categories.length)return 1/0;var t=Object(f.fromPairs)(s.map((function(e,t){return[e.name,t]})));return Math.min.apply(Math,Object(ne.a)(e.categories.map((function(e){return void 0!==t[e]?t[e]:1/0}))))}),[s]),m=Object(u.useMemo)((function(){return i.filter((function(e){return"uncategorized"===d.name?b(e)===1/0:e.categories&&e.categories.includes(d.name)}))}),[i,d]),v=Object(u.useMemo)((function(){return m.sort((function(e,t){return b(e)-b(t)}))}),[m,b]),O=Object(p.useAsyncList)(v);return Object(u.createElement)(u.Fragment,null,!!m.length&&Object(u.createElement)(Dl,{key:d.name,title:d.title,selectedCategory:d,patternCategories:s,onClickCategory:r},Object(u.createElement)(Ll,{shownPatterns:O,blockPatterns:m,onClickPattern:l})))}var Hl=function(e){var t=e.onInsert,n=e.onClickCategory,r=e.filterValue,o=e.selectedCategory;return r?Object(u.createElement)(Fl,{onInsert:t,filterValue:r}):Object(u.createElement)(Vl,{selectedCategory:o,onInsert:t,onClickCategory:n})},zl=n(31);function Ul(e){var t=e.debouncedSpeak,n=e.filterValue,r=e.onHover,o=e.onInsert,c=e.rootClientId,i=Kn(c,o),a=Object(re.a)(i,4),l=a[0],s=a[1],d=a[2],b=a[3],f=Object(u.useMemo)((function(){var e=l.filter((function(e){return"reusable"===e.category}));return n?zn(e,s,d,n):e}),[n,l,s,d]);return Object(u.useEffect)((function(){var e=Object(g.sprintf)(Object(g._n)("%d result found.","%d results found.",f.length),f.length);t(e)}),[n,t]),0===f.length?Object(u.createElement)(Pl,null):Object(u.createElement)(xl,{title:n?Object(g.__)("Search Results"):Object(g.__)("Reusable blocks")},Object(u.createElement)(El,{items:f,onSelect:b,onHover:r,label:n?Object(g.__)("Search Results"):Object(g.__)("Reusable blocks")}))}var Gl=Object(h.withSpokenMessages)((function(e){var t=e.rootClientId,n=e.onInsert,r=e.onHover,o=e.filterValue,c=e.debouncedSpeak;return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(Ul,{debouncedSpeak:c,filterValue:o,onHover:r,onInsert:n,rootClientId:t}),Object(u.createElement)("div",{className:"block-editor-inserter__manage-reusable-blocks-container"},Object(u.createElement)("a",{className:"block-editor-inserter__manage-reusable-blocks",href:Object(zl.addQueryArgs)("edit.php",{post_type:"wp_block"})},Object(g.__)("Manage all reusable blocks"))))}));var Kl=function(e){var t=e.rootClientId,n=e.insertionIndex,r=e.clientId,o=e.isAppender,i=e.selectBlockOnInsert,a=e.onSelect,l=Object(v.useSelect)((function(e){var c,i,a=e("core/block-editor"),l=a.getSelectedBlock,s=a.getBlockIndex,u=a.getBlockOrder,d=a.getBlockInsertionPoint;if(t||n||r||o)c=t,i=n||(r?s(r,c):u(c).length);else{var b=d();c=b.rootClientId,i=b.index}return{selectedBlock:l(),destinationRootClientId:c,destinationIndex:i}}),[t,n,r,o]),s=l.selectedBlock,u=l.destinationRootClientId,d=l.destinationIndex,b=Object(v.useDispatch)("core/block-editor"),f=b.replaceBlocks,p=b.insertBlocks,m=b.showInsertionPoint,O=b.hideInsertionPoint;return[u,function(e,t){if(!o&&s&&Object(c.isUnmodifiedDefaultBlock)(s)?f(s.clientId,e,null,null,t):p(e,d,u,i,t),!i){var n=Object(g._n)("%d block added.","%d blocks added.",e.length);Object(Le.speak)(n)}a&&a()},function(e){e?m(u,d):O()}]},Wl={name:"blocks",title:Object(g.__)("Blocks")},ql={name:"patterns",title:Object(g.__)("Patterns")},$l={name:"reusable",title:Object(g.__)("Reusable")};var Yl=function(e){var t=e.children,n=e.showPatterns,r=void 0!==n&&n,o=e.showReusableBlocks,c=void 0!==o&&o,i=e.onSelect,a=[Wl];return r&&a.push(ql),c&&a.push($l),Object(u.createElement)(h.TabPanel,{className:"block-editor-inserter__tabs",tabs:a,onSelect:i},t)},Xl=function(e){return e.stopPropagation()};var Ql=function(e){var t=e.rootClientId,n=e.clientId,r=e.isAppender,o=e.__experimentalSelectBlockOnInsert,c=e.__experimentalInsertionIndex,i=e.onSelect,a=e.showInserterHelpPanel,l=e.showMostUsedBlocks,s=Object(u.useState)("blocks"),d=Object(re.a)(s,2),b=d[0],f=d[1],p=Object(u.useState)(""),m=Object(re.a)(p,2),O=m[0],j=m[1],k=Object(u.useState)(null),y=Object(re.a)(k,2),_=y[0],E=y[1],C=Object(u.useState)(null),S=Object(re.a)(C,2),w=S[0],I=S[1],B=Kl({rootClientId:t,clientId:n,isAppender:r,selectBlockOnInsert:o,insertionIndex:c}),x=Object(re.a)(B,3),P=x[0],T=x[1],N=x[2],D=Object(v.useSelect)((function(e){var t=e("core/block-editor").getSettings(),n=t.__experimentalBlockPatterns,r=t.__experimentalReusableBlocks;return{hasPatterns:!!(null==n?void 0:n.length),hasReusableBlocks:!!(null==r?void 0:r.length)}}),[]),R=D.hasPatterns,A=D.hasReusableBlocks,M=!P&&R,L=function(e){T(e),i()},F=function(e){N(!!e),E(e)},V=Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{className:"block-editor-inserter__block-list"},Object(u.createElement)(Nl,{rootClientId:P,onInsert:L,onHover:F,filterValue:O,showMostUsedBlocks:l})),a&&Object(u.createElement)("div",{className:"block-editor-inserter__tips"},Object(u.createElement)(h.VisuallyHidden,{as:"h2"},Object(g.__)("A tip for using the block editor")),Object(u.createElement)(ao,null))),H=Object(u.createElement)(Hl,{onInsert:function(e,t){T(e,{patternName:t}),i()},filterValue:O,onClickCategory:function(e){I(e)},selectedCategory:w}),z=Object(u.createElement)(Gl,{rootClientId:P,onInsert:L,onHover:F,filterValue:O});return Object(u.createElement)("div",{className:"block-editor-inserter__menu",onKeyPress:Xl,onKeyDown:function(e){[st.LEFT,st.DOWN,st.RIGHT,st.UP,st.BACKSPACE,st.ENTER].includes(e.keyCode)&&e.stopPropagation()}},Object(u.createElement)("div",{className:"block-editor-inserter__main-area"},Object(u.createElement)("div",{className:"block-editor-inserter__content"},Object(u.createElement)(bo,{onChange:function(e){_&&E(null),j(e)},value:O,placeholder:"reusable"===b?Object(g.__)("Search for a reusable block"):"patterns"===b?Object(g.__)("Search for a pattern"):Object(g.__)("Search for a block")}),(M||A)&&Object(u.createElement)(Yl,{showPatterns:M,showReusableBlocks:A,onSelect:f},(function(e){return"blocks"===e.name?V:"patterns"===e.name?H:z})),!M&&!A&&V)),a&&_&&Object(u.createElement)(hl,{item:_}))},Zl=function(e){[st.LEFT,st.DOWN,st.RIGHT,st.UP,st.BACKSPACE,st.ENTER].includes(e.keyCode)&&e.stopPropagation()},Jl=function(e){return e.stopPropagation()};function es(e){var t=e.blockTypes,n=e.blockPatterns,r=e.onSelectBlockType,o=e.onSelectBlockPattern,c=e.onHover,i=Object(u.useMemo)((function(){return Object(f.orderBy)(t,["frecency"],["desc"]).slice(0,6)}),[t]),a=Object(u.useMemo)((function(){return n.slice(0,2)}),[t]);return Object(u.createElement)("div",{className:"block-editor-inserter__quick-inserter-results"},!i.length&&!a.length&&Object(u.createElement)(Pl,null),!!i.length&&Object(u.createElement)(xl,{title:Object(u.createElement)(h.VisuallyHidden,null,Object(g.__)("Blocks"))},Object(u.createElement)(El,{items:i,onSelect:r,onHover:c,label:Object(g.__)("Blocks")})),!!i.length&&!!a.length&&Object(u.createElement)("div",{className:"block-editor-inserter__quick-inserter-separator"}),!!a.length&&Object(u.createElement)(xl,{title:Object(u.createElement)(h.VisuallyHidden,null,Object(g.__)("Blocks"))},Object(u.createElement)("div",{className:"block-editor-inserter__quick-inserter-patterns"},Object(u.createElement)(Ll,{shownPatterns:a,blockPatterns:a,onClickPattern:o}))))}function ts(e){var t=e.onSelect,n=e.rootClientId,r=e.clientId,o=e.isAppender,c=e.selectBlockOnInsert,i=Object(p.useDebounce)(Le.speak,500),a=Object(u.useState)(""),l=Object(re.a)(a,2),s=l[0],d=l[1],f=Kl({onSelect:t,rootClientId:n,clientId:r,isAppender:o,selectBlockOnInsert:c}),m=Object(re.a)(f,3),O=m[0],j=m[1],k=m[2],y=Kn(O,j),_=Object(re.a)(y,4),E=_[0],C=_[1],S=_[2],w=_[3],I=Rl(j),B=Object(re.a)(I,3),x=B[0],P=B[2],T=!O&&x.length&&!!s,N=T&&x.length>6||E.length>6,D=Object(u.useMemo)((function(){return zn(E,C,S,s)}),[s,E,C,S]),R=Object(u.useMemo)((function(){return Un(x,s)}),[s,x]),A=Object(v.useSelect)((function(e){var t=e("core/block-editor"),o=t.getSettings,c=t.getBlockIndex;return{setInserterIsOpened:o().__experimentalSetIsInserterOpened,blockIndex:c(r,n)}}),[r,n]),M=A.setInserterIsOpened,L=A.blockIndex;Object(u.useEffect)((function(){M&&M(!1)}),[M]);var F=Object(v.useDispatch)("core/block-editor").__unstableSetInsertionPoint;Object(u.useEffect)((function(){if(s){var e=D.length+R.length,t=Object(g.sprintf)(Object(g._n)("%d result found.","%d results found.",e),e);i(t)}}),[s,i]);return Object(u.createElement)("div",{className:b()("block-editor-inserter__quick-inserter",{"has-search":N,"has-expand":M}),onKeyPress:Jl,onKeyDown:Zl},N&&Object(u.createElement)(bo,{value:s,onChange:function(e){d(e)},placeholder:Object(g.__)("Search for a block")}),Object(u.createElement)(es,{blockTypes:D,blockPatterns:T?R:[],onSelectBlockPattern:P,onSelectBlockType:w,onHover:k}),M&&Object(u.createElement)(h.Button,{className:"block-editor-inserter__quick-inserter-expand",onClick:function(){F(n,L),M(!0)},"aria-label":Object(g.__)("Browse all. This will open the main inserter panel in the editor toolbar.")},Object(g.__)("Browse all")))}function ns(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}var rs=function(e){var t,n=e.onToggle,r=e.disabled,o=e.isOpen,c=e.blockTitle,i=e.hasSingleBlockType,a=e.toggleProps,s=void 0===a?{}:a;t=i?Object(g.sprintf)(Object(g._x)("Add %s","directly add the only allowed block"),c):Object(g._x)("Add block","Generic label for block inserter button");var d=s.onClick,b=Object(he.a)(s,["onClick"]);return Object(u.createElement)(h.Button,Object(l.a)({icon:co.a,label:t,tooltipPosition:"bottom",onClick:function(e){n&&n(e),d&&d(e)},className:"block-editor-inserter__toggle","aria-haspopup":!i&&"true","aria-expanded":!i&&o,disabled:r},b))},os=function(e){Object(Wt.a)(n,e);var t=ns(n);function n(){var e;return Object(Ut.a)(this,n),(e=t.apply(this,arguments)).onToggle=e.onToggle.bind(Object(Kt.a)(e)),e.renderToggle=e.renderToggle.bind(Object(Kt.a)(e)),e.renderContent=e.renderContent.bind(Object(Kt.a)(e)),e}return Object(Gt.a)(n,[{key:"onToggle",value:function(e){var t=this.props.onToggle;t&&t(e)}},{key:"renderToggle",value:function(e){var t=e.onToggle,n=e.isOpen,r=this.props,o=r.disabled,c=r.blockTitle,i=r.hasSingleBlockType,a=r.toggleProps,l=r.hasItems,s=r.renderToggle,u=void 0===s?rs:s;return u({onToggle:t,isOpen:n,disabled:o||!l,blockTitle:c,hasSingleBlockType:i,toggleProps:a})}},{key:"renderContent",value:function(e){var t=e.onClose,n=this.props,r=n.rootClientId,o=n.clientId,c=n.isAppender,i=n.showInserterHelpPanel,a=n.__experimentalSelectBlockOnInsert;return n.__experimentalIsQuick?Object(u.createElement)(ts,{onSelect:t,rootClientId:r,clientId:o,isAppender:c,selectBlockOnInsert:a}):Object(u.createElement)(Ql,{onSelect:t,rootClientId:r,clientId:o,isAppender:c,showInserterHelpPanel:i,__experimentalSelectBlockOnInsert:a})}},{key:"render",value:function(){var e=this.props,t=e.position,n=e.hasSingleBlockType,r=e.insertOnlyAllowedBlock,o=e.__experimentalIsQuick;return n?this.renderToggle({onToggle:r}):Object(u.createElement)(h.Dropdown,{className:"block-editor-inserter",contentClassName:b()("block-editor-inserter__popover",{"is-quick":o}),position:t,onToggle:this.onToggle,expandOnMobile:!0,headerTitle:Object(g.__)("Add a block"),renderToggle:this.renderToggle,renderContent:this.renderContent})}}]),n}(u.Component),cs=Object(p.compose)([Object(v.withSelect)((function(e,t){var n=t.clientId,r=t.rootClientId,o=e("core/block-editor"),c=o.getBlockRootClientId,i=o.hasInserterItems,a=o.__experimentalGetAllowedBlocks,l=e("core/blocks").getBlockVariations,s=a(r=r||c(n)||void 0),u=1===Object(f.size)(s)&&0===Object(f.size)(l(s[0].name,"inserter")),d=!1;return u&&(d=s[0]),{hasItems:i(r),hasSingleBlockType:u,blockTitle:d?d.title:"",allowedBlockType:d,rootClientId:r}})),Object(v.withDispatch)((function(e,t,n){var r=n.select;return{insertOnlyAllowedBlock:function(){var n=t.rootClientId,o=t.clientId,i=t.isAppender,a=t.hasSingleBlockType,l=t.allowedBlockType,s=t.__experimentalSelectBlockOnInsert;if(a&&((0,e("core/block-editor").insertBlock)(Object(c.createBlock)(l.name),function(){var e=r("core/block-editor"),t=e.getBlockIndex,c=e.getBlockSelectionEnd,a=e.getBlockOrder;if(o)return t(o,n);var l=c();return!i&&l?t(l,n)+1:a(n).length}(),n,s),!s)){var u=Object(g.sprintf)(Object(g.__)("%s block added"),l.title);Object(Le.speak)(u)}}}})),Object(p.ifCondition)((function(e){var t=e.hasItems,n=e.isAppender,r=e.rootClientId,o=e.clientId;return t||!n&&!r&&!o}))])(os),is=Object(u.forwardRef)((function(e,t){var n=e.selectedClientId,r=e.isReverse,o=e.containerRef,c=e.noCapture,i=e.hasMultiSelection,a=e.multiSelectionContainer,l=Object(v.useSelect)((function(e){return e("core/block-editor").isNavigationMode()})),s=Object(v.useDispatch)("core/block-editor").setNavigationMode;return Object(u.createElement)("div",{ref:t,tabIndex:l?void 0:"0",onFocus:function(){if(c.current)c.current=null;else if(n){var e=qe(n);if(r){var t=kr.focus.tabbable.find(e);(Object(f.last)(t)||e).focus()}else e.focus()}else{if(i)return void a.current.focus();s(!0);var l=kr.focus.tabbable.find(o.current);l.length&&(r?Object(f.last)(l).focus():Object(f.first)(l).focus())}},style:{position:"fixed"}})}));var as=Object(f.overEvery)([kr.isTextField,kr.focus.tabbable.isTabbableIndex]);function ls(e,t,n,r){var o,c=kr.focus.focusable.find(n);return t&&(c=Object(f.reverse)(c)),c=c.slice(c.indexOf(e)+1),r&&(o=e.getBoundingClientRect()),Object(f.find)(c,(function t(n,c,i){if(!kr.focus.tabbable.isTabbableIndex(n))return!1;if(r){var a=n.getBoundingClientRect();if(a.left>=o.right||a.right<=o.left)return!1}if(Object(kr.isTextField)(n))return!0;if(!n.classList.contains("block-editor-block-list__block"))return!1;if(function(e){return e.classList.contains("block-editor-block-list__layout")||!!e.querySelector(".block-editor-block-list__layout")}(n))return!0;if(n.contains(e))return!1;for(var l,s=1;(l=i[c+s])&&n.contains(l);s++)if(t(l,c+s,i))return!1;return!0}))}function ss(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientId,r=t.getMultiSelectedBlocksStartClientId,o=t.getMultiSelectedBlocksEndClientId,c=t.getPreviousBlockClientId,i=t.getNextBlockClientId,a=t.getFirstMultiSelectedBlockClientId,l=t.getLastMultiSelectedBlockClientId,s=t.hasMultiSelection,u=t.getBlockOrder,d=t.isNavigationMode,b=t.hasBlockMovingClientId,f=t.getBlockIndex,p=t.getBlockRootClientId,m=t.getClientIdsOfDescendants,v=t.canInsertBlockType,O=t.getBlockName,g=t.isSelectionEnabled,h=t.getBlockSelectionStart,j=t.isMultiSelecting,k=t.getSettings,y=n(),_=r(),E=o();return{selectedBlockClientId:y,selectionStartClientId:_,selectionBeforeEndClientId:c(E||y),selectionAfterEndClientId:i(E||y),selectedFirstClientId:a(),selectedLastClientId:l(),hasMultiSelection:s(),blocks:u(),isNavigationMode:d(),hasBlockMovingClientId:b,getBlockIndex:f,getBlockRootClientId:p,getClientIdsOfDescendants:m,canInsertBlockType:v,getBlockName:O,isSelectionEnabled:g(),blockSelectionStart:h(),isMultiSelecting:j(),keepCaretInsideBlock:k().keepCaretInsideBlock}}function us(e){var t=e.children,n=Object(u.useRef)(),r=Object(u.useRef)(),o=Object(u.useRef)(),c=Object(u.useRef)(),i=Object(u.useRef)(),a=Object(u.useRef)(),l=Object(u.useRef)(),s=Object(v.useSelect)(ss,[]),d=s.selectedBlockClientId,p=s.selectionStartClientId,m=s.selectionBeforeEndClientId,O=s.selectionAfterEndClientId,h=s.selectedFirstClientId,j=s.selectedLastClientId,k=s.hasMultiSelection,y=s.blocks,_=s.isNavigationMode,E=s.hasBlockMovingClientId,C=s.isSelectionEnabled,S=s.blockSelectionStart,w=s.isMultiSelecting,I=s.getBlockIndex,B=s.getBlockRootClientId,x=s.getClientIdsOfDescendants,P=s.canInsertBlockType,T=s.getBlockName,N=s.keepCaretInsideBlock,D=Object(v.useDispatch)("core/block-editor"),R=D.multiSelect,A=D.selectBlock,M=D.clearSelectedBlock,L=D.setNavigationMode,F=D.setBlockMovingClientId,V=D.moveBlockToPosition,H=Object(u.useState)(!1),z=Object(re.a)(H,2),U=z[0],G=z[1];Object(u.useEffect)((function(){k&&!w&&c.current.focus()}),[k,w]);var K=b()("block-editor-writing-flow",{"is-navigate-mode":_,"is-block-moving-mode":!!E(),"can-insert-moving-block":U});return Object(u.createElement)("div",{className:K},Object(u.createElement)(is,{ref:r,selectedClientId:d,containerRef:n,noCapture:a,hasMultiSelection:k,multiSelectionContainer:c}),Object(u.createElement)("div",{ref:n,onKeyDown:function(e){var t=e.keyCode,s=e.target,u=t===st.UP,b=t===st.DOWN,v=t===st.LEFT,g=t===st.RIGHT,C=t===st.TAB,S=t===st.ESCAPE,w=t===st.ENTER,D=t===st.SPACE,H=u||v,z=v||g,U=u||b,K=z||U,W=e.shiftKey,q=W||e.ctrlKey||e.altKey||e.metaKey,$=U?kr.isVerticalEdge:kr.isHorizontalEdge;if(_){var Y,X=C&&W||u,Q=C&&!W||b,Z=v,J=g;if(X)Y=m;else if(Q)Y=O;else if(Z){var ee;Y=null!==(ee=B(d))&&void 0!==ee?ee:d}else if(J){var te;Y=null!==(te=x([d])[0])&&void 0!==te?te:d}var ne=E();if(ne&&Y&&G(P(T(ne),B(Y))),S&&ne&&(F(null),G(!1)),(w||D)&&ne){var re=B(ne),oe=B(d),ce=I(ne,re),ie=I(d,oe);ce<ie&&re===oe&&(ie-=1),V(ne,re,oe,ie),A(ne),F(null)}if(Q||X||Z||J)if(Y)e.preventDefault(),A(Y);else if(C&&d){var ae,le=qe(d);(ae=Q?kr.focus.tabbable.findNext(le):kr.focus.tabbable.findPrevious(le))&&(e.preventDefault(),ae.focus(),M())}}else{if(d)if(C){var se=qe(d);if(W){if(s===se)return a.current=!0,void r.current.focus()}else{var ue=kr.focus.tabbable.find(se);if(s===(Object(f.last)(ue)||se))return a.current=!0,void o.current.focus()}}else S&&L(!0);else if(k&&C&&s===c.current)return a.current=!0,void(W?r.current.focus():o.current.focus());var de=n.current.ownerDocument.defaultView;if(U?l.current||(l.current=Object(kr.computeCaretRect)(de)):l.current=null,!K)return st.isKeyboardEvent.primary(e)&&(i.current=Object(kr.isEntirelySelected)(s)),void(st.isKeyboardEvent.primary(e,"a")&&((s.isContentEditable?i.current:Object(kr.isEntirelySelected)(s))&&(R(Object(f.first)(y),Object(f.last)(y)),e.preventDefault()),i.current=!0));if(!e.nativeEvent.defaultPrevented&&function(e,t,n){if((t===st.UP||t===st.DOWN)&&!n)return!0;var r=e.tagName;return"INPUT"!==r&&"TEXTAREA"!==r}(s,t,q)){var be,fe="rtl"===(be=s).ownerDocument.defaultView.getComputedStyle(be).direction?!H:H;if(W)(H&&m||!H&&O)&&(k||function(e,t){var r,o,c=ls(e,t,n.current);return!(c&&(r=e,o=c,r.closest(".block-editor-block-list__block")===o.closest(".block-editor-block-list__block")))}(s,H)&&$(s,H))&&(!function(e){var t=e?m:O;t&&R(p||d,t)}(H),e.preventDefault());else if(k)!function(e){var t=e?h:j;t&&A(t)}(H),e.preventDefault();else if(U&&Object(kr.isVerticalEdge)(s,H)&&!N){var pe=ls(s,H,n.current,!0);pe&&(Object(kr.placeCaretAtVerticalEdge)(pe,H,l.current),e.preventDefault())}else if(z&&de.getSelection().isCollapsed&&Object(kr.isHorizontalEdge)(s,fe)&&!N){var me=ls(s,fe,n.current);Object(kr.placeCaretAtHorizontalEdge)(me,fe),e.preventDefault()}}}},onMouseDown:function(e){if(l.current=null,_&&d&&$e(qe(d),e.target)?(L(!1),F(null)):_&&E()&&Ye(e.target)&&G(P(T(E()),B(Ye(e.target)))),C&&0===e.button){var t=Ye(e.target);t&&(e.shiftKey?S!==t&&(R(S,t),e.preventDefault()):k&&A(t))}}},Object(u.createElement)("div",{ref:c,tabIndex:k?"0":void 0,"aria-label":k?Object(g.__)("Multiple selected blocks"):void 0,style:{position:"fixed"}}),t),Object(u.createElement)(is,{ref:o,selectedClientId:d,containerRef:n,noCapture:a,hasMultiSelection:k,multiSelectionContainer:c,isReverse:!0}),Object(u.createElement)("div",{"aria-hidden":!0,tabIndex:-1,onClick:function(){var e=kr.focus.focusable.find(n.current),t=Object(f.findLast)(e,as);t&&Object(kr.placeCaretAtHorizontalEdge)(t,!0)},className:"block-editor-writing-flow__click-redirect"}))}function ds(e){var t=e.clientId,n=e.setIsInserterForced,r=e.containerRef,o=Object(u.useRef)(),c=Object(v.useSelect)((function(e){var n=e("core/block-editor"),r=n.getMultiSelectedBlockClientIds,o=n.getSelectedBlockClientId,c=n.hasMultiSelection;if((0,n.getSettings)().hasReducedUI)return!0;var i=r(),a=o();return c()?i.includes(t):t===a}),[t]);return Object(u.createElement)("div",{ref:o,onFocus:function(){return n(!0)},onBlur:function(){return n(!1)},onClick:function(e){var n=e.clientX,c=e.clientY,i=e.target;if(i===o.current){var a=i.getBoundingClientRect(),l=c<a.top+a.height/2,s=qe(t),u=ls(s,!0,l?r.current:s)||s,d=new window.DOMRect(n,c,0,16);Object(kr.placeCaretAtVerticalEdge)(u,l,d,!1)}},tabIndex:-1,className:b()("block-editor-block-list__insertion-point-inserter",{"is-inserter-hidden":c})},Object(u.createElement)(cs,{position:"bottom center",clientId:t,__experimentalIsQuick:!0}))}function bs(e){var t=e.clientId,n=e.rootClientId,r=e.isInserterShown,o=e.isInserterForced,c=e.setIsInserterForced,i=e.containerRef,a=e.showInsertionPoint,l=Object(u.useContext)(Za),s=Object(u.useMemo)((function(){return t?qe(t):l.get(n||"")}),[t,n,l]);return Object(u.createElement)(h.Popover,{noArrow:!0,animate:!1,anchorRef:s,position:"top right left",focusOnMount:!1,className:"block-editor-block-list__insertion-point-popover",__unstableSlotName:"block-toolbar"},Object(u.createElement)("div",{className:"block-editor-block-list__insertion-point",style:{width:null==s?void 0:s.offsetWidth}},a&&Object(u.createElement)("div",{className:"block-editor-block-list__insertion-point-indicator"}),(r||o)&&Object(u.createElement)(ds,{clientId:t,setIsInserterForced:c,containerRef:i})))}function fs(e){var t=e.children,n=e.containerRef,r=Object(u.useState)(!1),o=Object(re.a)(r,2),c=o[0],i=o[1],a=Object(u.useState)(!1),l=Object(re.a)(a,2),s=l[0],d=l[1],b=Object(u.useState)(null),f=Object(re.a)(b,2),p=f[0],m=f[1],O=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.isMultiSelecting,r=t.isBlockInsertionPointVisible,o=t.getBlockInsertionPoint,c=t.getBlockOrder,i=o(),a=c(i.rootClientId);return{isMultiSelecting:n(),isInserterVisible:r(),selectedClientId:a[i.index],selectedRootClientId:i.rootClientId}}),[]),g=O.isMultiSelecting,h=O.isInserterVisible,j=O.selectedClientId,k=O.selectedRootClientId;var y=c||s||h;return Object(u.createElement)(u.Fragment,null,!g&&y&&Object(u.createElement)(bs,{clientId:h?j:p,rootClientId:k,isInserterShown:c,isInserterForced:s,setIsInserterForced:d,containerRef:n,showInsertionPoint:h}),Object(u.createElement)("div",{onMouseMove:s||g?void 0:function(e){if(e.target.classList.contains("block-editor-block-list__layout")){var t=e.target.getBoundingClientRect(),n=e.clientY-t.top,r=Array.from(e.target.children).find((function(e){return e.offsetTop>n}));if(r&&(r.id||(r=r.firstElementChild))){var o=r.id.slice("block-".length);if(o){var a=r.getBoundingClientRect();e.clientX>a.right||e.clientX<a.left?c&&i(!1):(i(!0),m(o))}}}else c&&i(!1)}},t))}var ps=function(e){var t=e.clientId,n=e.rootClientId,r=Object(he.a)(e,["clientId","rootClientId"]),o=Object(v.useSelect)((function(e){var r,o=e("core/block-editor"),c=o.__unstableGetBlockWithoutInnerBlocks,i=o.getBlockIndex,a=o.hasBlockMovingClientId,l=o.getBlockListSettings,s=i(t,n),u=c(t);return{index:s,name:u.name,attributes:u.attributes,blockMovingMode:a(),orientation:null===(r=l(n))||void 0===r?void 0:r.orientation}}),[t,n]),i=o.index,a=o.name,s=o.attributes,d=o.blockMovingMode,f=o.orientation,p=Object(v.useDispatch)("core/block-editor"),m=p.setNavigationMode,O=p.removeBlock,g=Object(u.useRef)();Object(u.useEffect)((function(){g.current.focus(),window.navigator.platform.indexOf("Win")>-1&&Object(Le.speak)(k)}),[]);var j=Object(c.getBlockType)(a),k=Object(c.__experimentalGetAccessibleBlockLabel)(j,s,i+1,f),y=b()("block-editor-block-list__block-selection-button",{"is-block-moving-mode":!!d});return Object(u.createElement)("div",Object(l.a)({className:y},r),Object(u.createElement)(h.Button,{ref:g,onClick:function(){return m(!1)},onKeyDown:function(e){var n=e.keyCode;n!==st.BACKSPACE&&n!==st.DELETE||(O(t),e.preventDefault())},label:k},Object(u.createElement)(Zn,{clientId:t})))};function ms(e,t,n){var r=Object(u.useState)(t),o=Object(re.a)(r,1)[0],c=Object(u.useCallback)((function(){var t,n,r;t=e.current,n=kr.focus.tabbable.find(t),(r=Object(re.a)(n,1)[0])&&r.focus()}),[]);Object(a.useShortcut)("core/block-editor/focus-toolbar",c,{bindGlobal:!0,eventName:"keydown"}),Object(u.useEffect)((function(){o&&c()}),[n,o,c])}var vs=function(e){var t=e.children,n=e.focusOnMount,r=Object(he.a)(e,["children","focusOnMount"]),o=Object(u.useRef)(),c=function(e){var t=Object(u.useState)(!0),n=Object(re.a)(t,2),r=n[0],o=n[1],c=Object(u.useCallback)((function(){var t=kr.focus.tabbable.find(e.current),n=!t.some((function(e){return!("toolbarItem"in e.dataset)}));n||to()("Using custom components as toolbar controls",{alternative:"ToolbarItem or ToolbarButton components",link:"https://developer.wordpress.org/block-editor/components/toolbar-button/#inside-blockcontrols"}),o(n)}),[]);return Object(u.useLayoutEffect)((function(){var t=new window.MutationObserver(c);return t.observe(e.current,{childList:!0,subtree:!0}),function(){return t.disconnect()}}),[r]),r}(o);return ms(o,n,c),c?Object(u.createElement)(h.Toolbar,Object(l.a)({label:r["aria-label"],ref:o},r),t):Object(u.createElement)(h.NavigableMenu,Object(l.a)({orientation:"horizontal",role:"toolbar",ref:o},r),t)},Os=Object(u.createElement)(j.SVG,{width:"18",height:"18",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 18 18"},Object(u.createElement)(j.Path,{d:"M5 4h2V2H5v2zm6-2v2h2V2h-2zm-6 8h2V8H5v2zm6 0h2V8h-2v2zm-6 6h2v-2H5v2zm6 0h2v-2h-2v2z"}));function gs(e){var t=e.clientIds,n=Object(v.useSelect)((function(e){var n;if(1===t.length){var r=(0,e("core/block-editor").getBlockName)(Object(re.a)(t,1)[0]);return null===(n=Object(c.getBlockType)(r))||void 0===n?void 0:n.icon}}),[t]);return Object(u.createElement)("div",{className:"block-editor-block-draggable-chip-wrapper"},Object(u.createElement)("div",{className:"block-editor-block-draggable-chip"},Object(u.createElement)(h.Flex,{justify:"center",className:"block-editor-block-draggable-chip__content"},Object(u.createElement)(h.FlexItem,null,n?Object(u.createElement)(qn,{icon:n}):Object(g.sprintf)(Object(g._n)("%d block","%d blocks",t.length),t.length)),Object(u.createElement)(h.FlexItem,null,Object(u.createElement)(qn,{icon:Os})))))}var hs=function(e){var t,n,r,o,c=e.children,i=e.clientIds,a=e.cloneClassname,l=e.onDragStart,s=e.onDragEnd,d=e.elementId,b=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getBlockRootClientId,r=t.getTemplateLock,o=n(i[0]);return{srcRootClientId:o,isDraggable:"all"!==(o?r(o):null)}}),[i]),f=b.srcRootClientId,p=b.isDraggable,m=Object(u.useRef)(!1),O=(t=Object(u.useRef)(null),n=Object(u.useRef)(null),r=Object(u.useRef)(null),o=Object(u.useRef)(null),Object(u.useEffect)((function(){return function(){o.current&&(clearInterval(o.current),o.current=null)}}),[]),[Object(u.useCallback)((function(e){t.current=e.clientY,r.current=Object(kr.getScrollContainer)(e.target),o.current=setInterval((function(){if(r.current&&n.current){var e=r.current.scrollTop+n.current;r.current.scroll({top:e})}}),25)}),[]),Object(u.useCallback)((function(e){if(r.current){var o=r.current.offsetHeight,c=t.current-r.current.offsetTop,i=e.clientY-r.current.offsetTop;if(e.clientY>c){var a=Math.max(o-c-50,0),l=Math.max(i-c-50,0)/a;n.current=25*l}else if(e.clientY<c){var s=Math.max(c-50,0),u=Math.max(c-i-50,0)/s;n.current=-25*u}else n.current=0}}),[]),function(){t.current=null,r.current=null,o.current&&(clearInterval(o.current),o.current=null)}]),g=Object(re.a)(O,3),j=g[0],k=g[1],y=g[2],_=Object(v.useDispatch)("core/block-editor"),E=_.startDraggingBlocks,C=_.stopDraggingBlocks;if(Object(u.useEffect)((function(){return function(){m.current&&C()}}),[]),!p)return c({isDraggable:!1});var S={type:"block",srcClientIds:i,srcRootClientId:f};return Object(u.createElement)(h.Draggable,{cloneClassname:a,elementId:d||"block-".concat(i[0]),transferData:S,onDragStart:function(e){E(i),m.current=!0,j(e),l&&l()},onDragOver:k,onDragEnd:function(){C(),m.current=!1,y(),s&&s()},__experimentalDragComponent:Object(u.createElement)(gs,{clientIds:i})},(function(e){var t=e.onDraggableStart,n=e.onDraggableEnd;return c({isDraggable:!0,onDraggableStart:t,onDraggableEnd:n})}))};var js=Object(v.withSelect)((function(e,t){var n,r=t.clientIds,o=e("core/block-editor"),i=o.getBlock,a=o.getBlockIndex,l=o.getBlockListSettings,s=o.getTemplateLock,u=o.getBlockOrder,d=o.getBlockRootClientId,b=Object(f.castArray)(r),p=Object(f.first)(b),m=i(p),v=d(Object(f.first)(b)),O=a(p,v),g=0===O,h=a(Object(f.last)(b),v)===u(v).length-1;return{blockType:m?Object(c.getBlockType)(m.name):null,isLocked:"all"===s(v),rootClientId:v,firstIndex:O,isFirst:g,isLast:h,orientation:null===(n=l(v))||void 0===n?void 0:n.orientation}}))((function(e){var t=e.isFirst,n=e.isLast,r=e.clientIds,o=e.isLocked,c=e.isHidden,i=e.rootClientId,a=e.orientation,s=e.hideDragHandle,d=Object(u.useState)(!1),f=Object(re.a)(d,2),p=f[0],m=f[1],v=function(){return m(!0)},O=function(){return m(!1)};if(o||t&&n&&!i)return null;var j=1===r.length?Object(g.__)("Drag block"):Object(g.__)("Drag blocks");return Object(u.createElement)("div",{className:b()("block-editor-block-mover",{"is-visible":p||!c,"is-horizontal":"horizontal"===a})},!s&&Object(u.createElement)(hs,{clientIds:r,cloneClassname:"block-editor-block-mover__drag-clone"},(function(e){var t=e.isDraggable,n=e.onDraggableStart,r=e.onDraggableEnd;return Object(u.createElement)(h.Button,{icon:Os,className:"block-editor-block-mover__drag-handle","aria-hidden":"true",label:j,tabIndex:"-1",onDragStart:n,onDragEnd:r,draggable:t})})),Object(u.createElement)(h.ToolbarGroup,{className:"block-editor-block-mover__move-button-container"},Object(u.createElement)(h.ToolbarItem,{onFocus:v,onBlur:O},(function(e){return Object(u.createElement)(Rr,Object(l.a)({clientIds:r},e))})),Object(u.createElement)(h.ToolbarItem,{onFocus:v,onBlur:O},(function(e){return Object(u.createElement)(Ar,Object(l.a)({clientIds:r},e))}))))}));function ks(){var e=Object(v.useDispatch)("core/block-editor").selectBlock,t=Object(v.useSelect)((function(e){var t=e("core/block-editor"),r=t.getBlockName,o=t.getBlockParents,i=t.getSelectedBlockClientId,a=e("core/blocks").hasBlockSupport,l=o(i()),s=l[l.length-1],u=r(s);return{parentBlockType:Object(c.getBlockType)(u),firstParentClientId:s,shouldHide:!a(n,"__experimentalParentSelector",!0)}}),[]),n=t.parentBlockType,r=t.firstParentClientId;return t.shouldHide?null:void 0!==r?Object(u.createElement)("div",{className:"block-editor-block-parent-selector",key:r},Object(u.createElement)(h.ToolbarButton,{className:"block-editor-block-parent-selector__button",onClick:function(){return e(r)},label:Object(g.sprintf)(Object(g.__)("Select parent (%s)"),n.title),showTooltip:!0,icon:Object(u.createElement)(qn,{icon:n.icon})})):null}var ys=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(j.Path,{d:"M20.2 8v11c0 .7-.6 1.2-1.2 1.2H6v1.5h13c1.5 0 2.7-1.2 2.7-2.8V8zM18 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.6zm-13.5 0V4.6c0-.1.1-.1.1-.1h11.8c.1 0 .1.1.1.1v11.8c0 .1-.1.1-.1.1H4.6l-.1-.1z"}));function _s(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return Es(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Es(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,i=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return i=e.done,e},e:function(e){a=!0,c=e},f:function(){try{i||null==n.return||n.return()}finally{if(a)throw c}}}}function Es(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Cs(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ss(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Cs(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cs(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ws(e){var t=e.genericPreviewBlock,n=e.style,r=e.isActive,o=e.onBlur,c=e.onHover,i=e.onSelect,a=e.styleClassName,l=e.itemRole,s=Object(u.useMemo)((function(){return Ss(Ss({},t),{},{attributes:Ss(Ss({},t.attributes),{},{className:a})})}),[t,a]);return Object(u.createElement)("div",{key:n.name,className:b()("block-editor-block-styles__item",{"is-active":r}),onClick:function(){return i()},onKeyDown:function(e){st.ENTER!==e.keyCode&&st.SPACE!==e.keyCode||(e.preventDefault(),i())},onMouseEnter:c,onMouseLeave:o,role:l||"button",tabIndex:"0","aria-label":n.label||n.name},Object(u.createElement)("div",{className:"block-editor-block-styles__item-preview"},Object(u.createElement)(vl,{viewportWidth:500,blocks:s})),Object(u.createElement)("div",{className:"block-editor-block-styles__item-label"},n.label||n.name))}var Is=function(e){var t=e.clientId,n=e.onSwitch,r=void 0===n?f.noop:n,o=e.onHoverClassName,i=void 0===o?f.noop:o,a=e.itemRole,l=Object(v.useSelect)((function(e){var n=e("core/block-editor").getBlock,r=e("core/blocks").getBlockStyles,o=n(t);return{block:o,type:Object(c.getBlockType)(o.name),styles:r(o.name),className:o.attributes.className||""}}),[t]),s=l.styles,d=l.block,b=l.type,p=l.className,m=Object(v.useDispatch)("core/block-editor").updateBlockAttributes,O=function(e,t){return Object(u.useMemo)((function(){return t.example?Object(c.getBlockFromExample)(e.name,{attributes:t.example.attributes,innerBlocks:t.example.innerBlocks}):Object(c.cloneBlock)(e)}),[t.example?e.name:e,t])}(d,b);if(!s||0===s.length)return null;var h=Object(f.find)(s,"isDefault")?s:[{name:"default",label:Object(g._x)("Default","block style"),isDefault:!0}].concat(Object(ne.a)(s)),j=function(e,t){var n,r=_s(new vt.a(t).values());try{for(r.s();!(n=r.n()).done;){var o=n.value;if(-1!==o.indexOf("is-style-")){var c=o.substring(9),i=Object(f.find)(e,{name:c});if(i)return i}}}catch(e){r.e(e)}finally{r.f()}return Object(f.find)(e,"isDefault")}(h,p);return Object(u.createElement)("div",{className:"block-editor-block-styles"},h.map((function(e){var n=function(e,t,n){var r=new vt.a(e);return t&&r.remove("is-style-"+t.name),r.add("is-style-"+n.name),r.value}(p,j,e);return Object(u.createElement)(ws,{genericPreviewBlock:O,className:p,isActive:j===e,key:e.name,onSelect:function(){m(t,{className:n}),i(null),r()},onBlur:function(){return i(null)},onHover:function(){return i(n)},style:e,styleClassName:n,itemRole:a})})))},Bs=function(e){var t=e.className,n=e.possibleBlockTransformations,r=e.onSelect;return Object(u.createElement)(h.MenuGroup,{label:Object(g.__)("Transform to"),className:t},n.map((function(e){var t=e.name,n=e.icon,o=e.title;return Object(u.createElement)(h.MenuItem,{key:t,className:Object(c.getBlockMenuDefaultClassName)(t),onClick:function(e){e.preventDefault(),r(t)}},Object(u.createElement)(qn,{icon:n,showColors:!0}),o)})))};function xs(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}function Ps(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ts(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ps(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ps(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ns(e){var t=e.hoveredBlock,n=e.hoveredClassName,r=Object(c.getBlockType)(t.name);return Object(u.createElement)("div",{className:"block-editor-block-switcher__popover__preview__parent"},Object(u.createElement)("div",{className:"block-editor-block-switcher__popover__preview__container"},Object(u.createElement)(h.Popover,{className:"block-editor-block-switcher__preview__popover",position:"bottom right",focusOnMount:!1},Object(u.createElement)("div",{className:"block-editor-block-switcher__preview"},Object(u.createElement)("div",{className:"block-editor-block-switcher__preview-title"},Object(g.__)("Preview")),Object(u.createElement)(vl,{viewportWidth:500,blocks:r.example?Object(c.getBlockFromExample)(t.name,{attributes:Ts(Ts({},r.example.attributes),{},{className:n}),innerBlocks:r.example.innerBlocks}):Object(c.cloneBlock)(t,{className:n})})))))}var Ds=function(e){Object(Wt.a)(n,e);var t=xs(n);function n(){var e;return Object(Ut.a)(this,n),(e=t.apply(this,arguments)).state={hoveredClassName:null},e.onHoverClassName=e.onHoverClassName.bind(Object(Kt.a)(e)),e}return Object(Gt.a)(n,[{key:"onHoverClassName",value:function(e){this.setState({hoveredClassName:e})}},{key:"render",value:function(){var e=this,t=this.props,n=t.blocks,r=t.onTransform,o=t.inserterItems,i=t.hasBlockStyles,a=this.state.hoveredClassName;if(!Array.isArray(n)||!n.length)return null;var l,s=Object(re.a)(n,1)[0],d=Object(f.mapKeys)(o,(function(e){return e.name})),b=Object(f.orderBy)(Object(f.filter)(Object(c.getPossibleBlockTransformations)(n),(function(e){return e&&!!d[e.name]})),(function(e){return d[e.name].frecency}),"desc");if(1===Object(f.uniq)(Object(f.map)(n,"name")).length){var p=s.name,m=Object(c.getBlockType)(p);l=m.icon}else l=ys;var v=!!b.length;if(!i&&!v)return Object(u.createElement)(h.ToolbarGroup,null,Object(u.createElement)(h.ToolbarButton,{disabled:!0,className:"block-editor-block-switcher__no-switcher-icon",title:Object(g.__)("Block icon"),icon:Object(u.createElement)(qn,{icon:l,showColors:!0})}));var O=1===n.length?Object(g.__)("Change block type or style"):Object(g.sprintf)(Object(g._n)("Change type of %d block","Change type of %d blocks",n.length),n.length);return Object(u.createElement)(h.ToolbarGroup,null,Object(u.createElement)(h.ToolbarItem,null,(function(t){return Object(u.createElement)(h.DropdownMenu,{className:"block-editor-block-switcher",label:O,popoverProps:{position:"bottom right",isAlternate:!0,className:"block-editor-block-switcher__popover"},icon:Object(u.createElement)(qn,{icon:l,className:"block-editor-block-switcher__toggle",showColors:!0}),toggleProps:t,menuProps:{orientation:"both"}},(function(t){var o=t.onClose;return(i||v)&&Object(u.createElement)("div",{className:"block-editor-block-switcher__container"},v&&Object(u.createElement)(Bs,{className:"block-editor-block-switcher__transforms__menugroup",possibleBlockTransformations:b,onSelect:function(e){r(n,e),o()}}),i&&Object(u.createElement)(h.MenuGroup,{label:Object(g.__)("Styles"),className:"block-editor-block-switcher__styles__menugroup"},null!==a&&Object(u.createElement)(Ns,{hoveredBlock:s,hoveredClassName:a}),Object(u.createElement)(Is,{clientId:s.clientId,onSwitch:o,onHoverClassName:e.onHoverClassName,itemRole:"menuitem"})))}))})))}}]),n}(u.Component),Rs=Object(p.compose)(Object(v.withSelect)((function(e,t){var n=t.clientIds,r=e("core/block-editor"),o=r.getBlocksByClientId,c=r.getBlockRootClientId,i=r.getInserterItems,a=e("core/blocks").getBlockStyles,l=c(Object(f.castArray)(n)[0]),s=o(n),u=s&&1===s.length?s[0]:null,d=u&&a(u.name);return{blocks:s,inserterItems:i(l),hasBlockStyles:d&&d.length>0}})),Object(v.withDispatch)((function(e,t){return{onTransform:function(n,r){e("core/block-editor").replaceBlocks(t.clientIds,Object(c.switchToBlockType)(n,r))}}})))(Ds),As=n(41);function Ms(){var e=Object(v.useSelect)((function(e){return e("core/block-editor")}),[]).getBlockName,t=Object(v.useSelect)((function(e){return e("core/blocks")}),[]).getBlockType,n=Object(v.useDispatch)("core/notices").createSuccessNotice;return Object(u.useCallback)((function(r,o){var c="";if(1===o.length){var i=o[0],a=t(e(i)).title;c="copy"===r?Object(g.sprintf)(Object(g.__)('Copied "%s" to clipboard.'),a):Object(g.sprintf)(Object(g.__)('Moved "%s" to clipboard.'),a)}else c="copy"===r?Object(g.sprintf)(Object(g._n)("Copied %d block to clipboard.","Copied %d blocks to clipboard.",o.length),o.length):Object(g.sprintf)(Object(g._n)("Moved %d block to clipboard.","Moved %d blocks to clipboard.",o.length),o.length);n(c,{type:"snackbar"})}),[])}var Ls=function(e){var t=e.children,n=Object(u.useRef)(),r=Object(v.useSelect)((function(e){return e("core/block-editor")}),[]),o=r.getBlocksByClientId,i=r.getSelectedBlockClientIds,a=r.hasMultiSelection,l=r.getSettings,s=Object(v.useDispatch)("core/block-editor"),d=s.flashBlock,b=s.removeBlocks,p=s.replaceBlocks,m=Ms(),O=l().__experimentalCanUserUseUnfilteredHTML,g=function(e){var t=i();if(0!==t.length){if(!a()){var r=e.target.ownerDocument;if("copy"===e.type||"cut"===e.type?Object(kr.documentHasUncollapsedSelection)(r):Object(kr.documentHasSelection)(r))return}if(n.current.contains(e.target)){if(e.preventDefault(),"copy"===e.type||"cut"===e.type){1===t.length&&d(t[0]),m(e.type,t);var l=o(t),s=Object(c.serialize)(l);e.clipboardData.setData("text/plain",s),e.clipboardData.setData("text/html",s)}if("cut"===e.type)b(t);else if("paste"===e.type){var u=function(e){var t=e.clipboardData,n=t.items,r=t.files;n=Object(f.isNil)(n)?[]:n,r=Object(f.isNil)(r)?[]:r;var o="",c="";try{o=t.getData("text/plain"),c=t.getData("text/html")}catch(e){try{c=t.getData("Text")}catch(e){return}}return r=Array.from(r),Array.from(n).forEach((function(e){if(e.getAsFile){var t=e.getAsFile();if(t){var n=t.name,o=t.type,c=t.size;Object(f.find)(r,{name:n,type:o,size:c})||r.push(t)}}})),(r=r.filter((function(e){var t=e.type;return/^image\/(?:jpe?g|png|gif)$/.test(t)}))).length&&!c&&(c=r.map((function(e){return'<img src="'.concat(Object(As.createBlobURL)(e),'">')})).join(""),o=""),{html:c,plainText:o}}(e),v=u.plainText,g=u.html,h=Object(c.pasteHandler)({HTML:g,plainText:v,mode:"BLOCKS",canUserUseUnfilteredHTML:O});p(t,h,h.length-1,-1)}}}};return Object(u.createElement)("div",{ref:n,onCopy:g,onCut:g,onPaste:g},t)};function Fs(e){var t=e.clientIds,n=e.children,r=e.__experimentalUpdateSelection,o=Object(v.useSelect)((function(e){return e("core/block-editor")}),[]),i=o.canInsertBlockType,a=o.getBlockRootClientId,l=o.getBlocksByClientId,s=o.getTemplateLock,u=Object(v.useSelect)((function(e){return e("core/blocks")}),[]),d=u.getDefaultBlockName,b=u.getGroupingBlockName,p=l(t),m=a(t[0]),O=Object(f.every)(p,(function(e){return!!e&&Object(c.hasBlockSupport)(e.name,"multiple",!0)&&i(e.name,m)})),g=i(d(),m),h=Object(v.useDispatch)("core/block-editor"),j=h.removeBlocks,k=h.replaceBlocks,y=h.duplicateBlocks,_=h.insertAfterBlock,E=h.insertBeforeBlock,C=h.flashBlock,S=h.setBlockMovingClientId,w=h.setNavigationMode,I=h.selectBlock,B=Ms();return n({canDuplicate:O,canInsertDefaultBlock:g,isLocked:!!s(m),rootClientId:m,blocks:p,onDuplicate:function(){return y(t,r)},onRemove:function(){return j(t,r)},onInsertBefore:function(){E(Object(f.first)(Object(f.castArray)(t)))},onInsertAfter:function(){_(Object(f.last)(Object(f.castArray)(t)))},onMoveTo:function(){w(!0),I(t[0]),S(t[0])},onGroup:function(){if(p.length){var e=b(),n=Object(c.switchToBlockType)(p,e);n&&k(t,n)}},onUngroup:function(){if(p.length){var e=p[0].innerBlocks;e.length&&k(t,e)}},onCopy:function(){var e=p.map((function(e){return e.clientId}));1===p.length&&C(e[0]),B("copy",e)}})}var Vs=Object(p.compose)([Object(v.withSelect)((function(e,t){var n=t.clientId,r=e("core/block-editor"),o=r.getBlock,i=r.getBlockMode,a=r.getSettings,l=o(n),s=a().codeEditingEnabled;return{mode:i(n),blockType:l?Object(c.getBlockType)(l.name):null,isCodeEditingEnabled:s}})),Object(v.withDispatch)((function(e,t){var n=t.onToggle,r=void 0===n?f.noop:n,o=t.clientId;return{onToggleMode:function(){e("core/block-editor").toggleBlockMode(o),r()}}}))])((function(e){var t=e.blockType,n=e.mode,r=e.onToggleMode,o=e.small,i=void 0!==o&&o,a=e.isCodeEditingEnabled,l=void 0===a||a;if(!Object(c.hasBlockSupport)(t,"html",!0)||!l)return null;var s="visual"===n?Object(g.__)("Edit as HTML"):Object(g.__)("Edit visually");return Object(u.createElement)(h.MenuItem,{onClick:r},!i&&s)}));var Hs=Object(p.compose)(Object(v.withSelect)((function(e,t){var n=t.clientId,r=e("core/block-editor").getBlock(n);return{block:r,shouldRender:r&&"core/html"===r.name}})),Object(v.withDispatch)((function(e,t){var n=t.block;return{onClick:function(){return e("core/block-editor").replaceBlocks(n.clientId,Object(c.rawHandler)({HTML:Object(c.getBlockContent)(n)}))}}})))((function(e){var t=e.shouldRender,n=e.onClick,r=e.small;if(!t)return null;var o=Object(g.__)("Convert to Blocks");return Object(u.createElement)(h.MenuItem,{onClick:n},!r&&o)})),zs=Object(h.createSlotFill)("__experimentalBlockSettingsMenuFirstItem"),Us=zs.Fill,Gs=zs.Slot;Us.Slot=Gs;var Ks=Us;function Ws(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function qs(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ws(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ws(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var $s=Object(h.createSlotFill)("BlockSettingsMenuControls"),Ys=$s.Fill,Xs=$s.Slot;Ys.Slot=function(e){var t=e.fillProps,n=e.clientIds,r=void 0===n?null:n,o=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getBlocksByClientId,o=t.getSelectedBlockClientIds,c=null!==r?r:o();return Object(f.map)(Object(f.compact)(n(c)),(function(e){return e.name}))}),[r]);return Object(u.createElement)(Xs,{fillProps:qs(qs({},t),{},{selectedBlocks:o})},(function(e){return!Object(f.isEmpty)(e)&&Object(u.createElement)(h.MenuGroup,null,e)}))};var Qs=Ys,Zs={className:"block-editor-block-settings-menu__popover",position:"bottom right",isAlternate:!0};var Js=function(e){var t=e.clientIds,n=e.__experimentalSelectBlock,r=e.children,o=Object(he.a)(e,["clientIds","__experimentalSelectBlock","children"]),i=Object(f.castArray)(t),a=i.length,s=i[0],d=Object(v.useSelect)((function(e){var t=e("core/keyboard-shortcuts").getShortcutRepresentation;return{duplicate:t("core/block-editor/duplicate"),remove:t("core/block-editor/remove"),insertAfter:t("core/block-editor/insert-after"),insertBefore:t("core/block-editor/insert-before")}}),[]),b=Object(u.useCallback)(n?function(){var e=Object(gr.a)(Or.a.mark((function e(t){var r;return Or.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t;case 2:(r=e.sent)&&r[0]&&n(r[0]);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}():f.noop,[n]),p=1===a?Object(g.__)("Remove block"):Object(g.__)("Remove blocks");return Object(u.createElement)(Fs,{clientIds:t,__experimentalUpdateSelection:!n},(function(e){var n=e.canDuplicate,i=e.canInsertDefaultBlock,m=e.isLocked,v=e.onDuplicate,O=e.onInsertAfter,j=e.onInsertBefore,k=e.onRemove,y=e.onCopy,_=e.onMoveTo,E=e.blocks;return Object(u.createElement)(h.DropdownMenu,Object(l.a)({icon:hr.a,label:Object(g.__)("More options"),className:"block-editor-block-settings-menu",popoverProps:Zs,noIcons:!0},o),(function(e){var o=e.onClose;return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.MenuGroup,null,Object(u.createElement)(Ks.Slot,{fillProps:{onClose:o}}),1===a&&Object(u.createElement)(Hs,{clientId:s}),Object(u.createElement)(h.ClipboardButton,{text:function(){return Object(c.serialize)(E)},role:"menuitem",className:"components-menu-item__button",onCopy:y},Object(g.__)("Copy")),n&&Object(u.createElement)(h.MenuItem,{onClick:Object(f.flow)(o,v,b),shortcut:d.duplicate},Object(g.__)("Duplicate")),i&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.MenuItem,{onClick:Object(f.flow)(o,j),shortcut:d.insertBefore},Object(g.__)("Insert Before")),Object(u.createElement)(h.MenuItem,{onClick:Object(f.flow)(o,O),shortcut:d.insertAfter},Object(g.__)("Insert After"))),!m&&Object(u.createElement)(h.MenuItem,{onClick:Object(f.flow)(o,_)},Object(g.__)("Move To")),1===a&&Object(u.createElement)(Vs,{clientId:s,onToggle:o})),Object(u.createElement)(Qs.Slot,{fillProps:{onClose:o},clientIds:t}),"function"==typeof r?r({onClose:o}):u.Children.map((function(e){return Object(u.cloneElement)(e,{onClose:o})})),Object(u.createElement)(h.MenuGroup,null,!m&&Object(u.createElement)(h.MenuItem,{onClick:Object(f.flow)(o,k,b),shortcut:d.remove},p)))}))}))};var eu=function(e){var t=e.clientIds,n=Object(he.a)(e,["clientIds"]);return Object(u.createElement)(h.ToolbarGroup,null,Object(u.createElement)(h.ToolbarItem,null,(function(e){return Object(u.createElement)(Js,Object(l.a)({clientIds:t,toggleProps:e},n))})))},tu=window,nu=tu.clearTimeout,ru=tu.setTimeout;function ou(e){var t=e.ref,n=e.isFocused,r=e.debounceTimeout,o=void 0===r?200:r,c=e.onChange,i=void 0===c?f.noop:c,a=Object(u.useState)(!1),l=Object(re.a)(a,2),s=l[0],d=l[1],b=Object(u.useRef)(),p=function(e){(null==t?void 0:t.current)&&d(e),i(e)},m=function(){var e=(null==t?void 0:t.current)&&t.current.matches(":hover");return!n&&!e},v=function(){var e=b.current;e&&nu&&nu(e)};return Object(u.useEffect)((function(){return function(){return v()}}),[]),{showMovers:s,debouncedShowMovers:function(e){e&&e.stopPropagation(),v(),s||p(!0)},debouncedHideMovers:function(e){e&&e.stopPropagation(),v(),b.current=ru((function(){m()&&p(!1)}),o)}}}var cu=n(278);function iu(e){var t=e.hideDragHandle,n=e.__experimentalExpandedControl,r=void 0!==n&&n,o=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getBlockName,r=t.getBlockMode,o=t.getSelectedBlockClientIds,i=t.isBlockValid,a=t.getBlockRootClientId,l=t.getSettings,s=o(),u=s[0],d=a(u),b=l();return{blockClientIds:s,blockClientId:u,blockType:u&&Object(c.getBlockType)(n(u)),hasFixedToolbar:b.hasFixedToolbar,hasReducedUI:b.hasReducedUI,rootClientId:d,isValid:s.every((function(e){return i(e)})),isVisual:s.every((function(e){return"visual"===r(e)}))}}),[]),i=o.blockClientIds,a=o.blockClientId,s=o.blockType,d=o.hasFixedToolbar,m=o.hasReducedUI,g=o.isValid,j=o.isVisual,k=Object(v.useDispatch)("core/block-editor").toggleBlockHighlight,y=Object(u.useRef)(),_=function(e){var t=e.ref,n=e.debounceTimeout,r=void 0===n?200:n,o=e.onChange,c=void 0===o?f.noop:o,i=Object(u.useState)(!1),a=Object(re.a)(i,2),l=a[0],s=a[1],d=ou({ref:t,debounceTimeout:r,isFocused:l,onChange:c}),b=d.showMovers,p=d.debouncedShowMovers,m=d.debouncedHideMovers,v=Object(u.useRef)(!1),O=function(){return(null==t?void 0:t.current)&&t.current.contains(t.current.ownerDocument.activeElement)};return Object(u.useEffect)((function(){var e=t.current,n=function(){O()&&(s(!0),p())},r=function(){O()||(s(!1),m())};return e&&!v.current&&(e.addEventListener("focus",n,!0),e.addEventListener("blur",r,!0),v.current=!0),function(){e&&(e.removeEventListener("focus",n),e.removeEventListener("blur",r))}}),[t,v,s,p,m]),{showMovers:b,gestures:{onMouseMove:p,onMouseLeave:m}}}({ref:y,onChange:function(e){e&&m||k(a,e)}}),E=_.showMovers,C=_.gestures,S=Object(p.useViewportMatch)("medium","<")||d;if(s&&!Object(c.hasBlockSupport)(s,"__experimentalToolbar",!0))return null;var w=S||E;if(0===i.length)return null;var I=g&&j,B=i.length>1,x=b()("block-editor-block-toolbar",w&&"is-showing-movers"),P=r?cu.a:"div";return Object(u.createElement)(P,{className:x},Object(u.createElement)("div",Object(l.a)({ref:y},C),!B&&Object(u.createElement)("div",{className:"block-editor-block-toolbar__block-parent-selector-wrapper"},Object(u.createElement)(ks,{clientIds:i})),(I||B)&&Object(u.createElement)(h.ToolbarGroup,{className:"block-editor-block-toolbar__block-controls"},Object(u.createElement)(Rs,{clientIds:i}),Object(u.createElement)(js,{clientIds:i,hideDragHandle:t||m}))),I&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(O.a.Slot,{bubblesVirtually:!0,className:"block-editor-block-toolbar__slot"}),Object(u.createElement)(mr.Slot,{bubblesVirtually:!0,className:"block-editor-block-toolbar__slot"})),Object(u.createElement)(eu,{clientIds:i}))}var au=function(e){var t=e.focusOnMount,n=Object(he.a)(e,["focusOnMount"]),r=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getBlockName,r=t.getSelectedBlockClientIds,o=e("core/blocks").getBlockType,c=r()[0];return{blockType:c&&o(n(c))}}),[]).blockType;return r&&!Object(c.hasBlockSupport)(r,"__experimentalToolbar",!0)?null:Object(u.createElement)("div",{className:"block-editor-block-contextual-toolbar-wrapper"},Object(u.createElement)(vs,Object(l.a)({focusOnMount:t,className:"block-editor-block-contextual-toolbar","aria-label":Object(g.__)("Block tools")},n),Object(u.createElement)(iu,null)))};function lu(e){var t=e("core/block-editor"),n=t.isNavigationMode,r=t.isMultiSelecting,o=t.hasMultiSelection,c=t.isTyping,i=t.isCaretWithinFormattedText,a=t.getSettings,l=t.getLastMultiSelectedBlockClientId;return{isNavigationMode:n(),isMultiSelecting:r(),isTyping:c(),isCaretWithinFormattedText:i(),hasMultiSelection:o(),hasFixedToolbar:a().hasFixedToolbar,lastClientId:l()}}function su(e){var t=e.clientId,n=e.rootClientId,r=e.isValid,o=e.isEmptyDefaultBlock,c=e.capturingClientId,i=Object(v.useSelect)(lu,[]),l=i.isNavigationMode,s=i.isMultiSelecting,d=i.isTyping,f=i.isCaretWithinFormattedText,m=i.hasMultiSelection,O=i.hasFixedToolbar,g=i.lastClientId,j=Object(p.useViewportMatch)("medium"),k=Object(u.useState)(!1),y=Object(re.a)(k,2),_=y[0],E=y[1],C=Object(u.useState)(!1),S=Object(re.a)(C,2),w=S[0],I=S[1],B=Object(u.useContext)(fu),x=!d&&!l&&o&&r,P=l,T=!l&&!O&&j&&!x&&!s&&(!d||f),N=!(l||T||O||o);if(Object(a.useShortcut)("core/block-editor/focus-toolbar",Object(u.useCallback)((function(){return E(!0)}),[]),{bindGlobal:!0,eventName:"keydown",isDisabled:!N}),!(P||T||_||x))return null;var D=B[t];if(c&&(D=document.getElementById("block-"+c)),!D)return null;var R=D;if(m){var A=B[g];if(!A)return null;R={top:D,bottom:A}}var M=x?"top left right":"top right left";return Object(u.createElement)(h.Popover,{noArrow:!0,animate:!1,position:M,focusOnMount:!1,anchorRef:R,className:"block-editor-block-list__block-popover",__unstableSticky:!x,__unstableSlotName:"block-toolbar",__unstableBoundaryParent:!0,__unstableObserveElement:D,onBlur:function(){return E(!1)},shouldAnchorIncludePadding:!0},(T||_)&&Object(u.createElement)("div",{onFocus:function(){I(!0)},onBlur:function(){I(!1)},tabIndex:-1,className:b()("block-editor-block-list__block-popover-inserter",{"is-visible":w})},Object(u.createElement)(cs,{clientId:t,rootClientId:n,__experimentalIsQuick:!0})),(T||_)&&Object(u.createElement)(au,{focusOnMount:_}),P&&Object(u.createElement)(ps,{clientId:t,rootClientId:n}),x&&Object(u.createElement)("div",{className:"block-editor-block-list__empty-block-inserter"},Object(u.createElement)(cs,{position:"bottom right",rootClientId:n,clientId:t,__experimentalIsQuick:!0})))}function uu(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientId,r=t.getFirstMultiSelectedBlockClientId,o=t.getBlockRootClientId,i=t.__unstableGetBlockWithoutInnerBlocks,a=t.getBlockParents,l=t.__experimentalGetBlockListSettingsForBlocks,s=n()||r();if(s){var u,d=i(s)||{},b=d.name,p=d.attributes,m=void 0===p?{}:p,v=d.isValid,O=a(s),g=l(O),h=Object(f.findIndex)(g,["__experimentalCaptureToolbars",!0]);return-1!==h&&(u=O[h]),{clientId:s,rootClientId:o(s),name:b,isValid:v,isEmptyDefaultBlock:b&&Object(c.isUnmodifiedDefaultBlock)({name:b,attributes:m}),capturingClientId:u}}}function du(){var e=Object(v.useSelect)(uu,[]);if(!e)return null;var t=e.clientId,n=e.rootClientId,r=e.name,o=e.isValid,c=e.isEmptyDefaultBlock,i=e.capturingClientId;return r?Object(u.createElement)(su,{clientId:t,rootClientId:n,isValid:o,isEmptyDefaultBlock:c,capturingClientId:i}):null}var bu=Object(u.createContext)(),fu=Object(u.createContext)(),pu=Object(u.createContext)();function mu(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientId,r=t.hasMultiSelection;return{selectedBlockClientId:n(),hasMultiSelection:r()}}function vu(e){Ye(e.target)&&e.preventDefault()}var Ou=Object(u.forwardRef)((function(e,t){var n=e.children,r=e.className,o=Object(v.useSelect)(mu,[]),c=o.selectedBlockClientId,i=o.hasMultiSelection,a=Object(v.useDispatch)("core/block-editor").selectBlock,l=function(e){var t=Object(v.useSelect)(ro,[]),n=t.isSelectionEnabled,r=t.isMultiSelecting,o=t.multiSelectedBlockClientIds,c=t.hasMultiSelection,i=t.getBlockParents,a=t.selectedBlockClientId,l=Object(v.useDispatch)("core/block-editor"),s=l.startMultiSelect,d=l.stopMultiSelect,b=l.multiSelect,f=l.selectBlock,p=Object(u.useRef)(),m=Object(u.useRef)(),O=Object(u.useRef)();Object(u.useEffect)((function(){var t=e.current.ownerDocument,n=t.defaultView;if(c&&!r){var i=o.length;if(!(i<2)){var l=o[0],s=o[i-1],u=qe(l),d=qe(s),b=n.getSelection(),f=t.createRange();u=no(u,"start"),d=no(d,"end"),f.setStartBefore(u),f.setEndAfter(d),b.removeAllRanges(),b.addRange(f)}}else{if(!a||r)return;var p=n.getSelection();if(p.rangeCount&&!p.isCollapsed){var m=qe(a),v=p.getRangeAt(0),O=v.startContainer,g=v.endContainer;!m||m.contains(O)&&m.contains(g)||p.removeAllRanges()}}}),[c,r,o,f,a]);var g=Object(u.useCallback)((function(t){var n=t.isSelectionEnd,r=e.current.ownerDocument.defaultView.getSelection();if(r.rangeCount&&!r.isCollapsed){var o=Ye(r.focusNode);if(m.current===o){if(f(o),n&&(oo(e.current,!0),r.rangeCount)){var c=r.getRangeAt(0).commonAncestorContainer;O.current.contains(c)&&O.current.focus()}}else{var a=[].concat(Object(ne.a)(i(m.current)),[m.current]),l=[].concat(Object(ne.a)(i(o)),[o]),s=Math.min(a.length,l.length)-1;b(a[s],l[s])}}else oo(e.current,!0)}),[f,i,b]),h=Object(u.useCallback)((function(){var t=e.current.ownerDocument,n=t.defaultView;t.removeEventListener("selectionchange",g),n.removeEventListener("mouseup",h),p.current=n.requestAnimationFrame((function(){g({isSelectionEnd:!0}),d()}))}),[g,d]);return Object(u.useEffect)((function(){var t=e.current.ownerDocument,n=t.defaultView;return function(){t.removeEventListener("selectionchange",g),n.removeEventListener("mouseup",h),n.cancelAnimationFrame(p.current)}}),[g,h]),Object(u.useCallback)((function(t){if(n){var r=e.current.ownerDocument,o=r.defaultView;m.current=t,O.current=r.activeElement,s(),r.addEventListener("selectionchange",g),o.addEventListener("mouseup",h),oo(e.current,!1)}}),[n,s,h])}(t),s=Object(u.useState)({}),d=Object(re.a)(s,2),f=d[0],p=d[1];return Object(u.createElement)(fs,{containerRef:t},Object(u.createElement)(fu.Provider,{value:f},Object(u.createElement)(du,null),Object(u.createElement)("div",{ref:t,className:b()(r,"is-root-container"),onFocus:function(e){if(!i){var t=Ye(e.target);t&&t!==c&&a(t)}},onDragStart:vu},Object(u.createElement)(pu.Provider,{value:p},Object(u.createElement)(bu.Provider,{value:l},n)))))})),gu=["p","div","h1","h2","h3","h4","h5","h6","ol","ul","li","figure","nav","pre","header","section","aside","footer","main"];function hu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ju(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?hu(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ku(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.__unstableIsHtml,r=Object(u.useRef)(),o=e.ref||r,c=Object(u.useContext)(bu),i=Object(u.useContext)(pu),a=Object(u.useContext)(Su),l=a.clientId,d=a.rootClientId,p=a.isSelected,m=a.isFirstMultiSelected,O=a.isLastMultiSelected,h=a.isPartOfMultiSelection,j=a.enableAnimation,k=a.index,y=a.className,_=a.name,E=a.mode,C=a.blockTitle,S=a.wrapperProps,w=void 0===S?{}:S,I=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getSelectedBlocksInitialCaretPosition,r=t.isMultiSelecting,o=t.isNavigationMode;return{shouldFocusFirstElement:p&&!r()&&!o(),initialPosition:p?n():void 0,isNavigationMode:o}}),[p]),B=I.initialPosition,x=I.shouldFocusFirstElement,P=I.isNavigationMode,T=Object(v.useDispatch)("core/block-editor"),N=T.insertDefaultBlock,D=T.removeBlock,R=Object(u.useState)(!1),A=Object(re.a)(R,2),M=A[0],L=A[1];Object(u.useEffect)((function(){if(p||m||O){var e=o.current;return i((function(t){return ju(ju({},t),{},Object(s.a)({},l,e))})),function(){i((function(e){return Object(f.omit)(e,l)}))}}}),[p,m,O]),Object(u.useEffect)((function(){var e=o.current;i((function(t){return t[l]&&t[l]!==e?ju(ju({},t),{},Object(s.a)({},l,e)):t}))}));var F=Object(g.sprintf)(Object(g.__)("Block: %s"),C),V=function(){var e=o.current.ownerDocument;if(!e.activeElement||!$e(o.current,e.activeElement)){var t=kr.focus.tabbable.find(o.current).filter((function(e){return Object(kr.isTextField)(e)&&$e(o.current,e)&&!e.closest(".block-list-appender")})),n=-1===B,r=(n?f.last:f.first)(t)||o.current;Object(kr.placeCaretAtHorizontalEdge)(r,n)}};Object(u.useEffect)((function(){x&&V()}),[x]),Er(o,p||h,p||m,j,k),Object(u.useEffect)((function(){if(p)return o.current.addEventListener("keydown",e),o.current.addEventListener("mouseleave",t),function(){o.current.removeEventListener("mouseleave",t),o.current.removeEventListener("keydown",e)};function e(e){var t=e.keyCode,n=e.target;t!==st.ENTER&&t!==st.BACKSPACE&&t!==st.DELETE||n!==o.current||Object(kr.isTextField)(n)||(e.preventDefault(),t===st.ENTER?N({},d,k+1):D(l))}function t(e){1===e.buttons&&c(l)}}),[p,c,N,D]),Object(u.useEffect)((function(){if(P)return o.current.addEventListener("mouseover",e),o.current.addEventListener("mouseout",t),function(){o.current.removeEventListener("mouseover",e),o.current.removeEventListener("mouseout",t)};function e(e){e.defaultPrevented||(e.preventDefault(),M||L(!0))}function t(e){e.defaultPrevented||(e.preventDefault(),M&&L(!1))}}),[P,M,L]);var H="html"!==E||n?"":"-visual";return ju(ju(ju({},w),e),{},{ref:o,id:"block-".concat(l).concat(H),tabIndex:0,role:"group","aria-label":F,"data-block":l,"data-type":_,"data-title":C,className:b()(y,e.className,w.className,{"is-hovered":M}),style:ju(ju({},w.style),e.style)})}ku.save=c.__unstableGetBlockProps;var yu=Object(u.forwardRef)((function(e,t){var n=e.children,r=e.tagName,o=void 0===r?"div":r,c=Object(he.a)(e,["children","tagName"]);to()("wp.blockEditor.__experimentalBlock",{alternative:"wp.blockEditor.useBlockProps"});var i=ku(ju(ju({},c),{},{ref:t}));return Object(u.createElement)(o,i,n)})),_u=gu.reduce((function(e,t){return e[t]=Object(u.forwardRef)((function(e,n){return Object(u.createElement)(yu,Object(l.a)({},e,{ref:n,tagName:t}))})),e}),yu);function Eu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Cu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Eu(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Eu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Su=Object(u.createContext)();function wu(e){var t=e.children,n=e.isHtml,r=Object(he.a)(e,["children","isHtml"]);return Object(u.createElement)("div",ku(r,{__unstableIsHtml:n}),t)}var Iu=Object(v.withSelect)((function(e,t){var n=t.clientId,r=t.rootClientId,o=e("core/block-editor"),c=o.isBlockSelected,i=o.isAncestorMultiSelected,a=o.isBlockMultiSelected,l=o.isFirstMultiSelectedBlock,s=o.getLastMultiSelectedBlockClientId,u=o.isTyping,d=o.getBlockMode,b=o.isSelectionEnabled,f=o.hasSelectedInnerBlock,p=o.getTemplateLock,m=o.__unstableGetBlockWithoutInnerBlocks,v=o.getMultiSelectedBlockClientIds,O=m(n),g=c(n),h=p(r),j=f(n,!0),k=O||{},y=k.name,_=k.attributes,E=k.isValid,C=l(n);return{isMultiSelected:a(n),isPartOfMultiSelection:a(n)||i(n),isFirstMultiSelected:C,isLastMultiSelected:s()===n,multiSelectedClientIds:C?v():void 0,isTypingWithinBlock:(g||j)&&u(),mode:d(n),isSelectionEnabled:b(),isLocked:!!h,block:O,name:y,attributes:_,isValid:E,isSelected:g,isAncestorOfSelectedBlock:j}})),Bu=Object(v.withDispatch)((function(e,t,n){var r=n.select,o=e("core/block-editor"),i=o.updateBlockAttributes,a=o.insertBlocks,l=o.mergeBlocks,s=o.replaceBlocks,u=o.toggleSelection,d=o.__unstableMarkLastChangeAsPersistent;return{setAttributes:function(e){var n=t.clientId,r=t.isFirstMultiSelected,o=t.multiSelectedClientIds;i(r?o:[n],e)},onInsertBlocks:function(e,n){var r=t.rootClientId;a(e,n,r)},onInsertBlocksAfter:function(e){var n=t.clientId,o=t.rootClientId,c=(0,r("core/block-editor").getBlockIndex)(n,o);a(e,c+1,o)},onMerge:function(e){var n=t.clientId,o=r("core/block-editor"),c=o.getPreviousBlockClientId,i=o.getNextBlockClientId;if(e){var a=i(n);a&&l(n,a)}else{var s=c(n);s&&l(s,n)}},onReplace:function(e,n,r){e.length&&!Object(c.isUnmodifiedDefaultBlock)(e[e.length-1])&&d(),s([t.clientId],e,n,r)},toggleSelection:function(e){u(e)}}})),xu=Object(p.compose)(p.pure,Iu,Bu,Object(p.ifCondition)((function(e){return!!e.block})),Object(h.withFilters)("editor.BlockListBlock"))((function(e){var t,n,r,o=e.mode,i=e.isLocked,a=e.clientId,s=e.rootClientId,d=e.isSelected,m=e.isMultiSelected,O=e.isPartOfMultiSelection,g=e.isFirstMultiSelected,h=e.isLastMultiSelected,j=e.isTypingWithinBlock,k=e.isAncestorOfSelectedBlock,y=e.isSelectionEnabled,_=e.className,E=e.name,C=e.isValid,S=e.attributes,w=e.wrapperProps,I=e.setAttributes,B=e.onReplace,x=e.onInsertBlocksAfter,P=e.onMerge,T=e.toggleSelection,N=e.index,D=e.enableAnimation,R=e.activeEntityBlockId,A=Object(p.useViewportMatch)("medium"),M=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.isBlockBeingDragged,r=t.isBlockHighlighted,o=t.getSettings;return{isDragging:n(a),isHighlighted:r(a),isFocusMode:o().focusMode}}),[a]),L=M.isDragging,F=M.isHighlighted,V=M.isFocusMode,H=Object(v.useDispatch)("core/block-editor").removeBlock,z=Object(u.useCallback)((function(){return H(a)}),[a]),U=Object(u.useState)(!1),G=Object(re.a)(U,2),K=G[0],W=G[1],q=Object(c.getBlockType)(E),$=q.apiVersion>1||Object(c.hasBlockSupport)(q,"lightBlockWrapper",!1),Y=E===Object(c.getUnregisteredTypeHandlerName)();q.getEditWrapperProps&&(t=w,n=q.getEditWrapperProps(S),r=Cu(Cu({},t),n),t&&n&&t.className&&n.className&&(r.className=b()(t.className,n.className)),t&&n&&t.style&&n.style&&(r.style=Cu(Cu({},t.style),n.style)),w=r);var X=$&&Object(c.hasBlockSupport)(q,"className",!0)?Object(c.getBlockDefaultClassName)(E):null,Q=$?S.className:null,Z=w&&!!w["data-align"],J=b()(X,Q,"block-editor-block-list__block",{"wp-block":!Z,"has-warning":!C||!!K||Y,"is-selected":d&&!L,"is-highlighted":F,"is-multi-selected":m,"is-reusable":Object(c.isReusableBlock)(q),"is-dragging":L,"is-typing":j,"is-focused":V&&A&&(d||k),"is-focus-mode":V&&A,"has-child-selected":k&&!L,"is-active-entity":R===a},_),ee=Object(u.createElement)(ur,{name:E,isSelected:d,attributes:S,setAttributes:I,insertBlocksAfter:i?void 0:x,onReplace:i?void 0:B,onRemove:i?void 0:z,mergeBlocks:i?void 0:P,clientId:a,isSelectionEnabled:y,toggleSelection:T});if(Z){var te={"data-align":w["data-align"]};ee=Object(u.createElement)("div",Object(l.a)({className:"wp-block"},te),ee)}var ne,oe={clientId:a,rootClientId:s,isSelected:d,isFirstMultiSelected:g,isLastMultiSelected:h,isPartOfMultiSelection:O,enableAnimation:D,index:N,className:J,isLocked:i,name:E,mode:o,blockTitle:q.title,wrapperProps:Object(f.omit)(w,["data-align"])},ce=Object(u.useMemo)((function(){return oe}),Object.values(oe));return ne=C?"html"===o?Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{style:{display:"none"}},ee),Object(u.createElement)(wu,{isHtml:!0},Object(u.createElement)(Jr,{clientId:a}))):$?ee:Object(u.createElement)(wu,w,ee):Object(u.createElement)(wu,null,Object(u.createElement)(Wr,{clientId:a}),Object(u.createElement)("div",null,Object(c.getSaveElement)(q,S))),Object(u.createElement)(Su.Provider,{value:ce},Object(u.createElement)(Xr,{onError:function(){return W(!0)}},ne),!!K&&Object(u.createElement)(wu,null,Object(u.createElement)($r,null)))})),Pu=function(e,t,n){return Object(g.sprintf)(Object(g.__)("Block %1$d of %2$d, Level %3$d"),e,t,n)};var Tu=Object(u.forwardRef)((function e(t,n){var r=t.className,o=t.block,i=t.isSelected,a=t.onClick,l=t.position,s=t.siblingBlockCount,d=t.level,f=t.tabIndex,m=t.onFocus,v=t.onDragStart,O=t.onDragEnd,j=t.draggable,k=o.name,y=o.attributes,_=Object(c.getBlockType)(k),E=Object(c.__experimentalGetBlockLabel)(_,y),C=Object(p.useInstanceId)(e),S="block-navigation-block-select-button__".concat(C),w=Pu(l,s,d);return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.Button,{className:b()("block-editor-block-navigation-block-select-button",r),onClick:a,"aria-describedby":S,ref:n,tabIndex:f,onFocus:m,onDragStart:v,onDragEnd:O,draggable:j},Object(u.createElement)(qn,{icon:_.icon,showColors:!0}),E,i&&Object(u.createElement)(h.VisuallyHidden,null,Object(g.__)("(selected block)"))),Object(u.createElement)("div",{className:"block-editor-block-navigation-block-select-button__description",id:S},w))}));function Nu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Du(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Nu(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Nu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ru=function(e){return"BlockNavigationBlock-".concat(e)};var Au=Object(u.forwardRef)((function e(t,n){var r=Object(p.useInstanceId)(e),o=t.block.clientId;return Object(u.createElement)(h.Slot,{name:Ru(o)},(function(e){if(!e.length)return Object(u.createElement)(Tu,Object(l.a)({ref:n},t));var o=t.className,i=t.block,a=t.isSelected,s=t.position,d=t.siblingBlockCount,f=t.level,p=t.tabIndex,m=t.onFocus,v=i.name,O=Object(c.getBlockType)(v),j="block-navigation-block-slot__".concat(r),k=Pu(s,d,f),y={tabIndex:p,onFocus:m,ref:n,"aria-describedby":j};return Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{className:b()("block-editor-block-navigation-block-slot",o)},Object(u.createElement)(qn,{icon:O.icon,showColors:!0}),u.Children.map(e,(function(e){return Object(u.cloneElement)(e,Du(Du({},e.props),y))})),a&&Object(u.createElement)(h.VisuallyHidden,null,Object(g.__)("(selected block)")),Object(u.createElement)("div",{className:"block-editor-block-navigation-block-slot__description",id:j},k)))}))})),Mu=function(e){var t=Object(u.useContext)(Su).clientId;return Object(u.createElement)(h.Fill,Object(l.a)({},e,{name:Ru(t)}))},Lu=Object(u.forwardRef)((function(e,t){var n=e.onClick,r=e.block,o=e.isSelected,c=e.position,i=e.siblingBlockCount,a=e.level,s=Object(he.a)(e,["onClick","block","isSelected","position","siblingBlockCount","level"]),d=Fr(),f=d.__experimentalFeatures,p=d.blockDropTarget,m=void 0===p?{}:p,O=r.clientId,g=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getBlockRootClientId,r=t.hasBlockMovingClientId,o=t.getSelectedBlockClientId;return{rootClientId:n(O)||"",blockMovingClientId:r(),selectedBlockInBlockEditor:o()}}),[O]),h=g.rootClientId,j=g.blockMovingClientId,k=g.selectedBlockInBlockEditor,y=j&&k===O,_=m.rootClientId,E=m.clientId,C=m.dropPosition,S=_===h&&E===O&&"top"===C,w=_===h&&E===O&&"bottom"===C,I=_===O&&"inside"===C,B=b()("block-editor-block-navigation-block-contents",{"is-dropping-before":S||y,"is-dropping-after":w,"is-dropping-to-inner-blocks":I});return Object(u.createElement)(hs,{clientIds:[r.clientId],elementId:"block-navigation-block-".concat(r.clientId)},(function(e){var d=e.isDraggable,b=e.onDraggableStart,p=e.onDraggableEnd;return f?Object(u.createElement)(Au,Object(l.a)({ref:t,className:B,block:r,onClick:n,isSelected:o,position:c,siblingBlockCount:i,level:a,draggable:d&&f,onDragStart:b,onDragEnd:p},s)):Object(u.createElement)(Tu,Object(l.a)({ref:t,className:B,block:r,onClick:n,isSelected:o,position:c,siblingBlockCount:i,level:a,draggable:d&&f,onDragStart:b,onDragEnd:p},s))}))}));function Fu(e){var t=e.block,n=e.isSelected,r=e.onClick,o=e.position,c=e.level,i=e.rowCount,a=e.siblingBlockCount,l=e.showBlockMovers,s=e.terminatedLevels,d=e.path,f=Object(u.useRef)(null),p=Object(u.useState)(!1),m=Object(re.a)(p,2),O=m[0],j=m[1],k=Object(u.useState)(!1),y=Object(re.a)(k,2),_=y[0],E=y[1],C=t.clientId,S=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.isBlockBeingDragged,r=t.isAncestorBeingDragged;return n(C)||r(C)}),[C]),w=Object(v.useDispatch)("core/block-editor").selectBlock,I=l&&a>0,B=O||_,x=b()("block-editor-block-navigation-block__mover-cell",{"is-visible":B}),P=Fr().__experimentalFeatures,T=b()("block-editor-block-navigation-block__menu-cell",{"is-visible":B});return Object(u.useEffect)((function(){P&&n&&f.current.focus()}),[P,n]),Object(u.createElement)(Sr,{className:b()({"is-selected":n,"is-dragging":S}),onMouseEnter:function(){return j(!0)},onMouseLeave:function(){return j(!1)},onFocus:function(){return E(!0)},onBlur:function(){return E(!1)},level:c,position:o,rowCount:i,path:d,id:"block-navigation-block-".concat(C),"data-block":C},Object(u.createElement)(h.__experimentalTreeGridCell,{className:"block-editor-block-navigation-block__contents-cell",colSpan:I?void 0:2,ref:f},(function(e){var l=e.ref,d=e.tabIndex,b=e.onFocus;return Object(u.createElement)("div",{className:"block-editor-block-navigation-block__contents-container"},Object(u.createElement)(Mr,{level:c,isLastRow:o===i,terminatedLevels:s}),Object(u.createElement)(Lu,{block:t,onClick:function(){return r(t.clientId)},isSelected:n,position:o,siblingBlockCount:a,level:c,ref:l,tabIndex:d,onFocus:b}))})),I&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.__experimentalTreeGridCell,{className:x,withoutGridItem:!0},Object(u.createElement)(h.__experimentalTreeGridItem,null,(function(e){var t=e.ref,n=e.tabIndex,r=e.onFocus;return Object(u.createElement)(Rr,{orientation:"vertical",clientIds:[C],ref:t,tabIndex:n,onFocus:r})})),Object(u.createElement)(h.__experimentalTreeGridItem,null,(function(e){var t=e.ref,n=e.tabIndex,r=e.onFocus;return Object(u.createElement)(Ar,{orientation:"vertical",clientIds:[C],ref:t,tabIndex:n,onFocus:r})})))),P&&Object(u.createElement)(h.__experimentalTreeGridCell,{className:T},(function(e){var t=e.ref,n=e.tabIndex,o=e.onFocus;return Object(u.createElement)(Js,{clientIds:[C],icon:hr.a,toggleProps:{ref:t,tabIndex:n,onFocus:o},disableOpenOnArrowDown:!0,__experimentalSelectBlock:r},(function(e){var t=e.onClose;return Object(u.createElement)(h.MenuGroup,null,Object(u.createElement)(h.MenuItem,{onClick:Object(gr.a)(Or.a.mark((function e(){return Or.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w(null);case 2:return e.next=4,w(C);case 4:t();case 5:case"end":return e.stop()}}),e)})))},Object(g.__)("Go to block")))}))})))}function Vu(e){var t=e.parentBlockClientId,n=e.position,r=e.level,o=e.rowCount,c=e.terminatedLevels,i=e.path,a=Object(v.useSelect)((function(e){var n=e("core/block-editor"),r=n.isBlockBeingDragged,o=n.isAncestorBeingDragged;return r(t)||o(t)}),[t]),l=Object(p.useInstanceId)(Vu),s="block-navigation-appender-row__description_".concat(l),d=Object(g.sprintf)(Object(g.__)("Add block at position %1$d, Level %2$d"),n,r);return Object(u.createElement)(Sr,{className:b()({"is-dragging":a}),level:r,position:n,rowCount:o,path:i},Object(u.createElement)(h.__experimentalTreeGridCell,{className:"block-editor-block-navigation-appender__cell",colSpan:"3"},(function(e){var i=e.ref,a=e.tabIndex,l=e.onFocus;return Object(u.createElement)("div",{className:"block-editor-block-navigation-appender__container"},Object(u.createElement)(Mr,{level:r,isLastRow:n===o,terminatedLevels:c}),Object(u.createElement)(cs,{rootClientId:t,__experimentalIsQuick:!0,__experimentalSelectBlockOnInsert:!1,"aria-describedby":s,toggleProps:{ref:i,tabIndex:a,onFocus:l}}),Object(u.createElement)("div",{className:"block-editor-block-navigation-appender__description",id:s},d))})))}function Hu(e){var t=e.blocks,n=e.selectBlock,r=e.selectedBlockClientId,o=e.showAppender,c=e.showBlockMovers,i=e.showNestedBlocks,a=e.parentBlockClientId,l=e.level,s=void 0===l?1:l,d=e.terminatedLevels,b=void 0===d?[]:d,p=e.path,m=void 0===p?[]:p,v=!a,O=Object(f.compact)(t),g=function(e){return o&&!v&&r===e},h=g(a),j=O.length,k=h?j+1:j,y=k;return Object(u.createElement)(u.Fragment,null,Object(f.map)(O,(function(e,t){var a=e.clientId,l=e.innerBlocks,d=t+1,f=k===d?[].concat(Object(ne.a)(b),[s]):b,p=[].concat(Object(ne.a)(m),[d]),v=i&&!!l&&!!l.length,O=g(a);return Object(u.createElement)(u.Fragment,{key:a},Object(u.createElement)(Fu,{block:e,onClick:n,isSelected:r===a,level:s,position:d,rowCount:k,siblingBlockCount:j,showBlockMovers:c,terminatedLevels:b,path:p}),(v||O)&&Object(u.createElement)(Hu,{blocks:l,selectedBlockClientId:r,selectBlock:n,showAppender:o,showBlockMovers:c,showNestedBlocks:i,parentBlockClientId:a,level:s+1,terminatedLevels:f,path:p}))})),h&&Object(u.createElement)(Vu,{parentBlockClientId:a,position:k,rowCount:y,level:s,terminatedLevels:b,path:[].concat(Object(ne.a)(m),[y])}))}function zu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Uu(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return Gu(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Gu(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,i=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return i=e.done,e},e:function(e){a=!0,c=e},f:function(){try{i||null==n.return||n.return()}finally{if(a)throw c}}}}function Gu(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ku(e,t){return t.left<=e.x&&t.right>=e.x&&t.top<=e.y&&t.bottom>=e.y}Hu.defaultProps={selectBlock:function(){}};var Wu=["top","bottom"];function qu(e){var t=Object(u.useState)(),n=Object(re.a)(t,2),r=n[0],o=void 0===r?{}:r,c=n[1],i=ol(o.rootClientId,o.blockIndex),a=Object(h.__unstableUseDropZone)(function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zu(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({element:e,withPosition:!0},i)),l=a.position,d=a.type,b=function(e,t,n){var r=Object(v.useSelect)((function(e){var t=e("core/block-editor");return{canInsertBlocks:t.canInsertBlocks,getBlockRootClientId:t.getBlockRootClientId,getBlockIndex:t.getBlockIndex,getBlockCount:t.getBlockCount,getDraggedBlockClientIds:t.getDraggedBlockClientIds}}),[]),o=r.getBlockRootClientId,c=r.getBlockIndex,i=r.getBlockCount,a=r.getDraggedBlockClientIds,l=r.canInsertBlocks,s=Object(u.useRef)(),d=!!t;return Object(u.useEffect)((function(){if(e.current&&d){var t="default"===n,r=t?a():void 0,u=Array.from(e.current.querySelectorAll("[data-block]"));s.current=u.map((function(e){var n=e.dataset.block,a=o(n);return{clientId:n,rootClientId:a,blockIndex:c(n,a),element:e,isDraggedBlock:!!t&&r.includes(n),innerBlockCount:i(n),canInsertDraggedBlocksAsSibling:!t||l(r,a),canInsertDraggedBlocksAsChild:!t||l(r,n)}}))}}),[e,d,n,l,i,c,o,a]),s}(e,l,d);if(Object(u.useEffect)((function(){if(l){var e=function(e,t){var n,r,o,c,i,a=Uu(e);try{for(a.s();!(i=a.n()).done;){var l=i.value;if(!l.isDraggedBlock){var s=l.element.getBoundingClientRect(),u=il(t,s,Wu),d=Object(re.a)(u,2),b=d[0],f=d[1],p=Ku(t,s);if(void 0===o||b<o||p){o=b;var m=e.indexOf(l),v=e[m-1];if("top"===f&&v&&v.rootClientId===l.rootClientId&&!v.isDraggedBlock?(r=v,n="bottom",c=v.element.getBoundingClientRect()):(r=l,n=f,c=s),p)break}}}}catch(e){a.e(e)}finally{a.f()}if(r){var O="bottom"===n;if(O&&r.canInsertDraggedBlocksAsChild&&(r.innerBlockCount>0||function(e,t){var n=t.left+t.width/2;return e.x>n}(t,c)))return{rootClientId:r.clientId,blockIndex:0,dropPosition:"inside"};if(r.canInsertDraggedBlocksAsSibling){var g=O?1:0;return{rootClientId:r.rootClientId,clientId:r.clientId,blockIndex:r.blockIndex+g,dropPosition:n}}}}(b.current,l);e&&c(e)}}),[b,l]),l)return o}function $u(e){var t=e.__experimentalFeatures,n=Object(he.a)(e,["__experimentalFeatures"]),r=Object(u.useRef)(),o=qu(r);t||(o=void 0);var c=Object(u.useMemo)((function(){return{__experimentalFeatures:t,blockDropTarget:o}}),[t,o]);return Object(u.createElement)(h.__experimentalTreeGrid,{className:"block-editor-block-navigation-tree","aria-label":Object(g.__)("Block navigation structure"),ref:r},Object(u.createElement)(Lr.Provider,{value:c},Object(u.createElement)(Hu,n)))}var Yu=Object(p.compose)(Object(v.withSelect)((function(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientId,r=t.getBlockHierarchyRootClientId,o=t.__unstableGetBlockWithBlockTree,c=t.__unstableGetBlockTree,i=n();return{rootBlocks:c(),rootBlock:i?o(r(i)):null,selectedBlockClientId:i}})),Object(v.withDispatch)((function(e,t){var n=t.onSelect,r=void 0===n?f.noop:n;return{selectBlock:function(t){e("core/block-editor").selectBlock(t),r(t)}}})))((function(e){var t=e.rootBlock,n=e.rootBlocks,r=e.selectedBlockClientId,o=e.selectBlock,c=e.__experimentalFeatures;if(!n||0===n.length)return null;var i=t&&(t.clientId!==r||t.innerBlocks&&0!==t.innerBlocks.length);return Object(u.createElement)("div",{className:"block-editor-block-navigation__container"},Object(u.createElement)("p",{className:"block-editor-block-navigation__label"},Object(g.__)("List view")),i&&Object(u.createElement)($u,{blocks:[t],selectedBlockClientId:r,selectBlock:o,__experimentalFeatures:c,showNestedBlocks:!0}),!i&&Object(u.createElement)($u,{blocks:n,selectedBlockClientId:r,selectBlock:o,__experimentalFeatures:c}))})),Xu=Object(u.createElement)(h.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24"},Object(u.createElement)(h.Path,{d:"M13.8 5.2H3v1.5h10.8V5.2zm-3.6 12v1.5H21v-1.5H10.2zm7.2-6H6.6v1.5h10.8v-1.5z"}));function Qu(e){var t=e.isEnabled,n=e.onToggle,r=e.isOpen,o=e.innerRef,c=Object(he.a)(e,["isEnabled","onToggle","isOpen","innerRef"]);Object(a.useShortcut)("core/edit-post/toggle-block-navigation",Object(u.useCallback)(n,[n]),{bindGlobal:!0,isDisabled:!t});var i=Object(v.useSelect)((function(e){return e("core/keyboard-shortcuts").getShortcutRepresentation("core/edit-post/toggle-block-navigation")}),[]);return Object(u.createElement)(h.Button,Object(l.a)({},c,{ref:o,icon:Xu,"aria-expanded":r,"aria-haspopup":"true",onClick:t?n:void 0,label:Object(g.__)("Outline"),className:"block-editor-block-navigation",shortcut:i,"aria-disabled":!t}))}var Zu=Object(u.forwardRef)((function(e,t){var n=e.isDisabled,r=e.__experimentalFeatures,o=Object(he.a)(e,["isDisabled","__experimentalFeatures"]),c=Object(v.useSelect)((function(e){return!!e("core/block-editor").getBlockCount()}),[])&&!n;return Object(u.createElement)(h.Dropdown,{contentClassName:"block-editor-block-navigation__popover",position:"bottom right",renderToggle:function(e){var n=e.isOpen,r=e.onToggle;return Object(u.createElement)(Qu,Object(l.a)({},o,{innerRef:t,isOpen:n,onToggle:r,isEnabled:c}))},renderContent:function(e){var t=e.onClose;return Object(u.createElement)(Yu,{onSelect:t,__experimentalFeatures:r})}})})),Ju=n(130),ed=[st.rawShortcut.primary("z"),st.rawShortcut.primaryShift("z"),st.rawShortcut.primary("y")],td=Object(u.createElement)(h.KeyboardShortcuts,{bindGlobal:!0,shortcuts:Object(f.fromPairs)(ed.map((function(e){return[e,function(e){return e.preventDefault()}]})))}),nd=function(){return td};function rd(e){return e.filter((function(e){var t=e.type;return/^image\/(?:jpe?g|png|gif)$/.test(t)})).map((function(e){return'<img src="'.concat(Object(As.createBlobURL)(e),'">')})).join("")}var od={position:"bottom right",isAlternate:!0},cd=function(){return Object(u.createElement)("div",{className:"block-editor-format-toolbar"},Object(u.createElement)(h.ToolbarGroup,null,["bold","italic","link","text-color"].map((function(e){return Object(u.createElement)(h.Slot,{name:"RichText.ToolbarControls.".concat(e),key:e})})),Object(u.createElement)(h.Slot,{name:"RichText.ToolbarControls"},(function(e){return 0!==e.length&&Object(u.createElement)(h.ToolbarItem,null,(function(t){return Object(u.createElement)(h.DropdownMenu,{icon:xr.a,label:Object(g.__)("More rich text controls"),toggleProps:t,controls:Object(f.orderBy)(e.map((function(e){return Object(re.a)(e,1)[0].props})),"title"),popoverProps:od})}))}))))},id=function(e){var t=e.inline,n=e.anchorRef;return t?Object(u.createElement)(h.Popover,{noArrow:!0,position:"top center",focusOnMount:!1,anchorRef:n,className:"block-editor-rich-text__inline-format-toolbar"},Object(u.createElement)(cd,null)):Object(u.createElement)(mr,null,Object(u.createElement)(cd,null))};function ad(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ld(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ad(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ad(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function sd(e){if(!0===e||"p"===e||"li"===e)return!0===e?"p":e}function ud(e){var t=e.allowedFormats,n=e.formattingControls;return e.disableFormats?ud.EMPTY_ARRAY:t||n?t||(to()("wp.blockEditor.RichText formattingControls prop",{alternative:"allowedFormats"}),n.map((function(e){return"core/".concat(e)}))):void 0}ud.EMPTY_ARRAY=[];var dd=Object(u.forwardRef)((function e(t,n){var r=t.children,o=t.tagName,a=t.value,s=t.onChange,d=t.isSelected,f=t.multiline,m=t.inlineToolbar,O=t.wrapperClassName,g=t.autocompleters,h=t.onReplace,j=t.placeholder,k=t.keepPlaceholderOnFocus,y=t.allowedFormats,_=t.formattingControls,E=t.withoutInteractiveFormatting,C=t.onRemove,S=t.onMerge,w=t.onSplit,I=t.__unstableOnSplitAtEnd,B=t.__unstableOnSplitMiddle,x=t.identifier,P=t.preserveWhiteSpace,T=t.__unstableEmbedURLOnPaste,N=t.__unstableDisableFormats,D=t.disableLineBreaks,R=t.unstableOnFocus,A=t.__unstableAllowPrefixTransformations,M=t.__unstableMultilineRootTag,L=t.__unstableMobileNoFocusOnMount,F=t.deleteEnter,V=t.placeholderTextColor,H=t.textAlign,U=t.selectionColor,G=t.tagsToEliminate,K=t.rootTagsToEliminate,W=t.disableEditingMenu,q=t.fontSize,$=t.fontFamily,Y=t.fontWeight,X=t.fontStyle,Q=t.minWidth,Z=t.maxWidth,J=t.onBlur,ee=t.setRef,te=Object(he.a)(t,["children","tagName","value","onChange","isSelected","multiline","inlineToolbar","wrapperClassName","autocompleters","onReplace","placeholder","keepPlaceholderOnFocus","allowedFormats","formattingControls","withoutInteractiveFormatting","onRemove","onMerge","onSplit","__unstableOnSplitAtEnd","__unstableOnSplitMiddle","identifier","preserveWhiteSpace","__unstableEmbedURLOnPaste","__unstableDisableFormats","disableLineBreaks","unstableOnFocus","__unstableAllowPrefixTransformations","__unstableMultilineRootTag","__unstableMobileNoFocusOnMount","deleteEnter","placeholderTextColor","textAlign","selectionColor","tagsToEliminate","rootTagsToEliminate","disableEditingMenu","fontSize","fontFamily","fontWeight","fontStyle","minWidth","maxWidth","onBlur","setRef"]),oe=Object(p.useInstanceId)(e);x=x||oe;var ce=Object(u.useRef)(),ie=n||ce,ae=Object(z.b)(),le=ae.clientId,se=ae.onCaretVerticalPositionChange,ue=ae.isSelected,de=Object(v.useSelect)((function(e){var t,n=e("core/block-editor"),r=n.isCaretWithinFormattedText,o=n.getSelectionStart,i=n.getSelectionEnd,a=n.getSettings,l=n.didAutomaticChange,s=n.__unstableGetBlockWithoutInnerBlocks,b=n.isMultiSelecting,f=n.hasMultiSelection,p=o(),m=i(),v=a().__experimentalUndo;void 0===d?t=p.clientId===le&&p.attributeKey===x:d&&(t=p.clientId===le);var O={};if("native"===u.Platform.OS){var g=le&&s(le);O={shouldBlurOnUnmount:g&&t&&Object(c.isUnmodifiedDefaultBlock)(g)}}return ld({isCaretWithinFormattedText:r(),selectionStart:t?p.offset:void 0,selectionEnd:t?m.offset:void 0,isSelected:t,didAutomaticChange:l(),disabled:b()||f(),undo:v},O)})),be=de.isCaretWithinFormattedText,fe=de.selectionStart,pe=de.selectionEnd,me=de.isSelected,ve=de.didAutomaticChange,Oe=de.disabled,ge=de.undo,je=de.shouldBlurOnUnmount,ke=Object(v.useDispatch)("core/block-editor"),ye=ke.__unstableMarkLastChangeAsPersistent,_e=ke.enterFormattedText,Ee=ke.exitFormattedText,Ce=ke.selectionChange,Se=ke.__unstableMarkAutomaticChange,we=sd(f),Ie=ud({allowedFormats:y,formattingControls:_,disableFormats:N}),Be=!Ie||Ie.length>0,xe=a,Pe=s;Array.isArray(a)&&(xe=c.children.toHTML(a),Pe=function(e){return s(c.children.fromDOM(Object(i.__unstableCreateElement)(document,e).childNodes))});var Te=Object(u.useCallback)((function(e,t){Ce(le,x,e,t)}),[le,x]),Ne=Object(u.useCallback)((function(e){var t=e.value,n=e.isReverse;S&&S(!n),C&&Object(i.isEmpty)(t)&&n&&C(!n)}),[S,C]),De=Object(u.useCallback)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if(h&&w){var n=[],r=Object(i.split)(e),o=Object(re.a)(r,2),c=o[0],a=o[1],l=t.length>0,s=-1;l&&Object(i.isEmpty)(c)||(n.push(w(Object(i.toHTMLString)({value:c,multilineTag:we}))),s+=1),l?(n.push.apply(n,Object(ne.a)(t)),s+=t.length):B&&n.push(B()),(l||B)&&Object(i.isEmpty)(a)||n.push(w(Object(i.toHTMLString)({value:a,multilineTag:we})));var u=l?s:1,d=l?-1:null;h(n,u,d)}}),[h,w,we,B]),Re=Object(u.useCallback)((function(e){var t=e.value,n=e.onChange,r=e.shiftKey,o=h&&w;if(h){var a=Object(c.getBlockTransforms)("from").filter((function(e){return"enter"===e.type})),l=Object(c.findTransform)(a,(function(e){return e.regExp.test(t.text)}));l&&(h([l.transform({content:t.text})]),Se())}if(f)r?D||n(Object(i.insert)(t,"\n")):o&&Object(i.__unstableIsEmptyLine)(t)?De(t):n(Object(i.__unstableInsertLineSeparator)(t));else{var s=t.text,u=t.start,d=t.end,b=I&&u===d&&d===s.length;r||!o&&!b?D||n(Object(i.insert)(t,"\n")):!o&&b?I():o&&De(t)}}),[h,w,Se,f,De,I]),Ae=Object(u.useCallback)((function(e){var t=e.value,n=e.onChange,r=e.html,a=e.plainText,l=e.files,s=e.activeFormats;if(l&&l.length&&!r){var u=Object(c.pasteHandler)({HTML:rd(l),mode:"BLOCKS",tagName:o,preserveWhiteSpace:P});return window.console.log("Received items:\n\n",l),void(h&&Object(i.isEmpty)(t)?h(u):De(t,u))}var d,b=h&&w?"AUTO":"INLINE";"AUTO"===b&&Object(i.isEmpty)(t)&&(d=a,Object(Ju.regexp)(".*").test(d))&&(b="BLOCKS"),T&&Object(i.isEmpty)(t)&&Object(zl.isURL)(a.trim())&&(b="BLOCKS");var p=Object(c.pasteHandler)({HTML:r,plainText:a,mode:b,tagName:o,preserveWhiteSpace:P});if("string"==typeof p){var m=Object(i.create)({html:p});if(s.length)for(var v=m.formats.length;v--;)m.formats[v]=[].concat(Object(ne.a)(s),Object(ne.a)(m.formats[v]||[]));f&&(m=Object(i.replace)(m,/\n+/g,i.__UNSTABLE_LINE_SEPARATOR)),n(Object(i.insert)(t,m))}else p.length>0&&(h&&Object(i.isEmpty)(t)?h(p,p.length-1,-1):De(t,p))}),[o,h,w,De,T,f,P]),Me=Object(u.useCallback)((function(e,t){if(h){var n=e.start,r=e.text;if(" "===r.slice(n-1,n)){var o=r.slice(0,n).trim(),a=Object(c.getBlockTransforms)("from").filter((function(e){return"prefix"===e.type})),l=Object(c.findTransform)(a,(function(e){var t=e.prefix;return o===t}));if(l){var s=t(Object(i.slice)(e,n,r.length)),u=l.transform(s);h([u]),Se()}}}}),[h,Se]),Le=Object(u.createElement)(i.__experimentalRichText,{clientId:le,identifier:x,ref:ie,value:xe,onChange:Pe,selectionStart:fe,selectionEnd:pe,onSelectionChange:Te,tagName:o,placeholder:j,allowedFormats:Ie,withoutInteractiveFormatting:E,onEnter:Re,onDelete:Ne,onPaste:Ae,__unstableIsSelected:me,__unstableInputRule:Me,__unstableMultilineTag:we,__unstableIsCaretWithinFormattedText:be,__unstableOnEnterFormattedText:_e,__unstableOnExitFormattedText:Ee,__unstableOnCreateUndoLevel:ye,__unstableMarkAutomaticChange:Se,__unstableDidAutomaticChange:ve,__unstableUndo:ge,__unstableDisableFormats:N,preserveWhiteSpace:P,disabled:Oe,unstableOnFocus:R,__unstableAllowPrefixTransformations:A,__unstableMultilineRootTag:M,onCaretVerticalPositionChange:se,blockIsSelected:void 0!==d?d:ue,shouldBlurOnUnmount:je,__unstableMobileNoFocusOnMount:L,deleteEnter:F,placeholderTextColor:V,textAlign:H,selectionColor:U,tagsToEliminate:G,rootTagsToEliminate:K,disableEditingMenu:W,fontSize:q,fontFamily:$,fontWeight:Y,fontStyle:X,minWidth:Q,maxWidth:Z,onBlur:J,setRef:ee,id:te.id,style:te.style},(function(e){var t=e.isSelected,n=e.value,o=e.onChange,c=e.onFocus,i=e.editableProps,a=e.editableTagName;return Object(u.createElement)(u.Fragment,null,r&&r({value:n,onChange:o,onFocus:c}),t&&Be&&Object(u.createElement)(id,{inline:m,anchorRef:ie.current}),t&&Object(u.createElement)(nd,null),Object(u.createElement)(Xn,{onReplace:h,completers:g,record:n,onChange:o,isSelected:t},(function(e){var t=e.listBoxId,n=e.activeId,r=e.onKeyDown;return Object(u.createElement)(a,Object(l.a)({},i,te,{style:te.style?ld(ld({},te.style),i.style):i.style,className:b()("block-editor-rich-text__editable",te.className,i.className,{"keep-placeholder-on-focus":k}),"aria-autocomplete":t?"list":void 0,"aria-owns":t,"aria-activedescendant":n,onKeyDown:function(e){r(e),i.onKeyDown(e)}}))})))}));return O?(to()("wp.blockEditor.RichText wrapperClassName prop",{alternative:"className prop or create your own wrapper div"}),Object(u.createElement)("div",{className:b()("block-editor-rich-text",O)},Le)):Le}));dd.Content=function(e){var t=e.value,n=e.tagName,r=e.multiline,o=Object(he.a)(e,["value","tagName","multiline"]);Array.isArray(t)&&(t=c.children.toHTML(t));var i=sd(r);!t&&i&&(t="<".concat(i,"></").concat(i,">"));var a=Object(u.createElement)(u.RawHTML,null,t);return n?Object(u.createElement)(n,Object(f.omit)(o,["format"]),a):a},dd.isEmpty=function(e){return!e||0===e.length},dd.Content.defaultProps={format:"string",value:""};var bd=dd;function fd(e){var t=e.value,n=e.onChange;return Object(u.createElement)(Mu,null,Object(u.createElement)(bd,{value:t,onChange:n,placeholder:Object(g.__)("Navigation item"),keepPlaceholderOnFocus:!0,withoutInteractiveFormatting:!0,allowedFormats:["core/bold","core/italic","core/image","core/strikethrough"]}))}var pd=n(318);var md=function(e){var t=e.icon,n=void 0===t?pd.a:t,r=e.label,o=void 0===r?Object(g.__)("Choose variation"):r,c=e.instructions,i=void 0===c?Object(g.__)("Select a variation to start with."):c,a=e.variations,l=e.onSelect,s=e.allowSkip,d=b()("block-editor-block-variation-picker",{"has-many-variations":a.length>4});return Object(u.createElement)(h.Placeholder,{icon:n,label:o,instructions:i,className:d},Object(u.createElement)("ul",{className:"block-editor-block-variation-picker__variations",role:"list","aria-label":Object(g.__)("Block variations")},a.map((function(e){return Object(u.createElement)("li",{key:e.name},Object(u.createElement)(h.Button,{isSecondary:!0,icon:e.icon,iconSize:48,onClick:function(){return l(e)},className:"block-editor-block-variation-picker__variation",label:e.description||e.title}),Object(u.createElement)("span",{className:"block-editor-block-variation-picker__variation-label",role:"presentation"},e.title))}))),s&&Object(u.createElement)("div",{className:"block-editor-block-variation-picker__skip"},Object(u.createElement)(h.Button,{isLink:!0,onClick:function(){return l()}},Object(g.__)("Skip"))))},vd=Object(u.createElement)(h.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(h.Path,{d:"M15 4H9v11h6V4zM4 18.5V20h16v-1.5H4z"})),Od=Object(u.createElement)(h.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(h.Path,{d:"M20 11h-5V4H9v7H4v1.5h5V20h6v-7.5h5z"}));function gd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function hd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?gd(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var jd={top:{icon:Object(u.createElement)(h.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(h.Path,{d:"M9 20h6V9H9v11zM4 4v1.5h16V4H4z"})),title:Object(g._x)("Vertically Align Top","Block vertical alignment setting")},center:{icon:Od,title:Object(g._x)("Vertically Align Middle","Block vertical alignment setting")},bottom:{icon:vd,title:Object(g._x)("Vertically Align Bottom","Block vertical alignment setting")}},kd=["top","center","bottom"],yd={isAlternate:!0};var _d=function(e){var t=e.value,n=e.onChange,r=e.controls,o=void 0===r?kd:r,c=e.isCollapsed,i=void 0===c||c,a=jd[t],l=jd.top;return Object(u.createElement)(h.ToolbarGroup,{popoverProps:yd,isCollapsed:i,icon:a?a.icon:l.icon,label:Object(g._x)("Change vertical alignment","Block vertical alignment setting label"),controls:o.map((function(e){return hd(hd({},jd[e]),{},{isActive:t===e,role:i?"menuitemradio":void 0,onClick:(r=e,function(){return n(t===r?void 0:r)})});var r}))})};function Ed(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Cd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ed(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ed(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Sd=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=de("color.palette"),r=!de("color.custom"),o=void 0===t.colors?n:t.colors,c=void 0===t.disableCustomColors?r:t.disableCustomColors,i=!Object(f.isEmpty)(o)||!c;return Object(u.createElement)(e,Cd(Cd({},t),{},{colors:o,disableCustomColors:c,hasColorsToChoose:i}))}}),"withColorContext"),wd=Sd(h.ColorPalette);function Id(e){var t=e.onChange,n=e.value,r=Object(he.a)(e,["onChange","value"]);return Object(u.createElement)(Ie,Object(l.a)({},r,{onColorChange:t,colorValue:n,gradients:[],disableCustomGradients:!0}))}var Bd=[];function xd(e){var t=de("color.gradients")||Bd,n=!de("color.customGradient");return Object(u.createElement)(h.__experimentalGradientPicker,Object(l.a)({gradients:void 0!==e.gradients?e.gradient:t,disableCustomGradients:void 0!==e.disableCustomGradients?e.disableCustomGradients:n},e))}var Pd=function(e){var t=void 0!==e.gradients&&void 0!==e.disableCustomGradients?h.__experimentalGradientPicker:xd;return Object(u.createElement)(t,e)};function Td(e){var t=e.className,n=e.value,r=e.onChange,o=e.label,c=void 0===o?Object(g.__)("Gradient Presets"):o,i=Object(he.a)(e,["className","value","onChange","label"]),a=de("color.gradients"),s=!de("color.customGradient");return Object(f.isEmpty)(a)&&s?null:Object(u.createElement)(h.BaseControl,{className:b()("block-editor-gradient-picker-control",t)},Object(u.createElement)(h.BaseControl.VisualLabel,null,c),Object(u.createElement)(Pd,Object(l.a)({value:n,onChange:r,className:"block-editor-gradient-picker-control__gradient-picker-presets",gradients:a,disableCustomGradients:s},i)))}function Nd(e){var t=de("color.gradients");return Object(f.isEmpty)(t)?null:Object(u.createElement)(h.PanelBody,{title:Object(g.__)("Gradient")},Object(u.createElement)(Td,e))}var Dd=[25,50,75,100];function Rd(e){var t,n,r=e.imageWidth,o=e.imageHeight,c=e.imageSizeOptions,i=void 0===c?[]:c,a=e.isResizable,l=void 0===a||a,s=e.slug,d=e.width,b=e.height,p=e.onChange,m=e.onChangeImage,v=void 0===m?f.noop:m;function O(e,t){return function(){p({width:e,height:t})}}return Object(u.createElement)(u.Fragment,null,!Object(f.isEmpty)(i)&&Object(u.createElement)(h.SelectControl,{label:Object(g.__)("Image size"),value:s,options:i,onChange:v}),l&&Object(u.createElement)("div",{className:"block-editor-image-size-control"},Object(u.createElement)("p",{className:"block-editor-image-size-control__row"},Object(g.__)("Image dimensions")),Object(u.createElement)("div",{className:"block-editor-image-size-control__row"},Object(u.createElement)(h.TextControl,{type:"number",className:"block-editor-image-size-control__width",label:Object(g.__)("Width"),value:null!==(t=null!=d?d:r)&&void 0!==t?t:"",min:1,onChange:function(e){return p({width:parseInt(e,10)})}}),Object(u.createElement)(h.TextControl,{type:"number",className:"block-editor-image-size-control__height",label:Object(g.__)("Height"),value:null!==(n=null!=b?b:o)&&void 0!==n?n:"",min:1,onChange:function(e){return p({height:parseInt(e,10)})}})),Object(u.createElement)("div",{className:"block-editor-image-size-control__row"},Object(u.createElement)(h.ButtonGroup,{"aria-label":Object(g.__)("Image size presets")},Dd.map((function(e){var t=Math.round(r*(e/100)),n=Math.round(o*(e/100)),c=d===t&&b===n;return Object(u.createElement)(h.Button,{key:e,isSmall:!0,isPrimary:c,isPressed:c,onClick:O(t,n)},e,"%")}))),Object(u.createElement)(h.Button,{isSmall:!0,onClick:O()},Object(g.__)("Reset")))))}var Ad=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=Object(z.b)().clientId;return Object(u.createElement)(e,Object(l.a)({},t,{clientId:n}))}}),"withClientId"),Md=Ad((function(e){var t=e.clientId,n=e.showSeparator,r=e.isFloating,o=e.onAddBlock;return Object(u.createElement)(Qa,{rootClientId:t,showSeparator:n,isFloating:r,onAddBlock:o})})),Ld=Object(p.compose)([Ad,Object(v.withSelect)((function(e,t){var n=t.clientId,r=(0,e("core/block-editor").getBlockOrder)(n);return{lastBlockClientId:Object(f.last)(r)}}))])((function(e){var t=e.clientId,n=e.lastBlockClientId;return Object(u.createElement)(Xa,{rootClientId:t,lastBlockClientId:n})})),Fd=n(64),Vd=n.n(Fd);var Hd=new WeakMap;function zd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ud(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zd(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Gd(e){var t=e.clientId,n=e.allowedBlocks,r=e.template,o=e.templateLock,i=e.wrapperRef,a=e.templateInsertUpdatesSelection,l=e.__experimentalCaptureToolbars,s=e.__experimentalAppenderTagName,d=e.renderAppender,b=e.orientation,p=e.placeholder;!function(e,t,n,r,o){var c=Object(v.useDispatch)("core/block-editor").updateBlockListSettings,i=Object(v.useSelect)((function(t){var n=t("core/block-editor").getBlockRootClientId(e);return{blockListSettings:t("core/block-editor").getBlockListSettings(e),parentLock:t("core/block-editor").getTemplateLock(n)}}),[e]),a=i.blockListSettings,l=i.parentLock;Object(u.useLayoutEffect)((function(){var i={allowedBlocks:t,templateLock:void 0===n?l:n};void 0!==r&&(i.__experimentalCaptureToolbars=r),void 0!==o&&(i.orientation=o),Vd()(a,i)||c(e,i)}),[e,a,t,n,l,r,o,c])}(t,n,o,l,b),function(e,t,n,r){var o=Object(v.useDispatch)("core/block-editor").replaceInnerBlocks,i=Object(v.useSelect)((function(t){return t("core/block-editor").getBlocks(e)}),[e]),a=Object(u.useRef)(null);Object(u.useLayoutEffect)((function(){if((0===i.length||"all"===n)&&!Object(f.isEqual)(t,a.current)){a.current=t;var l=Object(c.synchronizeBlocksWithTemplate)(i,t);Object(f.isEqual)(l,i)||o(e,l,0===i.length&&r&&0!==l.length)}}),[i,n,e])}(t,r,o,a);var m=Object(v.useSelect)((function(e){var n=e("core/block-editor").getBlock(t),r=Object(c.getBlockType)(n.name);if(r&&r.providesContext)return function(e,t){Hd.has(t)||Hd.set(t,new WeakMap);var n=Hd.get(t);if(!n.has(e)){var r=Object(f.mapValues)(t.providesContext,(function(t){return e[t]}));n.set(e,r)}return n.get(e)}(n.attributes,r)}),[t]);return Object(u.createElement)(rr,{value:m},Object(u.createElement)(dl,{rootClientId:t,renderAppender:d,__experimentalAppenderTagName:s,wrapperRef:i,placeholder:p}))}function Kd(e){return qa(e),Object(u.createElement)(Gd,e)}var Wd=Object(u.forwardRef)((function(e,t){var n=qd({ref:t},e);return Object(u.createElement)("div",{className:"block-editor-inner-blocks"},Object(u.createElement)("div",n))}));function qd(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=Object(u.useRef)(),r=Object(z.b)(),o=r.clientId,c=Object(p.useViewportMatch)("medium","<"),i=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getBlockName,r=t.isBlockSelected,i=t.hasSelectedInnerBlock,a=(0,t.isNavigationMode)()||c;return"core/template"!==n(o)&&!r(o)&&!i(o,!0)&&a}),[o,c]),a=e.ref||n,s=t.value&&t.onChange?Kd:Gd;return Ud(Ud({},e),{},{ref:a,className:b()(e.className,"block-editor-block-list__layout",{"has-overlay":i}),children:Object(u.createElement)(s,Object(l.a)({},t,{clientId:o,wrapperRef:a}))})}Wd.DefaultBlockAppender=Ld,Wd.ButtonBlockAppender=Md,Wd.Content=Object(c.withBlockContentContext)((function(e){var t=e.BlockContent;return Object(u.createElement)(t,null)}));var $d=Wd,Yd=n(216);function Xd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Qd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Xd(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Zd=[{id:"opensInNewTab",title:Object(g.__)("Open in new tab")}],Jd=function(e){var t=e.value,n=e.onChange,r=void 0===n?f.noop:n,o=e.settings,c=void 0===o?Zd:o;if(!c||!c.length)return null;var i=function(e){return function(n){r(Qd(Qd({},t),{},Object(s.a)({},e.id,n)))}},a=c.map((function(e){return Object(u.createElement)(h.ToggleControl,{className:"block-editor-link-control__setting",key:e.id,label:e.title,onChange:i(e),checked:!!t&&!!t[e.id]})}));return Object(u.createElement)("fieldset",{className:"block-editor-link-control__settings"},Object(u.createElement)(h.VisuallyHidden,{as:"legend"},Object(g.__)("Currently selected link settings")),a)},eb=n(127),tb=n.n(eb);function nb(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}var rb=function(e){return e.stopPropagation()},ob=function(e){Object(Wt.a)(n,e);var t=nb(n);function n(e){var r;return Object(Ut.a)(this,n),(r=t.call(this,e)).onChange=r.onChange.bind(Object(Kt.a)(r)),r.onFocus=r.onFocus.bind(Object(Kt.a)(r)),r.onKeyDown=r.onKeyDown.bind(Object(Kt.a)(r)),r.selectLink=r.selectLink.bind(Object(Kt.a)(r)),r.handleOnClick=r.handleOnClick.bind(Object(Kt.a)(r)),r.bindSuggestionNode=r.bindSuggestionNode.bind(Object(Kt.a)(r)),r.autocompleteRef=e.autocompleteRef||Object(u.createRef)(),r.inputRef=Object(u.createRef)(),r.updateSuggestions=Object(f.debounce)(r.updateSuggestions.bind(Object(Kt.a)(r)),200),r.suggestionNodes=[],r.isUpdatingSuggestions=!1,r.state={suggestions:[],showSuggestions:!1,selectedSuggestion:null,suggestionsListboxId:"",suggestionOptionIdPrefix:""},r}return Object(Gt.a)(n,[{key:"componentDidUpdate",value:function(e){var t=this,n=this.state,r=n.showSuggestions,o=n.selectedSuggestion,c=this.props.value;r&&null!==o&&this.suggestionNodes[o]&&!this.scrollingIntoView&&(this.scrollingIntoView=!0,tb()(this.suggestionNodes[o],this.autocompleteRef.current,{onlyScrollIfNeeded:!0}),this.props.setTimeout((function(){t.scrollingIntoView=!1}),100)),e.value!==c&&this.shouldShowInitialSuggestions()&&this.updateSuggestions()}},{key:"componentDidMount",value:function(){this.shouldShowInitialSuggestions()&&this.updateSuggestions()}},{key:"componentWillUnmount",value:function(){delete this.suggestionsRequest}},{key:"bindSuggestionNode",value:function(e){var t=this;return function(n){t.suggestionNodes[e]=n}}},{key:"shouldShowInitialSuggestions",value:function(){var e=this.state.suggestions,t=this.props,n=t.__experimentalShowInitialSuggestions,r=void 0!==n&&n,o=t.value;return!this.isUpdatingSuggestions&&r&&!(o&&o.length)&&!(e&&e.length)}},{key:"updateSuggestions",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=this.props,r=n.__experimentalFetchLinkSuggestions,o=n.__experimentalHandleURLSuggestions;if(r){var c=!(t&&t.length);if(c||!(t.length<2||!o&&Object(zl.isURL)(t))){this.isUpdatingSuggestions=!0,this.setState({selectedSuggestion:null,loading:!0});var i=r(t,{isInitialSuggestions:c});i.then((function(t){e.suggestionsRequest===i&&(e.setState({suggestions:t,loading:!1,showSuggestions:!!t.length}),t.length?e.props.debouncedSpeak(Object(g.sprintf)(Object(g._n)("%d result found, use up and down arrow keys to navigate.","%d results found, use up and down arrow keys to navigate.",t.length),t.length),"assertive"):e.props.debouncedSpeak(Object(g.__)("No results."),"assertive"),e.isUpdatingSuggestions=!1)})).catch((function(){e.suggestionsRequest===i&&(e.setState({loading:!1}),e.isUpdatingSuggestions=!1)})),this.suggestionsRequest=i}else this.setState({showSuggestions:!1,selectedSuggestion:null,loading:!1})}}},{key:"onChange",value:function(e){var t=e.target.value;this.props.onChange(t),this.props.disableSuggestions||this.updateSuggestions(t.trim())}},{key:"onFocus",value:function(){var e=this.state.suggestions,t=this.props,n=t.disableSuggestions,r=t.value;!r||n||this.isUpdatingSuggestions||e&&e.length||this.updateSuggestions(r.trim())}},{key:"onKeyDown",value:function(e){var t=this.state,n=t.showSuggestions,r=t.selectedSuggestion,o=t.suggestions,c=t.loading;if(n&&o.length&&!c){var i=this.state.suggestions[this.state.selectedSuggestion];switch(e.keyCode){case st.UP:e.stopPropagation(),e.preventDefault();var a=r?r-1:o.length-1;this.setState({selectedSuggestion:a});break;case st.DOWN:e.stopPropagation(),e.preventDefault();var l=null===r||r===o.length-1?0:r+1;this.setState({selectedSuggestion:l});break;case st.TAB:null!==this.state.selectedSuggestion&&(this.selectLink(i),this.props.speak(Object(g.__)("Link selected.")));break;case st.ENTER:null!==this.state.selectedSuggestion&&(e.stopPropagation(),this.selectLink(i))}}else switch(e.keyCode){case st.UP:0!==e.target.selectionStart&&(e.stopPropagation(),e.preventDefault(),e.target.setSelectionRange(0,0));break;case st.DOWN:this.props.value.length!==e.target.selectionStart&&(e.stopPropagation(),e.preventDefault(),e.target.setSelectionRange(this.props.value.length,this.props.value.length))}}},{key:"selectLink",value:function(e){this.props.onChange(e.url,e),this.setState({selectedSuggestion:null,showSuggestions:!1})}},{key:"handleOnClick",value:function(e){this.selectLink(e),this.inputRef.current.focus()}},{key:"render",value:function(){return Object(u.createElement)(u.Fragment,null,this.renderControl(),this.renderSuggestions())}},{key:"renderControl",value:function(){var e=this.props,t=e.label,n=e.className,r=e.isFullWidth,o=e.instanceId,c=e.placeholder,i=void 0===c?Object(g.__)("Paste URL or type to search"):c,a=e.__experimentalRenderControl,l=e.value,s=void 0===l?"":l,d=e.autoFocus,f=void 0===d||d,p=this.state,m=p.loading,v=p.showSuggestions,O=p.selectedSuggestion,j=p.suggestionsListboxId,k=p.suggestionOptionIdPrefix,y={id:"url-input-control-".concat(o),label:t,className:b()("block-editor-url-input",n,{"is-full-width":r})},_={value:s,required:!0,autoFocus:f,className:"block-editor-url-input__input",type:"text",onChange:this.onChange,onFocus:this.onFocus,onInput:rb,placeholder:i,onKeyDown:this.onKeyDown,role:"combobox","aria-label":Object(g.__)("URL"),"aria-expanded":v,"aria-autocomplete":"list","aria-owns":j,"aria-activedescendant":null!==O?"".concat(k,"-").concat(O):void 0,ref:this.inputRef};return a?a(y,_,m):Object(u.createElement)(h.BaseControl,y,Object(u.createElement)("input",_),m&&Object(u.createElement)(h.Spinner,null))}},{key:"renderSuggestions",value:function(){var e=this,t=this.props,n=t.className,r=t.__experimentalRenderSuggestions,o=t.value,c=void 0===o?"":o,i=t.__experimentalShowInitialSuggestions,a=void 0!==i&&i,s=this.state,d=s.showSuggestions,p=s.suggestions,m=s.selectedSuggestion,v=s.suggestionsListboxId,O=s.suggestionOptionIdPrefix,g=s.loading,j={id:v,ref:this.autocompleteRef,role:"listbox"},k=function(t,n){return{role:"option",tabIndex:"-1",id:"".concat(O,"-").concat(n),ref:e.bindSuggestionNode(n),"aria-selected":n===m}};return Object(f.isFunction)(r)&&d&&p.length?r({suggestions:p,selectedSuggestion:m,suggestionsListProps:j,buildSuggestionItemProps:k,isLoading:g,handleSuggestionClick:this.handleOnClick,isInitialSuggestions:a&&!(c&&c.length)}):!Object(f.isFunction)(r)&&d&&p.length?Object(u.createElement)(h.Popover,{position:"bottom",noArrow:!0,focusOnMount:!1},Object(u.createElement)("div",Object(l.a)({},j,{className:b()("block-editor-url-input__suggestions","".concat(n,"__suggestions"))}),p.map((function(t,n){return Object(u.createElement)(h.Button,Object(l.a)({},k(0,n),{key:t.id,className:b()("block-editor-url-input__suggestion",{"is-selected":n===m}),onClick:function(){return e.handleOnClick(t)}}),t.title)})))):null}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n=e.value,r=e.instanceId,o=e.disableSuggestions,c=e.__experimentalShowInitialSuggestions,i=void 0!==c&&c,a=t.showSuggestions,l=n&&n.length;return i||l||(a=!1),!0===o&&(a=!1),{showSuggestions:a,suggestionsListboxId:"block-editor-url-input-suggestions-".concat(r),suggestionOptionIdPrefix:"block-editor-url-input-suggestion-".concat(r)}}}]),n}(u.Component),cb=Object(p.compose)(p.withSafeTimeout,h.withSpokenMessages,p.withInstanceId,Object(v.withSelect)((function(e,t){if(!Object(f.isFunction)(t.__experimentalFetchLinkSuggestions))return{__experimentalFetchLinkSuggestions:(0,e("core/block-editor").getSettings)().__experimentalFetchLinkSuggestions}})))(ob),ib=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(u.createElement)(j.Path,{d:"M10 1c-5 0-9 4-9 9s4 9 9 9 9-4 9-9-4-9-9-9zm0 16c-3.9 0-7-3.1-7-7s3.1-7 7-7 7 3.1 7 7-3.1 7-7 7zm1-11H9v3H6v2h3v3h2v-3h3V9h-3V6zM10 1c-5 0-9 4-9 9s4 9 9 9 9-4 9-9-4-9-9-9zm0 16c-3.9 0-7-3.1-7-7s3.1-7 7-7 7 3.1 7 7-3.1 7-7 7zm1-11H9v3H6v2h3v3h2v-3h3V9h-3V6z"})),ab=function(e){var t,n=e.searchTerm,r=e.onClick,o=e.itemProps,c=e.isSelected,i=e.buttonText;return n?(t=i?Object(f.isFunction)(i)?i(n):i:Object(u.createInterpolateElement)(Object(g.sprintf)(Object(g.__)("Create: <mark>%s</mark>"),n),{mark:Object(u.createElement)("mark",null)}),Object(u.createElement)(h.Button,Object(l.a)({},o,{className:b()("block-editor-link-control__search-create block-editor-link-control__search-item",{"is-selected":c}),onClick:r}),Object(u.createElement)(so.a,{className:"block-editor-link-control__search-item-icon",icon:ib}),Object(u.createElement)("span",{className:"block-editor-link-control__search-item-header"},Object(u.createElement)("span",{className:"block-editor-link-control__search-item-title"},t)))):null},lb=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(u.createElement)(j.Path,{d:"M9 0C4.03 0 0 4.03 0 9s4.03 9 9 9 9-4.03 9-9-4.03-9-9-9zM1.11 9.68h2.51c.04.91.167 1.814.38 2.7H1.84c-.403-.85-.65-1.764-.73-2.7zm8.57-5.4V1.19c.964.366 1.756 1.08 2.22 2 .205.347.386.708.54 1.08l-2.76.01zm3.22 1.35c.232.883.37 1.788.41 2.7H9.68v-2.7h3.22zM8.32 1.19v3.09H5.56c.154-.372.335-.733.54-1.08.462-.924 1.255-1.64 2.22-2.01zm0 4.44v2.7H4.7c.04-.912.178-1.817.41-2.7h3.21zm-4.7 2.69H1.11c.08-.936.327-1.85.73-2.7H4c-.213.886-.34 1.79-.38 2.7zM4.7 9.68h3.62v2.7H5.11c-.232-.883-.37-1.788-.41-2.7zm3.63 4v3.09c-.964-.366-1.756-1.08-2.22-2-.205-.347-.386-.708-.54-1.08l2.76-.01zm1.35 3.09v-3.04h2.76c-.154.372-.335.733-.54 1.08-.464.92-1.256 1.634-2.22 2v-.04zm0-4.44v-2.7h3.62c-.04.912-.178 1.817-.41 2.7H9.68zm4.71-2.7h2.51c-.08.936-.327 1.85-.73 2.7H14c.21-.87.337-1.757.38-2.65l.01-.05zm0-1.35c-.046-.894-.176-1.78-.39-2.65h2.16c.403.85.65 1.764.73 2.7l-2.5-.05zm1-4H13.6c-.324-.91-.793-1.76-1.39-2.52 1.244.56 2.325 1.426 3.14 2.52h.04zm-9.6-2.52c-.597.76-1.066 1.61-1.39 2.52H2.65c.815-1.094 1.896-1.96 3.14-2.52zm-3.15 12H4.4c.324.91.793 1.76 1.39 2.52-1.248-.567-2.33-1.445-3.14-2.55l-.01.03zm9.56 2.52c.597-.76 1.066-1.61 1.39-2.52h1.76c-.82 1.08-1.9 1.933-3.14 2.48l-.01.04z"})),sb=function(e){var t=e.itemProps,n=e.suggestion,r=e.isSelected,o=void 0!==r&&r,c=e.onClick,i=e.isURL,a=void 0!==i&&i,s=e.searchTerm,d=void 0===s?"":s,f=e.shouldShowType,p=void 0!==f&&f;return Object(u.createElement)(h.Button,Object(l.a)({},t,{onClick:c,className:b()("block-editor-link-control__search-item",{"is-selected":o,"is-url":a,"is-entity":!a})}),a&&Object(u.createElement)(so.a,{className:"block-editor-link-control__search-item-icon",icon:lb}),Object(u.createElement)("span",{className:"block-editor-link-control__search-item-header"},Object(u.createElement)("span",{className:"block-editor-link-control__search-item-title"},Object(u.createElement)(h.TextHighlight,{text:n.title,highlight:d})),Object(u.createElement)("span",{"aria-hidden":!a,className:"block-editor-link-control__search-item-info"},!a&&(Object(zl.filterURLForDisplay)(Object(zl.safeDecodeURI)(n.url))||""),a&&Object(g.__)("Press ENTER to add this link"))),p&&n.type&&Object(u.createElement)("span",{className:"block-editor-link-control__search-item-type"},"post_tag"===n.type?"tag":n.type))};function ub(e){var t=e.instanceId,n=e.withCreateSuggestion,r=e.currentInputValue,o=e.handleSuggestionClick,c=e.suggestionsListProps,i=e.buildSuggestionItemProps,a=e.suggestions,s=e.selectedSuggestion,d=e.isLoading,f=e.isInitialSuggestions,p=e.createSuggestionButtonText,m=e.suggestionsQuery,v=b()("block-editor-link-control__search-results",{"is-loading":d}),O=["url","mailto","tel","internal"],j=1===a.length&&O.includes(a[0].type.toLowerCase()),k=n&&!j&&!f,y=!(null==m?void 0:m.type),_="block-editor-link-control-search-results-label-".concat(t),E=f?Object(g.__)("Recently updated"):Object(g.sprintf)(Object(g.__)('Search results for "%s"'),r),C=Object(u.createElement)(f?u.Fragment:h.VisuallyHidden,{},Object(u.createElement)("span",{className:"block-editor-link-control__search-results-label",id:_},E));return Object(u.createElement)("div",{className:"block-editor-link-control__search-results-wrapper"},C,Object(u.createElement)("div",Object(l.a)({},c,{className:v,"aria-labelledby":_}),a.map((function(e,t){return k&&"__CREATE__"===e.type?Object(u.createElement)(ab,{searchTerm:r,buttonText:p,onClick:function(){return o(e)},key:e.type,itemProps:i(e,t),isSelected:t===s}):"__CREATE__"===e.type?null:Object(u.createElement)(sb,{key:"".concat(e.id,"-").concat(e.type),itemProps:i(e,t),suggestion:e,index:t,onClick:function(){o(e)},isSelected:t===s,isURL:O.includes(e.type.toLowerCase()),searchTerm:r,shouldShowType:y})}))))}function db(e){var t=Object(f.startsWith)(e,"#");return Object(zl.isURL)(e)||e&&e.includes("www.")||t}function bb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function fb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bb(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var pb=function(){return Promise.resolve([])},mb=function(e){var t="URL",n=Object(zl.getProtocol)(e)||"";return n.includes("mailto")&&(t="mailto"),n.includes("tel")&&(t="tel"),Object(f.startsWith)(e,"#")&&(t="internal"),Promise.resolve([{id:e,title:e,url:"URL"===t?Object(zl.prependHTTP)(e):e,type:t}])},vb=function(){var e=Object(gr.a)(Or.a.mark((function e(t,n,r,o,c,i){var a,l,s;return Or.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=n.isInitialSuggestions,e.next=3,Promise.all([r(t,n),o(t)]);case 3:if(l=e.sent,s=!t.includes(" "),l=s&&i&&!a?l[0].concat(l[1]):l[0],!a){e.next=8;break}return e.abrupt("return",l);case 8:return e.abrupt("return",db(t)||!c?l:l.concat({title:t,url:t,type:"__CREATE__"}));case 9:case"end":return e.stop()}}),e)})));return function(t,n,r,o,c,i){return e.apply(this,arguments)}}();function Ob(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function gb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ob(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ob(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var hb=Promise.resolve([]),jb=Object(u.forwardRef)((function(e,t){var n=e.value,r=e.children,o=e.currentLink,c=void 0===o?{}:o,i=e.className,a=void 0===i?null:i,l=e.placeholder,s=void 0===l?null:l,d=e.withCreateSuggestion,b=void 0!==d&&d,m=e.onCreateSuggestion,O=void 0===m?f.noop:m,h=e.onChange,j=void 0===h?f.noop:h,k=e.onSelect,y=void 0===k?f.noop:k,_=e.showSuggestions,E=void 0===_||_,C=e.renderSuggestions,S=void 0===C?function(e){return Object(u.createElement)(ub,e)}:C,w=e.fetchSuggestions,I=void 0===w?null:w,B=e.allowDirectEntry,x=void 0===B||B,P=e.showInitialSuggestions,T=void 0!==P&&P,N=e.suggestionsQuery,D=void 0===N?{}:N,R=e.withURLSuggestion,A=void 0===R||R,M=e.createSuggestionButtonText,L=function(e,t,n,r){var o=Object(v.useSelect)((function(e){return{fetchSearchSuggestions:(0,e("core/block-editor").getSettings)().__experimentalFetchLinkSuggestions}}),[]).fetchSearchSuggestions,c=t?mb:pb;return Object(u.useCallback)((function(t,i){var a=i.isInitialSuggestions;return db(t)?c(t,{isInitialSuggestions:a}):vb(t,fb(fb({},e),{},{isInitialSuggestions:a}),o,c,n,r)}),[c,o,n])}(D,x,b,A),F=E?I||L:hb,V=Object(p.useInstanceId)(jb),H=Object(u.useState)(),z=Object(re.a)(H,2),U=z[0],G=z[1],K=function(){var e=Object(gr.a)(Or.a.mark((function e(t){var n,r;return Or.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t,"__CREATE__"!==t.type){e.next=12;break}return e.prev=2,e.next=5,O(t.title);case 5:n=e.sent,(null===(r=n)||void 0===r?void 0:r.url)&&y(n),e.next=11;break;case 9:e.prev=9,e.t0=e.catch(2);case 11:return e.abrupt("return");case 12:(x||n&&Object.keys(n).length>=1)&&y(gb(gb({},Object(f.omit)(c,"id","url")),n),n);case 13:case"end":return e.stop()}}),e,null,[[2,9]])})));return function(t){return e.apply(this,arguments)}}();return Object(u.createElement)("form",{onSubmit:function(e){e.preventDefault(),K(U||{url:n})}},Object(u.createElement)(cb,{className:a,value:n,onChange:function(e,t){j(e),G(t)},placeholder:null!=s?s:Object(g.__)("Search or type url"),__experimentalRenderSuggestions:E?function(e){return S(gb(gb({},e),{},{instanceId:V,withCreateSuggestion:b,currentInputValue:n,createSuggestionButtonText:M,suggestionsQuery:D,handleSuggestionClick:function(t){e.handleSuggestionClick&&e.handleSuggestionClick(t),K(t)}}))}:null,__experimentalFetchLinkSuggestions:F,__experimentalHandleURLSuggestions:!0,__experimentalShowInitialSuggestions:T,ref:t}),r)})),kb=jb,yb=Object(h.createSlotFill)("BlockEditorLinkControlViewer"),_b=yb.Slot,Eb=yb.Fill;function Cb(e){var t=e.value,n=e.onEditClick,r=t&&Object(zl.filterURLForDisplay)(Object(zl.safeDecodeURI)(t.url))||"";return Object(u.createElement)("div",{"aria-label":Object(g.__)("Currently selected"),"aria-selected":"true",className:b()("block-editor-link-control__search-item",{"is-current":!0})},Object(u.createElement)("span",{className:"block-editor-link-control__search-item-header"},Object(u.createElement)(h.ExternalLink,{className:"block-editor-link-control__search-item-title",href:t.url},t&&t.title||r),t&&t.title&&Object(u.createElement)("span",{className:"block-editor-link-control__search-item-info"},r)),Object(u.createElement)(h.Button,{isSecondary:!0,onClick:function(){return n()},className:"block-editor-link-control__search-item-action"},Object(g.__)("Edit")),Object(u.createElement)(_b,{fillProps:t}))}var Sb=function(e){var t=!1;return{promise:new Promise((function(n,r){e.then((function(e){return t?r({isCanceled:!0}):n(e)}),(function(e){return r(t?{isCanceled:!0}:e)}))})),cancel:function(){t=!0}}};function wb(e){var t=e.searchInputPlaceholder,n=e.value,r=e.settings,o=e.onChange,c=void 0===o?f.noop:o,i=e.noDirectEntry,a=void 0!==i&&i,l=e.showSuggestions,s=void 0===l||l,d=e.showInitialSuggestions,b=e.forceIsEditingLink,p=e.createSuggestion,m=e.withCreateSuggestion,v=e.inputValue,O=void 0===v?"":v,j=e.suggestionsQuery,k=void 0===j?{}:j,y=e.noURLSuggestion,_=void 0!==y&&y,E=e.createSuggestionButtonText;void 0===m&&p&&(m=!0);var C=Object(u.useRef)(),S=Object(u.useState)(n&&n.url||""),w=Object(re.a)(S,2),I=w[0],B=w[1],x=O||I,P=Object(u.useState)(void 0!==b?b:!n||!n.url),T=Object(re.a)(P,2),N=T[0],D=T[1],R=Object(u.useRef)(!1);Object(u.useEffect)((function(){void 0!==b&&b!==N&&D(b)}),[b]),Object(u.useEffect)((function(){R.current&&C.current&&!C.current.contains(C.current.ownerDocument.activeElement)&&(kr.focus.focusable.find(C.current)[0]||C.current).focus();R.current=!1}),[N]);var A=function(e){var t=Object(u.useRef)(),n=Object(u.useState)(!1),r=Object(re.a)(n,2),o=r[0],c=r[1],i=Object(u.useState)(null),a=Object(re.a)(i,2),l=a[0],s=a[1],d=function(){var n=Object(gr.a)(Or.a.mark((function n(r){return Or.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return c(!0),s(null),n.prev=2,t.current=Sb(Promise.resolve(e(r))),n.next=6,t.current.promise;case 6:return n.abrupt("return",n.sent);case 9:if(n.prev=9,n.t0=n.catch(2),!n.t0||!n.t0.isCanceled){n.next=13;break}return n.abrupt("return");case 13:throw s(n.t0.message||Object(g.__)("An unknown error occurred during creation. Please try again.")),n.t0;case 15:return n.prev=15,c(!1),n.finish(15);case 18:case"end":return n.stop()}}),n,null,[[2,9,15,18]])})));return function(e){return n.apply(this,arguments)}}();return Object(u.useEffect)((function(){return function(){t.current&&t.current.cancel()}}),[]),{createPage:d,isCreatingPage:o,errorMessage:l}}(p),M=A.createPage,L=A.isCreatingPage,F=A.errorMessage;return Object(u.createElement)("div",{tabIndex:-1,ref:C,className:"block-editor-link-control"},L&&Object(u.createElement)("div",{className:"block-editor-link-control__loading"},Object(u.createElement)(h.Spinner,null)," ",Object(g.__)("Creating"),"…"),(N||!n)&&!L&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{className:"block-editor-link-control__search-input-wrapper"},Object(u.createElement)(kb,{currentLink:n,className:"block-editor-link-control__search-input",placeholder:t,value:x,withCreateSuggestion:m,onCreateSuggestion:M,onChange:B,onSelect:function(e){var t;c(e),R.current=!!(null===(t=C.current)||void 0===t?void 0:t.contains(C.current.ownerDocument.activeElement)),D(!1)},showInitialSuggestions:d,allowDirectEntry:!a,showSuggestions:s,suggestionsQuery:k,withURLSuggestion:!_,createSuggestionButtonText:E},Object(u.createElement)("div",{className:"block-editor-link-control__search-actions"},Object(u.createElement)(h.Button,{type:"submit",label:Object(g.__)("Submit"),icon:Yd.a,className:"block-editor-link-control__search-submit"})))),F&&Object(u.createElement)(h.Notice,{className:"block-editor-link-control__search-error",status:"error",isDismissible:!1},F)),n&&!N&&!L&&Object(u.createElement)(Cb,{value:n,onEditClick:function(){return D(!0)}}),Object(u.createElement)(Jd,{value:n,settings:r,onChange:c}))}wb.ViewerFill=Eb;var Ib=wb,Bb=n(319),xb=n(217),Pb=Object(h.withFilters)("editor.MediaUpload")((function(){return null}));var Tb=function(e){var t=e.fallback,n=void 0===t?null:t,r=e.children;return Object(v.useSelect)((function(e){return!!(0,e("core/block-editor").getSettings)().mediaUpload}),[])?r:n},Nb=Object(p.compose)([Object(v.withDispatch)((function(e){var t=e("core/notices");return{createNotice:t.createNotice,removeNotice:t.removeNotice}})),Object(h.withFilters)("editor.MediaReplaceFlow")])((function(e){var t=e.mediaURL,n=e.mediaId,r=e.allowedTypes,o=e.accept,c=e.onSelect,i=e.onSelectURL,a=e.onFilesUpload,l=void 0===a?f.noop:a,s=e.name,d=void 0===s?Object(g.__)("Replace"):s,b=e.createNotice,p=e.removeNotice,m=Object(u.useState)(t),O=Object(re.a)(m,2),j=O[0],k=O[1],y=Object(v.useSelect)((function(e){return e("core/block-editor").getSettings().mediaUpload}),[]),_=Object(u.createRef)(),E=Object(f.uniqueId)("block-editor/media-replace-flow/error-notice/"),C=function(e){var t=document.createElement("div");t.innerHTML=Object(u.renderToString)(e);var n=t.textContent||t.innerText||"";setTimeout((function(){b("error",n,{speak:!0,id:E,isDismissible:!0})}),1e3)},S=function(e){c(e),k(e.url),Object(Le.speak)(Object(g.__)("The media file has been replaced")),p(E)},w=function(e){e.keyCode===st.DOWN&&(e.preventDefault(),e.stopPropagation(),e.target.click())};return Object(u.createElement)(h.Dropdown,{popoverProps:{isAlternate:!0},contentClassName:"block-editor-media-replace-flow__options",renderToggle:function(e){var t=e.isOpen,n=e.onToggle;return Object(u.createElement)(h.ToolbarGroup,{className:"media-replace-flow"},Object(u.createElement)(h.ToolbarButton,{ref:_,"aria-expanded":t,"aria-haspopup":"true",onClick:n,onKeyDown:w},d))},renderContent:function(e){e.onClose;return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.NavigableMenu,{className:"block-editor-media-replace-flow__media-upload-menu"},Object(u.createElement)(Pb,{value:n,onSelect:function(e){return S(e)},allowedTypes:r,render:function(e){var t=e.open;return Object(u.createElement)(h.MenuItem,{icon:Bb.a,onClick:t},Object(g.__)("Open Media Library"))}}),Object(u.createElement)(Tb,null,Object(u.createElement)(h.FormFileUpload,{onChange:function(e){!function(e){var t=e.target.files;l(t);y({allowedTypes:r,filesList:t,onFileChange:function(e){var t=Object(re.a)(e,1)[0];S(t)},onError:C})}(e)},accept:o,render:function(e){var t=e.openFileDialog;return Object(u.createElement)(h.MenuItem,{icon:xb.a,onClick:function(){t()}},Object(g.__)("Upload"))}}))),i&&Object(u.createElement)("form",{className:"block-editor-media-flow__url-input",onKeyDown:function(e){e.stopPropagation()},onKeyPress:function(e){e.stopPropagation()}},Object(u.createElement)("span",{className:"block-editor-media-replace-flow__image-url-label"},Object(g.__)("Current media URL:")),Object(u.createElement)(Ib,{value:{url:j},settings:[],showSuggestions:!1,onChange:function(e){var t=e.url;k(t),i(t),_.current.focus()}})))}})})),Db=n(274);function Rb(e){var t=e.url,n=e.urlLabel,r=e.className,o=b()(r,"block-editor-url-popover__link-viewer-url");return t?Object(u.createElement)(h.ExternalLink,{className:o,href:t},n||Object(zl.filterURLForDisplay)(Object(zl.safeDecodeURI)(t))):Object(u.createElement)("span",{className:o})}function Ab(e){var t=e.additionalControls,n=e.children,r=e.renderSettings,o=e.position,c=void 0===o?"bottom center":o,i=e.focusOnMount,a=void 0===i?"firstElement":i,s=Object(he.a)(e,["additionalControls","children","renderSettings","position","focusOnMount"]),d=Object(u.useState)(!1),b=Object(re.a)(d,2),f=b[0],p=b[1],m=!!r&&f;return Object(u.createElement)(h.Popover,Object(l.a)({className:"block-editor-url-popover",focusOnMount:a,position:c},s),Object(u.createElement)("div",{className:"block-editor-url-popover__input-container"},Object(u.createElement)("div",{className:"block-editor-url-popover__row"},n,!!r&&Object(u.createElement)(h.Button,{className:"block-editor-url-popover__settings-toggle",icon:xr.a,label:Object(g.__)("Link settings"),onClick:function(){p(!f)},"aria-expanded":f})),m&&Object(u.createElement)("div",{className:"block-editor-url-popover__row block-editor-url-popover__settings"},r())),t&&!m&&Object(u.createElement)("div",{className:"block-editor-url-popover__additional-controls"},t))}Ab.LinkEditor=function(e){var t=e.autocompleteRef,n=e.className,r=e.onChangeInputValue,o=e.value,c=Object(he.a)(e,["autocompleteRef","className","onChangeInputValue","value"]);return Object(u.createElement)("form",Object(l.a)({className:b()("block-editor-url-popover__link-editor",n)},c),Object(u.createElement)(cb,{value:o,onChange:r,autocompleteRef:t}),Object(u.createElement)(h.Button,{icon:Yd.a,label:Object(g.__)("Apply"),type:"submit"}))},Ab.LinkViewer=function(e){var t=e.className,n=e.linkClassName,r=e.onEditLinkClick,o=e.url,c=e.urlLabel,i=Object(he.a)(e,["className","linkClassName","onEditLinkClick","url","urlLabel"]);return Object(u.createElement)("div",Object(l.a)({className:b()("block-editor-url-popover__link-viewer",t)},i),Object(u.createElement)(Rb,{url:o,urlLabel:c,className:n}),r&&Object(u.createElement)(h.Button,{icon:Db.a,label:Object(g.__)("Edit"),onClick:r}))};var Mb=Ab,Lb=function(e){var t=e.src,n=e.onChange,r=e.onSubmit,o=e.onClose;return Object(u.createElement)(Mb,{onClose:o},Object(u.createElement)("form",{className:"block-editor-media-placeholder__url-input-form",onSubmit:r},Object(u.createElement)("input",{className:"block-editor-media-placeholder__url-input-field",type:"url","aria-label":Object(g.__)("URL"),placeholder:Object(g.__)("Paste or type URL"),onChange:n,value:t}),Object(u.createElement)(h.Button,{className:"block-editor-media-placeholder__url-input-submit-button",icon:Yd.a,label:Object(g.__)("Apply"),type:"submit"})))};var Fb=Object(h.withFilters)("editor.MediaPlaceholder")((function(e){var t=e.value,n=void 0===t?{}:t,r=e.allowedTypes,o=e.className,c=e.icon,i=e.labels,a=void 0===i?{}:i,l=e.mediaPreview,s=e.notices,d=e.isAppender,p=e.accept,m=e.addToGallery,O=e.multiple,j=void 0!==O&&O,k=e.dropZoneUIOnly,y=e.disableDropZone,_=e.disableMediaButtons,E=e.onError,C=e.onSelect,S=e.onCancel,w=e.onSelectURL,I=e.onDoubleClick,B=e.onFilesPreUpload,x=void 0===B?f.noop:B,P=e.onHTMLDrop,T=void 0===P?f.noop:P,N=e.children,D=Object(v.useSelect)((function(e){return(0,e("core/block-editor").getSettings)().mediaUpload}),[]),R=Object(u.useState)(""),A=Object(re.a)(R,2),M=A[0],L=A[1],F=Object(u.useState)(!1),V=Object(re.a)(F,2),H=V[0],z=V[1];Object(u.useEffect)((function(){var e;L(null!==(e=null==n?void 0:n.src)&&void 0!==e?e:"")}),[null==n?void 0:n.src]);var U=function(e){L(e.target.value)},G=function(){z(!0)},K=function(){z(!1)},W=function(e){e.preventDefault(),M&&w&&(w(M),K())},q=function(e){var t;if(x(e),j)if(m){var o=[];t=function(e){var t=(null!=n?n:[]).filter((function(e){return e.id?!o.some((function(t){var n=t.id;return Number(n)===Number(e.id)})):!o.some((function(t){var n=t.urlSlug;return e.url.includes(n)}))}));C(t.concat(e)),o=e.map((function(e){var t=e.url.lastIndexOf("."),n=e.url.slice(0,t);return{id:e.id,urlSlug:n}}))}}else t=C;else t=function(e){var t=Object(re.a)(e,1)[0];return C(t)};D({allowedTypes:r,filesList:e,onFileChange:t,onError:E})},$=function(e){q(e.target.files)},Y=function(e,t){var n=a.instructions,i=a.title;if(D||w||(n=Object(g.__)("To edit this block, you need permission to upload media.")),void 0===n||void 0===i){var f=null!=r?r:[],p=Object(re.a)(f,1)[0],m=1===f.length,v=m&&"audio"===p,O=m&&"image"===p,j=m&&"video"===p;void 0===n&&D&&(n=Object(g.__)("Upload a media file or pick one from your media library."),v?n=Object(g.__)("Upload an audio file, pick one from your media library, or add one with a URL."):O?n=Object(g.__)("Upload an image file, pick one from your media library, or add one with a URL."):j&&(n=Object(g.__)("Upload a video file, pick one from your media library, or add one with a URL."))),void 0===i&&(i=Object(g.__)("Media"),v?i=Object(g.__)("Audio"):O?i=Object(g.__)("Image"):j&&(i=Object(g.__)("Video")))}var k=b()("block-editor-media-placeholder",o,{"is-appender":d});return Object(u.createElement)(h.Placeholder,{icon:c,label:i,instructions:n,className:k,notices:s,onClick:t,onDoubleClick:I,preview:l},e,N)},X=function(){return y?null:Object(u.createElement)(h.DropZone,{onFilesDrop:q,onHTMLDrop:T})},Q=function(){return S&&Object(u.createElement)(h.Button,{className:"block-editor-media-placeholder__cancel-button",title:Object(g.__)("Cancel"),isLink:!0,onClick:S},Object(g.__)("Cancel"))},Z=function(){return w&&Object(u.createElement)("div",{className:"block-editor-media-placeholder__url-input-container"},Object(u.createElement)(h.Button,{className:"block-editor-media-placeholder__button",onClick:G,isPressed:H,isTertiary:!0},Object(g.__)("Insert from URL")),H&&Object(u.createElement)(Lb,{src:M,onChange:U,onSubmit:W,onClose:K}))};return k||_?(k&&to()("wp.blockEditor.MediaPlaceholder dropZoneUIOnly prop",{alternative:"disableMediaButtons"}),Object(u.createElement)(Tb,null,X())):Object(u.createElement)(Tb,{fallback:Y(Z())},function(){var e=Object(u.createElement)(Pb,{addToGallery:m,gallery:j&&!(!r||0===r.length)&&r.every((function(e){return"image"===e||e.startsWith("image/")})),multiple:j,onSelect:C,allowedTypes:r,value:Array.isArray(n)?n.map((function(e){return e.id})):n.id,render:function(e){var t=e.open;return Object(u.createElement)(h.Button,{isTertiary:!0,onClick:function(e){e.stopPropagation(),t()}},Object(g.__)("Media Library"))}});if(D&&d)return Object(u.createElement)(u.Fragment,null,X(),Object(u.createElement)(h.FormFileUpload,{onChange:$,accept:p,multiple:j,render:function(t){var n=t.openFileDialog,r=Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.Button,{isPrimary:!0,className:b()("block-editor-media-placeholder__button","block-editor-media-placeholder__upload-button")},Object(g.__)("Upload")),e,Z(),Q());return Y(r,n)}}));if(D){var t=Object(u.createElement)(u.Fragment,null,X(),Object(u.createElement)(h.FormFileUpload,{isPrimary:!0,className:b()("block-editor-media-placeholder__button","block-editor-media-placeholder__upload-button"),onChange:$,accept:p,multiple:j},Object(g.__)("Upload")),e,Z(),Q());return Y(t)}return Y(e)}())})),Vb=Object(u.forwardRef)((function(e,t){return Object(u.createElement)(bd,Object(l.a)({ref:t},e,{__unstableDisableFormats:!0,preserveWhiteSpace:!0}))}));Vb.Content=function(e){var t=e.value,n=void 0===t?"":t,r=e.tagName,o=void 0===r?"div":r,c=Object(he.a)(e,["value","tagName"]);return Object(u.createElement)(o,c,n)};var Hb=Vb,zb=Object(u.forwardRef)((function(e,t){var n=e.__experimentalVersion,r=Object(he.a)(e,["__experimentalVersion"]);if(2===n)return Object(u.createElement)(Hb,Object(l.a)({ref:t},r));var o=r.className,c=r.onChange,i=Object(he.a)(r,["className","onChange"]);return Object(u.createElement)(Zr.a,Object(l.a)({ref:t,className:b()("block-editor-plain-text",o),onChange:function(e){return c(e.target.value)}},i))}));function Ub(e){var t=e.property,n=e.viewport,r=e.desc,o=Object(p.useInstanceId)(Ub),c=r||Object(g.sprintf)(Object(g._x)("Controls the %1$s property for %2$s viewports.","Text labelling a interface as controlling a given layout property (eg: margin) for a given screen size."),t,n.label);return Object(u.createElement)(u.Fragment,null,Object(u.createElement)("span",{"aria-describedby":"rbc-desc-".concat(o)},n.label),Object(u.createElement)(h.VisuallyHidden,{as:"span",id:"rbc-desc-".concat(o)},c))}var Gb=function(e){var t=e.title,n=e.property,r=e.toggleLabel,o=e.onIsResponsiveChange,c=e.renderDefaultControl,i=e.renderResponsiveControls,a=e.isResponsive,l=void 0!==a&&a,s=e.defaultLabel,d=void 0===s?{id:"all",label:Object(g.__)("All")}:s,f=e.viewports,p=void 0===f?[{id:"small",label:Object(g.__)("Small screens")},{id:"medium",label:Object(g.__)("Medium screens")},{id:"large",label:Object(g.__)("Large screens")}]:f;if(!t||!n||!c)return null;var m=r||Object(g.sprintf)(Object(g.__)("Use the same %s on all screensizes."),n),v=Object(g.__)("Toggle between using the same value for all screen sizes or using a unique value per screen size."),O=c(Object(u.createElement)(Ub,{property:n,viewport:d}),d);return Object(u.createElement)("fieldset",{className:"block-editor-responsive-block-control"},Object(u.createElement)("legend",{className:"block-editor-responsive-block-control__title"},t),Object(u.createElement)("div",{className:"block-editor-responsive-block-control__inner"},Object(u.createElement)(h.ToggleControl,{className:"block-editor-responsive-block-control__toggle",label:m,checked:!l,onChange:o,help:v}),Object(u.createElement)("div",{className:b()("block-editor-responsive-block-control__group",{"is-responsive":l})},!l&&O,l&&(i?i(p):p.map((function(e){return Object(u.createElement)(u.Fragment,{key:e.id},c(Object(u.createElement)(Ub,{property:n,viewport:e}),e))}))))))};function Kb(e){var t=e.character,n=e.type,r=e.onUse;return Object(p.useKeyboardShortcut)(st.rawShortcut[n](t),(function(){return r(),!1}),{bindGlobal:!0}),null}function Wb(e){var t,n=e.name,r=e.shortcutType,o=e.shortcutCharacter,c=Object(he.a)(e,["name","shortcutType","shortcutCharacter"]),i="RichText.ToolbarControls";return n&&(i+=".".concat(n)),r&&o&&(t=st.displayShortcut[r](o)),Object(u.createElement)(h.Fill,{name:i},Object(u.createElement)(h.ToolbarButton,Object(l.a)({},c,{shortcut:t})))}function qb(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}var $b=function(e){Object(Wt.a)(n,e);var t=qb(n);function n(){var e;return Object(Ut.a)(this,n),(e=t.apply(this,arguments)).onInput=e.onInput.bind(Object(Kt.a)(e)),e}return Object(Gt.a)(n,[{key:"onInput",value:function(e){e.inputType===this.props.inputType&&this.props.onInput()}},{key:"componentDidMount",value:function(){document.addEventListener("input",this.onInput,!0)}},{key:"componentWillUnmount",value:function(){document.removeEventListener("input",this.onInput,!0)}},{key:"render",value:function(){return null}}]),n}(u.Component),Yb=Object(u.createElement)(h.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},Object(u.createElement)(h.Path,{d:"M9.4 20.5L5.2 3.8l14.6 9-2 .3c-.2 0-.4.1-.7.1-.9.2-1.6.3-2.2.5-.8.3-1.4.5-1.8.8-.4.3-.8.8-1.3 1.5-.4.5-.8 1.2-1.2 2l-.3.6-.9 1.9zM7.6 7.1l2.4 9.3c.2-.4.5-.8.7-1.1.6-.8 1.1-1.4 1.6-1.8.5-.4 1.3-.8 2.2-1.1l1.2-.3-8.1-5z"}));var Xb=Object(u.forwardRef)((function(e,t){var n=Object(v.useSelect)((function(e){return e("core/block-editor").isNavigationMode()}),[]),r=Object(v.useDispatch)("core/block-editor").setNavigationMode,o=function(e){r("edit"!==e)};return Object(u.createElement)(h.Dropdown,{renderToggle:function(r){var o=r.isOpen,c=r.onToggle;return Object(u.createElement)(h.Button,Object(l.a)({},e,{ref:t,icon:n?Yb:Db.a,"aria-expanded":o,"aria-haspopup":"true",onClick:c,label:Object(g.__)("Modes")}))},position:"bottom right",renderContent:function(){return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.NavigableMenu,{role:"menu","aria-label":Object(g.__)("Modes")},Object(u.createElement)(h.MenuItemsChoice,{value:n?"select":"edit",onSelect:o,choices:[{value:"edit",label:Object(u.createElement)(u.Fragment,null,Object(u.createElement)(so.a,{icon:Db.a}),Object(g.__)("Edit"))},{value:"select",label:Object(u.createElement)(u.Fragment,null,Yb,Object(g.__)("Select"))}]})),Object(u.createElement)("div",{className:"block-editor-tool-selector__help"},Object(g.__)("Tools offer different interactions for block selection & editing. To select, press Escape, to go back to editing, press Enter.")))}})})),Qb=n(186),Zb=Object(u.createElement)(j.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(u.createElement)(j.Path,{d:"M9.737 18.011L3.98 12.255l5.734-6.28 1.107 1.012-4.103 4.494h13.3v1.5H6.828l3.97 3.97-1.06 1.06z"}));function Jb(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}var ef=function(e){Object(Wt.a)(n,e);var t=Jb(n);function n(){var e;return Object(Ut.a)(this,n),(e=t.apply(this,arguments)).toggle=e.toggle.bind(Object(Kt.a)(e)),e.submitLink=e.submitLink.bind(Object(Kt.a)(e)),e.state={expanded:!1},e}return Object(Gt.a)(n,[{key:"toggle",value:function(){this.setState({expanded:!this.state.expanded})}},{key:"submitLink",value:function(e){e.preventDefault(),this.toggle()}},{key:"render",value:function(){var e=this.props,t=e.url,n=e.onChange,r=this.state.expanded,o=t?Object(g.__)("Edit link"):Object(g.__)("Insert link");return Object(u.createElement)("div",{className:"block-editor-url-input__button"},Object(u.createElement)(h.Button,{icon:Qb.a,label:o,onClick:this.toggle,className:"components-toolbar__control",isPressed:!!t}),r&&Object(u.createElement)("form",{className:"block-editor-url-input__button-modal",onSubmit:this.submitLink},Object(u.createElement)("div",{className:"block-editor-url-input__button-modal-line"},Object(u.createElement)(h.Button,{className:"block-editor-url-input__back",icon:Zb,label:Object(g.__)("Close"),onClick:this.toggle}),Object(u.createElement)(cb,{value:t||"",onChange:n}),Object(u.createElement)(h.Button,{icon:Yd.a,label:Object(g.__)("Submit"),type:"submit"}))))}}]),n}(u.Component),tf=n(160),nf=["noreferrer","noopener"],rf=Object(u.createElement)(h.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(u.createElement)(h.Path,{d:"M0,0h24v24H0V0z",fill:"none"}),Object(u.createElement)(h.Path,{d:"m19 5v14h-14v-14h14m0-2h-14c-1.1 0-2 0.9-2 2v14c0 1.1 0.9 2 2 2h14c1.1 0 2-0.9 2-2v-14c0-1.1-0.9-2-2-2z"}),Object(u.createElement)(h.Path,{d:"m14.14 11.86l-3 3.87-2.14-2.59-3 3.86h12l-3.86-5.14z"})),of=function(e){var t=e.linkDestination,n=e.onChangeUrl,r=e.url,o=e.mediaType,c=void 0===o?"image":o,i=e.mediaUrl,a=e.mediaLink,l=e.linkTarget,s=e.linkClass,d=e.rel,b=Object(u.useState)(!1),p=Object(re.a)(b,2),m=p[0],v=p[1],O=Object(u.useCallback)((function(){v(!0)})),j=Object(u.useState)(!1),k=Object(re.a)(j,2),y=k[0],_=k[1],E=Object(u.useState)(null),C=Object(re.a)(E,2),S=C[0],w=C[1],I=Object(u.useRef)(null),B=function(e){e.stopPropagation()},x=function(e){[st.LEFT,st.DOWN,st.RIGHT,st.UP,st.BACKSPACE,st.ENTER].indexOf(e.keyCode)>-1&&e.stopPropagation()},P=Object(u.useCallback)((function(){"media"!==t&&"attachment"!==t||w(""),_(!0)})),T=Object(u.useCallback)((function(){_(!1)})),N=Object(u.useCallback)((function(){w(null),T(),v(!1)})),D=function(e){var t=e;return void 0===e||Object(f.isEmpty)(t)||Object(f.isEmpty)(t)||(Object(f.each)(nf,(function(e){var n=new RegExp("\\b"+e+"\\b","gi");t=t.replace(n,"")})),t!==e&&(t=t.trim()),Object(f.isEmpty)(t)&&(t=void 0)),t},R=Object(u.useCallback)((function(){return function(e){var t=I.current;t&&t.contains(e.target)||(v(!1),w(null),T())}})),A=Object(u.useCallback)((function(){return function(e){S&&n({href:S}),T(),w(null),e.preventDefault()}})),M=Object(u.useCallback)((function(){n({linkDestination:"none",href:""})})),L=function(){var e=[{linkDestination:"media",title:Object(g.__)("Media File"),url:"image"===c?i:void 0,icon:rf}];return"image"===c&&a&&e.push({linkDestination:"attachment",title:Object(g.__)("Attachment Page"),url:"image"===c?a:void 0,icon:Object(u.createElement)(h.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(u.createElement)(h.Path,{d:"M0 0h24v24H0V0z",fill:"none"}),Object(u.createElement)(h.Path,{d:"M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zM6 20V4h7v5h5v11H6z"}))}),e},F=Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.ToggleControl,{label:Object(g.__)("Open in new tab"),onChange:function(e){var t=function(e){var t=e?"_blank":void 0;return{linkTarget:t,rel:t||d?D(d):void 0}}(e);n(t)},checked:"_blank"===l}),Object(u.createElement)(h.TextControl,{label:Object(g.__)("Link Rel"),value:D(d)||"",onChange:function(e){n({rel:e})},onKeyPress:B,onKeyDown:x}),Object(u.createElement)(h.TextControl,{label:Object(g.__)("Link CSS Class"),value:s||"",onKeyPress:B,onKeyDown:x,onChange:function(e){n({linkClass:e})}})),V=null!==S?S:r,H=(Object(f.find)(L(),["linkDestination",t])||{}).title;return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.ToolbarButton,{icon:Qb.a,className:"components-toolbar__control",label:r?Object(g.__)("Edit link"):Object(g.__)("Insert link"),"aria-expanded":m,onClick:O}),m&&Object(u.createElement)(Mb,{onFocusOutside:R(),onClose:N,renderSettings:function(){return F},additionalControls:!V&&Object(u.createElement)(h.NavigableMenu,null,Object(f.map)(L(),(function(e){return Object(u.createElement)(h.MenuItem,{key:e.linkDestination,icon:e.icon,onClick:function(){var t,r,o;w(null),t=e.url,o=L(),r=t?(Object(f.find)(o,(function(e){return e.url===t}))||{linkDestination:"custom"}).linkDestination:"none",n({linkDestination:r,href:t}),T()}},e.title)})))},(!r||y)&&Object(u.createElement)(Mb.LinkEditor,{className:"block-editor-format-toolbar__link-container-content",value:V,onChangeInputValue:w,onKeyDown:x,onKeyPress:B,onSubmit:A(),autocompleteRef:I}),r&&!y&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(Mb.LinkViewer,{className:"block-editor-format-toolbar__link-container-content",onKeyPress:B,url:r,onEditLinkClick:P,urlLabel:H}),Object(u.createElement)(h.Button,{icon:tf.a,label:Object(g.__)("Remove link"),onClick:M}))))},cf=n(161);function af(e){var t=e.children,n=e.className,r=e.isEnabled,o=void 0===r||r,c=e.deviceType,i=e.setDeviceType;if(Object(p.useViewportMatch)("small","<"))return null;var a={className:b()(n,"block-editor-post-preview__dropdown-content"),position:"bottom left"},l={isTertiary:!0,className:"block-editor-post-preview__button-toggle",disabled:!o,children:Object(g.__)("Preview")};return Object(u.createElement)(h.DropdownMenu,{className:"block-editor-post-preview__dropdown",popoverProps:a,toggleProps:l,icon:null},(function(){return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.MenuGroup,null,Object(u.createElement)(h.MenuItem,{className:"block-editor-post-preview__button-resize",onClick:function(){return i("Desktop")},icon:"Desktop"===c&&cf.a},Object(g.__)("Desktop")),Object(u.createElement)(h.MenuItem,{className:"block-editor-post-preview__button-resize",onClick:function(){return i("Tablet")},icon:"Tablet"===c&&cf.a},Object(g.__)("Tablet")),Object(u.createElement)(h.MenuItem,{className:"block-editor-post-preview__button-resize",onClick:function(){return i("Mobile")},icon:"Mobile"===c&&cf.a},Object(g.__)("Mobile"))),t)}))}var lf=n(280),sf=/\((min|max)-width:[^\(]*?\)/g;function uf(e){return!!e.media&&!!e.media.mediaText.match(sf)}function df(e,t,n){e.deleteRule(n),e.insertRule(t,n)}function bf(e,t){return e.replace(sf,(function(e){return Object(lf.match)(e,{type:"screen",width:t})?"(min-width:0px)":"(min-width:999999px)"}))}function ff(e,t){Object(u.useEffect)((function(){if(t){var n,r,o,c="undefined"==typeof window?[]:Object(f.filter)(null!==(n=null===(r=window)||void 0===r||null===(o=r.document)||void 0===o?void 0:o.styleSheets)&&void 0!==n?n:[],(function(e){return!!e.href&&Object(zl.getProtocol)(e.href)===window.location.protocol&&Object(zl.getAuthority)(e.href)===window.location.host})),i=[];return c.forEach((function(n,r){for(var o=!1,c=0;c<n.cssRules.length;++c){var a=n.cssRules[c];if((a.type===window.CSSRule.STYLE_RULE||a.type===window.CSSRule.MEDIA_RULE)&&(!o&&a.cssText.match(new RegExp("#start-".concat(e)))&&(o=!0),o&&a.cssText.match(new RegExp("#end-".concat(e)))&&(o=!1),o&&uf(a))){var l=a.cssText;i[r]||(i[r]=[]),i[r][c]=l,df(n,bf(l,t),c)}}})),function(){i.forEach((function(e,t){if(e)for(var n=0;n<e.length;++n){var r=e[n];r&&df(c[t],r,n)}}))}}}),[t])}function pf(e){var t=Object(u.useState)(window.innerWidth),n=Object(re.a)(t,2),r=n[0],o=n[1];Object(u.useEffect)((function(){if("Desktop"!==e){var t=function(){return o(window.innerWidth)};return window.addEventListener("resize",t),function(){window.removeEventListener("resize",t)}}}),[e]);var c=function(e){var t;switch(e){case"Tablet":t=780;break;case"Mobile":t=360;break;default:return null}return t<r?t:r};return ff("resizable-editor-section",c(e)),function(e){var t="Mobile"===e?"768px":"1024px";switch(e){case"Tablet":case"Mobile":return{width:c(e),margin:(window.innerHeight<800?36:72)+"px auto",flexGrow:0,height:t,minHeight:t,maxHeight:t,overflowY:"auto"};default:return null}}(e)}var mf=Object(v.withSelect)((function(e){return{selectedBlockClientId:e("core/block-editor").getBlockSelectionStart()}}))((function(e){var t=e.selectedBlockClientId;return t&&Object(u.createElement)(h.Button,{isSecondary:!0,className:"block-editor-skip-to-selected-block",onClick:function(){qe(t).focus()}},Object(g.__)("Skip to the selected block"))})),vf=n(128);var Of=Object(v.withSelect)((function(e){return{blocks:(0,e("core/block-editor").getMultiSelectedBlocks)()}}))((function(e){var t=e.blocks,n=Object(vf.count)(Object(c.serialize)(t),"words");return Object(u.createElement)("div",{className:"block-editor-multi-selection-inspector__card"},Object(u.createElement)(qn,{icon:ys,showColors:!0}),Object(u.createElement)("div",{className:"block-editor-multi-selection-inspector__card-content"},Object(u.createElement)("div",{className:"block-editor-multi-selection-inspector__card-title"},Object(g.sprintf)(Object(g._n)("%d block","%d blocks",t.length),t.length)),Object(u.createElement)("div",{className:"block-editor-multi-selection-inspector__card-description"},Object(g.sprintf)(Object(g._n)("%d word","%d words",n),n))))}));function gf(e){var t=e.blockName,n=Object(v.useSelect)((function(e){var n,r,o=e("core/block-editor").getSettings().__experimentalPreferredStyleVariations;return{preferredStyle:null==o||null===(n=o.value)||void 0===n?void 0:n[t],onUpdatePreferredStyleVariations:null!==(r=null==o?void 0:o.onChange)&&void 0!==r?r:null,styles:e("core/blocks").getBlockStyles(t)}}),[t]),r=n.preferredStyle,o=n.onUpdatePreferredStyleVariations,c=n.styles,i=Object(u.useMemo)((function(){return[{label:Object(g.__)("Not set"),value:""}].concat(Object(ne.a)(c.map((function(e){return{label:e.label,value:e.name}}))))}),[c]),a=Object(u.useCallback)((function(e){o(t,e)}),[t,o]);return o&&Object(u.createElement)(h.SelectControl,{options:i,value:r||"",label:Object(g.__)("Default Style"),onChange:a})}var hf=function(e){var t=e.slotName,n=e.bubblesVirtually,r=Object(h.__experimentalUseSlot)(t);return Boolean(r.fills&&r.fills.length)?Object(u.createElement)(h.PanelBody,{className:"block-editor-block-inspector__advanced",title:Object(g.__)("Advanced"),initialOpen:!1},Object(u.createElement)(q.Slot,{bubblesVirtually:n})):null},jf=Object(v.withSelect)((function(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientId,r=t.getSelectedBlockCount,o=t.getBlockName,i=e("core/blocks").getBlockStyles,a=n(),l=a&&o(a),s=a&&Object(c.getBlockType)(l),u=a&&i(l);return{count:r(),hasBlockStyles:u&&u.length>0,selectedBlockName:l,selectedBlockClientId:a,blockType:s}}))((function(e){var t=e.blockType,n=e.count,r=e.hasBlockStyles,o=e.selectedBlockClientId,i=e.selectedBlockName,a=e.showNoBlockSelectedMessage,l=void 0===a||a,s=e.bubblesVirtually,d=void 0===s||s;if(n>1)return Object(u.createElement)("div",{className:"block-editor-block-inspector"},Object(u.createElement)(Of,null),Object(u.createElement)(We.Slot,{bubblesVirtually:d}));var b=i===Object(c.getUnregisteredTypeHandlerName)();return t&&o&&!b?Object(u.createElement)("div",{className:"block-editor-block-inspector"},Object(u.createElement)(fo,{blockType:t}),r&&Object(u.createElement)("div",null,Object(u.createElement)(h.PanelBody,{title:Object(g.__)("Styles")},Object(u.createElement)(Is,{clientId:o}),Object(c.hasBlockSupport)(t.name,"defaultStylePicker",!0)&&Object(u.createElement)(gf,{blockName:t.name}))),Object(u.createElement)(We.Slot,{bubblesVirtually:d}),Object(u.createElement)("div",null,Object(u.createElement)(hf,{slotName:q.slotName,bubblesVirtually:d})),Object(u.createElement)(mf,{key:"back"})):l?Object(u.createElement)("span",{className:"block-editor-block-inspector__no-blocks"},Object(g.__)("No block selected.")):null}));function kf(e){var t,n,r=(t=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.hasSelectedBlock,r=t.hasMultiSelection;return n()||r()})),n=Object(v.useDispatch)("core/block-editor").clearSelectedBlock,function(e){e.target===e.currentTarget&&t&&n()});return Object(u.createElement)("div",Object(l.a)({tabIndex:-1,onFocus:r},e))}var yf=n(281),_f=n.n(yf),Ef=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,Cf=function(e,t){t=t||{};var n=1,r=1;function o(e){var t=e.match(/\n/g);t&&(n+=t.length);var o=e.lastIndexOf("\n");r=~o?e.length-o:r+e.length}function c(){var e={line:n,column:r};return function(t){return t.position=new i(e),f(),t}}function i(e){this.start=e,this.end={line:n,column:r},this.source=t.source}i.prototype.content=e;var a=[];function l(o){var c=new Error(t.source+":"+n+":"+r+": "+o);if(c.reason=o,c.filename=t.source,c.line=n,c.column=r,c.source=e,!t.silent)throw c;a.push(c)}function s(){return b(/^{\s*/)}function u(){return b(/^}/)}function d(){var t,n=[];for(f(),p(n);e.length&&"}"!==e.charAt(0)&&(t=C()||S());)!1!==t&&(n.push(t),p(n));return n}function b(t){var n=t.exec(e);if(n){var r=n[0];return o(r),e=e.slice(r.length),n}}function f(){b(/^\s*/)}function p(e){var t;for(e=e||[];t=m();)!1!==t&&e.push(t);return e}function m(){var t=c();if("/"===e.charAt(0)&&"*"===e.charAt(1)){for(var n=2;""!==e.charAt(n)&&("*"!==e.charAt(n)||"/"!==e.charAt(n+1));)++n;if(n+=2,""===e.charAt(n-1))return l("End of comment missing");var i=e.slice(2,n-2);return r+=2,o(i),e=e.slice(n),r+=2,t({type:"comment",comment:i})}}function v(){var e=b(/^([^{]+)/);if(e)return Sf(e[0]).replace(/\/\*([^*]|[\r\n]|(\*+([^*/]|[\r\n])))*\*\/+/g,"").replace(/"(?:\\"|[^"])*"|'(?:\\'|[^'])*'/g,(function(e){return e.replace(/,/g,"")})).split(/\s*(?![^(]*\)),\s*/).map((function(e){return e.replace(/\u200C/g,",")}))}function O(){var e=c(),t=b(/^(\*?[-#\/\*\\\w]+(\[[0-9a-z_-]+\])?)\s*/);if(t){if(t=Sf(t[0]),!b(/^:\s*/))return l("property missing ':'");var n=b(/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^\)]*?\)|[^};])+)/),r=e({type:"declaration",property:t.replace(Ef,""),value:n?Sf(n[0]).replace(Ef,""):""});return b(/^[;\s]*/),r}}function g(){var e,t=[];if(!s())return l("missing '{'");for(p(t);e=O();)!1!==e&&(t.push(e),p(t));return u()?t:l("missing '}'")}function h(){for(var e,t=[],n=c();e=b(/^((\d+\.\d+|\.\d+|\d+)%?|[a-z]+)\s*/);)t.push(e[1]),b(/^,\s*/);if(t.length)return n({type:"keyframe",values:t,declarations:g()})}var j,k=E("import"),y=E("charset"),_=E("namespace");function E(e){var t=new RegExp("^@"+e+"\\s*([^;]+);");return function(){var n=c(),r=b(t);if(r){var o={type:e};return o[e]=r[1].trim(),n(o)}}}function C(){if("@"===e[0])return function(){var e=c(),t=b(/^@([-\w]+)?keyframes\s*/);if(t){var n=t[1];if(!(t=b(/^([-\w]+)\s*/)))return l("@keyframes missing name");var r,o=t[1];if(!s())return l("@keyframes missing '{'");for(var i=p();r=h();)i.push(r),i=i.concat(p());return u()?e({type:"keyframes",name:o,vendor:n,keyframes:i}):l("@keyframes missing '}'")}}()||function(){var e=c(),t=b(/^@media *([^{]+)/);if(t){var n=Sf(t[1]);if(!s())return l("@media missing '{'");var r=p().concat(d());return u()?e({type:"media",media:n,rules:r}):l("@media missing '}'")}}()||function(){var e=c(),t=b(/^@custom-media\s+(--[^\s]+)\s*([^{;]+);/);if(t)return e({type:"custom-media",name:Sf(t[1]),media:Sf(t[2])})}()||function(){var e=c(),t=b(/^@supports *([^{]+)/);if(t){var n=Sf(t[1]);if(!s())return l("@supports missing '{'");var r=p().concat(d());return u()?e({type:"supports",supports:n,rules:r}):l("@supports missing '}'")}}()||k()||y()||_()||function(){var e=c(),t=b(/^@([-\w]+)?document *([^{]+)/);if(t){var n=Sf(t[1]),r=Sf(t[2]);if(!s())return l("@document missing '{'");var o=p().concat(d());return u()?e({type:"document",document:r,vendor:n,rules:o}):l("@document missing '}'")}}()||function(){var e=c();if(b(/^@page */)){var t=v()||[];if(!s())return l("@page missing '{'");for(var n,r=p();n=O();)r.push(n),r=r.concat(p());return u()?e({type:"page",selectors:t,declarations:r}):l("@page missing '}'")}}()||function(){var e=c();if(b(/^@host\s*/)){if(!s())return l("@host missing '{'");var t=p().concat(d());return u()?e({type:"host",rules:t}):l("@host missing '}'")}}()||function(){var e=c();if(b(/^@font-face\s*/)){if(!s())return l("@font-face missing '{'");for(var t,n=p();t=O();)n.push(t),n=n.concat(p());return u()?e({type:"font-face",declarations:n}):l("@font-face missing '}'")}}()}function S(){var e=c(),t=v();return t?(p(),e({type:"rule",selectors:t,declarations:g()})):l("selector missing")}return function e(t,n){var r=t&&"string"==typeof t.type,o=r?t:n;for(var c in t){var i=t[c];Array.isArray(i)?i.forEach((function(t){e(t,o)})):i&&"object"===Object(Ao.a)(i)&&e(i,o)}r&&Object.defineProperty(t,"parent",{configurable:!0,writable:!0,enumerable:!1,value:n||null});return t}((j=d(),{type:"stylesheet",stylesheet:{source:t.source,rules:j,parsingErrors:a}}))};function Sf(e){return e?e.replace(/^\s+|\s+$/g,""):""}var wf=n(171),If=n.n(wf),Bf=xf;function xf(e){this.options=e||{}}xf.prototype.emit=function(e){return e},xf.prototype.visit=function(e){return this[e.type](e)},xf.prototype.mapVisit=function(e,t){var n="";t=t||"";for(var r=0,o=e.length;r<o;r++)n+=this.visit(e[r]),t&&r<o-1&&(n+=this.emit(t));return n};var Pf=Tf;function Tf(e){Bf.call(this,e)}If()(Tf,Bf),Tf.prototype.compile=function(e){return e.stylesheet.rules.map(this.visit,this).join("")},Tf.prototype.comment=function(e){return this.emit("",e.position)},Tf.prototype.import=function(e){return this.emit("@import "+e.import+";",e.position)},Tf.prototype.media=function(e){return this.emit("@media "+e.media,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Tf.prototype.document=function(e){var t="@"+(e.vendor||"")+"document "+e.document;return this.emit(t,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Tf.prototype.charset=function(e){return this.emit("@charset "+e.charset+";",e.position)},Tf.prototype.namespace=function(e){return this.emit("@namespace "+e.namespace+";",e.position)},Tf.prototype.supports=function(e){return this.emit("@supports "+e.supports,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Tf.prototype.keyframes=function(e){return this.emit("@"+(e.vendor||"")+"keyframes "+e.name,e.position)+this.emit("{")+this.mapVisit(e.keyframes)+this.emit("}")},Tf.prototype.keyframe=function(e){var t=e.declarations;return this.emit(e.values.join(","),e.position)+this.emit("{")+this.mapVisit(t)+this.emit("}")},Tf.prototype.page=function(e){var t=e.selectors.length?e.selectors.join(", "):"";return this.emit("@page "+t,e.position)+this.emit("{")+this.mapVisit(e.declarations)+this.emit("}")},Tf.prototype["font-face"]=function(e){return this.emit("@font-face",e.position)+this.emit("{")+this.mapVisit(e.declarations)+this.emit("}")},Tf.prototype.host=function(e){return this.emit("@host",e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Tf.prototype["custom-media"]=function(e){return this.emit("@custom-media "+e.name+" "+e.media+";",e.position)},Tf.prototype.rule=function(e){var t=e.declarations;return t.length?this.emit(e.selectors.join(","),e.position)+this.emit("{")+this.mapVisit(t)+this.emit("}"):""},Tf.prototype.declaration=function(e){return this.emit(e.property+":"+e.value,e.position)+this.emit(";")};var Nf=Df;function Df(e){e=e||{},Bf.call(this,e),this.indentation=e.indent}If()(Df,Bf),Df.prototype.compile=function(e){return this.stylesheet(e)},Df.prototype.stylesheet=function(e){return this.mapVisit(e.stylesheet.rules,"\n\n")},Df.prototype.comment=function(e){return this.emit(this.indent()+"/*"+e.comment+"*/",e.position)},Df.prototype.import=function(e){return this.emit("@import "+e.import+";",e.position)},Df.prototype.media=function(e){return this.emit("@media "+e.media,e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.rules,"\n\n")+this.emit(this.indent(-1)+"\n}")},Df.prototype.document=function(e){var t="@"+(e.vendor||"")+"document "+e.document;return this.emit(t,e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.rules,"\n\n")+this.emit(this.indent(-1)+"\n}")},Df.prototype.charset=function(e){return this.emit("@charset "+e.charset+";",e.position)},Df.prototype.namespace=function(e){return this.emit("@namespace "+e.namespace+";",e.position)},Df.prototype.supports=function(e){return this.emit("@supports "+e.supports,e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.rules,"\n\n")+this.emit(this.indent(-1)+"\n}")},Df.prototype.keyframes=function(e){return this.emit("@"+(e.vendor||"")+"keyframes "+e.name,e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.keyframes,"\n")+this.emit(this.indent(-1)+"}")},Df.prototype.keyframe=function(e){var t=e.declarations;return this.emit(this.indent())+this.emit(e.values.join(", "),e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(t,"\n")+this.emit(this.indent(-1)+"\n"+this.indent()+"}\n")},Df.prototype.page=function(e){var t=e.selectors.length?e.selectors.join(", ")+" ":"";return this.emit("@page "+t,e.position)+this.emit("{\n")+this.emit(this.indent(1))+this.mapVisit(e.declarations,"\n")+this.emit(this.indent(-1))+this.emit("\n}")},Df.prototype["font-face"]=function(e){return this.emit("@font-face ",e.position)+this.emit("{\n")+this.emit(this.indent(1))+this.mapVisit(e.declarations,"\n")+this.emit(this.indent(-1))+this.emit("\n}")},Df.prototype.host=function(e){return this.emit("@host",e.position)+this.emit(" {\n"+this.indent(1))+this.mapVisit(e.rules,"\n\n")+this.emit(this.indent(-1)+"\n}")},Df.prototype["custom-media"]=function(e){return this.emit("@custom-media "+e.name+" "+e.media+";",e.position)},Df.prototype.rule=function(e){var t=this.indent(),n=e.declarations;return n.length?this.emit(e.selectors.map((function(e){return t+e})).join(",\n"),e.position)+this.emit(" {\n")+this.emit(this.indent(1))+this.mapVisit(n,"\n")+this.emit(this.indent(-1))+this.emit("\n"+this.indent()+"}"):""},Df.prototype.declaration=function(e){return this.emit(this.indent())+this.emit(e.property+": "+e.value,e.position)+this.emit(";")},Df.prototype.indent=function(e){return this.level=this.level||1,null!==e?(this.level+=e,""):Array(this.level).join(this.indentation||" ")};var Rf=function(e,t){try{var n=Cf(e),r=_f.a.map(n,(function(e){if(!e)return e;var n=t(e);return this.update(n)}));return o=r,((c=c||{}).compress?new Pf(c):new Nf(c)).compile(o)}catch(e){return console.warn("Error while traversing the CSS: "+e),null}var o,c};function Af(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Mf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Af(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Af(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Lf(e){return 0!==e.value.indexOf("data:")&&0!==e.value.indexOf("#")&&(t=e.value,!/^\/(?!\/)/.test(t)&&!function(e){return/^(?:https?:)?\/\//.test(e)}(e.value));var t}function Ff(e,t){return new URL(e,t).toString()}var Vf=function(e){return function(t){if("declaration"===t.type){var n=function(e){for(var t,n=/url\((\s*)(['"]?)(.+?)\2(\s*)\)/g,r=[];null!==(t=n.exec(e));){var o={source:t[0],before:t[1],quote:t[2],value:t[3],after:t[4]};Lf(o)&&r.push(o)}return r}(t.value).map((c=e,function(e){return Mf(Mf({},e),{},{newUrl:"url("+e.before+e.quote+Ff(e.value,c)+e.quote+e.after+")"})}));return Mf(Mf({},t),{},{value:(r=t.value,o=n,o.forEach((function(e){r=r.replace(e.source,e.newUrl)})),r)})}var r,o,c;return t}};function Hf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function zf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Hf(Object(n),!0).forEach((function(t){Object(s.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Hf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Uf=/^(body|html|:root).*$/,Gf=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return function(n){return"rule"===n.type?zf(zf({},n),{},{selectors:n.selectors.map((function(n){return t.includes(n.trim())?n:n.match(Uf)?n.replace(/^(body|html|:root)/,e):e+" "+n}))}):n}},Kf=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Object(f.map)(e,(function(e){var n=e.css,r=e.baseURL,o=[];return t&&o.push(Gf(t)),r&&o.push(Vf(r)),o.length?Rf(n,Object(p.compose)(o)):n}))};var Wf=function(e){var t=e.styles;return Object(u.useEffect)((function(){var e=Kf(t,".editor-styles-wrapper"),n=Object(f.map)(Object(f.compact)(e),(function(e){var t=document.createElement("style");return t.innerHTML=e,document.body.appendChild(t),t}));return function(){return n.forEach((function(e){return document.body.removeChild(e)}))}}),[t]),null};var qf=function(e){var t=e.rootClientId,n=e.clientId,r=e.isAppender,o=e.showInserterHelpPanel,c=e.showMostUsedBlocks,i=void 0!==c&&c,a=e.__experimentalSelectBlockOnInsert,l=e.__experimentalInsertionIndex,s=e.onSelect,d=void 0===s?f.noop:s,b=Object(v.useSelect)((function(e){var r=e("core/block-editor").getBlockRootClientId;return t||r(n)||void 0}),[n,t]);return Object(u.createElement)(Ql,{onSelect:d,rootClientId:b,clientId:n,isAppender:r,showInserterHelpPanel:o,showMostUsedBlocks:i,__experimentalSelectBlockOnInsert:a,__experimentalInsertionIndex:l})};function $f(){var e=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientIds,r=t.getBlockOrder,o=t.getBlockRootClientId,c=n(),i=Object(re.a)(c,1)[0];return{clientIds:c,rootBlocksClientIds:r(),rootClientId:o(i)}}),[]),t=e.clientIds,n=e.rootBlocksClientIds,r=e.rootClientId,o=Object(v.useDispatch)("core/block-editor"),c=o.duplicateBlocks,i=o.removeBlocks,l=o.insertAfterBlock,s=o.insertBeforeBlock,d=o.multiSelect,b=o.clearSelectedBlock,p=o.moveBlocksUp,m=o.moveBlocksDown;return Object(a.useShortcut)("core/block-editor/move-up",Object(u.useCallback)((function(e){e.preventDefault(),p(t,r)}),[t,p]),{bindGlobal:!0,isDisabled:0===t.length}),Object(a.useShortcut)("core/block-editor/move-down",Object(u.useCallback)((function(e){e.preventDefault(),m(t,r)}),[t,m]),{bindGlobal:!0,isDisabled:0===t.length}),Object(a.useShortcut)("core/block-editor/duplicate",Object(u.useCallback)((function(e){e.preventDefault(),c(t)}),[t,c]),{bindGlobal:!0,isDisabled:0===t.length}),Object(a.useShortcut)("core/block-editor/remove",Object(u.useCallback)((function(e){e.preventDefault(),i(t)}),[t,i]),{bindGlobal:!0,isDisabled:0===t.length}),Object(a.useShortcut)("core/block-editor/insert-after",Object(u.useCallback)((function(e){e.preventDefault(),l(Object(f.last)(t))}),[t,l]),{bindGlobal:!0,isDisabled:0===t.length}),Object(a.useShortcut)("core/block-editor/insert-before",Object(u.useCallback)((function(e){e.preventDefault(),s(Object(f.first)(t))}),[t,s]),{bindGlobal:!0,isDisabled:0===t.length}),Object(a.useShortcut)("core/block-editor/delete-multi-selection",Object(u.useCallback)((function(e){e.preventDefault(),i(t)}),[t,i]),{isDisabled:t.length<2}),Object(a.useShortcut)("core/block-editor/select-all",Object(u.useCallback)((function(e){e.preventDefault(),d(Object(f.first)(n),Object(f.last)(n))}),[n,d])),Object(a.useShortcut)("core/block-editor/unselect",Object(u.useCallback)((function(e){e.preventDefault(),b(),e.target.ownerDocument.defaultView.getSelection().removeAllRanges()}),[t,b]),{isDisabled:t.length<2}),null}$f.Register=function(){var e=Object(v.useDispatch)("core/keyboard-shortcuts").registerShortcut;return Object(u.useEffect)((function(){e({name:"core/block-editor/duplicate",category:"block",description:Object(g.__)("Duplicate the selected block(s)."),keyCombination:{modifier:"primaryShift",character:"d"}}),e({name:"core/block-editor/remove",category:"block",description:Object(g.__)("Remove the selected block(s)."),keyCombination:{modifier:"access",character:"z"}}),e({name:"core/block-editor/insert-before",category:"block",description:Object(g.__)("Insert a new block before the selected block(s)."),keyCombination:{modifier:"primaryAlt",character:"t"}}),e({name:"core/block-editor/insert-after",category:"block",description:Object(g.__)("Insert a new block after the selected block(s)."),keyCombination:{modifier:"primaryAlt",character:"y"}}),e({name:"core/block-editor/delete-multi-selection",category:"block",description:Object(g.__)("Remove multiple selected blocks."),keyCombination:{character:"del"},aliases:[{character:"backspace"}]}),e({name:"core/block-editor/select-all",category:"selection",description:Object(g.__)("Select all text when typing. Press again to select all blocks."),keyCombination:{modifier:"primary",character:"a"}}),e({name:"core/block-editor/unselect",category:"selection",description:Object(g.__)("Clear selection."),keyCombination:{character:"escape"}}),e({name:"core/block-editor/focus-toolbar",category:"global",description:Object(g.__)("Navigate to the nearest toolbar."),keyCombination:{modifier:"alt",character:"F10"}}),e({name:"core/block-editor/move-up",category:"block",description:Object(g.__)("Move the selected block(s) up."),keyCombination:{modifier:"secondary",character:"t"}}),e({name:"core/block-editor/move-down",category:"block",description:Object(g.__)("Move the selected block(s) down."),keyCombination:{modifier:"secondary",character:"y"}})}),[e]),null};var Yf=$f;function Xf(){var e=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getBlockSelectionEnd,r=t.hasMultiSelection,o=t.isMultiSelecting;return{selectionEnd:n(),isMultiSelection:r(),isMultiSelecting:o()}}),[]),t=e.isMultiSelection,n=e.selectionEnd,r=e.isMultiSelecting;return Object(u.useEffect)((function(){if(n&&!r&&t){var e=qe(n);if(e){var o=Object(kr.getScrollContainer)(e);o&&tb()(e,o,{onlyScrollIfNeeded:!0})}}}),[t,n,r]),null}var Qf=[st.UP,st.RIGHT,st.DOWN,st.LEFT,st.ENTER,st.BACKSPACE];var Zf=Object(p.withSafeTimeout)((function(e){var t=e.children,n=e.setTimeout,r=Object(u.useRef)(),o=Object(u.useRef)(),c=Object(v.useSelect)((function(e){return e("core/block-editor").isTyping()})),i=Object(v.useDispatch)("core/block-editor"),a=i.startTyping,l=i.stopTyping;function s(e){var t=e?"addEventListener":"removeEventListener";r.current.ownerDocument[t]("selectionchange",b),r.current.ownerDocument[t]("mousemove",d),document[t]("mousemove",d)}function d(e){var t=e.clientX,n=e.clientY;if(o.current){var r=o.current,c=r.clientX,i=r.clientY;c===t&&i===n||l()}o.current={clientX:t,clientY:n}}function b(e){var t=e.target.defaultView.getSelection();t.rangeCount>0&&t.getRangeAt(0).collapsed||l()}function p(e){var t=e.type,n=e.target;!c&&Object(kr.isTextField)(n)&&r.current.contains(n)&&("keydown"!==t||function(e){var t=e.keyCode;return!e.shiftKey&&Qf.includes(t)}(e))&&a()}return Object(u.useEffect)((function(){return s(c),function(){return s(!1)}}),[c]),Object(u.createElement)("div",{ref:r,onFocus:function(e){var t=e.target;n((function(){c&&!Object(kr.isTextField)(t)&&l()}))},onKeyPress:p,onKeyDown:Object(f.over)([p,function(e){!c||e.keyCode!==st.ESCAPE&&e.keyCode!==st.TAB||l()}])},t)}));function Jf(){return to()("PreserveScrollInReorder component",{hint:"This behavior is now built-in the block list"}),null}function ep(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object($t.a)(e);if(t){var o=Object($t.a)(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Object(qt.a)(this,n)}}var tp=-1!==window.navigator.userAgent.indexOf("Trident"),np=new Set([st.UP,st.DOWN,st.LEFT,st.RIGHT]),rp=function(e){Object(Wt.a)(n,e);var t=ep(n);function n(){var e;return Object(Ut.a)(this,n),(e=t.apply(this,arguments)).ref=Object(u.createRef)(),e.onKeyDown=e.onKeyDown.bind(Object(Kt.a)(e)),e.addSelectionChangeListener=e.addSelectionChangeListener.bind(Object(Kt.a)(e)),e.computeCaretRectOnSelectionChange=e.computeCaretRectOnSelectionChange.bind(Object(Kt.a)(e)),e.maintainCaretPosition=e.maintainCaretPosition.bind(Object(Kt.a)(e)),e.computeCaretRect=e.computeCaretRect.bind(Object(Kt.a)(e)),e.onScrollResize=e.onScrollResize.bind(Object(Kt.a)(e)),e.isSelectionEligibleForScroll=e.isSelectionEligibleForScroll.bind(Object(Kt.a)(e)),e.getDocument=e.getDocument.bind(Object(Kt.a)(e)),e.getWindow=e.getWindow.bind(Object(Kt.a)(e)),e}return Object(Gt.a)(n,[{key:"componentDidMount",value:function(){this.getWindow().addEventListener("scroll",this.onScrollResize,!0),this.getWindow().addEventListener("resize",this.onScrollResize,!0)}},{key:"componentWillUnmount",value:function(){this.getWindow().removeEventListener("scroll",this.onScrollResize,!0),this.getWindow().removeEventListener("resize",this.onScrollResize,!0),this.getDocument().removeEventListener("selectionchange",this.computeCaretRectOnSelectionChange),this.onScrollResize.rafId&&this.getWindow().cancelAnimationFrame(this.onScrollResize.rafId),this.onKeyDown.rafId&&this.getWindow().cancelAnimationFrame(this.onKeyDown.rafId)}},{key:"getDocument",value:function(){return this.ref.current.ownerDocument}},{key:"getWindow",value:function(){return this.getDocument().defaultView}},{key:"computeCaretRect",value:function(){this.isSelectionEligibleForScroll()&&(this.caretRect=Object(kr.computeCaretRect)(this.getWindow()))}},{key:"computeCaretRectOnSelectionChange",value:function(){this.getDocument().removeEventListener("selectionchange",this.computeCaretRectOnSelectionChange),this.computeCaretRect()}},{key:"onScrollResize",value:function(){var e=this;this.onScrollResize.rafId||(this.onScrollResize.rafId=this.getWindow().requestAnimationFrame((function(){e.computeCaretRect(),delete e.onScrollResize.rafId})))}},{key:"isSelectionEligibleForScroll",value:function(){return this.props.selectedBlockClientId&&this.ref.current.contains(this.getDocument().activeElement)&&this.getDocument().activeElement.isContentEditable}},{key:"isLastEditableNode",value:function(){var e=this.ref.current.querySelectorAll('[contenteditable="true"]');return e[e.length-1]===this.getDocument().activeElement}},{key:"maintainCaretPosition",value:function(e){var t=e.keyCode;if(this.isSelectionEligibleForScroll()){var n=Object(kr.computeCaretRect)(this.getWindow());if(n)if(this.caretRect)if(np.has(t))this.caretRect=n;else{var r=n.top-this.caretRect.top;if(0!==r){var o=Object(kr.getScrollContainer)(this.ref.current);if(o){var c=o===this.getDocument().body,i=c?this.getWindow().scrollY:o.scrollTop,a=c?0:o.getBoundingClientRect().top,l=c?this.caretRect.top/this.getWindow().innerHeight:(this.caretRect.top-a)/(this.getWindow().innerHeight-a);if(0===i&&l<.75&&this.isLastEditableNode())this.caretRect=n;else{var s=c?this.getWindow().innerHeight:o.clientHeight;this.caretRect.top+this.caretRect.height>a+s||this.caretRect.top<a?this.caretRect=n:c?this.getWindow().scrollBy(0,r):o.scrollTop+=r}}}}else this.caretRect=n}}},{key:"addSelectionChangeListener",value:function(){this.getDocument().addEventListener("selectionchange",this.computeCaretRectOnSelectionChange)}},{key:"onKeyDown",value:function(e){var t=this;e.persist(),this.onKeyDown.rafId&&this.getWindow().cancelAnimationFrame(this.onKeyDown.rafId),this.onKeyDown.rafId=this.getWindow().requestAnimationFrame((function(){t.maintainCaretPosition(e),delete t.onKeyDown.rafId}))}},{key:"render",value:function(){return Object(u.createElement)("div",{ref:this.ref,onKeyDown:this.onKeyDown,onKeyUp:this.maintainCaretPosition,onMouseDown:this.addSelectionChangeListener,onTouchStart:this.addSelectionChangeListener,className:"block-editor__typewriter"},this.props.children)}}]),n}(u.Component),op=tp?function(e){return e.children}:Object(v.withSelect)((function(e){return{selectedBlockClientId:(0,e("core/block-editor").getSelectedBlockClientId)()}}))(rp);function cp(e){if(void 0===e)e=mo.colors;else{var t=e.filter((function(e){return e.color}));0===t.length?e=mo.colors:t.length<e.length&&(e=t)}return e}function ip(e){if(void 0===e)e=mo.gradients;else{var t=e.filter((function(e){return e.gradient}));0===t.length?e=mo.gradients:t.length<e.length&&(e=t)}return e}}]); |