mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-14 20:57:49 +00:00
Fix minified compat/modern builds.
This commit is contained in:
4
dist/lodash.min.js
vendored
4
dist/lodash.min.js
vendored
@@ -16,7 +16,7 @@ var a=typeof n,f=typeof t;if(n===n&&(null==n||null==t||"function"!=a&&"object"!=
|
||||
}for(u||(u=[]),o||(o=[]),f=u.length;f--;)if(u[f]==n)return o[f]==t;var p=0,i=true;if(u.push(n),o.push(t),a){if(f=n.length,p=t.length,(i=p==f)||e)for(;p--;)if(a=f,l=t[p],e)for(;a--&&!(i=yt(n[a],l,r,e,u,o)););else if(!(i=yt(n[p],l,r,e,u,o)))break}else pt(t,function(t,a,f){return Kr.call(f,a)?(p++,i=Kr.call(n,a)&&yt(n[a],t,r,e,u,o)):void 0},pr),i&&!e&&pt(n,function(n,t,r){return Kr.call(r,t)?i=-1<--p:void 0},pr);return u.pop(),o.pop(),i}function mt(n,t,r,e,u){(we(t)?ft:gt)(t,function(t,o){var i,a,f=t,l=n[o];
|
||||
if(t&&((a=we(t))||xe(t))){for(f=e.length;f--;)if(i=e[f]==t){l=u[f];break}if(!i){var c;r&&(f=r(l,t),c=typeof f!="undefined")&&(l=f),c||(l=a?we(l)?l:[]:xe(l)?l:{}),e.push(t),u.push(l),c||mt(l,t,r,e,u)}}else r&&(f=r(l,t),typeof f=="undefined"&&(f=t)),typeof f!="undefined"&&(l=f);n[o]=l})}function dt(n,t){return n+qr(ae()*(t-n+1))}function bt(n,e,u){var o=n?n.length:0;if(!o)return[];var i=-1,a=Ct(),f=!e&&a===t,l=f&&ge&&200<=o,f=f&&!l,c=[];if(l)var p=ge(),a=r;else p=u&&!e?[]:c;n:for(;++i<o;){var s=n[i],h=u?u(s,i,n):s;
|
||||
if(f){for(var g=p.length;g--;)if(p[g]===h)continue n;u&&p.push(h),c.push(s)}else e?i&&p===h||(p=h,c.push(s)):0>a(p,h)&&((u||l)&&p.push(h),c.push(s))}return c}function _t(n,t){for(var r=-1,e=t(n),u=e.length,o=xr(u);++r<u;)o[r]=n[e[r]];return o}function wt(n,t,r){for(var e=t.length,u=-1,o=ee(r.length-e,0),i=-1,a=n.length,f=xr(o+a);++i<a;)f[i]=n[i];for(;++u<e;)f[t[u]]=r[u];for(;o--;)f[i++]=r[u++];return f}function xt(n,t){return function(r,e,o){var i=t?[[],[]]:{};e=u.createCallback(e,o,3),o=-1;var a=r?r.length:0;
|
||||
if(typeof a=="number")for(;++o<a;){var f=r[o];n(i,f,e(f,o,r),r)}else ft(r,function(t,r,u){n(i,t,e(t,r,u),u)});return i}}function kt(n,t,r){return n=n.length,t=+t||0,n<t?(t-=n,r=null==r?"":Rr(r),vr(r,zr(t/r.length)).slice(0,t)):""}function jt(n,t,r,e,u,o,i,a){var f=t&_,c=t&w,p=t&j,s=t&C;if(!c&&!ir(n))throw new Nr;p&&!u.length&&(t&=~j,p=u=false),s&&!o.length&&(t&=~C,s=o=false);var h=!c&&n[A];return h&&true!==h?(h=Wt(h),h[4]&&(h[4]=Wt(h[4])),h[5]&&(h[5]=Wt(h[5])),typeof r=="number"&&(h[2]=r),n=h[1]&_,f&&!n&&(h[3]=e),!f&&n&&(t|=k),p&&(h[4]?Mr.apply(h[4],u):h[4]=u),s&&(h[5]?Zr.apply(h[5],o):h[5]=o),h[1]|=t,jt.apply(null,h)):(null==r?r=c?0:n.length:0>r&&(r=0),p&&(i=[]),s&&(a=[]),h=[n,t,r,e,u,o,i,a],t==_||t==(_|j)?l(h):V(h))
|
||||
if(typeof a=="number")for(;++o<a;){var f=r[o];n(i,f,e(f,o,r),r)}else ft(r,function(t,r,u){n(i,t,e(t,r,u),u)});return i}}function kt(n,t,r){return n=n.length,t=+t||0,n<t?(t-=n,r=null==r?" ":Rr(r),vr(r,zr(t/r.length)).slice(0,t)):""}function jt(n,t,r,e,u,o,i,a){var f=t&_,c=t&w,p=t&j,s=t&C;if(!c&&!ir(n))throw new Nr;p&&!u.length&&(t&=~j,p=u=false),s&&!o.length&&(t&=~C,s=o=false);var h=!c&&n[A];return h&&true!==h?(h=Wt(h),h[4]&&(h[4]=Wt(h[4])),h[5]&&(h[5]=Wt(h[5])),typeof r=="number"&&(h[2]=r),n=h[1]&_,f&&!n&&(h[3]=e),!f&&n&&(t|=k),p&&(h[4]?Mr.apply(h[4],u):h[4]=u),s&&(h[5]?Zr.apply(h[5],o):h[5]=o),h[1]|=t,jt.apply(null,h)):(null==r?r=c?0:n.length:0>r&&(r=0),p&&(i=[]),s&&(a=[]),h=[n,t,r,e,u,o,i,a],t==_||t==(_|j)?l(h):V(h))
|
||||
}function Ct(){var n=(n=u.indexOf)===Rt?t:n;return n}function Ot(n){return typeof n=="function"&&Lr.test(Ur.call(n))}function At(n){var t,r;return n&&Dr.call(n)==tt&&(Kr.call(n,"constructor")||(t=n.constructor,!ir(t)||t instanceof t))?(pt(n,function(n,t){r=t},pr),typeof r=="undefined"||Kr.call(n,r)):false}function It(n){for(var t=-1,r=pr(n),e=r.length,u=[];++t<e;){var o=r[t];Kr.call(n,o)&&u.push(o)}return u}function Et(n,t,r){if(typeof t!="number"&&null!=t){var e=-1,o=n?n.length:0,i=0;for(t=u.createCallback(t,r,3);++e<o&&t(n[e],e,n);)i++
|
||||
}else if(i=t,null==i||r)return n?n[0]:b;return Wt(n,0,0<i?i:0)}function Rt(n,r,e){var u=n?n.length:0;if(typeof e=="number")e=0>e?ee(0,u+e):e||0;else if(e)return e=Ft(n,r),u&&n[e]===r?e:-1;return t(n,r,e)}function Nt(n,t,r){var e=n?n.length:0;if(typeof t!="number"&&null!=t){var o=e,i=0;for(t=u.createCallback(t,r,3);o--&&t(n[o],o,n);)i++}else i=null==t||r?1:t;return i=e-i,Wt(n,0,0<i?i:0)}function St(n,t,r){var e=n?n.length:0;if(typeof t!="number"&&null!=t){var o=e,i=0;for(t=u.createCallback(t,r,3);o--&&t(n[o],o,n);)i++
|
||||
}else if(i=t,null==i||r)return n?n[e-1]:b;return i=e-i,Wt(n,0<i?i:0)}function Tt(n,t,r){if(typeof t!="number"&&null!=t){var e=-1,o=n?n.length:0,i=0;for(t=u.createCallback(t,r,3);++e<o&&t(n[e],e,n);)i++}else i=null==t||r?1:0<t?t:0;return Wt(n,i)}function Wt(n,t,r){var e=-1,u=n?n.length:0;for(typeof t=="undefined"?t=0:0>t?t=ee(u+t,0):t>u&&(t=u),typeof r=="undefined"?r=u:0>r?r=ee(u+r,0):r>u&&(r=u),u=r-t||0,r=xr(u);++e<u;)r[e]=n[t+e];return r}function Ft(n,t,r,e){var o=0,i=n?n.length:o;for(r=r?u.createCallback(r,e,1):mr,t=r(t);o<i;)e=o+i>>>1,r(n[e])<t?o=e+1:i=e;
|
||||
@@ -60,5 +60,5 @@ n.replace(l,function(t,r,e,u,a,l){return e||(e=u),c+=n.slice(f,l).replace(M,p),r
|
||||
r=r.slice(0,null==a?o:a)}}else n.indexOf(u,o)!=o&&(u=r.lastIndexOf(u),-1<u&&(r=r.slice(0,u)));return r+e},u.unescape=function(n){return null==n?"":(n=Rr(n),0>n.indexOf(";")?n:n.replace(S,m))},u.uniqueId=function(n){var t=++I;return Rr(null==n?"":n)+t},u.all=qt,u.any=Ht,u.detect=Pt,u.findWhere=Pt,u.foldl=Yt,u.foldr=Zt,u.include=Bt,u.inject=Yt,br(function(){var n={};return gt(u,function(t,r){u.prototype[r]||(n[r]=t)}),n}(),false),u.first=Et,u.last=St,u.sample=function(n,t,r){return n&&typeof n.length!="number"&&(n=hr(n)),null==t||r?n?n[dt(0,n.length-1)]:b:(n=Gt(n),n.length=ue(ee(0,t),n.length),n)
|
||||
},u.take=Et,u.takeRight=St,u.takeRightWhile=St,u.takeWhile=Et,u.head=Et,gt(u,function(n,t){var r="sample"!==t;u.prototype[t]||(u.prototype[t]=function(t,e){var u=this.__chain__,i=n(this.__wrapped__,t,e);return u||null!=t&&(!e||r&&typeof t=="function")?new o(i,u):i})}),u.VERSION=O,u.prototype.chain=function(){return this.__chain__=true,this},u.prototype.toString=function(){return Rr(this.__wrapped__)},u.prototype.value=zt,u.prototype.valueOf=zt,ft(["join","pop","shift"],function(n){var t=Sr[n];u.prototype[n]=function(){var n=this.__chain__,r=t.apply(this.__wrapped__,arguments);
|
||||
return n?new o(r,n):r}}),ft(["push","reverse","sort","unshift"],function(n){var t=Sr[n];u.prototype[n]=function(){return t.apply(this.__wrapped__,arguments),this}}),ft(["concat","splice"],function(n){var t=Sr[n];u.prototype[n]=function(){return new o(t.apply(this.__wrapped__,arguments),this.__chain__)}}),u}var b,_=1,w=2,x=4,k=8,j=16,C=32,O="2.4.1",A="__lodash@"+O+"__",I=0,E=/\b__p\+='';/g,R=/\b(__p\+=)''\+/g,N=/(__e\(.*?\)|\b__t\))\+'';/g,S=/&(?:amp|lt|gt|quot|#39);/g,T=/[&<>"']/g,W=/<%-([\s\S]+?)%>/g,F=/<%([\s\S]+?)%>/g,$=/<%=([\s\S]+?)%>/g,D=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,L=/\w*$/,z=/^\s*function[ \n\r\t]+\w/,B=/^0[xX]/,q=/[\xC0-\xFF]/g,U=/($^)/,P=/[.*+?^${}()|[\]\\]/g,K=/\bthis\b/,M=/['\n\r\t\u2028\u2029\\]/g,V=/[a-zA-Z0-9][a-z0-9]*/g,X=" \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",Y="Array Boolean Date Function Math Number Object RegExp Set String _ clearTimeout document isFinite isNaN parseInt setTimeout TypeError window WinRTError".split(" "),Z="[object Arguments]",G="[object Array]",H="[object Boolean]",J="[object Date]",Q="[object Function]",nt="[object Number]",tt="[object Object]",rt="[object RegExp]",et="[object String]",ut={};
|
||||
ut[Q]=false,ut[Z]=ut[G]=ut[H]=ut[J]=ut[nt]=ut[tt]=ut[rt]=ut[et]=true;var ot={leading:false,maxWait:0,trailing:false},it={configurable:false,enumerable:false,value:null,writable:false},at={"&":"&","<":"<",">":">",'"':""","'":"'"},ft={"&":"&","<":"<",">":">",""":'"',"'":"'"},lt={\u00c0:"A",\u00c1:"A",\u00c2:"A",\u00c3:"A",\u00c4:"A",\u00c5:"A",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u00e3:"a",\u00e4:"a",\u00e5:"a",\u00c7:"C",\u00e7:"c",\u00d0:"D",\u00f0:"d",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u00cb:"E",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u00eb:"e",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u00cf:"I",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u00ef:"i",\u00d1:"N",\u00f1:"n",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u00d5:"O",\u00d6:"O",\u00d8:"O",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u00f5:"o",\u00f6:"o",\u00f8:"o",\u00d9:"U",\u00da:"U",\u00db:"U",\u00dc:"U",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u00fc:"u",\u00dd:"Y",\u00fd:"y",\u00ff:"y",\u00c6:"AE",\u00e6:"ae",\u00de:"Th",\u00fe:"th",\u00df:"ss","\xd7":"","\xf7":""},ct={"function":true,object:true},pt={"\\":"\\","'":"'","\n":"n","\r":"r","\t":"t","\u2028":"u2028","\u2029":"u2029"},st=ct[typeof window]&&window||this,ht=ct[typeof exports]&&exports&&!exports.nodeType&&exports,ct=ct[typeof module]&&module&&!module.nodeType&&module,gt=ht&&ct&&typeof global=="object"&&global;
|
||||
ut[Q]=false,ut[Z]=ut[G]=ut[H]=ut[J]=ut[nt]=ut[tt]=ut[rt]=ut[et]=true;var ot={leading:false,maxWait:0,trailing:false},it={configurable:false,enumerable:false,value:null,writable:false},at={"&":"&","<":"<",">":">",'"':""","'":"'"},ft={"&":"&","<":"<",">":">",""":'"',"'":"'"},lt={\u00c0:"A",\u00c1:"A",\u00c2:"A",\u00c3:"A",\u00c4:"A",\u00c5:"A",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u00e3:"a",\u00e4:"a",\u00e5:"a",\u00c7:"C",\u00e7:"c",\u00d0:"D",\u00f0:"d",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u00cb:"E",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u00eb:"e",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u00cf:"I",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u00ef:"i",\u00d1:"N",\u00f1:"n",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u00d5:"O",\u00d6:"O",\u00d8:"O",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u00f5:"o",\u00f6:"o",\u00f8:"o",\u00d9:"U",\u00da:"U",\u00db:"U",\u00dc:"U",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u00fc:"u",\u00dd:"Y",\u00fd:"y",\u00ff:"y",\u00c6:"AE",\u00e6:"ae",\u00de:"Th",\u00fe:"th",\u00df:"ss","\xd7":" ","\xf7":" "},ct={"function":true,object:true},pt={"\\":"\\","'":"'","\n":"n","\r":"r","\t":"t","\u2028":"u2028","\u2029":"u2029"},st=ct[typeof window]&&window||this,ht=ct[typeof exports]&&exports&&!exports.nodeType&&exports,ct=ct[typeof module]&&module&&!module.nodeType&&module,gt=ht&&ct&&typeof global=="object"&&global;
|
||||
!gt||gt.global!==gt&>.window!==gt&>.self!==gt||(st=gt);var gt=ct&&ct.exports===ht&&ht,vt=d();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(st._=vt, define(function(){return vt})):ht&&ct?gt?(ct.exports=vt)._=vt:ht._=vt:st._=vt}).call(this);
|
||||
Reference in New Issue
Block a user