WordPress/wp-includes/js/dist/block-library.min.js

14 lines
821 KiB
JavaScript
Raw Normal View History

/*! This file is auto-generated */
(()=>{var e={2321:e=>{e.exports=function(e){return e&&"__experimental"in e&&!1!==e.__experimental}},1668:(e,t)=>{var n;
/*!
Editor: Sync changes from the Gutenberg plugin 14.1 release Updated WordPress packages necessary for releasing WordPress 6.1 Beta 1: - @wordpress/a11y@3.17.1 - @wordpress/annotations@2.17.2 - @wordpress/api-fetch@6.14.1 - @wordpress/autop@3.17.1 - @wordpress/babel-plugin-import-jsx-pragma@4.0.1 - @wordpress/babel-plugin-makepot@5.1.1 - @wordpress/babel-preset-default@7.1.1 - @wordpress/base-styles@4.8.1 - @wordpress/blob@3.17.1 - @wordpress/block-directory@3.15.2 - @wordpress/block-editor@10.0.2 - @wordpress/block-library@7.14.2 - @wordpress/block-serialization-default-parser@4.17.1 - @wordpress/block-serialization-spec-parser@4.17.1 - @wordpress/blocks@11.16.2 - @wordpress/browserslist-config@5.0.1 - @wordpress/components@21.0.2 - @wordpress/compose@5.15.2 - @wordpress/core-data@5.0.2 - @wordpress/create-block-tutorial-template@2.5.1 - @wordpress/create-block@4.1.1 - @wordpress/custom-templated-path-webpack-plugin@2.1.3 - @wordpress/customize-widgets@3.14.2 - @wordpress/data-controls@2.17.2 - @wordpress/data@7.1.2 - @wordpress/date@4.17.1 - @wordpress/dependency-extraction-webpack-plugin@4.0.2 - @wordpress/deprecated@3.17.1 - @wordpress/docgen@1.26.1 - @wordpress/dom-ready@3.17.1 - @wordpress/dom@3.17.2 - @wordpress/e2e-test-utils@8.1.1 - @wordpress/e2e-tests@5.1.2 - @wordpress/edit-post@6.14.2 - @wordpress/edit-site@4.14.2 - @wordpress/edit-widgets@4.14.2 - @wordpress/editor@12.16.2 - @wordpress/element@4.15.1 - @wordpress/env@5.2.1 - @wordpress/escape-html@2.17.1 - @wordpress/eslint-plugin@13.1.1 - @wordpress/format-library@3.15.2 - @wordpress/hooks@3.17.1 - @wordpress/html-entities@3.17.1 - @wordpress/i18n@4.17.1 - @wordpress/icons@9.8.1 - @wordpress/interface@4.16.2 - @wordpress/is-shallow-equal@4.17.1 - @wordpress/jest-console@6.0.1 - @wordpress/jest-preset-default@9.0.1 - @wordpress/jest-puppeteer-axe@5.0.1 - @wordpress/keyboard-shortcuts@3.15.2 - @wordpress/keycodes@3.17.1 - @wordpress/lazy-import@1.4.3 - @wordpress/library-export-default-webpack-plugin@2.3.3 - @wordpress/list-reusable-blocks@3.15.2 - @wordpress/media-utils@4.8.1 - @wordpress/notices@3.17.2 - @wordpress/npm-package-json-lint-config@4.2.1 - @wordpress/nux@5.15.2 - @wordpress/plugins@4.15.2 - @wordpress/postcss-plugins-preset@4.1.1 - @wordpress/postcss-themes@5.0.1 - @wordpress/preferences-persistence@1.9.1 - @wordpress/preferences@2.9.2 - @wordpress/prettier-config@2.0.1 - @wordpress/primitives@3.15.1 - @wordpress/priority-queue@2.17.2 - @wordpress/project-management-automation@1.16.1 - @wordpress/react-i18n@3.15.1 - @wordpress/readable-js-assets-webpack-plugin@2.0.1 - @wordpress/redux-routine@4.17.1 - @wordpress/reusable-blocks@3.15.2 - @wordpress/rich-text@5.15.2 - @wordpress/scripts@24.1.2 - @wordpress/server-side-render@3.15.2 - @wordpress/shortcode@3.17.1 - @wordpress/style-engine@1.0.1 - @wordpress/stylelint-config@21.0.1 - @wordpress/token-list@2.17.1 - @wordpress/url@3.18.1 - @wordpress/viewport@4.15.2 - @wordpress/warning@2.17.1 - @wordpress/widgets@2.15.2 - @wordpress/wordcount@3.17.1 Props bernhard-reiter, cbravobernal, czapla, oandregal, isabel_brison, andrewserong, mciampini. See #56467. Built from https://develop.svn.wordpress.org/trunk@54257 git-svn-id: http://core.svn.wordpress.org/trunk@53816 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2022-09-20 17:43:29 +02:00
Copyright (c) 2018 Jed Watson.
Licensed under the MIT License (MIT), see
http://jedwatson.github.io/classnames
*/!function(){"use strict";var a=function(){function e(){}function t(e,t){for(var n=t.length,a=0;a<n;++a)o(e,t[a])}e.prototype=Object.create(null);var n={}.hasOwnProperty;var a=/\s+/;function o(e,o){if(o){var r=typeof o;"string"===r?function(e,t){for(var n=t.split(a),o=n.length,r=0;r<o;++r)e[n[r]]=!0}(e,o):Array.isArray(o)?t(e,o):"object"===r?function(e,t){if(t.toString===Object.prototype.toString||t.toString.toString().includes("[native code]"))for(var a in t)n.call(t,a)&&(e[a]=!!t[a]);else e[t.toString()]=!0}(e,o):"number"===r&&function(e,t){e[t]=!0}(e,o)}}return function(){for(var n=arguments.length,a=Array(n),o=0;o<n;o++)a[o]=arguments[o];var r=new e;t(r,a);var l=[];for(var i in r)r[i]&&l.push(i);return l.join(" ")}}();e.exports?(a.default=a,e.exports=a):void 0===(n=function(){return a}.apply(t,[]))||(e.exports=n)}()},5755:(e,t)=>{var n;
/*!
Editor: Sync changes from the Gutenberg plugin 14.1 release Updated WordPress packages necessary for releasing WordPress 6.1 Beta 1: - @wordpress/a11y@3.17.1 - @wordpress/annotations@2.17.2 - @wordpress/api-fetch@6.14.1 - @wordpress/autop@3.17.1 - @wordpress/babel-plugin-import-jsx-pragma@4.0.1 - @wordpress/babel-plugin-makepot@5.1.1 - @wordpress/babel-preset-default@7.1.1 - @wordpress/base-styles@4.8.1 - @wordpress/blob@3.17.1 - @wordpress/block-directory@3.15.2 - @wordpress/block-editor@10.0.2 - @wordpress/block-library@7.14.2 - @wordpress/block-serialization-default-parser@4.17.1 - @wordpress/block-serialization-spec-parser@4.17.1 - @wordpress/blocks@11.16.2 - @wordpress/browserslist-config@5.0.1 - @wordpress/components@21.0.2 - @wordpress/compose@5.15.2 - @wordpress/core-data@5.0.2 - @wordpress/create-block-tutorial-template@2.5.1 - @wordpress/create-block@4.1.1 - @wordpress/custom-templated-path-webpack-plugin@2.1.3 - @wordpress/customize-widgets@3.14.2 - @wordpress/data-controls@2.17.2 - @wordpress/data@7.1.2 - @wordpress/date@4.17.1 - @wordpress/dependency-extraction-webpack-plugin@4.0.2 - @wordpress/deprecated@3.17.1 - @wordpress/docgen@1.26.1 - @wordpress/dom-ready@3.17.1 - @wordpress/dom@3.17.2 - @wordpress/e2e-test-utils@8.1.1 - @wordpress/e2e-tests@5.1.2 - @wordpress/edit-post@6.14.2 - @wordpress/edit-site@4.14.2 - @wordpress/edit-widgets@4.14.2 - @wordpress/editor@12.16.2 - @wordpress/element@4.15.1 - @wordpress/env@5.2.1 - @wordpress/escape-html@2.17.1 - @wordpress/eslint-plugin@13.1.1 - @wordpress/format-library@3.15.2 - @wordpress/hooks@3.17.1 - @wordpress/html-entities@3.17.1 - @wordpress/i18n@4.17.1 - @wordpress/icons@9.8.1 - @wordpress/interface@4.16.2 - @wordpress/is-shallow-equal@4.17.1 - @wordpress/jest-console@6.0.1 - @wordpress/jest-preset-default@9.0.1 - @wordpress/jest-puppeteer-axe@5.0.1 - @wordpress/keyboard-shortcuts@3.15.2 - @wordpress/keycodes@3.17.1 - @wordpress/lazy-import@1.4.3 - @wordpress/library-export-default-webpack-plugin@2.3.3 - @wordpress/list-reusable-blocks@3.15.2 - @wordpress/media-utils@4.8.1 - @wordpress/notices@3.17.2 - @wordpress/npm-package-json-lint-config@4.2.1 - @wordpress/nux@5.15.2 - @wordpress/plugins@4.15.2 - @wordpress/postcss-plugins-preset@4.1.1 - @wordpress/postcss-themes@5.0.1 - @wordpress/preferences-persistence@1.9.1 - @wordpress/preferences@2.9.2 - @wordpress/prettier-config@2.0.1 - @wordpress/primitives@3.15.1 - @wordpress/priority-queue@2.17.2 - @wordpress/project-management-automation@1.16.1 - @wordpress/react-i18n@3.15.1 - @wordpress/readable-js-assets-webpack-plugin@2.0.1 - @wordpress/redux-routine@4.17.1 - @wordpress/reusable-blocks@3.15.2 - @wordpress/rich-text@5.15.2 - @wordpress/scripts@24.1.2 - @wordpress/server-side-render@3.15.2 - @wordpress/shortcode@3.17.1 - @wordpress/style-engine@1.0.1 - @wordpress/stylelint-config@21.0.1 - @wordpress/token-list@2.17.1 - @wordpress/url@3.18.1 - @wordpress/viewport@4.15.2 - @wordpress/warning@2.17.1 - @wordpress/widgets@2.15.2 - @wordpress/wordcount@3.17.1 Props bernhard-reiter, cbravobernal, czapla, oandregal, isabel_brison, andrewserong, mciampini. See #56467. Built from https://develop.svn.wordpress.org/trunk@54257 git-svn-id: http://core.svn.wordpress.org/trunk@53816 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2022-09-20 17:43:29 +02:00
Copyright (c) 2018 Jed Watson.
Licensed under the MIT License (MIT), see
http://jedwatson.github.io/classnames
*/!function(){"use strict";var a={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var r=typeof n;if("string"===r||"number"===r)e.push(n);else if(Array.isArray(n)){if(n.length){var l=o.apply(null,n);l&&e.push(l)}}else if("object"===r){if(n.toString!==Object.prototype.toString&&!n.toString.toString().includes("[native code]")){e.push(n.toString());continue}for(var i in n)a.call(n,i)&&n[i]&&e.push(i)}}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(n=function(){return o}.apply(t,[]))||(e.exports=n)}()},7734:e=>{"use strict";e.exports=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){if(t.constructor!==n.constructor)return!1;var a,o,r;if(Array.isArray(t)){if((a=t.length)!=n.length)return!1;for(o=a;0!=o--;)if(!e(t[o],n[o]))return!1;return!0}if(t instanceof Map&&n instanceof Map){if(t.size!==n.size)return!1;for(o of t.entries())if(!n.has(o[0]))return!1;for(o of t.entries())if(!e(o[1],n.get(o[0])))return!1;return!0}if(t instanceof Set&&n instanceof Set){if(t.size!==n.size)return!1;for(o of t.entries())if(!n.has(o[0]))return!1;return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(n)){if((a=t.length)!=n.length)return!1;for(o=a;0!=o--;)if(t[o]!==n[o])return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((a=(r=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(o=a;0!=o--;)if(!Object.prototype.hasOwnProperty.call(n,r[o]))return!1;for(o=a;0!=o--;){var l=r[o];if(!e(t[l],n[l]))return!1}return!0}return t!=t&&n!=n}},9681:e=>{var t={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",:"A",:"A",:"A",:"A",:"A",Æ:"AE",:"A",:"A",Ȃ:"A",:"A",:"A",:"A",:"A",:"A",Ç:"C",:"C",È:"E",É:"E",Ê:"E",Ë:"E",:"E",:"E",:"E",:"E",:"E",Ȇ:"E",:"E",:"E",:"E",:"E",:"E",:"E",Ì:"I",Í:"I",Î:"I",Ï:"I",:"I",Ȋ:"I",:"I",:"I",Ð:"D",Ñ:"N",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",:"O",:"O",:"O",Ȏ:"O",:"O",:"O",:"O",:"O",:"O",:"O",:"O",:"O",:"O",:"O",Ù:"U",Ú:"U",Û:"U",Ü:"U",:"U",:"U",:"U",:"U",:"U",Ý:"Y",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",:"a",:"a",:"a",:"a",:"a",æ:"ae",:"a",:"a",ȃ:"a",:"a",:"a",:"a",:"a",:"a",ç:"c",:"c",è:"e",é:"e",ê:"e",ë:"e",ế:"e",:"e",:"e",:"e",:"e",ȇ:"e",:"e",:"e",:"e",:"e",:"e",:"e",ì:"i",í:"i",î:"i",ï:"i",:"i",ȋ:"i",:"i",:"i",ð:"d",ñ:"n",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",:"o",:"o",:"o",ȏ:"o",:"o",:"o",:"o",:"o",:"o",:"o",:"o",:"o",:"o",:"o",ù:"u",ú:"u",û:"u",ü:"u",:"u",:"u",:"u",:"u",:"u",ý:"y",ÿ:"y",Ā:"A",ā:"a",Ă:"A",ă:"a",Ą:"A",ą:"a",Ć:"C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"x",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Y̆:"Y",y̆:"y",Ź:"Z",ź:"z",Ż:"Z",ż:"z",Ž:"Z",ž:"z",<EFBFBD>
/*! Fast Average Color | © 2022 Denis Seleznev | MIT License | https://github.com/fast-average-color/fast-average-color */
function Jl(e){var t=e.toString(16);return 1===t.length?"0"+t:t}function Xl(e){return"#"+e.map(Jl).join("")}function ei(e){return e?(t=e,Array.isArray(t[0])?e:[e]):[];var t}function ti(e,t,n){for(var a=0;a<n.length;a++)if(ni(e,t,n[a]))return!0;return!1}function ni(e,t,n){switch(n.length){case 3:if(function(e,t,n){if(255!==e[t+3])return!0;if(e[t]===n[0]&&e[t+1]===n[1]&&e[t+2]===n[2])return!0;return!1}(e,t,n))return!0;break;case 4:if(function(e,t,n){if(e[t+3]&&n[3])return e[t]===n[0]&&e[t+1]===n[1]&&e[t+2]===n[2]&&e[t+3]===n[3];return e[t+3]===n[3]}(e,t,n))return!0;break;case 5:if(function(e,t,n){var a=n[0],o=n[1],r=n[2],l=n[3],i=n[4],s=e[t+3],c=ai(s,l,i);if(!l)return c;if(!s&&c)return!0;if(ai(e[t],a,i)&&ai(e[t+1],o,i)&&ai(e[t+2],r,i)&&c)return!0;return!1}(e,t,n))return!0;break;default:return!1}}function ai(e,t,n){return e>=t-n&&e<=t+n}function oi(e,t,n){for(var a={},o=n.ignoredColor,r=n.step,l=[0,0,0,0,0],i=0;i<t;i+=r){var s=e[i],c=e[i+1],m=e[i+2],u=e[i+3];if(!o||!ti(e,i,o)){var p=Math.round(s/24)+","+Math.round(c/24)+","+Math.round(m/24);a[p]?a[p]=[a[p][0]+s*u,a[p][1]+c*u,a[p][2]+m*u,a[p][3]+u,a[p][4]+1]:a[p]=[s*u,c*u,m*u,u,1],l[4]<a[p][4]&&(l=a[p])}}var d=l[0],g=l[1],h=l[2],b=l[3],_=l[4];return b?[Math.round(d/b),Math.round(g/b),Math.round(h/b),Math.round(b/_)]:n.defaultColor}function ri(e,t,n){for(var a=0,o=0,r=0,l=0,i=0,s=n.ignoredColor,c=n.step,m=0;m<t;m+=c){var u=e[m+3],p=e[m]*u,d=e[m+1]*u,g=e[m+2]*u;s&&ti(e,m,s)||(a+=p,o+=d,r+=g,l+=u,i++)}return l?[Math.round(a/l),Math.round(o/l),Math.round(r/l),Math.round(l/i)]:n.defaultColor}function li(e,t,n){for(var a=0,o=0,r=0,l=0,i=0,s=n.ignoredColor,c=n.step,m=0;m<t;m+=c){var u=e[m],p=e[m+1],d=e[m+2],g=e[m+3];s&&ti(e,m,s)||(a+=u*u*g,o+=p*p*g,r+=d*d*g,l+=g,i++)}return l?[Math.round(Math.sqrt(a/l)),Math.round(Math.sqrt(o/l)),Math.round(Math.sqrt(r/l)),Math.round(l/i)]:n.defaultColor}function ii(e){return si(e,"defaultColor",[0,0,0,0])}function si(e,t,n){return void 0===e[t]?n:e[t]}function ci(e){if(ui(e)){var t=e.naturalWidth,n=e.naturalHeight;return e.naturalWidth||-1===e.src.search(/\.svg(\?|$)/i)||(t=n=100),{width:t,height:n}}return function(e){return"undefined"!=typeof HTMLVideoElement&&e instanceof HTMLVideoElement}(e)?{width:e.videoWidth,height:e.videoHeight}:{width:e.width,height:e.height}}function mi(e){return function(e){return"undefined"!=typeof HTMLCanvasElement&&e instanceof HTMLCanvasElement}(e)?"canvas":function(e){return pi&&e instanceof OffscreenCanvas}(e)?"offscreencanvas":function(e){return"undefined"!=typeof ImageBitmap&&e instanceof ImageBitmap}(e)?"imagebitmap":e.src}function ui(e){return"undefined"!=typeof HTMLImageElement&&e instanceof HTMLImageElement}var pi="undefined"!=typeof OffscreenCanvas;var di="undefined"==typeof window;function gi(e){return Error("FastAverageColor: "+e)}function hi(e,t){t||console.error(e)}var bi=function(){function e(){this.canvas=null,this.ctx=null}return e.prototype.getColorAsync=function(e,t){if(!e)return Promise.reject(gi("call .getColorAsync() without resource."));if("string"==typeof e){if("undefined"==typeof Image)return Promise.reject(gi("resource as string is not supported in this environment"));var n=new Image;return n.crossOrigin=t&&t.crossOrigin||"",n.src=e,this.bindImageEvents(n,t)}if(ui(e)&&!e.complete)return this.bindImageEvents(e,t);var a=this.getColor(e,t);return a.error?Promise.reject(a.error):Promise.resolve(a)},e.prototype.getColor=function(e,t){var n=ii(t=t||{});if(!e)return hi(r=gi("call .getColor(null) without resource"),t.silent),this.prepareResult(n,r);var a=function(e,t){var n,a=si(t,"left",0),o=si(t,"top",0),r=si(t,"width",e.width),l=si(t,"height",e.height),i=r,s=l;return"precision"===t.mode||(r>l?(n=r/l,i=100,s=Math.round(i/n)):(n=l/r,s=100,i=Math.round(s/n)),(i>r||s>l||i<10||s<10)&&(i=r,s=l)),{srcLeft:a,srcTop:o,srcWidth:r,srcHeight:l,destWidth:i,destHeight:s}}(ci(e),t);if(!(a.srcWidth&&a.srcHeight&&a.destWidth&&a.destHeight))return hi(r=gi('incorrect sizes for resource "'.concat(mi(e),'"')),t.silent),this.prepareResult(n,r);if(!this.canvas&&(this.canvas=di?pi?new OffscreenCanvas(1,1):null:document.