//>>built
define("dojo/i18n","./_base/kernel,require,./has,./_base/array,./_base/config,./_base/lang,./_base/xhr,./json,module".split(","),function(h,j,n,s,x,o,p,y,z){n.add("dojo-preload-i18n-Api",1);var p=h.i18n={},A=/(^.*(^|\/)nls)(\/|$)([^\/]*)\/?([^\/]*)/,B=function(a,c,b,e){for(var g=[b+e],c=c.split("-"),m="",i=0;i<c.length;i++)m+=(m?"-":"")+c[i],(!a||a[m])&&g.push(b+m+"/"+e);return g},k={},v=function(a,c,b){b=b?b.toLowerCase():h.locale;a=a.replace(/\./g,"/");c=c.replace(/\./g,"/");return/root/i.test(b)?
a+"/nls/"+c:a+"/nls/"+b+"/"+c};h.getL10nName=function(a,c,b){return z.id+"!"+v(a,c,b)};var D=function(a,c,b,e,g,m){a([c],function(i){var d=o.clone(i.root||i.ROOT),r=B(!i._v1x&&i,g,b,e);a(r,function(){for(var a=1;a<r.length;a++)d=o.mixin(o.clone(d),arguments[a]);k[c+"/"+g]=d;m()})})},E=function(a){var c=x.extraLocale||[],c=o.isArray(c)?c:[c];c.push(a);return c},u=function(a,c,b){if(n("dojo-preload-i18n-Api")){var e=a.split("*"),g="preload"==e[1];g&&(k[a]||(k[a]=1,F(e[2],y.parse(e[3]),1,c)),b(1));if(!(e=
g))q&&t.push([a,c,b]),e=q;if(e)return}var a=A.exec(a),d=a[1]+"/",i=a[5]||a[4],j=d+i,e=(a=a[5]&&a[4])||h.locale,r=j+"/"+e,a=a?[e]:E(e),C=a.length,w=function(){--C||b(o.delegate(k[r]))};s.forEach(a,function(a){var b=j+"/"+a;n("dojo-preload-i18n-Api")&&f(b);k[b]?w():D(c,j,d,i,a,w)})};if(n("dojo-unit-tests"))var G=p.unitTests=[];n("dojo-preload-i18n-Api");var H=p.normalizeLocale=function(a){a=a?a.toLowerCase():h.locale;return"root"==a?"ROOT":a},q=0,t=[],F=p._preloadLocalizations=function(a,c,b,e){function d(a,
c){e([a],c)}function m(a,c){for(var b=a.split("-");b.length;){if(c(b.join("-")))return;b.pop()}c("ROOT")}function i(){for(--q;!q&&t.length;)u.apply(null,t.shift())}function f(b){b=H(b);m(b,function(f){if(0<=s.indexOf(c,f)){var h=a.replace(/\./g,"/")+"_"+f;q++;d(h,function(a){for(var c in a){var d=a[c],g=c.match(/(.+)\/([^\/]+)$/),h;if(g){h=g[2];g=g[1]+"/";d._localized=d._localized||{};var l;if("ROOT"===f){var n=l=d._localized;delete d._localized;n.root=d;k[j.toAbsMid(c)]=n}else l=d._localized,k[j.toAbsMid(g+
h+"/"+f)]=d;f!==b&&function(a,c,d,g){var f=[],h=[];m(b,function(b){g[b]&&(f.push(j.toAbsMid(a+b+"/"+c)),h.push(j.toAbsMid(a+c+"/"+b)))});f.length?(q++,e(f,function(){for(var e=0;e<f.length;e++)d=o.mixin(o.clone(d),arguments[e]),k[h[e]]=d;k[j.toAbsMid(a+c+"/"+b)]=o.clone(d);i()})):k[j.toAbsMid(a+c+"/"+b)]=d}(g,h,d,l)}}i()});return!0}return!1})}e=e||j;f();s.forEach(h.config.extraLocale,f)},f=function(){},d={},l=new Function("__bundle","__checkForLegacyModules","__mid","__amdValue","var define = function(mid, factory){define.called = 1; __amdValue.result = factory || mid;},\t   require = function(){define.called = 1;};try{define.called = 0;eval(__bundle);if(define.called==1)return __amdValue;if((__checkForLegacyModules = __checkForLegacyModules(__mid)))return __checkForLegacyModules;}catch(e){}try{return eval('('+__bundle+')');}catch(e){return e;}"),
f=function(a){for(var c,b=a.split("/"),d=h.global[b[0]],g=1;d&&g<b.length-1;d=d[b[g++]]);d&&((c=d[b[g]])||(c=d[b[g].replace(/-/g,"_")]),c&&(k[a]=c));return c};p.getLocalization=function(a,c,b){var d,a=v(a,c,b);u(a,j,function(a){d=a});return d};n("dojo-unit-tests")&&G.push(function(a){a.register("tests.i18n.unit",function(a){var b;b=l("{prop:1}",f,"nonsense",d);a.is({prop:1},b);a.is(void 0,b[1]);b=l("({prop:1})",f,"nonsense",d);a.is({prop:1},b);a.is(void 0,b[1]);b=l("{'prop-x':1}",f,"nonsense",d);
a.is({"prop-x":1},b);a.is(void 0,b[1]);b=l("({'prop-x':1})",f,"nonsense",d);a.is({"prop-x":1},b);a.is(void 0,b[1]);b=l("define({'prop-x':1})",f,"nonsense",d);a.is(d,b);a.is({"prop-x":1},d.result);b=l("define('some/module', {'prop-x':1})",f,"nonsense",d);a.is(d,b);a.is({"prop-x":1},d.result);b=l("this is total nonsense and should throw an error",f,"nonsense",d);a.is(b instanceof Error,!0)})});return o.mixin(p,{dynamic:!0,normalize:function(a,c){return/^\./.test(a)?c(a):a},load:u,cache:k})});