mirror of
https://github.com/wahyd4/cdnjs.git
synced 2026-08-21 18:56:05 +10:00
1 line
2.4 KiB
JavaScript
1 line
2.4 KiB
JavaScript
!function(e){function n(e){throw RangeError(L[e])}function o(e,n){for(var o=e.length;o--;)e[o]=n(e[o]);return e}function r(e,n){return o(e.split(S),n).join(".")}function t(e){for(var n,o,r=[],t=0,i=e.length;i>t;)n=e.charCodeAt(t++),55296==(63488&n)&&i>t?(o=e.charCodeAt(t++),56320==(64512&o)?r.push(((1023&n)<<10)+(1023&o)+65536):r.push(n,o)):r.push(n);return r}function i(e){return o(e,function(e){var n="";return e>65535&&(e-=65536,n+=R(e>>>10&1023|55296),e=56320|1023&e),n+=R(e)}).join("")}function u(e){return 10>e-48?e-22:26>e-65?e-65:26>e-97?e-97:C}function f(e,n){return e+22+75*(26>e)-((0!=n)<<5)}function c(e,n,o){var r=0;for(e=o?P(e/A):e>>1,e+=P(e/n);e>M*b>>1;r+=C)e=P(e/M);return P(r+(M+1)*e/(e+j))}function s(e){var o,r,t,f,s,d,a,l,p,h,v=[],g=e.length,w=0,j=I,A=m;for(r=e.lastIndexOf(F),0>r&&(r=0),t=0;r>t;++t)e.charCodeAt(t)>=128&&n("not-basic"),v.push(e.charCodeAt(t));for(f=r>0?r+1:0;g>f;){for(s=w,d=1,a=C;f>=g&&n("invalid-input"),l=u(e.charCodeAt(f++)),(l>=C||l>P((x-w)/d))&&n("overflow"),w+=l*d,p=A>=a?y:a>=A+b?b:a-A,!(p>l);a+=C)h=C-p,d>P(x/h)&&n("overflow"),d*=h;o=v.length+1,A=c(w-s,o,0==s),P(w/o)>x-j&&n("overflow"),j+=P(w/o),w%=o,v.splice(w++,0,j)}return i(v)}function d(e){var o,r,i,u,s,d,a,l,p,h,v,g,w,j,A,E=[];for(e=t(e),g=e.length,o=I,r=0,s=m,d=0;g>d;++d)v=e[d],128>v&&E.push(R(v));for(i=u=E.length,u&&E.push(F);g>i;){for(a=x,d=0;g>d;++d)v=e[d],v>=o&&a>v&&(a=v);for(w=i+1,a-o>P((x-r)/w)&&n("overflow"),r+=(a-o)*w,o=a,d=0;g>d;++d)if(v=e[d],o>v&&++r>x&&n("overflow"),v==o){for(l=r,p=C;h=s>=p?y:p>=s+b?b:p-s,!(h>l);p+=C)A=l-h,j=C-h,E.push(R(f(h+A%j,0))),l=P(A/j);E.push(R(f(l,0))),s=c(r,w,i==u),r=0,++i}++r,++o}return E.join("")}function a(e){return r(e,function(e){return E.test(e)?s(e.slice(4).toLowerCase()):e})}function l(e){return r(e,function(e){return O.test(e)?"xn--"+d(e):e})}var p,h,v="function"==typeof define&&"object"==typeof define.amd&&define.amd&&define,g="object"==typeof exports&&exports,w="object"==typeof module&&module,x=2147483647,C=36,y=1,b=26,j=38,A=700,m=72,I=128,F="-",E=/^xn--/,O=/[^ -~]/,S=/\x2E|\u3002|\uFF0E|\uFF61/g,L={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},M=C-y,P=Math.floor,R=String.fromCharCode;if(p={version:"1.2.0",ucs2:{decode:t,encode:i},decode:s,encode:d,toASCII:l,toUnicode:a},g)if(w&&w.exports==g)w.exports=p;else for(h in p)p.hasOwnProperty(h)&&(g[h]=p[h]);else v?define("punycode",p):e.punycode=p}(this); |