Browse files

bump to version 0.6.7

  • Loading branch information...
1 parent 1e6452e commit ec8c7e4b7aa6ac6d1fbcd369f50ba26883cc6b57 @unscriptable committed Jul 27, 2012
View
2 README.md
@@ -20,6 +20,8 @@ Helpful link for updating submodules:
What's New?
=======
+* 0.6.7
+ * Fix problems using google closure compiler to create "dist" versions.
* 0.6.6
* Fix for Safari 6's strict treatment of string properties in un-compiled
files (paths were broken -- thanks Tiago!)
View
13 dist/curl-for-dojo1.6/curl.js
@@ -1,20 +1,21 @@
-/*
+(function(){/*
MIT License (c) copyright B Cavalier & J Hann */
var h=!0,k=!1,l=this.window||global;function m(){}function o(a,b){return 0==aa.call(a).indexOf("[object "+b)}function p(a){return a&&"/"==a.charAt(a.length-1)?a.substr(0,a.length-1):a}function r(a,b){var c,e,d;e=1;a=a.replace(ca,function(a,b,c,j){c&&e++;d=h;return j||""});return d?(c=b.split("/"),c.splice(c.length-e,e),c.concat(a||[]).join("/")):a}function s(a){var b=a.indexOf("!");return{I:a.substr(b+1),j:0<=b&&a.substr(0,b)}}function t(){}
-function u(a,b){t.prototype=a||v;var c=new t;t.prototype=v;for(var e in b)c[e]=b[e];return c}function x(){function a(a,b,d){e.push([a,b,d])}function b(a,b){for(var d,c=0;d=e[c++];)(d=d[a])&&d(b)}var c,e,d;c=this;e=[];d=function(c,f){a=c?function(a){a&&a(f)}:function(a,b){b&&b(f)};d=m;b(c?0:1,f);b=m;e=y};this.X=function(b,d,c){a(b,d,c)};this.h=function(a){c.da=a;d(h,a)};this.e=function(a){c.ca=a;d(k,a)};this.p=function(a){b(2,a)}}function z(a,b,c,e){a instanceof x?a.X(b,c,e):b(a)}
+function u(a,b){t.prototype=a||v;var c=new t;t.prototype=v;for(var e in b)c[e]=b[e];return c}function x(){function a(a,b,d){e.push([a,b,d])}function b(a,b){for(var d,c=0;d=e[c++];)(d=d[a])&&d(b)}var c,e,d;c=this;e=[];d=function(c,f){a=c?function(a){a&&a(f)}:function(a,b){b&&b(f)};d=m;b(c?0:1,f);b=m;e=y};this.X=function(b,d,c){a(b,d,c)};this.h=function(a){c.ca=a;d(h,a)};this.e=function(a){c.ba=a;d(k,a)};this.p=function(a){b(2,a)}}function z(a,b,c,e){a instanceof x?a.X(b,c,e):b(a)}
function A(a,b,c){var e;return function(){0<=--a&&b&&(e=b.apply(y,arguments));0==a&&c&&c(e);return e}}function B(){function a(b,d,c){var f;f=D.c(E,y,[].concat(b));this.then=b=function(a,b){z(f,function(b){a&&a.apply(y,b)},function(a){if(b)b(a);else throw a;});return this};this.next=function(b,d){return new a(b,d,f)};d&&b(d);z(c,function(){D.i(f)})}var b=[].slice.call(arguments),c;o(b[0],"Object")&&(c=b.shift(),E=D.b(c,E),D.s(c));return new a(b[0],b[1])}
function F(a){var b=a.id;if(b==y)if(G!==y)G={z:"Multiple anonymous defines in url"};else if(!(b=D.S()))G=a;if(b!=y){var c=H[b];b in H||(c=D.l(b,E).b,c=H[b]=D.u(c,b));if(!(c instanceof x))throw Error("duplicate define: "+b);c.Z=k;D.v(c,a)}}
var E=l.curl,I,K,L=l.document,M=L&&(L.head||L.getElementsByTagName("head")[0]),N={},O={},P={},Q={},v={},aa=v.toString,y,R={loaded:1,interactive:P,complete:1},H={},S=k,G,da=/\?/,ea=/^\/|^[^:]+:\/\//,ca=/(\.)(\.?)(?:$|\/([^\.\/]+.*)?)/g,fa=/\/\*[\s\S]*?\*\/|(?:[^\\])\/\/.*?[\n\r]/g,ga=/require\s*\(\s*["']([^"']+)["']\s*\)|(?:[^\\]?)(["'])/g,T,D;
D={c:function(a,b,c,e){function d(a){return r(a,f.f)}function g(b,c){var g,n,J,ba;g=c&&function(a){c.apply(y,a)};if(o(b,"String")){n=d(b);J=H[n];ba=J instanceof x&&J.a;if(!(n in H))throw Error("Module not resolved: "+n);if(g)throw Error("require(id, callback) not allowed");return ba||J}z(D.i(D.c(a,f.f,b,e)),g)}var f;f=new x;f.f=f.id=b||"";f.T=e;f.w=c;f.k=g;g.toUrl=function(b){return D.l(d(b),a).url};f.Y=d;return f},u:function(a,b,c,e){var d,g,f;d=D.c(a,b,y,c);d.f=e==y?b:e;g=d.h;f=A(1,function(a){d.n=
a;try{return D.L(d)}catch(b){d.e(b)}});d.h=function(a){z(c||S,function(){g(H[d.id]=f(a))})};d.A=function(a){z(c||S,function(){d.a&&(f(a),d.p(O))})};return d},K:function(a,b,c,e){a=D.c(a,b,y,c);a.f=e;return a},R:function(a){return a.k},B:function(a){return a.a||(a.a={})},Q:function(a){var b=a.o;b||(b=a.o={id:a.id,uri:D.C(a),exports:D.B(a)},b.a=b.exports);return b},C:function(a){return a.url||(a.url=D.t(a.k.toUrl(a.id)))},b:function(a){var b,c,e;(b=a)||(a={});c=a.apiName||"curl";e=a.apiContext||l;if(e!=
-l||"curl"!=c?e[c]:I&&b)throw Error(c+" already exists");e[c]=B;I&&b&&(l.curl=I);c=a.defineName||"define";e=a.defineContext||l;if(e!=l||"define"!=c?e[c]:K&&b)throw Error(c+" already exists");e[c]=c=function(){var a=D.P(arguments);F(a)};K&&b&&(l.define=K);c.amd={plugins:h,jQuery:h,$:"0.6.6"};b&&(D.b=D.F);return D.F(a)},F:function(a,b){function c(a,b){var c,e,f,i,C;for(C in a){f=a[C];f.name=f.id||f.name||C;i=d;e=s(p(f.name||C));c=e.I;if(e=e.j)i=g[e],i||(i=g[e]=u(d),i.g=u(d.g),i.d=[]),delete a[C];if(b){e=
-f;var w=void 0;e.path=p(e.path||e.location||"");w=p(e.main)||"main";"."!=w.charAt(0)&&(w="./"+w);e.D=r(w,e.name+"/");e.V=r(w,e.path+"/");e.b=e.config}else e={path:p(f)};e.J=c.split("/").length;c?(i.g[c]=e,i.d.push(c)):i.r=D.H(f,d)}}function e(a){var b=a.g;a.W=RegExp("^("+a.d.sort(function(a,c){return b[a].J<b[c].J}).join("|").replace(/\/|\./g,"\\$&")+")(?=\\/|$)");delete a.d}var d,g;b||(b={});d=u(b,a);d.r=d.baseUrl||"";d.G=d.pluginPath||"curl/plugin";d.g=u(b.g);g=d.plugins=u(b.plugins,a.plugins);
+l||"curl"!=c?e[c]:I&&b)throw Error(c+" already exists");e[c]=B;I&&b&&(l.curl=I);c=a.defineName||"define";e=a.defineContext||l;if(e!=l||"define"!=c?e[c]:K&&b)throw Error(c+" already exists");e[c]=c=function(){var a=D.P(arguments);F(a)};K&&b&&(l.define=K);c.amd={plugins:h,jQuery:h,curl:"0.6.7"};b&&(D.b=D.F);return D.F(a)},F:function(a,b){function c(a,b){var c,e,f,i,C;for(C in a){f=a[C];f.name=f.id||f.name||C;i=d;e=s(p(f.name||C));c=e.I;if(e=e.j)i=g[e],i||(i=g[e]=u(d),i.g=u(d.g),i.d=[]),delete a[C];
+if(b){e=f;var w=void 0;e.path=p(e.path||e.location||"");w=p(e.main)||"main";"."!=w.charAt(0)&&(w="./"+w);e.D=r(w,e.name+"/");e.V=r(w,e.path+"/");e.b=e.config}else e={path:p(f)};e.J=c.split("/").length;c?(i.g[c]=e,i.d.push(c)):i.r=D.H(f,d)}}function e(a){var b=a.g;a.W=RegExp("^("+a.d.sort(function(a,c){return b[a].J<b[c].J}).join("|").replace(/\/|\./g,"\\$&")+")(?=\\/|$)");delete a.d}var d,g;b||(b={});d=u(b,a);d.r=d.baseUrl||"";d.G=d.pluginPath||"curl/plugin";d.g=u(b.g);g=d.plugins=u(b.plugins,a.plugins);
d.d=[];c(a.paths,k);c(a.packages,h);for(var f in g){var i=g[f].d;i&&(g[f].d=i.concat(d.d),e(g[f]))}e(d);return d},s:function(a){var b;(b=a&&a.preloads)&&0<b.length&&z(S,function(){S=D.i(D.c(E,y,b,h))})},l:function(a,b,c){var e,d,g,f;e=b.g;c&&(b.G&&0>a.indexOf("/")&&!(a in e))&&(g=a=p(b.G)+"/"+a);c=ea.test(a)?a:a.replace(b.W,function(b){d=e[b]||{};f=d.b;return d.D&&b==a?(g=d.D,d.V):d.path||""});return{f:g||a,b:f||E,url:D.H(c,b)}},H:function(a,b){var c=b.r;return c&&!ea.test(a)?p(c)+"/"+a:a},t:function(a){return a+
-(da.test(a)?"":".js")},U:function(a,b,c){var e=L.createElement("script");e.onload=e.onreadystatechange=function(c){c=c||l.event;if("load"==c.type||R[e.readyState])delete Q[a.id],e.onload=e.onreadystatechange=e.onerror="",b()};e.onerror=function(){c(Error("Syntax or http error: "+a.url))};e.type=a.aa||"text/javascript";e.charset="utf-8";e.async=!a.ba;e.src=a.url;Q[a.id]=e;M.insertBefore(e,M.firstChild);return e},M:function(a){var b=[],c;("string"==typeof a?a:a.toSource?a.toSource():a.toString()).replace(fa,
+(da.test(a)?"":".js")},U:function(a,b,c){var e=L.createElement("script");e.onload=e.onreadystatechange=function(c){c=c||l.event;if("load"==c.type||R[e.readyState])delete Q[a.id],e.onload=e.onreadystatechange=e.onerror="",b()};e.onerror=function(){c(Error("Syntax or http error: "+a.url))};e.type=a.$||"text/javascript";e.charset="utf-8";e.async=!a.aa;e.src=a.url;Q[a.id]=e;M.insertBefore(e,M.firstChild);return e},M:function(a){var b=[],c;("string"==typeof a?a:a.toSource?a.toSource():a.toString()).replace(fa,
"").replace(ga,function(a,d,g){g?c=c==g?y:c:c||b.push(d);return a});return b},P:function(a){var b,c,e,d,g,f;g=a.length;e=a[g-1];d=o(e,"Function")?e.length:-1;2==g?o(a[0],"Array")?c=a[0]:b=a[0]:3==g&&(b=a[0],c=a[1]);!c&&0<d&&(f=h,c=["require","exports","module"].slice(0,d).concat(D.M(e)));return{id:b,n:c||[],q:0<=d?e:function(){return e},m:f}},L:function(a){var b;b=a.q.apply(a.m?a.a:y,a.n);b===y&&a.a&&(b=a.o?a.a=a.o.a:a.a);return b},v:function(a,b){a.q=b.q;a.m=b.m;a.w=b.n;D.i(a)},i:function(a){function b(a,
b,c){f[b]=a;c&&q(a,b)}function c(b,c){var e,d,f,g;e=A(1,function(a){d(a);n(a,c)});d=A(1,function(a){q(a,c)});f=D.N(b,a);(g=f instanceof x&&f.a)&&d(g);z(f,e,a.e,a.a&&function(a){f.a&&(a==N?d(f.a):a==O&&e(f.a))})}function e(){a.h(f)}var d,g,f,i,j,q,n;f=[];g=a.w;i=g.length;0==g.length&&e();q=A(i,b,function(){a.A&&a.A(f)});n=A(i,b,e);for(d=0;d<i;d++)j=g[d],j in T?(n(T[j](a),d,h),a.a&&a.p(N)):j?c(j,d):n(y,d,h);return a},O:function(a){D.C(a);D.U(a,function(){var b=G;G=y;a.Z!==k&&(!b||b.z?a.e(Error(b&&b.z||
"define() missing or duplicated: "+a.url)):D.v(a,b))},a.e);return a},N:function(a,b){var c,e,d,g,f,i,j,q,n;c=b.Y;e=b.T;d=s(a);i=d.I;g=c(d.j||i);j=D.l(g,E,!!d.j);if(d.j)f=g;else if(f=j.b.moduleLoader)i=g,g=f,j=D.l(f,E);d=H[g];g in H||(d=H[g]=D.u(j.b,g,e,j.f),d.url=D.t(j.url),D.O(d));g==f&&(q=new x,n=E.plugins[f]||E,z(d,function(a){var b,d,g;g=a.dynamic;i="normalize"in a?a.normalize(i,c,n)||"":c(i);d=f+"!"+i;b=H[d];if(!(d in H)){b=D.K(n,d,e,i);g||(H[d]=b);var j=function(a){b.h(a);g||(H[d]=a)};j.resolve=
-j;j.reject=b.e;a.load(i,b.k,j,n)}q!=b&&z(b,q.h,q.e,q.p)},q.e));return q||d},S:function(){var a;if(!o(l.opera,"Opera"))for(var b in Q)if(R[Q[b].readyState]==P){a=b;break}return a}};T={require:D.R,exports:D.B,module:D.Q};B.version="0.6.6";"function"==typeof define&&(K=define);"function"==typeof E&&(I=E,E=k);E=D.b(E);D.s(E);H.curl=B;H["curl/_privileged"]={core:D,cache:H,cfg:E,_define:F,_curl:B,Promise:x};var U=this.document;
+j;j.reject=b.e;a.load(i,b.k,j,n)}q!=b&&z(b,q.h,q.e,q.p)},q.e));return q||d},S:function(){var a;if(!o(l.opera,"Opera"))for(var b in Q)if(R[Q[b].readyState]==P){a=b;break}return a}};T={require:D.R,exports:D.B,module:D.Q};B.version="0.6.7";"function"==typeof define&&(K=define);"function"==typeof E&&(I=E,E=k);E=D.b(E);D.s(E);H.curl=B;H["curl/_privileged"]={core:D,cache:H,cfg:E,_define:F,_curl:B,Promise:x};var U=this.document;
function ha(){if(!U.body)return k;V||(V=U.createTextNode(""));try{U.body.removeChild(U.body.appendChild(V));V=ia;return h}catch(a){return k}}function W(){var a;a=ja[U[X]]&&ha();if(!Y&&a){Y=h;for(clearTimeout(Z);ka=la.pop();)ka();ma&&(U[X]="complete");for(var b;b=na.shift();)b()}return a}function oa(){W();Y||(Z=setTimeout(oa,pa))}var X="readyState",ja={loaded:1,interactive:1,complete:1},na=[],ma=U&&"string"!=typeof U[X],Y=k,pa=10,$,ka,la=[],Z,ia,V;
$="addEventListener"in this?function(a,b){a.addEventListener(b,W,k);return function(){a.removeEventListener(b,W,k)}}:function(a,b){a.attachEvent("on"+b,W);return function(){a.detachEvent(b,W)}};U&&!W()&&(la=[$(this,"load"),$(U,"readystatechange"),$(this,"DOMContentLoaded")],Z=setTimeout(oa,pa));define("curl/domReady",function(){function a(a){Y?a():na.push(a)}a.then=a;a.amd=h;return a});var qa;
define("curl/shim/dojo16",["curl/_privileged","curl/domReady"],function(a,b){function c(a){a.ready||(a.ready=function(a){b(a)});a.nameToUrl||(a.nameToUrl=function(b,c){return a.toUrl(b+(c||""))});a.cache||(a.cache={})}var e=a._curl,d=a.core.c;c(e);typeof qa=="undefined"&&(qa=e);a.core.c=function(){var a=d.apply(this,arguments);c(a.k);return a};return h});define("domReady",["curl/domReady"],function(a){return{load:function(b,c,e){a(e)}}});
+}());
View
9 dist/curl-for-jQuery/curl.js
@@ -1,22 +1,23 @@
-/*
+(function(){/*
MIT License (c) copyright B Cavalier & J Hann */
var h=!0,l=!1,m=this.window||global;function n(){}function p(a,b){return 0==aa.call(a).indexOf("[object "+b)}function q(a){return a&&"/"==a.charAt(a.length-1)?a.substr(0,a.length-1):a}function r(a,b){var d,c,e;c=1;a=a.replace(ba,function(a,b,d,j){d&&c++;e=h;return j||""});return e?(d=b.split("/"),d.splice(d.length-c,c),d.concat(a||[]).join("/")):a}function t(a){var b=a.indexOf("!");return{L:a.substr(b+1),j:0<=b&&a.substr(0,b)}}function u(){}
-function w(a,b){u.prototype=a||y;var d=new u;u.prototype=y;for(var c in b)d[c]=b[c];return d}function A(){function a(a,b,e){c.push([a,b,e])}function b(a,b){for(var e,d=0;e=c[d++];)(e=e[a])&&e(b)}var d,c,e;d=this;c=[];e=function(d,f){a=d?function(a){a&&a(f)}:function(a,b){b&&b(f)};e=n;b(d?0:1,f);b=n;c=B};this.$=function(b,e,d){a(b,e,d)};this.h=function(a){d.r=a;e(h,a)};this.d=function(a){d.ea=a;e(l,a)};this.o=function(a){b(2,a)}}function C(a,b,d,c){a instanceof A?a.$(b,d,c):b(a)}
+function w(a,b){u.prototype=a||y;var d=new u;u.prototype=y;for(var c in b)d[c]=b[c];return d}function A(){function a(a,b,e){c.push([a,b,e])}function b(a,b){for(var e,d=0;e=c[d++];)(e=e[a])&&e(b)}var d,c,e;d=this;c=[];e=function(d,f){a=d?function(a){a&&a(f)}:function(a,b){b&&b(f)};e=n;b(d?0:1,f);b=n;c=B};this.$=function(b,e,d){a(b,e,d)};this.h=function(a){d.r=a;e(h,a)};this.d=function(a){d.da=a;e(l,a)};this.o=function(a){b(2,a)}}function C(a,b,d,c){a instanceof A?a.$(b,d,c):b(a)}
function D(a,b,d){var c;return function(){0<=--a&&b&&(c=b.apply(B,arguments));0==a&&d&&d(c);return c}}function E(){function a(b,e,d){var f;f=F.g(H,B,[].concat(b));this.then=b=function(a,b){C(f,function(b){a&&a.apply(B,b)},function(a){if(b)b(a);else throw a;});return this};this.next=function(b,e){return new a(b,e,f)};e&&b(e);C(d,function(){F.i(f)})}var b=[].slice.call(arguments),d;p(b[0],"Object")&&(d=b.shift(),H=F.b(d,H),F.t(d));return new a(b[0],b[1])}
function I(a){var b=a.id;if(b==B)if(J!==B)J={A:"Multiple anonymous defines in url"};else if(!(b=F.V()))J=a;if(b!=B){var d=K[b];b in K||(d=F.k(b,H).b,d=K[b]=F.v(d,b));if(!(d instanceof A))throw Error("duplicate define: "+b);d.ca=l;F.w(d,a)}}
var H=m.curl,L,M,N=m.document,O=N&&(N.head||N.getElementsByTagName("head")[0]),P={},ca={},da={},Q={},y={},aa=y.toString,B,ea={loaded:1,interactive:da,complete:1},K={},R=l,J,fa=/\?/,ga=/^\/|^[^:]+:\/\//,ba=/(\.)(\.?)(?:$|\/([^\.\/]+.*)?)/g,ha=/\/\*[\s\S]*?\*\/|(?:[^\\])\/\/.*?[\n\r]/g,ia=/require\s*\(\s*["']([^"']+)["']\s*\)|(?:[^\\]?)(["'])/g,S,F;
F={g:function(a,b,d,c){function e(a){return r(a,f.e)}function g(b,d){var g,k,s,x;g=d&&function(a){d.apply(B,a)};if(p(b,"String")){k=e(b);s=K[k];x=s instanceof A&&s.a;if(!(k in K))throw Error("Module not resolved: "+k);if(g)throw Error("require(id, callback) not allowed");return x||s}C(F.i(F.g(a,f.e,b,c)),g)}var f;f=new A;f.e=f.id=b||"";f.W=c;f.z=d;f.p=g;g.toUrl=function(b){return F.k(e(b),a).url};f.ba=e;return f},v:function(a,b,d,c){var e,g,f;e=F.g(a,b,B,d);e.e=c==B?b:c;g=e.h;f=D(1,function(a){e.m=
a;try{return F.O(e)}catch(b){e.d(b)}});e.h=function(a){C(d||R,function(){g(K[e.id]=f(a))})};e.B=function(a){C(d||R,function(){e.a&&(f(a),e.o(ca))})};return e},N:function(a,b,d,c){a=F.g(a,b,B,d);a.e=c;return a},U:function(a){return a.p},C:function(a){return a.a||(a.a={})},T:function(a){var b=a.n;b||(b=a.n={id:a.id,uri:F.D(a),exports:F.C(a)},b.a=b.exports);return b},D:function(a){return a.url||(a.url=F.u(a.p.toUrl(a.id)))},b:function(a){var b,d,c;(b=a)||(a={});d=a.apiName||"curl";c=a.apiContext||m;
-if(c!=m||"curl"!=d?c[d]:L&&b)throw Error(d+" already exists");c[d]=E;L&&b&&(m.curl=L);d=a.defineName||"define";c=a.defineContext||m;if(c!=m||"define"!=d?c[d]:M&&b)throw Error(d+" already exists");c[d]=d=function(){var a=F.S(arguments);I(a)};M&&b&&(m.define=M);d.amd={plugins:h,jQuery:h,da:"0.6.6"};b&&(F.b=F.I);return F.I(a)},I:function(a,b){function d(a,b){var d,c,f,i,v;for(v in a){f=a[v];f.name=f.id||f.name||v;i=e;c=t(q(f.name||v));d=c.L;if(c=c.j)i=g[c],i||(i=g[c]=w(e),i.f=w(e.f),i.c=[]),delete a[v];
+if(c!=m||"curl"!=d?c[d]:L&&b)throw Error(d+" already exists");c[d]=E;L&&b&&(m.curl=L);d=a.defineName||"define";c=a.defineContext||m;if(c!=m||"define"!=d?c[d]:M&&b)throw Error(d+" already exists");c[d]=d=function(){var a=F.S(arguments);I(a)};M&&b&&(m.define=M);d.amd={plugins:h,jQuery:h,curl:"0.6.7"};b&&(F.b=F.I);return F.I(a)},I:function(a,b){function d(a,b){var d,c,f,i,v;for(v in a){f=a[v];f.name=f.id||f.name||v;i=e;c=t(q(f.name||v));d=c.L;if(c=c.j)i=g[c],i||(i=g[c]=w(e),i.f=w(e.f),i.c=[]),delete a[v];
if(b){c=f;var z=void 0;c.path=q(c.path||c.location||"");z=q(c.main)||"main";"."!=z.charAt(0)&&(z="./"+z);c.G=r(z,c.name+"/");c.X=r(z,c.path+"/");c.b=c.config}else c={path:q(f)};c.M=d.split("/").length;d?(i.f[d]=c,i.c.push(d)):i.s=F.K(f,e)}}function c(a){var b=a.f;a.Z=RegExp("^("+a.c.sort(function(a,c){return b[a].M<b[c].M}).join("|").replace(/\/|\./g,"\\$&")+")(?=\\/|$)");delete a.c}var e,g;b||(b={});e=w(b,a);e.s=e.baseUrl||"";e.J=e.pluginPath||"curl/plugin";e.f=w(b.f);g=e.plugins=w(b.plugins,a.plugins);
e.c=[];d(a.paths,l);d(a.packages,h);for(var f in g){var i=g[f].c;i&&(g[f].c=i.concat(e.c),c(g[f]))}c(e);return e},t:function(a){var b;(b=a&&a.preloads)&&0<b.length&&C(R,function(){R=F.i(F.g(H,B,b,h))})},k:function(a,b,d){var c,e,g,f;c=b.f;d&&(b.J&&0>a.indexOf("/")&&!(a in c))&&(g=a=q(b.J)+"/"+a);d=ga.test(a)?a:a.replace(b.Z,function(b){e=c[b]||{};f=e.b;return e.G&&b==a?(g=e.G,e.X):e.path||""});return{e:g||a,b:f||H,url:F.K(d,b)}},K:function(a,b){var d=b.s;return d&&!ga.test(a)?q(d)+"/"+a:a},u:function(a){return a+
(fa.test(a)?"":".js")},F:function(a,b,d){var c=N.createElement("script");c.onload=c.onreadystatechange=function(d){d=d||m.event;if("load"==d.type||ea[c.readyState])delete Q[a.id],c.onload=c.onreadystatechange=c.onerror="",b()};c.onerror=function(){d(Error("Syntax or http error: "+a.url))};c.type=a.H||"text/javascript";c.charset="utf-8";c.async=!a.Y;c.src=a.url;Q[a.id]=c;O.insertBefore(c,O.firstChild);return c},P:function(a){var b=[],d;("string"==typeof a?a:a.toSource?a.toSource():a.toString()).replace(ha,
"").replace(ia,function(a,e,g){g?d=d==g?B:d:d||b.push(e);return a});return b},S:function(a){var b,d,c,e,g,f;g=a.length;c=a[g-1];e=p(c,"Function")?c.length:-1;2==g?p(a[0],"Array")?d=a[0]:b=a[0]:3==g&&(b=a[0],d=a[1]);!d&&0<e&&(f=h,d=["require","exports","module"].slice(0,e).concat(F.P(c)));return{id:b,m:d||[],q:0<=e?c:function(){return c},l:f}},O:function(a){var b;b=a.q.apply(a.l?a.a:B,a.m);b===B&&a.a&&(b=a.n?a.a=a.n.a:a.a);return b},w:function(a,b){a.q=b.q;a.l=b.l;a.z=b.m;F.i(a)},i:function(a){function b(a,
b,d){f[b]=a;d&&o(a,b)}function d(b,d){var c,e,f,i;c=D(1,function(a){e(a);k(a,d)});e=D(1,function(a){o(a,d)});f=F.Q(b,a);(i=f instanceof A&&f.a)&&e(i);C(f,c,a.d,a.a&&function(a){f.a&&(a==P?e(f.a):a==ca&&c(f.a))})}function c(){a.h(f)}var e,g,f,i,j,o,k;f=[];g=a.z;i=g.length;0==g.length&&c();o=D(i,b,function(){a.B&&a.B(f)});k=D(i,b,c);for(e=0;e<i;e++)j=g[e],j in S?(k(S[j](a),e,h),a.a&&a.o(P)):j?d(j,e):k(B,e,h);return a},R:function(a){F.D(a);F.F(a,function(){var b=J;J=B;a.ca!==l&&(!b||b.A?a.d(Error(b&&
b.A||"define() missing or duplicated: "+a.url)):F.w(a,b))},a.d);return a},Q:function(a,b){var d,c,e,g,f,i,j,o,k;d=b.ba;c=b.W;e=t(a);i=e.L;g=d(e.j||i);j=F.k(g,H,!!e.j);if(e.j)f=g;else if(f=j.b.moduleLoader)i=g,g=f,j=F.k(f,H);e=K[g];g in K||(e=K[g]=F.v(j.b,g,c,j.e),e.url=F.u(j.url),F.R(e));g==f&&(o=new A,k=H.plugins[f]||H,C(e,function(a){var b,e,g;g=a.dynamic;i="normalize"in a?a.normalize(i,d,k)||"":d(i);e=f+"!"+i;b=K[e];if(!(e in K)){b=F.N(k,e,c,i);g||(K[e]=b);var j=function(a){b.h(a);g||(K[e]=a)};
-j.resolve=j;j.reject=b.d;a.load(i,b.p,j,k)}o!=b&&C(b,o.h,o.d,o.o)},o.d));return o||e},V:function(){var a;if(!p(m.opera,"Opera"))for(var b in Q)if(ea[Q[b].readyState]==da){a=b;break}return a}};S={require:F.U,exports:F.C,module:F.T};E.version="0.6.6";"function"==typeof define&&(M=define);"function"==typeof H&&(L=H,H=l);H=F.b(H);F.t(H);K.curl=E;K["curl/_privileged"]={core:F,cache:K,cfg:H,_define:I,_curl:E,Promise:A};var T=this.document;
+j.resolve=j;j.reject=b.d;a.load(i,b.p,j,k)}o!=b&&C(b,o.h,o.d,o.o)},o.d));return o||e},V:function(){var a;if(!p(m.opera,"Opera"))for(var b in Q)if(ea[Q[b].readyState]==da){a=b;break}return a}};S={require:F.U,exports:F.C,module:F.T};E.version="0.6.7";"function"==typeof define&&(M=define);"function"==typeof H&&(L=H,H=l);H=F.b(H);F.t(H);K.curl=E;K["curl/_privileged"]={core:F,cache:K,cfg:H,_define:I,_curl:E,Promise:A};var T=this.document;
function ja(){if(!T.body)return l;U||(U=T.createTextNode(""));try{T.body.removeChild(T.body.appendChild(U));U=ka;return h}catch(a){return l}}function V(){var a;a=la[T[W]]&&ja();if(!X&&a){X=h;for(clearTimeout(Y);ma=na.pop();)ma();oa&&(T[W]="complete");for(var b;b=pa.shift();)b()}return a}function qa(){V();X||(Y=setTimeout(qa,ra))}var W="readyState",la={loaded:1,interactive:1,complete:1},pa=[],oa=T&&"string"!=typeof T[W],X=l,ra=10,Z,ma,na=[],Y,ka,U;
Z="addEventListener"in this?function(a,b){a.addEventListener(b,V,l);return function(){a.removeEventListener(b,V,l)}}:function(a,b){a.attachEvent("on"+b,V);return function(){a.detachEvent(b,V)}};T&&!V()&&(na=[Z(this,"load"),Z(T,"readystatechange"),Z(this,"DOMContentLoaded")],Y=setTimeout(qa,ra));define("curl/domReady",function(){function a(a){X?a():pa.push(a)}a.then=a;a.amd=h;return a});var sa=this.document;function ta(a){try{return eval(a)}catch(b){}}
define("js",["curl/_privileged"],function(a){function b(b,d,c){function e(){g||(f<new Date?c():setTimeout(e,10))}var f,g,G;f=(new Date).valueOf()+(b.aa||3E5);c&&b.a&&setTimeout(e,10);G=a.core.F(b,function(){g=h;if(b.a)b.r=ta(b.a);!b.a||b.r?d(G):c()},function(a){g=h;c(a)})}function d(a,c){b(a,function(){var b=e.shift();f=e.length>0;b&&d.apply(null,b);c.resolve(a.r||h)},function(a){c.reject(a)})}var c={},e=[],g=sa&&sa.createElement("script").async==h,f;return{dynamic:h,load:function(a,j,o,k){var s,
x,G,v;s=a.indexOf("!order")>0;x=a.indexOf("!exports=");G=x>0&&a.substr(x+9);v="prefetch"in k?k.prefetch:h;a=s||x>0?a.substr(0,a.indexOf("!")):a;if(a in c)o(c[a]);else{c[a]=void 0;j={name:a,url:j.toUrl(a.lastIndexOf(".")<=a.lastIndexOf("/")?a+".js":a),Y:s,a:G,aa:k.timeout};k={resolve:function(b){c[a]=b;(o.resolve||o)(b)},reject:o.reject||function(a){throw a;}};if(s&&!g&&f){e.push([j,k]);if(v){j.H="text/cache";b(j,function(a){a&&a.parentNode.removeChild(a)},function(){});j.H=""}}else{f=f||s;d(j,k)}}}}});
var $=this.document,ua=/^\/\//,va;$&&(va=$.head||($.head=$.getElementsByTagName("head")[0]));define("link",{load:function(a,b,d,c){a=b.toUrl(a.lastIndexOf(".")<=a.lastIndexOf("/")?a+".css":a);c=a=(c="fixSchemalessUrls"in c?c.fixSchemalessUrls:$.location.protocol)?a.replace(ua,c+"//"):a;a=$.createElement("link");a.rel="stylesheet";a.type="text/css";a.href=c;va.appendChild(a);d(a.sheet||a.styleSheet)}});define("domReady",["curl/domReady"],function(a){return{load:function(b,d,c){a(c)}}});
+}());
View
8 dist/curl-for-ssjs/curl.js
@@ -9,12 +9,12 @@
* Licensed under the MIT License at:
* http://www.opensource.org/licenses/mit-license.php
*
- * @version 0.6.6
+ * @version 0.6.7
*/
(function (global) {
//"use strict"; don't restore this until the config routine is refactored
var
- version = '0.6.6',
+ version = '0.6.7',
curlName = 'curl',
userCfg = global[curlName],
prevCurl,
@@ -393,7 +393,7 @@
if (prevDefine && hasCfg) global[defineName] = prevDefine;
// indicate our capabilities:
- define['amd'] = { 'plugins': true, 'jQuery': true, curlName: version };
+ define['amd'] = { 'plugins': true, 'jQuery': true, 'curl': version };
// switch to re-runnable config
if (hasCfg) core.config = core.moreConfig;
@@ -1219,7 +1219,7 @@ define('curl/loader/cjsm11', function () {
*
* @experimental
*/
-define.amd.ssjs = true;
+define['amd'].ssjs = true;
var require, load;
(function (freeRequire, globalLoad) {
define('curl/shim/ssjs', function (require, exports) {
View
19 dist/curl-kitchen-sink/curl.js
@@ -1,36 +1,37 @@
-/*
+(function(){/*
MIT License (c) copyright B Cavalier & J Hann */
var i=void 0,m=!0,o=null,p=!1,s=this.window||global;function aa(){}function t(a,b){return 0==ba.call(a).indexOf("[object "+b)}function v(a){return a&&"/"==a.charAt(a.length-1)?a.substr(0,a.length-1):a}function w(a,b){var c,d,e;d=1;a=a.replace(ca,function(a,b,c,h){c&&d++;e=m;return h||""});return e?(c=b.split("/"),c.splice(c.length-d,d),c.concat(a||[]).join("/")):a}function da(a){var b=a.indexOf("!");return{Q:a.substr(b+1),m:0<=b&&a.substr(0,b)}}function y(){}
-function z(a,b){y.prototype=a||ea;var c=new y;y.prototype=ea;for(var d in b)c[d]=b[d];return c}function A(){function a(a,b,c){d.push([a,b,c])}function b(a,b){for(var c,e=0;c=d[e++];)(c=c[a])&&c(b)}var c,d,e;c=this;d=[];e=function(c,g){a=c?function(a){a&&a(g)}:function(a,b){b&&b(g)};e=aa;b(c?0:1,g);b=aa;d=B};this.z=function(b,d,e){a(b,d,e);return c};this.d=function(a){c.w=a;e(m,a)};this.b=function(a){c.oa=a;e(p,a)};this.u=function(a){b(2,a)}}function C(a,b,c,d){a instanceof A?a.z(b,c,d):b(a)}
+function z(a,b){y.prototype=a||ea;var c=new y;y.prototype=ea;for(var d in b)c[d]=b[d];return c}function A(){function a(a,b,c){d.push([a,b,c])}function b(a,b){for(var c,e=0;c=d[e++];)(c=c[a])&&c(b)}var c,d,e;c=this;d=[];e=function(c,g){a=c?function(a){a&&a(g)}:function(a,b){b&&b(g)};e=aa;b(c?0:1,g);b=aa;d=B};this.z=function(b,d,e){a(b,d,e);return c};this.d=function(a){c.w=a;e(m,a)};this.b=function(a){c.ma=a;e(p,a)};this.u=function(a){b(2,a)}}function C(a,b,c,d){a instanceof A?a.z(b,c,d):b(a)}
function D(a,b,c){var d;return function(){0<=--a&&b&&(d=b.apply(B,arguments));0==a&&c&&c(d);return d}}function E(){function a(b,c,f){var g;g=F.e(G,B,[].concat(b));this.then=b=function(a,b){C(g,function(b){a&&a.apply(B,b)},function(a){if(b)b(a);else throw a;});return this};this.next=function(b,c){return new a(b,c,g)};c&&b(c);C(f,function(){F.l(g)})}var b=[].slice.call(arguments),c;t(b[0],"Object")&&(c=b.shift(),G=F.c(c,G),F.A(c));return new a(b[0],b[1])}
function fa(a){var b=a.id;if(b==B)if(H!==B)H={G:"Multiple anonymous defines in url"};else if(!(b=F.$()))H=a;if(b!=B){var c=I[b];b in I||(c=F.o(b,G).c,c=I[b]=F.C(c,b));if(!(c instanceof A))throw Error("duplicate define: "+b);c.ga=p;F.D(c,a)}}
-var G=s.curl,J,K,L=s.document,ga=L&&(L.head||L.getElementsByTagName("head")[0]),ha={},ia={},ja={},M={},ea={},ba=ea.toString,B,ma={loaded:1,interactive:ja,complete:1},I={},N=p,H,na=/\?/,oa=/^\/|^[^:]+:\/\//,ca=/(\.)(\.?)(?:$|\/([^\.\/]+.*)?)/g,pa=/\/\*[\s\S]*?\*\/|(?:[^\\])\/\/.*?[\n\r]/g,qa=/require\s*\(\s*["']([^"']+)["']\s*\)|(?:[^\\]?)(["'])/g,ra,F;
+var G=s.curl,J,K,L=s.document,ga=L&&(L.head||L.getElementsByTagName("head")[0]),ha={},ia={},la={},M={},ea={},ba=ea.toString,B,ma={loaded:1,interactive:la,complete:1},I={},N=p,H,na=/\?/,oa=/^\/|^[^:]+:\/\//,ca=/(\.)(\.?)(?:$|\/([^\.\/]+.*)?)/g,pa=/\/\*[\s\S]*?\*\/|(?:[^\\])\/\/.*?[\n\r]/g,qa=/require\s*\(\s*["']([^"']+)["']\s*\)|(?:[^\\]?)(["'])/g,ra,F;
F={e:function(a,b,c,d){function e(a){return w(a,g.g)}function f(b,c){var f,j,n,q;f=c&&function(a){c.apply(B,a)};if(t(b,"String")){j=e(b);n=I[j];q=n instanceof A&&n.a;if(!(j in I))throw Error("Module not resolved: "+j);if(f)throw Error("require(id, callback) not allowed");return q||n}C(F.l(F.e(a,g.g,b,d)),f)}var g;g=new A;g.g=g.id=b||"";g.aa=d;g.F=c;g.n=f;f.toUrl=function(b){return F.o(e(b),a).url};g.fa=e;return g},C:function(a,b,c,d){var e,f,g;e=F.e(a,b,B,c);e.g=d==B?b:d;f=e.d;g=D(1,function(a){e.q=
a;try{return F.U(e)}catch(b){e.b(b)}});e.d=function(a){C(c||N,function(){f(I[e.id]=g(a))})};e.H=function(a){C(c||N,function(){e.a&&(g(a),e.u(ia))})};return e},S:function(a,b,c,d){a=F.e(a,b,B,c);a.g=d;return a},Z:function(a){return a.n},J:function(a){return a.a||(a.a={})},Y:function(a){var b=a.s;b||(b=a.s={id:a.id,uri:F.K(a),exports:F.J(a)},b.a=b.exports);return b},K:function(a){return a.url||(a.url=F.B(a.n.toUrl(a.id)))},c:function(a){var b,c,d;(b=a)||(a={});c=a.apiName||"curl";d=a.apiContext||s;
-if(d!=s||"curl"!=c?d[c]:J&&b)throw Error(c+" already exists");d[c]=E;J&&b&&(s.curl=J);c=a.defineName||"define";d=a.defineContext||s;if(d!=s||"define"!=c?d[c]:K&&b)throw Error(c+" already exists");d[c]=c=function(){var a=F.X(arguments);fa(a)};K&&b&&(s.define=K);c.amd={plugins:m,jQuery:m,na:"0.6.6"};b&&(F.c=F.N);return F.N(a)},N:function(a,b){function c(a,b){var c,d,g,k,r;for(r in a){g=a[r];g.name=g.id||g.name||r;k=e;d=da(v(g.name||r));c=d.Q;if(d=d.m)k=f[d],k||(k=f[d]=z(e),k.h=z(e.h),k.f=[]),delete a[r];
+if(d!=s||"curl"!=c?d[c]:J&&b)throw Error(c+" already exists");d[c]=E;J&&b&&(s.curl=J);c=a.defineName||"define";d=a.defineContext||s;if(d!=s||"define"!=c?d[c]:K&&b)throw Error(c+" already exists");d[c]=c=function(){var a=F.X(arguments);fa(a)};K&&b&&(s.define=K);c.amd={plugins:m,jQuery:m,curl:"0.6.7"};b&&(F.c=F.N);return F.N(a)},N:function(a,b){function c(a,b){var c,d,g,k,r;for(r in a){g=a[r];g.name=g.id||g.name||r;k=e;d=da(v(g.name||r));c=d.Q;if(d=d.m)k=f[d],k||(k=f[d]=z(e),k.h=z(e.h),k.f=[]),delete a[r];
if(b){d=g;var x=i;d.path=v(d.path||d.location||"");x=v(d.main)||"main";"."!=x.charAt(0)&&(x="./"+x);d.L=w(x,d.name+"/");d.ba=w(x,d.path+"/");d.c=d.config}else d={path:v(g)};d.R=c.split("/").length;c?(k.h[c]=d,k.f.push(c)):k.j=F.P(g,e)}}function d(a){var b=a.h;a.da=RegExp("^("+a.f.sort(function(a,c){return b[a].R<b[c].R}).join("|").replace(/\/|\./g,"\\$&")+")(?=\\/|$)");delete a.f}var e,f;b||(b={});e=z(b,a);e.j=e.baseUrl||"";e.O=e.pluginPath||"curl/plugin";e.h=z(b.h);f=e.plugins=z(b.plugins,a.plugins);
e.f=[];c(a.paths,p);c(a.packages,m);for(var g in f){var k=f[g].f;k&&(f[g].f=k.concat(e.f),d(f[g]))}d(e);return e},A:function(a){var b;(b=a&&a.preloads)&&0<b.length&&C(N,function(){N=F.l(F.e(G,B,b,m))})},o:function(a,b,c){var d,e,f,g;d=b.h;c&&(b.O&&0>a.indexOf("/")&&!(a in d))&&(f=a=v(b.O)+"/"+a);c=oa.test(a)?a:a.replace(b.da,function(b){e=d[b]||{};g=e.c;return e.L&&b==a?(f=e.L,e.ba):e.path||""});return{g:f||a,c:g||G,url:F.P(c,b)}},P:function(a,b){var c=b.j;return c&&!oa.test(a)?v(c)+"/"+a:a},B:function(a){return a+
(na.test(a)?"":".js")},r:function(a,b,c){var d=L.createElement("script");d.onload=d.onreadystatechange=function(c){c=c||s.event;if("load"==c.type||ma[d.readyState])delete M[a.id],d.onload=d.onreadystatechange=d.onerror="",b()};d.onerror=function(){c(Error("Syntax or http error: "+a.url))};d.type=a.M||"text/javascript";d.charset="utf-8";d.async=!a.ca;d.src=a.url;M[a.id]=d;ga.insertBefore(d,ga.firstChild);return d},I:function(a){var b=[],c;("string"==typeof a?a:a.toSource?a.toSource():a.toString()).replace(pa,
"").replace(qa,function(a,e,f){f?c=c==f?B:c:c||b.push(e);return a});return b},X:function(a){var b,c,d,e,f,g;f=a.length;d=a[f-1];e=t(d,"Function")?d.length:-1;2==f?t(a[0],"Array")?c=a[0]:b=a[0]:3==f&&(b=a[0],c=a[1]);!c&&0<e&&(g=m,c=["require","exports","module"].slice(0,e).concat(F.I(d)));return{id:b,q:c||[],v:0<=e?d:function(){return d},p:g}},U:function(a){var b;b=a.v.apply(a.p?a.a:B,a.q);b===B&&a.a&&(b=a.s?a.a=a.s.a:a.a);return b},D:function(a,b){a.v=b.v;a.p=b.p;a.F=b.q;F.l(a)},l:function(a){function b(a,
b,c){g[b]=a;c&&l(a,b)}function c(b,c){var d,e,f,g;d=D(1,function(a){e(a);j(a,c)});e=D(1,function(a){l(a,c)});f=F.V(b,a);(g=f instanceof A&&f.a)&&e(g);C(f,d,a.b,a.a&&function(a){f.a&&(a==ha?e(f.a):a==ia&&d(f.a))})}function d(){a.d(g)}var e,f,g,k,h,l,j;g=[];f=a.F;k=f.length;0==f.length&&d();l=D(k,b,function(){a.H&&a.H(g)});j=D(k,b,d);for(e=0;e<k;e++)h=f[e],h in ra?(j(ra[h](a),e,m),a.a&&a.u(ha)):h?c(h,e):j(B,e,m);return a},W:function(a){F.K(a);F.r(a,function(){var b=H;H=B;a.ga!==p&&(!b||b.G?a.b(Error(b&&
b.G||"define() missing or duplicated: "+a.url)):F.D(a,b))},a.b);return a},V:function(a,b){var c,d,e,f,g,k,h,l,j;c=b.fa;d=b.aa;e=da(a);k=e.Q;f=c(e.m||k);h=F.o(f,G,!!e.m);if(e.m)g=f;else if(g=h.c.moduleLoader)k=f,f=g,h=F.o(g,G);e=I[f];f in I||(e=I[f]=F.C(h.c,f,d,h.g),e.url=F.B(h.url),F.W(e));f==g&&(l=new A,j=G.plugins[g]||G,C(e,function(a){var b,e,f;f=a.dynamic;k="normalize"in a?a.normalize(k,c,j)||"":c(k);e=g+"!"+k;b=I[e];if(!(e in I)){b=F.S(j,e,d,k);f||(I[e]=b);var h=function(a){b.d(a);f||(I[e]=a)};
-h.resolve=h;h.reject=b.b;a.load(k,b.n,h,j)}l!=b&&C(b,l.d,l.b,l.u)},l.b));return l||e},$:function(){var a;if(!t(s.opera,"Opera"))for(var b in M)if(ma[M[b].readyState]==ja){a=b;break}return a}};ra={require:F.Z,exports:F.J,module:F.Y};E.version="0.6.6";"function"==typeof define&&(K=define);"function"==typeof G&&(J=G,G=p);G=F.c(G);F.A(G);I.curl=E;I["curl/_privileged"]={core:F,cache:I,cfg:G,_define:fa,_curl:E,Promise:A};var O=this.document;
+h.resolve=h;h.reject=b.b;a.load(k,b.n,h,j)}l!=b&&C(b,l.d,l.b,l.u)},l.b));return l||e},$:function(){var a;if(!t(s.opera,"Opera"))for(var b in M)if(ma[M[b].readyState]==la){a=b;break}return a}};ra={require:F.Z,exports:F.J,module:F.Y};E.version="0.6.7";"function"==typeof define&&(K=define);"function"==typeof G&&(J=G,G=p);G=F.c(G);F.A(G);I.curl=E;I["curl/_privileged"]={core:F,cache:I,cfg:G,_define:fa,_curl:E,Promise:A};var O=this.document;
function sa(){if(!O.body)return p;P||(P=O.createTextNode(""));try{O.body.removeChild(O.body.appendChild(P));P=ta;return m}catch(a){return p}}function Q(){var a;a=ua[O[va]]&&sa();if(!R&&a){R=m;for(clearTimeout(wa);xa=ya.pop();)xa();za&&(O[va]="complete");for(var b;b=Aa.shift();)b()}return a}function Ba(){Q();R||(wa=setTimeout(Ba,Ca))}var va="readyState",ua={loaded:1,interactive:1,complete:1},Aa=[],za=O&&"string"!=typeof O[va],R=p,Ca=10,S,xa,ya=[],wa,ta,P;
S="addEventListener"in this?function(a,b){a.addEventListener(b,Q,p);return function(){a.removeEventListener(b,Q,p)}}:function(a,b){a.attachEvent("on"+b,Q);return function(){a.detachEvent(b,Q)}};O&&!Q()&&(ya=[S(this,"load"),S(O,"readystatechange"),S(this,"DOMContentLoaded")],wa=setTimeout(Ba,Ca));define("curl/domReady",function(){function a(a){R?a():Aa.push(a)}a.then=a;a.amd=m;return a});var Da;
define("curl/shim/dojo16",["curl/_privileged","curl/domReady"],function(a,b){function c(a){a.ready||(a.ready=function(a){b(a)});a.nameToUrl||(a.nameToUrl=function(b,c){return a.toUrl(b+(c||""))});a.cache||(a.cache={})}var d=a._curl,e=a.core.e;c(d);typeof Da=="undefined"&&(Da=d);a.core.e=function(){var a=e.apply(this,arguments);c(a.n);return a};return m});var Ea=this.document;function Fa(a){try{return eval(a)}catch(b){}}
define("js",["curl/_privileged"],function(a){function b(b,c,d){function e(){g||(f<new Date?d():setTimeout(e,10))}var f,g,u;f=(new Date).valueOf()+(b.ea||3E5);d&&b.a&&setTimeout(e,10);u=a.core.r(b,function(){g=m;if(b.a)b.w=Fa(b.a);!b.a||b.w?c(u):d()},function(a){g=m;d(a)})}function c(a,d){b(a,function(){var b=e.shift();g=e.length>0;b&&c.apply(o,b);d.resolve(a.w||m)},function(a){d.reject(a)})}var d={},e=[],f=Ea&&Ea.createElement("script").async==m,g;return{dynamic:m,load:function(a,h,l,j){var n,q,u,
r;n=a.indexOf("!order")>0;q=a.indexOf("!exports=");u=q>0&&a.substr(q+9);r="prefetch"in j?j.prefetch:m;a=n||q>0?a.substr(0,a.indexOf("!")):a;if(a in d)l(d[a]);else{d[a]=i;h={name:a,url:h.toUrl(a.lastIndexOf(".")<=a.lastIndexOf("/")?a+".js":a),ca:n,a:u,ea:j.timeout};j={resolve:function(b){d[a]=b;(l.resolve||l)(b)},reject:l.reject||function(a){throw a;}};if(n&&!f&&g){e.push([h,j]);if(r){h.M="text/cache";b(h,function(a){a&&a.parentNode.removeChild(a)},function(){});h.M=""}}else{g=g||n;c(h,j)}}}}});
define("text",function(){function a(){if(typeof XMLHttpRequest!=="undefined")a=function(){return new XMLHttpRequest};else for(var b=a=function(){throw Error("getXhr(): XMLHttpRequest not available");};c.length>0&&a===b;)(function(b){try{new ActiveXObject(b);a=function(){return new ActiveXObject(b)}}catch(c){}})(c.shift());return a()}function b(a){throw a;}var c=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"];return{load:function(c,e,f){var g=f.d||f,k=f.b||b,c=e.toUrl(c),h=a();h.open("GET",
c,m);h.onreadystatechange=function(){h.readyState===4&&(h.status<400?g(h.responseText):k(Error("fetchText() failed. status: "+h.statusText)))};h.send(o)},"plugin-builder":"./builder/text"}});define("async",function(){return{load:function(a,b,c){function d(a){typeof c.d=="function"?c.d(a):c(a)}function e(a){typeof c.b=="function"&&c.b(a)}b([a],function(a){typeof a.z=="function"?a.z(function(b){arguments.length==0&&(b=a);d(b)},e):d(a)})},analyze:function(a,b,c){c(a)}}});
-function Ga(a,b){var c=a.link,d,e,f=p;try{d=c.sheet||c.styleSheet;if((f=(e=d.cssRules||d.rules)?e.length>0:e!==Ha)&&{}.toString.call(window.ka)=="[object Chrome]"){d.insertRule("#_cssx_load_test{margin-top:-5px;}",0);if(!T){T=U[Ia]("div");T.id="_cssx_load_test";V.appendChild(T)}f=U.defaultView.getComputedStyle(T,o).marginTop=="-5px";d.deleteRule(0)}}catch(g){f=g.code==1E3||g.message.match(/security|denied/i)}if(f){c=a.link;c[Ja]=c[Ka]=o;b()}else La||setTimeout(function(){Ga(a,b)},a.ha)}
+function Ga(a,b){var c=a.link,d,e,f=p;try{d=c.sheet||c.styleSheet;if((f=(e=d.cssRules||d.rules)?e.length>0:e!==Ha)&&{}.toString.call(window.ja)=="[object Chrome]"){d.insertRule("#_cssx_load_test{margin-top:-5px;}",0);if(!T){T=U[Ia]("div");T.id="_cssx_load_test";V.appendChild(T)}f=U.defaultView.getComputedStyle(T,o).marginTop=="-5px";d.deleteRule(0)}}catch(g){f=g.code==1E3||g.message.match(/security|denied/i)}if(f){c=a.link;c[Ja]=c[Ka]=o;b()}else La||setTimeout(function(){Ga(a,b)},a.ha)}
function Ma(a,b){function c(){if(!d){d=m;b()}}var d,e=a.link;e[Ja]=e[Ka]=function(){if(!e.readyState||e.readyState=="complete"){Na["event-link-onload"]=m;var b=a.link;b[Ja]=b[Ka]=o;c()}};Na["event-link-onload"]||Ga(a,c)}
function W(a){clearTimeout(W.T);if(W.i)W.i.push(a);else{W.i=[a];X=U.createStyleSheet?U.createStyleSheet():V.appendChild(U.createElement("style"))}W.T=setTimeout(function(){var a,c;a=X;X=Ha;c=W.i.join("\n");W.i=Ha;c=c.replace(/.+charset[^;]+;/g,"");"cssText"in a?a.cssText=c:a.appendChild(U.createTextNode(c))},0);return X}
function Oa(a){return{cssRules:function(){return a.cssRules||a.rules},insertRule:a.insertRule||function(b,c){var d=b.split(/\{|\}/g);a.addRule(d[0],d[1],c);return c},deleteRule:a.deleteRule||function(b){a.removeRule(b);return b},sheet:function(){return a}}}var Ja="onreadystatechange",Ka="onload",Ia="createElement",La=p,Ha,Pa={},Na={},Qa=/^\/|^[^:]*:\/\//,Ra=/url\s*\(['"]?([^'"\)]*)['"]?\)/g,U=this.document,V;U&&(V=U.head||(U.head=U.getElementsByTagName("head")[0]));var Y,T,X;
define("css",{normalize:function(a,b){var c,d;if(!a)return a;c=a.split(",");d=[];for(var e=0,f=c.length;e<f;e++)d.push(b(c[e]));return d.join(",")},load:function(a,b,c,d){function e(){--g==0&&setTimeout(function(){c(Oa(n.sheet||n.styleSheet))},0)}var f=(a||"").split(","),g=f.length;if(a)for(var k=f.length-1,h;k>=0;k--,h=m){for(var a=f[k],a=a.split("!"),l=i,j=1,l=i;l=a[j++];){l=l.split("=",2);a[l[0]]=l.length==2?l[1]:m}var j=a.shift(),j=b.toUrl(j.lastIndexOf(".")<=j.lastIndexOf("/")?j+".css":j),n,
l=U;if(document.createStyleSheet){Y||(Y=document.createStyleSheet());if(document.styleSheets.length>=30){var q=i,u=i,r=i,x=0,r=Y;Y=o;for(u=document.getElementsByTagName("link");q=u[x];)if(q.getAttribute("_curl_movable")){r.addImport(q.href);q.parentNode&&q.parentNode.removeChild(q)}else x++}}l=l[Ia]("link");l.rel="stylesheet";l.type="text/css";l.setAttribute("_curl_movable",m);n=l;l={link:n,url:j,ha:d.cssWatchPeriod||50};("nowait"in a?a.nowait!="false":d.cssDeferLoad)?c(Oa(n.sheet||n.styleSheet)):
Ma(l,e);n.href=j;h?V.insertBefore(n,Pa[h].previousSibling):V.appendChild(n);Pa[j]=n}else c({translateUrls:function(a,c){var d;d=b.toUrl(c);var e=d=d.substr(0,d.lastIndexOf("/")+1);return a.replace(Ra,function(a,b){var c=b;Qa.test(c)||(c=e+c);return'url("'+c+'")'})},injectStyle:function(a){return W(a)},proxySheet:function(a){if(a.sheet)a=a.sheet;return Oa(a)}})},"plugin-builder":"./builder/css"});var Z=this.document,Sa=/^\/\//,Ta;Z&&(Ta=Z.head||(Z.head=Z.getElementsByTagName("head")[0]));
define("link",{load:function(a,b,c,d){a=b.toUrl(a.lastIndexOf(".")<=a.lastIndexOf("/")?a+".css":a);d=a=(d="fixSchemalessUrls"in d?d.fixSchemalessUrls:Z.location.protocol)?a.replace(Sa,d+"//"):a;a=Z.createElement("link");a.rel="stylesheet";a.type="text/css";a.href=d;Ta.appendChild(a);c(a.sheet||a.styleSheet)}});define("domReady",["curl/domReady"],function(a){return{load:function(b,c,d){a(d)}}});var $=this.document;function Ua(a){eval(a)}
-define("curl/loader/cjsm11",function(){function a(b,d){a="text"in b?function(a,b){a.text=b}:function(a,b){a.appendChild($.createTextNode(b))};a(b,d)}var b;b=$&&($.head||$.getElementsByTagName("head")[0]);return{load:function(c,d,e,f){d(["text!"+c+".js","curl/_privileged"],function(g,k){var h;h=k.core.I(g);d(h,function(){var h=g,j=f.injectSourceUrl!==p&&d.qa(c),j=j?"////@ sourceURL="+j.replace(/\s/g,"%20")+".js":"";g="define('"+c+"',['require','exports','module'],function(require,exports,module){"+
-h+"\n});\n"+j+"\n";if(f.injectScript){h=g;j=$.createElement("script");a(j,h);j.charset="utf-8";b.insertBefore(j,b.firstChild)}else Ua(g);e(d(c))})})}}});define.ia.pa=m;
+define("curl/loader/cjsm11",function(){function a(b,d){a="text"in b?function(a,b){a.text=b}:function(a,b){a.appendChild($.createTextNode(b))};a(b,d)}var b;b=$&&($.head||$.getElementsByTagName("head")[0]);return{load:function(c,d,e,f){d(["text!"+c+".js","curl/_privileged"],function(g,k){var h;h=k.core.I(g);d(h,function(){var h=g,j=f.injectSourceUrl!==p&&d.oa(c),j=j?"////@ sourceURL="+j.replace(/\s/g,"%20")+".js":"";g="define('"+c+"',['require','exports','module'],function(require,exports,module){"+
+h+"\n});\n"+j+"\n";if(f.injectScript){h=g;j=$.createElement("script");a(j,h);j.charset="utf-8";b.insertBefore(j,b.firstChild)}else Ua(g);e(d(c))})})}}});define.amd.na=m;
(function(a,b){define("curl/shim/ssjs",function(c){function d(a,c,d){try{b(a.url);c()}catch(e){d(e)}}function e(b,c,d){var e;try{e=b.url.replace(/\.js$/,"");a(e);c()}catch(f){d(f)}}function f(b,c,d){var e,b=a("url").parse(b.url,p,m);e="";q.get(b,function(a){a.t("data",function(a){e=e+a}).t("end",function(){k(e);c()}).t("error",d)}).t("error",d)}function g(a){throw Error("ssjs: unable to load module in current environment: "+a.url);}function k(a){eval(a)}var h,l,j,n,q,u,r;if(!(typeof window=="object"&&
-(window.la||window.navigator))){c=c("curl/_privileged");h=c.ja;l=/^\w+:/;j=/(^\w+:)?.*$/;n=(h.k&&h.k[h.k.length-1]!=":"?h.k+":":h.k)||h.j&&h.j.replace(j,function(a,b){return b})||"http:";if(b)u=r=d;else if(a){u=e;try{q=a("http");r=f}catch(x){r=g}}else u=r=g;c.ma.r=function(a,b,c){if(/^\/\//.test(a.url))a.url=n+a.url;return l.test(a.url)?r(a,b,c):u(a,b,c)}}})})(Da,i);
+(window.ka||window.navigator))){c=c("curl/_privileged");h=c.ia;l=/^\w+:/;j=/(^\w+:)?.*$/;n=(h.k&&h.k[h.k.length-1]!=":"?h.k+":":h.k)||h.j&&h.j.replace(j,function(a,b){return b})||"http:";if(b)u=r=d;else if(a){u=e;try{q=a("http");r=f}catch(x){r=g}}else u=r=g;c.la.r=function(a,b,c){if(/^\/\//.test(a.url))a.url=n+a.url;return l.test(a.url)?r(a,b,c):u(a,b,c)}}})})(Da,i);
+}());
View
11 dist/curl-with-js-and-domReady/curl.js
@@ -1,22 +1,23 @@
-/*
+(function(){/*
MIT License (c) copyright B Cavalier & J Hann */
var h=!0,l=!1,m=this.window||global;function n(){}function p(a,b){return 0==aa.call(a).indexOf("[object "+b)}function q(a){return a&&"/"==a.charAt(a.length-1)?a.substr(0,a.length-1):a}function r(a,b){var c,d,e;d=1;a=a.replace(ba,function(a,b,i,c){i&&d++;e=h;return c||""});return e?(c=b.split("/"),c.splice(c.length-d,d),c.concat(a||[]).join("/")):a}function t(a){var b=a.indexOf("!");return{L:a.substr(b+1),j:0<=b&&a.substr(0,b)}}function u(){}
-function w(a,b){u.prototype=a||y;var c=new u;u.prototype=y;for(var d in b)c[d]=b[d];return c}function A(){function a(a,b,e){d.push([a,b,e])}function b(a,b){for(var e,c=0;e=d[c++];)(e=e[a])&&e(b)}var c,d,e;c=this;d=[];e=function(c,f){a=c?function(a){a&&a(f)}:function(a,b){b&&b(f)};e=n;b(c?0:1,f);b=n;d=B};this.$=function(b,e,c){a(b,e,c)};this.h=function(a){c.r=a;e(h,a)};this.d=function(a){c.ea=a;e(l,a)};this.o=function(a){b(2,a)}}function C(a,b,c,d){a instanceof A?a.$(b,c,d):b(a)}
+function w(a,b){u.prototype=a||y;var c=new u;u.prototype=y;for(var d in b)c[d]=b[d];return c}function A(){function a(a,b,e){d.push([a,b,e])}function b(a,b){for(var e,c=0;e=d[c++];)(e=e[a])&&e(b)}var c,d,e;c=this;d=[];e=function(c,f){a=c?function(a){a&&a(f)}:function(a,b){b&&b(f)};e=n;b(c?0:1,f);b=n;d=B};this.$=function(b,e,c){a(b,e,c)};this.h=function(a){c.r=a;e(h,a)};this.d=function(a){c.da=a;e(l,a)};this.o=function(a){b(2,a)}}function C(a,b,c,d){a instanceof A?a.$(b,c,d):b(a)}
function D(a,b,c){var d;return function(){0<=--a&&b&&(d=b.apply(B,arguments));0==a&&c&&c(d);return d}}function E(){function a(b,e,c){var f;f=G.g(H,B,[].concat(b));this.then=b=function(a,b){C(f,function(b){a&&a.apply(B,b)},function(a){if(b)b(a);else throw a;});return this};this.next=function(b,e){return new a(b,e,f)};e&&b(e);C(c,function(){G.i(f)})}var b=[].slice.call(arguments),c;p(b[0],"Object")&&(c=b.shift(),H=G.b(c,H),G.t(c));return new a(b[0],b[1])}
function I(a){var b=a.id;if(b==B)if(J!==B)J={A:"Multiple anonymous defines in url"};else if(!(b=G.V()))J=a;if(b!=B){var c=K[b];b in K||(c=G.k(b,H).b,c=K[b]=G.v(c,b));if(!(c instanceof A))throw Error("duplicate define: "+b);c.ca=l;G.w(c,a)}}
var H=m.curl,L,M,N=m.document,O=N&&(N.head||N.getElementsByTagName("head")[0]),P={},Q={},ca={},R={},y={},aa=y.toString,B,da={loaded:1,interactive:ca,complete:1},K={},S=l,J,ea=/\?/,fa=/^\/|^[^:]+:\/\//,ba=/(\.)(\.?)(?:$|\/([^\.\/]+.*)?)/g,ga=/\/\*[\s\S]*?\*\/|(?:[^\\])\/\/.*?[\n\r]/g,ha=/require\s*\(\s*["']([^"']+)["']\s*\)|(?:[^\\]?)(["'])/g,T,G;
G={g:function(a,b,c,d){function e(a){return r(a,f.e)}function g(b,c){var g,k,s,x;g=c&&function(a){c.apply(B,a)};if(p(b,"String")){k=e(b);s=K[k];x=s instanceof A&&s.a;if(!(k in K))throw Error("Module not resolved: "+k);if(g)throw Error("require(id, callback) not allowed");return x||s}C(G.i(G.g(a,f.e,b,d)),g)}var f;f=new A;f.e=f.id=b||"";f.W=d;f.z=c;f.p=g;g.toUrl=function(b){return G.k(e(b),a).url};f.ba=e;return f},v:function(a,b,c,d){var e,g,f;e=G.g(a,b,B,c);e.e=d==B?b:d;g=e.h;f=D(1,function(a){e.m=
a;try{return G.O(e)}catch(b){e.d(b)}});e.h=function(a){C(c||S,function(){g(K[e.id]=f(a))})};e.B=function(a){C(c||S,function(){e.a&&(f(a),e.o(Q))})};return e},N:function(a,b,c,d){a=G.g(a,b,B,c);a.e=d;return a},U:function(a){return a.p},C:function(a){return a.a||(a.a={})},T:function(a){var b=a.n;b||(b=a.n={id:a.id,uri:G.D(a),exports:G.C(a)},b.a=b.exports);return b},D:function(a){return a.url||(a.url=G.u(a.p.toUrl(a.id)))},b:function(a){var b,c,d;(b=a)||(a={});c=a.apiName||"curl";d=a.apiContext||m;if(d!=
-m||"curl"!=c?d[c]:L&&b)throw Error(c+" already exists");d[c]=E;L&&b&&(m.curl=L);c=a.defineName||"define";d=a.defineContext||m;if(d!=m||"define"!=c?d[c]:M&&b)throw Error(c+" already exists");d[c]=c=function(){var a=G.S(arguments);I(a)};M&&b&&(m.define=M);c.amd={plugins:h,jQuery:h,da:"0.6.6"};b&&(G.b=G.I);return G.I(a)},I:function(a,b){function c(a,b){var c,d,f,i,v;for(v in a){f=a[v];f.name=f.id||f.name||v;i=e;d=t(q(f.name||v));c=d.L;if(d=d.j)i=g[d],i||(i=g[d]=w(e),i.f=w(e.f),i.c=[]),delete a[v];if(b){d=
-f;var z=void 0;d.path=q(d.path||d.location||"");z=q(d.main)||"main";"."!=z.charAt(0)&&(z="./"+z);d.G=r(z,d.name+"/");d.X=r(z,d.path+"/");d.b=d.config}else d={path:q(f)};d.M=c.split("/").length;c?(i.f[c]=d,i.c.push(c)):i.s=G.K(f,e)}}function d(a){var b=a.f;a.Z=RegExp("^("+a.c.sort(function(a,c){return b[a].M<b[c].M}).join("|").replace(/\/|\./g,"\\$&")+")(?=\\/|$)");delete a.c}var e,g;b||(b={});e=w(b,a);e.s=e.baseUrl||"";e.J=e.pluginPath||"curl/plugin";e.f=w(b.f);g=e.plugins=w(b.plugins,a.plugins);
+m||"curl"!=c?d[c]:L&&b)throw Error(c+" already exists");d[c]=E;L&&b&&(m.curl=L);c=a.defineName||"define";d=a.defineContext||m;if(d!=m||"define"!=c?d[c]:M&&b)throw Error(c+" already exists");d[c]=c=function(){var a=G.S(arguments);I(a)};M&&b&&(m.define=M);c.amd={plugins:h,jQuery:h,curl:"0.6.7"};b&&(G.b=G.I);return G.I(a)},I:function(a,b){function c(a,b){var c,d,f,i,v;for(v in a){f=a[v];f.name=f.id||f.name||v;i=e;d=t(q(f.name||v));c=d.L;if(d=d.j)i=g[d],i||(i=g[d]=w(e),i.f=w(e.f),i.c=[]),delete a[v];
+if(b){d=f;var z=void 0;d.path=q(d.path||d.location||"");z=q(d.main)||"main";"."!=z.charAt(0)&&(z="./"+z);d.G=r(z,d.name+"/");d.X=r(z,d.path+"/");d.b=d.config}else d={path:q(f)};d.M=c.split("/").length;c?(i.f[c]=d,i.c.push(c)):i.s=G.K(f,e)}}function d(a){var b=a.f;a.Z=RegExp("^("+a.c.sort(function(a,c){return b[a].M<b[c].M}).join("|").replace(/\/|\./g,"\\$&")+")(?=\\/|$)");delete a.c}var e,g;b||(b={});e=w(b,a);e.s=e.baseUrl||"";e.J=e.pluginPath||"curl/plugin";e.f=w(b.f);g=e.plugins=w(b.plugins,a.plugins);
e.c=[];c(a.paths,l);c(a.packages,h);for(var f in g){var i=g[f].c;i&&(g[f].c=i.concat(e.c),d(g[f]))}d(e);return e},t:function(a){var b;(b=a&&a.preloads)&&0<b.length&&C(S,function(){S=G.i(G.g(H,B,b,h))})},k:function(a,b,c){var d,e,g,f;d=b.f;c&&(b.J&&0>a.indexOf("/")&&!(a in d))&&(g=a=q(b.J)+"/"+a);c=fa.test(a)?a:a.replace(b.Z,function(b){e=d[b]||{};f=e.b;return e.G&&b==a?(g=e.G,e.X):e.path||""});return{e:g||a,b:f||H,url:G.K(c,b)}},K:function(a,b){var c=b.s;return c&&!fa.test(a)?q(c)+"/"+a:a},u:function(a){return a+
(ea.test(a)?"":".js")},F:function(a,b,c){var d=N.createElement("script");d.onload=d.onreadystatechange=function(c){c=c||m.event;if("load"==c.type||da[d.readyState])delete R[a.id],d.onload=d.onreadystatechange=d.onerror="",b()};d.onerror=function(){c(Error("Syntax or http error: "+a.url))};d.type=a.H||"text/javascript";d.charset="utf-8";d.async=!a.Y;d.src=a.url;R[a.id]=d;O.insertBefore(d,O.firstChild);return d},P:function(a){var b=[],c;("string"==typeof a?a:a.toSource?a.toSource():a.toString()).replace(ga,
"").replace(ha,function(a,e,g){g?c=c==g?B:c:c||b.push(e);return a});return b},S:function(a){var b,c,d,e,g,f;g=a.length;d=a[g-1];e=p(d,"Function")?d.length:-1;2==g?p(a[0],"Array")?c=a[0]:b=a[0]:3==g&&(b=a[0],c=a[1]);!c&&0<e&&(f=h,c=["require","exports","module"].slice(0,e).concat(G.P(d)));return{id:b,m:c||[],q:0<=e?d:function(){return d},l:f}},O:function(a){var b;b=a.q.apply(a.l?a.a:B,a.m);b===B&&a.a&&(b=a.n?a.a=a.n.a:a.a);return b},w:function(a,b){a.q=b.q;a.l=b.l;a.z=b.m;G.i(a)},i:function(a){function b(a,
b,c){f[b]=a;c&&o(a,b)}function c(b,c){var d,e,f,i;d=D(1,function(a){e(a);k(a,c)});e=D(1,function(a){o(a,c)});f=G.Q(b,a);(i=f instanceof A&&f.a)&&e(i);C(f,d,a.d,a.a&&function(a){f.a&&(a==P?e(f.a):a==Q&&d(f.a))})}function d(){a.h(f)}var e,g,f,i,j,o,k;f=[];g=a.z;i=g.length;0==g.length&&d();o=D(i,b,function(){a.B&&a.B(f)});k=D(i,b,d);for(e=0;e<i;e++)j=g[e],j in T?(k(T[j](a),e,h),a.a&&a.o(P)):j?c(j,e):k(B,e,h);return a},R:function(a){G.D(a);G.F(a,function(){var b=J;J=B;a.ca!==l&&(!b||b.A?a.d(Error(b&&
b.A||"define() missing or duplicated: "+a.url)):G.w(a,b))},a.d);return a},Q:function(a,b){var c,d,e,g,f,i,j,o,k;c=b.ba;d=b.W;e=t(a);i=e.L;g=c(e.j||i);j=G.k(g,H,!!e.j);if(e.j)f=g;else if(f=j.b.moduleLoader)i=g,g=f,j=G.k(f,H);e=K[g];g in K||(e=K[g]=G.v(j.b,g,d,j.e),e.url=G.u(j.url),G.R(e));g==f&&(o=new A,k=H.plugins[f]||H,C(e,function(a){var b,e,g;g=a.dynamic;i="normalize"in a?a.normalize(i,c,k)||"":c(i);e=f+"!"+i;b=K[e];if(!(e in K)){b=G.N(k,e,d,i);g||(K[e]=b);var j=function(a){b.h(a);g||(K[e]=a)};
-j.resolve=j;j.reject=b.d;a.load(i,b.p,j,k)}o!=b&&C(b,o.h,o.d,o.o)},o.d));return o||e},V:function(){var a;if(!p(m.opera,"Opera"))for(var b in R)if(da[R[b].readyState]==ca){a=b;break}return a}};T={require:G.U,exports:G.C,module:G.T};E.version="0.6.6";"function"==typeof define&&(M=define);"function"==typeof H&&(L=H,H=l);H=G.b(H);G.t(H);K.curl=E;K["curl/_privileged"]={core:G,cache:K,cfg:H,_define:I,_curl:E,Promise:A};var U=this.document;
+j.resolve=j;j.reject=b.d;a.load(i,b.p,j,k)}o!=b&&C(b,o.h,o.d,o.o)},o.d));return o||e},V:function(){var a;if(!p(m.opera,"Opera"))for(var b in R)if(da[R[b].readyState]==ca){a=b;break}return a}};T={require:G.U,exports:G.C,module:G.T};E.version="0.6.7";"function"==typeof define&&(M=define);"function"==typeof H&&(L=H,H=l);H=G.b(H);G.t(H);K.curl=E;K["curl/_privileged"]={core:G,cache:K,cfg:H,_define:I,_curl:E,Promise:A};var U=this.document;
function ia(){if(!U.body)return l;V||(V=U.createTextNode(""));try{U.body.removeChild(U.body.appendChild(V));V=ja;return h}catch(a){return l}}function W(){var a;a=ka[U[X]]&&ia();if(!Y&&a){Y=h;for(clearTimeout(Z);la=ma.pop();)la();na&&(U[X]="complete");for(var b;b=oa.shift();)b()}return a}function pa(){W();Y||(Z=setTimeout(pa,qa))}var X="readyState",ka={loaded:1,interactive:1,complete:1},oa=[],na=U&&"string"!=typeof U[X],Y=l,qa=10,$,la,ma=[],Z,ja,V;
$="addEventListener"in this?function(a,b){a.addEventListener(b,W,l);return function(){a.removeEventListener(b,W,l)}}:function(a,b){a.attachEvent("on"+b,W);return function(){a.detachEvent(b,W)}};U&&!W()&&(ma=[$(this,"load"),$(U,"readystatechange"),$(this,"DOMContentLoaded")],Z=setTimeout(pa,qa));define("curl/domReady",function(){function a(a){Y?a():oa.push(a)}a.then=a;a.amd=h;return a});var ra=this.document;function sa(a){try{return eval(a)}catch(b){}}
define("js",["curl/_privileged"],function(a){function b(b,c,e){function d(){g||(f<new Date?e():setTimeout(d,10))}var f,g,F;f=(new Date).valueOf()+(b.aa||3E5);e&&b.a&&setTimeout(d,10);F=a.core.F(b,function(){g=h;if(b.a)b.r=sa(b.a);!b.a||b.r?c(F):e()},function(a){g=h;e(a)})}function c(a,d){b(a,function(){var b=e.shift();f=e.length>0;b&&c.apply(null,b);d.resolve(a.r||h)},function(a){d.reject(a)})}var d={},e=[],g=ra&&ra.createElement("script").async==h,f;return{dynamic:h,load:function(a,j,o,k){var s,
x,F,v;s=a.indexOf("!order")>0;x=a.indexOf("!exports=");F=x>0&&a.substr(x+9);v="prefetch"in k?k.prefetch:h;a=s||x>0?a.substr(0,a.indexOf("!")):a;if(a in d)o(d[a]);else{d[a]=void 0;j={name:a,url:j.toUrl(a.lastIndexOf(".")<=a.lastIndexOf("/")?a+".js":a),Y:s,a:F,aa:k.timeout};k={resolve:function(b){d[a]=b;(o.resolve||o)(b)},reject:o.reject||function(a){throw a;}};if(s&&!g&&f){e.push([j,k]);if(v){j.H="text/cache";b(j,function(a){a&&a.parentNode.removeChild(a)},function(){});j.H=""}}else{f=f||s;c(j,k)}}}}});
define("domReady",["curl/domReady"],function(a){return{load:function(b,c,d){a(d)}}});
+}());
View
13 dist/curl/curl.js
@@ -1,17 +1,18 @@
-/*
+(function(){/*
MIT License (c) copyright B Cavalier & J Hann */
var h=!0,k=!1,l=this.window||global;function m(){}function p(a,b){return 0==q.call(a).indexOf("[object "+b)}function r(a){return a&&"/"==a.charAt(a.length-1)?a.substr(0,a.length-1):a}function t(a,b){var c,e,d;e=1;a=a.replace(u,function(a,b,c,j){c&&e++;d=h;return j||""});return d?(c=b.split("/"),c.splice(c.length-e,e),c.concat(a||[]).join("/")):a}function v(a){var b=a.indexOf("!");return{I:a.substr(b+1),j:0<=b&&a.substr(0,b)}}function x(){}
-function y(a,b){x.prototype=a||z;var c=new x;x.prototype=z;for(var e in b)c[e]=b[e];return c}function A(){function a(a,b,d){e.push([a,b,d])}function b(a,b){for(var d,c=0;d=e[c++];)(d=d[a])&&d(b)}var c,e,d;c=this;e=[];d=function(c,f){a=c?function(a){a&&a(f)}:function(a,b){b&&b(f)};d=m;b(c?0:1,f);b=m;e=B};this.X=function(b,d,c){a(b,d,c)};this.h=function(a){c.da=a;d(h,a)};this.d=function(a){c.ca=a;d(k,a)};this.o=function(a){b(2,a)}}function C(a,b,c,e){a instanceof A?a.X(b,c,e):b(a)}
+function y(a,b){x.prototype=a||z;var c=new x;x.prototype=z;for(var e in b)c[e]=b[e];return c}function A(){function a(a,b,d){e.push([a,b,d])}function b(a,b){for(var d,c=0;d=e[c++];)(d=d[a])&&d(b)}var c,e,d;c=this;e=[];d=function(c,f){a=c?function(a){a&&a(f)}:function(a,b){b&&b(f)};d=m;b(c?0:1,f);b=m;e=B};this.X=function(b,d,c){a(b,d,c)};this.h=function(a){c.ca=a;d(h,a)};this.d=function(a){c.ba=a;d(k,a)};this.o=function(a){b(2,a)}}function C(a,b,c,e){a instanceof A?a.X(b,c,e):b(a)}
function D(a,b,c){var e;return function(){0<=--a&&b&&(e=b.apply(B,arguments));0==a&&c&&c(e);return e}}function E(){function a(b,d,c){var f;f=F.g(G,B,[].concat(b));this.then=b=function(a,b){C(f,function(b){a&&a.apply(B,b)},function(a){if(b)b(a);else throw a;});return this};this.next=function(b,d){return new a(b,d,f)};d&&b(d);C(c,function(){F.i(f)})}var b=[].slice.call(arguments),c;p(b[0],"Object")&&(c=b.shift(),G=F.b(c,G),F.s(c));return new a(b[0],b[1])}
function I(a){var b=a.id;if(b==B)if(J!==B)J={z:"Multiple anonymous defines in url"};else if(!(b=F.S()))J=a;if(b!=B){var c=K[b];b in K||(c=F.k(b,G).b,c=K[b]=F.u(c,b));if(!(c instanceof A))throw Error("duplicate define: "+b);c.Z=k;F.v(c,a)}}
var G=l.curl,L,M,N=l.document,O=N&&(N.head||N.getElementsByTagName("head")[0]),P={},Q={},R={},S={},z={},q=z.toString,B,T={loaded:1,interactive:R,complete:1},K={},U=k,J,W=/\?/,X=/^\/|^[^:]+:\/\//,u=/(\.)(\.?)(?:$|\/([^\.\/]+.*)?)/g,Y=/\/\*[\s\S]*?\*\/|(?:[^\\])\/\/.*?[\n\r]/g,Z=/require\s*\(\s*["']([^"']+)["']\s*\)|(?:[^\\]?)(["'])/g,$,F;
F={g:function(a,b,c,e){function d(a){return t(a,f.e)}function g(b,c){var g,n,H,V;g=c&&function(a){c.apply(B,a)};if(p(b,"String")){n=d(b);H=K[n];V=H instanceof A&&H.a;if(!(n in K))throw Error("Module not resolved: "+n);if(g)throw Error("require(id, callback) not allowed");return V||H}C(F.i(F.g(a,f.e,b,e)),g)}var f;f=new A;f.e=f.id=b||"";f.T=e;f.w=c;f.p=g;g.toUrl=function(b){return F.k(d(b),a).url};f.Y=d;return f},u:function(a,b,c,e){var d,g,f;d=F.g(a,b,B,c);d.e=e==B?b:e;g=d.h;f=D(1,function(a){d.m=
a;try{return F.L(d)}catch(b){d.d(b)}});d.h=function(a){C(c||U,function(){g(K[d.id]=f(a))})};d.A=function(a){C(c||U,function(){d.a&&(f(a),d.o(Q))})};return d},K:function(a,b,c,e){a=F.g(a,b,B,c);a.e=e;return a},R:function(a){return a.p},B:function(a){return a.a||(a.a={})},Q:function(a){var b=a.n;b||(b=a.n={id:a.id,uri:F.C(a),exports:F.B(a)},b.a=b.exports);return b},C:function(a){return a.url||(a.url=F.t(a.p.toUrl(a.id)))},b:function(a){var b,c,e;(b=a)||(a={});c=a.apiName||"curl";e=a.apiContext||l;if(e!=
-l||"curl"!=c?e[c]:L&&b)throw Error(c+" already exists");e[c]=E;L&&b&&(l.curl=L);c=a.defineName||"define";e=a.defineContext||l;if(e!=l||"define"!=c?e[c]:M&&b)throw Error(c+" already exists");e[c]=c=function(){var a=F.P(arguments);I(a)};M&&b&&(l.define=M);c.amd={plugins:h,jQuery:h,$:"0.6.6"};b&&(F.b=F.F);return F.F(a)},F:function(a,b){function c(a,b){var c,e,f,s,i;for(i in a){f=a[i];f.name=f.id||f.name||i;s=d;e=v(r(f.name||i));c=e.I;if(e=e.j)s=g[e],s||(s=g[e]=y(d),s.f=y(d.f),s.c=[]),delete a[i];if(b){e=
-f;var w=void 0;e.path=r(e.path||e.location||"");w=r(e.main)||"main";"."!=w.charAt(0)&&(w="./"+w);e.D=t(w,e.name+"/");e.V=t(w,e.path+"/");e.b=e.config}else e={path:r(f)};e.J=c.split("/").length;c?(s.f[c]=e,s.c.push(c)):s.r=F.H(f,d)}}function e(a){var b=a.f;a.W=RegExp("^("+a.c.sort(function(a,c){return b[a].J<b[c].J}).join("|").replace(/\/|\./g,"\\$&")+")(?=\\/|$)");delete a.c}var d,g;b||(b={});d=y(b,a);d.r=d.baseUrl||"";d.G=d.pluginPath||"curl/plugin";d.f=y(b.f);g=d.plugins=y(b.plugins,a.plugins);
+l||"curl"!=c?e[c]:L&&b)throw Error(c+" already exists");e[c]=E;L&&b&&(l.curl=L);c=a.defineName||"define";e=a.defineContext||l;if(e!=l||"define"!=c?e[c]:M&&b)throw Error(c+" already exists");e[c]=c=function(){var a=F.P(arguments);I(a)};M&&b&&(l.define=M);c.amd={plugins:h,jQuery:h,curl:"0.6.7"};b&&(F.b=F.F);return F.F(a)},F:function(a,b){function c(a,b){var c,e,f,s,i;for(i in a){f=a[i];f.name=f.id||f.name||i;s=d;e=v(r(f.name||i));c=e.I;if(e=e.j)s=g[e],s||(s=g[e]=y(d),s.f=y(d.f),s.c=[]),delete a[i];
+if(b){e=f;var w=void 0;e.path=r(e.path||e.location||"");w=r(e.main)||"main";"."!=w.charAt(0)&&(w="./"+w);e.D=t(w,e.name+"/");e.V=t(w,e.path+"/");e.b=e.config}else e={path:r(f)};e.J=c.split("/").length;c?(s.f[c]=e,s.c.push(c)):s.r=F.H(f,d)}}function e(a){var b=a.f;a.W=RegExp("^("+a.c.sort(function(a,c){return b[a].J<b[c].J}).join("|").replace(/\/|\./g,"\\$&")+")(?=\\/|$)");delete a.c}var d,g;b||(b={});d=y(b,a);d.r=d.baseUrl||"";d.G=d.pluginPath||"curl/plugin";d.f=y(b.f);g=d.plugins=y(b.plugins,a.plugins);
d.c=[];c(a.paths,k);c(a.packages,h);for(var f in g){var i=g[f].c;i&&(g[f].c=i.concat(d.c),e(g[f]))}e(d);return d},s:function(a){var b;(b=a&&a.preloads)&&0<b.length&&C(U,function(){U=F.i(F.g(G,B,b,h))})},k:function(a,b,c){var e,d,g,f;e=b.f;c&&(b.G&&0>a.indexOf("/")&&!(a in e))&&(g=a=r(b.G)+"/"+a);c=X.test(a)?a:a.replace(b.W,function(b){d=e[b]||{};f=d.b;return d.D&&b==a?(g=d.D,d.V):d.path||""});return{e:g||a,b:f||G,url:F.H(c,b)}},H:function(a,b){var c=b.r;return c&&!X.test(a)?r(c)+"/"+a:a},t:function(a){return a+
-(W.test(a)?"":".js")},U:function(a,b,c){var e=N.createElement("script");e.onload=e.onreadystatechange=function(c){c=c||l.event;if("load"==c.type||T[e.readyState])delete S[a.id],e.onload=e.onreadystatechange=e.onerror="",b()};e.onerror=function(){c(Error("Syntax or http error: "+a.url))};e.type=a.aa||"text/javascript";e.charset="utf-8";e.async=!a.ba;e.src=a.url;S[a.id]=e;O.insertBefore(e,O.firstChild);return e},M:function(a){var b=[],c;("string"==typeof a?a:a.toSource?a.toSource():a.toString()).replace(Y,
+(W.test(a)?"":".js")},U:function(a,b,c){var e=N.createElement("script");e.onload=e.onreadystatechange=function(c){c=c||l.event;if("load"==c.type||T[e.readyState])delete S[a.id],e.onload=e.onreadystatechange=e.onerror="",b()};e.onerror=function(){c(Error("Syntax or http error: "+a.url))};e.type=a.$||"text/javascript";e.charset="utf-8";e.async=!a.aa;e.src=a.url;S[a.id]=e;O.insertBefore(e,O.firstChild);return e},M:function(a){var b=[],c;("string"==typeof a?a:a.toSource?a.toSource():a.toString()).replace(Y,
"").replace(Z,function(a,d,g){g?c=c==g?B:c:c||b.push(d);return a});return b},P:function(a){var b,c,e,d,g,f;g=a.length;e=a[g-1];d=p(e,"Function")?e.length:-1;2==g?p(a[0],"Array")?c=a[0]:b=a[0]:3==g&&(b=a[0],c=a[1]);!c&&0<d&&(f=h,c=["require","exports","module"].slice(0,d).concat(F.M(e)));return{id:b,m:c||[],q:0<=d?e:function(){return e},l:f}},L:function(a){var b;b=a.q.apply(a.l?a.a:B,a.m);b===B&&a.a&&(b=a.n?a.a=a.n.a:a.a);return b},v:function(a,b){a.q=b.q;a.l=b.l;a.w=b.m;F.i(a)},i:function(a){function b(a,
b,c){f[b]=a;c&&o(a,b)}function c(b,c){var e,d,f,g;e=D(1,function(a){d(a);n(a,c)});d=D(1,function(a){o(a,c)});f=F.N(b,a);(g=f instanceof A&&f.a)&&d(g);C(f,e,a.d,a.a&&function(a){f.a&&(a==P?d(f.a):a==Q&&e(f.a))})}function e(){a.h(f)}var d,g,f,i,j,o,n;f=[];g=a.w;i=g.length;0==g.length&&e();o=D(i,b,function(){a.A&&a.A(f)});n=D(i,b,e);for(d=0;d<i;d++)j=g[d],j in $?(n($[j](a),d,h),a.a&&a.o(P)):j?c(j,d):n(B,d,h);return a},O:function(a){F.C(a);F.U(a,function(){var b=J;J=B;a.Z!==k&&(!b||b.z?a.d(Error(b&&b.z||
"define() missing or duplicated: "+a.url)):F.v(a,b))},a.d);return a},N:function(a,b){var c,e,d,g,f,i,j,o,n;c=b.Y;e=b.T;d=v(a);i=d.I;g=c(d.j||i);j=F.k(g,G,!!d.j);if(d.j)f=g;else if(f=j.b.moduleLoader)i=g,g=f,j=F.k(f,G);d=K[g];g in K||(d=K[g]=F.u(j.b,g,e,j.e),d.url=F.t(j.url),F.O(d));g==f&&(o=new A,n=G.plugins[f]||G,C(d,function(a){var b,d,g;g=a.dynamic;i="normalize"in a?a.normalize(i,c,n)||"":c(i);d=f+"!"+i;b=K[d];if(!(d in K)){b=F.K(n,d,e,i);g||(K[d]=b);var j=function(a){b.h(a);g||(K[d]=a)};j.resolve=
-j;j.reject=b.d;a.load(i,b.p,j,n)}o!=b&&C(b,o.h,o.d,o.o)},o.d));return o||d},S:function(){var a;if(!p(l.opera,"Opera"))for(var b in S)if(T[S[b].readyState]==R){a=b;break}return a}};$={require:F.R,exports:F.B,module:F.Q};E.version="0.6.6";"function"==typeof define&&(M=define);"function"==typeof G&&(L=G,G=k);G=F.b(G);F.s(G);K.curl=E;K["curl/_privileged"]={core:F,cache:K,cfg:G,_define:I,_curl:E,Promise:A};
+j;j.reject=b.d;a.load(i,b.p,j,n)}o!=b&&C(b,o.h,o.d,o.o)},o.d));return o||d},S:function(){var a;if(!p(l.opera,"Opera"))for(var b in S)if(T[S[b].readyState]==R){a=b;break}return a}};$={require:F.R,exports:F.B,module:F.Q};E.version="0.6.7";"function"==typeof define&&(M=define);"function"==typeof G&&(L=G,G=k);G=F.b(G);F.s(G);K.curl=E;K["curl/_privileged"]={core:F,cache:K,cfg:G,_define:I,_curl:E,Promise:A};
+}());
View
2 package.json
@@ -1,6 +1,6 @@
{
"name": "curl",
- "version": "0.6.6",
+ "version": "0.6.7",
"description": "A small, fast module and resource loader with dependency management. (AMD, CommonJS Modules/1.1, CSS, HTML, etc.)",
"keywords": ["curl", "cujo", "amd", "loader", "module"],
"licenses": [
View
4 src/curl.js
@@ -9,12 +9,12 @@
* Licensed under the MIT License at:
* http://www.opensource.org/licenses/mit-license.php
*
- * @version 0.6.6
+ * @version 0.6.7
*/
(function (global) {
//"use strict"; don't restore this until the config routine is refactored
var
- version = '0.6.6',
+ version = '0.6.7',
curlName = 'curl',
userCfg = global[curlName],
prevCurl,

0 comments on commit ec8c7e4

Please sign in to comment.