LocalCDN-Firefox-Chrome-Brave/resources/underscore.js/1.11.0/underscore-min.jsm

6 lines
24 KiB
JavaScript

// Underscore.js 1.11.0
// https://underscorejs.org
// (c) 2009-2020 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
// Underscore may be freely distributed under the MIT license.
var VERSION="1.11.0",root="object"==typeof self&&self.self===self&&self||"object"==typeof global&&global.global===global&&global||Function("return this")()||{},ArrayProto=Array.prototype,ObjProto=Object.prototype,SymbolProto="undefined"!=typeof Symbol?Symbol.prototype:null,push=ArrayProto.push,slice=ArrayProto.slice,toString=ObjProto.toString,hasOwnProperty=ObjProto.hasOwnProperty,supportsArrayBuffer="undefined"!=typeof ArrayBuffer,nativeIsArray=Array.isArray,nativeKeys=Object.keys,nativeCreate=Object.create,nativeIsView=supportsArrayBuffer&&ArrayBuffer.isView,_isNaN=isNaN,_isFinite=isFinite,hasEnumBug=!{toString:null}.propertyIsEnumerable("toString"),nonEnumerableProps=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],MAX_ARRAY_INDEX=Math.pow(2,53)-1;function restArguments(e,t){return t=null==t?e.length-1:+t,function(){for(var n=Math.max(arguments.length-t,0),r=Array(n),i=0;i<n;i++)r[i]=arguments[i+t];switch(t){case 0:return e.call(this,r);case 1:return e.call(this,arguments[0],r);case 2:return e.call(this,arguments[0],arguments[1],r)}var a=Array(t+1);for(i=0;i<t;i++)a[i]=arguments[i];return a[t]=r,e.apply(this,a)}}function isObject(e){var t=typeof e;return"function"===t||"object"===t&&!!e}function isNull(e){return null===e}function isUndefined(e){return void 0===e}function isBoolean(e){return!0===e||!1===e||"[object Boolean]"===toString.call(e)}function isElement(e){return!(!e||1!==e.nodeType)}function tagTester(e){return function(t){return toString.call(t)==="[object "+e+"]"}}var isString=tagTester("String"),isNumber=tagTester("Number"),isDate=tagTester("Date"),isRegExp=tagTester("RegExp"),isError=tagTester("Error"),isSymbol=tagTester("Symbol"),isMap=tagTester("Map"),isWeakMap=tagTester("WeakMap"),isSet=tagTester("Set"),isWeakSet=tagTester("WeakSet"),isArrayBuffer=tagTester("ArrayBuffer"),isDataView=tagTester("DataView"),isArray=nativeIsArray||tagTester("Array"),isFunction=tagTester("Function"),nodelist=root.document&&root.document.childNodes;"function"!=typeof/./&&"object"!=typeof Int8Array&&"function"!=typeof nodelist&&(isFunction=function(e){return"function"==typeof e||!1});var isFunction$1=isFunction;function has(e,t){return null!=e&&hasOwnProperty.call(e,t)}var isArguments=tagTester("Arguments");!function(){isArguments(arguments)||(isArguments=function(e){return has(e,"callee")})}();var isArguments$1=isArguments;function isFinite$1(e){return!isSymbol(e)&&_isFinite(e)&&!isNaN(parseFloat(e))}function isNaN$1(e){return isNumber(e)&&_isNaN(e)}function constant(e){return function(){return e}}function createSizePropertyCheck(e){return function(t){var n=e(t);return"number"==typeof n&&n>=0&&n<=MAX_ARRAY_INDEX}}function shallowProperty(e){return function(t){return null==t?void 0:t[e]}}var getByteLength=shallowProperty("byteLength"),isBufferLike=createSizePropertyCheck(getByteLength),typedArrayPattern=/\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/;function isTypedArray(e){return nativeIsView?nativeIsView(e)&&!isDataView(e):isBufferLike(e)&&typedArrayPattern.test(toString.call(e))}var isTypedArray$1=supportsArrayBuffer?isTypedArray:constant(!1),getLength=shallowProperty("length"),isArrayLike=createSizePropertyCheck(getLength);function emulatedSet(e){for(var t={},n=e.length,r=0;r<n;++r)t[e[r]]=!0;return{contains:function(e){return t[e]},push:function(n){return t[n]=!0,e.push(n)}}}function collectNonEnumProps(e,t){t=emulatedSet(t);var n=nonEnumerableProps.length,r=e.constructor,i=isFunction$1(r)&&r.prototype||ObjProto,a="constructor";for(has(e,a)&&!t.contains(a)&&t.push(a);n--;)(a=nonEnumerableProps[n])in e&&e[a]!==i[a]&&!t.contains(a)&&t.push(a)}function keys(e){if(!isObject(e))return[];if(nativeKeys)return nativeKeys(e);var t=[];for(var n in e)has(e,n)&&t.push(n);return hasEnumBug&&collectNonEnumProps(e,t),t}function isEmpty(e){return null==e||(isArrayLike(e)&&(isArray(e)||isString(e)||isArguments$1(e))?0===e.length:0===keys(e).length)}function isMatch(e,t){var n=keys(t),r=n.length;if(null==e)return!r;for(var i=Object(e),a=0;a<r;a++){var u=n[a];if(t[u]!==i[u]||!(u in i))return!1}return!0}function _(e){return e instanceof _?e:this instanceof _?void(this._wrapped=e):new _(e)}function eq(e,t,n,r){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return!1;if(e!=e)return t!=t;var i=typeof e;return("function"===i||"object"===i||"object"==typeof t)&&deepEq(e,t,n,r)}function deepEq(e,t,n,r){e instanceof _&&(e=e._wrapped),t instanceof _&&(t=t._wrapped);var i=toString.call(e);if(i!==toString.call(t))return!1;switch(i){case"[object RegExp]":case"[object String]":return""+e==""+t;case"[object Number]":return+e!=+e?+t!=+t:0==+e?1/+e==1/t:+e==+t;case"[object Date]":case"[object Boolean]":return+e==+t;case"[object Symbol]":return SymbolProto.valueOf.call(e)===SymbolProto.valueOf.call(t);case"[object ArrayBuffer]":return deepEq(new DataView(e),new DataView(t),n,r);case"[object DataView]":var a=getByteLength(e);if(a!==getByteLength(t))return!1;for(;a--;)if(e.getUint8(a)!==t.getUint8(a))return!1;return!0}if(isTypedArray$1(e))return deepEq(new DataView(e.buffer),new DataView(t.buffer),n,r);var u="[object Array]"===i;if(!u){if("object"!=typeof e||"object"!=typeof t)return!1;var o=e.constructor,s=t.constructor;if(o!==s&&!(isFunction$1(o)&&o instanceof o&&isFunction$1(s)&&s instanceof s)&&"constructor"in e&&"constructor"in t)return!1}r=r||[];for(var c=(n=n||[]).length;c--;)if(n[c]===e)return r[c]===t;if(n.push(e),r.push(t),u){if((c=e.length)!==t.length)return!1;for(;c--;)if(!eq(e[c],t[c],n,r))return!1}else{var l,f=keys(e);if(c=f.length,keys(t).length!==c)return!1;for(;c--;)if(!has(t,l=f[c])||!eq(e[l],t[l],n,r))return!1}return n.pop(),r.pop(),!0}function isEqual(e,t){return eq(e,t)}function allKeys(e){if(!isObject(e))return[];var t=[];for(var n in e)t.push(n);return hasEnumBug&&collectNonEnumProps(e,t),t}function values(e){for(var t=keys(e),n=t.length,r=Array(n),i=0;i<n;i++)r[i]=e[t[i]];return r}function pairs(e){for(var t=keys(e),n=t.length,r=Array(n),i=0;i<n;i++)r[i]=[t[i],e[t[i]]];return r}function invert(e){for(var t={},n=keys(e),r=0,i=n.length;r<i;r++)t[e[n[r]]]=n[r];return t}function functions(e){var t=[];for(var n in e)isFunction$1(e[n])&&t.push(n);return t.sort()}function createAssigner(e,t){return function(n){var r=arguments.length;if(t&&(n=Object(n)),r<2||null==n)return n;for(var i=1;i<r;i++)for(var a=arguments[i],u=e(a),o=u.length,s=0;s<o;s++){var c=u[s];t&&void 0!==n[c]||(n[c]=a[c])}return n}}_.VERSION=VERSION,_.prototype.value=function(){return this._wrapped},_.prototype.valueOf=_.prototype.toJSON=_.prototype.value,_.prototype.toString=function(){return String(this._wrapped)};var extend=createAssigner(allKeys),extendOwn=createAssigner(keys),defaults=createAssigner(allKeys,!0);function ctor(){return function(){}}function baseCreate(e){if(!isObject(e))return{};if(nativeCreate)return nativeCreate(e);var t=ctor();t.prototype=e;var n=new t;return t.prototype=null,n}function create(e,t){var n=baseCreate(e);return t&&extendOwn(n,t),n}function clone(e){return isObject(e)?isArray(e)?e.slice():extend({},e):e}function tap(e,t){return t(e),e}function has$1(e,t){if(!isArray(t))return has(e,t);for(var n=t.length,r=0;r<n;r++){var i=t[r];if(null==e||!hasOwnProperty.call(e,i))return!1;e=e[i]}return!!n}function identity(e){return e}function matcher(e){return e=extendOwn({},e),function(t){return isMatch(t,e)}}function deepGet(e,t){for(var n=t.length,r=0;r<n;r++){if(null==e)return;e=e[t[r]]}return n?e:void 0}function property(e){return isArray(e)?function(t){return deepGet(t,e)}:shallowProperty(e)}function optimizeCb(e,t,n){if(void 0===t)return e;switch(null==n?3:n){case 1:return function(n){return e.call(t,n)};case 3:return function(n,r,i){return e.call(t,n,r,i)};case 4:return function(n,r,i,a){return e.call(t,n,r,i,a)}}return function(){return e.apply(t,arguments)}}function baseIteratee(e,t,n){return null==e?identity:isFunction$1(e)?optimizeCb(e,t,n):isObject(e)&&!isArray(e)?matcher(e):property(e)}function iteratee(e,t){return baseIteratee(e,t,1/0)}function cb(e,t,n){return _.iteratee!==iteratee?_.iteratee(e,t):baseIteratee(e,t,n)}function mapObject(e,t,n){t=cb(t,n);for(var r=keys(e),i=r.length,a={},u=0;u<i;u++){var o=r[u];a[o]=t(e[o],o,e)}return a}function noop(){}function propertyOf(e){return null==e?function(){}:function(t){return isArray(t)?deepGet(e,t):e[t]}}function times(e,t,n){var r=Array(Math.max(0,e));t=optimizeCb(t,n,1);for(var i=0;i<e;i++)r[i]=t(i);return r}function random(e,t){return null==t&&(t=e,e=0),e+Math.floor(Math.random()*(t-e+1))}_.iteratee=iteratee;var now=Date.now||function(){return(new Date).getTime()};function createEscaper(e){var t=function(t){return e[t]},n="(?:"+keys(e).join("|")+")",r=RegExp(n),i=RegExp(n,"g");return function(e){return e=null==e?"":""+e,r.test(e)?e.replace(i,t):e}}var escapeMap={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},_escape=createEscaper(escapeMap),unescapeMap=invert(escapeMap),_unescape=createEscaper(unescapeMap),templateSettings=_.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g},noMatch=/(.)^/,escapes={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},escapeRegExp=/\\|'|\r|\n|\u2028|\u2029/g;function escapeChar(e){return"\\"+escapes[e]}function template(e,t,n){!t&&n&&(t=n),t=defaults({},t,_.templateSettings);var r,i=RegExp([(t.escape||noMatch).source,(t.interpolate||noMatch).source,(t.evaluate||noMatch).source].join("|")+"|$","g"),a=0,u="__p+='";e.replace(i,(function(t,n,r,i,o){return u+=e.slice(a,o).replace(escapeRegExp,escapeChar),a=o+t.length,n?u+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'":r?u+="'+\n((__t=("+r+"))==null?'':__t)+\n'":i&&(u+="';\n"+i+"\n__p+='"),t})),u+="';\n",t.variable||(u="with(obj||{}){\n"+u+"}\n"),u="var __t,__p='',__j=Array.prototype.join,"+"print=function(){__p+=__j.call(arguments,'');};\n"+u+"return __p;\n";try{r=new Function(t.variable||"obj","_",u)}catch(e){throw e.source=u,e}var o=function(e){return r.call(this,e,_)},s=t.variable||"obj";return o.source="function("+s+"){\n"+u+"}",o}function result(e,t,n){isArray(t)||(t=[t]);var r=t.length;if(!r)return isFunction$1(n)?n.call(e):n;for(var i=0;i<r;i++){var a=null==e?void 0:e[t[i]];void 0===a&&(a=n,i=r),e=isFunction$1(a)?a.call(e):a}return e}var idCounter=0;function uniqueId(e){var t=++idCounter+"";return e?e+t:t}function chain(e){var t=_(e);return t._chain=!0,t}function executeBound(e,t,n,r,i){if(!(r instanceof t))return e.apply(n,i);var a=baseCreate(e.prototype),u=e.apply(a,i);return isObject(u)?u:a}var partial=restArguments((function(e,t){var n=partial.placeholder,r=function(){for(var i=0,a=t.length,u=Array(a),o=0;o<a;o++)u[o]=t[o]===n?arguments[i++]:t[o];for(;i<arguments.length;)u.push(arguments[i++]);return executeBound(e,r,this,this,u)};return r}));partial.placeholder=_;var bind=restArguments((function(e,t,n){if(!isFunction$1(e))throw new TypeError("Bind must be called on a function");var r=restArguments((function(i){return executeBound(e,r,t,this,n.concat(i))}));return r}));function flatten(e,t,n,r){if(r=r||[],t||0===t){if(t<=0)return r.concat(e)}else t=1/0;for(var i=r.length,a=0,u=getLength(e);a<u;a++){var o=e[a];if(isArrayLike(o)&&(isArray(o)||isArguments$1(o)))if(t>1)flatten(o,t-1,n,r),i=r.length;else for(var s=0,c=o.length;s<c;)r[i++]=o[s++];else n||(r[i++]=o)}return r}var bindAll=restArguments((function(e,t){var n=(t=flatten(t,!1,!1)).length;if(n<1)throw new Error("bindAll must be passed function names");for(;n--;){var r=t[n];e[r]=bind(e[r],e)}return e}));function memoize(e,t){var n=function(r){var i=n.cache,a=""+(t?t.apply(this,arguments):r);return has(i,a)||(i[a]=e.apply(this,arguments)),i[a]};return n.cache={},n}var delay=restArguments((function(e,t,n){return setTimeout((function(){return e.apply(null,n)}),t)})),defer=partial(delay,_,1);function throttle(e,t,n){var r,i,a,u,o=0;n||(n={});var s=function(){o=!1===n.leading?0:now(),r=null,u=e.apply(i,a),r||(i=a=null)},c=function(){var c=now();o||!1!==n.leading||(o=c);var l=t-(c-o);return i=this,a=arguments,l<=0||l>t?(r&&(clearTimeout(r),r=null),o=c,u=e.apply(i,a),r||(i=a=null)):r||!1===n.trailing||(r=setTimeout(s,l)),u};return c.cancel=function(){clearTimeout(r),o=0,r=i=a=null},c}function debounce(e,t,n){var r,i,a=function(t,n){r=null,n&&(i=e.apply(t,n))},u=restArguments((function(u){if(r&&clearTimeout(r),n){var o=!r;r=setTimeout(a,t),o&&(i=e.apply(this,u))}else r=delay(a,t,this,u);return i}));return u.cancel=function(){clearTimeout(r),r=null},u}function wrap(e,t){return partial(t,e)}function negate(e){return function(){return!e.apply(this,arguments)}}function compose(){var e=arguments,t=e.length-1;return function(){for(var n=t,r=e[t].apply(this,arguments);n--;)r=e[n].call(this,r);return r}}function after(e,t){return function(){if(--e<1)return t.apply(this,arguments)}}function before(e,t){var n;return function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=null),n}}var once=partial(before,2);function findKey(e,t,n){t=cb(t,n);for(var r,i=keys(e),a=0,u=i.length;a<u;a++)if(t(e[r=i[a]],r,e))return r}function createPredicateIndexFinder(e){return function(t,n,r){n=cb(n,r);for(var i=getLength(t),a=e>0?0:i-1;a>=0&&a<i;a+=e)if(n(t[a],a,t))return a;return-1}}var findIndex=createPredicateIndexFinder(1),findLastIndex=createPredicateIndexFinder(-1);function sortedIndex(e,t,n,r){for(var i=(n=cb(n,r,1))(t),a=0,u=getLength(e);a<u;){var o=Math.floor((a+u)/2);n(e[o])<i?a=o+1:u=o}return a}function createIndexFinder(e,t,n){return function(r,i,a){var u=0,o=getLength(r);if("number"==typeof a)e>0?u=a>=0?a:Math.max(a+o,u):o=a>=0?Math.min(a+1,o):a+o+1;else if(n&&a&&o)return r[a=n(r,i)]===i?a:-1;if(i!=i)return(a=t(slice.call(r,u,o),isNaN$1))>=0?a+u:-1;for(a=e>0?u:o-1;a>=0&&a<o;a+=e)if(r[a]===i)return a;return-1}}var indexOf=createIndexFinder(1,findIndex,sortedIndex),lastIndexOf=createIndexFinder(-1,findLastIndex);function find(e,t,n){var r=(isArrayLike(e)?findIndex:findKey)(e,t,n);if(void 0!==r&&-1!==r)return e[r]}function findWhere(e,t){return find(e,matcher(t))}function each(e,t,n){var r,i;if(t=optimizeCb(t,n),isArrayLike(e))for(r=0,i=e.length;r<i;r++)t(e[r],r,e);else{var a=keys(e);for(r=0,i=a.length;r<i;r++)t(e[a[r]],a[r],e)}return e}function map(e,t,n){t=cb(t,n);for(var r=!isArrayLike(e)&&keys(e),i=(r||e).length,a=Array(i),u=0;u<i;u++){var o=r?r[u]:u;a[u]=t(e[o],o,e)}return a}function createReduce(e){var t=function(t,n,r,i){var a=!isArrayLike(t)&&keys(t),u=(a||t).length,o=e>0?0:u-1;for(i||(r=t[a?a[o]:o],o+=e);o>=0&&o<u;o+=e){var s=a?a[o]:o;r=n(r,t[s],s,t)}return r};return function(e,n,r,i){var a=arguments.length>=3;return t(e,optimizeCb(n,i,4),r,a)}}var reduce=createReduce(1),reduceRight=createReduce(-1);function filter(e,t,n){var r=[];return t=cb(t,n),each(e,(function(e,n,i){t(e,n,i)&&r.push(e)})),r}function reject(e,t,n){return filter(e,negate(cb(t)),n)}function every(e,t,n){t=cb(t,n);for(var r=!isArrayLike(e)&&keys(e),i=(r||e).length,a=0;a<i;a++){var u=r?r[a]:a;if(!t(e[u],u,e))return!1}return!0}function some(e,t,n){t=cb(t,n);for(var r=!isArrayLike(e)&&keys(e),i=(r||e).length,a=0;a<i;a++){var u=r?r[a]:a;if(t(e[u],u,e))return!0}return!1}function contains(e,t,n,r){return isArrayLike(e)||(e=values(e)),("number"!=typeof n||r)&&(n=0),indexOf(e,t,n)>=0}var invoke=restArguments((function(e,t,n){var r,i;return isFunction$1(t)?i=t:isArray(t)&&(r=t.slice(0,-1),t=t[t.length-1]),map(e,(function(e){var a=i;if(!a){if(r&&r.length&&(e=deepGet(e,r)),null==e)return;a=e[t]}return null==a?a:a.apply(e,n)}))}));function pluck(e,t){return map(e,property(t))}function where(e,t){return filter(e,matcher(t))}function max(e,t,n){var r,i,a=-1/0,u=-1/0;if(null==t||"number"==typeof t&&"object"!=typeof e[0]&&null!=e)for(var o=0,s=(e=isArrayLike(e)?e:values(e)).length;o<s;o++)null!=(r=e[o])&&r>a&&(a=r);else t=cb(t,n),each(e,(function(e,n,r){((i=t(e,n,r))>u||i===-1/0&&a===-1/0)&&(a=e,u=i)}));return a}function min(e,t,n){var r,i,a=1/0,u=1/0;if(null==t||"number"==typeof t&&"object"!=typeof e[0]&&null!=e)for(var o=0,s=(e=isArrayLike(e)?e:values(e)).length;o<s;o++)null!=(r=e[o])&&r<a&&(a=r);else t=cb(t,n),each(e,(function(e,n,r){((i=t(e,n,r))<u||i===1/0&&a===1/0)&&(a=e,u=i)}));return a}function sample(e,t,n){if(null==t||n)return isArrayLike(e)||(e=values(e)),e[random(e.length-1)];var r=isArrayLike(e)?clone(e):values(e),i=getLength(r);t=Math.max(Math.min(t,i),0);for(var a=i-1,u=0;u<t;u++){var o=random(u,a),s=r[u];r[u]=r[o],r[o]=s}return r.slice(0,t)}function shuffle(e){return sample(e,1/0)}function sortBy(e,t,n){var r=0;return t=cb(t,n),pluck(map(e,(function(e,n,i){return{value:e,index:r++,criteria:t(e,n,i)}})).sort((function(e,t){var n=e.criteria,r=t.criteria;if(n!==r){if(n>r||void 0===n)return 1;if(n<r||void 0===r)return-1}return e.index-t.index})),"value")}function group(e,t){return function(n,r,i){var a=t?[[],[]]:{};return r=cb(r,i),each(n,(function(t,i){var u=r(t,i,n);e(a,t,u)})),a}}var groupBy=group((function(e,t,n){has(e,n)?e[n].push(t):e[n]=[t]})),indexBy=group((function(e,t,n){e[n]=t})),countBy=group((function(e,t,n){has(e,n)?e[n]++:e[n]=1})),partition=group((function(e,t,n){e[n?0:1].push(t)}),!0),reStrSymbol=/[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g;function toArray(e){return e?isArray(e)?slice.call(e):isString(e)?e.match(reStrSymbol):isArrayLike(e)?map(e,identity):values(e):[]}function size(e){return null==e?0:isArrayLike(e)?e.length:keys(e).length}function keyInObj(e,t,n){return t in n}var pick=restArguments((function(e,t){var n={},r=t[0];if(null==e)return n;isFunction$1(r)?(t.length>1&&(r=optimizeCb(r,t[1])),t=allKeys(e)):(r=keyInObj,t=flatten(t,!1,!1),e=Object(e));for(var i=0,a=t.length;i<a;i++){var u=t[i],o=e[u];r(o,u,e)&&(n[u]=o)}return n})),omit=restArguments((function(e,t){var n,r=t[0];return isFunction$1(r)?(r=negate(r),t.length>1&&(n=t[1])):(t=map(flatten(t,!1,!1),String),r=function(e,n){return!contains(t,n)}),pick(e,r,n)}));function initial(e,t,n){return slice.call(e,0,Math.max(0,e.length-(null==t||n?1:t)))}function first(e,t,n){return null==e||e.length<1?null==t||n?void 0:[]:null==t||n?e[0]:initial(e,e.length-t)}function rest(e,t,n){return slice.call(e,null==t||n?1:t)}function last(e,t,n){return null==e||e.length<1?null==t||n?void 0:[]:null==t||n?e[e.length-1]:rest(e,Math.max(0,e.length-t))}function compact(e){return filter(e,Boolean)}function flatten$1(e,t){return flatten(e,t,!1)}var difference=restArguments((function(e,t){return t=flatten(t,!0,!0),filter(e,(function(e){return!contains(t,e)}))})),without=restArguments((function(e,t){return difference(e,t)}));function uniq(e,t,n,r){isBoolean(t)||(r=n,n=t,t=!1),null!=n&&(n=cb(n,r));for(var i=[],a=[],u=0,o=getLength(e);u<o;u++){var s=e[u],c=n?n(s,u,e):s;t&&!n?(u&&a===c||i.push(s),a=c):n?contains(a,c)||(a.push(c),i.push(s)):contains(i,s)||i.push(s)}return i}var union=restArguments((function(e){return uniq(flatten(e,!0,!0))}));function intersection(e){for(var t=[],n=arguments.length,r=0,i=getLength(e);r<i;r++){var a=e[r];if(!contains(t,a)){var u;for(u=1;u<n&&contains(arguments[u],a);u++);u===n&&t.push(a)}}return t}function unzip(e){for(var t=e&&max(e,getLength).length||0,n=Array(t),r=0;r<t;r++)n[r]=pluck(e,r);return n}var zip=restArguments(unzip);function object(e,t){for(var n={},r=0,i=getLength(e);r<i;r++)t?n[e[r]]=t[r]:n[e[r][0]]=e[r][1];return n}function range(e,t,n){null==t&&(t=e||0,e=0),n||(n=t<e?-1:1);for(var r=Math.max(Math.ceil((t-e)/n),0),i=Array(r),a=0;a<r;a++,e+=n)i[a]=e;return i}function chunk(e,t){if(null==t||t<1)return[];for(var n=[],r=0,i=e.length;r<i;)n.push(slice.call(e,r,r+=t));return n}function chainResult(e,t){return e._chain?_(t).chain():t}function mixin(e){return each(functions(e),(function(t){var n=_[t]=e[t];_.prototype[t]=function(){var e=[this._wrapped];return push.apply(e,arguments),chainResult(this,n.apply(_,e))}})),_}each(["pop","push","reverse","shift","sort","splice","unshift"],(function(e){var t=ArrayProto[e];_.prototype[e]=function(){var n=this._wrapped;return null!=n&&(t.apply(n,arguments),"shift"!==e&&"splice"!==e||0!==n.length||delete n[0]),chainResult(this,n)}})),each(["concat","join","slice"],(function(e){var t=ArrayProto[e];_.prototype[e]=function(){var e=this._wrapped;return null!=e&&(e=t.apply(e,arguments)),chainResult(this,e)}}));var allExports={__proto__:null,VERSION:VERSION,restArguments:restArguments,isObject:isObject,isNull:isNull,isUndefined:isUndefined,isBoolean:isBoolean,isElement:isElement,isString:isString,isNumber:isNumber,isDate:isDate,isRegExp:isRegExp,isError:isError,isSymbol:isSymbol,isMap:isMap,isWeakMap:isWeakMap,isSet:isSet,isWeakSet:isWeakSet,isArrayBuffer:isArrayBuffer,isDataView:isDataView,isArray:isArray,isFunction:isFunction$1,isArguments:isArguments$1,isFinite:isFinite$1,isNaN:isNaN$1,isTypedArray:isTypedArray$1,isEmpty:isEmpty,isMatch:isMatch,isEqual:isEqual,keys:keys,allKeys:allKeys,values:values,pairs:pairs,invert:invert,functions:functions,methods:functions,extend:extend,extendOwn:extendOwn,assign:extendOwn,defaults:defaults,create:create,clone:clone,tap:tap,has:has$1,mapObject:mapObject,identity:identity,constant:constant,noop:noop,property:property,propertyOf:propertyOf,matcher:matcher,matches:matcher,times:times,random:random,now:now,escape:_escape,unescape:_unescape,templateSettings:templateSettings,template:template,result:result,uniqueId:uniqueId,chain:chain,iteratee:iteratee,partial:partial,bind:bind,bindAll:bindAll,memoize:memoize,delay:delay,defer:defer,throttle:throttle,debounce:debounce,wrap:wrap,negate:negate,compose:compose,after:after,before:before,once:once,findKey:findKey,findIndex:findIndex,findLastIndex:findLastIndex,sortedIndex:sortedIndex,indexOf:indexOf,lastIndexOf:lastIndexOf,find:find,detect:find,findWhere:findWhere,each:each,forEach:each,map:map,collect:map,reduce:reduce,foldl:reduce,inject:reduce,reduceRight:reduceRight,foldr:reduceRight,filter:filter,select:filter,reject:reject,every:every,all:every,some:some,any:some,contains:contains,includes:contains,include:contains,invoke:invoke,pluck:pluck,where:where,max:max,min:min,shuffle:shuffle,sample:sample,sortBy:sortBy,groupBy:groupBy,indexBy:indexBy,countBy:countBy,partition:partition,toArray:toArray,size:size,pick:pick,omit:omit,first:first,head:first,take:first,initial:initial,last:last,rest:rest,tail:rest,drop:rest,compact:compact,flatten:flatten$1,without:without,uniq:uniq,unique:uniq,union:union,intersection:intersection,difference:difference,unzip:unzip,transpose:unzip,zip:zip,object:object,range:range,chunk:chunk,mixin:mixin,default:_},_$1=mixin(allExports);_$1._=_$1;export default _$1;export{VERSION,after,every as all,allKeys,some as any,extendOwn as assign,before,bind,bindAll,chain,chunk,clone,map as collect,compact,compose,constant,contains,countBy,create,debounce,defaults,defer,delay,find as detect,difference,rest as drop,each,_escape as escape,every,extend,extendOwn,filter,find,findIndex,findKey,findLastIndex,findWhere,first,flatten$1 as flatten,reduce as foldl,reduceRight as foldr,each as forEach,functions,groupBy,has$1 as has,first as head,identity,contains as include,contains as includes,indexBy,indexOf,initial,reduce as inject,intersection,invert,invoke,isArguments$1 as isArguments,isArray,isArrayBuffer,isBoolean,isDataView,isDate,isElement,isEmpty,isEqual,isError,isFinite$1 as isFinite,isFunction$1 as isFunction,isMap,isMatch,isNaN$1 as isNaN,isNull,isNumber,isObject,isRegExp,isSet,isString,isSymbol,isTypedArray$1 as isTypedArray,isUndefined,isWeakMap,isWeakSet,iteratee,keys,last,lastIndexOf,map,mapObject,matcher,matcher as matches,max,memoize,functions as methods,min,mixin,negate,noop,now,object,omit,once,pairs,partial,partition,pick,pluck,property,propertyOf,random,range,reduce,reduceRight,reject,rest,restArguments,result,sample,filter as select,shuffle,size,some,sortBy,sortedIndex,rest as tail,first as take,tap,template,templateSettings,throttle,times,toArray,unzip as transpose,_unescape as unescape,union,uniq,uniq as unique,uniqueId,unzip,values,where,without,wrap,zip};