Version Description
Download this release
Release Info
Developer | youknowriad |
Plugin | Gutenberg |
Version | 9.2.1 |
Comparing to | |
See all releases |
Code changes from version 9.2.0 to 9.2.1
build/block-editor/index.asset.php
CHANGED
@@ -1 +1 @@
|
|
1 |
-
<?php return array('dependencies' => array('lodash', 'react', 'react-dom', 'wp-a11y', 'wp-blob', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-data', 'wp-deprecated', 'wp-dom', 'wp-element', 'wp-hooks', 'wp-html-entities', 'wp-i18n', 'wp-is-shallow-equal', 'wp-keyboard-shortcuts', 'wp-keycodes', 'wp-notices', 'wp-polyfill', 'wp-primitives', 'wp-rich-text', 'wp-shortcode', 'wp-token-list', 'wp-url', 'wp-viewport', 'wp-warning', 'wp-wordcount'), 'version' => '
|
1 |
+
<?php return array('dependencies' => array('lodash', 'react', 'react-dom', 'wp-a11y', 'wp-blob', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-data', 'wp-deprecated', 'wp-dom', 'wp-element', 'wp-hooks', 'wp-html-entities', 'wp-i18n', 'wp-is-shallow-equal', 'wp-keyboard-shortcuts', 'wp-keycodes', 'wp-notices', 'wp-polyfill', 'wp-primitives', 'wp-rich-text', 'wp-shortcode', 'wp-token-list', 'wp-url', 'wp-viewport', 'wp-warning', 'wp-wordcount'), 'version' => '111d02e55937608149e0d53ccb3d5ab2');
|
build/block-editor/index.js
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
-
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=402)}([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){!function(){e.exports=this.wp.primitives}()},function(e,t,n){var r;!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))e.push(o.apply(null,r));else if("object"===c)for(var i in r)n.call(r,i)&&r[i]&&e.push(i)}}return e.join(" ")}e.exports?e.exports=o:void 0===(r=function(){return o}.apply(t,[]))||(e.exports=r)}()},function(e,t){!function(){e.exports=this.React}()},function(e,t){!function(){e.exports=this.wp.blocks}()},function(e,t){!function(){e.exports=this.wp.compose}()},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){!function(){e.exports=this.regeneratorRuntime}()},function(e,t){!function(){e.exports=this.wp.keycodes}()},,,,function(e,t){!function(){e.exports=this.wp.richText}()},function(e,t){!function(){e.exports=this.wp.url}()},,function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(169);var o=n(136),c=n(170);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,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){e.exports=n(139)()},function(e,t){!function(){e.exports=this.wp.dom}()},,,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,t){if(null==e)return{};var n,r,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,t);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}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";n.d(t,"a",(function(){return c}));var r=n(8),o=n(52);function c(e){var t=Object(r.useRef)(e);return Object(o.a)((function(){t.current=e})),t}},function(e,t){!function(){e.exports=this.wp.blob}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return l}));var r=n(8),o=n(57);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(38);var a=n(46);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={},f=n||{};for(var b in f)void 0!==f[b]&&(d[b]=f[b]);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(8),o=n(38),c=n(72);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(46);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,f=e.keys,b=void 0===f?(null==l?void 0:l.__keys)||[]:f,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,b),d=u[0],f=u[1],p=l(d,Object(o.a)({ref:t},f)),v=p.wrapElement,g=Object(o.b)(p,["wrapElement"]),O=(null===(s=c.render)||void 0===s?void 0:s.__keys)||c.__keys,h=O&&i(a,O)[0],j=h?Object(o.a)(Object(o.a)({},g),h):g,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=b,v.unstable_propsAreEqual=d||a.a,v}},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){return e?e.ownerDocument||e:window.document}n.d(t,"a",(function(){return r}))},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){!function(){e.exports=this.wp.a11y}()},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";n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return g})),n.d(t,"c",(function(){return p})),n.d(t,"d",(function(){return b})),n.d(t,"e",(function(){return h})),n.d(t,"f",(function(){return s})),n.d(t,"g",(function(){return S}));var r=n(11),o=n(8),c=n(52),i=n(54),a=n(55),l=n(58);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 f(e,t){return t?e.find((function(e){return!e.disabled&&e.id!==t})):e.find((function(e){return!e.disabled}))}function b(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 g(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 O(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=f(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,w=e.wrap,S=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=f(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 $=S.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=S.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=b(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=f(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,fe=ce&&w&&w!==ue,be=t.hasNullItem||!ce&&de&&null===T;if(de){var pe=f(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))}(fe&&!be?re:k(re,oe.groupId),u,be),u);return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==pe?void 0:pe.id}))}if(fe){var me=f(be?le:ae,u),ve=be?(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 ge=f(le,u);return C(e,!ge&&be?Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null}):Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==ge?void 0:ge.id}));case"previous":var Oe=!!!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:Oe}));return Object(r.b)(Object(r.b)({},he),{},{items:i});case"down":var je=v(g(O(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(g(O(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 we=f(i);return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==we?void 0:we.id}));case"last":var Se=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)({},Se),{},{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,w)});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 w(e){return Object(o.useCallback)(e,[])}function S(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,f=t.currentId,b=t.loop,p=void 0!==b&&b,m=t.wrap,v=void 0!==m&&m,g=Object(r.a)(t,["unstable_virtual","rtl","orientation","currentId","loop","wrap"]),O=Object(o.useReducer)(C,{unstable_virtual:a,rtl:u,orientation:d,items:[],groups:[],currentId:f,loop:p,wrap:v,unstable_moves:0,pastIds:[],initialVirtual:a,initialRTL:u,initialOrientation:d,initialCurrentId:f,initialLoop:p,initialWrap:v}),h=O[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=O[1],y=Object(o.useState)(!1),_=y[0],E=y[1],S=Object(l.a)(g),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)({},S),j),{},{unstable_hasActiveWidget:_,unstable_setHasActiveWidget:E,registerItem:w((function(e){I.current||k({type:"registerItem",item:e})})),unregisterItem:w((function(e){I.current||k({type:"unregisterItem",id:e})})),registerGroup:w((function(e){I.current||k({type:"registerGroup",group:e})})),unregisterGroup:w((function(e){I.current||k({type:"unregisterGroup",id:e})})),move:w((function(e){return k({type:"move",id:e})})),next:w((function(e){return k({type:"next",allTheWay:e})})),previous:w((function(e){return k({type:"previous",allTheWay:e})})),up:w((function(e){return k({type:"up",allTheWay:e})})),down:w((function(e){return k({type:"down",allTheWay:e})})),first:w((function(){return k({type:"first"})})),last:w((function(){return k({type:"last"})})),unstable_sort:w((function(){return k({type:"sort"})})),unstable_setVirtual:w((function(e){return k({type:"setVirtual",virtual:e})})),setRTL:w((function(e){return k({type:"setRTL",rtl:e})})),setOrientation:w((function(e){return k({type:"setOrientation",orientation:e})})),setCurrentId:w((function(e){return k({type:"setCurrentId",currentId:e})})),setLoop:w((function(e){return k({type:"setLoop",loop:e})})),setWrap:w((function(e){return k({type:"setWrap",wrap:e})})),reset:w((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"]);S.__keys=I},function(e,t){!function(){e.exports=this.wp.keyboardShortcuts}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(8),o="undefined"==typeof window?r.useEffect:r.useLayoutEffect},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(45);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(8);function o(e){return Object(r.useState)(e)[0]}},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(8),o=Object(r.createContext)({})},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(8),o=n(54),c=n(60);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){"use strict";n.d(t,"a",(function(){return o}));var r=n(8);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,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(11),o=n(43),c=n(42),i=n(46),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 c}));var r=n(8);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,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";n.d(t,"a",(function(){return o}));var r=n(53);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(53),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(11),o=n(43),c=n(42),i=n(61),a=n(8),l=n(62),s=n(67),u=(n(75),n(40)),d=n(52),f=n(66),b=n(69),p=n(53),m=n(68);function v(e){return"undefined"!=typeof window&&-1!==window.navigator.userAgent.indexOf(e)}var g=v("Mac")&&!v("Chrome")&&(v("Safari")||v("Firefox"));function O(e){Object(f.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,f=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],w=E?o:o||0,S=e.disabled?Object(r.b)({pointerEvents:"none"},f):f,I=function(){if(g){var e=Object(a.useState)(null),t=e[0],n=e[1];return Object(a.useEffect)((function(){t&&(O(t),n(null))}),[t]),Object(a.useCallback)((function(e){var t=e.currentTarget;if(!Object(b.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 O(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:S,tabIndex:y?void 0:w,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){!function(){e.exports=this.wp.htmlEntities}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(8),o=n(57),c=n(38);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){!function(){e.exports=this.wp.isShallowEqual}()},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 f(e,t){if(t=t||{},(e=e||"")instanceof f)return e;if(!(this instanceof f))return new f(e,t);var n=function(e){var t={r:0,g:0,b:0},n=1,r=null,a=null,l=null,d=!1,f=!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)?(b=e.r,p=e.g,m=e.b,t={r:255*N(b,255),g:255*N(p,255),b:255*N(m,255)},d=!0,f="%"===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,f="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,f="hsl"),e.hasOwnProperty("a")&&(n=e.a));var b,p,m;return n=T(n),{ok:d,format:e.format||f,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 b(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 g(e,t){t=0===t?0:t||10;var n=f(e).toHsl();return n.s-=t/100,n.s=D(n.s),f(n)}function O(e,t){t=0===t?0:t||10;var n=f(e).toHsl();return n.s+=t/100,n.s=D(n.s),f(n)}function h(e){return f(e).desaturate(100)}function j(e,t){t=0===t?0:t||10;var n=f(e).toHsl();return n.l+=t/100,n.l=D(n.l),f(n)}function k(e,t){t=0===t?0:t||10;var n=f(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))),f(n)}function y(e,t){t=0===t?0:t||10;var n=f(e).toHsl();return n.l-=t/100,n.l=D(n.l),f(n)}function _(e,t){var n=f(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,f(n)}function E(e){var t=f(e).toHsl();return t.h=(t.h+180)%360,f(t)}function C(e){var t=f(e).toHsl(),n=t.h;return[f(e),f({h:(n+120)%360,s:t.s,l:t.l}),f({h:(n+240)%360,s:t.s,l:t.l})]}function w(e){var t=f(e).toHsl(),n=t.h;return[f(e),f({h:(n+90)%360,s:t.s,l:t.l}),f({h:(n+180)%360,s:t.s,l:t.l}),f({h:(n+270)%360,s:t.s,l:t.l})]}function S(e){var t=f(e).toHsl(),n=t.h;return[f(e),f({h:(n+72)%360,s:t.s,l:t.l}),f({h:(n+216)%360,s:t.s,l:t.l})]}function I(e,t,n){t=t||6,n=n||30;var r=f(e).toHsl(),o=360/n,c=[f(e)];for(r.h=(r.h-(o*t>>1)+720)%360;--t;)r.h=(r.h+o)%360,c.push(f(r));return c}function B(e,t){t=t||6;for(var n=f(e).toHsv(),r=n.h,o=n.s,c=n.v,i=[],a=1/t;t--;)i.push(f({h:r,s:o,v:c})),c=(c+a)%1;return i}f.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=b(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=b(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=f(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 f(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(g,arguments)},saturate:function(){return this._applyModification(O,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(S,arguments)},triad:function(){return this._applyCombination(C,arguments)},tetrad:function(){return this._applyCombination(w,arguments)}},f.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 f(e,t)},f.equals=function(e,t){return!(!e||!t)&&f(e).toRgbString()==f(t).toRgbString()},f.random=function(){return f.fromRatio({r:d(),g:d(),b:d()})},f.mix=function(e,t,n){n=0===n?0:n||50;var r=f(e).toRgb(),o=f(t).toRgb(),c=n/100;return f({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})},f.readability=function(e,t){var n=f(e),r=f(t);return(o.max(n.getLuminance(),r.getLuminance())+.05)/(o.min(n.getLuminance(),r.getLuminance())+.05)},f.isReadable=function(e,t,n){var r,o,c=f.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},f.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=f.readability(e,t[s]))>l&&(l=r,a=f(t[s]));return f.isReadable(e,a,{level:c,size:i})||!o?a:(n.includeFallbackColors=!1,f.mostReadable(e,["#fff","#000"],n))};var x=f.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=f.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=f:void 0===(r=function(){return f}.call(t,n,t,e))||(e.exports=r)}(Math)},function(e,t,n){"use strict";n(91),n(8)},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(11),o=n(43),c=n(42),i=n(8),a=n(67),l=(n(75),n(40)),s=n(49),u=n(70);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],f=u[1],b=Object(l.a)(n),p=Object(l.a)(o),m=Object(i.useCallback)((function(t){var n;if(null===(n=b.current)||void 0===n||n.call(b,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&&f(!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&&(f(!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.notices}()},,,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(100);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";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.d(t,"a",(function(){return s}));var r=n(11),o=n(43),c=n(42),i=n(8),a=n(60),l=n(58),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"},,function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(45);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){!function(){e.exports=this.wp.warning}()},,,function(e,t,n){"use strict";t.__esModule=!0;var r=n(185);t.default=r.default},,function(e,t){!function(){e.exports=this.wp.viewport}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(45);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){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 f(){u&&l&&(u=!1,l.length?s=l.concat(s):d=-1,s.length&&b())}function b(){if(!u){var e=a(f);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(b)},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){!function(){e.exports=this.ReactDOM}()},,,,function(e,t,n){"use strict";n.d(t,"a",(function(){return E})),n.d(t,"b",(function(){return _}));var r=n(11),o=n(43),c=n(42),i=n(61),a=n(8),l=n(62),s=(n(75),n(40)),u=n(49),d=n(53),f=n(70),b=n(72),p=n(76),m=n(45),v=n(81),g=n(93),O=n(50),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(g.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:[f.a],useState:O.g,useOptions:function(e){return Object(r.b)(Object(r.b)({},e),{},{currentId:Object(O.e)(e)})},useProps:function(e,t){var n=t.ref,o=t.onFocus,c=t.onBlur,i=t.onKeyDown,f=t.onKeyUp,b=Object(r.a)(t,["ref","onFocus","onBlur","onKeyDown","onKeyUp"]),g=Object(a.useRef)(null),_=Object(O.d)(e.items,e.currentId),E=Object(a.useRef)(void 0),C=Object(s.a)(o),w=Object(s.a)(c),S=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}(g):void 0;Object(a.useEffect)((function(){var t=g.current;t&&e.unstable_moves&&!_&&t.focus()}),[e.unstable_moves,_]);var I=k(e.unstable_virtual,_,i),B=k(e.unstable_virtual,_,f),x=Object(a.useCallback)((function(t){var n;if(e.unstable_virtual){var r,o,c=(null==S?void 0:S.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=w.current)||void 0===n||n.call(w,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(O.a)(Object(O.b)(Object(O.f)(Object(O.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)(g,n),id:e.baseId,onFocus:x,onBlur:P,onKeyDown:T,onKeyUp:B,"aria-activedescendant":e.unstable_virtual&&(null==_?void 0:_.id)||void 0},b)},useComposeProps:function(e,t){t=Object(i.a)(e,t,!0);var n=Object(f.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(b.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(11),o=n(43),c=n(42),i=n(8),a=n(62),l=(n(75),n(40)),s=n(49),u=n(66),d=n(69),f=n(68),b=n(77),p=n(76),m=n(45),v=n(50),g=n(86),O=n(82),h=n(83);function j(e){return e.querySelector("[data-composite-item-widget]")}var k=Object(c.a)({name:"CompositeItem",compose:[b.a,g.a],useState:v.g,propsAreEqual:function(e,t){if(!t.id||e.id!==t.id)return b.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 b.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,b=void 0===c?0:c,v=t.onFocus,g=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,w=e.disabled&&!e.focusable,S=e.currentId===C,I=Object(l.a)(S),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)(g),N=Object(l.a)(k),D=Object(l.a)(y),R=!e.unstable_virtual&&!e.unstable_hasActiveWidget&&S||!(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:!!w}),function(){var t;null===(t=e.unregisterItem)||void 0===t||t.call(e,C)}}),[C,w,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(f.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(O.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(O.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?b:-1,"aria-selected":!(!e.unstable_virtual||!S)||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";function r(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(182)),c=r(n(183)),i=n(8),a=r(i),l=r(n(145)),s=r(n(184)),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 f(e,t){return u.und(e)||u.nul(e)?t:e}function b(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,g,O=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 O&&e.addChild(s(t))}))},t.detach=function(){return t.payload.forEach((function(e){return e instanceof O&&e.removeChild(s(t))}))},t}return l(t,e),t}(O),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 O&&e.addChild(s(t))}))},t.detach=function(){return Object.values(t.payload).forEach((function(e){return e instanceof O&&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 O)&&(t[n]=r instanceof O?r[e?"getAnimatedValue":"getValue"]():r)}return t},n.getAnimatedValue=function(){return this.getValue(!0)},t}(O);function k(e,t){v={fn:e,transform:t}}function y(e){g=e}var _,E=function(e){return"undefined"!=typeof window?window.requestAnimationFrame(e):-1},C=function(e){"undefined"!=typeof window&&window.cancelAnimationFrame(e)};function w(e){_=e}var S,I=function(){return Date.now()};function B(e){S=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 g},injectColorNames:y,get requestFrame(){return E},get cancelFrame(){return C},injectFrame:function(e,t){E=e,C=t},get interpolation(){return _},injectStringInterpolator:w,get now(){return I},injectNow:function(e){I=e},get defaultElement(){return S},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,f=0;f<s.animatedValues.length;f++){var b=s.animatedValues[f];if(!b.done){var p=s.fromValues[f],m=s.toValues[f],v=b.lastPosition,g=m instanceof O,h=Array.isArray(s.initialVelocity)?s.initialVelocity[f]:s.initialVelocity;if(g&&(m=m.getValue()),s.immediate)b.setValue(m),b.done=!0;else if("string"!=typeof p&&"string"!=typeof m){if(void 0!==s.duration)v=p+s.easing((t-b.startTime)/s.duration)*(m-p),u=t>=b.startTime+s.duration;else if(s.decay)v=p+h/(1-.998)*(1-Math.exp(-(1-.998)*(t-b.startTime))),(u=Math.abs(b.lastPosition-v)<.1)&&(m=v);else{d=void 0!==b.lastTime?b.lastTime:t,h=void 0!==b.lastVelocity?b.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,b.lastVelocity=h,b.lastTime=t}g&&!s.toValues[f].done&&(u=!1),u?(b.value!==m&&(v=m),b.done=!0):a=!0,b.setValue(v),b.lastPosition=v}else b.setValue(m),b.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){var c;return(c=e.call(this)||this).calc=void 0,c.payload=n instanceof h&&!(n instanceof t)?n.getPayload():Array.isArray(n)?n:[n],c.calc=F(r,o),c}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){this.calc=F(e,t)},n.interpolate=function(e,n){return new t(this,e,n)},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){return new V(this,e,t)},t}(O),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,f=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[f]),f++,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,O=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)&&!g[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,w=a.parent,S=a.interpolation,B=b(j?y.getPayload():y),x=i;h&&(x=_({range:[0,1],output:[i,i]})(1));var P,T=S&&S.getValue(),N=!u.und(w)&&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)w=S=a.parent||new H(k);else if(m)w=S=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?(w=a.parent).setValue(0,!1):w=new H(0);var F={output:[L,i]};a.interpolation?(S=a.interpolation,a.interpolation.updateConfig(F)):S=w.interpolate(F)}return B=b(j?y.getPayload():y),C=b(w.getPayload()),v&&!h&&w.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(O,r)&&w.setValue(h?y:i,!1),o({},e,((M={})[r]=o({},a,{name:r,parent:w,interpolation:S,animatedValues:C,toValues:B,previous:x,config:E,fromValues:b(w.getValue()),immediate:p(O,r),initialVelocity:f(E.velocity,0),clamp:f(E.clamp,!1),precision:f(E.precision,.01),tension:f(E.tension,170),friction:f(E.friction,26),mass:f(E.mass,1),duration:E.duration,easing:f(E.easing,(function(e){return e})),decay:E.decay}),M))}return D?e:(h&&(w.setValue(1,!1),S.updateConfig({output:[x,x]})),w.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):b(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=b(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 O||(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 fe(e){var t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function be(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|fe(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]),be(n[2]),be(n[3])))>>>0:(n=re.exec(t))?(se(de(n[1]),be(n[2]),be(n[3]))|fe(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,ge=new RegExp("("+Object.keys(Q).join("|")+")","g"),Oe={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||Oe.hasOwnProperty(e)&&Oe[e]?(""+t).trim():t+"px"}Oe=Object.keys(Oe).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}),Oe);var ke={};N((function(e){return new X(e)})),B("div"),w((function(e){var t=e.output.map((function(e){return e.replace(ve,pe)})).map((function(e){return e.replace(ge,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 f in a){var b=l?f:ke[f]||(ke[f]=f.replace(/([A-Z])/g,(function(e){return"-"+e.toLowerCase()})));void 0!==e.getAttribute(b)&&e.setAttribute(b,a[f])}}),(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),f=i.useRef(null),b=i.useCallback((function(e){var t=s.current;s.current=new R(e,(function(){f.current&&!1===v.fn(f.current,s.current.getAnimatedValue())&&r()})),t&&t.detach()}),[]);i.useEffect((function(){return function(){l.current=!1,s.current&&s.current.detach()}}),[]),i.useImperativeHandle(n,(function(){return T(f,l,r)})),b(t);var p=s.current.getValue(),m=(p.scrollTop,p.scrollLeft,c(p,["scrollTop","scrollLeft"]));return a.createElement(e,o({},m,{ref:function(e){return f.current=function(e,t){return t&&(u.fun(t)?t(e):u.obj(t)&&(t.current=e)),e}(e,n)}}))}))},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],f=l[2],b=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&&b(t)})),i.useEffect((function(){n.current=!0}),[]),r?[s,b,f]: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),f=void 0!==u&&u,b=(a.enter,a.leave,a.update,a.onDestroyed),m=(a.keys,a.items,a.onFrame),v=a.onRest,g=a.onStart,O=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,f=a.enter,b=a.leave,m=a.update,v=a.trail,g=void 0===v?0:v,O=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),w=[].concat(i.deleted),S=Object.keys(C),I=new Set(S),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=-g;for(;k.length;){switch(k.shift()){case"enter":x.forEach((function(e,t){O&&w.find((function(t){return t.originalKey===e}))&&(w=w.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:O?String(e):W++,item:o,trail:N+=g,config:p(h,o,c),from:p(n&&void 0!==u?u||{}:d,o),to:p(f,o)}}));break;case"leave":P.forEach((function(e){var t=_.indexOf(e),n=E[t];w.unshift(o({},C[e],{slot:"leave",destroyed:!0,left:_[Math.max(0,t-1)],right:_[Math.min(_.length,t+1)],trail:N+=g,config:p(h,n,"leave"),to:p(b,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+=g,config:p(h,n,"update"),to:p(m,n)})}))}}var D=s.map((function(e){return C[e]}));return w.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:w,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:O,onRest:function(n){y.current.mounted&&(e.destroyed&&(O||s||Y(y,a),b&&b(l)),!Array.from(y.current.instances).some((function(e){return!e[1].idle}))&&(O||s)&&y.current.deleted.length>0&&Y(y),v&&v(l,t,n))},onStart:g&&function(){return g(l,t)},onFrame:m&&function(e){return m(l,t,e)},delay:i,reset:f&&"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";e.exports=n(190)},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(0),o=n(6),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(6),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(6),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";var r=n(21),o=n(32),c=n(0),i=n(2),a=n(3),l=n(168),s=Object(a.createSlotFill)("BlockControls"),u=s.Fill,d=s.Slot;var f=function(e){return"BlockControls".concat(e?"-expanded":"")},b=function(e){var t=e.controls,n=e.__experimentalIsExpanded,r=e.children;return Object(l.a)()?Object(c.createElement)(u,{name:f(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};b.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:f(n)},i,{fillProps:l}))},t.a=b},,,,,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(152);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,n){"use strict";var r=n(140);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,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){if(null==e)return{};var n,r,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,t);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var 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=o(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){r(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){e.exports=function(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}},function(e,t,n){e.exports=function(){"use strict";return function(e){var t={};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])}(t,e),function(e){return function(n){return function(r){var o,c,i=t[r.type],a=n(r);if(i)for(o=0;o<i.length;o++)(c=i[o](r,e))&&e.dispatch(c);return a}}}}}()},,,,,,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){!function(){e.exports=this.wp.tokenList}()},,,function(e,t,n){"use strict";var r=n(0),o=n(6),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(6),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";n.d(t,"a",(function(){return c}));var r=n(4),o=n(85);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,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){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,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(291)),o=a(n(296)),c=a(n(212)),i=a(n(209));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(8),l=n(22),s=n(186),u=n(187),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(){this.props.value!==this.currentValue&&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;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(188);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(0),o=n(6),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(191);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 f=r.isWindow(t),b=r.offset(e),p=r.outerHeight(e),m=r.outerWidth(e),v=void 0,g=void 0,O=void 0,h=void 0,j=void 0,k=void 0,y=void 0,_=void 0,E=void 0,C=void 0;f?(y=t,C=r.height(y),E=r.width(y),_={left:r.scrollLeft(y),top:r.scrollTop(y)},j={left:b.left-_.left-s,top:b.top-_.top-l},k={left:b.left+m-(_.left+E)+d,top:b.top+p-(_.top+C)+u},h=_):(v=r.offset(t),g=t.clientHeight,O=t.clientWidth,h={left:t.scrollLeft,top:t.scrollTop},j={left:b.left-(v.left+(parseFloat(r.css(t,"borderLeftWidth"))||0))-s,top:b.top-(v.top+(parseFloat(r.css(t,"borderTopWidth"))||0))-l},k={left:b.left+m-(v.left+O+(parseFloat(r.css(t,"borderRightWidth"))||0))+d,top:b.top+p-(v.top+g+(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 f=void 0;function b(e,t){for(var n=0;n<e.length;n++)t(e[n])}function p(e){return"border-box"===f(e,"boxSizing")}"undefined"!=typeof window&&(f=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 g(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(f(e,a))||0}return r}function O(e){return null!=e&&e==e.window}var h={};function j(e,t,n){if(O(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=(f(e),p(e)),i=0;(null==o||o<=0)&&(o=void 0,(null==(i=f(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-g(e,["border","padding"],r):i;if(a){var s=2===n?-g(e,["border"],r):g(e,["margin"],r);return l+(1===n?0:s)}return i+g(e,m.slice(n),r)}b(["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)):f(e,t);for(var c in t)t.hasOwnProperty(c)&&_(e,c,t[c])}b(["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){f(t);return p(t)&&(r+=g(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:O,each:b,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(O(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(O(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(6),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(6),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";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(22)),o=a(n(8)),c=a(n(106)),i=n(210);n(211);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(22))&&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(22)),o=a(n(8)),c=n(210),i=n(297);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 f=(0,c.polyfill)(d);t.default=f,e.exports=t.default},function(e,t,n){"use strict";var r=n(0),o=n(6),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(6),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(6),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(6),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";var r=n(0),o=n(6),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(6),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";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(20),o=n(0),c=n(175),i=n(2),a=(n(94),n(131));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)(),f=Object(o.useRef)(),b=Object(o.useState)({}),p=Object(r.a)(b,2),m=p[0],v=p[1],g=Object(o.useRef)();g.current=n;var O=Object(o.useCallback)(Object(i.throttle)((function(){var e=g.current.length?d.current:f.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}))&&O()}));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:f},s))))}}).call(this,n(101))},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(298))&&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 f=n?c(d):d,b={},p=!0,m={node:f,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){b.before=e},after:function(e){b.after=e},pre:function(e){b.pre=e},post:function(e){b.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 g=t.call(m,m.node);return void 0!==g&&m.update&&m.update(g),b.before&&b.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),b.pre&&b.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,b.post&&b.post.call(m,c),r.pop()})),o.pop()),b.after&&b.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(6),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(6),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(6),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(6),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(22));var r=a(n(292)),o=a(n(295)),c=a(n(8)),i=a(n(209));n(211);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 f=d;t.default=f,e.exports=t.default},function(e,t,n){"use strict";var r=n(293);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(294));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(22));var r=i(n(8)),o=n(106),c=i(n(212));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],f=(0,r.isValidElement)(d)&&!d.props.in;!u||s&&!f?u||!s||f?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(8);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";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 f=t[i-1];return i>1&&"string"==typeof f.value&&(f.added||f.removed)&&e.equals("",f.value)&&(t[i-2].value+=f.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,f=[{newPos:-1,components:[]}],b=this.extractCommon(f[0],t,e,0);if(f[0].newPos+1>=l&&b+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=f[n-1],b=f[n+1],p=(b?b.newPos:0)-n;d&&(f[n-1]=void 0);var m=d&&d.newPos+1<l,v=b&&0<=p&&p<s;if(m||v){if(!m||v&&d.newPos<b.newPos?(r=c(b),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));f[n]=r}else f[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(6),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(6),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 pe})),n.d(t,"getColorObjectByAttributeValues",(function(){return fe})),n.d(t,"getColorObjectByColorValue",(function(){return be})),n.d(t,"createCustomColorsHOC",(function(){return dn})),n.d(t,"withColors",(function(){return fn})),n.d(t,"__experimentalUseColors",(function(){return In})),n.d(t,"__experimentalGetGradientClass",(function(){return Oe})),n.d(t,"getGradientValueBySlug",(function(){return he})),n.d(t,"__experimentalGetGradientObjectByGradientValue",(function(){return je})),n.d(t,"getGradientSlugByValue",(function(){return ke})),n.d(t,"__experimentalUseGradient",(function(){return ye})),n.d(t,"getFontSize",(function(){return yt})),n.d(t,"getFontSizeClass",(function(){return Et})),n.d(t,"getFontSizeObjectByValue",(function(){return _t})),n.d(t,"FontSizePicker",(function(){return Ct})),n.d(t,"withFontSizes",(function(){return Nn})),n.d(t,"AlignmentToolbar",(function(){return Hn})),n.d(t,"Autocomplete",(function(){return or})),n.d(t,"BlockAlignmentToolbar",(function(){return T})),n.d(t,"__experimentalBlockAlignmentMatrixToolbar",(function(){return cr})),n.d(t,"BlockBreadcrumb",(function(){return ar})),n.d(t,"BlockContextProvider",(function(){return dr})),n.d(t,"BlockControls",(function(){return g.a})),n.d(t,"BlockColorsStyleSelector",(function(){return mr})),n.d(t,"BlockEdit",(function(){return Or})),n.d(t,"useBlockEditContext",(function(){return z.b})),n.d(t,"BlockFormatControls",(function(){return _r})),n.d(t,"BlockIcon",(function(){return tr})),n.d(t,"BlockNavigationDropdown",(function(){return cd})),n.d(t,"__experimentalBlockNavigationBlockFill",(function(){return Gu})),n.d(t,"__experimentalBlockNavigationEditor",(function(){return jd})),n.d(t,"__experimentalBlockNavigationTree",(function(){return td})),n.d(t,"__experimentalBlockVariationPicker",(function(){return yd})),n.d(t,"BlockVerticalAlignmentToolbar",(function(){return xd})),n.d(t,"ButtonBlockerAppender",(function(){return rl})),n.d(t,"ColorPalette",(function(){return Dd})),n.d(t,"ColorPaletteControl",(function(){return Rd})),n.d(t,"ContrastChecker",(function(){return Ke})),n.d(t,"__experimentalGradientPicker",(function(){return Ld})),n.d(t,"__experimentalGradientPickerControl",(function(){return Fd})),n.d(t,"__experimentalGradientPickerPanel",(function(){return Vd})),n.d(t,"__experimentalColorGradientControl",(function(){return Ne})),n.d(t,"__experimentalPanelColorGradientSettings",(function(){return ze})),n.d(t,"__experimentalImageSizeControl",(function(){return zd})),n.d(t,"InnerBlocks",(function(){return tf})),n.d(t,"__experimentalUseInnerBlocksProps",(function(){return ef})),n.d(t,"InspectorAdvancedControls",(function(){return q})),n.d(t,"InspectorControls",(function(){return Qe})),n.d(t,"__experimentalLinkControl",(function(){return Af})),n.d(t,"__experimentalLinkControlSearchInput",(function(){return Bf})),n.d(t,"__experimentalLinkControlSearchResults",(function(){return Of})),n.d(t,"__experimentalLinkControlSearchItem",(function(){return gf})),n.d(t,"LineHeightControl",(function(){return mt})),n.d(t,"MediaReplaceFlow",(function(){return Hf})),n.d(t,"MediaPlaceholder",(function(){return qf})),n.d(t,"MediaUpload",(function(){return Ff})),n.d(t,"MediaUploadCheck",(function(){return Vf})),n.d(t,"PanelColorSettings",(function(){return gn})),n.d(t,"PlainText",(function(){return Xf})),n.d(t,"__experimentalResponsiveBlockControl",(function(){return Zf})),n.d(t,"RichText",(function(){return hd})),n.d(t,"RichTextShortcut",(function(){return Jf})),n.d(t,"RichTextToolbarButton",(function(){return eb})),n.d(t,"__unstableRichTextInputEvent",(function(){return nb})),n.d(t,"ToolSelector",(function(){return ob})),n.d(t,"__experimentalUnitControl",(function(){return Rt})),n.d(t,"URLInput",(function(){return bf})),n.d(t,"URLInputButton",(function(){return lb})),n.d(t,"URLPopover",(function(){return Kf})),n.d(t,"__experimentalImageURLInputUI",(function(){return fb})),n.d(t,"withColorContext",(function(){return Nd})),n.d(t,"__experimentalBlockSettingsMenuFirstItem",(function(){return Zs})),n.d(t,"__experimentalInserterMenuExtension",(function(){return Rl})),n.d(t,"__experimentalPreviewOptions",(function(){return pb})),n.d(t,"__experimentalUseResizeCanvas",(function(){return kb})),n.d(t,"BlockInspector",(function(){return Sb})),n.d(t,"BlockList",(function(){return hl})),n.d(t,"__experimentalBlock",(function(){return xu})),n.d(t,"useBlockProps",(function(){return Iu})),n.d(t,"BlockMover",(function(){return Ss})),n.d(t,"BlockPreview",(function(){return yl})),n.d(t,"BlockSelectionClearer",(function(){return Ib})),n.d(t,"BlockSettingsMenu",(function(){return au})),n.d(t,"BlockSettingsMenuControls",(function(){return ou})),n.d(t,"BlockTitle",(function(){return ir})),n.d(t,"BlockToolbar",(function(){return bu})),n.d(t,"CopyHandler",(function(){return Ks})),n.d(t,"DefaultBlockAppender",(function(){return nl})),n.d(t,"__unstableEditorStyles",(function(){return Jb})),n.d(t,"Inserter",(function(){return fs})),n.d(t,"__experimentalLibrary",(function(){return ep})),n.d(t,"__experimentalSearchForm",(function(){return ko})),n.d(t,"BlockEditorKeyboardShortcuts",(function(){return np})),n.d(t,"MultiSelectScrollIntoView",(function(){return rp})),n.d(t,"NavigableToolbar",(function(){return _s})),n.d(t,"ObserveTyping",(function(){return cp})),n.d(t,"PreserveScrollInReorder",(function(){return ip})),n.d(t,"SkipToSelectedBlock",(function(){return yb})),n.d(t,"Typewriter",(function(){return dp})),n.d(t,"Warning",(function(){return Xr})),n.d(t,"WritingFlow",(function(){return gs})),n.d(t,"BlockEditorProvider",(function(){return el})),n.d(t,"__experimentalUseSimulatedMediaQuery",(function(){return jb})),n.d(t,"__experimentalUseEditorFeature",(function(){return ve})),n.d(t,"transformStyles",(function(){return Zb})),n.d(t,"validateThemeColors",(function(){return fp})),n.d(t,"validateThemeGradients",(function(){return bp})),n.d(t,"storeConfig",(function(){return Qa})),n.d(t,"SETTINGS_DEFAULTS",(function(){return Eo}));var r={};n.r(r),n.d(r,"resetBlocks",(function(){return sc})),n.d(r,"resetSelection",(function(){return uc})),n.d(r,"receiveBlocks",(function(){return dc})),n.d(r,"updateBlockAttributes",(function(){return fc})),n.d(r,"updateBlock",(function(){return bc})),n.d(r,"selectBlock",(function(){return pc})),n.d(r,"selectPreviousBlock",(function(){return mc})),n.d(r,"selectNextBlock",(function(){return vc})),n.d(r,"startMultiSelect",(function(){return gc})),n.d(r,"stopMultiSelect",(function(){return Oc})),n.d(r,"multiSelect",(function(){return hc})),n.d(r,"clearSelectedBlock",(function(){return jc})),n.d(r,"toggleSelection",(function(){return kc})),n.d(r,"replaceBlocks",(function(){return _c})),n.d(r,"replaceBlock",(function(){return Ec})),n.d(r,"moveBlocksDown",(function(){return wc})),n.d(r,"moveBlocksUp",(function(){return Sc})),n.d(r,"moveBlocksToPosition",(function(){return Ic})),n.d(r,"moveBlockToPosition",(function(){return Bc})),n.d(r,"insertBlock",(function(){return xc})),n.d(r,"insertBlocks",(function(){return Pc})),n.d(r,"showInsertionPoint",(function(){return Tc})),n.d(r,"hideInsertionPoint",(function(){return Nc})),n.d(r,"setTemplateValidity",(function(){return Dc})),n.d(r,"synchronizeTemplate",(function(){return Rc})),n.d(r,"mergeBlocks",(function(){return Ac})),n.d(r,"removeBlocks",(function(){return Mc})),n.d(r,"removeBlock",(function(){return Lc})),n.d(r,"replaceInnerBlocks",(function(){return Fc})),n.d(r,"toggleBlockMode",(function(){return Vc})),n.d(r,"startTyping",(function(){return Hc})),n.d(r,"stopTyping",(function(){return zc})),n.d(r,"startDraggingBlocks",(function(){return Uc})),n.d(r,"stopDraggingBlocks",(function(){return Gc})),n.d(r,"enterFormattedText",(function(){return Kc})),n.d(r,"exitFormattedText",(function(){return Wc})),n.d(r,"selectionChange",(function(){return qc})),n.d(r,"insertDefaultBlock",(function(){return $c})),n.d(r,"updateBlockListSettings",(function(){return Yc})),n.d(r,"updateSettings",(function(){return Xc})),n.d(r,"__unstableSaveReusableBlock",(function(){return Qc})),n.d(r,"__unstableMarkLastChangeAsPersistent",(function(){return Zc})),n.d(r,"__unstableMarkNextChangeAsNotPersistent",(function(){return Jc})),n.d(r,"__unstableMarkAutomaticChange",(function(){return ei})),n.d(r,"setNavigationMode",(function(){return ti})),n.d(r,"setBlockMovingClientId",(function(){return ni})),n.d(r,"duplicateBlocks",(function(){return ri})),n.d(r,"insertBeforeBlock",(function(){return oi})),n.d(r,"insertAfterBlock",(function(){return ci})),n.d(r,"toggleBlockHighlight",(function(){return ii})),n.d(r,"flashBlock",(function(){return ai})),n.d(r,"setHasControlledInnerBlocks",(function(){return li}));var o={};n.r(o),n.d(o,"getBlockName",(function(){return vi})),n.d(o,"isBlockValid",(function(){return gi})),n.d(o,"getBlockAttributes",(function(){return Oi})),n.d(o,"getBlock",(function(){return hi})),n.d(o,"__unstableGetBlockWithoutInnerBlocks",(function(){return ji})),n.d(o,"getBlocks",(function(){return ki})),n.d(o,"__unstableGetBlockWithBlockTree",(function(){return yi})),n.d(o,"__unstableGetBlockTree",(function(){return _i})),n.d(o,"getClientIdsOfDescendants",(function(){return Ei})),n.d(o,"getClientIdsWithDescendants",(function(){return Ci})),n.d(o,"getGlobalBlockCount",(function(){return wi})),n.d(o,"getBlocksByClientId",(function(){return Si})),n.d(o,"getBlockCount",(function(){return Ii})),n.d(o,"getSelectionStart",(function(){return Bi})),n.d(o,"getSelectionEnd",(function(){return xi})),n.d(o,"getBlockSelectionStart",(function(){return Pi})),n.d(o,"getBlockSelectionEnd",(function(){return Ti})),n.d(o,"getSelectedBlockCount",(function(){return Ni})),n.d(o,"hasSelectedBlock",(function(){return Di})),n.d(o,"getSelectedBlockClientId",(function(){return Ri})),n.d(o,"getSelectedBlock",(function(){return Ai})),n.d(o,"getBlockRootClientId",(function(){return Mi})),n.d(o,"getBlockParents",(function(){return Li})),n.d(o,"getBlockParentsByBlockName",(function(){return Fi})),n.d(o,"getBlockHierarchyRootClientId",(function(){return Vi})),n.d(o,"getLowestCommonAncestorWithSelectedBlock",(function(){return Hi})),n.d(o,"getAdjacentBlockClientId",(function(){return zi})),n.d(o,"getPreviousBlockClientId",(function(){return Ui})),n.d(o,"getNextBlockClientId",(function(){return Gi})),n.d(o,"getSelectedBlocksInitialCaretPosition",(function(){return Ki})),n.d(o,"getSelectedBlockClientIds",(function(){return Wi})),n.d(o,"getMultiSelectedBlockClientIds",(function(){return qi})),n.d(o,"getMultiSelectedBlocks",(function(){return $i})),n.d(o,"getFirstMultiSelectedBlockClientId",(function(){return Yi})),n.d(o,"getLastMultiSelectedBlockClientId",(function(){return Xi})),n.d(o,"isFirstMultiSelectedBlock",(function(){return Qi})),n.d(o,"isBlockMultiSelected",(function(){return Zi})),n.d(o,"isAncestorMultiSelected",(function(){return Ji})),n.d(o,"getMultiSelectedBlocksStartClientId",(function(){return ea})),n.d(o,"getMultiSelectedBlocksEndClientId",(function(){return ta})),n.d(o,"getBlockOrder",(function(){return na})),n.d(o,"getBlockIndex",(function(){return ra})),n.d(o,"isBlockSelected",(function(){return oa})),n.d(o,"hasSelectedInnerBlock",(function(){return ca})),n.d(o,"isBlockWithinSelection",(function(){return ia})),n.d(o,"hasMultiSelection",(function(){return aa})),n.d(o,"isMultiSelecting",(function(){return la})),n.d(o,"isSelectionEnabled",(function(){return sa})),n.d(o,"getBlockMode",(function(){return ua})),n.d(o,"isTyping",(function(){return da})),n.d(o,"isDraggingBlocks",(function(){return fa})),n.d(o,"getDraggedBlockClientIds",(function(){return ba})),n.d(o,"isBlockBeingDragged",(function(){return pa})),n.d(o,"isAncestorBeingDragged",(function(){return ma})),n.d(o,"isCaretWithinFormattedText",(function(){return va})),n.d(o,"getBlockInsertionPoint",(function(){return ga})),n.d(o,"isBlockInsertionPointVisible",(function(){return Oa})),n.d(o,"isValidTemplate",(function(){return ha})),n.d(o,"getTemplate",(function(){return ja})),n.d(o,"getTemplateLock",(function(){return ka})),n.d(o,"canInsertBlockType",(function(){return _a})),n.d(o,"canInsertBlocks",(function(){return Ea})),n.d(o,"getInserterItems",(function(){return Ia})),n.d(o,"hasInserterItems",(function(){return Ba})),n.d(o,"__experimentalGetAllowedBlocks",(function(){return xa})),n.d(o,"getBlockListSettings",(function(){return Pa})),n.d(o,"getSettings",(function(){return Ta})),n.d(o,"isLastBlockChangePersistent",(function(){return Na})),n.d(o,"__experimentalGetBlockListSettingsForBlocks",(function(){return Da})),n.d(o,"__experimentalGetParsedReusableBlock",(function(){return Ra})),n.d(o,"__unstableIsLastBlockChangeIgnored",(function(){return Aa})),n.d(o,"__experimentalGetLastBlockAttributeChanges",(function(){return Ma})),n.d(o,"isNavigationMode",(function(){return Fa})),n.d(o,"hasBlockMovingClientId",(function(){return Va})),n.d(o,"didAutomaticChange",(function(){return Ha})),n.d(o,"isBlockHighlighted",(function(){return za})),n.d(o,"areInnerBlocksControlled",(function(){return Ua})),n.d(o,"__experimentalGetActiveBlockIdByBlockNames",(function(){return Ga}));var c=n(9),i=n(17),a=(n(99),n(51)),l=(n(78),n(21));function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var u=n(0),d=n(7),f=n.n(d),b=n(2),p=n(10),m=n(26),v=n(4),g=n(131),O=n(1),h=n(3),j=n(6),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 w(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 S(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var I={left:{icon:k,title:Object(O.__)("Align left")},center:{icon:y,title:Object(O.__)("Align center")},right:{icon:_,title:Object(O.__)("Align right")},wide:{icon:E,title:Object(O.__)("Wide width")},full:{icon:C,title:Object(O.__)("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(O.__)("Change alignment"),controls:l.map((function(e){return S(S({},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){s(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?b.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)(g.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(b.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=f()("align".concat(r),e.className)),e}));var z=n(85),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){s(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(O.__)("HTML anchor"),help:Object(u.createElement)(u.Fragment,null,Object(O.__)("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(O.__)("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){s(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(b.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(O.__)("Additional CSS class(es)"),value:t.attributes.className||"",onChange:function(e){t.setAttributes({className:""!==e?e:void 0})},help:Object(O.__)("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=f()(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(b.omit)(e,["className"]),o=Object(c.getSaveContent)(t,r),i=te(o),a=te(n),l=Object(b.difference)(a,i);l.length?e.className=l.join(" "):o&&delete e.className}return e}));var ne=n(152);function re(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}var oe=n(136);function ce(e){return function(e){if(Array.isArray(e))return Object(ne.a)(e)}(e)||re(e)||Object(oe.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.")}()}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(b.uniq)([Object(c.getBlockDefaultClassName)(t.name)].concat(ce(e.className.split(" ")))).join(" ").trim():e.className=Object(c.getBlockDefaultClassName)(t.name)),e}));var ie=n(20),ae=n(169),le=n(170);function se(e){return Object(ae.a)(e)||re(e)||Object(oe.a)(e)||Object(le.a)()}var ue=n(74),de=n.n(ue),fe=function(e,t,n){if(t){var r=Object(b.find)(e,{slug:t});if(r)return r}return{color:n}},be=function(e,t){return Object(b.find)(e,{color:t})};function pe(e,t){if(e&&t)return"has-".concat(Object(b.kebabCase)(t),"-").concat(e)}var me={"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 ve(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(b.get)(o,i))&&void 0!==r?r:Object(b.get)(o,c);if(void 0!==a)return a;var l=me[e]?me[e](o):void 0;return void 0!==l?l:"typography.dropCap"===e||void 0}),[t,e])}var ge=[];function Oe(e){if(e)return"has-".concat(e,"-gradient-background")}function he(e,t){var n=Object(b.find)(e,["slug",t]);return n&&n.gradient}function je(e,t){return Object(b.find)(e,["gradient",t])}function ke(e,t){var n=je(e,t);return n&&n.slug}function ye(){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=ve("color.gradients")||ge,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,f=l.customGradient,b=Object(v.useDispatch)("core/block-editor"),p=b.updateBlockAttributes,m=Object(u.useCallback)((function(e){var t,r,c=ke(a,e);c?p(i,(s(r={},n,c),s(r,o,void 0),r)):p(i,(s(t={},n,void 0),s(t,o,e),t))}),[a,i,p]),g=Oe(d);return{gradientClass:g,gradientValue:d?he(a,d):f,setGradient:m}}var _e=function e(t){if(!Object(b.isObject)(t))return t;var n=Object(b.pickBy)(Object(b.mapValues)(t,e),b.identity);return Object(b.isEqual)(n,{})?void 0:n},Ee=n(32);function Ce(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 we(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ce(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ce(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}
|
2 |
// translators: first %s: the color name or value (e.g. red or #ff0000)
|
3 |
var Se=Object(O.__)("(Color: %s)"),Ie=Object(O.__)("(Gradient: %s)"),Be=["colors","disableCustomColors","gradients","disableCustomGradients"];// translators: first %s: the gradient name or value (e.g. red to green or linear-gradient(135deg,rgba(6,147,227,1) 0%,rgb(155,81,224) 100%)
|
4 |
function xe(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=be(r,t=a),d=s&&s.name;n=Object(O.sprintf)(Se,d||t)}}else if("gradient"===i&&l){var f=je(o,t=l),b=f&&f.name;n=Object(O.sprintf)(Ie,b||t)}return Object(u.createElement)(u.Fragment,null,c,!!t&&Object(u.createElement)(h.ColorIndicator,{colorValue:t,"aria-label":n}))}function Pe(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(b.isEmpty)(t)||!r),v=s&&(!Object(b.isEmpty)(n)||!o),g=Object(u.useState)(p?"gradient":!!m&&"color"),j=Object(ie.a)(g,2),k=j[0],y=j[1];return m||v?Object(u.createElement)(h.BaseControl,{className:f()("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)(xe,{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(O.__)("Solid")),Object(u.createElement)(h.Button,{isSmall:!0,isPressed:"gradient"===k,onClick:function(){return y("gradient")}},Object(O.__)("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 Te(e){var t={};return t.colors=ve("color.palette"),t.gradients=ve("color.gradients"),t.disableCustomColors=!ve("color.custom"),t.disableCustomGradients=!ve("color.customGradient"),Object(u.createElement)(Pe,we(we({},t),e))}var Ne=function(e){return Object(b.every)(Be,(function(t){return e.hasOwnProperty(t)}))?Object(u.createElement)(Pe,e):Object(u.createElement)(Te,e)};function De(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 Re(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?De(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):De(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}
|
5 |
// translators: first %s: The type of color or gradient (e.g. background, overlay...), second %s: the color name or value (e.g. red or #ff0000)
|
6 |
var Ae=Object(O.__)("(%s: color %s)"),Me=Object(O.__)("(%s: gradient %s)"),Le=["colors","disableCustomColors","gradients","disableCustomGradients"],Fe=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=be(l||t,c);o=Object(O.sprintf)(Ae,a.toLowerCase(),d&&d.name||c)}else{var f=je(s||n,c);o=Object(O.sprintf)(Me,a.toLowerCase(),f&&f.name||i)}return Object(u.createElement)(h.ColorIndicator,{key:r,colorValue:c||i,"aria-label":o})}))},Ve=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(Ee.a)(e,["className","colors","gradients","disableCustomColors","disableCustomGradients","children","settings","title"]);if(Object(b.isEmpty)(n)&&Object(b.isEmpty)(r)&&o&&c&&Object(b.every)(a,(function(e){return Object(b.isEmpty)(e.colors)&&Object(b.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)(Fe,{colors:n,gradients:r,settings:a}));return Object(u.createElement)(h.PanelBody,Object(l.a)({className:f()("block-editor-panel-color-gradient-settings",t),title:p},d),a.map((function(e,t){return Object(u.createElement)(Ne,Object(l.a)({key:t},Re({colors:n,gradients:r,disableCustomColors:o,disableCustomGradients:c},e)))})),i)},He=function(e){var t={};return t.colors=ve("color.palette"),t.gradients=ve("color.gradients"),t.disableCustomColors=!ve("color.custom"),t.disableCustomGradients=!ve("color.customGradient"),Object(u.createElement)(Ve,Re(Re({},t),e))},ze=function(e){return Object(b.every)(Le,(function(t){return e.hasOwnProperty(t)}))?Object(u.createElement)(Ve,e):Object(u.createElement)(He,e)},Ue=n(48);// translators: first %s: The type of color or gradient (e.g. background, overlay...), second %s: the color name or value (e.g. red or #ff0000)
|
7 |
-
function Ge(e){var t=e.tinyBackgroundColor,n=e.tinyTextColor,r=e.backgroundColor,o=e.textColor,c=t.getBrightness()<n.getBrightness()?Object(O.__)("This color combination may be hard for people to read. Try using a darker background color and/or a brighter text color."):Object(O.__)("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(Ue.speak)(Object(O.__)("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 Ke=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=de()(t||n),l=de()(i||r);return 1!==a.getAlpha()||1!==l.getAlpha()||de.a.isReadable(a,l,{level:"AA",size:c||!1!==c&&o>=24?"large":"small"})?null:Object(u.createElement)(Ge,{backgroundColor:t,textColor:i,tinyBackgroundColor:a,tinyTextColor:l})},We=n(168),qe=Object(h.createSlotFill)("InspectorControls"),$e=qe.Fill,Ye=qe.Slot;function Xe(e){var t=e.children;return Object(We.a)()?Object(u.createElement)($e,null,t):null}Xe.Slot=Ye;var Qe=Xe;function Ze(e){return document.getElementById("block-"+e)}function Je(e,t){return t.closest(".block-editor-block-list__block")===e}function et(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 tt(e){return e.ownerDocument.defaultView.getComputedStyle(e)}function nt(e){var t=e.settings,n=e.clientId,r=e.enableContrastChecking,o=void 0===r||r,c=Object(u.useState)(),i=Object(ie.a)(c,2),a=i[0],l=i[1],s=Object(u.useState)(),d=Object(ie.a)(s,2),f=d[0],b=d[1];return Object(u.useEffect)((function(){if(o){var e=Ze(n);if(e){b(tt(e).color);for(var t=e,r=tt(t).backgroundColor;"rgba(0, 0, 0, 0)"===r&&t.parentNode&&t.parentNode.nodeType===t.parentNode.ELEMENT_NODE;)r=tt(t=t.parentNode).backgroundColor;l(r)}}})),Object(u.createElement)(Qe,null,Object(u.createElement)(ze,{title:Object(O.__)("Color settings"),initialOpen:!1,settings:t},o&&Object(u.createElement)(Ke,{backgroundColor:a,textColor:f})))}function rt(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 ot(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rt(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ct=[],it=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)},at=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return Object(b.isObject)(t)&&!!t.link},lt=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return Object(b.isObject)(t)&&!!t.gradients},st=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return t&&!1!==t.text};function ut(e,t,n){var r,o,c,i,a,l;if(!it(t))return e;var u=lt(t),d=n.backgroundColor,b=n.textColor,p=n.gradient,m=n.style,v=pe("background-color",d),g=Oe(p),O=pe("color",b),h=f()(e.className,O,g,(s(l={},v,!(u&&(null==m||null===(r=m.color)||void 0===r?void 0:r.gradient)||!v)),s(l,"has-text-color",b||(null==m||null===(o=m.color)||void 0===o?void 0:o.text)),s(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))),s(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 dt=function(e,t){var n=/var:preset\|color\|(.+)/.exec(t);return n&&n[1]?fe(e,n[1]).color:t};function ft(e){var t,n,r,o,i,a,l=e.name,d=e.attributes,f=ve("color.link"),b=ve("color.palette")||ct,p=ve("color.gradients")||ct,m=Object(u.useRef)(d);if(Object(u.useEffect)((function(){m.current=d}),[d]),!it(l))return null;var v,g=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return t&&!1!==t.background}(l),h=lt(l),j=d.style,k=d.textColor,y=d.backgroundColor,_=d.gradient;if(h&&_)v=he(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=be(b,n),i=t+"Color",a=ot(ot({},m.current.style),{},{color:ot(ot({},null===(r=m.current)||void 0===r||null===(o=r.style)||void 0===o?void 0:o.color),{},s({},t,(null==c?void 0:c.slug)?void 0:n))}),l=(null==c?void 0:c.slug)?c.slug:void 0,u=s({style:_e(a)},i,l);e.setAttributes(u),m.current=ot(ot({},m.current),u)}};return Object(u.createElement)(nt,{enableContrastChecking:"web"===u.Platform.OS&&!_&&!(null==j||null===(t=j.color)||void 0===t?void 0:t.gradient),clientId:e.clientId,settings:[].concat(ce(st(l)?[{label:Object(O.__)("Text Color"),onColorChange:C("text"),colorValue:fe(b,k,null==j||null===(n=j.color)||void 0===n?void 0:n.text).color}]:[]),ce(g||h?[{label:Object(O.__)("Background Color"),onColorChange:g?C("background"):void 0,colorValue:fe(b,y,null==j||null===(r=j.color)||void 0===r?void 0:r.background).color,gradientValue:v,onGradientChange:h?function(t){var n,r=ke(p,t);if(r){var o,c,i,a=ot(ot({},null===(o=m.current)||void 0===o?void 0:o.style),{},{color:ot(ot({},null===(c=m.current)||void 0===c||null===(i=c.style)||void 0===i?void 0:i.color),{},{gradient:void 0})});n={style:_e(a),gradient:r}}else{var l,s,u,d=ot(ot({},null===(l=m.current)||void 0===l?void 0:l.style),{},{color:ot(ot({},null===(s=m.current)||void 0===s||null===(u=s.style)||void 0===u?void 0:u.color),{},{gradient:t})});n={style:_e(d),gradient:void 0}}e.setAttributes(n),m.current=ot(ot({},m.current),n)}:void 0}]:[]),ce(f&&at(l)?[{label:Object(O.__)("Link Color"),onColorChange:function(t){var n,r=be(b,t);e.setAttributes({style:ot(ot({},e.attributes.style),{},{color:ot(ot({},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:dt(b,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 bt=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=ve("color.palette")||ct;if(!it(c))return Object(u.createElement)(e,t);var f={color:s?null===(n=fe(d,s))||void 0===n?void 0:n.color:void 0,backgroundColor:a?null===(r=fe(d,a))||void 0===r?void 0:r.color:void 0},b=t.wrapperProps;return b=ot(ot({},t.wrapperProps),{},{style:ot(ot({},f),null===(o=t.wrapperProps)||void 0===o?void 0:o.style)}),Object(u.createElement)(e,Object(l.a)({},t,{wrapperProps:b}))}}));Object(m.addFilter)("blocks.registerBlockType","core/color/addAttribute",(function(e){return it(e)?(e.attributes.backgroundColor||Object.assign(e.attributes,{backgroundColor:{type:"string"}}),e.attributes.textColor||Object.assign(e.attributes,{textColor:{type:"string"}}),lt(e)&&!e.attributes.gradient&&Object.assign(e.attributes,{gradient:{type:"string"}}),e):e})),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/color/addSaveProps",ut),Object(m.addFilter)("blocks.registerBlockType","core/color/addEditProps",(function(e){if(!it(e))return e;var t=e.getEditWrapperProps;return e.getEditWrapperProps=function(n){var r={};return t&&(r=t(n)),ut(r,e,n)},e})),Object(m.addFilter)("editor.BlockListBlock","core/color/with-color-palette-styles",bt);var pt=n(13);function mt(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!==pt.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(O.__)("Line height"),placeholder:1.5,step:.1,type:"number",value:o,min:0}))}function vt(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 gt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?vt(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ot(e){var t,n=e.attributes.style;if(ht(e))return null;return Object(u.createElement)(mt,{value:null==n||null===(t=n.typography)||void 0===t?void 0:t.lineHeight,onChange:function(t){var r=gt(gt({},n),{},{typography:gt(gt({},null==n?void 0:n.typography),{},{lineHeight:t})});e.setAttributes({style:_e(r)})}})}function ht(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=!ve("typography.customLineHeight");return!Object(c.hasBlockSupport)(t,"lineHeight")||n}var jt=n(153),kt=n.n(jt),yt=function(e,t,n){if(t){var r=Object(b.find)(e,{slug:t});if(r)return r}return{size:n}};function _t(e,t){var n=Object(b.find)(e,{size:t});return n||{size:t}}function Et(e){if(e)return"has-".concat(Object(b.kebabCase)(e),"-font-size")}var Ct=function(e){var t=ve("typography.fontSizes"),n=!ve("typography.customFontSize");return Object(u.createElement)(h.FontSizePicker,Object(l.a)({},e,{fontSizes:t,disableCustomFontSizes:n}))};function wt(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 St(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?wt(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function It(e,t,n){if(!Object(c.hasBlockSupport)(t,"fontSize"))return e;var r=new kt.a(e.className);r.add(Et(n.fontSize));var o=r.value;return e.className=o||void 0,e}function Bt(e){var t,n=e.attributes,r=n.fontSize,o=n.style,c=e.setAttributes,i=xt(e),a=ve("typography.fontSizes");if(i)return null;var l=yt(a,r,null==o||null===(t=o.typography)||void 0===t?void 0:t.fontSize);return Object(u.createElement)(Ct,{value:l.size,onChange:function(e){var t=_t(a,e).slug;c({style:_e(St(St({},o),{},{typography:St(St({},null==o?void 0:o.typography),{},{fontSize:t?void 0:e})})),fontSize:t})}})}function xt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=ve("typography.fontSizes"),r=!!(null==n?void 0:n.length);return!Object(c.hasBlockSupport)(t,"fontSize")||!r}var Pt=Object(p.createHigherOrderComponent)((function(e){return function(t){var n,r=ve("typography.fontSizes"),o=t.name,i=t.attributes,a=i.fontSize,l=i.style,s=t.wrapperProps,d=St({},t);if(Object(c.hasBlockSupport)(o,"fontSize")&&a&&!(null==l||null===(n=l.typography)||void 0===n?void 0:n.fontSize)){var f,b=yt(r,a,null==l||null===(f=l.typography)||void 0===f?void 0:f.fontSize).size;d.wrapperProps=St(St({},s),{},{style:St({fontSize:b},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",It),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)),It(r,e,n)},e})),Object(m.addFilter)("editor.BlockListBlock","core/font-size/with-font-size-inline-styles",Pt);var Tt=["lineHeight","fontSize"];function Nt(e){var t=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=[xt(e),ht(e)];return t.filter(Boolean).length===t.length}(e),n=Dt(e.name);return t||!n?null:Object(u.createElement)(Qe,null,Object(u.createElement)(h.PanelBody,{title:Object(O.__)("Typography")},Object(u.createElement)(Bt,e),Object(u.createElement)(Ot,e)))}var Dt=function(e){return"web"===u.Platform.OS&&Tt.some((function(t){return Object(c.hasBlockSupport)(e,t)}))};function Rt(e){var t=e.units,n=Object(Ee.a)(e,["units"]),r=At(t);return Object(u.createElement)(h.__experimentalUnitControl,Object(l.a)({units:r},n))}function At(e){var t=ve("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 Mt(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 Lt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Mt(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ft(e){var t,n=e.name,r=e.attributes.style,o=e.setAttributes,i=At();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=Lt(Lt({},r),{},{spacing:{padding:e}});o({style:_e(t)})},onChangeShowVisualizer:function(e){var t=Lt(Lt({},r),{},{visualizers:{padding:e}});o({style:_e(t)})},label:Object(O.__)("Padding"),units:i})),native:null})}function Vt(e){var t=e.children,n=Object(Ee.a)(e,["children"]);return ve("spacing.customPadding")?Object(u.createElement)(Qe,n,Object(u.createElement)(h.PanelBody,{title:Object(O.__)("Spacing")},t)):null}function Ht(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 zt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ht(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ht(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ut=[].concat(ce(Tt),["color","spacing"]),Gt=function(e){return Ut.some((function(t){return Object(c.hasBlockSupport)(e,t)}))};function Kt(e){if(Object(b.startsWith)(e,"var:")){var t=e.slice("var:".length).split("|").join("--");return"var(--wp--".concat(t,")")}return e}function Wt(e,t,n){if(!Gt(t))return e;var r=n.style;return e.style=zt(zt({},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=se(n),o=r[0],c=r.slice(1),i=Object(ie.a)(c,1)[0];Object(b.has)(e,i)&&(t[o]=Kt(Object(b.get)(e,i)))})),t}(r)),e.style),e}var qt=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=t.name,r=Object(c.hasBlockSupport)(n,"spacing");return[Object(u.createElement)(Nt,Object(l.a)({key:"typography"},t)),Object(u.createElement)(ft,Object(l.a)({key:"colors"},t)),Object(u.createElement)(e,Object(l.a)({key:"edit"},t)),r&&Object(u.createElement)(Vt,{key:"spacing"},Object(u.createElement)(Ft,t))]}}),"withToolbarControls");function $t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Yt(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 Xt(e,t,n){return t&&Yt(e.prototype,t),n&&Yt(e,n),e}function Qt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Zt(e,t){return(Zt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Jt(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&&Zt(e,t)}function en(e){return(en="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)}function tn(e,t){return!t||"object"!==en(t)&&"function"!=typeof t?Qt(e):t}function nn(e){return(nn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function rn(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}function on(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 cn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?on(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):on(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}Object(m.addFilter)("blocks.registerBlockType","core/style/addAttribute",(function(e){return Gt(e)?(e.attributes.style||Object.assign(e.attributes,{style:{type:"object"}}),e):e})),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/style/addSaveProps",Wt),Object(m.addFilter)("blocks.registerBlockType","core/style/addEditProps",(function(e){if(!Gt(e))return e;var t=e.getEditWrapperProps;return e.getEditWrapperProps=function(n){var r={};return t&&(r=t(n)),Wt(r,e,n)},e})),Object(m.addFilter)("editor.BlockEdit","core/style/with-block-controls",qt);var an=[],ln=function(e){return Object(p.createHigherOrderComponent)((function(t){return function(n){return Object(u.createElement)(t,Object(l.a)({},n,{colors:e}))}}),"withCustomColorPalette")},sn=function(){return Object(p.createHigherOrderComponent)((function(e){return function(t){var n=ve("color.palette")||an;return Object(u.createElement)(e,Object(l.a)({},t,{colors:n}))}}),"withEditorColorPalette")};function un(e,t){var n=Object(b.reduce)(e,(function(e,t){return cn(cn({},e),Object(b.isString)(t)?s({},t,Object(b.kebabCase)(t)):t)}),{});return Object(p.compose)([t,function(e){return function(t){Jt(o,t);var r=rn(o);function o(e){var t;return $t(this,o),(t=r.call(this,e)).setters=t.createSetters(),t.colorUtils={getMostReadableColor:t.getMostReadableColor.bind(Qt(t))},t.state={},t}return Xt(o,[{key:"getMostReadableColor",value:function(e){return function(e,t){return de.a.mostReadable(t,Object(b.map)(e,"color")).toHexString()}(this.props.colors,e)}},{key:"createSetters",value:function(){var e=this;return Object(b.reduce)(n,(function(t,n,r){var o=Object(b.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=be(n.props.colors,r);n.props.setAttributes((s(o={},e,c&&c.slug?c.slug:void 0),s(o,t,c&&c.slug?void 0:r),o))}}},{key:"render",value:function(){return Object(u.createElement)(e,cn(cn(cn(cn({},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(b.reduce)(n,(function(e,n,c){var i=fe(o,r[c],r["custom".concat(Object(b.upperFirst)(c))]),a=t[c];return(null==a?void 0:a.color)===i.color&&a?e[c]=a:e[c]=cn(cn({},i),{},{class:pe(n,i.slug)}),e}),{})}}]),o}(u.Component)}])}function dn(e){return function(){for(var t=ln(e),n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return Object(p.createHigherOrderComponent)(un(r,t),"withCustomColors")}}function fn(){for(var e=sn(),t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return Object(p.createHigherOrderComponent)(un(n,e),"withColors")}var bn=n(65),pn=n.n(bn);function mn(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 vn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?mn(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var gn=function(e){var t=e.colorSettings,n=Object(Ee.a)(e,["colorSettings"]),r=t.map((function(e){var t=e.value,n=e.onChange;return vn(vn({},Object(Ee.a)(e,["value","onChange"])),{},{colorValue:t,onColorChange:n})}));return Object(u.createElement)(ze,Object(l.a)({settings:r,gradients:[],disableCustomGradients:!0},n))},On=function(e,t,n){return"function"==typeof e?e(t):!0===e?n:e};function hn(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)(gn,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(Ee.a)(e,["backgroundColor","textColor"]);return t=On(t,n,c),r=On(r,n,i),Object(u.createElement)(Ke,Object(l.a)({key:"".concat(t,"-").concat(r),backgroundColor:t,textColor:r},o))})):Object(b.map)(n,(function(e){var t=e.value,r=o.backgroundColor,a=o.textColor;return r=On(r||t,n,c),a=On(a||t,n,i),Object(u.createElement)(Ke,Object(l.a)({},o,{key:"".concat(r,"-").concat(a),backgroundColor:r,textColor:a}))}))),"function"==typeof a?a(n):a)}function jn(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 kn(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 kn(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 kn(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 yn(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 _n(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?yn(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function En(e){return e.ownerDocument.defaultView.getComputedStyle(e)}var Cn=[],wn={textColor:Object(O.__)("Text Color"),backgroundColor:Object(O.__)("Background Color")},Sn=function(e){return Object(u.createElement)(Qe,null,Object(u.createElement)(hn,e))};function In(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{panelTitle:Object(O.__)("Color settings")},n=t.panelTitle,r=void 0===n?Object(O.__)("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,g=void 0===m?l:m,h=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],j=Object(z.b)(),k=j.clientId,y=ve("color.palette")||Cn,_=Object(v.useSelect)((function(e){return{attributes:(0,e("core/block-editor").getBlockAttributes)(k)}}),[k]),E=_.attributes,C=Object(v.useDispatch)("core/block-editor"),w=C.updateBlockAttributes,S=Object(u.useCallback)((function(e){return w(k,e)}),[w,k]),I=Object(u.useMemo)((function(){return pn()((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,g={};r?g=s({},t,o):c&&(g=s({},t,c));var O={className:f()(p,(a={},s(a,"has-".concat(Object(b.kebabCase)(r),"-").concat(Object(b.kebabCase)(t)),r),s(a,n||"has-".concat(Object(b.kebabCase)(e)),r||c),a)),style:_n(_n({},g),v)};return Object(b.isFunction)(l)?l(O):u.Children.map(l,(function(e){return Object(u.cloneElement)(e,{className:f()(e.props.className,O.className),style:_n(_n({},O.style),e.props.style||{})})}))}}),{maxSize:e.length})}),[e.length]),B=Object(u.useMemo)((function(){return pn()((function(e,t){return function(n){var r=t.find((function(e){return e.color===n}));S(s({},r?Object(b.camelCase)("custom ".concat(e)):e,void 0)),S(s({},r?e:Object(b.camelCase)("custom ".concat(e)),r?r.slug:n))}}),{maxSize:e.length})}),[S,e.length]),x=Object(u.useState)(),P=Object(ie.a)(x,2),T=P[0],N=P[1],D=Object(u.useState)(),R=Object(ie.a)(D,2),A=R[0],M=R[1];return Object(u.useEffect)((function(){if(c){var e,t=!1,n=!1,r=jn(Object(b.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(En(g.current).color),t){for(var l=p.current,s=En(l).backgroundColor;"rgba(0, 0, 0, 0)"===s&&l.parentNode&&l.parentNode.nodeType===l.parentNode.ELEMENT_NODE;)s=En(l=l.parentNode).backgroundColor;N(s)}}}),[e.reduce((function(e,t){return"".concat(e," | ").concat(E[t.name]," | ").concat(E[Object(b.camelCase)("custom ".concat(t.name))])}),"")].concat(ce(h))),Object(u.useMemo)((function(){var t={},n=e.reduce((function(e,n){"string"==typeof n&&(n={name:n});var r=_n(_n({},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||wn[o]||Object(b.startCase)(o):l,u=r.componentName,d=void 0===u?Object(b.startCase)(o).replace(/\s/g,""):u,f=r.color,p=void 0===f?n.color:f,m=r.colors,v=void 0===m?y:m,g=E[Object(b.camelCase)("custom ".concat(o))],O=g?void 0:v.find((function(e){return e.slug===p}));return e[d]=I(o,i,a,p,O&&O.color,g),e[d].displayName=d,e[d].color=g||O&&O.color,e[d].slug=p,e[d].setColor=B(o,v),t[d]={value:O?O.color:E[Object(b.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 _n(_n({},n),{},{ColorPanel:Object(u.createElement)(hn,a),InspectorControlsColorPanel:Object(u.createElement)(Sn,a)})}),[E,S,A,T].concat(ce(h)))}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){s(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}function Pn(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var Tn=[],Nn=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=Object(b.reduce)(t,(function(e,t){return e[t]="custom".concat(Object(b.upperFirst)(t)),e}),{});return Object(p.createHigherOrderComponent)(Object(p.compose)([Object(p.createHigherOrderComponent)((function(e){return function(t){var n=ve("typography.fontSizes")||Tn;return Object(u.createElement)(e,Object(l.a)({},t,{fontSizes:n}))}}),"withFontSizes"),function(e){return function(t){Jt(o,t);var n=Pn(o);function o(e){var t;return $t(this,o),(t=n.call(this,e)).setters=t.createSetters(),t.state={},t}return Xt(o,[{key:"createSetters",value:function(){var e=this;return Object(b.reduce)(r,(function(t,n,r){var o=Object(b.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(b.find)(n.props.fontSizes,{size:Number(r)});n.props.setAttributes((s(o={},e,c&&c.slug?c.slug:void 0),s(o,t,c&&c.slug?void 0:r),o))}}},{key:"render",value:function(){return Object(u.createElement)(e,xn(xn(xn({},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(b.some)(r,c))return null;var i=Object(b.reduce)(Object(b.pickBy)(r,c),(function(e,t,r){var c=n[r],i=yt(o,c,n[t]);return e[r]=xn(xn({},i),{},{class:Et(c)}),e}),{});return xn(xn({},t),i)}}]),o}(u.Component)}]),"withFontSizes")},Dn=n(287),Rn=n(288),An=n(289);function Mn(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?Mn(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Fn=[{icon:Dn.a,title:Object(O.__)("Align text left"),align:"left"},{icon:Rn.a,title:Object(O.__)("Align text center"),align:"center"},{icon:An.a,title:Object(O.__)("Align text right"),align:"right"}],Vn={position:"bottom right",isAlternate:!0};var Hn=function(e){var t=e.value,n=e.onChange,r=e.alignmentControls,o=void 0===r?Fn:r,c=e.label,i=void 0===c?Object(O.__)("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 f=Object(b.find)(o,(function(e){return e.align===t}));return Object(u.createElement)(h.ToolbarGroup,{isCollapsed:l,icon:f?f.icon:s?An.a:Dn.a,label:i,popoverProps:Vn,controls:o.map((function(e){var n=e.align,r=t===n;return Ln(Ln({},e),{},{isActive:r,role:l?"menuitemradio":void 0,onClick:d(n)})}))})},zn=function(e){return e.name||""},Un=function(e){return e.title},Gn=function(e){return e.keywords||[]},Kn=function(e){return e.category},Wn=function(){return null};function qn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e=(e=(e=Object(b.deburr)(e)).replace(/^\//,"")).toLowerCase()}var $n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return Object(b.words)(qn(e))},Yn=function(e,t){return Object(b.differenceWith)(e,$n(t),(function(e,t){return t.includes(e)}))},Xn=function(e,t,n,r){return 0===$n(r).length?e:Qn(e,r,{getCategory:function(e){var n;return null===(n=Object(b.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))}})},Qn=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=$n(t);if(0===r.length)return e;var o=e.map((function(e){return[e,Zn(e,t,n)]})).filter((function(e){return Object(ie.a)(e,2)[1]>0}));return o.sort((function(e,t){var n=Object(ie.a)(e,2)[1];return Object(ie.a)(t,2)[1]-n})),o.map((function(e){return Object(ie.a)(e,1)[0]}))};function Zn(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.getName,o=void 0===r?zn:r,c=n.getTitle,i=void 0===c?Un:c,a=n.getKeywords,l=void 0===a?Gn:a,s=n.getCategory,u=void 0===s?Kn:s,d=n.getCollection,f=void 0===d?Wn:d,p=o(e),m=i(e),v=l(e),g=u(e),O=f(e),h=qn(t),j=qn(m),k=0;if(h===j)k+=30;else if(j.startsWith(h))k+=20;else{var y=[p,m].concat(ce(v),[g,O]).join(" "),_=Object(b.words)(h),E=Yn(_,y);0===E.length&&(k+=10)}return 0!==k&&p.startsWith("core/")&&k++,k}var Jn=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)}]},er=n(156);function tr(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:er.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:f()("block-editor-block-icon",c,{"has-colors":o})},i)}var nr={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=Jn(n,b.noop),c=Object(ie.a)(o,3),i=c[0],a=c[1],l=c[2],s=Object(u.useMemo)((function(){return(e.trim()?Xn(i,a,l,e):Object(b.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)(tr,{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))}}},rr=[];var or=function(e){var t=Object(z.b)().name,n=e.completers,r=void 0===n?rr:n;return r=Object(u.useMemo)((function(){var e=r;return t===Object(c.getDefaultBlockName)()&&(e=e.concat([nr])),Object(m.hasFilter)("editor.Autocomplete.completers")&&(e===r&&(e=e.map(b.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 cr=function(e){var t=e.label,n=void 0===t?Object(O.__)("Change matrix alignment"):t,r=e.onChange,o=void 0===r?b.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!==pt.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 ir(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(b.truncate)(l,{length:15})):a}var ar=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(O.__)("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(O.__)("Document")),!i&&Object(O.__)("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)(ir,{clientId:e})))})),!!o&&Object(u.createElement)("li",{className:"block-editor-block-breadcrumb__current","aria-current":"true"},Object(u.createElement)(ir,{clientId:o})))};function lr(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 sr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?lr(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):lr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ur=Object(u.createContext)({});function dr(e){var t=e.value,n=e.children,r=Object(u.useContext)(ur),o=Object(u.useMemo)((function(){return sr(sr({},r),t)}),[r,t]);return Object(u.createElement)(ur.Provider,{value:o,children:n})}var fr=ur,br=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"}))},pr=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)(br,null)))},mr=function(e){var t,n,r,o=e.children,c=Object(Ee.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(O.__)("Open Colors Selector"),onClick:t,onKeyDown:function(e){o||e.keyCode!==pt.DOWN||(e.preventDefault(),e.stopPropagation(),t())},icon:Object(u.createElement)(r,null,Object(u.createElement)(n,null,Object(u.createElement)(pr,null)))}))}),renderContent:function(){return o}})},vr={},gr=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)(fr),a=Object(u.useMemo)((function(){return o&&o.usesContext?Object(b.pick)(i,o.usesContext):vr}),[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=f()(d,n.className);return Object(u.createElement)(s,Object(l.a)({},e,{context:a,className:p}))}));function Or(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)(gr,e))}var hr=Object(h.createSlotFill)("BlockFormatControls"),jr=hr.Fill,kr=hr.Slot;var yr=function(e){return Object(z.b)().isSelected?Object(u.createElement)(jr,null,(function(t){var n=Object(b.isEmpty)(t)?null:t;return Object(u.createElement)(h.__experimentalToolbarContext.Provider,{value:n},e.children)})):null};yr.Slot=function(e){var t=Object(u.useContext)(h.__experimentalToolbarContext);return Object(u.createElement)(kr,Object(l.a)({},e,{fillProps:t}))};var _r=yr,Er=n(12),Cr=n.n(Er);function wr(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 Sr(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var c=e.apply(t,n);function i(e){wr(c,r,o,i,a,"next",e)}function a(e){wr(c,r,o,i,a,"throw",e)}i(void 0)}))}}var Ir=n(216),Br=n(114),xr=n(23),Pr=function(e){return e+1},Tr=function(e){return{top:e.offsetTop,left:e.offsetLeft}};var Nr=function(e,t,n,r,o){var c=Object(p.useReducedMotion)()||!r,i=Object(u.useReducer)(Pr,0),a=Object(ie.a)(i,2),l=a[0],s=a[1],d=Object(u.useReducer)(Pr,0),f=Object(ie.a)(d,2),b=f[0],m=f[1],v=Object(u.useState)({x:0,y:0}),g=Object(ie.a)(v,2),O=g[0],h=g[1],j=Object(u.useMemo)((function(){return e.current?Tr(e.current):null}),[o]),k=Object(u.useMemo)((function(){if(!n||!e.current)return function(){};var t=Object(xr.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=Tr(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(Br.useSpring)({from:{x:O.x,y:O.y},to:{x:0,y:0},reset:l!==b,config:{mass:5,tension:2e3,friction:200},immediate:c,onFrame:y})},Dr=Object(Br.animated)(h.__experimentalTreeGridRow);function Rr(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(Ee.a)(e,["isSelected","position","level","rowCount","children","className","path"]),d=Object(u.useRef)(null),b=a.join("_"),p=Nr(d,t,!1,!0,b);return Object(u.createElement)(Dr,Object(l.a)({ref:d,style:p,className:f()("block-editor-block-navigation-leaf",i),level:r,positionInSet:n,setSize:o},s),c)}var Ar=n(213),Mr=n(214),Lr=n(215),Fr=n(189);function Vr(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(O.__)("Blocks cannot be moved up as they are already at the top");if(o>0&&r)return Object(O.__)("Blocks cannot be moved down as they are already at the bottom");if(o<0&&!n)return Object(O.sprintf)(// translators: 1: Number of selected blocks, 2: Position of selected blocks
|
8 |
Object(O._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(O.sprintf)(// translators: 1: Number of selected blocks, 2: Position of selected blocks
|
9 |
Object(O._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(O.sprintf)(// translators: %s: Type of block (i.e. Text, Image etc)
|
10 |
Object(O.__)("Block %s is the only block, and cannot be moved"),t);if(c>0&&!o){var u=s("down");if("down"===u)return Object(O.sprintf)(// translators: 1: Type of block (i.e. Text, Image etc), 2: Position of selected block, 3: New position
|
@@ -19,17 +19,17 @@ Object(O.__)("Move %1$s block from position %2$d left to position %3$d"),t,l,l-1
|
|
19 |
Object(O.__)("Move %1$s block from position %2$d right to position %3$d"),t,l,l-1)}if(c<0&&r){var b=s("up");if("up"===b)return Object(O.sprintf)(// translators: 1: Type of block (i.e. Text, Image etc)
|
20 |
Object(O.__)("Block %1$s is at the beginning of the content and can’t be moved up"),t);if("left"===b)return Object(O.sprintf)(// translators: 1: Type of block (i.e. Text, Image etc)
|
21 |
Object(O.__)("Block %1$s is at the beginning of the content and can’t be moved left"),t);if("right"===b)return Object(O.sprintf)(// translators: 1: Type of block (i.e. Text, Image etc)
|
22 |
-
Object(O.__)("Block %1$s is at the beginning of the content and can’t be moved right"),t)}}var Hr=function(e,t,n){return"up"===e?"horizontal"===t?n?Ar.a:Mr.a:Lr.a:"down"===e?"horizontal"===t?n?Mr.a:Ar.a:Fr.a:null},zr=function(e,t,n){return"up"===e?"horizontal"===t?n?Object(O.__)("Move right"):Object(O.__)("Move left"):Object(O.__)("Move up"):"down"===e?"horizontal"===t?n?Object(O.__)("Move left"):Object(O.__)("Move right"):Object(O.__)("Move down"):null},Ur=Object(u.forwardRef)((function(e,t){var n=e.clientIds,r=e.direction,o=e.orientation,i=Object(Ee.a)(e,["clientIds","direction","orientation"]),a=Object(p.useInstanceId)(Ur),s=Object(b.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,f=Object(b.castArray)(n),p=Object(b.first)(f),m=a(p),v=i(p,m),g=i(Object(b.last)(f),m),O=l(m),h=s(p),j=0===v,k=g===O.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,g=d.isDisabled,O=d.rootClientId,j=d.isFirst,k=d.isLast,y=d.firstIndex,_=d.isRTL,E=d.orientation,C=void 0===E?"vertical":E,w=Object(v.useDispatch)("core/block-editor"),S=w.moveBlocksDown,I=w.moveBlocksUp,B="up"===r?I:S,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:f()("block-editor-block-mover-button","is-".concat(r,"-button")),icon:Hr(r,C,_),label:zr(r,C,_),"aria-describedby":x},i,{onClick:g?null:function(e){B(n,O),i.onClick&&i.onClick(e)},"aria-disabled":g})),Object(u.createElement)("span",{id:x,className:"block-editor-block-mover-button__description"},Vr(s,m&&m.title,y,j,k,"up"===r?-1:1,C,_)))})),Gr=Object(u.forwardRef)((function(e,t){return Object(u.createElement)(Ur,Object(l.a)({direction:"up",ref:t},e))})),
|
23 |
// translators: Button to fix block content
|
24 |
title:Object(O._x)("Resolve","imperative verb"),onClick:b},a&&{title:Object(O.__)("Convert to HTML"),onClick:t},{title:Object(O.__)("Convert to Classic Block"),onClick:r}].filter(Boolean)}),[b,t,r]);return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(Xr,{actions:[Object(u.createElement)(h.Button,{key:"recover",onClick:o,isPrimary:!0},Object(O.__)("Attempt Block Recovery"))],secondaryActions:m},Object(O.__)("This block contains unexpected or invalid content.")),d&&Object(u.createElement)(h.Modal,{title:// translators: Dialog title to fix block content
|
25 |
-
Object(O.__)("Resolve Block"),onRequestClose:p,className:"block-editor-block-compare"},Object(u.createElement)(Jr,{block:i,onKeep:t,onConvert:n,convertor:eo,convertButtonText:Object(O.__)("Convert to Blocks")})))})),no=Object(u.createElement)(Xr,{className:"block-editor-block-list__block-crash-warning"},Object(O.__)("This block has encountered an error and cannot be previewed.")),ro=function(){return no};function oo(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var co=function(e){Jt(n,e);var t=oo(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).state={hasError:!1},e}return Xt(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),io=n(97),ao=n.n(io);var lo=function(e){var t=e.clientId,n=Object(u.useState)(""),r=Object(ie.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)(ao.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)}})},so=n(31),uo=n.n(so);function fo(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 bo(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 po(e,t){Array.from(e.querySelectorAll(".rich-text")).forEach((function(e){t?e.setAttribute("contenteditable",!0):e.removeAttribute("contenteditable")}))}var mo=n(157),vo=[Object(u.createInterpolateElement)(Object(O.__)("While writing, you can press <kbd>/</kbd> to quickly insert new blocks."),{kbd:Object(u.createElement)("kbd",null)}),Object(u.createInterpolateElement)(Object(O.__)("Indent a list by pressing <kbd>space</kbd> at the beginning of a line."),{kbd:Object(u.createElement)("kbd",null)}),Object(u.createInterpolateElement)(Object(O.__)("Outdent a list by pressing <kbd>backspace</kbd> at the beginning of a line."),{kbd:Object(u.createElement)("kbd",null)}),Object(O.__)("Drag files into the editor to automatically insert media blocks."),Object(O.__)("Change a block's type by pressing the block icon on the toolbar.")];var go=function(){var e=Object(u.useState)(Math.floor(Math.random()*vo.length)),t=Object(ie.a)(e,1)[0];return Object(u.createElement)(h.Tip,null,vo[t])},Oo=n(127),ho=n(144),jo=n(290);var ko=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:f()("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:Oo.a,label:Object(O.__)("Reset search"),onClick:function(){r(""),a.current.focus()}}),!o&&Object(u.createElement)(ho.a,{icon:jo.a})))};var yo=function(e){var t=e.blockType;return Object(u.createElement)("div",{className:"block-editor-block-card"},Object(u.createElement)(tr,{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)))},_o={insertUsage:{}},Eo={alignWide:!1,colors:[{name:Object(O.__)("Black"),slug:"black",color:"#000000"},{name:Object(O.__)("Cyan bluish gray"),slug:"cyan-bluish-gray",color:"#abb8c3"},{name:Object(O.__)("White"),slug:"white",color:"#ffffff"},{name:Object(O.__)("Pale pink"),slug:"pale-pink",color:"#f78da7"},{name:Object(O.__)("Vivid red"),slug:"vivid-red",color:"#cf2e2e"},{name:Object(O.__)("Luminous vivid orange"),slug:"luminous-vivid-orange",color:"#ff6900"},{name:Object(O.__)("Luminous vivid amber"),slug:"luminous-vivid-amber",color:"#fcb900"},{name:Object(O.__)("Light green cyan"),slug:"light-green-cyan",color:"#7bdcb5"},{name:Object(O.__)("Vivid green cyan"),slug:"vivid-green-cyan",color:"#00d084"},{name:Object(O.__)("Pale cyan blue"),slug:"pale-cyan-blue",color:"#8ed1fc"},{name:Object(O.__)("Vivid cyan blue"),slug:"vivid-cyan-blue",color:"#0693e3"},{name:Object(O.__)("Vivid purple"),slug:"vivid-purple",color:"#9b51e0"}],fontSizes:[{name:Object(O._x)("Small","font size name"),size:13,slug:"small"},{name:Object(O._x)("Normal","font size name"),size:16,slug:"normal"},{name:Object(O._x)("Medium","font size name"),size:20,slug:"medium"},{name:Object(O._x)("Large","font size name"),size:36,slug:"large"},{name:Object(O._x)("Huge","font size name"),size:42,slug:"huge"}],imageSizes:[{slug:"thumbnail",name:Object(O.__)("Thumbnail")},{slug:"medium",name:Object(O.__)("Medium")},{slug:"large",name:Object(O.__)("Large")},{slug:"full",name:Object(O.__)("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(O.__)("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(O.__)("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(O.__)("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(O.__)("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(O.__)("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(O.__)("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(O.__)("Blush light purple"),gradient:"linear-gradient(135deg,rgb(255,206,236) 0%,rgb(152,150,240) 100%)",slug:"blush-light-purple"},{name:Object(O.__)("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(O.__)("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(O.__)("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(O.__)("Electric grass"),gradient:"linear-gradient(135deg,rgb(202,248,128) 0%,rgb(113,206,126) 100%)",slug:"electric-grass"},{name:Object(O.__)("Midnight"),gradient:"linear-gradient(135deg,rgb(2,3,129) 0%,rgb(40,116,252) 100%)",slug:"midnight"}]};function Co(e,t,n){return[].concat(ce(e.slice(0,n)),ce(Object(b.castArray)(t)),ce(e.slice(n)))}function wo(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,o=ce(e);return o.splice(t,r),Co(o,e.slice(t,t+r),n)}function So(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 Io(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?So(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):So(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Bo(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=s({},t,[]);return e.forEach((function(e){var r=e.clientId,o=e.innerBlocks;n[t].push(r),Object.assign(n,Bo(o,r))})),n}function xo(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return e.reduce((function(e,n){return Object.assign(e,s({},n.clientId,t),xo(n.innerBlocks,n.clientId))}),{})}function Po(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:b.identity,n={},r=ce(e);r.length;){var o=r.shift(),c=o.innerBlocks,i=Object(Ee.a)(o,["innerBlocks"]);r.push.apply(r,ce(c)),n[i.clientId]=t(i)}return n}function To(e){return Po(e,(function(e){return Object(b.omit)(e,"attributes")}))}function No(e){return Po(e,(function(e){return e.attributes}))}function Do(e,t){return e===t?Io({},e):t}function Ro(e,t){return"UPDATE_BLOCK_ATTRIBUTES"===e.type&&void 0!==t&&"UPDATE_BLOCK_ATTRIBUTES"===t.type&&Object(b.isEqual)(e.clientIds,t.clientIds)&&(n=e.attributes,r=t.attributes,Object(b.isEqual)(Object(b.keys)(n),Object(b.keys)(r)));var n,r}var Ao=function(e){return e.reduce((function(e,t){return e[t]={},e}),{})};var Mo=Object(b.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=Io({},t)).attributes=Object(b.mapValues)(t.attributes,(function(e,n){return"core/block"===t.byClientId[n].name&&e.ref===r?Io(Io({},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(b.mapValues)(Po(n.blocks),(function(){return{}}));break;case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":var c=Object(b.keys)(Po(n.blocks));n.rootClientId&&!t.controlledInnerBlocks[n.rootClientId]&&c.push(n.rootClientId),r.cache=Io(Io({},r.cache),Ao(o(c)));break;case"UPDATE_BLOCK":r.cache=Io(Io({},r.cache),Ao(o([n.clientId])));break;case"UPDATE_BLOCK_ATTRIBUTES":r.cache=Io(Io({},r.cache),Ao(o(n.clientIds)));break;case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":var i=Ao(o(n.replacedClientIds));r.cache=Io(Io(Io({},Object(b.omit)(r.cache,n.replacedClientIds)),Object(b.omit)(i,n.replacedClientIds)),Ao(Object(b.keys)(Po(n.blocks))));break;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":r.cache=Io(Io({},Object(b.omit)(r.cache,n.removedClientIds)),Ao(Object(b.difference)(o(n.clientIds),n.clientIds)));break;case"MOVE_BLOCKS_TO_POSITION":var a=ce(n.clientIds);n.fromRootClientId&&a.push(n.fromRootClientId),n.toRootClientId&&a.push(n.toRootClientId),r.cache=Io(Io({},r.cache),Ao(o(a)));break;case"MOVE_BLOCKS_UP":case"MOVE_BLOCKS_DOWN":var l=[];n.rootClientId&&l.push(n.rootClientId),r.cache=Io(Io({},r.cache),Ao(o(l)));break;case"SAVE_REUSABLE_BLOCK_SUCCESS":var s=Object(b.keys)(Object(b.omitBy)(r.attributes,(function(e,t){return"core/block"!==r.byClientId[t].name||e.ref!==n.updatedId})));r.cache=Io(Io({},r.cache),Ao(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=ce(r)),(c=r).push.apply(c,ce(t.order[r[o]])))}return r};if(t)switch(n.type){case"REMOVE_BLOCKS":n=Io(Io({},n),{},{type:"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN",removedClientIds:r(n.clientIds)});break;case"REPLACE_BLOCKS":n=Io(Io({},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=ce(n.blocks);o.length;){var c=o.shift(),i=c.innerBlocks,a=Object(Ee.a)(c,["innerBlocks"]);o.push.apply(o,ce(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,Io(Io({},n),{},{type:"INSERT_BLOCKS",index:0}))).order=Io(Io({},s.order),Object(b.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(b.reduce)(t[n],(function(n,o){return r[o]?n:[].concat(ce(n),[o],ce(e(t,o)))}),[])}(t.order,"",t.controlledInnerBlocks),o=Object.keys(Object(b.pickBy)(t.controlledInnerBlocks));return Io(Io({},t),{},{byClientId:Io(Io({},Object(b.omit)(t.byClientId,r)),To(n.blocks)),attributes:Io(Io({},Object(b.omit)(t.attributes,r)),No(n.blocks)),order:Io(Io({},Object(b.omit)(t.order,r)),Object(b.omit)(Bo(n.blocks),o)),parents:Io(Io({},Object(b.omit)(t.parents,r)),xo(n.blocks)),cache:Io(Io({},Object(b.omit)(t.cache,r)),Object(b.omit)(Object(b.mapValues)(Po(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:Io(Io({},c),{},{isPersistentChange:l})}return c=Io(Io({},c),{},{isPersistentChange:i?!n:!Ro(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 To(t.blocks);case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":return Io(Io({},e),To(t.blocks));case"UPDATE_BLOCK":if(!e[t.clientId])return e;var n=Object(b.omit)(t.updates,"attributes");return Object(b.isEmpty)(n)?e:Io(Io({},e),{},s({},t.clientId,Io(Io({},e[t.clientId]),n)));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return t.blocks?Io(Io({},Object(b.omit)(e,t.replacedClientIds)),To(t.blocks)):e;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(b.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 No(t.blocks);case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":return Io(Io({},e),No(t.blocks));case"UPDATE_BLOCK":return e[t.clientId]&&t.updates.attributes?Io(Io({},e),{},s({},t.clientId,Io(Io({},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 Io(Io({},n),{},s({},r,Object(b.reduce)(t.attributes,(function(t,n,o){return n!==t[o]&&((t=Do(e[r],t))[o]=n),t}),e[r])))}),{});return t.clientIds.every((function(t){return n[t]===e[t]}))?e:Io(Io({},e),n);case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return t.blocks?Io(Io({},Object(b.omit)(e,t.replacedClientIds)),No(t.blocks)):e;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(b.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 Bo(t.blocks);case"RECEIVE_BLOCKS":return Io(Io({},e),Object(b.omit)(Bo(t.blocks),""));case"INSERT_BLOCKS":var n=t.rootClientId,r=void 0===n?"":n,o=e[r]||[],c=Bo(t.blocks,r),i=t.index,a=void 0===i?o.length:i;return Io(Io(Io({},e),c),{},s({},r,Co(o,c[r],a)));case"MOVE_BLOCKS_TO_POSITION":var l,u=t.fromRootClientId,d=void 0===u?"":u,f=t.toRootClientId,p=void 0===f?"":f,m=t.clientIds,v=t.index,g=void 0===v?e[p].length:v;if(d===p){var O=e[p],h=O.indexOf(m[0]);return Io(Io({},e),{},s({},p,wo(e[p],h,g,m.length)))}return Io(Io({},e),{},(s(l={},d,b.without.apply(void 0,[e[d]].concat(ce(m)))),s(l,p,Co(e[p],m,g)),l));case"MOVE_BLOCKS_UP":var j=t.clientIds,k=t.rootClientId,y=void 0===k?"":k,_=Object(b.first)(j),E=e[y];if(!E.length||_===Object(b.first)(E))return e;var C=E.indexOf(_);return Io(Io({},e),{},s({},y,wo(E,C,C-1,j.length)));case"MOVE_BLOCKS_DOWN":var w=t.clientIds,S=t.rootClientId,I=void 0===S?"":S,B=Object(b.first)(w),x=Object(b.last)(w),P=e[I];if(!P.length||x===Object(b.last)(P))return e;var T=P.indexOf(B);return Io(Io({},e),{},s({},I,wo(P,T,T+1,w.length)));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":var N=t.clientIds;if(!t.blocks)return e;var D=Bo(t.blocks);return Object(b.flow)([function(e){return Object(b.omit)(e,t.replacedClientIds)},function(e){return Io(Io({},e),Object(b.omit)(D,""))},function(e){return Object(b.mapValues)(e,(function(e){return Object(b.reduce)(e,(function(e,t){return t===N[0]?[].concat(ce(e),ce(D[""])):(-1===N.indexOf(t)&&e.push(t),e)}),[])}))}])(e);case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(b.flow)([function(e){return Object(b.omit)(e,t.removedClientIds)},function(e){return Object(b.mapValues)(e,(function(e){return b.without.apply(void 0,[e].concat(ce(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 xo(t.blocks);case"RECEIVE_BLOCKS":return Io(Io({},e),xo(t.blocks));case"INSERT_BLOCKS":return Io(Io({},e),xo(t.blocks,t.rootClientId||""));case"MOVE_BLOCKS_TO_POSITION":return Io(Io({},e),t.clientIds.reduce((function(e,n){return e[n]=t.toRootClientId||"",e}),{}));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Io(Io({},Object(b.omit)(e,t.replacedClientIds)),xo(t.blocks,e[t.clientIds[0]]));case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(b.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?Io(Io({},e),{},s({},r,o)):e}});function Lo(){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}var Fo=Object(v.combineReducers)({blocks:Mo,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 Lo(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 Lo(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 Io(Io({},e),{},s({},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(b.omit)(e,t.clientIds);case"UPDATE_BLOCK_LIST_SETTINGS":var n=t.clientId;return t.settings?Object(b.isEqual)(e[n],t.settings)?e:Io(Io({},e),{},s({},n,t.settings)):e.hasOwnProperty(n)?Object(b.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"SHOW_INSERTION_POINT":var n=t.rootClientId,r=t.index;return{rootClientId:n,index:r};case"HIDE_INSERTION_POINT":return null}return e},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 Io(Io({},e),{},{isValid:t.isValid})}return e},settings:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Eo,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"UPDATE_SETTINGS":return Io(Io({},e),t.settings)}return e},preferences:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:_o,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),Io(Io({},e),{},{insertUsage:Io(Io({},e.insertUsage),{},s({},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 s({},t.clientId,t.updates.attributes);case"UPDATE_BLOCK_ATTRIBUTES":return t.clientIds.reduce((function(e,n){return Io(Io({},e),{},s({},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}}),Vo=n(146),Ho=n.n(Vo),zo=n(263),Uo=n.n(zo);function Go(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 Ko(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 Ko(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 Ko(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 Wo(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 qo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Wo(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Wo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var $o=Cr.a.mark(lc),Yo=Cr.a.mark(mc),Xo=Cr.a.mark(vc),Qo=Cr.a.mark(_c),Zo=Cr.a.mark(Ic),Jo=Cr.a.mark(Bc),ec=Cr.a.mark(Pc),tc=Cr.a.mark(Mc),nc=Cr.a.mark(ti),rc=Cr.a.mark(ni),oc=Cr.a.mark(ri),cc=Cr.a.mark(oi),ic=Cr.a.mark(ci),ac=Cr.a.mark(ai);function lc(){return Cr.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,$c();case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}}),$o)}function sc(e){return{type:"RESET_BLOCKS",blocks:e}}function uc(e,t){return{type:"RESET_SELECTION",selectionStart:e,selectionEnd:t}}function dc(e){return{type:"RECEIVE_BLOCKS",blocks:e}}function fc(e,t){return{type:"UPDATE_BLOCK_ATTRIBUTES",clientIds:Object(b.castArray)(e),attributes:t}}function bc(e,t){return{type:"UPDATE_BLOCK",clientId:e,updates:t}}function pc(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return{type:"SELECT_BLOCK",initialPosition:t,clientId:e}}function mc(e){var t;return Cr.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,pc(t,-1);case 6:return n.abrupt("return",[t]);case 7:case"end":return n.stop()}}),Yo)}function vc(e){var t;return Cr.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,pc(t);case 6:return n.abrupt("return",[t]);case 7:case"end":return n.stop()}}),Xo)}function gc(){return{type:"START_MULTI_SELECT"}}function Oc(){return{type:"STOP_MULTI_SELECT"}}function hc(e,t){return{type:"MULTI_SELECT",start:e,end:t}}function jc(){return{type:"CLEAR_SELECTED_BLOCK"}}function kc(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return{type:"TOGGLE_SELECTION",isSelectionEnabled:e}}function yc(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 qo(qo({},e),{},{attributes:qo(qo({},a),{},{className:"".concat(r||""," is-style-").concat(l).trim()})})}))}function _c(e,t,n,r,o){var c,i,a;return Cr.a.wrap((function(l){for(;;)switch(l.prev=l.next){case 0:return e=Object(b.castArray)(e),l.t0=yc,l.t1=Object(b.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(b.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(lc(),"t3",24);case 24:case"end":return l.stop()}}),Qo)}function Ec(e,t){return _c(e,t)}function Cc(e){return function(t,n){return{clientIds:Object(b.castArray)(t),type:e,rootClientId:n}}}var wc=Cc("MOVE_BLOCKS_DOWN"),Sc=Cc("MOVE_BLOCKS_UP");function Ic(e){var t,n,r,o,c,i=arguments;return Cr.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()}}),Zo)}function Bc(e){var t,n,r,o=arguments;return Cr.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,Ic([e],t,n,r);case 5:case"end":return c.stop()}}),Jo)}function xc(e,t,n){var r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];return Pc([e],t,n,r)}function Pc(e,t,n){var r,o,c,i,a,l,s=arguments;return Cr.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=yc,u.t1=Object(b.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=Go(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()}}),ec,null,[[10,22,25,28]])}function Tc(e,t){return{type:"SHOW_INSERTION_POINT",rootClientId:e,index:t}}function Nc(){return{type:"HIDE_INSERTION_POINT"}}function Dc(e){return{type:"SET_TEMPLATE_VALIDITY",isValid:e}}function Rc(){return{type:"SYNCHRONIZE_TEMPLATE"}}function Ac(e,t){return{type:"MERGE_BLOCKS",blocks:[e,t]}}function Mc(e){var t,n,r,o,c=arguments;return Cr.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(b.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,mc(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(lc(),"t0",24);case 24:return o=i.t0,i.abrupt("return",[r||o]);case 26:case"end":return i.stop()}}),tc)}function Lc(e,t){return Mc([e],t)}function Fc(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 Vc(e){return{type:"TOGGLE_BLOCK_MODE",clientId:e}}function Hc(){return{type:"START_TYPING"}}function zc(){return{type:"STOP_TYPING"}}function Uc(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return{type:"START_DRAGGING_BLOCKS",clientIds:e}}function Gc(){return{type:"STOP_DRAGGING_BLOCKS"}}function Kc(){return{type:"ENTER_FORMATTED_TEXT"}}function Wc(){return{type:"EXIT_FORMATTED_TEXT"}}function qc(e,t,n,r){return{type:"SELECTION_CHANGE",clientId:e,attributeKey:t,startOffset:n,endOffset:r}}function $c(e,t,n){var r=Object(c.getDefaultBlockName)();if(r)return xc(Object(c.createBlock)(r,e),n,t)}function Yc(e,t){return{type:"UPDATE_BLOCK_LIST_SETTINGS",clientId:e,settings:t}}function Xc(e){return{type:"UPDATE_SETTINGS",settings:e}}function Qc(e,t){return{type:"SAVE_REUSABLE_BLOCK_SUCCESS",id:e,updatedId:t}}function Zc(){return{type:"MARK_LAST_CHANGE_AS_PERSISTENT"}}function Jc(){return{type:"MARK_NEXT_CHANGE_AS_NOT_PERSISTENT"}}function ei(){return{type:"MARK_AUTOMATIC_CHANGE"}}function ti(){var e,t=arguments;return Cr.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(Ue.speak)(Object(O.__)("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(Ue.speak)(Object(O.__)("You are currently in edit mode. To return to the navigation mode, press Escape."));case 4:case"end":return n.stop()}}),nc)}function ni(){var e,t=arguments;return Cr.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(Ue.speak)(Object(O.__)("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()}}),rc)}function ri(e){var t,n,r,o,i,a,l=arguments;return Cr.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(b.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(b.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(b.last)(Object(b.castArray)(e)),r);case 16:return i=s.sent,a=n.map((function(e){return Object(c.cloneBlock)(e)})),s.next=20,Pc(a,i+1,r,t);case 20:if(!(a.length>1&&t)){s.next=23;break}return s.next=23,hc(Object(b.first)(a).clientId,Object(b.last)(a).clientId);case 23:return s.abrupt("return",a.map((function(e){return e.clientId})));case 24:case"end":return s.stop()}}),oc)}function oi(e){var t,n;return Cr.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,$c({},t,n);case 15:return r.abrupt("return",r.sent);case 16:case"end":return r.stop()}}),cc)}function ci(e){var t,n;return Cr.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,$c({},t,n+1);case 15:return r.abrupt("return",r.sent);case 16:case"end":return r.stop()}}),ic)}function ii(e,t){return{type:"TOGGLE_BLOCK_HIGHLIGHT",clientId:e,isHighlighted:t}}function ai(e){return Cr.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ii(e,!0);case 2:return t.next=4,{type:"SLEEP",duration:150};case 4:return t.next=6,ii(e,!1);case 6:case"end":return t.stop()}}),ac)}function li(e,t){return{type:"SET_HAS_CONTROLLED_INNER_BLOCKS",hasControlledInnerBlocks:t,clientId:e}}var si=n(44);function ui(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 di(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 di(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 di(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 fi(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 bi(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?fi(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fi(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var pi=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"}))),mi=[];function vi(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 gi(e,t){var n=e.blocks.byClientId[t];return!!n&&n.isValid}function Oi(e,t){return e.blocks.byClientId[t]?e.blocks.attributes[t]:null}var hi=Object(si.a)((function(e,t){var n=e.blocks.byClientId[t];return n?bi(bi({},n),{},{attributes:Oi(e,t),innerBlocks:Ua(e,t)?mi:ki(e,t)}):null}),(function(e,t){return[e.blocks.cache[t]]})),ji=Object(si.a)((function(e,t){var n=e.blocks.byClientId[t];return n?bi(bi({},n),{},{attributes:Oi(e,t)}):null}),(function(e,t){return[e.blocks.byClientId[t],e.blocks.attributes[t]]})),ki=Object(si.a)((function(e,t){return Object(b.map)(na(e,t),(function(t){return hi(e,t)}))}),(function(e,t){return Object(b.map)(e.blocks.order[t||""],(function(t){return e.blocks.cache[t]}))})),yi=Object(si.a)((function(e,t){var n=e.blocks.byClientId[t];return n?bi(bi({},n),{},{attributes:Oi(e,t),innerBlocks:_i(e,t)}):null}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]})),_i=Object(si.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Object(b.map)(na(e,t),(function(t){return yi(e,t)}))}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]})),Ei=function e(t,n){return Object(b.flatMap)(n,(function(n){var r=na(t,n);return[].concat(ce(r),ce(e(t,r)))}))},Ci=Object(si.a)((function(e){var t=na(e);return[].concat(ce(t),ce(Ei(e,t)))}),(function(e){return[e.blocks.order]})),wi=Object(si.a)((function(e,t){var n=Ci(e);return t?Object(b.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]})),Si=Object(si.a)((function(e,t){return Object(b.map)(Object(b.castArray)(t),(function(t){return hi(e,t)}))}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]}));function Ii(e,t){return na(e,t).length}function Bi(e){return e.selectionStart}function xi(e){return e.selectionEnd}function Pi(e){return e.selectionStart.clientId}function Ti(e){return e.selectionEnd.clientId}function Ni(e){var t=qi(e).length;return t||(e.selectionStart.clientId?1:0)}function Di(e){var t=e.selectionStart,n=e.selectionEnd;return!!t.clientId&&t.clientId===n.clientId}function Ri(e){var t=e.selectionStart,n=e.selectionEnd,r=t.clientId;return r&&r===n.clientId?r:null}function Ai(e){var t=Ri(e);return t?hi(e,t):null}function Mi(e,t){return void 0!==e.blocks.parents[t]?e.blocks.parents[t]:null}var Li=Object(si.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]})),Fi=Object(si.a)((function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=Li(e,t,r);return Object(b.map)(Object(b.filter)(Object(b.map)(o,(function(t){return{id:t,name:vi(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 Vi(e,t){var n,r=t;do{n=r,r=e.blocks.parents[r]}while(r);return n}function Hi(e,t){for(var n,r=Ri(e),o=[].concat(ce(Li(e,t)),[t]),c=[].concat(ce(Li(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 zi(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;if(void 0===t&&(t=Ri(e)),void 0===t&&(t=n<0?Yi(e):Xi(e)),!t)return null;var r=Mi(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 Ui(e,t){return zi(e,t,-1)}function Gi(e,t){return zi(e,t,1)}function Ki(e){return e.initialPosition}var Wi=Object(si.a)((function(e){var t=e.selectionStart,n=e.selectionEnd;if(void 0===t.clientId||void 0===n.clientId)return mi;if(t.clientId===n.clientId)return[t.clientId];var r=Mi(e,t.clientId);if(null===r)return mi;var o=na(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 qi(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?mi:Wi(e)}var $i=Object(si.a)((function(e){var t=qi(e);return t.length?t.map((function(t){return hi(e,t)})):mi}),(function(e){return[].concat(ce(Wi.getDependants(e)),[e.blocks.byClientId,e.blocks.order,e.blocks.attributes])}));function Yi(e){return Object(b.first)(qi(e))||null}function Xi(e){return Object(b.last)(qi(e))||null}function Qi(e,t){return Yi(e)===t}function Zi(e,t){return-1!==qi(e).indexOf(t)}var Ji=Object(si.a)((function(e,t){for(var n=t,r=!1;n&&!r;)r=Zi(e,n=Mi(e,n));return r}),(function(e){return[e.blocks.order,e.selectionStart.clientId,e.selectionEnd.clientId]}));function ea(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?null:t.clientId||null}function ta(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?null:n.clientId||null}function na(e,t){return e.blocks.order[t||""]||mi}function ra(e,t,n){return na(e,n).indexOf(t)}function oa(e,t){var n=e.selectionStart,r=e.selectionEnd;return n.clientId===r.clientId&&n.clientId===t}function ca(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return Object(b.some)(na(e,t),(function(t){return oa(e,t)||Zi(e,t)||n&&ca(e,t,n)}))}function ia(e,t){if(!t)return!1;var n=qi(e),r=n.indexOf(t);return r>-1&&r<n.length-1}function aa(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId!==n.clientId}function la(e){return e.isMultiSelecting}function sa(e){return e.isSelectionEnabled}function ua(e,t){return e.blocksMode[t]||"visual"}function da(e){return e.isTyping}function fa(e){return!!e.draggedBlocks.length}function ba(e){return e.draggedBlocks}function pa(e,t){return e.draggedBlocks.includes(t)}function ma(e,t){if(!fa(e))return!1;var n=Li(e,t);return Object(b.some)(n,(function(t){return pa(e,t)}))}function va(e){return e.isCaretWithinFormattedText}function ga(e){var t,n,r=e.insertionPoint,o=e.selectionEnd;if(null!==r)return r;var c=o.clientId;return c?(t=Mi(e,c)||void 0,n=ra(e,o.clientId,t)+1):n=na(e).length,{rootClientId:t,index:n}}function Oa(e){return null!==e.insertionPoint}function ha(e){return e.template.isValid}function ja(e){return e.settings.template}function ka(e,t){if(!t)return e.settings.templateLock;var n=Pa(e,t);return n?n.templateLock:null}var ya=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(b.isBoolean)(e)?e:Object(b.isArray)(e)?!(!e.includes("core/post-content")||null!==t)||e.includes(t):n},o=Object(c.getBlockType)(t);if(!o)return!1;var i=Ta(e),a=i.allowedBlockTypes,l=r(a,t,!0);if(!l)return!1;var s=!!ka(e,n);if(s)return!1;var u=Pa(e,n);if(n&&void 0===u)return!1;var d=null==u?void 0:u.allowedBlocks,f=r(d,t),p=o.parent,m=vi(e,n),v=r(p,m);return null!==f&&null!==v?f||v:null!==f?f:null===v||v},_a=Object(si.a)(ya,(function(e,t,n){return[e.blockListSettings[n],e.blocks.byClientId[n],e.settings.allowedBlockTypes,e.settings.templateLock]}));function Ea(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return t.every((function(t){return _a(e,vi(e,t),n)}))}function Ca(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 wa=function(e,t,n){return!!Object(c.hasBlockSupport)(t,"inserter",!0)&&ya(e,t.name,n)},Sa=function(e){return function(t){return bi(bi({},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:bi(bi({},e.initialAttributes),t.attributes),innerBlocks:t.innerBlocks,keywords:t.keywords||e.keywords})}},Ia=Object(si.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(b.some)(Si(e,Ci(e)),{name:t.name}));var i=Ca(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=Ra(e,t.id);1===i.length&&(n=Object(c.getBlockType)(i[0].name));var a=Ca(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:pi,category:"reusable",keywords:[],isDisabled:!1,utility:1,frecency:u}},a=Object(c.getBlockTypes)().filter((function(t){return wa(e,t,n)})).map(o),l=ya(e,"core/block",n)?La(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=ui(a);try{for(d.s();!(t=d.n()).done;){var f=t.value,p=f.variations,m=void 0===p?[]:p;if(m.length){var v=Sa(f);u.push.apply(u,ce(m.map(v)))}}}catch(e){d.e(e)}finally{d.f()}return[].concat(ce(s),u,ce(l))}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.blocks.order,e.preferences.insertUsage,e.settings.allowedBlockTypes,e.settings.templateLock,La(e),Object(c.getBlockTypes)()]})),Ba=Object(si.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=Object(b.some)(Object(c.getBlockTypes)(),(function(n){return wa(e,n,t)}));if(n)return!0;var r=ya(e,"core/block",t)&&La(e).length>0;return r}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.settings.allowedBlockTypes,e.settings.templateLock,La(e),Object(c.getBlockTypes)()]})),xa=Object(si.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(t)return Object(b.filter)(Object(c.getBlockTypes)(),(function(n){return wa(e,n,t)}))}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.settings.allowedBlockTypes,e.settings.templateLock,Object(c.getBlockTypes)()]}));function Pa(e,t){return e.blockListSettings[t]}function Ta(e){return e.settings}function Na(e){return e.blocks.isPersistentChange}var Da=Object(si.a)((function(e,t){return Object(b.filter)(e.blockListSettings,(function(e,n){return t.includes(n)}))}),(function(e){return[e.blockListSettings]})),Ra=Object(si.a)((function(e,t){var n=Object(b.find)(La(e),(function(e){return e.id===t}));return n?Object(c.parse)(n.content.raw||n.content):null}),(function(e){return[La(e)]}));function Aa(e){return e.blocks.isIgnoredChange}function Ma(e){return e.lastBlockAttributesChange}function La(e){var t,n;return null!==(t=null==e||null===(n=e.settings)||void 0===n?void 0:n.__experimentalReusableBlocks)&&void 0!==t?t:mi}function Fa(e){return e.isNavigationMode}function Va(e){return e.hasBlockMovingClientId}function Ha(e){return!!e.automaticChangeStatus}function za(e,t){return e.highlightedBlock===t}function Ua(e,t){return!!e.blocks.controlledInnerBlocks[t]}var Ga=Object(si.a)((function(e,t){if(!t.length)return null;var n=Ri(e);if(t.includes(vi(e,n)))return n;var r=qi(e),o=Fi(e,n||r[0],t);return o?Object(b.last)(o):null}),(function(e,t){return[e.selectionStart.clientId,e.selectionEnd.clientId,t]}));function Ka(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 Wa(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ka(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ka(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var qa={MERGE_BLOCKS:function(e,t){var n=t.dispatch,r=t.getState(),o=Object(ie.a)(e.blocks,2),a=o[0],l=o[1],s=hi(r,a),u=Object(c.getBlockType)(s.name);if(u.merge){var d=hi(r,l),f=Object(c.getBlockType)(d.name),p=Bi(r),m=p.clientId,v=p.attributeKey,g=p.offset,O=(m===a?u:f).attributes[v],h=(m===a||m===l)&&void 0!==v&&void 0!==g&&!!O;O||("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(en(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=O.multiline,C=O.__unstableMultilineWrapperTags,w=O.__unstablePreserveWhiteSpace,S=Object(i.insert)(Object(i.create)({html:_,multilineTag:E,multilineWrapperTags:C,preserveWhiteSpace:w}),"",g,g);y.attributes[v]=Object(i.toHTMLString)({value:S,multilineTag:E,preserveWhiteSpace:w})}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(b.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(qc(s.clientId,x,M,M))}n(_c([s.clientId,d.clientId],[Wa(Wa({},s),{},{attributes:Wa(Wa({},s.attributes),B)})].concat(ce(I.slice(1)))))}}else n(pc(s.clientId))},RESET_BLOCKS:[function(e,t){var n=t.getState(),r=ja(n),o=ka(n),i=!r||"all"!==o||Object(c.doBlocksMatchTemplate)(e.blocks,r);if(i!==ha(n))return Dc(i)}],MULTI_SELECT:function(e,t){var n=Ni((0,t.getState)());Object(Ue.speak)(Object(O.sprintf)(
|
26 |
/* translators: %s: number of selected blocks */
|
27 |
Object(O._n)("%s block selected.","%s blocks selected.",n),n),"assertive")},SYNCHRONIZE_TEMPLATE:function(e,t){var n=(0,t.getState)(),r=ki(n),o=ja(n);return sc(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 $a=function(e){var t,n=[Ho()(qa),Uo.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=b.flowRight.apply(void 0,ce(t))(e.dispatch),e.dispatch=r,e};function Ya(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 Xa(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ya(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ya(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Qa={reducer:Fo,selectors:o,actions:r,controls:{SLEEP:function(e){var t=e.duration;return new Promise((function(e){setTimeout(e,t)}))}}},Za=Object(v.registerStore)("core/block-editor",Xa(Xa({},Qa),{},{persist:["preferences"]}));$a(Za);function Ja(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?b.noop:i,l=e.onInput,s=void 0===l?b.noop:l,d=Object(v.useRegistry)(),f=d.dispatch("core/block-editor"),p=f.resetBlocks,m=f.resetSelection,g=f.replaceInnerBlocks,O=f.setHasControlledInnerBlocks,h=f.__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(b.last)(_.current.outgoing)===r&&(_.current.outgoing=[]):y(n)!==r&&(_.current.outgoing=[],_.current.incoming=r,r&&(h(),n?(O(n,!0),h(),g(n,r,!1)):p(r)),o&&c&&m(o,c))}),[r,n])}var el=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(Ee.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(ie.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",Qa);$a(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]),Ja(e),t})),tl=n(71);var nl=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),f=a().bodyPlaceholder;return{isVisible:s||!u||!d,showPrompt:s,isLocked:!!l(t.rootClientId),placeholder:f}})),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(tl.decodeEntities)(c)||Object(O.__)("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)(ao.a,{role:"button","aria-label":Object(O.__)("Add block"),className:"block-editor-default-block-appender__content",readOnly:!0,onFocus:r,value:o?a:""}),Object(u.createElement)(fs,{rootClientId:i,position:"bottom right",isAppender:!0,__experimentalIsQuick:!0}))}));var rl=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)(fs,{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(O.sprintf)(// translators: %s: the name of the block when there is only one
|
28 |
Object(O._x)("Add %s","directly add the only allowed block"),s):Object(O._x)("Add block","Generic label for block inserter button");var b=!d,p=Object(u.createElement)(h.Button,{ref:t,onFocus:c,tabIndex:i,className:f()(r,"block-editor-button-block-appender"),onClick:o,"aria-haspopup":b?"true":void 0,"aria-expanded":b?l:void 0,disabled:a,label:n},!d&&Object(u.createElement)(h.VisuallyHidden,{as:"span"},n),Object(u.createElement)(ho.a,{icon:mo.a}));return(b||d)&&(p=Object(u.createElement)(h.Tooltip,{text:n},p)),p},isAppender:!0})})),ol=Object(u.createContext)();function cl(e){e.stopPropagation()}var il=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)(ol);if(c||!1===i)return null;if(i)t=Object(u.createElement)(i,null);else{var m=!r,v=l===r,g=l&&!n.includes(l);if(!m&&!v&&(!l||g))return null;t=o?Object(u.createElement)(nl,{rootClientId:r,lastBlockClientId:Object(b.last)(n)}):Object(u.createElement)(rl,{rootClientId:r,className:"block-list-appender__toggle"})}return Object(u.createElement)(d,{tabIndex:-1,onFocus:cl,className:f()("block-list-appender","wp-block",a),ref:function(e){e?p.set(r||"",e):p.delete(r||"")}},t)}));function al(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 ll(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 sl(e,t,n){return function(r){var o=Object(c.pasteHandler)({HTML:r,mode:"BLOCKS"});o.length&&n(o,t,e)}}function ul(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:al(e,t,r,o,l),onFilesDrop:ll(e,t,c,s,a),onHTMLDrop:sl(e,t,a)}}function dl(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 fl(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=dl(e,t,o);(void 0===n||c<n)&&(n=c,r=o)})),[n,r]}function bl(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 pl(e){var t=e.element,n=e.rootClientId,r=void 0===n?"":n,o=Object(u.useState)(null),c=Object(ie.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,f=l.orientation,b=ul(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?bl(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({element:t,isDisabled:d,withPosition:!0},b)).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=fl(t,a,c),s=Object(ie.a)(l,2),u=s[0],d=s[1];if(void 0===o||u<o){var f="bottom"===d||"right"===d,b=f?1:0,p=f&&e[i+1]&&e[i+1].classList.contains("is-dragging");o=u,r=i+(b+=p?1:0)}}})),r}(Array.from(t.current.children),p,f);a(void 0===e?0:e)}}),[p]),p)return i}var ml=new Map;function vl(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,f=r.isDraggingBlocks,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,isDraggingBlocks:f(),activeEntityBlockId:b}}),[n]),a=i.blockClientIds,l=i.selectedBlockClientId,s=i.multiSelectedBlockClientIds,d=i.orientation,b=i.hasMultiSelection,p=i.enableAnimation,m=i.isDraggingBlocks,g=i.activeEntityBlockId,O=pl({element:c,rootClientId:n}),h=O===a.length&&m;return Object(u.createElement)(u.Fragment,null,a.map((function(e,t){var r=b?s.includes(e):l===e,o=O===t&&m;return Object(u.createElement)(v.AsyncModeProvider,{key:e,value:!r},Object(u.createElement)(Mu,{rootClientId:n,clientId:e,index:t,enableAnimation:p,className:f()({"is-drop-target":o,"is-dropping-horizontally":o&&"horizontal"===d,"has-active-entity":g}),activeEntityBlockId:g}))})),a.length<1&&t,Object(u.createElement)(il,{tagName:o,rootClientId:n,renderAppender:r,className:f()({"is-drop-target":h,"is-dropping-horizontally":h&&"horizontal"===d})}))}function gl(e){return Object(u.createElement)(v.AsyncModeProvider,{value:!1},Object(u.createElement)(vl,e))}var Ol,hl=Object(u.forwardRef)((function(e,t){var n=e.className,r=e.placeholder,o=e.rootClientId,c=e.renderAppender,i=o?"div":Eu,a=Object(u.useRef)(),l=t||a;return Object(u.createElement)(ol.Provider,{value:ml},Object(u.createElement)(i,{ref:l,className:f()("block-editor-block-list__layout",n)},Object(u.createElement)(gl,{placeholder:r,rootClientId:o,renderAppender:c,wrapperRef:l})))}));function jl(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)(hl,null)))}var kl=function(e){var t=e.viewportWidth,n=e.__experimentalPadding,r=Object(p.useResizeObserver)(),o=Object(ie.a)(r,2),c=o[0],i=o[1].width,a=Object(p.useResizeObserver)(),l=Object(ie.a)(a,2),s=l[0],d=l[1].height;Ol=Ol||Object(p.pure)(hl);var f=(i-2*n)/t;return Object(u.createElement)("div",{className:"block-editor-block-preview__container editor-styles-wrapper","aria-hidden":!0,style:{height:d*f+2*n}},c,Object(u.createElement)(h.Disabled,{style:{transform:"scale(".concat(f,")"),width:t,left:n,right:n,top:n},className:"block-editor-block-preview__content"},s,Object(u.createElement)(Ol,null)))};var yl=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(b.castArray)(t)}),[t]);return t&&0!==t.length?Object(u.createElement)(el,{value:d,settings:s},a?Object(u.createElement)(jl,{onClick:l}):Object(u.createElement)(kl,{viewportWidth:c,__experimentalPadding:r})):null}));function _l(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 El(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_l(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Cl=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)(yl,{__experimentalPadding:16,viewportWidth:500,blocks:n.example?Object(c.getBlockFromExample)(t.name,{attributes:El(El({},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(O.__)("No Preview Available."))),!Object(c.isReusableBlock)(t)&&Object(u.createElement)(yo,{blockType:t}))},wl=n(50),Sl=n(110),Il=n(111);var Bl=function(e){var t=e.icon,n=e.onClick,r=e.isDisabled,o=e.title,c=e.className,i=e.composite,a=Object(Ee.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)(Il.a,Object(l.a)({role:"option",as:h.Button},i,{className:f()("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)(tr,{icon:t,showColors:!0})),Object(u.createElement)("span",{className:"block-editor-block-types-list__item-title"},o)))};var xl=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(wl.g)(),f=n.reduce((function(e,t){return e+"--"+t.id}),"");return Object(u.useEffect)((function(){d.unstable_sort()}),[d.unstable_sort,f]),Object(u.createElement)(Sl.a,Object(l.a)({},d,{role:"listbox",className:"block-editor-block-types-list","aria-label":s}),n.map((function(e){return Object(u.createElement)(Bl,{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 Pl(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)(tr,{icon:c,showColors:!0}),o&&Object(u.createElement)("h2",null,o)),n)}var Tl=Object(h.createSlotFill)("__experimentalInserterMenuExtension"),Nl=Tl.Fill,Dl=Tl.Slot;Nl.Slot=Dl;var Rl=Nl;var Al=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 Ml=function(){return Object(u.createElement)("div",{className:"block-editor-inserter__no-results"},Object(u.createElement)(ho.a,{className:"block-editor-inserter__no-results-icon",icon:er.a}),Object(u.createElement)("p",null,Object(O.__)("No results found.")))};function Ll(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 Fl=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=Jn(t,n),l=Object(ie.a)(a,4),d=l[0],f=l[1],p=l[2],m=l[3],g=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 Xn(d,f,p,o)}),[o,d,f,p]),j=Object(u.useMemo)((function(){return Object(b.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(b.findIndex)(f,(function(t){return t.slug===e.category}))};return Object(b.flow)((function(e){return e.filter((function(e){return e.category&&"reusable"!==e.category}))}),(function(t){return Object(b.sortBy)(t,e)}),(function(e){return Object(b.groupBy)(e,"category")}))(h)}),[h,f]),_=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?Ll(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ll(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(O.sprintf)(
|
29 |
/* translators: %d: number of results. */
|
30 |
Object(O._n)("%d result found.","%d results found.",h.length),h.length);c(e)}),[o,c]);var E=!Object(b.isEmpty)(h);return Object(u.createElement)("div",null,g&&Object(u.createElement)(Pl,{rootClientId:t},Object(u.createElement)(xl,{items:h,onSelect:m,onHover:r,label:Object(O.__)("Child Blocks")})),i&&!g&&!!j.length&&!o&&Object(u.createElement)(Al,{title:Object(O._x)("Most used","blocks")},Object(u.createElement)(xl,{items:j,onSelect:m,onHover:r,label:Object(O._x)("Most used","blocks")})),!g&&Object(b.map)(f,(function(e){var t=y[e.slug];return t&&t.length?Object(u.createElement)(Al,{key:e.slug,title:e.title,icon:e.icon},Object(u.createElement)(xl,{items:t,onSelect:m,onHover:r,label:e.title})):null})),!g&&!!k.length&&Object(u.createElement)(Al,{className:"block-editor-inserter__uncategorized-blocks-panel",title:Object(O.__)("Uncategorized")},Object(u.createElement)(xl,{items:k,onSelect:m,onHover:r,label:Object(O.__)("Uncategorized")})),!g&&Object(b.map)(p,(function(e,t){var n=_[t];return n&&n.length?Object(u.createElement)(Al,{key:t,title:e.title,icon:e.icon},Object(u.createElement)(xl,{items:n,onSelect:m,onHover:r,label:e.title})):null})),Object(u.createElement)(Rl.Slot,{fillProps:{onSelect:m,onHover:r,filterValue:o,hasItems:E}},(function(e){return e.length?e:E?null:Object(u.createElement)(Ml,null)})))}));var Vl=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:f()("block-editor-inserter__panel-header","block-editor-inserter__panel-header-patterns")},Object(u.createElement)(h.SelectControl,{className:"block-editor-inserter__panel-dropdown",label:Object(O.__)("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))},Hl=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(b.map)(n,(function(e){return Object(c.cloneBlock)(e)})),t.name),o(Object(O.sprintf)(
|
31 |
/* translators: %s: block pattern title. */
|
32 |
-
Object(O.__)('Block pattern "%s" inserted.'),t.title),{type:"snackbar"})}),[])]};function zl(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)(zl),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){pt.ENTER!==e.keyCode&&pt.SPACE!==e.keyCode||n(t,i)},tabIndex:0,"aria-label":t.title,"aria-describedby":t.description?l:void 0},Object(u.createElement)(yl,{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 Ul(){return Object(u.createElement)("div",{className:"block-editor-block-patterns-list__item is-placeholder"})}var Gl=function(e){var t=e.blockPatterns,n=e.shownPatterns,r=e.onClickPattern;return t.map((function(e){return n.includes(e)?Object(u.createElement)(zl,{key:e.name,pattern:e,onClick:r}):Object(u.createElement)(Ul,{key:e.name})}))};function
|
33 |
/* translators: %d: number of results. */
|
34 |
Object(O._n)("%d result found.","%d results found.",b.length),b.length);t(e)}),[n,t]),0===b.length?Object(u.createElement)(Ml,null):Object(u.createElement)(Al,{title:n?Object(O.__)("Search Results"):Object(O.__)("Reusable blocks")},Object(u.createElement)(xl,{items:b,onSelect:f,onHover:r,label:n?Object(O.__)("Search Results"):Object(O.__)("Reusable blocks")}))}var Xl=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)(Yl,{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($l.addQueryArgs)("edit.php",{post_type:"wp_block"})},Object(O.__)("Manage all reusable blocks"))))}));function Ql(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 Zl=function(e){var t=e.onSelect,n=e.rootClientId,r=e.clientId,o=e.isAppender,i=e.selectBlockOnInsert,a=e.insertionIndex,l=Object(v.useSelect)((function(e){var t,c=e("core/block-editor"),i=c.getSettings,a=c.getBlockRootClientId,l=c.getBlockSelectionEnd,u=n;if(!u&&!r&&!o){var d=l();d&&(u=a(d))}return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ql(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ql(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({hasPatterns:!!(null===(t=i().__experimentalBlockPatterns)||void 0===t?void 0:t.length),destinationRootClientId:u},Object(b.pick)(e("core/block-editor"),["getSelectedBlock","getBlockIndex","getBlockSelectionEnd","getBlockOrder"]))}),[o,r,n]),u=l.destinationRootClientId,d=l.getSelectedBlock,f=l.getBlockIndex,p=l.getBlockSelectionEnd,m=l.getBlockOrder,g=Object(v.useDispatch)("core/block-editor"),h=g.replaceBlocks,j=g.insertBlocks,k=g.showInsertionPoint,y=g.hideInsertionPoint;function _(){if(void 0!==a)return a;if(r)return f(r,u);var e=p();return!o&&e?f(e,u)+1:m(u).length}return[u,function(e,n){var r=d();if(!o&&r&&Object(c.isUnmodifiedDefaultBlock)(r)?h(r.clientId,e,null,null,n):j(e,_(),u,i,n),!i){
|
35 |
// translators: %d: the name of the block that has been added
|
@@ -43,9 +43,9 @@ title:Object(O.__)("Reusable")};var ns=function(e){var t=e.children,n=e.showPatt
|
|
43 |
/* translators: %d: number of results. */
|
44 |
Object(O._n)("%d result found.","%d results found.",e),e);i(t)}}),[s,i]);return Object(u.createElement)("div",{className:f()("block-editor-inserter__quick-inserter",{"has-search":N,"has-expand":A}),onKeyPress:is,onKeyDown:cs},N&&Object(u.createElement)(ko,{value:s,onChange:function(e){d(e)},placeholder:Object(O.__)("Search for a block")}),Object(u.createElement)(as,{blockTypes:D,blockPatterns:T?R:[],onSelectBlockPattern:P,onSelectBlockType:S,onHover:k}),A&&Object(u.createElement)(h.Button,{className:"block-editor-inserter__quick-inserter-expand",onClick:function(){L(M),setTimeout((function(){A(!0)}))},"aria-label":Object(O.__)("Browse all. This will open the main inserter panel in the editor toolbar.")},Object(O.__)("Browse all")))}function ss(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var us=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(O.sprintf)(// translators: %s: the name of the block when there is only one
|
45 |
Object(O._x)("Add %s","directly add the only allowed block"),c):Object(O._x)("Add block","Generic label for block inserter button");var d=s.onClick,f=Object(Ee.a)(s,["onClick"]);return Object(u.createElement)(h.Button,Object(l.a)({icon:mo.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},f))},ds=function(e){Jt(n,e);var t=ss(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).onToggle=e.onToggle.bind(Qt(e)),e.renderToggle=e.renderToggle.bind(Qt(e)),e.renderContent=e.renderContent.bind(Qt(e)),e}return Xt(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?us: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)(ls,{onSelect:t,rootClientId:r,clientId:o,isAppender:c,selectBlockOnInsert:a}):Object(u.createElement)(os,{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:f()("block-editor-inserter__popover",{"is-quick":o}),position:t,onToggle:this.onToggle,expandOnMobile:!0,headerTitle:Object(O.__)("Add a block"),renderToggle:this.renderToggle,renderContent:this.renderContent})}}]),n}(u.Component),fs=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(b.size)(s)&&0===Object(b.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(O.sprintf)(// translators: %s: the name of the block that has been added
|
46 |
-
Object(O.__)("%s block added"),l.title);Object(Ue.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}))])(ds),bs=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=Ze(n);if(r){var t=xr.focus.tabbable.find(e);(Object(b.last)(t)||e).focus()}else e.focus()}else{if(i)return void a.current.focus();s(!0);var l=xr.focus.tabbable.find(o.current);l.length&&(r?Object(b.last)(l).focus():Object(b.first)(l).focus())}},style:{position:"fixed"}})}));var ps=Object(b.overEvery)([xr.isTextField,xr.focus.tabbable.isTabbableIndex]);function ms(e,t,n,r){var o,c=xr.focus.focusable.find(n);return t&&(c=Object(b.reverse)(c)),c=c.slice(c.indexOf(e)+1),r&&(o=e.getBoundingClientRect()),Object(b.find)(c,(function t(n,c,i){if(!xr.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(xr.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 vs(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,f=t.hasBlockMovingClientId,b=t.getBlockIndex,p=t.getBlockRootClientId,m=t.getClientIdsOfDescendants,v=t.canInsertBlockType,g=t.getBlockName,O=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:f,getBlockIndex:b,getBlockRootClientId:p,getClientIdsOfDescendants:m,canInsertBlockType:v,getBlockName:g,isSelectionEnabled:O(),blockSelectionStart:h(),isMultiSelecting:j(),keepCaretInsideBlock:k().keepCaretInsideBlock}}function gs(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)(vs,[]),d=s.selectedBlockClientId,p=s.selectionStartClientId,m=s.selectionBeforeEndClientId,g=s.selectionAfterEndClientId,h=s.selectedFirstClientId,j=s.selectedLastClientId,k=s.hasMultiSelection,y=s.blocks,_=s.isNavigationMode,E=s.hasBlockMovingClientId,C=s.isSelectionEnabled,w=s.blockSelectionStart,S=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(ie.a)(H,2),U=z[0],G=z[1];Object(u.useEffect)((function(){k&&!S&&c.current.focus()}),[k,S]);var K=f()("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)(bs,{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===pt.UP,f=t===pt.DOWN,v=t===pt.LEFT,O=t===pt.RIGHT,C=t===pt.TAB,w=t===pt.ESCAPE,S=t===pt.ENTER,D=t===pt.SPACE,H=u||v,z=v||O,U=u||f,K=z||U,W=e.shiftKey,q=W||e.ctrlKey||e.altKey||e.metaKey,$=U?xr.isVerticalEdge:xr.isHorizontalEdge;if(_){var Y,X=C&&W||u,Q=C&&!W||f,Z=v,J=O;if(X)Y=m;else if(Q)Y=g;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))),w&&ne&&(F(null),G(!1)),(S||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=Ze(d);(ae=Q?xr.focus.tabbable.findNext(le):xr.focus.tabbable.findPrevious(le))&&(e.preventDefault(),ae.focus(),M())}}else{if(d)if(C){var se=Ze(d);if(W){if(s===se)return a.current=!0,void r.current.focus()}else{var ue=xr.focus.tabbable.find(se);if(s===(Object(b.last)(ue)||se))return a.current=!0,void o.current.focus()}}else w&&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(xr.computeCaretRect)(de)):l.current=null,!K)return pt.isKeyboardEvent.primary(e)&&(i.current=Object(xr.isEntirelySelected)(s)),void(pt.isKeyboardEvent.primary(e,"a")&&((s.isContentEditable?i.current:Object(xr.isEntirelySelected)(s))&&(R(Object(b.first)(y),Object(b.last)(y)),e.preventDefault()),i.current=!0));if(!e.nativeEvent.defaultPrevented&&function(e,t,n){if((t===pt.UP||t===pt.DOWN)&&!n)return!0;var r=e.tagName;return"INPUT"!==r&&"TEXTAREA"!==r}(s,t,q)){var fe,be="rtl"===(fe=s).ownerDocument.defaultView.getComputedStyle(fe).direction?!H:H;if(W)(H&&m||!H&&g)&&(k||function(e,t){var r,o,c=ms(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:g;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(xr.isVerticalEdge)(s,H)&&!N){var pe=ms(s,H,n.current,!0);pe&&(Object(xr.placeCaretAtVerticalEdge)(pe,H,l.current),e.preventDefault())}else if(z&&de.getSelection().isCollapsed&&Object(xr.isHorizontalEdge)(s,be)&&!N){var me=ms(s,be,n.current);Object(xr.placeCaretAtHorizontalEdge)(me,be),e.preventDefault()}}}},onMouseDown:function(e){if(l.current=null,_&&d&&Je(Ze(d),e.target)?(L(!1),F(null)):_&&E()&&et(e.target)&&G(P(T(E()),B(et(e.target)))),C&&0===e.button){var t=et(e.target);t&&(e.shiftKey?w!==t&&(R(w,t),e.preventDefault()):k&&A(t))}}},Object(u.createElement)("div",{ref:c,tabIndex:k?"0":void 0,"aria-label":k?Object(O.__)("Multiple selected blocks"):void 0,style:{position:"fixed"}}),t),Object(u.createElement)(bs,{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=xr.focus.focusable.find(n.current),t=Object(b.findLast)(e,ps);t&&Object(xr.placeCaretAtHorizontalEdge)(t,!0)},className:"block-editor-writing-flow__click-redirect"}))}function Os(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=Ze(t),u=ms(s,!0,l?r.current:s)||s,d=new window.DOMRect(n,c,0,16);Object(xr.placeCaretAtVerticalEdge)(u,l,d,!1)}},tabIndex:-1,className:f()("block-editor-block-list__insertion-point-inserter",{"is-inserter-hidden":c})},Object(u.createElement)(fs,{position:"bottom center",clientId:t,__experimentalIsQuick:!0}))}function hs(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)(ol),s=Object(u.useMemo)((function(){return t?Ze(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)(Os,{clientId:t,setIsInserterForced:c,containerRef:i})))}function js(e){var t=e.children,n=e.containerRef,r=Object(u.useState)(!1),o=Object(ie.a)(r,2),c=o[0],i=o[1],a=Object(u.useState)(!1),l=Object(ie.a)(a,2),s=l[0],d=l[1],f=Object(u.useState)(null),b=Object(ie.a)(f,2),p=b[0],m=b[1],g=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}}),[]),O=g.isMultiSelecting,h=g.isInserterVisible,j=g.selectedClientId,k=g.selectedRootClientId;var y=c||s||h;return Object(u.createElement)(u.Fragment,null,!O&&y&&Object(u.createElement)(hs,{clientId:h?j:p,rootClientId:k,isInserterShown:c,isInserterForced:s,setIsInserterForced:d,containerRef:n,showInsertionPoint:h}),Object(u.createElement)("div",{onMouseMove:s||O?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 ks=function(e){var t=e.clientId,n=e.rootClientId,r=Object(Ee.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,b=o.orientation,p=Object(v.useDispatch)("core/block-editor"),m=p.setNavigationMode,g=p.removeBlock,O=Object(u.useRef)();Object(u.useEffect)((function(){O.current.focus(),window.navigator.platform.indexOf("Win")>-1&&Object(Ue.speak)(k)}),[]);var j=Object(c.getBlockType)(a),k=Object(c.__experimentalGetAccessibleBlockLabel)(j,s,i+1,b),y=f()("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:O,onClick:function(){return m(!1)},onKeyDown:function(e){var n=e.keyCode;n!==pt.BACKSPACE&&n!==pt.DELETE||(g(t),e.preventDefault())},label:k},Object(u.createElement)(ir,{clientId:t})))};function ys(e,t,n){var r=Object(u.useState)(t),o=Object(ie.a)(r,1)[0],c=Object(u.useCallback)((function(){var t,n,r;t=e.current,n=xr.focus.tabbable.find(t),(r=Object(ie.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 _s=function(e){var t=e.children,n=e.focusOnMount,r=Object(Ee.a)(e,["children","focusOnMount"]),o=Object(u.useRef)(),c=function(e){var t=Object(u.useState)(!0),n=Object(ie.a)(t,2),r=n[0],o=n[1],c=Object(u.useCallback)((function(){var t=xr.focus.tabbable.find(e.current),n=!t.some((function(e){return!("toolbarItem"in e.dataset)}));n||uo()("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 ys(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)},Es=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 Cs(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(ie.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)(tr,{icon:n}):Object(O.sprintf)(
|
47 |
/* translators: %d: Number of blocks. */
|
48 |
-
Object(O._n)("%d block","%d blocks",t.length),t.length)),Object(u.createElement)(h.FlexItem,null,Object(u.createElement)(tr,{icon:Es})))))}var ws=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,f=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]),b=f.srcRootClientId,p=f.isDraggable,m=Object(u.useRef)(!1),g=(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(xr.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)}]),O=Object(ie.a)(g,3),j=O[0],k=O[1],y=O[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 w={type:"block",srcClientIds:i,srcRootClientId:b};return Object(u.createElement)(h.Draggable,{cloneClassname:a,elementId:d||"block-".concat(i[0]),transferData:w,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)(Cs,{clientIds:i})},(function(e){var t=e.onDraggableStart,n=e.onDraggableEnd;return c({isDraggable:!0,onDraggableStart:t,onDraggableEnd:n})}))};var Ss=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,f=Object(b.castArray)(r),p=Object(b.first)(f),m=i(p),v=d(Object(b.first)(f)),g=a(p,v),O=0===g,h=a(Object(b.last)(f),v)===u(v).length-1;return{blockType:m?Object(c.getBlockType)(m.name):null,isLocked:"all"===s(v),rootClientId:v,firstIndex:g,isFirst:O,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),b=Object(ie.a)(d,2),p=b[0],m=b[1],v=function(){return m(!0)},g=function(){return m(!1)};return o||t&&n&&!i?null:Object(u.createElement)("div",{className:f()("block-editor-block-mover",{"is-visible":p||!c,"is-horizontal":"horizontal"===a})},!s&&Object(u.createElement)(ws,{clientIds:r,cloneClassname:"block-editor-block-mover__drag-clone"},(function(e){var t=e.isDraggable,n=e.onDraggableStart,o=e.onDraggableEnd;return Object(u.createElement)(h.Button,{icon:Es,className:"block-editor-block-mover__drag-handle","aria-hidden":"true",label:Object(O._n)("Drag block","Drag blocks",r.length),tabIndex:"-1",onDragStart:n,onDragEnd:o,draggable:t})})),Object(u.createElement)(h.ToolbarGroup,{className:"block-editor-block-mover__move-button-container"},Object(u.createElement)(h.ToolbarItem,{onFocus:v,onBlur:g},(function(e){return Object(u.createElement)(Gr,Object(l.a)({clientIds:r},e))})),Object(u.createElement)(h.ToolbarItem,{onFocus:v,onBlur:g},(function(e){return Object(u.createElement)(
|
49 |
/* translators: %s: Name of the block's parent. */
|
50 |
Object(O.__)("Select parent (%s)"),n.title),showTooltip:!0,icon:Object(u.createElement)(tr,{icon:n.icon})})):null}var Bs=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 xs(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 Ps(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 Ps(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 Ps(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 Ts(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 Ns(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ts(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ts(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ds(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 Ns(Ns({},t),{},{attributes:Ns(Ns({},t.attributes),{},{className:a})})}),[t,a]);return Object(u.createElement)("div",{key:n.name,className:f()("block-editor-block-styles__item",{"is-active":r}),onClick:function(){return i()},onKeyDown:function(e){pt.ENTER!==e.keyCode&&pt.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)(yl,{viewportWidth:500,blocks:s})),Object(u.createElement)("div",{className:"block-editor-block-styles__item-label"},n.label||n.name))}var Rs=function(e){var t=e.clientId,n=e.onSwitch,r=void 0===n?b.noop:n,o=e.onHoverClassName,i=void 0===o?b.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,f=l.type,p=l.className,m=Object(v.useDispatch)("core/block-editor").updateBlockAttributes,g=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,f);if(!s||0===s.length)return null;var h=Object(b.find)(s,"isDefault")?s:[{name:"default",label:Object(O._x)("Default","block style"),isDefault:!0}].concat(ce(s)),j=function(e,t){var n,r=xs(new kt.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(b.find)(e,{name:c});if(i)return i}}}catch(e){r.e(e)}finally{r.f()}return Object(b.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 kt.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)(Ds,{genericPreviewBlock:g,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})})))},As=function(e){var t=e.className,n=e.possibleBlockTransformations,r=e.onSelect;return Object(u.createElement)(h.MenuGroup,{label:Object(O.__)("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)(tr,{icon:n,showColors:!0}),o)})))};function Ms(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}function Ls(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 Fs(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ls(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ls(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Vs(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(O.__)("Preview")),Object(u.createElement)(yl,{viewportWidth:500,blocks:r.example?Object(c.getBlockFromExample)(t.name,{attributes:Fs(Fs({},r.example.attributes),{},{className:n}),innerBlocks:r.example.innerBlocks}):Object(c.cloneBlock)(t,{className:n})})))))}var Hs=function(e){Jt(n,e);var t=Ms(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).state={hoveredClassName:null},e.onHoverClassName=e.onHoverClassName.bind(Qt(e)),e}return Xt(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(ie.a)(n,1)[0],d=Object(b.mapKeys)(o,(function(e){return e.name})),f=Object(b.orderBy)(Object(b.filter)(Object(c.getPossibleBlockTransformations)(n),(function(e){return e&&!!d[e.name]})),(function(e){return d[e.name].frecency}),"desc");if(1===Object(b.uniq)(Object(b.map)(n,"name")).length){var p=s.name,m=Object(c.getBlockType)(p);l=m.icon}else l=Bs;var v=!!f.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(O.__)("Block icon"),icon:Object(u.createElement)(tr,{icon:l,showColors:!0})}));var g=1===n.length?Object(O.__)("Change block type or style"):Object(O.sprintf)(
|
51 |
/* translators: %s: number of blocks. */
|
@@ -53,20 +53,20 @@ Object(O._n)("Change type of %d block","Change type of %d blocks",n.length),n.le
|
|
53 |
Object(O.__)('Copied "%s" to clipboard.'),a):Object(O.sprintf)(// Translators: Name of the block being cut, e.g. "Paragraph".
|
54 |
Object(O.__)('Moved "%s" to clipboard.'),a)}else c="copy"===r?Object(O.sprintf)(// Translators: %d: Number of blocks being copied.
|
55 |
Object(O._n)("Copied %d block to clipboard.","Copied %d blocks to clipboard.",o.length),o.length):Object(O.sprintf)(// Translators: %d: Number of blocks being cut.
|
56 |
-
Object(O._n)("Moved %d block to clipboard.","Moved %d blocks to clipboard.",o.length),o.length);n(c,{type:"snackbar"})}),[])}var Ks=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,f=s.removeBlocks,p=s.replaceBlocks,m=Gs(),g=l().__experimentalCanUserUseUnfilteredHTML,O=function(e){var t=i();if(0!==t.length){if(!a()){var r=e.target.ownerDocument;if("copy"===e.type||"cut"===e.type?Object(xr.documentHasUncollapsedSelection)(r):Object(xr.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)f(t);else if("paste"===e.type){var u=function(e){var t=e.clipboardData,n=t.items,r=t.files;n=Object(b.isNil)(n)?[]:n,r=Object(b.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(b.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(Us.createBlobURL)(e),'">')})).join(""),o=""),{html:c,plainText:o}}(e),v=u.plainText,O=u.html,h=Object(c.pasteHandler)({HTML:O,plainText:v,mode:"BLOCKS",canUserUseUnfilteredHTML:g});p(t,h,h.length-1,-1)}}}};return Object(u.createElement)("div",{ref:n,onCopy:O,onCut:O,onPaste:O},t)};function Ws(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,f=u.getGroupingBlockName,p=l(t),m=a(t[0]),g=Object(b.every)(p,(function(e){return!!e&&Object(c.hasBlockSupport)(e.name,"multiple",!0)&&i(e.name,m)})),O=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,w=h.setBlockMovingClientId,S=h.setNavigationMode,I=h.selectBlock,B=Gs();return n({canDuplicate:g,canInsertDefaultBlock:O,isLocked:!!s(m),rootClientId:m,blocks:p,onDuplicate:function(){return y(t,r)},onRemove:function(){return j(t,r)},onInsertBefore:function(){E(Object(b.first)(Object(b.castArray)(t)))},onInsertAfter:function(){_(Object(b.last)(Object(b.castArray)(t)))},onMoveTo:function(){S(!0),I(t[0]),w(t[0])},onGroup:function(){if(p.length){var e=f(),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 qs=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?b.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(O.__)("Edit as HTML"):Object(O.__)("Edit visually");return Object(u.createElement)(h.MenuItem,{onClick:r},!i&&s)}));var $s=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(O.__)("Convert to Blocks");return Object(u.createElement)(h.MenuItem,{onClick:n},!r&&o)})),Ys=Object(h.createSlotFill)("__experimentalBlockSettingsMenuFirstItem"),Xs=Ys.Fill,Qs=Ys.Slot;Xs.Slot=Qs;var Zs=Xs;function Js(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 eu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Js(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Js(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var tu=Object(h.createSlotFill)("BlockSettingsMenuControls"),nu=tu.Fill,ru=tu.Slot;nu.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(b.map)(Object(b.compact)(n(c)),(function(e){return e.name}))}),[r]);return Object(u.createElement)(ru,{fillProps:eu(eu({},t),{},{selectedBlocks:o})},(function(e){return!Object(b.isEmpty)(e)&&Object(u.createElement)(h.MenuGroup,null,e)}))};var ou=nu,cu={className:"block-editor-block-settings-menu__popover",position:"bottom right",isAlternate:!0};var iu=function(e){var t=e.clientIds,n=e.__experimentalSelectBlock,r=e.children,o=Object(Ee.a)(e,["clientIds","__experimentalSelectBlock","children"]),i=Object(b.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")}}),[]),f=Object(u.useCallback)(n?function(){var e=Sr(Cr.a.mark((function e(t){var r;return Cr.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)}}():b.noop,[n]);return Object(u.createElement)(Ws,{clientIds:t,__experimentalUpdateSelection:!n},(function(e){var n=e.canDuplicate,i=e.canInsertDefaultBlock,p=e.isLocked,m=e.onDuplicate,v=e.onInsertAfter,g=e.onInsertBefore,j=e.onRemove,k=e.onCopy,y=e.onMoveTo,_=e.blocks;return Object(u.createElement)(h.DropdownMenu,Object(l.a)({icon:Ir.a,label:Object(O.__)("More options"),className:"block-editor-block-settings-menu",popoverProps:cu,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)(Zs.Slot,{fillProps:{onClose:o}}),1===a&&Object(u.createElement)($s,{clientId:s}),Object(u.createElement)(h.ClipboardButton,{text:function(){return Object(c.serialize)(_)},role:"menuitem",className:"components-menu-item__button",onCopy:k},Object(O.__)("Copy")),n&&Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,m,f),shortcut:d.duplicate},Object(O.__)("Duplicate")),i&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,g),shortcut:d.insertBefore},Object(O.__)("Insert Before")),Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,v),shortcut:d.insertAfter},Object(O.__)("Insert After"))),!p&&Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,y)},Object(O.__)("Move To")),1===a&&Object(u.createElement)(qs,{clientId:s,onToggle:o})),Object(u.createElement)(ou.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,!p&&Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,j,f),shortcut:d.remove},Object(O._n)("Remove block","Remove blocks",a))))}))}))};var au=function(e){var t=e.clientIds,n=Object(Ee.a)(e,["clientIds"]);return Object(u.createElement)(h.ToolbarGroup,null,Object(u.createElement)(h.ToolbarItem,null,(function(e){return Object(u.createElement)(iu,Object(l.a)({clientIds:t,toggleProps:e},n))})))},lu=window,su=lu.clearTimeout,uu=lu.setTimeout;function du(e){var t=e.ref,n=e.isFocused,r=e.debounceTimeout,o=void 0===r?200:r,c=e.onChange,i=void 0===c?b.noop:c,a=Object(u.useState)(!1),l=Object(ie.a)(a,2),s=l[0],d=l[1],f=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=f.current;e&&su&&su(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(),f.current=uu((function(){m()&&p(!1)}),o)}}}var fu=n(264);function bu(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),f=l();return{blockClientIds:s,blockClientId:u,blockType:u&&Object(c.getBlockType)(n(u)),hasFixedToolbar:f.hasFixedToolbar,hasReducedUI:f.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,O=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?b.noop:o,i=Object(u.useState)(!1),a=Object(ie.a)(i,2),l=a[0],s=a[1],d=du({ref:t,debounceTimeout:r,isFocused:l,onChange:c}),f=d.showMovers,p=d.debouncedShowMovers,m=d.debouncedHideMovers,v=Object(u.useRef)(!1),g=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(){g()&&(s(!0),p())},r=function(){g()||(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:f,gestures:{onMouseMove:p,onMouseLeave:m}}}({ref:y,onChange:function(e){e&&m||k(a,e)}}),E=_.showMovers,C=_.gestures,w=Object(p.useViewportMatch)("medium","<")||d;if(s&&!Object(c.hasBlockSupport)(s,"__experimentalToolbar",!0))return null;var S=w||E;if(0===i.length)return null;var I=O&&j,B=i.length>1,x=f()("block-editor-block-toolbar",S&&"is-showing-movers"),P=r?fu.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)(Is,{clientIds:i})),(I||B)&&Object(u.createElement)(h.ToolbarGroup,{className:"block-editor-block-toolbar__block-controls"},Object(u.createElement)(zs,{clientIds:i}),Object(u.createElement)(Ss,{clientIds:i,hideDragHandle:t||m}))),I&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(g.a.Slot,{bubblesVirtually:!0,className:"block-editor-block-toolbar__slot"}),Object(u.createElement)(_r.Slot,{bubblesVirtually:!0,className:"block-editor-block-toolbar__slot"})),Object(u.createElement)(au,{clientIds:i}))}var pu=function(e){var t=e.focusOnMount,n=Object(Ee.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)(_s,Object(l.a)({focusOnMount:t,className:"block-editor-block-contextual-toolbar"
|
57 |
/* translators: accessibility text for the block toolbar */,"aria-label":Object(O.__)("Block tools")},n),Object(u.createElement)(bu,null)))};function mu(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 vu(e){var t=e.clientId,n=e.rootClientId,r=e.isValid,o=e.isEmptyDefaultBlock,c=e.capturingClientId,i=Object(v.useSelect)(mu,[]),l=i.isNavigationMode,s=i.isMultiSelecting,d=i.isTyping,b=i.isCaretWithinFormattedText,m=i.hasMultiSelection,g=i.hasFixedToolbar,O=i.lastClientId,j=Object(p.useViewportMatch)("medium"),k=Object(u.useState)(!1),y=Object(ie.a)(k,2),_=y[0],E=y[1],C=Object(u.useState)(!1),w=Object(ie.a)(C,2),S=w[0],I=w[1],B=Object(u.useContext)(ju),x=!d&&!l&&o&&r,P=l,T=!l&&!g&&j&&!x&&!s&&(!d||b),N=!(l||T||g||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[O];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:f()("block-editor-block-list__block-popover-inserter",{"is-visible":S})},Object(u.createElement)(fs,{clientId:t,rootClientId:n,__experimentalIsQuick:!0})),(T||_)&&Object(u.createElement)(pu,{focusOnMount:_}),P&&Object(u.createElement)(ks,{clientId:t,rootClientId:n}),x&&Object(u.createElement)("div",{className:"block-editor-block-list__empty-block-inserter"},Object(u.createElement)(fs,{position:"bottom right",rootClientId:n,clientId:t,__experimentalIsQuick:!0})))}function gu(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)||{},f=d.name,p=d.attributes,m=void 0===p?{}:p,v=d.isValid,g=a(s),O=l(g),h=Object(b.findIndex)(O,["__experimentalCaptureToolbars",!0]);return-1!==h&&(u=g[h]),{clientId:s,rootClientId:o(s),name:f,isValid:v,isEmptyDefaultBlock:f&&Object(c.isUnmodifiedDefaultBlock)({name:f,attributes:m}),capturingClientId:u}}}function Ou(){var e=Object(v.useSelect)(gu,[]);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)(vu,{clientId:t,rootClientId:n,isValid:o,isEmptyDefaultBlock:c,capturingClientId:i}):null}var hu=Object(u.createContext)(),ju=Object(u.createContext)(),ku=Object(u.createContext)();function yu(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientId,r=t.hasMultiSelection;return{selectedBlockClientId:n(),hasMultiSelection:r()}}function _u(e){et(e.target)&&e.preventDefault()}var Eu=Object(u.forwardRef)((function(e,t){var n=e.children,r=e.className,o=Object(v.useSelect)(yu,[]),c=o.selectedBlockClientId,i=o.hasMultiSelection,a=Object(v.useDispatch)("core/block-editor").selectBlock,l=function(e){var t=Object(v.useSelect)(bo,[]),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,f=l.multiSelect,b=l.selectBlock,p=Object(u.useRef)(),m=Object(u.useRef)(),g=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=Ze(l),d=Ze(s),f=n.getSelection(),b=t.createRange();u=fo(u,"start"),d=fo(d,"end"),b.setStartBefore(u),b.setEndAfter(d),f.removeAllRanges(),f.addRange(b)}}else{if(!a||r)return;var p=n.getSelection();if(p.rangeCount&&!p.isCollapsed){var m=Ze(a),v=p.getRangeAt(0),g=v.startContainer,O=v.endContainer;!m||m.contains(g)&&m.contains(O)||p.removeAllRanges()}}}),[c,r,o,b,a]);var O=Object(u.useCallback)((function(t){var n=t.isSelectionEnd,r=e.current.ownerDocument.defaultView.getSelection();if(r.rangeCount&&!r.isCollapsed){var o=et(r.focusNode);if(m.current===o){if(b(o),n&&(po(e.current,!0),r.rangeCount)){var c=r.getRangeAt(0).commonAncestorContainer;g.current.contains(c)&&g.current.focus()}}else{var a=[].concat(ce(i(m.current)),[m.current]),l=[].concat(ce(i(o)),[o]),s=Math.min(a.length,l.length)-1;f(a[s],l[s])}}else po(e.current,!0)}),[b,i,f]),h=Object(u.useCallback)((function(){var t=e.current.ownerDocument,n=t.defaultView;t.removeEventListener("selectionchange",O),n.removeEventListener("mouseup",h),p.current=n.requestAnimationFrame((function(){O({isSelectionEnd:!0}),d()}))}),[O,d]);return Object(u.useEffect)((function(){var t=e.current.ownerDocument,n=t.defaultView;return function(){t.removeEventListener("selectionchange",O),n.removeEventListener("mouseup",h),n.cancelAnimationFrame(p.current)}}),[O,h]),Object(u.useCallback)((function(t){if(n){var r=e.current.ownerDocument,o=r.defaultView;m.current=t,g.current=r.activeElement,s(),r.addEventListener("selectionchange",O),o.addEventListener("mouseup",h),po(e.current,!1)}}),[n,s,h])}(t),s=Object(u.useState)({}),d=Object(ie.a)(s,2),b=d[0],p=d[1];return Object(u.createElement)(js,{containerRef:t},Object(u.createElement)(ju.Provider,{value:b},Object(u.createElement)(Ou,null),Object(u.createElement)("div",{ref:t,className:f()(r,"is-root-container"),onFocus:function(e){if(!i){var t=et(e.target);t&&t!==c&&a(t)}},onDragStart:_u},Object(u.createElement)(ku.Provider,{value:p},Object(u.createElement)(hu.Provider,{value:l},n)))))})),Cu=["p","div","h1","h2","h3","h4","h5","h6","ol","ul","li","figure","nav","pre","header","section","aside","footer","main"];function wu(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 Su(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?wu(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Iu(){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)(hu),i=Object(u.useContext)(ku),a=Object(u.useContext)(Nu),l=a.clientId,d=a.rootClientId,p=a.isSelected,m=a.isFirstMultiSelected,g=a.isLastMultiSelected,h=a.isPartOfMultiSelection,j=a.enableAnimation,k=a.index,y=a.className,_=a.name,E=a.mode,C=a.blockTitle,w=a.wrapperProps,S=void 0===w?{}:w,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(ie.a)(R,2),M=A[0],L=A[1];Object(u.useEffect)((function(){if(p||m||g){var e=o.current;return i((function(t){return Su(Su({},t),{},s({},l,e))})),function(){i((function(e){return Object(b.omit)(e,l)}))}}}),[p,m,g]),Object(u.useEffect)((function(){var e=o.current;i((function(t){return t[l]&&t[l]!==e?Su(Su({},t),{},s({},l,e)):t}))}));// translators: %s: Type of block (i.e. Text, Image etc)
|
58 |
-
var F=Object(O.sprintf)(Object(O.__)("Block: %s"),C),V=function(){var e=o.current.ownerDocument;if(!e.activeElement||!Je(o.current,e.activeElement)){var t=xr.focus.tabbable.find(o.current).filter((function(e){return Object(xr.isTextField)(e)&&Je(o.current,e)&&!e.closest(".block-list-appender")})),n=-1===B,r=(n?b.last:b.first)(t)||o.current;Object(xr.placeCaretAtHorizontalEdge)(r,n)}};Object(u.useEffect)((function(){x&&V()}),[x]),Nr(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!==pt.ENTER&&t!==pt.BACKSPACE&&t!==pt.DELETE||n!==o.current||Object(xr.isTextField)(n)||(e.preventDefault(),t===pt.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 Su(Su(Su({},S),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:f()(y,e.className,S.className,{"is-hovered":M}),style:Su(Su({},S.style),e.style)})}Iu.save=c.__unstableGetBlockProps;var Bu=Object(u.forwardRef)((function(e,t){var n=e.children,r=e.tagName,o=void 0===r?"div":r,c=Object(Ee.a)(e,["children","tagName"]);uo()("wp.blockEditor.__experimentalBlock",{alternative:"wp.blockEditor.useBlockProps"});var i=Iu(Su(Su({},c),{},{ref:t}));return Object(u.createElement)(o,i,n)})),xu=Cu.reduce((function(e,t){return e[t]=Object(u.forwardRef)((function(e,n){return Object(u.createElement)(Bu,Object(l.a)({},e,{ref:n,tagName:t}))})),e}),Bu);function Pu(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 Tu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Pu(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Nu=Object(u.createContext)();function Du(e){var t=e.children,n=e.isHtml,r=Object(Ee.a)(e,["children","isHtml"]);return Object(u.createElement)("div",Iu(r,{__unstableIsHtml:n}),t)}var Ru=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,f=o.isSelectionEnabled,b=o.hasSelectedInnerBlock,p=o.getTemplateLock,m=o.__unstableGetBlockWithoutInnerBlocks,v=o.getMultiSelectedBlockClientIds,g=m(n),O=c(n),h=p(r),j=b(n,!0),k=g||{},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:(O||j)&&u(),mode:d(n),isSelectionEnabled:f(),isLocked:!!h,block:g,name:y,attributes:_,isValid:E,isSelected:O,isAncestorOfSelectedBlock:j}})),Au=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)}}})),Mu=Object(p.compose)(p.pure,Ru,Au,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,g=e.isPartOfMultiSelection,O=e.isFirstMultiSelected,h=e.isLastMultiSelected,j=e.isTypingWithinBlock,k=e.isAncestorOfSelectedBlock,y=e.isSelectionEnabled,_=e.className,E=e.name,C=e.isValid,w=e.attributes,S=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(ie.a)(U,2),
|
59 |
/* translators: 1: The numerical position of the block. 2: The total number of blocks. 3. The level of nesting for the block. */
|
60 |
-
Object(O.__)("Block %1$d of %2$d, Level %3$d"),e,t,n)};var Fu=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,b=t.tabIndex,m=t.onFocus,v=t.onDragStart,g=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),w="block-navigation-block-select-button__".concat(C),S=Lu(l,s,d);return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.Button,{className:f()("block-editor-block-navigation-block-select-button",r),onClick:a,"aria-describedby":w,ref:n,tabIndex:b,onFocus:m,onDragStart:v,onDragEnd:g,draggable:j},Object(u.createElement)(tr,{icon:_.icon,showColors:!0}),E,i&&Object(u.createElement)(h.VisuallyHidden,null,Object(O.__)("(selected block)"))),Object(u.createElement)("div",{className:"block-editor-block-navigation-block-select-button__description",id:w},S))}));function Vu(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 Hu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Vu(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var zu=function(e){return"BlockNavigationBlock-".concat(e)};var Uu=Object(u.forwardRef)((function e(t,n){var r=Object(p.useInstanceId)(e),o=t.block.clientId;return Object(u.createElement)(h.Slot,{name:zu(o)},(function(e){if(!e.length)return Object(u.createElement)(Fu,Object(l.a)({ref:n},t));var o=t.className,i=t.block,a=t.isSelected,s=t.position,d=t.siblingBlockCount,b=t.level,p=t.tabIndex,m=t.onFocus,v=i.name,g=Object(c.getBlockType)(v),j="block-navigation-block-slot__".concat(r),k=Lu(s,d,b),y={tabIndex:p,onFocus:m,ref:n,"aria-describedby":j};return Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{className:f()("block-editor-block-navigation-block-slot",o)},Object(u.createElement)(tr,{icon:g.icon,showColors:!0}),u.Children.map(e,(function(e){return Object(u.cloneElement)(e,Hu(Hu({},e.props),y))})),a&&Object(u.createElement)(h.VisuallyHidden,null,Object(O.__)("(selected block)")),Object(u.createElement)("div",{className:"block-editor-block-navigation-block-slot__description",id:j},k)))}))})),Gu=function(e){var t=Object(u.useContext)(Nu).clientId;return Object(u.createElement)(h.Fill,Object(l.a)({},e,{name:zu(t)}))},
|
61 |
/* translators: 1: The numerical position of the block that will be inserted. 2: The level of nesting for the block that will be inserted. */
|
62 |
-
Object(O.__)("Add block at position %1$d, Level %2$d"),n,r);return Object(u.createElement)(Rr,{className:f()({"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)(
|
63 |
-
/* translators: button label text should, if possible, be under 16 characters. */,label:Object(O.__)("Outline"),className:"block-editor-block-navigation",shortcut:i,"aria-disabled":!t}))}var cd=Object(u.forwardRef)((function(e,t){var n=e.isDisabled,r=e.__experimentalFeatures,o=Object(Ee.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)(od,Object(l.a)({},o,{innerRef:t,isOpen:n,onToggle:r,isEnabled:c}))},renderContent:function(e){var t=e.onClose;return Object(u.createElement)(nd,{onSelect:t,__experimentalFeatures:r})}})})),id=n(126),ad=[pt.rawShortcut.primary("z"),pt.rawShortcut.primaryShift("z"),pt.rawShortcut.primary("y")],ld=Object(u.createElement)(h.KeyboardShortcuts,{bindGlobal:!0,shortcuts:Object(b.fromPairs)(ad.map((function(e){return[e,function(e){return e.preventDefault()}]})))}),sd=function(){return ld};function ud(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(Us.createBlobURL)(e),'">')})).join("")}var dd={position:"bottom right",isAlternate:!0},fd=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:Fr.a,label:Object(O.__)("More rich text controls"),toggleProps:t,controls:Object(b.orderBy)(e.map((function(e){return Object(ie.a)(e,1)[0].props})),"title"),popoverProps:dd})}))}))))},bd=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)(fd,null)):Object(u.createElement)(_r,null,Object(u.createElement)(fd,null))};function pd(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 md(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?pd(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function vd(e){if(!0===e||"p"===e||"li"===e)return!0===e?"p":e}function gd(e){var t=e.allowedFormats,n=e.formattingControls;return e.disableFormats?gd.EMPTY_ARRAY:t||n?t||(uo()("wp.blockEditor.RichText formattingControls prop",{alternative:"allowedFormats"}),n.map((function(e){return"core/".concat(e)}))):void 0}gd.EMPTY_ARRAY=[];var Od=Object(u.forwardRef)((function e(t,n){var r=t.children,o=t.tagName,a=t.value,s=t.onChange,d=t.isSelected,b=t.multiline,m=t.inlineToolbar,g=t.wrapperClassName,O=t.autocompleters,h=t.onReplace,j=t.placeholder,k=t.keepPlaceholderOnFocus,y=t.allowedFormats,_=t.formattingControls,E=t.withoutInteractiveFormatting,C=t.onRemove,w=t.onMerge,S=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(Ee.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"]),ne=Object(p.useInstanceId)(e);x=x||ne;var re=Object(u.useRef)(),oe=n||re,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,f=n.isMultiSelecting,b=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 g={};if("native"===u.Platform.OS){var O=le&&s(le);g={shouldBlurOnUnmount:O&&t&&Object(c.isUnmodifiedDefaultBlock)(O)}}return md({isCaretWithinFormattedText:r(),selectionStart:t?p.offset:void 0,selectionEnd:t?m.offset:void 0,isSelected:t,didAutomaticChange:l(),disabled:f()||b(),undo:v},g)})),fe=de.isCaretWithinFormattedText,be=de.selectionStart,pe=de.selectionEnd,me=de.isSelected,ve=de.didAutomaticChange,ge=de.disabled,Oe=de.undo,he=de.shouldBlurOnUnmount,je=Object(v.useDispatch)("core/block-editor"),ke=je.__unstableMarkLastChangeAsPersistent,ye=je.enterFormattedText,_e=je.exitFormattedText,Ce=je.selectionChange,we=je.__unstableMarkAutomaticChange,Se=vd(b),Ie=gd({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;w&&w(!n),C&&Object(i.isEmpty)(t)&&n&&C(!n)}),[w,C]),De=Object(u.useCallback)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if(h&&S){var n=[],r=Object(i.split)(e),o=Object(ie.a)(r,2),c=o[0],a=o[1],l=t.length>0,s=-1;l&&Object(i.isEmpty)(c)||(n.push(S(Object(i.toHTMLString)({value:c,multilineTag:Se}))),s+=1),l?(n.push.apply(n,ce(t)),s+=t.length):B&&n.push(B()),(l||B)&&Object(i.isEmpty)(a)||n.push(S(Object(i.toHTMLString)({value:a,multilineTag:Se})));var u=l?s:1,d=l?-1:null;h(n,u,d)}}),[h,S,Se,B]),Re=Object(u.useCallback)((function(e){var t=e.value,n=e.onChange,r=e.shiftKey,o=h&&S;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})]),we())}if(b)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,f=I&&u===d&&d===s.length;r||!o&&!f?D||n(Object(i.insert)(t,"\n")):!o&&f?I():o&&De(t)}}),[h,S,we,b,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:ud(l),mode:"BLOCKS",tagName:o});return window.console.log("Received items:\n\n",l),void(h&&Object(i.isEmpty)(t)?h(u):De(t,u))}var d,f=h&&S?"AUTO":"INLINE";"AUTO"===f&&Object(i.isEmpty)(t)&&(d=a,Object(id.regexp)(".*").test(d))&&(f="BLOCKS"),T&&Object(i.isEmpty)(t)&&Object($l.isURL)(a.trim())&&(f="BLOCKS");var p=Object(c.pasteHandler)({HTML:r,plainText:a,mode:f,tagName:o});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(ce(s),ce(m.formats[v]||[]));b&&(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,S,De,T,b]),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]),we()}}}}),[h,we]),Le=Object(u.createElement)(i.__experimentalRichText,{clientId:le,identifier:x,ref:oe,value:xe,onChange:Pe,selectionStart:be,selectionEnd:pe,onSelectionChange:Te,tagName:o,placeholder:j,allowedFormats:Ie,withoutInteractiveFormatting:E,onEnter:Re,onDelete:Ne,onPaste:Ae,__unstableIsSelected:me,__unstableInputRule:Me,__unstableMultilineTag:Se,__unstableIsCaretWithinFormattedText:fe,__unstableOnEnterFormattedText:ye,__unstableOnExitFormattedText:_e,__unstableOnCreateUndoLevel:ke,__unstableMarkAutomaticChange:we,__unstableDidAutomaticChange:ve,__unstableUndo:Oe,__unstableDisableFormats:N,preserveWhiteSpace:P,disabled:ge,unstableOnFocus:R,__unstableAllowPrefixTransformations:A,__unstableMultilineRootTag:M,onCaretVerticalPositionChange:se,blockIsSelected:void 0!==d?d:ue,shouldBlurOnUnmount:he,__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)(bd,{inline:m,anchorRef:oe.current}),t&&Object(u.createElement)(sd,null),Object(u.createElement)(or,{onReplace:h,completers:O,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?md(md({},te.style),i.style):i.style,className:f()("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 g?(uo()("wp.blockEditor.RichText wrapperClassName prop",{alternative:"className prop or create your own wrapper div"}),Object(u.createElement)("div",{className:f()("block-editor-rich-text",g)},Le)):Le}));Od.Content=function(e){var t=e.value,n=e.tagName,r=e.multiline,o=Object(Ee.a)(e,["value","tagName","multiline"]);Array.isArray(t)&&(t=c.children.toHTML(t));var i=vd(r);!t&&i&&(t="<".concat(i,"></").concat(i,">"));var a=Object(u.createElement)(u.RawHTML,null,t);return n?Object(u.createElement)(n,Object(b.omit)(o,["format"]),a):a},Od.isEmpty=function(e){return!e||0===e.length},Od.Content.defaultProps={format:"string",value:""};var hd=Od;function jd(e){var t=e.value,n=e.onChange;return Object(u.createElement)(Gu,null,Object(u.createElement)(hd,{value:t,onChange:n,placeholder:Object(O.__)("Navigation item"),keepPlaceholderOnFocus:!0,withoutInteractiveFormatting:!0,allowedFormats:["core/bold","core/italic","core/image","core/strikethrough"]}))}var kd=n(299);var yd=function(e){var t=e.icon,n=void 0===t?kd.a:t,r=e.label,o=void 0===r?Object(O.__)("Choose variation"):r,c=e.instructions,i=void 0===c?Object(O.__)("Select a variation to start with."):c,a=e.variations,l=e.onSelect,s=e.allowSkip,d=f()("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(O.__)("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(O.__)("Skip"))))},_d=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"})),Ed=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 Cd(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 wd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Cd(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Sd={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(O._x)("Vertically Align Top","Block vertical alignment setting")},center:{icon:Ed,title:Object(O._x)("Vertically Align Middle","Block vertical alignment setting")},bottom:{icon:_d,title:Object(O._x)("Vertically Align Bottom","Block vertical alignment setting")}},Id=["top","center","bottom"],Bd={isAlternate:!0};var xd=function(e){var t=e.value,n=e.onChange,r=e.controls,o=void 0===r?Id:r,c=e.isCollapsed,i=void 0===c||c,a=Sd[t],l=Sd.top;return Object(u.createElement)(h.ToolbarGroup,{popoverProps:Bd,isCollapsed:i,icon:a?a.icon:l.icon,label:Object(O._x)("Change vertical alignment","Block vertical alignment setting label"),controls:o.map((function(e){return wd(wd({},Sd[e]),{},{isActive:t===e,role:i?"menuitemradio":void 0,onClick:(r=e,function(){return n(t===r?void 0:r)})});var r}))})};function Pd(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 Td(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Pd(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Nd=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=ve("color.palette"),r=!ve("color.custom"),o=void 0===t.colors?n:t.colors,c=void 0===t.disableCustomColors?r:t.disableCustomColors,i=!Object(b.isEmpty)(o)||!c;return Object(u.createElement)(e,Td(Td({},t),{},{colors:o,disableCustomColors:c,hasColorsToChoose:i}))}}),"withColorContext"),Dd=Nd(h.ColorPalette);function Rd(e){var t=e.onChange,n=e.value,r=Object(Ee.a)(e,["onChange","value"]);return Object(u.createElement)(Ne,Object(l.a)({},r,{onColorChange:t,colorValue:n,gradients:[],disableCustomGradients:!0}))}var Ad=[];function Md(e){var t=ve("color.gradients")||Ad,n=!ve("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 Ld=function(e){var t=void 0!==e.gradients&&void 0!==e.disableCustomGradients?h.__experimentalGradientPicker:Md;return Object(u.createElement)(t,e)};function Fd(e){var t=e.className,n=e.value,r=e.onChange,o=e.label,c=void 0===o?Object(O.__)("Gradient Presets"):o,i=Object(Ee.a)(e,["className","value","onChange","label"]),a=ve("color.gradients"),s=!ve("color.customGradient");return Object(b.isEmpty)(a)&&s?null:Object(u.createElement)(h.BaseControl,{className:f()("block-editor-gradient-picker-control",t)},Object(u.createElement)(h.BaseControl.VisualLabel,null,c),Object(u.createElement)(Ld,Object(l.a)({value:n,onChange:r,className:"block-editor-gradient-picker-control__gradient-picker-presets",gradients:a,disableCustomGradients:s},i)))}function Vd(e){var t=ve("color.gradients");return Object(b.isEmpty)(t)?null:Object(u.createElement)(h.PanelBody,{title:Object(O.__)("Gradient")},Object(u.createElement)(Fd,e))}var Hd=[25,50,75,100];function zd(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,f=e.height,p=e.onChange,m=e.onChangeImage,v=void 0===m?b.noop:m;function g(e,t){return function(){p({width:e,height:t})}}return Object(u.createElement)(u.Fragment,null,!Object(b.isEmpty)(i)&&Object(u.createElement)(h.SelectControl,{label:Object(O.__)("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(O.__)("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(O.__)("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(O.__)("Height"),value:null!==(n=null!=f?f: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(O.__)("Image size presets")},Hd.map((function(e){var t=Math.round(r*(e/100)),n=Math.round(o*(e/100)),c=d===t&&f===n;return Object(u.createElement)(h.Button,{key:e,isSmall:!0,isPrimary:c,isPressed:c,onClick:g(t,n)},e,"%")}))),Object(u.createElement)(h.Button,{isSmall:!0,onClick:g()},Object(O.__)("Reset")))))}var Ud=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"),Gd=Ud((function(e){var t=e.clientId,n=e.showSeparator,r=e.isFloating,o=e.onAddBlock;return Object(u.createElement)(rl,{rootClientId:t,showSeparator:n,isFloating:r,onAddBlock:o})})),Kd=Object(p.compose)([Ud,Object(v.withSelect)((function(e,t){var n=t.clientId,r=(0,e("core/block-editor").getBlockOrder)(n);return{lastBlockClientId:Object(b.last)(r)}}))])((function(e){var t=e.clientId,n=e.lastBlockClientId;return Object(u.createElement)(nl,{rootClientId:t,lastBlockClientId:n})})),Wd=n(73),qd=n.n(Wd);var $d=new WeakMap;function Yd(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 Xd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yd(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Qd(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,f=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),qd()(a,i)||c(e,i)}),[e,a,t,n,l,r,o,c])}(t,n,o,l,f),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(b.isEqual)(t,a.current)){a.current=t;var l=Object(c.synchronizeBlocksWithTemplate)(i,t);Object(b.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){$d.has(t)||$d.set(t,new WeakMap);var n=$d.get(t);if(!n.has(e)){var r=Object(b.mapValues)(t.providesContext,(function(t){return e[t]}));n.set(e,r)}return n.get(e)}(n.attributes,r)}),[t]);return Object(u.createElement)(dr,{value:m},Object(u.createElement)(gl,{rootClientId:t,renderAppender:d,__experimentalAppenderTagName:s,wrapperRef:i,placeholder:p}))}function Zd(e){return Ja(e),Object(u.createElement)(Qd,e)}var Jd=Object(u.forwardRef)((function(e,t){var n=ef({ref:t},e);return Object(u.createElement)("div",{className:"block-editor-inner-blocks"},Object(u.createElement)("div",n))}));function ef(){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?Zd:Qd;return Xd(Xd({},e),{},{ref:a,className:f()(e.className,"block-editor-block-list__layout",{"has-overlay":i}),children:Object(u.createElement)(s,Object(l.a)({},t,{clientId:o,wrapperRef:a}))})}Jd.DefaultBlockAppender=Kd,Jd.ButtonBlockAppender=Gd,Jd.Content=Object(c.withBlockContentContext)((function(e){var t=e.BlockContent;return Object(u.createElement)(t,null)}));var tf=Jd,nf=n(217);function rf(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 of(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rf(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var cf=[{id:"opensInNewTab",title:Object(O.__)("Open in new tab")}],af=function(e){var t=e.value,n=e.onChange,r=void 0===n?b.noop:n,o=e.settings,c=void 0===o?cf:o;if(!c||!c.length)return null;var i=function(e){return function(n){r(of(of({},t),{},s({},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(O.__)("Currently selected link settings")),a)},lf=n(123),sf=n.n(lf);function uf(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var df=function(e){return e.stopPropagation()},ff=function(e){Jt(n,e);var t=uf(n);function n(e){var r;return $t(this,n),(r=t.call(this,e)).onChange=r.onChange.bind(Qt(r)),r.onFocus=r.onFocus.bind(Qt(r)),r.onKeyDown=r.onKeyDown.bind(Qt(r)),r.selectLink=r.selectLink.bind(Qt(r)),r.handleOnClick=r.handleOnClick.bind(Qt(r)),r.bindSuggestionNode=r.bindSuggestionNode.bind(Qt(r)),r.autocompleteRef=e.autocompleteRef||Object(u.createRef)(),r.inputRef=Object(u.createRef)(),r.updateSuggestions=Object(b.throttle)(r.updateSuggestions.bind(Qt(r)),200),r.suggestionNodes=[],r.isUpdatingSuggestions=!1,r.state={suggestions:[],showSuggestions:!1,selectedSuggestion:null,suggestionsListboxId:"",suggestionOptionIdPrefix:""},r}return Xt(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,sf()(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($l.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(O.sprintf)(
|
64 |
/* translators: %s: number of results. */
|
65 |
Object(O._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(O.__)("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 pt.UP:e.stopPropagation(),e.preventDefault();var a=r?r-1:o.length-1;this.setState({selectedSuggestion:a});break;case pt.DOWN:e.stopPropagation(),e.preventDefault();var l=null===r||r===o.length-1?0:r+1;this.setState({selectedSuggestion:l});break;case pt.TAB:null!==this.state.selectedSuggestion&&(this.selectLink(i),this.props.speak(Object(O.__)("Link selected.")));break;case pt.ENTER:null!==this.state.selectedSuggestion&&(e.stopPropagation(),this.selectLink(i))}}else switch(e.keyCode){case pt.UP:0!==e.target.selectionStart&&(e.stopPropagation(),e.preventDefault(),e.target.setSelectionRange(0,0));break;case pt.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(O.__)("Paste URL or type to search"):c,a=e.__experimentalRenderControl,l=e.value,s=void 0===l?"":l,d=e.autoFocus,b=void 0===d||d,p=this.state,m=p.loading,v=p.showSuggestions,g=p.selectedSuggestion,j=p.suggestionsListboxId,k=p.suggestionOptionIdPrefix,y={id:"url-input-control-".concat(o),label:t,className:f()("block-editor-url-input",n,{"is-full-width":r})},_={value:s,required:!0,autoFocus:b,className:"block-editor-url-input__input",type:"text",onChange:this.onChange,onFocus:this.onFocus,onInput:df,placeholder:i,onKeyDown:this.onKeyDown,role:"combobox","aria-label":Object(O.__)("URL"),"aria-expanded":v,"aria-autocomplete":"list","aria-owns":j,"aria-activedescendant":null!==g?"".concat(k,"-").concat(g):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,g=s.suggestionOptionIdPrefix,O=s.loading,j={id:v,ref:this.autocompleteRef,role:"listbox"},k=function(t,n){return{role:"option",tabIndex:"-1",id:"".concat(g,"-").concat(n),ref:e.bindSuggestionNode(n),"aria-selected":n===m}};return Object(b.isFunction)(r)&&d&&p.length?r({suggestions:p,selectedSuggestion:m,suggestionsListProps:j,buildSuggestionItemProps:k,isLoading:O,handleSuggestionClick:this.handleOnClick,isInitialSuggestions:a&&!(c&&c.length)}):!Object(b.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:f()("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:f()("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),bf=Object(p.compose)(p.withSafeTimeout,h.withSpokenMessages,p.withInstanceId,Object(v.withSelect)((function(e,t){if(!Object(b.isFunction)(t.__experimentalFetchLinkSuggestions))return{__experimentalFetchLinkSuggestions:(0,e("core/block-editor").getSettings)().__experimentalFetchLinkSuggestions}})))(ff),pf=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"})),mf=function(e){var t,n=e.searchTerm,r=e.onClick,o=e.itemProps,c=e.isSelected,i=e.buttonText;return n?(t=i?Object(b.isFunction)(i)?i(n):i:Object(u.createInterpolateElement)(Object(O.sprintf)(
|
66 |
/* translators: %s: search term. */
|
67 |
Object(O.__)("Create: <mark>%s</mark>"),n),{mark:Object(u.createElement)("mark",null)}),Object(u.createElement)(h.Button,Object(l.a)({},o,{className:f()("block-editor-link-control__search-create block-editor-link-control__search-item",{"is-selected":c}),onClick:r}),Object(u.createElement)(ho.a,{className:"block-editor-link-control__search-item-icon",icon:pf}),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},vf=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"})),gf=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,b=e.shouldShowType,p=void 0!==b&&b;return Object(u.createElement)(h.Button,Object(l.a)({},t,{onClick:c,className:f()("block-editor-link-control__search-item",{"is-selected":o,"is-url":a,"is-entity":!a})}),a&&Object(u.createElement)(ho.a,{className:"block-editor-link-control__search-item-icon",icon:vf}),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($l.filterURLForDisplay)(Object($l.safeDecodeURI)(n.url))||""),a&&Object(O.__)("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 Of(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,b=e.isInitialSuggestions,p=e.createSuggestionButtonText,m=e.suggestionsQuery,v=f()("block-editor-link-control__search-results",{"is-loading":d}),g=["url","mailto","tel","internal"],j=1===a.length&&g.includes(a[0].type.toLowerCase()),k=n&&!j&&!b,y=!(null==m?void 0:m.type),_="block-editor-link-control-search-results-label-".concat(t),E=b?Object(O.__)("Recently updated"):Object(O.sprintf)(
|
68 |
/* translators: %s: search term. */
|
69 |
-
Object(O.__)('Search results for "%s"'),r),C=Object(u.createElement)(b?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)(mf,{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)(gf,{key:"".concat(e.id,"-").concat(e.type),itemProps:i(e,t),suggestion:e,index:t,onClick:function(){o(e)},isSelected:t===s,isURL:g.includes(e.type.toLowerCase()),searchTerm:r,shouldShowType:y})}))))}function hf(e){var t=Object(b.startsWith)(e,"#");return Object($l.isURL)(e)||e&&e.includes("www.")||t}function jf(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 kf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?jf(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var yf=function(){return Promise.resolve([])},_f=function(e){var t="URL",n=Object($l.getProtocol)(e)||"";return n.includes("mailto")&&(t="mailto"),n.includes("tel")&&(t="tel"),Object(b.startsWith)(e,"#")&&(t="internal"),Promise.resolve([{id:e,title:e,url:"URL"===t?Object($l.prependHTTP)(e):e,type:t}])},Ef=function(){var e=Sr(Cr.a.mark((function e(t,n,r,o,c,i){var a,l,s;return Cr.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",hf(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 Cf(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 wf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Cf(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Sf=Promise.resolve([]),If=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,f=void 0!==d&&d,m=e.onCreateSuggestion,g=void 0===m?b.noop:m,h=e.onChange,j=void 0===h?b.noop:h,k=e.onSelect,y=void 0===k?b.noop:k,_=e.showSuggestions,E=void 0===_||_,C=e.renderSuggestions,w=void 0===C?function(e){return Object(u.createElement)(Of,e)}:C,S=e.fetchSuggestions,I=void 0===S?null:S,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?_f:yf;return Object(u.useCallback)((function(t,i){var a=i.isInitialSuggestions;return hf(t)?c(t,{isInitialSuggestions:a}):Ef(t,kf(kf({},e),{},{isInitialSuggestions:a}),o,c,n,r)}),[c,o,n])}(D,x,f,A),F=E?I||L:Sf,V=Object(p.useInstanceId)(If),H=Object(u.useState)(),z=Object(ie.a)(H,2),U=z[0],G=z[1],K=function(){var e=Sr(Cr.a.mark((function e(t){var n,r;return Cr.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,g(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(wf(wf({},Object(b.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)(bf,{className:a,value:n,onChange:function(e,t){j(e),G(t)},placeholder:null!=s?s:Object(O.__)("Search or type url"),__experimentalRenderSuggestions:E?function(e){return w(wf(wf({},e),{},{instanceId:V,withCreateSuggestion:f,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)})),Bf=If,xf=Object(h.createSlotFill)("BlockEditorLinkControlViewer"),Pf=xf.Slot,Tf=xf.Fill;function Nf(e){var t=e.value,n=e.onEditClick,r=t&&Object($l.filterURLForDisplay)(Object($l.safeDecodeURI)(t.url))||"";return Object(u.createElement)("div",{"aria-label":Object(O.__)("Currently selected"),"aria-selected":"true",className:f()("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(O.__)("Edit")),Object(u.createElement)(Pf,{fillProps:t}))}var Df=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 Rf(e){var t=e.searchInputPlaceholder,n=e.value,r=e.settings,o=e.onChange,c=void 0===o?b.noop:o,i=e.noDirectEntry,a=void 0!==i&&i,l=e.showSuggestions,s=void 0===l||l,d=e.showInitialSuggestions,f=e.forceIsEditingLink,p=e.createSuggestion,m=e.withCreateSuggestion,v=e.inputValue,g=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)(),w=Object(u.useState)(n&&n.url||""),S=Object(ie.a)(w,2),I=S[0],B=S[1],x=g||I,P=Object(u.useState)(void 0!==f?f:!n||!n.url),T=Object(ie.a)(P,2),N=T[0],D=T[1],R=Object(u.useRef)(!1);Object(u.useEffect)((function(){void 0!==f&&f!==N&&D(f)}),[f]),Object(u.useEffect)((function(){R.current&&C.current&&!C.current.contains(C.current.ownerDocument.activeElement)&&(xr.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(ie.a)(n,2),o=r[0],c=r[1],i=Object(u.useState)(null),a=Object(ie.a)(i,2),l=a[0],s=a[1],d=function(){var n=Sr(Cr.a.mark((function n(r){return Cr.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return c(!0),s(null),n.prev=2,t.current=Df(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(O.__)("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(O.__)("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)(Bf,{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(O.__)("Submit"),icon:nf.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)(Nf,{value:n,onEditClick:function(){return D(!0)}}),Object(u.createElement)(af,{value:n,settings:r,onChange:c}))}Rf.ViewerFill=Tf;var Af=Rf,Mf=n(300),Lf=n(218),Ff=Object(h.withFilters)("editor.MediaUpload")((function(){return null}));var Vf=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},Hf=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?b.noop:a,s=e.name,d=void 0===s?Object(O.__)("Replace"):s,f=e.createNotice,p=e.removeNotice,m=Object(u.useState)(t),g=Object(ie.a)(m,2),j=g[0],k=g[1],y=Object(v.useSelect)((function(e){return e("core/block-editor").getSettings().mediaUpload}),[]),_=Object(u.createRef)(),E=Object(b.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(){f("error",n,{speak:!0,id:E,isDismissible:!0})}),1e3)},w=function(e){c(e),k(e.url),Object(Ue.speak)(Object(O.__)("The media file has been replaced")),p(E)},S=function(e){e.keyCode===pt.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:S},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)(Ff,{value:n,onSelect:function(e){return w(e)},allowedTypes:r,render:function(e){var t=e.open;return Object(u.createElement)(h.MenuItem,{icon:Mf.a,onClick:t},Object(O.__)("Open Media Library"))}}),Object(u.createElement)(Vf,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(ie.a)(e,1)[0];w(t)},onError:C})}(e)},accept:o,render:function(e){var t=e.openFileDialog;return Object(u.createElement)(h.MenuItem,{icon:Lf.a,onClick:function(){t()}},Object(O.__)("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(O.__)("Current media URL:")),Object(u.createElement)(Af,{value:{url:j},settings:[],showSuggestions:!1,onChange:function(e){var t=e.url;k(t),i(t),_.current.focus()}})))}})})),zf=n(200);function Uf(e){var t=e.url,n=e.urlLabel,r=e.className,o=f()(r,"block-editor-url-popover__link-viewer-url");return t?Object(u.createElement)(h.ExternalLink,{className:o,href:t},n||Object($l.filterURLForDisplay)(Object($l.safeDecodeURI)(t))):Object(u.createElement)("span",{className:o})}function Gf(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(Ee.a)(e,["additionalControls","children","renderSettings","position","focusOnMount"]),d=Object(u.useState)(!1),f=Object(ie.a)(d,2),b=f[0],p=f[1],m=!!r&&b;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:Fr.a,label:Object(O.__)("Link settings"),onClick:function(){p(!b)},"aria-expanded":b})),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))}Gf.LinkEditor=function(e){var t=e.autocompleteRef,n=e.className,r=e.onChangeInputValue,o=e.value,c=Object(Ee.a)(e,["autocompleteRef","className","onChangeInputValue","value"]);return Object(u.createElement)("form",Object(l.a)({className:f()("block-editor-url-popover__link-editor",n)},c),Object(u.createElement)(bf,{value:o,onChange:r,autocompleteRef:t}),Object(u.createElement)(h.Button,{icon:nf.a,label:Object(O.__)("Apply"),type:"submit"}))},Gf.LinkViewer=function(e){var t=e.className,n=e.linkClassName,r=e.onEditLinkClick,o=e.url,c=e.urlLabel,i=Object(Ee.a)(e,["className","linkClassName","onEditLinkClick","url","urlLabel"]);return Object(u.createElement)("div",Object(l.a)({className:f()("block-editor-url-popover__link-viewer",t)},i),Object(u.createElement)(Uf,{url:o,urlLabel:c,className:n}),r&&Object(u.createElement)(h.Button,{icon:zf.a,label:Object(O.__)("Edit"),onClick:r}))};var Kf=Gf,Wf=function(e){var t=e.src,n=e.onChange,r=e.onSubmit,o=e.onClose;return Object(u.createElement)(Kf,{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(O.__)("URL"),placeholder:Object(O.__)("Paste or type URL"),onChange:n,value:t}),Object(u.createElement)(h.Button,{className:"block-editor-media-placeholder__url-input-submit-button",icon:nf.a,label:Object(O.__)("Apply"),type:"submit"})))};var qf=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,g=e.multiple,j=void 0!==g&&g,k=e.dropZoneUIOnly,y=e.disableDropZone,_=e.disableMediaButtons,E=e.onError,C=e.onSelect,w=e.onCancel,S=e.onSelectURL,I=e.onDoubleClick,B=e.onFilesPreUpload,x=void 0===B?b.noop:B,P=e.onHTMLDrop,T=void 0===P?b.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(ie.a)(R,2),M=A[0],L=A[1],F=Object(u.useState)(!1),V=Object(ie.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&&S&&(S(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(ie.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||S||(n=Object(O.__)("To edit this block, you need permission to upload media.")),void 0===n||void 0===i){var b=null!=r?r:[],p=Object(ie.a)(b,1)[0],m=1===b.length,v=m&&"audio"===p,g=m&&"image"===p,j=m&&"video"===p;void 0===n&&D&&(n=Object(O.__)("Upload a media file or pick one from your media library."),v?n=Object(O.__)("Upload an audio file, pick one from your media library, or add one with a URL."):g?n=Object(O.__)("Upload an image file, pick one from your media library, or add one with a URL."):j&&(n=Object(O.__)("Upload a video file, pick one from your media library, or add one with a URL."))),void 0===i&&(i=Object(O.__)("Media"),v?i=Object(O.__)("Audio"):g?i=Object(O.__)("Image"):j&&(i=Object(O.__)("Video")))}var k=f()("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 w&&Object(u.createElement)(h.Button,{className:"block-editor-media-placeholder__cancel-button",title:Object(O.__)("Cancel"),isLink:!0,onClick:w},Object(O.__)("Cancel"))},Z=function(){return S&&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(O.__)("Insert from URL")),H&&Object(u.createElement)(Wf,{src:M,onChange:U,onSubmit:W,onClose:K}))};return k||_?(k&&uo()("wp.blockEditor.MediaPlaceholder dropZoneUIOnly prop",{alternative:"disableMediaButtons"}),Object(u.createElement)(Vf,null,X())):Object(u.createElement)(Vf,{fallback:Y(Z())},function(){var e=Object(u.createElement)(Ff,{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(O.__)("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:f()("block-editor-media-placeholder__button","block-editor-media-placeholder__upload-button")},Object(O.__)("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:f()("block-editor-media-placeholder__button","block-editor-media-placeholder__upload-button"),onChange:$,accept:p,multiple:j},Object(O.__)("Upload")),e,Z(),Q());return Y(t)}return Y(e)}())})),$f=Object(u.forwardRef)((function(e,t){return Object(u.createElement)(hd,Object(l.a)({ref:t},e,{__unstableDisableFormats:!0,preserveWhiteSpace:!0}))}));$f.Content=function(e){var t=e.value,n=void 0===t?"":t,r=e.tagName,o=void 0===r?"div":r,c=Object(Ee.a)(e,["value","tagName"]);return Object(u.createElement)(o,c,n)};var Yf=$f,Xf=Object(u.forwardRef)((function(e,t){var n=e.__experimentalVersion,r=Object(Ee.a)(e,["__experimentalVersion"]);if(2===n)return Object(u.createElement)(Yf,Object(l.a)({ref:t},r));var o=r.className,c=r.onChange,i=Object(Ee.a)(r,["className","onChange"]);return Object(u.createElement)(ao.a,Object(l.a)({ref:t,className:f()("block-editor-plain-text",o),onChange:function(e){return c(e.target.value)}},i))}));function Qf(e){var t=e.property,n=e.viewport,r=e.desc,o=Object(p.useInstanceId)(Qf),c=r||Object(O.sprintf)(
|
70 |
/* translators: 1: property name. 2: viewport name. */
|
71 |
Object(O._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 Zf=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",
|
72 |
/* translators: 'Label. Used to signify a layout property (eg: margin, padding) will apply uniformly to all screensizes.' */
|
@@ -74,10 +74,10 @@ label:Object(O.__)("All")}:s,b=e.viewports,p=void 0===b?[{id:"small",label:Objec
|
|
74 |
/* translators: 'Toggle control label. Should the property be the same across all screen sizes or unique per screen size.'. %s property value for the control (eg: margin, padding...etc) */
|
75 |
Object(O.__)("Use the same %s on all screensizes."),n),v=Object(O.__)("Toggle between using the same value for all screen sizes or using a unique value per screen size."),g=c(Object(u.createElement)(Qf,{property:n,viewport:d}),d);
|
76 |
/* translators: 'Help text for the responsive mode toggle control.' */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:f()("block-editor-responsive-block-control__group",{"is-responsive":l})},!l&&g,l&&(i?i(p):p.map((function(e){return Object(u.createElement)(u.Fragment,{key:e.id},c(Object(u.createElement)(Qf,{property:n,viewport:e}),e))}))))))};function Jf(e){var t=e.character,n=e.type,r=e.onUse;return Object(p.useKeyboardShortcut)(pt.rawShortcut[n](t),(function(){return r(),!1}),{bindGlobal:!0}),null}function eb(e){var t,n=e.name,r=e.shortcutType,o=e.shortcutCharacter,c=Object(Ee.a)(e,["name","shortcutType","shortcutCharacter"]),i="RichText.ToolbarControls";return n&&(i+=".".concat(n)),r&&o&&(t=pt.displayShortcut[r](o)),Object(u.createElement)(h.Fill,{name:i},Object(u.createElement)(h.ToolbarButton,Object(l.a)({},c,{shortcut:t})))}function tb(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var nb=function(e){Jt(n,e);var t=tb(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).onInput=e.onInput.bind(Qt(e)),e}return Xt(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),rb=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 ob=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?rb:zf.a,"aria-expanded":o,"aria-haspopup":"true",onClick:c
|
77 |
-
/* translators: button label text should, if possible, be under 16 characters. */,label:Object(O.__)("Modes")}))},position:"bottom right",renderContent:function(){return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.NavigableMenu,{role:"menu","aria-label":Object(O.__)("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)(ho.a,{icon:zf.a}),Object(O.__)("Edit"))},{value:"select",label:Object(u.createElement)(u.Fragment,null,rb,Object(O.__)("Select"))}]})),Object(u.createElement)("div",{className:"block-editor-tool-selector__help"},Object(O.__)("Tools offer different interactions for block selection & editing. To select, press Escape, to go back to editing, press Enter.")))}})})),cb=n(192),ib=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 ab(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var lb=function(e){Jt(n,e);var t=ab(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).toggle=e.toggle.bind(Qt(e)),e.submitLink=e.submitLink.bind(Qt(e)),e.state={expanded:!1},e}return Xt(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(O.__)("Edit link"):Object(O.__)("Insert link");return Object(u.createElement)("div",{className:"block-editor-url-input__button"},Object(u.createElement)(h.Button,{icon:cb.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:ib,label:Object(O.__)("Close"),onClick:this.toggle}),Object(u.createElement)(bf,{value:t||"",onChange:n}),Object(u.createElement)(h.Button,{icon:nf.a,label:Object(O.__)("Submit"),type:"submit"}))))}}]),n}(u.Component),sb=n(128),ub=["noreferrer","noopener"],db=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"})),fb=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,f=Object(u.useState)(!1),p=Object(ie.a)(f,2),m=p[0],v=p[1],g=Object(u.useCallback)((function(){v(!0)})),j=Object(u.useState)(!1),k=Object(ie.a)(j,2),y=k[0],_=k[1],E=Object(u.useState)(null),C=Object(ie.a)(E,2),w=C[0],S=C[1],I=Object(u.useRef)(null),B=function(e){e.stopPropagation()},x=function(e){[pt.LEFT,pt.DOWN,pt.RIGHT,pt.UP,pt.BACKSPACE,pt.ENTER].indexOf(e.keyCode)>-1&&e.stopPropagation()},P=Object(u.useCallback)((function(){"media"!==t&&"attachment"!==t||S(""),_(!0)})),T=Object(u.useCallback)((function(){_(!1)})),N=Object(u.useCallback)((function(){S(null),T(),v(!1)})),D=function(e){var t=e;return void 0===e||Object(b.isEmpty)(t)||Object(b.isEmpty)(t)||(Object(b.each)(ub,(function(e){var n=new RegExp("\\b"+e+"\\b","gi");t=t.replace(n,"")})),t!==e&&(t=t.trim()),Object(b.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),S(null),T())}})),A=Object(u.useCallback)((function(){return function(e){w&&n({href:w}),T(),S(null),e.preventDefault()}})),M=Object(u.useCallback)((function(){n({linkDestination:"none",href:""})})),L=function(){var e=[{linkDestination:"media",title:Object(O.__)("Media File"),url:"image"===c?i:void 0,icon:db}];return"image"===c&&a&&e.push({linkDestination:"attachment",title:Object(O.__)("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(O.__)("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(O.__)("Link Rel"),value:D(d)||"",onChange:function(e){n({rel:e})},onKeyPress:B,onKeyDown:x}),Object(u.createElement)(h.TextControl,{label:Object(O.__)("Link CSS Class"),value:s||"",onKeyPress:B,onKeyDown:x,onChange:function(e){n({linkClass:e})}})),V=null!==w?w:r,H=(Object(b.find)(L(),["linkDestination",t])||{}).title;return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.ToolbarButton,{icon:cb.a,className:"components-toolbar__control",label:r?Object(O.__)("Edit link"):Object(O.__)("Insert link"),"aria-expanded":m,onClick:g}),m&&Object(u.createElement)(
|
78 |
/* translators: button label text should, if possible, be under 16 characters. */
|
79 |
children:Object(O.__)("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&&bb.a},Object(O.__)("Desktop")),Object(u.createElement)(h.MenuItem,{className:"block-editor-post-preview__button-resize",onClick:function(){return i("Tablet")},icon:"Tablet"===c&&bb.a},Object(O.__)("Tablet")),Object(u.createElement)(h.MenuItem,{className:"block-editor-post-preview__button-resize",onClick:function(){return i("Mobile")},icon:"Mobile"===c&&bb.a},Object(O.__)("Mobile"))),t)}))}var mb=n(266),vb=/\((min|max)-width:[^\(]*?\)/g;function gb(e){return!!e.media&&!!e.media.mediaText.match(vb)}function Ob(e,t,n){e.deleteRule(n),e.insertRule(t,n)}function hb(e,t){return e.replace(vb,(function(e){return Object(mb.match)(e,{type:"screen",width:t})?"(min-width:0px)":"(min-width:999999px)"}))}function jb(e,t){Object(u.useEffect)((function(){if(t){var n,r,o,c="undefined"==typeof window?[]:Object(b.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($l.getProtocol)(e.href)===window.location.protocol&&Object($l.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&&gb(a))){var l=a.cssText;i[r]||(i[r]=[]),i[r][c]=l,Ob(n,hb(l,t),c)}}})),function(){i.forEach((function(e,t){if(e)for(var n=0;n<e.length;++n){var r=e[n];r&&Ob(c[t],r,n)}}))}}}),[t])}function kb(e){var t=Object(u.useState)(window.innerWidth),n=Object(ie.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 jb("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 yb=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(){Ze(t).focus()}},Object(O.__)("Skip to the selected block"))})),_b=n(124);var Eb=Object(v.withSelect)((function(e){return{blocks:(0,e("core/block-editor").getMultiSelectedBlocks)()}}))((function(e){var t=e.blocks,n=Object(_b.count)(Object(c.serialize)(t),"words");return Object(u.createElement)("div",{className:"block-editor-multi-selection-inspector__card"},Object(u.createElement)(tr,{icon:Bs,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(O.sprintf)(
|
80 |
/* translators: %d: number of blocks */
|
81 |
Object(O._n)("%d block","%d blocks",t.length),t.length)),Object(u.createElement)("div",{className:"block-editor-multi-selection-inspector__card-description"},Object(O.sprintf)(
|
82 |
/* translators: %d: number of words */
|
83 |
-
Object(O._n)("%d word","%d words",n),n))))}));function Cb(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(O.__)("Not set"),value:""}].concat(ce(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(O.__)("Default Style"),onChange:a})}var wb=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(O.__)("Advanced"),initialOpen:!1},Object(u.createElement)(q.Slot,{bubblesVirtually:n})):null},Sb=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)(Eb,null),Object(u.createElement)(Qe.Slot,{bubblesVirtually:d}));var f=i===Object(c.getUnregisteredTypeHandlerName)();return t&&o&&!f?Object(u.createElement)("div",{className:"block-editor-block-inspector"},Object(u.createElement)(yo,{blockType:t}),r&&Object(u.createElement)("div",null,Object(u.createElement)(h.PanelBody,{title:Object(O.__)("Styles")},Object(u.createElement)(Rs,{clientId:o}),Object(c.hasBlockSupport)(t.name,"defaultStylePicker",!0)&&Object(u.createElement)(Cb,{blockName:t.name}))),Object(u.createElement)(Qe.Slot,{bubblesVirtually:d}),Object(u.createElement)("div",null,Object(u.createElement)(wb,{slotName:q.slotName,bubblesVirtually:d})),Object(u.createElement)(yb,{key:"back"})):l?Object(u.createElement)("span",{className:"block-editor-block-inspector__no-blocks"},Object(O.__)("No block selected.")):null}));function Ib(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 Bb=n(267),xb=n.n(Bb),Pb=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,Tb=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),b(),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 f(/^{\s*/)}function u(){return f(/^}/)}function d(){var t,n=[];for(b(),p(n);e.length&&"}"!==e.charAt(0)&&(t=C()||w());)!1!==t&&(n.push(t),p(n));return n}function f(t){var n=t.exec(e);if(n){var r=n[0];return o(r),e=e.slice(r.length),n}}function b(){f(/^\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=f(/^([^{]+)/);if(e)return Nb(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 g(){var e=c(),t=f(/^(\*?[-#\/\*\\\w]+(\[[0-9a-z_-]+\])?)\s*/);if(t){if(t=Nb(t[0]),!f(/^:\s*/))return l("property missing ':'");var n=f(/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^\)]*?\)|[^};])+)/),r=e({type:"declaration",property:t.replace(Pb,""),value:n?Nb(n[0]).replace(Pb,""):""});return f(/^[;\s]*/),r}}function O(){var e,t=[];if(!s())return l("missing '{'");for(p(t);e=g();)!1!==e&&(t.push(e),p(t));return u()?t:l("missing '}'")}function h(){for(var e,t=[],n=c();e=f(/^((\d+\.\d+|\.\d+|\d+)%?|[a-z]+)\s*/);)t.push(e[1]),f(/^,\s*/);if(t.length)return n({type:"keyframe",values:t,declarations:O()})}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=f(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=f(/^@([-\w]+)?keyframes\s*/);if(t){var n=t[1];if(!(t=f(/^([-\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=f(/^@media *([^{]+)/);if(t){var n=Nb(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=f(/^@custom-media\s+(--[^\s]+)\s*([^{;]+);/);if(t)return e({type:"custom-media",name:Nb(t[1]),media:Nb(t[2])})}()||function(){var e=c(),t=f(/^@supports *([^{]+)/);if(t){var n=Nb(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=f(/^@([-\w]+)?document *([^{]+)/);if(t){var n=Nb(t[1]),r=Nb(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(f(/^@page */)){var t=v()||[];if(!s())return l("@page missing '{'");for(var n,r=p();n=g();)r.push(n),r=r.concat(p());return u()?e({type:"page",selectors:t,declarations:r}):l("@page missing '}'")}}()||function(){var e=c();if(f(/^@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(f(/^@font-face\s*/)){if(!s())return l("@font-face missing '{'");for(var t,n=p();t=g();)n.push(t),n=n.concat(p());return u()?e({type:"font-face",declarations:n}):l("@font-face missing '}'")}}()}function w(){var e=c(),t=v();return t?(p(),e({type:"rule",selectors:t,declarations:O()})):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"===en(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 Nb(e){return e?e.replace(/^\s+|\s+$/g,""):""}var Db=n(171),Rb=n.n(Db),Ab=Mb;function Mb(e){this.options=e||{}}Mb.prototype.emit=function(e){return e},Mb.prototype.visit=function(e){return this[e.type](e)},Mb.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 Lb=Fb;function Fb(e){Ab.call(this,e)}Rb()(Fb,Ab),Fb.prototype.compile=function(e){return e.stylesheet.rules.map(this.visit,this).join("")},Fb.prototype.comment=function(e){return this.emit("",e.position)},Fb.prototype.import=function(e){return this.emit("@import "+e.import+";",e.position)},Fb.prototype.media=function(e){return this.emit("@media "+e.media,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Fb.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("}")},Fb.prototype.charset=function(e){return this.emit("@charset "+e.charset+";",e.position)},Fb.prototype.namespace=function(e){return this.emit("@namespace "+e.namespace+";",e.position)},Fb.prototype.supports=function(e){return this.emit("@supports "+e.supports,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Fb.prototype.keyframes=function(e){return this.emit("@"+(e.vendor||"")+"keyframes "+e.name,e.position)+this.emit("{")+this.mapVisit(e.keyframes)+this.emit("}")},Fb.prototype.keyframe=function(e){var t=e.declarations;return this.emit(e.values.join(","),e.position)+this.emit("{")+this.mapVisit(t)+this.emit("}")},Fb.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("}")},Fb.prototype["font-face"]=function(e){return this.emit("@font-face",e.position)+this.emit("{")+this.mapVisit(e.declarations)+this.emit("}")},Fb.prototype.host=function(e){return this.emit("@host",e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Fb.prototype["custom-media"]=function(e){return this.emit("@custom-media "+e.name+" "+e.media+";",e.position)},Fb.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("}"):""},Fb.prototype.declaration=function(e){return this.emit(e.property+":"+e.value,e.position)+this.emit(";")};var Vb=Hb;function Hb(e){e=e||{},Ab.call(this,e),this.indentation=e.indent}Rb()(Hb,Ab),Hb.prototype.compile=function(e){return this.stylesheet(e)},Hb.prototype.stylesheet=function(e){return this.mapVisit(e.stylesheet.rules,"\n\n")},Hb.prototype.comment=function(e){return this.emit(this.indent()+"/*"+e.comment+"*/",e.position)},Hb.prototype.import=function(e){return this.emit("@import "+e.import+";",e.position)},Hb.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}")},Hb.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}")},Hb.prototype.charset=function(e){return this.emit("@charset "+e.charset+";",e.position)},Hb.prototype.namespace=function(e){return this.emit("@namespace "+e.namespace+";",e.position)},Hb.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}")},Hb.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)+"}")},Hb.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")},Hb.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}")},Hb.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}")},Hb.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}")},Hb.prototype["custom-media"]=function(e){return this.emit("@custom-media "+e.name+" "+e.media+";",e.position)},Hb.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()+"}"):""},Hb.prototype.declaration=function(e){return this.emit(this.indent())+this.emit(e.property+": "+e.value,e.position)+this.emit(";")},Hb.prototype.indent=function(e){return this.level=this.level||1,null!==e?(this.level+=e,""):Array(this.level).join(this.indentation||" ")};var zb=function(e,t){try{var n=Tb(e),r=xb.a.map(n,(function(e){if(!e)return e;var n=t(e);return this.update(n)}));return o=r,((c=c||{}).compress?new Lb(c):new Vb(c)).compile(o)}catch(e){return console.warn("Error while traversing the CSS: "+e),null}var o,c};function Ub(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?Ub(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ub(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Kb(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 Wb(e,t){return new URL(e,t).toString()}var qb=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]};Kb(o)&&r.push(o)}return r}(t.value).map((c=e,function(e){return Gb(Gb({},e),{},{newUrl:"url("+e.before+e.quote+Wb(e.value,c)+e.quote+e.after+")"})}));return Gb(Gb({},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 $b(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 Yb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$b(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$b(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Xb=/^(body|html|:root).*$/,Qb=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return function(n){return"rule"===n.type?Yb(Yb({},n),{},{selectors:n.selectors.map((function(n){return t.includes(n.trim())?n:n.match(Xb)?n.replace(/^(body|html|:root)/,e):e+" "+n}))}):n}},Zb=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Object(b.map)(e,(function(e){var n=e.css,r=e.baseURL,o=[];return t&&o.push(Qb(t)),r&&o.push(qb(r)),o.length?zb(n,Object(p.compose)(o)):n}))};var Jb=function(e){var t=e.styles;return Object(u.useEffect)((function(){var e=Zb(t,".editor-styles-wrapper"),n=Object(b.map)(Object(b.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 ep=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?b.noop:s,f=Object(v.useSelect)((function(e){var r=e("core/block-editor").getBlockRootClientId;return t||r(n)||void 0}),[n,t]);return Object(u.createElement)(os,{onSelect:d,rootClientId:f,clientId:n,isAppender:r,showInserterHelpPanel:o,showMostUsedBlocks:i,__experimentalSelectBlockOnInsert:a,__experimentalInsertionIndex:l})};function tp(){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(ie.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,f=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(b.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(b.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(b.first)(n),Object(b.last)(n))}),[n,d])),Object(a.useShortcut)("core/block-editor/unselect",Object(u.useCallback)((function(e){e.preventDefault(),f(),e.target.ownerDocument.defaultView.getSelection().removeAllRanges()}),[t,f]),{isDisabled:t.length<2}),null}tp.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(O.__)("Duplicate the selected block(s)."),keyCombination:{modifier:"primaryShift",character:"d"}}),e({name:"core/block-editor/remove",category:"block",description:Object(O.__)("Remove the selected block(s)."),keyCombination:{modifier:"access",character:"z"}}),e({name:"core/block-editor/insert-before",category:"block",description:Object(O.__)("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(O.__)("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(O.__)("Remove multiple selected blocks."),keyCombination:{character:"del"},aliases:[{character:"backspace"}]}),e({name:"core/block-editor/select-all",category:"selection",description:Object(O.__)("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(O.__)("Clear selection."),keyCombination:{character:"escape"}}),e({name:"core/block-editor/focus-toolbar",category:"global",description:Object(O.__)("Navigate to the nearest toolbar."),keyCombination:{modifier:"alt",character:"F10"}}),e({name:"core/block-editor/move-up",category:"block",description:Object(O.__)("Move the selected block(s) up."),keyCombination:{modifier:"secondary",character:"t"}}),e({name:"core/block-editor/move-down",category:"block",description:Object(O.__)("Move the selected block(s) down."),keyCombination:{modifier:"secondary",character:"y"}})}),[e]),null};var np=tp;function rp(){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=Ze(n);if(e){var o=Object(xr.getScrollContainer)(e);o&&sf()(e,o,{onlyScrollIfNeeded:!0})}}}),[t,n,r]),null}var op=[pt.UP,pt.RIGHT,pt.DOWN,pt.LEFT,pt.ENTER,pt.BACKSPACE];var cp=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",f),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 f(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(xr.isTextField)(n)&&r.current.contains(n)&&("keydown"!==t||function(e){var t=e.keyCode;return!e.shiftKey&&op.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(xr.isTextField)(t)&&l()}))},onKeyPress:p,onKeyDown:Object(b.over)([p,function(e){!c||e.keyCode!==pt.ESCAPE&&e.keyCode!==pt.TAB||l()}])},t)}));function ip(){return uo()("PreserveScrollInReorder component",{hint:"This behavior is now built-in the block list"}),null}function ap(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var lp=-1!==window.navigator.userAgent.indexOf("Trident"),sp=new Set([pt.UP,pt.DOWN,pt.LEFT,pt.RIGHT]),up=function(e){Jt(n,e);var t=ap(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).ref=Object(u.createRef)(),e.onKeyDown=e.onKeyDown.bind(Qt(e)),e.addSelectionChangeListener=e.addSelectionChangeListener.bind(Qt(e)),e.computeCaretRectOnSelectionChange=e.computeCaretRectOnSelectionChange.bind(Qt(e)),e.maintainCaretPosition=e.maintainCaretPosition.bind(Qt(e)),e.computeCaretRect=e.computeCaretRect.bind(Qt(e)),e.onScrollResize=e.onScrollResize.bind(Qt(e)),e.isSelectionEligibleForScroll=e.isSelectionEligibleForScroll.bind(Qt(e)),e.getDocument=e.getDocument.bind(Qt(e)),e.getWindow=e.getWindow.bind(Qt(e)),e}return Xt(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(xr.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(xr.computeCaretRect)(this.getWindow());if(n)if(this.caretRect)if(sp.has(t))this.caretRect=n;else{var r=n.top-this.caretRect.top;if(0!==r){var o=Object(xr.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),dp=lp?function(e){return e.children}:Object(v.withSelect)((function(e){return{selectedBlockClientId:(0,e("core/block-editor").getSelectedBlockClientId)()}}))(up);function fp(e){if(void 0===e)e=Eo.colors;else{var t=e.filter((function(e){return e.color}));0===t.length?e=Eo.colors:t.length<e.length&&(e=t)}return e}function bp(e){if(void 0===e)e=Eo.gradients;else{var t=e.filter((function(e){return e.gradient}));0===t.length?e=Eo.gradients:t.length<e.length&&(e=t)}return e}}]);
|
1 |
+
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=402)}([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){!function(){e.exports=this.wp.primitives}()},function(e,t,n){var r;!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))e.push(o.apply(null,r));else if("object"===c)for(var i in r)n.call(r,i)&&r[i]&&e.push(i)}}return e.join(" ")}e.exports?e.exports=o:void 0===(r=function(){return o}.apply(t,[]))||(e.exports=r)}()},function(e,t){!function(){e.exports=this.React}()},function(e,t){!function(){e.exports=this.wp.blocks}()},function(e,t){!function(){e.exports=this.wp.compose}()},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){!function(){e.exports=this.regeneratorRuntime}()},function(e,t){!function(){e.exports=this.wp.keycodes}()},,,,function(e,t){!function(){e.exports=this.wp.richText}()},function(e,t){!function(){e.exports=this.wp.url}()},,function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(169);var o=n(136),c=n(170);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,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){e.exports=n(139)()},function(e,t){!function(){e.exports=this.wp.dom}()},,,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,t){if(null==e)return{};var n,r,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,t);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}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";n.d(t,"a",(function(){return c}));var r=n(8),o=n(52);function c(e){var t=Object(r.useRef)(e);return Object(o.a)((function(){t.current=e})),t}},function(e,t){!function(){e.exports=this.wp.blob}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return l}));var r=n(8),o=n(57);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(38);var a=n(46);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={},f=n||{};for(var b in f)void 0!==f[b]&&(d[b]=f[b]);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(8),o=n(38),c=n(72);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(46);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,f=e.keys,b=void 0===f?(null==l?void 0:l.__keys)||[]:f,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,b),d=u[0],f=u[1],p=l(d,Object(o.a)({ref:t},f)),v=p.wrapElement,g=Object(o.b)(p,["wrapElement"]),O=(null===(s=c.render)||void 0===s?void 0:s.__keys)||c.__keys,h=O&&i(a,O)[0],j=h?Object(o.a)(Object(o.a)({},g),h):g,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=b,v.unstable_propsAreEqual=d||a.a,v}},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){return e?e.ownerDocument||e:window.document}n.d(t,"a",(function(){return r}))},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){!function(){e.exports=this.wp.a11y}()},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";n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return g})),n.d(t,"c",(function(){return p})),n.d(t,"d",(function(){return b})),n.d(t,"e",(function(){return h})),n.d(t,"f",(function(){return s})),n.d(t,"g",(function(){return S}));var r=n(11),o=n(8),c=n(52),i=n(54),a=n(55),l=n(58);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 f(e,t){return t?e.find((function(e){return!e.disabled&&e.id!==t})):e.find((function(e){return!e.disabled}))}function b(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 g(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 O(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=f(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,w=e.wrap,S=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),W=Object(r.b)(Object(r.b)({},e),{},{items:_(i,U,G)});return R||I||void 0!==T?W:Object(r.b)(Object(r.b)({},W),{},{currentId:null===(V=f(W.items))||void 0===V?void 0:V.id});case"unregisterItem":var K=t.id,q=i.filter((function(e){return e.id!==K}));if(q.length===i.length)return e;var $=S.filter((function(e){return e!==K})),Y=Object(r.b)(Object(r.b)({},e),{},{pastIds:$,items:q});if(u&&u===K){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=S.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=b(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=f(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,fe=ce&&w&&w!==ue,be=t.hasNullItem||!ce&&de&&null===T;if(de){var pe=f(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))}(fe&&!be?re:k(re,oe.groupId),u,be),u);return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==pe?void 0:pe.id}))}if(fe){var me=f(be?le:ae,u),ve=be?(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 ge=f(le,u);return C(e,!ge&&be?Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null}):Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==ge?void 0:ge.id}));case"previous":var Oe=!!!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:Oe}));return Object(r.b)(Object(r.b)({},he),{},{items:i});case"down":var je=v(g(O(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(g(O(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 we=f(i);return C(e,Object(r.b)(Object(r.b)({},t),{},{type:"move",id:null==we?void 0:we.id}));case"last":var Se=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)({},Se),{},{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,w)});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 w(e){return Object(o.useCallback)(e,[])}function S(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,f=t.currentId,b=t.loop,p=void 0!==b&&b,m=t.wrap,v=void 0!==m&&m,g=Object(r.a)(t,["unstable_virtual","rtl","orientation","currentId","loop","wrap"]),O=Object(o.useReducer)(C,{unstable_virtual:a,rtl:u,orientation:d,items:[],groups:[],currentId:f,loop:p,wrap:v,unstable_moves:0,pastIds:[],initialVirtual:a,initialRTL:u,initialOrientation:d,initialCurrentId:f,initialLoop:p,initialWrap:v}),h=O[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=O[1],y=Object(o.useState)(!1),_=y[0],E=y[1],S=Object(l.a)(g),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)({},S),j),{},{unstable_hasActiveWidget:_,unstable_setHasActiveWidget:E,registerItem:w((function(e){I.current||k({type:"registerItem",item:e})})),unregisterItem:w((function(e){I.current||k({type:"unregisterItem",id:e})})),registerGroup:w((function(e){I.current||k({type:"registerGroup",group:e})})),unregisterGroup:w((function(e){I.current||k({type:"unregisterGroup",id:e})})),move:w((function(e){return k({type:"move",id:e})})),next:w((function(e){return k({type:"next",allTheWay:e})})),previous:w((function(e){return k({type:"previous",allTheWay:e})})),up:w((function(e){return k({type:"up",allTheWay:e})})),down:w((function(e){return k({type:"down",allTheWay:e})})),first:w((function(){return k({type:"first"})})),last:w((function(){return k({type:"last"})})),unstable_sort:w((function(){return k({type:"sort"})})),unstable_setVirtual:w((function(e){return k({type:"setVirtual",virtual:e})})),setRTL:w((function(e){return k({type:"setRTL",rtl:e})})),setOrientation:w((function(e){return k({type:"setOrientation",orientation:e})})),setCurrentId:w((function(e){return k({type:"setCurrentId",currentId:e})})),setLoop:w((function(e){return k({type:"setLoop",loop:e})})),setWrap:w((function(e){return k({type:"setWrap",wrap:e})})),reset:w((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"]);S.__keys=I},function(e,t){!function(){e.exports=this.wp.keyboardShortcuts}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(8),o="undefined"==typeof window?r.useEffect:r.useLayoutEffect},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(45);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(8);function o(e){return Object(r.useState)(e)[0]}},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(8),o=Object(r.createContext)({})},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(8),o=n(54),c=n(60);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){"use strict";n.d(t,"a",(function(){return o}));var r=n(8);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,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(11),o=n(43),c=n(42),i=n(46),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 c}));var r=n(8);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,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";n.d(t,"a",(function(){return o}));var r=n(53);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(53),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(11),o=n(43),c=n(42),i=n(61),a=n(8),l=n(62),s=n(67),u=(n(75),n(40)),d=n(52),f=n(66),b=n(69),p=n(53),m=n(68);function v(e){return"undefined"!=typeof window&&-1!==window.navigator.userAgent.indexOf(e)}var g=v("Mac")&&!v("Chrome")&&(v("Safari")||v("Firefox"));function O(e){Object(f.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,f=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],w=E?o:o||0,S=e.disabled?Object(r.b)({pointerEvents:"none"},f):f,I=function(){if(g){var e=Object(a.useState)(null),t=e[0],n=e[1];return Object(a.useEffect)((function(){t&&(O(t),n(null))}),[t]),Object(a.useCallback)((function(e){var t=e.currentTarget;if(!Object(b.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 O(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:S,tabIndex:y?void 0:w,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){!function(){e.exports=this.wp.htmlEntities}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(8),o=n(57),c=n(38);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){!function(){e.exports=this.wp.isShallowEqual}()},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 f(e,t){if(t=t||{},(e=e||"")instanceof f)return e;if(!(this instanceof f))return new f(e,t);var n=function(e){var t={r:0,g:0,b:0},n=1,r=null,a=null,l=null,d=!1,f=!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)?(b=e.r,p=e.g,m=e.b,t={r:255*N(b,255),g:255*N(p,255),b:255*N(m,255)},d=!0,f="%"===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,f="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,f="hsl"),e.hasOwnProperty("a")&&(n=e.a));var b,p,m;return n=T(n),{ok:d,format:e.format||f,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 b(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 g(e,t){t=0===t?0:t||10;var n=f(e).toHsl();return n.s-=t/100,n.s=D(n.s),f(n)}function O(e,t){t=0===t?0:t||10;var n=f(e).toHsl();return n.s+=t/100,n.s=D(n.s),f(n)}function h(e){return f(e).desaturate(100)}function j(e,t){t=0===t?0:t||10;var n=f(e).toHsl();return n.l+=t/100,n.l=D(n.l),f(n)}function k(e,t){t=0===t?0:t||10;var n=f(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))),f(n)}function y(e,t){t=0===t?0:t||10;var n=f(e).toHsl();return n.l-=t/100,n.l=D(n.l),f(n)}function _(e,t){var n=f(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,f(n)}function E(e){var t=f(e).toHsl();return t.h=(t.h+180)%360,f(t)}function C(e){var t=f(e).toHsl(),n=t.h;return[f(e),f({h:(n+120)%360,s:t.s,l:t.l}),f({h:(n+240)%360,s:t.s,l:t.l})]}function w(e){var t=f(e).toHsl(),n=t.h;return[f(e),f({h:(n+90)%360,s:t.s,l:t.l}),f({h:(n+180)%360,s:t.s,l:t.l}),f({h:(n+270)%360,s:t.s,l:t.l})]}function S(e){var t=f(e).toHsl(),n=t.h;return[f(e),f({h:(n+72)%360,s:t.s,l:t.l}),f({h:(n+216)%360,s:t.s,l:t.l})]}function I(e,t,n){t=t||6,n=n||30;var r=f(e).toHsl(),o=360/n,c=[f(e)];for(r.h=(r.h-(o*t>>1)+720)%360;--t;)r.h=(r.h+o)%360,c.push(f(r));return c}function B(e,t){t=t||6;for(var n=f(e).toHsv(),r=n.h,o=n.s,c=n.v,i=[],a=1/t;t--;)i.push(f({h:r,s:o,v:c})),c=(c+a)%1;return i}f.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=b(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=b(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=f(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 f(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(g,arguments)},saturate:function(){return this._applyModification(O,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(S,arguments)},triad:function(){return this._applyCombination(C,arguments)},tetrad:function(){return this._applyCombination(w,arguments)}},f.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 f(e,t)},f.equals=function(e,t){return!(!e||!t)&&f(e).toRgbString()==f(t).toRgbString()},f.random=function(){return f.fromRatio({r:d(),g:d(),b:d()})},f.mix=function(e,t,n){n=0===n?0:n||50;var r=f(e).toRgb(),o=f(t).toRgb(),c=n/100;return f({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})},f.readability=function(e,t){var n=f(e),r=f(t);return(o.max(n.getLuminance(),r.getLuminance())+.05)/(o.min(n.getLuminance(),r.getLuminance())+.05)},f.isReadable=function(e,t,n){var r,o,c=f.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},f.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=f.readability(e,t[s]))>l&&(l=r,a=f(t[s]));return f.isReadable(e,a,{level:c,size:i})||!o?a:(n.includeFallbackColors=!1,f.mostReadable(e,["#fff","#000"],n))};var x=f.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=f.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=f:void 0===(r=function(){return f}.call(t,n,t,e))||(e.exports=r)}(Math)},function(e,t,n){"use strict";n(91),n(8)},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(11),o=n(43),c=n(42),i=n(8),a=n(67),l=(n(75),n(40)),s=n(49),u=n(70);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],f=u[1],b=Object(l.a)(n),p=Object(l.a)(o),m=Object(i.useCallback)((function(t){var n;if(null===(n=b.current)||void 0===n||n.call(b,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&&f(!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&&(f(!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.notices}()},,,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(100);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";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.d(t,"a",(function(){return s}));var r=n(11),o=n(43),c=n(42),i=n(8),a=n(60),l=n(58),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"},,function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(45);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){!function(){e.exports=this.wp.warning}()},,,function(e,t,n){"use strict";t.__esModule=!0;var r=n(185);t.default=r.default},,function(e,t){!function(){e.exports=this.wp.viewport}()},function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(45);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){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 f(){u&&l&&(u=!1,l.length?s=l.concat(s):d=-1,s.length&&b())}function b(){if(!u){var e=a(f);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(b)},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){!function(){e.exports=this.ReactDOM}()},,,,function(e,t,n){"use strict";n.d(t,"a",(function(){return E})),n.d(t,"b",(function(){return _}));var r=n(11),o=n(43),c=n(42),i=n(61),a=n(8),l=n(62),s=(n(75),n(40)),u=n(49),d=n(53),f=n(70),b=n(72),p=n(76),m=n(45),v=n(81),g=n(93),O=n(50),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(g.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:[f.a],useState:O.g,useOptions:function(e){return Object(r.b)(Object(r.b)({},e),{},{currentId:Object(O.e)(e)})},useProps:function(e,t){var n=t.ref,o=t.onFocus,c=t.onBlur,i=t.onKeyDown,f=t.onKeyUp,b=Object(r.a)(t,["ref","onFocus","onBlur","onKeyDown","onKeyUp"]),g=Object(a.useRef)(null),_=Object(O.d)(e.items,e.currentId),E=Object(a.useRef)(void 0),C=Object(s.a)(o),w=Object(s.a)(c),S=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}(g):void 0;Object(a.useEffect)((function(){var t=g.current;t&&e.unstable_moves&&!_&&t.focus()}),[e.unstable_moves,_]);var I=k(e.unstable_virtual,_,i),B=k(e.unstable_virtual,_,f),x=Object(a.useCallback)((function(t){var n;if(e.unstable_virtual){var r,o,c=(null==S?void 0:S.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=w.current)||void 0===n||n.call(w,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(O.a)(Object(O.b)(Object(O.f)(Object(O.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)(g,n),id:e.baseId,onFocus:x,onBlur:P,onKeyDown:T,onKeyUp:B,"aria-activedescendant":e.unstable_virtual&&(null==_?void 0:_.id)||void 0},b)},useComposeProps:function(e,t){t=Object(i.a)(e,t,!0);var n=Object(f.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(b.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(11),o=n(43),c=n(42),i=n(8),a=n(62),l=(n(75),n(40)),s=n(49),u=n(66),d=n(69),f=n(68),b=n(77),p=n(76),m=n(45),v=n(50),g=n(86),O=n(82),h=n(83);function j(e){return e.querySelector("[data-composite-item-widget]")}var k=Object(c.a)({name:"CompositeItem",compose:[b.a,g.a],useState:v.g,propsAreEqual:function(e,t){if(!t.id||e.id!==t.id)return b.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 b.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,b=void 0===c?0:c,v=t.onFocus,g=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,w=e.disabled&&!e.focusable,S=e.currentId===C,I=Object(l.a)(S),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)(g),N=Object(l.a)(k),D=Object(l.a)(y),R=!e.unstable_virtual&&!e.unstable_hasActiveWidget&&S||!(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:!!w}),function(){var t;null===(t=e.unregisterItem)||void 0===t||t.call(e,C)}}),[C,w,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(f.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(O.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(O.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?b:-1,"aria-selected":!(!e.unstable_virtual||!S)||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";function r(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(182)),c=r(n(183)),i=n(8),a=r(i),l=r(n(145)),s=r(n(184)),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 f(e,t){return u.und(e)||u.nul(e)?t:e}function b(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,g,O=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 O&&e.addChild(s(t))}))},t.detach=function(){return t.payload.forEach((function(e){return e instanceof O&&e.removeChild(s(t))}))},t}return l(t,e),t}(O),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 O&&e.addChild(s(t))}))},t.detach=function(){return Object.values(t.payload).forEach((function(e){return e instanceof O&&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 O)&&(t[n]=r instanceof O?r[e?"getAnimatedValue":"getValue"]():r)}return t},n.getAnimatedValue=function(){return this.getValue(!0)},t}(O);function k(e,t){v={fn:e,transform:t}}function y(e){g=e}var _,E=function(e){return"undefined"!=typeof window?window.requestAnimationFrame(e):-1},C=function(e){"undefined"!=typeof window&&window.cancelAnimationFrame(e)};function w(e){_=e}var S,I=function(){return Date.now()};function B(e){S=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 g},injectColorNames:y,get requestFrame(){return E},get cancelFrame(){return C},injectFrame:function(e,t){E=e,C=t},get interpolation(){return _},injectStringInterpolator:w,get now(){return I},injectNow:function(e){I=e},get defaultElement(){return S},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,f=0;f<s.animatedValues.length;f++){var b=s.animatedValues[f];if(!b.done){var p=s.fromValues[f],m=s.toValues[f],v=b.lastPosition,g=m instanceof O,h=Array.isArray(s.initialVelocity)?s.initialVelocity[f]:s.initialVelocity;if(g&&(m=m.getValue()),s.immediate)b.setValue(m),b.done=!0;else if("string"!=typeof p&&"string"!=typeof m){if(void 0!==s.duration)v=p+s.easing((t-b.startTime)/s.duration)*(m-p),u=t>=b.startTime+s.duration;else if(s.decay)v=p+h/(1-.998)*(1-Math.exp(-(1-.998)*(t-b.startTime))),(u=Math.abs(b.lastPosition-v)<.1)&&(m=v);else{d=void 0!==b.lastTime?b.lastTime:t,h=void 0!==b.lastVelocity?b.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,b.lastVelocity=h,b.lastTime=t}g&&!s.toValues[f].done&&(u=!1),u?(b.value!==m&&(v=m),b.done=!0):a=!0,b.setValue(v),b.lastPosition=v}else b.setValue(m),b.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){var c;return(c=e.call(this)||this).calc=void 0,c.payload=n instanceof h&&!(n instanceof t)?n.getPayload():Array.isArray(n)?n:[n],c.calc=F(r,o),c}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){this.calc=F(e,t)},n.interpolate=function(e,n){return new t(this,e,n)},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){return new V(this,e,t)},t}(O),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,f=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[f]),f++,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,O=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)&&!g[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,w=a.parent,S=a.interpolation,B=b(j?y.getPayload():y),x=i;h&&(x=_({range:[0,1],output:[i,i]})(1));var P,T=S&&S.getValue(),N=!u.und(w)&&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)w=S=a.parent||new H(k);else if(m)w=S=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?(w=a.parent).setValue(0,!1):w=new H(0);var F={output:[L,i]};a.interpolation?(S=a.interpolation,a.interpolation.updateConfig(F)):S=w.interpolate(F)}return B=b(j?y.getPayload():y),C=b(w.getPayload()),v&&!h&&w.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(O,r)&&w.setValue(h?y:i,!1),o({},e,((M={})[r]=o({},a,{name:r,parent:w,interpolation:S,animatedValues:C,toValues:B,previous:x,config:E,fromValues:b(w.getValue()),immediate:p(O,r),initialVelocity:f(E.velocity,0),clamp:f(E.clamp,!1),precision:f(E.precision,.01),tension:f(E.tension,170),friction:f(E.friction,26),mass:f(E.mass,1),duration:E.duration,easing:f(E.easing,(function(e){return e})),decay:E.decay}),M))}return D?e:(h&&(w.setValue(1,!1),S.updateConfig({output:[x,x]})),w.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}(),W=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},K=0,q=function(e,t){return("function"==typeof t?e.map(t):b(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=b(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 O||(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 fe(e){var t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function be(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|fe(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]),be(n[2]),be(n[3])))>>>0:(n=re.exec(t))?(se(de(n[1]),be(n[2]),be(n[3]))|fe(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,ge=new RegExp("("+Object.keys(Q).join("|")+")","g"),Oe={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||Oe.hasOwnProperty(e)&&Oe[e]?(""+t).trim():t+"px"}Oe=Object.keys(Oe).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}),Oe);var ke={};N((function(e){return new X(e)})),B("div"),w((function(e){var t=e.output.map((function(e){return e.replace(ve,pe)})).map((function(e){return e.replace(ge,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 f in a){var b=l?f:ke[f]||(ke[f]=f.replace(/([A-Z])/g,(function(e){return"-"+e.toLowerCase()})));void 0!==e.getAttribute(b)&&e.setAttribute(b,a[f])}}),(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),f=i.useRef(null),b=i.useCallback((function(e){var t=s.current;s.current=new R(e,(function(){f.current&&!1===v.fn(f.current,s.current.getAnimatedValue())&&r()})),t&&t.detach()}),[]);i.useEffect((function(){return function(){l.current=!1,s.current&&s.current.detach()}}),[]),i.useImperativeHandle(n,(function(){return T(f,l,r)})),b(t);var p=s.current.getValue(),m=(p.scrollTop,p.scrollLeft,c(p,["scrollTop","scrollLeft"]));return a.createElement(e,o({},m,{ref:function(e){return f.current=function(e,t){return t&&(u.fun(t)?t(e):u.obj(t)&&(t.current=e)),e}(e,n)}}))}))},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=W(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=W(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],f=l[2],b=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&&b(t)})),i.useEffect((function(){n.current=!0}),[]),r?[s,b,f]: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),f=void 0!==u&&u,b=(a.enter,a.leave,a.update,a.onDestroyed),m=(a.keys,a.items,a.onFrame),v=a.onRest,g=a.onStart,O=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,f=a.enter,b=a.leave,m=a.update,v=a.trail,g=void 0===v?0:v,O=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),w=[].concat(i.deleted),S=Object.keys(C),I=new Set(S),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=-g;for(;k.length;){switch(k.shift()){case"enter":x.forEach((function(e,t){O&&w.find((function(t){return t.originalKey===e}))&&(w=w.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:O?String(e):K++,item:o,trail:N+=g,config:p(h,o,c),from:p(n&&void 0!==u?u||{}:d,o),to:p(f,o)}}));break;case"leave":P.forEach((function(e){var t=_.indexOf(e),n=E[t];w.unshift(o({},C[e],{slot:"leave",destroyed:!0,left:_[Math.max(0,t-1)],right:_[Math.min(_.length,t+1)],trail:N+=g,config:p(h,n,"leave"),to:p(b,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+=g,config:p(h,n,"update"),to:p(m,n)})}))}}var D=s.map((function(e){return C[e]}));return w.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:w,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:O,onRest:function(n){y.current.mounted&&(e.destroyed&&(O||s||Y(y,a),b&&b(l)),!Array.from(y.current.instances).some((function(e){return!e[1].idle}))&&(O||s)&&y.current.deleted.length>0&&Y(y),v&&v(l,t,n))},onStart:g&&function(){return g(l,t)},onFrame:m&&function(e){return m(l,t,e)},delay:i,reset:f&&"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=W},,,,,,,,,function(e,t,n){"use strict";e.exports=n(190)},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(0),o=n(6),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(6),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(6),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";var r=n(21),o=n(32),c=n(0),i=n(2),a=n(3),l=n(168),s=Object(a.createSlotFill)("BlockControls"),u=s.Fill,d=s.Slot;var f=function(e){return"BlockControls".concat(e?"-expanded":"")},b=function(e){var t=e.controls,n=e.__experimentalIsExpanded,r=e.children;return Object(l.a)()?Object(c.createElement)(u,{name:f(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};b.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:f(n)},i,{fillProps:l}))},t.a=b},,,,,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(152);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,n){"use strict";var r=n(140);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,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){if(null==e)return{};var n,r,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,t);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var 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=o(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){r(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){e.exports=function(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}},function(e,t,n){e.exports=function(){"use strict";return function(e){var t={};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])}(t,e),function(e){return function(n){return function(r){var o,c,i=t[r.type],a=n(r);if(i)for(o=0;o<i.length;o++)(c=i[o](r,e))&&e.dispatch(c);return a}}}}}()},,,,,,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){!function(){e.exports=this.wp.tokenList}()},,,function(e,t,n){"use strict";var r=n(0),o=n(6),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(6),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";n.d(t,"a",(function(){return c}));var r=n(4),o=n(85);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,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){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,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(291)),o=a(n(296)),c=a(n(212)),i=a(n(209));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(8),l=n(22),s=n(186),u=n(187),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(){this.props.value!==this.currentValue&&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;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(188);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(0),o=n(6),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(191);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 f=r.isWindow(t),b=r.offset(e),p=r.outerHeight(e),m=r.outerWidth(e),v=void 0,g=void 0,O=void 0,h=void 0,j=void 0,k=void 0,y=void 0,_=void 0,E=void 0,C=void 0;f?(y=t,C=r.height(y),E=r.width(y),_={left:r.scrollLeft(y),top:r.scrollTop(y)},j={left:b.left-_.left-s,top:b.top-_.top-l},k={left:b.left+m-(_.left+E)+d,top:b.top+p-(_.top+C)+u},h=_):(v=r.offset(t),g=t.clientHeight,O=t.clientWidth,h={left:t.scrollLeft,top:t.scrollTop},j={left:b.left-(v.left+(parseFloat(r.css(t,"borderLeftWidth"))||0))-s,top:b.top-(v.top+(parseFloat(r.css(t,"borderTopWidth"))||0))-l},k={left:b.left+m-(v.left+O+(parseFloat(r.css(t,"borderRightWidth"))||0))+d,top:b.top+p-(v.top+g+(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 f=void 0;function b(e,t){for(var n=0;n<e.length;n++)t(e[n])}function p(e){return"border-box"===f(e,"boxSizing")}"undefined"!=typeof window&&(f=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 g(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(f(e,a))||0}return r}function O(e){return null!=e&&e==e.window}var h={};function j(e,t,n){if(O(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=(f(e),p(e)),i=0;(null==o||o<=0)&&(o=void 0,(null==(i=f(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-g(e,["border","padding"],r):i;if(a){var s=2===n?-g(e,["border"],r):g(e,["margin"],r);return l+(1===n?0:s)}return i+g(e,m.slice(n),r)}b(["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)):f(e,t);for(var c in t)t.hasOwnProperty(c)&&_(e,c,t[c])}b(["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){f(t);return p(t)&&(r+=g(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:O,each:b,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(O(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(O(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(6),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(6),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";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(22)),o=a(n(8)),c=a(n(106)),i=n(210);n(211);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(22))&&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(22)),o=a(n(8)),c=n(210),i=n(297);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 f=(0,c.polyfill)(d);t.default=f,e.exports=t.default},function(e,t,n){"use strict";var r=n(0),o=n(6),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(6),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(6),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(6),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";var r=n(0),o=n(6),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(6),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";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(20),o=n(0),c=n(175),i=n(2),a=(n(94),n(131));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)(),f=Object(o.useRef)(),b=Object(o.useState)({}),p=Object(r.a)(b,2),m=p[0],v=p[1],g=Object(o.useRef)();g.current=n;var O=Object(o.useCallback)(Object(i.throttle)((function(){var e=g.current.length?d.current:f.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}))&&O()}));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:f},s))))}}).call(this,n(101))},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(298))&&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 f=n?c(d):d,b={},p=!0,m={node:f,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){b.before=e},after:function(e){b.after=e},pre:function(e){b.pre=e},post:function(e){b.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 g=t.call(m,m.node);return void 0!==g&&m.update&&m.update(g),b.before&&b.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),b.pre&&b.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,b.post&&b.post.call(m,c),r.pop()})),o.pop()),b.after&&b.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(6),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(6),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(6),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(6),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(22));var r=a(n(292)),o=a(n(295)),c=a(n(8)),i=a(n(209));n(211);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 f=d;t.default=f,e.exports=t.default},function(e,t,n){"use strict";var r=n(293);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(294));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(22));var r=i(n(8)),o=n(106),c=i(n(212));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],f=(0,r.isValidElement)(d)&&!d.props.in;!u||s&&!f?u||!s||f?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(8);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";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 f=t[i-1];return i>1&&"string"==typeof f.value&&(f.added||f.removed)&&e.equals("",f.value)&&(t[i-2].value+=f.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,f=[{newPos:-1,components:[]}],b=this.extractCommon(f[0],t,e,0);if(f[0].newPos+1>=l&&b+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=f[n-1],b=f[n+1],p=(b?b.newPos:0)-n;d&&(f[n-1]=void 0);var m=d&&d.newPos+1<l,v=b&&0<=p&&p<s;if(m||v){if(!m||v&&d.newPos<b.newPos?(r=c(b),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));f[n]=r}else f[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(6),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(6),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 pe})),n.d(t,"getColorObjectByAttributeValues",(function(){return fe})),n.d(t,"getColorObjectByColorValue",(function(){return be})),n.d(t,"createCustomColorsHOC",(function(){return dn})),n.d(t,"withColors",(function(){return fn})),n.d(t,"__experimentalUseColors",(function(){return In})),n.d(t,"__experimentalGetGradientClass",(function(){return Oe})),n.d(t,"getGradientValueBySlug",(function(){return he})),n.d(t,"__experimentalGetGradientObjectByGradientValue",(function(){return je})),n.d(t,"getGradientSlugByValue",(function(){return ke})),n.d(t,"__experimentalUseGradient",(function(){return ye})),n.d(t,"getFontSize",(function(){return yt})),n.d(t,"getFontSizeClass",(function(){return Et})),n.d(t,"getFontSizeObjectByValue",(function(){return _t})),n.d(t,"FontSizePicker",(function(){return Ct})),n.d(t,"withFontSizes",(function(){return Nn})),n.d(t,"AlignmentToolbar",(function(){return Hn})),n.d(t,"Autocomplete",(function(){return or})),n.d(t,"BlockAlignmentToolbar",(function(){return T})),n.d(t,"__experimentalBlockAlignmentMatrixToolbar",(function(){return cr})),n.d(t,"BlockBreadcrumb",(function(){return ar})),n.d(t,"BlockContextProvider",(function(){return dr})),n.d(t,"BlockControls",(function(){return g.a})),n.d(t,"BlockColorsStyleSelector",(function(){return mr})),n.d(t,"BlockEdit",(function(){return Or})),n.d(t,"useBlockEditContext",(function(){return z.b})),n.d(t,"BlockFormatControls",(function(){return _r})),n.d(t,"BlockIcon",(function(){return tr})),n.d(t,"BlockNavigationDropdown",(function(){return cd})),n.d(t,"__experimentalBlockNavigationBlockFill",(function(){return Gu})),n.d(t,"__experimentalBlockNavigationEditor",(function(){return jd})),n.d(t,"__experimentalBlockNavigationTree",(function(){return td})),n.d(t,"__experimentalBlockVariationPicker",(function(){return yd})),n.d(t,"BlockVerticalAlignmentToolbar",(function(){return xd})),n.d(t,"ButtonBlockerAppender",(function(){return rl})),n.d(t,"ColorPalette",(function(){return Dd})),n.d(t,"ColorPaletteControl",(function(){return Rd})),n.d(t,"ContrastChecker",(function(){return We})),n.d(t,"__experimentalGradientPicker",(function(){return Ld})),n.d(t,"__experimentalGradientPickerControl",(function(){return Fd})),n.d(t,"__experimentalGradientPickerPanel",(function(){return Vd})),n.d(t,"__experimentalColorGradientControl",(function(){return Ne})),n.d(t,"__experimentalPanelColorGradientSettings",(function(){return ze})),n.d(t,"__experimentalImageSizeControl",(function(){return zd})),n.d(t,"InnerBlocks",(function(){return tf})),n.d(t,"__experimentalUseInnerBlocksProps",(function(){return ef})),n.d(t,"InspectorAdvancedControls",(function(){return q})),n.d(t,"InspectorControls",(function(){return Qe})),n.d(t,"__experimentalLinkControl",(function(){return Af})),n.d(t,"__experimentalLinkControlSearchInput",(function(){return Bf})),n.d(t,"__experimentalLinkControlSearchResults",(function(){return Of})),n.d(t,"__experimentalLinkControlSearchItem",(function(){return gf})),n.d(t,"LineHeightControl",(function(){return mt})),n.d(t,"MediaReplaceFlow",(function(){return Hf})),n.d(t,"MediaPlaceholder",(function(){return qf})),n.d(t,"MediaUpload",(function(){return Ff})),n.d(t,"MediaUploadCheck",(function(){return Vf})),n.d(t,"PanelColorSettings",(function(){return gn})),n.d(t,"PlainText",(function(){return Xf})),n.d(t,"__experimentalResponsiveBlockControl",(function(){return Zf})),n.d(t,"RichText",(function(){return hd})),n.d(t,"RichTextShortcut",(function(){return Jf})),n.d(t,"RichTextToolbarButton",(function(){return eb})),n.d(t,"__unstableRichTextInputEvent",(function(){return nb})),n.d(t,"ToolSelector",(function(){return ob})),n.d(t,"__experimentalUnitControl",(function(){return Rt})),n.d(t,"URLInput",(function(){return bf})),n.d(t,"URLInputButton",(function(){return lb})),n.d(t,"URLPopover",(function(){return Wf})),n.d(t,"__experimentalImageURLInputUI",(function(){return fb})),n.d(t,"withColorContext",(function(){return Nd})),n.d(t,"__experimentalBlockSettingsMenuFirstItem",(function(){return Zs})),n.d(t,"__experimentalInserterMenuExtension",(function(){return Rl})),n.d(t,"__experimentalPreviewOptions",(function(){return pb})),n.d(t,"__experimentalUseResizeCanvas",(function(){return kb})),n.d(t,"BlockInspector",(function(){return Sb})),n.d(t,"BlockList",(function(){return hl})),n.d(t,"__experimentalBlock",(function(){return xu})),n.d(t,"useBlockProps",(function(){return Iu})),n.d(t,"BlockMover",(function(){return Ss})),n.d(t,"BlockPreview",(function(){return yl})),n.d(t,"BlockSelectionClearer",(function(){return Ib})),n.d(t,"BlockSettingsMenu",(function(){return au})),n.d(t,"BlockSettingsMenuControls",(function(){return ou})),n.d(t,"BlockTitle",(function(){return ir})),n.d(t,"BlockToolbar",(function(){return bu})),n.d(t,"CopyHandler",(function(){return Ws})),n.d(t,"DefaultBlockAppender",(function(){return nl})),n.d(t,"__unstableEditorStyles",(function(){return Jb})),n.d(t,"Inserter",(function(){return fs})),n.d(t,"__experimentalLibrary",(function(){return ep})),n.d(t,"__experimentalSearchForm",(function(){return ko})),n.d(t,"BlockEditorKeyboardShortcuts",(function(){return np})),n.d(t,"MultiSelectScrollIntoView",(function(){return rp})),n.d(t,"NavigableToolbar",(function(){return _s})),n.d(t,"ObserveTyping",(function(){return cp})),n.d(t,"PreserveScrollInReorder",(function(){return ip})),n.d(t,"SkipToSelectedBlock",(function(){return yb})),n.d(t,"Typewriter",(function(){return dp})),n.d(t,"Warning",(function(){return Xr})),n.d(t,"WritingFlow",(function(){return gs})),n.d(t,"BlockEditorProvider",(function(){return el})),n.d(t,"__experimentalUseSimulatedMediaQuery",(function(){return jb})),n.d(t,"__experimentalUseEditorFeature",(function(){return ve})),n.d(t,"transformStyles",(function(){return Zb})),n.d(t,"validateThemeColors",(function(){return fp})),n.d(t,"validateThemeGradients",(function(){return bp})),n.d(t,"storeConfig",(function(){return Qa})),n.d(t,"SETTINGS_DEFAULTS",(function(){return Eo}));var r={};n.r(r),n.d(r,"resetBlocks",(function(){return sc})),n.d(r,"resetSelection",(function(){return uc})),n.d(r,"receiveBlocks",(function(){return dc})),n.d(r,"updateBlockAttributes",(function(){return fc})),n.d(r,"updateBlock",(function(){return bc})),n.d(r,"selectBlock",(function(){return pc})),n.d(r,"selectPreviousBlock",(function(){return mc})),n.d(r,"selectNextBlock",(function(){return vc})),n.d(r,"startMultiSelect",(function(){return gc})),n.d(r,"stopMultiSelect",(function(){return Oc})),n.d(r,"multiSelect",(function(){return hc})),n.d(r,"clearSelectedBlock",(function(){return jc})),n.d(r,"toggleSelection",(function(){return kc})),n.d(r,"replaceBlocks",(function(){return _c})),n.d(r,"replaceBlock",(function(){return Ec})),n.d(r,"moveBlocksDown",(function(){return wc})),n.d(r,"moveBlocksUp",(function(){return Sc})),n.d(r,"moveBlocksToPosition",(function(){return Ic})),n.d(r,"moveBlockToPosition",(function(){return Bc})),n.d(r,"insertBlock",(function(){return xc})),n.d(r,"insertBlocks",(function(){return Pc})),n.d(r,"showInsertionPoint",(function(){return Tc})),n.d(r,"hideInsertionPoint",(function(){return Nc})),n.d(r,"setTemplateValidity",(function(){return Dc})),n.d(r,"synchronizeTemplate",(function(){return Rc})),n.d(r,"mergeBlocks",(function(){return Ac})),n.d(r,"removeBlocks",(function(){return Mc})),n.d(r,"removeBlock",(function(){return Lc})),n.d(r,"replaceInnerBlocks",(function(){return Fc})),n.d(r,"toggleBlockMode",(function(){return Vc})),n.d(r,"startTyping",(function(){return Hc})),n.d(r,"stopTyping",(function(){return zc})),n.d(r,"startDraggingBlocks",(function(){return Uc})),n.d(r,"stopDraggingBlocks",(function(){return Gc})),n.d(r,"enterFormattedText",(function(){return Wc})),n.d(r,"exitFormattedText",(function(){return Kc})),n.d(r,"selectionChange",(function(){return qc})),n.d(r,"insertDefaultBlock",(function(){return $c})),n.d(r,"updateBlockListSettings",(function(){return Yc})),n.d(r,"updateSettings",(function(){return Xc})),n.d(r,"__unstableSaveReusableBlock",(function(){return Qc})),n.d(r,"__unstableMarkLastChangeAsPersistent",(function(){return Zc})),n.d(r,"__unstableMarkNextChangeAsNotPersistent",(function(){return Jc})),n.d(r,"__unstableMarkAutomaticChange",(function(){return ei})),n.d(r,"setNavigationMode",(function(){return ti})),n.d(r,"setBlockMovingClientId",(function(){return ni})),n.d(r,"duplicateBlocks",(function(){return ri})),n.d(r,"insertBeforeBlock",(function(){return oi})),n.d(r,"insertAfterBlock",(function(){return ci})),n.d(r,"toggleBlockHighlight",(function(){return ii})),n.d(r,"flashBlock",(function(){return ai})),n.d(r,"setHasControlledInnerBlocks",(function(){return li}));var o={};n.r(o),n.d(o,"getBlockName",(function(){return vi})),n.d(o,"isBlockValid",(function(){return gi})),n.d(o,"getBlockAttributes",(function(){return Oi})),n.d(o,"getBlock",(function(){return hi})),n.d(o,"__unstableGetBlockWithoutInnerBlocks",(function(){return ji})),n.d(o,"getBlocks",(function(){return ki})),n.d(o,"__unstableGetBlockWithBlockTree",(function(){return yi})),n.d(o,"__unstableGetBlockTree",(function(){return _i})),n.d(o,"getClientIdsOfDescendants",(function(){return Ei})),n.d(o,"getClientIdsWithDescendants",(function(){return Ci})),n.d(o,"getGlobalBlockCount",(function(){return wi})),n.d(o,"getBlocksByClientId",(function(){return Si})),n.d(o,"getBlockCount",(function(){return Ii})),n.d(o,"getSelectionStart",(function(){return Bi})),n.d(o,"getSelectionEnd",(function(){return xi})),n.d(o,"getBlockSelectionStart",(function(){return Pi})),n.d(o,"getBlockSelectionEnd",(function(){return Ti})),n.d(o,"getSelectedBlockCount",(function(){return Ni})),n.d(o,"hasSelectedBlock",(function(){return Di})),n.d(o,"getSelectedBlockClientId",(function(){return Ri})),n.d(o,"getSelectedBlock",(function(){return Ai})),n.d(o,"getBlockRootClientId",(function(){return Mi})),n.d(o,"getBlockParents",(function(){return Li})),n.d(o,"getBlockParentsByBlockName",(function(){return Fi})),n.d(o,"getBlockHierarchyRootClientId",(function(){return Vi})),n.d(o,"getLowestCommonAncestorWithSelectedBlock",(function(){return Hi})),n.d(o,"getAdjacentBlockClientId",(function(){return zi})),n.d(o,"getPreviousBlockClientId",(function(){return Ui})),n.d(o,"getNextBlockClientId",(function(){return Gi})),n.d(o,"getSelectedBlocksInitialCaretPosition",(function(){return Wi})),n.d(o,"getSelectedBlockClientIds",(function(){return Ki})),n.d(o,"getMultiSelectedBlockClientIds",(function(){return qi})),n.d(o,"getMultiSelectedBlocks",(function(){return $i})),n.d(o,"getFirstMultiSelectedBlockClientId",(function(){return Yi})),n.d(o,"getLastMultiSelectedBlockClientId",(function(){return Xi})),n.d(o,"isFirstMultiSelectedBlock",(function(){return Qi})),n.d(o,"isBlockMultiSelected",(function(){return Zi})),n.d(o,"isAncestorMultiSelected",(function(){return Ji})),n.d(o,"getMultiSelectedBlocksStartClientId",(function(){return ea})),n.d(o,"getMultiSelectedBlocksEndClientId",(function(){return ta})),n.d(o,"getBlockOrder",(function(){return na})),n.d(o,"getBlockIndex",(function(){return ra})),n.d(o,"isBlockSelected",(function(){return oa})),n.d(o,"hasSelectedInnerBlock",(function(){return ca})),n.d(o,"isBlockWithinSelection",(function(){return ia})),n.d(o,"hasMultiSelection",(function(){return aa})),n.d(o,"isMultiSelecting",(function(){return la})),n.d(o,"isSelectionEnabled",(function(){return sa})),n.d(o,"getBlockMode",(function(){return ua})),n.d(o,"isTyping",(function(){return da})),n.d(o,"isDraggingBlocks",(function(){return fa})),n.d(o,"getDraggedBlockClientIds",(function(){return ba})),n.d(o,"isBlockBeingDragged",(function(){return pa})),n.d(o,"isAncestorBeingDragged",(function(){return ma})),n.d(o,"isCaretWithinFormattedText",(function(){return va})),n.d(o,"getBlockInsertionPoint",(function(){return ga})),n.d(o,"isBlockInsertionPointVisible",(function(){return Oa})),n.d(o,"isValidTemplate",(function(){return ha})),n.d(o,"getTemplate",(function(){return ja})),n.d(o,"getTemplateLock",(function(){return ka})),n.d(o,"canInsertBlockType",(function(){return _a})),n.d(o,"canInsertBlocks",(function(){return Ea})),n.d(o,"getInserterItems",(function(){return Ia})),n.d(o,"hasInserterItems",(function(){return Ba})),n.d(o,"__experimentalGetAllowedBlocks",(function(){return xa})),n.d(o,"getBlockListSettings",(function(){return Pa})),n.d(o,"getSettings",(function(){return Ta})),n.d(o,"isLastBlockChangePersistent",(function(){return Na})),n.d(o,"__experimentalGetBlockListSettingsForBlocks",(function(){return Da})),n.d(o,"__experimentalGetParsedReusableBlock",(function(){return Ra})),n.d(o,"__unstableIsLastBlockChangeIgnored",(function(){return Aa})),n.d(o,"__experimentalGetLastBlockAttributeChanges",(function(){return Ma})),n.d(o,"isNavigationMode",(function(){return Fa})),n.d(o,"hasBlockMovingClientId",(function(){return Va})),n.d(o,"didAutomaticChange",(function(){return Ha})),n.d(o,"isBlockHighlighted",(function(){return za})),n.d(o,"areInnerBlocksControlled",(function(){return Ua})),n.d(o,"__experimentalGetActiveBlockIdByBlockNames",(function(){return Ga}));var c=n(9),i=n(17),a=(n(99),n(51)),l=(n(78),n(21));function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var u=n(0),d=n(7),f=n.n(d),b=n(2),p=n(10),m=n(26),v=n(4),g=n(131),O=n(1),h=n(3),j=n(6),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 w(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 S(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var I={left:{icon:k,title:Object(O.__)("Align left")},center:{icon:y,title:Object(O.__)("Align center")},right:{icon:_,title:Object(O.__)("Align right")},wide:{icon:E,title:Object(O.__)("Wide width")},full:{icon:C,title:Object(O.__)("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(O.__)("Change alignment"),controls:l.map((function(e){return S(S({},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){s(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?b.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)(g.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(b.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=f()("align".concat(r),e.className)),e}));var z=n(85),U=Object(h.createSlotFill)("InspectorAdvancedControls"),G=U.Fill,W=U.Slot;function K(e){var t=e.children;return Object(z.b)().isSelected?Object(u.createElement)(G,null,t):null}K.slotName="InspectorAdvancedControls",K.Slot=W;var q=K;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){s(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(O.__)("HTML anchor"),help:Object(u.createElement)(u.Fragment,null,Object(O.__)("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(O.__)("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){s(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(b.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(O.__)("Additional CSS class(es)"),value:t.attributes.className||"",onChange:function(e){t.setAttributes({className:""!==e?e:void 0})},help:Object(O.__)("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=f()(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(b.omit)(e,["className"]),o=Object(c.getSaveContent)(t,r),i=te(o),a=te(n),l=Object(b.difference)(a,i);l.length?e.className=l.join(" "):o&&delete e.className}return e}));var ne=n(152);function re(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}var oe=n(136);function ce(e){return function(e){if(Array.isArray(e))return Object(ne.a)(e)}(e)||re(e)||Object(oe.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.")}()}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(b.uniq)([Object(c.getBlockDefaultClassName)(t.name)].concat(ce(e.className.split(" ")))).join(" ").trim():e.className=Object(c.getBlockDefaultClassName)(t.name)),e}));var ie=n(20),ae=n(169),le=n(170);function se(e){return Object(ae.a)(e)||re(e)||Object(oe.a)(e)||Object(le.a)()}var ue=n(74),de=n.n(ue),fe=function(e,t,n){if(t){var r=Object(b.find)(e,{slug:t});if(r)return r}return{color:n}},be=function(e,t){return Object(b.find)(e,{color:t})};function pe(e,t){if(e&&t)return"has-".concat(Object(b.kebabCase)(t),"-").concat(e)}var me={"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 ve(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(b.get)(o,i))&&void 0!==r?r:Object(b.get)(o,c);if(void 0!==a)return a;var l=me[e]?me[e](o):void 0;return void 0!==l?l:"typography.dropCap"===e||void 0}),[t,e])}var ge=[];function Oe(e){if(e)return"has-".concat(e,"-gradient-background")}function he(e,t){var n=Object(b.find)(e,["slug",t]);return n&&n.gradient}function je(e,t){return Object(b.find)(e,["gradient",t])}function ke(e,t){var n=je(e,t);return n&&n.slug}function ye(){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=ve("color.gradients")||ge,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,f=l.customGradient,b=Object(v.useDispatch)("core/block-editor"),p=b.updateBlockAttributes,m=Object(u.useCallback)((function(e){var t,r,c=ke(a,e);c?p(i,(s(r={},n,c),s(r,o,void 0),r)):p(i,(s(t={},n,void 0),s(t,o,e),t))}),[a,i,p]),g=Oe(d);return{gradientClass:g,gradientValue:d?he(a,d):f,setGradient:m}}var _e=function e(t){if(!Object(b.isObject)(t))return t;var n=Object(b.pickBy)(Object(b.mapValues)(t,e),b.identity);return Object(b.isEqual)(n,{})?void 0:n},Ee=n(32);function Ce(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 we(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ce(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ce(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}
|
2 |
// translators: first %s: the color name or value (e.g. red or #ff0000)
|
3 |
var Se=Object(O.__)("(Color: %s)"),Ie=Object(O.__)("(Gradient: %s)"),Be=["colors","disableCustomColors","gradients","disableCustomGradients"];// translators: first %s: the gradient name or value (e.g. red to green or linear-gradient(135deg,rgba(6,147,227,1) 0%,rgb(155,81,224) 100%)
|
4 |
function xe(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=be(r,t=a),d=s&&s.name;n=Object(O.sprintf)(Se,d||t)}}else if("gradient"===i&&l){var f=je(o,t=l),b=f&&f.name;n=Object(O.sprintf)(Ie,b||t)}return Object(u.createElement)(u.Fragment,null,c,!!t&&Object(u.createElement)(h.ColorIndicator,{colorValue:t,"aria-label":n}))}function Pe(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(b.isEmpty)(t)||!r),v=s&&(!Object(b.isEmpty)(n)||!o),g=Object(u.useState)(p?"gradient":!!m&&"color"),j=Object(ie.a)(g,2),k=j[0],y=j[1];return m||v?Object(u.createElement)(h.BaseControl,{className:f()("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)(xe,{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(O.__)("Solid")),Object(u.createElement)(h.Button,{isSmall:!0,isPressed:"gradient"===k,onClick:function(){return y("gradient")}},Object(O.__)("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 Te(e){var t={};return t.colors=ve("color.palette"),t.gradients=ve("color.gradients"),t.disableCustomColors=!ve("color.custom"),t.disableCustomGradients=!ve("color.customGradient"),Object(u.createElement)(Pe,we(we({},t),e))}var Ne=function(e){return Object(b.every)(Be,(function(t){return e.hasOwnProperty(t)}))?Object(u.createElement)(Pe,e):Object(u.createElement)(Te,e)};function De(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 Re(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?De(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):De(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}
|
5 |
// translators: first %s: The type of color or gradient (e.g. background, overlay...), second %s: the color name or value (e.g. red or #ff0000)
|
6 |
var Ae=Object(O.__)("(%s: color %s)"),Me=Object(O.__)("(%s: gradient %s)"),Le=["colors","disableCustomColors","gradients","disableCustomGradients"],Fe=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=be(l||t,c);o=Object(O.sprintf)(Ae,a.toLowerCase(),d&&d.name||c)}else{var f=je(s||n,c);o=Object(O.sprintf)(Me,a.toLowerCase(),f&&f.name||i)}return Object(u.createElement)(h.ColorIndicator,{key:r,colorValue:c||i,"aria-label":o})}))},Ve=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(Ee.a)(e,["className","colors","gradients","disableCustomColors","disableCustomGradients","children","settings","title"]);if(Object(b.isEmpty)(n)&&Object(b.isEmpty)(r)&&o&&c&&Object(b.every)(a,(function(e){return Object(b.isEmpty)(e.colors)&&Object(b.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)(Fe,{colors:n,gradients:r,settings:a}));return Object(u.createElement)(h.PanelBody,Object(l.a)({className:f()("block-editor-panel-color-gradient-settings",t),title:p},d),a.map((function(e,t){return Object(u.createElement)(Ne,Object(l.a)({key:t},Re({colors:n,gradients:r,disableCustomColors:o,disableCustomGradients:c},e)))})),i)},He=function(e){var t={};return t.colors=ve("color.palette"),t.gradients=ve("color.gradients"),t.disableCustomColors=!ve("color.custom"),t.disableCustomGradients=!ve("color.customGradient"),Object(u.createElement)(Ve,Re(Re({},t),e))},ze=function(e){return Object(b.every)(Le,(function(t){return e.hasOwnProperty(t)}))?Object(u.createElement)(Ve,e):Object(u.createElement)(He,e)},Ue=n(48);// translators: first %s: The type of color or gradient (e.g. background, overlay...), second %s: the color name or value (e.g. red or #ff0000)
|
7 |
+
function Ge(e){var t=e.tinyBackgroundColor,n=e.tinyTextColor,r=e.backgroundColor,o=e.textColor,c=t.getBrightness()<n.getBrightness()?Object(O.__)("This color combination may be hard for people to read. Try using a darker background color and/or a brighter text color."):Object(O.__)("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(Ue.speak)(Object(O.__)("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 We=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=de()(t||n),l=de()(i||r);return 1!==a.getAlpha()||1!==l.getAlpha()||de.a.isReadable(a,l,{level:"AA",size:c||!1!==c&&o>=24?"large":"small"})?null:Object(u.createElement)(Ge,{backgroundColor:t,textColor:i,tinyBackgroundColor:a,tinyTextColor:l})},Ke=n(168),qe=Object(h.createSlotFill)("InspectorControls"),$e=qe.Fill,Ye=qe.Slot;function Xe(e){var t=e.children;return Object(Ke.a)()?Object(u.createElement)($e,null,t):null}Xe.Slot=Ye;var Qe=Xe;function Ze(e){return document.getElementById("block-"+e)}function Je(e,t){return t.closest(".block-editor-block-list__block")===e}function et(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 tt(e){return e.ownerDocument.defaultView.getComputedStyle(e)}function nt(e){var t=e.settings,n=e.clientId,r=e.enableContrastChecking,o=void 0===r||r,c=Object(u.useState)(),i=Object(ie.a)(c,2),a=i[0],l=i[1],s=Object(u.useState)(),d=Object(ie.a)(s,2),f=d[0],b=d[1];return Object(u.useEffect)((function(){if(o){var e=Ze(n);if(e){b(tt(e).color);for(var t=e,r=tt(t).backgroundColor;"rgba(0, 0, 0, 0)"===r&&t.parentNode&&t.parentNode.nodeType===t.parentNode.ELEMENT_NODE;)r=tt(t=t.parentNode).backgroundColor;l(r)}}})),Object(u.createElement)(Qe,null,Object(u.createElement)(ze,{title:Object(O.__)("Color settings"),initialOpen:!1,settings:t},o&&Object(u.createElement)(We,{backgroundColor:a,textColor:f})))}function rt(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 ot(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rt(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ct=[],it=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)},at=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return Object(b.isObject)(t)&&!!t.link},lt=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return Object(b.isObject)(t)&&!!t.gradients},st=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return t&&!1!==t.text};function ut(e,t,n){var r,o,c,i,a,l;if(!it(t))return e;var u=lt(t),d=n.backgroundColor,b=n.textColor,p=n.gradient,m=n.style,v=pe("background-color",d),g=Oe(p),O=pe("color",b),h=f()(e.className,O,g,(s(l={},v,!(u&&(null==m||null===(r=m.color)||void 0===r?void 0:r.gradient)||!v)),s(l,"has-text-color",b||(null==m||null===(o=m.color)||void 0===o?void 0:o.text)),s(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))),s(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 dt=function(e,t){var n=/var:preset\|color\|(.+)/.exec(t);return n&&n[1]?fe(e,n[1]).color:t};function ft(e){var t,n,r,o,i,a,l=e.name,d=e.attributes,f=ve("color.link"),b=ve("color.palette")||ct,p=ve("color.gradients")||ct,m=Object(u.useRef)(d);if(Object(u.useEffect)((function(){m.current=d}),[d]),!it(l))return null;var v,g=function(e){if("web"!==u.Platform.OS)return!1;var t=Object(c.getBlockSupport)(e,"color");return t&&!1!==t.background}(l),h=lt(l),j=d.style,k=d.textColor,y=d.backgroundColor,_=d.gradient;if(h&&_)v=he(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=be(b,n),i=t+"Color",a=ot(ot({},m.current.style),{},{color:ot(ot({},null===(r=m.current)||void 0===r||null===(o=r.style)||void 0===o?void 0:o.color),{},s({},t,(null==c?void 0:c.slug)?void 0:n))}),l=(null==c?void 0:c.slug)?c.slug:void 0,u=s({style:_e(a)},i,l);e.setAttributes(u),m.current=ot(ot({},m.current),u)}};return Object(u.createElement)(nt,{enableContrastChecking:"web"===u.Platform.OS&&!_&&!(null==j||null===(t=j.color)||void 0===t?void 0:t.gradient),clientId:e.clientId,settings:[].concat(ce(st(l)?[{label:Object(O.__)("Text Color"),onColorChange:C("text"),colorValue:fe(b,k,null==j||null===(n=j.color)||void 0===n?void 0:n.text).color}]:[]),ce(g||h?[{label:Object(O.__)("Background Color"),onColorChange:g?C("background"):void 0,colorValue:fe(b,y,null==j||null===(r=j.color)||void 0===r?void 0:r.background).color,gradientValue:v,onGradientChange:h?function(t){var n,r=ke(p,t);if(r){var o,c,i,a=ot(ot({},null===(o=m.current)||void 0===o?void 0:o.style),{},{color:ot(ot({},null===(c=m.current)||void 0===c||null===(i=c.style)||void 0===i?void 0:i.color),{},{gradient:void 0})});n={style:_e(a),gradient:r}}else{var l,s,u,d=ot(ot({},null===(l=m.current)||void 0===l?void 0:l.style),{},{color:ot(ot({},null===(s=m.current)||void 0===s||null===(u=s.style)||void 0===u?void 0:u.color),{},{gradient:t})});n={style:_e(d),gradient:void 0}}e.setAttributes(n),m.current=ot(ot({},m.current),n)}:void 0}]:[]),ce(f&&at(l)?[{label:Object(O.__)("Link Color"),onColorChange:function(t){var n,r=be(b,t);e.setAttributes({style:ot(ot({},e.attributes.style),{},{color:ot(ot({},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:dt(b,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 bt=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=ve("color.palette")||ct;if(!it(c))return Object(u.createElement)(e,t);var f={color:s?null===(n=fe(d,s))||void 0===n?void 0:n.color:void 0,backgroundColor:a?null===(r=fe(d,a))||void 0===r?void 0:r.color:void 0},b=t.wrapperProps;return b=ot(ot({},t.wrapperProps),{},{style:ot(ot({},f),null===(o=t.wrapperProps)||void 0===o?void 0:o.style)}),Object(u.createElement)(e,Object(l.a)({},t,{wrapperProps:b}))}}));Object(m.addFilter)("blocks.registerBlockType","core/color/addAttribute",(function(e){return it(e)?(e.attributes.backgroundColor||Object.assign(e.attributes,{backgroundColor:{type:"string"}}),e.attributes.textColor||Object.assign(e.attributes,{textColor:{type:"string"}}),lt(e)&&!e.attributes.gradient&&Object.assign(e.attributes,{gradient:{type:"string"}}),e):e})),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/color/addSaveProps",ut),Object(m.addFilter)("blocks.registerBlockType","core/color/addEditProps",(function(e){if(!it(e))return e;var t=e.getEditWrapperProps;return e.getEditWrapperProps=function(n){var r={};return t&&(r=t(n)),ut(r,e,n)},e})),Object(m.addFilter)("editor.BlockListBlock","core/color/with-color-palette-styles",bt);var pt=n(13);function mt(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!==pt.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(O.__)("Line height"),placeholder:1.5,step:.1,type:"number",value:o,min:0}))}function vt(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 gt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?vt(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ot(e){var t,n=e.attributes.style;if(ht(e))return null;return Object(u.createElement)(mt,{value:null==n||null===(t=n.typography)||void 0===t?void 0:t.lineHeight,onChange:function(t){var r=gt(gt({},n),{},{typography:gt(gt({},null==n?void 0:n.typography),{},{lineHeight:t})});e.setAttributes({style:_e(r)})}})}function ht(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=!ve("typography.customLineHeight");return!Object(c.hasBlockSupport)(t,"lineHeight")||n}var jt=n(153),kt=n.n(jt),yt=function(e,t,n){if(t){var r=Object(b.find)(e,{slug:t});if(r)return r}return{size:n}};function _t(e,t){var n=Object(b.find)(e,{size:t});return n||{size:t}}function Et(e){if(e)return"has-".concat(Object(b.kebabCase)(e),"-font-size")}var Ct=function(e){var t=ve("typography.fontSizes"),n=!ve("typography.customFontSize");return Object(u.createElement)(h.FontSizePicker,Object(l.a)({},e,{fontSizes:t,disableCustomFontSizes:n}))};function wt(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 St(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?wt(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function It(e,t,n){if(!Object(c.hasBlockSupport)(t,"fontSize"))return e;var r=new kt.a(e.className);r.add(Et(n.fontSize));var o=r.value;return e.className=o||void 0,e}function Bt(e){var t,n=e.attributes,r=n.fontSize,o=n.style,c=e.setAttributes,i=xt(e),a=ve("typography.fontSizes");if(i)return null;var l=yt(a,r,null==o||null===(t=o.typography)||void 0===t?void 0:t.fontSize);return Object(u.createElement)(Ct,{value:l.size,onChange:function(e){var t=_t(a,e).slug;c({style:_e(St(St({},o),{},{typography:St(St({},null==o?void 0:o.typography),{},{fontSize:t?void 0:e})})),fontSize:t})}})}function xt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=ve("typography.fontSizes"),r=!!(null==n?void 0:n.length);return!Object(c.hasBlockSupport)(t,"fontSize")||!r}var Pt=Object(p.createHigherOrderComponent)((function(e){return function(t){var n,r=ve("typography.fontSizes"),o=t.name,i=t.attributes,a=i.fontSize,l=i.style,s=t.wrapperProps,d=St({},t);if(Object(c.hasBlockSupport)(o,"fontSize")&&a&&!(null==l||null===(n=l.typography)||void 0===n?void 0:n.fontSize)){var f,b=yt(r,a,null==l||null===(f=l.typography)||void 0===f?void 0:f.fontSize).size;d.wrapperProps=St(St({},s),{},{style:St({fontSize:b},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",It),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)),It(r,e,n)},e})),Object(m.addFilter)("editor.BlockListBlock","core/font-size/with-font-size-inline-styles",Pt);var Tt=["lineHeight","fontSize"];function Nt(e){var t=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=[xt(e),ht(e)];return t.filter(Boolean).length===t.length}(e),n=Dt(e.name);return t||!n?null:Object(u.createElement)(Qe,null,Object(u.createElement)(h.PanelBody,{title:Object(O.__)("Typography")},Object(u.createElement)(Bt,e),Object(u.createElement)(Ot,e)))}var Dt=function(e){return"web"===u.Platform.OS&&Tt.some((function(t){return Object(c.hasBlockSupport)(e,t)}))};function Rt(e){var t=e.units,n=Object(Ee.a)(e,["units"]),r=At(t);return Object(u.createElement)(h.__experimentalUnitControl,Object(l.a)({units:r},n))}function At(e){var t=ve("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 Mt(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 Lt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Mt(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mt(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ft(e){var t,n=e.name,r=e.attributes.style,o=e.setAttributes,i=At();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=Lt(Lt({},r),{},{spacing:{padding:e}});o({style:_e(t)})},onChangeShowVisualizer:function(e){var t=Lt(Lt({},r),{},{visualizers:{padding:e}});o({style:_e(t)})},label:Object(O.__)("Padding"),units:i})),native:null})}function Vt(e){var t=e.children,n=Object(Ee.a)(e,["children"]);return ve("spacing.customPadding")?Object(u.createElement)(Qe,n,Object(u.createElement)(h.PanelBody,{title:Object(O.__)("Spacing")},t)):null}function Ht(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 zt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ht(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ht(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ut=[].concat(ce(Tt),["color","spacing"]),Gt=function(e){return Ut.some((function(t){return Object(c.hasBlockSupport)(e,t)}))};function Wt(e){if(Object(b.startsWith)(e,"var:")){var t=e.slice("var:".length).split("|").join("--");return"var(--wp--".concat(t,")")}return e}function Kt(e,t,n){if(!Gt(t))return e;var r=n.style;return e.style=zt(zt({},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=se(n),o=r[0],c=r.slice(1),i=Object(ie.a)(c,1)[0];Object(b.has)(e,i)&&(t[o]=Wt(Object(b.get)(e,i)))})),t}(r)),e.style),e}var qt=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=t.name,r=Object(c.hasBlockSupport)(n,"spacing");return[Object(u.createElement)(Nt,Object(l.a)({key:"typography"},t)),Object(u.createElement)(ft,Object(l.a)({key:"colors"},t)),Object(u.createElement)(e,Object(l.a)({key:"edit"},t)),r&&Object(u.createElement)(Vt,{key:"spacing"},Object(u.createElement)(Ft,t))]}}),"withToolbarControls");function $t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Yt(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 Xt(e,t,n){return t&&Yt(e.prototype,t),n&&Yt(e,n),e}function Qt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Zt(e,t){return(Zt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Jt(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&&Zt(e,t)}function en(e){return(en="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)}function tn(e,t){return!t||"object"!==en(t)&&"function"!=typeof t?Qt(e):t}function nn(e){return(nn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function rn(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}function on(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 cn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?on(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):on(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}Object(m.addFilter)("blocks.registerBlockType","core/style/addAttribute",(function(e){return Gt(e)?(e.attributes.style||Object.assign(e.attributes,{style:{type:"object"}}),e):e})),Object(m.addFilter)("blocks.getSaveContent.extraProps","core/style/addSaveProps",Kt),Object(m.addFilter)("blocks.registerBlockType","core/style/addEditProps",(function(e){if(!Gt(e))return e;var t=e.getEditWrapperProps;return e.getEditWrapperProps=function(n){var r={};return t&&(r=t(n)),Kt(r,e,n)},e})),Object(m.addFilter)("editor.BlockEdit","core/style/with-block-controls",qt);var an=[],ln=function(e){return Object(p.createHigherOrderComponent)((function(t){return function(n){return Object(u.createElement)(t,Object(l.a)({},n,{colors:e}))}}),"withCustomColorPalette")},sn=function(){return Object(p.createHigherOrderComponent)((function(e){return function(t){var n=ve("color.palette")||an;return Object(u.createElement)(e,Object(l.a)({},t,{colors:n}))}}),"withEditorColorPalette")};function un(e,t){var n=Object(b.reduce)(e,(function(e,t){return cn(cn({},e),Object(b.isString)(t)?s({},t,Object(b.kebabCase)(t)):t)}),{});return Object(p.compose)([t,function(e){return function(t){Jt(o,t);var r=rn(o);function o(e){var t;return $t(this,o),(t=r.call(this,e)).setters=t.createSetters(),t.colorUtils={getMostReadableColor:t.getMostReadableColor.bind(Qt(t))},t.state={},t}return Xt(o,[{key:"getMostReadableColor",value:function(e){return function(e,t){return de.a.mostReadable(t,Object(b.map)(e,"color")).toHexString()}(this.props.colors,e)}},{key:"createSetters",value:function(){var e=this;return Object(b.reduce)(n,(function(t,n,r){var o=Object(b.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=be(n.props.colors,r);n.props.setAttributes((s(o={},e,c&&c.slug?c.slug:void 0),s(o,t,c&&c.slug?void 0:r),o))}}},{key:"render",value:function(){return Object(u.createElement)(e,cn(cn(cn(cn({},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(b.reduce)(n,(function(e,n,c){var i=fe(o,r[c],r["custom".concat(Object(b.upperFirst)(c))]),a=t[c];return(null==a?void 0:a.color)===i.color&&a?e[c]=a:e[c]=cn(cn({},i),{},{class:pe(n,i.slug)}),e}),{})}}]),o}(u.Component)}])}function dn(e){return function(){for(var t=ln(e),n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return Object(p.createHigherOrderComponent)(un(r,t),"withCustomColors")}}function fn(){for(var e=sn(),t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return Object(p.createHigherOrderComponent)(un(n,e),"withColors")}var bn=n(65),pn=n.n(bn);function mn(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 vn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?mn(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var gn=function(e){var t=e.colorSettings,n=Object(Ee.a)(e,["colorSettings"]),r=t.map((function(e){var t=e.value,n=e.onChange;return vn(vn({},Object(Ee.a)(e,["value","onChange"])),{},{colorValue:t,onColorChange:n})}));return Object(u.createElement)(ze,Object(l.a)({settings:r,gradients:[],disableCustomGradients:!0},n))},On=function(e,t,n){return"function"==typeof e?e(t):!0===e?n:e};function hn(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)(gn,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(Ee.a)(e,["backgroundColor","textColor"]);return t=On(t,n,c),r=On(r,n,i),Object(u.createElement)(We,Object(l.a)({key:"".concat(t,"-").concat(r),backgroundColor:t,textColor:r},o))})):Object(b.map)(n,(function(e){var t=e.value,r=o.backgroundColor,a=o.textColor;return r=On(r||t,n,c),a=On(a||t,n,i),Object(u.createElement)(We,Object(l.a)({},o,{key:"".concat(r,"-").concat(a),backgroundColor:r,textColor:a}))}))),"function"==typeof a?a(n):a)}function jn(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 kn(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 kn(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 kn(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 yn(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 _n(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?yn(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function En(e){return e.ownerDocument.defaultView.getComputedStyle(e)}var Cn=[],wn={textColor:Object(O.__)("Text Color"),backgroundColor:Object(O.__)("Background Color")},Sn=function(e){return Object(u.createElement)(Qe,null,Object(u.createElement)(hn,e))};function In(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{panelTitle:Object(O.__)("Color settings")},n=t.panelTitle,r=void 0===n?Object(O.__)("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,g=void 0===m?l:m,h=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],j=Object(z.b)(),k=j.clientId,y=ve("color.palette")||Cn,_=Object(v.useSelect)((function(e){return{attributes:(0,e("core/block-editor").getBlockAttributes)(k)}}),[k]),E=_.attributes,C=Object(v.useDispatch)("core/block-editor"),w=C.updateBlockAttributes,S=Object(u.useCallback)((function(e){return w(k,e)}),[w,k]),I=Object(u.useMemo)((function(){return pn()((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,g={};r?g=s({},t,o):c&&(g=s({},t,c));var O={className:f()(p,(a={},s(a,"has-".concat(Object(b.kebabCase)(r),"-").concat(Object(b.kebabCase)(t)),r),s(a,n||"has-".concat(Object(b.kebabCase)(e)),r||c),a)),style:_n(_n({},g),v)};return Object(b.isFunction)(l)?l(O):u.Children.map(l,(function(e){return Object(u.cloneElement)(e,{className:f()(e.props.className,O.className),style:_n(_n({},O.style),e.props.style||{})})}))}}),{maxSize:e.length})}),[e.length]),B=Object(u.useMemo)((function(){return pn()((function(e,t){return function(n){var r=t.find((function(e){return e.color===n}));S(s({},r?Object(b.camelCase)("custom ".concat(e)):e,void 0)),S(s({},r?e:Object(b.camelCase)("custom ".concat(e)),r?r.slug:n))}}),{maxSize:e.length})}),[S,e.length]),x=Object(u.useState)(),P=Object(ie.a)(x,2),T=P[0],N=P[1],D=Object(u.useState)(),R=Object(ie.a)(D,2),A=R[0],M=R[1];return Object(u.useEffect)((function(){if(c){var e,t=!1,n=!1,r=jn(Object(b.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(En(g.current).color),t){for(var l=p.current,s=En(l).backgroundColor;"rgba(0, 0, 0, 0)"===s&&l.parentNode&&l.parentNode.nodeType===l.parentNode.ELEMENT_NODE;)s=En(l=l.parentNode).backgroundColor;N(s)}}}),[e.reduce((function(e,t){return"".concat(e," | ").concat(E[t.name]," | ").concat(E[Object(b.camelCase)("custom ".concat(t.name))])}),"")].concat(ce(h))),Object(u.useMemo)((function(){var t={},n=e.reduce((function(e,n){"string"==typeof n&&(n={name:n});var r=_n(_n({},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||wn[o]||Object(b.startCase)(o):l,u=r.componentName,d=void 0===u?Object(b.startCase)(o).replace(/\s/g,""):u,f=r.color,p=void 0===f?n.color:f,m=r.colors,v=void 0===m?y:m,g=E[Object(b.camelCase)("custom ".concat(o))],O=g?void 0:v.find((function(e){return e.slug===p}));return e[d]=I(o,i,a,p,O&&O.color,g),e[d].displayName=d,e[d].color=g||O&&O.color,e[d].slug=p,e[d].setColor=B(o,v),t[d]={value:O?O.color:E[Object(b.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 _n(_n({},n),{},{ColorPanel:Object(u.createElement)(hn,a),InspectorControlsColorPanel:Object(u.createElement)(Sn,a)})}),[E,S,A,T].concat(ce(h)))}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){s(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}function Pn(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var Tn=[],Nn=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=Object(b.reduce)(t,(function(e,t){return e[t]="custom".concat(Object(b.upperFirst)(t)),e}),{});return Object(p.createHigherOrderComponent)(Object(p.compose)([Object(p.createHigherOrderComponent)((function(e){return function(t){var n=ve("typography.fontSizes")||Tn;return Object(u.createElement)(e,Object(l.a)({},t,{fontSizes:n}))}}),"withFontSizes"),function(e){return function(t){Jt(o,t);var n=Pn(o);function o(e){var t;return $t(this,o),(t=n.call(this,e)).setters=t.createSetters(),t.state={},t}return Xt(o,[{key:"createSetters",value:function(){var e=this;return Object(b.reduce)(r,(function(t,n,r){var o=Object(b.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(b.find)(n.props.fontSizes,{size:Number(r)});n.props.setAttributes((s(o={},e,c&&c.slug?c.slug:void 0),s(o,t,c&&c.slug?void 0:r),o))}}},{key:"render",value:function(){return Object(u.createElement)(e,xn(xn(xn({},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(b.some)(r,c))return null;var i=Object(b.reduce)(Object(b.pickBy)(r,c),(function(e,t,r){var c=n[r],i=yt(o,c,n[t]);return e[r]=xn(xn({},i),{},{class:Et(c)}),e}),{});return xn(xn({},t),i)}}]),o}(u.Component)}]),"withFontSizes")},Dn=n(287),Rn=n(288),An=n(289);function Mn(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?Mn(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Fn=[{icon:Dn.a,title:Object(O.__)("Align text left"),align:"left"},{icon:Rn.a,title:Object(O.__)("Align text center"),align:"center"},{icon:An.a,title:Object(O.__)("Align text right"),align:"right"}],Vn={position:"bottom right",isAlternate:!0};var Hn=function(e){var t=e.value,n=e.onChange,r=e.alignmentControls,o=void 0===r?Fn:r,c=e.label,i=void 0===c?Object(O.__)("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 f=Object(b.find)(o,(function(e){return e.align===t}));return Object(u.createElement)(h.ToolbarGroup,{isCollapsed:l,icon:f?f.icon:s?An.a:Dn.a,label:i,popoverProps:Vn,controls:o.map((function(e){var n=e.align,r=t===n;return Ln(Ln({},e),{},{isActive:r,role:l?"menuitemradio":void 0,onClick:d(n)})}))})},zn=function(e){return e.name||""},Un=function(e){return e.title},Gn=function(e){return e.keywords||[]},Wn=function(e){return e.category},Kn=function(){return null};function qn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e=(e=(e=Object(b.deburr)(e)).replace(/^\//,"")).toLowerCase()}var $n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return Object(b.words)(qn(e))},Yn=function(e,t){return Object(b.differenceWith)(e,$n(t),(function(e,t){return t.includes(e)}))},Xn=function(e,t,n,r){return 0===$n(r).length?e:Qn(e,r,{getCategory:function(e){var n;return null===(n=Object(b.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))}})},Qn=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=$n(t);if(0===r.length)return e;var o=e.map((function(e){return[e,Zn(e,t,n)]})).filter((function(e){return Object(ie.a)(e,2)[1]>0}));return o.sort((function(e,t){var n=Object(ie.a)(e,2)[1];return Object(ie.a)(t,2)[1]-n})),o.map((function(e){return Object(ie.a)(e,1)[0]}))};function Zn(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.getName,o=void 0===r?zn:r,c=n.getTitle,i=void 0===c?Un:c,a=n.getKeywords,l=void 0===a?Gn:a,s=n.getCategory,u=void 0===s?Wn:s,d=n.getCollection,f=void 0===d?Kn:d,p=o(e),m=i(e),v=l(e),g=u(e),O=f(e),h=qn(t),j=qn(m),k=0;if(h===j)k+=30;else if(j.startsWith(h))k+=20;else{var y=[p,m].concat(ce(v),[g,O]).join(" "),_=Object(b.words)(h),E=Yn(_,y);0===E.length&&(k+=10)}return 0!==k&&p.startsWith("core/")&&k++,k}var Jn=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)}]},er=n(156);function tr(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:er.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:f()("block-editor-block-icon",c,{"has-colors":o})},i)}var nr={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=Jn(n,b.noop),c=Object(ie.a)(o,3),i=c[0],a=c[1],l=c[2],s=Object(u.useMemo)((function(){return(e.trim()?Xn(i,a,l,e):Object(b.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)(tr,{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))}}},rr=[];var or=function(e){var t=Object(z.b)().name,n=e.completers,r=void 0===n?rr:n;return r=Object(u.useMemo)((function(){var e=r;return t===Object(c.getDefaultBlockName)()&&(e=e.concat([nr])),Object(m.hasFilter)("editor.Autocomplete.completers")&&(e===r&&(e=e.map(b.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 cr=function(e){var t=e.label,n=void 0===t?Object(O.__)("Change matrix alignment"):t,r=e.onChange,o=void 0===r?b.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!==pt.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 ir(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(b.truncate)(l,{length:15})):a}var ar=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(O.__)("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(O.__)("Document")),!i&&Object(O.__)("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)(ir,{clientId:e})))})),!!o&&Object(u.createElement)("li",{className:"block-editor-block-breadcrumb__current","aria-current":"true"},Object(u.createElement)(ir,{clientId:o})))};function lr(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 sr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?lr(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):lr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ur=Object(u.createContext)({});function dr(e){var t=e.value,n=e.children,r=Object(u.useContext)(ur),o=Object(u.useMemo)((function(){return sr(sr({},r),t)}),[r,t]);return Object(u.createElement)(ur.Provider,{value:o,children:n})}var fr=ur,br=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"}))},pr=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)(br,null)))},mr=function(e){var t,n,r,o=e.children,c=Object(Ee.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(O.__)("Open Colors Selector"),onClick:t,onKeyDown:function(e){o||e.keyCode!==pt.DOWN||(e.preventDefault(),e.stopPropagation(),t())},icon:Object(u.createElement)(r,null,Object(u.createElement)(n,null,Object(u.createElement)(pr,null)))}))}),renderContent:function(){return o}})},vr={},gr=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)(fr),a=Object(u.useMemo)((function(){return o&&o.usesContext?Object(b.pick)(i,o.usesContext):vr}),[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=f()(d,n.className);return Object(u.createElement)(s,Object(l.a)({},e,{context:a,className:p}))}));function Or(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)(gr,e))}var hr=Object(h.createSlotFill)("BlockFormatControls"),jr=hr.Fill,kr=hr.Slot;var yr=function(e){return Object(z.b)().isSelected?Object(u.createElement)(jr,null,(function(t){var n=Object(b.isEmpty)(t)?null:t;return Object(u.createElement)(h.__experimentalToolbarContext.Provider,{value:n},e.children)})):null};yr.Slot=function(e){var t=Object(u.useContext)(h.__experimentalToolbarContext);return Object(u.createElement)(kr,Object(l.a)({},e,{fillProps:t}))};var _r=yr,Er=n(12),Cr=n.n(Er);function wr(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 Sr(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var c=e.apply(t,n);function i(e){wr(c,r,o,i,a,"next",e)}function a(e){wr(c,r,o,i,a,"throw",e)}i(void 0)}))}}var Ir=n(216),Br=n(114),xr=n(23),Pr=function(e){return e+1},Tr=function(e){return{top:e.offsetTop,left:e.offsetLeft}};var Nr=function(e,t,n,r,o){var c=Object(p.useReducedMotion)()||!r,i=Object(u.useReducer)(Pr,0),a=Object(ie.a)(i,2),l=a[0],s=a[1],d=Object(u.useReducer)(Pr,0),f=Object(ie.a)(d,2),b=f[0],m=f[1],v=Object(u.useState)({x:0,y:0}),g=Object(ie.a)(v,2),O=g[0],h=g[1],j=Object(u.useMemo)((function(){return e.current?Tr(e.current):null}),[o]),k=Object(u.useMemo)((function(){if(!n||!e.current)return function(){};var t=Object(xr.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=Tr(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(Br.useSpring)({from:{x:O.x,y:O.y},to:{x:0,y:0},reset:l!==b,config:{mass:5,tension:2e3,friction:200},immediate:c,onFrame:y})},Dr=Object(Br.animated)(h.__experimentalTreeGridRow);function Rr(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(Ee.a)(e,["isSelected","position","level","rowCount","children","className","path"]),d=Object(u.useRef)(null),b=a.join("_"),p=Nr(d,t,!1,!0,b);return Object(u.createElement)(Dr,Object(l.a)({ref:d,style:p,className:f()("block-editor-block-navigation-leaf",i),level:r,positionInSet:n,setSize:o},s),c)}var Ar=n(213),Mr=n(214),Lr=n(215),Fr=n(189);function Vr(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(O.__)("Blocks cannot be moved up as they are already at the top");if(o>0&&r)return Object(O.__)("Blocks cannot be moved down as they are already at the bottom");if(o<0&&!n)return Object(O.sprintf)(// translators: 1: Number of selected blocks, 2: Position of selected blocks
|
8 |
Object(O._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(O.sprintf)(// translators: 1: Number of selected blocks, 2: Position of selected blocks
|
9 |
Object(O._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(O.sprintf)(// translators: %s: Type of block (i.e. Text, Image etc)
|
10 |
Object(O.__)("Block %s is the only block, and cannot be moved"),t);if(c>0&&!o){var u=s("down");if("down"===u)return Object(O.sprintf)(// translators: 1: Type of block (i.e. Text, Image etc), 2: Position of selected block, 3: New position
|
19 |
Object(O.__)("Move %1$s block from position %2$d right to position %3$d"),t,l,l-1)}if(c<0&&r){var b=s("up");if("up"===b)return Object(O.sprintf)(// translators: 1: Type of block (i.e. Text, Image etc)
|
20 |
Object(O.__)("Block %1$s is at the beginning of the content and can’t be moved up"),t);if("left"===b)return Object(O.sprintf)(// translators: 1: Type of block (i.e. Text, Image etc)
|
21 |
Object(O.__)("Block %1$s is at the beginning of the content and can’t be moved left"),t);if("right"===b)return Object(O.sprintf)(// translators: 1: Type of block (i.e. Text, Image etc)
|
22 |
+
Object(O.__)("Block %1$s is at the beginning of the content and can’t be moved right"),t)}}var Hr=function(e,t,n){return"up"===e?"horizontal"===t?n?Ar.a:Mr.a:Lr.a:"down"===e?"horizontal"===t?n?Mr.a:Ar.a:Fr.a:null},zr=function(e,t,n){return"up"===e?"horizontal"===t?n?Object(O.__)("Move right"):Object(O.__)("Move left"):Object(O.__)("Move up"):"down"===e?"horizontal"===t?n?Object(O.__)("Move left"):Object(O.__)("Move right"):Object(O.__)("Move down"):null},Ur=Object(u.forwardRef)((function(e,t){var n=e.clientIds,r=e.direction,o=e.orientation,i=Object(Ee.a)(e,["clientIds","direction","orientation"]),a=Object(p.useInstanceId)(Ur),s=Object(b.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,f=Object(b.castArray)(n),p=Object(b.first)(f),m=a(p),v=i(p,m),g=i(Object(b.last)(f),m),O=l(m),h=s(p),j=0===v,k=g===O.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,g=d.isDisabled,O=d.rootClientId,j=d.isFirst,k=d.isLast,y=d.firstIndex,_=d.isRTL,E=d.orientation,C=void 0===E?"vertical":E,w=Object(v.useDispatch)("core/block-editor"),S=w.moveBlocksDown,I=w.moveBlocksUp,B="up"===r?I:S,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:f()("block-editor-block-mover-button","is-".concat(r,"-button")),icon:Hr(r,C,_),label:zr(r,C,_),"aria-describedby":x},i,{onClick:g?null:function(e){B(n,O),i.onClick&&i.onClick(e)},"aria-disabled":g})),Object(u.createElement)("span",{id:x,className:"block-editor-block-mover-button__description"},Vr(s,m&&m.title,y,j,k,"up"===r?-1:1,C,_)))})),Gr=Object(u.forwardRef)((function(e,t){return Object(u.createElement)(Ur,Object(l.a)({direction:"up",ref:t},e))})),Wr=Object(u.forwardRef)((function(e,t){return Object(u.createElement)(Ur,Object(l.a)({direction:"down",ref:t},e))}));function Kr(e){var t=e.level,n=e.isLastRow,r=e.terminatedLevels;return Object(b.times)(t-1,(function(e){var o=e+2,c=o===t;return Object(u.createElement)("div",{key:e,"aria-hidden":"true",className:f()("block-editor-block-navigator-descender-line",{"has-item":c,"is-last-row":n,"is-terminated":r.includes(o)})})}))}var qr=Object(u.createContext)({__experimentalFeatures:!1}),$r=function(){return Object(u.useContext)(qr)},Yr=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 Xr=function(e){var t=e.className,n=e.actions,r=e.children,o=e.secondaryActions;return Object(u.createElement)("div",{className:f()(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:Yr,label:Object(O.__)("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)})))})))))},Qr=n(265),Zr=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 Jr=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(b.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(Qr.diffChars)(e,t).map((function(e,t){var n=f()({"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)(Zr,{title:Object(O.__)("Current"),className:"block-editor-block-compare__current",action:a,actionText:Object(O.__)("Convert to HTML"),rawContent:p.rawContent,renderedContent:p.renderedContent}),Object(u.createElement)(Zr,{title:Object(O.__)("After Conversion"),className:"block-editor-block-compare__converted",action:l,actionText:d,rawContent:v,renderedContent:m.renderedContent}))};var eo=function(e){return Object(c.rawHandler)({HTML:e.originalContent})},to=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,eo(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(ie.a)(l,2),d=s[0],f=s[1],b=Object(u.useCallback)((function(){return f(!0)}),[]),p=Object(u.useCallback)((function(){return f(!1)}),[]),m=Object(u.useMemo)((function(){return[{
|
23 |
// translators: Button to fix block content
|
24 |
title:Object(O._x)("Resolve","imperative verb"),onClick:b},a&&{title:Object(O.__)("Convert to HTML"),onClick:t},{title:Object(O.__)("Convert to Classic Block"),onClick:r}].filter(Boolean)}),[b,t,r]);return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(Xr,{actions:[Object(u.createElement)(h.Button,{key:"recover",onClick:o,isPrimary:!0},Object(O.__)("Attempt Block Recovery"))],secondaryActions:m},Object(O.__)("This block contains unexpected or invalid content.")),d&&Object(u.createElement)(h.Modal,{title:// translators: Dialog title to fix block content
|
25 |
+
Object(O.__)("Resolve Block"),onRequestClose:p,className:"block-editor-block-compare"},Object(u.createElement)(Jr,{block:i,onKeep:t,onConvert:n,convertor:eo,convertButtonText:Object(O.__)("Convert to Blocks")})))})),no=Object(u.createElement)(Xr,{className:"block-editor-block-list__block-crash-warning"},Object(O.__)("This block has encountered an error and cannot be previewed.")),ro=function(){return no};function oo(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var co=function(e){Jt(n,e);var t=oo(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).state={hasError:!1},e}return Xt(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),io=n(97),ao=n.n(io);var lo=function(e){var t=e.clientId,n=Object(u.useState)(""),r=Object(ie.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)(ao.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)}})},so=n(31),uo=n.n(so);function fo(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 bo(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 po(e,t){Array.from(e.querySelectorAll(".rich-text")).forEach((function(e){t?e.setAttribute("contenteditable",!0):e.removeAttribute("contenteditable")}))}var mo=n(157),vo=[Object(u.createInterpolateElement)(Object(O.__)("While writing, you can press <kbd>/</kbd> to quickly insert new blocks."),{kbd:Object(u.createElement)("kbd",null)}),Object(u.createInterpolateElement)(Object(O.__)("Indent a list by pressing <kbd>space</kbd> at the beginning of a line."),{kbd:Object(u.createElement)("kbd",null)}),Object(u.createInterpolateElement)(Object(O.__)("Outdent a list by pressing <kbd>backspace</kbd> at the beginning of a line."),{kbd:Object(u.createElement)("kbd",null)}),Object(O.__)("Drag files into the editor to automatically insert media blocks."),Object(O.__)("Change a block's type by pressing the block icon on the toolbar.")];var go=function(){var e=Object(u.useState)(Math.floor(Math.random()*vo.length)),t=Object(ie.a)(e,1)[0];return Object(u.createElement)(h.Tip,null,vo[t])},Oo=n(127),ho=n(144),jo=n(290);var ko=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:f()("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:Oo.a,label:Object(O.__)("Reset search"),onClick:function(){r(""),a.current.focus()}}),!o&&Object(u.createElement)(ho.a,{icon:jo.a})))};var yo=function(e){var t=e.blockType;return Object(u.createElement)("div",{className:"block-editor-block-card"},Object(u.createElement)(tr,{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)))},_o={insertUsage:{}},Eo={alignWide:!1,colors:[{name:Object(O.__)("Black"),slug:"black",color:"#000000"},{name:Object(O.__)("Cyan bluish gray"),slug:"cyan-bluish-gray",color:"#abb8c3"},{name:Object(O.__)("White"),slug:"white",color:"#ffffff"},{name:Object(O.__)("Pale pink"),slug:"pale-pink",color:"#f78da7"},{name:Object(O.__)("Vivid red"),slug:"vivid-red",color:"#cf2e2e"},{name:Object(O.__)("Luminous vivid orange"),slug:"luminous-vivid-orange",color:"#ff6900"},{name:Object(O.__)("Luminous vivid amber"),slug:"luminous-vivid-amber",color:"#fcb900"},{name:Object(O.__)("Light green cyan"),slug:"light-green-cyan",color:"#7bdcb5"},{name:Object(O.__)("Vivid green cyan"),slug:"vivid-green-cyan",color:"#00d084"},{name:Object(O.__)("Pale cyan blue"),slug:"pale-cyan-blue",color:"#8ed1fc"},{name:Object(O.__)("Vivid cyan blue"),slug:"vivid-cyan-blue",color:"#0693e3"},{name:Object(O.__)("Vivid purple"),slug:"vivid-purple",color:"#9b51e0"}],fontSizes:[{name:Object(O._x)("Small","font size name"),size:13,slug:"small"},{name:Object(O._x)("Normal","font size name"),size:16,slug:"normal"},{name:Object(O._x)("Medium","font size name"),size:20,slug:"medium"},{name:Object(O._x)("Large","font size name"),size:36,slug:"large"},{name:Object(O._x)("Huge","font size name"),size:42,slug:"huge"}],imageSizes:[{slug:"thumbnail",name:Object(O.__)("Thumbnail")},{slug:"medium",name:Object(O.__)("Medium")},{slug:"large",name:Object(O.__)("Large")},{slug:"full",name:Object(O.__)("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(O.__)("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(O.__)("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(O.__)("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(O.__)("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(O.__)("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(O.__)("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(O.__)("Blush light purple"),gradient:"linear-gradient(135deg,rgb(255,206,236) 0%,rgb(152,150,240) 100%)",slug:"blush-light-purple"},{name:Object(O.__)("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(O.__)("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(O.__)("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(O.__)("Electric grass"),gradient:"linear-gradient(135deg,rgb(202,248,128) 0%,rgb(113,206,126) 100%)",slug:"electric-grass"},{name:Object(O.__)("Midnight"),gradient:"linear-gradient(135deg,rgb(2,3,129) 0%,rgb(40,116,252) 100%)",slug:"midnight"}]};function Co(e,t,n){return[].concat(ce(e.slice(0,n)),ce(Object(b.castArray)(t)),ce(e.slice(n)))}function wo(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,o=ce(e);return o.splice(t,r),Co(o,e.slice(t,t+r),n)}function So(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 Io(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?So(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):So(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Bo(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=s({},t,[]);return e.forEach((function(e){var r=e.clientId,o=e.innerBlocks;n[t].push(r),Object.assign(n,Bo(o,r))})),n}function xo(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return e.reduce((function(e,n){return Object.assign(e,s({},n.clientId,t),xo(n.innerBlocks,n.clientId))}),{})}function Po(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:b.identity,n={},r=ce(e);r.length;){var o=r.shift(),c=o.innerBlocks,i=Object(Ee.a)(o,["innerBlocks"]);r.push.apply(r,ce(c)),n[i.clientId]=t(i)}return n}function To(e){return Po(e,(function(e){return Object(b.omit)(e,"attributes")}))}function No(e){return Po(e,(function(e){return e.attributes}))}function Do(e,t){return e===t?Io({},e):t}function Ro(e,t){return"UPDATE_BLOCK_ATTRIBUTES"===e.type&&void 0!==t&&"UPDATE_BLOCK_ATTRIBUTES"===t.type&&Object(b.isEqual)(e.clientIds,t.clientIds)&&(n=e.attributes,r=t.attributes,Object(b.isEqual)(Object(b.keys)(n),Object(b.keys)(r)));var n,r}var Ao=function(e){return e.reduce((function(e,t){return e[t]={},e}),{})};var Mo=Object(b.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=Io({},t)).attributes=Object(b.mapValues)(t.attributes,(function(e,n){return"core/block"===t.byClientId[n].name&&e.ref===r?Io(Io({},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(b.mapValues)(Po(n.blocks),(function(){return{}}));break;case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":var c=Object(b.keys)(Po(n.blocks));n.rootClientId&&!t.controlledInnerBlocks[n.rootClientId]&&c.push(n.rootClientId),r.cache=Io(Io({},r.cache),Ao(o(c)));break;case"UPDATE_BLOCK":r.cache=Io(Io({},r.cache),Ao(o([n.clientId])));break;case"UPDATE_BLOCK_ATTRIBUTES":r.cache=Io(Io({},r.cache),Ao(o(n.clientIds)));break;case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":var i=Ao(o(n.replacedClientIds));r.cache=Io(Io(Io({},Object(b.omit)(r.cache,n.replacedClientIds)),Object(b.omit)(i,n.replacedClientIds)),Ao(Object(b.keys)(Po(n.blocks))));break;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":r.cache=Io(Io({},Object(b.omit)(r.cache,n.removedClientIds)),Ao(Object(b.difference)(o(n.clientIds),n.clientIds)));break;case"MOVE_BLOCKS_TO_POSITION":var a=ce(n.clientIds);n.fromRootClientId&&a.push(n.fromRootClientId),n.toRootClientId&&a.push(n.toRootClientId),r.cache=Io(Io({},r.cache),Ao(o(a)));break;case"MOVE_BLOCKS_UP":case"MOVE_BLOCKS_DOWN":var l=[];n.rootClientId&&l.push(n.rootClientId),r.cache=Io(Io({},r.cache),Ao(o(l)));break;case"SAVE_REUSABLE_BLOCK_SUCCESS":var s=Object(b.keys)(Object(b.omitBy)(r.attributes,(function(e,t){return"core/block"!==r.byClientId[t].name||e.ref!==n.updatedId})));r.cache=Io(Io({},r.cache),Ao(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=ce(r)),(c=r).push.apply(c,ce(t.order[r[o]])))}return r};if(t)switch(n.type){case"REMOVE_BLOCKS":n=Io(Io({},n),{},{type:"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN",removedClientIds:r(n.clientIds)});break;case"REPLACE_BLOCKS":n=Io(Io({},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=ce(n.blocks);o.length;){var c=o.shift(),i=c.innerBlocks,a=Object(Ee.a)(c,["innerBlocks"]);o.push.apply(o,ce(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,Io(Io({},n),{},{type:"INSERT_BLOCKS",index:0}))).order=Io(Io({},s.order),Object(b.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(b.reduce)(t[n],(function(n,o){return r[o]?n:[].concat(ce(n),[o],ce(e(t,o)))}),[])}(t.order,"",t.controlledInnerBlocks),o=Object.keys(Object(b.pickBy)(t.controlledInnerBlocks));return Io(Io({},t),{},{byClientId:Io(Io({},Object(b.omit)(t.byClientId,r)),To(n.blocks)),attributes:Io(Io({},Object(b.omit)(t.attributes,r)),No(n.blocks)),order:Io(Io({},Object(b.omit)(t.order,r)),Object(b.omit)(Bo(n.blocks),o)),parents:Io(Io({},Object(b.omit)(t.parents,r)),xo(n.blocks)),cache:Io(Io({},Object(b.omit)(t.cache,r)),Object(b.omit)(Object(b.mapValues)(Po(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:Io(Io({},c),{},{isPersistentChange:l})}return c=Io(Io({},c),{},{isPersistentChange:i?!n:!Ro(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 To(t.blocks);case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":return Io(Io({},e),To(t.blocks));case"UPDATE_BLOCK":if(!e[t.clientId])return e;var n=Object(b.omit)(t.updates,"attributes");return Object(b.isEmpty)(n)?e:Io(Io({},e),{},s({},t.clientId,Io(Io({},e[t.clientId]),n)));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return t.blocks?Io(Io({},Object(b.omit)(e,t.replacedClientIds)),To(t.blocks)):e;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(b.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 No(t.blocks);case"RECEIVE_BLOCKS":case"INSERT_BLOCKS":return Io(Io({},e),No(t.blocks));case"UPDATE_BLOCK":return e[t.clientId]&&t.updates.attributes?Io(Io({},e),{},s({},t.clientId,Io(Io({},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 Io(Io({},n),{},s({},r,Object(b.reduce)(t.attributes,(function(t,n,o){return n!==t[o]&&((t=Do(e[r],t))[o]=n),t}),e[r])))}),{});return t.clientIds.every((function(t){return n[t]===e[t]}))?e:Io(Io({},e),n);case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return t.blocks?Io(Io({},Object(b.omit)(e,t.replacedClientIds)),No(t.blocks)):e;case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(b.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 Bo(t.blocks);case"RECEIVE_BLOCKS":return Io(Io({},e),Object(b.omit)(Bo(t.blocks),""));case"INSERT_BLOCKS":var n=t.rootClientId,r=void 0===n?"":n,o=e[r]||[],c=Bo(t.blocks,r),i=t.index,a=void 0===i?o.length:i;return Io(Io(Io({},e),c),{},s({},r,Co(o,c[r],a)));case"MOVE_BLOCKS_TO_POSITION":var l,u=t.fromRootClientId,d=void 0===u?"":u,f=t.toRootClientId,p=void 0===f?"":f,m=t.clientIds,v=t.index,g=void 0===v?e[p].length:v;if(d===p){var O=e[p],h=O.indexOf(m[0]);return Io(Io({},e),{},s({},p,wo(e[p],h,g,m.length)))}return Io(Io({},e),{},(s(l={},d,b.without.apply(void 0,[e[d]].concat(ce(m)))),s(l,p,Co(e[p],m,g)),l));case"MOVE_BLOCKS_UP":var j=t.clientIds,k=t.rootClientId,y=void 0===k?"":k,_=Object(b.first)(j),E=e[y];if(!E.length||_===Object(b.first)(E))return e;var C=E.indexOf(_);return Io(Io({},e),{},s({},y,wo(E,C,C-1,j.length)));case"MOVE_BLOCKS_DOWN":var w=t.clientIds,S=t.rootClientId,I=void 0===S?"":S,B=Object(b.first)(w),x=Object(b.last)(w),P=e[I];if(!P.length||x===Object(b.last)(P))return e;var T=P.indexOf(B);return Io(Io({},e),{},s({},I,wo(P,T,T+1,w.length)));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":var N=t.clientIds;if(!t.blocks)return e;var D=Bo(t.blocks);return Object(b.flow)([function(e){return Object(b.omit)(e,t.replacedClientIds)},function(e){return Io(Io({},e),Object(b.omit)(D,""))},function(e){return Object(b.mapValues)(e,(function(e){return Object(b.reduce)(e,(function(e,t){return t===N[0]?[].concat(ce(e),ce(D[""])):(-1===N.indexOf(t)&&e.push(t),e)}),[])}))}])(e);case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(b.flow)([function(e){return Object(b.omit)(e,t.removedClientIds)},function(e){return Object(b.mapValues)(e,(function(e){return b.without.apply(void 0,[e].concat(ce(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 xo(t.blocks);case"RECEIVE_BLOCKS":return Io(Io({},e),xo(t.blocks));case"INSERT_BLOCKS":return Io(Io({},e),xo(t.blocks,t.rootClientId||""));case"MOVE_BLOCKS_TO_POSITION":return Io(Io({},e),t.clientIds.reduce((function(e,n){return e[n]=t.toRootClientId||"",e}),{}));case"REPLACE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Io(Io({},Object(b.omit)(e,t.replacedClientIds)),xo(t.blocks,e[t.clientIds[0]]));case"REMOVE_BLOCKS_AUGMENTED_WITH_CHILDREN":return Object(b.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?Io(Io({},e),{},s({},r,o)):e}});function Lo(){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}var Fo=Object(v.combineReducers)({blocks:Mo,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 Lo(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 Lo(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 Io(Io({},e),{},s({},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(b.omit)(e,t.clientIds);case"UPDATE_BLOCK_LIST_SETTINGS":var n=t.clientId;return t.settings?Object(b.isEqual)(e[n],t.settings)?e:Io(Io({},e),{},s({},n,t.settings)):e.hasOwnProperty(n)?Object(b.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"SHOW_INSERTION_POINT":var n=t.rootClientId,r=t.index;return{rootClientId:n,index:r};case"HIDE_INSERTION_POINT":return null}return e},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 Io(Io({},e),{},{isValid:t.isValid})}return e},settings:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Eo,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"UPDATE_SETTINGS":return Io(Io({},e),t.settings)}return e},preferences:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:_o,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),Io(Io({},e),{},{insertUsage:Io(Io({},e.insertUsage),{},s({},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 s({},t.clientId,t.updates.attributes);case"UPDATE_BLOCK_ATTRIBUTES":return t.clientIds.reduce((function(e,n){return Io(Io({},e),{},s({},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}}),Vo=n(146),Ho=n.n(Vo),zo=n(263),Uo=n.n(zo);function Go(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 Wo(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 Wo(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 Wo(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 Ko(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 qo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ko(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ko(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var $o=Cr.a.mark(lc),Yo=Cr.a.mark(mc),Xo=Cr.a.mark(vc),Qo=Cr.a.mark(_c),Zo=Cr.a.mark(Ic),Jo=Cr.a.mark(Bc),ec=Cr.a.mark(Pc),tc=Cr.a.mark(Mc),nc=Cr.a.mark(ti),rc=Cr.a.mark(ni),oc=Cr.a.mark(ri),cc=Cr.a.mark(oi),ic=Cr.a.mark(ci),ac=Cr.a.mark(ai);function lc(){return Cr.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,$c();case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}}),$o)}function sc(e){return{type:"RESET_BLOCKS",blocks:e}}function uc(e,t){return{type:"RESET_SELECTION",selectionStart:e,selectionEnd:t}}function dc(e){return{type:"RECEIVE_BLOCKS",blocks:e}}function fc(e,t){return{type:"UPDATE_BLOCK_ATTRIBUTES",clientIds:Object(b.castArray)(e),attributes:t}}function bc(e,t){return{type:"UPDATE_BLOCK",clientId:e,updates:t}}function pc(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return{type:"SELECT_BLOCK",initialPosition:t,clientId:e}}function mc(e){var t;return Cr.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,pc(t,-1);case 6:return n.abrupt("return",[t]);case 7:case"end":return n.stop()}}),Yo)}function vc(e){var t;return Cr.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,pc(t);case 6:return n.abrupt("return",[t]);case 7:case"end":return n.stop()}}),Xo)}function gc(){return{type:"START_MULTI_SELECT"}}function Oc(){return{type:"STOP_MULTI_SELECT"}}function hc(e,t){return{type:"MULTI_SELECT",start:e,end:t}}function jc(){return{type:"CLEAR_SELECTED_BLOCK"}}function kc(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return{type:"TOGGLE_SELECTION",isSelectionEnabled:e}}function yc(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 qo(qo({},e),{},{attributes:qo(qo({},a),{},{className:"".concat(r||""," is-style-").concat(l).trim()})})}))}function _c(e,t,n,r,o){var c,i,a;return Cr.a.wrap((function(l){for(;;)switch(l.prev=l.next){case 0:return e=Object(b.castArray)(e),l.t0=yc,l.t1=Object(b.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(b.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(lc(),"t3",24);case 24:case"end":return l.stop()}}),Qo)}function Ec(e,t){return _c(e,t)}function Cc(e){return function(t,n){return{clientIds:Object(b.castArray)(t),type:e,rootClientId:n}}}var wc=Cc("MOVE_BLOCKS_DOWN"),Sc=Cc("MOVE_BLOCKS_UP");function Ic(e){var t,n,r,o,c,i=arguments;return Cr.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()}}),Zo)}function Bc(e){var t,n,r,o=arguments;return Cr.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,Ic([e],t,n,r);case 5:case"end":return c.stop()}}),Jo)}function xc(e,t,n){var r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];return Pc([e],t,n,r)}function Pc(e,t,n){var r,o,c,i,a,l,s=arguments;return Cr.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=yc,u.t1=Object(b.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=Go(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()}}),ec,null,[[10,22,25,28]])}function Tc(e,t){return{type:"SHOW_INSERTION_POINT",rootClientId:e,index:t}}function Nc(){return{type:"HIDE_INSERTION_POINT"}}function Dc(e){return{type:"SET_TEMPLATE_VALIDITY",isValid:e}}function Rc(){return{type:"SYNCHRONIZE_TEMPLATE"}}function Ac(e,t){return{type:"MERGE_BLOCKS",blocks:[e,t]}}function Mc(e){var t,n,r,o,c=arguments;return Cr.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(b.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,mc(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(lc(),"t0",24);case 24:return o=i.t0,i.abrupt("return",[r||o]);case 26:case"end":return i.stop()}}),tc)}function Lc(e,t){return Mc([e],t)}function Fc(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 Vc(e){return{type:"TOGGLE_BLOCK_MODE",clientId:e}}function Hc(){return{type:"START_TYPING"}}function zc(){return{type:"STOP_TYPING"}}function Uc(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return{type:"START_DRAGGING_BLOCKS",clientIds:e}}function Gc(){return{type:"STOP_DRAGGING_BLOCKS"}}function Wc(){return{type:"ENTER_FORMATTED_TEXT"}}function Kc(){return{type:"EXIT_FORMATTED_TEXT"}}function qc(e,t,n,r){return{type:"SELECTION_CHANGE",clientId:e,attributeKey:t,startOffset:n,endOffset:r}}function $c(e,t,n){var r=Object(c.getDefaultBlockName)();if(r)return xc(Object(c.createBlock)(r,e),n,t)}function Yc(e,t){return{type:"UPDATE_BLOCK_LIST_SETTINGS",clientId:e,settings:t}}function Xc(e){return{type:"UPDATE_SETTINGS",settings:e}}function Qc(e,t){return{type:"SAVE_REUSABLE_BLOCK_SUCCESS",id:e,updatedId:t}}function Zc(){return{type:"MARK_LAST_CHANGE_AS_PERSISTENT"}}function Jc(){return{type:"MARK_NEXT_CHANGE_AS_NOT_PERSISTENT"}}function ei(){return{type:"MARK_AUTOMATIC_CHANGE"}}function ti(){var e,t=arguments;return Cr.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(Ue.speak)(Object(O.__)("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(Ue.speak)(Object(O.__)("You are currently in edit mode. To return to the navigation mode, press Escape."));case 4:case"end":return n.stop()}}),nc)}function ni(){var e,t=arguments;return Cr.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(Ue.speak)(Object(O.__)("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()}}),rc)}function ri(e){var t,n,r,o,i,a,l=arguments;return Cr.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(b.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(b.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(b.last)(Object(b.castArray)(e)),r);case 16:return i=s.sent,a=n.map((function(e){return Object(c.cloneBlock)(e)})),s.next=20,Pc(a,i+1,r,t);case 20:if(!(a.length>1&&t)){s.next=23;break}return s.next=23,hc(Object(b.first)(a).clientId,Object(b.last)(a).clientId);case 23:return s.abrupt("return",a.map((function(e){return e.clientId})));case 24:case"end":return s.stop()}}),oc)}function oi(e){var t,n;return Cr.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,$c({},t,n);case 15:return r.abrupt("return",r.sent);case 16:case"end":return r.stop()}}),cc)}function ci(e){var t,n;return Cr.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,$c({},t,n+1);case 15:return r.abrupt("return",r.sent);case 16:case"end":return r.stop()}}),ic)}function ii(e,t){return{type:"TOGGLE_BLOCK_HIGHLIGHT",clientId:e,isHighlighted:t}}function ai(e){return Cr.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ii(e,!0);case 2:return t.next=4,{type:"SLEEP",duration:150};case 4:return t.next=6,ii(e,!1);case 6:case"end":return t.stop()}}),ac)}function li(e,t){return{type:"SET_HAS_CONTROLLED_INNER_BLOCKS",hasControlledInnerBlocks:t,clientId:e}}var si=n(44);function ui(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 di(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 di(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 di(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 fi(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 bi(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?fi(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fi(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var pi=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"}))),mi=[];function vi(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 gi(e,t){var n=e.blocks.byClientId[t];return!!n&&n.isValid}function Oi(e,t){return e.blocks.byClientId[t]?e.blocks.attributes[t]:null}var hi=Object(si.a)((function(e,t){var n=e.blocks.byClientId[t];return n?bi(bi({},n),{},{attributes:Oi(e,t),innerBlocks:Ua(e,t)?mi:ki(e,t)}):null}),(function(e,t){return[e.blocks.cache[t]]})),ji=Object(si.a)((function(e,t){var n=e.blocks.byClientId[t];return n?bi(bi({},n),{},{attributes:Oi(e,t)}):null}),(function(e,t){return[e.blocks.byClientId[t],e.blocks.attributes[t]]})),ki=Object(si.a)((function(e,t){return Object(b.map)(na(e,t),(function(t){return hi(e,t)}))}),(function(e,t){return Object(b.map)(e.blocks.order[t||""],(function(t){return e.blocks.cache[t]}))})),yi=Object(si.a)((function(e,t){var n=e.blocks.byClientId[t];return n?bi(bi({},n),{},{attributes:Oi(e,t),innerBlocks:_i(e,t)}):null}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]})),_i=Object(si.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Object(b.map)(na(e,t),(function(t){return yi(e,t)}))}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]})),Ei=function e(t,n){return Object(b.flatMap)(n,(function(n){var r=na(t,n);return[].concat(ce(r),ce(e(t,r)))}))},Ci=Object(si.a)((function(e){var t=na(e);return[].concat(ce(t),ce(Ei(e,t)))}),(function(e){return[e.blocks.order]})),wi=Object(si.a)((function(e,t){var n=Ci(e);return t?Object(b.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]})),Si=Object(si.a)((function(e,t){return Object(b.map)(Object(b.castArray)(t),(function(t){return hi(e,t)}))}),(function(e){return[e.blocks.byClientId,e.blocks.order,e.blocks.attributes]}));function Ii(e,t){return na(e,t).length}function Bi(e){return e.selectionStart}function xi(e){return e.selectionEnd}function Pi(e){return e.selectionStart.clientId}function Ti(e){return e.selectionEnd.clientId}function Ni(e){var t=qi(e).length;return t||(e.selectionStart.clientId?1:0)}function Di(e){var t=e.selectionStart,n=e.selectionEnd;return!!t.clientId&&t.clientId===n.clientId}function Ri(e){var t=e.selectionStart,n=e.selectionEnd,r=t.clientId;return r&&r===n.clientId?r:null}function Ai(e){var t=Ri(e);return t?hi(e,t):null}function Mi(e,t){return void 0!==e.blocks.parents[t]?e.blocks.parents[t]:null}var Li=Object(si.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]})),Fi=Object(si.a)((function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=Li(e,t,r);return Object(b.map)(Object(b.filter)(Object(b.map)(o,(function(t){return{id:t,name:vi(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 Vi(e,t){var n,r=t;do{n=r,r=e.blocks.parents[r]}while(r);return n}function Hi(e,t){for(var n,r=Ri(e),o=[].concat(ce(Li(e,t)),[t]),c=[].concat(ce(Li(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 zi(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;if(void 0===t&&(t=Ri(e)),void 0===t&&(t=n<0?Yi(e):Xi(e)),!t)return null;var r=Mi(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 Ui(e,t){return zi(e,t,-1)}function Gi(e,t){return zi(e,t,1)}function Wi(e){return e.initialPosition}var Ki=Object(si.a)((function(e){var t=e.selectionStart,n=e.selectionEnd;if(void 0===t.clientId||void 0===n.clientId)return mi;if(t.clientId===n.clientId)return[t.clientId];var r=Mi(e,t.clientId);if(null===r)return mi;var o=na(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 qi(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?mi:Ki(e)}var $i=Object(si.a)((function(e){var t=qi(e);return t.length?t.map((function(t){return hi(e,t)})):mi}),(function(e){return[].concat(ce(Ki.getDependants(e)),[e.blocks.byClientId,e.blocks.order,e.blocks.attributes])}));function Yi(e){return Object(b.first)(qi(e))||null}function Xi(e){return Object(b.last)(qi(e))||null}function Qi(e,t){return Yi(e)===t}function Zi(e,t){return-1!==qi(e).indexOf(t)}var Ji=Object(si.a)((function(e,t){for(var n=t,r=!1;n&&!r;)r=Zi(e,n=Mi(e,n));return r}),(function(e){return[e.blocks.order,e.selectionStart.clientId,e.selectionEnd.clientId]}));function ea(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?null:t.clientId||null}function ta(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId===n.clientId?null:n.clientId||null}function na(e,t){return e.blocks.order[t||""]||mi}function ra(e,t,n){return na(e,n).indexOf(t)}function oa(e,t){var n=e.selectionStart,r=e.selectionEnd;return n.clientId===r.clientId&&n.clientId===t}function ca(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return Object(b.some)(na(e,t),(function(t){return oa(e,t)||Zi(e,t)||n&&ca(e,t,n)}))}function ia(e,t){if(!t)return!1;var n=qi(e),r=n.indexOf(t);return r>-1&&r<n.length-1}function aa(e){var t=e.selectionStart,n=e.selectionEnd;return t.clientId!==n.clientId}function la(e){return e.isMultiSelecting}function sa(e){return e.isSelectionEnabled}function ua(e,t){return e.blocksMode[t]||"visual"}function da(e){return e.isTyping}function fa(e){return!!e.draggedBlocks.length}function ba(e){return e.draggedBlocks}function pa(e,t){return e.draggedBlocks.includes(t)}function ma(e,t){if(!fa(e))return!1;var n=Li(e,t);return Object(b.some)(n,(function(t){return pa(e,t)}))}function va(e){return e.isCaretWithinFormattedText}function ga(e){var t,n,r=e.insertionPoint,o=e.selectionEnd;if(null!==r)return r;var c=o.clientId;return c?(t=Mi(e,c)||void 0,n=ra(e,o.clientId,t)+1):n=na(e).length,{rootClientId:t,index:n}}function Oa(e){return null!==e.insertionPoint}function ha(e){return e.template.isValid}function ja(e){return e.settings.template}function ka(e,t){if(!t)return e.settings.templateLock;var n=Pa(e,t);return n?n.templateLock:null}var ya=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(b.isBoolean)(e)?e:Object(b.isArray)(e)?!(!e.includes("core/post-content")||null!==t)||e.includes(t):n},o=Object(c.getBlockType)(t);if(!o)return!1;var i=Ta(e),a=i.allowedBlockTypes,l=r(a,t,!0);if(!l)return!1;var s=!!ka(e,n);if(s)return!1;var u=Pa(e,n);if(n&&void 0===u)return!1;var d=null==u?void 0:u.allowedBlocks,f=r(d,t),p=o.parent,m=vi(e,n),v=r(p,m);return null!==f&&null!==v?f||v:null!==f?f:null===v||v},_a=Object(si.a)(ya,(function(e,t,n){return[e.blockListSettings[n],e.blocks.byClientId[n],e.settings.allowedBlockTypes,e.settings.templateLock]}));function Ea(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return t.every((function(t){return _a(e,vi(e,t),n)}))}function Ca(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 wa=function(e,t,n){return!!Object(c.hasBlockSupport)(t,"inserter",!0)&&ya(e,t.name,n)},Sa=function(e){return function(t){return bi(bi({},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:bi(bi({},e.initialAttributes),t.attributes),innerBlocks:t.innerBlocks,keywords:t.keywords||e.keywords})}},Ia=Object(si.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(b.some)(Si(e,Ci(e)),{name:t.name}));var i=Ca(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=Ra(e,t.id);1===i.length&&(n=Object(c.getBlockType)(i[0].name));var a=Ca(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:pi,category:"reusable",keywords:[],isDisabled:!1,utility:1,frecency:u}},a=Object(c.getBlockTypes)().filter((function(t){return wa(e,t,n)})).map(o),l=ya(e,"core/block",n)?La(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=ui(a);try{for(d.s();!(t=d.n()).done;){var f=t.value,p=f.variations,m=void 0===p?[]:p;if(m.length){var v=Sa(f);u.push.apply(u,ce(m.map(v)))}}}catch(e){d.e(e)}finally{d.f()}return[].concat(ce(s),u,ce(l))}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.blocks.order,e.preferences.insertUsage,e.settings.allowedBlockTypes,e.settings.templateLock,La(e),Object(c.getBlockTypes)()]})),Ba=Object(si.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=Object(b.some)(Object(c.getBlockTypes)(),(function(n){return wa(e,n,t)}));if(n)return!0;var r=ya(e,"core/block",t)&&La(e).length>0;return r}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.settings.allowedBlockTypes,e.settings.templateLock,La(e),Object(c.getBlockTypes)()]})),xa=Object(si.a)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(t)return Object(b.filter)(Object(c.getBlockTypes)(),(function(n){return wa(e,n,t)}))}),(function(e,t){return[e.blockListSettings[t],e.blocks.byClientId,e.settings.allowedBlockTypes,e.settings.templateLock,Object(c.getBlockTypes)()]}));function Pa(e,t){return e.blockListSettings[t]}function Ta(e){return e.settings}function Na(e){return e.blocks.isPersistentChange}var Da=Object(si.a)((function(e,t){return Object(b.filter)(e.blockListSettings,(function(e,n){return t.includes(n)}))}),(function(e){return[e.blockListSettings]})),Ra=Object(si.a)((function(e,t){var n=Object(b.find)(La(e),(function(e){return e.id===t}));return n?Object(c.parse)(n.content.raw||n.content):null}),(function(e){return[La(e)]}));function Aa(e){return e.blocks.isIgnoredChange}function Ma(e){return e.lastBlockAttributesChange}function La(e){var t,n;return null!==(t=null==e||null===(n=e.settings)||void 0===n?void 0:n.__experimentalReusableBlocks)&&void 0!==t?t:mi}function Fa(e){return e.isNavigationMode}function Va(e){return e.hasBlockMovingClientId}function Ha(e){return!!e.automaticChangeStatus}function za(e,t){return e.highlightedBlock===t}function Ua(e,t){return!!e.blocks.controlledInnerBlocks[t]}var Ga=Object(si.a)((function(e,t){if(!t.length)return null;var n=Ri(e);if(t.includes(vi(e,n)))return n;var r=qi(e),o=Fi(e,n||r[0],t);return o?Object(b.last)(o):null}),(function(e,t){return[e.selectionStart.clientId,e.selectionEnd.clientId,t]}));function Wa(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 Ka(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Wa(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Wa(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var qa={MERGE_BLOCKS:function(e,t){var n=t.dispatch,r=t.getState(),o=Object(ie.a)(e.blocks,2),a=o[0],l=o[1],s=hi(r,a),u=Object(c.getBlockType)(s.name);if(u.merge){var d=hi(r,l),f=Object(c.getBlockType)(d.name),p=Bi(r),m=p.clientId,v=p.attributeKey,g=p.offset,O=(m===a?u:f).attributes[v],h=(m===a||m===l)&&void 0!==v&&void 0!==g&&!!O;O||("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(en(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=O.multiline,C=O.__unstableMultilineWrapperTags,w=O.__unstablePreserveWhiteSpace,S=Object(i.insert)(Object(i.create)({html:_,multilineTag:E,multilineWrapperTags:C,preserveWhiteSpace:w}),"",g,g);y.attributes[v]=Object(i.toHTMLString)({value:S,multilineTag:E,preserveWhiteSpace:w})}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(b.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(qc(s.clientId,x,M,M))}n(_c([s.clientId,d.clientId],[Ka(Ka({},s),{},{attributes:Ka(Ka({},s.attributes),B)})].concat(ce(I.slice(1)))))}}else n(pc(s.clientId))},RESET_BLOCKS:[function(e,t){var n=t.getState(),r=ja(n),o=ka(n),i=!r||"all"!==o||Object(c.doBlocksMatchTemplate)(e.blocks,r);if(i!==ha(n))return Dc(i)}],MULTI_SELECT:function(e,t){var n=Ni((0,t.getState)());Object(Ue.speak)(Object(O.sprintf)(
|
26 |
/* translators: %s: number of selected blocks */
|
27 |
Object(O._n)("%s block selected.","%s blocks selected.",n),n),"assertive")},SYNCHRONIZE_TEMPLATE:function(e,t){var n=(0,t.getState)(),r=ki(n),o=ja(n);return sc(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 $a=function(e){var t,n=[Ho()(qa),Uo.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=b.flowRight.apply(void 0,ce(t))(e.dispatch),e.dispatch=r,e};function Ya(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 Xa(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ya(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ya(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Qa={reducer:Fo,selectors:o,actions:r,controls:{SLEEP:function(e){var t=e.duration;return new Promise((function(e){setTimeout(e,t)}))}}},Za=Object(v.registerStore)("core/block-editor",Xa(Xa({},Qa),{},{persist:["preferences"]}));$a(Za);function Ja(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?b.noop:i,l=e.onInput,s=void 0===l?b.noop:l,d=Object(v.useRegistry)(),f=d.dispatch("core/block-editor"),p=f.resetBlocks,m=f.resetSelection,g=f.replaceInnerBlocks,O=f.setHasControlledInnerBlocks,h=f.__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(b.last)(_.current.outgoing)===r&&(_.current.outgoing=[]):y(n)!==r&&(_.current.outgoing=[],_.current.incoming=r,r&&(h(),n?(O(n,!0),h(),g(n,r,!1)):p(r)),o&&c&&m(o,c))}),[r,n])}var el=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(Ee.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(ie.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",Qa);$a(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]),Ja(e),t})),tl=n(71);var nl=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),f=a().bodyPlaceholder;return{isVisible:s||!u||!d,showPrompt:s,isLocked:!!l(t.rootClientId),placeholder:f}})),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(tl.decodeEntities)(c)||Object(O.__)("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)(ao.a,{role:"button","aria-label":Object(O.__)("Add block"),className:"block-editor-default-block-appender__content",readOnly:!0,onFocus:r,value:o?a:""}),Object(u.createElement)(fs,{rootClientId:i,position:"bottom right",isAppender:!0,__experimentalIsQuick:!0}))}));var rl=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)(fs,{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(O.sprintf)(// translators: %s: the name of the block when there is only one
|
28 |
Object(O._x)("Add %s","directly add the only allowed block"),s):Object(O._x)("Add block","Generic label for block inserter button");var b=!d,p=Object(u.createElement)(h.Button,{ref:t,onFocus:c,tabIndex:i,className:f()(r,"block-editor-button-block-appender"),onClick:o,"aria-haspopup":b?"true":void 0,"aria-expanded":b?l:void 0,disabled:a,label:n},!d&&Object(u.createElement)(h.VisuallyHidden,{as:"span"},n),Object(u.createElement)(ho.a,{icon:mo.a}));return(b||d)&&(p=Object(u.createElement)(h.Tooltip,{text:n},p)),p},isAppender:!0})})),ol=Object(u.createContext)();function cl(e){e.stopPropagation()}var il=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)(ol);if(c||!1===i)return null;if(i)t=Object(u.createElement)(i,null);else{var m=!r,v=l===r,g=l&&!n.includes(l);if(!m&&!v&&(!l||g))return null;t=o?Object(u.createElement)(nl,{rootClientId:r,lastBlockClientId:Object(b.last)(n)}):Object(u.createElement)(rl,{rootClientId:r,className:"block-list-appender__toggle"})}return Object(u.createElement)(d,{tabIndex:-1,onFocus:cl,className:f()("block-list-appender","wp-block",a),ref:function(e){e?p.set(r||"",e):p.delete(r||"")}},t)}));function al(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 ll(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 sl(e,t,n){return function(r){var o=Object(c.pasteHandler)({HTML:r,mode:"BLOCKS"});o.length&&n(o,t,e)}}function ul(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:al(e,t,r,o,l),onFilesDrop:ll(e,t,c,s,a),onHTMLDrop:sl(e,t,a)}}function dl(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 fl(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=dl(e,t,o);(void 0===n||c<n)&&(n=c,r=o)})),[n,r]}function bl(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 pl(e){var t=e.element,n=e.rootClientId,r=void 0===n?"":n,o=Object(u.useState)(null),c=Object(ie.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,f=l.orientation,b=ul(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?bl(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({element:t,isDisabled:d,withPosition:!0},b)).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=fl(t,a,c),s=Object(ie.a)(l,2),u=s[0],d=s[1];if(void 0===o||u<o){var f="bottom"===d||"right"===d,b=f?1:0,p=f&&e[i+1]&&e[i+1].classList.contains("is-dragging");o=u,r=i+(b+=p?1:0)}}})),r}(Array.from(t.current.children),p,f);a(void 0===e?0:e)}}),[p]),p)return i}var ml=new Map;function vl(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,f=r.isDraggingBlocks,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,isDraggingBlocks:f(),activeEntityBlockId:b}}),[n]),a=i.blockClientIds,l=i.selectedBlockClientId,s=i.multiSelectedBlockClientIds,d=i.orientation,b=i.hasMultiSelection,p=i.enableAnimation,m=i.isDraggingBlocks,g=i.activeEntityBlockId,O=pl({element:c,rootClientId:n}),h=O===a.length&&m;return Object(u.createElement)(u.Fragment,null,a.map((function(e,t){var r=b?s.includes(e):l===e,o=O===t&&m;return Object(u.createElement)(v.AsyncModeProvider,{key:e,value:!r},Object(u.createElement)(Mu,{rootClientId:n,clientId:e,index:t,enableAnimation:p,className:f()({"is-drop-target":o,"is-dropping-horizontally":o&&"horizontal"===d,"has-active-entity":g}),activeEntityBlockId:g}))})),a.length<1&&t,Object(u.createElement)(il,{tagName:o,rootClientId:n,renderAppender:r,className:f()({"is-drop-target":h,"is-dropping-horizontally":h&&"horizontal"===d})}))}function gl(e){return Object(u.createElement)(v.AsyncModeProvider,{value:!1},Object(u.createElement)(vl,e))}var Ol,hl=Object(u.forwardRef)((function(e,t){var n=e.className,r=e.placeholder,o=e.rootClientId,c=e.renderAppender,i=o?"div":Eu,a=Object(u.useRef)(),l=t||a;return Object(u.createElement)(ol.Provider,{value:ml},Object(u.createElement)(i,{ref:l,className:f()("block-editor-block-list__layout",n)},Object(u.createElement)(gl,{placeholder:r,rootClientId:o,renderAppender:c,wrapperRef:l})))}));function jl(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)(hl,null)))}var kl=function(e){var t=e.viewportWidth,n=e.__experimentalPadding,r=Object(p.useResizeObserver)(),o=Object(ie.a)(r,2),c=o[0],i=o[1].width,a=Object(p.useResizeObserver)(),l=Object(ie.a)(a,2),s=l[0],d=l[1].height;Ol=Ol||Object(p.pure)(hl);var f=(i-2*n)/t;return Object(u.createElement)("div",{className:"block-editor-block-preview__container editor-styles-wrapper","aria-hidden":!0,style:{height:d*f+2*n}},c,Object(u.createElement)(h.Disabled,{style:{transform:"scale(".concat(f,")"),width:t,left:n,right:n,top:n},className:"block-editor-block-preview__content"},s,Object(u.createElement)(Ol,null)))};var yl=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(b.castArray)(t)}),[t]);return t&&0!==t.length?Object(u.createElement)(el,{value:d,settings:s},a?Object(u.createElement)(jl,{onClick:l}):Object(u.createElement)(kl,{viewportWidth:c,__experimentalPadding:r})):null}));function _l(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 El(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_l(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Cl=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)(yl,{__experimentalPadding:16,viewportWidth:500,blocks:n.example?Object(c.getBlockFromExample)(t.name,{attributes:El(El({},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(O.__)("No Preview Available."))),!Object(c.isReusableBlock)(t)&&Object(u.createElement)(yo,{blockType:t}))},wl=n(50),Sl=n(110),Il=n(111);var Bl=function(e){var t=e.icon,n=e.onClick,r=e.isDisabled,o=e.title,c=e.className,i=e.composite,a=Object(Ee.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)(Il.a,Object(l.a)({role:"option",as:h.Button},i,{className:f()("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)(tr,{icon:t,showColors:!0})),Object(u.createElement)("span",{className:"block-editor-block-types-list__item-title"},o)))};var xl=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(wl.g)(),f=n.reduce((function(e,t){return e+"--"+t.id}),"");return Object(u.useEffect)((function(){d.unstable_sort()}),[d.unstable_sort,f]),Object(u.createElement)(Sl.a,Object(l.a)({},d,{role:"listbox",className:"block-editor-block-types-list","aria-label":s}),n.map((function(e){return Object(u.createElement)(Bl,{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 Pl(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)(tr,{icon:c,showColors:!0}),o&&Object(u.createElement)("h2",null,o)),n)}var Tl=Object(h.createSlotFill)("__experimentalInserterMenuExtension"),Nl=Tl.Fill,Dl=Tl.Slot;Nl.Slot=Dl;var Rl=Nl;var Al=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 Ml=function(){return Object(u.createElement)("div",{className:"block-editor-inserter__no-results"},Object(u.createElement)(ho.a,{className:"block-editor-inserter__no-results-icon",icon:er.a}),Object(u.createElement)("p",null,Object(O.__)("No results found.")))};function Ll(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 Fl=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=Jn(t,n),l=Object(ie.a)(a,4),d=l[0],f=l[1],p=l[2],m=l[3],g=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 Xn(d,f,p,o)}),[o,d,f,p]),j=Object(u.useMemo)((function(){return Object(b.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(b.findIndex)(f,(function(t){return t.slug===e.category}))};return Object(b.flow)((function(e){return e.filter((function(e){return e.category&&"reusable"!==e.category}))}),(function(t){return Object(b.sortBy)(t,e)}),(function(e){return Object(b.groupBy)(e,"category")}))(h)}),[h,f]),_=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?Ll(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ll(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(O.sprintf)(
|
29 |
/* translators: %d: number of results. */
|
30 |
Object(O._n)("%d result found.","%d results found.",h.length),h.length);c(e)}),[o,c]);var E=!Object(b.isEmpty)(h);return Object(u.createElement)("div",null,g&&Object(u.createElement)(Pl,{rootClientId:t},Object(u.createElement)(xl,{items:h,onSelect:m,onHover:r,label:Object(O.__)("Child Blocks")})),i&&!g&&!!j.length&&!o&&Object(u.createElement)(Al,{title:Object(O._x)("Most used","blocks")},Object(u.createElement)(xl,{items:j,onSelect:m,onHover:r,label:Object(O._x)("Most used","blocks")})),!g&&Object(b.map)(f,(function(e){var t=y[e.slug];return t&&t.length?Object(u.createElement)(Al,{key:e.slug,title:e.title,icon:e.icon},Object(u.createElement)(xl,{items:t,onSelect:m,onHover:r,label:e.title})):null})),!g&&!!k.length&&Object(u.createElement)(Al,{className:"block-editor-inserter__uncategorized-blocks-panel",title:Object(O.__)("Uncategorized")},Object(u.createElement)(xl,{items:k,onSelect:m,onHover:r,label:Object(O.__)("Uncategorized")})),!g&&Object(b.map)(p,(function(e,t){var n=_[t];return n&&n.length?Object(u.createElement)(Al,{key:t,title:e.title,icon:e.icon},Object(u.createElement)(xl,{items:n,onSelect:m,onHover:r,label:e.title})):null})),Object(u.createElement)(Rl.Slot,{fillProps:{onSelect:m,onHover:r,filterValue:o,hasItems:E}},(function(e){return e.length?e:E?null:Object(u.createElement)(Ml,null)})))}));var Vl=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:f()("block-editor-inserter__panel-header","block-editor-inserter__panel-header-patterns")},Object(u.createElement)(h.SelectControl,{className:"block-editor-inserter__panel-dropdown",label:Object(O.__)("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))},Hl=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(b.map)(n,(function(e){return Object(c.cloneBlock)(e)})),t.name),o(Object(O.sprintf)(
|
31 |
/* translators: %s: block pattern title. */
|
32 |
+
Object(O.__)('Block pattern "%s" inserted.'),t.title),{type:"snackbar"})}),[])]};function zl(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)(zl),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){pt.ENTER!==e.keyCode&&pt.SPACE!==e.keyCode||n(t,i)},tabIndex:0,"aria-label":t.title,"aria-describedby":t.description?l:void 0},Object(u.createElement)(yl,{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 Ul(){return Object(u.createElement)("div",{className:"block-editor-block-patterns-list__item is-placeholder"})}var Gl=function(e){var t=e.blockPatterns,n=e.shownPatterns,r=e.onClickPattern;return t.map((function(e){return n.includes(e)?Object(u.createElement)(zl,{key:e.name,pattern:e,onClick:r}):Object(u.createElement)(Ul,{key:e.name})}))};function Wl(e){var t=e.filterValue,n=e.onInsert,r=Hl(n),o=Object(ie.a)(r,3),c=o[0],i=o[2],a=Object(u.useMemo)((function(){return Qn(c,t)}),[t,c]),l=Object(p.useAsyncList)(a);if(t)return a.length?Object(u.createElement)(Al,{title:Object(O.__)("Search Results")},Object(u.createElement)(Gl,{shownPatterns:l,blockPatterns:a,onClickPattern:i})):Object(u.createElement)(Ml,null)}function Kl(e){var t=e.onInsert,n=e.selectedCategory,r=e.onClickCategory,o=Hl(t),c=Object(ie.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 f(e)===1/0}))&&!s.find((function(e){return"uncategorized"===e.name}))&&s.push({name:"uncategorized",label:Object(O._x)("Uncategorized")})}),[s,i]);var f=Object(u.useCallback)((function(e){if(!e.categories||!e.categories.length)return 1/0;var t=Object(b.fromPairs)(s.map((function(e,t){return[e.name,t]})));return Math.min.apply(Math,ce(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?f(e)===1/0:e.categories&&e.categories.includes(d.name)}))}),[i,d]),v=Object(u.useMemo)((function(){return m.sort((function(e,t){return f(e)-f(t)}))}),[m,f]),g=Object(p.useAsyncList)(v);return Object(u.createElement)(u.Fragment,null,!!m.length&&Object(u.createElement)(Vl,{key:d.name,title:d.title,selectedCategory:d,patternCategories:s,onClickCategory:r},Object(u.createElement)(Gl,{shownPatterns:g,blockPatterns:m,onClickPattern:l})))}var ql=function(e){var t=e.onInsert,n=e.onClickCategory,r=e.filterValue,o=e.selectedCategory;return r?Object(u.createElement)(Wl,{onInsert:t,filterValue:r}):Object(u.createElement)(Kl,{selectedCategory:o,onInsert:t,onClickCategory:n})},$l=n(18);function Yl(e){var t=e.debouncedSpeak,n=e.filterValue,r=e.onHover,o=e.onInsert,c=e.rootClientId,i=Jn(c,o),a=Object(ie.a)(i,4),l=a[0],s=a[1],d=a[2],f=a[3],b=Object(u.useMemo)((function(){var e=l.filter((function(e){return"reusable"===e.category}));return n?Xn(e,s,d,n):e}),[n,l,s,d]);return Object(u.useEffect)((function(){var e=Object(O.sprintf)(
|
33 |
/* translators: %d: number of results. */
|
34 |
Object(O._n)("%d result found.","%d results found.",b.length),b.length);t(e)}),[n,t]),0===b.length?Object(u.createElement)(Ml,null):Object(u.createElement)(Al,{title:n?Object(O.__)("Search Results"):Object(O.__)("Reusable blocks")},Object(u.createElement)(xl,{items:b,onSelect:f,onHover:r,label:n?Object(O.__)("Search Results"):Object(O.__)("Reusable blocks")}))}var Xl=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)(Yl,{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($l.addQueryArgs)("edit.php",{post_type:"wp_block"})},Object(O.__)("Manage all reusable blocks"))))}));function Ql(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 Zl=function(e){var t=e.onSelect,n=e.rootClientId,r=e.clientId,o=e.isAppender,i=e.selectBlockOnInsert,a=e.insertionIndex,l=Object(v.useSelect)((function(e){var t,c=e("core/block-editor"),i=c.getSettings,a=c.getBlockRootClientId,l=c.getBlockSelectionEnd,u=n;if(!u&&!r&&!o){var d=l();d&&(u=a(d))}return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ql(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ql(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({hasPatterns:!!(null===(t=i().__experimentalBlockPatterns)||void 0===t?void 0:t.length),destinationRootClientId:u},Object(b.pick)(e("core/block-editor"),["getSelectedBlock","getBlockIndex","getBlockSelectionEnd","getBlockOrder"]))}),[o,r,n]),u=l.destinationRootClientId,d=l.getSelectedBlock,f=l.getBlockIndex,p=l.getBlockSelectionEnd,m=l.getBlockOrder,g=Object(v.useDispatch)("core/block-editor"),h=g.replaceBlocks,j=g.insertBlocks,k=g.showInsertionPoint,y=g.hideInsertionPoint;function _(){if(void 0!==a)return a;if(r)return f(r,u);var e=p();return!o&&e?f(e,u)+1:m(u).length}return[u,function(e,n){var r=d();if(!o&&r&&Object(c.isUnmodifiedDefaultBlock)(r)?h(r.clientId,e,null,null,n):j(e,_(),u,i,n),!i){
|
35 |
// translators: %d: the name of the block that has been added
|
43 |
/* translators: %d: number of results. */
|
44 |
Object(O._n)("%d result found.","%d results found.",e),e);i(t)}}),[s,i]);return Object(u.createElement)("div",{className:f()("block-editor-inserter__quick-inserter",{"has-search":N,"has-expand":A}),onKeyPress:is,onKeyDown:cs},N&&Object(u.createElement)(ko,{value:s,onChange:function(e){d(e)},placeholder:Object(O.__)("Search for a block")}),Object(u.createElement)(as,{blockTypes:D,blockPatterns:T?R:[],onSelectBlockPattern:P,onSelectBlockType:S,onHover:k}),A&&Object(u.createElement)(h.Button,{className:"block-editor-inserter__quick-inserter-expand",onClick:function(){L(M),setTimeout((function(){A(!0)}))},"aria-label":Object(O.__)("Browse all. This will open the main inserter panel in the editor toolbar.")},Object(O.__)("Browse all")))}function ss(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var us=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(O.sprintf)(// translators: %s: the name of the block when there is only one
|
45 |
Object(O._x)("Add %s","directly add the only allowed block"),c):Object(O._x)("Add block","Generic label for block inserter button");var d=s.onClick,f=Object(Ee.a)(s,["onClick"]);return Object(u.createElement)(h.Button,Object(l.a)({icon:mo.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},f))},ds=function(e){Jt(n,e);var t=ss(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).onToggle=e.onToggle.bind(Qt(e)),e.renderToggle=e.renderToggle.bind(Qt(e)),e.renderContent=e.renderContent.bind(Qt(e)),e}return Xt(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?us: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)(ls,{onSelect:t,rootClientId:r,clientId:o,isAppender:c,selectBlockOnInsert:a}):Object(u.createElement)(os,{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:f()("block-editor-inserter__popover",{"is-quick":o}),position:t,onToggle:this.onToggle,expandOnMobile:!0,headerTitle:Object(O.__)("Add a block"),renderToggle:this.renderToggle,renderContent:this.renderContent})}}]),n}(u.Component),fs=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(b.size)(s)&&0===Object(b.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(O.sprintf)(// translators: %s: the name of the block that has been added
|
46 |
+
Object(O.__)("%s block added"),l.title);Object(Ue.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}))])(ds),bs=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=Ze(n);if(r){var t=xr.focus.tabbable.find(e);(Object(b.last)(t)||e).focus()}else e.focus()}else{if(i)return void a.current.focus();s(!0);var l=xr.focus.tabbable.find(o.current);l.length&&(r?Object(b.last)(l).focus():Object(b.first)(l).focus())}},style:{position:"fixed"}})}));var ps=Object(b.overEvery)([xr.isTextField,xr.focus.tabbable.isTabbableIndex]);function ms(e,t,n,r){var o,c=xr.focus.focusable.find(n);return t&&(c=Object(b.reverse)(c)),c=c.slice(c.indexOf(e)+1),r&&(o=e.getBoundingClientRect()),Object(b.find)(c,(function t(n,c,i){if(!xr.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(xr.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 vs(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,f=t.hasBlockMovingClientId,b=t.getBlockIndex,p=t.getBlockRootClientId,m=t.getClientIdsOfDescendants,v=t.canInsertBlockType,g=t.getBlockName,O=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:f,getBlockIndex:b,getBlockRootClientId:p,getClientIdsOfDescendants:m,canInsertBlockType:v,getBlockName:g,isSelectionEnabled:O(),blockSelectionStart:h(),isMultiSelecting:j(),keepCaretInsideBlock:k().keepCaretInsideBlock}}function gs(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)(vs,[]),d=s.selectedBlockClientId,p=s.selectionStartClientId,m=s.selectionBeforeEndClientId,g=s.selectionAfterEndClientId,h=s.selectedFirstClientId,j=s.selectedLastClientId,k=s.hasMultiSelection,y=s.blocks,_=s.isNavigationMode,E=s.hasBlockMovingClientId,C=s.isSelectionEnabled,w=s.blockSelectionStart,S=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(ie.a)(H,2),U=z[0],G=z[1];Object(u.useEffect)((function(){k&&!S&&c.current.focus()}),[k,S]);var W=f()("block-editor-writing-flow",{"is-navigate-mode":_,"is-block-moving-mode":!!E(),"can-insert-moving-block":U});return Object(u.createElement)("div",{className:W},Object(u.createElement)(bs,{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===pt.UP,f=t===pt.DOWN,v=t===pt.LEFT,O=t===pt.RIGHT,C=t===pt.TAB,w=t===pt.ESCAPE,S=t===pt.ENTER,D=t===pt.SPACE,H=u||v,z=v||O,U=u||f,W=z||U,K=e.shiftKey,q=K||e.ctrlKey||e.altKey||e.metaKey,$=U?xr.isVerticalEdge:xr.isHorizontalEdge;if(_){var Y,X=C&&K||u,Q=C&&!K||f,Z=v,J=O;if(X)Y=m;else if(Q)Y=g;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))),w&&ne&&(F(null),G(!1)),(S||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=Ze(d);(ae=Q?xr.focus.tabbable.findNext(le):xr.focus.tabbable.findPrevious(le))&&(e.preventDefault(),ae.focus(),M())}}else{if(d)if(C){var se=Ze(d);if(K){if(s===se)return a.current=!0,void r.current.focus()}else{var ue=xr.focus.tabbable.find(se);if(s===(Object(b.last)(ue)||se))return a.current=!0,void o.current.focus()}}else w&&L(!0);else if(k&&C&&s===c.current)return a.current=!0,void(K?r.current.focus():o.current.focus());var de=n.current.ownerDocument.defaultView;if(U?l.current||(l.current=Object(xr.computeCaretRect)(de)):l.current=null,!W)return pt.isKeyboardEvent.primary(e)&&(i.current=Object(xr.isEntirelySelected)(s)),void(pt.isKeyboardEvent.primary(e,"a")&&((s.isContentEditable?i.current:Object(xr.isEntirelySelected)(s))&&(R(Object(b.first)(y),Object(b.last)(y)),e.preventDefault()),i.current=!0));if(!e.nativeEvent.defaultPrevented&&function(e,t,n){if((t===pt.UP||t===pt.DOWN)&&!n)return!0;var r=e.tagName;return"INPUT"!==r&&"TEXTAREA"!==r}(s,t,q)){var fe,be="rtl"===(fe=s).ownerDocument.defaultView.getComputedStyle(fe).direction?!H:H;if(K)(H&&m||!H&&g)&&(k||function(e,t){var r,o,c=ms(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:g;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(xr.isVerticalEdge)(s,H)&&!N){var pe=ms(s,H,n.current,!0);pe&&(Object(xr.placeCaretAtVerticalEdge)(pe,H,l.current),e.preventDefault())}else if(z&&de.getSelection().isCollapsed&&Object(xr.isHorizontalEdge)(s,be)&&!N){var me=ms(s,be,n.current);Object(xr.placeCaretAtHorizontalEdge)(me,be),e.preventDefault()}}}},onMouseDown:function(e){if(l.current=null,_&&d&&Je(Ze(d),e.target)?(L(!1),F(null)):_&&E()&&et(e.target)&&G(P(T(E()),B(et(e.target)))),C&&0===e.button){var t=et(e.target);t&&(e.shiftKey?w!==t&&(R(w,t),e.preventDefault()):k&&A(t))}}},Object(u.createElement)("div",{ref:c,tabIndex:k?"0":void 0,"aria-label":k?Object(O.__)("Multiple selected blocks"):void 0,style:{position:"fixed"}}),t),Object(u.createElement)(bs,{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=xr.focus.focusable.find(n.current),t=Object(b.findLast)(e,ps);t&&Object(xr.placeCaretAtHorizontalEdge)(t,!0)},className:"block-editor-writing-flow__click-redirect"}))}function Os(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=Ze(t),u=ms(s,!0,l?r.current:s)||s,d=new window.DOMRect(n,c,0,16);Object(xr.placeCaretAtVerticalEdge)(u,l,d,!1)}},tabIndex:-1,className:f()("block-editor-block-list__insertion-point-inserter",{"is-inserter-hidden":c})},Object(u.createElement)(fs,{position:"bottom center",clientId:t,__experimentalIsQuick:!0}))}function hs(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)(ol),s=Object(u.useMemo)((function(){return t?Ze(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)(Os,{clientId:t,setIsInserterForced:c,containerRef:i})))}function js(e){var t=e.children,n=e.containerRef,r=Object(u.useState)(!1),o=Object(ie.a)(r,2),c=o[0],i=o[1],a=Object(u.useState)(!1),l=Object(ie.a)(a,2),s=l[0],d=l[1],f=Object(u.useState)(null),b=Object(ie.a)(f,2),p=b[0],m=b[1],g=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}}),[]),O=g.isMultiSelecting,h=g.isInserterVisible,j=g.selectedClientId,k=g.selectedRootClientId;var y=c||s||h;return Object(u.createElement)(u.Fragment,null,!O&&y&&Object(u.createElement)(hs,{clientId:h?j:p,rootClientId:k,isInserterShown:c,isInserterForced:s,setIsInserterForced:d,containerRef:n,showInsertionPoint:h}),Object(u.createElement)("div",{onMouseMove:s||O?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 ks=function(e){var t=e.clientId,n=e.rootClientId,r=Object(Ee.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,b=o.orientation,p=Object(v.useDispatch)("core/block-editor"),m=p.setNavigationMode,g=p.removeBlock,O=Object(u.useRef)();Object(u.useEffect)((function(){O.current.focus(),window.navigator.platform.indexOf("Win")>-1&&Object(Ue.speak)(k)}),[]);var j=Object(c.getBlockType)(a),k=Object(c.__experimentalGetAccessibleBlockLabel)(j,s,i+1,b),y=f()("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:O,onClick:function(){return m(!1)},onKeyDown:function(e){var n=e.keyCode;n!==pt.BACKSPACE&&n!==pt.DELETE||(g(t),e.preventDefault())},label:k},Object(u.createElement)(ir,{clientId:t})))};function ys(e,t,n){var r=Object(u.useState)(t),o=Object(ie.a)(r,1)[0],c=Object(u.useCallback)((function(){var t,n,r;t=e.current,n=xr.focus.tabbable.find(t),(r=Object(ie.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 _s=function(e){var t=e.children,n=e.focusOnMount,r=Object(Ee.a)(e,["children","focusOnMount"]),o=Object(u.useRef)(),c=function(e){var t=Object(u.useState)(!0),n=Object(ie.a)(t,2),r=n[0],o=n[1],c=Object(u.useCallback)((function(){var t=xr.focus.tabbable.find(e.current),n=!t.some((function(e){return!("toolbarItem"in e.dataset)}));n||uo()("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 ys(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)},Es=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 Cs(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(ie.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)(tr,{icon:n}):Object(O.sprintf)(
|
47 |
/* translators: %d: Number of blocks. */
|
48 |
+
Object(O._n)("%d block","%d blocks",t.length),t.length)),Object(u.createElement)(h.FlexItem,null,Object(u.createElement)(tr,{icon:Es})))))}var ws=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,f=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]),b=f.srcRootClientId,p=f.isDraggable,m=Object(u.useRef)(!1),g=(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(xr.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)}]),O=Object(ie.a)(g,3),j=O[0],k=O[1],y=O[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 w={type:"block",srcClientIds:i,srcRootClientId:b};return Object(u.createElement)(h.Draggable,{cloneClassname:a,elementId:d||"block-".concat(i[0]),transferData:w,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)(Cs,{clientIds:i})},(function(e){var t=e.onDraggableStart,n=e.onDraggableEnd;return c({isDraggable:!0,onDraggableStart:t,onDraggableEnd:n})}))};var Ss=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,f=Object(b.castArray)(r),p=Object(b.first)(f),m=i(p),v=d(Object(b.first)(f)),g=a(p,v),O=0===g,h=a(Object(b.last)(f),v)===u(v).length-1;return{blockType:m?Object(c.getBlockType)(m.name):null,isLocked:"all"===s(v),rootClientId:v,firstIndex:g,isFirst:O,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),b=Object(ie.a)(d,2),p=b[0],m=b[1],v=function(){return m(!0)},g=function(){return m(!1)};return o||t&&n&&!i?null:Object(u.createElement)("div",{className:f()("block-editor-block-mover",{"is-visible":p||!c,"is-horizontal":"horizontal"===a})},!s&&Object(u.createElement)(ws,{clientIds:r,cloneClassname:"block-editor-block-mover__drag-clone"},(function(e){var t=e.isDraggable,n=e.onDraggableStart,o=e.onDraggableEnd;return Object(u.createElement)(h.Button,{icon:Es,className:"block-editor-block-mover__drag-handle","aria-hidden":"true",label:Object(O._n)("Drag block","Drag blocks",r.length),tabIndex:"-1",onDragStart:n,onDragEnd:o,draggable:t})})),Object(u.createElement)(h.ToolbarGroup,{className:"block-editor-block-mover__move-button-container"},Object(u.createElement)(h.ToolbarItem,{onFocus:v,onBlur:g},(function(e){return Object(u.createElement)(Gr,Object(l.a)({clientIds:r},e))})),Object(u.createElement)(h.ToolbarItem,{onFocus:v,onBlur:g},(function(e){return Object(u.createElement)(Wr,Object(l.a)({clientIds:r},e))}))))}));function Is(){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(O.sprintf)(
|
49 |
/* translators: %s: Name of the block's parent. */
|
50 |
Object(O.__)("Select parent (%s)"),n.title),showTooltip:!0,icon:Object(u.createElement)(tr,{icon:n.icon})})):null}var Bs=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 xs(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 Ps(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 Ps(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 Ps(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 Ts(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 Ns(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ts(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ts(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ds(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 Ns(Ns({},t),{},{attributes:Ns(Ns({},t.attributes),{},{className:a})})}),[t,a]);return Object(u.createElement)("div",{key:n.name,className:f()("block-editor-block-styles__item",{"is-active":r}),onClick:function(){return i()},onKeyDown:function(e){pt.ENTER!==e.keyCode&&pt.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)(yl,{viewportWidth:500,blocks:s})),Object(u.createElement)("div",{className:"block-editor-block-styles__item-label"},n.label||n.name))}var Rs=function(e){var t=e.clientId,n=e.onSwitch,r=void 0===n?b.noop:n,o=e.onHoverClassName,i=void 0===o?b.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,f=l.type,p=l.className,m=Object(v.useDispatch)("core/block-editor").updateBlockAttributes,g=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,f);if(!s||0===s.length)return null;var h=Object(b.find)(s,"isDefault")?s:[{name:"default",label:Object(O._x)("Default","block style"),isDefault:!0}].concat(ce(s)),j=function(e,t){var n,r=xs(new kt.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(b.find)(e,{name:c});if(i)return i}}}catch(e){r.e(e)}finally{r.f()}return Object(b.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 kt.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)(Ds,{genericPreviewBlock:g,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})})))},As=function(e){var t=e.className,n=e.possibleBlockTransformations,r=e.onSelect;return Object(u.createElement)(h.MenuGroup,{label:Object(O.__)("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)(tr,{icon:n,showColors:!0}),o)})))};function Ms(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}function Ls(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 Fs(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ls(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ls(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Vs(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(O.__)("Preview")),Object(u.createElement)(yl,{viewportWidth:500,blocks:r.example?Object(c.getBlockFromExample)(t.name,{attributes:Fs(Fs({},r.example.attributes),{},{className:n}),innerBlocks:r.example.innerBlocks}):Object(c.cloneBlock)(t,{className:n})})))))}var Hs=function(e){Jt(n,e);var t=Ms(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).state={hoveredClassName:null},e.onHoverClassName=e.onHoverClassName.bind(Qt(e)),e}return Xt(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(ie.a)(n,1)[0],d=Object(b.mapKeys)(o,(function(e){return e.name})),f=Object(b.orderBy)(Object(b.filter)(Object(c.getPossibleBlockTransformations)(n),(function(e){return e&&!!d[e.name]})),(function(e){return d[e.name].frecency}),"desc");if(1===Object(b.uniq)(Object(b.map)(n,"name")).length){var p=s.name,m=Object(c.getBlockType)(p);l=m.icon}else l=Bs;var v=!!f.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(O.__)("Block icon"),icon:Object(u.createElement)(tr,{icon:l,showColors:!0})}));var g=1===n.length?Object(O.__)("Change block type or style"):Object(O.sprintf)(
|
51 |
/* translators: %s: number of blocks. */
|
53 |
Object(O.__)('Copied "%s" to clipboard.'),a):Object(O.sprintf)(// Translators: Name of the block being cut, e.g. "Paragraph".
|
54 |
Object(O.__)('Moved "%s" to clipboard.'),a)}else c="copy"===r?Object(O.sprintf)(// Translators: %d: Number of blocks being copied.
|
55 |
Object(O._n)("Copied %d block to clipboard.","Copied %d blocks to clipboard.",o.length),o.length):Object(O.sprintf)(// Translators: %d: Number of blocks being cut.
|
56 |
+
Object(O._n)("Moved %d block to clipboard.","Moved %d blocks to clipboard.",o.length),o.length);n(c,{type:"snackbar"})}),[])}var Ws=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,f=s.removeBlocks,p=s.replaceBlocks,m=Gs(),g=l().__experimentalCanUserUseUnfilteredHTML,O=function(e){var t=i();if(0!==t.length){if(!a()){var r=e.target.ownerDocument;if("copy"===e.type||"cut"===e.type?Object(xr.documentHasUncollapsedSelection)(r):Object(xr.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)f(t);else if("paste"===e.type){var u=function(e){var t=e.clipboardData,n=t.items,r=t.files;n=Object(b.isNil)(n)?[]:n,r=Object(b.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(b.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(Us.createBlobURL)(e),'">')})).join(""),o=""),{html:c,plainText:o}}(e),v=u.plainText,O=u.html,h=Object(c.pasteHandler)({HTML:O,plainText:v,mode:"BLOCKS",canUserUseUnfilteredHTML:g});p(t,h,h.length-1,-1)}}}};return Object(u.createElement)("div",{ref:n,onCopy:O,onCut:O,onPaste:O},t)};function Ks(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,f=u.getGroupingBlockName,p=l(t),m=a(t[0]),g=Object(b.every)(p,(function(e){return!!e&&Object(c.hasBlockSupport)(e.name,"multiple",!0)&&i(e.name,m)})),O=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,w=h.setBlockMovingClientId,S=h.setNavigationMode,I=h.selectBlock,B=Gs();return n({canDuplicate:g,canInsertDefaultBlock:O,isLocked:!!s(m),rootClientId:m,blocks:p,onDuplicate:function(){return y(t,r)},onRemove:function(){return j(t,r)},onInsertBefore:function(){E(Object(b.first)(Object(b.castArray)(t)))},onInsertAfter:function(){_(Object(b.last)(Object(b.castArray)(t)))},onMoveTo:function(){S(!0),I(t[0]),w(t[0])},onGroup:function(){if(p.length){var e=f(),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 qs=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?b.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(O.__)("Edit as HTML"):Object(O.__)("Edit visually");return Object(u.createElement)(h.MenuItem,{onClick:r},!i&&s)}));var $s=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(O.__)("Convert to Blocks");return Object(u.createElement)(h.MenuItem,{onClick:n},!r&&o)})),Ys=Object(h.createSlotFill)("__experimentalBlockSettingsMenuFirstItem"),Xs=Ys.Fill,Qs=Ys.Slot;Xs.Slot=Qs;var Zs=Xs;function Js(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 eu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Js(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Js(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var tu=Object(h.createSlotFill)("BlockSettingsMenuControls"),nu=tu.Fill,ru=tu.Slot;nu.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(b.map)(Object(b.compact)(n(c)),(function(e){return e.name}))}),[r]);return Object(u.createElement)(ru,{fillProps:eu(eu({},t),{},{selectedBlocks:o})},(function(e){return!Object(b.isEmpty)(e)&&Object(u.createElement)(h.MenuGroup,null,e)}))};var ou=nu,cu={className:"block-editor-block-settings-menu__popover",position:"bottom right",isAlternate:!0};var iu=function(e){var t=e.clientIds,n=e.__experimentalSelectBlock,r=e.children,o=Object(Ee.a)(e,["clientIds","__experimentalSelectBlock","children"]),i=Object(b.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")}}),[]),f=Object(u.useCallback)(n?function(){var e=Sr(Cr.a.mark((function e(t){var r;return Cr.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)}}():b.noop,[n]);return Object(u.createElement)(Ks,{clientIds:t,__experimentalUpdateSelection:!n},(function(e){var n=e.canDuplicate,i=e.canInsertDefaultBlock,p=e.isLocked,m=e.onDuplicate,v=e.onInsertAfter,g=e.onInsertBefore,j=e.onRemove,k=e.onCopy,y=e.onMoveTo,_=e.blocks;return Object(u.createElement)(h.DropdownMenu,Object(l.a)({icon:Ir.a,label:Object(O.__)("More options"),className:"block-editor-block-settings-menu",popoverProps:cu,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)(Zs.Slot,{fillProps:{onClose:o}}),1===a&&Object(u.createElement)($s,{clientId:s}),Object(u.createElement)(h.ClipboardButton,{text:function(){return Object(c.serialize)(_)},role:"menuitem",className:"components-menu-item__button",onCopy:k},Object(O.__)("Copy")),n&&Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,m,f),shortcut:d.duplicate},Object(O.__)("Duplicate")),i&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,g),shortcut:d.insertBefore},Object(O.__)("Insert Before")),Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,v),shortcut:d.insertAfter},Object(O.__)("Insert After"))),!p&&Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,y)},Object(O.__)("Move To")),1===a&&Object(u.createElement)(qs,{clientId:s,onToggle:o})),Object(u.createElement)(ou.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,!p&&Object(u.createElement)(h.MenuItem,{onClick:Object(b.flow)(o,j,f),shortcut:d.remove},Object(O._n)("Remove block","Remove blocks",a))))}))}))};var au=function(e){var t=e.clientIds,n=Object(Ee.a)(e,["clientIds"]);return Object(u.createElement)(h.ToolbarGroup,null,Object(u.createElement)(h.ToolbarItem,null,(function(e){return Object(u.createElement)(iu,Object(l.a)({clientIds:t,toggleProps:e},n))})))},lu=window,su=lu.clearTimeout,uu=lu.setTimeout;function du(e){var t=e.ref,n=e.isFocused,r=e.debounceTimeout,o=void 0===r?200:r,c=e.onChange,i=void 0===c?b.noop:c,a=Object(u.useState)(!1),l=Object(ie.a)(a,2),s=l[0],d=l[1],f=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=f.current;e&&su&&su(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(),f.current=uu((function(){m()&&p(!1)}),o)}}}var fu=n(264);function bu(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),f=l();return{blockClientIds:s,blockClientId:u,blockType:u&&Object(c.getBlockType)(n(u)),hasFixedToolbar:f.hasFixedToolbar,hasReducedUI:f.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,O=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?b.noop:o,i=Object(u.useState)(!1),a=Object(ie.a)(i,2),l=a[0],s=a[1],d=du({ref:t,debounceTimeout:r,isFocused:l,onChange:c}),f=d.showMovers,p=d.debouncedShowMovers,m=d.debouncedHideMovers,v=Object(u.useRef)(!1),g=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(){g()&&(s(!0),p())},r=function(){g()||(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:f,gestures:{onMouseMove:p,onMouseLeave:m}}}({ref:y,onChange:function(e){e&&m||k(a,e)}}),E=_.showMovers,C=_.gestures,w=Object(p.useViewportMatch)("medium","<")||d;if(s&&!Object(c.hasBlockSupport)(s,"__experimentalToolbar",!0))return null;var S=w||E;if(0===i.length)return null;var I=O&&j,B=i.length>1,x=f()("block-editor-block-toolbar",S&&"is-showing-movers"),P=r?fu.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)(Is,{clientIds:i})),(I||B)&&Object(u.createElement)(h.ToolbarGroup,{className:"block-editor-block-toolbar__block-controls"},Object(u.createElement)(zs,{clientIds:i}),Object(u.createElement)(Ss,{clientIds:i,hideDragHandle:t||m}))),I&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(g.a.Slot,{bubblesVirtually:!0,className:"block-editor-block-toolbar__slot"}),Object(u.createElement)(_r.Slot,{bubblesVirtually:!0,className:"block-editor-block-toolbar__slot"})),Object(u.createElement)(au,{clientIds:i}))}var pu=function(e){var t=e.focusOnMount,n=Object(Ee.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)(_s,Object(l.a)({focusOnMount:t,className:"block-editor-block-contextual-toolbar"
|
57 |
/* translators: accessibility text for the block toolbar */,"aria-label":Object(O.__)("Block tools")},n),Object(u.createElement)(bu,null)))};function mu(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 vu(e){var t=e.clientId,n=e.rootClientId,r=e.isValid,o=e.isEmptyDefaultBlock,c=e.capturingClientId,i=Object(v.useSelect)(mu,[]),l=i.isNavigationMode,s=i.isMultiSelecting,d=i.isTyping,b=i.isCaretWithinFormattedText,m=i.hasMultiSelection,g=i.hasFixedToolbar,O=i.lastClientId,j=Object(p.useViewportMatch)("medium"),k=Object(u.useState)(!1),y=Object(ie.a)(k,2),_=y[0],E=y[1],C=Object(u.useState)(!1),w=Object(ie.a)(C,2),S=w[0],I=w[1],B=Object(u.useContext)(ju),x=!d&&!l&&o&&r,P=l,T=!l&&!g&&j&&!x&&!s&&(!d||b),N=!(l||T||g||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[O];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:f()("block-editor-block-list__block-popover-inserter",{"is-visible":S})},Object(u.createElement)(fs,{clientId:t,rootClientId:n,__experimentalIsQuick:!0})),(T||_)&&Object(u.createElement)(pu,{focusOnMount:_}),P&&Object(u.createElement)(ks,{clientId:t,rootClientId:n}),x&&Object(u.createElement)("div",{className:"block-editor-block-list__empty-block-inserter"},Object(u.createElement)(fs,{position:"bottom right",rootClientId:n,clientId:t,__experimentalIsQuick:!0})))}function gu(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)||{},f=d.name,p=d.attributes,m=void 0===p?{}:p,v=d.isValid,g=a(s),O=l(g),h=Object(b.findIndex)(O,["__experimentalCaptureToolbars",!0]);return-1!==h&&(u=g[h]),{clientId:s,rootClientId:o(s),name:f,isValid:v,isEmptyDefaultBlock:f&&Object(c.isUnmodifiedDefaultBlock)({name:f,attributes:m}),capturingClientId:u}}}function Ou(){var e=Object(v.useSelect)(gu,[]);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)(vu,{clientId:t,rootClientId:n,isValid:o,isEmptyDefaultBlock:c,capturingClientId:i}):null}var hu=Object(u.createContext)(),ju=Object(u.createContext)(),ku=Object(u.createContext)();function yu(e){var t=e("core/block-editor"),n=t.getSelectedBlockClientId,r=t.hasMultiSelection;return{selectedBlockClientId:n(),hasMultiSelection:r()}}function _u(e){et(e.target)&&e.preventDefault()}var Eu=Object(u.forwardRef)((function(e,t){var n=e.children,r=e.className,o=Object(v.useSelect)(yu,[]),c=o.selectedBlockClientId,i=o.hasMultiSelection,a=Object(v.useDispatch)("core/block-editor").selectBlock,l=function(e){var t=Object(v.useSelect)(bo,[]),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,f=l.multiSelect,b=l.selectBlock,p=Object(u.useRef)(),m=Object(u.useRef)(),g=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=Ze(l),d=Ze(s),f=n.getSelection(),b=t.createRange();u=fo(u,"start"),d=fo(d,"end"),b.setStartBefore(u),b.setEndAfter(d),f.removeAllRanges(),f.addRange(b)}}else{if(!a||r)return;var p=n.getSelection();if(p.rangeCount&&!p.isCollapsed){var m=Ze(a),v=p.getRangeAt(0),g=v.startContainer,O=v.endContainer;!m||m.contains(g)&&m.contains(O)||p.removeAllRanges()}}}),[c,r,o,b,a]);var O=Object(u.useCallback)((function(t){var n=t.isSelectionEnd,r=e.current.ownerDocument.defaultView.getSelection();if(r.rangeCount&&!r.isCollapsed){var o=et(r.focusNode);if(m.current===o){if(b(o),n&&(po(e.current,!0),r.rangeCount)){var c=r.getRangeAt(0).commonAncestorContainer;g.current.contains(c)&&g.current.focus()}}else{var a=[].concat(ce(i(m.current)),[m.current]),l=[].concat(ce(i(o)),[o]),s=Math.min(a.length,l.length)-1;f(a[s],l[s])}}else po(e.current,!0)}),[b,i,f]),h=Object(u.useCallback)((function(){var t=e.current.ownerDocument,n=t.defaultView;t.removeEventListener("selectionchange",O),n.removeEventListener("mouseup",h),p.current=n.requestAnimationFrame((function(){O({isSelectionEnd:!0}),d()}))}),[O,d]);return Object(u.useEffect)((function(){var t=e.current.ownerDocument,n=t.defaultView;return function(){t.removeEventListener("selectionchange",O),n.removeEventListener("mouseup",h),n.cancelAnimationFrame(p.current)}}),[O,h]),Object(u.useCallback)((function(t){if(n){var r=e.current.ownerDocument,o=r.defaultView;m.current=t,g.current=r.activeElement,s(),r.addEventListener("selectionchange",O),o.addEventListener("mouseup",h),po(e.current,!1)}}),[n,s,h])}(t),s=Object(u.useState)({}),d=Object(ie.a)(s,2),b=d[0],p=d[1];return Object(u.createElement)(js,{containerRef:t},Object(u.createElement)(ju.Provider,{value:b},Object(u.createElement)(Ou,null),Object(u.createElement)("div",{ref:t,className:f()(r,"is-root-container"),onFocus:function(e){if(!i){var t=et(e.target);t&&t!==c&&a(t)}},onDragStart:_u},Object(u.createElement)(ku.Provider,{value:p},Object(u.createElement)(hu.Provider,{value:l},n)))))})),Cu=["p","div","h1","h2","h3","h4","h5","h6","ol","ul","li","figure","nav","pre","header","section","aside","footer","main"];function wu(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 Su(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?wu(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Iu(){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)(hu),i=Object(u.useContext)(ku),a=Object(u.useContext)(Nu),l=a.clientId,d=a.rootClientId,p=a.isSelected,m=a.isFirstMultiSelected,g=a.isLastMultiSelected,h=a.isPartOfMultiSelection,j=a.enableAnimation,k=a.index,y=a.className,_=a.name,E=a.mode,C=a.blockTitle,w=a.wrapperProps,S=void 0===w?{}:w,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(ie.a)(R,2),M=A[0],L=A[1];Object(u.useEffect)((function(){if(p||m||g){var e=o.current;return i((function(t){return Su(Su({},t),{},s({},l,e))})),function(){i((function(e){return Object(b.omit)(e,l)}))}}}),[p,m,g]),Object(u.useEffect)((function(){var e=o.current;i((function(t){return t[l]&&t[l]!==e?Su(Su({},t),{},s({},l,e)):t}))}));// translators: %s: Type of block (i.e. Text, Image etc)
|
58 |
+
var F=Object(O.sprintf)(Object(O.__)("Block: %s"),C),V=function(){var e=o.current.ownerDocument;if(!e.activeElement||!Je(o.current,e.activeElement)){var t=xr.focus.tabbable.find(o.current).filter((function(e){return Object(xr.isTextField)(e)&&Je(o.current,e)&&!e.closest(".block-list-appender")})),n=-1===B,r=(n?b.last:b.first)(t)||o.current;Object(xr.placeCaretAtHorizontalEdge)(r,n)}};Object(u.useEffect)((function(){x&&V()}),[x]),Nr(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!==pt.ENTER&&t!==pt.BACKSPACE&&t!==pt.DELETE||n!==o.current||Object(xr.isTextField)(n)||(e.preventDefault(),t===pt.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 Su(Su(Su({},S),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:f()(y,e.className,S.className,{"is-hovered":M}),style:Su(Su({},S.style),e.style)})}Iu.save=c.__unstableGetBlockProps;var Bu=Object(u.forwardRef)((function(e,t){var n=e.children,r=e.tagName,o=void 0===r?"div":r,c=Object(Ee.a)(e,["children","tagName"]);uo()("wp.blockEditor.__experimentalBlock",{alternative:"wp.blockEditor.useBlockProps"});var i=Iu(Su(Su({},c),{},{ref:t}));return Object(u.createElement)(o,i,n)})),xu=Cu.reduce((function(e,t){return e[t]=Object(u.forwardRef)((function(e,n){return Object(u.createElement)(Bu,Object(l.a)({},e,{ref:n,tagName:t}))})),e}),Bu);function Pu(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 Tu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Pu(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Nu=Object(u.createContext)();function Du(e){var t=e.children,n=e.isHtml,r=Object(Ee.a)(e,["children","isHtml"]);return Object(u.createElement)("div",Iu(r,{__unstableIsHtml:n}),t)}var Ru=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,f=o.isSelectionEnabled,b=o.hasSelectedInnerBlock,p=o.getTemplateLock,m=o.__unstableGetBlockWithoutInnerBlocks,v=o.getMultiSelectedBlockClientIds,g=m(n),O=c(n),h=p(r),j=b(n,!0),k=g||{},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:(O||j)&&u(),mode:d(n),isSelectionEnabled:f(),isLocked:!!h,block:g,name:y,attributes:_,isValid:E,isSelected:O,isAncestorOfSelectedBlock:j}})),Au=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)}}})),Mu=Object(p.compose)(p.pure,Ru,Au,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,g=e.isPartOfMultiSelection,O=e.isFirstMultiSelected,h=e.isLastMultiSelected,j=e.isTypingWithinBlock,k=e.isAncestorOfSelectedBlock,y=e.isSelectionEnabled,_=e.className,E=e.name,C=e.isValid,w=e.attributes,S=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(ie.a)(U,2),W=G[0],K=G[1],q=Object(c.getBlockType)(E),$=q.apiVersion>1||Object(c.hasBlockSupport)(q,"lightBlockWrapper",!1),Y=E===Object(c.getUnregisteredTypeHandlerName)();q.getEditWrapperProps&&(t=S,n=q.getEditWrapperProps(w),r=Tu(Tu({},t),n),t&&n&&t.className&&n.className&&(r.className=f()(t.className,n.className)),t&&n&&t.style&&n.style&&(r.style=Tu(Tu({},t.style),n.style)),S=r);var X=$&&Object(c.hasBlockSupport)(q,"className",!0)?Object(c.getBlockDefaultClassName)(E):null,Q=$?w.className:null,Z=S&&!!S["data-align"],J=f()(X,Q,"block-editor-block-list__block",{"wp-block":!Z,"has-warning":!C||!!W||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)(Or,{name:E,isSelected:d,attributes:w,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":S["data-align"]};ee=Object(u.createElement)("div",Object(l.a)({className:"wp-block"},te),ee)}var ne,re={clientId:a,rootClientId:s,isSelected:d,isFirstMultiSelected:O,isLastMultiSelected:h,isPartOfMultiSelection:g,enableAnimation:D,index:N,className:J,isLocked:i,name:E,mode:o,blockTitle:q.title,wrapperProps:Object(b.omit)(S,["data-align"])},oe=Object(u.useMemo)((function(){return re}),Object.values(re));return ne=C?"html"===o?Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{style:{display:"none"}},ee),Object(u.createElement)(Du,{isHtml:!0},Object(u.createElement)(lo,{clientId:a}))):$?ee:Object(u.createElement)(Du,S,ee):Object(u.createElement)(Du,null,Object(u.createElement)(to,{clientId:a}),Object(u.createElement)("div",null,Object(c.getSaveElement)(q,w))),Object(u.createElement)(Nu.Provider,{value:oe},Object(u.createElement)(co,{onError:function(){return K(!0)}},ne),!!W&&Object(u.createElement)(Du,null,Object(u.createElement)(ro,null)))})),Lu=function(e,t,n){return Object(O.sprintf)(
|
59 |
/* translators: 1: The numerical position of the block. 2: The total number of blocks. 3. The level of nesting for the block. */
|
60 |
+
Object(O.__)("Block %1$d of %2$d, Level %3$d"),e,t,n)};var Fu=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,b=t.tabIndex,m=t.onFocus,v=t.onDragStart,g=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),w="block-navigation-block-select-button__".concat(C),S=Lu(l,s,d);return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.Button,{className:f()("block-editor-block-navigation-block-select-button",r),onClick:a,"aria-describedby":w,ref:n,tabIndex:b,onFocus:m,onDragStart:v,onDragEnd:g,draggable:j},Object(u.createElement)(tr,{icon:_.icon,showColors:!0}),E,i&&Object(u.createElement)(h.VisuallyHidden,null,Object(O.__)("(selected block)"))),Object(u.createElement)("div",{className:"block-editor-block-navigation-block-select-button__description",id:w},S))}));function Vu(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 Hu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Vu(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var zu=function(e){return"BlockNavigationBlock-".concat(e)};var Uu=Object(u.forwardRef)((function e(t,n){var r=Object(p.useInstanceId)(e),o=t.block.clientId;return Object(u.createElement)(h.Slot,{name:zu(o)},(function(e){if(!e.length)return Object(u.createElement)(Fu,Object(l.a)({ref:n},t));var o=t.className,i=t.block,a=t.isSelected,s=t.position,d=t.siblingBlockCount,b=t.level,p=t.tabIndex,m=t.onFocus,v=i.name,g=Object(c.getBlockType)(v),j="block-navigation-block-slot__".concat(r),k=Lu(s,d,b),y={tabIndex:p,onFocus:m,ref:n,"aria-describedby":j};return Object(u.createElement)(u.Fragment,null,Object(u.createElement)("div",{className:f()("block-editor-block-navigation-block-slot",o)},Object(u.createElement)(tr,{icon:g.icon,showColors:!0}),u.Children.map(e,(function(e){return Object(u.cloneElement)(e,Hu(Hu({},e.props),y))})),a&&Object(u.createElement)(h.VisuallyHidden,null,Object(O.__)("(selected block)")),Object(u.createElement)("div",{className:"block-editor-block-navigation-block-slot__description",id:j},k)))}))})),Gu=function(e){var t=Object(u.useContext)(Nu).clientId;return Object(u.createElement)(h.Fill,Object(l.a)({},e,{name:zu(t)}))},Wu=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(Ee.a)(e,["onClick","block","isSelected","position","siblingBlockCount","level"]),d=$r(),b=d.__experimentalFeatures,p=d.blockDropTarget,m=void 0===p?{}:p,g=r.clientId,O=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.getBlockRootClientId,r=t.hasBlockMovingClientId,o=t.getSelectedBlockClientId;return{rootClientId:n(g)||"",blockMovingClientId:r(),selectedBlockInBlockEditor:o()}}),[g]),h=O.rootClientId,j=O.blockMovingClientId,k=O.selectedBlockInBlockEditor,y=j&&k===g,_=m.rootClientId,E=m.clientId,C=m.dropPosition,w=_===h&&E===g&&"top"===C,S=_===h&&E===g&&"bottom"===C,I=_===g&&"inside"===C,B=f()("block-editor-block-navigation-block-contents",{"is-dropping-before":w||y,"is-dropping-after":S,"is-dropping-to-inner-blocks":I});return Object(u.createElement)(ws,{clientIds:[r.clientId],elementId:"block-navigation-block-".concat(r.clientId)},(function(e){var d=e.isDraggable,f=e.onDraggableStart,p=e.onDraggableEnd;return b?Object(u.createElement)(Uu,Object(l.a)({ref:t,className:B,block:r,onClick:n,isSelected:o,position:c,siblingBlockCount:i,level:a,draggable:d&&b,onDragStart:f,onDragEnd:p},s)):Object(u.createElement)(Fu,Object(l.a)({ref:t,className:B,block:r,onClick:n,isSelected:o,position:c,siblingBlockCount:i,level:a,draggable:d&&b,onDragStart:f,onDragEnd:p},s))}))}));function Ku(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,b=Object(u.useRef)(null),p=Object(u.useState)(!1),m=Object(ie.a)(p,2),g=m[0],j=m[1],k=Object(u.useState)(!1),y=Object(ie.a)(k,2),_=y[0],E=y[1],C=t.clientId,w=Object(v.useSelect)((function(e){var t=e("core/block-editor"),n=t.isBlockBeingDragged,r=t.isAncestorBeingDragged;return n(C)||r(C)}),[C]),S=Object(v.useDispatch)("core/block-editor").selectBlock,I=l&&a>0,B=g||_,x=f()("block-editor-block-navigation-block__mover-cell",{"is-visible":B}),P=$r().__experimentalFeatures,T=f()("block-editor-block-navigation-block__menu-cell",{"is-visible":B});return Object(u.useEffect)((function(){P&&n&&b.current.focus()}),[P,n]),Object(u.createElement)(Rr,{className:f()({"is-selected":n,"is-dragging":w}),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:b},(function(e){var l=e.ref,d=e.tabIndex,f=e.onFocus;return Object(u.createElement)("div",{className:"block-editor-block-navigation-block__contents-container"},Object(u.createElement)(Kr,{level:c,isLastRow:o===i,terminatedLevels:s}),Object(u.createElement)(Wu,{block:t,onClick:function(){return r(t.clientId)},isSelected:n,position:o,siblingBlockCount:a,level:c,ref:l,tabIndex:d,onFocus:f}))})),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)(Gr,{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)(Wr,{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)(iu,{clientIds:[C],icon:Ir.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:Sr(Cr.a.mark((function e(){return Cr.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,S(null);case 2:return e.next=4,S(C);case 4:t();case 5:case"end":return e.stop()}}),e)})))},Object(O.__)("Go to block")))}))})))}function qu(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)(qu),s="block-navigation-appender-row__description_".concat(l),d=Object(O.sprintf)(
|
61 |
/* translators: 1: The numerical position of the block that will be inserted. 2: The level of nesting for the block that will be inserted. */
|
62 |
+
Object(O.__)("Add block at position %1$d, Level %2$d"),n,r);return Object(u.createElement)(Rr,{className:f()({"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)(Kr,{level:r,isLastRow:n===o,terminatedLevels:c}),Object(u.createElement)(fs,{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 $u(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,f=void 0===d?[]:d,p=e.path,m=void 0===p?[]:p,v=!a,g=Object(b.compact)(t),O=function(e){return o&&!v&&r===e},h=O(a),j=g.length,k=h?j+1:j,y=k;return Object(u.createElement)(u.Fragment,null,Object(b.map)(g,(function(e,t){var a=e.clientId,l=e.innerBlocks,d=t+1,b=k===d?[].concat(ce(f),[s]):f,p=[].concat(ce(m),[d]),v=i&&!!l&&!!l.length,g=O(a);return Object(u.createElement)(u.Fragment,{key:a},Object(u.createElement)(Ku,{block:e,onClick:n,isSelected:r===a,level:s,position:d,rowCount:k,siblingBlockCount:j,showBlockMovers:c,terminatedLevels:f,path:p}),(v||g)&&Object(u.createElement)($u,{blocks:l,selectedBlockClientId:r,selectBlock:n,showAppender:o,showBlockMovers:c,showNestedBlocks:i,parentBlockClientId:a,level:s+1,terminatedLevels:b,path:p}))})),h&&Object(u.createElement)(qu,{parentBlockClientId:a,position:k,rowCount:y,level:s,terminatedLevels:f,path:[].concat(ce(m),[y])}))}function Yu(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 Xu(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 Qu(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 Qu(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 Qu(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 Zu(e,t){return t.left<=e.x&&t.right>=e.x&&t.top<=e.y&&t.bottom>=e.y}$u.defaultProps={selectBlock:function(){}};var Ju=["top","bottom"];function ed(e){var t=Object(u.useState)(),n=Object(ie.a)(t,2),r=n[0],o=void 0===r?{}:r,c=n[1],i=ul(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?Yu(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yu(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,f=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=Xu(e);try{for(a.s();!(i=a.n()).done;){var l=i.value;if(!l.isDraggedBlock){var s=l.element.getBoundingClientRect(),u=fl(t,s,Ju),d=Object(ie.a)(u,2),f=d[0],b=d[1],p=Zu(t,s);if(void 0===o||f<o||p){o=f;var m=e.indexOf(l),v=e[m-1];if("top"===b&&v&&v.rootClientId===l.rootClientId&&!v.isDraggedBlock?(r=v,n="bottom",c=v.element.getBoundingClientRect()):(r=l,n=b,c=s),p)break}}}}catch(e){a.e(e)}finally{a.f()}if(r){var g="bottom"===n;if(g&&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 O=g?1:0;return{rootClientId:r.rootClientId,clientId:r.clientId,blockIndex:r.blockIndex+O,dropPosition:n}}}}(f.current,l);e&&c(e)}}),[f,l]),l)return o}function td(e){var t=e.__experimentalFeatures,n=Object(Ee.a)(e,["__experimentalFeatures"]),r=Object(u.useRef)(),o=ed(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(O.__)("Block navigation structure"),ref:r},Object(u.createElement)(qr.Provider,{value:c},Object(u.createElement)($u,n)))}var nd=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?b.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(O.__)("List view")),i&&Object(u.createElement)(td,{blocks:[t],selectedBlockClientId:r,selectBlock:o,__experimentalFeatures:c,showNestedBlocks:!0}),!i&&Object(u.createElement)(td,{blocks:n,selectedBlockClientId:r,selectBlock:o,__experimentalFeatures:c}))})),rd=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 od(e){var t=e.isEnabled,n=e.onToggle,r=e.isOpen,o=e.innerRef,c=Object(Ee.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:rd,"aria-expanded":r,"aria-haspopup":"true",onClick:t?n:void 0
|
63 |
+
/* translators: button label text should, if possible, be under 16 characters. */,label:Object(O.__)("Outline"),className:"block-editor-block-navigation",shortcut:i,"aria-disabled":!t}))}var cd=Object(u.forwardRef)((function(e,t){var n=e.isDisabled,r=e.__experimentalFeatures,o=Object(Ee.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)(od,Object(l.a)({},o,{innerRef:t,isOpen:n,onToggle:r,isEnabled:c}))},renderContent:function(e){var t=e.onClose;return Object(u.createElement)(nd,{onSelect:t,__experimentalFeatures:r})}})})),id=n(126),ad=[pt.rawShortcut.primary("z"),pt.rawShortcut.primaryShift("z"),pt.rawShortcut.primary("y")],ld=Object(u.createElement)(h.KeyboardShortcuts,{bindGlobal:!0,shortcuts:Object(b.fromPairs)(ad.map((function(e){return[e,function(e){return e.preventDefault()}]})))}),sd=function(){return ld};function ud(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(Us.createBlobURL)(e),'">')})).join("")}var dd={position:"bottom right",isAlternate:!0},fd=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:Fr.a,label:Object(O.__)("More rich text controls"),toggleProps:t,controls:Object(b.orderBy)(e.map((function(e){return Object(ie.a)(e,1)[0].props})),"title"),popoverProps:dd})}))}))))},bd=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)(fd,null)):Object(u.createElement)(_r,null,Object(u.createElement)(fd,null))};function pd(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 md(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?pd(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function vd(e){if(!0===e||"p"===e||"li"===e)return!0===e?"p":e}function gd(e){var t=e.allowedFormats,n=e.formattingControls;return e.disableFormats?gd.EMPTY_ARRAY:t||n?t||(uo()("wp.blockEditor.RichText formattingControls prop",{alternative:"allowedFormats"}),n.map((function(e){return"core/".concat(e)}))):void 0}gd.EMPTY_ARRAY=[];var Od=Object(u.forwardRef)((function e(t,n){var r=t.children,o=t.tagName,a=t.value,s=t.onChange,d=t.isSelected,b=t.multiline,m=t.inlineToolbar,g=t.wrapperClassName,O=t.autocompleters,h=t.onReplace,j=t.placeholder,k=t.keepPlaceholderOnFocus,y=t.allowedFormats,_=t.formattingControls,E=t.withoutInteractiveFormatting,C=t.onRemove,w=t.onMerge,S=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,W=t.rootTagsToEliminate,K=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(Ee.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"]),ne=Object(p.useInstanceId)(e);x=x||ne;var re=Object(u.useRef)(),oe=n||re,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,f=n.isMultiSelecting,b=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 g={};if("native"===u.Platform.OS){var O=le&&s(le);g={shouldBlurOnUnmount:O&&t&&Object(c.isUnmodifiedDefaultBlock)(O)}}return md({isCaretWithinFormattedText:r(),selectionStart:t?p.offset:void 0,selectionEnd:t?m.offset:void 0,isSelected:t,didAutomaticChange:l(),disabled:f()||b(),undo:v},g)})),fe=de.isCaretWithinFormattedText,be=de.selectionStart,pe=de.selectionEnd,me=de.isSelected,ve=de.didAutomaticChange,ge=de.disabled,Oe=de.undo,he=de.shouldBlurOnUnmount,je=Object(v.useDispatch)("core/block-editor"),ke=je.__unstableMarkLastChangeAsPersistent,ye=je.enterFormattedText,_e=je.exitFormattedText,Ce=je.selectionChange,we=je.__unstableMarkAutomaticChange,Se=vd(b),Ie=gd({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;w&&w(!n),C&&Object(i.isEmpty)(t)&&n&&C(!n)}),[w,C]),De=Object(u.useCallback)((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if(h&&S){var n=[],r=Object(i.split)(e),o=Object(ie.a)(r,2),c=o[0],a=o[1],l=t.length>0,s=-1;l&&Object(i.isEmpty)(c)||(n.push(S(Object(i.toHTMLString)({value:c,multilineTag:Se}))),s+=1),l?(n.push.apply(n,ce(t)),s+=t.length):B&&n.push(B()),(l||B)&&Object(i.isEmpty)(a)||n.push(S(Object(i.toHTMLString)({value:a,multilineTag:Se})));var u=l?s:1,d=l?-1:null;h(n,u,d)}}),[h,S,Se,B]),Re=Object(u.useCallback)((function(e){var t=e.value,n=e.onChange,r=e.shiftKey,o=h&&S;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})]),we())}if(b)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,f=I&&u===d&&d===s.length;r||!o&&!f?D||n(Object(i.insert)(t,"\n")):!o&&f?I():o&&De(t)}}),[h,S,we,b,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:ud(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,f=h&&S?"AUTO":"INLINE";"AUTO"===f&&Object(i.isEmpty)(t)&&(d=a,Object(id.regexp)(".*").test(d))&&(f="BLOCKS"),T&&Object(i.isEmpty)(t)&&Object($l.isURL)(a.trim())&&(f="BLOCKS");var p=Object(c.pasteHandler)({HTML:r,plainText:a,mode:f,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(ce(s),ce(m.formats[v]||[]));b&&(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,S,De,T,b,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]),we()}}}}),[h,we]),Le=Object(u.createElement)(i.__experimentalRichText,{clientId:le,identifier:x,ref:oe,value:xe,onChange:Pe,selectionStart:be,selectionEnd:pe,onSelectionChange:Te,tagName:o,placeholder:j,allowedFormats:Ie,withoutInteractiveFormatting:E,onEnter:Re,onDelete:Ne,onPaste:Ae,__unstableIsSelected:me,__unstableInputRule:Me,__unstableMultilineTag:Se,__unstableIsCaretWithinFormattedText:fe,__unstableOnEnterFormattedText:ye,__unstableOnExitFormattedText:_e,__unstableOnCreateUndoLevel:ke,__unstableMarkAutomaticChange:we,__unstableDidAutomaticChange:ve,__unstableUndo:Oe,__unstableDisableFormats:N,preserveWhiteSpace:P,disabled:ge,unstableOnFocus:R,__unstableAllowPrefixTransformations:A,__unstableMultilineRootTag:M,onCaretVerticalPositionChange:se,blockIsSelected:void 0!==d?d:ue,shouldBlurOnUnmount:he,__unstableMobileNoFocusOnMount:L,deleteEnter:F,placeholderTextColor:V,textAlign:H,selectionColor:U,tagsToEliminate:G,rootTagsToEliminate:W,disableEditingMenu:K,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)(bd,{inline:m,anchorRef:oe.current}),t&&Object(u.createElement)(sd,null),Object(u.createElement)(or,{onReplace:h,completers:O,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?md(md({},te.style),i.style):i.style,className:f()("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 g?(uo()("wp.blockEditor.RichText wrapperClassName prop",{alternative:"className prop or create your own wrapper div"}),Object(u.createElement)("div",{className:f()("block-editor-rich-text",g)},Le)):Le}));Od.Content=function(e){var t=e.value,n=e.tagName,r=e.multiline,o=Object(Ee.a)(e,["value","tagName","multiline"]);Array.isArray(t)&&(t=c.children.toHTML(t));var i=vd(r);!t&&i&&(t="<".concat(i,"></").concat(i,">"));var a=Object(u.createElement)(u.RawHTML,null,t);return n?Object(u.createElement)(n,Object(b.omit)(o,["format"]),a):a},Od.isEmpty=function(e){return!e||0===e.length},Od.Content.defaultProps={format:"string",value:""};var hd=Od;function jd(e){var t=e.value,n=e.onChange;return Object(u.createElement)(Gu,null,Object(u.createElement)(hd,{value:t,onChange:n,placeholder:Object(O.__)("Navigation item"),keepPlaceholderOnFocus:!0,withoutInteractiveFormatting:!0,allowedFormats:["core/bold","core/italic","core/image","core/strikethrough"]}))}var kd=n(299);var yd=function(e){var t=e.icon,n=void 0===t?kd.a:t,r=e.label,o=void 0===r?Object(O.__)("Choose variation"):r,c=e.instructions,i=void 0===c?Object(O.__)("Select a variation to start with."):c,a=e.variations,l=e.onSelect,s=e.allowSkip,d=f()("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(O.__)("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(O.__)("Skip"))))},_d=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"})),Ed=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 Cd(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 wd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Cd(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Sd={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(O._x)("Vertically Align Top","Block vertical alignment setting")},center:{icon:Ed,title:Object(O._x)("Vertically Align Middle","Block vertical alignment setting")},bottom:{icon:_d,title:Object(O._x)("Vertically Align Bottom","Block vertical alignment setting")}},Id=["top","center","bottom"],Bd={isAlternate:!0};var xd=function(e){var t=e.value,n=e.onChange,r=e.controls,o=void 0===r?Id:r,c=e.isCollapsed,i=void 0===c||c,a=Sd[t],l=Sd.top;return Object(u.createElement)(h.ToolbarGroup,{popoverProps:Bd,isCollapsed:i,icon:a?a.icon:l.icon,label:Object(O._x)("Change vertical alignment","Block vertical alignment setting label"),controls:o.map((function(e){return wd(wd({},Sd[e]),{},{isActive:t===e,role:i?"menuitemradio":void 0,onClick:(r=e,function(){return n(t===r?void 0:r)})});var r}))})};function Pd(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 Td(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Pd(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Nd=Object(p.createHigherOrderComponent)((function(e){return function(t){var n=ve("color.palette"),r=!ve("color.custom"),o=void 0===t.colors?n:t.colors,c=void 0===t.disableCustomColors?r:t.disableCustomColors,i=!Object(b.isEmpty)(o)||!c;return Object(u.createElement)(e,Td(Td({},t),{},{colors:o,disableCustomColors:c,hasColorsToChoose:i}))}}),"withColorContext"),Dd=Nd(h.ColorPalette);function Rd(e){var t=e.onChange,n=e.value,r=Object(Ee.a)(e,["onChange","value"]);return Object(u.createElement)(Ne,Object(l.a)({},r,{onColorChange:t,colorValue:n,gradients:[],disableCustomGradients:!0}))}var Ad=[];function Md(e){var t=ve("color.gradients")||Ad,n=!ve("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 Ld=function(e){var t=void 0!==e.gradients&&void 0!==e.disableCustomGradients?h.__experimentalGradientPicker:Md;return Object(u.createElement)(t,e)};function Fd(e){var t=e.className,n=e.value,r=e.onChange,o=e.label,c=void 0===o?Object(O.__)("Gradient Presets"):o,i=Object(Ee.a)(e,["className","value","onChange","label"]),a=ve("color.gradients"),s=!ve("color.customGradient");return Object(b.isEmpty)(a)&&s?null:Object(u.createElement)(h.BaseControl,{className:f()("block-editor-gradient-picker-control",t)},Object(u.createElement)(h.BaseControl.VisualLabel,null,c),Object(u.createElement)(Ld,Object(l.a)({value:n,onChange:r,className:"block-editor-gradient-picker-control__gradient-picker-presets",gradients:a,disableCustomGradients:s},i)))}function Vd(e){var t=ve("color.gradients");return Object(b.isEmpty)(t)?null:Object(u.createElement)(h.PanelBody,{title:Object(O.__)("Gradient")},Object(u.createElement)(Fd,e))}var Hd=[25,50,75,100];function zd(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,f=e.height,p=e.onChange,m=e.onChangeImage,v=void 0===m?b.noop:m;function g(e,t){return function(){p({width:e,height:t})}}return Object(u.createElement)(u.Fragment,null,!Object(b.isEmpty)(i)&&Object(u.createElement)(h.SelectControl,{label:Object(O.__)("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(O.__)("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(O.__)("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(O.__)("Height"),value:null!==(n=null!=f?f: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(O.__)("Image size presets")},Hd.map((function(e){var t=Math.round(r*(e/100)),n=Math.round(o*(e/100)),c=d===t&&f===n;return Object(u.createElement)(h.Button,{key:e,isSmall:!0,isPrimary:c,isPressed:c,onClick:g(t,n)},e,"%")}))),Object(u.createElement)(h.Button,{isSmall:!0,onClick:g()},Object(O.__)("Reset")))))}var Ud=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"),Gd=Ud((function(e){var t=e.clientId,n=e.showSeparator,r=e.isFloating,o=e.onAddBlock;return Object(u.createElement)(rl,{rootClientId:t,showSeparator:n,isFloating:r,onAddBlock:o})})),Wd=Object(p.compose)([Ud,Object(v.withSelect)((function(e,t){var n=t.clientId,r=(0,e("core/block-editor").getBlockOrder)(n);return{lastBlockClientId:Object(b.last)(r)}}))])((function(e){var t=e.clientId,n=e.lastBlockClientId;return Object(u.createElement)(nl,{rootClientId:t,lastBlockClientId:n})})),Kd=n(73),qd=n.n(Kd);var $d=new WeakMap;function Yd(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 Xd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yd(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Qd(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,f=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),qd()(a,i)||c(e,i)}),[e,a,t,n,l,r,o,c])}(t,n,o,l,f),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(b.isEqual)(t,a.current)){a.current=t;var l=Object(c.synchronizeBlocksWithTemplate)(i,t);Object(b.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){$d.has(t)||$d.set(t,new WeakMap);var n=$d.get(t);if(!n.has(e)){var r=Object(b.mapValues)(t.providesContext,(function(t){return e[t]}));n.set(e,r)}return n.get(e)}(n.attributes,r)}),[t]);return Object(u.createElement)(dr,{value:m},Object(u.createElement)(gl,{rootClientId:t,renderAppender:d,__experimentalAppenderTagName:s,wrapperRef:i,placeholder:p}))}function Zd(e){return Ja(e),Object(u.createElement)(Qd,e)}var Jd=Object(u.forwardRef)((function(e,t){var n=ef({ref:t},e);return Object(u.createElement)("div",{className:"block-editor-inner-blocks"},Object(u.createElement)("div",n))}));function ef(){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?Zd:Qd;return Xd(Xd({},e),{},{ref:a,className:f()(e.className,"block-editor-block-list__layout",{"has-overlay":i}),children:Object(u.createElement)(s,Object(l.a)({},t,{clientId:o,wrapperRef:a}))})}Jd.DefaultBlockAppender=Wd,Jd.ButtonBlockAppender=Gd,Jd.Content=Object(c.withBlockContentContext)((function(e){var t=e.BlockContent;return Object(u.createElement)(t,null)}));var tf=Jd,nf=n(217);function rf(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 of(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rf(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var cf=[{id:"opensInNewTab",title:Object(O.__)("Open in new tab")}],af=function(e){var t=e.value,n=e.onChange,r=void 0===n?b.noop:n,o=e.settings,c=void 0===o?cf:o;if(!c||!c.length)return null;var i=function(e){return function(n){r(of(of({},t),{},s({},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(O.__)("Currently selected link settings")),a)},lf=n(123),sf=n.n(lf);function uf(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var df=function(e){return e.stopPropagation()},ff=function(e){Jt(n,e);var t=uf(n);function n(e){var r;return $t(this,n),(r=t.call(this,e)).onChange=r.onChange.bind(Qt(r)),r.onFocus=r.onFocus.bind(Qt(r)),r.onKeyDown=r.onKeyDown.bind(Qt(r)),r.selectLink=r.selectLink.bind(Qt(r)),r.handleOnClick=r.handleOnClick.bind(Qt(r)),r.bindSuggestionNode=r.bindSuggestionNode.bind(Qt(r)),r.autocompleteRef=e.autocompleteRef||Object(u.createRef)(),r.inputRef=Object(u.createRef)(),r.updateSuggestions=Object(b.throttle)(r.updateSuggestions.bind(Qt(r)),200),r.suggestionNodes=[],r.isUpdatingSuggestions=!1,r.state={suggestions:[],showSuggestions:!1,selectedSuggestion:null,suggestionsListboxId:"",suggestionOptionIdPrefix:""},r}return Xt(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,sf()(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($l.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(O.sprintf)(
|
64 |
/* translators: %s: number of results. */
|
65 |
Object(O._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(O.__)("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 pt.UP:e.stopPropagation(),e.preventDefault();var a=r?r-1:o.length-1;this.setState({selectedSuggestion:a});break;case pt.DOWN:e.stopPropagation(),e.preventDefault();var l=null===r||r===o.length-1?0:r+1;this.setState({selectedSuggestion:l});break;case pt.TAB:null!==this.state.selectedSuggestion&&(this.selectLink(i),this.props.speak(Object(O.__)("Link selected.")));break;case pt.ENTER:null!==this.state.selectedSuggestion&&(e.stopPropagation(),this.selectLink(i))}}else switch(e.keyCode){case pt.UP:0!==e.target.selectionStart&&(e.stopPropagation(),e.preventDefault(),e.target.setSelectionRange(0,0));break;case pt.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(O.__)("Paste URL or type to search"):c,a=e.__experimentalRenderControl,l=e.value,s=void 0===l?"":l,d=e.autoFocus,b=void 0===d||d,p=this.state,m=p.loading,v=p.showSuggestions,g=p.selectedSuggestion,j=p.suggestionsListboxId,k=p.suggestionOptionIdPrefix,y={id:"url-input-control-".concat(o),label:t,className:f()("block-editor-url-input",n,{"is-full-width":r})},_={value:s,required:!0,autoFocus:b,className:"block-editor-url-input__input",type:"text",onChange:this.onChange,onFocus:this.onFocus,onInput:df,placeholder:i,onKeyDown:this.onKeyDown,role:"combobox","aria-label":Object(O.__)("URL"),"aria-expanded":v,"aria-autocomplete":"list","aria-owns":j,"aria-activedescendant":null!==g?"".concat(k,"-").concat(g):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,g=s.suggestionOptionIdPrefix,O=s.loading,j={id:v,ref:this.autocompleteRef,role:"listbox"},k=function(t,n){return{role:"option",tabIndex:"-1",id:"".concat(g,"-").concat(n),ref:e.bindSuggestionNode(n),"aria-selected":n===m}};return Object(b.isFunction)(r)&&d&&p.length?r({suggestions:p,selectedSuggestion:m,suggestionsListProps:j,buildSuggestionItemProps:k,isLoading:O,handleSuggestionClick:this.handleOnClick,isInitialSuggestions:a&&!(c&&c.length)}):!Object(b.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:f()("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:f()("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),bf=Object(p.compose)(p.withSafeTimeout,h.withSpokenMessages,p.withInstanceId,Object(v.withSelect)((function(e,t){if(!Object(b.isFunction)(t.__experimentalFetchLinkSuggestions))return{__experimentalFetchLinkSuggestions:(0,e("core/block-editor").getSettings)().__experimentalFetchLinkSuggestions}})))(ff),pf=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"})),mf=function(e){var t,n=e.searchTerm,r=e.onClick,o=e.itemProps,c=e.isSelected,i=e.buttonText;return n?(t=i?Object(b.isFunction)(i)?i(n):i:Object(u.createInterpolateElement)(Object(O.sprintf)(
|
66 |
/* translators: %s: search term. */
|
67 |
Object(O.__)("Create: <mark>%s</mark>"),n),{mark:Object(u.createElement)("mark",null)}),Object(u.createElement)(h.Button,Object(l.a)({},o,{className:f()("block-editor-link-control__search-create block-editor-link-control__search-item",{"is-selected":c}),onClick:r}),Object(u.createElement)(ho.a,{className:"block-editor-link-control__search-item-icon",icon:pf}),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},vf=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"})),gf=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,b=e.shouldShowType,p=void 0!==b&&b;return Object(u.createElement)(h.Button,Object(l.a)({},t,{onClick:c,className:f()("block-editor-link-control__search-item",{"is-selected":o,"is-url":a,"is-entity":!a})}),a&&Object(u.createElement)(ho.a,{className:"block-editor-link-control__search-item-icon",icon:vf}),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($l.filterURLForDisplay)(Object($l.safeDecodeURI)(n.url))||""),a&&Object(O.__)("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 Of(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,b=e.isInitialSuggestions,p=e.createSuggestionButtonText,m=e.suggestionsQuery,v=f()("block-editor-link-control__search-results",{"is-loading":d}),g=["url","mailto","tel","internal"],j=1===a.length&&g.includes(a[0].type.toLowerCase()),k=n&&!j&&!b,y=!(null==m?void 0:m.type),_="block-editor-link-control-search-results-label-".concat(t),E=b?Object(O.__)("Recently updated"):Object(O.sprintf)(
|
68 |
/* translators: %s: search term. */
|
69 |
+
Object(O.__)('Search results for "%s"'),r),C=Object(u.createElement)(b?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)(mf,{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)(gf,{key:"".concat(e.id,"-").concat(e.type),itemProps:i(e,t),suggestion:e,index:t,onClick:function(){o(e)},isSelected:t===s,isURL:g.includes(e.type.toLowerCase()),searchTerm:r,shouldShowType:y})}))))}function hf(e){var t=Object(b.startsWith)(e,"#");return Object($l.isURL)(e)||e&&e.includes("www.")||t}function jf(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 kf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?jf(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var yf=function(){return Promise.resolve([])},_f=function(e){var t="URL",n=Object($l.getProtocol)(e)||"";return n.includes("mailto")&&(t="mailto"),n.includes("tel")&&(t="tel"),Object(b.startsWith)(e,"#")&&(t="internal"),Promise.resolve([{id:e,title:e,url:"URL"===t?Object($l.prependHTTP)(e):e,type:t}])},Ef=function(){var e=Sr(Cr.a.mark((function e(t,n,r,o,c,i){var a,l,s;return Cr.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",hf(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 Cf(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 wf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Cf(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Sf=Promise.resolve([]),If=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,f=void 0!==d&&d,m=e.onCreateSuggestion,g=void 0===m?b.noop:m,h=e.onChange,j=void 0===h?b.noop:h,k=e.onSelect,y=void 0===k?b.noop:k,_=e.showSuggestions,E=void 0===_||_,C=e.renderSuggestions,w=void 0===C?function(e){return Object(u.createElement)(Of,e)}:C,S=e.fetchSuggestions,I=void 0===S?null:S,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?_f:yf;return Object(u.useCallback)((function(t,i){var a=i.isInitialSuggestions;return hf(t)?c(t,{isInitialSuggestions:a}):Ef(t,kf(kf({},e),{},{isInitialSuggestions:a}),o,c,n,r)}),[c,o,n])}(D,x,f,A),F=E?I||L:Sf,V=Object(p.useInstanceId)(If),H=Object(u.useState)(),z=Object(ie.a)(H,2),U=z[0],G=z[1],W=function(){var e=Sr(Cr.a.mark((function e(t){var n,r;return Cr.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,g(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(wf(wf({},Object(b.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(),W(U||{url:n})}},Object(u.createElement)(bf,{className:a,value:n,onChange:function(e,t){j(e),G(t)},placeholder:null!=s?s:Object(O.__)("Search or type url"),__experimentalRenderSuggestions:E?function(e){return w(wf(wf({},e),{},{instanceId:V,withCreateSuggestion:f,currentInputValue:n,createSuggestionButtonText:M,suggestionsQuery:D,handleSuggestionClick:function(t){e.handleSuggestionClick&&e.handleSuggestionClick(t),W(t)}}))}:null,__experimentalFetchLinkSuggestions:F,__experimentalHandleURLSuggestions:!0,__experimentalShowInitialSuggestions:T,ref:t}),r)})),Bf=If,xf=Object(h.createSlotFill)("BlockEditorLinkControlViewer"),Pf=xf.Slot,Tf=xf.Fill;function Nf(e){var t=e.value,n=e.onEditClick,r=t&&Object($l.filterURLForDisplay)(Object($l.safeDecodeURI)(t.url))||"";return Object(u.createElement)("div",{"aria-label":Object(O.__)("Currently selected"),"aria-selected":"true",className:f()("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(O.__)("Edit")),Object(u.createElement)(Pf,{fillProps:t}))}var Df=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 Rf(e){var t=e.searchInputPlaceholder,n=e.value,r=e.settings,o=e.onChange,c=void 0===o?b.noop:o,i=e.noDirectEntry,a=void 0!==i&&i,l=e.showSuggestions,s=void 0===l||l,d=e.showInitialSuggestions,f=e.forceIsEditingLink,p=e.createSuggestion,m=e.withCreateSuggestion,v=e.inputValue,g=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)(),w=Object(u.useState)(n&&n.url||""),S=Object(ie.a)(w,2),I=S[0],B=S[1],x=g||I,P=Object(u.useState)(void 0!==f?f:!n||!n.url),T=Object(ie.a)(P,2),N=T[0],D=T[1],R=Object(u.useRef)(!1);Object(u.useEffect)((function(){void 0!==f&&f!==N&&D(f)}),[f]),Object(u.useEffect)((function(){R.current&&C.current&&!C.current.contains(C.current.ownerDocument.activeElement)&&(xr.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(ie.a)(n,2),o=r[0],c=r[1],i=Object(u.useState)(null),a=Object(ie.a)(i,2),l=a[0],s=a[1],d=function(){var n=Sr(Cr.a.mark((function n(r){return Cr.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return c(!0),s(null),n.prev=2,t.current=Df(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(O.__)("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(O.__)("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)(Bf,{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(O.__)("Submit"),icon:nf.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)(Nf,{value:n,onEditClick:function(){return D(!0)}}),Object(u.createElement)(af,{value:n,settings:r,onChange:c}))}Rf.ViewerFill=Tf;var Af=Rf,Mf=n(300),Lf=n(218),Ff=Object(h.withFilters)("editor.MediaUpload")((function(){return null}));var Vf=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},Hf=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?b.noop:a,s=e.name,d=void 0===s?Object(O.__)("Replace"):s,f=e.createNotice,p=e.removeNotice,m=Object(u.useState)(t),g=Object(ie.a)(m,2),j=g[0],k=g[1],y=Object(v.useSelect)((function(e){return e("core/block-editor").getSettings().mediaUpload}),[]),_=Object(u.createRef)(),E=Object(b.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(){f("error",n,{speak:!0,id:E,isDismissible:!0})}),1e3)},w=function(e){c(e),k(e.url),Object(Ue.speak)(Object(O.__)("The media file has been replaced")),p(E)},S=function(e){e.keyCode===pt.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:S},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)(Ff,{value:n,onSelect:function(e){return w(e)},allowedTypes:r,render:function(e){var t=e.open;return Object(u.createElement)(h.MenuItem,{icon:Mf.a,onClick:t},Object(O.__)("Open Media Library"))}}),Object(u.createElement)(Vf,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(ie.a)(e,1)[0];w(t)},onError:C})}(e)},accept:o,render:function(e){var t=e.openFileDialog;return Object(u.createElement)(h.MenuItem,{icon:Lf.a,onClick:function(){t()}},Object(O.__)("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(O.__)("Current media URL:")),Object(u.createElement)(Af,{value:{url:j},settings:[],showSuggestions:!1,onChange:function(e){var t=e.url;k(t),i(t),_.current.focus()}})))}})})),zf=n(200);function Uf(e){var t=e.url,n=e.urlLabel,r=e.className,o=f()(r,"block-editor-url-popover__link-viewer-url");return t?Object(u.createElement)(h.ExternalLink,{className:o,href:t},n||Object($l.filterURLForDisplay)(Object($l.safeDecodeURI)(t))):Object(u.createElement)("span",{className:o})}function Gf(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(Ee.a)(e,["additionalControls","children","renderSettings","position","focusOnMount"]),d=Object(u.useState)(!1),f=Object(ie.a)(d,2),b=f[0],p=f[1],m=!!r&&b;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:Fr.a,label:Object(O.__)("Link settings"),onClick:function(){p(!b)},"aria-expanded":b})),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))}Gf.LinkEditor=function(e){var t=e.autocompleteRef,n=e.className,r=e.onChangeInputValue,o=e.value,c=Object(Ee.a)(e,["autocompleteRef","className","onChangeInputValue","value"]);return Object(u.createElement)("form",Object(l.a)({className:f()("block-editor-url-popover__link-editor",n)},c),Object(u.createElement)(bf,{value:o,onChange:r,autocompleteRef:t}),Object(u.createElement)(h.Button,{icon:nf.a,label:Object(O.__)("Apply"),type:"submit"}))},Gf.LinkViewer=function(e){var t=e.className,n=e.linkClassName,r=e.onEditLinkClick,o=e.url,c=e.urlLabel,i=Object(Ee.a)(e,["className","linkClassName","onEditLinkClick","url","urlLabel"]);return Object(u.createElement)("div",Object(l.a)({className:f()("block-editor-url-popover__link-viewer",t)},i),Object(u.createElement)(Uf,{url:o,urlLabel:c,className:n}),r&&Object(u.createElement)(h.Button,{icon:zf.a,label:Object(O.__)("Edit"),onClick:r}))};var Wf=Gf,Kf=function(e){var t=e.src,n=e.onChange,r=e.onSubmit,o=e.onClose;return Object(u.createElement)(Wf,{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(O.__)("URL"),placeholder:Object(O.__)("Paste or type URL"),onChange:n,value:t}),Object(u.createElement)(h.Button,{className:"block-editor-media-placeholder__url-input-submit-button",icon:nf.a,label:Object(O.__)("Apply"),type:"submit"})))};var qf=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,g=e.multiple,j=void 0!==g&&g,k=e.dropZoneUIOnly,y=e.disableDropZone,_=e.disableMediaButtons,E=e.onError,C=e.onSelect,w=e.onCancel,S=e.onSelectURL,I=e.onDoubleClick,B=e.onFilesPreUpload,x=void 0===B?b.noop:B,P=e.onHTMLDrop,T=void 0===P?b.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(ie.a)(R,2),M=A[0],L=A[1],F=Object(u.useState)(!1),V=Object(ie.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)},W=function(){z(!1)},K=function(e){e.preventDefault(),M&&S&&(S(M),W())},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(ie.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||S||(n=Object(O.__)("To edit this block, you need permission to upload media.")),void 0===n||void 0===i){var b=null!=r?r:[],p=Object(ie.a)(b,1)[0],m=1===b.length,v=m&&"audio"===p,g=m&&"image"===p,j=m&&"video"===p;void 0===n&&D&&(n=Object(O.__)("Upload a media file or pick one from your media library."),v?n=Object(O.__)("Upload an audio file, pick one from your media library, or add one with a URL."):g?n=Object(O.__)("Upload an image file, pick one from your media library, or add one with a URL."):j&&(n=Object(O.__)("Upload a video file, pick one from your media library, or add one with a URL."))),void 0===i&&(i=Object(O.__)("Media"),v?i=Object(O.__)("Audio"):g?i=Object(O.__)("Image"):j&&(i=Object(O.__)("Video")))}var k=f()("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 w&&Object(u.createElement)(h.Button,{className:"block-editor-media-placeholder__cancel-button",title:Object(O.__)("Cancel"),isLink:!0,onClick:w},Object(O.__)("Cancel"))},Z=function(){return S&&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(O.__)("Insert from URL")),H&&Object(u.createElement)(Kf,{src:M,onChange:U,onSubmit:K,onClose:W}))};return k||_?(k&&uo()("wp.blockEditor.MediaPlaceholder dropZoneUIOnly prop",{alternative:"disableMediaButtons"}),Object(u.createElement)(Vf,null,X())):Object(u.createElement)(Vf,{fallback:Y(Z())},function(){var e=Object(u.createElement)(Ff,{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(O.__)("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:f()("block-editor-media-placeholder__button","block-editor-media-placeholder__upload-button")},Object(O.__)("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:f()("block-editor-media-placeholder__button","block-editor-media-placeholder__upload-button"),onChange:$,accept:p,multiple:j},Object(O.__)("Upload")),e,Z(),Q());return Y(t)}return Y(e)}())})),$f=Object(u.forwardRef)((function(e,t){return Object(u.createElement)(hd,Object(l.a)({ref:t},e,{__unstableDisableFormats:!0,preserveWhiteSpace:!0}))}));$f.Content=function(e){var t=e.value,n=void 0===t?"":t,r=e.tagName,o=void 0===r?"div":r,c=Object(Ee.a)(e,["value","tagName"]);return Object(u.createElement)(o,c,n)};var Yf=$f,Xf=Object(u.forwardRef)((function(e,t){var n=e.__experimentalVersion,r=Object(Ee.a)(e,["__experimentalVersion"]);if(2===n)return Object(u.createElement)(Yf,Object(l.a)({ref:t},r));var o=r.className,c=r.onChange,i=Object(Ee.a)(r,["className","onChange"]);return Object(u.createElement)(ao.a,Object(l.a)({ref:t,className:f()("block-editor-plain-text",o),onChange:function(e){return c(e.target.value)}},i))}));function Qf(e){var t=e.property,n=e.viewport,r=e.desc,o=Object(p.useInstanceId)(Qf),c=r||Object(O.sprintf)(
|
70 |
/* translators: 1: property name. 2: viewport name. */
|
71 |
Object(O._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 Zf=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",
|
72 |
/* translators: 'Label. Used to signify a layout property (eg: margin, padding) will apply uniformly to all screensizes.' */
|
74 |
/* translators: 'Toggle control label. Should the property be the same across all screen sizes or unique per screen size.'. %s property value for the control (eg: margin, padding...etc) */
|
75 |
Object(O.__)("Use the same %s on all screensizes."),n),v=Object(O.__)("Toggle between using the same value for all screen sizes or using a unique value per screen size."),g=c(Object(u.createElement)(Qf,{property:n,viewport:d}),d);
|
76 |
/* translators: 'Help text for the responsive mode toggle control.' */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:f()("block-editor-responsive-block-control__group",{"is-responsive":l})},!l&&g,l&&(i?i(p):p.map((function(e){return Object(u.createElement)(u.Fragment,{key:e.id},c(Object(u.createElement)(Qf,{property:n,viewport:e}),e))}))))))};function Jf(e){var t=e.character,n=e.type,r=e.onUse;return Object(p.useKeyboardShortcut)(pt.rawShortcut[n](t),(function(){return r(),!1}),{bindGlobal:!0}),null}function eb(e){var t,n=e.name,r=e.shortcutType,o=e.shortcutCharacter,c=Object(Ee.a)(e,["name","shortcutType","shortcutCharacter"]),i="RichText.ToolbarControls";return n&&(i+=".".concat(n)),r&&o&&(t=pt.displayShortcut[r](o)),Object(u.createElement)(h.Fill,{name:i},Object(u.createElement)(h.ToolbarButton,Object(l.a)({},c,{shortcut:t})))}function tb(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var nb=function(e){Jt(n,e);var t=tb(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).onInput=e.onInput.bind(Qt(e)),e}return Xt(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),rb=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 ob=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?rb:zf.a,"aria-expanded":o,"aria-haspopup":"true",onClick:c
|
77 |
+
/* translators: button label text should, if possible, be under 16 characters. */,label:Object(O.__)("Modes")}))},position:"bottom right",renderContent:function(){return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.NavigableMenu,{role:"menu","aria-label":Object(O.__)("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)(ho.a,{icon:zf.a}),Object(O.__)("Edit"))},{value:"select",label:Object(u.createElement)(u.Fragment,null,rb,Object(O.__)("Select"))}]})),Object(u.createElement)("div",{className:"block-editor-tool-selector__help"},Object(O.__)("Tools offer different interactions for block selection & editing. To select, press Escape, to go back to editing, press Enter.")))}})})),cb=n(192),ib=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 ab(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var lb=function(e){Jt(n,e);var t=ab(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).toggle=e.toggle.bind(Qt(e)),e.submitLink=e.submitLink.bind(Qt(e)),e.state={expanded:!1},e}return Xt(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(O.__)("Edit link"):Object(O.__)("Insert link");return Object(u.createElement)("div",{className:"block-editor-url-input__button"},Object(u.createElement)(h.Button,{icon:cb.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:ib,label:Object(O.__)("Close"),onClick:this.toggle}),Object(u.createElement)(bf,{value:t||"",onChange:n}),Object(u.createElement)(h.Button,{icon:nf.a,label:Object(O.__)("Submit"),type:"submit"}))))}}]),n}(u.Component),sb=n(128),ub=["noreferrer","noopener"],db=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"})),fb=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,f=Object(u.useState)(!1),p=Object(ie.a)(f,2),m=p[0],v=p[1],g=Object(u.useCallback)((function(){v(!0)})),j=Object(u.useState)(!1),k=Object(ie.a)(j,2),y=k[0],_=k[1],E=Object(u.useState)(null),C=Object(ie.a)(E,2),w=C[0],S=C[1],I=Object(u.useRef)(null),B=function(e){e.stopPropagation()},x=function(e){[pt.LEFT,pt.DOWN,pt.RIGHT,pt.UP,pt.BACKSPACE,pt.ENTER].indexOf(e.keyCode)>-1&&e.stopPropagation()},P=Object(u.useCallback)((function(){"media"!==t&&"attachment"!==t||S(""),_(!0)})),T=Object(u.useCallback)((function(){_(!1)})),N=Object(u.useCallback)((function(){S(null),T(),v(!1)})),D=function(e){var t=e;return void 0===e||Object(b.isEmpty)(t)||Object(b.isEmpty)(t)||(Object(b.each)(ub,(function(e){var n=new RegExp("\\b"+e+"\\b","gi");t=t.replace(n,"")})),t!==e&&(t=t.trim()),Object(b.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),S(null),T())}})),A=Object(u.useCallback)((function(){return function(e){w&&n({href:w}),T(),S(null),e.preventDefault()}})),M=Object(u.useCallback)((function(){n({linkDestination:"none",href:""})})),L=function(){var e=[{linkDestination:"media",title:Object(O.__)("Media File"),url:"image"===c?i:void 0,icon:db}];return"image"===c&&a&&e.push({linkDestination:"attachment",title:Object(O.__)("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(O.__)("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(O.__)("Link Rel"),value:D(d)||"",onChange:function(e){n({rel:e})},onKeyPress:B,onKeyDown:x}),Object(u.createElement)(h.TextControl,{label:Object(O.__)("Link CSS Class"),value:s||"",onKeyPress:B,onKeyDown:x,onChange:function(e){n({linkClass:e})}})),V=null!==w?w:r,H=(Object(b.find)(L(),["linkDestination",t])||{}).title;return Object(u.createElement)(u.Fragment,null,Object(u.createElement)(h.ToolbarButton,{icon:cb.a,className:"components-toolbar__control",label:r?Object(O.__)("Edit link"):Object(O.__)("Insert link"),"aria-expanded":m,onClick:g}),m&&Object(u.createElement)(Wf,{onFocusOutside:R(),onClose:N,renderSettings:function(){return F},additionalControls:!V&&Object(u.createElement)(h.NavigableMenu,null,Object(b.map)(L(),(function(e){return Object(u.createElement)(h.MenuItem,{key:e.linkDestination,icon:e.icon,onClick:function(){var t,r,o;S(null),t=e.url,o=L(),r=t?(Object(b.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)(Wf.LinkEditor,{className:"block-editor-format-toolbar__link-container-content",value:V,onChangeInputValue:S,onKeyDown:x,onKeyPress:B,onSubmit:A(),autocompleteRef:I}),r&&!y&&Object(u.createElement)(u.Fragment,null,Object(u.createElement)(Wf.LinkViewer,{className:"block-editor-format-toolbar__link-container-content",onKeyPress:B,url:r,onEditLinkClick:P,urlLabel:H}),Object(u.createElement)(h.Button,{icon:sb.a,label:Object(O.__)("Remove link"),onClick:M}))))},bb=n(129);function pb(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:f()(n,"block-editor-post-preview__dropdown-content"),position:"bottom left"},l={isTertiary:!0,className:"block-editor-post-preview__button-toggle",disabled:!o,
|
78 |
/* translators: button label text should, if possible, be under 16 characters. */
|
79 |
children:Object(O.__)("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&&bb.a},Object(O.__)("Desktop")),Object(u.createElement)(h.MenuItem,{className:"block-editor-post-preview__button-resize",onClick:function(){return i("Tablet")},icon:"Tablet"===c&&bb.a},Object(O.__)("Tablet")),Object(u.createElement)(h.MenuItem,{className:"block-editor-post-preview__button-resize",onClick:function(){return i("Mobile")},icon:"Mobile"===c&&bb.a},Object(O.__)("Mobile"))),t)}))}var mb=n(266),vb=/\((min|max)-width:[^\(]*?\)/g;function gb(e){return!!e.media&&!!e.media.mediaText.match(vb)}function Ob(e,t,n){e.deleteRule(n),e.insertRule(t,n)}function hb(e,t){return e.replace(vb,(function(e){return Object(mb.match)(e,{type:"screen",width:t})?"(min-width:0px)":"(min-width:999999px)"}))}function jb(e,t){Object(u.useEffect)((function(){if(t){var n,r,o,c="undefined"==typeof window?[]:Object(b.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($l.getProtocol)(e.href)===window.location.protocol&&Object($l.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&&gb(a))){var l=a.cssText;i[r]||(i[r]=[]),i[r][c]=l,Ob(n,hb(l,t),c)}}})),function(){i.forEach((function(e,t){if(e)for(var n=0;n<e.length;++n){var r=e[n];r&&Ob(c[t],r,n)}}))}}}),[t])}function kb(e){var t=Object(u.useState)(window.innerWidth),n=Object(ie.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 jb("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 yb=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(){Ze(t).focus()}},Object(O.__)("Skip to the selected block"))})),_b=n(124);var Eb=Object(v.withSelect)((function(e){return{blocks:(0,e("core/block-editor").getMultiSelectedBlocks)()}}))((function(e){var t=e.blocks,n=Object(_b.count)(Object(c.serialize)(t),"words");return Object(u.createElement)("div",{className:"block-editor-multi-selection-inspector__card"},Object(u.createElement)(tr,{icon:Bs,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(O.sprintf)(
|
80 |
/* translators: %d: number of blocks */
|
81 |
Object(O._n)("%d block","%d blocks",t.length),t.length)),Object(u.createElement)("div",{className:"block-editor-multi-selection-inspector__card-description"},Object(O.sprintf)(
|
82 |
/* translators: %d: number of words */
|
83 |
+
Object(O._n)("%d word","%d words",n),n))))}));function Cb(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(O.__)("Not set"),value:""}].concat(ce(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(O.__)("Default Style"),onChange:a})}var wb=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(O.__)("Advanced"),initialOpen:!1},Object(u.createElement)(q.Slot,{bubblesVirtually:n})):null},Sb=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)(Eb,null),Object(u.createElement)(Qe.Slot,{bubblesVirtually:d}));var f=i===Object(c.getUnregisteredTypeHandlerName)();return t&&o&&!f?Object(u.createElement)("div",{className:"block-editor-block-inspector"},Object(u.createElement)(yo,{blockType:t}),r&&Object(u.createElement)("div",null,Object(u.createElement)(h.PanelBody,{title:Object(O.__)("Styles")},Object(u.createElement)(Rs,{clientId:o}),Object(c.hasBlockSupport)(t.name,"defaultStylePicker",!0)&&Object(u.createElement)(Cb,{blockName:t.name}))),Object(u.createElement)(Qe.Slot,{bubblesVirtually:d}),Object(u.createElement)("div",null,Object(u.createElement)(wb,{slotName:q.slotName,bubblesVirtually:d})),Object(u.createElement)(yb,{key:"back"})):l?Object(u.createElement)("span",{className:"block-editor-block-inspector__no-blocks"},Object(O.__)("No block selected.")):null}));function Ib(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 Bb=n(267),xb=n.n(Bb),Pb=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,Tb=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),b(),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 f(/^{\s*/)}function u(){return f(/^}/)}function d(){var t,n=[];for(b(),p(n);e.length&&"}"!==e.charAt(0)&&(t=C()||w());)!1!==t&&(n.push(t),p(n));return n}function f(t){var n=t.exec(e);if(n){var r=n[0];return o(r),e=e.slice(r.length),n}}function b(){f(/^\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=f(/^([^{]+)/);if(e)return Nb(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 g(){var e=c(),t=f(/^(\*?[-#\/\*\\\w]+(\[[0-9a-z_-]+\])?)\s*/);if(t){if(t=Nb(t[0]),!f(/^:\s*/))return l("property missing ':'");var n=f(/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^\)]*?\)|[^};])+)/),r=e({type:"declaration",property:t.replace(Pb,""),value:n?Nb(n[0]).replace(Pb,""):""});return f(/^[;\s]*/),r}}function O(){var e,t=[];if(!s())return l("missing '{'");for(p(t);e=g();)!1!==e&&(t.push(e),p(t));return u()?t:l("missing '}'")}function h(){for(var e,t=[],n=c();e=f(/^((\d+\.\d+|\.\d+|\d+)%?|[a-z]+)\s*/);)t.push(e[1]),f(/^,\s*/);if(t.length)return n({type:"keyframe",values:t,declarations:O()})}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=f(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=f(/^@([-\w]+)?keyframes\s*/);if(t){var n=t[1];if(!(t=f(/^([-\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=f(/^@media *([^{]+)/);if(t){var n=Nb(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=f(/^@custom-media\s+(--[^\s]+)\s*([^{;]+);/);if(t)return e({type:"custom-media",name:Nb(t[1]),media:Nb(t[2])})}()||function(){var e=c(),t=f(/^@supports *([^{]+)/);if(t){var n=Nb(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=f(/^@([-\w]+)?document *([^{]+)/);if(t){var n=Nb(t[1]),r=Nb(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(f(/^@page */)){var t=v()||[];if(!s())return l("@page missing '{'");for(var n,r=p();n=g();)r.push(n),r=r.concat(p());return u()?e({type:"page",selectors:t,declarations:r}):l("@page missing '}'")}}()||function(){var e=c();if(f(/^@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(f(/^@font-face\s*/)){if(!s())return l("@font-face missing '{'");for(var t,n=p();t=g();)n.push(t),n=n.concat(p());return u()?e({type:"font-face",declarations:n}):l("@font-face missing '}'")}}()}function w(){var e=c(),t=v();return t?(p(),e({type:"rule",selectors:t,declarations:O()})):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"===en(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 Nb(e){return e?e.replace(/^\s+|\s+$/g,""):""}var Db=n(171),Rb=n.n(Db),Ab=Mb;function Mb(e){this.options=e||{}}Mb.prototype.emit=function(e){return e},Mb.prototype.visit=function(e){return this[e.type](e)},Mb.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 Lb=Fb;function Fb(e){Ab.call(this,e)}Rb()(Fb,Ab),Fb.prototype.compile=function(e){return e.stylesheet.rules.map(this.visit,this).join("")},Fb.prototype.comment=function(e){return this.emit("",e.position)},Fb.prototype.import=function(e){return this.emit("@import "+e.import+";",e.position)},Fb.prototype.media=function(e){return this.emit("@media "+e.media,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Fb.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("}")},Fb.prototype.charset=function(e){return this.emit("@charset "+e.charset+";",e.position)},Fb.prototype.namespace=function(e){return this.emit("@namespace "+e.namespace+";",e.position)},Fb.prototype.supports=function(e){return this.emit("@supports "+e.supports,e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Fb.prototype.keyframes=function(e){return this.emit("@"+(e.vendor||"")+"keyframes "+e.name,e.position)+this.emit("{")+this.mapVisit(e.keyframes)+this.emit("}")},Fb.prototype.keyframe=function(e){var t=e.declarations;return this.emit(e.values.join(","),e.position)+this.emit("{")+this.mapVisit(t)+this.emit("}")},Fb.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("}")},Fb.prototype["font-face"]=function(e){return this.emit("@font-face",e.position)+this.emit("{")+this.mapVisit(e.declarations)+this.emit("}")},Fb.prototype.host=function(e){return this.emit("@host",e.position)+this.emit("{")+this.mapVisit(e.rules)+this.emit("}")},Fb.prototype["custom-media"]=function(e){return this.emit("@custom-media "+e.name+" "+e.media+";",e.position)},Fb.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("}"):""},Fb.prototype.declaration=function(e){return this.emit(e.property+":"+e.value,e.position)+this.emit(";")};var Vb=Hb;function Hb(e){e=e||{},Ab.call(this,e),this.indentation=e.indent}Rb()(Hb,Ab),Hb.prototype.compile=function(e){return this.stylesheet(e)},Hb.prototype.stylesheet=function(e){return this.mapVisit(e.stylesheet.rules,"\n\n")},Hb.prototype.comment=function(e){return this.emit(this.indent()+"/*"+e.comment+"*/",e.position)},Hb.prototype.import=function(e){return this.emit("@import "+e.import+";",e.position)},Hb.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}")},Hb.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}")},Hb.prototype.charset=function(e){return this.emit("@charset "+e.charset+";",e.position)},Hb.prototype.namespace=function(e){return this.emit("@namespace "+e.namespace+";",e.position)},Hb.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}")},Hb.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)+"}")},Hb.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")},Hb.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}")},Hb.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}")},Hb.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}")},Hb.prototype["custom-media"]=function(e){return this.emit("@custom-media "+e.name+" "+e.media+";",e.position)},Hb.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()+"}"):""},Hb.prototype.declaration=function(e){return this.emit(this.indent())+this.emit(e.property+": "+e.value,e.position)+this.emit(";")},Hb.prototype.indent=function(e){return this.level=this.level||1,null!==e?(this.level+=e,""):Array(this.level).join(this.indentation||" ")};var zb=function(e,t){try{var n=Tb(e),r=xb.a.map(n,(function(e){if(!e)return e;var n=t(e);return this.update(n)}));return o=r,((c=c||{}).compress?new Lb(c):new Vb(c)).compile(o)}catch(e){return console.warn("Error while traversing the CSS: "+e),null}var o,c};function Ub(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?Ub(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ub(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Wb(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 Kb(e,t){return new URL(e,t).toString()}var qb=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]};Wb(o)&&r.push(o)}return r}(t.value).map((c=e,function(e){return Gb(Gb({},e),{},{newUrl:"url("+e.before+e.quote+Kb(e.value,c)+e.quote+e.after+")"})}));return Gb(Gb({},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 $b(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 Yb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$b(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$b(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Xb=/^(body|html|:root).*$/,Qb=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return function(n){return"rule"===n.type?Yb(Yb({},n),{},{selectors:n.selectors.map((function(n){return t.includes(n.trim())?n:n.match(Xb)?n.replace(/^(body|html|:root)/,e):e+" "+n}))}):n}},Zb=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Object(b.map)(e,(function(e){var n=e.css,r=e.baseURL,o=[];return t&&o.push(Qb(t)),r&&o.push(qb(r)),o.length?zb(n,Object(p.compose)(o)):n}))};var Jb=function(e){var t=e.styles;return Object(u.useEffect)((function(){var e=Zb(t,".editor-styles-wrapper"),n=Object(b.map)(Object(b.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 ep=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?b.noop:s,f=Object(v.useSelect)((function(e){var r=e("core/block-editor").getBlockRootClientId;return t||r(n)||void 0}),[n,t]);return Object(u.createElement)(os,{onSelect:d,rootClientId:f,clientId:n,isAppender:r,showInserterHelpPanel:o,showMostUsedBlocks:i,__experimentalSelectBlockOnInsert:a,__experimentalInsertionIndex:l})};function tp(){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(ie.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,f=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(b.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(b.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(b.first)(n),Object(b.last)(n))}),[n,d])),Object(a.useShortcut)("core/block-editor/unselect",Object(u.useCallback)((function(e){e.preventDefault(),f(),e.target.ownerDocument.defaultView.getSelection().removeAllRanges()}),[t,f]),{isDisabled:t.length<2}),null}tp.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(O.__)("Duplicate the selected block(s)."),keyCombination:{modifier:"primaryShift",character:"d"}}),e({name:"core/block-editor/remove",category:"block",description:Object(O.__)("Remove the selected block(s)."),keyCombination:{modifier:"access",character:"z"}}),e({name:"core/block-editor/insert-before",category:"block",description:Object(O.__)("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(O.__)("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(O.__)("Remove multiple selected blocks."),keyCombination:{character:"del"},aliases:[{character:"backspace"}]}),e({name:"core/block-editor/select-all",category:"selection",description:Object(O.__)("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(O.__)("Clear selection."),keyCombination:{character:"escape"}}),e({name:"core/block-editor/focus-toolbar",category:"global",description:Object(O.__)("Navigate to the nearest toolbar."),keyCombination:{modifier:"alt",character:"F10"}}),e({name:"core/block-editor/move-up",category:"block",description:Object(O.__)("Move the selected block(s) up."),keyCombination:{modifier:"secondary",character:"t"}}),e({name:"core/block-editor/move-down",category:"block",description:Object(O.__)("Move the selected block(s) down."),keyCombination:{modifier:"secondary",character:"y"}})}),[e]),null};var np=tp;function rp(){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=Ze(n);if(e){var o=Object(xr.getScrollContainer)(e);o&&sf()(e,o,{onlyScrollIfNeeded:!0})}}}),[t,n,r]),null}var op=[pt.UP,pt.RIGHT,pt.DOWN,pt.LEFT,pt.ENTER,pt.BACKSPACE];var cp=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",f),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 f(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(xr.isTextField)(n)&&r.current.contains(n)&&("keydown"!==t||function(e){var t=e.keyCode;return!e.shiftKey&&op.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(xr.isTextField)(t)&&l()}))},onKeyPress:p,onKeyDown:Object(b.over)([p,function(e){!c||e.keyCode!==pt.ESCAPE&&e.keyCode!==pt.TAB||l()}])},t)}));function ip(){return uo()("PreserveScrollInReorder component",{hint:"This behavior is now built-in the block list"}),null}function ap(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=nn(e);if(t){var o=nn(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return tn(this,n)}}var lp=-1!==window.navigator.userAgent.indexOf("Trident"),sp=new Set([pt.UP,pt.DOWN,pt.LEFT,pt.RIGHT]),up=function(e){Jt(n,e);var t=ap(n);function n(){var e;return $t(this,n),(e=t.apply(this,arguments)).ref=Object(u.createRef)(),e.onKeyDown=e.onKeyDown.bind(Qt(e)),e.addSelectionChangeListener=e.addSelectionChangeListener.bind(Qt(e)),e.computeCaretRectOnSelectionChange=e.computeCaretRectOnSelectionChange.bind(Qt(e)),e.maintainCaretPosition=e.maintainCaretPosition.bind(Qt(e)),e.computeCaretRect=e.computeCaretRect.bind(Qt(e)),e.onScrollResize=e.onScrollResize.bind(Qt(e)),e.isSelectionEligibleForScroll=e.isSelectionEligibleForScroll.bind(Qt(e)),e.getDocument=e.getDocument.bind(Qt(e)),e.getWindow=e.getWindow.bind(Qt(e)),e}return Xt(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(xr.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(xr.computeCaretRect)(this.getWindow());if(n)if(this.caretRect)if(sp.has(t))this.caretRect=n;else{var r=n.top-this.caretRect.top;if(0!==r){var o=Object(xr.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),dp=lp?function(e){return e.children}:Object(v.withSelect)((function(e){return{selectedBlockClientId:(0,e("core/block-editor").getSelectedBlockClientId)()}}))(up);function fp(e){if(void 0===e)e=Eo.colors;else{var t=e.filter((function(e){return e.color}));0===t.length?e=Eo.colors:t.length<e.length&&(e=t)}return e}function bp(e){if(void 0===e)e=Eo.gradients;else{var t=e.filter((function(e){return e.gradient}));0===t.length?e=Eo.gradients:t.length<e.length&&(e=t)}return e}}]);
|
build/block-library/blocks/archives.php
CHANGED
@@ -88,17 +88,16 @@ function gutenberg_render_block_core_archives( $attributes ) {
|
|
88 |
|
89 |
$classnames = esc_attr( $class );
|
90 |
|
91 |
-
|
92 |
|
|
|
93 |
return sprintf(
|
94 |
-
'<div
|
95 |
-
$
|
96 |
__( 'No archives to show.' )
|
97 |
);
|
98 |
}
|
99 |
|
100 |
-
$wrapper_attributes = get_block_wrapper_attributes( array( 'class' => $classnames ) );
|
101 |
-
|
102 |
return sprintf(
|
103 |
'<ul %1$s>%2$s</ul>',
|
104 |
$wrapper_attributes,
|
88 |
|
89 |
$classnames = esc_attr( $class );
|
90 |
|
91 |
+
$wrapper_attributes = get_block_wrapper_attributes( array( 'class' => $classnames ) );
|
92 |
|
93 |
+
if ( empty( $archives ) ) {
|
94 |
return sprintf(
|
95 |
+
'<div %1$s>%2$s</div>',
|
96 |
+
$wrapper_attributes,
|
97 |
__( 'No archives to show.' )
|
98 |
);
|
99 |
}
|
100 |
|
|
|
|
|
101 |
return sprintf(
|
102 |
'<ul %1$s>%2$s</ul>',
|
103 |
$wrapper_attributes,
|
build/block-library/index.asset.php
CHANGED
@@ -1 +1 @@
|
|
1 |
-
<?php return array('dependencies' => array('lodash', 'moment', 'react', 'wp-api-fetch', 'wp-autop', 'wp-blob', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-date', 'wp-deprecated', 'wp-dom', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-notices', 'wp-polyfill', 'wp-primitives', 'wp-reusable-blocks', 'wp-rich-text', 'wp-server-side-render', 'wp-url', 'wp-viewport'), 'version' => '
|
1 |
+
<?php return array('dependencies' => array('lodash', 'moment', 'react', 'wp-api-fetch', 'wp-autop', 'wp-blob', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-date', 'wp-deprecated', 'wp-dom', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-notices', 'wp-polyfill', 'wp-primitives', 'wp-reusable-blocks', 'wp-rich-text', 'wp-server-side-render', 'wp-url', 'wp-viewport'), 'version' => 'acfc7c34cdfa2d860d7d94012f56d5a3');
|
build/block-library/index.js
CHANGED
@@ -15,7 +15,7 @@ Object(Ee.__)("Write citation…"),className:"wp-block-quote__citation",textAlig
|
|
15 |
/* translators: 1: the order number of the image. 2: the total number of images. */
|
16 |
Object(Ee.__)("image %1$d of %2$d in gallery"),t+1,y.length);return Object(Ce.createElement)("li",{className:"blocks-gallery-item",key:e.id||e.url},Object(Ce.createElement)(dr,{url:e.url,alt:e.alt,id:e.id,isFirstItem:0===t,isLastItem:t+1===y.length,isSelected:o&&a===t,onMoveBackward:l(t),onMoveForward:s(t),onRemove:u(t),onSelect:b(t),onDeselect:m(t),setAttributes:function(e){return d(t,e)},caption:e.caption,"aria-label":r,sizeSlug:n.sizeSlug}))}))),i,Object(Ce.createElement)(pr,{isHidden:!o&&_e.RichText.isEmpty(O),tagName:"figcaption",className:"blocks-gallery-caption",placeholder:Object(Ee.__)("Write gallery caption…"),value:O,unstableOnFocus:p,onChange:function(e){return c({caption:e})},inlineToolbar:!0,__unstableOnSplitAtEnd:function(){return g(Object(we.createBlock)("core/paragraph"))}}))};function fr(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 hr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?fr(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var vr=[{value:"post",label:Object(Ee.__)("Attachment Page")},{value:"file",label:Object(Ee.__)("Media File")},{value:"none",label:Object(Ee.__)("None")}],Or=["image"],jr=Ce.Platform.select({web:Object(Ee.__)("Drag images, upload new ones or select files from your library."),native:Object(Ee.__)("ADD MEDIA")}),yr=Ce.Platform.select({web:{},native:{type:"stepper"}});var _r=Object(et.compose)([Object(Le.withSelect)((function(e,t){var n=t.attributes.ids,r=t.isSelected,o=e("core").getMedia,c=(0,e("core/block-editor").getSettings)(),a=c.imageSizes,i=c.mediaUpload,l={};return r&&(l=Object(ke.reduce)(n,(function(e,t){if(!t)return e;var n=o(t),r=Object(ke.reduce)(a,(function(e,t){var r=Object(ke.get)(n,["sizes",t.slug,"url"]),o=Object(ke.get)(n,["media_details","sizes",t.slug,"source_url"]);return hr(hr({},e),{},je({},t.slug,r||o))}),{});return hr(hr({},e),{},je({},parseInt(t,10),r))}),{})),{imageSizes:a,mediaUpload:i,resizedImages:l}})),He.withNotices,Object(Jn.withViewportMatch)({isNarrow:"< small"})])((function(e){var t=e.attributes,n=e.className,r=e.isSelected,o=e.noticeUI,c=e.noticeOperations,a=e.mediaUpload,i=e.imageSizes,l=e.resizedImages,s=e.onFocus,u=t.columns,b=void 0===u?qn(t):u,m=t.imageCrop,d=t.images,p=t.linkTo,g=t.sizeSlug,f=Ve(Object(Ce.useState)(),2),h=f[0],v=f[1],O=Ve(Object(Ce.useState)(),2),j=O[0],y=O[1];function _(t){if(t.ids)throw new Error('The "ids" attribute should not be changed directly. It is managed automatically when "images" attribute changes');t.images&&(t=hr(hr({},t),{},{ids:Object(ke.map)(t.images,(function(e){var t=e.id;return parseInt(t,10)}))})),e.setAttributes(t)}function w(e,t){var n=Oe(d);n.splice(t,1,d[e]),n.splice(e,1,d[t]),v(t),_({images:n})}function k(e){var t=Object(ke.toString)(e.id),n=Object(ke.find)(d,{id:t}),r=n?n.caption:e.caption;if(!j)return r;var o=Object(ke.find)(j,{id:t});return o&&o.caption!==e.caption?e.caption:r}function E(e){y(e.map((function(e){return{id:Object(ke.toString)(e.id),caption:e.caption}}))),_({images:e.map((function(e){return hr(hr({},Wn(e,g)),{},{caption:k(e),id:Object(ke.toString)(e.id)})})),columns:t.columns?Math.min(e.length,t.columns):t.columns})}Object(Ce.useEffect)((function(){if("web"===Ce.Platform.OS&&d&&d.length>0&&Object(ke.every)(d,(function(e){var t=e.url;return Object(Xe.isBlobURL)(t)}))){var e=Object(ke.map)(d,(function(e){var t=e.url;return Object(Xe.getBlobByURL)(t)}));Object(ke.forEach)(d,(function(e){var t=e.url;return Object(Xe.revokeBlobURL)(t)})),a({filesList:e,onFileChange:E,allowedTypes:["image"]})}}),[]),Object(Ce.useEffect)((function(){r||v()}),[r]),Object(Ce.useEffect)((function(){var e,t,n,r,o,c;p||_({linkTo:(null===(e=window)||void 0===e||null===(t=e.wp)||void 0===t||null===(n=t.media)||void 0===n||null===(r=n.view)||void 0===r||null===(o=r.settings)||void 0===o||null===(c=o.defaultProps)||void 0===c?void 0:c.link)||"none"})}),[p]);var C=!!d.length,x=Object(Ce.createElement)(_e.MediaPlaceholder,{addToGallery:C,isAppender:C,className:n,disableMediaButtons:C&&!r,icon:!C&&Qn,labels:{title:!C&&Object(Ee.__)("Gallery"),instructions:!C&&jr},onSelect:E,accept:"image/*",allowedTypes:Or,multiple:!0,value:d,onError:function(e){c.removeAllNotices(),c.createErrorNotice(e)},notices:C?void 0:o,onFocus:s});if(!C)return x;var S=Object(ke.map)(Object(ke.filter)(i,(function(e){var t=e.slug;return Object(ke.some)(l,(function(e){return e[t]}))})),(function(e){var t=e.name;return{value:e.slug,label:t}})),P=C&&!Object(ke.isEmpty)(S);return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Gallery settings")},d.length>1&&Object(Ce.createElement)(He.RangeControl,Ae({label:Object(Ee.__)("Columns"),value:b,onChange:function(e){_({columns:e})},min:1,max:Math.min(8,d.length)},yr,{required:!0})),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Crop images"),checked:!!m,onChange:function(){_({imageCrop:!m})},help:function(e){return e?Object(Ee.__)("Thumbnails are cropped to align."):Object(Ee.__)("Thumbnails are not cropped.")}}),Object(Ce.createElement)(He.SelectControl,{label:Object(Ee.__)("Link to"),value:p,onChange:function(e){_({linkTo:e})},options:vr}),P&&Object(Ce.createElement)(He.SelectControl,{label:Object(Ee.__)("Image size"),value:g,options:S,onChange:function(e){_({images:Object(ke.map)(d,(function(t){if(!t.id)return t;var n=Object(ke.get)(l,[parseInt(t.id,10),e]);return hr(hr({},t),n&&{url:n})})),newSizeSlug:e})}}))),o,Object(Ce.createElement)(gr,Ae({},e,{selectedImage:h,mediaPlaceholder:x,onMoveBackward:function(e){return function(){0!==e&&w(e,e-1)}},onMoveForward:function(e){return function(){e!==d.length-1&&w(e,e+1)}},onRemoveImage:function(e){return function(){var n=Object(ke.filter)(d,(function(t,n){return e!==n}));v(),_({images:n,columns:t.columns?Math.min(n.length,t.columns):t.columns})}},onSelectImage:function(e){return function(){v(e)}},onDeselectImage:function(){return function(){v()}},onSetImageAttributes:function(e,t){d[e]&&_({images:[].concat(Oe(d.slice(0,e)),[hr(hr({},d[e]),t)],Oe(d.slice(e+1)))})},onFocusGalleryCaption:function(){v()}})))}));var wr=function(e){return e?e.split(",").map((function(e){return parseInt(e,10)})):[]},kr={from:[{type:"block",isMultiBlock:!0,blocks:["core/image"],transform:function(e){var t=e[0],n=t.align,r=t.sizeSlug;n=Object(ke.every)(e,["align",n])?n:void 0,r=Object(ke.every)(e,["sizeSlug",r])?r:void 0;var o=Object(ke.filter)(e,(function(e){return e.url}));return Object(we.createBlock)("core/gallery",{images:o.map((function(e){var t=e.id,n=e.url,r=e.alt,o=e.caption;return{id:Object(ke.toString)(t),url:n,alt:r,caption:o}})),ids:o.map((function(e){var t=e.id;return parseInt(t,10)})),align:n,sizeSlug:r})}},{type:"shortcode",tag:"gallery",attributes:{images:{type:"array",shortcode:function(e){var t=e.named.ids;return wr(t).map((function(e){return{id:Object(ke.toString)(e)}}))}},ids:{type:"array",shortcode:function(e){var t=e.named.ids;return wr(t)}},columns:{type:"number",shortcode:function(e){var t=e.named.columns;return parseInt(void 0===t?"3":t,10)}},linkTo:{type:"string",shortcode:function(e){var t=e.named.link;return void 0===t?"post":t}}},isMatch:function(e){return void 0!==e.named.ids}},{type:"files",isMatch:function(e){return 1!==e.length&&Object(ke.every)(e,(function(e){return 0===e.type.indexOf("image/")}))},transform:function(e){return Object(we.createBlock)("core/gallery",{images:e.map((function(e){return Wn({url:Object(Xe.createBlobURL)(e)})}))})}}],to:[{type:"block",blocks:["core/image"],transform:function(e){var t=e.images,n=e.align,r=e.sizeSlug,o=e.ids;return t.length>0?t.map((function(e,t){var c=e.url,a=e.alt,i=e.caption;return Object(we.createBlock)("core/image",{id:o[t],url:c,alt:a,caption:i,align:n,sizeSlug:r})})):Object(we.createBlock)("core/image",{align:n})}}]},Er={name:"core/gallery",category:"media",attributes:{images:{type:"array",default:[],source:"query",selector:".blocks-gallery-item",query:{url:{type:"string",source:"attribute",selector:"img",attribute:"src"},fullUrl:{type:"string",source:"attribute",selector:"img",attribute:"data-full-url"},link:{type:"string",source:"attribute",selector:"img",attribute:"data-link"},alt:{type:"string",source:"attribute",selector:"img",attribute:"alt",default:""},id:{type:"string",source:"attribute",selector:"img",attribute:"data-id"},caption:{type:"string",source:"html",selector:".blocks-gallery-item__caption"}}},ids:{type:"array",items:{type:"number"},default:[]},columns:{type:"number",minimum:1,maximum:8},caption:{type:"string",source:"html",selector:".blocks-gallery-caption"},imageCrop:{type:"boolean",default:!0},linkTo:{type:"string"},sizeSlug:{type:"string",default:"large"}},supports:{anchor:!0,align:!0}},Cr=Er.name,xr={title:Object(Ee.__)("Gallery"),description:Object(Ee.__)("Display multiple images in a rich gallery."),icon:Un,keywords:[Object(Ee.__)("images"),Object(Ee.__)("photos")],example:{attributes:{columns:2,images:[{url:"https://s.w.org/images/core/5.3/Glacial_lakes%2C_Bhutan.jpg"},{url:"https://s.w.org/images/core/5.3/Sediment_off_the_Yucatan_Peninsula.jpg"}]}},transforms:kr,edit:_r,save:function(e){var t=e.attributes,n=t.images,r=t.columns,o=void 0===r?qn(t):r,c=t.imageCrop,a=t.caption,i=t.linkTo;return Object(Ce.createElement)("figure",{className:"columns-".concat(o," ").concat(c?"is-cropped":"")},Object(Ce.createElement)("ul",{className:"blocks-gallery-grid"},n.map((function(e){var t;switch(i){case"file":t=e.fullUrl||e.url;break;case"post":t=e.link}var n=Object(Ce.createElement)("img",{src:e.url,alt:""!==e.alt?e.alt:e.caption,"data-id":e.id,"data-full-url":e.fullUrl,"data-link":e.link,className:e.id?"wp-image-".concat(e.id):null});return Object(Ce.createElement)("li",{key:e.id||e.url,className:"blocks-gallery-item"},Object(Ce.createElement)("figure",null,t?Object(Ce.createElement)("a",{href:t},n):n,!_e.RichText.isEmpty(e.caption)&&Object(Ce.createElement)(_e.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-item__caption",value:e.caption})))}))),!_e.RichText.isEmpty(a)&&Object(Ce.createElement)(_e.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-caption",value:a}))},deprecated:$n},Sr=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 6.2h-5.9l-.6-1.1c-.3-.7-1-1.1-1.8-1.1H5c-1.1 0-2 .9-2 2v11.8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V8.2c0-1.1-.9-2-2-2zm.5 11.6c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h5.8c.2 0 .4.1.4.3l1 2H19c.3 0 .5.2.5.5v9.5zM8 12.8h8v-1.5H8v1.5zm0 3h8v-1.5H8v1.5z"})),Pr=n(90),Tr=n.n(Pr);var Br={apiVersion:2,name:"core/archives",category:"widgets",attributes:{displayAsDropdown:{type:"boolean",default:!1},showPostCounts:{type:"boolean",default:!1}},supports:{align:!0,html:!1}},zr=Br.name,Nr={title:Object(Ee.__)("Archives"),description:Object(Ee.__)("Display a monthly archive of your posts."),icon:Sr,example:{},edit:function(e){var t=e.attributes,n=e.setAttributes,r=t.showPostCounts,o=t.displayAsDropdown;return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Archives settings")},Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Display as dropdown"),checked:o,onChange:function(){return n({displayAsDropdown:!o})}}),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Show post counts"),checked:r,onChange:function(){return n({showPostCounts:!r})}}))),Object(Ce.createElement)("div",Object(_e.useBlockProps)(),Object(Ce.createElement)(He.Disabled,null,Object(Ce.createElement)(Tr.a,{block:"core/archives",attributes:t}))))}},Ir=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M17.7 4.3c-1.2 0-2.8 0-3.8 1-.6.6-.9 1.5-.9 2.6V14c-.6-.6-1.5-1-2.5-1C8.6 13 7 14.6 7 16.5S8.6 20 10.5 20c1.5 0 2.8-1 3.3-2.3.5-.8.7-1.8.7-2.5V7.9c0-.7.2-1.2.5-1.6.6-.6 1.8-.6 2.8-.6h.3V4.3h-.4z"})),Mr=[{attributes:{src:{type:"string",source:"attribute",selector:"audio",attribute:"src"},caption:{type:"string",source:"html",selector:"figcaption"},id:{type:"number"},autoplay:{type:"boolean",source:"attribute",selector:"audio",attribute:"autoplay"},loop:{type:"boolean",source:"attribute",selector:"audio",attribute:"loop"},preload:{type:"string",source:"attribute",selector:"audio",attribute:"preload"}},supports:{align:!0},save:function(e){var t=e.attributes,n=t.autoplay,r=t.caption,o=t.loop,c=t.preload,a=t.src;return Object(Ce.createElement)("figure",null,Object(Ce.createElement)("audio",{controls:"controls",src:a,autoPlay:n,loop:o,preload:c}),!_e.RichText.isEmpty(r)&&Object(Ce.createElement)(_e.RichText.Content,{tagName:"figcaption",value:r}))}}],Rr=["audio"];var Ar=Object(He.withNotices)((function(e){var t=e.attributes,n=e.noticeOperations,r=e.setAttributes,o=e.onReplace,c=e.isSelected,a=e.noticeUI,i=e.insertBlocksAfter,l=t.id,s=t.autoplay,u=t.caption,b=t.loop,m=t.preload,d=t.src,p=Object(_e.useBlockProps)(),g=Object(Le.useSelect)((function(e){return(0,e("core/block-editor").getSettings)().mediaUpload}),[]);function f(e){return function(t){r(je({},e,t))}}function h(e){if(e!==d){var t=dt({attributes:{url:e}});if(void 0!==t)return void o(t);r({src:e,id:void 0})}}function v(e){n.removeAllNotices(),n.createErrorNotice(e)}function O(e){e&&e.url?r({src:e.url,id:e.id}):r({src:void 0,id:void 0})}return Object(Ce.useEffect)((function(){if(!l&&Object(Xe.isBlobURL)(d)){var e=Object(Xe.getBlobByURL)(d);e&&g({filesList:[e],onFileChange:function(e){var t=Ve(e,1)[0],n=t.id,o=t.url;r({id:n,src:o})},onError:function(e){r({src:void 0,id:void 0}),n.createErrorNotice(e)},allowedTypes:Rr})}}),[]),d?Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.BlockControls,null,Object(Ce.createElement)(_e.MediaReplaceFlow,{mediaId:l,mediaURL:d,allowedTypes:Rr,accept:"audio/*",onSelect:O,onSelectURL:h,onError:v})),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Audio settings")},Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Autoplay"),onChange:f("autoplay"),checked:s,help:function(e){return e?Object(Ee.__)("Note: Autoplaying audio may cause usability issues for some visitors."):null}}),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Loop"),onChange:f("loop"),checked:b}),Object(Ce.createElement)(He.SelectControl,{label:Object(Ee.__)("Preload"),value:m||"",onChange:function(e){return r({preload:e||void 0})},options:[{value:"",label:Object(Ee.__)("Browser default")},{value:"auto",label:Object(Ee.__)("Auto")},{value:"metadata",label:Object(Ee.__)("Metadata")},{value:"none",label:Object(Ee.__)("None")}]}))),Object(Ce.createElement)("figure",p,Object(Ce.createElement)(He.Disabled,null,Object(Ce.createElement)("audio",{controls:"controls",src:d})),(!_e.RichText.isEmpty(u)||c)&&Object(Ce.createElement)(_e.RichText,{tagName:"figcaption",placeholder:Object(Ee.__)("Write caption…"),value:u,onChange:function(e){return r({caption:e})},inlineToolbar:!0,__unstableOnSplitAtEnd:function(){return i(Object(we.createBlock)("core/paragraph"))}}))):Object(Ce.createElement)("div",p,Object(Ce.createElement)(_e.MediaPlaceholder,{icon:Object(Ce.createElement)(_e.BlockIcon,{icon:Ir}),onSelect:O,onSelectURL:h,accept:"audio/*",allowedTypes:Rr,value:t,notices:a,onError:v}))}));var Vr={from:[{type:"files",isMatch:function(e){return 1===e.length&&0===e[0].type.indexOf("audio/")},transform:function(e){var t=e[0];return Object(we.createBlock)("core/audio",{src:Object(Xe.createBlobURL)(t)})}},{type:"shortcode",tag:"audio",attributes:{src:{type:"string",shortcode:function(e){var t=e.named,n=t.src,r=t.mp3,o=t.m4a,c=t.ogg,a=t.wav,i=t.wma;return n||r||o||c||a||i}},loop:{type:"string",shortcode:function(e){return e.named.loop}},autoplay:{type:"string",shortcode:function(e){return e.named.autoplay}},preload:{type:"string",shortcode:function(e){return e.named.preload}}}}]},Hr={apiVersion:2,name:"core/audio",category:"media",attributes:{src:{type:"string",source:"attribute",selector:"audio",attribute:"src"},caption:{type:"string",source:"html",selector:"figcaption"},id:{type:"number"},autoplay:{type:"boolean",source:"attribute",selector:"audio",attribute:"autoplay"},loop:{type:"boolean",source:"attribute",selector:"audio",attribute:"loop"},preload:{type:"string",source:"attribute",selector:"audio",attribute:"preload"}},supports:{anchor:!0,align:!0}},Lr=Hr.name,Dr={title:Object(Ee.__)("Audio"),description:Object(Ee.__)("Embed a simple audio player."),keywords:[Object(Ee.__)("music"),Object(Ee.__)("sound"),Object(Ee.__)("podcast"),Object(Ee.__)("recording")],icon:Ir,transforms:Vr,deprecated:Mr,edit:Ar,save:function(e){var t=e.attributes,n=t.autoplay,r=t.caption,o=t.loop,c=t.preload,a=t.src;return a&&Object(Ce.createElement)("figure",_e.useBlockProps.save(),Object(Ce.createElement)("audio",{controls:"controls",src:a,autoPlay:n,loop:o,preload:c}),!_e.RichText.isEmpty(r)&&Object(Ce.createElement)(_e.RichText.Content,{tagName:"figcaption",value:r}))}},Fr=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 6.5H5c-1.1 0-2 .9-2 2v7c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-7c0-1.1-.9-2-2-2zm.5 9c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5v-7c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v7zM8 13h8v-1.5H8V13z"})),Gr={from:[{type:"block",isMultiBlock:!0,blocks:["core/button"],transform:function(e){return Object(we.createBlock)("core/buttons",{},e.map((function(e){return Object(we.createBlock)("core/button",e)})))}}]};function Ur(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 qr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ur(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ur(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Wr=function(e){if(!e.customTextColor&&!e.customBackgroundColor&&!e.customGradient)return e;var t={color:{}};return e.customTextColor&&(t.color.text=e.customTextColor),e.customBackgroundColor&&(t.color.background=e.customBackgroundColor),e.customGradient&&(t.color.gradient=e.customGradient),qr(qr({},Object(ke.omit)(e,["customTextColor","customBackgroundColor","customGradient"])),{},{style:t})},Zr=function(e){return Wr(Object(ke.omit)(qr(qr({},e),{},{customTextColor:e.textColor&&"#"===e.textColor[0]?e.textColor:void 0,customBackgroundColor:e.color&&"#"===e.color[0]?e.color:void 0}),["color","textColor"]))},Kr={url:{type:"string",source:"attribute",selector:"a",attribute:"href"},title:{type:"string",source:"attribute",selector:"a",attribute:"title"},text:{type:"string",source:"html",selector:"a"}},$r=[{supports:{align:!0,alignWide:!1,color:{gradients:!0}},attributes:qr(qr({},Kr),{},{linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"},style:{type:"object"}}),save:function(e){var t=e.attributes,n=t.borderRadius,r=t.linkTarget,o=t.rel,c=t.text,a=t.title,i=t.url,l=Te()("wp-block-button__link",{"no-border-radius":0===n}),s={borderRadius:n?n+"px":void 0};return Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:l,href:i,title:a,style:s,value:c,target:r,rel:o})}},{supports:{align:!0,alignWide:!1},attributes:qr(qr({},Kr),{},{linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},customGradient:{type:"string"},gradient:{type:"string"}}),isEligible:function(e){return!!e.customTextColor||!!e.customBackgroundColor||!!e.customGradient},migrate:Wr,save:function(e){var t,n=e.attributes,r=n.backgroundColor,o=n.borderRadius,c=n.customBackgroundColor,a=n.customTextColor,i=n.customGradient,l=n.linkTarget,s=n.gradient,u=n.rel,b=n.text,m=n.textColor,d=n.title,p=n.url,g=Object(_e.getColorClassName)("color",m),f=!i&&Object(_e.getColorClassName)("background-color",r),h=Object(_e.__experimentalGetGradientClass)(s),v=Te()("wp-block-button__link",(je(t={"has-text-color":m||a},g,g),je(t,"has-background",r||c||i||s),je(t,f,f),je(t,"no-border-radius",0===o),je(t,h,h),t)),O={background:i||void 0,backgroundColor:f||i||s?void 0:c,color:g?void 0:a,borderRadius:o?o+"px":void 0};return Object(Ce.createElement)("div",null,Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:v,href:p,title:d,style:O,value:b,target:l,rel:u}))}},{attributes:qr(qr({},Kr),{},{align:{type:"string",default:"none"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"}}),isEligible:function(e){return e.className&&e.className.includes("is-style-squared")},migrate:function(e){var t=e.className;return t&&(t=t.replace(/is-style-squared[\s]?/,"").trim()),Wr(qr(qr({},e),{},{className:t||void 0,borderRadius:0}))},save:function(e){var t,n=e.attributes,r=n.backgroundColor,o=n.customBackgroundColor,c=n.customTextColor,a=n.linkTarget,i=n.rel,l=n.text,s=n.textColor,u=n.title,b=n.url,m=Object(_e.getColorClassName)("color",s),d=Object(_e.getColorClassName)("background-color",r),p=Te()("wp-block-button__link",(je(t={"has-text-color":s||c},m,m),je(t,"has-background",r||o),je(t,d,d),t)),g={backgroundColor:d?void 0:o,color:m?void 0:c};return Object(Ce.createElement)("div",null,Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:p,href:b,title:u,style:g,value:l,target:a,rel:i}))}},{attributes:qr(qr({},Kr),{},{align:{type:"string",default:"none"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"}}),migrate:Zr,save:function(e){var t,n=e.attributes,r=n.url,o=n.text,c=n.title,a=n.backgroundColor,i=n.textColor,l=n.customBackgroundColor,s=n.customTextColor,u=Object(_e.getColorClassName)("color",i),b=Object(_e.getColorClassName)("background-color",a),m=Te()("wp-block-button__link",(je(t={"has-text-color":i||s},u,u),je(t,"has-background",a||l),je(t,b,b),t)),d={backgroundColor:b?void 0:l,color:u?void 0:s};return Object(Ce.createElement)("div",null,Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:m,href:r,title:c,style:d,value:o}))}},{attributes:qr(qr({},Kr),{},{color:{type:"string"},textColor:{type:"string"},align:{type:"string",default:"none"}}),save:function(e){var t=e.attributes,n=t.url,r=t.text,o=t.title,c=t.align,a={backgroundColor:t.color,color:t.textColor};return Object(Ce.createElement)("div",{className:"align".concat(c)},Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:"wp-block-button__link",href:n,title:o,style:a,value:r}))},migrate:Zr},{attributes:qr(qr({},Kr),{},{color:{type:"string"},textColor:{type:"string"},align:{type:"string",default:"none"}}),save:function(e){var t=e.attributes,n=t.url,r=t.text,o=t.title,c=t.align,a=t.color,i=t.textColor;return Object(Ce.createElement)("div",{className:"align".concat(c),style:{backgroundColor:a}},Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",href:n,title:o,style:{color:i},value:r}))},migrate:Zr}],Jr=n(192),Qr=n(219);function Yr(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 Xr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yr(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var eo=[],to="web"===Ce.Platform.OS;function no(e){return e.ownerDocument.defaultView.getComputedStyle(e)}var ro=function e(t){if(!Object(ke.isObject)(t))return t;var n=Object(ke.pickBy)(Object(ke.mapValues)(t,e),ke.identity);return Object(ke.isEqual)(n,{})?void 0:n};function oo(e){var t=e.settings,n=e.clientId,r=e.enableContrastChecking,o=void 0===r||r,c=Ve(Object(Ce.useState)(),2),a=c[0],i=c[1],l=Ve(Object(Ce.useState)(),2),s=l[0],u=l[1],b=to?Object(Ee.__)("Color settings"):Object(Ee.__)("Color Settings");return Object(Ce.useEffect)((function(){if(!to||o){var e=function(e){return document.getElementById("block-"+e)}(n);if(e){u(no(e).color);for(var t=e,r=no(t).backgroundColor;"rgba(0, 0, 0, 0)"===r&&t.parentNode&&t.parentNode.nodeType===t.parentNode.ELEMENT_NODE;)r=no(t=t.parentNode).backgroundColor;i(r)}}})),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(_e.__experimentalPanelColorGradientSettings,{title:b,initialOpen:!1,settings:t},to&&o&&Object(Ce.createElement)(_e.ContrastChecker,{backgroundColor:a,textColor:s})))}var co=function(e){var t,n,r,o=e.attributes,c=Object(_e.__experimentalUseEditorFeature)("color.palette")||eo,a=Object(_e.__experimentalUseEditorFeature)("color.gradients")||eo,i=Object(Ce.useRef)(o);Object(Ce.useEffect)((function(){i.current=o}),[o]);var l,s,u=o.style,b=o.textColor,m=o.backgroundColor,d=o.gradient;l=d?Object(_e.getGradientValueBySlug)(a,d):null==u||null===(s=u.color)||void 0===s?void 0:s.gradient;var p=function(t){return function(n){var r,o,a=Object(_e.getColorObjectByColorValue)(c,n),l=t+"Color",s=Xr(Xr({},i.current.style),{},{color:Xr(Xr({},null===(r=i.current)||void 0===r||null===(o=r.style)||void 0===o?void 0:o.color),{},je({},t,(null==a?void 0:a.slug)?void 0:n))}),u=(null==a?void 0:a.slug)?a.slug:void 0,b=je({style:ro(s)},l,u);e.setAttributes(b),i.current=Xr(Xr({},i.current),b)}};return Object(Ce.createElement)(oo,{enableContrastChecking:!d&&!(null==u||null===(t=u.color)||void 0===t?void 0:t.gradient),clientId:e.clientId,settings:[{label:Object(Ee.__)("Text Color"),onColorChange:p("text"),colorValue:Object(_e.getColorObjectByAttributeValues)(c,b,null==u||null===(n=u.color)||void 0===n?void 0:n.text).color},{label:Object(Ee.__)("Background Color"),onColorChange:p("background"),colorValue:Object(_e.getColorObjectByAttributeValues)(c,m,null==u||null===(r=u.color)||void 0===r?void 0:r.background).color,gradientValue:l,onGradientChange:function(t){var n,r=Object(_e.getGradientSlugByValue)(a,t);if(r){var o,c,l,s=Xr(Xr({},null===(o=i.current)||void 0===o?void 0:o.style),{},{color:Xr(Xr({},null===(c=i.current)||void 0===c||null===(l=c.style)||void 0===l?void 0:l.color),{},{gradient:void 0})});n={style:ro(s),gradient:r}}else{var u,b,m,d=Xr(Xr({},null===(u=i.current)||void 0===u?void 0:u.style),{},{color:Xr(Xr({},null===(b=i.current)||void 0===b||null===(m=b.style)||void 0===m?void 0:m.color),{},{gradient:t})});n={style:ro(d),gradient:void 0}}e.setAttributes(n),i.current=Xr(Xr({},i.current),n)}}]})};function ao(e,t){var n,r,o,c,a,i,l,s,u,b,m,d=arguments.length>2&&void 0!==arguments[2]&&arguments[2],p=e.backgroundColor,g=e.textColor,f=e.gradient,h=e.style,v=Object(_e.getColorClassName)("background-color",p),O=Object(_e.__experimentalGetGradientClass)(f),j=Object(_e.getColorClassName)("color",g),y=Te()(j,O,(je(a={},v,!(null==h||null===(n=h.color)||void 0===n?void 0:n.gradient)&&!!v),je(a,"has-text-color",g||(null==h||null===(r=h.color)||void 0===r?void 0:r.text)),je(a,"has-background",p||(null==h||null===(o=h.color)||void 0===o?void 0:o.background)||f||(null==h||null===(c=h.color)||void 0===c?void 0:c.gradient)),a)),_=(null==h||null===(i=h.color)||void 0===i?void 0:i.background)||(null==h||null===(l=h.color)||void 0===l?void 0:l.text)||(null==h||null===(s=h.color)||void 0===s?void 0:s.gradient)?{background:(null==h||null===(u=h.color)||void 0===u?void 0:u.gradient)?h.color.gradient:void 0,backgroundColor:(null==h||null===(b=h.color)||void 0===b?void 0:b.background)?h.color.background:void 0,color:(null==h||null===(m=h.color)||void 0===m?void 0:m.text)?h.color.text:void 0}:{};if(d){if(p){var w=Object(_e.getColorObjectByAttributeValues)(t,p);_.backgroundColor=w.color}if(g){var k=Object(_e.getColorObjectByAttributeValues)(t,g);_.color=k.color}}return{className:y||void 0,style:_}}function io(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 lo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?io(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):io(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var so=[];function uo(e){var t=e.borderRadius,n=void 0===t?"":t,r=e.setAttributes,o=n,c=Object(Ce.useCallback)((function(e){r(void 0===e?{borderRadius:o}:{borderRadius:e})}),[r]);return Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Border settings")},Object(Ce.createElement)(He.RangeControl,{value:n,label:Object(Ee.__)("Border radius"),min:0,max:50,initialPosition:5,allowReset:!0,onChange:c}))}function bo(e){var t,n=e.isSelected,r=e.url,o=e.setAttributes,c=e.opensInNewTab,a=e.onToggleOpenInNewTab,i=Ve(Object(Ce.useState)(!1),2),l=i[0],s=i[1],u=!!r,b=u&&n,m=function(){return s(!0),!1},d=function(){o({url:void 0,linkTarget:void 0,rel:void 0}),s(!1)},p=(l||b)&&Object(Ce.createElement)(He.Popover,{position:"bottom center",onClose:function(){return s(!1)}},Object(Ce.createElement)(_e.__experimentalLinkControl,{className:"wp-block-navigation-link__inline-link-input",value:{url:r,opensInNewTab:c},onChange:function(e){var t=e.url,n=void 0===t?"":t,r=e.opensInNewTab;o({url:n}),c!==r&&a(r)}}));return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.BlockControls,null,Object(Ce.createElement)(He.ToolbarGroup,null,!u&&Object(Ce.createElement)(He.ToolbarButton,{name:"link",icon:Jr.a,title:Object(Ee.__)("Link"),shortcut:gn.displayShortcut.primary("k"),onClick:m}),b&&Object(Ce.createElement)(He.ToolbarButton,{name:"link",icon:Qr.a,title:Object(Ee.__)("Unlink"),shortcut:gn.displayShortcut.primaryShift("k"),onClick:d,isActive:!0}))),n&&Object(Ce.createElement)(He.KeyboardShortcuts,{bindGlobal:!0,shortcuts:(t={},je(t,gn.rawShortcut.primary("k"),m),je(t,gn.rawShortcut.primaryShift("k"),d),t)}),p)}var mo=function(e){var t=e.attributes,n=e.setAttributes,r=e.className,o=e.isSelected,c=e.onReplace,a=e.mergeBlocks,i=t.borderRadius,l=t.linkTarget,s=t.placeholder,u=t.rel,b=t.text,m=t.url,d=Object(Ce.useCallback)((function(e){n({rel:e})}),[n]),p=Object(_e.__experimentalUseEditorFeature)("color.palette")||so,g=Object(Ce.useCallback)((function(e){var t=e?"_blank":void 0,r=u;t&&!u?r="noreferrer noopener":t||"noreferrer noopener"!==u||(r=void 0),n({linkTarget:t,rel:r})}),[u,n]),f=ao(t,p,!0),h=Object(_e.useBlockProps)();return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(co,e),Object(Ce.createElement)("div",h,Object(Ce.createElement)(_e.RichText,{placeholder:s||Object(Ee.__)("Add text…"),value:b,onChange:function(e){return n({text:e})},withoutInteractiveFormatting:!0,className:Te()(r,"wp-block-button__link",f.className,{"no-border-radius":0===i}),style:lo({borderRadius:i?i+"px":void 0},f.style),onSplit:function(e){return Object(we.createBlock)("core/button",lo(lo({},t),{},{text:e}))},onReplace:c,onMerge:a,identifier:"text"})),Object(Ce.createElement)(bo,{url:m,setAttributes:n,isSelected:o,opensInNewTab:"_blank"===l,onToggleOpenInNewTab:g}),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(uo,{borderRadius:i,setAttributes:n}),Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Link settings")},Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Open in new tab"),onChange:g,checked:"_blank"===l}),Object(Ce.createElement)(He.TextControl,{label:Object(Ee.__)("Link rel"),value:u||"",onChange:d}))))};function po(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 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 fo(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){je(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}var ho={apiVersion:2,name:"core/button",category:"design",parent:["core/buttons"],attributes:{url:{type:"string",source:"attribute",selector:"a",attribute:"href"},title:{type:"string",source:"attribute",selector:"a",attribute:"title"},text:{type:"string",source:"html",selector:"a"},linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},style:{type:"object"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"}},supports:{anchor:!0,align:!0,alignWide:!1,reusable:!1,__experimentalSelector:".wp-block-button > a"}},vo=ho.name,Oo={title:Object(Ee.__)("Button"),description:Object(Ee.__)("Prompt visitors to take action with a button-style link."),icon:Fr,keywords:[Object(Ee.__)("link")],example:{attributes:{className:"is-style-fill",backgroundColor:"vivid-green-cyan",text:Object(Ee.__)("Call to Action")}},styles:[{name:"fill",label:Object(Ee.__)("Fill"),isDefault:!0},{name:"outline",label:Object(Ee.__)("Outline")}],edit:mo,save:function(e){var t=e.attributes,n=t.borderRadius,r=t.linkTarget,o=t.rel,c=t.text,a=t.title,i=t.url,l=ao(t),s=Te()("wp-block-button__link",l.className,{"no-border-radius":0===n}),u=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?po(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):po(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({borderRadius:n?n+"px":void 0},l.style);return Object(Ce.createElement)("div",_e.useBlockProps.save(),Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:s,href:i,title:a,style:u,value:c,target:r,rel:o}))},deprecated:$r,merge:function(e,t){var n=t.text,r=void 0===n?"":n;return fo(fo({},e),{},{text:(e.text||"")+r})}},jo=[vo],yo=[["core/button"]],_o={isEmbedButton:!0};var wo=function(){var e=Object(_e.useBlockProps)(),t=Object(_e.__experimentalUseInnerBlocksProps)(e,{allowedBlocks:jo,template:yo,orientation:"horizontal"});return Object(Ce.createElement)(_e.__experimentalAlignmentHookSettingsProvider,{value:_o},Object(Ce.createElement)("div",t))};var ko={apiVersion:2,name:"core/buttons",category:"design",supports:{anchor:!0,align:!0,alignWide:!1}},Eo=ko.name,Co={title:Object(Ee.__)("Buttons"),description:Object(Ee.__)("Prompt visitors to take action with a group of button-style links."),icon:Fr,keywords:[Object(Ee.__)("link")],example:{innerBlocks:[{name:"core/button",attributes:{text:Object(Ee.__)("Find out more")}},{name:"core/button",attributes:{text:Object(Ee.__)("Contact us")}}]},transforms:Gr,edit:wo,save:function(){return Object(Ce.createElement)("div",_e.useBlockProps.save(),Object(Ce.createElement)(_e.InnerBlocks.Content,null))}},xo=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V7h15v12zM9 10H7v2h2v-2zm0 4H7v2h2v-2zm4-4h-2v2h2v-2zm4 0h-2v2h2v-2zm-4 4h-2v2h2v-2zm4 0h-2v2h2v-2z"})),So=n(47),Po=n.n(So);function To(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 Bo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?To(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):To(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var zo=lt()((function(e){if(!e)return{};var t=Po()(e);return{year:t.year(),month:t.month()+1}}));var No={apiVersion:2,name:"core/calendar",category:"widgets",attributes:{month:{type:"integer"},year:{type:"integer"}},supports:{align:!0}},Io=No.name,Mo={title:Object(Ee.__)("Calendar"),description:Object(Ee.__)("A calendar of your site’s posts."),icon:xo,keywords:[Object(Ee.__)("posts"),Object(Ee.__)("archive")],example:{},edit:function(e){var t=e.attributes,n=Object(Le.useSelect)((function(e){var t=e("core/editor").getEditedPostAttribute;return"post"===t("type")?t("date"):void 0}),[]);return Object(Ce.createElement)("div",Object(_e.useBlockProps)(),Object(Ce.createElement)(He.Disabled,null,Object(Ce.createElement)(Tr.a,{block:"core/calendar",attributes:Bo(Bo({},t),zo(n))})))}},Ro=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V7h15v12zM9 10H7v2h2v-2zm0 4H7v2h2v-2zm4-4h-2v2h2v-2zm4 0h-2v2h2v-2zm-4 4h-2v2h2v-2zm4 0h-2v2h2v-2z"})),Ao=Object(Ce.createElement)(xe.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(Ce.createElement)(xe.Path,{d:"M10.44 3.02l1.82-1.82 6.36 6.35-1.83 1.82c-1.05-.68-2.48-.57-3.41.36l-.75.75c-.92.93-1.04 2.35-.35 3.41l-1.83 1.82-2.41-2.41-2.8 2.79c-.42.42-3.38 2.71-3.8 2.29s1.86-3.39 2.28-3.81l2.79-2.79L4.1 9.36l1.83-1.82c1.05.69 2.48.57 3.4-.36l.75-.75c.93-.92 1.05-2.35.36-3.41z"}));var Vo={apiVersion:2,name:"core/categories",category:"widgets",attributes:{displayAsDropdown:{type:"boolean",default:!1},showHierarchy:{type:"boolean",default:!1},showPostCounts:{type:"boolean",default:!1}},supports:{align:!0,html:!1}},Ho=Vo.name,Lo={title:Object(Ee.__)("Categories"),description:Object(Ee.__)("Display a list of all categories."),icon:Ro,example:{},edit:function e(t){var n,r=t.attributes,o=r.displayAsDropdown,c=r.showHierarchy,a=r.showPostCounts,i=t.setAttributes,l=Object(et.useInstanceId)(e,"blocks-category-select"),s=Object(Le.useSelect)((function(e){var t=e("core").getEntityRecords,n=e("core/data").isResolving,r={per_page:-1,hide_empty:!0};return{categories:t("taxonomy","category",r),isRequesting:n("core","getEntityRecords",["taxonomy","category",r])}}),[]),u=s.categories,b=s.isRequesting,m=function(e){return(null==u?void 0:u.length)?null===e?u:u.filter((function(t){return t.parent===e})):[]},d=function(e){return"wp-block-categories__list wp-block-categories__list-level-".concat(e)},p=function(e){return function(t){return i(je({},e,t))}},g=function(e){return e?Object(ke.unescape)(e).trim():Object(Ee.__)("(Untitled)")},f=function e(t,n){var r=m(t.id),o=t.id,i=t.link,l=t.count,s=t.name;return Object(Ce.createElement)("li",{key:o},Object(Ce.createElement)("a",{href:i,target:"_blank",rel:"noreferrer noopener"},g(s)),a&&Object(Ce.createElement)("span",{className:"wp-block-categories__post-count"}," (".concat(l,")")),c&&!!r.length&&Object(Ce.createElement)("ul",{className:d(n+1)},r.map((function(t){return e(t,n+1)}))))},h=function e(t,n){var r=t.id,o=t.count,i=t.name,l=m(r);return[Object(Ce.createElement)("option",{key:r},Object(ke.times)(3*n,(function(){return" "})),g(i),a&&" (".concat(o,")")),c&&!!l.length&&l.map((function(t){return e(t,n+1)}))]};return Object(Ce.createElement)("div",Object(_e.useBlockProps)(),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Categories settings")},Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Display as dropdown"),checked:o,onChange:p("displayAsDropdown")}),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Show hierarchy"),checked:c,onChange:p("showHierarchy")}),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Show post counts"),checked:a,onChange:p("showPostCounts")}))),b&&Object(Ce.createElement)(He.Placeholder,{icon:Ao,label:Object(Ee.__)("Categories")},Object(Ce.createElement)(He.Spinner,null)),!b&&(o?(n=m(c?0:null),Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(He.VisuallyHidden,{as:"label",htmlFor:l},Object(Ee.__)("Categories")),Object(Ce.createElement)("select",{id:l,className:"wp-block-categories__dropdown"},n.map((function(e){return h(e,0)}))))):function(){var e=m(c?0:null);return Object(Ce.createElement)("ul",{className:d(0)},e.map((function(e){return f(e,0)})))}()))}},Do=n(301);function Fo(e){return e.replace(/\[/g,"[")}function Go(e){return e.replace(/^(\s*https?:)\/\/([^\s<>"]+\s*)$/m,"$1//$2")}var Uo={from:[{type:"enter",regExp:/^```$/,transform:function(){return Object(we.createBlock)("core/code")}},{type:"block",blocks:["core/html"],transform:function(e){var t=e.content;return Object(we.createBlock)("core/code",{content:t})}},{type:"raw",isMatch:function(e){return"PRE"===e.nodeName&&1===e.children.length&&"CODE"===e.firstChild.nodeName},schema:{pre:{children:{code:{children:{"#text":{}}}}}}}]},qo={apiVersion:2,name:"core/code",category:"text",attributes:{content:{type:"string",source:"html",selector:"code"}},supports:{anchor:!0}},Wo=qo.name,Zo={title:Object(Ee.__)("Code"),description:Object(Ee.__)("Display code snippets that respect your spacing and tabs."),icon:Do.a,example:{attributes:{
|
17 |
// translators: Preserve \n markers for line breaks
|
18 |
-
content:Object(Ee.__)('// A "block" is the abstract term used\n// to describe units of markup that\n// when composed together, form the\n// content or layout of a page.\nregisterBlockType( name, settings );')}},transforms:Uo,edit:function(e){var t=e.attributes,n=e.setAttributes,r=Object(_e.useBlockProps)();return Object(Ce.createElement)("pre",r,Object(Ce.createElement)(_e.RichText,{tagName:"code",value:t.content,onChange:function(e){return n({content:e})},placeholder:Object(Ee.__)("Write code…"),"aria-label":Object(Ee.__)("Code")}))},save:function(e){var t,n=e.attributes;return Object(Ce.createElement)("pre",_e.useBlockProps.save(),Object(Ce.createElement)(_e.RichText.Content,{tagName:"code",value:(t=n.content,Object(ke.flow)(Fo,Go)(t||""))}))}},Ko=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 6H6c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h13c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-4.1 1.5v10H10v-10h4.9zM5.5 17V8c0-.3.2-.5.5-.5h2.5v10H6c-.3 0-.5-.2-.5-.5zm14 0c0 .3-.2.5-.5.5h-2.6v-10H19c.3 0 .5.2.5.5v9z"}));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 Jo(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){je(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 Qo(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 Yo(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 Yo(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,a=!0,i=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){i=!0,c=e},f:function(){try{a||null==n.return||n.return()}finally{if(i)throw c}}}}function Yo(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 Xo(e){var t,n=Xo.doc;n||(n=document.implementation.createHTMLDocument(""),Xo.doc=n),n.body.innerHTML=e;var r,o=Qo(n.body.firstChild.classList);try{for(o.s();!(r=o.n()).done;){if(t=r.value.match(/^layout-column-(\d+)$/))return Number(t[1])-1}}catch(e){o.e(e)}finally{o.f()}}var ec=[{attributes:{verticalAlignment:{type:"string"},backgroundColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},textColor:{type:"string"}},migrate:function(e){if(!e.customTextColor&&!e.customBackgroundColor)return e;var t={color:{}};return e.customTextColor&&(t.color.text=e.customTextColor),e.customBackgroundColor&&(t.color.background=e.customBackgroundColor),Jo(Jo({},Object(ke.omit)(e,["customTextColor","customBackgroundColor"])),{},{style:t})},save:function(e){var t,n=e.attributes,r=n.verticalAlignment,o=n.backgroundColor,c=n.customBackgroundColor,a=n.textColor,i=n.customTextColor,l=Object(_e.getColorClassName)("background-color",o),s=Object(_e.getColorClassName)("color",a),u=Te()((je(t={"has-background":o||c,"has-text-color":a||i},l,l),je(t,s,s),je(t,"are-vertically-aligned-".concat(r),r),t)),b={backgroundColor:l?void 0:c,color:s?void 0:i};return Object(Ce.createElement)("div",{className:u||void 0,style:b},Object(Ce.createElement)(_e.InnerBlocks.Content,null))}},{attributes:{columns:{type:"number",default:2}},isEligible:function(e,t){return!!t.some((function(e){return/layout-column-\d+/.test(e.originalContent)}))&&t.some((function(e){return void 0!==Xo(e.originalContent)}))},migrate:function(e,t){var n=t.reduce((function(e,t){var n=Xo(t.originalContent);return void 0===n&&(n=0),e[n]||(e[n]=[]),e[n].push(t),e}),[]).map((function(e){return Object(we.createBlock)("core/column",{},e)}));return[Object(ke.omit)(e,["columns"]),n]},save:function(e){var t=e.attributes.columns;return Object(Ce.createElement)("div",{className:"has-".concat(t,"-columns")},Object(Ce.createElement)(_e.InnerBlocks.Content,null))}},{attributes:{columns:{type:"number",default:2}},migrate:function(e,t){return[e=Object(ke.omit)(e,["columns"]),t]},save:function(e){var t=e.attributes,n=t.verticalAlignment,r=t.columns,o=Te()("has-".concat(r,"-columns"),je({},"are-vertically-aligned-".concat(n),n));return Object(Ce.createElement)("div",{className:o},Object(Ce.createElement)(_e.InnerBlocks.Content,null))}}],tc=function(e){return Number.isFinite(e)?parseFloat(e.toFixed(2)):void 0};function nc(e,t){var n=e.attributes.width;return tc(void 0===n?100/t:n)}function rc(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.length;return Object(ke.sumBy)(e,(function(e){return nc(e,t)}))}function oc(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.length;return e.reduce((function(e,n){var r=nc(n,t);return Object.assign(e,je({},n.clientId,r))}),{})}function cc(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,r=rc(e,n),o=t-r,c=o/e.length;return Object(ke.mapValues)(oc(e,n),(function(e){return tc(e+c)}))}function ac(e,t){return e.map((function(e){return Object(ke.merge)({},e,{attributes:{width:t[e.clientId]}})}))}var ic=["core/column"];var lc=Object(Le.withDispatch)((function(e,t,n){return{updateAlignment:function(r){var o=t.clientId,c=t.setAttributes,a=e("core/block-editor").updateBlockAttributes,i=n.select("core/block-editor").getBlockOrder;c({verticalAlignment:r}),i(o).forEach((function(e){a(e,{verticalAlignment:r})}))},updateColumns:function(r,o){var c=t.clientId,a=e("core/block-editor").replaceInnerBlocks,i=(0,n.select("core/block-editor").getBlocks)(c),l=i.every((function(e){return Number.isFinite(e.attributes.width)})),s=o>r;if(s&&l){var u=tc(100/o),b=cc(i,100-u);i=[].concat(Oe(ac(i,b)),Oe(Object(ke.times)(o-r,(function(){return Object(we.createBlock)("core/column",{width:u})}))))}else if(s)i=[].concat(Oe(i),Oe(Object(ke.times)(o-r,(function(){return Object(we.createBlock)("core/column")}))));else{if(i=Object(ke.dropRight)(i,r-o),l)i=ac(i,cc(i,100))}a(c,i,!1)}}}))((function(e){var t=e.attributes,n=e.updateAlignment,r=e.updateColumns,o=e.clientId,c=t.verticalAlignment,a=Object(Le.useSelect)((function(e){return{count:e("core/block-editor").getBlockCount(o)}}),[o]).count,i=Te()(je({},"are-vertically-aligned-".concat(c),c)),l=Object(_e.useBlockProps)({className:i}),s=Object(_e.__experimentalUseInnerBlocksProps)(l,{allowedBlocks:ic,orientation:"horizontal",renderAppender:!1});return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.BlockControls,null,Object(Ce.createElement)(_e.BlockVerticalAlignmentToolbar,{onChange:n,value:c})),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,null,Object(Ce.createElement)(He.RangeControl,{label:Object(Ee.__)("Columns"),value:a,onChange:function(e){return r(a,e)},min:1,max:Math.max(6,a)}),a>6&&Object(Ce.createElement)(He.Notice,{status:"warning",isDismissible:!1},Object(Ee.__)("This column count exceeds the recommended amount and may cause visual breakage.")))),Object(Ce.createElement)("div",s))}));function sc(e){var t=e.clientId,n=e.name,r=e.setAttributes,o=Object(Le.useSelect)((function(e){var t=e("core/blocks"),r=t.getBlockVariations,o=t.getBlockType,c=t.getDefaultBlockVariation;return{blockType:o(n),defaultVariation:c(n,"block"),variations:r(n,"block")}}),[n]),c=o.blockType,a=o.defaultVariation,i=o.variations,l=Object(Le.useDispatch)("core/block-editor").replaceInnerBlocks,s=Object(_e.useBlockProps)();return Object(Ce.createElement)("div",s,Object(Ce.createElement)(_e.__experimentalBlockVariationPicker,{icon:Object(ke.get)(c,["icon","src"]),label:Object(ke.get)(c,["title"]),variations:i,onSelect:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:a;e.attributes&&r(e.attributes),e.innerBlocks&&l(t,Object(we.createBlocksFromInnerBlocksTemplate)(e.innerBlocks))},allowSkip:!0}))}var uc=function(e){var t=e.clientId,n=Object(Le.useSelect)((function(e){return e("core/block-editor").getBlocks(t).length>0}),[t])?lc:sc;return Object(Ce.createElement)(n,e)};var bc=[{name:"one-column-full",title:Object(Ee.__)("100"),description:Object(Ee.__)("One column"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"m39.0625 14h-30.0625v20.0938h30.0625zm-30.0625-2c-1.10457 0-2 .8954-2 2v20.0938c0 1.1045.89543 2 2 2h30.0625c1.1046 0 2-.8955 2-2v-20.0938c0-1.1046-.8954-2-2-2z"})),innerBlocks:[["core/column"]],scope:["block"]},{name:"two-columns-equal",title:Object(Ee.__)("50 / 50"),description:Object(Ee.__)("Two columns; equal split"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H25V34H39ZM23 34H9V14H23V34Z"})),isDefault:!0,innerBlocks:[["core/column"],["core/column"]],scope:["block"]},{name:"two-columns-one-third-two-thirds",title:Object(Ee.__)("30 / 70"),description:Object(Ee.__)("Two columns; one-third, two-thirds split"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H20V34H39ZM18 34H9V14H18V34Z"})),innerBlocks:[["core/column",{width:"33.33%"}],["core/column",{width:"66.66%"}]],scope:["block"]},{name:"two-columns-two-thirds-one-third",title:Object(Ee.__)("70 / 30"),description:Object(Ee.__)("Two columns; two-thirds, one-third split"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H30V34H39ZM28 34H9V14H28V34Z"})),innerBlocks:[["core/column",{width:"66.66%"}],["core/column",{width:"33.33%"}]],scope:["block"]},{name:"three-columns-equal",title:Object(Ee.__)("33 / 33 / 33"),description:Object(Ee.__)("Three columns; equal split"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",d:"M41 14a2 2 0 0 0-2-2H9a2 2 0 0 0-2 2v20a2 2 0 0 0 2 2h30a2 2 0 0 0 2-2V14zM28.5 34h-9V14h9v20zm2 0V14H39v20h-8.5zm-13 0H9V14h8.5v20z"})),innerBlocks:[["core/column"],["core/column"],["core/column"]],scope:["block"]},{name:"three-columns-wider-center",title:Object(Ee.__)("25 / 50 / 25"),description:Object(Ee.__)("Three columns; wide center column"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",d:"M41 14a2 2 0 0 0-2-2H9a2 2 0 0 0-2 2v20a2 2 0 0 0 2 2h30a2 2 0 0 0 2-2V14zM31 34H17V14h14v20zm2 0V14h6v20h-6zm-18 0H9V14h6v20z"})),innerBlocks:[["core/column",{width:"25%"}],["core/column",{width:"50%"}],["core/column",{width:"25%"}]],scope:["block"]}];function mc(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 dc(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?mc(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mc(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var pc={from:[{type:"block",isMultiBlock:!0,blocks:["*"],__experimentalConvert:function(e){var t=+(100/e.length).toFixed(2),n=e.map((function(e){var n=e.name,r=e.attributes,o=e.innerBlocks;return["core/column",{width:"".concat(t,"%")},[[n,dc({},r),o]]]}));return Object(we.createBlock)("core/columns",{},Object(we.createBlocksFromInnerBlocksTemplate)(n))},isMatch:function(e){var t=e.length;return t&&t<=6}}]},gc={apiVersion:2,name:"core/columns",category:"design",attributes:{verticalAlignment:{type:"string"}},supports:{anchor:!0,align:["wide","full"],html:!1,color:{gradients:!0,link:!0}}},fc=gc.name,hc={title:Object(Ee.__)("Columns"),icon:Ko,description:Object(Ee.__)("Add a block that displays content in multiple columns, then add whatever content blocks you’d like."),variations:bc,example:{innerBlocks:[{name:"core/column",innerBlocks:[{name:"core/paragraph",attributes:{
|
19 |
/* translators: example text. */
|
20 |
content:Object(Ee.__)("Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent et eros eu felis.")}},{name:"core/image",attributes:{url:"https://s.w.org/images/core/5.3/Windbuchencom.jpg"}},{name:"core/paragraph",attributes:{
|
21 |
/* translators: example text. */
|
15 |
/* translators: 1: the order number of the image. 2: the total number of images. */
|
16 |
Object(Ee.__)("image %1$d of %2$d in gallery"),t+1,y.length);return Object(Ce.createElement)("li",{className:"blocks-gallery-item",key:e.id||e.url},Object(Ce.createElement)(dr,{url:e.url,alt:e.alt,id:e.id,isFirstItem:0===t,isLastItem:t+1===y.length,isSelected:o&&a===t,onMoveBackward:l(t),onMoveForward:s(t),onRemove:u(t),onSelect:b(t),onDeselect:m(t),setAttributes:function(e){return d(t,e)},caption:e.caption,"aria-label":r,sizeSlug:n.sizeSlug}))}))),i,Object(Ce.createElement)(pr,{isHidden:!o&&_e.RichText.isEmpty(O),tagName:"figcaption",className:"blocks-gallery-caption",placeholder:Object(Ee.__)("Write gallery caption…"),value:O,unstableOnFocus:p,onChange:function(e){return c({caption:e})},inlineToolbar:!0,__unstableOnSplitAtEnd:function(){return g(Object(we.createBlock)("core/paragraph"))}}))};function fr(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 hr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?fr(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var vr=[{value:"post",label:Object(Ee.__)("Attachment Page")},{value:"file",label:Object(Ee.__)("Media File")},{value:"none",label:Object(Ee.__)("None")}],Or=["image"],jr=Ce.Platform.select({web:Object(Ee.__)("Drag images, upload new ones or select files from your library."),native:Object(Ee.__)("ADD MEDIA")}),yr=Ce.Platform.select({web:{},native:{type:"stepper"}});var _r=Object(et.compose)([Object(Le.withSelect)((function(e,t){var n=t.attributes.ids,r=t.isSelected,o=e("core").getMedia,c=(0,e("core/block-editor").getSettings)(),a=c.imageSizes,i=c.mediaUpload,l={};return r&&(l=Object(ke.reduce)(n,(function(e,t){if(!t)return e;var n=o(t),r=Object(ke.reduce)(a,(function(e,t){var r=Object(ke.get)(n,["sizes",t.slug,"url"]),o=Object(ke.get)(n,["media_details","sizes",t.slug,"source_url"]);return hr(hr({},e),{},je({},t.slug,r||o))}),{});return hr(hr({},e),{},je({},parseInt(t,10),r))}),{})),{imageSizes:a,mediaUpload:i,resizedImages:l}})),He.withNotices,Object(Jn.withViewportMatch)({isNarrow:"< small"})])((function(e){var t=e.attributes,n=e.className,r=e.isSelected,o=e.noticeUI,c=e.noticeOperations,a=e.mediaUpload,i=e.imageSizes,l=e.resizedImages,s=e.onFocus,u=t.columns,b=void 0===u?qn(t):u,m=t.imageCrop,d=t.images,p=t.linkTo,g=t.sizeSlug,f=Ve(Object(Ce.useState)(),2),h=f[0],v=f[1],O=Ve(Object(Ce.useState)(),2),j=O[0],y=O[1];function _(t){if(t.ids)throw new Error('The "ids" attribute should not be changed directly. It is managed automatically when "images" attribute changes');t.images&&(t=hr(hr({},t),{},{ids:Object(ke.map)(t.images,(function(e){var t=e.id;return parseInt(t,10)}))})),e.setAttributes(t)}function w(e,t){var n=Oe(d);n.splice(t,1,d[e]),n.splice(e,1,d[t]),v(t),_({images:n})}function k(e){var t=Object(ke.toString)(e.id),n=Object(ke.find)(d,{id:t}),r=n?n.caption:e.caption;if(!j)return r;var o=Object(ke.find)(j,{id:t});return o&&o.caption!==e.caption?e.caption:r}function E(e){y(e.map((function(e){return{id:Object(ke.toString)(e.id),caption:e.caption}}))),_({images:e.map((function(e){return hr(hr({},Wn(e,g)),{},{caption:k(e),id:Object(ke.toString)(e.id)})})),columns:t.columns?Math.min(e.length,t.columns):t.columns})}Object(Ce.useEffect)((function(){if("web"===Ce.Platform.OS&&d&&d.length>0&&Object(ke.every)(d,(function(e){var t=e.url;return Object(Xe.isBlobURL)(t)}))){var e=Object(ke.map)(d,(function(e){var t=e.url;return Object(Xe.getBlobByURL)(t)}));Object(ke.forEach)(d,(function(e){var t=e.url;return Object(Xe.revokeBlobURL)(t)})),a({filesList:e,onFileChange:E,allowedTypes:["image"]})}}),[]),Object(Ce.useEffect)((function(){r||v()}),[r]),Object(Ce.useEffect)((function(){var e,t,n,r,o,c;p||_({linkTo:(null===(e=window)||void 0===e||null===(t=e.wp)||void 0===t||null===(n=t.media)||void 0===n||null===(r=n.view)||void 0===r||null===(o=r.settings)||void 0===o||null===(c=o.defaultProps)||void 0===c?void 0:c.link)||"none"})}),[p]);var C=!!d.length,x=Object(Ce.createElement)(_e.MediaPlaceholder,{addToGallery:C,isAppender:C,className:n,disableMediaButtons:C&&!r,icon:!C&&Qn,labels:{title:!C&&Object(Ee.__)("Gallery"),instructions:!C&&jr},onSelect:E,accept:"image/*",allowedTypes:Or,multiple:!0,value:d,onError:function(e){c.removeAllNotices(),c.createErrorNotice(e)},notices:C?void 0:o,onFocus:s});if(!C)return x;var S=Object(ke.map)(Object(ke.filter)(i,(function(e){var t=e.slug;return Object(ke.some)(l,(function(e){return e[t]}))})),(function(e){var t=e.name;return{value:e.slug,label:t}})),P=C&&!Object(ke.isEmpty)(S);return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Gallery settings")},d.length>1&&Object(Ce.createElement)(He.RangeControl,Ae({label:Object(Ee.__)("Columns"),value:b,onChange:function(e){_({columns:e})},min:1,max:Math.min(8,d.length)},yr,{required:!0})),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Crop images"),checked:!!m,onChange:function(){_({imageCrop:!m})},help:function(e){return e?Object(Ee.__)("Thumbnails are cropped to align."):Object(Ee.__)("Thumbnails are not cropped.")}}),Object(Ce.createElement)(He.SelectControl,{label:Object(Ee.__)("Link to"),value:p,onChange:function(e){_({linkTo:e})},options:vr}),P&&Object(Ce.createElement)(He.SelectControl,{label:Object(Ee.__)("Image size"),value:g,options:S,onChange:function(e){_({images:Object(ke.map)(d,(function(t){if(!t.id)return t;var n=Object(ke.get)(l,[parseInt(t.id,10),e]);return hr(hr({},t),n&&{url:n})})),newSizeSlug:e})}}))),o,Object(Ce.createElement)(gr,Ae({},e,{selectedImage:h,mediaPlaceholder:x,onMoveBackward:function(e){return function(){0!==e&&w(e,e-1)}},onMoveForward:function(e){return function(){e!==d.length-1&&w(e,e+1)}},onRemoveImage:function(e){return function(){var n=Object(ke.filter)(d,(function(t,n){return e!==n}));v(),_({images:n,columns:t.columns?Math.min(n.length,t.columns):t.columns})}},onSelectImage:function(e){return function(){v(e)}},onDeselectImage:function(){return function(){v()}},onSetImageAttributes:function(e,t){d[e]&&_({images:[].concat(Oe(d.slice(0,e)),[hr(hr({},d[e]),t)],Oe(d.slice(e+1)))})},onFocusGalleryCaption:function(){v()}})))}));var wr=function(e){return e?e.split(",").map((function(e){return parseInt(e,10)})):[]},kr={from:[{type:"block",isMultiBlock:!0,blocks:["core/image"],transform:function(e){var t=e[0],n=t.align,r=t.sizeSlug;n=Object(ke.every)(e,["align",n])?n:void 0,r=Object(ke.every)(e,["sizeSlug",r])?r:void 0;var o=Object(ke.filter)(e,(function(e){return e.url}));return Object(we.createBlock)("core/gallery",{images:o.map((function(e){var t=e.id,n=e.url,r=e.alt,o=e.caption;return{id:Object(ke.toString)(t),url:n,alt:r,caption:o}})),ids:o.map((function(e){var t=e.id;return parseInt(t,10)})),align:n,sizeSlug:r})}},{type:"shortcode",tag:"gallery",attributes:{images:{type:"array",shortcode:function(e){var t=e.named.ids;return wr(t).map((function(e){return{id:Object(ke.toString)(e)}}))}},ids:{type:"array",shortcode:function(e){var t=e.named.ids;return wr(t)}},columns:{type:"number",shortcode:function(e){var t=e.named.columns;return parseInt(void 0===t?"3":t,10)}},linkTo:{type:"string",shortcode:function(e){var t=e.named.link;return void 0===t?"post":t}}},isMatch:function(e){return void 0!==e.named.ids}},{type:"files",isMatch:function(e){return 1!==e.length&&Object(ke.every)(e,(function(e){return 0===e.type.indexOf("image/")}))},transform:function(e){return Object(we.createBlock)("core/gallery",{images:e.map((function(e){return Wn({url:Object(Xe.createBlobURL)(e)})}))})}}],to:[{type:"block",blocks:["core/image"],transform:function(e){var t=e.images,n=e.align,r=e.sizeSlug,o=e.ids;return t.length>0?t.map((function(e,t){var c=e.url,a=e.alt,i=e.caption;return Object(we.createBlock)("core/image",{id:o[t],url:c,alt:a,caption:i,align:n,sizeSlug:r})})):Object(we.createBlock)("core/image",{align:n})}}]},Er={name:"core/gallery",category:"media",attributes:{images:{type:"array",default:[],source:"query",selector:".blocks-gallery-item",query:{url:{type:"string",source:"attribute",selector:"img",attribute:"src"},fullUrl:{type:"string",source:"attribute",selector:"img",attribute:"data-full-url"},link:{type:"string",source:"attribute",selector:"img",attribute:"data-link"},alt:{type:"string",source:"attribute",selector:"img",attribute:"alt",default:""},id:{type:"string",source:"attribute",selector:"img",attribute:"data-id"},caption:{type:"string",source:"html",selector:".blocks-gallery-item__caption"}}},ids:{type:"array",items:{type:"number"},default:[]},columns:{type:"number",minimum:1,maximum:8},caption:{type:"string",source:"html",selector:".blocks-gallery-caption"},imageCrop:{type:"boolean",default:!0},linkTo:{type:"string"},sizeSlug:{type:"string",default:"large"}},supports:{anchor:!0,align:!0}},Cr=Er.name,xr={title:Object(Ee.__)("Gallery"),description:Object(Ee.__)("Display multiple images in a rich gallery."),icon:Un,keywords:[Object(Ee.__)("images"),Object(Ee.__)("photos")],example:{attributes:{columns:2,images:[{url:"https://s.w.org/images/core/5.3/Glacial_lakes%2C_Bhutan.jpg"},{url:"https://s.w.org/images/core/5.3/Sediment_off_the_Yucatan_Peninsula.jpg"}]}},transforms:kr,edit:_r,save:function(e){var t=e.attributes,n=t.images,r=t.columns,o=void 0===r?qn(t):r,c=t.imageCrop,a=t.caption,i=t.linkTo;return Object(Ce.createElement)("figure",{className:"columns-".concat(o," ").concat(c?"is-cropped":"")},Object(Ce.createElement)("ul",{className:"blocks-gallery-grid"},n.map((function(e){var t;switch(i){case"file":t=e.fullUrl||e.url;break;case"post":t=e.link}var n=Object(Ce.createElement)("img",{src:e.url,alt:""!==e.alt?e.alt:e.caption,"data-id":e.id,"data-full-url":e.fullUrl,"data-link":e.link,className:e.id?"wp-image-".concat(e.id):null});return Object(Ce.createElement)("li",{key:e.id||e.url,className:"blocks-gallery-item"},Object(Ce.createElement)("figure",null,t?Object(Ce.createElement)("a",{href:t},n):n,!_e.RichText.isEmpty(e.caption)&&Object(Ce.createElement)(_e.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-item__caption",value:e.caption})))}))),!_e.RichText.isEmpty(a)&&Object(Ce.createElement)(_e.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-caption",value:a}))},deprecated:$n},Sr=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 6.2h-5.9l-.6-1.1c-.3-.7-1-1.1-1.8-1.1H5c-1.1 0-2 .9-2 2v11.8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V8.2c0-1.1-.9-2-2-2zm.5 11.6c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h5.8c.2 0 .4.1.4.3l1 2H19c.3 0 .5.2.5.5v9.5zM8 12.8h8v-1.5H8v1.5zm0 3h8v-1.5H8v1.5z"})),Pr=n(90),Tr=n.n(Pr);var Br={apiVersion:2,name:"core/archives",category:"widgets",attributes:{displayAsDropdown:{type:"boolean",default:!1},showPostCounts:{type:"boolean",default:!1}},supports:{align:!0,html:!1}},zr=Br.name,Nr={title:Object(Ee.__)("Archives"),description:Object(Ee.__)("Display a monthly archive of your posts."),icon:Sr,example:{},edit:function(e){var t=e.attributes,n=e.setAttributes,r=t.showPostCounts,o=t.displayAsDropdown;return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Archives settings")},Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Display as dropdown"),checked:o,onChange:function(){return n({displayAsDropdown:!o})}}),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Show post counts"),checked:r,onChange:function(){return n({showPostCounts:!r})}}))),Object(Ce.createElement)("div",Object(_e.useBlockProps)(),Object(Ce.createElement)(He.Disabled,null,Object(Ce.createElement)(Tr.a,{block:"core/archives",attributes:t}))))}},Ir=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M17.7 4.3c-1.2 0-2.8 0-3.8 1-.6.6-.9 1.5-.9 2.6V14c-.6-.6-1.5-1-2.5-1C8.6 13 7 14.6 7 16.5S8.6 20 10.5 20c1.5 0 2.8-1 3.3-2.3.5-.8.7-1.8.7-2.5V7.9c0-.7.2-1.2.5-1.6.6-.6 1.8-.6 2.8-.6h.3V4.3h-.4z"})),Mr=[{attributes:{src:{type:"string",source:"attribute",selector:"audio",attribute:"src"},caption:{type:"string",source:"html",selector:"figcaption"},id:{type:"number"},autoplay:{type:"boolean",source:"attribute",selector:"audio",attribute:"autoplay"},loop:{type:"boolean",source:"attribute",selector:"audio",attribute:"loop"},preload:{type:"string",source:"attribute",selector:"audio",attribute:"preload"}},supports:{align:!0},save:function(e){var t=e.attributes,n=t.autoplay,r=t.caption,o=t.loop,c=t.preload,a=t.src;return Object(Ce.createElement)("figure",null,Object(Ce.createElement)("audio",{controls:"controls",src:a,autoPlay:n,loop:o,preload:c}),!_e.RichText.isEmpty(r)&&Object(Ce.createElement)(_e.RichText.Content,{tagName:"figcaption",value:r}))}}],Rr=["audio"];var Ar=Object(He.withNotices)((function(e){var t=e.attributes,n=e.noticeOperations,r=e.setAttributes,o=e.onReplace,c=e.isSelected,a=e.noticeUI,i=e.insertBlocksAfter,l=t.id,s=t.autoplay,u=t.caption,b=t.loop,m=t.preload,d=t.src,p=Object(_e.useBlockProps)(),g=Object(Le.useSelect)((function(e){return(0,e("core/block-editor").getSettings)().mediaUpload}),[]);function f(e){return function(t){r(je({},e,t))}}function h(e){if(e!==d){var t=dt({attributes:{url:e}});if(void 0!==t)return void o(t);r({src:e,id:void 0})}}function v(e){n.removeAllNotices(),n.createErrorNotice(e)}function O(e){e&&e.url?r({src:e.url,id:e.id}):r({src:void 0,id:void 0})}return Object(Ce.useEffect)((function(){if(!l&&Object(Xe.isBlobURL)(d)){var e=Object(Xe.getBlobByURL)(d);e&&g({filesList:[e],onFileChange:function(e){var t=Ve(e,1)[0],n=t.id,o=t.url;r({id:n,src:o})},onError:function(e){r({src:void 0,id:void 0}),n.createErrorNotice(e)},allowedTypes:Rr})}}),[]),d?Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.BlockControls,null,Object(Ce.createElement)(_e.MediaReplaceFlow,{mediaId:l,mediaURL:d,allowedTypes:Rr,accept:"audio/*",onSelect:O,onSelectURL:h,onError:v})),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Audio settings")},Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Autoplay"),onChange:f("autoplay"),checked:s,help:function(e){return e?Object(Ee.__)("Note: Autoplaying audio may cause usability issues for some visitors."):null}}),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Loop"),onChange:f("loop"),checked:b}),Object(Ce.createElement)(He.SelectControl,{label:Object(Ee.__)("Preload"),value:m||"",onChange:function(e){return r({preload:e||void 0})},options:[{value:"",label:Object(Ee.__)("Browser default")},{value:"auto",label:Object(Ee.__)("Auto")},{value:"metadata",label:Object(Ee.__)("Metadata")},{value:"none",label:Object(Ee.__)("None")}]}))),Object(Ce.createElement)("figure",p,Object(Ce.createElement)(He.Disabled,null,Object(Ce.createElement)("audio",{controls:"controls",src:d})),(!_e.RichText.isEmpty(u)||c)&&Object(Ce.createElement)(_e.RichText,{tagName:"figcaption",placeholder:Object(Ee.__)("Write caption…"),value:u,onChange:function(e){return r({caption:e})},inlineToolbar:!0,__unstableOnSplitAtEnd:function(){return i(Object(we.createBlock)("core/paragraph"))}}))):Object(Ce.createElement)("div",p,Object(Ce.createElement)(_e.MediaPlaceholder,{icon:Object(Ce.createElement)(_e.BlockIcon,{icon:Ir}),onSelect:O,onSelectURL:h,accept:"audio/*",allowedTypes:Rr,value:t,notices:a,onError:v}))}));var Vr={from:[{type:"files",isMatch:function(e){return 1===e.length&&0===e[0].type.indexOf("audio/")},transform:function(e){var t=e[0];return Object(we.createBlock)("core/audio",{src:Object(Xe.createBlobURL)(t)})}},{type:"shortcode",tag:"audio",attributes:{src:{type:"string",shortcode:function(e){var t=e.named,n=t.src,r=t.mp3,o=t.m4a,c=t.ogg,a=t.wav,i=t.wma;return n||r||o||c||a||i}},loop:{type:"string",shortcode:function(e){return e.named.loop}},autoplay:{type:"string",shortcode:function(e){return e.named.autoplay}},preload:{type:"string",shortcode:function(e){return e.named.preload}}}}]},Hr={apiVersion:2,name:"core/audio",category:"media",attributes:{src:{type:"string",source:"attribute",selector:"audio",attribute:"src"},caption:{type:"string",source:"html",selector:"figcaption"},id:{type:"number"},autoplay:{type:"boolean",source:"attribute",selector:"audio",attribute:"autoplay"},loop:{type:"boolean",source:"attribute",selector:"audio",attribute:"loop"},preload:{type:"string",source:"attribute",selector:"audio",attribute:"preload"}},supports:{anchor:!0,align:!0}},Lr=Hr.name,Dr={title:Object(Ee.__)("Audio"),description:Object(Ee.__)("Embed a simple audio player."),keywords:[Object(Ee.__)("music"),Object(Ee.__)("sound"),Object(Ee.__)("podcast"),Object(Ee.__)("recording")],icon:Ir,transforms:Vr,deprecated:Mr,edit:Ar,save:function(e){var t=e.attributes,n=t.autoplay,r=t.caption,o=t.loop,c=t.preload,a=t.src;return a&&Object(Ce.createElement)("figure",_e.useBlockProps.save(),Object(Ce.createElement)("audio",{controls:"controls",src:a,autoPlay:n,loop:o,preload:c}),!_e.RichText.isEmpty(r)&&Object(Ce.createElement)(_e.RichText.Content,{tagName:"figcaption",value:r}))}},Fr=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 6.5H5c-1.1 0-2 .9-2 2v7c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-7c0-1.1-.9-2-2-2zm.5 9c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5v-7c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v7zM8 13h8v-1.5H8V13z"})),Gr={from:[{type:"block",isMultiBlock:!0,blocks:["core/button"],transform:function(e){return Object(we.createBlock)("core/buttons",{},e.map((function(e){return Object(we.createBlock)("core/button",e)})))}}]};function Ur(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 qr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ur(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ur(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Wr=function(e){if(!e.customTextColor&&!e.customBackgroundColor&&!e.customGradient)return e;var t={color:{}};return e.customTextColor&&(t.color.text=e.customTextColor),e.customBackgroundColor&&(t.color.background=e.customBackgroundColor),e.customGradient&&(t.color.gradient=e.customGradient),qr(qr({},Object(ke.omit)(e,["customTextColor","customBackgroundColor","customGradient"])),{},{style:t})},Zr=function(e){return Wr(Object(ke.omit)(qr(qr({},e),{},{customTextColor:e.textColor&&"#"===e.textColor[0]?e.textColor:void 0,customBackgroundColor:e.color&&"#"===e.color[0]?e.color:void 0}),["color","textColor"]))},Kr={url:{type:"string",source:"attribute",selector:"a",attribute:"href"},title:{type:"string",source:"attribute",selector:"a",attribute:"title"},text:{type:"string",source:"html",selector:"a"}},$r=[{supports:{align:!0,alignWide:!1,color:{gradients:!0}},attributes:qr(qr({},Kr),{},{linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"},style:{type:"object"}}),save:function(e){var t=e.attributes,n=t.borderRadius,r=t.linkTarget,o=t.rel,c=t.text,a=t.title,i=t.url,l=Te()("wp-block-button__link",{"no-border-radius":0===n}),s={borderRadius:n?n+"px":void 0};return Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:l,href:i,title:a,style:s,value:c,target:r,rel:o})}},{supports:{align:!0,alignWide:!1},attributes:qr(qr({},Kr),{},{linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},customGradient:{type:"string"},gradient:{type:"string"}}),isEligible:function(e){return!!e.customTextColor||!!e.customBackgroundColor||!!e.customGradient},migrate:Wr,save:function(e){var t,n=e.attributes,r=n.backgroundColor,o=n.borderRadius,c=n.customBackgroundColor,a=n.customTextColor,i=n.customGradient,l=n.linkTarget,s=n.gradient,u=n.rel,b=n.text,m=n.textColor,d=n.title,p=n.url,g=Object(_e.getColorClassName)("color",m),f=!i&&Object(_e.getColorClassName)("background-color",r),h=Object(_e.__experimentalGetGradientClass)(s),v=Te()("wp-block-button__link",(je(t={"has-text-color":m||a},g,g),je(t,"has-background",r||c||i||s),je(t,f,f),je(t,"no-border-radius",0===o),je(t,h,h),t)),O={background:i||void 0,backgroundColor:f||i||s?void 0:c,color:g?void 0:a,borderRadius:o?o+"px":void 0};return Object(Ce.createElement)("div",null,Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:v,href:p,title:d,style:O,value:b,target:l,rel:u}))}},{attributes:qr(qr({},Kr),{},{align:{type:"string",default:"none"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"}}),isEligible:function(e){return e.className&&e.className.includes("is-style-squared")},migrate:function(e){var t=e.className;return t&&(t=t.replace(/is-style-squared[\s]?/,"").trim()),Wr(qr(qr({},e),{},{className:t||void 0,borderRadius:0}))},save:function(e){var t,n=e.attributes,r=n.backgroundColor,o=n.customBackgroundColor,c=n.customTextColor,a=n.linkTarget,i=n.rel,l=n.text,s=n.textColor,u=n.title,b=n.url,m=Object(_e.getColorClassName)("color",s),d=Object(_e.getColorClassName)("background-color",r),p=Te()("wp-block-button__link",(je(t={"has-text-color":s||c},m,m),je(t,"has-background",r||o),je(t,d,d),t)),g={backgroundColor:d?void 0:o,color:m?void 0:c};return Object(Ce.createElement)("div",null,Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:p,href:b,title:u,style:g,value:l,target:a,rel:i}))}},{attributes:qr(qr({},Kr),{},{align:{type:"string",default:"none"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"}}),migrate:Zr,save:function(e){var t,n=e.attributes,r=n.url,o=n.text,c=n.title,a=n.backgroundColor,i=n.textColor,l=n.customBackgroundColor,s=n.customTextColor,u=Object(_e.getColorClassName)("color",i),b=Object(_e.getColorClassName)("background-color",a),m=Te()("wp-block-button__link",(je(t={"has-text-color":i||s},u,u),je(t,"has-background",a||l),je(t,b,b),t)),d={backgroundColor:b?void 0:l,color:u?void 0:s};return Object(Ce.createElement)("div",null,Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:m,href:r,title:c,style:d,value:o}))}},{attributes:qr(qr({},Kr),{},{color:{type:"string"},textColor:{type:"string"},align:{type:"string",default:"none"}}),save:function(e){var t=e.attributes,n=t.url,r=t.text,o=t.title,c=t.align,a={backgroundColor:t.color,color:t.textColor};return Object(Ce.createElement)("div",{className:"align".concat(c)},Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:"wp-block-button__link",href:n,title:o,style:a,value:r}))},migrate:Zr},{attributes:qr(qr({},Kr),{},{color:{type:"string"},textColor:{type:"string"},align:{type:"string",default:"none"}}),save:function(e){var t=e.attributes,n=t.url,r=t.text,o=t.title,c=t.align,a=t.color,i=t.textColor;return Object(Ce.createElement)("div",{className:"align".concat(c),style:{backgroundColor:a}},Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",href:n,title:o,style:{color:i},value:r}))},migrate:Zr}],Jr=n(192),Qr=n(219);function Yr(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 Xr(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yr(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var eo=[],to="web"===Ce.Platform.OS;function no(e){return e.ownerDocument.defaultView.getComputedStyle(e)}var ro=function e(t){if(!Object(ke.isObject)(t))return t;var n=Object(ke.pickBy)(Object(ke.mapValues)(t,e),ke.identity);return Object(ke.isEqual)(n,{})?void 0:n};function oo(e){var t=e.settings,n=e.clientId,r=e.enableContrastChecking,o=void 0===r||r,c=Ve(Object(Ce.useState)(),2),a=c[0],i=c[1],l=Ve(Object(Ce.useState)(),2),s=l[0],u=l[1],b=to?Object(Ee.__)("Color settings"):Object(Ee.__)("Color Settings");return Object(Ce.useEffect)((function(){if(!to||o){var e=function(e){return document.getElementById("block-"+e)}(n);if(e){u(no(e).color);for(var t=e,r=no(t).backgroundColor;"rgba(0, 0, 0, 0)"===r&&t.parentNode&&t.parentNode.nodeType===t.parentNode.ELEMENT_NODE;)r=no(t=t.parentNode).backgroundColor;i(r)}}})),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(_e.__experimentalPanelColorGradientSettings,{title:b,initialOpen:!1,settings:t},to&&o&&Object(Ce.createElement)(_e.ContrastChecker,{backgroundColor:a,textColor:s})))}var co=function(e){var t,n,r,o=e.attributes,c=Object(_e.__experimentalUseEditorFeature)("color.palette")||eo,a=Object(_e.__experimentalUseEditorFeature)("color.gradients")||eo,i=Object(Ce.useRef)(o);Object(Ce.useEffect)((function(){i.current=o}),[o]);var l,s,u=o.style,b=o.textColor,m=o.backgroundColor,d=o.gradient;l=d?Object(_e.getGradientValueBySlug)(a,d):null==u||null===(s=u.color)||void 0===s?void 0:s.gradient;var p=function(t){return function(n){var r,o,a=Object(_e.getColorObjectByColorValue)(c,n),l=t+"Color",s=Xr(Xr({},i.current.style),{},{color:Xr(Xr({},null===(r=i.current)||void 0===r||null===(o=r.style)||void 0===o?void 0:o.color),{},je({},t,(null==a?void 0:a.slug)?void 0:n))}),u=(null==a?void 0:a.slug)?a.slug:void 0,b=je({style:ro(s)},l,u);e.setAttributes(b),i.current=Xr(Xr({},i.current),b)}};return Object(Ce.createElement)(oo,{enableContrastChecking:!d&&!(null==u||null===(t=u.color)||void 0===t?void 0:t.gradient),clientId:e.clientId,settings:[{label:Object(Ee.__)("Text Color"),onColorChange:p("text"),colorValue:Object(_e.getColorObjectByAttributeValues)(c,b,null==u||null===(n=u.color)||void 0===n?void 0:n.text).color},{label:Object(Ee.__)("Background Color"),onColorChange:p("background"),colorValue:Object(_e.getColorObjectByAttributeValues)(c,m,null==u||null===(r=u.color)||void 0===r?void 0:r.background).color,gradientValue:l,onGradientChange:function(t){var n,r=Object(_e.getGradientSlugByValue)(a,t);if(r){var o,c,l,s=Xr(Xr({},null===(o=i.current)||void 0===o?void 0:o.style),{},{color:Xr(Xr({},null===(c=i.current)||void 0===c||null===(l=c.style)||void 0===l?void 0:l.color),{},{gradient:void 0})});n={style:ro(s),gradient:r}}else{var u,b,m,d=Xr(Xr({},null===(u=i.current)||void 0===u?void 0:u.style),{},{color:Xr(Xr({},null===(b=i.current)||void 0===b||null===(m=b.style)||void 0===m?void 0:m.color),{},{gradient:t})});n={style:ro(d),gradient:void 0}}e.setAttributes(n),i.current=Xr(Xr({},i.current),n)}}]})};function ao(e,t){var n,r,o,c,a,i,l,s,u,b,m,d=arguments.length>2&&void 0!==arguments[2]&&arguments[2],p=e.backgroundColor,g=e.textColor,f=e.gradient,h=e.style,v=Object(_e.getColorClassName)("background-color",p),O=Object(_e.__experimentalGetGradientClass)(f),j=Object(_e.getColorClassName)("color",g),y=Te()(j,O,(je(a={},v,!(null==h||null===(n=h.color)||void 0===n?void 0:n.gradient)&&!!v),je(a,"has-text-color",g||(null==h||null===(r=h.color)||void 0===r?void 0:r.text)),je(a,"has-background",p||(null==h||null===(o=h.color)||void 0===o?void 0:o.background)||f||(null==h||null===(c=h.color)||void 0===c?void 0:c.gradient)),a)),_=(null==h||null===(i=h.color)||void 0===i?void 0:i.background)||(null==h||null===(l=h.color)||void 0===l?void 0:l.text)||(null==h||null===(s=h.color)||void 0===s?void 0:s.gradient)?{background:(null==h||null===(u=h.color)||void 0===u?void 0:u.gradient)?h.color.gradient:void 0,backgroundColor:(null==h||null===(b=h.color)||void 0===b?void 0:b.background)?h.color.background:void 0,color:(null==h||null===(m=h.color)||void 0===m?void 0:m.text)?h.color.text:void 0}:{};if(d){if(p){var w=Object(_e.getColorObjectByAttributeValues)(t,p);_.backgroundColor=w.color}if(g){var k=Object(_e.getColorObjectByAttributeValues)(t,g);_.color=k.color}}return{className:y||void 0,style:_}}function io(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 lo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?io(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):io(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var so=[];function uo(e){var t=e.borderRadius,n=void 0===t?"":t,r=e.setAttributes,o=n,c=Object(Ce.useCallback)((function(e){r(void 0===e?{borderRadius:o}:{borderRadius:e})}),[r]);return Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Border settings")},Object(Ce.createElement)(He.RangeControl,{value:n,label:Object(Ee.__)("Border radius"),min:0,max:50,initialPosition:5,allowReset:!0,onChange:c}))}function bo(e){var t,n=e.isSelected,r=e.url,o=e.setAttributes,c=e.opensInNewTab,a=e.onToggleOpenInNewTab,i=Ve(Object(Ce.useState)(!1),2),l=i[0],s=i[1],u=!!r,b=u&&n,m=function(){return s(!0),!1},d=function(){o({url:void 0,linkTarget:void 0,rel:void 0}),s(!1)},p=(l||b)&&Object(Ce.createElement)(He.Popover,{position:"bottom center",onClose:function(){return s(!1)}},Object(Ce.createElement)(_e.__experimentalLinkControl,{className:"wp-block-navigation-link__inline-link-input",value:{url:r,opensInNewTab:c},onChange:function(e){var t=e.url,n=void 0===t?"":t,r=e.opensInNewTab;o({url:n}),c!==r&&a(r)}}));return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.BlockControls,null,Object(Ce.createElement)(He.ToolbarGroup,null,!u&&Object(Ce.createElement)(He.ToolbarButton,{name:"link",icon:Jr.a,title:Object(Ee.__)("Link"),shortcut:gn.displayShortcut.primary("k"),onClick:m}),b&&Object(Ce.createElement)(He.ToolbarButton,{name:"link",icon:Qr.a,title:Object(Ee.__)("Unlink"),shortcut:gn.displayShortcut.primaryShift("k"),onClick:d,isActive:!0}))),n&&Object(Ce.createElement)(He.KeyboardShortcuts,{bindGlobal:!0,shortcuts:(t={},je(t,gn.rawShortcut.primary("k"),m),je(t,gn.rawShortcut.primaryShift("k"),d),t)}),p)}var mo=function(e){var t=e.attributes,n=e.setAttributes,r=e.className,o=e.isSelected,c=e.onReplace,a=e.mergeBlocks,i=t.borderRadius,l=t.linkTarget,s=t.placeholder,u=t.rel,b=t.text,m=t.url,d=Object(Ce.useCallback)((function(e){n({rel:e})}),[n]),p=Object(_e.__experimentalUseEditorFeature)("color.palette")||so,g=Object(Ce.useCallback)((function(e){var t=e?"_blank":void 0,r=u;t&&!u?r="noreferrer noopener":t||"noreferrer noopener"!==u||(r=void 0),n({linkTarget:t,rel:r})}),[u,n]),f=ao(t,p,!0),h=Object(_e.useBlockProps)();return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(co,e),Object(Ce.createElement)("div",h,Object(Ce.createElement)(_e.RichText,{placeholder:s||Object(Ee.__)("Add text…"),value:b,onChange:function(e){return n({text:e})},withoutInteractiveFormatting:!0,className:Te()(r,"wp-block-button__link",f.className,{"no-border-radius":0===i}),style:lo({borderRadius:i?i+"px":void 0},f.style),onSplit:function(e){return Object(we.createBlock)("core/button",lo(lo({},t),{},{text:e}))},onReplace:c,onMerge:a,identifier:"text"})),Object(Ce.createElement)(bo,{url:m,setAttributes:n,isSelected:o,opensInNewTab:"_blank"===l,onToggleOpenInNewTab:g}),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(uo,{borderRadius:i,setAttributes:n}),Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Link settings")},Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Open in new tab"),onChange:g,checked:"_blank"===l}),Object(Ce.createElement)(He.TextControl,{label:Object(Ee.__)("Link rel"),value:u||"",onChange:d}))))};function po(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 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 fo(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){je(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}var ho={apiVersion:2,name:"core/button",category:"design",parent:["core/buttons"],attributes:{url:{type:"string",source:"attribute",selector:"a",attribute:"href"},title:{type:"string",source:"attribute",selector:"a",attribute:"title"},text:{type:"string",source:"html",selector:"a"},linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},style:{type:"object"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"}},supports:{anchor:!0,align:!0,alignWide:!1,reusable:!1,__experimentalSelector:".wp-block-button > a"}},vo=ho.name,Oo={title:Object(Ee.__)("Button"),description:Object(Ee.__)("Prompt visitors to take action with a button-style link."),icon:Fr,keywords:[Object(Ee.__)("link")],example:{attributes:{className:"is-style-fill",backgroundColor:"vivid-green-cyan",text:Object(Ee.__)("Call to Action")}},styles:[{name:"fill",label:Object(Ee.__)("Fill"),isDefault:!0},{name:"outline",label:Object(Ee.__)("Outline")}],edit:mo,save:function(e){var t=e.attributes,n=t.borderRadius,r=t.linkTarget,o=t.rel,c=t.text,a=t.title,i=t.url,l=ao(t),s=Te()("wp-block-button__link",l.className,{"no-border-radius":0===n}),u=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?po(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):po(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({borderRadius:n?n+"px":void 0},l.style);return Object(Ce.createElement)("div",_e.useBlockProps.save(),Object(Ce.createElement)(_e.RichText.Content,{tagName:"a",className:s,href:i,title:a,style:u,value:c,target:r,rel:o}))},deprecated:$r,merge:function(e,t){var n=t.text,r=void 0===n?"":n;return fo(fo({},e),{},{text:(e.text||"")+r})}},jo=[vo],yo=[["core/button"]],_o={isEmbedButton:!0};var wo=function(){var e=Object(_e.useBlockProps)(),t=Object(_e.__experimentalUseInnerBlocksProps)(e,{allowedBlocks:jo,template:yo,orientation:"horizontal"});return Object(Ce.createElement)(_e.__experimentalAlignmentHookSettingsProvider,{value:_o},Object(Ce.createElement)("div",t))};var ko={apiVersion:2,name:"core/buttons",category:"design",supports:{anchor:!0,align:!0,alignWide:!1}},Eo=ko.name,Co={title:Object(Ee.__)("Buttons"),description:Object(Ee.__)("Prompt visitors to take action with a group of button-style links."),icon:Fr,keywords:[Object(Ee.__)("link")],example:{innerBlocks:[{name:"core/button",attributes:{text:Object(Ee.__)("Find out more")}},{name:"core/button",attributes:{text:Object(Ee.__)("Contact us")}}]},transforms:Gr,edit:wo,save:function(){return Object(Ce.createElement)("div",_e.useBlockProps.save(),Object(Ce.createElement)(_e.InnerBlocks.Content,null))}},xo=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V7h15v12zM9 10H7v2h2v-2zm0 4H7v2h2v-2zm4-4h-2v2h2v-2zm4 0h-2v2h2v-2zm-4 4h-2v2h2v-2zm4 0h-2v2h2v-2z"})),So=n(47),Po=n.n(So);function To(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 Bo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?To(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):To(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var zo=lt()((function(e){if(!e)return{};var t=Po()(e);return{year:t.year(),month:t.month()+1}}));var No={apiVersion:2,name:"core/calendar",category:"widgets",attributes:{month:{type:"integer"},year:{type:"integer"}},supports:{align:!0}},Io=No.name,Mo={title:Object(Ee.__)("Calendar"),description:Object(Ee.__)("A calendar of your site’s posts."),icon:xo,keywords:[Object(Ee.__)("posts"),Object(Ee.__)("archive")],example:{},edit:function(e){var t=e.attributes,n=Object(Le.useSelect)((function(e){var t=e("core/editor").getEditedPostAttribute;return"post"===t("type")?t("date"):void 0}),[]);return Object(Ce.createElement)("div",Object(_e.useBlockProps)(),Object(Ce.createElement)(He.Disabled,null,Object(Ce.createElement)(Tr.a,{block:"core/calendar",attributes:Bo(Bo({},t),zo(n))})))}},Ro=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V7h15v12zM9 10H7v2h2v-2zm0 4H7v2h2v-2zm4-4h-2v2h2v-2zm4 0h-2v2h2v-2zm-4 4h-2v2h2v-2zm4 0h-2v2h2v-2z"})),Ao=Object(Ce.createElement)(xe.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(Ce.createElement)(xe.Path,{d:"M10.44 3.02l1.82-1.82 6.36 6.35-1.83 1.82c-1.05-.68-2.48-.57-3.41.36l-.75.75c-.92.93-1.04 2.35-.35 3.41l-1.83 1.82-2.41-2.41-2.8 2.79c-.42.42-3.38 2.71-3.8 2.29s1.86-3.39 2.28-3.81l2.79-2.79L4.1 9.36l1.83-1.82c1.05.69 2.48.57 3.4-.36l.75-.75c.93-.92 1.05-2.35.36-3.41z"}));var Vo={apiVersion:2,name:"core/categories",category:"widgets",attributes:{displayAsDropdown:{type:"boolean",default:!1},showHierarchy:{type:"boolean",default:!1},showPostCounts:{type:"boolean",default:!1}},supports:{align:!0,html:!1}},Ho=Vo.name,Lo={title:Object(Ee.__)("Categories"),description:Object(Ee.__)("Display a list of all categories."),icon:Ro,example:{},edit:function e(t){var n,r=t.attributes,o=r.displayAsDropdown,c=r.showHierarchy,a=r.showPostCounts,i=t.setAttributes,l=Object(et.useInstanceId)(e,"blocks-category-select"),s=Object(Le.useSelect)((function(e){var t=e("core").getEntityRecords,n=e("core/data").isResolving,r={per_page:-1,hide_empty:!0};return{categories:t("taxonomy","category",r),isRequesting:n("core","getEntityRecords",["taxonomy","category",r])}}),[]),u=s.categories,b=s.isRequesting,m=function(e){return(null==u?void 0:u.length)?null===e?u:u.filter((function(t){return t.parent===e})):[]},d=function(e){return"wp-block-categories__list wp-block-categories__list-level-".concat(e)},p=function(e){return function(t){return i(je({},e,t))}},g=function(e){return e?Object(ke.unescape)(e).trim():Object(Ee.__)("(Untitled)")},f=function e(t,n){var r=m(t.id),o=t.id,i=t.link,l=t.count,s=t.name;return Object(Ce.createElement)("li",{key:o},Object(Ce.createElement)("a",{href:i,target:"_blank",rel:"noreferrer noopener"},g(s)),a&&Object(Ce.createElement)("span",{className:"wp-block-categories__post-count"}," (".concat(l,")")),c&&!!r.length&&Object(Ce.createElement)("ul",{className:d(n+1)},r.map((function(t){return e(t,n+1)}))))},h=function e(t,n){var r=t.id,o=t.count,i=t.name,l=m(r);return[Object(Ce.createElement)("option",{key:r},Object(ke.times)(3*n,(function(){return" "})),g(i),a&&" (".concat(o,")")),c&&!!l.length&&l.map((function(t){return e(t,n+1)}))]};return Object(Ce.createElement)("div",Object(_e.useBlockProps)(),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,{title:Object(Ee.__)("Categories settings")},Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Display as dropdown"),checked:o,onChange:p("displayAsDropdown")}),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Show hierarchy"),checked:c,onChange:p("showHierarchy")}),Object(Ce.createElement)(He.ToggleControl,{label:Object(Ee.__)("Show post counts"),checked:a,onChange:p("showPostCounts")}))),b&&Object(Ce.createElement)(He.Placeholder,{icon:Ao,label:Object(Ee.__)("Categories")},Object(Ce.createElement)(He.Spinner,null)),!b&&(o?(n=m(c?0:null),Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(He.VisuallyHidden,{as:"label",htmlFor:l},Object(Ee.__)("Categories")),Object(Ce.createElement)("select",{id:l,className:"wp-block-categories__dropdown"},n.map((function(e){return h(e,0)}))))):function(){var e=m(c?0:null);return Object(Ce.createElement)("ul",{className:d(0)},e.map((function(e){return f(e,0)})))}()))}},Do=n(301);function Fo(e){return e.replace(/\[/g,"[")}function Go(e){return e.replace(/^(\s*https?:)\/\/([^\s<>"]+\s*)$/m,"$1//$2")}var Uo={from:[{type:"enter",regExp:/^```$/,transform:function(){return Object(we.createBlock)("core/code")}},{type:"block",blocks:["core/html"],transform:function(e){var t=e.content;return Object(we.createBlock)("core/code",{content:t})}},{type:"raw",isMatch:function(e){return"PRE"===e.nodeName&&1===e.children.length&&"CODE"===e.firstChild.nodeName},schema:{pre:{children:{code:{children:{"#text":{}}}}}}}]},qo={apiVersion:2,name:"core/code",category:"text",attributes:{content:{type:"string",source:"html",selector:"code"}},supports:{anchor:!0}},Wo=qo.name,Zo={title:Object(Ee.__)("Code"),description:Object(Ee.__)("Display code snippets that respect your spacing and tabs."),icon:Do.a,example:{attributes:{
|
17 |
// translators: Preserve \n markers for line breaks
|
18 |
+
content:Object(Ee.__)('// A "block" is the abstract term used\n// to describe units of markup that\n// when composed together, form the\n// content or layout of a page.\nregisterBlockType( name, settings );')}},transforms:Uo,edit:function(e){var t=e.attributes,n=e.setAttributes,r=Object(_e.useBlockProps)();return Object(Ce.createElement)("pre",r,Object(Ce.createElement)(_e.RichText,{tagName:"code",value:t.content,onChange:function(e){return n({content:e})},placeholder:Object(Ee.__)("Write code…"),"aria-label":Object(Ee.__)("Code"),preserveWhiteSpace:!0}))},save:function(e){var t,n=e.attributes;return Object(Ce.createElement)("pre",_e.useBlockProps.save(),Object(Ce.createElement)(_e.RichText.Content,{tagName:"code",value:(t=n.content,Object(ke.flow)(Fo,Go)(t||""))}))}},Ko=Object(Ce.createElement)(xe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(xe.Path,{d:"M19 6H6c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h13c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-4.1 1.5v10H10v-10h4.9zM5.5 17V8c0-.3.2-.5.5-.5h2.5v10H6c-.3 0-.5-.2-.5-.5zm14 0c0 .3-.2.5-.5.5h-2.6v-10H19c.3 0 .5.2.5.5v9z"}));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 Jo(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){je(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 Qo(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 Yo(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 Yo(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,a=!0,i=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){i=!0,c=e},f:function(){try{a||null==n.return||n.return()}finally{if(i)throw c}}}}function Yo(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 Xo(e){var t,n=Xo.doc;n||(n=document.implementation.createHTMLDocument(""),Xo.doc=n),n.body.innerHTML=e;var r,o=Qo(n.body.firstChild.classList);try{for(o.s();!(r=o.n()).done;){if(t=r.value.match(/^layout-column-(\d+)$/))return Number(t[1])-1}}catch(e){o.e(e)}finally{o.f()}}var ec=[{attributes:{verticalAlignment:{type:"string"},backgroundColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},textColor:{type:"string"}},migrate:function(e){if(!e.customTextColor&&!e.customBackgroundColor)return e;var t={color:{}};return e.customTextColor&&(t.color.text=e.customTextColor),e.customBackgroundColor&&(t.color.background=e.customBackgroundColor),Jo(Jo({},Object(ke.omit)(e,["customTextColor","customBackgroundColor"])),{},{style:t})},save:function(e){var t,n=e.attributes,r=n.verticalAlignment,o=n.backgroundColor,c=n.customBackgroundColor,a=n.textColor,i=n.customTextColor,l=Object(_e.getColorClassName)("background-color",o),s=Object(_e.getColorClassName)("color",a),u=Te()((je(t={"has-background":o||c,"has-text-color":a||i},l,l),je(t,s,s),je(t,"are-vertically-aligned-".concat(r),r),t)),b={backgroundColor:l?void 0:c,color:s?void 0:i};return Object(Ce.createElement)("div",{className:u||void 0,style:b},Object(Ce.createElement)(_e.InnerBlocks.Content,null))}},{attributes:{columns:{type:"number",default:2}},isEligible:function(e,t){return!!t.some((function(e){return/layout-column-\d+/.test(e.originalContent)}))&&t.some((function(e){return void 0!==Xo(e.originalContent)}))},migrate:function(e,t){var n=t.reduce((function(e,t){var n=Xo(t.originalContent);return void 0===n&&(n=0),e[n]||(e[n]=[]),e[n].push(t),e}),[]).map((function(e){return Object(we.createBlock)("core/column",{},e)}));return[Object(ke.omit)(e,["columns"]),n]},save:function(e){var t=e.attributes.columns;return Object(Ce.createElement)("div",{className:"has-".concat(t,"-columns")},Object(Ce.createElement)(_e.InnerBlocks.Content,null))}},{attributes:{columns:{type:"number",default:2}},migrate:function(e,t){return[e=Object(ke.omit)(e,["columns"]),t]},save:function(e){var t=e.attributes,n=t.verticalAlignment,r=t.columns,o=Te()("has-".concat(r,"-columns"),je({},"are-vertically-aligned-".concat(n),n));return Object(Ce.createElement)("div",{className:o},Object(Ce.createElement)(_e.InnerBlocks.Content,null))}}],tc=function(e){return Number.isFinite(e)?parseFloat(e.toFixed(2)):void 0};function nc(e,t){var n=e.attributes.width;return tc(void 0===n?100/t:n)}function rc(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.length;return Object(ke.sumBy)(e,(function(e){return nc(e,t)}))}function oc(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.length;return e.reduce((function(e,n){var r=nc(n,t);return Object.assign(e,je({},n.clientId,r))}),{})}function cc(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,r=rc(e,n),o=t-r,c=o/e.length;return Object(ke.mapValues)(oc(e,n),(function(e){return tc(e+c)}))}function ac(e,t){return e.map((function(e){return Object(ke.merge)({},e,{attributes:{width:t[e.clientId]}})}))}var ic=["core/column"];var lc=Object(Le.withDispatch)((function(e,t,n){return{updateAlignment:function(r){var o=t.clientId,c=t.setAttributes,a=e("core/block-editor").updateBlockAttributes,i=n.select("core/block-editor").getBlockOrder;c({verticalAlignment:r}),i(o).forEach((function(e){a(e,{verticalAlignment:r})}))},updateColumns:function(r,o){var c=t.clientId,a=e("core/block-editor").replaceInnerBlocks,i=(0,n.select("core/block-editor").getBlocks)(c),l=i.every((function(e){return Number.isFinite(e.attributes.width)})),s=o>r;if(s&&l){var u=tc(100/o),b=cc(i,100-u);i=[].concat(Oe(ac(i,b)),Oe(Object(ke.times)(o-r,(function(){return Object(we.createBlock)("core/column",{width:u})}))))}else if(s)i=[].concat(Oe(i),Oe(Object(ke.times)(o-r,(function(){return Object(we.createBlock)("core/column")}))));else{if(i=Object(ke.dropRight)(i,r-o),l)i=ac(i,cc(i,100))}a(c,i,!1)}}}))((function(e){var t=e.attributes,n=e.updateAlignment,r=e.updateColumns,o=e.clientId,c=t.verticalAlignment,a=Object(Le.useSelect)((function(e){return{count:e("core/block-editor").getBlockCount(o)}}),[o]).count,i=Te()(je({},"are-vertically-aligned-".concat(c),c)),l=Object(_e.useBlockProps)({className:i}),s=Object(_e.__experimentalUseInnerBlocksProps)(l,{allowedBlocks:ic,orientation:"horizontal",renderAppender:!1});return Object(Ce.createElement)(Ce.Fragment,null,Object(Ce.createElement)(_e.BlockControls,null,Object(Ce.createElement)(_e.BlockVerticalAlignmentToolbar,{onChange:n,value:c})),Object(Ce.createElement)(_e.InspectorControls,null,Object(Ce.createElement)(He.PanelBody,null,Object(Ce.createElement)(He.RangeControl,{label:Object(Ee.__)("Columns"),value:a,onChange:function(e){return r(a,e)},min:1,max:Math.max(6,a)}),a>6&&Object(Ce.createElement)(He.Notice,{status:"warning",isDismissible:!1},Object(Ee.__)("This column count exceeds the recommended amount and may cause visual breakage.")))),Object(Ce.createElement)("div",s))}));function sc(e){var t=e.clientId,n=e.name,r=e.setAttributes,o=Object(Le.useSelect)((function(e){var t=e("core/blocks"),r=t.getBlockVariations,o=t.getBlockType,c=t.getDefaultBlockVariation;return{blockType:o(n),defaultVariation:c(n,"block"),variations:r(n,"block")}}),[n]),c=o.blockType,a=o.defaultVariation,i=o.variations,l=Object(Le.useDispatch)("core/block-editor").replaceInnerBlocks,s=Object(_e.useBlockProps)();return Object(Ce.createElement)("div",s,Object(Ce.createElement)(_e.__experimentalBlockVariationPicker,{icon:Object(ke.get)(c,["icon","src"]),label:Object(ke.get)(c,["title"]),variations:i,onSelect:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:a;e.attributes&&r(e.attributes),e.innerBlocks&&l(t,Object(we.createBlocksFromInnerBlocksTemplate)(e.innerBlocks))},allowSkip:!0}))}var uc=function(e){var t=e.clientId,n=Object(Le.useSelect)((function(e){return e("core/block-editor").getBlocks(t).length>0}),[t])?lc:sc;return Object(Ce.createElement)(n,e)};var bc=[{name:"one-column-full",title:Object(Ee.__)("100"),description:Object(Ee.__)("One column"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"m39.0625 14h-30.0625v20.0938h30.0625zm-30.0625-2c-1.10457 0-2 .8954-2 2v20.0938c0 1.1045.89543 2 2 2h30.0625c1.1046 0 2-.8955 2-2v-20.0938c0-1.1046-.8954-2-2-2z"})),innerBlocks:[["core/column"]],scope:["block"]},{name:"two-columns-equal",title:Object(Ee.__)("50 / 50"),description:Object(Ee.__)("Two columns; equal split"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H25V34H39ZM23 34H9V14H23V34Z"})),isDefault:!0,innerBlocks:[["core/column"],["core/column"]],scope:["block"]},{name:"two-columns-one-third-two-thirds",title:Object(Ee.__)("30 / 70"),description:Object(Ee.__)("Two columns; one-third, two-thirds split"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H20V34H39ZM18 34H9V14H18V34Z"})),innerBlocks:[["core/column",{width:"33.33%"}],["core/column",{width:"66.66%"}]],scope:["block"]},{name:"two-columns-two-thirds-one-third",title:Object(Ee.__)("70 / 30"),description:Object(Ee.__)("Two columns; two-thirds, one-third split"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H30V34H39ZM28 34H9V14H28V34Z"})),innerBlocks:[["core/column",{width:"66.66%"}],["core/column",{width:"33.33%"}]],scope:["block"]},{name:"three-columns-equal",title:Object(Ee.__)("33 / 33 / 33"),description:Object(Ee.__)("Three columns; equal split"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",d:"M41 14a2 2 0 0 0-2-2H9a2 2 0 0 0-2 2v20a2 2 0 0 0 2 2h30a2 2 0 0 0 2-2V14zM28.5 34h-9V14h9v20zm2 0V14H39v20h-8.5zm-13 0H9V14h8.5v20z"})),innerBlocks:[["core/column"],["core/column"],["core/column"]],scope:["block"]},{name:"three-columns-wider-center",title:Object(Ee.__)("25 / 50 / 25"),description:Object(Ee.__)("Three columns; wide center column"),icon:Object(Ce.createElement)(He.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(Ce.createElement)(He.Path,{fillRule:"evenodd",d:"M41 14a2 2 0 0 0-2-2H9a2 2 0 0 0-2 2v20a2 2 0 0 0 2 2h30a2 2 0 0 0 2-2V14zM31 34H17V14h14v20zm2 0V14h6v20h-6zm-18 0H9V14h6v20z"})),innerBlocks:[["core/column",{width:"25%"}],["core/column",{width:"50%"}],["core/column",{width:"25%"}]],scope:["block"]}];function mc(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 dc(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?mc(Object(n),!0).forEach((function(t){je(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mc(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var pc={from:[{type:"block",isMultiBlock:!0,blocks:["*"],__experimentalConvert:function(e){var t=+(100/e.length).toFixed(2),n=e.map((function(e){var n=e.name,r=e.attributes,o=e.innerBlocks;return["core/column",{width:"".concat(t,"%")},[[n,dc({},r),o]]]}));return Object(we.createBlock)("core/columns",{},Object(we.createBlocksFromInnerBlocksTemplate)(n))},isMatch:function(e){var t=e.length;return t&&t<=6}}]},gc={apiVersion:2,name:"core/columns",category:"design",attributes:{verticalAlignment:{type:"string"}},supports:{anchor:!0,align:["wide","full"],html:!1,color:{gradients:!0,link:!0}}},fc=gc.name,hc={title:Object(Ee.__)("Columns"),icon:Ko,description:Object(Ee.__)("Add a block that displays content in multiple columns, then add whatever content blocks you’d like."),variations:bc,example:{innerBlocks:[{name:"core/column",innerBlocks:[{name:"core/paragraph",attributes:{
|
19 |
/* translators: example text. */
|
20 |
content:Object(Ee.__)("Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent et eros eu felis.")}},{name:"core/image",attributes:{url:"https://s.w.org/images/core/5.3/Windbuchencom.jpg"}},{name:"core/paragraph",attributes:{
|
21 |
/* translators: example text. */
|
build/blocks/index.asset.php
CHANGED
@@ -1 +1 @@
|
|
1 |
-
<?php return array('dependencies' => array('lodash', 'wp-autop', 'wp-blob', 'wp-block-serialization-default-parser', 'wp-compose', 'wp-data', 'wp-deprecated', 'wp-dom', 'wp-element', 'wp-hooks', 'wp-html-entities', 'wp-i18n', 'wp-is-shallow-equal', 'wp-polyfill', 'wp-primitives', 'wp-shortcode'), 'version' => '
|
1 |
+
<?php return array('dependencies' => array('lodash', 'wp-autop', 'wp-blob', 'wp-block-serialization-default-parser', 'wp-compose', 'wp-data', 'wp-deprecated', 'wp-dom', 'wp-element', 'wp-hooks', 'wp-html-entities', 'wp-i18n', 'wp-is-shallow-equal', 'wp-polyfill', 'wp-primitives', 'wp-shortcode'), 'version' => 'c8e8f699f604ff1628eaf1863098f07a');
|
build/blocks/index.js
CHANGED
@@ -10,4 +10,4 @@ Object(d.__)("%1$s Block. Column %2$d"),a,r):s?Object(d.sprintf)(
|
|
10 |
/* translators: accessibility text. %1: The block title. %2: The block label. */
|
11 |
Object(d.__)("%1$s Block. %2$s"),a,o):Object(d.sprintf)(
|
12 |
/* translators: accessibility text. %s: The block title. */
|
13 |
-
Object(d.__)("%s Block"),a)}var ke=["attributes","supports","save","migrate","isEligible","apiVersion"],Oe={"--wp--style--color--link":["color","link"],background:["color","gradient"],backgroundColor:["color","background"],color:["color","text"],fontSize:["typography","fontSize"],lineHeight:["typography","lineHeight"],paddingBottom:["spacing","padding","bottom"],paddingLeft:["spacing","padding","left"],paddingRight:["spacing","padding","right"],paddingTop:["spacing","padding","top"]};function je(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ce(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?je(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):je(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var xe={common:"text",formatting:"text",layout:"design"},Te={};function Pe(e){Te=Ce(Ce({},Te),e)}function Se(e,t){if(t=Ce(Ce({name:e,icon:ce.a,keywords:[],attributes:{},providesContext:{},usesContext:[],supports:{},styles:[],save:function(){return null}},Object(f.pickBy)(Object(f.get)(Te,e,{}),(function(e){return!Object(f.isNil)(e)}))),t),"string"==typeof e)if(/^[a-z][a-z0-9-]*\/[a-z][a-z0-9-]*$/.test(e))if(Object(o.select)("core/blocks").getBlockType(e))console.error('Block "'+e+'" is already registered.');else{var r=Ce({},t);if((t=Object(se.applyFilters)("blocks.registerBlockType",t,e)).deprecated&&(t.deprecated=t.deprecated.map((function(t){return Object(f.pick)(Object(se.applyFilters)("blocks.registerBlockType",Ce(Ce({},Object(f.omit)(r,ke)),t),e),ke)}))),Object(f.isPlainObject)(t))if(Object(f.isFunction)(t.save))if(!("edit"in t)||Object(f.isFunction)(t.edit))if(xe.hasOwnProperty(t.category)&&(t.category=xe[t.category]),"category"in t&&!Object(f.some)(Object(o.select)("core/blocks").getCategories(),{slug:t.category})&&(console.warn('The block "'+e+'" is registered with an invalid category "'+t.category+'".'),delete t.category),"title"in t&&""!==t.title)if("string"==typeof t.title){if(t.icon=_e(t.icon),me(t.icon.src))return Object(o.dispatch)("core/blocks").addBlockTypes(t),t;console.error("The icon passed is invalid. The icon should be a string, an element, a function, or an object following the specifications documented in https://developer.wordpress.org/block-editor/developers/block-api/block-registration/#icon-optional")}else console.error("Block titles must be strings.");else console.error('The block "'+e+'" must have a title.');else console.error('The "edit" property must be a valid function.');else console.error('The "save" property must be a valid function.');else console.error("Block settings must be a valid object.")}else console.error("Block names must contain a namespace prefix, include only lowercase alphanumeric characters or dashes, and start with a letter. Example: my-plugin/my-custom-block");else console.error("Block names must be strings.")}function Ae(e,t){var r=t.title,n=t.icon;Object(o.dispatch)("core/blocks").addBlockCollection(e,r,n)}function Ee(e){var t=Object(o.select)("core/blocks").getBlockType(e);if(t)return Object(o.dispatch)("core/blocks").removeBlockTypes(e),t;console.error('Block "'+e+'" is not registered.')}function Be(e){Object(o.dispatch)("core/blocks").setFreeformFallbackBlockName(e)}function Ne(){return Object(o.select)("core/blocks").getFreeformFallbackBlockName()}function Le(){return Object(o.select)("core/blocks").getGroupingBlockName()}function Me(e){Object(o.dispatch)("core/blocks").setUnregisteredFallbackBlockName(e)}function ze(){return Object(o.select)("core/blocks").getUnregisteredFallbackBlockName()}function De(e){Object(o.dispatch)("core/blocks").setDefaultBlockName(e)}function He(e){Object(o.dispatch)("core/blocks").setGroupingBlockName(e)}function Ie(){return Object(o.select)("core/blocks").getDefaultBlockName()}function Ve(e){return Object(o.select)("core/blocks").getBlockType(e)}function Re(){return Object(o.select)("core/blocks").getBlockTypes()}function Fe(e,t,r){return Object(o.select)("core/blocks").getBlockSupport(e,t,r)}function $e(e,t,r){return Object(o.select)("core/blocks").hasBlockSupport(e,t,r)}function qe(e){return"core/block"===e.name}var Ue=function(e){return Object(o.select)("core/blocks").getChildBlockNames(e)},Ge=function(e){return Object(o.select)("core/blocks").hasChildBlocks(e)},Ke=function(e){return Object(o.select)("core/blocks").hasChildBlocksWithInserterSupport(e)},We=function(e,t){Object(o.dispatch)("core/blocks").addBlockStyles(e,t)},Ye=function(e,t){Object(o.dispatch)("core/blocks").removeBlockStyles(e,t)},Ze=function(e,t){return Object(o.select)("core/blocks").getBlockVariations(e,t)},Qe=function(e,t){Object(o.dispatch)("core/blocks").addBlockVariations(e,t)},Xe=function(e,t){Object(o.dispatch)("core/blocks").removeBlockVariations(e,t)};function Je(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function et(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Je(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Je(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function tt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],n=Ve(e);if(void 0===n)throw new Error("Block type '".concat(e,"' is not registered."));var a=Object(f.reduce)(n.attributes,(function(e,r,n){var a=t[n];return void 0!==a?e[n]=a:r.hasOwnProperty("default")&&(e[n]=r.default),-1!==["node","children"].indexOf(r.source)&&("string"==typeof e[n]?e[n]=[e[n]]:Array.isArray(e[n])||(e[n]=[])),e}),{}),o=Object(ie.a)();return{clientId:o,name:e,isValid:!0,attributes:a,innerBlocks:r}}function rt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e.map((function(e){var t=oe(Array.isArray(e)?e:[e.name,e.attributes,e.innerBlocks],3),r=t[0],n=t[1],a=t[2];return tt(r,n,rt(void 0===a?[]:a))}))}function nt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,n=Object(ie.a)();return et(et({},e),{},{clientId:n,attributes:et(et({},e.attributes),t),innerBlocks:r||e.innerBlocks.map((function(e){return nt(e)}))})}var at=function(e,t,r){if(Object(f.isEmpty)(r))return!1;var n=r.length>1,a=Object(f.first)(r).name;if(!(ot(e)||!n||e.isMultiBlock))return!1;if(!ot(e)&&!Object(f.every)(r,{name:a}))return!1;if(!("block"===e.type))return!1;var o=Object(f.first)(r);if(!("from"!==t||-1!==e.blocks.indexOf(o.name)||ot(e)))return!1;if(!n&&it(o.name)&&it(e.blockName))return!1;if(Object(f.isFunction)(e.isMatch)){var i=e.isMultiBlock?r.map((function(e){return e.attributes})):o.attributes;if(!e.isMatch(i))return!1}return!0},ot=function(e){return e&&"block"===e.type&&Array.isArray(e.blocks)&&e.blocks.includes("*")},it=function(e){return e===Le()};function st(e){if(Object(f.isEmpty)(e))return[];var t=function(e){if(Object(f.isEmpty)(e))return[];var t=Re();return Object(f.filter)(t,(function(t){return!!ct(lt("from",t.name),(function(t){return at(t,"from",e)}))}))}(e),r=function(e){if(Object(f.isEmpty)(e))return[];var t=lt("to",Ve(Object(f.first)(e).name).name),r=Object(f.filter)(t,(function(t){return t&&at(t,"to",e)}));return Object(f.flatMap)(r,(function(e){return e.blocks})).map((function(e){return Ve(e)}))}(e);return Object(f.uniq)([].concat(l(t),l(r)))}function ct(e,t){for(var r=Object(se.createHooks)(),n=function(n){var a=e[n];t(a)&&r.addFilter("transform","transform/"+n.toString(),(function(e){return e||a}),a.priority)},a=0;a<e.length;a++)n(a);return r.applyFilters("transform",null)}function lt(e,t){if(void 0===t)return Object(f.flatMap)(Re(),(function(t){var r=t.name;return lt(e,r)}));var r=ve(t)||{},n=r.name,a=r.transforms;return a&&Array.isArray(a[e])?a[e].map((function(e){return et(et({},e),{},{blockName:n})})):[]}function ut(e,t){var r,n=Object(f.castArray)(e),a=n.length>1,o=n[0],i=o.name,s=lt("from",t),c=ct(lt("to",i),(function(e){return"block"===e.type&&(ot(e)||-1!==e.blocks.indexOf(t))&&(!a||e.isMultiBlock)}))||ct(s,(function(e){return"block"===e.type&&(ot(e)||-1!==e.blocks.indexOf(i))&&(!a||e.isMultiBlock)}));if(!c)return null;if(r=c.isMultiBlock?Object(f.has)(c,"__experimentalConvert")?c.__experimentalConvert(n):c.transform(n.map((function(e){return e.attributes})),n.map((function(e){return e.innerBlocks}))):Object(f.has)(c,"__experimentalConvert")?c.__experimentalConvert(o):c.transform(o.attributes,o.innerBlocks),!Object(f.isObjectLike)(r))return null;if((r=Object(f.castArray)(r)).some((function(e){return!Ve(e.name)})))return null;var l=Object(f.findIndex)(r,(function(e){return e.name===t}));return l<0?null:r.map((function(t,r){var n=et(et({},t),{},{clientId:r===l?o.clientId:t.clientId});return Object(se.applyFilters)("blocks.switchToBlockType.transformedBlock",n,e)}))}var ft=function e(t,r){return tt(t,r.attributes,Object(f.map)(r.innerBlocks,(function(t){return e(t.name,t)})))};function dt(e,t){for(var r,n=t.split(".");r=n.shift();){if(!(r in e))return;e=e[r]}return e}var pt,ht=function(){return pt||(pt=document.implementation.createHTMLDocument("")),pt};function gt(e,t){if(t){if("string"==typeof e){var r=ht();r.body.innerHTML=e,e=r.body}if("function"==typeof t)return t(e);if(Object===t.constructor)return Object.keys(t).reduce((function(r,n){return r[n]=gt(e,t[n]),r}),{})}}function bt(e,t){return 1===arguments.length&&(t=e,e=void 0),function(r){var n=r;if(e&&(n=r.querySelector(e)),n)return dt(n,t)}}var mt=r(102),_t=r(269);function vt(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}var wt=/^#[xX]([A-Fa-f0-9]+)$/,yt=/^#([0-9]+)$/,kt=/^([A-Za-z0-9]+)$/,Ot=(function(){function e(e){this.named=e}e.prototype.parse=function(e){if(e){var t=e.match(wt);return t?String.fromCharCode(parseInt(t[1],16)):(t=e.match(yt))?String.fromCharCode(parseInt(t[1],10)):(t=e.match(kt))?this.named[t[1]]:void 0}}}(),/[\t\n\f ]/),jt=/[A-Za-z]/,Ct=/\r\n?/g;function xt(e){return Ot.test(e)}function Tt(e){return jt.test(e)}var Pt=function(){function e(e,t){this.delegate=e,this.entityParser=t,this.state="beforeData",this.line=-1,this.column=-1,this.input="",this.index=-1,this.tagNameBuffer="",this.states={beforeData:function(){var e=this.peek();if("<"===e)this.transitionTo("tagOpen"),this.markTagStart(),this.consume();else{if("\n"===e){var t=this.tagNameBuffer.toLowerCase();"pre"!==t&&"textarea"!==t||this.consume()}this.transitionTo("data"),this.delegate.beginData()}},data:function(){var e=this.peek();"<"===e?(this.delegate.finishData(),this.transitionTo("tagOpen"),this.markTagStart(),this.consume()):"&"===e?(this.consume(),this.delegate.appendToData(this.consumeCharRef()||"&")):(this.consume(),this.delegate.appendToData(e))},tagOpen:function(){var e=this.consume();"!"===e?this.transitionTo("markupDeclarationOpen"):"/"===e?this.transitionTo("endTagOpen"):("@"===e||":"===e||Tt(e))&&(this.transitionTo("tagName"),this.tagNameBuffer="",this.delegate.beginStartTag(),this.appendToTagName(e))},markupDeclarationOpen:function(){"-"===this.consume()&&"-"===this.input.charAt(this.index)&&(this.consume(),this.transitionTo("commentStart"),this.delegate.beginComment())},commentStart:function(){var e=this.consume();"-"===e?this.transitionTo("commentStartDash"):">"===e?(this.delegate.finishComment(),this.transitionTo("beforeData")):(this.delegate.appendToCommentData(e),this.transitionTo("comment"))},commentStartDash:function(){var e=this.consume();"-"===e?this.transitionTo("commentEnd"):">"===e?(this.delegate.finishComment(),this.transitionTo("beforeData")):(this.delegate.appendToCommentData("-"),this.transitionTo("comment"))},comment:function(){var e=this.consume();"-"===e?this.transitionTo("commentEndDash"):this.delegate.appendToCommentData(e)},commentEndDash:function(){var e=this.consume();"-"===e?this.transitionTo("commentEnd"):(this.delegate.appendToCommentData("-"+e),this.transitionTo("comment"))},commentEnd:function(){var e=this.consume();">"===e?(this.delegate.finishComment(),this.transitionTo("beforeData")):(this.delegate.appendToCommentData("--"+e),this.transitionTo("comment"))},tagName:function(){var e=this.consume();xt(e)?this.transitionTo("beforeAttributeName"):"/"===e?this.transitionTo("selfClosingStartTag"):">"===e?(this.delegate.finishTag(),this.transitionTo("beforeData")):this.appendToTagName(e)},beforeAttributeName:function(){var e=this.peek();xt(e)?this.consume():"/"===e?(this.transitionTo("selfClosingStartTag"),this.consume()):">"===e?(this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):"="===e?(this.delegate.reportSyntaxError("attribute name cannot start with equals sign"),this.transitionTo("attributeName"),this.delegate.beginAttribute(),this.consume(),this.delegate.appendToAttributeName(e)):(this.transitionTo("attributeName"),this.delegate.beginAttribute())},attributeName:function(){var e=this.peek();xt(e)?(this.transitionTo("afterAttributeName"),this.consume()):"/"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.transitionTo("selfClosingStartTag")):"="===e?(this.transitionTo("beforeAttributeValue"),this.consume()):">"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):'"'===e||"'"===e||"<"===e?(this.delegate.reportSyntaxError(e+" is not a valid character within attribute names"),this.consume(),this.delegate.appendToAttributeName(e)):(this.consume(),this.delegate.appendToAttributeName(e))},afterAttributeName:function(){var e=this.peek();xt(e)?this.consume():"/"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.transitionTo("selfClosingStartTag")):"="===e?(this.consume(),this.transitionTo("beforeAttributeValue")):">"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.transitionTo("attributeName"),this.delegate.beginAttribute(),this.consume(),this.delegate.appendToAttributeName(e))},beforeAttributeValue:function(){var e=this.peek();xt(e)?this.consume():'"'===e?(this.transitionTo("attributeValueDoubleQuoted"),this.delegate.beginAttributeValue(!0),this.consume()):"'"===e?(this.transitionTo("attributeValueSingleQuoted"),this.delegate.beginAttributeValue(!0),this.consume()):">"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):(this.transitionTo("attributeValueUnquoted"),this.delegate.beginAttributeValue(!1),this.consume(),this.delegate.appendToAttributeValue(e))},attributeValueDoubleQuoted:function(){var e=this.consume();'"'===e?(this.delegate.finishAttributeValue(),this.transitionTo("afterAttributeValueQuoted")):"&"===e?this.delegate.appendToAttributeValue(this.consumeCharRef()||"&"):this.delegate.appendToAttributeValue(e)},attributeValueSingleQuoted:function(){var e=this.consume();"'"===e?(this.delegate.finishAttributeValue(),this.transitionTo("afterAttributeValueQuoted")):"&"===e?this.delegate.appendToAttributeValue(this.consumeCharRef()||"&"):this.delegate.appendToAttributeValue(e)},attributeValueUnquoted:function(){var e=this.peek();xt(e)?(this.delegate.finishAttributeValue(),this.consume(),this.transitionTo("beforeAttributeName")):"/"===e?(this.delegate.finishAttributeValue(),this.consume(),this.transitionTo("selfClosingStartTag")):"&"===e?(this.consume(),this.delegate.appendToAttributeValue(this.consumeCharRef()||"&")):">"===e?(this.delegate.finishAttributeValue(),this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):(this.consume(),this.delegate.appendToAttributeValue(e))},afterAttributeValueQuoted:function(){var e=this.peek();xt(e)?(this.consume(),this.transitionTo("beforeAttributeName")):"/"===e?(this.consume(),this.transitionTo("selfClosingStartTag")):">"===e?(this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):this.transitionTo("beforeAttributeName")},selfClosingStartTag:function(){">"===this.peek()?(this.consume(),this.delegate.markTagAsSelfClosing(),this.delegate.finishTag(),this.transitionTo("beforeData")):this.transitionTo("beforeAttributeName")},endTagOpen:function(){var e=this.consume();("@"===e||":"===e||Tt(e))&&(this.transitionTo("tagName"),this.tagNameBuffer="",this.delegate.beginEndTag(),this.appendToTagName(e))}},this.reset()}return e.prototype.reset=function(){this.transitionTo("beforeData"),this.input="",this.index=0,this.line=1,this.column=0,this.delegate.reset()},e.prototype.transitionTo=function(e){this.state=e},e.prototype.tokenize=function(e){this.reset(),this.tokenizePart(e),this.tokenizeEOF()},e.prototype.tokenizePart=function(e){for(this.input+=function(e){return e.replace(Ct,"\n")}(e);this.index<this.input.length;){var t=this.states[this.state];if(void 0===t)throw new Error("unhandled state "+this.state);t.call(this)}},e.prototype.tokenizeEOF=function(){this.flushData()},e.prototype.flushData=function(){"data"===this.state&&(this.delegate.finishData(),this.transitionTo("beforeData"))},e.prototype.peek=function(){return this.input.charAt(this.index)},e.prototype.consume=function(){var e=this.peek();return this.index++,"\n"===e?(this.line++,this.column=0):this.column++,e},e.prototype.consumeCharRef=function(){var e=this.input.indexOf(";",this.index);if(-1!==e){var t=this.input.slice(this.index,e),r=this.entityParser.parse(t);if(r){for(var n=t.length;n;)this.consume(),n--;return this.consume(),r}}},e.prototype.markTagStart=function(){this.delegate.tagOpen()},e.prototype.appendToTagName=function(e){this.tagNameBuffer+=e,this.delegate.appendToTagName(e)},e}(),St=function(){function e(e,t){void 0===t&&(t={}),this.options=t,this.token=null,this.startLine=1,this.startColumn=0,this.tokens=[],this.tokenizer=new Pt(this,e),this._currentAttribute=void 0}return e.prototype.tokenize=function(e){return this.tokens=[],this.tokenizer.tokenize(e),this.tokens},e.prototype.tokenizePart=function(e){return this.tokens=[],this.tokenizer.tokenizePart(e),this.tokens},e.prototype.tokenizeEOF=function(){return this.tokens=[],this.tokenizer.tokenizeEOF(),this.tokens[0]},e.prototype.reset=function(){this.token=null,this.startLine=1,this.startColumn=0},e.prototype.current=function(){var e=this.token;if(null===e)throw new Error("token was unexpectedly null");if(0===arguments.length)return e;for(var t=0;t<arguments.length;t++)if(e.type===arguments[t])return e;throw new Error("token type was unexpectedly "+e.type)},e.prototype.push=function(e){this.token=e,this.tokens.push(e)},e.prototype.currentAttribute=function(){return this._currentAttribute},e.prototype.addLocInfo=function(){this.options.loc&&(this.current().loc={start:{line:this.startLine,column:this.startColumn},end:{line:this.tokenizer.line,column:this.tokenizer.column}}),this.startLine=this.tokenizer.line,this.startColumn=this.tokenizer.column},e.prototype.beginData=function(){this.push({type:"Chars",chars:""})},e.prototype.appendToData=function(e){this.current("Chars").chars+=e},e.prototype.finishData=function(){this.addLocInfo()},e.prototype.beginComment=function(){this.push({type:"Comment",chars:""})},e.prototype.appendToCommentData=function(e){this.current("Comment").chars+=e},e.prototype.finishComment=function(){this.addLocInfo()},e.prototype.tagOpen=function(){},e.prototype.beginStartTag=function(){this.push({type:"StartTag",tagName:"",attributes:[],selfClosing:!1})},e.prototype.beginEndTag=function(){this.push({type:"EndTag",tagName:""})},e.prototype.finishTag=function(){this.addLocInfo()},e.prototype.markTagAsSelfClosing=function(){this.current("StartTag").selfClosing=!0},e.prototype.appendToTagName=function(e){this.current("StartTag","EndTag").tagName+=e},e.prototype.beginAttribute=function(){this._currentAttribute=["","",!1]},e.prototype.appendToAttributeName=function(e){this.currentAttribute()[0]+=e},e.prototype.beginAttributeValue=function(e){this.currentAttribute()[2]=e},e.prototype.appendToAttributeValue=function(e){this.currentAttribute()[1]+=e},e.prototype.finishAttributeValue=function(){this.current("StartTag").attributes.push(this._currentAttribute)},e.prototype.reportSyntaxError=function(e){this.current().syntaxError=e},e}();var At=r(71);function Et(){function e(e){return function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),a=1;a<r;a++)n[a-1]=arguments[a];return e.apply(void 0,["Block validation: "+t].concat(n))}}return{error:e(console.error),warning:e(console.warn),getItems:function(){return[]}}}function Bt(){var e=[],t=Et();return{error:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];e.push({log:t.error,args:n})},warning:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];e.push({log:t.warning,args:n})},getItems:function(){return e}}}var Nt=r(73),Lt=r.n(Nt);function Mt(){return(Mt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e}).apply(this,arguments)}var zt=r(10),Dt=Object(fe.createContext)((function(){})),Ht=Dt.Consumer,It=Dt.Provider,Vt=Object(zt.createHigherOrderComponent)((function(e){return function(t){return Object(fe.createElement)(Ht,null,(function(r){return Object(fe.createElement)(e,Mt({},t,{BlockContent:r}))}))}}),"withBlockContentContext"),Rt=function(e){var t=e.children,r=e.innerBlocks;return Object(fe.createElement)(It,{value:function(){var e=Jt(r,{isInnerBlocks:!0});return Object(fe.createElement)(fe.RawHTML,null,e)}},t)};function Ft(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function $t(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ft(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ft(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function qt(e){var t="wp-block-"+e.replace(/\//,"-").replace(/^core-/,"");return Object(se.applyFilters)("blocks.getBlockDefaultClassName",t,e)}function Ut(e){var t="editor-block-list-item-"+e.replace(/\//,"-").replace(/^core-/,"");return Object(se.applyFilters)("blocks.getBlockMenuDefaultClassName",t,e)}var Gt={};function Kt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=Gt.blockType,r=Gt.attributes;return Object(se.applyFilters)("blocks.getSaveContent.extraProps",$t({},e),t,r)}function Wt(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],n=ve(e),a=n.save;if(a.prototype instanceof fe.Component){var o=new a({attributes:t});a=o.render.bind(o)}Gt.blockType=n,Gt.attributes=t;var i=a({attributes:t,innerBlocks:r});if(Object(f.isObject)(i)&&Object(se.hasFilter)("blocks.getSaveContent.extraProps")&&!n.apiVersion){var s=Object(se.applyFilters)("blocks.getSaveContent.extraProps",$t({},i.props),n,t);Lt()(s,i.props)||(i=Object(fe.cloneElement)(i,s))}return i=Object(se.applyFilters)("blocks.getSaveElement",i,n,t),Object(fe.createElement)(Rt,{innerBlocks:r},i)}function Yt(e,t,r){var n=ve(e);return Object(fe.renderToString)(Wt(n,t,r))}function Zt(e,t){return Object(f.reduce)(e.attributes,(function(e,r,n){var a=t[n];return void 0===a||void 0!==r.source||"default"in r&&r.default===a||(e[n]=a),e}),{})}function Qt(e){var t=e.originalContent;if(e.isValid||e.innerBlocks.length)try{t=Yt(e.name,e.attributes,e.innerBlocks)}catch(e){}return t}function Xt(e,t,r){var n=Object(f.isEmpty)(t)?"":function(e){return JSON.stringify(e).replace(/--/g,"\\u002d\\u002d").replace(/</g,"\\u003c").replace(/>/g,"\\u003e").replace(/&/g,"\\u0026").replace(/\\"/g,"\\u0022")}(t)+" ",a=Object(f.startsWith)(e,"core/")?e.slice(5):e;return r?"\x3c!-- wp:".concat(a," ").concat(n,"--\x3e\n")+r+"\n\x3c!-- /wp:".concat(a," --\x3e"):"\x3c!-- wp:".concat(a," ").concat(n,"/--\x3e")}function Jt(e,t){return Object(f.castArray)(e).map((function(e){return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.isInnerBlocks,n=void 0!==r&&r,a=e.name,o=Qt(e);if(a===ze()||!n&&a===Ne())return o;var i=Ve(a),s=Zt(i,e.attributes);return Xt(a,s,o)}(e,t)})).join("\n\n")}function er(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}var tr=/[\t\n\r\v\f ]+/g,rr=/^[\t\n\r\v\f ]*$/,nr=/^url\s*\(['"\s]*(.*?)['"\s]*\)$/,ar=["allowfullscreen","allowpaymentrequest","allowusermedia","async","autofocus","autoplay","checked","controls","default","defer","disabled","download","formnovalidate","hidden","ismap","itemscope","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected","typemustmatch"],or=[].concat(ar,["autocapitalize","autocomplete","charset","contenteditable","crossorigin","decoding","dir","draggable","enctype","formenctype","formmethod","http-equiv","inputmode","kind","method","preload","scope","shape","spellcheck","translate","type","wrap"]),ir=[f.identity,function(e){return fr(e).join(" ")}],sr=/^[\da-z]+$/i,cr=/^#\d+$/,lr=/^#x[\da-f]+$/i;var ur=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,r,n;return t=e,(r=[{key:"parse",value:function(e){if(t=e,sr.test(t)||cr.test(t)||lr.test(t))return Object(At.decodeEntities)("&"+e+";");var t}}])&&vt(t.prototype,r),n&&vt(t,n),e}();function fr(e){return e.trim().split(tr)}function dr(e){return e.attributes.filter((function(e){var t=oe(e,2),r=t[0];return t[1]||0===r.indexOf("data-")||Object(f.includes)(or,r)}))}function pr(e,t){for(var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et(),n=e.chars,a=t.chars,o=0;o<ir.length;o++){var i=ir[o];if((n=i(n))===(a=i(a)))return!0}return r.warning("Expected text `%s`, saw `%s`.",t.chars,e.chars),!1}function hr(e){return e.replace(nr,"url($1)")}function gr(e){var t=e.replace(/;?\s*$/,"").split(";").map((function(e){var t,r=e.split(":"),n=ne(t=r)||s(t)||c(t)||ae(),a=n[0],o=n.slice(1).join(":");return[a.trim(),hr(o.trim())]}));return Object(f.fromPairs)(t)}var br=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?er(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):er(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({class:function(e,t){return!f.xor.apply(void 0,l([e,t].map(fr))).length},style:function(e,t){return f.isEqual.apply(void 0,l([e,t].map(gr)))}},Object(f.fromPairs)(ar.map((function(e){return[e,f.stubTrue]}))));function mr(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et();if(e.length!==t.length)return r.warning("Expected attributes %o, instead saw %o.",t,e),!1;for(var n={},a=0;a<t.length;a++)n[t[a][0].toLowerCase()]=t[a][1];for(var o=0;o<e.length;o++){var i=oe(e[o],2),s=i[0],c=i[1],l=s.toLowerCase();if(!n.hasOwnProperty(l))return r.warning("Encountered unexpected attribute `%s`.",s),!1;var u=n[l],f=br[l];if(f){if(!f(c,u))return r.warning("Expected attribute `%s` of value `%s`, saw `%s`.",s,u,c),!1}else if(c!==u)return r.warning("Expected attribute `%s` of value `%s`, saw `%s`.",s,u,c),!1}return!0}var _r={StartTag:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et();return e.tagName!==t.tagName&&e.tagName.toLowerCase()!==t.tagName.toLowerCase()?(r.warning("Expected tag name `%s`, instead saw `%s`.",t.tagName,e.tagName),!1):mr.apply(void 0,l([e,t].map(dr)).concat([r]))},Chars:pr,Comment:pr};function vr(e){for(var t;t=e.shift();){if("Chars"!==t.type)return t;if(!rr.test(t.chars))return t}}function wr(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Et();try{return new St(new ur).tokenize(e)}catch(r){t.warning("Malformed HTML detected: %s",e)}return null}function yr(e,t){return!!e.selfClosing&&!(!t||t.tagName!==e.tagName||"EndTag"!==t.type)}function kr(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et();if(e===t)return!0;var n,a,o=[e,t].map((function(e){return wr(e,r)})),i=oe(o,2),s=i[0],c=i[1];if(!s||!c)return!1;for(;n=vr(s);){if(!(a=vr(c)))return r.warning("Expected end of content, instead saw %o.",n),!1;if(n.type!==a.type)return r.warning("Expected token of type `%s` (%o), instead saw `%s` (%o).",a.type,a,n.type,n),!1;var l=_r[n.type];if(l&&!l(n,a,r))return!1;yr(n,c[0])?vr(c):yr(a,s[0])&&vr(s)}return!(a=vr(c))||(r.warning("Expected %o, instead saw end of content.",a),!1)}function Or(e,t,r){var n,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:Bt(),o=ve(e);try{n=Yt(o,t)}catch(e){return a.error("Block validation failed because an error occurred while generating block content:\n\n%s",e.toString()),{isValid:!1,validationIssues:a.getItems()}}var i=kr(r,n,a);return i||a.error("Block validation failed for `%s` (%o).\n\nContent generated by `save` function:\n\n%s\n\nContent retrieved from post body:\n\n%s",o.name,o,n,r),{isValid:i,validationIssues:a.getItems()}}function jr(e,t,r){return Or(e,t,r,Et()).isValid}function Cr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function xr(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Cr(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Cr(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function Tr(e){for(var t={},r=0;r<e.length;r++){var n=e[r],a=n.name,o=n.value;t[a]=o}return t}function Pr(e){if(e.nodeType===e.TEXT_NODE)return e.nodeValue;if(e.nodeType!==e.ELEMENT_NODE)throw new TypeError("A block node can only be created from a node of type text or element.");return{type:e.nodeName.toLowerCase(),props:xr(xr({},Tr(e.attributes)),{},{children:Er(e.childNodes)})}}function Sr(e){return function(t){var r=t;e&&(r=t.querySelector(e));try{return Pr(r)}catch(e){return null}}}var Ar={isNodeOfType:function(e,t){return e&&e.type===t},fromDOM:Pr,toHTML:function(e){return Br([e])},matcher:Sr};function Er(e){for(var t=[],r=0;r<e.length;r++)try{t.push(Pr(e[r]))}catch(e){}return t}function Br(e){var t=e;return Object(fe.renderToString)(t)}function Nr(e){return function(t){var r=t;return e&&(r=t.querySelector(e)),r?Er(r.childNodes):[]}}var Lr={concat:function(){for(var e=[],t=0;t<arguments.length;t++)for(var r=Object(f.castArray)(t<0||arguments.length<=t?void 0:arguments[t]),n=0;n<r.length;n++){var a=r[n],o="string"==typeof a&&"string"==typeof e[e.length-1];o?e[e.length-1]+=a:e.push(a)}return e},getChildrenArray:function(e){return e},fromDOM:Er,toHTML:Br,matcher:Nr};function Mr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function zr(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Mr(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Mr(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}new Set(["attribute","html","text","tag"]);function Dr(e,t){return t.some((function(t){return function(e,t){switch(t){case"string":return"string"==typeof e;case"boolean":return"boolean"==typeof e;case"object":return!!e&&e.constructor===Object;case"null":return null===e;case"array":return Array.isArray(e);case"integer":case"number":return"number"==typeof e}return!0}(e,t)}))}function Hr(e){switch(e.source){case"attribute":var t=function(e,t){return 1===arguments.length&&(t=e,e=void 0),function(r){var n=bt(e,"attributes")(r);if(n&&n.hasOwnProperty(t))return n[t].value}}(e.selector,e.attribute);return"boolean"===e.type&&(t=function(e){return Object(f.flow)([e,function(e){return void 0!==e}])}(t)),t;case"html":return n=e.selector,a=e.multiline,function(e){var t=e;if(n&&(t=e.querySelector(n)),!t)return"";if(a){for(var r="",o=t.children.length,i=0;i<o;i++){var s=t.children[i];s.nodeName.toLowerCase()===a&&(r+=s.outerHTML)}return r}return t.innerHTML};case"text":return function(e){return bt(e,"textContent")}(e.selector);case"children":return Nr(e.selector);case"node":return Sr(e.selector);case"query":var r=Object(f.mapValues)(e.query,Hr);return function(e,t){return function(r){var n=r.querySelectorAll(e);return[].map.call(n,(function(e){return gt(e,t)}))}}(e.selector,r);case"tag":return Object(f.flow)([bt(e.selector,"nodeName"),function(e){return e?e.toLowerCase():void 0}]);default:console.error('Unknown source type "'.concat(e.source,'"'))}var n,a}function Ir(e,t){return gt(e,Hr(t))}function Vr(e,t,r,n){var a,o=t.type,i=t.enum;switch(t.source){case void 0:a=n?n[e]:void 0;break;case"attribute":case"property":case"html":case"text":case"children":case"node":case"query":case"tag":a=Ir(r,t)}return function(e,t){return void 0===t||Dr(e,Object(f.castArray)(t))}(a,o)&&function(e,t){return!Array.isArray(t)||t.includes(e)}(a,i)||(a=void 0),void 0===a?t.default:a}function Rr(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=ve(e),a=Object(f.mapValues)(n.attributes,(function(e,n){return Vr(n,e,t,r)}));return Object(se.applyFilters)("blocks.getBlockAttributes",a,n,t,r)}function Fr(e,t){var r=zr({},t);if("core/cover-image"===e&&(e="core/cover"),"core/text"!==e&&"core/cover-text"!==e||(e="core/paragraph"),e&&0===e.indexOf("core/social-link-")&&(r.service=e.substring(17),e="core/social-link"),e&&0===e.indexOf("core-embed/")){var n=e.substring(11),a={speaker:"speaker-deck",polldaddy:"crowdsignal"};r.providerNameSlug=n in a?a[n]:n,["amazon-kindle","wordpress"].includes(n)||(r.responsive=!0),e="core/embed"}return{name:e,attributes:r}}function $r(e){var t=e.blockName,r=e.attrs,n=e.innerBlocks,a=void 0===n?[]:n,o=e.innerHTML,i=e.innerContent,s=Ne(),c=ze()||s;r=r||{},o=o.trim();var u=t||s,d=Fr(u,r);u=d.name,r=d.attributes,u===s&&(o=Object(mt.autop)(o).trim());var p=Ve(u);if(!p){var h={attrs:r,blockName:t,innerBlocks:a,innerContent:i},g=qr(h,{isCommentDelimited:!1}),b=qr(h,{isCommentDelimited:!0});u&&(o=b),r={originalName:t,originalContent:b,originalUndelimitedContent:g},p=Ve(u=c)}a=(a=a.map($r)).filter((function(e){return e}));var m=u===s||u===c;if(p&&(o||!m)){var _=tt(u,Rr(p,o,r),a);if(!m){var v=Or(p,_.attributes,o),w=v.isValid,y=v.validationIssues;_.isValid=w,_.validationIssues=y}return _.originalContent=_.originalContent||o,(_=function(e,t){var r=Ve(e.name),n=r.deprecated;if(!n||!n.length)return e;for(var a=e,o=a.originalContent,i=a.innerBlocks,s=0;s<n.length;s++){var c=n[s].isEligible,u=void 0===c?f.stubFalse:c;if(!e.isValid||u(t,i)){var d=Object.assign(Object(f.omit)(r,ke),n[s]),p=Rr(d,o,t),h=Or(d,p,o),g=h.isValid,b=h.validationIssues;if(g){var m=i,_=d.migrate;if(_){var v=oe(Object(f.castArray)(_(p,i)),2),w=v[0];p=void 0===w?t:w;var y=v[1];m=void 0===y?i:y}e=zr(zr({},e),{},{attributes:p,innerBlocks:m,isValid:!0})}else e=zr(zr({},e),{},{validationIssues:[].concat(l(Object(f.get)(e,"validationIssues",[])),l(b))})}}return e}(_,r)).validationIssues&&_.validationIssues.length>0&&(_.isValid?console.info("Block successfully updated for `%s` (%o).\n\nNew content generated by `save` function:\n\n%s\n\nContent retrieved from post body:\n\n%s",p.name,p,Yt(p,_.attributes),_.originalContent):_.validationIssues.forEach((function(e){var t=e.log,r=e.args;return t.apply(void 0,l(r))}))),_}}function qr(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.isCommentDelimited,n=void 0===r||r,a=e.blockName,o=e.attrs,i=void 0===o?{}:o,s=e.innerBlocks,c=void 0===s?[]:s,l=e.innerContent,u=void 0===l?[]:l,f=0,d=u.map((function(e){return null!==e?e:qr(c[f++],t)})).join("\n").replace(/\n+/g,"\n").trim();return n?Xt(a,i,d):d}var Ur,Gr=(Ur=_t.parse,function(e){return Ur(e).reduce((function(e,t){var r=$r(t);return r&&e.push(r),e}),[])}),Kr=Gr;function Wr(e){var t=document.implementation.createHTMLDocument(""),r=document.implementation.createHTMLDocument(""),n=t.body,a=r.body;for(n.innerHTML=e;n.firstChild;){var o=n.firstChild;o.nodeType===o.TEXT_NODE?o.nodeValue.trim()?(a.lastChild&&"P"===a.lastChild.nodeName||a.appendChild(r.createElement("P")),a.lastChild.appendChild(o)):n.removeChild(o):o.nodeType===o.ELEMENT_NODE?"BR"===o.nodeName?(o.nextSibling&&"BR"===o.nextSibling.nodeName&&(a.appendChild(r.createElement("P")),n.removeChild(o.nextSibling)),a.lastChild&&"P"===a.lastChild.nodeName&&a.lastChild.hasChildNodes()?a.lastChild.appendChild(o):n.removeChild(o)):"P"===o.nodeName?Object(de.isEmpty)(o)?n.removeChild(o):a.appendChild(o):Object(de.isPhrasingContent)(o)?(a.lastChild&&"P"===a.lastChild.nodeName||a.appendChild(r.createElement("P")),a.lastChild.appendChild(o)):a.appendChild(o):n.removeChild(o)}return a.innerHTML}function Yr(e,t){if(e.nodeType===e.COMMENT_NODE)if("nextpage"!==e.nodeValue){if(0===e.nodeValue.indexOf("more")){for(var r=e.nodeValue.slice(4).trim(),n=e,a=!1;n=n.nextSibling;)if(n.nodeType===n.COMMENT_NODE&&"noteaser"===n.nodeValue){a=!0,Object(de.remove)(n);break}Object(de.replace)(e,function(e,t,r){var n=r.createElement("wp-block");n.dataset.block="core/more",e&&(n.dataset.customText=e);t&&(n.dataset.noTeaser="");return n}(r,a,t))}}else Object(de.replace)(e,function(e){var t=e.createElement("wp-block");return t.dataset.block="core/nextpage",t}(t))}function Zr(e){e.nodeType===e.COMMENT_NODE&&Object(de.remove)(e)}function Qr(e,t){return e.every((function(e){return function(e,t){if(Object(de.isTextContent)(e))return!0;if(!t)return!1;var r=e.nodeName.toLowerCase();return[["ul","li","ol"],["h1","h2","h3","h4","h5","h6"]].some((function(e){return 0===Object(f.difference)([r,t],e).length}))}(e,t)&&Qr(Array.from(e.children),t)}))}function Xr(e){return"BR"===e.nodeName&&e.previousSibling&&"BR"===e.previousSibling.nodeName}function Jr(e,t){if("SPAN"===e.nodeName&&e.style){var r=e.style,n=r.fontWeight,a=r.fontStyle,o=r.textDecorationLine,i=r.textDecoration,s=r.verticalAlign;"bold"!==n&&"700"!==n||Object(de.wrap)(t.createElement("strong"),e),"italic"===a&&Object(de.wrap)(t.createElement("em"),e),("line-through"===o||Object(f.includes)(i,"line-through"))&&Object(de.wrap)(t.createElement("s"),e),"super"===s?Object(de.wrap)(t.createElement("sup"),e):"sub"===s&&Object(de.wrap)(t.createElement("sub"),e)}else"B"===e.nodeName?e=Object(de.replaceTag)(e,"strong"):"I"===e.nodeName?e=Object(de.replaceTag)(e,"em"):"A"===e.nodeName&&(e.target&&"_blank"===e.target.toLowerCase()?e.rel="noreferrer noopener":(e.removeAttribute("target"),e.removeAttribute("rel")))}function en(e){"SCRIPT"!==e.nodeName&&"NOSCRIPT"!==e.nodeName&&"TEMPLATE"!==e.nodeName&&"STYLE"!==e.nodeName||e.parentNode.removeChild(e)}var tn=window.parseInt;function rn(e){return"OL"===e.nodeName||"UL"===e.nodeName}function nn(e,t){if("P"===e.nodeName){var r=e.getAttribute("style");if(r&&-1!==r.indexOf("mso-list")){var n=/mso-list\s*:[^;]+level([0-9]+)/i.exec(r);if(n){var a=tn(n[1],10)-1||0,o=e.previousElementSibling;if(!o||!rn(o)){var i=e.textContent.trim().slice(0,1),s=/[1iIaA]/.test(i),c=t.createElement(s?"ol":"ul");s&&c.setAttribute("type",i),e.parentNode.insertBefore(c,e)}var l=e.previousElementSibling,u=l.nodeName,f=t.createElement("li"),d=l;for(e.removeChild(e.firstElementChild);e.firstChild;)f.appendChild(e.firstChild);for(;a--;)rn(d=d.lastElementChild||d)&&(d=d.lastElementChild||d);rn(d)||(d=d.appendChild(t.createElement(u))),d.appendChild(f),e.parentNode.removeChild(e)}}}}function an(e){return"OL"===e.nodeName||"UL"===e.nodeName}function on(e){if(an(e)){var t=e,r=e.previousElementSibling;if(r&&r.nodeName===e.nodeName&&1===t.children.length){for(;t.firstChild;)r.appendChild(t.firstChild);t.parentNode.removeChild(t)}var n,a=e.parentNode;if(a&&"LI"===a.nodeName&&1===a.children.length&&!/\S/.test((n=a,Array.from(n.childNodes).map((function(e){var t=e.nodeValue;return void 0===t?"":t})).join("")))){var o=a,i=o.previousElementSibling,s=o.parentNode;i?(i.appendChild(t),s.removeChild(o)):(s.parentNode.insertBefore(t,s),s.parentNode.removeChild(s))}if(a&&an(a)){var c=e.previousElementSibling;c?c.appendChild(e):Object(de.unwrap)(e)}}}var sn=r(41),cn=window,ln=cn.atob,un=cn.File;function fn(e){if("IMG"===e.nodeName){if(0===e.src.indexOf("file:")&&(e.src=""),0===e.src.indexOf("data:")){var t,r=oe(e.src.split(","),2),n=r[0],a=r[1],o=oe(n.slice(5).split(";"),1)[0];if(!a||!o)return void(e.src="");try{t=ln(a)}catch(t){return void(e.src="")}for(var i=new Uint8Array(t.length),s=0;s<i.length;s++)i[s]=t.charCodeAt(s);var c=o.replace("/","."),l=new un([i],c,{type:o});e.src=Object(sn.createBlobURL)(l)}1!==e.height&&1!==e.width||e.parentNode.removeChild(e)}}function dn(e){"BLOCKQUOTE"===e.nodeName&&(e.innerHTML=Wr(e.innerHTML))}function pn(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,r=e.ownerDocument.createElement("figure");t.parentNode.insertBefore(r,t),r.appendChild(e)}function hn(e,t,r){if(function(e,t){var r=e.nodeName.toLowerCase();return"figcaption"!==r&&!Object(de.isTextContent)(e)&&Object(f.has)(t,["figure","children",r])}(e,r)){var n=e,a=e.parentNode;(function(e,t){var r=e.nodeName.toLowerCase();return Object(f.has)(t,["figure","children","a","children",r])})(e,r)&&"A"===a.nodeName&&1===a.childNodes.length&&(n=e.parentNode);var o=n.closest("p,div");o?e.classList?(e.classList.contains("alignright")||e.classList.contains("alignleft")||e.classList.contains("aligncenter")||!o.textContent.trim())&&pn(n,o):pn(n,o):"BODY"===n.parentNode.nodeName&&pn(n)}}var gn=r(126);function bn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function mn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?bn(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):bn(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var _n=function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],a=lt("from"),o=ct(a,(function(e){return-1===n.indexOf(e.blockName)&&"shortcode"===e.type&&Object(f.some)(Object(f.castArray)(e.tag),(function(e){return Object(gn.regexp)(e).test(t)}))}));if(!o)return[t];var i,s=Object(f.castArray)(o.tag),c=Object(f.find)(s,(function(e){return Object(gn.regexp)(e).test(t)})),u=r;if(i=Object(gn.next)(c,t,r)){r=i.index+i.content.length;var d=t.substr(0,i.index),p=t.substr(r);if(!(Object(f.includes)(i.shortcode.content||"","<")||/(\n|<p>)\s*$/.test(d)&&/^\s*(\n|<\/p>)/.test(p)))return e(t,r);if(o.isMatch&&!o.isMatch(i.shortcode.attrs))return e(t,u,[].concat(l(n),[o.blockName]));var h=Object(f.mapValues)(Object(f.pickBy)(o.attributes,(function(e){return e.shortcode})),(function(e){return e.shortcode(i.shortcode.attrs,i)})),g=tt(o.blockName,Rr(mn(mn({},Ve(o.blockName)),{},{attributes:o.attributes}),i.shortcode.content,h));return[].concat(l(e(d)),[g],l(e(p)))}return[t]},vn=r(270),wn=new(r.n(vn).a.Converter)({noHeaderId:!0,tables:!0,literalMidWordUnderscores:!0,omitExtraWLInCodeBlocks:!0,simpleLineBreaks:!0,strikethrough:!0});function yn(e){if("IFRAME"===e.nodeName){var t=e.ownerDocument.createTextNode(e.src);e.parentNode.replaceChild(t,e)}}function kn(e){e.id&&0===e.id.indexOf("docs-internal-guid-")&&Object(de.unwrap)(e)}function On(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function jn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?On(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):On(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function Cn(e,t,r){var n=e.map((function(e){var n=e.isMatch,a=e.blockName,o=e.schema,i=$e(a,"anchor");return o=Object(f.isFunction)(o)?o({phrasingContentSchema:t,isPaste:r}):o,i||n?Object(f.mapValues)(o,(function(e){var t=e.attributes||[];return i&&(t=[].concat(l(t),["id"])),jn(jn({},e),{},{attributes:t,isMatch:n||void 0})})):o}));return f.mergeWith.apply(void 0,[{}].concat(l(n),[function(e,t,r){switch(r){case"children":return"*"===e||"*"===t?"*":jn(jn({},e),t);case"attributes":case"require":return[].concat(l(e||[]),l(t||[]));case"isMatch":if(!e||!t)return;return function(){return e.apply(void 0,arguments)||t.apply(void 0,arguments)}}}]))}function xn(e,t,r,n){Array.from(e).forEach((function(e){xn(e.childNodes,t,r,n),t.forEach((function(t){r.contains(e)&&t(e,r,n)}))}))}function Tn(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2?arguments[2]:void 0,n=document.implementation.createHTMLDocument("");return n.body.innerHTML=e,xn(n.body.childNodes,t,n,r),n.body.innerHTML}function Pn(e,t){var r=e["".concat(t,"Sibling")];if(r&&Object(de.isPhrasingContent)(r))return r;var n=e.parentNode;return n&&Object(de.isPhrasingContent)(n)?Pn(n,t):void 0}function Sn(e){if(e.nodeType===e.TEXT_NODE){for(var t=e;t=t.parentNode;)if(t.nodeType===t.ELEMENT_NODE&&"PRE"===t.nodeName)return;var r,n=e.data.replace(/[ \r\n\t]+/g," ");if(" "===n[0]){var a=Pn(e,"previous");a&&"BR"!==a.nodeName&&" "!==a.textContent.slice(-1)||(n=n.slice(1))}if(" "===n[n.length-1]){var o=Pn(e,"next");(!o||"BR"===o.nodeName||o.nodeType===o.TEXT_NODE&&(" "===(r=o.textContent[0])||"\r"===r||"\n"===r||"\t"===r))&&(n=n.slice(0,-1))}n?e.data=n:e.parentNode.removeChild(e)}}function An(e){"BR"===e.nodeName&&(Pn(e,"next")||e.parentNode.removeChild(e))}function En(e){"P"===e.nodeName&&(e.hasChildNodes()||e.parentNode.removeChild(e))}function Bn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Nn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Bn(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Bn(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var Ln=window.console;function Mn(e){return e=Tn(e,[kn,Jr,Zr]),e=Tn(e=Object(de.removeInvalidHTML)(e,Object(de.getPhrasingContentSchema)("paste"),{inline:!0}),[Sn,An]),Ln.log("Processed inline HTML:\n\n",e),e}function zn(e){var t,r=e.HTML,n=void 0===r?"":r,a=e.plainText,o=void 0===a?"":a,i=e.mode,s=void 0===i?"AUTO":i,c=e.tagName;if(n=(n=(n=n.replace(/<meta[^>]+>/g,"")).replace(/^\s*<html[^>]*>\s*<body[^>]*>(?:\s*<!--\s*StartFragment\s*-->)?/i,"")).replace(/(?:<!--\s*EndFragment\s*-->\s*)?<\/body>\s*<\/html>\s*$/i,""),"INLINE"!==s){var l=n||o;if(-1!==l.indexOf("\x3c!-- wp:"))return Gr(l)}if(String.prototype.normalize&&(n=n.normalize()),!o||n&&!function(e){return!/<(?!br[ />])/i.test(e)}(n)||(t=o,n=wn.makeHtml(function(e){return e.replace(/((?:^|\n)```)([^\n`]+)(```(?:$|\n))/,(function(e,t,r,n){return"".concat(t,"\n").concat(r,"\n").concat(n)}))}(t)),"AUTO"===s&&-1===o.indexOf("\n")&&0!==o.indexOf("<p>")&&0===n.indexOf("<p>")&&(s="INLINE")),"INLINE"===s)return Mn(n);var u=_n(n),d=u.length>1;if("AUTO"===s&&!d&&function(e,t){var r=document.implementation.createHTMLDocument("");r.body.innerHTML=e;var n=Array.from(r.body.children);return!n.some(Xr)&&Qr(n,t)}(n,c))return Mn(n);var p=Object(f.filter)(lt("from"),{type:"raw"}).map((function(e){return e.isMatch?e:Nn(Nn({},e),{},{isMatch:function(t){return e.selector&&t.matches(e.selector)}})})),h=Object(de.getPhrasingContentSchema)("paste"),g=Cn(p,h,!0),b=Object(f.compact)(Object(f.flatMap)(u,(function(e){if("string"!=typeof e)return e;var t=[kn,nn,en,on,fn,Jr,Yr,Zr,yn,hn,dn],r=Nn(Nn({},g),h);return e=Tn(e,t,g),e=Tn(e=Wr(e=Object(de.removeInvalidHTML)(e,r)),[Sn,An,En],g),Ln.log("Processed HTML piece:\n\n",e),function(e){var t=e.html,r=e.rawTransforms,n=document.implementation.createHTMLDocument("");return n.body.innerHTML=t,Array.from(n.body.children).map((function(e){var t=ct(r,(function(t){return(0,t.isMatch)(e)}));if(!t)return tt("core/html",Rr("core/html",e.outerHTML));var n=t.transform,a=t.blockName;return n?n(e):tt(a,Rr(a,e.outerHTML))}))}({html:e,rawTransforms:p})})));if("AUTO"===s&&1===b.length&&$e(b[0].name,"__unstablePasteTextInline",!1)){var m=o.trim();if(""!==m&&-1===m.indexOf("\n"))return Object(de.removeInvalidHTML)(Qt(b[0]),h)}return b}var Dn=r(31),Hn=r.n(Dn);function In(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Vn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?In(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):In(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function Rn(e){return Hn()("wp.blocks.getPhrasingContentSchema",{alternative:"wp.dom.getPhrasingContentSchema"}),Object(de.getPhrasingContentSchema)(e)}function Fn(e){var t=e.HTML,r=void 0===t?"":t;if(-1!==r.indexOf("\x3c!-- wp:"))return Gr(r);var n=_n(r),a=Object(f.filter)(lt("from"),{type:"raw"}).map((function(e){return e.isMatch?e:Vn(Vn({},e),{},{isMatch:function(t){return e.selector&&t.matches(e.selector)}})})),o=Object(de.getPhrasingContentSchema)(),i=Cn(a,o);return Object(f.compact)(Object(f.flatMap)(n,(function(e){return"string"!=typeof e?e:function(e){var t=e.html,r=e.rawTransforms,n=document.implementation.createHTMLDocument("");return n.body.innerHTML=t,Array.from(n.body.children).map((function(e){var t=ct(r,(function(t){return(0,t.isMatch)(e)}));if(!t)return tt("core/html",Rr("core/html",e.outerHTML));var n=t.transform,a=t.blockName;return n?n(e):tt(a,Rr(a,e.outerHTML))}))}({html:e=Wr(e=Tn(e,[on,Yr,hn,dn],i)),rawTransforms:a})})))}function $n(){return Object(o.select)("core/blocks").getCategories()}function qn(e){Object(o.dispatch)("core/blocks").setCategories(e)}function Un(e,t){Object(o.dispatch)("core/blocks").updateCategory(e,t)}function Gn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Kn(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Gn(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Gn(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function Wn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return e.length===t.length&&Object(f.every)(t,(function(t,r){var n=oe(t,3),a=n[0],o=n[2],i=e[r];return a===i.name&&Wn(i.innerBlocks,o)}))}function Yn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0;return t?Object(f.map)(t,(function(t,r){var n=oe(t,3),a=n[0],o=n[1],i=n[2],s=e[r];if(s&&s.name===a){var c=Yn(s.innerBlocks,i);return Kn(Kn({},s),{},{innerBlocks:c})}var l=Ve(a),u=function(e,t){return Object(f.mapValues)(t,(function(t,r){return d(e[r],t)}))},d=function(e,t){return r=e,"html"===Object(f.get)(r,["source"])&&Object(f.isArray)(t)?Object(fe.renderToString)(t):function(e){return"query"===Object(f.get)(e,["source"])}(e)&&t?t.map((function(t){return u(e.query,t)})):t;var r},p=Fr(a,u(Object(f.get)(l,["attributes"],{}),o));return tt(p.name,p.attributes,Yn([],i))})):e}},41:function(e,t){!function(){e.exports=this.wp.blob}()},44:function(e,t,r){"use strict";var n,a;function o(e){return[e]}function i(){var e={clear:function(){e.head=null}};return e}function s(e,t,r){var n;if(e.length!==t.length)return!1;for(n=r;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}n={},a="undefined"!=typeof WeakMap,t.a=function(e,t){var r,c;function l(){r=a?new WeakMap:i()}function u(){var r,n,a,o,i,l=arguments.length;for(o=new Array(l),a=0;a<l;a++)o[a]=arguments[a];for(i=t.apply(null,o),(r=c(i)).isUniqueByDependants||(r.lastDependants&&!s(i,r.lastDependants,0)&&r.clear(),r.lastDependants=i),n=r.head;n;){if(s(n.args,o,1))return n!==r.head&&(n.prev.next=n.next,n.next&&(n.next.prev=n.prev),n.next=r.head,n.prev=null,r.head.prev=n,r.head=n),n.val;n=n.next}return n={val:e.apply(null,o)},o[0]=null,n.args=o,r.head&&(r.head.prev=n,n.next=r.head),r.head=n,n.val}return t||(t=o),c=a?function(e){var t,a,o,s,c,l=r,u=!0;for(t=0;t<e.length;t++){if(a=e[t],!(c=a)||"object"!=typeof c){u=!1;break}l.has(a)?l=l.get(a):(o=new WeakMap,l.set(a,o),l=o)}return l.has(n)||((s=i()).isUniqueByDependants=u,l.set(n,s)),l.get(n)}:function(){return r},u.getDependants=t,u.clear=l,l(),u}},6:function(e,t){!function(){e.exports=this.wp.primitives}()},71:function(e,t){!function(){e.exports=this.wp.htmlEntities}()},73:function(e,t){!function(){e.exports=this.wp.isShallowEqual}()},74:function(e,t,r){var n;!function(a){var o=/^\s+/,i=/\s+$/,s=0,c=a.round,l=a.min,u=a.max,f=a.random;function d(e,t){if(t=t||{},(e=e||"")instanceof d)return e;if(!(this instanceof d))return new d(e,t);var r=function(e){var t={r:0,g:0,b:0},r=1,n=null,s=null,c=null,f=!1,d=!1;"string"==typeof e&&(e=function(e){e=e.replace(o,"").replace(i,"").toLowerCase();var t,r=!1;if(A[e])e=A[e],r=!0;else if("transparent"==e)return{r:0,g:0,b:0,a:0,format:"name"};if(t=$.rgb.exec(e))return{r:t[1],g:t[2],b:t[3]};if(t=$.rgba.exec(e))return{r:t[1],g:t[2],b:t[3],a:t[4]};if(t=$.hsl.exec(e))return{h:t[1],s:t[2],l:t[3]};if(t=$.hsla.exec(e))return{h:t[1],s:t[2],l:t[3],a:t[4]};if(t=$.hsv.exec(e))return{h:t[1],s:t[2],v:t[3]};if(t=$.hsva.exec(e))return{h:t[1],s:t[2],v:t[3],a:t[4]};if(t=$.hex8.exec(e))return{r:M(t[1]),g:M(t[2]),b:M(t[3]),a:I(t[4]),format:r?"name":"hex8"};if(t=$.hex6.exec(e))return{r:M(t[1]),g:M(t[2]),b:M(t[3]),format:r?"name":"hex"};if(t=$.hex4.exec(e))return{r:M(t[1]+""+t[1]),g:M(t[2]+""+t[2]),b:M(t[3]+""+t[3]),a:I(t[4]+""+t[4]),format:r?"name":"hex8"};if(t=$.hex3.exec(e))return{r:M(t[1]+""+t[1]),g:M(t[2]+""+t[2]),b:M(t[3]+""+t[3]),format:r?"name":"hex"};return!1}(e));"object"==typeof e&&(q(e.r)&&q(e.g)&&q(e.b)?(p=e.r,h=e.g,g=e.b,t={r:255*N(p,255),g:255*N(h,255),b:255*N(g,255)},f=!0,d="%"===String(e.r).substr(-1)?"prgb":"rgb"):q(e.h)&&q(e.s)&&q(e.v)?(n=D(e.s),s=D(e.v),t=function(e,t,r){e=6*N(e,360),t=N(t,100),r=N(r,100);var n=a.floor(e),o=e-n,i=r*(1-t),s=r*(1-o*t),c=r*(1-(1-o)*t),l=n%6;return{r:255*[r,s,i,i,c,r][l],g:255*[c,r,r,s,i,i][l],b:255*[i,i,c,r,r,s][l]}}(e.h,n,s),f=!0,d="hsv"):q(e.h)&&q(e.s)&&q(e.l)&&(n=D(e.s),c=D(e.l),t=function(e,t,r){var n,a,o;function i(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+6*(t-e)*r:r<.5?t:r<2/3?e+(t-e)*(2/3-r)*6:e}if(e=N(e,360),t=N(t,100),r=N(r,100),0===t)n=a=o=r;else{var s=r<.5?r*(1+t):r+t-r*t,c=2*r-s;n=i(c,s,e+1/3),a=i(c,s,e),o=i(c,s,e-1/3)}return{r:255*n,g:255*a,b:255*o}}(e.h,n,c),f=!0,d="hsl"),e.hasOwnProperty("a")&&(r=e.a));var p,h,g;return r=B(r),{ok:f,format:e.format||d,r:l(255,u(t.r,0)),g:l(255,u(t.g,0)),b:l(255,u(t.b,0)),a:r}}(e);this._originalInput=e,this._r=r.r,this._g=r.g,this._b=r.b,this._a=r.a,this._roundA=c(100*this._a)/100,this._format=t.format||r.format,this._gradientType=t.gradientType,this._r<1&&(this._r=c(this._r)),this._g<1&&(this._g=c(this._g)),this._b<1&&(this._b=c(this._b)),this._ok=r.ok,this._tc_id=s++}function p(e,t,r){e=N(e,255),t=N(t,255),r=N(r,255);var n,a,o=u(e,t,r),i=l(e,t,r),s=(o+i)/2;if(o==i)n=a=0;else{var c=o-i;switch(a=s>.5?c/(2-o-i):c/(o+i),o){case e:n=(t-r)/c+(t<r?6:0);break;case t:n=(r-e)/c+2;break;case r:n=(e-t)/c+4}n/=6}return{h:n,s:a,l:s}}function h(e,t,r){e=N(e,255),t=N(t,255),r=N(r,255);var n,a,o=u(e,t,r),i=l(e,t,r),s=o,c=o-i;if(a=0===o?0:c/o,o==i)n=0;else{switch(o){case e:n=(t-r)/c+(t<r?6:0);break;case t:n=(r-e)/c+2;break;case r:n=(e-t)/c+4}n/=6}return{h:n,s:a,v:s}}function g(e,t,r,n){var a=[z(c(e).toString(16)),z(c(t).toString(16)),z(c(r).toString(16))];return n&&a[0].charAt(0)==a[0].charAt(1)&&a[1].charAt(0)==a[1].charAt(1)&&a[2].charAt(0)==a[2].charAt(1)?a[0].charAt(0)+a[1].charAt(0)+a[2].charAt(0):a.join("")}function b(e,t,r,n){return[z(H(n)),z(c(e).toString(16)),z(c(t).toString(16)),z(c(r).toString(16))].join("")}function m(e,t){t=0===t?0:t||10;var r=d(e).toHsl();return r.s-=t/100,r.s=L(r.s),d(r)}function _(e,t){t=0===t?0:t||10;var r=d(e).toHsl();return r.s+=t/100,r.s=L(r.s),d(r)}function v(e){return d(e).desaturate(100)}function w(e,t){t=0===t?0:t||10;var r=d(e).toHsl();return r.l+=t/100,r.l=L(r.l),d(r)}function y(e,t){t=0===t?0:t||10;var r=d(e).toRgb();return r.r=u(0,l(255,r.r-c(-t/100*255))),r.g=u(0,l(255,r.g-c(-t/100*255))),r.b=u(0,l(255,r.b-c(-t/100*255))),d(r)}function k(e,t){t=0===t?0:t||10;var r=d(e).toHsl();return r.l-=t/100,r.l=L(r.l),d(r)}function O(e,t){var r=d(e).toHsl(),n=(r.h+t)%360;return r.h=n<0?360+n:n,d(r)}function j(e){var t=d(e).toHsl();return t.h=(t.h+180)%360,d(t)}function C(e){var t=d(e).toHsl(),r=t.h;return[d(e),d({h:(r+120)%360,s:t.s,l:t.l}),d({h:(r+240)%360,s:t.s,l:t.l})]}function x(e){var t=d(e).toHsl(),r=t.h;return[d(e),d({h:(r+90)%360,s:t.s,l:t.l}),d({h:(r+180)%360,s:t.s,l:t.l}),d({h:(r+270)%360,s:t.s,l:t.l})]}function T(e){var t=d(e).toHsl(),r=t.h;return[d(e),d({h:(r+72)%360,s:t.s,l:t.l}),d({h:(r+216)%360,s:t.s,l:t.l})]}function P(e,t,r){t=t||6,r=r||30;var n=d(e).toHsl(),a=360/r,o=[d(e)];for(n.h=(n.h-(a*t>>1)+720)%360;--t;)n.h=(n.h+a)%360,o.push(d(n));return o}function S(e,t){t=t||6;for(var r=d(e).toHsv(),n=r.h,a=r.s,o=r.v,i=[],s=1/t;t--;)i.push(d({h:n,s:a,v:o})),o=(o+s)%1;return i}d.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,r,n=this.toRgb();return e=n.r/255,t=n.g/255,r=n.b/255,.2126*(e<=.03928?e/12.92:a.pow((e+.055)/1.055,2.4))+.7152*(t<=.03928?t/12.92:a.pow((t+.055)/1.055,2.4))+.0722*(r<=.03928?r/12.92:a.pow((r+.055)/1.055,2.4))},setAlpha:function(e){return this._a=B(e),this._roundA=c(100*this._a)/100,this},toHsv:function(){var e=h(this._r,this._g,this._b);return{h:360*e.h,s:e.s,v:e.v,a:this._a}},toHsvString:function(){var e=h(this._r,this._g,this._b),t=c(360*e.h),r=c(100*e.s),n=c(100*e.v);return 1==this._a?"hsv("+t+", "+r+"%, "+n+"%)":"hsva("+t+", "+r+"%, "+n+"%, "+this._roundA+")"},toHsl:function(){var e=p(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=p(this._r,this._g,this._b),t=c(360*e.h),r=c(100*e.s),n=c(100*e.l);return 1==this._a?"hsl("+t+", "+r+"%, "+n+"%)":"hsla("+t+", "+r+"%, "+n+"%, "+this._roundA+")"},toHex:function(e){return g(this._r,this._g,this._b,e)},toHexString:function(e){return"#"+this.toHex(e)},toHex8:function(e){return function(e,t,r,n,a){var o=[z(c(e).toString(16)),z(c(t).toString(16)),z(c(r).toString(16)),z(H(n))];if(a&&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[3].charAt(0)==o[3].charAt(1))return o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0)+o[3].charAt(0);return o.join("")}(this._r,this._g,this._b,this._a,e)},toHex8String:function(e){return"#"+this.toHex8(e)},toRgb:function(){return{r:c(this._r),g:c(this._g),b:c(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+c(this._r)+", "+c(this._g)+", "+c(this._b)+")":"rgba("+c(this._r)+", "+c(this._g)+", "+c(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:c(100*N(this._r,255))+"%",g:c(100*N(this._g,255))+"%",b:c(100*N(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+c(100*N(this._r,255))+"%, "+c(100*N(this._g,255))+"%, "+c(100*N(this._b,255))+"%)":"rgba("+c(100*N(this._r,255))+"%, "+c(100*N(this._g,255))+"%, "+c(100*N(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(E[g(this._r,this._g,this._b,!0)]||!1)},toFilter:function(e){var t="#"+b(this._r,this._g,this._b,this._a),r=t,n=this._gradientType?"GradientType = 1, ":"";if(e){var a=d(e);r="#"+b(a._r,a._g,a._b,a._a)}return"progid:DXImageTransform.Microsoft.gradient("+n+"startColorstr="+t+",endColorstr="+r+")"},toString:function(e){var t=!!e;e=e||this._format;var r=!1,n=this._a<1&&this._a>=0;return t||!n||"hex"!==e&&"hex6"!==e&&"hex3"!==e&&"hex4"!==e&&"hex8"!==e&&"name"!==e?("rgb"===e&&(r=this.toRgbString()),"prgb"===e&&(r=this.toPercentageRgbString()),"hex"!==e&&"hex6"!==e||(r=this.toHexString()),"hex3"===e&&(r=this.toHexString(!0)),"hex4"===e&&(r=this.toHex8String(!0)),"hex8"===e&&(r=this.toHex8String()),"name"===e&&(r=this.toName()),"hsl"===e&&(r=this.toHslString()),"hsv"===e&&(r=this.toHsvString()),r||this.toHexString()):"name"===e&&0===this._a?this.toName():this.toRgbString()},clone:function(){return d(this.toString())},_applyModification:function(e,t){var r=e.apply(null,[this].concat([].slice.call(t)));return this._r=r._r,this._g=r._g,this._b=r._b,this.setAlpha(r._a),this},lighten:function(){return this._applyModification(w,arguments)},brighten:function(){return this._applyModification(y,arguments)},darken:function(){return this._applyModification(k,arguments)},desaturate:function(){return this._applyModification(m,arguments)},saturate:function(){return this._applyModification(_,arguments)},greyscale:function(){return this._applyModification(v,arguments)},spin:function(){return this._applyModification(O,arguments)},_applyCombination:function(e,t){return e.apply(null,[this].concat([].slice.call(t)))},analogous:function(){return this._applyCombination(P,arguments)},complement:function(){return this._applyCombination(j,arguments)},monochromatic:function(){return this._applyCombination(S,arguments)},splitcomplement:function(){return this._applyCombination(T,arguments)},triad:function(){return this._applyCombination(C,arguments)},tetrad:function(){return this._applyCombination(x,arguments)}},d.fromRatio=function(e,t){if("object"==typeof e){var r={};for(var n in e)e.hasOwnProperty(n)&&(r[n]="a"===n?e[n]:D(e[n]));e=r}return d(e,t)},d.equals=function(e,t){return!(!e||!t)&&d(e).toRgbString()==d(t).toRgbString()},d.random=function(){return d.fromRatio({r:f(),g:f(),b:f()})},d.mix=function(e,t,r){r=0===r?0:r||50;var n=d(e).toRgb(),a=d(t).toRgb(),o=r/100;return d({r:(a.r-n.r)*o+n.r,g:(a.g-n.g)*o+n.g,b:(a.b-n.b)*o+n.b,a:(a.a-n.a)*o+n.a})},d.readability=function(e,t){var r=d(e),n=d(t);return(a.max(r.getLuminance(),n.getLuminance())+.05)/(a.min(r.getLuminance(),n.getLuminance())+.05)},d.isReadable=function(e,t,r){var n,a,o=d.readability(e,t);switch(a=!1,(n=function(e){var t,r;t=((e=e||{level:"AA",size:"small"}).level||"AA").toUpperCase(),r=(e.size||"small").toLowerCase(),"AA"!==t&&"AAA"!==t&&(t="AA");"small"!==r&&"large"!==r&&(r="small");return{level:t,size:r}}(r)).level+n.size){case"AAsmall":case"AAAlarge":a=o>=4.5;break;case"AAlarge":a=o>=3;break;case"AAAsmall":a=o>=7}return a},d.mostReadable=function(e,t,r){var n,a,o,i,s=null,c=0;a=(r=r||{}).includeFallbackColors,o=r.level,i=r.size;for(var l=0;l<t.length;l++)(n=d.readability(e,t[l]))>c&&(c=n,s=d(t[l]));return d.isReadable(e,s,{level:o,size:i})||!a?s:(r.includeFallbackColors=!1,d.mostReadable(e,["#fff","#000"],r))};var A=d.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"},E=d.hexNames=function(e){var t={};for(var r in e)e.hasOwnProperty(r)&&(t[e[r]]=r);return t}(A);function B(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 r=function(e){return"string"==typeof e&&-1!=e.indexOf("%")}(e);return e=l(t,u(0,parseFloat(e))),r&&(e=parseInt(e*t,10)/100),a.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function L(e){return l(1,u(0,e))}function M(e){return parseInt(e,16)}function z(e){return 1==e.length?"0"+e:""+e}function D(e){return e<=1&&(e=100*e+"%"),e}function H(e){return a.round(255*parseFloat(e)).toString(16)}function I(e){return M(e)/255}var V,R,F,$=(R="[\\s|\\(]+("+(V="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)")+")[,|\\s]+("+V+")[,|\\s]+("+V+")\\s*\\)?",F="[\\s|\\(]+("+V+")[,|\\s]+("+V+")[,|\\s]+("+V+")[,|\\s]+("+V+")\\s*\\)?",{CSS_UNIT:new RegExp(V),rgb:new RegExp("rgb"+R),rgba:new RegExp("rgba"+F),hsl:new RegExp("hsl"+R),hsla:new RegExp("hsla"+F),hsv:new RegExp("hsv"+R),hsva:new RegExp("hsva"+F),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 q(e){return!!$.CSS_UNIT.exec(e)}e.exports?e.exports=d:void 0===(n=function(){return d}.call(t,r,t,e))||(e.exports=n)}(Math)}});
|
10 |
/* translators: accessibility text. %1: The block title. %2: The block label. */
|
11 |
Object(d.__)("%1$s Block. %2$s"),a,o):Object(d.sprintf)(
|
12 |
/* translators: accessibility text. %s: The block title. */
|
13 |
+
Object(d.__)("%s Block"),a)}var ke=["attributes","supports","save","migrate","isEligible","apiVersion"],Oe={"--wp--style--color--link":["color","link"],background:["color","gradient"],backgroundColor:["color","background"],color:["color","text"],fontSize:["typography","fontSize"],lineHeight:["typography","lineHeight"],paddingBottom:["spacing","padding","bottom"],paddingLeft:["spacing","padding","left"],paddingRight:["spacing","padding","right"],paddingTop:["spacing","padding","top"]};function je(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ce(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?je(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):je(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var xe={common:"text",formatting:"text",layout:"design"},Te={};function Pe(e){Te=Ce(Ce({},Te),e)}function Se(e,t){if(t=Ce(Ce({name:e,icon:ce.a,keywords:[],attributes:{},providesContext:{},usesContext:[],supports:{},styles:[],save:function(){return null}},Object(f.pickBy)(Object(f.get)(Te,e,{}),(function(e){return!Object(f.isNil)(e)}))),t),"string"==typeof e)if(/^[a-z][a-z0-9-]*\/[a-z][a-z0-9-]*$/.test(e))if(Object(o.select)("core/blocks").getBlockType(e))console.error('Block "'+e+'" is already registered.');else{var r=Ce({},t);if((t=Object(se.applyFilters)("blocks.registerBlockType",t,e)).deprecated&&(t.deprecated=t.deprecated.map((function(t){return Object(f.pick)(Object(se.applyFilters)("blocks.registerBlockType",Ce(Ce({},Object(f.omit)(r,ke)),t),e),ke)}))),Object(f.isPlainObject)(t))if(Object(f.isFunction)(t.save))if(!("edit"in t)||Object(f.isFunction)(t.edit))if(xe.hasOwnProperty(t.category)&&(t.category=xe[t.category]),"category"in t&&!Object(f.some)(Object(o.select)("core/blocks").getCategories(),{slug:t.category})&&(console.warn('The block "'+e+'" is registered with an invalid category "'+t.category+'".'),delete t.category),"title"in t&&""!==t.title)if("string"==typeof t.title){if(t.icon=_e(t.icon),me(t.icon.src))return Object(o.dispatch)("core/blocks").addBlockTypes(t),t;console.error("The icon passed is invalid. The icon should be a string, an element, a function, or an object following the specifications documented in https://developer.wordpress.org/block-editor/developers/block-api/block-registration/#icon-optional")}else console.error("Block titles must be strings.");else console.error('The block "'+e+'" must have a title.');else console.error('The "edit" property must be a valid function.');else console.error('The "save" property must be a valid function.');else console.error("Block settings must be a valid object.")}else console.error("Block names must contain a namespace prefix, include only lowercase alphanumeric characters or dashes, and start with a letter. Example: my-plugin/my-custom-block");else console.error("Block names must be strings.")}function Ae(e,t){var r=t.title,n=t.icon;Object(o.dispatch)("core/blocks").addBlockCollection(e,r,n)}function Ee(e){var t=Object(o.select)("core/blocks").getBlockType(e);if(t)return Object(o.dispatch)("core/blocks").removeBlockTypes(e),t;console.error('Block "'+e+'" is not registered.')}function Be(e){Object(o.dispatch)("core/blocks").setFreeformFallbackBlockName(e)}function Ne(){return Object(o.select)("core/blocks").getFreeformFallbackBlockName()}function Le(){return Object(o.select)("core/blocks").getGroupingBlockName()}function Me(e){Object(o.dispatch)("core/blocks").setUnregisteredFallbackBlockName(e)}function ze(){return Object(o.select)("core/blocks").getUnregisteredFallbackBlockName()}function De(e){Object(o.dispatch)("core/blocks").setDefaultBlockName(e)}function He(e){Object(o.dispatch)("core/blocks").setGroupingBlockName(e)}function Ie(){return Object(o.select)("core/blocks").getDefaultBlockName()}function Ve(e){return Object(o.select)("core/blocks").getBlockType(e)}function Re(){return Object(o.select)("core/blocks").getBlockTypes()}function Fe(e,t,r){return Object(o.select)("core/blocks").getBlockSupport(e,t,r)}function $e(e,t,r){return Object(o.select)("core/blocks").hasBlockSupport(e,t,r)}function qe(e){return"core/block"===e.name}var Ue=function(e){return Object(o.select)("core/blocks").getChildBlockNames(e)},Ge=function(e){return Object(o.select)("core/blocks").hasChildBlocks(e)},Ke=function(e){return Object(o.select)("core/blocks").hasChildBlocksWithInserterSupport(e)},We=function(e,t){Object(o.dispatch)("core/blocks").addBlockStyles(e,t)},Ye=function(e,t){Object(o.dispatch)("core/blocks").removeBlockStyles(e,t)},Ze=function(e,t){return Object(o.select)("core/blocks").getBlockVariations(e,t)},Qe=function(e,t){Object(o.dispatch)("core/blocks").addBlockVariations(e,t)},Xe=function(e,t){Object(o.dispatch)("core/blocks").removeBlockVariations(e,t)};function Je(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function et(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Je(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Je(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function tt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],n=Ve(e);if(void 0===n)throw new Error("Block type '".concat(e,"' is not registered."));var a=Object(f.reduce)(n.attributes,(function(e,r,n){var a=t[n];return void 0!==a?e[n]=a:r.hasOwnProperty("default")&&(e[n]=r.default),-1!==["node","children"].indexOf(r.source)&&("string"==typeof e[n]?e[n]=[e[n]]:Array.isArray(e[n])||(e[n]=[])),e}),{}),o=Object(ie.a)();return{clientId:o,name:e,isValid:!0,attributes:a,innerBlocks:r}}function rt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e.map((function(e){var t=oe(Array.isArray(e)?e:[e.name,e.attributes,e.innerBlocks],3),r=t[0],n=t[1],a=t[2];return tt(r,n,rt(void 0===a?[]:a))}))}function nt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,n=Object(ie.a)();return et(et({},e),{},{clientId:n,attributes:et(et({},e.attributes),t),innerBlocks:r||e.innerBlocks.map((function(e){return nt(e)}))})}var at=function(e,t,r){if(Object(f.isEmpty)(r))return!1;var n=r.length>1,a=Object(f.first)(r).name;if(!(ot(e)||!n||e.isMultiBlock))return!1;if(!ot(e)&&!Object(f.every)(r,{name:a}))return!1;if(!("block"===e.type))return!1;var o=Object(f.first)(r);if(!("from"!==t||-1!==e.blocks.indexOf(o.name)||ot(e)))return!1;if(!n&&it(o.name)&&it(e.blockName))return!1;if(Object(f.isFunction)(e.isMatch)){var i=e.isMultiBlock?r.map((function(e){return e.attributes})):o.attributes;if(!e.isMatch(i))return!1}return!0},ot=function(e){return e&&"block"===e.type&&Array.isArray(e.blocks)&&e.blocks.includes("*")},it=function(e){return e===Le()};function st(e){if(Object(f.isEmpty)(e))return[];var t=function(e){if(Object(f.isEmpty)(e))return[];var t=Re();return Object(f.filter)(t,(function(t){return!!ct(lt("from",t.name),(function(t){return at(t,"from",e)}))}))}(e),r=function(e){if(Object(f.isEmpty)(e))return[];var t=lt("to",Ve(Object(f.first)(e).name).name),r=Object(f.filter)(t,(function(t){return t&&at(t,"to",e)}));return Object(f.flatMap)(r,(function(e){return e.blocks})).map((function(e){return Ve(e)}))}(e);return Object(f.uniq)([].concat(l(t),l(r)))}function ct(e,t){for(var r=Object(se.createHooks)(),n=function(n){var a=e[n];t(a)&&r.addFilter("transform","transform/"+n.toString(),(function(e){return e||a}),a.priority)},a=0;a<e.length;a++)n(a);return r.applyFilters("transform",null)}function lt(e,t){if(void 0===t)return Object(f.flatMap)(Re(),(function(t){var r=t.name;return lt(e,r)}));var r=ve(t)||{},n=r.name,a=r.transforms;return a&&Array.isArray(a[e])?a[e].map((function(e){return et(et({},e),{},{blockName:n})})):[]}function ut(e,t){var r,n=Object(f.castArray)(e),a=n.length>1,o=n[0],i=o.name,s=lt("from",t),c=ct(lt("to",i),(function(e){return"block"===e.type&&(ot(e)||-1!==e.blocks.indexOf(t))&&(!a||e.isMultiBlock)}))||ct(s,(function(e){return"block"===e.type&&(ot(e)||-1!==e.blocks.indexOf(i))&&(!a||e.isMultiBlock)}));if(!c)return null;if(r=c.isMultiBlock?Object(f.has)(c,"__experimentalConvert")?c.__experimentalConvert(n):c.transform(n.map((function(e){return e.attributes})),n.map((function(e){return e.innerBlocks}))):Object(f.has)(c,"__experimentalConvert")?c.__experimentalConvert(o):c.transform(o.attributes,o.innerBlocks),!Object(f.isObjectLike)(r))return null;if((r=Object(f.castArray)(r)).some((function(e){return!Ve(e.name)})))return null;var l=Object(f.findIndex)(r,(function(e){return e.name===t}));return l<0?null:r.map((function(t,r){var n=et(et({},t),{},{clientId:r===l?o.clientId:t.clientId});return Object(se.applyFilters)("blocks.switchToBlockType.transformedBlock",n,e)}))}var ft=function e(t,r){return tt(t,r.attributes,Object(f.map)(r.innerBlocks,(function(t){return e(t.name,t)})))};function dt(e,t){for(var r,n=t.split(".");r=n.shift();){if(!(r in e))return;e=e[r]}return e}var pt,ht=function(){return pt||(pt=document.implementation.createHTMLDocument("")),pt};function gt(e,t){if(t){if("string"==typeof e){var r=ht();r.body.innerHTML=e,e=r.body}if("function"==typeof t)return t(e);if(Object===t.constructor)return Object.keys(t).reduce((function(r,n){return r[n]=gt(e,t[n]),r}),{})}}function bt(e,t){return 1===arguments.length&&(t=e,e=void 0),function(r){var n=r;if(e&&(n=r.querySelector(e)),n)return dt(n,t)}}var mt=r(102),_t=r(269);function vt(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}var wt=/^#[xX]([A-Fa-f0-9]+)$/,yt=/^#([0-9]+)$/,kt=/^([A-Za-z0-9]+)$/,Ot=(function(){function e(e){this.named=e}e.prototype.parse=function(e){if(e){var t=e.match(wt);return t?String.fromCharCode(parseInt(t[1],16)):(t=e.match(yt))?String.fromCharCode(parseInt(t[1],10)):(t=e.match(kt))?this.named[t[1]]:void 0}}}(),/[\t\n\f ]/),jt=/[A-Za-z]/,Ct=/\r\n?/g;function xt(e){return Ot.test(e)}function Tt(e){return jt.test(e)}var Pt=function(){function e(e,t){this.delegate=e,this.entityParser=t,this.state="beforeData",this.line=-1,this.column=-1,this.input="",this.index=-1,this.tagNameBuffer="",this.states={beforeData:function(){var e=this.peek();if("<"===e)this.transitionTo("tagOpen"),this.markTagStart(),this.consume();else{if("\n"===e){var t=this.tagNameBuffer.toLowerCase();"pre"!==t&&"textarea"!==t||this.consume()}this.transitionTo("data"),this.delegate.beginData()}},data:function(){var e=this.peek();"<"===e?(this.delegate.finishData(),this.transitionTo("tagOpen"),this.markTagStart(),this.consume()):"&"===e?(this.consume(),this.delegate.appendToData(this.consumeCharRef()||"&")):(this.consume(),this.delegate.appendToData(e))},tagOpen:function(){var e=this.consume();"!"===e?this.transitionTo("markupDeclarationOpen"):"/"===e?this.transitionTo("endTagOpen"):("@"===e||":"===e||Tt(e))&&(this.transitionTo("tagName"),this.tagNameBuffer="",this.delegate.beginStartTag(),this.appendToTagName(e))},markupDeclarationOpen:function(){"-"===this.consume()&&"-"===this.input.charAt(this.index)&&(this.consume(),this.transitionTo("commentStart"),this.delegate.beginComment())},commentStart:function(){var e=this.consume();"-"===e?this.transitionTo("commentStartDash"):">"===e?(this.delegate.finishComment(),this.transitionTo("beforeData")):(this.delegate.appendToCommentData(e),this.transitionTo("comment"))},commentStartDash:function(){var e=this.consume();"-"===e?this.transitionTo("commentEnd"):">"===e?(this.delegate.finishComment(),this.transitionTo("beforeData")):(this.delegate.appendToCommentData("-"),this.transitionTo("comment"))},comment:function(){var e=this.consume();"-"===e?this.transitionTo("commentEndDash"):this.delegate.appendToCommentData(e)},commentEndDash:function(){var e=this.consume();"-"===e?this.transitionTo("commentEnd"):(this.delegate.appendToCommentData("-"+e),this.transitionTo("comment"))},commentEnd:function(){var e=this.consume();">"===e?(this.delegate.finishComment(),this.transitionTo("beforeData")):(this.delegate.appendToCommentData("--"+e),this.transitionTo("comment"))},tagName:function(){var e=this.consume();xt(e)?this.transitionTo("beforeAttributeName"):"/"===e?this.transitionTo("selfClosingStartTag"):">"===e?(this.delegate.finishTag(),this.transitionTo("beforeData")):this.appendToTagName(e)},beforeAttributeName:function(){var e=this.peek();xt(e)?this.consume():"/"===e?(this.transitionTo("selfClosingStartTag"),this.consume()):">"===e?(this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):"="===e?(this.delegate.reportSyntaxError("attribute name cannot start with equals sign"),this.transitionTo("attributeName"),this.delegate.beginAttribute(),this.consume(),this.delegate.appendToAttributeName(e)):(this.transitionTo("attributeName"),this.delegate.beginAttribute())},attributeName:function(){var e=this.peek();xt(e)?(this.transitionTo("afterAttributeName"),this.consume()):"/"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.transitionTo("selfClosingStartTag")):"="===e?(this.transitionTo("beforeAttributeValue"),this.consume()):">"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):'"'===e||"'"===e||"<"===e?(this.delegate.reportSyntaxError(e+" is not a valid character within attribute names"),this.consume(),this.delegate.appendToAttributeName(e)):(this.consume(),this.delegate.appendToAttributeName(e))},afterAttributeName:function(){var e=this.peek();xt(e)?this.consume():"/"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.transitionTo("selfClosingStartTag")):"="===e?(this.consume(),this.transitionTo("beforeAttributeValue")):">"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.transitionTo("attributeName"),this.delegate.beginAttribute(),this.consume(),this.delegate.appendToAttributeName(e))},beforeAttributeValue:function(){var e=this.peek();xt(e)?this.consume():'"'===e?(this.transitionTo("attributeValueDoubleQuoted"),this.delegate.beginAttributeValue(!0),this.consume()):"'"===e?(this.transitionTo("attributeValueSingleQuoted"),this.delegate.beginAttributeValue(!0),this.consume()):">"===e?(this.delegate.beginAttributeValue(!1),this.delegate.finishAttributeValue(),this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):(this.transitionTo("attributeValueUnquoted"),this.delegate.beginAttributeValue(!1),this.consume(),this.delegate.appendToAttributeValue(e))},attributeValueDoubleQuoted:function(){var e=this.consume();'"'===e?(this.delegate.finishAttributeValue(),this.transitionTo("afterAttributeValueQuoted")):"&"===e?this.delegate.appendToAttributeValue(this.consumeCharRef()||"&"):this.delegate.appendToAttributeValue(e)},attributeValueSingleQuoted:function(){var e=this.consume();"'"===e?(this.delegate.finishAttributeValue(),this.transitionTo("afterAttributeValueQuoted")):"&"===e?this.delegate.appendToAttributeValue(this.consumeCharRef()||"&"):this.delegate.appendToAttributeValue(e)},attributeValueUnquoted:function(){var e=this.peek();xt(e)?(this.delegate.finishAttributeValue(),this.consume(),this.transitionTo("beforeAttributeName")):"/"===e?(this.delegate.finishAttributeValue(),this.consume(),this.transitionTo("selfClosingStartTag")):"&"===e?(this.consume(),this.delegate.appendToAttributeValue(this.consumeCharRef()||"&")):">"===e?(this.delegate.finishAttributeValue(),this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):(this.consume(),this.delegate.appendToAttributeValue(e))},afterAttributeValueQuoted:function(){var e=this.peek();xt(e)?(this.consume(),this.transitionTo("beforeAttributeName")):"/"===e?(this.consume(),this.transitionTo("selfClosingStartTag")):">"===e?(this.consume(),this.delegate.finishTag(),this.transitionTo("beforeData")):this.transitionTo("beforeAttributeName")},selfClosingStartTag:function(){">"===this.peek()?(this.consume(),this.delegate.markTagAsSelfClosing(),this.delegate.finishTag(),this.transitionTo("beforeData")):this.transitionTo("beforeAttributeName")},endTagOpen:function(){var e=this.consume();("@"===e||":"===e||Tt(e))&&(this.transitionTo("tagName"),this.tagNameBuffer="",this.delegate.beginEndTag(),this.appendToTagName(e))}},this.reset()}return e.prototype.reset=function(){this.transitionTo("beforeData"),this.input="",this.index=0,this.line=1,this.column=0,this.delegate.reset()},e.prototype.transitionTo=function(e){this.state=e},e.prototype.tokenize=function(e){this.reset(),this.tokenizePart(e),this.tokenizeEOF()},e.prototype.tokenizePart=function(e){for(this.input+=function(e){return e.replace(Ct,"\n")}(e);this.index<this.input.length;){var t=this.states[this.state];if(void 0===t)throw new Error("unhandled state "+this.state);t.call(this)}},e.prototype.tokenizeEOF=function(){this.flushData()},e.prototype.flushData=function(){"data"===this.state&&(this.delegate.finishData(),this.transitionTo("beforeData"))},e.prototype.peek=function(){return this.input.charAt(this.index)},e.prototype.consume=function(){var e=this.peek();return this.index++,"\n"===e?(this.line++,this.column=0):this.column++,e},e.prototype.consumeCharRef=function(){var e=this.input.indexOf(";",this.index);if(-1!==e){var t=this.input.slice(this.index,e),r=this.entityParser.parse(t);if(r){for(var n=t.length;n;)this.consume(),n--;return this.consume(),r}}},e.prototype.markTagStart=function(){this.delegate.tagOpen()},e.prototype.appendToTagName=function(e){this.tagNameBuffer+=e,this.delegate.appendToTagName(e)},e}(),St=function(){function e(e,t){void 0===t&&(t={}),this.options=t,this.token=null,this.startLine=1,this.startColumn=0,this.tokens=[],this.tokenizer=new Pt(this,e),this._currentAttribute=void 0}return e.prototype.tokenize=function(e){return this.tokens=[],this.tokenizer.tokenize(e),this.tokens},e.prototype.tokenizePart=function(e){return this.tokens=[],this.tokenizer.tokenizePart(e),this.tokens},e.prototype.tokenizeEOF=function(){return this.tokens=[],this.tokenizer.tokenizeEOF(),this.tokens[0]},e.prototype.reset=function(){this.token=null,this.startLine=1,this.startColumn=0},e.prototype.current=function(){var e=this.token;if(null===e)throw new Error("token was unexpectedly null");if(0===arguments.length)return e;for(var t=0;t<arguments.length;t++)if(e.type===arguments[t])return e;throw new Error("token type was unexpectedly "+e.type)},e.prototype.push=function(e){this.token=e,this.tokens.push(e)},e.prototype.currentAttribute=function(){return this._currentAttribute},e.prototype.addLocInfo=function(){this.options.loc&&(this.current().loc={start:{line:this.startLine,column:this.startColumn},end:{line:this.tokenizer.line,column:this.tokenizer.column}}),this.startLine=this.tokenizer.line,this.startColumn=this.tokenizer.column},e.prototype.beginData=function(){this.push({type:"Chars",chars:""})},e.prototype.appendToData=function(e){this.current("Chars").chars+=e},e.prototype.finishData=function(){this.addLocInfo()},e.prototype.beginComment=function(){this.push({type:"Comment",chars:""})},e.prototype.appendToCommentData=function(e){this.current("Comment").chars+=e},e.prototype.finishComment=function(){this.addLocInfo()},e.prototype.tagOpen=function(){},e.prototype.beginStartTag=function(){this.push({type:"StartTag",tagName:"",attributes:[],selfClosing:!1})},e.prototype.beginEndTag=function(){this.push({type:"EndTag",tagName:""})},e.prototype.finishTag=function(){this.addLocInfo()},e.prototype.markTagAsSelfClosing=function(){this.current("StartTag").selfClosing=!0},e.prototype.appendToTagName=function(e){this.current("StartTag","EndTag").tagName+=e},e.prototype.beginAttribute=function(){this._currentAttribute=["","",!1]},e.prototype.appendToAttributeName=function(e){this.currentAttribute()[0]+=e},e.prototype.beginAttributeValue=function(e){this.currentAttribute()[2]=e},e.prototype.appendToAttributeValue=function(e){this.currentAttribute()[1]+=e},e.prototype.finishAttributeValue=function(){this.current("StartTag").attributes.push(this._currentAttribute)},e.prototype.reportSyntaxError=function(e){this.current().syntaxError=e},e}();var At=r(71);function Et(){function e(e){return function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),a=1;a<r;a++)n[a-1]=arguments[a];return e.apply(void 0,["Block validation: "+t].concat(n))}}return{error:e(console.error),warning:e(console.warn),getItems:function(){return[]}}}function Bt(){var e=[],t=Et();return{error:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];e.push({log:t.error,args:n})},warning:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];e.push({log:t.warning,args:n})},getItems:function(){return e}}}var Nt=r(73),Lt=r.n(Nt);function Mt(){return(Mt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e}).apply(this,arguments)}var zt=r(10),Dt=Object(fe.createContext)((function(){})),Ht=Dt.Consumer,It=Dt.Provider,Vt=Object(zt.createHigherOrderComponent)((function(e){return function(t){return Object(fe.createElement)(Ht,null,(function(r){return Object(fe.createElement)(e,Mt({},t,{BlockContent:r}))}))}}),"withBlockContentContext"),Rt=function(e){var t=e.children,r=e.innerBlocks;return Object(fe.createElement)(It,{value:function(){var e=Jt(r,{isInnerBlocks:!0});return Object(fe.createElement)(fe.RawHTML,null,e)}},t)};function Ft(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function $t(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ft(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ft(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function qt(e){var t="wp-block-"+e.replace(/\//,"-").replace(/^core-/,"");return Object(se.applyFilters)("blocks.getBlockDefaultClassName",t,e)}function Ut(e){var t="editor-block-list-item-"+e.replace(/\//,"-").replace(/^core-/,"");return Object(se.applyFilters)("blocks.getBlockMenuDefaultClassName",t,e)}var Gt={};function Kt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=Gt.blockType,r=Gt.attributes;return Object(se.applyFilters)("blocks.getSaveContent.extraProps",$t({},e),t,r)}function Wt(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],n=ve(e),a=n.save;if(a.prototype instanceof fe.Component){var o=new a({attributes:t});a=o.render.bind(o)}Gt.blockType=n,Gt.attributes=t;var i=a({attributes:t,innerBlocks:r});if(Object(f.isObject)(i)&&Object(se.hasFilter)("blocks.getSaveContent.extraProps")&&!n.apiVersion){var s=Object(se.applyFilters)("blocks.getSaveContent.extraProps",$t({},i.props),n,t);Lt()(s,i.props)||(i=Object(fe.cloneElement)(i,s))}return i=Object(se.applyFilters)("blocks.getSaveElement",i,n,t),Object(fe.createElement)(Rt,{innerBlocks:r},i)}function Yt(e,t,r){var n=ve(e);return Object(fe.renderToString)(Wt(n,t,r))}function Zt(e,t){return Object(f.reduce)(e.attributes,(function(e,r,n){var a=t[n];return void 0===a||void 0!==r.source||"default"in r&&r.default===a||(e[n]=a),e}),{})}function Qt(e){var t=e.originalContent;if(e.isValid||e.innerBlocks.length)try{t=Yt(e.name,e.attributes,e.innerBlocks)}catch(e){}return t}function Xt(e,t,r){var n=Object(f.isEmpty)(t)?"":function(e){return JSON.stringify(e).replace(/--/g,"\\u002d\\u002d").replace(/</g,"\\u003c").replace(/>/g,"\\u003e").replace(/&/g,"\\u0026").replace(/\\"/g,"\\u0022")}(t)+" ",a=Object(f.startsWith)(e,"core/")?e.slice(5):e;return r?"\x3c!-- wp:".concat(a," ").concat(n,"--\x3e\n")+r+"\n\x3c!-- /wp:".concat(a," --\x3e"):"\x3c!-- wp:".concat(a," ").concat(n,"/--\x3e")}function Jt(e,t){return Object(f.castArray)(e).map((function(e){return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.isInnerBlocks,n=void 0!==r&&r,a=e.name,o=Qt(e);if(a===ze()||!n&&a===Ne())return o;var i=Ve(a),s=Zt(i,e.attributes);return Xt(a,s,o)}(e,t)})).join("\n\n")}function er(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}var tr=/[\t\n\r\v\f ]+/g,rr=/^[\t\n\r\v\f ]*$/,nr=/^url\s*\(['"\s]*(.*?)['"\s]*\)$/,ar=["allowfullscreen","allowpaymentrequest","allowusermedia","async","autofocus","autoplay","checked","controls","default","defer","disabled","download","formnovalidate","hidden","ismap","itemscope","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected","typemustmatch"],or=[].concat(ar,["autocapitalize","autocomplete","charset","contenteditable","crossorigin","decoding","dir","draggable","enctype","formenctype","formmethod","http-equiv","inputmode","kind","method","preload","scope","shape","spellcheck","translate","type","wrap"]),ir=[f.identity,function(e){return fr(e).join(" ")}],sr=/^[\da-z]+$/i,cr=/^#\d+$/,lr=/^#x[\da-f]+$/i;var ur=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,r,n;return t=e,(r=[{key:"parse",value:function(e){if(t=e,sr.test(t)||cr.test(t)||lr.test(t))return Object(At.decodeEntities)("&"+e+";");var t}}])&&vt(t.prototype,r),n&&vt(t,n),e}();function fr(e){return e.trim().split(tr)}function dr(e){return e.attributes.filter((function(e){var t=oe(e,2),r=t[0];return t[1]||0===r.indexOf("data-")||Object(f.includes)(or,r)}))}function pr(e,t){for(var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et(),n=e.chars,a=t.chars,o=0;o<ir.length;o++){var i=ir[o];if((n=i(n))===(a=i(a)))return!0}return r.warning("Expected text `%s`, saw `%s`.",t.chars,e.chars),!1}function hr(e){return e.replace(nr,"url($1)")}function gr(e){var t=e.replace(/;?\s*$/,"").split(";").map((function(e){var t,r=e.split(":"),n=ne(t=r)||s(t)||c(t)||ae(),a=n[0],o=n.slice(1).join(":");return[a.trim(),hr(o.trim())]}));return Object(f.fromPairs)(t)}var br=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?er(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):er(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({class:function(e,t){return!f.xor.apply(void 0,l([e,t].map(fr))).length},style:function(e,t){return f.isEqual.apply(void 0,l([e,t].map(gr)))}},Object(f.fromPairs)(ar.map((function(e){return[e,f.stubTrue]}))));function mr(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et();if(e.length!==t.length)return r.warning("Expected attributes %o, instead saw %o.",t,e),!1;for(var n={},a=0;a<t.length;a++)n[t[a][0].toLowerCase()]=t[a][1];for(var o=0;o<e.length;o++){var i=oe(e[o],2),s=i[0],c=i[1],l=s.toLowerCase();if(!n.hasOwnProperty(l))return r.warning("Encountered unexpected attribute `%s`.",s),!1;var u=n[l],f=br[l];if(f){if(!f(c,u))return r.warning("Expected attribute `%s` of value `%s`, saw `%s`.",s,u,c),!1}else if(c!==u)return r.warning("Expected attribute `%s` of value `%s`, saw `%s`.",s,u,c),!1}return!0}var _r={StartTag:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et();return e.tagName!==t.tagName&&e.tagName.toLowerCase()!==t.tagName.toLowerCase()?(r.warning("Expected tag name `%s`, instead saw `%s`.",t.tagName,e.tagName),!1):mr.apply(void 0,l([e,t].map(dr)).concat([r]))},Chars:pr,Comment:pr};function vr(e){for(var t;t=e.shift();){if("Chars"!==t.type)return t;if(!rr.test(t.chars))return t}}function wr(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Et();try{return new St(new ur).tokenize(e)}catch(r){t.warning("Malformed HTML detected: %s",e)}return null}function yr(e,t){return!!e.selfClosing&&!(!t||t.tagName!==e.tagName||"EndTag"!==t.type)}function kr(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et();if(e===t)return!0;var n,a,o=[e,t].map((function(e){return wr(e,r)})),i=oe(o,2),s=i[0],c=i[1];if(!s||!c)return!1;for(;n=vr(s);){if(!(a=vr(c)))return r.warning("Expected end of content, instead saw %o.",n),!1;if(n.type!==a.type)return r.warning("Expected token of type `%s` (%o), instead saw `%s` (%o).",a.type,a,n.type,n),!1;var l=_r[n.type];if(l&&!l(n,a,r))return!1;yr(n,c[0])?vr(c):yr(a,s[0])&&vr(s)}return!(a=vr(c))||(r.warning("Expected %o, instead saw end of content.",a),!1)}function Or(e,t,r){var n,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:Bt(),o=ve(e);try{n=Yt(o,t)}catch(e){return a.error("Block validation failed because an error occurred while generating block content:\n\n%s",e.toString()),{isValid:!1,validationIssues:a.getItems()}}var i=kr(r,n,a);return i||a.error("Block validation failed for `%s` (%o).\n\nContent generated by `save` function:\n\n%s\n\nContent retrieved from post body:\n\n%s",o.name,o,n,r),{isValid:i,validationIssues:a.getItems()}}function jr(e,t,r){return Or(e,t,r,Et()).isValid}function Cr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function xr(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Cr(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Cr(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function Tr(e){for(var t={},r=0;r<e.length;r++){var n=e[r],a=n.name,o=n.value;t[a]=o}return t}function Pr(e){if(e.nodeType===e.TEXT_NODE)return e.nodeValue;if(e.nodeType!==e.ELEMENT_NODE)throw new TypeError("A block node can only be created from a node of type text or element.");return{type:e.nodeName.toLowerCase(),props:xr(xr({},Tr(e.attributes)),{},{children:Er(e.childNodes)})}}function Sr(e){return function(t){var r=t;e&&(r=t.querySelector(e));try{return Pr(r)}catch(e){return null}}}var Ar={isNodeOfType:function(e,t){return e&&e.type===t},fromDOM:Pr,toHTML:function(e){return Br([e])},matcher:Sr};function Er(e){for(var t=[],r=0;r<e.length;r++)try{t.push(Pr(e[r]))}catch(e){}return t}function Br(e){var t=e;return Object(fe.renderToString)(t)}function Nr(e){return function(t){var r=t;return e&&(r=t.querySelector(e)),r?Er(r.childNodes):[]}}var Lr={concat:function(){for(var e=[],t=0;t<arguments.length;t++)for(var r=Object(f.castArray)(t<0||arguments.length<=t?void 0:arguments[t]),n=0;n<r.length;n++){var a=r[n],o="string"==typeof a&&"string"==typeof e[e.length-1];o?e[e.length-1]+=a:e.push(a)}return e},getChildrenArray:function(e){return e},fromDOM:Er,toHTML:Br,matcher:Nr};function Mr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function zr(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Mr(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Mr(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}new Set(["attribute","html","text","tag"]);function Dr(e,t){return t.some((function(t){return function(e,t){switch(t){case"string":return"string"==typeof e;case"boolean":return"boolean"==typeof e;case"object":return!!e&&e.constructor===Object;case"null":return null===e;case"array":return Array.isArray(e);case"integer":case"number":return"number"==typeof e}return!0}(e,t)}))}function Hr(e){switch(e.source){case"attribute":var t=function(e,t){return 1===arguments.length&&(t=e,e=void 0),function(r){var n=bt(e,"attributes")(r);if(n&&n.hasOwnProperty(t))return n[t].value}}(e.selector,e.attribute);return"boolean"===e.type&&(t=function(e){return Object(f.flow)([e,function(e){return void 0!==e}])}(t)),t;case"html":return n=e.selector,a=e.multiline,function(e){var t=e;if(n&&(t=e.querySelector(n)),!t)return"";if(a){for(var r="",o=t.children.length,i=0;i<o;i++){var s=t.children[i];s.nodeName.toLowerCase()===a&&(r+=s.outerHTML)}return r}return t.innerHTML};case"text":return function(e){return bt(e,"textContent")}(e.selector);case"children":return Nr(e.selector);case"node":return Sr(e.selector);case"query":var r=Object(f.mapValues)(e.query,Hr);return function(e,t){return function(r){var n=r.querySelectorAll(e);return[].map.call(n,(function(e){return gt(e,t)}))}}(e.selector,r);case"tag":return Object(f.flow)([bt(e.selector,"nodeName"),function(e){return e?e.toLowerCase():void 0}]);default:console.error('Unknown source type "'.concat(e.source,'"'))}var n,a}function Ir(e,t){return gt(e,Hr(t))}function Vr(e,t,r,n){var a,o=t.type,i=t.enum;switch(t.source){case void 0:a=n?n[e]:void 0;break;case"attribute":case"property":case"html":case"text":case"children":case"node":case"query":case"tag":a=Ir(r,t)}return function(e,t){return void 0===t||Dr(e,Object(f.castArray)(t))}(a,o)&&function(e,t){return!Array.isArray(t)||t.includes(e)}(a,i)||(a=void 0),void 0===a?t.default:a}function Rr(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=ve(e),a=Object(f.mapValues)(n.attributes,(function(e,n){return Vr(n,e,t,r)}));return Object(se.applyFilters)("blocks.getBlockAttributes",a,n,t,r)}function Fr(e,t){var r=zr({},t);if("core/cover-image"===e&&(e="core/cover"),"core/text"!==e&&"core/cover-text"!==e||(e="core/paragraph"),e&&0===e.indexOf("core/social-link-")&&(r.service=e.substring(17),e="core/social-link"),e&&0===e.indexOf("core-embed/")){var n=e.substring(11),a={speaker:"speaker-deck",polldaddy:"crowdsignal"};r.providerNameSlug=n in a?a[n]:n,["amazon-kindle","wordpress"].includes(n)||(r.responsive=!0),e="core/embed"}return{name:e,attributes:r}}function $r(e){var t=e.blockName,r=e.attrs,n=e.innerBlocks,a=void 0===n?[]:n,o=e.innerHTML,i=e.innerContent,s=Ne(),c=ze()||s;r=r||{},o=o.trim();var u=t||s,d=Fr(u,r);u=d.name,r=d.attributes,u===s&&(o=Object(mt.autop)(o).trim());var p=Ve(u);if(!p){var h={attrs:r,blockName:t,innerBlocks:a,innerContent:i},g=qr(h,{isCommentDelimited:!1}),b=qr(h,{isCommentDelimited:!0});u&&(o=b),r={originalName:t,originalContent:b,originalUndelimitedContent:g},p=Ve(u=c)}a=(a=a.map($r)).filter((function(e){return e}));var m=u===s||u===c;if(p&&(o||!m)){var _=tt(u,Rr(p,o,r),a);if(!m){var v=Or(p,_.attributes,o),w=v.isValid,y=v.validationIssues;_.isValid=w,_.validationIssues=y}return _.originalContent=_.originalContent||o,(_=function(e,t){var r=Ve(e.name),n=r.deprecated;if(!n||!n.length)return e;for(var a=e,o=a.originalContent,i=a.innerBlocks,s=0;s<n.length;s++){var c=n[s].isEligible,u=void 0===c?f.stubFalse:c;if(!e.isValid||u(t,i)){var d=Object.assign(Object(f.omit)(r,ke),n[s]),p=Rr(d,o,t),h=Or(d,p,o),g=h.isValid,b=h.validationIssues;if(g){var m=i,_=d.migrate;if(_){var v=oe(Object(f.castArray)(_(p,i)),2),w=v[0];p=void 0===w?t:w;var y=v[1];m=void 0===y?i:y}e=zr(zr({},e),{},{attributes:p,innerBlocks:m,isValid:!0})}else e=zr(zr({},e),{},{validationIssues:[].concat(l(Object(f.get)(e,"validationIssues",[])),l(b))})}}return e}(_,r)).validationIssues&&_.validationIssues.length>0&&(_.isValid?console.info("Block successfully updated for `%s` (%o).\n\nNew content generated by `save` function:\n\n%s\n\nContent retrieved from post body:\n\n%s",p.name,p,Yt(p,_.attributes),_.originalContent):_.validationIssues.forEach((function(e){var t=e.log,r=e.args;return t.apply(void 0,l(r))}))),_}}function qr(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.isCommentDelimited,n=void 0===r||r,a=e.blockName,o=e.attrs,i=void 0===o?{}:o,s=e.innerBlocks,c=void 0===s?[]:s,l=e.innerContent,u=void 0===l?[]:l,f=0,d=u.map((function(e){return null!==e?e:qr(c[f++],t)})).join("\n").replace(/\n+/g,"\n").trim();return n?Xt(a,i,d):d}var Ur,Gr=(Ur=_t.parse,function(e){return Ur(e).reduce((function(e,t){var r=$r(t);return r&&e.push(r),e}),[])}),Kr=Gr;function Wr(e){var t=document.implementation.createHTMLDocument(""),r=document.implementation.createHTMLDocument(""),n=t.body,a=r.body;for(n.innerHTML=e;n.firstChild;){var o=n.firstChild;o.nodeType===o.TEXT_NODE?o.nodeValue.trim()?(a.lastChild&&"P"===a.lastChild.nodeName||a.appendChild(r.createElement("P")),a.lastChild.appendChild(o)):n.removeChild(o):o.nodeType===o.ELEMENT_NODE?"BR"===o.nodeName?(o.nextSibling&&"BR"===o.nextSibling.nodeName&&(a.appendChild(r.createElement("P")),n.removeChild(o.nextSibling)),a.lastChild&&"P"===a.lastChild.nodeName&&a.lastChild.hasChildNodes()?a.lastChild.appendChild(o):n.removeChild(o)):"P"===o.nodeName?Object(de.isEmpty)(o)?n.removeChild(o):a.appendChild(o):Object(de.isPhrasingContent)(o)?(a.lastChild&&"P"===a.lastChild.nodeName||a.appendChild(r.createElement("P")),a.lastChild.appendChild(o)):a.appendChild(o):n.removeChild(o)}return a.innerHTML}function Yr(e,t){if(e.nodeType===e.COMMENT_NODE)if("nextpage"!==e.nodeValue){i
|