lodash-rails 2.0.0 → 2.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/lodash/rails/version.rb +1 -1
- data/vendor/assets/javascripts/lodash.compat.js +107 -55
- data/vendor/assets/javascripts/lodash.compat.min.js +45 -45
- data/vendor/assets/javascripts/lodash.js +98 -47
- data/vendor/assets/javascripts/lodash.min.js +48 -48
- data/vendor/assets/javascripts/lodash.underscore.js +76 -39
- data/vendor/assets/javascripts/lodash.underscore.min.js +34 -33
- metadata +2 -2
@@ -1,6 +1,6 @@
|
|
1
1
|
/**
|
2
2
|
* @license
|
3
|
-
* Lo-Dash 2.
|
3
|
+
* Lo-Dash 2.1.0 (Custom Build) <http://lodash.com/>
|
4
4
|
* Build: `lodash modern -o ./dist/lodash.js`
|
5
5
|
* Copyright 2012-2013 The Dojo Foundation <http://dojofoundation.org/>
|
6
6
|
* Based on Underscore.js 1.5.2 <http://underscorejs.org/LICENSE>
|
@@ -67,7 +67,7 @@
|
|
67
67
|
var reNoMatch = /($^)/;
|
68
68
|
|
69
69
|
/** Used to detect functions containing a `this` reference */
|
70
|
-
var reThis =
|
70
|
+
var reThis = /\bthis\b/;
|
71
71
|
|
72
72
|
/** Used to match unescaped characters in compiled string literals */
|
73
73
|
var reUnescapedString = /['\n\r\t\u2028\u2029\\]/g;
|
@@ -126,10 +126,13 @@
|
|
126
126
|
var root = (objectTypes[typeof window] && window) || this;
|
127
127
|
|
128
128
|
/** Detect free variable `exports` */
|
129
|
-
var freeExports = objectTypes[typeof exports] && exports;
|
129
|
+
var freeExports = objectTypes[typeof exports] && exports && !exports.nodeType && exports;
|
130
130
|
|
131
131
|
/** Detect free variable `module` */
|
132
|
-
var freeModule = objectTypes[typeof module] && module && module.
|
132
|
+
var freeModule = objectTypes[typeof module] && module && !module.nodeType && module;
|
133
|
+
|
134
|
+
/** Detect the popular CommonJS extension `module.exports` */
|
135
|
+
var moduleExports = freeModule && freeModule.exports === freeExports && freeExports;
|
133
136
|
|
134
137
|
/** Detect free variable `global` from Node.js or Browserified code and use it as `root` */
|
135
138
|
var freeGlobal = objectTypes[typeof global] && global;
|
@@ -189,7 +192,7 @@
|
|
189
192
|
}
|
190
193
|
|
191
194
|
/**
|
192
|
-
* Adds a given
|
195
|
+
* Adds a given value to the corresponding cache object.
|
193
196
|
*
|
194
197
|
* @private
|
195
198
|
* @param {*} value The value to add to the cache.
|
@@ -268,9 +271,11 @@
|
|
268
271
|
var index = -1,
|
269
272
|
length = array.length,
|
270
273
|
first = array[0],
|
274
|
+
mid = array[(length / 2) | 0],
|
271
275
|
last = array[length - 1];
|
272
276
|
|
273
|
-
if (first && typeof first == 'object' &&
|
277
|
+
if (first && typeof first == 'object' &&
|
278
|
+
mid && typeof mid == 'object' && last && typeof last == 'object') {
|
274
279
|
return false;
|
275
280
|
}
|
276
281
|
var cache = getObject();
|
@@ -409,7 +414,7 @@
|
|
409
414
|
/*--------------------------------------------------------------------------*/
|
410
415
|
|
411
416
|
/**
|
412
|
-
* Create a new `lodash` function using the given
|
417
|
+
* Create a new `lodash` function using the given context object.
|
413
418
|
*
|
414
419
|
* @static
|
415
420
|
* @memberOf _
|
@@ -612,6 +617,15 @@
|
|
612
617
|
*/
|
613
618
|
support.fastBind = nativeBind && !isV8;
|
614
619
|
|
620
|
+
/**
|
621
|
+
* Detect if functions can be decompiled by `Function#toString`
|
622
|
+
* (all but PS3 and older Opera mobile browsers & avoided in Windows 8 apps).
|
623
|
+
*
|
624
|
+
* @memberOf _.support
|
625
|
+
* @type boolean
|
626
|
+
*/
|
627
|
+
support.funcDecomp = !reNative.test(context.WinRTError) && reThis.test(runInContext);
|
628
|
+
|
615
629
|
/**
|
616
630
|
* Detect if `Function#name` is supported (all but IE).
|
617
631
|
*
|
@@ -689,7 +703,7 @@
|
|
689
703
|
*
|
690
704
|
* @private
|
691
705
|
* @param {*} value The value to clone.
|
692
|
-
* @param {boolean} [deep=false]
|
706
|
+
* @param {boolean} [deep=false] Specify a deep clone.
|
693
707
|
* @param {Function} [callback] The function to customize cloning values.
|
694
708
|
* @param {Array} [stackA=[]] Tracks traversed source objects.
|
695
709
|
* @param {Array} [stackB=[]] Associates clones with source counterparts.
|
@@ -799,7 +813,7 @@
|
|
799
813
|
}
|
800
814
|
if (support.funcNames || !bindData) {
|
801
815
|
// checks if `func` references the `this` keyword and stores the result
|
802
|
-
bindData = !
|
816
|
+
bindData = !support.funcDecomp || reThis.test(source);
|
803
817
|
setBindData(func, bindData);
|
804
818
|
}
|
805
819
|
}
|
@@ -842,9 +856,21 @@
|
|
842
856
|
|
843
857
|
while (++index < length) {
|
844
858
|
var value = array[index];
|
845
|
-
|
846
|
-
if (value && typeof value == 'object' &&
|
847
|
-
|
859
|
+
|
860
|
+
if (value && typeof value == 'object' && typeof value.length == 'number'
|
861
|
+
&& (isArray(value) || isArguments(value))) {
|
862
|
+
// recursively flatten arrays (susceptible to call stack limits)
|
863
|
+
if (!isShallow) {
|
864
|
+
value = baseFlatten(value, isShallow, isArgArrays);
|
865
|
+
}
|
866
|
+
var valIndex = -1,
|
867
|
+
valLength = value.length,
|
868
|
+
resIndex = result.length;
|
869
|
+
|
870
|
+
result.length += valLength;
|
871
|
+
while (++valIndex < valLength) {
|
872
|
+
result[resIndex++] = value[valIndex];
|
873
|
+
}
|
848
874
|
} else if (!isArgArrays) {
|
849
875
|
result.push(value);
|
850
876
|
}
|
@@ -1325,7 +1351,7 @@
|
|
1325
1351
|
* @param {Function} func The function to set data on.
|
1326
1352
|
* @param {*} value The value to set.
|
1327
1353
|
*/
|
1328
|
-
var setBindData = function(func, value) {
|
1354
|
+
var setBindData = !defineProperty ? noop : function(func, value) {
|
1329
1355
|
var descriptor = getObject();
|
1330
1356
|
descriptor.value = value;
|
1331
1357
|
defineProperty(func, '__bindData__', descriptor);
|
@@ -1390,7 +1416,8 @@
|
|
1390
1416
|
* // => false
|
1391
1417
|
*/
|
1392
1418
|
function isArguments(value) {
|
1393
|
-
return
|
1419
|
+
return value && typeof value == 'object' && typeof value.length == 'number' &&
|
1420
|
+
toString.call(value) == argsClass || false;
|
1394
1421
|
}
|
1395
1422
|
|
1396
1423
|
/**
|
@@ -1411,7 +1438,8 @@
|
|
1411
1438
|
* // => true
|
1412
1439
|
*/
|
1413
1440
|
var isArray = nativeIsArray || function(value) {
|
1414
|
-
return
|
1441
|
+
return value && typeof value == 'object' && typeof value.length == 'number' &&
|
1442
|
+
toString.call(value) == arrayClass || false;
|
1415
1443
|
};
|
1416
1444
|
|
1417
1445
|
/**
|
@@ -1548,7 +1576,7 @@
|
|
1548
1576
|
* @memberOf _
|
1549
1577
|
* @category Objects
|
1550
1578
|
* @param {*} value The value to clone.
|
1551
|
-
* @param {boolean} [deep=false]
|
1579
|
+
* @param {boolean} [deep=false] Specify a deep clone.
|
1552
1580
|
* @param {Function} [callback] The function to customize cloning values.
|
1553
1581
|
* @param {*} [thisArg] The `this` binding of `callback`.
|
1554
1582
|
* @returns {*} Returns the cloned `value`.
|
@@ -3209,10 +3237,11 @@
|
|
3209
3237
|
}
|
3210
3238
|
|
3211
3239
|
/**
|
3212
|
-
* Retrieves the maximum value of
|
3213
|
-
*
|
3214
|
-
*
|
3215
|
-
*
|
3240
|
+
* Retrieves the maximum value of a collection. If the collection is empty or
|
3241
|
+
* falsey `-Infinity` is returned. If a callback is provided it will be executed
|
3242
|
+
* for each value in the collection to generate the criterion by which the value
|
3243
|
+
* is ranked. The callback is bound to `thisArg` and invoked with three
|
3244
|
+
* arguments; (value, index, collection).
|
3216
3245
|
*
|
3217
3246
|
* If a property name is provided for `callback` the created "_.pluck" style
|
3218
3247
|
* callback will return the property value of the given element.
|
@@ -3278,10 +3307,11 @@
|
|
3278
3307
|
}
|
3279
3308
|
|
3280
3309
|
/**
|
3281
|
-
* Retrieves the minimum value of
|
3282
|
-
*
|
3283
|
-
*
|
3284
|
-
*
|
3310
|
+
* Retrieves the minimum value of a collection. If the collection is empty or
|
3311
|
+
* falsey `Infinity` is returned. If a callback is provided it will be executed
|
3312
|
+
* for each value in the collection to generate the criterion by which the value
|
3313
|
+
* is ranked. The callback is bound to `thisArg` and invoked with three
|
3314
|
+
* arguments; (value, index, collection).
|
3285
3315
|
*
|
3286
3316
|
* If a property name is provided for `callback` the created "_.pluck" style
|
3287
3317
|
* callback will return the property value of the given element.
|
@@ -3745,16 +3775,16 @@
|
|
3745
3775
|
* @category Collections
|
3746
3776
|
* @param {Array|Object|string} collection The collection to iterate over.
|
3747
3777
|
* @param {Object} properties The object of property values to filter by.
|
3748
|
-
* @returns {Array} Returns a new array of elements that have the given
|
3778
|
+
* @returns {Array} Returns a new array of elements that have the given properties.
|
3749
3779
|
* @example
|
3750
3780
|
*
|
3751
3781
|
* var stooges = [
|
3752
3782
|
* { 'name': 'curly', 'age': 30, 'quotes': ['Oh, a wise guy, eh?', 'Poifect!'] },
|
3753
|
-
* { 'name': 'moe', 'age':
|
3783
|
+
* { 'name': 'moe', 'age': 40, 'quotes': ['Spread out!', 'You knucklehead!'] }
|
3754
3784
|
* ];
|
3755
3785
|
*
|
3756
3786
|
* _.where(stooges, { 'age': 40 });
|
3757
|
-
* // => [{ 'name': 'moe', 'age':
|
3787
|
+
* // => [{ 'name': 'moe', 'age': 40, 'quotes': ['Spread out!', 'You knucklehead!'] }]
|
3758
3788
|
*
|
3759
3789
|
* _.where(stooges, { 'quotes': ['Poifect!'] });
|
3760
3790
|
* // => [{ 'name': 'curly', 'age': 30, 'quotes': ['Oh, a wise guy, eh?', 'Poifect!'] }]
|
@@ -4906,7 +4936,7 @@
|
|
4906
4936
|
*/
|
4907
4937
|
function compose() {
|
4908
4938
|
var funcs = arguments,
|
4909
|
-
length = funcs.length
|
4939
|
+
length = funcs.length;
|
4910
4940
|
|
4911
4941
|
while (length--) {
|
4912
4942
|
if (!isFunction(funcs[length])) {
|
@@ -5173,7 +5203,7 @@
|
|
5173
5203
|
return setTimeout(function() { func.apply(undefined, args); }, 1);
|
5174
5204
|
}
|
5175
5205
|
// use `setImmediate` if available in Node.js
|
5176
|
-
if (isV8 &&
|
5206
|
+
if (isV8 && moduleExports && typeof setImmediate == 'function') {
|
5177
5207
|
defer = function(func) {
|
5178
5208
|
if (!isFunction(func)) {
|
5179
5209
|
throw new TypeError;
|
@@ -5538,7 +5568,7 @@
|
|
5538
5568
|
}
|
5539
5569
|
|
5540
5570
|
/**
|
5541
|
-
* Converts the given
|
5571
|
+
* Converts the given value into an integer of the specified radix.
|
5542
5572
|
* If `radix` is `undefined` or `0` a `radix` of `10` is used unless the
|
5543
5573
|
* `value` is a hexadecimal, in which case a `radix` of `16` is used.
|
5544
5574
|
*
|
@@ -5564,35 +5594,56 @@
|
|
5564
5594
|
/**
|
5565
5595
|
* Produces a random number between `min` and `max` (inclusive). If only one
|
5566
5596
|
* argument is provided a number between `0` and the given number will be
|
5567
|
-
* returned.
|
5597
|
+
* returned. If `floating` is truey or either `min` or `max` are floats a
|
5598
|
+
* floating-point number will be returned instead of an integer.
|
5568
5599
|
*
|
5569
5600
|
* @static
|
5570
5601
|
* @memberOf _
|
5571
5602
|
* @category Utilities
|
5572
5603
|
* @param {number} [min=0] The minimum possible value.
|
5573
5604
|
* @param {number} [max=1] The maximum possible value.
|
5605
|
+
* @param {boolean} [floating=false] Specify returning a floating-point number.
|
5574
5606
|
* @returns {number} Returns a random number.
|
5575
5607
|
* @example
|
5576
5608
|
*
|
5577
5609
|
* _.random(0, 5);
|
5578
|
-
* // =>
|
5610
|
+
* // => an integer between 0 and 5
|
5579
5611
|
*
|
5580
5612
|
* _.random(5);
|
5581
|
-
* // => also
|
5613
|
+
* // => also an integer between 0 and 5
|
5614
|
+
*
|
5615
|
+
* _.random(5, true);
|
5616
|
+
* // => a floating-point number between 0 and 5
|
5617
|
+
*
|
5618
|
+
* _.random(1.2, 5.2);
|
5619
|
+
* // => a floating-point number between 1.2 and 5.2
|
5582
5620
|
*/
|
5583
|
-
function random(min, max) {
|
5584
|
-
|
5621
|
+
function random(min, max, floating) {
|
5622
|
+
var noMin = min == null,
|
5623
|
+
noMax = max == null;
|
5624
|
+
|
5625
|
+
if (floating == null) {
|
5626
|
+
if (typeof min == 'boolean' && noMax) {
|
5627
|
+
floating = min;
|
5628
|
+
min = 1;
|
5629
|
+
}
|
5630
|
+
else if (!noMax && typeof max == 'boolean') {
|
5631
|
+
floating = max;
|
5632
|
+
noMax = true;
|
5633
|
+
}
|
5634
|
+
}
|
5635
|
+
if (noMin && noMax) {
|
5585
5636
|
max = 1;
|
5586
5637
|
}
|
5587
5638
|
min = +min || 0;
|
5588
|
-
if (
|
5639
|
+
if (noMax) {
|
5589
5640
|
max = min;
|
5590
5641
|
min = 0;
|
5591
5642
|
} else {
|
5592
5643
|
max = +max || 0;
|
5593
5644
|
}
|
5594
5645
|
var rand = nativeRandom();
|
5595
|
-
return (min % 1 || max % 1)
|
5646
|
+
return (floating || min % 1 || max % 1)
|
5596
5647
|
? min + nativeMin(rand * (max - min + parseFloat('1e-' + ((rand +'').length - 1))), max)
|
5597
5648
|
: min + floor(rand * (max - min + 1));
|
5598
5649
|
}
|
@@ -5691,8 +5742,8 @@
|
|
5691
5742
|
* // => 'hello mustache!'
|
5692
5743
|
*
|
5693
5744
|
* // using the `imports` option to import jQuery
|
5694
|
-
* var list = '<% $.each(people, function(name) { %><li
|
5695
|
-
* _.template(list, { 'people': ['moe', 'larry'] }, { 'imports': { '$': jQuery });
|
5745
|
+
* var list = '<% $.each(people, function(name) { %><li><%- name %></li><% }); %>';
|
5746
|
+
* _.template(list, { 'people': ['moe', 'larry'] }, { 'imports': { '$': jQuery } });
|
5696
5747
|
* // => '<li>moe</li><li>larry</li>'
|
5697
5748
|
*
|
5698
5749
|
* // using the `sourceURL` option to specify a custom sourceURL for the template
|
@@ -5810,7 +5861,7 @@
|
|
5810
5861
|
if (data) {
|
5811
5862
|
return result(data);
|
5812
5863
|
}
|
5813
|
-
// provide the compiled function's source
|
5864
|
+
// provide the compiled function's source by its `toString` method, in
|
5814
5865
|
// supported environments, or the `source` property as a convenience for
|
5815
5866
|
// inlining compiled templates during the build process
|
5816
5867
|
result.source = source;
|
@@ -5895,7 +5946,7 @@
|
|
5895
5946
|
/*--------------------------------------------------------------------------*/
|
5896
5947
|
|
5897
5948
|
/**
|
5898
|
-
* Creates a `lodash` object that wraps the given
|
5949
|
+
* Creates a `lodash` object that wraps the given value.
|
5899
5950
|
*
|
5900
5951
|
* @static
|
5901
5952
|
* @memberOf _
|
@@ -6196,7 +6247,7 @@
|
|
6196
6247
|
* @memberOf _
|
6197
6248
|
* @type string
|
6198
6249
|
*/
|
6199
|
-
lodash.VERSION = '2.
|
6250
|
+
lodash.VERSION = '2.1.0';
|
6200
6251
|
|
6201
6252
|
// add "Chaining" functions to the wrapper
|
6202
6253
|
lodash.prototype.chain = wrapperChain;
|
@@ -6247,7 +6298,7 @@
|
|
6247
6298
|
// Expose Lo-Dash to the global object even when an AMD loader is present in
|
6248
6299
|
// case Lo-Dash was injected by a third-party script and not intended to be
|
6249
6300
|
// loaded as a module. The global assignment can be reverted in the Lo-Dash
|
6250
|
-
// module
|
6301
|
+
// module by its `noConflict()` method.
|
6251
6302
|
root._ = _;
|
6252
6303
|
|
6253
6304
|
// define as an anonymous module so, through path mapping, it can be
|
@@ -6257,12 +6308,12 @@
|
|
6257
6308
|
});
|
6258
6309
|
}
|
6259
6310
|
// check for `exports` after `define` in case a build optimizer adds an `exports` object
|
6260
|
-
else if (freeExports &&
|
6261
|
-
// in Node.js or RingoJS
|
6262
|
-
if (
|
6311
|
+
else if (freeExports && freeModule) {
|
6312
|
+
// in Node.js or RingoJS
|
6313
|
+
if (moduleExports) {
|
6263
6314
|
(freeModule.exports = _)._ = _;
|
6264
6315
|
}
|
6265
|
-
// in Narwhal or
|
6316
|
+
// in Narwhal or Rhino -require
|
6266
6317
|
else {
|
6267
6318
|
freeExports._ = _;
|
6268
6319
|
}
|
@@ -1,52 +1,52 @@
|
|
1
1
|
/**
|
2
2
|
* @license
|
3
|
-
* Lo-Dash 2.
|
3
|
+
* Lo-Dash 2.1.0 (Custom Build) lodash.com/license | Underscore.js 1.5.2 underscorejs.org/LICENSE
|
4
4
|
* Build: `lodash modern -o ./dist/lodash.js`
|
5
5
|
*/
|
6
|
-
;(function(){function n(n,t,e){e=(e||0)-1;for(var r=n?n.length:0;++e<r;)if(n[e]===t)return e;return-1}function t(t,e){var r=typeof e;if(t=t.k,"boolean"==r||null==e)return t[e]?0:-1;"number"!=r&&"string"!=r&&(r="object");var u="number"==r?e:
|
7
|
-
}}function r(n){return n.charCodeAt(0)}function u(n,t){var e=n.l,r=t.l;if(e!==r){if(e>r||typeof e=="undefined")return 1;if(e<r||typeof r=="undefined")return-1}return n.m-t.m}function o(n){var t=-1,r=n.length,u=n[0],o=n[r-1];if(u&&typeof u=="object"&&o&&typeof o=="object")return!1;for(u=f(),u["false"]=u["null"]=u["true"]=u.undefined=!1,o=f(),o.b=n,o.k=u,o.push=e;++t<r;)o.push(n[t]);return o}function a(n){return"\\"+
|
8
|
-
}function l(n){n.length=0,
|
9
|
-
for(var r=-1,u=
|
10
|
-
if(!u)return o;var a=arguments,i=0,f=typeof e=="number"?2:a.length;if(3<f&&"function"==typeof a[f-2])var l=nt(a[--f-1],a[f--],2);else 2<f&&"function"==typeof a[f-1]&&(l=a[--f]);for(;++i<f;)if((u=a[i])&&
|
11
|
-
}function
|
12
|
-
}),f&&(
|
13
|
-
}return Pt(n,t)}function tt(n,t,e,r){r=(r||0)-1;for(var u=n?n.length:0,o=[];++r<u;){var a=n[r];a&&typeof a=="object"&&(
|
14
|
-
case W:case P:return n==ee(t)}if(
|
15
|
-
return a}return
|
16
|
-
n[o]=l})}function ut(e,r,u){var a=-1,f=ft(),
|
17
|
-
if(!i&&!gt(n))throw new re;c&&!e.length&&(t&=-17,c=e=!1),p&&!r.length&&(t&=-33,p=r=!1);var v=n&&n.__bindData__;if(v)return!a||1&v[1]||(v[4]=u),!a&&1&v[1]&&(t|=8),!f||4&v[1]||(v[5]=o),c&&ge.apply(v[2]||(v[2]=[]),e),p&&ge.apply(v[3]||(v[3]=[]),r),v[1]|=t,at.apply(null,v);if(!a||i||f||p||!(Fe.fastBind||je&&c))g=function(){var v=arguments,h=a?u:this;return(f||c||p)&&(v=
|
18
|
-
};else{if(c){var h=[u];ge.apply(h,e)}var g=c?je.apply(n,h):je.call(n,u)}return
|
19
|
-
}function vt(n){var t=[];return
|
20
|
-
}),a}function wt(n,t,e){var r=!0;t=
|
21
|
-
}),u}for(;++e<r;){var o=n[e];if(t(o,e,n))return o}}function xt(n,t,e){var r=-1,u=n?n.length:0;if(t=t&&typeof e=="undefined"?t:nt(t,e,3),typeof u=="number")for(;++r<u&&false!==t(n[r],r,n););else
|
22
|
-
else o=[],
|
23
|
-
else
|
24
|
-
if(l){var
|
25
|
-
for(t=
|
26
|
-
t?u[o]=t[e]:o&&(u[o[0]]=o[1])}return u}function Pt(n,t){return 2<arguments.length?at(n,17,
|
27
|
-
return function(){if(o=arguments,f=he(),l=this,p=g&&(c||!y),false===
|
28
|
-
})})}function Vt(n,t){null==n
|
29
|
-
},ge=ue.push,ye=e.setImmediate,me=e.setTimeout,
|
30
|
-
var Fe=
|
31
|
-
}),Ue=ot(function(n,t,e){n[e]=t})
|
32
|
-
n[u]=at(n[u],1,null,null,n)}return n},
|
33
|
-
if(null==n||"function"==r)return nt(n,t,e);if("object"!=r)return function(t){return t[n]};var u=
|
34
|
-
},t)},
|
35
|
-
for(t=
|
36
|
-
return xt(n,function(n){a[++r]=(u?t:n[t]).apply(n,e)}),a},
|
37
|
-
return
|
38
|
-
}},
|
39
|
-
return n},
|
40
|
-
for(t=
|
41
|
-
},
|
42
|
-
},
|
43
|
-
}),r},
|
44
|
-
},
|
45
|
-
},
|
46
|
-
n||(n=""),e=
|
47
|
-
try{var c=Xt(r,"return "+l).apply(
|
48
|
-
if(typeof t!="number"&&null!=t){var o=u;for(t=
|
49
|
-
})}),
|
50
|
-
|
51
|
-
|
52
|
-
})):
|
6
|
+
;(function(){function n(n,t,e){e=(e||0)-1;for(var r=n?n.length:0;++e<r;)if(n[e]===t)return e;return-1}function t(t,e){var r=typeof e;if(t=t.k,"boolean"==r||null==e)return t[e]?0:-1;"number"!=r&&"string"!=r&&(r="object");var u="number"==r?e:b+e;return t=(t=t[r])&&t[u],"object"==r?t&&-1<n(t,e)?0:-1:t?0:-1}function e(n){var t=this.k,e=typeof n;if("boolean"==e||null==n)t[n]=!0;else{"number"!=e&&"string"!=e&&(e="object");var r="number"==e?n:b+n,t=t[e]||(t[e]={});"object"==e?(t[r]||(t[r]=[])).push(n):t[r]=!0
|
7
|
+
}}function r(n){return n.charCodeAt(0)}function u(n,t){var e=n.l,r=t.l;if(e!==r){if(e>r||typeof e=="undefined")return 1;if(e<r||typeof r=="undefined")return-1}return n.m-t.m}function o(n){var t=-1,r=n.length,u=n[0],o=n[0|r/2],a=n[r-1];if(u&&typeof u=="object"&&o&&typeof o=="object"&&a&&typeof a=="object")return!1;for(u=f(),u["false"]=u["null"]=u["true"]=u.undefined=!1,o=f(),o.b=n,o.k=u,o.push=e;++t<r;)o.push(n[t]);return o}function a(n){return"\\"+U[n]}function i(){return g.pop()||[]}function f(){return y.pop()||{b:null,k:null,configurable:!1,l:null,enumerable:!1,"false":!1,m:0,leading:!1,maxWait:0,"null":!1,number:null,z:null,push:null,string:null,trailing:!1,"true":!1,undefined:!1,n:null,writable:!1}
|
8
|
+
}function l(){}function c(n){n.length=0,g.length<d&&g.push(n)}function p(n){var t=n.k;t&&p(t),n.b=n.k=n.l=n.object=n.number=n.string=n.n=null,y.length<d&&y.push(n)}function s(n,t,e){t||(t=0),typeof e=="undefined"&&(e=n?n.length:0);var r=-1;e=e-t||0;for(var u=Array(0>e?0:e);++r<e;)u[r]=n[t+r];return u}function v(e){function g(n){if(!n||_e.call(n)!=q)return!1;var t=n.valueOf,e=typeof t=="function"&&(e=se(t))&&se(e);return e?n==e||se(n)==e:lt(n)}function y(n,t,e){if(!n||!M[typeof n])return n;t=t&&typeof e=="undefined"?t:nt(t,e,3);
|
9
|
+
for(var r=-1,u=M[typeof n]&&We(n),o=u?u.length:0;++r<o&&(e=u[r],false!==t(n[e],e,n)););return n}function d(n,t,e){var r;if(!n||!M[typeof n])return n;t=t&&typeof e=="undefined"?t:nt(t,e,3);for(r in n)if(false===t(n[r],r,n))break;return n}function U(n,t,e){var r,u=n,o=u;if(!u)return o;for(var a=arguments,i=0,f=typeof e=="number"?2:a.length;++i<f;)if((u=a[i])&&M[typeof u])for(var l=-1,c=M[typeof u]&&We(u),p=c?c.length:0;++l<p;)r=c[l],"undefined"==typeof o[r]&&(o[r]=u[r]);return o}function G(n,t,e){var r,u=n,o=u;
|
10
|
+
if(!u)return o;var a=arguments,i=0,f=typeof e=="number"?2:a.length;if(3<f&&"function"==typeof a[f-2])var l=nt(a[--f-1],a[f--],2);else 2<f&&"function"==typeof a[f-1]&&(l=a[--f]);for(;++i<f;)if((u=a[i])&&M[typeof u])for(var c=-1,p=M[typeof u]&&We(u),s=p?p.length:0;++c<s;)r=p[c],o[r]=l?l(o[r],u[r]):u[r];return o}function H(n){var t,e=[];if(!n||!M[typeof n])return e;for(t in n)ve.call(n,t)&&e.push(t);return e}function Q(n){return n&&typeof n=="object"&&!ze(n)&&ve.call(n,"__wrapped__")?n:new Y(n)}function Y(n,t){this.__chain__=!!t,this.__wrapped__=n
|
11
|
+
}function Z(n,t,e,r,u){var o=n;if(e){if(o=e(o),typeof o!="undefined")return o;o=n}var a=yt(o);if(a){var f=_e.call(o);if(!L[f])return o;var l=ze(o)}if(!a||!t)return a?l?s(o):G({},o):o;switch(a=$e[f],f){case F:case T:return new a(+o);case W:case K:return new a(o);case P:return a(o.source,O.exec(o))}f=!r,r||(r=i()),u||(u=i());for(var p=r.length;p--;)if(r[p]==n)return u[p];return o=l?a(o.length):{},l&&(ve.call(n,"index")&&(o.index=n.index),ve.call(n,"input")&&(o.input=n.input)),r.push(n),u.push(o),(l?xt:y)(n,function(n,a){o[a]=Z(n,t,e,r,u)
|
12
|
+
}),f&&(c(r),c(u)),o}function nt(n,t,e){if(typeof n!="function")return Mt;if(typeof t=="undefined")return n;var r=n.__bindData__||Fe.funcNames&&!n.name;if(typeof r=="undefined"){var u=R&&pe.call(n);Fe.funcNames||!u||N.test(u)||(r=!0),(Fe.funcNames||!r)&&(r=!Fe.funcDecomp||R.test(u),Te(n,r))}if(true!==r&&r&&1&r[1])return n;switch(e){case 1:return function(e){return n.call(t,e)};case 2:return function(e,r){return n.call(t,e,r)};case 3:return function(e,r,u){return n.call(t,e,r,u)};case 4:return function(e,r,u,o){return n.call(t,e,r,u,o)
|
13
|
+
}}return Pt(n,t)}function tt(n,t,e,r){r=(r||0)-1;for(var u=n?n.length:0,o=[];++r<u;){var a=n[r];if(a&&typeof a=="object"&&typeof a.length=="number"&&(ze(a)||pt(a))){t||(a=tt(a,t,e));var i=-1,f=a.length,l=o.length;for(o.length+=f;++i<f;)o[l++]=a[i]}else e||o.push(a)}return o}function et(n,t,e,r,u,o){if(e){var a=e(n,t);if(typeof a!="undefined")return!!a}if(n===t)return 0!==n||1/n==1/t;if(n===n&&!(n&&M[typeof n]||t&&M[typeof t]))return!1;if(null==n||null==t)return n===t;var f=_e.call(n),l=_e.call(t);
|
14
|
+
if(f==B&&(f=q),l==B&&(l=q),f!=l)return!1;switch(f){case F:case T:return+n==+t;case W:return n!=+n?t!=+t:0==n?1/n==1/t:n==+t;case P:case K:return n==ee(t)}if(l=f==$,!l){if(ve.call(n,"__wrapped__")||ve.call(t,"__wrapped__"))return et(n.__wrapped__||n,t.__wrapped__||t,e,r,u,o);if(f!=q)return!1;var f=n.constructor,p=t.constructor;if(f!=p&&!(gt(f)&&f instanceof f&>(p)&&p instanceof p))return!1}for(p=!u,u||(u=i()),o||(o=i()),f=u.length;f--;)if(u[f]==n)return o[f]==t;var s=0,a=!0;if(u.push(n),o.push(t),l){if(f=n.length,s=t.length,a=s==n.length,!a&&!r)return a;
|
15
|
+
for(;s--;)if(l=f,p=t[s],r)for(;l--&&!(a=et(n[l],p,e,r,u,o)););else if(!(a=et(n[s],p,e,r,u,o)))break;return a}return d(t,function(t,i,f){return ve.call(f,i)?(s++,a=ve.call(n,i)&&et(n[i],t,e,r,u,o)):void 0}),a&&!r&&d(n,function(n,t,e){return ve.call(e,t)?a=-1<--s:void 0}),p&&(c(u),c(o)),a}function rt(n,t,e,r,u){(ze(t)?xt:y)(t,function(t,o){var a,i,f=t,l=n[o];if(t&&((i=ze(t))||g(t))){for(f=r.length;f--;)if(a=r[f]==t){l=u[f];break}if(!a){var c;e&&(f=e(l,t),c=typeof f!="undefined")&&(l=f),c||(l=i?ze(l)?l:[]:g(l)?l:{}),r.push(t),u.push(l),c||rt(l,t,e,r,u)
|
16
|
+
}}else e&&(f=e(l,t),typeof f=="undefined"&&(f=t)),typeof f!="undefined"&&(l=f);n[o]=l})}function ut(e,r,u){var a=-1,f=ft(),l=e?e.length:0,s=[],v=!r&&l>=_&&f===n,h=u||v?i():s;if(v){var g=o(h);g?(f=t,h=g):(v=!1,h=u?h:(c(h),s))}for(;++a<l;){var g=e[a],y=u?u(g,a,e):g;(r?!a||h[h.length-1]!==y:0>f(h,y))&&((u||v)&&h.push(y),s.push(g))}return v?(c(h.b),p(h)):u&&c(h),s}function ot(n){return function(t,e,r){var u={};e=Q.createCallback(e,r,3),r=-1;var o=t?t.length:0;if(typeof o=="number")for(;++r<o;){var a=t[r];
|
17
|
+
n(u,a,e(a,r,t),t)}else y(t,function(t,r,o){n(u,t,e(t,r,o),o)});return u}}function at(n,t,e,r,u,o){var a=1&t,i=2&t,f=4&t,l=8&t,c=16&t,p=32&t,s=n;if(!i&&!gt(n))throw new re;c&&!e.length&&(t&=-17,c=e=!1),p&&!r.length&&(t&=-33,p=r=!1);var v=n&&n.__bindData__;if(v)return!a||1&v[1]||(v[4]=u),!a&&1&v[1]&&(t|=8),!f||4&v[1]||(v[5]=o),c&&ge.apply(v[2]||(v[2]=[]),e),p&&ge.apply(v[3]||(v[3]=[]),r),v[1]|=t,at.apply(null,v);if(!a||i||f||p||!(Fe.fastBind||je&&c))g=function(){var v=arguments,h=a?u:this;return(f||c||p)&&(v=Ae.call(v),c&&de.apply(v,e),p&&ge.apply(v,r),f&&v.length<o)?(t|=16,at(n,l?t:-4&t,v,null,u,o)):(i&&(n=h[s]),this instanceof g?(h=yt(n.prototype)?ke(n.prototype):{},v=n.apply(h,v),yt(v)?v:h):n.apply(h,v))
|
18
|
+
};else{if(c){var h=[u];ge.apply(h,e)}var g=c?je.apply(n,h):je.call(n,u)}return Te(g,Ae.call(arguments)),g}function it(n){return qe[n]}function ft(){var t=(t=Q.indexOf)===$t?n:t;return t}function lt(n){var t,e;return n&&_e.call(n)==q&&(t=n.constructor,!gt(t)||t instanceof t)?(d(n,function(n,t){e=t}),typeof e=="undefined"||ve.call(n,e)):!1}function ct(n){return Pe[n]}function pt(n){return n&&typeof n=="object"&&typeof n.length=="number"&&_e.call(n)==B||!1}function st(n,t,e){var r=We(n),u=r.length;for(t=nt(t,e,3);u--&&(e=r[u],false!==t(n[e],e,n)););return n
|
19
|
+
}function vt(n){var t=[];return d(n,function(n,e){gt(n)&&t.push(e)}),t.sort()}function ht(n){for(var t=-1,e=We(n),r=e.length,u={};++t<r;){var o=e[t];u[n[o]]=o}return u}function gt(n){return typeof n=="function"}function yt(n){return!(!n||!M[typeof n])}function mt(n){return typeof n=="number"||_e.call(n)==W}function bt(n){return typeof n=="string"||_e.call(n)==K}function _t(n){for(var t=-1,e=We(n),r=e.length,u=Ht(r);++t<r;)u[t]=n[e[t]];return u}function dt(n,t,e){var r=-1,u=ft(),o=n?n.length:0,a=!1;return e=(0>e?Ee(0,o+e):e)||0,ze(n)?a=-1<u(n,t,e):typeof o=="number"?a=-1<(bt(n)?n.indexOf(t,e):u(n,t,e)):y(n,function(n){return++r<e?void 0:!(a=n===t)
|
20
|
+
}),a}function wt(n,t,e){var r=!0;t=Q.createCallback(t,e,3),e=-1;var u=n?n.length:0;if(typeof u=="number")for(;++e<u&&(r=!!t(n[e],e,n)););else y(n,function(n,e,u){return r=!!t(n,e,u)});return r}function jt(n,t,e){var r=[];t=Q.createCallback(t,e,3),e=-1;var u=n?n.length:0;if(typeof u=="number")for(;++e<u;){var o=n[e];t(o,e,n)&&r.push(o)}else y(n,function(n,e,u){t(n,e,u)&&r.push(n)});return r}function kt(n,t,e){t=Q.createCallback(t,e,3),e=-1;var r=n?n.length:0;if(typeof r!="number"){var u;return y(n,function(n,e,r){return t(n,e,r)?(u=n,!1):void 0
|
21
|
+
}),u}for(;++e<r;){var o=n[e];if(t(o,e,n))return o}}function xt(n,t,e){var r=-1,u=n?n.length:0;if(t=t&&typeof e=="undefined"?t:nt(t,e,3),typeof u=="number")for(;++r<u&&false!==t(n[r],r,n););else y(n,t);return n}function Ct(n,t,e){var r=n?n.length:0;if(t=t&&typeof e=="undefined"?t:nt(t,e,3),typeof r=="number")for(;r--&&false!==t(n[r],r,n););else{var u=We(n),r=u.length;y(n,function(n,e,o){return e=u?u[--r]:--r,t(o[e],e,o)})}return n}function Ot(n,t,e){var r=-1,u=n?n.length:0;if(t=Q.createCallback(t,e,3),typeof u=="number")for(var o=Ht(u);++r<u;)o[r]=t(n[r],r,n);
|
22
|
+
else o=[],y(n,function(n,e,u){o[++r]=t(n,e,u)});return o}function Nt(n,t,e){var u=-1/0,o=u;if(!t&&ze(n)){e=-1;for(var a=n.length;++e<a;){var i=n[e];i>o&&(o=i)}}else t=!t&&bt(n)?r:Q.createCallback(t,e,3),xt(n,function(n,e,r){e=t(n,e,r),e>u&&(u=e,o=n)});return o}function Et(n,t){var e=-1,r=n?n.length:0;if(typeof r=="number")for(var u=Ht(r);++e<r;)u[e]=n[e][t];return u||Ot(n,t)}function It(n,t,e,r){if(!n)return e;var u=3>arguments.length;t=nt(t,r,4);var o=-1,a=n.length;if(typeof a=="number")for(u&&(e=n[++o]);++o<a;)e=t(e,n[o],o,n);
|
23
|
+
else y(n,function(n,r,o){e=u?(u=!1,n):t(e,n,r,o)});return e}function St(n,t,e,r){var u=3>arguments.length;return t=nt(t,r,4),Ct(n,function(n,r,o){e=u?(u=!1,n):t(e,n,r,o)}),e}function Rt(n){var t=-1,e=n?n.length:0,r=Ht(typeof e=="number"?e:0);return xt(n,function(n){var e=Vt(++t);r[t]=r[e],r[e]=n}),r}function At(n,t,e){var r;t=Q.createCallback(t,e,3),e=-1;var u=n?n.length:0;if(typeof u=="number")for(;++e<u&&!(r=t(n[e],e,n)););else y(n,function(n,e,u){return!(r=t(n,e,u))});return!!r}function Dt(e){var r=-1,u=ft(),a=e?e.length:0,i=tt(arguments,!0,!0,1),f=[],l=a>=_&&u===n;
|
24
|
+
if(l){var c=o(i);c?(u=t,i=c):l=!1}for(;++r<a;)c=e[r],0>u(i,c)&&f.push(c);return l&&p(i),f}function Bt(n,t,e){var r=0,u=n?n.length:0;if(typeof t!="number"&&null!=t){var o=-1;for(t=Q.createCallback(t,e,3);++o<u&&t(n[o],o,n);)r++}else if(r=t,null==r||e)return n?n[0]:h;return s(n,0,Ie(Ee(0,r),u))}function $t(t,e,r){if(typeof r=="number"){var u=t?t.length:0;r=0>r?Ee(0,u+r):r||0}else if(r)return r=Tt(t,e),t[r]===e?r:-1;return n(t,e,r)}function Ft(n,t,e){if(typeof t!="number"&&null!=t){var r=0,u=-1,o=n?n.length:0;
|
25
|
+
for(t=Q.createCallback(t,e,3);++u<o&&t(n[u],u,n);)r++}else r=null==t||e?1:Ee(0,t);return s(n,r)}function Tt(n,t,e,r){var u=0,o=n?n.length:u;for(e=e?Q.createCallback(e,r,1):Mt,t=e(t);u<o;)r=u+o>>>1,e(n[r])<t?u=r+1:o=r;return u}function zt(n,t,e,r){return typeof t!="boolean"&&null!=t&&(e=(r=e)&&r[t]===n?null:t,t=!1),null!=e&&(e=Q.createCallback(e,r,3)),ut(n,t,e)}function Wt(){for(var n=1<arguments.length?arguments:arguments[0],t=-1,e=n?Nt(Et(n,"length")):0,r=Ht(0>e?0:e);++t<e;)r[t]=Et(n,t);return r}function qt(n,t){for(var e=-1,r=n?n.length:0,u={};++e<r;){var o=n[e];
|
26
|
+
t?u[o]=t[e]:o&&(u[o[0]]=o[1])}return u}function Pt(n,t){return 2<arguments.length?at(n,17,Ae.call(arguments,2),null,t):at(n,1,null,null,t)}function Kt(n,t,e){function r(){c&&le(c),a=c=p=h,(g||v!==t)&&(s=he(),i=n.apply(l,o))}function u(){var e=t-(he()-f);0<e?c=me(u,e):(a&&le(a),e=p,a=c=p=h,e&&(s=he(),i=n.apply(l,o)))}var o,a,i,f,l,c,p,s=0,v=!1,g=!0;if(!gt(n))throw new re;if(t=Ee(0,t)||0,true===e)var y=!0,g=!1;else yt(e)&&(y=e.leading,v="maxWait"in e&&(Ee(t,e.maxWait)||0),g="trailing"in e?e.trailing:g);
|
27
|
+
return function(){if(o=arguments,f=he(),l=this,p=g&&(c||!y),false===v)var e=y&&!c;else{a||y||(s=f);var h=v-(f-s);0<h?a||(a=me(r,h)):(a&&(a=le(a)),s=f,i=n.apply(l,o))}return c||t===v||(c=me(u,t)),e&&(i=n.apply(l,o)),i}}function Lt(n){if(!gt(n))throw new re;var t=Ae.call(arguments,1);return me(function(){n.apply(h,t)},1)}function Mt(n){return n}function Ut(n,t){var e=n,r=!t||gt(e);t||(e=Y,t=n,n=Q),xt(vt(t),function(u){var o=n[u]=t[u];r&&(e.prototype[u]=function(){var t=this.__wrapped__,r=[t];return ge.apply(r,arguments),r=o.apply(n,r),t&&typeof t=="object"&&t===r?this:new e(r)
|
28
|
+
})})}function Vt(n,t,e){var r=null==n,u=null==t;return null==e&&(typeof n=="boolean"&&u?(e=n,n=1):u||typeof t!="boolean"||(e=t,u=!0)),r&&u&&(t=1),n=+n||0,u?(t=n,n=0):t=+t||0,r=Re(),e||n%1||t%1?n+Ie(r*(t-n+parseFloat("1e-"+((r+"").length-1))),t):n+ce(r*(t-n+1))}function Gt(){return this.__wrapped__}e=e?X.defaults(V.Object(),e,X.pick(V,D)):V;var Ht=e.Array,Jt=e.Boolean,Qt=e.Date,Xt=e.Function,Yt=e.Math,Zt=e.Number,ne=e.Object,te=e.RegExp,ee=e.String,re=e.TypeError,ue=[],oe=ne.prototype,ae=e._,ie=te("^"+ee(oe.valueOf).replace(/[.*+?^${}()|[\]\\]/g,"\\$&").replace(/valueOf|for [^\]]+/g,".+?")+"$"),fe=Yt.ceil,le=e.clearTimeout,ce=Yt.floor,pe=Xt.prototype.toString,se=ie.test(se=ne.getPrototypeOf)&&se,ve=oe.hasOwnProperty,he=ie.test(he=Qt.now)&&he||function(){return+new Qt
|
29
|
+
},ge=ue.push,ye=e.setImmediate,me=e.setTimeout,be=ue.splice,_e=oe.toString,de=ue.unshift,we=function(){try{var n={},t=ie.test(t=ne.defineProperty)&&t,e=t(n,n,n)&&t}catch(r){}return e}(),je=ie.test(je=_e.bind)&&je,ke=ie.test(ke=ne.create)&&ke,xe=ie.test(xe=Ht.isArray)&&xe,Ce=e.isFinite,Oe=e.isNaN,Ne=ie.test(Ne=ne.keys)&&Ne,Ee=Yt.max,Ie=Yt.min,Se=e.parseInt,Re=Yt.random,Ae=ue.slice,De=ie.test(e.attachEvent),Be=je&&!/\n|true/.test(je+De),$e={};$e[$]=Ht,$e[F]=Jt,$e[T]=Qt,$e[z]=Xt,$e[q]=ne,$e[W]=Zt,$e[P]=te,$e[K]=ee,Y.prototype=Q.prototype;
|
30
|
+
var Fe=Q.support={};Fe.fastBind=je&&!Be,Fe.funcDecomp=!ie.test(e.a)&&R.test(v),Fe.funcNames=typeof Xt.name=="string",Q.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:E,variable:"",imports:{_:Q}};var Te=we?function(n,t){var e=f();e.value=t,we(n,"__bindData__",e),p(e)}:l,ze=xe||function(n){return n&&typeof n=="object"&&typeof n.length=="number"&&_e.call(n)==$||!1},We=Ne?function(n){return yt(n)?Ne(n):[]}:H,qe={"&":"&","<":"<",">":">",'"':""","'":"'"},Pe=ht(qe),Ke=te("("+We(Pe).join("|")+")","g"),Le=te("["+We(qe).join("")+"]","g"),Me=ot(function(n,t,e){ve.call(n,e)?n[e]++:n[e]=1
|
31
|
+
}),Ue=ot(function(n,t,e){(ve.call(n,e)?n[e]:n[e]=[]).push(t)}),Ve=ot(function(n,t,e){n[e]=t});Be&&J&&typeof ye=="function"&&(Lt=function(n){if(!gt(n))throw new re;return ye.apply(e,arguments)});var Ge=8==Se(w+"08")?Se:function(n,t){return Se(bt(n)?n.replace(I,""):n,t||0)};return Q.after=function(n,t){if(!gt(t))throw new re;return function(){return 1>--n?t.apply(this,arguments):void 0}},Q.assign=G,Q.at=function(n){for(var t=arguments,e=-1,r=tt(t,!0,!1,1),t=t[2]&&t[2][t[1]]===n?1:r.length,u=Ht(t);++e<t;)u[e]=n[r[e]];
|
32
|
+
return u},Q.bind=Pt,Q.bindAll=function(n){for(var t=1<arguments.length?tt(arguments,!0,!1,1):vt(n),e=-1,r=t.length;++e<r;){var u=t[e];n[u]=at(n[u],1,null,null,n)}return n},Q.bindKey=function(n,t){return 2<arguments.length?at(t,19,Ae.call(arguments,2),null,n):at(t,3,null,null,n)},Q.chain=function(n){return n=new Y(n),n.__chain__=!0,n},Q.compact=function(n){for(var t=-1,e=n?n.length:0,r=[];++t<e;){var u=n[t];u&&r.push(u)}return r},Q.compose=function(){for(var n=arguments,t=n.length;t--;)if(!gt(n[t]))throw new re;
|
33
|
+
return function(){for(var t=arguments,e=n.length;e--;)t=[n[e].apply(this,t)];return t[0]}},Q.countBy=Me,Q.createCallback=function(n,t,e){var r=typeof n;if(null==n||"function"==r)return nt(n,t,e);if("object"!=r)return function(t){return t[n]};var u=We(n),o=u[0],a=n[o];return 1!=u.length||a!==a||yt(a)?function(t){for(var e=u.length,r=!1;e--&&(r=et(t[u[e]],n[u[e]],null,!0)););return r}:function(n){return n=n[o],a===n&&(0!==a||1/a==1/n)}},Q.curry=function(n,t){return t=typeof t=="number"?t:+t||n.length,at(n,4,null,null,null,t)
|
34
|
+
},Q.debounce=Kt,Q.defaults=U,Q.defer=Lt,Q.delay=function(n,t){if(!gt(n))throw new re;var e=Ae.call(arguments,2);return me(function(){n.apply(h,e)},t)},Q.difference=Dt,Q.filter=jt,Q.flatten=function(n,t,e,r){return typeof t!="boolean"&&null!=t&&(e=(r=e)&&r[t]===n?null:t,t=!1),null!=e&&(n=Ot(n,e,r)),tt(n,t)},Q.forEach=xt,Q.forEachRight=Ct,Q.forIn=d,Q.forInRight=function(n,t,e){var r=[];d(n,function(n,t){r.push(t,n)});var u=r.length;for(t=nt(t,e,3);u--&&false!==t(r[u--],r[u],n););return n},Q.forOwn=y,Q.forOwnRight=st,Q.functions=vt,Q.groupBy=Ue,Q.indexBy=Ve,Q.initial=function(n,t,e){var r=0,u=n?n.length:0;
|
35
|
+
if(typeof t!="number"&&null!=t){var o=u;for(t=Q.createCallback(t,e,3);o--&&t(n[o],o,n);)r++}else r=null==t||e?1:t||r;return s(n,0,Ie(Ee(0,u-r),u))},Q.intersection=function(e){for(var r=arguments,u=r.length,a=-1,f=i(),l=-1,s=ft(),v=e?e.length:0,h=[],g=i();++a<u;){var y=r[a];f[a]=s===n&&(y?y.length:0)>=_&&o(a?r[a]:g)}n:for(;++l<v;){var m=f[0],y=e[l];if(0>(m?t(m,y):s(g,y))){for(a=u,(m||g).push(y);--a;)if(m=f[a],0>(m?t(m,y):s(r[a],y)))continue n;h.push(y)}}for(;u--;)(m=f[u])&&p(m);return c(f),c(g),h},Q.invert=ht,Q.invoke=function(n,t){var e=Ae.call(arguments,2),r=-1,u=typeof t=="function",o=n?n.length:0,a=Ht(typeof o=="number"?o:0);
|
36
|
+
return xt(n,function(n){a[++r]=(u?t:n[t]).apply(n,e)}),a},Q.keys=We,Q.map=Ot,Q.max=Nt,Q.memoize=function(n,t){function e(){var r=e.cache,u=t?t.apply(this,arguments):b+arguments[0];return ve.call(r,u)?r[u]:r[u]=n.apply(this,arguments)}if(!gt(n))throw new re;return e.cache={},e},Q.merge=function(n){var t=arguments,e=2;if(!yt(n))return n;if("number"!=typeof t[2]&&(e=t.length),3<e&&"function"==typeof t[e-2])var r=nt(t[--e-1],t[e--],2);else 2<e&&"function"==typeof t[e-1]&&(r=t[--e]);for(var t=Ae.call(arguments,1,e),u=-1,o=i(),a=i();++u<e;)rt(n,t[u],r,o,a);
|
37
|
+
return c(o),c(a),n},Q.min=function(n,t,e){var u=1/0,o=u;if(!t&&ze(n)){e=-1;for(var a=n.length;++e<a;){var i=n[e];i<o&&(o=i)}}else t=!t&&bt(n)?r:Q.createCallback(t,e,3),xt(n,function(n,e,r){e=t(n,e,r),e<u&&(u=e,o=n)});return o},Q.omit=function(n,t,e){var r=ft(),u=typeof t=="function",o={};if(u)t=Q.createCallback(t,e,3);else var a=tt(arguments,!0,!1,1);return d(n,function(n,e,i){(u?!t(n,e,i):0>r(a,e))&&(o[e]=n)}),o},Q.once=function(n){var t,e;if(!gt(n))throw new re;return function(){return t?e:(t=!0,e=n.apply(this,arguments),n=null,e)
|
38
|
+
}},Q.pairs=function(n){for(var t=-1,e=We(n),r=e.length,u=Ht(r);++t<r;){var o=e[t];u[t]=[o,n[o]]}return u},Q.partial=function(n){return at(n,16,Ae.call(arguments,1))},Q.partialRight=function(n){return at(n,32,null,Ae.call(arguments,1))},Q.pick=function(n,t,e){var r={};if(typeof t!="function")for(var u=-1,o=tt(arguments,!0,!1,1),a=yt(n)?o.length:0;++u<a;){var i=o[u];i in n&&(r[i]=n[i])}else t=Q.createCallback(t,e,3),d(n,function(n,e,u){t(n,e,u)&&(r[e]=n)});return r},Q.pluck=Et,Q.pull=function(n){for(var t=arguments,e=0,r=t.length,u=n?n.length:0;++e<r;)for(var o=-1,a=t[e];++o<u;)n[o]===a&&(be.call(n,o--,1),u--);
|
39
|
+
return n},Q.range=function(n,t,e){n=+n||0,e=typeof e=="number"?e:+e||1,null==t&&(t=n,n=0);var r=-1;t=Ee(0,fe((t-n)/(e||1)));for(var u=Ht(t);++r<t;)u[r]=n,n+=e;return u},Q.reject=function(n,t,e){return t=Q.createCallback(t,e,3),jt(n,function(n,e,r){return!t(n,e,r)})},Q.remove=function(n,t,e){var r=-1,u=n?n.length:0,o=[];for(t=Q.createCallback(t,e,3);++r<u;)e=n[r],t(e,r,n)&&(o.push(e),be.call(n,r--,1),u--);return o},Q.rest=Ft,Q.shuffle=Rt,Q.sortBy=function(n,t,e){var r=-1,o=n?n.length:0,a=Ht(typeof o=="number"?o:0);
|
40
|
+
for(t=Q.createCallback(t,e,3),xt(n,function(n,e,u){var o=a[++r]=f();o.l=t(n,e,u),o.m=r,o.n=n}),o=a.length,a.sort(u);o--;)n=a[o],a[o]=n.n,p(n);return a},Q.tap=function(n,t){return t(n),n},Q.throttle=function(n,t,e){var r=!0,u=!0;if(!gt(n))throw new re;return false===e?r=!1:yt(e)&&(r="leading"in e?e.leading:r,u="trailing"in e?e.trailing:u),e=f(),e.leading=r,e.maxWait=t,e.trailing=u,n=Kt(n,t,e),p(e),n},Q.times=function(n,t,e){n=-1<(n=+n)?n:0;var r=-1,u=Ht(n);for(t=nt(t,e,1);++r<n;)u[r]=t(r);return u},Q.toArray=function(n){return n&&typeof n.length=="number"?s(n):_t(n)
|
41
|
+
},Q.transform=function(n,t,e,r){var u=ze(n);return t=nt(t,r,4),null==e&&(u?e=[]:(r=n&&n.constructor,e=yt(r&&r.prototype)?ke(r&&r.prototype):{})),(u?xt:y)(n,function(n,r,u){return t(e,n,r,u)}),e},Q.union=function(){return ut(tt(arguments,!0,!0))},Q.uniq=zt,Q.values=_t,Q.where=jt,Q.without=function(n){return Dt(n,Ae.call(arguments,1))},Q.wrap=function(n,t){if(!gt(t))throw new re;return function(){var e=[n];return ge.apply(e,arguments),t.apply(this,e)}},Q.zip=Wt,Q.zipObject=qt,Q.collect=Ot,Q.drop=Ft,Q.each=xt,Q.c=Ct,Q.extend=G,Q.methods=vt,Q.object=qt,Q.select=jt,Q.tail=Ft,Q.unique=zt,Q.unzip=Wt,Ut(Q),Q.clone=function(n,t,e,r){return typeof t!="boolean"&&null!=t&&(r=e,e=t,t=!1),Z(n,t,typeof e=="function"&&nt(e,r,1))
|
42
|
+
},Q.cloneDeep=function(n,t,e){return Z(n,!0,typeof t=="function"&&nt(t,e,1))},Q.contains=dt,Q.escape=function(n){return null==n?"":ee(n).replace(Le,it)},Q.every=wt,Q.find=kt,Q.findIndex=function(n,t,e){var r=-1,u=n?n.length:0;for(t=Q.createCallback(t,e,3);++r<u;)if(t(n[r],r,n))return r;return-1},Q.findKey=function(n,t,e){var r;return t=Q.createCallback(t,e,3),y(n,function(n,e,u){return t(n,e,u)?(r=e,!1):void 0}),r},Q.findLast=function(n,t,e){var r;return t=Q.createCallback(t,e,3),Ct(n,function(n,e,u){return t(n,e,u)?(r=n,!1):void 0
|
43
|
+
}),r},Q.findLastIndex=function(n,t,e){var r=n?n.length:0;for(t=Q.createCallback(t,e,3);r--;)if(t(n[r],r,n))return r;return-1},Q.findLastKey=function(n,t,e){var r;return t=Q.createCallback(t,e,3),st(n,function(n,e,u){return t(n,e,u)?(r=e,!1):void 0}),r},Q.has=function(n,t){return n?ve.call(n,t):!1},Q.identity=Mt,Q.indexOf=$t,Q.isArguments=pt,Q.isArray=ze,Q.isBoolean=function(n){return true===n||false===n||_e.call(n)==F},Q.isDate=function(n){return n?typeof n=="object"&&_e.call(n)==T:!1},Q.isElement=function(n){return n?1===n.nodeType:!1
|
44
|
+
},Q.isEmpty=function(n){var t=!0;if(!n)return t;var e=_e.call(n),r=n.length;return e==$||e==K||e==B||e==q&&typeof r=="number"&>(n.splice)?!r:(y(n,function(){return t=!1}),t)},Q.isEqual=function(n,t,e,r){return et(n,t,typeof e=="function"&&nt(e,r,2))},Q.isFinite=function(n){return Ce(n)&&!Oe(parseFloat(n))},Q.isFunction=gt,Q.isNaN=function(n){return mt(n)&&n!=+n},Q.isNull=function(n){return null===n},Q.isNumber=mt,Q.isObject=yt,Q.isPlainObject=g,Q.isRegExp=function(n){return n?typeof n=="object"&&_e.call(n)==P:!1
|
45
|
+
},Q.isString=bt,Q.isUndefined=function(n){return typeof n=="undefined"},Q.lastIndexOf=function(n,t,e){var r=n?n.length:0;for(typeof e=="number"&&(r=(0>e?Ee(0,r+e):Ie(e,r-1))+1);r--;)if(n[r]===t)return r;return-1},Q.mixin=Ut,Q.noConflict=function(){return e._=ae,this},Q.parseInt=Ge,Q.random=Vt,Q.reduce=It,Q.reduceRight=St,Q.result=function(n,t){if(n){var e=n[t];return gt(e)?n[t]():e}},Q.runInContext=v,Q.size=function(n){var t=n?n.length:0;return typeof t=="number"?t:We(n).length},Q.some=At,Q.sortedIndex=Tt,Q.template=function(n,t,e){var r=Q.templateSettings;
|
46
|
+
n||(n=""),e=U({},e,r);var u,o=U({},e.imports,r.imports),r=We(o),o=_t(o),i=0,f=e.interpolate||S,l="__p+='",f=te((e.escape||S).source+"|"+f.source+"|"+(f===E?C:S).source+"|"+(e.evaluate||S).source+"|$","g");n.replace(f,function(t,e,r,o,f,c){return r||(r=o),l+=n.slice(i,c).replace(A,a),e&&(l+="'+__e("+e+")+'"),f&&(u=!0,l+="';"+f+";__p+='"),r&&(l+="'+((__t=("+r+"))==null?'':__t)+'"),i=c+t.length,t}),l+="';\n",f=e=e.variable,f||(e="obj",l="with("+e+"){"+l+"}"),l=(u?l.replace(j,""):l).replace(k,"$1").replace(x,"$1;"),l="function("+e+"){"+(f?"":e+"||("+e+"={});")+"var __t,__p='',__e=_.escape"+(u?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":";")+l+"return __p}";
|
47
|
+
try{var c=Xt(r,"return "+l).apply(h,o)}catch(p){throw p.source=l,p}return t?c(t):(c.source=l,c)},Q.unescape=function(n){return null==n?"":ee(n).replace(Ke,ct)},Q.uniqueId=function(n){var t=++m;return ee(null==n?"":n)+t},Q.all=wt,Q.any=At,Q.detect=kt,Q.findWhere=kt,Q.foldl=It,Q.foldr=St,Q.include=dt,Q.inject=It,y(Q,function(n,t){Q.prototype[t]||(Q.prototype[t]=function(){var t=[this.__wrapped__],e=this.__chain__;return ge.apply(t,arguments),t=n.apply(Q,t),e?new Y(t,e):t})}),Q.first=Bt,Q.last=function(n,t,e){var r=0,u=n?n.length:0;
|
48
|
+
if(typeof t!="number"&&null!=t){var o=u;for(t=Q.createCallback(t,e,3);o--&&t(n[o],o,n);)r++}else if(r=t,null==r||e)return n?n[u-1]:h;return s(n,Ee(0,u-r))},Q.sample=function(n,t,e){var r=n?n.length:0;return typeof r!="number"&&(n=_t(n)),null==t||e?n?n[Vt(r-1)]:h:(n=Rt(n),n.length=Ie(Ee(0,t),n.length),n)},Q.take=Bt,Q.head=Bt,y(Q,function(n,t){var e="sample"!==t;Q.prototype[t]||(Q.prototype[t]=function(t,r){var u=this.__chain__,o=n(this.__wrapped__,t,r);return u||null!=t&&(!r||e&&typeof t=="function")?new Y(o,u):o
|
49
|
+
})}),Q.VERSION="2.1.0",Q.prototype.chain=function(){return this.__chain__=!0,this},Q.prototype.toString=function(){return ee(this.__wrapped__)},Q.prototype.value=Gt,Q.prototype.valueOf=Gt,xt(["join","pop","shift"],function(n){var t=ue[n];Q.prototype[n]=function(){var n=this.__chain__,e=t.apply(this.__wrapped__,arguments);return n?new Y(e,n):e}}),xt(["push","reverse","sort","unshift"],function(n){var t=ue[n];Q.prototype[n]=function(){return t.apply(this.__wrapped__,arguments),this}}),xt(["concat","slice","splice"],function(n){var t=ue[n];
|
50
|
+
Q.prototype[n]=function(){return new Y(t.apply(this.__wrapped__,arguments),this.__chain__)}}),Q}var h,g=[],y=[],m=0,b=+new Date+"",_=75,d=40,w=" \t\x0B\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000",j=/\b__p\+='';/g,k=/\b(__p\+=)''\+/g,x=/(__e\(.*?\)|\b__t\))\+'';/g,C=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,O=/\w*$/,N=/^function[ \n\r\t]+\w/,E=/<%=([\s\S]+?)%>/g,I=RegExp("^["+w+"]*0+(?=.$)"),S=/($^)/,R=/\bthis\b/,A=/['\n\r\t\u2028\u2029\\]/g,D="Array Boolean Date Function Math Number Object RegExp String _ attachEvent clearTimeout isFinite isNaN parseInt setImmediate setTimeout".split(" "),B="[object Arguments]",$="[object Array]",F="[object Boolean]",T="[object Date]",z="[object Function]",W="[object Number]",q="[object Object]",P="[object RegExp]",K="[object String]",L={};
|
51
|
+
L[z]=!1,L[B]=L[$]=L[F]=L[T]=L[W]=L[q]=L[P]=L[K]=!0;var M={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,undefined:!1},U={"\\":"\\","'":"'","\n":"n","\r":"r","\t":"t","\u2028":"u2028","\u2029":"u2029"},V=M[typeof window]&&window||this,G=M[typeof exports]&&exports&&!exports.nodeType&&exports,H=M[typeof module]&&module&&!module.nodeType&&module,J=H&&H.exports===G&&G,Q=M[typeof global]&&global;!Q||Q.global!==Q&&Q.window!==Q||(V=Q);var X=v();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(V._=X, define(function(){return X
|
52
|
+
})):G&&H?J?(H.exports=X)._=X:G._=X:V._=X}).call(this);
|