Update Dojo and Dojo builder to 1.13.0
This is a result of the previous commits. Building the Dojo builder was bit more complex as it was: 1. patched Dojo sources 2. built from Dojo builder sources. 3. moved to it's location in FreeIPA project 4. built by util/make-builder.sh (does minimazation and replaces itself) Then Dojo layer is built by just: 1. util/make-dojo.sh This process was documented some time ago at: https://www.freeipa.org/page/V3/WebUI_build Reviewed-By: Armando Neto <abiagion@redhat.com>
This commit is contained in:
1 parent
df95ba5983
commit
19c3f173d9
2 files changed
+13
-2
No files matched your search
Vendored
+5
-1
@@ -1 +1,5 @@
|
||||
(function(e,t){var n=function(){},r=function(e){for(var t in e)return 0;return 1},i={}.toString,s=function(e){return i.call(e)=="[object Function]"},o=function(e){return i.call(e)=="[object String]"},u=function(e){return i.call(e)=="[object Array]"},a=function(e,t){if(e)for(var n=0;e[n];)t(e[n++])},f=function(e,t){for(var n in t)e[n]=t[n];return e},l=function(e,t){return f(new Error(e),{src:"dojoLoader",info:t})},c=1,h=function(){return"_"+c++},p=function(e,t,n){return xt(e,t,n,0,p)},d=this,v=d.document,m=v&&v.createElement("DiV"),g=p.has=function(e){return s(y[e])?y[e]=y[e](d,v,m):y[e]},y=g.cache=t.hasCache;g.add=function(e,t,n,r){return(y[e]===undefined||r)&&(y[e]=t),n&&g(e)},0,0;for(var x in e.has)g.add(x,e.has[x],0,1);var T=1,N=2,C=3,k=4,L=5,A=0,O="sync",M="xd",_=[],D=0,P=n,H=n,B;p.isXdUrl=n,p.initSyncLoader=function(e,t,n){return D||(D=e,P=t,H=n),{sync:O,requested:T,arrived:N,nonmodule:C,executing:k,executed:L,syncExecStack:_,modules:Z,execQ:Nt,getModule:Ft,injectModule:ln,setArrived:At,signal:X,finishExec:Gt,execModule:Zt,dojoRequirePlugin:D,getLegacyMode:function(){return A},guardCheckComplete:tn}};var j=location.protocol,F=location.host;p.isXdUrl=function(e){if(/^\./.test(e))return!1;if(/^\/\//.test(e))return!0;var t=e.match(/^([^\/\:]+\:)\/+([^\/]+)/);return t&&(t[1]!=j||F&&t[2]!=F)},1,g.add("dojo-force-activex-xhr",!v.addEventListener&&window.location.protocol=="file:"),g.add("native-xhr",typeof XMLHttpRequest!="undefined");if(g("native-xhr")&&!g("dojo-force-activex-xhr"))B=function(){return new XMLHttpRequest};else{for(var I=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"],q,S=0;S<3;)try{q=I[S++];if(new ActiveXObject(q))break}catch(R){}B=function(){return new ActiveXObject(q)}}p.getXhr=B,g.add("dojo-gettext-api",1),p.getText=function(e,t,n){var r=B();r.open("GET",rn(e),!1),r.send(null);if(r.status==200||!location.host&&!r.status)return n&&n(r.responseText,t),r.responseText;throw l("xhrFailed",r.status)};var U=new Function("return eval(arguments[0]);");p.eval=function(e,t){return U(e+"\r\n////@ sourceURL="+t)};var z={},W="error",X=p.signal=function(e,t){var n=z[e];a(n&&n.slice(0),function(e){e.apply(null,u(t)?t:[t])})},V=p.on=function(e,t){var n=z[e]||(z[e]=[]);return n.push(t),{remove:function(){for(var e=0;e<n.length;e++)if(n[e]===t){n.splice(e,1);return}}}},$=[],J={},K=[],Q={},G=p.map={},Y=[],Z={},et="",tt={},nt="url:",rt={},it={},st=0,ot=function(e){var t,n,r,i,s;for(t in rt)n=rt[t],r=t.match(/^url\:(.+)/),r?tt[nt+qt(r[1],e)]=n:t=="*now"?i=n:t!="*noref"&&(s=Ht(t,e),tt[s.mid]=tt[nt+s.url]=n);i&&i(Tt(e)),rt={}},ut=function(e){return e.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g,function(e){return"\\"+e})},at=function(e,t){t.splice(0,t.length);for(var n in e)t.push([n,e[n],new RegExp("^"+ut(n)+"(/|$)"),n.length]);return t.sort(function(e,t){return t[3]-e[3]}),t},ft=function(e,t){a(e,function(e){t.push([o(e[0])?new RegExp("^"+ut(e[0])+"$"):e[0],e[1]])})},lt=function(e){var t=e.name;t||(t=e,e={name:t}),e=f({main:"main"},e),e.location=e.location?e.location:t,e.packageMap&&(G[t]=e.packageMap),e.main.indexOf("./")||(e.main=e.main.substring(2)),Q[t]=e},ct=[],ht=function(e,t,n){for(var r in e){r=="waitSeconds"&&(p.waitms=(e[r]||0)*1e3),r=="cacheBust"&&(et=e[r]?o(e[r])?e[r]:(new Date).getTime()+"":"");if(r=="baseUrl"||r=="combo")p[r]=e[r];if(r=="async"){var i=e[r];p.legacyMode=A=o(i)&&/sync|legacyAsync/.test(i)?i:i?!1:O,p.async=!A}e[r]!==y&&(p.rawConfig[r]=e[r],r!="has"&&g.add("config-"+r,e[r],0,t))}p.baseUrl||(p.baseUrl="./"),/\/$/.test(p.baseUrl)||(p.baseUrl+="/");for(r in e.has)g.add(r,e.has[r],0,t);a(e.packages,lt);for(b in e.packagePaths)a(e.packagePaths[b],function(e){var t=b+"/"+e;o(e)&&(e={name:e}),e.location=t,lt(e)});at(f(G,e.map),Y),a(Y,function(e){e[1]=at(e[1],[]),e[0]=="*"&&(Y.star=e)}),at(f(J,e.paths),K),ft(e.aliases,$);if(t)ct.push({config:e.config});else for(r in e.config){var s=Ft(r,n);s.config=f(s.config||{},e.config[r])}e.cache&&(ot(),rt=e.cache,e.cache["*noref"]&&ot()),X("config",[e,p.rawConfig])};if(g("dojo-cdn")||1){var pt=v.getElementsByTagName("script"),S=0,dt,vt,mt,gt;while(S<pt.length){dt=pt[S++],(mt=dt.getAttribute("src"))&&(gt=mt.match(/(((.*)\/)|^)dojo\.js(\W|$)/i))&&(vt=gt[3]||"",t.baseUrl=t.baseUrl||vt,st=dt);if(mt=dt.getAttribute("data-dojo-config")||dt.getAttribute("djConfig"))it=p.eval("({ "+mt+" })","data-dojo-config"),st=dt}}p.rawConfig={},ht(t,1),g("dojo-cdn")&&(Q.dojo.location=vt,vt&&(vt+="/"),Q.dijit.location=vt+"../dijit/",Q.dojox.location=vt+"../dojox/"),ht(e,1),ht(it,1);var St=function(e){tn(function(){a(e.deps,ln)})},xt=function(e,t,r,i,s){var a,c;if(o(e)){a=Ft(e,i,!0);if(a&&a.executed)return a.result;throw l("undefinedModule",e)}u(e)||(ht(e,0,i),e=t,t=r);if(u(e))if(!e.length)t&&t();else{c="require*"+h();for(var d,v=[],m=0;m<e.length;)d=e[m++],v.push(Ft(d,i));a=f(Dt("",c,0,""),{injected:N,deps:v,def:t||n,require:i?i.require:p,gc:1}),Z[a.mid]=a,St(a);var g=en&&A!=O;tn(function(){Zt(a,g)}),a.executed||Nt.push(a),nn()}return s},Tt=function(e){if(!e)return p;Line truncated
|
||||
(function(userConfig,defaultConfig){var globalObject=function(){if(typeof global!=="undefined"&&typeof global!=="function"){return global}else if(typeof window!=="undefined"){return window}else if(typeof self!=="undefined"){return self}return this}();var noop=function(){},isEmpty=function(it){for(var p in it){return 0}return 1},toString={}.toString,isFunction=function(it){return toString.call(it)=="[object Function]"},isString=function(it){return toString.call(it)=="[object String]"},isArray=function(it){return toString.call(it)=="[object Array]"},forEach=function(vector,callback){if(vector){for(var i=0;i<vector.length;){callback(vector[i++])}}},mix=function(dest,src){for(var p in src){dest[p]=src[p]}return dest},makeError=function(error,info){return mix(new Error(error),{src:"dojoLoader",info:info})},uidSeed=1,uid=function(){return"_"+uidSeed++},req=function(config,dependencies,callback){return contextRequire(config,dependencies,callback,0,req)},global=globalObject,doc=global.document,element=doc&&doc.createElement("DiV"),has=req.has=function(name){return isFunction(hasCache[name])?hasCache[name]=hasCache[name](global,doc,element):hasCache[name]},hasCache=has.cache=defaultConfig.hasCache;if(isFunction(userConfig)){userConfig=userConfig(globalObject)}has.add=function(name,test,now,force){(hasCache[name]===undefined||force)&&(hasCache[name]=test);return now&&has(name)};0&&has.add("host-node",userConfig.has&&"host-node"in userConfig.has?userConfig.has["host-node"]:typeof process=="object"&&process.versions&&process.versions.node&&process.versions.v8);if(0){require("./_base/configNode.js").config(defaultConfig);defaultConfig.loaderPatch.nodeRequire=require}0&&has.add("host-rhino",userConfig.has&&"host-rhino"in userConfig.has?userConfig.has["host-rhino"]:typeof load=="function"&&(typeof Packages=="function"||typeof Packages=="object"));if(0){for(var baseUrl=userConfig.baseUrl||".",arg,rhinoArgs=this.arguments,i=0;i<rhinoArgs.length;){arg=(rhinoArgs[i++]+"").split("=");if(arg[0]=="baseUrl"){baseUrl=arg[1];break}}load(baseUrl+"/_base/configRhino.js");rhinoDojoConfig(defaultConfig,baseUrl,rhinoArgs)}has.add("host-webworker",typeof WorkerGlobalScope!=="undefined"&&self instanceof WorkerGlobalScope);if(has("host-webworker")){mix(defaultConfig.hasCache,{"host-browser":0,dom:0,"dojo-dom-ready-api":0,"dojo-sniff":0,"dojo-inject-api":1,"host-webworker":1,"dojo-guarantee-console":0});defaultConfig.loaderPatch={injectUrl:function(url,callback){try{importScripts(url);callback()}catch(e){console.info("failed to load resource ("+url+")");console.error(e)}}}}for(var p in userConfig.has){has.add(p,userConfig.has[p],0,1)}var requested=1,arrived=2,nonmodule=3,executing=4,executed=5;if(0){requested="requested";arrived="arrived";nonmodule="not-a-module";executing="executing";executed="executed"}var legacyMode=0,sync="sync",xd="xd",syncExecStack=[],dojoRequirePlugin=0,checkDojoRequirePlugin=noop,transformToAmd=noop,getXhr;if(1){req.isXdUrl=noop;req.initSyncLoader=function(dojoRequirePlugin_,checkDojoRequirePlugin_,transformToAmd_){if(!dojoRequirePlugin){dojoRequirePlugin=dojoRequirePlugin_;checkDojoRequirePlugin=checkDojoRequirePlugin_;transformToAmd=transformToAmd_}return{sync:sync,requested:requested,arrived:arrived,nonmodule:nonmodule,executing:executing,executed:executed,syncExecStack:syncExecStack,modules:modules,execQ:execQ,getModule:getModule,injectModule:injectModule,setArrived:setArrived,signal:signal,finishExec:finishExec,execModule:execModule,dojoRequirePlugin:dojoRequirePlugin,getLegacyMode:function(){return legacyMode},guardCheckComplete:guardCheckComplete}};if(1||has("host-webworker")){var locationProtocol=location.protocol,locationHost=location.host;req.isXdUrl=function(url){if(/^\./.test(url)){return false}if(/^\/\//.test(url)){return true}var match=url.match(/^([^\/\:]+\:)\/+([^\/]+)/);return match&&(match[1]!=locationProtocol||locationHost&&match[2]!=locationHost)};1||has.add("dojo-xhr-factory",1);has.add("dojo-force-activex-xhr",1&&!doc.addEventListener&&window.location.protocol=="file:");has.add("native-xhr",typeof XMLHttpRequest!="undefined");if(has("native-xhr")&&!has("dojo-force-activex-xhr")){getXhr=function(){return new XMLHttpRequest}}else{for(var XMLHTTP_PROGIDS=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"],progid,i=0;i<3;){try{progid=XMLHTTP_PROGIDS[i++];if(new ActiveXObject(progid)){break}}catch(e){}}getXhr=function(){return new ActiveXObject(progid)}}req.getXhr=getXhr;has.add("dojo-gettext-api",1);req.getText=function(url,async,onLoad){var xhr=getXhr();xhr.open("GET",fixupUrl(url),false);xhr.send(null);if(xhr.status==200||!location.host&&!xhr.status){if(onLoad){onLoad(xhr.responseText,async)}}else{throw makeError("xhrFailed",xhr.status)}return xhr.responseText}}}else{req.async=1}var eval_=has("csp-restrictions")?function(){}:new Function("return eval(arguments[0]);");req.eval=function(text,hint){return eval_(text+"\r\n//# sourceURL="+hint)};var listenerQueues={},error="error",signal=req.Line truncated
|
||||
node.detachEvent(event,detectReady)})};var div=doc.createElement("div");try{if(div.doScroll&&global.frameElement===null){tests.push(function(){try{div.doScroll("left");return 1}catch(e){}})}}catch(e){}}on(doc,"DOMContentLoaded");on(global,"load");if("onreadystatechange"in doc){on(doc,"readystatechange")}else if(!fixReadyState){tests.push(function(){return readyStates[doc.readyState]})}if(tests.length){var poller=function(){if(ready){return}var i=tests.length;while(i--){if(tests[i]()){detectReady("poller");return}}setTimeout(poller,30)};poller()}}return domReady})},"dojo/global":function(){define(function(){if(typeof global!=="undefined"&&typeof global!=="function"){return global}else if(typeof window!=="undefined"){return window}else if(typeof self!=="undefined"){return self}return this})},"dojo/has":function(){define(["./global","require","module"],function(global,require,module){var has=require.has||function(){};if(!1){var isBrowser=typeof window!="undefined"&&typeof location!="undefined"&&typeof document!="undefined"&&window.location==location&&window.document==document,doc=isBrowser&&document,element=doc&&doc.createElement("DiV"),cache=module.config&&module.config()||{};has=function(name){return typeof cache[name]=="function"?cache[name]=cache[name](global,doc,element):cache[name]};has.cache=cache;has.add=function(name,test,now,force){(typeof cache[name]=="undefined"||force)&&(cache[name]=test);return now&&has(name)};1||has.add("host-browser",isBrowser);0&&has.add("host-node",typeof process=="object"&&process.versions&&process.versions.node&&process.versions.v8);0&&has.add("host-rhino",typeof load=="function"&&(typeof Packages=="function"||typeof Packages=="object"));1||has.add("dom",isBrowser);1||has.add("dojo-dom-ready-api",1);1||has.add("dojo-sniff",1)}if(1){has.add("dom-addeventlistener",!!document.addEventListener);has.add("touch","ontouchstart"in document||"onpointerdown"in document&&navigator.maxTouchPoints>0||window.navigator.msMaxTouchPoints);has.add("touch-events","ontouchstart"in document);has.add("pointer-events","pointerEnabled"in window.navigator?window.navigator.pointerEnabled:"PointerEvent"in window);has.add("MSPointer",window.navigator.msPointerEnabled);has.add("touch-action",has("touch")&&has("pointer-events"));has.add("device-width",screen.availWidth||innerWidth);var form=document.createElement("form");has.add("dom-attributes-explicit",form.attributes.length==0);has.add("dom-attributes-specified-flag",form.attributes.length>0&&form.attributes.length<40)}has.clearElement=function(element){element.innerHTML="";return element};has.normalize=function(id,toAbsMid){var tokens=id.match(/[\?:]|[^:\?]*/g),i=0,get=function(skip){var term=tokens[i++];if(term==":"){return 0}else{if(tokens[i++]=="?"){if(!skip&&has(term)){return get()}else{get(true);return get(skip)}}return term||0}};id=get();return id&&toAbsMid(id)};has.load=function(id,parentRequire,loaded){if(id){parentRequire([id],loaded)}else{loaded()}};return has})},"dojo/_base/declare":function(){define(["./kernel","../has","./lang"],function(dojo,has,lang){var mix=lang.mixin,op=Object.prototype,opts=op.toString,xtor,counter=0,cname="constructor";if(!has("csp-restrictions")){xtor=new Function}else{xtor=function(){}}function err(msg,cls){throw new Error("declare"+(cls?" "+cls:"")+": "+msg)}function c3mro(bases,className){var result=[],roots=[{cls:0,refs:[]}],nameMap={},clsCount=1,l=bases.length,i=0,j,lin,base,top,proto,rec,name,refs;for(;i<l;++i){base=bases[i];if(!base){err("mixin #"+i+" is unknown. Did you use dojo.require to pull it in?",className)}else if(opts.call(base)!="[object Function]"){err("mixin #"+i+" is not a callable constructor.",className)}lin=base._meta?base._meta.bases:[base];top=0;for(j=lin.length-1;j>=0;--j){proto=lin[j].prototype;if(!proto.hasOwnProperty("declaredClass")){proto.declaredClass="uniqName_"+counter++}name=proto.declaredClass;if(!nameMap.hasOwnProperty(name)){nameMap[name]={count:0,refs:[],cls:lin[j]};++clsCount}rec=nameMap[name];if(top&&top!==rec){rec.refs.push(top);++top.count}top=rec}++top.count;roots[0].refs.push(top)}while(roots.length){top=roots.pop();result.push(top.cls);--clsCount;while(refs=top.refs,refs.length==1){top=refs[0];if(!top||--top.count){top=0;break}result.push(top.cls);--clsCount}if(top){for(i=0,l=refs.length;i<l;++i){top=refs[i];if(!--top.count){roots.push(top)}}}}if(clsCount){err("can't build consistent linearization",className)}base=bases[0];result[0]=base?base._meta&&base===result[result.length-base._meta.bases.length]?base._meta.bases.length:1:0;return result}function inherited(args,a,f,g){var name,chains,bases,caller,meta,base,proto,opf,pos,cache=this._inherited=this._inherited||{};if(typeof args==="string"){name=args;args=a;a=f;f=g}if(typeof args==="function"){caller=args;args=a;a=f}else{try{caller=args.callee}catch(e){if(e instanceof TypeError){err("strict mode inherited() requires the caller function to be passed before arguments",this.declaredClass)}else{throw e}}}name=name||calLine truncated
|
||||
node.removeChild(c)}}exports.empty=function empty(node){_empty(dom.byId(node))};function _destroy(node,parent){if(node.firstChild){_empty(node)}if(parent){has("ie")&&parent.canHaveChildren&&"removeNode"in node?node.removeNode(false):parent.removeChild(node)}}var destroy=exports.destroy=function destroy(node){node=dom.byId(node);if(!node){return}_destroy(node,node.parentNode)}})},"dojo/dom-attr":function(){define(["exports","./sniff","./_base/lang","./dom","./dom-style","./dom-prop"],function(exports,has,lang,dom,style,prop){var forcePropNames={innerHTML:1,textContent:1,className:1,htmlFor:has("ie"),value:1},attrNames={classname:"class",htmlfor:"for",tabindex:"tabIndex",readonly:"readOnly"};function _hasAttr(node,name){var attr=node.getAttributeNode&&node.getAttributeNode(name);return!!attr&&attr.specified}exports.has=function hasAttr(node,name){var lc=name.toLowerCase();return forcePropNames[prop.names[lc]||name]||_hasAttr(dom.byId(node),attrNames[lc]||name)};exports.get=function getAttr(node,name){node=dom.byId(node);var lc=name.toLowerCase(),propName=prop.names[lc]||name,forceProp=forcePropNames[propName],value=node[propName];if(forceProp&&typeof value!="undefined"){return value}if(propName=="textContent"){return prop.get(node,propName)}if(propName!="href"&&(typeof value=="boolean"||lang.isFunction(value))){return value}var attrName=attrNames[lc]||name;return _hasAttr(node,attrName)?node.getAttribute(attrName):null};exports.set=function setAttr(node,name,value){node=dom.byId(node);if(arguments.length==2){for(var x in name){exports.set(node,x,name[x])}return node}var lc=name.toLowerCase(),propName=prop.names[lc]||name,forceProp=forcePropNames[propName];if(propName=="style"&&typeof value!="string"){style.set(node,value);return node}if(forceProp||typeof value=="boolean"||lang.isFunction(value)){return prop.set(node,name,value)}node.setAttribute(attrNames[lc]||name,value);return node};exports.remove=function removeAttr(node,name){dom.byId(node).removeAttribute(attrNames[name.toLowerCase()]||name)};exports.getNodeProp=function getNodeProp(node,name){node=dom.byId(node);var lc=name.toLowerCase(),propName=prop.names[lc]||name;if(propName in node&&propName!="href"){return node[propName]}var attrName=attrNames[lc]||name;return _hasAttr(node,attrName)?node.getAttribute(attrName):null}})},"dojo/dom-style":function(){define(["./sniff","./dom","./_base/window"],function(has,dom,win){var getComputedStyle,style={};if(has("webkit")){getComputedStyle=function(node){var s;if(node.nodeType==1){var dv=node.ownerDocument.defaultView;s=dv.getComputedStyle(node,null);if(!s&&node.style){node.style.display="";s=dv.getComputedStyle(node,null)}}return s||{}}}else if(has("ie")&&(has("ie")<9||has("quirks"))){getComputedStyle=function(node){return node.nodeType==1&&node.currentStyle?node.currentStyle:{}}}else{getComputedStyle=function(node){if(node.nodeType===1){var dv=node.ownerDocument.defaultView,w=dv.opener?dv:win.global.window;return w.getComputedStyle(node,null)}return{}}}style.getComputedStyle=getComputedStyle;var toPixel;if(!has("ie")){toPixel=function(element,value){return parseFloat(value)||0}}else{toPixel=function(element,avalue){if(!avalue){return 0}if(avalue=="medium"){return 4}if(avalue.slice&&avalue.slice(-2)=="px"){return parseFloat(avalue)}var s=element.style,rs=element.runtimeStyle,cs=element.currentStyle,sLeft=s.left,rsLeft=rs.left;rs.left=cs.left;try{s.left=avalue;avalue=s.pixelLeft}catch(e){avalue=0}s.left=sLeft;rs.left=rsLeft;return avalue}}style.toPixelValue=toPixel;var astr="DXImageTransform.Microsoft.Alpha";var af=function(n,f){try{return n.filters.item(astr)}catch(e){return f?{}:null}};var _getOpacity=has("ie")<9||has("ie")<10&&has("quirks")?function(node){try{return af(node).Opacity/100}catch(e){return 1}}:function(node){return getComputedStyle(node).opacity};var _setOpacity=has("ie")<9||has("ie")<10&&has("quirks")?function(node,opacity){if(opacity===""){opacity=1}var ov=opacity*100,fullyOpaque=opacity===1;if(fullyOpaque){node.style.zoom="";if(af(node)){node.style.filter=node.style.filter.replace(new RegExp("\\s*progid:"+astr+"\\([^\\)]+?\\)","i"),"")}}else{node.style.zoom=1;if(af(node)){af(node,1).Opacity=ov}else{node.style.filter+=" progid:"+astr+"(Opacity="+ov+")"}af(node,1).Enabled=true}if(node.tagName.toLowerCase()=="tr"){for(var td=node.firstChild;td;td=td.nextSibling){if(td.tagName.toLowerCase()=="td"){_setOpacity(td,opacity)}}}return opacity}:function(node,opacity){return node.style.opacity=opacity};var _pixelNamesCache={left:true,top:true};var _pixelRegExp=/margin|padding|width|height|max|min|offset/;function _toStyleValue(node,type,value){type=type.toLowerCase();if(value=="auto"){if(type=="height"){return node.offsetHeight}if(type=="width"){return node.offsetWidth}}if(type=="fontweight"){switch(value){case 700:return"bold";case 400:default:return"normal"}}if(!(type in _pixelNamesCache)){_pixelNamesCache[type]=_pixelRegExp.test(type)}return _pixelNamesCache[type]?toPixel(node,value):value}var _floaLine truncated
|
||||
META:has("webkit")?91:224,PAUSE:19,CAPS_LOCK:20,ESCAPE:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT_ARROW:37,UP_ARROW:38,RIGHT_ARROW:39,DOWN_ARROW:40,INSERT:45,DELETE:46,HELP:47,LEFT_WINDOW:91,RIGHT_WINDOW:92,SELECT:93,NUMPAD_0:96,NUMPAD_1:97,NUMPAD_2:98,NUMPAD_3:99,NUMPAD_4:100,NUMPAD_5:101,NUMPAD_6:102,NUMPAD_7:103,NUMPAD_8:104,NUMPAD_9:105,NUMPAD_MULTIPLY:106,NUMPAD_PLUS:107,NUMPAD_ENTER:108,NUMPAD_MINUS:109,NUMPAD_PERIOD:110,NUMPAD_DIVIDE:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,F13:124,F14:125,F15:126,NUM_LOCK:144,SCROLL_LOCK:145,UP_DPAD:175,DOWN_DPAD:176,LEFT_DPAD:177,RIGHT_DPAD:178,copyKey:has("mac")&&!has("air")?has("safari")?91:224:17}})},"dojo/dom-class":function(){define(["./_base/lang","./_base/array","./dom"],function(lang,array,dom){var className="className";var cls,spaces=/\s+/,a1=[""];function str2array(s){if(typeof s=="string"||s instanceof String){if(s&&!spaces.test(s)){a1[0]=s;return a1}var a=s.split(spaces);if(a.length&&!a[0]){a.shift()}if(a.length&&!a[a.length-1]){a.pop()}return a}if(!s){return[]}return array.filter(s,function(x){return x})}var fakeNode={};cls={contains:function containsClass(node,classStr){return(" "+dom.byId(node)[className]+" ").indexOf(" "+classStr+" ")>=0},add:function addClass(node,classStr){node=dom.byId(node);classStr=str2array(classStr);var cls=node[className],oldLen;cls=cls?" "+cls+" ":" ";oldLen=cls.length;for(var i=0,len=classStr.length,c;i<len;++i){c=classStr[i];if(c&&cls.indexOf(" "+c+" ")<0){cls+=c+" "}}if(oldLen<cls.length){node[className]=cls.substr(1,cls.length-2)}},remove:function removeClass(node,classStr){node=dom.byId(node);var cls;if(classStr!==undefined){classStr=str2array(classStr);cls=" "+node[className]+" ";for(var i=0,len=classStr.length;i<len;++i){cls=cls.replace(" "+classStr[i]+" "," ")}cls=lang.trim(cls)}else{cls=""}if(node[className]!=cls){node[className]=cls}},replace:function replaceClass(node,addClassStr,removeClassStr){node=dom.byId(node);fakeNode[className]=node[className];cls.remove(fakeNode,removeClassStr);cls.add(fakeNode,addClassStr);if(node[className]!==fakeNode[className]){node[className]=fakeNode[className]}},toggle:function toggleClass(node,classStr,condition){node=dom.byId(node);if(condition===undefined){classStr=str2array(classStr);for(var i=0,len=classStr.length,c;i<len;++i){c=classStr[i];cls[cls.contains(node,c)?"remove":"add"](node,c)}}else{cls[condition?"add":"remove"](node,classStr)}return condition}};return cls})},"dojo/Stateful":function(){define(["./_base/declare","./_base/lang","./_base/array","./when"],function(declare,lang,array,when){return declare("dojo.Stateful",null,{_attrPairNames:{},_getAttrNames:function(name){var apn=this._attrPairNames;if(apn[name]){return apn[name]}return apn[name]={s:"_"+name+"Setter",g:"_"+name+"Getter"}},postscript:function(params){if(params){this.set(params)}},_get:function(name,names){return typeof this[names.g]==="function"?this[names.g]():this[name]},get:function(name){return this._get(name,this._getAttrNames(name))},set:function(name,value){if(typeof name==="object"){for(var x in name){if(name.hasOwnProperty(x)&&x!="_watchCallbacks"){this.set(x,name[x])}}return this}var names=this._getAttrNames(name),oldValue=this._get(name,names),setter=this[names.s],result;if(typeof setter==="function"){result=setter.apply(this,Array.prototype.slice.call(arguments,1))}else{this[name]=value}if(this._watchCallbacks){var self=this;when(result,function(){self._watchCallbacks(name,oldValue,value)})}return this},_changeAttrValue:function(name,value){var oldValue=this.get(name);this[name]=value;if(this._watchCallbacks){this._watchCallbacks(name,oldValue,value)}return this},watch:function(name,callback){var callbacks=this._watchCallbacks;if(!callbacks){var self=this;callbacks=this._watchCallbacks=function(name,oldValue,value,ignoreCatchall){var notify=function(propertyCallbacks){if(propertyCallbacks){propertyCallbacks=propertyCallbacks.slice();for(var i=0,l=propertyCallbacks.length;i<l;i++){propertyCallbacks[i].call(self,name,oldValue,value)}}};notify(callbacks["_"+name]);if(!ignoreCatchall){notify(callbacks["*"])}}}if(!callback&&typeof name==="function"){callback=name;name="*"}else{name="_"+name}var propertyCallbacks=callbacks[name];if(typeof propertyCallbacks!=="object"){propertyCallbacks=callbacks[name]=[]}propertyCallbacks.push(callback);var handle={};handle.unwatch=handle.remove=function(){var index=array.indexOf(propertyCallbacks,callback);if(index>-1){propertyCallbacks.splice(index,1)}};return handle}})})},"dojo/when":function(){define(["./Deferred","./promise/Promise"],function(Deferred,Promise){"use strict";return function when(valueOrPromise,callback,errback,progback){var receivedPromise=valueOrPromise&&typeof valueOrPromise.then==="function";var nativePromise=receivedPromise&&valueOrPromise instanceof Promise;if(!receivedPromise){if(arguments.length>1){return callback?callback(valueOrPromise):valueOrPromise}else{return(new DeferrLine truncated
|
||||
if(this._parent){return this._parent}else{return new this._NodeListCtor(0)}},concat:function(item){var t=aps.call(this,0),m=array.map(arguments,function(a){return aps.call(a,0)});return this._wrap(apc.apply(t,m),this)},map:function(func,obj){return this._wrap(array.map(this,func,obj),this)},forEach:function(callback,thisObj){forEach(this,callback,thisObj);return this},filter:function(filter){var a=arguments,items=this,start=0;if(typeof filter=="string"){items=query._filterResult(this,a[0]);if(a.length==1){return items._stash(this)}start=1}return this._wrap(array.filter(items,a[start],a[start+1]),this)},instantiate:function(declaredClass,properties){var c=lang.isFunction(declaredClass)?declaredClass:lang.getObject(declaredClass);properties=properties||{};return this.forEach(function(node){new c(properties,node)})},at:function(){var t=new this._NodeListCtor(0);forEach(arguments,function(i){if(i<0){i=this.length+i}if(this[i]){t.push(this[i])}},this);return t._stash(this)}});function queryForEngine(engine,NodeList){var query=function(query,root){if(typeof root=="string"){root=dom.byId(root);if(!root){return new NodeList([])}}var results=typeof query=="string"?engine(query,root):query?query.end&&query.on?query:[query]:[];if(results.end&&results.on){return results}return new NodeList(results)};query.matches=engine.match||function(node,selector,root){return query.filter([node],selector,root).length>0};query.filter=engine.filter||function(nodes,selector,root){return query(selector,root).filter(function(node){return array.indexOf(nodes,node)>-1})};if(typeof engine!="function"){var search=engine.search;engine=function(selector,root){return search(root||document,selector)}}return query}var query=queryForEngine(defaultEngine,NodeList);dojo.query=queryForEngine(defaultEngine,function(array){return NodeList(array)});query.load=function(id,parentRequire,loaded){loader.load(id,parentRequire,function(engine){loaded(queryForEngine(engine,NodeList))})};dojo._filterQueryResult=query._filterResult=function(nodes,selector,root){return new NodeList(query.filter(nodes,selector,root))};dojo.NodeList=query.NodeList=NodeList;return query})},"dojo/selector/_loader":function(){define(["../has","require"],function(has,require){"use strict";if(typeof document!=="undefined"){var testDiv=document.createElement("div");has.add("dom-qsa2.1",!!testDiv.querySelectorAll);has.add("dom-qsa3",function(){try{testDiv.innerHTML="<p class='TEST'></p>";return testDiv.querySelectorAll(".TEST:empty").length==1}catch(e){}})}var fullEngine;var acme="./acme",lite="./lite";return{load:function(id,parentRequire,loaded,config){if(config&&config.isBuild){loaded();return}var req=require;id=id=="default"?has("config-selectorEngine")||"css3":id;id=id=="css2"||id=="lite"?lite:id=="css2.1"?has("dom-qsa2.1")?lite:acme:id=="css3"?has("dom-qsa3")?lite:acme:id=="acme"?acme:(req=parentRequire)&&id;if(id.charAt(id.length-1)=="?"){id=id.substring(0,id.length-1);var optionalLoad=true}if(optionalLoad&&(has("dom-compliant-qsa")||fullEngine)){return loaded(fullEngine)}req([id],function(engine){if(id!="./lite"){fullEngine=engine}loaded(engine)})}}})},"dojo/selector/lite":function(){define(["../has","../_base/kernel"],function(has,dojo){"use strict";var testDiv=document.createElement("div");var matchesSelector=testDiv.matches||testDiv.webkitMatchesSelector||testDiv.mozMatchesSelector||testDiv.msMatchesSelector||testDiv.oMatchesSelector;var querySelectorAll=testDiv.querySelectorAll;var unionSplit=/([^\s,](?:"(?:\\.|[^"])+"|'(?:\\.|[^'])+'|[^,])*)/g;has.add("dom-matches-selector",!!matchesSelector);has.add("dom-qsa",!!querySelectorAll);var liteEngine=function(selector,root){if(combine&&selector.indexOf(",")>-1){return combine(selector,root)}var doc=root?root.ownerDocument||root:dojo.doc||document,match=(querySelectorAll?/^([\w]*)#([\w\-]+$)|^(\.)([\w\-\*]+$)|^(\w+$)/:/^([\w]*)#([\w\-]+)(?:\s+(.*))?$|(?:^|(>|.+\s+))([\w\-\*]+)(\S*$)/).exec(selector);root=root||doc;if(match){var isInsideDomTree=has("ie")===8&&has("quirks")?root.nodeType===doc.nodeType:root.parentNode!==null&&root.nodeType!==9&&root.parentNode===doc;if(match[2]&&isInsideDomTree){var found=dojo.byId?dojo.byId(match[2],doc):doc.getElementById(match[2]);if(!found||match[1]&&match[1]!=found.tagName.toLowerCase()){return[]}if(root!=doc){var parent=found;while(parent!=root){parent=parent.parentNode;if(!parent){return[]}}}return match[3]?liteEngine(match[3],found):[found]}if(match[3]&&root.getElementsByClassName){return root.getElementsByClassName(match[4])}var found;if(match[5]){found=root.getElementsByTagName(match[5]);if(match[4]||match[6]){selector=(match[4]||"")+match[6]}else{return found}}}if(querySelectorAll){if(root.nodeType===1&&root.nodeName.toLowerCase()!=="object"){return useRoot(root,selector,root.querySelectorAll)}else{return root.querySelectorAll(selector)}}else if(!found){found=root.getElementsByTagName("*")}var results=[];for(var i=0,l=found.length;i<l;i++){var node=found[i];if(node.nodeType==1&&jsMatchesSeLine truncated
|
||||
@@ -1 +1,8 @@
|
||||
(function(e,t){var n=function(){},r=function(e){for(var t in e)return 0;return 1},i={}.toString,s=function(e){return i.call(e)=="[object Function]"},o=function(e){return i.call(e)=="[object String]"},u=function(e){return i.call(e)=="[object Array]"},a=function(e,t){if(e)for(var n=0;e[n];)t(e[n++])},f=function(e,t){for(var n in t)e[n]=t[n];return e},l=function(e,t){return f(new Error(e),{src:"dojoLoader",info:t})},c=1,h=function(){return"_"+c++},p=function(e,t,n){return xt(e,t,n,0,p)},d=this,v=d.document,m=v&&v.createElement("DiV"),g=p.has=function(e){return s(y[e])?y[e]=y[e](d,v,m):y[e]},y=g.cache=t.hasCache;g.add=function(e,t,n,r){return(y[e]===undefined||r)&&(y[e]=t),n&&g(e)},0,1;for(var b=e.baseUrl||".",w,E=this.arguments,S=0;S<E.length;){w=(E[S++]+"").split("=");if(w[0]=="baseUrl"){b=w[1];break}}load(b+"/_base/configRhino.js"),rhinoDojoConfig(t,b,E);for(var x in e.has)g.add(x,e.has[x],0,1);var T=1,N=2,C=3,k=4,L=5;T="requested",N="arrived",C="not-a-module",k="executing",L="executed";var A=0,O="sync",M="xd",_=[],D=0,P=n,H=n,B;p.isXdUrl=n,p.initSyncLoader=function(e,t,n){return D||(D=e,P=t,H=n),{sync:O,requested:T,arrived:N,nonmodule:C,executing:k,executed:L,syncExecStack:_,modules:Z,execQ:Nt,getModule:Ft,injectModule:ln,setArrived:At,signal:X,finishExec:Gt,execModule:Zt,dojoRequirePlugin:D,getLegacyMode:function(){return A},guardCheckComplete:tn}};var U=new Function("return eval(arguments[0]);");p.eval=function(e,t){return U(e+"\r\n////@ sourceURL="+t)};var z={},W="error",X=p.signal=function(e,t){var n=z[e];a(n&&n.slice(0),function(e){e.apply(null,u(t)?t:[t])})},V=p.on=function(e,t){var n=z[e]||(z[e]=[]);return n.push(t),{remove:function(){for(var e=0;e<n.length;e++)if(n[e]===t){n.splice(e,1);return}}}},$=[],J={},K=[],Q={},G=p.map={},Y=[],Z={},et="",tt={},nt="url:",rt={},it={},st=0,ot=function(e){var t,n,r,i,s;for(t in rt)n=rt[t],r=t.match(/^url\:(.+)/),r?tt[nt+qt(r[1],e)]=n:t=="*now"?i=n:t!="*noref"&&(s=Ht(t,e),tt[s.mid]=tt[nt+s.url]=n);i&&i(Tt(e)),rt={}},ut=function(e){return e.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g,function(e){return"\\"+e})},at=function(e,t){t.splice(0,t.length);for(var n in e)t.push([n,e[n],new RegExp("^"+ut(n)+"(/|$)"),n.length]);return t.sort(function(e,t){return t[3]-e[3]}),t},ft=function(e,t){a(e,function(e){t.push([o(e[0])?new RegExp("^"+ut(e[0])+"$"):e[0],e[1]])})},lt=function(e){var t=e.name;t||(t=e,e={name:t}),e=f({main:"main"},e),e.location=e.location?e.location:t,e.packageMap&&(G[t]=e.packageMap),e.main.indexOf("./")||(e.main=e.main.substring(2)),Q[t]=e},ct=[],ht=function(e,t,n){for(var r in e){r=="waitSeconds"&&(p.waitms=(e[r]||0)*1e3),r=="cacheBust"&&(et=e[r]?o(e[r])?e[r]:(new Date).getTime()+"":"");if(r=="baseUrl"||r=="combo")p[r]=e[r];if(r=="async"){var i=e[r];p.legacyMode=A=o(i)&&/sync|legacyAsync/.test(i)?i:i?!1:O,p.async=!A}e[r]!==y&&(p.rawConfig[r]=e[r],r!="has"&&g.add("config-"+r,e[r],0,t))}p.baseUrl||(p.baseUrl="./"),/\/$/.test(p.baseUrl)||(p.baseUrl+="/");for(r in e.has)g.add(r,e.has[r],0,t);a(e.packages,lt);for(b in e.packagePaths)a(e.packagePaths[b],function(e){var t=b+"/"+e;o(e)&&(e={name:e}),e.location=t,lt(e)});at(f(G,e.map),Y),a(Y,function(e){e[1]=at(e[1],[]),e[0]=="*"&&(Y.star=e)}),at(f(J,e.paths),K),ft(e.aliases,$);if(t)ct.push({config:e.config});else for(r in e.config){var s=Ft(r,n);s.config=f(s.config||{},e.config[r])}e.cache&&(ot(),rt=e.cache,e.cache["*noref"]&&ot()),X("config",[e,p.rawConfig])};if(g("dojo-cdn")||0){var pt=v.getElementsByTagName("script"),S=0,dt,vt,mt,gt;while(S<pt.length){dt=pt[S++],(mt=dt.getAttribute("src"))&&(gt=mt.match(/(((.*)\/)|^)dojo\.js(\W|$)/i))&&(vt=gt[3]||"",t.baseUrl=t.baseUrl||vt,st=dt);if(mt=dt.getAttribute("data-dojo-config")||dt.getAttribute("djConfig"))it=p.eval("({ "+mt+" })","data-dojo-config"),st=dt}}p.rawConfig={},ht(t,1),g("dojo-cdn")&&(Q.dojo.location=vt,vt&&(vt+="/"),Q.dijit.location=vt+"../dijit/",Q.dojox.location=vt+"../dojox/"),ht(e,1),ht(it,1);var St=function(e){tn(function(){a(e.deps,ln)})},xt=function(e,t,r,i,s){var a,c;if(o(e)){a=Ft(e,i,!0);if(a&&a.executed)return a.result;throw l("undefinedModule",e)}u(e)||(ht(e,0,i),e=t,t=r);if(u(e))if(!e.length)t&&t();else{c="require*"+h();for(var d,v=[],m=0;m<e.length;)d=e[m++],v.push(Ft(d,i));a=f(Dt("",c,0,""),{injected:N,deps:v,def:t||n,require:i?i.require:p,gc:1}),Z[a.mid]=a,St(a);var g=en&&A!=O;tn(function(){Zt(a,g)}),a.executed||Nt.push(a),nn()}return s},Tt=function(e){if(!e)return p;var t=e.require;return t||(t=function(n,r,i){return xt(n,r,i,e,t)},e.require=f(t,p),t.module=e,t.toUrl=function(t){return qt(t,e)},t.toAbsMid=function(t){return It(t,e)},t.syncLoadNls=function(t){var n=Ht(t,e),r=Z[n.mid];if(!r||!r.executed)on=tt[n.mid]||tt[nt+n.url],on&&(fn(on),r=Z[n.mid]);return r&&r.executed&&r.result}),t},Nt=[],Ct=[],kt={},Lt=function(e){e.injected=T,kt[e.mid]=1,e.url&&(kt[e.url]=e.pack||1),vn()},At=function(e){e.injected=N,delete kt[e.mid],e.url&&delete kt[e.url],r(kt)&&(dn(),A==M&&(A=O))},Ot=p.idle=function(){return!Ct.length&&r(kt)&&!Nt.length&&!en},Mt=functLine truncated
|
||||
(function(userConfig,defaultConfig){var globalObject=function(){if(typeof global!=="undefined"&&typeof global!=="function"){return global}else if(typeof window!=="undefined"){return window}else if(typeof self!=="undefined"){return self}return this}();var noop=function(){},isEmpty=function(it){for(var p in it){return 0}return 1},toString={}.toString,isFunction=function(it){return toString.call(it)=="[object Function]"},isString=function(it){return toString.call(it)=="[object String]"},isArray=function(it){return toString.call(it)=="[object Array]"},forEach=function(vector,callback){if(vector){for(var i=0;i<vector.length;){callback(vector[i++])}}},mix=function(dest,src){for(var p in src){dest[p]=src[p]}return dest},makeError=function(error,info){return mix(new Error(error),{src:"dojoLoader",info:info})},uidSeed=1,uid=function(){return"_"+uidSeed++},req=function(config,dependencies,callback){return contextRequire(config,dependencies,callback,0,req)},global=globalObject,doc=global.document,element=doc&&doc.createElement("DiV"),has=req.has=function(name){return isFunction(hasCache[name])?hasCache[name]=hasCache[name](global,doc,element):hasCache[name]},hasCache=has.cache=defaultConfig.hasCache;if(isFunction(userConfig)){userConfig=userConfig(globalObject)}has.add=function(name,test,now,force){(hasCache[name]===undefined||force)&&(hasCache[name]=test);return now&&has(name)};1||has.add("host-node",userConfig.has&&"host-node"in userConfig.has?userConfig.has["host-node"]:typeof process=="object"&&process.versions&&process.versions.node&&process.versions.v8);if(1){require("./_base/configNode.js").config(defaultConfig);defaultConfig.loaderPatch.nodeRequire=require}0&&has.add("host-rhino",userConfig.has&&"host-rhino"in userConfig.has?userConfig.has["host-rhino"]:typeof load=="function"&&(typeof Packages=="function"||typeof Packages=="object"));if(0){for(var baseUrl=userConfig.baseUrl||".",arg,rhinoArgs=this.arguments,i=0;i<rhinoArgs.length;){arg=(rhinoArgs[i++]+"").split("=");if(arg[0]=="baseUrl"){baseUrl=arg[1];break}}load(baseUrl+"/_base/configRhino.js");rhinoDojoConfig(defaultConfig,baseUrl,rhinoArgs)}has.add("host-webworker",typeof WorkerGlobalScope!=="undefined"&&self instanceof WorkerGlobalScope);if(has("host-webworker")){mix(defaultConfig.hasCache,{"host-browser":0,dom:0,"dojo-dom-ready-api":0,"dojo-sniff":0,"dojo-inject-api":1,"host-webworker":1,"dojo-guarantee-console":0});defaultConfig.loaderPatch={injectUrl:function(url,callback){try{importScripts(url);callback()}catch(e){console.info("failed to load resource ("+url+")");console.error(e)}}}}for(var p in userConfig.has){has.add(p,userConfig.has[p],0,1)}var requested=1,arrived=2,nonmodule=3,executing=4,executed=5;if(1){requested="requested";arrived="arrived";nonmodule="not-a-module";executing="executing";executed="executed"}var legacyMode=0,sync="sync",xd="xd",syncExecStack=[],dojoRequirePlugin=0,checkDojoRequirePlugin=noop,transformToAmd=noop,getXhr;if(1){req.isXdUrl=noop;req.initSyncLoader=function(dojoRequirePlugin_,checkDojoRequirePlugin_,transformToAmd_){if(!dojoRequirePlugin){dojoRequirePlugin=dojoRequirePlugin_;checkDojoRequirePlugin=checkDojoRequirePlugin_;transformToAmd=transformToAmd_}return{sync:sync,requested:requested,arrived:arrived,nonmodule:nonmodule,executing:executing,executed:executed,syncExecStack:syncExecStack,modules:modules,execQ:execQ,getModule:getModule,injectModule:injectModule,setArrived:setArrived,signal:signal,finishExec:finishExec,execModule:execModule,dojoRequirePlugin:dojoRequirePlugin,getLegacyMode:function(){return legacyMode},guardCheckComplete:guardCheckComplete}};if(0||has("host-webworker")){var locationProtocol=location.protocol,locationHost=location.host;req.isXdUrl=function(url){if(/^\./.test(url)){return false}if(/^\/\//.test(url)){return true}var match=url.match(/^([^\/\:]+\:)\/+([^\/]+)/);return match&&(match[1]!=locationProtocol||locationHost&&match[2]!=locationHost)};0&&has.add("dojo-xhr-factory",1);has.add("dojo-force-activex-xhr",0&&!doc.addEventListener&&window.location.protocol=="file:");has.add("native-xhr",typeof XMLHttpRequest!="undefined");if(has("native-xhr")&&!has("dojo-force-activex-xhr")){getXhr=function(){return new XMLHttpRequest}}else{for(var XMLHTTP_PROGIDS=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"],progid,i=0;i<3;){try{progid=XMLHTTP_PROGIDS[i++];if(new ActiveXObject(progid)){break}}catch(e){}}getXhr=function(){return new ActiveXObject(progid)}}req.getXhr=getXhr;1||has.add("dojo-gettext-api",1);req.getText=function(url,async,onLoad){var xhr=getXhr();xhr.open("GET",fixupUrl(url),false);xhr.send(null);if(xhr.status==200||!location.host&&!xhr.status){if(onLoad){onLoad(xhr.responseText,async)}}else{throw makeError("xhrFailed",xhr.status)}return xhr.responseText}}}else{req.async=1}var eval_=has("csp-restrictions")?function(){}:new Function("return eval(arguments[0]);");req.eval=function(text,hint){return eval_(text+"\r\n//# sourceURL="+hint)};var listenerQueues={},error="error",signal=rLine truncated
|
||||
Function("d","d.eval = function(){return d.global.eval ? d.global.eval(arguments[0]) : eval(arguments[0]);}")(dojo)}if(0){dojo.exit=function(exitcode){quit(exitcode)}}else{dojo.exit=function(){}}if(!has("host-webworker")){1||has.add("dojo-guarantee-console",1)}if(1){has.add("console-as-object",function(){return Function.prototype.bind&&console&&typeof console.log==="object"});typeof console!="undefined"||(console={});var cn=["assert","count","debug","dir","dirxml","error","group","groupEnd","info","profile","profileEnd","time","timeEnd","trace","warn","log"];var tn;i=0;while(tn=cn[i++]){if(!console[tn]){(function(){var tcn=tn+"";console[tcn]="log"in console?function(){var a=Array.prototype.slice.call(arguments);a.unshift(tcn+":");console["log"](a.join(" "))}:function(){};console[tcn]._fake=true})()}else if(has("console-as-object")){console[tn]=Function.prototype.bind.call(console[tn],console)}}}has.add("dojo-debug-messages",!!config.isDebug);dojo.deprecated=dojo.experimental=function(){};if(has("dojo-debug-messages")){dojo.deprecated=function(behaviour,extra,removal){var message="DEPRECATED: "+behaviour;if(extra){message+=" "+extra}if(removal){message+=" -- will be removed in version: "+removal}console.warn(message)};dojo.experimental=function(moduleName,extra){var message="EXPERIMENTAL: "+moduleName+" -- APIs subject to change without notice.";if(extra){message+=" "+extra}console.warn(message)}}1||has.add("dojo-modulePaths",1);if(1){if(config.modulePaths){dojo.deprecated("dojo.modulePaths","use paths configuration");var paths={};for(p in config.modulePaths){paths[p.replace(/\./g,"/")]=config.modulePaths[p]}require({paths:paths})}}1||has.add("dojo-moduleUrl",1);if(1){dojo.moduleUrl=function(module,url){dojo.deprecated("dojo.moduleUrl()","use require.toUrl","2.0");var result=null;if(module){result=require.toUrl(module.replace(/\./g,"/")+(url?"/"+url:"")+"/*.*").replace(/\/\*\.\*/,"")+(url?"":"/")}return result}}dojo._hasResource={};return dojo})},"dojo/global":function(){define(function(){if(typeof global!=="undefined"&&typeof global!=="function"){return global}else if(typeof window!=="undefined"){return window}else if(typeof self!=="undefined"){return self}return this})},"dojo/has":function(){define(["./global","require","module"],function(global,require,module){var has=require.has||function(){};if(!1){var isBrowser=typeof window!="undefined"&&typeof location!="undefined"&&typeof document!="undefined"&&window.location==location&&window.document==document,doc=isBrowser&&document,element=doc&&doc.createElement("DiV"),cache=module.config&&module.config()||{};has=function(name){return typeof cache[name]=="function"?cache[name]=cache[name](global,doc,element):cache[name]};has.cache=cache;has.add=function(name,test,now,force){(typeof cache[name]=="undefined"||force)&&(cache[name]=test);return now&&has(name)};0&&has.add("host-browser",isBrowser);1||has.add("host-node",typeof process=="object"&&process.versions&&process.versions.node&&process.versions.v8);0&&has.add("host-rhino",typeof load=="function"&&(typeof Packages=="function"||typeof Packages=="object"));0&&has.add("dom",isBrowser);0&&has.add("dojo-dom-ready-api",1);0&&has.add("dojo-sniff",1)}if(0){has.add("dom-addeventlistener",!!document.addEventListener);has.add("touch","ontouchstart"in document||"onpointerdown"in document&&navigator.maxTouchPoints>0||window.navigator.msMaxTouchPoints);has.add("touch-events","ontouchstart"in document);has.add("pointer-events","pointerEnabled"in window.navigator?window.navigator.pointerEnabled:"PointerEvent"in window);has.add("MSPointer",window.navigator.msPointerEnabled);has.add("touch-action",has("touch")&&has("pointer-events"));has.add("device-width",screen.availWidth||innerWidth);var form=document.createElement("form");has.add("dom-attributes-explicit",form.attributes.length==0);has.add("dom-attributes-specified-flag",form.attributes.length>0&&form.attributes.length<40)}has.clearElement=function(element){element.innerHTML="";return element};has.normalize=function(id,toAbsMid){var tokens=id.match(/[\?:]|[^:\?]*/g),i=0,get=function(skip){var term=tokens[i++];if(term==":"){return 0}else{if(tokens[i++]=="?"){if(!skip&&has(term)){return get()}else{get(true);return get(skip)}}return term||0}};id=get();return id&&toAbsMid(id)};has.load=function(id,parentRequire,loaded){if(id){parentRequire([id],loaded)}else{loaded()}};return has})},"dojo/_base/config":function(){define(["../global","../has","require"],function(global,has,require){var result={};if(1){var src=require.rawConfig,p;for(p in src){result[p]=src[p]}}else{var adviseHas=function(featureSet,prefix,booting){for(p in featureSet){p!="has"&&has.add(prefix+p,featureSet[p],0,booting)}};result=1?require.rawConfig:global.dojoConfig||global.djConfig||{};adviseHas(result,"config",1);adviseHas(result.has,"",1)}if(!result.locale&&typeof navigator!="undefined"){var language=navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.language||navigator.userLanguLine truncated
|
||||
target[method]&&target[method].apply(target,args)}while(event&&event.bubbles&&(target=target.parentNode));return event&&event.cancelable&&event};var captures=has("event-focusin")?{}:{focusin:"focus",focusout:"blur"};if(!has("event-stopimmediatepropagation")){var stopImmediatePropagation=function(){this.immediatelyStopped=true;this.modified=true};var addStopImmediate=function(listener){return function(event){if(!event.immediatelyStopped){event.stopImmediatePropagation=stopImmediatePropagation;return listener.apply(this,arguments)}}}}if(has("dom-addeventlistener")){on.emit=function(target,type,event){if(target.dispatchEvent&&document.createEvent){var ownerDocument=target.ownerDocument||document;var nativeEvent=ownerDocument.createEvent("HTMLEvents");nativeEvent.initEvent(type,!!event.bubbles,!!event.cancelable);for(var i in event){if(!(i in nativeEvent)){nativeEvent[i]=event[i]}}return target.dispatchEvent(nativeEvent)&&nativeEvent}return syntheticDispatch.apply(on,arguments)}}else{on._fixEvent=function(evt,sender){if(!evt){var w=sender&&(sender.ownerDocument||sender.document||sender).parentWindow||window;evt=w.event}if(!evt){return evt}try{if(lastEvent&&evt.type==lastEvent.type&&evt.srcElement==lastEvent.target){evt=lastEvent}}catch(e){}if(!evt.target){evt.target=evt.srcElement;evt.currentTarget=sender||evt.srcElement;if(evt.type=="mouseover"){evt.relatedTarget=evt.fromElement}if(evt.type=="mouseout"){evt.relatedTarget=evt.toElement}if(!evt.stopPropagation){evt.stopPropagation=stopPropagation;evt.preventDefault=preventDefault}switch(evt.type){case"keypress":var c="charCode"in evt?evt.charCode:evt.keyCode;if(c==10){c=0;evt.keyCode=13}else if(c==13||c==27){c=0}else if(c==3){c=99}evt.charCode=c;_setKeyChar(evt);break}}return evt};var lastEvent,IESignal=function(handle){this.handle=handle};IESignal.prototype.remove=function(){delete _dojoIEListeners_[this.handle]};var fixListener=function(listener){return function(evt){evt=on._fixEvent(evt,this);var result=listener.call(this,evt);if(evt.modified){if(!lastEvent){setTimeout(function(){lastEvent=null})}lastEvent=evt}return result}};var fixAttach=function(target,type,listener){listener=fixListener(listener);if(((target.ownerDocument?target.ownerDocument.parentWindow:target.parentWindow||target.window||window)!=top||has("jscript")<5.8)&&!has("config-_allow_leaks")){if(typeof _dojoIEListeners_=="undefined"){_dojoIEListeners_=[]}var emitter=target[type];if(!emitter||!emitter.listeners){var oldListener=emitter;emitter=Function("event","var callee = arguments.callee; for(var i = 0; i<callee.listeners.length; i++){var listener = _dojoIEListeners_[callee.listeners[i]]; if(listener){listener.call(this,event);}}");emitter.listeners=[];target[type]=emitter;emitter.global=this;if(oldListener){emitter.listeners.push(_dojoIEListeners_.push(oldListener)-1)}}var handle;emitter.listeners.push(handle=emitter.global._dojoIEListeners_.push(listener)-1);return new IESignal(handle)}return aspect.after(target,type,listener,true)};var _setKeyChar=function(evt){evt.keyChar=evt.charCode?String.fromCharCode(evt.charCode):"";evt.charOrCode=evt.keyChar||evt.keyCode};var stopPropagation=function(){this.cancelBubble=true};var preventDefault=on._preventDefault=function(){this.bubbledKeyCode=this.keyCode;if(this.ctrlKey){try{this.keyCode=0}catch(e){}}this.defaultPrevented=true;this.returnValue=false;this.modified=true}}if(has("touch")){var EventDelegate=function(){};var windowOrientation=window.orientation;var fixTouchListener=function(listener){return function(originalEvent){var event=originalEvent.corrected;if(!event){var type=originalEvent.type;try{delete originalEvent.type}catch(e){}if(originalEvent.type){if(has("touch-can-modify-event-delegate")){EventDelegate.prototype=originalEvent;event=new EventDelegate}else{event={};for(var name in originalEvent){event[name]=originalEvent[name]}}event.preventDefault=function(){originalEvent.preventDefault()};event.stopPropagation=function(){originalEvent.stopPropagation()}}else{event=originalEvent;event.type=type}originalEvent.corrected=event;if(type=="resize"){if(windowOrientation==window.orientation){return null}windowOrientation=window.orientation;event.type="orientationchange";return listener.call(this,event)}if(!("rotation"in event)){event.rotation=0;event.scale=1}if(window.TouchEvent&&originalEvent instanceof TouchEvent){var firstChangeTouch=event.changedTouches[0];for(var i in firstChangeTouch){delete event[i];event[i]=firstChangeTouch[i]}}}return listener.call(this,event)}}}return on})},"dojo/topic":function(){define(["./Evented"],function(Evented){var hub=new Evented;return{publish:function(topic,event){return hub.emit.apply(hub,arguments)},subscribe:function(topic,listener){return hub.on.apply(hub,arguments)}}})},"dojo/Evented":function(){define(["./aspect","./on"],function(aspect,on){"use strict";var after=aspect.after;function Evented(){}Evented.prototype={on:function(type,listener){return on.parse(this,type,listener,function(target,type){reLine truncated
|
||||
},isRejected:function(){throwAbstract()},isFulfilled:function(){throwAbstract()},isCanceled:function(){throwAbstract()},always:function(callbackOrErrback){return this.then(callbackOrErrback,callbackOrErrback)},catch:function(errback){return this.then(null,errback)},otherwise:function(errback){return this.then(null,errback)},trace:function(){return this},traceRejected:function(){return this},toString:function(){return"[object Promise]"}})})},"dojo/promise/instrumentation":function(){define(["./tracer","../has","../_base/lang","../_base/array"],function(tracer,has,lang,arrayUtil){has.add("config-useDeferredInstrumentation","report-unhandled-rejections");function logError(error,rejection,deferred){if(error&&error.log===false){return}var stack="";if(error&&error.stack){stack+=error.stack}if(rejection&&rejection.stack){stack+="\n ----------------------------------------\n rejected"+rejection.stack.split("\n").slice(1).join("\n").replace(/^\s+/," ")}if(deferred&&deferred.stack){stack+="\n ----------------------------------------\n"+deferred.stack}console.error(error,stack)}function reportRejections(error,handled,rejection,deferred){if(!handled){logError(error,rejection,deferred)}}var errors=[];var activeTimeout=false;var unhandledWait=1e3;function trackUnhandledRejections(error,handled,rejection,deferred){if(!arrayUtil.some(errors,function(obj){if(obj.error===error){if(handled){obj.handled=true}return true}})){errors.push({error:error,rejection:rejection,handled:handled,deferred:deferred,timestamp:(new Date).getTime()})}if(!activeTimeout){activeTimeout=setTimeout(logRejected,unhandledWait)}}function logRejected(){var now=(new Date).getTime();var reportBefore=now-unhandledWait;errors=arrayUtil.filter(errors,function(obj){if(obj.timestamp<reportBefore){if(!obj.handled){logError(obj.error,obj.rejection,obj.deferred)}return false}return true});if(errors.length){activeTimeout=setTimeout(logRejected,errors[0].timestamp+unhandledWait-now)}else{activeTimeout=false}}return function(Deferred){var usage=has("config-useDeferredInstrumentation");if(usage){tracer.on("resolved",lang.hitch(console,"log","resolved"));tracer.on("rejected",lang.hitch(console,"log","rejected"));tracer.on("progress",lang.hitch(console,"log","progress"));var args=[];if(typeof usage==="string"){args=usage.split(",");usage=args.shift()}if(usage==="report-rejections"){Deferred.instrumentRejected=reportRejections}else if(usage==="report-unhandled-rejections"||usage===true||usage===1){Deferred.instrumentRejected=trackUnhandledRejections;unhandledWait=parseInt(args[0],10)||unhandledWait}else{throw new Error("Unsupported instrumentation usage <"+usage+">")}}}})},"dojo/promise/tracer":function(){define(["../_base/lang","./Promise","../Evented"],function(lang,Promise,Evented){"use strict";var evented=new Evented;var emit=evented.emit;evented.emit=null;function emitAsync(args){setTimeout(function(){emit.apply(evented,args)},0)}Promise.prototype.trace=function(){var args=lang._toArray(arguments);this.then(function(value){emitAsync(["resolved",value].concat(args))},function(error){emitAsync(["rejected",error].concat(args))},function(update){emitAsync(["progress",update].concat(args))});return this};Promise.prototype.traceRejected=function(){var args=lang._toArray(arguments);this.otherwise(function(error){emitAsync(["rejected",error].concat(args))});return this};return evented})},"dojo/when":function(){define(["./Deferred","./promise/Promise"],function(Deferred,Promise){"use strict";return function when(valueOrPromise,callback,errback,progback){var receivedPromise=valueOrPromise&&typeof valueOrPromise.then==="function";var nativePromise=receivedPromise&&valueOrPromise instanceof Promise;if(!receivedPromise){if(arguments.length>1){return callback?callback(valueOrPromise):valueOrPromise}else{return(new Deferred).resolve(valueOrPromise)}}else if(!nativePromise){var deferred=new Deferred(valueOrPromise.cancel);valueOrPromise.then(deferred.resolve,deferred.reject,deferred.progress);valueOrPromise=deferred.promise}if(callback||errback||progback){return valueOrPromise.then(callback,errback,progback)}return valueOrPromise}})},"dojo/_base/json":function(){define(["./kernel","../json"],function(dojo,json){dojo.fromJson=function(js){return eval("("+js+")")};dojo._escapeString=json.stringify;dojo.toJsonIndentStr="\t";dojo.toJson=function(it,prettyPrint){return json.stringify(it,function(key,value){if(value){var tf=value.__json__||value.json;if(typeof tf=="function"){return tf.call(value)}}return value},prettyPrint&&dojo.toJsonIndentStr)};return dojo})},"dojo/json":function(){define(["./has"],function(has){"use strict";var hasJSON=typeof JSON!="undefined";has.add("json-parse",hasJSON);has.add("json-stringify",hasJSON&&JSON.stringify({a:0},function(k,v){return v||1})=='{"a":1}');if(has("json-stringify")){return JSON}else{var escapeString=function(str){return('"'+str.replace(/(["\\])/g,"\\$1")+'"').replace(/[\f]/g,"\\f").replace(/[\b]/g,"\\b").replace(/[\n]/g,"\\n").reLine truncated
|
||||
if(pending[url]){pending[url].push(finish)}else{var pendingList=pending[url]=[finish];getText(url,!require.async,function(text){theCache[absMid]=theCache[url]=text;for(var i=0;i<pendingList.length;){pendingList[i++](text)}delete pending[url]})}}else{finish(text)}}}})},"build/argv":function(){define(["require","dojo/json","dojo/has","./fs","./fileUtils","./process","./commandLineArgs","./stringify","./version","./messages","./v1xProfiles","dojo/text!./help.txt"],function(require,json,has,fs,fileUtils,process,argv,stringify,version,messages,v1xProfiles,help){eval(require.scopeify("./fileUtils"));var result={profiles:[]},cwd=process.cwd(),dojoPath=computePath(require.toUrl("dojo/package.json").match(/(.+)\/package\.json$/)[1],cwd),utilBuildscriptsPath=compactPath(catPath(dojoPath,"/../util/buildscripts")),printVersion=0,printHelp=0,checkArgs=0,illegalArgumentValue=function(argumentName,position){messages.log("inputIllegalCommandlineArg",["switch",argumentName,"position",position])},evalScriptArg=function(arg){if(arg=="true"){return true}else if(arg=="false"){return false}else if(arg=="null"){return null}else if(isNaN(arg)){return arg+""}else{return Number(arg)}},readProfile=function(scriptType,filename){var path=getFilepath(filename);if(!fileExists(filename)){messages.log("inputFileDoesNotExist",[scriptType,filename]);return 0}try{var src=fs.readFileSync(filename,"utf8")}catch(e){messages.log("inputFailedReadfile",[scriptType,filename,"error",e]);return 0}if(scriptType=="profileFile"){messages.log("inputProfileFileDeprecated");scriptType="profile"}var fixupBasePath=function(profile){var fixupBasePath=function(path,referencePath){if(path){path=computePath(path,referencePath)}else if(typeof path=="undefined"){path=referencePath}return path};profile.basePath=fixupBasePath(profile.basePath,path);if(profile.build&&profile.build.basePath){profile.build.basePath=fixupBasePath(profile.build.basePath,path)}},f,profile;try{if(scriptType=="require"){f=new Function("var __result, require= function(config){__result=config;};"+src+"; return __result || require;");profile=f();fixupBasePath(profile)}else if(scriptType=="dojoConfig"){f=new Function(src+"; return dojoConfig;");profile=f();fixupBasePath(profile)}else if(scriptType=="profile"){f=new Function("selfPath","logger","profile","dependencies",src+"; return {profile:profile, dependencies:dependencies}");profile=f(path,messages,0,0);if(profile.profile){profile=profile.profile;fixupBasePath(profile)}else{profile=v1xProfiles.processProfile(profile.dependencies,dojoPath,utilBuildscriptsPath,path)}}profile.selfFilename=filename;messages.log("pacify","processing "+scriptType+" resource "+filename);return profile}catch(e){messages.log("inputFailedToEvalProfile",[scriptType,filename,"error",e]);return 0}},processHtmlDir=function(arg){if(!fileUtils.dirExists(arg)){messages.log("inputHTMLDirDoesNotExist",["directory",arg]);return 0}else{var htmlFiles=[];fs.readdirSync(arg).forEach(function(filename){if(/\.html$/.test(filename)){htmlFiles.push(arg+"/"+filename)}});if(!htmlFiles.length){messages.log("inputHTMLDirNoFiles",["directory",arg]);return 0}else{return v1xProfiles.processHtmlFiles(htmlFiles,dojoPath,utilBuildscriptsPath)}}},processHtmlFiles=function(arg){var htmlFiles=arg.split(",").filter(function(filename){if(!fileUtils.fileExists(filename)){messages.log("inputHTMLFileDoesNotExist",["filename",filename]);return 0}else{return 1}});if(htmlFiles.length){return v1xProfiles.processHtmlFiles(htmlFiles,dojoPath,utilBuildscriptsPath)}else{return 0}},readPackageJson=function(filename,missingMessageId){if(!fileUtils.fileExists(filename)){messages.log(missingMessageId,["filename",filename])}else{try{var result=json.parse(fs.readFileSync(filename,"utf8"));result.selfFilename=filename;return result}catch(e){messages.log("inputMalformedPackageJson",["filename",filename])}}return 0},processPackageJson=function(packageRoot){var packageJsonFilename=catPath(packageRoot,"package.json"),packageJson=readPackageJson(packageJsonFilename,"inputMissingPackageJson");if(packageJson){packageJson.selfFilename=packageJsonFilename;result.profiles.push({packages:[{name:packageJson.progName||packageJson.name,packageJson:packageJson}]})}},readCopyrightOrBuildNotice=function(filename,hint){if(!fileExists(filename)){messages.log("inputFileDoesNotExist",[hint,filename])}try{var prop=hint=="copyrightFile"?"copyright":"buildNotice";result[prop]=fs.readFileSync(filename,"utf8")}catch(e){messages.log("inputFailedReadfile",[hint,filename,"error",e])}},normalizeSwitch={"-p":"profile","--profile":"profile","--profileFile":"profileFile",p:"profile",profile:"profile",profileFile:"profileFile","--package":"package",package:"package","--require":"require",require:"require","--dojoConfig":"dojoConfig",dojoConfig:"dojoConfig","--htmlDir":"htmlDir",htmlDir:"htmlDir","--htmlFiles":"htmlFiles",htmlFiles:"htmlFiles","--copyrightFile":"copyrightFile",copyrightFile:"copyrightFile","--buildNoticeFile":"buildNoticeFile",buildNotLine truncated
|
||||
if(!/paths|plugins|messages|transforms|staticHasFeatures|packages|packagePaths|defaultConfig/.test(p)){bc[p]=src[p]}}["paths","plugins","transforms","staticHasFeatures"].forEach(function(p){bc[p]=mix(bc[p],src[p])});if(src.messageCategories){for(p in src.messageCategories){bc.addCategory(p,src.messageCategories[p])}}(src.messages||[]).forEach(function(item){bc.addMessage.apply(bc,item)});for(var base in src.packagePaths){src.packagePaths[base].forEach(function(packageInfo){if(isString(packageInfo)){packageInfo={name:packageInfo}}packageInfo.location=catPath(base,packageInfo.name);mixPackage(packageInfo)})}(src.packages||[]).forEach(function(packageInfo){if(isString(packageInfo)){packageInfo={name:packageInfo}}mixPackage(packageInfo)});for(p in src.defaultConfig){if(p=="hasCache"){mix(bc.defaultConfig.hasCache,src.defaultConfig.hasCache)}else{bc.defaultConfig[p]=src.defaultConfig[p]}}};argv.args.profiles.forEach(function(item){var temp=mix({},item),build=item.build;delete temp.build;mixProfileObject(temp);build&&mixProfileObject(build)});cleanDeprecated(argv.args,"command line");for(var argName in argv.args)if(argName!="profiles"){bc[argName]=argv.args[argName]}bc.basePath=computePath(bc.basePath,process.cwd());var releaseDir=catPath(bc.releaseDir||"../release",bc.releaseName||"");bc.destBasePath=computePath(releaseDir,bc.basePath);bc.copyright=isNonemptyString(bc.copyright)?maybeRead(computePath(bc.copyright,bc.basePath))||bc.copyright:"";bc.copyrightLayers=!!bc.copyrightLayers;bc.copyrightNonlayers=!!bc.copyrightNonlayers;(function(){for(var property in{files:1,dirs:1,trees:1}){if(bc[property]instanceof Array){bc[property]=bc[property].map(function(item){return cleanupFilenamePair(item,bc.basePath,bc.destBasePath,property)})}}})();(function(){var cleanSet={},src,dest;for(src in bc.replacements){cleanSet[computePath(src,bc.basePath)]=bc.replacements[src]}bc.replacements=cleanSet})();if(!("mini"in bc)){bc.mini=true}if(!("copyTests"in bc)){bc.copyTests=!bc.mini}if(isString(bc.copyTests)){bc.copyTests=bc.copyTests.toLowerCase()}if(bc.copyTests!="build"){bc.copyTests=!!bc.copyTests}function getDiscreteLocales(locale){for(var locales=locale.split("-"),result=[],current="",i=0;i<locales.length;i++){result.push(current+=(i?"-":"")+locales[i])}return result}if(isString(bc.localeList)){bc.localeList=bc.localeList.split(",");if(bc.localeList.length){bc.localeList=bc.localeList.map(function(locale){return lang.trim(locale)})}}if(bc.localeList&&bc.localeList.length){if(bc.localeList.indexOf("ROOT")==-1){bc.localeList.push("ROOT")}var localeList={};bc.localeList.forEach(function(locale){locale=lang.trim(locale);localeList[locale]=getDiscreteLocales(locale)});bc.localeList.discreteLocales=localeList}else{bc.localeList=false}(function(){function processPackage(pack){var packName=pack.name,basePath=pack.basePath||bc.basePath;if(!pack.packageJson){pack.packageJson=argv.readPackageJson(catPath(computePath(pack.location||"./"+packName,basePath),"package.json"),"missingPackageJson")}var packageJson=pack.packageJson;if(packageJson){if(packageJson.version){bc.log("packageVersion",["package",packName,"version",packageJson.version]);if(typeof bc.version=="undefined"&&packName=="dojo"){bc.version=packageJson.version}}if(packageJson.main&&!pack.main){pack.main=packageJson.main}if(packageJson.directories&&packageJson.directories.lib&&!pack.location){pack.location=catPath(getFilepath(packageJson.selfFilename),packageJson.directories.lib)}if("dojoBuild"in packageJson){var defaultProfile=argv.readProfile("profile",catPath(getFilepath(packageJson.selfFilename),packageJson.dojoBuild));for(var p in defaultProfile){if(!(p in pack)){pack[p]=defaultProfile[p]}else if(p in{resourceTags:1}){mix(pack[p],defaultProfile[p])}}}else{bc.log("missingProfile",["package",packageJson.name])}}pack.main=isString(pack.main)?pack.main:"main";if(pack.main.indexOf("./")===0){pack.main=pack.main.substring(2)}if(pack.destMain&&pack.destMain.indexOf("./")===0){pack.destMain=pack.destMain.substring(2)}pack.location=computePath(pack.location||"./"+packName,basePath);pack.copyright=isNonemptyString(pack.copyright)?maybeRead(computePath(pack.copyright,pack.location))||maybeRead(computePath(pack.copyright,bc.basePath))||pack.copyright:pack.copyright?bc.copyright:"";pack.copyrightLayers=isDefined(pack.copyrightLayers)?!!pack.copyrightLayers:bc.copyrightLayers;pack.copyrightNonlayers=isDefined(pack.copyrightNonlayers)?!!pack.copyrightNonlayers:bc.copyrightNonlayers;var destPack=bc.destPackages[packName]={name:pack.destName||packName,main:pack.destMain||pack.main,location:computePath(pack.destLocation||"./"+(pack.destName||packName),bc.destBasePath)};var providedMids=pack.providedMids||[];pack.providedMids=[];array.forEach(providedMids,function(mid){pack.providedMids[mid]=true});delete pack.destName;delete pack.destMain;delete pack.destLocation;if(!pack.trees){pack.trees=[[pack.location,destPack.location,/(\/\.)|(^\.)|(~$)/]]}for(var property in{files:1,dirs:1,trees:1})Line truncated
|
||||
var getFiletype=fileUtils.getFiletype,encodingMap=bc.transformConfig.read&&bc.transformConfig.read.encoding||{css:"utf8",html:"utf8",htm:"utf8",js:"utf8",json:"utf8",asc:"utf8",c:"utf8",cpp:"utf8",log:"utf8",conf:"utf8",text:"utf8",txt:"utf8",dtd:"utf8",xml:"utf8",png:undefined,jpg:undefined,jpeg:undefined,gif:undefined};return function(resource,callback){resource.getText=function(){if(!this.replacementsApplied){this.replacementsApplied=true;if(bc.replacements[this.src]){this.text=replace(this.text,bc.replacements[this.src])}}return this.text};resource.setText=function(text){resource.text=text;resource.getText=function(){return this.text};return text};var filetype=getFiletype(resource.src,1);resource.encoding=resource.encoding||!(filetype in encodingMap)&&"utf8"||encodingMap[filetype];fs.readFile(resource.src,resource.encoding,function(err,data){if(!err){resource.text=data}callback(resource,err)});return callback}})},"build/transforms/writeAmd":function(){define(["../buildControl","../fileUtils","../fs","dojo/_base/lang","dojo/json"],function(bc,fileUtils,fs,lang,json){var computingLayers={},computeLayerContents=function(layerModule,include,exclude){if(computingLayers[layerModule.mid]){bc.log("amdCircularDependency",["module",layerModule.mid]);return{}}computingLayers[layerModule.mid]=1;var includeSet={},visited,includePhase,traverse=function(module){var mid=module.mid;if(visited[mid]){return}visited[mid]=1;if(includePhase){includeSet[mid]=module}else{delete includeSet[mid]}if(module!==layerModule&&module.layer){var layerModuleSet=module.moduleSet||computeLayerContents(module,module.layer.include,module.layer.exclude);for(var p in layerModuleSet){if(includePhase){includeSet[p]=layerModuleSet[p]}else{delete includeSet[p]}}}else{for(var deps=module.deps,i=0;deps&&i<deps.length;traverse(deps[i++])){}}};visited={};includePhase=true;traverse(layerModule);include.forEach(function(mid){var module=bc.amdResources[bc.getSrcModuleInfo(mid,layerModule).mid];if(!module){bc.log("amdMissingLayerIncludeModule",["missing",mid,"layer",layerModule.mid])}else{traverse(module)}});visited={};includePhase=false;exclude.forEach(function(mid){var module=bc.amdResources[bc.getSrcModuleInfo(mid,layerModule).mid];if(!module){bc.log("amdMissingLayerExcludeModule",["missing",mid,"layer",layerModule.mid])}else{traverse(module)}});layerModule.moduleSet=includeSet;delete computingLayers[layerModule.mid];var result={};for(var p in includeSet){result[p]=includeSet[p]}return result},insertAbsMid=function(text,resource){return!resource.mid||resource.tag.hasAbsMid||!bc.insertAbsMids?text:text.replace(/(define\s*\(\s*)(.*)/,'$1"'+resource.mid+'", $2')},pushString=function(strings,pair){strings[pair[0]]=pair[1]},appendStringsToCache=function(strings,cache){for(var p in strings){cache.push("'"+p+"':"+strings[p])}},getPreloadL10nRootPath=function(dest){var match=dest.match(/(.+)\/([^\/]+)$/);return match[1]+"/nls/"+match[2]},flattenRootBundle=function(resource){if(resource.flattenedBundles){return}resource.flattenedBundles={};var scheduledToFlatten={};bc.localeList.forEach(function(locale){scheduledToFlatten[locale]=1});bc.localeList.forEach(function(locale){var accumulator=lang.mixin({},resource.bundleValue.root);if(!bc.localeList.discreteLocales[locale]){console.log(resource.mid,locale)}else{bc.localeList.discreteLocales[locale].forEach(function(discreteLocale){var localizedBundle=resource.localizedSet[discreteLocale];if(localizedBundle&&localizedBundle.bundleValue){lang.mixin(accumulator,localizedBundle.bundleValue)}});var set={};if(locale==="ROOT"){for(var p in resource.localizedSet)set[p]=1}else{for(var p in resource.localizedSet)if(!scheduledToFlatten[p]&&p.indexOf(locale)==0&&p.length>locale.length){set[p]=1}}accumulator._localized=set}resource.flattenedBundles[locale]=accumulator})},getFlattenedBundles=function(resource,rootBundles){rootBundles.forEach(flattenRootBundle);var newline=bc.newline,rootPath=getPreloadL10nRootPath(resource.dest.match(/(.+)(\.js)$/)[1]),mid,cache;bc.localeList.forEach(function(locale){cache=[];rootBundles.forEach(function(rootResource){cache.push("'"+rootResource.prefix+rootResource.bundle+"':"+json.stringify(rootResource.flattenedBundles[locale])+newline)});mid=getPreloadL10nRootPath(resource.mid)+"_"+locale;var flattenedResource={src:"*synthetic*",dest:rootPath+"_"+locale+".js",pid:resource.pid,mid:mid,pack:resource.pack,deps:[],tag:{flattenedNlsBundle:1},encoding:"utf8",text:"define("+(bc.insertAbsMids?"'"+mid+"',{":"{")+newline+cache.join(","+newline)+"});",getText:function(){return this.text}};if(bc.insertAbsMids){flattenedResource.tag.hasAbsMid=1}bc.start(flattenedResource)})},getLayerText=function(resource,resourceText){var newline=bc.newline,rootBundles=[],strings={},cache=[],layer=resource.layer,moduleSet=computeLayerContents(resource,layer.include,layer.exclude),includeLocales="includeLocales"in layer?layer.includeLocales:bc.includeLocales;for(var p in moduleSet){if(p!=resource.mid||resourceText===falsLine truncated
|
||||
;resource.text=insertSymbols(resource,bc.symbolTable)}}return 0}})},"build/transforms/hasReport":function(){define(["../buildControl","../stringify"],function(bc,stringify){return function(){if(bc.hasReport){var p,features=bc.hasFeatures,sorted=[];for(p in features){if(1||!(p in bc.staticHasFeatures)){sorted.push([[p],features[p]])}}sorted.sort(function(lhs,rhs){return lhs[0]<rhs[0]?-1:lhs[0]>rhs[0]?1:0});var sort=function(set){var sorted=[];for(var p in set){sorted.push(p)}return sorted.sort()};var newline=bc.newline;bc.log("hasReport",sorted.map(function(item){return"\t// "+sort(item[1]).join(", ")+newline+"\t '"+item[0]+"':1"}).join(","+newline+newline))}return 0}})},"build/transforms/writeCss":function(){define(["../buildControl","../fileUtils","../fs"],function(bc,fileUtils,fs){return function(resource,callback){var waitCount=0,errors=[],onWriteComplete=function(err){if(err){errors.push(err)}if(--waitCount==0){callback(resource,errors.length&&errors)}},doWrite=function(filename,text,encoding){fileUtils.ensureDirectoryByFilename(filename);waitCount++;fs.writeFile(filename,bc.newlineFilter(text,resource,"writeCss"),encoding||"utf8",onWriteComplete)},wroteExterns=0;try{doWrite(resource.dest,resource.text);if(resource.compactDest!=resource.dest){doWrite(resource.compactDest,resource.compactText)}if(wroteExterns){return callback}wroteExterns=1;var destDirToExternSet=bc.destDirToExternSet,dir,resourceSet,src;for(dir in destDirToExternSet){resourceSet=destDirToExternSet[dir];for(src in resourceSet){doWrite(dir+"/"+resourceSet[src],bc.resources[src].text,resource.encoding)}}}catch(e){if(waitCount){errors.push(e);return 0}else{return e}}return callback}})},"build/transforms/depsDeclarative":function(){define(["../buildControl","../fs","../fileUtils","dojo/_base/lang","dojo/_base/json"],function(bc,fs,fileUtils,lang,json){return function(resource){var aggregateDeps=[],interningAutoRequireRegExp=/\sdata-dojo-(?:type|mids)\s*=\s*["']([^"']+\/[^"']+)["']/gi,interningDeclarativeRequireRegExp=/<script\s+[^>]*type=["']dojo\/require["'][^>]*>([^<]*)<\/script>/gi,processAutoRequire=function(){var mids=[],str=resource.text,match;while(match=interningAutoRequireRegExp.exec(str)){match[1].split(/\s*,\s*/).forEach(function(mid){mids.push(mid)})}return mids},processDeclarativeRequire=function(){var mids=[],str=resource.text,match;while(match=interningDeclarativeRequireRegExp.exec(str)){try{var h=json.fromJson("{"+match[1]+"}")}catch(e){bc.log("declarativeRequireFailed",["resource",resource.src,"error",e])}for(var i in h){var mid=h[i];if(typeof mid=="string"){mids.push(mid)}else{bc.log("userWarn",["declarative require has invalid value","resource",resource.src,"key",i,"value",mid])}}}return mids};aggregateDeps=aggregateDeps.concat(processAutoRequire());aggregateDeps=aggregateDeps.concat(processDeclarativeRequire());for(var mid in bc.amdResources){if(bc.amdResources[mid].layer){var includes=bc.amdResources[mid].layer.include,idx=includes.indexOf(resource.mid);if(~idx){includes.splice(idx,1);aggregateDeps.forEach(function(dep){if(!/^(require|exports|module)$/.test(dep)){if(!~includes.indexOf(dep)){includes.push(dep)}}})}}}}})},"build/transforms/optimizeCss":function(){define(["../buildControl","../fileUtils","dojo/_base/lang"],function(bc,fileUtils,lang){var cssImportRegExp=/\@import\s+(url\()?\s*([^);]+)\s*(\))?([\w, ]*)(;)?/g,cssUrlRegExp=/url\(\s*([^\)]+)\s*\)?/g,checkSlashes=function(name){return name.replace(/\\/g,"/")},cssImportIgnore=bc.cssImportIgnore?bc.cssImportIgnore.split(",").map(function(item){return lang.trim(item)}).join(",")+",":"",cleanCssUrlQuotes=function(url){url=lang.trim(url);if(url.charAt(0)=="'"||url.charAt(0)=='"'){url=url.substring(1,url.length-1)}return url},removeComments=function(text,filename){var originalText=text,startIndex=-1,endIndex;while((startIndex=text.indexOf("/*"))!=-1){endIndex=text.indexOf("*/",startIndex+2);if(endIndex==-1){bc.log("cssOptimizeImproperComment",["CSS file",filename]);return originalText}text=text.substring(0,startIndex)+text.substring(endIndex+2,text.length)}return text},isRelative=function(url){var colonIndex=url.indexOf(":");return url.charAt(0)!="/"&&(colonIndex==-1||colonIndex>url.indexOf("/"))},getDestRelativeFilename=function(dest,relativeResource){var referenceSegments=dest.split("/"),relativeSegments=relativeResource.dest.split("/");referenceSegments.pop();while(referenceSegments.length&&relativeSegments.length&&referenceSegments[0]==relativeSegments[0]){referenceSegments.shift();relativeSegments.shift()}for(var i=0;i<referenceSegments.length;i++){relativeSegments.unshift("..")}return relativeSegments.join("/")},getDestRelativeUrlFromSrcUrl=function(dest,fullSrcFilename,msgInfo){var relativeResource=bc.resources[fullSrcFilename];if(relativeResource){return getDestRelativeFilename(dest,relativeResource)}else{bc.log("cssOptimizeUnableToResolveURL",msgInfo)}return 0},flattenCss=function(resource){if(resource.optimizedText){return}var dest=resource.dest,src=resourcLine truncated
|
||||
Reference in new issue
Block a user