Simplify _.toArray and wrapper methods.

Former-commit-id: b0440d401bd58cfa2d7aaf213549a824963474c3
This commit is contained in:
John-David Dalton
2012-12-25 17:06:51 -06:00
parent ef7cb26b01
commit e3b80a5e09
6 changed files with 87 additions and 90 deletions

View File

@@ -363,6 +363,8 @@
return match.replace(/^( *)return new lodash.+/m, function() { return match.replace(/^( *)return new lodash.+/m, function() {
var indent = arguments[1]; var indent = arguments[1];
return indent + [ return indent + [
'',
'var result = func.apply(lodash, args);',
'if (this.__chain__) {', 'if (this.__chain__) {',
' result = new lodash(result);', ' result = new lodash(result);',
' result.__chain__ = true;', ' result.__chain__ = true;',

View File

@@ -187,7 +187,7 @@
<!-- div --> <!-- div -->
### <a id="_compactarray"></a>`_.compact(array)` ### <a id="_compactarray"></a>`_.compact(array)`
<a href="#_compactarray">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2768 "View in source") [&#x24C9;][1] <a href="#_compactarray">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2767 "View in source") [&#x24C9;][1]
Creates an array with all falsey values of `array` removed. The values `false`, `null`, `0`, `""`, `undefined` and `NaN` are all falsey. Creates an array with all falsey values of `array` removed. The values `false`, `null`, `0`, `""`, `undefined` and `NaN` are all falsey.
@@ -211,7 +211,7 @@ _.compact([0, 1, false, 2, '', 3]);
<!-- div --> <!-- div -->
### <a id="_differencearray--array1-array2-"></a>`_.difference(array [, array1, array2, ...])` ### <a id="_differencearray--array1-array2-"></a>`_.difference(array [, array1, array2, ...])`
<a href="#_differencearray--array1-array2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2798 "View in source") [&#x24C9;][1] <a href="#_differencearray--array1-array2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2797 "View in source") [&#x24C9;][1]
Creates an array of `array` elements not present in the other arrays using strict equality for comparisons, i.e. `===`. Creates an array of `array` elements not present in the other arrays using strict equality for comparisons, i.e. `===`.
@@ -236,7 +236,7 @@ _.difference([1, 2, 3, 4, 5], [5, 2, 10]);
<!-- div --> <!-- div -->
### <a id="_firstarray--n"></a>`_.first(array [, n])` ### <a id="_firstarray--n"></a>`_.first(array [, n])`
<a href="#_firstarray--n">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2833 "View in source") [&#x24C9;][1] <a href="#_firstarray--n">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2832 "View in source") [&#x24C9;][1]
Gets the first element of the `array`. Pass `n` to return the first `n` elements of the `array`. Gets the first element of the `array`. Pass `n` to return the first `n` elements of the `array`.
@@ -264,7 +264,7 @@ _.first([5, 4, 3, 2, 1]);
<!-- div --> <!-- div -->
### <a id="_flattenarray-shallow"></a>`_.flatten(array, shallow)` ### <a id="_flattenarray-shallow"></a>`_.flatten(array, shallow)`
<a href="#_flattenarray-shallow">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2860 "View in source") [&#x24C9;][1] <a href="#_flattenarray-shallow">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2859 "View in source") [&#x24C9;][1]
Flattens a nested array *(the nesting can be to any depth)*. If `shallow` is truthy, `array` will only be flattened a single level. Flattens a nested array *(the nesting can be to any depth)*. If `shallow` is truthy, `array` will only be flattened a single level.
@@ -292,7 +292,7 @@ _.flatten([1, [2], [3, [[4]]]], true);
<!-- div --> <!-- div -->
### <a id="_indexofarray-value--fromindex0"></a>`_.indexOf(array, value [, fromIndex=0])` ### <a id="_indexofarray-value--fromindex0"></a>`_.indexOf(array, value [, fromIndex=0])`
<a href="#_indexofarray-value--fromindex0">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2902 "View in source") [&#x24C9;][1] <a href="#_indexofarray-value--fromindex0">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2901 "View in source") [&#x24C9;][1]
Gets the index at which the first occurrence of `value` is found using strict equality for comparisons, i.e. `===`. If the `array` is already sorted, passing `true` for `fromIndex` will run a faster binary search. Gets the index at which the first occurrence of `value` is found using strict equality for comparisons, i.e. `===`. If the `array` is already sorted, passing `true` for `fromIndex` will run a faster binary search.
@@ -324,7 +324,7 @@ _.indexOf([1, 1, 2, 2, 3, 3], 2, true);
<!-- div --> <!-- div -->
### <a id="_initialarray--n1"></a>`_.initial(array [, n=1])` ### <a id="_initialarray--n1"></a>`_.initial(array [, n=1])`
<a href="#_initialarray--n1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2937 "View in source") [&#x24C9;][1] <a href="#_initialarray--n1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2936 "View in source") [&#x24C9;][1]
Gets all but the last element of `array`. Pass `n` to exclude the last `n` elements from the result. Gets all but the last element of `array`. Pass `n` to exclude the last `n` elements from the result.
@@ -349,7 +349,7 @@ _.initial([3, 2, 1]);
<!-- div --> <!-- div -->
### <a id="_intersectionarray1-array2-"></a>`_.intersection([array1, array2, ...])` ### <a id="_intersectionarray1-array2-"></a>`_.intersection([array1, array2, ...])`
<a href="#_intersectionarray1-array2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2961 "View in source") [&#x24C9;][1] <a href="#_intersectionarray1-array2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2960 "View in source") [&#x24C9;][1]
Computes the intersection of all the passed-in arrays using strict equality for comparisons, i.e. `===`. Computes the intersection of all the passed-in arrays using strict equality for comparisons, i.e. `===`.
@@ -373,7 +373,7 @@ _.intersection([1, 2, 3], [101, 2, 1, 10], [2, 1]);
<!-- div --> <!-- div -->
### <a id="_lastarray--n"></a>`_.last(array [, n])` ### <a id="_lastarray--n"></a>`_.last(array [, n])`
<a href="#_lastarray--n">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3014 "View in source") [&#x24C9;][1] <a href="#_lastarray--n">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3013 "View in source") [&#x24C9;][1]
Gets the last element of the `array`. Pass `n` to return the last `n` elements of the `array`. Gets the last element of the `array`. Pass `n` to return the last `n` elements of the `array`.
@@ -398,7 +398,7 @@ _.last([3, 2, 1]);
<!-- div --> <!-- div -->
### <a id="_lastindexofarray-value--fromindexarraylength-1"></a>`_.lastIndexOf(array, value [, fromIndex=array.length-1])` ### <a id="_lastindexofarray-value--fromindexarraylength-1"></a>`_.lastIndexOf(array, value [, fromIndex=array.length-1])`
<a href="#_lastindexofarray-value--fromindexarraylength-1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3041 "View in source") [&#x24C9;][1] <a href="#_lastindexofarray-value--fromindexarraylength-1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3040 "View in source") [&#x24C9;][1]
Gets the index at which the last occurrence of `value` is found using strict equality for comparisons, i.e. `===`. If `fromIndex` is negative, it is used as the offset from the end of the collection. Gets the index at which the last occurrence of `value` is found using strict equality for comparisons, i.e. `===`. If `fromIndex` is negative, it is used as the offset from the end of the collection.
@@ -427,7 +427,7 @@ _.lastIndexOf([1, 2, 3, 1, 2, 3], 2, 3);
<!-- div --> <!-- div -->
### <a id="_objectkeys--values"></a>`_.object(keys [, values=[]])` ### <a id="_objectkeys--values"></a>`_.object(keys [, values=[]])`
<a href="#_objectkeys--values">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3071 "View in source") [&#x24C9;][1] <a href="#_objectkeys--values">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3070 "View in source") [&#x24C9;][1]
Creates an object composed from arrays of `keys` and `values`. Pass either a single two dimensional array, i.e. `[[key1, value1], [key2, value2]]`, or two arrays, one of `keys` and one of corresponding `values`. Creates an object composed from arrays of `keys` and `values`. Pass either a single two dimensional array, i.e. `[[key1, value1], [key2, value2]]`, or two arrays, one of `keys` and one of corresponding `values`.
@@ -452,7 +452,7 @@ _.object(['moe', 'larry', 'curly'], [30, 40, 50]);
<!-- div --> <!-- div -->
### <a id="_rangestart0-end--step1"></a>`_.range([start=0], end [, step=1])` ### <a id="_rangestart0-end--step1"></a>`_.range([start=0], end [, step=1])`
<a href="#_rangestart0-end--step1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3116 "View in source") [&#x24C9;][1] <a href="#_rangestart0-end--step1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3115 "View in source") [&#x24C9;][1]
Creates an array of numbers *(positive and/or negative)* progressing from `start` up to but not including `stop`. This method is a port of Python's `range()` function. See http://docs.python.org/library/functions.html#range. Creates an array of numbers *(positive and/or negative)* progressing from `start` up to but not including `stop`. This method is a port of Python's `range()` function. See http://docs.python.org/library/functions.html#range.
@@ -490,7 +490,7 @@ _.range(0);
<!-- div --> <!-- div -->
### <a id="_restarray--n1"></a>`_.rest(array [, n=1])` ### <a id="_restarray--n1"></a>`_.rest(array [, n=1])`
<a href="#_restarray--n1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3155 "View in source") [&#x24C9;][1] <a href="#_restarray--n1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3154 "View in source") [&#x24C9;][1]
The opposite of `_.initial`, this method gets all but the first value of `array`. Pass `n` to exclude the first `n` values from the result. The opposite of `_.initial`, this method gets all but the first value of `array`. Pass `n` to exclude the first `n` values from the result.
@@ -518,7 +518,7 @@ _.rest([3, 2, 1]);
<!-- div --> <!-- div -->
### <a id="_sortedindexarray-value--callbackidentityproperty-thisarg"></a>`_.sortedIndex(array, value [, callback=identity|property, thisArg])` ### <a id="_sortedindexarray-value--callbackidentityproperty-thisarg"></a>`_.sortedIndex(array, value [, callback=identity|property, thisArg])`
<a href="#_sortedindexarray-value--callbackidentityproperty-thisarg">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3199 "View in source") [&#x24C9;][1] <a href="#_sortedindexarray-value--callbackidentityproperty-thisarg">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3198 "View in source") [&#x24C9;][1]
Uses a binary search to determine the smallest index at which the `value` should be inserted into `array` in order to maintain the sort order of the sorted `array`. If `callback` is passed, it will be executed for `value` and each element in `array` to compute their sort ranking. The `callback` is bound to `thisArg` and invoked with one argument; *(value)*. The `callback` argument may also be the name of a property to order by. Uses a binary search to determine the smallest index at which the `value` should be inserted into `array` in order to maintain the sort order of the sorted `array`. If `callback` is passed, it will be executed for `value` and each element in `array` to compute their sort ranking. The `callback` is bound to `thisArg` and invoked with one argument; *(value)*. The `callback` argument may also be the name of a property to order by.
@@ -562,7 +562,7 @@ _.sortedIndex(['twenty', 'thirty', 'fifty'], 'fourty', function(word) {
<!-- div --> <!-- div -->
### <a id="_unionarray1-array2-"></a>`_.union([array1, array2, ...])` ### <a id="_unionarray1-array2-"></a>`_.union([array1, array2, ...])`
<a href="#_unionarray1-array2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3231 "View in source") [&#x24C9;][1] <a href="#_unionarray1-array2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3230 "View in source") [&#x24C9;][1]
Computes the union of the passed-in arrays using strict equality for comparisons, i.e. `===`. Computes the union of the passed-in arrays using strict equality for comparisons, i.e. `===`.
@@ -586,7 +586,7 @@ _.union([1, 2, 3], [101, 2, 1, 10], [2, 1]);
<!-- div --> <!-- div -->
### <a id="_uniqarray--issortedfalse-callbackidentity-thisarg"></a>`_.uniq(array [, isSorted=false, callback=identity, thisArg])` ### <a id="_uniqarray--issortedfalse-callbackidentity-thisarg"></a>`_.uniq(array [, isSorted=false, callback=identity, thisArg])`
<a href="#_uniqarray--issortedfalse-callbackidentity-thisarg">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3265 "View in source") [&#x24C9;][1] <a href="#_uniqarray--issortedfalse-callbackidentity-thisarg">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3264 "View in source") [&#x24C9;][1]
Creates a duplicate-value-free version of the `array` using strict equality for comparisons, i.e. `===`. If the `array` is already sorted, passing `true` for `isSorted` will run a faster algorithm. If `callback` is passed, each element of `array` is passed through a callback` before uniqueness is computed. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index, array)*. Creates a duplicate-value-free version of the `array` using strict equality for comparisons, i.e. `===`. If the `array` is already sorted, passing `true` for `isSorted` will run a faster algorithm. If `callback` is passed, each element of `array` is passed through a callback` before uniqueness is computed. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index, array)*.
@@ -625,7 +625,7 @@ _.uniq([1, 2, 1.5, 3, 2.5], function(num) { return this.floor(num); }, Math);
<!-- div --> <!-- div -->
### <a id="_withoutarray--value1-value2-"></a>`_.without(array [, value1, value2, ...])` ### <a id="_withoutarray--value1-value2-"></a>`_.without(array [, value1, value2, ...])`
<a href="#_withoutarray--value1-value2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3324 "View in source") [&#x24C9;][1] <a href="#_withoutarray--value1-value2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3323 "View in source") [&#x24C9;][1]
Creates an array with all occurrences of the passed values removed using strict equality for comparisons, i.e. `===`. Creates an array with all occurrences of the passed values removed using strict equality for comparisons, i.e. `===`.
@@ -650,7 +650,7 @@ _.without([1, 2, 1, 0, 3, 1, 4], 0, 1);
<!-- div --> <!-- div -->
### <a id="_ziparray1-array2-"></a>`_.zip([array1, array2, ...])` ### <a id="_ziparray1-array2-"></a>`_.zip([array1, array2, ...])`
<a href="#_ziparray1-array2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3355 "View in source") [&#x24C9;][1] <a href="#_ziparray1-array2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3354 "View in source") [&#x24C9;][1]
Groups the elements of each array at their corresponding indexes. Useful for separate data sources that are coordinated through matching array indexes. For a matrix of nested arrays, `_.zip.apply(...)` can transpose the matrix in a similar fashion. Groups the elements of each array at their corresponding indexes. Useful for separate data sources that are coordinated through matching array indexes. For a matrix of nested arrays, `_.zip.apply(...)` can transpose the matrix in a similar fashion.
@@ -707,7 +707,7 @@ The wrapper functions `first` and `last` return wrapped values when `n` is passe
<!-- div --> <!-- div -->
### <a id="_tapvalue-interceptor"></a>`_.tap(value, interceptor)` ### <a id="_tapvalue-interceptor"></a>`_.tap(value, interceptor)`
<a href="#_tapvalue-interceptor">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4223 "View in source") [&#x24C9;][1] <a href="#_tapvalue-interceptor">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4220 "View in source") [&#x24C9;][1]
Invokes `interceptor` with the `value` as the first argument, and then returns `value`. The purpose of this method is to "tap into" a method chain, in order to perform operations on intermediate results within the chain. Invokes `interceptor` with the `value` as the first argument, and then returns `value`. The purpose of this method is to "tap into" a method chain, in order to perform operations on intermediate results within the chain.
@@ -737,7 +737,7 @@ _.chain([1, 2, 3, 200])
<!-- div --> <!-- div -->
### <a id="_prototypetostring"></a>`_.prototype.toString()` ### <a id="_prototypetostring"></a>`_.prototype.toString()`
<a href="#_prototypetostring">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4240 "View in source") [&#x24C9;][1] <a href="#_prototypetostring">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4237 "View in source") [&#x24C9;][1]
Produces the `toString` result of the wrapped value. Produces the `toString` result of the wrapped value.
@@ -758,7 +758,7 @@ _([1, 2, 3]).toString();
<!-- div --> <!-- div -->
### <a id="_prototypevalueof"></a>`_.prototype.valueOf()` ### <a id="_prototypevalueof"></a>`_.prototype.valueOf()`
<a href="#_prototypevalueof">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4257 "View in source") [&#x24C9;][1] <a href="#_prototypevalueof">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4254 "View in source") [&#x24C9;][1]
Extracts the wrapped value. Extracts the wrapped value.
@@ -1414,7 +1414,7 @@ Converts the `collection` to an array.
<!-- div --> <!-- div -->
### <a id="_wherecollection-properties"></a>`_.where(collection, properties)` ### <a id="_wherecollection-properties"></a>`_.where(collection, properties)`
<a href="#_wherecollection-properties">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2738 "View in source") [&#x24C9;][1] <a href="#_wherecollection-properties">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2737 "View in source") [&#x24C9;][1]
Examines each element in a `collection`, returning an array of all elements that contain the given `properties`. Examines each element in a `collection`, returning an array of all elements that contain the given `properties`.
@@ -1452,7 +1452,7 @@ _.where(stooges, { 'age': 40 });
<!-- div --> <!-- div -->
### <a id="_aftern-func"></a>`_.after(n, func)` ### <a id="_aftern-func"></a>`_.after(n, func)`
<a href="#_aftern-func">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3388 "View in source") [&#x24C9;][1] <a href="#_aftern-func">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3387 "View in source") [&#x24C9;][1]
Creates a function that is restricted to executing `func` only after it is called `n` times. The `func` is executed with the `this` binding of the created function. Creates a function that is restricted to executing `func` only after it is called `n` times. The `func` is executed with the `this` binding of the created function.
@@ -1480,7 +1480,7 @@ _.forEach(notes, function(note) {
<!-- div --> <!-- div -->
### <a id="_bindfunc--thisarg-arg1-arg2-"></a>`_.bind(func [, thisArg, arg1, arg2, ...])` ### <a id="_bindfunc--thisarg-arg1-arg2-"></a>`_.bind(func [, thisArg, arg1, arg2, ...])`
<a href="#_bindfunc--thisarg-arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3421 "View in source") [&#x24C9;][1] <a href="#_bindfunc--thisarg-arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3420 "View in source") [&#x24C9;][1]
Creates a function that, when called, invokes `func` with the `this` binding of `thisArg` and prepends any additional `bind` arguments to those passed to the bound function. Creates a function that, when called, invokes `func` with the `this` binding of `thisArg` and prepends any additional `bind` arguments to those passed to the bound function.
@@ -1511,7 +1511,7 @@ func();
<!-- div --> <!-- div -->
### <a id="_bindallobject--methodname1-methodname2-"></a>`_.bindAll(object [, methodName1, methodName2, ...])` ### <a id="_bindallobject--methodname1-methodname2-"></a>`_.bindAll(object [, methodName1, methodName2, ...])`
<a href="#_bindallobject--methodname1-methodname2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3451 "View in source") [&#x24C9;][1] <a href="#_bindallobject--methodname1-methodname2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3450 "View in source") [&#x24C9;][1]
Binds methods on `object` to `object`, overwriting the existing method. If no method names are provided, all the function properties of `object` will be bound. Binds methods on `object` to `object`, overwriting the existing method. If no method names are provided, all the function properties of `object` will be bound.
@@ -1542,7 +1542,7 @@ jQuery('#lodash_button').on('click', buttonView.onClick);
<!-- div --> <!-- div -->
### <a id="_bindkeyobject-key--arg1-arg2-"></a>`_.bindKey(object, key [, arg1, arg2, ...])` ### <a id="_bindkeyobject-key--arg1-arg2-"></a>`_.bindKey(object, key [, arg1, arg2, ...])`
<a href="#_bindkeyobject-key--arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3497 "View in source") [&#x24C9;][1] <a href="#_bindkeyobject-key--arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3496 "View in source") [&#x24C9;][1]
Creates a function that, when called, invokes the method at `object[key]` and prepends any additional `bindKey` arguments to those passed to the bound function. This method differs from `_.bind` by allowing bound functions to reference methods that will be redefined or don't yet exist. See http://michaux.ca/articles/lazy-function-definition-pattern. Creates a function that, when called, invokes the method at `object[key]` and prepends any additional `bindKey` arguments to those passed to the bound function. This method differs from `_.bind` by allowing bound functions to reference methods that will be redefined or don't yet exist. See http://michaux.ca/articles/lazy-function-definition-pattern.
@@ -1583,7 +1583,7 @@ func();
<!-- div --> <!-- div -->
### <a id="_composefunc1-func2-"></a>`_.compose([func1, func2, ...])` ### <a id="_composefunc1-func2-"></a>`_.compose([func1, func2, ...])`
<a href="#_composefunc1-func2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3520 "View in source") [&#x24C9;][1] <a href="#_composefunc1-func2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3519 "View in source") [&#x24C9;][1]
Creates a function that is the composition of the passed functions, where each function consumes the return value of the function that follows. In math terms, composing the functions `f()`, `g()`, and `h()` produces `f(g(h()))`. Each function is executed with the `this` binding of the composed function. Creates a function that is the composition of the passed functions, where each function consumes the return value of the function that follows. In math terms, composing the functions `f()`, `g()`, and `h()` produces `f(g(h()))`. Each function is executed with the `this` binding of the composed function.
@@ -1610,7 +1610,7 @@ welcome('moe');
<!-- div --> <!-- div -->
### <a id="_debouncefunc-wait-immediate"></a>`_.debounce(func, wait, immediate)` ### <a id="_debouncefunc-wait-immediate"></a>`_.debounce(func, wait, immediate)`
<a href="#_debouncefunc-wait-immediate">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3553 "View in source") [&#x24C9;][1] <a href="#_debouncefunc-wait-immediate">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3552 "View in source") [&#x24C9;][1]
Creates a function that will delay the execution of `func` until after `wait` milliseconds have elapsed since the last time it was invoked. Pass `true` for `immediate` to cause debounce to invoke `func` on the leading, instead of the trailing, edge of the `wait` timeout. Subsequent calls to the debounced function will return the result of the last `func` call. Creates a function that will delay the execution of `func` until after `wait` milliseconds have elapsed since the last time it was invoked. Pass `true` for `immediate` to cause debounce to invoke `func` on the leading, instead of the trailing, edge of the `wait` timeout. Subsequent calls to the debounced function will return the result of the last `func` call.
@@ -1636,7 +1636,7 @@ jQuery(window).on('resize', lazyLayout);
<!-- div --> <!-- div -->
### <a id="_deferfunc--arg1-arg2-"></a>`_.defer(func [, arg1, arg2, ...])` ### <a id="_deferfunc--arg1-arg2-"></a>`_.defer(func [, arg1, arg2, ...])`
<a href="#_deferfunc--arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3617 "View in source") [&#x24C9;][1] <a href="#_deferfunc--arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3616 "View in source") [&#x24C9;][1]
Defers executing the `func` function until the current call stack has cleared. Additional arguments will be passed to `func` when it is invoked. Defers executing the `func` function until the current call stack has cleared. Additional arguments will be passed to `func` when it is invoked.
@@ -1661,7 +1661,7 @@ _.defer(function() { alert('deferred'); });
<!-- div --> <!-- div -->
### <a id="_delayfunc-wait--arg1-arg2-"></a>`_.delay(func, wait [, arg1, arg2, ...])` ### <a id="_delayfunc-wait--arg1-arg2-"></a>`_.delay(func, wait [, arg1, arg2, ...])`
<a href="#_delayfunc-wait--arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3597 "View in source") [&#x24C9;][1] <a href="#_delayfunc-wait--arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3596 "View in source") [&#x24C9;][1]
Executes the `func` function after `wait` milliseconds. Additional arguments will be passed to `func` when it is invoked. Executes the `func` function after `wait` milliseconds. Additional arguments will be passed to `func` when it is invoked.
@@ -1688,7 +1688,7 @@ _.delay(log, 1000, 'logged later');
<!-- div --> <!-- div -->
### <a id="_memoizefunc--resolver"></a>`_.memoize(func [, resolver])` ### <a id="_memoizefunc--resolver"></a>`_.memoize(func [, resolver])`
<a href="#_memoizefunc--resolver">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3641 "View in source") [&#x24C9;][1] <a href="#_memoizefunc--resolver">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3640 "View in source") [&#x24C9;][1]
Creates a function that memoizes the result of `func`. If `resolver` is passed, it will be used to determine the cache key for storing the result based on the arguments passed to the memoized function. By default, the first argument passed to the memoized function is used as the cache key. The `func` is executed with the `this` binding of the memoized function. Creates a function that memoizes the result of `func`. If `resolver` is passed, it will be used to determine the cache key for storing the result based on the arguments passed to the memoized function. By default, the first argument passed to the memoized function is used as the cache key. The `func` is executed with the `this` binding of the memoized function.
@@ -1714,7 +1714,7 @@ var fibonacci = _.memoize(function(n) {
<!-- div --> <!-- div -->
### <a id="_oncefunc"></a>`_.once(func)` ### <a id="_oncefunc"></a>`_.once(func)`
<a href="#_oncefunc">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3668 "View in source") [&#x24C9;][1] <a href="#_oncefunc">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3667 "View in source") [&#x24C9;][1]
Creates a function that is restricted to execute `func` once. Repeat calls to the function will return the value of the first call. The `func` is executed with the `this` binding of the created function. Creates a function that is restricted to execute `func` once. Repeat calls to the function will return the value of the first call. The `func` is executed with the `this` binding of the created function.
@@ -1740,7 +1740,7 @@ initialize();
<!-- div --> <!-- div -->
### <a id="_partialfunc--arg1-arg2-"></a>`_.partial(func [, arg1, arg2, ...])` ### <a id="_partialfunc--arg1-arg2-"></a>`_.partial(func [, arg1, arg2, ...])`
<a href="#_partialfunc--arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3703 "View in source") [&#x24C9;][1] <a href="#_partialfunc--arg1-arg2-">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3702 "View in source") [&#x24C9;][1]
Creates a function that, when called, invokes `func` with any additional `partial` arguments prepended to those passed to the new function. This method is similar to `bind`, except it does **not** alter the `this` binding. Creates a function that, when called, invokes `func` with any additional `partial` arguments prepended to those passed to the new function. This method is similar to `bind`, except it does **not** alter the `this` binding.
@@ -1767,7 +1767,7 @@ hi('moe');
<!-- div --> <!-- div -->
### <a id="_throttlefunc-wait"></a>`_.throttle(func, wait)` ### <a id="_throttlefunc-wait"></a>`_.throttle(func, wait)`
<a href="#_throttlefunc-wait">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3725 "View in source") [&#x24C9;][1] <a href="#_throttlefunc-wait">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3724 "View in source") [&#x24C9;][1]
Creates a function that, when executed, will only call the `func` function at most once per every `wait` milliseconds. If the throttled function is invoked more than once during the `wait` timeout, `func` will also be called on the trailing edge of the timeout. Subsequent calls to the throttled function will return the result of the last `func` call. Creates a function that, when executed, will only call the `func` function at most once per every `wait` milliseconds. If the throttled function is invoked more than once during the `wait` timeout, `func` will also be called on the trailing edge of the timeout. Subsequent calls to the throttled function will return the result of the last `func` call.
@@ -1792,7 +1792,7 @@ jQuery(window).on('scroll', throttled);
<!-- div --> <!-- div -->
### <a id="_wrapvalue-wrapper"></a>`_.wrap(value, wrapper)` ### <a id="_wrapvalue-wrapper"></a>`_.wrap(value, wrapper)`
<a href="#_wrapvalue-wrapper">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3778 "View in source") [&#x24C9;][1] <a href="#_wrapvalue-wrapper">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3777 "View in source") [&#x24C9;][1]
Creates a function that passes `value` to the `wrapper` function as its first argument. Additional arguments passed to the function are appended to those passed to the `wrapper` function. The `wrapper` is executed with the `this` binding of the created function. Creates a function that passes `value` to the `wrapper` function as its first argument. Additional arguments passed to the function are appended to those passed to the `wrapper` function. The `wrapper` is executed with the `this` binding of the created function.
@@ -2739,7 +2739,7 @@ _.values({ 'one': 1, 'two': 2, 'three': 3 });
<!-- div --> <!-- div -->
### <a id="_escapestring"></a>`_.escape(string)` ### <a id="_escapestring"></a>`_.escape(string)`
<a href="#_escapestring">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3802 "View in source") [&#x24C9;][1] <a href="#_escapestring">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3801 "View in source") [&#x24C9;][1]
Converts the characters `&`, `<`, `>`, `"`, and `'` in `string` to their corresponding HTML entities. Converts the characters `&`, `<`, `>`, `"`, and `'` in `string` to their corresponding HTML entities.
@@ -2763,7 +2763,7 @@ _.escape('Moe, Larry & Curly');
<!-- div --> <!-- div -->
### <a id="_identityvalue"></a>`_.identity(value)` ### <a id="_identityvalue"></a>`_.identity(value)`
<a href="#_identityvalue">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3820 "View in source") [&#x24C9;][1] <a href="#_identityvalue">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3819 "View in source") [&#x24C9;][1]
This function returns the first argument passed to it. This function returns the first argument passed to it.
@@ -2788,7 +2788,7 @@ moe === _.identity(moe);
<!-- div --> <!-- div -->
### <a id="_mixinobject"></a>`_.mixin(object)` ### <a id="_mixinobject"></a>`_.mixin(object)`
<a href="#_mixinobject">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3846 "View in source") [&#x24C9;][1] <a href="#_mixinobject">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3845 "View in source") [&#x24C9;][1]
Adds functions properties of `object` to the `lodash` function and chainable wrapper. Adds functions properties of `object` to the `lodash` function and chainable wrapper.
@@ -2818,7 +2818,7 @@ _('curly').capitalize();
<!-- div --> <!-- div -->
### <a id="_noconflict"></a>`_.noConflict()` ### <a id="_noconflict"></a>`_.noConflict()`
<a href="#_noconflict">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3872 "View in source") [&#x24C9;][1] <a href="#_noconflict">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3869 "View in source") [&#x24C9;][1]
Reverts the '_' variable to its previous value and returns a reference to the `lodash` function. Reverts the '_' variable to its previous value and returns a reference to the `lodash` function.
@@ -2838,7 +2838,7 @@ var lodash = _.noConflict();
<!-- div --> <!-- div -->
### <a id="_randommin0-max1"></a>`_.random([min=0, max=1])` ### <a id="_randommin0-max1"></a>`_.random([min=0, max=1])`
<a href="#_randommin0-max1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3895 "View in source") [&#x24C9;][1] <a href="#_randommin0-max1">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3892 "View in source") [&#x24C9;][1]
Produces a random number between `min` and `max` *(inclusive)*. If only one argument is passed, a number between `0` and the given number will be returned. Produces a random number between `min` and `max` *(inclusive)*. If only one argument is passed, a number between `0` and the given number will be returned.
@@ -2866,7 +2866,7 @@ _.random(5);
<!-- div --> <!-- div -->
### <a id="_resultobject-property"></a>`_.result(object, property)` ### <a id="_resultobject-property"></a>`_.result(object, property)`
<a href="#_resultobject-property">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3933 "View in source") [&#x24C9;][1] <a href="#_resultobject-property">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3930 "View in source") [&#x24C9;][1]
Resolves the value of `property` on `object`. If `property` is a function it will be invoked and its result returned, else the property value is returned. If `object` is falsey, then `null` is returned. Resolves the value of `property` on `object`. If `property` is a function it will be invoked and its result returned, else the property value is returned. If `object` is falsey, then `null` is returned.
@@ -2901,7 +2901,7 @@ _.result(object, 'stuff');
<!-- div --> <!-- div -->
### <a id="_templatetext-data-options"></a>`_.template(text, data, options)` ### <a id="_templatetext-data-options"></a>`_.template(text, data, options)`
<a href="#_templatetext-data-options">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4018 "View in source") [&#x24C9;][1] <a href="#_templatetext-data-options">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4015 "View in source") [&#x24C9;][1]
A micro-templating method that handles arbitrary delimiters, preserves whitespace, and correctly escapes quotes within interpolated code. A micro-templating method that handles arbitrary delimiters, preserves whitespace, and correctly escapes quotes within interpolated code.
@@ -2979,7 +2979,7 @@ fs.writeFileSync(path.join(cwd, 'jst.js'), '\
<!-- div --> <!-- div -->
### <a id="_timesn-callback--thisarg"></a>`_.times(n, callback [, thisArg])` ### <a id="_timesn-callback--thisarg"></a>`_.times(n, callback [, thisArg])`
<a href="#_timesn-callback--thisarg">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4149 "View in source") [&#x24C9;][1] <a href="#_timesn-callback--thisarg">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4146 "View in source") [&#x24C9;][1]
Executes the `callback` function `n` times, returning an array of the results of each `callback` execution. The `callback` is bound to `thisArg` and invoked with one argument; *(index)*. Executes the `callback` function `n` times, returning an array of the results of each `callback` execution. The `callback` is bound to `thisArg` and invoked with one argument; *(index)*.
@@ -3011,7 +3011,7 @@ _.times(3, function(n) { this.cast(n); }, mage);
<!-- div --> <!-- div -->
### <a id="_unescapestring"></a>`_.unescape(string)` ### <a id="_unescapestring"></a>`_.unescape(string)`
<a href="#_unescapestring">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4175 "View in source") [&#x24C9;][1] <a href="#_unescapestring">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4172 "View in source") [&#x24C9;][1]
The opposite of `_.escape`, this method converts the HTML entities `&amp;`, `&lt;`, `&gt;`, `&quot;`, and `&#x27;` in `string` to their corresponding characters. The opposite of `_.escape`, this method converts the HTML entities `&amp;`, `&lt;`, `&gt;`, `&quot;`, and `&#x27;` in `string` to their corresponding characters.
@@ -3035,7 +3035,7 @@ _.unescape('Moe, Larry &amp; Curly');
<!-- div --> <!-- div -->
### <a id="_uniqueidprefix"></a>`_.uniqueId([prefix])` ### <a id="_uniqueidprefix"></a>`_.uniqueId([prefix])`
<a href="#_uniqueidprefix">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4195 "View in source") [&#x24C9;][1] <a href="#_uniqueidprefix">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4192 "View in source") [&#x24C9;][1]
Generates a unique ID. If `prefix` is passed, the ID will be appended to it. Generates a unique ID. If `prefix` is passed, the ID will be appended to it.
@@ -3069,7 +3069,7 @@ _.uniqueId();
<!-- div --> <!-- div -->
### <a id="_version"></a>`_.VERSION` ### <a id="_version"></a>`_.VERSION`
<a href="#_version">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4422 "View in source") [&#x24C9;][1] <a href="#_version">#</a> [&#x24C8;](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4419 "View in source") [&#x24C9;][1]
*(String)*: The semantic version number. *(String)*: The semantic version number.

View File

@@ -2705,8 +2705,7 @@
* // => [2, 3, 4] * // => [2, 3, 4]
*/ */
function toArray(collection) { function toArray(collection) {
var length = collection ? collection.length : 0; if (collection && typeof collection.length == 'number') {
if (typeof length == 'number') {
return noCharByIndex && isString(collection) return noCharByIndex && isString(collection)
? collection.split('') ? collection.split('')
: slice(collection); : slice(collection);
@@ -3850,9 +3849,7 @@
lodash.prototype[methodName] = function() { lodash.prototype[methodName] = function() {
var args = [this.__wrapped__]; var args = [this.__wrapped__];
push.apply(args, arguments); push.apply(args, arguments);
return new lodash(func.apply(lodash, args));
var result = func.apply(lodash, args);
return new lodash(result);
}; };
}); });
} }
@@ -4447,8 +4444,7 @@
each(['concat', 'slice', 'splice'], function(methodName) { each(['concat', 'slice', 'splice'], function(methodName) {
var func = arrayRef[methodName]; var func = arrayRef[methodName];
lodash.prototype[methodName] = function() { lodash.prototype[methodName] = function() {
var result = func.apply(this.__wrapped__, arguments); return new lodash(func.apply(this.__wrapped__, arguments));
return new lodash(result);
}; };
}); });

68
lodash.min.js vendored
View File

@@ -3,37 +3,37 @@
* Lo-Dash 1.0.0-rc.3 lodash.com/license * Lo-Dash 1.0.0-rc.3 lodash.com/license
* Underscore.js 1.4.3 underscorejs.org/LICENSE * Underscore.js 1.4.3 underscorejs.org/LICENSE
*/ */
;(function(n,t){function r(n){return n&&typeof n=="object"&&n.__wrapped__?n:this instanceof r?(this.__wrapped__=n,void 0):new r(n)}function e(n,t,r){t||(t=0);var e=n.length,u=e-t>=(r||it);if(u)for(var o={},r=t-1;e>++r;){var i=n[r]+"";(Et.call(o,i)?o[i]:o[i]=[]).push(n[r])}return function(r){if(u){var e=r+"";return Et.call(o,e)&&C(o[e],r)>-1}return C(n,r,t)>-1}}function u(n){return n.charCodeAt(0)}function o(n,t){var r=n.b,e=t.b,n=n.a,t=t.a;if(n!==t){if(n>t||n===void 0)return 1;if(t>n||t===void 0)return-1 ;(function(n,t){function r(n){return n&&typeof n=="object"&&n.__wrapped__?n:this instanceof r?(this.__wrapped__=n,void 0):new r(n)}function e(n,t,r){t||(t=0);var e=n.length,u=e-t>=(r||et);if(u)for(var o={},r=t-1;e>++r;){var i=n[r]+"";(xt.call(o,i)?o[i]:o[i]=[]).push(n[r])}return function(r){if(u){var e=r+"";return xt.call(o,e)&&C(o[e],r)>-1}return C(n,r,t)>-1}}function u(n){return n.charCodeAt(0)}function o(n,t){var r=n.b,e=t.b,n=n.a,t=t.a;if(n!==t){if(n>t||n===void 0)return 1;if(t>n||t===void 0)return-1
}return e>r?-1:1}function i(n,t,r){function e(){var a=arguments,f=o?this:t;return u||(n=t[i]),r.length&&(a=a.length?r.concat(v(a)):r),this instanceof e?(s.prototype=n.prototype,f=new s,s.prototype=W,a=n.apply(f,a),x(a)?a:f):n.apply(f,a)}var u=j(n),o=!r,i=t;return o&&(r=t),u||(t=n),e}function a(n,t,r){return n?typeof n!="function"?function(t){return t[n]}:t!==void 0?r?function(r,e,u,o){return n.call(t,r,e,u,o)}:function(r,e,u){return n.call(t,r,e,u)}:n:G}function f(){for(var n,t={b:"",c:"",e:nt,f:Qt,g:"",h:Xt,i:nr,j:wt,k:"",l:Q},r=0;n=arguments[r];r++)for(var e in n)t[e]=n[e]; }return e>r?-1:1}function i(n,t,r){function e(){var a=arguments,f=o?this:t;return u||(n=t[i]),r.length&&(a=a.length?r.concat(v(a)):r),this instanceof e?(s.prototype=n.prototype,f=new s,s.prototype=null,a=n.apply(f,a),x(a)?a:f):n.apply(f,a)}var u=j(n),o=!r,i=t;return o&&(r=t),u||(t=n),e}function a(n,t,r){return n?typeof n!="function"?function(t){return t[n]}:t!==void 0?r?function(r,e,u,o){return n.call(t,r,e,u,o)}:function(r,e,u){return n.call(t,r,e,u)}:n:G}function f(){for(var n,t={b:"",c:"",e:X,f:Gt,g:"",h:Jt,i:Xt,j:_t,k:"",l:!0},r=0;n=arguments[r];r++)for(var e in n)t[e]=n[e];
if(n=t.a,t.d=/^[^,]+/.exec(n)[0],r="var i,l="+t.d+",t="+t.d+";if(!"+t.d+")return t;"+t.k+";",t.b?(r+="var m=l.length;i=-1;if(typeof m=='number'){",t.i&&(r+="if(k(l)){l=l.split('')}"),r+="while(++i<m){"+t.b+"}}else {"):t.h&&(r+="var m=l.length;i=-1;if(m&&j(l)){while(++i<m){i+='';"+t.g+"}}else {"),t.e||(r+="var u=typeof l=='function'&&s.call(l,'prototype');"),t.f&&t.l?(r+="var q=-1,r=p[typeof l]?n(l):[],m=r.length;while(++q<m){i=r[q];",t.e||(r+="if(!(u&&i=='prototype')){"),r+=t.g+"",t.e||(r+="}")):(r+="for(i in l){",(!t.e||t.l)&&(r+="if(",t.e||(r+="!(u&&i=='prototype')"),!t.e&&t.l&&(r+="&&"),t.l&&(r+="h.call(l,i)"),r+="){"),r+=t.g+";",(!t.e||t.l)&&(r+="}")),r+="}",t.e)for(r+="var f=l.constructor;",e=0;7>e;e++)r+="i='"+t.j[e]+"';if(","constructor"==t.j[e]&&(r+="!(f&&f.prototype===l)&&"),r+="h.call(l,i)){"+t.g+"}"; if(n=t.a,t.d=/^[^,]+/.exec(n)[0],r=Function,e="var i,l="+t.d+",t="+t.d+";if(!"+t.d+")return t;"+t.k+";",t.b?(e+="var m=l.length;i=-1;if(typeof m=='number'){",t.i&&(e+="if(k(l)){l=l.split('')}"),e+="while(++i<m){"+t.b+"}}else {"):t.h&&(e+="var m=l.length;i=-1;if(m&&j(l)){while(++i<m){i+='';"+t.g+"}}else {"),t.e||(e+="var u=typeof l=='function'&&s.call(l,'prototype');"),t.f&&t.l?(e+="var q=-1,r=p[typeof l]?n(l):[],m=r.length;while(++q<m){i=r[q];",t.e||(e+="if(!(u&&i=='prototype')){"),e+=t.g+"",t.e||(e+="}")):(e+="for(i in l){",(!t.e||t.l)&&(e+="if(",t.e||(e+="!(u&&i=='prototype')"),!t.e&&t.l&&(e+="&&"),t.l&&(e+="h.call(l,i)"),e+="){"),e+=t.g+";",(!t.e||t.l)&&(e+="}")),e+="}",t.e){e+="var f=l.constructor;";
return(t.b||t.h)&&(r+="}"),r+=t.c+";return t",Function("e,h,j,k,p,n,s","return function("+n+"){"+r+"}")(a,Et,h,A,or,Dt,kt)}function c(n){return"\\"+ir[n]}function l(n){return hr[n]}function p(n){return typeof n.toString!="function"&&typeof(n+"")=="string"}function s(){}function v(n,t,r){t||(t=0),r===void 0&&(r=n?n.length:0);for(var e=-1,r=r-t||0,u=Array(0>r?0:r);r>++e;)u[e]=n[t+e];return u}function g(n){return yr[n]}function h(n){return $t.call(n)==Mt}function y(n){var t=X;if(!n||typeof n!="object"||h(n))return t; for(var u=0;7>u;u++)e+="i='"+t.j[u]+"';if(","constructor"==t.j[u]&&(e+="!(f&&f.prototype===l)&&"),e+="h.call(l,i)){"+t.g+"}"}return(t.b||t.h)&&(e+="}"),e+=t.c+";return t",r("e,h,j,k,p,n,s","return function("+n+"){"+e+"}")(a,xt,h,A,rr,Nt,At)}function c(n){return"\\"+er[n]}function l(n){return sr[n]}function p(n){return typeof n.toString!="function"&&typeof(n+"")=="string"}function s(){}function v(n,t,r){t||(t=0),r===void 0&&(r=n?n.length:0);for(var e=-1,r=r-t||0,u=Array(0>r?0:r);r>++e;)u[e]=n[t+e];
var r=n.constructor;return!j(r)&&(!tr||!p(n))||r instanceof r?tt?(sr(n,function(n,r,e){return t=!Et.call(e,r),X}),t===X):(sr(n,function(n,r){t=r}),t===X||Et.call(n,t)):t}function m(n){var t=[];return vr(n,function(n,r){t.push(r)}),t}function _(n,t,r,e,u){if(n==W)return n;if(r&&(t=X),r=x(n)){var o=$t.call(n);if(!er[o]||tr&&p(n))return n;var i=_r(n)}if(!r||!t)return r?i?v(n):pr({},n):n;switch(r=ur[o],o){case zt:case Ct:return new r(+n);case Kt:case Vt:return new r(n);case Ut:return r(n.source,vt.exec(n)) return u}function g(n){return vr[n]}function h(n){return Et.call(n)==It}function y(n){var t=!1;if(!n||typeof n!="object"||h(n))return t;var r=n.constructor;return!j(r)&&(!Yt||!p(n))||r instanceof r?Y?(cr(n,function(n,r,e){return t=!xt.call(e,r),!1}),!1===t):(cr(n,function(n,r){t=r}),!1===t||xt.call(n,t)):t}function m(n){var t=[];return lr(n,function(n,r){t.push(r)}),t}function _(n,t,r,e,u){if(null==n)return n;if(r&&(t=!1),r=x(n)){var o=Et.call(n);if(!nr[o]||Yt&&p(n))return n;var i=hr(n)}if(!r||!t)return r?i?v(n):fr({},n):n;
}for(e||(e=[]),u||(u=[]),o=e.length;o--;)if(e[o]==n)return u[o];var a=i?r(n.length):{};return e.push(n),u.push(a),(i?R:vr)(n,function(n,r){a[r]=_(n,t,W,e,u)}),i&&(Et.call(n,"index")&&(a.index=n.index),Et.call(n,"input")&&(a.input=n.input)),a}function d(n){var t=[];return sr(n,function(n,r){j(n)&&t.push(r)}),t.sort()}function b(n){for(var t=-1,r=gr(n),e=r.length,u={};e>++t;){var o=r[t];u[n[o]]=o}return u}function w(n,t,r,e){if(n===t)return 0!==n||1/n==1/t;if(n==W||t==W)return n===t;var u=$t.call(n),o=$t.call(t); switch(r=tr[o],o){case Bt:case Mt:return new r(+n);case Pt:case Kt:return new r(n);case Ct:return r(n.source,lt.exec(n))}for(e||(e=[]),u||(u=[]),o=e.length;o--;)if(e[o]==n)return u[o];var a=i?r(n.length):{};return e.push(n),u.push(a),(i?R:lr)(n,function(n,r){a[r]=_(n,t,null,e,u)}),i&&(xt.call(n,"index")&&(a.index=n.index),xt.call(n,"input")&&(a.input=n.input)),a}function d(n){var t=[];return cr(n,function(n,r){j(n)&&t.push(r)}),t.sort()}function b(n){for(var t=-1,r=pr(n),e=r.length,u={};e>++t;){var o=r[t];
if(u==Mt&&(u=Lt),o==Mt&&(o=Lt),u!=o)return X;switch(u){case zt:case Ct:return+n==+t;case Kt:return n!=+n?t!=+t:0==n?1/n==1/t:n==+t;case Ut:case Vt:return n==t+""}if(o=u==Pt,!o){if(n.__wrapped__||t.__wrapped__)return w(n.__wrapped__||n,t.__wrapped__||t);if(u!=Lt||tr&&(p(n)||p(t)))return X;var u=!Yt&&h(n)?Object:n.constructor,i=!Yt&&h(t)?Object:t.constructor;if(!(u==i||j(u)&&u instanceof u&&j(i)&&i instanceof i))return X}for(r||(r=[]),e||(e=[]),u=r.length;u--;)if(r[u]==n)return e[u]==t;var a=Q,f=0; u[n[o]]=o}return u}function w(n,t,r,e){if(n===t)return 0!==n||1/n==1/t;if(null==n||null==t)return n===t;var u=Et.call(n),o=Et.call(t);if(u==It&&(u=zt),o==It&&(o=zt),u!=o)return!1;switch(u){case Bt:case Mt:return+n==+t;case Pt:return n!=+n?t!=+t:0==n?1/n==1/t:n==+t;case Ct:case Kt:return n==t+""}if(o=u==Tt,!o){if(n.__wrapped__||t.__wrapped__)return w(n.__wrapped__||n,t.__wrapped__||t);if(u!=zt||Yt&&(p(n)||p(t)))return!1;var u=!Qt&&h(n)?Object:n.constructor,i=!Qt&&h(t)?Object:t.constructor;if(!(u==i||j(u)&&u instanceof u&&j(i)&&i instanceof i))return!1
if(r.push(n),e.push(t),o){if(f=n.length,a=f==t.length)for(;f--&&(a=w(n[f],t[f],r,e)););return a}return sr(n,function(n,u,o){return Et.call(o,u)?(f++,a=Et.call(t,u)&&w(n,t[u],r,e)):void 0}),a&&sr(t,function(n,t,r){return Et.call(r,t)?a=--f>-1:void 0}),a}function j(n){return typeof n=="function"}function x(n){return n?or[typeof n]:X}function O(n){return typeof n=="number"||$t.call(n)==Kt}function A(n){return typeof n=="string"||$t.call(n)==Vt}function E(n,t,r){var e=arguments,u=0,o=2,i=e[3],a=e[4];for(r!==ot&&(i=[],a=[],typeof r!="number"&&(o=e.length));o>++u;)vr(e[u],function(t,r){var e,u,o; }for(r||(r=[]),e||(e=[]),u=r.length;u--;)if(r[u]==n)return e[u]==t;var a=!0,f=0;if(r.push(n),e.push(t),o){if(f=n.length,a=f==t.length)for(;f--&&(a=w(n[f],t[f],r,e)););return a}return cr(n,function(n,u,o){return xt.call(o,u)?(f++,a=xt.call(t,u)&&w(n,t[u],r,e)):void 0}),a&&cr(t,function(n,t,r){return xt.call(r,t)?a=--f>-1:void 0}),a}function j(n){return typeof n=="function"}function x(n){return n?rr[typeof n]:!1}function O(n){return typeof n=="number"||Et.call(n)==Pt}function A(n){return typeof n=="string"||Et.call(n)==Kt
if(t&&((u=_r(t))||dr(t))){for(var f=i.length;f--&&!(e=i[f]==t););e?n[r]=a[f]:(i.push(t),a.push((o=n[r],o=u?_r(o)?o:[]:dr(o)?o:{})),n[r]=E(o,t,ot,i,a))}else t!=W&&(n[r]=t)});return n}function S(n){for(var t=-1,r=gr(n),e=r.length,u=Array(e);e>++t;)u[t]=n[r[t]];return u}function k(n,t,r){var e=-1,u=n?n.length:0,o=X,r=(0>r?It(0,u+r):r)||0;return typeof u=="number"?o=(A(n)?n.indexOf(t,r):C(n,t,r))>-1:lr(n,function(n){return r>++e?void 0:!(o=n===t)}),o}function $(n,t,r){var e=Q,t=a(t,r);if(_r(n))for(var r=-1,u=n.length;u>++r&&(e=!!t(n[r],r,n)););else lr(n,function(n,r,u){return e=!!t(n,r,u) }function E(n,t,r){var e=arguments,u=0,o=2,i=e[3],a=e[4];for(r!==rt&&(i=[],a=[],typeof r!="number"&&(o=e.length));o>++u;)lr(e[u],function(t,r){var e,u,o;if(t&&((u=hr(t))||yr(t))){for(var f=i.length;f--&&!(e=i[f]==t););e?n[r]=a[f]:(i.push(t),a.push((o=n[r],o=u?hr(o)?o:[]:yr(o)?o:{})),n[r]=E(o,t,rt,i,a))}else null!=t&&(n[r]=t)});return n}function S(n){for(var t=-1,r=pr(n),e=r.length,u=Array(e);e>++t;)u[t]=n[r[t]];return u}function k(n,t,r){var e=-1,u=n?n.length:0,o=!1,r=(0>r?Rt(0,u+r):r)||0;return typeof u=="number"?o=(A(n)?n.indexOf(t,r):C(n,t,r))>-1:ar(n,function(n){return r>++e?void 0:!(o=n===t)
});return e}function q(n,t,r){var e=[],t=a(t,r);if(_r(n))for(var r=-1,u=n.length;u>++r;){var o=n[r];t(o,r,n)&&e.push(o)}else lr(n,function(n,r,u){t(n,r,u)&&e.push(n)});return e}function N(n,t,r){var e,t=a(t,r);return R(n,function(n,r,u){return t(n,r,u)?(e=n,X):void 0}),e}function R(n,t,r){if(t&&r===void 0&&_r(n))for(var r=-1,e=n.length;e>++r&&t(n[r],r,n)!==X;);else lr(n,t,r);return n}function F(n,t,r){var e=-1,u=n?n.length:0,o=Array(typeof u=="number"?u:0),t=a(t,r);if(_r(n))for(;u>++e;)o[e]=t(n[e],e,n); }),o}function $(n,t,r){var e=!0,t=a(t,r);if(hr(n))for(var r=-1,u=n.length;u>++r&&(e=!!t(n[r],r,n)););else ar(n,function(n,r,u){return e=!!t(n,r,u)});return e}function q(n,t,r){var e=[],t=a(t,r);if(hr(n))for(var r=-1,u=n.length;u>++r;){var o=n[r];t(o,r,n)&&e.push(o)}else ar(n,function(n,r,u){t(n,r,u)&&e.push(n)});return e}function N(n,t,r){var e,t=a(t,r);return R(n,function(n,r,u){return t(n,r,u)?(e=n,!1):void 0}),e}function R(n,t,r){if(t&&r===void 0&&hr(n))for(var r=-1,e=n.length;e>++r&&!1!==t(n[r],r,n););else ar(n,t,r);
else lr(n,function(n,r,u){o[++e]=t(n,r,u)});return o}function D(n,t,r){var e=-1/0,o=e;if(!t&&_r(n))for(var r=-1,i=n.length;i>++r;){var f=n[r];f>o&&(o=f)}else t=!t&&A(n)?u:a(t,r),lr(n,function(n,r,u){r=t(n,r,u),r>e&&(e=r,o=n)});return o}function I(n,t){return F(n,t+"")}function T(n,t,r,e){var u=3>arguments.length,t=a(t,e,ot);if(_r(n)){var o=-1,i=n.length;for(u&&(r=n[++o]);i>++o;)r=t(r,n[o],o,n)}else lr(n,function(n,e,o){r=u?(u=X,n):t(r,n,e,o)});return r}function B(n,t,r,e){var u=n,o=n?n.length:0,i=3>arguments.length; return n}function F(n,t,r){var e=-1,u=n?n.length:0,o=Array(typeof u=="number"?u:0),t=a(t,r);if(hr(n))for(;u>++e;)o[e]=t(n[e],e,n);else ar(n,function(n,r,u){o[++e]=t(n,r,u)});return o}function D(n,t,r){var e=-1/0,o=e;if(!t&&hr(n))for(var r=-1,i=n.length;i>++r;){var f=n[r];f>o&&(o=f)}else t=!t&&A(n)?u:a(t,r),ar(n,function(n,r,u){r=t(n,r,u),r>e&&(e=r,o=n)});return o}function I(n,t){return F(n,t+"")}function T(n,t,r,e){var u=3>arguments.length,t=a(t,e,rt);if(hr(n)){var o=-1,i=n.length;for(u&&(r=n[++o]);i>++o;)r=t(r,n[o],o,n)
if(typeof o!="number")var f=gr(n),o=f.length;else nr&&A(n)&&(u=n.split(""));return t=a(t,e,ot),R(n,function(n,e,a){e=f?f[--o]:--o,r=i?(i=X,u[e]):t(r,u[e],e,a)}),r}function M(n,t,r){var e,t=a(t,r);if(_r(n))for(var r=-1,u=n.length;u>++r&&!(e=t(n[r],r,n)););else lr(n,function(n,r,u){return!(e=t(n,r,u))});return!!e}function P(n,t,r){if(n){var e=n.length;return t==W||r?n[0]:v(n,0,Tt(It(0,t),e))}}function z(n,t){for(var r=-1,e=n?n.length:0,u=[];e>++r;){var o=n[r];_r(o)?St.apply(u,t?o:z(o)):u.push(o)}return u }else ar(n,function(n,e,o){r=u?(u=!1,n):t(r,n,e,o)});return r}function B(n,t,r,e){var u=n,o=n?n.length:0,i=3>arguments.length;if(typeof o!="number")var f=pr(n),o=f.length;else Xt&&A(n)&&(u=n.split(""));return t=a(t,e,rt),R(n,function(n,e,a){e=f?f[--o]:--o,r=i?(i=!1,u[e]):t(r,u[e],e,a)}),r}function M(n,t,r){var e,t=a(t,r);if(hr(n))for(var r=-1,u=n.length;u>++r&&!(e=t(n[r],r,n)););else ar(n,function(n,r,u){return!(e=t(n,r,u))});return!!e}function P(n,t,r){if(n){var e=n.length;return null==t||r?n[0]:v(n,0,Ft(Rt(0,t),e))
}function C(n,t,r){var e=-1,u=n?n.length:0;if(typeof r=="number")e=(0>r?It(0,u+r):r||0)-1;else if(r)return e=L(n,t),n[e]===t?e:-1;for(;u>++e;)if(n[e]===t)return e;return-1}function K(n,t,r){return v(n,t==W||r?1:It(0,t))}function L(n,t,r,e){for(var u=0,o=n?n.length:u,r=r?a(r,e):G,t=r(t);o>u;)e=u+o>>>1,t>r(n[e])?u=e+1:o=e;return u}function U(n,t,r,e){var u=-1,o=n?n.length:0,i=[],f=i;typeof t=="function"&&(e=r,r=t,t=X);var c=!t&&o>=75;if(c)var l={};for(r&&(f=[],r=a(r,e));o>++u;){var e=n[u],p=r?r(e,u,n):e; }}function z(n,t){for(var r=-1,e=n?n.length:0,u=[];e>++r;){var o=n[r];hr(o)?Ot.apply(u,t?o:z(o)):u.push(o)}return u}function C(n,t,r){var e=-1,u=n?n.length:0;if(typeof r=="number")e=(0>r?Rt(0,u+r):r||0)-1;else if(r)return e=L(n,t),n[e]===t?e:-1;for(;u>++e;)if(n[e]===t)return e;return-1}function K(n,t,r){return v(n,null==t||r?1:Rt(0,t))}function L(n,t,r,e){for(var u=0,o=n?n.length:u,r=r?a(r,e):G,t=r(t);o>u;)e=u+o>>>1,t>r(n[e])?u=e+1:o=e;return u}function U(n,t,r,e){var u=-1,o=n?n.length:0,i=[],f=i;
if(c)var s=p+"",s=Et.call(l,s)?!(f=l[s]):f=l[s]=[];(t?!u||f[f.length-1]!==p:s||0>C(f,p))&&((r||c)&&f.push(p),i.push(e))}return i}function V(n,t){return Jt||qt&&arguments.length>2?qt.call.apply(qt,arguments):i(n,t,v(arguments,2))}function G(n){return n}function H(n){R(d(n),function(t){var e=r[t]=n[t];r.prototype[t]=function(){var n=[this.__wrapped__];return St.apply(n,arguments),n=e.apply(r,n),new r(n)}})}function J(){return this.__wrapped__}var Q=!0,W=null,X=!1,Y=typeof exports=="object"&&exports,Z=typeof global=="object"&&global; typeof t=="function"&&(e=r,r=t,t=!1);var c=!t&&o>=75;if(c)var l={};for(r&&(f=[],r=a(r,e));o>++u;){var e=n[u],p=r?r(e,u,n):e;if(c)var s=p+"",s=xt.call(l,s)?!(f=l[s]):f=l[s]=[];(t?!u||f[f.length-1]!==p:s||0>C(f,p))&&((r||c)&&f.push(p),i.push(e))}return i}function V(n,t){return Vt||St&&arguments.length>2?St.call.apply(St,arguments):i(n,t,v(arguments,2))}function G(n){return n}function H(n){R(d(n),function(t){var e=r[t]=n[t];r.prototype[t]=function(){var n=[this.__wrapped__];return Ot.apply(n,arguments),new r(e.apply(r,n))
Z.global===Z&&(n=Z);var nt,tt,rt=[],et=new function(){},ut=0,ot=et,it=30,at=n._,ft=/[-?+=!~*%&^<>|{(\/]|\[\D|\b(?:delete|in|instanceof|new|typeof|void)\b/,ct=/&(?:amp|lt|gt|quot|#x27);/g,lt=/\b__p\+='';/g,pt=/\b(__p\+=)''\+/g,st=/(__e\(.*?\)|\b__t\))\+'';/g,vt=/\w*$/,gt=/(?:__e|__t=)\(\s*(?![\d\s"']|this\.)/g,ht=RegExp("^"+(et.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&").replace(/valueOf|for [^\]]+/g,".+?")+"$"),yt=/\$\{((?:(?=\\?)\\?[\s\S])*?)}/g,mt=/<%=([\s\S]+?)%>/g,_t=/($^)/,dt=/[&<>"']/g,bt=/['\n\r\t\u2028\u2029\\]/g,wt="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" "),jt=Math.ceil,xt=rt.concat,Ot=Math.floor,At=ht.test(At=Object.getPrototypeOf)&&At,Et=et.hasOwnProperty,St=rt.push,kt=et.propertyIsEnumerable,$t=et.toString,qt=ht.test(qt=v.bind)&&qt,Nt=ht.test(Nt=Array.isArray)&&Nt,Rt=n.isFinite,Ft=n.isNaN,Dt=ht.test(Dt=Object.keys)&&Dt,It=Math.max,Tt=Math.min,Bt=Math.random,Mt="[object Arguments]",Pt="[object Array]",zt="[object Boolean]",Ct="[object Date]",Kt="[object Number]",Lt="[object Object]",Ut="[object RegExp]",Vt="[object String]",Gt=!!n.attachEvent,Ht=qt&&!/\n|true/.test(qt+Gt),Jt=qt&&!Ht,Qt=Dt&&(Gt||Ht),Wt=(Wt={0:1,length:1},rt.splice.call(Wt,0,1),Wt[0]),Xt=Q; }})}function J(){return this.__wrapped__}var Q=typeof exports=="object"&&exports,W=typeof global=="object"&&global;W.global===W&&(n=W);var X,Y,Z=[],nt=new function(){},tt=0,rt=nt,et=30,ut=n._,ot=/[-?+=!~*%&^<>|{(\/]|\[\D|\b(?:delete|in|instanceof|new|typeof|void)\b/,it=/&(?:amp|lt|gt|quot|#x27);/g,at=/\b__p\+='';/g,ft=/\b(__p\+=)''\+/g,ct=/(__e\(.*?\)|\b__t\))\+'';/g,lt=/\w*$/,pt=/(?:__e|__t=)\(\s*(?![\d\s"']|this\.)/g,st=RegExp("^"+(nt.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&").replace(/valueOf|for [^\]]+/g,".+?")+"$"),vt=/\$\{((?:(?=\\?)\\?[\s\S])*?)}/g,gt=/<%=([\s\S]+?)%>/g,ht=/($^)/,yt=/[&<>"']/g,mt=/['\n\r\t\u2028\u2029\\]/g,_t="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" "),dt=Math.ceil,bt=Z.concat,wt=Math.floor,jt=st.test(jt=Object.getPrototypeOf)&&jt,xt=nt.hasOwnProperty,Ot=Z.push,At=nt.propertyIsEnumerable,Et=nt.toString,St=st.test(St=v.bind)&&St,kt=st.test(kt=Array.isArray)&&kt,$t=n.isFinite,qt=n.isNaN,Nt=st.test(Nt=Object.keys)&&Nt,Rt=Math.max,Ft=Math.min,Dt=Math.random,It="[object Arguments]",Tt="[object Array]",Bt="[object Boolean]",Mt="[object Date]",Pt="[object Number]",zt="[object Object]",Ct="[object RegExp]",Kt="[object String]",Lt=!!n.attachEvent,Ut=St&&!/\n|true/.test(St+Lt),Vt=St&&!Ut,Gt=Nt&&(Lt||Ut),Ht=(Ht={0:1,length:1},Z.splice.call(Ht,0,1),Ht[0]),Jt=!0;
(function(){function n(){this.x=1}var t=[];n.prototype={valueOf:1,y:1};for(var r in new n)t.push(r);for(r in arguments)Xt=!r;nt=!/valueOf/.test(t),tt="x"!=t[0]})(1);var Yt=arguments.constructor==Object,Zt=!h(arguments),nr="xx"!="x"[0]+Object("x")[0];try{var tr=$t.call(document)==Lt}catch(rr){}var er={"[object Function]":X};er[Mt]=er[Pt]=er[zt]=er[Ct]=er[Kt]=er[Lt]=er[Ut]=er[Vt]=Q;var ur={};ur[Pt]=Array,ur[zt]=Boolean,ur[Ct]=Date,ur[Lt]=Object,ur[Kt]=Number,ur[Ut]=RegExp,ur[Vt]=String;var or={"boolean":X,"function":Q,object:Q,number:X,string:X,undefined:X},ir={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"}; (function(){function n(){this.x=1}var t=[];n.prototype={valueOf:1,y:1};for(var r in new n)t.push(r);for(r in arguments)Jt=!r;X=!/valueOf/.test(t),Y="x"!=t[0]})(1);var Qt=arguments.constructor==Object,Wt=!h(arguments),Xt="xx"!="x"[0]+Object("x")[0];try{var Yt=Et.call(document)==zt}catch(Zt){}var nr={"[object Function]":!1};nr[It]=nr[Tt]=nr[Bt]=nr[Mt]=nr[Pt]=nr[zt]=nr[Ct]=nr[Kt]=!0;var tr={};tr[Tt]=Array,tr[Bt]=Boolean,tr[Mt]=Date,tr[zt]=Object,tr[Pt]=Number,tr[Ct]=RegExp,tr[Kt]=String;var rr={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,undefined:!1},er={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};
r.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:mt,variable:""};var ar={a:"o,v,g",k:"for(var a=1,b=typeof g=='number'?2:arguments.length;a<b;a++){if((l=arguments[a])){",g:"t[i]=l[i]",c:"}}"},fr={a:"d,c,w",k:"c=c&&typeof w=='undefined'?c:e(c,w)",b:"if(c(l[i],i,d)===false)return t",g:"if(c(l[i],i,d)===false)return t"},cr={b:W},lr=f(fr),pr=f(ar);Zt&&(h=function(n){return n?Et.call(n,"callee"):X});var sr=f(fr,cr,{l:X}),vr=f(fr,cr),gr=Dt?function(n){return typeof n=="function"&&kt.call(n,"prototype")?m(n):x(n)?Dt(n):[] r.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:gt,variable:""};var ur={a:"o,v,g",k:"for(var a=1,b=typeof g=='number'?2:arguments.length;a<b;a++){if((l=arguments[a])){",g:"t[i]=l[i]",c:"}}"},or={a:"d,c,w",k:"c=c&&typeof w=='undefined'?c:e(c,w)",b:"if(c(l[i],i,d)===false)return t",g:"if(c(l[i],i,d)===false)return t"},ir={b:null},ar=f(or),fr=f(ur);Wt&&(h=function(n){return n?xt.call(n,"callee"):!1});var cr=f(or,ir,{l:!1}),lr=f(or,ir),pr=Nt?function(n){return typeof n=="function"&&At.call(n,"prototype")?m(n):x(n)?Nt(n):[]
}:m,hr={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;"},yr=b(hr),mr=f(ar,{g:"if(t[i]==null)"+ar.g}),_r=Nt||function(n){return Yt&&n instanceof Array||$t.call(n)==Pt};j(/x/)&&(j=function(n){return n instanceof Function||"[object Function]"==$t.call(n)});var dr=At?function(n){if(!n||typeof n!="object")return X;var t=n.valueOf,r=typeof t=="function"&&(r=At(t))&&At(r);return r?n==r||At(n)==r&&!h(n):y(n)}:y;r.after=function(n,t){return 1>n?t():function(){return 1>--n?t.apply(this,arguments):void 0 }:m,sr={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;"},vr=b(sr),gr=f(ur,{g:"if(t[i]==null)"+ur.g}),hr=kt||function(n){return Qt&&n instanceof Array||Et.call(n)==Tt};j(/x/)&&(j=function(n){return n instanceof Function||"[object Function]"==Et.call(n)});var yr=jt?function(n){if(!n||typeof n!="object")return!1;var t=n.valueOf,r=typeof t=="function"&&(r=jt(t))&&jt(r);return r?n==r||jt(n)==r&&!h(n):y(n)}:y;r.after=function(n,t){return 1>n?t():function(){return 1>--n?t.apply(this,arguments):void 0
}},r.assign=pr,r.at=function(n){var t=-1,r=xt.apply(rt,v(arguments,1)),e=r.length,u=Array(e);for(nr&&A(n)&&(n=n.split(""));e>++t;)u[t]=n[r[t]];return u},r.bind=V,r.bindAll=function(n){for(var t=arguments,r=t.length>1?0:(t=d(n),-1),e=t.length;e>++r;){var u=t[r];n[u]=V(n[u],n)}return n},r.bindKey=function(n,t){return i(n,t,v(arguments,2))},r.compact=function(n){for(var t=-1,r=n?n.length:0,e=[];r>++t;){var u=n[t];u&&e.push(u)}return e},r.compose=function(){var n=arguments;return function(){for(var t=arguments,r=n.length;r--;)t=[n[r].apply(this,t)]; }},r.assign=fr,r.at=function(n){var t=-1,r=bt.apply(Z,v(arguments,1)),e=r.length,u=Array(e);for(Xt&&A(n)&&(n=n.split(""));e>++t;)u[t]=n[r[t]];return u},r.bind=V,r.bindAll=function(n){for(var t=arguments,r=t.length>1?0:(t=d(n),-1),e=t.length;e>++r;){var u=t[r];n[u]=V(n[u],n)}return n},r.bindKey=function(n,t){return i(n,t,v(arguments,2))},r.compact=function(n){for(var t=-1,r=n?n.length:0,e=[];r>++t;){var u=n[t];u&&e.push(u)}return e},r.compose=function(){var n=arguments;return function(){for(var t=arguments,r=n.length;r--;)t=[n[r].apply(this,t)];
return t[0]}},r.countBy=function(n,t,r){var e={},t=a(t,r);return R(n,function(n,r,u){r=t(n,r,u),Et.call(e,r)?e[r]++:e[r]=1}),e},r.debounce=function(n,t,r){function e(){a=W,r||(o=n.apply(i,u))}var u,o,i,a;return function(){var f=r&&!a;return u=arguments,i=this,clearTimeout(a),a=setTimeout(e,t),f&&(o=n.apply(i,u)),o}},r.defaults=mr,r.defer=function(n){var r=v(arguments,1);return setTimeout(function(){n.apply(t,r)},1)},r.delay=function(n,r){var e=v(arguments,2);return setTimeout(function(){n.apply(t,e) return t[0]}},r.countBy=function(n,t,r){var e={},t=a(t,r);return R(n,function(n,r,u){r=t(n,r,u),xt.call(e,r)?e[r]++:e[r]=1}),e},r.debounce=function(n,t,r){function e(){a=null,r||(o=n.apply(i,u))}var u,o,i,a;return function(){var f=r&&!a;return u=arguments,i=this,clearTimeout(a),a=setTimeout(e,t),f&&(o=n.apply(i,u)),o}},r.defaults=gr,r.defer=function(n){var r=v(arguments,1);return setTimeout(function(){n.apply(t,r)},1)},r.delay=function(n,r){var e=v(arguments,2);return setTimeout(function(){n.apply(t,e)
},r)},r.difference=function(n){for(var t=-1,r=n?n.length:0,u=xt.apply(rt,arguments),u=e(u,r),o=[];r>++t;){var i=n[t];u(i)||o.push(i)}return o},r.filter=q,r.flatten=z,r.forEach=R,r.forIn=sr,r.forOwn=vr,r.functions=d,r.groupBy=function(n,t,r){var e={},t=a(t,r);return R(n,function(n,r,u){r=t(n,r,u),(Et.call(e,r)?e[r]:e[r]=[]).push(n)}),e},r.initial=function(n,t,r){if(!n)return[];var e=n.length;return v(n,0,Tt(It(0,e-(t==W||r?1:t||0)),e))},r.intersection=function(n){var t=arguments,r=t.length,u={0:{}},o=-1,i=n?n.length:0,a=i>=100,f=[],c=f; },r)},r.difference=function(n){for(var t=-1,r=n?n.length:0,u=bt.apply(Z,arguments),u=e(u,r),o=[];r>++t;){var i=n[t];u(i)||o.push(i)}return o},r.filter=q,r.flatten=z,r.forEach=R,r.forIn=cr,r.forOwn=lr,r.functions=d,r.groupBy=function(n,t,r){var e={},t=a(t,r);return R(n,function(n,r,u){r=t(n,r,u),(xt.call(e,r)?e[r]:e[r]=[]).push(n)}),e},r.initial=function(n,t,r){if(!n)return[];var e=n.length;return v(n,0,Ft(Rt(0,e-(null==t||r?1:t||0)),e))},r.intersection=function(n){var t=arguments,r=t.length,u={0:{}},o=-1,i=n?n.length:0,a=i>=100,f=[],c=f;
n:for(;i>++o;){var l=n[o];if(a)var p=l+"",p=Et.call(u[0],p)?!(c=u[0][p]):c=u[0][p]=[];if(p||0>C(c,l)){a&&c.push(l);for(var s=r;--s;)if(!(u[s]||(u[s]=e(t[s],0,100)))(l))continue n;f.push(l)}}return f},r.invert=b,r.invoke=function(n,t){var r=v(arguments,2),e=typeof t=="function",u=[];return R(n,function(n){u.push((e?t:n[t]).apply(n,r))}),u},r.keys=gr,r.map=F,r.max=D,r.memoize=function(n,t){var r={};return function(){var e=t?t.apply(this,arguments):arguments[0];return Et.call(r,e)?r[e]:r[e]=n.apply(this,arguments) n:for(;i>++o;){var l=n[o];if(a)var p=l+"",p=xt.call(u[0],p)?!(c=u[0][p]):c=u[0][p]=[];if(p||0>C(c,l)){a&&c.push(l);for(var s=r;--s;)if(!(u[s]||(u[s]=e(t[s],0,100)))(l))continue n;f.push(l)}}return f},r.invert=b,r.invoke=function(n,t){var r=v(arguments,2),e=typeof t=="function",u=[];return R(n,function(n){u.push((e?t:n[t]).apply(n,r))}),u},r.keys=pr,r.map=F,r.max=D,r.memoize=function(n,t){var r={};return function(){var e=t?t.apply(this,arguments):arguments[0];return xt.call(r,e)?r[e]:r[e]=n.apply(this,arguments)
}},r.merge=E,r.min=function(n,t,r){var e=1/0,o=e;if(!t&&_r(n))for(var r=-1,i=n.length;i>++r;){var f=n[r];o>f&&(o=f)}else t=!t&&A(n)?u:a(t,r),lr(n,function(n,r,u){r=t(n,r,u),e>r&&(e=r,o=n)});return o},r.object=function(n,t){for(var r=-1,e=n?n.length:0,u={};e>++r;){var o=n[r];t?u[o]=t[r]:u[o[0]]=o[1]}return u},r.omit=function(n,t,r){var e=typeof t=="function",u={};if(e)t=a(t,r);else var o=xt.apply(rt,arguments);return sr(n,function(n,r,i){(e?!t(n,r,i):0>C(o,r,1))&&(u[r]=n)}),u},r.once=function(n){var t,r=X; }},r.merge=E,r.min=function(n,t,r){var e=1/0,o=e;if(!t&&hr(n))for(var r=-1,i=n.length;i>++r;){var f=n[r];o>f&&(o=f)}else t=!t&&A(n)?u:a(t,r),ar(n,function(n,r,u){r=t(n,r,u),e>r&&(e=r,o=n)});return o},r.object=function(n,t){for(var r=-1,e=n?n.length:0,u={};e>++r;){var o=n[r];t?u[o]=t[r]:u[o[0]]=o[1]}return u},r.omit=function(n,t,r){var e=typeof t=="function",u={};if(e)t=a(t,r);else var o=bt.apply(Z,arguments);return cr(n,function(n,r,i){(e?!t(n,r,i):0>C(o,r,1))&&(u[r]=n)}),u},r.once=function(n){var t,r=!1;
return function(){return r?t:(r=Q,t=n.apply(this,arguments),n=W,t)}},r.pairs=function(n){for(var t=-1,r=gr(n),e=r.length,u=Array(e);e>++t;){var o=r[t];u[t]=[o,n[o]]}return u},r.partial=function(n){return i(n,v(arguments,1))},r.pick=function(n,t,r){var e={};if(typeof t!="function")for(var u=0,o=xt.apply(rt,arguments),i=o.length;i>++u;){var f=o[u];f in n&&(e[f]=n[f])}else t=a(t,r),sr(n,function(n,r,u){t(n,r,u)&&(e[r]=n)});return e},r.pluck=I,r.range=function(n,t,r){n=+n||0,r=+r||1,t==W&&(t=n,n=0);for(var e=-1,t=It(0,jt((t-n)/r)),u=Array(t);t>++e;)u[e]=n,n+=r; return function(){return r?t:(r=!0,t=n.apply(this,arguments),n=null,t)}},r.pairs=function(n){for(var t=-1,r=pr(n),e=r.length,u=Array(e);e>++t;){var o=r[t];u[t]=[o,n[o]]}return u},r.partial=function(n){return i(n,v(arguments,1))},r.pick=function(n,t,r){var e={};if(typeof t!="function")for(var u=0,o=bt.apply(Z,arguments),i=o.length;i>++u;){var f=o[u];f in n&&(e[f]=n[f])}else t=a(t,r),cr(n,function(n,r,u){t(n,r,u)&&(e[r]=n)});return e},r.pluck=I,r.range=function(n,t,r){n=+n||0,r=+r||1,null==t&&(t=n,n=0);
return u},r.reject=function(n,t,r){return t=a(t,r),q(n,function(n,r,e){return!t(n,r,e)})},r.rest=K,r.shuffle=function(n){var t=-1,r=Array(n?n.length:0);return R(n,function(n){var e=Ot(Bt()*(++t+1));r[t]=r[e],r[e]=n}),r},r.sortBy=function(n,t,r){var e=[],t=a(t,r);for(R(n,function(n,r,u){e.push({a:t(n,r,u),b:r,c:n})}),n=e.length,e.sort(o);n--;)e[n]=e[n].c;return e},r.tap=function(n,t){return t(n),n},r.throttle=function(n,t){function r(){a=new Date,i=W,u=n.apply(o,e)}var e,u,o,i,a=0;return function(){var f=new Date,c=t-(f-a); for(var e=-1,t=Rt(0,dt((t-n)/r)),u=Array(t);t>++e;)u[e]=n,n+=r;return u},r.reject=function(n,t,r){return t=a(t,r),q(n,function(n,r,e){return!t(n,r,e)})},r.rest=K,r.shuffle=function(n){var t=-1,r=Array(n?n.length:0);return R(n,function(n){var e=wt(Dt()*(++t+1));r[t]=r[e],r[e]=n}),r},r.sortBy=function(n,t,r){var e=[],t=a(t,r);for(R(n,function(n,r,u){e.push({a:t(n,r,u),b:r,c:n})}),n=e.length,e.sort(o);n--;)e[n]=e[n].c;return e},r.tap=function(n,t){return t(n),n},r.throttle=function(n,t){function r(){a=new Date,i=null,u=n.apply(o,e)
return e=arguments,o=this,c>0?i||(i=setTimeout(r,c)):(clearTimeout(i),i=W,a=f,u=n.apply(o,e)),u}},r.times=function(n,t,r){for(var n=+n||0,e=-1,u=Array(n);n>++e;)u[e]=t.call(r,e);return u},r.toArray=function(n){return typeof(n?n.length:0)=="number"?nr&&A(n)?n.split(""):v(n):S(n)},r.union=function(){return U(xt.apply(rt,arguments))},r.uniq=U,r.values=S,r.where=function(n,t){var r=gr(t);return q(n,function(n){for(var e=r.length;e--;){var u=n[r[e]]===t[r[e]];if(!u)break}return!!u})},r.without=function(n){for(var t=-1,r=n?n.length:0,u=e(arguments,1,20),o=[];r>++t;){var i=n[t]; }var e,u,o,i,a=0;return function(){var f=new Date,c=t-(f-a);return e=arguments,o=this,c>0?i||(i=setTimeout(r,c)):(clearTimeout(i),i=null,a=f,u=n.apply(o,e)),u}},r.times=function(n,t,r){for(var n=+n||0,e=-1,u=Array(n);n>++e;)u[e]=t.call(r,e);return u},r.toArray=function(n){return n&&typeof n.length=="number"?Xt&&A(n)?n.split(""):v(n):S(n)},r.union=function(){return U(bt.apply(Z,arguments))},r.uniq=U,r.values=S,r.where=function(n,t){var r=pr(t);return q(n,function(n){for(var e=r.length;e--;){var u=n[r[e]]===t[r[e]];
u(i)||o.push(i)}return o},r.wrap=function(n,t){return function(){var r=[n];return St.apply(r,arguments),t.apply(this,r)}},r.zip=function(n){for(var t=-1,r=n?D(I(arguments,"length")):0,e=Array(r);r>++t;)e[t]=I(arguments,t);return e},r.collect=F,r.drop=K,r.each=R,r.extend=pr,r.methods=d,r.select=q,r.tail=K,r.unique=U,H(r),r.clone=_,r.cloneDeep=function(n){return _(n,Q)},r.contains=k,r.escape=function(n){return n==W?"":(n+"").replace(dt,l)},r.every=$,r.find=N,r.has=function(n,t){return n?Et.call(n,t):X if(!u)break}return!!u})},r.without=function(n){for(var t=-1,r=n?n.length:0,u=e(arguments,1,20),o=[];r>++t;){var i=n[t];u(i)||o.push(i)}return o},r.wrap=function(n,t){return function(){var r=[n];return Ot.apply(r,arguments),t.apply(this,r)}},r.zip=function(n){for(var t=-1,r=n?D(I(arguments,"length")):0,e=Array(r);r>++t;)e[t]=I(arguments,t);return e},r.collect=F,r.drop=K,r.each=R,r.extend=fr,r.methods=d,r.select=q,r.tail=K,r.unique=U,H(r),r.clone=_,r.cloneDeep=function(n){return _(n,!0)},r.contains=k,r.escape=function(n){return null==n?"":(n+"").replace(yt,l)
},r.identity=G,r.indexOf=C,r.isArguments=h,r.isArray=_r,r.isBoolean=function(n){return n===Q||n===X||$t.call(n)==zt},r.isDate=function(n){return n instanceof Date||$t.call(n)==Ct},r.isElement=function(n){return n?1===n.nodeType:X},r.isEmpty=function(n){var t=Q;if(!n)return t;var r=$t.call(n),e=n.length;return r==Pt||r==Vt||r==Mt||Zt&&h(n)||r==Lt&&typeof e=="number"&&j(n.splice)?!e:(vr(n,function(){return t=X}),t)},r.isEqual=w,r.isFinite=function(n){return Rt(n)&&!Ft(parseFloat(n))},r.isFunction=j,r.isNaN=function(n){return O(n)&&n!=+n },r.every=$,r.find=N,r.has=function(n,t){return n?xt.call(n,t):!1},r.identity=G,r.indexOf=C,r.isArguments=h,r.isArray=hr,r.isBoolean=function(n){return!0===n||!1===n||Et.call(n)==Bt},r.isDate=function(n){return n instanceof Date||Et.call(n)==Mt},r.isElement=function(n){return n?1===n.nodeType:!1},r.isEmpty=function(n){var t=!0;if(!n)return t;var r=Et.call(n),e=n.length;return r==Tt||r==Kt||r==It||Wt&&h(n)||r==zt&&typeof e=="number"&&j(n.splice)?!e:(lr(n,function(){return t=!1}),t)},r.isEqual=w,r.isFinite=function(n){return $t(n)&&!qt(parseFloat(n))
},r.isNull=function(n){return n===W},r.isNumber=O,r.isObject=x,r.isPlainObject=dr,r.isRegExp=function(n){return n instanceof RegExp||$t.call(n)==Ut},r.isString=A,r.isUndefined=function(n){return n===void 0},r.lastIndexOf=function(n,t,r){var e=n?n.length:0;for(typeof r=="number"&&(e=(0>r?It(0,e+r):Tt(r,e-1))+1);e--;)if(n[e]===t)return e;return-1},r.mixin=H,r.noConflict=function(){return n._=at,this},r.random=function(n,t){return n==W&&t==W&&(t=1),n=+n||0,t==W&&(t=n,n=0),n+Ot(Bt()*((+t||0)-n+1))},r.reduce=T,r.reduceRight=B,r.result=function(n,t){var r=n?n[t]:W; },r.isFunction=j,r.isNaN=function(n){return O(n)&&n!=+n},r.isNull=function(n){return null===n},r.isNumber=O,r.isObject=x,r.isPlainObject=yr,r.isRegExp=function(n){return n instanceof RegExp||Et.call(n)==Ct},r.isString=A,r.isUndefined=function(n){return n===void 0},r.lastIndexOf=function(n,t,r){var e=n?n.length:0;for(typeof r=="number"&&(e=(0>r?Rt(0,e+r):Ft(r,e-1))+1);e--;)if(n[e]===t)return e;return-1},r.mixin=H,r.noConflict=function(){return n._=ut,this},r.random=function(n,t){return null==n&&null==t&&(t=1),n=+n||0,null==t&&(t=n,n=0),n+wt(Dt()*((+t||0)-n+1))
return j(r)?n[t]():r},r.size=function(n){var t=n?n.length:0;return typeof t=="number"?t:gr(n).length},r.some=M,r.sortedIndex=L,r.template=function(n,t,e){n||(n=""),e||(e={});var u,o,i=r.templateSettings,a=0,f=e.interpolate||i.interpolate||_t,l="__p+='",p=e.variable||i.variable,s=p;n.replace(RegExp((e.escape||i.escape||_t).source+"|"+f.source+"|"+(f===mt?yt:_t).source+"|"+(e.evaluate||i.evaluate||_t).source+"|$","g"),function(t,r,e,o,i,f){return e||(e=o),l+=n.slice(a,f).replace(bt,c),r&&(l+="'+__e("+r+")+'"),i&&(l+="';"+i+";__p+='"),e&&(l+="'+((__t=("+e+"))==null?'':__t)+'"),u||(u=i||ft.test(r||e)),a=f+t.length,t },r.reduce=T,r.reduceRight=B,r.result=function(n,t){var r=n?n[t]:null;return j(r)?n[t]():r},r.size=function(n){var t=n?n.length:0;return typeof t=="number"?t:pr(n).length},r.some=M,r.sortedIndex=L,r.template=function(n,t,e){n||(n=""),e||(e={});var u,o,i=r.templateSettings,a=0,f=e.interpolate||i.interpolate||ht,l="__p+='",p=e.variable||i.variable,s=p;n.replace(RegExp((e.escape||i.escape||ht).source+"|"+f.source+"|"+(f===gt?vt:ht).source+"|"+(e.evaluate||i.evaluate||ht).source+"|$","g"),function(t,r,e,o,i,f){return e||(e=o),l+=n.slice(a,f).replace(mt,c),r&&(l+="'+__e("+r+")+'"),i&&(l+="';"+i+";__p+='"),e&&(l+="'+((__t=("+e+"))==null?'':__t)+'"),u||(u=i||ot.test(r||e)),a=f+t.length,t
}),l+="';\n",s||(p="obj",u?l="with("+p+"){"+l+"}":(e=RegExp("(\\(\\s*)"+p+"\\."+p+"\\b","g"),l=l.replace(gt,"$&"+p+".").replace(e,"$1__d"))),l=(u?l.replace(lt,""):l).replace(pt,"$1").replace(st,"$1;"),l="function("+p+"){"+(s?"":p+"||("+p+"={});")+"var __t,__p='',__e=_.escape"+(u?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":(s?"":",__d="+p+"."+p+"||"+p)+";")+l+"return __p}";try{o=Function("_","return "+l)(r)}catch(v){throw v.source=l,v}return t?o(t):(o.source=l,o)},r.unescape=function(n){return n==W?"":(n+"").replace(ct,g) }),l+="';\n",s||(p="obj",u?l="with("+p+"){"+l+"}":(e=RegExp("(\\(\\s*)"+p+"\\."+p+"\\b","g"),l=l.replace(pt,"$&"+p+".").replace(e,"$1__d"))),l=(u?l.replace(at,""):l).replace(ft,"$1").replace(ct,"$1;"),l="function("+p+"){"+(s?"":p+"||("+p+"={});")+"var __t,__p='',__e=_.escape"+(u?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":(s?"":",__d="+p+"."+p+"||"+p)+";")+l+"return __p}";try{o=Function("_","return "+l)(r)}catch(v){throw v.source=l,v}return t?o(t):(o.source=l,o)},r.unescape=function(n){return null==n?"":(n+"").replace(it,g)
},r.uniqueId=function(n){var t=++ut;return(n==W?"":n+"")+t},r.all=$,r.any=M,r.detect=N,r.foldl=T,r.foldr=B,r.include=k,r.inject=T,vr(r,function(n,t){r.prototype[t]||(r.prototype[t]=function(){var t=[this.__wrapped__];return St.apply(t,arguments),n.apply(r,t)})}),r.first=P,r.last=function(n,t,r){if(n){var e=n.length;return t==W||r?n[e-1]:v(n,It(0,e-t))}},r.take=P,r.head=P,vr(r,function(n,t){r.prototype[t]||(r.prototype[t]=function(t,e){var u=n(this.__wrapped__,t,e);return t==W||e?u:new r(u)})}),r.VERSION="1.0.0-rc.3",r.prototype.toString=function(){return this.__wrapped__+"" },r.uniqueId=function(n){var t=++tt;return(null==n?"":n+"")+t},r.all=$,r.any=M,r.detect=N,r.foldl=T,r.foldr=B,r.include=k,r.inject=T,lr(r,function(n,t){r.prototype[t]||(r.prototype[t]=function(){var t=[this.__wrapped__];return Ot.apply(t,arguments),n.apply(r,t)})}),r.first=P,r.last=function(n,t,r){if(n){var e=n.length;return null==t||r?n[e-1]:v(n,Rt(0,e-t))}},r.take=P,r.head=P,lr(r,function(n,t){r.prototype[t]||(r.prototype[t]=function(t,e){var u=n(this.__wrapped__,t,e);return null==t||e?u:new r(u)
},r.prototype.value=J,r.prototype.valueOf=J,lr(["join","pop","shift"],function(n){var t=rt[n];r.prototype[n]=function(){return t.apply(this.__wrapped__,arguments)}}),lr(["push","reverse","sort","unshift"],function(n){var t=rt[n];r.prototype[n]=function(){return t.apply(this.__wrapped__,arguments),this}}),lr(["concat","slice","splice"],function(n){var t=rt[n];r.prototype[n]=function(){var n=t.apply(this.__wrapped__,arguments);return new r(n)}}),Wt&&lr(["pop","shift","splice"],function(n){var t=rt[n],e="splice"==n; })}),r.VERSION="1.0.0-rc.3",r.prototype.toString=function(){return this.__wrapped__+""},r.prototype.value=J,r.prototype.valueOf=J,ar(["join","pop","shift"],function(n){var t=Z[n];r.prototype[n]=function(){return t.apply(this.__wrapped__,arguments)}}),ar(["push","reverse","sort","unshift"],function(n){var t=Z[n];r.prototype[n]=function(){return t.apply(this.__wrapped__,arguments),this}}),ar(["concat","slice","splice"],function(n){var t=Z[n];r.prototype[n]=function(){return new r(t.apply(this.__wrapped__,arguments))
r.prototype[n]=function(){var n=this.__wrapped__,u=t.apply(n,arguments);return 0===n.length&&delete n[0],e?new r(u):u}}),typeof define=="function"&&typeof define.amd=="object"&&define.amd?(n._=r,define(function(){return r})):Y?typeof module=="object"&&module&&module.exports==Y?(module.exports=r)._=r:Y._=r:n._=r})(this); }}),Ht&&ar(["pop","shift","splice"],function(n){var t=Z[n],e="splice"==n;r.prototype[n]=function(){var n=this.__wrapped__,u=t.apply(n,arguments);return 0===n.length&&delete n[0],e?new r(u):u}}),typeof define=="function"&&typeof define.amd=="object"&&define.amd?(n._=r,define(function(){return r})):Q?typeof module=="object"&&module&&module.exports==Q?(module.exports=r)._=r:Q._=r:n._=r})(this);

View File

@@ -2241,8 +2241,7 @@
* // => [2, 3, 4] * // => [2, 3, 4]
*/ */
function toArray(collection) { function toArray(collection) {
var length = collection ? collection.length : 0; if (collection && typeof collection.length == 'number') {
if (typeof length == 'number') {
return slice(collection); return slice(collection);
} }
return values(collection); return values(collection);
@@ -3298,7 +3297,7 @@
lodash.prototype[methodName] = function() { lodash.prototype[methodName] = function() {
var args = [this.__wrapped__]; var args = [this.__wrapped__];
push.apply(args, arguments); push.apply(args, arguments);
var result = func.apply(lodash, args); var result = func.apply(lodash, args);
if (this.__chain__) { if (this.__chain__) {
result = new lodash(result); result = new lodash(result);

View File

@@ -22,7 +22,7 @@ o.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpo
return N(n,function(n){u.push((e?t:n[t]).apply(n,r))}),u},o.keys=Rt,o.map=F,o.max=R,o.memoize=function(n,t){var r={};return function(){var e=t?t.apply(this,arguments):arguments[0];return ft.call(r,e)?r[e]:r[e]=n.apply(this,arguments)}},o.min=function(n,t,r){var e=1/0,o=e;if(!t&&Bt(n))for(var r=-1,i=n.length;i>++r;){var a=n[r];o>a&&(o=a)}else t=f(t,r),u(n,function(n,r,u){r=t(n,r,u),e>r&&(e=r,o=n)});return o},o.object=function(n,t){for(var r=-1,e=n?n.length:0,u={};e>++r;){var o=n[r];t?u[o]=t[r]:u[o[0]]=o[1] return N(n,function(n){u.push((e?t:n[t]).apply(n,r))}),u},o.keys=Rt,o.map=F,o.max=R,o.memoize=function(n,t){var r={};return function(){var e=t?t.apply(this,arguments):arguments[0];return ft.call(r,e)?r[e]:r[e]=n.apply(this,arguments)}},o.min=function(n,t,r){var e=1/0,o=e;if(!t&&Bt(n))for(var r=-1,i=n.length;i>++r;){var a=n[r];o>a&&(o=a)}else t=f(t,r),u(n,function(n,r,u){r=t(n,r,u),e>r&&(e=r,o=n)});return o},o.object=function(n,t){for(var r=-1,e=n?n.length:0,u={};e>++r;){var o=n[r];t?u[o]=t[r]:u[o[0]]=o[1]
}return u},o.omit=function(n){var t=it.apply(W,arguments),r={};return e(n,function(n,e){0>I(t,e,1)&&(r[e]=n)}),r},o.once=function(n){var t,r=K;return function(){return r?t:(r=H,t=n.apply(this,arguments),n=J,t)}},o.pairs=function(n){for(var t=-1,r=Rt(n),e=r.length,u=Array(e);e>++t;){var o=r[t];u[t]=[o,n[o]]}return u},o.pick=function(n){for(var t=0,r=it.apply(W,arguments),e=r.length,u={};e>++t;){var o=r[t];o in n&&(u[o]=n[o])}return u},o.pluck=T,o.range=function(n,t,r){n=+n||0,r=+r||1,t==J&&(t=n,n=0); }return u},o.omit=function(n){var t=it.apply(W,arguments),r={};return e(n,function(n,e){0>I(t,e,1)&&(r[e]=n)}),r},o.once=function(n){var t,r=K;return function(){return r?t:(r=H,t=n.apply(this,arguments),n=J,t)}},o.pairs=function(n){for(var t=-1,r=Rt(n),e=r.length,u=Array(e);e>++t;){var o=r[t];u[t]=[o,n[o]]}return u},o.pick=function(n){for(var t=0,r=it.apply(W,arguments),e=r.length,u={};e>++t;){var o=r[t];o in n&&(u[o]=n[o])}return u},o.pluck=T,o.range=function(n,t,r){n=+n||0,r=+r||1,t==J&&(t=n,n=0);
for(var e=-1,t=_t(0,ot((t-n)/r)),u=Array(t);t>++e;)u[e]=n,n+=r;return u},o.reject=function(n,t,r){return t=f(t,r),S(n,function(n,r,e){return!t(n,r,e)})},o.rest=z,o.shuffle=function(n){var t=-1,r=Array(n?n.length:0);return N(n,function(n){var e=at(yt()*(++t+1));r[t]=r[e],r[e]=n}),r},o.sortBy=function(n,t,r){var e=[],t=f(t,r);for(N(n,function(n,r,u){e.push({a:t(n,r,u),b:r,c:n})}),n=e.length,e.sort(i);n--;)e[n]=e[n].c;return e},o.tap=function(n,t){return t(n),n},o.throttle=function(n,t){function r(){a=new Date,i=J,u=n.apply(o,e) for(var e=-1,t=_t(0,ot((t-n)/r)),u=Array(t);t>++e;)u[e]=n,n+=r;return u},o.reject=function(n,t,r){return t=f(t,r),S(n,function(n,r,e){return!t(n,r,e)})},o.rest=z,o.shuffle=function(n){var t=-1,r=Array(n?n.length:0);return N(n,function(n){var e=at(yt()*(++t+1));r[t]=r[e],r[e]=n}),r},o.sortBy=function(n,t,r){var e=[],t=f(t,r);for(N(n,function(n,r,u){e.push({a:t(n,r,u),b:r,c:n})}),n=e.length,e.sort(i);n--;)e[n]=e[n].c;return e},o.tap=function(n,t){return t(n),n},o.throttle=function(n,t){function r(){a=new Date,i=J,u=n.apply(o,e)
}var e,u,o,i,a=0;return function(){var f=new Date,c=t-(f-a);return e=arguments,o=this,c>0?i||(i=setTimeout(r,c)):(clearTimeout(i),i=J,a=f,u=n.apply(o,e)),u}},o.times=function(n,t,r){for(var n=+n||0,e=-1,u=Array(n);n>++e;)u[e]=t.call(r,e);return u},o.toArray=function(n){return typeof(n?n.length:0)=="number"?p(n):A(n)},o.union=function(){return P(it.apply(W,arguments))},o.uniq=P,o.values=A,o.where=function(n,t){var r=Rt(t);return S(n,function(n){for(var e=r.length;e--;){var u=n[r[e]]===t[r[e]];if(!u)break }var e,u,o,i,a=0;return function(){var f=new Date,c=t-(f-a);return e=arguments,o=this,c>0?i||(i=setTimeout(r,c)):(clearTimeout(i),i=J,a=f,u=n.apply(o,e)),u}},o.times=function(n,t,r){for(var n=+n||0,e=-1,u=Array(n);n>++e;)u[e]=t.call(r,e);return u},o.toArray=function(n){return n&&typeof n.length=="number"?p(n):A(n)},o.union=function(){return P(it.apply(W,arguments))},o.uniq=P,o.values=A,o.where=function(n,t){var r=Rt(t);return S(n,function(n){for(var e=r.length;e--;){var u=n[r[e]]===t[r[e]];if(!u)break
}return!!u})},o.without=function(n){for(var t=-1,r=n.length,e=[];r>++t;){var u=n[t];0>I(arguments,u,1)&&e.push(u)}return e},o.wrap=function(n,t){return function(){var r=[n];return ct.apply(r,arguments),t.apply(this,r)}},o.zip=function(n){for(var t=-1,r=n?R(T(arguments,"length")):0,e=Array(r);r>++t;)e[t]=T(arguments,t);return e},o.collect=F,o.drop=z,o.each=N,o.extend=g,o.methods=m,o.select=S,o.tail=z,o.unique=P,o.clone=function(n){return n&&Nt[typeof n]?Bt(n)?p(n):g({},n):n},o.contains=E,o.escape=function(n){return n==J?"":(n+"").replace(et,l) }return!!u})},o.without=function(n){for(var t=-1,r=n.length,e=[];r>++t;){var u=n[t];0>I(arguments,u,1)&&e.push(u)}return e},o.wrap=function(n,t){return function(){var r=[n];return ct.apply(r,arguments),t.apply(this,r)}},o.zip=function(n){for(var t=-1,r=n?R(T(arguments,"length")):0,e=Array(r);r>++t;)e[t]=T(arguments,t);return e},o.collect=F,o.drop=z,o.each=N,o.extend=g,o.methods=m,o.select=S,o.tail=z,o.unique=P,o.clone=function(n){return n&&Nt[typeof n]?Bt(n)?p(n):g({},n):n},o.contains=E,o.escape=function(n){return n==J?"":(n+"").replace(et,l)
},o.every=O,o.find=k,o.has=function(n,t){return n?ft.call(n,t):K},o.identity=V,o.indexOf=I,o.isArray=Bt,o.isBoolean=function(n){return n===H||n===K||lt.call(n)==bt},o.isDate=function(n){return n instanceof Date||lt.call(n)==jt},o.isElement=function(n){return n?1===n.nodeType:K},o.isEmpty=function(n){if(!n)return H;if(Bt(n)||x(n))return!n.length;for(var t in n)if(ft.call(n,t))return K;return H},o.isEqual=d,o.isFinite=function(n){return vt(n)&&!gt(parseFloat(n))},o.isFunction=b,o.isNaN=function(n){return w(n)&&n!=+n },o.every=O,o.find=k,o.has=function(n,t){return n?ft.call(n,t):K},o.identity=V,o.indexOf=I,o.isArray=Bt,o.isBoolean=function(n){return n===H||n===K||lt.call(n)==bt},o.isDate=function(n){return n instanceof Date||lt.call(n)==jt},o.isElement=function(n){return n?1===n.nodeType:K},o.isEmpty=function(n){if(!n)return H;if(Bt(n)||x(n))return!n.length;for(var t in n)if(ft.call(n,t))return K;return H},o.isEqual=d,o.isFinite=function(n){return vt(n)&&!gt(parseFloat(n))},o.isFunction=b,o.isNaN=function(n){return w(n)&&n!=+n
},o.isNull=function(n){return n===J},o.isNumber=w,o.isObject=j,o.isRegExp=function(n){return n instanceof RegExp||lt.call(n)==At},o.isString=x,o.isUndefined=function(n){return n===void 0},o.lastIndexOf=function(n,t,r){var e=n?n.length:0;for(typeof r=="number"&&(e=(0>r?_t(0,e+r):mt(r,e-1))+1);e--;)if(n[e]===t)return e;return-1},o.mixin=G,o.noConflict=function(){return n._=Z,this},o.random=function(n,t){return n==J&&t==J&&(t=1),n=+n||0,t==J&&(t=n,n=0),n+at(yt()*((+t||0)-n+1))},o.reduce=q,o.reduceRight=B,o.result=function(n,t){var r=n?n[t]:J; },o.isNull=function(n){return n===J},o.isNumber=w,o.isObject=j,o.isRegExp=function(n){return n instanceof RegExp||lt.call(n)==At},o.isString=x,o.isUndefined=function(n){return n===void 0},o.lastIndexOf=function(n,t,r){var e=n?n.length:0;for(typeof r=="number"&&(e=(0>r?_t(0,e+r):mt(r,e-1))+1);e--;)if(n[e]===t)return e;return-1},o.mixin=G,o.noConflict=function(){return n._=Z,this},o.random=function(n,t){return n==J&&t==J&&(t=1),n=+n||0,t==J&&(t=n,n=0),n+at(yt()*((+t||0)-n+1))},o.reduce=q,o.reduceRight=B,o.result=function(n,t){var r=n?n[t]:J;