WordPress/wp-includes/js/dist/core-data.min.js

2 lines
55 KiB
JavaScript
Raw Normal View History

/*! This file is auto-generated */
!function(){"use strict";var e={5360:function(e,t,n){n.d(t,{createUndoManager:function(){return a}});var r=n(9127),i=n.n(r);function s(e,t){const n={...e};return Object.entries(t).forEach((([e,t])=>{n[e]?n[e]={...n[e],to:t.to}:n[e]=t})),n}const o=(e,t)=>{const n=e?.findIndex((({id:e})=>"string"==typeof e?e===t.id:i()(e,t.id))),r=[...e];return-1!==n?r[n]={id:t.id,changes:s(r[n].changes,t.changes)}:r.push(t),r};function a(){let e=[],t=[],n=0;const r=()=>{e=e.slice(0,n||void 0),n=0},s=()=>{var n;const r=0===e.length?0:e.length-1;let i=null!==(n=e[r])&&void 0!==n?n:[];t.forEach((e=>{i=o(i,e)})),t=[],e[r]=i};return{addRecord(n,a=!1){const c=!n||(e=>!e.filter((({changes:e})=>Object.values(e).some((({from:e,to:t})=>"function"!=typeof e&&"function"!=typeof t&&!i()(e,t))))).length)(n);if(a){if(c)return;n.forEach((e=>{t=o(t,e)}))}else{if(r(),t.length&&s(),c)return;e.push(n)}},undo(){t.length&&(r(),s());const i=e[e.length-1+n];if(i)return n-=1,i},redo(){const t=e[e.length+n];if(t)return n+=1,t},hasUndo(){return!!e[e.length-1+n]},hasRedo(){return!!e[e.length+n]}}}},2167:function(e){function t(e){return t="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},t(e)}function n(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 r(e,t){var n=e._map,r=e._arrayTreeMap,i=e._objectTreeMap;if(n.has(t))return n.get(t);for(var s=Object.keys(t).sort(),o=Array.isArray(t)?r:i,a=0;a<s.length;a++){var c=s[a];if(void 0===(o=o.get(c)))return;var u=t[c];if(void 0===(o=o.get(u)))return}var l=o.get("_ekm_value");return l?(n.delete(l[0]),l[0]=t,o.set("_ekm_value",l),n.set(t,l),l):void 0}var i=function(){function e(t){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.clear(),t instanceof e){var n=[];t.forEach((function(e,t){n.push([t,e])})),t=n}if(null!=t)for(var r=0;r<t.length;r++)this.set(t[r][0],t[r][1])}var i,s,o;return i=e,s=[{key:"set",value:function(n,r){if(null===n||"object"!==t(n))return this._map.set(n,r),this;for(var i=Object.keys(n).sort(),s=[n,r],o=Array.isArray(n)?this._arrayTreeMap:this._objectTreeMap,a=0;a<i.length;a++){var c=i[a];o.has(c)||o.set(c,new e),o=o.get(c);var u=n[c];o.has(u)||o.set(u,new e),o=o.get(u)}var l=o.get("_ekm_value");return l&&this._map.delete(l[0]),o.set("_ekm_value",s),this._map.set(n,s),this}},{key:"get",value:function(e){if(null===e||"object"!==t(e))return this._map.get(e);var n=r(this,e);return n?n[1]:void 0}},{key:"has",value:function(e){return null===e||"object"!==t(e)?this._map.has(e):void 0!==r(this,e)}},{key:"delete",value:function(e){return!!this.has(e)&&(this.set(e,void 0),!0)}},{key:"forEach",value:function(e){var n=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this;this._map.forEach((function(i,s){null!==s&&"object"===t(s)&&(i=i[1]),e.call(r,i,s,n)}))}},{key:"clear",value:function(){this._map=new Map,this._arrayTreeMap=new Map,this._objectTreeMap=new Map}},{key:"size",get:function(){return this._map.size}}],s&&n(i.prototype,s),o&&n(i,o),e}();e.exports=i},5619:function(e){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 r,i,s;if(Array.isArray(t)){if((r=t.length)!=n.length)return!1;for(i=r;0!=i--;)if(!e(t[i],n[i]))return!1;return!0}if(t instanceof Map&&n instanceof Map){if(t.size!==n.size)return!1;for(i of t.entries())if(!n.has(i[0]))return!1;for(i of t.entries())if(!e(i[1],n.get(i[0])))return!1;return!0}if(t instanceof Set&&n instanceof Set){if(t.size!==n.size)return!1;for(i of t.entries())if(!n.has(i[0]))return!1;return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(n)){if((r=t.length)!=n.length)return!1;for(i=r;0!=i--;)if(t[i]!==n[i])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.val