WordPress/wp-includes/js/dist/token-list.min.js
Peter Wilson 5a721be794 Build: Use hashed/deterministic moduleIDs in webpack config
Props peterwilsoncc, desrosj, gziolo.
Merges [50940] in to the 5.7 branch.
Fixes #53192.


Built from https://develop.svn.wordpress.org/branches/5.7@50990


git-svn-id: http://core.svn.wordpress.org/branches/5.7@50599 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-05-25 05:22:08 +00:00

2 lines
3.8 KiB
JavaScript

/*! This file is auto-generated */
this.wp=this.wp||{},this.wp.tokenList=function(e){var t={};function r(n){if(t[n])return t[n].exports;var u=t[n]={i:n,l:!1,exports:{}};return e[n].call(u.exports,u,u.exports,r),u.l=!0,u.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var u in e)r.d(n,u,function(t){return e[t]}.bind(null,u));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s="./node_modules/@wordpress/token-list/build-module/index.js")}({"./node_modules/@babel/runtime/helpers/esm/classCallCheck.js":function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}r.d(t,"a",(function(){return n}))},"./node_modules/@babel/runtime/helpers/esm/createClass.js":function(e,t,r){"use strict";function n(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)}}function u(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),e}r.d(t,"a",(function(){return u}))},"./node_modules/@wordpress/token-list/build-module/index.js":function(e,t,r){"use strict";r.r(t),r.d(t,"default",(function(){return s}));var n=r("@babel/runtime/regenerator"),u=r.n(n),a=r("./node_modules/@babel/runtime/helpers/esm/classCallCheck.js"),o=r("./node_modules/@babel/runtime/helpers/esm/createClass.js"),i=r("lodash"),s=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";Object(a.a)(this,e),this.value=t,this._currentValue,this._valueAsArray}return Object(o.a)(e,[{key:"entries",value:function(){var e;return(e=this._valueAsArray).entries.apply(e,arguments)}},{key:"forEach",value:function(){var e;return(e=this._valueAsArray).forEach.apply(e,arguments)}},{key:"keys",value:function(){var e;return(e=this._valueAsArray).keys.apply(e,arguments)}},{key:"values",value:function(){var e;return(e=this._valueAsArray).values.apply(e,arguments)}},{key:"toString",value:function(){return this.value}},{key:Symbol.iterator,value:u.a.mark((function e(){return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.delegateYield(this._valueAsArray,"t0",1);case 1:return e.abrupt("return",e.t0);case 2:case"end":return e.stop()}}),e,this)}))},{key:"item",value:function(e){return this._valueAsArray[e]}},{key:"contains",value:function(e){return-1!==this._valueAsArray.indexOf(e)}},{key:"add",value:function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];this.value+=" "+t.join(" ")}},{key:"remove",value:function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];this.value=i.without.apply(void 0,[this._valueAsArray].concat(t)).join(" ")}},{key:"toggle",value:function(e,t){return void 0===t&&(t=!this.contains(e)),t?this.add(e):this.remove(e),t}},{key:"replace",value:function(e,t){return!!this.contains(e)&&(this.remove(e),this.add(t),!0)}},{key:"supports",value:function(){return!0}},{key:"value",get:function(){return this._currentValue},set:function(e){e=String(e),this._valueAsArray=Object(i.uniq)(Object(i.compact)(e.split(/\s+/g))),this._currentValue=this._valueAsArray.join(" ")}},{key:"length",get:function(){return this._valueAsArray.length}}]),e}()},"@babel/runtime/regenerator":function(e,t){e.exports=window.regeneratorRuntime},lodash:function(e,t){e.exports=window.lodash}}).default;