// All material copyright ESRI, All Rights Reserved, unless otherwise specified.
// See https://js.arcgis.com/4.11/esri/copyright.txt for details.
//>>built
(function(b,e){var m,d=function(){return"undefined"!==typeof v&&"function"!==typeof v?v:"undefined"!==typeof window?window:"undefined"!==typeof self?self:this}(),k=function(){},l=function(a){for(var c in a)return 0;return 1},h={}.toString,a=function(a){return"[object Function]"==h.call(a)},c=function(a){return"[object String]"==h.call(a)},f=function(a){return"[object Array]"==h.call(a)},n=function(a,c){if(a)for(var f=0;f<a.length;)c(a[f++])},g=function(a,c){for(var f in c)a[f]=c[f];return a},q=function(a,
c){return g(Error(a),{src:"dojoLoader",info:c})},p=1,t=function(){return"_"+p++},r=function(a,c,f){return Ea(a,c,f,0,r)},v=d,u=v.document,z=u&&u.createElement("DiV"),y=r.has=function(c){return a(x[c])?x[c]=x[c](v,u,z):x[c]},x=y.cache=e.hasCache;a(b)&&(b=b(d));y.add=function(a,c,f,g){(void 0===x[a]||g)&&(x[a]=c);return f&&y(a)};y.add("host-webworker","undefined"!==typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope);y("host-webworker")&&(g(e.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}),e.loaderPatch={injectUrl:function(a,c){try{importScripts(a),c()}catch(mb){console.info("failed to load resource ("+a+")"),console.error(mb)}}});for(var w in b.has)y.add(w,b.has[w],0,1);r.async=1;var A=y("csp-restrictions")?function(){}:new Function("return eval(arguments[0]);");r.eval=function(a,c){return A(a+"\r\n//# sourceURL\x3d"+c)};var B={},F=r.signal=function(a,c){a=B[a];n(a&&a.slice(0),function(a){a.apply(null,
f(c)?c:[c])})};w=r.on=function(a,c){var f=B[a]||(B[a]=[]);f.push(c);return{remove:function(){for(var a=0;a<f.length;a++)if(f[a]===c){f.splice(a,1);break}}}};var C=[],E={},G=[],Q={},V=r.map={},R=[],I={},W="",M={},U={},d={},O=0;if(!y("foreign-loader"))var J=function(a,c){c=!1!==c;var f,g,p,n;for(f in U)g=U[f],(p=f.match(/^url\:(.+)/))?M["url:"+Wa(p[1],a)]=g:"*now"==f?n=g:"*noref"!=f&&(p=Sa(f,a,!0),M[p.mid]=M["url:"+p.url]=g);n&&n(ra(a));c&&(U={})};var fa=function(a){return a.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g,
function(a){return"\\"+a})},H=function(a,c){c.splice(0,c.length);for(var f in a)c.push([f,a[f],new RegExp("^"+fa(f)+"(/|$)"),f.length]);c.sort(function(a,c){return c[3]-a[3]});return c},da=function(a,f){n(a,function(a){f.push([c(a[0])?new RegExp("^"+fa(a[0])+"$"):a[0],a[1]])})},aa=function(a){var c=a.name;c||(c=a,a={name:c});a=g({main:"main"},a);a.location=a.location?a.location:c;a.packageMap&&(V[c]=a.packageMap);a.main.indexOf("./")||(a.main=a.main.substring(2));Q[c]=a},oa=[],ga=function(a,f,p){for(var h in a){"waitSeconds"==
h&&(r.waitms=1E3*(a[h]||0));"cacheBust"==h&&(W=a[h]?c(a[h])?a[h]:(new Date).getTime()+"":"");if("baseUrl"==h||"combo"==h)r[h]=a[h];a[h]!==x&&(r.rawConfig[h]=a[h],"has"!=h&&y.add("config-"+h,a[h],0,f))}r.baseUrl||(r.baseUrl="./");/\/$/.test(r.baseUrl)||(r.baseUrl+="/");for(h in a.has)y.add(h,a.has[h],0,f);n(a.packages,aa);for(var d in a.packagePaths)n(a.packagePaths[d],function(a){var f=d+"/"+a;c(a)&&(a={name:a});a.location=f;aa(a)});H(g(V,a.map),R);n(R,function(a){a[1]=H(a[1],[]);"*"==a[0]&&(R.star=
a)});H(g(E,a.paths),G);da(a.aliases,C);if(!y("foreign-loader")){if(f)oa.push({config:a.config});else for(h in a.config)f=Ia(h,p),f.config=g(f.config||{},a.config[h]);a.cache&&(J(),U=a.cache,J(0,!!a.cache["*noref"]))}F("config",[a,r.rawConfig])};if(y("dojo-cdn")){var la=u.getElementsByTagName("script");m=0;for(var Z,ja,ea,sa;m<la.length;)if(Z=la[m++],(ea=Z.getAttribute("src"))&&(sa=ea.match(/(((.*)\/)|^)dojo\.js(\W|$)/i))&&(ja=sa[3]||"",e.baseUrl=e.baseUrl||ja,O=Z),ea=Z.getAttribute("data-dojo-config")||
Z.getAttribute("djConfig"))d=r.eval("({ "+ea+" })","data-dojo-config"),O=Z}r.rawConfig={};ga(e,1);y("dojo-cdn")&&((Q.dojo.location=ja)&&(ja+="/"),Q.dijit.location=ja+"../dijit/",Q.dojox.location=ja+"../dojox/");ga(b,1);ga(d,1);if(!y("foreign-loader"))var pa=function(a){D(function(){n(a.deps,L)})},Ea=function(a,p,n,h,d){var b;if(c(a)){if((b=Ia(a,h,!0))&&b.executed)return b.result;throw q("undefinedModule",a);}f(a)||(ga(a,0,h),a=p,p=n);if(f(a))if(a.length){n="require*"+t();for(var e,l=[],v=0;v<a.length;)e=
a[v++],l.push(Ia(e,h));b=g(ya("",n,0,""),{injected:2,deps:l,def:p||k,require:h?h.require:r,gc:1});I[b.mid]=b;pa(b);var u=ia&&!0;D(function(){K(b,u)});b.executed||na.push(b);ba()}else p&&p();return d},ra=function(a){if(!a)return r;var c=a.require;c||(c=function(f,g,p){return Ea(f,g,p,a,c)},a.require=g(c,r),c.module=a,c.toUrl=function(c){return Wa(c,a)},c.toAbsMid=function(c){return Ga(c,a)});return c},na=[],ua=[],qa={},Ca=function(a){a.injected=1;qa[a.mid]=1;a.url&&(qa[a.url]=a.pack||1);wb()},wa=function(a){a.injected=
2;delete qa[a.mid];a.url&&delete qa[a.url];l(qa)&&Xa()},Ta=r.idle=function(){return!ua.length&&l(qa)&&!na.length&&!ia};var T=function(a,c){if(c)for(var f=0;f<c.length;f++)if(c[f][2].test(a))return c[f];return 0},xa=function(a){var c=[],f,g;for(a=a.replace(/\\/g,"/").split("/");a.length;)f=a.shift(),".."==f&&c.length&&".."!=g?(c.pop(),g=c[c.length-1]):"."!=f&&c.push(g=f);return c.join("/")},ya=function(a,c,f,g){return{pid:a,mid:c,pack:f,url:g,executed:0,def:0}},hb=function(c,f,g,p,h,d,b,e,t,r){var l,
v,u,k;k=/^\./.test(c);if(/(^\/)|(\:)|(\.js$)/.test(c)||k&&!f)return ya(0,c,0,c);c=xa(k?f.mid+"/../"+c:c);if(/^\./.test(c))throw q("irrationalPath",c);r||k||!d.star||(u=T(c,d.star[1]));!u&&f&&(u=(u=T(f.mid,d))&&T(c,u[1]));u&&(c=u[1]+c.substring(u[3]));f=(sa=c.match(/^([^\/]+)(\/(.+))?$/))?sa[1]:"";(l=g[f])?c=f+"/"+(v=sa[3]||l.main):f="";var x=0;n(e,function(f){var g=c.match(f[0]);g&&0<g.length&&(x=a(f[1])?c.replace(f[0],f[1]):f[1])});if(x)return hb(x,0,g,p,h,d,b,e,t);if(g=p[c])return t?ya(g.pid,g.mid,
g.pack,g.url):p[c];p=(u=T(c,b))?u[1]+c.substring(u[3]):f?("/"===l.location.slice(-1)?l.location.slice(0,-1):l.location)+"/"+v:c;/(^\/)|(\:)/.test(p)||(p=h+p);return ya(f,c,l,xa(p+".js"))},Sa=function(a,c,f){return hb(a,c,Q,I,r.baseUrl,R,G,C,void 0,f)};if(!y("foreign-loader"))var Da=function(a,c,f){return a.normalize?a.normalize(c,function(a){return Ga(a,f)}):Ga(c,f)},Ka=0,Ia=function(a,c,f){var g,p;(g=a.match(/^(.+?)\!(.*)$/))?(p=Ia(g[1],c,f),5!==p.executed||p.load||Oa(p),p.load?(g=Da(p,g[2],c),a=
p.mid+"!"+(p.dynamic?++Ka+"!":"")+g):(g=g[2],a=p.mid+"!"+ ++Ka+"!waitingForPlugin"),a={plugin:p,mid:a,req:ra(c),prid:g}):a=Sa(a,c);return I[a.mid]||!f&&(I[a.mid]=a)};var Ga=r.toAbsMid=function(a,c){return Sa(a,c).mid},Wa=r.toUrl=function(a,c){c=Sa(a+"/x",c);var f=c.url;return X(0===c.pid?a:f.substring(0,f.length-5))};if(!y("foreign-loader")){var Ja={injected:2,executed:5,def:3,result:3};ja=function(a){return I[a]=g({mid:a},Ja)};var cb=ja("require"),N=ja("exports"),Ha=ja("module"),Ya={},ca=0,Oa=function(a){var c=
a.result;a.dynamic=c.dynamic;a.normalize=c.normalize;a.load=c.load;return a},La=function(a){var c={};n(a.loadQ,function(f){var p=Da(a,f.prid,f.req.module),n=a.dynamic?f.mid.replace(/waitingForPlugin$/,p):a.mid+"!"+p,p=g(g({},f),{mid:n,prid:p,injected:0});I[n]&&I[n].injected||ka(I[n]=p);c[f.mid]=I[n];wa(f);delete I[f.mid]});a.loadQ=0;var f=function(a){for(var f=a.deps||[],g=0;g<f.length;g++)(a=c[f[g].mid])&&(f[g]=a)},p;for(p in I)f(I[p]);n(na,f)},ha=function(a){r.trace("loader-finish-exec",[a.mid]);
a.executed=5;a.defOrder=ca++;a.loadQ&&(Oa(a),La(a));for(m=0;m<na.length;)na[m]===a?na.splice(m,1):m++;/^require\*/.test(a.mid)&&delete I[a.mid]},db=[],K=function(c,f){if(4===c.executed)return r.trace("loader-circular-dependency",[db.concat(c.mid).join("-\x3e")]),!c.def||f?Ya:c.cjs&&c.cjs.exports;if(!c.executed){if(!c.def)return Ya;var g=c.mid,p=c.deps||[],n,h=[],d=0;for(c.executed=4;n=p[d++];){n=n===cb?ra(c):n===N?c.cjs.exports:n===Ha?c.cjs:K(n,f);if(n===Ya)return c.executed=0,r.trace("loader-exec-module",
["abort",g]),Ya;h.push(n)}r.trace("loader-run-factory",[c.mid]);f=c.def;h=a(f)?f.apply(null,h):f;c.result=void 0===h&&c.cjs?c.cjs.exports:h;ha(c)}return c.result},ia=0,D=function(a){try{ia++,a()}catch(ub){throw ub;}finally{ia--}Ta()&&F("idle",[])},ba=function(){ia||D(function(){for(var a,c,f=0;f<na.length;)a=ca,c=na[f],K(c),a!=ca?f=0:f++})}}var X="function"==typeof b.fixupUrl?b.fixupUrl:function(a){a+="";return a+(W?(/\?/.test(a)?"\x26":"?")+W:"")};void 0===y("dojo-loader-eval-hint-url")&&y.add("dojo-loader-eval-hint-url",
1);var ka=function(a){var c=a.plugin;5!==c.executed||c.load||Oa(c);var f=function(c){a.result=c;wa(a);ha(a);ba()};c.load?c.load(a.prid,a.req,f):c.loadQ?c.loadQ.push(a):(c.loadQ=[a],na.unshift(c),L(c))},S=0,Y=function(a,c){y("config-stripStrict")&&(a=a.replace(/(["'])use strict\1/g,""));a===S?S.call(null):r.eval(a,y("dojo-loader-eval-hint-url")?c.url:c.mid)},L=function(a){var c=a.mid,f=a.url;if(!(a.executed||a.injected||qa[c]||a.url&&(a.pack&&qa[a.url]===a.pack||1==qa[a.url])))if(Ca(a),a.plugin)ka(a);
else{var p=function(){Ma(a);if(2!==a.injected){if(y("dojo-enforceDefine")){F("error",q("noDefine",a));return}wa(a);g(a,Ja);r.trace("loader-define-nonmodule",[a.url])}ba()};(S=M[c]||M["url:"+a.url])?(r.trace("loader-inject",["cache",a.mid,f]),Y(S,a),p()):(r.trace("loader-inject",["script",a.mid,f]),r.injectUrl(X(f),p,a))}},nb=function(c,f,p){r.trace("loader-define-module",[c.mid,f]);if(2===c.injected)return F("error",q("multipleDefine",c)),c;g(c,{deps:f,def:p,cjs:{id:c.mid,uri:c.url,exports:c.result=
{},setExports:function(a){c.cjs.exports=a},config:function(){return c.config}}});for(var n=0;f[n];n++)f[n]=Ia(f[n],c);wa(c);a(p)||f.length||(c.result=p,ha(c));return c},Ma=function(a,c){for(var f=[],g,p;ua.length;)p=ua.shift(),c&&(p[0]=c.shift()),g=p[0]&&Ia(p[0])||a,f.push([g,p[1],p[2]]);J(a);n(f,function(a){pa(nb.apply(null,a))})},Xa=k,wb=k;y("dom");if(y("dom")){var Pa=function(a,c,f,g){a.addEventListener(c,g,!1);return function(){a.removeEventListener(c,g,!1)}},yb=Pa(window,"load","onload",function(){r.pageLoaded=
1;try{"complete"!=u.readyState&&(u.readyState="complete")}catch(tb){}yb()}),la=u.getElementsByTagName("script");for(m=0;!O;)/^dojo/.test((Z=la[m++])&&Z.type)||(O=Z);r.injectUrl=function(a,c,f){f=f.node=u.createElement("script");var g=Pa(f,"load","onreadystatechange",function(a){a=a||window.event;var f=a.target||a.srcElement;if("load"===a.type||/complete|loaded/.test(f.readyState))g(),p(),c&&c()}),p=Pa(f,"error","onerror",function(c){g();p();F("error",q("scriptError: "+a,[a,c]))});f.type="text/javascript";
f.charset="utf-8";f.src=a;O.parentNode.insertBefore(f,O);return f}}r.log=k;r.trace=k;y("foreign-loader")?Z=k:(Z=function(f,g,p){var n=arguments.length,h=["require","exports","module"],d=[0,f,g];1==n?d=[0,a(f)?h:[],f]:2==n&&c(f)?d=[f,a(g)?h:[],g]:3==n&&(d=[f,g,p]);r.trace("loader-define",d.slice(0,2));(n=d[0]&&Ia(d[0]))&&!qa[n.mid]?pa(nb(n,d[1],d[2])):ua.push(d)},Z.amd={vendor:"dojotoolkit.org"});g(g(r,e.loaderPatch),b.loaderPatch);w("error",function(a){try{if(console.error(a),a instanceof Error){for(var c in a)console.log(c+
":",a[c]);console.log(".")}}catch(mb){}});g(r,{uid:t,cache:M,packs:Q});v.define||(v.define=Z,v.require=r,y("foreign-loader")||(n(oa,function(a){ga(a)}),Z=d.deps||b.deps||e.deps,b=d.callback||b.callback||e.callback,r.boot=Z||b?[Z||[],b]:0))})(function(b){return b.dojoConfig||b.djConfig||b.require||{}},{aliases:[[/^webgl-engine/,function(){return"esri/views/3d/webgl-engine"}],[/^engine/,function(){return"esri/views/3d/webgl-engine"}],[/^esri-hydra/,function(){return"esri"}]],async:1,baseUrl:"https://js.arcgis.com/4.11/dojo",
hasCache:{"config-deferredInstrumentation":0,"config-selectorEngine":"lite","config-tlmSiblingOfDojo":1,"dojo-built":1,"dojo-has-api":1,"dojo-loader":1,"dojo-undef-api":0,dom:1,"esri-built":1,"host-browser":1},map:{globalize:{cldr:"cldrjs/dist/cldr","cldr/event":"cldrjs/dist/cldr/event","cldr/supplemental":"cldrjs/dist/cldr/supplemental","cldr/unresolved":"cldrjs/dist/cldr/unresolved"}},packages:[{location:".",name:"dojo"},{location:"../dijit",name:"dijit"},{location:"../dojox",name:"dojox"},{location:"../dgrid",
main:"OnDemandGrid",name:"dgrid"},{location:"../dstore",main:"Store",name:"dstore"},{location:"../esri",name:"esri"},{location:"../moment",main:"moment",name:"moment"},{location:"../@dojo",name:"@dojo"},{location:"../cldrjs",main:"dist/cldr",name:"cldrjs"},{location:"../globalize",main:"dist/globalize",name:"globalize"},{location:"../intersection-observer",main:"intersection-observer",name:"intersection-observer"},{location:"../maquette",main:"dist/maquette.umd",name:"maquette"},{location:"../maquette-css-transitions",
main:"dist/maquette-css-transitions.umd",name:"maquette-css-transitions"},{location:"../maquette-jsx",main:"dist/maquette-jsx.umd",name:"maquette-jsx"},{location:"../tslib",main:"tslib",name:"tslib"},{location:"../whatwg-fetch",main:"dist/fetch.umd",name:"whatwg-fetch"}]});
require({cache:{"dojo/domReady":function(){define(["./global","./has"],function(b,e){function m(f){c.push(f);a&&d()}function d(){if(!f){for(f=!0;c.length;)try{c.shift()(k)}catch(p){console.error(p,"in domReady callback",p.stack)}f=!1;m._onQEmpty()}}var k=document,l={loaded:1,complete:1},h="string"!=typeof k.readyState,a=!!l[k.readyState],c=[],f;m.load=function(a,c,f){m(f)};m._Q=c;m._onQEmpty=function(){};h&&(k.readyState="loading");if(!a){var n=[],g=function(c){c=c||b.event;a||"readystatechange"==
c.type&&!l[k.readyState]||(h&&(k.readyState="complete"),a=1,d())};e=function(a,f){a.addEventListener(f,g,!1);c.push(function(){a.removeEventListener(f,g,!1)})};e(k,"DOMContentLoaded");e(b,"load");"onreadystatechange"in k?e(k,"readystatechange"):h||n.push(function(){return l[k.readyState]});if(n.length){var q=function(){if(!a){for(var c=n.length;c--;)if(n[c]()){g("poller");return}setTimeout(q,30)}};q()}}return m})},"dojo/global":function(){define(function(){return"undefined"!==typeof global&&"function"!==
typeof global?global:"undefined"!==typeof window?window:"undefined"!==typeof self?self:this})},"dojo/has":function(){define(["./global","require","module"],function(b,e,m){var d=e.has||function(){};if(!d("dojo-has-api")){var k=(e="undefined"!=typeof window&&"undefined"!=typeof location&&"undefined"!=typeof document&&window.location==location&&window.document==document)&&document,l=k&&k.createElement("DiV"),h=m.config&&m.config()||{},d=function(a){return"function"==typeof h[a]?h[a]=h[a](b,k,l):h[a]};
d.cache=h;d.add=function(a,c,f,n){("undefined"==typeof h[a]||n)&&(h[a]=c);return f&&d(a)};d.add("host-browser",e);d.add("dom",e)}d("host-browser")&&(d.add("touch","ontouchstart"in document||"onpointerdown"in document&&0<navigator.maxTouchPoints||window.navigator.msMaxTouchPoints),d.add("touch-events","ontouchstart"in document),d.add("pointer-events","pointerEnabled"in window.navigator?window.navigator.pointerEnabled:"PointerEvent"in window),d.add("device-width",screen.availWidth||innerWidth),m=document.createElement("form"),
d.add("dom-attributes-specified-flag",0<m.attributes.length&&40>m.attributes.length));d.clearElement=function(a){a.innerHTML="";return a};d.normalize=function(a,c){var f=a.match(/[\?:]|[^:\?]*/g),n=0,g=function(a){var c=f[n++];if(":"==c)return 0;if("?"==f[n++]){if(!a&&d(c))return g();g(!0);return g(a)}return c||0};return(a=g())&&c(a)};d.load=function(a,c,f){a?c([a],f):f()};return d})},"dojo/_base/browser":function(){require.has&&require.has.add("config-selectorEngine","acme");define("../ready ./kernel ./connect ./unload ./window ./event ./html ./NodeList ../query ./xhr ./fx".split(" "),
function(b){return b})},"dojo/ready":function(){define(["./_base/kernel","./has","require","./has!host-browser?./domReady","./_base/lang"],function(b,e,m,d,k){var l=0,h=[],a=0;e=function(){l=1;b._postLoad=b.config.afterOnLoad=!0;c()};var c=function(){if(!a){for(a=1;l&&(!d||0==d._Q.length)&&(m.idle?m.idle():1)&&h.length;){var c=h.shift();try{c()}catch(q){if(q.info=q.message,m.signal)m.signal("error",q);else throw q;}}a=0}};m.on&&m.on("idle",c);d&&(d._onQEmpty=c);var f=b.ready=b.addOnLoad=function(a,
f,p){var g=k._toArray(arguments);"number"!=typeof a?(p=f,f=a,a=1E3):g.shift();p=p?k.hitch.apply(b,g):function(){f()};p.priority=a;for(g=0;g<h.length&&a>=h[g].priority;g++);h.splice(g,0,p);c()},n=b.config.addOnLoad;if(n)f[k.isArray(n)?"apply":"call"](b,n);d?d(e):e();return f})},"dojo/_base/kernel":function(){define(["../global","../has","./config","require","module"],function(b,e,m,d,k){var l,h={},a={},c={config:m,global:b,dijit:h,dojox:a},h={dojo:["dojo",c],dijit:["dijit",h],dojox:["dojox",a]};k=
d.map&&d.map[k.id.match(/[^\/]+/)[0]];for(l in k)h[l]?h[l][0]=k[l]:h[l]=[k[l],{}];for(l in h)k=h[l],k[1]._scopeName=k[0],m.noGlobals||(b[k[0]]=k[1]);c.scopeMap=h;c.baseUrl=c.config.baseUrl=d.baseUrl;c.isAsync=d.async;c.locale=m.locale;b="$Rev: d6e8ff38 $".match(/[0-9a-f]{7,}/);c.version={major:1,minor:14,patch:2,flag:"",revision:b?b[0]:NaN,toString:function(){var a=c.version;return a.major+"."+a.minor+"."+a.patch+a.flag+" ("+a.revision+")"}};e("csp-restrictions")||Function("d","d.eval \x3d function(){return d.global.eval ? d.global.eval(arguments[0]) : eval(arguments[0]);}")(c);
c.exit=function(){};e("host-webworker");"undefined"!=typeof console||(console={});b="assert count debug dir dirxml error group groupEnd info profile profileEnd time timeEnd trace warn log".split(" ");var f;for(e=0;f=b[e++];)console[f]?console[f]=Function.prototype.bind.call(console[f],console):function(){var a=f+"";console[a]="log"in console?function(){var c=Array.prototype.slice.call(arguments);c.unshift(a+":");console.log(c.join(" "))}:function(){};console[a]._fake=!0}();c.deprecated=c.experimental=
function(){};c._hasResource={};return c})},"dojo/_base/config":function(){define(["../global","../has","require"],function(b,e,m){b={};m=m.rawConfig;for(var d in m)b[d]=m[d];!b.locale&&"undefined"!=typeof navigator&&(d=navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.language||navigator.userLanguage)&&(b.locale=d.toLowerCase());return b})},"dojo/_base/lang":function(){define(["./kernel","../has","../sniff"],function(b,e){var m=function(a,c,f){f||(f=a[0]&&b.scopeMap[a[0]]?
b.scopeMap[a.shift()][1]:b.global);try{for(var n=0;n<a.length;n++){var g=a[n];if(!(g in f))if(c)f[g]={};else return;f=f[g]}return f}catch(q){}},d=Object.prototype.toString,k=function(a,c,f){return(f||[]).concat(Array.prototype.slice.call(a,c||0))},l=/\{([^\}]+)\}/g,h={_extraNames:[],_mixin:function(a,c,f){var n,g,h={};for(n in c)g=c[n],n in a&&(a[n]===g||n in h&&h[n]===g)||(a[n]=f?f(g):g);return a},mixin:function(a,c){a||(a={});for(var f=1,n=arguments.length;f<n;f++)h._mixin(a,arguments[f]);return a},
setObject:function(a,c,f){var n=a.split(".");a=n.pop();return(f=m(n,!0,f))&&a?f[a]=c:void 0},getObject:function(a,c,f){return a?m(a.split("."),c,f):f},exists:function(a,c){return void 0!==h.getObject(a,!1,c)},isString:function(a){return"string"==typeof a||a instanceof String},isArray:Array.isArray||function(a){return"[object Array]"==d.call(a)},isFunction:function(a){return"[object Function]"===d.call(a)},isObject:function(a){return void 0!==a&&(null===a||"object"==typeof a||h.isArray(a)||h.isFunction(a))},
isArrayLike:function(a){return!!a&&!h.isString(a)&&!h.isFunction(a)&&!(a.tagName&&"form"==a.tagName.toLowerCase())&&(h.isArray(a)||isFinite(a.length))},isAlien:function(a){return a&&!h.isFunction(a)&&/\{\s*\[native code\]\s*\}/.test(String(a))},extend:function(a,c){for(var f=1,n=arguments.length;f<n;f++)h._mixin(a.prototype,arguments[f]);return a},_hitchArgs:function(a,c){var f=h._toArray(arguments,2),n=h.isString(c);return function(){var g=h._toArray(arguments),d=n?(a||b.global)[c]:c;return d&&d.apply(a||
this,f.concat(g))}},hitch:function(a,c){if(2<arguments.length)return h._hitchArgs.apply(b,arguments);c||(c=a,a=null);if(h.isString(c)){a=a||b.global;if(!a[c])throw['lang.hitch: scope["',c,'"] is null (scope\x3d"',a,'")'].join("");return function(){return a[c].apply(a,arguments||[])}}return a?function(){return c.apply(a,arguments||[])}:c},delegate:function(){function a(){}return function(c,f){a.prototype=c;c=new a;a.prototype=null;f&&h._mixin(c,f);return c}}(),_toArray:e("ie")?function(){function a(a,
f,n){n=n||[];for(f=f||0;f<a.length;f++)n.push(a[f]);return n}return function(c){return(c.item?a:k).apply(this,arguments)}}():k,partial:function(a){return h.hitch.apply(b,[null].concat(h._toArray(arguments)))},clone:function(a){if(!a||"object"!=typeof a||h.isFunction(a))return a;if(a.nodeType&&"cloneNode"in a)return a.cloneNode(!0);if(a instanceof Date)return new Date(a.getTime());if(a instanceof RegExp)return new RegExp(a);var c,f,n;if(h.isArray(a))for(c=[],f=0,n=a.length;f<n;++f)f in a&&(c[f]=h.clone(a[f]));
else c=a.constructor?new a.constructor:{};return h._mixin(c,a,h.clone)},trim:String.prototype.trim?function(a){return a.trim()}:function(a){return a.replace(/^\s\s*/,"").replace(/\s\s*$/,"")},replace:function(a,c,f){return a.replace(f||l,h.isFunction(c)?c:function(a,f){return h.getObject(f,!1,c)})}};h.mixin(b,h);return h})},"dojo/sniff":function(){define(["./has"],function(b){if(b("host-browser")){var e=navigator,m=e.userAgent,e=e.appVersion,d=parseFloat(e);b.add("edge",parseFloat(m.split("Edge/")[1])||
void 0);b.add("webkit",!b("edge")&&parseFloat(m.split("WebKit/")[1])||void 0);b.add("chrome",!b("edge")&&!0&&parseFloat(m.split("Chrome/")[1])||void 0);b.add("safari",0<=e.indexOf("Safari")&&!b("chrome")&&!b("edge")?parseFloat(e.split("Version/")[1]):void 0);b.add("mac",0<=e.indexOf("Macintosh"));if(m.match(/(iPhone|iPod|iPad)/)){var k=RegExp.$1.replace(/P/,"p"),l=m.match(/OS ([\d_]+)/)?RegExp.$1:"1",l=parseFloat(l.replace(/_/,".").replace(/_/g,""));b.add(k,l);b.add("ios",l)}b.add("trident",parseFloat(e.split("Trident/")[1])||
void 0);b("webkit")||(0<=m.indexOf("Opera")&&b.add("opera",9.8<=d?parseFloat(m.split("Version/")[1])||d:d),0<=m.indexOf("Gecko")&&!b("trident")&&!b("edge")&&b.add("mozilla",d),b("mozilla")&&b.add("ff",parseFloat(m.split("Firefox/")[1]||m.split("Minefield/")[1])||void 0),document.all&&!b("opera")&&(m=parseFloat(e.split("MSIE ")[1])||void 0,(e=document.documentMode)&&5!=e&&Math.floor(m)!=e&&(m=e),b.add("ie",m)))}return b})},"dojo/_base/connect":function(){define("./kernel ../on ../topic ../aspect ./event ../mouse ./sniff ./lang ../keys".split(" "),
function(b,e,m,d,k,l,h,a){function c(c,f,g,n,h){n=a.hitch(g,n);if(!c||!c.addEventListener&&!c.attachEvent)return d.after(c||b.global,f,n,!0);"string"==typeof f&&"on"==f.substring(0,2)&&(f=f.substring(2));c||(c=b.global);if(!h)switch(f){case "keypress":f=p;break;case "mouseenter":f=l.enter;break;case "mouseleave":f=l.leave}return e(c,f,n,h)}function f(a){a.keyChar=a.charCode?String.fromCharCode(a.charCode):"";a.charOrCode=a.keyChar||a.keyCode}h.add("events-keypress-typed",function(){var a={charCode:0};
try{a=document.createEvent("KeyboardEvent"),(a.initKeyboardEvent||a.initKeyEvent).call(a,"keypress",!0,!0,null,!1,!1,!1,!1,9,3)}catch(v){}return 0==a.charCode&&!h("opera")});var n={106:42,111:47,186:59,187:43,188:44,189:45,190:46,191:47,192:96,219:91,220:92,221:93,222:39,229:113},g=h("mac")?"metaKey":"ctrlKey",q=function(c,g){g=a.mixin({},c,g);f(g);g.preventDefault=function(){c.preventDefault()};g.stopPropagation=function(){c.stopPropagation()};return g},p;p=h("events-keypress-typed")?function(a,
c){var f=e(a,"keydown",function(a){var f=a.keyCode,g=13!=f&&32!=f&&(27!=f||!h("ie"))&&(48>f||90<f)&&(96>f||111<f)&&(186>f||192<f)&&(219>f||222<f)&&229!=f;if(g||a.ctrlKey){g=g?0:f;if(a.ctrlKey){if(3==f||13==f)return c.call(a.currentTarget,a);g=95<g&&106>g?g-48:!a.shiftKey&&65<=g&&90>=g?g+32:n[g]||g}f=q(a,{type:"keypress",faux:!0,charCode:g});c.call(a.currentTarget,f);if(h("ie"))try{a.keyCode=f.keyCode}catch(A){}}}),g=e(a,"keypress",function(a){var f=a.charCode;a=q(a,{charCode:32<=f?f:0,faux:!0});return c.call(this,
a)});return{remove:function(){f.remove();g.remove()}}}:h("opera")?function(a,c){return e(a,"keypress",function(a){var f=a.which;3==f&&(f=99);f=32>f&&!a.shiftKey?0:f;a.ctrlKey&&!a.shiftKey&&65<=f&&90>=f&&(f+=32);return c.call(this,q(a,{charCode:f}))})}:function(a,c){return e(a,"keypress",function(a){f(a);return c.call(this,a)})};var t={_keypress:p,connect:function(a,f,g,p,n){var h=arguments,d=[],b=0;d.push("string"==typeof h[0]?null:h[b++],h[b++]);var e=h[b+1];d.push("string"==typeof e||"function"==
typeof e?h[b++]:null,h[b++]);for(e=h.length;b<e;b++)d.push(h[b]);return c.apply(this,d)},disconnect:function(a){a&&a.remove()},subscribe:function(c,f,g){return m.subscribe(c,a.hitch(f,g))},publish:function(a,c){return m.publish.apply(m,[a].concat(c))},connectPublisher:function(a,c,f){var g=function(){t.publish(a,arguments)};return f?t.connect(c,f,g):t.connect(c,g)},isCopyKey:function(a){return a[g]}};t.unsubscribe=t.disconnect;a.mixin(b,t);return t})},"dojo/on":function(){define(["require","./_base/kernel",
"./sniff"],function(b,e,m){function d(c,f,g,d,b){if(d=f.match(/(.*):(.*)/))return f=d[2],d=d[1],h.selector(d,f).call(b,c,g);m("touch")&&a.test(f)&&(g=q(g));if(c.addEventListener){var p=f in n,e=p?n[f]:f;c.addEventListener(e,g,p);return{remove:function(){c.removeEventListener(e,g,p)}}}throw Error("Target must be an event emitter");}function k(){this.cancelable=!1;this.defaultPrevented=!0}function l(){this.bubbles=!1}m("dom")&&m("touch");var h=function(a,c,f,g){return"function"!=typeof a.on||"function"==
typeof c||a.nodeType?h.parse(a,c,f,d,g,this):a.on(c,f)};h.pausable=function(a,c,f,g){var p;a=h(a,c,function(){if(!p)return f.apply(this,arguments)},g);a.pause=function(){p=!0};a.resume=function(){p=!1};return a};h.once=function(a,c,f,g){var p=h(a,c,function(){p.remove();return f.apply(this,arguments)});return p};h.parse=function(a,c,f,g,n,d){var p;if(c.call)return c.call(d,a,f);c instanceof Array?p=c:-1<c.indexOf(",")&&(p=c.split(/\s*,\s*/));if(p){var b=[];c=0;for(var e;e=p[c++];)b.push(h.parse(a,
e,f,g,n,d));b.remove=function(){for(var a=0;a<b.length;a++)b[a].remove()};return b}return g(a,c,f,n,d)};var a=/^touch/;h.matches=function(a,c,f,g,n){n=n&&"function"==typeof n.matches?n:e.query;g=!1!==g;1!=a.nodeType&&(a=a.parentNode);for(;!n.matches(a,c,f);)if(a==f||!1===g||!(a=a.parentNode)||1!=a.nodeType)return!1;return a};h.selector=function(a,c,f){return function(g,p){function n(c){return h.matches(c,a,g,f,d)}var d="function"==typeof a?{matches:a}:this,b=c.bubble;return b?h(g,b(n),p):h(g,c,function(a){var c=
n(a.target);if(c)return a.selectorTarget=c,p.call(c,a)})}};var c=[].slice,f=h.emit=function(a,f,g){var p=c.call(arguments,2),n="on"+f;if("parentNode"in a){var h=p[0]={},d;for(d in g)h[d]=g[d];h.preventDefault=k;h.stopPropagation=l;h.target=a;h.type=f;g=h}do a[n]&&a[n].apply(a,p);while(g&&g.bubbles&&(a=a.parentNode));return g&&g.cancelable&&g},n={};h.emit=function(a,c,g){if(a.dispatchEvent&&document.createEvent){var p=(a.ownerDocument||document).createEvent("HTMLEvents");p.initEvent(c,!!g.bubbles,
!!g.cancelable);for(var n in g)n in p||(p[n]=g[n]);return a.dispatchEvent(p)&&p}return f.apply(h,arguments)};if(m("touch"))var g=window.orientation,q=function(a){return function(c){var f=c.corrected;if(!f){var p=c.type;try{delete c.type}catch(y){}if(c.type){var f={},n;for(n in c)f[n]=c[n];f.preventDefault=function(){c.preventDefault()};f.stopPropagation=function(){c.stopPropagation()}}else f=c,f.type=p;c.corrected=f;if("resize"==p){if(g==window.orientation)return null;g=window.orientation;f.type=
"orientationchange";return a.call(this,f)}"rotation"in f||(f.rotation=0,f.scale=1);if(window.TouchEvent&&c instanceof TouchEvent){var p=f.changedTouches[0],h;for(h in p)delete f[h],f[h]=p[h]}}return a.call(this,f)}};return h})},"dojo/topic":function(){define(["./Evented"],function(b){var e=new b;return{publish:function(b,d){return e.emit.apply(e,arguments)},subscribe:function(b,d){return e.on.apply(e,arguments)}}})},"dojo/Evented":function(){define(["./aspect","./on"],function(b,e){function m(){}
var d=b.after;m.prototype={on:function(b,l){return e.parse(this,b,l,function(h,a){return d(h,"on"+a,l,!0)})},emit:function(d,b){var h=[this];h.push.apply(h,arguments);return e.emit.apply(e,h)}};return m})},"dojo/aspect":function(){define([],function(){function b(h,a,c,f){var n=h[a],g="around"==a,d;if(g){var p=c(function(){return n.advice(this,arguments)});d={remove:function(){p&&(p=h=c=null)},advice:function(a,c){return p?p.apply(a,c):n.advice(a,c)}}}else d={remove:function(){if(d.advice){var f=d.previous,
g=d.next;g||f?(f?f.next=g:h[a]=g,g&&(g.previous=f)):delete h[a];h=c=d.advice=null}},id:h.nextId++,advice:c,receiveArguments:f};if(n&&!g)if("after"==a){for(;n.next&&(n=n.next););n.next=d;d.previous=n}else"before"==a&&(h[a]=d,d.next=n,n.previous=d);else h[a]=d;return d}function e(h){return function(a,c,f,n){var g=a[c],d;g&&g.target==a||(a[c]=d=function(){for(var a=d.nextId,c=arguments,f=d.before;f;)f.advice&&(c=f.advice.apply(this,c)||c),f=f.next;if(d.around)var g=d.around.advice(this,c);for(f=d.after;f&&
f.id<a;){if(f.advice)if(f.receiveArguments)var n=f.advice.apply(this,c),g=n===m?g:n;else g=f.advice.call(this,g,c);f=f.next}return g},g&&(d.around={advice:function(a,c){return g.apply(a,c)}}),d.target=a,d.nextId=d.nextId||0);a=b(d||g,h,f,n);f=null;return a}}var m,d=e("after"),k=e("before"),l=e("around");return{before:k,around:l,after:d}})},"dojo/_base/event":function(){define(["./kernel","../on","../has","../dom-geometry"],function(b,e,m,d){if(e._fixEvent){var k=e._fixEvent;e._fixEvent=function(b,
h){(b=k(b,h))&&d.normalizeEvent(b);return b}}m={fix:function(d,h){return e._fixEvent?e._fixEvent(d,h):d},stop:function(d){d.preventDefault();d.stopPropagation()}};b.fixEvent=m.fix;b.stopEvent=m.stop;return m})},"dojo/dom-geometry":function(){define(["./sniff","./_base/window","./dom","./dom-style"],function(b,e,m,d){function k(a,c,g,h,p,d){d=d||"px";a=a.style;isNaN(c)||(a.left=c+d);isNaN(g)||(a.top=g+d);0<=h&&(a.width=h+d);0<=p&&(a.height=p+d)}function l(a){return"button"==a.tagName.toLowerCase()||
"input"==a.tagName.toLowerCase()&&"button"==(a.getAttribute("type")||"").toLowerCase()}function h(c){return"border-box"==a.boxModel||"table"==c.tagName.toLowerCase()||l(c)}var a={boxModel:"content-box"};b("ie")&&(a.boxModel="BackCompat"==document.compatMode?"border-box":"content-box");a.getPadExtents=function(a,c){a=m.byId(a);var f=c||d.getComputedStyle(a),n=d.toPixelValue;c=n(a,f.paddingLeft);var p=n(a,f.paddingTop),h=n(a,f.paddingRight);a=n(a,f.paddingBottom);return{l:c,t:p,r:h,b:a,w:c+h,h:p+a}};
a.getBorderExtents=function(a,c){a=m.byId(a);var f=d.toPixelValue,n=c||d.getComputedStyle(a);c="none"!=n.borderLeftStyle?f(a,n.borderLeftWidth):0;var p="none"!=n.borderTopStyle?f(a,n.borderTopWidth):0,h="none"!=n.borderRightStyle?f(a,n.borderRightWidth):0;a="none"!=n.borderBottomStyle?f(a,n.borderBottomWidth):0;return{l:c,t:p,r:h,b:a,w:c+h,h:p+a}};a.getPadBorderExtents=function(c,n){c=m.byId(c);var f=n||d.getComputedStyle(c);n=a.getPadExtents(c,f);c=a.getBorderExtents(c,f);return{l:n.l+c.l,t:n.t+
c.t,r:n.r+c.r,b:n.b+c.b,w:n.w+c.w,h:n.h+c.h}};a.getMarginExtents=function(a,c){a=m.byId(a);var f=c||d.getComputedStyle(a),n=d.toPixelValue;c=n(a,f.marginLeft);var p=n(a,f.marginTop),h=n(a,f.marginRight);a=n(a,f.marginBottom);return{l:c,t:p,r:h,b:a,w:c+h,h:p+a}};a.getMarginBox=function(c,n){c=m.byId(c);n=n||d.getComputedStyle(c);n=a.getMarginExtents(c,n);var f=c.offsetLeft-n.l,h=c.offsetTop-n.t,p=c.parentNode,e=d.toPixelValue;8==b("ie")&&p&&(p=d.getComputedStyle(p),f-="none"!=p.borderLeftStyle?e(c,
p.borderLeftWidth):0,h-="none"!=p.borderTopStyle?e(c,p.borderTopWidth):0);return{l:f,t:h,w:c.offsetWidth+n.w,h:c.offsetHeight+n.h}};a.getContentBox=function(c,n){c=m.byId(c);var f=n||d.getComputedStyle(c);n=c.clientWidth;var h,p=a.getPadExtents(c,f);h=a.getBorderExtents(c,f);var f=c.offsetLeft+p.l+h.l,e=c.offsetTop+p.t+h.t;n?h=c.clientHeight:(n=c.offsetWidth-h.w,h=c.offsetHeight-h.h);if(8==b("ie")){var r=c.parentNode,l=d.toPixelValue;r&&(r=d.getComputedStyle(r),f-="none"!=r.borderLeftStyle?l(c,r.borderLeftWidth):
0,e-="none"!=r.borderTopStyle?l(c,r.borderTopWidth):0)}return{l:f,t:e,w:n-p.w,h:h-p.h}};a.setContentSize=function(c,n,g){c=m.byId(c);var f=n.w;n=n.h;h(c)&&(g=a.getPadBorderExtents(c,g),0<=f&&(f+=g.w),0<=n&&(n+=g.h));k(c,NaN,NaN,f,n)};var c={l:0,t:0,w:0,h:0};a.setMarginBox=function(f,n,g){f=m.byId(f);var e=g||d.getComputedStyle(f);g=n.w;var p=n.h,t=h(f)?c:a.getPadBorderExtents(f,e),e=a.getMarginExtents(f,e);if(b("webkit")&&l(f)){var r=f.style;0<=g&&!r.width&&(r.width="4px");0<=p&&!r.height&&(r.height=
"4px")}0<=g&&(g=Math.max(g-t.w-e.w,0));0<=p&&(p=Math.max(p-t.h-e.h,0));k(f,n.l,n.t,g,p)};a.isBodyLtr=function(a){a=a||e.doc;return"ltr"==(e.body(a).dir||a.documentElement.dir||"ltr").toLowerCase()};a.docScroll=function(c){c=c||e.doc;var f=e.doc.parentWindow||e.doc.defaultView;return"pageXOffset"in f?{x:f.pageXOffset,y:f.pageYOffset}:(f=c.documentElement)&&{x:a.fixIeBiDiScrollLeft(f.scrollLeft||0,c),y:f.scrollTop||0}};a.getIeDocumentElementOffset=function(a){return{x:0,y:0}};a.fixIeBiDiScrollLeft=
function(c,n){n=n||e.doc;var f=b("ie");if(f&&!a.isBodyLtr(n)){n=n.documentElement;var h=e.global;6==f&&h.frameElement&&n.scrollHeight>n.clientHeight&&(c+=n.clientLeft);return 8>f?c+n.clientWidth-n.scrollWidth:-c}return c};a.position=function(c,n){c=m.byId(c);e.body(c.ownerDocument);var f=c.getBoundingClientRect(),f={x:f.left,y:f.top,w:f.right-f.left,h:f.bottom-f.top};9>b("ie")&&(f.x-=0,f.y-=0);n&&(c=a.docScroll(c.ownerDocument),f.x+=c.x,f.y+=c.y);return f};a.getMarginSize=function(c,n){c=m.byId(c);
n=a.getMarginExtents(c,n||d.getComputedStyle(c));c=c.getBoundingClientRect();return{w:c.right-c.left+n.w,h:c.bottom-c.top+n.h}};a.normalizeEvent=function(c){"layerX"in c||(c.layerX=c.offsetX,c.layerY=c.offsetY);if(!("pageX"in c)){var f=c.target,f=f&&f.ownerDocument||document,g=f.documentElement;c.pageX=c.clientX+a.fixIeBiDiScrollLeft(g.scrollLeft||0,f);c.pageY=c.clientY+(g.scrollTop||0)}};return a})},"dojo/_base/window":function(){define(["./kernel","./lang","../sniff"],function(b,e,m){var d={global:b.global,
doc:b.global.document||null,body:function(d){d=d||b.doc;return d.body||d.getElementsByTagName("body")[0]},setContext:function(e,l){b.global=d.global=e;b.doc=d.doc=l},withGlobal:function(e,l,h,a){var c=b.global;try{return b.global=d.global=e,d.withDoc.call(null,e.document,l,h,a)}finally{b.global=d.global=c}},withDoc:function(e,l,h,a){var c=d.doc,f=m("ie"),n,g,q;try{return b.doc=d.doc=e,b.isQuirks=0,m("ie")&&(q=e.parentWindow)&&q.navigator&&(n=parseFloat(q.navigator.appVersion.split("MSIE ")[1])||void 0,
(g=e.documentMode)&&5!=g&&Math.floor(n)!=g&&(n=g),b.isIE=m.add("ie",n,!0,!0)),h&&"string"==typeof l&&(l=h[l]),l.apply(h,a||[])}finally{b.doc=d.doc=c,b.isQuirks=0,b.isIE=m.add("ie",f,!0,!0)}}};e.mixin(b,d);return d})},"dojo/dom":function(){define(["./sniff","./_base/window","./_base/kernel"],function(b,e,m){if(7>=b("ie"))try{document.execCommand("BackgroundImageCache",!1,!0)}catch(l){}var d={};b("ie")?d.byId=function(d,h){if("string"!=typeof d)return d;var a=h||e.doc;h=d&&a.getElementById(d);if(!h||
h.attributes.id.value!=d&&h.id!=d){a=a.all[d];if(!a||a.nodeName)a=[a];for(var c=0;h=a[c++];)if(h.attributes&&h.attributes.id&&h.attributes.id.value==d||h.id==d)return h}else return h}:d.byId=function(d,h){return("string"==typeof d?(h||e.doc).getElementById(d):d)||null};m=m.global.document||null;b.add("dom-contains",!(!m||!m.contains));d.isDescendant=b("dom-contains")?function(b,h){return!(!(h=d.byId(h))||!h.contains(d.byId(b)))}:function(b,h){try{for(b=d.byId(b),h=d.byId(h);b;){if(b==h)return!0;b=
b.parentNode}}catch(a){}return!1};b.add("css-user-select",function(d,h,a){if(!a)return!1;d=a.style;h=["Khtml","O","Moz","Webkit"];a=h.length;var c="userSelect";do if("undefined"!==typeof d[c])return c;while(a--&&(c=h[a]+"UserSelect"));return!1});var k=b("css-user-select");d.setSelectable=k?function(b,h){d.byId(b).style[k]=h?"":"none"}:function(b,h){b=d.byId(b);var a=b.getElementsByTagName("*"),c=a.length;if(h)for(b.removeAttribute("unselectable");c--;)a[c].removeAttribute("unselectable");else for(b.setAttribute("unselectable",
"on");c--;)a[c].setAttribute("unselectable","on")};return d})},"dojo/dom-style":function(){define(["./sniff","./dom","./_base/window"],function(b,e,m){function d(a,c,f){c=c.toLowerCase();if("auto"==f){if("height"==c)return a.offsetHeight;if("width"==c)return a.offsetWidth}if("fontweight"==c)switch(f){case 700:return"bold";default:return"normal"}c in n||(n[c]=g.test(c));return n[c]?h(a,f):f}var k,l={};k=b("webkit")?function(a){var c;if(1==a.nodeType){var f=a.ownerDocument.defaultView;c=f.getComputedStyle(a,
null);!c&&a.style&&(a.style.display="",c=f.getComputedStyle(a,null))}return c||{}}:b("ie")&&9>b("ie")?function(a){return 1==a.nodeType&&a.currentStyle?a.currentStyle:{}}:function(a){if(1===a.nodeType){var c=a.ownerDocument.defaultView;return(c.opener?c:m.global.window).getComputedStyle(a,null)}return{}};l.getComputedStyle=k;var h;h=b("ie")?function(a,c){if(!c)return 0;if("medium"==c)return 4;if(c.slice&&"px"==c.slice(-2))return parseFloat(c);var f=a.style,g=a.runtimeStyle,n=f.left,p=g.left;g.left=
a.currentStyle.left;try{f.left=c,c=f.pixelLeft}catch(y){c=0}f.left=n;g.left=p;return c}:function(a,c){return parseFloat(c)||0};l.toPixelValue=h;var a=function(a,c){try{return a.filters.item("DXImageTransform.Microsoft.Alpha")}catch(r){return c?{}:null}},c=9>b("ie")||(b("ie"),0)?function(c){try{return a(c).Opacity/100}catch(t){return 1}}:function(a){return k(a).opacity},f=9>b("ie")||(b("ie"),0)?function(c,g){""===g&&(g=1);var n=100*g;1===g?(c.style.zoom="",a(c)&&(c.style.filter=c.style.filter.replace(/\s*progid:DXImageTransform.Microsoft.Alpha\([^\)]+?\)/i,
""))):(c.style.zoom=1,a(c)?a(c,1).Opacity=n:c.style.filter+=" progid:DXImageTransform.Microsoft.Alpha(Opacity\x3d"+n+")",a(c,1).Enabled=!0);if("tr"==c.tagName.toLowerCase())for(c=c.firstChild;c;c=c.nextSibling)"td"==c.tagName.toLowerCase()&&f(c,g);return g}:function(a,c){return a.style.opacity=c},n={left:!0,top:!0},g=/margin|padding|width|height|max|min|offset/,q={cssFloat:1,styleFloat:1,"float":1};l.get=function(a,f){var g=e.byId(a),n=arguments.length;if(2==n&&"opacity"==f)return c(g);f=q[f]?"cssFloat"in
g.style?"cssFloat":"styleFloat":f;var p=l.getComputedStyle(g);return 1==n?p:d(g,f,p[f]||g.style[f])};l.set=function(a,c,g){var n=e.byId(a),p=arguments.length,d="opacity"==c;c=q[c]?"cssFloat"in n.style?"cssFloat":"styleFloat":c;if(3==p)return d?f(n,g):n.style[c]=g;for(var h in c)l.set(a,h,c[h]);return l.getComputedStyle(n)};return l})},"dojo/mouse":function(){define(["./_base/kernel","./on","./has","./dom","./_base/window"],function(b,e,m,d,k){function l(h,a){var c=function(c,n){return e(c,h,function(f){if(a)return a(f,
n);if(!d.isDescendant(f.relatedTarget,c))return n.call(this,f)})};c.bubble=function(a){return l(h,function(c,f){var g=a(c.target),n=c.relatedTarget;if(g&&g!=(n&&1==n.nodeType&&a(n)))return f.call(g,c)})};return c}m={LEFT:0,MIDDLE:1,RIGHT:2,isButton:function(d,a){return d.button==a},isLeft:function(d){return 0==d.button},isMiddle:function(d){return 1==d.button},isRight:function(d){return 2==d.button}};b.mouseButtons=m;return{_eventHandler:l,enter:l("mouseover"),leave:l("mouseout"),wheel:"mousewheel",
isLeft:m.isLeft,isMiddle:m.isMiddle,isRight:m.isRight}})},"dojo/_base/sniff":function(){define(["./kernel","./lang","../sniff"],function(b,e,m){if(!m("host-browser"))return m;b._name="browser";e.mixin(b,{isBrowser:!0,isFF:m("ff"),isIE:m("ie"),isKhtml:0,isWebKit:m("webkit"),isMozilla:m("mozilla"),isMoz:m("mozilla"),isOpera:m("opera"),isSafari:m("safari"),isChrome:m("chrome"),isMac:m("mac"),isIos:m("ios"),isAndroid:0,isWii:0,isQuirks:0,isAir:0});return m})},"dojo/keys":function(){define(["./_base/kernel",
"./sniff"],function(b,e){return b.keys={BACKSPACE:8,TAB:9,CLEAR:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,META:e("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:e("mac")?e("safari")?91:224:17}})},"dojo/_base/unload":function(){define(["./kernel","./lang","../on"],function(b,e,m){var d=window,k={addOnWindowUnload:function(l,h){b.windowUnloaded||m(d,"unload",b.windowUnloaded=function(){});m(d,"unload",e.hitch(l,
h))},addOnUnload:function(b,h){m(d,"beforeunload",e.hitch(b,h))}};b.addOnWindowUnload=k.addOnWindowUnload;b.addOnUnload=k.addOnUnload;return k})},"dojo/_base/html":function(){define("./kernel ../dom ../dom-style ../dom-attr ../dom-prop ../dom-class ../dom-construct ../dom-geometry".split(" "),function(b,e,m,d,k,l,h,a){b.byId=e.byId;b.isDescendant=e.isDescendant;b.setSelectable=e.setSelectable;b.getAttr=d.get;b.setAttr=d.set;b.hasAttr=d.has;b.removeAttr=d.remove;b.getNodeProp=d.getNodeProp;b.attr=
function(a,f,n){return 2==arguments.length?d["string"==typeof f?"get":"set"](a,f):d.set(a,f,n)};b.hasClass=l.contains;b.addClass=l.add;b.removeClass=l.remove;b.toggleClass=l.toggle;b.replaceClass=l.replace;b._toDom=b.toDom=h.toDom;b.place=h.place;b.create=h.create;b.empty=function(a){h.empty(a)};b._destroyElement=b.destroy=function(a){h.destroy(a)};b._getPadExtents=b.getPadExtents=a.getPadExtents;b._getBorderExtents=b.getBorderExtents=a.getBorderExtents;b._getPadBorderExtents=b.getPadBorderExtents=
a.getPadBorderExtents;b._getMarginExtents=b.getMarginExtents=a.getMarginExtents;b._getMarginSize=b.getMarginSize=a.getMarginSize;b._getMarginBox=b.getMarginBox=a.getMarginBox;b.setMarginBox=a.setMarginBox;b._getContentBox=b.getContentBox=a.getContentBox;b.setContentSize=a.setContentSize;b._isBodyLtr=b.isBodyLtr=a.isBodyLtr;b._docScroll=b.docScroll=a.docScroll;b._getIeDocumentElementOffset=b.getIeDocumentElementOffset=a.getIeDocumentElementOffset;b._fixIeBiDiScrollLeft=b.fixIeBiDiScrollLeft=a.fixIeBiDiScrollLeft;
b.position=a.position;b.marginBox=function(c,f){return f?a.setMarginBox(c,f):a.getMarginBox(c)};b.contentBox=function(c,f){return f?a.setContentSize(c,f):a.getContentBox(c)};b.coords=function(c,f){b.deprecated("dojo.coords()","Use dojo.position() or dojo.marginBox().");c=e.byId(c);var n=m.getComputedStyle(c),n=a.getMarginBox(c,n);c=a.position(c,f);n.x=c.x;n.y=c.y;return n};b.getProp=k.get;b.setProp=k.set;b.prop=function(a,f,n){return 2==arguments.length?k["string"==typeof f?"get":"set"](a,f):k.set(a,
f,n)};b.getStyle=m.get;b.setStyle=m.set;b.getComputedStyle=m.getComputedStyle;b.__toPixelValue=b.toPixelValue=m.toPixelValue;b.style=function(a,f,n){switch(arguments.length){case 1:return m.get(a);case 2:return m["string"==typeof f?"get":"set"](a,f)}return m.set(a,f,n)};return b})},"dojo/dom-attr":function(){define("exports ./sniff ./_base/lang ./dom ./dom-style ./dom-prop".split(" "),function(b,e,m,d,k,l){function h(a,c){a=a.getAttributeNode&&a.getAttributeNode(c);return!!a&&a.specified}var a={innerHTML:1,
textContent:1,className:1,htmlFor:e("ie"),value:1},c={classname:"class",htmlfor:"for",tabindex:"tabIndex",readonly:"readOnly"};b.has=function(f,n){var g=n.toLowerCase();return a[l.names[g]||n]||h(d.byId(f),c[g]||n)};b.get=function(f,n){f=d.byId(f);var g=n.toLowerCase(),b=l.names[g]||n,p=f[b];if(a[b]&&"undefined"!=typeof p)return p;if("textContent"==b)return l.get(f,b);if("href"!=b&&("boolean"==typeof p||m.isFunction(p)))return p;n=c[g]||n;return h(f,n)?f.getAttribute(n):null};b.set=function(f,n,g){f=
d.byId(f);if(2==arguments.length){for(var h in n)b.set(f,h,n[h]);return f}h=n.toLowerCase();var p=l.names[h]||n,e=a[p];if("style"==p&&"string"!=typeof g)return k.set(f,g),f;if(e||"boolean"==typeof g||m.isFunction(g))return l.set(f,n,g);f.setAttribute(c[h]||n,g);return f};b.remove=function(a,n){d.byId(a).removeAttribute(c[n.toLowerCase()]||n)};b.getNodeProp=function(a,n){a=d.byId(a);var f=n.toLowerCase(),b=l.names[f]||n;if(b in a&&"href"!=b)return a[b];n=c[f]||n;return h(a,n)?a.getAttribute(n):null}})},
"dojo/dom-prop":function(){define("exports ./_base/kernel ./sniff ./_base/lang ./dom ./dom-style ./dom-construct ./_base/connect".split(" "),function(b,e,m,d,k,l,h,a){var c={},f=1,n=e._scopeName+"attrid";b.names={"class":"className","for":"htmlFor",tabindex:"tabIndex",readonly:"readOnly",colspan:"colSpan",frameborder:"frameBorder",rowspan:"rowSpan",textcontent:"textContent",valuetype:"valueType"};b.get=function(a,c){a=k.byId(a);var f=c.toLowerCase();return a[b.names[f]||c]};b.set=function(g,e,p){g=
k.byId(g);if(2==arguments.length&&"string"!=typeof e){for(var q in e)b.set(g,q,e[q]);return g}q=e.toLowerCase();q=b.names[q]||e;if("style"==q&&"string"!=typeof p)return l.set(g,p),g;if("innerHTML"==q)return m("ie")&&g.tagName.toLowerCase()in{col:1,colgroup:1,table:1,tbody:1,tfoot:1,thead:1,tr:1,title:1}?(h.empty(g),g.appendChild(h.toDom(p,g.ownerDocument))):g[q]=p,g;if(d.isFunction(p)){var r=g[n];r||(r=f++,g[n]=r);c[r]||(c[r]={});var v=c[r][q];if(v)a.disconnect(v);else try{delete g[q]}catch(u){}p?
c[r][q]=a.connect(g,q,p):g[q]=null;return g}g[q]=p;return g}})},"dojo/dom-construct":function(){define("exports ./_base/kernel ./sniff ./_base/window ./dom ./dom-attr".split(" "),function(b,e,m,d,k,l){function h(a,c){var f=c.parentNode;f&&f.insertBefore(a,c)}function a(a){if("innerHTML"in a)try{a.innerHTML="";return}catch(y){}for(var c;c=a.lastChild;)a.removeChild(c)}var c={option:["select"],tbody:["table"],thead:["table"],tfoot:["table"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table",
"thead","tr"],legend:["fieldset"],caption:["table"],colgroup:["table"],col:["table","colgroup"],li:["ul"]},f=/<\s*([\w\:]+)/,n={},g=0,q="__"+e._scopeName+"ToDomId",p;for(p in c)c.hasOwnProperty(p)&&(e=c[p],e.pre="option"==p?'\x3cselect multiple\x3d"multiple"\x3e':"\x3c"+e.join("\x3e\x3c")+"\x3e",e.post="\x3c/"+e.reverse().join("\x3e\x3c/")+"\x3e");var t;8>=m("ie")&&(t=function(a){a.__dojo_html5_tested="yes";var c=r("div",{innerHTML:"\x3cnav\x3ea\x3c/nav\x3e",style:{visibility:"hidden"}},a.body);1!==
c.childNodes.length&&"abbr article aside audio canvas details figcaption figure footer header hgroup mark meter nav output progress section summary time video".replace(/\b\w+\b/g,function(c){a.createElement(c)});v(c)});b.toDom=function(a,p){p=p||d.doc;var h=p[q];h||(p[q]=h=++g+"",n[h]=p.createElement("div"));8>=m("ie")&&!p.__dojo_html5_tested&&p.body&&t(p);a+="";var b=a.match(f),e=b?b[1].toLowerCase():"",h=n[h];if(b&&c[e])for(b=c[e],h.innerHTML=b.pre+a+b.post,a=b.length;a;--a)h=h.firstChild;else h.innerHTML=
a;if(1==h.childNodes.length)return h.removeChild(h.firstChild);for(a=p.createDocumentFragment();p=h.firstChild;)a.appendChild(p);return a};b.place=function(a,c,f){c=k.byId(c);"string"==typeof a&&(a=/^\s*</.test(a)?b.toDom(a,c.ownerDocument):k.byId(a));if("number"==typeof f){var g=c.childNodes;!g.length||g.length<=f?c.appendChild(a):h(a,g[0>f?0:f])}else switch(f){case "before":h(a,c);break;case "after":f=a;(g=c.parentNode)&&(g.lastChild==c?g.appendChild(f):g.insertBefore(f,c.nextSibling));break;case "replace":c.parentNode.replaceChild(a,
c);break;case "only":b.empty(c);c.appendChild(a);break;case "first":if(c.firstChild){h(a,c.firstChild);break}default:c.appendChild(a)}return a};var r=b.create=function(a,c,f,g){var n=d.doc;f&&(f=k.byId(f),n=f.ownerDocument);"string"==typeof a&&(a=n.createElement(a));c&&l.set(a,c);f&&b.place(a,f,g);return a};b.empty=function(c){a(k.byId(c))};var v=b.destroy=function(c){if(c=k.byId(c)){var f=c;c=c.parentNode;f.firstChild&&a(f);c&&(m("ie")&&c.canHaveChildren&&"removeNode"in f?f.removeNode(!1):c.removeChild(f))}}})},
"dojo/dom-class":function(){define(["./_base/lang","./_base/array","./dom"],function(b,e,m){function d(a){if("string"==typeof a||a instanceof String){if(a&&!l.test(a))return h[0]=a,h;a=a.split(l);a.length&&!a[0]&&a.shift();a.length&&!a[a.length-1]&&a.pop();return a}return a?e.filter(a,function(a){return a}):[]}var k,l=/\s+/,h=[""],a={};return k={contains:function(a,f){return 0<=(" "+m.byId(a).className+" ").indexOf(" "+f+" ")},add:function(a,f){a=m.byId(a);f=d(f);var c=a.className,g,c=c?" "+c+" ":
" ";g=c.length;for(var h=0,p=f.length,b;h<p;++h)(b=f[h])&&0>c.indexOf(" "+b+" ")&&(c+=b+" ");g<c.length&&(a.className=c.substr(1,c.length-2))},remove:function(a,f){a=m.byId(a);var c;if(void 0!==f){f=d(f);c=" "+a.className+" ";for(var g=0,h=f.length;g<h;++g)c=c.replace(" "+f[g]+" "," ");c=b.trim(c)}else c="";a.className!=c&&(a.className=c)},replace:function(c,f,n){c=m.byId(c);a.className=c.className;k.remove(a,n);k.add(a,f);c.className!==a.className&&(c.className=a.className)},toggle:function(a,f,
n){a=m.byId(a);if(void 0===n){f=d(f);for(var c=0,h=f.length,p;c<h;++c)p=f[c],k[k.contains(a,p)?"remove":"add"](a,p)}else k[n?"add":"remove"](a,f);return n}}})},"dojo/_base/array":function(){define(["./kernel","../has","./lang"],function(b,e,m){function d(a){return h[a]=new Function("item","index","array",a)}function k(a){var c=!a;return function(f,n,p){var g=0,b=f&&f.length||0,e;b&&"string"==typeof f&&(f=f.split(""));"string"==typeof n&&(n=h[n]||d(n));if(p)for(;g<b;++g){if(e=!n.call(p,f[g],g,f),a^
e)return!e}else for(;g<b;++g)if(e=!n(f[g],g,f),a^e)return!e;return c}}function l(f){var n=1,g=0,h=0;f||(n=g=h=-1);return function(p,d,b,e){if(e&&0<n)return c.lastIndexOf(p,d,b);e=p&&p.length||0;var q=f?e+h:g;b===a?b=f?g:e+h:0>b?(b=e+b,0>b&&(b=g)):b=b>=e?e+h:b;for(e&&"string"==typeof p&&(p=p.split(""));b!=q;b+=n)if(p[b]==d)return b;return-1}}var h={},a,c={every:k(!1),some:k(!0),indexOf:l(!0),lastIndexOf:l(!1),forEach:function(a,c,g){var f=0,n=a&&a.length||0;n&&"string"==typeof a&&(a=a.split(""));"string"==
typeof c&&(c=h[c]||d(c));if(g)for(;f<n;++f)c.call(g,a[f],f,a);else for(;f<n;++f)c(a[f],f,a)},map:function(a,c,g,b){var f=0,n=a&&a.length||0;b=new (b||Array)(n);n&&"string"==typeof a&&(a=a.split(""));"string"==typeof c&&(c=h[c]||d(c));if(g)for(;f<n;++f)b[f]=c.call(g,a[f],f,a);else for(;f<n;++f)b[f]=c(a[f],f,a);return b},filter:function(a,c,g){var f=0,n=a&&a.length||0,b=[],e;n&&"string"==typeof a&&(a=a.split(""));"string"==typeof c&&(c=h[c]||d(c));if(g)for(;f<n;++f)e=a[f],c.call(g,e,f,a)&&b.push(e);
else for(;f<n;++f)e=a[f],c(e,f,a)&&b.push(e);return b},clearCache:function(){h={}}};m.mixin(b,c);return c})},"dojo/_base/NodeList":function(){define(["./kernel","../query","./array","./html","../NodeList-dom"],function(b,e,m){e=e.NodeList;var d=e.prototype;d.connect=e._adaptAsForEach(function(){return b.connect.apply(this,arguments)});d.coords=e._adaptAsMap(b.coords);e.events="blur focus change click error keydown keypress keyup load mousedown mouseenter mouseleave mousemove mouseout mouseover mouseup submit".split(" ");
m.forEach(e.events,function(b){var e="on"+b;d[e]=function(h,a){return this.connect(e,h,a)}});return b.NodeList=e})},"dojo/query":function(){define("./_base/kernel ./has ./dom ./on ./_base/array ./_base/lang ./selector/_loader ./selector/_loader!default".split(" "),function(b,e,m,d,k,l,h,a){function c(a,c){var f=function(f,g){if("string"==typeof g&&(g=m.byId(g),!g))return new c([]);f="string"==typeof f?a(f,g):f?f.end&&f.on?f:[f]:[];return f.end&&f.on?f:new c(f)};f.matches=a.match||function(a,c,g){return 0<
f.filter([a],c,g).length};f.filter=a.filter||function(a,c,g){return f(c,g).filter(function(c){return-1<k.indexOf(a,c)})};if("function"!=typeof a){var g=a.search;a=function(a,c){return g(c||document,a)}}return f}var f=Array.prototype,n=f.slice,g=f.concat,q=k.forEach,p=function(a,c,f){c=[0].concat(n.call(c,0));f=f||b.global;return function(g){c[0]=g;return a.apply(f,c)}},t=function(a){var c=this instanceof r&&1;"number"==typeof a&&(a=Array(a));var f=a&&"length"in a?a:arguments;if(c||!f.sort){for(var g=
c?this:[],n=g.length=f.length,p=0;p<n;p++)g[p]=f[p];if(c)return g;f=g}l._mixin(f,v);f._NodeListCtor=function(a){return r(a)};return f},r=t,v=r.prototype=[];r._wrap=v._wrap=function(a,c,f){a=new (f||this._NodeListCtor||r)(a);return c?a._stash(c):a};r._adaptAsMap=function(a,c){return function(){return this.map(p(a,arguments,c))}};r._adaptAsForEach=function(a,c){return function(){this.forEach(p(a,arguments,c));return this}};r._adaptAsFilter=function(a,c){return function(){return this.filter(p(a,arguments,
c))}};r._adaptWithCondition=function(a,c,f){return function(){var g=arguments,n=p(a,g,f);if(c.call(f||b.global,g))return this.map(n);this.forEach(n);return this}};q(["slice","splice"],function(a){var c=f[a];v[a]=function(){return this._wrap(c.apply(this,arguments),"slice"==a?this:null)}});q(["indexOf","lastIndexOf","every","some"],function(a){var c=k[a];v[a]=function(){return c.apply(b,[this].concat(n.call(arguments,0)))}});l.extend(t,{constructor:r,_NodeListCtor:r,toString:function(){return this.join(",")},
_stash:function(a){this._parent=a;return this},on:function(a,c){var f=this.map(function(f){return d(f,a,c)});f.remove=function(){for(var a=0;a<f.length;a++)f[a].remove()};return f},end:function(){return this._parent?this._parent:new this._NodeListCtor(0)},concat:function(a){var c=n.call(this,0),f=k.map(arguments,function(a){return n.call(a,0)});return this._wrap(g.apply(c,f),this)},map:function(a,c){return this._wrap(k.map(this,a,c),this)},forEach:function(a,c){q(this,a,c);return this},filter:function(a){var c=
arguments,f=this,g=0;if("string"==typeof a){f=u._filterResult(this,c[0]);if(1==c.length)return f._stash(this);g=1}return this._wrap(k.filter(f,c[g],c[g+1]),this)},instantiate:function(a,c){var f=l.isFunction(a)?a:l.getObject(a);c=c||{};return this.forEach(function(a){new f(c,a)})},at:function(){var a=new this._NodeListCtor(0);q(arguments,function(c){0>c&&(c=this.length+c);this[c]&&a.push(this[c])},this);return a._stash(this)}});var u=c(a,t);b.query=c(a,function(a){return t(a)});u.load=function(a,
f,g){h.load(a,f,function(a){g(c(a,t))})};b._filterQueryResult=u._filterResult=function(a,c,f){return new t(u.filter(a,c,f))};b.NodeList=u.NodeList=t;return u})},"dojo/selector/_loader":function(){define(["../has","require"],function(b,e){"undefined"!==typeof document&&document.createElement("div");var m;return{load:function(d,k,l,h){if(h&&h.isBuild)l();else{h=e;d="default"==d?b("config-selectorEngine")||"css3":d;d="css2"==d||"lite"==d?"./lite":"css2.1"==d?"./lite":"css3"==d?"./lite":"acme"==d?"./acme":
(h=k)&&d;if("?"==d.charAt(d.length-1)){d=d.substring(0,d.length-1);var a=!0}if(a&&(b("dom-compliant-qsa")||m))return l(m);h([d],function(a){"./lite"!=d&&(m=a);l(a)})}}}})},"dojo/selector/lite":function(){define(["../has","../_base/kernel"],function(b,e){var m=document.createElement("div"),d=m.matches||m.webkitMatchesSelector||m.mozMatchesSelector||m.msMatchesSelector||m.oMatchesSelector,k=m.querySelectorAll,l=/([^\s,](?:"(?:\\.|[^"])+"|'(?:\\.|[^'])+'|[^,])*)/g,h=function(c,f){var n=f?f.ownerDocument||
f:e.doc||document,g=(k?/^([\w]*)#([\w\-]+$)|^(\.)([\w\-\*]+$)|^(\w+$)/:/^([\w]*)#([\w\-]+)(?:\s+(.*))?$|(?:^|(>|.+\s+))([\w\-\*]+)(\S*$)/).exec(c);f=f||n;if(g){var d=(b("ie"),null!==f.parentNode&&9!==f.nodeType&&f.parentNode===n);if(g[2]&&d){var p=e.byId?e.byId(g[2],n):n.getElementById(g[2]);if(!p||g[1]&&g[1]!=p.tagName.toLowerCase())return[];if(f!=n)for(c=p;c!=f;)if(c=c.parentNode,!c)return[];return g[3]?h(g[3],p):[p]}if(g[3]&&f.getElementsByClassName)return f.getElementsByClassName(g[4]);if(g[5])if(p=
f.getElementsByTagName(g[5]),g[4]||g[6])c=(g[4]||"")+g[6];else return p}if(k)return 1===f.nodeType&&"object"!==f.nodeName.toLowerCase()?a(f,c,f.querySelectorAll):f.querySelectorAll(c);p||(p=f.getElementsByTagName("*"));g=[];n=0;for(d=p.length;n<d;n++){var t=p[n];1==t.nodeType&&(void 0)(t,c,f)&&g.push(t)}return g},a=function(a,f,n){var c=a,h=a.getAttribute("id"),p=h||"__dojo__",d=a.parentNode,b=/^\s*[+~]/.test(f);if(b&&!d)return[];h?p=p.replace(/'/g,"\\$\x26"):a.setAttribute("id",p);b&&d&&(a=a.parentNode);
f=f.match(l);for(d=0;d<f.length;d++)f[d]="[id\x3d'"+p+"'] "+f[d];f=f.join(",");try{return n.call(a,f)}finally{h||c.removeAttribute("id")}};h.match=d?function(c,f,n){return n&&9!=n.nodeType?a(n,f,function(a){return d.call(c,a)}):d.call(c,f)}:void 0;return h})},"dojo/NodeList-dom":function(){define("./_base/kernel ./query ./_base/array ./_base/lang ./dom-class ./dom-construct ./dom-geometry ./dom-attr ./dom-style".split(" "),function(b,e,m,d,k,l,h,a,c){function f(a){return function(c,f,g){return 2==
arguments.length?a["string"==typeof f?"get":"set"](c,f):a.set(c,f,g)}}var n=function(a){return 1==a.length&&"string"==typeof a[0]},g=function(a){var c=a.parentNode;c&&c.removeChild(a)},q=e.NodeList,p=q._adaptWithCondition,t=q._adaptAsForEach,r=q._adaptAsMap;d.extend(q,{_normalize:function(a,c){var f=!0===a.parse;if("string"==typeof a.template){var g=a.templateFunc||b.string&&b.string.substitute;a=g?g(a.template,a):a}g=typeof a;"string"==g||"number"==g?(a=l.toDom(a,c&&c.ownerDocument),a=11==a.nodeType?
d._toArray(a.childNodes):[a]):d.isArrayLike(a)?d.isArray(a)||(a=d._toArray(a)):a=[a];f&&(a._runParse=!0);return a},_cloneNode:function(a){return a.cloneNode(!0)},_place:function(a,c,f,g){if(1==c.nodeType||"only"!=f)for(var n,p=a.length,h=p-1;0<=h;h--){var d=g?this._cloneNode(a[h]):a[h];if(a._runParse&&b.parser&&b.parser.parse)for(n||(n=c.ownerDocument.createElement("div")),n.appendChild(d),b.parser.parse(n),d=n.firstChild;n.firstChild;)n.removeChild(n.firstChild);h==p-1?l.place(d,c,f):c.parentNode.insertBefore(d,
c);c=d}},position:r(h.position),attr:p(f(a),n),style:p(f(c),n),addClass:t(k.add),removeClass:t(k.remove),toggleClass:t(k.toggle),replaceClass:t(k.replace),empty:t(l.empty),removeAttr:t(a.remove),marginBox:r(h.getMarginBox),place:function(a,c){var f=e(a)[0];return this.forEach(function(a){l.place(a,f,c)})},orphan:function(a){return(a?e._filterResult(this,a):this).forEach(g)},adopt:function(a,c){return e(a).place(this[0],c)._stash(this)},query:function(a){if(!a)return this;var c=new q;this.map(function(f){e(a,
f).forEach(function(a){void 0!==a&&c.push(a)})});return c._stash(this)},filter:function(a){var c=arguments,f=this,g=0;if("string"==typeof a){f=e._filterResult(this,c[0]);if(1==c.length)return f._stash(this);g=1}return this._wrap(m.filter(f,c[g],c[g+1]),this)},addContent:function(a,c){a=this._normalize(a,this[0]);for(var f=0,g;g=this[f];f++)a.length?this._place(a,g,c,0<f):l.empty(g);return this}});return q})},"dojo/_base/xhr":function(){define("./kernel ./sniff require ../io-query ../dom ../dom-form ./Deferred ./config ./json ./lang ./array ../on ../aspect ../request/watch ../request/xhr ../request/util".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r){b._xhrObj=t._create;var v=b.config;b.objectToQuery=d.objectToQuery;b.queryToObject=d.queryToObject;b.fieldToObject=l.fieldToObject;b.formToObject=l.toObject;b.formToQuery=l.toQuery;b.formToJson=l.toJson;b._blockAsync=!1;var u=b._contentHandlers=b.contentHandlers={text:function(a){return a.responseText},json:function(a){return c.fromJson(a.responseText||null)},"json-comment-filtered":function(f){a.useCommentedJson||console.warn("Consider using the standard mimetype:application/json. json-commenting can introduce security issues. To decrease the chances of hijacking, use the standard the 'json' handler and prefix your json with: {}\x26\x26\nUse djConfig.useCommentedJson\x3dtrue to turn off this message.");
f=f.responseText;var g=f.indexOf("/*"),n=f.lastIndexOf("*/");if(-1==g||-1==n)throw Error("JSON was not comment filtered");return c.fromJson(f.substring(g+2,n))},javascript:function(a){return b.eval(a.responseText)},xml:function(a){var c=a.responseXML;c&&!c.querySelectorAll&&(c=(new DOMParser).parseFromString(a.responseText,"application/xml"));if(e("ie")&&(!c||!c.documentElement)){var f=function(a){return"MSXML"+a+".DOMDocument"},f=["Microsoft.XMLDOM",f(6),f(4),f(3),f(2)];n.some(f,function(f){try{var g=
new ActiveXObject(f);g.async=!1;g.loadXML(a.responseText);c=g}catch(G){return!1}return!0})}return c},"json-comment-optional":function(a){return a.responseText&&/^[^{\[]*\/\*/.test(a.responseText)?u["json-comment-filtered"](a):u.json(a)}};u.arraybuffer=u.blob=u.document=function(a,c){return a.response};b._ioSetArgs=function(a,c,g,n){var p={args:a,url:a.url},e=null;if(a.form){var e=k.byId(a.form),q=e.getAttributeNode("action");p.url=p.url||(q?q.value:b.doc?b.doc.URL:null);e=l.toObject(e)}q={};e&&f.mixin(q,
e);a.content&&f.mixin(q,a.content);a.preventCache&&(q["dojo.preventCache"]=(new Date).valueOf());p.query=d.objectToQuery(q);p.handleAs=a.handleAs||"text";var t=new h(function(a){a.canceled=!0;c&&c(a);var f=a.ioArgs.error;f||(f=Error("request cancelled"),f.dojoType="cancel",a.ioArgs.error=f);return f});t.addCallback(g);var r=a.load;r&&f.isFunction(r)&&t.addCallback(function(c){return r.call(a,c,p)});var u=a.error;u&&f.isFunction(u)&&t.addErrback(function(c){return u.call(a,c,p)});var x=a.handle;x&&
f.isFunction(x)&&t.addBoth(function(c){return x.call(a,c,p)});t.addErrback(function(a){return n(a,t)});v.ioPublish&&b.publish&&!1!==p.args.ioPublish&&(t.addCallbacks(function(a){b.publish("/dojo/io/load",[t,a]);return a},function(a){b.publish("/dojo/io/error",[t,a]);return a}),t.addBoth(function(a){b.publish("/dojo/io/done",[t,a]);return a}));t.ioArgs=p;return t};var z=function(a){a=u[a.ioArgs.handleAs](a.ioArgs.xhr,a.ioArgs);return void 0===a?null:a},y=function(a,c){c.ioArgs.args.failOk||console.error(a);
return a},x=function(a){0>=w&&(w=0,v.ioPublish&&b.publish&&(!a||a&&!1!==a.ioArgs.args.ioPublish)&&b.publish("/dojo/io/stop"))},w=0;q.after(p,"_onAction",function(){--w});q.after(p,"_onInFlight",x);b._ioCancelAll=p.cancelAll;b._ioNotifyStart=function(a){v.ioPublish&&b.publish&&!1!==a.ioArgs.args.ioPublish&&(w||b.publish("/dojo/io/start"),w+=1,b.publish("/dojo/io/send",[a]))};b._ioWatch=function(a,c,g,n){a.ioArgs.options=a.ioArgs.args;f.mixin(a,{response:a.ioArgs,isValid:function(f){return c(a)},isReady:function(c){return g(a)},
handleResponse:function(c){return n(a)}});p(a);x(a)};b._ioAddQueryToUrl=function(a){a.query.length&&(a.url+=(-1==a.url.indexOf("?")?"?":"\x26")+a.query,a.query=null)};b.xhr=function(a,c,f){var g,n=b._ioSetArgs(c,function(a){g&&g.cancel()},z,y),p=n.ioArgs;"postData"in c?p.query=c.postData:"putData"in c?p.query=c.putData:"rawBody"in c?p.query=c.rawBody:(2<arguments.length&&!f||-1==="POST|PUT".indexOf(a.toUpperCase()))&&b._ioAddQueryToUrl(p);var h={method:a,handleAs:{arraybuffer:1,blob:1,document:1}[c.handleAs]?
c.handleAs:"text",responseType:c.responseType,timeout:c.timeout,withCredentials:c.withCredentials,ioArgs:p};"undefined"!==typeof c.headers&&(h.headers=c.headers);"undefined"!==typeof c.contentType&&(h.headers||(h.headers={}),h.headers["Content-Type"]=c.contentType);"undefined"!==typeof p.query&&(h.data=p.query);"undefined"!==typeof c.sync&&(h.sync=c.sync);b._ioNotifyStart(n);try{g=t(p.url,h,!0)}catch(V){return n.cancel(),n}n.ioArgs.xhr=g.response.xhr;g.then(function(){n.resolve(n)}).otherwise(function(a){p.error=
a;a.response&&(a.status=a.response.status,a.responseText=a.response.text,a.xhr=a.response.xhr);n.reject(a)});return n};b.xhrGet=function(a){return b.xhr("GET",a)};b.rawXhrPost=b.xhrPost=function(a){return b.xhr("POST",a,!0)};b.rawXhrPut=b.xhrPut=function(a){return b.xhr("PUT",a,!0)};b.xhrDelete=function(a){return b.xhr("DELETE",a)};b._isDocumentOk=function(a){return r.checkStatus(a.status)};b._getText=function(a){var c;b.xhrGet({url:a,sync:!0,load:function(a){c=a}});return c};f.mixin(b.xhr,{_xhrObj:b._xhrObj,
fieldToObject:l.fieldToObject,formToObject:l.toObject,objectToQuery:d.objectToQuery,formToQuery:l.toQuery,formToJson:l.toJson,queryToObject:d.queryToObject,contentHandlers:u,_ioSetArgs:b._ioSetArgs,_ioCancelAll:b._ioCancelAll,_ioNotifyStart:b._ioNotifyStart,_ioWatch:b._ioWatch,_ioAddQueryToUrl:b._ioAddQueryToUrl,_isDocumentOk:b._isDocumentOk,_getText:b._getText,get:b.xhrGet,post:b.xhrPost,put:b.xhrPut,del:b.xhrDelete});return b.xhr})},"dojo/io-query":function(){define(["./_base/lang"],function(b){var e=
{};return{objectToQuery:function(m){var d=encodeURIComponent,k=[],l;for(l in m){var h=m[l];if(h!=e[l]){var a=d(l)+"\x3d";if(b.isArray(h))for(var c=0,f=h.length;c<f;++c)k.push(a+d(h[c]));else k.push(a+d(h))}}return k.join("\x26")},queryToObject:function(e){var d=decodeURIComponent;e=e.split("\x26");for(var k={},l,h,a=0,c=e.length;a<c;++a)if(h=e[a],h.length){var f=h.indexOf("\x3d");0>f?(l=d(h),h=""):(l=d(h.slice(0,f)),h=d(h.slice(f+1)));"string"==typeof k[l]&&(k[l]=[k[l]]);b.isArray(k[l])?k[l].push(h):
k[l]=h}return k}}})},"dojo/dom-form":function(){define(["./_base/lang","./dom","./io-query","./json"],function(b,e,m,d){var k={fieldToObject:function(d){var h=null;if(d=e.byId(d)){var a=d.name,c=(d.type||"").toLowerCase();if(a&&c&&!d.disabled)if("radio"==c||"checkbox"==c)d.checked&&(h=d.value);else if(d.multiple)for(h=[],d=[d.firstChild];d.length;)for(a=d.pop();a;a=a.nextSibling)if(1==a.nodeType&&"option"==a.tagName.toLowerCase())a.selected&&h.push(a.value);else{a.nextSibling&&d.push(a.nextSibling);
a.firstChild&&d.push(a.firstChild);break}else h=d.value}return h},toObject:function(d){var h={};d=e.byId(d).elements;for(var a=0,c=d.length;a<c;++a){var f=d[a],n=f.name,g=(f.type||"").toLowerCase();if(n&&g&&0>"file|submit|image|reset|button".indexOf(g)&&!f.disabled){var q=h,p=n,f=k.fieldToObject(f);if(null!==f){var t=q[p];"string"==typeof t?q[p]=[t,f]:b.isArray(t)?t.push(f):q[p]=f}"image"==g&&(h[n+".x"]=h[n+".y"]=h[n].x=h[n].y=0)}}return h},toQuery:function(d){return m.objectToQuery(k.toObject(d))},
toJson:function(b,h){return d.stringify(k.toObject(b),null,h?4:0)}};return k})},"dojo/json":function(){define(["./has"],function(b){return JSON})},"dojo/_base/Deferred":function(){define("./kernel ../Deferred ../promise/Promise ../errors/CancelError ../has ./lang ../when".split(" "),function(b,e,m,d,k,l,h){var a=function(){},c=Object.freeze||function(){},f=b.Deferred=function(n){function g(a){if(b)throw Error("This deferred has already been resolved");p=a;b=!0;h()}function h(){for(var c;!c&&y;){var f=
y;y=y.next;if(c=f.progress==a)b=!1;var g=u?f.error:f.resolved;k("config-useDeferredInstrumentation")&&u&&e.instrumentRejected&&e.instrumentRejected(p,!!g);if(g)try{var n=g(p);n&&"function"===typeof n.then?n.then(l.hitch(f.deferred,"resolve"),l.hitch(f.deferred,"reject"),l.hitch(f.deferred,"progress")):(g=c&&void 0===n,c&&!g&&(u=n instanceof Error),f.deferred[g&&u?"reject":"resolve"](g?p:n))}catch(E){f.deferred.reject(E)}else u?f.deferred.reject(p):f.deferred.resolve(p)}}var p,b,r,v,u,z,y,x=this.promise=
new m;this.isResolved=x.isResolved=function(){return 0==v};this.isRejected=x.isRejected=function(){return 1==v};this.isFulfilled=x.isFulfilled=function(){return 0<=v};this.isCanceled=x.isCanceled=function(){return r};this.resolve=this.callback=function(a){this.fired=v=0;this.results=[a,null];g(a)};this.reject=this.errback=function(a){u=!0;this.fired=v=1;k("config-useDeferredInstrumentation")&&e.instrumentRejected&&e.instrumentRejected(a,!!y);g(a);this.results=[null,a]};this.progress=function(a){for(var c=
y;c;){var f=c.progress;f&&f(a);c=c.next}};this.addCallbacks=function(c,f){this.then(c,f,a);return this};x.then=this.then=function(c,g,n){var p=n==a?this:new f(x.cancel);c={resolved:c,error:g,progress:n,deferred:p};y?z=z.next=c:y=z=c;b&&h();return p.promise};var w=this;x.cancel=this.cancel=function(){if(!b){var a=n&&n(w);b||(a instanceof Error||(a=new d(a)),a.log=!1,w.reject(a))}r=!0};c(x)};l.extend(f,{addCallback:function(a){return this.addCallbacks(l.hitch.apply(b,arguments))},addErrback:function(a){return this.addCallbacks(null,
l.hitch.apply(b,arguments))},addBoth:function(a){var c=l.hitch.apply(b,arguments);return this.addCallbacks(c,c)},fired:-1});f.when=b.when=h;return f})},"dojo/Deferred":function(){define(["./has","./_base/lang","./errors/CancelError","./promise/Promise","./has!config-deferredInstrumentation?./promise/instrumentation"],function(b,e,m,d,k){var l=Object.freeze||function(){},h=function(c,f,p,d,h){b("config-deferredInstrumentation")&&2===f&&n.instrumentRejected&&0===c.length&&n.instrumentRejected(p,!1,
d,h);for(h=0;h<c.length;h++)a(c[h],f,p,d)},a=function(a,d,p,h){var g=a[d],e=a.deferred;if(g)try{var q=g(p);if(0===d)"undefined"!==typeof q&&f(e,d,q);else{if(q&&"function"===typeof q.then){a.cancel=q.cancel;q.then(c(e,1),c(e,2),c(e,0));return}f(e,1,q)}}catch(z){f(e,2,z)}else f(e,d,p);b("config-deferredInstrumentation")&&2===d&&n.instrumentRejected&&n.instrumentRejected(p,!!g,h,e.promise)},c=function(a,c){return function(g){f(a,c,g)}},f=function(a,c,f){if(!a.isCanceled())switch(c){case 0:a.progress(f);
break;case 1:a.resolve(f);break;case 2:a.reject(f)}},n=function(c){var f=this.promise=new d,g=this,e,r,k,u=!1,z=[];b("config-deferredInstrumentation")&&Error.captureStackTrace&&(Error.captureStackTrace(g,n),Error.captureStackTrace(f,n));this.isResolved=f.isResolved=function(){return 1===e};this.isRejected=f.isRejected=function(){return 2===e};this.isFulfilled=f.isFulfilled=function(){return!!e};this.isCanceled=f.isCanceled=function(){return u};this.progress=function(a,c){if(e){if(!0===c)throw Error("This deferred has already been fulfilled.");
return f}h(z,0,a,null,g);return f};this.resolve=function(a,c){if(e){if(!0===c)throw Error("This deferred has already been fulfilled.");return f}h(z,e=1,r=a,null,g);z=null;return f};var y=this.reject=function(a,c){if(e){if(!0===c)throw Error("This deferred has already been fulfilled.");return f}b("config-deferredInstrumentation")&&Error.captureStackTrace&&Error.captureStackTrace(k={},y);h(z,e=2,r=a,k,g);z=null;return f};this.then=f.then=function(c,g,p){var d=[p,c,g];d.cancel=f.cancel;d.deferred=new n(function(a){return d.cancel&&
d.cancel(a)});e&&!z?a(d,e,r,k):z.push(d);return d.deferred.promise};this.cancel=f.cancel=function(a,f){if(!e){c&&(f=c(a),a="undefined"===typeof f?a:f);u=!0;if(!e)return"undefined"===typeof a&&(a=new m),y(a),a;if(2===e&&r===a)return a}else if(!0===f)throw Error("This deferred has already been fulfilled.");};l(f)};n.prototype.toString=function(){return"[object Deferred]"};k&&k(n);return n})},"dojo/errors/CancelError":function(){define(["./create"],function(b){return b("CancelError",null,null,{dojoType:"cancel",
log:!1})})},"dojo/errors/create":function(){define(["../_base/lang"],function(b){return function(e,m,d,k){d=d||Error;var l=function(h){if(d===Error){Error.captureStackTrace&&Error.captureStackTrace(this,l);var a=Error.call(this,h),c;for(c in a)a.hasOwnProperty(c)&&(this[c]=a[c]);this.message=h;this.stack=a.stack}else d.apply(this,arguments);m&&m.apply(this,arguments)};l.prototype=b.delegate(d.prototype,k);l.prototype.name=e;return l.prototype.constructor=l}})},"dojo/promise/Promise":function(){define(["../_base/lang"],
function(b){function e(){throw new TypeError("abstract");}return b.extend(function(){},{then:function(b,d,k){e()},cancel:function(b,d){e()},isResolved:function(){e()},isRejected:function(){e()},isFulfilled:function(){e()},isCanceled:function(){e()},always:function(b){return this.then(b,b)},"catch":function(b){return this.then(null,b)},otherwise:function(b){return this.then(null,b)},trace:function(){return this},traceRejected:function(){return this},toString:function(){return"[object Promise]"}})})},
"dojo/when":function(){define(["./Deferred","./promise/Promise"],function(b,e){return function(m,d,k,l){var h=m&&"function"===typeof m.then,a=h&&m instanceof e;if(!h)return 1<arguments.length?d?d(m):m:(new b).resolve(m);a||(h=new b(m.cancel),m.then(h.resolve,h.reject,h.progress),m=h.promise);return d||k||l?m.then(d,k,l):m}})},"dojo/_base/json":function(){define(["./kernel","../json"],function(b,e){b.fromJson=function(b){return eval("("+b+")")};b._escapeString=e.stringify;b.toJsonIndentStr="\t";b.toJson=
function(m,d){return e.stringify(m,function(d,b){return b&&(d=b.__json__||b.json,"function"==typeof d)?d.call(b):b},d&&b.toJsonIndentStr)};return b})},"dojo/request/watch":function(){define("./util ../errors/RequestTimeoutError ../errors/CancelError ../_base/array ../has!host-browser?../_base/window: ../has!host-browser?dom-addeventlistener?:../on:".split(" "),function(b,e,m,d,k,l){function h(){for(var n=+new Date,g=0,d;g<f.length&&(d=f[g]);g++){var p=d.response,h=p.options;d.isCanceled&&d.isCanceled()||
d.isValid&&!d.isValid(p)?(f.splice(g--,1),a._onAction&&a._onAction()):d.isReady&&d.isReady(p)?(f.splice(g--,1),d.handleResponse(p),a._onAction&&a._onAction()):d.startTime&&d.startTime+(h.timeout||0)<n&&(f.splice(g--,1),d.cancel(new e("Timeout exceeded",p)),a._onAction&&a._onAction())}a._onInFlight&&a._onInFlight(d);f.length||(clearInterval(c),c=null)}function a(a){a.response.options.timeout&&(a.startTime=+new Date);a.isFulfilled()||(f.push(a),c||(c=setInterval(h,50)),a.response.options.sync&&h())}
var c=null,f=[];a.cancelAll=function(){try{d.forEach(f,function(a){try{a.cancel(new m("All requests canceled."))}catch(g){}})}catch(n){}};k&&l&&k.doc.attachEvent&&l(k.global,"unload",function(){a.cancelAll()});return a})},"dojo/request/util":function(){define("exports ../errors/RequestError ../errors/CancelError ../Deferred ../io-query ../_base/array ../_base/lang ../promise/Promise ../has".split(" "),function(b,e,m,d,k,l,h,a,c){function f(a){return g(a)}function n(a){return void 0!==a.data?a.data:
a.text}b.deepCopy=function(a,c){for(var f in c){var g=a[f],n=c[f];g!==n&&(g&&"object"===typeof g&&n&&"object"===typeof n?n instanceof Date?a[f]=new Date(n):b.deepCopy(g,n):a[f]=n)}return a};b.deepCreate=function(a,c){c=c||{};var f=h.delegate(a),g,n;for(g in a)(n=a[g])&&"object"===typeof n&&(f[g]=b.deepCreate(n,c[g]));return b.deepCopy(f,c)};var g=Object.freeze||function(a){return a};b.deferred=function(c,p,t,r,l,k){var q=new d(function(a){p&&p(q,c);return a&&(a instanceof e||a instanceof m)?a:new m("Request canceled",
c)});q.response=c;q.isValid=t;q.isReady=r;q.handleResponse=l;t=q.then(f).otherwise(function(a){a.response=c;throw a;});b.notify&&t.then(h.hitch(b.notify,"emit","load"),h.hitch(b.notify,"emit","error"));r=t.then(n);l=new a;for(var v in r)r.hasOwnProperty(v)&&(l[v]=r[v]);l.response=t;g(l);k&&q.then(function(a){k.call(q,a)},function(a){k.call(q,c,a)});q.promise=l;q.then=l.then;return q};b.addCommonMethods=function(a,c){l.forEach(c||["GET","POST","PUT","DELETE"],function(c){a[("DELETE"===c?"DEL":c).toLowerCase()]=
function(f,g){g=h.delegate(g||{});g.method=c;return a(f,g)}})};b.parseArgs=function(a,c,f){var g=c.data,n=c.query;!g||f||"object"!==typeof g||g instanceof ArrayBuffer||g instanceof Blob||(c.data=k.objectToQuery(g));n?("object"===typeof n&&(n=k.objectToQuery(n)),c.preventCache&&(n+=(n?"\x26":"")+"request.preventCache\x3d"+ +new Date)):c.preventCache&&(n="request.preventCache\x3d"+ +new Date);a&&n&&(a+=(~a.indexOf("?")?"\x26":"?")+n);return{url:a,options:c,getHeader:function(a){return null}}};b.checkStatus=
function(a){a=a||0;return 200<=a&&300>a||304===a||1223===a||!a}})},"dojo/errors/RequestError":function(){define(["./create"],function(b){return b("RequestError",function(b,m){this.response=m})})},"dojo/errors/RequestTimeoutError":function(){define(["./create","./RequestError"],function(b,e){return b("RequestTimeoutError",null,e,{dojoType:"timeout"})})},"dojo/request/xhr":function(){define(["../errors/RequestError","./watch","./handlers","./util","../has"],function(b,e,m,d,k){function l(a,c){var f=
a.xhr;a.status=a.xhr.status;try{a.text=f.responseText}catch(y){}"xml"===a.options.handleAs&&(a.data=f.responseXML);var g;if(c)this.reject(c);else{try{m(a)}catch(y){g=y}d.checkStatus(f.status)?g?this.reject(g):this.resolve(a):(c=g?new b("Unable to load "+a.url+" status: "+f.status+" and an error in handleAs: transformation of response",a):new b("Unable to load "+a.url+" status: "+f.status,a),this.reject(c))}}function h(a){return this.xhr.getResponseHeader(a)}function a(r,v,u){var m=v&&v.data&&v.data instanceof
FormData,y=d.parseArgs(r,d.deepCreate(t,v),m);r=y.url;v=y.options;var x=!v.data&&"POST"!==v.method&&"PUT"!==v.method;10>=k("ie")&&(r=r.split("#")[0]);var w,A=d.deferred(y,q,f,n,l,function(){w&&w()}),B=y.xhr=a._create();if(!B)return A.cancel(new b("XHR was not created")),u?A:A.promise;y.getHeader=h;g&&(w=g(B,A,y,v.uploadProgress));var F="undefined"===typeof v.data?null:v.data,C=!v.sync,E=v.method;try{B.open(E,r,C,v.user||p,v.password||p);v.withCredentials&&(B.withCredentials=v.withCredentials);v.handleAs in
c&&(B.responseType=c[v.handleAs]);var G=v.headers;r=m||x?!1:"application/x-www-form-urlencoded";if(G)for(var Q in G)"content-type"===Q.toLowerCase()?r=G[Q]:G[Q]&&B.setRequestHeader(Q,G[Q]);r&&!1!==r&&B.setRequestHeader("Content-Type",r);G&&"X-Requested-With"in G||B.setRequestHeader("X-Requested-With","XMLHttpRequest");d.notify&&d.notify.emit("send",y,A.promise.cancel);B.send(F)}catch(V){A.reject(V)}e(A);B=null;return u?A:A.promise}k.add("dojo-force-activex-xhr",function(){return 0});var c={blob:"blob",
document:"document",arraybuffer:"arraybuffer"},f,n,g,q;f=function(a){return!this.isFulfilled()};q=function(a,c){c.xhr.abort()};g=function(a,c,f,g){function n(a){c.handleResponse(f)}function d(a){a=new b("Unable to load "+f.url+" status: "+a.target.status,f);c.handleResponse(f,a)}function h(a,g){f.transferType=a;g.lengthComputable?(f.loaded=g.loaded,f.total=g.total,c.progress(f)):3===f.xhr.readyState&&(f.loaded="loaded"in g?g.loaded:g.position,c.progress(f))}function p(a){return h("download",a)}function e(a){return h("upload",
a)}a.addEventListener("load",n,!1);a.addEventListener("error",d,!1);a.addEventListener("progress",p,!1);g&&a.upload&&a.upload.addEventListener("progress",e,!1);return function(){a.removeEventListener("load",n,!1);a.removeEventListener("error",d,!1);a.removeEventListener("progress",p,!1);a.upload.removeEventListener("progress",e,!1);a=null}};var p,t={data:null,query:null,sync:!1,method:"GET"};a._create=function(){throw Error("XMLHTTP not available");};k("dojo-force-activex-xhr")||(a._create=function(){return new XMLHttpRequest});
d.addCommonMethods(a);return a})},"dojo/request/handlers":function(){define(["../json","../_base/kernel","../_base/array","../has","../has!dom?../selector/_loader"],function(b,e,m,d){function k(d){var a=l[d.options.handleAs];d.data=a?a(d):d.data||d.text;return d}m=function(d){return d.xhr.response};var l={javascript:function(d){return e.eval(d.text||"")},json:function(d){return b.parse(d.text||null)},xml:void 0,blob:m,arraybuffer:m,document:m};k.register=function(d,a){l[d]=a};return k})},"dojo/_base/fx":function(){define("./kernel ./config ./lang ../Evented ./Color ../aspect ../sniff ../dom ../dom-style".split(" "),
function(b,e,m,d,k,l,h,a,c){var f=m.mixin,n={},g=n._Line=function(a,c){this.start=a;this.end=c};g.prototype.getValue=function(a){return(this.end-this.start)*a+this.start};var q=n.Animation=function(a){f(this,a);m.isArray(this.curve)&&(this.curve=new g(this.curve[0],this.curve[1]))};q.prototype=new d;m.extend(q,{duration:350,repeat:0,rate:20,_percent:0,_startRepeatCount:0,_getStep:function(){var a=this._percent,c=this.easing;return c?c(a):a},_fire:function(a,c){c=c||[];if(this[a])if(e.debugAtAllCosts)this[a].apply(this,
c);else try{this[a].apply(this,c)}catch(x){console.error("exception in animation handler for:",a),console.error(x)}return this},play:function(a,c){this._delayTimer&&this._clearTimer();if(c)this._stopTimer(),this._active=this._paused=!1,this._percent=0;else if(this._active&&!this._paused)return this;this._fire("beforeBegin",[this.node]);a=a||this.delay;c=m.hitch(this,"_play",c);if(0<a)return this._delayTimer=setTimeout(c,a),this;c();return this},_play:function(a){this._delayTimer&&this._clearTimer();
this._startTime=(new Date).valueOf();this._paused&&(this._startTime-=this.duration*this._percent);this._active=!0;this._paused=!1;a=this.curve.getValue(this._getStep());this._percent||(this._startRepeatCount||(this._startRepeatCount=this.repeat),this._fire("onBegin",[a]));this._fire("onPlay",[a]);this._cycle();return this},pause:function(){this._delayTimer&&this._clearTimer();this._stopTimer();if(!this._active)return this;this._paused=!0;this._fire("onPause",[this.curve.getValue(this._getStep())]);
return this},gotoPercent:function(a,c){this._stopTimer();this._active=this._paused=!0;this._percent=a;c&&this.play();return this},stop:function(a){this._delayTimer&&this._clearTimer();if(!this._timer)return this;this._stopTimer();a&&(this._percent=1);this._fire("onStop",[this.curve.getValue(this._getStep())]);this._active=this._paused=!1;return this},destroy:function(){this.stop()},status:function(){return this._active?this._paused?"paused":"playing":"stopped"},_cycle:function(){if(this._active){var a=
(new Date).valueOf(),a=0===this.duration?1:(a-this._startTime)/this.duration;1<=a&&(a=1);this._percent=a;this.easing&&(a=this.easing(a));this._fire("onAnimate",[this.curve.getValue(a)]);1>this._percent?this._startTimer():(this._active=!1,0<this.repeat?(this.repeat--,this.play(null,!0)):-1==this.repeat?this.play(null,!0):this._startRepeatCount&&(this.repeat=this._startRepeatCount,this._startRepeatCount=0),this._percent=0,this._fire("onEnd",[this.node]),!this.repeat&&this._stopTimer())}return this},
_clearTimer:function(){clearTimeout(this._delayTimer);delete this._delayTimer}});var p=0,t=null,r={run:function(){}};m.extend(q,{_startTimer:function(){this._timer||(this._timer=l.after(r,"run",m.hitch(this,"_cycle"),!0),p++);t||(t=setInterval(m.hitch(r,"run"),this.rate))},_stopTimer:function(){this._timer&&(this._timer.remove(),this._timer=null,p--);0>=p&&(clearInterval(t),t=null,p=0)}});var v=h("ie")?function(a){var f=a.style;f.width.length||"auto"!=c.get(a,"width")||(f.width="auto")}:function(){};
n._fade=function(g){g.node=a.byId(g.node);var d=f({properties:{}},g);g=d.properties.opacity={};g.start="start"in d?d.start:function(){return+c.get(d.node,"opacity")||0};g.end=d.end;g=n.animateProperty(d);l.after(g,"beforeBegin",m.partial(v,d.node),!0);return g};n.fadeIn=function(a){return n._fade(f({end:1},a))};n.fadeOut=function(a){return n._fade(f({end:0},a))};n._defaultEasing=function(a){return.5+Math.sin((a+1.5)*Math.PI)/2};var u=function(a){this._properties=a;for(var c in a){var f=a[c];f.start instanceof
k&&(f.tempColor=new k)}};u.prototype.getValue=function(a){var c={},f;for(f in this._properties){var g=this._properties[f],n=g.start;n instanceof k?c[f]=k.blendColors(n,g.end,a,g.tempColor).toCss():m.isArray(n)||(c[f]=(g.end-n)*a+n+("opacity"!=f?g.units||"px":0))}return c};n.animateProperty=function(g){var n=g.node=a.byId(g.node);g.easing||(g.easing=b._defaultEasing);g=new q(g);l.after(g,"beforeBegin",m.hitch(g,function(){var a={},g;for(g in this.properties){var d=function(a,f){var g={height:a.offsetHeight,
width:a.offsetWidth}[f];if(void 0!==g)return g;g=c.get(a,f);return"opacity"==f?+g:h?g:parseFloat(g)};if("width"==g||"height"==g)this.node.display="block";var p=this.properties[g];m.isFunction(p)&&(p=p(n));p=a[g]=f({},m.isObject(p)?p:{end:p});m.isFunction(p.start)&&(p.start=p.start(n));m.isFunction(p.end)&&(p.end=p.end(n));var h=0<=g.toLowerCase().indexOf("color");"end"in p?"start"in p||(p.start=d(n,g)):p.end=d(n,g);h?(p.start=new k(p.start),p.end=new k(p.end)):p.start="opacity"==g?+p.start:parseFloat(p.start)}this.curve=
new u(a)}),!0);l.after(g,"onAnimate",m.hitch(c,"set",g.node),!0);return g};n.anim=function(a,c,f,g,d,p){return n.animateProperty({node:a,duration:f||q.prototype.duration,properties:c,easing:g,onEnd:d}).play(p||0)};f(b,n);b._Animation=q;return n})},"dojo/_base/Color":function(){define(["./kernel","./lang","./array","./config"],function(b,e,m,d){var k=b.Color=function(d){d&&this.setColor(d)};k.named={black:[0,0,0],silver:[192,192,192],gray:[128,128,128],white:[255,255,255],maroon:[128,0,0],red:[255,
0,0],purple:[128,0,128],fuchsia:[255,0,255],green:[0,128,0],lime:[0,255,0],olive:[128,128,0],yellow:[255,255,0],navy:[0,0,128],blue:[0,0,255],teal:[0,128,128],aqua:[0,255,255],transparent:d.transparentColor||[0,0,0,0]};e.extend(k,{r:255,g:255,b:255,a:1,_set:function(d,h,a,c){this.r=d;this.g=h;this.b=a;this.a=c},setColor:function(d){e.isString(d)?k.fromString(d,this):e.isArray(d)?k.fromArray(d,this):(this._set(d.r,d.g,d.b,d.a),d instanceof k||this.sanitize());return this},sanitize:function(){return this},
toRgb:function(){return[this.r,this.g,this.b]},toRgba:function(){return[this.r,this.g,this.b,this.a]},toHex:function(){return"#"+m.map(["r","g","b"],function(d){d=this[d].toString(16);return 2>d.length?"0"+d:d},this).join("")},toCss:function(d){var h=this.r+", "+this.g+", "+this.b;return(d?"rgba("+h+", "+this.a:"rgb("+h)+")"},toString:function(){return this.toCss(!0)}});k.blendColors=b.blendColors=function(d,h,a,c){c=c||new k;c.r=Math.round(d.r+(h.r-d.r)*a);c.g=Math.round(d.g+(h.g-d.g)*a);c.b=Math.round(d.b+
(h.b-d.b)*a);c.a=d.a+(h.a-d.a)*a;return c.sanitize()};k.fromRgb=b.colorFromRgb=function(d,h){return(d=d.toLowerCase().match(/^rgba?\(([\s\.,0-9]+)\)/))&&k.fromArray(d[1].split(/\s*,\s*/),h)};k.fromHex=b.colorFromHex=function(d,h){var a=h||new k,c=4==d.length?4:8,f=(1<<c)-1;d=Number("0x"+d.substr(1));if(isNaN(d))return null;m.forEach(["b","g","r"],function(n){var g=d&f;d>>=c;a[n]=4==c?17*g:g});a.a=1;return a};k.fromArray=b.colorFromArray=function(d,h){h=h||new k;h._set(Number(d[0]),Number(d[1]),Number(d[2]),
Number(d[3]));isNaN(h.a)&&(h.a=1);return h.sanitize()};k.fromString=b.colorFromString=function(d,h){var a=k.named[d];return a&&k.fromArray(a,h)||k.fromRgb(d,h)||k.fromHex(d,h)};return k})},"dojo/request":function(){define(["./request/default!"],function(b){return b})},"dojo/request/default":function(){define(["exports","require","../has"],function(b,e,m){var d=m("config-requestProvider"),k;if(m("host-browser")||m("host-webworker"))k="./xhr";d||(d=k);b.getPlatformDefaultId=function(){return k};b.load=
function(b,h,a,c){e(["platform"==b?k:d],function(c){a(c)})}})},"esri/Map":function(){define("require exports ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./Basemap ./Ground ./core/Accessor ./core/CollectionFlattener ./core/Evented ./core/Logger ./core/accessorSupport/decorators ./support/basemapUtils ./support/groundUtils ./support/LayersMixin".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g,q,p){var t=f.getLogger("esri.Map");return function(c){function f(a){a=c.call(this)||this;
a.basemap=null;a.ground=new l;a._basemapCache=g.createCache();return a}m(f,c);Object.defineProperty(f.prototype,"allLayers",{get:function(){return new a({root:this,rootCollectionNames:["basemap.baseLayers","ground.layers","layers","basemap.referenceLayers"],getChildrenFunction:function(a){return a.layers}})},enumerable:!0,configurable:!0});f.prototype.castBasemap=function(a){return g.ensureType(a,this._basemapCache)};f.prototype.castGround=function(a){a=q.ensureType(a);return a?a:(t.error("Map.ground may not be set to null or undefined"),
this._get("ground"))};d([n.property({readOnly:!0})],f.prototype,"allLayers",null);d([n.property({type:k})],f.prototype,"basemap",void 0);d([n.cast("basemap")],f.prototype,"castBasemap",null);d([n.property({type:l,nonNullable:!0})],f.prototype,"ground",void 0);d([n.cast("ground")],f.prototype,"castGround",null);return f=d([n.subclass("esri.Map")],f)}(n.declared(h,c,p))})},"esri/core/tsSupport/declareExtendsHelper":function(){define(["require","exports"],function(b,e){return function(b,d){b.__bases__=
d.__bases__}})},"esri/core/tsSupport/decorateHelper":function(){define([],function(){return function(b,e,m,d){var k=arguments.length,l=3>k?e:null===d?d=Object.getOwnPropertyDescriptor(e,m):d,h;if("object"===typeof Reflect&&"function"===typeof Reflect.decorate)l=Reflect.decorate(b,e,m,d);else for(var a=b.length-1;0<=a;a--)if(h=b[a])l=(3>k?h(l):3<k?h(e,m,l):h(e,m))||l;return 3<k&&l&&Object.defineProperty(e,m,l),l}})},"esri/Basemap":function(){define("require exports ./core/tsSupport/assignHelper ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./core/asyncUtils ./core/collectionUtils ./core/compilerUtils ./core/Evented ./core/JSONSupport ./core/lang ./core/Loadable ./core/loadAll ./core/Logger ./core/promiseUtils ./core/urlUtils ./core/accessorSupport/decorators ./layers/support/LayerCollection ./portal/Portal ./portal/PortalItem ./support/basemapDefinitions".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x){var w=0,A=p.getLogger("esri.Basemap");return function(c){function f(a){var f=c.call(this)||this;f.id=null;f.portalItem=null;f.thumbnailUrl=null;f.title="Basemap";f.id=Date.now().toString(16)+"-basemap-"+w++;f.baseLayers=new u.default;f.referenceLayers=new u.default;var g=function(a){a.parent&&a.parent!==f&&"remove"in a.parent&&a.parent.remove(a);a.parent=f;"elevation"===a.type&&A.error("Layer '"+a.title+", id:"+a.id+"' of type '"+a.type+"' is not supported as a basemap layer and will therefore be ignored.")};
f.baseLayers.on("after-add",function(a){return g(a.item)});f.referenceLayers.on("after-add",function(a){return g(a.item)});f.baseLayers.on("after-remove",function(a){a.item.parent=null});f.referenceLayers.on("after-remove",function(a){a.item.parent=null});return f}d(f,c);g=f;f.prototype.initialize=function(){var a=this;this.when().catch(function(c){A.error("#load()","Failed to load basemap (title: '"+a.title+"', id: '"+a.id+"')",c)});this.resourceInfo&&this.read(this.resourceInfo.data,this.resourceInfo.context)};
f.prototype.normalizeCtorArgs=function(a){a&&"resourceInfo"in a&&(this._set("resourceInfo",a.resourceInfo),a=m({},a),delete a.resourceInfo);return a};Object.defineProperty(f.prototype,"baseLayers",{set:function(a){this._set("baseLayers",h.referenceSetter(a,this._get("baseLayers"),u.default))},enumerable:!0,configurable:!0});f.prototype.writeBaseLayers=function(c,f,g,d){var n=[];c&&(d=m({},d,{layerContainerType:"basemap"}),this.baseLayers.forEach(function(c){if("write"in c){var f={};a.typeCast(c)().write(f,
d)&&n.push(f)}}),this.referenceLayers.forEach(function(a){if("write"in a&&a.write){var c={isReference:!0};a.write(c,d)&&n.push(c)}}));f[g]=n};Object.defineProperty(f.prototype,"referenceLayers",{set:function(a){this._set("referenceLayers",h.referenceSetter(a,this._get("referenceLayers"),u.default))},enumerable:!0,configurable:!0});f.prototype.writeTitle=function(a,c){c.title=a||"Basemap"};f.prototype.load=function(){this.addResolvingPromise(this._loadFromSource());return this.when()};f.prototype.loadAll=
function(){var a=this;return l.safeCast(q.loadAll(this,function(c){c(a.baseLayers,a.referenceLayers)}))};f.prototype.clone=function(){var a={id:this.id,title:this.title,portalItem:this.portalItem,baseLayers:this.baseLayers.slice(),referenceLayers:this.referenceLayers.slice()};this.loaded&&(a.loadStatus="loaded");return(new g({resourceInfo:this.resourceInfo})).set(a)};f.prototype.read=function(a,c){this.resourceInfo||this._set("resourceInfo",{data:a,context:c});this.inherited(arguments)};f.prototype.write=
function(a,c){a=a||{};c&&c.origin||(c=m({origin:"web-map"},c));this.inherited(arguments,[a,c]);!this.loaded&&this.resourceInfo&&this.resourceInfo.data.baseMapLayers&&(a.baseMapLayers=this.resourceInfo.data.baseMapLayers.map(function(a){a=n.clone(a);a.url&&r.isProtocolRelative(a.url)&&(a.url="https:"+a.url);a.templateUrl&&r.isProtocolRelative(a.templateUrl)&&(a.templateUrl="https:"+a.templateUrl);return a}));return a};f.prototype._loadFromSource=function(){var a=this.resourceInfo,c=this.portalItem;
return a?this._loadLayersFromJSON(a.data,a.context?a.context.url:null):c?this._loadFromItem(c):t.resolve(null)};f.prototype._loadLayersFromJSON=function(a,c){var f=this,g=this.resourceInfo&&this.resourceInfo.context,d=this.portalItem&&this.portalItem.portal||g&&g.portal||null,n=g&&"web-scene"===g.origin?"web-scene":"web-map";return t.create(function(a){return b(["./portal/support/layersCreator"],a)}).then(function(g){var p=[];if(a.baseMapLayers&&Array.isArray(a.baseMapLayers)){var h={context:{origin:n,
url:c,portal:d,layerContainerType:"basemap"},defaultLayerType:"DefaultTileLayer"},b=g.populateOperationalLayers(f.baseLayers,a.baseMapLayers.filter(function(a){return!a.isReference}),h);p.push(l.safeCast(b));g=g.populateOperationalLayers(f.referenceLayers,a.baseMapLayers.filter(function(a){return a.isReference}),h);p.push(l.safeCast(g))}return t.eachAlways(p)}).then(function(){})};f.prototype._loadFromItem=function(a){var c=this;return a.load().then(function(a){return a.fetchData()}).then(function(f){var g=
r.urlToObject(a.itemUrl);c._set("resourceInfo",{data:f.baseMap,context:{origin:"web-map",portal:a.portal||z.getDefault(),url:g}});c.read(c.resourceInfo.data,c.resourceInfo.context);c.read({title:a.title,thumbnailUrl:a.thumbnailUrl},{origin:"portal-item",portal:a.portal||z.getDefault(),url:g});return c._loadLayersFromJSON(c.resourceInfo.data,g)})};f.fromId=function(a){return(a=x[a])?g.fromJSON(a):null};var g;k([v.property({type:u.default,json:{write:{ignoreOrigin:!0,target:"baseMapLayers"}}}),v.cast(h.castForReferenceSetter)],
f.prototype,"baseLayers",null);k([v.writer("baseLayers")],f.prototype,"writeBaseLayers",null);k([v.property({type:String,json:{origins:{"web-scene":{write:!0}}}})],f.prototype,"id",void 0);k([v.property({type:y})],f.prototype,"portalItem",void 0);k([v.property({type:u.default}),v.cast(h.castForReferenceSetter)],f.prototype,"referenceLayers",null);k([v.property({readOnly:!0})],f.prototype,"resourceInfo",void 0);k([v.property()],f.prototype,"thumbnailUrl",void 0);k([v.property({type:String,json:{origins:{"web-scene":{write:{isRequired:!0}}}}})],
f.prototype,"title",void 0);k([v.writer("title")],f.prototype,"writeTitle",null);return f=g=k([v.subclass("esri.Basemap")],f)}(v.declared(f,c,g))})},"esri/core/tsSupport/assignHelper":function(){define([],function(){return Object.assign||function(b){for(var e,m=1,d=arguments.length;m<d;m++){e=arguments[m];for(var k in e)Object.prototype.hasOwnProperty.call(e,k)&&(b[k]=e[k])}return b}})},"esri/core/asyncUtils":function(){define(["require","exports","./tsSupport/generatorHelper","./tsSupport/awaiterHelper",
"./promiseUtils"],function(b,e,m,d,k){Object.defineProperty(e,"__esModule",{value:!0});e.forEach=function(d,h,a){return k.eachAlways(d.map(function(c,f){return h.apply(a,[c,f])}))};e.map=function(d,h,a){return k.eachAlways(d.map(function(c,f){return h.apply(a,[c,f])})).then(function(a){return a.map(function(a){return a.value})})};e.result=function(d){return d.then(function(d){return{ok:!0,value:d}}).catch(function(d){return{ok:!1,error:d}})};e.assertResult=function(d){if(!0===d.ok)return d.value;
throw d.error;};e.safeCast=function(d){return d}})},"esri/core/tsSupport/generatorHelper":function(){define([],function(){return function(b,e){function m(a){return function(c){return d([a,c])}}function d(c){if(l)throw new TypeError("Generator is already executing.");for(;k;)try{if(l=1,h&&(a=c[0]&2?h["return"]:c[0]?h["throw"]||((a=h["return"])&&a.call(h),0):h.next)&&!(a=a.call(h,c[1])).done)return a;if(h=0,a)c=[c[0]&2,a.value];switch(c[0]){case 0:case 1:a=c;break;case 4:return k.label++,{value:c[1],
done:!1};case 5:k.label++;h=c[1];c=[0];continue;case 7:c=k.ops.pop();k.trys.pop();continue;default:if(!(a=k.trys,a=0<a.length&&a[a.length-1])&&(6===c[0]||2===c[0])){k=0;continue}if(3===c[0]&&(!a||c[1]>a[0]&&c[1]<a[3]))k.label=c[1];else if(6===c[0]&&k.label<a[1])k.label=a[1],a=c;else if(a&&k.label<a[2])k.label=a[2],k.ops.push(c);else{a[2]&&k.ops.pop();k.trys.pop();continue}}c=e.call(b,k)}catch(n){c=[6,n],h=0}finally{l=a=0}if(c[0]&5)throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}var k={label:0,sent:function(){if(a[0]&
1)throw a[1];return a[1]},trys:[],ops:[]},l,h,a,c;return c={next:m(0),"throw":m(1),"return":m(2)},"function"===typeof Symbol&&(c[Symbol.iterator]=function(){return this}),c}})},"esri/core/tsSupport/awaiterHelper":function(){define(["../promiseUtils"],function(b){return function(e,m,d,k){var l=null;return b.create(function(d,a){function c(c){try{n(k.next(c))}catch(q){a(q)}}function f(c){try{n(k["throw"](c))}catch(q){a(q)}}function n(g){g.done?(l=b.when(g.value),l.then(d,a)):(l=b.when(g.value),l.then(c,
f))}n((k=k.apply(e,m||[])).next())},function(d){l&&l.cancel(d)})}})},"esri/core/promiseUtils":function(){define(["require","exports","dojo/Deferred","dojo/promise/all","./Error"],function(b,e,m,d,k){function l(a,d){var f=new m(d);try{a(function(a){return c(a).then(f.resolve)},f.reject)}catch(q){f.reject(q)}return f.promise}function h(c){if(c){if("function"!==typeof c.forEach){var f=Object.keys(c),g=f.map(function(a){return c[a]});return h(g).then(function(a){var c={};f.forEach(function(f,g){return c[f]=
a[g]});return c})}var d=null,p=a;return l(function(a,f){var g=[],n=c.length;0===n&&a(g);c.forEach(function(c){var h={promise:c||p(c)};g.push(h);h.promise.then(function(a){h.value=a}).catch(function(a){h.error=a}).then(function(){--n;0===n&&(d?f(new k("AbortError",d)):a(g))})})},function(a){d=a||"Invocation cancellation";c.forEach(function(c){return c.cancel(a)})})}}function a(a){void 0===a&&(a=void 0);var c=new m;c.resolve(a);return c.promise}function c(c){return c&&"object"===typeof c&&"then"in c&&
"function"===typeof c.then?c:a(c)}Object.defineProperty(e,"__esModule",{value:!0});e.all=function(a){return d(a)};e.filter=function(a,c){var f=a.slice();return d(a.map(function(a,f){return c(a,f)})).then(function(a){return f.filter(function(c,f){return a[f]})})};e.create=l;e.createDeferred=function(a){var c=null;a=l(function(a,f){c={resolve:a,reject:f}},a);c.promise=a;c.cancel=function(){var a=new k("AbortError","AbortError");a.dojoType="cancel";c.reject(a)};return c};e.eachAlways=h;e.eachAlwaysValues=
function(a){return h(a).then(function(a){return a.filter(function(a){return!!a.value}).map(function(a){return a.value})})};e.first=function(c){return c&&c.length?l(function(a,f){for(var g=0;g<c.length;g++)c[g].then(a,f)}):a()};e.reject=function(a){var c=new m;c.reject(a);return c.promise};e.resolve=a;e.after=function(a,c){void 0===c&&(c=void 0);var f=0;return l(function(g){f=setTimeout(function(){g(c)},a)},function(){f&&(clearTimeout(f),f=0)})};e.timeout=function(a,c,g){var f=0,d=new m(a.cancel);
a.then(function(a){d.isFulfilled()||(d.resolve(a),f&&(clearTimeout(f),f=0))});a.catch(function(a){d.isFulfilled()||(d.reject(a),f&&(clearTimeout(f),f=0))});f=setTimeout(function(){var a=g||new k("promiseUtils:timeout","The wrapped promise did not resolve within "+c+" ms");d.reject(a)},c);return d.promise};e.wrapCallback=function(c){var f=!1;return l(function(){c(function(c){f||a(c)})},function(){return f=!0})};e.isThenable=function(a){return a&&"function"===typeof a.then};e.when=c;e.createResolver=
function(a){var c,f;a=l(function(a,g){c=a;f=g},a);var d=function(a){c(a)};d.resolve=function(a){return c(a)};d.reject=function(a){return f(a)};d.promise=a;return d}})},"dojo/promise/all":function(){define(["../_base/array","../_base/lang","../Deferred","../when"],function(b,e,m,d){var k=b.some;return function(b){var h,a;e.isArray(b)?a=b:b&&"object"===typeof b&&(h=b);var c,f=[];if(h){a=[];for(var n in h)Object.hasOwnProperty.call(h,n)&&(f.push(n),a.push(h[n]));c={}}else a&&(c=[]);if(!a||!a.length)return(new m).resolve(c);
var g=new m;g.promise.always(function(){c=f=null});var q=a.length;k(a,function(a,n){h||f.push(n);d(a,function(a){g.isFulfilled()||(c[f[n]]=a,0===--q&&g.resolve(c))},g.reject);return g.isFulfilled()});return g.promise}})},"esri/core/Error":function(){define(["require","exports","./tsSupport/extendsHelper","./lang","./Message"],function(b,e,m,d,k){b=function(b){function h(a,c,f){var d=b.call(this,a,c,f)||this;return d instanceof h?d:new h(a,c,f)}m(h,b);h.prototype.toJSON=function(){return{name:this.name,
message:this.message,details:d.clone(this.details),dojoType:this.dojoType}};h.fromJSON=function(a){var c=new h(a.name,a.message,a.details);null!=a.dojoType&&(c.dojoType=a.dojoType);return c};return h}(k);b.prototype.type="error";return b})},"esri/core/tsSupport/extendsHelper":function(){define([],function(){return function(){var b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,m){b.__proto__=m}||function(b,m){for(var d in m)m.hasOwnProperty(d)&&(b[d]=m[d])};return function(e,m){function d(){this.constructor=
e}b(e,m);e.prototype=null===m?Object.create(m):(d.prototype=m.prototype,new d)}}()})},"esri/core/lang":function(){define("require exports dojo/date dojo/i18n!../nls/common dojo/number dojo/date/locale ./global ./typedArrayUtil @dojo/framework/shim/string".split(" "),function(b,e,m,d,k,l,h,a,c){function f(a,c){var g;if(c)for(g in a)a.hasOwnProperty(g)&&(void 0===a[g]?delete a[g]:a[g]instanceof Object&&f(a[g],!0));else for(g in a)a.hasOwnProperty(g)&&void 0===a[g]&&delete a[g];return a}function n(c){return c&&
"object"===typeof c&&"function"!==typeof c?a.isInt8Array(c)||a.isUint8Array(c)||a.isUint8ClampedArray(c)||a.isInt16Array(c)||a.isUint16Array(c)||a.isInt32Array(c)||a.isUint32Array(c)||a.isFloat32Array(c)||a.isFloat64Array(c)?a.slice(c):c instanceof Date?new Date(c.getTime()):c instanceof ArrayBuffer?c.slice(0,c.byteLength):"function"===typeof c.clone?c.clone():"function"===typeof c.map&&"function"===typeof c.forEach?c.map(n):"function"===typeof c.notifyChange&&"function"===typeof c.watch?c.clone():
p({},c,n):c}function g(a){void 0===a&&(a={});for(var c=1;c<arguments.length;c++);for(var c=1,f=arguments.length;c<f;c++)p(a,arguments[c]);return a}function q(a){var c=a.key,f=a.data,g=a.dateFormat,d=a.nbrFormat;a=c.split(":");if(1<a.length)return c=a[0],a.shift(),t(c,f,a.join(":"));if(g&&-1!==(g.properties||[]).indexOf(c))return t(c,f,g.formatter||"DateString");if(d&&-1!==(d.properties||[]).indexOf(c))return t(c,f,d.formatter||"NumberFormat");f=f[c];return null!=f?f:""}function p(a,c,f){var g,d,n=
{};for(g in c){d=c[g];var p=!(g in n)||n[g]!==d;if(!(g in a)||a[g]!==d&&p)a[g]=f?f(d):d}return a}function t(a,c,f){var d=f.match(z),n=d[1].trim();f=c[a];var d=JSON.parse((d[2]?d[2].trim():"{}").replace(y,"{").replace(x,"}").replace(w,'$1"$2":').replace(A,'":"').replace(B,'"$1')),p=d.utcOffset;if(-1===r.indexOf(n)){var b;a:{n=n.split(".");p=void 0;p=h;try{for(var e=0;e<n.length;e++){var q=n[e];if(!(q in p)){b=void 0;break a}p=p[q]}b=p;break a}catch(U){}b=void 0}"function"===typeof b&&(f=b(f,a,c,d))}else if("number"===
typeof f||"string"===typeof f&&f&&!isNaN(Number(f)))switch(f=Number(f),n){case "NumberFormat":a=g({},d);c="string"===typeof a.places?parseFloat(a.places):a.places;if(isNaN(c)||0>c)a.places=Infinity;return k.format(f,a);case "DateString":f=new Date(f);if(d.local||d.systemLocale)return d.systemLocale?f.toLocaleDateString()+(d.hideTime?"":" "+f.toLocaleTimeString()):f.toDateString()+(d.hideTime?"":" "+f.toTimeString());f=f.toUTCString();d.hideTime&&(f=f.replace(F,""));return f;case "DateFormat":return f=
new Date(f),null!=p&&(f=m.add(f,"minute",f.getTimezoneOffset()-p)),l.format(f,d)}return null!=f?f:""}Object.defineProperty(e,"__esModule",{value:!0});var r=["NumberFormat","DateString","DateFormat"],v=/<\/?[^>]+>/g,u=/\{([^\}]+)\}/g,z=/([^\(]+)(\([^\)]+\))?/i,y=/^\(/,x=/\)$/,w=/([{,])\s*([0-9a-zA-Z\_]+)\s*:/gi,A=/\"\s*:\s*\'/gi,B=/\'\s*(,|\})/gi,F=/\s+\d\d\:\d\d\:\d\d\s+(utc|gmt)/i;e.startsWith=c.startsWith;e.endsWith=c.endsWith;e.fixJson=f;e.clone=n;e.equals=function(a,c){return a===c||"number"===
typeof a&&isNaN(a)&&"number"===typeof c&&isNaN(c)||"function"===typeof(a||{}).getTime&&"function"===typeof(c||{}).getTime&&a.getTime()===c.getTime()||!1};e.mixin=g;e.valueOf=function(a,c){for(var f in a)if(a[f]===c)return f;return null};e.stripTags=function(a){if(a){var c=typeof a;if("string"===c)a=a.replace(v,"");else if("object"===c)for(c in c=void 0,a){var f=a[c];f&&"string"===typeof f&&(f=f.replace(v,""));a[c]=f}}return a};e.substitute=function(a,c,f){var g,n,p;null!=f&&("object"===typeof f?(g=
f.first,n=f.dateFormat,p=f.numberFormat):g=f);if(!c||"{*}"===c){c=['\x3ctable class\x3d"esri-widget__table" summary\x3d"'+d.fieldsSummary+'"\x3e\x3ctbody\x3e'];var b=f=void 0;for(b in a)if(f=a[b],n&&-1!==(n.properties||[]).indexOf(b)?f=t(b,a,n.formatter||"DateString"):p&&-1!==(p.properties||[]).indexOf(b)&&(f=t(b,a,p.formatter||"NumberFormat")),c.push("\x3ctr\x3e\x3cth\x3e"+b+"\x3c/th\x3e\x3ctd\x3e"+(null!=f?f:"")+"\x3c/td\x3e\x3c/tr\x3e"),g)break;c.push("\x3c/tbody\x3e\x3c/table\x3e");return c.join("")}return c.replace(u,
function(c,f){return q({key:f,data:a,dateFormat:n,nbrFormat:p})})};e.filter=function(a,c,f){c=["string"===typeof a?a.split(""):a,f||h,"string"===typeof c?new Function("item","index","array",c):c];f={};var g;a=c[0];for(g in a)c[2].call(c[g],a[g],g,a)&&(f[g]=a[g]);return f}})},"dojo/date":function(){define(["./has","./_base/lang"],function(b,e){var m={getDaysInMonth:function(d){var b=d.getMonth();return 1==b&&m.isLeapYear(d)?29:[31,28,31,30,31,30,31,31,30,31,30,31][b]},isLeapYear:function(d){d=d.getFullYear();
return!(d%400)||!(d%4)&&!!(d%100)},getTimezoneName:function(d){var b=d.toString(),e="",h=b.indexOf("(");if(-1<h)e=b.substring(++h,b.indexOf(")"));else if(h=/([A-Z\/]+) \d{4}$/,b=b.match(h))e=b[1];else if(b=d.toLocaleString(),h=/ ([A-Z\/]+)$/,b=b.match(h))e=b[1];return"AM"==e||"PM"==e?"":e},compare:function(d,b,e){d=new Date(+d);b=new Date(+(b||new Date));"date"==e?(d.setHours(0,0,0,0),b.setHours(0,0,0,0)):"time"==e&&(d.setFullYear(0,0,0),b.setFullYear(0,0,0));return d>b?1:d<b?-1:0},add:function(d,
b,e){var h=new Date(+d),a=!1,c="Date";switch(b){case "day":break;case "weekday":var f;(b=e%5)?f=parseInt(e/5):(b=0<e?5:-5,f=0<e?(e-5)/5:(e+5)/5);var n=d.getDay(),g=0;6==n&&0<e?g=1:0==n&&0>e&&(g=-1);n+=b;if(0==n||6==n)g=0<e?2:-2;e=7*f+b+g;break;case "year":c="FullYear";a=!0;break;case "week":e*=7;break;case "quarter":e*=3;case "month":a=!0;c="Month";break;default:c="UTC"+b.charAt(0).toUpperCase()+b.substring(1)+"s"}if(c)h["set"+c](h["get"+c]()+e);a&&h.getDate()<d.getDate()&&h.setDate(0);return h},
difference:function(d,b,e){b=b||new Date;e=e||"day";var h=b.getFullYear()-d.getFullYear(),a=1;switch(e){case "quarter":d=d.getMonth();b=b.getMonth();a=Math.floor(b/3)+1+4*h-(Math.floor(d/3)+1);break;case "weekday":h=Math.round(m.difference(d,b,"day"));e=parseInt(m.difference(d,b,"week"));if(0==h%7)h=5*e;else{var a=0,c=d.getDay(),f=b.getDay();e=parseInt(h/7);b=h%7;d=new Date(d);d.setDate(d.getDate()+7*e);d=d.getDay();if(0<h)switch(!0){case 6==c:a=-1;break;case 0==c:a=0;break;case 6==f:a=-1;break;case 0==
f:a=-2;break;case 5<d+b:a=-2}else if(0>h)switch(!0){case 6==c:a=0;break;case 0==c:a=1;break;case 6==f:a=2;break;case 0==f:a=1;break;case 0>d+b:a=2}h=h+a-2*e}a=h;break;case "year":a=h;break;case "month":a=b.getMonth()-d.getMonth()+12*h;break;case "week":a=parseInt(m.difference(d,b,"day")/7);break;case "day":a/=24;case "hour":a/=60;case "minute":a/=60;case "second":a/=1E3;case "millisecond":a*=b.getTime()-d.getTime()}return Math.round(a)}};e.mixin(e.getObject("dojo.date",!0),m);return m})},"dojo/i18n":function(){define("./_base/kernel require ./has ./_base/array ./_base/config ./_base/lang ./has!host-browser?./_base/xhr ./json module".split(" "),
function(b,e,m,d,k,l,h,a,c){m.add("dojo-preload-i18n-Api",1);h=b.i18n={};var f=/(^.*(^|\/)nls)(\/|$)([^\/]*)\/?([^\/]*)/,n=function(a,c,f,g){var d=[f+g];c=c.split("-");for(var n="",b=0;b<c.length;b++)if(n+=(n?"-":"")+c[b],!a||a[n])d.push(f+n+"/"+g),d.specificity=n;return d},g={},q=function(a,c,f){f=f?f.toLowerCase():b.locale;a=a.replace(/\./g,"/");c=c.replace(/\./g,"/");return/root/i.test(f)?a+"/nls/"+c:a+"/nls/"+f+"/"+c},p=b.getL10nName=function(a,f,g){return a=c.id+"!"+q(a,f,g)},t=function(a,c,
f,d,b,p){a([c],function(h){var e=l.clone(h.root||h.ROOT),q=n(!h._v1x&&h,b,f,d);a(q,function(){for(var a=1;a<q.length;a++)e=l.mixin(l.clone(e),arguments[a]);g[c+"/"+b]=e;e.$locale=q.specificity;p()})})},r=function(a){var c=k.extraLocale||[],c=l.isArray(c)?c:[c];c.push(a);return c},v=function(c,n,p){var h=f.exec(c),e=h[1]+"/",q=h[5]||h[4],k=e+q,v=(h=h[5]&&h[4])||b.locale||"",u=k+"/"+v,h=h?[v]:r(v),B=h.length,C=function(){--B||p(l.delegate(g[u]))},v=c.split("*"),A="preload"==v[1];if(m("dojo-preload-i18n-Api")){if(A&&
(g[c]||(g[c]=1,x(v[2],a.parse(v[3]),1,n)),p(1)),(v=A)||(z&&y.push([c,n,p]),v=z&&!g[u]),v)return}else if(A){p(1);return}d.forEach(h,function(a){var c=k+"/"+a;m("dojo-preload-i18n-Api")&&w(c);g[c]?C():t(n,k,e,q,a,C)})};m("dojo-preload-i18n-Api");var u=h.normalizeLocale=function(a){a=a?a.toLowerCase():b.locale;return"root"==a?"ROOT":a},z=0,y=[],x=h._preloadLocalizations=function(a,c,f,n){function p(a,c){n([a],c)}function h(a,c){for(a=a.split("-");a.length;){if(c(a.join("-")))return;a.pop()}c("ROOT")}
function q(){for(--z;!z&&y.length;)v.apply(null,y.shift())}function t(f){f=u(f);h(f,function(b){if(0<=d.indexOf(c,b)){var t=a.replace(/\./g,"/")+"_"+b;z++;p(t,function(a){for(var c in a){var d=a[c],p=c.match(/(.+)\/([^\/]+)$/),t;if(p&&(t=p[2],p=p[1]+"/",d._localized)){var r;if("ROOT"===b){var k=r=d._localized;delete d._localized;k.root=d;g[e.toAbsMid(c)]=k}else r=d._localized,g[e.toAbsMid(p+t+"/"+b)]=d;b!==f&&function(a,c,d,b){var p=[],t=[];h(f,function(f){b[f]&&(p.push(e.toAbsMid(a+f+"/"+c)),t.push(e.toAbsMid(a+
c+"/"+f)))});p.length?(z++,n(p,function(){for(var n=p.length-1;0<=n;n--)d=l.mixin(l.clone(d),arguments[n]),g[t[n]]=d;g[e.toAbsMid(a+c+"/"+f)]=l.clone(d);q()})):g[e.toAbsMid(a+c+"/"+f)]=d}(p,t,d,r)}}q()});return!0}return!1})}n=n||e;t();d.forEach(b.config.extraLocale,t)},w=function(){},A={},w=function(a){for(var c,f=a.split("/"),d=b.global[f[0]],n=1;d&&n<f.length-1;d=d[f[n++]]);d&&((c=d[f[n]])||(c=d[f[n].replace(/-/g,"_")]),c&&(g[a]=c));return c};h.getLocalization=function(a,c,f){var g,d=q(a,c,f);if(A[d])return A[d];
v(d,e,function(a){g=A[d]=a});return g};return l.mixin(h,{dynamic:!0,normalize:function(a,c){return/^\./.test(a)?c(a):a},load:v,cache:g,getL10nName:p})})},"dojo/number":function(){define(["./_base/lang","./i18n","./i18n!./cldr/nls/number","./string","./regexp"],function(b,e,m,d,k){var l={};b.setObject("dojo.number",l);l.format=function(a,c){c=b.mixin({},c||{});var f=e.normalizeLocale(c.locale),f=e.getLocalization("dojo.cldr","number",f);c.customs=f;f=c.pattern||f[(c.type||"decimal")+"Format"];return isNaN(a)||
Infinity==Math.abs(a)?null:l._applyPattern(a,f,c)};l._numberPatternRE=/[#0,]*[#0](?:\.0*#*)?/;l._applyPattern=function(a,c,f){f=f||{};var d=f.customs.group,g=f.customs.decimal;c=c.split(";");var b=c[0];c=c[0>a?1:0]||"-"+b;if(-1!=c.indexOf("%"))a*=100;else if(-1!=c.indexOf("\u2030"))a*=1E3;else if(-1!=c.indexOf("\u00a4"))d=f.customs.currencyGroup||d,g=f.customs.currencyDecimal||g,c=c.replace(/([\s\xa0]*)(\u00a4{1,3})([\s\xa0]*)/,function(a,c,g,d){return(a=f[["symbol","currency","displayName"][g.length-
1]]||f.currency||"")?c+a+d:""});else if(-1!=c.indexOf("E"))throw Error("exponential notation not supported");var p=l._numberPatternRE,b=b.match(p);if(!b)throw Error("unable to find a number expression in pattern: "+c);!1===f.fractional&&(f.places=0);return c.replace(p,l._formatAbsolute(a,b[0],{decimal:g,group:d,places:f.places,round:f.round}))};l.round=function(a,c,f){f=10/(f||10);return(f*+a).toFixed(c)/f};if(0==(.9).toFixed()){var h=l.round;l.round=function(a,c,f){var d=Math.pow(10,-c||0),g=Math.abs(a);
if(!a||g>=d)d=0;else if(g/=d,.5>g||.95<=g)d=0;return h(a,c,f)+(0<a?d:-d)}}l._formatAbsolute=function(a,c,f){f=f||{};!0===f.places&&(f.places=0);Infinity===f.places&&(f.places=6);c=c.split(".");var n="string"==typeof f.places&&f.places.indexOf(","),g=f.places;n?g=f.places.substring(n+1):0<=g||(g=(c[1]||[]).length);0>f.round||(a=l.round(a,g,f.round));a=String(Math.abs(a)).split(".");var b=a[1]||"";c[1]||f.places?(n&&(f.places=f.places.substring(0,n)),n=void 0!==f.places?f.places:c[1]&&c[1].lastIndexOf("0")+
1,n>b.length&&(a[1]=d.pad(b,n,"0",!0)),g<b.length&&(a[1]=b.substr(0,g))):a[1]&&a.pop();g=c[0].replace(",","");n=g.indexOf("0");-1!=n&&(n=g.length-n,n>a[0].length&&(a[0]=d.pad(a[0],n)),-1==g.indexOf("#")&&(a[0]=a[0].substr(a[0].length-n)));var g=c[0].lastIndexOf(","),p,h;-1!=g&&(p=c[0].length-g-1,c=c[0].substr(0,g),g=c.lastIndexOf(","),-1!=g&&(h=c.length-g-1));c=[];for(g=a[0];g;)n=g.length-p,c.push(0<n?g.substr(n):g),g=0<n?g.slice(0,n):"",h&&(p=h,h=void 0);a[0]=c.reverse().join(f.group||",");return a.join(f.decimal||
".")};l.regexp=function(a){return l._parseInfo(a).regexp};l._parseInfo=function(a){a=a||{};var c=e.normalizeLocale(a.locale),c=e.getLocalization("dojo.cldr","number",c),f=a.pattern||c[(a.type||"decimal")+"Format"],d=c.group,g=c.decimal,b=1;if(-1!=f.indexOf("%"))b/=100;else if(-1!=f.indexOf("\u2030"))b/=1E3;else{var p=-1!=f.indexOf("\u00a4");p&&(d=c.currencyGroup||d,g=c.currencyDecimal||g)}c=f.split(";");1==c.length&&c.push("-"+c[0]);c=k.buildGroupRE(c,function(c){c="(?:"+k.escapeString(c,".")+")";
return c.replace(l._numberPatternRE,function(c){var f={signed:!1,separator:a.strict?d:[d,""],fractional:a.fractional,decimal:g,exponent:!1};c=c.split(".");var n=a.places;1==c.length&&1!=b&&(c[1]="###");1==c.length||0===n?f.fractional=!1:(void 0===n&&(n=a.pattern?c[1].lastIndexOf("0")+1:Infinity),n&&void 0==a.fractional&&(f.fractional=!0),!a.places&&n<c[1].length&&(n+=","+c[1].length),f.places=n);c=c[0].split(",");1<c.length&&(f.groupSize=c.pop().length,1<c.length&&(f.groupSize2=c.pop().length));return"("+
l._realNumberRegexp(f)+")"})},!0);p&&(c=c.replace(/([\s\xa0]*)(\u00a4{1,3})([\s\xa0]*)/g,function(c,f,g,d){c=k.escapeString(a[["symbol","currency","displayName"][g.length-1]]||a.currency||"");if(!c)return"";f=f?"[\\s\\xa0]":"";d=d?"[\\s\\xa0]":"";return a.strict?f+c+d:(f&&(f+="*"),d&&(d+="*"),"(?:"+f+c+d+")?")}));return{regexp:c.replace(/[\xa0 ]/g,"[\\s\\xa0]"),group:d,decimal:g,factor:b}};l.parse=function(a,c){c=l._parseInfo(c);a=(new RegExp("^"+c.regexp+"$")).exec(a);if(!a)return NaN;var f=a[1];
if(!a[1]){if(!a[2])return NaN;f=a[2];c.factor*=-1}f=f.replace(new RegExp("["+c.group+"\\s\\xa0]","g"),"").replace(c.decimal,".");return f*c.factor};l._realNumberRegexp=function(a){a=a||{};"places"in a||(a.places=Infinity);"string"!=typeof a.decimal&&(a.decimal=".");"fractional"in a&&!/^0/.test(a.places)||(a.fractional=[!0,!1]);"exponent"in a||(a.exponent=[!0,!1]);"eSigned"in a||(a.eSigned=[!0,!1]);var c=l._integerRegexp(a),f=k.buildGroupRE(a.fractional,function(c){var f="";c&&0!==a.places&&(f="\\"+
a.decimal,f=Infinity==a.places?"(?:"+f+"\\d+)?":f+("\\d{"+a.places+"}"));return f},!0),d=k.buildGroupRE(a.exponent,function(c){return c?"([eE]"+l._integerRegexp({signed:a.eSigned})+")":""}),c=c+f;f&&(c="(?:(?:"+c+")|(?:"+f+"))");return c+d};l._integerRegexp=function(a){a=a||{};"signed"in a||(a.signed=[!0,!1]);"separator"in a?"groupSize"in a||(a.groupSize=3):a.separator="";var c=k.buildGroupRE(a.signed,function(a){return a?"[-+]":""},!0),f=k.buildGroupRE(a.separator,function(c){if(!c)return"(?:\\d+)";
c=k.escapeString(c);" "==c?c="\\s":"\u00a0"==c&&(c="\\s\\xa0");var f=a.groupSize,d=a.groupSize2;return d?(c="(?:0|[1-9]\\d{0,"+(d-1)+"}(?:["+c+"]\\d{"+d+"})*["+c+"]\\d{"+f+"})",0<f-d?"(?:"+c+"|(?:0|[1-9]\\d{0,"+(f-1)+"}))":c):"(?:0|[1-9]\\d{0,"+(f-1)+"}(?:["+c+"]\\d{"+f+"})*)"},!0);return c+f};return l})},"dojo/string":function(){define(["./_base/kernel","./_base/lang"],function(b,e){var m=/[&<>'"\/]/g,d={"\x26":"\x26amp;","\x3c":"\x26lt;","\x3e":"\x26gt;",'"':"\x26quot;","'":"\x26#x27;","/":"\x26#x2F;"},
k={};e.setObject("dojo.string",k);k.escape=function(b){return b?b.replace(m,function(b){return d[b]}):""};k.rep=function(d,b){if(0>=b||!d)return"";for(var a=[];;){b&1&&a.push(d);if(!(b>>=1))break;d+=d}return a.join("")};k.pad=function(d,b,a,c){a||(a="0");d=String(d);b=k.rep(a,Math.ceil((b-d.length)/a.length));return c?d+b:b+d};k.substitute=function(d,h,a,c){c=c||b.global;a=a?e.hitch(c,a):function(a){return a};return d.replace(/\$\{([^\s\:\}]*)(?:\:([^\s\:\}]+))?\}/g,function(f,d,g){if(""==d)return"$";
f=e.getObject(d,!1,h);g&&(f=e.getObject(g,!1,c).call(c,f,d));g=a(f,d);if("undefined"===typeof g)throw Error('string.substitute could not find key "'+d+'" in template');return g.toString()})};k.trim=String.prototype.trim?e.trim:function(d){d=d.replace(/^\s+/,"");for(var b=d.length-1;0<=b;b--)if(/\S/.test(d.charAt(b))){d=d.substring(0,b+1);break}return d};return k})},"dojo/regexp":function(){define(["./_base/kernel","./_base/lang"],function(b,e){var m={};e.setObject("dojo.regexp",m);m.escapeString=
function(d,b){return d.replace(/([\.$?*|{}\(\)\[\]\\\/\+\-^])/g,function(d){return b&&-1!=b.indexOf(d)?d:"\\"+d})};m.buildGroupRE=function(d,b,e){if(!(d instanceof Array))return b(d);for(var h=[],a=0;a<d.length;a++)h.push(b(d[a]));return m.group(h.join("|"),e)};m.group=function(d,b){return"("+(b?"?:":"")+d+")"};return m})},"dojo/date/locale":function(){define("../_base/lang ../_base/array ../date ../cldr/supplemental ../i18n ../regexp ../string ../i18n!../cldr/nls/gregorian module".split(" "),function(b,
e,m,d,k,l,h,a,c){function f(a,c,f,g){return g.replace(/([a-z])\1*/ig,function(b){var n,p,e=b.charAt(0);b=b.length;var t=["abbr","wide","narrow"];switch(e){case "G":n=c[4>b?"eraAbbr":"eraNames"][0>a.getFullYear()?0:1];break;case "y":n=a.getFullYear();switch(b){case 1:break;case 2:if(!f.fullYear){n=String(n);n=n.substr(n.length-2);break}default:p=!0}break;case "Q":case "q":n=Math.ceil((a.getMonth()+1)/3);p=!0;break;case "M":case "L":n=a.getMonth();3>b?(n+=1,p=!0):(e=["months","L"==e?"standAlone":"format",
t[b-3]].join("-"),n=c[e][n]);break;case "w":n=q._getWeekOfYear(a,0);p=!0;break;case "d":n=a.getDate();p=!0;break;case "D":n=q._getDayOfYear(a);p=!0;break;case "e":case "c":if(n=a.getDay(),2>b){n=(n-d.getFirstDayOfWeek(f.locale)+8)%7;break}case "E":n=a.getDay();3>b?(n+=1,p=!0):(e=["days","c"==e?"standAlone":"format",t[b-3]].join("-"),n=c[e][n]);break;case "a":e=12>a.getHours()?"am":"pm";n=f[e]||c["dayPeriods-format-wide-"+e];break;case "h":case "H":case "K":case "k":p=a.getHours();switch(e){case "h":n=
p%12||12;break;case "H":n=p;break;case "K":n=p%12;break;case "k":n=p||24}p=!0;break;case "m":n=a.getMinutes();p=!0;break;case "s":n=a.getSeconds();p=!0;break;case "S":n=Math.round(a.getMilliseconds()*Math.pow(10,b-3));p=!0;break;case "v":case "z":if(n=q._getZone(a,!0,f))break;b=4;case "Z":e=q._getZone(a,!1,f);e=[0>=e?"+":"-",h.pad(Math.floor(Math.abs(e)/60),2),h.pad(Math.abs(e)%60,2)];4==b&&(e.splice(0,0,"GMT"),e.splice(3,0,":"));n=e.join("");break;default:throw Error("dojo.date.locale.format: invalid pattern char: "+
g);}p&&(n=h.pad(n,b));return n})}function n(a,c,f,g){var d=function(a){return a};c=c||d;f=f||d;g=g||d;var b=a.match(/(''|[^'])+/g),n="'"==a.charAt(0);e.forEach(b,function(a,g){a?(b[g]=(n?f:c)(a.replace(/''/g,"'")),n=!n):b[g]=""});return g(b.join(""))}function g(a,c,f,g){g=l.escapeString(g);f.strict||(g=g.replace(" a"," ?a"));return g.replace(/([a-z])\1*/ig,function(g){var d;d=g.charAt(0);var b=g.length,n="",h="";f.strict?(1<b&&(n="0{"+(b-1)+"}"),2<b&&(h="0{"+(b-2)+"}")):(n="0?",h="0{0,2}");switch(d){case "y":d=
"\\d{2,4}";break;case "M":case "L":2<b?(d=c["months-"+("L"==d?"standAlone":"format")+"-"+p[b-3]].slice(0).join("|"),f.strict||(d=d.replace(/\./g,""),d="(?:"+d+")\\.?")):d="1[0-2]|"+n+"[1-9]";break;case "D":d="[12][0-9][0-9]|3[0-5][0-9]|36[0-6]|"+n+"[1-9][0-9]|"+h+"[1-9]";break;case "d":d="3[01]|[12]\\d|"+n+"[1-9]";break;case "w":d="[1-4][0-9]|5[0-3]|"+n+"[1-9]";break;case "E":case "e":case "c":d=".+?";break;case "h":d="1[0-2]|"+n+"[1-9]";break;case "k":d="1[01]|"+n+"\\d";break;case "H":d="1\\d|2[0-3]|"+
n+"\\d";break;case "K":d="1\\d|2[0-4]|"+n+"[1-9]";break;case "m":case "s":d="[0-5]\\d";break;case "S":d="\\d{"+b+"}";break;case "a":b=f.am||c["dayPeriods-format-wide-am"];n=f.pm||c["dayPeriods-format-wide-pm"];d=b+"|"+n;f.strict||(b!=b.toLowerCase()&&(d+="|"+b.toLowerCase()),n!=n.toLowerCase()&&(d+="|"+n.toLowerCase()),-1!=d.indexOf(".")&&(d+="|"+d.replace(/\./g,"")));d=d.replace(/\./g,"\\.");break;default:d=".*"}a&&a.push(g);return"("+d+")"}).replace(/[\xa0 ]/g,"[\\s\\xa0]")}var q={};b.setObject(c.id.replace(/\//g,
"."),q);q._getZone=function(a,c,f){return c?m.getTimezoneName(a):a.getTimezoneOffset()};q.format=function(a,c){c=c||{};var g=k.normalizeLocale(c.locale),d=c.formatLength||"short",g=q._getGregorianBundle(g),p=[];a=b.hitch(this,f,a,g,c);if("year"==c.selector)return n(g["dateFormatItem-yyyy"]||"yyyy",a);var h;"date"!=c.selector&&(h=c.timePattern||g["timeFormat-"+d])&&p.push(n(h,a));"time"!=c.selector&&(h=c.datePattern||g["dateFormat-"+d])&&p.push(n(h,a));return 1==p.length?p[0]:g["dateTimeFormat-"+d].replace(/\'/g,
"").replace(/\{(\d+)\}/g,function(a,c){return p[c]})};q.regexp=function(a){return q._parseInfo(a).regexp};q._parseInfo=function(a){a=a||{};var c=k.normalizeLocale(a.locale),c=q._getGregorianBundle(c),f=a.formatLength||"short",d=a.datePattern||c["dateFormat-"+f],p=a.timePattern||c["timeFormat-"+f],f="date"==a.selector?d:"time"==a.selector?p:c["dateTimeFormat-"+f].replace(/\{(\d+)\}/g,function(a,c){return[p,d][c]}),h=[];return{regexp:n(f,b.hitch(this,g,h,c,a)),tokens:h,bundle:c}};q.parse=function(a,
c){var f=/[\u200E\u200F\u202A\u202E]/g,g=q._parseInfo(c),d=g.tokens,b=g.bundle;a=(new RegExp("^"+g.regexp.replace(f,"")+"$",g.strict?"":"i")).exec(a&&a.replace(f,""));if(!a)return null;var n=["abbr","wide","narrow"],p=[1970,0,1,0,0,0,0],h="";a=e.every(a,function(a,f){if(!f)return!0;var g=d[f-1];f=g.length;g=g.charAt(0);switch(g){case "y":if(2!=f&&c.strict)p[0]=a;else if(100>a)a=Number(a),g=""+(new Date).getFullYear(),f=100*g.substring(0,2),g=Math.min(Number(g.substring(2,4))+20,99),p[0]=a<g?f+a:f-
100+a;else{if(c.strict)return!1;p[0]=a}break;case "M":case "L":if(2<f){if(f=b["months-"+("L"==g?"standAlone":"format")+"-"+n[f-3]].concat(),c.strict||(a=a.replace(".","").toLowerCase(),f=e.map(f,function(a){return a.replace(".","").toLowerCase()})),a=e.indexOf(f,a),-1==a)return!1}else a--;p[1]=a;break;case "E":case "e":case "c":f=b["days-"+("c"==g?"standAlone":"format")+"-"+n[f-3]].concat();c.strict||(a=a.toLowerCase(),f=e.map(f,function(a){return a.toLowerCase()}));a=e.indexOf(f,a);if(-1==a)return!1;
break;case "D":p[1]=0;case "d":p[2]=a;break;case "a":f=c.am||b["dayPeriods-format-wide-am"];g=c.pm||b["dayPeriods-format-wide-pm"];if(!c.strict){var t=/\./g;a=a.replace(t,"").toLowerCase();f=f.replace(t,"").toLowerCase();g=g.replace(t,"").toLowerCase()}if(c.strict&&a!=f&&a!=g)return!1;h=a==g?"p":a==f?"a":"";break;case "K":24==a&&(a=0);case "h":case "H":case "k":if(23<a)return!1;p[3]=a;break;case "m":p[4]=a;break;case "s":p[5]=a;break;case "S":p[6]=a}return!0});f=+p[3];"p"===h&&12>f?p[3]=f+12:"a"===
h&&12==f&&(p[3]=0);f=new Date(p[0],p[1],p[2],p[3],p[4],p[5],p[6]);c.strict&&f.setFullYear(p[0]);var t=d.join(""),g=-1!=t.indexOf("d"),t=-1!=t.indexOf("M");if(!a||t&&f.getMonth()>p[1]||g&&f.getDate()>p[2])return null;if(t&&f.getMonth()<p[1]||g&&f.getDate()<p[2])f=m.add(f,"hour",1);return f};var p=["abbr","wide","narrow"],t=[],r={};q.addCustomFormats=function(a,c){t.push({pkg:a,name:c});r={}};q._getGregorianBundle=function(a){if(r[a])return r[a];var c={};e.forEach(t,function(f){f=k.getLocalization(f.pkg,
f.name,a);c=b.mixin(c,f)},this);return r[a]=c};q.addCustomFormats(c.id.replace(/\/date\/locale$/,".cldr"),"gregorian");q.getNames=function(a,c,f,g){var d;g=q._getGregorianBundle(g);a=[a,f,c];"standAlone"==f&&(f=a.join("-"),d=g[f],1==d[0]&&(d=void 0));a[1]="format";return(d||g[a.join("-")]).concat()};q.isWeekend=function(a,c){c=d.getWeekend(c);a=(a||new Date).getDay();c.end<c.start&&(c.end+=7,a<c.start&&(a+=7));return a>=c.start&&a<=c.end};q._getDayOfYear=function(a){return m.difference(new Date(a.getFullYear(),
0,1,a.getHours()),a)+1};q._getWeekOfYear=function(a,c){1==arguments.length&&(c=0);var f=(new Date(a.getFullYear(),0,1)).getDay(),g=(f-c+7)%7,g=Math.floor((q._getDayOfYear(a)+g-1)/7);f==c&&g++;return g};return q})},"dojo/cldr/supplemental":function(){define(["../_base/lang","../i18n"],function(b,e){var m={};b.setObject("dojo.cldr.supplemental",m);m.getFirstDayOfWeek=function(d){d={bd:5,mv:5,ae:6,af:6,bh:6,dj:6,dz:6,eg:6,iq:6,ir:6,jo:6,kw:6,ly:6,ma:6,om:6,qa:6,sa:6,sd:6,sy:6,ye:6,ag:0,ar:0,as:0,au:0,
br:0,bs:0,bt:0,bw:0,by:0,bz:0,ca:0,cn:0,co:0,dm:0,"do":0,et:0,gt:0,gu:0,hk:0,hn:0,id:0,ie:0,il:0,"in":0,jm:0,jp:0,ke:0,kh:0,kr:0,la:0,mh:0,mm:0,mo:0,mt:0,mx:0,mz:0,ni:0,np:0,nz:0,pa:0,pe:0,ph:0,pk:0,pr:0,py:0,sg:0,sv:0,th:0,tn:0,tt:0,tw:0,um:0,us:0,ve:0,vi:0,ws:0,za:0,zw:0}[m._region(d)];return void 0===d?1:d};m._region=function(d){d=e.normalizeLocale(d);d=d.split("-");var b=d[1];b?4==b.length&&(b=d[2]):b={aa:"et",ab:"ge",af:"za",ak:"gh",am:"et",ar:"eg",as:"in",av:"ru",ay:"bo",az:"az",ba:"ru",be:"by",
bg:"bg",bi:"vu",bm:"ml",bn:"bd",bo:"cn",br:"fr",bs:"ba",ca:"es",ce:"ru",ch:"gu",co:"fr",cr:"ca",cs:"cz",cv:"ru",cy:"gb",da:"dk",de:"de",dv:"mv",dz:"bt",ee:"gh",el:"gr",en:"us",es:"es",et:"ee",eu:"es",fa:"ir",ff:"sn",fi:"fi",fj:"fj",fo:"fo",fr:"fr",fy:"nl",ga:"ie",gd:"gb",gl:"es",gn:"py",gu:"in",gv:"gb",ha:"ng",he:"il",hi:"in",ho:"pg",hr:"hr",ht:"ht",hu:"hu",hy:"am",ia:"fr",id:"id",ig:"ng",ii:"cn",ik:"us","in":"id",is:"is",it:"it",iu:"ca",iw:"il",ja:"jp",ji:"ua",jv:"id",jw:"id",ka:"ge",kg:"cd",ki:"ke",
kj:"na",kk:"kz",kl:"gl",km:"kh",kn:"in",ko:"kr",ks:"in",ku:"tr",kv:"ru",kw:"gb",ky:"kg",la:"va",lb:"lu",lg:"ug",li:"nl",ln:"cd",lo:"la",lt:"lt",lu:"cd",lv:"lv",mg:"mg",mh:"mh",mi:"nz",mk:"mk",ml:"in",mn:"mn",mo:"ro",mr:"in",ms:"my",mt:"mt",my:"mm",na:"nr",nb:"no",nd:"zw",ne:"np",ng:"na",nl:"nl",nn:"no",no:"no",nr:"za",nv:"us",ny:"mw",oc:"fr",om:"et",or:"in",os:"ge",pa:"in",pl:"pl",ps:"af",pt:"br",qu:"pe",rm:"ch",rn:"bi",ro:"ro",ru:"ru",rw:"rw",sa:"in",sd:"in",se:"no",sg:"cf",si:"lk",sk:"sk",sl:"si",
sm:"ws",sn:"zw",so:"so",sq:"al",sr:"rs",ss:"za",st:"za",su:"id",sv:"se",sw:"tz",ta:"in",te:"in",tg:"tj",th:"th",ti:"et",tk:"tm",tl:"ph",tn:"za",to:"to",tr:"tr",ts:"za",tt:"ru",ty:"pf",ug:"cn",uk:"ua",ur:"pk",uz:"uz",ve:"za",vi:"vn",wa:"be",wo:"sn",xh:"za",yi:"il",yo:"ng",za:"cn",zh:"cn",zu:"za",ace:"id",ady:"ru",agq:"cm",alt:"ru",amo:"ng",asa:"tz",ast:"es",awa:"in",bal:"pk",ban:"id",bas:"cm",bax:"cm",bbc:"id",bem:"zm",bez:"tz",bfq:"in",bft:"pk",bfy:"in",bhb:"in",bho:"in",bik:"ph",bin:"ng",bjj:"in",
bku:"ph",bqv:"ci",bra:"in",brx:"in",bss:"cm",btv:"pk",bua:"ru",buc:"yt",bug:"id",bya:"id",byn:"er",cch:"ng",ccp:"in",ceb:"ph",cgg:"ug",chk:"fm",chm:"ru",chp:"ca",chr:"us",cja:"kh",cjm:"vn",ckb:"iq",crk:"ca",csb:"pl",dar:"ru",dav:"ke",den:"ca",dgr:"ca",dje:"ne",doi:"in",dsb:"de",dua:"cm",dyo:"sn",dyu:"bf",ebu:"ke",efi:"ng",ewo:"cm",fan:"gq",fil:"ph",fon:"bj",fur:"it",gaa:"gh",gag:"md",gbm:"in",gcr:"gf",gez:"et",gil:"ki",gon:"in",gor:"id",grt:"in",gsw:"ch",guz:"ke",gwi:"ca",haw:"us",hil:"ph",hne:"in",
hnn:"ph",hoc:"in",hoj:"in",ibb:"ng",ilo:"ph",inh:"ru",jgo:"cm",jmc:"tz",kaa:"uz",kab:"dz",kaj:"ng",kam:"ke",kbd:"ru",kcg:"ng",kde:"tz",kdt:"th",kea:"cv",ken:"cm",kfo:"ci",kfr:"in",kha:"in",khb:"cn",khq:"ml",kht:"in",kkj:"cm",kln:"ke",kmb:"ao",koi:"ru",kok:"in",kos:"fm",kpe:"lr",krc:"ru",kri:"sl",krl:"ru",kru:"in",ksb:"tz",ksf:"cm",ksh:"de",kum:"ru",lag:"tz",lah:"pk",lbe:"ru",lcp:"cn",lep:"in",lez:"ru",lif:"np",lis:"cn",lki:"ir",lmn:"in",lol:"cd",lua:"cd",luo:"ke",luy:"ke",lwl:"th",mad:"id",mag:"in",
mai:"in",mak:"id",man:"gn",mas:"ke",mdf:"ru",mdh:"ph",mdr:"id",men:"sl",mer:"ke",mfe:"mu",mgh:"mz",mgo:"cm",min:"id",mni:"in",mnk:"gm",mnw:"mm",mos:"bf",mua:"cm",mwr:"in",myv:"ru",nap:"it",naq:"na",nds:"de","new":"np",niu:"nu",nmg:"cm",nnh:"cm",nod:"th",nso:"za",nus:"sd",nym:"tz",nyn:"ug",pag:"ph",pam:"ph",pap:"bq",pau:"pw",pon:"fm",prd:"ir",raj:"in",rcf:"re",rej:"id",rjs:"np",rkt:"in",rof:"tz",rwk:"tz",saf:"gh",sah:"ru",saq:"ke",sas:"id",sat:"in",saz:"in",sbp:"tz",scn:"it",sco:"gb",sdh:"ir",seh:"mz",
ses:"ml",shi:"ma",shn:"mm",sid:"et",sma:"se",smj:"se",smn:"fi",sms:"fi",snk:"ml",srn:"sr",srr:"sn",ssy:"er",suk:"tz",sus:"gn",swb:"yt",swc:"cd",syl:"bd",syr:"sy",tbw:"ph",tcy:"in",tdd:"cn",tem:"sl",teo:"ug",tet:"tl",tig:"er",tiv:"ng",tkl:"tk",tmh:"ne",tpi:"pg",trv:"tw",tsg:"ph",tts:"th",tum:"mw",tvl:"tv",twq:"ne",tyv:"ru",tzm:"ma",udm:"ru",uli:"fm",umb:"ao",unr:"in",unx:"in",vai:"lr",vun:"tz",wae:"ch",wal:"et",war:"ph",xog:"ug",xsr:"np",yao:"mz",yap:"fm",yav:"cm",zza:"tr"}[d[0]];return b};m.getWeekend=
function(d){var b=m._region(d);d={"in":0,af:4,dz:4,ir:4,om:4,sa:4,ye:4,ae:5,bh:5,eg:5,il:5,iq:5,jo:5,kw:5,ly:5,ma:5,qa:5,sd:5,sy:5,tn:5}[b];b={af:5,dz:5,ir:5,om:5,sa:5,ye:5,ae:6,bh:5,eg:6,il:6,iq:6,jo:6,kw:6,ly:6,ma:6,qa:6,sd:6,sy:6,tn:6}[b];void 0===d&&(d=6);void 0===b&&(b=0);return{start:d,end:b}};return m})},"esri/core/global":function(){define(["require","exports"],function(b,e){return function(){if("undefined"!==typeof self)return self;if("undefined"!==typeof window)return window;if("undefined"!==
typeof global)return global}()})},"esri/core/typedArrayUtil":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.forEach=function(b,d){if(b.forEach)b.forEach(d);else for(var e=0;e<b.length;e++)d(b[e],e,b)};e.slice=function(b,d,e){if(b.slice)return b.slice(d,e);void 0===d?d=0:(0>d&&(d+=b.length),d=Math.min(b.length,Math.max(0,d)));void 0===e?e=b.length:(0>e&&(e+=b.length),e=Math.min(b.length,Math.max(0,e)));e=Math.max(0,e-d);for(var l=new b.constructor(e),
h=0;h<e;h++)l[h]=b[d+h];return l};e.isArrayBuffer=function(b){return b instanceof ArrayBuffer||b&&b.constructor&&"ArrayBuffer"===b.constructor.name};e.isInt8Array=function(b){return b instanceof Int8Array||b&&b.constructor&&"Int8Array"===b.constructor.name};e.isUint8Array=function(b){return b instanceof Uint8Array||b&&b.constructor&&"Uint8Array"===b.constructor.name};e.isUint8ClampedArray=function(b){return b instanceof Uint8ClampedArray||b&&b.constructor&&"Uint8ClampedArray"===b.constructor.name};
e.isInt16Array=function(b){return b instanceof Int16Array||b&&b.constructor&&"Int16Array"===b.constructor.name};e.isUint16Array=function(b){return b instanceof Uint16Array||b&&b.constructor&&"Uint16Array"===b.constructor.name};e.isInt32Array=function(b){return b instanceof Int32Array||b&&b.constructor&&"Int32Array"===b.constructor.name};e.isUint32Array=function(b){return b instanceof Uint32Array||b&&b.constructor&&"Uint32Array"===b.constructor.name};e.isFloat32Array=function(b){return b instanceof
Float32Array||b&&b.constructor&&"Float32Array"===b.constructor.name};e.isFloat64Array=function(b){return b instanceof Float64Array||b&&b.constructor&&"Float64Array"===b.constructor.name};e.toArray=function(b){for(var d=Array(b.length),e=0;e<b.length;e++)d[e]=b[e];return d}})},"@dojo/framework/shim/string":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define("require exports tslib ./global ../has/has ./support/util".split(" "),
b)})(function(b,e){Object.defineProperty(e,"__esModule",{value:!0});var m=b("tslib"),d=b("./global"),k=b("../has/has");b=b("./support/util");e.HIGH_SURROGATE_MIN=55296;e.HIGH_SURROGATE_MAX=56319;e.LOW_SURROGATE_MIN=56320;e.LOW_SURROGATE_MAX=57343;if(k.default("es6-string")&&k.default("es6-string-raw"))e.fromCodePoint=d.default.String.fromCodePoint,e.raw=d.default.String.raw,e.codePointAt=b.wrapNative(d.default.String.prototype.codePointAt),e.endsWith=b.wrapNative(d.default.String.prototype.endsWith),
e.includes=b.wrapNative(d.default.String.prototype.includes),e.normalize=b.wrapNative(d.default.String.prototype.normalize),e.repeat=b.wrapNative(d.default.String.prototype.repeat),e.startsWith=b.wrapNative(d.default.String.prototype.startsWith);else{var l=function(d,a,c,f,b){void 0===b&&(b=!1);if(null==a)throw new TypeError("string."+d+" requires a valid string to search against.");d=a.length;return[a,String(c),Math.min(Math.max(f!==f?b?d:0:f,0),d)]};e.fromCodePoint=function(){for(var d=0;d<arguments.length;d++);
d=arguments.length;if(!d)return"";for(var a=String.fromCharCode,c=[],f=-1,b="";++f<d;){var g=Number(arguments[f]);if(!(isFinite(g)&&Math.floor(g)===g&&0<=g&&1114111>=g))throw RangeError("string.fromCodePoint: Invalid code point "+g);65535>=g?c.push(g):(g-=65536,c.push((g>>10)+e.HIGH_SURROGATE_MIN,g%1024+e.LOW_SURROGATE_MIN));if(f+1===d||16384<c.length)b+=a.apply(null,c),c.length=0}return b};e.raw=function(d){for(var a=[],c=1;c<arguments.length;c++)a[c-1]=arguments[c];var c=d.raw,f="",b=a.length;if(null==
d||null==d.raw)throw new TypeError("string.raw requires a valid callSite object with a raw value");for(var g=0,h=c.length;g<h;g++)f+=c[g]+(g<b&&g<h-1?a[g]:"");return f};e.codePointAt=function(d,a){void 0===a&&(a=0);if(null==d)throw new TypeError("string.codePointAt requries a valid string.");var c=d.length;a!==a&&(a=0);if(!(0>a||a>=c)){var f=d.charCodeAt(a);return f>=e.HIGH_SURROGATE_MIN&&f<=e.HIGH_SURROGATE_MAX&&c>a+1&&(d=d.charCodeAt(a+1),d>=e.LOW_SURROGATE_MIN&&d<=e.LOW_SURROGATE_MAX)?1024*(f-
e.HIGH_SURROGATE_MIN)+d-e.LOW_SURROGATE_MIN+65536:f}};e.endsWith=function(d,a,c){if(""===a)return!0;if("undefined"===typeof c)c=d.length;else if(null===c||isNaN(c))return!1;c=m.__read(l("endsWith",d,a,c,!0),3);d=c[0];a=c[1];c=c[2];var f=c-a.length;return 0>f?!1:d.slice(f,c)===a};e.includes=function(d,a,c){void 0===c&&(c=0);c=m.__read(l("includes",d,a,c),3);d=c[0];a=c[1];c=c[2];return-1!==d.indexOf(a,c)};e.repeat=function(d,a){void 0===a&&(a=0);if(null==d)throw new TypeError("string.repeat requires a valid string.");
a!==a&&(a=0);if(0>a||Infinity===a)throw new RangeError("string.repeat requires a non-negative finite count.");for(var c="";a;)a%2&&(c+=d),1<a&&(d+=d),a>>=1;return c};e.startsWith=function(d,a,c){void 0===c&&(c=0);a=String(a);c=m.__read(l("startsWith",d,a,c),3);d=c[0];a=c[1];c=c[2];var f=c+a.length;return f>d.length?!1:d.slice(c,f)===a}}k.default("es2017-string")?(e.padEnd=b.wrapNative(d.default.String.prototype.padEnd),e.padStart=b.wrapNative(d.default.String.prototype.padStart)):(e.padEnd=function(d,
a,c){void 0===c&&(c=" ");if(null===d||void 0===d)throw new TypeError("string.repeat requires a valid string.");if(Infinity===a)throw new RangeError("string.padEnd requires a non-negative finite count.");if(null===a||void 0===a||0>a)a=0;d=String(d);a-=d.length;0<a&&(d+=e.repeat(c,Math.floor(a/c.length))+c.slice(0,a%c.length));return d},e.padStart=function(d,a,c){void 0===c&&(c=" ");if(null===d||void 0===d)throw new TypeError("string.repeat requires a valid string.");if(Infinity===a)throw new RangeError("string.padStart requires a non-negative finite count.");
if(null===a||void 0===a||0>a)a=0;d=String(d);a-=d.length;0<a&&(d=e.repeat(c,Math.floor(a/c.length))+c.slice(0,a%c.length)+d);return d})})},"tslib/tslib":function(){var b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z;(function(a){function c(a,c){a!==f&&("function"===typeof Object.create?Object.defineProperty(a,"__esModule",{value:!0}):a.__esModule=!0);return function(f,g){return a[f]=c?c(f,g):g}}var f="object"===typeof global?global:"object"===typeof self?self:"object"===typeof this?this:{};"function"===typeof define&&
define.amd?define("tslib",["exports"],function(g){a(c(f,c(g)))}):"object"===typeof module&&"object"===typeof module.exports?a(c(f,c(module.exports))):a(c(f))})(function(y){var x=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var f in c)c.hasOwnProperty(f)&&(a[f]=c[f])};b=function(a,c){function f(){this.constructor=a}x(a,c);a.prototype=null===c?Object.create(c):(f.prototype=c.prototype,new f)};e=Object.assign||function(a){for(var c,f=1,g=arguments.length;f<
g;f++){c=arguments[f];for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(a[d]=c[d])}return a};m=function(a,c){var f={},g;for(g in a)Object.prototype.hasOwnProperty.call(a,g)&&0>c.indexOf(g)&&(f[g]=a[g]);if(null!=a&&"function"===typeof Object.getOwnPropertySymbols){var d=0;for(g=Object.getOwnPropertySymbols(a);d<g.length;d++)0>c.indexOf(g[d])&&(f[g[d]]=a[g[d]])}return f};d=function(a,c,f,g){var d=arguments.length,b=3>d?c:null===g?g=Object.getOwnPropertyDescriptor(c,f):g,n;if("object"===typeof Reflect&&
"function"===typeof Reflect.decorate)b=Reflect.decorate(a,c,f,g);else for(var p=a.length-1;0<=p;p--)if(n=a[p])b=(3>d?n(b):3<d?n(c,f,b):n(c,f))||b;return 3<d&&b&&Object.defineProperty(c,f,b),b};k=function(a,c){return function(f,g){c(f,g,a)}};l=function(a,c){if("object"===typeof Reflect&&"function"===typeof Reflect.metadata)return Reflect.metadata(a,c)};h=function(a,c,f,g){return new (f||(f=Promise))(function(d,b){function n(a){try{h(g.next(a))}catch(I){b(I)}}function p(a){try{h(g["throw"](a))}catch(I){b(I)}}
function h(a){a.done?d(a.value):(new f(function(c){c(a.value)})).then(n,p)}h((g=g.apply(a,c||[])).next())})};a=function(a,c){function f(a){return function(c){return g([a,c])}}function g(f){if(b)throw new TypeError("Generator is already executing.");for(;d;)try{if(b=1,n&&(p=f[0]&2?n["return"]:f[0]?n["throw"]||((p=n["return"])&&p.call(n),0):n.next)&&!(p=p.call(n,f[1])).done)return p;if(n=0,p)f=[f[0]&2,p.value];switch(f[0]){case 0:case 1:p=f;break;case 4:return d.label++,{value:f[1],done:!1};case 5:d.label++;
n=f[1];f=[0];continue;case 7:f=d.ops.pop();d.trys.pop();continue;default:if(!(p=d.trys,p=0<p.length&&p[p.length-1])&&(6===f[0]||2===f[0])){d=0;continue}if(3===f[0]&&(!p||f[1]>p[0]&&f[1]<p[3]))d.label=f[1];else if(6===f[0]&&d.label<p[1])d.label=p[1],p=f;else if(p&&d.label<p[2])d.label=p[2],d.ops.push(f);else{p[2]&&d.ops.pop();d.trys.pop();continue}}f=c.call(a,d)}catch(I){f=[6,I],n=0}finally{b=p=0}if(f[0]&5)throw f[1];return{value:f[0]?f[1]:void 0,done:!0}}var d={label:0,sent:function(){if(p[0]&1)throw p[1];
return p[1]},trys:[],ops:[]},b,n,p,h;return h={next:f(0),"throw":f(1),"return":f(2)},"function"===typeof Symbol&&(h[Symbol.iterator]=function(){return this}),h};c=function(a,c){for(var f in a)c.hasOwnProperty(f)||(c[f]=a[f])};f=function(a){var c="function"===typeof Symbol&&a[Symbol.iterator],f=0;return c?c.call(a):{next:function(){a&&f>=a.length&&(a=void 0);return{value:a&&a[f++],done:!a}}}};n=function(a,c){var f="function"===typeof Symbol&&a[Symbol.iterator];if(!f)return a;a=f.call(a);var g,d=[],
b;try{for(;(void 0===c||0<c--)&&!(g=a.next()).done;)d.push(g.value)}catch(G){b={error:G}}finally{try{g&&!g.done&&(f=a["return"])&&f.call(a)}finally{if(b)throw b.error;}}return d};g=function(){for(var a=[],c=0;c<arguments.length;c++)a=a.concat(n(arguments[c]));return a};q=function(a){return this instanceof q?(this.v=a,this):new q(a)};p=function(a,c,f){function g(a){h[a]&&(e[a]=function(c){return new Promise(function(f,g){1<t.push([a,c,f,g])||d(a,c)})})}function d(a,c){try{var f=h[a](c);f.value instanceof
q?Promise.resolve(f.value.v).then(b,n):p(t[0][2],f)}catch(O){p(t[0][3],O)}}function b(a){d("next",a)}function n(a){d("throw",a)}function p(a,c){(a(c),t.shift(),t.length)&&d(t[0][0],t[0][1])}if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var h=f.apply(a,c||[]),e,t=[];return e={},g("next"),g("throw"),g("return"),e[Symbol.asyncIterator]=function(){return this},e};t=function(a){function c(c,d){f[c]=a[c]?function(f){return(g=!g)?{value:q(a[c](f)),done:"return"===c}:
d?d(f):f}:d}var f,g;return f={},c("next"),c("throw",function(a){throw a;}),c("return"),f[Symbol.iterator]=function(){return this},f};r=function(a){function c(c){b[c]=a[c]&&function(f){return new Promise(function(d,b){f=a[c](f);g(d,b,f.done,f.value)})}}function g(a,c,f,g){Promise.resolve(g).then(function(c){a({value:c,done:f})},c)}if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var d=a[Symbol.asyncIterator],b;return d?d.call(a):(a="function"===typeof f?f(a):a[Symbol.iterator](),
b={},c("next"),c("throw"),c("return"),b[Symbol.asyncIterator]=function(){return this},b)};v=function(a,c){Object.defineProperty?Object.defineProperty(a,"raw",{value:c}):a.raw=c;return a};u=function(a){if(a&&a.__esModule)return a;var c={};if(null!=a)for(var f in a)Object.hasOwnProperty.call(a,f)&&(c[f]=a[f]);c["default"]=a;return c};z=function(a){return a&&a.__esModule?a:{"default":a}};y("__extends",b);y("__assign",e);y("__rest",m);y("__decorate",d);y("__param",k);y("__metadata",l);y("__awaiter",h);
y("__generator",a);y("__exportStar",c);y("__values",f);y("__read",n);y("__spread",g);y("__await",q);y("__asyncGenerator",p);y("__asyncDelegator",t);y("__asyncValues",r);y("__makeTemplateObject",v);y("__importStar",u);y("__importDefault",z)})},"@dojo/framework/shim/global":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define(["require","exports"],b)})(function(b,e){Object.defineProperty(e,
"__esModule",{value:!0});b=function(){if("undefined"!==typeof self)return self;if("undefined"!==typeof window)return window;if("undefined"!==typeof global)return global}();e.default=b})},"@dojo/framework/has/has":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define(["require","exports","tslib","../shim/global"],b)})(function(b,e){function m(c){c=c.toLowerCase();return!!(c in
a||c in e.testCache||e.testFunctions[c])}function d(c,d,g){void 0===g&&(g=!1);var f=c.toLowerCase();if(m(f)&&!g&&!(f in a))throw new TypeError('Feature "'+c+'" exists and overwrite not true.');"function"===typeof d?e.testFunctions[f]=d:(e.testCache[f]=d,delete e.testFunctions[f])}function k(c){var f=c.toLowerCase();if(f in a)c=a[f];else if(e.testFunctions[f])c=e.testCache[f]=e.testFunctions[f].call(null),delete e.testFunctions[f];else if(f in e.testCache)c=e.testCache[f];else throw new TypeError('Attempt to detect unregistered has feature "'+
c+'"');return c}Object.defineProperty(e,"__esModule",{value:!0});var l=b("tslib"),h=b("../shim/global");e.testCache={};e.testFunctions={};b=(h.default.DojoHasEnvironment||{}).staticFeatures;"DojoHasEnvironment"in h.default&&delete h.default.DojoHasEnvironment;var a=b?"function"===typeof b?b.apply(h.default):b:{};e.load=function(a,c,g,d){a?c([a],g):g()};e.normalize=function(a,c){function f(a){var c=d[b++];if(":"===c)return null;if("?"===d[b++]){if(!a&&k(c))return f();f(!0);return f(a)}return c}var d=
a.match(/[\?:]|[^:\?]*/g)||[],b=0;return(a=f())&&c(a)};e.exists=m;e.add=d;e.default=k;d("public-path",void 0);d("dojo-debug",!1);d("host-browser","undefined"!==typeof document&&"undefined"!==typeof location);d("host-node",function(){if("object"===typeof process&&process.versions&&process.versions.node)return process.versions.node});d("fetch","fetch"in h.default&&"function"===typeof h.default.fetch,!0);d("es6-array",function(){return["from","of"].every(function(a){return a in h.default.Array})&&["findIndex",
"find","copyWithin"].every(function(a){return a in h.default.Array.prototype})},!0);d("es6-array-fill",function(){return"fill"in h.default.Array.prototype?1===[1].fill(9,Number.POSITIVE_INFINITY)[0]:!1},!0);d("es7-array",function(){return"includes"in h.default.Array.prototype},!0);d("es6-map",function(){if("function"===typeof h.default.Map)try{var a=new h.default.Map([[0,1]]);return a.has(0)&&"function"===typeof a.keys&&k("es6-symbol")&&"function"===typeof a.values&&"function"===typeof a.entries}catch(n){}return!1},
!0);d("es6-math",function(){return"clz32 sign log10 log2 log1p expm1 cosh sinh tanh acosh asinh atanh trunc fround cbrt hypot".split(" ").every(function(a){return"function"===typeof h.default.Math[a]})},!0);d("es6-math-imul",function(){return"imul"in h.default.Math?-5===Math.imul(4294967295,5):!1},!0);d("es6-object",function(){return k("es6-symbol")&&["assign","is","getOwnPropertySymbols","setPrototypeOf"].every(function(a){return"function"===typeof h.default.Object[a]})},!0);d("es2017-object",function(){return["values",
"entries","getOwnPropertyDescriptors"].every(function(a){return"function"===typeof h.default.Object[a]})},!0);d("es-observable",function(){return"undefined"!==typeof h.default.Observable},!0);d("es6-promise",function(){return"undefined"!==typeof h.default.Promise&&k("es6-symbol")},!0);d("es2018-promise-finally",function(){return k("es6-promise")&&"undefined"!==typeof h.default.Promise.prototype.finally},!0);d("es6-set",function(){if("function"===typeof h.default.Set){var a=new h.default.Set([1]);
return a.has(1)&&"keys"in a&&"function"===typeof a.keys&&k("es6-symbol")}return!1},!0);d("es6-string",function(){return["fromCodePoint"].every(function(a){return"function"===typeof h.default.String[a]})&&"codePointAt normalize repeat startsWith endsWith includes".split(" ").every(function(a){return"function"===typeof h.default.String.prototype[a]})},!0);d("es6-string-raw",function(){function a(a){for(var c=1;c<arguments.length;c++);c=l.__spread(a);c.raw=a.raw;return c}if("raw"in h.default.String){var d=
a(c||(c=l.__makeTemplateObject(["a\n",""],["a\\n",""])),1);d.raw=["a\\n"];return"a\\n"===h.default.String.raw(d,42)}return!1},!0);d("es2017-string",function(){return["padStart","padEnd"].every(function(a){return"function"===typeof h.default.String.prototype[a]})},!0);d("es6-symbol",function(){return"undefined"!==typeof h.default.Symbol&&"symbol"===typeof Symbol()},!0);d("es6-weakmap",function(){if("undefined"!==typeof h.default.WeakMap){var a={},c={},g=new h.default.WeakMap([[a,1]]);Object.freeze(a);
return 1===g.get(a)&&g.set(c,2)===g&&k("es6-symbol")}return!1},!0);d("microtasks",function(){return k("es6-promise")||0||k("dom-mutationobserver")},!0);d("postmessage",function(){return"undefined"!==typeof h.default.window&&"function"===typeof h.default.postMessage},!0);d("raf",function(){return"function"===typeof h.default.requestAnimationFrame},!0);d("setimmediate",function(){return"undefined"!==typeof h.default.setImmediate},!0);d("dom-mutationobserver",function(){if(k("host-browser")&&(h.default.MutationObserver||
h.default.WebKitMutationObserver)){var a=document.createElement("div"),c=new (h.default.MutationObserver||h.default.WebKitMutationObserver)(function(){});c.observe(a,{attributes:!0});a.style.setProperty("display","block");return!!c.takeRecords().length}return!1},!0);d("dom-webanimation",function(){return k("host-browser")&&void 0!==h.default.Animation&&void 0!==h.default.KeyframeEffect},!0);d("abort-controller",function(){return"undefined"!==typeof h.default.AbortController});d("abort-signal",function(){return"undefined"!==
typeof h.default.AbortSignal});d("dom-intersection-observer",function(){return k("host-browser")&&void 0!==h.default.IntersectionObserver},!0);d("dom-resize-observer",function(){return k("host-browser")&&void 0!==h.default.ResizeObserver},!0);d("dom-pointer-events",function(){return k("host-browser")&&void 0!==h.default.onpointerdown},!0);d("build-elide",!1);var c})},"@dojo/framework/shim/support/util":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,
exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define(["require","exports"],b)})(function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.getValueDescriptor=function(b,d,e,l){void 0===d&&(d=!1);void 0===e&&(e=!0);void 0===l&&(l=!0);return{value:b,enumerable:d,writable:e,configurable:l}};e.wrapNative=function(b){return function(d){for(var e=[],l=1;l<arguments.length;l++)e[l-1]=arguments[l];return b.apply(d,e)}}})},"esri/core/Message":function(){define(["require",
"exports","dojo/string"],function(b,e,m){return function(){function d(b,e,h){this instanceof d&&(this.name=b,this.message=e&&m.substitute(e,h,function(a){return null==a?"":a})||"",this.details=h)}d.prototype.toString=function(){return"["+this.name+"]: "+this.message};return d}()})},"esri/core/collectionUtils":function(){define(["require","exports","./Collection"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.referenceSetter=function(d,b,e){void 0===e&&(e=m);b||(b=new e);if(b===
d)return b;b.removeAll();d&&(Array.isArray(d)||d.isInstanceOf&&d.isInstanceOf(m))?b.addMany(d):d&&b.add(d);return b};e.castForReferenceSetter=function(d){return d}})},"esri/core/Collection":function(){define("require exports ./tsSupport/declareExtendsHelper ./tsSupport/decorateHelper ./Accessor ./ArrayPool ./Evented ./lang ./ObjectPool ./scheduling ./accessorSupport/decorators ./accessorSupport/ensureType".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){function q(a){return a?a.isInstanceOf&&a.isInstanceOf(B):
!1}function p(a){return a?q(a)?a.toArray():a.length?Array.prototype.slice.apply(a):[]:[]}function t(a){if(a&&a.length)return a[0]}function r(a,c,f,g){c&&c.forEach(function(c,d,b){a.push(c);r(a,f.call(g,c,d,b),f,g)})}b=function(){function a(){this.target=null;this.defaultPrevented=this.cancellable=!1}a.prototype.preventDefault=function(){this.cancellable&&(this.defaultPrevented=!0)};a.prototype.reset=function(a){this.defaultPrevented=!1;this.item=a};return a}();var v=function(){},u=new c(b,!0,function(a){a.item=
null;a.target=null}),z=new Set,y=new Set,x=new Set,w=new Map,A=0,B=function(c){function b(a){a=c.call(this,a)||this;a._boundDispatch=a._dispatchColChange.bind(a);a._chgListeners=[];a._notifications=null;a._timer=null;a.length=0;a._items=[];Object.defineProperty(a,"uid",{value:A++});return a}m(b,c);h=b;b.ofType=function(a){if(!a)return h;if(w.has(a))return w.get(a);var c;if("function"===typeof a)c=a.prototype.declaredClass;else if(a.base)c=a.base.prototype.declaredClass;else for(var f in a.typeMap){var d=
a.typeMap[f].prototype.declaredClass;c=c?c+(" | "+d):d}c=h.createSubclass({declaredClass:"esri.core.Collection\x3c"+c+"\x3e"});c.isCollection=q;f={Type:a,ensureType:"function"===typeof a?g.ensureType(a):g.ensureOneOfType(a)};Object.defineProperty(c.prototype,"itemType",{value:f});w.set(a,c);return c};b.prototype.normalizeCtorArgs=function(a){return a?Array.isArray(a)||q(a)?{items:a}:a:{}};Object.defineProperty(b.prototype,"items",{get:function(){return this._items},set:function(a){this._emitBeforeChanges()||
(this._splice.apply(this,[0,this.length].concat(p(a))),this._emitAfterChanges())},enumerable:!0,configurable:!0});b.prototype.on=function(a,c){if("change"===a){var f=this._chgListeners,g={removed:!1,callback:c};f.push(g);this._notifications&&this._notifications.push({listeners:f.slice(),items:this._items.slice(),changes:[]});return{remove:function(){this.remove=v;g.removed=!0;f.splice(f.indexOf(g),1)}}}return this._emitter.on(a,c)};b.prototype.hasEventListener=function(a){return"change"===a?0<this._chgListeners.length:
this._emitter.hasEventListener(a)};b.prototype.add=function(a,c){if(this._emitBeforeChanges())return this;c=this.getNextIndex(c);this._splice(c,0,a);this._emitAfterChanges();return this};b.prototype.addMany=function(a,c){void 0===c&&(c=this._items.length);if(!a||!a.length||this._emitBeforeChanges())return this;c=this.getNextIndex(c);this._splice.apply(this,[c,0].concat(p(a)));this._emitAfterChanges();return this};b.prototype.removeAll=function(){if(!this.length||this._emitBeforeChanges())return[];
var a=this._splice(0,this.length)||[];this._emitAfterChanges();return a};b.prototype.clone=function(){return this._createNewInstance({items:this._items.map(a.clone)})};b.prototype.concat=function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];var f,a=a.map(p);return this._createNewInstance({items:(f=this._items).concat.apply(f,a)})};b.prototype.drain=function(a,c){if(this.length&&!this._emitBeforeChanges()){for(var f=this._splice(0,this.length),g=f.length,d=0;d<g;d++)a.call(c,f[d],d,
f);this._emitAfterChanges()}};b.prototype.every=function(a,c){return this._items.every(a,c)};b.prototype.filter=function(a,c){var f;f=2===arguments.length?this._items.filter(a,c):this._items.filter(a);return this._createNewInstance({items:f})};b.prototype.find=function(a,c){if("function"!==typeof a)throw new TypeError(a+" is not a function");for(var f=this._items,g=f.length,d=0;d<g;d++){var b=f[d];if(a.call(c,b,d,f))return b}};b.prototype.findIndex=function(a,c){if("function"!==typeof a)throw new TypeError(a+
" is not a function");for(var f=this._items,g=f.length,d=0;d<g;d++)if(a.call(c,f[d],d,f))return d;return-1};b.prototype.flatten=function(a,c){var f=[];r(f,this,a,c);return new h(f)};b.prototype.forEach=function(a,c){return this._items.forEach(a,c)};b.prototype.getItemAt=function(a){return this._items[a]};b.prototype.getNextIndex=function(a){var c=this.length;a=null==a?c:a;0>a?a=0:a>c&&(a=c);return a};b.prototype.includes=function(a,c){void 0===c&&(c=0);return arguments.length?-1!==this._items.indexOf(a,
c):!1};b.prototype.indexOf=function(a,c){void 0===c&&(c=0);return this._items.indexOf(a,c)};b.prototype.join=function(a){void 0===a&&(a=",");return this._items.join(a)};b.prototype.lastIndexOf=function(a,c){void 0===c&&(c=this.length-1);return this._items.lastIndexOf(a,c)};b.prototype.map=function(a,c){a=this._items.map(a,c);return new h({items:a})};b.prototype.reorder=function(a,c){void 0===c&&(c=this.length-1);var f=this.indexOf(a);if(-1!==f){0>c?c=0:c>=this.length&&(c=this.length-1);if(f!==c){if(this._emitBeforeChanges())return a;
this._splice(f,1);this._splice(c,0,a);this._emitAfterChanges()}return a}};b.prototype.pop=function(){if(this.length&&!this._emitBeforeChanges()){var a=t(this._splice(this.length-1,1));this._emitAfterChanges();return a}};b.prototype.push=function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];if(this._emitBeforeChanges())return this.length;this._splice.apply(this,[this.length,0].concat(a));this._emitAfterChanges();return this.length};b.prototype.reduce=function(a,c){var f=this._items;
return 2===arguments.length?f.reduce(a,c):f.reduce(a)};b.prototype.reduceRight=function(a,c){var f=this._items;return 2===arguments.length?f.reduceRight(a,c):f.reduceRight(a)};b.prototype.remove=function(a){return this.removeAt(this.indexOf(a))};b.prototype.removeAt=function(a){if(!(0>a||a>=this.length||this._emitBeforeChanges()))return a=t(this._splice(a,1)),this._emitAfterChanges(),a};b.prototype.removeMany=function(a){if(!a||!a.length||this._emitBeforeChanges())return[];a=q(a)?a.toArray():a;for(var c=
this._items,f=[],d=a.length,g=0;g<d;g++){var b=c.indexOf(a[g]);if(-1<b){for(var p=g+1,n=b+1,h=Math.min(a.length-p,c.length-n),e=0;e<h&&a[p+e]===c[n+e];)e++;p=1+e;(b=this._splice(b,p))&&0<b.length&&f.push.apply(f,b);g+=p-1}}this._emitAfterChanges();return f};b.prototype.reverse=function(){if(this._emitBeforeChanges())return this;var a=this._splice(0,this.length);a&&(a.reverse(),this._splice.apply(this,[0,0].concat(a)));this._emitAfterChanges();return this};b.prototype.shift=function(){if(this.length&&
!this._emitBeforeChanges()){var a=t(this._splice(0,1));this._emitAfterChanges();return a}};b.prototype.slice=function(a,c){void 0===a&&(a=0);void 0===c&&(c=this.length);return this._createNewInstance({items:this._items.slice(a,c)})};b.prototype.some=function(a,c){return this._items.some(a,c)};b.prototype.sort=function(a){if(!this.length||this._emitBeforeChanges())return this;var c=this._splice(0,this.length);arguments.length?c.sort(a):c.sort();this._splice.apply(this,[0,0].concat(c));return this};
b.prototype.splice=function(a,c){for(var f=[],g=2;g<arguments.length;g++)f[g-2]=arguments[g];if(this._emitBeforeChanges())return[];f=this._splice.apply(this,[a,c].concat(f))||[];this._emitAfterChanges();return f};b.prototype.toArray=function(){return this._items.slice()};b.prototype.toJSON=function(){return this.toArray()};b.prototype.toLocaleString=function(){return this._items.toLocaleString()};b.prototype.toString=function(){return this._items.toString()};b.prototype.unshift=function(){for(var a=
[],c=0;c<arguments.length;c++)a[c]=arguments[c];if(this._emitBeforeChanges())return this.length;this._splice.apply(this,[0,0].concat(a));this._emitAfterChanges();return this.length};b.prototype._createNewInstance=function(a){return new this.constructor(a)};b.prototype._splice=function(a,c){for(var g=[],d=2;d<arguments.length;d++)g[d-2]=arguments[d];var d=this._items,b=this.constructor.prototype.itemType,p,n;!this._notifications&&this.hasEventListener("change")&&(this._notifications=[{listeners:this._chgListeners.slice(),
items:this._items.slice(),changes:[]}],this._timer&&this._timer.remove(),this._timer=f.schedule(this._boundDispatch));if(c){n=d.splice(a,c);if(this.hasEventListener("before-remove")){var h=u.acquire();h.target=this;h.cancellable=!0;for(var e=0,t=n.length;e<t;e++)p=n[e],h.reset(p),this.emit("before-remove",h),h.defaultPrevented&&(n.splice(e,1),d.splice(a,0,p),a+=1,--e,--t);u.release(h)}this.length=this._items.length;if(this.hasEventListener("after-remove")){p=u.acquire();p.target=this;p.cancellable=
!1;t=n.length;for(e=0;e<t;e++)p.reset(n[e]),this.emit("after-remove",p);u.release(p)}}if(g&&g.length){if(b){e=[];for(t=0;t<g.length;t++)p=g[t],h=b.ensureType(p),null==h&&null!=p||e.push(h);g=e}b=this.hasEventListener("before-add");e=this.hasEventListener("after-add");t=a===this.length;if(b||e){p=u.acquire();p.target=this;p.cancellable=!0;h=u.acquire();h.target=this;h.cancellable=!1;for(var q=0,r=g;q<r.length;q++){var l=r[q];b?(p.reset(l),this.emit("before-add",p),p.defaultPrevented||(t?d.push(l):
d.splice(a++,0,l),this._set("length",d.length),e&&(h.reset(l),this.emit("after-add",h)))):(t?d.push(l):d.splice(a++,0,l),this._set("length",d.length),h.reset(l),this.emit("after-add",h))}u.release(h);u.release(p)}else t?d.push.apply(d,g):d.splice.apply(d,[a,0].concat(g)),this._set("length",d.length)}(g&&g.length||n&&n.length)&&this._notifyChangeEvent(g,n);return n};b.prototype._emitBeforeChanges=function(){var a=!1;if(this.hasEventListener("before-changes")){var c=u.acquire();c.target=this;c.cancellable=
!0;this.emit("before-changes",c);a=c.defaultPrevented;u.release(c)}return a};b.prototype._emitAfterChanges=function(){if(this.hasEventListener("after-changes")){var a=u.acquire();a.target=this;a.cancellable=!1;this.emit("after-changes",a);u.release(a)}};b.prototype._notifyChangeEvent=function(a,c){this.hasEventListener("change")&&this._notifications[this._notifications.length-1].changes.push({added:a,removed:c})};b.prototype._dispatchColChange=function(){this._timer&&(this._timer.remove(),this._timer=
null);if(this._notifications){var a=this._notifications;this._notifications=null;for(var c=function(a){var c=a.changes;z.clear();y.clear();x.clear();for(var d=0;d<c.length;d++){var g=c[d],b=g.added,g=g.removed;if(b)if(0===x.size&&0===y.size)for(var p=0,n=b;p<n.length;p++)b=n[p],z.add(b);else for(p=0,n=b;p<n.length;p++)b=n[p],y.has(b)?(x.add(b),y.delete(b)):x.has(b)||z.add(b);if(g)if(0===x.size&&0===z.size)for(p=0;p<g.length;p++)b=g[p],y.add(b);else for(p=0;p<g.length;p++)b=g[p],z.has(b)?z.delete(b):
(x.delete(b),y.add(b))}var h=l.acquire();z.forEach(function(a){h.push(a)});var e=l.acquire();y.forEach(function(a){e.push(a)});var t=f._items,q=a.items,r=l.acquire();x.forEach(function(a){q.indexOf(a)!==t.indexOf(a)&&r.push(a)});if(a.listeners&&(h.length||e.length||r.length))for(c={target:f,added:h,removed:e,moved:r},d=a.listeners.length,b=0;b<d;b++)g=a.listeners[b],g.removed||g.callback.call(f,c);l.release(h);l.release(e);l.release(r)},f=this,d=0;d<a.length;d++)c(a[d]);z.clear();y.clear();x.clear()}};
var h;b.isCollection=q;d([n.property()],b.prototype,"length",void 0);d([n.property()],b.prototype,"items",null);return b=h=d([n.subclass("esri.core.Collection")],b)}(n.declared(k,h));return B})},"esri/core/Accessor":function(){define("./declare ./accessorSupport/Properties ./accessorSupport/get ./accessorSupport/introspection ./accessorSupport/set ./accessorSupport/watch".split(" "),function(b,e,m,d,k,l){e=e.default;b.before(function(a,c){b.hasMixin(a,h)&&d.processPrototype(c)});b.after(function(a){b.hasMixin(a,
h)&&(d.processClass(a),Object.defineProperties(a.prototype,{initialized:{get:function(){return this.__accessor__&&this.__accessor__.initialized||!1}},constructed:{get:function(){return this.__accessor__&&2===this.__accessor__.lifecycle||!1}},destroyed:{get:function(){return this.__accessor__&&this.__accessor__.destroyed||!1}}}))});var h=b(null,{declaredClass:"esri.core.Accessor","-chains-":{initialize:"after",destroy:"before"},constructor:function(){if(this.constructor===h)throw Error("[accessor] cannot instantiate Accessor. This can be fixed by creating a subclass of Accessor");
Object.defineProperty(this,"__accessor__",{value:new e(this)});if(0<arguments.length&&this.normalizeCtorArgs){for(var a=[],c=0;c<arguments.length;c++)a.push(arguments[c]);this.__accessor__.ctorArgs=this.normalizeCtorArgs.apply(this,a)}},__accessor__:null,postscript:function(a){var c=this.__accessor__;a=c.ctorArgs||a;c.initialize();a&&(this.set(a),c.ctorArgs=null);c.constructed();this.initialize()},initialize:function(){},destroy:function(){if(this.destroyed)try{throw Error("instance is already destroyed");
}catch(a){console.warn(a.stack)}else l.removeTarget(this),this.__accessor__.destroy()},get:function(a){return m.get(this,a)},hasOwnProperty:function(a){return this.__accessor__?this.__accessor__.has(a):Object.prototype.hasOwnProperty.call(this,a)},keys:function(){return this.__accessor__?this.__accessor__.keys():[]},set:function(a,c){k.set(this,a,c);return this},watch:function(a,c,f){return l.watch(this,a,c,f)},_clearOverride:function(a){return this.__accessor__.clearOverride(a)},_override:function(a,
c){return this.__accessor__.override(a,c)},_isOverridden:function(a){return this.__accessor__.isOverridden(a)},notifyChange:function(a){this.__accessor__.propertyInvalidated(a)},_get:function(a){return this.__accessor__.internalGet(a)},_set:function(a,c){return this.__accessor__.internalSet(a,c)}});return h})},"esri/core/declare":function(){define(["require","exports","dojo/_base/declare"],function(b,e,m){function d(a,c){a&&!Array.isArray(a)&&"function"!==typeof a&&(c=a,a=null);a=a||[];c=c||{};return k([this].concat(a),
c)}function k(a,c){a&&!Array.isArray(a)&&"function"!==typeof a&&(c=a,a=null);"function"===typeof a?a=[a]:a||(a=[]);c=c||{};var f,b;f=0;for(b=l.length;f<b;f++)l[f](a,c);a=m(a,c);a.createSubclass=d;f=0;for(b=h.length;f<b;f++)h[f](a);return a}var l=[],h=[];(function(a){a.hasMixin=function(a,f){a=Array.isArray(a)?a.reduce(function(a,c){return c._meta?a.concat(c._meta.bases):a},[]):a._meta?a._meta.bases:a;if(!a)return!1;if("string"===typeof f)for(var c=a.length-1;0<=c;c--)if(a[c].prototype.declaredClass===
f)return!0;return-1!==a.indexOf(f)};a.safeMixin=function(a,f){return m.safeMixin(a,f)};a.before=function(a){l.push(a)};a.after=function(a){h.push(a)}})(k||(k={}));return k})},"dojo/_base/declare":function(){define(["./kernel","../has","./lang"],function(b,e,m){function d(a,c){throw Error("declare"+(c?" "+c:"")+": "+a);}function k(a,c){for(var f=[],g=[{cls:0,refs:[]}],b={},p=1,n=a.length,h=0,e,t,q,r,l;h<n;++h){(e=a[h])?"[object Function]"!=w.call(e)&&d("mixin #"+h+" is not a callable constructor.",
c):d("mixin #"+h+" is unknown. Did you use dojo.require to pull it in?",c);t=e._meta?e._meta.bases:[e];q=0;for(e=t.length-1;0<=e;--e)r=t[e].prototype,r.hasOwnProperty("declaredClass")||(r.declaredClass="uniqName_"+B++),r=r.declaredClass,b.hasOwnProperty(r)||(b[r]={count:0,refs:[],cls:t[e]},++p),r=b[r],q&&q!==r&&(r.refs.push(q),++q.count),q=r;++q.count;g[0].refs.push(q)}for(;g.length;){q=g.pop();f.push(q.cls);for(--p;l=q.refs,1==l.length;){q=l[0];if(!q||--q.count){q=0;break}f.push(q.cls);--p}if(q)for(h=
0,n=l.length;h<n;++h)q=l[h],--q.count||g.push(q)}p&&d("can't build consistent linearization",c);e=a[0];f[0]=e?e._meta&&e===f[f.length-e._meta.bases.length]?e._meta.bases.length:1:0;return f}function l(a,c,f,g){var b,p,n,h,e,t,q=this._inherited=this._inherited||{};"string"===typeof a&&(b=a,a=c,c=f,f=g);if("function"===typeof a)n=a,a=c,c=f;else try{n=a.callee}catch(J){if(J instanceof TypeError)d("strict mode inherited() requires the caller function to be passed before arguments",this.declaredClass);
else throw J;}(b=b||n.nom)||d("can't deduce a name to call inherited()",this.declaredClass);f=g=0;h=this.constructor._meta;g=h.bases;t=q.p;if("constructor"!=b){if(q.c!==n&&(t=0,e=g[0],h=e._meta,h.hidden[b]!==n)){(p=h.chains)&&"string"==typeof p[b]&&d("calling chained method with inherited: "+b,this.declaredClass);do if(h=e._meta,p=e.prototype,h&&(p[b]===n&&p.hasOwnProperty(b)||h.hidden[b]===n))break;while(e=g[++t]);t=e?t:-1}if(e=g[++t])if(p=e.prototype,e._meta&&p.hasOwnProperty(b))f=p[b];else{n=x[b];
do if(p=e.prototype,(f=p[b])&&(e._meta?p.hasOwnProperty(b):f!==n))break;while(e=g[++t])}f=e&&f||x[b]}else{if(q.c!==n&&(t=0,(h=g[0]._meta)&&h.ctor!==n)){for((p=h.chains)&&"manual"===p.constructor||d("calling chained constructor with inherited",this.declaredClass);(e=g[++t])&&(!(h=e._meta)||h.ctor!==n););t=e?t:-1}for(;(e=g[++t])&&!(f=(h=e._meta)?h.ctor:e););f=e&&f}q.c=f;q.p=t;if(f)return!0===c?f:f.apply(this,c||a)}function h(a,c,f){return"string"===typeof a?"function"===typeof c?this.__inherited(a,
c,f,!0):this.__inherited(a,c,!0):"function"===typeof a?this.__inherited(a,c,!0):this.__inherited(a,!0)}function a(a,c,f,g){var d=this.getInherited(a,c,f);if(d)return d.apply(this,g||f||c||a)}function c(a){for(var c=this.constructor._meta.bases,f=0,g=c.length;f<g;++f)if(c[f]===a)return!0;return this instanceof a}function f(a,c){for(var f in c)"constructor"!=f&&c.hasOwnProperty(f)&&(a[f]=c[f])}function n(a){z.safeMixin(this.prototype,a);return this}function g(a,c){a instanceof Array||"function"===typeof a||
(c=a,a=void 0);c=c||{};a=a||[];return z([this].concat(a),c)}function q(a,c){return function(){var f=arguments,g=f,d=f[0],b,p;p=a.length;var n;if(!(this instanceof f.callee))return u(f);if(c&&(d&&d.preamble||this.preamble))for(n=Array(a.length),n[0]=f,b=0;;){(d=f[0])&&(d=d.preamble)&&(f=d.apply(this,f)||f);d=a[b].prototype;(d=d.hasOwnProperty("preamble")&&d.preamble)&&(f=d.apply(this,f)||f);if(++b==p)break;n[b]=f}for(b=p-1;0<=b;--b)d=a[b],(d=(p=d._meta)?p.ctor:d)&&d.apply(this,n?n[b]:f);(d=this.postscript)&&
d.apply(this,g)}}function p(a,c){return function(){var f=arguments,d=f,g=f[0];if(!(this instanceof f.callee))return u(f);c&&(g&&(g=g.preamble)&&(d=g.apply(this,d)||d),(g=this.preamble)&&g.apply(this,d));a&&a.apply(this,f);(g=this.postscript)&&g.apply(this,f)}}function t(a){return function(){var c=arguments,f=0,g,d;if(!(this instanceof c.callee))return u(c);for(;g=a[f];++f)if(g=(d=g._meta)?d.ctor:g){g.apply(this,c);break}(g=this.postscript)&&g.apply(this,c)}}function r(a,c,f){return function(){var g,
d,b=0,p=1;f&&(b=c.length-1,p=-1);for(;g=c[b];b+=p)d=g._meta,(g=(d?d.hidden:g.prototype)[a])&&g.apply(this,arguments)}}function v(a){A.prototype=a.prototype;a=new A;A.prototype=null;return a}function u(a){var c=a.callee,f=v(c);c.apply(f,a);return f}function z(a,b,u){"string"!=typeof a&&(u=b,b=a,a="");u=u||{};var B,A,C,E,G,M,U,O=1,J=b;"[object Array]"==w.call(b)?(M=k(b,a),C=M[0],O=M.length-C,b=M[O]):(M=[0],b?"[object Function]"==w.call(b)?(C=b._meta,M=M.concat(C?C.bases:b)):d("base class is not a callable constructor.",
a):null!==b&&d("unknown base class. Did you use dojo.require to pull it in?",a));if(b)for(A=O-1;;--A){B=v(b);if(!A)break;C=M[A];(C._meta?f:y)(B,C.prototype);E=e("csp-restrictions")?function(){}:new Function;E.superclass=b;E.prototype=B;b=B.constructor=E}else B={};z.safeMixin(B,u);C=u.constructor;C!==x.constructor&&(C.nom="constructor",B.constructor=C);for(A=O-1;A;--A)(C=M[A]._meta)&&C.chains&&(U=y(U||{},C.chains));B["-chains-"]&&(U=y(U||{},B["-chains-"]));b&&b.prototype&&b.prototype["-chains-"]&&
(U=y(U||{},b.prototype["-chains-"]));C=!U||!U.hasOwnProperty("constructor");M[0]=E=U&&"manual"===U.constructor?t(M):1==M.length?p(u.constructor,C):q(M,C);E._meta={bases:M,hidden:u,chains:U,parents:J,ctor:u.constructor};E.superclass=b&&b.prototype;E.extend=n;E.createSubclass=g;E.prototype=B;B.constructor=E;B.getInherited=h;B.isInstanceOf=c;B.inherited=F;B.__inherited=l;a&&(B.declaredClass=a,m.setObject(a,E));if(U)for(G in U)B[G]&&"string"==typeof U[G]&&"constructor"!=G&&(C=B[G]=r(G,M,"after"===U[G]),
C.nom=G);return E}var y=m.mixin,x=Object.prototype,w=x.toString,A,B=0;A=e("csp-restrictions")?function(){}:new Function;var F=b.config.isDebug?a:l;b.safeMixin=z.safeMixin=function(a,c){var f,g;for(f in c)g=c[f],g===x[f]&&f in x||"constructor"==f||("[object Function]"==w.call(g)&&(g.nom=f),a[f]=g);return a};return b.declare=z})},"esri/core/accessorSupport/Properties":function(){define("require exports ../has ../lang ../Logger ../ObjectPool ./extensions ./PropertyOrigin ./Store".split(" "),function(b,
e,m,d,k,l,h,a,c){Object.defineProperty(e,"__esModule",{value:!0});k.getLogger("esri.core.accessorSupport.Properties");b=function(){function b(f){this.host=f;this._origin=a.OriginId.USER;this.ctorArgs=this.cursors=null;this.destroyed=!1;this.dirties={};this.lifecycle=0;this.overridden=null;this.store=new c.default;f=this.host.constructor.__accessorMetadata__;this.metadatas=f.properties;this.autoDestroy=f.autoDestroy}b.prototype.initialize=function(){this.lifecycle=1;h.instanceCreated(this.host,this.metadatas)};
b.prototype.constructed=function(){this.lifecycle=2};b.prototype.destroy=function(){this.destroyed=!0;var a=this.cursors;if(a)for(var c=0,f=Object.getOwnPropertyNames(a);c<f.length;c++){var d=f[c],b=a[d];if(b){for(;0<b.length;)b.pop().propertyDestroyed(this,d);a[d]=null}}if(this.autoDestroy)for(d in this.metadatas)(a=this.internalGet(d))&&a&&"function"===typeof a.destroy&&(a.destroy(),this.metadatas[d].nonNullable||this.internalSet(d,null))};Object.defineProperty(b.prototype,"initialized",{get:function(){return 0!==
this.lifecycle},enumerable:!0,configurable:!0});b.prototype.clearOverride=function(a){this.isOverridden(a)&&(this.overridden[a]=!1,this.propertyInvalidated(a))};b.prototype.get=function(c){var f=this.metadatas[c];if(this.store.has(c)&&!this.dirties[c])return this.store.get(c);var d=f.get;return d?(f=d.call(this.host),this.store.set(c,f,a.OriginId.COMPUTED),this.propertyCommitted(c),f):f.value};b.prototype.originOf=function(c){var f=this.store.originOf(c);return void 0===f&&(c=this.metadatas[c])&&
c.hasOwnProperty("value")?"defaults":a.idToName(f)};b.prototype.has=function(a){return this.metadatas[a]?this.store.has(a):!1};b.prototype.internalGet=function(a){if(this.metadatas[a]){var c=this.store;return c.has(a)?c.get(a):this.metadatas[a].value}};b.prototype.internalSet=function(c,f){if(this.metadatas[c]){var g=this.initialized?this._origin:a.OriginId.DEFAULTS,b=this.store.get(c,g);d.equals(f,b)&&this.store.has(c,g)&&!this.isOverridden(c)||(this.propertyInvalidated(c),this.store.set(c,f,g),
this.propertyCommitted(c))}};b.prototype.isOverridden=function(a){return null!=this.overridden&&!0===this.overridden[a]};b.prototype.keys=function(){return Object.keys(this.metadatas)};b.prototype.override=function(a,c){if(this.metadatas[a]){this.overridden||(this.overridden={});var d=this.metadatas[a];if(!d.nonNullable||null!=c){if(d=d.cast){c=this.cast(d,c);var d=c.valid,g=c.value;f.release(c);if(!d)return;c=g}this.overridden[a]=!0;this.internalSet(a,c)}}};b.prototype.set=function(a,c){if(this.metadatas[a]){var d=
this.metadatas[a];if(!d.nonNullable||null!=c){var g=d.set;if(d=d.cast){c=this.cast(d,c);var d=c.valid,b=c.value;f.release(c);if(!d)return;c=b}g?g.call(this.host,c):this.internalSet(a,c)}}};b.prototype.setDefaultOrigin=function(c){this._origin=a.nameToId(c)};b.prototype.propertyInvalidated=function(a){var c=this.dirties,f=this.isOverridden(a),d=this.cursors&&this.cursors[a],g=this.metadatas[a].computes;if(d)for(var b=0;b<d.length;b++)d[b].propertyInvalidated(this,a);f||(c[a]=!0);if(g)for(a=0;a<g.length;a++)this.propertyInvalidated(g[a])};
b.prototype.propertyCommitted=function(a){var c=this.cursors&&this.cursors[a];this.dirties[a]=!1;if(c)for(var f=0;f<c.length;f++)c[f].propertyCommitted(this,a)};b.prototype.addCursor=function(a,c){this.cursors||(this.cursors={});var f=this.cursors[a];f||(this.cursors[a]=f=[]);f.push(c)};b.prototype.removeCursor=function(a,c){var f=this.cursors[a];this.cursors[a]&&(f.splice(f.indexOf(c),1),0===f.length&&(this.cursors[a]=null))};b.prototype.cast=function(a,c){var d=f.acquire();d.valid=!0;d.value=c;
a&&(d.value=a.call(this.host,c,d));return d};return b}();m=function(){function a(){this.value=null;this.valid=!0}a.prototype.acquire=function(){this.valid=!0};a.prototype.release=function(){this.value=null};return a}();var f=new l(m);e.default=b})},"esri/core/has":function(){define(["require","exports","dojo/sniff","./global","../views/webgl/context-util"],function(b,e,m,d,k){function l(){var a={available:!1,version:0,majorPerformanceCaveat:!1,supportsHighPrecisionFragment:!1,supportsVertexShaderSamplers:!1,
supportsElementIndexUint:!1,supportsStandardDerivatives:!1,supportsInstancedArrays:!1},c=document.createElement("canvas");if(!c)return a;var d=k.createContext(c,{failIfMajorPerformanceCaveat:!0},"webgl");!d&&(d=k.createContext(c,{},"webgl"))&&(a.majorPerformanceCaveat=!0);if(!d)return a;c=d.getParameter(d.VERSION);if(!c)return a;if(c=c.match(/^WebGL\s+([\d.]*)/))a.version=parseFloat(c[1]),a.available=.94<=a.version,c=d.getShaderPrecisionFormat(d.FRAGMENT_SHADER,d.HIGH_FLOAT),a.supportsHighPrecisionFragment=
c&&0<c.precision,a.supportsVertexShaderSamplers=0<d.getParameter(d.MAX_VERTEX_TEXTURE_IMAGE_UNITS),a.supportsElementIndexUint=null!==d.getExtension("OES_element_index_uint"),a.supportsStandardDerivatives=null!==d.getExtension("OES_standard_derivatives"),a.supportsInstancedArrays=null!==d.getExtension("ANGLE_instanced_arrays");return a}function h(){var a={available:!1,version:0},c=document.createElement("canvas");if(!c)return a;c=k.createContext(c,{},"webgl2");if(!c)return a;a.available=!0;c=c.getParameter(c.VERSION);
if(!c)return a;if(c=c.match(/^WebGL\s+([\d.]*)/))a.version=parseFloat(c[1]);return a}var a=null,c=null;(function(){var f=navigator.userAgent,b=f.match(/Android|webOS|iPhone|iPad|iPod|BlackBerry|Opera Mini|IEMobile/i),f=f.match(/iPhone/i);b&&m.add("esri-mobile",b);f&&m.add("esri-iPhone",f);m.add("esri-geolocation",function(){return!!navigator.geolocation});m.add("esri-canvas-svg-support",function(){return!(m("trident")||m("ie"))});m.add("esri-secure-context",function(){if("isSecureContext"in d)return d.isSecureContext;
if(d.location&&d.location.origin)return 0===d.location.origin.indexOf("https:")});m.add("esri-wasm","WebAssembly"in d);m("host-webworker")||(m.add("esri-workers","Worker"in d),m.add("esri-url-encodes-apostrophe",function(){var a=d.document.createElement("a");a.href="?'";return-1<a.href.indexOf("?%27")}),a||(a=l()),m.add("esri-webgl",a.available),m.add("esri-webgl-high-precision-fragment",a.supportsHighPrecisionFragment),m.add("esri-webgl-vertex-shader-samplers",a.supportsVertexShaderSamplers),m.add("esri-webgl-element-index-uint",
a.supportsElementIndexUint),m.add("esri-webgl-standard-derivatives",a.supportsStandardDerivatives),m.add("esri-webgl-instanced-arrays",a.supportsInstancedArrays),m.add("esri-webgl-major-performance-caveat",a.majorPerformanceCaveat),m.add("esri-featurelayer-webgl",!0),m.add("esri-featurelayer-webgl-labeling",!0),c||(c=h()),m.add("esri-webgl2",c.available))})();return m})},"esri/views/webgl/context-util":function(){define(["require","exports"],function(b,e){function m(d,a,c){void 0===a&&(a={});var f;
switch(c){case "webgl":f=["webgl","experimental-webgl","webkit-3d","moz-webgl"];break;case "webgl2":f=["webgl2"];break;default:f=["webgl","experimental-webgl","webkit-3d","moz-webgl"]}c=null;for(var b=0;b<f.length;b++){var g=f[b];try{c=d.getContext(g,a)}catch(q){}if(c)break}return c}function d(d,a){(d=d.parentNode)&&(d.innerHTML='\x3ctable style\x3d"background-color: #8CE; width: 100%; height: 100%;"\x3e\x3ctr\x3e\x3ctd align\x3d"center"\x3e\x3cdiv style\x3d"display: table-cell; vertical-align: middle;"\x3e\x3cdiv style\x3d""\x3e'+
a+"\x3c/div\x3e\x3c/div\x3e\x3c/td\x3e\x3c/tr\x3e\x3c/table\x3e")}Object.defineProperty(e,"__esModule",{value:!0});e.createContextOrErrorHTML=function(b,a,c){void 0===a&&(a={});if(!window.WebGLRenderingContext)return d(b,k),null;a=m(b,a,c);return a?a:(d(b,l),null)};e.createContext=m;var k='This page requires a browser that supports WebGL.\x3cbr/\x3e\x3ca href\x3d"http://get.webgl.org"\x3eClick here to upgrade your browser.\x3c/a\x3e',l='It doesn\'t appear your computer can support WebGL.\x3cbr/\x3e\x3ca href\x3d"http://get.webgl.org/troubleshooting/"\x3eClick here for more information.\x3c/a\x3e'})},
"esri/core/Logger":function(){define(["require","exports","./has"],function(b,e,m){var d={info:0,warn:1,error:2};b=function(){function b(d){void 0===d&&(d={});this.module=d.module||"";this.writer=d.writer||null;this.level=d.level||null;null!=d.enabled&&(this.enabled=!!d.enabled);b._loggers[this.module]=this;d=this.module.lastIndexOf(".");-1!==d&&(this.parent=b.getLogger(this.module.slice(0,d)))}b.prototype.log=function(d){for(var b=[],a=1;a<arguments.length;a++)b[a-1]=arguments[a];this._isEnabled()&&
this._matchLevel(d)&&(a=this._inheritedWriter())&&a.apply(void 0,[d,this.module].concat(b))};b.prototype.error=function(){for(var d=[],b=0;b<arguments.length;b++)d[b]=arguments[b];this.log.apply(this,["error"].concat(d))};b.prototype.warn=function(){for(var d=[],b=0;b<arguments.length;b++)d[b]=arguments[b];this.log.apply(this,["warn"].concat(d))};b.prototype.info=function(){for(var d=[],b=0;b<arguments.length;b++)d[b]=arguments[b];this.log.apply(this,["info"].concat(d))};b.prototype.getLogger=function(d){return b.getLogger(this.module+
"."+d)};b.getLogger=function(d){var e=b._loggers[d];e||(e=new b({module:d}));return e};b.prototype._parentWithMember=function(d,b){for(var a=this;a&&null==a[d];)a=a.parent;return a?a[d]:b};b.prototype._inheritedWriter=function(){return this._parentWithMember("writer",this._consoleWriter)};b.prototype._consoleWriter=function(d,b){for(var a=[],c=2;c<arguments.length;c++)a[c-2]=arguments[c];console[d].apply(console,["["+b+"]"].concat(a))};b.prototype._matchLevel=function(b){return d[this._parentWithMember("level",
"error")]<=d[b]};b.prototype._isEnabled=function(){return this._parentWithMember("enabled",!0)};b._loggers={};return b}();b.getLogger("esri").level="warn";return b})},"esri/core/ObjectPool":function(){define(["require","exports"],function(b,e){var m=function(){return function(){}}();return function(){function d(d,b,e,a,c){void 0===a&&(a=1);void 0===c&&(c=0);this.classConstructor=d;this.acquireFunctionOrWithConstructor=b;this.releaseFunction=e;this.growthSize=a;!0===b?this.acquireFunction=this._constructorAcquireFunction:
"function"===typeof b&&(this.acquireFunction=b);this._pool=Array(c);this._initialSize=c;for(d=0;d<c;d++)this._pool[d]=new this.classConstructor;this.growthSize=Math.max(a,1)}d.prototype.destroy=function(){this.prune(0);this._pool=null};d.prototype.acquire=function(){for(var d=[],b=0;b<arguments.length;b++)d[b]=arguments[b];b=this.classConstructor||m;if(0===this._pool.length)for(var e=this.growthSize,a=0;a<e;a++)this._pool[a]=new b;b=this._pool.pop();this.acquireFunction?this.acquireFunction.apply(this,
[b].concat(d)):b&&b.acquire&&"function"===typeof b.acquire&&b.acquire.apply(b,d);return b};d.prototype.release=function(d){d&&(this.releaseFunction?this.releaseFunction(d):d&&d.release&&"function"===typeof d.release&&d.release(),this._pool.push(d))};d.prototype.prune=function(d){void 0===d&&(d=this._initialSize);if(!(d>=this._pool.length)){for(var b=d;b<this._pool.length;++b)this._dispose(this._pool[b]);this._pool.length=d}};d.prototype._dispose=function(d){d.dispose&&"function"===typeof d.dispose&&
d.dispose()};d.prototype._constructorAcquireFunction=function(d){for(var b=[],e=1;e<arguments.length;e++)b[e-1]=arguments[e];var a;(a=this.classConstructor).call.apply(a,[d].concat(b))};return d}()})},"esri/core/accessorSupport/extensions":function(){define(["require","exports","./extensions/aliasedProperty","./extensions/computedProperty","./extensions/serializableProperty"],function(b,e,m,d,k){Object.defineProperty(e,"__esModule",{value:!0});var l=[m.default,d.default,k.default];e.processPrototypeMetadatas=
function(d,a){for(var c=0;c<l.length;c++){var f=l[c];if(f.processPrototypePropertyMetadata)for(var b in d)f.processPrototypePropertyMetadata(b,d[b],d,a)}};e.processClassMetadatas=function(d,a){for(var c=0;c<l.length;c++){var f=l[c];if(f.processClassPropertyMetadata)for(var b in d)f.processClassPropertyMetadata(b,d[b],d,a)}};e.instanceCreated=function(d,a){for(var c=Object.getOwnPropertyNames(a),f=0;f<l.length;f++){var b=l[f];b.instanceCreated&&b.instanceCreated(d,a,c)}}})},"esri/core/accessorSupport/extensions/aliasedProperty":function(){define("require exports ../../has ../get ../set ../utils ../wire".split(" "),
function(b,e,m,d,k,l,h){function a(a,f,d){var c=l.getProperties(a);return h.wire(a,d.aliasOf,function(){c.propertyInvalidated(f)})}Object.defineProperty(e,"__esModule",{value:!0});e.AliasedPropertyExtension={processClassPropertyMetadata:function(a,f,b,g){var c=f.aliasOf;if(c&&(a=c.split(".")[0],null!=b[a]&&!f.set&&!f.get)){var p;f.get=function(){var a=d.default(this,c);if("function"===typeof a){p||(p=c.split(".").slice(0,-1).join("."));var f=d.default(this,p);f&&(a=a.bind(f))}return a};f.readOnly||
(f.set=function(a){return k.default(this,c,a)})}},instanceCreated:function(c,f,d){for(var b=0;b<d.length;b++){var n=d[b],p=f[n];p.aliasOf&&a(c,n,p)}}};e.default=e.AliasedPropertyExtension})},"esri/core/accessorSupport/get":function(){define(["require","exports","./utils"],function(b,e,m){function d(a,c,f){a="?"===a[a.length-1]?a.slice(0,-1):a;if(null!=f.getItemAt||Array.isArray(f)){var d=parseInt(a,10);if(!isNaN(d))return Array.isArray(f)?f[d]:f.getItemAt(d)}d=m.getProperties(f);return c?m.isPropertyDeclared(d,
a)?d.get(a):f[a]:m.isPropertyDeclared(d,a)?d.internalGet(a):f[a]}function k(a,c,f,b){if(null==a)return a;if((a=d(c[b],f,a))||!(b<c.length-1))return b===c.length-1?a:k(a,c,f,b+1)}function l(a,c,f,b){void 0===f&&(f=!1);void 0===b&&(b=0);return"string"===typeof c&&-1===c.indexOf(".")?d(c,f,a):k(a,m.pathToArray(c),f,b)}function h(a,c){return l(a,c,!0)}Object.defineProperty(e,"__esModule",{value:!0});e.valueOf=l;e.get=h;e.exists=function(a,c){return void 0!==l(c,a,!0)};e.default=h})},"esri/core/accessorSupport/utils":function(){define(["require",
"exports","../lang"],function(b,e,m){function d(a,c,f){return c?Object.keys(c).reduce(function(a,b){var g=null,p="merge";f&&(g=f.path?f.path+"."+b:b,p=f.policy(g));if("replace"===p)return a[b]=c[b],a;if(void 0===a[b])return a[b]=m.clone(c[b]),a;var n=a[b],p=c[b];if(n===p)return a;if(Array.isArray(p)||Array.isArray(a))n=n?Array.isArray(n)?a[b]=n.concat():a[b]=[n]:a[b]=[],p&&(Array.isArray(p)||(p=[p]),p.forEach(function(a){-1===n.indexOf(a)&&n.push(a)}));else if(p&&"object"===typeof p)if(f){var e=f.path;
f.path=g;a[b]=d(n,p,f);f.path=e}else a[b]=d(n,p,null);else if(!a.hasOwnProperty(b)||c.hasOwnProperty(b))a[b]=p;return a},a||{}):a}function k(a){return Array.isArray(a)?a:a.split(".")}function l(a){if(Array.isArray(a)||-1<a.indexOf(",")){a=Array.isArray(a)?a:a.split(",");for(var c=0;c<a.length;c++)a[c]=a[c].trim();return 1===a.length?a[0]:a}return a.trim()}function h(a){var c=!1;return function(){c||(c=!0,a())}}Object.defineProperty(e,"__esModule",{value:!0});e.getProperties=function(a){return a?a.__accessor__?
a.__accessor__:a.propertyInvalidated?a:null:null};e.isPropertyDeclared=function(a,c){return a&&a.metadatas&&null!=a.metadatas[c]};e.merge=function(a,c,f){return f?d(a,c,{policy:f,path:""}):d(a,c,null)};e.pathToStringOrArray=function(a){return!a||"string"===typeof a&&-1===a.indexOf(".")?a:k(a)};e.pathToArray=k;e.splitPath=l;e.parseConditionalPath=function(a){if(-1===a.indexOf("?"))return null;a=k(a);for(var c=Array(a.length),f=0;f<a.length;f++){var d=a[f];c[f]="?"===d[d.length-1];c[f]&&(a[f]=d.slice(0,
-1))}return{fullPath:a.join("."),conditional:c}};e.parse=function(a,c,f,d){c=l(c);if(Array.isArray(c)){var b=c.map(function(c){return d(a,c.trim(),f)});return{remove:h(function(){return b.forEach(function(a){return a.remove()})})}}return d(a,c.trim(),f)};e.once=h})},"esri/core/accessorSupport/set":function(){define(["require","exports","../has","../Logger","./get"],function(b,e,m,d,k){function l(d,a,c){if(d&&a)if("object"===typeof a){c=0;for(var f=Object.getOwnPropertyNames(a);c<f.length;c++){var b=
f[c];l(d,b,a[b])}}else"_"!==a[0]&&(-1!==a.indexOf(".")?(a=a.split("."),b=a.splice(a.length-1,1)[0],l(k.default(d,a),b,c)):d[a]=c)}Object.defineProperty(e,"__esModule",{value:!0});d.getLogger("esri.core.accessorSupport.set");e.set=l;e.default=l})},"esri/core/accessorSupport/wire":function(){define(["require","exports","./utils"],function(b,e,m){function d(f,d,b){d=m.splitPath(d);if(Array.isArray(d)){for(var g=[],p=0;p<d.length;p++)g.push((new k(d[p],b)).install(f));return new a(g)}f=(new k(d,b)).install(f);
return new c(f)}Object.defineProperty(e,"__esModule",{value:!0});var k=function(){function a(a,c){this.path=a;this.callback=c;this.conditional=this.chain=null;if(-1<a.indexOf(".")){if(a=m.parseConditionalPath(a))this.path=a.fullPath,this.conditional=a.conditional;this.chain=m.pathToArray(this.path)}else"?"===a[a.length-1]&&(this.path=a.slice(0,a.length-1),this.conditional=[!0],this.chain=[this.path]);this.callback=c;return this}a.prototype.install=function(a){a=this.chain?new h(this,a):new l(this,
a);return a};a.prototype.notify=function(a){this.callback(a,this.path)};return a}(),l=function(){function a(a,c){this.binding=a;this.target=c;m.getProperties(c).addCursor(this.binding.path,this)}a.prototype.destroy=function(){this.target&&(m.getProperties(this.target).removeCursor(this.binding.path,this),this.target=this.binding=null)};a.prototype.propertyDestroyed=function(a,c){m.getProperties(this.target).removeCursor(c,this)};a.prototype.propertyInvalidated=function(a,c){this.binding&&this.binding.notify(this.target)};
a.prototype.propertyCommitted=function(a,c){this.binding&&this.binding.notify(this.target)};return a}(),h=function(){function a(a,c){this.binding=a;this.target=c;this.stack=[];this.properties=m.getProperties(c);this.stack.push({properties:this.properties,propertyName:a.chain[0]});this.properties.addCursor(a.chain[0],this);this.moveForward();return this}a.prototype.destroy=function(){for(;;){var a=this.stack.pop();if(null==a)break;a.properties.removeCursor(a.propertyName,this)}this.target=this.binding=
null};a.prototype.propertyDestroyed=function(a,c){this.moveBackward(a,c)};a.prototype.propertyInvalidated=function(a,c){this.binding&&this.binding.notify(this.target)};a.prototype.propertyCommitted=function(a,c){this.binding&&(this.moveBackward(a,c),this.moveForward(),this.binding.notify(this.target))};a.prototype.moveBackward=function(a,c){for(var f=this.stack,d=f[f.length-1];d.properties!==a&&d.propertyName!==c;)d.properties.removeCursor(d.propertyName,this),f.pop(),d=f[f.length-1]};a.prototype.moveForward=
function(){var a=this.stack,c=a[a.length-1];if(1!==a.length||!this.binding.conditional||!this.binding.conditional[a.length-1]||c.properties.metadatas[c.propertyName])if(c=c.properties.internalGet(c.propertyName),(c=m.getProperties(c))&&a.length<this.binding.chain.length){var f=this.binding.chain[a.length];this.binding.conditional&&this.binding.conditional[a.length]&&!c.metadatas[f]||(this.stack.push({properties:c,propertyName:f}),c.addCursor(f,this),this.moveForward())}};return a}(),a=function(){function a(a){this.cursors=
a}a.prototype.remove=function(){for(var a=this.cursors;0<a.length;)a.pop().destroy();this.cursors=null};return a}(),c=function(){function a(a){this.cursor=a}a.prototype.remove=function(){this.cursor.destroy();this.cursor=null};return a}();e.create=function(f,d){f=m.splitPath(f);if(Array.isArray(f)){for(var b=[],e=0;e<f.length;e++)b.push(new k(f[e],d));return function(c){for(var f=[],d=0;d<b.length;d++)f[d]=b[d].install(c);return new a(f)}}var p=new k(f,d);return function(a){return new c(p.install(a))}};
e.wire=d;e.default=d})},"esri/core/accessorSupport/extensions/computedProperty":function(){define("require exports ../../has ../../Logger ../utils ../wire".split(" "),function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});d.getLogger("esri.core.accessorSupport.extensions.computedProperty");e.ComputedPropertyExtension={processClassPropertyMetadata:function(d,a,c,f){a.dependsOn&&(c=void 0,c=a.dependsOn.slice())&&(a.wire=l.create(c,function(a){return k.getProperties(a).propertyInvalidated(d)}))},
instanceCreated:function(d,a,c){for(var f=0;f<c.length;f++){var b=a[c[f]];b.wire&&b.wire(d)}}};e.default=e.ComputedPropertyExtension})},"esri/core/accessorSupport/extensions/serializableProperty":function(){define("require exports ../ensureType ./serializableProperty/originAliases ./serializableProperty/reader ./serializableProperty/shorthands ./serializableProperty/writer".split(" "),function(b,e,m,d,k,l,h){function a(a,f,d){var c=a&&a.json;a&&a.json&&a.json.origins&&d&&(a=a.json.origins[d.origin])&&
f in a&&(c=a);return c}Object.defineProperty(e,"__esModule",{value:!0});e.originSpecificReadPropertyDefinition=function(c,f){return a(c,"read",f)};e.originSpecificWritePropertyDefinition=function(c,f){return a(c,"write",f)};e.SerializablePropertyExtension={processPrototypePropertyMetadata:function(a,f,b,g){if(l.process(f)){d.process(f);b=f.type;for(g=0;Array.isArray(b)&&!m.isOneOf(b);)b=b[0],g++;if(f.json.origins)for(var c in f.json.origins){var p=f.json.origins[c];k.create(b,g,a,p);h.create(b,g,
a,p)}k.create(b,g,a,f.json);h.create(b,g,a,f.json)}}};e.default=e.SerializablePropertyExtension})},"esri/core/accessorSupport/ensureType":function(){define(["require","exports","../Logger"],function(b,e,m){function d(a,c){return c.isInstanceOf?c.isInstanceOf(a):c instanceof a}function k(a){return null==a?a:new Date(a)}function l(a){return null==a?a:!!a}function h(a){return null==a?a:a.toString()}function a(a){return null==a?a:"number"===typeof a&&isNaN(a)?0:parseFloat(a)}function c(a){return null==
a?a:Math.round(parseFloat(a))}function f(a){return a&&a.constructor&&void 0!==a.constructor._meta}function n(a,c){return null!=c&&a&&!d(a,c)}function g(a){return a&&("isCollection"in a||a._meta&&a._meta.bases&&a._meta.bases.some(function(a){return"isCollection"in a}))}function q(a){return a&&a.Type?"function"===typeof a.Type?a.Type:a.Type.base:null}function p(a,c){if(!c||!c.constructor||!g(c.constructor))return t(a,c)?c:new a(c);var f=q(a.prototype.itemType),d=q(c.constructor.prototype.itemType);
if(!f)return c;if(!d)return new a(c);if(f===d)return c;if((d=d._meta&&d._meta.bases)&&-1!==d.indexOf(f))return new a(c);t(a,c);return c}function t(a,c){return f(c)?(B.error("Accessor#set","Assigning an instance of '"+(c.declaredClass||"unknown")+"' which is not a subclass of '"+(a&&a.prototype&&a.prototype.declaredClass||"unknown")+"'"),!0):!1}function r(a,c){return null==c?c:g(a)?p(a,c):n(a,c)?t(a,c)?c:new a(c):c}function v(f){switch(f){case Number:return a;case F:return c;case Boolean:return l;
case String:return h;case Date:return k;default:return r.bind(null,f)}}function u(a,c){var f=v(a);return 1===arguments.length?f:f(c)}function z(a,c){return 1===arguments.length?z.bind(null,a):c?Array.isArray(c)?c.map(a):[a(c)]:c}function y(a,c,f){return 0!==c&&Array.isArray(f)?f.map(function(f){return y(a,c-1,f)}):a(f)}function x(a,c,f){if(2===arguments.length)return x.bind(null,a,c);if(!f)return f;f=y(a,c,f);for(var d=c,b=f;0<d&&Array.isArray(b);)d--,b=b[0];if(void 0!==b)for(b=0;b<d;b++)f=[f];return f}
function w(a,c){if(2===arguments.length)return w(a).call(null,c);for(var f=new Set,d=0;d<a.length;d++)f.add(a[d]);var b=null;return function(c,d){if(null==c)return c;f.has(c)||(b||(b=a.map(function(a){return"string"===typeof a?"'"+a+"'":""+a}).join(", ")),B.error("Accessor#set","'"+c+"' is not a valid value for this property, only the following values are valid: "+b),d&&(d.valid=!1));return c}}function A(a,c){if(2===arguments.length)return A(a).call(null,c);var d={},b=[],g=[],p;for(p in a.typeMap){var e=
a.typeMap[p];d[p]=u(e);b.push(e&&e.prototype&&e.prototype.declaredClass||"unknown");g.push(p)}var h="string"===typeof a.key?function(c){return c[a.key]}:a.key;return function(c){if(a.base&&!n(a.base,c))return c;var p=h(c)||a.defaultKeyValue,e=d[p];if(!e)return B.error("Accessor#set","Invalid property value, value needs to be one of "+("'"+b.join("', '")+"'")+", or a plain object that can autocast (having .type \x3d "+("'"+g.join("', '")+"'")+")"),null;if(!n(a.typeMap[p],c))return c;if("string"===
typeof a.key&&!f(c)){var p={},t;for(t in c)t!==a.key&&(p[t]=c[t]);return e(p)}return e(c)}}Object.defineProperty(e,"__esModule",{value:!0});var B=m.getLogger("esri.core.Accessor");e.isInstanceOf=d;e.ensureDate=k;e.ensureBoolean=l;e.ensureString=h;e.ensureNumber=a;e.ensureInteger=c;e.isClassedType=f;e.requiresType=n;e.ensureClass=r;e.ensureType=u;e.ensureArrayTyped=z;e.ensureArray=function(a,c){return 1===arguments.length?z(u.bind(null,a)):z(u.bind(null,a),c)};e.ensureNArrayTyped=x;e.ensureNArray=
function(a,c,f){return 2===arguments.length?x(u.bind(null,a),c):x(u.bind(null,a),c,f)};e.isOneOf=function(a){if(!Array.isArray(a))return!1;a=typeof a[0];return"string"===a||"number"===a};e.ensureOneOf=w;e.ensureOneOfType=A;var F=function(){return function(){}}();e.Integer=F;e.default=u})},"esri/core/accessorSupport/extensions/serializableProperty/originAliases":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.process=function(b){if(b.json&&b.json.origins){var d=
b.json.origins,e={"web-document":["web-scene","web-map"]};b=function(b){if(d[b]){var a=d[b];e[b].forEach(function(c){d[c]=a});delete d[b]}};for(var l in e)b(l)}}})},"esri/core/accessorSupport/extensions/serializableProperty/reader":function(){define(["require","exports","../../../object","./type"],function(b,e,m,d){function k(d,b,p,e){if(1<b)return a(d,b);if(1===b)return c(d);if(f(d)){var g=c(d.prototype.itemType.Type);return function(a,c,f){return(a=g(a,c,f))?new d(a):a}}return l(d)}function l(a){return a.prototype.read?
function(c,f,d){if(null==c)return c;f=new a;f.read(c,d);return f}:a.fromJSON}function h(a,c,f,d){return 0!==d&&Array.isArray(c)?c.map(function(c){return h(a,c,f,d-1)}):a(c,null,f)}function a(a,c){a=l(a);var f=h.bind(null,a);return function(a,d,b){if(null==a)return a;a=f(a,b,c);d=c;for(b=a;0<d&&Array.isArray(b);)d--,b=b[0];if(void 0!==b)for(b=0;b<d;b++)a=[a];return a}}function c(a){var c=l(a);return function(a,f,d){return null==a?a:Array.isArray(a)?a.map(function(a){return c(a,null,d)}):[c(a,null,
d)]}}function f(a){return d.isCollection(a)?(a=a.prototype.itemType)&&a.Type&&"function"===typeof a.Type?n(a.Type):!1:!1}function n(a){return Array.isArray(a)?!1:!!a&&a.prototype&&("read"in a.prototype||"fromJSON"in a||f(a))}Object.defineProperty(e,"__esModule",{value:!0});e.create=function(a,c,f,d){(!d.read||!d.read.reader&&!1!==d.read.enabled)&&n(a)&&m.setDeepValue("read.reader",k(a,c,f,d),d)}})},"esri/core/object":function(){define(["require","exports"],function(b,e){function m(d,b,e){for(var h=
0;h<d.length;h++){var a=d[h];if(null==e)return;if(!(a in e))if(b)e[a]={};else return;e=e[a]}return e}Object.defineProperty(e,"__esModule",{value:!0});e.getDeepValue=function(d,b){return m(d.split("."),!1,b)};e.setDeepValue=function(d,b,e){var h=d.split(".");d=h.pop();(e=m(h,!0,e))&&d&&(e[d]=b)}})},"esri/core/accessorSupport/extensions/serializableProperty/type":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.isCollection=function(b){return!!b&&
b.prototype&&b.prototype.declaredClass&&0===b.prototype.declaredClass.indexOf("esri.core.Collection")}})},"esri/core/accessorSupport/extensions/serializableProperty/shorthands":function(){define(["require","exports"],function(b,e){function m(d){"boolean"===typeof d.read?d.read={enabled:d.read}:"function"===typeof d.read?d.read={enabled:!0,reader:d.read}:d.read&&"object"===typeof d.read&&void 0===d.read.enabled&&(d.read.enabled=!0)}function d(d){"boolean"===typeof d.write?d.write={enabled:d.write}:
"function"===typeof d.write?d.write={enabled:!0,writer:d.write}:d.write&&"object"===typeof d.write&&void 0===d.write.enabled&&(d.write.enabled=!0)}Object.defineProperty(e,"__esModule",{value:!0});e.process=function(b){b.json||(b.json={});m(b.json);d(b.json);if(b.json.origins)for(var e in b.json.origins)m(b.json.origins[e]),d(b.json.origins[e]);return!0}})},"esri/core/accessorSupport/extensions/serializableProperty/writer":function(){define(["require","exports","../../../object","./type"],function(b,
e,m,d){function k(a,c,d,b){m.setDeepValue(d,l(a,b),c)}function l(a,c){return a&&"function"===typeof a.write?a.write({},c):a&&"function"===typeof a.toJSON?a.toJSON():"number"===typeof a?-Infinity===a?-Number.MAX_VALUE:Infinity===a?Number.MAX_VALUE:isNaN(a)?null:a:a}function h(a,c,d,b){null===a?a=null:a&&"function"===typeof a.map?(a=a.map(function(a){return l(a,b)}),"function"===typeof a.toArray&&(a=a.toArray())):a=[l(a,b)];m.setDeepValue(d,a,c)}function a(c,d,b){return 0!==b&&Array.isArray(c)?c.map(function(c){return a(c,
d,b-1)}):l(c,d)}function c(c){return function(f,d,b,p){if(null===f)f=null;else{f=a(f,p,c);p=c;for(var g=f;0<p&&Array.isArray(g);)p--,g=g[0];if(void 0!==g)for(g=0;g<p;g++)f=[f]}m.setDeepValue(b,f,d)}}Object.defineProperty(e,"__esModule",{value:!0});e.create=function(a,b,g,e){e.write&&!e.write.writer&&!1!==e.write.enabled&&(1===b||d.isCollection(a)?e.write.writer=h:e.write.writer=1<b?c(b):k)}})},"esri/core/accessorSupport/PropertyOrigin":function(){define(["require","exports"],function(b,e){function m(d){switch(d){case "defaults":return k.DEFAULTS;
case "service":return k.SERVICE;case "portal-item":return k.PORTAL_ITEM;case "web-scene":return k.WEB_SCENE;case "web-map":return k.WEB_MAP;case "user":return k.USER}}function d(d){switch(d){case k.DEFAULTS:return"defaults";case k.SERVICE:return"service";case k.PORTAL_ITEM:return"portal-item";case k.WEB_SCENE:return"web-scene";case k.WEB_MAP:return"web-map";case k.USER:return"user"}}Object.defineProperty(e,"__esModule",{value:!0});var k;(function(d){d[d.DEFAULTS=0]="DEFAULTS";d[d.COMPUTED=1]="COMPUTED";
d[d.SERVICE=2]="SERVICE";d[d.PORTAL_ITEM=3]="PORTAL_ITEM";d[d.WEB_SCENE=4]="WEB_SCENE";d[d.WEB_MAP=5]="WEB_MAP";d[d.USER=6]="USER";d[d.NUM=7]="NUM"})(k=e.OriginId||(e.OriginId={}));e.nameToId=m;e.idToName=d;e.readableNameToId=function(d){return m(d)};e.idToReadableName=function(b){return d(b)};e.writableNameToId=function(d){return m(d)};e.idToWritableName=function(b){return d(b)}})},"esri/core/accessorSupport/Store":function(){define(["require","exports","./PropertyOrigin"],function(b,e,m){Object.defineProperty(e,
"__esModule",{value:!0});b=function(){function d(){this._values={}}d.prototype.get=function(d){return this._values[d]};d.prototype.originOf=function(d){return m.OriginId.USER};d.prototype.keys=function(){return Object.keys(this._values)};d.prototype.set=function(d,b){this._values[d]=b};d.prototype.clear=function(d){delete this._values[d]};d.prototype.has=function(d){return d in this._values};return d}();e.default=b})},"esri/core/accessorSupport/introspection":function(){define("require exports ./ensureType ./extensions ./metadata ./utils ./decorators/cast".split(" "),
function(b,e,m,d,k,l,h){function a(a,f){return function(c){c=+a(c);null!=f.min&&(c=Math.max(f.min,c));null!=f.max&&(c=Math.min(f.max,c));return c}}Object.defineProperty(e,"__esModule",{value:!0});e.processPrototype=function(c){var f=c.declaredClass,b=c.properties||{},g;for(g in b){var e=b[g],p=typeof e;null==e?k.setPropertyMetadata(c,g,{value:e}):Array.isArray(e)?k.setPropertyMetadata(c,g,{type:[e[0]],value:null}):"object"===p?l.getProperties(e)||e instanceof Date?k.setPropertyMetadata(c,g,{type:e.constructor,
value:e}):k.setPropertyMetadata(c,g,e):"boolean"===p?k.setPropertyMetadata(c,g,{type:Boolean,value:e}):"string"===p?k.setPropertyMetadata(c,g,{type:String,value:e}):"number"===p?k.setPropertyMetadata(c,g,{type:Number,value:e}):"function"===p&&k.setPropertyMetadata(c,g,{type:e,value:null})}c=k.getPropertiesMetadata(c);for(g in c){b=c[g];p=b.type;e=b.types;if(!b.cast)if(p){for(var e=b,h=0,r=p;Array.isArray(r)&&1===r.length&&"string"!==typeof r[0]&&"number"!==typeof r[0];)r=r[0],h++;p=m.isOneOf(r)?0===
h?m.ensureOneOf(r):m.ensureNArrayTyped(m.ensureOneOf(r),h):1===h?m.ensureArray(r):1<h?m.ensureNArray(r,h):m.ensureType(p);e.cast=p}else e&&(Array.isArray(e)?b.cast=m.ensureArrayTyped(m.ensureOneOfType(e[0])):b.cast=m.ensureOneOfType(e));b.range&&(b.cast=a(b.cast,b.range))}d.processPrototypeMetadatas(c,f);return c};e.processClass=function(a){for(var c=a.prototype,b=c.declaredClass,g=a._meta.bases,e={},p=g.length-1;0<=p;p--)k.merge(e,k.getMetadata(g[p].prototype));var t=e.properties;d.processClassMetadatas(t,
b);Object.defineProperty(a,"__accessorMetadata__",{value:{properties:t,autoDestroy:!!e.autoDestroy}});for(var r={},b=function(a){var c=t[a];r[a]={enumerable:!0,configurable:!0,get:function(){return this.__accessor__?this.__accessor__.get(a):c.value},set:function(f){var d=this.__accessor__;if(!d)Object.defineProperty(this,a,{enumerable:!0,configurable:!0,writable:!0,value:f});else if(!Object.isFrozen(this)){if(d.initialized&&c.readOnly)throw new TypeError("[accessor] cannot assign to read-only property '"+
a+"' of "+this.declaredClass);if(2===d.lifecycle&&c.constructOnly)throw new TypeError("[accessor] cannot assign to construct-only property '"+a+"' of "+this.declaredClass);d.set(a,f)}}}},g=0,p=Object.getOwnPropertyNames(t);g<p.length;g++)b(p[g]);Object.defineProperties(a.prototype,r);if(e.parameters)for(a=0,b=Object.getOwnPropertyNames(e.parameters);a<b.length;a++)g=b[a],p=Object.getOwnPropertyDescriptor(c,g)||{value:c[g]},(p=h.autocastMethod(c,g,p))&&Object.defineProperty(c,g,p);return e}})},"esri/core/accessorSupport/metadata":function(){define(["require",
"exports","./utils"],function(b,e,m){function d(a){return null!=a.__accessorMetadata__}function k(a){return d(a)&&null!=l(a).properties}function l(a){a.__accessorMetadata__||Object.defineProperty(a,"__accessorMetadata__",{value:{},enumerable:!0,configurable:!0,writable:!0});return a.__accessorMetadata__}function h(a){a=l(a);var c=a.properties;c||(c=a.properties={});return c}function a(a,c){var f=l(a);a=f.parameters;a||(a=f.parameters={});f=a[c];f||(f=[],a[c]=f);return f}function c(a){return n.test(a)?
"replace":"merge"}function f(a){return g.test(a)?c(a.slice(11)):"merge"}Object.defineProperty(e,"__esModule",{value:!0});e.hasMetadata=d;e.hasPropertiesMetadata=k;e.hasPropertyMetadata=function(a,c){return k(a)&&null!=h(a)[c]};e.hasParametersMetadata=function(a,c){return d(a)&&null!=l(a).parameters&&null!=l(a).parameters[c]};e.getMetadata=l;e.getPropertiesMetadata=h;e.getPropertyMetadata=function(a,c){a=h(a);var f=a[c];f||(f=a[c]={});return f};e.setPropertyMetadata=function(a,c,f){h(a)[c]=f};e.getParametersMetadata=
a;e.getParameterMetadata=function(c,f,d){var b=a(c,f)[d];b||(a(c,f)[d]=b={index:d});return b};e.merge=function(a,c){return m.merge(a,c,f)};e.mergeProperty=function(a,f){return m.merge(a,f,c)};var n=/^[^.]+\.(?:value|type|(?:json\.type|json\.origins\.[^.]\.type))$/,g=/^properties\./})},"esri/core/accessorSupport/decorators/cast":function(){define(["require","exports","../ensureType","../metadata"],function(b,e,m,d){function k(a){var c="_meta"in a?m.ensureType(a):a;return function(){for(var a=[],f=
0;f<arguments.length;f++)a[f]=arguments[f];a.push(c);return"number"===typeof a[2]?h.apply(this,a):l.apply(this,a)}}function l(a,c,b,e){d.getPropertyMetadata(a,c).cast=e}function h(a,c,b,e){d.getParameterMetadata(a,c,b).cast=e}function a(a){return function(c,f,b){d.getPropertyMetadata(c,a).cast=c[f]}}Object.defineProperty(e,"__esModule",{value:!0});var c=Object.prototype.toString;e.autocastMethod=function(a,c,b){if(d.hasParametersMetadata(a,c)){var f=d.getParametersMetadata(a,c).filter(function(a){return null!=
a.cast});if(f.length){var g=b.value;b.value=function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];for(c=0;c<f.length;c++){var d=f[c];a[d.index]=d.cast(a[d.index])}return g.apply(this,a)};return b}console.warn("Method "+a.declaredClass+"::"+c+" is decorated with @cast but no parameters are decorated")}};e.cast=function(){for(var f=[],d=0;d<arguments.length;d++)f[d]=arguments[d];if(3!==f.length||"string"!==typeof f[1]){if(1===f.length&&"[object Function]"===c.call(f[0]))return k(f[0]);
if(1===f.length&&"string"===typeof f[0])return a(f[0])}}})},"esri/core/accessorSupport/watch":function(){define("require exports ../ArrayPool ../lang ../ReentrantObjectPool ../scheduling ./get ./utils ./wire".split(" "),function(b,e,m,d,k,l,h,a,c){function f(a){u.has(a)?z.splice(z.indexOf(a),1):u.add(a);z.push(a);y||(y=l.schedule(g))}function n(a){if(!a.removed){var c=a.callback,f=a.path,b=a.oldValue,g=a.target,p=h.valueOf(g,a.propertyPath,!0);d.equals(b,p)||(a.oldValue=p,c.call(g,p,b,f,g))}}function g(){if(y){y=
null;var a=z;z=v.acquire();u.clear();for(var c=v.acquire(),f=0;f<a.length;f++){var d=a[f];n(d);d.removed&&c.push(d)}for(f=0;f<z.length;f++)d=z[f],d.removed&&(c.push(d),u.delete(d),z.splice(f,1),--f);for(f=0;f<c.length;f++)r.pool.release(c[f]);v.release(a);v.release(c);x.forEach(function(a){return a()})}}function q(d,b,g){var p=a.parse(d,b,g,function(d,b,g){var e=h.valueOf(d,b,!0),n,t=c.wire(d,b,function(a,c){a.__accessor__.destroyed?p.remove():(n||(n=r.pool.acquire(a,c,e,g),e=null),f(n))});return{remove:a.once(function(){t.remove();
n&&(n.removed=!0,f(n),n=null);p=t=e=null})}});return p}function p(f,b,g){var p=a.parse(f,b,g,function(a,f,b){var g=h.valueOf(a,f,!0),e=!1;return c.wire(a,f,function(a,c){if(a.__accessor__.destroyed)p.remove();else if(!e){e=!0;var f=h.valueOf(a,c,!0);d.equals(g,f)||b.call(a,f,g,c,a);g=h.valueOf(a,c,!0);e=!1}})});return p}function t(a,c,f,d){void 0===d&&(d=!1);return!a.__accessor__||a.__accessor__.destroyed?{remove:function(){}}:d?p(a,c,f):q(a,c,f)}Object.defineProperty(e,"__esModule",{value:!0});var r=
function(){function c(c,f,d,b){this.target=c;this.path=f;this.oldValue=d;this.callback=b;this.removed=!1;this.propertyPath=a.pathToStringOrArray(f)}c.prototype.release=function(){this.target=this.path=this.propertyPath=this.callback=this.oldValue=null;this.removed=!0};c.pool=new k.ReentrantObjectPool(c,!0);return c}(),v=new m,u=new Set,z=v.acquire(),y;e.dispatchTarget=function(a){for(var c=v.copy(z),f=0;f<c.length;f++){var d=c[f];d.target===a&&(n(d),u.delete(d),z.splice(z.indexOf(d),1))}};e.removeTarget=
function(a){for(var c=0;c<z.length;c++){var f=z[c];f.target===a&&(f.removed=!0)}};e.dispatch=g;var x=new Set;e.afterDispatch=function(a){x.add(a);return{remove:function(){x.delete(a)}}};e.watch=t;e.isValueInUse=function(a){return z.some(function(c){return c.oldValue===a})};e.default=t})},"esri/core/ArrayPool":function(){define(["require","exports","./ObjectPool"],function(b,e,m){function d(d){d.length=0}var k=Array.prototype.splice;b=function(){function b(a,c){void 0===a&&(a=50);void 0===c&&(c=50);
this._pool=new m(Array,!1,d,c,a)}b.prototype.acquire=function(){return this._pool.acquire()};b.prototype.copy=function(a){var c=this.acquire();a.unshift(0,0);k.apply(c,a);a.splice(0,2);return c};b.prototype.release=function(a){this._pool.release(a)};b.acquire=function(){return l.acquire()};b.copy=function(a){return l.copy(a)};b.release=function(a){return l.release(a)};return b}();var l=new b(100);return b})},"esri/core/ReentrantObjectPool":function(){define(["require","exports","./tsSupport/extendsHelper",
"./ObjectPool"],function(b,e,m,d){Object.defineProperty(e,"__esModule",{value:!0});b=function(d){function b(){var b=null!==d&&d.apply(this,arguments)||this;b._set=new Set;return b}m(b,d);b.prototype.destroy=function(){d.prototype.destroy.call(this);this._set=null};b.prototype.acquire=function(){for(var b=[],a=0;a<arguments.length;a++)b[a]=arguments[a];b=d.prototype.acquire.apply(this,b);this._set.delete(b);return b};b.prototype.release=function(b){b&&!this._set.has(b)&&(d.prototype.release.call(this,
b),this._set.add(b))};b.prototype._dispose=function(b){this._set.delete(b);d.prototype._dispose.call(this,b)};return b}(d);e.ReentrantObjectPool=b})},"esri/core/scheduling":function(){define(["require","exports","./nextTick","./now","./requestAnimationFrame"],function(b,e,m,d,k){function l(a){void 0===a&&(a=e.now());e.debug.rafId=null;0<z.length&&(e.debug.rafId=h());0<q&&(t=Math.min(a-q,t));e.debug.executeFrameTasks(a)}function h(){return e.debug.requestNextFrame?e.debug.requestNextFrame(f):f()}function a(){for(var a=
0;a<z.length;){var c=z[a];a++;if(c.removed){z.splice(a-1,1);for(var f=0;f<v.length;f++){var d=v[f];if(c.phases[d]){var d=y[d],b=d.indexOf(c);-1!==b&&d.splice(b,1)}}}}}function c(){for(;u.length;){var a=u.shift();a.isActive&&(a.isActive=!1,a.callback())}e.debug.willDispatch=!1}function f(){return k(l)}Object.defineProperty(e,"__esModule",{value:!0});e.now=d;var n=function(){return function(a){this.phases=a;this.paused=!1;this.pausedAt=0;this.epoch=-1;this.dt=0;this.ticks=-1;this.removed=!1}}(),g=function(){function a(a){this.callback=
a;this.isActive=!0}a.prototype.remove=function(){this.isActive=!1};return a}(),q=-1,p=0,t=Number.POSITIVE_INFINITY,r={time:0,deltaTime:0,tickTime:0,elapsedFrameTime:0,frameDuration:0,spendInTask:0},v=["prepare","preRender","render","postRender","update"],u=[],z=[],y={prepare:[],preRender:[],render:[],postRender:[],update:[]},x=function(){function a(a){this._task=a}a.prototype.remove=function(){this._task.removed=!0};a.prototype.pause=function(){this._task.paused||(this._task.paused=!0,this._task.pausedAt=
e.now())};a.prototype.resume=function(){this._task.paused&&(this._task.paused=!1,-1!==this._task.epoch&&(this._task.epoch+=e.now()-this._task.pausedAt))};return a}();e.FrameTaskHandle=x;e.debug={frameTasks:z,rafId:null,requestNextFrame:null,willDispatch:!1,clearFrameTasks:function(c){void 0===c&&(c=!1);for(var f=0;f<z.length;f++)z[f].removed=!0;c&&a()},dispatch:c,executeFrameTasks:function(c){void 0===c&&(c=e.now());0>q&&(q=c);var f=c-q,d=0<p?p:t,b=Math.max(0,f-d);q=c;for(var g=0;g<z.length;g++){var h=
z[g];-1!==h.epoch&&(h.dt=f)}for(g=0;g<v.length;g++)for(var f=v[g],n=y[f],l=0;l<n.length;l++)h=n[(l+w)%n.length],h.paused||h.removed||(0===g&&h.ticks++,-1===h.epoch&&(h.epoch=c),r.time=c,r.deltaTime=h.dt,r.tickTime=Math.min(t,33),r.elapsedFrameTime=e.now()-c,r.frameDuration=d-b,r.spendInTask=c-h.epoch,h.phases[f].call(h,r));a();++w}};e.schedule=function(a){a=new g(a);u.push(a);e.debug.willDispatch||(e.debug.willDispatch=!0,m(c));return a};e.addFrameTask=function(a){var c=new n(a);z.push(c);for(var f=
0,d=v;f<d.length;f++){var b=d[f];a[b]&&y[b].push(c)}e.debug.rafId||(q=-1,e.debug.rafId=h());return new x(c)};e.setFrameDuration=function(a){p=Math.max(0,a)};var w=0;e.requestNextFrame=h})},"esri/core/nextTick":function(){define(["require","exports","./global"],function(b,e,m){function d(){if(m.postMessage&&!m.importScripts){var a=m.onmessage,c=!0;m.onmessage=function(){c=!1};m.postMessage("","*");m.onmessage=a;return c}return!1}function k(f){a.push(f);1===a.length&&h(function(){for(var f=0,d=c;f<
d.length;f++)(0,d[f])();f=a.slice();for(d=a.length=0;d<f.length;d++)(0,f[d])()})}var l=m.MutationObserver||m.WebKitMutationObserver,h=function(){if(m.process&&m.process.nextTick)return function(a){m.process.nextTick(a)};if(m.Promise)return function(a){m.Promise.resolve().then(a)};if(l){var a=[],c=document.createElement("div");(new l(function(){for(;0<a.length;)a.shift()()})).observe(c,{attributes:!0});return function(f){a.push(f);c.setAttribute("queueStatus","1")}}if(d()){var b=[];m.addEventListener("message",
function(a){if(a.source===m&&"esri-nexttick-message"===a.data)for(a.stopPropagation();b.length;)b.shift()()},!0);return function(a){b.push(a);m.postMessage("esri-nexttick-message","*")}}return m.setImmediate?function(a){return m.setImmediate(a)}:function(a){return m.setTimeout(a,0)}}(),a=[],c=[];(function(a){a.before=function(a){c.push(a);return{remove:function(){c=c.filter(function(c){return c!==a})}}}})(k||(k={}));return k})},"esri/core/now":function(){define(["require","exports","./global"],function(b,
e,m){return function(){var d=m.performance||{};if(d.now)return function(){return d.now()};if(d.webkitNow)return function(){return d.webkitNow()};if(d.mozNow)return function(){return d.mozNow()};if(d.msNow)return function(){return d.msNow()};if(d.oNow)return function(){return d.oNow()};var b;b=d.timing&&d.timing.navigationStart?d.timing.navigationStart:Date.now();return function(){return Date.now()-b}}()})},"esri/core/requestAnimationFrame":function(){define(["require","exports","./global","./now"],
function(b,e,m,d){var k=d();b=m.requestAnimationFrame;if(!b){e=["ms","moz","webkit","o"];for(var l=0;l<e.length&&!b;++l)b=m[e[l]+"RequestAnimationFrame"];b||(b=function(b){var a=d(),c=Math.max(0,16-(a-k)),f=m.setTimeout(function(){b(d())},c);k=a+c;return f})}return b})},"esri/core/Evented":function(){define(["require","exports","./tsSupport/extendsHelper","@dojo/framework/shim/Map"],function(b,e,m,d){var k=function(){function b(d){this.target=d}b.prototype.emit=function(d,a){var c=this;d=this._listenersMap&&
this._listenersMap.get(d);if(!d)return!1;a=a||{};a.target||(a.target=this.target);d.slice().forEach(function(f){f.call(c.target,a)});return 0<d.length};b.prototype.on=function(b,a){var c=this;if(Array.isArray(b)){var f=b.map(function(f){return c.on(f,a)});return{remove:function(){return f.forEach(function(a){return a.remove()})}}}if(-1<b.indexOf(","))throw new TypeError("Evented.on() with a comma delimited string of event types is not supported");this._listenersMap||(this._listenersMap=new d.default);
var e=this._listenersMap.get(b)||[];e.push(a);this._listenersMap.set(b,e);return{remove:function(){var f=c._listenersMap.get(b)||[];f.splice(f.indexOf(a),1)}}};b.prototype.once=function(d,a){var c=this,f;return f=this.on(d,function(d){f.remove();a.call(c.target,d)})};b.prototype.hasEventListener=function(d){d=this._listenersMap&&this._listenersMap.get(d);return null!=d&&0<d.length};return b}();b=function(){function d(){this._emitter=new k(this)}d.prototype.emit=function(d,a){return this._emitter.emit(d,
a)};d.prototype.on=function(d,a){return this._emitter.on(d,a)};d.prototype.once=function(d,a){return this._emitter.once(d,a)};d.prototype.hasEventListener=function(d){return this._emitter.hasEventListener(d)};return d}();(function(d){d.EventedMixin=function(d){return function(a){function c(){return null!==a&&a.apply(this,arguments)||this}m(c,a);c.prototype.emit=function(a,c){return this._emitter.emit(a,c)};c.prototype.on=function(a,c){return this._emitter.on(a,c)};c.prototype.once=function(a,c){return this._emitter.once(a,
c)};c.prototype.hasEventListener=function(a){return this._emitter.hasEventListener(a)};return c}(d)}})(b||(b={}));return b})},"@dojo/framework/shim/Map":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define("require exports tslib ./iterator ./global ./object ../has/has ./Symbol".split(" "),b)})(function(b,e){Object.defineProperty(e,"__esModule",{value:!0});var m=b("tslib"),
d=b("./iterator"),k=b("./global"),l=b("./object"),h=b("../has/has");b("./Symbol");e.Map=k.default.Map;h.default("es6-map")||(e.Map=(a=function(){function a(a){this._keys=[];this._values=[];this[Symbol.toStringTag]="Map";if(a)if(d.isArrayLike(a))for(var c=0;c<a.length;c++){var f=a[c];this.set(f[0],f[1])}else try{for(var c=m.__values(a),b=c.next();!b.done;b=c.next())f=b.value,this.set(f[0],f[1])}catch(r){p={error:r}}finally{try{b&&!b.done&&(e=c.return)&&e.call(c)}finally{if(p)throw p.error;}}var p,
e}a.prototype._indexOfKey=function(a,c){for(var f=0,d=a.length;f<d;f++)if(l.is(a[f],c))return f;return-1};Object.defineProperty(a.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0});a.prototype.clear=function(){this._keys.length=this._values.length=0};a.prototype.delete=function(a){a=this._indexOfKey(this._keys,a);if(0>a)return!1;this._keys.splice(a,1);this._values.splice(a,1);return!0};a.prototype.entries=function(){var a=this,c=this._keys.map(function(c,f){return[c,
a._values[f]]});return new d.ShimIterator(c)};a.prototype.forEach=function(a,c){for(var f=this._keys,d=this._values,b=0,e=f.length;b<e;b++)a.call(c,d[b],f[b],this)};a.prototype.get=function(a){a=this._indexOfKey(this._keys,a);return 0>a?void 0:this._values[a]};a.prototype.has=function(a){return-1<this._indexOfKey(this._keys,a)};a.prototype.keys=function(){return new d.ShimIterator(this._keys)};a.prototype.set=function(a,c){var f=this._indexOfKey(this._keys,a),f=0>f?this._keys.length:f;this._keys[f]=
a;this._values[f]=c;return this};a.prototype.values=function(){return new d.ShimIterator(this._values)};a.prototype[Symbol.iterator]=function(){return this.entries()};return a}(),a[Symbol.species]=a,a));e.default=e.Map;var a})},"@dojo/framework/shim/iterator":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define(["require","exports","./Symbol","./string"],b)})(function(b,
e){function m(a){return a&&"function"===typeof a[Symbol.iterator]}function d(a){return a&&"number"===typeof a.length}function k(c){if(m(c))return c[Symbol.iterator]();if(d(c))return new a(c)}Object.defineProperty(e,"__esModule",{value:!0});b("./Symbol");var l=b("./string"),h={done:!0,value:void 0},a=function(){function a(a){this._nextIndex=-1;m(a)?this._nativeIterator=a[Symbol.iterator]():this._list=a}a.prototype.next=function(){return this._nativeIterator?this._nativeIterator.next():this._list?++this._nextIndex<
this._list.length?{done:!1,value:this._list[this._nextIndex]}:h:h};a.prototype[Symbol.iterator]=function(){return this};return a}();e.ShimIterator=a;e.isIterable=m;e.isArrayLike=d;e.get=k;e.forOf=function(a,f,b){function c(){e=!0}var e=!1;if(d(a)&&"string"===typeof a)for(var p=a.length,h=0;h<p;++h){var n=a[h];if(h+1<p){var v=n.charCodeAt(0);v>=l.HIGH_SURROGATE_MIN&&v<=l.HIGH_SURROGATE_MAX&&(n+=a[++h])}f.call(b,n,a,c);if(e)break}else if(p=k(a))for(h=p.next();!h.done;){f.call(b,h.value,a,c);if(e)break;
h=p.next()}}})},"@dojo/framework/shim/Symbol":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define(["require","exports","../has/has","./global","./support/util"],b)})(function(b,e){function m(a){return a&&("symbol"===typeof a||"Symbol"===a["@@toStringTag"])||!1}Object.defineProperty(e,"__esModule",{value:!0});var d=b("../has/has"),k=b("./global"),l=b("./support/util");
e.Symbol=k.default.Symbol;if(!d.default("es6-symbol")){var h=function(a){if(!m(a))throw new TypeError(a+" is not a symbol");return a},a=Object.defineProperties,c=Object.defineProperty,f=Object.create,n=Object.prototype,g={},q=function(){var a=f(null);return function(f){for(var d=0,b;a[String(f)+(d||"")];)++d;f+=String(d||"");a[f]=!0;b="@@"+f;Object.getOwnPropertyDescriptor(n,b)||c(n,b,{set:function(a){c(this,b,l.getValueDescriptor(a))}});return b}}(),p=function r(a){if(this instanceof p)throw new TypeError("TypeError: Symbol is not a constructor");
return r(a)};e.Symbol=k.default.Symbol=function v(c){if(this instanceof v)throw new TypeError("TypeError: Symbol is not a constructor");var f=Object.create(p.prototype);c=void 0===c?"":String(c);return a(f,{__description__:l.getValueDescriptor(c),__name__:l.getValueDescriptor(q(c))})};c(e.Symbol,"for",l.getValueDescriptor(function(a){return g[a]?g[a]:g[a]=e.Symbol(String(a))}));a(e.Symbol,{keyFor:l.getValueDescriptor(function(a){var c;h(a);for(c in g)if(g[c]===a)return c}),hasInstance:l.getValueDescriptor(e.Symbol.for("hasInstance"),
!1,!1),isConcatSpreadable:l.getValueDescriptor(e.Symbol.for("isConcatSpreadable"),!1,!1),iterator:l.getValueDescriptor(e.Symbol.for("iterator"),!1,!1),match:l.getValueDescriptor(e.Symbol.for("match"),!1,!1),observable:l.getValueDescriptor(e.Symbol.for("observable"),!1,!1),replace:l.getValueDescriptor(e.Symbol.for("replace"),!1,!1),search:l.getValueDescriptor(e.Symbol.for("search"),!1,!1),species:l.getValueDescriptor(e.Symbol.for("species"),!1,!1),split:l.getValueDescriptor(e.Symbol.for("split"),!1,
!1),toPrimitive:l.getValueDescriptor(e.Symbol.for("toPrimitive"),!1,!1),toStringTag:l.getValueDescriptor(e.Symbol.for("toStringTag"),!1,!1),unscopables:l.getValueDescriptor(e.Symbol.for("unscopables"),!1,!1)});a(p.prototype,{constructor:l.getValueDescriptor(e.Symbol),toString:l.getValueDescriptor(function(){return this.__name__},!1,!1)});a(e.Symbol.prototype,{toString:l.getValueDescriptor(function(){return"Symbol ("+h(this).__description__+")"}),valueOf:l.getValueDescriptor(function(){return h(this)})});
c(e.Symbol.prototype,e.Symbol.toPrimitive,l.getValueDescriptor(function(){return h(this)}));c(e.Symbol.prototype,e.Symbol.toStringTag,l.getValueDescriptor("Symbol",!1,!1,!0));c(p.prototype,e.Symbol.toPrimitive,l.getValueDescriptor(e.Symbol.prototype[e.Symbol.toPrimitive],!1,!1,!0));c(p.prototype,e.Symbol.toStringTag,l.getValueDescriptor(e.Symbol.prototype[e.Symbol.toStringTag],!1,!1,!0))}e.isSymbol=m;"hasInstance isConcatSpreadable iterator species replace search split match toPrimitive toStringTag unscopables observable".split(" ").forEach(function(a){e.Symbol[a]||
Object.defineProperty(e.Symbol,a,l.getValueDescriptor(e.Symbol.for(a),!1,!1))});e.default=e.Symbol})},"@dojo/framework/shim/object":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define(["require","exports","./global","../has/has","./Symbol"],b)})(function(b,e){Object.defineProperty(e,"__esModule",{value:!0});var m=b("./global"),d=b("../has/has"),k=b("./Symbol");d.default("es6-object")?
(b=m.default.Object,e.assign=b.assign,e.getOwnPropertyDescriptor=b.getOwnPropertyDescriptor,e.getOwnPropertyNames=b.getOwnPropertyNames,e.getOwnPropertySymbols=b.getOwnPropertySymbols,e.is=b.is,e.keys=b.keys):(e.keys=function(d){return Object.keys(d).filter(function(d){return!d.match(/^@@.+/)})},e.assign=function(d){for(var b=[],a=1;a<arguments.length;a++)b[a-1]=arguments[a];if(null==d)throw new TypeError("Cannot convert undefined or null to object");var c=Object(d);b.forEach(function(a){a&&e.keys(a).forEach(function(f){c[f]=
a[f]})});return c},e.getOwnPropertyDescriptor=function(d,b){k.isSymbol(b);return Object.getOwnPropertyDescriptor(d,b)},e.getOwnPropertyNames=function(d){return Object.getOwnPropertyNames(d).filter(function(d){return!d.match(/^@@.+/)})},e.getOwnPropertySymbols=function(d){return Object.getOwnPropertyNames(d).filter(function(d){return!!d.match(/^@@.+/)}).map(function(d){return Symbol.for(d.substring(2))})},e.is=function(d,b){return d===b?0!==d||1/d===1/b:d!==d&&b!==b});d.default("es2017-object")?(b=
m.default.Object,e.getOwnPropertyDescriptors=b.getOwnPropertyDescriptors,e.entries=b.entries,e.values=b.values):(e.getOwnPropertyDescriptors=function(d){return e.getOwnPropertyNames(d).reduce(function(b,a){b[a]=e.getOwnPropertyDescriptor(d,a);return b},{})},e.entries=function(d){return e.keys(d).map(function(b){return[b,d[b]]})},e.values=function(d){return e.keys(d).map(function(b){return d[b]})})})},"esri/core/accessorSupport/decorators":function(){define("require exports ./decorators/aliasOf ./decorators/autoDestroy ./decorators/cast ./decorators/declared ./decorators/enumeration ./decorators/property ./decorators/reader ./decorators/shared ./decorators/subclass ./decorators/writer".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g){function q(a){for(var c in a)e.hasOwnProperty(c)||(e[c]=a[c])}Object.defineProperty(e,"__esModule",{value:!0});q(m);q(d);q(k);q(l);q(h);q(a);q(c);q(f);q(n);q(g)})},"esri/core/accessorSupport/decorators/aliasOf":function(){define(["require","exports","../metadata"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.aliasOf=function(d){return function(b,e){m.getPropertyMetadata(b,e).aliasOf=d}}})},"esri/core/accessorSupport/decorators/autoDestroy":function(){define(["require",
"exports","../metadata"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.autoDestroy=function(){return function(d,b,e){m.getMetadata(d).autoDestroy=!0;return d[b]}}})},"esri/core/accessorSupport/decorators/declared":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.declared=function(b){for(var d=[],e=1;e<arguments.length;e++)d[e-1]=arguments[e];e=function(){return this||{}};e.__bases__=[b].concat(d);return e}})},"esri/core/accessorSupport/decorators/enumeration":function(){define(["require",
"exports","../../kebabDictionary","./property"],function(b,e,m,d){function k(b){return d.property({type:b})}Object.defineProperty(e,"__esModule",{value:!0});e.enumeration=k;(function(b){b.serializable=function(){return function(b){b=b instanceof m.KebabDictionary?b:new m.KebabDictionary(b,{ignoreUnknown:!0});return d.property({type:b.apiValues,json:{type:b.jsonValues,read:{reader:b.read},write:{writer:b.write}}})}}})(k=e.enumeration||(e.enumeration={}))})},"esri/core/kebabDictionary":function(){define(["require",
"exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});var m=function(){function d(d,b){void 0===b&&(b={ignoreUnknown:!1});var e=this;this.jsonToAPI=d;this.options=b;this.apiValues=[];this.jsonValues=[];this.apiToJSON=this.invertMap(d);this.apiValues=this.getKeysSorted(this.apiToJSON);this.jsonValues=this.getKeysSorted(this.jsonToAPI);this.read=function(a){return e.fromJSON(a)};this.write=function(a,c,f){a=e.toJSON(a);void 0!==a&&(c[f]=a)}}d.prototype.toJSON=function(d){return this.apiToJSON.hasOwnProperty(d)?
this.apiToJSON[d]:this.options.ignoreUnknown?void 0:d};d.prototype.fromJSON=function(d){return this.jsonToAPI.hasOwnProperty(d)?this.jsonToAPI[d]:this.options.ignoreUnknown?void 0:d};d.prototype.invertMap=function(d){var b={},e;for(e in d)b[d[e]]=e;return b};d.prototype.getKeysSorted=function(d){var b=[],e;for(e in d)b.push(e);b.sort();return b};return d}();e.KebabDictionary=m;e.strict=function(){return function(d){return new m(d,{ignoreUnknown:!0})}};e.default=m})},"esri/core/accessorSupport/decorators/property":function(){define("require exports ../../has ../../lang ../../Logger ../metadata".split(" "),
function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});k.getLogger("esri.core.accessorSupport.decorators.property");e.property=function(b){void 0===b&&(b={});return function(a,c){var f=a.constructor.prototype;f!==Function.prototype&&((a=Object.getOwnPropertyDescriptor(a,c))&&(a.get||a.set)?(b=d.clone(b),a.set&&(b.set=a.set),a.get&&(b.get=a.get)):a&&a.hasOwnProperty("value")&&(b=d.clone(b),b.value=a.value),c=l.getPropertyMetadata(f,c),l.mergeProperty(c,b))}};e.propertyJSONMeta=function(d,
a,c){d=l.getPropertyMetadata(d.constructor.prototype,c);d.json||(d.json={});d=d.json;void 0!==a&&(d.origins||(d.origins={}),d.origins[a]||(d.origins[a]={}),d=d.origins[a]);return d}})},"esri/core/accessorSupport/decorators/reader":function(){define(["require","exports","../../object","./property"],function(b,e,m,d){Object.defineProperty(e,"__esModule",{value:!0});e.reader=function(b,e,h){var a,c;void 0===e||Array.isArray(e)?(c=b,h=e,a=[void 0]):(c=e,a=Array.isArray(b)?b:[b]);return function(f,b,g){var e=
f.constructor.prototype;a.forEach(function(a){a=d.propertyJSONMeta(f,a,c);a.read&&"object"!==typeof a.read&&(a.read={});m.setDeepValue("read.reader",e[b],a);h&&(a.read.source=(a.read.source||[]).concat(h))})}}})},"esri/core/accessorSupport/decorators/shared":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.shared=function(b){return function(d,e){d[e]=b}}})},"esri/core/accessorSupport/decorators/subclass":function(){define(["require","exports",
"../../declare","../metadata"],function(b,e,m,d){function k(a,c){a.read&&("function"===typeof a.read?c.push(a.read):"object"===typeof a.read&&a.read.reader&&c.push(a.read.reader))}function l(a,c){a.write&&("function"===typeof a.write?c.push(a.write):"object"===typeof a.write&&a.write.writer&&c.push(a.write.writer))}function h(a){var c=[];a=d.getPropertiesMetadata(a.prototype);if(!a)return c;for(var f in a){var b=a[f];b.cast&&c.push(b.cast);b.copy&&c.push(b.copy);if(b=b.json)if(k(b,c),l(b,c),b=b.origins)for(var e in b){var h=
b[e];k(h,c);l(h,c)}}return c}function a(a){var c={values:{},descriptors:{}},b=["__bases__"],e=d.getPropertiesMetadata(a.prototype),n=h(a);Object.getOwnPropertyNames(a.prototype).filter(function(c){return-1!==b.indexOf(c)||e&&e.hasOwnProperty(c)||!f(Object.getOwnPropertyDescriptor(a.prototype,c))&&-1!==n.indexOf(a.prototype[c])?!1:!0}).forEach(function(d){var b=Object.getOwnPropertyDescriptor(a.prototype,d);f(b)?c.descriptors[d]=b:c.values[d]=a.prototype[d]});return c}function c(a){var c=Object.getOwnPropertyNames(a),
d=Object.getPrototypeOf(a.prototype).constructor,b=Object.getOwnPropertyNames(Function);b.push("__bases__");var e=Object.getOwnPropertyNames(d),h={values:{},descriptors:{}};c.filter(function(c){return-1!==b.indexOf(c)?!1:-1===e.indexOf(c)||d[c]!==a[c]?!0:!1}).forEach(function(c){var d=Object.getOwnPropertyDescriptor(a,c);f(d)?h.descriptors[c]=d:h.values[c]=a[c]});return h}function f(a){return a&&!(!a.get&&!a.set)}Object.defineProperty(e,"__esModule",{value:!0});e.subclass=function(f){return function(d){var b=
a(d),g=c(d);null!=f&&(b.values.declaredClass=f);d=m(d.__bases__,b.values);Object.defineProperties(d.prototype,b.descriptors);for(var e in g.values)d[e]=g.values[e];Object.defineProperties(d,g.descriptors);return d}}})},"esri/core/accessorSupport/decorators/writer":function(){define(["require","exports","../../object","./property"],function(b,e,m,d){Object.defineProperty(e,"__esModule",{value:!0});e.writer=function(b,e,h){var a,c;void 0===e?(c=b,a=[void 0]):"string"!==typeof e?(c=b,a=[void 0],h=e):
(c=e,a=Array.isArray(b)?b:[b]);return function(f,b,g){var e=f.constructor.prototype;a.forEach(function(a){a=d.propertyJSONMeta(f,a,c);a.write&&"object"!==typeof a.write&&(a.write={});h&&m.setDeepValue("write.target",h,a);m.setDeepValue("write.writer",e[b],a)})}}})},"esri/core/compilerUtils":function(){define(["require","exports","./has"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.neverReached=function(d){};e.neverReachedSilent=function(d){};e.typeCast=function(d){return function(){return d}};
e.tuple=function(){for(var d=[],b=0;b<arguments.length;b++)d[b]=arguments[b];return d}})},"esri/core/JSONSupport":function(){define("require exports ./tsSupport/declareExtendsHelper ./tsSupport/decorateHelper ./Accessor ./declare ./accessorSupport/decorators ./accessorSupport/read ./accessorSupport/write".split(" "),function(b,e,m,d,k,l,h,a,c){function f(a,c){if(!a)return null;if(a.declaredClass)throw Error("JSON object is already hydrated");var f=new this;f.read(a,c);return f}var n=function(b){function g(){return null!==
b&&b.apply(this,arguments)||this}m(g,b);g.prototype.read=function(c,f){a.default(this,c,f)};g.prototype.write=function(a,f){return c.default(this,a||{},f)};g.prototype.toJSON=function(a){return this.write(null,a)};g.fromJSON=function(a,c){return f.call(this,a,c)};return g=d([h.subclass("esri.core.JSONSupport")],g)}(h.declared(k));n.prototype.toJSON.isDefaultToJSON=!0;l.after(function(a){l.hasMixin(a,n)&&(a.fromJSON=f.bind(a))});return n})},"esri/core/accessorSupport/read":function(){define("require exports ../tsSupport/assignHelper ./get ./utils ./extensions/serializableProperty".split(" "),
function(b,e,m,d,k,l){function h(c,f,b){void 0===b&&(b=a);if(f&&"object"===typeof f){for(var g=k.getProperties(c),e=g.metadatas,p={},h=0,n=Object.getOwnPropertyNames(f);h<n.length;h++){var v=p,u=e,m=n[h],y=f,x=b,w=l.originSpecificReadPropertyDefinition(u[m],x);w&&(!w.read||!1!==w.read.enabled&&!w.read.source)&&(v[m]=!0);for(var A=0,B=Object.getOwnPropertyNames(u);A<B.length;A++){var F=B[A],w=l.originSpecificReadPropertyDefinition(u[F],x),C;a:{C=m;var E=y;if(w&&w.read&&!1!==w.read.enabled&&w.read.source)if(w=
w.read.source,"string"===typeof w){if(w===C||-1<w.indexOf(".")&&0===w.indexOf(C)&&d.exists(w,E)){C=!0;break a}}else for(var G=0;G<w.length;G++){var Q=w[G];if(Q===C||-1<Q.indexOf(".")&&0===Q.indexOf(C)&&d.exists(Q,E)){C=!0;break a}}C=!1}C&&(v[F]=!0)}}g.setDefaultOrigin(b.origin);n=0;for(v=Object.getOwnPropertyNames(p);n<v.length;n++)h=v[n],m=(u=l.originSpecificReadPropertyDefinition(e[h],b).read)&&u.source,y=void 0,y=m&&"string"===typeof m?d.valueOf(f,m):f[h],u&&u.reader&&(y=u.reader.call(c,y,f,b)),
void 0!==y&&g.set(h,y);if(!b||!b.ignoreDefaults)for(f=0,e=Object.getOwnPropertyNames(e);f<e.length;f++)h=e[f],p[h]||(n=c,v=g,u=b,m=(m=l.originSpecificReadPropertyDefinition(v.metadatas[h],u))&&m.default,void 0!==m&&(n="function"===typeof m?m.call(n,h,u):m,void 0!==n&&v.set(h,n)));g.setDefaultOrigin("user")}}Object.defineProperty(e,"__esModule",{value:!0});var a={origin:"service"};e.read=h;e.readLoadable=function(c,f,d,b){void 0===b&&(b=a);f=m({},b,{messages:[]});d(f);f.messages.forEach(function(a){"warning"!==
a.type||c.loaded?b&&b.messages.push(a):c.loadWarnings.push(a)})};e.default=h})},"esri/core/accessorSupport/write":function(){define("require exports ../arrayUtils ../Error ../Logger ./PropertyOrigin ./utils ./extensions/serializableProperty".split(" "),function(b,e,m,d,k,l,h,a){function c(a,c,f,b,e,h){if(!b||!b.write)return!1;var g=a.get(f);if(!e&&b.write.overridePolicy){var p=b.write.overridePolicy.call(a,g,f,h);void 0!==p&&(e=p)}e||(e=b.write);if(!e||!1===e.enabled)return!1;if((null===g&&!e.allowNull||
void 0===g)&&e.isRequired)return(g=new d("web-document-write:property-required","Missing value for required property '"+f+"' on '"+a.declaredClass+"'",{propertyName:f,target:a}),h)&&h.messages?h.messages.push(g):g&&!h&&n.error(g.name,g.message),!1;if(void 0===g||null===g&&!e.allowNull||!e.ignoreOrigin&&h&&h.origin&&c.store.originOf(f)<l.nameToId(h.origin))return!1;c=b.default;void 0===c?h=!1:"function"===typeof c?Array.isArray(g)?(h=c.call(a,f,h),h=m.equals(h,g)):h=!1:h=c===g;return h?!1:!0}function f(f,
d,b){if(f&&"function"===typeof f.toJSON&&(!f.toJSON.isDefaultToJSON||!f.write))return h.merge(d,f.toJSON());var g=h.getProperties(f),e=g.metadatas,p;for(p in e){var n=a.originSpecificWritePropertyDefinition(e[p],b);if(c(f,g,p,n,null,b)){var q=f.get(p),k={};n.write.writer.call(f,q,k,"string"===typeof n.write.target?n.write.target:p,b);n=k;0<Object.keys(n).length&&(d=h.merge(d,n),b&&b.writtenProperties&&b.writtenProperties.push({target:f,propName:p,oldOrigin:l.idToReadableName(g.store.originOf(p)),
newOrigin:b.origin}))}}return d}Object.defineProperty(e,"__esModule",{value:!0});var n=k.getLogger("esri.core.accessorSupport.write");e.willPropertyWrite=function(f,d,b,e){var g=h.getProperties(f),p=a.originSpecificWritePropertyDefinition(g.metadatas[d],e);return p?c(f,g,d,p,b,e):!1};e.write=f;e.default=f})},"esri/core/arrayUtils":function(){define(["require","exports","@dojo/framework/shim/array","./RandomLCG"],function(b,e,m,d){function k(a,c){return-1===a.indexOf(c)}function l(a,c,f){return!a.some(c.bind(null,
f))}function h(a){return a}Object.defineProperty(e,"__esModule",{value:!0});e.find=m.find;e.findIndex=m.findIndex;e.unique=function(a){return a.filter(function(a,c,f){return f.indexOf(a)===c})};e.equals=function(a,c,f){if(!a&&!c)return!0;if(!a||!c||a.length!==c.length)return!1;if(f)for(var d=0;d<a.length;d++){if(!f(a[d],c[d]))return!1}else for(d=0;d<a.length;d++)if(a[d]!==c[d])return!1;return!0};e.difference=function(a,c,f){var d;f?(d=c.filter(l.bind(null,a,f)),a=a.filter(l.bind(null,c,f))):(d=c.filter(k.bind(null,
a)),a=a.filter(k.bind(null,c)));return{added:d,removed:a}};e.intersect=function(a,c,f){return a&&c?f?a.filter(function(a){return-1<m.findIndex(c,function(c){return f(a,c)})}):a.filter(function(a){return-1<c.indexOf(a)}):[]};e.constant=function(a,c){for(var f=Array(a),d=0;d<a;d++)f[d]=c;return f};e.range=function(a,c){void 0===c&&(c=a,a=0);for(var f=Array(c-a),d=a;d<c;d++)f[d-a]=d;return f};e.binaryIndexOf=function(a,c,f){for(var d=a.length,b=0,g=d-1;b<g;){var e=b+Math.floor((g-b)/2);c>a[e]?b=e+1:
g=e}g=a[b];return f?c>=a[d-1]?-1:g===c?b:b-1:g===c?b:-1};e.flatten=function(a){return a.reduce(function(a,c){return a.concat(c||[])},[])};b=function(){return function(){this.last=0}}();e.RemoveHint=b;var a=new b;e.removeUnordered=function(c,f,d,b){b=b||a;for(var g=null==d?c.length:d,e=Math.max(0,b.last-10),p=-1,h=e;h<g;++h)if(c[h]===f){p=h;break}if(-1===p){for(h=0;h<e;++h)if(c[h]===f){p=h;break}if(-1===p)return}c[p]=c[g-1];null==d&&c.pop();b.last=p;return f};var c=new Set;e.removeUnorderedMany=function(f,
d,b,e,h,r){void 0===b&&(b=f.length);void 0===e&&(e=d.length);if(0===e||0===b)return b;c.clear();for(var g=0;g<e;++g)c.add(d[g]);h=h||a;for(g=d=Math.max(0,h.last-10);g<b;++g)if(c.has(f[g])&&(r&&r.push(f[g]),c.delete(f[g]),f[g]=f[b-1],--b,--g,0===c.size||0===b))return c.clear(),b;for(g=0;g<d;++g)if(c.has(f[g])&&(r&&r.push(f[g]),c.delete(f[g]),f[g]=f[b-1],--b,--g,0===c.size||0===b))return c.clear(),b;c.clear();return b};e.shuffle=function(a,c){c=(f.seed=c)?function(){return f.getFloat()}:Math.random;
for(var d=a.length-1;0<d;d--){var b=Math.floor(c()*(d+1)),g=a[d];a[d]=a[b];a[b]=g}return a};var f=new d;e.keysOfMap=function(a){var c=[];a.forEach(function(a,f){return c.push(f)});return c};e.keysOfSet=function(a,c){void 0===c&&(c=h);var f=[];a.forEach(function(a){return f.push(c(a))});return f};e.fromMapValues=function(a){if(Array.from)return Array.from(a.values());var c=Array(a.size),f=0;a.forEach(function(a){c[f++]=a});return c}})},"@dojo/framework/shim/array":function(){(function(b){"object"===
typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define("require exports tslib ./global ./iterator ./number ../has/has ./support/util".split(" "),b)})(function(b,e){Object.defineProperty(e,"__esModule",{value:!0});var m=b("tslib"),d=b("./global"),k=b("./iterator"),l=b("./number"),h=b("../has/has");b=b("./support/util");if(h.default("es6-array")&&h.default("es6-array-fill"))e.from=d.default.Array.from,e.of=
d.default.Array.of,e.copyWithin=b.wrapNative(d.default.Array.prototype.copyWithin),e.fill=b.wrapNative(d.default.Array.prototype.fill),e.find=b.wrapNative(d.default.Array.prototype.find),e.findIndex=b.wrapNative(d.default.Array.prototype.findIndex);else{var a=function(a){if(isNaN(a))return 0;a=Number(a);isFinite(a)&&(a=Math.floor(a));return Math.min(Math.max(a,0),l.MAX_SAFE_INTEGER)},c=function(a){a=Number(a);return isNaN(a)?0:0!==a&&isFinite(a)?(0<a?1:-1)*Math.floor(Math.abs(a)):a},f=function(a,
c){return 0>a?Math.max(c+a,0):Math.min(a,c)};e.from=function(c,f,d){if(null==c)throw new TypeError("from: requires an array-like object");f&&d&&(f=f.bind(d));d=a(c.length);var b="function"===typeof this?Object(new this(d)):Array(d);if(!k.isArrayLike(c)&&!k.isIterable(c))return b;if(k.isArrayLike(c)){if(0===d)return[];for(var g=0;g<c.length;g++)b[g]=f?f(c[g],g):c[g]}else{g=0;try{for(var e=m.__values(c),h=e.next();!h.done;h=e.next()){var n=h.value;b[g]=f?f(n,g):n;g++}}catch(x){q={error:x}}finally{try{h&&
!h.done&&(l=e.return)&&l.call(e)}finally{if(q)throw q.error;}}}void 0!==c.length&&(b.length=d);return b;var q,l};e.of=function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];return Array.prototype.slice.call(a)};e.copyWithin=function(d,b,e,p){if(null==d)throw new TypeError("copyWithin: target must be an array-like object");var g=a(d.length);b=f(c(b),g);e=f(c(e),g);p=f(void 0===p?g:c(p),g);p=Math.min(p-e,g-b);g=1;b>e&&b<e+p&&(g=-1,e+=p-1,b+=p-1);for(;0<p;)e in d?d[b]=d[e]:delete d[b],
b+=g,e+=g,p--;return d};e.fill=function(d,b,e,p){var g=a(d.length);e=f(c(e),g);for(p=f(void 0===p?g:c(p),g);e<p;)d[e++]=b;return d};e.find=function(a,c,f){c=e.findIndex(a,c,f);return-1!==c?a[c]:void 0};e.findIndex=function(c,f,d){var b=a(c.length);if(!f)throw new TypeError("find: second argument must be a function");d&&(f=f.bind(d));for(d=0;d<b;d++)if(f(c[d],d,c))return d;return-1}}h.default("es7-array")?e.includes=b.wrapNative(d.default.Array.prototype.includes):e.includes=function(a,c,f){void 0===
f&&(f=0);var d;d=a.length;d=Number(d);isNaN(d)?d=0:(isFinite(d)&&(d=Math.floor(d)),d=Math.min(Math.max(d,0),l.MAX_SAFE_INTEGER));for(;f<d;++f){var b=a[f];if(c===b||c!==c&&b!==b)return!0}return!1}})},"@dojo/framework/shim/number":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define(["require","exports","./global"],b)})(function(b,e){function m(d){return"number"===typeof d&&
k.default.isFinite(d)}function d(d){return m(d)&&Math.floor(d)===d}Object.defineProperty(e,"__esModule",{value:!0});var k=b("./global");e.EPSILON=1;e.MAX_SAFE_INTEGER=Math.pow(2,53)-1;e.MIN_SAFE_INTEGER=-e.MAX_SAFE_INTEGER;e.isNaN=function(d){return"number"===typeof d&&k.default.isNaN(d)};e.isFinite=m;e.isInteger=d;e.isSafeInteger=function(b){return d(b)&&Math.abs(b)<=e.MAX_SAFE_INTEGER}})},"esri/core/RandomLCG":function(){define(["require","exports"],function(b,e){return function(){function b(d){void 0===
d&&(d=1);this._seed=d}Object.defineProperty(b.prototype,"seed",{set:function(d){this._seed=null==d?Math.random()*b._m:d},enumerable:!0,configurable:!0});b.prototype.getInt=function(){return this._seed=(b._a*this._seed+b._c)%b._m};b.prototype.getFloat=function(){return this.getInt()/(b._m-1)};b.prototype.getIntRange=function(d,b){return Math.round(this.getFloatRange(d,b))};b.prototype.getFloatRange=function(d,e){e-=d;var l=this.getInt()/b._m;return d+Math.floor(l*e)};b._m=2147483647;b._a=48271;b._c=
0;return b}()})},"esri/core/Loadable":function(){define("require exports ./tsSupport/declareExtendsHelper ./tsSupport/decorateHelper ./Accessor ./Error ./lang ./Promise ./promiseUtils ./Warning ./accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h,a,c,f,n){b=function(a){function b(){var f=a.call(this)||this;f.loadError=null;f.loadStatus="not-loaded";f.loadWarnings=null;f._set("loadWarnings",[]);f.addResolvingPromise(c.create(function(a){var c=!1,d=f.load.bind(f);f.load=function(){"not-loaded"===
f.loadStatus&&(f._set("loadStatus","loading"),d());c||(a(),c=!0);return f.when()}}));f.when(function(a){f._set("loadStatus","loaded")},function(a){f._set("loadStatus","failed");f._set("loadError",a)});return f}m(b,a);Object.defineProperty(b.prototype,"loaded",{get:function(){return"loaded"===this.loadStatus},enumerable:!0,configurable:!0});b.prototype.load=function(){return null};b.prototype.cancelLoad=function(){if(this.isFulfilled())return this;this._set("loadError",new l("load:cancelled","Cancelled"));
this._promiseProps.resolver.reject(this.loadError);return this};d([n.property({readOnly:!0,dependsOn:["loadStatus"]})],b.prototype,"loaded",null);d([n.property({readOnly:!0})],b.prototype,"loadError",void 0);d([n.property()],b.prototype,"loadStatus",void 0);d([n.property({type:[f],readOnly:!0})],b.prototype,"loadWarnings",void 0);return b=d([n.subclass("esri.core.Loadable")],b)}(n.declared(k,a));b.prototype["-chains-"]=h.mixin({},k._meta.chains,{load:"after"});return b})},"esri/core/Promise":function(){define("require exports ./tsSupport/declareExtendsHelper ./tsSupport/decorateHelper ./Accessor ./Error ./promiseUtils ./scheduling ./accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a,c){function f(c){var f=c._promiseProps;if(!f.isFulfilled()){var d=f.resolvingPromises,b,g;f.allPromise&&f.allPromise.cancel();var e,n=h.create(function(a,c){e={resolve:a,reject:c}});for(b=d.length-1;0<=b;b--)g=d[b],g.isCanceled&&g.isCanceled()&&d.splice(b,1);g=null;(f.allPromise=h.all(d.concat([n]))).then(function(){f.resolver.resolve(c);c=f=e=f.allPromise=f.resolvingPromises=null},function(a){f.allPromise=null;if(!a||"cancel"!==a.dojoType){var d=Array.prototype.slice.call(arguments,
0);f.resolver.reject(d[0]);c=f=e=f.allPromise=f.resolvingPromises=null}});e&&a.schedule(function(){e&&e.resolve()})}}var n=function(a){a=new l("AbortError");a.target=this.instance;a.dojoType="cancel";return a},g=function(){function a(a){var c=this;this.canceler=n.bind(this);this.status=void 0;this.initialized=!1;this.resolvingPromises=[];this.instance=a;this.promise=h.create(function(a,f){c.resolver={resolve:a,reject:f}});this.promise.then(function(){c.status=1},function(){c.status=2})}a.prototype.cancel=
function(){if(!this.isFulfilled()){this.allPromise.cancel();for(var a=this.resolvingPromises.concat(),c=a.length-1;0<=c;c--)a[c].cancel();this.resolver.cancel()}};a.prototype.isResolved=function(){return 1===this.status};a.prototype.isRejected=function(){return 2===this.status};a.prototype.isFulfilled=function(){return!!this.status};return a}();return function(a){function b(){var c=a.call(this)||this;c._promiseProps=new g(c);var d=c.postscript;d?c.postscript=function(){for(var a=[],b=0;b<arguments.length;b++)a[b]=
arguments[b];d.apply(c,a);c.postscript=d;f(c)}:f(c);return c}m(b,a);b.prototype.isResolved=function(){return this._promiseProps.isResolved()};b.prototype.isRejected=function(){return this._promiseProps.isRejected()};b.prototype.isFulfilled=function(){return this._promiseProps.isFulfilled()};b.prototype.when=function(a,c){var f=this;return h.create(function(a,c){f._promiseProps.promise.then(a,c)},this._promiseProps.canceler).then(a,c)};b.prototype.catch=function(a){return this.when(null,a)};b.prototype.addResolvingPromise=
function(a){a&&!this._promiseProps.isFulfilled()&&("_promiseProps"in a?this._promiseProps.resolvingPromises.push(a.when()):this._promiseProps.resolvingPromises.push(a),f(this))};return b=d([c.subclass()],b)}(c.declared(k))})},"esri/core/Warning":function(){define(["require","exports","./tsSupport/extendsHelper","./tsSupport/decorateHelper","./Message"],function(b,e,m,d,k){b=function(d){function b(a,c,f){var e=d.call(this,a,c,f)||this;return e instanceof b?e:new b(a,c,f)}m(b,d);return b}(k);b.prototype.type=
"warning";return b})},"esri/core/loadAll":function(){define("require exports ./tsSupport/generatorHelper ./tsSupport/awaiterHelper ./asyncUtils ./Collection ./Loadable".split(" "),function(b,e,m,d,k,l,h){function a(a,b){return d(this,void 0,void 0,function(){return m(this,function(f){switch(f.label){case 0:return[4,a.load()];case 1:return f.sent(),[2,c(a,b)]}})})}function c(a,c){return d(this,void 0,void 0,function(){var f,b,e,n=this;return m(this,function(g){switch(g.label){case 0:return f=[],b=
function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];for(c=0;c<a.length;c++){var d=a[c];d&&(Array.isArray(d)?b.apply(void 0,d):l.isCollection(d)?d.forEach(function(a){return b(a)}):d.isInstanceOf&&d.isInstanceOf(h)&&f.push(d))}},c(b),e=null,[4,k.map(f,function(a){return d(n,void 0,void 0,function(){var c;return m(this,function(f){switch(f.label){case 0:return[4,k.result("loadAll"in a&&"function"===typeof a.loadAll?a.loadAll():a.load())];case 1:return c=f.sent(),!1!==c.ok||e||(e=a),
[2]}})})})];case 1:g.sent();if(e)throw e.loadError;return[2,a]}})})}Object.defineProperty(e,"__esModule",{value:!0});e.loadAll=a;e.loadAllChildren=c;e.default=a})},"esri/core/urlUtils":function(){define("require exports ./tsSupport/assignHelper dojo/io-query dojo/_base/url ../config ../kernel ./Error ./global ./lang ./Logger".split(" "),function(b,e,m,d,k,l,h,a,c,f,n){function g(a){var c={path:null,query:null},f=new e.Url(a),b=a.indexOf("?");null===f.query?c.path=a:(c.path=a.substring(0,b),c.query=
d.queryToObject(f.query));f.fragment&&(c.hash=f.fragment,null===f.query&&(c.path=c.path.substring(0,c.path.length-(f.fragment.length+1))));return c}function q(a){var c=a.indexOf("?");-1!==c?(pa.path=a.slice(0,c),pa.query=a.slice(c+1)):(pa.path=a,pa.query=null);return pa}function p(a){a=q(a).path;a&&"/"===a[a.length-1]||(a+="/");a=M(a,!0);return a=a.toLowerCase()}function t(a){var c=oa.proxyRules;a=p(a);for(var f=0;f<c.length;f++)if(0===a.indexOf(c[f].urlPrefix))return c[f]}function r(a){a=y(a);var c=
a.indexOf("/sharing");return 0<c?a.substring(0,c):a.replace(/\/+$/,"")}function v(a,c,f){void 0===f&&(f=!1);a=J(a);c=J(c);return f||a.scheme===c.scheme?a.host.toLowerCase()===c.host.toLowerCase()&&a.port===c.port:!1}function u(a,c,f){void 0===c&&(c=e.appBaseUrl);if(Q(a))return f&&f.preserveProtocolRelative?a:"http"===e.appUrl.scheme&&e.appUrl.authority===w(a).slice(2)?"http:"+a:"https:"+a;if(!V(a)){f=x;if("/"===a[0]){var d=c.indexOf("//"),d=c.indexOf("/",d+2);c=-1===d?c:c.slice(0,d)}return f(c,a)}return a}
function z(a,c,f){void 0===c&&(c=e.appBaseUrl);if(!A(a))return a;var d=y(a),b=d.toLowerCase();c=y(c).toLowerCase().replace(/\/+$/,"");if((f=f?y(f).toLowerCase().replace(/\/+$/,""):null)&&0!==c.indexOf(f))return a;for(var g=function(a,c,f){f=a.indexOf(c,f);return-1===f?a.length:f},p=g(b,"/",b.indexOf("//")+2),h=-1;b.slice(0,p+1)===c.slice(0,p)+"/";){h=p+1;if(p===b.length)break;p=g(b,"/",p+1)}if(-1===h||f&&h<f.length)return a;a=d.slice(h);d=c.slice(h-1).replace(/[^/]+/g,"").length;if(0<d)for(b=0;b<
d;b++)a="../"+a;else a="./"+a;return a}function y(a){a=a.trim();a=u(a);if(/^https?:\/\//i.test(a)){var c=q(a);a=c.path.replace(/\/{2,}/g,"/");a=a.replace("/","//");c.query&&(a+="?"+c.query)}a=a.replace(/^(https?:\/\/)(arcgis\.com)/i,"$1www.$2");return a=U(a)}function x(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];if(a&&a.length){c=[];if(A(a[0])){var f=a[0],d=f.indexOf("//");c.push(f.slice(0,d+1));ja.test(a[0])&&(c[0]+="/");a[0]=f.slice(d+2)}else"/"===a[0][0]&&c.push("");a=a.reduce(function(a,
c){return c?a.concat(c.split("/")):a},[]);for(f=0;f<a.length;f++)d=a[f],".."===d&&0<c.length&&".."!==c[c.length-1]?c.pop():!d||"."===d&&0!==c.length||c.push(d);return c.join("/")}}function w(a){if(B(a)||F(a))return null;var c=a.indexOf("://");if(-1===c&&Q(a))c=2;else if(-1!==c)c+=3;else return null;c=a.indexOf("/",c);return-1===c?a:a.slice(0,c)}function A(a){return Q(a)||V(a)}function B(a){return"blob:"===a.slice(0,5)}function F(a){return"data:"===a.slice(0,5)}function C(a){a=E(a);if(!a||!a.isBase64)return null;
a=atob(a.data);for(var c=new Uint8Array(a.length),f=0;f<a.length;f++)c[f]=a.charCodeAt(f);return c.buffer}function E(a){return(a=a.match(Ea))?{mediaType:a[1],isBase64:!!a[2],data:a[3]}:null}function G(a){var c=C(a);if(!c)return null;a=E(a);return new Blob([c],{type:a.mediaType})}function Q(a){return a&&"/"===a[0]&&"/"===a[1]}function V(a){return ga.test(a)}function R(a){return la.test(a)||"http"===e.appUrl.scheme&&Q(a)}function I(a){return Q(a)?"https:"+a:a.replace(la,"https:")}function W(){return"https"===
e.appUrl.scheme}function M(a,c){void 0===c&&(c=!1);if(Q(a))return a.slice(2);a=a.replace(ga,"");c&&1<a.length&&"/"===a[0]&&"/"===a[1]&&(a=a.slice(2));return a}function U(a){var c=oa.httpsDomains;if(!R(a))return a;var d=a.indexOf("/",7),b;b=-1===d?a:a.slice(0,d);b=b.toLowerCase().slice(7);if(ea.test(b))if(f.endsWith(b,":80"))b=b.slice(0,-3),a=a.replace(":80","");else return a;if("http"===e.appUrl.scheme&&b===e.appUrl.authority&&!sa.test(a))return a;if(W()&&b===e.appUrl.authority||c&&c.some(function(a){return b===
a||f.endsWith(b,"."+a)})||W()&&!t(a))a=I(a);return a}function O(a,c,f){if(!(c&&f&&a&&A(a)))return a;var d=a.indexOf("//"),b=a.indexOf("/",d+2),g=a.indexOf(":",d+2),b=Math.min(0>b?a.length:b,0>g?a.length:g);if(a.slice(d+2,b).toLowerCase()!==c.toLowerCase())return a;c=a.slice(0,d+2);a=a.slice(b);return""+c+f+a}function J(a){if("string"===typeof a)return new e.Url(u(a));a.scheme||(a.scheme=e.appUrl.scheme);return a}function fa(a,c){var f=c&&c.url&&c.url.path;a&&f&&(a=u(a,f,{preserveProtocolRelative:!0}));
(c=c&&c.portal)&&!c.isPortal&&c.urlKey&&c.customBaseUrl?(f=c.urlKey+"."+c.customBaseUrl,c=v(e.appUrl,e.appUrl.scheme+"://"+f)?O(a,c.portalHostname,f):O(a,f,c.portalHostname)):c=a;return c}function H(a,c){if(!a)return a;!A(a)&&c&&c.blockedRelativeUrls&&c.blockedRelativeUrls.push(a);var f=u(a);if(c){var d=c.verifyItemRelativeUrls&&c.verifyItemRelativeUrls.rootPath||c.url&&c.url.path;d&&(f=z(f,d,d),f!==a&&c.verifyItemRelativeUrls&&c.verifyItemRelativeUrls.writtenUrls.push(f))}a=f;f=(c=c&&c.portal)&&
!c.isPortal&&c.urlKey&&c.customBaseUrl?O(a,c.urlKey+"."+c.customBaseUrl,c.portalHostname):a;A(f)&&(f=y(f));return f}function da(a,c,f){a=g(a);var b=a.query||{};b[c]=f;return a.path+"?"+d.objectToQuery(b)}Object.defineProperty(e,"__esModule",{value:!0});e.Url=k;var aa=n.getLogger("esri.core.urlUtils"),oa=l.request,ga=/^\s*[a-z][a-z0-9-+.]*:(?![0-9])/i,la=/^\s*http:/i,Z=/^\s*https:/i,ja=/^\s*file:/i,ea=/:\d+$/,sa=/^https?:\/\/[^/]+\.arcgis.com\/sharing(\/|$)/i;e.appUrl=new e.Url(l.applicationUrl);e.trustedServersUrlCache=
{};e.appBaseUrl=function(){var a=e.appUrl.path,a=a.substring(0,a.lastIndexOf(a.split("/")[a.split("/").length-1]));return""+(e.appUrl.scheme+"://"+e.appUrl.host+(null!=e.appUrl.port?":"+e.appUrl.port:""))+a}();e.urlToObject=g;e.getProxyUrl=function(c){void 0===c&&(c=!1);var f,d=oa.proxyUrl;if("string"===typeof c){if(f=c,f=Z.test(f)||"https"===e.appUrl.scheme&&Q(f),c=t(c))d=c.proxyUrl}else f=!!c;if(!d)throw aa.warn("esri/config: esriConfig.request.proxyUrl is not set."),new a("urlutils:proxy-not-set",
"esri/config: esriConfig.request.proxyUrl is not set.");f&&W()&&(d=I(d));return g(d)};e.addProxy=function(a){var c=t(a),f,b;c&&(b=q(c.proxyUrl),f=b.path,b=b.query?d.queryToObject(b.query):null);f&&(c=g(a),a=f+"?"+c.path,(f=d.objectToQuery(m({},b,c.query)))&&(a=a+"?"+f));return a};var pa={path:"",query:""};e.addProxyRule=function(a){a={proxyUrl:a.proxyUrl,urlPrefix:p(a.urlPrefix)};for(var c=oa.proxyRules,f=a.urlPrefix,d=c.length,b=0;b<c.length;b++){var g=c[b].urlPrefix;if(0===f.indexOf(g)){if(f.length===
g.length)return-1;d=b;break}0===g.indexOf(f)&&(d=b+1)}c.splice(d,0,a);return d};e.getProxyRule=t;e.hasSamePortal=function(a,c){a=r(a);c=r(c);return M(a)===M(c)};e.getInterceptor=function(a){var c=function(c){return null==c||c instanceof RegExp&&c.test(a)||"string"===typeof c&&f.startsWith(a,c)},d=oa.interceptors;if(d)for(var b=0;b<d.length;b++){var g=d[b];if(Array.isArray(g.urls)){if(g.urls.some(c))return g}else if(c(g.urls))return g}return null};e.hasSameOrigin=v;e.isTrustedServer=function(a){if("string"===
typeof a)if(A(a))a=J(a);else return!0;for(var c=oa.trustedServers||[],f=0;f<c.length;f++){var d;d=c[f];e.trustedServersUrlCache[d]||(V(d)||Q(d)?e.trustedServersUrlCache[d]=[new e.Url(u(d))]:e.trustedServersUrlCache[d]=[new e.Url("http://"+d),new e.Url("https://"+d)]);d=e.trustedServersUrlCache[d];for(var b=0;b<d.length;b++)if(v(a,d[b]))return!0}return!1};e.makeAbsolute=u;e.makeRelative=z;e.normalize=y;e.join=x;e.getOrigin=w;e.isAbsolute=A;e.isBlobProtocol=B;e.isDataProtocol=F;e.dataToArrayBuffer=
C;var Ea=/^data:(.*?)(;base64)?,(.*)$/;e.dataComponents=E;e.makeData=function(a){return a.isBase64?"data:"+a.mediaType+";base64,"+a.data:"data:"+a.mediaType+","+a.data};e.dataToBlob=G;e.downloadDataAsFile=function(a,f){var d;a:if(d=document.createElement("a"),"download"in d){var b=null;if(c.URL&&c.URL.createObjectURL){b=G(a);if(!b){d=!1;break a}b=c.URL.createObjectURL(b)}d.download=f;d.href=b||a;d.style.display="none";document.body.appendChild(d);d.click();document.body.removeChild(d);b&&c.URL.revokeObjectURL(b);
d=void 0}else d=!1;d||window.navigator.msSaveOrOpenBlob&&window.navigator.msSaveOrOpenBlob(G(a),f)};e.isProtocolRelative=Q;e.hasProtocol=V;e.toHTTP=function(a){return Q(a)?"http:"+a:a.replace(Z,"http:")};e.toHTTPS=I;e.isAppHTTPS=W;e.removeFile=function(a){var c=0;if(A(a)){var f=a.indexOf("//");-1!==f&&(c=f+2)}f=a.lastIndexOf("/");return f<c?a:a.slice(0,f+1)};e.removeTrailingSlash=function(a){return a.replace(/\/+$/,"")};e.changeDomain=O;e.fromJSON=fa;e.read=function(a,c,f){return fa(a,f)};e.toJSON=
H;e.write=function(a,c,f,d){(a=H(a,d))&&(c[f]=a)};e.isSVG=function(a){return ra.test(a)};e.removeQueryParameters=function(a,c){a=g(a);var f=Object.keys(a.query||{});0<f.length&&c&&c.warn("removeQueryParameters()","Url query parameters are not supported, the following parameters have been removed: "+f.join(", ")+".");return a.path};e.addQueryParameter=da;e.addQueryParameters=function(a,c){a=g(a);var f=a.query||{},b;for(b in c)f[b]=c[b];return(c=d.objectToQuery(f))?a.path+"?"+c:a.path};e.removeQueryParameter=
function(a,c){var f=g(a),b=f.path,f=f.query;if(!f)return a;delete f[c];return(a=d.objectToQuery(f))?b+"?"+a:b};e.addTokenParameter=function(a){var c=h.id&&h.id.findCredential(a);return c&&c.token?da(a,"token",c.token):a};var ra=/(^data:image\/svg|\.svg$)/i})},"dojo/_base/url":function(){define(["./kernel"],function(b){var e=/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/,m=/^((([^\[:]+):)?([^@]+)@)?(\[([^\]]+)\]|([^\[:]*))(:([0-9]+))?$/,d=function(){for(var b=arguments,l=[b[0]],h=1;h<
b.length;h++)if(b[h]){var a=new d(b[h]+""),l=new d(l[0]+"");if(""==a.path&&!a.scheme&&!a.authority&&!a.query)null!=a.fragment&&(l.fragment=a.fragment),a=l;else if(!a.scheme&&(a.scheme=l.scheme,!a.authority&&(a.authority=l.authority,"/"!=a.path.charAt(0)))){for(var l=(l.path.substring(0,l.path.lastIndexOf("/")+1)+a.path).split("/"),c=0;c<l.length;c++)"."==l[c]?c==l.length-1?l[c]="":(l.splice(c,1),c--):0<c&&(1!=c||""!=l[0])&&".."==l[c]&&".."!=l[c-1]&&(c==l.length-1?(l.splice(c,1),l[c-1]=""):(l.splice(c-
1,2),c-=2));a.path=l.join("/")}l=[];a.scheme&&l.push(a.scheme,":");a.authority&&l.push("//",a.authority);l.push(a.path);a.query&&l.push("?",a.query);a.fragment&&l.push("#",a.fragment)}this.uri=l.join("");b=this.uri.match(e);this.scheme=b[2]||(b[1]?"":null);this.authority=b[4]||(b[3]?"":null);this.path=b[5];this.query=b[7]||(b[6]?"":null);this.fragment=b[9]||(b[8]?"":null);null!=this.authority&&(b=this.authority.match(m),this.user=b[3]||null,this.password=b[4]||null,this.host=b[6]||b[7],this.port=
b[9]||null)};d.prototype.toString=function(){return this.uri};return b._Url=d})},"esri/config":function(){define(["require","exports","./core/global"],function(b,e,m){b={applicationUrl:m.location&&m.location.href,screenDPI:96,fontsUrl:"https://static.arcgis.com/fonts",geometryService:null,geometryServiceUrl:"https://utility.arcgisonline.com/arcgis/rest/services/Geometry/GeometryServer",geoRSSServiceUrl:"https://utility.arcgis.com/sharing/rss",kmlServiceUrl:"https://utility.arcgis.com/sharing/kml",
portalUrl:"https://www.arcgis.com",workers:{loaderConfig:{has:{},paths:{},map:{},packages:[]}},request:{httpsDomains:"arcgis.com arcgisonline.com esrikr.com premiumservices.blackbridge.com esripremium.accuweather.com gbm.digitalglobe.com firstlook.digitalglobe.com msi.digitalglobe.com".split(" "),interceptors:[],maxUrlLength:2E3,proxyRules:[],proxyUrl:null,timeout:6E4,trustedServers:[],useIdentity:!0}};b.request.corsEnabledServers=[];b.request.corsEnabledServers.push=function(){console.warn("[esri.config]",
"request.corsEnabledServers is not supported and will be removed in a future release. See http://esriurl.com/cors8664");return 0};return b})},"esri/kernel":function(){define(["require","./core/promiseUtils","./core/has","dojo/main"],function(b,e,m,d){(function(){var b=d.config,e=b.has&&void 0!==b.has["config-deferredInstrumentation"],h=b.has&&void 0!==b.has["config-useDeferredInstrumentation"];void 0!==b.useDeferredInstrumentation||e||h||(m.add("config-deferredInstrumentation",!1,!0,!0),m.add("config-useDeferredInstrumentation",
!1,!0,!0))})();return{version:"4.11",workerMessages:{request:function(d){return e.create(function(d){b(["./request"],d)}).then(function(b){var e=d.options||{};e.responseType="array-buffer";return b(d.url,e)}).then(function(d){return{result:{data:d.data,ssl:d.ssl},transferList:[d.data]}})}}}})},"dojo/main":function(){define("./_base/kernel ./has require ./sniff ./_base/lang ./_base/array ./_base/config ./ready ./_base/declare ./_base/connect ./_base/Deferred ./_base/json ./_base/Color require ./has!host-browser?./_base/browser require".split(" "),
function(b,e,m,d,k,l,h,a){h.isDebug&&m(["./_firebug/firebug"]);return b})},"esri/layers/support/LayerCollection":function(){define(["require","exports","../../core/Collection","../Layer"],function(b,e,m,d){Object.defineProperty(e,"__esModule",{value:!0});e.LayerCollection=m.ofType(d);e.default=e.LayerCollection})},"esri/layers/Layer":function(){define("require ../core/Accessor ../core/Error ../core/Evented ../core/Identifiable ../core/Loadable ../core/urlUtils ../core/promiseUtils ../core/Logger ../config ../request ../geometry/SpatialReference ../geometry/Extent".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q){k=k.Identifiable;var p=0,t=c.getLogger("esri.layers.Layer");e=e.createSubclass([d,k,l],{declaredClass:"esri.layers.Layer",properties:{attributionDataUrl:null,fullExtent:new q(-180,-90,180,90,g.WGS84),hasAttributionData:{readOnly:!0,dependsOn:["attributionDataUrl"],get:function(){return null!=this.attributionDataUrl}},id:{get:function(){return Date.now().toString(16)+"-layer-"+p++}},legendEnabled:!0,listMode:{type:["show","hide","hide-children"],value:"show"},opacity:{value:1,
type:Number,range:{min:0,max:1},nonNullable:!0},parent:null,parsedUrl:{readOnly:!0,dependsOn:["url"],get:function(){var a=this._get("url");return a?h.urlToObject(a):null}},popupEnabled:!0,attributionVisible:!0,spatialReference:g.WGS84,title:null,type:{type:String,readOnly:!0,value:null,json:{read:!1}},url:{value:null},visible:{value:!0,nonNullable:!0,type:Boolean}},initialize:function(){this.when().catch(function(a){c.getLogger(this.declaredClass).error("#load()","Failed to load layer (title: '"+
this.title+"', id: '"+this.id+"')",a)}.bind(this))},createLayerView:function(c){return c?this.importLayerViewModule(c).then(function(a){a.default&&(a=a.default);return new a({layer:this,view:c})}.bind(this)):a.reject(new m("layerview:module-unavailable","No LayerView module available for layer '${layer.declaredClass}' and view type: '${view.type}'",{view:c,layer:this}))},destroyLayerView:function(a){a.destroy()},fetchAttributionData:function(){var c=this.attributionDataUrl;return this.hasAttributionData&&
c?n(c,{query:{f:"json"},responseType:"json"}).then(function(a){return a.data}):a.reject(new m("layer:no-attribution-data","Layer does not have attribution data"))},refresh:function(){this.emit("refresh")},importLayerViewModule:function(c){return a.reject(new m("layerview:override-method","Must provide implementation in '${layer.declaredClass}'",{view:c,layer:this}))}});e.fromArcGISServerUrl=function(c){"string"===typeof c&&(c={url:c});var f=a.create(function(a){b(["./support/arcgisLayers"],a)}).then(function(a){return a.fromUrl(c)});
f.catch(function(a){t.error("#fromArcGISServerUrl({ url: '"+c.url+"'})","Failed to create layer from arcgis server url",a)});return f};e.fromPortalItem=function(c){!c||c.portalItem||"object"!==typeof c||c.declaredClass&&"esri.portal.PortalItem"!==c.declaredClass||(c={portalItem:c});var d=a.create(function(a){b(["../portal/support/portalLayers"],a)}).then(function(a){return a.fromItem(c)});d.catch(function(a){var d=c&&c.portalItem;t.error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+
(d&&d.portal&&d.portal.url||f.portalUrl)+"', id: '"+(d&&d.id||"unset")+"')",a)});return d};return e})},"esri/core/Identifiable":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});var m=0;b=function(){return function(){Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:Date.now().toString(16)+"-object-"+m++})}}();e.Identifiable=b})},"esri/request":function(){define("require exports ./core/tsSupport/assignHelper dojo/Deferred dojo/has!host-webworker?./core/workers/request dojo/io-query ./core/urlUtils dojo/errors/CancelError dojo/request/xhr ./config ./core/deferredUtils ./core/Error ./core/global ./core/has ./core/lang ./core/promiseUtils ./core/urlUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v){function u(a,c){void 0===c&&(c=!1);v.isBlobProtocol(a.url)||v.isDataProtocol(a.url)||!a.content||(a.preventCache&&(a.content["request.preventCache"]=Date.now()),a.url=v.addQueryParameters(a.url,a.content));var f=new Image;f.crossOrigin=a.withCredentials?"use-credentials":"anonymous";var d=!1;return r.create(function(b,g){var e=function(){f.onload=f.onerror=f.onabort=null;c&&URL.revokeObjectURL(this.src);d||g(Error("Unable to load the resource"))};f.onload=
function(){f.onload=f.onerror=f.onabort=null;c&&URL.revokeObjectURL(this.src);d||b(this)};f.onerror=e;f.onabort=e;f.alt="";f.src=a.url},function(){d=!0;f.onload=f.onerror=f.onabort=null;f.src=""})}function z(a){a=new h.Url(a);return(a.host+(a.port?":"+a.port:"")).toLowerCase()}function y(){return I?I:I=r.create(function(a){b(["./identity/IdentityManager"],a)}).then(function(a){R=a})}function x(a,f){var d=!!a.useProxy,b=a.method||"auto";a=m({},a);a.content=a.content||{};a._ssl&&(a.url=a.url.replace(/^http:/i,
"https:"));var g=a.url,e=v.isBlobProtocol(g)||v.isDataProtocol(g);a._token&&(a.content.token=a._token);var h=0,n;e||(n=l.objectToQuery(a.content),h=n.length+g.length+1,p("esri-url-encodes-apostrophe")&&(h=n.replace(/'/g,"%27").length+g.length+1));a.timeout=null!=a.timeout?a.timeout:E.timeout;a.handleAs=a.handleAs||"json";try{var q=n=void 0,k=!e&&("post"===b||!!a.body||h>E.maxUrlLength),x=!e&&(d||!!v.getProxyRule(a.url)),z;if(z=!x&&"image"===a.handleAs&&E.proxyUrl&&!e){var y=v.getOrigin(a.url);z=!(!y||
t.endsWith(y,".arcgis.com")||v.hasSameOrigin(y,v.appUrl)||-1!==C._corsServers.indexOf(y)||v.isTrustedServer(y))}z&&(a.handleAs="blob");x&&(p("host-browser")||p("host-webworker"))&&(n=v.getProxyUrl(g),q=n.path,!k&&q.length+1+h>E.maxUrlLength&&(k=!0),n.query&&(a.content=m({},n.query,a.content)),k||(a.preventCache&&(a.content["request.preventCache"]=Date.now(),a.preventCache=!1),a.url=v.addQueryParameters(a.url,a.content),a.content=null),a.url=q+"?"+a.url);var B=a.headers;if(!e){!p("host-browser")&&
!p("host-webworker")||B&&B.hasOwnProperty("X-Requested-With")||(a.headers=B||{},a.headers["X-Requested-With"]=null);if(p("host-browser")&&f){var w=a.content&&a.content.token;w&&(f.set?f.set("token",w):f.append("token",w));a.contentType=!1}if(!a.hasOwnProperty("withCredentials"))if(d=x?q:g,v.isTrustedServer(d))a.withCredentials=!0;else if(R){var A=R.findServerInfo(d);A&&A.webTierAuth&&(a.withCredentials=!0)}}if(k)return"image"===a.handleAs&&(a.handleAs="blob"),a.body?(a.data=f||a.body,a.query=a.content):
a.data=a.content,delete a.body,delete a.content,!x&&p("safari")&&(a.url+=(-1===a.url.indexOf("?")?"?":"\x26")+"_ts\x3d"+Date.now()+Q++),c.post(a.url,a);var F;if(F="image"===a.handleAs){var G;a:{if(B)for(var V in B)if(B[V]){G=!0;break a}G=!1}F=!G}if(F)return u(a);"image"===a.handleAs&&(a.handleAs="blob");a.query=a.content;delete a.content;return c.get(a.url,a)}catch(na){return r.reject(na)}}function w(a,c,f,b){function e(a){a._pendingDfd=x(f,r);var c=!!a._pendingDfd.response;(a._pendingDfd.response||
a._pendingDfd).then(function(a){if(!c||!a.data)return a;E.proxyUrl&&!t.startsWith(a.url,E.proxyUrl)&&F(a.url);var f=a.getHeader("Content-Type");if(f&&(f=f.toLowerCase(),-1===f.indexOf("text/plain")&&-1===f.indexOf("application/json")))return a;f=a.data;if(f instanceof ArrayBuffer&&750>=f.byteLength)f=new Blob([f]);else if(!(f instanceof Blob&&750>=f.size))return a;var b=new d,g=new FileReader;g.readAsText(f);g.onloadend=function(){if(!g.error)try{var c=JSON.parse(g.result);c.error&&(Object.isExtensible(a)||
(a=m({},a)),a._jsonData=c)}catch(ra){}b.resolve(a)};return b.promise}).then(function(a){return c&&!a._jsonData&&"image"===b.requestOptions.responseType&&a.data instanceof Blob?(c=!1,f.url=URL.createObjectURL(a.data),u(f,!0)):a}).then(function(f){var d=c?f.data:f,g=c?f.getHeader.bind(f):V;if(d&&(f=c&&f._jsonData||d,f.error||"error"===f.status))throw d=t.mixin(Error(),f.error||f),d.getHeader=g,d;a.resolve({data:d,url:b.url,requestOptions:b.requestOptions,getHeader:g});a._pendingDfd=null}).catch(function(c){var d,
g,e,n;c&&(d=Number(c.code),g=c.hasOwnProperty("subcode")?Number(c.subcode):null,e=(e=c.messageCode)&&e.toUpperCase(),n=c.response);if(n&&0===n.status&&E.proxyUrl&&!p&&"post"!==f.method&&n.url&&!t.startsWith(n.url,E.proxyUrl))v.addProxyRule({proxyUrl:E.proxyUrl,urlPrefix:v.removeFile(v.urlToObject(f.url).path)}),w(a,!0,f,b);else{if(403===d&&(4===g||c.message&&-1<c.message.toLowerCase().indexOf("ssl")&&-1===c.message.toLowerCase().indexOf("permission"))){if(!f._ssl){f._ssl=f._sslFromServer=!0;w(a,!0,
f,b);return}}else if(h&&"no-prompt"!==f.authMode&&R._errorCodes&&-1!==R._errorCodes.indexOf(d)&&!R._isPublic(f.url)&&(403!==d||G&&-1===G.indexOf(e)&&(null==g||2===g&&f._token))){A(a,f,b,B("request:server",c,b));return}n&&0<n.status&&n.url&&E.proxyUrl&&!t.startsWith(n.url,E.proxyUrl)&&F(n.url);a.reject(B("request:server",c,b));a._pendingDfd=null}})}var p=f.body,h=f.useIdentity,n,r=null,q=p instanceof FormData;if(q||p&&p.elements)r=q?p:new FormData(p);var l=!!(-1!==f.url.toLowerCase().indexOf("token\x3d")||
f.content&&f.content.token||r&&r.get&&r.get("token")||p&&p.elements&&p.elements.token);c||(!h||l||f._token||R._isPublic(f.url)||(c=function(a){a&&(f._token=a.token,f._ssl=a.ssl)},"immediate"===f.authMode?n=R.getCredential(f.url).then(c):"no-prompt"===f.authMode?n=R.checkSignInStatus(f.url).then(c).catch(function(){}):c(R.findCredential(f.url))),c=function(a){delete f._credential;if(a){var c=!!f._ssl;a instanceof g?a.details.ssl=c:a.ssl=c}},a.then(function(a){(/\/sharing\/rest\/accounts\/self/i.test(f.url)||
/\/sharing\/rest\/portals\/self/i.test(f.url))&&!l&&!f._token&&a.data&&a.data.user&&a.data.user.username&&(v.isTrustedServer(f.url)||E.trustedServers.push(z(f.url)));var c=f._credential;if(c){var d=R.findServerInfo(c.server),d=d&&d.owningSystemUrl,b=void 0;d&&(d=d.replace(/\/?$/,"/sharing"),(b=R.findCredential(d,c.userId))&&-1===R._getIdenticalSvcIdx(d,b)&&b.resources.splice(0,0,d))}return a}).then(c,c));n?n.then(function(){a.isCanceled()||e(a)}).catch(function(c){a.reject(c)}):e(a);return a.promise}
function A(a,c,f,d){a._pendingDfd=R.getCredential(c.url,{error:d,token:c._token});a._pendingDfd.then(function(d){c._token=d.token;c._credential=d;c._ssl=c._sslFromServer||d.ssl;w(a,!0,c,f)}).catch(function(c){a.reject(c);a._pendingDfd=null})}function B(a,c,f){var d="Error",b={url:f.url,requestOptions:f.requestOptions,getHeader:V};if(c instanceof g)return c.details?(c.details=t.clone(c.details),c.details.url=f.url,c.details.requestOptions=f.requestOptions):c.details=b,c;if(c){var e=c.response;f=e&&
e.getHeader;var e=e&&e.status,p=c.message;f=c.getHeader||f;p&&(d=p);f&&(b.getHeader=f);b.httpStatus=(null!=c.httpCode?c.httpCode:c.code)||e;b.subCode=c.subcode;b.messageCode=c.messageCode;b.messages="string"===typeof c.details?[c.details]:c.details}a=new g(a,d,b);c&&"cancel"===c.dojoType&&(a.name="AbortError",a.dojoType="cancel");return a}function F(a){v.isBlobProtocol(a)||v.isDataProtocol(a)||(a=v.getOrigin(a))&&-1===C._corsServers.indexOf(a)&&C._corsServers.push(a)}function C(c,f){if(k&&q.invokeStaticMessage)return k.execute(c,
f);v.isBlobProtocol(c)||v.isDataProtocol(c)||(c=v.normalize(c));var d={url:c,requestOptions:m({},f)},b=v.getInterceptor(c);if(b){if(null!=b.responseData)return r.resolve({data:b.responseData,requestOptions:d.requestOptions,getHeader:V,url:c});b.headers&&(d.requestOptions.headers=m({},d.requestOptions.headers,b.headers));b.query&&(d.requestOptions.query=m({},d.requestOptions.query,b.query));if(b.before&&(f=b.before(d),null!=f))return f instanceof Error||f instanceof g?r.reject(B("request:interceptor",
f,d)):r.resolve({data:f,requestOptions:d.requestOptions,getHeader:V,url:d.url})}var e=m({url:d.url},d.requestOptions);e.content=e.query;delete e.query;e.preventCache=!!e.cacheBust;delete e.cacheBust;e.handleAs=e.responseType;delete e.responseType;"array-buffer"===e.handleAs&&(e.handleAs="arraybuffer");if("image"===e.handleAs){if(p("host-webworker"))return r.reject(B("request:invalid-parameters",Error("responseType 'image' is not supported in Web Workers or Node environment"),d))}else if(v.isDataProtocol(c))return r.reject(B("request:invalid-parameters",
Error("Data URLs are not supported for responseType \x3d "+e.handleAs),d));var t=E.useIdentity;"anonymous"===e.authMode&&(t=!1);e.useIdentity=t;e.urlObj=new h.Url(e.url);var l=n.makeDeferredCancellingPending(),u;d.requestOptions.signal&&(c=d.requestOptions.signal,u=function(){l.cancel(B("AbortError",new a("Request canceled"),d))},c.aborted?u():c.addEventListener("abort",u));r.resolve().then(function(){if(t&&!R)return y()}).catch(function(){}).then(function(){l.isCanceled()||w(l,!1,e,d)});return l.then(function(a){d.requestOptions.signal&&
d.requestOptions.signal.removeEventListener("abort",u);b&&b.after&&b.after(a);return a}).catch(function(a){d.requestOptions.signal&&d.requestOptions.signal.removeEventListener("abort",u);throw a;})}var E=f.request,G=["COM_0056","COM_0057"],Q=0,V=function(){return null},R,I;(C||(C={}))._corsServers=["https://server.arcgisonline.com","https://services.arcgisonline.com"];return C})},"esri/core/deferredUtils":function(){define(["dojo/Deferred"],function(b){var e={makeDeferredCancellingPending:function(){var m=
{},d=e._dfdCanceller.bind(null,m),d=new b(d);return m.deferred=d},_dfdCanceller:function(b){b=b.deferred?b.deferred:b;b.canceled=!0;var d=b._pendingDfd;b.isResolved()||!d||d.isResolved()||d.cancel();b._pendingDfd=null},_fixDfd:function(b){var d=b.then;b.then=function(b,e,h){if(b){var a=b;b=function(c){return c&&c._argsArray?a.apply(null,c):a(c)}}return d.call(this,b,e,h)};return b},_resDfd:function(b,d,e){var l=d.length;1===l?e?b.reject(d[0]):b.resolve(d[0]):1<l?(d._argsArray=!0,b.resolve(d)):b.resolve()}};
return e})},"esri/geometry/SpatialReference":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/accessorSupport/decorators ./support/spatialReferenceUtils".split(" "),function(b,e,m,d,k,l,h){b=function(a){function c(c){c=a.call(this)||this;c.latestWkid=null;c.wkid=null;c.wkt=null;return c}m(c,a);f=c;c.fromJSON=function(a){if(!a)return null;if(a.wkid){if(102100===a.wkid)return f.WebMercator;if(4326===a.wkid)return f.WGS84}var c=
new f;c.read(a);return c};c.prototype.normalizeCtorArgs=function(a){var c;return a&&"object"===typeof a?a:(c={},c["string"===typeof a?"wkt":"wkid"]=a,c)};Object.defineProperty(c.prototype,"isWGS84",{get:function(){return h.isWGS84(this)},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"isWebMercator",{get:function(){return h.isWebMercator(this)},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"isGeographic",{get:function(){return h.isGeographic(this)},enumerable:!0,
configurable:!0});Object.defineProperty(c.prototype,"isWrappable",{get:function(){return h.isWrappable(this)},enumerable:!0,configurable:!0});c.prototype.writeWkt=function(a,c){this.wkid||(c.wkt=a)};c.prototype.clone=function(){if(this===f.WGS84)return f.WGS84;if(this===f.WebMercator)return f.WebMercator;var a=new f;null!=this.wkid?(a.wkid=this.wkid,null!=this.latestWkid&&(a.latestWkid=this.latestWkid),null!=this.vcsWkid&&(a.vcsWkid=this.vcsWkid),null!=this.latestVcsWkid&&(a.latestVcsWkid=this.latestVcsWkid)):
null!=this.wkt&&(a.wkt=this.wkt);return a};c.prototype.equals=function(a){return h.equals(this,a)};c.prototype.toJSON=function(a){return this.write(null,a)};var f;c.GCS_NAD_1927=null;c.WGS84=null;c.WebMercator=null;d([l.property({dependsOn:["wkid"],readOnly:!0})],c.prototype,"isWGS84",null);d([l.property({dependsOn:["wkid"],readOnly:!0})],c.prototype,"isWebMercator",null);d([l.property({dependsOn:["wkid","wkt"],readOnly:!0})],c.prototype,"isGeographic",null);d([l.property({dependsOn:["wkid"],readOnly:!0})],
c.prototype,"isWrappable",null);d([l.property({type:Number,json:{write:!0}})],c.prototype,"latestWkid",void 0);d([l.property({type:Number,json:{write:!0,origins:{"web-scene":{write:{overridePolicy:function(){return{isRequired:null===this.wkt?!0:!1}}}}}}})],c.prototype,"wkid",void 0);d([l.property({type:String,json:{origins:{"web-scene":{write:{overridePolicy:function(){return{isRequired:null===this.wkid?!0:!1}}}}}}})],c.prototype,"wkt",void 0);d([l.writer("wkt"),l.writer("web-scene","wkt")],c.prototype,
"writeWkt",null);d([l.property({type:Number,json:{write:!0}})],c.prototype,"vcsWkid",void 0);d([l.property({type:Number,json:{write:!0}})],c.prototype,"latestVcsWkid",void 0);return c=f=d([l.subclass("esri.geometry.SpatialReference")],c)}(l.declared(k));b.prototype.toJSON.isDefaultToJSON=!0;b.GCS_NAD_1927=new b({wkid:4267,wkt:'GEOGCS["GCS_North_American_1927",DATUM["D_North_American_1927",SPHEROID["Clarke_1866",6378206.4,294.9786982]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]]'});
b.WGS84=new b(h.WGS84);b.WebMercator=new b(h.WebMercator);Object.freeze&&(Object.freeze(b.GCS_NAD_1927),Object.freeze(b.WGS84),Object.freeze(b.WebMercator));return b})},"esri/geometry/support/spatialReferenceUtils":function(){define(["require","exports","../../core/lang","./WKIDUnitConversion"],function(b,e,m,d){function k(a){return h(a)&&a.wkid?n[a.wkid]:null}function l(c){return h(c)&&!0===a[c.wkid]}function h(a){return null!=a&&(null!=a.wkid&&2E3<=a.wkid||null!=a.wkt)}Object.defineProperty(e,"__esModule",
{value:!0});var a={102113:!0,102100:!0,3857:!0,3785:!0},c={102113:!0,102100:!0,3857:!0,3785:!0,4326:!0};b=[-2.0037508342788905E7,2.0037508342788905E7];var f=[-2.0037508342787E7,2.0037508342787E7],n={102113:{wkTemplate:'PROJCS["WGS_1984_Web_Mercator",GEOGCS["GCS_WGS_1984_Major_Auxiliary_Sphere",DATUM["D_WGS_1984_Major_Auxiliary_Sphere",SPHEROID["WGS_1984_Major_Auxiliary_Sphere",6378137.0,0.0]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Mercator"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",{Central_Meridian}],PARAMETER["Standard_Parallel_1",0.0],UNIT["Meter",1.0]]',
valid:b,origin:f,dx:1E-5},102100:{wkTemplate:'PROJCS["WGS_1984_Web_Mercator_Auxiliary_Sphere",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Mercator_Auxiliary_Sphere"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",{Central_Meridian}],PARAMETER["Standard_Parallel_1",0.0],PARAMETER["Auxiliary_Sphere_Type",0.0],UNIT["Meter",1.0]]',valid:b,origin:f,
dx:1E-5},3785:{wkTemplate:'PROJCS["WGS_1984_Web_Mercator",GEOGCS["GCS_WGS_1984_Major_Auxiliary_Sphere",DATUM["D_WGS_1984_Major_Auxiliary_Sphere",SPHEROID["WGS_1984_Major_Auxiliary_Sphere",6378137.0,0.0]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Mercator"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",{Central_Meridian}],PARAMETER["Standard_Parallel_1",0.0],UNIT["Meter",1.0]]',valid:b,origin:f,dx:1E-5},3857:{wkTemplate:'PROJCS["WGS_1984_Web_Mercator_Auxiliary_Sphere",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Mercator_Auxiliary_Sphere"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",{Central_Meridian}],PARAMETER["Standard_Parallel_1",0.0],PARAMETER["Auxiliary_Sphere_Type",0.0],UNIT["Meter",1.0]]',
valid:b,origin:f,dx:1E-5},4326:{wkTemplate:'GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",{Central_Meridian}],UNIT["Degree",0.0174532925199433]]',altTemplate:'PROJCS["WGS_1984_Plate_Carree",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Plate_Carree"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",{Central_Meridian}],UNIT["Degrees",111319.491]]',
valid:[-180,180],origin:[-180,180],dx:1E-5}};e.equals=function(a,c){return a&&c?a===c?!0:null!=a.wkid||null!=c.wkid?a.wkid===c.wkid||l(a)&&l(c)||null!=c.latestWkid&&a.wkid===c.latestWkid||null!=a.latestWkid&&c.wkid===a.latestWkid:a.wkt&&c.wkt?a.wkt.toUpperCase()===c.wkt.toUpperCase():!1:!1};e.getInfo=k;e.isGeographic=function(a){return h(a)?a.wkid?null==d[a.wkid]:a.wkt?!!/^\s*GEOGCS/i.test(a.wkt):!1:!1};e.isWGS84=function(a){return h(a)&&4326===a.wkid};e.isWebMercator=l;e.isWrappable=function(a){return h(a)&&
!0===c[a.wkid]};e.isValid=h;e.WGS84={wkid:4326,wkt:m.substitute({Central_Meridian:"0.0"},k({wkid:4326}).wkTemplate)};e.WebMercator={wkid:102100,latestWkid:3857}})},"esri/geometry/support/WKIDUnitConversion":function(){define([],function(){var b,e={values:[1,.3048,.3048006096012192,.3047972654,.9143917962,.201166195164,.9143984146160287,.3047994715386762,20.11676512155263,20.11678249437587,.9143985307444408,.91439523,.3047997101815088,20.116756,5E4,15E4],units:"Meter Foot Foot_US Foot_Clarke Yard_Clarke Link_Clarke Yard_Sears Foot_Sears Chain_Sears Chain_Benoit_1895_B Yard_Indian Yard_Indian_1937 Foot_Gold_Coast Chain_Sears_1922_Truncated 50_Kilometers 150_Kilometers".split(" "),
2066:5,2136:12,2155:2,2157:0,2158:0,2159:12,2160:12,2204:2,2219:0,2220:0,2254:2,2255:2,2256:1,2265:1,2266:1,2267:2,2268:2,2269:1,2270:1,2271:2,2272:2,2273:1,2294:0,2295:0,2314:3,2899:2,2900:2,2901:1,2909:1,2910:1,2911:2,2912:2,2913:1,2914:1,2992:1,2993:0,2994:1,3080:1,3089:2,3090:0,3091:2,3102:2,3141:0,3142:0,3167:13,3359:2,3360:0,3361:1,3362:0,3363:2,3364:0,3365:2,3366:3,3404:2,3405:0,3406:0,3407:3,3439:0,3440:0,3479:1,3480:0,3481:1,3482:0,3483:1,3484:0,3485:2,3486:0,3487:2,3488:0,3489:0,3490:2,
3491:0,3492:2,3493:0,3494:2,3495:0,3496:2,3497:0,3498:2,3499:0,3500:2,3501:0,3502:2,3503:0,3504:2,3505:0,3506:2,3507:0,3508:2,3509:0,3510:2,3511:0,3512:2,3513:0,3514:0,3515:2,3516:0,3517:2,3518:0,3519:2,3520:0,3521:2,3522:0,3523:2,3524:0,3525:2,3526:0,3527:2,3528:0,3529:2,3530:0,3531:2,3532:0,3533:2,3534:0,3535:2,3536:0,3537:2,3538:0,3539:2,3540:0,3541:2,3542:0,3543:2,3544:0,3545:2,3546:0,3547:2,3548:0,3549:2,3550:0,3551:2,3552:0,3553:2,3582:2,3583:0,3584:2,3585:0,3586:2,3587:0,3588:1,3589:0,3590:1,
3591:0,3592:0,3593:1,3598:2,3599:0,3600:2,3605:1,3606:0,3607:0,3608:2,3609:0,3610:2,3611:0,3612:2,3613:0,3614:2,3615:0,3616:2,3617:0,3618:2,3619:0,3620:2,3621:0,3622:2,3623:0,3624:2,3625:0,3626:2,3627:0,3628:2,3629:0,3630:2,3631:0,3632:2,3633:0,3634:1,3635:0,3636:1,3640:2,3641:0,3642:2,3643:0,3644:1,3645:0,3646:1,3647:0,3648:1,3649:0,3650:2,3651:0,3652:2,3653:0,3654:2,3655:0,3656:1,3657:0,3658:2,3659:0,3660:2,3661:0,3662:2,3663:0,3664:2,3668:2,3669:0,3670:2,3671:0,3672:2,3673:0,3674:2,3675:0,3676:1,
3677:2,3678:0,3679:1,3680:2,3681:0,3682:1,3683:2,3684:0,3685:0,3686:2,3687:0,3688:2,3689:0,3690:2,3691:0,3692:2,3696:2,3697:0,3698:2,3699:0,3700:2,3793:0,3794:0,3812:0,3854:0,3857:0,3920:0,3978:0,3979:0,3991:2,3992:2,4026:0,4037:0,4038:0,4071:0,4082:0,4083:0,4087:0,4088:0,4217:2,4414:0,4415:0,4417:0,4434:0,4437:0,4438:2,4439:2,4462:0,4467:0,4471:0,4474:0,4559:0,4647:0,4822:0,4826:0,4839:0,5018:0,5048:0,5167:0,5168:0,5221:0,5223:0,5234:0,5235:0,5243:0,5247:0,5266:0,5316:0,5320:0,5321:0,5325:0,5337:0,
5361:0,5362:0,5367:0,5382:0,5383:0,5396:0,5456:0,5457:0,5469:0,5472:4,5490:0,5513:0,5514:0,5523:0,5559:0,5588:1,5589:3,5596:0,5627:0,5629:0,5641:0,5643:0,5644:0,5646:2,5654:2,5655:2,5659:0,5700:0,5825:0,5836:0,5837:0,5839:0,5842:0,5844:0,5858:0,5879:0,5880:0,5887:0,5890:0,6128:1,6129:1,6141:1,6204:0,6210:0,6211:0,6307:0,6312:0,6316:0,6362:0,6391:1,6405:1,6406:0,6407:1,6408:0,6409:1,6410:0,6411:2,6412:0,6413:2,6414:0,6415:0,6416:2,6417:0,6418:2,6419:0,6420:2,6421:0,6422:2,6423:0,6424:2,6425:0,6426:2,
6427:0,6428:2,6429:0,6430:2,6431:0,6432:2,6433:0,6434:2,6435:0,6436:2,6437:0,6438:2,6439:0,6440:0,6441:2,6442:0,6443:2,6444:0,6445:2,6446:0,6447:2,6448:0,6449:2,6450:0,6451:2,6452:0,6453:2,6454:0,6455:2,6456:0,6457:2,6458:0,6459:2,6460:0,6461:2,6462:0,6463:2,6464:0,6465:2,6466:0,6467:2,6468:0,6469:2,6470:0,6471:2,6472:0,6473:2,6474:0,6475:2,6476:0,6477:2,6478:0,6479:2,6484:2,6485:0,6486:2,6487:0,6488:2,6489:0,6490:2,6491:0,6492:2,6493:0,6494:1,6495:0,6496:1,6497:0,6498:0,6499:1,6500:0,6501:2,6502:0,
6503:2,6504:0,6505:2,6506:0,6507:2,6508:0,6509:0,6510:2,6515:1,6516:0,6518:0,6519:2,6520:0,6521:2,6522:0,6523:2,6524:0,6525:2,6526:0,6527:2,6528:0,6529:2,6530:0,6531:2,6532:0,6533:2,6534:0,6535:2,6536:0,6537:2,6538:0,6539:2,6540:0,6541:2,6542:0,6543:2,6544:0,6545:1,6546:0,6547:1,6548:0,6549:2,6550:0,6551:2,6552:0,6553:2,6554:0,6555:2,6556:0,6557:1,6558:0,6559:1,6560:0,6561:1,6562:0,6563:2,6564:0,6565:2,6566:0,6567:0,6568:2,6569:0,6570:1,6571:0,6572:2,6573:0,6574:2,6575:0,6576:2,6577:0,6578:2,6582:2,
6583:0,6584:2,6585:0,6586:2,6587:0,6588:2,6589:0,6590:2,6591:0,6592:0,6593:2,6594:0,6595:2,6596:0,6597:2,6598:0,6599:2,6600:0,6601:2,6602:0,6603:2,6605:2,6606:0,6607:2,6608:0,6609:2,6610:0,6611:0,6612:2,6613:0,6614:2,6615:0,6616:2,6617:0,6618:2,6633:2,6646:0,6703:0,6784:0,6785:1,6786:0,6787:1,6788:0,6789:1,6790:0,6791:1,6792:0,6793:1,6794:0,6795:1,6796:0,6797:1,6798:0,6799:1,6800:0,6801:1,6802:0,6803:1,6804:0,6805:1,6806:0,6807:1,6808:0,6809:1,6810:0,6811:1,6812:0,6813:1,6814:0,6815:1,6816:0,6817:1,
6818:0,6819:1,6820:0,6821:1,6822:0,6823:1,6824:0,6825:1,6826:0,6827:1,6828:0,6829:1,6830:0,6831:1,6832:0,6833:1,6834:0,6835:1,6836:0,6837:1,6838:0,6839:1,6840:0,6841:1,6842:0,6843:1,6844:0,6845:1,6846:0,6847:1,6848:0,6849:1,6850:0,6851:1,6852:0,6853:1,6854:0,6855:1,6856:0,6857:1,6858:0,6859:1,6860:0,6861:1,6862:0,6863:1,6867:0,6868:1,6870:0,6875:0,6876:0,6879:0,6880:2,6884:0,6885:1,6886:0,6887:1,6915:0,6922:0,6923:2,6924:0,6925:2,6962:0,6984:0,6991:0,7128:2,7131:0,7132:2,7142:0,7257:0,7258:2,7259:0,
7260:2,7261:0,7262:2,7263:0,7264:2,7265:0,7266:2,7267:0,7268:2,7269:0,7270:2,7271:0,7272:2,7273:0,7274:2,7275:0,7276:2,7277:0,7278:2,7279:0,7280:2,7281:0,7282:2,7283:0,7284:2,7285:0,7286:2,7287:0,7288:2,7289:0,7290:2,7291:0,7292:2,7293:0,7294:2,7295:0,7296:2,7297:0,7298:2,7299:0,7300:2,7301:0,7302:2,7303:0,7304:2,7305:0,7306:2,7307:0,7308:2,7309:0,7310:2,7311:0,7312:2,7313:0,7314:2,7315:0,7316:2,7317:0,7318:2,7319:0,7320:2,7321:0,7322:2,7323:0,7324:2,7325:0,7326:2,7327:0,7328:2,7329:0,7330:2,7331:0,
7332:2,7333:0,7334:2,7335:0,7336:2,7337:0,7338:2,7339:0,7340:2,7341:0,7342:2,7343:0,7344:2,7345:0,7346:2,7347:0,7348:2,7349:0,7350:2,7351:0,7352:2,7353:0,7354:2,7355:0,7356:2,7357:0,7358:2,7359:0,7360:2,7361:0,7362:2,7363:0,7364:2,7365:0,7366:2,7367:0,7368:2,7369:0,7370:2,7877:0,7878:0,7882:0,7883:0,7887:0,7899:0,7991:0,7992:0,8058:0,8059:0,8082:0,8083:0,8090:0,8091:2,8092:0,8093:2,8095:0,8096:2,8097:0,8098:2,8099:0,8100:2,8101:0,8102:2,8103:0,8104:2,8105:0,8106:2,8107:0,8108:2,8109:0,8110:2,8111:0,
8112:2,8113:0,8114:2,8115:0,8116:2,8117:0,8118:2,8119:0,8120:2,8121:0,8122:2,8123:0,8124:2,8125:0,8126:2,8127:0,8128:2,8129:0,8130:2,8131:0,8132:2,8133:0,8134:2,8135:0,8136:2,8137:0,8138:2,8139:0,8140:2,8141:0,8142:2,8143:0,8144:2,8145:0,8146:2,8147:0,8148:2,8149:0,8150:2,8151:0,8152:2,8153:0,8154:2,8155:0,8156:2,8157:0,8158:2,8159:0,8160:2,8161:0,8162:2,8163:0,8164:2,8165:0,8166:2,8167:0,8168:2,8169:0,8170:2,8171:0,8172:2,8173:0,8177:2,8179:0,8180:2,8181:0,8182:2,8184:0,8185:2,8187:0,8189:2,8191:0,
8193:2,8196:0,8197:2,8198:0,8200:2,8201:0,8202:2,8203:0,8204:2,8205:0,8206:2,8207:0,8208:2,8209:0,8210:2,8212:0,8213:2,8214:0,8216:2,8218:0,8220:2,8222:0,8224:2,8225:0,8226:2,8311:0,8312:1,8313:0,8314:1,8315:0,8316:1,8317:0,8318:1,8319:0,8320:1,8321:0,8322:1,8323:0,8324:1,8325:0,8326:1,8327:0,8328:1,8329:0,8330:1,8331:0,8332:1,8333:0,8334:1,8335:0,8336:1,8337:0,8338:1,8339:0,8340:1,8341:0,8342:1,8343:0,8344:1,8345:0,8346:1,8347:0,8348:1,8379:0,8380:2,8381:0,8382:2,8383:0,8384:2,8385:0,8387:2,8391:0,
8682:0,20499:0,20538:0,20539:0,20790:0,20791:0,21291:0,21292:0,21500:0,21817:0,21818:0,22032:0,22033:0,22091:0,22092:0,22332:0,22391:0,22392:0,22700:0,22770:0,22780:0,22832:0,23090:0,23095:0,23239:0,23240:0,23433:0,23700:0,24047:0,24048:0,24100:3,24200:0,24305:0,24306:0,24382:10,24383:0,24500:0,24547:0,24548:0,24571:9,24600:0,25E3:0,25231:0,25884:0,25932:0,26237:0,26331:0,26332:0,26432:0,26591:0,26592:0,26632:0,26692:0,27120:0,27200:0,27291:6,27292:6,27429:0,27492:0,27493:0,27500:0,27700:0,28232:0,
28600:0,28991:0,28992:0,29100:0,29101:0,29220:0,29221:0,29333:0,29635:0,29636:0,29701:0,29738:0,29739:0,29849:0,29850:0,29871:8,29872:7,29873:0,30200:5,30339:0,30340:0,30591:0,30592:0,30791:0,30792:0,30800:0,31028:0,31121:0,31154:0,31170:0,31171:0,31370:0,31528:0,31529:0,31600:0,31700:0,31838:0,31839:0,31900:0,31901:0,32061:0,32062:0,32098:0,32099:2,32100:0,32104:0,32161:0,32766:0,53048:0,53049:0,54090:0,54091:0,65061:2,65062:2,65161:0,65163:0,102041:2,102064:11,102068:14,102069:15,102118:2,102119:1,
102120:2,102121:2,102217:2,102218:0,102219:2,102220:2,102378:1,102379:1,102380:0,102381:1,102589:2,102599:2,102600:2,102604:2,102647:0,102704:2,102705:2,102706:0,102761:2,102762:0,102763:2,102764:0,102765:0,102766:2,102962:0,102963:0,102970:1,102974:2,102993:0,102994:0,102995:2,102996:2,103015:0,103016:2,103017:0,103018:2,103025:0,103026:0,103027:2,103028:2,103035:0,103036:0,103037:2,103038:2,103039:0,103040:0,103041:2,103042:2,103043:0,103044:0,103045:2,103046:2,103047:0,103048:0,103049:2,103050:2,
103051:0,103052:2,103053:0,103054:2,103055:0,103056:2,103057:0,103058:0,103059:2,103060:2,103061:0,103062:0,103063:2,103064:2,103069:2,103070:0,103071:0,103072:2,103073:2,103086:0,103087:0,103088:2,103089:2,103094:1,103095:0,103096:2,103103:0,103104:2,103105:0,103106:2,103121:0,103122:2,103123:0,103124:0,103125:1,103126:1,103127:0,103128:0,103129:2,103130:2,103131:0,103132:0,103133:2,103134:2,103135:0,103136:0,103137:1,103138:1,103139:0,103140:2,103141:0,103142:2,103143:0,103144:2,103145:0,103146:1,
103147:0,103148:0,103149:2,103150:2,103151:0,103152:2,103172:0,103173:2,103174:0,103175:0,103176:2,103177:2,103178:0,103179:0,103180:2,103181:2,103182:0,103183:0,103184:2,103185:2,103228:0,103229:0,103230:2,103231:2,103250:0,103251:2,103252:0,103253:2,103260:0,103261:0,103262:2,103263:2,103270:0,103271:0,103272:2,103273:2,103274:0,103275:0,103276:2,103277:2,103278:0,103279:0,103280:2,103281:2,103282:0,103283:0,103284:2,103285:2,103286:0,103287:2,103288:0,103289:2,103290:0,103291:2,103292:0,103293:0,
103294:2,103295:2,103296:0,103297:0,103298:2,103299:2,103376:2,103377:0,103378:0,103379:2,103380:2,103393:0,103394:0,103395:2,103396:2,103472:0,103473:1,103474:0,103475:2,103482:0,103483:2,103484:0,103485:2,103500:0,103501:2,103502:0,103503:0,103504:1,103505:1,103506:0,103507:0,103508:2,103509:2,103510:0,103511:0,103512:2,103513:2,103514:0,103515:2,103516:0,103517:2,103518:0,103519:2,103520:0,103521:1,103522:0,103523:0,103524:2,103525:2,103526:0,103527:2,103561:2,103562:2,103563:0,103564:0,103565:2,
103566:2,103567:0,103568:0,103569:2,103570:2,103584:0,103585:2,103695:2};for(b=2E3;2045>=b;b++)e[b]=0;for(b=2056;2065>=b;b++)e[b]=0;for(b=2067;2135>=b;b++)e[b]=0;for(b=2137;2154>=b;b++)e[b]=0;for(b=2161;2170>=b;b++)e[b]=0;for(b=2172;2193>=b;b++)e[b]=0;for(b=2195;2198>=b;b++)e[b]=0;for(b=2200;2203>=b;b++)e[b]=0;for(b=2205;2217>=b;b++)e[b]=0;for(b=2222;2224>=b;b++)e[b]=1;for(b=2225;2250>=b;b++)e[b]=2;for(b=2251;2253>=b;b++)e[b]=1;for(b=2257;2264>=b;b++)e[b]=2;for(b=2274;2279>=b;b++)e[b]=2;for(b=2280;2282>=
b;b++)e[b]=1;for(b=2283;2289>=b;b++)e[b]=2;for(b=2290;2292>=b;b++)e[b]=0;for(b=2308;2313>=b;b++)e[b]=0;for(b=2315;2491>=b;b++)e[b]=0;for(b=2494;2866>=b;b++)e[b]=0;for(b=2867;2869>=b;b++)e[b]=1;for(b=2870;2888>=b;b++)e[b]=2;for(b=2891;2895>=b;b++)e[b]=2;for(b=2896;2898>=b;b++)e[b]=1;for(b=2902;2908>=b;b++)e[b]=2;for(b=2915;2920>=b;b++)e[b]=2;for(b=2921;2923>=b;b++)e[b]=1;for(b=2924;2930>=b;b++)e[b]=2;for(b=2931;2962>=b;b++)e[b]=0;for(b=2964;2968>=b;b++)e[b]=2;for(b=2969;2973>=b;b++)e[b]=0;for(b=2975;2991>=
b;b++)e[b]=0;for(b=2995;3051>=b;b++)e[b]=0;for(b=3054;3079>=b;b++)e[b]=0;for(b=3081;3088>=b;b++)e[b]=0;for(b=3092;3101>=b;b++)e[b]=0;for(b=3106;3138>=b;b++)e[b]=0;for(b=3146;3151>=b;b++)e[b]=0;for(b=3153;3166>=b;b++)e[b]=0;for(b=3168;3172>=b;b++)e[b]=0;for(b=3174;3203>=b;b++)e[b]=0;for(b=3294;3358>=b;b++)e[b]=0;for(b=3367;3403>=b;b++)e[b]=0;for(b=3408;3416>=b;b++)e[b]=0;for(b=3417;3438>=b;b++)e[b]=2;for(b=3441;3446>=b;b++)e[b]=2;for(b=3447;3450>=b;b++)e[b]=0;for(b=3451;3459>=b;b++)e[b]=2;for(b=3460;3478>=
b;b++)e[b]=0;for(b=3554;3559>=b;b++)e[b]=0;for(b=3560;3570>=b;b++)e[b]=2;for(b=3571;3581>=b;b++)e[b]=0;for(b=3594;3597>=b;b++)e[b]=0;for(b=3601;3604>=b;b++)e[b]=0;for(b=3637;3639>=b;b++)e[b]=0;for(b=3665;3667>=b;b++)e[b]=0;for(b=3693;3695>=b;b++)e[b]=0;for(b=3701;3727>=b;b++)e[b]=0;for(b=3728;3739>=b;b++)e[b]=2;for(b=3740;3751>=b;b++)e[b]=0;for(b=3753;3760>=b;b++)e[b]=2;for(b=3761;3773>=b;b++)e[b]=0;for(b=3775;3777>=b;b++)e[b]=0;for(b=3779;3781>=b;b++)e[b]=0;for(b=3783;3785>=b;b++)e[b]=0;for(b=3788;3791>=
b;b++)e[b]=0;for(b=3797;3802>=b;b++)e[b]=0;for(b=3814;3816>=b;b++)e[b]=0;for(b=3825;3829>=b;b++)e[b]=0;for(b=3832;3841>=b;b++)e[b]=0;for(b=3844;3852>=b;b++)e[b]=0;for(b=3873;3885>=b;b++)e[b]=0;for(b=3890;3893>=b;b++)e[b]=0;for(b=3907;3912>=b;b++)e[b]=0;for(b=3942;3950>=b;b++)e[b]=0;for(b=3968;3970>=b;b++)e[b]=0;for(b=3973;3976>=b;b++)e[b]=0;for(b=3986;3989>=b;b++)e[b]=0;for(b=3994;3997>=b;b++)e[b]=0;for(b=4048;4051>=b;b++)e[b]=0;for(b=4056;4063>=b;b++)e[b]=0;for(b=4093;4096>=b;b++)e[b]=0;for(b=4390;4398>=
b;b++)e[b]=0;for(b=4399;4413>=b;b++)e[b]=2;for(b=4418;4433>=b;b++)e[b]=2;for(b=4455;4457>=b;b++)e[b]=2;for(b=4484;4489>=b;b++)e[b]=0;for(b=4491;4554>=b;b++)e[b]=0;for(b=4568;4589>=b;b++)e[b]=0;for(b=4652;4656>=b;b++)e[b]=0;for(b=4766;4800>=b;b++)e[b]=0;for(b=5014;5016>=b;b++)e[b]=0;for(b=5069;5072>=b;b++)e[b]=0;for(b=5105;5130>=b;b++)e[b]=0;for(b=5173;5188>=b;b++)e[b]=0;for(b=5253;5259>=b;b++)e[b]=0;for(b=5269;5275>=b;b++)e[b]=0;for(b=5292;5311>=b;b++)e[b]=0;for(b=5329;5331>=b;b++)e[b]=0;for(b=5343;5349>=
b;b++)e[b]=0;for(b=5355;5357>=b;b++)e[b]=0;for(b=5387;5389>=b;b++)e[b]=0;for(b=5459;5463>=b;b++)e[b]=0;for(b=5479;5482>=b;b++)e[b]=0;for(b=5518;5520>=b;b++)e[b]=0;for(b=5530;5539>=b;b++)e[b]=0;for(b=5550;5552>=b;b++)e[b]=0;for(b=5562;5583>=b;b++)e[b]=0;for(b=5623;5625>=b;b++)e[b]=2;for(b=5631;5639>=b;b++)e[b]=0;for(b=5649;5653>=b;b++)e[b]=0;for(b=5663;5680>=b;b++)e[b]=0;for(b=5682;5685>=b;b++)e[b]=0;for(b=5875;5877>=b;b++)e[b]=0;for(b=5921;5940>=b;b++)e[b]=0;for(b=6050;6125>=b;b++)e[b]=0;for(b=6244;6275>=
b;b++)e[b]=0;for(b=6328;6348>=b;b++)e[b]=0;for(b=6350;6356>=b;b++)e[b]=0;for(b=6366;6372>=b;b++)e[b]=0;for(b=6381;6387>=b;b++)e[b]=0;for(b=6393;6404>=b;b++)e[b]=0;for(b=6480;6483>=b;b++)e[b]=0;for(b=6511;6514>=b;b++)e[b]=0;for(b=6579;6581>=b;b++)e[b]=0;for(b=6619;6624>=b;b++)e[b]=0;for(b=6625;6627>=b;b++)e[b]=2;for(b=6628;6632>=b;b++)e[b]=0;for(b=6634;6637>=b;b++)e[b]=0;for(b=6669;6692>=b;b++)e[b]=0;for(b=6707;6709>=b;b++)e[b]=0;for(b=6720;6723>=b;b++)e[b]=0;for(b=6732;6738>=b;b++)e[b]=0;for(b=6931;6933>=
b;b++)e[b]=0;for(b=6956;6959>=b;b++)e[b]=0;for(b=7005;7007>=b;b++)e[b]=0;for(b=7057;7070>=b;b++)e[b]=2;for(b=7074;7082>=b;b++)e[b]=0;for(b=7109;7118>=b;b++)e[b]=0;for(b=7119;7127>=b;b++)e[b]=1;for(b=7374;7376>=b;b++)e[b]=0;for(b=7528;7586>=b;b++)e[b]=0;for(b=7587;7645>=b;b++)e[b]=2;for(b=7755;7787>=b;b++)e[b]=0;for(b=7791;7795>=b;b++)e[b]=0;for(b=7799;7801>=b;b++)e[b]=0;for(b=7803;7805>=b;b++)e[b]=0;for(b=7825;7831>=b;b++)e[b]=0;for(b=7845;7859>=b;b++)e[b]=0;for(b=8013;8032>=b;b++)e[b]=0;for(b=8065;8068>=
b;b++)e[b]=1;for(b=8836;8840>=b;b++)e[b]=0;for(b=8857;8859>=b;b++)e[b]=0;for(b=20002;20032>=b;b++)e[b]=0;for(b=20062;20092>=b;b++)e[b]=0;for(b=20135;20138>=b;b++)e[b]=0;for(b=20248;20258>=b;b++)e[b]=0;for(b=20348;20358>=b;b++)e[b]=0;for(b=20436;20440>=b;b++)e[b]=0;for(b=20822;20824>=b;b++)e[b]=0;for(b=20934;20936>=b;b++)e[b]=0;for(b=21035;21037>=b;b++)e[b]=0;for(b=21095;21097>=b;b++)e[b]=0;for(b=21148;21150>=b;b++)e[b]=0;for(b=21413;21423>=b;b++)e[b]=0;for(b=21473;21483>=b;b++)e[b]=0;for(b=21780;21782>=
b;b++)e[b]=0;for(b=21891;21894>=b;b++)e[b]=0;for(b=21896;21899>=b;b++)e[b]=0;for(b=22171;22177>=b;b++)e[b]=0;for(b=22181;22187>=b;b++)e[b]=0;for(b=22191;22197>=b;b++)e[b]=0;for(b=22234;22236>=b;b++)e[b]=0;for(b=22521;22525>=b;b++)e[b]=0;for(b=22991;22994>=b;b++)e[b]=0;for(b=23028;23038>=b;b++)e[b]=0;for(b=23830;23853>=b;b++)e[b]=0;for(b=23866;23872>=b;b++)e[b]=0;for(b=23877;23884>=b;b++)e[b]=0;for(b=23886;23894>=b;b++)e[b]=0;for(b=23946;23948>=b;b++)e[b]=0;for(b=24311;24313>=b;b++)e[b]=0;for(b=24342;24347>=
b;b++)e[b]=0;for(b=24370;24374>=b;b++)e[b]=10;for(b=24375;24381>=b;b++)e[b]=0;for(b=24718;24721>=b;b++)e[b]=0;for(b=24817;24821>=b;b++)e[b]=0;for(b=24877;24882>=b;b++)e[b]=0;for(b=24891;24893>=b;b++)e[b]=0;for(b=25391;25395>=b;b++)e[b]=0;for(b=25828;25838>=b;b++)e[b]=0;for(b=26191;26195>=b;b++)e[b]=0;for(b=26391;26393>=b;b++)e[b]=0;for(b=26701;26722>=b;b++)e[b]=0;for(b=26729;26799>=b;b++)e[b]=2;for(b=26801;26803>=b;b++)e[b]=2;for(b=26811;26813>=b;b++)e[b]=2;for(b=26847;26870>=b;b++)e[b]=2;for(b=26891;26899>=
b;b++)e[b]=0;for(b=26901;26923>=b;b++)e[b]=0;for(b=26929;26946>=b;b++)e[b]=0;for(b=26948;26998>=b;b++)e[b]=0;for(b=27037;27040>=b;b++)e[b]=0;for(b=27205;27232>=b;b++)e[b]=0;for(b=27258;27260>=b;b++)e[b]=0;for(b=27391;27398>=b;b++)e[b]=0;for(b=27561;27564>=b;b++)e[b]=0;for(b=27571;27574>=b;b++)e[b]=0;for(b=27581;27584>=b;b++)e[b]=0;for(b=27591;27594>=b;b++)e[b]=0;for(b=28191;28193>=b;b++)e[b]=0;for(b=28348;28358>=b;b++)e[b]=0;for(b=28402;28432>=b;b++)e[b]=0;for(b=28462;28492>=b;b++)e[b]=0;for(b=29118;29122>=
b;b++)e[b]=0;for(b=29168;29172>=b;b++)e[b]=0;for(b=29177;29185>=b;b++)e[b]=0;for(b=29187;29195>=b;b++)e[b]=0;for(b=29900;29903>=b;b++)e[b]=0;for(b=30161;30179>=b;b++)e[b]=0;for(b=30491;30494>=b;b++)e[b]=0;for(b=30729;30732>=b;b++)e[b]=0;for(b=31251;31259>=b;b++)e[b]=0;for(b=31265;31268>=b;b++)e[b]=0;for(b=31275;31279>=b;b++)e[b]=0;for(b=31281;31297>=b;b++)e[b]=0;for(b=31461;31469>=b;b++)e[b]=0;for(b=31491;31495>=b;b++)e[b]=0;for(b=31917;31922>=b;b++)e[b]=0;for(b=31965;32E3>=b;b++)e[b]=0;for(b=32001;32003>=
b;b++)e[b]=2;for(b=32005;32031>=b;b++)e[b]=2;for(b=32033;32060>=b;b++)e[b]=2;for(b=32064;32067>=b;b++)e[b]=2;for(b=32074;32077>=b;b++)e[b]=2;for(b=32081;32086>=b;b++)e[b]=0;for(b=32107;32130>=b;b++)e[b]=0;for(b=32133;32158>=b;b++)e[b]=0;for(b=32164;32167>=b;b++)e[b]=2;for(b=32180;32199>=b;b++)e[b]=0;for(b=32201;32260>=b;b++)e[b]=0;for(b=32301;32360>=b;b++)e[b]=0;for(b=32601;32662>=b;b++)e[b]=0;for(b=32664;32667>=b;b++)e[b]=2;for(b=32701;32761>=b;b++)e[b]=0;for(b=53001;53004>=b;b++)e[b]=0;for(b=53008;53019>=
b;b++)e[b]=0;for(b=53021;53032>=b;b++)e[b]=0;for(b=53034;53037>=b;b++)e[b]=0;for(b=53042;53046>=b;b++)e[b]=0;for(b=53074;53080>=b;b++)e[b]=0;for(b=54001;54004>=b;b++)e[b]=0;for(b=54008;54019>=b;b++)e[b]=0;for(b=54021;54032>=b;b++)e[b]=0;for(b=54034;54037>=b;b++)e[b]=0;for(b=54042;54046>=b;b++)e[b]=0;for(b=54048;54053>=b;b++)e[b]=0;for(b=54074;54080>=b;b++)e[b]=0;for(b=102001;102040>=b;b++)e[b]=0;for(b=102042;102063>=b;b++)e[b]=0;for(b=102065;102067>=b;b++)e[b]=0;for(b=102070;102117>=b;b++)e[b]=0;
for(b=102122;102216>=b;b++)e[b]=0;for(b=102221;102377>=b;b++)e[b]=0;for(b=102382;102388>=b;b++)e[b]=0;for(b=102389;102398>=b;b++)e[b]=2;for(b=102399;102444>=b;b++)e[b]=0;for(b=102445;102447>=b;b++)e[b]=2;for(b=102448;102458>=b;b++)e[b]=0;for(b=102459;102468>=b;b++)e[b]=2;for(b=102469;102499>=b;b++)e[b]=0;for(b=102500;102519>=b;b++)e[b]=1;for(b=102520;102524>=b;b++)e[b]=0;for(b=102525;102529>=b;b++)e[b]=2;for(b=102530;102588>=b;b++)e[b]=0;for(b=102590;102598>=b;b++)e[b]=0;for(b=102601;102603>=b;b++)e[b]=
0;for(b=102605;102628>=b;b++)e[b]=0;for(b=102629;102646>=b;b++)e[b]=2;for(b=102648;102700>=b;b++)e[b]=2;for(b=102701;102703>=b;b++)e[b]=0;for(b=102707;102730>=b;b++)e[b]=2;for(b=102733;102758>=b;b++)e[b]=2;for(b=102767;102900>=b;b++)e[b]=0;for(b=102965;102969>=b;b++)e[b]=0;for(b=102971;102973>=b;b++)e[b]=0;for(b=102975;102989>=b;b++)e[b]=0;for(b=102990;102992>=b;b++)e[b]=1;for(b=102997;103002>=b;b++)e[b]=0;for(b=103003;103008>=b;b++)e[b]=2;for(b=103009;103011>=b;b++)e[b]=0;for(b=103012;103014>=b;b++)e[b]=
2;for(b=103019;103021>=b;b++)e[b]=0;for(b=103022;103024>=b;b++)e[b]=2;for(b=103029;103031>=b;b++)e[b]=0;for(b=103032;103034>=b;b++)e[b]=2;for(b=103065;103068>=b;b++)e[b]=0;for(b=103074;103076>=b;b++)e[b]=0;for(b=103077;103079>=b;b++)e[b]=1;for(b=103080;103082>=b;b++)e[b]=0;for(b=103083;103085>=b;b++)e[b]=2;for(b=103090;103093>=b;b++)e[b]=0;for(b=103097;103099>=b;b++)e[b]=0;for(b=103100;103102>=b;b++)e[b]=2;for(b=103107;103109>=b;b++)e[b]=0;for(b=103110;103112>=b;b++)e[b]=2;for(b=103113;103116>=b;b++)e[b]=
0;for(b=103117;103120>=b;b++)e[b]=2;for(b=103153;103157>=b;b++)e[b]=0;for(b=103158;103162>=b;b++)e[b]=2;for(b=103163;103165>=b;b++)e[b]=0;for(b=103166;103168>=b;b++)e[b]=1;for(b=103169;103171>=b;b++)e[b]=2;for(b=103186;103188>=b;b++)e[b]=0;for(b=103189;103191>=b;b++)e[b]=2;for(b=103192;103195>=b;b++)e[b]=0;for(b=103196;103199>=b;b++)e[b]=2;for(b=103200;103224>=b;b++)e[b]=0;for(b=103225;103227>=b;b++)e[b]=1;for(b=103232;103237>=b;b++)e[b]=0;for(b=103238;103243>=b;b++)e[b]=2;for(b=103244;103246>=b;b++)e[b]=
0;for(b=103247;103249>=b;b++)e[b]=2;for(b=103254;103256>=b;b++)e[b]=0;for(b=103257;103259>=b;b++)e[b]=2;for(b=103264;103266>=b;b++)e[b]=0;for(b=103267;103269>=b;b++)e[b]=2;for(b=103300;103375>=b;b++)e[b]=0;for(b=103381;103383>=b;b++)e[b]=0;for(b=103384;103386>=b;b++)e[b]=1;for(b=103387;103389>=b;b++)e[b]=0;for(b=103390;103392>=b;b++)e[b]=2;for(b=103397;103399>=b;b++)e[b]=0;for(b=103400;103471>=b;b++)e[b]=2;for(b=103476;103478>=b;b++)e[b]=0;for(b=103479;103481>=b;b++)e[b]=2;for(b=103486;103488>=b;b++)e[b]=
0;for(b=103489;103491>=b;b++)e[b]=2;for(b=103492;103495>=b;b++)e[b]=0;for(b=103496;103499>=b;b++)e[b]=2;for(b=103528;103543>=b;b++)e[b]=0;for(b=103544;103548>=b;b++)e[b]=2;for(b=103549;103551>=b;b++)e[b]=0;for(b=103552;103554>=b;b++)e[b]=1;for(b=103555;103557>=b;b++)e[b]=2;for(b=103558;103560>=b;b++)e[b]=0;for(b=103571;103573>=b;b++)e[b]=0;for(b=103574;103576>=b;b++)e[b]=2;for(b=103577;103580>=b;b++)e[b]=0;for(b=103581;103583>=b;b++)e[b]=2;for(b=103600;103694>=b;b++)e[b]=0;for(b=103700;103793>=b;b++)e[b]=
2;for(b=103794;103871>=b;b++)e[b]=0;for(b=103900;103971>=b;b++)e[b]=2;return e})},"esri/geometry/Extent":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/lang ../core/accessorSupport/decorators ./Geometry ./Point ./SpatialReference ./support/contains ./support/intersects ./support/spatialReferenceUtils ./support/webMercatorUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g,q){function p(a,c,f){return null==c?f:null==f?c:a(c,f)}b=function(b){function e(){for(var a=
0;a<arguments.length;a++);a=b.call(this)||this;a.type="extent";a.xmin=0;a.ymin=0;a.mmin=void 0;a.zmin=void 0;a.xmax=0;a.ymax=0;a.mmax=void 0;a.zmax=void 0;return a}m(e,b);h=e;e.prototype.normalizeCtorArgs=function(a,f,d,b,e){return!a||"esri.geometry.SpatialReference"!==a.declaredClass&&null==a.wkid?"object"===typeof a?(a.spatialReference=null==a.spatialReference?c.WGS84:a.spatialReference,a):{xmin:a,ymin:f,xmax:d,ymax:b,spatialReference:null==e?c.WGS84:e}:{spatialReference:a,xmin:0,ymin:0,xmax:0,
ymax:0}};Object.defineProperty(e.prototype,"center",{get:function(){var c=new a({x:.5*(this.xmin+this.xmax),y:.5*(this.ymin+this.ymax),spatialReference:this.spatialReference});this.hasZ&&(c.z=.5*(this.zmin+this.zmax));this.hasM&&(c.m=.5*(this.mmin+this.mmax));return c},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"extent",{get:function(){return this.clone()},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"hasM",{get:function(){return null!=this.mmin&&null!=
this.mmax},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"hasZ",{get:function(){return null!=this.zmin&&null!=this.zmax},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"height",{get:function(){return Math.abs(this.ymax-this.ymin)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"width",{get:function(){return Math.abs(this.xmax-this.xmin)},enumerable:!0,configurable:!0});e.prototype.centerAt=function(a){var c=this.center;return null!=a.z&&this.hasZ?
this.offset(a.x-c.x,a.y-c.y,a.z-c.z):this.offset(a.x-c.x,a.y-c.y)};e.prototype.clone=function(){var a=new h;a.xmin=this.xmin;a.ymin=this.ymin;a.xmax=this.xmax;a.ymax=this.ymax;a.spatialReference=this.spatialReference;null!=this.zmin&&(a.zmin=this.zmin,a.zmax=this.zmax);null!=this.mmin&&(a.mmin=this.mmin,a.mmax=this.mmax);return a};e.prototype.contains=function(a){if(!a)return!1;var c=this.spatialReference,d=a.spatialReference;c&&d&&!c.equals(d)&&q.canProject(c,d)&&(a=c.isWebMercator?q.geographicToWebMercator(a):
q.webMercatorToGeographic(a,!0));return"point"===a.type?f.extentContainsPoint(this,a):"extent"===a.type?f.extentContainsExtent(this,a):!1};e.prototype.equals=function(a){if(!a)return!1;var c=this.spatialReference,f=a.spatialReference;c&&f&&!c.equals(f)&&q.canProject(c,f)&&(a=c.isWebMercator?q.geographicToWebMercator(a):q.webMercatorToGeographic(a,!0));return this.xmin===a.xmin&&this.ymin===a.ymin&&this.zmin===a.zmin&&this.mmin===a.mmin&&this.xmax===a.xmax&&this.ymax===a.ymax&&this.zmax===a.zmax&&
this.mmax===a.mmax};e.prototype.expand=function(a){a=.5*(1-a);var c=this.width*a,f=this.height*a;this.xmin+=c;this.ymin+=f;this.xmax-=c;this.ymax-=f;this.hasZ&&(c=(this.zmax-this.zmin)*a,this.zmin+=c,this.zmax-=c);this.hasM&&(a*=this.mmax-this.mmin,this.mmin+=a,this.mmax-=a);return this};e.prototype.intersects=function(a){if(!a)return!1;var c=this.spatialReference,f=a.spatialReference;c&&f&&!c.equals(f)&&q.canProject(c,f)&&(a=c.isWebMercator?q.geographicToWebMercator(a):q.webMercatorToGeographic(a,
!0));c=n.getExtentIntersector(a.type);return"mesh"!==a.type?c(this,a):c(this,a.extent)};e.prototype.normalize=function(){var a=this._normalize(!1,!0);return Array.isArray(a)?a:[a]};e.prototype.offset=function(a,c,f){this.xmin+=a;this.ymin+=c;this.xmax+=a;this.ymax+=c;null!=f&&(this.zmin+=f,this.zmax+=f);return this};e.prototype.shiftCentralMeridian=function(){return this._normalize(!0)};e.prototype.union=function(a){this.xmin=Math.min(this.xmin,a.xmin);this.ymin=Math.min(this.ymin,a.ymin);this.xmax=
Math.max(this.xmax,a.xmax);this.ymax=Math.max(this.ymax,a.ymax);if(this.hasZ||a.hasZ)this.zmin=p(Math.min,this.zmin,a.zmin),this.zmax=p(Math.max,this.zmax,a.zmax);if(this.hasM||a.hasM)this.mmin=p(Math.min,this.mmin,a.mmin),this.mmax=p(Math.max,this.mmax,a.mmax);return this};e.prototype.intersection=function(a){if(!this.intersects(a))return null;this.xmin=Math.max(this.xmin,a.xmin);this.ymin=Math.max(this.ymin,a.ymin);this.xmax=Math.min(this.xmax,a.xmax);this.ymax=Math.min(this.ymax,a.ymax);if(this.hasZ||
a.hasZ)this.zmin=p(Math.max,this.zmin,a.zmin),this.zmax=p(Math.min,this.zmax,a.zmax);if(this.hasM||a.hasM)this.mmin=p(Math.max,this.mmin,a.mmin),this.mmax=p(Math.min,this.mmax,a.mmax);return this};e.prototype.toJSON=function(a){return this.write(null,a)};e.prototype._shiftCM=function(a){void 0===a&&(a=g.getInfo(this.spatialReference));if(!a||!this.spatialReference)return this;var f=this.spatialReference,d=this._getCM(a);if(d){var b=f.isWebMercator?q.webMercatorToGeographic(d):d;this.xmin-=d.x;this.xmax-=
d.x;f.isWebMercator||(b.x=this._normalizeX(b.x,a).x);this.spatialReference=new c(k.substitute({Central_Meridian:b.x},f.isWGS84?a.altTemplate:a.wkTemplate))}return this};e.prototype._getCM=function(a){var c=null,f=a.valid;a=f[0];var f=f[1],d=this.xmin,b=this.xmax;d>=a&&d<=f&&b>=a&&b<=f||(c=this.center);return c};e.prototype._normalize=function(a,c,f){var d=this.spatialReference;if(!d)return this;f=f||g.getInfo(d);if(!f)return this;var b=this._getParts(f).map(function(a){return a.extent});if(2>b.length)return b[0]||
this;if(2<b.length)return a?this._shiftCM(f):this.set({xmin:f.valid[0],xmax:f.valid[1]});if(a)return this._shiftCM(f);if(c)return b;var e=!0,p=!0;b.forEach(function(a){a.hasZ||(e=!1);a.hasM||(p=!1)});return{rings:b.map(function(a){var c=[[a.xmin,a.ymin],[a.xmin,a.ymax],[a.xmax,a.ymax],[a.xmax,a.ymin],[a.xmin,a.ymin]];if(e)for(var f=(a.zmax-a.zmin)/2,d=0;d<c.length;d++)c[d].push(f);if(p)for(a=(a.mmax-a.mmin)/2,d=0;d<c.length;d++)c[d].push(a);return c}),hasZ:e,hasM:p,spatialReference:d}};e.prototype._getParts=
function(a){var c=this.cache._parts;if(!c){var c=[],f=this.ymin,d=this.ymax,b=this.spatialReference,e=this.width,p=this.xmin,n=this.xmax,t=void 0;a=a||g.getInfo(b);var r=a.valid,l=r[0],q=r[1],t=this._normalizeX(this.xmin,a),k=t.x,r=t.frameId,t=this._normalizeX(this.xmax,a),v=t.x;a=t.frameId;t=k===v&&0<e;if(e>2*q){e=new h(p<n?k:v,f,q,d,b);p=new h(l,f,p<n?v:k,d,b);n=new h(0,f,q,d,b);f=new h(l,f,0,d,b);d=[];b=[];e.contains(n)&&d.push(r);e.contains(f)&&b.push(r);p.contains(n)&&d.push(a);p.contains(f)&&
b.push(a);for(l=r+1;l<a;l++)d.push(l),b.push(l);c.push({extent:e,frameIds:[r]},{extent:p,frameIds:[a]},{extent:n,frameIds:d},{extent:f,frameIds:b})}else k>v||t?c.push({extent:new h(k,f,q,d,b),frameIds:[r]},{extent:new h(l,f,v,d,b),frameIds:[a]}):c.push({extent:new h(k,f,v,d,b),frameIds:[r]});this.cache._parts=c}a=this.hasZ;f=this.hasM;if(a||f)for(r={},a&&(r.zmin=this.zmin,r.zmax=this.zmax),f&&(r.mmin=this.mmin,r.mmax=this.mmax),a=0;a<c.length;a++)c[a].extent.set(r);return c};e.prototype._normalizeX=
function(a,c){var f=c.valid;c=f[0];var d=f[1],f=2*d,b=0;a>d?(c=Math.ceil(Math.abs(a-d)/f),a-=c*f,b=c):a<c&&(c=Math.ceil(Math.abs(a-c)/f),a+=c*f,b=-c);return{x:a,frameId:b}};var h;d([l.property({dependsOn:"xmin ymin zmin mmin xmax ymax zmax mmax spatialReference".split(" ")})],e.prototype,"cache",void 0);d([l.property({readOnly:!0,dependsOn:["cache"]})],e.prototype,"center",null);d([l.property({readOnly:!0,dependsOn:["cache"]})],e.prototype,"extent",null);d([l.property({readOnly:!0,dependsOn:["mmin",
"mmax"],json:{write:{enabled:!1,overridePolicy:null}}})],e.prototype,"hasM",null);d([l.property({readOnly:!0,dependsOn:["zmin","zmax"],json:{write:{enabled:!1,overridePolicy:null}}})],e.prototype,"hasZ",null);d([l.property({readOnly:!0,dependsOn:["ymin","ymax"]})],e.prototype,"height",null);d([l.property({readOnly:!0,dependsOn:["xmin","xmax"]})],e.prototype,"width",null);d([l.property({type:Number,json:{write:!0}})],e.prototype,"xmin",void 0);d([l.property({type:Number,json:{write:!0}})],e.prototype,
"ymin",void 0);d([l.property({type:Number,json:{origins:{"web-scene":{write:!1}},write:{overridePolicy:function(){return{enabled:this.hasM}}}}})],e.prototype,"mmin",void 0);d([l.property({type:Number,json:{origins:{"web-scene":{write:!1}},write:{overridePolicy:function(){return{enabled:this.hasZ}}}}})],e.prototype,"zmin",void 0);d([l.property({type:Number,json:{write:!0}})],e.prototype,"xmax",void 0);d([l.property({type:Number,json:{write:!0}})],e.prototype,"ymax",void 0);d([l.property({type:Number,
json:{origins:{"web-scene":{write:!1}},write:{overridePolicy:function(){return{enabled:this.hasM}}}}})],e.prototype,"mmax",void 0);d([l.property({type:Number,json:{origins:{"web-scene":{write:!1}},write:{overridePolicy:function(){return{enabled:this.hasZ}}}}})],e.prototype,"zmax",void 0);return e=h=d([l.subclass("esri.geometry.Extent")],e)}(l.declared(h));b.prototype.toJSON.isDefaultToJSON=!0;return b})},"esri/geometry/Geometry":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/accessorSupport/decorators ./SpatialReference".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(){var c=a.call(this)||this;c.type=null;c.extent=null;c.hasM=!1;c.hasZ=!1;c.spatialReference=h.WGS84;return c}m(c,a);Object.defineProperty(c.prototype,"cache",{get:function(){return{}},enumerable:!0,configurable:!0});c.prototype.readSpatialReference=function(a,c){if(a instanceof h)return a;if(null!=a){var f=new h;f.read(a,c);return f}return a};c.prototype.clone=function(){console.warn(".clone() is not implemented for "+this.declaredClass);return null};
c.prototype.clearCache=function(){this.notifyChange("cache")};c.prototype.getCacheValue=function(a){return this.cache[a]};c.prototype.setCacheValue=function(a,c){this.cache[a]=c};d([l.property()],c.prototype,"type",void 0);d([l.property({readOnly:!0,dependsOn:["spatialReference"]})],c.prototype,"cache",null);d([l.property({readOnly:!0,dependsOn:["spatialReference"]})],c.prototype,"extent",void 0);d([l.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],c.prototype,
"hasM",void 0);d([l.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],c.prototype,"hasZ",void 0);d([l.property({type:h,json:{write:!0}})],c.prototype,"spatialReference",void 0);d([l.reader("spatialReference")],c.prototype,"readSpatialReference",null);return c=d([l.subclass("esri.geometry.Geometry")],c)}(l.declared(k))})},"esri/geometry/Point":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Logger ../core/accessorSupport/decorators ../core/accessorSupport/ensureType ./Geometry ./SpatialReference ./support/offset ./support/spatialReferenceUtils ./support/webMercatorUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g){function q(a){return a&&("esri.geometry.SpatialReference"===a.declaredClass||null!=a.wkid)}var p=[0,0],t=k.getLogger("esri.geometry.Point");b=function(a){function b(c,f,d,b,e){c=a.call(this)||this;c.x=0;c.y=0;c.z=void 0;c.m=void 0;c.type="point";return c}m(b,a);e=b;b.copy=function(a,c){c._set("x",a._get("x"));c._set("y",a._get("y"));c._set("z",a._get("z"));c._set("m",a._get("m"));a=a._get("spatialReference");c._set("spatialReference",Object.isFrozen(a)?a:a.clone())};
b.distance=function(a,c){var f=a.x-c.x,d=a.y-c.y;a=a.hasZ&&c.hasZ?a.z-c.z:0;return Math.sqrt(f*f+d*d+a*a)};b.prototype.normalizeCtorArgs=function(a,f,d,b,e){var h;if(Array.isArray(a))h=a,e=f,a=h[0],f=h[1],d=h[2],b=h[3];else if(a&&"object"===typeof a){if(h=a,a=null!=h.x?h.x:h.longitude,f=null!=h.y?h.y:h.latitude,d=null!=h.z?h.z:h.altitude,b=h.m,(e=h.spatialReference)&&"esri.geometry.SpatialReference"!==e.declaredClass&&(e=new c(e)),null!=h.longitude||null!=h.latitude)null==h.longitude?t.warn(".longitude\x3d",
"Latitude was defined without longitude"):null==h.latitude?t.warn(".latitude\x3d","Longitude was defined without latitude"):!h.declaredClass&&e&&e.isWebMercator&&(f=g.lngLatToXY(h.longitude,h.latitude,p),a=f[0],f=f[1])}else q(d)?(e=d,d=null):q(b)&&(e=b,b=null);a={x:a,y:f};null==a.x&&null!=a.y?t.warn(".y\x3d","Y coordinate was defined without an X coordinate"):null==a.y&&null!=a.x&&t.warn(".x\x3d","X coordinate was defined without a Y coordinate");null!=e&&(a.spatialReference=e);null!=d&&(a.z=d);null!=
b&&(a.m=b);return a};Object.defineProperty(b.prototype,"hasM",{get:function(){return void 0!==this.m},set:function(a){a!==this.hasM&&(this._set("m",a?0:void 0),this._set("hasM",a))},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"hasZ",{get:function(){return void 0!==this.z},set:function(a){a!==this.hasZ&&(this._set("z",a?0:void 0),this._set("hasZ",a))},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"latitude",{get:function(){var a=this._get("spatialReference");
if(a){if(a.isWebMercator)return g.xyToLngLat(this.x,this.y,p)[1];if(a.isWGS84)return this._get("y")}return null},set:function(a){var c=this._get("spatialReference");c&&(c.isWebMercator?this._set("y",g.lngLatToXY(this.x,a,p)[1]):c.isWGS84&&this._set("y",a),this._set("latitude",a))},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"longitude",{get:function(){var a=this._get("spatialReference");if(a){if(a.isWebMercator)return g.xyToLngLat(this._get("x"),this._get("y"),p)[0];if(a.isWGS84)return this._get("x")}return null},
set:function(a){var c=this._get("spatialReference");c&&(c.isWebMercator?this._set("x",g.lngLatToXY(a,this._get("y"),p)[0]):c.isWGS84&&this._set("x",a),this._set("longitude",a))},enumerable:!0,configurable:!0});b.prototype.writeX=function(a,c,f){c[f]=isNaN(a)?"NaN":a};b.prototype.readX=function(a){return"string"===typeof a?NaN:a};b.prototype.clone=function(){var a=new e;a.x=this.x;a.y=this.y;a.z=this.z;a.m=this.m;a.spatialReference=this.spatialReference;return a};b.prototype.copy=function(a){e.copy(a,
this);return this};b.prototype.equals=function(a){var c;if(!a)return!1;var f=this.x,d=this.y,b=this.z,e=this.m,p=this.spatialReference,h=a.z,n=a.m,t=a.x;c=a.y;a=a.spatialReference;if(!p.equals(a))if(p.isWebMercator&&a.isWGS84)c=g.lngLatToXY(t,c),t=c[0],c=c[1],a=p;else if(p.isWGS84&&a.isWebMercator)c=g.xyToLngLat(t,c),t=c[0],c=c[1],a=p;else return!1;return f===t&&d===c&&b===h&&e===n&&p.wkid===a.wkid};b.prototype.offset=function(a,c,d){return f.offsetPoint(this,a,c,d)};b.prototype.normalize=function(){if(!this.spatialReference)return this;
var a=n.getInfo(this.spatialReference);if(!a)return this;var c=this.x,f=a.valid,a=f[0],d=f[1],f=2*d;c>d?(a=Math.ceil(Math.abs(c-d)/f),c-=a*f):c<a&&(a=Math.ceil(Math.abs(c-a)/f),c+=a*f);this._set("x",c);return this};b.prototype.distance=function(a){return e.distance(this,a)};b.prototype.toArray=function(){var a=this.hasZ,c=this.hasM;return a&&c?[this.x,this.y,this.z,this.m]:a?[this.x,this.y,this.z]:c?[this.x,this.y,this.m]:[this.x,this.y]};b.prototype.toJSON=function(a){return this.write(null,a)};
var e;d([l.property({dependsOn:["x","y","z","m","spatialReference"]})],b.prototype,"cache",void 0);d([l.property({type:Boolean,dependsOn:["m"],json:{read:!1,write:{enabled:!1,overridePolicy:null}}})],b.prototype,"hasM",null);d([l.property({type:Boolean,dependsOn:["z"],json:{read:!1,write:{enabled:!1,overridePolicy:null}}})],b.prototype,"hasZ",null);d([l.property({type:Number,dependsOn:["y"]})],b.prototype,"latitude",null);d([l.property({type:Number,dependsOn:["x"]})],b.prototype,"longitude",null);
d([l.property({type:Number,json:{type:[Number,String],write:{isRequired:!0,allowNull:!0}}}),l.cast(function(a){return isNaN(a)?a:h.ensureNumber(a)})],b.prototype,"x",void 0);d([l.writer("x")],b.prototype,"writeX",null);d([l.reader("x")],b.prototype,"readX",null);d([l.property({type:Number,json:{write:!0}})],b.prototype,"y",void 0);d([l.property({type:Number,json:{write:{overridePolicy:function(){return{enabled:this.hasZ}}}}})],b.prototype,"z",void 0);d([l.property({type:Number,json:{write:{overridePolicy:function(){return{enabled:this.hasM}}}}})],
b.prototype,"m",void 0);return b=e=d([l.subclass("esri.geometry.Point")],b)}(l.declared(a));b.prototype.toJSON.isDefaultToJSON=!0;return b})},"esri/geometry/support/offset":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.offsetPoint=function(b,d,e,l){b.x+=d;b.y+=e;null!=l&&null!=b.z&&(b.z+=l);return b};e.offsetCoordsX=function(b,d){b[0]+=d;return b}})},"esri/geometry/support/webMercatorUtils":function(){define("require exports ../../core/lang ../../core/wgs84Constants ../SpatialReference ./spatialReferenceUtils".split(" "),
function(b,e,m,d,k,l){function h(a,c,f,d,b){var e;if("x"in a&&"x"in b)c=c(a.x,a.y,g,d),b.x=c[0],b.y=c[1];else if("xmin"in a&&"xmin"in b)e=c(a.xmin,a.ymin,g,d),b.xmin=e[0],b.ymin=e[1],c=c(a.xmax,a.ymax,g,d),b.xmax=c[0],b.ymax=c[1];else if("paths"in a&&"paths"in b||"rings"in a&&"rings"in b){e="paths"in a?a.paths:a.rings;var p=[],h=void 0;for(a=0;a<e.length;a++){var n=e[a],h=[];p.push(h);for(var t=0;t<n.length;t++)h.push(c(n[t][0],n[t][1],[0,0],d)),2<n[t].length&&h[t].push(n[t][2]),3<n[t].length&&h[t].push(n[t][3])}"paths"in
b?b.paths=p:b.rings=p}else if("points"in a&&"points"in b){e=a.points;p=[];for(a=0;a<e.length;a++)p[a]=c(e[a][0],e[a][1],[0,0],d),2<e[a].length&&p[a].push(e[a][2]),3<e[a].length&&p[a].push(e[a][3]);b.points=p}else if("type"in a&&"mesh"===a.type&&"type"in b&&"mesh"===b.type&&(e=a.vertexAttributes&&a.vertexAttributes.position,p=b.vertexAttributes&&b.vertexAttributes.position,e))for(h=[0,0],a=0;a<e.length;a+=3)c(e[a],e[a+1],h,d),p[a]=h[0],p[a+1]=h[1];b.spatialReference=f;return b}function a(a,c){a=a&&
(null!=a.wkid||null!=a.wkt?a:a.spatialReference);c=c&&(null!=c.wkid||null!=c.wkt?c:c.spatialReference);return a&&c?l.equals(c,a)?!0:l.isWebMercator(c)&&l.isWGS84(a)||l.isWebMercator(a)&&l.isWGS84(c):!1}function c(a,c,f){void 0===f&&(f=[0,0]);89.99999<c?c=89.99999:-89.99999>c&&(c=-89.99999);c*=.017453292519943;f[0]=.017453292519943*a*n;f[1]=.5*n*Math.log((1+Math.sin(c))/(1-Math.sin(c)));return f}function f(a,c,f,d){void 0===f&&(f=[0,0]);void 0===d&&(d=!1);a=a/n*57.29577951308232;f[0]=d?a:a-360*Math.floor((a+
180)/360);f[1]=57.29577951308232*(Math.PI/2-2*Math.atan(Math.exp(-1*c/n)));return f}Object.defineProperty(e,"__esModule",{value:!0});var n=d.wgs84Radius,g=[0,0];e.canProject=a;e.project=function(d,b){var e=d&&d.spatialReference;b=b&&(null!=b.wkid||null!=b.wkt?b:b.spatialReference);return a(e,b)?l.equals(e,b)?m.clone(d):l.isWebMercator(b)?h(d,c,k.WebMercator,!1,m.clone(d)):l.isWGS84(b)?h(d,f,k.WGS84,!1,m.clone(d)):null:null};e.lngLatToXY=c;e.xyToLngLat=f;e.geographicToWebMercator=function(a,f,d){void 0===
f&&(f=!1);void 0===d&&(d=m.clone(a));return h(a,c,k.WebMercator,f,d)};e.webMercatorToGeographic=function(a,c,d){void 0===c&&(c=!1);void 0===d&&(d=m.clone(a));return h(a,f,k.WGS84,c,d)}})},"esri/core/wgs84Constants":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.wgs84Radius=6378137;e.wgs84InverseFlattening=298.257223563;e.wgs84Flattening=1/e.wgs84InverseFlattening;e.wgs84PolarRadius=e.wgs84Radius*(1-e.wgs84Flattening);e.wgs84Eccentricity=.0818191908426215})},
"esri/geometry/support/contains":function(){define(["require","exports"],function(b,e){function m(a,c){return d(a,c[0],c[1])}function d(a,c,f,d){return c>=a.xmin&&c<=a.xmax&&f>=a.ymin&&f<=a.ymax?null!=d&&a.hasZ?d>=a.zmin&&d<=a.zmax:!0:!1}function k(a,c){if(a=a.rings)if(Array.isArray(a[0][0])){for(var f=!1,d=0,b=a.length;d<b;d++)f=l(f,a[d],c);c=f}else c=l(!1,a,c);else c=!1;return c}function l(a,c,f){var d=f[0];f=f[1];for(var b=0,e=0,h=c.length;e<h;e++){b++;b===h&&(b=0);var t=c[e],r=t[0],t=t[1],l=c[b],
k=l[0],l=l[1];(t<f&&l>=f||l<f&&t>=f)&&r+(f-t)/(l-t)*(k-r)<d&&(a=!a)}return a}Object.defineProperty(e,"__esModule",{value:!0});var h=[0,0];e.extentContainsPoint=function(a,c){return d(a,c.x,c.y,c.z)};e.extentContainsMultipoint=function(a,c){if(!c.points||c.points.length)return!1;var f=0;for(c=c.points;f<c.length;f++)if(!m(a,c[f]))return!1;return!0};e.extentContainsExtent=function(a,c){var f=c.xmin,b=c.ymin,e=c.zmin,h=c.xmax,p=c.ymax,t=c.zmax;return a.hasZ&&c.hasZ?d(a,f,b,e)&&d(a,f,p,e)&&d(a,h,p,e)&&
d(a,h,b,e)&&d(a,f,b,t)&&d(a,f,p,t)&&d(a,h,p,t)&&d(a,h,b,t):d(a,f,b)&&d(a,f,p)&&d(a,h,p)&&d(a,h,b)};e.extentContainsCoords2D=m;e.extentContainsCoords3D=function(a,c){return d(a,c[0],c[1],c[2])};e.polygonContainsPoint=function(a,c){h[1]=c.y;h[0]=c.x;return k(a,h)};e.polygonContainsCoords=k})},"esri/geometry/support/intersects":function(){define(["require","exports","./contains"],function(b,e,m){function d(a,c){return m.extentContainsPoint(a,c)}function k(a,c){var f=a.hasZ&&c.hasZ,d;if(a.xmin<=c.xmin){if(d=
c.xmin,a.xmax<d)return!1}else if(d=a.xmin,c.xmax<d)return!1;if(a.ymin<=c.ymin){if(d=c.ymin,a.ymax<d)return!1}else if(d=a.ymin,c.ymax<d)return!1;if(f&&c.hasZ)if(a.zmin<=c.zmin){if(f=c.zmin,a.zmax<f)return!1}else if(f=a.zmin,c.zmax<f)return!1;return!0}function l(a,c){var f=c.hasZ?m.extentContainsCoords3D:m.extentContainsCoords2D,d=0;for(c=c.points;d<c.length;d++)if(f(a,c[d]))return!0;return!1}function h(a,f){n[0]=a.xmin;n[1]=a.ymax;g[0]=a.xmax;g[1]=a.ymax;q[0]=a.xmin;q[1]=a.ymin;p[0]=a.xmax;p[1]=a.ymin;
for(var d=0,b=t;d<b.length;d++)if(m.polygonContainsCoords(f,b[d]))return!0;d=0;for(f=f.rings;d<f.length;d++)if(b=f[d],b.length){var e=b[0];if(m.extentContainsCoords2D(a,e))return!0;for(var h=1;h<b.length;h++){var l=b[h];if(m.extentContainsCoords2D(a,l)||c(e,l,r))return!0;e=l}}return!1}function a(a,f){n[0]=a.xmin;n[1]=a.ymax;g[0]=a.xmax;g[1]=a.ymax;q[0]=a.xmin;q[1]=a.ymin;p[0]=a.xmax;p[1]=a.ymin;f=f.paths;for(var d=0;d<f.length;d++){var b=f[d];if(f.length){var e=b[0];if(m.extentContainsCoords2D(a,
e))return!0;for(var h=1;h<b.length;h++){var t=b[h];if(m.extentContainsCoords2D(a,t)||c(e,t,r))return!0;e=t}}}return!1}function c(a,c,d){for(var b=0;b<d.length;b++)if(f(a,c,d[b][0],d[b][1]))return!0;return!1}function f(a,c,f,d,b){var e=a[0];a=a[1];var g=c[0];c=c[1];var h=f[0],p=f[1];f=d[0]-h;var h=e-h,n=g-e;d=d[1]-p;var p=a-p,t=c-a,r=d*n-f*t;if(0===r)return!1;f=(f*p-d*h)/r;h=(n*p-t*h)/r;return 0<=f&&1>=f&&0<=h&&1>=h?(b&&(b[0]=e+f*(g-e),b[1]=a+f*(c-a)),!0):!1}Object.defineProperty(e,"__esModule",{value:!0});
e.extentIntersectsPoint=d;e.extentIntersectsExtent=k;e.extentIntersectsMultipoint=l;var n=[0,0],g=[0,0],q=[0,0],p=[0,0],t=[n,g,q,p],r=[[q,n],[n,g],[g,p],[p,q]];e.extentIntersectsPolygon=h;e.extentIntersectsPolyline=a;var v=[0,0];e.isSelfIntersecting=function(a){for(var c=0;c<a.length;c++){for(var d=a[c],b=0;b<d.length-1;b++)for(var e=d[b],g=d[b+1],h=c+1;h<a.length;h++)for(var p=0;p<a[h].length-1;p++){var n=a[h][p],t=a[h][p+1],r=f(e,g,n,t,v);if(r&&!(v[0]===e[0]&&v[1]===e[1]||v[0]===n[0]&&v[1]===n[1]||
v[0]===g[0]&&v[1]===g[1]||v[0]===t[0]&&v[1]===t[1]))return!0}p=d.length;if(!(4>=p))for(b=0;b<p-3;b++){var l=p-1;0===b&&(l=p-2);e=d[b];g=d[b+1];for(h=b+2;h<l;h++)if(n=d[h],t=d[h+1],(r=f(e,g,n,t,v))&&!(v[0]===e[0]&&v[1]===e[1]||v[0]===n[0]&&v[1]===n[1]||v[0]===g[0]&&v[1]===g[1]||v[0]===t[0]&&v[1]===t[1]))return!0}}return!1};e.segmentIntersects=f;e.getExtentIntersector=function(c){switch(c){case "esriGeometryEnvelope":case "extent":return k;case "esriGeometryMultipoint":case "multipoint":return l;case "esriGeometryPoint":case "point":return d;
case "esriGeometryPolygon":case "polygon":return h;case "esriGeometryPolyline":case "polyline":return a;case "mesh":return k}}})},"esri/portal/Portal":function(){define("require exports ../core/tsSupport/assignHelper ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/paramHelper dojo/_base/kernel ../config ../kernel ../request ../core/Error ../core/JSONSupport ../core/lang ../core/Loadable ../core/promiseUtils ../core/accessorSupport/decorators ../geometry/Extent ./PortalQueryParams ./PortalQueryResult ./PortalUser".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y){var x,w={Bookmark:function(){return t.create(function(a){return b(["./Bookmark"],a)})},Portal:function(){return t.create(function(a){return b(["./Portal"],a)})},PortalFolder:function(){return t.create(function(a){return b(["./PortalFolder"],a)})},PortalGroup:function(){return t.create(function(a){return b(["./PortalGroup"],a)})},PortalItem:function(){return t.create(function(a){return b(["./PortalItem"],a)})},PortalQueryParams:function(){return t.create(function(a){return b(["./PortalQueryParams"],
a)})},PortalQueryResult:function(){return t.create(function(a){return b(["./PortalQueryResult"],a)})},PortalRating:function(){return t.create(function(a){return b(["./PortalRating"],a)})},PortalUser:function(){return t.create(function(a){return b(["./PortalUser"],a)})}};return function(e){function g(c){c=e.call(this)||this;c.access=null;c.allSSL=!1;c.authMode="auto";c.authorizedCrossOriginDomains=null;c.basemapGalleryGroupQuery=null;c.bingKey=null;c.canListApps=!1;c.canListData=!1;c.canListPreProvisionedItems=
!1;c.canProvisionDirectPurchase=!1;c.canSearchPublic=!0;c.canShareBingPublic=!1;c.canSharePublic=!1;c.canSignInArcGIS=!1;c.canSignInIDP=!1;c.colorSetsGroupQuery=null;c.commentsEnabled=!1;c.created=null;c.culture=null;c.customBaseUrl=null;c.defaultBasemap=null;c.defaultExtent=null;c.defaultVectorBasemap=null;c.description=null;c.eueiEnabled=!1;c.featuredGroups=null;c.featuredItemsGroupQuery=null;c.galleryTemplatesGroupQuery=null;c.livingAtlasGroupQuery=null;c.hasCategorySchema=!1;c.helperServices=
null;c.homePageFeaturedContent=null;c.homePageFeaturedContentCount=null;c.httpPort=null;c.httpsPort=null;c.id=null;c.ipCntryCode=null;c.isPortal=!1;c.layerTemplatesGroupQuery=null;c.maxTokenExpirationMinutes=null;c.modified=null;c.name=null;c.portalHostname=null;c.portalMode=null;c.portalProperties=null;c.region=null;c.rotatorPanels=null;c.showHomePageDescription=!1;c.supportsHostedServices=!1;c.symbolSetsGroupQuery=null;c.templatesGroupQuery=null;c.units=null;c.url=a.portalUrl;c.urlKey=null;c.user=
null;c.useStandardizedQuery=!1;c.useVectorBasemaps=!1;c.vectorBasemapGalleryGroupQuery=null;return c}d(g,e);p=g;g.prototype.normalizeCtorArgs=function(a){return"string"===typeof a?{url:a}:a};g.prototype.destroy=function(){this._esriId_credentialCreateHandle&&(this._esriId_credentialCreateHandle.remove(),this._esriId_credentialCreateHandle=null)};g.prototype.readAuthorizedCrossOriginDomains=function(c){if(c)for(var f=0;f<c.length;f++){var d=c[f];-1===a.request.trustedServers.indexOf(d)&&a.request.trustedServers.push(d)}return c};
g.prototype.readDefaultBasemap=function(a){return a?(a=x.fromJSON(a),a.portalItem={portal:this},a):null};g.prototype.readDefaultVectorBasemap=function(a){return a?(a=x.fromJSON(a),a.portalItem={portal:this},a):null};Object.defineProperty(g.prototype,"extraQuery",{get:function(){var a=!(this.user&&this.user.orgId)||this.canSearchPublic;return this.id&&!a?" AND orgid:"+this.id:null},enumerable:!0,configurable:!0});Object.defineProperty(g.prototype,"isOrganization",{get:function(){return!!this.access},
enumerable:!0,configurable:!0});Object.defineProperty(g.prototype,"restUrl",{get:function(){var a=this.url;if(a)var c=a.indexOf("/sharing"),a=0<c?a.substring(0,c):this.url.replace(/\/+$/,""),a=a+"/sharing/rest";return a},enumerable:!0,configurable:!0});Object.defineProperty(g.prototype,"thumbnailUrl",{get:function(){var a=this.restUrl,c=this.thumbnail;return a&&c?this._normalizeSSL(a+"/portals/self/resources/"+c):null},enumerable:!0,configurable:!0});g.prototype.readUrlKey=function(a){return a?a.toLowerCase():
a};g.prototype.readUser=function(a){var c=null;a&&(c=y.fromJSON(a),c.portal=this);return c};g.prototype.load=function(){var a=this,f=t.create(function(a){return b(["../Basemap"],a)}).then(function(a){x=a}).then(function(){return a._fetchSelf()}).then(function(f){if(c.id){var d=c.id;a.credential=d.findCredential(a.restUrl);a.credential||a.authMode!==p.AUTH_MODE_AUTO||(a._esriId_credentialCreateHandle=d.on("credential-create",function(){d.findCredential(a.restUrl)&&a._signIn()}))}a.read(f)});this.addResolvingPromise(f);
return this.when()};g.prototype.fetchBasemaps=function(a){var c=new u;c.query=a||(this.useVectorBasemaps?this.vectorBasemapGalleryGroupQuery:this.basemapGalleryGroupQuery);c.disableExtraQuery=!0;return this.queryGroups(c).then(function(a){c.num=100;c.query='type:"Web Map" -type:"Web Application"';return a.total?(a=a.results[0],c.sortField=a.sortField||"name",c.sortOrder=a.sortOrder||"desc",a.queryItems(c)):null}).then(function(a){return a&&a.total?a.results.filter(function(a){return"Web Map"===a.type}).map(function(a){return new x({portalItem:a})}):
[]})};g.prototype.fetchCategorySchema=function(){return this.hasCategorySchema?this._request(this.restUrl+"/portals/self/categorySchema").then(function(a){return a.categorySchema}):t.resolve([])};g.prototype.fetchFeaturedGroups=function(){var a=this.featuredGroups,c=new u;c.num=100;c.sortField="title";if(a&&a.length){for(var f=[],d=0;d<a.length;d++){var b=a[d];f.push('(title:"'+b.title+'" AND owner:'+b.owner+")")}c.query=f.join(" OR ");return this.queryGroups(c).then(function(a){return a.results})}return t.resolve([])};
g.prototype.fetchRegions=function(){return this._request(this.restUrl+"/portals/regions",{query:{culture:this.user&&this.user.culture||this.culture||h.locale}})};g.getDefault=function(){p._default||(p._default=new p);return p._default};g.prototype.queryGroups=function(a){return this._queryPortal("/community/groups",a,"PortalGroup")};g.prototype.queryItems=function(a){return this._queryPortal("/search",a,"PortalItem")};g.prototype.queryUsers=function(a){a.sortField||(a.sortField="username");return this._queryPortal("/community/users",
a,"PortalUser")};g.prototype.toJSON=function(){throw new n("internal:not-yet-implemented","Portal.toJSON is not yet implemented");};g.prototype._fetchSelf=function(a,c){void 0===a&&(a=this.authMode);void 0===c&&(c=!1);var f=this.restUrl+"/portals/self";a={authMode:a,query:{culture:h.locale}};"auto"===a.authMode&&(a.authMode="no-prompt");c&&(a.query.default=!0);return this._request(f,a)};g.prototype._queryPortal=function(a,c,f){var d=this,b=function(f){return d._request(d.restUrl+a,c.toRequestOptions(d)).then(function(a){var b=
c.clone();b.start=a.nextStart;return new z({nextQueryParams:b,queryParams:c,total:a.total,results:p._resultsToTypedArray(f,{portal:d},a)})}).then(function(a){return t.all(a.results.map(function(c){return"function"===typeof c.when?c.when():a})).then(function(){return a},function(){return a})})};return f&&w[f]?w[f]().then(function(a){return b(a)}):b()};g.prototype._signIn=function(){var a=this;if(this.authMode===p.AUTH_MODE_ANONYMOUS)return t.reject(new n("portal:invalid-auth-mode",'Current "authMode"\' is "'+
this.authMode+'"'));if("failed"===this.loadStatus)return t.reject(this.loadError);var f=function(c){return t.resolve().then(function(){if("not-loaded"===a.loadStatus)return c||(a.authMode="immediate"),a.load().then(function(){return null});if("loading"===a.loadStatus)return a.load().then(function(){if(a.credential)return null;a.credential=c;return a._fetchSelf("immediate")});if(a.user&&a.credential===c)return null;a.credential=c;return a._fetchSelf("immediate")}).then(function(c){c&&a.read(c)})};
return c.id?c.id.getCredential(this.restUrl).then(function(a){return f(a)}):f(this.credential)};g.prototype._normalizeSSL=function(a){return a.replace(/^http:/i,"https:").replace(":7080",":7443")};g.prototype._normalizeUrl=function(a){var c=this.credential&&this.credential.token;return this._normalizeSSL(c?a+(-1<a.indexOf("?")?"\x26":"?")+"token\x3d"+c:a)};g.prototype._requestToTypedArray=function(a,c,f){var d=this,e=function(f){return d._request(a,c).then(function(a){var c=p._resultsToTypedArray(f,
{portal:d},a);return t.all(c.map(function(c){return"function"===typeof c.when?c.when():a})).then(function(){return c},function(){return c})})};return f?t.create(function(a){return b(["./"+f],a)}).then(function(a){return e(a)}):e()};g.prototype._request=function(a,c){var d=this.authMode===p.AUTH_MODE_ANONYMOUS?"anonymous":"auto",b=null,e="auto",g={f:"json"},h="json";c&&(c.authMode&&(d=c.authMode),c.body&&(b=c.body),c.method&&(e=c.method),c.query&&(g=m({},g,c.query)),c.responseType&&(h=c.responseType));
c={authMode:d,body:b,method:e,query:g,responseType:h,timeout:0};return f(this._normalizeSSL(a),c).then(function(a){return a.data})};g._resultsToTypedArray=function(a,c,f){if(f){if(f=f.listings||f.notifications||f.userInvitations||f.tags||f.items||f.groups||f.comments||f.provisions||f.results||f.relatedItems||f,a||c)f=f.map(function(f){f=q.mixin(a?a.fromJSON(f):f,c);"function"===typeof f.load&&f.load();return f})}else f=[];return f};var p;g.AUTH_MODE_ANONYMOUS="anonymous";g.AUTH_MODE_AUTO="auto";g.AUTH_MODE_IMMEDIATE=
"immediate";k([r.property()],g.prototype,"access",void 0);k([r.property()],g.prototype,"allSSL",void 0);k([r.property()],g.prototype,"authMode",void 0);k([r.property()],g.prototype,"authorizedCrossOriginDomains",void 0);k([r.reader("authorizedCrossOriginDomains")],g.prototype,"readAuthorizedCrossOriginDomains",null);k([r.property()],g.prototype,"basemapGalleryGroupQuery",void 0);k([r.property()],g.prototype,"bingKey",void 0);k([r.property()],g.prototype,"canListApps",void 0);k([r.property()],g.prototype,
"canListData",void 0);k([r.property()],g.prototype,"canListPreProvisionedItems",void 0);k([r.property()],g.prototype,"canProvisionDirectPurchase",void 0);k([r.property()],g.prototype,"canSearchPublic",void 0);k([r.property()],g.prototype,"canShareBingPublic",void 0);k([r.property()],g.prototype,"canSharePublic",void 0);k([r.property()],g.prototype,"canSignInArcGIS",void 0);k([r.property()],g.prototype,"canSignInIDP",void 0);k([r.property()],g.prototype,"colorSetsGroupQuery",void 0);k([r.property()],
g.prototype,"commentsEnabled",void 0);k([r.property({type:Date})],g.prototype,"created",void 0);k([r.property()],g.prototype,"credential",void 0);k([r.property()],g.prototype,"culture",void 0);k([r.property()],g.prototype,"currentVersion",void 0);k([r.property()],g.prototype,"customBaseUrl",void 0);k([r.property()],g.prototype,"defaultBasemap",void 0);k([r.reader("defaultBasemap")],g.prototype,"readDefaultBasemap",null);k([r.property({type:v})],g.prototype,"defaultExtent",void 0);k([r.property()],
g.prototype,"defaultVectorBasemap",void 0);k([r.reader("defaultVectorBasemap")],g.prototype,"readDefaultVectorBasemap",null);k([r.property()],g.prototype,"description",void 0);k([r.property()],g.prototype,"eueiEnabled",void 0);k([r.property({dependsOn:["user","id","canSearchPublic"],readOnly:!0})],g.prototype,"extraQuery",null);k([r.property()],g.prototype,"featuredGroups",void 0);k([r.property()],g.prototype,"featuredItemsGroupQuery",void 0);k([r.property()],g.prototype,"galleryTemplatesGroupQuery",
void 0);k([r.property()],g.prototype,"livingAtlasGroupQuery",void 0);k([r.property()],g.prototype,"hasCategorySchema",void 0);k([r.property()],g.prototype,"helpBase",void 0);k([r.property()],g.prototype,"helperServices",void 0);k([r.property()],g.prototype,"helpMap",void 0);k([r.property()],g.prototype,"homePageFeaturedContent",void 0);k([r.property()],g.prototype,"homePageFeaturedContentCount",void 0);k([r.property()],g.prototype,"httpPort",void 0);k([r.property()],g.prototype,"httpsPort",void 0);
k([r.property()],g.prototype,"id",void 0);k([r.property()],g.prototype,"ipCntryCode",void 0);k([r.property({dependsOn:["access"],readOnly:!0})],g.prototype,"isOrganization",null);k([r.property()],g.prototype,"isPortal",void 0);k([r.property()],g.prototype,"layerTemplatesGroupQuery",void 0);k([r.property()],g.prototype,"maxTokenExpirationMinutes",void 0);k([r.property({type:Date})],g.prototype,"modified",void 0);k([r.property()],g.prototype,"name",void 0);k([r.property()],g.prototype,"portalHostname",
void 0);k([r.property()],g.prototype,"portalMode",void 0);k([r.property()],g.prototype,"portalProperties",void 0);k([r.property()],g.prototype,"region",void 0);k([r.property({dependsOn:["url"],readOnly:!0})],g.prototype,"restUrl",null);k([r.property()],g.prototype,"rotatorPanels",void 0);k([r.property()],g.prototype,"showHomePageDescription",void 0);k([r.property()],g.prototype,"staticImagesUrl",void 0);k([r.property()],g.prototype,"stylesGroupQuery",void 0);k([r.property()],g.prototype,"supportsHostedServices",
void 0);k([r.property()],g.prototype,"symbolSetsGroupQuery",void 0);k([r.property()],g.prototype,"templatesGroupQuery",void 0);k([r.property()],g.prototype,"thumbnail",void 0);k([r.property({dependsOn:["restUrl","thumbnail"],readOnly:!0})],g.prototype,"thumbnailUrl",null);k([r.property()],g.prototype,"units",void 0);k([r.property()],g.prototype,"url",void 0);k([r.property()],g.prototype,"urlKey",void 0);k([r.reader("urlKey")],g.prototype,"readUrlKey",null);k([r.property()],g.prototype,"user",void 0);
k([r.reader("user")],g.prototype,"readUser",null);k([r.property()],g.prototype,"useStandardizedQuery",void 0);k([r.property()],g.prototype,"useVectorBasemaps",void 0);k([r.property()],g.prototype,"vectorBasemapGalleryGroupQuery",void 0);k([l(1,r.cast(u))],g.prototype,"_queryPortal",null);return g=p=k([r.subclass("esri.portal.Portal")],g)}(r.declared(g,p))})},"esri/core/tsSupport/paramHelper":function(){define([],function(){return function(b,e){return function(m,d){e(m,d,b)}}})},"esri/portal/PortalQueryParams":function(){define("require exports ../core/tsSupport/assignHelper ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Accessor ../core/kebabDictionary ../core/lang ../core/accessorSupport/decorators ../geometry/Extent ../geometry/SpatialReference ../geometry/support/webMercatorUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g){var q=new h.default({avgRating:"avg-rating",numRatings:"num-ratings",numComments:"num-comments",numViews:"num-views"});return function(b){function e(a){a=b.call(this)||this;a.categories=null;a.disableExtraQuery=!1;a.extent=null;a.num=10;a.query=null;a.sortField=null;a.start=1;return a}d(e,b);h=e;Object.defineProperty(e.prototype,"sortOrder",{get:function(){return this._get("sortOrder")||"asc"},set:function(a){"asc"!==a&&"desc"!==a||this._set("sortOrder",a)},enumerable:!0,
configurable:!0});e.prototype.clone=function(){return new h({categories:this.categories?a.clone(this.categories):null,disableExtraQuery:this.disableExtraQuery,extent:this.extent?this.extent.clone():null,num:this.num,query:this.query,sortField:this.sortField,sortOrder:this.sortOrder,start:this.start})};e.prototype.toRequestOptions=function(a,c){var f;this.categories&&(f=this.categories.map(function(a){return Array.isArray(a)?JSON.stringify(a):a}));var d;if(this.extent){var b=g.project(this.extent,
n.WGS84);b&&(d=b.xmin+","+b.ymin+","+b.xmax+","+b.ymax)}b=this.query;!this.disableExtraQuery&&a.extraQuery&&(b="("+b+")"+a.extraQuery);a={categories:f,bbox:d,q:b,num:this.num,sortField:null,sortOrder:null,start:this.start};this.sortField&&(a.sortField=q.toJSON(this.sortField),a.sortOrder=this.sortOrder);return{query:m({},c,a)}};var h;k([c.property()],e.prototype,"categories",void 0);k([c.property()],e.prototype,"disableExtraQuery",void 0);k([c.property({type:f})],e.prototype,"extent",void 0);k([c.property()],
e.prototype,"num",void 0);k([c.property()],e.prototype,"query",void 0);k([c.property()],e.prototype,"sortField",void 0);k([c.property()],e.prototype,"sortOrder",null);k([c.property()],e.prototype,"start",void 0);return e=h=k([c.subclass("esri.portal.PortalQueryParams")],e)}(c.declared(l))})},"esri/portal/PortalQueryResult":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Accessor ../core/accessorSupport/decorators".split(" "),function(b,
e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.nextQueryParams=null;a.queryParams=null;a.results=null;a.total=null;return a}m(a,b);d([l.property()],a.prototype,"nextQueryParams",void 0);d([l.property()],a.prototype,"queryParams",void 0);d([l.property()],a.prototype,"results",void 0);d([l.property()],a.prototype,"total",void 0);return a=d([l.subclass("esri.portal.PortalQueryResult")],a)}(l.declared(k))})},"esri/portal/PortalUser":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Error ../core/JSONSupport ../core/promiseUtils ../core/accessorSupport/decorators ./PortalFolder ./PortalGroup".split(" "),
function(b,e,m,d,k,l,h,a,c,f){return function(e){function g(){var a=e.call(this)||this;a.access=null;a.created=null;a.culture=null;a.description=null;a.email=null;a.fullName=null;a.modified=null;a.orgId=null;a.portal=null;a.preferredView=null;a.privileges=null;a.region=null;a.role=null;a.roleId=null;a.units=null;a.username=null;a.userType=null;return a}m(g,e);Object.defineProperty(g.prototype,"thumbnailUrl",{get:function(){var a=this.url,c=this.thumbnail;return a&&c?this.portal._normalizeUrl(a+"/info/"+
c+"?f\x3djson"):null},enumerable:!0,configurable:!0});Object.defineProperty(g.prototype,"userContentUrl",{get:function(){var a=this.get("portal.restUrl");return a?a+"/content/users/"+this.username:null},enumerable:!0,configurable:!0});Object.defineProperty(g.prototype,"url",{get:function(){var a=this.get("portal.restUrl");return a?a+"/community/users/"+this.username:null},enumerable:!0,configurable:!0});g.prototype.addItem=function(a){var c=this,f=a&&a.item,d=a&&a.data;a=a&&a.folder;var b={method:"post"};
f&&(b.query=f._getPostQuery(),null!=d&&("string"===typeof d?b.query.text=d:"object"===typeof d&&(b.query.text=JSON.stringify(d))));d=this.userContentUrl;a&&(d+="/"+a.id);return this.portal._request(d+"/addItem",b).then(function(a){f.id=a.id;f.portal=c.portal;return f.loaded?f._reload():f.load()})};g.prototype.deleteItem=function(a){var c=this.userContentUrl;a.ownerFolder&&(c+="/"+a.ownerFolder);return this.portal._request(c+("/items/"+a.id+"/delete"),{method:"post"}).then(function(){a.id=null;a.portal=
null})};g.prototype.deleteItems=function(a){var c=this.userContentUrl+"/deleteItems",f=a.map(function(a){return a.id});return f.length?(f={method:"post",query:{items:f.join(",")}},this.portal._request(c,f).then(function(){a.forEach(function(a){a.id=null;a.portal=null})})):h.resolve(void 0)};g.prototype.fetchFolders=function(){var a=this;return this.portal._request(this.userContentUrl,{query:{num:1}}).then(function(f){return f&&f.folders?f.folders.map(function(f){f=c.fromJSON(f);f.portal=a.portal;
return f}):[]})};g.prototype.fetchGroups=function(){var a=this;return this.portal._request(this.url).then(function(c){return c&&c.groups?c.groups.map(function(c){c=f.fromJSON(c);c.portal=a.portal;return c}):[]})};g.prototype.fetchItems=function(a){var c=this;a||(a={});var f=this.userContentUrl;a.folder&&(f+="/"+a.folder.id);var d;return h.create(function(a){return b(["./PortalItem"],a)}).then(function(b){d=b;return c.portal._request(f,{query:{folders:!1,num:a.num||10,start:a.start||1}})}).then(function(a){var f;
return a&&a.items?(f=a.items.map(function(a){a=d.fromJSON(a);a.portal=c.portal;return a}),h.all(f.map(function(a){return a.load()})).catch(function(a){return a}).then(function(){return{items:f,nextStart:a.nextStart,total:a.total}})):{items:[],nextStart:-1,total:0}})};g.prototype.getThumbnailUrl=function(a){var c=this.thumbnailUrl;c&&a&&(c+="\x26w\x3d"+a);return c};g.prototype.queryFavorites=function(a){return this.favGroupId?(this._favGroup||(this._favGroup=new f({id:this.favGroupId,portal:this.portal})),
this._favGroup.queryItems(a)):h.reject(new k("internal:unknown","Unknown internal error",{internalError:"Unknown favGroupId"}))};g.prototype.toJSON=function(){throw new k("internal:not-yet-implemented","PortalGroup.toJSON is not yet implemented");};d([a.property()],g.prototype,"access",void 0);d([a.property({type:Date})],g.prototype,"created",void 0);d([a.property()],g.prototype,"culture",void 0);d([a.property()],g.prototype,"description",void 0);d([a.property()],g.prototype,"email",void 0);d([a.property()],
g.prototype,"favGroupId",void 0);d([a.property()],g.prototype,"fullName",void 0);d([a.property({type:Date})],g.prototype,"modified",void 0);d([a.property()],g.prototype,"orgId",void 0);d([a.property()],g.prototype,"portal",void 0);d([a.property()],g.prototype,"preferredView",void 0);d([a.property()],g.prototype,"privileges",void 0);d([a.property()],g.prototype,"region",void 0);d([a.property()],g.prototype,"role",void 0);d([a.property()],g.prototype,"roleId",void 0);d([a.property()],g.prototype,"thumbnail",
void 0);d([a.property({dependsOn:["url","thumbnail","portal.credential.token"],readOnly:!0})],g.prototype,"thumbnailUrl",null);d([a.property()],g.prototype,"units",void 0);d([a.property({dependsOn:["portal.restUrl"],readOnly:!0})],g.prototype,"userContentUrl",null);d([a.property({dependsOn:["portal.restUrl"],readOnly:!0})],g.prototype,"url",null);d([a.property()],g.prototype,"username",void 0);d([a.property()],g.prototype,"userType",void 0);return g=d([a.subclass("esri.portal.PortalUser")],g)}(a.declared(l))})},
"esri/portal/PortalFolder":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Error ../core/JSONSupport ../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.created=null;c.id=null;c.portal=null;c.title=null;c.username=null;return c}m(c,a);Object.defineProperty(c.prototype,"url",{get:function(){var a=this.get("portal.restUrl");return a?a+"/content/users/"+this.username+
"/"+this.id:null},enumerable:!0,configurable:!0});c.prototype.toJSON=function(){throw new k("internal:not-yet-implemented","PortalFolder.toJSON is not yet implemented");};d([h.property({type:Date})],c.prototype,"created",void 0);d([h.property()],c.prototype,"id",void 0);d([h.property()],c.prototype,"portal",void 0);d([h.property()],c.prototype,"title",void 0);d([h.property({dependsOn:["portal.restUrl"],readOnly:!0})],c.prototype,"url",null);d([h.property()],c.prototype,"username",void 0);return c=
d([h.subclass("esri.portal.PortalFolder")],c)}(h.declared(l))})},"esri/portal/PortalGroup":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/paramHelper ../core/Error ../core/JSONSupport ../core/accessorSupport/decorators ./PortalQueryParams".split(" "),function(b,e,m,d,k,l,h,a,c){return function(f){function b(a){a=f.call(this)||this;a.access=null;a.created=null;a.description=null;a.id=null;a.isInvitationOnly=!1;a.modified=
null;a.owner=null;a.portal=null;a.snippet=null;a.sortField=null;a.sortOrder=null;a.tags=null;a.title=null;return a}m(b,f);Object.defineProperty(b.prototype,"thumbnailUrl",{get:function(){var a=this.url,c=this.thumbnail;return a&&c?this.portal._normalizeUrl(a+"/info/"+c+"?f\x3djson"):null},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"url",{get:function(){var a=this.get("portal.restUrl");return a?a+"/community/groups/"+this.id:null},enumerable:!0,configurable:!0});b.prototype.fetchCategorySchema=
function(){var a=this;return this.portal._request(this.url+"/categorySchema").then(function(c){c=c.categorySchema||[];return c.some(function(a){return"contentCategorySetsGroupQuery.LivingAtlas"===a.source})?a._fetchCategorySchemaSet("LivingAtlas"):c})};b.prototype.fetchMembers=function(){return this.portal._request(this.url+"/users")};b.prototype.getThumbnailUrl=function(a){var c=this.thumbnailUrl;c&&a&&(c+="\x26w\x3d"+a);return c};b.prototype.toJSON=function(){throw new l("internal:not-yet-implemented",
"PortalGroup.toJSON is not yet implemented");};b.prototype.queryItems=function(a){if(5<parseFloat(this.portal.currentVersion))return a=a||new c,this.portal._queryPortal("/content/groups/"+this.id+"/search",a,"PortalItem");a=a?a.clone():new c;a.query="group:"+this.id+(a.query?" "+a.query:"");return this.portal.queryItems(a)};b.prototype._fetchCategorySchemaSet=function(a){var f=this;return this.portal._fetchSelf(this.portal.authMode,!0).then(function(a){if(a=a.contentCategorySetsGroupQuery){var b=
new c;b.disableExtraQuery=!0;b.num=1;b.query=a;return f.portal.queryGroups(b)}throw new l("portal-group:fetchCategorySchema","contentCategorySetsGroupQuery value not found");}).then(function(f){if(f.total){f=f.results[0];var b=new c;b.num=1;b.query='typekeywords:"'+a+'"';return f.queryItems(b)}throw new l("portal-group:fetchCategorySchema","contentCategorySetsGroupQuery group not found");}).then(function(a){return a.total?a.results[0].fetchData().then(function(a){return(a=a&&a.categorySchema)&&a.length?
a:[]}):[]})};d([a.property()],b.prototype,"access",void 0);d([a.property({type:Date})],b.prototype,"created",void 0);d([a.property()],b.prototype,"description",void 0);d([a.property()],b.prototype,"id",void 0);d([a.property()],b.prototype,"isInvitationOnly",void 0);d([a.property({type:Date})],b.prototype,"modified",void 0);d([a.property()],b.prototype,"owner",void 0);d([a.property()],b.prototype,"portal",void 0);d([a.property()],b.prototype,"snippet",void 0);d([a.property()],b.prototype,"sortField",
void 0);d([a.property()],b.prototype,"sortOrder",void 0);d([a.property()],b.prototype,"tags",void 0);d([a.property()],b.prototype,"thumbnail",void 0);d([a.property({dependsOn:["url","thumbnail","portal.credential.token"],readOnly:!0})],b.prototype,"thumbnailUrl",null);d([a.property()],b.prototype,"title",void 0);d([a.property({dependsOn:["portal.restUrl"],readOnly:!0})],b.prototype,"url",null);d([k(0,a.cast(c))],b.prototype,"queryItems",null);return b=d([a.subclass("esri.portal.PortalGroup")],b)}(a.declared(h))})},
"esri/portal/PortalItem":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Error ../core/JSONSupport ../core/lang ../core/Loadable ../core/promiseUtils ../core/urlUtils ../core/accessorSupport/decorators ../geometry/Extent ./Portal ./PortalRating".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g,q,p){return function(a){function e(c){c=a.call(this)||this;c.access=null;c.accessInformation=null;c.applicationProxies=null;c.avgRating=null;c.categories=
null;c.created=null;c.culture=null;c.description=null;c.extent=null;c.groupCategories=null;c.id=null;c.itemControl=null;c.licenseInfo=null;c.modified=null;c.name=null;c.numComments=null;c.numRatings=null;c.numViews=null;c.owner=null;c.portal=null;c.screenshots=null;c.size=null;c.snippet=null;c.tags=null;c.title=null;c.type=null;c.typeKeywords=null;c.url=null;return c}m(e,a);t=e;Object.defineProperty(e.prototype,"displayName",{get:function(){var a=this.type,c=this.typeKeywords||[],f=a;"Feature Service"===
a||"Feature Collection"===a?f=-1<c.indexOf("Table")?"Table":-1<c.indexOf("Route Layer")?"Route Layer":-1<c.indexOf("Markup")?"Markup":"Feature Layer":"Image Service"===a?f=-1<c.indexOf("Elevation 3D Layer")?"Elevation Layer":"Imagery Layer":"Scene Service"===a?f="Scene Layer":"Scene Package"===a?f="Scene Layer Package":"Stream Service"===a?f="Feature Layer":"Geoprocessing Service"===a&&this.portal&&this.portal.isPortal?f=-1<c.indexOf("Web Tool")?"Tool":"Geoprocessing Service":"Geocoding Service"===
a?f="Locator":"Microsoft Powerpoint"===a?f="Microsoft PowerPoint":"GeoJson"===a?f="GeoJSON":"Globe Service"===a?f="Globe Layer":"Vector Tile Service"===a?f="Tile Layer":"netCDF"===a?f="NetCDF":"Map Service"===a?f=-1===c.indexOf("Spatiotemporal")&&(-1<c.indexOf("Hosted Service")||-1<c.indexOf("Tiled"))&&-1===c.indexOf("Relational")?"Tile Layer":"Map Image Layer":a&&-1<a.toLowerCase().indexOf("add in")?f=a.replace(/(add in)/gi,"Add-In"):"datastore catalog service"===a?f="Big Data File Share":"Compact Tile Package"===
a&&(f="Tile Package (tpkx)");return f},enumerable:!0,configurable:!0});e.prototype.readExtent=function(a){return a&&a.length?new g(a[0][0],a[0][1],a[1][0],a[1][1]):null};Object.defineProperty(e.prototype,"iconUrl",{get:function(){var a=this.type&&this.type.toLowerCase()||"",c=this.typeKeywords||[],f=!1,d=!1,e=!1,g=!1,h=!1;0<a.indexOf("service")||"feature collection"===a||"kml"===a||"wms"===a||"wmts"===a||"wfs"===a?(f=-1<c.indexOf("Hosted Service"),"feature service"===a||"feature collection"===a||
"kml"===a||"wfs"===a?(d=-1<c.indexOf("Table"),e=-1<c.indexOf("Route Layer"),g=-1<c.indexOf("Markup"),a=(h=-1!==c.indexOf("Spatiotemporal"))&&d?"spatiotemporaltable":d?"table":e?"routelayer":g?"markup":h?"spatiotemporal":f?"featureshosted":"features"):"map service"===a||"wms"===a||"wmts"===a?(h=-1!==c.indexOf("Spatiotemporal"),a=f||-1<c.indexOf("Tiled")||"wmts"===a?"maptiles":h?"spatiotemporal":"mapimages"):a="scene service"===a?-1<c.indexOf("Line")?"sceneweblayerline":-1<c.indexOf("3DObject")?"sceneweblayermultipatch":
-1<c.indexOf("Point")?"sceneweblayerpoint":-1<c.indexOf("IntegratedMesh")?"sceneweblayermesh":-1<c.indexOf("PointCloud")?"sceneweblayerpointcloud":-1<c.indexOf("Polygon")?"sceneweblayerpolygon":-1<c.indexOf("Building")?"sceneweblayerbuilding":"sceneweblayer":"image service"===a?-1<c.indexOf("Elevation 3D Layer")?"elevationlayer":"imagery":"stream service"===a?"streamlayer":"vector tile service"===a?"vectortile":"datastore catalog service"===a?"datastorecollection":"geocoding service"===a?"geocodeservice":
"geoprocessing service"===a?-1<c.indexOf("Web Tool")&&this.portal&&this.portal.isPortal?"tool":"layers":"layers"):a="web map"===a||"cityengine web scene"===a?"maps":"web scene"===a?-1<c.indexOf("ViewingMode-Local")?"webscenelocal":"websceneglobal":"web mapping application"===a||"mobile application"===a||"application"===a||"operation view"===a||"desktop application"===a?"apps":"map document"===a||"map package"===a||"published map"===a||"scene document"===a||"globe document"===a||"basemap package"===
a||"mobile basemap package"===a||"mobile map package"===a||"project package"===a||"project template"===a||"pro map"===a||"layout"===a||"layer"===a&&-1<c.indexOf("ArcGIS Pro")||"explorer map"===a&&c.indexOf("Explorer Document")?"mapsgray":"service definition"===a||"csv"===a||"shapefile"===a||"cad drawing"===a||"geojson"===a||"360 vr experience"===a||"netcdf"===a?"datafiles":"explorer add in"===a||"desktop add in"===a||"windows viewer add in"===a||"windows viewer configuration"===a?"appsgray":"arcgis pro add in"===
a||"arcgis pro configuration"===a?"addindesktop":"rule package"===a||"file geodatabase"===a||"sqlite geodatabase"===a||"csv collection"===a||"kml collection"===a||"windows mobile package"===a||"map template"===a||"desktop application template"===a||"arcpad package"===a||"code sample"===a||"form"===a||"document link"===a||"operations dashboard add in"===a||"rules package"===a||"image"===a||"workflow manager package"===a||"explorer map"===a&&-1<c.indexOf("Explorer Mapping Application")||-1<c.indexOf("Document")?
"datafilesgray":"network analysis service"===a||"geoprocessing service"===a||"geodata service"===a||"geometry service"===a||"geoprocessing package"===a||"locator package"===a||"geoprocessing sample"===a||"workflow manager service"===a?"toolsgray":"layer"===a||"layer package"===a||"explorer layer"===a?"layersgray":"scene package"===a?"scenepackage":"mobile scene package"===a?"mobilescenepackage":"tile package"===a||"compact tile package"===a?"tilepackage":"task file"===a?"taskfile":"report template"===
a?"report-template":"statistical data collection"===a?"statisticaldatacollection":"insights workbook"===a?"workbook":"insights model"===a?"insightsmodel":"insights page"===a?"insightspage":"insights theme"===a?"insightstheme":"hub initiative"===a?"hubinitiative":"hubpage"===a?"hubpage":"hub site application"===a?"hubsite":"relational database connection"===a?"relationaldatabaseconnection":"big data file share"===a?"datastorecollection":"image collection"===a?"imagecollection":"style"===a?"style":
"desktop style"===a?"desktopstyle":"dashboard"===a?"dashboard":"raster function template"===a?"rasterprocessingtemplate":"vector tile package"===a?"vectortilepackage":"ortho mapping project"===a?"orthomappingproject":"ortho mapping template"===a?"orthomappingtemplate":"solution"===a?"solutions":"geopackage"===a?"geopackage":"deep learning package"===a?"deeplearningpackage":"real time analytic"===a?"realtimeanalytics":"big data analytic"===a?"bigdataanalytics":"feed"===a?"feed":"excalibur imagery project"===
a?"excaliburimageryproject":"notebook"===a?"notebook":"storymap"===a?"storymap":"survey123 add in"===a?"survey123addin":"maps";return a?b.toUrl("../images/portal/"+a+"16.png"):null},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"isLayer",{get:function(){return-1<"Map Service;Feature Service;Feature Collection;Scene Service;Image Service;Stream Service;Vector Tile Service;WMTS;WMS".split(";").indexOf(this.type)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,
"itemUrl",{get:function(){var a=this.get("portal.restUrl");return a?a+"/content/items/"+this.id:null},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"thumbnailUrl",{get:function(){var a=this.itemUrl,c=this.thumbnail;return a&&c?this.portal._normalizeUrl(a+"/info/"+c+"?f\x3djson"):null},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"userItemUrl",{get:function(){var a=this.get("portal.restUrl");if(!a)return null;var c=this.owner||this.get("portal.user.username");
return c?a+"/content/users/"+(this.ownerFolder?c+"/"+this.ownerFolder:c)+"/items/"+this.id:null},enumerable:!0,configurable:!0});e.prototype.load=function(){var a=this;this.portal||(this.portal=q.getDefault());var c=this.portal.load().then(function(){return a.resourceInfo?a.resourceInfo:a.id&&a.itemUrl?a.portal._request(a.itemUrl):{}}).then(function(c){a.resourceInfo=c;a.read(c)});this.addResolvingPromise(c);return this.when()};e.prototype.addRating=function(a){var c={method:"post",query:{}};a instanceof
p&&(a=a.rating);isNaN(a)||"number"!==typeof a||(c.query.rating=a);return this.portal._request(this.itemUrl+"/addRating",c).then(function(){return new p({rating:a,created:new Date})})};e.prototype.deleteRating=function(){return this.portal._request(this.itemUrl+"/deleteRating",{method:"post"}).then(function(){})};e.prototype.fetchData=function(a){void 0===a&&(a="json");return this.portal._request(this.itemUrl+"/data",{responseType:a})};e.prototype.fetchRating=function(){return this.portal._request(this.itemUrl+
"/rating").then(function(a){return null!=a.rating?(a.created=new Date(a.created),new p(a)):null})};e.prototype.fetchRelatedItems=function(a){return this.portal._requestToTypedArray(this.itemUrl+"/relatedItems",{query:a},"PortalItem")};e.prototype.getThumbnailUrl=function(a){var c=this.thumbnailUrl;c&&a&&(c+="\x26w\x3d"+a);return c};e.prototype.update=function(a){var f=this;return this.id?this.load().then(function(){return f.portal._signIn()}).then(function(){var c=a&&a.data,b={method:"post"};b.query=
f._getPostQuery();for(var d in b.query)null===b.query[d]&&(b.query[d]="");b.query.clearEmptyFields=!0;null!=c&&("string"===typeof c?b.query.text=c:"object"===typeof c&&(b.query.text=JSON.stringify(c)));return f.portal._request(f.userItemUrl+"/update",b).then(function(){return f._reload()})}):c.reject(new k("portal:item-does-not-exist","The item does not exist yet and cannot be updated"))};e.prototype.updateThumbnail=function(a){var b=this;return this.id?this.load().then(function(){return b.portal._signIn()}).then(function(){var c=
a.thumbnail,d={method:"post"};if("string"===typeof c)f.isDataProtocol(c)?d.query={data:c}:d.query={url:f.makeAbsolute(c)};else{var e=new FormData;e.append("file",c);d.body=e}return b.portal._request(b.userItemUrl+"/updateThumbnail",d).then(function(){return b._reload()})}):c.reject(new k("portal:item-does-not-exist","The item does not exist yet and cannot be updated"))};e.prototype.toJSON=function(){var a=this.extent,a={created:this.created&&this.created.getTime(),description:this.description,extent:a&&
[[a.xmin,a.ymin],[a.xmax,a.ymax]],id:this.id,modified:this.modified&&this.modified.getTime(),name:this.name,owner:this.owner,ownerFolder:this.ownerFolder,snippet:this.snippet,tags:this.tags,thumbnail:this.thumbnail,title:this.title,type:this.type,typeKeywords:this.typeKeywords,url:this.url};return h.fixJson(a)};e.fromJSON=function(a){if(!a)return null;if(a.declaredClass)throw Error("JSON object is already hydrated");return new t({resourceInfo:a})};e.prototype._reload=function(){var a=this;return this.portal._request(this.itemUrl,
{query:{_ts:Date.now()}}).then(function(c){a.resourceInfo=c;a.read(c);return a})};e.prototype._getPostQuery=function(){var a=this.toJSON(),c;for(c in a)"tags"===c&&null!==a[c]&&(a[c]=a[c].join(", ")),"typeKeywords"===c&&null!==a[c]&&(a[c]=a[c].join(", "));return a};var t;d([n.property()],e.prototype,"access",void 0);d([n.property()],e.prototype,"accessInformation",void 0);d([n.property({json:{read:{source:"appProxies"}}})],e.prototype,"applicationProxies",void 0);d([n.property()],e.prototype,"avgRating",
void 0);d([n.property()],e.prototype,"categories",void 0);d([n.property({type:Date})],e.prototype,"created",void 0);d([n.property()],e.prototype,"culture",void 0);d([n.property()],e.prototype,"description",void 0);d([n.property({dependsOn:["type","typeKeywords"],readOnly:!0})],e.prototype,"displayName",null);d([n.property({type:g})],e.prototype,"extent",void 0);d([n.reader("extent")],e.prototype,"readExtent",null);d([n.property()],e.prototype,"groupCategories",void 0);d([n.property({dependsOn:["type",
"typeKeywords"],readOnly:!0})],e.prototype,"iconUrl",null);d([n.property()],e.prototype,"id",void 0);d([n.property({dependsOn:["type"],readOnly:!0})],e.prototype,"isLayer",null);d([n.property()],e.prototype,"itemControl",void 0);d([n.property({dependsOn:["portal.restUrl","id"],readOnly:!0})],e.prototype,"itemUrl",null);d([n.property()],e.prototype,"licenseInfo",void 0);d([n.property({type:Date})],e.prototype,"modified",void 0);d([n.property()],e.prototype,"name",void 0);d([n.property()],e.prototype,
"numComments",void 0);d([n.property()],e.prototype,"numRatings",void 0);d([n.property()],e.prototype,"numViews",void 0);d([n.property()],e.prototype,"owner",void 0);d([n.property()],e.prototype,"ownerFolder",void 0);d([n.property({type:q})],e.prototype,"portal",void 0);d([n.property()],e.prototype,"resourceInfo",void 0);d([n.property()],e.prototype,"screenshots",void 0);d([n.property()],e.prototype,"size",void 0);d([n.property()],e.prototype,"snippet",void 0);d([n.property()],e.prototype,"tags",void 0);
d([n.property()],e.prototype,"thumbnail",void 0);d([n.property({dependsOn:["itemUrl","thumbnail","portal.credential.token"],readOnly:!0})],e.prototype,"thumbnailUrl",null);d([n.property()],e.prototype,"title",void 0);d([n.property()],e.prototype,"type",void 0);d([n.property()],e.prototype,"typeKeywords",void 0);d([n.property()],e.prototype,"url",void 0);d([n.property({dependsOn:["portal.restUrl","portal.user.username","owner","ownerFolder","id"],readOnly:!0})],e.prototype,"userItemUrl",null);return e=
t=d([n.subclass("esri.portal.PortalItem")],e)}(n.declared(l,a))})},"esri/portal/PortalRating":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Accessor ../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.created=null;a.rating=null;return a}m(a,b);d([l.property()],a.prototype,"created",void 0);d([l.property()],a.prototype,"rating",void 0);return a=d([l.subclass("esri.portal.PortalRating")],
a)}(l.declared(k))})},"esri/support/basemapDefinitions":function(){define(["require","exports","dojo/i18n!../nls/basemaps"],function(b,e,m){return{streets:{id:"streets",title:m.streets,thumbnailUrl:b.toUrl("../images/basemap/streets.jpg"),baseMapLayers:[{id:"streets-base-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Street Map",showLegend:!1,visibility:!0,opacity:1}]},satellite:{id:"satellite",title:m.satellite,
thumbnailUrl:b.toUrl("../images/basemap/satellite.jpg"),baseMapLayers:[{id:"satellite-base-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Imagery",showLegend:!1,visibility:!0,opacity:1}]},hybrid:{id:"hybrid",title:m.hybrid,thumbnailUrl:b.toUrl("../images/basemap/hybrid.jpg"),baseMapLayers:[{id:"hybrid-base-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer",layerType:"ArcGISTiledMapServiceLayer",
title:"World Imagery",showLegend:!1,visibility:!0,opacity:1},{id:"hybrid-reference-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/Reference/World_Boundaries_and_Places/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Boundaries and Places",isReference:!0,showLegend:!1,visibility:!0,opacity:1}]},terrain:{id:"terrain",title:m.terrain,thumbnailUrl:b.toUrl("../images/basemap/terrain.jpg"),baseMapLayers:[{id:"terrain-base-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/World_Terrain_Base/MapServer",
layerType:"ArcGISTiledMapServiceLayer",title:"World Terrain Base",showLegend:!1,visibility:!0,opacity:1},{id:"terrain-reference-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/Reference/World_Reference_Overlay/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Reference Overlay",isReference:!0,showLegend:!1,visibility:!0,opacity:1}]},topo:{id:"topo",title:m.topo,thumbnailUrl:b.toUrl("../images/basemap/topo.jpg"),baseMapLayers:[{id:"topo-base-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer",
layerType:"ArcGISTiledMapServiceLayer",title:"World Topo Map",showLegend:!1,visibility:!0,opacity:1}]},gray:{id:"gray",title:m.gray,thumbnailUrl:b.toUrl("../images/basemap/gray.jpg"),baseMapLayers:[{id:"gray-base-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/Canvas/World_Light_Gray_Base/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Light Gray Base",showLegend:!1,visibility:!0,opacity:1},{id:"gray-reference-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/Canvas/World_Light_Gray_Reference/MapServer",
layerType:"ArcGISTiledMapServiceLayer",title:"World Light Gray Reference",isReference:!0,showLegend:!1,visibility:!0,opacity:1}]},"dark-gray":{id:"dark-gray",title:m["dark-gray"],thumbnailUrl:b.toUrl("../images/basemap/dark-gray.jpg"),baseMapLayers:[{id:"dark-gray-base-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/Canvas/World_Dark_Gray_Base/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Dark Gray Base",showLegend:!1,visibility:!0,opacity:1},{id:"dark-gray-reference-layer",
url:"//services.arcgisonline.com/ArcGIS/rest/services/Canvas/World_Dark_Gray_Reference/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Dark Gray Reference",isReference:!0,showLegend:!1,visibility:!0,opacity:1}]},oceans:{id:"oceans",title:m.oceans,thumbnailUrl:b.toUrl("../images/basemap/oceans.jpg"),baseMapLayers:[{id:"oceans-base-layer",url:"//services.arcgisonline.com/arcgis/rest/services/Ocean/World_Ocean_Base/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Ocean Base",
showLegend:!1,visibility:!0,opacity:1},{id:"oceans-reference-layer",url:"//services.arcgisonline.com/arcgis/rest/services/Ocean/World_Ocean_Reference/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Ocean Reference",isReference:!0,showLegend:!1,visibility:!0,opacity:1}]},"national-geographic":{id:"national-geographic",title:m["national-geographic"],thumbnailUrl:b.toUrl("../images/basemap/national-geographic.jpg"),baseMapLayers:[{id:"national-geographic-base-layer",url:"//services.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer",
title:"NatGeo World Map",showLegend:!1,layerType:"ArcGISTiledMapServiceLayer",visibility:!0,opacity:1}]},osm:{id:"osm",title:m.osm,thumbnailUrl:b.toUrl("../images/basemap/osm.jpg"),baseMapLayers:[{id:"osm-base-layer",layerType:"OpenStreetMap",title:"Open Street Map",showLegend:!1,visibility:!0,opacity:1}]},"dark-gray-vector":{id:"dark-gray-vector",title:m["dark-gray"],thumbnailUrl:b.toUrl("../images/basemap/dark-gray.jpg"),baseMapLayers:[{id:"dark-gray-base-layer",styleUrl:"//www.arcgis.com/sharing/rest/content/items/c11ce4f7801740b2905eb03ddc963ac8/resources/styles/root.json",
layerType:"VectorTileLayer",title:"World Dark Gray",visibility:!0,opacity:1}]},"gray-vector":{id:"gray-vector",title:m.gray,thumbnailUrl:b.toUrl("../images/basemap/gray.jpg"),baseMapLayers:[{id:"gray-base-layer",styleUrl:"//www.arcgis.com/sharing/rest/content/items/8a2cba3b0ebf4140b7c0dc5ee149549a/resources/styles/root.json",layerType:"VectorTileLayer",title:"World Light Gray",visibility:!0,opacity:1}]},"streets-vector":{id:"streets-vector",title:m.streets,thumbnailUrl:b.toUrl("../images/basemap/streets.jpg"),
baseMapLayers:[{id:"streets-vector-base-layer",styleUrl:"//www.arcgis.com/sharing/rest/content/items/de26a3cf4cc9451298ea173c4b324736/resources/styles/root.json",layerType:"VectorTileLayer",title:"World Streets",visibility:!0,opacity:1}]},"topo-vector":{id:"topo-vector",title:m.topo,thumbnailUrl:b.toUrl("../images/basemap/topo.jpg"),baseMapLayers:[{id:"world-hillshade-layer",url:"//services.arcgisonline.com/arcgis/rest/services/Elevation/World_Hillshade/MapServer",layerType:"ArcGISTiledMapServiceLayer",
title:"World Hillshade",showLegend:!1,visibility:!0,opacity:1},{id:"topo-vector-base-layer",styleUrl:"//www.arcgis.com/sharing/rest/content/items/7dc6cea0b1764a1f9af2e679f642f0f5/resources/styles/root.json",layerType:"VectorTileLayer",title:"World Topo",visibility:!0,opacity:1}]},"streets-night-vector":{id:"streets-night-vector",title:m["streets-night-vector"],thumbnailUrl:b.toUrl("../images/basemap/streets-night.jpg"),baseMapLayers:[{id:"streets-night-vector-base-layer",styleUrl:"//www.arcgis.com/sharing/rest/content/items/86f556a2d1fd468181855a35e344567f/resources/styles/root.json",
layerType:"VectorTileLayer",title:"World Streets Night",visibility:!0,opacity:1}]},"streets-relief-vector":{id:"streets-relief-vector",title:m["streets-relief-vector"],thumbnailUrl:b.toUrl("../images/basemap/streets-relief.jpg"),baseMapLayers:[{id:"world-hillshade-layer",url:"//services.arcgisonline.com/arcgis/rest/services/Elevation/World_Hillshade/MapServer",layerType:"ArcGISTiledMapServiceLayer",title:"World Hillshade",showLegend:!1,visibility:!0,opacity:1},{id:"streets-relief-vector-base-layer",
styleUrl:"//www.arcgis.com/sharing/rest/content/items/b266e6d17fc345b498345613930fbd76/resources/styles/root.json",title:"World Streets Relief",layerType:"VectorTileLayer",showLegend:!1,visibility:!0,opacity:1}]},"streets-navigation-vector":{id:"streets-navigation-vector",title:m["streets-navigation-vector"],thumbnailUrl:b.toUrl("../images/basemap/streets-navigation.jpg"),baseMapLayers:[{id:"streets-navigation-vector-base-layer",styleUrl:"//www.arcgis.com/sharing/rest/content/items/63c47b7177f946b49902c24129b87252/resources/styles/root.json",
layerType:"VectorTileLayer",title:"World Streets Navigation",visibility:!0,opacity:1}]}}})},"esri/Ground":function(){define("require exports ./core/tsSupport/assignHelper ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./Color ./core/asyncUtils ./core/collectionUtils ./core/compilerUtils ./core/Error ./core/JSONSupport ./core/lang ./core/Loadable ./core/loadAll ./core/Logger ./core/promiseUtils ./core/accessorSupport/decorators ./core/accessorSupport/ensureType ./ground/navigationConstraints ./layers/support/LayerCollection ./layers/support/types ./webdoc/support/opacityUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x,w){var A=t.getLogger("esri.Ground");return function(e){function n(a){var c=e.call(this)||this;c.opacity=1;c.surfaceColor=null;c.navigationConstraint=null;c.layers=new y.default;c.layers.on("after-add",function(a){a=a.item;a.parent&&a.parent!==c&&"remove"in a.parent&&a.parent.remove(a);a.parent=c;x.isOfType(a,["elevation","base-elevation"])||A.error("Layer '"+a.title+", id:"+a.id+"' of type '"+a.type+"' is not supported as a ground layer and will therefore be ignored. Only layers of type 'elevation' are supported.")});
c.layers.on("after-remove",function(a){a.item.parent=null});return c}d(n,e);t=n;n.prototype.initialize=function(){this.when().catch(function(a){A.error("#load()","Failed to load ground",a)});this.resourceInfo&&this.read(this.resourceInfo.data,this.resourceInfo.context)};n.prototype.normalizeCtorArgs=function(a){a&&"resourceInfo"in a&&(this._set("resourceInfo",a.resourceInfo),a=m({},a),delete a.resourceInfo);return a};Object.defineProperty(n.prototype,"layers",{set:function(c){this._set("layers",a.referenceSetter(c,
this._get("layers"),y.default))},enumerable:!0,configurable:!0});n.prototype.writeLayers=function(a,b,d,e){var g=[];a&&(e=m({},e,{layerContainerType:"ground"}),a.forEach(function(a){if("write"in a){var b={};c.typeCast(a)().write(b,e)&&g.push(b)}else e&&e.messages&&e.messages.push(new f("layer:unsupported","Layers ("+a.title+", "+a.id+") of type '"+a.declaredClass+"' cannot be persisted in the ground",{layer:a}))}));b.layers=g};n.prototype.load=function(){this.addResolvingPromise(this._loadFromSource());
return this.when()};n.prototype.loadAll=function(){var a=this;return h.safeCast(p.loadAll(this,function(c){c(a.layers)}))};n.prototype.queryElevation=function(a,c){var f=this;return this._importElevationQuery().then(function(b){b=new b.ElevationQuery;var d=f.layers.filter(function(a){return"elevation"===a.type}).toArray();return b.queryAll(d,a,c)})};n.prototype.createElevationSampler=function(a,c){var f=this;return this._importElevationQuery().then(function(b){b=new b.ElevationQuery;var d=f.layers.filter(function(a){return"elevation"===
a.type}).toArray();return b.createSamplerAll(d,a,c)})};n.prototype.clone=function(){var a={opacity:this.opacity,surfaceColor:g.clone(this.surfaceColor),navigationConstraint:g.clone(this.navigationConstraint),layers:this.layers.slice()};this.loaded&&(a.loadStatus="loaded");return(new t({resourceInfo:this.resourceInfo})).set(a)};n.prototype.read=function(a,c){this.resourceInfo||this._set("resourceInfo",{data:a,context:c});this.inherited(arguments)};n.prototype._loadFromSource=function(){var a=this.resourceInfo;
return a?this._loadLayersFromJSON(a.data,a.context):r.resolve(null)};n.prototype._loadLayersFromJSON=function(a,c){var f=this,d=c&&c.origin||"web-scene",e=c&&c.portal||null,g=c&&c.url||null;return r.create(function(a){return b(["./portal/support/layersCreator"],a)}).then(function(c){var b=[];a.layers&&Array.isArray(a.layers)&&b.push(h.safeCast(c.populateOperationalLayers(f.layers,a.layers,{context:{origin:d,url:g,portal:e,layerContainerType:"ground"},defaultLayerType:"ArcGISTiledElevationServiceLayer"})));
return r.eachAlways(b)}).then(function(){})};n.prototype._importElevationQuery=function(){return r.create(function(a){b(["./layers/support/ElevationQuery"],a)})};var t;k([v.property({type:y.default,json:{read:!1}}),v.cast(a.castForReferenceSetter)],n.prototype,"layers",null);k([v.writer("layers")],n.prototype,"writeLayers",null);k([v.property({readOnly:!0})],n.prototype,"resourceInfo",void 0);k([v.property({type:Number,nonNullable:!0,range:{min:0,max:1},json:{type:u.Integer,read:{reader:w.transparencyToOpacity,
source:"transparency"},write:{writer:function(a,c){c.transparency=w.opacityToTransparency(a)},target:"transparency"}}})],n.prototype,"opacity",void 0);k([v.property({type:l,json:{type:[u.Integer],write:function(a,c){c.surfaceColor=a.toJSON().slice(0,3)}}})],n.prototype,"surfaceColor",void 0);k([v.property({types:z.navigationConstraintTypes,json:{read:z.readNavigationConstraint,write:!0}})],n.prototype,"navigationConstraint",void 0);return n=t=k([v.subclass("esri.Ground")],n)}(v.declared(n,q))})},
"esri/Color":function(){define(["require","exports","./core/accessorSupport/ensureType"],function(b,e,m){function d(b){return Math.max(0,Math.min(m.ensureInteger(b),255))}function k(b,a,c){b=Number(b);return isNaN(b)?c:b<a?a:b>c?c:b}function l(b,a,c){0>c&&++c;1<c&&--c;var f=6*c;return 1>f?b+(a-b)*f:1>2*c?a:2>3*c?b+(a-b)*(2/3-c)*6:b}b=function(){function b(a){this.b=this.g=this.r=255;this.a=1;a&&this.setColor(a)}b.blendColors=function(a,c,f,d){void 0===d&&(d=new b);d.r=Math.round(a.r+(c.r-a.r)*f);
d.g=Math.round(a.g+(c.g-a.g)*f);d.b=Math.round(a.b+(c.b-a.b)*f);d.a=a.a+(c.a-a.a)*f;return d._sanitize()};b.fromRgb=function(a,c){var f=a.toLowerCase().match(/^(rgba?|hsla?)\(([\s\.\-,%0-9]+)\)/);if(f){a=f[2].split(/\s*,\s*/);f=f[1];if("rgb"===f&&3===a.length||"rgba"===f&&4===a.length)return f=a[0],"%"===f.charAt(f.length-1)?(f=a.map(function(a){return 2.56*parseFloat(a)}),4===a.length&&(f[3]=parseFloat(a[3])),b.fromArray(f,c)):b.fromArray(a.map(function(a){return parseFloat(a)}),c);if("hsl"===f&&
3===a.length||"hsla"===f&&4===a.length){var f=(parseFloat(a[0])%360+360)%360/360,d=parseFloat(a[1])/100,e=parseFloat(a[2])/100,d=.5>=e?e*(d+1):e+d-e*d,e=2*e-d,f=[256*l(e,d,f+1/3),256*l(e,d,f),256*l(e,d,f-1/3),1];4===a.length&&(f[3]=parseFloat(a[3]));return b.fromArray(f,c)}}return null};b.fromHex=function(a,c){void 0===c&&(c=new b);var f=4===a.length?4:8,d=(1<<f)-1,e=Number("0x"+a.substr(1));if(isNaN(e))return null;["b","g","r"].forEach(function(a){var b=e&d;e>>=f;c[a]=4===f?17*b:b});c.a=1;return c};
b.fromArray=function(a,c){void 0===c&&(c=new b);c._set(Number(a[0]),Number(a[1]),Number(a[2]),Number(a[3]));isNaN(c.a)&&(c.a=1);return c._sanitize()};b.fromString=function(a,c){var f=b.named[a];return f&&b.fromArray(f,c)||b.fromRgb(a,c)||b.fromHex(a,c)};b.toJSON=function(a){return a&&[d(a.r),d(a.g),d(a.b),1<a.a?a.a:d(255*a.a)]};b.fromJSON=function(a){return a&&new b([a[0],a[1],a[2],a[3]/255])};b.toUnitRGB=function(a){return[a.r/255,a.g/255,a.b/255]};b.toUnitRGBA=function(a){return[a.r/255,a.g/255,
a.b/255,null!=a.a?a.a:1]};b.prototype.setColor=function(a){"string"===typeof a?b.fromString(a,this):Array.isArray(a)?b.fromArray(a,this):(this._set(a.r,a.g,a.b,a.a),a instanceof b||this._sanitize());return this};b.prototype.toRgb=function(){return[this.r,this.g,this.b]};b.prototype.toRgba=function(){return[this.r,this.g,this.b,this.a]};b.prototype.toHex=function(){var a=this.r.toString(16),c=this.g.toString(16),f=this.b.toString(16);return"#"+(2>a.length?"0"+a:a)+(2>c.length?"0"+c:c)+(2>f.length?
"0"+f:f)};b.prototype.toCss=function(a){void 0===a&&(a=!1);var c=this.r+", "+this.g+", "+this.b;return a?"rgba("+c+", "+this.a+")":"rgb("+c+")"};b.prototype.toString=function(){return this.toCss(!0)};b.prototype.toJSON=function(){return[d(this.r),d(this.g),d(this.b),1<this.a?this.a:d(255*this.a)]};b.prototype.clone=function(){return new b(this.toRgba())};b.prototype._sanitize=function(){this.r=Math.round(k(this.r,0,255));this.g=Math.round(k(this.g,0,255));this.b=Math.round(k(this.b,0,255));this.a=
k(this.a,0,1);return this};b.prototype._set=function(a,c,f,b){this.r=a;this.g=c;this.b=f;this.a=b};b.named={transparent:[0,0,0,0],black:[0,0,0],silver:[192,192,192],gray:[128,128,128],white:[255,255,255],maroon:[128,0,0],red:[255,0,0],purple:[128,0,128],fuchsia:[255,0,255],green:[0,128,0],lime:[0,255,0],olive:[128,128,0],yellow:[255,255,0],navy:[0,0,128],blue:[0,0,255],teal:[0,128,128],aqua:[0,255,255],aliceblue:[240,248,255],antiquewhite:[250,235,215],aquamarine:[127,255,212],azure:[240,255,255],
beige:[245,245,220],bisque:[255,228,196],blanchedalmond:[255,235,205],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,
107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],
goldenrod:[218,165,32],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,
160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,
25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],oldlace:[253,245,230],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],rebeccapurple:[102,51,153],rosybrown:[188,143,143],royalblue:[65,
105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],whitesmoke:[245,245,245],yellowgreen:[154,205,50]};return b}();b.prototype.declaredClass=
"esri.Color";return b})},"esri/ground/navigationConstraints":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/Warning ../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h){Object.defineProperty(e,"__esModule",{value:!0});b=function(a){function c(){return null!==a&&a.apply(this,arguments)||this}m(c,a);d([h.enumeration.serializable()({none:"none",stayAbove:"stay-above"}),h.property({readOnly:!0,json:{read:!1}})],
c.prototype,"type",void 0);return c=d([h.subclass("esri.ground.NavigationConstraint")],c)}(h.declared(k));e.NavigationConstraint=b;k=function(a){function c(){var c=null!==a&&a.apply(this,arguments)||this;c.type="none";return c}m(c,a);f=c;c.prototype.clone=function(){return new f};var f;d([h.property({type:["none"],json:{type:["none"]}})],c.prototype,"type",void 0);return c=f=d([h.subclass("esri.ground.NoneNavigationConstraint")],c)}(h.declared(b));e.NoneNavigationConstraint=k;var a=function(a){function c(){var c=
null!==a&&a.apply(this,arguments)||this;c.type="stay-above";return c}m(c,a);f=c;c.prototype.clone=function(){return new f};var f;d([h.property({type:["stay-above"],json:{type:["stayAbove"]}})],c.prototype,"type",void 0);return c=f=d([h.subclass("esri.ground.StayAboveNavigationConstraint")],c)}(h.declared(b));e.StayAboveNavigationConstraint=a;e.readNavigationConstraint=function(a,b,d){if(b=a&&c[a.type])return b=new b,b.read(a,d),b;d&&d.messages&&a&&d.messages.push(new l("navigationconstraint:unsupported",
"Navigation constraint of type '"+(a.type||"unknown")+"' is not supported",{definition:a,context:d}))};var c={none:k,stayAbove:a};e.navigationConstraintTypes={key:"type",base:b,typeMap:{none:k,"stay-above":a}}})},"esri/layers/support/types":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.isOfType=function(b,d){b=b.constructor._meta;if(!b||!b.bases)return!1;b=b.bases;var e=Array.isArray(d);return b.some(function(b){b=b.__accessorMetadata__;if(!b)return!1;
b=b.properties;if(!b||!b.type||!b.type.value)return!1;b=b.type.value;return e?-1!==d.indexOf(b):b===d})}})},"esri/webdoc/support/opacityUtils":function(){define(["require","exports","../../core/accessorSupport/ensureType"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.opacityToTransparency=function(b){b=m.ensureInteger(100*(1-b));return Math.max(0,Math.min(b,100))};e.transparencyToOpacity=function(b){return Math.max(0,Math.min(1-b/100,1))}})},"esri/core/CollectionFlattener":function(){define("require exports ./tsSupport/declareExtendsHelper ./tsSupport/decorateHelper ./Collection ./Handles ./accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c._handles=new l;c.root=null;c.refresh=c.refresh.bind(c);c.updateCollections=c.updateCollections.bind(c);return c}m(c,a);c.prototype.initialize=function(){var a=this;this._handles.add(this.rootCollectionNames.map(function(c){return a.watch("root."+c,a.updateCollections,!0)}));this.updateCollections()};c.prototype.destroy=function(){this.root=null;this.refresh();this._handles.destroy();this._handles=null};c.prototype.updateCollections=
function(){var a=this;this._collections=this.rootCollectionNames.map(function(c){return a.get("root."+c)}).filter(function(a){return null!=a});this.refresh()};c.prototype.refresh=function(){var a=this._handles;a.remove("collections");this.removeAll();for(var c=this._collections.slice(),b=0,d=this._collections;b<d.length;b++)this._processCollection(c,this,d[b]);for(b=0;b<c.length;b++)a.add(c[b].on("after-changes",this.refresh),"collections")};c.prototype._createNewInstance=function(a){return new k(a)};
c.prototype._processCollection=function(a,c,b){var f=this;b&&(a.push(b),b.forEach(function(b){b&&(c.push(b),f._processCollection(a,c,f.getChildrenFunction(b)))}))};d([h.property()],c.prototype,"rootCollectionNames",void 0);d([h.property()],c.prototype,"root",void 0);d([h.property()],c.prototype,"getChildrenFunction",void 0);return c=d([h.subclass("esri.core.CollectionFlattener")],c)}(h.declared(k))})},"esri/core/Handles":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ./Accessor ./Collection ./accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c._groups=new Map;return c}m(c,a);c.prototype.destroy=function(){this.removeAll()};Object.defineProperty(c.prototype,"size",{get:function(){var a=0;this._groups.forEach(function(c){a+=c.length});return a},enumerable:!0,configurable:!0});c.prototype.add=function(a,c){var b=this;if(!this._isHandle(a)&&!Array.isArray(a)&&!l.isCollection(a))return this;var f=this._getOrCreateGroup(c);Array.isArray(a)||l.isCollection(a)?a.forEach(function(a){return b._isHandle(a)&&
f.push(a)}):f.push(a);this.notifyChange("size");return this};c.prototype.forEach=function(a,c){if("function"===typeof a)this._groups.forEach(function(c){return c.forEach(a)});else{var b=this._getGroup(a);b&&b.forEach(c)}};c.prototype.has=function(a){return this._groups.has(this._ensureGroupKey(a))};c.prototype.remove=function(a){if(Array.isArray(a)||l.isCollection(a))return a.forEach(this.remove,this),this;if(!this.has(a))return this;for(var c=this._getGroup(a),b=0;b<c.length;b++)c[b].remove();this._deleteGroup(a);
this.notifyChange("size");return this};c.prototype.removeAll=function(){this._groups.forEach(function(a){for(var c=0;c<a.length;c++)a[c].remove()});this._groups.clear();this.notifyChange("size");return this};c.prototype._isHandle=function(a){return a&&!!a.remove};c.prototype._getOrCreateGroup=function(a){if(this.has(a))return this._getGroup(a);var c=[];this._groups.set(this._ensureGroupKey(a),c);return c};c.prototype._getGroup=function(a){return this._groups.get(this._ensureGroupKey(a))};c.prototype._deleteGroup=
function(a){return this._groups.delete(this._ensureGroupKey(a))};c.prototype._ensureGroupKey=function(a){return a||"_default_"};d([h.property({readOnly:!0})],c.prototype,"size",null);return c=d([h.subclass("esri.core.Handles")],c)}(h.declared(k))})},"esri/support/basemapUtils":function(){define("require exports ../Basemap ../core/Collection ../core/Logger ../core/urlUtils ../core/accessorSupport/ensureType ./basemapDefinitions".split(" "),function(b,e,m,d,k,l,h,a){function c(c,b){var f;if("string"===
typeof c){if(!(c in a))return b=Object.keys(a).map(function(a){return'"'+a+'"'}).join(", "),y.warn("Unable to find basemap definition for: "+c+". Try one of these: "+b),null;b&&(f=b[c]);f||(f=m.fromId(c),b&&(b[c]=f))}else f=h.default(m,c);return f}function f(a,c){return a.map(function(a){return c.find(function(c){return u(q(a),q(c))})||a})}function n(a){return a?!a.loaded&&a.resourceInfo?p(a.resourceInfo.data):{baseLayers:g(a.baseLayers),referenceLayers:g(a.referenceLayers)}:null}function g(a){return(d.isCollection(a)?
a.toArray():a).map(q)}function q(a){return{type:a.type,url:z("urlTemplate"in a&&a.urlTemplate||a.url||"styleUrl"in a&&a.styleUrl),minScale:"minScale"in a&&null!=a.minScale?a.minScale:0,maxScale:"maxScale"in a&&null!=a.maxScale?a.maxScale:0,opacity:null!=a.opacity?a.opacity:1,visible:null!=a.visible?!!a.visible:!0}}function p(a){return a?{baseLayers:t(a.baseMapLayers.filter(function(a){return!a.isReference})),referenceLayers:t(a.baseMapLayers.filter(function(a){return a.isReference}))}:null}function t(a){return a.map(function(a){var c;
switch(a.layerType){case "VectorTileLayer":c="vector-tile";break;case "ArcGISTiledMapServiceLayer":c="tile";break;default:c="unknown"}return{type:c,url:z(a.templateUrl||a.urlTemplate||a.styleUrl||a.url),minScale:null!=a.minScale?a.minScale:0,maxScale:null!=a.maxScale?a.maxScale:0,opacity:null!=a.opacity?a.opacity:1,visible:null!=a.visibility?!!a.visibility:!0}})}function r(a,c,b){return null!=a!==(null!=c)?"not-equal":a?v(a.baseLayers,c.baseLayers)?v(a.referenceLayers,c.referenceLayers)?"equal":b.mustMatchReferences?
"not-equal":"base-layers-equal":"not-equal":"equal"}function v(a,c){if(a.length!==c.length)return!1;for(var b=0;b<a.length;b++)if(!u(a[b],c[b]))return!1;return!0}function u(a,c){return a.type===c.type&&a.url===c.url&&a.minScale===c.minScale&&a.maxScale===c.maxScale&&a.visible===c.visible&&a.opacity===c.opacity}function z(a){return a?l.normalize(a).replace(/^\s*https?:/i,"").toLowerCase():""}Object.defineProperty(e,"__esModule",{value:!0});var y=k.getLogger("esri.support.basemapUtils");e.createCache=
function(){return{}};e.ensureType=c;e.clonePreservingTiledLayers=function(a,b){void 0===b&&(b=null);a=c(a);if(!a)return null;var d=new m({id:a.id,title:a.title,baseLayers:a.baseLayers.slice(),referenceLayers:a.referenceLayers.slice()});b&&(d.baseLayers=f(d.baseLayers,b.baseLayers),d.referenceLayers=f(d.referenceLayers,b.referenceLayers));d.load();d.portalItem=a.portalItem;return d};e.getWellKnownBasemapId=function(c){var b=null;c=n(c);for(var f in a){var d=p(a[f]),d=r(c,d,{mustMatchReferences:!1});
if("equal"===d){b=f;break}"base-layers-equal"===d&&(b=f)}return b};e.contentEquals=function(a,c){if(a===c)return!0;a=n(a);c=n(c);return"equal"===r(a,c,{mustMatchReferences:!0})}})},"esri/support/groundUtils":function(){define(["require","exports","../Ground","../core/Logger","../core/accessorSupport/ensureType"],function(b,e,m,d,k){Object.defineProperty(e,"__esModule",{value:!0});var l=d.getLogger("esri.support.groundUtils");e.groundElevationLayers={"world-elevation":{id:"worldElevation",url:"//elevation3d.arcgis.com/arcgis/rest/services/WorldElevation3D/Terrain3D/ImageServer",
layerType:"ArcGISTiledElevationServiceLayer"},"world-topobathymetry":{id:"worldTopoBathymetry",url:"//elevation3d.arcgis.com/arcgis/rest/services/WorldElevation3D/TopoBathy3D/ImageServer",layerType:"ArcGISTiledElevationServiceLayer"}};e.ensureType=function(b){var a;"string"===typeof b?b in e.groundElevationLayers?a=new m({resourceInfo:{data:{layers:[e.groundElevationLayers[b]]}}}):l.warn("Unable to find ground definition for: "+b+'. Try "world-elevation"'):a=k.default(m,b);return a}})},"esri/support/LayersMixin":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Accessor ../core/collectionUtils ../core/Logger ../core/promiseUtils ../core/accessorSupport/decorators ../layers/Layer ../layers/support/LayerCollection".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){function g(a,c,b){for(var f,d=0,e=a.length;d<e;d++)if(f=a.getItemAt(d),f[c]===b||f&&"group"===f.type&&(f=g(f.layers,c,b)))return f}var q=h.getLogger("esri.support.LayersMixin");return function(b){function e(a){var c=b.call(this,a)||this;c.layers=new n.default;c.layers.on("after-add",function(a){a=a.item;a.parent&&a.parent!==c&&"remove"in a.parent&&a.parent.remove(a);a.parent=c;c.layerAdded(a);"elevation"===a.type&&q.error("Layer '"+a.title+", id:"+a.id+"' of type '"+
a.type+"' is not supported as an operational layer and will therefore be ignored.")});c.layers.on("after-remove",function(a){a=a.item;a.parent=null;c.layerRemoved(a)});return c}m(e,b);e.prototype.destroy=function(){this.layers.drain(this.layerRemoved,this)};Object.defineProperty(e.prototype,"layers",{set:function(a){this._set("layers",l.referenceSetter(a,this._get("layers"),n.default))},enumerable:!0,configurable:!0});e.prototype.findLayerById=function(a){return g(this.layers,"id",a)};e.prototype.add=
function(c,b){var d=this,e=this.layers;b=e.getNextIndex(b);c instanceof f?(c.parent===this&&this.reorder(c,b),e.add(c,b)):a.isThenable(c)?c.then(function(a){d.destroyed||d.add(a,b)}):q.error("#add()","The item being added is not a Layer or a Promise that resolves to a Layer.")};e.prototype.addMany=function(a,c){var b=this,f=this.layers;c=f.getNextIndex(c);a.slice().forEach(function(a){a.parent===b?b.reorder(a,c):(f.add(a,c),c+=1)})};e.prototype.findLayerByUid=function(a){return g(this.layers,"uid",
a)};e.prototype.remove=function(a){return this.layers.remove(a)};e.prototype.removeMany=function(a){return this.layers.removeMany(a)};e.prototype.removeAll=function(){return this.layers.removeAll()};e.prototype.reorder=function(a,c){return this.layers.reorder(a,c)};e.prototype.layerAdded=function(a){};e.prototype.layerRemoved=function(a){};d([c.property({type:n.default,cast:l.castForReferenceSetter})],e.prototype,"layers",null);return e=d([c.subclass("esri.support.LayersMixin")],e)}(c.declared(k))})},
"esri/geometry":function(){define("require exports ./core/kebabDictionary ./core/accessorSupport/ensureType ./geometry/Extent ./geometry/Geometry ./geometry/Multipoint ./geometry/Point ./geometry/Polygon ./geometry/Polyline ./geometry/SpatialReference ./geometry/support/jsonUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){Object.defineProperty(e,"__esModule",{value:!0});e.Extent=k;e.BaseGeometry=l;e.Multipoint=h;e.Point=a;e.Polygon=c;e.Polyline=f;e.SpatialReference=n;e.isGeometry=function(a){return a instanceof
e.BaseGeometry};e.fromJSON=g.fromJSON;e.typeKebabDictionary=m.strict()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"});e.isFeatureGeometryType=function(a){return"point"===a||"multipoint"===a||"polyline"===a||"polygon"===a};e.featureGeometryTypeKebabDictionary=m.strict()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"});
e.geometryTypes={base:e.BaseGeometry,key:"type",typeMap:{extent:e.Extent,multipoint:e.Multipoint,point:e.Point,polyline:e.Polyline,polygon:e.Polygon}};e.ensureType=d.ensureOneOfType(e.geometryTypes)})},"esri/geometry/Multipoint":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/lang ../core/accessorSupport/decorators ./Extent ./Geometry ./Point ./support/zmUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f){function n(a){return function(c,
b){return null==c?b:null==b?c:a(c,b)}}b=function(a){function b(){for(var c=0;c<arguments.length;c++);c=a.call(this)||this;c.points=[];c.type="multipoint";return c}m(b,a);e=b;b.prototype.normalizeCtorArgs=function(a,c){if(!a&&!c)return null;var b={};Array.isArray(a)?(b.points=a,b.spatialReference=c):!a||"esri.geometry.SpatialReference"!==a.declaredClass&&null==a.wkid?(a.points&&(b.points=a.points),a.spatialReference&&(b.spatialReference=a.spatialReference),a.hasZ&&(b.hasZ=a.hasZ),a.hasM&&(b.hasM=a.hasM)):
b.spatialReference=a;if(a=b.points&&b.points[0])void 0===b.hasZ&&void 0===b.hasM?(b.hasZ=2<a.length,b.hasM=!1):void 0===b.hasZ?b.hasZ=3<a.length:void 0===b.hasM&&(b.hasM=3<a.length);return b};Object.defineProperty(b.prototype,"extent",{get:function(){var a=this.points;if(!a.length)return null;for(var c=new h,b=this.hasZ,f=this.hasM,d=b?3:2,e=a[0],g=n(Math.min),p=n(Math.max),l=e[0],k=e[1],q=e[0],e=e[1],m,E,G,Q,V=0,R=a.length;V<R;V++){var I=a[V],W=I[0],M=I[1],l=g(l,W),k=g(k,M),q=p(q,W),e=p(e,M);b&&
2<I.length&&(W=I[2],m=g(m,W),G=p(G,W));f&&I.length>d&&(I=I[d],E=g(E,I),Q=p(Q,I))}c.xmin=l;c.ymin=k;c.xmax=q;c.ymax=e;c.spatialReference=this.spatialReference;b?(c.zmin=m,c.zmax=G):(c.zmin=null,c.zmax=null);f?(c.mmin=E,c.mmax=Q):(c.mmin=null,c.mmax=null);return c},enumerable:!0,configurable:!0});b.prototype.writePoints=function(a,c,b,f){c.points=k.clone(this.points)};b.prototype.addPoint=function(a){this.clearCache();f.updateSupportFromPoint(this,a);Array.isArray(a)?this.points.push(a):this.points.push(a.toArray());
return this};b.prototype.clone=function(){var a={points:k.clone(this.points),spatialReference:this.spatialReference};this.hasZ&&(a.hasZ=!0);this.hasM&&(a.hasM=!0);return new e(a)};b.prototype.getPoint=function(a){if(!this._validateInputs(a))return null;a=this.points[a];var b={x:a[0],y:a[1],spatialReference:this.spatialReference},f=2;this.hasZ&&(b.z=a[2],f=3);this.hasM&&(b.m=a[f]);return new c(b)};b.prototype.removePoint=function(a){if(!this._validateInputs(a))return null;this.clearCache();return new c(this.points.splice(a,
1)[0],this.spatialReference)};b.prototype.setPoint=function(a,c){if(!this._validateInputs(a))return this;this.clearCache();f.updateSupportFromPoint(c);this.points[a]=c.toArray();return this};b.prototype.toJSON=function(a){return this.write(null,a)};b.prototype._validateInputs=function(a){return null!=a&&0<=a&&a<this.points.length};var e;d([l.property({dependsOn:["points","hasZ","hasM","spatialReference"]})],b.prototype,"cache",void 0);d([l.property({dependsOn:["cache"]})],b.prototype,"extent",null);
d([l.property({type:[[Number]],json:{write:{isRequired:!0}}})],b.prototype,"points",void 0);d([l.writer("points")],b.prototype,"writePoints",null);return b=e=d([l.subclass("esri.geometry.Multipoint")],b)}(l.declared(a));b.prototype.toJSON.isDefaultToJSON=!0;return b})},"esri/geometry/support/zmUtils":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.updateSupportFromPoint=function(b,d,e){void 0===e&&(e=!1);var l=b.hasM,h=b.hasZ;Array.isArray(d)?
4!==d.length||l||h?3===d.length&&e&&!l?(h=!0,l=!1):3===d.length&&l&&h&&(h=l=!1):h=l=!0:(h=!h&&d.hasZ&&(!l||d.hasM),l=!l&&d.hasM&&(!h||d.hasZ));b.hasZ=h;b.hasM=l}})},"esri/geometry/Polygon":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/lang ../core/screenUtils ../core/accessorSupport/decorators ./Extent ./Geometry ./Point ./SpatialReference ./support/centroid ./support/contains ./support/coordsUtils ./support/extentUtils ./support/intersects ./support/webMercatorUtils ./support/zmUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u){b=function(c){function b(){for(var a=0;a<arguments.length;a++);a=c.call(this)||this;a.rings=[];a.type="polygon";return a}m(b,c);e=b;b.createEllipse=function(a){var c=a.center.x,b=a.center.y,f=a.center.z,d=a.center.m,g=a.center.hasZ,h=a.center.hasM,p=a.longAxis,n=a.shortAxis,t=a.numberOfPoints;a=a.view;for(var r=[],k=2*Math.PI/t,q=g?3:2,v=0;v<t;v++){var m=a.toMap(l.createScreenPoint(p*Math.cos(v*k)+c,n*Math.sin(v*k)+b)),m=[m.x,m.y];g&&(m[2]=f);h&&(m[q]=
d);r.push(m)}r.push(r[0]);return new e({rings:[r],spatialReference:a.spatialReference})};b.createCircle=function(a){return e.createEllipse({center:a.center,longAxis:a.r,shortAxis:a.r,numberOfPoints:a.numberOfPoints,view:a.view})};b.fromExtent=function(a){var c=a.clone().normalize();a=a.spatialReference;var b=!1,f=!1;c.map(function(a){a.hasZ&&(b=!0);a.hasM&&(f=!0)});c={rings:c.map(function(a){var c=[[a.xmin,a.ymin],[a.xmin,a.ymax],[a.xmax,a.ymax],[a.xmax,a.ymin],[a.xmin,a.ymin]];if(b&&a.hasZ)for(var d=
a.zmin+.5*(a.zmax-a.zmin),e=0;e<c.length;e++)c[e].push(d);if(f&&a.hasM)for(a=a.mmin+.5*(a.mmax-a.mmin),e=0;e<c.length;e++)c[e].push(a);return c}),spatialReference:a};b&&(c.hasZ=!0);f&&(c.hasM=!0);return new e(c)};b.prototype.normalizeCtorArgs=function(a,c){var b=null,f,d,e=null;a&&!Array.isArray(a)?(b=a.rings?a.rings:null,c||(a.spatialReference?c=a.spatialReference:a.rings||(c=a)),f=a.hasZ,d=a.hasM):b=a;b=b||[];c=c||n.WGS84;b.length&&b[0]&&null!=b[0][0]&&"number"===typeof b[0][0]&&(b=[b]);if(e=b[0]&&
b[0][0])void 0===f&&void 0===d?(f=2<e.length,d=!1):void 0===f?f=!d&&3<e.length:void 0===d&&(d=!f&&3<e.length);return{rings:b,spatialReference:c,hasZ:f,hasM:d}};Object.defineProperty(b.prototype,"centroid",{get:function(){var a=g.polygonCentroid(this);if(!a||isNaN(a[0])||isNaN(a[1])||this.hasZ&&isNaN(a[2]))return null;var c=new f;c.x=a[0];c.y=a[1];c.spatialReference=this.spatialReference;this.hasZ&&(c.z=a[2]);return c},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"extent",{get:function(){var c=
this.spatialReference,b=new a(t.getPolygonExtent(this));b.spatialReference=c;return b},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"isSelfIntersecting",{get:function(){return r.isSelfIntersecting(this.rings)},enumerable:!0,configurable:!0});b.prototype.writePaths=function(a,c,b,f){c.rings=k.clone(this.rings)};b.prototype.addRing=function(a){if(a){this.clearCache();var c=this.rings,b=c.length;if(Array.isArray(a[0]))c[b]=a.concat();else{for(var f=[],d=0,e=a.length;d<e;d++)f[d]=
a[d].toArray();c[b]=f}return this}};b.prototype.clone=function(){var a=new e;a.spatialReference=this.spatialReference;a.rings=k.clone(this.rings);a.hasZ=this.hasZ;a.hasM=this.hasM;return a};b.prototype.contains=function(a){if(!a)return!1;v.canProject(a,this.spatialReference)&&(a=v.project(a,this.spatialReference));return q.polygonContainsPoint(this,a)};b.prototype.isClockwise=function(a){var c=this;a=Array.isArray(a[0])?a:a.map(function(a){return c.hasZ?c.hasM?[a.x,a.y,a.z,a.m]:[a.x,a.y,a.z]:[a.x,
a.y]});return p.isClockwise(a,this.hasM,this.hasZ)};b.prototype.getPoint=function(a,c){if(!this._validateInputs(a,c))return null;a=this.rings[a][c];c=this.hasZ;var b=this.hasM;return c&&!b?new f(a[0],a[1],a[2],void 0,this.spatialReference):b&&!c?new f(a[0],a[1],void 0,a[2],this.spatialReference):c&&b?new f(a[0],a[1],a[2],a[3],this.spatialReference):new f(a[0],a[1],this.spatialReference)};b.prototype.insertPoint=function(a,c,b){if(!this._validateInputs(a,c,!0))return this;this.clearCache();u.updateSupportFromPoint(this,
b);Array.isArray(b)||(b=b.toArray());this.rings[a].splice(c,0,b);return this};b.prototype.removePoint=function(a,c){if(!this._validateInputs(a,c))return null;this.clearCache();return new f(this.rings[a].splice(c,1)[0],this.spatialReference)};b.prototype.removeRing=function(a){if(!this._validateInputs(a,null))return null;this.clearCache();a=this.rings.splice(a,1)[0];var c=this.spatialReference;return a.map(function(a){return new f(a,c)})};b.prototype.setPoint=function(a,c,b){if(!this._validateInputs(a,
c))return this;this.clearCache();u.updateSupportFromPoint(this,b);Array.isArray(b)||(b=b.toArray());this.rings[a][c]=b;return this};b.prototype._validateInputs=function(a,c,b){void 0===b&&(b=!1);return null==a||0>a||a>=this.rings.length||null!=c&&(a=this.rings[a],b&&(0>c||c>a.length)||!b&&(0>c||c>=a.length))?!1:!0};b.prototype.toJSON=function(a){return this.write(null,a)};var e;d([h.property({dependsOn:["hasM","hasZ","rings"]})],b.prototype,"cache",void 0);d([h.property({readOnly:!0,dependsOn:["cache"]})],
b.prototype,"centroid",null);d([h.property({dependsOn:["cache"],readOnly:!0})],b.prototype,"extent",null);d([h.property({dependsOn:["cache"],readOnly:!0})],b.prototype,"isSelfIntersecting",null);d([h.property({type:[[[Number]]],json:{write:{isRequired:!0}}})],b.prototype,"rings",void 0);d([h.writer("rings")],b.prototype,"writePaths",null);return b=e=d([h.subclass("esri.geometry.Polygon")],b)}(h.declared(c));b.prototype.toJSON.isDefaultToJSON=!0;return b})},"esri/core/screenUtils":function(){define(["require",
"exports","./compilerUtils","./libs/gl-matrix-2/vec2f64","./libs/gl-matrix-2/vec3f64"],function(b,e,m,d,k){function l(a){return a?72*a/e.DPI:0}function h(a,c){void 0===a&&(a=0);void 0===c&&(c=0);return{x:a,y:c}}function a(a,c){void 0===a&&(a=0);void 0===c&&(c=0);return d.vec2f64.fromValues(a,c)}function c(a,c){void 0===a&&(a=0);void 0===c&&(c=0);return{x:a,y:c}}function f(a,c){void 0===a&&(a=0);void 0===c&&(c=0);return d.vec2f64.fromValues(a,c)}function n(a,c){return c?(c[0]=a.x,c[1]=a.y,2<c.length&&
(c[2]=0),c):d.vec2f64.fromValues(a.x,a.y)}function g(a){return h(a.x,a.y)}function q(a,c){a=(a instanceof HTMLElement?a:a.surface).getBoundingClientRect();return h(c.clientX-a.left,c.clientY-a.top)}Object.defineProperty(e,"__esModule",{value:!0});var p=/^-?(\d+(\.\d+)?)\s*((px)|(pt))?$/i;e.DPI=96;e.pt2px=function(a){return a?a/72*e.DPI:0};e.px2pt=l;e.toPt=function(a){if("string"===typeof a){if(p.test(a)){var c=a.match(p),b=Number(c[1]),c=c[3]&&c[3].toLowerCase();a="-"===a.charAt(0);b="px"===c?l(b):
b;return a?-b:b}console.warn("screenUtils.toPt: input not recognized!");return null}return a};e.createScreenPoint=h;e.createScreenPointArray=a;e.createRenderScreenPoint=c;e.createRenderScreenPointArray=f;e.createRenderScreenPointArray3=function(a,c,b){void 0===a&&(a=0);void 0===c&&(c=0);void 0===b&&(b=0);return k.vec3f64.fromValues(a,c,b)};e.castRenderScreenPointArray=function(a){return a};e.castRenderScreenPointArray3=function(a){return a};e.castScreenPointArray=function(a){return a};e.screenToRender=
function(a,b,f){var d,e;switch(a.type){case "2d":a=window.devicePixelRatio||1;d=b.x*a;e=b.y*a;break;case "3d":n(b,r),a.state.camera.screenToRender(r,t),d=t[0],e=t[1]}return f?(f.x=d,f.y=e,f):c(d,e)};e.renderToScreen=function(a,c,b){var f,d;switch(a.type){case "2d":a=window.devicePixelRatio||1;f=c.x/a;d=c.y/a;break;case "3d":n(c,t),a.state.camera.renderToScreen(t,r),f=r[0],d=r[1]}return b?(b.x=f,b.y=d,b):h(f,d)};e.screenArrayToRender=function(a,c,b){var d,e;switch(a.type){case "2d":a=window.devicePixelRatio||
1;d=c[0]*a;e=c[1]*a;break;case "3d":a.state.camera.screenToRender(c,t),d=t[0],e=t[1]}return b?(b[0]=d,b[1]=e,2<b.length&&(b[2]=0),b):f(d,e)};e.renderArrayToScreen=function(c,b,f){var d,e;switch(c.type){case "2d":c=window.devicePixelRatio||1;d=b[0]/c;e=b[0]/c;break;case "3d":c.state.camera.renderToScreen(b,r),d=r[0],e=r[1]}return f?(f[0]=d,f[1]=e,f):a(d,e)};e.screenPointArrayToObject=function(a,c){return c?(c.x=a[0],c.y=a[1],c):{x:a[0],y:a[1]}};e.screenPointObjectToArray=n;e.createScreenPointFromEvent=
g;e.createScreenPointFromNativeEvent=q;e.createScreenPointFromSupportedEvent=function(a,c){return c instanceof Event?q(a,c):g(c)};e.isSupportedScreenPointEvent=function(a){if(a instanceof Event)return!0;if("object"===typeof a&&"type"in a)switch(a=a.type,a){case "click":case "double-click":case "pointer-down":case "pointer-drag":case "pointer-enter":case "pointer-leave":case "pointer-up":case "pointer-move":case "immediate-click":case "hold":case "drag":case "mouse-wheel":return!0;case "key-down":case "key-up":case "gamepad":case "focus":case "blur":break;
default:m.neverReachedSilent(a)}return!1};var t=f(),r=a()})},"esri/core/libs/gl-matrix-2/vec2f64":function(){define(["require","exports","./factories/vec2f64"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.vec2f64=m})},"esri/core/libs/gl-matrix-2/factories/vec2f64":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.create=function(){return[0,0]};e.clone=function(b){return[b[0],b[1]]};e.fromValues=function(b,d){return[b,d]};
e.fromArray=function(b){for(var d=[0,0],e=Math.min(2,b.length),l=0;l<e;++l)d[l]=b[l];return d};e.createView=function(b,d){return new Float64Array(b,d,2)}})},"esri/core/libs/gl-matrix-2/vec3f64":function(){define(["require","exports","./factories/vec3f64"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.vec3f64=m})},"esri/core/libs/gl-matrix-2/factories/vec3f64":function(){define(["require","exports"],function(b,e){function m(){return[0,0,0]}Object.defineProperty(e,"__esModule",
{value:!0});e.create=m;e.clone=function(b){return[b[0],b[1],b[2]]};e.fromValues=function(b,e,l){return[b,e,l]};e.fromArray=function(b){for(var d=m(),e=Math.min(3,b.length),h=0;h<e;++h)d[h]=b[h];return d};e.createView=function(b,e){return new Float64Array(b,e,3)}})},"esri/geometry/support/centroid":function(){define(["require","exports","./coordsUtils"],function(b,e,m){function d(b,a){if(!b||!b.length)return null;for(var c=[],f=[],d=a?[Infinity,-Infinity,Infinity,-Infinity,Infinity,-Infinity]:[Infinity,
-Infinity,Infinity,-Infinity],e=0,h=b.length;e<h;e++){var p=k(b[e],a,d);p&&f.push(p)}f.sort(function(c,b){var f=c[2]-b[2];0===f&&a&&(f=c[4]-b[4]);return f});f.length&&(e=6*f[0][2],c[0]=f[0][0]/e,c[1]=f[0][1]/e,a&&(e=6*f[0][4],c[2]=0!==e?f[0][3]/e:0),c[0]<d[0]||c[0]>d[1]||c[1]<d[2]||c[1]>d[3]||a&&(c[2]<d[4]||c[2]>d[5]))&&(c.length=0);if(!c.length)if(b=b[0]&&b[0].length?l(b[0],a):null)c[0]=b[0],c[1]=b[1],a&&2<b.length&&(c[2]=b[2]);else return null;return c}function k(b,a,c){for(var f=0,d=0,e=0,h=0,
p=0,t=0,l=b.length-1;t<l;t++){var k=b[t],m=k[0],z=k[1],y=k[2],x=b[t+1],w=x[0],A=x[1],B=x[2],F=m*A-w*z,h=h+F,f=f+(m+w)*F,d=d+(z+A)*F;a&&2<k.length&&2<x.length&&(F=m*B-w*y,e+=(y+B)*F,p+=F);m<c[0]&&(c[0]=m);m>c[1]&&(c[1]=m);z<c[2]&&(c[2]=z);z>c[3]&&(c[3]=z);a&&(y<c[4]&&(c[4]=y),y>c[5]&&(c[5]=y))}0<h&&(h*=-1);0<p&&(p*=-1);if(!h)return null;b=[f,d,.5*h];a&&(b[3]=e,b[4]=.5*p);return b}function l(b,a){for(var c=a?[0,0,0]:[0,0],f=a?[0,0,0]:[0,0],d=0,e=0,h=0,p=0,t=0,l=b.length;t<l-1;t++){var k=b[t],u=b[t+
1];if(k&&u){c[0]=k[0];c[1]=k[1];f[0]=u[0];f[1]=u[1];a&&2<k.length&&2<u.length&&(c[2]=k[2],f[2]=u[2]);var z=m.getLength(c,f);z&&(d+=z,k=m.getMidpoint(k,u),e+=z*k[0],h+=z*k[1],a&&2<k.length&&(p+=z*k[2]))}}return 0<d?a?[e/d,h/d,p/d]:[e/d,h/d]:b.length?b[0]:null}Object.defineProperty(e,"__esModule",{value:!0});e.extentCentroid=function(b){return b?b.hasZ?[b.xmax-b.xmin/2,b.ymax-b.ymin/2,b.zmax-b.zmin/2]:[b.xmax-b.xmin/2,b.ymax-b.ymin/2]:null};e.polygonCentroid=function(b){return b?d(b.rings,b.hasZ):null};
e.ringsCentroid=d;e.lineCentroid=l})},"esri/geometry/support/coordsUtils":function(){define(["require","exports","./spatialReferenceUtils"],function(b,e,m){function d(b,a){var c=a[0]-b[0],f=a[1]-b[1];return 2<b.length&&2<a.length?(b=b[2]-a[2],Math.sqrt(c*c+f*f+b*b)):Math.sqrt(c*c+f*f)}function k(b,a,c){var f=b[0]+c*(a[0]-b[0]),d=b[1]+c*(a[1]-b[1]);return 2<b.length&&2<a.length?[f,d,b[2]+c*(a[2]-b[2])]:[f,d]}function l(b,a){if(a=m.getInfo(a)){var c=a.valid[0],f=a.valid[1],d=f-c;a=function(a){var b=
Infinity,e=-Infinity;a.forEach(function(a){for(var g=a[0];g<c;)g+=d;for(;g>f;)g-=d;b=Math.min(b,g);e=Math.max(e,g);a[0]=g});var g=e-b;d-g<g&&a.forEach(function(a){0>a[0]&&(a[0]+=d)})};for(var e=0;e<b.length;e++)a(b[e])}}Object.defineProperty(e,"__esModule",{value:!0});e.geometryToCoordinates=function(b){if(!b)return null;if(Array.isArray(b))return b;var a=b.hasZ,c=b.hasM;if("point"===b.type)return c&&a?[b.x,b.y,b.z,b.m]:a?[b.x,b.y,b.z]:c?[b.x,b.y,b.m]:[b.x,b.y];if("polygon"===b.type)return b.rings.slice(0);
if("polyline"===b.type)return b.paths.slice(0);if("multipoint"===b.type)return b.points.slice(0);if("extent"===b.type){b=b.clone().normalize();if(!b)return null;var f=!1,d=!1;b.forEach(function(a){a.hasZ&&(f=!0);a.hasM&&(d=!0)});return b.map(function(a){var c=[[a.xmin,a.ymin],[a.xmin,a.ymax],[a.xmax,a.ymax],[a.xmax,a.ymin],[a.xmin,a.ymin]];if(f&&a.hasZ)for(var b=.5*(a.zmax-a.zmin),e=0;e<c.length;e++)c[e].push(b);if(d&&a.hasM)for(a=.5*(a.mmax-a.mmin),e=0;e<c.length;e++)c[e].push(a);return c})}return null};
e.getLength=d;e.getMidpoint=function(b,a){return k(b,a,.5)};e.getPathLength=function(b){for(var a=b.length,c=0,f=0;f<a-1;++f)c+=d(b[f],b[f+1]);return c};e.getPointOnPath=function(b,a){if(0>=a)return b[0];for(var c=b.length,f=0,e=0;e<c-1;++e){var g=d(b[e],b[e+1]);if(a-f<g)return k(b[e],b[e+1],(a-f)/g);f+=g}return b[c-1]};e.isClockwise=function(b,a,c){for(var f=b.length,d=0,e=0,h=0,p=0;p<f;p++){var t=b[p],l=b[(p+1)%f],k=2,d=d+(t[0]*l[1]-l[0]*t[1]);2<t.length&&2<l.length&&c&&(e+=t[0]*l[2]-l[0]*t[2],
k=3);t.length>k&&l.length>k&&a&&(h+=t[0]*l[k]-l[0]*t[k])}return 0>=d&&0>=e&&0>=h};e.getRingArea=function(b){for(var a=b.length,c=0,f=0;f<a;f++)var d=b[f],e=b[(f+1)%a],c=c+(d[0]*e[1]-e[0]*d[1]);return c};e.unnormalizeGeometryOnDatelineCrossing=function(b){if("polygon"!==b.type&&"polyline"!==b.type)return b;l("polygon"===b.type?b.rings:b.paths,b.spatialReference);return b};e.unnormalizeVerticesOnDatelineCrossing=l;e.computeUnnormalizedVertexPositionsOnDateLineCrossing=function(b,a,c,f){var d=Infinity,
e=-Infinity;b.forEach(function(b){for(var g=b.pos[0];g<a;)g+=f;for(;g>c;)g-=f;d=Math.min(d,g);e=Math.max(e,g);b.unnormalizedPos[0]=g;b.unnormalizedPos[1]=b.pos[1]});var h=e-d;f-h<h&&b.forEach(function(a){0>a.unnormalizedPos[0]&&(a.unnormalizedPos[0]+=f)})}})},"esri/geometry/support/extentUtils":function(){define(["require","exports","./boundsUtils"],function(b,e,m){function d(a,c,b){void 0===c&&(c=!1);void 0===b&&(b=!1);return c?b?{xmin:a[0],ymin:a[1],zmin:a[2],mmin:a[3],xmax:a[4],ymax:a[5],zmax:a[6],
mmax:a[7]}:{xmin:a[0],ymin:a[1],zmin:a[2],xmax:a[3],ymax:a[4],zmax:a[5]}:b?{xmin:a[0],ymin:a[1],mmin:a[2],xmax:a[3],ymax:a[4],mmax:a[5]}:{xmin:a[0],ymin:a[1],xmax:a[2],ymax:a[3]}}function k(a){var b=a.hasZ,f=a.hasM;return d(m.getPointsBounds(c,a.points,b,f),b,f)}function l(a){var c=a.x,b=a.y,d=a.z;a=a.m;var f=null!=a;return null!=d?f?{xmin:c,ymin:b,zmin:d,mmin:a,xmax:c,ymax:b,zmax:d,mmax:a}:{xmin:c,ymin:b,zmin:d,xmax:c,ymax:b,zmax:d}:f?{xmin:c,ymin:b,mmin:a,xmax:c,ymax:b,mmax:a}:{xmin:c,ymin:b,xmax:c,
ymax:b}}function h(a){var b=a.hasZ,f=a.hasM;return d(m.getRingsOrPathsBounds(c,a.rings,b,f),b,f)}function a(a){var b=a.hasZ,f=a.hasM;return d(m.getRingsOrPathsBounds(c,a.paths,b,f),b,f)}Object.defineProperty(e,"__esModule",{value:!0});var c=[];e.getGeometryExtent=function(c){return c?void 0!==c.xmin&&void 0!==c.ymin&&void 0!==c.xmax&&void 0!==c.ymax?c:void 0!==c.x&&void 0!==c.y?l(c):void 0!==c.rings?h(c):void 0!==c.paths?a(c):void 0!==c.points?k(c):null:null};e.getMultipointExtent=k;e.getPointExtent=
l;e.getPolygonExtent=h;e.getPolylineExtent=a})},"esri/geometry/support/boundsUtils":function(){define(["require","exports"],function(b,e){function m(a){return function(c,b){return null==c?b:null==b?c:a(c,b)}}function d(c,b,d,e){var f=d?3:2;if(!b.length||!b[0].length)return null;for(var g=b[0][0],n=g[0],g=g[1],l=b[0][0],k=l[0],l=l[1],m=void 0,z=void 0,y=void 0,x=void 0,w=0;w<b.length;w++)for(var A=b[w],B=0;B<A.length;B++){var F=A[B],C=F[0],E=F[1],n=h(n,C),g=h(g,E),k=a(k,C),l=a(l,E);d&&2<F.length&&
(C=F[2],m=h(m,C),z=a(z,C));e&&F.length>f&&(x=F[f],y=h(m,x),x=a(z,x))}if(d){if(e)return c[0]=n,c[1]=g,c[2]=m,c[3]=y,c[4]=k,c[5]=l,c[6]=z,c[7]=x,c.length=8,c;c[0]=n;c[1]=g;c[2]=m;c[3]=k;c[4]=l;c[5]=z;c.length=6;return c}if(e)return c[0]=n,c[1]=g,c[2]=y,c[3]=k,c[4]=l,c[5]=x,c.length=6,c;c[0]=n;c[1]=g;c[2]=k;c[3]=l;c.length=4;return c}function k(a,b,d,e,h,p){d=b.xmin;e=b.xmax;var c=b.ymin,f=b.ymax,g=b.zmin,n=b.zmax,l=b.mmin;b=b.mmax;if(h){g=g||0;n=n||0;if(p)return a[0]=d,a[1]=c,a[2]=g,a[3]=l||0,a[4]=
e,a[5]=f,a[6]=n,a[7]=b||0,a;a[0]=d;a[1]=c;a[2]=g;a[3]=e;a[4]=f;a[5]=n;return a}if(p)return a[0]=d,a[1]=c,a[2]=l||0,a[3]=e,a[4]=f,a[5]=b||0,a;a[0]=d;a[1]=c;a[2]=e;a[3]=f;return a}function l(c,b,d,e,l,p){var f=d?3:2;e=e&&p;d=d&&l;if(!b.length||!b[0].length)return null;for(var g=b[0],n=g[0],g=g[1],k=b[0],q=k[0],k=k[1],m=void 0,x=void 0,w=void 0,A=void 0,B=0;B<b.length;B++){var F=b[B],C=F[0],E=F[1],n=h(n,C),g=h(g,E),q=a(q,C),k=a(k,E);d&&2<F.length&&(C=F[2],m=h(m,C),x=a(x,C));e&&F.length>f&&(A=F[f],w=
h(m,A),A=a(x,A))}if(l){m=m||0;x=x||0;if(p)return c[0]=n,c[1]=g,c[2]=m,c[3]=w||0,c[4]=q,c[5]=k,c[6]=x,c[7]=A||0,c;c[0]=n;c[1]=g;c[2]=m;c[3]=q;c[4]=k;c[5]=x;return c}if(p)return c[0]=n,c[1]=g,c[2]=w||0,c[3]=q,c[4]=k,c[5]=A||0,c;c[0]=n;c[1]=g;c[2]=q;c[3]=k;return c}Object.defineProperty(e,"__esModule",{value:!0});var h=m(Math.min),a=m(Math.max);e.getBoundsXY=function(a,b){if(void 0!==b.paths)return d(a,b.paths,!1,!1);if(void 0!==b.rings)return d(a,b.rings,!1,!1);if(void 0!==b.points)return l(a,b.points,
!1,!1,!1,!1);if(void 0!==b.xmin&&void 0!==b.ymin&&void 0!==b.xmax&&void 0!==b.ymax)return k(a,b);void 0!==b.x&&void 0!==b.y&&(a[0]=b.x,a[1]=b.y,a[2]=b.x,a[3]=b.y);return a};e.getRingsOrPathsBounds=d;e.getExtentBounds=k;e.getPointsBounds=l;e.getPointsBoundsWidth=function(c){if(!c.length||!c[0].length)return null;for(var b=c[0][0],d=c[0][0],e=0;e<c.length;e++)var l=c[e][0],b=h(b,l),d=a(d,l);return d-b};e.getPointsBoundsCenterX=function(c){if(!c.length||!c[0].length)return null;for(var b=c[0][0],d=c[0][0],
e=0;e<c.length;e++)var l=c[e][0],b=h(b,l),d=a(d,l);return b+.5*(d-b)}})},"esri/geometry/Polyline":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/lang ../core/accessorSupport/decorators ./Extent ./Geometry ./Point ./SpatialReference ./support/extentUtils ./support/zmUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){b=function(a){function b(){for(var c=0;c<arguments.length;c++);c=a.call(this)||this;c.paths=[];c.type="polyline";return c}
m(b,a);e=b;b.prototype.normalizeCtorArgs=function(a,c){var b=null,d,e,g=null;a&&!Array.isArray(a)?(b=a.paths?a.paths:null,c||(a.spatialReference?c=a.spatialReference:a.paths||(c=a)),d=a.hasZ,e=a.hasM):b=a;b=b||[];c=c||f.WGS84;b.length&&b[0]&&null!=b[0][0]&&"number"===typeof b[0][0]&&(b=[b]);if(g=b[0]&&b[0][0])void 0===d&&void 0===e?(d=2<g.length,e=!1):void 0===d?d=!e&&3<g.length:void 0===e&&(e=!d&&3<g.length);return{paths:b,spatialReference:c,hasZ:d,hasM:e}};Object.defineProperty(b.prototype,"extent",
{get:function(){var a=this.spatialReference,c=new h(n.getPolylineExtent(this));c.spatialReference=a;return c},enumerable:!0,configurable:!0});b.prototype.writePaths=function(a,c,b,d){c.paths=k.clone(this.paths)};b.prototype.addPath=function(a){if(a){this.clearCache();var c=this.paths,b=c.length;if(Array.isArray(a[0]))c[b]=a.concat();else{for(var d=[],f=0,e=a.length;f<e;f++)d[f]=a[f].toArray();c[b]=d}return this}};b.prototype.clone=function(){var a=new e;a.spatialReference=this.spatialReference;a.paths=
k.clone(this.paths);a.hasZ=this.hasZ;a.hasM=this.hasM;return a};b.prototype.getPoint=function(a,b){if(!this._validateInputs(a,b))return null;a=this.paths[a][b];b=this.hasZ;var d=this.hasM;return b&&!d?new c(a[0],a[1],a[2],void 0,this.spatialReference):d&&!b?new c(a[0],a[1],void 0,a[2],this.spatialReference):b&&d?new c(a[0],a[1],a[2],a[3],this.spatialReference):new c(a[0],a[1],this.spatialReference)};b.prototype.insertPoint=function(a,c,b){if(!this._validateInputs(a,c,!0))return this;this.clearCache();
g.updateSupportFromPoint(this,b);Array.isArray(b)||(b=b.toArray());this.paths[a].splice(c,0,b);return this};b.prototype.removePath=function(a){if(!this._validateInputs(a,null))return null;this.clearCache();a=this.paths.splice(a,1)[0];var b=this.spatialReference;return a.map(function(a){return new c(a,b)})};b.prototype.removePoint=function(a,b){if(!this._validateInputs(a,b))return null;this.clearCache();return new c(this.paths[a].splice(b,1)[0],this.spatialReference)};b.prototype.setPoint=function(a,
c,b){if(!this._validateInputs(a,c))return this;this.clearCache();g.updateSupportFromPoint(this,b);Array.isArray(b)||(b=b.toArray());this.paths[a][c]=b;return this};b.prototype._validateInputs=function(a,c,b){void 0===b&&(b=!1);return null==a||0>a||a>=this.paths.length||null!=c&&(a=this.paths[a],b&&(0>c||c>a.length)||!b&&(0>c||c>=a.length))?!1:!0};b.prototype.toJSON=function(a){return this.write(null,a)};var e;d([l.property({dependsOn:["hasM","hasZ","paths"]})],b.prototype,"cache",void 0);d([l.property({dependsOn:["cache"],
readOnly:!0})],b.prototype,"extent",null);d([l.property({type:[[[Number]]],json:{write:{isRequired:!0}}})],b.prototype,"paths",void 0);d([l.writer("paths")],b.prototype,"writePaths",null);return b=e=d([l.subclass("esri.geometry.Polyline")],b)}(l.declared(a));b.prototype.toJSON.isDefaultToJSON=!0;return b})},"esri/geometry/support/jsonUtils":function(){define("require exports ../Extent ../Multipoint ../Point ../Polygon ../Polyline".split(" "),function(b,e,m,d,k,l,h){function a(a){return void 0!==a.xmin&&
void 0!==a.ymin&&void 0!==a.xmax&&void 0!==a.ymax}function c(a){return void 0!==a.points}function f(a){return void 0!==a.x&&void 0!==a.y}function n(a){return void 0!==a.paths}function g(a){return void 0!==a.rings}function q(b){return b?f(b)?k.fromJSON(b):n(b)?h.fromJSON(b):g(b)?l.fromJSON(b):c(b)?d.fromJSON(b):a(b)?m.fromJSON(b):null:null}Object.defineProperty(e,"__esModule",{value:!0});e.fromJson=function(a){try{throw Error("fromJson is deprecated, use fromJSON instead");}catch(r){console.warn(r.stack)}return q(a)};
e.isExtent=a;e.isMultipoint=c;e.isPoint=f;e.isPolyline=n;e.isPolygon=g;e.isMesh=function(a){return void 0!==a.vertexAttributes};e.fromJSON=q;e.getJsonType=function(b){return b?f(b)?"esriGeometryPoint":n(b)?"esriGeometryPolyline":g(b)?"esriGeometryPolygon":a(b)?"esriGeometryEnvelope":c(b)?"esriGeometryMultipoint":null:null};var p={esriGeometryPoint:k,esriGeometryPolyline:h,esriGeometryPolygon:l,esriGeometryEnvelope:m,esriGeometryMultipoint:d};e.getGeometryType=function(a){return a&&p[a]||null}})},
"esri/Viewpoint":function(){define("require exports ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./Camera ./geometry ./core/JSONSupport ./core/accessorSupport/decorators ./geometry/support/jsonUtils".split(" "),function(b,e,m,d,k,l,h,a,c){function f(){return{enabled:!this.camera}}return function(b){function e(a){a=b.call(this)||this;a.rotation=0;a.scale=0;a.targetGeometry=null;a.camera=null;return a}m(e,b);h=e;e.prototype.castRotation=function(a){a%=360;0>a&&(a+=360);return a};
e.prototype.clone=function(){return new h({rotation:this.rotation,scale:this.scale,targetGeometry:this.targetGeometry?this.targetGeometry.clone():null,camera:this.camera?this.camera.clone():null})};var h;d([a.property({type:Number,json:{write:!0,origins:{"web-scene":{write:{overridePolicy:f}}}}})],e.prototype,"rotation",void 0);d([a.cast("rotation")],e.prototype,"castRotation",null);d([a.property({type:Number,json:{write:!0,origins:{"web-scene":{write:{overridePolicy:f}}}}})],e.prototype,"scale",
void 0);d([a.property({types:l.geometryTypes,json:{read:c.fromJSON,write:!0,origins:{"web-scene":{read:c.fromJSON,write:{overridePolicy:f}}}}})],e.prototype,"targetGeometry",void 0);d([a.property({type:k,json:{write:!0}})],e.prototype,"camera",void 0);return e=h=d([a.subclass("esri.Viewpoint")],e)}(a.declared(h))})},"esri/Camera":function(){define("require exports ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./core/JSONSupport ./core/accessorSupport/decorators ./core/accessorSupport/ensureType ./geometry/Point ./views/3d/support/mathUtils".split(" "),
function(b,e,m,d,k,l,h,a,c){return function(b){function f(c,d,f,e){c=b.call(this)||this;c.position=new a([0,0,0]);c.heading=0;c.tilt=0;c.fov=55;return c}m(f,b);e=f;f.prototype.normalizeCtorArgs=function(a,c,b,d){a&&"object"===typeof a&&("x"in a||Array.isArray(a))&&(a={position:a},null!=c&&(a.heading=c),null!=b&&(a.tilt=b),null!=d&&(a.fov=d));return a};f.prototype.writePosition=function(a,c,b,d){var f=a.clone();f.x=h.ensureNumber(a.x||0);f.y=h.ensureNumber(a.y||0);f.z=a.hasZ?h.ensureNumber(a.z||0):
a.z;c[b]=f.write(null,d)};f.prototype.readPosition=function(c,b){var d=new a;d.read(c,b);d.x=h.ensureNumber(d.x||0);d.y=h.ensureNumber(d.y||0);d.z=d.hasZ?h.ensureNumber(d.z||0):d.z;return d};f.prototype.equals=function(a){return a?this.tilt===a.tilt&&this.heading===a.heading&&this.fov===a.fov&&this.position.equals(a.position):!1};f.prototype.clone=function(){return new e({position:this.position.clone(),heading:this.heading,tilt:this.tilt,fov:this.fov})};var e;d([l.property({type:a,json:{write:{isRequired:!0}}})],
f.prototype,"position",void 0);d([l.writer("position")],f.prototype,"writePosition",null);d([l.reader("position")],f.prototype,"readPosition",null);d([l.property({type:Number,nonNullable:!0,json:{write:{isRequired:!0}}}),l.cast(function(a){return c.cyclicalDeg.normalize(h.ensureNumber(a))})],f.prototype,"heading",void 0);d([l.property({type:Number,nonNullable:!0,json:{write:{isRequired:!0}}}),l.cast(function(a){return c.clamp(h.ensureNumber(a),-180,180)})],f.prototype,"tilt",void 0);d([l.property({type:Number,
nonNullable:!0,json:{read:!1,write:!1}})],f.prototype,"fov",void 0);return f=e=d([l.subclass("esri.Camera")],f)}(l.declared(k))})},"esri/views/3d/support/mathUtils":function(){define(["require","exports","../../../core/libs/gl-matrix-2/vec3","../../../core/libs/gl-matrix-2/vec3f64"],function(b,e,m,d){function k(a){return Math.asin(1<a?1:-1>a?-1:a)}function l(a){return Math.acos(1<a?1:-1>a?-1:a)}function h(a,c,b){return a<c?c:a>b?b:a}function a(a){for(var c in a){var b=a[c];b instanceof Function&&
(a[c]=b.bind(a))}return a}Object.defineProperty(e,"__esModule",{value:!0});e.deg2rad=function(a){return a*Math.PI/180};e.rad2deg=function(a){return 180*a/Math.PI};e.asin=k;e.acos=l;e.cosCapped=function(a,c){return a>c?Math.cos(c):Math.cos(a)};e.sign=Math.sign||function(a){return+(0<a)-+(0>a)||+a};e.log2=Math.log2||function(a){return Math.log(a)/Math.LN2};e.isPowerOfTwo=function(a){return 0===(a&a-1)};e.nextHighestPowerOfTen=function(a){return Math.pow(10,Math.ceil(Math.LOG10E*Math.log(a)))};e.fovx2fovy=
function(a,c,b){return 2*Math.atan(b*Math.tan(.5*a)/c)};e.fovy2fovx=function(a,c,b){return 2*Math.atan(c*Math.tan(.5*a)/b)};e.maxScale=function(a){return Math.max(Math.max(Math.sqrt(a[0]*a[0]+a[4]*a[4]+a[8]*a[8]),Math.sqrt(a[1]*a[1]+a[5]*a[5]+a[9]*a[9])),Math.sqrt(a[2]*a[2]+a[6]*a[6]+a[10]*a[10]))};e.scaleFromMatrix=function(a,c){m.vec3.set(a,Math.sqrt(c[0]*c[0]+c[4]*c[4]+c[8]*c[8]),Math.sqrt(c[1]*c[1]+c[5]*c[5]+c[9]*c[9]),Math.sqrt(c[2]*c[2]+c[6]*c[6]+c[10]*c[10]));return a};e.makeOrthonormal=function(a,
c,b){b=b||a;var d=m.vec3.dot(a,c);m.vec3.set(b,a[0]-d*c[0],a[1]-d*c[1],a[2]-d*c[2]);m.vec3.normalize(b,b)};e.tangentFrame=function(a,c,b){Math.abs(a[0])>Math.abs(a[1])?m.vec3.set(c,0,1,0):m.vec3.set(c,1,0,0);m.vec3.cross(b,a,c);m.vec3.normalize(c,c);m.vec3.cross(c,b,a);m.vec3.normalize(b,b)};e.moduloPositive=function(a,c){return(a%c+c)%c};e.cartesianToSpherical=function(a,c){var b=m.vec3.length(a),d=k(a[2]/b);m.vec3.set(c,b,d,Math.atan2(a[1]/b,a[0]/b));return c};e.sphericalToCartesian=function(a,
c){var b=a[0],d=a[1];a=a[2];var f=Math.cos(d);m.vec3.set(c,b*f*Math.cos(a),b*f*Math.sin(a),b*Math.sin(d))};e.directionFromTo=function(a,c,b){var d=b[0]-c[0],f=b[1]-c[1];c=b[2]-c[2];b=d*d+f*f+c*c;if(!b)return a[0]=0,a[1]=0,a[2]=0,a;b=1/Math.sqrt(b);a[0]=d*b;a[1]=f*b;a[2]=c*b;return a};e.lerp=function(a,c,b){return a+(c-a)*b};e.bilerp=function(a,c,b,d,f,e){a+=(c-a)*f;return a+(b+(d-b)*f-a)*e};e.slerp=function(a,c,b,f){void 0===f&&(f=d.vec3f64.create());var e=m.vec3.length(a),h=m.vec3.length(c),p=m.vec3.dot(a,
c)/(e*h);if(.9999999999999999>p){var p=Math.acos(p),n=((1-b)*e+b*h)/Math.sin(p),h=n/h*Math.sin(b*p);m.vec3.scale(g,a,n/e*Math.sin((1-b)*p));m.vec3.scale(q,c,h);return m.vec3.add(f,g,q)}return m.vec3.lerp(f,a,c,b)};e.angle=function(a,c,b){a=m.vec3.normalize(g,a);c=m.vec3.normalize(q,c);var d=l(m.vec3.dot(a,c));return b&&(a=m.vec3.cross(n,a,c),0>m.vec3.dot(a,b))?-d:d};e.clamp=h;e.makePiecewiseLinearFunction=function(a){var c=a.length;return function(b){if(b<=a[0][0])return a[0][1];if(b>=a[c-1][0])return a[c-
1][1];for(var d=1;b>a[d][0];)d++;var f=a[d][0];b=(f-b)/(f-a[d-1][0]);return b*a[d-1][1]+(1-b)*a[d][1]}};e.vectorEquals=function(a,c){if(null==a||null==c)return a!==c;if(a.length!==c.length)return!1;for(var b=0;b<a.length;b++)if(a[b]!==c[b])return!1;return!0};e.floatEqualRelative=function(a,c,b){void 0===b&&(b=1E-6);if(isNaN(a)||isNaN(c))return!1;if(a===c)return!0;var d=Math.abs(a-c),f=Math.abs(a),e=Math.abs(c);if(0===a||0===c||1E-12>f&&1E-12>e){if(d>.01*b)return!1}else if(d/(f+e)>b)return!1;return!0};
e.floatEqualAbsolute=function(a,c,b){void 0===b&&(b=1E-6);return isNaN(a)||isNaN(c)?!1:(a>c?a-c:c-a)<=b};b=function(){function a(a,c){this.min=a;this.max=c;this.range=c-a}a.prototype.ndiff=function(a,c){void 0===c&&(c=0);return Math.ceil((a-c)/this.range)*this.range+c};a.prototype._normalize=function(a,c,b,d){void 0===d&&(d=0);b-=d;b<a?b+=this.ndiff(a-b):b>c&&(b-=this.ndiff(b-c));return b+d};a.prototype.normalize=function(a,c){return this._normalize(this.min,this.max,a,c)};a.prototype.clamp=function(a,
c){void 0===c&&(c=0);return h(a-c,this.min,this.max)+c};a.prototype.monotonic=function(a,c,b){return a<c?c:c+this.ndiff(a-c,b)};a.prototype.minimalMonotonic=function(a,c,b){return this._normalize(a,a+this.range,c,b)};a.prototype.center=function(a,c,b){c=this.monotonic(a,c,b);return this.normalize((a+c)/2,b)};a.prototype.diff=function(a,c,b){return this.monotonic(a,c,b)-a};a.prototype.shortestSignedDiff=function(a,c){a=this.normalize(a);c=this.normalize(c);var b=c-a;a=c<a?this.minimalMonotonic(a,c)-
a:c-this.minimalMonotonic(c,a);return Math.abs(b)<Math.abs(a)?b:a};a.prototype.contains=function(a,c,b){c=this.minimalMonotonic(a,c);b=this.minimalMonotonic(a,b);return b>a&&b<c};return a}();e.Cyclical=b;e.planeFromPoints=function(a,b,d,e){m.vec3.subtract(c,b,a);m.vec3.subtract(f,d,a);m.vec3.cross(e,c,f);m.vec3.normalize(e,e);e[3]=-m.vec3.dot(a,e)};var c=d.vec3f64.create(),f=d.vec3f64.create();e.cyclical2PI=a(new b(0,2*Math.PI));e.cyclicalPI=a(new b(-Math.PI,Math.PI));e.cyclicalDeg=a(new b(0,360));
var n=d.vec3f64.create(),g=d.vec3f64.create(),q=d.vec3f64.create()})},"esri/core/libs/gl-matrix-2/vec3":function(){define(["require","exports","./math/vec3"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.vec3=m})},"esri/core/libs/gl-matrix-2/math/vec3":function(){define(["require","exports","../factories/vec3f64","./common"],function(b,e,m,d){function k(a){var c=a[0],b=a[1];a=a[2];return Math.sqrt(c*c+b*b+a*a)}function l(a,c){a[0]=c[0];a[1]=c[1];a[2]=c[2];return a}function h(a,
c,b){a[0]=c[0]-b[0];a[1]=c[1]-b[1];a[2]=c[2]-b[2];return a}function a(a,c,b){a[0]=c[0]*b[0];a[1]=c[1]*b[1];a[2]=c[2]*b[2];return a}function c(a,c,b){a[0]=c[0]/b[0];a[1]=c[1]/b[1];a[2]=c[2]/b[2];return a}function f(a,c){var b=c[0]-a[0],d=c[1]-a[1];a=c[2]-a[2];return Math.sqrt(b*b+d*d+a*a)}function n(a,c){var b=c[0]-a[0],d=c[1]-a[1];a=c[2]-a[2];return b*b+d*d+a*a}function g(a){var c=a[0],b=a[1];a=a[2];return c*c+b*b+a*a}function q(a,c){var b=c[0],d=c[1],f=c[2],b=b*b+d*d+f*f;0<b&&(b=1/Math.sqrt(b),a[0]=
c[0]*b,a[1]=c[1]*b,a[2]=c[2]*b);return a}function p(a,c){return a[0]*c[0]+a[1]*c[1]+a[2]*c[2]}Object.defineProperty(e,"__esModule",{value:!0});e.length=k;e.copy=l;e.set=function(a,c,b,d){a[0]=c;a[1]=b;a[2]=d;return a};e.add=function(a,c,b){a[0]=c[0]+b[0];a[1]=c[1]+b[1];a[2]=c[2]+b[2];return a};e.subtract=h;e.multiply=a;e.divide=c;e.ceil=function(a,c){a[0]=Math.ceil(c[0]);a[1]=Math.ceil(c[1]);a[2]=Math.ceil(c[2]);return a};e.floor=function(a,c){a[0]=Math.floor(c[0]);a[1]=Math.floor(c[1]);a[2]=Math.floor(c[2]);
return a};e.min=function(a,c,b){a[0]=Math.min(c[0],b[0]);a[1]=Math.min(c[1],b[1]);a[2]=Math.min(c[2],b[2]);return a};e.max=function(a,c,b){a[0]=Math.max(c[0],b[0]);a[1]=Math.max(c[1],b[1]);a[2]=Math.max(c[2],b[2]);return a};e.round=function(a,c){a[0]=Math.round(c[0]);a[1]=Math.round(c[1]);a[2]=Math.round(c[2]);return a};e.scale=function(a,c,b){a[0]=c[0]*b;a[1]=c[1]*b;a[2]=c[2]*b;return a};e.scaleAndAdd=function(a,c,b,d){a[0]=c[0]+b[0]*d;a[1]=c[1]+b[1]*d;a[2]=c[2]+b[2]*d;return a};e.distance=f;e.squaredDistance=
n;e.squaredLength=g;e.negate=function(a,c){a[0]=-c[0];a[1]=-c[1];a[2]=-c[2];return a};e.inverse=function(a,c){a[0]=1/c[0];a[1]=1/c[1];a[2]=1/c[2];return a};e.normalize=q;e.dot=p;e.cross=function(a,c,b){var d=c[0],f=c[1];c=c[2];var e=b[0],g=b[1];b=b[2];a[0]=f*b-c*g;a[1]=c*e-d*b;a[2]=d*g-f*e;return a};e.lerp=function(a,c,b,d){var f=c[0],e=c[1];c=c[2];a[0]=f+d*(b[0]-f);a[1]=e+d*(b[1]-e);a[2]=c+d*(b[2]-c);return a};e.hermite=function(a,c,b,d,f,e){var g=e*e,h=g*(2*e-3)+1,p=g*(e-2)+e,n=g*(e-1);e=g*(3-2*
e);a[0]=c[0]*h+b[0]*p+d[0]*n+f[0]*e;a[1]=c[1]*h+b[1]*p+d[1]*n+f[1]*e;a[2]=c[2]*h+b[2]*p+d[2]*n+f[2]*e;return a};e.bezier=function(a,c,b,d,f,e){var g=1-e,h=g*g,p=e*e,n=h*g,h=3*e*h,g=3*p*g;e*=p;a[0]=c[0]*n+b[0]*h+d[0]*g+f[0]*e;a[1]=c[1]*n+b[1]*h+d[1]*g+f[1]*e;a[2]=c[2]*n+b[2]*h+d[2]*g+f[2]*e;return a};e.random=function(a,c){c=c||1;var b=2*d.RANDOM()*Math.PI,f=2*d.RANDOM()-1,e=Math.sqrt(1-f*f)*c;a[0]=Math.cos(b)*e;a[1]=Math.sin(b)*e;a[2]=f*c;return a};e.transformMat4=function(a,c,b){var d=c[0],f=c[1];
c=c[2];a[0]=b[0]*d+b[4]*f+b[8]*c+b[12];a[1]=b[1]*d+b[5]*f+b[9]*c+b[13];a[2]=b[2]*d+b[6]*f+b[10]*c+b[14];return a};e.transformMat3=function(a,c,b){var d=c[0],f=c[1];c=c[2];a[0]=d*b[0]+f*b[3]+c*b[6];a[1]=d*b[1]+f*b[4]+c*b[7];a[2]=d*b[2]+f*b[5]+c*b[8];return a};e.transformQuat=function(a,c,b){var d=b[0],f=b[1],e=b[2],g=c[0],h=c[1];c=c[2];var p=f*c-e*h,n=e*g-d*c,l=d*h-f*g;b=2*b[3];a[0]=g+p*b+2*(f*l-e*n);a[1]=h+n*b+2*(e*p-d*l);a[2]=c+l*b+2*(d*n-f*p);return a};e.rotateX=function(a,c,b,d){var f=[],e=[];
f[0]=c[0]-b[0];f[1]=c[1]-b[1];f[2]=c[2]-b[2];e[0]=f[0];e[1]=f[1]*Math.cos(d)-f[2]*Math.sin(d);e[2]=f[1]*Math.sin(d)+f[2]*Math.cos(d);a[0]=e[0]+b[0];a[1]=e[1]+b[1];a[2]=e[2]+b[2];return a};e.rotateY=function(a,c,b,d){var f=[],e=[];f[0]=c[0]-b[0];f[1]=c[1]-b[1];f[2]=c[2]-b[2];e[0]=f[2]*Math.sin(d)+f[0]*Math.cos(d);e[1]=f[1];e[2]=f[2]*Math.cos(d)-f[0]*Math.sin(d);a[0]=e[0]+b[0];a[1]=e[1]+b[1];a[2]=e[2]+b[2];return a};e.rotateZ=function(a,c,b,d){var f=[],e=[];f[0]=c[0]-b[0];f[1]=c[1]-b[1];f[2]=c[2]-b[2];
e[0]=f[0]*Math.cos(d)-f[1]*Math.sin(d);e[1]=f[0]*Math.sin(d)+f[1]*Math.cos(d);e[2]=f[2];a[0]=e[0]+b[0];a[1]=e[1]+b[1];a[2]=e[2]+b[2];return a};e.angle=function(a,c){l(t,a);l(r,c);q(t,t);q(r,r);a=p(t,r);return 1<a?0:-1>a?Math.PI:Math.acos(a)};var t=m.create(),r=m.create();e.str=function(a){return"vec3("+a[0]+", "+a[1]+", "+a[2]+")"};e.exactEquals=function(a,c){return a[0]===c[0]&&a[1]===c[1]&&a[2]===c[2]};e.equals=function(a,c){var b=a[0],f=a[1];a=a[2];var e=c[0],g=c[1];c=c[2];return Math.abs(b-e)<=
d.EPSILON*Math.max(1,Math.abs(b),Math.abs(e))&&Math.abs(f-g)<=d.EPSILON*Math.max(1,Math.abs(f),Math.abs(g))&&Math.abs(a-c)<=d.EPSILON*Math.max(1,Math.abs(a),Math.abs(c))};e.sub=h;e.mul=a;e.div=c;e.dist=f;e.sqrDist=n;e.len=k;e.sqrLen=g})},"esri/core/libs/gl-matrix-2/math/common":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.EPSILON=1E-6;e.RANDOM=Math.random;var m=Math.PI/180,d=180/Math.PI;e.toRadian=function(b){return b*m};e.toDegree=function(b){return b*
d};e.equals=function(b,d){return Math.abs(b-d)<=e.EPSILON*Math.max(1,Math.abs(b),Math.abs(d))}})},"esri/layers/mixins/ArcGISMapService":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ../../geometry/Extent ../../geometry/SpatialReference ./ArcGISService ../support/commonProperties".split(" "),function(b,e,m,d,k,l,h,a,c){return function(a){function b(){var c=null!==a&&a.apply(this,arguments)||this;
c.capabilities=void 0;c.copyright=null;c.fullExtent=null;c.legendEnabled=!0;c.spatialReference=null;c.version=null;return c}m(b,a);b.prototype.readCapabilities=function(a,c){var b=c.capabilities&&c.capabilities.split(",").map(function(a){return a.toLowerCase().trim()});if(!b)return{operations:{supportsQuery:!1,supportsExportMap:!1,supportsExportTiles:!1,supportsTileMap:!1},exportMap:null,exportTiles:null};a=this.type;var d=-1!==b.indexOf("query"),f=-1!==b.indexOf("map"),e=!!c.exportTilesAllowed,b=
-1!==b.indexOf("tilemap"),g="tile"!==a&&!!c.supportsDynamicLayers,h="tile"!==a&&(!c.tileInfo||g),n="tile"!==a&&(!c.tileInfo||g);return{operations:{supportsQuery:d,supportsExportMap:f,supportsExportTiles:e,supportsTileMap:b},exportMap:f?{supportsSublayersChanges:"tile"!==a,supportsDynamicLayers:g,supportsSublayerVisibility:h,supportsSublayerDefinitionExpression:n}:null,exportTiles:e?{maxExportTilesCount:+c.maxExportTilesCount}:null}};b.prototype.readVersion=function(a,c){(a=c.currentVersion)||(a=c.hasOwnProperty("capabilities")||
c.hasOwnProperty("tables")?10:c.hasOwnProperty("supportedImageFormatTypes")?9.31:9.3);return a};d([k.property({readOnly:!0})],b.prototype,"capabilities",void 0);d([k.reader("service","capabilities",["capabilities","exportTilesAllowed","maxExportTilesCount","supportsDynamicLayers","tileInfo"])],b.prototype,"readCapabilities",null);d([k.property({json:{read:{source:"copyrightText"}}})],b.prototype,"copyright",void 0);d([k.property({type:l})],b.prototype,"fullExtent",void 0);d([k.property({json:{origins:{service:{read:!1},
"portal-item":{read:!1}}}})],b.prototype,"id",void 0);d([k.property({type:Boolean,json:{origins:{service:{read:{enabled:!1}}},read:{source:"showLegend"},write:{target:"showLegend"}}})],b.prototype,"legendEnabled",void 0);d([k.property(c.popupEnabled)],b.prototype,"popupEnabled",void 0);d([k.property({type:h})],b.prototype,"spatialReference",void 0);d([k.property()],b.prototype,"version",void 0);d([k.reader("version",["currentVersion","capabilities","tables","supportedImageFormatTypes"])],b.prototype,
"readVersion",null);return b=d([k.subclass("esri.layers.mixins.ArcGISMapService")],b)}(k.declared(a))})},"esri/layers/mixins/ArcGISService":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Logger ../../core/MultiOriginJSONSupport ../../core/accessorSupport/decorators ../support/arcgisLayerUrl".split(" "),function(b,e,m,d,k,l,h,a){var c=k.getLogger("esri.layers.mixins.ArcGISService");return function(b){function f(){return null!==
b&&b.apply(this,arguments)||this}m(f,b);Object.defineProperty(f.prototype,"title",{get:function(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){var c=a.parse(this.url);if(c&&c.title)return c.title}return this._get("title")||""},set:function(a){this._set("title",a)},enumerable:!0,configurable:!0});Object.defineProperty(f.prototype,"url",{set:function(b){this._set("url",a.sanitizeUrl(b,c))},enumerable:!0,configurable:!0});d([h.property({dependsOn:["url"]})],
f.prototype,"title",null);d([h.property({type:String})],f.prototype,"url",null);return f=d([h.subclass("esri.layers.mixins.ArcGISService")],f)}(h.declared(l))})},"esri/core/MultiOriginJSONSupport":function(){define("require exports ./tsSupport/declareExtendsHelper ./tsSupport/decorateHelper ./Accessor ./accessorSupport/decorators ./accessorSupport/MultiOriginStore ./accessorSupport/PropertyOrigin ./accessorSupport/read ./accessorSupport/utils ./accessorSupport/write".split(" "),function(b,e,m,d,k,
l,h,a,c,f,n){function g(a){return f.getProperties(a).store}return function(b){function e(){var c=b.call(this)||this,d=f.getProperties(c),e=d.metadatas,g=d.store,p=new h.default;d.store=p;g.keys().forEach(function(c){p.set(c,g.get(c),a.OriginId.DEFAULTS)});Object.keys(e).forEach(function(c){d.internalGet(c)&&p.set(c,d.internalGet(c),a.OriginId.DEFAULTS)});return c}m(e,b);e.prototype.clear=function(c,b){void 0===b&&(b="user");return g(this).clear(c,a.nameToId(b))};e.prototype.read=function(a,b){c.default(this,
a,b)};e.prototype.write=function(a,c){a=a||{};n.default(this,a,c);return a};e.prototype.getAtOrigin=function(c,b){var d=g(this),f=a.nameToId(b);if("string"===typeof c)return d.get(c,f);var e={};c.forEach(function(a){e[a]=d.get(a,f)});return e};e.prototype.originOf=function(c){var b=g(this);if("string"===typeof c)return a.idToName(b.originOf(c));c.forEach(function(c){a.idToName(b.originOf(c))})};e.prototype.revert=function(c,b){var d=g(this),e=a.nameToId(b),h=f.getProperties(this);("string"===typeof c?
"*"===c?Object.keys(d.getAll(e)):[c]:c).forEach(function(a){h.propertyInvalidated(a);d.revert(a,e);h.propertyCommitted(a)})};e.prototype.removeOrigin=function(c){var b=g(this);c=a.nameToId(c);var d=b.getAll(c),f;for(f in d)b.originOf(f)===c&&b.set(f,d[f],a.OriginId.USER)};e.prototype.updateOrigin=function(c,b){var d=g(this);b=a.nameToId(b);var f=this.get(c);d.clear(c);d.set(c,f,b)};return e=d([l.subclass("esri.core.MultiOriginJSONSupport")],e)}(l.declared(k))})},"esri/core/accessorSupport/MultiOriginStore":function(){define(["require",
"exports","./PropertyOrigin"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});b=function(){function b(){this._propertyOriginMap={};this._originStores=Array(m.OriginId.NUM);this._values={}}b.prototype.get=function(b,d){return(d=void 0===d?this._values:this._originStores[d])?d[b]:void 0};b.prototype.keys=function(){return Object.keys(this._values)};b.prototype.set=function(b,d,e){void 0===e&&(e=m.OriginId.USER);var a=this._originStores[e];a||(a={},this._originStores[e]=a);a[b]=d;return!(b in
this._values)||this._propertyOriginMap[b]<=e?(a=this._values[b],this._values[b]=d,this._propertyOriginMap[b]=e,a!==d):!1};b.prototype.clear=function(b,d){void 0===d&&(d=m.OriginId.USER);var e=this._originStores[d];if(e){var a=e[b];delete e[b];if(b in this._values&&this._propertyOriginMap[b]===d)for(delete this._values[b],--d;0<=d;d--)if((e=this._originStores[d])&&b in e){this._values[b]=e[b];this._propertyOriginMap[b]=d;break}return a}};b.prototype.has=function(b,d){return(d=void 0===d?this._values:
this._originStores[d])?b in d:!1};b.prototype.revert=function(b,d){for(;0<d&&!this.has(b,d);)--d;var e=this._originStores[d],e=e&&e[b],a=this._values[b];this._values[b]=e;this._propertyOriginMap[b]=d;return a!==e};b.prototype.originOf=function(b,d){return this._propertyOriginMap[b]||m.OriginId.DEFAULTS};b.prototype.getAll=function(b){return this._originStores[b]};return b}();e.default=b})},"esri/layers/support/arcgisLayerUrl":function(){define(["require","exports","../../core/urlUtils"],function(b,
e,m){function d(b){var d=m.urlToObject(b).path.match(e.match);if(!d)return null;b=d[1];var a=d[2],c=d[3],d=d[4],f=a.indexOf("/");return{title:k(-1!==f?a.slice(f+1):a),serverType:c,sublayer:null!=d&&""!==d?parseInt(d,10):null,url:{path:b}}}function k(b){b=b.replace(/\s*[/_]+\s*/g," ");return b[0].toUpperCase()+b.slice(1)}Object.defineProperty(e,"__esModule",{value:!0});e.serverTypes="MapServer ImageServer FeatureServer SceneServer StreamServer VectorTileServer".split(" ");e.match=new RegExp("^((?:https?:)?\\/\\/\\S+?\\/rest\\/services\\/(.+?)\\/("+
e.serverTypes.join("|")+"))(?:\\/(?:layers\\/)?(\\d+))?","i");e.test=function(b){return!!e.match.test(b)};e.parse=d;e.cleanTitle=k;e.titleFromUrlAndName=function(b,e){var a=[];b&&(b=d(b))&&b.title&&a.push(b.title);e&&(e=k(e),a.push(e));if(2===a.length){if(-1!==a[0].toLowerCase().indexOf(a[1].toLowerCase()))return a[0];if(-1!==a[1].toLowerCase().indexOf(a[0].toLowerCase()))return a[1]}return a.join(" - ")};e.isHostedAgolService=function(b){if(!b)return!1;b=b.toLowerCase();var d=-1!==b.indexOf(".arcgis.com/");
b=-1!==b.indexOf("//services")||-1!==b.indexOf("//tiles")||-1!==b.indexOf("//features");return d&&b};e.isHostedSecuredProxyService=function(b,d){return d&&b&&-1!==b.toLowerCase().indexOf(d.toLowerCase())};e.sanitizeUrl=function(b,d){return b?m.removeTrailingSlash(m.removeQueryParameters(b,d)):b};e.sanitizeUrlWithLayerId=function(b,e,a){if(!e)return{url:e};e=m.removeQueryParameters(e,a);a=m.urlToObject(e);a=d(a.path);var c;a&&null!=a.sublayer&&(null==b.layerId&&(c=a.sublayer),e=a.url.path);return{url:m.removeTrailingSlash(e),
layerId:c}};e.writeUrlWithLayerId=function(b,d,a,c,f){m.write(d,c,"url",f);c.url&&null!=b.layerId&&(c.url=m.join(c.url,a,b.layerId.toString()))};e.isWmsServer=function(b){if(!b)return!1;var d=b.toLowerCase();b=-1!==d.indexOf("/services/");var a=-1!==d.indexOf("/mapserver/wmsserver"),c=-1!==d.indexOf("/imageserver/wmsserver"),d=-1!==d.indexOf("/wmsserver");return b&&(a||c||d)}})},"esri/layers/support/commonProperties":function(){define("require exports ../../core/urlUtils ../../core/accessorSupport/PropertyOrigin ../../core/accessorSupport/utils ../../core/accessorSupport/write ../../symbols/support/ElevationInfo".split(" "),
function(b,e,m,d,k,l,h){Object.defineProperty(e,"__esModule",{value:!0});e.screenSizePerspectiveEnabled={type:Boolean,value:!0,json:{origins:{"web-scene":{read:{source:["id","url","layerType"],reader:function(a,c){if(null==c.screenSizePerspective&&"defaults"===this.originOf("screenSizePerspectiveEnabled"))k.getProperties(this).store.set("screenSizePerspectiveEnabled",!1,d.OriginId.DEFAULTS);else return c.screenSizePerspective}},write:{ignoreOrigin:!0,target:"screenSizePerspective",writer:function(a,
c,b,d){"defaults"===this.originOf("screenSizePerspectiveEnabled")&&a?c[b]=a:l.willPropertyWrite(this,"screenSizePerspectiveEnabled",{},d)&&(c[b]=a)}}}}}};e.popupEnabled={type:Boolean,value:!0,json:{read:{source:"disablePopup",reader:function(a,c){return!c.disablePopup}},write:{target:"disablePopup",writer:function(a,c,b){c[b]=!a}}}};e.labelsVisible={type:Boolean,json:{read:{source:"showLabels"},write:{target:"showLabels"}}};e.url={type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writer:m.write}}};
e.legendEnabled={type:Boolean,value:!0,json:{origins:{service:{read:{enabled:!1}}},read:{source:"showLegend"},write:{target:"showLegend"}}};e.elevationInfo={value:null,type:h,json:{origins:{service:{read:{source:"elevationInfo"},write:{target:"elevationInfo",enabled:!1}}},read:{source:"layerDefinition.elevationInfo"},write:{target:"layerDefinition.elevationInfo"}}};e.readOnlyService=function(a){return{type:a,readOnly:!0,json:{origins:{service:{read:!0}},read:!1}}}})},"esri/symbols/support/ElevationInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/tsSupport/generatorHelper ../../core/tsSupport/awaiterHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/accessorSupport/decorators ../../layers/support/fieldUtils ./unitConversionUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){var g=a.strict()({onTheGround:"on-the-ground",relativeToGround:"relative-to-ground",relativeToScene:"relative-to-scene",absoluteHeight:"absolute-height"}),q=new a.KebabDictionary({foot:"feet",kilometer:"kilometers",meter:"meters",mile:"miles","us-foot":"us-feet",yard:"yards"}),p=function(a){function b(){return null!==a&&a.apply(this,arguments)||this}m(b,a);e=b;b.prototype.collectRequiredFields=function(a,c){return l(this,void 0,void 0,function(){return k(this,function(b){return[2,
f.collectArcadeFieldNames(a,c,this.expression)]})})};b.prototype.clone=function(){return new e({expression:this.expression,title:this.title})};var e;d([c.property({type:String,json:{write:!0}})],b.prototype,"expression",void 0);d([c.property({type:String,json:{write:!0}})],b.prototype,"title",void 0);return b=e=d([c.subclass("esri.layers.support.FeatureExpressionInfo")],b)}(c.declared(h));return function(a){function b(){return null!==a&&a.apply(this,arguments)||this}m(b,a);f=b;b.prototype.readFeatureExpressionInfo=
function(a,c){if(null!=a)return a;if(c.featureExpression&&0===c.featureExpression.value)return{expression:"0"}};b.prototype.writeFeatureExpressionInfo=function(a,c,b,d){c[b]=a.write(null,d);"0"===a.expression&&(c.featureExpression={value:0})};Object.defineProperty(b.prototype,"mode",{get:function(){return this._isOverridden("mode")?this._get("mode"):null!=this.offset||this.featureExpressionInfo?"relative-to-ground":"on-the-ground"},set:function(a){this._override("mode",a)},enumerable:!0,configurable:!0});
Object.defineProperty(b.prototype,"unit",{set:function(a){this._set("unit",a)},enumerable:!0,configurable:!0});b.prototype.write=function(a,c){return this.offset||this.mode||this.featureExpressionInfo||this.unit?this.inherited(arguments):null};b.prototype.clone=function(){return new f({mode:this.mode,offset:this.offset,featureExpressionInfo:this.featureExpressionInfo?this.featureExpressionInfo.clone():void 0,unit:this.unit})};var f;d([c.property({type:p,json:{write:!0}})],b.prototype,"featureExpressionInfo",
void 0);d([c.reader("featureExpressionInfo",["featureExpressionInfo","featureExpression"])],b.prototype,"readFeatureExpressionInfo",null);d([c.writer("featureExpressionInfo",{featureExpressionInfo:{type:p},"featureExpression.value":{type:[0]}})],b.prototype,"writeFeatureExpressionInfo",null);d([c.property({type:g.apiValues,dependsOn:["offset","featureExpressionInfo"],nonNullable:!0,json:{type:g.jsonValues,read:g.read,write:{writer:g.write,isRequired:!0}}})],b.prototype,"mode",null);d([c.property({type:Number,
json:{write:!0}})],b.prototype,"offset",void 0);d([c.property({type:n.supportedUnits,json:{type:String,read:q.read,write:q.write}})],b.prototype,"unit",null);return b=f=d([c.subclass("esri.layers.support.ElevationInfo")],b)}(c.declared(h))})},"esri/layers/support/fieldUtils":function(){define("require exports ../../core/tsSupport/assignHelper ../../core/tsSupport/generatorHelper ../../core/tsSupport/awaiterHelper @dojo/framework/shim/array @dojo/framework/shim/Set ../../core/Error ../../core/object ../../core/promiseUtils ./domains".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){function g(a,b,d){if(a)for(var f=0;f<a.length;f++){var e=a[f],g=c.getDeepValue(e,b);(g=g&&"function"!==typeof g&&r(d,g))&&c.setDeepValue(e,g.name,b)}}function q(a,c){if(!a||!c)return[];I.clear();p(I,a,c);return l.from(I).sort()}function p(a,c,b){if(b)if(c&&c.length)if(l.includes(b,"*"))for(b=0;b<c.length;b++)a.add(c[b].name);else for(var d=0;d<b.length;d++)f=b[d],t(a,c,f);else if(l.includes(b,"*"))a.clear(),a.add("*");else for(c=0;c<b.length;c++){var f=b[c];a.add(f)}}
function t(a,c,b){c&&c.length?(c=r(c,b))&&a.add(c.name):"string"===typeof b&&a.add(b)}function r(a,c){if("string"!==typeof c)return null;if(null!=a){c=c.toLowerCase();for(var b=0;b<a.length;b++){var d=a[b];if(d&&d.name.toLowerCase()===c)return d}}return null}function v(a,c,e){return k(this,void 0,void 0,function(){var g,h,p,n,l;return d(this,function(d){switch(d.label){case 0:return e?[4,f.create(function(a){b(["../../support/arcadeUtils"],function(c){a(c)})})]:[2];case 1:g=d.sent();h=g.extractFieldNames(e);
p=0;for(n=h;p<n.length;p++)l=n[p],t(a,c,l);return[2]}})})}function u(a,b){return k(this,void 0,void 0,function(){var f,e;return d(this,function(d){if(!b)return[2];f=b.fields;return(e=c.getDeepValue("elevationInfo.featureExpressionInfo",b))?[2,e.collectRequiredFields(a,f)]:[2]})})}function z(a,c){return k(this,void 0,void 0,function(){var b,e;return d(this,function(d){switch(d.label){case 0:return b=c.labelingInfo,e=c.fields,b&&b.length?[4,f.all(b.map(function(c){return y(a,e,c)}))]:[2];case 1:return d.sent(),
[2]}})})}function y(a,c,b){return k(this,void 0,void 0,function(){var f,e,g,h,p;return d(this,function(d){switch(d.label){case 0:if(!b)return[2];f=b.getLabelExpression();e=b.where;return"arcade"!==f.type?[3,2]:[4,v(a,c,f.expression)];case 1:return d.sent(),[3,3];case 2:(g=f.expression.match(/{[^}]*}/g))&&g.forEach(function(b){t(a,c,b.slice(1,-1))}),d.label=3;case 3:return h=/['"]+/g,e&&(p=e.split(" "),3===p.length&&t(a,c,p[0].replace(h,"")),7===p.length&&(t(a,c,p[0].replace(h,"")),t(a,c,p[4].replace(h,
"")))),[2]}})})}function x(a){return"number"===typeof a&&!isNaN(a)&&isFinite(a)}function w(a){return null===a||x(a)}function A(a){return null===a||W(a)}function B(a){return null!=a&&"string"===typeof a}function F(a){return null===a||B(a)}function C(a){return!0}function E(a,c){var b;switch(a.type){case "date":case "integer":case "long":case "small-integer":case "esriFieldTypeDate":case "esriFieldTypeInteger":case "esriFieldTypeLong":case "esriFieldTypeSmallInteger":b=a.nullable?A:W;break;case "double":case "single":case "esriFieldTypeSingle":case "esriFieldTypeDouble":b=
a.nullable?w:x;break;case "string":case "esriFieldTypeString":b=a.nullable?F:B;break;default:b=C}return 1===arguments.length?b:b(c)}function G(a){return null!=a&&M.has(a.type)}function Q(a,c){return a.nullable&&null===c?null:G(a)&&!V(a.type,c)?U.OUT_OF_RANGE:E(a,c)?a.domain?n.validateDomainValue(a.domain,c):null:O.INVALID_TYPE}function V(a,c){return(a="string"===typeof a?R(a):a)?a.isInteger?W(c)&&c>=a.min&&c<=a.max:c>=a.min&&c<=a.max:!1}function R(a){switch(a){case "esriFieldTypeSmallInteger":case "small-integer":return e.smallIntegerRange;
case "esriFieldTypeInteger":case "integer":return e.integerRange;case "esriFieldTypeSingle":case "single":return e.singleRange;case "esriFieldTypeDouble":case "double":return e.doubleRange}}Object.defineProperty(e,"__esModule",{value:!0});e.rendererFields="field field2 field3 normalizationField rotationInfo.field proportionalSymbolInfo.field proportionalSymbolInfo.normalizationField colorInfo.field colorInfo.normalizationField".split(" ");e.visualVariableFields=["field","normalizationField"];e.fixRendererFields=
function(a,c){if(null!=a&&null!=c){var b=0;for(a=Array.isArray(a)?a:[a];b<a.length;b++){var d=a[b];g(e.rendererFields,d,c);if("visualVariables"in d&&d.visualVariables)for(var f=0,d=d.visualVariables;f<d.length;f++)g(e.visualVariableFields,d[f],c)}}};e.fixTimeInfoFields=function(a,c){if(null!=a&&null!=c)if("startField"in a){var b=r(c,a.startField);c=r(c,a.endField);a.startField=b&&b.name||null;a.endField=c&&c.name||null}else b=r(c,a.startTimeField),c=r(c,a.endTimeField),a.startTimeField=b&&b.name||
null,a.endTimeField=c&&c.name||null};var I=new h.default;e.fixFields=q;e.collectFields=p;e.collectField=t;e.unpackFieldNames=function(a,c){return c&&a?l.includes(c,"*")?a.map(function(a){return a.name}):c:[]};e.packFields=function(a,c,b){void 0===b&&(b=1);if(!c||!a)return[];if(l.includes(c,"*"))return["*"];c=q(a,c);return c.length/a.length>=b?["*"]:c};e.getField=r;e.hasField=function(a,c){if(!a||!c||"string"!==typeof c)return!1;c=c.toLowerCase();for(var b=0;b<a.length;b++){var d=a[b];if(d&&d.name.toLowerCase()===
c)return!0}return!1};e.collectArcadeFieldNames=v;e.getElevationFields=function(a){return k(this,void 0,void 0,function(){var c;return d(this,function(b){switch(b.label){case 0:if(!a)return[2,[]];c=new h.default;return[4,u(c,a)];case 1:return b.sent(),[2,l.from(c).sort()]}})})};e.collectElevationFields=u;e.collectFilterFields=function(c,e,g){return k(this,void 0,void 0,function(){var h,n;return d(this,function(d){switch(d.label){case 0:if(!e||!g||!(g.where&&"1\x3d1"!==g.where||g.timeExtent))return[2];
e.timeInfo&&g.timeExtent&&p(c,e.fields,[e.timeInfo.startField,e.timeInfo.endField]);return g.where?[4,f.create(function(a){b(["../../core/sql/WhereClause"],a)})]:[3,2];case 1:h=d.sent();n=h.create(g.where);if(!n.isStandardized())return[2,f.reject(new a("fieldUtils:collectFilterFields","Where clause is not standardized"))];p(c,e.fields,n.getFields());d.label=2;case 2:return[2]}})})};e.getTimeFields=function(a){return k(this,void 0,void 0,function(){var c;return d(this,function(b){return a?(c="timeInfo"in
a&&a.timeInfo)?[2,q(a.fields,[a.trackIdField,c.startField,c.endField])]:[2,[]]:[2,[]]})})};e.getFeatureEditFields=function(a){if(!a)return[];var c="editFieldsInfo"in a&&a.editFieldsInfo;return c?q(a.fields,[c&&c.creatorField,c&&c.creationDateField,c&&c.editorField,c&&c.editDateField]):[]};e.getFeatureGeometryFields=function(a){if(!a)return[];var c="geometryProperties"in a&&a.geometryProperties;return c?q(a.fields,[c&&c.shapeAreaFieldName,c&&c.shapeLengthFieldName]):[]};e.getLabelingFields=function(a){return k(this,
void 0,void 0,function(){var c;return d(this,function(b){switch(b.label){case 0:if(!a)return[2,[]];c=new h.default;return[4,z(c,a)];case 1:return b.sent(),[2,l.from(c).sort()]}})})};e.collectLabelingFields=z;e.getFieldDefaultValue=function(a){var c=a.defaultValue;if(void 0!==c&&E(a,c))return c;if(a.nullable)return null};var W=function(){return"isInteger"in Number?Number.isInteger:function(a){return"number"===typeof a&&isFinite(a)&&Math.floor(a)===a}}();e.isValueMatchingFieldType=E;e.numericTypes=
["integer","small-integer","single","double"];var M=new h.default(e.numericTypes.concat(["esriFieldTypeInteger","esriFieldTypeSmallInteger","esriFieldTypeSingle","esriFieldTypeDouble"]));e.isNumericField=G;e.isStringField=function(a){return null!=a&&("string"===a.type||"esriFieldTypeString"===a.type)};e.isDateField=function(a){return null!=a&&("date"===a.type||"esriFieldTypeDate"===a.type)};e.isValidFieldValue=function(a,c){return null===Q(a,c)};var U;(U=e.NumericRangeValidationError||(e.NumericRangeValidationError=
{})).OUT_OF_RANGE="numeric-range-validation-error::out-of-range";var O;(O=e.TypeValidationError||(e.TypeValidationError={})).INVALID_TYPE="type-validation-error::invalid-type";e.sanitizeNullFieldValue=function(a){return null==a||"number"===typeof a&&isNaN(a)?null:a};e.validateFieldValue=Q;e.isNumberInRange=V;e.getFieldRange=function(a){var c=n.getDomainRange(a.domain);if(c)return c;if(G(a))return R(a.type)};e.getNumericTypeForValue=function(a){if(!x(a))return null;if(W(a)){if(a>=e.smallIntegerRange.min&&
a<=e.smallIntegerRange.max)return"esriFieldTypeSmallInteger";if(a>=e.integerRange.min&&a<=e.integerRange.max)return"esriFieldTypeInteger"}return a>=e.singleRange.min&&a<=e.singleRange.max?"esriFieldTypeSingle":"esriFieldTypeDouble"};e.smallIntegerRange={min:-32768,max:32767,isInteger:!0};e.integerRange={min:-2147483648,max:2147483647,isInteger:!0};e.singleRange={min:-3.4E38,max:1.2E38,isInteger:!1};e.doubleRange={min:-Number.MAX_VALUE,max:Number.MAX_VALUE,isInteger:!1};e.validationErrorToString=function(a,
c,b){switch(a){case n.DomainValidationError.INVALID_CODED_VALUE:return"Value "+b+" is not in the coded domain - field: "+c.name+", domain: "+JSON.stringify(c.domain);case n.DomainValidationError.VALUE_OUT_OF_RANGE:return"Value "+b+" is out of the range of valid values - field: "+c.name+", domain: "+JSON.stringify(c.domain);case O.INVALID_TYPE:return"Value "+b+" is not a valid value for the field type - field: "+c.name+", type: "+c.type+", nullable: "+c.nullable;case U.OUT_OF_RANGE:return a=R(c.type),
"Value "+b+" is out of range for the number type - field: "+c.name+", type: "+c.type+", value range is "+a.min+" to "+a.max}};e.featureHasFields=function(a,c){if(!c||!c.attributes||!a)return!1;c=c.attributes;for(var b=0;b<a.length;b++)if(!(a[b]in c))return!1;return!0}})},"@dojo/framework/shim/Set":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define("require exports tslib ./global ./iterator ../has/has ./Symbol".split(" "),
b)})(function(b,e){Object.defineProperty(e,"__esModule",{value:!0});var m=b("tslib"),d=b("./global"),k=b("./iterator"),l=b("../has/has");b("./Symbol");e.Set=d.default.Set;l.default("es6-set")||(e.Set=(h=function(){function a(a){this._setData=[];this[Symbol.toStringTag]="Set";if(a)if(k.isArrayLike(a))for(var c=0;c<a.length;c++)this.add(a[c]);else try{for(var c=m.__values(a),b=c.next();!b.done;b=c.next())this.add(b.value)}catch(p){d={error:p}}finally{try{b&&!b.done&&(e=c.return)&&e.call(c)}finally{if(d)throw d.error;
}}var d,e}a.prototype.add=function(a){if(this.has(a))return this;this._setData.push(a);return this};a.prototype.clear=function(){this._setData.length=0};a.prototype.delete=function(a){a=this._setData.indexOf(a);if(-1===a)return!1;this._setData.splice(a,1);return!0};a.prototype.entries=function(){return new k.ShimIterator(this._setData.map(function(a){return[a,a]}))};a.prototype.forEach=function(a,b){for(var c=this.values(),d=c.next();!d.done;)a.call(b,d.value,d.value,this),d=c.next()};a.prototype.has=
function(a){return-1<this._setData.indexOf(a)};a.prototype.keys=function(){return new k.ShimIterator(this._setData)};Object.defineProperty(a.prototype,"size",{get:function(){return this._setData.length},enumerable:!0,configurable:!0});a.prototype.values=function(){return new k.ShimIterator(this._setData)};a.prototype[Symbol.iterator]=function(){return new k.ShimIterator(this._setData)};return a}(),h[Symbol.species]=h,h));e.default=e.Set;var h})},"esri/layers/support/domains":function(){define("require exports ./CodedValueDomain ./Domain ./InheritedDomain ./RangeDomain".split(" "),
function(b,e,m,d,k,l){function h(c,b){switch(c.type){case "range":var d="range"in c?c.range[1]:c.maxValue;if(+b<("range"in c?c.range[0]:c.minValue)||+b>d)return a.VALUE_OUT_OF_RANGE;break;case "coded-value":case "codedValue":if(null==c.codedValues||c.codedValues.every(function(a){return null==a||a.code!==b}))return a.INVALID_CODED_VALUE}return null}Object.defineProperty(e,"__esModule",{value:!0});e.CodedValueDomain=m;e.DomainBase=d;e.InheritedDomain=k;e.RangeDomain=l;var a;(function(a){a.VALUE_OUT_OF_RANGE=
"domain-validation-error::value-out-of-range";a.INVALID_CODED_VALUE="domain-validation-error::invalid-coded-value"})(a=e.DomainValidationError||(e.DomainValidationError={}));e.isValidDomainValue=function(a,b){return null===h(a,b)};e.validateDomainValue=h;e.types={key:"type",base:e.DomainBase,typeMap:{range:e.RangeDomain,"coded-value":e.CodedValueDomain}};e.getDomainRange=function(a){if(a&&"range"===a.type)return{min:"range"in a?a.range[0]:a.minValue,max:"range"in a?a.range[1]:a.maxValue}};e.fromJSON=
function(a){return a&&a.type?"range"===a.type?e.RangeDomain.fromJSON(a):"codedValue"===a.type?e.CodedValueDomain.fromJSON(a):null:null}})},"esri/layers/support/CodedValueDomain":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/lang ../../core/accessorSupport/decorators ./Domain".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this,c)||this;c.codedValues=null;c.type="coded-value";return c}m(c,a);
b=c;c.prototype.writeCodedValues=function(a,c){var b=null;a&&(b=a.map(function(a){return k.fixJson(k.clone(a))}));c.codedValues=b};c.prototype.getName=function(a){var c=null;if(this.codedValues){var b=String(a);this.codedValues.some(function(a){String(a.code)===b&&(c=a.name);return!!c})}return c};c.prototype.clone=function(){return new b({codedValues:k.clone(this.codedValues),name:this.name})};var b;d([l.property({json:{write:!0}})],c.prototype,"codedValues",void 0);d([l.writer("codedValues")],c.prototype,
"writeCodedValues",null);d([l.enumeration.serializable()({codedValue:"coded-value"})],c.prototype,"type",void 0);return c=b=d([l.subclass("esri.layers.support.CodedValueDomain")],c)}(l.declared(h))})},"esri/layers/support/Domain":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h){var a=new l.default({inherited:"inherited",
codedValue:"coded-value",range:"range"});return function(c){function b(a){a=c.call(this,a)||this;a.name=null;a.type=null;return a}m(b,c);d([h.property({json:{write:!0}})],b.prototype,"name",void 0);d([h.property({json:{read:a.read,write:a.write}})],b.prototype,"type",void 0);return b=d([h.subclass("esri.layers.support.Domain")],b)}(h.declared(k))})},"esri/layers/support/InheritedDomain":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./Domain".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this,a)||this;a.type="inherited";return a}m(a,b);c=a;a.prototype.clone=function(){return new c};var c;d([k.enumeration.serializable()({inherited:"inherited"})],a.prototype,"type",void 0);return a=c=d([k.subclass("esri.layers.support.InheritedDomain")],a)}(k.declared(l))})},"esri/layers/support/RangeDomain":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./Domain".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this,a)||this;a.maxValue=null;a.minValue=null;a.type="range";return a}m(a,b);c=a;a.prototype.clone=function(){return new c({maxValue:this.maxValue,minValue:this.minValue,name:this.name})};var c;d([k.property({json:{read:{source:"range",reader:function(a,c){return c.range&&c.range[1]}},write:{target:"range",writer:function(a,c,b){c[b]=[this.minValue,a]}}}})],a.prototype,"maxValue",void 0);d([k.property({json:{read:{source:"range",reader:function(a,
c){return c.range&&c.range[0]}},write:{target:"range",writer:function(a,c,b){c[b]=[a,this.maxValue]}}}})],a.prototype,"minValue",void 0);d([k.enumeration.serializable()({range:"range"})],a.prototype,"type",void 0);return a=c=d([k.subclass("esri.layers.support.RangeDomain")],a)}(k.declared(l))})},"esri/symbols/support/unitConversionUtils":function(){define(["require","exports","../../renderers/support/utils"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.supportsUnit=function(b){return null!=
m.meterIn[b]};e.getMetersPerUnit=function(b){return 1/(m.meterIn[b]||1)};e.supportedUnits=function(){var b=Object.keys(m.meterIn);b.sort();return b}()})},"esri/renderers/support/utils":function(){define("dojo/date/locale ../../Color ../../core/lang ../../core/numberUtils ../../core/unitUtils dojo/i18n!dojo/cldr/nls/gregorian".split(" "),function(b,e,m,d,k,l){function h(a,b,d){var f="";0===b?f=c.lt+" ":b===d&&(f=c.gt+" ");return f+a}var a={},c={lte:"\x3c\x3d",gte:"\x3e\x3d",lt:"\x3c",gt:"\x3e",pct:"%",
ld:"\u2013"},f={millisecond:0,second:1,minute:2,hour:3,day:4,month:5,year:6},n={millisecond:{dateOptions:{formatLength:"long"},timeOptions:{formatLength:"medium"}},second:{dateOptions:{formatLength:"long"},timeOptions:{formatLength:"medium"}},minute:{dateOptions:{formatLength:"long"},timeOptions:{formatLength:"short"}},hour:{dateOptions:{formatLength:"long"},timeOptions:{formatLength:"short"}},day:{selector:"date",dateOptions:{formatLength:"long"}},month:{selector:"date",dateOptions:{formatLength:"long"}},
year:{selector:"date",dateOptions:{selector:"year"}}},g={formatLength:"short",fullYear:!0},q={formatLength:"short"};m.mixin(a,{meterIn:{inches:k.convertUnit(1,"meters","inches"),feet:k.convertUnit(1,"meters","feet"),"us-feet":k.convertUnit(1,"meters","us-feet"),yards:k.convertUnit(1,"meters","yards"),miles:k.convertUnit(1,"meters","miles"),"nautical-miles":k.convertUnit(1,"meters","nautical-miles"),millimeters:k.convertUnit(1,"meters","millimeters"),centimeters:k.convertUnit(1,"meters","centimeters"),
decimeters:k.convertUnit(1,"meters","decimeters"),meters:k.convertUnit(1,"meters","meters"),kilometers:k.convertUnit(1,"meters","kilometers"),"decimal-degrees":1/k.lengthToDegrees(1,"meters")},timelineDateFormatOptions:{selector:"date",dateOptions:{formatLength:"short",fullYear:!0}},formatDate:function(a,c){var d=[];null==a||a instanceof Date||(a=new Date(a));c=c||{};c=m.mixin({},c);var f=c.selector?c.selector.toLowerCase():null,e=!f||-1<f.indexOf("time"),f=!f||-1<f.indexOf("date");e&&(c.timeOptions=
c.timeOptions||q,c.timeOptions&&(c.timeOptions=m.mixin({},c.timeOptions),c.timeOptions.selector=c.timeOptions.selector||"time",d.push(c.timeOptions)));f&&(c.dateOptions=c.dateOptions||g,c.dateOptions&&(c.dateOptions=m.mixin({},c.dateOptions),c.dateOptions.selector=c.dateOptions.selector||"date",d.push(c.dateOptions)));d&&d.length?(d=d.map(function(c){return b.format(a,c)}),c=1==d.length?d[0]:l["dateTimeFormat-medium"].replace(/\'/g,"").replace(/\{(\d+)\}/g,function(a,c){return d[c]})):c=b.format(a);
return c},createColorStops:function(c){var b=c.values,f=c.colors,e=c.labelIndexes,g=c.isDate,p=c.dateFormatOptions;c=[];return c=b.map(function(c,n){var l=null;if(!e||-1<e.indexOf(n)){var k;(k=g?a.formatDate(c,p):d.format(c))&&(l=h(k,n,b.length-1))}return{value:c,color:f[n],label:l}})},updateColorStops:function(c){var b=c.stops,f=c.changes,e=c.isDate,g=c.dateFormatOptions,p=[],n,l=b.map(function(a){return a.value});f.forEach(function(a){p.push(a.index);l[a.index]=a.value});n=d.round(l,{indexes:p});
b.forEach(function(c,f){c.value=l[f];if(null!=c.label){var p,k=null;(p=e?a.formatDate(n[f],g):d.format(n[f]))&&(k=h(p,f,b.length-1));c.label=k}})},createClassBreakLabel:function(a){var b=a.minValue,f=a.maxValue,e=a.isFirstBreak?"":c.gt+" ";a="percent-of-total"===a.normalizationType?c.pct:"";b=null==b?"":d.format(b);f=null==f?"":d.format(f);return e+b+a+" "+c.ld+" "+f+a},setLabelsForClassBreaks:function(c){var b=c.classBreakInfos,f=c.classificationMethod,e=c.normalizationType,g=[];b&&b.length&&("standard-deviation"===
f?console.log("setLabelsForClassBreaks: cannot set labels for class breaks generated using 'standard-deviation' method."):c.round?(g.push(b[0].minValue),b.forEach(function(a){g.push(a.maxValue)}),g=d.round(g),b.forEach(function(c,b){c.label=a.createClassBreakLabel({minValue:0===b?g[0]:g[b],maxValue:g[b+1],isFirstBreak:0===b,normalizationType:e})})):b.forEach(function(c,b){c.label=a.createClassBreakLabel({minValue:c.minValue,maxValue:c.maxValue,isFirstBreak:0===b,normalizationType:e})}))},updateClassBreak:function(c){var b=
c.classBreaks,d=c.normalizationType,f=c.change,e=f.index,f=f.value,g=-1,h=-1,p=b.length;"standard-deviation"===c.classificationMethod?console.log("updateClassBreak: cannot update labels for class breaks generated using 'standard-deviation' method."):(0===e?g=e:e===p?h=e-1:(h=e-1,g=e),-1<g&&g<p&&(c=b[g],c.minValue=f,c.label=a.createClassBreakLabel({minValue:c.minValue,maxValue:c.maxValue,isFirstBreak:0===g,normalizationType:d})),-1<h&&h<p&&(c=b[h],c.maxValue=f,c.label=a.createClassBreakLabel({minValue:c.minValue,
maxValue:c.maxValue,isFirstBreak:0===h,normalizationType:d})))},calculateDateFormatInterval:function(a){var c,b,d=a.length,e,g,h,p,n,l,k=Infinity,q;a=a.map(function(a){return new Date(a)});for(c=0;c<d-1;c++){e=a[c];h=[];n=Infinity;l="";for(b=c+1;b<d;b++)g=a[b],g=e.getFullYear()!==g.getFullYear()&&"year"||e.getMonth()!==g.getMonth()&&"month"||e.getDate()!==g.getDate()&&"day"||e.getHours()!==g.getHours()&&"hour"||e.getMinutes()!==g.getMinutes()&&"minute"||e.getSeconds()!==g.getSeconds()&&"second"||
"millisecond",p=f[g],p<n&&(n=p,l=g),h.push(g);n<k&&(k=n,q=l)}return q},createUniqueValueLabel:function(c){var b=c.value,f=c.fieldInfo,e=c.domain;c=c.dateFormatInterval;var g=String(b);(e=e&&e.codedValues?e.getName(b):null)?g=e:"number"===typeof b&&(g=f&&"date"===f.type?a.formatDate(b,c&&n[c]):d.format(b));return g}});return a})},"esri/core/numberUtils":function(){define(["dojo/number","dojo/i18n!dojo/cldr/nls/number"],function(b,e){function m(a,c){return a-c}var d=/^-?(\d+)(\.(\d+))?$/i,k=new RegExp("\\"+
e.decimal+"0+$","g"),l=/(\d)0*$/g,h={numDigits:function(a){var c=String(a),b=c.match(d);a={integer:0,fractional:0};b&&b[1]?(a.integer=b[1].split("").length,a.fractional=b[3]?b[3].split("").length:0):-1<c.toLowerCase().indexOf("e")&&(b=c.split("e"),c=b[0],b=b[1],c&&b&&(c=Number(c),b=Number(b),(a=0<b)||(b=Math.abs(b)),c=h.numDigits(c),a?(c.integer+=b,c.fractional=b>c.fractional?0:c.fractional-b):(c.fractional+=b,c.integer=b>c.integer?1:c.integer-b),a=c));return a},percentChange:function(a,c,b,d){var f=
{previous:null,next:null},e;null!=b&&(e=a-b,f.previous=Math.floor(Math.abs(100*(c-b-e)/e)));null!=d&&(e=d-a,f.next=Math.floor(Math.abs(100*(d-c-e)/e)));return f},round:function(a,c){a=a.slice(0);var b,d,e,l,p,k,r,v,u=c&&null!=c.tolerance?c.tolerance:2,z=c&&c.indexes,y=c&&null!=c.strictBounds?c.strictBounds:!1;if(z)z.sort(m);else for(z=[],p=0;p<a.length;p++)z.push(p);for(p=0;p<z.length;p++)if(v=z[p],c=a[v],b=0===v?null:a[v-1],d=v===a.length-1?null:a[v+1],e=h.numDigits(c),e=e.fractional){k=0;for(r=
!1;k<=e&&!r;){l=c;r=k;var x=void 0,w=void 0,x=Number(l.toFixed(r));x<l?w=x+1/Math.pow(10,r):(w=x,x-=1/Math.pow(10,r));x=Number(x.toFixed(r));w=Number(w.toFixed(r));l=[x,w];l=y&&0===p?l[1]:l[0];r=u;var x=h.percentChange(c,l,b,d),A=w=void 0,w=void 0,w=null==x.previous||x.previous<=r,A=null==x.next||x.next<=r;r=w=w&&A||x.previous+x.next<=2*r;k++}r&&(a[v]=l)}return a},format:function(a,c){c=c||{places:20,round:-1};(a=b.format(a,c))&&(a=a.replace(l,"$1").replace(k,""));return a}};return h})},"esri/core/unitUtils":function(){define("require exports ./compilerUtils ./kebabDictionary ./wgs84Constants ../geometry/support/WKIDUnitConversion".split(" "),
function(b,e,m,d,k,l){function h(a){if(a=z[a])return a;throw Error("unknown measure");}function a(a){return u[a].baseUnit}function c(a,c){void 0===c&&(c=null);c=c||h(a);return u[c].baseUnit===a}function f(a,b,d){if(b===d)return a;var f=h(b);if(f!==h(d))throw Error("incompatible units");a=c(b,f)?a:a*u[f].units[b].inBaseUnits;return c(d,f)?a:a/u[f].units[d].inBaseUnits}function n(a){return v.fromJSON(a.toLowerCase())||null}function g(a){return q(a)||e.decDegToMeters}function q(a){var c,b,d;null!=a&&
("object"===typeof a?(c=a.wkid,b=a.wkt):"number"===typeof a?c=a:"string"===typeof a&&(b=a));c?d=r.values[r[c]]:b&&-1!==b.search(/^PROJCS/i)&&(a=t.exec(b))&&a[1]&&(d=parseFloat(a[1].split(",")[1]));return d}function p(a){var c,b,d;null!=a&&("object"===typeof a?(c=a.wkid,b=a.wkt):"number"===typeof a?c=a:"string"===typeof a&&(b=a));c?d=r.units[r[c]]:b&&-1!==b.search(/^PROJCS/i)&&(a=t.exec(b))&&a[1]&&(d=(a=/[\\"\\']{1}([^\\"\\']+)/.exec(a[1]))&&a[1]);return d?n(d):null}Object.defineProperty(e,"__esModule",
{value:!0});e.inchesPerMeter=39.37;e.decDegToMeters=k.wgs84Radius*Math.PI/180;var t=/UNIT\[([^\]]+)\]\]$/i,r=l,v=d.strict()({meter:"meters",foot:"feet",foot_us:"us-feet",foot_clarke:"clarke-feet",yard_clarke:"clarke-yards",link_clarke:"clarke-links",yard_sears:"sears-yards",foot_sears:"sears-feet",chain_sears:"sears-chains",chain_benoit_1895_b:"benoit-1895-b-chains",yard_indian:"indian-yards",yard_indian_1937:"indian-1937-yards",foot_gold_coast:"gold-coast-feet",chain_sears_1922_truncated:"sears-1922-truncated-chains",
"50_kilometers":"50-kilometers","150_kilometers":"150-kilometers"});b={millimeters:{inBaseUnits:.001},centimeters:{inBaseUnits:.01},decimeters:{inBaseUnits:.1},meters:{inBaseUnits:1},kilometers:{inBaseUnits:1E3},inches:{inBaseUnits:.0254},feet:{inBaseUnits:.3048},yards:{inBaseUnits:.9144},miles:{inBaseUnits:1609.344},"nautical-miles":{inBaseUnits:1852},"us-feet":{inBaseUnits:1200/3937}};d={"square-millimeters":{inBaseUnits:1E-6},"square-centimeters":{inBaseUnits:1E-4},"square-decimeters":{inBaseUnits:.1*
.1},"square-meters":{inBaseUnits:1},"square-kilometers":{inBaseUnits:1E6},"square-inches":{inBaseUnits:6.4516E-4},"square-feet":{inBaseUnits:.09290304},"square-yards":{inBaseUnits:.83612736},"square-miles":{inBaseUnits:2589988.110336},"square-us-feet":{inBaseUnits:function(a){return a*a}(1200/3937)},acres:{inBaseUnits:4046.8564224},ares:{inBaseUnits:100},hectares:{inBaseUnits:1E4}};var u={length:{baseUnit:"meters",units:b},area:{baseUnit:"square-meters",units:d},volume:{baseUnit:"liters",units:{liters:{inBaseUnits:1},
"cubic-millimeters":{inBaseUnits:1E3*1E-9},"cubic-centimeters":{inBaseUnits:.001},"cubic-decimeters":{inBaseUnits:1},"cubic-meters":{inBaseUnits:1E3},"cubic-kilometers":{inBaseUnits:1E12},"cubic-inches":{inBaseUnits:.016387064},"cubic-feet":{inBaseUnits:.09290304*304.8},"cubic-yards":{inBaseUnits:764.554857984},"cubic-miles":{inBaseUnits:4.16818182544058E12}}},angle:{baseUnit:"radians",units:{radians:{inBaseUnits:1},degrees:{inBaseUnits:Math.PI/180}}}},z=function(){var a={},c;for(c in u)for(var b in u[c].units)a[b]=
c;return a}();e.measureForUnit=h;e.baseUnitForMeasure=a;e.baseUnitForUnit=function(c){return a(h(c))};e.isBaseUnit=c;e.convertUnit=f;e.preferredMetricLengthUnit=function(a,c){return 3E3>f(a,c,"meters")?"meters":"kilometers"};e.preferredMetricVerticalLengthUnit=function(a,c){return 1E5>f(a,c,"meters")?"meters":"kilometers"};e.preferredImperialLengthUnit=function(a,c){return 1E3>f(a,c,"feet")?"feet":"miles"};e.preferredImperialVerticalLengthUnit=function(a,c){return 1E5>f(a,c,"feet")?"feet":"miles"};
e.preferredMetricAreaUnit=function(a,c){return 3E6>f(a,c,"square-meters")?"square-meters":"square-kilometers"};e.preferredImperialAreaUnit=function(a,c){return 1E6>f(a,c,"square-feet")?"square-feet":"square-miles"};e.lengthToDegrees=function(a,c,b){void 0===b&&(b=k.wgs84Radius);return f(a,c,"meters")/(b*Math.PI/180)};e.unitFromRESTJSON=n;e.unitToRESTJSON=function(a){return v.toJSON(a)||null};e.getMetersPerVerticalUnitForSR=function(a){a=g(a);return 1E5<a?1:a};e.getVerticalUnitStringForSR=function(a){return 1E5<
g(a)?"meters":p(a)};e.getMetersPerUnitForSR=g;e.getMetersPerUnit=q;e.getUnitString=p;e.getDefaultUnitSystem=function(a){if(!a)return null;a=p(a);switch(a){case "feet":case "us-feet":case "clarke-feet":case "clarke-yards":case "clarke-links":case "sears-yards":case "sears-feet":case "sears-chains":case "benoit-1895-b-chains":case "indian-yards":case "indian-1937-yards":case "gold-coast-feet":case "sears-1922-truncated-chains":return"imperial";case "50-kilometers":case "150-kilometers":case "meters":return"metric";
case null:case void 0:break;default:m.neverReached(a)}return null}})},"esri/layers/mixins/OperationalLayer":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/Error ../../core/MultiOriginJSONSupport ../../core/promiseUtils ../../core/accessorSupport/decorators ../../core/accessorSupport/read ../../core/accessorSupport/write ../../webdoc/support/opacityUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){e=
function(a){function b(){var c=null!==a&&a.apply(this,arguments)||this;c.title="Layer";return c}m(b,a);e=b;b.prototype.writeListMode=function(a,c,b,d){d&&"ground"===d.layerContainerType?c[b]=a:a&&n.willPropertyWrite(this,b,{},d)&&(c[b]=a)};b.prototype.writeTitle=function(a,c){c.title=a||"Layer"};b.prototype.writeOperationalLayerType=function(a,c){a&&(c.layerType=a)};b.prototype.readOpacity=function(a,c,b){if(void 0!==c.opacity&&(!b||"web-map"===b.origin||"web-scene"===b.origin))return c.opacity;if((!b||
"service"===b.origin)&&c.drawingInfo&&void 0!==c.drawingInfo.transparency)return g.transparencyToOpacity(c.drawingInfo.transparency);if(c.layerDefinition&&c.layerDefinition.drawingInfo&&void 0!==c.layerDefinition.drawingInfo.transparency)return g.transparencyToOpacity(c.layerDefinition.drawingInfo.transparency)};b.prototype.read=function(a,c){var b=this,d=arguments;c&&(c.layer=this);f.readLoadable(this,a,function(c){return b.inherited(d,[a,c])},c)};b.prototype.write=function(a,c){if(c&&c.origin){var b=
c.origin+"/"+(c.layerContainerType||"operational-layers"),d=e.supportedTypes[b],d=d&&d[this.operationalLayerType];if("write"!==d&&"readwrite"!==d)return c.messages&&c.messages.push(new l("layer:unsupported","Layers ("+this.title+", "+this.id+") of type '"+this.declaredClass+"' are not supported in the context of '"+b+"'",{layer:this})),null}b=this.inherited(arguments,[a,c]);d=!!c&&!!c.messages&&!!c.messages.filter(function(a){return a instanceof l&&"web-document-write:property-required"===a.name}).length;
return!this.url&&d?null:b};var e;d([c.property({type:String,json:{write:{ignoreOrigin:!0},origins:{"web-scene":{write:{isRequired:!0,ignoreOrigin:!0}}}}})],b.prototype,"id",void 0);d([c.property({json:{write:{ignoreOrigin:!0}}})],b.prototype,"listMode",void 0);d([c.writer("listMode")],b.prototype,"writeListMode",null);d([c.property({type:String,json:{write:{ignoreOrigin:!0,allowNull:!0},origins:{"web-scene":{write:{isRequired:!0,ignoreOrigin:!0}}}}})],b.prototype,"title",void 0);d([c.writer("title")],
b.prototype,"writeTitle",null);d([c.property({type:String,readOnly:!0,json:{write:{target:"layerType",ignoreOrigin:!0}}})],b.prototype,"operationalLayerType",void 0);d([c.writer("operationalLayerType")],b.prototype,"writeOperationalLayerType",null);d([c.property({type:Number,json:{origins:{"web-document":{default:1,write:!0}}}})],b.prototype,"opacity",void 0);d([c.reader("opacity",["opacity","layerDefinition.drawingInfo.transparency","drawingInfo.transparency"])],b.prototype,"readOpacity",null);d([c.property({type:Boolean,
json:{read:{source:"visibility"},write:{target:"visibility"},origins:{"web-document":{read:{source:"visibility"},write:{target:"visibility"},default:!0}}}})],b.prototype,"visible",void 0);return b=e=d([c.subclass("esri.layers.mixins.OperationalLayer")],b)}(c.declared(k,h));(function(c){c.typeModuleMap={ArcGISFeatureLayer:function(){return a.create(function(a){return b(["../FeatureLayer"],a)})},ArcGISImageServiceLayer:function(){return a.create(function(a){return b(["../ImageryLayer"],a)})},ArcGISImageServiceVectorLayer:function(){return a.resolve(null)},
ArcGISMapServiceLayer:function(){return a.create(function(a){return b(["../MapImageLayer"],a)})},ArcGISSceneServiceLayer:function(){return a.create(function(a){return b(["../SceneLayer"],a)})},ArcGISStreamLayer:function(){return a.create(function(a){return b(["../StreamLayer"],a)})},ArcGISTiledElevationServiceLayer:function(){return a.create(function(a){return b(["../ElevationLayer"],a)})},ArcGISTiledImageServiceLayer:function(){return a.create(function(a){return b(["../TileLayer"],a)})},ArcGISTiledMapServiceLayer:function(){return a.create(function(a){return b(["../TileLayer"],
a)})},BingMapsAerial:function(){return a.create(function(a){return b(["../BingMapsLayer"],a)})},BingMapsRoad:function(){return a.create(function(a){return b(["../BingMapsLayer"],a)})},BingMapsHybrid:function(){return a.create(function(a){return b(["../BingMapsLayer"],a)})},BuildingSceneLayer:function(){return a.create(function(a){return b(["../BuildingSceneLayer"],a)})},CSV:function(){return a.create(function(a){return b(["../CSVLayer"],a)})},GeoRSS:function(){return a.create(function(a){return b(["../GeoRSSLayer"],
a)})},GroupLayer:function(){return a.create(function(a){return b(["../GroupLayer"],a)})},IntegratedMeshLayer:function(){return a.create(function(a){return b(["../IntegratedMeshLayer"],a)})},KML:function(){return a.create(function(a){return b(["../KMLLayer"],a)})},OpenStreetMap:function(){return a.create(function(a){return b(["../OpenStreetMapLayer"],a)})},PointCloudLayer:function(){return a.create(function(a){return b(["../PointCloudLayer"],a)})},VectorTileLayer:function(){return a.create(function(a){return b(["../VectorTileLayer"],
a)})},WebTiledLayer:function(){return a.create(function(a){return b(["../WebTileLayer"],a)})},WMS:function(){return a.create(function(a){return b(["../WMSLayer"],a)})},RasterDataLayer:function(){return a.resolve(null)}};c.supportedTypes={"web-scene/operational-layers":{ArcGISFeatureLayer:"readwrite",ArcGISImageServiceLayer:"readwrite",ArcGISMapServiceLayer:"readwrite",ArcGISSceneServiceLayer:"readwrite",ArcGISTiledElevationServiceLayer:"read",ArcGISTiledImageServiceLayer:"readwrite",ArcGISTiledMapServiceLayer:"readwrite",
BuildingSceneLayer:"readwrite",GroupLayer:"readwrite",IntegratedMeshLayer:"readwrite",PointCloudLayer:"readwrite",WebTiledLayer:"readwrite",CSV:"readwrite",VectorTileLayer:"readwrite",WMS:"readwrite",KML:"readwrite",RasterDataLayer:"readwrite"},"web-scene/basemap":{ArcGISTiledImageServiceLayer:"readwrite",ArcGISTiledMapServiceLayer:"readwrite",WebTiledLayer:"readwrite",OpenStreetMap:"readwrite",VectorTileLayer:"readwrite",ArcGISImageServiceLayer:"readwrite",WMS:"readwrite",ArcGISMapServiceLayer:"readwrite"},
"web-scene/ground":{ArcGISTiledElevationServiceLayer:"readwrite"},"web-map/operational-layers":{ArcGISImageServiceLayer:"readwrite",ArcGISImageServiceVectorLayer:"readwrite",ArcGISMapServiceLayer:"readwrite",ArcGISStreamLayer:"readwrite",ArcGISTiledImageServiceLayer:"readwrite",ArcGISTiledMapServiceLayer:"readwrite",ArcGISFeatureLayer:"readwrite",BingMapsAerial:"readwrite",BingMapsRoad:"readwrite",BingMapsHybrid:"readwrite",CSV:"readwrite",GeoRSS:"readwrite",KML:"readwrite",VectorTileLayer:"readwrite",
WMS:"readwrite",WebTiledLayer:"readwrite"},"web-map/basemap":{ArcGISImageServiceLayer:"readwrite",ArcGISImageServiceVectorLayer:"readwrite",ArcGISMapServiceLayer:"readwrite",ArcGISTiledImageServiceLayer:"readwrite",ArcGISTiledMapServiceLayer:"readwrite",OpenStreetMap:"readwrite",VectorTileLayer:"readwrite",WMS:"readwrite",WebTiledLayer:"readwrite",BingMapsAerial:"readwrite",BingMapsRoad:"readwrite",BingMapsHybrid:"readwrite"}}})(e||(e={}));return e})},"esri/layers/mixins/PortalLayer":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/Error ../../core/Logger ../../core/promiseUtils ../../core/urlUtils ../../core/accessorSupport/decorators ../../portal/Portal ../../portal/PortalItem".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g){var q=h.getLogger("esri.layers.mixins.PortalLayer");return function(e){function h(){return null!==e&&e.apply(this,arguments)||this}m(h,e);Object.defineProperty(h.prototype,"portalItem",{set:function(a){a!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",a))},enumerable:!0,configurable:!0});h.prototype.readPortalItem=function(a,c,b){if(c.itemId)return new g({id:c.itemId,portal:b&&b.portal})};h.prototype.writePortalItem=function(a,
c,b){a&&a.id&&(c.itemId=a.id)};h.prototype.loadFromPortal=function(c){var d=this;return this.portalItem&&this.portalItem.id?a.create(function(a){return b(["../../portal/support/layersLoader"],a)}).then(function(a){return a.load({instance:d,supportedTypes:c.supportedTypes,validateItem:c.validateItem,supportsData:c.supportsData}).catch(function(a){q.warn("Failed to load layer ("+d.title+", "+d.id+") portal item ("+d.portalItem.id+")\n  "+a);throw a;})}):a.resolve()};h.prototype.read=function(a,c){c&&
(c.layer=this);this.inherited(arguments)};h.prototype.write=function(a,b){var d=b&&b.portal,f=this.portalItem&&this.portalItem.id&&(this.portalItem.portal||n.getDefault());return d&&f&&!c.hasSamePortal(f.restUrl,d.restUrl)?(b.messages&&b.messages.push(new l("layer:cross-portal","The layer '"+this.title+" ("+this.id+")' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save the scene, set the layer.portalItem to null or save the scene to the same portal as the item associated with the layer",
{layer:this})),null):this.inherited(arguments)};d([f.property({type:g})],h.prototype,"portalItem",null);d([f.reader("web-document","portalItem",["itemId"])],h.prototype,"readPortalItem",null);d([f.writer("portalItem",{itemId:{type:String}})],h.prototype,"writePortalItem",null);return h=d([f.subclass("esri.layers.mixins.PortalLayer")],h)}(f.declared(k))})},"esri/layers/mixins/ScaleRangeLayer":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){return function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.minScale=0;a.maxScale=0;return a}m(a,b);d([l.property({type:Number,json:{write:!0}})],a.prototype,"minScale",void 0);d([l.property({type:Number,json:{write:!0}})],a.prototype,"maxScale",void 0);return a=d([l.subclass("esri.layers.mixins.ScaleRangeLayer")],a)}(l.declared(k))})},"esri/layers/mixins/RefreshableLayer":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){return function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.refreshInterval=0;return a}m(a,b);a.prototype.refresh=function(){this.emit("refresh")};d([l.property({type:Number,cast:function(a){return.1<=a?a:0>=a?0:.1},json:{write:!0,origins:{"web-document":{default:0,write:!0}}}})],a.prototype,"refreshInterval",void 0);return a=d([l.subclass("esri.layers.mixins.RefreshableLayer")],a)}(l.declared(k))})},"esri/portal/support/layersCreator":function(){define("require exports ../../core/tsSupport/generatorHelper ../../core/tsSupport/awaiterHelper ../../core/Collection ../../core/has ../../core/promiseUtils ../../layers/support/lazyLayerLoader ../PortalItem ./mapNotesUtils ./portalLayers ../../renderers/support/styleUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g){function q(a,c,b){return d(this,void 0,void 0,function(){var d;return m(this,function(f){switch(f.label){case 0:return d=new a,d.read(c,b.context),[4,g.loadStyleRenderer(d,b.context)];case 1:return f.sent(),[2,d]}})})}function p(a,c){return d(this,void 0,void 0,function(){var b;return m(this,function(d){switch(d.label){case 0:return[4,t(a,c)];case 1:return b=d.sent(),[2,q(b,a,c)]}})})}function t(b,e){return d(this,void 0,void 0,function(){var d,g,h,p,l,k,t,q;return m(this,
function(r){switch(r.label){case 0:d=e.context;switch(d.origin){case "web-scene":switch(d.layerContainerType){case "basemap":r=y;break;case "ground":r=z;break;default:r=u}break;default:switch(d.layerContainerType){case "basemap":r=w;break;default:r=x}}g=r;h=b.layerType||b.type;!h&&e&&e.defaultLayerType&&(h=e.defaultLayerType);l=(p=g[h])?a.layerLookupMap[p]:a.layerLookupMap.UnknownLayer;if("Feature Collection"!==b.type)return[3,4];if(!b.itemId)return[3,3];k=new c({id:b.itemId,portal:d&&d.portal});
return[4,k.load()];case 1:return r.sent(),[4,n.selectLayerClassPath(k)];case 2:t=r.sent(),q=t.className||"UnknownLayer",l=a.layerLookupMap[q],r.label=3;case 3:return[3,5];case 4:"ArcGISFeatureLayer"===h&&f.isMapNotesLayer(b)&&(l=a.layerLookupMap.MapNotesLayer),r.label=5;case 5:return b.wmtsInfo&&(l=a.layerLookupMap.WMTSLayer),[2,l()]}})})}function r(a,c,b){return d(this,void 0,void 0,function(){var d,f,e;return m(this,function(g){switch(g.label){case 0:return d=new k,f=v(d,Array.isArray(c.layers)?
c.layers:[],b),[4,a];case 1:return e=g.sent(),[4,f];case 2:return g.sent(),"group"===e.type?(e.layers.addMany(d),[2,e]):[2]}})})}function v(a,c,b){return d(this,void 0,void 0,function(){var d,f,e,g,n,l,k,t,q;return m(this,function(m){switch(m.label){case 0:if(!c)return[2];d=[];f=0;for(e=c;f<e.length;f++)g=e[f],n=p(g,b),"GroupLayer"===g.layerType?d.push(r(n,g,b)):d.push(n);return[4,h.eachAlways(d)];case 1:l=m.sent();k=0;for(t=l;k<t.length;k++)q=t[k],!q.value||b.filter&&!b.filter(q.value)||a.add(q.value);
return[2]}})})}Object.defineProperty(e,"__esModule",{value:!0});var u={ArcGISFeatureLayer:"FeatureLayer",ArcGISImageServiceLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",PointCloudLayer:"PointCloudLayer",ArcGISSceneServiceLayer:"SceneLayer",IntegratedMeshLayer:"IntegratedMeshLayer",BuildingSceneLayer:"BuildingSceneLayer",ArcGISTiledElevationServiceLayer:"ElevationLayer",ArcGISTiledImageServiceLayer:"TileLayer",ArcGISTiledMapServiceLayer:"TileLayer",GroupLayer:"GroupLayer",WebTiledLayer:"WebTileLayer",
CSV:"CSVLayer",VectorTileLayer:"VectorTileLayer",WMS:"WMSLayer",DefaultTileLayer:"TileLayer",KML:"KMLLayer",RasterDataLayer:"UnsupportedLayer"},z={ArcGISTiledElevationServiceLayer:"ElevationLayer",DefaultTileLayer:"ElevationLayer"},y={ArcGISTiledMapServiceLayer:"TileLayer",ArcGISTiledImageServiceLayer:"TileLayer",OpenStreetMap:"OpenStreetMapLayer",WebTiledLayer:"WebTileLayer",VectorTileLayer:"VectorTileLayer",ArcGISImageServiceLayer:"UnsupportedLayer",WMS:"UnsupportedLayer",ArcGISMapServiceLayer:"UnsupportedLayer",
DefaultTileLayer:"TileLayer"},x={ArcGISFeatureLayer:"FeatureLayer",ArcGISImageServiceLayer:"ImageryLayer",ArcGISImageServiceVectorLayer:"UnsupportedLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISStreamLayer:"StreamLayer",ArcGISTiledImageServiceLayer:"TileLayer",ArcGISTiledMapServiceLayer:"TileLayer",VectorTileLayer:"VectorTileLayer",WebTiledLayer:"WebTileLayer",CSV:"CSVLayer",GeoRSS:"GeoRSSLayer",KML:"KMLLayer",WMS:"WMSLayer",BingMapsAerial:"BingMapsLayer",BingMapsRoad:"BingMapsLayer",BingMapsHybrid:"BingMapsLayer",
DefaultTileLayer:"TileLayer"},w={ArcGISImageServiceLayer:"ImageryLayer",ArcGISImageServiceVectorLayer:"UnsupportedLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISTiledImageServiceLayer:"TileLayer",ArcGISTiledMapServiceLayer:"TileLayer",OpenStreetMap:"OpenStreetMapLayer",VectorTileLayer:"VectorTileLayer",WebTiledLayer:"WebTileLayer",BingMapsAerial:"BingMapsLayer",BingMapsRoad:"BingMapsLayer",BingMapsHybrid:"BingMapsLayer",WMS:"WMSLayer",DefaultTileLayer:"TileLayer"};e.createLayer=p;e.populateOperationalLayers=
function(a,c,b){return d(this,void 0,void 0,function(){return m(this,function(d){return[2,v(a,c,b)]})})}})},"esri/layers/support/lazyLayerLoader":function(){define(["require","exports","../../core/promiseUtils"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.layerLookupMap={CSVLayer:function(){return m.create(function(d){return b(["../CSVLayer"],d)})},ElevationLayer:function(){return m.create(function(d){return b(["../ElevationLayer"],d)})},FeatureLayer:function(){return m.create(function(d){return b(["../FeatureLayer"],
d)})},GroupLayer:function(){return m.create(function(d){return b(["../GroupLayer"],d)})},GeoRSSLayer:function(){return m.create(function(d){return b(["../GeoRSSLayer"],d)})},ImageryLayer:function(){return m.create(function(d){return b(["../ImageryLayer"],d)})},KMLLayer:function(){return m.create(function(d){return b(["../KMLLayer"],d)})},MapImageLayer:function(){return m.create(function(d){return b(["../MapImageLayer"],d)})},MapNotesLayer:function(){return m.create(function(d){return b(["../MapNotesLayer"],
d)})},OpenStreetMapLayer:function(){return m.create(function(d){return b(["../OpenStreetMapLayer"],d)})},PointCloudLayer:function(){return m.create(function(d){return b(["../PointCloudLayer"],d)})},SceneLayer:function(){return m.create(function(d){return b(["../SceneLayer"],d)})},BuildingSceneLayer:function(){return m.create(function(d){return b(["../BuildingSceneLayer"],d)})},IntegratedMeshLayer:function(){return m.create(function(d){return b(["../IntegratedMeshLayer"],d)})},StreamLayer:function(){return m.create(function(d){return b(["../StreamLayer"],
d)})},TileLayer:function(){return m.create(function(d){return b(["../TileLayer"],d)})},UnknownLayer:function(){return m.create(function(d){return b(["../UnknownLayer"],d)})},UnsupportedLayer:function(){return m.create(function(d){return b(["../UnsupportedLayer"],d)})},VectorTileLayer:function(){return m.create(function(d){return b(["../VectorTileLayer"],d)})},WebTileLayer:function(){return m.create(function(d){return b(["../WebTileLayer"],d)})},WMSLayer:function(){return m.create(function(d){return b(["../WMSLayer"],
d)})},WMTSLayer:function(){return m.create(function(d){return b(["../WMTSLayer"],d)})},BingMapsLayer:function(){return m.create(function(d){return b(["../BingMapsLayer"],d)})}}})},"esri/portal/support/mapNotesUtils":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.isMapNotesLayer=function(b){var d=["TITLE","DESCRIPTION","IMAGE_URL","IMAGE_LINK_URL"];if((b=b.layers||b.featureCollection&&b.featureCollection.layers)&&Array.isArray(b))return b=b[0],
b.layerDefinition&&Array.isArray(b.layerDefinition.fields)&&b.layerDefinition.fields.forEach(function(b){b=d.indexOf(b.name);-1<b&&d.splice(b,1)}),d.length?!1:!0}})},"esri/portal/support/portalLayers":function(){define("require exports ../../core/tsSupport/assignHelper ../../request ../../core/Collection ../../core/Error ../../core/promiseUtils ../../layers/support/lazyLayerLoader ../PortalItem ./mapNotesUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f){function n(a){switch(a.type){case "Map Service":return q(a);
case "Feature Service":return p(a);case "Feature Collection":return r(a);case "Scene Service":return t(a);case "Image Service":return v(a);case "Stream Service":return{className:"StreamLayer"};case "Vector Tile Service":return{className:"VectorTileLayer"};case "KML":return{className:"KMLLayer"};case "WMTS":return{className:"WMTSLayer"};case "WMS":return{className:"WMSLayer"};default:return h.reject(new l("portal:unknown-item-type","Unknown item type '${type}'",{type:a.type}))}}function g(c){return(0,a.layerLookupMap[c.className])().then(function(a){return{constructor:a,
properties:c.properties}})}function q(a){return u(a).then(function(a){return a?{className:"TileLayer"}:{className:"MapImageLayer"}})}function p(a){return z(a).then(function(a){if("object"===typeof a){var c={outFields:["*"]};null!=a.id&&(c.layerId=a.id);return{className:"FeatureLayer",properties:c}}return{className:"GroupLayer"}})}function t(a){return z(a).then(function(c){if("object"===typeof c){var b={},d=void 0;null!=c.id?(b.layerId=c.id,d=a.url+"/layers/"+c.id):d=a.url;if(Array.isArray(a.typeKeywords)&&
0<a.typeKeywords.length){c={IntegratedMesh:"IntegratedMeshLayer","3DObject":"SceneLayer",Point:"SceneLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};for(var f=0,e=Object.keys(c);f<e.length;f++){var g=e[f];if(-1!==a.typeKeywords.indexOf(g))return{className:c[g]}}}return y(d).then(function(a){var c="SceneLayer",d={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};a&&a.layerType&&d[a.layerType]&&
(c=d[a.layerType]);return{className:c,properties:b}})}return{className:"GroupLayer"}})}function r(a){return a.load().then(function(){return a.fetchData()}).then(function(a){if(a&&Array.isArray(a.layers)){if(f.isMapNotesLayer(a))return{className:"MapNotesLayer"};if(1===a.layers.length)return{className:"FeatureLayer"}}return{className:"GroupLayer"}})}function v(a){return u(a).then(function(c){var b=new k(a.typeKeywords);return c?b.find(function(a){return"elevation 3d layer"===a.toLowerCase()})?{className:"ElevationLayer"}:
{className:"TileLayer"}:{className:"ImageryLayer"}})}function u(a){return y(a.url).then(function(a){return a.tileInfo})}function z(a){return!a.url||a.url.match(/\/\d+$/)?h.resolve({}):a.load().then(function(){return a.fetchData()}).then(function(c){return c&&Array.isArray(c.layers)?1===c.layers.length?{id:c.layers[0].id}:!1:y(a.url).then(function(a){return a&&Array.isArray(a.layers)?1===a.layers.length?{id:a.layers[0].id}:!1:{}})})}function y(a){return d(a,{responseType:"json",query:{f:"json"}}).then(function(a){return a.data})}
Object.defineProperty(e,"__esModule",{value:!0});e.fromItem=function(a){!a.portalItem||a.portalItem instanceof c||a.portalItem.constructor&&a.portalItem.constructor._meta||(a=m({},a,{portalItem:new c(a.portalItem)}));return a.portalItem.load().then(n).then(g).then(function(c){var b=m({portalItem:a.portalItem},c.properties);return h.resolve(new c.constructor(b))})};e.selectLayerClassPath=n})},"esri/renderers/support/styleUtils":function(){define("require exports ../../core/tsSupport/generatorHelper ../../core/tsSupport/awaiterHelper ../../core/asyncUtils ../../core/Warning".split(" "),
function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});e.loadStyleRenderer=function(b,a){return d(this,void 0,void 0,function(){var c,d,e;return m(this,function(f){switch(f.label){case 0:return(c=b&&b.getAtOrigin&&b.getAtOrigin("renderer",a.origin))&&"unique-value"===c.type&&c.styleOrigin?[4,k.result(c.populateFromStyle())]:[3,2];case 1:d=f.sent(),!1===d.ok&&(e=d.error,a&&a.messages&&a.messages.push(new l("renderer:style-reference","Failed to create unique value renderer from style reference: "+
e.message,{error:e,context:a})),b.clear("renderer",a.origin)),f.label=2;case 2:return[2]}})})}})},"esri/layers/FeatureLayer":function(){define("require exports ../core/tsSupport/assignHelper ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/paramHelper ../core/tsSupport/generatorHelper ../core/tsSupport/awaiterHelper @dojo/framework/shim/array ../PopupTemplate ../renderers ../request ../symbols ../core/asyncUtils ../core/Collection ../core/Error ../core/Handles ../core/kebabDictionary ../core/Logger ../core/MultiOriginJSONSupport ../core/promiseUtils ../core/urlUtils ../core/accessorSupport/decorators ../geometry/Extent ../geometry/HeightModelInfo ../geometry/SpatialReference ./Layer ./graphics/editingSupport ./graphics/sources/MemorySource ./mixins/ArcGISService ./mixins/OperationalLayer ./mixins/PortalLayer ./mixins/RefreshableLayer ./mixins/ScaleRangeLayer ./mixins/TemporalLayer ./support/arcgisLayerUrl ./support/commonProperties ./support/FeatureIndex ./support/FeatureProcessing ./support/FeatureReduction ./support/FeatureReductionSelection ./support/FeatureTemplate ./support/FeatureType ./support/Field ./support/fieldUtils ./support/LabelClass ./support/labelingInfo ./support/layerSourceUtils ./support/Relationship ../renderers/support/jsonUtils ../renderers/support/styleUtils ../support/popupUtils ../symbols/support/jsonUtils ../tasks/support/AttachmentQuery ../tasks/support/FeatureSet ../tasks/support/Query ../tasks/support/RelationshipQuery".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x,w,A,B,F,C,E,G,Q,V,R,I,W,M,U,O,J,fa,H,da,aa,oa,ga,la,Z,ja,ea,sa,pa,Ea,ra,na,ua,qa,Ca,wa,Ta){function T(a,c,b){return!(a&&a.hasOwnProperty(c)?!a[c]:!b)}var xa=new u.default({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryMultiPatch:"multipatch"}),ya=z.getLogger("esri.layers.FeatureLayer");return function(e){function u(a){var c=e.call(this)||this;c._handles=new v;
c.capabilities=null;c.copyright=null;c.displayField=null;c.definitionExpression=null;c.dynamicDataSource=null;c.editFieldsInfo=null;c.editingEnabled=!0;c.elevationInfo=null;c.featureReduction=null;c.fields=null;c.fullExtent=null;c.gdbVersion=null;c.geometryProperties=null;c.geometryType=null;c.hasM=void 0;c.hasZ=void 0;c.heightModelInfo=null;c.historicMoment=null;c.isTable=!1;c.labelsVisible=!0;c.labelingInfo=null;c.layerId=void 0;c.legendEnabled=!0;c.maxRecordCount=void 0;c.tileMaxRecordCount=void 0;
c.minScale=0;c.maxScale=0;c.objectIdField=null;c.path=null;c.popupEnabled=!0;c.popupTemplate=null;c.relationships=null;c.returnM=void 0;c.returnZ=void 0;c.screenSizePerspectiveEnabled=!0;c.serviceDefinitionExpression=null;c.spatialReference=C.WGS84;c.templates=null;c.timeInfo=null;c.title=null;c.sublayerTitleMode="item-title";c.trackIdField=null;c.type="feature";c.typeIdField=null;c.types=null;c.indexes=new (t.ofType(fa.FeatureIndex));c.userIsAdmin=!1;c.version=void 0;c.visible=!0;c.when().then(function(){return c._setOutFields()});
return c}d(u,e);u.prototype.normalizeCtorArgs=function(a,c){return"string"===typeof a?m({url:a},c):a};u.prototype.load=function(){var a=this;if(this.portalItem&&this.portalItem.loaded&&this.source)this.addResolvingPromise(this.createGraphicsSource().then(function(c){return a._initLayerProperties(c)}));else{var c=this.loadFromPortal({supportedTypes:["Feature Service","Feature Collection"]}).catch(function(a){return a}).then(function(){if(a.url&&null==a.layerId&&/FeatureServer|MapServer\/*$/i.test(a.url))return a._fetchFirstLayerId().then(function(c){null!=
c&&(a.layerId=c)})}).then(function(){if(!a.url&&!a._hasMemorySource())throw new r("feature-layer:missing-url-or-source","Feature layer must be created with either a url or a source");return a.createGraphicsSource().then(function(c){return a._initLayerProperties(c)})});this.addResolvingPromise(c);return this.when()}};u.prototype.readCapabilities=function(a,c){c=c.layerDefinition||c;return{data:this._readDataCapabilities(c),operations:this._readOperationsCapabilities(c.capabilities||a,c),query:this._readQueryCapabilities(c),
queryRelated:this._readQueryRelatedCapabilities(c),editing:this._readEditingCapabilities(c)}};u.prototype.readEditingEnabled=function(a,c){return"Query"===c.capabilities?!1:!0};u.prototype.writeEditingEnabled=function(a,c,b,d){a||(c.capabilities="Query")};Object.defineProperty(u.prototype,"fieldsMap",{get:function(){var a=this.fields,c=new Map;if(!a)return c;for(var b=0;b<a.length;b++){var d=a[b],f=d&&d.name&&d.name.trim();f&&(c.set(f,d),c.set(f.toLowerCase(),d))}if(this.processing&&this.processing.fields)for(a=
0,b=this.processing.fields;a<b.length;a++)if(f=(d=b[a])&&d.name&&d.name.trim())c.set(f,d),c.set(f.toLowerCase(),d);return c},enumerable:!0,configurable:!0});u.prototype.readIsTable=function(a,c){c=c&&c.layerDefinition||c;return"Table"===c.type};Object.defineProperty(u.prototype,"hasService",{get:function(){return!this._hasMemorySource()},enumerable:!0,configurable:!0});u.prototype.readMinScale=function(a,c){return c.effectiveMinScale||a||0};u.prototype.readMaxScale=function(a,c){return c.effectiveMaxScale||
a||0};u.prototype.readObjectIdFieldFromService=function(a,c){c=c.layerDefinition||c;if(c.objectIdField)return c.objectIdField;if(c.fields)for(a=0,c=c.fields;a<c.length;a++){var b=c[a];if("esriFieldTypeOID"===b.type)return b.name}};Object.defineProperty(u.prototype,"outFields",{set:function(a){Array.isArray(a)?this._setOutFields(a):this._set("outFields",null)},enumerable:!0,configurable:!0});Object.defineProperty(u.prototype,"parsedUrl",{get:function(){var a=this.url?w.urlToObject(this.url):null;if(null!=
a)if(null!=this.layerId)a.path=w.join(a.path,this.layerId.toString());else if(null!=this.dynamicDataSource){var c={source:sa.sourceToJSON(this.dynamicDataSource)};a.query={layer:JSON.stringify(c)}}return a},enumerable:!0,configurable:!0});Object.defineProperty(u.prototype,"defaultPopupTemplate",{get:function(){return this.createPopupTemplate()},enumerable:!0,configurable:!0});Object.defineProperty(u.prototype,"renderer",{set:function(a){Z.fixRendererFields(a,this.fields);this._set("renderer",a)},
enumerable:!0,configurable:!0});u.prototype.readRenderer=function(a,c,b){c=c.layerDefinition||c;var d=c.drawingInfo&&c.drawingInfo.renderer||void 0,f,e;if(d)(f=Ea.read(d,c,b)||void 0)||ya.error("Failed to create renderer",{rendererDefinition:c.drawingInfo.renderer,layer:this,context:b});else if(c.defaultSymbol)ua.read(c.defaultSymbol,c,b),c.types&&c.types.length?(f=new n.UniqueValueRenderer({defaultSymbol:e,field:c.typeIdField}),c.types.forEach(function(a){d.addUniqueValueInfo(a.id,ua.read(a.symbol,
a,b))})):f=new n.SimpleRenderer({symbol:e});else if("Table"!==c.type){switch(c.geometryType){case "esriGeometryPoint":case "esriGeometryMultipoint":e=new q.SimpleMarkerSymbol;break;case "esriGeometryPolyline":e=new q.SimpleLineSymbol;break;case "esriGeometryPolygon":e=new q.SimpleFillSymbol}f=e&&new n.SimpleRenderer({symbol:e})}return f};u.prototype.writeRenderer=function(a,c,b,d){Ea.writeTarget(a,c,b,d)};Object.defineProperty(u.prototype,"source",{set:function(a){var c=this._get("source");c!==a&&
(c&&c&&c.isInstanceOf&&c.isInstanceOf(t)&&this._resetMemorySource(c),a&&a&&a.isInstanceOf&&a.isInstanceOf(t)&&this._initMemorySource(a),this._set("source",a))},enumerable:!0,configurable:!0});u.prototype.castSource=function(a){return a?Array.isArray(a)||a&&a.isInstanceOf&&a.isInstanceOf(t)?new Q.default({layer:this,items:a}):a:null};u.prototype.readSource=function(a,c){a=Ca.fromJSON(c.featureSet);return new Q.default({layer:this,items:a&&a.features||[]})};u.prototype.readTemplates=function(a,c){var b=
c.editFieldsInfo;c=b&&b.creatorField;b=b&&b.editorField;a=a&&a.map(function(a){return oa.fromJSON(a)});this._fixTemplates(a,c);this._fixTemplates(a,b);return a};u.prototype.readTitle=function(a,c){a=c.layerDefinition&&c.layerDefinition.name||c.name;c=c.title||c.layerDefinition&&c.layerDefinition.title;if(a){c=this.portalItem&&this.portalItem.title;if("item-title"===this.sublayerTitleMode)return this.url?O.titleFromUrlAndName(this.url,a):a;a=a||this.url&&O.parse(this.url).title;if(!a)return;"item-title-and-service-name"===
this.sublayerTitleMode&&c&&(a=c+" - "+a);return O.cleanTitle(a)}if("item-title"===this.sublayerTitleMode&&c)return c};u.prototype.readTitleFromWebMap=function(a,c){return c.title||c.layerDefinition&&c.layerDefinition.name};u.prototype.readTypeIdField=function(a,c){c=c.layerDefinition||c;if(a=c.typeIdField)if(c=this.getField(a,c.fields))a=c.name;return a};u.prototype.readTypes=function(a,c){var b=this;c=c.layerDefinition||c;a=c.types;var d=(c=c.editFieldsInfo)&&c.creatorField,f=c&&c.editorField;return a&&
a.map(function(a){a=ga.fromJSON(a);b._fixTemplates(a.templates,d);b._fixTemplates(a.templates,f);return a})};Object.defineProperty(u.prototype,"url",{set:function(a){a=O.sanitizeUrlWithLayerId(this,a,ya);this._set("url",a.url);null!=a.layerId&&this._set("layerId",a.layerId)},enumerable:!0,configurable:!0});u.prototype.writeUrl=function(a,c,b,d){O.writeUrlWithLayerId(this,a,null,c,d)};u.prototype.readVersion=function(a,c){return c.currentVersion?c.currentVersion:c.hasOwnProperty("capabilities")||c.hasOwnProperty("drawingInfo")||
c.hasOwnProperty("hasAttachments")||c.hasOwnProperty("htmlPopupType")||c.hasOwnProperty("relationships")||c.hasOwnProperty("timeInfo")||c.hasOwnProperty("typeIdField")||c.hasOwnProperty("types")?10:9.3};u.prototype.readVisible=function(a,c){if(c.layerDefinition&&null!=c.layerDefinition.defaultVisibility)return!!c.layerDefinition.defaultVisibility;if(null!=c.visibility)return!!c.visibility};u.prototype.addAttachment=function(a,c){var b=this;return this.load().then(function(){return b._checkAttachmentSupport(a)}).then(function(){return"addAttachment"in
b.source?b.source.addAttachment(a,c):x.reject(new r("FeatureLayer","Layer source does not support addAttachment capability"))})};u.prototype.updateAttachment=function(a,c,b){var d=this;return this.load().then(function(){return d._checkAttachmentSupport(a)}).then(function(){return"updateAttachment"in d.source?d.source.updateAttachment(a,c,b):x.reject(new r("FeatureLayer","Layer source does not support updateAttachment capability"))})};u.prototype.applyEdits=function(a){return p.safeCast(G.applyEdits(this,
a))};u.prototype.on=function(a,c){return this.inherited(arguments)};u.prototype.createPopupTemplate=function(a){return na.createPopupTemplate(this,a)};u.prototype.createGraphicsSource=function(){var a=this;return this._hasMemorySource()?(this.emit("graphics-source-create",{graphicsSource:this.source}),this.source.load()):x.create(function(a){return b(["./graphics/sources/FeatureLayerSource"],a)}).then(function(c){return(new c.default({layer:a})).load()}).then(function(c){a.emit("graphics-source-create",
{graphicsSource:c});return c})};u.prototype.createQuery=function(){var a=new wa,c=this.get("capabilities.data");a.gdbVersion=this.gdbVersion;a.historicMoment=this.historicMoment;a.returnGeometry=!0;c&&(c.supportsZ&&null!=this.returnZ&&(a.returnZ=this.returnZ),c.supportsM&&null!=this.returnM&&(a.returnM=this.returnM));a.outFields=["*"];a.where=this.definitionExpression||"1\x3d1";a.multipatchOption="multipatch"===this.geometryType?"xyFootprint":null;return a};u.prototype.deleteAttachments=function(a,
c){var b=this;return this.load().then(function(){return b._checkAttachmentSupport(a)}).then(function(){return"deleteAttachments"in b.source?b.source.deleteAttachments(a,c):x.reject(new r("FeatureLayer","Layer source does not support deleteAttachments capability"))})};u.prototype.getFeatureType=function(a){var c=this.typeIdField;if(!c||!a)return null;var b=a.attributes?a.attributes[c]:void 0;if(null==b)return null;var d=null;this.types.some(function(a){var c=a.id;if(null==c)return!1;c.toString()===
b.toString()&&(d=a);return!!d});return d};u.prototype.getFieldDomain=function(a,c){var b=this,d,f=!1;c=(c=c&&c.feature)&&c.attributes;var e=this.typeIdField&&c&&c[this.typeIdField];null!=e&&this.types&&(f=this.types.some(function(c){return c.id==e?((d=c.domains&&c.domains[a])&&"inherited"===d.type&&(d=b._getLayerDomain(a)),!0):!1}));f||d||(d=this._getLayerDomain(a));return d};u.prototype.getField=function(a,c){return c?Z.getField(c,a):this.fieldsMap.get(a)||this.fieldsMap.get(a.toLowerCase())};u.prototype.queryAttachments=
function(a){var c=this;return this.load().then(function(){if(!c.get("capabilities.data.supportsAttachment"))return x.reject(new r("FeatureLayer","this layer doesn't support attachments"));var b=a.attachmentTypes,d=a.objectIds,f=a.globalIds,e=a.num,g=a.size,h=a.start,p=a.where;return!c.get("capabilities.operations.supportsQueryAttachments")&&(b=b&&b.length,f=f&&f.length,g=g&&g.length,d&&1<d.length||b||f||g||e||h||p)?x.reject(new r("FeatureLayer","when 'supportsQueryAttachments' is false, only objectIds of length 1 are supported",
a)):d&&d.length||p?"queryAttachments"in c.source?c.source.queryAttachments(a):x.reject(new r("FeatureLayer","Layer source does not support queryAttachments capability",a)):x.reject(new r("FeatureLayer","'objectIds' or 'where' are required to perform attachment query",a))})};u.prototype.queryFeatures=function(a,c){var b=this;return this.load().then(function(){return b.source.queryFeatures(a||b.createQuery(),c)}).then(function(a){if(a&&a.features)for(var c=0,d=a.features;c<d.length;c++){var f=d[c];
f.layer=f.sourceLayer=b}return a})};u.prototype.queryObjectIds=function(a,c){var b=this;return this.load().then(function(){return b.source.queryObjectIds?b.source.queryObjectIds(a||b.createQuery(),c):x.reject(new r("FeatureLayer","Layer source does not support queryObjectIds capability"))})};u.prototype.queryFeatureCount=function(a,c){var b=this;return this.load().then(function(){return b.source.queryFeatureCount?b.source.queryFeatureCount(a||b.createQuery(),c):x.reject(new r("FeatureLayer","Layer source does not support queryFeatureCount capability"))})};
u.prototype.queryExtent=function(a,c){var b=this;return this.load().then(function(){return b.source.queryExtent?b.source.queryExtent(a||b.createQuery(),c):x.reject(new r("FeatureLayer","Layer source does not support queryExtent capability"))})};u.prototype.queryRelatedFeatures=function(a){var c=this;return this.load().then(function(){return"queryRelatedFeatures"in c.source?c.source.queryRelatedFeatures(a):x.reject(new r("FeatureLayer","Layer source does not support queryRelatedFeatures capability"))})};
u.prototype.read=function(a,c){var b=a.featureCollection;if(b){var d=b.layers;d&&1===d.length&&(this.inherited(arguments,[d[0],c]),null!=b.showLegend&&this.inherited(arguments,[{showLegend:b.showLegend},c]))}this.inherited(arguments,[a,c]);c&&"service"===c.origin&&this.revert(["objectIdField","fields","timeInfo"],"service")};u.prototype.write=function(a,c){return c&&("web-scene"===c.origin||"web-map"===c.origin)&&c.messages&&this.isTable?(c.messages.push(new r("layer:unsupported","Layers ("+this.title+
", "+this.id+") of type '"+this.declaredClass+"' using a Table source cannot written to web scenes",{layer:this})),null):this.inherited(arguments)};u.prototype.importLayerViewModule=function(a){switch(a.type){case "2d":return x.create(function(a){return b(["../views/2d/layers/FeatureLayerView2D"],a)});case "3d":return x.create(function(a){return b(["../views/3d/layers/FeatureLayerView3D"],a)})}};u.prototype._checkAttachmentSupport=function(a){var c=a.attributes,b=this.objectIdField;if(!this.get("capabilities.data.supportsAttachment"))return x.reject(new r("FeatureLayer",
"this layer doesn't support attachments"));if(!a)return x.reject(new r("FeatureLayer","A feature is required to add/delete/update attachments"));if(!c)return x.reject(new r("FeatureLayer","'attributes' are required on a feature to query attachments"));if(!c[b])return x.reject(new r("FeatureLayer","feature is missing the identifying attribute "+b))};u.prototype._getLayerDomain=function(a){if(!this.fields)return null;var c=null;this.fields.some(function(b){b.name===a&&(c=b.domain);return!!c});return c};
u.prototype._fetchFirstLayerId=function(){return g(this.url,{query:{f:"json"},responseType:"json"}).then(function(a){if(a=a.data){if(Array.isArray(a.layers)&&0<a.layers.length)return a.layers[0].id;if(Array.isArray(a.tables)&&0<a.tables.length)return a.tables[0].id}})};u.prototype._initLayerProperties=function(c){return a(this,void 0,void 0,function(){return h(this,function(a){this._set("source",c);c.layerDefinition&&this.read(c.layerDefinition,{origin:"service",url:this.parsedUrl});this._verifySource();
this._verifyFields();Z.fixRendererFields(this.renderer,this.fields);Z.fixTimeInfoFields(this.timeInfo,this.fields);return[2,ra.loadStyleRenderer(this,{origin:"service"})]})})};u.prototype._verifyFields=function(){var a=this.parsedUrl&&this.parsedUrl.path||"undefined";this.objectIdField||console.log("FeatureLayer: 'objectIdField' property is not defined (url: "+a+")");this.isTable||this._hasMemorySource()||-1!==a.search(/\/FeatureServer\//i)||this.fields&&this.fields.some(function(a){return"geometry"===
a.type})||console.log("FeatureLayer: unable to find field of type 'geometry' in the layer 'fields' list. If you are using a map service layer, features will not have geometry (url: "+a+")")};u.prototype._fixTemplates=function(a,c){a&&a.forEach(function(a){(a=a.prototype&&a.prototype.attributes)&&c&&delete a[c]})};u.prototype._verifySource=function(){if(this._hasMemorySource()){if(this.url)throw new r("feature-layer:mixed-source-and-url","FeatureLayer cannot be created with both an in-memory source and a url");
}else if(!this.url)throw new r("feature-layer:source-or-url-required","FeatureLayer requires either a url, a valid portal item or a source");};u.prototype._initMemorySource=function(a){var c=this;a.forEach(function(a){a.layer=c;a.sourceLayer=c});this._handles.add([a.on("after-add",function(a){a.item.layer=c;a.item.sourceLayer=c}),a.on("after-remove",function(a){a.item.layer=null;a.item.sourceLayer=null})],"fl-source")};u.prototype._resetMemorySource=function(a){a.forEach(function(a){a.layer=null;
a.sourceLayer=null});this._handles.remove("fl-source")};u.prototype._hasMemorySource=function(){return!(this.url||!this.source)};u.prototype._readDataCapabilities=function(a){return{supportsAttachment:T(a,"hasAttachments",!1),supportsM:T(a,"hasM",!1),supportsZ:T(a,"hasZ",!1)}};u.prototype._readOperationsCapabilities=function(a,c){a=a?a.toLowerCase().split(",").map(function(a){return a.trim()}):[];var b=-1!==a.indexOf("editing"),d=b&&-1!==a.indexOf("create"),f=b&&-1!==a.indexOf("delete"),e=b&&-1!==
a.indexOf("update");!b||d||f||e||(d=f=e=!0);return{supportsCalculate:T(c,"supportsCalculate",!1),supportsTruncate:T(c,"supportsTruncate",!1),supportsValidateSql:T(c,"supportsValidateSql",!1),supportsAdd:d,supportsDelete:f,supportsEditing:b,supportsQuery:-1!==a.indexOf("query"),supportsQueryAttachments:T(c.advancedQueryCapabilities,"supportsQueryAttachments",!1),supportsResizeAttachments:T(c,"supportsAttachmentsResizing",!1),supportsUpdate:e,supportsExceedsLimitStatistics:T(c,"supportsExceedsLimitStatistics",
!1)}};u.prototype._readQueryCapabilities=function(a){var c=a.advancedQueryCapabilities,b=a.ownershipBasedAccessControlForFeatures,d=a.archivingInfo,f=(a.supportedQueryFormats||"").split(",").reduce(function(a,c){(c=c.toLowerCase().trim())&&a.add(c);return a},new Set);return{supportsStatistics:T(c,"supportsStatistics",a.supportsStatistics),supportsCentroid:T(c,"supportsReturningGeometryCentroid",!1),supportsDistance:T(c,"supportsQueryWithDistance",!1),supportsDistinct:T(c,"supportsDistinct",a.supportsAdvancedQueries),
supportsExtent:T(c,"supportsReturningQueryExtent",!1),supportsGeometryProperties:T(c,"supportsReturningGeometryProperties",!1),supportsHavingClause:T(c,"supportsHavingClause",!1),supportsOrderBy:T(c,"supportsOrderBy",a.supportsAdvancedQueries),supportsPagination:T(c,"supportsPagination",!1),supportsQuantization:T(a,"supportsCoordinatesQuantization",!1),supportsQuantizationEditMode:T(a,"supportsQuantizationEditMode",!1),supportsQueryGeometry:T(a,"supportsReturningQueryGeometry",!1),supportsResultType:T(c,
"supportsQueryWithResultType",!1),supportsMaxRecordCountFactor:T(c,"supportsMaxRecordCountFactor",!1),supportsSqlExpression:T(c,"supportsSqlExpression",!1),supportsStandardizedQueriesOnly:T(a,"useStandardizedQueries",!1),supportsQueryByOthers:T(b,"allowOthersToQuery",!0),supportsHistoricMoment:T(d,"supportsQueryWithHistoricMoment",!1),supportsFormatPBF:f.has("pbf"),supportsDisjointSpatialRelationship:T(c,"supportsDisjointSpatialRel",!1)}};u.prototype._readQueryRelatedCapabilities=function(a){a=a.advancedQueryCapabilities;
var c=T(a,"supportsAdvancedQueryRelated",!1);return{supportsPagination:T(a,"supportsQueryRelatedPagination",!1),supportsCount:c,supportsOrderBy:c}};u.prototype._readEditingCapabilities=function(a){var c=a.ownershipBasedAccessControlForFeatures;return{supportsGeometryUpdate:T(a,"allowGeometryUpdates",!0),supportsGlobalId:T(a,"supportsApplyEditsWithGlobalIds",!1),supportsRollbackOnFailure:T(a,"supportsRollbackOnFailureParameter",!1),supportsUpdateWithoutM:T(a,"allowUpdateWithoutMValues",!1),supportsUploadWithItemId:T(a,
"supportsAttachmentsByUploadId",!1),supportsDeleteByAnonymous:T(c,"allowAnonymousToDelete",!0),supportsDeleteByOthers:T(c,"allowOthersToDelete",!0),supportsUpdateByAnonymous:T(c,"allowAnonymousToUpdate",!0),supportsUpdateByOthers:T(c,"allowOthersToUpdate",!0)}};u.prototype._setOutFields=function(a){void 0===a&&(a=this._get("outFields"));if(a&&a.length)if(c.includes(a,"*"))this._set("outFields",["*"]);else if(this.loaded){for(var b=0,d=a;b<d.length;b++){var f=d[b];Z.hasField(this.fields,f)||ya.error(new r("feature-layer:invalid-field",
"Invalid field "+f+" found in outFields",{layer:this,outFields:a}))}this._set("outFields",Z.fixFields(this.fields,a))}else this._set("outFields",a)};k([A.property({readOnly:!0,json:{read:!1}})],u.prototype,"capabilities",void 0);k([A.reader("service","capabilities","advancedQueryCapabilities archivingInfo supportsStatistics supportsAdvancedQueries hasAttachments hasM hasZ supportsAttachmentsResizing supportsCalculate supportsTruncate supportsValidateSql supportsCoordinatesQuantization supportsQuantizationEditMode useStandardizedQueries ownershipBasedAccessControlForFeatures allowGeometryUpdates supportsApplyEditsWithGlobalIds supportsRollbackOnFailureParameter allowUpdateWithoutMValues supportsAttachmentsByUploadId capabilities supportedQueryFormats supportsExceedsLimitStatistics".split(" "))],
u.prototype,"readCapabilities",null);k([A.property({type:String,json:{read:{source:"layerDefinition.copyrightText"},origins:{service:{read:{source:"copyrightText"}}}}})],u.prototype,"copyright",void 0);k([A.property({type:String,json:{read:{source:"layerDefinition.displayField"},origins:{service:{read:{source:"displayField"}}}}})],u.prototype,"displayField",void 0);k([A.property({type:String,json:{origins:{service:{read:!1,write:!1}},read:{source:"layerDefinition.definitionExpression"},write:{target:"layerDefinition.definitionExpression"}}})],
u.prototype,"definitionExpression",void 0);k([A.property({readOnly:!0,json:{read:ua.read}})],u.prototype,"defaultSymbol",void 0);k([A.property()],u.prototype,"dynamicDataSource",void 0);k([A.property({readOnly:!0})],u.prototype,"editFieldsInfo",void 0);k([A.property({type:Boolean})],u.prototype,"editingEnabled",void 0);k([A.reader(["portal-item","web-map","web-scene"],"editingEnabled",["capabilities"])],u.prototype,"readEditingEnabled",null);k([A.writer(["portal-item","web-map","web-scene"],"editingEnabled")],
u.prototype,"writeEditingEnabled",null);k([A.property(J.elevationInfo)],u.prototype,"elevationInfo",void 0);k([A.property({types:{key:"type",base:da.default,typeMap:{selection:aa.default}},json:{origins:{"web-scene":{read:{source:"layerDefinition.featureReduction"},write:{target:"layerDefinition.featureReduction"}}}}})],u.prototype,"featureReduction",void 0);k([A.property({type:[la],json:{origins:{service:{read:!0}},read:{source:"layerDefinition.fields"}}})],u.prototype,"fields",void 0);k([A.property({readOnly:!0,
dependsOn:["fields","processing"]})],u.prototype,"fieldsMap",null);k([A.property({type:B,json:{origins:{service:{read:{source:"extent"}}},read:{source:"layerDefinition.extent"}}})],u.prototype,"fullExtent",void 0);k([A.property()],u.prototype,"gdbVersion",void 0);k([A.property({readOnly:!0})],u.prototype,"geometryProperties",void 0);k([A.property({type:"point polygon polyline multipoint multipatch mesh".split(" "),json:{origins:{service:{read:xa.read}},read:{source:"layerDefinition.geometryType",
reader:xa.read}}})],u.prototype,"geometryType",void 0);k([A.property({type:Boolean,json:{origins:{service:{read:!0}},read:{source:"layerDefinition.hasM"}}})],u.prototype,"hasM",void 0);k([A.property({type:Boolean,json:{origins:{service:{read:!0}},read:{source:"layerDefinition.hasZ"}}})],u.prototype,"hasZ",void 0);k([A.property({readOnly:!0,type:F})],u.prototype,"heightModelInfo",void 0);k([A.property({type:Date})],u.prototype,"historicMoment",void 0);k([A.property({json:{origins:{service:{read:!1},
"portal-item":{read:!1}}}})],u.prototype,"id",void 0);k([A.property({readOnly:!0})],u.prototype,"isTable",void 0);k([A.reader("service","isTable",["type"]),A.reader("isTable",["layerDefinition.type"])],u.prototype,"readIsTable",null);k([A.property({dependsOn:["loaded","url","source"],readOnly:!0})],u.prototype,"hasService",null);k([A.property(J.labelsVisible)],u.prototype,"labelsVisible",void 0);k([A.property({type:[ja],json:{origins:{service:{read:{source:"drawingInfo.labelingInfo",reader:ea.reader},
write:{target:"drawingInfo.labelingInfo",enabled:!1}}},read:{source:"layerDefinition.drawingInfo.labelingInfo",reader:ea.reader},write:{target:"layerDefinition.drawingInfo.labelingInfo"}}})],u.prototype,"labelingInfo",void 0);k([A.property({type:Number,json:{origins:{service:{read:{source:"id"}}},read:!1}})],u.prototype,"layerId",void 0);k([A.property(J.legendEnabled)],u.prototype,"legendEnabled",void 0);k([A.property({type:["show","hide"]})],u.prototype,"listMode",void 0);k([A.property({type:Number,
json:{origins:{service:{read:!0}},read:{source:"layerDefinition.maxRecordCount"}}})],u.prototype,"maxRecordCount",void 0);k([A.property({type:Number,json:{origins:{service:{read:!0}},read:{source:"layerDefinition.tileMaxRecordCount"}}})],u.prototype,"tileMaxRecordCount",void 0);k([A.property({type:Number,json:{origins:{service:{write:{enabled:!1}}},read:{source:"layerDefinition.minScale"},write:{target:"layerDefinition.minScale"}}})],u.prototype,"minScale",void 0);k([A.reader("service","minScale",
["minScale","effectiveMinScale"])],u.prototype,"readMinScale",null);k([A.property({type:Number,json:{origins:{service:{write:{enabled:!1}}},read:{source:"layerDefinition.maxScale"},write:{target:"layerDefinition.maxScale"}}})],u.prototype,"maxScale",void 0);k([A.reader("service","maxScale",["maxScale","effectiveMaxScale"])],u.prototype,"readMaxScale",null);k([A.property({type:String})],u.prototype,"objectIdField",void 0);k([A.reader("objectIdField",["layerDefinition.objectIdField","layerDefinition.fields"]),
A.reader("service","objectIdField",["objectIdField","fields"])],u.prototype,"readObjectIdFieldFromService",null);k([A.property({value:"ArcGISFeatureLayer",type:["ArcGISFeatureLayer"]})],u.prototype,"operationalLayerType",void 0);k([A.property()],u.prototype,"outFields",null);k([A.property({readOnly:!0,dependsOn:["layerId"]})],u.prototype,"parsedUrl",null);k([A.property({type:String,json:{origins:{"web-scene":{read:!0,write:!0}},read:!1}})],u.prototype,"path",void 0);k([A.property(J.popupEnabled)],
u.prototype,"popupEnabled",void 0);k([A.property({type:f,json:{read:{source:"popupInfo"},write:{target:"popupInfo"}}})],u.prototype,"popupTemplate",void 0);k([A.property({readOnly:!0,dependsOn:["fields","title"]})],u.prototype,"defaultPopupTemplate",null);k([A.property({type:H})],u.prototype,"processing",void 0);k([A.property({type:[pa],readOnly:!0})],u.prototype,"relationships",void 0);k([A.property({types:n.rendererTypes,json:{origins:{service:{write:{target:"drawingInfo.renderer",enabled:!1}}},
write:{target:"layerDefinition.drawingInfo.renderer"}}})],u.prototype,"renderer",null);k([A.reader("service","renderer",["drawingInfo.renderer","defaultSymbol","type"]),A.reader("renderer",["layerDefinition.drawingInfo.renderer","layerDefinition.defaultSymbol","layerDefinition.type"])],u.prototype,"readRenderer",null);k([A.writer("renderer")],u.prototype,"writeRenderer",null);k([A.property()],u.prototype,"resourceInfo",void 0);k([A.property({type:Boolean})],u.prototype,"returnM",void 0);k([A.property({type:Boolean})],
u.prototype,"returnZ",void 0);k([A.property(J.screenSizePerspectiveEnabled)],u.prototype,"screenSizePerspectiveEnabled",void 0);k([A.property()],u.prototype,"source",null);k([A.cast("source")],u.prototype,"castSource",null);k([A.reader("portal-item","source",["featureSet"]),A.reader("web-map","source",["featureSet"])],u.prototype,"readSource",null);k([A.property({readOnly:!0,json:{origins:{service:{read:{source:"definitionExpression"}}}}})],u.prototype,"serviceDefinitionExpression",void 0);k([A.property({type:C,
json:{origins:{service:{read:{source:"extent.spatialReference"}}},read:{source:"layerDefinition.extent.spatialReference"}}})],u.prototype,"spatialReference",void 0);k([A.property({type:[oa]})],u.prototype,"templates",void 0);k([A.reader("templates",["editFieldsInfo","creatorField","editorField","templates"])],u.prototype,"readTemplates",null);k([A.property()],u.prototype,"timeInfo",void 0);k([A.property()],u.prototype,"title",void 0);k([A.reader("service","title",["name"]),A.reader("portal-item",
"title",["layerDefinition.title","layerDefinition.name","title"])],u.prototype,"readTitle",null);k([A.reader("web-map","title",["layerDefinition.name","title"])],u.prototype,"readTitleFromWebMap",null);k([A.property({type:String})],u.prototype,"sublayerTitleMode",void 0);k([A.property({type:String,json:{read:{source:"timeInfo.trackIdField"}}})],u.prototype,"trackIdField",void 0);k([A.property({json:{read:!1}})],u.prototype,"type",void 0);k([A.property({type:String,readOnly:!0})],u.prototype,"typeIdField",
void 0);k([A.reader("service","typeIdField"),A.reader("typeIdField",["layerDefinition.typeIdField"])],u.prototype,"readTypeIdField",null);k([A.property({type:[ga]})],u.prototype,"types",void 0);k([A.reader("service","types",["types"]),A.reader("types",["layerDefinition.types"])],u.prototype,"readTypes",null);k([A.property({type:t.ofType(fa.FeatureIndex),readOnly:!0})],u.prototype,"indexes",void 0);k([A.property(J.url)],u.prototype,"url",null);k([A.writer("url")],u.prototype,"writeUrl",null);k([A.property({readOnly:!0})],
u.prototype,"userIsAdmin",void 0);k([A.property({json:{origins:{service:{read:!0}},read:!1}})],u.prototype,"version",void 0);k([A.reader("service","version","currentVersion capabilities drawingInfo hasAttachments htmlPopupType relationships timeInfo typeIdField types".split(" "))],u.prototype,"readVersion",null);k([A.property({type:Boolean,json:{origins:{"portal-item":{write:{target:"layerDefinition.defaultVisibility"}}}}})],u.prototype,"visible",void 0);k([A.reader("portal-item","visible",["visibility",
"layerDefinition.defaultVisibility"])],u.prototype,"readVisible",null);k([l(0,A.cast(qa))],u.prototype,"queryAttachments",null);k([l(0,A.cast(wa))],u.prototype,"queryFeatures",null);k([l(0,A.cast(wa))],u.prototype,"queryObjectIds",null);k([l(0,A.cast(wa))],u.prototype,"queryFeatureCount",null);k([l(0,A.cast(wa))],u.prototype,"queryExtent",null);k([l(0,A.cast(Ta))],u.prototype,"queryRelatedFeatures",null);return u=k([A.subclass("esri.layers.FeatureLayer")],u)}(A.declared(E,R,I,M,W,V,y,U))})},"esri/PopupTemplate":function(){define("require exports ./core/tsSupport/assignHelper ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./core/tsSupport/generatorHelper ./core/tsSupport/awaiterHelper @dojo/framework/shim/array @dojo/framework/shim/Set ./core/Collection ./core/JSONSupport ./core/lang ./core/Logger ./core/promiseUtils ./core/accessorSupport/decorators ./core/accessorSupport/ensureType ./layers/support/fieldUtils ./popup/content ./popup/ExpressionInfo ./popup/FieldInfo ./popup/LayerOptions ./popup/RelatedRecordsInfo ./popup/content/AttachmentsContent ./popup/content/Content ./popup/content/FieldsContent ./popup/content/MediaContent ./popup/content/TextContent ./popup/content/support/mediaInfoTypes ./support/actions/ActionBase ./support/actions/ActionButton ./support/actions/ActionToggle".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x,w,A,B,F,C,E,G,Q,V,R){var I=f.ofType({key:"type",defaultKeyValue:"button",base:Q,typeMap:{button:V,toggle:R}}),W={base:B,key:"type",typeMap:{media:C,text:E,attachments:A,fields:F}},M=q.getLogger("esri.PopupTemplate");return function(b){function e(){var a=null!==b&&b.apply(this,arguments)||this;a.actions=null;a.content="";a.expressionInfos=null;a.fieldInfos=null;a.layerOptions=null;a.lastEditInfoEnabled=!0;a.outFields=null;a.overwriteActions=!1;a.title=
"";a.relatedRecordsInfo=null;return a}d(e,b);n=e;e.prototype.castContent=function(a){if(Array.isArray(a))return a.map(function(a){return r.ensureOneOfType(W,a)});if("string"===typeof a||"function"===typeof a||a instanceof HTMLElement||p.isThenable(a))return a;M.error("content error","unsupported content value",{value:a});return null};e.prototype.readContent=function(a,c){var b=c.description,d=c.mediaInfos;a=c.popupElements;c=c.showAttachments;if(Array.isArray(a)&&0<a.length)return a.map(function(a){if("media"===
a.type)return!a.mediaInfos&&d&&(a.mediaInfos=d),C.fromJSON(a);if("text"===a.type)return!a.text&&b&&(a.text=b),E.fromJSON(a);if("attachments"===a.type)return A.fromJSON(a);if("fields"===a.type)return F.fromJSON(a)}).filter(Boolean);a=[];b?a.push(new E({text:b})):a.push(new F);Array.isArray(d)&&d.length&&a.push(C.fromJSON({mediaInfos:d}));c&&a.push(A.fromJSON({displayType:"list"}));return a.length?a:b};e.prototype.writeContent=function(a,c){c.showAttachments=!1;"string"===typeof a?c.description=a:Array.isArray(a)&&
(c.popupElements=a.map(function(a){return a&&a.toJSON()}),c.popupElements.forEach(function(a){"attachments"!==a.type||c.showAttachments?"media"!==a.type||c.mediaInfos?"text"!==a.type||c.description||(a.text&&(c.description=a.text),delete a.text):(a.mediaInfos&&(c.mediaInfos=g.clone(a.mediaInfos)),delete a.mediaInfos):c.showAttachments=!0}))};e.prototype.writeLayerOptions=function(a,c){c.layerOptions=a&&null!==a.showNoDataRecords?a.toJSON():null};e.prototype.writeTitle=function(a,c){c.title=a||""};
e.prototype.clone=function(){var a=this.actions,a=a?g.clone(a.toArray()):[];return new n({actions:a,content:Array.isArray(this.content)?g.clone(this.content):this.content,expressionInfos:Array.isArray(this.expressionInfos)?g.clone(this.expressionInfos):null,fieldInfos:Array.isArray(this.fieldInfos)?g.clone(this.fieldInfos):null,layerOptions:this.layerOptions?g.clone(this.layerOptions):null,lastEditInfoEnabled:this.lastEditInfoEnabled,outFields:Array.isArray(this.outFields)?g.clone(this.outFields):
null,overwriteActions:this.overwriteActions,title:this.title,relatedRecordsInfo:this.relatedRecordsInfo?g.clone(this.relatedRecordsInfo):null})};e.prototype.collectRequiredFields=function(a,c){return h(this,void 0,void 0,function(){return l(this,function(b){switch(b.label){case 0:return[4,this._collectExpressionInfoFields(a,c,this.expressionInfos)];case 1:return b.sent(),v.collectFields(a,c,(this.outFields||[]).concat(this._getActionsFields(this.actions),this._getTitleFields(this.title),this._getContentFields(this.content))),
[2]}})})};e.prototype.getRequiredFields=function(b){return h(this,void 0,void 0,function(){var d;return l(this,function(f){switch(f.label){case 0:return d=new c.default,[4,this.collectRequiredFields(d,b)];case 1:return f.sent(),[2,a.from(d).sort()]}})})};e.prototype._getContentElementFields=function(a){var c=this;if(!a||"attachments"===a.type)return[];if("fields"===a.type)return this._getFieldInfoFields(a.fieldInfos||this.fieldInfos);if("media"===a.type)return(a.mediaInfos||[]).reduce(function(a,
b){return a.concat(c._getMediaInfoFields(b))},[]);if("text"===a.type)return this._extractFieldNames(a.text)};e.prototype._getMediaInfoFields=function(a){var c=a.caption,b=a.value||{},d=b.fields,f=void 0===d?[]:d,d=b.normalizeField,e=b.tooltipField,g=b.sourceURL,b=b.linkURL;a=this._extractFieldNames(a.title).concat(this._extractFieldNames(c),this._extractFieldNames(g),this._extractFieldNames(b),f);d&&a.push(d);e&&a.push(e);return a};e.prototype._getContentFields=function(a){var c=this;return"string"===
typeof a?this._extractFieldNames(a):Array.isArray(a)?a.reduce(function(a,b){return a.concat(c._getContentElementFields(b))},[]):[]};e.prototype._collectExpressionInfoFields=function(a,c,b){return h(this,void 0,void 0,function(){return l(this,function(d){switch(d.label){case 0:return b?[4,p.all(b.map(function(b){return v.collectArcadeFieldNames(a,c,b.expression)}))]:[2];case 1:return d.sent(),[2]}})})};e.prototype._getFieldInfoFields=function(a){return a?a.filter(function(a){return"undefined"===typeof a.visible?
!0:!!a.visible}).map(function(a){return a.fieldName}).filter(function(a){return-1===a.indexOf("relationships/")&&-1===a.indexOf("expression/")}):[]};e.prototype._getActionsFields=function(a){var c=this;return a?a.toArray().reduce(function(a,b){return a.concat(c._getActionFields(b))},[]):[]};e.prototype._getActionFields=function(a){var c=a.className,b=a.type,b="button"===b||"toggle"===b?a.image:"";return this._extractFieldNames(a.title).concat(this._extractFieldNames(c),this._extractFieldNames(b))};
e.prototype._getTitleFields=function(a){return"string"===typeof a?this._extractFieldNames(a):[]};e.prototype._extractFieldNames=function(a){if(!a||"string"!==typeof a)return[];a=a.match(/{[^}]*}/g);if(!a)return[];var c=/\{(\w+):.+\}/;return(a=a.filter(function(a){return!(0===a.indexOf("{relationships/")||0===a.indexOf("{expression/"))}).map(function(a){return a.replace(c,"{$1}")}))?a.map(function(a){return a.slice(1,-1)}):[]};var n;k([t.property({type:I})],e.prototype,"actions",void 0);k([t.property()],
e.prototype,"content",void 0);k([t.cast("content")],e.prototype,"castContent",null);k([t.reader("content",["description","popupElements","mediaInfos","showAttachments"])],e.prototype,"readContent",null);k([t.writer("content",{popupElements:{type:f.ofType(u.types)},showAttachments:{type:Boolean},mediaInfos:{type:f.ofType(G.types)},description:{type:String}})],e.prototype,"writeContent",null);k([t.property({type:[z],json:{write:!0}})],e.prototype,"expressionInfos",void 0);k([t.property({type:[y],json:{write:!0}})],
e.prototype,"fieldInfos",void 0);k([t.property({type:x})],e.prototype,"layerOptions",void 0);k([t.writer("layerOptions")],e.prototype,"writeLayerOptions",null);k([t.property({type:Boolean,json:{read:{source:"showLastEditInfo"},write:{target:"showLastEditInfo"},default:!0}})],e.prototype,"lastEditInfoEnabled",void 0);k([t.property()],e.prototype,"outFields",void 0);k([t.property()],e.prototype,"overwriteActions",void 0);k([t.property({json:{type:String}})],e.prototype,"title",void 0);k([t.writer("title")],
e.prototype,"writeTitle",null);k([t.property({type:w,json:{write:!0}})],e.prototype,"relatedRecordsInfo",void 0);return e=n=k([t.subclass("esri.PopupTemplate")],e)}(t.declared(n))})},"esri/popup/content":function(){define("require exports ./content/AttachmentsContent ./content/Content ./content/FieldsContent ./content/MediaContent ./content/TextContent".split(" "),function(b,e,m,d,k,l,h){Object.defineProperty(e,"__esModule",{value:!0});e.AttachmentsContent=m;e.BaseContent=d;e.FieldsContent=k;e.MediaContent=
l;e.TextContent=h;e.isContent=function(a){return a instanceof e.BaseContent};e.types={base:null,key:"type",typeMap:{attachment:e.AttachmentsContent,fields:e.FieldsContent,media:e.MediaContent,text:e.TextContent}}})},"esri/popup/content/AttachmentsContent":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/lang ../../core/accessorSupport/decorators ../../layers/support/AttachmentInfo ./Content".split(" "),function(b,e,m,d,k,l,
h,a){return function(a){function c(c){c=a.call(this)||this;c.attachmentInfos=null;c.displayType=null;c.type="attachments";return c}m(c,a);b=c;c.prototype.clone=function(){return new b({displayType:this.displayType,attachmentInfos:this.attachmentInfos?k.clone(this.attachmentInfos):null})};var b;d([l.property({type:[h]})],c.prototype,"attachmentInfos",void 0);d([l.property({type:String,json:{write:!0}})],c.prototype,"displayType",void 0);d([l.property({type:String,readOnly:!0,json:{read:!1,write:!0}})],
c.prototype,"type",void 0);return c=b=d([l.subclass("esri.popup.content.AttachmentsContent")],c)}(l.declared(a))})},"esri/layers/support/AttachmentInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators ../../core/accessorSupport/ensureType".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.contentType=null;c.exifInfo=null;c.id=null;c.keywords=
null;c.name=null;c.parentObjectId=null;c.size=null;c.url=null;return c}m(c,a);b=c;c.prototype.clone=function(){return new b({contentType:this.contentType,exifInfo:this.exifInfo,id:this.id,keywords:this.keywords,name:this.name,parentObjectId:this.parentObjectId,size:this.size,url:this.url})};var b;d([l.property({type:String})],c.prototype,"contentType",void 0);d([l.property()],c.prototype,"exifInfo",void 0);d([l.property({type:h.Integer})],c.prototype,"id",void 0);d([l.property({type:String})],c.prototype,
"keywords",void 0);d([l.property({type:String})],c.prototype,"name",void 0);d([l.property({json:{read:!1}})],c.prototype,"parentObjectId",void 0);d([l.property({type:h.Integer})],c.prototype,"size",void 0);d([l.property({json:{read:!1}})],c.prototype,"url",void 0);return c=b=d([l.subclass("esri.layers.support.AttachmentInfo")],c)}(l.declared(k))})},"esri/popup/content/Content":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.type=null;return a}m(a,b);d([l.property({type:["attachments","fields","media","text"],readOnly:!0,json:{read:!1,write:!0}})],a.prototype,"type",void 0);return a=d([l.subclass("esri.popup.content.Content")],a)}(l.declared(k))})},"esri/popup/content/FieldsContent":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/lang ../../core/accessorSupport/decorators ../FieldInfo ./Content".split(" "),
function(b,e,m,d,k,l,h,a){return function(a){function c(c){c=a.call(this)||this;c.fieldInfos=null;c.type="fields";return c}m(c,a);b=c;c.prototype.writeFieldInfos=function(a,c){c.fieldInfos=a&&a.map(function(a){return a.toJSON()})};c.prototype.clone=function(){return new b({fieldInfos:Array.isArray(this.fieldInfos)?k.clone(this.fieldInfos):null})};var b;d([l.property({type:[h]})],c.prototype,"fieldInfos",void 0);d([l.writer("fieldInfos")],c.prototype,"writeFieldInfos",null);d([l.property({type:String,
readOnly:!0,json:{read:!1,write:!0}})],c.prototype,"type",void 0);return c=b=d([l.subclass("esri.popup.content.FieldsContent")],c)}(l.declared(a))})},"esri/popup/FieldInfo":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/kebabDictionary ../core/lang ../core/accessorSupport/decorators ./support/FieldInfoFormat".split(" "),function(b,e,m,d,k,l,h,a,c){var f=new l.default({richtext:"rich-text",textarea:"text-area",
textbox:"text-box"});return function(b){function e(a){a=b.call(this)||this;a.fieldName=null;a.format=null;a.isEditable=!1;a.label=null;a.stringFieldOption="text-box";a.statisticType=null;a.tooltip=null;a.visible=!0;return a}m(e,b);n=e;e.prototype.writeStringFieldOption=function(a,c){c.stringFieldOption=f.toJSON(a)};e.prototype.readStringFieldOption=function(a){if(a)return f.fromJSON(a)};e.prototype.clone=function(){return new n({fieldName:this.fieldName,format:this.format?h.clone(this.format):null,
isEditable:this.isEditable,label:this.label,stringFieldOption:this.stringFieldOption,statisticType:this.statisticType,tooltip:this.tooltip,visible:this.visible})};var n;d([a.property({type:String,json:{write:!0}})],e.prototype,"fieldName",void 0);d([a.property({type:c,json:{write:!0}})],e.prototype,"format",void 0);d([a.property({type:Boolean,json:{write:!0,default:!1}})],e.prototype,"isEditable",void 0);d([a.property({type:String,json:{write:!0}})],e.prototype,"label",void 0);d([a.property({type:f.apiValues,
json:{write:!0,default:"text-box",type:f.jsonValues}})],e.prototype,"stringFieldOption",void 0);d([a.writer("stringFieldOption")],e.prototype,"writeStringFieldOption",null);d([a.reader("stringFieldOption")],e.prototype,"readStringFieldOption",null);d([a.property({type:"count sum min max avg stddev var".split(" "),json:{write:!0}})],e.prototype,"statisticType",void 0);d([a.property({type:String,json:{write:!0}})],e.prototype,"tooltip",void 0);d([a.property({type:Boolean,json:{write:!0}})],e.prototype,
"visible",void 0);return e=n=d([a.subclass("esri.popup.FieldInfo")],e)}(a.declared(k))})},"esri/popup/support/FieldInfoFormat":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/date ../../core/JSONSupport ../../core/accessorSupport/decorators ../../core/accessorSupport/ensureType".split(" "),function(b,e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this)||this;a.dateFormat=null;a.digitSeparator=!1;a.places=null;return a}
m(b,c);e=b;b.prototype.clone=function(){return new e({dateFormat:this.dateFormat,digitSeparator:this.digitSeparator,places:this.places})};var e;d([h.enumeration.serializable()(k.dictionary)],b.prototype,"dateFormat",void 0);d([h.property({type:Boolean,json:{write:!0}})],b.prototype,"digitSeparator",void 0);d([h.property({type:a.Integer,json:{write:!0}})],b.prototype,"places",void 0);return b=e=d([h.subclass("esri.popup.support.FieldInfoFormat")],b)}(h.declared(l))})},"esri/core/date":function(){define(["require",
"exports","./kebabDictionary"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.formats={"short-date":"(datePattern: 'M/d/y', selector: 'date')","short-date-short-time":"(datePattern: 'M/d/y', timePattern: 'h:mm a', selector: 'date and time')","short-date-short-time-24":"(datePattern: 'M/d/y', timePattern: 'H:mm', selector: 'date and time')","short-date-long-time":"(datePattern: 'M/d/y', timePattern: 'h:mm:ss a', selector: 'date and time')","short-date-long-time-24":"(datePattern: 'M/d/y', timePattern: 'H:mm:ss', selector: 'date and time')",
"short-date-le":"(datePattern: 'd/M/y', selector: 'date')","short-date-le-short-time":"(datePattern: 'd/M/y', timePattern: 'h:mm a', selector: 'date and time')","short-date-le-short-time-24":"(datePattern: 'd/M/y', timePattern: 'H:mm', selector: 'date and time')","short-date-le-long-time":"(datePattern: 'd/M/y', timePattern: 'h:mm:ss a', selector: 'date and time')","short-date-le-long-time-24":"(datePattern: 'd/M/y', timePattern: 'H:mm:ss', selector: 'date and time')","long-month-day-year":"(datePattern: 'MMMM d, y', selector: 'date')",
"long-month-day-year-short-time":"(datePattern: 'MMMM d, y', timePattern: 'h:mm a', selector: 'date and time')","long-month-day-year-short-time-24":"(datePattern: 'MMMM d, y', timePattern: 'H:mm', selector: 'date and time')","long-month-day-year-long-time":"(datePattern: 'MMMM d, y', timePattern: 'h:mm:ss a', selector: 'date and time')","long-month-day-year-long-time-24":"(datePattern: 'MMMM d, y', timePattern: 'H:mm:ss', selector: 'date and time')","day-short-month-year":"(datePattern: 'd MMM y', selector: 'date')",
"day-short-month-year-short-time":"(datePattern: 'd MMM y', timePattern: 'h:mm a', selector: 'date and time')","day-short-month-year-short-time-24":"(datePattern: 'd MMM y', timePattern: 'H:mm', selector: 'date and time')","day-short-month-year-long-time":"(datePattern: 'd MMM y', timePattern: 'h:mm:ss a', selector: 'date and time')","day-short-month-year-long-time-24":"(datePattern: 'd MMM y', timePattern: 'H:mm:ss', selector: 'date and time')","long-date":"(datePattern: 'EEEE, MMMM d, y', selector: 'date')",
"long-date-short-time":"(datePattern: 'EEEE, MMMM d, y', timePattern: 'h:mm a', selector: 'date and time')","long-date-short-time-24":"(datePattern: 'EEEE, MMMM d, y', timePattern: 'H:mm', selector: 'date and time')","long-date-long-time":"(datePattern: 'EEEE, MMMM d, y', timePattern: 'h:mm:ss a', selector: 'date and time')","long-date-long-time-24":"(datePattern: 'EEEE, MMMM d, y', timePattern: 'H:mm:ss', selector: 'date and time')","long-month-year":"(datePattern: 'MMMM y', selector: 'date')","short-month-year":"(datePattern: 'MMM y', selector: 'date')",
year:"(datePattern: 'y', selector: 'date')"};e.dictionary=m.strict()({shortDate:"short-date",shortDateShortTime:"short-date-short-time",shortDateShortTime24:"short-date-short-time-24",shortDateLongTime:"short-date-long-time",shortDateLongTime24:"short-date-long-time-24",shortDateLE:"short-date-le",shortDateLEShortTime:"short-date-le-short-time",shortDateLEShortTime24:"short-date-le-short-time-24",shortDateLELongTime:"short-date-le-long-time",shortDateLELongTime24:"short-date-le-long-time-24",longMonthDayYear:"long-month-day-year",
longMonthDayYearShortTime:"long-month-day-year-short-time",longMonthDayYearShortTime24:"long-month-day-year-short-time-24",longMonthDayYearLongTime:"long-month-day-year-long-time",longMonthDayYearLongTime24:"long-month-day-year-long-time-24",dayShortMonthYear:"day-short-month-year",dayShortMonthYearShortTime:"day-short-month-year-short-time",dayShortMonthYearShortTime24:"day-short-month-year-short-time-24",dayShortMonthYearLongTime:"day-short-month-year-long-time",dayShortMonthYearLongTime24:"day-short-month-year-long-time-24",
longDate:"long-date",longDateShortTime:"long-date-short-time",longDateShortTime24:"long-date-short-time-24",longDateLongTime:"long-date-long-time",longDateLongTime24:"long-date-long-time-24",longMonthYear:"long-month-year",shortMonthYear:"short-month-year",year:"year"});e.toJSON=e.dictionary.toJSON.bind(e.dictionary);e.fromJSON=e.dictionary.fromJSON.bind(e.dictionary);e.getFormat=function(b){return e.formats[b]}})},"esri/popup/content/MediaContent":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/lang ../../core/accessorSupport/decorators ./BarChartMediaInfo ./ColumnChartMediaInfo ./Content ./ImageMediaInfo ./LineChartMediaInfo ./PieChartMediaInfo ./support/mediaInfoTypes".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q){return function(c){function b(a){a=c.call(this)||this;a.mediaInfos=null;a.type="media";return a}m(b,c);e=b;b.prototype.readMediaInfos=function(c){return c&&c.map(function(c){if("image"===c.type)return f.fromJSON(c);if("barchart"===c.type)return h.fromJSON(c);if("columnchart"===c.type)return a.fromJSON(c);if("linechart"===c.type)return n.fromJSON(c);if("piechart"===c.type)return g.fromJSON(c)}).filter(Boolean)};b.prototype.writeMediaInfos=function(a,c){c.mediaInfos=
a&&a.map(function(a){return a.toJSON()})};b.prototype.clone=function(){return new e({mediaInfos:this.mediaInfos?k.clone(this.mediaInfos):null})};var e;d([l.property({types:[q.types]})],b.prototype,"mediaInfos",void 0);d([l.reader("mediaInfos")],b.prototype,"readMediaInfos",null);d([l.writer("mediaInfos")],b.prototype,"writeMediaInfos",null);d([l.property({type:String,readOnly:!0,json:{read:!1,write:!0}})],b.prototype,"type",void 0);return b=e=d([l.subclass("esri.popup.content.MediaContent")],b)}(l.declared(c))})},
"esri/popup/content/BarChartMediaInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./mixins/ChartMediaInfo ./support/chartMediaInfoUtils".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.type="bar-chart";return c}m(c,a);b=c;c.prototype.clone=function(){return new b({title:this.title,caption:this.caption,value:this.value?this.value.clone():null})};var b;
d([k.property({type:["bar-chart"],readOnly:!0,json:{read:!1,write:h.chartTypeKebabDict.write}})],c.prototype,"type",void 0);return c=b=d([k.subclass("esri.popup.content.BarChartMediaInfo")],c)}(k.declared(l))})},"esri/popup/content/mixins/ChartMediaInfo":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/accessorSupport/decorators ./MediaInfo ../support/ChartMediaInfoValue".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=
a.call(this)||this;c.type=null;c.value=null;return c}m(c,a);d([k.property({type:["bar-chart","column-chart","line-chart","pie-chart"],readOnly:!0,json:{read:!1,write:!0}})],c.prototype,"type",void 0);d([k.property({type:h,json:{write:!0}})],c.prototype,"value",void 0);return c=d([k.subclass("esri.popup.content.mixins.ChartMediaInfo")],c)}(k.declared(l))})},"esri/popup/content/mixins/MediaInfo":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/JSONSupport ../../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.caption="";a.title="";a.type=null;return a}m(a,b);d([l.property({type:String,json:{write:!0}})],a.prototype,"caption",void 0);d([l.property({type:String,json:{write:!0}})],a.prototype,"title",void 0);d([l.property({type:["image","bar-chart","column-chart","line-chart","pie-chart"],readOnly:!0,json:{read:!1,write:!0}})],a.prototype,"type",void 0);return a=d([l.subclass("esri.popup.content.mixins.MediaInfo")],a)}(l.declared(k))})},
"esri/popup/content/support/ChartMediaInfoValue":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/JSONSupport ../../../core/lang ../../../core/accessorSupport/decorators ./ChartMediaInfoValueSeries".split(" "),function(b,e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this)||this;a.fields=[];a.normalizeField=null;a.series=[];a.tooltipField=null;return a}m(b,c);e=b;b.prototype.clone=function(){return new e({fields:l.clone(this.fields),
normalizeField:this.normalizeField,tooltipField:this.tooltipField})};var e;d([h.property({type:[String],json:{write:!0}})],b.prototype,"fields",void 0);d([h.property({type:String,json:{write:!0}})],b.prototype,"normalizeField",void 0);d([h.property({type:[a],json:{read:!1}})],b.prototype,"series",void 0);d([h.property({type:String,json:{write:!0}})],b.prototype,"tooltipField",void 0);return b=e=d([h.subclass("esri.popup.content.support.ChartMediaInfoValue")],b)}(h.declared(k))})},"esri/popup/content/support/ChartMediaInfoValueSeries":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/Accessor ../../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.tooltip=null;a.x=null;a.y=null;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({tooltip:this.tooltip,x:this.x,y:this.y})};var c;d([l.property()],a.prototype,"tooltip",void 0);d([l.property()],a.prototype,"x",void 0);d([l.property()],a.prototype,"y",void 0);return a=c=d([l.subclass("esri.popup.content.support.ChartMediaInfoValueSeries")],a)}(l.declared(k))})},"esri/popup/content/support/chartMediaInfoUtils":function(){define(["require",
"exports","../../../core/kebabDictionary"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.chartTypeKebabDict=m.strict()({barchart:"bar-chart",columnchart:"column-chart",linechart:"line-chart",piechart:"pie-chart"})})},"esri/popup/content/ColumnChartMediaInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./mixins/ChartMediaInfo ./support/chartMediaInfoUtils".split(" "),function(b,
e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.type="column-chart";return c}m(c,a);b=c;c.prototype.clone=function(){return new b({title:this.title,caption:this.caption,value:this.value?this.value.clone():null})};var b;d([k.property({type:["column-chart"],readOnly:!0,json:{read:!1,write:h.chartTypeKebabDict.write}})],c.prototype,"type",void 0);return c=b=d([k.subclass("esri.popup.content.ColumnChartMediaInfo")],c)}(k.declared(l))})},"esri/popup/content/ImageMediaInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./mixins/MediaInfo ./support/ImageMediaInfoValue".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.refreshInterval=null;c.type="image";c.value=null;return c}m(c,a);b=c;c.prototype.clone=function(){return new b({title:this.title,caption:this.caption,refreshInterval:this.refreshInterval,value:this.value?this.value.clone():null})};var b;d([k.property({type:Number,json:{write:!0}})],c.prototype,"refreshInterval",void 0);d([k.property({type:["image"],readOnly:!0,json:{read:!1,write:!0}})],c.prototype,"type",void 0);d([k.property({type:h,
json:{write:!0}})],c.prototype,"value",void 0);return c=b=d([k.subclass("esri.popup.content.ImageMediaInfo")],c)}(k.declared(l))})},"esri/popup/content/support/ImageMediaInfoValue":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/JSONSupport ../../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.linkURL=null;a.sourceURL=null;return a}m(a,b);
c=a;a.prototype.clone=function(){return new c({linkURL:this.linkURL,sourceURL:this.sourceURL})};var c;d([l.property({type:String,json:{write:!0}})],a.prototype,"linkURL",void 0);d([l.property({type:String,json:{write:!0}})],a.prototype,"sourceURL",void 0);return a=c=d([l.subclass("esri.popup.content.support.ImageMediaInfoValue")],a)}(l.declared(k))})},"esri/popup/content/LineChartMediaInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./mixins/ChartMediaInfo ./support/chartMediaInfoUtils".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.type="line-chart";return c}m(c,a);b=c;c.prototype.clone=function(){return new b({title:this.title,caption:this.caption,value:this.value?this.value.clone():null})};var b;d([k.property({type:["line-chart"],readOnly:!0,json:{read:!1,write:h.chartTypeKebabDict.write}})],c.prototype,"type",void 0);return c=b=d([k.subclass("esri.popup.content.LineChartMediaInfo")],c)}(k.declared(l))})},"esri/popup/content/PieChartMediaInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./mixins/ChartMediaInfo ./support/chartMediaInfoUtils".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.type="pie-chart";return c}m(c,a);b=c;c.prototype.clone=function(){return new b({title:this.title,caption:this.caption,value:this.value?this.value.clone():null})};var b;d([k.property({type:["pie-chart"],readOnly:!0,json:{read:!1,write:h.chartTypeKebabDict.write}})],c.prototype,"type",void 0);return c=b=d([k.subclass("esri.popup.content.PieChartMediaInfo")],c)}(k.declared(l))})},"esri/popup/content/support/mediaInfoTypes":function(){define("require exports ../BarChartMediaInfo ../ColumnChartMediaInfo ../ImageMediaInfo ../LineChartMediaInfo ../PieChartMediaInfo ../mixins/MediaInfo".split(" "),
function(b,e,m,d,k,l,h,a){Object.defineProperty(e,"__esModule",{value:!0});e.types={base:a,key:"type",defaultKeyValue:"image",typeMap:{"bar-chart":m,"column-chart":d,"line-chart":l,"pie-chart":h,image:k}};e.default=e.types})},"esri/popup/content/TextContent":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./Content".split(" "),function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||
this;a.text=null;a.type="text";return a}m(a,b);c=a;a.prototype.clone=function(){return new c({text:this.text})};var c;d([k.property({type:String,json:{write:!0}})],a.prototype,"text",void 0);d([k.property({type:String,readOnly:!0,json:{read:!1,write:!0}})],a.prototype,"type",void 0);return a=c=d([k.subclass("esri.popup.content.TextContent")],a)}(k.declared(l))})},"esri/popup/ExpressionInfo":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.name=null;a.title=null;a.expression=null;a.returnType=null;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({name:this.name,title:this.title,expression:this.expression,returnType:this.returnType})};var c;d([l.property({type:String,json:{write:!0}})],a.prototype,"name",void 0);d([l.property({type:String,json:{write:!0}})],a.prototype,"title",void 0);d([l.property({type:String,json:{write:!0}})],a.prototype,"expression",
void 0);d([l.property({type:["string","number"],json:{write:!0}})],a.prototype,"returnType",void 0);return a=c=d([l.subclass("esri.popup.ExpressionInfo")],a)}(l.declared(k))})},"esri/popup/LayerOptions":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.showNoDataRecords=null;return a}m(a,b);c=a;a.prototype.clone=
function(){return new c({showNoDataRecords:this.showNoDataRecords})};var c;d([l.property({type:Boolean,json:{write:!0}})],a.prototype,"showNoDataRecords",void 0);return a=c=d([l.subclass("esri.popup.LayerOptions")],a)}(l.declared(k))})},"esri/popup/RelatedRecordsInfo":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/lang ../core/accessorSupport/decorators ./support/RelatedRecordsInfoFieldOrder".split(" "),function(b,
e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this)||this;a.showRelatedRecords=null;a.orderByFields=null;return a}m(b,c);e=b;b.prototype.clone=function(){return new e({showRelatedRecords:this.showRelatedRecords,orderByFields:this.orderByFields?l.clone(this.orderByFields):null})};var e;d([h.property({type:Boolean,json:{write:!0}})],b.prototype,"showRelatedRecords",void 0);d([h.property({type:[a],json:{write:!0}})],b.prototype,"orderByFields",void 0);return b=e=d([h.subclass("esri.popup.RelatedRecordsInfo")],
b)}(h.declared(k))})},"esri/popup/support/RelatedRecordsInfoFieldOrder":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.field=null;a.order=null;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({field:this.field,order:this.order})};var c;d([l.property({type:String,json:{write:!0}})],
a.prototype,"field",void 0);d([l.property({type:["asc","desc"],json:{write:!0}})],a.prototype,"order",void 0);return a=c=d([l.subclass("esri.popup.support.RelatedRecordsInfoFieldOrder")],a)}(l.declared(k))})},"esri/support/actions/ActionBase":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/Identifiable ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=
a.call(this)||this;c.active=!1;c.className=null;c.disabled=!1;c.id=null;c.indicator=!1;c.title=null;c.type=null;c.visible=!0;return c}m(c,a);b=c;c.prototype.clone=function(){return new b({active:this.active,className:this.className,disabled:this.disabled,id:this.id,indicator:this.indicator,title:this.title,visible:this.visible})};var b;d([h.property()],c.prototype,"active",void 0);d([h.property()],c.prototype,"className",void 0);d([h.property()],c.prototype,"disabled",void 0);d([h.property()],c.prototype,
"id",void 0);d([h.property()],c.prototype,"indicator",void 0);d([h.property()],c.prototype,"title",void 0);d([h.property()],c.prototype,"type",void 0);d([h.property()],c.prototype,"visible",void 0);return c=b=d([h.subclass("esri.support.actions.ActionBase")],c)}(h.declared(k,l.Identifiable))})},"esri/support/actions/ActionButton":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./ActionBase".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.image=null;a.type="button";return a}m(a,b);c=a;a.prototype.clone=function(){return new c({active:this.active,className:this.className,disabled:this.disabled,id:this.id,indicator:this.indicator,title:this.title,visible:this.visible,image:this.image})};var c;d([k.property()],a.prototype,"image",void 0);return a=c=d([k.subclass("esri.support.Action.ActionButton")],a)}(k.declared(l))})},"esri/support/actions/ActionToggle":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./ActionBase".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.image=null;a.type="toggle";a.value=!1;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({active:this.active,className:this.className,disabled:this.disabled,id:this.id,indicator:this.indicator,title:this.title,visible:this.visible,image:this.image,value:this.value})};var c;d([k.property()],a.prototype,"image",void 0);d([k.property()],a.prototype,"value",void 0);return a=c=d([k.subclass("esri.support.Action.ActionToggle")],
a)}(k.declared(l))})},"esri/renderers":function(){define("require exports ./renderers/ClassBreaksRenderer ./renderers/DotDensityRenderer ./renderers/HeatmapRenderer ./renderers/Renderer ./renderers/SimpleRenderer ./renderers/StretchRenderer ./renderers/UniqueValueRenderer ./renderers/support/jsonUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f){Object.defineProperty(e,"__esModule",{value:!0});e.ClassBreaksRenderer=m;e.DotDensityRenderer=d;e.HeatmapRenderer=k;e.BaseRenderer=l;e.SimpleRenderer=h;e.StretchRenderer=
a;e.UniqueValueRenderer=c;e.isRenderer=function(a){return a instanceof e.BaseRenderer};e.read=f.read;e.write=f.write;e.fromJSON=f.fromJSON;e.rendererTypes={key:"type",base:e.BaseRenderer,typeMap:{heatmap:e.HeatmapRenderer,simple:e.SimpleRenderer,"unique-value":e.UniqueValueRenderer,"class-breaks":e.ClassBreaksRenderer,"dot-density":e.DotDensityRenderer}}})},"esri/renderers/ClassBreaksRenderer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/paramHelper ../core/tsSupport/generatorHelper ../core/tsSupport/awaiterHelper ../symbols ../symbols ../core/kebabDictionary ../core/lang ../core/Logger ../core/accessorSupport/decorators ../core/accessorSupport/ensureType ../layers/support/fieldUtils ./Renderer ./mixins/VisualVariablesRenderer ./support/ClassBreakInfo ./support/LegendOptions ../support/arcadeUtils ../symbols/support/jsonUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x){var w=g.getLogger("esri.renderers.ClassBreaksRenderer"),A=new f.default({esriNormalizeByLog:"log",esriNormalizeByPercentOfTotal:"percent-of-total",esriNormalizeByField:"field"}),B=p.ensureType(u.ClassBreakInfo);return function(b){function f(a){a=b.call(this)||this;a.backgroundFillSymbol=null;a.classBreakInfos=null;a.defaultLabel=null;a.defaultSymbol=null;a.field=null;a.isMaxInclusive=!0;a.legendOptions=null;a.normalizationField=null;a.normalizationTotal=
null;a.type="class-breaks";a.valueExpression=null;a.valueExpressionTitle=null;a._set("classBreakInfos",[]);return a}m(f,b);e=f;f.prototype.readClassBreakInfos=function(a,c,b){if(Array.isArray(a)){var d=c.minValue;return a.map(function(a){var c=new u.ClassBreakInfo;c.read(a,b);null==c.minValue&&(c.minValue=d);null==c.maxValue&&(c.maxValue=c.minValue);d=c.maxValue;return c})}};f.prototype.writeClassBreakInfos=function(a,c,b,d){a=a.map(function(a){return a.write({},d)});this._areClassBreaksConsecutive()&&
a.forEach(function(a){return delete a.classMinValue});c[b]=a};Object.defineProperty(f.prototype,"compiledFunc",{get:function(){return y.createFunction(this.valueExpression)},enumerable:!0,configurable:!0});f.prototype.readDefaultSymbol=function(a,c,b){return x.read(a,c,b)};f.prototype.writeDefaultSymbolWebScene=function(a,c,b,d){x.writeTarget(a,c,b,d)};f.prototype.writeDefaultSymbol=function(a,c,b,d){x.writeTarget(a,c,b,d)};f.prototype.castField=function(a){return null==a?a:"function"===typeof a?
(w.error(".field: field must be a string value"),null):p.ensureString(a)};Object.defineProperty(f.prototype,"minValue",{get:function(){return this.classBreakInfos&&this.classBreakInfos[0]&&this.classBreakInfos[0].minValue||0},enumerable:!0,configurable:!0});Object.defineProperty(f.prototype,"normalizationType",{get:function(){var a=this._get("normalizationType"),c=!!this.normalizationField,b=null!=this.normalizationTotal;if(c||b)a=c&&"field"||b&&"percent-of-total"||null,c&&b&&w.warn("warning: both normalizationField and normalizationTotal are set!");
else if("field"===a||"percent-of-total"===a)a=null;return a},set:function(a){this._set("normalizationType",a)},enumerable:!0,configurable:!0});f.prototype.addClassBreakInfo=function(a,c,b){var d=null,d="number"===typeof a?new u.ClassBreakInfo({minValue:a,maxValue:c,symbol:b}):B(n.clone(a));this.classBreakInfos.push(d);1===this.classBreakInfos.length&&this.notifyChange("minValue")};f.prototype.removeClassBreakInfo=function(a,c){for(var b=this.classBreakInfos.length,d=0;d<b;d++){var f=[this.classBreakInfos[d].minValue,
this.classBreakInfos[d].maxValue];if(f[0]===a&&f[1]===c){this.classBreakInfos.splice(d,1);break}}};f.prototype.getBreakIndex=function(a,c){var b=this.field,d=a.attributes,f=this.isMaxInclusive,e=null;if(this.valueExpression)e=y.executeFunction(this.compiledFunc,y.createExecContext(a,y.getViewInfo(c)));else if(e=parseFloat(d[b]),a=this.normalizationType)if(c=this.normalizationTotal,d=parseFloat(d[this.normalizationField]),"log"===a)e=Math.log(e)*Math.LOG10E;else if("percent-of-total"===a&&!isNaN(c))e=
e/c*100;else if("field"===a&&!isNaN(d)){if(isNaN(e)||isNaN(d))return-1;e/=d}if(null!=e&&"number"===typeof e&&!isNaN(e))for(d=0;d<this.classBreakInfos.length;d++)if(a=[this.classBreakInfos[d].minValue,this.classBreakInfos[d].maxValue],a[0]<=e&&(f?e<=a[1]:e<a[1]))return d;return-1};f.prototype.getClassBreakInfo=function(a,c){a=this.getBreakIndex(a,c);return-1!==a?this.classBreakInfos[a]:null};f.prototype.getSymbol=function(a,c){a=this.getBreakIndex(a,c);return-1<a?this.classBreakInfos[a].symbol:this.defaultSymbol};
f.prototype.getSymbols=function(){var a=[];this.classBreakInfos.forEach(function(c){c.symbol&&a.push(c.symbol)});this.defaultSymbol&&a.push(this.defaultSymbol);return a};f.prototype.clone=function(){return new e({field:this.field,backgroundFillSymbol:this.backgroundFillSymbol&&this.backgroundFillSymbol.clone(),defaultLabel:this.defaultLabel,defaultSymbol:this.defaultSymbol&&this.defaultSymbol.clone(),valueExpression:this.valueExpression,valueExpressionTitle:this.valueExpressionTitle,classBreakInfos:n.clone(this.classBreakInfos),
isMaxInclusive:this.isMaxInclusive,normalizationField:this.normalizationField,normalizationTotal:this.normalizationTotal,normalizationType:this.normalizationType,visualVariables:n.clone(this.visualVariables),legendOptions:n.clone(this.legendOptions),authoringInfo:this.authoringInfo&&this.authoringInfo.clone()})};f.prototype.collectRequiredFields=function(a,c){return h(this,void 0,void 0,function(){return l(this,function(b){switch(b.label){case 0:return[4,this.collectVVRequiredFields(a,c)];case 1:return b.sent(),
t.collectField(a,c,this.field),t.collectField(a,c,this.normalizationField),[4,t.collectArcadeFieldNames(a,c,this.valueExpression)];case 2:return b.sent(),[2]}})})};f.prototype._areClassBreaksConsecutive=function(){for(var a=this.classBreakInfos,c=a.length,b=1;b<c;b++)if(a[b-1].maxValue!==a[b].minValue)return!1;return!0};var e;d([q.property({types:{base:a.BaseSymbol,key:"type",typeMap:{"simple-fill":c.symbolTypesRenderer.typeMap["simple-fill"],"picture-fill":c.symbolTypesRenderer.typeMap["picture-fill"],
"polygon-3d":c.symbolTypesRenderer.typeMap["polygon-3d"]}},json:{origins:{"web-scene":{read:x.read,write:{target:{backgroundFillSymbol:{type:a.PolygonSymbol3D}},writer:x.writeTarget}}},read:x.read,write:x.writeTarget}})],f.prototype,"backgroundFillSymbol",void 0);d([q.property({type:[u.ClassBreakInfo]})],f.prototype,"classBreakInfos",void 0);d([q.reader("classBreakInfos")],f.prototype,"readClassBreakInfos",null);d([q.writer("classBreakInfos")],f.prototype,"writeClassBreakInfos",null);d([q.property({dependsOn:["valueExpression"]})],
f.prototype,"compiledFunc",null);d([q.property({type:String,json:{write:!0}})],f.prototype,"defaultLabel",void 0);d([q.property({types:c.symbolTypesRenderer})],f.prototype,"defaultSymbol",void 0);d([q.reader("defaultSymbol")],f.prototype,"readDefaultSymbol",null);d([q.writer("web-scene","defaultSymbol",{defaultSymbol:{types:c.symbolTypesRenderer3D}})],f.prototype,"writeDefaultSymbolWebScene",null);d([q.writer("defaultSymbol")],f.prototype,"writeDefaultSymbol",null);d([q.property({type:String,json:{write:!0}})],
f.prototype,"field",void 0);d([q.cast("field")],f.prototype,"castField",null);d([q.property({type:Boolean})],f.prototype,"isMaxInclusive",void 0);d([q.property({type:z.default,json:{write:!0}})],f.prototype,"legendOptions",void 0);d([q.property({type:Number,readOnly:!0,value:null,dependsOn:["classBreakInfos"],json:{read:!1,write:{overridePolicy:function(){return 0!==this.classBreakInfos.length&&this._areClassBreaksConsecutive()?{enabled:!0}:{enabled:!1}}}}})],f.prototype,"minValue",null);d([q.property({type:String,
json:{write:!0}})],f.prototype,"normalizationField",void 0);d([q.property({type:Number,cast:function(a){return p.ensureNumber(a)},json:{write:!0}})],f.prototype,"normalizationTotal",void 0);d([q.property({type:A.apiValues,value:null,dependsOn:["normalizationField","normalizationTotal"],json:{type:A.jsonValues,read:A.read,write:A.write}})],f.prototype,"normalizationType",null);d([q.enumeration.serializable()({classBreaks:"class-breaks"})],f.prototype,"type",void 0);d([q.property({type:String,json:{write:!0}})],
f.prototype,"valueExpression",void 0);d([q.property({type:String,json:{write:!0}})],f.prototype,"valueExpressionTitle",void 0);d([k(2,q.cast(c.ensureType))],f.prototype,"addClassBreakInfo",null);return f=e=d([q.subclass("esri.renderers.ClassBreaksRenderer")],f)}(q.declared(r,v))})},"esri/symbols":function(){define("require exports ./core/accessorSupport/ensureType ./symbols/CIMSymbol ./symbols/ExtrudeSymbol3DLayer ./symbols/FillSymbol ./symbols/FillSymbol3DLayer ./symbols/Font ./symbols/IconSymbol3DLayer ./symbols/LabelSymbol3D ./symbols/LineSymbol3D ./symbols/LineSymbol3DLayer ./symbols/MarkerSymbol ./symbols/MeshSymbol3D ./symbols/ObjectSymbol3DLayer ./symbols/PathSymbol3DLayer ./symbols/PictureFillSymbol ./symbols/PictureMarkerSymbol ./symbols/PointSymbol3D ./symbols/PolygonSymbol3D ./symbols/SimpleFillSymbol ./symbols/SimpleLineSymbol ./symbols/SimpleMarkerSymbol ./symbols/Symbol ./symbols/Symbol3D ./symbols/Symbol3DLayer ./symbols/TextSymbol ./symbols/TextSymbol3DLayer ./symbols/WebStyleSymbol ./symbols/callouts/LineCallout3D ./symbols/callouts/LineCallout3DBorder ./symbols/support/Symbol3DVerticalOffset ./symbols/support/jsonUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x,w,A,B,F,C,E,G,Q,V,R,I,W){Object.defineProperty(e,"__esModule",{value:!0});e.CIMSymbol=d;e.ExtrudeSymbol3DLayer=k;e.BaseFillSymbol=l;e.FillSymbol3DLayer=h;e.Font=a;e.IconSymbol3DLayer=c;e.LabelSymbol3D=f;e.LineSymbol3D=n;e.LineSymbol3DLayer=g;e.BaseMarkerSymbol=q;e.MeshSymbol3D=p;e.ObjectSymbol3DLayer=t;e.PathSymbol3DLayer=r;e.PictureFillSymbol=v;e.PictureMarkerSymbol=u;e.PointSymbol3D=z;e.PolygonSymbol3D=y;e.SimpleFillSymbol=x;e.SimpleLineSymbol=
w;e.SimpleMarkerSymbol=A;e.BaseSymbol=B;e.BaseSymbol3D=F;e.BaseSymbol3DLayer=C;e.TextSymbol=E;e.TextSymbol3DLayer=G;e.WebStyleSymbol=Q;e.LineCallout3D=V;e.LineCallout3DBorder=R;e.Symbol3DVerticalOffset=I.Symbol3DVerticalOffset;e.fromJSON=W.fromJSON;e.isSymbol=function(a){return a instanceof e.BaseSymbol};e.isSymbol2D=function(a){if(!a)return!1;switch(a.type){case "picture-fill":case "picture-marker":case "simple-fill":case "simple-line":case "simple-marker":case "text":case "cim":return!0;default:return!1}};
e.isSymbol3D=function(a){if(!a)return!1;switch(a.type){case "label-3d":case "line-3d":case "mesh-3d":case "point-3d":case "polygon-3d":return!0;default:return!1}};e.symbolTypes={base:e.BaseSymbol,key:"type",typeMap:{"simple-fill":e.SimpleFillSymbol,"picture-fill":e.PictureFillSymbol,"picture-marker":e.PictureMarkerSymbol,"simple-line":e.SimpleLineSymbol,"simple-marker":e.SimpleMarkerSymbol,text:e.TextSymbol,"label-3d":e.LabelSymbol3D,"line-3d":e.LineSymbol3D,"mesh-3d":e.MeshSymbol3D,"point-3d":e.PointSymbol3D,
"polygon-3d":e.PolygonSymbol3D,"web-style":e.WebStyleSymbol,cim:e.CIMSymbol}};e.symbolTypesRenderer={base:e.BaseSymbol,key:"type",typeMap:{"simple-fill":e.SimpleFillSymbol,"picture-fill":e.PictureFillSymbol,"picture-marker":e.PictureMarkerSymbol,"simple-line":e.SimpleLineSymbol,"simple-marker":e.SimpleMarkerSymbol,text:e.TextSymbol,"line-3d":e.LineSymbol3D,"mesh-3d":e.MeshSymbol3D,"point-3d":e.PointSymbol3D,"polygon-3d":e.PolygonSymbol3D,"web-style":e.WebStyleSymbol,cim:e.CIMSymbol}};e.symbolTypesLabel=
{base:e.BaseSymbol,key:"type",typeMap:{text:e.TextSymbol,"label-3d":e.LabelSymbol3D}};e.symbolTypes3D={base:e.BaseSymbol,key:"type",typeMap:{"label-3d":e.LabelSymbol3D,"line-3d":e.LineSymbol3D,"mesh-3d":e.MeshSymbol3D,"point-3d":e.PointSymbol3D,"polygon-3d":e.PolygonSymbol3D,"web-style":e.WebStyleSymbol}};e.symbolTypesRenderer3D={base:e.BaseSymbol,key:"type",typeMap:{"line-3d":e.LineSymbol3D,"mesh-3d":e.MeshSymbol3D,"point-3d":e.PointSymbol3D,"polygon-3d":e.PolygonSymbol3D,"web-style":e.WebStyleSymbol}};
e.symbolTypesLabel3D={base:e.BaseSymbol,key:"type",typeMap:{"label-3d":e.LabelSymbol3D}};e.ensureType=m.ensureOneOfType(e.symbolTypes)})},"esri/symbols/CIMSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/accessorSupport/decorators ../portal/Portal ./Symbol".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this,c)||this;c.data=null;c.portal=null;c.styleName="";c.styleUrl="";c.type="cim";return c}m(c,
a);b=c;c.prototype.readData=function(a,c){return c.data?c.data:c};c.prototype.clone=function(){return new b({color:this.color,data:this.data,portal:this.portal,styleName:this.styleName,styleUrl:this.styleUrl})};var b;d([k.property({json:{write:!1}})],c.prototype,"color",void 0);d([k.property({json:{write:!0}})],c.prototype,"data",void 0);d([k.reader("data",["data","symbol"])],c.prototype,"readData",null);d([k.property({type:l,json:{write:!1}})],c.prototype,"portal",void 0);d([k.property({type:String,
json:{write:!0}})],c.prototype,"styleName",void 0);d([k.property({type:String,json:{write:!0}})],c.prototype,"styleUrl",void 0);d([k.property({type:String,readOnly:!0})],c.prototype,"type",void 0);return c=b=d([k.subclass("esri.symbols.CIMSymbol")],c)}(k.declared(h))})},"esri/symbols/Symbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../Color ../core/JSONSupport ../core/kebabDictionary ../core/accessorSupport/decorators".split(" "),function(b,
e,m,d,k,l,h,a){var c=new h.default({esriSMS:"simple-marker",esriPMS:"picture-marker",esriSLS:"simple-line",esriSFS:"simple-fill",esriPFS:"picture-fill",esriTS:"text",esriSHD:"shield-label-symbol",PointSymbol3D:"point-3d",LineSymbol3D:"line-3d",PolygonSymbol3D:"polygon-3d",MeshSymbol3D:"mesh-3d",LabelSymbol3D:"label-3d",CIMSymbolReference:"cim"}),f=0;return function(b){function e(a){a=b.call(this,a)||this;a.id="sym"+f++;a.type=null;return a}m(e,b);Object.defineProperty(e.prototype,"color",{set:function(a){this._set("color",
a)},enumerable:!0,configurable:!0});e.prototype.readColor=function(a,c,b){return a&&null!=a[0]?[a[0],a[1],a[2],a[3]/255]:a};e.prototype.clone=function(){};d([a.property({type:c.apiValues,json:{read:c.read,write:{ignoreOrigin:!0,writer:c.write}}})],e.prototype,"type",void 0);d([a.property({type:k,value:new k([0,0,0,1]),json:{write:{allowNull:!0}}})],e.prototype,"color",null);d([a.reader("color")],e.prototype,"readColor",null);return e=d([a.subclass("esri.symbols.Symbol")],e)}(a.declared(l))})},"esri/symbols/ExtrudeSymbol3DLayer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/accessorSupport/decorators ./Symbol3DLayer ./edges/utils".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.type="extrude";c.size=void 0;c.material=null;c.castShadows=!0;c.edges=null;return c}m(c,a);b=c;c.prototype.clone=function(){return new b({edges:this.edges&&this.edges.clone(),enabled:this.enabled,elevationInfo:this.elevationInfo&&this.elevationInfo.clone(),material:this.material&&this.material.clone(),castShadows:this.castShadows,size:this.size})};var b;d([k.enumeration.serializable()({Extrude:"extrude"})],c.prototype,
"type",void 0);d([k.property({type:Number,json:{write:!0}})],c.prototype,"size",void 0);d([k.property()],c.prototype,"material",void 0);d([k.property({type:Boolean,nonNullable:!0,json:{write:!0,default:!0}})],c.prototype,"castShadows",void 0);d([k.property(h.symbol3dEdgesProperty)],c.prototype,"edges",void 0);return c=b=d([k.subclass("esri.symbols.ExtrudeSymbol3DLayer")],c)}(k.declared(l))})},"esri/symbols/Symbol3DLayer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/kebabDictionary ../core/accessorSupport/decorators ./support/ElevationInfo ./support/Symbol3DMaterial".split(" "),
function(b,e,m,d,k,l,h,a,c){var f=l.strict()({Icon:"icon",Object:"object",Line:"line",Path:"path",Fill:"fill",Extrude:"extrude",Text:"text"});b=function(b){function e(a){a=b.call(this)||this;a.enabled=!0;a.material=null;a.type=null;return a}m(e,b);e.prototype.writeEnabled=function(a,c,b){a||(c[b]=a)};d([h.property({type:Boolean,json:{read:{source:"enable"},write:{target:"enable"}}})],e.prototype,"enabled",void 0);d([h.writer("enabled")],e.prototype,"writeEnabled",null);d([h.property({type:a,json:{read:!1,
write:!1}})],e.prototype,"elevationInfo",void 0);d([h.property({type:c.default,json:{write:!0}})],e.prototype,"material",void 0);d([h.property({type:f.apiValues,readOnly:!0,json:{read:!1,write:{ignoreOrigin:!0,writer:f.write}}})],e.prototype,"type",void 0);return e=d([h.subclass("esri.symbols.Symbol3DLayer")],e)}(h.declared(k));(b||(b={})).typeJSONDictionary=f;return b})},"esri/symbols/support/Symbol3DMaterial":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators ./materialUtils".split(" "),
function(b,e,m,d,k,l,h){Object.defineProperty(e,"__esModule",{value:!0});b=function(a){function c(){return null!==a&&a.apply(this,arguments)||this}m(c,a);b=c;c.prototype.clone=function(){return new b({color:this.color?this.color.clone():null})};var b;d([l.property(h.colorAndTransparencyProperty)],c.prototype,"color",void 0);return c=b=d([l.subclass("esri.symbols.support.Symbol3DMaterial")],c)}(l.declared(k));e.Symbol3DMaterial=b;e.default=b})},"esri/symbols/support/materialUtils":function(){define("require exports ../../Color ../../core/screenUtils ../../core/accessorSupport/ensureType ../../webdoc/support/opacityUtils".split(" "),
function(b,e,m,d,k,l){function h(a,b){a=null!=b.transparency?l.transparencyToOpacity(b.transparency):1;if((b=b.color)&&Array.isArray(b))return new m([b[0]||0,b[1]||0,b[2]||0,a])}function a(a,b){b.color=a.toJSON().slice(0,3);a=l.opacityToTransparency(a.a);0!==a&&(b.transparency=a)}Object.defineProperty(e,"__esModule",{value:!0});e.readColorAndTransparency=h;e.writeColorAndTransparency=a;e.colorAndTransparencyProperty={type:m,json:{type:[k.Integer],read:{source:["color","transparency"],reader:h},write:{target:{color:{type:[k.Integer]},
transparency:{type:k.Integer}},writer:a}}};e.screenSizeProperty={type:Number,cast:d.toPt,json:{write:!0}}})},"esri/symbols/edges/utils":function(){define(["require","exports","./Edges3D","./SketchEdges3D","./SolidEdges3D"],function(b,e,m,d,k){function l(b,a,c){if(!b)return b;switch(b.type){case "solid":return a=new k,a.read(b,c),a;case "sketch":return a=new d,a.read(b,c),a}}Object.defineProperty(e,"__esModule",{value:!0});e.read=l;e.symbol3dEdgesProperty={types:{key:"type",base:m,typeMap:{solid:k,
sketch:d}},json:{read:l,write:!0}}})},"esri/symbols/edges/Edges3D":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/tsSupport/assignHelper ../../Color ../../core/JSONSupport ../../core/lang ../../core/screenUtils ../../core/accessorSupport/decorators ../support/materialUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f,n){return function(b){function e(a){a=b.call(this)||this;a.color=new l([0,0,0,1]);a.extensionLength=0;a.size=
c.px2pt(1);return a}m(e,b);e.prototype.normalizeCtorArgs=function(a){a&&a.type&&(a=k({},a),delete a.type);return a};e.prototype.clone=function(){};e.prototype.cloneProperties=function(){return{color:a.clone(this.color),size:this.size,extensionLength:this.extensionLength}};d([f.property({type:["solid","sketch"],readOnly:!0,json:{read:!0,write:{ignoreOrigin:!0}}})],e.prototype,"type",void 0);d([f.property(n.colorAndTransparencyProperty)],e.prototype,"color",void 0);d([f.property(k({},n.screenSizeProperty,
{json:{write:{overridePolicy:function(a){return{enabled:!!a}}}}}))],e.prototype,"extensionLength",void 0);d([f.property(n.screenSizeProperty)],e.prototype,"size",void 0);return e=d([f.subclass("esri.symbols.edges.Edges3D")],e)}(f.declared(h))})},"esri/symbols/edges/SketchEdges3D":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./Edges3D".split(" "),function(b,e,m,d,k,l){return function(b){function a(a){a=
b.call(this)||this;a.type="sketch";return a}m(a,b);c=a;a.prototype.clone=function(){return new c(this.cloneProperties())};var c;d([k.property({type:["sketch"]})],a.prototype,"type",void 0);return a=c=d([k.subclass("esri.symbols.edges.SketchEdges3D")],a)}(k.declared(l))})},"esri/symbols/edges/SolidEdges3D":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./Edges3D".split(" "),function(b,e,m,d,k,l){return function(b){function a(a){a=
b.call(this)||this;a.type="solid";return a}m(a,b);c=a;a.prototype.clone=function(){return new c(this.cloneProperties())};var c;d([k.property({type:["solid"]})],a.prototype,"type",void 0);return a=c=d([k.subclass("esri.symbols.support.SolidEdges3D")],a)}(k.declared(l))})},"esri/symbols/FillSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/kebabDictionary ../core/accessorSupport/decorators ./SimpleLineSymbol ./Symbol".split(" "),
function(b,e,m,d,k,l,h,a){var c=new k.default({esriSFS:"simple-fill",esriPFS:"picture-fill"});return function(a){function b(c){c=a.call(this,c)||this;c.outline=null;c.type=null;return c}m(b,a);d([l.property({type:h,json:{default:null,write:!0}})],b.prototype,"outline",void 0);d([l.property({type:c.apiValues,readOnly:!0,json:{type:c.jsonValues}})],b.prototype,"type",void 0);return b=d([l.subclass("esri.symbols.FillSymbol")],b)}(l.declared(a))})},"esri/symbols/SimpleLineSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/kebabDictionary ../core/lang ../core/screenUtils ../core/accessorSupport/decorators ./LineSymbol".split(" "),
function(b,e,m,d,k,l,h,a,c){var f=new k.default({esriSLSSolid:"solid",esriSLSDash:"dash",esriSLSDot:"dot",esriSLSDashDot:"dash-dot",esriSLSDashDotDot:"long-dash-dot-dot",esriSLSNull:"none",esriSLSInsideFrame:"inside-frame",esriSLSShortDash:"short-dash",esriSLSShortDot:"short-dot",esriSLSShortDashDot:"short-dash-dot",esriSLSShortDashDotDot:"short-dash-dot-dot",esriSLSLongDash:"long-dash",esriSLSLongDashDot:"long-dash-dot"});return function(c){function b(a,b,d,f,e,g){a=c.call(this,a)||this;a.type="simple-line";
a.style="solid";a.cap="round";a.join="round";a.miterLimit=7.5;return a}m(b,c);e=b;b.prototype.normalizeCtorArgs=function(a,c,b,d,f,e){if(a&&"string"!==typeof a)return a;var g={};null!=a&&(g.style=a);null!=c&&(g.color=c);null!=b&&(g.width=h.toPt(b));null!=d&&(g.cap=d);null!=f&&(g.join=f);null!=e&&(g.miterLimit=h.toPt(e));return g};b.prototype.clone=function(){return new e({color:l.clone(this.color),style:this.style,width:this.width,cap:this.cap,join:this.join,miterLimit:this.miterLimit})};var e;d([a.enumeration.serializable()({esriSLS:"simple-line"})],
b.prototype,"type",void 0);d([a.property({type:f.apiValues,json:{read:f.read,write:f.write}})],b.prototype,"style",void 0);d([a.property({type:["butt","round","square"],json:{write:{overridePolicy:function(a,c,b){return{enabled:"round"!==a&&(null==b||null==b.origin)}}}}})],b.prototype,"cap",void 0);d([a.property({type:["miter","round","bevel"],json:{write:{overridePolicy:function(a,c,b){return{enabled:"round"!==a&&(null==b||null==b.origin)}}}}})],b.prototype,"join",void 0);d([a.property({type:Number,
cast:h.toPt,json:{read:!1,write:!1}})],b.prototype,"miterLimit",void 0);return b=e=d([a.subclass("esri.symbols.SimpleLineSymbol")],b)}(a.declared(c))})},"esri/symbols/LineSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/screenUtils ../core/accessorSupport/decorators ./Symbol".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this,c)||this;c.type="simple-line";c.width=.75;return c}m(c,a);d([l.enumeration.serializable()({esriSLS:"simple-line"})],
c.prototype,"type",void 0);d([l.property({type:Number,cast:k.toPt,json:{write:!0}})],c.prototype,"width",void 0);return c=d([l.subclass("esri.symbols.LineSymbol")],c)}(l.declared(h))})},"esri/symbols/FillSymbol3DLayer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/accessorSupport/decorators ./Symbol3DLayer ./edges/utils ./support/Symbol3DFillMaterial ./support/Symbol3DOutline".split(" "),function(b,e,m,d,k,l,h,a,c){return function(b){function f(a){a=
b.call(this)||this;a.type="fill";a.material=null;a.castShadows=!0;a.outline=null;a.edges=null;return a}m(f,b);e=f;f.prototype.clone=function(){return new e({edges:this.edges&&this.edges.clone(),enabled:this.enabled,elevationInfo:this.elevationInfo&&this.elevationInfo.clone(),material:this.material&&this.material.clone(),castShadows:this.castShadows,outline:this.outline&&this.outline.clone()})};var e;d([k.enumeration.serializable()({Fill:"fill"})],f.prototype,"type",void 0);d([k.property({type:a.default})],
f.prototype,"material",void 0);d([k.property({type:Boolean,nonNullable:!0,json:{write:!0,default:!0}})],f.prototype,"castShadows",void 0);d([k.property({type:c.default,json:{write:!0}})],f.prototype,"outline",void 0);d([k.property(h.symbol3dEdgesProperty)],f.prototype,"edges",void 0);return f=e=d([k.subclass("esri.symbols.FillSymbol3DLayer")],f)}(k.declared(l))})},"esri/symbols/support/Symbol3DFillMaterial":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./Symbol3DMaterial".split(" "),
function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function a(){return null!==b&&b.apply(this,arguments)||this}m(a,b);c=a;a.prototype.clone=function(){return new c({color:this.color?this.color.clone():null,colorMixMode:this.colorMixMode})};var c;d([k.enumeration.serializable()({multiply:"multiply",replace:"replace",tint:"tint"})],a.prototype,"colorMixMode",void 0);return a=c=d([k.subclass("esri.symbols.support.Symbol3DFillMaterial")],a)}(k.declared(l.default));e.Symbol3DFillMaterial=
b;e.default=b})},"esri/symbols/support/Symbol3DOutline":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../Color ../../core/JSONSupport ../../core/screenUtils ../../core/accessorSupport/decorators ./materialUtils".split(" "),function(b,e,m,d,k,l,h,a,c){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function f(){var a=null!==b&&b.apply(this,arguments)||this;a.color=new k([0,0,0,1]);a.size=h.px2pt(1);return a}m(f,b);
e=f;f.prototype.clone=function(){return new e({color:this.color?this.color.clone():null,size:this.size})};var e;d([a.property(c.colorAndTransparencyProperty)],f.prototype,"color",void 0);d([a.property(c.screenSizeProperty)],f.prototype,"size",void 0);return f=e=d([a.subclass("esri.symbols.support.Symbol3DOutline")],f)}(a.declared(l));e.Symbol3DOutline=b;e.default=b})},"esri/symbols/Font":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/screenUtils ../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.decoration="none";c.family="sans-serif";c.size=9;c.style="normal";c.weight="normal";return c}m(c,a);b=c;c.prototype.castSize=function(a){return l.toPt(a)};c.prototype.clone=function(){return new b({decoration:this.decoration,family:this.family,size:this.size,style:this.style,weight:this.weight})};var b;d([h.property({type:["underline","line-through","none"],json:{default:"none",write:!0}})],c.prototype,"decoration",void 0);
d([h.property({type:String,json:{write:!0}})],c.prototype,"family",void 0);d([h.property({type:Number,json:{write:{overridePolicy:function(a,c,b){return{enabled:!b||!b.textSymbol3D}}}}})],c.prototype,"size",void 0);d([h.cast("size")],c.prototype,"castSize",null);d([h.property({type:["normal","italic","oblique"],json:{default:"normal",write:!0}})],c.prototype,"style",void 0);d([h.property({type:["normal","bold","bolder","lighter"],json:{default:"normal",write:!0}})],c.prototype,"weight",void 0);return c=
b=d([h.subclass("esri.symbols.Font")],c)}(h.declared(k))})},"esri/symbols/IconSymbol3DLayer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/accessorSupport/decorators ./Symbol3DLayer ./support/IconSymbol3DLayerResource ./support/materialUtils ./support/Symbol3DAnchorPosition2D ./support/Symbol3DOutline".split(" "),function(b,e,m,d,k,l,h,a,c,f){return function(b){function e(a){a=b.call(this)||this;a.material=null;a.resource=null;a.type=
"icon";a.size=12;a.anchor="center";a.anchorPosition=void 0;a.outline=void 0;return a}m(e,b);n=e;e.prototype.clone=function(){return new n({anchor:this.anchor,anchorPosition:this.anchorPosition&&this.anchorPosition.clone(),enabled:this.enabled,elevationInfo:this.elevationInfo&&this.elevationInfo.clone(),material:this.material&&this.material.clone(),outline:this.outline&&this.outline.clone(),resource:this.resource&&this.resource.clone(),size:this.size})};var n;d([k.property()],e.prototype,"material",
void 0);d([k.property({type:h.default,json:{write:!0}})],e.prototype,"resource",void 0);d([k.enumeration.serializable()({Icon:"icon"})],e.prototype,"type",void 0);d([k.property(a.screenSizeProperty)],e.prototype,"size",void 0);d([k.enumeration.serializable()({center:"center",left:"left",right:"right",top:"top",bottom:"bottom",topLeft:"top-left",topRight:"top-right",bottomLeft:"bottom-left",bottomRight:"bottom-right",relative:"relative"}),k.property({json:{default:"center"}})],e.prototype,"anchor",
void 0);d([k.property({type:c.Symbol3DAnchorPosition2D,json:{read:{reader:function(a){return new c.Symbol3DAnchorPosition2D({x:a[0],y:a[1]})}},write:{writer:function(a,c){c.anchorPosition=[a.x,a.y]},overridePolicy:function(){return{enabled:"relative"===this.anchor}}}}})],e.prototype,"anchorPosition",void 0);d([k.property({type:f.default,json:{write:!0}})],e.prototype,"outline",void 0);return e=n=d([k.subclass("esri.symbols.IconSymbol3DLayer")],e)}(k.declared(l))})},"esri/symbols/support/IconSymbol3DLayerResource":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/urlUtils ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a){Object.defineProperty(e,"__esModule",{value:!0});var c=l.strict()({circle:"circle",square:"square",cross:"cross",x:"x",kite:"kite",triangle:"triangle"});b=function(b){function f(a){return b.call(this,a)||this}m(f,b);e=f;f.prototype.readHref=function(a,c,b){return a?h.fromJSON(a,b):c.dataURI};f.prototype.writeHref=function(a,c,b,d){a&&(h.isDataProtocol(a)?c.dataURI=a:(c.href=h.toJSON(a,d),h.isAbsolute(c.href)&&(c.href=h.normalize(c.href))))};f.prototype.clone=function(){return new e({href:this.href,
primitive:this.primitive})};var e;d([a.property({type:String,json:{write:!0,read:{source:["href","dataURI"]}}})],f.prototype,"href",void 0);d([a.reader("href")],f.prototype,"readHref",null);d([a.writer("href",{href:{type:String},dataURI:{type:String}})],f.prototype,"writeHref",null);d([a.enumeration.serializable()(c)],f.prototype,"primitive",void 0);return f=e=d([a.subclass("esri.symbols.support.IconSymbol3DLayerResource")],f)}(a.declared(k));e.IconSymbol3DLayerResource=b;e.defaultPrimitive="circle";
e.default=b})},"esri/symbols/support/Symbol3DAnchorPosition2D":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.x=0;a.y=0;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({x:this.x,y:this.y})};var c;d([l.property({type:Number})],
a.prototype,"x",void 0);d([l.property({type:Number})],a.prototype,"y",void 0);return a=c=d([l.subclass("esri.symbols.support.Symbol3DAnchorPosition2D")],a)}(l.declared(k));e.Symbol3DAnchorPosition2D=b;e.default=b})},"esri/symbols/LabelSymbol3D":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Collection ../core/lang ../core/accessorSupport/decorators ./Symbol3D ./TextSymbol3DLayer ./callouts/calloutUtils ./support/Symbol3DVerticalOffset".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){var g=k.ofType({base:null,key:"type",typeMap:{text:c}});return function(a){function c(c){c=a.call(this)||this;c.verticalOffset=null;c.callout=null;c.styleOrigin=null;c.symbolLayers=new g;c.type="label-3d";return c}m(c,a);b=c;c.prototype.supportsCallout=function(){return!0};c.prototype.hasVisibleCallout=function(){return f.hasVisibleCallout(this)};c.prototype.hasVisibleVerticalOffset=function(){return f.hasVisibleVerticalOffset(this)};c.prototype.clone=function(){return new b({styleOrigin:l.clone(this.styleOrigin),
symbolLayers:l.clone(this.symbolLayers),thumbnail:l.clone(this.thumbnail),callout:l.clone(this.callout),verticalOffset:l.clone(this.verticalOffset)})};var b;d([h.property({type:n.default,json:{write:!0}})],c.prototype,"verticalOffset",void 0);d([h.property(f.calloutProperty)],c.prototype,"callout",void 0);d([h.property({json:{read:!1,write:!1}})],c.prototype,"styleOrigin",void 0);d([h.property({type:g})],c.prototype,"symbolLayers",void 0);d([h.enumeration.serializable()({LabelSymbol3D:"label-3d"})],
c.prototype,"type",void 0);return c=b=d([h.subclass("esri.symbols.LabelSymbol3D")],c)}(h.declared(a))})},"esri/symbols/Symbol3D":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Collection ../core/collectionUtils ../core/kebabDictionary ../core/Logger ../core/urlUtils ../core/Warning ../core/accessorSupport/decorators ../portal/Portal ./ExtrudeSymbol3DLayer ./FillSymbol3DLayer ./IconSymbol3DLayer ./LineSymbol3DLayer ./ObjectSymbol3DLayer ./PathSymbol3DLayer ./Symbol ./Symbol3DLayer ./TextSymbol3DLayer ./support/StyleOrigin ./support/Thumbnail".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x,w,A){var B={icon:t,object:v,line:r,path:u,fill:p,extrude:q,text:x},F=k.ofType({base:y,key:"type",typeMap:B}),C=h.strict()({PointSymbol3D:"point-3d",PolygonSymbol3D:"polygon-3d",LineSymbol3D:"line-3d",MeshSymbol3D:"mesh-3d",LabelSymbol3D:"label-3d"}),E=a.getLogger("esri.symbols.Symbol3D");return function(a){function b(c){c=a.call(this)||this;c.styleOrigin=null;c.thumbnail=null;c.type=null;var b=c.__accessor__&&c.__accessor__.metadatas&&c.__accessor__.metadatas.symbolLayers;
c._set("symbolLayers",new (b&&b.type||k));return c}m(b,a);Object.defineProperty(b.prototype,"color",{get:function(){return null},set:function(a){E.error("Symbol3D does not support colors on the symbol level. Colors may be set on individual symbol layer materials instead.")},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"symbolLayers",{set:function(a){l.referenceSetter(a,this._get("symbolLayers"))},enumerable:!0,configurable:!0});b.prototype.readSymbolLayers=function(a,c,b){c=[];
for(var d=0;d<a.length;d++){var e=a[d],g=y.typeJSONDictionary.read(e.type),h=g&&B[g];h?(e=new h,e.read(a[d],b),c.push(e)):(E.warn("Unknown symbol layer type: "+g),b&&b.messages&&b.messages.push(new f("symbol-layer:unsupported","Symbol layers of type '"+(g||e.type||"unknown")+"' are not supported",{definition:e,context:b})))}return c};b.prototype.readStyleOrigin=function(a,b,d){if(a.styleUrl&&a.name)return b=c.fromJSON(a.styleUrl,d),new w({styleUrl:b,name:a.name});if(a.styleName&&a.name)return new w({portal:d&&
d.portal||g.getDefault(),styleName:a.styleName,name:a.name});d&&d.messages&&d.messages.push(new f("symbol3d:incomplete-style-origin","Style origin requires either a 'styleUrl' or 'styleName' and a 'name' property",{context:d,definition:a}))};b.prototype.writeStyleOrigin=function(a,b,d,e){a.styleUrl&&a.name?(d=c.toJSON(a.styleUrl,e),c.isAbsolute(d)&&(d=c.normalize(d)),b.styleOrigin={styleUrl:d,name:a.name}):a.styleName&&a.name&&(a.portal&&e&&e.portal&&!c.hasSamePortal(a.portal.restUrl,e.portal.restUrl)?
e&&e.messages&&e.messages.push(new f("symbol:cross-portal","The symbol style origin cannot be persisted because it refers to an item on a different portal than the one being saved to.",{symbol:this})):b.styleOrigin={styleName:a.styleName,name:a.name})};b.prototype.normalizeCtorArgs=function(a){return a instanceof y||a&&B[a.type]?{symbolLayers:[a]}:Array.isArray(a)?{symbolLayers:a}:a};d([n.property({json:{read:!1,write:!1}})],b.prototype,"color",null);d([n.property({type:F,nonNullable:!0,json:{write:!0}}),
n.cast(l.castForReferenceSetter)],b.prototype,"symbolLayers",null);d([n.reader("symbolLayers")],b.prototype,"readSymbolLayers",null);d([n.property({type:w})],b.prototype,"styleOrigin",void 0);d([n.reader("styleOrigin")],b.prototype,"readStyleOrigin",null);d([n.writer("styleOrigin",{"styleOrigin.styleUrl":{type:String},"styleOrigin.styleName":{type:String},"styleOrigin.name":{type:String}})],b.prototype,"writeStyleOrigin",null);d([n.property({type:A.default,json:{read:!1}})],b.prototype,"thumbnail",
void 0);d([n.property({type:C.apiValues,readOnly:!0,json:{type:C.jsonValues,read:!1}})],b.prototype,"type",void 0);return b=d([n.subclass("esri.symbols.Symbol3D")],b)}(n.declared(z))})},"esri/symbols/LineSymbol3DLayer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/screenUtils ../core/accessorSupport/decorators ./Symbol3DLayer ./support/materialUtils".split(" "),function(b,e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this)||
this;a.material=null;a.type="line";a.size=k.px2pt(1);return a}m(b,c);e=b;b.prototype.clone=function(){return new e({enabled:this.enabled,elevationInfo:this.elevationInfo&&this.elevationInfo.clone(),material:this.material&&this.material.clone(),size:this.size})};var e;d([l.property()],b.prototype,"material",void 0);d([l.enumeration.serializable()({Line:"line"})],b.prototype,"type",void 0);d([l.property(a.screenSizeProperty)],b.prototype,"size",void 0);return b=e=d([l.subclass("esri.symbols.LineSymbol3DLayer")],
b)}(l.declared(h))})},"esri/symbols/ObjectSymbol3DLayer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/accessorSupport/decorators ./Symbol3DLayer ./support/ObjectSymbol3DLayerResource ./support/Symbol3DAnchorPosition3D ./support/Symbol3DMaterial".split(" "),function(b,e,m,d,k,l,h,a,c){return function(b){function f(a){a=b.call(this)||this;a.material=null;a.castShadows=!0;a.resource=null;a.type="object";a.width=void 0;a.height=void 0;
a.depth=void 0;a.anchor=void 0;a.anchorPosition=void 0;a.heading=void 0;a.tilt=void 0;a.roll=void 0;return a}m(f,b);e=f;f.prototype.clone=function(){return new e({heading:this.heading,tilt:this.tilt,roll:this.roll,anchor:this.anchor,anchorPosition:this.anchorPosition&&this.anchorPosition.clone(),depth:this.depth,enabled:this.enabled,elevationInfo:this.elevationInfo&&this.elevationInfo.clone(),height:this.height,material:this.material&&this.material.clone(),castShadows:this.castShadows,resource:this.resource&&
this.resource.clone(),width:this.width})};Object.defineProperty(f.prototype,"isPrimitive",{get:function(){return!this.resource||"string"!==typeof this.resource.href},enumerable:!0,configurable:!0});var e;d([k.property({type:c.default})],f.prototype,"material",void 0);d([k.property({type:Boolean,nonNullable:!0,json:{write:!0,default:!0}})],f.prototype,"castShadows",void 0);d([k.property({type:h.default,json:{write:!0}})],f.prototype,"resource",void 0);d([k.enumeration.serializable()({Object:"object"})],
f.prototype,"type",void 0);d([k.property({type:Number,json:{write:!0}})],f.prototype,"width",void 0);d([k.property({type:Number,json:{write:!0}})],f.prototype,"height",void 0);d([k.property({type:Number,json:{write:!0}})],f.prototype,"depth",void 0);d([k.enumeration.serializable()({center:"center",top:"top",bottom:"bottom",origin:"origin",relative:"relative"}),k.property({json:{default:"origin"}})],f.prototype,"anchor",void 0);d([k.property({type:a.Symbol3DAnchorPosition3D,json:{type:[Number],read:{reader:function(c){return new a.Symbol3DAnchorPosition3D({x:c[0],
y:c[1],z:c[2]})}},write:{writer:function(a,c){c.anchorPosition=[a.x,a.y,a.z]},overridePolicy:function(){return{enabled:"relative"===this.anchor}}}}})],f.prototype,"anchorPosition",void 0);d([k.property({type:Number,json:{write:!0}})],f.prototype,"heading",void 0);d([k.property({type:Number,json:{write:!0}})],f.prototype,"tilt",void 0);d([k.property({type:Number,json:{write:!0}})],f.prototype,"roll",void 0);d([k.property({readOnly:!0,dependsOn:["resource","resource.href"]})],f.prototype,"isPrimitive",
null);return f=e=d([k.subclass("esri.symbols.ObjectSymbol3DLayer")],f)}(k.declared(l))})},"esri/symbols/support/ObjectSymbol3DLayerResource":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/urlUtils ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h,a){Object.defineProperty(e,"__esModule",{value:!0});var c=l.strict()({sphere:"sphere",cylinder:"cylinder",
cube:"cube",cone:"cone",diamond:"diamond",tetrahedron:"tetrahedron",invertedCone:"inverted-cone"});b=function(b){function f(){return null!==b&&b.apply(this,arguments)||this}m(f,b);e=f;f.prototype.clone=function(){return new e({href:this.href,primitive:this.primitive})};var e;d([a.property({type:String,json:{read:h.read,write:h.write}})],f.prototype,"href",void 0);d([a.enumeration.serializable()(c)],f.prototype,"primitive",void 0);return f=e=d([a.subclass("esri.symbols.support.ObjectSymbol3DLayerResource")],
f)}(a.declared(k));e.ObjectSymbol3DLayerResource=b;e.defaultPrimitive="sphere";e.default=b})},"esri/symbols/support/Symbol3DAnchorPosition3D":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.x=0;a.y=0;a.z=0;return a}m(a,b);
c=a;a.prototype.clone=function(){return new c({x:this.x,y:this.y,z:this.z})};var c;d([l.property({type:Number})],a.prototype,"x",void 0);d([l.property({type:Number})],a.prototype,"y",void 0);d([l.property({type:Number})],a.prototype,"z",void 0);return a=c=d([l.subclass("esri.symbols.support.Symbol3DAnchorPosition3D")],a)}(l.declared(k));e.Symbol3DAnchorPosition3D=b;e.default=b})},"esri/symbols/PathSymbol3DLayer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/accessorSupport/decorators ./Symbol3DLayer".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.material=null;a.castShadows=!0;a.type="path";a.size=void 0;a.profile="tube";a.joint="simple";return a}m(a,b);c=a;a.prototype.readSize=function(a,c){return a||c.width||0};a.prototype.clone=function(){return new c({enabled:this.enabled,elevationInfo:this.elevationInfo&&this.elevationInfo.clone(),material:this.material&&this.material.clone(),castShadows:this.castShadows,size:this.size,profile:this.profile,joint:this.joint})};
var c;d([k.property()],a.prototype,"material",void 0);d([k.property({type:Boolean,nonNullable:!0,json:{write:!0,default:!0}})],a.prototype,"castShadows",void 0);d([k.enumeration.serializable()({Path:"path"})],a.prototype,"type",void 0);d([k.property({type:Number,json:{write:{enabled:!0,target:{size:{type:Number},width:{type:Number}}}}})],a.prototype,"size",void 0);d([k.reader("size",["size","width"])],a.prototype,"readSize",null);d([k.property()],a.prototype,"profile",void 0);d([k.property()],a.prototype,
"joint",void 0);return a=c=d([k.subclass("esri.symbols.PathSymbol3DLayer")],a)}(k.declared(l))})},"esri/symbols/TextSymbol3DLayer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/assignHelper ../core/lang ../core/accessorSupport/decorators ./Font ./Symbol3DLayer ./support/materialUtils ./support/Symbol3DHalo".split(" "),function(b,e,m,d,k,l,h,a,c,f,n){return function(c){function b(a){a=c.call(this)||this;a._userSize=void 0;
a.halo=null;a.material=null;a.text=void 0;a.type="text";return a}m(b,c);e=b;Object.defineProperty(b.prototype,"font",{get:function(){return this._get("font")||null},set:function(a){a&&this._userSize&&(a.size=this._userSize);this._set("font",a)},enumerable:!0,configurable:!0});b.prototype.writeFont=function(a,c,b,d){b=k({},d,{textSymbol3D:!0});c.font=a.write({},b);delete c.font.size};Object.defineProperty(b.prototype,"size",{get:function(){return null!=this._userSize?this._userSize:this.font&&null!=
this.font.size?this.font.size:9},set:function(a){this._userSize=a;this.font&&(this.font.size=this._userSize);this.notifyChange("size")},enumerable:!0,configurable:!0});b.prototype.clone=function(){return new e({enabled:this.enabled,elevationInfo:this.elevationInfo&&this.elevationInfo.clone(),font:this.font&&l.clone(this.font),halo:this.halo&&l.clone(this.halo),material:this.material&&this.material.clone(),size:this.size,text:this.text})};var e;d([h.property({type:a,json:{write:!0}})],b.prototype,
"font",null);d([h.writer("font")],b.prototype,"writeFont",null);d([h.property({type:n.default,json:{write:!0}})],b.prototype,"halo",void 0);d([h.property()],b.prototype,"material",void 0);d([h.property(f.screenSizeProperty),h.property({dependsOn:["font.size"]})],b.prototype,"size",null);d([h.property({type:String,json:{write:!0}})],b.prototype,"text",void 0);d([h.enumeration.serializable()({Text:"text"})],b.prototype,"type",void 0);return b=e=d([h.subclass("esri.symbols.TextSymbol3DLayer")],b)}(h.declared(c))})},
"esri/symbols/support/Symbol3DHalo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../Color ../../core/JSONSupport ../../core/lang ../../core/accessorSupport/decorators ./materialUtils".split(" "),function(b,e,m,d,k,l,h,a,c){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function f(){var a=null!==b&&b.apply(this,arguments)||this;a.color=new k([0,0,0,1]);a.size=0;return a}m(f,b);e=f;f.prototype.clone=function(){return new e({color:h.clone(this.color),
size:this.size})};var e;d([a.property(c.colorAndTransparencyProperty)],f.prototype,"color",void 0);d([a.property(c.screenSizeProperty)],f.prototype,"size",void 0);return f=e=d([a.subclass("esri.symbols.support.Symbol3DHalo")],f)}(a.declared(l));e.Symbol3DHalo=b;e.default=b})},"esri/symbols/support/StyleOrigin":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators ../../portal/Portal".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(){var c=null!==a&&a.apply(this,arguments)||this;c.portal=null;return c}m(c,a);b=c;c.prototype.clone=function(){return new b({name:this.name,styleUrl:this.styleUrl,styleName:this.styleName,portal:this.portal})};var b;d([l.property({type:String})],c.prototype,"name",void 0);d([l.property({type:String})],c.prototype,"styleUrl",void 0);d([l.property({type:String})],c.prototype,"styleName",void 0);d([l.property({type:h})],c.prototype,"portal",void 0);
return c=b=d([l.subclass("esri.symbols.support.StyleOrigin")],c)}(l.declared(k))})},"esri/symbols/support/Thumbnail":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function a(){return null!==b&&b.apply(this,arguments)||this}m(a,b);c=a;a.prototype.clone=function(){return new c({url:this.url})};
var c;d([l.property({type:String})],a.prototype,"url",void 0);return a=c=d([l.subclass("esri.symbols.support.Thumbnail")],a)}(l.declared(k));e.Thumbnail=b;e.default=b})},"esri/symbols/callouts/calloutUtils":function(){define(["require","exports","./Callout3D","./LineCallout3D"],function(b,e,m,d){function k(b){if(!b)return!1;b=b.verticalOffset;return!b||0>=b.screenLength||0>=b.maxWorldLength?!1:!0}function l(b,a,c){if(!b)return b;switch(b.type){case "line":return a=new d,a.read(b,c),a}}Object.defineProperty(e,
"__esModule",{value:!0});e.hasVisibleVerticalOffset=k;e.hasVisibleCallout=function(b){if(!b||!b.supportsCallout||!b.supportsCallout())return!1;var a=b.callout;return a&&a.visible?k(b)?!0:!1:!1};e.isCalloutSupport=function(b){return"point-3d"===b.type||"label-3d"===b.type};e.read=l;e.calloutProperty={types:{key:"type",base:m,typeMap:{line:d}},json:{read:l,write:!0}}})},"esri/symbols/callouts/Callout3D":function(){define("require exports ../../core/tsSupport/assignHelper ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.visible=!0;return c}d(c,a);c.prototype.normalizeCtorArgs=function(a){a&&a.type&&(a=m({},a),delete a.type);return a};c.prototype.clone=function(){};k([h.property({type:["line"],readOnly:!0,json:{read:!1,write:{ignoreOrigin:!0}}})],c.prototype,"type",void 0);k([h.property({readOnly:!0})],c.prototype,"visible",void 0);return c=k([h.subclass("esri.symbols.callouts.Callout3D")],c)}(h.declared(l))})},"esri/symbols/callouts/LineCallout3D":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../Color ../../core/lang ../../core/screenUtils ../../core/accessorSupport/decorators ./Callout3D ./LineCallout3DBorder ../support/materialUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){return function(c){function b(a){a=c.call(this)||this;a.type="line";a.color=new k([0,0,0,1]);a.size=h.px2pt(1);a.border=null;return a}m(b,c);e=b;Object.defineProperty(b.prototype,"visible",{get:function(){return 0<this.size&&0<this.color.a},enumerable:!0,configurable:!0});b.prototype.clone=function(){return new e({color:l.clone(this.color),size:this.size,border:l.clone(this.border)})};var e;d([a.property({type:["line"]})],b.prototype,"type",void 0);d([a.property(n.colorAndTransparencyProperty)],
b.prototype,"color",void 0);d([a.property(n.screenSizeProperty)],b.prototype,"size",void 0);d([a.property({type:f.default,json:{write:!0}})],b.prototype,"border",void 0);d([a.property({dependsOn:["size","color"],readOnly:!0})],b.prototype,"visible",null);return b=e=d([a.subclass("esri.symbols.callouts.LineCallout3D")],b)}(a.declared(c))})},"esri/symbols/callouts/LineCallout3DBorder":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../Color ../../core/JSONSupport ../../core/lang ../../core/accessorSupport/decorators ../support/materialUtils".split(" "),
function(b,e,m,d,k,l,h,a,c){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function f(){var a=null!==b&&b.apply(this,arguments)||this;a.color=new k("white");return a}m(f,b);e=f;f.prototype.clone=function(){return new e({color:h.clone(this.color)})};var e;d([a.property(c.colorAndTransparencyProperty)],f.prototype,"color",void 0);return f=e=d([a.subclass("esri.symbols.callouts.LineCallout3DBorder")],f)}(a.declared(l));e.LineCallout3DBorder=b;e.default=b})},"esri/symbols/support/Symbol3DVerticalOffset":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators ./materialUtils".split(" "),
function(b,e,m,d,k,l,h){Object.defineProperty(e,"__esModule",{value:!0});b=function(a){function c(){var c=null!==a&&a.apply(this,arguments)||this;c.screenLength=0;c.minWorldLength=0;return c}m(c,a);b=c;c.prototype.clone=function(){return new b({screenLength:this.screenLength,minWorldLength:this.minWorldLength,maxWorldLength:this.maxWorldLength})};var b;d([l.property(h.screenSizeProperty)],c.prototype,"screenLength",void 0);d([l.property({type:Number,json:{write:!0,default:0}})],c.prototype,"minWorldLength",
void 0);d([l.property({type:Number,json:{write:!0}})],c.prototype,"maxWorldLength",void 0);return c=b=d([l.subclass("esri.symbols.support.Symbol3DVerticalOffset")],c)}(l.declared(k));e.Symbol3DVerticalOffset=b;e.default=b})},"esri/symbols/LineSymbol3D":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Collection ../core/lang ../core/accessorSupport/decorators ./LineSymbol3DLayer ./PathSymbol3DLayer ./Symbol3D".split(" "),function(b,
e,m,d,k,l,h,a,c,f){var n=k.ofType({base:null,key:"type",typeMap:{line:a,path:c}}),g=k.ofType({base:null,key:"type",typeMap:{line:a,path:c}});return function(a){function c(c){c=a.call(this)||this;c.symbolLayers=new n;c.type="line-3d";return c}m(c,a);b=c;c.prototype.clone=function(){return new b({styleOrigin:l.clone(this.styleOrigin),symbolLayers:l.clone(this.symbolLayers),thumbnail:l.clone(this.thumbnail)})};var b;d([h.property({type:n,json:{type:g}})],c.prototype,"symbolLayers",void 0);d([h.enumeration.serializable()({LineSymbol3D:"line-3d"})],
c.prototype,"type",void 0);return c=b=d([h.subclass("esri.symbols.LineSymbol3D")],c)}(h.declared(f))})},"esri/symbols/MarkerSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/kebabDictionary ../core/screenUtils ../core/accessorSupport/decorators ./Symbol".split(" "),function(b,e,m,d,k,l,h,a){var c=new k.default({esriSMS:"simple-marker",esriPMS:"picture-marker"});return function(a){function b(c){c=a.call(this,c)||this;c.angle=
0;c.type=null;c.xoffset=0;c.yoffset=0;c.size=9;return c}m(b,a);d([h.property({type:Number,json:{read:function(a){return a&&-1*a},write:function(a,c){return c.angle=a&&-1*a}}})],b.prototype,"angle",void 0);d([h.property({type:c.apiValues,readOnly:!0,json:{type:c.jsonValues}})],b.prototype,"type",void 0);d([h.property({type:Number,cast:l.toPt,json:{write:!0}})],b.prototype,"xoffset",void 0);d([h.property({type:Number,cast:l.toPt,json:{write:!0}})],b.prototype,"yoffset",void 0);d([h.property({type:Number,
cast:function(a){return"auto"===a?a:l.toPt(a)},json:{write:!0}})],b.prototype,"size",void 0);return b=d([h.subclass("esri.symbols.MarkerSymbol")],b)}(h.declared(a))})},"esri/symbols/MeshSymbol3D":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Collection ../core/lang ../core/accessorSupport/decorators ./FillSymbol3DLayer ./Symbol3D".split(" "),function(b,e,m,d,k,l,h,a,c){var f=k.ofType({base:null,key:"type",typeMap:{fill:a}});return function(a){function c(c){c=
a.call(this)||this;c.symbolLayers=new f;c.type="mesh-3d";return c}m(c,a);b=c;c.prototype.clone=function(){return new b({styleOrigin:l.clone(this.styleOrigin),symbolLayers:l.clone(this.symbolLayers),thumbnail:l.clone(this.thumbnail)})};var b;d([h.property({type:f})],c.prototype,"symbolLayers",void 0);d([h.enumeration.serializable()({MeshSymbol3D:"mesh-3d"})],c.prototype,"type",void 0);return c=b=d([h.subclass("esri.symbols.MeshSymbol3D")],c)}(h.declared(c))})},"esri/symbols/PictureFillSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/assignHelper ../core/lang ../core/screenUtils ../core/accessorSupport/decorators ./FillSymbol ./support/urlUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f){return function(c){function b(a,b,d,f){a=c.call(this,a)||this;a.type="picture-fill";a.url=null;a.xscale=1;a.yscale=1;a.width=12;a.height=12;a.xoffset=0;a.yoffset=0;a.source=null;return a}m(b,c);e=b;b.prototype.normalizeCtorArgs=function(a,c,b,d){if(a&&"string"!==typeof a&&null==a.imageData)return a;var f={};a&&(f.url=a);c&&(f.outline=c);null!=b&&(f.width=h.toPt(b));null!=d&&(f.height=h.toPt(d));return f};b.prototype.clone=function(){var a=new e({color:l.clone(this.color),
height:this.height,outline:this.outline&&this.outline.clone(),url:this.url,width:this.width,xoffset:this.xoffset,xscale:this.xscale,yoffset:this.yoffset,yscale:this.yscale});a._set("source",l.clone(this.source));return a};var e;d([a.enumeration.serializable()({esriPFS:"picture-fill"})],b.prototype,"type",void 0);d([a.property(f.urlPropertyDefinition)],b.prototype,"url",void 0);d([a.property({type:Number,json:{write:!0}})],b.prototype,"xscale",void 0);d([a.property({type:Number,json:{write:!0}})],
b.prototype,"yscale",void 0);d([a.property({type:Number,cast:h.toPt,json:{write:!0}})],b.prototype,"width",void 0);d([a.property({type:Number,cast:h.toPt,json:{write:!0}})],b.prototype,"height",void 0);d([a.property({type:Number,cast:h.toPt,json:{write:!0}})],b.prototype,"xoffset",void 0);d([a.property({type:Number,cast:h.toPt,json:{write:!0}})],b.prototype,"yoffset",void 0);d([a.property(f.sourcePropertyDefinition)],b.prototype,"source",void 0);return b=e=d([a.subclass("esri.symbols.PictureFillSymbol")],
b)}(a.declared(c))})},"esri/symbols/support/urlUtils":function(){define(["require","exports","../../core/urlUtils"],function(b,e,m){function d(b,a,c){return a.imageData?m.makeData({mediaType:a.contentType||"image/png",isBase64:!0,data:a.imageData}):k(a.url,c)}function k(b,a){return!a||"service"!==a.origin&&"portal-item"!==a.origin||!a.layer||"feature"!==a.layer.type&&"stream"!==a.layer.type||m.isAbsolute(b)||!a.layer.parsedUrl?m.fromJSON(b,a):m.join(a.layer.parsedUrl.path,"images",b)}function l(b,
a,c,d){m.isDataProtocol(b)?(b=m.dataComponents(b),a.contentType=b.mediaType,a.imageData=b.data,c&&c.imageData===a.imageData&&c.url&&m.write(c.url,a,"url",d)):m.write(b,a,"url",d)}Object.defineProperty(e,"__esModule",{value:!0});e.readImageDataOrUrl=d;e.read=k;e.writeImageDataAndUrl=l;e.urlPropertyDefinition={json:{read:{source:["imageData","url"],reader:d},write:{writer:function(b,a,c,d){l(b,a,this.source,d)}}}};e.sourcePropertyDefinition={readOnly:!0,json:{read:{source:["imageData","url"],reader:function(b,
a,c){b={};a.imageData&&(b.imageData=a.imageData);a.contentType&&(b.contentType=a.contentType);a.url&&(b.url=k(a.url,c));return b}}}}})},"esri/symbols/PictureMarkerSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/lang ../core/screenUtils ../core/accessorSupport/decorators ./MarkerSymbol ./support/urlUtils".split(" "),function(b,e,m,d,k,l,h,a,c){return function(a){function b(c,b,d){c=a.call(this,c)||this;c.color=null;c.type="picture-marker";
c.url=null;c.source=null;c.height=12;c.width=12;c.size=null;return c}m(b,a);f=b;b.prototype.normalizeCtorArgs=function(a,c,b){if(a&&"string"!==typeof a&&null==a.imageData)return a;var d={};a&&(d.url=a);null!=c&&(d.width=l.toPt(c));null!=b&&(d.height=l.toPt(b));return d};b.prototype.readHeight=function(a,c){return c.size||a};b.prototype.readWidth=function(a,c){return c.size||a};b.prototype.clone=function(){var a=new f({angle:this.angle,height:this.height,url:this.url,width:this.width,xoffset:this.xoffset,
yoffset:this.yoffset});a._set("source",k.clone(this.source));return a};var f;d([h.property({json:{write:!1}})],b.prototype,"color",void 0);d([h.enumeration.serializable()({esriPMS:"picture-marker"})],b.prototype,"type",void 0);d([h.property(c.urlPropertyDefinition)],b.prototype,"url",void 0);d([h.property(c.sourcePropertyDefinition)],b.prototype,"source",void 0);d([h.property({type:Number,cast:l.toPt,json:{write:!0}})],b.prototype,"height",void 0);d([h.reader("height",["height","size"])],b.prototype,
"readHeight",null);d([h.property({type:Number,cast:l.toPt,json:{write:!0}})],b.prototype,"width",void 0);d([h.property({json:{write:!1}})],b.prototype,"size",void 0);return b=f=d([h.subclass("esri.symbols.PictureMarkerSymbol")],b)}(h.declared(a))})},"esri/symbols/PointSymbol3D":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Collection ../core/Error ../core/lang ../core/accessorSupport/decorators ./IconSymbol3DLayer ./ObjectSymbol3DLayer ./Symbol3D ./TextSymbol3DLayer ./callouts/calloutUtils ./support/Symbol3DVerticalOffset".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p){var t=k.ofType({base:null,key:"type",typeMap:{icon:c,object:f,text:g}}),r=k.ofType({base:null,key:"type",typeMap:{icon:c,object:f}});return function(c){function b(a){a=c.call(this)||this;a.verticalOffset=null;a.callout=null;a.symbolLayers=new t;a.type="point-3d";return a}m(b,c);f=b;b.prototype.writeSymbolLayers=function(a,c,b,d){var f=a.filter(function(a){return"text"!==a.type});d&&d.messages&&f.length<a.length&&(a=a.find(function(a){return"text"===a.type}),d.messages.push(new l("symbol-layer:unsupported",
"Symbol layers of type 'text' cannot be persisted in PointSymbol3D",{symbolLayer:a})));c[b]=f.map(function(a){return a.write({},d)}).toArray()};b.prototype.supportsCallout=function(){if(1>(this.symbolLayers?this.symbolLayers.length:0))return!1;for(var a=0,c=this.symbolLayers.items;a<c.length;a++)switch(c[a].type){case "icon":case "text":case "object":continue;default:return!1}return!0};b.prototype.hasVisibleCallout=function(){return q.hasVisibleCallout(this)};b.prototype.hasVisibleVerticalOffset=
function(){return q.hasVisibleVerticalOffset(this)};b.prototype.clone=function(){return new f({verticalOffset:h.clone(this.verticalOffset),callout:h.clone(this.callout),styleOrigin:h.clone(this.styleOrigin),symbolLayers:h.clone(this.symbolLayers),thumbnail:h.clone(this.thumbnail)})};var f;d([a.property({type:p.default,json:{write:!0}})],b.prototype,"verticalOffset",void 0);d([a.property(q.calloutProperty)],b.prototype,"callout",void 0);d([a.property({type:t,json:{type:r}})],b.prototype,"symbolLayers",
void 0);d([a.writer("web-scene","symbolLayers")],b.prototype,"writeSymbolLayers",null);d([a.enumeration.serializable()({PointSymbol3D:"point-3d"})],b.prototype,"type",void 0);return b=f=d([a.subclass("esri.symbols.PointSymbol3D")],b)}(a.declared(n))})},"esri/symbols/PolygonSymbol3D":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Collection ../core/Error ../core/lang ../core/accessorSupport/decorators ./ExtrudeSymbol3DLayer ./FillSymbol3DLayer ./IconSymbol3DLayer ./LineSymbol3DLayer ./ObjectSymbol3DLayer ./Symbol3D ./TextSymbol3DLayer".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t){var r=k.ofType({base:null,key:"type",typeMap:{extrude:c,fill:f,icon:n,line:g,object:q,text:t}}),v=k.ofType({base:null,key:"type",typeMap:{extrude:c,fill:f,icon:n,line:g,object:q}});return function(c){function b(a){a=c.call(this)||this;a.type="polygon-3d";return a}m(b,c);f=b;b.prototype.writeSymbolLayers=function(a,c,b,d){var f=a.filter(function(a){return"text"!==a.type});d&&d.messages&&f.length<a.length&&(a=a.find(function(a){return"text"===a.type}),d.messages.push(new l("symbol-layer:unsupported",
"Symbol layers of type 'text' cannot be persisted in PolygonSymbol3D",{symbolLayer:a})));c[b]=f.map(function(a){return a.write({},d)}).toArray()};b.prototype.clone=function(){return new f({styleOrigin:h.clone(this.styleOrigin),symbolLayers:h.clone(this.symbolLayers),thumbnail:h.clone(this.thumbnail)})};b.fromJSON=function(a){var c=new f;c.read(a);if(2===c.symbolLayers.length&&"fill"===c.symbolLayers.getItemAt(0).type&&"line"===c.symbolLayers.getItemAt(1).type){var b=c.symbolLayers.getItemAt(0),d=
c.symbolLayers.getItemAt(1);!d.enabled||a.symbolLayers&&a.symbolLayers[1]&&!1===a.symbolLayers[1].enable||(b.outline={size:d.size,color:d.material.color});c.symbolLayers.removeAt(1)}return c};var f;d([a.property({type:r,json:{type:v}})],b.prototype,"symbolLayers",void 0);d([a.writer("web-scene","symbolLayers")],b.prototype,"writeSymbolLayers",null);d([a.enumeration.serializable()({PolygonSymbol3D:"polygon-3d"})],b.prototype,"type",void 0);return b=f=d([a.subclass("esri.symbols.PolygonSymbol3D")],
b)}(a.declared(p))})},"esri/symbols/SimpleFillSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/assignHelper ../Color ../core/kebabDictionary ../core/lang ../core/accessorSupport/decorators ./FillSymbol ./SimpleLineSymbol".split(" "),function(b,e,m,d,k,l,h,a,c,f,n){var g=new h.default({esriSFSSolid:"solid",esriSFSNull:"none",esriSFSHorizontal:"horizontal",esriSFSVertical:"vertical",esriSFSForwardDiagonal:"forward-diagonal",
esriSFSBackwardDiagonal:"backward-diagonal",esriSFSCross:"cross",esriSFSDiagonalCross:"diagonal-cross"});return function(b){function f(a,c,d){a=b.call(this,a)||this;a.color=new l([0,0,0,.25]);a.outline=new n;a.type="simple-fill";a.style="solid";return a}m(f,b);e=f;f.prototype.normalizeCtorArgs=function(a,c,b){if(a&&"string"!==typeof a)return a;var d={};a&&(d.style=a);c&&(d.outline=c);b&&(d.color=b);return d};f.prototype.clone=function(){return new e({color:a.clone(this.color),outline:this.outline&&
this.outline.clone(),style:this.style})};var e;d([c.property()],f.prototype,"color",void 0);d([c.property()],f.prototype,"outline",void 0);d([c.enumeration.serializable()({esriSFS:"simple-fill"})],f.prototype,"type",void 0);d([c.property({type:g.apiValues,json:{read:g.read,write:g.write}})],f.prototype,"style",void 0);return f=e=d([c.subclass("esri.symbols.SimpleFillSymbol")],f)}(c.declared(f))})},"esri/symbols/SimpleMarkerSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../Color ../core/kebabDictionary ../core/lang ../core/screenUtils ../core/accessorSupport/decorators ./MarkerSymbol ./SimpleLineSymbol".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){var g=new l.default({esriSMSCircle:"circle",esriSMSSquare:"square",esriSMSCross:"cross",esriSMSX:"x",esriSMSDiamond:"diamond",esriSMSTriangle:"triangle",esriSMSPath:"path"});return function(b){function f(a,c,d,f){a=b.call(this,a)||this;a.color=new k([255,255,255,.25]);a.type="simple-marker";a.size=12;a.style="circle";a.outline=new n;return a}m(f,b);e=f;f.prototype.normalizeCtorArgs=function(c,b,d,f){if(c&&"string"!==typeof c)return c;var e={};c&&(e.style=c);null!=b&&
(e.size=a.toPt(b));d&&(e.outline=d);f&&(e.color=f);return e};f.prototype.writeColor=function(a,c){a&&"x"!==this.style&&"cross"!==this.style&&(c.color=a.toJSON())};Object.defineProperty(f.prototype,"path",{set:function(a){this.style="path";this._set("path",a)},enumerable:!0,configurable:!0});f.prototype.clone=function(){return new e({angle:this.angle,color:h.clone(this.color),outline:this.outline&&this.outline.clone(),path:this.path,size:this.size,style:this.style,xoffset:this.xoffset,yoffset:this.yoffset})};
var e;d([c.property()],f.prototype,"color",void 0);d([c.writer("color")],f.prototype,"writeColor",null);d([c.enumeration.serializable()({esriSMS:"simple-marker"})],f.prototype,"type",void 0);d([c.property()],f.prototype,"size",void 0);d([c.property({type:g.apiValues,json:{read:g.read,write:g.write}})],f.prototype,"style",void 0);d([c.property({type:String,json:{write:!0}})],f.prototype,"path",null);d([c.property({type:n,json:{default:null,write:!0}})],f.prototype,"outline",void 0);return f=e=d([c.subclass("esri.symbols.SimpleMarkerSymbol")],
f)}(c.declared(f))})},"esri/symbols/TextSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../Color ../core/lang ../core/screenUtils ../core/accessorSupport/decorators ./Font ./Symbol".split(" "),function(b,e,m,d,k,l,h,a,c,f){return function(b){function f(a,d,f){a=b.call(this,a)||this;a.backgroundColor=null;a.borderLineColor=null;a.borderLineSize=null;a.font=new c;a.horizontalAlignment="center";a.kerning=!0;a.haloColor=null;a.haloSize=
null;a.rightToLeft=null;a.rotated=!1;a.text="";a.type="text";a.verticalAlignment=null;a.xoffset=0;a.yoffset=0;a.angle=0;a.width=null;return a}m(f,b);e=f;f.prototype.normalizeCtorArgs=function(a,c,b){if(a&&"string"!==typeof a)return a;var d={};a&&(d.text=a);c&&(d.font=c);b&&(d.color=b);return d};f.prototype.clone=function(){return new e({angle:this.angle,backgroundColor:l.clone(this.backgroundColor),borderLineColor:l.clone(this.borderLineColor),borderLineSize:this.borderLineSize,color:l.clone(this.color),
font:this.font&&this.font.clone(),haloColor:l.clone(this.haloColor),haloSize:this.haloSize,horizontalAlignment:this.horizontalAlignment,kerning:this.kerning,rightToLeft:this.rightToLeft,rotated:this.rotated,text:this.text,verticalAlignment:this.verticalAlignment,width:this.width,xoffset:this.xoffset,yoffset:this.yoffset})};var e;d([a.property({type:k,json:{write:!0}})],f.prototype,"backgroundColor",void 0);d([a.property({type:k,json:{write:!0}})],f.prototype,"borderLineColor",void 0);d([a.property({type:Number,
json:{write:!0}})],f.prototype,"borderLineSize",void 0);d([a.property({type:c,json:{write:!0}})],f.prototype,"font",void 0);d([a.property({type:["left","right","center","justify"],json:{write:!0}})],f.prototype,"horizontalAlignment",void 0);d([a.property({type:Boolean,json:{write:!0}})],f.prototype,"kerning",void 0);d([a.property({type:k,json:{write:!0}})],f.prototype,"haloColor",void 0);d([a.property({type:Number,cast:h.toPt,json:{write:!0}})],f.prototype,"haloSize",void 0);d([a.property({type:Boolean,
json:{write:!0}})],f.prototype,"rightToLeft",void 0);d([a.property({type:Boolean,json:{write:!0}})],f.prototype,"rotated",void 0);d([a.property({type:String,json:{write:!0}})],f.prototype,"text",void 0);d([a.property({type:String,readOnly:!0})],f.prototype,"type",void 0);d([a.property({type:["baseline","top","middle","bottom"],json:{write:!0}})],f.prototype,"verticalAlignment",void 0);d([a.property({type:Number,cast:h.toPt,json:{write:!0}})],f.prototype,"xoffset",void 0);d([a.property({type:Number,
cast:h.toPt,json:{write:!0}})],f.prototype,"yoffset",void 0);d([a.property({type:Number,json:{read:function(a){return a&&-1*a},write:function(a,c){return c.angle=a&&-1*a}}})],f.prototype,"angle",void 0);d([a.property({type:Number,json:{write:!0}})],f.prototype,"width",void 0);return f=e=d([a.subclass("esri.symbols.TextSymbol")],f)}(a.declared(f))})},"esri/symbols/WebStyleSymbol":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/kebabDictionary ../core/Logger ../core/promiseUtils ../core/urlUtils ../core/accessorSupport/decorators ../portal/Portal ./Symbol ./support/Thumbnail".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g){var q=l.getLogger("esri.symbols.WebStyleSymbol"),p=k.strict()({styleSymbolReference:"web-style"});return function(e){function n(a){a=e.call(this,a)||this;a.styleName=null;a.portal=null;a.styleUrl=null;a.thumbnail=null;a.name=null;a.type="web-style";return a}m(n,e);l=n;n.prototype.read=function(a,c){this.portal=c?c.portal:void 0;this.inherited(arguments,[a,c])};n.prototype.clone=function(){return new l({name:this.name,styleUrl:this.styleUrl,styleName:this.styleName,
portal:this.portal})};n.prototype.fetchSymbol=function(){var a=this;return h.create(function(a){return b(["./support/styleUtils"],a)}).then(function(c){c=c.resolveWebStyleSymbol(a,{portal:a.portal});c.catch(function(a){q.error("#fetchSymbol()","Failed to create symbol from style",a)});return c})};var l;d([c.property({json:{write:!1}})],n.prototype,"color",void 0);d([c.property({type:String,json:{write:!0}})],n.prototype,"styleName",void 0);d([c.property({type:f,json:{write:!1}})],n.prototype,"portal",
void 0);d([c.property({type:String,json:{read:a.read,write:a.write}})],n.prototype,"styleUrl",void 0);d([c.property({type:g.default,json:{read:!1}})],n.prototype,"thumbnail",void 0);d([c.property({type:String,json:{write:!0}})],n.prototype,"name",void 0);d([c.property({type:p.apiValues,readOnly:!0,json:{type:p.jsonValues,read:!1,write:p.write}})],n.prototype,"type",void 0);return n=l=d([c.subclass("esri.symbols.WebStyleSymbol")],n)}(c.declared(n))})},"esri/symbols/support/jsonUtils":function(){define("require exports ../../core/Error ../../core/Warning ../CIMSymbol ../LabelSymbol3D ../LineSymbol3D ../MeshSymbol3D ../PictureFillSymbol ../PictureMarkerSymbol ../PointSymbol3D ../PolygonSymbol3D ../SimpleFillSymbol ../SimpleLineSymbol ../SimpleMarkerSymbol ../Symbol3D ../TextSymbol ../WebStyleSymbol ../callouts/LineCallout3D ./symbolConversion".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y){function x(a,c,b){c=a?A[a.type]||null:null;if(c)return c=new c,c.read(a,b),c;b&&b.messages&&a&&b.messages.push(new d("symbol:unsupported","Symbols of type '"+(a.type||"unknown")+"' are not supported",{definition:a,context:b}));return null}function w(a,c,b){if(!a)return null;if(b&&"web-scene"===b.origin&&!a.isInstanceOf(r)&&!a.isInstanceOf(u)){var d=y.to3D(a);if(d.symbol)return d.symbol.write(c,b);b.messages&&b.messages.push(new m("symbol:unsupported",
"Symbols of type '"+a.declaredClass+"' are not supported in scenes. Use 3D symbology instead when working with WebScene and SceneView",{symbol:a,context:b,error:d.error}));return null}return a.write(c,b)}Object.defineProperty(e,"__esModule",{value:!0});var A={esriSMS:t,esriPMS:f,esriTS:v,esriSLS:p,esriSFS:q,esriPFS:c,PointSymbol3D:n,LineSymbol3D:h,PolygonSymbol3D:g,MeshSymbol3D:a,LabelSymbol3D:l,styleSymbolReference:u,CIMSymbolReference:k};e.read=x;e.writeTarget=function(a,c,b,d){(a=w(a,{},d))&&(c[b]=
a)};e.write=w;e.fromJSON=function(a,c){return x(a,null,c)};e.readCallout3D=function(a,c){if(!a||!a.type)return null;var b=null;switch(a.type){case "line":b=new z}b&&b.read(a,c);return b}})},"esri/symbols/support/symbolConversion":function(){define("require exports ../../Color ../../symbols ../../core/Error ../../core/lang ../../core/Logger ../../core/mathUtils ../Font ./IconSymbol3DLayerResource".split(" "),function(b,e,m,d,k,l,h,a,c,f){function n(a){var c=a.color?a.color.clone():new m([255,255,255]),
b,e,h,n;if(a instanceof d.PictureMarkerSymbol)a.color&&0===a.color.r&&0===a.color.g&&0===a.color.b&&(c=new m([255,255,255])),b=new f.default({href:a.url}),e=a.width<=a.height?a.height:a.width,(g(a.xoffset)||g(a.yoffset))&&0<a.width&&0<a.height&&(n={x:-(a.xoffset||0)/a.width,y:(a.yoffset||0)/a.height});else{b=f.default;e=a.style;var l=q[e];l?e=l:(p.warn(e+' cannot be mapped to Icon symbol. Fallback to "circle"'),e="circle");b=new b({primitive:e});e=a.size;(g(a.xoffset)||g(a.yoffset))&&0<a.size&&(n=
{x:-(a.xoffset||0)/e,y:(a.yoffset||0)/e});a.outline&&0<a.outline.width&&(h={size:a.outline.width,color:a.outline.color?a.outline.color.clone():[255,255,255]})}return new d.PointSymbol3D(new d.IconSymbol3DLayer({size:e,resource:b,material:{color:c},outline:h,anchor:n?"relative":void 0,anchorPosition:n}))}function g(c){return a.isFinite(c)&&0!==c}Object.defineProperty(e,"__esModule",{value:!0});var q={circle:"circle",cross:"cross",diamond:"kite",square:"square",x:"x",triangle:"triangle",path:null},
p=h.getLogger("esri.symbols.support.symbolConversion");e.to3D=function(a,b,f,e){void 0===b&&(b=!1);void 0===f&&(f=!1);void 0===e&&(e=!0);if(!a)return{symbol:null};if(d.isSymbol3D(a)||a instanceof d.WebStyleSymbol)e=a.clone();else if(a instanceof d.SimpleLineSymbol)e=new d.LineSymbol3D(new d.LineSymbol3DLayer({size:a.width||1,material:{color:a.color?a.color.clone():[255,255,255]}}));else if(a instanceof d.SimpleMarkerSymbol)e=n(a);else if(a instanceof d.PictureMarkerSymbol)e=n(a);else if(a instanceof
d.SimpleFillSymbol)e=new d.FillSymbol3DLayer({material:{color:a.color?a.color.clone():[255,255,255,0]}}),a.outline&&(e.outline={size:a.outline.width||0,color:a.outline.color?a.outline.color.clone():[255,255,255]}),e=new d.PolygonSymbol3D(e);else if(a instanceof d.TextSymbol){var g;g=a.haloColor;var h=a.haloSize;g=g&&0<h?{color:l.clone(g),size:h}:null;h=a.font?a.font.clone():new c;e=new (e?d.LabelSymbol3D:d.PointSymbol3D)(new d.TextSymbol3DLayer({size:h.size,font:h,halo:g,material:{color:a.color.clone()},
text:a.text}))}else return{error:new k("symbol-conversion:unsupported-2d-symbol","2D symbol of type '"+(a.type||a.declaredClass)+"' is unsupported in 3D",{symbol:a})};b&&(e.id=a.id);if(f&&d.isSymbol3D(e))for(a=0;a<e.symbolLayers.length;++a)e.symbolLayers.getItemAt(a)._ignoreDrivers=!0;return{symbol:e}}})},"esri/core/mathUtils":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.isFinite=Number.isFinite||function(b){return"number"===typeof b&&window.isFinite(b)};
e.isNaN=Number.isNaN||function(b){return b!==b};e.nextHighestPowerOfTwo=function(b){--b;for(var d=1;32>d;d<<=1)b|=b>>d;return b+1}})},"esri/renderers/Renderer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/generatorHelper ../core/tsSupport/awaiterHelper @dojo/framework/shim/array @dojo/framework/shim/Set ../core/JSONSupport ../core/kebabDictionary ../core/accessorSupport/decorators ./support/AuthoringInfo".split(" "),function(b,
e,m,d,k,l,h,a,c,f,n,g){var q=new f.default({simple:"simple",uniqueValue:"unique-value",classBreaks:"class-breaks",heatmap:"heatmap",dotDensity:"dot-density",rasterStretch:"raster-stretch"},{ignoreUnknown:!0});return function(c){function b(a){a=c.call(this,a)||this;a.authoringInfo=null;a.type=null;return a}m(b,c);b.prototype.getRequiredFields=function(c){return l(this,void 0,void 0,function(){var b;return k(this,function(d){switch(d.label){case 0:if(!this.collectRequiredFields)return[2,[]];b=new a.default;
return[4,this.collectRequiredFields(b,c)];case 1:return d.sent(),[2,h.from(b).sort()]}})})};b.prototype.getSymbol=function(a,c){};b.prototype.getSymbols=function(){return[]};d([n.property({type:g,json:{write:!0}})],b.prototype,"authoringInfo",void 0);d([n.property({type:q.apiValues,readOnly:!0,json:{type:q.jsonValues,read:!1,write:{writer:q.write,ignoreOrigin:!0}}})],b.prototype,"type",void 0);return b=d([n.subclass("esri.renderers.Renderer")],b)}(n.declared(c))})},"esri/renderers/support/AuthoringInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/lang ../../core/accessorSupport/decorators ../../core/accessorSupport/ensureType ./AuthoringInfoVisualVariable ../../tasks/support/ColorRamp ../../tasks/support/colorRamps".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g){var q=new l.default({esriClassifyDefinedInterval:"defined-interval",esriClassifyEqualInterval:"equal-interval",esriClassifyManual:"manual",esriClassifyNaturalBreaks:"natural-breaks",esriClassifyQuantile:"quantile",esriClassifyStandardDeviation:"standard-deviation"}),p=new l.default({classedSize:"class-breaks-size",classedColor:"class-breaks-color",univariateColorSize:"univariate-color-size",relationship:"relationship",predominance:"predominance"}),t="inches feet yards miles nautical-miles millimeters centimeters decimeters meters kilometers decimal-degrees".split(" ");
return function(b){function e(a){a=b.call(this)||this;a.colorRamp=null;a.lengthUnit=null;a.visualVariables=null;return a}m(e,b);l=e;Object.defineProperty(e.prototype,"classificationMethod",{get:function(){var a=this._get("classificationMethod"),c=this.type;return c&&"relationship"!==c?"class-breaks-size"===c||"class-breaks-color"===c?a||"manual":null:a},set:function(a){this._set("classificationMethod",a)},enumerable:!0,configurable:!0});e.prototype.readColorRamp=function(a,c){if(a)return g.fromJSON(a)};
Object.defineProperty(e.prototype,"fields",{get:function(){return this.type&&"predominance"!==this.type?null:this._get("fields")},set:function(a){this._set("fields",a)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"field1",{get:function(){return this.type&&"relationship"!==this.type?null:this._get("field1")},set:function(a){this._set("field1",a)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"field2",{get:function(){return this.type&&"relationship"!==this.type?
null:this._get("field2")},set:function(a){this._set("field2",a)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"focus",{get:function(){return this.type&&"relationship"!==this.type?null:this._get("focus")},set:function(a){this._set("focus",a)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"numClasses",{get:function(){return this.type&&"relationship"!==this.type?null:this._get("numClasses")},set:function(a){this._set("numClasses",a)},enumerable:!0,configurable:!0});
Object.defineProperty(e.prototype,"standardDeviationInterval",{get:function(){var a=this.type;return a&&"relationship"!==a&&"class-breaks-size"!==a&&"class-breaks-color"!==a?null:this.classificationMethod&&"standard-deviation"!==this.classificationMethod?null:this._get("standardDeviationInterval")},set:function(a){this._set("standardDeviationInterval",a)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"type",{get:function(){return this._get("type")},set:function(a){var c=a;"classed-size"===
a?c="class-breaks-size":"classed-color"===a&&(c="class-breaks-color");this._set("type",c)},enumerable:!0,configurable:!0});e.prototype.clone=function(){return new l({classificationMethod:this.classificationMethod,colorRamp:h.clone(this.colorRamp),fields:this.fields&&this.fields.slice(0),field1:h.clone(this.field1),field2:h.clone(this.field2),focus:this.focus,numClasses:this.numClasses,lengthUnit:this.lengthUnit,standardDeviationInterval:this.standardDeviationInterval,type:this.type,visualVariables:this.visualVariables&&
this.visualVariables.map(function(a){return a.clone()})})};var l;d([a.property({type:q.apiValues,value:null,dependsOn:["type"],json:{type:q.jsonValues,read:q.read,write:q.write,origins:{"web-document":{default:"manual",type:q.jsonValues,read:q.read,write:q.write}}}})],e.prototype,"classificationMethod",null);d([a.property({type:n,json:{write:!0}})],e.prototype,"colorRamp",void 0);d([a.reader("colorRamp")],e.prototype,"readColorRamp",null);d([a.property({type:[String],value:null,dependsOn:["type"],
json:{write:!0}})],e.prototype,"fields",null);d([a.property({value:null,dependsOn:["type"],json:{write:!0}})],e.prototype,"field1",null);d([a.property({value:null,dependsOn:["type"],json:{write:!0}})],e.prototype,"field2",null);d([a.property({type:["HH","HL","LH","LL"],value:null,dependsOn:["type"],json:{write:!0}})],e.prototype,"focus",null);d([a.property({type:Number,value:null,dependsOn:["type"],json:{type:c.Integer,write:!0}})],e.prototype,"numClasses",null);d([a.property({type:t,json:{type:t,
read:!1,write:!1,origins:{"web-scene":{read:!0,write:!0}}}})],e.prototype,"lengthUnit",void 0);d([a.property({type:[.25,.33,.5,1],value:null,dependsOn:["classificationMethod","type"],json:{type:[.25,.33,.5,1],write:!0}})],e.prototype,"standardDeviationInterval",null);d([a.property({type:String,value:null,json:{type:p.jsonValues,read:p.read,write:p.write}})],e.prototype,"type",null);d([a.property({type:[f],json:{write:!0}})],e.prototype,"visualVariables",void 0);return e=l=d([a.subclass("esri.renderers.support.AuthoringInfo")],
e)}(a.declared(k))})},"esri/renderers/support/AuthoringInfoVisualVariable":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/accessorSupport/decorators ../../core/accessorSupport/decorators/cast".split(" "),function(b,e,m,d,k,l,h,a){var c=new l.default({percentTotal:"percent-of-total",ratio:"ratio",percent:"percent"}),f=new l.default({sizeInfo:"size",colorInfo:"color",transparencyInfo:"opacity",
rotationInfo:"rotation"}),n={key:function(a){return"number"===typeof a?"number":"string"},typeMap:{number:Number,string:String},base:null},g=["high-to-low","above-and-below","centered-on","extremes"],q="seconds minutes hours days months years".split(" ");return function(b){function e(a){a=b.call(this)||this;a.endTime=null;a.field=null;a.maxSliderValue=null;a.minSliderValue=null;a.startTime=null;a.type=null;a.units=null;return a}m(e,b);p=e;e.prototype.castEndTime=function(a){return"string"===typeof a||
"number"===typeof a?a:null};e.prototype.castStartTime=function(a){return"string"===typeof a||"number"===typeof a?a:null};Object.defineProperty(e.prototype,"style",{get:function(){return"color"===this.type?this._get("style"):null},set:function(a){this._set("style",a)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"theme",{get:function(){return"color"===this.type?this._get("theme")||"high-to-low":null},set:function(a){this._set("theme",a)},enumerable:!0,configurable:!0});e.prototype.clone=
function(){return new p({endTime:this.endTime,field:this.field,maxSliderValue:this.maxSliderValue,minSliderValue:this.minSliderValue,startTime:this.startTime,style:this.style,theme:this.theme,type:this.type,units:this.units})};var p;d([h.property({types:n,json:{write:!0}})],e.prototype,"endTime",void 0);d([a.cast("endTime")],e.prototype,"castEndTime",null);d([h.property({type:String,json:{write:!0}})],e.prototype,"field",void 0);d([h.property({type:Number,json:{write:!0}})],e.prototype,"maxSliderValue",
void 0);d([h.property({type:Number,json:{write:!0}})],e.prototype,"minSliderValue",void 0);d([h.property({types:n,json:{write:!0}})],e.prototype,"startTime",void 0);d([a.cast("startTime")],e.prototype,"castStartTime",null);d([h.property({type:c.apiValues,value:null,dependsOn:["type"],json:{type:c.jsonValues,read:c.read,write:c.write}})],e.prototype,"style",null);d([h.property({type:g,value:null,dependsOn:["type"],json:{type:g,write:!0}})],e.prototype,"theme",null);d([h.property({type:f.apiValues,
json:{type:f.jsonValues,read:f.read,write:f.write}})],e.prototype,"type",void 0);d([h.property({type:q,json:{type:q,write:!0}})],e.prototype,"units",void 0);return e=p=d([h.subclass("esri.renderers.support.AuthoringInfoVisualVariable")],e)}(h.declared(k))})},"esri/tasks/support/ColorRamp":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){return function(b){function a(a){a=
b.call(this)||this;a.type=null;return a}m(a,b);d([l.property({readOnly:!0,json:{read:!1,write:!0}})],a.prototype,"type",void 0);return a=d([l.subclass("esri.tasks.support.ColorRamp")],a)}(l.declared(k))})},"esri/tasks/support/colorRamps":function(){define(["require","exports","./AlgorithmicColorRamp","./ColorRamp","./MultipartColorRamp"],function(b,e,m,d,k){Object.defineProperty(e,"__esModule",{value:!0});e.types={key:"type",base:d,typeMap:{algorithmic:m,multipart:k}};e.fromJSON=function(b){return b&&
b.type?"algorithmic"===b.type?m.fromJSON(b):"multipart"===b.type?k.fromJSON(b):null:null}})},"esri/tasks/support/AlgorithmicColorRamp":function(){define("require exports ../../core/tsSupport/decorateHelper ../../core/tsSupport/declareExtendsHelper ../../Color ../../core/lang ../../core/accessorSupport/decorators ./ColorRamp".split(" "),function(b,e,m,d,k,l,h,a){return function(a){function c(c){c=a.call(this)||this;c.algorithm=null;c.fromColor=null;c.toColor=null;c.type="algorithmic";return c}d(c,
a);b=c;c.prototype.clone=function(){return new b({fromColor:l.clone(this.fromColor),toColor:l.clone(this.toColor),algorithm:this.algorithm})};var b;m([h.enumeration.serializable()({esriCIELabAlgorithm:"cie-lab",esriHSVAlgorithm:"hsv",esriLabLChAlgorithm:"lab-lch"})],c.prototype,"algorithm",void 0);m([h.property({type:k,json:{write:!0}})],c.prototype,"fromColor",void 0);m([h.property({type:k,json:{write:!0}})],c.prototype,"toColor",void 0);m([h.property({type:["algorithmic"]})],c.prototype,"type",
void 0);return c=b=m([h.subclass("esri.tasks.support.AlgorithmicColorRamp")],c)}(h.declared(a))})},"esri/tasks/support/MultipartColorRamp":function(){define("require exports ../../core/tsSupport/decorateHelper ../../core/tsSupport/declareExtendsHelper ../../core/lang ../../core/accessorSupport/decorators ./AlgorithmicColorRamp ./ColorRamp".split(" "),function(b,e,m,d,k,l,h,a){return function(a){function c(c){c=a.call(this)||this;c.colorRamps=null;c.type="multipart";return c}d(c,a);b=c;c.prototype.clone=
function(){return new b({colorRamps:k.clone(this.colorRamps)})};var b;m([l.property({type:[h],json:{write:!0}})],c.prototype,"colorRamps",void 0);m([l.property({type:["multipart"]})],c.prototype,"type",void 0);return c=b=m([l.subclass("esri.tasks.support.MultipartColorRamp")],c)}(l.declared(a))})},"esri/renderers/mixins/VisualVariablesRenderer":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/tsSupport/generatorHelper ../../core/tsSupport/awaiterHelper ../../core/Accessor ../../core/accessorSupport/decorators ../../layers/support/fieldUtils ../visualVariables/ColorVariable ../visualVariables/OpacityVariable ../visualVariables/RotationVariable ../visualVariables/SizeVariable ../visualVariables/VisualVariable ../visualVariables/VisualVariableFactory ../../symbols/support/utils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r){function v(a){return a&&"opacity"in a?a.opacity*v(a.parent):1}var u={base:p,key:"type",typeMap:{opacity:n,color:f,rotation:g,size:q}};return function(b){function f(){var a=null!==b&&b.apply(this,arguments)||this;a._vvFactory=new t;return a}m(f,b);Object.defineProperty(f.prototype,"visualVariables",{set:function(a){this._vvFactory.visualVariables=a;this._set("visualVariables",this._vvFactory.visualVariables)},enumerable:!0,configurable:!0});f.prototype.readVisualVariables=
function(a,c,b){return this._vvFactory.readVariables(a,c,b)};f.prototype.writeVisualVariables=function(a,c,b,d){c[b]=this._vvFactory.writeVariables(a,d)};f.prototype.getDisplayedSymbol=function(a,c){return l(this,void 0,void 0,function(){var b,d,f,e,g,h,p,n,l;return k(this,function(k){if(!a)return[2];b=v(a.layer||a.sourceLayer);d=this.getSymbol(a);if(!d)return[2];d=d.clone();if(!this.visualVariables)return[2,d];f=this._vvFactory;e=f.colorVariables;g=f.opacityVariables;h=f.sizeVariables;p=f.rotationVariables;
n=!!e.length&&e[e.length-1].getColor(a,c);l=g.length?g[g.length-1].getOpacity(a,c):null;null!=b&&(l=null!=l?l*b:b);r.applyColorToSymbol(d,n,l);h.forEach(function(b){return r.applySizeToSymbol(d,b.getSize(a,c),b.axis)});p.forEach(function(b){return r.applyRotationToSymbol(d,b.getRotationAngle(a,c),b.axis)});return[2,d]})})};f.prototype.getVisualVariableValues=function(a,c){return this._vvFactory.getVisualVariableValues(a,c)};f.prototype.hasVisualVariables=function(a,c){return a?!!this.getVisualVariablesForType(a,
c):!!(this.getVisualVariablesForType("size",c)||this.getVisualVariablesForType("color",c)||this.getVisualVariablesForType("opacity",c)||this.getVisualVariablesForType("rotation",c))};f.prototype.getVisualVariablesForType=function(a,c){var b=this.visualVariables;if(b&&(b=b.filter(function(b){return b.type===a&&("string"===typeof c?b.target===c:!1===c?!b.target:!0)}),!b||0!==b.length))return b};f.prototype.getSize=function(a,c){return this._vvFactory.getSize(a,c)};f.prototype.getSizeRangeAtScale=function(a,
c,b){return a?a.getSizeRangeAtScale(c,b):this._vvFactory.getSizeRangeAtScale(c,b)};f.prototype.getColor=function(a,c){return this._vvFactory.getColor(a,c)};f.prototype.getOpacity=function(a,c){return this._vvFactory.getOpacity(a,c)};f.prototype.getRotationAngle=function(a,c){return this._vvFactory.getRotationAngle(a,c)};f.prototype.collectVVRequiredFields=function(a,b){return l(this,void 0,void 0,function(){var d,f,e,g;return k(this,function(h){switch(h.label){case 0:d=[],this.visualVariables&&(d=
d.concat(this.visualVariables)),f=0,e=d,h.label=1;case 1:if(!(f<e.length))return[3,4];g=e[f];if(!g)return[3,3];g.field&&c.collectField(a,b,g.field);g.normalizationField&&c.collectField(a,b,g.normalizationField);return g.valueExpression?[4,c.collectArcadeFieldNames(a,b,g.valueExpression)]:[3,3];case 2:h.sent(),h.label=3;case 3:return f++,[3,1];case 4:return[2]}})})};d([a.property({types:[u],value:null,json:{write:!0}})],f.prototype,"visualVariables",null);d([a.reader("visualVariables",["visualVariables",
"rotationType","rotationExpression"])],f.prototype,"readVisualVariables",null);d([a.writer("visualVariables")],f.prototype,"writeVisualVariables",null);return f=d([a.subclass("esri.renderers.mixins.VisualVariablesRenderer")],f)}(a.declared(h))})},"esri/renderers/visualVariables/ColorVariable":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../Color ../../core/accessorSupport/decorators ./VisualVariable ./support/ColorStop ./support/utils ../../support/arcadeUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f){return function(b){function e(a){a=b.call(this,a)||this;a.type="color";a.normalizationField=null;return a}m(e,b);h=e;Object.defineProperty(e.prototype,"_cache",{get:function(){var a=f.createSyntaxTree(this.valueExpression);return{ipData:this._interpolateData(),hasExpression:!!this.valueExpression,compiledFunc:f.createFunction(a)}},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"stops",{set:function(a){a&&Array.isArray(a)&&(a=a.filter(function(a){return!!a}),
a.sort(function(a,c){return a.value-c.value}));this._set("stops",a)},enumerable:!0,configurable:!0});e.prototype.getColor=function(a,b){var d="number"===typeof a,e=d?null:a,g=e&&e.attributes,h=d?a:null,p=this._cache;a=p.ipData;var n=p.hasExpression,p=p.compiledFunc,l=this.field;if(!l&&!n)return(b=this.stops)&&b[0]&&b[0].color;"number"!==typeof h&&(n?(h=f.getViewInfo(b),e=f.createExecContext(e,h),h=f.executeFunction(p,e)):g&&(h=g[l]));e=this.normalizationField;g=g?parseFloat(g[e]):void 0;if(null!=
h&&(!e||d||!isNaN(g)&&0!==g)&&(isNaN(g)||d||(h/=g),d=c.lookupData(h,a)))return g=d[0],a=d[1],b=g===a?this.stops[g].color:k.blendColors(this.stops[g].color,this.stops[a].color,d[2],b&&b.color),new k(b)};e.prototype.clone=function(){return new h({field:this.field,normalizationField:this.normalizationField,valueExpression:this.valueExpression,valueExpressionTitle:this.valueExpressionTitle,stops:this.stops&&this.stops.map(function(a){return a.clone()}),legendOptions:this.legendOptions&&this.legendOptions.clone()})};
e.prototype._interpolateData=function(){return this.stops&&this.stops.map(function(a){return a.value||0})};var h;d([l.property({readOnly:!0,dependsOn:["valueExpression","stops"]})],e.prototype,"_cache",null);d([l.property({type:["color"],json:{type:["colorInfo"]}})],e.prototype,"type",void 0);d([l.property({type:String,json:{write:!0}})],e.prototype,"normalizationField",void 0);d([l.property({type:[a],json:{write:!0}})],e.prototype,"stops",null);return e=h=d([l.subclass("esri.renderers.visualVariables.ColorVariable")],
e)}(l.declared(h))})},"esri/renderers/visualVariables/VisualVariable":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/Logger ../../core/accessorSupport/decorators ../../core/accessorSupport/ensureType ./support/VisualVariableLegendOptions".split(" "),function(b,e,m,d,k,l,h,a,c,f){var n=h.getLogger("esri.renderers.visualVariables.VisualVariable"),g=new l.default({colorInfo:"color",
transparencyInfo:"opacity",rotationInfo:"rotation",sizeInfo:"size"});return function(b){function e(a){a=b.call(this,a)||this;a.index=null;a.type=null;a.field=null;a.valueExpression=null;a.valueExpressionTitle=null;a.legendOptions=null;return a}m(e,b);e.prototype.castField=function(a){return null==a?a:"function"===typeof a?(n.error(".field: field must be a string value"),null):c.ensureString(a)};e.prototype.clone=function(){};d([a.property()],e.prototype,"index",void 0);d([a.property({type:g.apiValues,
readOnly:!0,json:{read:g.read,write:g.write}})],e.prototype,"type",void 0);d([a.property({type:String,json:{write:!0}})],e.prototype,"field",void 0);d([a.cast("field")],e.prototype,"castField",null);d([a.property({type:String,json:{write:!0}})],e.prototype,"valueExpression",void 0);d([a.property({type:String,json:{write:!0}})],e.prototype,"valueExpressionTitle",void 0);d([a.property({type:f,json:{write:!0}})],e.prototype,"legendOptions",void 0);return e=d([a.subclass("esri.renderers.visualVariables.VisualVariable")],
e)}(a.declared(k))})},"esri/renderers/visualVariables/support/VisualVariableLegendOptions":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/accessorSupport/decorators ../../support/LegendOptions".split(" "),function(b,e,m,d,k,l){return function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.showLegend=null;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({title:this.title,showLegend:this.showLegend})};
var c;d([k.property({type:Boolean,json:{write:!0}})],a.prototype,"showLegend",void 0);return a=c=d([k.subclass("esri.renderers.visualVariables.support.VisualVariableLegendOptions")],a)}(k.declared(l.default))})},"esri/renderers/support/LegendOptions":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});
b=function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.title=null;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({title:this.title})};var c;d([l.property({type:String,json:{write:!0}})],a.prototype,"title",void 0);return a=c=d([l.subclass("esri.renderers.support.LegendOptions")],a)}(l.declared(k));e.LegendOptions=b;e.default=b})},"esri/renderers/visualVariables/support/ColorStop":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../Color ../../../core/JSONSupport ../../../core/accessorSupport/decorators ../../../core/accessorSupport/ensureType".split(" "),
function(b,e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this,a)||this;a.color=null;a.label=null;a.value=null;return a}m(b,c);e=b;b.prototype.writeValue=function(a,c,b){c[b]=null==a?0:a};b.prototype.clone=function(){return new e({color:this.color&&this.color.clone(),label:this.label,value:this.value})};var e;d([h.property({type:k,json:{type:[a.Integer],write:!0}})],b.prototype,"color",void 0);d([h.property({type:String,json:{write:!0}})],b.prototype,"label",void 0);d([h.property({type:Number,
json:{write:{allowNull:!0}}})],b.prototype,"value",void 0);d([h.writer("value")],b.prototype,"writeValue",null);return b=e=d([h.subclass("esri.renderers.visualVariables.support.ColorStop")],b)}(h.declared(l))})},"esri/renderers/visualVariables/support/utils":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.isGraphic=function(b){return b&&"esri.Graphic"===b.declaredClass};e.lookupData=function(b,d){if(d){var e=0,l=d.length-1;d.some(function(d,
a){if(b<d)return l=a,!0;e=a;return!1});return[e,l,(b-d[e])/(d[l]-d[e])]}}})},"esri/support/arcadeUtils":function(){define("require exports ../arcade/arcade ../arcade/Dictionary ../arcade/Feature ../core/lang ../core/promiseUtils ../renderers/visualVariables/support/sizeVariableUtils".split(" "),function(b,e,m,d,k,l,h,a){function c(a){var c;try{c=a?m.parseScript(a):null}catch(t){c=null}return c}function f(a){a=c(a);return!!a&&m.scriptUsesGeometryEngine(a)}Object.defineProperty(e,"__esModule",{value:!0});
var n=/^\$feature\./i,g={vars:{$feature:"any",$view:"any"},spatialReference:null};e.createSyntaxTree=c;e.createFunction=function(a,b){b=b||l.clone(g);a="string"===typeof a?c(a):a;if(!a)return null;var d;try{d=a?m.compileScript(a,b):null}catch(r){d=null}return d};e.createExecContext=function(a,c){return{vars:{$feature:null==a?new k:k.createFromGraphic(a),$view:c&&c.view},spatialReference:c&&c.sr}};e.createFeature=function(a,c,b){return k.createFromGraphicLikeObject(c,a,b)};e.updateExecContext=function(a,
c){a.vars.$feature=c};e.evalSyntaxTree=function(a,c){var b;try{b=m.executeScript(a,c,c.spatialReference)}catch(r){b=null}return b};e.executeFunction=function(a,c){var b;try{b=a?a(c,c.spatialReference):null}catch(r){b=null}return b};e.executeAsyncFunction=function(a,c){try{return a?a(c,c.spatialReference):h.resolve(null)}catch(t){return h.resolve(null)}};e.extractFieldNames=function(a){if(!a)return[];a="string"===typeof a?c(a):a;if(!a)return[];var b=[];m.extractFieldLiterals(a).forEach(function(a){n.test(a)&&
(a=a.replace(n,""),b.push(a))});b.sort();return b.filter(function(a,c){return 0===c||b[c-1]!==a})};e.dependsOnView=function(a){return m.referencesMember(a,"$view")};e.hasVariable=function(a,c){return a?m.referencesMember(a,c):!1};e.getViewInfo=function(a){if(a&&(null!=a.spatialReference||null!=a.scale&&null!=a.viewingMode))return{view:a.viewingMode&&null!=a.scale?new d({viewingMode:a.viewingMode,scale:a.scale}):null,sr:a.spatialReference}};e.convertServiceUrlToWorkspace=function(a,c){var b=m.featureSetUtils();
return b?b.createFeatureSetCollectionFromService(a,c):null};e.convertFeatureLayerToFeatureSet=function(a,c){if(null===a)return null;var b=m.featureSetUtils();return b?b.constructFeatureSet(a,c):null};e.convertMapToFeatureSetCollection=function(a){if(null===a||null===a.map)return null;var c=m.featureSetUtils();return c?c.createFeatureSetCollectionFromMap(a.map,a.spatialReference):null};e.loadScriptDependencies=function(a,c,b){void 0===b&&(b=[]);return m.loadScriptDependencies(a,c,b)};e.enableGeometryOperations=
function(){return m.enableGeometrySupport()};e.enableFeatureSetOperations=function(){return m.enableFeatureSetSupport()};e.applyTextFormattingHTML=function(a){var c=/(\n)/gi;return"string"===typeof a?a.replace(c,'\x3cbr class\x3d"esri-text-new-line" /\x3e'):a};e.hasGeometryOperations=function(c){if(!c)return!1;if("simple"===c.type||"class-breaks"===c.type||"unique-value"===c.type||"dot-density"===c.type){if("dot-density"===c.type){var b=c.attributes.some(function(a){return f(a.valueExpression)});
if(b)return b}b=c.visualVariables;b=!!b&&b.some(function(c){var b=f(c.valueExpression);"size"===c.type&&(a.isSizeVariable(c.minSize)&&(b=b||f(c.minSize.valueExpression)),a.isSizeVariable(c.maxSize)&&(b=b||f(c.maxSize.valueExpression)));return b});return"valueExpression"in c&&f(c.valueExpression)?!0:b}return"esri.layers.support.LabelClass"===c.declaredClass?(c=c.labelExpressionInfo&&c.labelExpressionInfo.expression,!(!c||!f(c))||!1):"esri.PopupTemplate"===c.declaredClass?!!c.expressionInfos&&c.expressionInfos.some(function(a){return f(a.expression)}):
!1}})},"esri/arcade/arcade":function(){define("require exports ./arcadeCompiler ./arcadeRuntime ./parser ./treeAnalysis ../core/has ../core/promiseUtils".split(" "),function(b,e,m,d,k,l,h,a){function c(a,c){if(null===A)throw Error("Async Arcade must be enabled for this script");return h("csp-restrictions")||!1===y?function(c,b){return A.executeScript(a,c,b)}:m.compileScript(a,c,!0)}function f(a,c){void 0===c&&(c=[]);return k.parseScript(a,c)}function n(a,c,b){if(!0===c.useAsync||!0===a.isAsync){if(null===
A)throw Error("Async Arcade must be enabled for this script");return A.executeScript(a,c,b)}return d.executeScript(a,c,b)}function g(a,c){return d.referencesMember(a,c)}function q(a,c){void 0===c&&(c=[]);void 0===a.usesGeometry&&l.findScriptDependencies(a,c);return!0===a.usesGeometry}function p(){return F?F:F=a.create(function(a,c){b(["../geometry/geometryEngine","./functions/geomsync"],function(c,b){w=!0;b.setGeometryEngine(c);a(!0)},function(a){c(a)})})}function t(){return null!==C?C:C=m.enableAsyncSupport().then(function(){return a.create(function(a,
c){b(["./arcadeAsyncRuntime"],function(b){try{A=b;b=0;for(var d=B;b<d.length;b++){var f=d[b];A.extend(f);m.extend(f,"async")}B=null;a(!0)}catch(M){c(M)}},c)})})}function r(){return A?!0:!1}function v(){return E?E:E=t().then(function(){return a.create(function(a,c){b(["./featureSetUtils","./functions/featuresetbase","./functions/featuresetgeom","./functions/featuresetstats","./functions/featuresetstring"],function(b,d,f,e,g){try{G=b,A.extend([d,f,e,g]),m.extend([d,f,e,g],"async"),x=!0,a(!0)}catch(O){c(O)}},
c)})})}function u(a,c){void 0===c&&(c=[]);void 0===a.usesFeatureSet&&l.findScriptDependencies(a,c);return!0===a.usesFeatureSet}function z(a,c){if(c)for(var b=0;b<c.length;b++)if(g(a,c[b]))return!0;return!1}Object.defineProperty(e,"__esModule",{value:!0});var y=function(){if(h("csp-restrictions"))return!1;try{return(new Function("function* test() {}; return true"))()}catch(Q){return!1}}(),x=!1,w=!1,A=null,B=[];e.compileScript=function(a,b){return!0===b.useAsync||!0===a.isAsync?c(a,b):h("csp-restrictions")?
function(c,b){return d.executeScript(a,c,b)}:m.compileScript(a,b)};e.extend=function(a){d.extend(a);m.extend(a,"sync");null===A?B.push(a):(m.extend(a,"async"),A.extend(a))};e.parseScript=f;e.validateScript=function(a,c,b){void 0===b&&(b="");return k.validateScript(a,c,b)};e.scriptCheck=function(a,c,b,d){void 0===d&&(d="");return k.scriptCheck(a,c,b,d)};e.parseAndExecuteScript=function(a,c,b,d){void 0===d&&(d=[]);a=k.parseScript(a,d);return n(a,c,b)};e.executeScript=n;e.referencesMember=g;e.referencesFunction=
function(a,c){return d.referencesFunction(a,c)};e.extractFieldLiterals=function(a,c){void 0===c&&(c=!1);return k.extractFieldLiterals(a,c)};e.scriptUsesGeometryEngine=q;var F=null;e.enableGeometrySupport=p;var C=null;e.enableAsyncSupport=t;e.isFeatureSetSupportEnabled=function(){return x};e.isAsyncEnabled=r;e.isGeometryEnabled=function(){return w};var E=null;e.enableFeatureSetSupport=v;e.scriptUsesFeatureSet=u;e.scriptIsAsync=function(a,c){void 0===c&&(c=[]);void 0===a.isAsync&&l.findScriptDependencies(a,
c);return!0===a.isAsync};e.loadScriptDependencies=function(c,b,d,e){void 0===d&&(d=[]);void 0===e&&(e=!1);return a.create(function(g,h){var n="string"===typeof c?f(c):c,l=[];n&&(!1===w&&(q(n)||e)&&l.push(p()),!1===r()&&(!0===n.isAsync||b)&&l.push(t()),!1===x&&(u(n)||z(n,d))&&l.push(v()));l?a.all(l).then(function(){g(!0)},h):g(!0)})};e.scriptTouchesGeometry=function(a){if(q(a))return!0;a=l.findFunctionCalls(a,!0);return-1<a.indexOf("geometry")||-1<a.indexOf("feature")?!0:!1};var G=null;e.featureSetUtils=
function(){return G}})},"esri/arcade/arcadeCompiler":function(){define("require exports ./Attachment ./Dictionary ./Feature ./ImmutablePathArray ./ImmutablePointArray ./languageUtils ./treeAnalysis ./functions/date ./functions/geometry ./functions/geomsync ./functions/maths ./functions/stats ./functions/string ../core/promiseUtils ../geometry/Extent ../geometry/Geometry ../geometry/Multipoint ../geometry/Point ../geometry/Polygon ../geometry/Polyline ../geometry/SpatialReference".split(" "),function(b,
e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x,w,A){function B(a,c,b){try{return b(a,null,c)}catch(wa){throw wa;}}function F(a){return a instanceof Error?r.reject(a):r.reject(Error(a))}function C(a,b){try{switch(b.type){case "EmptyStatement":return"lc.voidOperation";case "VariableDeclarator":return R(a,b);case "VariableDeclaration":for(var d=[],f=0;f<b.declarations.length;f++)d.push(C(a,b.declarations[f]));return d.join("\n")+" \n lastStatement\x3d  lc.voidOperation; \n";case "BlockStatement":return V(a,
b);case "FunctionDeclaration":var e=b.id.name.toLowerCase(),g={isAsync:a.isAsync,applicationCache:void 0===a.applicationCache?null:a.applicationCache,spatialReference:a.spatialReference,console:a.console,lrucache:a.lrucache,services:a.services,symbols:a.symbols,mangleMap:a.mangleMap,localScope:{_SymbolsMap:{}},depthCounter:a.depthCounter+1,globalScope:a.globalScope};if(64<g.depthCounter)throw Error("Exceeded maximum function depth");for(var d="new lc.SizzleFunction( lang.functionDepthchecker(function() { var lastStatement \x3d lc.voidOperation; \n   var lscope \x3d runtimeCtx.localStack[runtimeCtx.localStack.length-1];\n",
h=0;h<b.params.length;h++){var p=b.params[h].name.toLowerCase(),n=da(p,a);g.localScope._SymbolsMap[p]=n;g.mangleMap[p]=n;d+="lscope['"+n+"']\x3darguments["+h.toString()+"];\n"}!0===a.isAsync?(d=d+"return lang.__awaiter(this, void 0, void 0, function* () {\n"+(V(g,b.body)+"\n return lastStatement; "),d+="});  }, runtimeCtx))\n lastStatement \x3d lc.voidOperation; \n"):(d+=V(g,b.body)+"\n return lastStatement; }, runtimeCtx))",d+="\n lastStatement \x3d lc.voidOperation; \n");void 0!==a.globalScope[e]?
f="gscope['"+e+"']\x3d"+d:void 0!==a.globalScope._SymbolsMap[e]?f="gscope['"+a.globalScope._SymbolsMap[e]+"']\x3d"+d:(n=da(e,a),a.globalScope._SymbolsMap[e]=n,a.mangleMap[e]=n,f="gscope['"+n+"']\x3d"+d);return f;case "ReturnStatement":var l;l=null===b.argument?"return lc.voidOperation":"return "+C(a,b.argument)+"";return l;case "IfStatement":if("AssignmentExpression"===b.test.type||"UpdateExpression"===b.test.type)throw Error(c.nodeErrorMessage(b.test,"RUNTIME","CANNOT_USE_ASSIGNMENT_IN_CONDITION"));
var k=C(a,b.test),m=aa(a),r="var "+m+" \x3d "+k+";\n if ("+m+" \x3d\x3d\x3d true) {\n"+Q(a,b.consequent)+"\n }\n",r=null!==b.alternate?r+("else if ("+m+"\x3d\x3d\x3dfalse)   { \n"+Q(a,b.alternate)+"}\n"):r+("else if ("+m+"\x3d\x3d\x3dfalse) { \n lastStatement \x3d lc.voidOperation;\n }\n");return r+="else { lang.error({type: '"+b.type+"'},'RUNTIME','CANNOT_USE_NONBOOLEAN_IN_CONDITION'); \n}\n";case "ExpressionStatement":var t;t="AssignmentExpression"===b.expression.type?"lastStatement \x3d lc.voidOperation; "+
C(a,b.expression)+"; \n ":"lastStatement \x3d "+C(a,b.expression)+"; ";return t;case "AssignmentExpression":return G(a,b);case "UpdateExpression":return E(a,b);case "BreakStatement":return"break";case "ContinueStatement":return"continue";case "ForStatement":d="lastStatement \x3d lc.voidOperation; \n";null!==b.init&&(d+=C(a,b.init)+"; ");var q=aa(a),x=aa(a),d=d+("var "+q+" \x3d true; ")+"\n do { ";null!==b.update&&(d+=" if ("+q+"\x3d\x3d\x3dfalse) {\n "+C(a,b.update)+"  \n}\n "+q+"\x3dfalse; \n");
null!==b.test&&(d+="var "+x+" \x3d "+C(a,b.test)+"; ",d+="if ("+x+"\x3d\x3d\x3dfalse) { break; } else if ("+x+"!\x3d\x3dtrue) { lang.error({type: '"+b.type+"'},'RUNTIME','CANNOT_USE_NONBOOLEAN_IN_CONDITION');   }\n");d+=C(a,b.body);null!==b.update&&(d+="\n "+C(a,b.update));return d+("\n"+q+" \x3d true; \n} while(true);  lastStatement \x3d lc.voidOperation; ");case "ForInStatement":var B=aa(a),v=aa(a),u=aa(a),w="var "+B+" \x3d "+C(a,b.right)+";\n";"VariableDeclaration"===b.left.type&&(w+=C(a,b.left));
var y="VariableDeclaration"===b.left.type?b.left.declarations[0].id.name:b.left.name,y=y.toLowerCase(),d="";null!==a.localScope&&(void 0!==a.localScope[y]?d="lscope['"+y+"']":void 0!==a.localScope._SymbolsMap[y]&&(d="lscope['"+a.localScope._SymbolsMap[y]+"']"));""===d&&(void 0!==a.globalScope[y]?d="gscope['"+y+"']":void 0!==a.globalScope._SymbolsMap[y]&&(d="gscope['"+a.globalScope._SymbolsMap[y]+"']"));w=w+("if ("+B+"\x3d\x3d\x3dnull) {  lastStatement \x3d lc.voidOperation; }\n ")+("else if (lc.isArray("+
B+") || lc.isString("+B+")) {")+("var "+v+"\x3d"+B+".length; \n")+("for(var "+u+"\x3d0; "+u+"\x3c"+v+"; "+u+"++) {\n");w+=d+"\x3d"+u+";\n";w+=C(a,b.body);w+="\n}\n";w+=" lastStatement \x3d lc.voidOperation; \n";w+=" \n}\n";w+="else if (lc.isImmutableArray("+B+")) {";w=w+("var "+v+"\x3d"+B+".length(); \n")+("for(var "+u+"\x3d0; "+u+"\x3c"+v+"; "+u+"++) {\n");w+=d+"\x3d"+u+";\n";w+=C(a,b.body);w+="\n}\n";w+=" lastStatement \x3d lc.voidOperation; \n";w+=" \n}\n";w+="else if (( "+B+" instanceof lang.Dictionary) || ( "+
B+" instanceof lang.Feature)) {";w=w+("var "+v+"\x3d"+B+".keys(); \n")+("for(var "+u+"\x3d0; "+u+"\x3c"+v+".length; "+u+"++) {\n");w+=d+"\x3d"+v+"["+u+"];\n";w+=C(a,b.body);w+="\n}\n";w+=" lastStatement \x3d lc.voidOperation; \n";w+=" \n}\n";a.isAsync&&(w+="else if (lc.isFeatureSet("+B+")) {",w=w+("var "+v+"\x3d"+B+".iterator(runtimeCtx.progressTracker); \n")+("for(var "+u+"\x3dlang. graphicToFeature( yield "+v+".next(),"+B+"); "+u+"!\x3dnull; "+u+"\x3dlang. graphicToFeature( yield "+v+".next(),"+
B+")) {\n")+(d+"\x3d"+u+";\n"),w+=C(a,b.body),w+="\n}\n",w+=" lastStatement \x3d lc.voidOperation; \n",w+=" \n}\n");return w+"else { lastStatement \x3d lc.voidOperation; } \n";case "Identifier":return W(a,b);case "MemberExpression":var z;try{d=void 0,d=!0===b.computed?C(a,b.property):"'"+b.property.name+"'",z="lang.member("+C(a,b.object)+","+d+")"}catch(X){throw X;}return z;case "Literal":return null===b.value||void 0===b.value?"null":JSON.stringify(b.value);case "ThisExpression":throw Error(c.nodeErrorMessage(b,
"RUNTIME","NOTSUPPORTED"));case "CallExpression":try{if("Identifier"!==b.callee.type)throw Error(c.nodeErrorMessage(b,"RUNTIME","ONLYNODESSUPPORTED"));var A=b.callee.name.toLowerCase(),f="";null!==a.localScope&&(void 0!==a.localScope[A]?f="lscope['"+A+"']":void 0!==a.localScope._SymbolsMap[A]&&(f="lscope['"+a.localScope._SymbolsMap[A]+"']"));""===f&&(void 0!==a.globalScope[A]?f="gscope['"+A+"']":void 0!==a.globalScope._SymbolsMap[A]&&(f="gscope['"+a.globalScope._SymbolsMap[A]+"']"));if(""!==f){e=
"[";for(g=0;g<b.arguments.length;g++)0<g&&(e+=", "),e+=C(a,b.arguments[g]);e+="]";d=a.isAsync?"(yield lang.callfunc("+f+","+e+",runtimeCtx) )":"lang.callfunc("+f+","+e+",runtimeCtx)"}else throw Error(c.nodeErrorMessage(b,"RUNTIME","NOTFOUND"));}catch(X){throw X;}return d;case "UnaryExpression":var F;try{F="lang.unary("+C(a,b.argument)+",'"+b.operator+"')"}catch(X){throw X;}return F;case "BinaryExpression":var ua;try{ua="lang.binary("+C(a,b.left)+","+C(a,b.right)+",'"+b.operator+"')"}catch(X){throw X;
}return ua;case "LogicalExpression":var sa;try{if("AssignmentExpression"===b.left.type||"UpdateExpression"===b.left.type)throw Error(c.nodeErrorMessage(b.left,"RUNTIME","CANNOT_USE_ASSIGNMENT_IN_CONDITION"));if("AssignmentExpression"===b.right.type||"UpdateExpression"===b.right.type)throw Error(c.nodeErrorMessage(b.right,"RUNTIME","CANNOT_USE_ASSIGNMENT_IN_CONDITION"));if("\x26\x26"===b.operator||"||"===b.operator)sa="(lang.logicalCheck("+C(a,b.left)+") "+b.operator+" lang.logicalCheck("+C(a,b.right)+
"))";else throw Error(c.nodeErrorMessage(b,"RUNTIME","ONLYORORAND"));}catch(X){throw X;}return sa;case "ConditionalExpression":throw Error(c.nodeErrorMessage(b,"RUNTIME","NOTSUPPORTED"));case "ArrayExpression":try{d=[];for(f=0;f<b.elements.length;f++)"Literal"===b.elements[f].type?d.push(C(a,b.elements[f])):d.push("lang.aCheck("+C(a,b.elements[f])+",'ArrayExpression')");h="["+d.join(",")+"]"}catch(X){throw X;}return h;case "ObjectExpression":d="lang.dictionary([";for(f=0;f<b.properties.length;f++){var pa=
b.properties[f],qa="Identifier"===pa.key.type?"'"+pa.key.name+"'":C(a,pa.key),oa=C(a,pa.value);0<f&&(d+=",");d+="lang.strCheck("+qa+",'ObjectExpression'),lang.aCheck("+oa+", 'ObjectExpression')"}return d+"])";case "Property":throw Error("Should not get here");case "Array":throw Error(c.nodeErrorMessage(b,"RUNTIME","NOTSUPPORTED"));default:throw Error(c.nodeErrorMessage(b,"RUNTIME","UNREOGNISED"));}}catch(X){throw X;}}function E(a,c){var b=null,d="";if("MemberExpression"===c.argument.type)return b=
C(a,c.argument.object),d=!0===c.argument.computed?C(a,c.argument.property):"'"+c.argument.property.name+"'","lang.memberupdate("+b+","+d+",'"+c.operator+"',"+c.prefix+")";b=c.argument.name.toLowerCase();if(null!==a.localScope){if(void 0!==a.localScope[b])return"lang.update(lscope, '"+b+"','"+c.operator+"',"+c.prefix+")";if(void 0!==a.localScope._SymbolsMap[b])return"lang.update(lscope, '"+a.localScope._SymbolsMap[b]+"','"+c.operator+"',"+c.prefix+")"}if(void 0!==a.globalScope[b])return"lang.update(gscope, '"+
b+"','"+c.operator+"',"+c.prefix+")";if(void 0!==a.globalScope._SymbolsMap[b])return"lang.update(gscope, '"+a.globalScope._SymbolsMap[b]+"','"+c.operator+"',"+c.prefix+")";throw Error("Variable not recognised");}function G(a,c){var b=C(a,c.right),d=null,f="";if("MemberExpression"===c.left.type)return d=C(a,c.left.object),f=!0===c.left.computed?C(a,c.left.property):"'"+c.left.property.name+"'","lang.assignmember("+d+","+f+",'"+c.operator+"',"+b+")";d=c.left.name.toLowerCase();if(null!==a.localScope){if(void 0!==
a.localScope[d])return"lscope['"+d+"']\x3dlang.assign("+b+",'"+c.operator+"', lscope['"+d+"'])";if(void 0!==a.localScope._SymbolsMap[d])return"lscope['"+a.localScope._SymbolsMap[d]+"']\x3dlang.assign("+b+",'"+c.operator+"', lscope['"+a.localScope._SymbolsMap[d]+"'])"}if(void 0!==a.globalScope[d])return"gscope['"+d+"']\x3dlang.assign("+b+",'"+c.operator+"', gscope['"+d+"'])";if(void 0!==a.globalScope._SymbolsMap[d])return"gscope['"+a.globalScope._SymbolsMap[d]+"']\x3dlang.assign("+b+",'"+c.operator+
"', gscope['"+a.globalScope._SymbolsMap[d]+"'])";throw Error("Variable not recognised");}function Q(a,c){return"BlockStatement"===c.type?C(a,c):"ReturnStatement"===c.type||"BreakStatement"===c.type||"ContinueStatement"===c.type?C(a,c)+"; ":"UpdateExpression"===c.type?"lastStatement \x3d "+C(a,c)+"; ":"ExpressionStatement"===c.type?C(a,c):"ObjectExpression"===c.type?"lastStatement \x3d "+C(a,c)+"; ":C(a,c)+"; "}function V(a,c){for(var b="",d=0;d<c.body.length;d++)b="ReturnStatement"===c.body[d].type?
b+(C(a,c.body[d])+"; \n"):"BreakStatement"===c.body[d].type?b+(C(a,c.body[d])+"; \n"):"ContinueStatement"===c.body[d].type?b+(C(a,c.body[d])+"; \n"):"UpdateExpression"===c.body[d].type?b+("lastStatement \x3d "+C(a,c.body[d])+"; \n"):"ObjectExpression"===c.body[d].type?b+("lastStatement \x3d "+C(a,c.body[d])+"; \n"):b+(C(a,c.body[d])+" \n");return b}function R(c,b){var d=null===b.init?null:C(c,b.init);d===a.voidOperation&&(d=null);b=b.id.name.toLowerCase();if(null!==c.localScope){if(void 0!==c.localScope[b])return"lscope['"+
b+"']\x3d"+d+"; ";if(void 0!==c.localScope._SymbolsMap[b])return"lscope['"+c.localScope._SymbolsMap[b]+"']\x3d"+d+"; ";var f=da(b,c);c.localScope._SymbolsMap[b]=f;c.mangleMap[b]=f;return"lscope['"+f+"']\x3d"+d+"; "}if(void 0!==c.globalScope[b])return"gscope['"+b+"']\x3d"+d+"; ";if(void 0!==c.globalScope._SymbolsMap[b])return"gscope['"+c.globalScope._SymbolsMap[b]+"']\x3d"+d+"; ";f=da(b,c);c.globalScope._SymbolsMap[b]=f;c.mangleMap[b]=f;return"gscope['"+f+"']\x3d"+d+"; "}function I(a,b,f){b=b.toLowerCase();
switch(b){case "hasz":return a=a.hasZ,void 0===a?!1:a;case "hasm":return a=a.hasM,void 0===a?!1:a;case "spatialreference":return b=a.spatialReference._arcadeCacheId,void 0===b&&(f=!0,Object.freeze&&Object.isFrozen(a.spatialReference)&&(f=!1),f&&(ja++,b=a.spatialReference._arcadeCacheId=ja)),a=new d({wkt:a.spatialReference.wkt,wkid:a.spatialReference.wkid}),void 0!==b&&(a._arcadeCacheId="SPREF"+b.toString()),a}switch(a.type){case "extent":switch(b){case "xmin":case "xmax":case "ymin":case "ymax":case "zmin":case "zmax":case "mmin":case "mmax":return a=
a[b],void 0!==a?a:null;case "type":return"Extent"}break;case "polygon":switch(b){case "rings":return b=a.cache._arcadeCacheId,void 0===b&&(ja++,b=ja,a.cache._arcadeCacheId=b),a=new l(a.rings,a.spatialReference,!0===a.hasZ,!0===a.hasM,b);case "type":return"Polygon"}break;case "point":switch(b){case "x":case "y":case "z":case "m":return void 0!==a[b]?a[b]:null;case "type":return"Point"}break;case "polyline":switch(b){case "paths":return b=a.cache._arcadeCacheId,void 0===b&&(ja++,b=ja,a.cache._arcadeCacheId=
b),a=new l(a.paths,a.spatialReference,!0===a.hasZ,!0===a.hasM,b);case "type":return"Polyline"}break;case "multipoint":switch(b){case "points":return b=a.cache._arcadeCacheId,void 0===b&&(ja++,b=ja,a.cache._arcadeCacheId=b),a=new h(a.points,a.spatialReference,!0===a.hasZ,!0===a.hasM,b,1);case "type":return"Multipoint"}}throw Error(c.nodeErrorMessage(f,"RUNTIME","PROPERTYNOTFOUND"));}function W(a,b){try{var d=b.name.toLowerCase();if(null!==a.localScope){if(void 0!==a.localScope[d])return"lscope['"+
d+"']";if(void 0!==a.localScope._SymbolsMap[d])return"lscope['"+a.localScope._SymbolsMap[d]+"']"}if(void 0!==a.globalScope[d])return"gscope['"+d+"']";if(void 0!==a.globalScope._SymbolsMap[d])return"gscope['"+a.globalScope._SymbolsMap[d]+"']";throw Error(c.nodeErrorMessage(b,"RUNTIME","VARIABLENOTFOUND"));}catch(wa){throw wa;}}function M(c){return null===c?"":a.isArray(c)||a.isImmutableArray(c)?"Array":a.isDate(c)?"Date":a.isString(c)?"String":a.isBoolean(c)?"Boolean":a.isNumber(c)?"Number":c instanceof
m?"Attachment":c instanceof d?"Dictionary":c instanceof k?"Feature":c instanceof y?"Point":c instanceof x?"Polygon":c instanceof w?"Polyline":c instanceof z?"Multipoint":c instanceof v?"Extent":a.isFunctionParameter(c)?"Function":a.isFeatureSet(c)?"FeatureSet":a.isFeatureSetCollection(c)?"FeatureSetCollection":c===a.voidOperation?"":"number"===typeof c&&isNaN(c)?"Number":"Unrecognised Type"}function U(c,b,d,f){try{if(a.equalityTest(b[d],f))return b[d+1];var e=b.length-d;return 1===e?b[d]:2===e?null:
3===e?b[d+2]:U(c,b,d+2,f)}catch(T){throw T;}}function O(c,b,d,f){try{if(!0===f)return b[d+1];if(3===b.length-d)return b[d+2];var e=b[d+2];if(!1===a.isBoolean(e))throw Error("WHEN needs boolean test conditions");return O(c,b,d+2,e)}catch(T){throw T;}}function J(a,c){var b=a.length,d=Math.floor(b/2);if(0===b)return[];if(1===b)return[a[0]];var f=J(a.slice(0,d),c);a=J(a.slice(d,b),c);for(b=[];0<f.length||0<a.length;)0<f.length&&0<a.length?(d=c(f[0],a[0]),isNaN(d)&&(d=0),0>=d?(b.push(f[0]),f=f.slice(1)):
(b.push(a[0]),a=a.slice(1))):0<f.length?(b.push(f[0]),f=f.slice(1)):0<a.length&&(b.push(a[0]),a=a.slice(1));return b}function fa(a,c){try{var b=a.length,d=Math.floor(b/2);if(0===b)return r.resolve([]);if(1===b)return r.resolve([a[0]]);var f=[fa(a.slice(0,d),c),fa(a.slice(d,b),c)];return r.all(f).then(function(a){return H(a[0],a[1],c,[])})}catch(T){return r.reject(T)}}function H(a,c,b,d){return r.create(function(f,e){0<a.length||0<c.length?0<a.length&&0<c.length?b(a[0],c[0]).then(function(g){try{isNaN(g)&&
(g=1),0>=g?(d.push(a[0]),a=a.slice(1)):(d.push(c[0]),c=c.slice(1)),H(a,c,b,d).then(function(a){f(a)},e)}catch(ya){e(ya)}},e):0<a.length?(d.push(a[0]),a=a.slice(1),H(a,c,b,d).then(function(a){f(a)},e)):0<c.length&&(d.push(c[0]),c=c.slice(1),H(a,c,b,d).then(function(a){f(a)},e)):f(d)})}function da(a,c){c.symbols.symbolCounter++;return"_T"+c.symbols.symbolCounter.toString()}function aa(a){a.symbols.symbolCounter++;return"_Tvar"+a.symbols.symbolCounter.toString()}function oa(a,c,b){var d={};a||(a={});
b||(b={});d._SymbolsMap={};d.textformatting=1;d.infinity=1;d.pi=1;for(var f in c)d[f]=1;for(f in b)d[f]=1;for(f in a)d[f]=1;return d}function ga(b,d){for(var f={mode:d,compiled:!0,functions:{},signatures:[],failDefferred:F,standardFunction:B,standardFunctionAsync:B,evaluateIdentifier:la},e=0;e<b.length;e++)b[e].registerFunctions(f);if("sync"===d){for(var g in f.functions)ea[g]=new a.NativeFunction(f.functions[g]),Ea.prototype[g]=ea[g];for(e=0;e<f.signatures.length;e++)c.addFunctionDeclaration(f.signatures[e],
"sync")}else{for(g in f.functions)sa[g]=new a.NativeFunction(f.functions[g]),ra.prototype[g]=sa[g];for(e=0;e<f.signatures.length;e++)c.addFunctionDeclaration(f.signatures[e],"async")}}function la(a,c){c=c.name;if("_SymbolsMap"===c)throw"Illegal";if(0<a.localStack.length){if("_t"!==c.substr(0,2).toLowerCase()&&void 0!==a.localStack[a.localStack.length-1][c])return a.localStack[a.localStack.length-1][c];var b=a.mangleMap[c];if(void 0!==b&&void 0!==a.localStack[a.localStack.length-1][b])return a.localStack[a.localStack.length-
1][b]}if("_t"!==c.substr(0,2).toLowerCase()&&void 0!==a.globalScope[c]||1===a.globalScope._SymbolsMap[c])return a.globalScope[c];c=a.mangleMap[c];if(void 0!==c)return a.globalScope[c]}function Z(a){console.log(a)}Object.defineProperty(e,"__esModule",{value:!0});var ja=0,ea={};f.registerFunctions(ea,B);t.registerFunctions(ea,B);q.registerFunctions(ea,B);n.registerFunctions(ea,B);p.registerFunctions(ea,B);ea["typeof"]=function(c,b){return B(c,b,function(c,b,d){a.pcCheck(d,1,1);c=M(d[0]);if("Unrecognised Type"===
c)throw Error("Unrecognised Type");return c})};ea.iif=function(c,b){try{return B(c,b,function(c,b,d){a.pcCheck(d,3,3);if(!1===a.isBoolean(d[0]))throw Error("IF Function must have a boolean test condition");return d[0]?d[1]:d[2]})}catch(Ca){throw Ca;}};ea.decode=function(a,c){try{return B(a,c,function(c,b,d){if(2>d.length)throw Error("Missing Parameters");if(2===d.length)return d[1];if(0===(d.length-1)%2)throw Error("Must have a default value result.");return U(a,d,1,d[0])})}catch(Ca){throw Ca;}};
ea.when=function(c,b){try{return B(c,b,function(b,d,f){if(3>f.length)throw Error("Missing Parameters");if(0===f.length%2)throw Error("Must have a default value result.");b=f[0];if(!1===a.isBoolean(b))throw Error("WHEN needs boolean test conditions");return O(c,f,0,b)})}catch(Ca){throw Ca;}};ea.top=function(c,b){return B(c,b,function(c,b,d){a.pcCheck(d,2,2);if(a.isArray(d[0]))return a.toNumber(d[1])>=d[0].length?d[0].slice(0):d[0].slice(0,a.toNumber(d[1]));if(a.isImmutableArray(d[0]))return a.toNumber(d[1])>=
d[0].length()?d[0].slice(0):d[0].slice(0,a.toNumber(d[1]));throw Error("Top cannot accept this parameter type");})};ea.first=function(c,b){return B(c,b,function(c,b,d){a.pcCheck(d,1,1);return a.isArray(d[0])?0===d[0].length?null:d[0][0]:a.isImmutableArray(d[0])?0===d[0].length()?null:d[0].get(0):null})};ea.sort=function(c,b){return B(c,b,function(b,d,f){a.pcCheck(f,1,2);d=f[0];a.isImmutableArray(d)&&(d=d.toArray());if(!1===a.isArray(d))throw Error("Illegal Argument");if(1<f.length){if(!1===a.isFunctionParameter(f[1]))throw Error("Illegal Argument");
var e=function(a,c){return na.callfunc(f[1],[a,c],b)};return c.isAsync?fa(d,e):d=J(d,function(a,c){return e(a,c)})}if(0===d.length)return[];for(var g={},h=0;h<d.length;h++){var p=M(d[h]);""!==p&&(g[p]=!0)}if(!0===g.Array||!0===g.Dictionary||!0===g.Feature||!0===g.Point||!0===g.Polygon||!0===g.Polyline||!0===g.Multipoint||!0===g.Extent||!0===g.Function)return d.slice(0);var h=0,p="",n;for(n in g)h++,p=n;return d=1<h||"String"===p?J(d,function(c,b){if(null===c||void 0===c||c===a.voidOperation)return null===
b||void 0===b||b===a.voidOperation?0:1;if(null===b||void 0===b||b===a.voidOperation)return-1;c=a.toString(c);b=a.toString(b);return c<b?-1:c===b?0:1}):"Number"===p?J(d,function(a,c){return a-c}):"Boolean"===p?J(d,function(a,c){return a===c?0:c?-1:1}):"Date"===p?J(d,function(a,c){return c-a}):d.slice(0)})};var sa={},pa;for(pa in ea)sa[pa]=new a.NativeFunction(ea[pa]);g.registerFunctions(ea,B);for(pa in ea)ea[pa]=new a.NativeFunction(ea[pa]);var Ea=function(){};Ea.prototype=ea;var ra=function(){};ra.prototype=
sa;e.functionHelper={fixSpatialReference:a.fixSpatialReference,parseArguments:function(a,c){for(var b=[],d=0;d<c.arguments.length;d++)b.push(C(a,c.arguments[d]));return b},standardFunction:B};e.extend=ga;e.executeScript=function(a,c,b){return a(c,b)};e.extractFieldLiterals=function(a,b){void 0===b&&(b=!1);return c.findFieldLiterals(a,b)};e.validateScript=function(a,b){return c.validateScript(a,b,"sync")};e.referencesMember=function(a,b){return c.referencesMember(a,b)};e.referencesFunction=function(a,
b){return c.referencesFunction(a,b)};var na={error:function(a,b,d){throw Error(c.nodeErrorMessage(a,b,d));},__awaiter:function(c,b,d,f){return r.create(function(d,e){function g(a){try{p(f.next(a))}catch(Da){e(Da)}}function h(a){try{p(f["throw"](a))}catch(Da){e(Da)}}function p(c){c.done?d(c.value):c.value&&a.isFeatureSet(c.value)?g(c.value):c.value&&c.value.then?c.value.then(g,h):g(c.value)}p((f=f.apply(c,b||[])).next())})},functionDepthchecker:function(a,c){return function(){c.depthCounter++;c.localStack.push([]);
if(64<c.depthCounter)throw Error("Exceeded maximum function depth");var b=a.apply(this,arguments);c.depthCounter--;--c.localStack.length;return b}},aCheck:function(b,d){if(a.isFunctionParameter(b))throw Error(c.nodeErrorMessage({type:d},"RUNTIME","FUNCTIONCONTEXTILLEGAL"));return b===a.voidOperation?null:b},Dictionary:d,Feature:k,dictionary:function(c){for(var b={},f=0;f<c.length;f+=2){if(a.isFunctionParameter(c[f+1]))throw Error("Illegal Argument");if(!1===a.isString(c[f]))throw Error("Illegal Argument");
b[c[f].toString()]=c[f+1]===a.voidOperation?null:c[f+1]}c=new d(b);c.immutable=!1;return c},strCheck:function(c,b){if(!1===a.isString(c))throw Error("Illegal Argument");return c},unary:function(b,d){if(a.isBoolean(b)){if("!"===d)return!b;if("-"===d)return-1*a.toNumber(b);if("+"===d)return 1*a.toNumber(b);throw Error(c.nodeErrorMessage({type:"UnaryExpression",operator:d,prefix:null,argument:null},"RUNTIME","NOTSUPPORTEDUNARYOPERATOR"));}if("-"===d)return-1*a.toNumber(b);if("+"===d)return 1*a.toNumber(b);
throw Error(c.nodeErrorMessage({type:"UnaryExpression",operator:d,prefix:null,argument:null},"RUNTIME","NOTSUPPORTEDUNARYOPERATOR"));},logicalCheck:function(b){if(!1===a.isBoolean(b))throw Error(c.nodeErrorMessage({type:"LogicalExpression",operator:null,left:null,right:null},"RUNTIME","ONLYORORAND"));return b},logical:function(b,d,f){if(a.isBoolean(b)&&a.isBoolean(d))switch(f){case "||":return b||d;case "\x26\x26":return b&&d}throw Error(c.nodeErrorMessage({type:"LogicalExpression",operator:null,
left:null,right:null},"RUNTIME","ONLYORORAND"));},binary:function(b,d,f){switch(f){case "\x3d\x3d":return a.equalityTest(b,d);case "\x3d":return a.equalityTest(b,d);case "!\x3d":return!a.equalityTest(b,d);case "\x3c":return a.greaterThanLessThan(b,d,f);case "\x3e":return a.greaterThanLessThan(b,d,f);case "\x3c\x3d":return a.greaterThanLessThan(b,d,f);case "\x3e\x3d":return a.greaterThanLessThan(b,d,f);case "+":return a.isString(b)||a.isString(d)?a.toString(b)+a.toString(d):a.toNumber(b)+a.toNumber(d);
case "-":return a.toNumber(b)-a.toNumber(d);case "*":return a.toNumber(b)*a.toNumber(d);case "/":return a.toNumber(b)/a.toNumber(d);case "%":return a.toNumber(b)%a.toNumber(d);default:throw Error(c.nodeErrorMessage({type:"BinaryExpression",operator:f,left:b,right:d},"RUNTIME","OPERATORNOTRECOGNISED"));}},assign:function(b,d,f){switch(d){case "\x3d":return b===a.voidOperation?null:b;case "/\x3d":return a.toNumber(f)/a.toNumber(b);case "*\x3d":return a.toNumber(f)*a.toNumber(b);case "-\x3d":return a.toNumber(f)-
a.toNumber(b);case "+\x3d":return a.isString(f)||a.isString(b)?a.toString(f)+a.toString(b):a.toNumber(f)+a.toNumber(b);case "%\x3d":return a.toNumber(f)%a.toNumber(b);default:throw Error(c.nodeErrorMessage({type:"AssignmentExpression",operator:d,left:null,right:null},"RUNTIME","OPERATORNOTRECOGNISED"));}},update:function(c,b,d,f){var e=a.toNumber(c[b]);c[b]="++"===d?e+1:e-1;return!1===f?e:"++"===d?e+1:e-1},graphicToFeature:function(a,c){return null===a?null:k.createFromGraphicLikeObject(a.geometry,
a.attributes,c)},memberupdate:function(c,b,f,e){var g;if(a.isArray(c))if(a.isNumber(b)){0>b&&(b=c.length+b);if(0>b||b>=c.length)throw Error("Assignment outside of array bounds");g=a.toNumber(c[b]);c[b]="++"===f?g+1:g-1}else throw Error("Invalid Parameter");else if(c instanceof d){if(!1===a.isString(b))throw Error("Dictionary accessor must be a string");if(!0===c.hasField(b))g=a.toNumber(c.field(b)),c.setField(b,"++"===f?g+1:g-1);else throw Error("Invalid Parameter");}else if(c instanceof k){if(!1===
a.isString(b))throw Error("Feature accessor must be a string");if(!0===c.hasField(b))g=a.toNumber(c.field(b)),c.setField(b,"++"===f?g+1:g-1);else throw Error("Invalid Parameter");}else{if(a.isImmutableArray(c))throw Error("Array is Immutable");throw Error("Invalid Parameter");}return!1===e?g:"++"===f?g+1:g-1},assignmember:function(c,b,f,e){if(a.isArray(c))if(a.isNumber(b)){0>b&&(b=c.length+b);if(0>b||b>c.length)throw Error("Assignment outside of array bounds");if(b===c.length&&"\x3d"!==f)throw Error("Invalid Parameter");
c[b]=this.assign(e,f,c[b])}else throw Error("Invalid Parameter");else if(c instanceof d){if(!1===a.isString(b))throw Error("Dictionary accessor must be a string");if(!0===c.hasField(b))c.setField(b,this.assign(e,f,c.field(b)));else{if("\x3d"!==f)throw Error("Invalid Parameter");c.setField(b,this.assign(e,f,null))}}else if(c instanceof k){if(!1===a.isString(b))throw Error("Feature accessor must be a string");if(!0===c.hasField(b))c.setField(b,this.assign(e,f,c.field(b)));else{if("\x3d"!==f)throw Error("Invalid Parameter");
c.setField(b,this.assign(e,f,null))}}else{if(a.isImmutableArray(c))throw Error("Array is Immutable");throw Error("Invalid Parameter");}},member:function(b,f){if(null===b)throw Error(c.nodeErrorMessage({type:"MemberExpression",object:null,property:null,computed:null},"RUNTIME","NOTFOUND"));if(b instanceof d||b instanceof k){if(a.isString(f))return b.field(f);throw Error(c.nodeErrorMessage({type:"MemberExpression",object:null,property:null,computed:null},"RUNTIME","INVALIDTYPE"));}if(b instanceof u){if(a.isString(f))return I(b,
f,"MemberExpression");throw Error(c.nodeErrorMessage({type:"MemberExpression",object:null,property:null,computed:null},"RUNTIME","INVALIDTYPE"));}if(a.isArray(b)){if(a.isNumber(f)&&isFinite(f)&&Math.floor(f)===f){0>f&&(f=b.length+f);if(f>=b.length||0>f)throw Error(c.nodeErrorMessage({type:"MemberExpression",object:null,property:null,computed:null},"RUNTIME","OUTOFBOUNDS"));return b[f]}throw Error(c.nodeErrorMessage({type:"MemberExpression",object:null,property:null,computed:null},"RUNTIME","INVALIDTYPE"));
}if(a.isString(b)){if(a.isNumber(f)&&isFinite(f)&&Math.floor(f)===f){0>f&&(f=b.length+f);if(f>=b.length||0>f)throw Error(c.nodeErrorMessage({type:"MemberExpression",object:null,property:null,computed:null},"RUNTIME","OUTOFBOUNDS"));return b[f]}throw Error(c.nodeErrorMessage({type:"MemberExpression",object:null,property:null,computed:null},"RUNTIME","INVALIDTYPE"));}if(a.isImmutableArray(b)&&a.isNumber(f)&&isFinite(f)&&Math.floor(f)===f){0>f&&(f=b.length()+f);if(f>=b.length()||0>f)throw Error(c.nodeErrorMessage({type:"MemberExpression",
object:null,property:null,computed:null},"RUNTIME","OUTOFBOUNDS"));return b.get(f)}throw Error(c.nodeErrorMessage({type:"MemberExpression",object:null,property:null,computed:null},"RUNTIME","INVALIDTYPE"));},callfunc:function(c,b,d){return c instanceof a.NativeFunction?c.fn(d,b):c instanceof a.SizzleFunction?c.fn.apply(this,b):c.apply(this,b)}};e.compileScript=function(c,b,f){void 0===b&&(b=null);void 0===f&&(f=!1);null===b&&(b={vars:{},customfunctions:{}});b={isAsync:f,globalScope:oa(b.vars,f?sa:
ea,b.customfunctions),localScope:null,mangleMap:{},console:Z,lrucache:b.lrucache,services:b.services,symbols:{symbolCounter:0}};c=C(b,c.body[0].body);""===c&&(c="lc.voidOperation; ");b={lc:a,lang:na,mangles:b.mangleMap,postProcess:function(c){c instanceof a.ReturnResult&&(c=c.value);c instanceof a.ImplicitResult&&(c=c.value);c===a.voidOperation&&(c=null);if(c===a.breakResult)throw Error("Cannot return BREAK");if(c===a.continueResult)throw Error("Cannot return CONTINUE");if(a.isFunctionParameter(c))throw Error("Cannot return FUNCTION");
return c},prepare:function(a,c,b){c||(c=new A({wkid:102100}));var f=a.vars,e=a.customfunctions,g=b?new ra:new Ea;f||(f={});e||(e={});var h=new d({newline:"\n",tab:"\t",singlequote:"'",doublequote:'"',forwardslash:"/",backwardslash:"\\"});h.immutable=!1;g._SymbolsMap={textformatting:1,infinity:1,pi:1};g.textformatting=h;g.infinity=Number.POSITIVE_INFINITY;g.pi=Math.PI;for(var p in e)g[p]=e[p],g._SymbolsMap[p]=1;for(p in f)g._SymbolsMap[p]=1,g[p]=f[p]&&"esri.Graphic"===f[p].declaredClass?k.createFromGraphic(f[p]):
f[p];return{localStack:[],isAsync:b,mangleMap:this.mangles,spatialReference:c,globalScope:g,progressTracker:void 0===a.progressTracker||null===a.progressTracker?r.createDeferred().promise:a.progressTracker,localScope:null,services:a.services,console:a.console?a.console:Z,lrucache:a.lrucache,symbols:{symbolCounter:0},depthCounter:1,applicationCache:void 0===a.applicationCache?null:a.applicationCache}}};return(new Function("context","spatialReference",f?"var runtimeCtx\x3dthis.prepare(context, spatialReference, true);\n var lc \x3d this.lc;  var lang \x3d this.lang; var gscope\x3druntimeCtx.globalScope; \nreturn lang.__awaiter(this, void 0, void 0, function* () {\n\n function mainBody() {\n var lastStatement\x3dlc.voidOperation;\n return lang.__awaiter(this, void 0, void 0, function* () {\n"+
c+"\n return lastStatement; }); } \n return this.postProcess(yield mainBody()); }); ":"var runtimeCtx\x3dthis.prepare(context, spatialReference, false);\n var lc \x3d this.lc;  var lang \x3d this.lang; var gscope\x3druntimeCtx.globalScope; \n function mainBody() {\n var lastStatement\x3dlc.voidOperation;\n "+c+"\n return lastStatement; } \n return this.postProcess(mainBody()); ")).bind(b)};e.enableAsyncSupport=function(){return r.create(function(a,c){b(["./functions/geomasync"],function(c){ga([c],
"async");a(!0)},function(a){c(a)})})}})},"esri/arcade/Attachment":function(){define(["require","exports","../core/tsSupport/extendsHelper","./Dictionary"],function(b,e,m,d){return function(b){function d(d,a,c,f,e){var g=b.call(this)||this;g.attachmentUrl=e;g.immutable=!1;g.setField("id",d);g.setField("name",a);g.setField("contenttype",c);g.setField("size",f);g.immutable=!0;return g}m(d,b);return d}(d)})},"esri/arcade/Dictionary":function(){define(["require","exports","./ImmutableArray","./languageUtils",
"../geometry/Geometry"],function(b,e,m,d,k){return function(){function b(d){this.declaredClass="esri.arcade.Dictionary";this.attributes=null;this.plain=!1;this.immutable=!0;this.attributes=d instanceof b?d.attributes:void 0===d?{}:null===d?{}:d}b.prototype.field=function(b){var a=b.toLowerCase();b=this.attributes[b];if(void 0!==b)return b;for(var c in this.attributes)if(c.toLowerCase()===a)return this.attributes[c];throw Error("Field not Found");};b.prototype.setField=function(b,a){if(this.immutable)throw Error("Dictionary is Immutable");
var c=b.toLowerCase();if(void 0===this.attributes[b])for(var d in this.attributes)if(d.toLowerCase()===c){this.attributes[d]=a;return}this.attributes[b]=a};b.prototype.hasField=function(b){var a=b.toLowerCase();if(void 0!==this.attributes[b])return!0;for(var c in this.attributes)if(c.toLowerCase()===a)return!0;return!1};b.prototype.keys=function(){var b=[],a;for(a in this.attributes)b.push(a);return b=b.sort()};b.prototype.castToText=function(){var b="",a;for(a in this.attributes){""!==b&&(b+=",");
var c=this.attributes[a];null==c?b+=JSON.stringify(a)+":null":d.isBoolean(c)||d.isNumber(c)||d.isString(c)?b+=JSON.stringify(a)+":"+JSON.stringify(c):c instanceof k?b+=JSON.stringify(a)+":"+d.toStringExplicit(c):c instanceof m?b+=JSON.stringify(a)+":"+d.toStringExplicit(c):c instanceof Array?b+=JSON.stringify(a)+":"+d.toStringExplicit(c):c instanceof Date?b+=JSON.stringify(a)+":"+JSON.stringify(c):null!==c&&"object"===typeof c&&void 0!==c.castToText&&(b+=JSON.stringify(a)+":"+c.castToText())}return"{"+
b+"}"};return b}()})},"esri/arcade/ImmutableArray":function(){define(["require","exports"],function(b,e){return function(){function b(b){void 0===b&&(b=[]);this._elements=b}b.prototype.length=function(){return this._elements.length};b.prototype.get=function(b){return this._elements[b]};b.prototype.toArray=function(){for(var b=[],e=0;e<this.length();e++)b.push(this.get(e));return b};return b}()})},"esri/arcade/languageUtils":function(){define("require exports dojo/number ../moment ./FunctionWrapper ./ImmutableArray ./ImmutablePathArray ./ImmutablePointArray ../geometry/Extent ../geometry/Geometry ../geometry/Multipoint ../geometry/Point ../geometry/Polygon ../geometry/Polyline ../geometry/support/coordsUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t){function r(a,c,b){if(""===c||null===c||void 0===c||c===b||c===b)return a;do a=a.replace(c,b);while(-1!==a.indexOf(c));return a}function v(a){return a instanceof fa||a instanceof k||a instanceof H}function u(a){return z(a)||x(a)||B(a)||y(a)||null===a||a===e.voidOperation||"number"===typeof a?!0:!1}function z(a){return"string"===typeof a||a instanceof String}function y(a){return"boolean"===typeof a}function x(a){return"number"===typeof a}function w(a){return a instanceof
Array}function A(a){return a instanceof l}function B(a){return a instanceof Date}function F(a,c){if(!1===isNaN(a)){if(void 0===c||null===c||""===c)return a.toString();c=r(c,"\u2030","");c=r(c,"\u00a4","");return m.format(a,{pattern:c})}return a.toString()}function C(a,c){a=d(a);return void 0===c||null===c||""===c?a.format():a.format(E(c))}function E(a){return a.replace(/(LTS)|L|l/g,function(a){return"["+a+"]"})}function G(a,c,b){switch(b){case "\x3e":return a>c;case "\x3c":return a<c;case "\x3e\x3d":return a>=
c;case "\x3c\x3d":return a<=c}return!1}function Q(c,b){if(c===b||null===c&&b===e.voidOperation||null===b&&c===e.voidOperation)return!0;if(B(c)&&B(b))return c.getTime()===b.getTime();if(c instanceof h||c instanceof a)return c.equalityTest(b);if(c instanceof g&&b instanceof g){var d=void 0,f=void 0,d=c.cache._arcadeCacheId,f=b.cache._arcadeCacheId;if(void 0!==d&&null!==d)return d===f}return void 0!==c&&void 0!==b&&null!==c&&null!==b&&"object"===typeof c&&"object"===typeof b&&(c._arcadeCacheId===b._arcadeCacheId&&
void 0!==c._arcadeCacheId&&null!==c._arcadeCacheId||c._underlyingGraphic===b._underlyingGraphic&&void 0!==c._underlyingGraphic&&null!==c._underlyingGraphic)?!0:!1}function V(a,c){if(z(a))return a;if(null===a)return"";if(x(a))return F(a,c);if(y(a))return a.toString();if(B(a))return C(a,c);if(a instanceof f)return JSON.stringify(a.toJSON());if(w(a)){c=[];for(var b=0;b<a.length;b++)c[b]=I(a[b]);return"["+c.join(",")+"]"}if(a instanceof l){c=[];for(b=0;b<a.length();b++)c[b]=I(a.get(b));return"["+c.join(",")+
"]"}return null!==a&&"object"===typeof a&&void 0!==a.castToText?a.castToText():v(a)?"object, Function":""}function R(a,b){if(z(a))return a;if(null===a)return"";if(x(a))return F(a,b);if(y(a))return a.toString();if(B(a))return C(a,b);if(a instanceof f)return a instanceof c?'{"xmin":'+a.xmin.toString()+',"ymin":'+a.ymin.toString()+","+(a.hasZ?'"zmin":'+a.zmin.toString()+",":"")+(a.hasM?'"mmin":'+a.mmin.toString()+",":"")+'"xmax":'+a.xmax.toString()+',"ymax":'+a.ymax.toString()+","+(a.hasZ?'"zmax":'+
a.zmax.toString()+",":"")+(a.hasM?'"mmax":'+a.mmax.toString()+",":"")+'"spatialReference":'+U(a.spatialReference)+"}":U(a.toJSON(),function(a,c){return a.key===c.key?0:"spatialReference"===a.key?1:"spatialReference"===c.key||a.key<c.key?-1:a.key>c.key?1:0});if(w(a)){b=[];for(var d=0;d<a.length;d++)b[d]=I(a[d]);return"["+b.join(",")+"]"}if(a instanceof l){b=[];for(d=0;d<a.length();d++)b[d]=I(a.get(d));return"["+b.join(",")+"]"}return null!==a&&"object"===typeof a&&void 0!==a.castToText?a.castToText():
v(a)?"object, Function":""}function I(a){return null===a?"null":y(a)||x(a)||z(a)?JSON.stringify(a):a instanceof f||a instanceof l||a instanceof Array?R(a):a instanceof Date?JSON.stringify(C(a,"")):null!==a&&"object"===typeof a&&void 0!==a.castToText?a.castToText():"null"}function W(a,c){return x(a)?a:null===a||""===a?0:B(a)?NaN:y(a)?a?1:0:w(a)||""===a||void 0===a?NaN:void 0!==c&&z(a)?(c=r(c,"\u2030",""),c=r(c,"\u00a4",""),m.parse(a,{pattern:c})):a===e.voidOperation?0:Number(a)}function M(a,c){var b;
c.fields.some(function(c){c.name===a&&(b=c.domain);return!!b});return b}function U(a,c){c||(c={});"function"===typeof c&&(c={cmp:c});var b="boolean"===typeof c.cycles?c.cycles:!1,d=c.cmp&&function(a){return function(c){return function(b,d){return a({key:b,value:c[b]},{key:d,value:c[d]})}}}(c.cmp),f=[];return function ja(a){a&&a.toJSON&&"function"===typeof a.toJSON&&(a=a.toJSON());if(void 0!==a){if("number"===typeof a)return isFinite(a)?""+a:"null";if("object"!==typeof a)return JSON.stringify(a);var c,
e;if(Array.isArray(a)){e="[";for(c=0;c<a.length;c++)c&&(e+=","),e+=ja(a[c])||"null";return e+"]"}if(null===a)return"null";if(-1!==f.indexOf(a)){if(b)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON");}var g=f.push(a)-1,h=Object.keys(a).sort(d&&d(a));e="";for(c=0;c<h.length;c++){var p=h[c],n=ja(a[p]);n&&(e&&(e+=","),e+=JSON.stringify(p)+":"+n)}f.splice(g,1);return"{"+e+"}"}}(a)}function O(a,c){if(c instanceof g)a.push(c.hasZ?c.hasM?[c.x,c.y,c.z,c.m]:[c.x,
c.y,c.z]:[c.x,c.y]);else throw Error("Invalid Argument");}Object.defineProperty(e,"__esModule",{value:!0});b=function(){return function(a){this.value=a}}();e.ReturnResultE=b;var J=function(){return function(a){this.value=a}}();e.ImplicitResultE=J;var fa=function(){return function(a){this.fn=a}}();e.NativeFunctionE=fa;var H=function(){return function(a){this.fn=a}}();e.SizzleFunctionE=H;e.NativeFunction=fa;e.ImplicitResult=J;e.ReturnResult=b;e.SizzleFunction=H;e.voidOperation={type:"VOID"};e.breakResult=
{type:"BREAK"};e.continueResult={type:"CONTINUE"};e.multiReplace=r;e.isFunctionParameter=v;e.isSimpleType=u;e.defaultUndefined=function(a,c){return void 0===a?c:a};e.isString=z;e.isBoolean=y;e.isNumber=x;e.isArray=w;e.isFeatureSet=function(a){return!0===(a&&a.declaredRootClass&&"esri.arcade.featureset.support.FeatureSet"===a.declaredRootClass)};e.isFeatureSetCollection=function(a){return!0===(a&&a.declaredRootClass&&"esri.arcade.featureSetCollection"===a.declaredRootClass)};e.isImmutableArray=A;e.isDate=
B;e.pcCheck=function(a,c,b){if(a.length<c||a.length>b)throw Error("Function called with wrong number of Parameters");};e.generateUUID=function(){var a=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(c){var b=(a+16*Math.random())%16|0;a=Math.floor(a/16);return("x"===c?b:b&3|8).toString(16)})};e.formatNumber=F;e.formatDate=C;e.standardiseDateFormat=E;e.greaterThanLessThan=function(a,c,b){if(null===a){if(null===c||c===e.voidOperation)return G(null,null,b);if(x(c))return G(0,
c,b);if(z(c)||y(c))return G(0,W(c),b);if(B(c))return G(0,c.getTime(),b)}if(a===e.voidOperation){if(null===c||c===e.voidOperation)return G(null,null,b);if(x(c))return G(0,c,b);if(z(c)||y(c))return G(0,W(c),b);if(B(c))return G(0,c.getTime(),b)}else if(x(a)){if(x(c))return G(a,c,b);if(y(c))return G(a,W(c),b);if(null===c||c===e.voidOperation)return G(a,0,b);if(z(c))return G(a,W(c),b);if(B(c))return G(a,c.getTime(),b)}else if(z(a)){if(z(c))return G(V(a),V(c),b);if(B(c))return G(W(a),c.getTime(),b);if(x(c))return G(W(a),
c,b);if(null===c||c===e.voidOperation)return G(W(a),0,b);if(y(c))return G(W(a),W(c),b)}else if(B(a)){if(B(c))return G(a,c,b);if(null===c||c===e.voidOperation)return G(a.getTime(),0,b);if(x(c))return G(a.getTime(),c,b);if(y(c)||z(c))return G(a.getTime(),W(c),b)}else if(y(a)){if(y(c))return G(a,c,b);if(x(c))return G(W(a),W(c),b);if(B(c))return G(W(a),c.getTime(),b);if(null===c||c===e.voidOperation)return G(W(a),0,b);if(z(c))return G(W(a),W(c),b)}return!Q(a,c)||"\x3c\x3d"!==b&&"\x3e\x3d"!==b?!1:!0};
e.equalityTest=Q;e.toString=V;e.toNumberArray=function(a){var c=[];if(!1===w(a))return null;if(a instanceof l){for(var b=0;b<a.length();b++)c[b]=W(a.get(b));return c}for(b=0;b<a.length;b++)c[b]=W(a[b]);return c};e.toStringExplicit=R;e.toNumber=W;e.toDate=function(a,c){return B(a)?a:z(a)&&(a=d(a,[void 0===c||null===c||""===c?d.ISO_8601:c]),a.isValid())?a.toDate():null};e.toDateM=function(a,c){return B(a)?d(a):z(a)&&(a=d(a,[void 0===c||null===c||""===c?d.ISO_8601:c]),a.isValid())?a:null};e.toBoolean=
function(a){return y(a)?a:z(a)?(a=a.toLowerCase(),"true"===a?!0:!1):x(a)?0===a||isNaN(a)?!1:!0:!1};e.fixSpatialReference=function(a,c){if(null===a||void 0===a)return null;if(null===a.spatialReference||void 0===a.spatialReference)a.spatialReference=c;return a};e.fixNullGeometry=function(a){return null===a?null:a instanceof g?"NaN"===a.x||null===a.x||isNaN(a.x)?null:a:a instanceof q?0===a.rings.length?null:a:a instanceof p?0===a.paths.length?null:a:a instanceof n?0===a.points.length?null:a:a instanceof
c?"NaN"===a.xmin||null===a.xmin||isNaN(a.xmin)?null:a:null};e.getDomainValue=function(a,c){if(!a||!a.domain)return null;var b=null;c="string"===a.field.type||"esriFieldTypeString"===a.field.type?V(c):W(c);for(var d=0;d<a.domain.codedValues.length;d++){var f=a.domain.codedValues[d];f.code===c&&(b=f)}return null===b?null:b.name};e.getDomainCode=function(a,c){if(!a||!a.domain)return null;var b=null;c=V(c);for(var d=0;d<a.domain.codedValues.length;d++){var f=a.domain.codedValues[d];f.name===c&&(b=f)}return null===
b?null:b.code};e.getDomain=function(a,c,b,d){void 0===b&&(b=null);if(!c||!c.fields)return null;for(var f=null,e=0;e<c.fields.length;e++){var g=c.fields[e];g.name.toLowerCase()===a.toString().toLowerCase()&&(f=g)}if(null===f)return null;var h,p;d||(d=b&&c.typeIdField&&b._field(c.typeIdField));null!=d&&c.types.some(function(a){return a.id===d?((h=a.domains&&a.domains[f.name])&&"inherited"===h.type&&(h=M(f.name,c),p=!0),!0):!1});p||h||(h=M(a,c));return{field:f,domain:h}};e.stableStringify=U;e.autoCastFeatureToGeometry=
function(a){if(null===a)return null;for(var c=[],b=0;b<a.length;b++){var d=a[b];d&&d.declaredClass&&"esri.arcade.Feature"===d.declaredClass?c.push(d.geometry()):c.push(d)}return c};e.autoCastArrayOfPointsToPolygon=function(c,b){if(w(c)||A(c)){var d=!1,f=!1,e=[];if(w(c)){for(var g=0;g<c.length;g++){var h=c[g];O(e,h)}0<e.length&&(b=c[0].spatialReference,d=c[0].hasZ,f=c[0].hasM)}else if(c instanceof a)e=c._elements,0<e.length&&(d=c._hasZ,f=c._hasM,b=c.get(0).spatialReference);else if(A(c)){for(var g=
0,p=c.toArray();g<p.length;g++)h=p[g],O(e,h);0<e.length&&(b=c.get(0).spatialReference,d=!0===c.get(0).hasZ,f=!0===c.get(0).hasM)}else throw Error("Invalid Argument");if(0===e.length)return null;!1===t.isClockwise(e,f,d)&&(e=e.slice(0).reverse());return new q({rings:[e],spatialReference:b,hasZ:d,hasM:f})}return c};e.autoCastArrayOfPointsToPolyline=function(c,b){if(w(c)||A(c)){var d=!1,f=!1,e=[];if(w(c)){for(var g=0;g<c.length;g++){var h=c[g];O(e,h)}0<e.length&&(b=c[0].spatialReference,d=!0===c[0].hasZ,
f=!0===c[0].hasM)}else if(c instanceof a)e=c._elements,0<e.length&&(d=c._hasZ,f=c._hasM,b=c.get(0).spatialReference);else if(A(c)){for(var g=0,n=c.toArray();g<n.length;g++)h=n[g],O(e,h);0<e.length&&(b=c.get(0).spatialReference,d=!0===c.get(0).hasZ,f=!0===c.get(0).hasM)}return 0===e.length?null:new p({paths:[e],spatialReference:b,hasZ:d,hasM:f})}return c};e.autoCastArrayOfPointsToMultiPoint=function(c,b){if(w(c)||A(c)){var d=!1,f=!1,e=[];if(w(c)){for(var g=0;g<c.length;g++){var h=c[g];O(e,h)}0<e.length&&
(b=c[0].spatialReference,d=!0===c[0].hasZ,f=!0===c[0].hasM)}else if(c instanceof a)e=c._elements,0<e.length&&(d=c._hasZ,f=c._hasM,b=c.get(0).spatialReference);else if(A(c)){for(var g=0,p=c.toArray();g<p.length;g++)h=p[g],O(e,h);0<e.length&&(b=c.get(0).spatialReference,d=!0===c.get(0).hasZ,f=!0===c.get(0).hasM)}return 0===e.length?null:new n({points:e,spatialReference:b,hasZ:d,hasM:f})}return c};e.toStringArray=function(a,c){void 0===c&&(c=!1);var b=[];if(null===a)return b;if(!0===w(a)){for(var d=
0;d<a.length;d++){var f=V(a[d]);""===f&&!0!==c||b.push(f)}return b}if(a instanceof l){for(d=0;d<a.length();d++)f=V(a.get(d)),""===f&&!0!==c||b.push(f);return b}return u(a)?(f=V(a),""===f&&!0!==c||b.push(f),b):[]}})},"esri/moment":function(){define(["require","exports","./plugins/moment!"],function(b,e,m){return m})},"esri/plugins/moment":function(){define(["require","exports","dojo/_base/kernel","moment/moment"],function(b,e,m,d){Object.defineProperty(e,"__esModule",{value:!0});var k={ar:1,"ar-dz":1,
"ar-kw":1,"ar-ly":1,"ar-ma":1,"ar-sa":1,"ar-tn":1,bs:1,ca:1,cs:1,da:1,de:1,"de-at":1,"de-ch":1,el:1,"en-au":1,"en-ca":1,"en-gb":1,"en-ie":1,"en-il":1,"en-nz":1,es:1,"es-do":1,"es-us":1,et:1,fi:1,fr:1,"fr-ca":1,"fr-ch":1,he:1,hi:1,hr:1,hu:1,id:1,it:1,ja:1,ko:1,lt:1,lv:1,nb:1,nl:1,"nl-be":1,pl:1,pt:1,"pt-br":1,ro:1,ru:1,sl:1,sr:1,"sr-cyrl":1,sv:1,th:1,tr:1,uk:1,vi:1,"zh-cn":1,"zh-hk":1,"zh-tw":1};e.load=function(b,e,a){b=m.locale;var c=b in k;if(!c){var f=b.split("-");1<f.length&&f[0]in k&&(b=f[0],
c=!0)}c?e(["moment/locale/"+b],function(){a(d)}):a(d)}})},"moment/moment":function(){(function(b,e){"object"===typeof exports&&"undefined"!==typeof module?module.exports=e():"function"===typeof define&&define.amd?define(e):b.moment=e()})(this,function(){function b(){return Vb.apply(null,arguments)}function e(a){return a instanceof Array||"[object Array]"===Object.prototype.toString.call(a)}function m(a){return null!=a&&"[object Object]"===Object.prototype.toString.call(a)}function d(a){if(Object.getOwnPropertyNames)return 0===
Object.getOwnPropertyNames(a).length;for(var c in a)if(a.hasOwnProperty(c))return!1;return!0}function k(a){return void 0===a}function l(a){return"number"===typeof a||"[object Number]"===Object.prototype.toString.call(a)}function h(a){return a instanceof Date||"[object Date]"===Object.prototype.toString.call(a)}function a(a,c){var b=[],d;for(d=0;d<a.length;++d)b.push(c(a[d],d));return b}function c(a,c){return Object.prototype.hasOwnProperty.call(a,c)}function f(a,b){for(var d in b)c(b,d)&&(a[d]=b[d]);
c(b,"toString")&&(a.toString=b.toString);c(b,"valueOf")&&(a.valueOf=b.valueOf);return a}function n(a,c,b,d){return db(a,c,b,d,!0).utc()}function g(a){null==a._pf&&(a._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null,rfc2822:!1,weekdayMismatch:!1});return a._pf}function q(a){if(null==a._isValid){var c=g(a),b=Wb.call(c.parsedDateParts,function(a){return null!=a}),b=!isNaN(a._d.getTime())&&
0>c.overflow&&!c.empty&&!c.invalidMonth&&!c.invalidWeekday&&!c.weekdayMismatch&&!c.nullInput&&!c.invalidFormat&&!c.userInvalidated&&(!c.meridiem||c.meridiem&&b);a._strict&&(b=b&&0===c.charsLeftOver&&0===c.unusedTokens.length&&void 0===c.bigHour);if(null!=Object.isFrozen&&Object.isFrozen(a))return b;a._isValid=b}return a._isValid}function p(a){var c=n(NaN);null!=a?f(g(c),a):g(c).userInvalidated=!0;return c}function t(a,c){var b,d,f;k(c._isAMomentObject)||(a._isAMomentObject=c._isAMomentObject);k(c._i)||
(a._i=c._i);k(c._f)||(a._f=c._f);k(c._l)||(a._l=c._l);k(c._strict)||(a._strict=c._strict);k(c._tzm)||(a._tzm=c._tzm);k(c._isUTC)||(a._isUTC=c._isUTC);k(c._offset)||(a._offset=c._offset);k(c._pf)||(a._pf=g(c));k(c._locale)||(a._locale=c._locale);if(0<Hb.length)for(b=0;b<Hb.length;b++)d=Hb[b],f=c[d],k(f)||(a[d]=f);return a}function r(a){t(this,a);this._d=new Date(null!=a._d?a._d.getTime():NaN);this.isValid()||(this._d=new Date(NaN));!1===Ib&&(Ib=!0,b.updateOffset(this),Ib=!1)}function v(a){return a instanceof
r||null!=a&&null!=a._isAMomentObject}function u(a){return 0>a?Math.ceil(a)||0:Math.floor(a)}function z(a){a=+a;var c=0;0!==a&&isFinite(a)&&(c=u(a));return c}function y(a,c,b){var d=Math.min(a.length,c.length),f=Math.abs(a.length-c.length),e=0,g;for(g=0;g<d;g++)(b&&a[g]!==c[g]||!b&&z(a[g])!==z(c[g]))&&e++;return e+f}function x(a){!1===b.suppressDeprecationWarnings&&"undefined"!==typeof console&&console.warn&&console.warn("Deprecation warning: "+a)}function w(a,c){var d=!0;return f(function(){null!=
b.deprecationHandler&&b.deprecationHandler(null,a);if(d){for(var f=[],e,g=0;g<arguments.length;g++){e="";if("object"===typeof arguments[g]){e+="\n["+g+"] ";for(var h in arguments[0])e+=h+": "+arguments[0][h]+", ";e=e.slice(0,-2)}else e=arguments[g];f.push(e)}x(a+"\nArguments: "+Array.prototype.slice.call(f).join("")+"\n"+Error().stack);d=!1}return c.apply(this,arguments)},c)}function A(a,c){null!=b.deprecationHandler&&b.deprecationHandler(a,c);Xb[a]||(x(c),Xb[a]=!0)}function B(a){return a instanceof
Function||"[object Function]"===Object.prototype.toString.call(a)}function F(a,b){var d=f({},a),e;for(e in b)c(b,e)&&(m(a[e])&&m(b[e])?(d[e]={},f(d[e],a[e]),f(d[e],b[e])):null!=b[e]?d[e]=b[e]:delete d[e]);for(e in a)c(a,e)&&!c(b,e)&&m(a[e])&&(d[e]=f({},d[e]));return d}function C(a){null!=a&&this.set(a)}function E(a,c){var b=a.toLowerCase();ob[b]=ob[b+"s"]=ob[c]=a}function G(a){return"string"===typeof a?ob[a]||ob[a.toLowerCase()]:void 0}function Q(a){var b={},d,f;for(f in a)c(a,f)&&(d=G(f))&&(b[d]=
a[f]);return b}function V(a){var c=[],b;for(b in a)c.push({unit:b,priority:Fa[b]});c.sort(function(a,c){return a.priority-c.priority});return c}function R(a,c,b){var d=""+Math.abs(a);return(0<=a?b?"+":"":"-")+Math.pow(10,Math.max(0,c-d.length)).toString().substr(1)+d}function I(a,c,b,d){var f=d;"string"===typeof d&&(f=function(){return this[d]()});a&&(lb[a]=f);c&&(lb[c[0]]=function(){return R(f.apply(this,arguments),c[1],c[2])});b&&(lb[b]=function(){return this.localeData().ordinal(f.apply(this,arguments),
a)})}function W(a){return a.match(/\[[\s\S]/)?a.replace(/^\[|\]$/g,""):a.replace(/\\/g,"")}function M(a){var c=a.match(Yb),b,d;b=0;for(d=c.length;b<d;b++)c[b]=lb[c[b]]?lb[c[b]]:W(c[b]);return function(b){var f="",e;for(e=0;e<d;e++)f+=B(c[e])?c[e].call(b,a):c[e];return f}}function U(a,c){if(!a.isValid())return a.localeData().invalidDate();c=O(c,a.localeData());Jb[c]=Jb[c]||M(c);return Jb[c](a)}function O(a,c){function b(a){return c.longDateFormat(a)||a}var d=5;for(zb.lastIndex=0;0<=d&&zb.test(a);)a=
a.replace(zb,b),zb.lastIndex=0,--d;return a}function J(a,c,b){Kb[a]=B(c)?c:function(a,d){return a&&b?b:c}}function fa(a,b){return c(Kb,a)?Kb[a](b._strict,b._locale):new RegExp(H(a))}function H(a){return da(a.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(a,c,b,d,f){return c||b||d||f}))}function da(a){return a.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$\x26")}function aa(a,c){var b,d=c;"string"===typeof a&&(a=[a]);l(c)&&(d=function(a,b){b[c]=z(a)});for(b=0;b<a.length;b++)Lb[a[b]]=
d}function oa(a,c){aa(a,function(a,b,d,f){d._w=d._w||{};c(a,d._w,d,f)})}function ga(a){return 0===a%4&&0!==a%100||0===a%400}function la(a,c){return function(d){return null!=d?(ja(this,a,d),b.updateOffset(this,c),this):Z(this,a)}}function Z(a,c){return a.isValid()?a._d["get"+(a._isUTC?"UTC":"")+c]():NaN}function ja(a,c,b){if(a.isValid()&&!isNaN(b))if("FullYear"===c&&ga(a.year())&&1===a.month()&&29===a.date())a._d["set"+(a._isUTC?"UTC":"")+c](b,a.month(),ea(b,a.month()));else a._d["set"+(a._isUTC?"UTC":
"")+c](b)}function ea(a,c){if(isNaN(a)||isNaN(c))return NaN;var b=(c%12+12)%12;return 1===b?ga(a+(c-b)/12)?29:28:31-b%7%2}function sa(a,c){var b;if(!a.isValid())return a;if("string"===typeof c)if(/^\d+$/.test(c))c=z(c);else if(c=a.localeData().monthsParse(c),!l(c))return a;b=Math.min(a.date(),ea(a.year(),c));a._d["set"+(a._isUTC?"UTC":"")+"Month"](c,b);return a}function pa(a){return null!=a?(sa(this,a),b.updateOffset(this,!0),this):Z(this,"Month")}function Ea(){function a(a,c){return c.length-a.length}
var c=[],b=[],d=[],f,e;for(f=0;12>f;f++)e=n([2E3,f]),c.push(this.monthsShort(e,"")),b.push(this.months(e,"")),d.push(this.months(e,"")),d.push(this.monthsShort(e,""));c.sort(a);b.sort(a);d.sort(a);for(f=0;12>f;f++)c[f]=da(c[f]),b[f]=da(b[f]);for(f=0;24>f;f++)d[f]=da(d[f]);this._monthsShortRegex=this._monthsRegex=new RegExp("^("+d.join("|")+")","i");this._monthsStrictRegex=new RegExp("^("+b.join("|")+")","i");this._monthsShortStrictRegex=new RegExp("^("+c.join("|")+")","i")}function ra(a,c,b,d,f,e,
g){c=new Date(a,c,b,d,f,e,g);100>a&&0<=a&&isFinite(c.getFullYear())&&c.setFullYear(a);return c}function na(a){var c=new Date(Date.UTC.apply(null,arguments));100>a&&0<=a&&isFinite(c.getUTCFullYear())&&c.setUTCFullYear(a);return c}function ua(a,c,b){b=7+c-b;return-((7+na(a,0,b).getUTCDay()-c)%7)+b-1}function qa(a,c,b,d,f){b=(7+b-d)%7;d=ua(a,d,f);d=1+7*(c-1)+b+d;0>=d?(c=a-1,a=(ga(c)?366:365)+d):d>(ga(a)?366:365)?(c=a+1,a=d-(ga(a)?366:365)):(c=a,a=d);return{year:c,dayOfYear:a}}function Ca(a,c,b){var d=
ua(a.year(),c,b),d=Math.floor((a.dayOfYear()-d-1)/7)+1;1>d?(a=a.year()-1,c=d+wa(a,c,b)):d>wa(a.year(),c,b)?(c=d-wa(a.year(),c,b),a=a.year()+1):(a=a.year(),c=d);return{week:c,year:a}}function wa(a,c,b){var d=ua(a,c,b);c=ua(a+1,c,b);return((ga(a)?366:365)-d+c)/7}function Ta(a,c,b){var d,f;a=a.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],d=0;7>d;++d)f=n([2E3,1]).day(d),this._minWeekdaysParse[d]=this.weekdaysMin(f,"").toLocaleLowerCase(),
this._shortWeekdaysParse[d]=this.weekdaysShort(f,"").toLocaleLowerCase(),this._weekdaysParse[d]=this.weekdays(f,"").toLocaleLowerCase();if(b)c="dddd"===c?za.call(this._weekdaysParse,a):"ddd"===c?za.call(this._shortWeekdaysParse,a):za.call(this._minWeekdaysParse,a);else if("dddd"===c){c=za.call(this._weekdaysParse,a);if(-1!==c)return c;c=za.call(this._shortWeekdaysParse,a);if(-1!==c)return c;c=za.call(this._minWeekdaysParse,a)}else if("ddd"===c){c=za.call(this._shortWeekdaysParse,a);if(-1!==c)return c;
c=za.call(this._weekdaysParse,a);if(-1!==c)return c;c=za.call(this._minWeekdaysParse,a)}else{c=za.call(this._minWeekdaysParse,a);if(-1!==c)return c;c=za.call(this._weekdaysParse,a);if(-1!==c)return c;c=za.call(this._shortWeekdaysParse,a)}return-1!==c?c:null}function T(){function a(a,c){return c.length-a.length}var c=[],b=[],d=[],f=[],e,g,h,p;for(e=0;7>e;e++)g=n([2E3,1]).day(e),h=this.weekdaysMin(g,""),p=this.weekdaysShort(g,""),g=this.weekdays(g,""),c.push(h),b.push(p),d.push(g),f.push(h),f.push(p),
f.push(g);c.sort(a);b.sort(a);d.sort(a);f.sort(a);for(e=0;7>e;e++)b[e]=da(b[e]),d[e]=da(d[e]),f[e]=da(f[e]);this._weekdaysMinRegex=this._weekdaysShortRegex=this._weekdaysRegex=new RegExp("^("+f.join("|")+")","i");this._weekdaysStrictRegex=new RegExp("^("+d.join("|")+")","i");this._weekdaysShortStrictRegex=new RegExp("^("+b.join("|")+")","i");this._weekdaysMinStrictRegex=new RegExp("^("+c.join("|")+")","i")}function xa(){return this.hours()%12||12}function ya(a,c){I(a,0,0,function(){return this.localeData().meridiem(this.hours(),
this.minutes(),c)})}function hb(a,c){return c._meridiemParse}function Sa(a){return a?a.toLowerCase().replace("_","-"):a}function Da(a){var c=null;if(!Aa[a]&&"undefined"!==typeof module&&module&&module.exports)try{c=pb._abbr,require("./locale/"+a),Ka(c)}catch(Wc){}return Aa[a]}function Ka(a,c){a&&((c=k(c)?Ga(a):Ia(a,c))?pb=c:"undefined"!==typeof console&&console.warn&&console.warn("Locale "+a+" not found. Did you forget to load it?"));return pb._abbr}function Ia(a,c){if(null!==c){var b;b=Zb;c.abbr=
a;if(null!=Aa[a])A("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),b=Aa[a]._config;else if(null!=c.parentLocale)if(null!=Aa[c.parentLocale])b=Aa[c.parentLocale]._config;else if(b=Da(c.parentLocale),null!=b)b=b._config;else return qb[c.parentLocale]||(qb[c.parentLocale]=[]),qb[c.parentLocale].push({name:a,
config:c}),null;Aa[a]=new C(F(b,c));qb[a]&&qb[a].forEach(function(a){Ia(a.name,a.config)});Ka(a);return Aa[a]}delete Aa[a];return null}function Ga(a){var c;a&&a._locale&&a._locale._abbr&&(a=a._locale._abbr);if(!a)return pb;if(!e(a)){if(c=Da(a))return c;a=[a]}a:{c=0;for(var b,d,f,g;c<a.length;){g=Sa(a[c]).split("-");b=g.length;for(d=(d=Sa(a[c+1]))?d.split("-"):null;0<b;){if(f=Da(g.slice(0,b).join("-"))){a=f;break a}if(d&&d.length>=b&&y(g,d,!0)>=b-1)break;b--}c++}a=pb}return a}function Wa(a){var c;
(c=a._a)&&-2===g(a).overflow&&(c=0>c[Za]||11<c[Za]?Za:1>c[Ua]||c[Ua]>ea(c[Qa],c[Za])?Ua:0>c[Ba]||24<c[Ba]||24===c[Ba]&&(0!==c[Ra]||0!==c[$a]||0!==c[ib])?Ba:0>c[Ra]||59<c[Ra]?Ra:0>c[$a]||59<c[$a]?$a:0>c[ib]||999<c[ib]?ib:-1,g(a)._overflowDayOfYear&&(c<Qa||c>Ua)&&(c=Ua),g(a)._overflowWeeks&&-1===c&&(c=mc),g(a)._overflowWeekday&&-1===c&&(c=nc),g(a).overflow=c);return a}function Ja(a,c,b){return null!=a?a:null!=c?c:b}function cb(a){var c,d=[],f;if(!a._d){f=new Date(b.now());f=a._useUTC?[f.getUTCFullYear(),
f.getUTCMonth(),f.getUTCDate()]:[f.getFullYear(),f.getMonth(),f.getDate()];if(a._w&&null==a._a[Ua]&&null==a._a[Za]){var e,h,p,n,l,k;e=a._w;if(null!=e.GG||null!=e.W||null!=e.E){if(l=1,k=4,h=Ja(e.GG,a._a[Qa],Ca(K(),1,4).year),p=Ja(e.W,1),n=Ja(e.E,1),1>n||7<n)c=!0}else if(l=a._locale._week.dow,k=a._locale._week.doy,p=Ca(K(),l,k),h=Ja(e.gg,a._a[Qa],p.year),p=Ja(e.w,p.week),null!=e.d){if(n=e.d,0>n||6<n)c=!0}else if(null!=e.e){if(n=e.e+l,0>e.e||6<e.e)c=!0}else n=l;1>p||p>wa(h,l,k)?g(a)._overflowWeeks=!0:
null!=c?g(a)._overflowWeekday=!0:(c=qa(h,p,n,l,k),a._a[Qa]=c.year,a._dayOfYear=c.dayOfYear)}if(null!=a._dayOfYear){c=Ja(a._a[Qa],f[Qa]);if(a._dayOfYear>(ga(c)?366:365)||0===a._dayOfYear)g(a)._overflowDayOfYear=!0;c=na(c,0,a._dayOfYear);a._a[Za]=c.getUTCMonth();a._a[Ua]=c.getUTCDate()}for(c=0;3>c&&null==a._a[c];++c)a._a[c]=d[c]=f[c];for(;7>c;c++)a._a[c]=d[c]=null==a._a[c]?2===c?1:0:a._a[c];24===a._a[Ba]&&0===a._a[Ra]&&0===a._a[$a]&&0===a._a[ib]&&(a._nextDay=!0,a._a[Ba]=0);a._d=(a._useUTC?na:ra).apply(null,
d);d=a._useUTC?a._d.getUTCDay():a._d.getDay();null!=a._tzm&&a._d.setUTCMinutes(a._d.getUTCMinutes()-a._tzm);a._nextDay&&(a._a[Ba]=24);a._w&&"undefined"!==typeof a._w.d&&a._w.d!==d&&(g(a).weekdayMismatch=!0)}}function N(a){var c,b;c=a._i;var d=oc.exec(c)||pc.exec(c),f,e,h,p;if(d){g(a).iso=!0;c=0;for(b=Ab.length;c<b;c++)if(Ab[c][1].exec(d[1])){e=Ab[c][0];f=!1!==Ab[c][2];break}if(null==e)a._isValid=!1;else{if(d[3]){c=0;for(b=Mb.length;c<b;c++)if(Mb[c][1].exec(d[3])){h=(d[2]||" ")+Mb[c][0];break}if(null==
h){a._isValid=!1;return}}if(f||null==h){if(d[4])if(qc.exec(d[4]))p="Z";else{a._isValid=!1;return}a._f=e+(h||"")+(p||"");ca(a)}else a._isValid=!1}}else a._isValid=!1}function Ha(a){var c=rc.exec(a._i.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(c){var b=c[3],d=c[2],f=c[5],e=c[6],h=c[7],p=parseInt(c[4],10),b=[49>=p?2E3+p:999>=p?1900+p:p,$b.indexOf(b),parseInt(d,10),parseInt(f,10),parseInt(e,10)];h&&b.push(parseInt(h,10));a:{if(h=c[1])if(h=ac.indexOf(h),
d=(new Date(b[0],b[1],b[2])).getDay(),h!==d){g(a).weekdayMismatch=!0;h=a._isValid=!1;break a}h=!0}h&&(a._a=b,(h=c[8])?c=sc[h]:c[9]?c=0:(c=parseInt(c[10],10),h=c%100,c=(c-h)/100*60+h),a._tzm=c,a._d=na.apply(null,a._a),a._d.setUTCMinutes(a._d.getUTCMinutes()-a._tzm),g(a).rfc2822=!0)}else a._isValid=!1}function Ya(a){var c=tc.exec(a._i);null!==c?a._d=new Date(+c[1]):(N(a),!1===a._isValid&&(delete a._isValid,Ha(a),!1===a._isValid&&(delete a._isValid,b.createFromInputFallback(a))))}function ca(a){if(a._f===
b.ISO_8601)N(a);else if(a._f===b.RFC_2822)Ha(a);else{a._a=[];g(a).empty=!0;var d=""+a._i,f,e,h,p,n,l=d.length,k=0;h=O(a._f,a._locale).match(Yb)||[];for(f=0;f<h.length;f++){p=h[f];if(e=(d.match(fa(p,a))||[])[0])n=d.substr(0,d.indexOf(e)),0<n.length&&g(a).unusedInput.push(n),d=d.slice(d.indexOf(e)+e.length),k+=e.length;if(lb[p]){if(e?g(a).empty=!1:g(a).unusedTokens.push(p),n=a,null!=e&&c(Lb,p))Lb[p](e,n._a,n,p)}else a._strict&&!e&&g(a).unusedTokens.push(p)}g(a).charsLeftOver=l-k;0<d.length&&g(a).unusedInput.push(d);
12>=a._a[Ba]&&!0===g(a).bigHour&&0<a._a[Ba]&&(g(a).bigHour=void 0);g(a).parsedDateParts=a._a.slice(0);g(a).meridiem=a._meridiem;d=a._a;f=Ba;l=a._locale;h=a._a[Ba];k=a._meridiem;null!=k&&(null!=l.meridiemHour?h=l.meridiemHour(h,k):null!=l.isPM&&((l=l.isPM(k))&&12>h&&(h+=12),l||12!==h||(h=0)));d[f]=h;cb(a);Wa(a)}}function Oa(c){if(!c._d){var b=Q(c._i);c._a=a([b.year,b.month,b.day||b.date,b.hour,b.minute,b.second,b.millisecond],function(a){return a&&parseInt(a,10)});cb(c)}}function La(a){var c=a._i,
b=a._f;a._locale=a._locale||Ga(a._l);if(null===c||void 0===b&&""===c)return p({nullInput:!0});"string"===typeof c&&(a._i=c=a._locale.preparse(c));if(v(c))return new r(Wa(c));if(h(c))a._d=c;else if(e(b)){var d,n,l;if(0===a._f.length)g(a).invalidFormat=!0,a._d=new Date(NaN);else{for(c=0;c<a._f.length;c++)if(b=0,d=t({},a),null!=a._useUTC&&(d._useUTC=a._useUTC),d._f=a._f[c],ca(d),q(d)&&(b+=g(d).charsLeftOver,b+=10*g(d).unusedTokens.length,g(d).score=b,null==l||b<l))l=b,n=d;f(a,n||d)}}else b?ca(a):ha(a);
q(a)||(a._d=null);return a}function ha(c){var d=c._i;k(d)?c._d=new Date(b.now()):h(d)?c._d=new Date(d.valueOf()):"string"===typeof d?Ya(c):e(d)?(c._a=a(d.slice(0),function(a){return parseInt(a,10)}),cb(c)):m(d)?Oa(c):l(d)?c._d=new Date(d):b.createFromInputFallback(c)}function db(a,c,b,f,g){var h={};if(!0===b||!1===b)f=b,b=void 0;if(m(a)&&d(a)||e(a)&&0===a.length)a=void 0;h._isAMomentObject=!0;h._useUTC=h._isUTC=g;h._l=b;h._i=a;h._f=c;h._strict=f;a=new r(Wa(La(h)));a._nextDay&&(a.add(1,"d"),a._nextDay=
void 0);return a}function K(a,c,b,d){return db(a,c,b,d,!1)}function ia(a,c){var b,d;1===c.length&&e(c[0])&&(c=c[0]);if(!c.length)return K();b=c[0];for(d=1;d<c.length;++d)if(!c[d].isValid()||c[d][a](b))b=c[d];return b}function D(a){for(var c in a)if(-1===za.call(rb,c)||null!=a[c]&&isNaN(a[c]))return!1;c=!1;for(var b=0;b<rb.length;++b)if(a[rb[b]]){if(c)return!1;parseFloat(a[rb[b]])!==z(a[rb[b]])&&(c=!0)}return!0}function ba(a){a=Q(a);var c=a.year||0,b=a.quarter||0,d=a.month||0,f=a.week||a.isoWeek||
0,e=a.day||0,g=a.hour||0,h=a.minute||0,p=a.second||0,n=a.millisecond||0;this._isValid=D(a);this._milliseconds=+n+1E3*p+6E4*h+36E5*g;this._days=+e+7*f;this._months=+d+3*b+12*c;this._data={};this._locale=Ga();this._bubble()}function X(a){return a instanceof ba}function ka(a){return 0>a?-1*Math.round(-1*a):Math.round(a)}function S(a,c){I(a,0,0,function(){var a=this.utcOffset(),b="+";0>a&&(a=-a,b="-");return b+R(~~(a/60),2)+c+R(~~a%60,2)})}function Y(a,c){a=(c||"").match(a);if(null===a)return null;a=
((a[a.length-1]||[])+"").match(uc)||["-",0,0];c=+(60*a[1])+z(a[2]);return 0===c?0:"+"===a[0]?c:-c}function L(a,c){return c._isUTC?(c=c.clone(),a=(v(a)||h(a)?a.valueOf():K(a).valueOf())-c.valueOf(),c._d.setTime(c._d.valueOf()+a),b.updateOffset(c,!1),c):K(a).local()}function nb(){return this.isValid()?this._isUTC&&0===this._offset:!1}function Ma(a,b){var d=a,f=null;X(a)?d={ms:a._milliseconds,d:a._days,M:a._months}:l(a)?(d={},b?d[b]=a:d.milliseconds=a):(f=vc.exec(a))?(d="-"===f[1]?-1:1,d={y:0,d:z(f[Ua])*
d,h:z(f[Ba])*d,m:z(f[Ra])*d,s:z(f[$a])*d,ms:z(ka(1E3*f[ib]))*d}):(f=wc.exec(a))?(d="-"===f[1]?-1:1,d={y:Xa(f[2],d),M:Xa(f[3],d),w:Xa(f[4],d),d:Xa(f[5],d),h:Xa(f[6],d),m:Xa(f[7],d),s:Xa(f[8],d)}):null==d?d={}:"object"===typeof d&&("from"in d||"to"in d)&&(f=K(d.from),d=K(d.to),f.isValid()&&d.isValid()?(d=L(d,f),f.isBefore(d)?d=wb(f,d):(d=wb(d,f),d.milliseconds=-d.milliseconds,d.months=-d.months),f=d):f={milliseconds:0,months:0},d={},d.ms=f.milliseconds,d.M=f.months);d=new ba(d);X(a)&&c(a,"_locale")&&
(d._locale=a._locale);return d}function Xa(a,c){a=a&&parseFloat(a.replace(",","."));return(isNaN(a)?0:a)*c}function wb(a,c){var b={milliseconds:0,months:0};b.months=c.month()-a.month()+12*(c.year()-a.year());a.clone().add(b.months,"M").isAfter(c)&&--b.months;b.milliseconds=+c-+a.clone().add(b.months,"M");return b}function Pa(a,c){return function(b,d){var f;null===d||isNaN(+d)||(A(c,"moment()."+c+"(period, number) is deprecated. Please use moment()."+c+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),
f=b,b=d,d=f);b=Ma("string"===typeof b?+b:b,d);yb(this,b,a);return this}}function yb(a,c,d,f){var e=c._milliseconds,g=ka(c._days);c=ka(c._months);a.isValid()&&(f=null==f?!0:f,c&&sa(a,Z(a,"Month")+c*d),g&&ja(a,"Date",Z(a,"Date")+g*d),e&&a._d.setTime(a._d.valueOf()+e*d),f&&b.updateOffset(a,g||c))}function tb(a,c){var b=12*(c.year()-a.year())+(c.month()-a.month()),d=a.clone().add(b,"months");0>c-d?(a=a.clone().add(b-1,"months"),c=(c-d)/(d-a)):(a=a.clone().add(b+1,"months"),c=(c-d)/(a-d));return-(b+c)||
0}function ub(a){if(void 0===a)return this._locale._abbr;a=Ga(a);null!=a&&(this._locale=a);return this}function mb(){return this._locale}function jb(a,c){I(0,[a,a.length],0,c)}function Qb(a,c,b,d,f){var e;if(null==a)return Ca(this,d,f).year;e=wa(a,d,f);c>e&&(c=e);a=qa(a,c,b,d,f);a=na(a.year,0,a.dayOfYear);this.year(a.getUTCFullYear());this.month(a.getUTCMonth());this.date(a.getUTCDate());return this}function kc(a,c){c[ib]=z(1E3*("0."+a))}function Rb(a){return a}function vb(a,c,b,d){var f=Ga();c=n().set(d,
c);return f[b](c,a)}function Sb(a,c,b){l(a)&&(c=a,a=void 0);a=a||"";if(null!=c)return vb(a,c,b,"month");var d=[];for(c=0;12>c;c++)d[c]=vb(a,c,b,"month");return d}function Gb(a,c,b,d){"boolean"!==typeof a&&(b=c=a,a=!1);l(c)&&(b=c,c=void 0);c=c||"";var f=Ga();a=a?f._week.dow:0;if(null!=b)return vb(c,(b+a)%7,d,"day");f=[];for(b=0;7>b;b++)f[b]=vb(c,(b+a)%7,d,"day");return f}function Tb(a,c,b,d){c=Ma(c,b);a._milliseconds+=d*c._milliseconds;a._days+=d*c._days;a._months+=d*c._months;return a._bubble()}function Ub(a){return 0>
a?Math.floor(a):Math.ceil(a)}function bb(a){return function(){return this.as(a)}}function gb(a){return function(){return this.isValid()?this._data[a]:NaN}}function lc(a,c,b,d,f){return f.relativeTime(c||1,!!b,a,d)}function kb(a){return(0<a)-(0>a)||+a}function xb(){if(!this.isValid())return this.localeData().invalidDate();var a=Nb(this._milliseconds)/1E3,c=Nb(this._days),b=Nb(this._months),d,f;d=u(a/60);f=u(d/60);a%=60;d%=60;var e=u(b/12),b=b%12,a=a?a.toFixed(3).replace(/\.?0+$/,""):"",g=this.asSeconds();
if(!g)return"P0D";var h=0>g?"-":"",p=kb(this._months)!==kb(g)?"-":"",n=kb(this._days)!==kb(g)?"-":"",g=kb(this._milliseconds)!==kb(g)?"-":"";return h+"P"+(e?p+e+"Y":"")+(b?p+b+"M":"")+(c?n+c+"D":"")+(f||d||a?"T":"")+(f?g+f+"H":"")+(d?g+d+"M":"")+(a?g+a+"S":"")}var Vb,Wb;Wb=Array.prototype.some?Array.prototype.some:function(a){for(var c=Object(this),b=c.length>>>0,d=0;d<b;d++)if(d in c&&a.call(this,c[d],d,c))return!0;return!1};var Hb=b.momentProperties=[],Ib=!1,Xb={};b.suppressDeprecationWarnings=
!1;b.deprecationHandler=null;var bc;bc=Object.keys?Object.keys:function(a){var b,d=[];for(b in a)c(a,b)&&d.push(b);return d};var ob={},Fa={},Yb=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,zb=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Jb={},lb={},cc=/\d/,Na=/\d\d/,dc=/\d{3}/,Ob=/\d{4}/,Bb=/[+-]?\d{6}/,va=/\d\d?/,ec=/\d\d\d\d?/,fc=/\d\d\d\d\d\d?/,Cb=/\d{1,3}/,
Pb=/\d{1,4}/,Db=/[+-]?\d{1,6}/,xc=/\d+/,Eb=/[+-]?\d+/,yc=/Z|[+-]\d\d:?\d\d/gi,Fb=/Z|[+-]\d\d(?::?\d\d)?/gi,sb=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,Kb={},Lb={},Qa=0,Za=1,Ua=2,Ba=3,Ra=4,$a=5,ib=6,mc=7,nc=8;I("Y",0,0,function(){var a=this.year();return 9999>=a?""+a:"+"+a});I(0,["YY",2],0,function(){return this.year()%100});I(0,["YYYY",4],0,"year");I(0,["YYYYY",5],0,"year");I(0,["YYYYYY",
6,!0],0,"year");E("year","y");Fa.year=1;J("Y",Eb);J("YY",va,Na);J("YYYY",Pb,Ob);J("YYYYY",Db,Bb);J("YYYYYY",Db,Bb);aa(["YYYYY","YYYYYY"],Qa);aa("YYYY",function(a,c){c[Qa]=2===a.length?b.parseTwoDigitYear(a):z(a)});aa("YY",function(a,c){c[Qa]=b.parseTwoDigitYear(a)});aa("Y",function(a,c){c[Qa]=parseInt(a,10)});b.parseTwoDigitYear=function(a){return z(a)+(68<z(a)?1900:2E3)};var gc=la("FullYear",!0),za;za=Array.prototype.indexOf?Array.prototype.indexOf:function(a){var c;for(c=0;c<this.length;++c)if(this[c]===
a)return c;return-1};I("M",["MM",2],"Mo",function(){return this.month()+1});I("MMM",0,0,function(a){return this.localeData().monthsShort(this,a)});I("MMMM",0,0,function(a){return this.localeData().months(this,a)});E("month","M");Fa.month=8;J("M",va);J("MM",va,Na);J("MMM",function(a,c){return c.monthsShortRegex(a)});J("MMMM",function(a,c){return c.monthsRegex(a)});aa(["M","MM"],function(a,c){c[Za]=z(a)-1});aa(["MMM","MMMM"],function(a,c,b,d){d=b._locale.monthsParse(a,d,b._strict);null!=d?c[Za]=d:g(b).invalidMonth=
a});var hc=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,$b="Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split(" ");I("w",["ww",2],"wo","week");I("W",["WW",2],"Wo","isoWeek");E("week","w");E("isoWeek","W");Fa.week=5;Fa.isoWeek=5;J("w",va);J("ww",va,Na);J("W",va);J("WW",va,Na);oa(["w","ww","W","WW"],function(a,c,b,d){c[d.substr(0,1)]=z(a)});I("d",0,"do","day");I("dd",0,0,function(a){return this.localeData().weekdaysMin(this,a)});I("ddd",0,0,function(a){return this.localeData().weekdaysShort(this,a)});I("dddd",
0,0,function(a){return this.localeData().weekdays(this,a)});I("e",0,0,"weekday");I("E",0,0,"isoWeekday");E("day","d");E("weekday","e");E("isoWeekday","E");Fa.day=11;Fa.weekday=11;Fa.isoWeekday=11;J("d",va);J("e",va);J("E",va);J("dd",function(a,c){return c.weekdaysMinRegex(a)});J("ddd",function(a,c){return c.weekdaysShortRegex(a)});J("dddd",function(a,c){return c.weekdaysRegex(a)});oa(["dd","ddd","dddd"],function(a,c,b,d){d=b._locale.weekdaysParse(a,d,b._strict);null!=d?c.d=d:g(b).invalidWeekday=a});
oa(["d","e","E"],function(a,c,b,d){c[d]=z(a)});var ac="Sun Mon Tue Wed Thu Fri Sat".split(" ");I("H",["HH",2],0,"hour");I("h",["hh",2],0,xa);I("k",["kk",2],0,function(){return this.hours()||24});I("hmm",0,0,function(){return""+xa.apply(this)+R(this.minutes(),2)});I("hmmss",0,0,function(){return""+xa.apply(this)+R(this.minutes(),2)+R(this.seconds(),2)});I("Hmm",0,0,function(){return""+this.hours()+R(this.minutes(),2)});I("Hmmss",0,0,function(){return""+this.hours()+R(this.minutes(),2)+R(this.seconds(),
2)});ya("a",!0);ya("A",!1);E("hour","h");Fa.hour=13;J("a",hb);J("A",hb);J("H",va);J("h",va);J("k",va);J("HH",va,Na);J("hh",va,Na);J("kk",va,Na);J("hmm",ec);J("hmmss",fc);J("Hmm",ec);J("Hmmss",fc);aa(["H","HH"],Ba);aa(["k","kk"],function(a,c,b){a=z(a);c[Ba]=24===a?0:a});aa(["a","A"],function(a,c,b){b._isPm=b._locale.isPM(a);b._meridiem=a});aa(["h","hh"],function(a,c,b){c[Ba]=z(a);g(b).bigHour=!0});aa("hmm",function(a,c,b){var d=a.length-2;c[Ba]=z(a.substr(0,d));c[Ra]=z(a.substr(d));g(b).bigHour=!0});
aa("hmmss",function(a,c,b){var d=a.length-4,f=a.length-2;c[Ba]=z(a.substr(0,d));c[Ra]=z(a.substr(d,2));c[$a]=z(a.substr(f));g(b).bigHour=!0});aa("Hmm",function(a,c,b){b=a.length-2;c[Ba]=z(a.substr(0,b));c[Ra]=z(a.substr(b))});aa("Hmmss",function(a,c,b){b=a.length-4;var d=a.length-2;c[Ba]=z(a.substr(0,b));c[Ra]=z(a.substr(b,2));c[$a]=z(a.substr(d))});var zc=la("Hours",!0),Zb={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",
sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:"January February March April May June July August September October November December".split(" "),
monthsShort:$b,week:{dow:0,doy:6},weekdays:"Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "),weekdaysMin:"Su Mo Tu We Th Fr Sa".split(" "),weekdaysShort:ac,meridiemParse:/[ap]\.?m?\.?/i},Aa={},qb={},pb,oc=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,pc=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,
qc=/Z|[+-]\d\d(?::?\d\d)?/,Ab=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],Mb=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",
/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],tc=/^\/?Date\((\-?\d+)/i,rc=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,sc={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};b.createFromInputFallback=w("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and will be removed in an upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",
function(a){a._d=new Date(a._i+(a._useUTC?" UTC":""))});b.ISO_8601=function(){};b.RFC_2822=function(){};var Ac=w("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var a=K.apply(null,arguments);return this.isValid()&&a.isValid()?a<this?this:a:p()}),Bc=w("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var a=K.apply(null,arguments);return this.isValid()&&a.isValid()?a>this?this:
a:p()}),rb="year quarter month week day hour minute second millisecond".split(" ");S("Z",":");S("ZZ","");J("Z",Fb);J("ZZ",Fb);aa(["Z","ZZ"],function(a,c,b){b._useUTC=!0;b._tzm=Y(Fb,a)});var uc=/([\+\-]|\d\d)/gi;b.updateOffset=function(){};var vc=/^(\-|\+)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)(\.\d*)?)?$/,wc=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;Ma.fn=ba.prototype;Ma.invalid=
function(){return Ma(NaN)};var Cc=Pa(1,"add"),Dc=Pa(-1,"subtract");b.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";b.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var ic=w("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(a){return void 0===a?this.localeData():this.locale(a)});I(0,["gg",2],0,function(){return this.weekYear()%100});I(0,["GG",2],0,function(){return this.isoWeekYear()%100});jb("gggg","weekYear");
jb("ggggg","weekYear");jb("GGGG","isoWeekYear");jb("GGGGG","isoWeekYear");E("weekYear","gg");E("isoWeekYear","GG");Fa.weekYear=1;Fa.isoWeekYear=1;J("G",Eb);J("g",Eb);J("GG",va,Na);J("gg",va,Na);J("GGGG",Pb,Ob);J("gggg",Pb,Ob);J("GGGGG",Db,Bb);J("ggggg",Db,Bb);oa(["gggg","ggggg","GGGG","GGGGG"],function(a,c,b,d){c[d.substr(0,2)]=z(a)});oa(["gg","GG"],function(a,c,d,f){c[f]=b.parseTwoDigitYear(a)});I("Q",0,"Qo","quarter");E("quarter","Q");Fa.quarter=7;J("Q",cc);aa("Q",function(a,c){c[Za]=3*(z(a)-1)});
I("D",["DD",2],"Do","date");E("date","D");Fa.date=9;J("D",va);J("DD",va,Na);J("Do",function(a,c){return a?c._dayOfMonthOrdinalParse||c._ordinalParse:c._dayOfMonthOrdinalParseLenient});aa(["D","DD"],Ua);aa("Do",function(a,c){c[Ua]=z(a.match(va)[0])});var jc=la("Date",!0);I("DDD",["DDDD",3],"DDDo","dayOfYear");E("dayOfYear","DDD");Fa.dayOfYear=4;J("DDD",Cb);J("DDDD",dc);aa(["DDD","DDDD"],function(a,c,b){b._dayOfYear=z(a)});I("m",["mm",2],0,"minute");E("minute","m");Fa.minute=14;J("m",va);J("mm",va,
Na);aa(["m","mm"],Ra);var Ec=la("Minutes",!1);I("s",["ss",2],0,"second");E("second","s");Fa.second=15;J("s",va);J("ss",va,Na);aa(["s","ss"],$a);var Fc=la("Seconds",!1);I("S",0,0,function(){return~~(this.millisecond()/100)});I(0,["SS",2],0,function(){return~~(this.millisecond()/10)});I(0,["SSS",3],0,"millisecond");I(0,["SSSS",4],0,function(){return 10*this.millisecond()});I(0,["SSSSS",5],0,function(){return 100*this.millisecond()});I(0,["SSSSSS",6],0,function(){return 1E3*this.millisecond()});I(0,
["SSSSSSS",7],0,function(){return 1E4*this.millisecond()});I(0,["SSSSSSSS",8],0,function(){return 1E5*this.millisecond()});I(0,["SSSSSSSSS",9],0,function(){return 1E6*this.millisecond()});E("millisecond","ms");Fa.millisecond=16;J("S",Cb,cc);J("SS",Cb,Na);J("SSS",Cb,dc);var eb;for(eb="SSSS";9>=eb.length;eb+="S")J(eb,xc);for(eb="S";9>=eb.length;eb+="S")aa(eb,kc);var Gc=la("Milliseconds",!1);I("z",0,0,"zoneAbbr");I("zz",0,0,"zoneName");var P=r.prototype;P.add=Cc;P.calendar=function(a,c){a=a||K();var d=
L(a,this).startOf("day"),d=b.calendarFormat(this,d)||"sameElse";c=c&&(B(c[d])?c[d].call(this,a):c[d]);return this.format(c||this.localeData().calendar(d,this,K(a)))};P.clone=function(){return new r(this)};P.diff=function(a,c,b){var d;if(!this.isValid())return NaN;a=L(a,this);if(!a.isValid())return NaN;d=6E4*(a.utcOffset()-this.utcOffset());c=G(c);switch(c){case "year":c=tb(this,a)/12;break;case "month":c=tb(this,a);break;case "quarter":c=tb(this,a)/3;break;case "second":c=(this-a)/1E3;break;case "minute":c=
(this-a)/6E4;break;case "hour":c=(this-a)/36E5;break;case "day":c=(this-a-d)/864E5;break;case "week":c=(this-a-d)/6048E5;break;default:c=this-a}return b?c:u(c)};P.endOf=function(a){a=G(a);if(void 0===a||"millisecond"===a)return this;"date"===a&&(a="day");return this.startOf(a).add(1,"isoWeek"===a?"week":a).subtract(1,"ms")};P.format=function(a){a||(a=this.isUtc()?b.defaultFormatUtc:b.defaultFormat);a=U(this,a);return this.localeData().postformat(a)};P.from=function(a,c){return this.isValid()&&(v(a)&&
a.isValid()||K(a).isValid())?Ma({to:this,from:a}).locale(this.locale()).humanize(!c):this.localeData().invalidDate()};P.fromNow=function(a){return this.from(K(),a)};P.to=function(a,c){return this.isValid()&&(v(a)&&a.isValid()||K(a).isValid())?Ma({from:this,to:a}).locale(this.locale()).humanize(!c):this.localeData().invalidDate()};P.toNow=function(a){return this.to(K(),a)};P.get=function(a){a=G(a);return B(this[a])?this[a]():this};P.invalidAt=function(){return g(this).overflow};P.isAfter=function(a,
c){a=v(a)?a:K(a);if(!this.isValid()||!a.isValid())return!1;c=G(c)||"millisecond";return"millisecond"===c?this.valueOf()>a.valueOf():a.valueOf()<this.clone().startOf(c).valueOf()};P.isBefore=function(a,c){a=v(a)?a:K(a);if(!this.isValid()||!a.isValid())return!1;c=G(c)||"millisecond";return"millisecond"===c?this.valueOf()<a.valueOf():this.clone().endOf(c).valueOf()<a.valueOf()};P.isBetween=function(a,c,b,d){a=v(a)?a:K(a);c=v(c)?c:K(c);if(!(this.isValid()&&a.isValid()&&c.isValid()))return!1;d=d||"()";
return("("===d[0]?this.isAfter(a,b):!this.isBefore(a,b))&&(")"===d[1]?this.isBefore(c,b):!this.isAfter(c,b))};P.isSame=function(a,c){a=v(a)?a:K(a);if(!this.isValid()||!a.isValid())return!1;c=G(c)||"millisecond";if("millisecond"===c)return this.valueOf()===a.valueOf();a=a.valueOf();return this.clone().startOf(c).valueOf()<=a&&a<=this.clone().endOf(c).valueOf()};P.isSameOrAfter=function(a,c){return this.isSame(a,c)||this.isAfter(a,c)};P.isSameOrBefore=function(a,c){return this.isSame(a,c)||this.isBefore(a,
c)};P.isValid=function(){return q(this)};P.lang=ic;P.locale=ub;P.localeData=mb;P.max=Bc;P.min=Ac;P.parsingFlags=function(){return f({},g(this))};P.set=function(a,c){if("object"===typeof a){a=Q(a);c=V(a);for(var b=0;b<c.length;b++)this[c[b].unit](a[c[b].unit])}else if(a=G(a),B(this[a]))return this[a](c);return this};P.startOf=function(a){a=G(a);switch(a){case "year":this.month(0);case "quarter":case "month":this.date(1);case "week":case "isoWeek":case "day":case "date":this.hours(0);case "hour":this.minutes(0);
case "minute":this.seconds(0);case "second":this.milliseconds(0)}"week"===a&&this.weekday(0);"isoWeek"===a&&this.isoWeekday(1);"quarter"===a&&this.month(3*Math.floor(this.month()/3));return this};P.subtract=Dc;P.toArray=function(){return[this.year(),this.month(),this.date(),this.hour(),this.minute(),this.second(),this.millisecond()]};P.toObject=function(){return{years:this.year(),months:this.month(),date:this.date(),hours:this.hours(),minutes:this.minutes(),seconds:this.seconds(),milliseconds:this.milliseconds()}};
P.toDate=function(){return new Date(this.valueOf())};P.toISOString=function(a){if(!this.isValid())return null;var c=(a=!0!==a)?this.clone().utc():this;return 0>c.year()||9999<c.year()?U(c,a?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):B(Date.prototype.toISOString)?a?this.toDate().toISOString():(new Date(this.valueOf()+6E4*this.utcOffset())).toISOString().replace("Z",U(c,"Z")):U(c,a?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")};P.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+
this._i+" */)";var a="moment",c="";this.isLocal()||(a=0===this.utcOffset()?"moment.utc":"moment.parseZone",c="Z");var a="["+a+'("]',b=0<=this.year()&&9999>=this.year()?"YYYY":"YYYYYY";return this.format(a+b+"-MM-DD[T]HH:mm:ss.SSS"+(c+'[")]'))};P.toJSON=function(){return this.isValid()?this.toISOString():null};P.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")};P.unix=function(){return Math.floor(this.valueOf()/1E3)};P.valueOf=function(){return this._d.valueOf()-
6E4*(this._offset||0)};P.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}};P.year=gc;P.isLeapYear=function(){return ga(this.year())};P.weekYear=function(a){return Qb.call(this,a,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)};P.isoWeekYear=function(a){return Qb.call(this,a,this.isoWeek(),this.isoWeekday(),1,4)};P.quarter=P.quarters=function(a){return null==a?Math.ceil((this.month()+1)/3):this.month(3*
(a-1)+this.month()%3)};P.month=pa;P.daysInMonth=function(){return ea(this.year(),this.month())};P.week=P.weeks=function(a){var c=this.localeData().week(this);return null==a?c:this.add(7*(a-c),"d")};P.isoWeek=P.isoWeeks=function(a){var c=Ca(this,1,4).week;return null==a?c:this.add(7*(a-c),"d")};P.weeksInYear=function(){var a=this.localeData()._week;return wa(this.year(),a.dow,a.doy)};P.isoWeeksInYear=function(){return wa(this.year(),1,4)};P.date=jc;P.day=P.days=function(a){if(!this.isValid())return null!=
a?this:NaN;var c=this._isUTC?this._d.getUTCDay():this._d.getDay();if(null!=a){var b=this.localeData();"string"===typeof a&&(isNaN(a)?(a=b.weekdaysParse(a),a="number"===typeof a?a:null):a=parseInt(a,10));return this.add(a-c,"d")}return c};P.weekday=function(a){if(!this.isValid())return null!=a?this:NaN;var c=(this.day()+7-this.localeData()._week.dow)%7;return null==a?c:this.add(a-c,"d")};P.isoWeekday=function(a){if(!this.isValid())return null!=a?this:NaN;if(null!=a){var c=this.localeData();a="string"===
typeof a?c.weekdaysParse(a)%7||7:isNaN(a)?null:a;return this.day(this.day()%7?a:a-7)}return this.day()||7};P.dayOfYear=function(a){var c=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864E5)+1;return null==a?c:this.add(a-c,"d")};P.hour=P.hours=zc;P.minute=P.minutes=Ec;P.second=P.seconds=Fc;P.millisecond=P.milliseconds=Gc;P.utcOffset=function(a,c,d){var f=this._offset||0,e;if(!this.isValid())return null!=a?this:NaN;if(null!=a){if("string"===typeof a){if(a=Y(Fb,a),null===a)return this}else 16>
Math.abs(a)&&!d&&(a*=60);!this._isUTC&&c&&(e=15*-Math.round(this._d.getTimezoneOffset()/15));this._offset=a;this._isUTC=!0;null!=e&&this.add(e,"m");f!==a&&(!c||this._changeInProgress?yb(this,Ma(a-f,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,b.updateOffset(this,!0),this._changeInProgress=null));return this}return this._isUTC?f:15*-Math.round(this._d.getTimezoneOffset()/15)};P.utc=function(a){return this.utcOffset(0,a)};P.local=function(a){this._isUTC&&(this.utcOffset(0,a),this._isUTC=
!1,a&&this.subtract(15*-Math.round(this._d.getTimezoneOffset()/15),"m"));return this};P.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"===typeof this._i){var a=Y(yc,this._i);null!=a?this.utcOffset(a):this.utcOffset(0,!0)}return this};P.hasAlignedHourOffset=function(a){if(!this.isValid())return!1;a=a?K(a).utcOffset():0;return 0===(this.utcOffset()-a)%60};P.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()};
P.isLocal=function(){return this.isValid()?!this._isUTC:!1};P.isUtcOffset=function(){return this.isValid()?this._isUTC:!1};P.isUtc=nb;P.isUTC=nb;P.zoneAbbr=function(){return this._isUTC?"UTC":""};P.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""};P.dates=w("dates accessor is deprecated. Use date instead.",jc);P.months=w("months accessor is deprecated. Use month instead",pa);P.years=w("years accessor is deprecated. Use year instead",gc);P.zone=w("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",
function(a,c){return null!=a?("string"!==typeof a&&(a=-a),this.utcOffset(a,c),this):-this.utcOffset()});P.isDSTShifted=w("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",function(){if(!k(this._isDSTShifted))return this._isDSTShifted;var a={};t(a,this);a=La(a);if(a._a){var c=a._isUTC?n(a._a):K(a._a);this._isDSTShifted=this.isValid()&&0<y(a._a,c.toArray())}else this._isDSTShifted=!1;return this._isDSTShifted});var ta=C.prototype;ta.calendar=function(a,
c,b){a=this._calendar[a]||this._calendar.sameElse;return B(a)?a.call(c,b):a};ta.longDateFormat=function(a){var c=this._longDateFormat[a],b=this._longDateFormat[a.toUpperCase()];if(c||!b)return c;this._longDateFormat[a]=b.replace(/MMMM|MM|DD|dddd/g,function(a){return a.slice(1)});return this._longDateFormat[a]};ta.invalidDate=function(){return this._invalidDate};ta.ordinal=function(a){return this._ordinal.replace("%d",a)};ta.preparse=Rb;ta.postformat=Rb;ta.relativeTime=function(a,c,b,d){var f=this._relativeTime[b];
return B(f)?f(a,c,b,d):f.replace(/%d/i,a)};ta.pastFuture=function(a,c){a=this._relativeTime[0<a?"future":"past"];return B(a)?a(c):a.replace(/%s/i,c)};ta.set=function(a){var c,b;for(b in a)c=a[b],B(c)?this[b]=c:this["_"+b]=c;this._config=a;this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)};ta.months=function(a,c){return a?e(this._months)?this._months[a.month()]:this._months[(this._months.isFormat||hc).test(c)?"format":
"standalone"][a.month()]:e(this._months)?this._months:this._months.standalone};ta.monthsShort=function(a,c){return a?e(this._monthsShort)?this._monthsShort[a.month()]:this._monthsShort[hc.test(c)?"format":"standalone"][a.month()]:e(this._monthsShort)?this._monthsShort:this._monthsShort.standalone};ta.monthsParse=function(a,c,b){var d,f;if(this._monthsParseExact){a:{a=a.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],d=0;12>d;++d)f=
n([2E3,d]),this._shortMonthsParse[d]=this.monthsShort(f,"").toLocaleLowerCase(),this._longMonthsParse[d]=this.months(f,"").toLocaleLowerCase();if(b)c="MMM"===c?za.call(this._shortMonthsParse,a):za.call(this._longMonthsParse,a);else if("MMM"===c){c=za.call(this._shortMonthsParse,a);if(-1!==c)break a;c=za.call(this._longMonthsParse,a)}else{c=za.call(this._longMonthsParse,a);if(-1!==c)break a;c=za.call(this._shortMonthsParse,a)}c=-1!==c?c:null}return c}this._monthsParse||(this._monthsParse=[],this._longMonthsParse=
[],this._shortMonthsParse=[]);for(d=0;12>d;d++)if(f=n([2E3,d]),b&&!this._longMonthsParse[d]&&(this._longMonthsParse[d]=new RegExp("^"+this.months(f,"").replace(".","")+"$","i"),this._shortMonthsParse[d]=new RegExp("^"+this.monthsShort(f,"").replace(".","")+"$","i")),b||this._monthsParse[d]||(f="^"+this.months(f,"")+"|^"+this.monthsShort(f,""),this._monthsParse[d]=new RegExp(f.replace(".",""),"i")),b&&"MMMM"===c&&this._longMonthsParse[d].test(a)||b&&"MMM"===c&&this._shortMonthsParse[d].test(a)||!b&&
this._monthsParse[d].test(a))return d};ta.monthsRegex=function(a){if(this._monthsParseExact)return c(this,"_monthsRegex")||Ea.call(this),a?this._monthsStrictRegex:this._monthsRegex;c(this,"_monthsRegex")||(this._monthsRegex=sb);return this._monthsStrictRegex&&a?this._monthsStrictRegex:this._monthsRegex};ta.monthsShortRegex=function(a){if(this._monthsParseExact)return c(this,"_monthsRegex")||Ea.call(this),a?this._monthsShortStrictRegex:this._monthsShortRegex;c(this,"_monthsShortRegex")||(this._monthsShortRegex=
sb);return this._monthsShortStrictRegex&&a?this._monthsShortStrictRegex:this._monthsShortRegex};ta.week=function(a){return Ca(a,this._week.dow,this._week.doy).week};ta.firstDayOfYear=function(){return this._week.doy};ta.firstDayOfWeek=function(){return this._week.dow};ta.weekdays=function(a,c){return a?e(this._weekdays)?this._weekdays[a.day()]:this._weekdays[this._weekdays.isFormat.test(c)?"format":"standalone"][a.day()]:e(this._weekdays)?this._weekdays:this._weekdays.standalone};ta.weekdaysMin=function(a){return a?
this._weekdaysMin[a.day()]:this._weekdaysMin};ta.weekdaysShort=function(a){return a?this._weekdaysShort[a.day()]:this._weekdaysShort};ta.weekdaysParse=function(a,c,b){var d,f;if(this._weekdaysParseExact)return Ta.call(this,a,c,b);this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]);for(d=0;7>d;d++)if(f=n([2E3,1]).day(d),b&&!this._fullWeekdaysParse[d]&&(this._fullWeekdaysParse[d]=new RegExp("^"+this.weekdays(f,"").replace(".",
"\\.?")+"$","i"),this._shortWeekdaysParse[d]=new RegExp("^"+this.weekdaysShort(f,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[d]=new RegExp("^"+this.weekdaysMin(f,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[d]||(f="^"+this.weekdays(f,"")+"|^"+this.weekdaysShort(f,"")+"|^"+this.weekdaysMin(f,""),this._weekdaysParse[d]=new RegExp(f.replace(".",""),"i")),b&&"dddd"===c&&this._fullWeekdaysParse[d].test(a)||b&&"ddd"===c&&this._shortWeekdaysParse[d].test(a)||b&&"dd"===c&&this._minWeekdaysParse[d].test(a)||
!b&&this._weekdaysParse[d].test(a))return d};ta.weekdaysRegex=function(a){if(this._weekdaysParseExact)return c(this,"_weekdaysRegex")||T.call(this),a?this._weekdaysStrictRegex:this._weekdaysRegex;c(this,"_weekdaysRegex")||(this._weekdaysRegex=sb);return this._weekdaysStrictRegex&&a?this._weekdaysStrictRegex:this._weekdaysRegex};ta.weekdaysShortRegex=function(a){if(this._weekdaysParseExact)return c(this,"_weekdaysRegex")||T.call(this),a?this._weekdaysShortStrictRegex:this._weekdaysShortRegex;c(this,
"_weekdaysShortRegex")||(this._weekdaysShortRegex=sb);return this._weekdaysShortStrictRegex&&a?this._weekdaysShortStrictRegex:this._weekdaysShortRegex};ta.weekdaysMinRegex=function(a){if(this._weekdaysParseExact)return c(this,"_weekdaysRegex")||T.call(this),a?this._weekdaysMinStrictRegex:this._weekdaysMinRegex;c(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=sb);return this._weekdaysMinStrictRegex&&a?this._weekdaysMinStrictRegex:this._weekdaysMinRegex};ta.isPM=function(a){return"p"===(a+"").toLowerCase().charAt(0)};
ta.meridiem=function(a,c,b){return 11<a?b?"pm":"PM":b?"am":"AM"};Ka("en",{dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(a){var c=a%10,c=1===z(a%100/10)?"th":1===c?"st":2===c?"nd":3===c?"rd":"th";return a+c}});b.lang=w("moment.lang is deprecated. Use moment.locale instead.",Ka);b.langData=w("moment.langData is deprecated. Use moment.localeData instead.",Ga);var ab=Math.abs,Hc=bb("ms"),Ic=bb("s"),Jc=bb("m"),Kc=bb("h"),Lc=bb("d"),Mc=bb("w"),Nc=bb("M"),Oc=bb("y"),Pc=gb("milliseconds"),
Qc=gb("seconds"),Rc=gb("minutes"),Sc=gb("hours"),Tc=gb("days"),Uc=gb("months"),Vc=gb("years"),fb=Math.round,Va={ss:44,s:45,m:45,h:22,d:26,M:11},Nb=Math.abs,ma=ba.prototype;ma.isValid=function(){return this._isValid};ma.abs=function(){var a=this._data;this._milliseconds=ab(this._milliseconds);this._days=ab(this._days);this._months=ab(this._months);a.milliseconds=ab(a.milliseconds);a.seconds=ab(a.seconds);a.minutes=ab(a.minutes);a.hours=ab(a.hours);a.months=ab(a.months);a.years=ab(a.years);return this};
ma.add=function(a,c){return Tb(this,a,c,1)};ma.subtract=function(a,c){return Tb(this,a,c,-1)};ma.as=function(a){if(!this.isValid())return NaN;var c,b=this._milliseconds;a=G(a);if("month"===a||"year"===a)return c=this._days+b/864E5,c=this._months+4800*c/146097,"month"===a?c:c/12;c=this._days+Math.round(146097*this._months/4800);switch(a){case "week":return c/7+b/6048E5;case "day":return c+b/864E5;case "hour":return 24*c+b/36E5;case "minute":return 1440*c+b/6E4;case "second":return 86400*c+b/1E3;case "millisecond":return Math.floor(864E5*
c)+b;default:throw Error("Unknown unit "+a);}};ma.asMilliseconds=Hc;ma.asSeconds=Ic;ma.asMinutes=Jc;ma.asHours=Kc;ma.asDays=Lc;ma.asWeeks=Mc;ma.asMonths=Nc;ma.asYears=Oc;ma.valueOf=function(){return this.isValid()?this._milliseconds+864E5*this._days+this._months%12*2592E6+31536E6*z(this._months/12):NaN};ma._bubble=function(){var a=this._milliseconds,c=this._days,b=this._months,d=this._data;0<=a&&0<=c&&0<=b||0>=a&&0>=c&&0>=b||(a+=864E5*Ub(146097*b/4800+c),b=c=0);d.milliseconds=a%1E3;a=u(a/1E3);d.seconds=
a%60;a=u(a/60);d.minutes=a%60;a=u(a/60);d.hours=a%24;c+=u(a/24);a=u(4800*c/146097);b+=a;c-=Ub(146097*a/4800);a=u(b/12);d.days=c;d.months=b%12;d.years=a;return this};ma.clone=function(){return Ma(this)};ma.get=function(a){a=G(a);return this.isValid()?this[a+"s"]():NaN};ma.milliseconds=Pc;ma.seconds=Qc;ma.minutes=Rc;ma.hours=Sc;ma.days=Tc;ma.weeks=function(){return u(this.days()/7)};ma.months=Uc;ma.years=Vc;ma.humanize=function(a){if(!this.isValid())return this.localeData().invalidDate();var c=this.localeData(),
b;b=!a;var d=Ma(this).abs(),f=fb(d.as("s")),e=fb(d.as("m")),g=fb(d.as("h")),h=fb(d.as("d")),p=fb(d.as("M")),d=fb(d.as("y")),f=f<=Va.ss&&["s",f]||f<Va.s&&["ss",f]||1>=e&&["m"]||e<Va.m&&["mm",e]||1>=g&&["h"]||g<Va.h&&["hh",g]||1>=h&&["d"]||h<Va.d&&["dd",h]||1>=p&&["M"]||p<Va.M&&["MM",p]||1>=d&&["y"]||["yy",d];f[2]=b;f[3]=0<+this;f[4]=c;b=lc.apply(null,f);a&&(b=c.pastFuture(+this,b));return c.postformat(b)};ma.toISOString=xb;ma.toString=xb;ma.toJSON=xb;ma.locale=ub;ma.localeData=mb;ma.toIsoString=w("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",
xb);ma.lang=ic;I("X",0,0,"unix");I("x",0,0,"valueOf");J("x",Eb);J("X",/[+-]?\d+(\.\d{1,3})?/);aa("X",function(a,c,b){b._d=new Date(1E3*parseFloat(a,10))});aa("x",function(a,c,b){b._d=new Date(z(a))});b.version="2.23.0";Vb=K;b.fn=P;b.min=function(){var a=[].slice.call(arguments,0);return ia("isBefore",a)};b.max=function(){var a=[].slice.call(arguments,0);return ia("isAfter",a)};b.now=function(){return Date.now?Date.now():+new Date};b.utc=n;b.unix=function(a){return K(1E3*a)};b.months=function(a,c){return Sb(a,
c,"months")};b.isDate=h;b.locale=Ka;b.invalid=p;b.duration=Ma;b.isMoment=v;b.weekdays=function(a,c,b){return Gb(a,c,b,"weekdays")};b.parseZone=function(){return K.apply(null,arguments).parseZone()};b.localeData=Ga;b.isDuration=X;b.monthsShort=function(a,c){return Sb(a,c,"monthsShort")};b.weekdaysMin=function(a,c,b){return Gb(a,c,b,"weekdaysMin")};b.defineLocale=Ia;b.updateLocale=function(a,c){if(null!=c){var b,d=Zb;b=Da(a);null!=b&&(d=b._config);c=F(d,c);c=new C(c);c.parentLocale=Aa[a];Aa[a]=c;Ka(a)}else null!=
Aa[a]&&(null!=Aa[a].parentLocale?Aa[a]=Aa[a].parentLocale:null!=Aa[a]&&delete Aa[a]);return Aa[a]};b.locales=function(){return bc(Aa)};b.weekdaysShort=function(a,c,b){return Gb(a,c,b,"weekdaysShort")};b.normalizeUnits=G;b.relativeTimeRounding=function(a){return void 0===a?fb:"function"===typeof a?(fb=a,!0):!1};b.relativeTimeThreshold=function(a,c){if(void 0===Va[a])return!1;if(void 0===c)return Va[a];Va[a]=c;"s"===a&&(Va.ss=c-1);return!0};b.calendarFormat=function(a,c){a=a.diff(c,"days",!0);return-6>
a?"sameElse":-1>a?"lastWeek":0>a?"lastDay":1>a?"sameDay":2>a?"nextDay":7>a?"nextWeek":"sameElse"};b.prototype=P;b.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"};return b})},"esri/arcade/FunctionWrapper":function(){define(["require","exports"],function(b,e){return function(){return function(b,d){this.context=
this.definition=null;this.definition=b;this.context=d}}()})},"esri/arcade/ImmutablePathArray":function(){define(["require","exports","../core/tsSupport/extendsHelper","./ImmutableArray","./ImmutablePointArray"],function(b,e,m,d,k){return function(b){function d(a,c,d,e,g){a=b.call(this,a)||this;a._lazyPath=[];a._hasZ=!1;a._hasM=!1;a._hasZ=d;a._hasM=e;a._spRef=c;a._cacheId=g;return a}m(d,b);d.prototype.get=function(a){if(void 0===this._lazyPath[a]){var c=this._elements[a];if(void 0===c)return;this._lazyPath[a]=
new k(c,this._spRef,this._hasZ,this._hasM,this._cacheId,a)}return this._lazyPath[a]};d.prototype.equalityTest=function(a){return a===this?!0:null===a||!1===a instanceof d?!1:a.getUniqueHash()===this.getUniqueHash()};d.prototype.getUniqueHash=function(){return this._cacheId.toString()};return d}(d)})},"esri/arcade/ImmutablePointArray":function(){define(["require","exports","../core/tsSupport/extendsHelper","./ImmutableArray","../geometry/Point"],function(b,e,m,d,k){return function(b){function d(a,
c,d,e,g,h){a=b.call(this,a)||this;a._lazyPt=[];a._hasZ=!1;a._hasM=!1;a._spRef=c;a._hasZ=d;a._hasM=e;a._cacheId=g;a._partId=h;return a}m(d,b);d.prototype.get=function(a){if(void 0===this._lazyPt[a]){var c=this._elements[a];if(void 0===c)return;var b=this._hasZ,d=this._hasM,e=null,e=b&&!d?new k(c[0],c[1],c[2],void 0,this._spRef):d&&b?new k(c[0],c[1],void 0,c[2],this._spRef):b&&d?new k(c[0],c[1],c[2],c[3],this._spRef):new k(c[0],c[1],this._spRef);e.cache._arcadeCacheId=this._cacheId.toString()+"-"+this._partId.toString()+
"-"+a.toString();this._lazyPt[a]=e}return this._lazyPt[a]};d.prototype.equalityTest=function(a){return a===this?!0:null===a||!1===a instanceof d?!1:a.getUniqueHash()===this.getUniqueHash()};d.prototype.getUniqueHash=function(){return this._cacheId.toString()+"-"+this._partId.toString()};return d}(d)})},"esri/arcade/Feature":function(){define("require exports ../core/tsSupport/assignHelper ./Dictionary ./ImmutableArray ./languageUtils ../geometry/Geometry ../geometry/Point ../geometry/support/jsonUtils ../layers/graphics/featureConversionUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f){return function(){function b(){this.declaredClass="esri.arcade.Feature";this._layer=this.attributes=this._geometry=this._optimizedGeomDefinition=null;this.immutable=this.immutable=this._datesfixed=!0}b.createFromGraphic=function(a){var c=new b;c._geometry=a.geometry?a.geometry:null;c.attributes=void 0===a.attributes?{}:null===a.attributes?{}:a.attributes;a._sourceLayer?(c._layer=a._sourceLayer,c._datesfixed=!1):a._layer?(c._layer=a._layer,c._datesfixed=!1):a.layer&&(c._layer=
a.layer,c._datesfixed=!1);return c};b.createFromArcadeFeature=function(a){var c=new b;c._datesfixed=a._datesfixed;c.attributes=a.attributes;c._geometry=a._geometry;c._optimizedGeomDefinition=a._optimizedGeomDefinition;a._layer&&(c._layer=a._layer);return c};b.createFromOptimisedFeature=function(a,c,d){var f=new b;f._geometry=a.geometry?{geometry:a.geometry}:null;f._optimizedGeomDefinition=d;f.attributes=a.attributes||{};f._layer=c;f._datesfixed=!1;return f};b.createFromArcadeDictionary=function(a){var c=
new b;c.attributes=a.field("attributes");null!==c.attributes?c.attributes instanceof d?(c.attributes=c.attributes.attributes,null===c.attributes&&(c.attributes={})):c.attributes={}:c.attributes={};c._geometry=a.field("geometry");null!==c._geometry&&(c._geometry instanceof d?c._geometry=b.parseGeometryFromDictionary(c._geometry):c._geometry instanceof h||(c._geometry=null));return c};b.createFromGraphicLikeObject=function(a,c,d){void 0===d&&(d=null);var f=new b;null===c&&(c={});f.attributes=c;f._geometry=
a?a:null;f._layer=d;f._layer&&(f._datesfixed=!1);return f};b.prototype.repurposeFromGraphicLikeObject=function(a,c,b){void 0===b&&(b=null);null===c&&(c={});this.attributes=c;this._geometry=a?a:null;this._datesfixed=(this._layer=b)?!1:!0};b.prototype.castToText=function(){var a="",c;for(c in this.attributes){""!==a&&(a+=",");var b=this.attributes[c];null==b?a+=JSON.stringify(c)+":null":l.isBoolean(b)||l.isNumber(b)||l.isString(b)?a+=JSON.stringify(c)+":"+JSON.stringify(b):b instanceof h?a+=JSON.stringify(c)+
":"+l.toStringExplicit(b):b instanceof k?a+=JSON.stringify(c)+":"+l.toStringExplicit(b):b instanceof Array?a+=JSON.stringify(c)+":"+l.toStringExplicit(b):b instanceof Date?a+=JSON.stringify(c)+":"+JSON.stringify(b):null!==b&&"object"===typeof b&&void 0!==b.castToText&&(a+=JSON.stringify(c)+":"+b.castToText())}return'{"geometry":'+(null===this.geometry()?"null":l.toStringExplicit(this.geometry()))+',"attributes":{'+a+"}}"};b.prototype._fixDates=function(){for(var a=[],c=0;c<this._layer.fields.length;c++){var b=
this._layer.fields[c];"date"!==b.type&&"esriFieldTypeDate"!==b.type||a.push(b.name)}0<a.length&&this._fixDateFields(a);this._datesfixed=!0};b.prototype._fixDateFields=function(a){this.attributes=m({},this.attributes);for(var c=0;c<a.length;c++){var b=this.attributes[a[c]];if(null!==b)if(void 0===b)for(var d in this.attributes){if(d.toLowerCase()===a[c]){b=this.attributes[d];null===b||b instanceof Date||(this.attributes[d]=new Date(b));break}}else b instanceof Date||(this.attributes[a[c]]=new Date(b))}};
b.prototype.geometry=function(){if(null===this._geometry||this._geometry instanceof h)return this._geometry;this._optimizedGeomDefinition?(this._geometry=c.fromJSON(f.convertToGeometry(this._geometry,this._optimizedGeomDefinition.geometryType,this._optimizedGeomDefinition.hasZ,this._optimizedGeomDefinition.hasM)),this._geometry.spatialReference=this._optimizedGeomDefinition.spatialReference):this._geometry=c.fromJSON(this._geometry);return this._geometry};b.prototype.field=function(a){!1===this._datesfixed&&
this._fixDates();var c=a.toLowerCase();a=this.attributes[a];if(void 0!==a)return a;for(var b in this.attributes)if(b.toLowerCase()===c)return this.attributes[b];if(this._hasFieldDefinition(c))return null;throw Error("Field not Found");};b.prototype._hasFieldDefinition=function(a){if(null===this._layer)return!1;for(var c=0;c<this._layer.fields.length;c++)if(this._layer.fields[c].name.toLowerCase()===a)return!0;return!1};b.prototype._field=function(a){!1===this._datesfixed&&this._fixDates();var c=a.toLowerCase();
a=this.attributes[a];if(void 0!==a)return a;for(var b in this.attributes)if(b.toLowerCase()===c)return this.attributes[b];return null};b.prototype.setField=function(a,c){if(this.immutable)throw Error("Feature is Immutable");if(!1===l.isSimpleType(c))throw Error("Illegal Value Assignment to Feature");var b=a.toLowerCase();if(void 0===this.attributes[a])for(var d in this.attributes)if(d.toLowerCase()===b){this.attributes[d]=c;return}this.attributes[a]=c};b.prototype.hasField=function(a){var c=a.toLowerCase();
if(void 0!==this.attributes[a])return!0;for(var b in this.attributes)if(b.toLowerCase()===c)return!0;return this._hasFieldDefinition(c)?!0:!1};b.prototype.keys=function(){var a=[],c={},b;for(b in this.attributes)a.push(b),c[b.toLowerCase()]=1;if(null!==this._layer)for(b=0;b<this._layer.fields.length;b++){var d=this._layer.fields[b];1!==c[d.name.toLowerCase()]&&a.push(d.name)}return a=a.sort()};b.parseGeometryFromDictionary=function(a){a=b.convertDictionaryToJson(a,!0);void 0!==a.spatialreference&&
(a.spatialReference=a.spatialreference,delete a.spatialreference);void 0!==a.rings&&(a.rings=this.fixPathArrays(a.rings,!0===a.hasZ,!0===a.hasM));void 0!==a.paths&&(a.paths=this.fixPathArrays(a.paths,!0===a.hasZ,!0===a.hasM));void 0!==a.points&&(a.points=this.fixPointArrays(a.points,!0===a.hasZ,!0===a.hasM));return c.fromJSON(a)};b.fixPathArrays=function(a,c,b){var d=[];if(a instanceof Array)for(var f=0;f<a.length;f++)d.push(this.fixPointArrays(a[f],c,b));else if(a instanceof k)for(f=0;f<a.length();f++)d.push(this.fixPointArrays(a.get(f),
c,b));return d};b.fixPointArrays=function(c,b,d){var f=[];if(c instanceof Array)for(var e=0;e<c.length;e++){var g=c[e];g instanceof a?b&&d?f.push([g.x,g.y,g.z,g.m]):b?f.push([g.x,g.y,g.z]):d?f.push([g.x,g.y,g.m]):f.push([g.x,g.y]):g instanceof k?f.push(g.toArray()):f.push(g)}else if(c instanceof k)for(e=0;e<c.length();e++)g=c.get(e),g instanceof a?b&&d?f.push([g.x,g.y,g.z,g.m]):b?f.push([g.x,g.y,g.z]):d?f.push([g.x,g.y,g.m]):f.push([g.x,g.y]):g instanceof k?f.push(g.toArray()):f.push(g);return f};
b.convertDictionaryToJson=function(a,c){void 0===c&&(c=!1);var f={},e;for(e in a.attributes){var g=a.attributes[e];g instanceof d&&(g=b.convertDictionaryToJson(g));c?f[e.toLowerCase()]=g:f[e]=g}return f};b.parseAttributesFromDictionary=function(a){var c={},b;for(b in a.attributes){var d=a.attributes[b];if(l.isSimpleType(d))c[b]=d;else throw Error("Illegal Argument");}return c};b.fromJson=function(a){var d=null;null!==a.geometry&&void 0!==a.geometry&&(d=c.fromJSON(a.geometry));var f={};if(null!==a.attributes&&
void 0!==a.attributes)for(var e in a.attributes){var g=a.attributes[e];if(null===g)f[e]=g;else if(l.isString(g)||l.isNumber(g)||l.isBoolean(g)||l.isDate(g))f[e]=g;else throw Error("Illegal Argument");}return b.createFromGraphicLikeObject(d,f,null)};b.prototype.domainValueLookup=function(a,c,b){if(null===this._layer||!this._layer.fields)return null;b=l.getDomain(a,this._layer,this,b);if(void 0===c)try{c=this.field(a)}catch(t){return null}return l.getDomainValue(b,c)};b.prototype.domainCodeLookup=function(a,
c,b){if(null===this._layer||!this._layer.fields)return null;if(void 0===c){try{c=this.field(a)}catch(t){return null}return c}a=l.getDomain(a,this._layer,this,b);return l.getDomainCode(a,c)};return b}()})},"esri/layers/graphics/featureConversionUtils":function(){define("require exports ../../core/Error ../../core/Logger ../../geometry/support/jsonUtils ./OptimizedFeature ./OptimizedFeatureSet ./OptimizedGeometry ./utils".split(" "),function(b,e,m,d,k,l,h,a,c){function f(a,c){return Math.round((c-a.translate[0])/
a.scale[0])}function n(a,c){return Math.round((a.translate[1]-c)/a.scale[1])}function g(a,c){return c*a.scale[0]+a.translate[0]}function q(a,c){return a.translate[1]-c*a.scale[1]}function p(a){a=a.coords;return{x:a[0],y:a[1]}}function t(a,c){a.coords[0]=c.x;a.coords[1]=c.y;return a}function r(a){a=a.coords;return{x:a[0],y:a[1],z:a[2]}}function v(a,c){a.coords[0]=c.x;a.coords[1]=c.y;a.coords[2]=c.z;return a}function u(a){a=a.coords;return{x:a[0],y:a[1],m:a[2]}}function z(a,c){a.coords[0]=c.x;a.coords[1]=
c.y;a.coords[2]=c.m;return a}function y(a){a=a.coords;return{x:a[0],y:a[1],z:a[2],m:a[3]}}function x(a,c){a.coords[0]=c.x;a.coords[1]=c.y;a.coords[2]=c.z;a.coords[3]=c.m;return a}function w(a,c){return a&&c?x:a?v:c?z:t}function A(a,b,d){if(!a)return null;for(var f=c.getStride(b,d),e=[],g=0;g<a.coords.length;g+=f){for(var h=[],p=0;p<f;p++)h.push(a.coords[g+p]);e.push(h)}return b?d?{points:e,hasZ:b,hasM:d}:{points:e,hasZ:b}:d?{points:e,hasM:d}:{points:e}}function B(a,b,d){void 0===d&&(d=c.getStride(b.hasZ,
b.hasM));a.lengths[0]=b.points.length;var f=a.coords,e=0,g=0;for(b=b.points;g<b.length;g++)for(var h=b[g],p=0;p<d;p++)f[e++]=h[p];return a}function F(a,b,d){if(!a)return null;var f=c.getStride(b,d),e=a.coords,g=[],h=0,p=0;for(a=a.lengths;p<a.length;p++){for(var n=a[p],l=[],k=0;k<n;k++){for(var m=[],r=0;r<f;r++)m.push(e[h++]);l.push(m)}g.push(l)}return b?d?{paths:g,hasZ:b,hasM:d}:{paths:g,hasZ:b}:d?{paths:g,hasM:d}:{paths:g}}function C(a,b,d){void 0===d&&(d=c.getStride(b.hasZ,b.hasM));var f=a.lengths,
e=a.coords,g=0,h=0;for(b=b.paths;h<b.length;h++){for(var p=b[h],n=0,l=p;n<l.length;n++)for(var k=l[n],m=0;m<d;m++)e[g++]=k[m];f.push(p.length)}return a}function E(a,b,d){if(!a)return null;var f=c.getStride(b,d),e=a.coords,g=[],h=0,p=0;for(a=a.lengths;p<a.length;p++){for(var n=a[p],l=[],k=0;k<n;k++){for(var m=[],r=0;r<f;r++)m.push(e[h++]);l.push(m)}g.push(l)}return b?d?{rings:g,hasZ:b,hasM:d}:{rings:g,hasZ:b}:d?{rings:g,hasM:d}:{rings:g}}function G(a,b,d,f){void 0===d&&(d=b.hasZ);void 0===f&&(f=b.hasM);
d=c.getStride(d,f);f=a.lengths;var e=a.coords,g=0,h=f.length=e.length=0;for(b=b.rings;h<b.length;h++){for(var p=b[h],n=0,l=p;n<l.length;n++)for(var k=l[n],m=0;m<d;m++)e[g++]=k[m];f.push(p.length)}return a}function Q(b,d,f,e,g,h){b.length=0;if(f){switch(f){case "esriGeometryPoint":e=w(e,g);for(g=0;g<d.length;g++){var p=d[g];f=p.geometry;var p=p.attributes,n=void 0;f&&(n=e(new a.default,f));b.push(new l.default(n,p,null,p[h]))}break;case "esriGeometryMultipoint":e=c.getStride(e,g);for(g=0;g<d.length;g++)p=
d[g],f=p.geometry,p=p.attributes,n=void 0,f&&(n=B(new a.default,f,e)),b.push(new l.default(n,p,null,p[h]));break;case "esriGeometryPolyline":e=c.getStride(e,g);for(g=0;g<d.length;g++)p=d[g],f=p.geometry,p=p.attributes,n=void 0,f&&(n=C(new a.default,f,e)),b.push(new l.default(n,p,null,p[h]));break;case "esriGeometryPolygon":for(f=0;f<d.length;f++){var k=d[f],p=k.geometry,n=k.centroid,k=k.attributes,r=void 0;p&&(r=G(new a.default,p,e,g));n?b.push(new l.default(r,k,t(new a.default,n),k[h])):b.push(new l.default(r,
k,null,k[h]))}break;default:M.error("convertToFeatureSet:unknown-geometry",new m("Unable to parse unknown geometry type '"+f+"'")),b.length=0}return b}b.length=0}function V(a,c,b,d,f){a.length=0;switch(b){case "esriGeometryPoint":b=p;d&&f?b=y:d?b=r:f&&(b=u);for(d=0;d<c.length;d++){var e=c[d];f=e.geometry;e=e.attributes;f=f?b(f):null;a.push({attributes:e,geometry:f})}break;case "esriGeometryMultipoint":for(b=0;b<c.length;b++){var g=c[b],e=g.geometry,g=g.attributes,h=void 0;e&&(h=A(e,d,f));a.push({attributes:g,
geometry:h})}break;case "esriGeometryPolyline":for(b=0;b<c.length;b++)g=c[b],e=g.geometry,g=g.attributes,h=void 0,e&&(h=F(e,d,f)),a.push({attributes:g,geometry:h});break;case "esriGeometryPolygon":for(b=0;b<c.length;b++){var h=c[b],g=h.geometry,e=h.attributes,n=h.centroid,h=void 0;g&&(h=E(g,d,f));n?(g=p(n),a.push({attributes:e,centroid:g,geometry:h})):a.push({attributes:e,geometry:h})}break;default:M.error("convertToFeatureSet:unknown-geometry",new m("Unable to parse unknown geometry type '"+b+"'"))}return a}
function R(a,b,d,e,g,h){a.lengths.length&&(a.lengths.length=0);a.coords.length&&(a.coords.length=0);if(!b||!b.coords.length)return null;g=U[g];var p=b.coords;b=b.lengths;var l=c.getStride(d,e);d=d?e?fa:J:e?J:O;if(!b.length)return d(a.coords,p,0,0,f(h,p[0]),n(h,p[1])),a.lengths.length&&(a.lengths.length=0),a.coords.length=l,a;for(var k,m,r,t=0,q,x=0,B=0;B<b.length;B++){var v=b[B];if(!(v<g)){var u=0;q=x;m=e=f(h,p[t]);r=k=n(h,p[t+1]);d(a.coords,p,q,t,m,r);u++;t+=l;q+=l;for(var w=1;w<v;w++,t+=l)if(m=
f(h,p[t]),r=n(h,p[t+1]),m!==e||r!==k)d(a.coords,p,q,t,m-e,r-k),q+=l,u++,e=m,k=r;u>=g&&(a.lengths.push(u),x=q)}}a.coords.length=x;return a.coords.length?a:null}function I(a,c,b,d,f,e,g){for(var h=g-b,p=0,n=0,l,k=e+b;k<g-b;k+=b){l=c[k];var m=c[k+1],r=c[e],t=c[e+1],q=c[h],x=c[h+1];r===q?l=Math.abs(l-r):(q=(x-t)/(q-r),l=Math.abs(q*l-m+(t-q*r))/Math.sqrt(q*q+1));l>p&&(n=k,p=l)}p>d?(I(a,c,b,d,f,e,n+b),I(a,c,b,d,f,n,g)):(f(a,c,a.length,e,c[e],c[e+1]),f(a,c,a.length,h,c[h],c[h+1]))}function W(a,b,d,f,e){var h=
b.coords,p=b.lengths,n=d?f?fa:J:f?J:O;d=c.getStride(d,f);if(!h.length)return a!==b&&(a.lengths.length=0,a.coords.length=0),a;if(!p.length)return n(a.coords,h,0,0,g(e,h[0]),q(e,h[1])),a!==b&&(a.lengths.length=0,a.coords.length=d),a;var l=e.scale;f=l[0];for(var l=l[1],k=0,m=0;m<p.length;m++){var r=p[m];a.lengths[m]=r;var t=g(e,h[k]),x=q(e,h[k+1]);n(a.coords,h,k,k,t,x);for(var k=k+d,B=1;B<r;B++,k+=d)t+=h[k]*f,x-=h[k+1]*l,n(a.coords,h,k,k,t,x)}a!==b&&(a.lengths.length=p.length,a.coords.length=h.length);
return a}Object.defineProperty(e,"__esModule",{value:!0});var M=d.getLogger("esri.tasks.support.optimizedFeatureSet"),U={esriGeometryPoint:0,esriGeometryPolyline:2,esriGeometryPolygon:3,esriGeometryMultipoint:0},O=function(a,c,b,d,f,e){a[b]=f;a[b+1]=e},J=function(a,c,b,d,f,e){a[b]=f;a[b+1]=e;a[b+2]=c[d+2]},fa=function(a,c,b,d,f,e){a[b]=f;a[b+1]=e;a[b+2]=c[d+2];a[b+3]=c[d+3]};e.quantizeX=f;e.quantizeY=n;e.hydrateX=g;e.hydrateY=q;e.convertToPoint=function(a,c,b){return a?c?b?y(a):r(a):b?u(a):p(a):null};
e.convertFromPoint=function(a,c,b){void 0===b&&(b=w(null!=c.z,null!=c.m));return b(a,c)};e.convertToMultipoint=A;e.convertFromMultipoint=B;e.convertToPolyline=F;e.convertToPolygon=E;e.convertFromPolygon=G;var H=[],da=[];e.convertFromFeature=function(a,c,b,d,f){H[0]=a;a=Q(da,H,c,b,d,f)[0];H.length=da.length=0;return a};e.convertFromFeatures=Q;e.convertToFeature=function(a,c,b,d){da[0]=a;V(H,da,c,b,d);a=H[0];H.length=da.length=0;return a};e.convertFromGeometry=function(c){if(!c)return null;var b=new a.default;
if(k.isPoint(c))return w(null!=c.z,null!=c.m)(b,c);if(k.isPolygon(c))return G(b,c);if(k.isPolyline(c))return C(b,c);if(k.isMultipoint(c))return B(b,c);M.error("convertFromGeometry:unknown-geometry",new m("Unable to parse unknown geometry type '"+c+"'"))};e.convertToGeometry=function(a,c,b,d){a=a&&("coords"in a?a:a.geometry);if(!a)return null;switch(c){case "esriGeometryPoint":return c=p,b&&d?c=y:b?c=r:d&&(c=u),c(a);case "esriGeometryMultipoint":return A(a,b,d);case "esriGeometryPolyline":return F(a,
b,d);case "esriGeometryPolygon":return E(a,b,d);default:M.error("convertToGeometry:unknown-geometry",new m("Unable to parse unknown geometry type '"+c+"'"))}};e.convertToFeatures=V;e.convertToFeatureSet=function(a){var c=a.objectIdFieldName,b=a.spatialReference,d=a.transform,f=a.fields,e=a.hasM,g=a.hasZ,h=a.geometryType,p=a.exceededTransferLimit;a={features:V([],a.features,h,g,e),fields:f,geometryType:h,objectIdFieldName:c,spatialReference:b};d&&(a.transform=d);p&&(a.exceededTransferLimit=p);e&&(a.hasM=
e);g&&(a.hasZ=g);return a};e.convertFromFeatureSet=function(a,c){var b=new h.default,d=a.hasM,f=a.hasZ,e=a.features,g=a.objectIdFieldName,p=a.spatialReference,n=a.geometryType,l=a.exceededTransferLimit,k=a.transform;b.fields=a.fields;b.geometryType=n;b.objectIdFieldName=g||c;b.spatialReference=p;if(!b.objectIdFieldName)return M.error(new m("optimized-features:invalid-objectIdFieldName","objectIdFieldName is missing")),b;e&&Q(b.features,e,n,f,d,b.objectIdFieldName);l&&(b.exceededTransferLimit=l);d&&
(b.hasM=d);f&&(b.hasZ=f);k&&(b.transform=k);return b};e.hydrateOptimizedFeatureSet=function(a){var c=a.transform,b=a.hasM,d=a.hasZ;if(!c)return a;for(var f=0,e=a.features;f<e.length;f++){var g=e[f];g.geometry&&W(g.geometry,g.geometry,b,d,c);g.centroid&&W(g.centroid,g.centroid,b,d,c)}a.transform=null;return a};e.quantizeOptimizedFeatureSet=function(c,b){var d=b.geometryType,f=b.features,e=b.hasM,g=b.hasZ;if(!c)return b;for(var h=0;h<f.length;h++){var p=f[h],n=new l.default(new a.default,p.attributes);
R(n.geometry,p.geometry,e,g,d,c);p.centroid&&(n.centroid=new a.default,R(n.centroid,p.centroid,e,g,"esriGeometryPoint",c));f[h]=n}b.transform=c;return b};e.quantizeOptimizedGeometry=R;e.quantizeOptimizedGeometryRemoveCollinear=function(a,b,d,e,g,h){a.lengths.length&&(a.lengths.length=0);a.coords.length&&(a.coords.length=0);if(!b||!b.coords.length)return null;g=U[g];var p=b.coords;b=b.lengths;var l=c.getStride(d,e);d=d?e?fa:J:e?J:O;if(!b.length)return d(a.coords,p,0,0,f(h,p[0]),n(h,p[1])),a.lengths.length&&
(a.lengths.length=0),a.coords.length=l,a;for(var k,m,r,t=0,q,x=0,B=0;B<b.length;B++){var v=b[B];if(!(v<g)){var u=0;q=x;e=k=f(h,p[t]);r=m=n(h,p[t+1]);d(a.coords,p,q,t,e,r);u++;for(var t=t+l,w=!1,y=0,z=0,A=1;A<v;A++,t+=l)if(e=f(h,p[t]),r=n(h,p[t+1]),e!==k||r!==m)k=e-k,m=r-m,w&&(0===y&&0===k||0===z&&0===m)?(y+=k,z+=m):(w=!0,y=k,z=m,q+=l,u++),d(a.coords,p,q,t,y,z),k=e,m=r;w&&(q+=l,d(a.coords,p,q,t,y,z));u>=g&&(a.lengths.push(u),x=q)}}a.coords.length!==x&&(a.coords.length=x);return a.coords.length?a:null};
e.generalizeOptimizedGeometry=function(a,b,d,f,e,g){a.lengths.length&&(a.lengths.length=0);a.coords.length&&(a.coords.length=0);if(!b||!b.coords.length)return null;e=U[e];var h=b.coords;b=b.lengths;var p=c.getStride(d,f);d=d?f?fa:J:f?J:O;if(!b.length)return d(a.coords,h,0,0,h[0],h[1]),a.lengths.length&&(a.lengths.length=0),a.coords.length=p,a;for(var n=f=0;n<b.length;n++){var l=b[n];if(!(l<e)){var k=a.coords.length/p;I(a.coords,h,p,g,d,f,f+l*p);var m=a.coords.length/p-k;m>=e?a.lengths.push(m):a.coords.length=
k*p}f+=l*p}return a.coords.length?a:null};e.getBoundsOptimizedGeometry=function(a,b,d,f){d=c.getStride(d,f);var e=f=Number.POSITIVE_INFINITY,g=Number.NEGATIVE_INFINITY,h=Number.NEGATIVE_INFINITY;if(b&&b.coords){b=b.coords;for(var p=0;p<b.length;p+=d){var n=b[p],l=b[p+1];f=Math.min(f,n);g=Math.max(g,n);e=Math.min(e,l);h=Math.max(h,l)}}a[0]=f;a[1]=e;a[2]=g;a[3]=h;return a};e.getQuantizedBoundsOptimizedGeometry=function(a,b,d,f){d=c.getStride(d,f);f=b.coords;var e=Number.POSITIVE_INFINITY,g=Number.POSITIVE_INFINITY,
h=Number.NEGATIVE_INFINITY,p=Number.NEGATIVE_INFINITY,n=0,l=0;for(b=b.lengths;l<b.length;l++)for(var k=b[l],m=f[n],r=f[n+1],e=Math.min(m,e),g=Math.min(r,g),h=Math.max(m,h),p=Math.max(r,p),n=n+d,t=1;t<k;t++,n+=d){var q=f[n],x=f[n+1],m=m+q,r=r+x;0>q&&(e=Math.min(e,m));0<q&&(h=Math.max(h,m));0>x?g=Math.min(g,r):0<x&&(p=Math.max(p,r))}a[0]=e;a[1]=g;a[2]=h;a[3]=p;return a};e.hydrateOptimizedGeometry=W})},"esri/layers/graphics/OptimizedFeature":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,
"__esModule",{value:!0});b=function(){return function(b,d,e,l){void 0===b&&(b=null);void 0===d&&(d={});this.geometry=b;d&&(this.attributes=d);e&&(this.centroid=e);null!=l&&(this.objectId=l)}}();e.default=b})},"esri/layers/graphics/OptimizedFeatureSet":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});b=function(){return function(){this.spatialReference=this.geometryType=this.geometryProperties=this.geohashFieldName=this.globalIdFieldName=this.objectIdFieldName=
null;this.hasM=this.hasZ=!1;this.features=[];this.fields=[];this.transform=null;this.exceededTransferLimit=!1}}();e.default=b})},"esri/layers/graphics/OptimizedGeometry":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});b=function(){return function(b,d){void 0===b&&(b=[]);void 0===d&&(d=[]);this.lengths=b;this.coords=d}}();e.default=b})},"esri/layers/graphics/utils":function(){define(["require","exports","../../geometry/support/jsonUtils"],function(b,
e,m){Object.defineProperty(e,"__esModule",{value:!0});var d=function(){return function(b,d,a){this.geometryType=b;this.hasM=d;this.hasZ=a}}();e.OptimizedGeometryInfo=d;var k={};e.getOptimizedGeometryInfo=function(b){var e=m.getJsonType(b),a;m.isPoint(b)?(a=null!=b.z,b=null!=b.m):(a=b.hasZ,b=b.hasM);var c=e+a+b;k[c]||(k[c]=new d(e,a,b));return k[c]};e.getStride=function(b,d){return b?d?4:3:d?3:2}})},"esri/arcade/treeAnalysis":function(){define(["require","exports"],function(b,e){function m(a,c,b,d){return"0"!==
a.min&&b.length<Number(a.min)||"*"!==a.max&&b.length>Number(a.max)?-2:1}function d(a,c,b){if(null!==b.localScope&&void 0!==b.localScope[a.toLowerCase()]){var d=b.localScope[a.toLowerCase()];if("FormulaFunction"===d.type||"any"===d.type)return void 0===d.signature&&(d.signature={min:"0",max:"*"}),m(d.signature,a,c,b)}return void 0!==b.globalScope[a.toLowerCase()]&&(d=b.globalScope[a.toLowerCase()],"FormulaFunction"===d.type||"any"===d.type)?(void 0===d.signature&&(d.signature={min:"0",max:"*"}),m(d.signature,
a,c,b)):-1}function k(a,c){if(a)for(var b=0;b<a.length;b++)l(a[b],c)}function l(a,c){if(a&&!1!==c(a))switch(a.type){case "ArrayExpression":k(a.elements,c);break;case "AssignmentExpression":case "BinaryExpression":l(a.left,c);l(a.right,c);break;case "BlockStatement":k(a.body,c);break;case "CallExpression":l(a.callee,c);k(a.arguments,c);break;case "ConditionalExpression":l(a.test,c);l(a.alternate,c);l(a.consequent,c);break;case "DoWhileStatement":l(a.test,c);l(a.body,c);break;case "ExpressionStatement":l(a.expression,
c);break;case "ForInStatement":l(a.left,c);l(a.right,c);l(a.body,c);break;case "ForStatement":l(a.init,c);l(a.test,c);l(a.update,c);l(a.body,c);break;case "FunctionDeclaration":case "FunctionDeclaration":case "FunctionExpression":l(a.id,c);k(a.params,c);l(a.body,c);break;case "IfStatement":l(a.test,c);l(a.consequent,c);l(a.alternate,c);break;case "LogicalExpression":l(a.left,c);l(a.right,c);break;case "MemberExpression":l(a.object,c);l(a.property,c);break;case "NewExpression":l(a.callee,c);k(a.arguments,
c);break;case "ObjectExpression":k(a.properties,c);break;case "Program":k(a.body,c);break;case "Property":l(a.key,c);l(a.value,c);break;case "ReturnStatement":l(a.argument,c);break;case "UnaryExpression":l(a.argument,c);break;case "UpdateExpression":l(a.argument,c);break;case "VariableDeclaration":k(a.declarations,c);break;case "VariableDeclarator":l(a.id,c),l(a.init,c)}}function h(a,c){void 0===c&&(c=!0);var b=q(a,"SYNTAX","UNREOGNISED");try{switch(a.type){case "VariableDeclarator":return null!==
a.init&&"FunctionExpression"===a.init.type?q(a,"SYNTAX","FUNCTIONVARIABLEDECLARATOR"):"Identifier"!==a.id.type?q(a,"SYNTAX","VARIABLEMUSTHAVEIDENTIFIER"):null!==a.init?h(a.init,!1):"";case "VariableDeclaration":for(var d=0;d<a.declarations.length;d++)if(b=h(a.declarations[d],c),""!==b)return b;return"";case "ForInStatement":b=h(a.left,c);if(""!==b)break;if("VariableDeclaration"===a.left.type){if(1<a.left.declarations.length)return q(a,"SYNTAX","ONLY1VAR");if(null!==a.left.declarations[0].init)return q(a,
"SYNTAX","CANNOTDECLAREVAL")}else if("Identifier"!==a.left.type)return q(a,"SYNTAX","LEFTNOTVAR");b=h(a.right,c);if(""!==b)break;b=h(a.body,c);if(""!==b)break;return"";case "ForStatement":if(null!==a.test&&(b=h(a.test,c),""!==b))break;if(null!==a.init&&(b=h(a.init,c),""!==b))break;if(null!==a.update&&(b=h(a.update,c),""!==b))break;if(null!==a.body&&(b=h(a.body,c),""!==b))break;return"";case "ContinueStatement":return"";case "EmptyStatement":return"";case "BreakStatement":return"";case "IfStatement":b=
h(a.test,c);if(""!==b)break;if(null!==a.consequent&&(b=h(a.consequent,!1),""!==b))break;if(null!==a.alternate&&(b=h(a.alternate,!1),""!==b))break;return"";case "BlockStatement":for(var f=[],d=0;d<a.body.length;d++)"EmptyStatement"!==a.body[d].type&&f.push(a.body[d]);a.body=f;for(d=0;d<a.body.length;d++)if(b=h(a.body[d],c),""!==b)return b;return"";case "FunctionDeclaration":return!1===c?q(a,"SYNTAX","GLOBALFUNCTIONSONLY"):"Identifier"!==a.id.type?q(a,"SYNTAX","FUNCTIONMUSTHAVEIDENTIFIER"):h(a.body,
!1);case "ReturnStatement":return null!==a.argument?h(a.argument,c):"";case "UpdateExpression":return"Identifier"!==a.argument.type&&"MemberExpression"!==a.argument.type?q(a,"SYNTAX","ASSIGNMENTTOVARSONLY"):h(a.argument,c);case "AssignmentExpression":if("Identifier"!==a.left.type&&"MemberExpression"!==a.left.type)return q(a,"SYNTAX","ASSIGNMENTTOVARSONLY");b=h(a.left,c);if(""!==b)break;switch(a.operator){case "\x3d":case "/\x3d":case "*\x3d":case "%\x3d":case "+\x3d":case "-\x3d":break;default:return q(a,
"SYNTAX","OPERATORNOTRECOGNISED")}return h(a.right,!1);case "ExpressionStatement":return h(a.expression,!1);case "Identifier":b="";break;case "MemberExpression":b=h(a.object,c);if(""!==b)break;return!0===a.computed?h(a.property,c):"";case "Literal":return"";case "CallExpression":if("Identifier"!==a.callee.type)return q(a,"SYNTAX","ONLYNODESSUPPORTED");b="";for(d=0;d<a.arguments.length;d++)if(b=h(a.arguments[d],c),""!==b)return b;return"";case "UnaryExpression":b=h(a.argument,c);break;case "BinaryExpression":b=
h(a.left,c);if(""!==b)break;b=h(a.right,c);if(""!==b)break;switch(a.operator){case "\x3d\x3d":case "!\x3d":case "\x3c":case "\x3c\x3d":case "\x3e":case "\x3e\x3d":case "+":case "-":case "*":case "/":case "%":break;default:return q(a,"SYNTAX","OPERATORNOTRECOGNISED")}return"";case "LogicalExpression":b=h(a.left,c);if(""!==b)break;b=h(a.right);if(""!==b)break;switch(a.operator){case "\x26\x26":case "||":break;default:return q(a,"SYNTAX","OPERATORNOTRECOGNISED")}return"";case "ConditionalExpression":return q(a,
"SYNTAX","NOTSUPPORTED");case "ArrayExpression":b="";for(d=0;d<a.elements.length&&(b=h(a.elements[d],c),""===b);d++);break;case "ObjectExpression":b="";for(d=0;d<a.properties.length;d++){b="";if(null!==a.properties[d].key&&("Literal"!==a.properties[d].key.type&&"Identifier"!==a.properties[d].key.type&&(b=q(a,"SYNTAX","OBJECTPROPERTYMUSTBESTRING")),"Literal"===a.properties[d].key.type)){var f=a.properties[d].key,e="value"in f?f.value:null;"string"===typeof e||e instanceof String||(b=q(a,"SYNTAX","OBJECTPROPERTYMUSTBESTRING"))}""===
b&&(b=h(a.properties[d],c));if(""!==b)break}break;case "Property":if("Literal"!==a.key.type&&"Identifier"!==a.key.type)return q(a,"SYNTAX","ONLYLITERAL");if("Identifier"!==a.key.type&&(b=h(a.key,c),""!==b))break;b=h(a.value,c)}return b}catch(E){throw E;}}function a(c,b){var e=q(c,"SYNTAX","UNREOGNISED"),g=null,h="";try{switch(c.type){case "VariableDeclarator":if(null!==c.init&&"FunctionExpression"===c.init.type)return q(c,"SYNTAX","FUNCTIONVARIABLEDECLARATOR");var p=null===c.init?"":a(c.init,b);if(""!==
p)return p;"Identifier"===c.id.type&&(null===b.localScope?b.globalScope[c.id.name.toLowerCase()]={type:"any"}:b.localScope[c.id.name.toLowerCase()]={type:"any"});return"";case "FunctionDeclaration":g=f(c.id.name.toLowerCase(),c,b);h=n(c,b);if(""!==h)return h;if(null!==b.localScope)return q(c,"SYNTAX","GLOBALFUNCTIONSONLY");g.isnative=!1;b.globalScope[c.id.name.toLowerCase()]={type:"FormulaFunction",signature:[g]};return"";case "VariableDeclaration":for(var e="",l=0;l<c.declarations.length&&(e=a(c.declarations[l],
b),""===e);l++);break;case "IfStatement":e=a(c.test,b);if(""!==e)break;if("AssignmentExpression"===c.test.type||"UpdateExpression"===c.test.type)return q(c.test,"SYNTAX","CANNOT_USE_ASSIGNMENT_IN_CONDITION");if(null!==c.consequent&&(e=a(c.consequent,b),""!==e))break;if(null!==c.alternate&&(e=a(c.alternate,b),""!==e))break;return"";case "EmptyStatement":return"";case "BlockStatement":for(l=0;l<c.body.length;l++)if(e=a(c.body[l],b),""!==e)return e;return"";case "ReturnStatement":return null!==c.argument?
a(c.argument,b):"";case "ForInStatement":if("VariableDeclaration"===c.left.type){if(1<c.left.declarations.length)return q(c,"SYNTAX","ONLY1VAR");if(null!==c.left.declarations[0].init)return q(c,"SYNTAX","CANNOTDECLAREVAL")}else if("Identifier"!==c.left.type)return q(c,"SYNTAX","LEFTNOTVAR");e=a(c.left,b);if(""!==e)break;e=a(c.right,b);if(""!==e)break;e=a(c.body,b);if(""!==e)break;return"";case "ForStatement":if(null!==c.init&&(e=a(c.init,b),""!==e))break;if(null!==c.test&&(e=a(c.test,b),""!==e))break;
if(null!==c.body&&(e=a(c.body,b),""!==e))break;if(null!==c.update&&(e=a(c.update,b),""!==e))break;return"";case "BreakStatement":return"";case "ContinueStatement":return"";case "UpdateExpression":if("Identifier"!==c.argument.type&&"MemberExpression"!==c.argument.type)return q(c,"SYNTAX","ASSIGNMENTTOVARSONLY");var k=!1;if("MemberExpression"===c.argument.type)return a(c.argument,b);null!==b.localScope&&void 0!==b.localScope[c.argument.name.toLowerCase()]&&(k=!0);void 0!==b.globalScope[c.argument.name.toLowerCase()]&&
(k=!0);return!1===k?"Identifier "+c.argument.name+" has not been declared.":"";case "AssignmentExpression":if("Identifier"!==c.left.type&&"MemberExpression"!==c.left.type)return q(c,"SYNTAX","ASSIGNMENTTOVARSONLY");var m=a(c.right,b);if(""!==m)return m;k=!1;if("MemberExpression"===c.left.type)return m=a(c.left,b),""!==m?m:"";null!==b.localScope&&void 0!==b.localScope[c.left.name.toLowerCase()]&&(k=!0);void 0!==b.globalScope[c.left.name.toLowerCase()]&&(k=!0);return!1===k?"Identifier "+c.left.name+
" has not been declared.":"";case "ExpressionStatement":return a(c.expression,b);case "Identifier":var r=c.name.toLowerCase();if(null!==b.localScope&&void 0!==b.localScope[r])return"";e=void 0!==b.globalScope[r]?"":q(c,"SYNTAX","VARIABLENOTFOUND");break;case "MemberExpression":e=a(c.object,b);if(""!==e)break;return!0===c.computed?a(c.property,b):"";case "Literal":return"";case "CallExpression":if("Identifier"!==c.callee.type)return q(c,"SYNTAX","ONLYNODESSUPPORTED");e="";for(l=0;l<c.arguments.length;l++)if(e=
a(c.arguments[l],b),""!==e)return e;var t=d(c.callee.name,c.arguments,b);-1===t&&(e=q(c,"SYNTAX","NOTFOUND"));-2===t&&(e=q(c,"SYNTAX","WRONGSIGNATURE"));break;case "UnaryExpression":e=a(c.argument,b);break;case "BinaryExpression":e=a(c.left,b);if(""!==e)break;e=a(c.right,b);if(""!==e)break;return"";case "LogicalExpression":e=a(c.left,b);if(""!==e)break;if("AssignmentExpression"===c.left.type||"UpdateExpression"===c.left.type)return q(c.left,"SYNTAX","CANNOT_USE_ASSIGNMENT_IN_CONDITION");e=a(c.right,
b);if(""!==e)break;return"AssignmentExpression"===c.right.type||"UpdateExpression"===c.right.type?q(c.right,"SYNTAX","CANNOT_USE_ASSIGNMENT_IN_CONDITION"):"";case "ConditionalExpression":return q(c,"SYNTAX","NOTSUPPORTED");case "ArrayExpression":e="";for(l=0;l<c.elements.length&&(e=a(c.elements[l],b),""===e);l++);break;case "ObjectExpression":e="";for(l=0;l<c.properties.length;l++){e="";if(null!==c.properties[l].key&&("Literal"!==c.properties[l].key.type&&"Identifier"!==c.properties[l].key.type&&
(e=q(c,"SYNTAX","OBJECTPROPERTYMUSTBESTRING")),"Literal"===c.properties[l].key.type)){var v=c.properties[l].key,u="value"in v?v.value:null;"string"===typeof u||u instanceof String||(e=q(c,"SYNTAX","OBJECTPROPERTYMUSTBESTRING"))}""===e&&(e=a(c.properties[l],b));if(""!==e)break}break;case "Property":if("Literal"!==c.key.type&&"Identifier"!==c.key.type)return q(c,"SYNTAX","ONLYLITERAL");if("Identifier"!==c.key.type&&(e=a(c.key,b),""!==e))break;e=a(c.value,b)}return e}catch(M){throw M;}}function c(a,
c){var b=!1,d=c.toLowerCase();l(a,function(a){if(b)return!1;"Identifier"===a.type&&a.name&&a.name.toLowerCase()===d&&(b=!0);return!0});return b}function f(a,c,b){b=[];if(void 0!==c.params&&null!==c.params)for(var d=0;d<c.params.length;d++)b.push("any");return{name:a,return:"any",params:b}}function n(c,b){b={globalScope:b.globalScope,localScope:{}};for(var d=0;d<c.params.length;d++)b.localScope[c.params[d].name.toLowerCase()]={type:"any"};return a(c.body,b)}function g(a,c,b,d){var f={};if(void 0===
a||null===a)a={};if(void 0===b||null===b)b={};f.infinity={type:"any"};f.textformatting={type:"any"};f.pi={type:"any"};for(var e in c)"sync"===d&&void 0!==c[e].min?f[e]={type:"FormulaFunction",signature:{min:c[e].min,max:c[e].max}}:"sync"!==d&&void 0!==c[e].fmin&&(f[e]={type:"FormulaFunction",signature:{min:c[e].fmin,max:c[e].fmax}});for(c=0;c<b.length;c++)e=b[c],f[e.name]={type:"FormulaFunction",signature:e};for(e in a)f[e]=a[e],f[e].type="any";return f}function q(a,c,b){var d="";switch(c){case "SYNTAX":d=
"Syntax Error: ";break;case "RUNTIME":d="Runtime Error: ";break;default:d="Syntax Error: "}try{switch(a.type){case "IfStatement":switch(b){case "CANNOT_USE_ASSIGNMENT_IN_CONDITION":d+=" Assignments not be made in logical tests";break;case "CANNOT_USE_NONBOOLEAN_IN_CONDITION":d+=" Non Boolean used as Condition"}break;case "UpdateExpression":case "AssignmentExpression":switch(b){case "CANNOT_USE_ASSIGNMENT_IN_CONDITION":d+=" Assignments not be made in logical tests";break;case "ASSIGNMENTTOVARSONLY":d+=
" Assignments can only be made to identifiers"}break;case "ExpressionStatement":d+=" Assignments can only be made to identifiers";break;case "FunctionDeclaration":switch(b){case "GLOBALFUNCTIONSONLY":d+=" Functions cannot be declared as variables";break;case "FUNCTIONMUSTHAVEIDENTIFIER":d+=" Function Definition must have an identifier"}break;case "VariableDeclaration":d+=" Only 1 variable can be declared at a time";break;case "VariableDeclarator":switch(b){case "FUNCTIONVARIABLEDECLARATOR":d+=" Functions cannot be declared as variables";
break;case "VARIABLEMUSTHAVEIDENTIFIER":d+=" Variable Definition must have an identifier"}break;case "Identifier":d+=" Identifier Not Found. ";d+=a.name;break;case "ObjectExpression":switch(b){case "OBJECTPROPERTYMUSTBESTRING":d+=" Property name must be a string"}break;case "ForStatement":switch(b){case "CANNOT_USE_NONBOOLEAN_IN_CONDITION":d+=" Non Boolean used as Condition"}break;case "ForInStatement":switch(b){case "ONLY1VAR":d+=" Can only declare 1 var for use with IN";break;case "CANNOTDECLAREVAL":d+=
" Can only declare value for use with IN";break;case "LEFTNOVAR":d+="Must provide a variable to iterate with.";break;case "VARIABLENOTDECLARED":d+="Variable must be declared before it is used..";break;case "CANNOTITERATETHISTYPE":d+="This type cannot be used in an IN loop"}break;case "MemberExpression":switch(b){case "PROPERTYNOTFOUND":d+="Cannot find member property. ";d+=!1===a.computed?"Identifier"===a.property.type?a.property.name:"":"";break;case "OUTOFBOUNDS":d+="Out of Bounds. ";d+=!1===a.computed?
"Identifier"===a.property.type?a.property.name:"":"";break;case "NOTFOUND":d+="Cannot call member method on null. ";d+=!1===a.computed?"Identifier"===a.property.type?a.property.name:"":"";break;case "INVALIDTYPE":d+="Cannot call member property on object of this type. ",d+=!1===a.computed?"Identifier"===a.property.type?a.property.name:"":""}break;case "Property":switch(b){case "ONLYLITERAL":d+="Property names must be literals or identifiers"}break;case "Literal":break;case "CallExpression":switch(b){case "WRONGSIGNATURE":d+=
"Function signature does not match: ";d+="Identifier"===a.callee.type?a.callee.name:"";break;case "ONLYNODESUPPORTED":d+="Functions must be declared.";d+="Identifier"===a.callee.type?a.callee.name:"";break;case "NOTAFUNCTION":d+="Not a Function: ";d+="Identifier"===a.callee.type?a.callee.name:"";break;case "NOTFOUND":d+="Function Not Found: "+("Identifier"===a.callee.type?a.callee.name:"")}break;case "UnaryExpression":switch(b){case "NOTSUPPORTEDUNARYOPERATOR":d+="Operator "+a.operator+" not allowed in this context. Only ! can be used with boolean, and - with a number";
break;case "NOTSUPPORTEDTYPE":d+="Unary operator "+a.operator+" cannot be used with this argument."}case "BinaryExpression":switch(b){case "OPERATORNOTRECOGNISED":d+="Binary Operator not recognised "+a.operator}break;case "LogicalExpression":switch(b){case "ONLYBOOLEAN":d+="Operator "+a.operator+" cannot be used. Only || or \x26\x26 are allowed values";break;case "ONLYORORAND":d+="Logical Expression "+a.operator+" being applied to parameters that are not boolean."}break;case "ConditionalExpression":d+=
"Conditional statements not supported.";break;case "ArrayExpression":switch(b){case "FUNCTIONCONTEXTILLEGAL":d+=" Cannot Put Function inside Array."}break;default:d+="Expression contains unrecognised code structures."}}catch(F){throw F;}return d}function p(a,c,b){return{line:a.loc.start.line,character:a.loc.start.column,reason:q(a,c,b)}}function t(a,c,b,d,f){void 0===f&&(f=!0);c={globalScope:c.globalScope,localScope:{}};for(f=0;f<a.params.length;f++)c.localScope[a.params[f].name.toLowerCase()]={type:"any"};
r(a.body,c,b,d,!1)}function r(a,c,b,e,g){void 0===g&&(g=!0);if(null===a)throw Error("Unnexpexted Expression Syntax");var h=null;try{switch(a.type){case "VariableDeclarator":if(null!==a.init&&"FunctionExpression"===a.init.type){e.push(p(a,"SYNTAX","FUNCTIONVARIABLEDECLARATOR"));break}"Identifier"!==a.id.type?e.push(p(a,"SYNTAX","VARIABLEMUSTHAVEIDENTIFIER")):(a.id.name.toLowerCase(),null===c.localScope?c.globalScope[a.id.name.toLowerCase()]={type:"any"}:c.localScope[a.id.name.toLowerCase()]={type:"any"});
null!==a.init&&r(a.init,c,b,e,g);break;case "FunctionDeclaration":!1===g&&e.push(p(a,"SYNTAX","GLOBALFUNCTIONSONLY"));"Identifier"!==a.id.type&&e.push(p(a,"SYNTAX","FUNCTIONMUSTHAVEIDENTIFIER"));h=f("",a,c);t(a,c,b,e,g);null!==c.localScope&&e.push(p(a,"SYNTAX","GLOBALFUNCTIONSONLY"));h.isnative=!1;"Identifier"===a.id.type&&(c.globalScope[a.id.name.toLowerCase()]={type:"FormulaFunction",signature:[h]});break;case "VariableDeclaration":for(var n=0;n<a.declarations.length;n++)r(a.declarations[n],c,b,
e,g);break;case "IfStatement":null!==a.test&&(r(a.test,c,b,e,g),"AssignmentExpression"!==a.test.type&&"UpdateExpression"!==a.test.type||e.push(p(a.test,"SYNTAX","CANNOT_USE_ASSIGNMENT_IN_CONDITION")));null!==a.consequent&&r(a.consequent,c,b,e,g);null!==a.alternate&&r(a.alternate,c,b,e,g);break;case "EmptyStatement":break;case "BlockStatement":if(null!==a.body)for(n=0;n<a.body.length;n++)r(a.body[n],c,b,e,g);break;case "ReturnStatement":null!==a.argument&&r(a.argument,c,b,e,g);break;case "ForInStatement":"VariableDeclaration"===
a.left.type?(1<a.left.declarations.length&&e.push(p(a,"SYNTAX","ONLY1VAR")),null!==a.left.declarations[0].init&&e.push(p(a,"SYNTAX","CANNOTDECLAREVAL"))):"Identifier"!==a.left.type&&e.push(p(a,"SYNTAX","LEFTNOTVAR"));r(a.left,c,b,e,g);r(a.right,c,b,e,g);r(a.body,c,b,e,g);break;case "ForStatement":null!==a.init&&r(a.init,c,b,e,g);null!==a.test&&r(a.test,c,b,e,g);null!==a.body&&r(a.body,c,b,e,g);null!==a.update&&r(a.update,c,b,e,g);break;case "BreakStatement":break;case "ContinueStatement":break;case "UpdateExpression":"Identifier"!==
a.argument.type&&"MemberExpression"!==a.argument.type?e.push(p(a,"SYNTAX","ASSIGNMENTTOVARSONLY")):("Identifier"===a.argument.type&&(h=!1,!1===b&&(null!==c.localScope&&void 0!==c.localScope[a.argument.name.toLowerCase()]&&(h=!0),void 0!==c.globalScope[a.argument.name.toLowerCase()]&&(h=!0),!1===h&&e.push({line:null===a?0:a.loc.start.line,character:null===a?0:a.loc.start.column,reason:"Identifier "+a.argument.name+" has not been declared."}))),"MemberExpression"===a.argument.type&&r(a.argument,c,b,
e,g));break;case "AssignmentExpression":"Identifier"!==a.left.type&&"MemberExpression"!==a.left.type&&e.push(p(a,"SYNTAX","ASSIGNMENTTOVARSONLY"));switch(a.operator){case "\x3d":case "/\x3d":case "*\x3d":case "%\x3d":case "+\x3d":case "-\x3d":break;default:e.push(p(a,"SYNTAX","OPERATORNOTRECOGNISED"))}r(a.right,c,b,e,g);h=!1;"Identifier"===a.left.type&&(null!==c.localScope&&void 0!==c.localScope[a.left.name.toLowerCase()]&&(h=!0),void 0!==c.globalScope[a.left.name.toLowerCase()]&&(h=!0),!1===b&&!1===
h&&e.push({line:null===a?0:a.loc.start.line,character:null===a?0:a.loc.start.column,reason:"Identifier "+a.left.name+" has not been declared."}));"MemberExpression"===a.left.type&&r(a.left,c,b,e,g);break;case "ExpressionStatement":r(a.expression,c,b,e,g);break;case "Identifier":var l=a.name.toLowerCase();if(null!==c.localScope&&void 0!==c.localScope[l])break;if(void 0!==c.globalScope[l])break;!1===b&&e.push(p(a,"SYNTAX","VARIABLENOTFOUND"));break;case "MemberExpression":r(a.object,c,b,e,g);!0===a.computed&&
r(a.property,c,b,e,g);break;case "Literal":return"";case "CallExpression":"Identifier"!==a.callee.type&&e.push(p(a,"SYNTAX","ONLYNODESSUPPORTED"));for(n=0;n<a.arguments.length;n++)r(a.arguments[n],c,b,e,g);if("Identifier"===a.callee.type){var k=d(a.callee.name,a.arguments,c);!1===b&&-1===k&&e.push(p(a,"SYNTAX","NOTFOUND"));-2===k&&e.push(p(a,"SYNTAX","WRONGSIGNATURE"))}break;case "UnaryExpression":r(a.argument,c,b,e,g);break;case "BinaryExpression":r(a.left,c,b,e,g);r(a.right,c,b,e,g);switch(a.operator){case "\x3d\x3d":case "!\x3d":case "\x3c":case "\x3c\x3d":case "\x3e":case "\x3e\x3d":case "+":case "-":case "*":case "/":case "%":break;
default:e.push(p(a,"SYNTAX","OPERATORNOTRECOGNISED"))}break;case "LogicalExpression":switch(a.operator){case "\x26\x26":case "||":break;default:e.push(p(a,"SYNTAX","OPERATORNOTRECOGNISED"))}r(a.left,c,b,e,g);"AssignmentExpression"!==a.left.type&&"UpdateExpression"!==a.left.type||e.push(p(a,"SYNTAX","CANNOT_USE_ASSIGNMENT_IN_CONDITION"));r(a.right,c,b,e,g);"AssignmentExpression"!==a.right.type&&"UpdateExpression"!==a.right.type||e.push(p(a,"SYNTAX","CANNOT_USE_ASSIGNMENT_IN_CONDITION"));break;case "ConditionalExpression":e.push(p(a,
"SYNTAX","NOTSUPPORTED"));break;case "ArrayExpression":for(n=0;n<a.elements.length;n++)r(a.elements[n],c,b,e,g);break;case "ObjectExpression":for(n=0;n<a.properties.length;n++)r(a.properties[n],c,b,e,g);break;case "Property":"Literal"!==a.key.type&&"Identifier"!==a.key.type&&e.push(p(a,"SYNTAX","ONLYLITERAL"));"Literal"===a.key.type&&r(a.key,c,b,e,g);r(a.value,c,b,e,g);break;default:e.push(p(a,"SYNTAX","UNRECOGNISED"))}}catch(V){e.push({line:null===a?0:a.loc.start.line,character:null===a?0:a.loc.start.column,
reason:"Unnexpected Syntax"})}}function v(a,c){var b=[];l(a,function(a){"CallExpression"===a.type&&"Identifier"===a.callee.type&&b.push(a.callee.name.toLowerCase());return!0});return b}Object.defineProperty(e,"__esModule",{value:!0});e.functionDecls={concatenate:{min:"0",max:"*"},split:{min:"2",max:"4"},guid:{min:"0",max:"1"},today:{min:"0",max:"0"},urlencode:{min:"1",max:"1"},now:{min:"0",max:"0"},timestamp:{min:"0",max:"0"},day:{min:"1",max:"1"},month:{min:"1",max:"1"},year:{min:"1",max:"1"},hour:{min:"1",
max:"1"},second:{min:"1",max:"1"},millisecond:{min:"1",max:"1"},minute:{min:"1",max:"1"},weekday:{min:"1",max:"1"},toutc:{min:"1",max:"1"},tolocal:{min:"1",max:"1"},date:{min:"0",max:"7"},datediff:{min:"2",max:"3"},dateadd:{min:"2",max:"3"},trim:{min:"1",max:"1"},text:{min:"1",max:"2"},left:{min:"2",max:"2"},right:{min:"2",max:"2"},mid:{min:"2",max:"3"},upper:{min:"1",max:"1"},proper:{min:"1",max:"2"},lower:{min:"1",max:"1"},find:{min:"2",max:"3"},iif:{min:"3",max:"3"},decode:{min:"2",max:"*"},when:{min:"2",
max:"*"},defaultvalue:{min:"2",max:"2"},isempty:{min:"1",max:"1"},domaincode:{min:"2",max:"4"},domainname:{min:"2",max:"4"},polygon:{min:"1",max:"1"},point:{min:"1",max:"1"},polyline:{min:"1",max:"1"},extent:{min:"1",max:"1"},multipoint:{min:"1",max:"1"},ringisclockwise:{min:"1",max:"1"},geometry:{min:"1",max:"1"},count:{min:"0",max:"*"},number:{min:"1",max:"2"},acos:{min:"1",max:"1"},asin:{min:"1",max:"1"},atan:{min:"1",max:"1"},atan2:{min:"2",max:"2"},ceil:{min:"1",max:"2"},floor:{min:"1",max:"2"},
round:{min:"1",max:"2"},cos:{min:"1",max:"1"},exp:{min:"1",max:"1"},log:{min:"1",max:"1"},min:{min:"0",max:"*"},constrain:{min:"3",max:"3"},console:{min:"0",max:"*"},max:{min:"0",max:"*"},pow:{min:"2",max:"2"},random:{min:"0",max:"0"},sqrt:{min:"1",max:"1"},sin:{min:"1",max:"1"},tan:{min:"1",max:"1"},abs:{min:"1",max:"1"},isnan:{min:"1",max:"1"},stdev:{min:"0",max:"*"},average:{min:"0",max:"*"},mean:{min:"0",max:"*"},sum:{min:"0",max:"*"},variance:{min:"0",max:"*"},distinct:{min:"0",max:"*"},first:{min:"1",
max:"1"},top:{min:"2",max:"2"},boolean:{min:"1",max:"1"},dictionary:{min:"0",max:"*"},typeof:{min:"1",max:"1"},reverse:{min:"1",max:"1"},replace:{min:"3",max:"4"},sort:{min:"1",max:"2"},feature:{min:"1",max:"*"},haskey:{min:"2",max:"2"},indexof:{min:"2",max:"2"},disjoint:{min:"2",max:"2"},intersects:{min:"2",max:"2"},touches:{min:"2",max:"2"},crosses:{min:"2",max:"2"},within:{min:"2",max:"2"},contains:{min:"2",max:"2"},overlaps:{min:"2",max:"2"},equals:{min:"2",max:"2"},relate:{min:"3",max:"3"},intersection:{min:"2",
max:"2"},union:{min:"1",max:"2"},difference:{min:"2",max:"2"},symmetricdifference:{min:"2",max:"2"},clip:{min:"2",max:"2"},cut:{min:"2",max:"2"},area:{min:"1",max:"2"},areageodetic:{min:"1",max:"2"},length:{min:"1",max:"2"},lengthgeodetic:{min:"1",max:"2"},distance:{min:"2",max:"3"},densify:{min:"2",max:"3"},densifygeodetic:{min:"2",max:"3"},generalize:{min:"2",max:"4"},buffer:{min:"2",max:"3"},buffergeodetic:{min:"2",max:"3"},offset:{min:"2",max:"6"},rotate:{min:"2",max:"3"},issimple:{min:"1",max:"1"},
simplify:{min:"1",max:"1"},centroid:{min:"1",max:"1"},multiparttosinglepart:{min:"1",max:"1"},setgeometry:{min:"2",max:"2"}};for(var u in e.functionDecls)e.functionDecls[u].fmin=e.functionDecls[u].min,e.functionDecls[u].fmax=e.functionDecls[u].max;var z="featureset featuresetbyid featuresetbyname featuresetbyurl attachments featuresetbyportalitem".split(" "),y="disjoint intersects touches crosses within contains overlaps equals relate intersection union difference symmetricdifference clip cut area areageodetic length lengthgeodetic distance densify densifygeodetic generalize buffer buffergeodetic offset rotate issimple simplify multiparttosinglepart".split(" ");
e.addFunctionDeclaration=function(a,c){var b=e.functionDecls[a.name.toLowerCase()];void 0===b?"sync"===c?e.functionDecls[a.name.toLowerCase()]={min:a.min,max:a.max}:e.functionDecls[a.name.toLowerCase()]={fmin:a.min,fmax:a.max}:"sync"===c?(b.min=a.min,b.max=a.max):(b.fmin=a.min,b.fmax=a.max)};e.checkFunctionSignature=m;e.findFunction=d;e.walk=l;e.validateLanguageNode=h;e.testValidityOfExpression=a;e.referencesMember=c;e.referencesFunction=function(a,c){var b=!1,d=c.toLowerCase();l(a,function(a){return b?
!1:"CallExpression"===a.type&&"Identifier"===a.callee.type&&a.callee.name&&a.callee.name.toLowerCase()===d?(b=!0,!1):!0});return b};e.findFieldLiterals=function(a,c){var b=[];l(a,function(a){if("MemberExpression"!==a.type||"Identifier"!==a.object.type)return!0;!1===a.computed&&a.object&&a.object.name&&a.property&&"Identifier"===a.property.type&&a.property.name?b.push(a.object.name.toLowerCase()+"."+a.property.name.toLowerCase()):a.object&&a.object.name&&a.property&&"Literal"===a.property.type&&"string"===
typeof a.property.value&&b.push(a.object.name.toLowerCase()+"."+a.property.value.toString().toLowerCase());return!1});return b};e.extractFunctionDeclaration=f;e.validateFunction=n;e.constructGlobalScope=g;e.validateScript=function(c,b,d,f){void 0===d&&(d="async");void 0===f&&(f=e.functionDecls);b={globalScope:g(b.vars,f,b.customFunctions,d),localScope:null};return a(c.body[0].body,b)};e.validateLanguage=function(a){return"BlockStatement"!==a.body[0].body.type?"Invalid formula content.":h(a.body[0].body)};
e.nodeErrorMessage=q;e.makeError=p;e.extractAllIssuesInFunction=t;e.extractAllIssues=r;e.checkScript=function(a,c,b,d,f){void 0===d&&(d="async");void 0===f&&(f=e.functionDecls);var h=[];if("BlockStatement"!==a.body[0].body.type)return[{line:0,character:0,reason:"Invalid Body"}];if(null===c||void 0===c)c={vars:{},customFunctions:[]};c={globalScope:g(c.vars,f,c.customFunctions,d),localScope:null};try{r(a.body[0].body,c,b,h)}catch(E){}return h};e.findFunctionCalls=v;e.findScriptDependencies=function(a,
b){void 0===b&&(b=[]);var d=null;if(void 0===a.usesFeatureSet){null===d&&(d=v(a,!1));a.usesFeatureSet=!1;for(var f=0;f<d.length;f++)-1<z.indexOf(d[f])&&(a.usesFeatureSet=!0,a.isAsync=!0);if(!1===a.usesFeatureSet&&b&&0<b.length)for(f=0;f<b.length;f++)if(c(a,b[f])){a.usesFeatureSet=!0;a.isAsync=!0;break}}void 0===a.isAsync&&(a.isAsync=!1);if(void 0===a.usesGeometry)for(a.usesGeometry=!1,null===d&&(d=v(a,!1)),f=0;f<d.length;f++)-1<y.indexOf(d[f])&&(a.usesGeometry=!0)};e.scriptUsesFeatureSet=function(a){a=
v(a,!1);for(var c=0;c<a.length;c++)if(-1<z.indexOf(a[c]))return!0;return!1}})},"esri/arcade/functions/date":function(){define(["require","exports","../../moment","../languageUtils"],function(b,e,m,d){function k(b){return null===b?b:isNaN(b.getTime())?null:b}Object.defineProperty(e,"__esModule",{value:!0});e.registerFunctions=function(b,e){b.today=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,0,0);a=new Date;a.setHours(0,0,0,0);return a})};b.now=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,
0,0);return new Date})};b.timestamp=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,0,0);a=new Date;return a=new Date(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate(),a.getUTCHours(),a.getUTCMinutes(),a.getUTCSeconds(),a.getUTCMilliseconds())})};b.toutc=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?null:new Date(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate(),a.getUTCHours(),a.getUTCMinutes(),a.getUTCSeconds(),a.getUTCMilliseconds())})};b.tolocal=
function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?null:m.utc([a.getFullYear(),a.getMonth(),a.getDate(),a.getHours(),a.getMinutes(),a.getSeconds(),a.getMilliseconds()]).toDate()})};b.day=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?NaN:a.getDate()})};b.month=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?NaN:a.getMonth()})};b.year=function(a,c){return e(a,c,function(a,
c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?NaN:a.getFullYear()})};b.hour=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?NaN:a.getHours()})};b.second=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?NaN:a.getSeconds()})};b.millisecond=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?NaN:a.getMilliseconds()})};b.minute=function(a,c){return e(a,c,function(a,
c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?NaN:a.getMinutes()})};b.weekday=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,1,1);a=d.toDate(b[0]);return null===a?NaN:a.getDay()})};b.date=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,0,7);if(3===b.length)return k(new Date(d.toNumber(b[0]),d.toNumber(b[1]),d.toNumber(b[2]),0,0,0,0));if(4===b.length)return k(new Date(d.toNumber(b[0]),d.toNumber(b[1]),d.toNumber(b[2]),d.toNumber(b[3]),0,0,0));if(5===b.length)return k(new Date(d.toNumber(b[0]),
d.toNumber(b[1]),d.toNumber(b[2]),d.toNumber(b[3]),d.toNumber(b[4]),0,0));if(6===b.length)return k(new Date(d.toNumber(b[0]),d.toNumber(b[1]),d.toNumber(b[2]),d.toNumber(b[3]),d.toNumber(b[4]),d.toNumber(b[5]),0));if(7===b.length)return k(new Date(d.toNumber(b[0]),d.toNumber(b[1]),d.toNumber(b[2]),d.toNumber(b[3]),d.toNumber(b[4]),d.toNumber(b[5]),d.toNumber(b[6])));if(2===b.length){a=d.toString(b[1]);if(""===a)return null;a=d.standardiseDateFormat(a);b=m(d.toString(b[0]),a,!0);return!0===b.isValid()?
b.toDate():null}if(1===b.length){if(d.isString(b[0])&&""===b[0].replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""))return null;a=d.toNumber(b[0]);return!1===isNaN(a)?k(new Date(a)):d.toDate(b[0])}if(0===b.length)return new Date})};b.datediff=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,2,3);a=d.toDateM(b[0]);c=d.toDateM(b[1]);if(null===a||null===c)return NaN;switch(d.toString(b[2]).toLowerCase()){case "days":case "day":case "d":return a.diff(c,"days",!0);case "months":case "month":return a.diff(c,
"months",!0);case "minutes":case "minute":case "m":return"M"===b[2]?a.diff(c,"months",!0):a.diff(c,"minutes",!0);case "seconds":case "second":case "s":return a.diff(c,"seconds",!0);case "milliseconds":case "millisecond":case "ms":return a.diff(c);case "hours":case "hour":case "h":return a.diff(c,"hours",!0);case "years":case "year":case "y":return a.diff(c,"years",!0);default:return a.diff(c)}})};b.dateadd=function(a,c){return e(a,c,function(a,c,b){d.pcCheck(b,2,3);a=d.toDateM(b[0]);if(null===a)return null;
c="milliseconds";switch(d.toString(b[2]).toLowerCase()){case "days":case "day":case "d":c="days";break;case "months":case "month":c="months";break;case "minutes":case "minute":case "m":c="M"===b[2]?"months":"minutes";break;case "seconds":case "second":case "s":c="seconds";break;case "milliseconds":case "millisecond":case "ms":c="milliseconds";break;case "hours":case "hour":case "h":c="hours";break;case "years":case "year":case "y":c="years"}a.add(d.toNumber(b[1]),c);return a.toDate()})}}})},"esri/arcade/functions/geometry":function(){define("require exports ../Dictionary ../Feature ../ImmutablePointArray ../languageUtils ../../geometry/Extent ../../geometry/Geometry ../../geometry/Multipoint ../../geometry/Point ../../geometry/Polygon ../../geometry/Polyline ../../geometry/support/jsonUtils ../../geometry/support/coordsUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p){Object.defineProperty(e,"__esModule",{value:!0});e.registerFunctions=function(b,e){b.ringisclockwise=function(a,c){return e(a,c,function(a,c,b){l.pcCheck(b,1,1);a=[];var d=c=!1;if(null===b[0])return!1;if(l.isArray(b[0])){for(var e=0,g=b[0];e<g.length;e++){var h=g[e];if(h instanceof f)a.push(h.hasZ?h.hasM?[h.x,h.y,h.z,h.m]:[h.x,h.y,h.z]:[h.x,h.y]);else throw Error("Invalid Argument");}0<a.length&&(c=b[0][0].hasZ,d=b[0][0].hasM)}else if(b[0]instanceof k)a=b[0]._elements,
0<a.length&&(c=b[0]._hasZ,d=b[0]._hasM);else if(l.isImmutableArray(b[0])){e=0;for(g=b[0].toArray();e<g.length;e++)if(h=g[e],h instanceof f)a.push(h.hasZ?h.hasM?[h.x,h.y,h.z,h.m]:[h.x,h.y,h.z]:[h.x,h.y]);else throw Error("Invalid Argument");0<a.length&&(c=b[0].get(0).hasZ,d=b[0].get(0).hasM)}else throw Error("Invalid Argument");return 3>a.length?!1:p.isClockwise(a,d,c)})};b.polygon=function(a,c){return e(a,c,function(c,b,f){l.pcCheck(f,1,1);c=null;if(f[0]instanceof m){if(c=l.fixSpatialReference(d.parseGeometryFromDictionary(f[0]),
a.spatialReference),!1===c instanceof n)throw Error("Illegal Parameter");}else c=f[0]instanceof n?q.fromJSON(f[0].toJSON()):l.fixSpatialReference(new n(JSON.parse(f[0])),a.spatialReference);if(null!==c&&!1===c.spatialReference.equals(a.spatialReference))throw Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l.fixNullGeometry(c)})};b.polyline=function(a,c){return e(a,c,function(c,b,f){l.pcCheck(f,1,1);c=null;if(f[0]instanceof m){if(c=l.fixSpatialReference(d.parseGeometryFromDictionary(f[0]),
a.spatialReference),!1===c instanceof g)throw Error("Illegal Parameter");}else c=f[0]instanceof g?q.fromJSON(f[0].toJSON()):l.fixSpatialReference(new g(JSON.parse(f[0])),a.spatialReference);if(null!==c&&!1===c.spatialReference.equals(a.spatialReference))throw Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l.fixNullGeometry(c)})};b.point=function(a,c){return e(a,c,function(c,b,e){l.pcCheck(e,1,1);c=null;if(e[0]instanceof m){if(c=l.fixSpatialReference(d.parseGeometryFromDictionary(e[0]),
a.spatialReference),!1===c instanceof f)throw Error("Illegal Parameter");}else c=e[0]instanceof f?q.fromJSON(e[0].toJSON()):l.fixSpatialReference(new f(JSON.parse(e[0])),a.spatialReference);if(null!==c&&!1===c.spatialReference.equals(a.spatialReference))throw Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l.fixNullGeometry(c)})};b.multipoint=function(a,b){return e(a,b,function(b,f,e){l.pcCheck(e,1,1);b=null;if(e[0]instanceof m){if(b=
l.fixSpatialReference(d.parseGeometryFromDictionary(e[0]),a.spatialReference),!1===b instanceof c)throw Error("Illegal Parameter");}else b=e[0]instanceof c?q.fromJSON(e[0].toJSON()):l.fixSpatialReference(new c(JSON.parse(e[0])),a.spatialReference);if(null!==b&&!1===b.spatialReference.equals(a.spatialReference))throw Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l.fixNullGeometry(b)})};b.extent=function(a,b){return e(a,b,function(b,
e,p){p=l.autoCastFeatureToGeometry(p);l.pcCheck(p,1,1);b=null;p[0]instanceof m?b=l.fixSpatialReference(d.parseGeometryFromDictionary(p[0]),a.spatialReference):p[0]instanceof f?(b={xmin:p[0].x,ymin:p[0].y,xmax:p[0].x,ymax:p[0].y,spatialReference:p[0].spatialReference.toJSON()},p[0].hasZ?(b.zmin=p[0].z,b.zmax=p[0].z):p[0].hasM&&(b.mmin=p[0].m,b.mmax=p[0].m),b=q.fromJSON(b)):b=p[0]instanceof n?q.fromJSON(p[0].extent.toJSON()):p[0]instanceof g?q.fromJSON(p[0].extent.toJSON()):p[0]instanceof c?q.fromJSON(p[0].extent.toJSON()):
p[0]instanceof h?q.fromJSON(p[0].toJSON()):l.fixSpatialReference(new h(JSON.parse(p[0])),a.spatialReference);if(null!==b&&!1===b.spatialReference.equals(a.spatialReference))throw Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l.fixNullGeometry(b)})};b.geometry=function(a,c){return e(a,c,function(c,b,f){l.pcCheck(f,1,1);c=null;c=f[0]instanceof d?l.fixSpatialReference(f[0].geometry(),a.spatialReference):f[0]instanceof m?l.fixSpatialReference(d.parseGeometryFromDictionary(f[0]),
a.spatialReference):l.fixSpatialReference(q.fromJSON(JSON.parse(f[0])),a.spatialReference);if(null!==c&&!1===c.spatialReference.equals(a.spatialReference))throw Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l.fixNullGeometry(c)})};b.setgeometry=function(c,b){return e(c,b,function(c,b,f){l.pcCheck(f,2,2);if(f[0]instanceof d){if(!0===f[0].immutable)throw Error("Feature is Immutable");if(f[1]instanceof a||null===f[1])f[0]._geometry=f[1];
else throw Error("Illegal Argument");}else throw Error("Illegal Argument");return l.voidOperation})};b.feature=function(c,b){return e(c,b,function(b,f,e){if(0===e.length)throw Error("Missing Parameters");b=null;if(1===e.length)if(l.isString(e[0]))b=d.fromJson(JSON.parse(e[0]));else if(e[0]instanceof d)b=d.createFromArcadeFeature(e[0]);else if(e[0]instanceof a)b=d.createFromGraphicLikeObject(e[0],null,null);else if(e[0]instanceof m)b=e[0].hasField("geometry")?e[0].field("geometry"):null,f=e[0].hasField("attributes")?
e[0].field("attributes"):null,null!==b&&b instanceof m&&(b=d.parseGeometryFromDictionary(b)),null!==f&&(f=d.parseAttributesFromDictionary(f)),b=d.createFromGraphicLikeObject(b,f,null);else throw Error("Illegal Argument");else{if(2===e.length){f=b=null;if(null!==e[0])if(e[0]instanceof a)b=e[0];else if(b instanceof m)b=d.parseGeometryFromDictionary(e[0]);else throw Error("Illegal Argument");if(null!==e[1])if(e[1]instanceof m)f=d.parseAttributesFromDictionary(e[1]);else throw Error("Illegal Argument");
}else{b=null;f={};if(null!==e[0])if(e[0]instanceof a)b=e[0];else if(b instanceof m)b=d.parseGeometryFromDictionary(e[0]);else throw Error("Illegal Argument");for(var g=1;g<e.length;g+=2){var h=l.toString(e[g]),p=e[g+1];if(null===p||void 0===p||l.isString(p)||isNaN(p)||l.isDate(p)||l.isNumber(p)||l.isBoolean(p)){if(l.isFunctionParameter(p)||!1===l.isSimpleType(p))throw Error("Illegal Argument");f[h]=p===l.voidOperation?null:p}else throw Error("Illegal Argument");}}b=d.createFromGraphicLikeObject(b,
f,null)}b._geometry=l.fixSpatialReference(b.geometry(),c.spatialReference);b.immutable=!1;return b})};b.dictionary=function(a,c){return e(a,c,function(a,c,b){if(0===b.length)throw Error("Missing Parameters");if(0!==b.length%2)throw Error("Missing Parameters");a={};for(c=0;c<b.length;c+=2){var d=l.toString(b[c]),f=b[c+1];if(null===f||void 0===f||l.isString(f)||isNaN(f)||l.isDate(f)||l.isNumber(f)||l.isBoolean(f)||l.isArray(f)||l.isImmutableArray(f)){if(l.isFunctionParameter(f))throw Error("Illegal Argument");
a[d]=f===l.voidOperation?null:f}else throw Error("Illegal Argument");}b=new m(a);b.immutable=!1;return b})};b.haskey=function(a,c){return e(a,c,function(a,c,b){l.pcCheck(b,2,2);a=l.toString(b[1]);if(b[0]instanceof d||b[0]instanceof m)return b[0].hasField(a);throw Error("Illegal Argument");})};b.indexof=function(a,c){return e(a,c,function(a,c,b){l.pcCheck(b,2,2);a=b[1];if(l.isArray(b[0])){for(c=0;c<b[0].length;c++)if(l.equalityTest(a,b[0][c]))return c;return-1}if(l.isImmutableArray(b[0])){var d=b[0].length();
for(c=0;c<d;c++)if(l.equalityTest(a,b[0].get(c)))return c;return-1}throw Error("Illegal Argument");})}}})},"esri/arcade/functions/geomsync":function(){define("require exports ../../kernel ../kernel ../languageUtils ../featureset/support/shared ./centroid ../../geometry/Extent ../../geometry/Geometry ../../geometry/Multipoint ../../geometry/Point ../../geometry/Polygon ../../geometry/Polyline ../../geometry/support/jsonUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g,q,p){function t(a){return 0===
m.version.indexOf("4.")?g.fromExtent(a):new g({spatialReference:a.spatialReference,rings:[[[a.xmin,a.ymin],[a.xmin,a.ymax],[a.xmax,a.ymax],[a.xmax,a.ymin],[a.xmin,a.ymin]]]})}Object.defineProperty(e,"__esModule",{value:!0});var r=null;e.setGeometryEngine=function(a){r=a};e.registerFunctions=function(b,e){function m(a){k.pcCheck(a,2,2);if(!(a[0]instanceof c&&a[1]instanceof c||a[0]instanceof c&&null===a[1]||a[1]instanceof c&&null===a[0]||null===a[0]&&null===a[1]))throw Error("Illegal Argument");}b.disjoint=
function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null===b[0]||null===b[1]?!0:r.disjoint(b[0],b[1])})};b.intersects=function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null===b[0]||null===b[1]?!1:r.intersects(b[0],b[1])})};b.touches=function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null===b[0]||null===b[1]?!1:r.touches(b[0],b[1])})};b.crosses=function(a,c){return e(a,c,function(a,c,b){b=
k.autoCastFeatureToGeometry(b);m(b);return null===b[0]||null===b[1]?!1:r.crosses(b[0],b[1])})};b.within=function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null===b[0]||null===b[1]?!1:r.within(b[0],b[1])})};b.contains=function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null===b[0]||null===b[1]?!1:r.contains(b[0],b[1])})};b.overlaps=function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null===
b[0]||null===b[1]?!1:r.overlaps(b[0],b[1])})};b.equals=function(a,b){return e(a,b,function(a,b,d){k.pcCheck(d,2,2);return d[0]===d[1]?!0:d[0]instanceof c&&d[1]instanceof c?r.equals(d[0],d[1]):k.isDate(d[0])&&k.isDate(d[1])?d[0].getTime()===d[1].getTime():!1})};b.relate=function(a,b){return e(a,b,function(a,b,d){d=k.autoCastFeatureToGeometry(d);k.pcCheck(d,3,3);if(d[0]instanceof c&&d[1]instanceof c)return r.relate(d[0],d[1],k.toString(d[2]));if(d[0]instanceof c&&null===d[1]||d[1]instanceof c&&null===
d[0]||null===d[0]&&null===d[1])return!1;throw Error("Illegal Argument");})};b.intersection=function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null===b[0]||null===b[1]?null:r.intersect(b[0],b[1])})};b.union=function(a,b){return e(a,b,function(b,d,f){f=k.autoCastFeatureToGeometry(f);b=[];if(0===f.length)throw Error("Function called with wrong number of Parameters");if(1===f.length)if(k.isArray(f[0]))for(f=k.autoCastFeatureToGeometry(f[0]),d=0;d<f.length;d++){if(null!==
f[d]){if(!(f[d]instanceof c))throw Error("Illegal Argument");b.push(f[d])}}else if(k.isImmutableArray(f[0]))for(f=k.autoCastFeatureToGeometry(f[0].toArray()),d=0;d<f.length;d++){if(null!==f[d]){if(!(f[d]instanceof c))throw Error("Illegal Argument");b.push(f[d])}}else{if(f[0]instanceof c)return k.fixSpatialReference(l.cloneGeometry(f[0]),a.spatialReference);if(null===f[0])return null;throw Error("Illegal Argument");}else for(d=0;d<f.length;d++)if(null!==f[d]){if(!(f[d]instanceof c))throw Error("Illegal Argument");
b.push(f[d])}return 0===b.length?null:r.union(b)})};b.difference=function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null!==b[0]&&null===b[1]?l.cloneGeometry(b[0]):null===b[0]?null:r.difference(b[0],b[1])})};b.symmetricdifference=function(a,c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);m(b);return null===b[0]&&null===b[1]?null:null===b[0]?l.cloneGeometry(b[1]):null===b[1]?l.cloneGeometry(b[0]):r.symmetricDifference(b[0],b[1])})};b.clip=function(b,
d){return e(b,d,function(b,d,f){f=k.autoCastFeatureToGeometry(f);k.pcCheck(f,2,2);if(!(f[1]instanceof a)&&null!==f[1])throw Error("Illegal Argument");if(null===f[0])return null;if(!(f[0]instanceof c))throw Error("Illegal Argument");return null===f[1]?null:r.clip(f[0],f[1])})};b.cut=function(a,b){return e(a,b,function(a,b,d){d=k.autoCastFeatureToGeometry(d);k.pcCheck(d,2,2);if(!(d[1]instanceof q)&&null!==d[1])throw Error("Illegal Argument");if(null===d[0])return[];if(!(d[0]instanceof c))throw Error("Illegal Argument");
return null===d[1]?[l.cloneGeometry(d[0])]:r.cut(d[0],d[1])})};b.area=function(a,b){return e(a,b,function(b,f,e){k.pcCheck(e,1,2);e=k.autoCastFeatureToGeometry(e);if(null===e[0])return 0;if(k.isArray(e[0])||k.isImmutableArray(e[0]))return b=k.autoCastArrayOfPointsToPolygon(e[0],a.spatialReference),null===b?0:r.planarArea(b,d.convertSquareUnitsToCode(k.defaultUndefined(e[1],-1)));if(!(e[0]instanceof c))throw Error("Illegal Argument");return r.planarArea(e[0],d.convertSquareUnitsToCode(k.defaultUndefined(e[1],
-1)))})};b.areageodetic=function(a,b){return e(a,b,function(b,f,e){k.pcCheck(e,1,2);e=k.autoCastFeatureToGeometry(e);if(null===e[0])return 0;if(k.isArray(e[0])||k.isImmutableArray(e[0]))return b=k.autoCastArrayOfPointsToPolygon(e[0],a.spatialReference),null===b?0:r.geodesicArea(b,d.convertSquareUnitsToCode(k.defaultUndefined(e[1],-1)));if(!(e[0]instanceof c))throw Error("Illegal Argument");return r.geodesicArea(e[0],d.convertSquareUnitsToCode(k.defaultUndefined(e[1],-1)))})};b.length=function(a,b){return e(a,
b,function(b,f,e){k.pcCheck(e,1,2);e=k.autoCastFeatureToGeometry(e);if(null===e[0])return 0;if(k.isArray(e[0])||k.isImmutableArray(e[0]))return b=k.autoCastArrayOfPointsToPolyline(e[0],a.spatialReference),null===b?0:r.planarLength(b,d.convertLinearUnitsToCode(k.defaultUndefined(e[1],-1)));if(!(e[0]instanceof c))throw Error("Illegal Argument");return r.planarLength(e[0],d.convertLinearUnitsToCode(k.defaultUndefined(e[1],-1)))})};b.lengthgeodetic=function(a,b){return e(a,b,function(b,f,e){k.pcCheck(e,
1,2);e=k.autoCastFeatureToGeometry(e);if(null===e[0])return 0;if(k.isArray(e[0])||k.isImmutableArray(e[0]))return b=k.autoCastArrayOfPointsToPolyline(e[0],a.spatialReference),null===b?0:r.geodesicLength(b,d.convertLinearUnitsToCode(k.defaultUndefined(e[1],-1)));if(!(e[0]instanceof c))throw Error("Illegal Argument");return r.geodesicLength(e[0],d.convertLinearUnitsToCode(k.defaultUndefined(e[1],-1)))})};b.distance=function(a,b){return e(a,b,function(b,f,e){e=k.autoCastFeatureToGeometry(e);k.pcCheck(e,
2,3);b=e[0];if(k.isArray(e[0])||k.isImmutableArray(e[0]))b=k.autoCastArrayOfPointsToMultiPoint(e[0],a.spatialReference);f=e[1];if(k.isArray(e[1])||k.isImmutableArray(e[1]))f=k.autoCastArrayOfPointsToMultiPoint(e[1],a.spatialReference);if(!(b instanceof c))throw Error("Illegal Argument");if(!(f instanceof c))throw Error("Illegal Argument");return r.distance(b,f,d.convertLinearUnitsToCode(k.defaultUndefined(e[2],-1)))})};b.densify=function(b,f){return e(b,f,function(b,f,e){e=k.autoCastFeatureToGeometry(e);
k.pcCheck(e,2,3);if(null===e[0])return null;if(!(e[0]instanceof c))throw Error("Illegal Argument");b=k.toNumber(e[1]);if(isNaN(b))throw Error("Illegal Argument");if(0>=b)throw Error("Illegal Argument");return e[0]instanceof g||e[0]instanceof q?r.densify(e[0],b,d.convertLinearUnitsToCode(k.defaultUndefined(e[2],-1))):e[0]instanceof a?r.densify(t(e[0]),b,d.convertLinearUnitsToCode(k.defaultUndefined(e[2],-1))):e[0]})};b.densifygeodetic=function(b,f){return e(b,f,function(b,f,e){e=k.autoCastFeatureToGeometry(e);
k.pcCheck(e,2,3);if(null===e[0])return null;if(!(e[0]instanceof c))throw Error("Illegal Argument");b=k.toNumber(e[1]);if(isNaN(b))throw Error("Illegal Argument");if(0>=b)throw Error("Illegal Argument");return e[0]instanceof g||e[0]instanceof q?r.geodesicDensify(e[0],b,d.convertLinearUnitsToCode(k.defaultUndefined(e[2],-1))):e[0]instanceof a?r.geodesicDensify(t(e[0]),b,d.convertLinearUnitsToCode(k.defaultUndefined(e[2],-1))):e[0]})};b.generalize=function(a,b){return e(a,b,function(a,b,f){f=k.autoCastFeatureToGeometry(f);
k.pcCheck(f,2,4);if(null===f[0])return null;if(!(f[0]instanceof c))throw Error("Illegal Argument");a=k.toNumber(f[1]);if(isNaN(a))throw Error("Illegal Argument");return r.generalize(f[0],a,k.toBoolean(k.defaultUndefined(f[2],!0)),d.convertLinearUnitsToCode(k.defaultUndefined(f[3],-1)))})};b.buffer=function(a,b){return e(a,b,function(a,b,f){f=k.autoCastFeatureToGeometry(f);k.pcCheck(f,2,3);if(null===f[0])return null;if(!(f[0]instanceof c))throw Error("Illegal Argument");a=k.toNumber(f[1]);if(isNaN(a))throw Error("Illegal Argument");
return 0===a?l.cloneGeometry(f[0]):r.buffer(f[0],a,d.convertLinearUnitsToCode(k.defaultUndefined(f[2],-1)))})};b.buffergeodetic=function(a,b){return e(a,b,function(a,b,f){f=k.autoCastFeatureToGeometry(f);k.pcCheck(f,2,3);if(null===f[0])return null;if(!(f[0]instanceof c))throw Error("Illegal Argument");a=k.toNumber(f[1]);if(isNaN(a))throw Error("Illegal Argument");return 0===a?l.cloneGeometry(f[0]):r.geodesicBuffer(f[0],a,d.convertLinearUnitsToCode(k.defaultUndefined(f[2],-1)))})};b.offset=function(a,
c){return e(a,c,function(a,c,b){b=k.autoCastFeatureToGeometry(b);k.pcCheck(b,2,6);if(null===b[0])return null;if(!(b[0]instanceof g||b[0]instanceof q))throw Error("Illegal Argument");a=k.toNumber(b[1]);if(isNaN(a))throw Error("Illegal Argument");c=k.toNumber(k.defaultUndefined(b[4],10));if(isNaN(c))throw Error("Illegal Argument");var f=k.toNumber(k.defaultUndefined(b[5],0));if(isNaN(f))throw Error("Illegal Argument");return r.offset(b[0],a,d.convertLinearUnitsToCode(k.defaultUndefined(b[2],-1)),k.toString(k.defaultUndefined(b[3],
"round")).toLowerCase(),c,f)})};b.rotate=function(b,d){return e(b,d,function(b,d,f){f=k.autoCastFeatureToGeometry(f);k.pcCheck(f,2,3);b=f[0];if(null===b)return null;if(!(b instanceof c))throw Error("Illegal Argument");b instanceof a&&(b=g.fromExtent(b));d=k.toNumber(f[1]);if(isNaN(d))throw Error("Illegal Argument");f=k.defaultUndefined(f[2],null);if(null===f)return r.rotate(b,d);if(f instanceof n)return r.rotate(b,d,f);throw Error("Illegal Argument");})};b.centroid=function(b,d){return e(b,d,function(d,
e,p){p=k.autoCastFeatureToGeometry(p);k.pcCheck(p,1,1);if(null===p[0])return null;d=p[0];if(k.isArray(p[0])||k.isImmutableArray(p[0]))d=k.autoCastArrayOfPointsToMultiPoint(p[0],b.spatialReference);if(null===d)return null;if(!(d instanceof c))throw Error("Illegal Argument");return d instanceof n?k.fixSpatialReference(l.cloneGeometry(p[0]),b.spatialReference):d instanceof g?d.centroid:d instanceof q?h.centroidPolyline(d):d instanceof f?h.centroidMultiPoint(d):d instanceof a?d.center:null})};b.multiparttosinglepart=
function(b,d){return e(b,d,function(d,e,h){h=k.autoCastFeatureToGeometry(h);k.pcCheck(h,1,1);e=[];if(null===h[0])return null;if(!(h[0]instanceof c))throw Error("Illegal Argument");if(h[0]instanceof n||h[0]instanceof a)return[k.fixSpatialReference(l.cloneGeometry(h[0]),b.spatialReference)];d=r.simplify(h[0]);if(d instanceof g){e=[];var m=[];for(h=0;h<d.rings.length;h++)if(d.isClockwise(d.rings[h])){var t=p.fromJSON({rings:[d.rings[h]],hasZ:!0===d.hasZ,hasM:!0===d.hasM,spatialReference:d.spatialReference.toJSON()});
e.push(t)}else m.push({ring:d.rings[h],pt:d.getPoint(h,0)});for(d=0;d<m.length;d++)for(h=0;h<e.length;h++)if(e[h].contains(m[d].pt)){e[h].addRing(m[d].ring);break}return e}if(d instanceof q){e=[];for(h=0;h<d.paths.length;h++)m=p.fromJSON({paths:[d.paths[h]],hasZ:!0===d.hasZ,hasM:!0===d.hasM,spatialReference:d.spatialReference.toJSON()}),e.push(m);return e}if(h[0]instanceof f){d=k.fixSpatialReference(l.cloneGeometry(h[0]),b.spatialReference);for(h=0;h<d.points.length;h++)e.push(d.getPoint(h));return e}return null})};
b.issimple=function(a,b){return e(a,b,function(a,b,d){d=k.autoCastFeatureToGeometry(d);k.pcCheck(d,1,1);if(null===d[0])return!0;if(!(d[0]instanceof c))throw Error("Illegal Argument");return r.isSimple(d[0])})};b.simplify=function(a,b){return e(a,b,function(a,b,d){d=k.autoCastFeatureToGeometry(d);k.pcCheck(d,1,1);if(null===d[0])return null;if(!(d[0]instanceof c))throw Error("Illegal Argument");return r.simplify(d[0])})}}})},"esri/arcade/kernel":function(){define(["require","exports","../geometry/Extent"],
function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.convertSquareUnitsToCode=function(b){if(void 0===b)return null;if("number"===typeof b)return b;switch(b.toLowerCase()){case "meters":case "meter":case "m":case "squaremeters":case "squaremeter":case "square-meter":case "square_meters":return 109404;case "miles":case "mile":case "squaremile":case "squaremiles":case "square-miles":case "square-mile":return 109413;case "kilometers":case "kilometer":case "squarekilometers":case "squarekilometer":case "square-kilometers":case "square-kilometer":case "km":return 109414;
case "acres":case "acre":case "ac":return 109402;case "hectares":case "hectare":case "ha":return 109401;case "yard":case "yd":case "yards":case "square-yards":case "square-yard":case "squareyards":case "squareyard":return 109442;case "feet":case "ft":case "foot":case "square-feet":case "square-foot":case "squarefeet":case "squarefoot":return 109405}return null};e.shapeExtent=function(b){if(null===b)return null;switch(b.type){case "polygon":case "multipoint":case "polyline":return b.extent;case "point":return new m({xmin:b.x,
ymin:b.y,xmax:b.x,ymax:b.y,spatialReference:b.spatialReference});case "extent":return b}return null};e.convertLinearUnitsToCode=function(b){if(void 0===b)return null;if("number"===typeof b||"number"===typeof b)return b;switch(b.toLowerCase()){case "meters":case "meter":case "m":case "squaremeters":case "squaremeter":case "square-meter":case "square-meters":return 9001;case "miles":case "mile":case "squaremile":case "squaremiles":case "square-miles":case "square-mile":return 9035;case "kilometers":case "kilometer":case "squarekilometers":case "squarekilometer":case "square-kilometers":case "square-kilometer":case "km":return 9036;
case "yard":case "yd":case "yards":case "square-yards":case "square-yard":case "squareyards":case "squareyard":return 9096;case "feet":case "ft":case "foot":case "square-feet":case "square-foot":case "squarefeet":case "squarefoot":return 9002}return null};e.sameGeomType=function(b,e){return b===e||"point"===b&&"esriGeometryPoint"===e||"polyline"===b&&"esriGeometryPolyline"===e||"polygon"===b&&"esriGeometryPolygon"===e||"extent"===b&&"esriGeometryEnvelope"===e||"multipoint"===b&&"esriGeometryMultipoint"===
e||"point"===e&&"esriGeometryPoint"===b||"polyline"===e&&"esriGeometryPolyline"===b||"polygon"===e&&"esriGeometryPolygon"===b||"extent"===e&&"esriGeometryEnvelope"===b||"multipoint"===e&&"esriGeometryMultipoint"===b?!0:!1}})},"esri/arcade/featureset/support/shared":function(){define(["require","exports","../../../core/promiseUtils","../../../geometry/Extent","../../../layers/support/Field"],function(b,e,m,d,k){function l(b){return b instanceof Date}Object.defineProperty(e,"__esModule",{value:!0});
(function(b){b[b.Standardised=0]="Standardised";b[b.SqlServer=1]="SqlServer";b[b.Oracle=2]="Oracle";b[b.Postgres=3]="Postgres";b[b.PGDB=4]="PGDB";b[b.FILEGDB=5]="FILEGDB";b[b.NotEvaluated=6]="NotEvaluated"})(e.FeatureServiceDatabaseType||(e.FeatureServiceDatabaseType={}));e.cloneField=function(b){return k.fromJSON(b.toJSON())};e.esriFieldToJson=function(b){return b.toJSON()};e.cloneGeometry=function(b){if(null===b)return null;var a=b.clone();void 0!==b.cache._geVersion&&(a.cache._geVersion=b.cache._geVersion);
return a};(function(b){b[b.InFeatureSet=0]="InFeatureSet";b[b.NotInFeatureSet=1]="NotInFeatureSet";b[b.Unknown=2]="Unknown"})(e.IdState||(e.IdState={}));e.isString=function(b){return"string"===typeof b||b instanceof String};e.isBoolean=function(b){return"boolean"===typeof b};e.isNumber=function(b){return"number"===typeof b};e.isArray=function(b){return b instanceof Array};e.isDate=l;e.equalityTest=function(b,a){return b===a?!0:l(b)&&l(a)?b.getTime()===a.getTime():!1};e.cloneAttributes=function(b){var a=
{},c;for(c in b)a[c]=b[c];return a};e.convertSquareUnitsToCode=function(b){if(void 0===b)return null;if("number"===typeof b)return b;switch(b.toLowerCase()){case "meters":case "meter":return 109404;case "miles":case "mile":return 109413;case "kilometers":case "kilometer":case "km":return 109414}return null};e.shapeExtent=function(b){if(null===b)return null;switch(b.type){case "polygon":case "multipoint":case "polyline":return b.extent;case "point":return new d({xmin:b.x,ymin:b.y,xmax:b.x,ymax:b.y,
spatialReference:b.spatialReference});case "extent":return b}return null};e.convertLinearUnitsToCode=function(b){if(void 0===b)return null;if("number"===typeof b||"number"===typeof b)return b;switch(b.toLowerCase()){case "meters":case "meter":return 9001;case "miles":case "mile":return 9035;case "kilometers":case "kilometer":case "km":return 9036}return null};e.sameGeomType=function(b,a){return b===a||"point"===b&&"esriGeometryPoint"===a||"polyline"===b&&"esriGeometryPolyline"===a||"polygon"===b&&
"esriGeometryPolygon"===a||"extent"===b&&"esriGeometryEnvelope"===a||"multipoint"===b&&"esriGeometryMultipoint"===a||"point"===a&&"esriGeometryPoint"===b||"polyline"===a&&"esriGeometryPolyline"===b||"polygon"===a&&"esriGeometryPolygon"===b||"extent"===a&&"esriGeometryEnvelope"===b||"multipoint"===a&&"esriGeometryMultipoint"===b?!0:!1};e.defaultMaxRecords=1E3;e.errback=function(b){return function(a){b.reject(a)}};e.callback=function(b,a){return function(c){try{b.apply(null,arguments)}catch(f){a.reject(f)}}};
e.layerGeometryEsriConstants={point:"point",polygon:"polygon",polyline:"polyline",multipoint:"multipoint",extent:"extent",esriGeometryPoint:"point",esriGeometryPolygon:"polygon",esriGeometryPolyline:"polyline",esriGeometryMultipoint:"multipoint",esriGeometryEnvelope:"extent",envelope:"extent"};e.toEsriGeometryType=function(b){switch(b){case "point":return"esriGeometryPoint";case "polygon":return"esriGeometryPolygon";case "multipoint":return"esriGeometryMultipoint";case "polyline":return"esriGeometryPolyline";
default:return"esriGeometryPoint"}};e.reduceArrayWithPromises=function(b,a,c){return m.create(function(c,d){var f=m.resolve(!0);b.reduce(function(c,b,d,f){return c.then(function(c){try{return a(c,b,d,f)}catch(u){return m.reject(u)}},function(a){return m.reject(a)})},f).then(c,d)})};e.stableStringify=function(b,a){a||(a={});"function"===typeof a&&(a={cmp:a});var c="boolean"===typeof a.cycles?a.cycles:!1,d=a.cmp&&function(a){return function(c){return function(b,d){return a({key:b,value:c[b]},{key:d,
value:c[d]})}}}(a.cmp),e=[];return function q(a){a&&a.toJSON&&"function"===typeof a.toJSON&&(a=a.toJSON());if(void 0!==a){if("number"===typeof a)return isFinite(a)?""+a:"null";if("object"!==typeof a)return JSON.stringify(a);var b,f;if(Array.isArray(a)){f="[";for(b=0;b<a.length;b++)b&&(f+=","),f+=q(a[b])||"null";return f+"]"}if(null===a)return"null";if(-1!==e.indexOf(a)){if(c)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON");}var h=e.push(a)-1,p=Object.keys(a).sort(d&&
d(a));f="";for(b=0;b<p.length;b++){var n=p[b],l=q(a[n]);l&&(f&&(f+=","),f+=JSON.stringify(n)+":"+l)}e.splice(h,1);return"{"+f+"}"}}(b)}})},"esri/layers/support/Field":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators ./domains ./fieldType".split(" "),function(b,e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this)||this;a.alias=null;a.defaultValue=void 0;a.domain=null;
a.editable=!0;a.length=-1;a.name=null;a.nullable=!0;a.type=null;return a}m(b,c);e=b;b.prototype.clone=function(){return new e({alias:this.alias,defaultValue:this.defaultValue,domain:this.domain&&this.domain.clone()||null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type})};var e;d([l.property({type:String,json:{write:!0}})],b.prototype,"alias",void 0);d([l.property({json:{write:{allowNull:!0}}})],b.prototype,"defaultValue",void 0);d([l.property({types:h.types,
json:{read:{reader:h.fromJSON},write:!0}})],b.prototype,"domain",void 0);d([l.property({type:Boolean,json:{write:!0}})],b.prototype,"editable",void 0);d([l.property({type:Number,json:{write:!0}})],b.prototype,"length",void 0);d([l.property({type:String,json:{write:!0}})],b.prototype,"name",void 0);d([l.property({type:Boolean,json:{write:!0}})],b.prototype,"nullable",void 0);d([l.property({type:String,json:{read:a.kebabDict.read,write:a.kebabDict.write}})],b.prototype,"type",void 0);return b=e=d([l.subclass("esri.layers.support.Field")],
b)}(l.declared(k))})},"esri/layers/support/fieldType":function(){define(["require","exports","../../core/kebabDictionary"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.kebabDict=new m.default({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",
esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml"})})},"esri/arcade/functions/centroid":function(){define(["require","exports","../../geometry/Point"],function(b,e,m){function d(b,a,c){var d={x:0,y:0};a&&(d.z=0);c&&(d.m=0);for(var e=0,g=b[0],h=0;h<b.length;h++){var p=b[h],l;a:if(p.length!==g.length)l=!1;else{for(l=0;l<p.length;l++)if(p[l]!==g[l]){l=!1;break a}l=!0}if(!1===l){l=k(g,p,a);var m=p,v=a,u=c,z={x:(g[0]+m[0])/2,y:(g[1]+m[1])/2};
v&&(z.z=(g[2]+m[2])/2);v&&u?z.m=(g[3]+m[3])/2:u&&(z.m=(g[2]+m[2])/2);g=z;g.x*=l;g.y*=l;d.x+=g.x;d.y+=g.y;a&&(g.z*=l,d.z+=g.z);c&&(g.m*=l,d.m+=g.m);e+=l;g=p}}0<e?(d.x/=e,d.y/=e,a&&(d.z/=e),c&&(d.m/=e)):(d.x=b[0][0],d.y=b[0][1],a&&(d.z=b[0][2]),c&&a?d.m=b[0][3]:c&&(d.m=b[0][2]));return d}function k(b,a,c){var d=a[0]-b[0];b=a[1]-b[1];return c?(a=a[2]-a[2],Math.sqrt(d*d+b*b+a*a)):Math.sqrt(d*d+b*b)}function l(b,a){var c=a[0],d=a[1],e=a[2],c=c*c+d*d+e*e;0<c&&(c=1/Math.sqrt(c),b[0]=a[0]*c,b[1]=a[1]*c,b[2]=
a[2]*c);return b}Object.defineProperty(e,"__esModule",{value:!0});e.centroidPolyline=function(b){for(var a={x:0,y:0,spatialReference:b.spatialReference.toJSON()},c={x:0,y:0,spatialReference:b.spatialReference.toJSON()},f=0,e=0,g=0;g<b.paths.length;g++)if(0!==b.paths[g].length){var h;h=b.paths[g];var p=!0===b.hasZ;if(1>=h.length)h=0;else{for(var l=0,r=1;r<h.length;r++)l+=k(h[r-1],h[r],p);h=l}0===h?(p=d(b.paths[g],!0===b.hasZ,!0===b.hasM),a.x+=p.x,a.y+=p.y,!0===b.hasZ&&(a.z+=p.z),!0===b.hasM&&(a.m+=
p.m),++f):(p=d(b.paths[g],!0===b.hasZ,!0===b.hasM),c.x+=p.x*h,c.y+=p.y*h,!0===b.hasZ&&(c.z+=p.z*h),!0===b.hasM&&(c.m+=p.m*h),e+=h)}return 0<e?(c.x/=e,c.y/=e,!0===b.hasZ&&(c.z/=e),!0===b.hasM&&(c.m/=e),new m(c)):0<f?(a.x/=f,a.y/=f,!0===b.hasZ&&(c.z/=f),!0===b.hasM&&(a.m/=f),new m(a)):null};e.centroidMultiPoint=function(b){if(0===b.points.length)return null;for(var a=0,c=0,d=0,e=0,g=0;g<b.points.length;g++){var h=b.getPoint(g);!0===h.hasZ&&(d+=h.z);!0===h.hasM&&(e+=h.m);a+=h.x;c+=h.y;e+=h.m}a={x:a/
b.points.length,y:c/b.points.length,spatialReference:null};a.spatialReference=b.spatialReference.toJSON();!0===b.hasZ&&(a.z=d/b.points.length);!0===b.hasM&&(a.m=e/b.points.length);return new m(a)};e.angle2D=function(b,a){var c=b.x;b=b.y;var d=a.x;a=a.y;var e=c*c+b*b;0<e&&(e=1/Math.sqrt(e));var g=d*d+a*a;0<g&&(g=1/Math.sqrt(g));c=(c*d+b*a)*e*g;return 1<c?0:-1>c?Math.PI:180*Math.acos(c)/Math.PI};e.angleBetween2D=function(b,a,c){var d=b.x-a.x;b=b.y-a.y;var e=c.x-a.x;a=c.y-a.y;c=Math.sqrt(d*d+b*b);var g=
Math.sqrt(e*e+a*a);return 180*Math.acos(d/c*(e/g)+b/c*(a/g))/Math.PI};e.angleBetween3D=function(b,a,c){var d=b.x-a.x,e=b.y-a.y;b=b.z-a.z;var g=c.x-a.x,h=c.y-a.y;a=c.z-a.z;c=Math.sqrt(d*d+e*e+b*b);var p=Math.sqrt(g*g+h*h+a*a);return 180*Math.acos(d/c*(g/p)+e/c*(h/p)+b/c*(a/p))/Math.PI};e.angle3D=function(b,a){b=l([b.x,b.y,b.z],[b.x,b.y,b.z]);a=l([a.x,a.y,a.z],[a.x,a.y,a.z]);a=b[0]*a[0]+b[1]*a[1]+b[2]*a[2];return 1<a?0:-1>a?Math.PI:180*Math.acos(a)/Math.PI}})},"esri/arcade/functions/maths":function(){define(["require",
"exports","dojo/number","../languageUtils"],function(b,e,m,d){function k(b,d,a){if("undefined"===typeof a||0===+a)return Math[b](d);d=+d;a=+a;if(isNaN(d)||"number"!==typeof a||0!==a%1)return NaN;d=d.toString().split("e");d=Math[b](+(d[0]+"e"+(d[1]?+d[1]-a:-a)));d=d.toString().split("e");return+(d[0]+"e"+(d[1]?+d[1]+a:a))}Object.defineProperty(e,"__esModule",{value:!0});e.registerFunctions=function(b,e){function a(a,b,e){a=d.toNumber(a);return isNaN(a)?a:isNaN(b)||isNaN(e)||b>e?NaN:a<b?b:a>e?e:a}b.number=
function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,2);a=b[0];return d.isNumber(a)?a:null===a?0:d.isDate(a)||d.isBoolean(a)?Number(a):d.isArray(a)?NaN:""===a||void 0===a?Number(a):d.isString(a)?void 0!==b[1]?(b=d.multiReplace(b[1],"\u2030",""),b=d.multiReplace(b,"\u00a4",""),m.parse(a,{pattern:b})):Number(a.trim()):Number(a)})};b.abs=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return Math.abs(d.toNumber(b[0]))})};b.acos=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,
1);return Math.acos(d.toNumber(b[0]))})};b.asin=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return Math.asin(d.toNumber(b[0]))})};b.atan=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return Math.atan(d.toNumber(b[0]))})};b.atan2=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,2,2);return Math.atan2(d.toNumber(b[0]),d.toNumber(b[1]))})};b.ceil=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,2);return 2===b.length?(a=d.toNumber(b[1]),isNaN(a)&&(a=0),k("ceil",
d.toNumber(b[0]),-1*a)):Math.ceil(d.toNumber(b[0]))})};b.round=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,2);return 2===b.length?(a=d.toNumber(b[1]),isNaN(a)&&(a=0),k("round",d.toNumber(b[0]),-1*a)):Math.round(d.toNumber(b[0]))})};b.floor=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,2);return 2===b.length?(a=d.toNumber(b[1]),isNaN(a)&&(a=0),k("floor",d.toNumber(b[0]),-1*a)):Math.floor(d.toNumber(b[0]))})};b.cos=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);
return Math.cos(d.toNumber(b[0]))})};b.isnan=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return"number"===typeof b[0]&&isNaN(b[0])})};b.exp=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return Math.exp(d.toNumber(b[0]))})};b.log=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return Math.log(d.toNumber(b[0]))})};b.pow=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,2,2);return Math.pow(d.toNumber(b[0]),d.toNumber(b[1]))})};b.random=function(a,b){return e(a,
b,function(a,c,b){d.pcCheck(b,0,0);return Math.random()})};b.sin=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return Math.sin(d.toNumber(b[0]))})};b.sqrt=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return Math.sqrt(d.toNumber(b[0]))})};b.tan=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return Math.tan(d.toNumber(b[0]))})};b.defaultvalue=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,2,2);return null===b[0]||""===b[0]||void 0===b[0]?b[1]:b[0]})};
b.isempty=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return null===b[0]||""===b[0]||void 0===b[0]?!0:!1})};b["boolean"]=function(a,b){return e(a,b,function(a,c,b){d.pcCheck(b,1,1);return d.toBoolean(b[0])})};b.constrain=function(c,b){return e(c,b,function(c,b,f){d.pcCheck(f,3,3);c=d.toNumber(f[1]);b=d.toNumber(f[2]);if(d.isArray(f[0])){var e=[],g=0;for(f=f[0];g<f.length;g++)e.push(a(f[g],c,b));return e}if(d.isImmutableArray(f[0])){e=[];for(g=0;g<f[0].length();g++)e.push(a(f[0].get(g),
c,b));return e}return a(f[0],c,b)})}}})},"esri/arcade/functions/stats":function(){define(["require","exports","../languageUtils","./fieldStats"],function(b,e,m,d){function k(b,e,a,c){if(1===c.length){if(m.isArray(c[0]))return d.calculateStat(b,c[0],-1);if(m.isImmutableArray(c[0]))return d.calculateStat(b,c[0].toArray(),-1)}return d.calculateStat(b,c,-1)}Object.defineProperty(e,"__esModule",{value:!0});e.registerFunctions=function(b,d){b.stdev=function(a,c){return d(a,c,function(a,c,b){return k("stdev",
a,c,b)})};b.variance=function(a,c){return d(a,c,function(a,c,b){return k("variance",a,c,b)})};b.average=function(a,c){return d(a,c,function(a,c,b){return k("mean",a,c,b)})};b.mean=function(a,c){return d(a,c,function(a,c,b){return k("mean",a,c,b)})};b.sum=function(a,c){return d(a,c,function(a,c,b){return k("sum",a,c,b)})};b.min=function(a,c){return d(a,c,function(a,c,b){return k("min",a,c,b)})};b.max=function(a,c){return d(a,c,function(a,c,b){return k("max",a,c,b)})};b.distinct=function(a,c){return d(a,
c,function(a,c,b){return k("distinct",a,c,b)})};b.count=function(a,c){return d(a,c,function(a,c,b){m.pcCheck(b,1,1);if(m.isArray(b[0])||m.isString(b[0]))return b[0].length;if(m.isImmutableArray(b[0]))return b[0].length();throw Error("Invalid Parameters for Count");})}}})},"esri/arcade/functions/fieldStats":function(){define(["require","exports","../languageUtils"],function(b,e,m){function d(b){for(var d=0,a=0;a<b.length;a++)d+=b[a];return d/b.length}function k(b){for(var e=d(b),a=0,c=0;c<b.length;c++)a+=
Math.pow(e-b[c],2);return a/b.length}Object.defineProperty(e,"__esModule",{value:!0});e.decodeStatType=function(b){switch(b.toLowerCase()){case "distinct":return"distinct";case "avg":case "mean":return"avg";case "min":return"min";case "sum":return"sum";case "max":return"max";case "stdev":case "stddev":return"stddev";case "var":case "variance":return"var";case "count":return"count"}return""};e.calculateStat=function(b,e,a){void 0===a&&(a=1E3);switch(b.toLowerCase()){case "distinct":a:{b=a;a=[];for(var c=
{},f=[],h=0;h<e.length;h++){if(void 0!==e[h]&&null!==e[h]&&e[h]!==m.voidOperation){var g=e[h];if(m.isNumber(g)||m.isString(g))void 0===c[g]&&(a.push(g),c[g]=1);else{for(var l=!1,p=0;p<f.length;p++)!0===m.equalityTest(f[p],g)&&(l=!0);!1===l&&(f.push(g),a.push(g))}}if(a.length>=b&&-1!==b){e=a;break a}}e=a}return e;case "avg":case "mean":return d(m.toNumberArray(e));case "min":return Math.min.apply(Math,m.toNumberArray(e));case "sum":e=m.toNumberArray(e);for(a=b=0;a<e.length;a++)b+=e[a];return b;case "max":return Math.max.apply(Math,
m.toNumberArray(e));case "stdev":case "stddev":return Math.sqrt(k(m.toNumberArray(e)));case "var":case "variance":return k(m.toNumberArray(e));case "count":return e.length}return 0}})},"esri/arcade/functions/string":function(){define(["require","exports","../Dictionary","../Feature","../languageUtils"],function(b,e,m,d,k){Object.defineProperty(e,"__esModule",{value:!0});e.registerFunctions=function(b,e){b.trim=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,1,1);return k.toString(b[0]).trim()})};
b.upper=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,1,1);return k.toString(b[0]).toUpperCase()})};b.proper=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,1,2);a=1;2===b.length&&"firstword"===k.toString(b[1]).toLowerCase()&&(a=2);c=/\s/;b=k.toString(b[0]);for(var d="",f=!0,e=0;e<b.length;e++){var g=b[e];c.test(g)?1===a&&(f=!0):g.toUpperCase()!==g.toLowerCase()&&(f?(g=g.toUpperCase(),f=!1):g=g.toLowerCase());d+=g}return d})};b.lower=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,
1,1);return k.toString(b[0]).toLowerCase()})};b.guid=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,0,1);if(0<b.length)switch(k.toString(b[0]).toLowerCase()){case "digits":return k.generateUUID().replace("-","").replace("-","").replace("-","").replace("-","");case "digits-hyphen":return k.generateUUID();case "digits-hyphen-parentheses":return"("+k.generateUUID()+")"}return"{"+k.generateUUID()+"}"})};b.console=function(a,c){return e(a,c,function(c,b,d){0!==d.length&&(1===d.length?a.console(k.toString(d[0])):
a.console(k.toString(d)));return k.voidOperation})};b.mid=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,2,3);a=k.toNumber(b[1]);if(isNaN(a))return"";0>a&&(a=0);if(2===b.length)return k.toString(b[0]).substr(a);c=k.toNumber(b[2]);if(isNaN(c))return"";0>c&&(c=0);return k.toString(b[0]).substr(a,c)})};b.find=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,2,3);a=0;if(2<b.length){a=k.toNumber(k.defaultUndefined(b[2],0));if(isNaN(a))return-1;0>a&&(a=0)}return k.toString(b[1]).indexOf(k.toString(b[0]),
a)})};b.left=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,2,2);a=k.toNumber(b[1]);if(isNaN(a))return"";0>a&&(a=0);return k.toString(b[0]).substr(0,a)})};b.right=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,2,2);a=k.toNumber(b[1]);if(isNaN(a))return"";0>a&&(a=0);return k.toString(b[0]).substr(-1*a,a)})};b.split=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,2,4);a=k.toNumber(k.defaultUndefined(b[2],-1));c=k.toBoolean(k.defaultUndefined(b[3],!1));-1===a||null===a||!0===c?
b=k.toString(b[0]).split(k.toString(b[1])):(isNaN(a)&&(a=-1),-1>a&&(a=-1),b=k.toString(b[0]).split(k.toString(b[1]),a));if(!1===c)return b;c=[];for(var d=0;d<b.length&&!(-1!==a&&c.length>=a);d++)""!==b[d]&&void 0!==b[d]&&c.push(b[d]);return c})};b.text=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,1,2);return k.toStringExplicit(b[0],b[1])})};b.concatenate=function(a,c){return e(a,c,function(a,c,b){a=[];if(1>b.length)return"";if(k.isArray(b[0])){c=k.defaultUndefined(b[2],"");for(var d=0;d<
b[0].length;d++)a[d]=k.toStringExplicit(b[0][d],c);return 1<b.length?a.join(b[1]):a.join("")}if(k.isImmutableArray(b[0])){c=k.defaultUndefined(b[2],"");for(d=0;d<b[0].length();d++)a[d]=k.toStringExplicit(b[0].get(d),c);return 1<b.length?a.join(b[1]):a.join("")}for(d=0;d<b.length;d++)a[d]=k.toStringExplicit(b[d]);return a.join("")})};b.reverse=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,1,1);if(k.isArray(b[0]))return a=b[0].slice(0),a.reverse(),a;if(k.isImmutableArray(b[0]))return a=b[0].toArray().slice(0),
a.reverse(),a;throw Error("Invalid Parameter");})};b.replace=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,3,4);a=k.toString(b[0]);c=k.toString(b[1]);var d=k.toString(b[2]);return(4===b.length?k.toBoolean(b[3]):1)?k.multiReplace(a,c,d):a.replace(c,d)})};b.domainname=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,2,4);if(b[0]instanceof d)return b[0].domainValueLookup(k.toString(b[1]),b[2],void 0===b[3]?void 0:k.toNumber(b[3]));throw Error("Invalid Parameter");})};b.domaincode=function(a,
c){return e(a,c,function(a,c,b){k.pcCheck(b,2,4);if(b[0]instanceof d)return b[0].domainCodeLookup(k.toString(b[1]),b[2],void 0===b[3]?void 0:k.toNumber(b[3]));throw Error("Invalid Parameter");})};b.urlencode=function(a,c){return e(a,c,function(a,c,b){k.pcCheck(b,1,1);if(null===b[0])return"";if(b[0]instanceof m){a="";c=0;for(var d=b[0].keys();c<d.length;c++){var e=d[c],f=b[0].field(e);""!==a&&(a+="\x26");a=null===f?a+(encodeURIComponent(e)+"\x3d"):a+(encodeURIComponent(e)+"\x3d"+encodeURIComponent(f))}return a}return encodeURIComponent(k.toString(b[0]))})}}})},
"esri/arcade/arcadeRuntime":function(){define("require exports ./Attachment ./Dictionary ./Feature ./FunctionWrapper ./ImmutablePathArray ./ImmutablePointArray ./languageUtils ./treeAnalysis ./functions/date ./functions/geometry ./functions/geomsync ./functions/maths ./functions/stats ./functions/string ../geometry/Extent ../geometry/Geometry ../geometry/Multipoint ../geometry/Point ../geometry/Polygon ../geometry/Polyline ../geometry/SpatialReference".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g,
q,p,t,r,v,u,z,y,x,w,A){function B(a,c){for(var b=[],d=0;d<c.arguments.length;d++)b.push(C(a,c.arguments[d]));return b}function F(a,c,b){try{return b(a,c,B(a,c))}catch(ra){throw ra;}}function C(a,b){try{switch(b.type){case "EmptyStatement":return c.voidOperation;case "VariableDeclarator":var e=null===b.init?null:C(a,b.init);e===c.voidOperation&&(e=null);if("Identifier"!==b.id.type)throw Error("Can only assign a regular variable");var g=b.id.name.toLowerCase();null!==a.localScope?a.localScope[g]={value:e,
valueset:!0,node:b.init}:a.globalScope[g]={value:e,valueset:!0,node:b.init};return c.voidOperation;case "VariableDeclaration":for(var h=0;h<b.declarations.length;h++)C(a,b.declarations[h]);return c.voidOperation;case "BlockStatement":var p;a:{for(var n=c.voidOperation,h=0;h<b.body.length;h++)if(n=C(a,b.body[h]),n instanceof c.ReturnResult||n===c.breakResult||n===c.continueResult){p=n;break a}p=n}return p;case "FunctionDeclaration":var m=b.id.name.toLowerCase();a.globalScope[m]={valueset:!0,node:null,
value:new l(b,a)};return c.voidOperation;case "ReturnStatement":var r;if(null===b.argument)r=new c.ReturnResult(c.voidOperation);else{var t=C(a,b.argument);r=new c.ReturnResult(t)}return r;case "IfStatement":var q;if("AssignmentExpression"===b.test.type||"UpdateExpression"===b.test.type)throw Error(f.nodeErrorMessage(b.test,"RUNTIME","CANNOT_USE_ASSIGNMENT_IN_CONDITION"));var u=C(a,b.test);if(!0===u)q=C(a,b.consequent);else if(!1===u)q=null!==b.alternate?C(a,b.alternate):c.voidOperation;else throw Error(f.nodeErrorMessage(b,
"RUNTIME","CANNOT_USE_NONBOOLEAN_IN_CONDITION"));return q;case "ExpressionStatement":var v;if("AssignmentExpression"===b.expression.type||"UpdateExpression"===b.expression.type)v=C(a,b.expression);else{var y=C(a,b.expression);v=y===c.voidOperation?c.voidOperation:new c.ImplicitResult(y)}return v;case "AssignmentExpression":var z;var w=C(a,b.right),h=null,x="";if("MemberExpression"===b.left.type){h=C(a,b.left.object);!0===b.left.computed?x=C(a,b.left.property):"Identifier"===b.left.property.type&&
(x=b.left.property.name);if(c.isArray(h))if(c.isNumber(x)){0>x&&(x=h.length+x);if(0>x||x>h.length)throw Error("Assignment outside of array bounds");if(x===h.length&&"\x3d"!==b.operator)throw Error("Invalid Parameter");h[x]=G(w,b.operator,h[x],b)}else throw Error("Invalid Parameter");else if(h instanceof d){if(!1===c.isString(x))throw Error("Dictionary accessor must be a string");if(!0===h.hasField(x))h.setField(x,G(w,b.operator,h.field(x),b));else{if("\x3d"!==b.operator)throw Error("Invalid Parameter");
h.setField(x,G(w,b.operator,null,b))}}else if(h instanceof k){if(!1===c.isString(x))throw Error("Feature accessor must be a string");if(!0===h.hasField(x))h.setField(x,G(w,b.operator,h.field(x),b));else{if("\x3d"!==b.operator)throw Error("Invalid Parameter");h.setField(x,G(w,b.operator,null,b))}}else{if(c.isImmutableArray(h))throw Error("Array is Immutable");throw Error("Invalid Parameter");}z=c.voidOperation}else if(h=b.left.name.toLowerCase(),null!==a.localScope&&void 0!==a.localScope[h])a.localScope[h]=
{value:G(w,b.operator,a.localScope[h].value,b),valueset:!0,node:b.right},z=c.voidOperation;else if(void 0!==a.globalScope[h])a.globalScope[h]={value:G(w,b.operator,a.globalScope[h].value,b),valueset:!0,node:b.right},z=c.voidOperation;else throw Error("Variable not recognised");return z;case "UpdateExpression":var F;var B,h=null,x="";if("MemberExpression"===b.argument.type){h=C(a,b.argument.object);!0===b.argument.computed?x=C(a,b.argument.property):"Identifier"===b.argument.property.type&&(x=b.argument.property.name);
if(c.isArray(h))if(c.isNumber(x)){0>x&&(x=h.length+x);if(0>x||x>=h.length)throw Error("Assignment outside of array bounds");B=c.toNumber(h[x]);h[x]="++"===b.operator?B+1:B-1}else throw Error("Invalid Parameter");else if(h instanceof d){if(!1===c.isString(x))throw Error("Dictionary accessor must be a string");if(!0===h.hasField(x))B=c.toNumber(h.field(x)),h.setField(x,"++"===b.operator?B+1:B-1);else throw Error("Invalid Parameter");}else if(h instanceof k){if(!1===c.isString(x))throw Error("Feature accessor must be a string");
if(!0===h.hasField(x))B=c.toNumber(h.field(x)),h.setField(x,"++"===b.operator?B+1:B-1);else throw Error("Invalid Parameter");}else{if(c.isImmutableArray(h))throw Error("Array is Immutable");throw Error("Invalid Parameter");}F=!1===b.prefix?B:"++"===b.operator?B+1:B-1}else{h="Identifier"===b.argument.type?b.argument.name.toLowerCase():"";if(!h)throw Error("Invalid identifier");if(null!==a.localScope&&void 0!==a.localScope[h])B=c.toNumber(a.localScope[h].value),a.localScope[h]={value:"++"===b.operator?
B+1:B-1,valueset:!0,node:b},F=!1===b.prefix?B:"++"===b.operator?B+1:B-1;else if(void 0!==a.globalScope[h])B=c.toNumber(a.globalScope[h].value),a.globalScope[h]={value:"++"===b.operator?B+1:B-1,valueset:!0,node:b},F=!1===b.prefix?B:"++"===b.operator?B+1:B-1;else throw Error("Variable not recognised");}return F;case "BreakStatement":return c.breakResult;case "ContinueStatement":return c.continueResult;case "ForStatement":null!==b.init&&C(a,b.init);x={testResult:!0,lastAction:c.voidOperation};do b:{z=
a;w=b;F=x;if(null!==w.test){F.testResult=C(z,w.test);if(!1===F.testResult)break b;if(!0!==F.testResult)throw Error(f.nodeErrorMessage(w,"RUNTIME","CANNOT_USE_NONBOOLEAN_IN_CONDITION"));}F.lastAction=C(z,w.body);F.lastAction===c.breakResult?F.testResult=!1:F.lastAction instanceof c.ReturnResult?F.testResult=!1:null!==w.update&&C(z,w.update)}while(!0===x.testResult);h=x.lastAction instanceof c.ReturnResult?x.lastAction:c.voidOperation;return h;case "ForInStatement":return E(a,b);case "Identifier":return M(a,
b);case "MemberExpression":return V(a,b);case "Literal":return b.value;case "CallExpression":return U(a,b);case "UnaryExpression":return R(a,b);case "BinaryExpression":return I(a,b);case "LogicalExpression":return W(a,b);case "ConditionalExpression":throw Error(f.nodeErrorMessage(b,"RUNTIME","NOTSUPPORTED"));case "ArrayExpression":try{for(h=[],x=0;x<b.elements.length;x++){var A=C(a,b.elements[x]);if(c.isFunctionParameter(A))throw Error(f.nodeErrorMessage(b,"RUNTIME","FUNCTIONCONTEXTILLEGAL"));A===
c.voidOperation?h.push(null):h.push(A)}}catch(N){throw N;}return h;case "ObjectExpression":h={};for(x=0;x<b.properties.length;x++){var Q=C(a,b.properties[x]);if(c.isFunctionParameter(Q.value))throw Error("Illegal Argument");if(!1===c.isString(Q.key))throw Error("Illegal Argument");h[Q.key.toString()]=Q.value===c.voidOperation?null:Q.value}var sa=new d(h);sa.immutable=!1;return sa;case "Property":return{key:"Identifier"===b.key.type?b.key.name:C(a,b.key),value:C(a,b.value)};default:throw Error(f.nodeErrorMessage(b,
"RUNTIME","UNREOGNISED"));}}catch(N){throw N;}}function E(a,b){var e=C(a,b.right);"VariableDeclaration"===b.left.type&&C(a,b.left);var g=null,h="";if("VariableDeclaration"===b.left.type){var p=b.left.declarations[0].id;"Identifier"===p.type&&(h=p.name)}else"Identifier"===b.left.type&&(h=b.left.name);if(!h)throw Error(f.nodeErrorMessage(b,"RUNTIME","INVALIDVARIABLE"));null!==a.localScope&&void 0!==a.localScope[h]&&(g=a.localScope[h]);null===g&&void 0!==a.globalScope[h]&&(g=a.globalScope[h]);if(null===
g)throw Error(f.nodeErrorMessage(b,"RUNTIME","VARIABLENOTDECLARED"));if(c.isArray(e)||c.isString(e)){e=e.length;for(p=0;p<e;p++){g.value=p;h=C(a,b.body);if(h===c.breakResult)break;if(h instanceof c.ReturnResult)return h}return c.voidOperation}if(c.isImmutableArray(e)){for(p=0;p<e.length();p++){g.value=p;h=C(a,b.body);if(h===c.breakResult)break;if(h instanceof c.ReturnResult)return h}return c.voidOperation}if(e instanceof d||e instanceof k)for(e=e.keys(),p=0;p<e.length;p++){g.value=e[p];h=C(a,b.body);
if(h===c.breakResult)break;if(h instanceof c.ReturnResult)return h}else return c.voidOperation}function G(a,b,d,e){switch(b){case "\x3d":return a===c.voidOperation?null:a;case "/\x3d":return c.toNumber(d)/c.toNumber(a);case "*\x3d":return c.toNumber(d)*c.toNumber(a);case "-\x3d":return c.toNumber(d)-c.toNumber(a);case "+\x3d":return c.isString(d)||c.isString(a)?c.toString(d)+c.toString(a):c.toNumber(d)+c.toNumber(a);case "%\x3d":return c.toNumber(d)%c.toNumber(a);default:throw Error(f.nodeErrorMessage(e,
"RUNTIME","OPERATORNOTRECOGNISED"));}}function Q(c,b,e,g){b=b.toLowerCase();switch(b){case "hasz":return c=c.hasZ,void 0===c?!1:c;case "hasm":return c=c.hasM,void 0===c?!1:c;case "spatialreference":return b=c.spatialReference._arcadeCacheId,void 0===b&&(e=!0,Object.freeze&&Object.isFrozen(c.spatialReference)&&(e=!1),e&&(la++,b=c.spatialReference._arcadeCacheId=la)),c=new d({wkt:c.spatialReference.wkt,wkid:c.spatialReference.wkid}),void 0!==b&&(c._arcadeCacheId="SPREF"+b.toString()),c}switch(c.type){case "extent":switch(b){case "xmin":case "xmax":case "ymin":case "ymax":case "zmin":case "zmax":case "mmin":case "mmax":return c=
c[b],void 0!==c?c:null;case "type":return"Extent"}break;case "polygon":switch(b){case "rings":return b=c.cache._arcadeCacheId,void 0===b&&(la++,b=la,c.cache._arcadeCacheId=b),c=new h(c.rings,c.spatialReference,!0===c.hasZ,!0===c.hasM,b);case "type":return"Polygon"}break;case "point":switch(b){case "x":case "y":case "z":case "m":return void 0!==c[b]?c[b]:null;case "type":return"Point"}break;case "polyline":switch(b){case "paths":return b=c.cache._arcadeCacheId,void 0===b&&(la++,b=la,c.cache._arcadeCacheId=
b),c=new h(c.paths,c.spatialReference,!0===c.hasZ,!0===c.hasM,b);case "type":return"Polyline"}break;case "multipoint":switch(b){case "points":return b=c.cache._arcadeCacheId,void 0===b&&(la++,b=la,c.cache._arcadeCacheId=b),c=new a(c.points,c.spatialReference,!0===c.hasZ,!0===c.hasM,b,1);case "type":return"Multipoint"}}throw Error(f.nodeErrorMessage(g,"RUNTIME","PROPERTYNOTFOUND"));}function V(a,b){try{var e=C(a,b.object);if(null===e)throw Error(f.nodeErrorMessage(b,"RUNTIME","NOTFOUND"));if(!1===
b.computed){if("Identifier"===b.property.type){if(e instanceof d||e instanceof k)return e.field(b.property.name);if(e instanceof u)return Q(e,b.property.name,a,b)}throw Error(f.nodeErrorMessage(b,"RUNTIME","INVALIDTYPE"));}var g=C(a,b.property);if(e instanceof d||e instanceof k){if(c.isString(g))return e.field(g);throw Error(f.nodeErrorMessage(b,"RUNTIME","INVALIDTYPE"));}if(e instanceof u){if(c.isString(g))return Q(e,g,a,b);throw Error(f.nodeErrorMessage(b,"RUNTIME","INVALIDTYPE"));}if(c.isArray(e)){if(c.isNumber(g)&&
isFinite(g)&&Math.floor(g)===g){0>g&&(g=e.length+g);if(g>=e.length||0>g)throw Error(f.nodeErrorMessage(b,"RUNTIME","OUTOFBOUNDS"));return e[g]}throw Error(f.nodeErrorMessage(b,"RUNTIME","INVALIDTYPE"));}if(c.isString(e)){if(c.isNumber(g)&&isFinite(g)&&Math.floor(g)===g){0>g&&(g=e.length+g);if(g>=e.length||0>g)throw Error(f.nodeErrorMessage(b,"RUNTIME","OUTOFBOUNDS"));return e[g]}throw Error(f.nodeErrorMessage(b,"RUNTIME","INVALIDTYPE"));}if(c.isImmutableArray(e)&&c.isNumber(g)&&isFinite(g)&&Math.floor(g)===
g){0>g&&(g=e.length()+g);if(g>=e.length()||0>g)throw Error(f.nodeErrorMessage(b,"RUNTIME","OUTOFBOUNDS"));return e.get(g)}throw Error(f.nodeErrorMessage(b,"RUNTIME","INVALIDTYPE"));}catch(na){throw na;}}function R(a,b){try{var d=C(a,b.argument);if(c.isBoolean(d)){if("!"===b.operator)return!d;if("-"===b.operator)return-1*c.toNumber(d);if("+"===b.operator)return 1*c.toNumber(d);throw Error(f.nodeErrorMessage(b,"RUNTIME","NOTSUPPORTEDUNARYOPERATOR"));}if("-"===b.operator)return-1*c.toNumber(d);if("+"===
b.operator)return 1*c.toNumber(d);throw Error(f.nodeErrorMessage(b,"RUNTIME","NOTSUPPORTEDUNARYOPERATOR"));}catch(ra){throw ra;}}function I(a,b){try{var d=[C(a,b.left),C(a,b.right)],e=d[0],g=d[1];switch(b.operator){case "\x3d\x3d":return c.equalityTest(e,g);case "!\x3d":return!c.equalityTest(e,g);case "\x3c":return c.greaterThanLessThan(e,g,b.operator);case "\x3e":return c.greaterThanLessThan(e,g,b.operator);case "\x3c\x3d":return c.greaterThanLessThan(e,g,b.operator);case "\x3e\x3d":return c.greaterThanLessThan(e,
g,b.operator);case "+":return c.isString(e)||c.isString(g)?c.toString(e)+c.toString(g):c.toNumber(e)+c.toNumber(g);case "-":return c.toNumber(e)-c.toNumber(g);case "*":return c.toNumber(e)*c.toNumber(g);case "/":return c.toNumber(e)/c.toNumber(g);case "%":return c.toNumber(e)%c.toNumber(g);default:throw Error(f.nodeErrorMessage(b,"RUNTIME","OPERATORNOTRECOGNISED"));}}catch(ua){throw ua;}}function W(a,b){try{if("AssignmentExpression"===b.left.type||"UpdateExpression"===b.left.type)throw Error(f.nodeErrorMessage(b.left,
"RUNTIME","CANNOT_USE_ASSIGNMENT_IN_CONDITION"));if("AssignmentExpression"===b.right.type||"UpdateExpression"===b.right.type)throw Error(f.nodeErrorMessage(b.right,"RUNTIME","CANNOT_USE_ASSIGNMENT_IN_CONDITION"));var d=C(a,b.left);if(c.isBoolean(d))switch(b.operator){case "||":if(!0===d)return d;var e=C(a,b.right);if(c.isBoolean(e))return e;throw Error(f.nodeErrorMessage(b,"RUNTIME","ONLYORORAND"));case "\x26\x26":if(!1===d)return d;e=C(a,b.right);if(c.isBoolean(e))return e;throw Error(f.nodeErrorMessage(b,
"RUNTIME","ONLYORORAND"));default:throw Error(f.nodeErrorMessage(b,"RUNTIME","ONLYORORAND"));}throw Error(f.nodeErrorMessage(b,"RUNTIME","ONLYBOOLEAN"));}catch(na){throw na;}}function M(a,c){var b;try{var d=c.name.toLowerCase();if(null!==a.localScope&&void 0!==a.localScope[d]){b=a.localScope[d];if(!0===b.valueset)return b.value;b.value=C(a,b.node);b.valueset=!0;return b.value}if(void 0!==a.globalScope[d]){b=a.globalScope[d];if(!0===b.valueset)return b.value;b.value=C(a,b.node);b.valueset=!0;return b.value}throw Error(f.nodeErrorMessage(c,
"RUNTIME","VARIABLENOTFOUND"));}catch(na){throw na;}}function U(a,b){try{if("Identifier"!==b.callee.type)throw Error(f.nodeErrorMessage(b,"RUNTIME","ONLYNODESSUPPORTED"));if(null!==a.localScope&&void 0!==a.localScope[b.callee.name.toLowerCase()]){var d=a.localScope[b.callee.name.toLowerCase()];if(d.value instanceof c.NativeFunction)return d.value.fn(a,b);if(d.value instanceof l)return aa(a,b,d.value.definition);throw Error(f.nodeErrorMessage(b,"RUNTIME","NOTAFUNCTION"));}if(void 0!==a.globalScope[b.callee.name.toLowerCase()]){d=
a.globalScope[b.callee.name.toLowerCase()];if(d.value instanceof c.NativeFunction)return d.value.fn(a,b);if(d.value instanceof l)return aa(a,b,d.value.definition);throw Error(f.nodeErrorMessage(b,"RUNTIME","NOTAFUNCTION"));}throw Error(f.nodeErrorMessage(b,"RUNTIME","NOTFOUND"));}catch(ra){throw ra;}}function O(a){return null==a?"":c.isArray(a)||c.isImmutableArray(a)?"Array":c.isDate(a)?"Date":c.isString(a)?"String":c.isBoolean(a)?"Boolean":c.isNumber(a)?"Number":a instanceof m?"Attachment":a instanceof
d?"Dictionary":a instanceof k?"Feature":a instanceof y?"Point":a instanceof x?"Polygon":a instanceof w?"Polyline":a instanceof z?"Multipoint":a instanceof v?"Extent":c.isFunctionParameter(a)?"Function":c.isFeatureSet(a)?"FeatureSet":c.isFeatureSetCollection(a)?"FeatureSetCollection":a===c.voidOperation?"":"number"===typeof a&&isNaN(a)?"Number":"Unrecognised Type"}function J(a,b,d,e){try{var f=C(a,b.arguments[d]);if(c.equalityTest(f,e))return C(a,b.arguments[d+1]);var g=b.arguments.length-d;return 1===
g?C(a,b.arguments[d]):2===g?null:3===g?C(a,b.arguments[d+2]):J(a,b,d+2,e)}catch(qa){throw qa;}}function fa(a,b,d,e){try{if(!0===e)return C(a,b.arguments[d+1]);if(3===b.arguments.length-d)return C(a,b.arguments[d+2]);var f=C(a,b.arguments[d+2]);if(!1===c.isBoolean(f))throw Error("WHEN needs boolean test conditions");return fa(a,b,d+2,f)}catch(ua){throw ua;}}function H(a,c){var b=a.length,d=Math.floor(b/2);if(0===b)return[];if(1===b)return[a[0]];var e=H(a.slice(0,d),c);a=H(a.slice(d,b),c);for(b=[];0<
e.length||0<a.length;)0<e.length&&0<a.length?(d=c(e[0],a[0]),isNaN(d)&&(d=0),0>=d?(b.push(e[0]),e=e.slice(1)):(b.push(a[0]),a=a.slice(1))):0<e.length?(b.push(e[0]),e=e.slice(1)):0<a.length&&(b.push(a[0]),a=a.slice(1));return b}function da(a,b,d){try{var e=a.body;if(d.length!==a.params.length)throw Error("Invalid Parameter calls to function.");for(var f=0;f<d.length;f++)b.localScope[a.params[f].name.toLowerCase()]={value:d[f],valueset:!0,node:null};var g=C(b,e);if(g instanceof c.ReturnResult)return g.value;
if(g===c.breakResult)throw Error("Cannot Break from a Function");if(g===c.continueResult)throw Error("Cannot Continue from a Function");return g instanceof c.ImplicitResult?g.value:g}catch(qa){throw qa;}}function aa(a,c,b){return F(a,c,function(c,d,e){c={spatialReference:a.spatialReference,applicationCache:void 0===a.applicationCache?null:a.applicationCache,globalScope:a.globalScope,depthCounter:a.depthCounter+1,console:a.console,lrucache:a.lrucache,localScope:{}};if(64<c.depthCounter)throw Error("Exceeded maximum function depth");
return da(b,c,e)})}function oa(a){return function(){var c={applicationCache:void 0===a.context.applicationCache?null:a.context.applicationCache,spatialReference:a.context.spatialReference,console:a.context.console,lrucache:a.context.lrucache,localScope:{},depthCounter:a.context.depthCounter+1,globalScope:a.context.globalScope};if(64<c.depthCounter)throw Error("Exceeded maximum function depth");return da(a.definition,c,arguments)}}function ga(a){console.log(a)}Object.defineProperty(e,"__esModule",
{value:!0});var la=0,Z={};n.registerFunctions(Z,F);r.registerFunctions(Z,F);p.registerFunctions(Z,F);g.registerFunctions(Z,F);t.registerFunctions(Z,F);q.registerFunctions(Z,F);Z["typeof"]=function(a,b){return F(a,b,function(a,b,d){c.pcCheck(d,1,1);a=O(d[0]);if("Unrecognised Type"===a)throw Error("Unrecognised Type");return a})};Z.iif=function(a,b){try{c.pcCheck(null===b.arguments?[]:b.arguments,3,3);var d=C(a,b.arguments[0]);if(!1===c.isBoolean(d))throw Error("IF Function must have a boolean test condition");
var e=C(a,b.arguments[1]),f=C(a,b.arguments[2]);return!0===d?e:f}catch(ua){throw ua;}};Z.decode=function(a,c){try{if(2>c.arguments.length)throw Error("Missing Parameters");if(2===c.arguments.length)return C(a,c.arguments[1]);if(0===(c.arguments.length-1)%2)throw Error("Must have a default value result.");var b=C(a,c.arguments[0]);return J(a,c,1,b)}catch(ra){throw ra;}};Z.when=function(a,b){try{if(3>b.arguments.length)throw Error("Missing Parameters");if(0===b.arguments.length%2)throw Error("Must have a default value result.");
var d=C(a,b.arguments[0]);if(!1===c.isBoolean(d))throw Error("WHEN needs boolean test conditions");return fa(a,b,0,d)}catch(ra){throw ra;}};Z.top=function(a,b){return F(a,b,function(a,b,d){c.pcCheck(d,2,2);if(c.isArray(d[0]))return c.toNumber(d[1])>=d[0].length?d[0].slice(0):d[0].slice(0,c.toNumber(d[1]));if(c.isImmutableArray(d[0]))return c.toNumber(d[1])>=d[0].length()?d[0].slice(0):d[0].slice(0,c.toNumber(d[1]));throw Error("Top cannot accept this parameter type");})};Z.first=function(a,b){return F(a,
b,function(a,b,d){c.pcCheck(d,1,1);return c.isArray(d[0])?0===d[0].length?null:d[0][0]:c.isImmutableArray(d[0])?0===d[0].length()?null:d[0].get(0):null})};Z.sort=function(a,b){return F(a,b,function(a,b,d){c.pcCheck(d,1,2);a=d[0];c.isImmutableArray(a)&&(a=a.toArray());if(!1===c.isArray(a))throw Error("Illegal Argument");if(1<d.length){if(!1===c.isFunctionParameter(d[1]))throw Error("Illegal Argument");var e=oa(d[1]);return a=H(a,function(a,c){return e(a,c)})}if(0===a.length)return[];d={};for(b=0;b<
a.length;b++){var f=O(a[b]);""!==f&&(d[f]=!0)}if(!0===d.Array||!0===d.Dictionary||!0===d.Feature||!0===d.Point||!0===d.Polygon||!0===d.Polyline||!0===d.Multipoint||!0===d.Extent||!0===d.Function)return a.slice(0);b=0;var f="",g;for(g in d)b++,f=g;return a=1<b||"String"===f?H(a,function(a,b){if(null===a||void 0===a||a===c.voidOperation)return null===b||void 0===b||b===c.voidOperation?0:1;if(null===b||void 0===b||b===c.voidOperation)return-1;a=c.toString(a);b=c.toString(b);return a<b?-1:a===b?0:1}):
"Number"===f?H(a,function(a,c){return a-c}):"Boolean"===f?H(a,function(a,c){return a===c?0:c?-1:1}):"Date"===f?H(a,function(a,c){return c-a}):a.slice(0)})};for(var ja in Z)Z[ja]={value:new c.NativeFunction(Z[ja]),valueset:!0,node:null};var ea=function(){};ea.prototype=Z;ea.prototype.infinity={value:Number.POSITIVE_INFINITY,valueset:!0,node:null};ea.prototype.pi={value:Math.PI,valueset:!0,node:null};e.functionHelper={fixSpatialReference:c.fixSpatialReference,parseArguments:B,standardFunction:F};e.extend=
function(a){for(var b={mode:"sync",compiled:!1,functions:{},signatures:[],standardFunction:F,evaluateIdentifier:M,arcadeCustomFunctionHandler:oa},d=0;d<a.length;d++)a[d].registerFunctions(b);for(var e in b.functions)Z[e]={value:new c.NativeFunction(b.functions[e]),valueset:!0,node:null},ea.prototype[e]=Z[e];for(d=0;d<b.signatures.length;d++)f.addFunctionDeclaration(b.signatures[d],"async")};e.executeScript=function(a,b,e){e||(e=new A({wkid:102100}));var f=b.vars,g=b.customfunctions,h=new ea;f||(f=
{});g||(g={});var p=new d({newline:"\n",tab:"\t",singlequote:"'",doublequote:'"',forwardslash:"/",backwardslash:"\\"});p.immutable=!1;h.textformatting={value:p,valueset:!0,node:null};for(var n in g)h[n]={value:new c.NativeFunction(g[n]),native:!0,valueset:!0,node:null};for(n in f)h[n]=f[n]&&"esri.Graphic"===f[n].declaredClass?{value:k.createFromGraphic(f[n]),valueset:!0,node:null}:{value:f[n],valueset:!0,node:null};a=C({spatialReference:e,globalScope:h,localScope:null,console:b.console?b.console:
ga,lrucache:b.lrucache,depthCounter:1,applicationCache:void 0===b.applicationCache?null:b.applicationCache},a.body[0].body);a instanceof c.ReturnResult&&(a=a.value);a instanceof c.ImplicitResult&&(a=a.value);a===c.voidOperation&&(a=null);if(a===c.breakResult)throw Error("Cannot return BREAK");if(a===c.continueResult)throw Error("Cannot return CONTINUE");if(a instanceof l)throw Error("Cannot return FUNCTION");if(a instanceof c.NativeFunction)throw Error("Cannot return FUNCTION");return a};e.extractFieldLiterals=
function(a,c){void 0===c&&(c=!1);return f.findFieldLiterals(a,c)};e.validateScript=function(a,c){return f.validateScript(a,c,"simple")};e.referencesMember=function(a,c){return f.referencesMember(a,c)};e.referencesFunction=function(a,c){return f.referencesFunction(a,c)};e.findFunctionCalls=function(a){return f.findFunctionCalls(a,!1)}})},"esri/arcade/parser":function(){define(["require","exports","./treeAnalysis","./lib/esprima"],function(b,e,m,d){Object.defineProperty(e,"__esModule",{value:!0});e.parseScript=
function(b,e){void 0===e&&(e=[]);b=d.parse("function _() { "+b+"\n}");if(null===b.body||void 0===b.body)throw Error("No formula provided.");if(0===b.body.length)throw Error("No formula provided.");if(0===b.body.length)throw Error("No formula provided.");if("BlockStatement"!==b.body[0].body.type)throw Error("Invalid formula content.");var h=m.validateLanguage(b);if(""!==h)throw Error(h);m.findScriptDependencies(b,e);return b};e.scriptCheck=function(b,e,h,a,c){var f=[];try{var n=d.parse("function _() { "+
b+"\n}",{tolerant:!0,loc:!0}),g=n.errors;if(0<g.length)for(var k=0;k<g.length;k++)f.push({line:g[k].lineNumber,character:g[k].column,reason:g[k].description});var p=m.checkScript(n,e,h,a,c);for(e=0;e<p.length;e++)f.push(p[e])}catch(t){try{"Unexpected token }"===t.description?(t.index=("function _() { "+b+"\n}").length-1,f.push({line:t.lineNumber,character:t.column,reason:"Unexpected end of script"})):f.push({line:t.lineNumber,character:t.column,reason:t.description})}catch(r){}}return f};e.extractFieldLiterals=
function(b,d){void 0===d&&(d=!1);return m.findFieldLiterals(b,d)};e.validateScript=function(b,d,e){return m.validateScript(b,d,e)};e.referencesMember=function(b,d){return m.referencesMember(b,d)};e.referencesFunction=function(b,d){return m.referencesFunction(b,d)}})},"esri/arcade/lib/esprima":function(){(function(b,e){"function"===typeof define&&define.amd?define(["exports"],e):"undefined"!==typeof exports?e(exports):e(b.esprima={})})(this,function(b){function e(a,c){if(!a)throw Error("ASSERT: "+
c);}function m(a){return 48<=a&&57>=a}function d(a){return 0<="0123456789abcdefABCDEF".indexOf(a)}function k(a){return 0<="01234567".indexOf(a)}function l(a){return 10===a||13===a||8232===a||8233===a}function h(a){return 36===a||95===a||65<=a&&90>=a||97<=a&&122>=a||92===a||128<=a&&db.NonAsciiIdentifierStart.test(String.fromCharCode(a))}function a(a){return 36===a||95===a||65<=a&&90>=a||97<=a&&122>=a||48<=a&&57>=a||92===a||128<=a&&db.NonAsciiIdentifierPart.test(String.fromCharCode(a))}function c(a){a=
a.toLowerCase();switch(a.length){case 2:return"if"===a||"in"===a;case 3:return"var"===a||"for"===a;case 4:return"else"===a;case 5:return"break"===a;case 6:return"return"===a;case 8:return"function"===a.toLowerCase()||"continue"===a;default:return!1}}function f(a,c,b,d,f){e("number"===typeof b,"Comment must have valid position");Y.lastCommentStart>=b||(Y.lastCommentStart=b,a={type:a,value:c},L.range&&(a.range=[b,d]),L.loc&&(a.loc=f),L.comments.push(a),L.attachComment&&(L.leadingComments.push(a),L.trailingComments.push(a)))}
function n(a){var c,b,d;c=D-a;for(b={start:{line:ba,column:D-X-a}};D<ka;)if(d=K.charCodeAt(D),++D,l(d)){L.comments&&(a=K.slice(c+a,D-1),b.end={line:ba,column:D-X-1},f("Line",a,c,D-1,b));13===d&&10===K.charCodeAt(D)&&++D;++ba;X=D;return}L.comments&&(a=K.slice(c+a,D),b.end={line:ba,column:D-X},f("Line",a,c,D,b))}function g(){var a,c;for(c=0===D;D<ka;)if(a=K.charCodeAt(D),32===a||9===a||11===a||12===a||160===a||5760<=a&&0<=[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,
65279].indexOf(a))++D;else if(l(a))++D,13===a&&10===K.charCodeAt(D)&&++D,++ba,X=D,c=!0;else if(47===a)if(a=K.charCodeAt(D+1),47===a)++D,++D,n(2),c=!0;else if(42===a){++D;++D;a:{var b=a=void 0,d=void 0,d=void 0;L.comments&&(a=D-2,b={start:{line:ba,column:D-X-2}});for(;D<ka;)if(d=K.charCodeAt(D),l(d))13===d&&10===K.charCodeAt(D+1)&&++D,++ba,++D,X=D,D>=ka&&M();else{if(42===d&&47===K.charCodeAt(D+1)){++D;++D;L.comments&&(d=K.slice(a+2,D-2),b.end={line:ba,column:D-X},f("Block",d,a,D,b));break a}++D}M()}}else break;
else if(c&&45===a)if(45===K.charCodeAt(D+1)&&62===K.charCodeAt(D+2))D+=3,n(3);else break;else if(60===a)if("!--"===K.slice(D+1,D+4))++D,++D,++D,++D,n(4);else break;else break}function q(a){var c,b,e=0;c="u"===a?4:2;for(a=0;a<c;++a)if(D<ka&&d(K[D]))b=K[D++],e=16*e+"0123456789abcdef".indexOf(b.toLowerCase());else return"";return String.fromCharCode(e)}function p(){var c,b;c=K.charCodeAt(D++);b=String.fromCharCode(c);92===c&&(117!==K.charCodeAt(D)&&M(),++D,(c=q("u"))&&"\\"!==c&&h(c.charCodeAt(0))||M(),
b=c);for(;D<ka;){c=K.charCodeAt(D);if(!a(c))break;++D;b+=String.fromCharCode(c);92===c&&(b=b.substr(0,b.length-1),117!==K.charCodeAt(D)&&M(),++D,(c=q("u"))&&"\\"!==c&&a(c.charCodeAt(0))||M(),b+=c)}return b}function t(){var a=D,c=K.charCodeAt(D),b,d=K[D];switch(c){case 46:case 40:case 41:case 59:case 44:case 123:case 125:case 91:case 93:case 58:case 63:case 126:return++D,L.tokenize&&(40===c?L.openParenToken=L.tokens.length:123===c&&(L.openCurlyToken=L.tokens.length)),{type:N.Punctuator,value:String.fromCharCode(c),
lineNumber:ba,lineStart:X,start:a,end:D};default:if(b=K.charCodeAt(D+1),61===b)switch(c){case 43:case 45:case 47:case 60:case 62:case 94:case 124:case 37:case 38:case 42:return D+=2,{type:N.Punctuator,value:String.fromCharCode(c)+String.fromCharCode(b),lineNumber:ba,lineStart:X,start:a,end:D};case 33:case 61:return D+=2,61===K.charCodeAt(D)&&++D,{type:N.Punctuator,value:K.slice(a,D),lineNumber:ba,lineStart:X,start:a,end:D}}}c=K.substr(D,4);if("\x3e\x3e\x3e\x3d"===c)return D+=4,{type:N.Punctuator,
value:c,lineNumber:ba,lineStart:X,start:a,end:D};c=c.substr(0,3);if("\x3e\x3e\x3e"===c||"\x3c\x3c\x3d"===c||"\x3e\x3e\x3d"===c)return D+=3,{type:N.Punctuator,value:c,lineNumber:ba,lineStart:X,start:a,end:D};c=c.substr(0,2);if(d===c[1]&&0<="+-\x3c\x3e\x26|".indexOf(d)||"\x3d\x3e"===c)return D+=2,{type:N.Punctuator,value:c,lineNumber:ba,lineStart:X,start:a,end:D};if(0<="\x3c\x3e\x3d!+-*%\x26|^/".indexOf(d))return++D,{type:N.Punctuator,value:d,lineNumber:ba,lineStart:X,start:a,end:D};M()}function r(){var a,
c,b;b=K[D];e(m(b.charCodeAt(0))||"."===b,"Numeric literal must start with a decimal digit or a decimal point");c=D;a="";if("."!==b){a=K[D++];b=K[D];if("0"===a){if("x"===b||"X"===b){++D;for(a="";D<ka&&d(K[D]);)a+=K[D++];0===a.length&&M();h(K.charCodeAt(D))&&M();return{type:N.NumericLiteral,value:parseInt("0x"+a,16),lineNumber:ba,lineStart:X,start:c,end:D}}if("b"===b||"B"===b){++D;for(b="";D<ka;){a=K[D];if("0"!==a&&"1"!==a)break;b+=K[D++]}0===b.length&&M();D<ka&&(a=K.charCodeAt(D),(h(a)||m(a))&&M());
return{type:N.NumericLiteral,value:parseInt(b,2),lineNumber:ba,lineStart:X,start:c,end:D}}if("o"===b||"O"===b){k(b)?(b=!0,a="0"+K[D++]):(b=!1,++D,a="");for(;D<ka&&k(K[D]);)a+=K[D++];b||0!==a.length||M();(h(K.charCodeAt(D))||m(K.charCodeAt(D)))&&M();return{type:N.NumericLiteral,value:parseInt(a,8),octal:b,lineNumber:ba,lineStart:X,start:c,end:D}}}for(;m(K.charCodeAt(D));)a+=K[D++];b=K[D]}if("."===b){for(a+=K[D++];m(K.charCodeAt(D));)a+=K[D++];b=K[D]}if("e"===b||"E"===b){a+=K[D++];b=K[D];if("+"===b||
"-"===b)a+=K[D++];if(m(K.charCodeAt(D)))for(;m(K.charCodeAt(D));)a+=K[D++];else M()}h(K.charCodeAt(D))&&M();return{type:N.NumericLiteral,value:parseFloat(a),lineNumber:ba,lineStart:X,start:c,end:D}}function v(){S=null;g();R("Regular Expression language structures not supported")}function u(){g();v()}function z(){var a;a=L.tokens[L.tokens.length-1];if(!a)return u();if("Punctuator"===a.type){if("]"===a.value)return t();if(")"===a.value)return a=L.tokens[L.openParenToken-1],!a||"Keyword"!==a.type||"if"!==
a.value.toLowerCase()&&"while"!==a.value.toLowerCase()&&"for"!==a.value.toLowerCase()&&"with"!==a.value.toLowerCase()?t():u();if("}"===a.value){if(L.tokens[L.openCurlyToken-3]&&"Keyword"===L.tokens[L.openCurlyToken-3].type){if(a=L.tokens[L.openCurlyToken-4],!a)return t()}else if(L.tokens[L.openCurlyToken-4]&&"Keyword"===L.tokens[L.openCurlyToken-4].type){if(a=L.tokens[L.openCurlyToken-5],!a)return u()}else return t();if(0<=Ya.indexOf(a.value))return t()}return u()}return"Keyword"===a.type&&"this"!==
a.value?u():t()}function y(){var b;g();if(D>=ka)return{type:N.EOF,lineNumber:ba,lineStart:X,start:D,end:D};b=K.charCodeAt(D);if(h(b)){var f;b=D;if(92===K.charCodeAt(D))f=p();else a:{var n;for(f=D++;D<ka;){n=K.charCodeAt(D);if(92===n){D=f;f=p();break a}if(a(n))++D;else break}f=K.slice(f,D)}return{type:1===f.length?N.Identifier:c(f)?N.Keyword:"null"===f.toLowerCase()?N.NullLiteral:"true"===f.toLowerCase()||"false"===f.toLowerCase()?N.BooleanLiteral:N.Identifier,value:f,lineNumber:ba,lineStart:X,start:b,
end:D}}if(40===b||41===b||59===b)return t();if(39===b||34===b){var u="",v,y,x;n=!1;var w,F;w=ba;F=X;b=K[D];e("'"===b||'"'===b,"String literal must starts with a quote");f=D;for(++D;D<ka;)if(v=K[D++],v===b){b="";break}else if("\\"===v)if((v=K[D++])&&l(v.charCodeAt(0)))++ba,"\r"===v&&"\n"===K[D]&&++D,X=D;else switch(v){case "u":case "x":if("{"===K[D]){++D;y=v=void 0;v=K[D];y=0;for("}"===v&&M();D<ka;){v=K[D++];if(!d(v))break;y=16*y+"0123456789abcdef".indexOf(v.toLowerCase())}(1114111<y||"}"!==v)&&M();
v=65535>=y?String.fromCharCode(y):String.fromCharCode((y-65536>>10)+55296,(y-65536&1023)+56320);u+=v}else x=D,(y=q(v))?u+=y:(D=x,u+=v);break;case "n":u+="\n";break;case "r":u+="\r";break;case "t":u+="\t";break;case "b":u+="\b";break;case "f":u+="\f";break;case "v":u+="\x0B";break;default:k(v)?(y="01234567".indexOf(v),0!==y&&(n=!0),D<ka&&k(K[D])&&(n=!0,y=8*y+"01234567".indexOf(K[D++]),0<="0123".indexOf(v)&&D<ka&&k(K[D])&&(y=8*y+"01234567".indexOf(K[D++]))),u+=String.fromCharCode(y)):u+=v}else if(l(v.charCodeAt(0)))break;
else u+=v;""!==b&&M();return{type:N.StringLiteral,value:u,octal:n,startLineNumber:w,startLineStart:F,lineNumber:ba,lineStart:X,start:f,end:D}}return 46===b?m(K.charCodeAt(D+1))?r():t():m(b)?r():L.tokenize&&47===b?z():t()}function x(){var a,c,b;g();a={start:{line:ba,column:D-X}};c=y();a.end={line:ba,column:D-X};c.type!==N.EOF&&(b=K.slice(c.start,c.end),a={type:Ha[c.type],value:b,range:[c.start,c.end],loc:a},c.regex&&(a.regex={pattern:c.regex.pattern,flags:c.regex.flags}),L.tokens.push(a));return c}
function w(){var a;a=S;D=a.end;ba=a.lineNumber;X=a.lineStart;S="undefined"!==typeof L.tokens?x():y();D=a.end;ba=a.lineNumber;X=a.lineStart;return a}function A(){var a,c,b;a=D;c=ba;b=X;S="undefined"!==typeof L.tokens?x():y();D=a;ba=c;X=b}function B(){this.line=ba;this.column=D-X}function F(){this.start=new B;this.end=null}function C(a){this.start=a.type===N.StringLiteral?{line:a.startLineNumber,column:a.start-a.startLineStart}:{line:a.lineNumber,column:a.start-a.lineStart};this.end=null}function E(){D=
S.start;S.type===N.StringLiteral?(ba=S.startLineNumber,X=S.startLineStart):(ba=S.lineNumber,X=S.lineStart);L.range&&(this.range=[D,0]);L.loc&&(this.loc=new F)}function G(a){L.range&&(this.range=[a.start,0]);L.loc&&(this.loc=new C(a))}function Q(){var a,c,b,d;a=D;c=ba;b=X;g();d=ba!==c;D=a;ba=c;X=b;return d}function V(a,c,b){var d=Error("Line "+a+": "+b);d.index=c;d.lineNumber=a;d.column=c-X+1;d.description=b;return d}function R(a){var c,b;c=Array.prototype.slice.call(arguments,1);b=a.replace(/%(\d)/g,
function(a,b){e(b<c.length,"Message reference must be in range");return c[b]});throw V(ba,D,b);}function I(a){var c,b;c=Array.prototype.slice.call(arguments,1);b=a.replace(/%(\d)/g,function(a,b){e(b<c.length,"Message reference must be in range");return c[b]});b=V(ba,D,b);if(L.errors)L.errors.push(b);else throw b;}function W(a,c){var b=ha.UnexpectedToken;a&&(b=c?c:a.type===N.EOF?ha.UnexpectedEOS:a.type===N.Identifier?ha.UnexpectedIdentifier:a.type===N.NumericLiteral?ha.UnexpectedNumber:a.type===N.StringLiteral?
ha.UnexpectedString:ha.UnexpectedToken);b=b.replace("%0",a?a.value:"ILLEGAL");return a&&"number"===typeof a.lineNumber?V(a.lineNumber,a.start,b):V(ba,D,b)}function M(a,c){throw W(a,c);}function U(a,c){a=W(a,c);if(L.errors)L.errors.push(a);else throw a;}function O(a){var c=w();c.type===N.Punctuator&&c.value===a||M(c)}function J(){var a;L.errors?(a=S,a.type===N.Punctuator&&","===a.value?w():a.type===N.Punctuator&&";"===a.value?(w(),U(a)):U(a,ha.UnexpectedToken)):O(",")}function fa(a){var c=w();c.type===
N.Keyword&&c.value.toLowerCase()===a.toLowerCase()||M(c)}function H(a){return S.type===N.Punctuator&&S.value===a}function da(a){return S.type===N.Keyword&&S.value.toLowerCase()===a.toLowerCase()}function aa(){var a;59===K.charCodeAt(D)||H(";")?w():(a=ba,g(),ba===a&&(S.type===N.EOF||H("}")||M(S)))}function oa(a){return a.type===ca.Identifier||a.type===ca.MemberExpression}function ga(a,c){var b,d=new E;c=ia;b=Ka();ia=c;return d.finishFunctionExpression(null,a,[],b)}function la(){var a,c;a=ia;ia=!0;
c=Ga();c=ga(c.params);ia=a;return c}function Z(){var a,c=new E;a=w();return a.type===N.StringLiteral||a.type===N.NumericLiteral?(ia&&a.octal&&U(a,ha.StrictOctalLiteral),c.finishLiteral(a)):c.finishIdentifier(a.value)}function ja(){var a,c,b,d=new E;a=S;if(a.type===N.Identifier)return c=Z(),"get"!==a.value||H(":")||H("(")?"set"!==a.value||H(":")||H("(")?H(":")?(w(),a=T(),d.finishProperty("init",c,a,!1,!1)):H("(")?(a=la(),d.finishProperty("init",c,a,!0,!1)):d.finishProperty("init",c,c,!1,!0):(c=Z(),
O("("),a=S,a.type!==N.Identifier?(O(")"),U(a),a=ga([])):(b=[ya()],O(")"),a=ga(b,a)),d.finishProperty("set",c,a,!1,!1)):(c=Z(),O("("),O(")"),a=ga([]),d.finishProperty("get",c,a,!1,!1));if(a.type===N.EOF||a.type===N.Punctuator)M(a);else{c=Z();if(H(":"))return w(),a=T(),d.finishProperty("init",c,a,!1,!1);if(H("("))return a=la(),d.finishProperty("init",c,a,!0,!1);M(w())}}function ea(a){var c=[],b,d,e={},f=String,g=new E;for(!0!==a&&O("{");!H("}");)a=ja(),b=a.key.type===ca.Identifier?a.key.name:f(a.key.value),
d="init"===a.kind?La.Data:"get"===a.kind?La.Get:La.Set,b="$"+b,Object.prototype.hasOwnProperty.call(e,b)?(e[b]===La.Data?ia&&d===La.Data?I(ha.StrictDuplicateProperty):d!==La.Data&&I(ha.AccessorDataProperty):d===La.Data?I(ha.AccessorDataProperty):e[b]&d&&I(ha.AccessorGetSet),e[b]|=d):e[b]=d,c.push(a),H("}")||J();O("}");return g.finishObjectExpression(c)}function sa(){var a,c,b,d;if(H("("))return O("("),H(")")?(w(),c=Oa.ArrowParameterPlaceHolder):(++Y.parenthesisCount,c=xa(),O(")")),c;if(H("[")){c=
[];var e=new E;for(O("[");!H("]");)H(",")?(w(),c.push(null)):(c.push(T()),H("]")||O(","));w();return e.finishArrayExpression(c)}if(H("{"))return ea();a=S.type;d=new E;if(a===N.Identifier)b=d.finishIdentifier(w().value);else if(a===N.StringLiteral||a===N.NumericLiteral)ia&&S.octal&&U(S,ha.StrictOctalLiteral),b=d.finishLiteral(w());else if(a===N.Keyword){if(da("function")){d=null;var f;b=[];var g=[],h,p=new E;fa("function");H("(")||(d=ya());f=Ga(c);b=f.params;g=f.defaults;a=f.stricted;c=f.firstRestricted;
f.message&&(e=f.message);h=ia;f=Ka();ia&&c&&M(c,e);ia&&a&&U(a,e);ia=h;return p.finishFunctionExpression(d,b,g,f)}da("this")?(w(),b=d.finishThisExpression()):M(w())}else a===N.BooleanLiteral?(c=w(),c.value="true"===c.value.toLowerCase(),b=d.finishLiteral(c)):a===N.NullLiteral?(c=w(),c.value=null,b=d.finishLiteral(c)):H("/")||H("/\x3d")?(b="undefined"!==typeof L.tokens?d.finishLiteral(u()):d.finishLiteral(v()),A()):M(w());return b}function pa(){var a=[];O("(");if(!H(")"))for(;D<ka;){a.push(T());if(H(")"))break;
J()}O(")");return a}function Ea(){O(".");var a,c=new E;a=w();a.type===N.Identifier||a.type===N.Keyword||a.type===N.BooleanLiteral||a.type===N.NullLiteral||M(a);return c.finishIdentifier(a.value)}function ra(){var a;O("[");a=xa();O("]");return a}function na(){var a,c,b=new E;fa("new");var d;e(Y.allowIn,"callee of new expression always allow in keyword.");d=S;for(a=da("new")?na():sa();;)if(H("["))c=ra(),a=(new G(d)).finishMemberExpression("[",a,c);else if(H("."))c=Ea(),a=(new G(d)).finishMemberExpression(".",
a,c);else break;c=H("(")?pa():[];return b.finishNewExpression(a,c)}function ua(){var a,c,b=S,d,e=Y.allowIn;c=S;Y.allowIn=!0;for(a=da("new")?na():sa();;)if(H("."))d=Ea(),a=(new G(c)).finishMemberExpression(".",a,d);else if(H("("))d=pa(),a=(new G(c)).finishCallExpression(a,d);else if(H("["))d=ra(),a=(new G(c)).finishMemberExpression("[",a,d);else break;Y.allowIn=e;S.type!==N.Punctuator||!H("++")&&!H("--")||Q()||(oa(a)||I(ha.InvalidLHSInAssignment),c=w(),a=(new G(b)).finishPostfixExpression(c.value,
a));return a}function qa(){var a,c,b;S.type!==N.Punctuator&&S.type!==N.Keyword?c=ua():H("++")||H("--")?(b=S,a=w(),c=qa(),oa(c)||I(ha.InvalidLHSInAssignment),c=(new G(b)).finishUnaryExpression(a.value,c)):H("+")||H("-")||H("~")||H("!")?(b=S,a=w(),c=qa(),c=(new G(b)).finishUnaryExpression(a.value,c)):da("delete")||da("void")||da("typeof")?(b=S,a=w(),c=qa(),c=(new G(b)).finishUnaryExpression(a.value,c),ia&&"delete"===c.operator&&c.argument.type===ca.Identifier&&I(ha.StrictDelete)):c=ua();return c}function Ca(a,
c){var b=0;if(a.type!==N.Punctuator&&a.type!==N.Keyword)return 0;switch(a.value){case "||":b=1;break;case "\x26\x26":b=2;break;case "|":b=3;break;case "^":b=4;break;case "\x26":b=5;break;case "\x3d\x3d":case "!\x3d":case "\x3d\x3d\x3d":case "!\x3d\x3d":b=6;break;case "\x3c":case "\x3e":case "\x3c\x3d":case "\x3e\x3d":case "instanceof":b=7;break;case "in":b=c?7:0;break;case "\x3c\x3c":case "\x3e\x3e":case "\x3e\x3e\x3e":b=8;break;case "+":case "-":b=9;break;case "*":case "/":case "%":b=11}return b}
function wa(){var a,c,b,d,e,f;a=S;c=qa();if(c===Oa.ArrowParameterPlaceHolder)return c;b=S;d=Ca(b,Y.allowIn);if(0===d)return c;b.prec=d;w();a=[a,S];f=qa();for(e=[c,b,f];0<(d=Ca(S,Y.allowIn));){for(;2<e.length&&d<=e[e.length-2].prec;)f=e.pop(),b=e.pop().value,c=e.pop(),a.pop(),c=(new G(a[a.length-1])).finishBinaryExpression(b,c,f),e.push(c);b=w();b.prec=d;e.push(b);a.push(S);c=qa();e.push(c)}d=e.length-1;c=e[d];for(a.pop();1<d;)c=(new G(a.pop())).finishBinaryExpression(e[d-1].value,e[d-2],c),d-=2;return c}
function Ta(a){var c,b,d,e,f,g,h;e=[];f=[];g=0;h={paramSet:{}};c=0;for(b=a.length;c<b;c+=1)if(d=a[c],d.type===ca.Identifier)e.push(d),f.push(null),Ia(h,d,d.name);else if(d.type===ca.AssignmentExpression)e.push(d.left),f.push(d.right),++g,Ia(h,d.left,d.left.name);else return null;h.message===ha.StrictParamDupe&&(a=ia?h.stricted:h.firstRestricted,M(a,h.message));0===g&&(f=[]);return{params:e,defaults:f,rest:null,stricted:h.stricted,firstRestricted:h.firstRestricted,message:h.message}}function T(){var a,
c,b,d,e;a=Y.parenthesisCount;c=e=S;var f,g;g=S;b=wa();b!==Oa.ArrowParameterPlaceHolder&&H("?")&&(w(),f=Y.allowIn,Y.allowIn=!0,c=T(),Y.allowIn=f,O(":"),f=T(),b=(new G(g)).finishConditionalExpression(b,c,f));if(b===Oa.ArrowParameterPlaceHolder||H("\x3d\x3e"))if(Y.parenthesisCount===a||Y.parenthesisCount===a+1)if(b.type===ca.Identifier?d=Ta([b]):b.type===ca.AssignmentExpression?d=Ta([b]):b.type===ca.SequenceExpression?d=Ta(b.expressions):b===Oa.ArrowParameterPlaceHolder&&(d=Ta([])),d)return a=d,e=new G(e),
O("\x3d\x3e"),d=ia,b=H("{")?Ka():T(),ia&&a.firstRestricted&&M(a.firstRestricted,a.message),ia&&a.stricted&&U(a.stricted,a.message),ia=d,e.finishArrowFunctionExpression(a.params,a.defaults,b,b.type!==ca.BlockStatement);S.type!==N.Punctuator?a=!1:(a=S.value,a="\x3d"===a||"*\x3d"===a||"/\x3d"===a||"%\x3d"===a||"+\x3d"===a||"-\x3d"===a||"\x3c\x3c\x3d"===a||"\x3e\x3e\x3d"===a||"\x3e\x3e\x3e\x3d"===a||"\x26\x3d"===a||"^\x3d"===a||"|\x3d"===a);a&&(oa(b)||I(ha.InvalidLHSInAssignment),c=w(),a=T(),b=(new G(e)).finishAssignmentExpression(c.value,
b,a));return b}function xa(){var a,c=S;a=T();if(H(",")){for(a=[a];D<ka&&H(",");)w(),a.push(T());a=(new G(c)).finishSequenceExpression(a)}return a}function ya(){var a,c=new E;a=w();a.type!==N.Identifier&&M(a);return c.finishIdentifier(a.value)}function hb(a){var c=null,b,d=new E;b=ya();"const"===a?(O("\x3d"),c=T()):H("\x3d")&&(w(),c=T());return d.finishVariableDeclarator(b,c)}function Sa(a){var c=[];do{c.push(hb(a));if(!H(","))break;w()}while(D<ka);return c}function Da(a){var c=S.type,b,d;c===N.EOF&&
M(S);if(c===N.Punctuator&&"{"===S.value){if(a){O("{");var e=S;a=D;b=ba;d=X;w();c=H(":");S=e;D=a;ba=b;X=d;if((S.type===N.Identifier||S.type===N.StringLiteral)&&c)return ea(!0);a=new E;for(b=[];D<ka&&!H("}");){d=Ja();if("undefined"===typeof d)break;b.push(d)}O("}");return a.finishBlockStatement(b)}return ea()}a=new E;if(c===N.Punctuator)switch(S.value){case ";":return a=new E,O(";"),a.finishEmptyStatement();case "(":return b=xa(),aa(),a.finishExpressionStatement(b)}else if(c===N.Keyword)switch(S.value.toLowerCase()){case "break":return b=
null,fa("break"),59===K.charCodeAt(D)?(w(),Y.inIteration||Y.inSwitch||R(ha.IllegalBreak),a=a.finishBreakStatement(null)):Q()?(Y.inIteration||Y.inSwitch||R(ha.IllegalBreak),a=a.finishBreakStatement(null)):(S.type===N.Identifier&&(b=ya(),d="$"+b.name,Object.prototype.hasOwnProperty.call(Y.labelSet,d)||R(ha.UnknownLabel,b.name)),aa(),null!==b||Y.inIteration||Y.inSwitch||R(ha.IllegalBreak),a=a.finishBreakStatement(b)),a;case "continue":return b=null,fa("continue"),59===K.charCodeAt(D)?(w(),Y.inIteration||
R(ha.IllegalContinue),a=a.finishContinueStatement(null)):Q()?(Y.inIteration||R(ha.IllegalContinue),a=a.finishContinueStatement(null)):(S.type===N.Identifier&&(b=ya(),d="$"+b.name,Object.prototype.hasOwnProperty.call(Y.labelSet,d)||R(ha.UnknownLabel,b.name)),aa(),null!==b||Y.inIteration||R(ha.IllegalContinue),a=a.finishContinueStatement(b)),a;case "for":var f,g,p;g=Y.allowIn;f=c=e=null;fa("for");O("(");if(H(";"))w();else{if(da("var")){Y.allowIn=!1;var n=new E;f=w();p=Sa();f=n.finishVariableDeclaration(p,
f.value);Y.allowIn=g;1===f.declarations.length&&da("in")&&(w(),b=f,d=xa(),f=null)}else Y.allowIn=!1,f=xa(),Y.allowIn=g,da("in")&&(oa(f)||I(ha.InvalidLHSInForIn),w(),b=f,d=xa(),f=null);"undefined"===typeof b&&O(";")}"undefined"===typeof b&&(H(";")||(c=xa()),O(";"),H(")")||(e=xa()));O(")");p=Y.inIteration;Y.inIteration=!0;g=Da(!0);Y.inIteration=p;return"undefined"===typeof b?a.finishForStatement(f,c,e,g):a.finishForInStatement(b,d,g);case "function":return Wa(a);case "if":return fa("if"),O("("),b=xa(),
O(")"),d=Da(!0),da("else")?(w(),c=Da(!0)):c=null,a.finishIfStatement(b,d,c);case "return":return b=null,fa("return"),Y.inFunctionBody||I(ha.IllegalReturn),32===K.charCodeAt(D)&&h(K.charCodeAt(D+1))?(b=xa(),aa(),a=a.finishReturnStatement(b)):Q()?a=a.finishReturnStatement(null):(H(";")||H("}")||S.type===N.EOF||(b=xa()),aa(),a=a.finishReturnStatement(b)),a;case "var":return fa("var"),b=Sa(),aa(),a.finishVariableDeclaration(b,"var")}b=xa();if(b.type===ca.Identifier&&H(":"))return w(),c="$"+b.name,Object.prototype.hasOwnProperty.call(Y.labelSet,
c)&&R(ha.Redeclaration,"Label",b.name),Y.labelSet[c]=!0,d=Da(!1),delete Y.labelSet[c],a.finishLabeledStatement(b,d);aa();return a.finishExpressionStatement(b)}function Ka(){var a,c=[],b,d,e,f,g,h=new E;for(O("{");D<ka&&S.type===N.StringLiteral;){b=S;a=Ja();c.push(a);if(a.expression.type!==ca.Literal)break;a=K.slice(b.start+1,b.end-1);"use strict"===a?(ia=!0,d&&U(d,ha.StrictOctalLiteral)):!d&&b.octal&&(d=b)}b=Y.labelSet;d=Y.inIteration;e=Y.inSwitch;f=Y.inFunctionBody;g=Y.parenthesizedCount;Y.labelSet=
{};Y.inIteration=!1;Y.inSwitch=!1;Y.inFunctionBody=!0;for(Y.parenthesizedCount=0;D<ka&&!H("}");){a=Ja();if("undefined"===typeof a)break;c.push(a)}O("}");Y.labelSet=b;Y.inIteration=d;Y.inSwitch=e;Y.inFunctionBody=f;Y.parenthesizedCount=g;return h.finishBlockStatement(c)}function Ia(a,c,b){b="$"+b;ia?Object.prototype.hasOwnProperty.call(a.paramSet,b)&&(a.stricted=c,a.message=ha.StrictParamDupe):!a.firstRestricted&&Object.prototype.hasOwnProperty.call(a.paramSet,b)&&(a.firstRestricted=c,a.message=ha.StrictParamDupe);
a.paramSet[b]=!0}function Ga(a){a={params:[],defaultCount:0,defaults:[],firstRestricted:a};O("(");if(!H(")"))for(a.paramSet={};D<ka;){var c=a,b=void 0,d=void 0,e=void 0,b=S,d=ya();Ia(c,b,b.value);H("\x3d")&&(w(),e=T(),++c.defaultCount);c.params.push(d);c.defaults.push(e);if(H(")"))break;O(",")}O(")");0===a.defaultCount&&(a.defaults=[]);return{params:a.params,defaults:a.defaults,stricted:a.stricted,firstRestricted:a.firstRestricted,message:a.message}}function Wa(){var a,c=[],b=[],d,e,f,g,h,p=new E;
fa("function");a=ya();d=Ga(f);c=d.params;b=d.defaults;e=d.stricted;f=d.firstRestricted;d.message&&(g=d.message);h=ia;d=Ka();ia&&f&&M(f,g);ia&&e&&U(e,g);ia=h;return p.finishFunctionDeclaration(a,c,b,d)}function Ja(){if(S.type===N.Keyword)return"function"===S.value.toLowerCase()?Wa():Da(!1);if(S.type!==N.EOF)return Da(!1)}function cb(){var a,c,b,d=[];for(a=0;a<L.tokens.length;++a)c=L.tokens[a],b={type:c.type,value:c.value},c.regex&&(b.regex={pattern:c.regex.pattern,flags:c.regex.flags}),L.range&&(b.range=
c.range),L.loc&&(b.loc=c.loc),d.push(b);L.tokens=d}var N,Ha,Ya,ca,Oa,La,ha,db,K,ia,D,ba,X,ka,S,Y,L;N={BooleanLiteral:1,EOF:2,Identifier:3,Keyword:4,NullLiteral:5,NumericLiteral:6,Punctuator:7,StringLiteral:8,RegularExpression:9};Ha={};Ha[N.BooleanLiteral]="Boolean";Ha[N.EOF]="\x3cend\x3e";Ha[N.Identifier]="Identifier";Ha[N.Keyword]="Keyword";Ha[N.NullLiteral]="Null";Ha[N.NumericLiteral]="Numeric";Ha[N.Punctuator]="Punctuator";Ha[N.StringLiteral]="String";Ha[N.RegularExpression]="RegularExpression";
Ya="( { [ in typeof instanceof new return case delete throw void \x3d +\x3d -\x3d *\x3d /\x3d %\x3d \x3c\x3c\x3d \x3e\x3e\x3d \x3e\x3e\x3e\x3d \x26\x3d |\x3d ^\x3d , + - * / % ++ -- \x3c\x3c \x3e\x3e \x3e\x3e\x3e \x26 | ^ ! ~ \x26\x26 || ? : \x3d\x3d\x3d \x3d\x3d \x3e\x3d \x3c\x3d \x3c \x3e !\x3d !\x3d\x3d".split(" ");ca={AssignmentExpression:"AssignmentExpression",ArrayExpression:"ArrayExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",
CallExpression:"CallExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DoWhileStatement:"DoWhileStatement",EmptyStatement:"EmptyStatement",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForInStatement:"ForInStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",Identifier:"Identifier",IfStatement:"IfStatement",Literal:"Literal",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",
ObjectExpression:"ObjectExpression",Program:"Program",Property:"Property",ReturnStatement:"ReturnStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator"};Oa={ArrowParameterPlaceHolder:{type:"ArrowParameterPlaceHolder"}};La={Data:1,Get:2,Set:4};ha={UnexpectedToken:"Unexpected token %0",UnexpectedNumber:"Unexpected number",UnexpectedString:"Unexpected string",UnexpectedIdentifier:"Unexpected identifier",
UnexpectedReserved:"Unexpected reserved word",UnexpectedEOS:"Unexpected end of input",NewlineAfterThrow:"Illegal newline after throw",InvalidRegExp:"Invalid regular expression",UnterminatedRegExp:"Invalid regular expression: missing /",InvalidLHSInAssignment:"Invalid left-hand side in assignment",InvalidLHSInForIn:"Invalid left-hand side in for-in",MultipleDefaultsInSwitch:"More than one default clause in switch statement",NoCatchOrFinally:"Missing catch or finally after try",UnknownLabel:"Undefined label '%0'",
Redeclaration:"%0 '%1' has already been declared",IllegalContinue:"Illegal continue statement",IllegalBreak:"Illegal break statement",IllegalReturn:"Illegal return statement",StrictModeWith:"Strict mode code may not include a with statement",StrictCatchVariable:"Catch variable may not be eval or arguments in strict mode",StrictVarName:"Variable name may not be eval or arguments in strict mode",StrictParamName:"Parameter name eval or arguments is not allowed in strict mode",StrictParamDupe:"Strict mode function may not have duplicate parameter names",
StrictFunctionName:"Function name may not be eval or arguments in strict mode",StrictOctalLiteral:"Octal literals are not allowed in strict mode.",StrictDelete:"Delete of an unqualified identifier in strict mode.",StrictDuplicateProperty:"Duplicate data property in object literal not allowed in strict mode",AccessorDataProperty:"Object literal may not have data and accessor property with the same name",AccessorGetSet:"Object literal may not have multiple get/set accessors with the same name",StrictLHSAssignment:"Assignment to eval or arguments is not allowed in strict mode",
StrictLHSPostfix:"Postfix increment/decrement may not have eval or arguments operand in strict mode",StrictLHSPrefix:"Prefix increment/decrement may not have eval or arguments operand in strict mode",StrictReservedWord:"Use of future reserved word in strict mode"};db={NonAsciiIdentifierStart:/[\u00aa\u00b5\u00ba\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u02c1\u02c6-\u02d1\u02e0-\u02e4\u02ec\u02ee\u0370-\u0374\u0376\u0377\u037a-\u037d\u037f\u0386\u0388-\u038a\u038c\u038e-\u03a1\u03a3-\u03f5\u03f7-\u0481\u048a-\u052f\u0531-\u0556\u0559\u0561-\u0587\u05d0-\u05ea\u05f0-\u05f2\u0620-\u064a\u066e\u066f\u0671-\u06d3\u06d5\u06e5\u06e6\u06ee\u06ef\u06fa-\u06fc\u06ff\u0710\u0712-\u072f\u074d-\u07a5\u07b1\u07ca-\u07ea\u07f4\u07f5\u07fa\u0800-\u0815\u081a\u0824\u0828\u0840-\u0858\u08a0-\u08b2\u0904-\u0939\u093d\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098c\u098f\u0990\u0993-\u09a8\u09aa-\u09b0\u09b2\u09b6-\u09b9\u09bd\u09ce\u09dc\u09dd\u09df-\u09e1\u09f0\u09f1\u0a05-\u0a0a\u0a0f\u0a10\u0a13-\u0a28\u0a2a-\u0a30\u0a32\u0a33\u0a35\u0a36\u0a38\u0a39\u0a59-\u0a5c\u0a5e\u0a72-\u0a74\u0a85-\u0a8d\u0a8f-\u0a91\u0a93-\u0aa8\u0aaa-\u0ab0\u0ab2\u0ab3\u0ab5-\u0ab9\u0abd\u0ad0\u0ae0\u0ae1\u0b05-\u0b0c\u0b0f\u0b10\u0b13-\u0b28\u0b2a-\u0b30\u0b32\u0b33\u0b35-\u0b39\u0b3d\u0b5c\u0b5d\u0b5f-\u0b61\u0b71\u0b83\u0b85-\u0b8a\u0b8e-\u0b90\u0b92-\u0b95\u0b99\u0b9a\u0b9c\u0b9e\u0b9f\u0ba3\u0ba4\u0ba8-\u0baa\u0bae-\u0bb9\u0bd0\u0c05-\u0c0c\u0c0e-\u0c10\u0c12-\u0c28\u0c2a-\u0c39\u0c3d\u0c58\u0c59\u0c60\u0c61\u0c85-\u0c8c\u0c8e-\u0c90\u0c92-\u0ca8\u0caa-\u0cb3\u0cb5-\u0cb9\u0cbd\u0cde\u0ce0\u0ce1\u0cf1\u0cf2\u0d05-\u0d0c\u0d0e-\u0d10\u0d12-\u0d3a\u0d3d\u0d4e\u0d60\u0d61\u0d7a-\u0d7f\u0d85-\u0d96\u0d9a-\u0db1\u0db3-\u0dbb\u0dbd\u0dc0-\u0dc6\u0e01-\u0e30\u0e32\u0e33\u0e40-\u0e46\u0e81\u0e82\u0e84\u0e87\u0e88\u0e8a\u0e8d\u0e94-\u0e97\u0e99-\u0e9f\u0ea1-\u0ea3\u0ea5\u0ea7\u0eaa\u0eab\u0ead-\u0eb0\u0eb2\u0eb3\u0ebd\u0ec0-\u0ec4\u0ec6\u0edc-\u0edf\u0f00\u0f40-\u0f47\u0f49-\u0f6c\u0f88-\u0f8c\u1000-\u102a\u103f\u1050-\u1055\u105a-\u105d\u1061\u1065\u1066\u106e-\u1070\u1075-\u1081\u108e\u10a0-\u10c5\u10c7\u10cd\u10d0-\u10fa\u10fc-\u1248\u124a-\u124d\u1250-\u1256\u1258\u125a-\u125d\u1260-\u1288\u128a-\u128d\u1290-\u12b0\u12b2-\u12b5\u12b8-\u12be\u12c0\u12c2-\u12c5\u12c8-\u12d6\u12d8-\u1310\u1312-\u1315\u1318-\u135a\u1380-\u138f\u13a0-\u13f4\u1401-\u166c\u166f-\u167f\u1681-\u169a\u16a0-\u16ea\u16ee-\u16f8\u1700-\u170c\u170e-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176c\u176e-\u1770\u1780-\u17b3\u17d7\u17dc\u1820-\u1877\u1880-\u18a8\u18aa\u18b0-\u18f5\u1900-\u191e\u1950-\u196d\u1970-\u1974\u1980-\u19ab\u19c1-\u19c7\u1a00-\u1a16\u1a20-\u1a54\u1aa7\u1b05-\u1b33\u1b45-\u1b4b\u1b83-\u1ba0\u1bae\u1baf\u1bba-\u1be5\u1c00-\u1c23\u1c4d-\u1c4f\u1c5a-\u1c7d\u1ce9-\u1cec\u1cee-\u1cf1\u1cf5\u1cf6\u1d00-\u1dbf\u1e00-\u1f15\u1f18-\u1f1d\u1f20-\u1f45\u1f48-\u1f4d\u1f50-\u1f57\u1f59\u1f5b\u1f5d\u1f5f-\u1f7d\u1f80-\u1fb4\u1fb6-\u1fbc\u1fbe\u1fc2-\u1fc4\u1fc6-\u1fcc\u1fd0-\u1fd3\u1fd6-\u1fdb\u1fe0-\u1fec\u1ff2-\u1ff4\u1ff6-\u1ffc\u2071\u207f\u2090-\u209c\u2102\u2107\u210a-\u2113\u2115\u2119-\u211d\u2124\u2126\u2128\u212a-\u212d\u212f-\u2139\u213c-\u213f\u2145-\u2149\u214e\u2160-\u2188\u2c00-\u2c2e\u2c30-\u2c5e\u2c60-\u2ce4\u2ceb-\u2cee\u2cf2\u2cf3\u2d00-\u2d25\u2d27\u2d2d\u2d30-\u2d67\u2d6f\u2d80-\u2d96\u2da0-\u2da6\u2da8-\u2dae\u2db0-\u2db6\u2db8-\u2dbe\u2dc0-\u2dc6\u2dc8-\u2dce\u2dd0-\u2dd6\u2dd8-\u2dde\u2e2f\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303c\u3041-\u3096\u309d-\u309f\u30a1-\u30fa\u30fc-\u30ff\u3105-\u312d\u3131-\u318e\u31a0-\u31ba\u31f0-\u31ff\u3400-\u4db5\u4e00-\u9fcc\ua000-\ua48c\ua4d0-\ua4fd\ua500-\ua60c\ua610-\ua61f\ua62a\ua62b\ua640-\ua66e\ua67f-\ua69d\ua6a0-\ua6ef\ua717-\ua71f\ua722-\ua788\ua78b-\ua78e\ua790-\ua7ad\ua7b0\ua7b1\ua7f7-\ua801\ua803-\ua805\ua807-\ua80a\ua80c-\ua822\ua840-\ua873\ua882-\ua8b3\ua8f2-\ua8f7\ua8fb\ua90a-\ua925\ua930-\ua946\ua960-\ua97c\ua984-\ua9b2\ua9cf\ua9e0-\ua9e4\ua9e6-\ua9ef\ua9fa-\ua9fe\uaa00-\uaa28\uaa40-\uaa42\uaa44-\uaa4b\uaa60-\uaa76\uaa7a\uaa7e-\uaaaf\uaab1\uaab5\uaab6\uaab9-\uaabd\uaac0\uaac2\uaadb-\uaadd\uaae0-\uaaea\uaaf2-\uaaf4\uab01-\uab06\uab09-\uab0e\uab11-\uab16\uab20-\uab26\uab28-\uab2e\uab30-\uab5a\uab5c-\uab5f\uab64\uab65\uabc0-\uabe2\uac00-\ud7a3\ud7b0-\ud7c6\ud7cb-\ud7fb\uf900-\ufa6d\ufa70-\ufad9\ufb00-\ufb06\ufb13-\ufb17\ufb1d\ufb1f-\ufb28\ufb2a-\ufb36\ufb38-\ufb3c\ufb3e\ufb40\ufb41\ufb43\ufb44\ufb46-\ufbb1\ufbd3-\ufd3d\ufd50-\ufd8f\ufd92-\ufdc7\ufdf0-\ufdfb\ufe70-\ufe74\ufe76-\ufefc\uff21-\uff3a\uff41-\uff5a\uff66-\uffbe\uffc2-\uffc7\uffca-\uffcf\uffd2-\uffd7\uffda-\uffdc]/,
NonAsciiIdentifierPart:/[\u00aa\u00b5\u00ba\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u02c1\u02c6-\u02d1\u02e0-\u02e4\u02ec\u02ee\u0300-\u0374\u0376\u0377\u037a-\u037d\u037f\u0386\u0388-\u038a\u038c\u038e-\u03a1\u03a3-\u03f5\u03f7-\u0481\u0483-\u0487\u048a-\u052f\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u05d0-\u05ea\u05f0-\u05f2\u0610-\u061a\u0620-\u0669\u066e-\u06d3\u06d5-\u06dc\u06df-\u06e8\u06ea-\u06fc\u06ff\u0710-\u074a\u074d-\u07b1\u07c0-\u07f5\u07fa\u0800-\u082d\u0840-\u085b\u08a0-\u08b2\u08e4-\u0963\u0966-\u096f\u0971-\u0983\u0985-\u098c\u098f\u0990\u0993-\u09a8\u09aa-\u09b0\u09b2\u09b6-\u09b9\u09bc-\u09c4\u09c7\u09c8\u09cb-\u09ce\u09d7\u09dc\u09dd\u09df-\u09e3\u09e6-\u09f1\u0a01-\u0a03\u0a05-\u0a0a\u0a0f\u0a10\u0a13-\u0a28\u0a2a-\u0a30\u0a32\u0a33\u0a35\u0a36\u0a38\u0a39\u0a3c\u0a3e-\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a59-\u0a5c\u0a5e\u0a66-\u0a75\u0a81-\u0a83\u0a85-\u0a8d\u0a8f-\u0a91\u0a93-\u0aa8\u0aaa-\u0ab0\u0ab2\u0ab3\u0ab5-\u0ab9\u0abc-\u0ac5\u0ac7-\u0ac9\u0acb-\u0acd\u0ad0\u0ae0-\u0ae3\u0ae6-\u0aef\u0b01-\u0b03\u0b05-\u0b0c\u0b0f\u0b10\u0b13-\u0b28\u0b2a-\u0b30\u0b32\u0b33\u0b35-\u0b39\u0b3c-\u0b44\u0b47\u0b48\u0b4b-\u0b4d\u0b56\u0b57\u0b5c\u0b5d\u0b5f-\u0b63\u0b66-\u0b6f\u0b71\u0b82\u0b83\u0b85-\u0b8a\u0b8e-\u0b90\u0b92-\u0b95\u0b99\u0b9a\u0b9c\u0b9e\u0b9f\u0ba3\u0ba4\u0ba8-\u0baa\u0bae-\u0bb9\u0bbe-\u0bc2\u0bc6-\u0bc8\u0bca-\u0bcd\u0bd0\u0bd7\u0be6-\u0bef\u0c00-\u0c03\u0c05-\u0c0c\u0c0e-\u0c10\u0c12-\u0c28\u0c2a-\u0c39\u0c3d-\u0c44\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c58\u0c59\u0c60-\u0c63\u0c66-\u0c6f\u0c81-\u0c83\u0c85-\u0c8c\u0c8e-\u0c90\u0c92-\u0ca8\u0caa-\u0cb3\u0cb5-\u0cb9\u0cbc-\u0cc4\u0cc6-\u0cc8\u0cca-\u0ccd\u0cd5\u0cd6\u0cde\u0ce0-\u0ce3\u0ce6-\u0cef\u0cf1\u0cf2\u0d01-\u0d03\u0d05-\u0d0c\u0d0e-\u0d10\u0d12-\u0d3a\u0d3d-\u0d44\u0d46-\u0d48\u0d4a-\u0d4e\u0d57\u0d60-\u0d63\u0d66-\u0d6f\u0d7a-\u0d7f\u0d82\u0d83\u0d85-\u0d96\u0d9a-\u0db1\u0db3-\u0dbb\u0dbd\u0dc0-\u0dc6\u0dca\u0dcf-\u0dd4\u0dd6\u0dd8-\u0ddf\u0de6-\u0def\u0df2\u0df3\u0e01-\u0e3a\u0e40-\u0e4e\u0e50-\u0e59\u0e81\u0e82\u0e84\u0e87\u0e88\u0e8a\u0e8d\u0e94-\u0e97\u0e99-\u0e9f\u0ea1-\u0ea3\u0ea5\u0ea7\u0eaa\u0eab\u0ead-\u0eb9\u0ebb-\u0ebd\u0ec0-\u0ec4\u0ec6\u0ec8-\u0ecd\u0ed0-\u0ed9\u0edc-\u0edf\u0f00\u0f18\u0f19\u0f20-\u0f29\u0f35\u0f37\u0f39\u0f3e-\u0f47\u0f49-\u0f6c\u0f71-\u0f84\u0f86-\u0f97\u0f99-\u0fbc\u0fc6\u1000-\u1049\u1050-\u109d\u10a0-\u10c5\u10c7\u10cd\u10d0-\u10fa\u10fc-\u1248\u124a-\u124d\u1250-\u1256\u1258\u125a-\u125d\u1260-\u1288\u128a-\u128d\u1290-\u12b0\u12b2-\u12b5\u12b8-\u12be\u12c0\u12c2-\u12c5\u12c8-\u12d6\u12d8-\u1310\u1312-\u1315\u1318-\u135a\u135d-\u135f\u1380-\u138f\u13a0-\u13f4\u1401-\u166c\u166f-\u167f\u1681-\u169a\u16a0-\u16ea\u16ee-\u16f8\u1700-\u170c\u170e-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176c\u176e-\u1770\u1772\u1773\u1780-\u17d3\u17d7\u17dc\u17dd\u17e0-\u17e9\u180b-\u180d\u1810-\u1819\u1820-\u1877\u1880-\u18aa\u18b0-\u18f5\u1900-\u191e\u1920-\u192b\u1930-\u193b\u1946-\u196d\u1970-\u1974\u1980-\u19ab\u19b0-\u19c9\u19d0-\u19d9\u1a00-\u1a1b\u1a20-\u1a5e\u1a60-\u1a7c\u1a7f-\u1a89\u1a90-\u1a99\u1aa7\u1ab0-\u1abd\u1b00-\u1b4b\u1b50-\u1b59\u1b6b-\u1b73\u1b80-\u1bf3\u1c00-\u1c37\u1c40-\u1c49\u1c4d-\u1c7d\u1cd0-\u1cd2\u1cd4-\u1cf6\u1cf8\u1cf9\u1d00-\u1df5\u1dfc-\u1f15\u1f18-\u1f1d\u1f20-\u1f45\u1f48-\u1f4d\u1f50-\u1f57\u1f59\u1f5b\u1f5d\u1f5f-\u1f7d\u1f80-\u1fb4\u1fb6-\u1fbc\u1fbe\u1fc2-\u1fc4\u1fc6-\u1fcc\u1fd0-\u1fd3\u1fd6-\u1fdb\u1fe0-\u1fec\u1ff2-\u1ff4\u1ff6-\u1ffc\u200c\u200d\u203f\u2040\u2054\u2071\u207f\u2090-\u209c\u20d0-\u20dc\u20e1\u20e5-\u20f0\u2102\u2107\u210a-\u2113\u2115\u2119-\u211d\u2124\u2126\u2128\u212a-\u212d\u212f-\u2139\u213c-\u213f\u2145-\u2149\u214e\u2160-\u2188\u2c00-\u2c2e\u2c30-\u2c5e\u2c60-\u2ce4\u2ceb-\u2cf3\u2d00-\u2d25\u2d27\u2d2d\u2d30-\u2d67\u2d6f\u2d7f-\u2d96\u2da0-\u2da6\u2da8-\u2dae\u2db0-\u2db6\u2db8-\u2dbe\u2dc0-\u2dc6\u2dc8-\u2dce\u2dd0-\u2dd6\u2dd8-\u2dde\u2de0-\u2dff\u2e2f\u3005-\u3007\u3021-\u302f\u3031-\u3035\u3038-\u303c\u3041-\u3096\u3099\u309a\u309d-\u309f\u30a1-\u30fa\u30fc-\u30ff\u3105-\u312d\u3131-\u318e\u31a0-\u31ba\u31f0-\u31ff\u3400-\u4db5\u4e00-\u9fcc\ua000-\ua48c\ua4d0-\ua4fd\ua500-\ua60c\ua610-\ua62b\ua640-\ua66f\ua674-\ua67d\ua67f-\ua69d\ua69f-\ua6f1\ua717-\ua71f\ua722-\ua788\ua78b-\ua78e\ua790-\ua7ad\ua7b0\ua7b1\ua7f7-\ua827\ua840-\ua873\ua880-\ua8c4\ua8d0-\ua8d9\ua8e0-\ua8f7\ua8fb\ua900-\ua92d\ua930-\ua953\ua960-\ua97c\ua980-\ua9c0\ua9cf-\ua9d9\ua9e0-\ua9fe\uaa00-\uaa36\uaa40-\uaa4d\uaa50-\uaa59\uaa60-\uaa76\uaa7a-\uaac2\uaadb-\uaadd\uaae0-\uaaef\uaaf2-\uaaf6\uab01-\uab06\uab09-\uab0e\uab11-\uab16\uab20-\uab26\uab28-\uab2e\uab30-\uab5a\uab5c-\uab5f\uab64\uab65\uabc0-\uabea\uabec\uabed\uabf0-\uabf9\uac00-\ud7a3\ud7b0-\ud7c6\ud7cb-\ud7fb\uf900-\ufa6d\ufa70-\ufad9\ufb00-\ufb06\ufb13-\ufb17\ufb1d-\ufb28\ufb2a-\ufb36\ufb38-\ufb3c\ufb3e\ufb40\ufb41\ufb43\ufb44\ufb46-\ufbb1\ufbd3-\ufd3d\ufd50-\ufd8f\ufd92-\ufdc7\ufdf0-\ufdfb\ufe00-\ufe0f\ufe20-\ufe2d\ufe33\ufe34\ufe4d-\ufe4f\ufe70-\ufe74\ufe76-\ufefc\uff10-\uff19\uff21-\uff3a\uff3f\uff41-\uff5a\uff66-\uffbe\uffc2-\uffc7\uffca-\uffcf\uffd2-\uffd7\uffda-\uffdc]/};
G.prototype=E.prototype={processComment:function(){var a,c,b,d=L.bottomRightStack,e,f,g=d[d.length-1];if(!(this.type===ca.Program&&0<this.body.length)){if(0<L.trailingComments.length){b=[];for(e=L.trailingComments.length-1;0<=e;--e)f=L.trailingComments[e],f.range[0]>=this.range[1]&&(b.unshift(f),L.trailingComments.splice(e,1));L.trailingComments=[]}else g&&g.trailingComments&&g.trailingComments[0].range[0]>=this.range[1]&&(b=g.trailingComments,delete g.trailingComments);if(g)for(;g&&g.range[0]>=this.range[0];)a=
g,g=d.pop();if(a)a.leadingComments&&a.leadingComments[a.leadingComments.length-1].range[1]<=this.range[0]&&(this.leadingComments=a.leadingComments,a.leadingComments=void 0);else if(0<L.leadingComments.length)for(c=[],e=L.leadingComments.length-1;0<=e;--e)f=L.leadingComments[e],f.range[1]<=this.range[0]&&(c.unshift(f),L.leadingComments.splice(e,1));c&&0<c.length&&(this.leadingComments=c);b&&0<b.length&&(this.trailingComments=b);d.push(this)}},finish:function(){L.range&&(this.range[1]=D);L.loc&&(this.loc.end=
new B,L.source&&(this.loc.source=L.source));L.attachComment&&this.processComment()},finishArrayExpression:function(a){this.type=ca.ArrayExpression;this.elements=a;this.finish();return this},finishAssignmentExpression:function(a,c,b){this.type=ca.AssignmentExpression;this.operator=a;this.left=c;this.right=b;this.finish();return this},finishBinaryExpression:function(a,c,b){this.type="||"===a||"\x26\x26"===a?ca.LogicalExpression:ca.BinaryExpression;this.operator=a;this.left=c;this.right=b;this.finish();
return this},finishBlockStatement:function(a){this.type=ca.BlockStatement;this.body=a;this.finish();return this},finishBreakStatement:function(a){this.type=ca.BreakStatement;this.label=a;this.finish();return this},finishCallExpression:function(a,c){this.type=ca.CallExpression;this.callee=a;this.arguments=c;this.finish();return this},finishConditionalExpression:function(a,c,b){this.type=ca.ConditionalExpression;this.test=a;this.consequent=c;this.alternate=b;this.finish();return this},finishContinueStatement:function(a){this.type=
ca.ContinueStatement;this.label=a;this.finish();return this},finishEmptyStatement:function(){this.type=ca.EmptyStatement;this.finish();return this},finishExpressionStatement:function(a){this.type=ca.ExpressionStatement;this.expression=a;this.finish();return this},finishForStatement:function(a,c,b,d){this.type=ca.ForStatement;this.init=a;this.test=c;this.update=b;this.body=d;this.finish();return this},finishForInStatement:function(a,c,b){this.type=ca.ForInStatement;this.left=a;this.right=c;this.body=
b;this.each=!1;this.finish();return this},finishFunctionDeclaration:function(a,c,b,d){this.type=ca.FunctionDeclaration;this.id=a;this.params=c;this.defaults=b;this.body=d;this.rest=null;this.expression=this.generator=!1;this.finish();return this},finishFunctionExpression:function(a,c,b,d){this.type=ca.FunctionExpression;this.id=a;this.params=c;this.defaults=b;this.body=d;this.rest=null;this.expression=this.generator=!1;this.finish();return this},finishIdentifier:function(a){this.type=ca.Identifier;
this.name=a;this.finish();return this},finishIfStatement:function(a,c,b){this.type=ca.IfStatement;this.test=a;this.consequent=c;this.alternate=b;this.finish();return this},finishLiteral:function(a){this.type=ca.Literal;this.value=a.value;this.raw=K.slice(a.start,a.end);a.regex&&(this.regex=a.regex);this.finish();return this},finishMemberExpression:function(a,c,b){this.type=ca.MemberExpression;this.computed="["===a;this.object=c;this.property=b;this.finish();return this},finishObjectExpression:function(a){this.type=
ca.ObjectExpression;this.properties=a;this.finish();return this},finishPostfixExpression:function(a,c){this.type=ca.UpdateExpression;this.operator=a;this.argument=c;this.prefix=!1;this.finish();return this},finishProgram:function(a){this.type=ca.Program;this.body=a;this.finish();return this},finishProperty:function(a,c,b,d,e){this.type=ca.Property;this.key=c;this.value=b;this.kind=a;this.method=d;this.shorthand=e;this.finish();return this},finishReturnStatement:function(a){this.type=ca.ReturnStatement;
this.argument=a;this.finish();return this},finishUnaryExpression:function(a,c){this.type="++"===a||"--"===a?ca.UpdateExpression:ca.UnaryExpression;this.operator=a;this.argument=c;this.prefix=!0;this.finish();return this},finishVariableDeclaration:function(a,c){this.type=ca.VariableDeclaration;this.declarations=a;this.kind=c;this.finish();return this},finishVariableDeclarator:function(a,c){this.type=ca.VariableDeclarator;this.id=a;this.init=c;this.finish();return this}};b.version="2.0.0-dev";b.tokenize=
function(a,c){var b,d;b=String;"string"===typeof a||a instanceof String||(a=b(a));K=a;D=0;ba=0<K.length?1:0;X=0;ka=K.length;S=null;Y={allowIn:!0,labelSet:{},inFunctionBody:!1,inIteration:!1,inSwitch:!1,lastCommentStart:-1};L={};c=c||{};c.tokens=!0;L.tokens=[];L.tokenize=!0;L.openParenToken=-1;L.openCurlyToken=-1;L.range="boolean"===typeof c.range&&c.range;L.loc="boolean"===typeof c.loc&&c.loc;"boolean"===typeof c.comment&&c.comment&&(L.comments=[]);"boolean"===typeof c.tolerant&&c.tolerant&&(L.errors=
[]);try{A();if(S.type===N.EOF)return L.tokens;for(w();S.type!==N.EOF;)try{w()}catch(Pa){if(L.errors){L.errors.push(Pa);break}else throw Pa;}cb();d=L.tokens;"undefined"!==typeof L.comments&&(d.comments=L.comments);"undefined"!==typeof L.errors&&(d.errors=L.errors)}catch(Pa){throw Pa;}finally{L={}}return d};b.parse=function(a,c){var b,d;d=String;"string"===typeof a||a instanceof String||(a=d(a));K=a;D=0;ba=0<K.length?1:0;X=0;ka=K.length;S=null;Y={allowIn:!0,labelSet:{},parenthesisCount:0,inFunctionBody:!1,
inIteration:!1,inSwitch:!1,lastCommentStart:-1};L={};"undefined"!==typeof c&&(L.range="boolean"===typeof c.range&&c.range,L.loc="boolean"===typeof c.loc&&c.loc,L.attachComment="boolean"===typeof c.attachComment&&c.attachComment,L.loc&&null!==c.source&&void 0!==c.source&&(L.source=d(c.source)),"boolean"===typeof c.tokens&&c.tokens&&(L.tokens=[]),"boolean"===typeof c.comment&&c.comment&&(L.comments=[]),"boolean"===typeof c.tolerant&&c.tolerant&&(L.errors=[]),L.attachComment&&(L.range=!0,L.comments=
[],L.bottomRightStack=[],L.trailingComments=[],L.leadingComments=[]));try{var e;g();A();e=new E;ia=!1;var f;a=[];for(var h,p,n;D<ka;){h=S;if(h.type!==N.StringLiteral)break;f=Ja();a.push(f);if(f.expression.type!==ca.Literal)break;p=K.slice(h.start+1,h.end-1);"use strict"===p?(ia=!0,n&&U(n,ha.StrictOctalLiteral)):!n&&h.octal&&(n=h)}for(;D<ka;){f=Ja();if("undefined"===typeof f)break;a.push(f)}b=e.finishProgram(a);"undefined"!==typeof L.comments&&(b.comments=L.comments);"undefined"!==typeof L.tokens&&
(cb(),b.tokens=L.tokens);"undefined"!==typeof L.errors&&(b.errors=L.errors)}catch(jb){throw jb;}finally{L={}}return b};b.Syntax=function(){var a,c={};"function"===typeof Object.create&&(c=Object.create(null));for(a in ca)ca.hasOwnProperty(a)&&(c[a]=ca[a]);"function"===typeof Object.freeze&&Object.freeze(c);return c}()})},"esri/renderers/visualVariables/support/sizeVariableUtils":function(){define(["require","exports","../../support/utils","./utils"],function(b,e,m,d){function k(a){return a&&"esri.renderers.visualVariables.SizeVariable"===
a.declaredClass}function l(a){return null!=a&&!isNaN(a)&&isFinite(a)}function h(a){return a.valueExpression?"expression":a.field&&"string"===typeof a.field?"field":"unknown"}function a(a,c,b){return null==a?null:k(a)?a.getSize(c,b):l(a)?a:null}function c(a,c,b){return l(b)&&a>b?b:l(c)&&a<c?c:a}Object.defineProperty(e,"__esModule",{value:!0});var f=Math.PI;e.isSizeVariable=k;e.isValidNumber=l;e.getInputValueType=h;e.getTransformationType=function(a,c){return"unknown"===(c||h(a))?"constant":a.stops?
"stops":null!=a.minSize&&null!=a.maxSize&&null!=a.minDataValue&&null!=a.maxDataValue?"clamped-linear":"unknown"===(a.valueUnit||"unknown")?null!=a.minSize&&null!=a.minDataValue?a.minSize&&a.minDataValue?"proportional":"additive":"identity":"real-world-size"};e.getSizeFromNumberOrVariable=a;e.getSizeForValue=function(b,e,h,p,k){switch(e.transformationType){case "additive":return p=a(e.minSize,h,p),b+(p||e.minDataValue);case "constant":return b=(b=e.stops)&&b.length&&b[0].size,null==b&&(b=e.minSize),
a(b,h,p);case "clamped-linear":k=(b-e.minDataValue)/(e.maxDataValue-e.minDataValue);var g=a(e.minSize,h,p);h=a(e.maxSize,h,p);p=p&&p.shape;b<=e.minDataValue?e=g:b>=e.maxDataValue?e=h:"area"===e.scaleBy&&p?(p=(e="circle"===p)?f*Math.pow(g/2,2):g*g,p+=k*((e?f*Math.pow(h/2,2):h*h)-p),e=e?2*Math.sqrt(p/f):Math.sqrt(p)):e=g+k*(h-g);return e;case "proportional":return k=p&&p.shape,b/=e.minDataValue,g=a(e.minSize,h,p),e=a(e.maxSize,h,p),p=null,p="circle"===k?2*Math.sqrt(b*Math.pow(g/2,2)):"square"===k||
"diamond"===k||"image"===k?Math.sqrt(b*Math.pow(g,2)):b*g,c(p,g,e);case "stops":return k=d.lookupData(b,k),g=k[0],b=k[1],k=k[2],g===b?e=a(e.stops[g].size,h,p):(g=a(e.stops[g].size,h,p),e=a(e.stops[b].size,h,p),e=g+(e-g)*k),e;case "real-world-size":return k=(p&&p.resolution?p.resolution:1)*m.meterIn[e.valueUnit],g=a(e.minSize,h,p),p=a(e.maxSize,h,p),e=e.valueRepresentation,h=null,h="area"===e?2*Math.sqrt(b/f)/k:"radius"===e||"distance"===e?2*b/k:b/k,c(h,g,p);case "identity":return b;case "unknown":return null}}})},
"esri/renderers/visualVariables/OpacityVariable":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./VisualVariable ./support/OpacityStop ./support/utils ../../support/arcadeUtils".split(" "),function(b,e,m,d,k,l,h,a,c){return function(b){function e(a){a=b.call(this,a)||this;a.type="opacity";a.normalizationField=null;return a}m(e,b);f=e;Object.defineProperty(e.prototype,"_cache",{get:function(){var a=
c.createSyntaxTree(this.valueExpression);return{ipData:this._interpolateData(),hasExpression:!!this.valueExpression,compiledFunc:c.createFunction(a)}},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"stops",{set:function(a){a&&Array.isArray(a)&&(a=a.filter(function(a){return!!a}),a.sort(function(a,c){return a.value-c.value}));this._set("stops",a)},enumerable:!0,configurable:!0});e.prototype.getOpacity=function(b,d){var e="number"===typeof b,f=e?null:b,g=f&&f.attributes,h=e?b:null,
p=this._cache;b=p.ipData;var n=p.hasExpression,p=p.compiledFunc,k=this.field;if(!k&&!n)return(e=this.stops)&&e[0]&&e[0].opacity;"number"!==typeof h&&(n?(h=c.getViewInfo(d),f=c.createExecContext(f,h),h=c.executeFunction(p,f)):g&&(h=g[k]));f=this.normalizationField;g=g?parseFloat(g[f]):void 0;if(null!=h&&(!f||e||!isNaN(g)&&0!==g)&&(isNaN(g)||e||(h/=g),e=a.lookupData(h,b))){b=e[0];g=e[1];if(b===g)return this.stops[b].opacity;b=this.stops[b].opacity;return b+(this.stops[g].opacity-b)*e[2]}};e.prototype.clone=
function(){return new f({field:this.field,normalizationField:this.normalizationField,valueExpression:this.valueExpression,valueExpressionTitle:this.valueExpressionTitle,stops:this.stops&&this.stops.map(function(a){return a.clone()}),legendOptions:this.legendOptions&&this.legendOptions.clone()})};e.prototype._interpolateData=function(){return this.stops&&this.stops.map(function(a){return a.value||0})};var f;d([k.property({readOnly:!0,dependsOn:["valueExpression","stops"]})],e.prototype,"_cache",null);
d([k.property({type:["opacity"],json:{type:["transparencyInfo"]}})],e.prototype,"type",void 0);d([k.property({type:String,json:{write:!0}})],e.prototype,"normalizationField",void 0);d([k.property({type:[h],json:{write:!0}})],e.prototype,"stops",null);return e=f=d([k.subclass("esri.renderers.visualVariables.OpacityVariable")],e)}(k.declared(l))})},"esri/renderers/visualVariables/support/OpacityStop":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/JSONSupport ../../../core/accessorSupport/decorators ../../../core/accessorSupport/ensureType ../../../webdoc/support/opacityUtils".split(" "),
function(b,e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this,a)||this;a.label=null;a.opacity=null;a.value=null;return a}m(b,c);e=b;b.prototype.readOpacity=function(c,b){return a.transparencyToOpacity(b.transparency)};b.prototype.writeOpacity=function(c,b,d){b[d]=a.opacityToTransparency(c)};b.prototype.clone=function(){return new e({label:this.label,opacity:this.opacity,value:this.value})};var e;d([l.property({type:String,json:{write:!0}})],b.prototype,"label",void 0);d([l.property({type:Number,
json:{type:h.Integer,write:{target:"transparency"}}})],b.prototype,"opacity",void 0);d([l.reader("opacity",["transparency"])],b.prototype,"readOpacity",null);d([l.writer("opacity")],b.prototype,"writeOpacity",null);d([l.property({type:Number,json:{write:!0}})],b.prototype,"value",void 0);return b=e=d([l.subclass("esri.renderers.visualVariables.support.OpacityStop")],b)}(l.declared(k))})},"esri/renderers/visualVariables/RotationVariable":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Error ../../core/accessorSupport/decorators ./VisualVariable ../../support/arcadeUtils".split(" "),
function(b,e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this,a)||this;a.axis=null;a.type="rotation";a.rotationType="geographic";a.valueExpressionTitle=null;return a}m(b,c);e=b;Object.defineProperty(b.prototype,"_cache",{get:function(){var c=a.createSyntaxTree(this.valueExpression);return{hasExpression:!!this.valueExpression,compiledFunc:a.createFunction(c)}},enumerable:!0,configurable:!0});b.prototype.writeValueExpressionTitleWebScene=function(a,c,b,d){d&&d.messages&&d.messages.push(new k("property:unsupported",
this.type+"VisualVariable.valueExpressionTitle is not supported in Web Scene. Please remove this property to save the Web Scene.",{instance:this,propertyName:"visualVariables["+this.index+"].valueExpressionTitle",context:d}))};b.prototype.getRotationAngle=function(c,b){var d=this.axis||"heading",e="heading"===d&&"arithmetic"===this.rotationType?90:0,d="heading"===d&&"arithmetic"===this.rotationType?-1:1,f=(c="number"===typeof c?null:c)&&c.attributes,g=this.field,h=this._cache,n=h.hasExpression,h=
h.compiledFunc,k=0;if(!g&&!n)return k;n?(b=a.getViewInfo(b),b=a.createExecContext(c,b),k=a.executeFunction(h,b)):f&&(k=f[g]||0);return k="number"!==typeof k||isNaN(k)?null:e+d*k};b.prototype.clone=function(){return new e({axis:this.axis,rotationType:this.rotationType,field:this.field,valueExpression:this.valueExpression,valueExpressionTitle:this.valueExpressionTitle,legendOptions:this.legendOptions&&this.legendOptions.clone()})};var e;d([l.property({readOnly:!0,dependsOn:["valueExpression"]})],b.prototype,
"_cache",null);d([l.property({type:["heading","tilt","roll"],json:{origins:{"web-scene":{default:"heading",write:!0}}}})],b.prototype,"axis",void 0);d([l.property({type:["rotation"],json:{type:["rotationInfo"]}})],b.prototype,"type",void 0);d([l.property({type:["geographic","arithmetic"],json:{write:!0,origins:{"web-document":{write:!0,default:"geographic"}}}})],b.prototype,"rotationType",void 0);d([l.property({type:String,json:{write:!0}})],b.prototype,"valueExpressionTitle",void 0);d([l.writer("web-scene",
"valueExpressionTitle")],b.prototype,"writeValueExpressionTitleWebScene",null);return b=e=d([l.subclass("esri.renderers.visualVariables.RotationVariable")],b)}(l.declared(h))})},"esri/renderers/visualVariables/SizeVariable":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/tsSupport/assignHelper ../../Graphic ../../core/Error ../../core/kebabDictionary ../../core/Logger ../../core/screenUtils ../../core/accessorSupport/decorators ./VisualVariable ./support/SizeStop ./support/SizeVariableLegendOptions ./support/sizeVariableUtils ../../support/arcadeUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r){function v(a){if(null!=a){if("string"===typeof a||"number"===typeof a)return f.toPt(a);if("size"===a.type){if(t.isSizeVariable(a))return a;a=k({},a);delete a.type;return new B(a)}}}function u(a,c,b){if("object"!==typeof a)return a;c=new B;c.read(a,b);return c}var z=/^\s*(return\s+)?\$view\.scale\s*(;)?\s*$/i,y=new l,x=c.getLogger("esri.renderers.visualVariables.SizeVariable"),w=new a.default({width:"width",depth:"depth",height:"height",widthAndDepth:"width-and-depth",
all:"all"}),A=new a.default({unknown:"unknown",inch:"inches",foot:"feet",yard:"yards",mile:"miles","nautical-mile":"nautical-miles",millimeter:"millimeters",centimeter:"centimeters",decimeter:"decimeters",meter:"meters",kilometer:"kilometers","decimal-degree":"decimal-degrees"}),B=function(a){function c(c){c=a.call(this,c)||this;c.axis=null;c.legendOptions=null;c.normalizationField=null;c.scaleBy=null;c.target=null;c.type="size";c.useSymbolValue=null;c.valueExpression=null;c.valueRepresentation=null;
c.valueUnit=null;return c}m(c,a);b=c;Object.defineProperty(c.prototype,"_cache",{get:function(){var a=r.createSyntaxTree(this.valueExpression);return{ipData:this._interpolateData(),hasExpression:!!this.valueExpression,compiledFunc:r.createFunction(a),isScaleDriven:z.test(this.valueExpression)}},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"expression",{set:function(a){x.warn("'expression' is deprecated since version 4.2. Use 'valueExpression' instead. The only supported expression is 'view.scale'.");
"view.scale"===a?(this.valueExpression="$view.scale",this._set("expression",a)):this._set("expression",null)},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"index",{set:function(a){t.isSizeVariable(this.maxSize)&&(this.maxSize.index="visualVariables["+a+"].maxSize");t.isSizeVariable(this.minSize)&&(this.minSize.index="visualVariables["+a+"].minSize");this._set("index",a)},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"inputValueType",{get:function(){return t.getInputValueType(this)},
enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"maxDataValue",{set:function(a){a&&this.stops&&(x.warn("cannot set maxDataValue when stops is not null."),a=null);this._set("maxDataValue",a)},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"maxSize",{set:function(a){a&&this.stops&&(x.warn("cannot set maxSize when stops is not null."),a=null);this._set("maxSize",a)},enumerable:!0,configurable:!0});c.prototype.castMaxSize=function(a){return v(a)};c.prototype.readMaxSize=
function(a,c,b){return u(a,c,b)};Object.defineProperty(c.prototype,"minDataValue",{set:function(a){a&&this.stops&&(x.warn("cannot set minDataValue when stops is not null."),a=null);this._set("minDataValue",a)},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"minSize",{set:function(a){a&&this.stops&&(x.warn("cannot set minSize when stops is not null."),a=null);this._set("minSize",a)},enumerable:!0,configurable:!0});c.prototype.castMinSize=function(a){return v(a)};c.prototype.readMinSize=
function(a,c,b){return u(a,c,b)};Object.defineProperty(c.prototype,"stops",{set:function(a){null==this.minDataValue&&null==this.maxDataValue&&null==this.minSize&&null==this.maxSize?a&&Array.isArray(a)&&(a=a.filter(function(a){return!!a}),a.sort(function(a,c){return a.value-c.value})):a&&(x.warn("cannot set stops when one of minDataValue, maxDataValue, minSize or maxSize is not null."),a=null);this._set("stops",a)},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"transformationType",
{get:function(){return t.getTransformationType(this,this.inputValueType)},enumerable:!0,configurable:!0});c.prototype.readValueExpression=function(a,c){return a||c.expression&&"$view.scale"};c.prototype.writeValueExpressionWebScene=function(a,c,b,d){"$view.scale"===a?d&&d.messages&&(a=this.index,d.messages.push(new h("property:unsupported",this.type+"VisualVariable.valueExpression \x3d '$view.scale' is not supported in Web Scene. Please remove this property to save the Web Scene.",{instance:this,
propertyName:("string"===typeof a?a:"visualVariables["+a+"]")+".valueExpression",context:d}))):c[b]=a};c.prototype.readValueUnit=function(a,c,b){return a?A.read(a):null};c.prototype.getSize=function(a,c){var b=this._getInputValue(a,c);a=t.getSizeForValue(b,this,a,c,this._cache.ipData);return null===a||void 0===a||isNaN(a)?0:a};c.prototype.getSizeRangeAtScale=function(a,c){var b=c&&"3d"===c.type;if(!(this._cache.isScaleDriven&&b||a))return null;c={scale:a,view:c};a=t.getSizeFromNumberOrVariable(this.minSize,
y,c);c=t.getSizeFromNumberOrVariable(this.maxSize,y,c);if(null!=a||null!=c)return a>c&&(b=c,c=a,a=b),{minSize:a,maxSize:c}};c.prototype.clone=function(){return new b({axis:this.axis,field:this.field,valueExpression:this.valueExpression,valueExpressionTitle:this.valueExpressionTitle,maxDataValue:this.maxDataValue,maxSize:t.isSizeVariable(this.maxSize)?this.maxSize.clone():this.maxSize,minDataValue:this.minDataValue,minSize:t.isSizeVariable(this.minSize)?this.minSize.clone():this.minSize,normalizationField:this.normalizationField,
stops:this.stops&&this.stops.map(function(a){return a.clone()}),target:this.target,useSymbolValue:this.useSymbolValue,valueRepresentation:this.valueRepresentation,valueUnit:this.valueUnit,legendOptions:this.legendOptions&&this.legendOptions.clone()})};c.prototype._interpolateData=function(){return this.stops&&this.stops.map(function(a){return a.value||0})};c.prototype._getInputValue=function(a,c){var b="number"===typeof a,d=b?null:a,e=d&&d.attributes,f=b?a:null,g=this._cache;a=g.compiledFunc;if(g.isScaleDriven)d=
c&&c.scale,c=c&&c.view,f=null==d||c&&"3d"===c.type?this._getAverageSizeValue():d;else if(!b)switch(this.inputValueType){case "expression":c=r.getViewInfo(c);c=r.createExecContext(d,c);f=r.executeFunction(a,c);break;case "field":e&&(f=e[this.field]);break;case "unknown":f=null}if(!t.isValidNumber(f))return null;if(b||!this.normalizationField)return f;b=e?parseFloat(e[this.normalizationField]):null;return t.isValidNumber(b)&&0!==b?f/b:null};c.prototype._getAverageSizeValue=function(){var a=null,c=null;
(c=this.stops)?(a=c[0].value,c=c[c.length-1].value):(a=this.minDataValue||0,c=this.maxDataValue||0);return(a+c)/2};var b;d([n.property({readOnly:!0,dependsOn:["valueExpression","stops"]})],c.prototype,"_cache",null);d([n.property({type:w.apiValues,json:{type:w.jsonValues,origins:{"web-map":{read:!1}},read:w.read,write:w.write}})],c.prototype,"axis",void 0);d([n.property({type:String,value:null,json:{read:!1}})],c.prototype,"expression",null);d([n.property()],c.prototype,"index",null);d([n.property({type:String,
readOnly:!0,dependsOn:["field","valueExpression"]})],c.prototype,"inputValueType",null);d([n.property({type:p,json:{write:!0}})],c.prototype,"legendOptions",void 0);d([n.property({type:Number,value:null,json:{write:!0}})],c.prototype,"maxDataValue",null);d([n.property({type:Number,value:null,json:{write:!0}})],c.prototype,"maxSize",null);d([n.cast("maxSize")],c.prototype,"castMaxSize",null);d([n.reader("maxSize")],c.prototype,"readMaxSize",null);d([n.property({type:Number,value:null,json:{write:!0}})],
c.prototype,"minDataValue",null);d([n.property({type:Number,value:null,json:{write:!0}})],c.prototype,"minSize",null);d([n.cast("minSize")],c.prototype,"castMinSize",null);d([n.reader("minSize")],c.prototype,"readMinSize",null);d([n.property({type:String,json:{write:!0}})],c.prototype,"normalizationField",void 0);d([n.property({type:String})],c.prototype,"scaleBy",void 0);d([n.property({type:[q],value:null,json:{write:!0}})],c.prototype,"stops",null);d([n.property({type:["outline"],json:{write:!0}})],
c.prototype,"target",void 0);d([n.property({type:String,readOnly:!0,dependsOn:"minDataValue maxDataValue minSize maxSize valueUnit inputValueType stops".split(" ")})],c.prototype,"transformationType",null);d([n.property({type:["size"],json:{type:["sizeInfo"]}})],c.prototype,"type",void 0);d([n.property({type:Boolean,json:{write:!0,origins:{"web-map":{read:!1}}}})],c.prototype,"useSymbolValue",void 0);d([n.property({type:String,json:{write:!0}})],c.prototype,"valueExpression",void 0);d([n.reader("valueExpression",
["valueExpression","expression"])],c.prototype,"readValueExpression",null);d([n.writer("web-scene","valueExpression")],c.prototype,"writeValueExpressionWebScene",null);d([n.property({type:["radius","diameter","area","width","distance"],json:{write:!0}})],c.prototype,"valueRepresentation",void 0);d([n.property({type:A.apiValues,json:{write:A.write,origins:{"web-map":{read:!1},"web-scene":{write:!0}}}})],c.prototype,"valueUnit",void 0);d([n.reader("valueUnit")],c.prototype,"readValueUnit",null);return c=
b=d([n.subclass("esri.renderers.visualVariables.SizeVariable")],c)}(n.declared(g));return B})},"esri/Graphic":function(){define("require exports ./core/tsSupport/assignHelper ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./geometry ./PopupTemplate ./symbols ./core/JSONSupport ./core/lang ./core/maybe ./core/accessorSupport/decorators ./geometry/support/jsonUtils ./symbols/support/jsonUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g,q,p){b=function(c){function b(a,b,d,f){a=
c.call(this,a,b,d,f)||this;a.layer=null;a.popupTemplate=null;a.sourceLayer=null;Object.defineProperty(a,"uid",{value:e.generateUID()});return a}d(b,c);e=b;b.prototype.normalizeCtorArgs=function(a,c,b,d){return a&&!a.declaredClass?a:{geometry:a,symbol:c,attributes:b,popupTemplate:d}};Object.defineProperty(b.prototype,"attributes",{set:function(a){var c=this._get("attributes");c!==a&&(this._set("attributes",a),this._notifyLayer("attributes",c,a))},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,
"geometry",{set:function(a){var c=this._get("geometry");c!==a&&(this._set("geometry",a),this._notifyLayer("geometry",c,a))},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"symbol",{set:function(a){var c=this._get("symbol");c!==a&&(this._set("symbol",a),this._notifyLayer("symbol",c,a))},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"visible",{set:function(a){var c=this._get("visible");c!==a&&(this._set("visible",a),this._notifyLayer("visible",c,a))},enumerable:!0,
configurable:!0});b.prototype.getEffectivePopupTemplate=function(a){void 0===a&&(a=!1);return this.popupTemplate?this.popupTemplate:this.sourceLayer?this.sourceLayer.popupTemplate?this.sourceLayer.popupTemplate:a&&n.isSome(this.sourceLayer.defaultPopupTemplate)?this.sourceLayer.defaultPopupTemplate:null:null};b.prototype.getAttribute=function(a){return this.attributes&&this.attributes[a]};b.prototype.setAttribute=function(a,c){var b;this.attributes?(b=this.getAttribute(a),this.attributes[a]=c,this._notifyLayer("attributes",
b,c,a)):(this.attributes=(b={},b[a]=c,b),this._notifyLayer("attributes",void 0,c,a))};b.prototype.toJSON=function(){return{geometry:this.geometry&&this.geometry.toJSON(),symbol:this.symbol&&this.symbol.toJSON(),attributes:m({},this.attributes),popupTemplate:this.popupTemplate&&this.popupTemplate.toJSON()}};b.prototype.clone=function(){return new e({attributes:f.clone(this.attributes),geometry:this.geometry&&this.geometry.clone()||null,layer:this.layer,popupTemplate:this.popupTemplate&&this.popupTemplate.clone(),
sourceLayer:this.sourceLayer,symbol:this.symbol&&this.symbol.clone()||null,visible:this.visible})};b.prototype._notifyLayer=function(a,c,b,d){this.layer&&this.layer.graphicChanged&&(c={graphic:this,property:a,oldValue:c,newValue:b},"attributes"===a&&(c.attributeName=d),this.layer.graphicChanged(c))};var e;k([g.property({value:null})],b.prototype,"attributes",null);k([g.property({value:null,types:l.geometryTypes,json:{read:q.fromJSON}})],b.prototype,"geometry",null);k([g.property()],b.prototype,"layer",
void 0);k([g.property({type:h})],b.prototype,"popupTemplate",void 0);k([g.property()],b.prototype,"sourceLayer",void 0);k([g.property({value:null,types:a.symbolTypes,json:{read:p.read}})],b.prototype,"symbol",null);k([g.property({type:Boolean,value:!0,set:function(a){}})],b.prototype,"visible",null);return b=e=k([g.subclass("esri.Graphic")],b)}(g.declared(c));var t=0;(function(a){a.generateUID=function(){return t++}})(b||(b={}));return b})},"esri/core/maybe":function(){define(["require","exports",
"./has"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.isSome=function(b){return null!=b};e.isNone=function(b){return null==b};e.map=function(b,e){return null!=b?e(b):null};e.unwrap=function(b){return b};e.expect=function(b){return b}})},"esri/renderers/visualVariables/support/SizeStop":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/JSONSupport ../../../core/screenUtils ../../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this,c)||this;c.label=null;c.size=null;c.value=null;return c}m(c,a);b=c;c.prototype.clone=function(){return new b({label:this.label,size:this.size,value:this.value})};var b;d([h.property({type:String,json:{write:!0}})],c.prototype,"label",void 0);d([h.property({type:Number,cast:l.toPt,json:{write:!0}})],c.prototype,"size",void 0);d([h.property({type:Number,json:{write:!0}})],c.prototype,"value",void 0);return c=b=d([h.subclass("esri.renderers.visualVariables.support.SizeStop")],
c)}(h.declared(k))})},"esri/renderers/visualVariables/support/SizeVariableLegendOptions":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/accessorSupport/decorators ./VisualVariableLegendOptions".split(" "),function(b,e,m,d,k,l){return function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.customValues=null;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({title:this.title,showLegend:this.showLegend,
customValues:this.customValues&&this.customValues.slice(0)})};var c;d([k.property({type:[Number],json:{write:!0}})],a.prototype,"customValues",void 0);return a=c=d([k.subclass("esri.renderers.visualVariables.support.SizeVariableLegendOptions")],a)}(k.declared(l))})},"esri/renderers/visualVariables/VisualVariableFactory":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/kebabDictionary ../../core/Logger ../../core/Warning ../../core/accessorSupport/decorators ./ColorVariable ./OpacityVariable ./RotationVariable ./SizeVariable".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q){var p=h.getLogger("esri.renderers.visualVariables.VisualVariableFactory"),t={color:f,size:q,opacity:n,rotation:g},r=new l.default({colorInfo:"color",transparencyInfo:"opacity",rotationInfo:"rotation",sizeInfo:"size"}),v=/^\[([^\]]+)\]$/i;return function(b){function e(){var a=null!==b&&b.apply(this,arguments)||this;a.colorVariables=null;a.opacityVariables=null;a.rotationVariables=null;a.sizeVariables=null;return a}m(e,b);Object.defineProperty(e.prototype,"visualVariables",
{set:function(a){this._resetVariables();if((a=a&&a.filter(function(a){return!!a}))&&a.length){for(var c=0,b=a;c<b.length;c++){var d=b[c];switch(d.type){case "color":this.colorVariables.push(d);break;case "opacity":this.opacityVariables.push(d);break;case "rotation":this.rotationVariables.push(d);break;case "size":this.sizeVariables.push(d)}}this.sizeVariables.length&&this.sizeVariables.some(function(a){return!!a.target})&&a.sort(function(a,c){var b=null;return b=a.target===c.target?0:a.target?1:-1});
for(c=0;c<a.length;c++)d=a[c],d.index=c}this._set("visualVariables",a)},enumerable:!0,configurable:!0});e.prototype.readVariables=function(c,b,d){var e=b.rotationExpression;b=b.rotationType;if(e=(e=e&&e.match(v))&&e[1])c||(c=[]),c.push({type:"rotationInfo",rotationType:b,field:e});if(c)return c.map(function(c){var b=r.read(c.type),e=t[b];e||(p.warn("Unknown variable type: "+b),d&&d.messages&&d.messages.push(new a("visual-variable:unsupported","visualVariable of type '"+b+"' is not supported",{definition:c,
context:d})));b=new e;b.read(c,d);return b})};e.prototype.writeVariables=function(a,c){for(var b=[],d=0;d<a.length;d++){var e=a[d].toJSON(c);e&&b.push(e)}return b};e.prototype.getVisualVariableValues=function(a,c){var b=[];this.colorVariables.forEach(function(d){var e=d.getColor(a,c);b.push({variable:d,value:e})});this.opacityVariables.forEach(function(d){var e=d.getOpacity(a,c);b.push({variable:d,value:e})});this.rotationVariables.forEach(function(d){var e=d.getRotationAngle(a,c);b.push({variable:d,
value:e})});this.sizeVariables.forEach(function(d){var e=d.getSize(a,c);b.push({variable:d,value:e})});return b.filter(function(a){return null!=a.value})};e.prototype.getColor=function(a,c){if(this.colorVariables.length)return this.colorVariables[0].getColor(a,c)};e.prototype.getOpacity=function(a,c){if(this.opacityVariables.length)return this.opacityVariables[0].getOpacity(a,c)};e.prototype.getRotationAngle=function(a,c){if(this.rotationVariables.length)return this.rotationVariables[0].getRotationAngle(a,
c)};e.prototype.getSize=function(a,c){if(this.sizeVariables.length)return this.sizeVariables[0].getSize(a,c)};e.prototype.getSizeRangeAtScale=function(a,c){if(this.sizeVariables.length)return this.sizeVariables[0].getSizeRangeAtScale(a,c)};e.prototype._resetVariables=function(){this.colorVariables=[];this.opacityVariables=[];this.rotationVariables=[];this.sizeVariables=[]};d([c.property()],e.prototype,"visualVariables",null);return e=d([c.subclass("esri.renderers.visualVariables.VisualVariableFactory")],
e)}(c.declared(k))})},"esri/symbols/support/utils":function(){define("require exports ../../Color ../../symbols ../../core/compilerUtils ../../core/has ../../core/Logger ../../core/screenUtils ./gfxUtils ./Symbol3DMaterial".split(" "),function(b,e,m,d,k,l,h,a,c,f){function n(a,c){if(null==c)return a;a=a.toRgba();a[3]*=c;return new m(a)}function g(a,c,b){(a=a.symbolLayers)&&a.forEach(function(a){if(a){var d=a.material;c=c||d&&d.color||null!=b&&r;var e=n(c,b);d?a.material.color=e:a.material=new f.default({color:e});
null!=b&&"outline"in a&&a.outline&&a.outline.color&&(a.outline.color=n(a.outline.color,b))}})}function q(a,c,b){(a=a.symbolLayers)&&a.forEach(function(a){if(a)switch(a.type){case "icon":case "line":case "path":case "extrude":case "text":a.size=c;break;case "object":switch(b){case "width":a.width=c;break;case "depth":a.depth=c;break;case "height":a.height=c;break;case "width-and-depth":a.width=c;a.depth=c;break;default:a.width=c,a.depth=c,a.height=c}break;default:p.warn("symbolUtils: applySizeToSymbol",
"symbolLayer not supported")}})}Object.defineProperty(e,"__esModule",{value:!0});var p=h.getLogger("esri.symbols.support.utils"),t=/\/resource\/(.*?)\.svg$/,r=new m("white");e.getSymbolOutlineSize=function(b){if(!b)return 0;if(d.isSymbol3D(b)){var e=b.symbolLayers&&b.symbolLayers.length;e?(b=b.symbolLayers.getItemAt(e-1),b="outline"in b&&b.outline&&b.outline.size):b=void 0;return b||0}return(b=c.getStroke(b))&&a.px2pt(b.width)||0};e.isVolumetricSymbol=function(a){if(!a||!a.symbolLayers)return!1;switch(a.type){case "point-3d":return a.symbolLayers.some(function(a){return"object"===
a.type});case "line-3d":return a.symbolLayers.some(function(a){return"path"===a.type});case "polygon-3d":return a.symbolLayers.some(function(a){return"object"===a.type||"extrude"===a.type});default:return!1}};e.getIconHref=function(a,c){c=c.resource.href;return!l("esri-canvas-svg-support")&&a.styleOrigin&&t.test(c)?c.replace(t,"/resource/png/$1.png"):c};e.applyOpacityToColor=n;e.applyColorToSymbol=function(a,c,b){if(a&&(c||null!=b))if(c&&(c=new m(c)),d.isSymbol3D(a))g(a,c,b);else if(d.isSymbol2D(a)){if(c=
c||a.color)a.color=n(c,b);null!=b&&"outline"in a&&a.outline&&a.outline.color&&(a.outline.color=n(a.outline.color,b))}};e.applySizeToSymbol=function(a,c,b){if(a&&null!=c)if(d.isSymbol3D(a))q(a,c,b);else if(d.isSymbol2D(a))switch(a.type){case "simple-marker":a.size=c;break;case "picture-marker":b=a.width/a.height;1<b?(a.width=c,a.height=c*b):(a.width=c*b,a.height=c);break;case "simple-line":a.width=c;break;case "text":a.font.size=c;break;case "simple-fill":case "picture-fill":break;case "cim":break;
default:k.neverReached(a)}};e.applyRotationToSymbol=function(a,c,b){a&&null!=c&&(d.isSymbol3D(a)?(a=a.symbolLayers)&&a.forEach(function(a){if(a&&"object"===a.type)switch(b){case "tilt":a.tilt=c;break;case "roll":a.roll=c;break;default:a.heading=c}}):!d.isSymbol2D(a)||"simple-marker"!==a.type&&"picture-marker"!==a.type&&"text"!==a.type||(a.angle=c))}})},"esri/symbols/support/gfxUtils":function(){define("require exports ../../core/tsSupport/assignHelper ../../Color ../../request ../../core/ItemCache ../../core/promiseUtils ../../core/screenUtils".split(" "),
function(b,e,m,d,k,l,h,a){function c(b){if(!b)return null;var d,e=a.pt2px(b.width);switch(b.type){case "simple-fill":case "picture-fill":case "simple-marker":d=c(b.outline);break;case "simple-line":"none"!==b.style&&0!==e&&(d={color:b.color,style:t(b.style),width:e,cap:b.cap,join:"miter"===b.join?a.pt2px(b.miterLimit):b.join});break;default:d=null}return d}Object.defineProperty(e,"__esModule",{value:!0});var f=b.toUrl("../../symbols/patterns/"),n={type:"pattern",x:0,y:0,width:0,height:0,src:""},g=
{left:"start",center:"middle",right:"end",justify:"start"},q={top:"text-before-edge",middle:"central",baseline:"alphabetic",bottom:"text-after-edge"},p=new l(1E3);e.getSVGAlign=function(a){return a=(a=a.horizontalAlignment)&&g[a.toLowerCase()]||"middle"};e.getSVGBaseline=function(a){return(a=a.verticalAlignment)&&q[a.toLowerCase()]||"alphabetic"};e.getSVGBaselineShift=function(a){return"bottom"===a.verticalAlignment?"super":null};e.getFill=function(c){var b=c.style,d=null;if(c)switch(c.type){case "simple-marker":"cross"!==
b&&"x"!==b&&(d=c.color);break;case "simple-fill":"solid"===b?d=c.color:"none"!==b&&(d=m({},n,{src:f+b+".png",width:8,height:8}));break;case "picture-fill":d=m({},n,{src:c.url,width:a.pt2px(c.width)*c.xscale,height:a.pt2px(c.height)*c.yscale,x:a.pt2px(c.xoffset),y:a.pt2px(c.yoffset)});break;case "text":d=c.color}return d};e.getPatternUrlWithColor=function(a,c){var b=a+"-"+c;return void 0!==p.get(b)?h.resolve(p.get(b)):k(a,{responseType:"image"}).then(function(a){a=a.data;var d=a.naturalWidth,e=a.naturalHeight,
f=document.createElement("canvas");f.width=d;f.height=e;var g=f.getContext("2d");g.fillStyle=c;g.fillRect(0,0,d,e);g.globalCompositeOperation="destination-in";g.drawImage(a,0,0);a=f.toDataURL();p.put(b,a);return a})};e.getStroke=c;e.create2DColorRamp=function(a){var c=a.colors,b=a.numClasses,d=a.size;a=a.surface.createGroup();for(var d=(d||75)/b,e=0;e<b;e++)for(var f=e*d,g=0;g<b;g++){var h=c[e][g];a.createRect({x:g*d,y:f,width:d,height:d}).setFill(h).setStroke(null)}return a};var t=function(){var a=
{};return function(c){if(a[c])return a[c];var b=c.replace(/-/g,"");return a[c]=b}}();e.defaultThematicColor=new d([128,128,128])})},"esri/core/ItemCache":function(){define(["require","exports","./MemCache"],function(b,e,m){return function(){function b(b,d){this._storage=new m.Storage;this._storage.maxSize=b;d&&this._storage.registerRemoveFunc("",d)}b.prototype.put=function(b,d){this._storage.put(b,d,1)};b.prototype.pop=function(b){return this._storage.pop(b)};b.prototype.get=function(b){return this._storage.get(b)};
b.prototype.clear=function(){this._storage.clearAll()};b.prototype.destroy=function(){this._storage.clearAll()};return b}()})},"esri/core/MemCache":function(){define(["require","exports","./iteratorUtils","./lang","./PooledArray"],function(b,e,m,d,k){b=function(){function b(b,a,c){this._namespace=b;this._storage=a;this._removeFunc=!1;this._miss=this._hit=0;this._storage.register(this);this._namespace+=":";c&&(this._storage.registerRemoveFunc(this._namespace,c),this._removeFunc=!0)}Object.defineProperty(b.prototype,
"namespace",{get:function(){return this._namespace.slice(0,-1)},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"hitRate",{get:function(){return this._hit/(this._hit+this._miss)},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"size",{get:function(){return this._storage.size},enumerable:!0,configurable:!0});Object.defineProperty(b.prototype,"maxSize",{get:function(){return this._storage.maxSize},enumerable:!0,configurable:!0});b.prototype.resetHitRate=function(){this._hit=
this._miss=0};b.prototype.destroy=function(){this._storage.clear(this._namespace);this._removeFunc&&this._storage.deregisterRemoveFunc(this._namespace);this._storage.deregister(this)};b.prototype.put=function(b,a,c){this._storage.put(this._namespace+b,a,c)};b.prototype.get=function(b){b=this._storage.get(this._namespace+b);void 0===b?++this._miss:++this._hit;return b};b.prototype.pop=function(b){b=this._storage.pop(this._namespace+b);void 0===b?++this._miss:++this._hit;return b};b.prototype.clear=
function(){this._storage.clear(this._namespace)};b.prototype.clearAll=function(){this._storage.clearAll()};b.prototype.getStats=function(){return this._storage.getStats()};b.prototype.resetStats=function(){this._storage.resetStats()};return b}();(function(b){var e=function(){function a(a){void 0===a&&(a=10485760);this._maxSize=a;this._db=new Map;this._miss=this._hit=this._size=0;this._removeFuncs=[];this._users=new k}a.prototype.register=function(a){this._users.push(a)};a.prototype.deregister=function(a){this._users.removeUnordered(a)};
a.prototype.registerRemoveFunc=function(a,b){this._removeFuncs.push([a,b])};a.prototype.deregisterRemoveFunc=function(a){this._removeFuncs=this._removeFuncs.filter(function(c){return c[0]!==a})};Object.defineProperty(a.prototype,"size",{get:function(){return this._size},enumerable:!0,configurable:!0});Object.defineProperty(a.prototype,"maxSize",{get:function(){return this._maxSize},set:function(a){this._maxSize=Math.max(a,0);this._size>this._maxSize&&this._removeEntries()},enumerable:!0,configurable:!0});
a.prototype.put=function(a,b,d){if(this._db.has(a)){var c=this._db.get(a);this._size-=c.size;this._db.delete(a);this._notifyRemoved(a,c.entry)}d>this._maxSize?this._notifyRemoved(a,b):void 0===b?console.warn("Refusing to cache undefined entry "):!d||0>d?console.warn("Refusing to cache entry with invalid size "+d):(this._db.set(a,{entry:b,size:d}),this._size+=d,this._size>this._maxSize&&this._removeEntries())};a.prototype.pop=function(a){if(this._db.has(a)){var c=this._db.get(a);this._size-=c.size;
this._db.delete(a);++this._hit;return c.entry}++this._miss};a.prototype.get=function(a){var c=this._db.get(a);if(void 0===c)++this._miss;else return this._db.delete(a),this._db.set(a,c),++this._hit,c.entry};a.prototype.getStats=function(){var a=this,b={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},e={};this._db.forEach(function(c,b){a._users.forEach(function(a){a=a.namespace;if(d.startsWith(b,
a))return e[a]=(e[a]||0)+c.size,!1})});var g={};this._users.forEach(function(a){var c=a.namespace;!isNaN(a.hitRate)&&0<a.hitRate?(e[c]=e[c]||0,g[c]=Math.round(100*a.hitRate)+"%"):g[c]="0%"});var h=Object.keys(e);h.forEach(function(c){return e[c]=e[c]/a._size*100});h.sort(function(a,c){return e[c]-e[a]});h.forEach(function(a){return b[a]=Math.round(e[a])+"% / "+g[a]});return b};a.prototype.resetStats=function(){this._hit=this._miss=0;this._users.forEach(function(a){return a.resetHitRate()})};a.prototype.clear=
function(a){var c=this;this._db.forEach(function(b,e){d.startsWith(e,a)&&(c._size-=b.size,c._db.delete(e),c._notifyRemoved(e,b.entry))})};a.prototype.clearAll=function(){var a=this;this._db.forEach(function(c,b){a._notifyRemoved(b,c.entry)});this._size=0;this._db.clear()};a.prototype._getHitRate=function(){return this._hit/(this._hit+this._miss)};a.prototype._notifyRemoved=function(a,b){this._removeFuncs.forEach(function(c){if(d.startsWith(a,c[0]))c[1](b)})};a.prototype._removeEntries=function(){var a=
this;m.everyMap(this._db,function(c,b){a._size-=c.size;a._db.delete(b);a._notifyRemoved(b,c.entry);return a._size>.9*a.maxSize})};return a}();b.Storage=e})(b||(b={}));return b})},"esri/core/iteratorUtils":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.everyMap=Map.prototype.entries?function(b,d){b=b.entries();for(var e=b.next();!e.done;e=b.next())if(!1===d(e.value[1],e.value[0]))return!1;return!0}:function(b,d){var e=!0;b.forEach(function(b,
h){e&&(e=!1!==d(b,h))});return e}})},"esri/core/PooledArray":function(){define(["require","exports","./tsSupport/generatorHelper","./arrayUtils","./HeapSort"],function(b,e,m,d,k){return function(){function b(b){var a=this;this.data=[];this._length=0;this._allocator=null;this._deallocator=function(){};this._shrink=function(){};this._hint=new d.RemoveHint;b&&(b.initialSize&&(this.data=Array(b.initialSize)),b.allocator?(this._allocator=b.allocator,this._deallocator=b.deallocator):"deallocator"in b&&
(this._deallocator=b.deallocator),b.shrink&&(this._shrink=function(){a.data.length>1.5*a.length&&(a.data.length=Math.floor(1.1*a.length))}))}b.prototype.toArray=function(){return this.data.slice(0,this.length)};Object.defineProperty(b.prototype,"length",{get:function(){return this._length},set:function(b){if(b>this._length)if(this._allocator)for(;this._length<b;)this.data[this._length++]=this._allocator(this.data[this._length]);else this._length=b;else{if(this._deallocator)for(var a=b;a<this._length;++a)this.data[a]=
this._deallocator(this.data[a]);this._length=b;this._shrink()}},enumerable:!0,configurable:!0});b.prototype.clear=function(){this.length=0};b.prototype.prune=function(){this.clear();this.data=[]};b.prototype.equal=function(b){return d.equals(this.data,b.data)};b.prototype.push=function(b){return this.data[this._length++]=b};b.prototype.pushArray=function(b){for(var a=0;a<b.length;a++)this.data[this._length++]=b[a];return this.back()};b.prototype.pushNew=function(){this._allocator&&(this.data[this.length]=
this._allocator(this.data[this.length]));++this._length;return this.back()};b.prototype.pop=function(){if(0!==this.length){var b=this.data[this.length-1];--this.length;this._shrink();return b}};b.prototype.removeMany=function(b){var a=this,c=[];this.data=this.data.filter(function(d,e){if(e>=a.length)return!1;if(0>b.indexOf(d))return!0;c.push(d);return!1});this._length=this.data.length;return c};b.prototype.iterableRemoveMany=function(b,a){var c,d;return m(this,function(e){switch(e.label){case 0:c=
[],d=0,e.label=1;case 1:if(!(d<this.length)||d>=this.length)return[3,4];0>b.indexOf(this.data[d])&&c.push(this.data[d]);return a()?[4]:[3,3];case 2:e.sent(),e.label=3;case 3:return++d,[3,1];case 4:return this.data=c,this._length=this.data.length,[2]}})};b.prototype.removeUnordered=function(b){b=d.removeUnordered(this.data,b,this.length,this._hint);void 0!==b&&--this.length;return b};b.prototype.removeUnorderedIndex=function(b){if(!(b>=this.length||0>b))return this.swapElements(b,this.length-1),this.pop()};
b.prototype.removeUnorderedMany=function(b,a,c){void 0===a&&(a=b.length);this.length=d.removeUnorderedMany(this.data,b,this.length,a,this._hint,c)};b.prototype.front=function(){if(0!==this.length)return this.data[0]};b.prototype.back=function(){if(0!==this.length)return this.data[this.length-1]};b.prototype.swapElements=function(b,a){var c;b>=this.length||a>=this.length||b===a||(c=[this.data[a],this.data[b]],this.data[b]=c[0],this.data[a]=c[1])};b.prototype.sort=function(b){k.sort(this.data,0,this.length,
b)};b.prototype.iterableSort=function(b,a){return k.iterableSort(this.data,0,this.length,b,a)};b.prototype.some=function(b,a){for(var c=0;c<this.length;++c)if(b.call(a,this.data[c],c,this.data))return!0;return!1};b.prototype.find=function(b,a){for(var c=0;c<this.length;++c){var d=this.data[c];if(b.call(a,d,c,this.data))return d}};b.prototype.filter=function(d,a,c){c=c||new b;for(var e=0;e<this.length;++e)d.call(a,this.data[e],e,this.data)&&c.push(this.data[e]);return c};b.prototype.forEach=function(b,
a){for(var c=this.length,d=0;d<Math.min(this.length,c);++d)b.call(a,this.data[d],d,this.data)};b.prototype.iterableForEach=function(){var b;return m(this,function(a){switch(a.label){case 0:b=0,a.label=1;case 1:return b<this.length?[4,this.data[b]]:[3,4];case 2:a.sent(),a.label=3;case 3:return++b,[3,1];case 4:return[2]}})};b.prototype.map=function(b,a){for(var c=Array(this.length),d=0;d<this.length;++d)c[d]=b.call(a,this.data[d],d,this.data);return c};return b}()})},"esri/core/HeapSort":function(){define(["require",
"exports","./tsSupport/generatorHelper"],function(b,e,m){var d;(function(b){function d(a,c,b,d){for(var e=c,f=b>>>1,h=a[e-1];c<=f;){c=e<<1;c<b&&0>d(a[c-1],a[c])&&++c;var n=a[c-1];if(0>=d(n,h))break;a[e-1]=n;e=c}a[e-1]=h}function e(a,c){return a<c?-1:a>c?1:0}b.sort=function(a,c,b,h){void 0===c&&(c=0);void 0===b&&(b=a.length);void 0===h&&(h=e);for(var f=b>>>1;f>c;f--)d(a,f,b,h);for(var n=c+1,f=b-1;f>c;f--)b=a[c],a[c]=a[f],a[f]=b,d(a,n,f,h)};b.iterableSort=function(a,c,b,h,g){var f,p,k;return m(this,
function(n){switch(n.label){case 0:void 0===c&&(c=0),void 0===b&&(b=a.length),void 0===h&&(h=e),f=b>>>1,n.label=1;case 1:if(!(f>c))return[3,4];d(a,f,b,h);return g&&g()?[4]:[3,3];case 2:n.sent(),n.label=3;case 3:return f--,[3,1];case 4:p=c+1,f=b-1,n.label=5;case 5:if(!(f>c))return[3,8];k=a[c];a[c]=a[f];a[f]=k;d(a,p,f,h);return g&&g()?[4]:[3,7];case 6:n.sent(),n.label=7;case 7:return f--,[3,5];case 8:return[2]}})}})(d||(d={}));return d})},"esri/renderers/support/ClassBreakInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../symbols ../../core/JSONSupport ../../core/accessorSupport/decorators ../../symbols/support/jsonUtils".split(" "),
function(b,e,m,d,k,l,h,a){Object.defineProperty(e,"__esModule",{value:!0});b=function(c){function b(){var a=null!==c&&c.apply(this,arguments)||this;a.description=null;a.label=null;a.minValue=null;a.maxValue=0;a.symbol=null;return a}m(b,c);e=b;b.prototype.clone=function(){return new e({description:this.description,label:this.label,minValue:this.minValue,maxValue:this.maxValue,symbol:this.symbol?this.symbol.clone():null})};var e;d([h.property({type:String,json:{write:!0}})],b.prototype,"description",
void 0);d([h.property({type:String,json:{write:!0}})],b.prototype,"label",void 0);d([h.property({type:Number,json:{read:{source:"classMinValue"},write:{target:"classMinValue"}}})],b.prototype,"minValue",void 0);d([h.property({type:Number,json:{read:{source:"classMaxValue"},write:{target:"classMaxValue"}}})],b.prototype,"maxValue",void 0);d([h.property({types:k.symbolTypesRenderer,json:{origins:{"web-scene":{read:a.read,write:{target:{symbol:{types:k.symbolTypesRenderer3D}},writer:a.writeTarget}}},
read:a.read,write:a.writeTarget}})],b.prototype,"symbol",void 0);return b=e=d([h.subclass("esri.renderers.support.ClassBreakInfo")],b)}(h.declared(l));e.ClassBreakInfo=b;e.default=b})},"esri/renderers/DotDensityRenderer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/assignHelper ../core/tsSupport/generatorHelper ../core/tsSupport/awaiterHelper ../Color ../core/lang ../core/accessorSupport/decorators ./Renderer ./mixins/VisualVariablesRenderer ./support/AttributeColorInfo ./support/DotDensityLegendOptions ../support/arcadeUtils ../symbols/SimpleFillSymbol ../symbols/SimpleLineSymbol".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v){return function(b){function e(c){c=b.call(this,c)||this;c.attributes=null;c.backgroundColor=new a([0,0,0,0]);c.blendDots=!0;c.dotShape="square";c.dotSize=1;c.legendOptions=null;c.outline=new v;c.referenceDotValue=null;c.referenceScale=null;c.seed=1;c.type="dot-density";return c}m(e,b);g=e;e.prototype.calculateDotValue=function(a){if(null==this.referenceScale)return this.referenceDotValue;a=a/this.referenceScale*this.referenceDotValue;return 1>a?1:a};e.prototype.getSymbol=
function(a,c){return new r({outline:this.outline})};e.prototype.getSymbols=function(){return[this.getSymbol(null)]};e.prototype.clone=function(){return new g({attributes:c.clone(this.attributes),backgroundColor:c.clone(this.backgroundColor),blendDots:c.clone(this.blendDots),dotShape:c.clone(this.dotShape),dotSize:c.clone(this.dotSize),legendOptions:c.clone(this.legendOptions),outline:c.clone(this.outline),referenceScale:c.clone(this.referenceScale),referenceDotValue:c.clone(this.referenceDotValue),
visualVariables:c.clone(this.visualVariables)})};e.prototype.getControllerHash=function(){var a=this.attributes.map(function(a){return a.field||a.valueExpression||""}),c=this.outline&&JSON.stringify(this.outline.toJSON())||"";return a+"-"+c};e.prototype.collectRequiredFields=function(a,c){return h(this,void 0,void 0,function(){var b,d,e;return l(this,function(f){switch(f.label){case 0:return[4,this.collectVVRequiredFields(a,c)];case 1:f.sent();b=0;for(d=this.attributes;b<d.length;b++)e=d[b],e.valueExpression&&
t.extractFieldNames(e.valueExpression).forEach(function(c){a.add(c)}),e.field&&a.add(e.field);return[2]}})})};var g;d([f.property({type:[q],json:{write:!0}})],e.prototype,"attributes",void 0);d([f.property({type:a,json:{write:!0}})],e.prototype,"backgroundColor",void 0);d([f.property({type:Boolean,json:{write:!0}})],e.prototype,"blendDots",void 0);d([f.property({type:String,json:{write:!0}})],e.prototype,"dotShape",void 0);d([f.property({type:Number,json:{write:!0}})],e.prototype,"dotSize",void 0);
d([f.property({type:p,json:{write:!0}})],e.prototype,"legendOptions",void 0);d([f.property({type:v,json:{default:null,write:!0}})],e.prototype,"outline",void 0);d([f.property({type:Number,json:{write:!0}})],e.prototype,"referenceDotValue",void 0);d([f.property({type:Number,json:{write:!0}})],e.prototype,"referenceScale",void 0);d([f.property({type:Number,json:{write:!0}})],e.prototype,"seed",void 0);d([f.enumeration.serializable()({dotDensity:"dot-density"})],e.prototype,"type",void 0);return e=g=
d([f.subclass("esri.renderers.DotDensityRenderer")],e)}(f.declared(n,g))})},"esri/renderers/support/AttributeColorInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../Color ../../core/JSONSupport ../../core/Logger ../../core/accessorSupport/decorators ../../core/accessorSupport/ensureType".split(" "),function(b,e,m,d,k,l,h,a,c){var f=h.getLogger("esri.renderers.support.AttributeColorInfo");return function(b){function e(a){a=b.call(this,
a)||this;a.color=null;a.field=null;a.label=null;a.valueExpression=null;a.valueExpressionTitle=null;return a}m(e,b);h=e;e.prototype.castField=function(a){return null==a?a:"function"===typeof a?(f.error(".field: field must be a string value"),null):c.ensureString(a)};e.prototype.clone=function(){return new h({color:this.color&&this.color.clone(),field:this.field,label:this.label,valueExpression:this.valueExpression,valueExpressionTitle:this.valueExpressionTitle})};var h;d([a.property({type:k,json:{type:[Number],
write:!0}})],e.prototype,"color",void 0);d([a.property({type:String,json:{write:!0}})],e.prototype,"field",void 0);d([a.cast("field")],e.prototype,"castField",null);d([a.property({type:String,json:{write:!0}})],e.prototype,"label",void 0);d([a.property({type:String,json:{write:!0}})],e.prototype,"valueExpression",void 0);d([a.property({type:String,json:{write:!0}})],e.prototype,"valueExpressionTitle",void 0);return e=h=d([a.subclass("esri.renderers.support.AttributeColorInfo")],e)}(a.declared(l))})},
"esri/renderers/support/DotDensityLegendOptions":function(){define("require exports ../../core/tsSupport/decorateHelper ../../core/tsSupport/declareExtendsHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){return function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.unit=null;return a}d(a,b);c=a;a.prototype.clone=function(){return new c({unit:this.unit})};var c;m([l.property({type:String,json:{write:!0}})],a.prototype,"unit",void 0);
return a=c=m([l.subclass("esri.renderers.support.DotDensityLegendOptions")],a)}(l.declared(k))})},"esri/renderers/HeatmapRenderer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/generatorHelper ../core/tsSupport/awaiterHelper ../Color ../core/lang ../core/accessorSupport/decorators ../layers/support/fieldUtils ./Renderer ./support/HeatmapColorStop".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){return function(b){function e(a){a=
b.call(this)||this;a.blurRadius=10;a.colorStops=[new g.HeatmapColorStop({ratio:0,color:new h("rgba(255, 140, 0, 0)")}),new g.HeatmapColorStop({ratio:.75,color:new h("rgba(255, 140, 0, 1)")}),new g.HeatmapColorStop({ratio:.9,color:new h("rgba(255, 0,   0, 1)")})];a.field=null;a.fieldOffset=0;a.maxPixelIntensity=100;a.minPixelIntensity=0;a.type="heatmap";return a}m(e,b);n=e;e.prototype.collectRequiredFields=function(a,c){return l(this,void 0,void 0,function(){var b;return k(this,function(d){(b=this.field)&&
"string"===typeof b&&f.collectField(a,c,b);return[2]})})};e.prototype.clone=function(){return new n({blurRadius:this.blurRadius,colorStops:a.clone(this.colorStops),field:this.field,maxPixelIntensity:this.maxPixelIntensity,minPixelIntensity:this.minPixelIntensity})};var n;d([c.property({type:Number,json:{write:!0}})],e.prototype,"blurRadius",void 0);d([c.property({type:[g.HeatmapColorStop],json:{write:!0}})],e.prototype,"colorStops",void 0);d([c.property({type:String,json:{write:!0}})],e.prototype,
"field",void 0);d([c.property({type:Number,json:{write:{overridePolicy:function(a,c,b){return{enabled:null==b}}}}})],e.prototype,"fieldOffset",void 0);d([c.property({type:Number,json:{write:!0}})],e.prototype,"maxPixelIntensity",void 0);d([c.property({type:Number,json:{write:!0}})],e.prototype,"minPixelIntensity",void 0);d([c.enumeration.serializable()({heatmap:"heatmap"})],e.prototype,"type",void 0);return e=n=d([c.subclass("esri.renderers.HeatmapRenderer")],e)}(c.declared(n))})},"esri/renderers/support/HeatmapColorStop":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../Color ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h){Object.defineProperty(e,"__esModule",{value:!0});b=function(a){function c(c){c=a.call(this)||this;c.color=null;c.ratio=null;return c}m(c,a);b=c;c.prototype.clone=function(){return new b({color:this.color,ratio:this.ratio})};var b;d([h.property({type:k,json:{write:!0}})],c.prototype,"color",void 0);d([h.property({type:Number,json:{write:!0}})],c.prototype,"ratio",void 0);return c=b=d([h.subclass("esri.renderers.support.HeatmapColorStop")],c)}(h.declared(l));e.HeatmapColorStop=
b;e.default=b})},"esri/renderers/SimpleRenderer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/generatorHelper ../core/tsSupport/awaiterHelper ../symbols ../core/lang ../core/accessorSupport/decorators ./Renderer ./mixins/VisualVariablesRenderer ../symbols/support/jsonUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){return function(b){function e(a){a=b.call(this)||this;a.description=null;a.label=null;a.symbol=null;a.type=
"simple";return a}m(e,b);f=e;e.prototype.writeSymbolWebScene=function(a,c,b,d){g.writeTarget(a,c,b,d)};e.prototype.writeSymbol=function(a,c,b,d){g.writeTarget(a,c,b,d)};e.prototype.readSymbol=function(a,c,b){return g.read(a,c,b)};e.prototype.collectRequiredFields=function(a,c){return l(this,void 0,void 0,function(){return k(this,function(b){return[2,this.collectVVRequiredFields(a,c)]})})};e.prototype.getSymbol=function(a,c){return this.symbol};e.prototype.getSymbols=function(){return this.symbol?
[this.symbol]:[]};e.prototype.clone=function(){return new f({description:this.description,label:this.label,symbol:this.symbol&&this.symbol.clone(),visualVariables:a.clone(this.visualVariables),authoringInfo:this.authoringInfo&&this.authoringInfo.clone()})};var f;d([c.property({type:String,json:{write:!0}})],e.prototype,"description",void 0);d([c.property({type:String,json:{write:!0}})],e.prototype,"label",void 0);d([c.property({types:h.symbolTypesRenderer})],e.prototype,"symbol",void 0);d([c.writer("web-scene",
"symbol",{symbol:{types:h.symbolTypesRenderer3D}})],e.prototype,"writeSymbolWebScene",null);d([c.writer("symbol")],e.prototype,"writeSymbol",null);d([c.reader("symbol")],e.prototype,"readSymbol",null);d([c.enumeration.serializable()({simple:"simple"})],e.prototype,"type",void 0);return e=f=d([c.subclass("esri.renderers.SimpleRenderer")],e)}(c.declared(f,n))})},"esri/renderers/StretchRenderer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/paramHelper ../core/lang ../core/accessorSupport/decorators ./Renderer ./support/stretchRendererUtils ../tasks/support/ColorRamp ../tasks/support/colorRamps".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){return function(a){function b(){var c=null!==a&&a.apply(this,arguments)||this;c.colorRamp=null;c.computeGamma=!1;c.dynamicRangeAdjustment=!0;c.gamma=[];c.maxPercent=null;c.minPercent=null;c.numberOfStandardDeviations=null;c.outputMax=null;c.outputMin=null;c.sigmoidStrengthLevel=null;c.statistics=[];c.useGamma=!1;c.stretchType="none";c.type="raster-stretch";return c}m(b,a);e=b;b.prototype.readColorRamp=function(a,c){if(a)return n.fromJSON(a)};b.prototype.clone=function(){return new e({stretchType:this.stretchType,
outputMin:this.outputMin,outputMax:this.outputMax,useGamma:this.useGamma,computeGamma:this.computeGamma,statistics:l.clone(this.statistics),gamma:l.clone(this.gamma),sigmoidStrengthLevel:this.sigmoidStrengthLevel,numberOfStandardDeviations:this.numberOfStandardDeviations,minPercent:this.minPercent,maxPercent:this.maxPercent,colorRamp:l.clone(this.colorRamp),dynamicRangeAdjustment:this.dynamicRangeAdjustment})};var e;d([h.property({type:f,json:{write:!0}})],b.prototype,"colorRamp",void 0);d([h.reader("colorRamp")],
b.prototype,"readColorRamp",null);d([h.property({type:Boolean,json:{write:!0}})],b.prototype,"computeGamma",void 0);d([h.property({type:Boolean,json:{write:{target:"dra"},read:{source:"dra"}}})],b.prototype,"dynamicRangeAdjustment",void 0);d([h.property({type:[Number],json:{write:{allowNull:!0}}})],b.prototype,"gamma",void 0);d([h.property({type:Number,json:{write:{allowNull:!0}}})],b.prototype,"maxPercent",void 0);d([h.property({type:Number,json:{write:{allowNull:!0}}})],b.prototype,"minPercent",
void 0);d([h.property({type:Number,json:{write:{allowNull:!0}}})],b.prototype,"numberOfStandardDeviations",void 0);d([h.property({type:Number,json:{read:{source:"max"},write:{target:"max",allowNull:!0}}})],b.prototype,"outputMax",void 0);d([h.property({type:Number,json:{read:{source:"min"},write:{target:"min",allowNull:!0}}})],b.prototype,"outputMin",void 0);d([h.property({type:Number,json:{write:{allowNull:!0}}})],b.prototype,"sigmoidStrengthLevel",void 0);d([h.property({type:[[Number]],json:{write:{allowNull:!0}}})],
b.prototype,"statistics",void 0);d([h.property({type:Boolean,json:{write:!0}})],b.prototype,"useGamma",void 0);d([h.property({type:c.stretchTypeJSONDict.apiValues,json:{type:c.stretchTypeJSONDict.jsonValues,read:c.stretchTypeJSONDict.read,write:c.stretchTypeJSONDict.write}})],b.prototype,"stretchType",void 0);d([h.enumeration.serializable()({rasterStretch:"raster-stretch"})],b.prototype,"type",void 0);return b=e=d([h.subclass("esri.renderers.StretchRenderer")],b)}(h.declared(a))})},"esri/renderers/support/stretchRendererUtils":function(){define(["require",
"exports","../../core/kebabDictionary"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.stretchTypeJSONDict=new m.default({none:"none",standardDeviation:"standard-deviation",histogramEqualization:"histogram-equalization",minMax:"min-max",percentClip:"percent-clip",sigmoid:"sigmoid"})})},"esri/renderers/UniqueValueRenderer":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/paramHelper ../core/tsSupport/generatorHelper ../core/tsSupport/awaiterHelper ../symbols ../symbols ../core/arrayUtils ../core/Error ../core/lang ../core/Logger ../core/urlUtils ../core/accessorSupport/decorators ../core/accessorSupport/ensureType ../layers/support/fieldUtils ../portal/Portal ./Renderer ./mixins/VisualVariablesRenderer ./support/diffUtils ./support/LegendOptions ./support/UniqueValueInfo ../support/arcadeUtils ../symbols/support/jsonUtils ../symbols/support/styleUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x,w,A,B,F,C){var E=q.getLogger("esri.renderers.UniqueValueRenderer"),G=r.ensureType(A.default);return function(b){function e(a){a=b.call(this)||this;a._valueInfoMap={};a._isDefaultSymbolDerived=!1;a.type="unique-value";a.backgroundFillSymbol=null;a.field=null;a.field2=null;a.field3=null;a.valueExpression=null;a.valueExpressionTitle=null;a.legendOptions=null;a.defaultLabel=null;a.fieldDelimiter=null;a.portal=null;a.styleOrigin=null;a.diff={uniqueValueInfos:function(a,
c){if(a||c){if(!a||!c)return{type:"complete",oldValue:a,newValue:c};for(var b=!1,d={type:"collection",added:[],removed:[],changed:[],unchanged:[]},e=function(e){var g=f.find(a,function(a){return a.value===c[e].value});g?x.diff(g,c[e])?(d.changed.push({type:"complete",oldValue:g,newValue:c[e]}),b=!0):d.unchanged.push({oldValue:g,newValue:c[e]}):(d.added.push(c[e]),b=!0)},g=0;g<c.length;g++)e(g);e=function(e){f.find(c,function(c){return c.value===a[e].value})||(d.removed.push(a[e]),b=!0)};for(g=0;g<
a.length;g++)e(g);return b?d:void 0}}};a._set("uniqueValueInfos",[]);return a}m(e,b);q=e;e.prototype.writeBackgroundFillSymbolWebScene=function(a,c,b,d){F.writeTarget(a,c,b,d)};e.prototype.castField=function(a){return null==a||"function"===typeof a?a:r.ensureString(a)};e.prototype.writeField=function(a,c,b,d){"string"===typeof a?c[b]=a:d&&d.messages?d.messages.push(new n("property:unsupported","UniqueValueRenderer.field set to a function cannot be written to JSON")):E.error(".field: cannot write field to JSON since it's not a string value")};
Object.defineProperty(e.prototype,"compiledFunc",{get:function(){return B.createFunction(this.valueExpression)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"defaultSymbol",{set:function(a){this._isDefaultSymbolDerived=!1;this._set("defaultSymbol",a)},enumerable:!0,configurable:!0});e.prototype.readDefaultSymbol=function(a,c,b){return F.read(a,c,b)};e.prototype.writeDefaultSymbolWebScene=function(a,c,b,d){this._isDefaultSymbolDerived||F.writeTarget(a,c,b,d)};e.prototype.writeDefaultSymbol=
function(a,c,b,d){this._isDefaultSymbolDerived||F.writeTarget(a,c,b,d)};e.prototype.readPortal=function(a,c,b){return b.portal||u.getDefault()};e.prototype.readStyleOrigin=function(a,c,b){if(c.styleName)return Object.freeze({styleName:c.styleName});if(c.styleUrl)return a=p.fromJSON(c.styleUrl,b),Object.freeze({styleUrl:a})};e.prototype.writeStyleOrigin=function(a,c,b,d){a.styleName?c.styleName=a.styleName:a.styleUrl&&(c.styleUrl=p.toJSON(a.styleUrl,d))};Object.defineProperty(e.prototype,"uniqueValueInfos",
{set:function(a){this.styleOrigin?E.error("#uniqueValueInfos\x3d","Cannot modify unique value infos of a UniqueValueRenderer created from a web style"):(this._set("uniqueValueInfos",a),this._updateValueInfoMap())},enumerable:!0,configurable:!0});e.prototype.addUniqueValueInfo=function(a,c){this.styleOrigin?E.error("#addUniqueValueInfo()","Cannot modify unique value infos of a UniqueValueRenderer created from a web style"):(a="object"===typeof a?G(a):new A.default({value:a,symbol:c}),this.uniqueValueInfos.push(a),
this._valueInfoMap[a.value]=a)};e.prototype.removeUniqueValueInfo=function(a){if(this.styleOrigin)E.error("#removeUniqueValueInfo()","Cannot modify unique value infos of a UniqueValueRenderer created from a web style");else for(var c=0;c<this.uniqueValueInfos.length;c++)if(this.uniqueValueInfos[c].value===a+""){delete this._valueInfoMap[a];this.uniqueValueInfos.splice(c,1);break}};e.prototype.getUniqueValueInfo=function(a,c){var b=this.field,d=a.attributes,e;this.valueExpression?e=B.executeFunction(this.compiledFunc,
B.createExecContext(a,B.getViewInfo(c))):"function"!==typeof b&&this.field2?(a=this.field2,c=this.field3,e=[],b&&e.push(d[b]),a&&e.push(d[a]),c&&e.push(d[c]),e=e.join(this.fieldDelimiter||"")):"function"===typeof b?e=b(a):b&&(e=d[b]);return this._valueInfoMap[e+""]};e.prototype.getSymbol=function(a,c){return(a=this.getUniqueValueInfo(a,c))&&a.symbol||this.defaultSymbol};e.prototype.getSymbols=function(){for(var a=[],c=0,b=this.uniqueValueInfos;c<b.length;c++){var d=b[c];d.symbol&&a.push(d.symbol)}this.defaultSymbol&&
a.push(this.defaultSymbol);return a};e.prototype.clone=function(){var a=new q({field:this.field,field2:this.field2,field3:this.field3,defaultLabel:this.defaultLabel,defaultSymbol:g.clone(this.defaultSymbol),valueExpression:this.valueExpression,valueExpressionTitle:this.valueExpressionTitle,fieldDelimiter:this.fieldDelimiter,visualVariables:g.clone(this.visualVariables),legendOptions:g.clone(this.legendOptions),authoringInfo:this.authoringInfo&&this.authoringInfo.clone(),backgroundFillSymbol:g.clone(this.backgroundFillSymbol)});
this._isDefaultSymbolDerived&&(a._isDefaultSymbolDerived=!0);a._set("portal",this.portal);var c=g.clone(this.uniqueValueInfos);this.styleOrigin&&(a._set("styleOrigin",Object.freeze(g.clone(this.styleOrigin))),Object.freeze(c));a._set("uniqueValueInfos",c);a._updateValueInfoMap();return a};e.prototype.collectRequiredFields=function(a,c){return h(this,void 0,void 0,function(){return l(this,function(b){switch(b.label){case 0:return[4,this.collectVVRequiredFields(a,c)];case 1:return b.sent(),v.collectField(a,
c,this.field),v.collectField(a,c,this.field2),v.collectField(a,c,this.field3),[4,v.collectArcadeFieldNames(a,c,this.valueExpression)];case 2:return b.sent(),[2]}})})};e.prototype.populateFromStyle=function(){var c=this;return C.fetchStyle(this.styleOrigin,{portal:this.portal}).then(function(b){var d=[];c._valueInfoMap={};b&&b.data&&Array.isArray(b.data.items)&&b.data.items.forEach(function(e){var f=new a.WebStyleSymbol({styleUrl:b.styleUrl,styleName:b.styleName,portal:c.portal,name:e.name});c.defaultSymbol||
e.name!==b.data.defaultItem||(c.defaultSymbol=f,c._isDefaultSymbolDerived=!0);f=new A.default({value:e.name,symbol:f});d.push(f);c._valueInfoMap[e.name]=f});c._set("uniqueValueInfos",Object.freeze(d));!c.defaultSymbol&&c.uniqueValueInfos.length&&(c.defaultSymbol=c.uniqueValueInfos[0].symbol,c._isDefaultSymbolDerived=!0);return c})};e.prototype._updateValueInfoMap=function(){var a=this;this._valueInfoMap={};this.uniqueValueInfos.forEach(function(c){return a._valueInfoMap[c.value+""]=c})};e.fromPortalStyle=
function(a,c){var b=new q(c&&c.properties);b._set("styleOrigin",Object.freeze({styleName:a}));b._set("portal",c&&c.portal||u.getDefault());c=b.populateFromStyle();c.catch(function(c){E.error("#fromPortalStyle('"+a+"'[, ...])","Failed to create unique value renderer from style name",c)});return c};e.fromStyleUrl=function(a,c){c=new q(c&&c.properties);c._set("styleOrigin",Object.freeze({styleUrl:a}));c=c.populateFromStyle();c.catch(function(c){E.error("#fromStyleUrl('"+a+"'[, ...])","Failed to create unique value renderer from style URL",
c)});return c};var q;d([t.enumeration.serializable()({uniqueValue:"unique-value"})],e.prototype,"type",void 0);d([t.property({types:{base:a.BaseSymbol,key:"type",typeMap:{"simple-fill":c.symbolTypesRenderer.typeMap["simple-fill"],"picture-fill":c.symbolTypesRenderer.typeMap["picture-fill"],"polygon-3d":c.symbolTypesRenderer.typeMap["polygon-3d"]}},json:{read:F.read,write:F.writeTarget}})],e.prototype,"backgroundFillSymbol",void 0);d([t.writer("web-scene","backgroundFillSymbol",{backgroundFillSymbol:{type:a.PolygonSymbol3D}})],
e.prototype,"writeBackgroundFillSymbolWebScene",null);d([t.property({json:{type:String,read:{source:"field1"},write:{target:"field1"}}})],e.prototype,"field",void 0);d([t.cast("field")],e.prototype,"castField",null);d([t.writer("field")],e.prototype,"writeField",null);d([t.property({type:String,json:{write:!0}})],e.prototype,"field2",void 0);d([t.property({type:String,json:{write:!0}})],e.prototype,"field3",void 0);d([t.property({type:String,json:{write:!0}})],e.prototype,"valueExpression",void 0);
d([t.property({type:String,json:{write:!0}})],e.prototype,"valueExpressionTitle",void 0);d([t.property({dependsOn:["valueExpression"]})],e.prototype,"compiledFunc",null);d([t.property({type:w.default,json:{write:!0}})],e.prototype,"legendOptions",void 0);d([t.property({type:String,json:{write:!0}})],e.prototype,"defaultLabel",void 0);d([t.property({types:c.symbolTypesRenderer})],e.prototype,"defaultSymbol",null);d([t.reader("defaultSymbol")],e.prototype,"readDefaultSymbol",null);d([t.writer("web-scene",
"defaultSymbol",{defaultSymbol:{types:c.symbolTypesRenderer3D}})],e.prototype,"writeDefaultSymbolWebScene",null);d([t.writer("defaultSymbol")],e.prototype,"writeDefaultSymbol",null);d([t.property({type:String,json:{write:!0}})],e.prototype,"fieldDelimiter",void 0);d([t.property({type:u,readOnly:!0})],e.prototype,"portal",void 0);d([t.reader("portal",["styleName"])],e.prototype,"readPortal",null);d([t.property({readOnly:!0})],e.prototype,"styleOrigin",void 0);d([t.reader("styleOrigin",["styleName",
"styleUrl"])],e.prototype,"readStyleOrigin",null);d([t.writer("styleOrigin",{styleName:{type:String},styleUrl:{type:String}})],e.prototype,"writeStyleOrigin",null);d([t.property({type:[A.default],json:{write:{overridePolicy:function(){return this.styleOrigin?{enabled:!1}:{enabled:!0}}}}})],e.prototype,"uniqueValueInfos",null);d([k(1,t.cast(c.ensureType))],e.prototype,"addUniqueValueInfo",null);return e=q=d([t.subclass("esri.renderers.UniqueValueRenderer")],e)}(t.declared(z,y))})},"esri/renderers/support/diffUtils":function(){define("require exports ../../core/Accessor ../../core/Collection ../../core/maybe ../../core/accessorSupport/utils".split(" "),
function(b,e,m,d,k,l){function h(a){return a instanceof d?Object.keys(a.items):a instanceof m?l.getProperties(a).keys():a?Object.keys(a):[]}function a(a,c){return a instanceof d?a.items[c]:a[c]}function c(a,c){return Array.isArray(a)&&Array.isArray(c)?a.length!==c.length:!1}function f(a){return a?a.declaredClass:null}function n(b,d){var e,g=b.diff;if(g&&"function"===typeof g)return g(b,d);var p=h(b),l=h(d);if(0!==p.length||0!==l.length){if(!p.length||!l.length||c(b,d))return{type:"complete",oldValue:b,
newValue:d};var t=l.filter(function(a){return-1===p.indexOf(a)}),x=p.filter(function(a){return-1===l.indexOf(a)}),t=p.filter(function(c){return-1<l.indexOf(c)&&a(b,c)!==a(d,c)}).concat(t,x).sort();if((x=f(b))&&-1<q.indexOf(x)&&t.length)return{type:"complete",oldValue:b,newValue:d};var w,x=b instanceof m&&d instanceof m,A;for(A in t){var B=t[A],F=a(b,B),C=a(d,B),E=void 0;!(x||"function"!==typeof F&&"function"!==typeof C)||F===C||null==F&&null==C||(E=g&&g[B]&&"function"===typeof g[B]?g[B](F,C):"object"===
typeof F&&"object"===typeof C&&f(F)===f(C)?n(F,C):{type:"complete",oldValue:F,newValue:C},k.isSome(E)&&(k.isSome(w)?w.diff[B]=E:w={type:"partial",diff:(e={},e[B]=E,e)}))}return w}}function g(a){if(k.isNone(a))return!0;switch(a.type){case "complete":return!1;case "collection":for(var c=0,b=a.added;c<b.length;c++){var d=b[c];if(!g(d))return!1}c=0;for(b=a.removed;c<b.length;c++)if(d=b[c],!g(d))return!1;c=0;for(a=a.changed;c<a.length;c++)if(d=a[c],!g(d))return!1;return!0;case "partial":for(c in a.diff)if(d=
a.diff[c],!g(d))return!1;return!0}}Object.defineProperty(e,"__esModule",{value:!0});var q=["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"];e.diff=function(a,c){if("function"!==typeof a&&"function"!==typeof c&&(a||c))return!a||!c||"object"===typeof a&&"object"===typeof c&&f(a)!==f(c)?{type:"complete",oldValue:a,newValue:c}:n(a,c)};e.isEmpty=g})},"esri/renderers/support/UniqueValueInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../symbols ../../core/JSONSupport ../../core/accessorSupport/decorators ../../symbols/support/jsonUtils".split(" "),
function(b,e,m,d,k,l,h,a){Object.defineProperty(e,"__esModule",{value:!0});b=function(c){function b(){var a=null!==c&&c.apply(this,arguments)||this;a.description=null;a.label=null;a.symbol=null;a.value=null;return a}m(b,c);e=b;b.prototype.clone=function(){return new e({value:this.value,description:this.description,label:this.label,symbol:this.symbol?this.symbol.clone():null})};var e;d([h.property({type:String,json:{write:!0}})],b.prototype,"description",void 0);d([h.property({type:String,json:{write:!0}})],
b.prototype,"label",void 0);d([h.property({types:k.symbolTypesRenderer,json:{origins:{"web-scene":{read:a.read,write:{target:{symbol:{types:k.symbolTypesRenderer3D}},writer:a.writeTarget}}},read:a.read,write:a.writeTarget}})],b.prototype,"symbol",void 0);d([h.property({type:String,json:{write:!0}})],b.prototype,"value",void 0);return b=e=d([h.subclass("esri.renderers.support.UniqueValueInfo")],b)}(h.declared(l));e.UniqueValueInfo=b;e.default=b})},"esri/symbols/support/styleUtils":function(){define("require exports ../../request ../../symbols ../../core/devEnvironmentUtils ../../core/Error ../../core/has ../../core/promiseUtils ../../core/urlUtils ../../portal/Portal ../../portal/PortalQueryParams ./jsonUtils ./StyleOrigin ./Thumbnail".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p){function t(a,b){return x(a).then(function(b){return{data:b.data,baseUrl:c.removeFile(a),styleUrl:a}})}function r(a,c){c=c.portal||f.getDefault();var b,d=c.url+" - "+(c.user&&c.user.username)+" - "+a;w[d]||(w[d]=v(a,c).then(function(a){b=a;return a.fetchData()}).then(function(c){return{data:c,baseUrl:b.itemUrl,styleName:a}}));return w[d]}function v(a,c){return c.load().then(function(){var b=new n({disableExtraQuery:!0,query:"owner:"+A+" AND type:"+B+' AND typekeywords:"'+
a+'"'});return c.queryItems(b)}).then(function(c){c=c.results;var b=null,d=a.toLowerCase();if(c&&Array.isArray(c))for(var e=0;e<c.length;e++){var f=c[e];if(f.typeKeywords.some(function(a){return a.toLowerCase()===d})&&f.type===B&&f.owner===A){b=f;break}}if(!b)throw new l("symbolstyleutils:style-not-found","The style '"+a+"' could not be found",{styleName:a});return b.load()})}function u(c,b){return c.styleUrl?t(c.styleUrl,b):c.styleName?r(c.styleName,b):a.reject(new l("symbolstyleutils:style-url-and-name-missing",
"Either styleUrl or styleName is required to resolve a style"))}function z(b,e,f){for(var h=b.data,n={portal:f.portal,url:c.urlToObject(b.baseUrl),origin:"portal-item"},m=function(a){if(a.name!==e)return"continue";var h=c.fromJSON(y(a),n),l=a.thumbnail&&a.thumbnail.href,m=a.thumbnail&&a.thumbnail.imageData;k.isDevEnvironment()&&(h=k.adjustStaticAGOUrl(h),l=k.adjustStaticAGOUrl(l));var r={portal:f.portal,url:c.urlToObject(c.removeFile(h)),origin:"portal-item"};return{value:x(h).then(function(a){if((a=
g.fromJSON(a.data,r))&&d.isSymbol3D(a)){if(l){var h=c.fromJSON(l,n);a.thumbnail=new p.default({url:h})}else m&&(a.thumbnail=new p.default({url:"data:image/png;base64,"+m}));b.styleUrl?a.styleOrigin=new q({portal:f.portal,styleUrl:b.styleUrl,name:e}):b.styleName&&(a.styleOrigin=new q({portal:f.portal,styleName:b.styleName,name:e}))}return a})}},r=0,h=h.items;r<h.length;r++){var t=m(h[r]);if("object"===typeof t)return t.value}return a.reject(new l("symbolstyleutils:symbol-name-not-found","The symbol name '"+
e+"' could not be found",{symbolName:e}))}function y(a){if(a.formatInfos&&!h("enable-feature:jschmid/force-wosr"))for(var c=0,b=a.formatInfos;c<b.length;c++){var d=b[c];if("gltf"===d.type)return d.href}return a.webRef}function x(a){return m(c.normalize(a),{responseType:"json",query:{f:"json"}})}Object.defineProperty(e,"__esModule",{value:!0});var w={};e.fetchStyle=u;e.resolveWebStyleSymbol=function(c,b){return c.name?u(c,b).then(function(a){return z(a,c.name,b)}):a.reject(new l("symbolstyleutils:style-symbol-reference-name-missing",
"Missing name in style symbol reference"))};e.fetchSymbolFromStyle=z;e.styleNameFromItem=function(a){var c=0;for(a=a.typeKeywords;c<a.length;c++){var b=a[c];if(/^Esri.*Style$/.test(b)&&"Esri Style"!==b)return b}};var A="esri_en",B="Style"})},"esri/core/devEnvironmentUtils":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.isDevEnvironment=function(a){a=a||window.location.hostname;return h.some(function(c){return null!=a.match(c)})};e.adjustStaticAGOUrl=
function(a,c){if(!a)return a;c=c||window.location.hostname;return null!=c.match(m)||null!=c.match(k)?a.replace("static.arcgis.com","staticdev.arcgis.com"):null!=c.match(d)||null!=c.match(l)?a.replace("static.arcgis.com","staticqa.arcgis.com"):a};e.isTelemetryDevEnvironment=function(a){a=a||window.location.hostname;return[/^zrh-.+?\.esri\.com$/].concat(h).some(function(c){return null!=a.match(c)})};var m=/^devext.arcgis.com$/,d=/^qaext.arcgis.com$/,k=/^[\w-]*\.mapsdevext.arcgis.com$/,l=/^[\w-]*\.mapsqa.arcgis.com$/,
h=[/^([\w-]*\.)?[\w-]*\.zrh-dev-local.esri.com$/,m,d,/^jsapps.esri.com$/,k,l]})},"esri/renderers/support/jsonUtils":function(){define("require exports ../../core/Error ../../core/object ../../core/Warning ../ClassBreaksRenderer ../DotDensityRenderer ../HeatmapRenderer ../SimpleRenderer ../StretchRenderer ../UniqueValueRenderer".split(" "),function(b,e,m,d,k,l,h,a,c,f,n){function g(a,c,b){if(!a)return null;if(a&&(a.styleName||a.styleUrl)&&"uniqueValue"!==a.type)return b&&b.messages&&b.messages.push(new k("renderer:unsupported",
"Only UniqueValueRenderer can be referenced from a web style, but found '"+a.type+"'",{definition:a,context:b})),null;c=a?p[a.type]||null:null;if(c)return c=new c,c.read(a,b),c;b&&b.messages&&a&&b.messages.push(new k("renderer:unsupported","Renderers of type '"+(a.type||"unknown")+"' are not supported",{definition:a,context:b}));return null}function q(a,c,b){return a?b&&"web-scene"===b.origin&&"heatmap"===a.type?(b.messages&&b.messages.push(new m("renderer:unsupported","Renderer of type '"+a.declaredClass+
"' are not supported in scenes.",{renderer:a,context:b})),null):a.write(c,b):null}Object.defineProperty(e,"__esModule",{value:!0});var p={simple:c,uniqueValue:n,classBreaks:l,heatmap:a,dotDensity:h,rasterStretch:f};e.read=g;e.writeTarget=function(a,c,b,e){(a=q(a,{},e))&&d.setDeepValue(b,a,c)};e.write=q;e.fromJSON=function(a,c){return g(a,null,c)}})},"esri/geometry/HeightModelInfo":function(){define("require exports ../core/tsSupport/assignHelper ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/arrayUtils ../core/JSONSupport ../core/kebabDictionary ../core/unitUtils ../core/Warning ../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){function g(a,c){return new f("height-unit:unsupported","Height unit of value '"+a+"' is not supported",c)}function q(a,c){return new f("height-model:unsupported","Height model of value '"+a+"' is not supported",c)}var p=a.strict()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),t=p.jsonValues.slice();l.removeUnordered(t,"orthometric");var r=a.strict()({meter:"meters",foot:"feet","us-foot":"us-feet","clarke-foot":"clarke-feet",
"clarke-yard":"clarke-yards","clarke-link":"clarke-links","sears-yard":"sears-yards","sears-foot":"sears-feet","sears-chain":"sears-chains","benoit-1895-b-chain":"benoit-1895-b-chains","indian-yard":"indian-yards","indian-1937-yard":"indian-1937-yards","gold-coast-foot":"gold-coast-feet","sears-1922-truncated-chain":"sears-1922-truncated-chains","50-kilometers":"50-kilometers","150-kilometers":"150-kilometers"});return function(a){function b(c){c=a.call(this)||this;c.heightModel="gravity-related-height";
c.heightUnit="meters";c.vertCRS=null;return c}d(b,a);e=b;b.prototype.writeHeightModel=function(a,c,b){return p.write(a,c,b)};b.prototype.readHeightModel=function(a,c,b){if(c=p.read(a))return c;b&&b.messages&&b.messages.push(q(a,{context:b}));return null};b.prototype.readHeightUnit=function(a,c,b){if(c=r.read(a))return c;b&&b.messages&&b.messages.push(g(a,{context:b}));return null};b.prototype.readHeightUnitService=function(a,b,d){if(b=c.unitFromRESTJSON(a)||r.read(a))return b;d&&d.messages&&d.messages.push(g(a,
{context:d}));return null};b.prototype.readVertCRS=function(a,c){return c.vertCRS||c.ellipsoid||c.geoid};b.prototype.clone=function(){return new e({heightModel:this.heightModel,heightUnit:this.heightUnit,vertCRS:this.vertCRS})};b.prototype.equals=function(a){return a?this===a?!0:this.heightModel===a.heightModel&&this.heightUnit===a.heightUnit&&this.vertCRS===a.vertCRS:!1};b.deriveUnitFromSR=function(a,b){b=c.getVerticalUnitStringForSR(b);return new e({heightModel:a.heightModel,heightUnit:b,vertCRS:a.vertCRS})};
b.prototype.write=function(a,c){c=m({origin:"web-scene"},c);return this.inherited(arguments,[a,c])};b.fromJSON=function(a){if(!a)return null;var c=new e;c.read(a,{origin:"web-scene"});return c};var e;k([n.property({type:p.apiValues,constructOnly:!0,json:{type:t}})],b.prototype,"heightModel",void 0);k([n.writer("web-scene","heightModel")],b.prototype,"writeHeightModel",null);k([n.reader(["web-scene","service"],"heightModel")],b.prototype,"readHeightModel",null);k([n.property({type:r.apiValues,constructOnly:!0,
json:{origins:{"web-scene":{type:r.jsonValues,write:r.write}}}})],b.prototype,"heightUnit",void 0);k([n.reader("web-scene","heightUnit")],b.prototype,"readHeightUnit",null);k([n.reader("service","heightUnit")],b.prototype,"readHeightUnitService",null);k([n.property({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],b.prototype,"vertCRS",void 0);k([n.reader("service","vertCRS",["vertCRS","ellipsoid","geoid"])],b.prototype,"readVertCRS",null);return b=e=k([n.subclass("esri.geometry.HeightModelInfo")],
b)}(n.declared(h))})},"esri/layers/graphics/editingSupport":function(){define("require exports ../../core/tsSupport/generatorHelper ../../core/tsSupport/awaiterHelper ../../core/tsSupport/assignHelper ../../Graphic ../../core/Error ../../core/lang ../../core/promiseUtils ../../geometry/support/normalizeUtils".split(" "),function(b,e,m,d,k,l,h,a,c,f){function n(a,b){return d(this,void 0,void 0,function(){return m(this,function(d){if(!b||!(b.addFeatures||b.deleteFeatures||b.updateFeatures||b.addFeatures.length||
b.deleteFeatures.length||b.updateFeatures.length))return[2,c.reject(new h(a.type+"-layer:missing-parameters","'addFeatures', 'updateFeatures' or 'deleteFeatures' parameter is required"))];b=k({},b);b.addFeatures=b.addFeatures||[];b.updateFeatures=b.updateFeatures||[];b.deleteFeatures=b.deleteFeatures||[];b.addFeatures=b.addFeatures.map(q);b.updateFeatures=b.updateFeatures.map(q);return[2,g(b)]})})}function g(a){return d(this,void 0,void 0,function(){var c,b,d,e,g,h;return m(this,function(p){switch(p.label){case 0:return c=
a.addFeatures,b=a.updateFeatures,d=c.concat(b).map(function(a){return a.geometry}),[4,f.normalizeCentralMeridian(d)];case 1:return e=p.sent(),g=c.length,h=b.length,e.slice(0,g).forEach(function(c,b){a.addFeatures[b].geometry=c}),e.slice(g,g+h).forEach(function(c,b){a.updateFeatures[b].geometry=c}),[2,a]}})})}function q(a){var c=new l;a.attributes||(a.attributes={});c.geometry=a.geometry;c.attributes=a.attributes;return c}Object.defineProperty(e,"__esModule",{value:!0});e.isEditableLayer=function(a){return!0===
a.get("capabilities.operations.supportsEditing")};e.applyEdits=function(b,e){return d(this,void 0,void 0,function(){var d,f,g,p,k,l,t,q,B;return m(this,function(m){switch(m.label){case 0:return g={edits:e,result:c.create(function(a,c){d=a;f=c})},b.emit("apply-edits",g),[4,b.load()];case 1:return m.sent(),(p=b.source)&&null!=p.applyEdits?b.editingEnabled?[4,n(b,e)]:[2,c.reject(new h(b.type+"-layer:editing-disabled","Editing is disabled for layer",{layer:b}))]:[2,c.reject(new h(b.type+"-layer:no-editing-support",
"Layer source does not support applyEdits capability",{layer:b}))];case 2:k=m.sent(),m.label=3;case 3:return m.trys.push([3,5,,6]),[4,p.applyEdits(k)];case 4:return l=m.sent(),t=function(c){return c.filter(function(a){return!a.error}).map(a.clone)},q={addedFeatures:t(l.addFeatureResults),updatedFeatures:t(l.updateFeatureResults),deletedFeatures:t(l.deleteFeatureResults)},(q.addedFeatures.length||q.updatedFeatures.length||q.deletedFeatures.length)&&b.emit("edits",q),d(q),[2,l];case 5:throw B=m.sent(),
f(B),B;case 6:return[2]}})})}})},"esri/geometry/support/normalizeUtils":function(){define("require exports ../../config ../../core/Error ../../core/Logger ../../core/promiseUtils ../Polygon ../Polyline ../SpatialReference ./spatialReferenceUtils ./webMercatorUtils ../../tasks/GeometryService".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){function q(a){return"polygon"===a.type?a.rings:a.paths}function p(a,c){return Math.ceil((a-c)/(2*c))}function t(a,c){for(var b=0,d=q(a);b<d.length;b++)for(var e=0,
f=d[b];e<f.length;e++)f[e][0]+=c;return a}function r(a){for(var c=[],b=0,d=0,e=0;e<a.length;e++){for(var f=a[e],g=null,h=0;h<f.length;h++)g=f[h],c.push(g),0===h?d=b=g[0]:(b=Math.min(b,g[0]),d=Math.max(d,g[0]));g&&c.push([(b+d)/2,0])}return c}function v(c,b){if(!(c instanceof a||c instanceof h))throw w.error("straightLineDensify: the input geometry is neither polyline nor polygon"),new d("straightLineDensify: the input geometry is neither polyline nor polygon");for(var e=[],f=0,g=q(c);f<g.length;f++){var p=
g[f],k=[];e.push(k);k.push([p[0][0],p[0][1]]);for(var n=0;n<p.length-1;n++){var l=p[n][0],m=p[n][1],r=p[n+1][0],t=p[n+1][1],u=Math.sqrt((r-l)*(r-l)+(t-m)*(t-m)),v=(t-m)/u,y=(r-l)/u,z=u/b;if(1<z){for(var B=1;B<=z-1;B++){var x=B*b;k.push([y*x+l,v*x+m])}u=(u+Math.floor(z-1)*b)/2;k.push([y*u+l,v*u+m])}k.push([r,t])}}return"polygon"===c.type?new h({rings:e,spatialReference:c.spatialReference}):new a({paths:e,spatialReference:c.spatialReference})}function u(a,c,b){c&&(a=v(a,1E6),a=n.webMercatorToGeographic(a,
!0));b&&(a=t(a,b));return a}function z(a,c,b){if(Array.isArray(a)){var d=a[0];if(d>c){var e=p(d,c);a[0]=d+-2*e*c}else d<b&&(e=p(d,b),a[0]=d+-2*e*b)}else d=a.x,d>c?(e=p(d,c),a=a.clone().offset(-2*e*c,0)):d<b&&(e=p(d,b),a=a.clone().offset(-2*e*b,0));return a}function y(a,c){for(var b=-1,d=function(d){var e=c.cutIndexes[d],f=c.geometries[d],g=q(f);d=function(a){var c=g[a];c.some(function(b){if(180>b[0])return!0;for(var d=b=0;d<c.length;d++){var e=c[d][0];b=e>b?e:b}b=Number(b.toFixed(9));b=-360*p(b,180);
for(d=0;d<c.length;d++)e=f.getPoint(a,d),f.setPoint(a,d,e.clone().offset(b,0));return!0})};for(var h=0;h<g.length;h++)d(h);if(e===b)if("polygon"===a[0].type)for(d=0,h=q(f);d<h.length;d++)a[e]=a[e].addRing(h[d]);else{if("polyline"===a[0].type)for(d=0,h=q(f);d<h.length;d++)a[e]=a[e].addPath(h[d])}else b=e,a[e]=f},e=0;e<c.cutIndexes.length;e++)d(e);return a}function x(c,b,d){if(!Array.isArray(c))return x([c],b);b||(B||(B=new g({url:m.geometryServiceUrl})),b=B);for(var e,k,r,q,v,w,F,C=0,E=[],J=[],fa=
0;fa<c.length;fa++){var H=c[fa];if(H)if(e||(e=H.spatialReference,k=f.getInfo(e),w=(r=e.isWebMercator)?102100:4326,q=A[w].maxX,v=A[w].minX,F=A[w].plus180Line,w=A[w].minus180Line),k)if("mesh"===H.type)J.push(H);else if("point"===H.type)J.push(z(H.clone(),q,v));else if("multipoint"===H.type)H=H.clone(),H.points=H.points.map(function(a){return z(a,q,v)}),J.push(H);else if("extent"===H.type){var da=H.clone(),H=da._normalize(!1,!1,k);J.push(H.rings?new h(H):H)}else if(H.extent){var da=H.extent,aa=2*p(da.xmin,
v)*q,H=0===aa?H.clone():t(H.clone(),aa);da.offset(aa,0);da.intersects(F)&&da.xmax!==q?(C=da.xmax>C?da.xmax:C,H=u(H,r),E.push(H),J.push("cut")):da.intersects(w)&&da.xmin!==v?(C=2*da.xmax*q>C?2*da.xmax*q:C,H=u(H,r,360),E.push(H),J.push("cut")):J.push(H)}else J.push(H.clone());else J.push(H);else J.push(H)}e=p(C,q);k=-90;F=e;for(C=new a;0<e;)fa=-180+360*e,C.addPath([[fa,k],[fa,-1*k]]),k*=-1,e--;if(0<E.length&&0<F)return b.cut(E,C,d).then(function(a){return y(E,a)}).then(function(a){for(var e=[],f=[],
g=0;g<J.length;g++){var h=J[g];if("cut"!==h)f.push(h);else{var h=a.shift(),p=c[g];"polygon"===p.type&&p.rings&&1<p.rings.length&&h.rings.length>=p.rings.length?(e.push(h),f.push("simplify")):f.push(r?n.geographicToWebMercator(h):h)}}return e.length?b.simplify(e,d).then(function(a){for(var c=[],b=0;b<f.length;b++){var d=f[b];"simplify"!==d?c.push(d):c.push(r?n.geographicToWebMercator(a.shift()):a.shift())}return c}):f});e=[];for(k=0;k<J.length;k++)F=J[k],"cut"!==F?e.push(F):(F=E.shift(),e.push(!0===
r?n.geographicToWebMercator(F):F));return l.resolve(e)}Object.defineProperty(e,"__esModule",{value:!0});var w=k.getLogger("esri.geometry.support.normalizeUtils"),A={102100:{maxX:2.0037508342788905E7,minX:-2.0037508342788905E7,plus180Line:new a({paths:[[[2.0037508342788905E7,-2.0037508342788905E7],[2.0037508342788905E7,2.0037508342788905E7]]],spatialReference:c.WebMercator}),minus180Line:new a({paths:[[[-2.0037508342788905E7,-2.0037508342788905E7],[-2.0037508342788905E7,2.0037508342788905E7]]],spatialReference:c.WebMercator})},
4326:{maxX:180,minX:-180,plus180Line:new a({paths:[[[180,-180],[180,180]]],spatialReference:c.WebMercator}),minus180Line:new a({paths:[[[-180,-180],[-180,180]]],spatialReference:c.WebMercator})}};e.straightLineDensify=v;var B;e.normalizeCentralMeridian=x;e.getDenormalizedExtent=function(a){var c;if(!a)return null;var b=a.extent;if(!b)return null;var d=a.spatialReference&&f.getInfo(a.spatialReference);if(!d)return b;var d=d.valid,e=d[0],d=d[1],g=b.width,h=b.xmin;c=b.xmax;c=[c,h];h=c[0];c=c[1];if("extent"===
a.type||0===g||g<=d||g>2*d||h<e||c>d)return b;var p;switch(a.type){case "polygon":if(1<a.rings.length)p=r(a.rings);else return b;break;case "polyline":if(1<a.paths.length)p=r(a.paths);else return b;break;case "multipoint":p=a.points}a=b.clone();for(e=0;e<p.length;e++){var k=p[e][0];0>k?(k+=d,c=Math.max(k,c)):(k-=d,h=Math.min(k,h))}a.xmin=h;a.xmax=c;return a.width<g?(a.xmin-=d,a.xmax-=d,a):b};e.normalizeMapX=function(a,c){if(c=f.getInfo(c)){var b=c.valid;c=b[0];var b=b[1],d=b-c;if(a<c)for(;a<c;)a+=
d;if(a>b)for(;a>b;)a-=d}return a}})},"esri/tasks/GeometryService":function(){define("../core/lang ../core/kebabDictionary ../core/accessorSupport/ensureType ../geometry/Extent ../geometry/Multipoint ../geometry/Polyline ../geometry/Polygon ../geometry/support/jsonUtils ../request ./Task ./support/ProjectParameters".split(" "),function(b,e,m,d,k,l,h,a,c,f,n){var g=new e.KebabDictionary({MGRS:"mgrs",USNG:"usng",UTM:"utm",GeoRef:"geo-ref",GARS:"gars",DMS:"dms",DDM:"ddm",DD:"dd"}),q=m.ensureType(n);e=
f.createSubclass({declaredClass:"esri.tasks.GeometryService",areasAndLengths:function(a,d){a={query:b.mixin({},this.parsedUrl.query,{f:"json"},a.toJSON())};if(this.requestOptions||d)a=b.mixin({},this.requestOptions,d,a);return c(this.parsedUrl.path+"/areasAndLengths",a).then(function(a){return a.data})},autoComplete:function(a,d,e){var f=a[0].spatialReference;a={query:b.mixin({},this.parsedUrl.query,{f:"json",sr:JSON.stringify(f.toJSON()),polygons:JSON.stringify(this._encodeGeometries(a).geometries),
polylines:JSON.stringify(this._encodeGeometries(d).geometries)})};if(this.requestOptions||e)a=b.mixin({},this.requestOptions,e,a);return c(this.parsedUrl.path+"/autoComplete",a).then(function(a){return(a.data.geometries||[]).map(function(a){return new h({spatialReference:f,rings:a.rings})})})},buffer:function(a,d){var e=b.mixin({},this.parsedUrl.query,{f:"json"},a.toJSON()),f=a.outSpatialReference||a.geometries[0].spatialReference;a={query:e};if(this.requestOptions||d)a=b.mixin({},this.requestOptions,
d,a);return c(this.parsedUrl.path+"/buffer",a).then(function(a){return(a.data.geometries||[]).map(function(a){return new h({spatialReference:f,rings:a.rings})})})},cut:function(d,e,f){var g=d[0].spatialReference,h=d.map(function(a){return a.toJSON()});d={query:b.mixin({},this.parsedUrl.query,{f:"json",sr:JSON.stringify(g.toJSON()),target:JSON.stringify({geometryType:a.getJsonType(d[0]),geometries:h}),cutter:JSON.stringify(e.toJSON())})};if(this.requestOptions||f)d=b.mixin({},this.requestOptions,f,
d);return c(this.parsedUrl.path+"/cut",d).then(function(c){c=c.data;return{cutIndexes:c.cutIndexes,geometries:(c.geometries||[]).map(function(c){return a.fromJSON(c).set("spatialReference",g)})}})},convexHull:function(d,e){var f=d[0].spatialReference;d={query:b.mixin({},this.parsedUrl.query,{f:"json",sr:JSON.stringify(f.toJSON()),geometries:JSON.stringify(this._encodeGeometries(d))})};if(this.requestOptions||e)d=b.mixin({},this.requestOptions,e,d);return c(this.parsedUrl.path+"/convexHull",d).then(function(c){return a.fromJSON(c.data.geometry).set("spatialReference",
f)})},densify:function(d,e){var f=b.mixin({},this.parsedUrl.query,{f:"json"},d.toJSON()),g=d.geometries[0].spatialReference;d={query:f};if(this.requestOptions||e)d=b.mixin({},this.requestOptions,e,d);return c(this.parsedUrl.path+"/densify",d).then(function(c){return(c.data.geometries||[]).map(function(c){return a.fromJSON(c).set("spatialReference",g)})})},difference:function(d,e,f){var g=d[0].spatialReference;d={query:b.mixin({},this.parsedUrl.query,{f:"json",sr:JSON.stringify(g.toJSON()),geometries:JSON.stringify(this._encodeGeometries(d)),
geometry:JSON.stringify({geometryType:a.getJsonType(e),geometry:e.toJSON()})})};if(this.requestOptions||f)d=b.mixin({},this.requestOptions,f,d);return c(this.parsedUrl.path+"/difference",d).then(function(c){return(c.data.geometries||[]).map(function(c){return a.fromJSON(c).set("spatialReference",g)})})},distance:function(a,d){a={query:b.mixin({},this.parsedUrl.query,{f:"json"},a.toJSON())};if(this.requestOptions||d)a=b.mixin({},this.requestOptions,d,a);return c(this.parsedUrl.path+"/distance",a).then(this._handleDistanceResponse)},
fromGeoCoordinateString:function(a,d){var e={};e.sr=null!=a.sr&&"object"===typeof a.sr?a.sr.wkid||JSON.stringify(a.sr):a.sr;e.strings=JSON.stringify(a.strings);e.conversionType=g.toJSON(a.conversionType||"mgrs");e.conversionMode=a.conversionMode;a={query:b.mixin({},this.parsedUrl.query,{f:"json"},e)};if(this.requestOptions||d)a=b.mixin({},this.requestOptions,d,a);return c(this.parsedUrl.path+"/fromGeoCoordinateString",a).then(this._handleFromGeoCoordinateResponse)},generalize:function(d,e){var f=
b.mixin({},this.parsedUrl.query,{f:"json"},d.toJSON()),g=d.geometries[0].spatialReference;d={query:f};if(this.requestOptions||e)d=b.mixin({},this.requestOptions,e,d);return c(this.parsedUrl.path+"/generalize",d).then(function(c){return(c.data.geometries||[]).map(function(c){return a.fromJSON(c).set("spatialReference",g)})})},intersect:function(d,e,f){var g=d[0].spatialReference;d={query:b.mixin({},this.parsedUrl.query,{f:"json",sr:JSON.stringify(g.toJSON()),geometries:JSON.stringify(this._encodeGeometries(d)),
geometry:JSON.stringify({geometryType:a.getJsonType(e),geometry:e.toJSON()})})};if(this.requestOptions||f)d=b.mixin({},this.requestOptions,f,d);return c(this.parsedUrl.path+"/intersect",d).then(function(c){return(c.data.geometries||[]).map(function(c){return a.fromJSON(c).set("spatialReference",g)})})},lengths:function(a,d){a={query:b.mixin({},this.parsedUrl.query,{f:"json"},a.toJSON())};if(this.requestOptions||d)a=b.mixin({},this.requestOptions,d,a);return c(this.parsedUrl.path+"/lengths",a).then(function(a){return a.data})},
labelPoints:function(d,e){var f=d.map(function(a){return a.toJSON()}),g=d[0].spatialReference;d={query:b.mixin({},this.parsedUrl.query,{f:"json",sr:g.wkid?g.wkid:JSON.stringify(g.toJSON()),polygons:JSON.stringify(f)})};if(this.requestOptions||e)d=b.mixin({},this.requestOptions,e,d);return c(this.parsedUrl.path+"/labelPoints",d).then(function(c){return(c.data.labelPoints||[]).map(function(c){return a.fromJSON(c).set("spatialReference",g)})})},offset:function(d,e){var f=b.mixin({},this.parsedUrl.query,
{f:"json"},d.toJSON()),g=d.geometries[0].spatialReference;d={query:f};if(this.requestOptions||e)d=b.mixin({},this.requestOptions,e,d);return c(this.parsedUrl.path+"/offset",d).then(function(c){return(c.data.geometries||[]).map(function(c){return a.fromJSON(c).set("spatialReference",g)})})},project:function(d,e){d=q(d);var f=b.mixin({},d.toJSON(),this.parsedUrl.query,{f:"json"}),g=d.outSpatialReference,h=a.getJsonType(d.geometries[0]),p=this._decodeGeometries;d={query:f};if(this.requestOptions||e)d=
b.mixin({},this.requestOptions,e,d);return c(this.parsedUrl.path+"/project",d).then(function(a){return p(a.data,h,g)})},relation:function(a,d){a={query:b.mixin({},this.parsedUrl.query,{f:"json"},a.toJSON())};if(this.requestOptions||d)a=b.mixin({},this.requestOptions,d,a);return c(this.parsedUrl.path+"/relation",a).then(this._handleRelationResponse)},reshape:function(d,e,f){var g=d.spatialReference;d={query:b.mixin({},this.parsedUrl.query,{f:"json",sr:JSON.stringify(g.toJSON()),target:JSON.stringify({geometryType:a.getJsonType(d),
geometry:d.toJSON()}),reshaper:JSON.stringify(e.toJSON())})};if(this.requestOptions||f)d=b.mixin({},this.requestOptions,f,d);return c(this.parsedUrl.path+"/reshape",d).then(function(c){return a.fromJSON(c.data.geometry).set("spatialReference",g)})},simplify:function(d,e){var f=d[0].spatialReference,g=b.mixin({},this.parsedUrl.query,{f:"json",sr:f.wkid?f.wkid:JSON.stringify(f.toJSON()),geometries:JSON.stringify(this._encodeGeometries(d))}),h=a.getJsonType(d[0]),p=this._decodeGeometries;d={query:g};
if(this.requestOptions||e)d=b.mixin({},this.requestOptions,e,d);return c(this.parsedUrl.path+"/simplify",d).then(function(a){return p(a.data,h,f)})},toGeoCoordinateString:function(a,d){var e={};e.sr=null!=a.sr&&"object"===typeof a.sr?a.sr.wkid||JSON.stringify(a.sr):a.sr;e.coordinates=JSON.stringify(a.coordinates);e.conversionType=g.toJSON(a.conversionType||"mgrs");e.conversionMode=a.conversionMode;e.numOfDigits=a.numOfDigits;e.rounding=a.rounding;e.addSpaces=a.addSpaces;a={query:b.mixin({},this.parsedUrl.query,
{f:"json"},e)};if(this.requestOptions||d)a=b.mixin({},this.requestOptions,d,a);return c(this.parsedUrl.path+"/toGeoCoordinateString",a).then(this._handleToGeoCoordinateResponse)},trimExtend:function(a,d){var e=b.mixin({},this.parsedUrl.query,{f:"json"},a.toJSON()),f=a.sr;a={query:e};if(this.requestOptions||d)a=b.mixin({},this.requestOptions,d,a);return c(this.parsedUrl.path+"/trimExtend",a).then(function(a){return(a.data.geometries||[]).map(function(a){return new l({spatialReference:f,paths:a.paths})})})},
union:function(d,e){var f=d[0].spatialReference;d={query:b.mixin({},this.parsedUrl.query,{f:"json",sr:JSON.stringify(f.toJSON()),geometries:JSON.stringify(this._encodeGeometries(d))})};if(this.requestOptions||e)d=b.mixin({},this.requestOptions,e,d);return c(this.parsedUrl.path+"/union",d).then(function(c){return a.fromJSON(c.data.geometry).set("spatialReference",f)})},_handleRelationResponse:function(a){return a.data.relations},_handleDistanceResponse:function(a){return(a=a.data)&&a.distance},_handleToGeoCoordinateResponse:function(a){return a.data.strings},
_handleFromGeoCoordinateResponse:function(a){return a.data.coordinates},_encodeGeometries:function(c){var b=[],d,e=c.length;for(d=0;d<e;d++)b.push(c[d].toJSON());return{geometryType:a.getJsonType(c[0]),geometries:b}},_decodeGeometries:function(c,d,e){var f=a.getGeometryType(d);c=c.geometries;var g=[],h={spatialReference:e.toJSON()},p=b.mixin;c.forEach(function(a,c){g[c]=new f(p(a,h))});return g},_toProjectGeometry:function(a){var c=a.spatialReference.toJSON();return a instanceof d?new h({rings:[[[a.xmin,
a.ymin],[a.xmin,a.ymax],[a.xmax,a.ymax],[a.xmax,a.ymin],[a.xmin,a.ymin]]],spatialReference:c}):new l({paths:[[].concat(a.points)],spatialReference:c})},_fromProjectedGeometry:function(a,c,b){return"extent"===c?(a=a.rings[0],new d(a[0][0],a[0][1],a[2][0],a[2][1],b)):new k({points:a.paths[0],spatialReference:b.toJSON()})}});b.mixin(e,{UNIT_METER:9001,UNIT_GERMAN_METER:9031,UNIT_FOOT:9002,UNIT_SURVEY_FOOT:9003,UNIT_CLARKE_FOOT:9005,UNIT_FATHOM:9014,UNIT_NAUTICAL_MILE:9030,UNIT_SURVEY_CHAIN:9033,UNIT_SURVEY_LINK:9034,
UNIT_SURVEY_MILE:9035,UNIT_KILOMETER:9036,UNIT_CLARKE_YARD:9037,UNIT_CLARKE_CHAIN:9038,UNIT_CLARKE_LINK:9039,UNIT_SEARS_YARD:9040,UNIT_SEARS_FOOT:9041,UNIT_SEARS_CHAIN:9042,UNIT_SEARS_LINK:9043,UNIT_BENOIT_1895A_YARD:9050,UNIT_BENOIT_1895A_FOOT:9051,UNIT_BENOIT_1895A_CHAIN:9052,UNIT_BENOIT_1895A_LINK:9053,UNIT_BENOIT_1895B_YARD:9060,UNIT_BENOIT_1895B_FOOT:9061,UNIT_BENOIT_1895B_CHAIN:9062,UNIT_BENOIT_1895B_LINK:9063,UNIT_INDIAN_FOOT:9080,UNIT_INDIAN_1937_FOOT:9081,UNIT_INDIAN_1962_FOOT:9082,UNIT_INDIAN_1975_FOOT:9083,
UNIT_INDIAN_YARD:9084,UNIT_INDIAN_1937_YARD:9085,UNIT_INDIAN_1962_YARD:9086,UNIT_INDIAN_1975_YARD:9087,UNIT_FOOT_1865:9070,UNIT_RADIAN:9101,UNIT_DEGREE:9102,UNIT_ARCMINUTE:9103,UNIT_ARCSECOND:9104,UNIT_GRAD:9105,UNIT_GON:9106,UNIT_MICRORADIAN:9109,UNIT_ARCMINUTE_CENTESIMAL:9112,UNIT_ARCSECOND_CENTESIMAL:9113,UNIT_MIL6400:9114,UNIT_BRITISH_1936_FOOT:9095,UNIT_GOLDCOAST_FOOT:9094,UNIT_INTERNATIONAL_CHAIN:109003,UNIT_INTERNATIONAL_LINK:109004,UNIT_INTERNATIONAL_YARD:109001,UNIT_STATUTE_MILE:9093,UNIT_SURVEY_YARD:109002,
UNIT_50KILOMETER_LENGTH:109030,UNIT_150KILOMETER_LENGTH:109031,UNIT_DECIMETER:109005,UNIT_CENTIMETER:109006,UNIT_MILLIMETER:109007,UNIT_INTERNATIONAL_INCH:109008,UNIT_US_SURVEY_INCH:109009,UNIT_INTERNATIONAL_ROD:109010,UNIT_US_SURVEY_ROD:109011,UNIT_US_NAUTICAL_MILE:109012,UNIT_UK_NAUTICAL_MILE:109013,UNIT_SQUARE_INCHES:"esriSquareInches",UNIT_SQUARE_FEET:"esriSquareFeet",UNIT_SQUARE_YARDS:"esriSquareYards",UNIT_ACRES:"esriAcres",UNIT_SQUARE_MILES:"esriSquareMiles",UNIT_SQUARE_MILLIMETERS:"esriSquareMillimeters",
UNIT_SQUARE_CENTIMETERS:"esriSquareCentimeters",UNIT_SQUARE_DECIMETERS:"esriSquareDecimeters",UNIT_SQUARE_METERS:"esriSquareMeters",UNIT_ARES:"esriAres",UNIT_HECTARES:"esriHectares",UNIT_SQUARE_KILOMETERS:"esriSquareKilometers"});return e})},"esri/tasks/Task":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/paramHelper ../core/tsSupport/assignHelper ../core/Accessor ../core/urlUtils ../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a,c){return function(b){function e(a){a=b.call(this)||this;a.requestOptions=null;a.url=null;return a}m(e,b);e.prototype.normalizeCtorArgs=function(a,c){return"string"!==typeof a?a:l({url:a},c)};Object.defineProperty(e.prototype,"parsedUrl",{get:function(){return this._parseUrl(this.url)},enumerable:!0,configurable:!0});e.prototype._parseUrl=function(c){return c?a.urlToObject(c):null};e.prototype._encode=function(a,c,b){var d={},e;for(e in a)if("declaredClass"!==e){var f=a[e];
if(null!=f&&"function"!==typeof f)if(Array.isArray(f)){d[e]=[];for(var g=0;g<f.length;g++)d[e][g]=this._encode(f[g])}else"object"===typeof f?f.toJSON&&(f=f.toJSON(b&&b[e]),d[e]=c?f:JSON.stringify(f)):d[e]=f}return d};d([c.property({readOnly:!0,dependsOn:["url"]})],e.prototype,"parsedUrl",null);d([c.property()],e.prototype,"requestOptions",void 0);d([c.property({type:String})],e.prototype,"url",void 0);return e=d([c.subclass("esri.tasks.Task")],e)}(c.declared(h))})},"esri/tasks/support/ProjectParameters":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/Logger ../../core/accessorSupport/decorators ../../geometry/support/jsonUtils".split(" "),
function(b,e,m,d,k,l,h,a){var c=l.getLogger("esri.tasks.support.ProjectParameters");return function(b){function e(a){a=b.call(this)||this;a.geometries=null;a.outSpatialReference=null;a.transformation=null;a.transformForward=null;return a}m(e,b);Object.defineProperty(e.prototype,"outSR",{get:function(){c.warn("ProjectParameters.outSR is deprecated. Use outSpatialReference instead.");return this.outSpatialReference},set:function(a){c.warn("ProjectParameters.outSR is deprecated. Use outSpatialReference instead.");
this.outSpatialReference=a},enumerable:!0,configurable:!0});e.prototype.toJSON=function(){var c=this.geometries.map(function(a){return a.toJSON()}),b=this.geometries[0],d={};d.outSR=this.outSpatialReference.wkid||JSON.stringify(this.outSpatialReference.toJSON());d.inSR=b.spatialReference.wkid||JSON.stringify(b.spatialReference.toJSON());d.geometries=JSON.stringify({geometryType:a.getJsonType(b),geometries:c});this.transformation&&(d.transformation=this.transformation.wkid||JSON.stringify(this.transformation));
null!=this.transformForward&&(d.transformForward=this.transformForward);return d};d([h.property()],e.prototype,"geometries",void 0);d([h.property({json:{read:{source:"outSR"}}})],e.prototype,"outSpatialReference",void 0);d([h.property({json:{read:!1}})],e.prototype,"outSR",null);d([h.property()],e.prototype,"transformation",void 0);d([h.property()],e.prototype,"transformForward",void 0);return e=d([h.subclass("esri.tasks.support.ProjectParameters")],e)}(h.declared(k))})},"esri/layers/graphics/sources/MemorySource":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../geometry ../../../Graphic ../../../core/Accessor ../../../core/Collection ../../../core/Error ../../../core/has ../../../core/Loadable ../../../core/Logger ../../../core/promiseUtils ../../../core/requireUtils ../../../core/workers ../../../core/accessorSupport/decorators ../../../core/accessorSupport/ensureType ../../../core/accessorSupport/typescript ../../../tasks/support/FeatureSet module".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y){Object.defineProperty(e,"__esModule",{value:!0});var x=0,w=g.getLogger("esri.layers.graphics.sources.MemorySource");h=function(a){function e(){var c=null!==a&&a.apply(this,arguments)||this;c._idToClientGraphic=null;c.type="memory";return c}m(e,a);e.prototype.load=function(){var a=this,c;c=q.resolve();this.addResolvingPromise(c.then(function(){return t.open(p.getAbsMid("./support/MemorySourceWorker",b,y),{strategy:f("esri-workers-for-memory-layers")?
"dedicated":"local"}).then(function(c){a._connection=c;var b=a.layer,d=b.fields,e=b.spatialReference,f=b.objectIdField,g=b.hasM,h=b.hasZ,b=b.timeInfo,p="defaults"===a.layer.originOf("spatialReference"),n=a._prepareAddFeatures(a.items);a.on("before-changes",function(a){w.error("Source modifications will not propagate after layer has been loaded. Please use .applyEdits() instead");a.preventDefault()});d={features:n.features,fields:d&&d.map(function(a){return a.toJSON()}),geometryType:k.typeKebabDictionary.toJSON(a.workerGeometryType),
hasM:g,hasZ:h,objectIdField:f,spatialReference:p?null:e&&e.toJSON(),timeInfo:b?b.toJSON():null};return c.invoke("load",d).then(function(c){for(var b=0,d=c.warnings;b<d.length;b++)w.warn(d[b].message,{layer:a.layer});c.featureErrors.length&&w.warn("Encountered "+c.featureErrors.length+" validation errors while loading features",c.featureErrors);b=c.layerDefinition;a._geometryTypeRequiresClientGraphicMapping(n.inferredGeometryType)&&(b.geometryType=k.typeKebabDictionary.toJSON(n.inferredGeometryType));
a.layerDefinition=b;a._requiresClientGraphicMapping()&&(a._idToClientGraphic=new Map);n.finish(c.assignedObjectIds)})})}));return this.when()};Object.defineProperty(e.prototype,"workerGeometryType",{get:function(){var a=this.layer&&this.layer.geometryType;return a?this._geometryTypeRequiresClientGraphicMapping(a)?"polygon":a:null},enumerable:!0,configurable:!0});e.prototype.applyEdits=function(a){var c=this;return this.load().then(function(){return c._applyEdits(a)})};e.prototype.openPorts=function(){var a=
this;return this.load().then(function(){return a._connection.openPorts()})};e.prototype.queryFeatures=function(a){var c=this;return this.load().then(function(){return c._connection.invoke("queryFeatures",a?a.toJSON():null)}).then(function(a){a=z.fromJSON(a);if(!c._requiresClientGraphicMapping())return a;for(var b=c.layer.objectIdField,d=0,e=a.features;d<e.length;d++){var f=e[d],g=c._idToClientGraphic.get(f.attributes[b]);g&&(f.geometry=g.geometry)}a.geometryType=c.layer.geometryType;return a})};e.prototype.queryFeaturesJSON=
function(a){var b=this;return this._requiresClientGraphicMapping()?q.reject(new c("query-features-json:unsupported","Cannot query in JSON format for client only geometry types (mesh and extent)")):this.load().then(function(){return b._connection.invoke("queryFeatures",a?a.toJSON():null)})};e.prototype.queryFeatureCount=function(a){var c=this;return this.load().then(function(){return c._connection.invoke("queryFeatureCount",a?a.toJSON():null)})};e.prototype.queryObjectIds=function(a){var c=this;return this.load().then(function(){return c._connection.invoke("queryObjectIds",
a?a.toJSON():null)})};e.prototype.queryExtent=function(a){var c=this;return this.load().then(function(){return c._connection.invoke("queryExtent",a?a.toJSON():null)}).then(function(a){return{count:a.count,extent:k.Extent.fromJSON(a.extent)}})};e.prototype._applyEdits=function(a){var b=this;if(!this._connection)throw new c("feature-layer-source:edit-failure","Memory source not loaded");var d=this.layer.objectIdField,e=null,f=[],g=[];a.addFeatures&&(e=this._prepareAddFeatures(a.addFeatures));if(a.deleteFeatures)for(var h=
0,p=a.deleteFeatures;h<p.length;h++){var k=p[h];"objectId"in k&&null!=k.objectId?f.push(k.objectId):"attributes"in k&&null!=k.attributes[d]&&f.push(k.attributes[d])}if(a.updateFeatures)for(d=0,a=a.updateFeatures;d<a.length;d++)k=a[d],g.push(this._serializeFeature(k));return this._connection.invoke("applyEdits",{adds:e?e.features:[],updates:g,deletes:f}).then(function(a){var c=a.featureEditResults;b.fullExtent=a.fullExtent;e&&e.finish(c.uidToObjectId);if(b._idToClientGraphic){a=0;for(var d=c.deleteResults;a<
d.length;a++){var f=d[a];f.success&&b._idToClientGraphic.delete(f.objectId)}}return b._createEditsResult(c)})};e.prototype._createEditsResult=function(a){return{addFeatureResults:a.addResults?a.addResults.map(this._createFeatureEditResult,this):[],updateFeatureResults:a.updateResults?a.updateResults.map(this._createFeatureEditResult,this):[],deleteFeatureResults:a.deleteResults?a.deleteResults.map(this._createFeatureEditResult,this):[]}};e.prototype._createFeatureEditResult=function(a){var b=!0===
a.success?null:a.error||{code:void 0,description:void 0};return{objectId:a.objectId,globalId:a.globalId,error:b?new c("feature-layer-source:edit-failure",b.description,{code:b.code}):null}};e.prototype._prepareAddFeatures=function(a){for(var c=new Map,b=Array(a.length),d=null,e=0;e<a.length;e++){var f=a[e],g=this._serializeFeature(f);!d&&f.geometry&&(d=f.geometry.type);b[e]=g;c.set(""+g.uid,f)}var h=this;return{features:b,inferredGeometryType:d,finish:function(a){var b=h.layerDefinition.objectIdField,
d;for(d in a){var e=a[d],f=c.get(d);f&&(f.attributes||(f.attributes={}),-1===e?delete f.attributes[b]:f.attributes[b]=e,h._addIdToClientGraphic(f))}}}};e.prototype._addIdToClientGraphic=function(a){if(this._idToClientGraphic){var c=this.layerDefinition.objectIdField,c=a.attributes&&a.attributes[c];null!=c&&this._idToClientGraphic.set(c,a)}};e.prototype._requiresClientGraphicMapping=function(){return this._geometryTypeRequiresClientGraphicMapping(this.layer.geometryType||this.layerDefinition.geometryType)};
e.prototype._geometryRequiresClientGraphicMapping=function(a){return this._geometryTypeRequiresClientGraphicMapping(a.type)};e.prototype._geometryTypeRequiresClientGraphicMapping=function(a){return"mesh"===a||"multipatch"===a||"extent"===a};e.prototype._serializeFeature=function(a){var c=a.attributes;a=this._geometryForSerialization(a);var b=(x++).toString();return a?{uid:b,geometry:a.toJSON(),attributes:c}:{uid:b,attributes:c}};e.prototype._geometryForSerialization=function(a){return(a=a.geometry)?
this._geometryRequiresClientGraphicMapping(a)?k.Polygon.fromExtent(a.extent):a:null};d([u.shared({Type:l,ensureType:v.ensureType(l)})],e.prototype,"itemType",void 0);d([r.property()],e.prototype,"type",void 0);d([r.property({constructOnly:!0})],e.prototype,"layer",void 0);d([r.property({readOnly:!0,dependsOn:["layer.geometryType"]})],e.prototype,"workerGeometryType",null);d([r.property()],e.prototype,"layerDefinition",void 0);return e=d([r.subclass("esri.layers.graphics.sources.MemorySource")],e)}(r.declared(h,
a,n));e.MemorySource=h;e.default=h})},"esri/core/requireUtils":function(){define(["require","exports","./promiseUtils"],function(b,e,m){function d(b,e){return Array.isArray(e)?m.create(function(d){b(e,function(){for(var a=[],c=0;c<arguments.length;c++)a[c]=arguments[c];d(a)})}):d(b,[e]).then(function(b){return b[0]})}Object.defineProperty(e,"__esModule",{value:!0});e.when=d;e.getAbsMid=function(b,d,e){return d.toAbsMid?d.toAbsMid(b):e.id.replace(/\/[^\/]*$/gi,"/")+b}})},"esri/core/workers":function(){define(["require",
"exports","./workers/workers"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});for(var d in m)e.hasOwnProperty(d)||(e[d]=m[d])})},"esri/core/workers/workers":function(){define("require exports ../Error ../has ../promiseUtils ./Connection ./RemoteClient ./WorkerOwner".split(" "),function(b,e,m,d,k,l,h,a){function c(){if(p)return p;for(var c=f+n,b=[],d=function(c){var d=a.create(c).then(function(a){return q[c]=a});b.push(d)},e=0;e<c;e++)d(e);return p=k.all(b).then(function(){})}Object.defineProperty(e,
"__esModule",{value:!0});e.Connection=l;e.RemoteClient=h;(l=d("host-browser")?navigator.hardwareConcurrency:0)||(l=d("safari")&&d("mac")||d("trident")?8:2);var f=d("esri-workers-debug")?1:Math.max(1,Math.ceil(l/2)),n=d("esri-workers-debug")?1:Math.max(1,Math.floor(l/2)),g=0,q=[];e.initialize=function(){c()};e.openWithPorts=function(a,c){return new e.Connection(a.map(function(a){return new e.RemoteClient(a,c,{})}))};e.open=function(a,d){void 0===d&&(d={});if("string"!==typeof a)return k.reject(new m("workers:undefined-module",
"modulePath is missing"));var h=d.strategy||"distributed";if("local"===h){var p=d.client;return k.create(function(c){return b([a],function(a){p=p||a;c(e.RemoteClient.connect(a))})}).then(function(a){return new e.Connection([new e.RemoteClient(a,p,d)])})}return c().then(function(){if("dedicated"===h){var c=f+g++;g%=n;return q[c].open(a).then(function(a){return new e.Connection([new e.RemoteClient(a,d.client,d)])})}return k.all(q.map(function(c){return c.open(a)})).then(function(a){return new e.Connection(a.map(function(a){return new e.RemoteClient(a,
d.client,d)}))})})};e.terminate=function(){p&&(p.cancel(),p=null);for(var a=0;a<q.length;a++)q[a]&&q[a].terminate();q.length=0};var p=null})},"esri/core/workers/Connection":function(){define(["require","exports","../Logger","../promiseUtils"],function(b,e,m,d){var k=m.getLogger("esri.core.workers.Connection");return function(){function b(b){this._clientIdx=0;this._clients=b}b.prototype.broadcast=function(b,a,c){for(var d=[],e=0,g=this._clients;e<g.length;e++)d.push(g[e].invoke(b,a,c));return d};b.prototype.close=
function(){for(var b=0,a=this._clients;b<a.length;b++)a[b].close();this._clients=[]};b.prototype.getAvailableClient=function(){var b;this._clients.some(function(a){return a.isBusy()?!1:(b=a,!0)})||(this._clientIdx=(this._clientIdx+1)%this._clients.length,b=this._clients[this._clientIdx]);return b};b.prototype.invoke=function(b,a,c){var e=null;Array.isArray(c)?(k.warn("invoke()","The transferList parameter is deprecated, use the options object instead"),e={transferList:c}):e=c;return this._clients&&
this._clients.length?this.getAvailableClient().invoke(b,a,e):d.reject(Error("Connection closed"))};b.prototype.openPorts=function(){return d.all(this._clients.map(function(b){return b.openPort()}))};return b}()})},"esri/core/workers/RemoteClient":function(){define("require exports @dojo/framework/shim/AbortController ../Error ../promiseUtils ./utils".split(" "),function(b,e,m,d,k,l){function h(a,c){a["delete"](c)}function a(a){a=new d("AbortError",a);a.dojoType="cancel";return a}var c=l.MessageType.CLOSE,
f=l.MessageType.ABORT,n=l.MessageType.INVOKE,g=l.MessageType.RESPONSE,q=l.MessageType.OPEN_PORT,p=function(){function a(a){this._timer=null;this._cancelledJobIds=new Set;this._invokeMessages=[];this._invoke=a;this._timer=null;this._process=this._process.bind(this)}a.prototype.push=function(a){a.type===l.MessageType.ABORT?this._cancelledJobIds.add(a.jobId):(this._invokeMessages.push(a),null===this._timer&&(this._timer=setTimeout(this._process,0)))};a.prototype.clear=function(){this._invokeMessages.length=
0;this._cancelledJobIds.clear();this._timer=null};a.prototype._process=function(){this._timer=null;for(var a=0,c=this._invokeMessages;a<c.length;a++){var b=c[a];this._cancelledJobIds.has(b.jobId)||this._invoke(b)}this._cancelledJobIds.clear();this._invokeMessages.length=0};return a}();return function(){function b(a,c,b){var d=this;this._port=a;this._client=c;this._outJobs=new Map;this._inJobs=new Map;this._queue=new p(function(a){return d._onInvoke(a)});this._responseQueue=[];this._onMessage=this._onMessage.bind(this);
this._port.addEventListener("message",this._onMessage);this._port.start();this._channel=b.channel;b.scheduler&&(this._frameTask=b.scheduler.registerTask(1,function(a){return d._update(a)},function(){return 0<d._responseQueue.length}))}b.connect=function(a){var c=new MessageChannel;a="function"===typeof a?new a:"default"in a&&"function"===typeof a.default?new a.default:a;a.remoteClient=new b(c.port1,a,{channel:c});return c.port2};b.prototype.close=function(){this._post({type:c});this._close()};b.prototype.isBusy=
function(){return 0<this._outJobs.size};b.prototype.invoke=function(c,b,e){var g=this,p=e&&e.signal,m=e&&e.transferList;if(!this._port)return k.reject(new d("remote-client:port-closed","Can't invoke(), port is closed"));if(p&&p.aborted)return k.reject(a("Job already aborted"));var r=l.newJobId(),t=function(){p&&p.removeEventListener("abort",t);var c=g._outJobs.get(r);c&&(h(g._outJobs,r),g._post({type:f,jobId:r}),c.reject(a("Job aborted")))};p&&p.addEventListener("abort",t);return k.create(function(a,
d){g._outJobs.set(r,{resolve:a,reject:d});g._post({type:n,jobId:r,methodName:c,abortable:!0},b,m)},t)};b.prototype.openPort=function(){var a=this,c=l.newJobId(),b=function(){h(a._outJobs,c);a._post({type:f,jobId:c})};return k.create(function(d,e){a._outJobs.set(c,{resolve:d,reject:e,signal:b});a._post({type:q,jobId:c})},b)};b.prototype._close=function(){this._channel&&(this._channel=null);this._port.removeEventListener("message",this._onMessage);this._port.close();this._outJobs.forEach(function(c){return c.reject(a("Abort job: worker closing"))});
this._inJobs.clear();this._outJobs.clear();this._queue.clear();this._port=this._client=null;this._frameTask&&this._frameTask.remove();this._responseQueue=this._frameTask=null};b.prototype._onMessage=function(a){if(a=l.receiveMessage(a))switch(a.type){case g:this._onResponse(a);break;case n:this._queue.push(a);break;case f:this._onAbort(a);break;case c:this._onClose();break;case q:this._onOpenPort(a)}};b.prototype._onAbort=function(a){var c=this._inJobs,b=a.jobId,d=c.get(b);this._queue.push(a);d&&
(d.controller&&d.controller.abort(),h(c,b))};b.prototype._onClose=function(){var a=this._client;this._close();a&&a.remoteClient===this&&"destroy"in a&&a.destroy();a.remoteClient=null};b.prototype._onInvoke=function(a){var c=this,b=a.methodName,d=a.jobId,e=a.data,f=a.abortable?new m.default:null,p=this._inJobs;a=this._client;var n=a[b],r;try{if(!n&&b&&-1!==b.indexOf("."))for(var t=b.split("."),q=0;q<t.length-1;q++)a=a[t[q]],n=a[t[q+1]];if("function"!==typeof n)throw new TypeError(b+" is not a function");
r=n.call(a,e,{client:this,signal:f?f.signal:null})}catch(G){this._post({type:g,jobId:d,error:l.toInvokeError(G)});return}if(k.isThenable(r)){p.set(d,{controller:f,promise:r});var E=function(){p.has(d)&&(f.signal.removeEventListener("abort",E),r.cancel(),h(p,d))};f.signal.addEventListener("abort",E);r.then(function(a){p.has(d)&&(h(p,d),c._post({type:g,jobId:d},a))}).catch(function(a){p.has(d)&&(f.signal.removeEventListener("abort",E),h(p,d),a&&"AbortError"===a.name||c._post({type:g,jobId:d,error:l.toInvokeError(a||
{message:"Error encountered at method "+b})}))})}else this._post({type:g,jobId:d},r)};b.prototype._onOpenPort=function(a){var c=new MessageChannel;new b(c.port1,this._client,{});this._post({type:g,jobId:a.jobId},c.port2,[c.port2])};b.prototype._onResponse=function(a){this._frameTask?this._responseQueue.push(a):this._handleResponse(a)};b.prototype._update=function(a){for(;!a.done&&0<this._responseQueue.length;)this._handleResponse(this._responseQueue.shift()),a.madeProgress()};b.prototype._handleResponse=
function(a){var c=a.jobId,b=a.error;a=a.data;var e=this._outJobs;if(e.has(c)){var f=e.get(c);h(e,c);b?f.reject(d.fromJSON(JSON.parse(b))):f.resolve(a)}};b.prototype._post=function(a,c,b){return l.postMessage(this._port,a,c,b)};return b}()})},"@dojo/framework/shim/AbortController":function(){(function(b){"object"===typeof module&&"object"===typeof module.exports?(b=b(require,exports),void 0!==b&&(module.exports=b)):"function"===typeof define&&define.amd&&define(["require","exports","./global","../has/has",
"./array"],b)})(function(b,e){Object.defineProperty(e,"__esModule",{value:!0});var m=b("./global"),d=b("../has/has"),k=b("./array");e.ShimAbortSignal=m.default.AbortSignal;d.default("abort-signal")||(m.default.AbortSignal=e.ShimAbortSignal=function(){function b(){this._aborted=!1;this.listeners={}}Object.defineProperty(b.prototype,"aborted",{get:function(){return this._aborted},enumerable:!0,configurable:!0});b.prototype.addEventListener=function(b,a){b in this.listeners||(this.listeners[b]=[]);this.listeners[b].push(a)};
b.prototype.removeEventListener=function(b,a){if(b in this.listeners){var c=k.findIndex(this.listeners[b],function(c){return c===a});0<=c&&this.listeners[b].splice(c,1)}};b.prototype.dispatchEvent=function(b){var a=this,c=b.type;"abort"===c&&(this._aborted=!0,"function"===typeof this.onabort&&this.onabort.call(this,b));if(!(c in this.listeners))return!1;this.listeners[c].forEach(function(c){setTimeout(function(){return c.call(a,b)},0)});return!b.preventDefault};return b}());e.ShimAbortController=
m.default.AbortController;d.default("abort-controller")||(m.default.AbortController=e.ShimAbortController=function(){function b(){this.signal=new e.ShimAbortSignal}b.prototype.abort=function(){var b;try{b=new Event("abort")}catch(a){"undefined"!==typeof document?(b=document.createEvent("Event"),b.initEvent("abort",!1,!1)):b={type:"abort",bubbles:!1,cancelable:!1}}this.signal.dispatchEvent(b)};return b}());e.default=e.ShimAbortController})},"esri/core/workers/utils":function(){define(["require","exports",
"../has"],function(b,e,m){function d(b){return b&&"object"===typeof b&&("result"in b||"transferList"in b)}function k(b){return b instanceof ArrayBuffer||b&&b.constructor&&"ArrayBuffer"===b.constructor.name}Object.defineProperty(e,"__esModule",{value:!0});(function(b){b[b.HANDSHAKE=0]="HANDSHAKE";b[b.CONFIGURE=1]="CONFIGURE";b[b.CONFIGURED=2]="CONFIGURED";b[b.OPEN=3]="OPEN";b[b.OPENED=4]="OPENED";b[b.RESPONSE=5]="RESPONSE";b[b.INVOKE=6]="INVOKE";b[b.ABORT=7]="ABORT";b[b.CLOSE=8]="CLOSE";b[b.OPEN_PORT=
9]="OPEN_PORT"})(e.MessageType||(e.MessageType={}));var l=0;e.newJobId=function(){return l++};e.isTranferableResult=d;e.toInvokeError=function(b){return b?b.toJSON?JSON.stringify(b):JSON.stringify({name:b.name,message:b.message,details:b.details,stack:b.stack}):null};e.postMessage=function(b,a,c,e){2===arguments.length||void 0===c&&void 0===e?b.postMessage(a):(m("esri-workers-arraybuffer-transfer")||(e?(e=e.filter(function(a){return!k(a)}),e.length||(e=null)):d(c)&&c.transferList&&(c.transferList=
c.transferList.filter(function(a){return!k(a)}),c.transferList.length||(c.transferList=null))),e?(a.data=c,b.postMessage(a,e)):d(c)?(a.data=c.result,c.transferList?b.postMessage(a,c.transferList):b.postMessage(a)):(a.data=c,b.postMessage(a)))};e.receiveMessage=function(b){return b?(b=b.data)?"string"===typeof b?JSON.parse(b):b:null:null}})},"esri/core/workers/WorkerOwner":function(){define("require exports ../../kernel ../Error ../Logger ../promiseUtils ./utils ./workerFactory".split(" "),function(b,
e,m,d,k,l,h,a){var c=k.getLogger("esri.core.workers"),f=h.MessageType.ABORT,n=h.MessageType.INVOKE,g=h.MessageType.OPEN,q=h.MessageType.OPENED,p=h.MessageType.RESPONSE;return function(){function b(a,b){this._outJobs=new Map;this._inJobs=new Map;this.worker=a;this.id=b;a.addEventListener("message",this._onMessage.bind(this));a.addEventListener("error",function(a){a.preventDefault();c.error(a)})}b.create=function(c){return a.createWorker().then(function(a){return new b(a,c)})};b.prototype.terminate=
function(){this.worker.terminate()};b.prototype.open=function(a){var c=this,b=h.newJobId(),d=function(){c._outJobs["delete"](b);c._post({type:f,jobId:b})};return l.create(function(e,f){c._outJobs.set(b,{resolve:e,reject:f,cancel:d});c._post({type:g,jobId:b,modulePath:a})},d)};b.prototype._onMessage=function(a){if(a=h.receiveMessage(a))switch(a.type){case q:case p:this._onResponse(a);break;case f:this._onCancel(a);break;case n:this._onInvoke(a)}};b.prototype._onCancel=function(a){(a=this._inJobs.get(a.jobId))&&
a.cancel()};b.prototype._onInvoke=function(a){var c=this,b=a.methodName,d=a.jobId;a=a.data;var e=this._inJobs,f=m.workerMessages[b],g;try{if("function"!==typeof f)throw new TypeError(b+" is not a function");g=f.call(null,a)}catch(A){this._post({type:p,jobId:d,error:h.toInvokeError(A)});return}l.isThenable(g)?(e.set(d,g),g.then(function(a){e["delete"](d);c._post({type:p,jobId:d},a)}).catch(function(a){e["delete"](d);a||(a={message:"Error encountered at method"+b});a.dojoType&&"cancel"===a.dojoType||
c._post({type:p,jobId:d,error:h.toInvokeError(a)})})):this._post({type:p,jobId:d},g)};b.prototype._onResponse=function(a){var c=a.jobId,b=a.error;a=a.data;var e=this._outJobs.get(c);e&&(this._outJobs["delete"](c),b?e.reject(d.fromJSON(JSON.parse(b))):e.resolve(a))};b.prototype._post=function(a,c,b){return h.postMessage(this.worker,a,c,b)};return b}()})},"esri/core/workers/workerFactory":function(){define("require exports ../tsSupport/assignHelper dojo/_base/kernel ../../config ../has ../Logger ../promiseUtils ./loaderConfig ./utils ./WorkerFallback".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){function g(b){return a.create(function(a){function e(h){if(h=f.receiveMessage(h))switch(h.type){case r:h=b;var n=k.workers.loaderUrl||c.DEFAULT_LOADER_URL,q;null!=k["default"]?(q=m({},k),delete q["default"],q=JSON.parse(JSON.stringify(q))):q=JSON.parse(JSON.stringify(k));var u=k.workers.loaderConfig,u=c.default({baseUrl:u.baseUrl,locale:d.locale,has:m({"config-deferredInstrumentation":0,"dojo-test-sniff":0,"esri-secure-context":l("esri-secure-context"),"esri-workers-arraybuffer-transfer":l("esri-workers-arraybuffer-transfer"),
"events-keypress-typed":0,"host-webworker":1},u.has),map:m({},u.map),paths:m({},u.paths),packages:u.packages||[]});h.postMessage({type:t,configure:{esriConfig:q,loaderUrl:n,loaderConfig:u}});break;case p:b.removeEventListener("message",e),b.removeEventListener("error",g),a(b)}}function g(a){a.preventDefault();b.removeEventListener("message",e);b.removeEventListener("error",g);q.warn("Failed to create Worker. Fallback to execute module in main thread",a);b=new n;b.addEventListener("message",e);b.addEventListener("error",
g)}b.addEventListener("message",e);b.addEventListener("error",g)})}Object.defineProperty(e,"__esModule",{value:!0});var q=h.getLogger("esri.core.workers");l.add("esri-workers-arraybuffer-transfer",!l("safari")||12<=l("safari"));var p=f.MessageType.CONFIGURED,t=f.MessageType.CONFIGURE,r=f.MessageType.HANDSHAKE,v;try{v=URL.createObjectURL(new Blob(['var globalId\x3d0;var outgoing\x3dnew Map;var configured\x3dfalse;var HANDSHAKE\x3d0;var CONFIGURE\x3d1;var CONFIGURED\x3d2;var OPEN\x3d3;var OPENED\x3d4;var RESPONSE\x3d5;var INVOKE\x3d6;var CANCEL\x3d7;function mapDelete(map,key){map["delete"](key)}function receiveMessage(event){if(!event||!event.data){return null}if(typeof event.data\x3d\x3d\x3d"string"){return JSON.parse(event.data)}return event.data}function invokeStaticMessage(methodName,data,options){var signal\x3doptions\x26\x26options.signal;var Deferred\x3drequire("dojo/Deferred");var jobId\x3dglobalId++;var abortHandler\x3dfunction(){if(!outgoing.has(jobId)){return}self.postMessage({type:CANCEL,methodName:methodName,jobId:jobId});mapDelete(outgoing,jobId);if(!deferred.isCanceled()){deferred.cancel()}if(signal){signal.removeEventListener("abort",abortHandler)}};if(signal){signal.addEventListener("abort",abortHandler)}var deferred\x3dnew Deferred(abortHandler);outgoing.set(jobId,deferred);self.postMessage({type:INVOKE,methodName:methodName,jobId:jobId,data:data});return deferred.promise}function messageHandler(event){var message\x3dreceiveMessage(event);if(!message){return}var jobId\x3dmessage.jobId;switch(message.type){case CONFIGURE:var configuration\x3dmessage.configure;if(configured){return}self.dojoConfig\x3dconfiguration.loaderConfig;self.importScripts(configuration.loaderUrl);if(typeof require.config\x3d\x3d\x3d"function"){require.config(configuration.loaderConfig)}require(["esri/config"],function(esriConfig){for(var name in configuration.esriConfig){if(Object.prototype.hasOwnProperty.call(configuration.esriConfig,name)){esriConfig[name]\x3dconfiguration.esriConfig[name]}}self.postMessage({type:CONFIGURED})});break;case OPEN:var modulePath\x3dmessage.modulePath;require(["esri/core/workers/RemoteClient",modulePath],function(RemoteClient,Module){var port\x3dRemoteClient.connect(Module);self.postMessage({type:OPENED,jobId:jobId,data:port},[port])});break;case RESPONSE:if(outgoing.has(jobId)){var deferred\x3doutgoing.get(jobId);mapDelete(outgoing,jobId);if(message.error){deferred.reject(JSON.parse(message.error))}else{deferred.resolve(message.data)}}break}}self.addEventListener("message",messageHandler);self.postMessage({type:HANDSHAKE});'],
{type:"text/javascript"}))}catch(u){}e.createWorker=function(){if(!l("esri-workers"))return g(new n);var a;if(v)try{a=new Worker(v)}catch(z){q.warn("Failed to create Worker. Fallback to execute module in main thread",event),a=new n}else q.warn("Failed to create Worker. Fallback to execute module in main thread",event),a=new n;return g(a)}})},"esri/core/workers/loaderConfig":function(){define(["require","exports","../tsSupport/assignHelper","../has","../urlUtils"],function(b,e,m,d,k){Object.defineProperty(e,
"__esModule",{value:!0});d=d("esri-built")?"dojo/dojo-lite.js":"dojo/dojo.js";e.DEFAULT_LOADER_URL=k.makeAbsolute(k.removeQueryParameters(b.toUrl(d)));e.DEFAULT_CONFIG={baseUrl:function(){var d=k.removeQueryParameters(b.toUrl("dojo/x.js"));return k.makeAbsolute(d.slice(0,d.length-5))}(),packages:[{name:"esri"},{name:"dojo"},{name:"dojox"},{name:"dstore"},{name:"moment",main:"moment"},{name:"@dojo"},{name:"cldrjs",main:"dist/cldr"},{name:"globalize",main:"dist/globalize"},{name:"maquette",main:"dist/maquette.umd"},
{name:"maquette-css-transitions",main:"dist/maquette-css-transitions.umd"},{name:"maquette-jsx",main:"dist/maquette-jsx.umd"},{name:"tslib",main:"tslib"}],map:{globalize:{cldr:"cldrjs/dist/cldr","cldr/event":"cldrjs/dist/cldr/event","cldr/supplemental":"cldrjs/dist/cldr/supplemental","cldr/unresolved":"cldrjs/dist/cldr/unresolved"}}};e.default=function(d){var h={async:d.async,isDebug:d.isDebug,locale:d.locale,baseUrl:d.baseUrl,has:m({},d.has),map:m({},d.map),packages:d.packages&&d.packages.concat()||
[],paths:m({},d.paths)};d.hasOwnProperty("async")||(h.async=!0);d.hasOwnProperty("isDebug")||(h.isDebug=!1);d.baseUrl||(h.baseUrl=e.DEFAULT_CONFIG.baseUrl);e.DEFAULT_CONFIG.packages.forEach(function(a){a:{for(var c=h.packages,d=0;d<c.length;d++)if(c[d].name===a.name)break a;a=m({},a);d=k.removeQueryParameters(b.toUrl(a.name+"/x.js"));d=d.slice(0,d.length-5);a.location=k.makeAbsolute(d);c.push(a)}});d=h.map=h.map||{};for(var a=0,c=Object.keys(e.DEFAULT_CONFIG.map);a<c.length;a++){var f=c[a];d[f]||
(d[f]=e.DEFAULT_CONFIG.map[f])}return h}})},"esri/core/workers/WorkerFallback":function(){define(["require","exports","../global","../has","./utils"],function(b,e,m,d,k){var l=function(){return function(){var a=this,c=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach(function(b){a[b]=function(){for(var a=[],d=0;d<arguments.length;d++)a[d]=arguments[d];return c[b].apply(c,a)}})}}(),h=m.MutationObserver||m.WebKitMutationObserver,a=function(){var a;
if(m.process&&m.process.nextTick)a=function(a){m.process.nextTick(a)};else if(m.Promise)a=function(a){m.Promise.resolve().then(a)};else if(h){var c=[],b=document.createElement("div");(new h(function(){for(;0<c.length;)c.shift()()})).observe(b,{attributes:!0});a=function(a){c.push(a);b.setAttribute("queueStatus","1")}}return a}(),c=function(){var a=m.MessageEvent;try{new a("message",{data:null})}catch(n){return function(a,c){void 0===c&&(c={});var b=c.data,d=c.bubbles,d=void 0===d?!1:d;c=c.cancelable;
c=void 0===c?!1:c;var e=document.createEvent("Event");e.initEvent(a,d,c);e.data=b;return e}}return function(c,b){return new a(c,b)}}();return function(){function d(){this._dispatcher=new l;this._isInitialized=!1;this._workerPostMessage({type:k.MessageType.HANDSHAKE})}d.prototype.terminate=function(){};Object.defineProperty(d.prototype,"onmessage",{get:function(){return this._onmessageHandler},set:function(a){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler);(this._onmessageHandler=
a)&&this.addEventListener("message",a)},enumerable:!0,configurable:!0});Object.defineProperty(d.prototype,"onerror",{get:function(){return this._onerrorHandler},set:function(a){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler);(this._onerrorHandler=a)&&this.addEventListener("error",a)},enumerable:!0,configurable:!0});d.prototype.postMessage=function(b,d){var e=this;a(function(){e._workerMessageHandler(c("message",{data:b}))})};d.prototype.dispatchEvent=function(a){return this._dispatcher.dispatchEvent(a)};
d.prototype.addEventListener=function(a,c,b){this._dispatcher.addEventListener(a,c,b)};d.prototype.removeEventListener=function(a,c,b){this._dispatcher.removeEventListener(a,c,b)};d.prototype._workerPostMessage=function(b,d){var e=this;a(function(){e.dispatchEvent(c("message",{data:b}))})};d.prototype._workerMessageHandler=function(a){var c=this;if(a=k.receiveMessage(a)){var d=a.jobId;switch(a.type){case k.MessageType.CONFIGURE:this._isInitialized||this._workerPostMessage({type:k.MessageType.CONFIGURED});
break;case k.MessageType.OPEN:b(["esri/core/workers/RemoteClient",a.modulePath],function(a,b){a=a.connect(b);c._workerPostMessage({type:k.MessageType.OPENED,jobId:d,data:a})})}}};return d}()})},"esri/core/accessorSupport/typescript":function(){define(["../declare","../typescript","../JSONSupport","../lang"],function(b,e,m,d){function k(b,d){if(!b)return d;if(!d)return b;for(var a in d){var c=b[a],e=d[a];Array.isArray(e)&&Array.isArray(c)?b[a]=c.concat(e):b[a]="object"===typeof e&&"object"===typeof c?
k(c,e):e}return b}return{subclass:function(l,h){return function(a){a=e.declareDefinition(a,l);c&&(a.instanceMembers.properties=k(c,a.instanceMembers.properties));var c=a.instanceMembers.properties;if(c)for(var f in c){var h=c[f];h&&!h.reader&&h.type&&(h.type===Date?h.reader=function(a){return null!=a?new Date(a):null}:-1!==h.type._meta.bases.indexOf(m)&&(h.reader=function(a){return function(c){return a.fromJSON(c)}}(h.type)))}return d.mixin(b(a.bases,a.instanceMembers),a.classMembers)}},shared:e.shared,
property:function(b){return function(d,a){var c=Object.getPrototypeOf(d),c=c&&c.properties;d.properties&&d.properties!==c||(d.properties={});d.properties=d.properties||{};d.properties[a]=b||{}}}}})},"esri/core/typescript":function(){define(["./declare","./lang"],function(b,e){var m={declareDefinition:function(b,e){var d=[],h=Object.getPrototypeOf(b.prototype),a;if(h!==Object.prototype){var c=h.constructor;a=c.prototype;d.push(c)}e&&(d=d.concat(e));e={};for(var c=Object.getOwnPropertyNames(b.prototype),
f=0;f<c.length;f++){var k=c[f];if("constructor"!==k){var g=k;"dojoConstructor"===k&&(g="constructor");a&&b.prototype[k]===a[k]||(e[g]=b.prototype[k])}}c=Object.getOwnPropertyNames(b);h=Object.getOwnPropertyNames(h.constructor);a={};for(f=0;f<c.length;f++)k=c[f],-1===h.indexOf(k)&&(a[k]=b[k]);return{bases:d,instanceMembers:e,classMembers:a}},subclass:function(d){return function(k){k=m.declareDefinition(k,d);return e.mixin(b(k.bases,k.instanceMembers),k.classMembers)}},shared:function(b){return function(d,
e){d[e]=b}}};return m})},"esri/tasks/support/FeatureSet":function(){define("require exports ../../core/tsSupport/decorateHelper ../../core/tsSupport/declareExtendsHelper ../../geometry ../../Graphic ../../core/JSONSupport ../../core/kebabDictionary ../../core/accessorSupport/decorators ../../geometry/SpatialReference ../../geometry/support/jsonUtils ../../layers/support/Field".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){var q=new a.default({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",
esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent"});b=function(a){function b(c){c=a.call(this,c)||this;c.displayFieldName=null;c.exceededTransferLimit=!1;c.features=[];c.fields=null;c.geometryType=null;c.hasM=!1;c.hasZ=!1;c.queryGeometry=null;c.spatialReference=null;return c}d(b,a);b.prototype.readFeatures=function(a,c){c=f.fromJSON(c.spatialReference);for(var b=[],d=0;d<a.length;d++){var e=a[d],g=l.fromJSON(e),e=e.geometry&&e.geometry.spatialReference;g.geometry&&
!e&&(g.geometry.spatialReference=c);b.push(g)}return b};b.prototype.writeGeometryType=function(a,c,b,d){if(a)q.write(a,c,b,d);else if(a=this.features)for(var e=0;e<a.length;e++){var f=a[e];if(f&&f.geometry){q.write(f.geometry.type,c,b,d);break}}};b.prototype.writeSpatialReference=function(a,c,b,d){if(a)c.spatialReference=a.toJSON();else if(a=this.features)for(b=0;b<a.length;b++)(d=a[b])&&d.geometry&&d.geometry.spatialReference&&(c.spatialReference=d.geometry.spatialReference.toJSON())};b.prototype.toJSON=
function(a){var c=this.write(null);if(c.features&&Array.isArray(a)&&0<a.length)for(var b=0;b<c.features.length;b++){var d=c.features[b];if(d.geometry){var e=a&&a[b];d.geometry=e&&e.toJSON()||d.geometry}}return c};b.prototype.quantize=function(a){for(var c=a.scale,b=c[0],d=c[1],c=a.translate,e=c[0],f=c[1],c=this.features,g=this._getQuantizationFunction(this.geometryType,function(a){return Math.round((a-e)/b)},function(a){return Math.round((f-a)/d)}),h=0,p=c.length;h<p;h++)g(c[h].geometry)||(c.splice(h,
1),h--,p--);this.transform=a;return this};b.prototype.unquantize=function(){var a=this.features,c=this.transform;if(!c)return this;for(var b=c.translate,d=b[0],e=b[1],c=c.scale,f=c[0],g=c[1],c=this._getHydrationFunction(this.geometryType,function(a){return a*f+d},function(a){return e-a*g}),b=0;b<a.length;b++){var h=a[b].geometry;h&&c(h)}return this};b.prototype._quantizePoints=function(a,c,b){for(var d,e,f=[],g=0,h=a.length;g<h;g++){var p=a[g];if(0<g){var k=c(p[0]),p=b(p[1]);if(k!==d||p!==e)f.push([k-
d,p-e]),d=k,e=p}else d=c(p[0]),e=b(p[1]),f.push([d,e])}return 0<f.length?f:null};b.prototype._getQuantizationFunction=function(a,c,b){var d=this;if("point"===a)return function(a){a.x=c(a.x);a.y=b(a.y);return a};if("polyline"===a||"polygon"===a)return function(a){for(var e=n.isPolygon(a)?a.rings:a.paths,f=[],g=0,h=e.length;g<h;g++){var p=d._quantizePoints(e[g],c,b);p&&f.push(p)}return 0<f.length?(n.isPolygon(a)?a.rings=f:a.paths=f,a):null};if("multipoint"===a)return function(a){var e;e=d._quantizePoints(a.points,
c,b);return 0<e.length?(a.points=e,a):null};if("extent"===a)return function(a){return a}};b.prototype._getHydrationFunction=function(a,c,b){if("point"===a)return function(a){a.x=c(a.x);a.y=b(a.y)};if("polyline"===a||"polygon"===a)return function(a){a=n.isPolygon(a)?a.rings:a.paths;for(var d,e,f=0,g=a.length;f<g;f++)for(var h=a[f],p=0,k=h.length;p<k;p++){var l=h[p];0<p?(d+=l[0],e+=l[1]):(d=l[0],e=l[1]);l[0]=c(d);l[1]=b(e)}};if("extent"===a)return function(a){a.xmin=c(a.xmin);a.ymin=b(a.ymin);a.xmax=
c(a.xmax);a.ymax=b(a.ymax)};if("multipoint"===a)return function(a){a=a.points;for(var d,e,f=0,g=a.length;f<g;f++){var h=a[f];0<f?(d+=h[0],e+=h[1]):(d=h[0],e=h[1]);h[0]=c(d);h[1]=b(e)}}};m([c.property({type:String,json:{write:!0}})],b.prototype,"displayFieldName",void 0);m([c.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],b.prototype,"exceededTransferLimit",void 0);m([c.property({type:[l],json:{write:!0}})],b.prototype,"features",void 0);m([c.reader("features")],
b.prototype,"readFeatures",null);m([c.property({type:[g],json:{write:!0}})],b.prototype,"fields",void 0);m([c.property({type:"point multipoint polyline polygon extent mesh".split(" "),json:{read:{reader:q.read}}})],b.prototype,"geometryType",void 0);m([c.writer("geometryType")],b.prototype,"writeGeometryType",null);m([c.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],b.prototype,"hasM",void 0);m([c.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],
b.prototype,"hasZ",void 0);m([c.property({types:k.geometryTypes,json:{read:n.fromJSON,write:!0}})],b.prototype,"queryGeometry",void 0);m([c.property({type:f,json:{write:!0}})],b.prototype,"spatialReference",void 0);m([c.writer("spatialReference")],b.prototype,"writeSpatialReference",null);m([c.property({json:{write:!0}})],b.prototype,"transform",void 0);return b=m([c.subclass("esri.tasks.support.FeatureSet")],b)}(c.declared(h));b.prototype.toJSON.isDefaultToJSON=!0;(function(a){})(b||(b={}));return b})},
"esri/layers/mixins/TemporalLayer":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators ../../layers/support/TimeInfo ../support/fieldUtils".split(" "),function(b,e,m,d,k,l,h,a){return function(c){function b(){return null!==c&&c.apply(this,arguments)||this}m(b,c);Object.defineProperty(b.prototype,"timeInfo",{set:function(c){a.fixTimeInfoFields(c,this.fields);this._set("timeInfo",c)},
enumerable:!0,configurable:!0});d([l.property({value:null,type:h,json:{write:!0}})],b.prototype,"timeInfo",null);return b=d([l.subclass("esri.layers.mixins.TemporalLayer")],b)}(l.declared(k))})},"esri/layers/support/TimeInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../TimeExtent ../../TimeSpan ../../core/JSONSupport ../../core/lang ../../core/accessorSupport/decorators ./TimeReference ./timeUtils".split(" "),function(b,e,
m,d,k,l,h,a,c,f,n){return function(b){function e(a){a=b.call(this)||this;a.cumulative=!1;a.endField=null;a.hasLiveData=!1;a.interval=null;a.offset=null;a.startField=null;a.timeReference=null;a.timeExtent=null;a.trackIdField=null;a.useTime=void 0;return a}m(e,b);g=e;e.prototype.readInterval=function(a,c){a=c.timeInterval;c=n.timeUnitKebabDictionary.fromJSON(c.timeIntervalUnits);return a&&c?new l({value:a,unit:c}):null};e.prototype.writeInterval=function(a,c){a?(a=a.toJSON(),c.timeInterval=a.value,
c.timeIntervalUnits=a.unit):(c.timeInterval=null,c.timeIntervalUnits=null)};e.prototype.readOffset=function(a,c){a=c.exportOptions.timeOffset;c=n.timeUnitKebabDictionary.fromJSON(c.exportOptions.timeOffsetUnits);return a&&c?new l({value:a,unit:c}):null};e.prototype.writeOffset=function(a,c){c.exportOptions||(c.exportOptions={});a?(a=a.toJSON(),c.exportOptions.timeOffset=a.value,c.exportOptions.timeOffsetUnits=a.unit):(c.exportOptions.timeOffset=null,c.exportOptions.timeOffsetUnits=null)};e.prototype.readTimeExtent=
function(a,c){return c.timeExtent&&Array.isArray(c.timeExtent)&&2===c.timeExtent.length?new k({start:c.timeExtent[0],end:c.timeExtent[1]}):null};e.prototype.writeTimeExtent=function(a,c,b){c.timeExtent=a&&a.start&&a.end?[a.start.getTime(),a.end.getTime()]:null};e.prototype.clone=function(){var c=this.timeExtent,b=this.trackIdField,d=this.useTime;return new g({cumulative:this.cumulative,endField:this.endField,hasLiveData:this.hasLiveData,interval:this.interval,offset:this.offset,startField:this.startField,
timeReference:a.clone(this.timeReference),timeExtent:a.clone(c),trackIdField:b,useTime:d})};var g;d([c.property({type:Boolean,json:{read:{source:"exportOptions.timeDataCumulative"},write:{target:"exportOptions.timeDataCumulative"}}})],e.prototype,"cumulative",void 0);d([c.property({type:String,json:{read:{source:"endTimeField"},write:{target:"endTimeField",allowNull:!0}}})],e.prototype,"endField",void 0);d([c.property({type:Boolean,json:{write:!0}})],e.prototype,"hasLiveData",void 0);d([c.property({type:l,
json:{write:{enabled:!0,allowNull:!0}}})],e.prototype,"interval",void 0);d([c.reader("interval",["timeInterval","timeIntervalUnits"])],e.prototype,"readInterval",null);d([c.writer("interval")],e.prototype,"writeInterval",null);d([c.property({type:l,json:{write:{enabled:!0,allowNull:!0}}})],e.prototype,"offset",void 0);d([c.reader("offset",["exportOptions.timeOffset","exportOptions.timeOffset"])],e.prototype,"readOffset",null);d([c.writer("offset")],e.prototype,"writeOffset",null);d([c.property({type:String,
json:{read:{source:"startTimeField"},write:{target:"startTimeField",allowNull:!0}}})],e.prototype,"startField",void 0);d([c.property({type:f,json:{write:{enabled:!0,allowNull:!0}}})],e.prototype,"timeReference",void 0);d([c.property({type:k,json:{write:{enabled:!0,allowNull:!0}}})],e.prototype,"timeExtent",void 0);d([c.reader("timeExtent")],e.prototype,"readTimeExtent",null);d([c.writer("timeExtent")],e.prototype,"writeTimeExtent",null);d([c.property({type:String,json:{write:{enabled:!0,allowNull:!0}}})],
e.prototype,"trackIdField",void 0);d([c.property({type:Boolean,json:{read:{source:"exportOptions.useTime"},write:{target:"exportOptions.useTime"}}})],e.prototype,"useTime",void 0);return e=g=d([c.subclass("esri.layers.support.TimeInfo")],e)}(c.declared(h))})},"esri/TimeExtent":function(){define("require exports ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./core/JSONSupport ./core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){var h={milliseconds:{getter:"getUTCMilliseconds",
setter:"setUTCMilliseconds",multiplier:1},seconds:{getter:"getUTCSeconds",setter:"setUTCSeconds",multiplier:1},minutes:{getter:"getUTCMinutes",setter:"setUTCMinutes",multiplier:1},hours:{getter:"getUTCHours",setter:"setUTCHours",multiplier:1},days:{getter:"getUTCDate",setter:"setUTCDate",multiplier:1},weeks:{getter:"getUTCDate",setter:"setUTCDate",multiplier:7},months:{getter:"getUTCMonth",setter:"setUTCMonth",multiplier:1},years:{getter:"getUTCFullYear",setter:"setUTCFullYear",multiplier:1},decades:{getter:"getUTCFullYear",
setter:"setUTCFullYear",multiplier:10},centuries:{getter:"getUTCFullYear",setter:"setUTCFullYear",multiplier:100}};return function(a){function c(c){c=a.call(this)||this;c.end=null;c.start=null;return c}m(c,a);b=c;c.prototype.readEnd=function(a,c){return null!=c.end?new Date(c.end):null};c.prototype.writeEnd=function(a,c,b){c.end=a?a.getTime():null};c.prototype.readStart=function(a,c){return null!=c.start?new Date(c.start):null};c.prototype.writeStart=function(a,c,b){c.start=a?a.getTime():null};c.prototype.clone=
function(){return new b({end:this.end,start:this.start})};c.prototype.intersection=function(a){if(!a)return null;var c=this.start?this.start.getTime():-Infinity,d=this.end?this.end.getTime():Infinity,e=a.start?a.start.getTime():-Infinity;a=a.end?a.end.getTime():Infinity;var f,h;e>=c&&e<=d?f=e:c>=e&&c<=a&&(f=c);d>=e&&d<=a?h=d:a>=c&&a<=d&&(h=a);return isNaN(f)||isNaN(h)?null:(c=new b,c.start=-Infinity===f?null:new Date(f),c.end=Infinity===h?null:new Date(h),c)};c.prototype.offset=function(a,c){var d=
new b,e=this.start,f=this.end;e&&(d.start=this._offsetDate(e,a,c));f&&(d.end=this._offsetDate(f,a,c));return d};c.prototype._offsetDate=function(a,c,b){a=new Date(a.getTime());c&&b&&(b=h[b],a[b.setter](a[b.getter]()+c*b.multiplier));return a};var b;d([l.property({type:Date,json:{write:{allowNull:!0}}})],c.prototype,"end",void 0);d([l.reader("end")],c.prototype,"readEnd",null);d([l.writer("end")],c.prototype,"writeEnd",null);d([l.property({type:Date,json:{write:{allowNull:!0}}})],c.prototype,"start",
void 0);d([l.reader("start")],c.prototype,"readStart",null);d([l.writer("start")],c.prototype,"writeStart",null);return c=b=d([l.subclass("esri.TimeExtent")],c)}(l.declared(k))})},"esri/TimeSpan":function(){define("require exports ./core/tsSupport/declareExtendsHelper ./core/tsSupport/decorateHelper ./core/JSONSupport ./core/accessorSupport/decorators ./layers/support/timeUtils".split(" "),function(b,e,m,d,k,l,h){return function(a){function c(c){c=a.call(this)||this;c.value=0;c.unit=null;return c}
m(c,a);d([l.property({type:Number,json:{write:!0}})],c.prototype,"value",void 0);d([l.property({type:h.timeUnitKebabDictionary.apiValues,json:{type:h.timeUnitKebabDictionary.jsonValues,read:h.timeUnitKebabDictionary.read,write:h.timeUnitKebabDictionary.write}})],c.prototype,"unit",void 0);return c=d([l.subclass("esri.TimeSpan")],c)}(l.declared(k))})},"esri/layers/support/timeUtils":function(){define(["require","exports","../../core/kebabDictionary"],function(b,e,m){Object.defineProperty(e,"__esModule",
{value:!0});e.timeUnitKebabDictionary=m.strict()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:null})})},"esri/layers/support/TimeReference":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.respectsDaylightSaving=!1;a.timezone=null;return a}m(a,b);c=a;a.prototype.readRespectsDaylightSaving=function(a,c){return void 0!==c.respectsDaylightSaving?c.respectsDaylightSaving:void 0!==c.respectDaylightSaving?c.respectDaylightSaving:!1};a.prototype.clone=function(){return new c({respectsDaylightSaving:this.respectsDaylightSaving,timezone:this.timezone})};var c;d([l.property({type:Boolean,json:{write:!0}})],a.prototype,
"respectsDaylightSaving",void 0);d([l.reader("respectsDaylightSaving",["respectsDaylightSaving","respectDaylightSaving"])],a.prototype,"readRespectsDaylightSaving",null);d([l.property({type:String,json:{read:{source:"timeZone"},write:{target:"timeZone"}}})],a.prototype,"timezone",void 0);return a=c=d([l.subclass("esri.layers.support.TimeReference")],a)}(l.declared(k))})},"esri/layers/support/FeatureIndex":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function a(a){return b.call(this,a)||this}m(a,b);c=a;a.prototype.clone=function(){return new c({name:this.name,fields:this.fields,isAscending:this.isAscending,isUnique:this.isUnique,description:this.description})};var c;d([l.property({constructOnly:!0})],a.prototype,"name",void 0);d([l.property({constructOnly:!0})],a.prototype,"fields",void 0);d([l.property({constructOnly:!0})],a.prototype,"isAscending",void 0);d([l.property({constructOnly:!0})],
a.prototype,"isUnique",void 0);d([l.property({constructOnly:!0})],a.prototype,"description",void 0);return a=c=d([l.subclass("esri.layers.support.FeatureIndex")],a)}(l.declared(k));e.FeatureIndex=b;e.default=b})},"esri/layers/support/FeatureProcessing":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/lang ../../core/accessorSupport/decorators ./Field ./fieldUtils".split(" "),function(b,e,m,d,k,l,h,a,c){return function(b){function e(){return null!==
b&&b.apply(this,arguments)||this}m(e,b);f=e;e.fromWorker=function(c){if(!c)return null;c=JSON.parse(c);var b=new f;b.fields=c.fields&&c.fields.map(function(c){return a.fromJSON(c)});b.options=c.options;b.process=new (Function.bind.apply(Function,[void 0].concat(c.process.args,[c.process.body])));return b};Object.defineProperty(e.prototype,"version",{get:function(){return(this._get("version")||0)+1},enumerable:!0,configurable:!0});e.prototype.clone=function(){return new f(l.clone({fields:this.fields,
options:this.options,process:this.process}))};e.prototype.getField=function(a){return c.getField(this.fields,a)};e.prototype.refresh=function(){this.notifyChange("version")};e.prototype.toWorker=function(){var a=this.process.toString();return JSON.stringify({fields:this.fields,options:this.options,process:{body:a.substring(a.indexOf("{")+1,a.lastIndexOf("}")),args:a.slice(a.indexOf("(")+1,a.indexOf(")")).match(/([^\s,]+)/g)}})};var f;d([h.property({type:[a]})],e.prototype,"fields",void 0);d([h.property()],
e.prototype,"options",void 0);d([h.property()],e.prototype,"process",void 0);d([h.property({readOnly:!0,dependsOn:["process","options","fields"]})],e.prototype,"version",null);return e=f=d([h.subclass("esri.layers.support.FeatureProcessing")],e)}(h.declared(k))})},"esri/layers/support/FeatureReduction":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),function(b,
e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.type=null;return a}m(a,b);d([l.property({type:["selection"],readOnly:!0,json:{read:!1,write:!0}})],a.prototype,"type",void 0);return a=d([l.subclass("esri.layers.support.FeatureReduction")],a)}(l.declared(k));e.FeatureReduction=b;e.default=b})},"esri/layers/support/FeatureReductionSelection":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/accessorSupport/decorators ./FeatureReduction".split(" "),
function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});b=function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.type="selection";return a}m(a,b);d([k.property({type:["selection"]})],a.prototype,"type",void 0);return a=d([k.subclass("esri.layers.support.FeatureReductionSelection")],a)}(k.declared(l.default));e.FeatureReductionSelection=b;e.default=b})},"esri/layers/support/FeatureTemplate":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/lang ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a){var c=new l.default({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",
esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});return function(b){function e(a){a=b.call(this,a)||this;a.name=null;a.description=null;a.drawingTool=null;a.prototype=null;a.thumbnail=null;return a}m(e,b);e.prototype.writeDrawingTool=function(a,b){b.drawingTool=c.toJSON(a)};e.prototype.writePrototype=function(a,c){c.prototype=h.fixJson(h.clone(a),!0)};e.prototype.writeThumbnail=function(a,c){c.thumbnail=h.fixJson(h.clone(a))};
d([a.property({json:{write:!0}})],e.prototype,"name",void 0);d([a.property({json:{write:!0}})],e.prototype,"description",void 0);d([a.property({json:{read:c.read,write:c.write}})],e.prototype,"drawingTool",void 0);d([a.writer("drawingTool")],e.prototype,"writeDrawingTool",null);d([a.property({json:{write:!0}})],e.prototype,"prototype",void 0);d([a.writer("prototype")],e.prototype,"writePrototype",null);d([a.property({json:{write:!0}})],e.prototype,"thumbnail",void 0);d([a.writer("thumbnail")],e.prototype,
"writeThumbnail",null);return e=d([a.subclass("esri.layers.support.FeatureTemplate")],e)}(a.declared(k))})},"esri/layers/support/FeatureType":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/lang ../../core/accessorSupport/decorators ./domains ./FeatureTemplate".split(" "),function(b,e,m,d,k,l,h,a,c){return function(b){function e(a){a=b.call(this,a)||this;a.id=null;a.name=null;a.domains=null;a.templates=
null;return a}m(e,b);e.prototype.readDomains=function(c){var b={},d;for(d in c)if(c.hasOwnProperty(d)){var e=c[d];switch(e.type){case "range":b[d]=a.RangeDomain.fromJSON(e);break;case "codedValue":b[d]=a.CodedValueDomain.fromJSON(e);break;case "inherited":b[d]=a.InheritedDomain.fromJSON(e)}}return b};e.prototype.writeDomains=function(a,c){var b={},d;for(d in a)a.hasOwnProperty(d)&&(b[d]=a[d]&&a[d].toJSON());l.fixJson(b);c.domains=b};e.prototype.readTemplates=function(a){return a&&a.map(function(a){return new c(a)})};
e.prototype.writeTemplates=function(a,c){c.templates=a&&a.map(function(a){return a.toJSON()})};d([h.property({json:{write:!0}})],e.prototype,"id",void 0);d([h.property({json:{write:!0}})],e.prototype,"name",void 0);d([h.property({json:{write:!0}})],e.prototype,"domains",void 0);d([h.reader("domains")],e.prototype,"readDomains",null);d([h.writer("domains")],e.prototype,"writeDomains",null);d([h.property({json:{write:!0}})],e.prototype,"templates",void 0);d([h.reader("templates")],e.prototype,"readTemplates",
null);d([h.writer("templates")],e.prototype,"writeTemplates",null);return e=d([h.subclass("esri.layers.support.FeatureType")],e)}(h.declared(k))})},"esri/layers/support/LabelClass":function(){define("require exports ../../core/tsSupport/decorateHelper ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/generatorHelper ../../core/tsSupport/awaiterHelper ../../symbols ../../core/JSONSupport ../../core/kebabDictionary ../../core/lang ../../core/accessorSupport/decorators ./LabelExpressionInfo ./labelUtils ./types ../../support/arcadeUtils ../../symbols/support/jsonUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r){function v(a){return a?"service"===a.origin?!1:!a.layer||!p.isOfType(a.layer,"map-image"):!0}function u(a){a=(a=t.createSyntaxTree(a))&&a.body&&a.body[0]&&a.body[0].body&&a.body[0].body.body;if(!a||1!==a.length)return null;a="ExpressionStatement"===a[0].type&&a[0].expression;if(!a||"MemberExpression"!==a.type)return null;var c=a.object;if(!c||"Identifier"!==c.type||"$feature"!==c.name)return null;a=a.property;if(!a)return null;switch(a.type){case "Literal":return a.value;
case "Identifier":return a.name}return null}var z=new c.default({esriServerPointLabelPlacementAboveCenter:"above-center",esriServerPointLabelPlacementAboveLeft:"above-left",esriServerPointLabelPlacementAboveRight:"above-right",esriServerPointLabelPlacementBelowCenter:"below-center",esriServerPointLabelPlacementBelowLeft:"below-left",esriServerPointLabelPlacementBelowRight:"below-right",esriServerPointLabelPlacementCenterCenter:"center-center",esriServerPointLabelPlacementCenterLeft:"center-left",
esriServerPointLabelPlacementCenterRight:"center-right",esriServerLinePlacementAboveAfter:"above-after",esriServerLinePlacementAboveAlong:"above-along",esriServerLinePlacementAboveBefore:"above-before",esriServerLinePlacementAboveStart:"above-start",esriServerLinePlacementAboveEnd:"above-end",esriServerLinePlacementBelowAfter:"below-after",esriServerLinePlacementBelowAlong:"below-along",esriServerLinePlacementBelowBefore:"below-before",esriServerLinePlacementBelowStart:"below-start",esriServerLinePlacementBelowEnd:"below-end",
esriServerLinePlacementCenterAfter:"center-after",esriServerLinePlacementCenterAlong:"center-along",esriServerLinePlacementCenterBefore:"center-before",esriServerLinePlacementCenterStart:"center-start",esriServerLinePlacementCenterEnd:"center-end",esriServerPolygonPlacementAlwaysHorizontal:"always-horizontal"},{ignoreUnknown:!0}),y=/^\s*\{([^}]+)\}\s*$/i;return function(a){function c(c){c=a.call(this,c)||this;c.name=null;c.labelExpression=null;c.labelExpressionInfo=null;c.labelPlacement=null;c.maxScale=
0;c.minScale=0;c.symbol=null;c.useCodedValues=void 0;c.where=null;return c}d(c,a);b=c;c.evaluateWhere=function(a,c){var b=function(a,c,b){switch(c){case "\x3d":return a==b?!0:!1;case "\x3c\x3e":return a!=b?!0:!1;case "\x3e":return a>b?!0:!1;case "\x3e\x3d":return a>=b?!0:!1;case "\x3c":return a<b?!0:!1;case "\x3c\x3d":return a<=b?!0:!1}return!1};try{if(null==a)return!0;var d=a.split(" ");if(3===d.length)return b(c[d[0]],d[1],d[2]);if(7===d.length){var e=b(c[d[0]],d[1],d[2]),f=d[3],g=b(c[d[4]],d[5],
d[6]);switch(f){case "AND":return e&&g;case "OR":return e||g}}return!1}catch(R){console.log("Error.: can't parse \x3d "+a)}};c.prototype.readLabelExpression=function(a,c){c=c.labelExpressionInfo;if(!c||!c.value&&!c.expression)return a};c.prototype.writeLabelExpression=function(a,c,b,d){this.labelExpressionInfo&&v(d)&&(null!=this.labelExpressionInfo.value?a=this.labelExpressionInfo.value.replace(/\{/g,"[").replace(/\}/g,"]"):null!=this.labelExpressionInfo.expression&&(d=u(this.labelExpressionInfo.expression))&&
(a="["+d+"]"));null!=a&&(c[b]=a)};c.prototype.writeLabelExpressionInfo=function(a,c,b,d){if(null==a&&null!=this.labelExpression&&v(d))a=new g({expression:this.getLabelExpressionArcade()});else if(!a)return;a=a.toJSON(d);a.expression&&(c[b]=a)};c.prototype.writeMaxScale=function(a,c){if(a||this.minScale)c.maxScale=a};c.prototype.writeMinScale=function(a,c){if(a||this.maxScale)c.minScale=a};c.prototype.getLabelExpression=function(){var a={expression:"",type:"none"};this.labelExpressionInfo?this.labelExpressionInfo.value?
(a.expression=this.labelExpressionInfo.value,a.type="conventional"):this.labelExpressionInfo.expression&&(a.expression=this.labelExpressionInfo.expression,a.type="arcade"):null!=this.labelExpression&&(a.expression=this.labelExpression.replace(/\[/g,"{").replace(/\]/g,"}"),a.type="conventional");return a};c.prototype.getLabelExpressionArcade=function(){var a=this.getLabelExpression();if(!a)return null;switch(a.type){case "conventional":return q.convertTemplatedStringToArcade(a.expression);case "arcade":return a.expression}return null};
c.prototype.getLabelExpressionSingleField=function(){var a=this.getLabelExpression();if(!a)return null;switch(a.type){case "conventional":return(a=a.expression.match(y))&&a[1].trim()||null;case "arcade":return u(a.expression)}return null};c.prototype.clone=function(){return new b({labelExpression:this.labelExpression,labelExpressionInfo:f.clone(this.labelExpressionInfo),labelPlacement:this.labelPlacement,maxScale:this.maxScale,minScale:this.minScale,name:this.name,symbol:f.clone(this.symbol),where:this.where,
useCodedValues:this.useCodedValues})};var b;m([n.property({type:String,json:{write:!0}})],c.prototype,"name",void 0);m([n.property({type:String,json:{write:{allowNull:!0}}})],c.prototype,"labelExpression",void 0);m([n.reader("labelExpression")],c.prototype,"readLabelExpression",null);m([n.writer("labelExpression")],c.prototype,"writeLabelExpression",null);m([n.property({type:g,json:{write:{overridePolicy:function(a,c,b){return v(b)?{allowNull:!0}:{enabled:!1}}}}})],c.prototype,"labelExpressionInfo",
void 0);m([n.writer("labelExpressionInfo")],c.prototype,"writeLabelExpressionInfo",null);m([n.property({type:z.apiValues,json:{type:z.jsonValues,read:z.read,write:z.write}})],c.prototype,"labelPlacement",void 0);m([n.property({type:Number})],c.prototype,"maxScale",void 0);m([n.writer("maxScale")],c.prototype,"writeMaxScale",null);m([n.property({type:Number})],c.prototype,"minScale",void 0);m([n.writer("minScale")],c.prototype,"writeMinScale",null);m([n.property({types:h.symbolTypesLabel,json:{origins:{"web-scene":{read:r.read,
write:{target:{symbol:{types:h.symbolTypesLabel3D}},writer:r.writeTarget}}},read:r.read,write:r.writeTarget}})],c.prototype,"symbol",void 0);m([n.property({type:Boolean,json:{write:!0}})],c.prototype,"useCodedValues",void 0);m([n.property({type:String,json:{write:!0}})],c.prototype,"where",void 0);return c=b=m([n.subclass("esri.layers.support.LabelClass")],c)}(n.declared(a))})},"esri/layers/support/LabelExpressionInfo":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators ./labelUtils".split(" "),
function(b,e,m,d,k,l,h){return function(a){function c(){var c=null!==a&&a.apply(this,arguments)||this;c.value=null;c.expression=null;return c}m(c,a);b=c;c.prototype.readExpression=function(a,c){return c.value?h.convertTemplatedStringToArcade(c.value):a};c.prototype.writeExpression=function(a,c,b){null!=this.value&&(a=h.convertTemplatedStringToArcade(this.value));c[b]=a};c.prototype.clone=function(){return new b({value:this.value,expression:this.expression})};var b;d([l.property({json:{read:!1,write:!1}})],
c.prototype,"value",void 0);d([l.property({type:String,json:{write:{allowNull:!0}}})],c.prototype,"expression",void 0);d([l.reader("expression",["expression","value"])],c.prototype,"readExpression",null);d([l.writer("expression")],c.prototype,"writeExpression",null);return c=b=d([l.subclass("esri.layers.support.LabelExpressionInfo")],c)}(l.declared(k))})},"esri/layers/support/labelUtils":function(){define(["require","exports","../../core/string"],function(b,e,m){Object.defineProperty(e,"__esModule",
{value:!0});var d=/__begin__/ig,k=/__end__/ig,l=/^__begin__/i,h=/__end__$/i;e.convertTemplatedStringToArcade=function(a){a?(a=m.replace(a,function(a,b){return'__begin__$feature["'+b+'"]__end__'}),a=l.test(a)?a.replace(l,""):'"'+a,a=h.test(a)?a.replace(h,""):a+'"',a=a.replace(d,'" + ').replace(k,' + "')):a='""';return a}})},"esri/core/string":function(){define(["require","exports","./object"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.replace=function(b,e,l){void 0===l&&(l=
/\{([^\}]+)\}/g);return b.replace(l,"object"===typeof e?function(b,a){return m.getDeepValue(a,e)}:e)}})},"esri/layers/support/labelingInfo":function(){define(["require","exports","./LabelClass"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});var d=/\[([^\[\]]+)\]/gi;e.reader=function(b,e,h){var a=this;return b?b.map(function(c){var b=new m;b.read(c,h);if(b.labelExpression){var k=e.fields||e.layerDefinition&&e.layerDefinition.fields||a.fields;b.labelExpression=b.labelExpression.replace(d,
function(a,c){a:if(k){a=c.toLowerCase();for(var b=0;b<k.length;b++){var d=k[b].name;if(d.toLowerCase()===a){c=d;break a}}}return"["+c+"]"})}return b}):null}})},"esri/layers/support/layerSourceUtils":function(){define(["require","exports","../../core/kebabDictionary","../../core/lang"],function(b,e,m,d){function k(a){return null!=a&&a.hasOwnProperty("mapLayerId")}function l(a){return null!=a&&a.hasOwnProperty("dataSource")}function h(a){if(!a)return a;k(a)&&(a.type=e.MAPLAYER);if(l(a)&&(a.type=e.DATALAYER,
!a.dataSource.type)){var c=a.dataSource;c.workspaceId?c.type=c.gdbVersion?"table":c.query||c.oidFields?"query-table":"raster":c.leftTableKey&&c.rightTableKey&&c.leftTableSource&&c.rightTableSource&&(c.type="join-table",c.leftTableSource=h(c.leftTableSource),c.rightTableSource=h(c.rightTableSource))}return a}function a(c){var b={};if(c.type===e.MAPLAYER)b.mapLayerId=c.mapLayerId,c.gdbVersion&&(b.gdbVersion=c.gdbVersion);else if(c.type===e.DATALAYER){c.fields&&(b.fields=c.fields);var h;h=c.dataSource;
var k;switch(h.type){case "table":k={dataSourceName:h.dataSourceName,workspaceId:h.workspaceId,gdbVersion:h.gdbVersion};break;case "query-table":k={geometryType:f.toJSON(h.geometryType),workspaceId:h.workspaceId,query:h.query,oidFields:h.oidFields,spatialReference:h.spatialReference};break;case "join-table":k={leftTableSource:a(h.leftTableSource),rightTableSource:a(h.rightTableSource),leftTableKey:h.leftTableKey,rightTableKey:h.rightTableKey,joinType:q.toJSON(h.joinType)};break;case "raster":k={workspaceId:h.workspaceId,
dataSourceName:h.dataSourceName}}k.type=g.toJSON(h.type);h=d.fixJson(k);b.dataSource=h}b.type=n.toJSON(c.type);return d.fixJson(b)}function c(a){var b={};if(n.fromJSON(a.type)===e.MAPLAYER)b.mapLayerId=a.mapLayerId,a.gdbVersion&&(b.gdbVersion=a.gdbVersion);else if(n.fromJSON(a.type)===e.DATALAYER){a.fields&&(b.fields=a.fields);var h;h=a.dataSource;var k;switch(h.type){case "table":k={dataSourceName:h.dataSourceName,workspaceId:h.workspaceId,gdbVersion:h.gdbVersion};break;case "queryTable":k={geometryType:f.fromJSON(h.geometryType),
workspaceId:h.workspaceId,query:h.query,oidFields:h.oidFields,spatialReference:h.spatialReference};break;case "joinTable":k={leftTableSource:c(h.leftTableSource),rightTableSource:c(h.rightTableSource),leftTableKey:h.leftTableKey,rightTableKey:h.rightTableKey,joinType:q.fromJSON(h.joinType)};break;case "raster":k={workspaceId:h.workspaceId,dataSourceName:h.dataSourceName}}k.type=g.fromJSON(h.type);h=d.fixJson(k);b.dataSource=h}b.type=n.fromJSON(a.type);return d.fixJson(b)}Object.defineProperty(e,"__esModule",
{value:!0});e.MAPLAYER="map-layer";e.DATALAYER="data-layer";var f=new m.default({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryMultiPatch:"multipatch"}),n=new m.default({mapLayer:e.MAPLAYER,dataLayer:e.DATALAYER}),g=new m.default({joinTable:"join-table",queryTable:"query-table"}),q=new m.default({esriLeftOuterJoin:"left-outer-join",esriLeftInnerJoin:"left-inner-join"});e.isMapLayerSource=k;e.isDataLayerSource=
l;e.castSource=h;e.sourceToJSON=a;e.sourceFromJSON=c})},"esri/layers/support/Relationship":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/kebabDictionary ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h){var a=new l.default({esriRelCardinalityOneToOne:"one-to-one",esriRelCardinalityOneToMany:"one-to-many",esriRelCardinalityManyToMany:"many-to-many"});return function(c){function b(a){a=
c.call(this,a)||this;a.cardinality=null;a.id=null;a.keyField=null;a.name=null;a.relatedTableId=null;return a}m(b,c);d([h.property({json:{read:a.read,write:a.write}})],b.prototype,"cardinality",void 0);d([h.property({json:{read:!0,write:!0}})],b.prototype,"id",void 0);d([h.property({json:{read:!0,write:!0}})],b.prototype,"keyField",void 0);d([h.property({json:{read:!0,write:!0}})],b.prototype,"name",void 0);d([h.property({json:{read:!0,write:!0}})],b.prototype,"relatedTableId",void 0);return b=d([h.subclass("esri.layers.support.Relationship")],
b)}(h.declared(k))})},"esri/support/popupUtils":function(){define("require exports ../core/tsSupport/assignHelper dojo/i18n!../widgets/Popup/nls/Popup ../PopupTemplate ../popup/content ../popup/FieldInfo ../popup/support/FieldInfoFormat".split(" "),function(b,e,m,d,k,l,h,a){function c(a,c){var b=a;c.ignoreFieldTypes&&(a=a.filter(function(a){return-1===c.ignoreFieldTypes.indexOf(a.type)}));if(0===a.length)return null;var d=c.maximumFields&&a.length>c.maximumFields;d&&(a=a.slice(0,c.maximumFields));
a===b&&(a=a.slice());a.sort(f);return{fields:a,limitExceeded:d}}function f(a,c){return"oid"===a.type?-1:"oid"===c.type?1:q(a)?-1:q(c)?1:(a.alias||a.name).toLocaleLowerCase().localeCompare((c.alias||c.name).toLocaleLowerCase())}function n(a){return a.map(function(a){return new h({fieldName:a.name,label:a.alias,format:g(a),visible:!0})})}function g(c){switch(c.type){case "small-integer":case "integer":case "single":return new a({digitSeparator:!0,places:0});case "double":return new a({digitSeparator:!0,
places:2});case "date":return new a({dateFormat:"long-month-day-year"});default:return null}}function q(a){if("name"===(a.name&&a.name.toLowerCase())||"name"===(a.alias&&a.alias.toLowerCase()))return!0}Object.defineProperty(e,"__esModule",{value:!0});e.createPopupTemplate=function(a,b){var e=a.fields;a=a.title;if(!e)return null;b=m({},p,b);e=c(e,b);if(!e)return null;a:{b=0;for(var f=e.fields;b<f.length;b++){var g=f[b];if(q(g)){a=a+": {"+g.name+"}";break a}}}f=e.limitExceeded;b=[new l.FieldsContent,
new l.AttachmentsContent];f&&b.push(new l.TextContent({text:"\x3csmall\x3e"+d.tooManyFields+"\x3c/small\x3e"}));e=n(e.fields);return new k({title:a,content:b,fieldInfos:e})};var p={ignoreFieldTypes:["geometry","blob","raster","guid","xml"],maximumFields:75}})},"esri/tasks/support/AttachmentQuery":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/lang ../../core/accessorSupport/decorators".split(" "),function(b,
e,m,d,k,l,h){return function(a){function c(c){c=a.call(this,c)||this;c.attachmentTypes=null;c.globalIds=null;c.num=null;c.objectIds=null;c.returnMetadata=!1;c.size=null;c.start=null;c.where=null;return c}m(c,a);b=c;c.prototype.writeStart=function(a,c,b){c.resultOffset=this.start;c.resultRecordCount=this.num||10};c.prototype.clone=function(){return new b(l.clone({attachmentTypes:this.attachmentTypes,where:this.where,globalIds:this.globalIds,num:this.num,objectIds:this.objectIds,returnMetadata:this.returnMetadata,
size:this.size,start:this.start}))};var b;d([h.property({type:[String],json:{write:!0}})],c.prototype,"attachmentTypes",void 0);d([h.property({type:[Number],json:{write:!0}})],c.prototype,"globalIds",void 0);d([h.property({type:Number,json:{read:{source:"resultRecordCount"}}})],c.prototype,"num",void 0);d([h.property({type:[Number],json:{write:!0}})],c.prototype,"objectIds",void 0);d([h.property({type:Boolean,json:{default:!1,write:!0}})],c.prototype,"returnMetadata",void 0);d([h.property({type:[Number],
json:{write:!0}})],c.prototype,"size",void 0);d([h.property({type:Number,json:{read:{source:"resultOffset"}}})],c.prototype,"start",void 0);d([h.writer("start"),h.writer("num")],c.prototype,"writeStart",null);d([h.property({type:String,json:{read:{source:"definitionExpression"},write:{target:"definitionExpression"}}})],c.prototype,"where",void 0);return c=b=d([h.subclass("esri.tasks.support.AttachmentQuery")],c)}(h.declared(k))})},"esri/tasks/support/Query":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../geometry ../../geometry ../../symbols ../../TimeExtent ../../core/JSONSupport ../../core/kebabDictionary ../../core/lang ../../core/accessorSupport/decorators ../../geometry/support/jsonUtils ../../symbols/support/jsonUtils ./QuantizationParameters ./StatisticDefinition".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r){var v=new f.default({esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"envelope-intersects",esriSpatialRelIndexIntersects:"index-intersects",esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:"relation"}),u=new f.default({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",
esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"});return function(c){function b(a){a=c.call(this,a)||this;a.datumTransformation=null;a.distance=void 0;a.gdbVersion=null;a.geometry=null;a.geometryPrecision=void 0;a.groupByFieldsForStatistics=null;a.having=null;a.historicMoment=null;a.maxAllowableOffset=void 0;a.maxRecordCountFactor=1;a.multipatchOption=null;a.num=void 0;a.objectIds=null;a.orderByFields=null;
a.outFields=null;a.outSpatialReference=null;a.outStatistics=null;a.parameterValues=null;a.pixelSize=null;a.quantizationParameters=null;a.rangeValues=null;a.relationParameter=null;a.resultType=null;a.returnCentroid=!1;a.returnDistinctValues=!1;a.returnExceededLimitFeatures=!0;a.returnGeometry=!1;a.returnQueryGeometry=!1;a.returnM=void 0;a.returnZ=void 0;a.source=null;a.spatialRelationship="intersects";a.start=void 0;a.sqlFormat=null;a.text=null;a.timeExtent=null;a.units=null;a.where=null;return a}
m(b,c);e=b;b.prototype.castDatumTransformation=function(a){return"number"===typeof a||"object"===typeof a?a:null};b.prototype.writeHistoricMoment=function(a,c,b){c.historicMoment=a&&a.getTime()};b.prototype.writeParameterValues=function(a,c,b){if(a){b={};for(var d in a){var e=a[d];Array.isArray(e)?b[d]=e.map(function(a){return a instanceof Date?a.getTime():a}):b[d]=e instanceof Date?e.getTime():e}c.parameterValues=b}};b.prototype.writeStart=function(a,c,b){c.resultOffset=this.start;c.resultRecordCount=
this.num||10;c.where="1\x3d1"};b.prototype.writeWhere=function(a,c,b){c.where=a||"1\x3d1"};b.prototype.clone=function(){return new e(n.clone({datumTransformation:this.datumTransformation,distance:this.distance,gdbVersion:this.gdbVersion,geometry:this.geometry,geometryPrecision:this.geometryPrecision,groupByFieldsForStatistics:this.groupByFieldsForStatistics,having:this.having,historicMoment:this.historicMoment?new Date(this.historicMoment.getTime()):null,maxAllowableOffset:this.maxAllowableOffset,
maxRecordCountFactor:this.maxRecordCountFactor,multipatchOption:this.multipatchOption,num:this.num,objectIds:this.objectIds,orderByFields:this.orderByFields,outFields:this.outFields,outSpatialReference:this.outSpatialReference,outStatistics:this.outStatistics,parameterValues:this.parameterValues,pixelSize:this.pixelSize,quantizationParameters:this.quantizationParameters,rangeValues:this.rangeValues,relationParameter:this.relationParameter,resultType:this.resultType,returnDistinctValues:this.returnDistinctValues,
returnGeometry:this.returnGeometry,returnCentroid:this.returnCentroid,returnExceededLimitFeatures:this.returnExceededLimitFeatures,returnQueryGeometry:this.returnQueryGeometry,returnM:this.returnM,returnZ:this.returnZ,source:this.source,spatialRelationship:this.spatialRelationship,start:this.start,sqlFormat:this.sqlFormat,text:this.text,timeExtent:this.timeExtent,units:this.units,where:this.where}))};var e;b.MAX_MAX_RECORD_COUNT_FACTOR=5;d([g.property({json:{write:!0}})],b.prototype,"datumTransformation",
void 0);d([g.cast("datumTransformation")],b.prototype,"castDatumTransformation",null);d([g.property({type:Number,json:{write:{overridePolicy:function(a){return{enabled:0<a}}}}})],b.prototype,"distance",void 0);d([g.property({type:String,json:{write:!0}})],b.prototype,"gdbVersion",void 0);d([g.property({types:l.geometryTypes,json:{read:q.fromJSON,write:!0}})],b.prototype,"geometry",void 0);d([g.property({type:Number,json:{write:!0}})],b.prototype,"geometryPrecision",void 0);d([g.property({type:[String],
json:{write:!0}})],b.prototype,"groupByFieldsForStatistics",void 0);d([g.property({type:String,json:{write:!0}})],b.prototype,"having",void 0);d([g.property({type:Date})],b.prototype,"historicMoment",void 0);d([g.writer("historicMoment")],b.prototype,"writeHistoricMoment",null);d([g.property({type:Number,json:{write:!0}})],b.prototype,"maxAllowableOffset",void 0);d([g.property({type:Number,cast:function(a){return 1>a?1:a>e.MAX_MAX_RECORD_COUNT_FACTOR?e.MAX_MAX_RECORD_COUNT_FACTOR:a},json:{write:{overridePolicy:function(a){return{enabled:1<
a}}}}})],b.prototype,"maxRecordCountFactor",void 0);d([g.property({type:String,json:{write:!0}})],b.prototype,"multipatchOption",void 0);d([g.property({type:Number,json:{read:{source:"resultRecordCount"}}})],b.prototype,"num",void 0);d([g.property({type:[Number],json:{write:!0}})],b.prototype,"objectIds",void 0);d([g.property({type:[String],json:{write:!0}})],b.prototype,"orderByFields",void 0);d([g.property({type:[String],json:{write:!0}})],b.prototype,"outFields",void 0);d([g.property({type:k.SpatialReference,
json:{read:{source:"outSR"},write:{target:"outSR"}}})],b.prototype,"outSpatialReference",void 0);d([g.property({type:[r],json:{write:!0}})],b.prototype,"outStatistics",void 0);d([g.property({json:{write:!0}})],b.prototype,"parameterValues",void 0);d([g.writer("parameterValues")],b.prototype,"writeParameterValues",null);d([g.property({types:h.symbolTypes,json:{read:p.read,write:!0}})],b.prototype,"pixelSize",void 0);d([g.property({type:t.default,json:{write:!0}})],b.prototype,"quantizationParameters",
void 0);d([g.property({type:[Object],json:{write:!0}})],b.prototype,"rangeValues",void 0);d([g.property({type:String,json:{read:{source:"relationParam"},write:{target:"relationParam",overridePolicy:function(a){return{enabled:"relation"===this.spatialRelationship}}}}})],b.prototype,"relationParameter",void 0);d([g.property({type:String,json:{write:!0}})],b.prototype,"resultType",void 0);d([g.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],b.prototype,"returnCentroid",
void 0);d([g.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],b.prototype,"returnDistinctValues",void 0);d([g.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:!a}}}}})],b.prototype,"returnExceededLimitFeatures",void 0);d([g.property({type:Boolean,json:{write:!0}})],b.prototype,"returnGeometry",void 0);d([g.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],b.prototype,"returnQueryGeometry",void 0);
d([g.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],b.prototype,"returnM",void 0);d([g.property({type:Boolean,json:{write:{overridePolicy:function(a){return{enabled:a}}}}})],b.prototype,"returnZ",void 0);d([g.property({json:{write:!0}})],b.prototype,"source",void 0);d([g.property({type:String,json:{read:{source:"spatialRel",reader:v.read},write:{target:"spatialRel",writer:v.write}}})],b.prototype,"spatialRelationship",void 0);d([g.property({type:Number,json:{read:{source:"resultOffset"}}})],
b.prototype,"start",void 0);d([g.writer("start"),g.writer("num")],b.prototype,"writeStart",null);d([g.property({type:String,json:{write:!0}})],b.prototype,"sqlFormat",void 0);d([g.property({type:String,json:{write:!0}})],b.prototype,"text",void 0);d([g.property({type:a,json:{write:!0}})],b.prototype,"timeExtent",void 0);d([g.property({type:String,json:{read:u.read,write:{writer:u.write,overridePolicy:function(a){return{enabled:a&&0<this.distance}}}}})],b.prototype,"units",void 0);d([g.property({type:String,
json:{write:{overridePolicy:function(a){return{enabled:null!=a||0<this.start}}}}})],b.prototype,"where",void 0);d([g.writer("where")],b.prototype,"writeWhere",null);return b=e=d([g.subclass("esri.tasks.support.Query")],b)}(g.declared(c))})},"esri/tasks/support/QuantizationParameters":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../geometry ../../core/JSONSupport ../../core/kebabDictionary ../../core/lang ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a,c){Object.defineProperty(e,"__esModule",{value:!0});var f=new h.default({upperLeft:"upper-left",lowerLeft:"lower-left"});b=function(b){function e(a){a=b.call(this,a)||this;a.extent=null;a.mode="view";a.originPosition="upper-left";a.tolerance=1;return a}m(e,b);h=e;e.prototype.clone=function(){return new h(a.clone({extent:this.extent,mode:this.mode,originPosition:this.originPosition,tolerance:this.tolerance}))};var h;d([c.property({type:k.Extent,json:{write:!0}})],e.prototype,
"extent",void 0);d([c.property({type:["view","edit"],json:{write:!0}})],e.prototype,"mode",void 0);d([c.property({type:String,json:{read:f.read,write:f.write}})],e.prototype,"originPosition",void 0);d([c.property({type:Number,json:{write:!0}})],e.prototype,"tolerance",void 0);return e=h=d([c.subclass("esri.tasks.support.QuantizationParameters")],e)}(c.declared(l));e.default=b})},"esri/tasks/support/StatisticDefinition":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/JSONSupport ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l){return function(b){function a(a){a=b.call(this)||this;a.maxPointCount=void 0;a.maxRecordCount=void 0;a.maxVertexCount=void 0;a.onStatisticField=null;a.outStatisticFieldName=null;a.statisticType=null;return a}m(a,b);c=a;a.prototype.clone=function(){return new c({maxPointCount:this.maxPointCount,maxRecordCount:this.maxRecordCount,maxVertexCount:this.maxVertexCount,onStatisticField:this.onStatisticField,outStatisticFieldName:this.outStatisticFieldName,statisticType:this.statisticType})};
var c;d([l.property({type:Number,json:{write:!0}})],a.prototype,"maxPointCount",void 0);d([l.property({type:Number,json:{write:!0}})],a.prototype,"maxRecordCount",void 0);d([l.property({type:Number,json:{write:!0}})],a.prototype,"maxVertexCount",void 0);d([l.property({type:String,json:{write:!0}})],a.prototype,"onStatisticField",void 0);d([l.property({type:String,json:{write:!0}})],a.prototype,"outStatisticFieldName",void 0);d([l.property({type:String,json:{write:!0}})],a.prototype,"statisticType",
void 0);return a=c=d([l.subclass("esri.tasks.support.StatisticDefinition")],a)}(l.declared(k))})},"esri/tasks/support/RelationshipQuery":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../geometry ../../core/JSONSupport ../../core/lang ../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h,a){return function(c){function b(a){a=c.call(this,a)||this;a.gdbVersion=null;a.geometryPrecision=void 0;a.historicMoment=null;
a.maxAllowableOffset=void 0;a.objectIds=null;a.outFields=null;a.outSpatialReference=null;a.relationshipId=void 0;a.returnGeometry=!1;a.source=null;a.where=null;return a}m(b,c);e=b;b.prototype._writeHistoricMoment=function(a,c){c.historicMoment=a&&a.getTime()};b.prototype.clone=function(){return new e(h.clone({gdbVersion:this.gdbVersion,geometryPrecision:this.geometryPrecision,historicMoment:this.historicMoment&&this.historicMoment.getTime(),maxAllowableOffset:this.maxAllowableOffset,objectIds:this.objectIds,
outFields:this.outFields,outSpatialReference:this.outSpatialReference,relationshipId:this.relationshipId,returnGeometry:this.returnGeometry,source:this.source,where:this.where}))};var e;d([a.property({type:String,json:{write:!0}})],b.prototype,"gdbVersion",void 0);d([a.property({type:Number,json:{write:!0}})],b.prototype,"geometryPrecision",void 0);d([a.property({type:Date})],b.prototype,"historicMoment",void 0);d([a.writer("historicMoment")],b.prototype,"_writeHistoricMoment",null);d([a.property({type:Number,
json:{write:!0}})],b.prototype,"maxAllowableOffset",void 0);d([a.property({type:[Number],json:{write:!0}})],b.prototype,"objectIds",void 0);d([a.property({type:[String],json:{write:!0}})],b.prototype,"outFields",void 0);d([a.property({type:k.SpatialReference,json:{read:{source:"outSR"},write:{target:"outSR"}}})],b.prototype,"outSpatialReference",void 0);d([a.property({json:{write:!0}})],b.prototype,"relationshipId",void 0);d([a.property({json:{write:!0}})],b.prototype,"returnGeometry",void 0);d([a.property({json:{write:!0}})],
b.prototype,"source",void 0);d([a.property({type:String,json:{read:{source:"definitionExpression"},write:{target:"definitionExpression"}}})],b.prototype,"where",void 0);return b=e=d([a.subclass("esri.tasks.support.RelationshipQuery")],b)}(a.declared(l))})},"esri/layers/graphics/sources/FeatureLayerSource":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/tsSupport/assignHelper dojo/io-query ../../../request ../../../core/Accessor ../../../core/Error ../../../core/Loadable ../../../core/promiseUtils ../../../core/accessorSupport/decorators ../../../tasks/QueryTask ../../../tasks/operations/queryAttachments".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p){Object.defineProperty(e,"__esModule",{value:!0});b=function(a){function b(){var c=null!==a&&a.apply(this,arguments)||this;c.type="feature-layer";return c}m(b,a);b.prototype.load=function(){this.addResolvingPromise(this._fetchService());return this.when()};Object.defineProperty(b.prototype,"queryTask",{get:function(){var a=this.layer,c=a.parsedUrl,b=a.gdbVersion;return new q({url:null!=a.dynamicDataSource?c.path+"?"+l.objectToQuery(c.query):c.path,gdbVersion:b})},
enumerable:!0,configurable:!0});b.prototype.addAttachment=function(a,c){var b=this;return this.load().then(function(){var d=a.attributes[b.layer.objectIdField],e=b.layer.parsedUrl.path+"/"+d+"/addAttachment",f=k({f:"json"},b.layer.parsedUrl.query),f=b._getFormDataForAttachment(c,f);return h(e,{body:f}).then(function(a){return b._createFeatureEditResult(a.data.addAttachmentResult)}).catch(function(a){return n.reject(b._createAttachmentErrorResult(d,a))})})};b.prototype.updateAttachment=function(a,
c,b){var d=this;return this.load().then(function(){var e=a.attributes[d.layer.objectIdField],f=d.layer.parsedUrl.path+"/"+e+"/updateAttachment",g=k({f:"json"},d.layer.parsedUrl.query,{attachmentId:c}),g=d._getFormDataForAttachment(b,g);return h(f,{body:g}).then(function(a){return d._createFeatureEditResult(a.data.updateAttachmentResult)}).catch(function(a){return n.reject(d._createAttachmentErrorResult(e,a))})})};b.prototype.applyEdits=function(a){var c=this;return this.load().then(function(){var b=
a.addFeatures.map(c._serializeFeature,c),d=a.updateFeatures.map(c._serializeFeature,c),e=c._getFeatureIds(a.deleteFeatures),b={f:"json",adds:b.length?JSON.stringify(b):null,updates:d.length?JSON.stringify(d):null,deletes:e.length?e.join(","):null};return h(c.layer.parsedUrl.path+"/applyEdits",{query:b,method:"post",responseType:"json"})}).then(function(a){return c._createEditsResult(a)})};b.prototype.deleteAttachments=function(a,c){var b=this;return this.load().then(function(){var d=a.attributes[b.layer.objectIdField];
return h(b.layer.parsedUrl.path+"/"+d+"/deleteAttachments",{query:k({f:"json"},b.layer.parsedUrl.query,{attachmentIds:c.join(",")}),method:"post",responseType:"json"}).then(function(a){return a.data.deleteAttachmentResults.map(b._createFeatureEditResult)}).catch(function(a){return n.reject(b._createAttachmentErrorResult(d,a))})})};b.prototype.queryAttachments=function(a){var c=this,b=this.layer.parsedUrl,d=b.path;return this.load().then(function(){var e={query:k({},b.query,{f:"json"}),responseType:"json"};
if(!c.layer.get("capabilities.operations.supportsQueryAttachments")){for(var f=a.objectIds,g=[],l=0;l<f.length;l++)g.push(h(d+"/"+f[l]+"/attachments",e));return n.all(g).then(function(a){return f.map(function(c,b){return{parentObjectId:c,attachmentInfos:a[b].data.attachmentInfos}})}).then(function(a){return p.processAttachmentQueryResult(a,d)})}return c.queryTask.executeAttachmentQuery(a,e)})};b.prototype.queryFeatures=function(a,c){var b=this;return this.load().then(function(){return b.queryTask.execute(a,
c)})};b.prototype.queryFeaturesJSON=function(a,c){var b=this;return this.load().then(function(){return b.queryTask.executeJSON(a,c)})};b.prototype.queryObjectIds=function(a,c){var b=this;return this.load().then(function(){return b.queryTask.executeForIds(a,c)})};b.prototype.queryFeatureCount=function(a,c){var b=this;return this.load().then(function(){return b.queryTask.executeForCount(a,c)})};b.prototype.queryExtent=function(a,c){var b=this;return this.load().then(function(){return b.queryTask.executeForExtent(a,
c)})};b.prototype.queryRelatedFeatures=function(a){var c=this;return this.load().then(function(){return c.queryTask.executeRelationshipQuery(a)})};b.prototype._fetchService=function(){var a=this,c=this.layer.resourceInfo;return c?(this.layerDefinition=c,n.resolve()):h(this.layer.parsedUrl.path,{query:k({f:"json"},this.layer.parsedUrl.query),responseType:"json"}).then(function(c){a.layerDefinition=c.data})};b.prototype._serializeFeature=function(a){var c=a.geometry;a=a.attributes;return c?"mesh"===
c.type||"extent"===c.type?null:{geometry:c.toJSON(),attributes:a}:{attributes:a}};b.prototype._getFeatureIds=function(a){var c=a[0];return c?"objectId"in c?this._getIdsFromFeatureIdentifier(a):this._getIdsFromFeatures(a):[]};b.prototype._getIdsFromFeatures=function(a){var c=this.layer.objectIdField;return a.map(function(a){return a.attributes&&a.attributes[c]})};b.prototype._getIdsFromFeatureIdentifier=function(a){return a.map(function(a){return a.objectId})};b.prototype._createEditsResult=function(a){a=
a.data;return{addFeatureResults:a.addResults?a.addResults.map(this._createFeatureEditResult,this):[],updateFeatureResults:a.updateResults?a.updateResults.map(this._createFeatureEditResult,this):[],deleteFeatureResults:a.deleteResults?a.deleteResults.map(this._createFeatureEditResult,this):[]}};b.prototype._createFeatureEditResult=function(a){var b=!0===a.success?null:a.error||{code:void 0,description:void 0};return{objectId:a.objectId,globalId:a.globalId,error:b?new c("feature-layer-source:edit-failure",
b.description,{code:b.code}):null}};b.prototype._createAttachmentErrorResult=function(a,b){return{objectId:a,globalId:null,error:new c("feature-layer-source:attachment-failure",b.details.messages&&b.details.messages[0]||b.message,{code:b.details.httpStatus||b.details.messageCode})}};b.prototype._getFormDataForAttachment=function(a,c){if(a=a instanceof FormData?a:a&&a.elements?new FormData(a):null)for(var b in c){var d=c[b];null!=d&&(a.set?a.set(b,d):a.append(b,d))}return a};d([g.property()],b.prototype,
"type",void 0);d([g.property({constructOnly:!0})],b.prototype,"layer",void 0);d([g.property({readOnly:!0,dependsOn:["layer.parsedUrl","layer.gdbVersion","layer.dynamicDataSource"]})],b.prototype,"queryTask",null);return b=d([g.subclass("esri.layers.graphics.sources.FeatureLayerSource")],b)}(g.declared(a,f));e.default=b})},"esri/tasks/QueryTask":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/tsSupport/paramHelper ../core/tsSupport/assignHelper ../geometry ../core/accessorSupport/decorators ./Task ./operations/query ./operations/queryAttachments ./operations/queryRelatedRecords ./support/AttachmentQuery ./support/FeatureSet ./support/Query ./support/RelationshipQuery".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r){return function(c){function b(a){a=c.call(this,a)||this;a.gdbVersion=null;a.source=null;return a}m(b,c);b.prototype.execute=function(a,c){return this.executeJSON(a,c).then(function(a){return p.fromJSON(a)})};b.prototype.executeJSON=function(a,c){return f.executeQuery(this.parsedUrl,this._normalizeQuery(a),l({},this.requestOptions,c)).then(function(a){return a.data})};b.prototype.executeForCount=function(a,c){return f.executeQueryForCount(this.parsedUrl,this._normalizeQuery(a),
l({},this.requestOptions,c)).then(function(a){return a.data.count})};b.prototype.executeForExtent=function(a,c){return f.executeQueryForExtent(this.parsedUrl,this._normalizeQuery(a),l({},this.requestOptions,c)).then(function(a){return{count:a.data.count,extent:h.Extent.fromJSON(a.data.extent)}})};b.prototype.executeForIds=function(a,c){return f.executeQueryForIds(this.parsedUrl,this._normalizeQuery(a),l({},this.requestOptions,c)).then(function(a){return a.data.objectIds})};b.prototype.executeRelationshipQuery=
function(a,c){if(this.gdbVersion||this.source)a=a.clone().set({gdbVersion:this.gdbVersion||a.gdbVersion,source:this.source||a.source});return g.executeRelationshipQuery(this.parsedUrl,a,l({},this.requestOptions,c)).then(function(a){var c=a.data,b={};Object.keys(c).forEach(function(a){return b[a]=p.fromJSON(c[a])});return b})};b.prototype.executeAttachmentQuery=function(a,c){var b=this;return n.executeAttachmentQuery(this.parsedUrl,a,l({},this.requestOptions,c)).then(function(a){return n.processAttachmentQueryResult(a.data.attachmentGroups,
b.parsedUrl.path)})};b.prototype._normalizeQuery=function(a){return this.gdbVersion||this.source?a.clone().set({gdbVersion:this.gdbVersion||a.gdbVersion,source:this.source||a.source}):a};d([a.property()],b.prototype,"gdbVersion",void 0);d([a.property()],b.prototype,"source",void 0);d([k(0,a.cast(t))],b.prototype,"execute",null);d([k(0,a.cast(t))],b.prototype,"executeJSON",null);d([k(0,a.cast(t))],b.prototype,"executeForCount",null);d([k(0,a.cast(t))],b.prototype,"executeForExtent",null);d([k(0,a.cast(t))],
b.prototype,"executeForIds",null);d([k(0,a.cast(r))],b.prototype,"executeRelationshipQuery",null);d([k(0,a.cast(q))],b.prototype,"executeAttachmentQuery",null);return b=d([a.subclass("esri.tasks.QueryTask")],b)}(a.declared(c))})},"esri/tasks/operations/query":function(){define("require exports ../../core/tsSupport/assignHelper ../../request ../../core/urlUtils ../../geometry/support/jsonUtils ../../geometry/support/normalizeUtils ./pbfQueryUtils ./PBFWorker ./urlUtils".split(" "),function(b,e,m,d,
k,l,h,a,c,f){function n(a,c){var b=a.geometry;a=a.toJSON();b&&(a.geometry=JSON.stringify(b),a.geometryType=l.getJsonType(b),a.inSR=b.spatialReference.wkid||JSON.stringify(b.spatialReference));a.groupByFieldsForStatistics&&(a.groupByFieldsForStatistics=a.groupByFieldsForStatistics.join(","));a.objectIds&&(a.objectIds=a.objectIds.join(","));a.orderByFields&&(a.orderByFields=a.orderByFields.join(","));!a.outFields||c&&(c.returnCountOnly||c.returnExtentOnly||c.returnIdsOnly)?delete a.outFields:-1!==a.outFields.indexOf("*")?
a.outFields="*":a.outFields=a.outFields.join(",");a.outSR?a.outSR=a.outSR.wkid||JSON.stringify(a.outSR):b&&(a.returnGeometry||a.returnCentroid)&&(a.outSR=a.inSR);a.returnGeometry&&delete a.returnGeometry;a.outStatistics&&(a.outStatistics=JSON.stringify(a.outStatistics));a.pixelSize&&(a.pixelSize=JSON.stringify(a.pixelSize));a.quantizationParameters&&(a.quantizationParameters=JSON.stringify(a.quantizationParameters));a.source&&(a.layer=JSON.stringify({source:a.source}),delete a.source);if(a.timeExtent){b=
a.timeExtent;c=b.start;b=b.end;if(null!=c||null!=b)a.time=c===b?c:(null==c?"null":c)+","+(null==b?"null":b);delete a.timeExtent}return a}function g(a,c,b,e,g){void 0===e&&(e={});var p="string"===typeof a?k.urlToObject(a):a;a=c.geometry?[c.geometry]:[];e.responseType="pbf"===b?"array-buffer":"json";return h.normalizeCentralMeridian(a,null,e).then(function(a){if(a=a&&a[0])c=c.clone(),c.geometry=a;a=f.mapParameters(m({},p.query,{f:b},g,n(c,g)));return d(p.path+"/query",m({},e,{query:a}))})}Object.defineProperty(e,
"__esModule",{value:!0});e.queryToQueryStringParameters=n;e.executeQuery=function(a,c,b){return g(a,c,"json",b)};e.executeQueryPBF=function(b,d,e,f){return g(b,d,"pbf",f).then(function(b){var d=function(a){b.data=a;return b};return e.useWorker?(null==q&&(q=new c.PBFWorker),q.parseFeatureQuery(b.data,e).then(function(a){return d(a)})):d(a.parsePBFFeatureQuery(b.data,e))})};e.executeQueryForIds=function(a,c,b){return g(a,c,"json",b,{returnIdsOnly:!0})};e.executeQueryForCount=function(a,c,b){return g(a,
c,"json",b,{returnIdsOnly:!0,returnCountOnly:!0})};e.executeQueryForExtent=function(a,c,b){return g(a,c,"json",b,{returnExtentOnly:!0,returnCountOnly:!0}).then(function(a){var c=a.data;if(c.hasOwnProperty("extent"))return a;if(c.features)throw Error("Layer does not support extent calculation.");if(c.hasOwnProperty("count"))throw Error("Layer does not support extent calculation.");return a})};var q})},"esri/tasks/operations/pbfQueryUtils":function(){define(["require","exports","./pbfFeatureServiceParser"],
function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.parsePBFFeatureQuery=function(b,e){if((b=m.parseFeatureQuery(b,e).queryResult.featureResult)&&b.features&&b.features.length&&b.objectIdFieldName){e=b.objectIdFieldName;for(var d=0,h=b.features;d<h.length;d++){var a=h[d];a.attributes&&(a.objectId=a.attributes[e])}}return b}})},"esri/tasks/operations/pbfFeatureServiceParser":function(){define("require exports ../../core/Error ../../core/Logger ../../core/pbf ./pbfDehydratedFeatureSet ./pbfOptimizedFeatureSet".split(" "),
function(b,e,m,d,k,l,h){function a(a){for(;a.next();)switch(a.tag()){case 1:return a.getString();case 2:return a.getFloat();case 3:return a.getDouble();case 4:return a.getSInt32();case 5:return a.getUInt32();case 6:return a.getInt64();case 7:return a.getUInt64();case 8:return a.getSInt64();case 9:return a.getBool();default:return a.skip(),null}return null}function c(a){for(var c={type:0>=g.length?null:g[0]};a.next();)switch(a.tag()){case 1:c.name=a.getString();break;case 2:var b=a.getEnum();c.type=
b>=g.length?null:g[b];break;case 3:c.alias=a.getString();break;case 4:b=a.getEnum();b=b>=q.length?null:q[b];c.sqlType=b;break;default:a.skip()}return c}function f(c,b,d,e){for(var f=c.createFeature(b),g=0;d.next();)switch(d.tag()){case 1:var h=e[g++].name;f.attributes[h]=a(d.getMessage());break;case 2:for(var h=c,k=b,p=d.getMessage(),l=h.createGeometry(k),k=2+(k.hasZ?1:0)+(k.hasM?1:0);p.next();)switch(p.tag()){case 2:for(var n=p.getUInt32(),n=p.pos()+n,m=0;p.pos()<n;)h.addLength(l,p.getUInt32(),m++);
break;case 3:for(var n=p.getUInt32(),n=p.pos()+n,r=m=0;p.pos()<n;)h.addCoordinate(l,p.getSInt64(),r,m),m++,m===k&&(r++,m=0);break;default:p.skip()}f.geometry=l;break;case 4:h=c;p=d.getMessage();for(l=h.createPointGeometry(b);p.next();)switch(p.tag()){case 3:k=p.getUInt32();k=p.pos()+k;for(n=0;p.pos()<k;)h.addCoordinatePoint(l,p.getSInt64(),0,n++);break;default:p.skip()}f.centroid=l;break;default:d.skip()}return f}Object.defineProperty(e,"__esModule",{value:!0});var n=d.getLogger("esri.tasks.operations.pbfFeatureServiceParser"),
g="esriFieldTypeSmallInteger esriFieldTypeInteger esriFieldTypeSingle esriFieldTypeDouble esriFieldTypeString esriFieldTypeDate esriFieldTypeOID esriFieldTypeGeometry esriFieldTypeBlob esriFieldTypeRaster esriFieldTypeGUID esriFieldTypeGlobalID esriFieldTypeXML".split(" "),q="sqlTypeBigInt sqlTypeBinary sqlTypeBit sqlTypeChar sqlTypeDate sqlTypeDecimal sqlTypeDouble sqlTypeFloat sqlTypeGeometry sqlTypeGUID sqlTypeInteger sqlTypeLongNVarchar sqlTypeLongVarbinary sqlTypeLongVarchar sqlTypeNChar sqlTypeNVarchar sqlTypeOther sqlTypeReal sqlTypeSmallInt sqlTypeSqlXml sqlTypeTime sqlTypeTimestamp sqlTypeTimestamp2 sqlTypeTinyInt sqlTypeVarbinary sqlTypeVarchar".split(" "),
p=["upperLeft","lowerLeft"];e.parseFeatureQuery=function(a,b){b=b&&"dehydrated"===b.type?new l.Context(b):new h.Context(b);try{var d=new k(new Uint8Array(a),new DataView(a));for(a={};d.next();)switch(d.tag()){case 2:for(var e=a,g=b,q=d.getMessage(),r={};q.next();)switch(q.tag()){case 1:var t=g,A=q.getMessage(),B=t.createFeatureResult();B.geometryType=0>=t.geometryTypes.length?null:t.geometryTypes[0];for(var F=!1;A.next();)switch(A.tag()){case 1:B.objectIdFieldName=A.getString();break;case 3:B.globalIdFieldName=
A.getString();break;case 4:B.geohashFieldName=A.getString();break;case 5:for(var C=A.getMessage(),E={};C.next();)switch(C.tag()){case 1:E.shapeAreaFieldName=C.getString();break;case 2:E.shapeLengthFieldName=C.getString();break;case 3:E.units=C.getString();break;default:C.skip()}B.geometryProperties=E;break;case 7:var G=A.getEnum();B.geometryType=G>=t.geometryTypes.length?null:t.geometryTypes[G];break;case 8:for(var Q=A.getMessage(),V=t.createSpatialReference();Q.next();)switch(Q.tag()){case 1:V.wkid=
Q.getUInt32();break;case 5:V.wkt=Q.getString();break;default:Q.skip()}B.spatialReference=V;break;case 10:B.hasZ=A.getBool();break;case 11:B.hasM=A.getBool();break;case 12:for(var R=A.getMessage(),I={originPosition:0>=p.length?null:p[0]};R.next();)switch(R.tag()){case 1:var W=R.getEnum();I.originPosition=W>=p.length?null:p[W];break;case 2:for(var M=R.getMessage(),E=[0,0,0,0];M.next();)switch(M.tag()){case 1:E[0]=M.getDouble();break;case 2:E[1]=M.getDouble();break;case 4:E[2]=M.getDouble();break;case 3:E[3]=
M.getDouble();break;default:M.skip()}I.scale=E;break;case 3:for(var U=R.getMessage(),E=[0,0,0,0];U.next();)switch(U.tag()){case 1:E[0]=U.getDouble();break;case 2:E[1]=U.getDouble();break;case 4:E[2]=U.getDouble();break;case 3:E[3]=U.getDouble();break;default:U.skip()}I.translate=E;break;default:R.skip()}B.transform=I;break;case 9:var O=A.getBool();B.exceededTransferLimit=O;break;case 13:t.addField(B,c(A.getMessage()));break;case 15:F||(t.prepareFeatures(B),F=!0);t.addFeature(B,f(t,B,A.getMessage(),
B.fields));break;default:A.skip()}t.finishFeatureResult(B);r.featureResult=B;break;default:q.skip()}e.queryResult=r;break;default:d.skip()}return a}catch(J){return d=new m("query:parsing-pbf","Error while parsing FeatureSet PBF payload",{error:J}),n.error(d),{queryResult:{featureResult:b.createFeatureResult()}}}}})},"esri/core/pbf":function(){define(["require","exports"],function(b,e){return function(){function b(b,e,l,h){this._tag=0;this._dataType=99;this._data=b;this._dataView=e;this._pos=l||0;
this._end=h||b.byteLength}b.prototype.clone=function(){return new b(this._data,this._dataView,this._pos,this._end)};b.prototype.pos=function(){return this._pos};b.prototype.next=function(b){for(;;){if(this._pos===this._end)return!1;var d=this._decodeVarint();this._tag=d>>3;this._dataType=d&7;if(!b||b===this._tag)break;this.skip()}return!0};b.prototype.empty=function(){return this._pos>=this._end};b.prototype.tag=function(){return this._tag};b.prototype.getInt32=function(){return this._decodeVarint()};
b.prototype.getInt64=function(){return this._decodeVarint()};b.prototype.getUInt32=function(){var b=4294967295,b=(this._data[this._pos]&127)>>>0;if(128>this._data[this._pos++])return b;b=(b|(this._data[this._pos]&127)<<7)>>>0;if(128>this._data[this._pos++])return b;b=(b|(this._data[this._pos]&127)<<14)>>>0;if(128>this._data[this._pos++])return b;b=(b|(this._data[this._pos]&127)<<21)>>>0;if(128>this._data[this._pos++])return b;b=(b|(this._data[this._pos]&15)<<28)>>>0;if(128>this._data[this._pos++])return b};
b.prototype.getUInt64=function(){return this._decodeVarint()};b.prototype.getSInt32=function(){var b=this.getUInt32();return b>>>1^-(b&1)|0};b.prototype.getSInt64=function(){return this._decodeSVarint()};b.prototype.getBool=function(){var b=0!==this._data[this._pos];this._skip(1);return b};b.prototype.getEnum=function(){return this._decodeVarint()};b.prototype.getFixed64=function(){var b=this._dataView,e=this._pos,b=b.getUint32(e,!0)+4294967296*b.getUint32(e+4,!0);this._skip(8);return b};b.prototype.getSFixed64=
function(){var b=this._dataView,e=this._pos,b=b.getUint32(e,!0)+4294967296*b.getInt32(e+4,!0);this._skip(8);return b};b.prototype.getDouble=function(){var b=this._dataView.getFloat64(this._pos,!0);this._skip(8);return b};b.prototype.getFixed32=function(){var b=this._dataView.getUint32(this._pos,!0);this._skip(4);return b};b.prototype.getSFixed32=function(){var b=this._dataView.getInt32(this._pos,!0);this._skip(4);return b};b.prototype.getFloat=function(){var b=this._dataView.getFloat32(this._pos,
!0);this._skip(4);return b};b.prototype.getString=function(){var b=this._getLength(),e=this._pos,e=this._toString(this._data,e,e+b);this._skip(b);return e};b.prototype.getBytes=function(){var b=this._getLength(),e=this._pos,e=this._toBytes(this._data,e,e+b);this._skip(b);return e};b.prototype.getMessage=function(){var d=this._getLength(),e=this._pos,e=new b(this._data,this._dataView,e,e+d);this._skip(d);return e};b.prototype.skip=function(){switch(this._dataType){case 0:this._decodeVarint();break;
case 1:this._skip(8);break;case 2:this._skip(this._getLength());break;case 5:this._skip(4);break;default:throw Error("Invalid data type!");}};b.prototype._skip=function(b){if(this._pos+b>this._end)throw Error("Attempt to skip past the end of buffer!");this._pos+=b};b.prototype._decodeVarint=function(){var b=this._data,e=this._pos,l=0,h;if(10<=this._end-e){if(h=b[e++],l|=h&127,0!==(h&128)&&(h=b[e++],l|=(h&127)<<7,0!==(h&128)&&(h=b[e++],l|=(h&127)<<14,0!==(h&128)&&(h=b[e++],l|=(h&127)<<21,0!==(h&128)&&
(h=b[e++],l+=268435456*(h&127),0!==(h&128)&&(h=b[e++],l+=34359738368*(h&127),0!==(h&128)&&(h=b[e++],l+=4398046511104*(h&127),0!==(h&128)&&(h=b[e++],l+=562949953421312*(h&127),0!==(h&128)&&(h=b[e++],l+=72057594037927936*(h&127),0!==(h&128)&&(h=b[e++],l+=0x7fffffffffffffff*(h&127),0!==(h&128)))))))))))throw Error("Varint too long!");}else{for(var a=1;e!==this._end;){h=b[e];if(0===(h&128))break;++e;l+=(h&127)*a;a*=128}if(e===this._end)throw Error("Varint overrun!");++e;l+=h*a}this._pos=e;return l};b.prototype._decodeSVarint=
function(){var b=this._decodeVarint();return b%2?-(b+1)/2:b/2};b.prototype._getLength=function(){if(2!==this._dataType)throw Error("Not a delimited data type!");return this._decodeVarint()};b.prototype._toString=function(b,e,l){var d="",a="";for(l=Math.min(this._end,l);e<l;++e){var c=b[e];c&128?a+="%"+c.toString(16):(d+=decodeURIComponent(a)+String.fromCharCode(c),a="")}a.length&&(d+=decodeURIComponent(a));return d};b.prototype._toBytes=function(b,e,l){l=Math.min(this._end,l);return new Uint8Array(b.buffer,
e,l-e)};return b}()})},"esri/tasks/operations/pbfDehydratedFeatureSet":function(){define("require exports ../../Graphic ../../core/compilerUtils ../../geometry/SpatialReference ../../layers/support/Field".split(" "),function(b,e,m,d,k,l){function h(a,c,b,d){return c}function a(a,c,b,d){switch(b){case 0:return g(a,c+d,0);case 1:return a.translate[1]-(c+d)*a.scale[1]}}function c(a,c,b,d){switch(b){case 0:return g(a,c+d,0);case 1:return a.translate[1]-(c+d)*a.scale[1];case 2:return g(a,c,2)}}function f(a,
c,b,d){switch(b){case 0:return g(a,c+d,0);case 1:return a.translate[1]-(c+d)*a.scale[1];case 2:return g(a,c,3)}}function n(a,c,b,d){switch(b){case 0:return g(a,c+d,0);case 1:return a.translate[1]-(c+d)*a.scale[1];case 2:return g(a,c,3);case 3:return g(a,c,3)}}function g(a,c,b){return a.translate[b]+c*a.scale[b]}Object.defineProperty(e,"__esModule",{value:!0});b=function(){function b(a){this.options=a;this.geometryTypes=["point","multipoint","polyline","polygon"];this.previousCoordinate=[0,0];this.transform=
null;this.applyTransform=h;this.lengths=[];this.vertexDimension=this.toAddInCurrentPath=this.currentLengthIndex=0;this.coordinateBuffer=null;this.coordinateBufferPtr=0}b.prototype.createFeatureResult=function(){return{exceededTransferLimit:!1,features:[],fields:[],hasM:!1,hasZ:!1,geometryType:null,objectIdFieldName:null,globalIdFieldName:null,geometryProperties:null,geohashFieldName:null,spatialReference:null,transform:null}};b.prototype.finishFeatureResult=function(a){this.options.applyTransform&&
(a.transform=null)};b.prototype.createSpatialReference=function(){return new k};b.prototype.addField=function(a,c){a.fields.push(l.fromJSON(c))};b.prototype.addFeature=function(a,c){var b=this.options.maxStringAttributeLength?this.options.maxStringAttributeLength:0;if(0<b)for(var d in c.attributes){var e=c.attributes[d];"string"===typeof e&&e.length>b&&delete c.attributes[d]}a.features.push(c)};b.prototype.prepareFeatures=function(a){this.options.applyTransform&&a.transform&&(this.transform=a.transform,
this.applyTransform=this.deriveApplyTransform(a));this.vertexDimension=2;a.hasZ&&this.vertexDimension++;a.hasM&&this.vertexDimension++;switch(a.geometryType){case "point":this.addCoordinate=this.addCoordinatePoint.bind(this);this.createGeometry=this.createPointGeometry.bind(this);break;case "polygon":this.addCoordinate=this.addCoordinatePolygon.bind(this);this.createGeometry=this.createPolygonGeometry.bind(this);break;case "polyline":this.addCoordinate=this.addCoordinatePolyline.bind(this);this.createGeometry=
this.createPolylineGeometry.bind(this);break;case "multipoint":this.addCoordinate=this.addCoordinateMultipoint.bind(this);this.createGeometry=this.createMultipointGeometry.bind(this);break;default:d.neverReached(a.geometryType)}};b.prototype.createFeature=function(a){this.currentLengthIndex=this.lengths.length=0;this.previousCoordinate[0]=0;this.previousCoordinate[1]=0;this.coordinateBuffer=null;this.coordinateBufferPtr=0;return{uid:m.generateUID(),objectId:null,attributes:{},geometry:null,visible:!0}};
b.prototype.addLength=function(a,c,b){0===this.lengths.length&&(this.toAddInCurrentPath=c);this.lengths.push(c)};b.prototype.createPointGeometry=function(a){a={type:"point",x:0,y:0,spatialReference:a.spatialReference,hasZ:!!a.hasZ,hasM:!!a.hasM};a.hasZ&&(a.z=0);a.hasM&&(a.m=0);return a};b.prototype.addCoordinatePoint=function(a,c,b,d){c=this.applyTransform(this.transform,c,d,0);switch(d){case 0:a.x=c;break;case 1:a.y=c;break;case 2:a.hasZ?a.z=c:a.m=c;break;case 3:a.m=c}};b.prototype.transformPathLikeValue=
function(a,c){var b=0;1>=c&&(b=this.previousCoordinate[c],this.previousCoordinate[c]+=a);return this.applyTransform(this.transform,a,c,b)};b.prototype.addCoordinatePolyline=function(a,c,b,d){this.dehydratedAddPointsCoordinate(a.paths,c,b,d)};b.prototype.addCoordinatePolygon=function(a,c,b,d){this.dehydratedAddPointsCoordinate(a.rings,c,b,d)};b.prototype.addCoordinateMultipoint=function(a,c,b){0===b&&a.points.push([]);c=this.transformPathLikeValue(c,b);a.points[a.points.length-1].push(c)};b.prototype.createPolygonGeometry=
function(a){return{type:"polygon",rings:[[]],spatialReference:a.spatialReference,hasZ:!!a.hasZ,hasM:!!a.hasM}};b.prototype.createPolylineGeometry=function(a){return{type:"polyline",paths:[[]],spatialReference:a.spatialReference,hasZ:!!a.hasZ,hasM:!!a.hasM}};b.prototype.createMultipointGeometry=function(a){return{type:"multipoint",points:[],spatialReference:a.spatialReference,hasZ:!!a.hasZ,hasM:!!a.hasM}};b.prototype.dehydratedAddPointsCoordinate=function(a,c,b,d){null===this.coordinateBuffer&&(b=
this.lengths.reduce(function(a,c){return a+c},0),this.coordinateBuffer=new Float64Array(b*this.vertexDimension));0===d&&0===this.toAddInCurrentPath--&&(a.push([]),this.toAddInCurrentPath=this.lengths[++this.currentLengthIndex]-1,this.previousCoordinate[0]=0,this.previousCoordinate[1]=0);c=this.transformPathLikeValue(c,d);a=a[a.length-1];0===d&&a.push(new Float64Array(this.coordinateBuffer.buffer,this.coordinateBufferPtr*Float64Array.BYTES_PER_ELEMENT,this.vertexDimension));this.coordinateBuffer[this.coordinateBufferPtr++]=
c};b.prototype.deriveApplyTransform=function(b){var d=b.hasZ;b=b.hasM;return d&&b?n:d?c:b?f:a};return b}();e.Context=b})},"esri/tasks/operations/pbfOptimizedFeatureSet":function(){define(["require","exports","../../layers/graphics/OptimizedFeature","../../layers/graphics/OptimizedFeatureSet","../../layers/graphics/OptimizedGeometry"],function(b,e,m,d,k){Object.defineProperty(e,"__esModule",{value:!0});b=function(){function b(b){this.geometryTypes=["esriGeometryPoint","esriGeometryMultipoint","esriGeometryPolyline",
"esriGeometryPolygon"]}b.prototype.createFeatureResult=function(){return new d.default};b.prototype.prepareFeatures=function(){};b.prototype.finishFeatureResult=function(){};b.prototype.addFeature=function(b,a){b.features.push(a)};b.prototype.createFeature=function(){return new m.default};b.prototype.createSpatialReference=function(){return{wkid:0}};b.prototype.createGeometry=function(){return new k.default};b.prototype.addField=function(b,a){b.fields.push(a)};b.prototype.addCoordinate=function(b,
a){b.coords.push(a)};b.prototype.addCoordinatePoint=function(b,a){b.coords.push(a)};b.prototype.addLength=function(b,a){b.lengths.push(a)};b.prototype.createPointGeometry=function(){return new k.default};return b}();e.Context=b})},"esri/tasks/operations/PBFWorker":function(){define("require exports ../../core/tsSupport/extendsHelper ../../Graphic ../../core/promiseUtils ../../core/requireUtils ../../core/workers ../../geometry/SpatialReference ./pbfQueryUtils module".split(" "),function(b,e,m,d,k,
l,h,a,c,f){Object.defineProperty(e,"__esModule",{value:!0});var n=function(){function a(){}a.prototype._parseFeatureQuery=function(a){var b=c.parsePBFFeatureQuery(a.buffer,a.options),d;a.options&&"dehydrated"===a.options.type&&(d=b.spatialReference.toJSON(),b.spatialReference=null);return k.resolve({featureSet:b,sr:d})};return a}(),g=function(e){function g(){var a=e.call(this)||this;a._thread=void 0;h.open(l.getAbsMid("./PBFWorker",b,f),{strategy:"dedicated"}).then(function(c){void 0===a._thread?
a._thread=c:c.close()});return a}m(g,e);g.prototype.destroy=function(){this._thread&&this._thread.close();this._thread=null};g.prototype.parseFeatureQuery=function(b,e){return b&&0!==b.byteLength?this._thread?this._thread.invoke("_parseFeatureQuery",{buffer:b,options:e},{transferList:[b]}).then(function(c){var b=c.featureSet;if(c.sr){var e=a.fromJSON(c.sr);b.spatialReference=e}for(var e=b.spatialReference,f=0,b=b.features;f<b.length;f++){var g=b[f];g.uid=d.generateUID();g.geometry&&(g.geometry.spatialReference=
e)}return c.featureSet}):k.resolve(c.parsePBFFeatureQuery(b,e)):k.resolve(null)};return g}(n);e.PBFWorker=g;e.default=function(){return new n}})},"esri/tasks/operations/urlUtils":function(){define(["require","exports"],function(b,e){function m(b){var d={},e;for(e in b)if("declaredClass"!==e){var h=b[e];if(null!=h&&"function"!==typeof h)if(Array.isArray(h)){d[e]=[];for(var a=0;a<h.length;a++)d[e][a]=m(h[a])}else"object"===typeof h?h.toJSON&&(d[e]=JSON.stringify(h)):d[e]=h}return d}Object.defineProperty(e,
"__esModule",{value:!0});e.mapParameters=m})},"esri/tasks/operations/queryAttachments":function(){define("require exports ../../core/tsSupport/assignHelper ../../request ../../core/urlUtils ../../layers/support/AttachmentInfo ./urlUtils".split(" "),function(b,e,m,d,k,l,h){function a(a){a=a.toJSON();a.attachmentTypes&&(a.attachmentTypes=a.attachmentTypes.join(","));a.globalIds&&(a.globalIds=a.globalIds.join(","));a.objectIds&&(a.objectIds=a.objectIds.join(","));a.size&&(a.size=a.size.join(","));return a}
Object.defineProperty(e,"__esModule",{value:!0});e.processAttachmentQueryResult=function(a,b){for(var c={},d=0;d<a.length;d++)for(var e=a[d],f=e.parentObjectId,h=0,e=e.attachmentInfos;h<e.length;h++){var m=e[h],v=k.addProxy(k.addTokenParameter(b+"/"+f+"/attachments/"+m.id)),m=l.fromJSON(m);m.set({url:v,parentObjectId:f});c[f]?c[f].push(m):c[f]=[m]}return c};e.executeAttachmentQuery=function(c,b,e){b={query:h.mapParameters(m({},c.query,{f:"json"},a(b)))};e&&(b=m({},e,b));return d(c.path+"/queryAttachments",
b)}})},"esri/tasks/operations/queryRelatedRecords":function(){define(["require","exports","../../core/tsSupport/assignHelper","../../request","./urlUtils"],function(b,e,m,d,k){function l(b){b=b.toJSON();b.objectIds&&(b.objectIds=b.objectIds.join(","));b.outFields&&(b.outFields=b.outFields.join(","));b.outSpatialReference&&(b.outSR=b.outSR.wkid||JSON.stringify(b.outSR.toJSON()),delete b.outSpatialReference);b.source&&(b.layer=JSON.stringify({source:b.source}),delete b.source);return b}Object.defineProperty(e,
"__esModule",{value:!0});e.toQueryStringParameters=l;e.executeRelationshipQuery=function(b,a,c){a={query:k.mapParameters(m({},b.query,{f:"json"},l(a)))};c&&(a=m({},c,a));return d(b.path+"/queryRelatedRecords",a).then(function(a){for(var b=a.data,c=b.geometryType,d=b.spatialReference,e={},f=0,b=b.relatedRecordGroups;f<b.length;f++){var h=b[f],k={fields:void 0,objectIdFieldName:void 0,geometryType:c,spatialReference:d,features:h.relatedRecords};if(null!=h.objectId)e[h.objectId]=k;else for(var l in h)h.hasOwnProperty(l)&&
"relatedRecords"!==l&&(e[h[l]]=k)}a.data=e;return a})}})},"esri/views/View":function(){define("require exports ../core/tsSupport/decorateHelper ../core/tsSupport/declareExtendsHelper ../core/tsSupport/assignHelper ../Map ../core/Accessor ../core/Collection ../core/CollectionFlattener ../core/Evented ../core/Handles ../core/Logger ../core/maybe ../core/Promise ../core/promiseUtils ../core/scheduling ../core/watchUtils ../core/accessorSupport/decorators ../geometry/Extent ../geometry/HeightModelInfo ../geometry/SpatialReference ../geometry/support/spatialReferenceUtils ../support/GraphicsCollection ./BasemapView ./LayerViewManager ./RefreshManager ./ToolViewManager ./input/Input ./navigation/Navigation ./support/DefaultsFromMap".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u,z,y,x,w,A,B,F,C,E,G,Q,V){var R=g.getLogger("esri.views.View");return function(b){function e(d){var e=b.call(this)||this;e._viewHandles=new n;e._isValid=!1;e._readyCycleForced=!1;e._userSpatialReference=null;e._currentSpatialReference=null;e._cursor=null;e.allLayerViews=new c({root:e,rootCollectionNames:["basemapView.baseLayerViews","groundView?.layerViews","layerViews","basemapView.referenceLayerViews"],getChildrenFunction:function(a){return a.layerViews}});
e.animation=null;e.basemapView=null;e.defaultsFromMap=new V({view:e});e.extent=null;e.graphicsView=null;e.graphics=new A.default;e.interacting=!1;e.layerViews=new a;e.padding={left:0,top:0,right:0,bottom:0};e.spatialReferenceWarningDelay=1E3;e.type=null;e.scale=null;e.updating=!1;e.initialExtentRequired=!0;e.renderContext=null;e.input=new G;e.navigation=new Q;e.layerViewManager=null;e.refreshManager=null;e.isHeightModelInfoRequired=!1;e.width=null;e.height=null;e.resizing=!1;e.suspended=!1;e._viewHandles.add(e.watch("ready",
function(a,b){a?(e._currentSpatialReference=e.spatialReference,f.views.add(e)):(e._currentSpatialReference=null,f.views.remove(e));e.notifyChange("spatialReference");!a&&b?(e.layerViewManager.clear(),e.toolViewManager.detach()):a&&!b&&e.whenReady().then(function(){return e.toolViewManager.attach()})}));return e}d(e,b);f=e;e.prototype.initialize=function(){var a=this,b=this.validate().then(function(){a._isValid=!0;a.notifyChange("ready");var b=function(){return v.whenOnce(a,"ready").then(function(){return t.after(0)}).then(function(){if(!a.ready)return b()})};
return b()});this.addResolvingPromise(b);this.basemapView=new B({view:this});this.layerViewManager=new F({view:this});this.refreshManager=new C({view:this});this.toolViewManager=new E({view:this});this._resetInitialViewPropertiesFromContent();var c;v.init(this.defaultsFromMap,"isSpatialReferenceDone",function(b){var d=!!(a.map&&0<a.map.allLayers.length);b&&!a.spatialReference&&d||!c?b&&!a.spatialReference&&d&&!c&&(c=t.after(a.spatialReferenceWarningDelay),c.then(function(){R.warn("#spatialReference",
"no spatial reference could be derived from the currently added map layers")}).catch(function(){})):(c.cancel(),c=null)},!0)};e.prototype.destroy=function(){this.destroyed||(f.views.remove(this),this.destroyViewData(),this.defaultsFromMap.destroy(),this.defaultsFromMap=null,this.navigation&&(this.navigation.destroy(),this._set("navigation",null)),this.map=null,this.graphics.destroy())};e.prototype.destroyViewData=function(){null!=this.toolViewManager&&(this._viewHandles.destroy(),this.toolViewManager.destroy(),
this.toolViewManager=null,this.refreshManager.destroy(),this.refreshManager=null,this.layerViewManager.destroy(),this.layerViewManager=null,this.basemapView.destroy(),this.basemapView=null)};e.prototype.whenReady=function(){return t.resolve()};Object.defineProperty(e.prototype,"heightModelInfo",{get:function(){return this.getDefaultHeightModelInfo()},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"map",{set:function(a){var b=this._get("map");a!==b&&(a&&a.load&&a.load(),this.initialized&&
(this.forceReadyCycle(),this._resetInitialViewPropertiesFromContent()),this._set("map",a))},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"ready",{get:function(){var a;if(a=this._isValid&&!this._readyCycleForced&&this.map&&0!==this.width&&0!==this.height&&this.spatialReference)a=this.map,a=!(a&&a.load)||this.map.loaded;return!!(a&&(this._currentSpatialReference||!this.initialExtentRequired||this.initialExtent||this.defaultsFromMap&&this.defaultsFromMap.isSpatialReferenceDone)&&
this.defaultsFromMap&&this.defaultsFromMap.isTileInfoDone&&this.isSpatialReferenceSupported(this.spatialReference))},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"spatialReference",{get:function(){var a=this._userSpatialReference||this._currentSpatialReference||this.getDefaultSpatialReference()||null;a&&this.isHeightModelInfoRequired&&this.defaultsFromMap&&(a=a.clone(),a.vcsWkid=this.defaultsFromMap.vcsWkid,a.latestVcsWkid=this.defaultsFromMap.latestVcsWkid);return a},set:function(a){this._userSpatialReference=
a;this._set("spatialReference",a)},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"stationary",{get:function(){return!this.animation&&!this.interacting&&!this.resizing},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"initialExtent",{get:function(){return this.defaultsFromMap&&this.defaultsFromMap.extent},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"cursor",{get:function(){var a=this.toolViewManager?this.toolViewManager.cursor:null;return q.isSome(a)?
a:this._cursor||"default"},set:function(a){this._cursor=a;this.notifyChange("cursor")},enumerable:!0,configurable:!0});Object.defineProperty(e.prototype,"size",{get:function(){return[this.width,this.height]},enumerable:!0,configurable:!0});e.prototype.whenLayerView=function(a){return this.layerViewManager.whenLayerView(a)};e.prototype.getDefaultSpatialReference=function(){return this.get("defaultsFromMap.spatialReference")};e.prototype.getDefaultHeightModelInfo=function(){return this.get("map.supportsHeightModelInfo")&&
this.get("map.heightModelInfo")||this.get("defaultsFromMap.heightModelInfo")||null};e.prototype.validate=function(){return t.resolve()};e.prototype.isSpatialReferenceSupported=function(a,b,c){return!0};e.prototype.isTileInfoRequired=function(){return!1};e.prototype.when=function(a,b){this.isResolved()&&!this.ready&&R.warn("#when()",'Calling view.when() while the view is no longer ready but was already resolved once will resolve immediately. Use watchUtils.whenOnce(view, "ready").then(...) instead.');
return this.inherited(arguments)};e.prototype.forceReadyCycle=function(){var a=this;this.ready&&(this._readyCycleForced=!0,v.whenFalseOnce(this,"ready",function(){a._readyCycleForced=!1;a.notifyChange("ready")}),this.notifyChange("ready"))};e.prototype.createTool=function(a,b,c){return this.toolViewManager.createTool(a,b,c)};e.prototype.removeTool=function(a){this.toolViewManager&&this.toolViewManager.removeTool(a)};e.prototype._resetInitialViewPropertiesFromContent=function(){var a=this;if(this.defaultsFromMap){var b=
function(){a.defaultsFromMap.start()};this.defaultsFromMap.reset();this._currentSpatialReference=null;this.notifyChange("spatialReference");this._viewHandles.remove("defaultsFromMap");this._viewHandles.add([v.watch(this,"spatialReference",function(a,c){w.equals(a,c)||b()}),v.watch(this,"initialExtentRequired",b),r.schedule(b)],"defaultsFromMap")}};var f;e.views=new a;m([u.aliasOf("toolViewManager.activeTool")],e.prototype,"activeTool",void 0);m([u.property({readOnly:!0})],e.prototype,"allLayerViews",
void 0);m([u.property()],e.prototype,"animation",void 0);m([u.property()],e.prototype,"basemapView",void 0);m([u.property()],e.prototype,"defaultsFromMap",void 0);m([u.property({type:z})],e.prototype,"extent",void 0);m([u.property({readOnly:!0})],e.prototype,"graphicsView",void 0);m([u.property(A.graphicsCollectionProperty)],e.prototype,"graphics",void 0);m([u.property({readOnly:!0,type:y,dependsOn:["map.heightModelInfo?","defaultsFromMap.heightModelInfo"]})],e.prototype,"heightModelInfo",null);m([u.property()],
e.prototype,"interacting",void 0);m([u.property({type:a,readOnly:!0})],e.prototype,"layerViews",void 0);m([u.property({value:null,type:l})],e.prototype,"map",null);m([u.property()],e.prototype,"padding",void 0);m([u.property({readOnly:!0,dependsOn:"map spatialReference width height initialExtentRequired initialExtent defaultsFromMap.isSpatialReferenceDone defaultsFromMap.isTileInfoDone map.loaded?".split(" ")})],e.prototype,"ready",null);m([u.property({type:x,dependsOn:["defaultsFromMap.spatialReference",
"defaultsFromMap.vcsWkid","defaultsFromMap.latestVcsWkid"]})],e.prototype,"spatialReference",null);m([u.property()],e.prototype,"spatialReferenceWarningDelay",void 0);m([u.property({dependsOn:["animation","interacting","resizing"]})],e.prototype,"stationary",null);m([u.aliasOf("toolViewManager.tools")],e.prototype,"tools",void 0);m([u.property()],e.prototype,"toolViewManager",void 0);m([u.property({readOnly:!0})],e.prototype,"type",void 0);m([u.property({type:Number})],e.prototype,"scale",void 0);
m([u.property({readOnly:!0})],e.prototype,"updating",void 0);m([u.property({readOnly:!0})],e.prototype,"initialExtentRequired",void 0);m([u.property({readOnly:!0,type:z,dependsOn:["defaultsFromMap.extent"]})],e.prototype,"initialExtent",null);m([u.property({dependsOn:["toolViewManager.cursor"]})],e.prototype,"cursor",null);m([u.property()],e.prototype,"renderContext",void 0);m([u.property({readOnly:!0})],e.prototype,"input",void 0);m([u.property({readOnly:!0})],e.prototype,"navigation",void 0);m([u.property()],
e.prototype,"width",void 0);m([u.property()],e.prototype,"height",void 0);m([u.property({readOnly:!0})],e.prototype,"resizing",void 0);m([u.property({value:null,dependsOn:["width","height"],readOnly:!0})],e.prototype,"size",null);m([u.property({readOnly:!0})],e.prototype,"suspended",void 0);return e=f=m([u.subclass("esri.views.View")],e)}(u.declared(h,p,f))})},"esri/core/watchUtils":function(){define(["require","exports","./promiseUtils"],function(b,e,m){function d(a,b,c,d,e){e=a.watch(b,function(b,
e,f,g){c&&!c(b)||d.call(a,b,e,f,g)},e);if(Array.isArray(b))for(var f=0;f<b.length;f++){var g=a.get(b[f]);c&&c(g)&&d.call(a,g,g,b,a)}else g=a.get(b),c&&c(g)&&d.call(a,g,g,b,a);return e}function k(a,b,c,e,f){function g(){k&&(k.remove(),k=null)}var h=!1,k,l=m.createDeferred(g),p={cancel:l.cancel,then:l.promise.then,catch:l.promise.catch,isCanceled:l.promise.isCanceled,isFulfilled:l.promise.isFulfilled,isRejected:l.promise.isRejected,isResolved:l.promise.isResolved,remove:g};Object.freeze(p);k=d(a,b,
c,function(b,c,d,f){h=!0;g();e&&e.call(a,b,c,d,f);l.resolve({value:b,oldValue:c,propertyName:d,target:f})},f);h&&g();return p}function l(a){return!!a}function h(a){return!a}function a(a){return!0===a}function c(a){return!1===a}function f(a){return void 0!==a}function n(a){return void 0===a}function g(a,b,c,d){var e=Array.isArray(b)?b:-1<b.indexOf(",")?b.split(","):[b];b=a.watch(b,c,d);for(d=0;d<e.length;d++){var f=e[d].trim().replace(q,"$1"),g=a.get(f);c.call(a,g,g,f,a)}return b}Object.defineProperty(e,
"__esModule",{value:!0});e.whenValidOnce=k;var q=/\?(\.|$)/g;e.init=g;e.watch=function(a,b,c,d){return a.watch(b,c,d)};e.once=function(a,b,c,d){return k(a,b,null,c,d)};e.when=function(a,b,c,e){return d(a,b,l,c,e)};e.whenOnce=function(a,b,c,d){return k(a,b,l,c,d)};e.whenNot=function(a,b,c,e){return d(a,b,h,c,e)};e.whenNotOnce=function(a,b,c,d){return k(a,b,h,c,d)};e.whenTrue=function(b,c,e,f){return d(b,c,a,e,f)};e.whenTrueOnce=function(b,c,d,e){return k(b,c,a,d,e)};e.whenFalse=function(a,b,e,f){return d(a,
b,c,e,f)};e.whenFalseOnce=function(a,b,d,e){return k(a,b,c,d,e)};e.whenDefined=function(a,b,c,e){return d(a,b,f,c,e)};e.whenDefinedOnce=function(a,b,c,d){return k(a,b,f,c,d)};e.whenUndefined=function(a,b,c,e){return d(a,b,n,c,e)};e.whenUndefinedOnce=function(a,b,c,d){return k(a,b,n,c,d)};e.pausable=function(a,b,c,d){var e=!1,f=a.watch(b,function(b,d,f,g){e||c.call(a,b,d,f,g)},d);return{remove:function(){f.remove()},pause:function(){e=!0},resume:function(){e=!1}}};e.on=function(a,b,c,d,e,f,h){function k(b){var d=
l[b];d&&(f&&f(d.target,b,a,c),d.handle.remove(),delete l[b])}var l={},n=g(a,b,function(b,f,g){k(g);b&&"function"===typeof b.on&&(l[g]={handle:b.on(c,d),target:b},e&&e(b,g,a,c))},h);return{remove:function(){n.remove();for(var a in l)k(a)}}}})},"esri/support/GraphicsCollection":function(){define("require exports ../core/tsSupport/decorateHelper ../core/tsSupport/declareExtendsHelper ../Graphic ../core/Collection ../core/collectionUtils ../core/accessorSupport/decorators ../core/accessorSupport/ensureType ../core/accessorSupport/typescript".split(" "),
function(b,e,m,d,k,l,h,a,c,f){Object.defineProperty(e,"__esModule",{value:!0});var n=l.ofType(k),g=function(b){function c(a){var c=b.call(this,a)||this;c.on("before-add",function(a){a.item||a.preventDefault()});c.on("after-add",function(a){return c._own(a.item)});c.on("after-remove",function(a){a.item.layer=null});return c}d(c,b);c.prototype.destroy=function(){this._unownAll()};Object.defineProperty(c.prototype,"owner",{get:function(){return this._get("owner")},set:function(a){a!==this._get("owner")&&
(this._unownAll(),this._set("owner",a),this._ownAll())},enumerable:!0,configurable:!0});c.prototype._createNewInstance=function(a){return new n(a)};c.prototype._ownAll=function(){var a=this;this.items.forEach(function(b){return a._own(b)})};c.prototype._own=function(a){a.layer&&"group"!==a.layer.type&&"remove"in a.layer&&a.layer!==this.owner&&a.layer.remove(a);a.layer=this.owner};c.prototype._unownAll=function(){var a=this;this.items.forEach(function(b){return a._unown(b)})};c.prototype._unown=function(a){a.layer===
this.owner&&(a.layer=null)};m([f.property()],c.prototype,"owner",null);return c=m([a.subclass("esri.support.GraphicsCollection")],c)}(a.declared(n));e.GraphicsCollection=g;e.castGraphicsCollection=function(a){if(a=c.default(g,a))a.owner=this;return a};e.graphicsCollectionProperty={type:g,cast:h.castForReferenceSetter,set:function(a){a=h.referenceSetter(a,this._get("graphics"),g);a.owner=this;this._set("graphics",a)}};e.default=g})},"esri/views/BasemapView":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Accessor ../core/Collection ../core/watchUtils ../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a){return function(b){function c(a){a=b.call(this)||this;a.view=null;a.baseLayerViews=new l;a.referenceLayerViews=new l;a._loadingHdl=h.init(a,"view.map.basemap",function(a){a&&a.load()});return a}m(c,b);c.prototype.destroy=function(){this._set("view",null);this._loadingHdl&&(this._loadingHdl.remove(),this._loadingHdl=null)};Object.defineProperty(c.prototype,"suspented",{get:function(){return this.view?this.view.suspended:!0},enumerable:!0,configurable:!0});d([a.property({constructOnly:!0})],
c.prototype,"view",void 0);d([a.property({readOnly:!0})],c.prototype,"baseLayerViews",void 0);d([a.property({readOnly:!0})],c.prototype,"referenceLayerViews",void 0);d([a.property({dependsOn:["view.suspended"]})],c.prototype,"suspented",null);return c=d([a.subclass("esri.views.BasemapView")],c)}(a.declared(k))})},"esri/views/LayerViewManager":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Accessor ../core/Error ../core/Handles ../core/promiseUtils ../core/scheduling ../core/watchUtils ../core/accessorSupport/decorators ./LayerViewFactory".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g){return function(b){function e(a){var c=b.call(this)||this;c._promisesMap=new Map;c._layerViewsMap=new Map;c._handles=new h;c.factory=new g;c.ready=!1;c.layersToLayerViews=function(){var a=new Map;a.set("view.map.basemap.baseLayers","view.basemapView.baseLayerViews");a.set("view.map.ground.layers","view.groundView.layerViews");a.set("view.map.layers","view.layerViews");a.set("view.map.basemap.referenceLayers","view.basemapView.referenceLayerViews");return a}();c._doWork=
c._doWork.bind(c);c.refresh=c.refresh.bind(c);c._handles.add(f.init(c,"view.ready",function(a){return c.ready=a}));c._handles.add(c.watch(["view.map.basemap","view.map.ground","view.map.layers","ready"],c.refresh),"watcher");return c}m(e,b);e.prototype.destroy=function(){this._handles&&(this.clear(),this.view=null,this.factory.destroy(),this.factory=null,this._handles.destroy(),this._map=this._layerViewsMap=this._promisesMap=this._handles=null)};e.prototype.clear=function(){var a=this;this.destroyed||
(this._layerViewsMap.forEach(function(b,c){return a._disposeLayerView(b,c)}),this._promisesMap.forEach(function(a){return a.cancel()}),this._layerViewsMap.clear(),this._promisesMap.clear(),this._refreshCollections())};e.prototype.refresh=function(){var a=this._handles;a.remove("refresh");a.add(c.schedule(this._doWork),"refresh")};e.prototype.whenLayerView=function(b){this.refresh();this._doWork();return this._promisesMap.has(b)?this._promisesMap.get(b):a.reject(new l("view:no-layerview-for-layer",
"No layerview has been found for the layer",{layer:b}))};e.prototype._doWork=function(){var a=this,b=this._handles,c=this.get("view.map");this._map!==c&&(this.clear(),this._map=c);if(b.has("refresh")){b.remove("refresh");b.remove("collection-change");this.factory.paused=!this.ready;var d=this._map&&this._map.allLayers;d&&(d.forEach(this._createLayerView,this),this._refreshCollections(),this._promisesMap.forEach(function(b,c){d.includes(c)||a._disposeLayerView(a._layerViewsMap.get(c),c)}),b.add(d.on("change",
this.refresh),"collection-change"))}};e.prototype._refreshCollections=function(){var a=this;this.layersToLayerViews.forEach(function(b,c){a._populateLayerViewsOwners(a.get(c),a.get(b),a.view)})};e.prototype._populateLayerViewsOwners=function(a,b,c){var d=this;if(a&&b){var e=0;a.forEach(function(a){var f=d._layerViewsMap.get(a);f&&(f.layer=a,f.parent=c,b.getItemAt(e)!==f&&b.splice(e,0,f),a.layers&&d._populateLayerViewsOwners(a.layers,f.layerViews,f),e+=1)});e<b.length&&b.splice(e,b.length)}else b&&
b.removeAll()};e.prototype._createLayerView=function(a){var b=this,c=this.view,d=this.factory,e=this._layerViewsMap,f=this._promisesMap;e.has(a)?a.load():f.has(a)||(d=d.create(c,a).then(function(d){if(!b._map||!b._map.allLayers.some(function(b){return a===b}))throw new l("view:no-layerview-for-layer","The layer has been removed from the map",{layer:a});e.set(a,d);b._refreshCollections();a.emit("layerview-create",{view:c,layerView:d});c.emit("layerview-create",{layer:a,layerView:d});return d.when()}),
f.set(a,d),d.then(this.refresh,this.refresh))};e.prototype._disposeLayerView=function(a,b){if(this._promisesMap.has(b)&&(this._promisesMap.get(b).cancel(),this._promisesMap.delete(b),a)){b=a.layer;var c=a.view;this.factory.dispose(a);a.layer=a.parent=a.view=null;this._layerViewsMap.delete(b);b.emit("layerview-destroy",{view:c,layerView:a});c.emit("layerview-destroy",{layer:b,layerView:a})}};d([n.property()],e.prototype,"ready",void 0);d([n.property()],e.prototype,"view",void 0);return e=d([n.subclass("esri.views.LayerViewManager")],
e)}(n.declared(k))})},"esri/views/LayerViewFactory":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper dojo/Deferred ../core/Accessor ../core/Collection ../core/Error ../core/Logger ../core/promiseUtils ../core/watchUtils ../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g){var q=c.getLogger("esri.views.LayerViewFactory");return function(b){function c(){var a=null!==b&&b.apply(this,arguments)||this;a.creationRequests=
new h;a.paused=!0;return a}m(c,b);c.prototype.initialize=function(){var a=this;n.whenFalse(this,"paused",function(){a.creationRequests.toArray().forEach(a._processRequest,a)},!0)};c.prototype.destroy=function(){this.creationRequests.drain(function(a){return a.deferred.cancel(void 0)})};Object.defineProperty(c.prototype,"working",{get:function(){return 0<this.creationRequests.length},enumerable:!0,configurable:!0});c.prototype.create=function(b,c){var d=this.getLayerViewPromise(c);if(d)return d;var e=
this.creationRequests,f={deferred:new k(function(){var b=new a("cancelled:layerview-create","layerview creation cancelled",{layer:c});e.remove(f);f.creationPromise&&f.creationPromise.cancel(b);return b}),view:b,layer:c,started:!1,creationPromise:null};e.push(f);this.paused?c.load():this._processRequest(f);return f.deferred.promise};c.prototype.dispose=function(a){a.layer.destroyLayerView(a)};c.prototype.getLayerViewPromise=function(a){var b=this.creationRequests&&this.creationRequests.find(function(b){return b.layer===
a});return b&&b.deferred.promise};c.prototype._processRequest=function(b){var c=this;if(!b.started){b.started=!0;var d=b.deferred,e=b.layer,g=b.view;e&&"importLayerViewModule"in e&&e.importLayerViewModule(g);e.load().then(function(a){if(!d.isCanceled())return b.creationPromise=a.createLayerView(g),b.creationPromise}).then(function(a){return d.isCanceled()?a:b.creationPromise=f.when(a.when())}).catch(function(b){d.isCanceled()||(q.error("Failed to create view for layer '"+e.title+", id:"+e.id+"' of type '"+
e.type+"'.",{error:b}),d.reject(new a("layerview:create-error","layerview creation failed",{layer:e,error:b})))}).then(function(a){c.creationRequests&&c.creationRequests.remove(b);d.isFulfilled()?a&&c.dispose(a):d.resolve(a);return a})}};d([g.property()],c.prototype,"creationRequests",void 0);d([g.property()],c.prototype,"paused",void 0);d([g.property()],c.prototype,"view",void 0);d([g.property({dependsOn:["paused","creationRequests.length"],readOnly:!0})],c.prototype,"working",null);return c=d([g.subclass("esri.views.LayerViewFactory")],
c)}(g.declared(l))})},"esri/views/RefreshManager":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Accessor ../core/Handles ../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h){return function(a){function b(){var b=null!==a&&a.apply(this,arguments)||this;b._handles=new l;b._currentTick=0;return b}m(b,a);b.prototype.initialize=function(){var a=this;this._handles.add([this.view.allLayerViews.on("after-changes",function(){a.notifyChange("tickInterval");
a._handles.remove("layerViewsUpdating");a._handles.add(a._getLayerViewHandles(),"layerViewsUpdating")}),this.watch("tickInterval",function(){return a._restartTicking()}),this.watch("view.ready",function(){return a._restartTicking()})]);this._restartTicking()};b.prototype.destroy=function(){this._handles&&(this._handles.destroy(),this._handles=null,this._intervalID&&clearInterval(this._intervalID),this._currentTick=0)};Object.defineProperty(b.prototype,"tickInterval",{get:function(){var a=this.view.allLayerViews.filter(function(a){return"refresh"in
a});return this._getCommonInterval(a)},enumerable:!0,configurable:!0});b.prototype._restartTicking=function(){var a=this;this._currentTick=0;this._intervalID&&clearInterval(this._intervalID);this.get("view.ready")&&this.tickInterval&&(this._intervalID=setInterval(function(){var b=Date.now();a._currentTick+=a.tickInterval;a.view.allLayerViews.forEach(function(c){if("refresh"in c){var d=Math.round(6E4*c.refreshInterval),e=0===a._currentTick%d,f=6E3>b-c.refreshTimestamp;d&&e&&!f&&c.refresh(b)}})},this.tickInterval))};
b.prototype._getLayerViewHandles=function(){var a=this,b=[],c=function(){return a.notifyChange("tickInterval")};this.view.allLayerViews.forEach(function(a){"refresh"in a&&a.layer&&b.push(a.watch("refreshInterval",c),a.layer.on("refresh",function(){a.refresh(Date.now())}))});return b};b.prototype._getCommonInterval=function(a){var b=function(a,c){return isNaN(a)||isNaN(c)?0:0>=c?a:b(c,a%c)};return a.toArray().reduce(function(a,c){return b(Math.round(6E4*c.refreshInterval),a)},0)};d([h.property()],
b.prototype,"view",void 0);d([h.property({readOnly:!0})],b.prototype,"tickInterval",null);return b=d([h.subclass("esri.views.RefreshManager")],b)}(h.declared(k))})},"esri/views/ToolViewManager":function(){define("require exports ../core/tsSupport/decorateHelper ../core/tsSupport/declareExtendsHelper ../core/tsSupport/generatorHelper ../core/tsSupport/awaiterHelper ../core/tsSupport/assignHelper ../core/Accessor ../core/Collection ../core/Handles ../core/Logger ../core/maybe ../core/screenUtils ../core/watchUtils ../core/accessorSupport/decorators ./input/ViewEvents ./interactive/interactiveToolUtils ./interactive/ManipulatorCollection".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t,r,v,u){function z(a){return"mouse"!==a.pointerType||0===a.button}function y(a){a=a.native;return!(!a.ctrlKey&&!a.metaKey)}var x=n.getLogger("esri.views.ToolViewManager");return function(b){function e(a){a=b.call(this)||this;a._handles=new f;a._ignorePopupEventId=null;a._ignoreClickEventId=null;a._manipulators=new u;a._stopDrag=!1;a._manipulatorPointerUpEventId=0;a._dragStartScreenPoints=new Map;a._dragPreviousScreenPoints=new Map;a._hoveredManipulators=new Map;
a._grabbedManipulators=new Map;a.tools=v.newToolCollection(a);a.cursor=null;return a}d(e,b);e.prototype.initialize=function(){var a=this,b=this.view;this._handles.add(r.eventTypes.map(function(c){return b.on(c,function(b){a._handleInputEvent(b)})}).concat([this.tools.on("change",function(){a._refreshToolCursorWatchers();a._refreshToolManipulatorWatchers()})]))};e.prototype.destroy=function(){this.tools.forEach(function(a){a.destroy&&a.destroy()});this._manipulators.destroy();this._manipulators=null;
this._handles.destroy();this._handles=null};Object.defineProperty(e.prototype,"activeTool",{set:function(a){var b=this;g.isSome(a)&&!this.view.ready?x.error("#activeTool\x3d","cannot set active tool while view is not ready"):v.swap(this,a,function(a){b._set("activeTool",a);b._setManipulatorActive()})},enumerable:!0,configurable:!0});e.prototype.createTool=function(a,b,c){return l(this,void 0,void 0,function(){var d;return k(this,function(e){switch(e.label){case 0:return[4,this.view.whenReady()];case 1:return e.sent(),
c?[4,this.removeTool(c)]:[3,3];case 2:e.sent(),e.label=3;case 3:return d=new a(h({},b,{view:this.view})),this.tools.add(d),[2,d]}})})};e.prototype.removeTool=function(a){this.tools.remove(a)};e.prototype.attach=function(){var a=this;this.tools.forEach(function(b){b.attach&&b.attach(v.wrapToolViewManager(a,b))})};e.prototype.detach=function(){var a=this;this.tools.forEach(function(b){b.detach&&b.detach();a.removeToolManipulators(b)})};e.prototype.handlesClickEvent=function(a){return g.isSome(this.activeTool)||
a.eventId===this._ignorePopupEventId||g.isSome(this._manipulators.findClosest(q.createScreenPointFromEvent(a),a.pointerType))};e.prototype.addToolManipulator=function(a,b){var c=this;this.tools.includes(a)&&this.view.ready?(this._manipulators.add(a,b,this._manipulatorPointerUpEventId),b.installRenderHandles&&b.installRenderHandles(this._handles,function(a){return c._manipulators.forEach(a)})):x.error("#addToolManipulator()","cannot add manipulator for tool not attached to view")};e.prototype.removeToolManipulator=
function(a,b){var c=this,d=this._manipulators.remove(a,b);this._hoveredManipulators.forEach(function(a,b){d===a.manipulatorId&&c._hoveredManipulators.delete(b)});this._grabbedManipulators.forEach(function(a,b){d===a.manipulatorId&&(c._grabbedManipulators.delete(b),c._dragStartScreenPoints.delete(b),c._dragPreviousScreenPoints.delete(b))});this._setToolCursor()};e.prototype.removeToolManipulators=function(a){var b=this;this._manipulators.removeTool(a);this._hoveredManipulators.forEach(function(c,d){a===
c.tool&&b._hoveredManipulators.delete(d)});this._grabbedManipulators.forEach(function(c,d){a===c.tool&&(b._grabbedManipulators.delete(d),b._dragStartScreenPoints.delete(d),b._dragPreviousScreenPoints.delete(d))});this._setToolCursor()};e.prototype.attemptManipulatorDragTo=function(a,b,c,d){if(this._manipulators.hasOverlappingInTool(a,b,c.screenPoint))return!1;b.attemptDragTo(c,g.isSome(d)?d:{start:c.screenPoint,previous:c.screenPoint});return!0};e.prototype._handleInputEvent=function(a){var b=this.activeTool;
"pointer-up"===a.type&&(this._manipulatorPointerUpEventId=a.eventId);"click"===a.type&&a.eventId===this._ignoreClickEventId||"double-click"===a.type&&a.eventId===this._ignoreClickEventId+2?a.stopPropagation():(g.isSome(this.activeTool)?(this.activeTool.handleInputEvent&&this.activeTool.handleInputEvent(a),"immediate-click"===a.type&&g.isNone(this.activeTool)&&(this._ignoreClickEventId=a.eventId)):this.tools.forEach(function(b){!1!==b.visible&&b.handleInputEvent&&b.handleInputEvent(a)}),this._handleManipulatorEvent(a)&&
(a.stopPropagation(),this._setToolCursor()),g.isSome(b)&&"pointer-up"===a.type&&(this._ignorePopupEventId=a.eventId))};e.prototype._handleManipulatorEvent=function(a){var b=!1;switch(a.type){case "drag":0<this._grabbedManipulators.size&&(this._stopDrag=!0);this._stopDrag&&(a.stopPropagation(),"end"===a.action&&(this._stopDrag=!1));break;case "pointer-down":if(!z(a)||y(a))break;var c=q.createScreenPointFromEvent(a),d=this._manipulators.findClosest(c,a.pointerType);if(g.isNone(d))break;var e=this._manipulators.findByKey(d);
g.isSome(e)&&e.interactive&&(b=!0,this._grabbedManipulators.set(a.pointerId,d),e.grabbing=!0,this._dragStartScreenPoints.set(a.pointerId,c),this._dragPreviousScreenPoints.set(a.pointerId,c),this.activeTool=d.tool);break;case "pointer-up":if(!z(a))break;d=this._manipulators.findByKey(this._grabbedManipulators.get(a.pointerId));g.isSome(d)&&(b=!0,d.grabbing=!1,1===this._grabbedManipulators.size&&(this.activeTool=null));this._grabbedManipulators.delete(a.pointerId);this._dragStartScreenPoints.delete(a.pointerId);
this._dragPreviousScreenPoints.delete(a.pointerId);break;case "pointer-drag":if(!z(a))break;e=this._grabbedManipulators.get(a.pointerId);d=this._manipulators.findByKey(e);if(g.isNone(d))break;c=q.createScreenPointFromEvent(a);c.x=Math.max(0,Math.min(this.view.width,c.x));c.y=Math.max(0,Math.min(this.view.height,c.y));var f={start:this._dragStartScreenPoints.get(a.pointerId),previous:this._dragPreviousScreenPoints.get(a.pointerId)};switch(a.action){case "start":case "update":d.dragging=!0;b=this.attemptManipulatorDragTo(e.tool,
d,{screenPoint:c},f);break;case "end":d.dragging=!1,b=!0}this._dragPreviousScreenPoints.set(a.pointerId,c);break;case "immediate-click":case "pointer-move":if("touch"===a.pointerType)break;c=this._manipulators.findByKey(this._hoveredManipulators.get(a.pointerId));d=this._manipulators.findClosest(q.createScreenPointFromEvent(a),a.pointerType);e=this._manipulators.findByKey(d);if(c===e)break;b=!0;g.isSome(c)&&(c.hovering=!1);g.isSome(d)&&g.isSome(e)&&e.interactive?(e.hovering=!0,this._hoveredManipulators.set(a.pointerId,
d)):this._hoveredManipulators.delete(a.pointerId);break;case "click":c=q.createScreenPointFromEvent(a),d=this._manipulators.findClosest(c,a.pointerType,a.eventId),e=this._manipulators.findByKey(d),y(a)||this._manipulators.forEach(function(a){a.selected=!1}),!g.isNone(e)&&e.interactive&&(e.selectable&&(e.selected=!0),e.click({screenPoint:c,button:a.button}),b=!0)}return b};e.prototype._refreshToolCursorWatchers=function(){var b=this;this._handles.remove("cursors");this._setToolCursor();this.tools.forEach(function(c){c instanceof
a&&(c=p.watch(c,["cursor","visible"],function(){return b._setToolCursor()}),b._handles.add(c,"cursors"))})};e.prototype._setToolCursor=function(){for(var a=null,b=0;b<this.tools.length;b++){var c=this.tools.getItemAt(b);if(null!=c.cursor&&!1!==c.visible){a=c.cursor;break}}!a&&0<this._grabbedManipulators.size&&(a="grabbing");!a&&0<this._hoveredManipulators.size&&(a="pointer");this._set("cursor",a)};e.prototype._refreshToolManipulatorWatchers=function(){var b=this;this._handles.remove("manipulators");
this.tools.forEach(function(c){c instanceof a&&(c=p.watch(c,"visible",function(){return b._setManipulatorActive()},!0),b._handles.add(c,"manipulators"))})};e.prototype._setManipulatorActive=function(){var a=this;this._manipulators.forEach(function(b,c){var d=g.isNone(a.activeTool)||a.activeTool===c;b.active=c.visible&&d})};m([t.property({constructOnly:!0,nonNullable:!0})],e.prototype,"view",void 0);m([t.property({value:null})],e.prototype,"activeTool",null);m([t.property({readOnly:!0,type:c})],e.prototype,
"tools",void 0);m([t.property({readOnly:!0})],e.prototype,"cursor",void 0);return e=m([t.subclass("esri.views.ToolViewManager")],e)}(t.declared(a))})},"esri/views/input/ViewEvents":function(){define("require exports ../../core/tsSupport/extendsHelper ../../core/compilerUtils ../../core/screenUtils ../3d/support/mathUtils ./InputHandler".split(" "),function(b,e,m,d,k,l,h){function a(a){return!!f[a]}function c(b){for(var c=0;c<b.length;c++)if(!a(b[c]))return!1;return!0}Object.defineProperty(e,"__esModule",
{value:!0});e.eventTypes="click double-click immediate-click hold drag key-down key-up pointer-down pointer-move pointer-up pointer-drag mouse-wheel pointer-enter pointer-leave gamepad focus blur".split(" ");var f={};e.eventTypes.forEach(function(a){f[a]=!0});b=function(){function b(a){this.handlers=new Map;this.counter=0;this.handlerCounts=new Map;this.view=a;this.inputManager=null}b.prototype.connect=function(a){var b=this;a&&this.disconnect();this.inputManager=a;this.handlers.forEach(function(a,
c){return b.inputManager.installHandlers(c,[a])})};b.prototype.disconnect=function(){var a=this;this.inputManager&&this.handlers.forEach(function(b,c){return a.inputManager.uninstallHandlers(c)});this.inputManager=null};b.prototype.destroy=function(){this.disconnect();this.handlers.clear();this.view=null};b.prototype.register=function(b,d,e){var f=this,g=Array.isArray(b)?b:b.split(",");if(!c(g))return g.some(a)&&console.error("Error: registering input events and other events on the view at the same time is not supported."),
null;b=Array.isArray(d)?d:[];e=Array.isArray(d)?e:d;var h=this.createUniqueGroupName();d=new n(this.view,g,b,e);this.handlers.set(h,d);for(e=0;e<g.length;e++){b=g[e];var k=this.handlerCounts.get(b)||0;this.handlerCounts.set(b,k+1)}this.inputManager&&this.inputManager.installHandlers(h,[d]);return{remove:function(){return f.removeHandler(h,g)}}};b.prototype.hasHandler=function(a){return!!this.handlerCounts.get(a)};b.prototype.removeHandler=function(a,b){if(this.handlers.has(a)){this.handlers.delete(a);
for(var c=0;c<b.length;c++){var d=b[c],e=this.handlerCounts.get(d);void 0===e?console.error("Trying to remove handler for event that has no handlers registered: ",d):1===e?this.handlerCounts.delete(d):this.handlerCounts.set(d,e-1)}}this.inputManager&&this.inputManager.uninstallHandlers(a)};b.prototype.createUniqueGroupName=function(){this.counter+=1;return"viewEvents_"+this.counter};return b}();e.ViewEvents=b;var n=function(a){function b(b,c,e,f){var g=a.call(this,!0)||this;g.view=b;for(b=0;b<c.length;b++){var h=
c[b];switch(h){case "click":g.registerIncoming("click",e,function(a){return f(g.wrapClick(a))});break;case "double-click":g.registerIncoming("double-click",e,function(a){return f(g.wrapDoubleClick(a))});break;case "immediate-click":g.registerIncoming("immediate-click",e,function(a){return f(g.wrapImmediateClick(a))});break;case "hold":g.registerIncoming("hold",e,function(a){return f(g.wrapHold(a))});break;case "drag":g.registerIncoming("drag",e,function(a){(a=g.wrapDrag(a))&&f(a)});break;case "key-down":g.registerIncoming("key-down",
e,function(a){return f(g.wrapKeyDown(a))});break;case "key-up":g.registerIncoming("key-up",e,function(a){return f(g.wrapKeyUp(a))});break;case "pointer-down":g.registerIncoming("pointer-down",e,function(a){return f(g.wrapPointer(a,"pointer-down"))});break;case "pointer-move":g.registerIncoming("pointer-move",e,function(a){return f(g.wrapPointer(a,"pointer-move"))});break;case "pointer-up":g.registerIncoming("pointer-up",e,function(a){return f(g.wrapPointer(a,"pointer-up"))});break;case "pointer-drag":g.registerIncoming("pointer-drag",
e,function(a){return f(g.wrapPointerDrag(a))});break;case "mouse-wheel":g.registerIncoming("mouse-wheel",e,function(a){return f(g.wrapMouseWheel(a))});break;case "pointer-enter":g.registerIncoming("pointer-enter",e,function(a){return f(g.wrapPointer(a,"pointer-enter"))});break;case "pointer-leave":g.registerIncoming("pointer-leave",e,function(a){return f(g.wrapPointer(a,"pointer-leave"))});break;case "gamepad":g.registerIncoming("gamepad",e,function(a){f(g.wrapGamepad(a))});break;case "focus":g.registerIncoming("focus",
e,function(a){f(g.wrapFocus(a))});break;case "blur":g.registerIncoming("blur",e,function(a){f(g.wrapBlur(a))});break;default:d.neverReached(h)}}return g}m(b,a);b.prototype.wrapFocus=function(a){return{type:"focus",timestamp:a.timestamp,native:a.data.native,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapBlur=function(a){return{type:"blur",timestamp:a.timestamp,native:a.data.native,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapClick=function(a){var b=
a.data,c=b.pointerType,d=b.button,e=b.buttons,f=b.x,g=b.y,h=b.native,b=b.eventId,l=a.timestamp,n=k.createScreenPoint(f,g),p=this.view.toMap(n);return{type:"click",pointerType:c,button:d,buttons:e,x:f,y:g,native:h,timestamp:l,screenPoint:n,mapPoint:p,eventId:b,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapDoubleClick=function(a){var b=a.data,c=b.x,d=b.y,e=b.eventId;return{type:"double-click",pointerType:b.pointerType,button:b.button,buttons:b.buttons,x:c,y:d,native:b.native,
timestamp:a.timestamp,mapPoint:this.view.toMap(k.createScreenPoint(c,d)),eventId:e,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapImmediateClick=function(a){var b=a.data,c=b.x,d=b.y,e=b.native,f=b.eventId;return{type:"immediate-click",pointerId:e.pointerId,pointerType:b.pointerType,button:b.button,buttons:b.buttons,x:c,y:d,native:e,timestamp:a.timestamp,mapPoint:this.view.toMap(k.createScreenPoint(c,d)),eventId:f,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapHold=
function(a){var b=a.data,c=b.x,d=b.y;return{type:"hold",pointerType:b.pointerType,button:b.button,buttons:b.buttons,x:c,y:d,native:b.native,timestamp:a.timestamp,mapPoint:this.view.toMap(k.createScreenPoint(c,d)),stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapDrag=function(a){var b=a.data,c=b.center,d=c.x,c=c.y,e=b.action,f=b.pointerType,g=b.button;"start"===e&&(this.latestDragStart=b);if(this.latestDragStart){var h=b.pointer.native,k=b.buttons,n=a.timestamp,p={x:this.latestDragStart.center.x,
y:this.latestDragStart.center.y};"end"===e&&(this.latestDragStart=void 0);return{type:"drag",action:e,x:d,y:c,origin:p,pointerType:f,button:g,buttons:k,radius:b.radius,angle:l.rad2deg(b.angle),native:h,timestamp:n,stopPropagation:function(){return a.stopPropagation()}}}};b.prototype.wrapKeyDown=function(a){var b=a.data;return{type:"key-down",key:b.key,repeat:b.repeat,native:b.native,timestamp:a.timestamp,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapKeyUp=function(a){var b=
a.data;return{type:"key-up",key:b.key,native:b.native,timestamp:a.timestamp,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapPointer=function(a,b){var c=a.data,d=c.native;return{type:b,x:c.x,y:c.y,pointerId:d.pointerId,pointerType:d.pointerType,button:c.button,buttons:c.buttons,native:d,timestamp:a.timestamp,eventId:c.eventId,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapPointerDrag=function(a){var b=a.data.currentEvent;return{type:"pointer-drag",
x:b.x,y:b.y,pointerId:a.data.startEvent.native.pointerId,pointerType:a.data.startEvent.native.pointerType,button:a.data.startEvent.button,buttons:b.buttons,action:a.data.action,origin:{x:a.data.startEvent.x,y:a.data.startEvent.y},native:b.native,timestamp:a.timestamp,eventId:b.eventId,stopPropagation:function(){return a.stopPropagation()}}};b.prototype.wrapMouseWheel=function(a){var b=a.data;return{type:"mouse-wheel",x:b.x,y:b.y,deltaY:b.deltaY,native:b.native,timestamp:a.timestamp,stopPropagation:function(){return a.stopPropagation()}}};
b.prototype.wrapGamepad=function(a){var b=a.data,c=b.state;return{type:"gamepad",device:b.device,timestamp:a.timestamp,action:b.action,buttons:c.buttons,axes:c.axes,stopPropagation:function(){return a.stopPropagation()}}};return b}(h.InputHandler)})},"esri/views/input/InputHandler":function(){define(["require","exports","../../core/Logger","./EventMatch"],function(b,e,m,d){Object.defineProperty(e,"__esModule",{value:!0});var k=m.getLogger("esri.views.input.InputHandler");b=function(){function a(a){this._manager=
null;this._incoming={};this._outgoing={};this._outgoingEventTypes=this._incomingEventTypes=this._incomingEventMatches=null;this._hasSideEffects=a}Object.defineProperty(a.prototype,"incomingEventMatches",{get:function(){if(!this._incomingEventMatches){this._incomingEventMatches=[];for(var a in this._incoming)for(var b=0,d=this._incoming[a];b<d.length;b++)this._incomingEventMatches.push(d[b].match)}return this._incomingEventMatches},enumerable:!0,configurable:!0});Object.defineProperty(a.prototype,
"incomingEventTypes",{get:function(){this._incomingEventTypes||(this._incomingEventTypes=this.incomingEventMatches.map(function(a){return a.eventType}));return this._incomingEventTypes},enumerable:!0,configurable:!0});Object.defineProperty(a.prototype,"outgoingEventTypes",{get:function(){this._outgoingEventTypes||(this._outgoingEventTypes=Object.keys(this._outgoing));return this._outgoingEventTypes},enumerable:!0,configurable:!0});Object.defineProperty(a.prototype,"hasSideEffects",{get:function(){return this._hasSideEffects},
enumerable:!0,configurable:!0});Object.defineProperty(a.prototype,"hasPendingInputs",{get:function(){return!1},enumerable:!0,configurable:!0});a.prototype.onInstall=function(a){var b=this;this._manager?k.error("This InputHandler has already been registered with an InputManager"):(a.setEventCallback(function(a){return b._handleEvent(a)}),a.setUninstallCallback(function(){return b._onUninstall()}),this._manager=a)};a.prototype.onUninstall=function(){};a.prototype.registerIncoming=function(a,b,e){var c=
this;"function"===typeof b?(e=b,b=[]):b=b||[];a="string"===typeof a?new d.EventMatch(a,b):a;var f=function(){c._incomingEventTypes=null;c._incomingEventMatches=null};b=function(a){var b=c._incoming[a.match.eventType];b&&(a=b.indexOf(a),b.splice(a,1),f(),c._manager&&c._manager.updateDependencies())};e=new l(a,e,{onPause:b,onRemove:b,onResume:function(a){var b=c._incoming[a.match.eventType];b&&-1===b.indexOf(a)&&(b.push(a),f(),c._manager&&c._manager.updateDependencies())}});b=this._incoming[a.eventType];
b||(b=[],this._incoming[a.eventType]=b);b.push(e);f();this._manager&&this._manager.updateDependencies();return e};a.prototype.registerOutgoing=function(a){var b=this;if(this._outgoing[a])throw Error("There is already a callback registered for this outgoing InputEvent: "+a);var c=new h(a,{onEmit:function(a,c,d,e){b._manager.emit(a.eventType,c,d,e)},onRemove:function(a){delete b._outgoing[a.eventType];b._manager.updateDependencies()}});this._outgoing[a]=c;this._outgoingEventTypes=null;this._manager&&
this._manager.updateDependencies();return c};a.prototype.startCapturingPointer=function(a){this._manager.setPointerCapture(a,!0)};a.prototype.stopCapturingPointer=function(a){this._manager.setPointerCapture(a,!1)};a.prototype.refreshHasPendingInputs=function(){this._manager.refreshHasPendingInputs()};a.prototype._onUninstall=function(){this._manager?(this.onUninstall(),this._manager=null):k.error("This InputHandler is not registered with an InputManager")};a.prototype._handleEvent=function(a){var b=
this._incoming[a.type];if(b)for(var c=0;c<b.length;c++){var d=b[c];if(d.match.matches(a)&&(d.callback(a),a.shouldStopPropagation()))break}};return a}();e.InputHandler=b;var l=function(){function a(a,b,d){this.match=a;this._callback=b;this._handler=d}a.prototype.pause=function(){this._handler.onPause(this)};a.prototype.resume=function(){this._handler.onResume(this)};a.prototype.remove=function(){this._handler.onRemove(this)};Object.defineProperty(a.prototype,"callback",{get:function(){return this._callback},
enumerable:!0,configurable:!0});return a}(),h=function(){function a(a,b){this.eventType=a;this._removed=!1;this._handler=b}a.prototype.emit=function(a,b,d){if(!this._removed)this._handler.onEmit(this,a,b,d)};a.prototype.remove=function(){this._removed=!0;this._handler.onRemove(this)};return a}()})},"esri/views/input/EventMatch":function(){define(["require","exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});b=function(){function b(b,e){void 0===e&&(e=[]);this.eventType=b;this.keyModifiers=
e}b.prototype.matches=function(b){if(b.type!==this.eventType)return!1;if(0===this.keyModifiers.length)return!0;b=b.modifiers;for(var d=0,e=this.keyModifiers;d<e.length;d++)if(!b.has(e[d]))return!1;return!0};return b}();e.EventMatch=b})},"esri/views/interactive/interactiveToolUtils":function(){define(["require","exports","../../core/Collection","../../core/maybe"],function(b,e,m,d){function k(b,a){var c=b.view;a&&c.ready&&c.activeTool!==b?(c.activeTool=b,c&&c.focus&&c.focus()):a||c.activeTool!==b||
(c.activeTool=null)}function l(b,a){return{addManipulator:function(c){return b.addToolManipulator(a,c)},removeManipulator:function(c){return b.removeToolManipulator(a,c)},removeManipulators:function(){return b.removeToolManipulators(a)},attemptManipulatorDragTo:function(c,d){return b.attemptManipulatorDragTo(a,c,{screenPoint:d})}}}Object.defineProperty(e,"__esModule",{value:!0});e.setActive=k;e.swap=function(b,a,c){var e=b.activeTool;a!==e&&(d.isSome(e)&&e.deactivate&&e.deactivate(),c(a),d.isSome(a)&&
a.activate&&a.activate(),b.tools.forEach(function(b){var c=d.isNone(a)||a===b;"enableEditing"in b&&"disableEditing"in b?c?b.enableEditing():b.disableEditing():"editable"in b&&(b.editable=c)}))};e.newToolCollection=function(b){var a=new m;a.on("after-add",function(a){a=a.item;a.view&&a.view.ready&&a.attach&&a.attach(l(b,a))});a.on("after-remove",function(a){a=a.item;k(a,!1);a.detach&&a.detach();b.removeToolManipulators(a)});return a};e.wrapToolViewManager=l})},"esri/views/interactive/ManipulatorCollection":function(){define("require exports ../../core/iteratorUtils ../../core/maybe ../../core/screenUtils ../../core/libs/gl-matrix-2/vec2".split(" "),
function(b,e,m,d,k,l){b=function(){function b(){this._toolManipulators=new Map;this._nextManipulatorId=0}b.prototype.add=function(a,b,c){this._toolManipulators.has(a)||this._toolManipulators.set(a,[]);a=this._toolManipulators.get(a);var d=this._nextManipulatorId++;a.push({id:d,manipulator:b,pointerUpEventId:c})};b.prototype.remove=function(a,b){if(this._toolManipulators.has(a)){a=this._toolManipulators.get(a);for(var c=0;c<a.length;c++)if(a[c].manipulator===b)return b=a.splice(c,1)[0],a=b.id,b.manipulator.destroy(),
a;return null}};b.prototype.removeTool=function(a){this._toolManipulators.has(a)&&(this._toolManipulators.get(a).forEach(function(a){return a.manipulator.destroy()}),this._toolManipulators.delete(a))};b.prototype.removeAll=function(){var a=this;this._toolManipulators.forEach(function(b,c){a.removeTool(c)})};b.prototype.destroy=function(){this.removeAll()};b.prototype.forEach=function(a){m.everyMap(this._toolManipulators,function(b,c){for(var d=0;d<b.length;d++)if(!1===a(b[d].manipulator,c))return!1;
return!0})};b.prototype.findClosest=function(a,b,c){void 0===c&&(c=null);var e=null,f=Number.MAX_VALUE;this._toolManipulators.forEach(function(g,h){g.forEach(function(g){var k=g.id,l=g.manipulator;g.pointerUpEventId!==c&&(g=l.intersectionDistance(a,b),d.isSome(g)&&g<f&&l.active&&(f=g,e={tool:h,manipulatorId:k}))})});return e};b.prototype.hasOverlappingInTool=function(b,c,d){var e=0;for(b=this._toolManipulators.get(b);e<b.length;e++){var f=b[e].manipulator;if(c!==f&&!f.allowOverlap){var g=k.screenPointObjectToArray(d,
h),n=k.screenPointObjectToArray(f.screenPoint,a),g=l.vec2.squaredDistance(g,n),f=c.radius+f.radius;if(g<f*f)return!0}}return!1};b.prototype.findByKey=function(a){if(d.isNone(a))return null;for(var b=0,c=this._toolManipulators.get(a.tool);b<c.length;b++){var e=c[b],f=e.manipulator;if(e.id===a.manipulatorId)return f}return null};return b}();var h=k.createScreenPointArray(),a=k.createScreenPointArray();return b})},"esri/core/libs/gl-matrix-2/vec2":function(){define(["require","exports","./math/vec2"],
function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.vec2=m})},"esri/core/libs/gl-matrix-2/math/vec2":function(){define(["require","exports","./common"],function(b,e,m){function d(a,b,c){a[0]=b[0]-c[0];a[1]=b[1]-c[1];return a}function k(a,b,c){a[0]=b[0]*c[0];a[1]=b[1]*c[1];return a}function l(a,b,c){a[0]=b[0]/c[0];a[1]=b[1]/c[1];return a}function h(a,b){var c=b[0]-a[0];a=b[1]-a[1];return Math.sqrt(c*c+a*a)}function a(a,b){var c=b[0]-a[0];a=b[1]-a[1];return c*c+a*a}function c(a){var b=
a[0];a=a[1];return Math.sqrt(b*b+a*a)}function f(a){var b=a[0];a=a[1];return b*b+a*a}Object.defineProperty(e,"__esModule",{value:!0});e.copy=function(a,b){a[0]=b[0];a[1]=b[1];return a};e.set=function(a,b,c){a[0]=b;a[1]=c;return a};e.add=function(a,b,c){a[0]=b[0]+c[0];a[1]=b[1]+c[1];return a};e.subtract=d;e.multiply=k;e.divide=l;e.ceil=function(a,b){a[0]=Math.ceil(b[0]);a[1]=Math.ceil(b[1]);return a};e.floor=function(a,b){a[0]=Math.floor(b[0]);a[1]=Math.floor(b[1]);return a};e.min=function(a,b,c){a[0]=
Math.min(b[0],c[0]);a[1]=Math.min(b[1],c[1]);return a};e.max=function(a,b,c){a[0]=Math.max(b[0],c[0]);a[1]=Math.max(b[1],c[1]);return a};e.round=function(a,b){a[0]=Math.round(b[0]);a[1]=Math.round(b[1]);return a};e.scale=function(a,b,c){a[0]=b[0]*c;a[1]=b[1]*c;return a};e.scaleAndAdd=function(a,b,c,d){a[0]=b[0]+c[0]*d;a[1]=b[1]+c[1]*d;return a};e.distance=h;e.squaredDistance=a;e.length=c;e.squaredLength=f;e.negate=function(a,b){a[0]=-b[0];a[1]=-b[1];return a};e.inverse=function(a,b){a[0]=1/b[0];a[1]=
1/b[1];return a};e.normalize=function(a,b){var c=b[0],d=b[1],c=c*c+d*d;0<c&&(c=1/Math.sqrt(c),a[0]=b[0]*c,a[1]=b[1]*c);return a};e.dot=function(a,b){return a[0]*b[0]+a[1]*b[1]};e.cross=function(a,b,c){b=b[0]*c[1]-b[1]*c[0];a[0]=a[1]=0;a[2]=b;return a};e.lerp=function(a,b,c,d){var e=b[0];b=b[1];a[0]=e+d*(c[0]-e);a[1]=b+d*(c[1]-b);return a};e.random=function(a,b){b=b||1;var c=2*m.RANDOM()*Math.PI;a[0]=Math.cos(c)*b;a[1]=Math.sin(c)*b;return a};e.transformMat2=function(a,b,c){var d=b[0];b=b[1];a[0]=
c[0]*d+c[2]*b;a[1]=c[1]*d+c[3]*b;return a};e.transformMat2d=function(a,b,c){var d=b[0];b=b[1];a[0]=c[0]*d+c[2]*b+c[4];a[1]=c[1]*d+c[3]*b+c[5];return a};e.transformMat3=function(a,b,c){var d=b[0];b=b[1];a[0]=c[0]*d+c[3]*b+c[6];a[1]=c[1]*d+c[4]*b+c[7];return a};e.transformMat4=function(a,b,c){var d=b[0];b=b[1];a[0]=c[0]*d+c[4]*b+c[12];a[1]=c[1]*d+c[5]*b+c[13];return a};e.rotate=function(a,b,c,d){var e=b[0]-c[0];b=b[1]-c[1];var f=Math.sin(d);d=Math.cos(d);a[0]=e*d-b*f+c[0];a[1]=e*f+b*d+c[1];return a};
e.angle=function(a,b){var c=a[0];a=a[1];var d=b[0];b=b[1];var e=c*c+a*a;0<e&&(e=1/Math.sqrt(e));var f=d*d+b*b;0<f&&(f=1/Math.sqrt(f));c=(c*d+a*b)*e*f;return 1<c?0:-1>c?Math.PI:Math.acos(c)};e.str=function(a){return"vec2("+a[0]+", "+a[1]+")"};e.exactEquals=function(a,b){return a[0]===b[0]&&a[1]===b[1]};e.equals=function(a,b){var c=a[0];a=a[1];var d=b[0];b=b[1];return Math.abs(c-d)<=m.EPSILON*Math.max(1,Math.abs(c),Math.abs(d))&&Math.abs(a-b)<=m.EPSILON*Math.max(1,Math.abs(a),Math.abs(b))};e.len=c;
e.sub=d;e.mul=k;e.div=l;e.dist=h;e.sqrDist=a;e.sqrLen=f})},"esri/views/input/Input":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators ./gamepad/GamepadSettings".split(" "),function(b,e,m,d,k,l,h){return function(a){function b(){var b=null!==a&&a.apply(this,arguments)||this;b.gamepad=new h;return b}m(b,a);d([l.property({readOnly:!0})],b.prototype,"gamepad",void 0);return b=d([l.subclass("esri.views.input.Input")],
b)}(l.declared(k))})},"esri/views/input/gamepad/GamepadSettings":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/Accessor ../../../core/Collection ../../../core/accessorSupport/decorators ./GamepadInputDevice".split(" "),function(b,e,m,d,k,l,h,a){return function(b){function c(){var a=b.call(this)||this;a.devices=new l;a.enabledFocusMode="document";return a}m(c,b);d([h.property({type:l.ofType(a),readOnly:!0})],c.prototype,
"devices",void 0);d([h.property({type:["document","view","none"]})],c.prototype,"enabledFocusMode",void 0);return c=d([h.subclass("esri.views.input.gamepad.GamepadSettings")],c)}(h.declared(k))})},"esri/views/input/gamepad/GamepadInputDevice":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/Accessor ../../../core/accessorSupport/decorators".split(" "),function(b,e,m,d,k,l){var h=/^(3dconnexion|space(mouse|navigator|pilot|explorer))/i,
a={standard:.15,spacemouse:.025,unknown:0};return function(b){function c(a){var c=b.call(this)||this;c.native=null;c._detectedDeviceType="unknown";"standard"===a.mapping?c._detectedDeviceType="standard":h.test(a.id)?c._detectedDeviceType="spacemouse":c._detectedDeviceType="unknown";c.native=a;return c}m(c,b);Object.defineProperty(c.prototype,"deviceType",{get:function(){return this._detectedDeviceType},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"axisThreshold",{get:function(){return a[this.deviceType]},
enumerable:!0,configurable:!0});d([l.property({nonNullable:!0,readOnly:!0})],c.prototype,"native",void 0);d([l.property({type:String,readOnly:!0})],c.prototype,"deviceType",null);d([l.property({type:Number,readOnly:!0})],c.prototype,"axisThreshold",null);return c=d([l.subclass("esri.views.input.gamepad.GamepadInputDevice")],c)}(l.declared(k))})},"esri/views/navigation/Navigation":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/accessorSupport/decorators ./gamepad/GamepadSettings".split(" "),
function(b,e,m,d,k,l,h){return function(a){function b(b){b=a.call(this,b)||this;b.gamepad=new h;return b}m(b,a);d([l.property({readOnly:!0})],b.prototype,"gamepad",void 0);return b=d([l.subclass("esri.views.navigation.Navigation")],b)}(l.declared(k))})},"esri/views/navigation/gamepad/GamepadSettings":function(){define("require exports ../../../core/tsSupport/declareExtendsHelper ../../../core/tsSupport/decorateHelper ../../../core/Accessor ../../../core/accessorSupport/decorators ../../input/gamepad/GamepadInputDevice".split(" "),
function(b,e,m,d,k,l,h){return function(a){function b(){var b=a.call(this)||this;b.enabled=!0;b.device=null;b.mode="pan";b.tiltDirection="forward-down";b.velocityFactor=1;return b}m(b,a);d([l.property({type:Boolean,nonNullable:!0})],b.prototype,"enabled",void 0);d([l.property({type:h})],b.prototype,"device",void 0);d([l.property({type:["pan","zoom"],nonNullable:!0})],b.prototype,"mode",void 0);d([l.property({type:["forward-down","forward-up"],nonNullable:!0})],b.prototype,"tiltDirection",void 0);
d([l.property({type:Number,nonNullable:!0})],b.prototype,"velocityFactor",void 0);return b=d([l.subclass("esri.views.navigation.gamepad.GamepadSettings")],b)}(l.declared(k))})},"esri/views/support/DefaultsFromMap":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Accessor ../../core/arrayUtils ../../core/Handles ../../core/Logger ../../core/watchUtils ../../core/accessorSupport/decorators ../../geometry/support/heightModelInfoUtils ../../geometry/support/webMercatorUtils ../../portal/support/geometryServiceUtils".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n,g,q){function p(a){return a?JSON.stringify(a.toJSON()):"undefined"}function t(a){switch(a){case 0:return"Waiting";case 1:return"Found";case 2:return"Exhausted"}return"Unknown: "+a}var r=a.getLogger("esri.views.support.DefaultsFromMap");return function(a){function b(){var b=null!==a&&a.apply(this,arguments)||this;b._handles=new h;b._waitTask=null;b._isStarted=!1;b._spatialReferenceCandidates=null;b._extentCandidates=null;b.logDebugInformation=!1;b.isSpatialReferenceDone=
!1;b.isTileInfoDone=!1;b.isHeightModelInfoSearching=!1;b.spatialReference=null;b.extent=null;b.heightModelInfo=null;b.vcsWkid=null;b.latestVcsWkid=null;b.mapCollectionPaths=e.DefaultMapCollectionPaths.slice();b.tileInfo=null;return b}m(b,a);e=b;b.prototype.initialize=function(){var a=this;this.watch("mapCollectionPaths",function(){a._isStarted&&(a.reset(),a.start())})};b.prototype.destroy=function(){this._set("view",null);this._handles&&(this._handles.destroy(),this._handles=null,this._isStarted=
!1);this._cancelLoading()};b.prototype.reset=function(){this._handles.removeAll();this._isStarted=!1;this._set("isSpatialReferenceDone",!1);this._set("isTileInfoDone",!1);this._set("isHeightModelInfoSearching",!1);this._set("spatialReference",null);this._set("extent",null);this._set("heightModelInfo",null);this._set("vcsWkid",null);this._set("latestVcsWkid",null);this._set("tileInfo",null);this._extentCandidates=this._spatialReferenceCandidates=null};b.prototype.start=function(){this._handles.removeAll();
this._isStarted=!0;for(var a=this._updateLayerChange.bind(this),b=0,d=this.mapCollectionPaths;b<d.length;b++)this._handles.add(c.on(this.view,"map."+d[b],"change",a,a,a,!0))};b.prototype._ownerNameFromCollectionName=function(a){var b=a.lastIndexOf(".");return-1===b?"view":"view."+a.slice(0,b)};b.prototype._ensureLoadedOwnersFromCollectionName=function(a){for(var b=this._ownerNameFromCollectionName(a).split("."),c,d=0;d<b.length;d++){c=this.get(b.slice(0,d+1).join("."));if(!c)break;if(c.load&&!c.isFulfilled())return{collectionName:a,
owner:null,loading:c.load()}}return{collectionName:a,owner:c}};b.prototype._cancelLoading=function(){this._waitTask=null;this._extentProjectTask&&(this._extentProjectTask.cancel(),this._extentProjectTask=null)};b.prototype._updateWhen=function(a){var b=this,c=!0,d=!1,e=a.catch(function(a){}).then(function(){c?d=!0:e===b._waitTask&&b._update()}),c=!1;d||(this._waitTask=e);return d};b.prototype._updateLayerChange=function(){this.isSpatialReferenceDone&&!this.spatialReference&&this._set("isSpatialReferenceDone",
!1);this._update()};b.prototype._update=function(){var a=this;this._cancelLoading();if(this.view){if(!this.isSpatialReferenceDone){this._debugLog("Starting search for spatial reference...");var b=this._processMapCollections(function(b){return a._processSpatialReferenceSource(b)});this._debugLog("Search ended with status '"+t(b)+"'");if(0!==b){var c=null,b=this._spatialReferenceCandidates;!b||1>b.length?(c=this.defaultSpatialReference,this._debugLog("No spatial reference found, locking to default ("+
p(c)+")")):(this.defaultSpatialReference&&1<b.length&&-1<l.findIndex(b,function(b){return b.equals(a.defaultSpatialReference)})&&(b=[this.defaultSpatialReference]),c=b[0],this._debugLog("Locking to "+p(c)));this._set("spatialReference",c);this._set("isSpatialReferenceDone",!0);c&&(b=this.logDebugInformation,this.logDebugInformation=!1,this._processMapCollections(function(b){return a._findExtent(b,c)}),this.extent||this._projectExtentCandidate(),this.logDebugInformation=b)}}null==this.heightModelInfo&&
this.view.isHeightModelInfoRequired&&(this._debugLog("Starting search for height model info..."),b=this._processMapCollections(function(b){return a._processHeightModelInfoSource(b)},function(a){return n.mayHaveHeightModelInfo(a)}),this._debugLog("Search ended with status "+t(b)),this._set("isHeightModelInfoSearching",0===b));null==this.tileInfo&&(b=!1,this.view.isTileInfoRequired()&&(b=this._deriveTileInfo()),b||this._set("isTileInfoDone",!0))}};b.prototype._processMapCollections=function(a,b){var c=
this;this._preloadMapCollections(b);var d=2;this._forAllMapCollectionSources(function(a){if(2!==d)return!1;c._debugLog("Processing collection "+a.collectionName+"...");if(a.loading&&!c._updateWhen(a.loading))return c._debugLog("Collection "+a.collectionName+" owner is loading -\x3e wait"),d=0,!1},function(e){if(2!==d)return!1;if(null!=b&&!b(e))return c._debugLog("Source "+e.id+" is skipped due to predicate"),!1;if(e.load&&!e.isFulfilled()&&!c._updateWhen(e.load()))return c._debugLog("Source "+e.id+
" is loading -\x3e wait"),d=0,!1;if((!e.load||e.isResolved())&&a(e))return d=1,!1});return d};b.prototype._preloadMapCollections=function(a){var b=this,c=10,d=this.logDebugInformation;this.logDebugInformation=!1;this._forAllMapCollectionSources(function(a){return!0},function(e){if(0===c||null!=a&&!a(e))return!1;e.load&&!e.isFulfilled()&&(b.logDebugInformation=d,b._debugLog("Pre-loading source "+e.id),b.logDebugInformation=!1,e.load(),c--)});this.logDebugInformation=d};b.prototype._forAllMapCollectionSources=
function(a,b){for(var c=0,d=this.mapCollectionPaths;c<d.length;c++){var e="map."+d[c],f=this._ensureLoadedOwnersFromCollectionName(e);!1!==a(f)&&(f=f.owner,!f||f.isRejected&&f.isRejected()?this._debugLog("Collection "+e+" owner is invalid or rejected -\x3e skip"):(f=this.view.get(e))?this._forEachSource(f,b):this._debugLog("Collection "+e+" does not exist -\x3e skip"))}};b.prototype._forEachSource=function(a,b){var c=0;for(a=a.items;c<a.length;c++){var d=a[c];!1!==b(d)&&"layers"in d&&this._forEachSource(d.layers,
b)}};b.prototype._processSpatialReferenceSource=function(a){var b=this._getSupportedSpatialReferences(a);if(0===b.length)return!1;this._spatialReferenceCandidates?(b=l.intersect(b,this._spatialReferenceCandidates,function(a,b){return a.equals(b)}),0<b.length?this._spatialReferenceCandidates=b:this._debugLog("Layer "+a.id+" is ignored because its supported spatial\n          references are not compatible with the previous candidates")):this._spatialReferenceCandidates=b;return 1===this._spatialReferenceCandidates.length};
b.prototype._findExtent=function(a,b){var c="fullExtents"in a&&a.fullExtents||(a.fullExtent?[a.fullExtent]:[]),d=l.find(c,function(a){return a.spatialReference.equals(b)});if(d)return this._set("extent",d),!0;0<this._getSupportedSpatialReferences(a).length&&(c=c.map(function(b){return{extent:b,layer:a}}),this._extentCandidates=(this._extentCandidates||[]).concat(c));return!1};b.prototype._projectExtentCandidate=function(){var a=this;if(this._extentCandidates&&this._extentCandidates.length){var b=
this.spatialReference,c=l.find(this._extentCandidates,function(a){return g.canProject(a.extent.spatialReference,b)});c?this._set("extent",g.project(c.extent,b)):(c=this._extentCandidates[0],this._extentProjectTask=q.projectGeometry(c.extent,b,c.layer.portalItem).then(function(b){a._set("extent",b)}))}};b.prototype._getSupportedSpatialReferences=function(a){var b=this,c="supportedSpatialReferences"in a&&a.supportedSpatialReferences||(a.spatialReference?[a.spatialReference]:[]);if(0===c.length)return this._debugLog("Layer "+
a.id+" is ignored because it does not have any spatial references"),[];c=c.filter(function(c){return b.view.isSpatialReferenceSupported(c,a,function(a){return b._debugLog(a)})});0===c.length?this._debugLog("Layer "+a.id+" has spatial references but none of them are supported (or layer doesn't require locking)"):this._debugLog("Layer "+a.id+" has spatial references. Resulting candidate set: "+c.map(p).join(", "));return c};b.prototype._processHeightModelInfoSource=function(a){var b=n.deriveHeightModelInfoFromLayer(a);
return b?(this._set("heightModelInfo",b),this._set("isHeightModelInfoSearching",!1),a.spatialReference&&(this._set("vcsWkid",a.spatialReference.vcsWkid),this._set("latestVcsWkid",a.spatialReference.latestVcsWkid)),!0):!1};b.prototype._deriveTileInfo=function(){if(!this.isSpatialReferenceDone)return!0;var a=this.get("view.map");if(!a)return!0;var b=a.basemap,c=b&&b.get("baseLayers.0"),a=a.get("layers.0"),d=!1,e=null;b&&"failed"!==b.loadStatus?b.loaded?c&&"failed"!==c.loadStatus?c.loaded?e="tileInfo"in
c&&c.tileInfo:(this._updateWhen(c.load()),d=!0):a&&"failed"!==a.loadStatus?a.loaded?e="tileInfo"in a&&a.tileInfo:(this._updateWhen(a.load()),d=!0):d=!0:(this._updateWhen(b.load()),d=!0):a&&"failed"!==a.loadStatus&&(a.loaded?e="tileInfo"in a&&a.tileInfo:(this._updateWhen(a.load()),d=!0));e&&!e.spatialReference.equals(this.spatialReference)&&(e=null);d||this._set("tileInfo",e);return d};b.prototype._debugLog=function(a){this.logDebugInformation&&r.info(a)};var e;b.DefaultMapCollectionPaths=["basemap.baseLayers",
"layers","ground.layers","basemap.referenceLayers"];d([f.property()],b.prototype,"logDebugInformation",void 0);d([f.property({readOnly:!0})],b.prototype,"isSpatialReferenceDone",void 0);d([f.property({readOnly:!0})],b.prototype,"isTileInfoDone",void 0);d([f.property({readOnly:!0})],b.prototype,"isHeightModelInfoSearching",void 0);d([f.property({constructOnly:!0})],b.prototype,"view",void 0);d([f.property({readOnly:!0})],b.prototype,"spatialReference",void 0);d([f.property({readOnly:!0})],b.prototype,
"extent",void 0);d([f.property({readOnly:!0})],b.prototype,"heightModelInfo",void 0);d([f.property({readOnly:!0})],b.prototype,"vcsWkid",void 0);d([f.property({readOnly:!0})],b.prototype,"latestVcsWkid",void 0);d([f.property()],b.prototype,"mapCollectionPaths",void 0);d([f.property()],b.prototype,"defaultSpatialReference",void 0);d([f.property({readOnly:!0})],b.prototype,"tileInfo",void 0);return b=e=d([f.subclass("esri.views.support.DefaultsFromMap")],b)}(f.declared(k))})},"esri/geometry/support/heightModelInfoUtils":function(){define("require exports ../../core/compilerUtils ../../core/Error ../HeightModelInfo ../../layers/support/arcgisLayerUrl".split(" "),
function(b,e,m,d,k,l){function h(b,c,d){if(!a(b)||!a(c))return 4;if(null==b||null==c)return 0;if(!d&&b.heightUnit!==c.heightUnit)return 1;if(b.heightModel!==c.heightModel)return 2;switch(b.heightModel){case "gravity-related-height":return 0;case "ellipsoidal":return b.vertCRS===c.vertCRS?0:3;default:return 4}}function a(a){return null==a||null!=a.heightModel&&null!=a.heightUnit}function c(a){var b=a.url&&l.parse(a.url);return(null!=(a.spatialReference&&a.spatialReference.vcsWkid)||!b||"ImageServer"!==
b.serverType)&&"heightModelInfo"in a&&a.heightModelInfo?a.heightModelInfo:n(a)?k.deriveUnitFromSR(q,a.spatialReference):null}function f(a){if(!("capabilities"in a))return!1;switch(a.type){case "feature":case "csv":case "stream":case "geojson":return!0;case "map-image":case "imagery":case "tile":case "vector-tile":case null:return!1;default:return m.neverReached(a),!1}}function n(a){return f(a)?!!(a.capabilities&&a.capabilities.data&&a.capabilities.data.supportsZ):g(a)}function g(a){switch(a.type){case "building-scene":case "elevation":case "integrated-mesh":case "point-cloud":case "scene":return!0;
case "base-dynamic":case "base-elevation":case "base-tile":case "bing-maps":case "csv":case "geojson":case "feature":case "geo-rss":case "graphics":case "group":case "imagery":case "kml":case "map-image":case "map-notes":case "open-street-map":case "stream":case "tile":case "unknown":case "unsupported":case "vector-tile":case "web-tile":case "wms":case "wmts":case null:break;default:m.neverReached(a)}return!1}Object.defineProperty(e,"__esModule",{value:!0});e.validateWebSceneError=function(b,c){if(!b)return null;
if(!a(b))return new d("webscene:unsupported-height-model-info","The vertical coordinate system of the scene is not supported",{heightModelInfo:b});var e=b.heightUnit;b=k.deriveUnitFromSR(b,c).heightUnit;return e!==b?new d("webscene:incompatible-height-unit","The vertical units of the scene ("+e+") must match the horizontal units of the scene ("+b+")",{verticalUnit:e,horizontalUnit:b}):null};e.rejectLayerError=function(a,b,e){var f=c(a),g=h(f,b,e),l=null;if(f){var m=k.deriveUnitFromSR(f,a.spatialReference).heightUnit;
e||m===f.heightUnit||(l=new d("layerview:unmatched-height-unit","The vertical units of the layer must match the horizontal units ("+m+")",{horizontalUnit:m}))}if(!("heightModelInfo"in a&&null!=a.heightModelInfo||null!=a.spatialReference)&&n(a)||4===g||l)return new d("layerview:unsupported-height-model-info","The vertical coordinate system of the layer is not supported",{heightModelInfo:f,error:l});l=null;switch(g){case 1:a=f.heightUnit||"unknown";e=b.heightUnit||"unknown";l=new d("layerview:incompatible-height-unit",
"The vertical units of the layer ("+a+") must match the vertical units of the scene ("+e+")",{layerUnit:a,sceneUnit:e});break;case 2:a=f.heightModel||"unknown";e=b.heightModel||"unknown";l=new d("layerview:incompatible-height-model","The height model of the layer ("+a+") must match the height model of the scene ("+e+")",{layerHeightModel:a,sceneHeightModel:e});break;case 3:a=f.vertCRS||"unknown",e=b.vertCRS||"unknown",l=new d("layerview:incompatible-vertical-datum","The vertical datum of the layer ("+
a+") must match the vertical datum of the scene ("+e+")",{layerDatum:a,sceneDatum:e})}return l?new d("layerview:incompatible-height-model-info","The vertical coordinate system of the layer is incompatible with the scene",{layerHeightModelInfo:f,sceneHeightModelInfo:b,error:l}):null};e.deriveHeightModelInfoFromLayer=c;e.mayHaveHeightModelInfo=function(a){return null!=a.layers||g(a)||f(a)||"heightModelInfo"in a};var q=new k({heightModel:"gravity-related-height"})})},"esri/portal/support/geometryServiceUtils":function(){define("require exports ../../config ../../core/Error ../../core/promiseUtils ../Portal ../PortalItem ../../tasks/GeometryService ../../tasks/support/ProjectParameters".split(" "),
function(b,e,m,d,k,l,h,a,c){function f(b){void 0===b&&(b=null);if(m.geometryServiceUrl)return k.resolve(new a({url:m.geometryServiceUrl}));if(!b)return k.reject(new d("internal:geometry-service-url-not-configured"));var c;b.isInstanceOf(h)?c=b.portal||l.getDefault():b.isInstanceOf(l)&&(c=b);return c.load().then(function(b){if(b.helperServices&&b.helperServices.geometry&&b.helperServices.geometry.url)return k.resolve(new a({url:b.helperServices.geometry.url}));throw new d("internal:geometry-service-url-not-configured");
})}Object.defineProperty(e,"__esModule",{value:!0});e.create=f;e.projectGeometry=function(a,b,d){void 0===d&&(d=null);return f(d).then(function(d){var e=new c;e.geometries=[a];e.outSpatialReference=b;return d.project(e)}).then(function(a){return a&&Array.isArray(a)&&1===a.length?a[0]:k.reject()})}})},"esri/views/ViewAnimation":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/Accessor ../core/Error ../core/Promise ../core/promiseUtils ../core/promiseUtils ../core/scheduling ../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){b=function(b){function e(a){a=b.call(this)||this;a.state="running";a.target=null;return a}m(e,b);e.prototype.initialize=function(){var b=this;this.addResolvingPromise(a.create(function(a,c){b._dfd={resolve:a,reject:c}}))};Object.defineProperty(e.prototype,"done",{get:function(){return"finished"===this.state||"stopped"===this.state},enumerable:!0,configurable:!0});e.prototype.stop=function(){"stopped"!==this.state&&"finished"!==this.state&&(this._set("state","stopped"),
f.schedule(this._dfd.reject.bind(this._dfd,new l("ViewAnimation stopped"))))};e.prototype.finish=function(){"stopped"!==this.state&&"finished"!==this.state&&(this._set("state","finished"),f.schedule(this._dfd.resolve))};e.prototype.update=function(a,b){b||(b=c.isThenable(a)?"waiting-for-target":"running");this._set("target",a);this._set("state",b)};d([n.property({readOnly:!0,dependsOn:["state"]})],e.prototype,"done",null);d([n.property({readOnly:!0,type:String})],e.prototype,"state",void 0);d([n.property()],
e.prototype,"target",void 0);return e=d([n.subclass("esri.views.ViewAnimation")],e)}(n.declared(k,h));(b||(b={})).State={RUNNING:"running",STOPPED:"stopped",FINISHED:"finished",WAITING_FOR_TARGET:"waiting-for-target"};return b})},"esri/views/layers/LayerView":function(){define("require exports ../../core/tsSupport/declareExtendsHelper ../../core/tsSupport/decorateHelper ../../core/Evented ../../core/HandleOwner ../../core/Identifiable ../../core/Logger ../../core/Promise ../../core/promiseUtils ../../core/accessorSupport/decorators".split(" "),
function(b,e,m,d,k,l,h,a,c,f,n){return function(b){function c(a){a=b.call(this)||this;a.layer=null;a.parent=null;a.view=null;return a}m(c,b);c.prototype.initialize=function(){var b=this;this.addResolvingPromise(this.layer);this.when().catch(function(c){if("layerview:create-error"!==c.name){var d=b.layer&&b.layer.id||"no id",e=b.layer&&b.layer.title||"no title";a.getLogger(b.declaredClass).error("#resolve()","Failed to resolve layer view (layer title: '"+e+"', id: '"+d+"')",c);return f.reject(c)}})};
c.prototype.destroy=function(){this.layer=this.view=this.parent=null};Object.defineProperty(c.prototype,"suspended",{get:function(){return!this.canResume()},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"updating",{get:function(){return!this.suspended&&this.isUpdating()},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"visible",{get:function(){return!0===this.get("layer.visible")},set:function(a){void 0===a?this._clearOverride("visible"):this._override("visible",
a)},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"fullOpacity",{get:function(){var a=this.get("layer.opacity"),a=null==a?1:a,b=this.get("parent.fullOpacity");return a*(null==b?1:b)},enumerable:!0,configurable:!0});c.prototype.canResume=function(){return!this.get("parent.suspended")&&this.get("view.ready")&&this.get("layer.loaded")&&this.visible||!1};c.prototype.isUpdating=function(){return!1};d([n.property()],c.prototype,"layer",void 0);d([n.property()],c.prototype,"parent",void 0);
d([n.property({readOnly:!0,dependsOn:["view","visible","layer.loaded","parent.suspended"]})],c.prototype,"suspended",null);d([n.property({type:Boolean,dependsOn:["suspended"],readOnly:!0})],c.prototype,"updating",null);d([n.property()],c.prototype,"view",void 0);d([n.property({dependsOn:["layer.visible"]})],c.prototype,"visible",null);d([n.property({dependsOn:["layer.opacity","parent.fullOpacity"]})],c.prototype,"fullOpacity",null);return c=d([n.subclass("esri.views.layers.LayerView")],c)}(n.declared(l,
k,h.Identifiable,c))})},"esri/core/HandleOwner":function(){define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ./Accessor ./Handles ./accessorSupport/decorators".split(" "),function(b,e,m,d,k,l,h){return function(a){function b(){for(var b=0;b<arguments.length;b++);b=a.call(this)||this;b.handles=new l;return b}m(b,a);b.prototype.destroy=function(){this.handles.destroy()};d([h.property({readOnly:!0})],b.prototype,"handles",void 0);return b=d([h.subclass("esri.core.HandleOwner")],
b)}(h.declared(k))})},"esri/widgets/Widget":function(){define("require exports ../core/tsSupport/assignHelper ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper dojo/dom ../core/Accessor ../core/Collection ../core/Evented ../core/Handles ../core/Logger ../core/watchUtils ../core/accessorSupport/decorators ./support/widget maquette".split(" "),function(b,e,m,d,k,l,h,a,c,f,n,g,q,p,t){var r=n.getLogger("esri.widgets.Widget"),v=0;return function(b){function c(a,c){a=b.call(this)||
this;a._attached=!1;a.destroyed=!1;a.domNode=null;a.iconClass="esri-icon-checkbox-unchecked";a.label=a.declaredClass.split(".").pop();a.visible=!0;a._internalHandles=new f;a.render=a.render.bind(a);return a}d(c,b);c.prototype.normalizeCtorArgs=function(a,b){a=m({},a);b&&(a.container=b);return a};c.prototype.initialize=function(){var b=this;this._internalHandles.add(this._renderableProps.map(function(c){return g.init(b,c,function(b,d){var e=this;a.isCollection(d)&&this._internalHandles.remove(this.declaredClass+
":"+c+"-collection-change-event-listener");a.isCollection(b)&&(b=b.on("change",function(){return e.scheduleRender()}),this._internalHandles.add(b,this.declaredClass+":"+c+"-collection-change-event-listener"));this.scheduleRender()})}));this._delegatedEventNames.length&&this._internalHandles.add(g.init(this,"viewModel",function(){b._get("viewModel")&&b._internalHandles.remove("delegated-events");b._delegatedEventNames.map(function(a){return b.viewModel.on(a,function(c){b.emit(a,c)})})}),"delegated-events");
this.postInitialize();this._internalHandles.add(g.whenOnce(this,"container",function(a){return b._attach(a)}))};c.prototype.postInitialize=function(){};c.prototype.destroy=function(){this.destroyed||(this.viewModel&&this.viewModel.destroy(),this._detach(this.container),this._internalHandles.destroy(),this._set("destroyed",!0))};c.prototype.startup=function(){r.warn("Widget.startup() is deprecated and no longer needed")};Object.defineProperty(c.prototype,"container",{set:function(a){this._get("container")||
this._set("container",a)},enumerable:!0,configurable:!0});c.prototype.castContainer=function(a){return l.byId(a)};Object.defineProperty(c.prototype,"id",{get:function(){return this._get("id")||this.get("container.id")||Date.now().toString(16)+"-widget-"+v++},set:function(a){a&&this._set("id",a)},enumerable:!0,configurable:!0});c.prototype.scheduleRender=function(){this._projector.scheduleRender()};c.prototype.on=function(a,b){var c=this.inherited(arguments);this._internalHandles.add(c);return c};
c.prototype.classes=function(){for(var a=[],b=0;b<arguments.length;b++)a[b]=arguments[b];return p.classes.apply(this,a)};c.prototype.own=function(a){1<arguments.length&&(a=Array.prototype.slice.call(arguments));this._internalHandles.add(a)};c.prototype.renderNow=function(){this._projector.renderNow()};c.prototype._attach=function(a){a&&(this._projector.merge(a,this.render),this._attached=!0)};c.prototype._detach=function(a){a&&this._attached&&(this._projector.detach(this.render),a.parentNode&&a.parentNode.removeChild(a),
this._attached=!1)};k([q.shared(t.createProjector())],c.prototype,"_projector",void 0);k([q.shared([])],c.prototype,"_renderableProps",void 0);k([q.shared([])],c.prototype,"_delegatedEventNames",void 0);k([q.property({value:null})],c.prototype,"container",null);k([q.cast("container")],c.prototype,"castContainer",null);k([q.property({readOnly:!0})],c.prototype,"destroyed",void 0);k([q.property({aliasOf:"container"})],c.prototype,"domNode",void 0);k([q.property()],c.prototype,"iconClass",void 0);k([q.property({dependsOn:["container"]})],
c.prototype,"id",null);k([q.property()],c.prototype,"label",void 0);k([q.property()],c.prototype,"viewModel",void 0);k([q.property()],c.prototype,"visible",void 0);return c=k([q.subclass("esri.widgets.Widget")],c)}(q.declared(h,c))})},"esri/widgets/support/widget":function(){define("require exports ./decorators ./jsxFactory ./widgetUtils ./shim/SVGElement".split(" "),function(b,e,m,d,k){function l(b){for(var a in b)e.hasOwnProperty(a)||(e[a]=b[a])}Object.defineProperty(e,"__esModule",{value:!0});
l(m);l(d);l(k);e.isWidget=function(b){return b&&"function"===typeof b.render};e.isWidgetBase=function(b){return b&&"function"===typeof b.postMixInProperties&&"function"===typeof b.buildRendering&&"function"===typeof b.postCreate&&"function"===typeof b.startup}})},"esri/widgets/support/decorators":function(){define(["require","exports","./decorators/accessibleHandler","./decorators/renderable","./decorators/vmEvent"],function(b,e,m,d,k){function l(b){for(var a in b)e.hasOwnProperty(a)||(e[a]=b[a])}
Object.defineProperty(e,"__esModule",{value:!0});l(m);l(d);l(k)})},"esri/widgets/support/decorators/accessibleHandler":function(){define(["require","exports","dojo/keys"],function(b,e,m){function d(b){return function(d){for(var e=[],a=1;a<arguments.length;a++)e[a-1]=arguments[a];a=d.type;if(d instanceof KeyboardEvent||"keyup"===a||"keydown"===a||"keypress"===a){if(d.keyCode===m.ENTER||d.keyCode===m.SPACE)d.preventDefault(),d.target.click()}else b.call.apply(b,[this,d].concat(e))}}Object.defineProperty(e,
"__esModule",{value:!0});e.accessibleHandler=function(){return function(b,e){return{value:d(b[e])}}}})},"esri/widgets/support/decorators/renderable":function(){define(["require","exports","./propUtils"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.renderable=function(b){var d="string"===typeof b?m.splitProps(b):b;return function(b,e){b._renderableProps||(b._renderableProps=[]);b=b._renderableProps;d?b.push.apply(b,m.normalizePropNames(d,e)):b.push(e)}}})},"esri/widgets/support/decorators/propUtils":function(){define(["require",
"exports"],function(b,e){Object.defineProperty(e,"__esModule",{value:!0});e.splitProps=function(b){return b.split(",").map(function(b){return b.trim()})};e.normalizePropNames=function(b,d){return b.map(function(b){b=0===b.indexOf(d)?b:d+"."+b;return b})}})},"esri/widgets/support/decorators/vmEvent":function(){define(["require","exports","./propUtils"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.vmEvent=function(b){return function(d){d._delegatedEventNames||(d._delegatedEventNames=
[]);var e=Array.isArray(b)?b:m.splitProps(b);d._delegatedEventNames=d._delegatedEventNames.concat(e)}}})},"esri/widgets/support/jsxFactory":function(){define(["require","exports","maquette-jsx"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});e.tsx=m.jsx})},"maquette-jsx/dist/maquette-jsx.umd":function(){(function(b,e){"object"===typeof exports&&"undefined"!==typeof module?e(exports):"function"===typeof define&&define.amd?define(["exports"],e):e(b.maquetteCssTransitions={})})(this,
function(b){var e=function(b,k){for(var d=0,h=b.length;d<h;d++){var a=b[d];Array.isArray(a)?e(a,k):null!==a&&void 0!==a&&!1!==a&&(a.hasOwnProperty("vnodeSelector")||(a={vnodeSelector:"",properties:void 0,children:void 0,text:a.toString(),domNode:null}),k.push(a))}},m=function(b,k){for(var d=[],h=2;h<arguments.length;h++)d[h-2]=arguments[h];if(1===d.length&&"string"===typeof d[0])return{vnodeSelector:b,properties:k||void 0,children:void 0,text:d[0],domNode:null};h=[];e(d,h);return{vnodeSelector:b,
properties:k||void 0,children:h,text:void 0,domNode:null}};b.jsx=m;b.enableGlobalJsx=function(){window.jsx=m};Object.defineProperty(b,"__esModule",{value:!0})})},"esri/widgets/support/widgetUtils":function(){define("require exports ../../core/ArrayPool ../../core/has ../../core/Logger maquette-css-transitions".split(" "),function(b,e,m,d,k,l){Object.defineProperty(e,"__esModule",{value:!0});k.getLogger("esri.widgets.support.widgetUtils");e.join=function(){for(var b=[],a=0;a<arguments.length;a++)b[a]=
arguments[a];return b.join(" ")};e.classes=function(b){for(var a=m.acquire(),c=0;c<arguments.length;c++){var d=arguments[c],e=typeof d;if("string"===e)a.push(d);else if(Array.isArray(d))a.push.apply(a,d);else if("object"===e)for(var g in d)d[g]&&a.push(g)}c=a.join(" ");m.release(a);return c};e.isRTL=function(){return"rtl"===document.dir};e.storeNode=function(b){this[b.getAttribute("data-node-ref")]=b};e.cssTransition=function(b,a){return("enter"===b?l.createEnterCssTransition:l.createExitCssTransition)(a)}})},
"maquette-css-transitions/dist/maquette-css-transitions.umd":function(){(function(b,e){"object"===typeof exports&&"undefined"!==typeof module?e(exports):"function"===typeof define&&define.amd?define(["exports"],e):e(b.maquetteCssTransitions={})})(this,function(b){var e,m,d=function(b){if("WebkitTransition"in b.style)e="webkitTransitionEnd",m="webkitAnimationEnd";else if("transition"in b.style)e="transitionend",m="animationend";else throw Error("Your browser is not supported!");};b.createEnterCssTransition=
function(b,l){void 0===l&&(l=b+"-active");return function(h){e||d(h);var a=!1,c=function(d){a||(a=!0,h.removeEventListener(e,c),h.removeEventListener(m,c),h.classList.remove(b),h.classList.remove(l))};h.classList.add(b);h.addEventListener(e,c);h.addEventListener(m,c);requestAnimationFrame(function(){h.classList.add(l)})}};b.createExitCssTransition=function(b,l){void 0===l&&(l=b+"-active");return function(h,a){e||d(h);var c=!1,f=function(b){c||(c=!0,h.removeEventListener(e,f),h.removeEventListener(m,
f),a())};h.classList.add(b);h.addEventListener(e,f);h.addEventListener(m,f);requestAnimationFrame(function(){h.classList.add(l)})}};Object.defineProperty(b,"__esModule",{value:!0})})},"esri/widgets/support/shim/SVGElement":function(){define(["require","exports","../../../core/has"],function(b,e,m){Object.defineProperty(e,"__esModule",{value:!0});m.add("esri-svg-classlist","classList"in SVGElement.prototype);var d=function(){function b(b){this._node=b}b.prototype.add=function(b){var d=this._node;d.className.baseVal=
(d.className.baseVal+" "+b).trim()};b.prototype.contains=function(b){return-1<this._node.className.baseVal.split(" ").indexOf(b)};b.prototype.remove=function(b){for(var d=this._node,a="",c=0,e=d.className.baseVal.split(" ");c<e.length;c++){var k=e[c];k!==b&&(a+=k+" ")}d.className.baseVal=a.trim()};b.prototype.toggle=function(b,d){var a=this.contains(b),c;if(c=a?!0!==d&&"remove":!1!==d&&"add")this[c](b);return void 0!==d?d:!a};return b}();e.DOMTokenListSubset=d;m("esri-svg-classlist")||Object.defineProperty(SVGElement.prototype,
"classList",{get:function(){return new d(this)}})})},"maquette/dist/maquette.umd":function(){(function(b,e){"object"===typeof exports&&"undefined"!==typeof module?e(exports):"function"===typeof define&&define.amd?define(["exports"],e):e(b.maquette={})})(this,function(b){var e=[],m=function(a,b){var c={};Object.keys(a).forEach(function(b){c[b]=a[b]});b&&Object.keys(b).forEach(function(a){c[a]=b[a]});return c},d=function(a,b){return a.vnodeSelector!==b.vnodeSelector?!1:a.properties&&b.properties?a.properties.key!==
b.properties.key?!1:a.properties.bind===b.properties.bind:!a.properties&&!b.properties},k=function(a){if("string"!==typeof a)throw Error("Style values must be strings");},l=function(a,b,c,e){var f=a[b];if(""!==f.vnodeSelector){var g=f.properties;if(!(g&&(void 0===g.key?g.bind:g.key)))for(g=0;g<a.length;g++)if(g!==b&&d(a[g],f))throw Error(c.vnodeSelector+" had a "+f.vnodeSelector+" child "+("added"===e?e:"removed")+", but there is now more than one. You must add unique key properties to make them distinguishable.");
}},h=[],a=!1,c=function(a){(a.children||[]).forEach(c);a.properties&&a.properties.afterRemoved&&a.properties.afterRemoved.apply(a.properties.bind||a.properties,[a.domNode])},f=function(){a=!1;h.forEach(c);h.length=0},n=function(b){h.push(b);a||(a=!0,"undefined"!==typeof window&&"requestIdleCallback"in window?window.requestIdleCallback(f,{timeout:16}):setTimeout(f,16))},g=function(a){var b=a.domNode;if(a.properties){var c=a.properties.exitAnimation;if(c){b.style.pointerEvents="none";c(b,function(){b.parentNode&&
(b.parentNode.removeChild(b),n(a))},a.properties);return}}b.parentNode&&(b.parentNode.removeChild(b),n(a))},q=function(a,b,c){if(b)for(var d=c.eventHandlerInterceptor,e=Object.keys(b),f=e.length,g=function(f){f=e[f];var g=b[f];if("className"===f)throw Error('Property "className" is not supported, use "class".');if("class"===f)v(a,g,!0);else if("classes"===f){var h=Object.keys(g),l=h.length;for(f=0;f<l;f++){var m=h[f];g[m]&&a.classList.add(m)}}else if("styles"===f)for(h=Object.keys(g),l=h.length,f=
0;f<l;f++){var m=h[f],n=g[m];n&&(k(n),c.styleApplyer(a,m,n))}else"key"!==f&&null!==g&&void 0!==g&&(h=typeof g,"function"===h?0===f.lastIndexOf("on",0)&&(d&&(g=d(f,g,a,b)),"oninput"===f&&function(){var a=g;g=function(b){a.apply(this,[b]);b.target["oninput-value"]=b.target.value}}(),a[f]=g):"http://www.w3.org/2000/svg"===c.namespace?"href"===f?a.setAttributeNS("http://www.w3.org/1999/xlink",f,g):a.setAttribute(f,g):"string"===h&&"value"!==f&&"innerHTML"!==f?a.setAttribute(f,g):a[f]=g)},h=0;h<f;h++)g(h)},
p=function(a,b,c){var d=b.children;if(d)for(var e=0;e<d.length;e++)t(d[e],a,void 0,c);b.text&&(a.textContent=b.text);q(a,b.properties,c);b.properties&&b.properties.afterCreate&&b.properties.afterCreate.apply(b.properties.bind||b.properties,[a,c,b.vnodeSelector,b.properties,b.children])},t=function(a,b,c,d){var e,f=0,g=a.vnodeSelector,h=b.ownerDocument;if(""===g)e=a.domNode=h.createTextNode(a.text),void 0!==c?b.insertBefore(e,c):b.appendChild(e);else{for(var k=0;k<=g.length;++k){var l=g.charAt(k);
if(k===g.length||"."===l||"#"===l)l=g.charAt(f-1),f=g.slice(f,k),"."===l?e.classList.add(f):"#"===l?e.id=f:("svg"===f&&(d=m(d,{namespace:"http://www.w3.org/2000/svg"})),void 0!==d.namespace?e=a.domNode=h.createElementNS(d.namespace,f):(e=a.domNode=a.domNode||h.createElement(f),"input"===f&&a.properties&&void 0!==a.properties.type&&e.setAttribute("type",a.properties.type)),void 0!==c?b.insertBefore(e,c):e.parentNode!==b&&b.appendChild(e)),f=k+1}p(e,a,d)}},r,v=function(a,b,c){b&&b.split(" ").forEach(function(b){return a.classList.toggle(b,
c)})};r=function(a,b,c){var f=a.domNode;if(a===b)return!1;var h=!1;if(""===b.vnodeSelector){if(b.text!==a.text)return a=f.ownerDocument.createTextNode(b.text),f.parentNode.replaceChild(a,f),b.domNode=a,!0;b.domNode=f}else{0===b.vnodeSelector.lastIndexOf("svg",0)&&(c=m(c,{namespace:"http://www.w3.org/2000/svg"}));a.text!==b.text&&(h=!0,void 0===b.text?f.removeChild(f.firstChild):f.textContent=b.text);b.domNode=f;var n;n=a.children;var p=b.children,q=c;if(n===p)n=!1;else{n=n||e;for(var p=p||e,u=n.length,
x=p.length,w=0,A=0,C=!1;A<x;){var y=w<u?n[w]:void 0,z=p[A];if(void 0!==y&&d(y,z))C=r(y,z,q)||C,w++;else{b:{var y=n,B=z;if(""!==B.vnodeSelector)for(var E=w+1;E<y.length;E++)if(d(y[E],B)){y=E;break b}y=-1}if(0<=y){for(;w<y;w++)g(n[w]),l(n,w,b,"removed");C=r(n[y],z,q)||C;w=y+1}else t(z,f,w<u?n[w].domNode:void 0,q),z.properties&&(y=z.properties.enterAnimation)&&y(z.domNode,z.properties),l(p,A,b,"added")}A++}if(u>w)for(;w<u;w++)g(n[w]),l(n,w,b,"removed");n=C}h=n||h;n=a.properties;p=b.properties;q=c;if(p){u=
!1;x=Object.keys(p);A=x.length;for(C=0;C<A;C++)if(y=x[C],z=p[y],w=n[y],"class"===y)w!==z&&(v(f,w,!1),v(f,z,!0));else if("classes"===y)for(var B=f.classList,E=Object.keys(z),F=E.length,y=0;y<F;y++){var ga=E[y],la=!!z[ga];la!==!!w[ga]&&(u=!0,la?B.add(ga):B.remove(ga))}else if("styles"===y)for(B=Object.keys(z),E=B.length,y=0;y<E;y++)F=B[y],ga=z[F],ga!==w[F]&&(u=!0,ga?(k(ga),q.styleApplyer(f,F,ga)):q.styleApplyer(f,F,""));else z||"string"!==typeof w||(z=""),"value"===y?(B=f[y],B!==z&&(f["oninput-value"]?
B===f["oninput-value"]:z!==w)&&(f[y]=z,f["oninput-value"]=void 0),z!==w&&(u=!0)):z!==w&&(w=typeof z,"function"===w&&q.eventHandlerInterceptor||("http://www.w3.org/2000/svg"===q.namespace?"href"===y?f.setAttributeNS("http://www.w3.org/1999/xlink",y,z):f.setAttribute(y,z):"string"===w&&"innerHTML"!==y?"role"===y&&""===z?f.removeAttribute(y):f.setAttribute(y,z):f[y]!==z&&(f[y]=z),u=!0));n=u}else n=void 0;h=n||h;b.properties&&b.properties.afterUpdate&&b.properties.afterUpdate.apply(b.properties.bind||
b.properties,[f,c,b.vnodeSelector,b.properties,b.children])}h&&b.properties&&b.properties.updateAnimation&&b.properties.updateAnimation(f,b.properties,a.properties);return!1};var u=function(a,b){return{getLastRender:function(){return a},update:function(c){if(a.vnodeSelector!==c.vnodeSelector)throw Error("The selector for the root VNode may not be changed. (consider using dom.merge and add one extra level to the virtual DOM)");var d=a;a=c;r(d,c,b)},domNode:a.domNode}},z={namespace:void 0,performanceLogger:function(){},
eventHandlerInterceptor:void 0,styleApplyer:function(a,b,c){a.style[b]=c}},y={create:function(a,b){b=m(z,b);t(a,document.createElement("div"),void 0,b);return u(a,b)},append:function(a,b,c){c=m(z,c);t(b,a,void 0,c);return u(b,c)},insertBefore:function(a,b,c){c=m(z,c);t(b,a.parentNode,a,c);return u(b,c)},merge:function(a,b,c){c=m(z,c);b.domNode=a;p(a,b,c);return u(b,c)},replace:function(a,b,c){c=m(z,c);t(b,a.parentNode,a,c);a.parentNode.removeChild(a);return u(b,c)}},x=function(a,b,c){for(var d=0,
e=b.length;d<e;d++){var f=b[d];Array.isArray(f)?x(a,f,c):null!==f&&void 0!==f&&!1!==f&&("string"===typeof f&&(f={vnodeSelector:"",properties:void 0,children:void 0,text:f.toString(),domNode:null}),c.push(f))}},w;w=Array.prototype.find?function(a,b){return a.find(b)}:function(a,b){return a.filter(b)[0]};var A=function(a,b){var c=a;b.forEach(function(a){c=c&&c.children?w(c.children,function(b){return b.domNode===a}):void 0});return c},B=function(a,b,c){var d=function(d){c("domEvent",d);var e=b(),f;
f=d.currentTarget;for(var g=e.domNode,h=[];f!==g;)h.push(f),f=f.parentNode;f=h;f.reverse();e=A(e.getLastRender(),f);a.scheduleRender();var k;e&&(k=e.properties["on"+d.type].apply(e.properties.bind||this,arguments));c("domEventProcessed",d);return k};return function(a,b,c,e){return d}};b.dom=y;b.h=function(a,b,c){if(Array.isArray(b))c=b,b=void 0;else if(b&&("string"===typeof b||b.hasOwnProperty("vnodeSelector"))||c&&("string"===typeof c||c.hasOwnProperty("vnodeSelector")))throw Error("h called with invalid arguments");
var d,e;c&&1===c.length&&"string"===typeof c[0]?d=c[0]:c&&(e=[],x(a,c,e),0===e.length&&(e=void 0));return{vnodeSelector:a,properties:b,children:e,text:""===d?void 0:d,domNode:null}};b.createProjector=function(a){var b,c=m(z,a),d=c.performanceLogger,e=!0,f,g=!1,h=[],k=[],l=function(a,e,f){var g;c.eventHandlerInterceptor=B(b,function(){return g},d);g=a(e,f(),c);h.push(g);k.push(f)},n=function(){f=void 0;if(e){e=!1;d("renderStart",void 0);for(var a=0;a<h.length;a++){var b=k[a]();d("rendered",void 0);
h[a].update(b);d("patched",void 0)}d("renderDone",void 0);e=!0}};return b={renderNow:n,scheduleRender:function(){f||g||(f=requestAnimationFrame(n))},stop:function(){f&&(cancelAnimationFrame(f),f=void 0);g=!0},resume:function(){g=!1;e=!0;b.scheduleRender()},append:function(a,b){l(y.append,a,b)},insertBefore:function(a,b){l(y.insertBefore,a,b)},merge:function(a,b){l(y.merge,a,b)},replace:function(a,b){l(y.replace,a,b)},detach:function(a){for(var b=0;b<k.length;b++)if(k[b]===a)return k.splice(b,1),h.splice(b,
1)[0];throw Error("renderFunction was not found");}}};b.createCache=function(){var a,b;return{invalidate:function(){a=b=void 0},result:function(c,d){if(a)for(var e=0;e<c.length;e++)a[e]!==c[e]&&(b=void 0);b||(b=d(),a=c);return b}}};b.createMapping=function(a,b,c){var d=[],e=[];return{results:e,map:function(f){for(var g=f.map(a),h=e.slice(),k=0,l=0;l<f.length;l++){var m=f[l],n=g[l];if(n===d[k])e[l]=h[k],c(m,h[k],l),k++;else{for(var p=!1,q=1;q<d.length+1;q++){var r=(k+q)%d.length;if(d[r]===n){e[l]=
h[r];c(f[l],h[r],l);k=r+1;p=!0;break}}p||(e[l]=b(m,l))}}e.length=f.length;d=g}}};Object.defineProperty(b,"__esModule",{value:!0})})},"*now":function(b){b(['dojo/i18n!*preload*dojo/nls/dojo*["ar","bs","ca","cs","da","de","el","en-au","en-ca","en-gb","en-us","es","es-mx","et","fi","fr","he","hi","hr","hu","id","it","ja","ko","lt","lv","nl","nb","pl","pt","pt-br","pt-pt","ro","ru","sl","sr","sv","th","tr","uk","vi","zh-cn","zh-hk","zh-tw","ROOT"]'])},"*noref":1}});require.boot&&require.apply(null,require.boot);