WordPress/wp-includes/js/dist/compose.min.js

1 line
8.2 KiB
JavaScript
Raw Normal View History

this.wp=this.wp||{},this.wp.compose=function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="PD33")}({"1OyB":function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}n.d(e,"a",(function(){return r}))},GRId:function(t,e){!function(){t.exports=this.wp.element}()},JX7q:function(t,e,n){"use strict";function r(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}n.d(e,"a",(function(){return r}))},Ji7U:function(t,e,n){"use strict";function r(t,e){return(r=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&r(t,e)}n.d(e,"a",(function(){return o}))},PD33:function(t,e,n){"use strict";n.r(e),n.d(e,"createHigherOrderComponent",(function(){return o})),n.d(e,"ifCondition",(function(){return u})),n.d(e,"pure",(function(){return h})),n.d(e,"withGlobalEvents",(function(){return j})),n.d(e,"withInstanceId",(function(){return m})),n.d(e,"withSafeTimeout",(function(){return v})),n.d(e,"withState",(function(){return w})),n.d(e,"compose",(function(){return r.flowRight}));var r=n("YLtl");var o=function(t,e){return function(n){var o=t(n),i=n.displayName,u=void 0===i?n.name||"Component":i;return o.displayName="".concat(Object(r.upperFirst)(Object(r.camelCase)(e)),"(").concat(u,")"),o}},i=n("GRId"),u=function(t){return o((function(e){return function(n){return t(n)?Object(i.createElement)(e,n):null}}),"ifCondition")},c=n("1OyB"),a=n("vuIU"),s=n("md7G"),f=n("foSv"),l=n("Ji7U"),p=n("rl8x"),b=n.n(p),h=o((function(t){return t.prototype instanceof i.Component?function(t){function e(){return Object(c.a)(this,e),Object(s.a)(this,Object(f.a)(e).apply(this,arguments))}return Object(l.a)(e,t),Object(a.a)(e,[{key:"shouldComponentUpdate",value:function(t,e){return!b()(t,this.props)||!b()(e,this.state)}}]),e}(t):function(e){function n(){return Object(c.a)(this,n),Object(s.a)(this,Object(f.a)(n).apply(this,arguments))}return Object(l.a)(n,e),Object(a.a)(n,[{key:"shouldComponentUpdate",value:function(t){return!b()(t,this.props)}},{key:"render",value:function(){return Object(i.createElement)(t,this.props)}}]),n}(i.Component)}),"pure"),d=n("wx14"),O=n("JX7q"),y=new(function(){function t(){Object(c.a)(this,t),this.listeners={},this.handleEvent=this.handleEvent.bind(this)}return Object(a.a)(t,[{key:"add",value:function(t,e){this.listeners[t]||(window.addEventListener(t,this.handleEvent),this.listeners[t]=[]),this.listeners[t].push(e)}},{key:"remove",value:function(t,e){this.listeners[t]=Object(r.without)(this.listeners[t],e),this.listeners[t].length||(window.removeEventListener(t,this.handleEvent),delete this.listeners[t])}},{key:"handleEvent",value:function(t){Object(r.forEach)(this.listeners[t.type],(function(e){e.handleEvent(t)}))}}]),t}());var j=function(t){return o((function(e){var n=function(n){function o(){var t;return Object(c.a)(this,o),(t=Object(s.a)(this,Object(f.a)(o).apply(this,arguments))).handleEvent=t.handleEvent.bind(Object(O.a)(Object(O.a)(t))),t.handl