mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-01 07:47:49 +00:00
Optimize _.isNumber and _.isString. [closes #126]
Former-commit-id: 633dfe2e9c2c0ff7e54d5bbb4bf95f9adcca83c4
This commit is contained in:
2
build.js
2
build.js
@@ -108,7 +108,7 @@
|
||||
'isEqual': ['isArguments', 'isFunction'],
|
||||
'isFinite': [],
|
||||
'isFunction': [],
|
||||
'isNaN': [],
|
||||
'isNaN': ['isNumber'],
|
||||
'isNull': [],
|
||||
'isNumber': [],
|
||||
'isObject': [],
|
||||
|
||||
@@ -1482,7 +1482,7 @@
|
||||
function isNaN(value) {
|
||||
// `NaN` as a primitive is the only value that is not equal to itself
|
||||
// (perform the [[Class]] check first to avoid errors with some host objects in IE)
|
||||
return toString.call(value) == numberClass && value != +value
|
||||
return isNumber(value) && value != +value
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1519,7 +1519,7 @@
|
||||
* // => true
|
||||
*/
|
||||
function isNumber(value) {
|
||||
return toString.call(value) == numberClass;
|
||||
return typeof value == 'number' || toString.call(value) == numberClass;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1589,7 +1589,7 @@
|
||||
* // => true
|
||||
*/
|
||||
function isString(value) {
|
||||
return toString.call(value) == stringClass;
|
||||
return typeof value == 'string' || toString.call(value) == stringClass;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
72
lodash.min.js
vendored
72
lodash.min.js
vendored
@@ -2,40 +2,40 @@
|
||||
Lo-Dash 0.10.0 lodash.com/license
|
||||
Underscore.js 1.4.2 underscorejs.org/LICENSE
|
||||
*/
|
||||
;(function(e,t){function s(t,r){var i,s=e.onerror,o=e._,u=G.createElement("script"),a=G.scripts[0];e.onerror=function(e){return i=e,n},u.text="var _=function("+t+"){"+r+"\n}",a.parentNode.insertBefore(u,a).parentNode.removeChild(u),u=e._,e._=o,e.onerror=s;if(i)throw new SyntaxError(i);return u}function o(e){if(e&&"object"==typeof e&&e.__wrapped__)return e;if(!(this instanceof o))return new o(e);this.__wrapped__=e}function u(e,t,n){t||(t=0);var r=e.length,i=r-t>=(n||nt);if(i)for(var s={},n=t-1;++n<
|
||||
r;){var o=e[n]+"";(St.call(s,o)?s[o]:s[o]=[]).push(e[n])}return function(n){if(i){var r=n+"";return St.call(s,r)&&-1<R(s[r],n)}return-1<R(e,n,t)}}function a(e){return e.charCodeAt(0)}function f(e,n){var r=e.b,i=n.b,e=e.a,n=n.a;if(e!==n){if(e>n||e===t)return 1;if(e<n||n===t)return-1}return r<i?-1:1}function l(e,t,n){function r(){var u=arguments,a=s?this:t;return i||(e=t[o]),n.length&&(u=u.length?n.concat(Nt.call(u)):n),this instanceof r?(v.prototype=e.prototype,a=new v,u=e.apply(a,u),N(u)?u:a):e.apply
|
||||
(a,u)}var i=T(e),s=!n,o=t;return s&&(n=t),i||(t=e),r}function c(e,n){return e?"function"!=typeof e?function(t){return t[e]}:n!==t?function(t,r,i){return e.call(n,t,r,i)}:e:V}function h(){for(var e={b:"",c:"",e:zt,f:Yt,g:"",h:Vt,i:Jt,j:gt,k:"",l:n},t,r=0;t=arguments[r];r++)for(var i in t)e[i]=t[i];t=e.a,e.d=/^[^,]+/.exec(t)[0],r="var i,l="+e.d+",t="+e.d+";if(!"+e.d+")return t;"+e.k+";",e.b?(r+="var m=l.length;i=-1;if(typeof m=='number'){",e.i&&(r+="if(k(l)){l=l.split('')}"),r+="while(++i<m){"+e.b+"}}else {"
|
||||
;(function(e,t){function s(t,r){var i,s=e.onerror,o=e._,u=Y.createElement("script"),a=Y.scripts[0];e.onerror=function(e){return i=e,n},u.text="var _=function("+t+"){"+r+"\n}",a.parentNode.insertBefore(u,a).parentNode.removeChild(u),u=e._,e._=o,e.onerror=s;if(i)throw new SyntaxError(i);return u}function o(e){if(e&&"object"==typeof e&&e.__wrapped__)return e;if(!(this instanceof o))return new o(e);this.__wrapped__=e}function u(e,t,n){t||(t=0);var r=e.length,i=r-t>=(n||rt);if(i)for(var s={},n=t-1;++n<
|
||||
r;){var o=e[n]+"";(xt.call(s,o)?s[o]:s[o]=[]).push(e[n])}return function(n){if(i){var r=n+"";return xt.call(s,r)&&-1<U(s[r],n)}return-1<U(e,n,t)}}function a(e){return e.charCodeAt(0)}function f(e,n){var r=e.b,i=n.b,e=e.a,n=n.a;if(e!==n){if(e>n||e===t)return 1;if(e<n||n===t)return-1}return r<i?-1:1}function l(e,t,n){function r(){var u=arguments,a=s?this:t;return i||(e=t[o]),n.length&&(u=u.length?n.concat(Ct.call(u)):n),this instanceof r?(v.prototype=e.prototype,a=new v,u=e.apply(a,u),N(u)?u:a):e.apply
|
||||
(a,u)}var i=T(e),s=!n,o=t;return s&&(n=t),i||(t=e),r}function c(e,n){return e?"function"!=typeof e?function(t){return t[e]}:n!==t?function(t,r,i){return e.call(n,t,r,i)}:e:$}function h(){for(var e={b:"",c:"",e:Wt,f:Zt,g:"",h:$t,i:Kt,j:yt,k:"",l:n},t,r=0;t=arguments[r];r++)for(var i in t)e[i]=t[i];t=e.a,e.d=/^[^,]+/.exec(t)[0],r="var i,l="+e.d+",t="+e.d+";if(!"+e.d+")return t;"+e.k+";",e.b?(r+="var m=l.length;i=-1;if(typeof m=='number'){",e.i&&(r+="if(k(l)){l=l.split('')}"),r+="while(++i<m){"+e.b+"}}else {"
|
||||
):e.h&&(r+="var m=l.length;i=-1;if(m&&j(l)){while(++i<m){i+='';"+e.g+"}}else {"),e.e||(r+="var u=typeof l=='function'&&s.call(l,'prototype');");if(e.f&&e.l)r+="var q=-1,r=p[typeof l]?n(l):[],m=r.length;while(++q<m){i=r[q];",e.e||(r+="if(!(u&&i=='prototype')){"),r+=e.g+"",e.e||(r+="}");else{r+="for(i in l){";if(!e.e||e.l)r+="if(",e.e||(r+="!(u&&i=='prototype')"),!e.e&&e.l&&(r+="&&"),e.l&&(r+="h.call(l,i)"),r+="){";r+=e.g+";";if(!e.e||e.l)r+="}"}r+="}";if(e.e){r+="var f=l.constructor;";for(i=0;7>i;
|
||||
i++)r+="i='"+e.j[i]+"';if(","constructor"==e.j[i]&&(r+="!(f&&f.prototype===l)&&"),r+="h.call(l,i)){"+e.g+"}"}if(e.b||e.h)r+="}";return r+=e.c+";return t",s("e,h,j,k,p,n,s","return function("+t+"){"+r+"}")(c,St,g,C,en,Mt,Tt)}function p(e){return"\\"+tn[e]}function d(e){return ln[e]}function v(){}function m(e){return cn[e]}function g(e){return Ct.call(e)==Ht}function y(e){var t=i;if(!e||"object"!=typeof e||g(e))return t;var n=e.constructor;return(!Kt||"function"==typeof e.toString||"string"!=typeof
|
||||
(e+""))&&(!T(n)||n instanceof n)?Wt?(an(e,function(e,n,r){return t=!St.call(r,n),i}),t===i):(an(e,function(e,n){t=n}),t===i||St.call(e,t)):t}function b(e){var t=[];return fn(e,function(e,n){t.push(n)}),t}function w(e,t,n,s,o){if(e==r)return e;n&&(t=i);if(n=N(e)){var u=Ct.call(e);if(!Zt[u]||$t&&g(e))return e;var a=u==Bt,n=a||(u==qt?dn(e):n)}if(!n||!t)return n?a?Nt.call(e):un({},e):e;n=e.constructor;switch(u){case jt:case Ft:return new n(+e);case It:case Ut:return new n(e);case Rt:return n(e.source
|
||||
,ft.exec(e))}s||(s=[]),o||(o=[]);for(u=s.length;u--;)if(s[u]==e)return o[u];var f=a?n(e.length):{};return s.push(e),o.push(f),(a?mn:fn)(e,function(e,n){f[n]=w(e,t,r,s,o)}),f}function E(e){var t=[];return an(e,function(e,n){T(e)&&t.push(n)}),t.sort()}function S(e){var t={};return fn(e,function(e,n){t[e]=n}),t}function x(e,t,s,o){if(e===t)return 0!==e||1/e==1/t;if(e==r||t==r)return e===t;var u=Ct.call(e);if(u!=Ct.call(t))return i;switch(u){case jt:case Ft:return+e==+t;case It:return e!=+e?t!=+t:0==
|
||||
e?1/e==1/t:e==+t;case Rt:case Ut:return e==t+""}var a=u==Bt||u==Ht;if($t&&!a&&(a=g(e))&&!g(t))return i;if(!a){if(e.__wrapped__||t.__wrapped__)return x(e.__wrapped__||e,t.__wrapped__||t);if(u!=qt||Kt&&("function"!=typeof e.toString&&"string"==typeof (e+"")||"function"!=typeof t.toString&&"string"==typeof (t+"")))return i;var u=e.constructor,f=t.constructor;if(u!=f&&(!T(u)||!(u instanceof u&&T(f)&&f instanceof f)))return i}s||(s=[]),o||(o=[]);for(u=s.length;u--;)if(s[u]==e)return o[u]==t;var u=-1,f=
|
||||
n,l=0;s.push(e),o.push(t);if(a){l=e.length;if(f=l==t.length)for(;l--&&(f=x(e[l],t[l],s,o)););return f}for(var c in e)if(St.call(e,c)&&(l++,!St.call(t,c)||!x(e[c],t[c],s,o)))return i;for(c in t)if(St.call(t,c)&&!(l--))return i;if(zt)for(;7>++u;)if(c=gt[u],St.call(e,c)&&(!St.call(t,c)||!x(e[c],t[c],s,o)))return i;return n}function T(e){return"function"==typeof e}function N(e){return e?en[typeof e]:i}function C(e){return Ct.call(e)==Ut}function k(e,t,n){var i=arguments,s=0,o=2,u=i[3],a=i[4];n!==tt&&
|
||||
(u=[],a=[],"number"!=typeof n&&(o=i.length));for(;++s<o;)fn(i[s],function(t,n){var i,s,o;if(t&&((s=pn(t))||dn(t))){for(var f=u.length;f--;)if(i=u[f]==t)break;i?e[n]=a[f]:(u.push(t),a.push(o=(o=e[n],s)?pn(o)?o:[]:dn(o)?o:{}),e[n]=k(o,t,tt,u,a))}else t!=r&&(e[n]=t)});return e}function L(e){var t=[];return fn(e,function(e){t.push(e)}),t}function A(e,t,n){var r=-1,s=e?e.length:0,o=i,n=(0>n?_t(0,s+n):n)||0;return"number"==typeof s?o=-1<(C(e)?e.indexOf(t,n):R(e,t,n)):mn(e,function(e){if(++r>=n)return!(
|
||||
o=e===t)}),o}function O(e,t,r){var i=n,t=c(t,r);if(pn(e))for(var r=-1,s=e.length;++r<s&&(i=!!t(e[r],r,e)););else mn(e,function(e,n,r){return i=!!t(e,n,r)});return i}function M(e,t,n){var r=[],t=c(t,n);if(pn(e))for(var n=-1,i=e.length;++n<i;){var s=e[n];t(s,n,e)&&r.push(s)}else mn(e,function(e,n,i){t(e,n,i)&&r.push(e)});return r}function _(e,t,n){var r,t=c(t,n);return mn(e,function(e,n,s){if(t(e,n,s))return r=e,i}),r}function D(e,t,n){var r=-1,i=e?e.length:0,s=Array("number"==typeof i?i:0),t=c(t,n
|
||||
);if(pn(e))for(;++r<i;)s[r]=t(e[r],r,e);else mn(e,function(e,n,i){s[++r]=t(e,n,i)});return s}function P(e,t,n){var r=-Infinity,i=-1,s=e?e.length:0,o=r;if(t||!pn(e))t=!t&&C(e)?a:c(t,n),mn(e,function(e,n,i){n=t(e,n,i),n>r&&(r=n,o=e)});else for(;++i<s;)e[i]>o&&(o=e[i]);return o}function H(e,t){var n=[];return mn(e,function(e){n.push(e[t])}),n}function B(e,t,n,r){var s=3>arguments.length;return t||(t=V),mn(e,function(e,o,u){n=s?(s=i,e):t.call(r,n,e,o,u)}),n}function j(e,t,n,r){var s=e,o=e?e.length:0,
|
||||
u=3>arguments.length;if("number"!=typeof o)var a=vn(e),o=a.length;else Jt&&C(e)&&(s=e.split(""));return t||(t=V),mn(e,function(e,f,l){f=a?a[--o]:--o,n=u?(u=i,s[f]):t.call(r,n,s[f],f,l)}),n}function F(e,t,n){var r,t=c(t,n);if(pn(e))for(var n=-1,i=e.length;++n<i&&!(r=t(e[n],n,e)););else mn(e,function(e,n,i){return!(r=t(e,n,i))});return!!r}function I(e,t,n){if(e)return t==r||n?e[0]:Nt.call(e,0,t)}function q(e,t){for(var n=-1,r=e?e.length:0,i=[];++n<r;){var s=e[n];pn(s)?xt.apply(i,t?s:q(s)):i.push(s)
|
||||
}return i}function R(e,t,n){var r=-1,i=e?e.length:0;if("number"==typeof n)r=(0>n?_t(0,i+n):n||0)-1;else if(n)return r=z(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function U(e,t,n){return e?Nt.call(e,t==r||n?1:t):[]}function z(e,t,n,r){for(var i=0,s=e?e.length:i,n=n?c(n,r):V,t=n(t);i<s;)r=i+s>>>1,n(e[r])<t?i=r+1:s=r;return i}function W(e,t,n,r){var s=-1,o=e?e.length:0,u=[],a=u;"function"==typeof t&&(r=n,n=t,t=i);var f=!t&&74<o;if(f)var l={};n&&(a=[],n=c(n,r));for(;++s<o;){var r=
|
||||
e[s],h=n?n(r,s,e):r;f&&(a=St.call(l,h+"")?l[h]:l[h]=[]);if(t?!s||a[a.length-1]!==h:0>R(a,h))(n||f)&&a.push(h),u.push(r)}return u}function X(e,t){return Gt||kt&&2<arguments.length?kt.call.apply(kt,arguments):l(e,t,Nt.call(arguments,2))}function V(e){return e}function $(e){mn(E(e),function(t){var n=o[t]=e[t];o.prototype[t]=function(){var e=[this.__wrapped__];return xt.apply(e,arguments),e=n.apply(o,e),new o(e)}})}function J(){return this.__wrapped__}var n=!0,r=null,i=!1,K="object"==typeof exports&&
|
||||
exports,Q="object"==typeof global&&global;Q.global===Q&&(e=Q);var G=e.document,Y=[],Z=new function(){},et=0,tt=Z,nt=30,rt=e._,it=/[-?+=!~*%&^<>|{(\/]|\[\D|\b(?:delete|in|instanceof|new|typeof|void)\b/,st=/&(?:amp|lt|gt|quot|#x27);/g,ot=/\b__p\+='';/g,ut=/\b(__p\+=)''\+/g,at=/(__e\(.*?\)|\b__t\))\+'';/g,ft=/\w*$/,lt=/(?:__e|__t=)\(\s*(?![\d\s"']|this\.)/g,ct=RegExp("^"+(Z.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&").replace(/valueOf|for [^\]]+/g,".+?")+"$"),ht=/\$\{((?:(?=\\?)\\?[\s\S])*?)}/g
|
||||
,pt=/<%=([\s\S]+?)%>/g,dt=/($^)/,vt=/[&<>"']/g,mt=/['\n\r\t\u2028\u2029\\]/g,gt="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" "),yt=Math.ceil,bt=Y.concat,wt=Math.floor,Et=ct.test(Et=Object.getPrototypeOf)&&Et,St=Z.hasOwnProperty,xt=Y.push,Tt=Z.propertyIsEnumerable,Nt=Y.slice,Ct=Z.toString,kt=ct.test(kt=Nt.bind)&&kt,Lt=ct.test(Lt=Array.isArray)&&Lt,At=e.isFinite,Ot=e.isNaN,Mt=ct.test(Mt=Object.keys)&&Mt,_t=Math.max,Dt=Math.min,Pt=Math.random
|
||||
,Ht="[object Arguments]",Bt="[object Array]",jt="[object Boolean]",Ft="[object Date]",It="[object Number]",qt="[object Object]",Rt="[object RegExp]",Ut="[object String]",zt,Wt,Xt=(Xt={0:1,length:1},Y.splice.call(Xt,0,1),Xt[0]),Vt=n;(function(){function e(){this.x=1}var t=[];e.prototype={valueOf:1,y:1};for(var n in new e)t.push(n);for(n in arguments)Vt=!n;zt=!/valueOf/.test(t),Wt="x"!=t[0]})(1);var $t=!g(arguments),Jt="xx"!="x"[0]+Object("x")[0];try{var Kt=("[object Object]",Ct.call(G||0)==qt)}catch(
|
||||
Qt){}var Gt=kt&&/\n|Opera/.test(kt+Ct.call(e.opera)),Yt=Mt&&/^.+$|true/.test(Mt+!!e.attachEvent),Zt={};Zt[Ht]=Zt["[object Function]"]=i,Zt[Bt]=Zt[jt]=Zt[Ft]=Zt[It]=Zt[qt]=Zt[Rt]=Zt[Ut]=n;var en={"boolean":i,"function":n,object:n,number:i,string:i,"undefined":i},tn={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};o.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:pt,variable:""};try{s()}catch(nn){s=Function}var rn={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:"}}"},sn={a:"d,c,w",k:"c=e(c,w)",b:"if(c(l[i],i,d)===false)return t",g:"if(c(l[i],i,d)===false)return t"},on={b:r},un=h(rn);$t&&(g=function(e){return e?St.call(e,"callee"):i});var an=h(sn,on,{l:i}),fn=h(sn,on),ln={"&":"&","<":"<",">":">",'"':""","'":"'"},cn=S(ln),hn=h(rn,{g:"if(t[i]==null)"+rn.g}),pn=Lt||function(e){return Ct.call(e)==Bt};T(/x/)&&(T=function(e){return"[object Function]"==Ct.call(e)});var dn=Et?function(e){if(!e||"object"!=typeof e)return i;var t=
|
||||
e.valueOf,n="function"==typeof t&&(n=Et(t))&&Et(n);return n?e==n||Et(e)==n&&!g(e):y(e)}:y,vn=Mt?function(e){return"function"==typeof e&&Tt.call(e,"prototype")?b(e):N(e)?Mt(e):[]}:b,mn=h(sn);o.VERSION="0.10.0",o.assign=un,o.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},o.bind=X,o.bindAll=function(e){for(var t=arguments,n=1<t.length?0:(t=E(e),-1),r=t.length;++n<r;){var i=t[n];e[i]=X(e[i],e)}return e},o.bindKey=function(e,t){return l(e,t,Nt.call(arguments,2)
|
||||
)},o.chain=function(e){return new o(e)},o.clone=w,o.compact=function(e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r},o.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},o.contains=A,o.countBy=function(e,t,n){var r={},t=c(t,n);return mn(e,function(e,n,i){n=t(e,n,i),St.call(r,n)?r[n]++:r[n]=1}),r},o.debounce=function(e,t,n){function i(){a=r,n||(o=e.apply(u,s))}var s,o,u,a;return function(){var r=
|
||||
n&&!a;return s=arguments,u=this,clearTimeout(a),a=setTimeout(i,t),r&&(o=e.apply(u,s)),o}},o.defaults=hn,o.defer=function(e){var n=Nt.call(arguments,1);return setTimeout(function(){e.apply(t,n)},1)},o.delay=function(e,n){var r=Nt.call(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},o.difference=function(e){for(var t=-1,n=e?e.length:0,r=bt.apply(Y,arguments),r=u(r,n),i=[];++t<n;){var s=e[t];r(s)||i.push(s)}return i},o.escape=function(e){return e==r?"":(e+"").replace(vt,d)},o.every=O,o.filter=
|
||||
M,o.find=_,o.first=I,o.flatten=q,o.forEach=mn,o.forIn=an,o.forOwn=fn,o.functions=E,o.groupBy=function(e,t,n){var r={},t=c(t,n);return mn(e,function(e,n,i){n=t(e,n,i),(St.call(r,n)?r[n]:r[n]=[]).push(e)}),r},o.has=function(e,t){return e?St.call(e,t):i},o.identity=V,o.indexOf=R,o.initial=function(e,t,n){return e?Nt.call(e,0,-(t==r||n?1:t)):[]},o.intersection=function(e){var t=arguments,n=t.length,r={},i=[];return mn(e,function(e){if(0>R(i,e)){for(var s=n;--s;)if(!(r[s]||(r[s]=u(t[s])))(e))return;i.
|
||||
push(e)}}),i},o.invert=S,o.invoke=function(e,t){var n=Nt.call(arguments,2),r="function"==typeof t,i=[];return mn(e,function(e){i.push((r?t:e[t]).apply(e,n))}),i},o.isArguments=g,o.isArray=pn,o.isBoolean=function(e){return e===n||e===i||Ct.call(e)==jt},o.isDate=function(e){return Ct.call(e)==Ft},o.isElement=function(e){return e?1===e.nodeType:i},o.isEmpty=function(e){var t=n;if(!e)return t;var r=Ct.call(e),s=e.length;return r==Bt||r==Ut||r==Ht||$t&&g(e)||r==qt&&"number"==typeof s&&T(e.splice)?!s:(
|
||||
fn(e,function(){return t=i}),t)},o.isEqual=x,o.isFinite=function(e){return At(e)&&!Ot(parseFloat(e))},o.isFunction=T,o.isNaN=function(e){return Ct.call(e)==It&&e!=+e},o.isNull=function(e){return e===r},o.isNumber=function(e){return Ct.call(e)==It},o.isObject=N,o.isPlainObject=dn,o.isRegExp=function(e){return Ct.call(e)==Rt},o.isString=C,o.isUndefined=function(e){return e===t},o.keys=vn,o.last=function(e,t,n){if(e){var i=e.length;return t==r||n?e[i-1]:Nt.call(e,-t||i)}},o.lastIndexOf=function(e,t,
|
||||
n){var r=e?e.length:0;for("number"==typeof n&&(r=(0>n?_t(0,r+n):Dt(n,r-1))+1);r--;)if(e[r]===t)return r;return-1},o.map=D,o.max=P,o.memoize=function(e,t){var n={};return function(){var r=t?t.apply(this,arguments):arguments[0];return St.call(n,r)?n[r]:n[r]=e.apply(this,arguments)}},o.merge=k,o.min=function(e,t,n){var r=Infinity,i=-1,s=e?e.length:0,o=r;if(t||!pn(e))t=!t&&C(e)?a:c(t,n),mn(e,function(e,n,i){n=t(e,n,i),n<r&&(r=n,o=e)});else for(;++i<s;)e[i]<o&&(o=e[i]);return o},o.mixin=$,o.noConflict=
|
||||
function(){return e._=rt,this},o.object=function(e,t){for(var n=-1,r=e?e.length:0,i={};++n<r;){var s=e[n];t?i[s]=t[n]:i[s[0]]=s[1]}return i},o.omit=function(e,t,n){var r="function"==typeof t,i={};if(r)t=c(t,n);else var s=bt.apply(Y,arguments);return an(e,function(e,n,o){if(r?!t(e,n,o):0>R(s,n,1))i[n]=e}),i},o.once=function(e){var t,s=i;return function(){return s?t:(s=n,t=e.apply(this,arguments),e=r,t)}},o.pairs=function(e){var t=[];return fn(e,function(e,n){t.push([n,e])}),t},o.partial=function(e
|
||||
){return l(e,Nt.call(arguments,1))},o.pick=function(e,t,n){var r={};if("function"!=typeof t)for(var i=0,s=bt.apply(Y,arguments),o=s.length;++i<o;){var u=s[i];u in e&&(r[u]=e[u])}else t=c(t,n),an(e,function(e,n,i){t(e,n,i)&&(r[n]=e)});return r},o.pluck=H,o.random=function(e,t){return e==r&&t==r&&(t=1),e=+e||0,t==r&&(t=e,e=0),e+wt(Pt()*((+t||0)-e+1))},o.range=function(e,t,n){e=+e||0,n=+n||1,t==r&&(t=e,e=0);for(var i=-1,t=_t(0,yt((t-e)/n)),s=Array(t);++i<t;)s[i]=e,e+=n;return s},o.reduce=B,o.reduceRight=
|
||||
j,o.reject=function(e,t,n){return t=c(t,n),M(e,function(e,n,r){return!t(e,n,r)})},o.rest=U,o.result=function(e,t){var n=e?e[t]:r;return T(n)?e[t]():n},o.shuffle=function(e){var t=-1,n=Array(e?e.length:0);return mn(e,function(e){var r=wt(Pt()*(++t+1));n[t]=n[r],n[r]=e}),n},o.size=function(e){var t=e?e.length:0;return"number"==typeof t?t:vn(e).length},o.some=F,o.sortBy=function(e,t,n){var r=[],t=c(t,n);mn(e,function(e,n,i){r.push({a:t(e,n,i),b:n,c:e})}),e=r.length;for(r.sort(f);e--;)r[e]=r[e].c;return r
|
||||
},o.sortedIndex=z,o.tap=function(e,t){return t(e),e},o.template=function(e,t,n){e||(e=""),n||(n={});var r,i,u=o.templateSettings,a=0,f=n.interpolate||u.interpolate||dt,l="__p+='",c=n.variable||u.variable,h=c;e.replace(RegExp((n.escape||u.escape||dt).source+"|"+f.source+"|"+(f===pt?ht:dt).source+"|"+(n.evaluate||u.evaluate||dt).source+"|$","g"),function(t,n,i,s,o,u){i||(i=s),l+=e.slice(a,u).replace(mt,p),l+=n?"'+__e("+n+")+'":o?"';"+o+";__p+='":i?"'+((__t=("+i+"))==null?'':__t)+'":"",r||(r=o||it.test
|
||||
(n||i)),a=u+t.length}),l+="';\n",h||(c="obj",r?l="with("+c+"){"+l+"}":(n=RegExp("(\\(\\s*)"+c+"\\."+c+"\\b","g"),l=l.replace(lt,"$&"+c+".").replace(n,"$1__d"))),l=(r?l.replace(ot,""):l).replace(ut,"$1").replace(at,"$1;"),l="function("+c+"){"+(h?"":c+"||("+c+"={});")+"var __t,__p='',__e=_.escape"+(r?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":(h?"":",__d="+c+"."+c+"||"+c)+";")+l+"return __p}";try{i=s("_","return "+l)(o)}catch(d){throw d.source=l,d}return t?i(t):(i.source=
|
||||
l,i)},o.throttle=function(e,t){function n(){a=new Date,u=r,s=e.apply(o,i)}var i,s,o,u,a=0;return function(){var r=new Date,f=t-(r-a);return i=arguments,o=this,0>=f?(clearTimeout(u),a=r,s=e.apply(o,i)):u||(u=setTimeout(n,f)),s}},o.times=function(e,t,n){for(var e=+e||0,r=-1,i=Array(e);++r<e;)i[r]=t.call(n,r);return i},o.toArray=function(e){var t=e?e.length:0;if("number"==typeof t){Jt&&C(e)&&(e=e.split(""));for(var n=-1,r=Array(t);++n<t;)r[n]=e[n];return r}return L(e)},o.unescape=function(e){return e==
|
||||
r?"":(e+"").replace(st,m)},o.union=function(){return W(bt.apply(Y,arguments))},o.uniq=W,o.uniqueId=function(e){var t=et++;return e?e+t:t},o.values=L,o.where=function(e,t){var n=vn(t);return M(e,function(e){for(var r=n.length;r--;){var i=e[n[r]]===t[n[r]];if(!i)break}return!!i})},o.without=function(e){for(var t=-1,n=e?e.length:0,r=u(arguments,1,20),i=[];++t<n;){var s=e[t];r(s)||i.push(s)}return i},o.wrap=function(e,t){return function(){var n=[e];return xt.apply(n,arguments),t.apply(this,n)}},o.zip=
|
||||
function(e){for(var t=-1,n=e?P(H(arguments,"length")):0,r=Array(n);++t<n;)r[t]=H(arguments,t);return r},o.all=O,o.any=F,o.collect=D,o.detect=_,o.drop=U,o.each=mn,o.extend=un,o.foldl=B,o.foldr=j,o.head=I,o.include=A,o.inject=B,o.methods=E,o.select=M,o.tail=U,o.take=I,o.unique=W,$(o),o.prototype.chain=function(){return this},o.prototype.toString=function(){return""+this.__wrapped__},o.prototype.value=J,o.prototype.valueOf=J,mn(["first","last"],function(e){var t=o[e];t&&(o.prototype[e]=function(e,n)
|
||||
{var i=t(this.__wrapped__,e,n);return e==r||n?i:new o(i)})}),mn(M(E(o),function(e){return/^(?:contains|every|find|has|is[A-Z].+|reduce.*|some)$/.test(e)}),function(e){var t=o[e];o.prototype[e]=function(){var e=[this.__wrapped__];return xt.apply(e,arguments),t.apply(o,e)}}),mn("pop push reverse shift sort splice unshift".split(" "),function(e){var t=Y[e];o.prototype[e]=function(){var e=this.__wrapped__;return t.apply(e,arguments),Xt&&e.length===0&&delete e[0],this}}),mn(["concat","join","slice"],function(
|
||||
e){var t=Y[e];o.prototype[e]=function(){var e=t.apply(this.__wrapped__,arguments);return new o(e)}}),typeof define=="function"&&typeof define.amd=="object"&&define.amd?(e._=o,define(function(){return o})):K?"object"==typeof module&&module&&module.exports==K?(module.exports=o)._=o:K._=o:e._=o})(this);
|
||||
i++)r+="i='"+e.j[i]+"';if(","constructor"==e.j[i]&&(r+="!(f&&f.prototype===l)&&"),r+="h.call(l,i)){"+e.g+"}"}if(e.b||e.h)r+="}";return r+=e.c+";return t",s("e,h,j,k,p,n,s","return function("+t+"){"+r+"}")(c,xt,g,k,tn,_t,Nt)}function p(e){return"\\"+nn[e]}function d(e){return cn[e]}function v(){}function m(e){return hn[e]}function g(e){return kt.call(e)==Bt}function y(e){var t=i;if(!e||"object"!=typeof e||g(e))return t;var n=e.constructor;return(!Qt||"function"==typeof e.toString||"string"!=typeof
|
||||
(e+""))&&(!T(n)||n instanceof n)?Xt?(fn(e,function(e,n,r){return t=!xt.call(r,n),i}),t===i):(fn(e,function(e,n){t=n}),t===i||xt.call(e,t)):t}function b(e){var t=[];return ln(e,function(e,n){t.push(n)}),t}function w(e,t,n,s,o){if(e==r)return e;n&&(t=i);if(n=N(e)){var u=kt.call(e);if(!en[u]||Jt&&g(e))return e;var a=u==jt,n=a||(u==Rt?vn(e):n)}if(!n||!t)return n?a?Ct.call(e):an({},e):e;n=e.constructor;switch(u){case Ft:case It:return new n(+e);case qt:case zt:return new n(e);case Ut:return n(e.source
|
||||
,lt.exec(e))}s||(s=[]),o||(o=[]);for(u=s.length;u--;)if(s[u]==e)return o[u];var f=a?n(e.length):{};return s.push(e),o.push(f),(a?gn:ln)(e,function(e,n){f[n]=w(e,t,r,s,o)}),f}function E(e){var t=[];return fn(e,function(e,n){T(e)&&t.push(n)}),t.sort()}function S(e){var t={};return ln(e,function(e,n){t[e]=n}),t}function x(e,t,s,o){if(e===t)return 0!==e||1/e==1/t;if(e==r||t==r)return e===t;var u=kt.call(e);if(u!=kt.call(t))return i;switch(u){case Ft:case It:return+e==+t;case qt:return e!=+e?t!=+t:0==
|
||||
e?1/e==1/t:e==+t;case Ut:case zt:return e==t+""}var a=u==jt||u==Bt;if(Jt&&!a&&(a=g(e))&&!g(t))return i;if(!a){if(e.__wrapped__||t.__wrapped__)return x(e.__wrapped__||e,t.__wrapped__||t);if(u!=Rt||Qt&&("function"!=typeof e.toString&&"string"==typeof (e+"")||"function"!=typeof t.toString&&"string"==typeof (t+"")))return i;var u=e.constructor,f=t.constructor;if(u!=f&&(!T(u)||!(u instanceof u&&T(f)&&f instanceof f)))return i}s||(s=[]),o||(o=[]);for(u=s.length;u--;)if(s[u]==e)return o[u]==t;var u=-1,f=
|
||||
n,l=0;s.push(e),o.push(t);if(a){l=e.length;if(f=l==t.length)for(;l--&&(f=x(e[l],t[l],s,o)););return f}for(var c in e)if(xt.call(e,c)&&(l++,!xt.call(t,c)||!x(e[c],t[c],s,o)))return i;for(c in t)if(xt.call(t,c)&&!(l--))return i;if(Wt)for(;7>++u;)if(c=yt[u],xt.call(e,c)&&(!xt.call(t,c)||!x(e[c],t[c],s,o)))return i;return n}function T(e){return"function"==typeof e}function N(e){return e?tn[typeof e]:i}function C(e){return"number"==typeof e||kt.call(e)==qt}function k(e){return"string"==typeof e||kt.call
|
||||
(e)==zt}function L(e,t,n){var i=arguments,s=0,o=2,u=i[3],a=i[4];n!==nt&&(u=[],a=[],"number"!=typeof n&&(o=i.length));for(;++s<o;)ln(i[s],function(t,n){var i,s,o;if(t&&((s=dn(t))||vn(t))){for(var f=u.length;f--;)if(i=u[f]==t)break;i?e[n]=a[f]:(u.push(t),a.push(o=(o=e[n],s)?dn(o)?o:[]:vn(o)?o:{}),e[n]=L(o,t,nt,u,a))}else t!=r&&(e[n]=t)});return e}function A(e){var t=[];return ln(e,function(e){t.push(e)}),t}function O(e,t,n){var r=-1,s=e?e.length:0,o=i,n=(0>n?Dt(0,s+n):n)||0;return"number"==typeof s?
|
||||
o=-1<(k(e)?e.indexOf(t,n):U(e,t,n)):gn(e,function(e){if(++r>=n)return!(o=e===t)}),o}function M(e,t,r){var i=n,t=c(t,r);if(dn(e))for(var r=-1,s=e.length;++r<s&&(i=!!t(e[r],r,e)););else gn(e,function(e,n,r){return i=!!t(e,n,r)});return i}function _(e,t,n){var r=[],t=c(t,n);if(dn(e))for(var n=-1,i=e.length;++n<i;){var s=e[n];t(s,n,e)&&r.push(s)}else gn(e,function(e,n,i){t(e,n,i)&&r.push(e)});return r}function D(e,t,n){var r,t=c(t,n);return gn(e,function(e,n,s){if(t(e,n,s))return r=e,i}),r}function P
|
||||
(e,t,n){var r=-1,i=e?e.length:0,s=Array("number"==typeof i?i:0),t=c(t,n);if(dn(e))for(;++r<i;)s[r]=t(e[r],r,e);else gn(e,function(e,n,i){s[++r]=t(e,n,i)});return s}function H(e,t,n){var r=-Infinity,i=-1,s=e?e.length:0,o=r;if(t||!dn(e))t=!t&&k(e)?a:c(t,n),gn(e,function(e,n,i){n=t(e,n,i),n>r&&(r=n,o=e)});else for(;++i<s;)e[i]>o&&(o=e[i]);return o}function B(e,t){var n=[];return gn(e,function(e){n.push(e[t])}),n}function j(e,t,n,r){var s=3>arguments.length;return t||(t=$),gn(e,function(e,o,u){n=s?(s=
|
||||
i,e):t.call(r,n,e,o,u)}),n}function F(e,t,n,r){var s=e,o=e?e.length:0,u=3>arguments.length;if("number"!=typeof o)var a=mn(e),o=a.length;else Kt&&k(e)&&(s=e.split(""));return t||(t=$),gn(e,function(e,f,l){f=a?a[--o]:--o,n=u?(u=i,s[f]):t.call(r,n,s[f],f,l)}),n}function I(e,t,n){var r,t=c(t,n);if(dn(e))for(var n=-1,i=e.length;++n<i&&!(r=t(e[n],n,e)););else gn(e,function(e,n,i){return!(r=t(e,n,i))});return!!r}function q(e,t,n){if(e)return t==r||n?e[0]:Ct.call(e,0,t)}function R(e,t){for(var n=-1,r=e?e
|
||||
.length:0,i=[];++n<r;){var s=e[n];dn(s)?Tt.apply(i,t?s:R(s)):i.push(s)}return i}function U(e,t,n){var r=-1,i=e?e.length:0;if("number"==typeof n)r=(0>n?Dt(0,i+n):n||0)-1;else if(n)return r=W(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function z(e,t,n){return e?Ct.call(e,t==r||n?1:t):[]}function W(e,t,n,r){for(var i=0,s=e?e.length:i,n=n?c(n,r):$,t=n(t);i<s;)r=i+s>>>1,n(e[r])<t?i=r+1:s=r;return i}function X(e,t,n,r){var s=-1,o=e?e.length:0,u=[],a=u;"function"==typeof t&&(r=n,n=t,t=
|
||||
i);var f=!t&&74<o;if(f)var l={};n&&(a=[],n=c(n,r));for(;++s<o;){var r=e[s],h=n?n(r,s,e):r;f&&(a=xt.call(l,h+"")?l[h]:l[h]=[]);if(t?!s||a[a.length-1]!==h:0>U(a,h))(n||f)&&a.push(h),u.push(r)}return u}function V(e,t){return Yt||Lt&&2<arguments.length?Lt.call.apply(Lt,arguments):l(e,t,Ct.call(arguments,2))}function $(e){return e}function J(e){gn(E(e),function(t){var n=o[t]=e[t];o.prototype[t]=function(){var e=[this.__wrapped__];return Tt.apply(e,arguments),e=n.apply(o,e),new o(e)}})}function K(){return this
|
||||
.__wrapped__}var n=!0,r=null,i=!1,Q="object"==typeof exports&&exports,G="object"==typeof global&&global;G.global===G&&(e=G);var Y=e.document,Z=[],et=new function(){},tt=0,nt=et,rt=30,it=e._,st=/[-?+=!~*%&^<>|{(\/]|\[\D|\b(?:delete|in|instanceof|new|typeof|void)\b/,ot=/&(?:amp|lt|gt|quot|#x27);/g,ut=/\b__p\+='';/g,at=/\b(__p\+=)''\+/g,ft=/(__e\(.*?\)|\b__t\))\+'';/g,lt=/\w*$/,ct=/(?:__e|__t=)\(\s*(?![\d\s"']|this\.)/g,ht=RegExp("^"+(et.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&").replace
|
||||
(/valueOf|for [^\]]+/g,".+?")+"$"),pt=/\$\{((?:(?=\\?)\\?[\s\S])*?)}/g,dt=/<%=([\s\S]+?)%>/g,vt=/($^)/,mt=/[&<>"']/g,gt=/['\n\r\t\u2028\u2029\\]/g,yt="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" "),bt=Math.ceil,wt=Z.concat,Et=Math.floor,St=ht.test(St=Object.getPrototypeOf)&&St,xt=et.hasOwnProperty,Tt=Z.push,Nt=et.propertyIsEnumerable,Ct=Z.slice,kt=et.toString,Lt=ht.test(Lt=Ct.bind)&&Lt,At=ht.test(At=Array.isArray)&&At,Ot=e.isFinite,Mt=e.isNaN
|
||||
,_t=ht.test(_t=Object.keys)&&_t,Dt=Math.max,Pt=Math.min,Ht=Math.random,Bt="[object Arguments]",jt="[object Array]",Ft="[object Boolean]",It="[object Date]",qt="[object Number]",Rt="[object Object]",Ut="[object RegExp]",zt="[object String]",Wt,Xt,Vt=(Vt={0:1,length:1},Z.splice.call(Vt,0,1),Vt[0]),$t=n;(function(){function e(){this.x=1}var t=[];e.prototype={valueOf:1,y:1};for(var n in new e)t.push(n);for(n in arguments)$t=!n;Wt=!/valueOf/.test(t),Xt="x"!=t[0]})(1);var Jt=!g(arguments),Kt="xx"!="x"[0
|
||||
]+Object("x")[0];try{var Qt=("[object Object]",kt.call(Y||0)==Rt)}catch(Gt){}var Yt=Lt&&/\n|Opera/.test(Lt+kt.call(e.opera)),Zt=_t&&/^.+$|true/.test(_t+!!e.attachEvent),en={};en[Bt]=en["[object Function]"]=i,en[jt]=en[Ft]=en[It]=en[qt]=en[Rt]=en[Ut]=en[zt]=n;var tn={"boolean":i,"function":n,object:n,number:i,string:i,"undefined":i},nn={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};o.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate
|
||||
:dt,variable:""};try{s()}catch(rn){s=Function}var sn={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:"}}"},on={a:"d,c,w",k:"c=e(c,w)",b:"if(c(l[i],i,d)===false)return t",g:"if(c(l[i],i,d)===false)return t"},un={b:r},an=h(sn);Jt&&(g=function(e){return e?xt.call(e,"callee"):i});var fn=h(on,un,{l:i}),ln=h(on,un),cn={"&":"&","<":"<",">":">",'"':""","'":"'"},hn=S(cn),pn=h(sn,{g:"if(t[i]==null)"+sn.g}),dn=At||function(
|
||||
e){return kt.call(e)==jt};T(/x/)&&(T=function(e){return"[object Function]"==kt.call(e)});var vn=St?function(e){if(!e||"object"!=typeof e)return i;var t=e.valueOf,n="function"==typeof t&&(n=St(t))&&St(n);return n?e==n||St(e)==n&&!g(e):y(e)}:y,mn=_t?function(e){return"function"==typeof e&&Nt.call(e,"prototype")?b(e):N(e)?_t(e):[]}:b,gn=h(on);o.VERSION="0.10.0",o.assign=an,o.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},o.bind=V,o.bindAll=function(e){for(var t=
|
||||
arguments,n=1<t.length?0:(t=E(e),-1),r=t.length;++n<r;){var i=t[n];e[i]=V(e[i],e)}return e},o.bindKey=function(e,t){return l(e,t,Ct.call(arguments,2))},o.chain=function(e){return new o(e)},o.clone=w,o.compact=function(e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r},o.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},o.contains=O,o.countBy=function(e,t,n){var r={},t=c(t,n);return gn(e,function(
|
||||
e,n,i){n=t(e,n,i),xt.call(r,n)?r[n]++:r[n]=1}),r},o.debounce=function(e,t,n){function i(){a=r,n||(o=e.apply(u,s))}var s,o,u,a;return function(){var r=n&&!a;return s=arguments,u=this,clearTimeout(a),a=setTimeout(i,t),r&&(o=e.apply(u,s)),o}},o.defaults=pn,o.defer=function(e){var n=Ct.call(arguments,1);return setTimeout(function(){e.apply(t,n)},1)},o.delay=function(e,n){var r=Ct.call(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},o.difference=function(e){for(var t=-1,n=e?e.length:0,r=wt
|
||||
.apply(Z,arguments),r=u(r,n),i=[];++t<n;){var s=e[t];r(s)||i.push(s)}return i},o.escape=function(e){return e==r?"":(e+"").replace(mt,d)},o.every=M,o.filter=_,o.find=D,o.first=q,o.flatten=R,o.forEach=gn,o.forIn=fn,o.forOwn=ln,o.functions=E,o.groupBy=function(e,t,n){var r={},t=c(t,n);return gn(e,function(e,n,i){n=t(e,n,i),(xt.call(r,n)?r[n]:r[n]=[]).push(e)}),r},o.has=function(e,t){return e?xt.call(e,t):i},o.identity=$,o.indexOf=U,o.initial=function(e,t,n){return e?Ct.call(e,0,-(t==r||n?1:t)):[]},o
|
||||
.intersection=function(e){var t=arguments,n=t.length,r={},i=[];return gn(e,function(e){if(0>U(i,e)){for(var s=n;--s;)if(!(r[s]||(r[s]=u(t[s])))(e))return;i.push(e)}}),i},o.invert=S,o.invoke=function(e,t){var n=Ct.call(arguments,2),r="function"==typeof t,i=[];return gn(e,function(e){i.push((r?t:e[t]).apply(e,n))}),i},o.isArguments=g,o.isArray=dn,o.isBoolean=function(e){return e===n||e===i||kt.call(e)==Ft},o.isDate=function(e){return kt.call(e)==It},o.isElement=function(e){return e?1===e.nodeType:i
|
||||
},o.isEmpty=function(e){var t=n;if(!e)return t;var r=kt.call(e),s=e.length;return r==jt||r==zt||r==Bt||Jt&&g(e)||r==Rt&&"number"==typeof s&&T(e.splice)?!s:(ln(e,function(){return t=i}),t)},o.isEqual=x,o.isFinite=function(e){return Ot(e)&&!Mt(parseFloat(e))},o.isFunction=T,o.isNaN=function(e){return C(e)&&e!=+e},o.isNull=function(e){return e===r},o.isNumber=C,o.isObject=N,o.isPlainObject=vn,o.isRegExp=function(e){return kt.call(e)==Ut},o.isString=k,o.isUndefined=function(e){return e===t},o.keys=mn
|
||||
,o.last=function(e,t,n){if(e){var i=e.length;return t==r||n?e[i-1]:Ct.call(e,-t||i)}},o.lastIndexOf=function(e,t,n){var r=e?e.length:0;for("number"==typeof n&&(r=(0>n?Dt(0,r+n):Pt(n,r-1))+1);r--;)if(e[r]===t)return r;return-1},o.map=P,o.max=H,o.memoize=function(e,t){var n={};return function(){var r=t?t.apply(this,arguments):arguments[0];return xt.call(n,r)?n[r]:n[r]=e.apply(this,arguments)}},o.merge=L,o.min=function(e,t,n){var r=Infinity,i=-1,s=e?e.length:0,o=r;if(t||!dn(e))t=!t&&k(e)?a:c(t,n),gn
|
||||
(e,function(e,n,i){n=t(e,n,i),n<r&&(r=n,o=e)});else for(;++i<s;)e[i]<o&&(o=e[i]);return o},o.mixin=J,o.noConflict=function(){return e._=it,this},o.object=function(e,t){for(var n=-1,r=e?e.length:0,i={};++n<r;){var s=e[n];t?i[s]=t[n]:i[s[0]]=s[1]}return i},o.omit=function(e,t,n){var r="function"==typeof t,i={};if(r)t=c(t,n);else var s=wt.apply(Z,arguments);return fn(e,function(e,n,o){if(r?!t(e,n,o):0>U(s,n,1))i[n]=e}),i},o.once=function(e){var t,s=i;return function(){return s?t:(s=n,t=e.apply(this,
|
||||
arguments),e=r,t)}},o.pairs=function(e){var t=[];return ln(e,function(e,n){t.push([n,e])}),t},o.partial=function(e){return l(e,Ct.call(arguments,1))},o.pick=function(e,t,n){var r={};if("function"!=typeof t)for(var i=0,s=wt.apply(Z,arguments),o=s.length;++i<o;){var u=s[i];u in e&&(r[u]=e[u])}else t=c(t,n),fn(e,function(e,n,i){t(e,n,i)&&(r[n]=e)});return r},o.pluck=B,o.random=function(e,t){return e==r&&t==r&&(t=1),e=+e||0,t==r&&(t=e,e=0),e+Et(Ht()*((+t||0)-e+1))},o.range=function(e,t,n){e=+e||0,n=+
|
||||
n||1,t==r&&(t=e,e=0);for(var i=-1,t=Dt(0,bt((t-e)/n)),s=Array(t);++i<t;)s[i]=e,e+=n;return s},o.reduce=j,o.reduceRight=F,o.reject=function(e,t,n){return t=c(t,n),_(e,function(e,n,r){return!t(e,n,r)})},o.rest=z,o.result=function(e,t){var n=e?e[t]:r;return T(n)?e[t]():n},o.shuffle=function(e){var t=-1,n=Array(e?e.length:0);return gn(e,function(e){var r=Et(Ht()*(++t+1));n[t]=n[r],n[r]=e}),n},o.size=function(e){var t=e?e.length:0;return"number"==typeof t?t:mn(e).length},o.some=I,o.sortBy=function(e,t
|
||||
,n){var r=[],t=c(t,n);gn(e,function(e,n,i){r.push({a:t(e,n,i),b:n,c:e})}),e=r.length;for(r.sort(f);e--;)r[e]=r[e].c;return r},o.sortedIndex=W,o.tap=function(e,t){return t(e),e},o.template=function(e,t,n){e||(e=""),n||(n={});var r,i,u=o.templateSettings,a=0,f=n.interpolate||u.interpolate||vt,l="__p+='",c=n.variable||u.variable,h=c;e.replace(RegExp((n.escape||u.escape||vt).source+"|"+f.source+"|"+(f===dt?pt:vt).source+"|"+(n.evaluate||u.evaluate||vt).source+"|$","g"),function(t,n,i,s,o,u){i||(i=s),
|
||||
l+=e.slice(a,u).replace(gt,p),l+=n?"'+__e("+n+")+'":o?"';"+o+";__p+='":i?"'+((__t=("+i+"))==null?'':__t)+'":"",r||(r=o||st.test(n||i)),a=u+t.length}),l+="';\n",h||(c="obj",r?l="with("+c+"){"+l+"}":(n=RegExp("(\\(\\s*)"+c+"\\."+c+"\\b","g"),l=l.replace(ct,"$&"+c+".").replace(n,"$1__d"))),l=(r?l.replace(ut,""):l).replace(at,"$1").replace(ft,"$1;"),l="function("+c+"){"+(h?"":c+"||("+c+"={});")+"var __t,__p='',__e=_.escape"+(r?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":
|
||||
(h?"":",__d="+c+"."+c+"||"+c)+";")+l+"return __p}";try{i=s("_","return "+l)(o)}catch(d){throw d.source=l,d}return t?i(t):(i.source=l,i)},o.throttle=function(e,t){function n(){a=new Date,u=r,s=e.apply(o,i)}var i,s,o,u,a=0;return function(){var r=new Date,f=t-(r-a);return i=arguments,o=this,0>=f?(clearTimeout(u),a=r,s=e.apply(o,i)):u||(u=setTimeout(n,f)),s}},o.times=function(e,t,n){for(var e=+e||0,r=-1,i=Array(e);++r<e;)i[r]=t.call(n,r);return i},o.toArray=function(e){var t=e?e.length:0;if("number"==typeof
|
||||
t){Kt&&k(e)&&(e=e.split(""));for(var n=-1,r=Array(t);++n<t;)r[n]=e[n];return r}return A(e)},o.unescape=function(e){return e==r?"":(e+"").replace(ot,m)},o.union=function(){return X(wt.apply(Z,arguments))},o.uniq=X,o.uniqueId=function(e){var t=tt++;return e?e+t:t},o.values=A,o.where=function(e,t){var n=mn(t);return _(e,function(e){for(var r=n.length;r--;){var i=e[n[r]]===t[n[r]];if(!i)break}return!!i})},o.without=function(e){for(var t=-1,n=e?e.length:0,r=u(arguments,1,20),i=[];++t<n;){var s=e[t];r(
|
||||
s)||i.push(s)}return i},o.wrap=function(e,t){return function(){var n=[e];return Tt.apply(n,arguments),t.apply(this,n)}},o.zip=function(e){for(var t=-1,n=e?H(B(arguments,"length")):0,r=Array(n);++t<n;)r[t]=B(arguments,t);return r},o.all=M,o.any=I,o.collect=P,o.detect=D,o.drop=z,o.each=gn,o.extend=an,o.foldl=j,o.foldr=F,o.head=q,o.include=O,o.inject=j,o.methods=E,o.select=_,o.tail=z,o.take=q,o.unique=X,J(o),o.prototype.chain=function(){return this},o.prototype.toString=function(){return""+this.__wrapped__
|
||||
},o.prototype.value=K,o.prototype.valueOf=K,gn(["first","last"],function(e){var t=o[e];t&&(o.prototype[e]=function(e,n){var i=t(this.__wrapped__,e,n);return e==r||n?i:new o(i)})}),gn(_(E(o),function(e){return/^(?:contains|every|find|has|is[A-Z].+|reduce.*|some)$/.test(e)}),function(e){var t=o[e];o.prototype[e]=function(){var e=[this.__wrapped__];return Tt.apply(e,arguments),t.apply(o,e)}}),gn("pop push reverse shift sort splice unshift".split(" "),function(e){var t=Z[e];o.prototype[e]=function(){
|
||||
var e=this.__wrapped__;return t.apply(e,arguments),Vt&&e.length===0&&delete e[0],this}}),gn(["concat","join","slice"],function(e){var t=Z[e];o.prototype[e]=function(){var e=t.apply(this.__wrapped__,arguments);return new o(e)}}),typeof define=="function"&&typeof define.amd=="object"&&define.amd?(e._=o,define(function(){return o})):Q?"object"==typeof module&&module&&module.exports==Q?(module.exports=o)._=o:Q._=o:e._=o})(this);
|
||||
54
lodash.underscore.min.js
vendored
54
lodash.underscore.min.js
vendored
@@ -3,30 +3,30 @@
|
||||
Build: `lodash underscore -m -o ./lodash.underscore.min.js`
|
||||
Underscore.js 1.4.2 underscorejs.org/LICENSE
|
||||
*/
|
||||
;(function(e,t){function n(e){if(e&&"object"==typeof e&&e.__wrapped__)return e;if(!(this instanceof n))return new n(e);this.__wrapped__=e}function r(e,n){var r=e.b,i=n.b,e=e.a,n=n.a;if(e!==n){if(e>n||e===t)return 1;if(e<n||n===t)return-1}return r<i?-1:1}function i(e,t,n){function r(){var i=arguments,s=t;return n.length&&(i=i.length?n.concat(tt.call(i)):n),this instanceof r?(a.prototype=e.prototype,s=new a,i=e.apply(s,i),g(i)?i:s):e.apply(s,i)}return r}function s(e,n){return e?"function"!=typeof e?
|
||||
function(t){return t[e]}:n!==t?function(t,r,i){return e.call(n,t,r,i)}:e:j}function o(e){return"\\"+wt[e]}function u(e){return xt[e]}function a(){}function f(e){return Tt[e]}function l(e){if(!e)return e;for(var t=1,n=arguments.length;t<n;t++){var r=arguments[t];if(r)for(var i in r)e[i]=r[i]}return e}function c(e){var t=[];return St(e,function(e,n){t.push(n)}),t}function h(e){if(!e)return e;for(var t=1,n=arguments.length;t<n;t++){var r=arguments[t];if(r)for(var i in r)null==e[i]&&(e[i]=r[i])}return e
|
||||
}function p(e){var t=[];return Et(e,function(e,n){m(e)&&t.push(n)}),t.sort()}function d(e){var t={};return St(e,function(e,n){t[e]=n}),t}function v(e,t,n,r){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return e===t;var i=nt.call(e);if(i!=nt.call(t))return!1;switch(i){case ct:case ht:return+e==+t;case pt:return e!=+e?t!=+t:0==e?1/e==1/t:e==+t;case vt:case mt:return e==t+""}var s=i==lt;if(!s){if(e.__wrapped__||t.__wrapped__)return v(e.__wrapped__||e,t.__wrapped__||t);if(i!=dt)return!1;var i=
|
||||
e.constructor,o=t.constructor;if(i!=o&&(!m(i)||!(i instanceof i&&m(o)&&o instanceof o)))return!1}n||(n=[]),r||(r=[]);for(i=n.length;i--;)if(n[i]==e)return r[i]==t;i=!0,o=0,n.push(e),r.push(t);if(s){o=e.length;if(i=o==t.length)for(;o--&&(i=v(e[o],t[o],n,r)););return i}for(var u in e)if(Z.call(e,u)&&(o++,!Z.call(t,u)||!v(e[u],t[u],n,r)))return!1;for(u in t)if(Z.call(t,u)&&!(o--))return!1;return!0}function m(e){return"function"==typeof e}function g(e){return e?bt[typeof e]:!1}function y(e){return nt
|
||||
.call(e)==mt}function b(e){var t=[];return St(e,function(e){t.push(e)}),t}function w(e,t){var n=!1;return"number"==typeof (e?e.length:0)?n=-1<_(e,t):kt(e,function(e){return(n=e===t)&&z}),n}function E(e,t,n){var r=!0,t=s(t,n);if(Nt(e))for(var n=-1,i=e.length;++n<i&&(r=!!t(e[n],n,e)););else kt(e,function(e,n,i){return!(r=!!t(e,n,i))&&z});return r}function S(e,t,n){var r=[],t=s(t,n);if(Nt(e))for(var n=-1,i=e.length;++n<i;){var o=e[n];t(o,n,e)&&r.push(o)}else kt(e,function(e,n,i){t(e,n,i)&&r.push(e)}
|
||||
);return r}function x(e,t,n){var r,t=s(t,n);return kt(e,function(e,n,i){if(t(e,n,i))return r=e,z}),r}function T(e,t,n){var r=-1,i=e?e.length:0,o=Array("number"==typeof i?i:0),t=s(t,n);if(Nt(e))for(;++r<i;)o[r]=t(e[r],r,e);else kt(e,function(e,n,i){o[++r]=t(e,n,i)});return o}function N(e,t,n){var r=-Infinity,i=-1,o=e?e.length:0,u=r;if(t||!Nt(e))t=s(t,n),kt(e,function(e,n,i){n=t(e,n,i),n>r&&(r=n,u=e)});else for(;++i<o;)e[i]>u&&(u=e[i]);return u}function C(e,t){var n=[];return kt(e,function(e){n.push
|
||||
(e[t])}),n}function k(e,t,n,r){var i=3>arguments.length;return t||(t=j),kt(e,function(e,s,o){n=i?(i=!1,e):t.call(r,n,e,s,o)}),n}function L(e,t,n,r){var i=e?e.length:0,s=3>arguments.length;if("number"!=typeof i)var o=Ct(e),i=o.length;return t||(t=j),kt(e,function(u,a,f){a=o?o[--i]:--i,n=s?(s=!1,e[a]):t.call(r,n,e[a],a,f)}),n}function A(e,t,n){var r,t=s(t,n);if(Nt(e))for(var n=-1,i=e.length;++n<i&&!(r=t(e[n],n,e)););else kt(e,function(e,n,i){return(r=t(e,n,i))&&z});return!!r}function O(e,t,n){if(e)
|
||||
return null==t||n?e[0]:tt.call(e,0,t)}function M(e,t){for(var n=-1,r=e?e.length:0,i=[];++n<r;){var s=e[n];Nt(s)?et.apply(i,t?s:M(s)):i.push(s)}return i}function _(e,t,n){var r=-1,i=e?e.length:0;if("number"==typeof n)r=(0>n?ut(0,i+n):n||0)-1;else if(n)return r=P(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function D(e,t,n){return e?tt.call(e,null==t||n?1:t):[]}function P(e,t,n,r){for(var i=0,o=e?e.length:i,n=n?s(n,r):j,t=n(t);i<o;)r=i+o>>>1,n(e[r])<t?i=r+1:o=r;return i}function H(
|
||||
e,t,n,r){var i=-1,o=e?e.length:0,u=[],a=u;n&&(a=[],n=s(n,r));for(;++i<o;){var r=e[i],f=n?n(r,i,e):r;if(t?!i||a[a.length-1]!==f:0>_(a,f))n&&a.push(f),u.push(r)}return u}function B(e,t){return yt||rt&&2<arguments.length?rt.call.apply(rt,arguments):i(e,t,tt.call(arguments,2))}function j(e){return e}function F(e){kt(p(e),function(t){var r=n[t]=e[t];n.prototype[t]=function(){var e=[this.__wrapped__];return et.apply(e,arguments),e=r.apply(n,e),this.__chain__&&(e=new n(e),e.__chain__=!0),e}})}var I="object"==typeof
|
||||
exports&&exports,q="object"==typeof global&&global;q.global===q&&(e=q);var R=[],q=new function(){},U=0,z=q,W=e._,X=/&(?:amp|lt|gt|quot|#x27);/g,V=RegExp("^"+(q.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&").replace(/valueOf|for [^\]]+/g,".+?")+"$"),$=/($^)/,J=/[&<>"']/g,K=/['\n\r\t\u2028\u2029\\]/g,Q=Math.ceil,G=R.concat,Y=Math.floor,Z=q.hasOwnProperty,et=R.push,tt=R.slice,nt=q.toString,rt=V.test(rt=tt.bind)&&rt,it=V.test(it=Array.isArray)&&it,st=e.isFinite,ot=V.test(ot=Object.keys)&&ot,ut=
|
||||
Math.max,at=Math.min,ft=Math.random,lt="[object Array]",ct="[object Boolean]",ht="[object Date]",pt="[object Number]",dt="[object Object]",vt="[object RegExp]",mt="[object String]",gt=(gt={0:1,length:1},R.splice.call(gt,0,1),gt[0]),yt=rt&&/\n|Opera/.test(rt+nt.call(e.opera)),bt={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,"undefined":!1},wt={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};n.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g
|
||||
,interpolate:/<%=([\s\S]+?)%>/g,variable:""},n.isArguments=function(e){return"[object Arguments]"==nt.call(e)},n.isArguments(arguments)||(n.isArguments=function(e){return e?Z.call(e,"callee"):!1});var Et=function(e,t){var n;if(!e)return e;t=s(t);for(n in e)if(t(e[n],n,e)===z)break;return e},St=function(e,t){var n;if(!e)return e;t=s(t);for(n in e)if(Z.call(e,n)&&t(e[n],n,e)===z)break;return e},xt={"&":"&","<":"<",">":">",'"':""","'":"'"},Tt=d(xt),Nt=it||function(e){return nt.call
|
||||
(e)==lt};m(/x/)&&(m=function(e){return"[object Function]"==nt.call(e)});var Ct=ot?function(e){return g(e)?ot(e):[]}:c,kt=function(e,t,n){if(!e)return e;var t=s(t,n),r=e.length,n=-1;if("number"==typeof r){for(;++n<r;)if(t(e[n],n,e)===z)return e}else for(n in e)if(Z.call(e,n)&&t(e[n],n,e)===z)return e};n.VERSION="0.10.0",n.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},n.bind=B,n.bindAll=function(e){for(var t=arguments,n=1<t.length?0:(t=p(e),-1),r=t.length;++
|
||||
n<r;){var i=t[n];e[i]=B(e[i],e)}return e},n.chain=function(e){return e=new n(e),e.__chain__=!0,e},n.clone=function(e){return e&&bt[typeof e]?Nt(e)?tt.call(e):l({},e):e},n.compact=function(e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r},n.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},n.contains=w,n.countBy=function(e,t,n){var r={},t=s(t,n);return kt(e,function(e,n,i){n=t(e,n,i),Z.call(r,n)?
|
||||
r[n]++:r[n]=1}),r},n.debounce=function(e,t,n){function r(){u=null,n||(s=e.apply(o,i))}var i,s,o,u;return function(){var a=n&&!u;return i=arguments,o=this,clearTimeout(u),u=setTimeout(r,t),a&&(s=e.apply(o,i)),s}},n.defaults=h,n.defer=function(e){var n=tt.call(arguments,1);return setTimeout(function(){e.apply(t,n)},1)},n.delay=function(e,n){var r=tt.call(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},n.difference=function(e){for(var t=-1,n=e.length,r=G.apply(R,arguments),i=[];++t<n;){var s=
|
||||
e[t];0>_(r,s,n)&&i.push(s)}return i},n.escape=function(e){return null==e?"":(e+"").replace(J,u)},n.every=E,n.filter=S,n.find=x,n.first=O,n.flatten=M,n.forEach=kt,n.functions=p,n.groupBy=function(e,t,n){var r={},t=s(t,n);return kt(e,function(e,n,i){n=t(e,n,i),(Z.call(r,n)?r[n]:r[n]=[]).push(e)}),r},n.has=function(e,t){return e?Z.call(e,t):!1},n.identity=j,n.indexOf=_,n.initial=function(e,t,n){return e?tt.call(e,0,-(null==t||n?1:t)):[]},n.intersection=function(e){var t=arguments,n=t.length,r=[];return kt
|
||||
(e,function(e){if(0>_(r,e)){for(var i=n;--i;)if(0>_(t[i],e))return;r.push(e)}}),r},n.invert=d,n.invoke=function(e,t){var n=tt.call(arguments,2),r="function"==typeof t,i=[];return kt(e,function(e){i.push((r?t:e[t]).apply(e,n))}),i},n.isArray=Nt,n.isBoolean=function(e){return!0===e||!1===e||nt.call(e)==ct},n.isDate=function(e){return nt.call(e)==ht},n.isElement=function(e){return e?1===e.nodeType:!1},n.isEmpty=function(e){if(!e)return!0;if(Nt(e)||y(e))return!e.length;for(var t in e)if(Z.call(e,t))return!1
|
||||
;return!0},n.isEqual=v,n.isFinite=function(e){return st(e)&&nt.call(e)==pt},n.isFunction=m,n.isNaN=function(e){return nt.call(e)==pt&&e!=+e},n.isNull=function(e){return null===e},n.isNumber=function(e){return nt.call(e)==pt},n.isObject=g,n.isRegExp=function(e){return nt.call(e)==vt},n.isString=y,n.isUndefined=function(e){return e===t},n.keys=Ct,n.last=function(e,t,n){if(e){var r=e.length;return null==t||n?e[r-1]:tt.call(e,-t||r)}},n.lastIndexOf=function(e,t,n){var r=e?e.length:0;for("number"==typeof
|
||||
n&&(r=(0>n?ut(0,r+n):at(n,r-1))+1);r--;)if(e[r]===t)return r;return-1},n.map=T,n.max=N,n.memoize=function(e,t){var n={};return function(){var r=t?t.apply(this,arguments):arguments[0];return Z.call(n,r)?n[r]:n[r]=e.apply(this,arguments)}},n.min=function(e,t,n){var r=Infinity,i=-1,o=e?e.length:0,u=r;if(t||!Nt(e))t=s(t,n),kt(e,function(e,n,i){n=t(e,n,i),n<r&&(r=n,u=e)});else for(;++i<o;)e[i]<u&&(u=e[i]);return u},n.mixin=F,n.noConflict=function(){return e._=W,this},n.object=function(e,t){for(var n=-1
|
||||
,r=e?e.length:0,i={};++n<r;){var s=e[n];t?i[s]=t[n]:i[s[0]]=s[1]}return i},n.omit=function(e){var t=G.apply(R,arguments),n={};return Et(e,function(e,r){0>_(t,r,1)&&(n[r]=e)}),n},n.once=function(e){var t,n=!1;return function(){return n?t:(n=!0,t=e.apply(this,arguments),e=null,t)}},n.pairs=function(e){var t=[];return St(e,function(e,n){t.push([n,e])}),t},n.pick=function(e){for(var t=0,n=G.apply(R,arguments),r=n.length,i={};++t<r;){var s=n[t];s in e&&(i[s]=e[s])}return i},n.pluck=C,n.random=function(
|
||||
e,t){return null==e&&null==t&&(t=1),e=+e||0,null==t&&(t=e,e=0),e+Y(ft()*((+t||0)-e+1))},n.range=function(e,t,n){e=+e||0,n=+n||1,null==t&&(t=e,e=0);for(var r=-1,t=ut(0,Q((t-e)/n)),i=Array(t);++r<t;)i[r]=e,e+=n;return i},n.reduce=k,n.reduceRight=L,n.reject=function(e,t,n){return t=s(t,n),S(e,function(e,n,r){return!t(e,n,r)})},n.rest=D,n.result=function(e,t){var n=e?e[t]:null;return m(n)?e[t]():n},n.shuffle=function(e){var t=-1,n=Array(e?e.length:0);return kt(e,function(e){var r=Y(ft()*(++t+1));n[t]=
|
||||
n[r],n[r]=e}),n},n.size=function(e){var t=e?e.length:0;return"number"==typeof t?t:Ct(e).length},n.some=A,n.sortBy=function(e,t,n){var i=[],t=s(t,n);kt(e,function(e,n,r){i.push({a:t(e,n,r),b:n,c:e})}),e=i.length;for(i.sort(r);e--;)i[e]=i[e].c;return i},n.sortedIndex=P,n.tap=function(e,t){return t(e),e},n.template=function(e,t,r){e||(e="");var r=h({},r,n.templateSettings),i=0,s="__p+='",u=r.variable;e.replace(RegExp((r.escape||$).source+"|"+(r.interpolate||$).source+"|"+(r.evaluate||$).source+"|$","g"
|
||||
),function(t,n,r,u,a){s+=e.slice(i,a).replace(K,o),s+=n?"'+_['escape']("+n+")+'":u?"';"+u+";__p+='":r?"'+((__t=("+r+"))==null?'':__t)+'":"",i=a+t.length}),s+="';\n",u||(u="obj",s="with("+u+"||{}){"+s+"}"),s="function("+u+"){var __t,__p='',__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}"+s+"return __p}";try{var a=Function("_","return "+s)(n)}catch(f){throw f.source=s,f}return t?a(t):(a.source=s,a)},n.throttle=function(e,t){function n(){u=new Date,o=null,i=e.apply(s,r)}var r,
|
||||
i,s,o,u=0;return function(){var a=new Date,f=t-(a-u);return r=arguments,s=this,0>=f?(clearTimeout(o),u=a,i=e.apply(s,r)):o||(o=setTimeout(n,f)),i}},n.times=function(e,t,n){for(var e=+e||0,r=-1,i=Array(e);++r<e;)i[r]=t.call(n,r);return i},n.toArray=function(e){var t=e?e.length:0;if("number"==typeof t){for(var n=-1,r=Array(t);++n<t;)r[n]=e[n];return r}return b(e)},n.unescape=function(e){return null==e?"":(e+"").replace(X,f)},n.union=function(){return H(G.apply(R,arguments))},n.uniq=H,n.uniqueId=function(
|
||||
e){var t=U++;return e?e+t:t},n.values=b,n.where=function(e,t){var n=Ct(t);return S(e,function(e){for(var r=n.length;r--;){var i=e[n[r]]===t[n[r]];if(!i)break}return!!i})},n.without=function(e){for(var t=-1,n=e.length,r=[];++t<n;){var i=e[t];0>_(arguments,i,1)&&r.push(i)}return r},n.wrap=function(e,t){return function(){var n=[e];return et.apply(n,arguments),t.apply(this,n)}},n.zip=function(e){for(var t=-1,n=e?N(C(arguments,"length")):0,r=Array(n);++t<n;)r[t]=C(arguments,t);return r},n.all=E,n.any=
|
||||
A,n.collect=T,n.detect=x,n.drop=D,n.each=kt,n.extend=l,n.foldl=k,n.foldr=L,n.head=O,n.include=w,n.inject=k,n.methods=p,n.select=S,n.tail=D,n.take=O,n.unique=H,F(n),n.prototype.chain=function(){return this.__chain__=!0,this},n.prototype.value=function(){return this.__wrapped__},kt("pop push reverse shift sort splice unshift".split(" "),function(e){var t=R[e];n.prototype[e]=function(){var e=this.__wrapped__;return t.apply(e,arguments),gt&&e.length===0&&delete e[0],this}}),kt(["concat","join","slice"
|
||||
],function(e){var t=R[e];n.prototype[e]=function(){var e=t.apply(this.__wrapped__,arguments);return this.__chain__&&(e=new n(e),e.__chain__=!0),e}}),I?"object"==typeof module&&module&&module.exports==I?(module.exports=n)._=n:I._=n:e._=n})(this);
|
||||
;(function(e,t){function n(e){if(e&&"object"==typeof e&&e.__wrapped__)return e;if(!(this instanceof n))return new n(e);this.__wrapped__=e}function r(e,n){var r=e.b,i=n.b,e=e.a,n=n.a;if(e!==n){if(e>n||e===t)return 1;if(e<n||n===t)return-1}return r<i?-1:1}function i(e,t,n){function r(){var i=arguments,s=t;return n.length&&(i=i.length?n.concat(nt.call(i)):n),this instanceof r?(a.prototype=e.prototype,s=new a,i=e.apply(s,i),g(i)?i:s):e.apply(s,i)}return r}function s(e,n){return e?"function"!=typeof e?
|
||||
function(t){return t[e]}:n!==t?function(t,r,i){return e.call(n,t,r,i)}:e:F}function o(e){return"\\"+Et[e]}function u(e){return Tt[e]}function a(){}function f(e){return Nt[e]}function l(e){if(!e)return e;for(var t=1,n=arguments.length;t<n;t++){var r=arguments[t];if(r)for(var i in r)e[i]=r[i]}return e}function c(e){var t=[];return xt(e,function(e,n){t.push(n)}),t}function h(e){if(!e)return e;for(var t=1,n=arguments.length;t<n;t++){var r=arguments[t];if(r)for(var i in r)null==e[i]&&(e[i]=r[i])}return e
|
||||
}function p(e){var t=[];return St(e,function(e,n){m(e)&&t.push(n)}),t.sort()}function d(e){var t={};return xt(e,function(e,n){t[e]=n}),t}function v(e,t,n,r){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return e===t;var i=rt.call(e);if(i!=rt.call(t))return!1;switch(i){case ht:case pt:return+e==+t;case dt:return e!=+e?t!=+t:0==e?1/e==1/t:e==+t;case mt:case gt:return e==t+""}var s=i==ct;if(!s){if(e.__wrapped__||t.__wrapped__)return v(e.__wrapped__||e,t.__wrapped__||t);if(i!=vt)return!1;var i=
|
||||
e.constructor,o=t.constructor;if(i!=o&&(!m(i)||!(i instanceof i&&m(o)&&o instanceof o)))return!1}n||(n=[]),r||(r=[]);for(i=n.length;i--;)if(n[i]==e)return r[i]==t;i=!0,o=0,n.push(e),r.push(t);if(s){o=e.length;if(i=o==t.length)for(;o--&&(i=v(e[o],t[o],n,r)););return i}for(var u in e)if(et.call(e,u)&&(o++,!et.call(t,u)||!v(e[u],t[u],n,r)))return!1;for(u in t)if(et.call(t,u)&&!(o--))return!1;return!0}function m(e){return"function"==typeof e}function g(e){return e?wt[typeof e]:!1}function y(e){return"number"==typeof
|
||||
e||rt.call(e)==dt}function b(e){return"string"==typeof e||rt.call(e)==gt}function w(e){var t=[];return xt(e,function(e){t.push(e)}),t}function E(e,t){var n=!1;return"number"==typeof (e?e.length:0)?n=-1<D(e,t):Lt(e,function(e){return(n=e===t)&&W}),n}function S(e,t,n){var r=!0,t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i&&(r=!!t(e[n],n,e)););else Lt(e,function(e,n,i){return!(r=!!t(e,n,i))&&W});return r}function x(e,t,n){var r=[],t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i;){var o=e[n];t(o,n,
|
||||
e)&&r.push(o)}else Lt(e,function(e,n,i){t(e,n,i)&&r.push(e)});return r}function T(e,t,n){var r,t=s(t,n);return Lt(e,function(e,n,i){if(t(e,n,i))return r=e,W}),r}function N(e,t,n){var r=-1,i=e?e.length:0,o=Array("number"==typeof i?i:0),t=s(t,n);if(Ct(e))for(;++r<i;)o[r]=t(e[r],r,e);else Lt(e,function(e,n,i){o[++r]=t(e,n,i)});return o}function C(e,t,n){var r=-Infinity,i=-1,o=e?e.length:0,u=r;if(t||!Ct(e))t=s(t,n),Lt(e,function(e,n,i){n=t(e,n,i),n>r&&(r=n,u=e)});else for(;++i<o;)e[i]>u&&(u=e[i]);return u
|
||||
}function k(e,t){var n=[];return Lt(e,function(e){n.push(e[t])}),n}function L(e,t,n,r){var i=3>arguments.length;return t||(t=F),Lt(e,function(e,s,o){n=i?(i=!1,e):t.call(r,n,e,s,o)}),n}function A(e,t,n,r){var i=e?e.length:0,s=3>arguments.length;if("number"!=typeof i)var o=kt(e),i=o.length;return t||(t=F),Lt(e,function(u,a,f){a=o?o[--i]:--i,n=s?(s=!1,e[a]):t.call(r,n,e[a],a,f)}),n}function O(e,t,n){var r,t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i&&!(r=t(e[n],n,e)););else Lt(e,function(e,n,i){return(
|
||||
r=t(e,n,i))&&W});return!!r}function M(e,t,n){if(e)return null==t||n?e[0]:nt.call(e,0,t)}function _(e,t){for(var n=-1,r=e?e.length:0,i=[];++n<r;){var s=e[n];Ct(s)?tt.apply(i,t?s:_(s)):i.push(s)}return i}function D(e,t,n){var r=-1,i=e?e.length:0;if("number"==typeof n)r=(0>n?at(0,i+n):n||0)-1;else if(n)return r=H(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function P(e,t,n){return e?nt.call(e,null==t||n?1:t):[]}function H(e,t,n,r){for(var i=0,o=e?e.length:i,n=n?s(n,r):F,t=n(t);i<o;)
|
||||
r=i+o>>>1,n(e[r])<t?i=r+1:o=r;return i}function B(e,t,n,r){var i=-1,o=e?e.length:0,u=[],a=u;n&&(a=[],n=s(n,r));for(;++i<o;){var r=e[i],f=n?n(r,i,e):r;if(t?!i||a[a.length-1]!==f:0>D(a,f))n&&a.push(f),u.push(r)}return u}function j(e,t){return bt||it&&2<arguments.length?it.call.apply(it,arguments):i(e,t,nt.call(arguments,2))}function F(e){return e}function I(e){Lt(p(e),function(t){var r=n[t]=e[t];n.prototype[t]=function(){var e=[this.__wrapped__];return tt.apply(e,arguments),e=r.apply(n,e),this.__chain__&&
|
||||
(e=new n(e),e.__chain__=!0),e}})}var q="object"==typeof exports&&exports,R="object"==typeof global&&global;R.global===R&&(e=R);var U=[],R=new function(){},z=0,W=R,X=e._,V=/&(?:amp|lt|gt|quot|#x27);/g,$=RegExp("^"+(R.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&").replace(/valueOf|for [^\]]+/g,".+?")+"$"),J=/($^)/,K=/[&<>"']/g,Q=/['\n\r\t\u2028\u2029\\]/g,G=Math.ceil,Y=U.concat,Z=Math.floor,et=R.hasOwnProperty,tt=U.push,nt=U.slice,rt=R.toString,it=$.test(it=nt.bind)&&it,st=$.test(st=Array.isArray
|
||||
)&&st,ot=e.isFinite,ut=$.test(ut=Object.keys)&&ut,at=Math.max,ft=Math.min,lt=Math.random,ct="[object Array]",ht="[object Boolean]",pt="[object Date]",dt="[object Number]",vt="[object Object]",mt="[object RegExp]",gt="[object String]",yt=(yt={0:1,length:1},U.splice.call(yt,0,1),yt[0]),bt=it&&/\n|Opera/.test(it+rt.call(e.opera)),wt={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,"undefined":!1},Et={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};n.templateSettings=
|
||||
{escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,variable:""},n.isArguments=function(e){return"[object Arguments]"==rt.call(e)},n.isArguments(arguments)||(n.isArguments=function(e){return e?et.call(e,"callee"):!1});var St=function(e,t){var n;if(!e)return e;t=s(t);for(n in e)if(t(e[n],n,e)===W)break;return e},xt=function(e,t){var n;if(!e)return e;t=s(t);for(n in e)if(et.call(e,n)&&t(e[n],n,e)===W)break;return e},Tt={"&":"&","<":"<",">":">",'"':"""
|
||||
,"'":"'"},Nt=d(Tt),Ct=st||function(e){return rt.call(e)==ct};m(/x/)&&(m=function(e){return"[object Function]"==rt.call(e)});var kt=ut?function(e){return g(e)?ut(e):[]}:c,Lt=function(e,t,n){if(!e)return e;var t=s(t,n),r=e.length,n=-1;if("number"==typeof r){for(;++n<r;)if(t(e[n],n,e)===W)return e}else for(n in e)if(et.call(e,n)&&t(e[n],n,e)===W)return e};n.VERSION="0.10.0",n.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},n.bind=j,n.bindAll=function(e){for(
|
||||
var t=arguments,n=1<t.length?0:(t=p(e),-1),r=t.length;++n<r;){var i=t[n];e[i]=j(e[i],e)}return e},n.chain=function(e){return e=new n(e),e.__chain__=!0,e},n.clone=function(e){return e&&wt[typeof e]?Ct(e)?nt.call(e):l({},e):e},n.compact=function(e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r},n.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},n.contains=E,n.countBy=function(e,t,n){var r={},t=s
|
||||
(t,n);return Lt(e,function(e,n,i){n=t(e,n,i),et.call(r,n)?r[n]++:r[n]=1}),r},n.debounce=function(e,t,n){function r(){u=null,n||(s=e.apply(o,i))}var i,s,o,u;return function(){var a=n&&!u;return i=arguments,o=this,clearTimeout(u),u=setTimeout(r,t),a&&(s=e.apply(o,i)),s}},n.defaults=h,n.defer=function(e){var n=nt.call(arguments,1);return setTimeout(function(){e.apply(t,n)},1)},n.delay=function(e,n){var r=nt.call(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},n.difference=function(e){for(
|
||||
var t=-1,n=e.length,r=Y.apply(U,arguments),i=[];++t<n;){var s=e[t];0>D(r,s,n)&&i.push(s)}return i},n.escape=function(e){return null==e?"":(e+"").replace(K,u)},n.every=S,n.filter=x,n.find=T,n.first=M,n.flatten=_,n.forEach=Lt,n.functions=p,n.groupBy=function(e,t,n){var r={},t=s(t,n);return Lt(e,function(e,n,i){n=t(e,n,i),(et.call(r,n)?r[n]:r[n]=[]).push(e)}),r},n.has=function(e,t){return e?et.call(e,t):!1},n.identity=F,n.indexOf=D,n.initial=function(e,t,n){return e?nt.call(e,0,-(null==t||n?1:t)):[]
|
||||
},n.intersection=function(e){var t=arguments,n=t.length,r=[];return Lt(e,function(e){if(0>D(r,e)){for(var i=n;--i;)if(0>D(t[i],e))return;r.push(e)}}),r},n.invert=d,n.invoke=function(e,t){var n=nt.call(arguments,2),r="function"==typeof t,i=[];return Lt(e,function(e){i.push((r?t:e[t]).apply(e,n))}),i},n.isArray=Ct,n.isBoolean=function(e){return!0===e||!1===e||rt.call(e)==ht},n.isDate=function(e){return rt.call(e)==pt},n.isElement=function(e){return e?1===e.nodeType:!1},n.isEmpty=function(e){if(!e)return!0
|
||||
;if(Ct(e)||b(e))return!e.length;for(var t in e)if(et.call(e,t))return!1;return!0},n.isEqual=v,n.isFinite=function(e){return ot(e)&&rt.call(e)==dt},n.isFunction=m,n.isNaN=function(e){return y(e)&&e!=+e},n.isNull=function(e){return null===e},n.isNumber=y,n.isObject=g,n.isRegExp=function(e){return rt.call(e)==mt},n.isString=b,n.isUndefined=function(e){return e===t},n.keys=kt,n.last=function(e,t,n){if(e){var r=e.length;return null==t||n?e[r-1]:nt.call(e,-t||r)}},n.lastIndexOf=function(e,t,n){var r=e?
|
||||
e.length:0;for("number"==typeof n&&(r=(0>n?at(0,r+n):ft(n,r-1))+1);r--;)if(e[r]===t)return r;return-1},n.map=N,n.max=C,n.memoize=function(e,t){var n={};return function(){var r=t?t.apply(this,arguments):arguments[0];return et.call(n,r)?n[r]:n[r]=e.apply(this,arguments)}},n.min=function(e,t,n){var r=Infinity,i=-1,o=e?e.length:0,u=r;if(t||!Ct(e))t=s(t,n),Lt(e,function(e,n,i){n=t(e,n,i),n<r&&(r=n,u=e)});else for(;++i<o;)e[i]<u&&(u=e[i]);return u},n.mixin=I,n.noConflict=function(){return e._=X,this},n
|
||||
.object=function(e,t){for(var n=-1,r=e?e.length:0,i={};++n<r;){var s=e[n];t?i[s]=t[n]:i[s[0]]=s[1]}return i},n.omit=function(e){var t=Y.apply(U,arguments),n={};return St(e,function(e,r){0>D(t,r,1)&&(n[r]=e)}),n},n.once=function(e){var t,n=!1;return function(){return n?t:(n=!0,t=e.apply(this,arguments),e=null,t)}},n.pairs=function(e){var t=[];return xt(e,function(e,n){t.push([n,e])}),t},n.pick=function(e){for(var t=0,n=Y.apply(U,arguments),r=n.length,i={};++t<r;){var s=n[t];s in e&&(i[s]=e[s])}return i
|
||||
},n.pluck=k,n.random=function(e,t){return null==e&&null==t&&(t=1),e=+e||0,null==t&&(t=e,e=0),e+Z(lt()*((+t||0)-e+1))},n.range=function(e,t,n){e=+e||0,n=+n||1,null==t&&(t=e,e=0);for(var r=-1,t=at(0,G((t-e)/n)),i=Array(t);++r<t;)i[r]=e,e+=n;return i},n.reduce=L,n.reduceRight=A,n.reject=function(e,t,n){return t=s(t,n),x(e,function(e,n,r){return!t(e,n,r)})},n.rest=P,n.result=function(e,t){var n=e?e[t]:null;return m(n)?e[t]():n},n.shuffle=function(e){var t=-1,n=Array(e?e.length:0);return Lt(e,function(
|
||||
e){var r=Z(lt()*(++t+1));n[t]=n[r],n[r]=e}),n},n.size=function(e){var t=e?e.length:0;return"number"==typeof t?t:kt(e).length},n.some=O,n.sortBy=function(e,t,n){var i=[],t=s(t,n);Lt(e,function(e,n,r){i.push({a:t(e,n,r),b:n,c:e})}),e=i.length;for(i.sort(r);e--;)i[e]=i[e].c;return i},n.sortedIndex=H,n.tap=function(e,t){return t(e),e},n.template=function(e,t,r){e||(e="");var r=h({},r,n.templateSettings),i=0,s="__p+='",u=r.variable;e.replace(RegExp((r.escape||J).source+"|"+(r.interpolate||J).source+"|"+
|
||||
(r.evaluate||J).source+"|$","g"),function(t,n,r,u,a){s+=e.slice(i,a).replace(Q,o),s+=n?"'+_['escape']("+n+")+'":u?"';"+u+";__p+='":r?"'+((__t=("+r+"))==null?'':__t)+'":"",i=a+t.length}),s+="';\n",u||(u="obj",s="with("+u+"||{}){"+s+"}"),s="function("+u+"){var __t,__p='',__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}"+s+"return __p}";try{var a=Function("_","return "+s)(n)}catch(f){throw f.source=s,f}return t?a(t):(a.source=s,a)},n.throttle=function(e,t){function n(){u=new Date
|
||||
,o=null,i=e.apply(s,r)}var r,i,s,o,u=0;return function(){var a=new Date,f=t-(a-u);return r=arguments,s=this,0>=f?(clearTimeout(o),u=a,i=e.apply(s,r)):o||(o=setTimeout(n,f)),i}},n.times=function(e,t,n){for(var e=+e||0,r=-1,i=Array(e);++r<e;)i[r]=t.call(n,r);return i},n.toArray=function(e){var t=e?e.length:0;if("number"==typeof t){for(var n=-1,r=Array(t);++n<t;)r[n]=e[n];return r}return w(e)},n.unescape=function(e){return null==e?"":(e+"").replace(V,f)},n.union=function(){return B(Y.apply(U,arguments
|
||||
))},n.uniq=B,n.uniqueId=function(e){var t=z++;return e?e+t:t},n.values=w,n.where=function(e,t){var n=kt(t);return x(e,function(e){for(var r=n.length;r--;){var i=e[n[r]]===t[n[r]];if(!i)break}return!!i})},n.without=function(e){for(var t=-1,n=e.length,r=[];++t<n;){var i=e[t];0>D(arguments,i,1)&&r.push(i)}return r},n.wrap=function(e,t){return function(){var n=[e];return tt.apply(n,arguments),t.apply(this,n)}},n.zip=function(e){for(var t=-1,n=e?C(k(arguments,"length")):0,r=Array(n);++t<n;)r[t]=k(arguments
|
||||
,t);return r},n.all=S,n.any=O,n.collect=N,n.detect=T,n.drop=P,n.each=Lt,n.extend=l,n.foldl=L,n.foldr=A,n.head=M,n.include=E,n.inject=L,n.methods=p,n.select=x,n.tail=P,n.take=M,n.unique=B,I(n),n.prototype.chain=function(){return this.__chain__=!0,this},n.prototype.value=function(){return this.__wrapped__},Lt("pop push reverse shift sort splice unshift".split(" "),function(e){var t=U[e];n.prototype[e]=function(){var e=this.__wrapped__;return t.apply(e,arguments),yt&&e.length===0&&delete e[0],this}}
|
||||
),Lt(["concat","join","slice"],function(e){var t=U[e];n.prototype[e]=function(){var e=t.apply(this.__wrapped__,arguments);return this.__chain__&&(e=new n(e),e.__chain__=!0),e}}),q?"object"==typeof module&&module&&module.exports==q?(module.exports=n)._=n:q._=n:e._=n})(this);
|
||||
Reference in New Issue
Block a user