@arcgis/core 4.25.2 → 4.25.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/07605077ef508206668a.js +1 -0
- package/assets/esri/core/workers/chunks/{04dbebaeb2d4d778f0e1.js → 5028c10cb621bc1d0412.js} +1 -1
- package/assets/esri/core/workers/chunks/50a96ea72049d68bb8d9.js +1 -0
- package/assets/esri/core/workers/chunks/7136855af8b8f8595448.js +1 -0
- package/assets/esri/core/workers/chunks/{1556e74845e521154fe8.js → 78ed65b7669747a48b28.js} +2 -2
- package/assets/esri/core/workers/chunks/{1556e74845e521154fe8.js.LICENSE.txt → 78ed65b7669747a48b28.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/8b240e5173bbdee38025.js +1 -0
- package/assets/esri/core/workers/chunks/{85f56a2bc01b611533d9.js → 8f86efd4bc2164699a2a.js} +1 -1
- package/assets/esri/core/workers/chunks/913ee3922213cdd1fbde.js +1 -0
- package/assets/esri/core/workers/chunks/94044fbeea16313ec193.js +1 -0
- package/assets/esri/core/workers/chunks/{77cc27d60c79df45dbc2.js → d2e4bdf1567bc27681eb.js} +1 -1
- package/assets/esri/core/workers/chunks/e7a2ae5717c1b3b88ca2.js +1 -0
- package/assets/esri/core/workers/chunks/fabddb860fa16e2b6d4d.js +1 -0
- package/assets/esri/themes/base/widgets/_Sketch.scss +7 -4
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/config.js +1 -1
- package/core/workers/workerFactory.js +1 -1
- package/interfaces.d.ts +190 -0
- package/layers/CSVLayer.js +1 -1
- package/layers/MapNotesLayer.js +1 -1
- package/layers/graphics/sources/support/CSVSourceWorker.js +1 -1
- package/package.json +2 -2
- package/rest/networks/queryAssociations.d.ts +4 -0
- package/rest/networks/support/QueryAssociationsParameters.d.ts +4 -0
- package/rest/networks/support/QueryAssociationsResult.d.ts +4 -0
- package/support/revision.js +1 -1
- package/views/2d/layers/FeatureLayerView2D.js +1 -1
- package/views/2d/layers/features/sources/SnapshotFeatureSource.js +1 -1
- package/views/support/imageReprojection.js +1 -1
- package/widgets/Editor/CreateFeaturesWorkflow.js +1 -1
- package/widgets/Editor.js +1 -1
- package/widgets/Sketch.js +1 -1
- package/widgets/TimeSlider/TimeSliderViewModel.js +1 -1
- package/assets/esri/core/workers/chunks/2ca1f23cfad22f0999d1.js +0 -1
- package/assets/esri/core/workers/chunks/30f0ab816d40fb908d4f.js +0 -1
- package/assets/esri/core/workers/chunks/3a0268b5d0bb8ead8622.js +0 -1
- package/assets/esri/core/workers/chunks/6ea2f9328cff3d948a13.js +0 -1
- package/assets/esri/core/workers/chunks/7b229e36e754923f461b.js +0 -1
- package/assets/esri/core/workers/chunks/ae2bec0b83a8c4bc493b.js +0 -1
- package/assets/esri/core/workers/chunks/f775b535abf3f2c8ec7e.js +0 -1
- package/assets/esri/core/workers/chunks/ffdb5c1133a45787cd63.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7154,5732],{5732:(e,t,i)=>{i.d(t,{a:()=>r,c:()=>n,g:()=>s});var n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function s(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function r(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}},69801:(e,t,i)=>{i.d(t,{WJ:()=>l,Xq:()=>a});var n,s,r=i(70586),o=i(44553);(s=n||(n={}))[s.ALL=0]="ALL",s[s.SOME=1]="SOME";class a{constructor(e,t,i){this._namespace=e,this._storage=t,this._removeFunc=!1,this._hit=0,this._miss=0,this._storage.register(this),this._namespace+=":",i&&(this._storage.registerRemoveFunc(this._namespace,i),this._removeFunc=!0)}destroy(){this._storage.clear(this._namespace),this._removeFunc&&this._storage.deregisterRemoveFunc(this._namespace),this._storage.deregister(this),this._storage=null}get namespace(){return this._namespace.slice(0,-1)}get hitRate(){return this._hit/(this._hit+this._miss)}get size(){return this._storage.size}get maxSize(){return this._storage.maxSize}resetHitRate(){this._hit=this._miss=0}put(e,t,i,n=0){this._storage.put(this._namespace+e,t,i,n)}get(e){const t=this._storage.get(this._namespace+e);return void 0===t?++this._miss:++this._hit,t}pop(e){const t=this._storage.pop(this._namespace+e);return void 0===t?++this._miss:++this._hit,t}updateSize(e,t,i){this._storage.updateSize(this._namespace+e,t,i)}clear(){this._storage.clear(this._namespace)}clearAll(){this._storage.clearAll()}getStats(){return this._storage.getStats()}resetStats(){this._storage.resetStats()}}class l{constructor(e=10485760){this._maxSize=e,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._removeFuncs=new o.Z,this._users=new o.Z}destroy(){this.clearAll(),this._removeFuncs.clear(),this._users.clear(),this._db=null}register(e){this._users.push(e)}deregister(e){this._users.removeUnordered(e)}registerRemoveFunc(e,t){this._removeFuncs.push([e,t])}deregisterRemoveFunc(e){this._removeFuncs.filterInPlace((t=>t[0]!==e))}get size(){return this._size}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,0),this._checkSizeLimit()}put(e,t,i,s){const r=this._db.get(e);if(r&&(this._size-=r.size,this._db.delete(e),r.entry!==t&&this._notifyRemove(e,r.entry,n.ALL)),i>this._maxSize)return void this._notifyRemove(e,t,n.ALL);if(void 0===t)return void console.warn("Refusing to cache undefined entry ");if(!i||i<0)return void console.warn("Refusing to cache entry with invalid size "+i);const o=1+Math.max(s,-3)- -3;this._db.set(e,{entry:t,size:i,lifetime:o,lives:o}),this._size+=i,this._checkSizeLimit()}updateSize(e,t,i){const s=this._db.get(e);if(s&&s.entry===t){for(this._size-=s.size;i>this._maxSize;){const s=this._notifyRemove(e,t,n.SOME);if(!((0,r.pC)(s)&&s>0))return void this._db.delete(e);i=s}s.size=i,this._size+=i,this._checkSizeLimit()}}pop(e){const t=this._db.get(e);if(t)return this._size-=t.size,this._db.delete(e),++this._hit,t.entry;++this._miss}get(e){const t=this._db.get(e);if(void 0!==t)return this._db.delete(e),t.lives=t.lifetime,this._db.set(e,t),++this._hit,t.entry;++this._miss}getStats(){const e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},i=new Array;this._db.forEach(((e,n)=>{const s=e.lifetime;i[s]=(i[s]||0)+e.size,this._users.forAll((i=>{const s=i.namespace;if(n.startsWith(s)){const i=t[s]||0;t[s]=i+e.size}}))}));const n={};this._users.forAll((e=>{const i=e.namespace;if(!isNaN(e.hitRate)&&e.hitRate>0){const s=t[i]||0;t[i]=s,n[i]=Math.round(100*e.hitRate)+"%"}else n[i]="0%"}));const s=Object.keys(t);s.sort(((e,i)=>t[i]-t[e])),s.forEach((i=>e[i]=Math.round(t[i]/2**20)+"MB / "+n[i]));for(let t=i.length-1;t>=0;--t){const n=i[t];n&&(e["Priority "+(t+-3-1)]=Math.round(n/this.size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._users.forAll((e=>e.resetHitRate()))}clear(e){this._db.forEach(((t,i)=>{i.startsWith(e)&&(this._size-=t.size,this._db.delete(i),this._notifyRemove(i,t.entry,n.ALL))}))}clearAll(){this._db.forEach(((e,t)=>this._notifyRemove(t,e.entry,n.ALL))),this._size=0,this._db.clear()}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,i){let n;return this._removeFuncs.some((s=>{if(e.startsWith(s[0])){const e=s[1](t,i);return"number"==typeof e&&(n=e),!0}return!1})),n}_checkSizeLimit(){if(!(this._size<=this._maxSize))for(const[e,t]of this._db){if(this._db.delete(e),t.lives<=1){this._size-=t.size;const i=this._notifyRemove(e,t.entry,n.SOME);(0,r.pC)(i)&&i>0&&(this._size+=i,t.lives=t.lifetime,t.size=i,this._db.set(e,t))}else--t.lives,this._db.set(e,t);if(this._size<=.9*this.maxSize)return}}}},66643:(e,t,i)=>{i.d(t,{Ed:()=>u,UI:()=>c,mt:()=>p,q6:()=>f,vr:()=>m});var n=i(43697),s=i(15923),r=i(70586),o=i(95330),a=i(5600),l=(i(67676),i(75215),i(52011));function u(e,t,i){return(0,o.as)(e.map(((e,n)=>t.apply(i,[e,n]))))}async function c(e,t,i){return(await(0,o.as)(e.map(((e,n)=>t.apply(i,[e,n]))))).map((e=>e.value))}function d(e){return{ok:!0,value:e}}function h(e){return{ok:!1,error:e}}async function f(e){if((0,r.Wi)(e))return{ok:!1,error:new Error("no promise provided")};try{return d(await e)}catch(e){return h(e)}}async function p(e){try{return d(await e)}catch(e){return(0,o.r9)(e),h(e)}}function m(e,t){return new g(e,t)}let g=class extends s.Z{constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,r.IM)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:i}=this._abortController;this.promise=e(i),this.promise.then((e=>{this._result=d(e),this._cleanup()}),(e=>{this._result=h(e),this._cleanup()})),this._abortHandle=(0,o.fu)(t,this.abort)}get value(){return e=this._result,(0,r.pC)(e)&&!0===e.ok?e.value:null;var e}get error(){return e=this._result,(0,r.pC)(e)&&!1===e.ok?e.error:null;var e}get finished(){return(0,r.pC)(this._result)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,r.hw)(this._abortHandle),this._abortController=null}};(0,n._)([(0,a.Cb)()],g.prototype,"value",null),(0,n._)([(0,a.Cb)()],g.prototype,"error",null),(0,n._)([(0,a.Cb)()],g.prototype,"finished",null),(0,n._)([(0,a.Cb)()],g.prototype,"promise",void 0),(0,n._)([(0,a.Cb)()],g.prototype,"_result",void 0),g=(0,n._)([(0,l.j)("esri.core.asyncUtils.ReactiveTask")],g)},14808:(e,t,i)=>{i.d(t,{Qc:()=>c,WU:()=>a,lt:()=>u});var n=i(19153),s=i(70171);const r={ar:[".",","],bg:[","," "],bs:[",","."],ca:[",","."],cs:[","," "],da:[",","."],de:[",","."],"de-ch":[".","’"],el:[",","."],en:[".",","],"en-au":[".",","],es:[",","."],"es-mx":[".",","],et:[","," "],fi:[","," "],fr:[","," "],"fr-ch":[","," "],he:[".",","],hi:[".",",","#,##,##0.###"],hr:[",","."],hu:[","," "],id:[",","."],it:[",","."],"it-ch":[".","’"],ja:[".",","],ko:[".",","],lt:[","," "],lv:[","," "],mk:[",","."],nb:[","," "],nl:[",","."],pl:[","," "],pt:[",","."],"pt-pt":[","," "],ro:[",","."],ru:[","," "],sk:[","," "],sl:[",","."],sr:[",","."],sv:[","," "],th:[".",","],tr:[",","."],uk:[","," "],vi:[",","."],zh:[".",","]};function o(e){e||(e=(0,s.Kd)());let t=e in r;if(!t){const i=e.split("-");i.length>1&&i[0]in r&&(e=i[0],t=!0),t||(e="en")}const[i,n,o="#,##0.###"]=r[e];return{decimal:i,group:n,pattern:o}}function a(e,t){const i=o((t={...t}).locale);t.customs=i;const n=t.pattern||i.pattern;return isNaN(e)||Math.abs(e)===1/0?null:function(e,t,i){const n=(i=i||{}).customs.group,s=i.customs.decimal,r=t.split(";"),o=r[0];if((t=r[e<0?1:0]||"-"+o).includes("%"))e*=100;else if(t.includes("‰"))e*=1e3;else{if(t.includes("¤"))throw new Error("currency notation not supported");if(t.includes("E"))throw new Error("exponential notation not supported")}const a=l,u=o.match(a);if(!u)throw new Error("unable to find a number expression in pattern: "+t);return!1===i.fractional&&(i.places=0),t.replace(a,function(e,t,i){!0===(i=i||{}).places&&(i.places=0),i.places===1/0&&(i.places=6);const n=t.split("."),s="string"==typeof i.places&&i.places.indexOf(",");let r=i.places;s?r=i.places.substring(s+1):r>=0||(r=(n[1]||[]).length),i.round<0||(e=Number(e.toFixed(Number(r))));const o=String(Math.abs(e)).split("."),a=o[1]||"";if(n[1]||i.places){s&&(i.places=i.places.substring(0,s));const e=void 0!==i.places?i.places:n[1]&&n[1].lastIndexOf("0")+1;e>a.length&&(o[1]=a.padEnd(Number(e),"0")),r<a.length&&(o[1]=a.substr(0,Number(r)))}else o[1]&&o.pop();const l=n[0].replace(",","");let u=l.indexOf("0");-1!==u&&(u=l.length-u,u>o[0].length&&(o[0]=o[0].padStart(u,"0")),l.includes("#")||(o[0]=o[0].substr(o[0].length-u)));let c,d,h=n[0].lastIndexOf(",");if(-1!==h){c=n[0].length-h-1;const e=n[0].substr(0,h);h=e.lastIndexOf(","),-1!==h&&(d=e.length-h-1)}const f=[];for(let e=o[0];e;){const t=e.length-c;f.push(t>0?e.substr(t):e),e=t>0?e.slice(0,t):"",d&&(c=d,d=void 0)}return o[0]=f.reverse().join(i.group||","),o.join(i.decimal||".")}(e,u[0],{decimal:s,group:n,places:i.places,round:i.round}))}(e,n,t)}const l=/[#0,]*[#0](?:\.0*#*)?/;function u(e){const t=o((e=e||{}).locale),i=e.pattern||t.pattern,s=t.group,r=t.decimal;let a=1;if(i.includes("%"))a/=100;else if(i.includes("‰"))a/=1e3;else if(i.includes("¤"))throw new Error("currency notation not supported");const u=i.split(";");1===u.length&&u.push("-"+u[0]);const c=h(u,(t=>(t="(?:"+(0,n.Qs)(t,".")+")").replace(l,(t=>{const i={signed:!1,separator:e.strict?s:[s,""],fractional:e.fractional,decimal:r,exponent:!1},n=t.split(".");let o=e.places;1===n.length&&1!==a&&(n[1]="###"),1===n.length||0===o?i.fractional=!1:(void 0===o&&(o=e.pattern?n[1].lastIndexOf("0")+1:1/0),o&&null==e.fractional&&(i.fractional=!0),!e.places&&o<n[1].length&&(o+=","+n[1].length),i.places=o);const l=n[0].split(",");return l.length>1&&(i.groupSize=l.pop().length,l.length>1&&(i.groupSize2=l.pop().length)),"("+function(e){"places"in(e=e||{})||(e.places=1/0),"string"!=typeof e.decimal&&(e.decimal="."),"fractional"in e&&!/^0/.test(String(e.places))||(e.fractional=[!0,!1]),"exponent"in e||(e.exponent=[!0,!1]),"eSigned"in e||(e.eSigned=[!0,!1]);const t=d(e),i=h(e.fractional,(t=>{let i="";return t&&0!==e.places&&(i="\\"+e.decimal,e.places===1/0?i="(?:"+i+"\\d+)?":i+="\\d{"+e.places+"}"),i}),!0);let n=t+i;return i&&(n="(?:(?:"+n+")|(?:"+i+"))"),n+h(e.exponent,(t=>t?"([eE]"+d({signed:e.eSigned})+")":""))}(i)+")"}))),!0);return{regexp:c.replace(/[\xa0 ]/g,"[\\s\\xa0]"),group:s,decimal:r,factor:a}}function c(e,t){const i=u(t),n=new RegExp("^"+i.regexp+"$").exec(e);if(!n)return NaN;let s=n[1];if(!n[1]){if(!n[2])return NaN;s=n[2],i.factor*=-1}return s=s.replace(new RegExp("["+i.group+"\\s\\xa0]","g"),"").replace(i.decimal,"."),Number(s)*i.factor}function d(e){return"signed"in(e=e||{})||(e.signed=[!0,!1]),"separator"in e?"groupSize"in e||(e.groupSize=3):e.separator="",h(e.signed,(e=>e?"[-+]":""),!0)+h(e.separator,(t=>{if(!t)return"(?:\\d+)";" "===(t=(0,n.Qs)(t))?t="\\s":" "===t&&(t="\\s\\xa0");const i=e.groupSize,s=e.groupSize2;if(s){const e="(?:0|[1-9]\\d{0,"+(s-1)+"}(?:["+t+"]\\d{"+s+"})*["+t+"]\\d{"+i+"})";return i-s>0?"(?:"+e+"|(?:0|[1-9]\\d{0,"+(i-1)+"}))":e}return"(?:0|[1-9]\\d{0,"+(i-1)+"}(?:["+t+"]\\d{"+i+"})*)"}),!0)}const h=(e,t,i)=>{if(!(e instanceof Array))return t(e);const n=[];for(let i=0;i<e.length;i++)n.push(t(e[i]));return f(n.join("|"),Boolean(i))},f=(e,t)=>"("+(t?"?:":"")+e+")"},17445:(e,t,i)=>{i.d(t,{N1:()=>h,YP:()=>l,Z_:()=>m,gx:()=>u,nn:()=>g,on:()=>d,tX:()=>y});var n=i(91460),s=i(50758),r=i(70586),o=i(95330),a=i(26258);function l(e,t,i={}){return c(e,t,i,f)}function u(e,t,i={}){return c(e,t,i,p)}function c(e,t,i={},n){let s=null;const o=i.once?(e,i)=>{n(e)&&((0,r.hw)(s),t(e,i))}:(e,i)=>{n(e)&&t(e,i)};if(s=(0,a.aQ)(e,o,i.sync,i.equals),i.initial){const t=e();o(t,t)}return s}function d(e,t,i,o={}){let a=null,u=null,c=null;function d(){a&&u&&(u.remove(),o.onListenerRemove?.(a),a=null,u=null)}function h(e){o.once&&o.once&&(0,r.hw)(c),i(e)}const f=l(e,((e,i)=>{d(),(0,n.vT)(e)&&(a=e,u=(0,n.on)(e,t,h),o.onListenerAdd?.(e))}),{sync:o.sync,initial:!0});return c=(0,s.kB)((()=>{f.remove(),d()})),c}function h(e,t){return function(e,t,i){if((0,o.Hc)(i))return Promise.reject((0,o.zE)());const n=e();if(t?.(n))return Promise.resolve(n);let a=null;function l(){a=(0,r.hw)(a)}return new Promise(((n,r)=>{a=(0,s.AL)([(0,o.fu)(i,(()=>{l(),r((0,o.zE)())})),c(e,(e=>{l(),n(e)}),{sync:!1,once:!0},t??f)])}))}(e,p,t)}function f(e){return!0}function p(e){return!!e}i(87538);const m={sync:!0},g={initial:!0},y={sync:!0,initial:!0}},60437:(e,t,i)=>{i.d(t,{Gv:()=>_,HH:()=>a,JR:()=>m,TC:()=>l,Tn:()=>h,Ue:()=>r,al:()=>o,cS:()=>p,dp:()=>c,fS:()=>y,op:()=>d,pp:()=>u,t8:()=>f});var n=i(70586),s=i(6570);function r(e=b){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function o(e,t,i,n,s,o,a=r()){return a[0]=e,a[1]=t,a[2]=i,a[3]=n,a[4]=s,a[5]=o,a}function a(e,t){const i=isFinite(e[2])||isFinite(e[5]);return new s.Z(i?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function l(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}function u(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}function c(e,t=[0,0,0]){return t[0]=function(e){return e[0]>=e[3]?0:e[3]-e[0]}(e),t[1]=function(e){return e[1]>=e[4]?0:e[4]-e[1]}(e),t[2]=function(e){return e[2]>=e[5]?0:e[5]-e[2]}(e),t}function d(e,t,i=e){return i[0]=t[0],i[1]=t[1],i[2]=t[2],i!==e&&(i[3]=e[3],i[4]=e[4],i[5]=e[5]),i}function h(e,t,i=e){return i[3]=t[0],i[4]=t[1],i[5]=t[2],i!==e&&(i[0]=e[0],i[1]=e[1],i[2]=e[2]),e}function f(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function p(e){return e?f(e,_):r(_)}function m(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function g(e){return 6===e.length}function y(e,t,i){if((0,n.Wi)(e)||(0,n.Wi)(t))return e===t;if(!g(e)||!g(t))return!1;if(i){for(let n=0;n<e.length;n++)if(!i(e[n],t[n]))return!1}else for(let i=0;i<e.length;i++)if(e[i]!==t[i])return!1;return!0}i(24470);const _=[1/0,1/0,1/0,-1/0,-1/0,-1/0],b=[0,0,0,0,0,0];r()},51806:(e,t,i)=>{i.d(t,{aX:()=>N});var n=i(68773),s=i(20102),r=i(92604),o=i(70586),a=i(38913),l=i(58901),u=i(82971),c=i(33955);const d={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new l.Z({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:u.Z.WebMercator}),minus180Line:new l.Z({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:u.Z.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new l.Z({paths:[[[180,-180],[180,180]]],spatialReference:u.Z.WGS84}),minus180Line:new l.Z({paths:[[[-180,-180],[-180,180]]],spatialReference:u.Z.WGS84})}};function h(e,t){return Math.ceil((e-t)/(2*t))}function f(e,t){const i=p(e);for(const e of i)for(const i of e)i[0]+=t;return e}function p(e){return(0,c.oU)(e)?e.rings:e.paths}var m=i(8744),g=i(40488),y=(i(66577),i(3172)),_=i(11282),b=i(17452);const x=r.Z.getLogger("esri.geometry.support.normalizeUtils");function S(e){return"polygon"===e[0].type}function I(e){return"polyline"===e[0].type}function v(e,t,i){if(t){const t=function(e,t){if(!(e instanceof l.Z||e instanceof a.Z)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw x.error(e),new s.Z(e)}const i=p(e),n=[];for(const e of i){const i=[];n.push(i),i.push([e[0][0],e[0][1]]);for(let n=0;n<e.length-1;n++){const s=e[n][0],r=e[n][1],o=e[n+1][0],a=e[n+1][1],l=Math.sqrt((o-s)*(o-s)+(a-r)*(a-r)),u=(a-r)/l,c=(o-s)/l,d=l/t;if(d>1){for(let e=1;e<=d-1;e++){const n=e*t,o=c*n+s,a=u*n+r;i.push([o,a])}const e=(l+Math.floor(d-1)*t)/2,n=c*e+s,o=u*e+r;i.push([n,o])}i.push([o,a])}}return function(e){return"polygon"===e.type}(e)?new a.Z({rings:n,spatialReference:e.spatialReference}):new l.Z({paths:n,spatialReference:e.spatialReference})}(e,1e6);e=(0,g.Sx)(t,!0)}return i&&(e=f(e,i)),e}function w(e,t,i){if(Array.isArray(e)){const n=e[0];if(n>t){const i=h(n,t);e[0]=n+i*(-2*t)}else if(n<i){const t=h(n,i);e[0]=n+t*(-2*i)}}else{const n=e.x;if(n>t){const i=h(n,t);e=e.clone().offset(i*(-2*t),0)}else if(n<i){const t=h(n,i);e=e.clone().offset(t*(-2*i),0)}}return e}function F(e,t){let i=-1;for(let n=0;n<t.cutIndexes.length;n++){const s=t.cutIndexes[n],r=t.geometries[n],o=p(r);for(let e=0;e<o.length;e++){const t=o[e];t.some((i=>{if(i[0]<180)return!0;{let i=0;for(let e=0;e<t.length;e++){const n=t[e][0];i=n>i?n:i}i=Number(i.toFixed(9));const n=-360*h(i,180);for(let i=0;i<t.length;i++){const t=r.getPoint(e,i);r.setPoint(e,i,t.clone().offset(n,0))}return!0}}))}if(s===i){if(S(e))for(const t of p(r))e[s]=e[s].addRing(t);else if(I(e))for(const t of p(r))e[s]=e[s].addPath(t)}else i=s,e[s]=r}return e}async function N(e,t,i){if(!Array.isArray(e))return N([e],t);t&&"string"!=typeof t&&x.warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const s="string"==typeof t?t:t?.url??n.Z.geometryServiceUrl;let r,u,p,S,I,E,z,T,M=0;const C=[],B=[];for(const t of e)if((0,o.Wi)(t))B.push(t);else if(r||(r=t.spatialReference,u=(0,m.C5)(r),p=r.isWebMercator,E=p?102100:4326,S=d[E].maxX,I=d[E].minX,z=d[E].plus180Line,T=d[E].minus180Line),u)if("mesh"===t.type)B.push(t);else if("point"===t.type)B.push(w(t.clone(),S,I));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>w(e,S,I))),B.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,u);B.push(e.rings?new a.Z(e):e)}else if(t.extent){const e=t.extent,i=h(e.xmin,I)*(2*S);let n=0===i?t.clone():f(t.clone(),i);e.offset(i,0),e.intersects(z)&&e.xmax!==S?(M=e.xmax>M?e.xmax:M,n=v(n,p),C.push(n),B.push("cut")):e.intersects(T)&&e.xmin!==I?(M=e.xmax*(2*S)>M?e.xmax*(2*S):M,n=v(n,p,360),C.push(n),B.push("cut")):B.push(n)}else B.push(t.clone());else B.push(t);let R=h(M,S),O=-90;const Z=R,q=new l.Z;for(;R>0;){const e=360*R-180;q.addPath([[e,O],[e,-1*O]]),O*=-1,R--}if(C.length>0&&Z>0){const t=F(C,await async function(e,t,i,n){const s=(0,_.en)(e),r=t[0].spatialReference,o={...n,query:{...s.query,f:"json",sr:JSON.stringify(r),target:JSON.stringify({geometryType:(0,c.Ji)(t[0]),geometries:t}),cutter:JSON.stringify(i)}},a=await(0,y.default)(s.path+"/cut",o),{cutIndexes:l,geometries:u=[]}=a.data;return{cutIndexes:l,geometries:u.map((e=>{const t=(0,c.im)(e);return t.spatialReference=r,t}))}}(s,C,q,i)),n=[],r=[];for(let i=0;i<B.length;i++){const s=B[i];if("cut"!==s)r.push(s);else{const s=t.shift(),a=e[i];(0,o.pC)(a)&&"polygon"===a.type&&a.rings&&a.rings.length>1&&s.rings.length>=a.rings.length?(n.push(s),r.push("simplify")):r.push(p?(0,g.$)(s):s)}}if(!n.length)return r;const a=await async function(e,t,i){const n="string"==typeof e?(0,b.mN)(e):e,s=t[0].spatialReference,r=(0,c.Ji)(t[0]),o={...i,query:{...n.query,f:"json",sr:s.wkid?s.wkid:JSON.stringify(s),geometries:JSON.stringify((l=t,{geometryType:(0,c.Ji)(l[0]),geometries:l.map((e=>e.toJSON()))}))}},{data:a}=await(0,y.default)(n.path+"/simplify",o);var l;return function(e,t,i){const n=(0,c.q9)(t);return e.map((e=>{const t=n.fromJSON(e);return t.spatialReference=i,t}))}(a.geometries,r,s)}(s,n,i),l=[];for(let e=0;e<r.length;e++){const t=r[e];"simplify"!==t?l.push(t):l.push(p?(0,g.$)(a.shift()):a.shift())}return l}const L=[];for(let e=0;e<B.length;e++){const t=B[e];if("cut"!==t)L.push(t);else{const e=C.shift();L.push(!0===p?(0,g.$)(e):e)}}return L}},70171:(e,t,i)=>{let n;i.d(t,{Kd:()=>o,Ze:()=>c,qe:()=>l});const s=globalThis.esriConfig?.locale??globalThis.dojoConfig?.locale;function r(){return s??globalThis.navigator?.language??"en"}function o(){return void 0===n&&(n=r()),n}const a=[];function l(e){return a.push(e),{remove(){a.splice(a.indexOf(e),1)}}}const u=[];function c(e){return u.push(e),{remove(){a.splice(u.indexOf(e),1)}}}globalThis.addEventListener?.("languagechange",(function(){const e=r();n!==e&&(n=e,[...u].forEach((t=>{t.call(null,e)})),[...a].forEach((t=>{t.call(null,e)})))}))},37549:(e,t,i)=>{i.d(t,{H:()=>a});var n=i(80442),s=i(24133),r=i(24470);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new s.Q(9,(0,n.Z)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((i,n)=>{e[t++]=n})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,r.cS)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,i){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,i)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},57191:(e,t,i)=>{i.d(t,{Z:()=>m});var n=i(20102),s=i(32448),r=i(92604),o=i(70586),a=i(60437),l=i(24470),u=i(98732),c=i(37549),d=i(29730),h=i(70272),f=i(5428);const p={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new h.u_(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>((0,o.Wi)(e.centroid)&&(e.centroid=(0,d.Y)(new f.Z,e.geometry,t.hasZ,t.hasM)),e.centroid)};class m{constructor(e){this.geometryInfo=e,this._boundsStore=new c.H,this._featuresById=new Map,this._markedIds=new Set,this.events=new s.Z,this.featureAdapter=p}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach((t=>{(0,o.pC)(t.geometry)&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t,i){for(const n of e){const e=this._boundsStore.get(n.objectId);e&&t((0,a.JR)(i,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}toArray(){return Array.from(this._featuresById.values())}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}startMarkingUsedFeatures(){this._boundsStore.invalidateIndex(),this._markedIds.clear()}sweep(){let e=!1;this._featuresById.forEach(((t,i)=>{this._markedIds.has(i)||(e=!0,this._remove(t))})),this._markedIds.clear(),e&&this._emitChanged()}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void r.Z.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.Z("featurestore:invalid-feature","feature id is missing",{feature:e}));const i=this._featuresById.get(t);let s;if(this._markedIds.add(t),i?(e.displayId=i.displayId,s=this._boundsStore.get(t),this._boundsStore.delete(t)):(0,o.pC)(this.onFeatureAdd)&&this.onFeatureAdd(e),(0,o.Wi)(e.geometry)||!e.geometry.coords||!e.geometry.coords.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);s=(0,u.$)((0,o.pC)(s)?s:(0,l.Ue)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),(0,o.pC)(s)&&this._boundsStore.set(t,s),this._featuresById.set(t,e)}_remove(e){return(0,o.pC)(this.onFeatureRemove)&&this.onFeatureRemove(e),this._markedIds.delete(e.objectId),this._boundsStore.delete(e.objectId),this._featuresById.delete(e.objectId),e}}},27793:(e,t,i)=>{i.r(t),i.d(t,{default:()=>K}),i(66577);var n=i(3172),s=i(66643),r=i(20102),o=i(92604),a=i(95330),l=i(17452),u=i(44547),c=i(37455),d=i(8744),h=i(40488),f=i(70272),p=i(5428),m=i(57191),g=i(37427),y=i(50245),_=i(14808);const b=/^\s*"([\S\s]*)"\s*$/,x=/""/g,S=[","," ",";","|","\t"];function*I(e,t,i){let n=0;for(;n<=e.length;){const s=e.indexOf(t,n),r=e.substring(n,s>-1?s:void 0);n+=r.length+t.length,i&&!r.trim()||(yield r)}}function v(e){const t=e.includes("\r\n")?"\r\n":"\n";return I(e,t,!0)}function w(e,t){return I(e,t,!1)}function F(e,t,i){e=e.trim(),t=t?.trim();const n=[],s=Array.from(new Set([i?.delimiter,...S])).filter((e=>null!=e));for(const i of s){const s=z(e,i).length,r=z(t,i).length??s;s>1&&n.push({weight:Math.min(s,r),delimiter:i})}const r=n.sort((({weight:e},{weight:t})=>t-e)).map((({delimiter:e})=>e));for(const t of r){const n=M(E(e,t).names,i?.longitudeField,i?.latitudeField);if(n.longitudeFieldName&&n.latitudeFieldName)return{delimiter:t,locationInfo:n}}return{delimiter:r[0],locationInfo:null}}function*N(e,t,i,n=(()=>Object.create(null))){const s=v(e);s.next();let r="",o="",a=0,l=n(),u=0;e:for(const e of s){const s=w(e,i);for(const e of s)if(r+=o+e,o="",a+=T(e),a%2==0){if(a>0){const e=b.exec(r);if(!e){l=n(),u=0,r="",a=0;continue e}l[t[u]]=e[1].replace(x,'"'),u++}else l[t[u]]=r,u++;r="",a=0}else o=i;0===a?(yield l,l=n(),u=0):o="\n"}}function E(e,t){const i=z(e,t).filter((e=>null!=e)),n=i.map((e=>$(e)));for(let e=n.length-1;e>=0;e--)n[e]||(n.splice(e,1),i.splice(e,1));return{names:n,aliases:i}}function z(e,t){if(!e?.length)return[];const i=[];let n="",s="",r=0;const o=w(e,t);for(const e of o)if(n+=s+e,s="",r+=T(e),r%2==0){if(r>0){const e=b.exec(n);e&&i.push(e[1].replace(x,'"'))}else i.push(n);n="",r=0}else s=t;return i}function T(e){let t=0,i=0;for(i=e.indexOf('"',i);i>=0;)t++,i=e.indexOf('"',i+1);return t}function M(e,t,i){t=$(t)?.toLowerCase(),i=$(i)?.toLowerCase();const n=e.map((e=>e.toLowerCase())),s=t?e[n.indexOf(t)]:null,r=i?e[n.indexOf(i)]:null;return{longitudeFieldName:s||e[n.indexOf(A.find((e=>n.includes(e))))],latitudeFieldName:r||e[n.indexOf(L.find((e=>n.includes(e))))]}}function C(e,t,i,n,s){const r=[],o=N(e,i,t),a=[];for(const e of o){if(10===a.length)break;a.push(e)}for(let e=0;e<i.length;e++){const t=i[e],o=n[e];if(t===s.longitudeFieldName||t===s.latitudeFieldName)r.push({name:t,type:"esriFieldTypeDouble",alias:o});else{let e,i;switch(B(a.map((e=>e[t])))){case"integer":e="esriFieldTypeInteger";break;case"double":e="esriFieldTypeDouble";break;case"date":e="esriFieldTypeDate",i=36;break;default:e="esriFieldTypeString",i=255}r.push({name:t,type:e,alias:o,length:i})}}return r}function B(e){if(!e.length)return"string";const t=/[^+-.,0-9]/;return e.map((e=>{let i=!1;if(""!==e){if(t.test(e))i=!0;else{let t=O(e);if(!isNaN(t))return/[.,]/.test(e)||!Number.isInteger(t)||t>214783647||t<-214783648?"double":"integer";if(e.includes("E")){if(t=Number(e),!isNaN(t))return"double";if(e.includes(",")){if(e=e.replace(",","."),t=Number(e),!isNaN(t))return"double";i=!0}else i=!0}else i=!0}return i?/^[-]?\d*[.,]?\d*$/.test(e)?"string":R(new Date(e),e)?"date":"string":"string"}})).reduce(((e,t)=>void 0===e?t:void 0===t?e:e===t?t:"string"===e||"string"===t?"string":"double"===e||"double"===t?"double":void 0))}function R(e,t){if(!e||"[object Date]"!==Object.prototype.toString.call(e)||isNaN(e.getTime()))return!1;let i=!0;if(!q&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,n=0;for(;!t&&n<=e.length;)t=!Z.test(e[n]),n++;i=!t}}return i}const O=function(){const e=(0,_.lt)(),t=new RegExp("^"+e.regexp+"$"),i=new RegExp("["+e.group+"\\s\\xa0]","g"),n=e.factor;return s=>{const r=t.exec(s);if(e.factor=n,!r)return NaN;let o=r[1];if(!r[1]){if(!r[2])return NaN;o=r[2],e.factor*=-1}return o=o.replace(i,"").replace(e.decimal,"."),+o*e.factor}}(),Z=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,q=Number.isNaN(new Date("technology 10").getTime()),L=["lat","latitude","latitude83","latdecdeg","lat_dd","y","ycenter","point_y"],A=["lon","lng","long","longitude","longitude83","longdecdeg","long_dd","x","xcenter","point_x"],k=/^([0-9])/,j=/[^A-Za-z0-9_\u0080-\uffff]/g,D=/_{2,}/g,P=/^_/,W=/_$/;function $(e){return e?e.trim().replace(j,"_").replace(D,"_").replace(P,"").replace(W,"").replace(k,"F$1"):null}var G=i(25278),J=i(99514),U=i(35671),H=i(82971);const Q=(0,G.bU)("esriGeometryPoint"),V=["csv"],X=[0,0];class Y{constructor(e,t){this.x=e,this.y=t}}class K{constructor(){this._queryEngine=null,this._snapshotFeatures=async e=>{const t=await this._fetch(e);return this._createFeatures(t)}}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t={}){this._loadOptions=e;const[i]=await Promise.all([this._fetch(t.signal),this._checkProjection(e?.parsingOptions?.spatialReference)]),n=function(e,t){const i=t.parsingOptions||{},n={delimiter:i.delimiter,layerDefinition:null,locationInfo:{latitudeFieldName:i.latitudeField,longitudeFieldName:i.longitudeField}},s=n.layerDefinition={name:(0,l.vt)(t.url,V)||"csv",drawingInfo:Q,geometryType:"esriGeometryPoint",objectIdField:null,fields:[],timeInfo:i.timeInfo,extent:{xmin:Number.POSITIVE_INFINITY,ymin:Number.POSITIVE_INFINITY,xmax:Number.NEGATIVE_INFINITY,ymax:Number.NEGATIVE_INFINITY,spatialReference:i.spatialReference||{wkid:102100}}},o=v(e),a=o.next().value?.trim(),u=o.next().value?.trim();if(!a)throw new r.Z("csv-layer:empty-csv","CSV is empty",{csv:e});const{delimiter:c,locationInfo:d}=F(a,u,i);if(!c)throw new r.Z("csv-layer:invalid-delimiter","Unable to detect the delimiter from CSV");if(!d)throw new r.Z("csv-layer:location-fields-not-found","Unable to identify latitude and longitude fields from the CSV file");n.locationInfo=d,n.delimiter=c;const{names:h,aliases:f}=E(a,c),p=C(e,n.delimiter,h,f,n.locationInfo);if(i.fields?.length){const e=new J.Z(i.fields);for(const t of p){const i=e.get(t.name);i&&Object.assign(t,i)}}if(s.fields=p,!s.fields.some((e=>"esriFieldTypeOID"===e.type&&(s.objectIdField=e.name,!0)))){const e={name:"__OBJECTID",alias:"__OBJECTID",type:"esriFieldTypeOID",editable:!1,nullable:!1};s.objectIdField=e.name,s.fields.unshift(e)}if(s.timeInfo){const e=new J.Z(s.fields),t=s.timeInfo;if(t.startTimeField){const i=e.get(t.startTimeField);i?(t.startTimeField=i.name,i.type="esriFieldTypeDate"):t.startTimeField=null}if(t.endTimeField){const i=e.get(t.endTimeField);i?(t.endTimeField=i.name,i.type="esriFieldTypeDate"):t.endTimeField=null}if(t.trackIdField){const i=e.get(t.trackIdField);t.trackIdField=i?i.name:null}t.startTimeField||t.endTimeField||(s.timeInfo=null)}return n}(i,e);this._locationInfo=n.locationInfo,this._delimiter=n.delimiter,this._queryEngine=this._createQueryEngine(n);const s=await this._createFeatures(i);if(this._queryEngine.featureStore.addMany(s),n.layerDefinition.extent=this._queryEngine.fullExtent,n.layerDefinition.timeInfo){const{start:e,end:t}=this._queryEngine.timeExtent;n.layerDefinition.timeInfo.timeExtent=[e,t]}return n}async applyEdits(){throw new r.Z("csv-layer:editing-not-supported","applyEdits() is not supported on CSVLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForIds(e,t.signal)}async queryExtent(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForExtent(e,t.signal)}async querySnapping(e,t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForSnapping(e,t.signal)}async refresh(e){return this._loadOptions.customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,s.vr)(this._snapshotFeatures),this._snapshotTask.promise.then((e=>{this._queryEngine.featureStore.clear(),e&&this._queryEngine.featureStore.addMany(e)}),(e=>{this._queryEngine.featureStore.clear(),(0,a.D_)(e)||o.Z.getLogger("esri.layers.CSVLayer").error(new r.Z("csv-layer:refresh","An error occurred during refresh",{error:e}))})),await this._waitSnapshotComplete(),{extent:this._queryEngine.fullExtent,timeExtent:this._queryEngine.timeExtent}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _fetch(e){const{url:t,customParameters:i}=this._loadOptions;if(!t)throw new r.Z("csv-layer:invalid-source","url not defined");const s=(0,l.mN)(t);return(await(0,n.default)(s.path,{query:{...s.query,...i},responseType:"text",signal:e})).data}_createQueryEngine(e){const{objectIdField:t,fields:i,extent:n,timeInfo:s}=e.layerDefinition,r=new m.Z({geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1});return new y.q({fields:i,geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1,timeInfo:s,objectIdField:t,spatialReference:n.spatialReference||{wkid:4326},cacheSpatialQueries:!0,featureStore:r})}async _createFeatures(e){const{latitudeFieldName:t,longitudeFieldName:i}=this._locationInfo,{objectIdField:n,fieldsIndex:s,spatialReference:r}=this._queryEngine;let o=[];const a=[],l=s.fields.filter((e=>e.name!==n)).map((e=>e.name));let m=0;const g={};for(const e of s.fields)if("esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type){const t=(0,U.os)(e);void 0!==t&&(g[e.name]=t)}const y=N(e,l,this._delimiter,(0,G.Dm)(g,n));for(const e of y){const r=this._parseCoordinateValue(e[t]),l=this._parseCoordinateValue(e[i]);if(null!=l&&null!=r&&!isNaN(r)&&!isNaN(l)){e[t]=r,e[i]=l;for(const n in e)if(n!==t&&n!==i)if(s.isDateField(n)){const t=new Date(e[n]);e[n]=R(t,e[n])?t.getTime():null}else if(s.isNumericField(n)){const t=O(e[n]);isNaN(t)?e[n]=null:e[n]=t}e[n]=m,m++,o.push(new Y(l,r)),a.push(e)}}if(!(0,d.fS)({wkid:4326},r))if((0,d.sS)(r))for(const e of o)[e.x,e.y]=(0,h.hG)(e.x,e.y,X);else o=(0,u.oj)(c.N,o,H.Z.WGS84,r,null,null);const _=[];for(let e=0;e<o.length;e++){const{x:t,y:i}=o[e],s=a[e];s[n]=e+1,_.push(new f.u_(new p.Z([],[t,i]),s,null,s[n]))}return _}_parseCoordinateValue(e){if(null==e||""===e)return null;let t=O(e);return(isNaN(t)||Math.abs(t)>181)&&(t=parseFloat(e)),t}async _checkProjection(e){try{await(0,g._W)(d.Zn,e)}catch{throw new r.Z("csv-layer:projection-not-supported","Projection not supported")}}}},25278:(e,t,i)=>{i.d(t,{Dm:()=>c,Hq:()=>d,MS:()=>h,bU:()=>a});var n=i(80442),s=i(22974),r=i(61159),o=i(58333);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.I4:"esriGeometryPolyline"===e?o.ET:o.lF}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function c(e,t){if((0,n.Z)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let i=`this.${t} = null;`;for(const t in e)i+=`this${l.test(t)?`.${t}`:`["${t}"]`} = ${JSON.stringify(e[t])};`;const n=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${i};\n }\n }\n `)();return()=>new n}catch(i){return()=>({[t]:null,...e})}}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,s.d9)(e)}}]}function h(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0},query:r.g,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1}}}},99514:(e,t,i)=>{i.d(t,{Z:()=>o});var n=i(35671);function s(e){return"oid"===e.type||"esriFieldTypeOID"===e.type}function r(e){return"global-id"===e.type||"esriFieldTypeGlobalID"===e.type}class o{constructor(e=[]){if(this.fields=[],this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this.dateFields=[],this.numericFields=[],this._requiredFields=null,!e)return;this.fields=e;const t=[];for(const o of e){const e=o&&o.name;if(e){const u=a(e),c=l(e);this._fieldsMap.set(e,o),this._fieldsMap.set(u,o),this._normalizedFieldsMap.set(c,o),t.push(u),"date"===(i=o).type||"esriFieldTypeDate"===i.type?(this.dateFields.push(o),this._dateFieldsSet.add(o)):(0,n.H7)(o)&&(this._numericFieldsSet.add(o),this.numericFields.push(o)),s(o)||r(o)||(o.editable=null==o.editable||!!o.editable,o.nullable=null==o.nullable||!!o.nullable)}}var i;t.sort(),this.uid=t.join(",")}destroy(){this._fieldsMap.clear()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)s(e)||r(e)||e.nullable||void 0!==(0,n.os)(e)||this._requiredFields.push(e)}return this._requiredFields}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(a(e))??this._normalizedFieldsMap.get(l(e)),t&&this._fieldsMap.set(e,t),t)}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){const t=this.get(e);if(t)return t.name??void 0}}function a(e){return e.trim().toLowerCase()}function l(e){return(0,n.q6)(e).toLowerCase()}},11282:(e,t,i)=>{i.d(t,{cv:()=>a,en:()=>o,lA:()=>r}),i(68773),i(40330);var n=i(22974),s=i(17452);function r(e,t){return t?{...t,query:{...e,...t.query}}:{query:e}}function o(e){return"string"==typeof e?(0,s.mN)(e):(0,n.d9)(e)}function a(e,t,i){const n={};for(const s in e){if("declaredClass"===s)continue;const r=e[s];if(null!=r&&"function"!=typeof r)if(Array.isArray(r)){n[s]=[];for(let e=0;e<r.length;e++)n[s][e]=a(r[e])}else if("object"==typeof r)if(r.toJSON){const e=r.toJSON(i&&i[s]);n[s]=t?e:JSON.stringify(e)}else n[s]=t?r:JSON.stringify(r);else n[s]=r}return n}i(71058)},58333:(e,t,i)=>{i.d(t,{ET:()=>r,I4:()=>s,eG:()=>l,lF:()=>o,lj:()=>c,qP:()=>a,wW:()=>u});const n=[252,146,31,255],s={type:"esriSMS",style:"esriSMSCircle",size:6,color:n,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},r={type:"esriSLS",style:"esriSLSSolid",width:.75,color:n},o={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},a={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},l={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},u={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},c={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7154,5732],{5732:(e,t,i)=>{i.d(t,{a:()=>r,c:()=>n,g:()=>s});var n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function s(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function r(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}},69801:(e,t,i)=>{i.d(t,{WJ:()=>l,Xq:()=>a});var n,s,r=i(70586),o=i(44553);(s=n||(n={}))[s.ALL=0]="ALL",s[s.SOME=1]="SOME";class a{constructor(e,t,i){this._namespace=e,this._storage=t,this._removeFunc=!1,this._hit=0,this._miss=0,this._storage.register(this),this._namespace+=":",i&&(this._storage.registerRemoveFunc(this._namespace,i),this._removeFunc=!0)}destroy(){this._storage.clear(this._namespace),this._removeFunc&&this._storage.deregisterRemoveFunc(this._namespace),this._storage.deregister(this),this._storage=null}get namespace(){return this._namespace.slice(0,-1)}get hitRate(){return this._hit/(this._hit+this._miss)}get size(){return this._storage.size}get maxSize(){return this._storage.maxSize}resetHitRate(){this._hit=this._miss=0}put(e,t,i,n=0){this._storage.put(this._namespace+e,t,i,n)}get(e){const t=this._storage.get(this._namespace+e);return void 0===t?++this._miss:++this._hit,t}pop(e){const t=this._storage.pop(this._namespace+e);return void 0===t?++this._miss:++this._hit,t}updateSize(e,t,i){this._storage.updateSize(this._namespace+e,t,i)}clear(){this._storage.clear(this._namespace)}clearAll(){this._storage.clearAll()}getStats(){return this._storage.getStats()}resetStats(){this._storage.resetStats()}}class l{constructor(e=10485760){this._maxSize=e,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._removeFuncs=new o.Z,this._users=new o.Z}destroy(){this.clearAll(),this._removeFuncs.clear(),this._users.clear(),this._db=null}register(e){this._users.push(e)}deregister(e){this._users.removeUnordered(e)}registerRemoveFunc(e,t){this._removeFuncs.push([e,t])}deregisterRemoveFunc(e){this._removeFuncs.filterInPlace((t=>t[0]!==e))}get size(){return this._size}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,0),this._checkSizeLimit()}put(e,t,i,s){const r=this._db.get(e);if(r&&(this._size-=r.size,this._db.delete(e),r.entry!==t&&this._notifyRemove(e,r.entry,n.ALL)),i>this._maxSize)return void this._notifyRemove(e,t,n.ALL);if(void 0===t)return void console.warn("Refusing to cache undefined entry ");if(!i||i<0)return void console.warn("Refusing to cache entry with invalid size "+i);const o=1+Math.max(s,-3)- -3;this._db.set(e,{entry:t,size:i,lifetime:o,lives:o}),this._size+=i,this._checkSizeLimit()}updateSize(e,t,i){const s=this._db.get(e);if(s&&s.entry===t){for(this._size-=s.size;i>this._maxSize;){const s=this._notifyRemove(e,t,n.SOME);if(!((0,r.pC)(s)&&s>0))return void this._db.delete(e);i=s}s.size=i,this._size+=i,this._checkSizeLimit()}}pop(e){const t=this._db.get(e);if(t)return this._size-=t.size,this._db.delete(e),++this._hit,t.entry;++this._miss}get(e){const t=this._db.get(e);if(void 0!==t)return this._db.delete(e),t.lives=t.lifetime,this._db.set(e,t),++this._hit,t.entry;++this._miss}getStats(){const e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},i=new Array;this._db.forEach(((e,n)=>{const s=e.lifetime;i[s]=(i[s]||0)+e.size,this._users.forAll((i=>{const s=i.namespace;if(n.startsWith(s)){const i=t[s]||0;t[s]=i+e.size}}))}));const n={};this._users.forAll((e=>{const i=e.namespace;if(!isNaN(e.hitRate)&&e.hitRate>0){const s=t[i]||0;t[i]=s,n[i]=Math.round(100*e.hitRate)+"%"}else n[i]="0%"}));const s=Object.keys(t);s.sort(((e,i)=>t[i]-t[e])),s.forEach((i=>e[i]=Math.round(t[i]/2**20)+"MB / "+n[i]));for(let t=i.length-1;t>=0;--t){const n=i[t];n&&(e["Priority "+(t+-3-1)]=Math.round(n/this.size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._users.forAll((e=>e.resetHitRate()))}clear(e){this._db.forEach(((t,i)=>{i.startsWith(e)&&(this._size-=t.size,this._db.delete(i),this._notifyRemove(i,t.entry,n.ALL))}))}clearAll(){this._db.forEach(((e,t)=>this._notifyRemove(t,e.entry,n.ALL))),this._size=0,this._db.clear()}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,i){let n;return this._removeFuncs.some((s=>{if(e.startsWith(s[0])){const e=s[1](t,i);return"number"==typeof e&&(n=e),!0}return!1})),n}_checkSizeLimit(){if(!(this._size<=this._maxSize))for(const[e,t]of this._db){if(this._db.delete(e),t.lives<=1){this._size-=t.size;const i=this._notifyRemove(e,t.entry,n.SOME);(0,r.pC)(i)&&i>0&&(this._size+=i,t.lives=t.lifetime,t.size=i,this._db.set(e,t))}else--t.lives,this._db.set(e,t);if(this._size<=.9*this.maxSize)return}}}},66643:(e,t,i)=>{i.d(t,{Ed:()=>u,UI:()=>c,mt:()=>p,q6:()=>f,vr:()=>m});var n=i(43697),s=i(15923),r=i(70586),o=i(95330),a=i(5600),l=(i(67676),i(75215),i(52011));function u(e,t,i){return(0,o.as)(e.map(((e,n)=>t.apply(i,[e,n]))))}async function c(e,t,i){return(await(0,o.as)(e.map(((e,n)=>t.apply(i,[e,n]))))).map((e=>e.value))}function d(e){return{ok:!0,value:e}}function h(e){return{ok:!1,error:e}}async function f(e){if((0,r.Wi)(e))return{ok:!1,error:new Error("no promise provided")};try{return d(await e)}catch(e){return h(e)}}async function p(e){try{return d(await e)}catch(e){return(0,o.r9)(e),h(e)}}function m(e,t){return new g(e,t)}let g=class extends s.Z{constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,r.IM)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:i}=this._abortController;this.promise=e(i),this.promise.then((e=>{this._result=d(e),this._cleanup()}),(e=>{this._result=h(e),this._cleanup()})),this._abortHandle=(0,o.fu)(t,this.abort)}get value(){return e=this._result,(0,r.pC)(e)&&!0===e.ok?e.value:null;var e}get error(){return e=this._result,(0,r.pC)(e)&&!1===e.ok?e.error:null;var e}get finished(){return(0,r.pC)(this._result)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,r.hw)(this._abortHandle),this._abortController=null}};(0,n._)([(0,a.Cb)()],g.prototype,"value",null),(0,n._)([(0,a.Cb)()],g.prototype,"error",null),(0,n._)([(0,a.Cb)()],g.prototype,"finished",null),(0,n._)([(0,a.Cb)()],g.prototype,"promise",void 0),(0,n._)([(0,a.Cb)()],g.prototype,"_result",void 0),g=(0,n._)([(0,l.j)("esri.core.asyncUtils.ReactiveTask")],g)},14808:(e,t,i)=>{i.d(t,{Qc:()=>c,WU:()=>a,lt:()=>u});var n=i(19153),s=i(70171);const r={ar:[".",","],bg:[","," "],bs:[",","."],ca:[",","."],cs:[","," "],da:[",","."],de:[",","."],"de-ch":[".","’"],el:[",","."],en:[".",","],"en-au":[".",","],es:[",","."],"es-mx":[".",","],et:[","," "],fi:[","," "],fr:[","," "],"fr-ch":[","," "],he:[".",","],hi:[".",",","#,##,##0.###"],hr:[",","."],hu:[","," "],id:[",","."],it:[",","."],"it-ch":[".","’"],ja:[".",","],ko:[".",","],lt:[","," "],lv:[","," "],mk:[",","."],nb:[","," "],nl:[",","."],pl:[","," "],pt:[",","."],"pt-pt":[","," "],ro:[",","."],ru:[","," "],sk:[","," "],sl:[",","."],sr:[",","."],sv:[","," "],th:[".",","],tr:[",","."],uk:[","," "],vi:[",","."],zh:[".",","]};function o(e){e||(e=(0,s.Kd)());let t=e in r;if(!t){const i=e.split("-");i.length>1&&i[0]in r&&(e=i[0],t=!0),t||(e="en")}const[i,n,o="#,##0.###"]=r[e];return{decimal:i,group:n,pattern:o}}function a(e,t){const i=o((t={...t}).locale);t.customs=i;const n=t.pattern||i.pattern;return isNaN(e)||Math.abs(e)===1/0?null:function(e,t,i){const n=(i=i||{}).customs.group,s=i.customs.decimal,r=t.split(";"),o=r[0];if((t=r[e<0?1:0]||"-"+o).includes("%"))e*=100;else if(t.includes("‰"))e*=1e3;else{if(t.includes("¤"))throw new Error("currency notation not supported");if(t.includes("E"))throw new Error("exponential notation not supported")}const a=l,u=o.match(a);if(!u)throw new Error("unable to find a number expression in pattern: "+t);return!1===i.fractional&&(i.places=0),t.replace(a,function(e,t,i){!0===(i=i||{}).places&&(i.places=0),i.places===1/0&&(i.places=6);const n=t.split("."),s="string"==typeof i.places&&i.places.indexOf(",");let r=i.places;s?r=i.places.substring(s+1):r>=0||(r=(n[1]||[]).length),i.round<0||(e=Number(e.toFixed(Number(r))));const o=String(Math.abs(e)).split("."),a=o[1]||"";if(n[1]||i.places){s&&(i.places=i.places.substring(0,s));const e=void 0!==i.places?i.places:n[1]&&n[1].lastIndexOf("0")+1;e>a.length&&(o[1]=a.padEnd(Number(e),"0")),r<a.length&&(o[1]=a.substr(0,Number(r)))}else o[1]&&o.pop();const l=n[0].replace(",","");let u=l.indexOf("0");-1!==u&&(u=l.length-u,u>o[0].length&&(o[0]=o[0].padStart(u,"0")),l.includes("#")||(o[0]=o[0].substr(o[0].length-u)));let c,d,h=n[0].lastIndexOf(",");if(-1!==h){c=n[0].length-h-1;const e=n[0].substr(0,h);h=e.lastIndexOf(","),-1!==h&&(d=e.length-h-1)}const f=[];for(let e=o[0];e;){const t=e.length-c;f.push(t>0?e.substr(t):e),e=t>0?e.slice(0,t):"",d&&(c=d,d=void 0)}return o[0]=f.reverse().join(i.group||","),o.join(i.decimal||".")}(e,u[0],{decimal:s,group:n,places:i.places,round:i.round}))}(e,n,t)}const l=/[#0,]*[#0](?:\.0*#*)?/;function u(e){const t=o((e=e||{}).locale),i=e.pattern||t.pattern,s=t.group,r=t.decimal;let a=1;if(i.includes("%"))a/=100;else if(i.includes("‰"))a/=1e3;else if(i.includes("¤"))throw new Error("currency notation not supported");const u=i.split(";");1===u.length&&u.push("-"+u[0]);const c=h(u,(t=>(t="(?:"+(0,n.Qs)(t,".")+")").replace(l,(t=>{const i={signed:!1,separator:e.strict?s:[s,""],fractional:e.fractional,decimal:r,exponent:!1},n=t.split(".");let o=e.places;1===n.length&&1!==a&&(n[1]="###"),1===n.length||0===o?i.fractional=!1:(void 0===o&&(o=e.pattern?n[1].lastIndexOf("0")+1:1/0),o&&null==e.fractional&&(i.fractional=!0),!e.places&&o<n[1].length&&(o+=","+n[1].length),i.places=o);const l=n[0].split(",");return l.length>1&&(i.groupSize=l.pop().length,l.length>1&&(i.groupSize2=l.pop().length)),"("+function(e){"places"in(e=e||{})||(e.places=1/0),"string"!=typeof e.decimal&&(e.decimal="."),"fractional"in e&&!/^0/.test(String(e.places))||(e.fractional=[!0,!1]),"exponent"in e||(e.exponent=[!0,!1]),"eSigned"in e||(e.eSigned=[!0,!1]);const t=d(e),i=h(e.fractional,(t=>{let i="";return t&&0!==e.places&&(i="\\"+e.decimal,e.places===1/0?i="(?:"+i+"\\d+)?":i+="\\d{"+e.places+"}"),i}),!0);let n=t+i;return i&&(n="(?:(?:"+n+")|(?:"+i+"))"),n+h(e.exponent,(t=>t?"([eE]"+d({signed:e.eSigned})+")":""))}(i)+")"}))),!0);return{regexp:c.replace(/[\xa0 ]/g,"[\\s\\xa0]"),group:s,decimal:r,factor:a}}function c(e,t){const i=u(t),n=new RegExp("^"+i.regexp+"$").exec(e);if(!n)return NaN;let s=n[1];if(!n[1]){if(!n[2])return NaN;s=n[2],i.factor*=-1}return s=s.replace(new RegExp("["+i.group+"\\s\\xa0]","g"),"").replace(i.decimal,"."),Number(s)*i.factor}function d(e){return"signed"in(e=e||{})||(e.signed=[!0,!1]),"separator"in e?"groupSize"in e||(e.groupSize=3):e.separator="",h(e.signed,(e=>e?"[-+]":""),!0)+h(e.separator,(t=>{if(!t)return"(?:\\d+)";" "===(t=(0,n.Qs)(t))?t="\\s":" "===t&&(t="\\s\\xa0");const i=e.groupSize,s=e.groupSize2;if(s){const e="(?:0|[1-9]\\d{0,"+(s-1)+"}(?:["+t+"]\\d{"+s+"})*["+t+"]\\d{"+i+"})";return i-s>0?"(?:"+e+"|(?:0|[1-9]\\d{0,"+(i-1)+"}))":e}return"(?:0|[1-9]\\d{0,"+(i-1)+"}(?:["+t+"]\\d{"+i+"})*)"}),!0)}const h=(e,t,i)=>{if(!(e instanceof Array))return t(e);const n=[];for(let i=0;i<e.length;i++)n.push(t(e[i]));return f(n.join("|"),Boolean(i))},f=(e,t)=>"("+(t?"?:":"")+e+")"},17445:(e,t,i)=>{i.d(t,{N1:()=>h,YP:()=>l,Z_:()=>m,gx:()=>u,nn:()=>g,on:()=>d,tX:()=>y});var n=i(91460),s=i(50758),r=i(70586),o=i(95330),a=i(26258);function l(e,t,i={}){return c(e,t,i,f)}function u(e,t,i={}){return c(e,t,i,p)}function c(e,t,i={},n){let s=null;const o=i.once?(e,i)=>{n(e)&&((0,r.hw)(s),t(e,i))}:(e,i)=>{n(e)&&t(e,i)};if(s=(0,a.aQ)(e,o,i.sync,i.equals),i.initial){const t=e();o(t,t)}return s}function d(e,t,i,o={}){let a=null,u=null,c=null;function d(){a&&u&&(u.remove(),o.onListenerRemove?.(a),a=null,u=null)}function h(e){o.once&&o.once&&(0,r.hw)(c),i(e)}const f=l(e,((e,i)=>{d(),(0,n.vT)(e)&&(a=e,u=(0,n.on)(e,t,h),o.onListenerAdd?.(e))}),{sync:o.sync,initial:!0});return c=(0,s.kB)((()=>{f.remove(),d()})),c}function h(e,t){return function(e,t,i){if((0,o.Hc)(i))return Promise.reject((0,o.zE)());const n=e();if(t?.(n))return Promise.resolve(n);let a=null;function l(){a=(0,r.hw)(a)}return new Promise(((n,r)=>{a=(0,s.AL)([(0,o.fu)(i,(()=>{l(),r((0,o.zE)())})),c(e,(e=>{l(),n(e)}),{sync:!1,once:!0},t??f)])}))}(e,p,t)}function f(e){return!0}function p(e){return!!e}i(87538);const m={sync:!0},g={initial:!0},y={sync:!0,initial:!0}},60437:(e,t,i)=>{i.d(t,{Gv:()=>_,HH:()=>a,JR:()=>m,TC:()=>l,Tn:()=>h,Ue:()=>r,al:()=>o,cS:()=>p,dp:()=>c,fS:()=>y,op:()=>d,pp:()=>u,t8:()=>f});var n=i(70586),s=i(6570);function r(e=b){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function o(e,t,i,n,s,o,a=r()){return a[0]=e,a[1]=t,a[2]=i,a[3]=n,a[4]=s,a[5]=o,a}function a(e,t){const i=isFinite(e[2])||isFinite(e[5]);return new s.Z(i?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function l(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}function u(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}function c(e,t=[0,0,0]){return t[0]=function(e){return e[0]>=e[3]?0:e[3]-e[0]}(e),t[1]=function(e){return e[1]>=e[4]?0:e[4]-e[1]}(e),t[2]=function(e){return e[2]>=e[5]?0:e[5]-e[2]}(e),t}function d(e,t,i=e){return i[0]=t[0],i[1]=t[1],i[2]=t[2],i!==e&&(i[3]=e[3],i[4]=e[4],i[5]=e[5]),i}function h(e,t,i=e){return i[3]=t[0],i[4]=t[1],i[5]=t[2],i!==e&&(i[0]=e[0],i[1]=e[1],i[2]=e[2]),e}function f(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function p(e){return e?f(e,_):r(_)}function m(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function g(e){return 6===e.length}function y(e,t,i){if((0,n.Wi)(e)||(0,n.Wi)(t))return e===t;if(!g(e)||!g(t))return!1;if(i){for(let n=0;n<e.length;n++)if(!i(e[n],t[n]))return!1}else for(let i=0;i<e.length;i++)if(e[i]!==t[i])return!1;return!0}i(24470);const _=[1/0,1/0,1/0,-1/0,-1/0,-1/0],b=[0,0,0,0,0,0];r()},51806:(e,t,i)=>{i.d(t,{aX:()=>N});var n=i(68773),s=i(20102),r=i(92604),o=i(70586),a=i(38913),l=i(58901),u=i(82971),c=i(33955);const d={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new l.Z({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:u.Z.WebMercator}),minus180Line:new l.Z({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:u.Z.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new l.Z({paths:[[[180,-180],[180,180]]],spatialReference:u.Z.WGS84}),minus180Line:new l.Z({paths:[[[-180,-180],[-180,180]]],spatialReference:u.Z.WGS84})}};function h(e,t){return Math.ceil((e-t)/(2*t))}function f(e,t){const i=p(e);for(const e of i)for(const i of e)i[0]+=t;return e}function p(e){return(0,c.oU)(e)?e.rings:e.paths}var m=i(8744),g=i(40488),y=(i(66577),i(3172)),_=i(11282),b=i(17452);const x=r.Z.getLogger("esri.geometry.support.normalizeUtils");function S(e){return"polygon"===e[0].type}function I(e){return"polyline"===e[0].type}function v(e,t,i){if(t){const t=function(e,t){if(!(e instanceof l.Z||e instanceof a.Z)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw x.error(e),new s.Z(e)}const i=p(e),n=[];for(const e of i){const i=[];n.push(i),i.push([e[0][0],e[0][1]]);for(let n=0;n<e.length-1;n++){const s=e[n][0],r=e[n][1],o=e[n+1][0],a=e[n+1][1],l=Math.sqrt((o-s)*(o-s)+(a-r)*(a-r)),u=(a-r)/l,c=(o-s)/l,d=l/t;if(d>1){for(let e=1;e<=d-1;e++){const n=e*t,o=c*n+s,a=u*n+r;i.push([o,a])}const e=(l+Math.floor(d-1)*t)/2,n=c*e+s,o=u*e+r;i.push([n,o])}i.push([o,a])}}return function(e){return"polygon"===e.type}(e)?new a.Z({rings:n,spatialReference:e.spatialReference}):new l.Z({paths:n,spatialReference:e.spatialReference})}(e,1e6);e=(0,g.Sx)(t,!0)}return i&&(e=f(e,i)),e}function w(e,t,i){if(Array.isArray(e)){const n=e[0];if(n>t){const i=h(n,t);e[0]=n+i*(-2*t)}else if(n<i){const t=h(n,i);e[0]=n+t*(-2*i)}}else{const n=e.x;if(n>t){const i=h(n,t);e=e.clone().offset(i*(-2*t),0)}else if(n<i){const t=h(n,i);e=e.clone().offset(t*(-2*i),0)}}return e}function F(e,t){let i=-1;for(let n=0;n<t.cutIndexes.length;n++){const s=t.cutIndexes[n],r=t.geometries[n],o=p(r);for(let e=0;e<o.length;e++){const t=o[e];t.some((i=>{if(i[0]<180)return!0;{let i=0;for(let e=0;e<t.length;e++){const n=t[e][0];i=n>i?n:i}i=Number(i.toFixed(9));const n=-360*h(i,180);for(let i=0;i<t.length;i++){const t=r.getPoint(e,i);r.setPoint(e,i,t.clone().offset(n,0))}return!0}}))}if(s===i){if(S(e))for(const t of p(r))e[s]=e[s].addRing(t);else if(I(e))for(const t of p(r))e[s]=e[s].addPath(t)}else i=s,e[s]=r}return e}async function N(e,t,i){if(!Array.isArray(e))return N([e],t);t&&"string"!=typeof t&&x.warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const s="string"==typeof t?t:t?.url??n.Z.geometryServiceUrl;let r,u,p,S,I,E,z,T,M=0;const C=[],B=[];for(const t of e)if((0,o.Wi)(t))B.push(t);else if(r||(r=t.spatialReference,u=(0,m.C5)(r),p=r.isWebMercator,E=p?102100:4326,S=d[E].maxX,I=d[E].minX,z=d[E].plus180Line,T=d[E].minus180Line),u)if("mesh"===t.type)B.push(t);else if("point"===t.type)B.push(w(t.clone(),S,I));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>w(e,S,I))),B.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,u);B.push(e.rings?new a.Z(e):e)}else if(t.extent){const e=t.extent,i=h(e.xmin,I)*(2*S);let n=0===i?t.clone():f(t.clone(),i);e.offset(i,0),e.intersects(z)&&e.xmax!==S?(M=e.xmax>M?e.xmax:M,n=v(n,p),C.push(n),B.push("cut")):e.intersects(T)&&e.xmin!==I?(M=e.xmax*(2*S)>M?e.xmax*(2*S):M,n=v(n,p,360),C.push(n),B.push("cut")):B.push(n)}else B.push(t.clone());else B.push(t);let R=h(M,S),O=-90;const L=R,Z=new l.Z;for(;R>0;){const e=360*R-180;Z.addPath([[e,O],[e,-1*O]]),O*=-1,R--}if(C.length>0&&L>0){const t=F(C,await async function(e,t,i,n){const s=(0,_.en)(e),r=t[0].spatialReference,o={...n,query:{...s.query,f:"json",sr:JSON.stringify(r),target:JSON.stringify({geometryType:(0,c.Ji)(t[0]),geometries:t}),cutter:JSON.stringify(i)}},a=await(0,y.default)(s.path+"/cut",o),{cutIndexes:l,geometries:u=[]}=a.data;return{cutIndexes:l,geometries:u.map((e=>{const t=(0,c.im)(e);return t.spatialReference=r,t}))}}(s,C,Z,i)),n=[],r=[];for(let i=0;i<B.length;i++){const s=B[i];if("cut"!==s)r.push(s);else{const s=t.shift(),a=e[i];(0,o.pC)(a)&&"polygon"===a.type&&a.rings&&a.rings.length>1&&s.rings.length>=a.rings.length?(n.push(s),r.push("simplify")):r.push(p?(0,g.$)(s):s)}}if(!n.length)return r;const a=await async function(e,t,i){const n="string"==typeof e?(0,b.mN)(e):e,s=t[0].spatialReference,r=(0,c.Ji)(t[0]),o={...i,query:{...n.query,f:"json",sr:s.wkid?s.wkid:JSON.stringify(s),geometries:JSON.stringify((l=t,{geometryType:(0,c.Ji)(l[0]),geometries:l.map((e=>e.toJSON()))}))}},{data:a}=await(0,y.default)(n.path+"/simplify",o);var l;return function(e,t,i){const n=(0,c.q9)(t);return e.map((e=>{const t=n.fromJSON(e);return t.spatialReference=i,t}))}(a.geometries,r,s)}(s,n,i),l=[];for(let e=0;e<r.length;e++){const t=r[e];"simplify"!==t?l.push(t):l.push(p?(0,g.$)(a.shift()):a.shift())}return l}const q=[];for(let e=0;e<B.length;e++){const t=B[e];if("cut"!==t)q.push(t);else{const e=C.shift();q.push(!0===p?(0,g.$)(e):e)}}return q}},70171:(e,t,i)=>{let n;i.d(t,{Kd:()=>o,Ze:()=>c,qe:()=>l});const s=globalThis.esriConfig?.locale??globalThis.dojoConfig?.locale;function r(){return s??globalThis.navigator?.language??"en"}function o(){return void 0===n&&(n=r()),n}const a=[];function l(e){return a.push(e),{remove(){a.splice(a.indexOf(e),1)}}}const u=[];function c(e){return u.push(e),{remove(){a.splice(u.indexOf(e),1)}}}globalThis.addEventListener?.("languagechange",(function(){const e=r();n!==e&&(n=e,[...u].forEach((t=>{t.call(null,e)})),[...a].forEach((t=>{t.call(null,e)})))}))},37549:(e,t,i)=>{i.d(t,{H:()=>a});var n=i(80442),s=i(24133),r=i(24470);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new s.Q(9,(0,n.Z)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((i,n)=>{e[t++]=n})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,r.cS)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,i){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,i)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},57191:(e,t,i)=>{i.d(t,{Z:()=>m});var n=i(20102),s=i(32448),r=i(92604),o=i(70586),a=i(60437),l=i(24470),u=i(98732),c=i(37549),d=i(29730),h=i(70272),f=i(5428);const p={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new h.u_(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>((0,o.Wi)(e.centroid)&&(e.centroid=(0,d.Y)(new f.Z,e.geometry,t.hasZ,t.hasM)),e.centroid)};class m{constructor(e){this.geometryInfo=e,this._boundsStore=new c.H,this._featuresById=new Map,this._markedIds=new Set,this.events=new s.Z,this.featureAdapter=p}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach((t=>{(0,o.pC)(t.geometry)&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t,i){for(const n of e){const e=this._boundsStore.get(n.objectId);e&&t((0,a.JR)(i,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}toArray(){return Array.from(this._featuresById.values())}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}startMarkingUsedFeatures(){this._boundsStore.invalidateIndex(),this._markedIds.clear()}sweep(){let e=!1;this._featuresById.forEach(((t,i)=>{this._markedIds.has(i)||(e=!0,this._remove(t))})),this._markedIds.clear(),e&&this._emitChanged()}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void r.Z.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.Z("featurestore:invalid-feature","feature id is missing",{feature:e}));const i=this._featuresById.get(t);let s;if(this._markedIds.add(t),i?(e.displayId=i.displayId,s=this._boundsStore.get(t),this._boundsStore.delete(t)):(0,o.pC)(this.onFeatureAdd)&&this.onFeatureAdd(e),(0,o.Wi)(e.geometry)||!e.geometry.coords||!e.geometry.coords.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);s=(0,u.$)((0,o.pC)(s)?s:(0,l.Ue)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),(0,o.pC)(s)&&this._boundsStore.set(t,s),this._featuresById.set(t,e)}_remove(e){return(0,o.pC)(this.onFeatureRemove)&&this.onFeatureRemove(e),this._markedIds.delete(e.objectId),this._boundsStore.delete(e.objectId),this._featuresById.delete(e.objectId),e}}},27793:(e,t,i)=>{i.r(t),i.d(t,{default:()=>K}),i(66577);var n=i(3172),s=i(66643),r=i(20102),o=i(92604),a=i(95330),l=i(17452),u=i(44547),c=i(37455),d=i(8744),h=i(40488),f=i(70272),p=i(5428),m=i(57191),g=i(37427),y=i(50245),_=i(14808);const b=/^\s*"([\S\s]*)"\s*$/,x=/""/g,S=[","," ",";","|","\t"];function*I(e,t,i){let n=0;for(;n<=e.length;){const s=e.indexOf(t,n),r=e.substring(n,s>-1?s:void 0);n+=r.length+t.length,i&&!r.trim()||(yield r)}}function v(e){const t=e.includes("\r\n")?"\r\n":"\n";return I(e,t,!0)}function w(e,t){return I(e,t,!1)}function F(e,t,i){e=e.trim(),t=t?.trim();const n=[],s=Array.from(new Set([i?.delimiter,...S])).filter((e=>null!=e));for(const i of s){const s=z(e,i).length,r=z(t,i).length??s;s>1&&n.push({weight:Math.min(s,r),delimiter:i})}const r=n.sort((({weight:e},{weight:t})=>t-e)).map((({delimiter:e})=>e));for(const t of r){const n=M(E(e,t).names,i?.longitudeField,i?.latitudeField);if(n.longitudeFieldName&&n.latitudeFieldName)return{delimiter:t,locationInfo:n}}return{delimiter:r[0],locationInfo:null}}function*N(e,t,i,n=(()=>Object.create(null))){const s=v(e);s.next();let r="",o="",a=0,l=n(),u=0;e:for(const e of s){const s=w(e,i);for(const e of s)if(r+=o+e,o="",a+=T(e),a%2==0){if(a>0){const e=b.exec(r);if(!e){l=n(),u=0,r="",a=0;continue e}l[t[u]]=e[1].replace(x,'"'),u++}else l[t[u]]=r,u++;r="",a=0}else o=i;0===a?(yield l,l=n(),u=0):o="\n"}}function E(e,t){const i=z(e,t).filter((e=>null!=e)),n=i.map((e=>$(e)));for(let e=n.length-1;e>=0;e--)n[e]||(n.splice(e,1),i.splice(e,1));return{names:n,aliases:i}}function z(e,t){if(!e?.length)return[];const i=[];let n="",s="",r=0;const o=w(e,t);for(const e of o)if(n+=s+e,s="",r+=T(e),r%2==0){if(r>0){const e=b.exec(n);e&&i.push(e[1].replace(x,'"'))}else i.push(n);n="",r=0}else s=t;return i}function T(e){let t=0,i=0;for(i=e.indexOf('"',i);i>=0;)t++,i=e.indexOf('"',i+1);return t}function M(e,t,i){t=$(t)?.toLowerCase(),i=$(i)?.toLowerCase();const n=e.map((e=>e.toLowerCase())),s=t?e[n.indexOf(t)]:null,r=i?e[n.indexOf(i)]:null;return{longitudeFieldName:s||e[n.indexOf(A.find((e=>n.includes(e))))],latitudeFieldName:r||e[n.indexOf(q.find((e=>n.includes(e))))]}}function C(e,t,i,n,s){const r=[],o=N(e,i,t),a=[];for(const e of o){if(10===a.length)break;a.push(e)}for(let e=0;e<i.length;e++){const t=i[e],o=n[e];if(t===s.longitudeFieldName||t===s.latitudeFieldName)r.push({name:t,type:"esriFieldTypeDouble",alias:o});else{let e,i;switch(B(a.map((e=>e[t])))){case"integer":e="esriFieldTypeInteger";break;case"double":e="esriFieldTypeDouble";break;case"date":e="esriFieldTypeDate",i=36;break;default:e="esriFieldTypeString",i=255}r.push({name:t,type:e,alias:o,length:i})}}return r}function B(e){if(!e.length)return"string";const t=/[^+-.,0-9]/;return e.map((e=>{let i=!1;if(""!==e){if(t.test(e))i=!0;else{let t=O(e);if(!isNaN(t))return/[.,]/.test(e)||!Number.isInteger(t)||t>214783647||t<-214783648?"double":"integer";if(e.includes("E")){if(t=Number(e),!isNaN(t))return"double";if(e.includes(",")){if(e=e.replace(",","."),t=Number(e),!isNaN(t))return"double";i=!0}else i=!0}else i=!0}return i?/^[-]?\d*[.,]?\d*$/.test(e)?"string":R(new Date(e),e)?"date":"string":"string"}})).reduce(((e,t)=>void 0===e?t:void 0===t?e:e===t?t:"string"===e||"string"===t?"string":"double"===e||"double"===t?"double":void 0))}function R(e,t){if(!e||"[object Date]"!==Object.prototype.toString.call(e)||isNaN(e.getTime()))return!1;let i=!0;if(!Z&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,n=0;for(;!t&&n<=e.length;)t=!L.test(e[n]),n++;i=!t}}return i}const O=function(){const e=(0,_.lt)(),t=new RegExp("^"+e.regexp+"$"),i=new RegExp("["+e.group+"\\s\\xa0]","g"),n=e.factor;return s=>{const r=t.exec(s);if(e.factor=n,!r)return NaN;let o=r[1];if(!r[1]){if(!r[2])return NaN;o=r[2],e.factor*=-1}return o=o.replace(i,"").replace(e.decimal,"."),+o*e.factor}}(),L=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,Z=Number.isNaN(new Date("technology 10").getTime()),q=["lat","latitude","latitude83","latdecdeg","lat_dd","y","ycenter","point_y"],A=["lon","lng","long","longitude","longitude83","longdecdeg","long_dd","x","xcenter","point_x"],k=/^([0-9])/,j=/[^A-Za-z0-9_\u0080-\uffff]/g,D=/_{2,}/g,P=/^_/,W=/_$/;function $(e){return e?e.trim().replace(j,"_").replace(D,"_").replace(P,"").replace(W,"").replace(k,"F$1"):null}var G=i(25278),J=i(99514),U=i(35671),H=i(82971);const Q=(0,G.bU)("esriGeometryPoint"),V=["csv"],X=[0,0];class Y{constructor(e,t){this.x=e,this.y=t}}class K{constructor(){this._queryEngine=null,this._snapshotFeatures=async e=>{const t=await this._fetch(e);return this._createFeatures(t)}}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t={}){this._loadOptions=e;const[i]=await Promise.all([this._fetch(t.signal),this._checkProjection(e?.parsingOptions?.spatialReference)]),n=function(e,t){const i=t.parsingOptions||{},n={delimiter:i.delimiter,layerDefinition:null,locationInfo:{latitudeFieldName:i.latitudeField,longitudeFieldName:i.longitudeField}},s=n.layerDefinition={name:(0,l.vt)(t.url,V)||"csv",drawingInfo:Q,geometryType:"esriGeometryPoint",objectIdField:null,fields:[],timeInfo:i.timeInfo,extent:{xmin:Number.POSITIVE_INFINITY,ymin:Number.POSITIVE_INFINITY,xmax:Number.NEGATIVE_INFINITY,ymax:Number.NEGATIVE_INFINITY,spatialReference:i.spatialReference||{wkid:102100}}},o=v(e),a=o.next().value?.trim(),u=o.next().value?.trim();if(!a)throw new r.Z("csv-layer:empty-csv","CSV is empty",{csv:e});const{delimiter:c,locationInfo:d}=F(a,u,i);if(!c)throw new r.Z("csv-layer:invalid-delimiter","Unable to detect the delimiter from CSV",{firstLine:a,secondLine:u,parsingOptions:i});if(!d)throw new r.Z("csv-layer:location-fields-not-found","Unable to identify latitude and longitude fields from the CSV file",{firstLine:a,secondLine:u,parsingOptions:i});n.locationInfo=d,n.delimiter=c;const{names:h,aliases:f}=E(a,c),p=C(e,n.delimiter,h,f,n.locationInfo);if(i.fields?.length){const e=new J.Z(i.fields);for(const t of p){const i=e.get(t.name);i&&Object.assign(t,i)}}if(!p.some((e=>"esriFieldTypeOID"===e.type&&(s.objectIdField=e.name,!0)))){const e={name:"__OBJECTID",alias:"__OBJECTID",type:"esriFieldTypeOID",editable:!1,nullable:!1};s.objectIdField=e.name,p.unshift(e)}s.fields=p;const m=new J.Z(s.fields);if(n.locationInfo&&(n.locationInfo.latitudeFieldName=m.get(n.locationInfo.latitudeFieldName).name,n.locationInfo.longitudeFieldName=m.get(n.locationInfo.longitudeFieldName).name),s.timeInfo){const e=s.timeInfo;if(e.startTimeField){const t=m.get(e.startTimeField);t?(e.startTimeField=t.name,t.type="esriFieldTypeDate"):e.startTimeField=null}if(e.endTimeField){const t=m.get(e.endTimeField);t?(e.endTimeField=t.name,t.type="esriFieldTypeDate"):e.endTimeField=null}if(e.trackIdField){const t=m.get(e.trackIdField);e.trackIdField=t?t.name:null}e.startTimeField||e.endTimeField||(s.timeInfo=null)}return n}(i,e);this._locationInfo=n.locationInfo,this._delimiter=n.delimiter,this._queryEngine=this._createQueryEngine(n);const s=await this._createFeatures(i);if(this._queryEngine.featureStore.addMany(s),n.layerDefinition.extent=this._queryEngine.fullExtent,n.layerDefinition.timeInfo){const{start:e,end:t}=this._queryEngine.timeExtent;n.layerDefinition.timeInfo.timeExtent=[e,t]}return n}async applyEdits(){throw new r.Z("csv-layer:editing-not-supported","applyEdits() is not supported on CSVLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForIds(e,t.signal)}async queryExtent(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForExtent(e,t.signal)}async querySnapping(e,t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForSnapping(e,t.signal)}async refresh(e){return this._loadOptions.customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,s.vr)(this._snapshotFeatures),this._snapshotTask.promise.then((e=>{this._queryEngine.featureStore.clear(),e&&this._queryEngine.featureStore.addMany(e)}),(e=>{this._queryEngine.featureStore.clear(),(0,a.D_)(e)||o.Z.getLogger("esri.layers.CSVLayer").error(new r.Z("csv-layer:refresh","An error occurred during refresh",{error:e}))})),await this._waitSnapshotComplete(),{extent:this._queryEngine.fullExtent,timeExtent:this._queryEngine.timeExtent}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _fetch(e){const{url:t,customParameters:i}=this._loadOptions;if(!t)throw new r.Z("csv-layer:invalid-source","url not defined");const s=(0,l.mN)(t);return(await(0,n.default)(s.path,{query:{...s.query,...i},responseType:"text",signal:e})).data}_createQueryEngine(e){const{objectIdField:t,fields:i,extent:n,timeInfo:s}=e.layerDefinition,r=new m.Z({geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1});return new y.q({fields:i,geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1,timeInfo:s,objectIdField:t,spatialReference:n.spatialReference||{wkid:4326},cacheSpatialQueries:!0,featureStore:r})}async _createFeatures(e){const{latitudeFieldName:t,longitudeFieldName:i}=this._locationInfo,{objectIdField:n,fieldsIndex:s,spatialReference:r}=this._queryEngine;let o=[];const a=[],l=s.fields.filter((e=>e.name!==n)).map((e=>e.name));let m=0;const g={};for(const e of s.fields)if("esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type){const t=(0,U.os)(e);void 0!==t&&(g[e.name]=t)}const y=N(e,l,this._delimiter,(0,G.Dm)(g,n));for(const e of y){const r=this._parseCoordinateValue(e[t]),l=this._parseCoordinateValue(e[i]);if(null!=l&&null!=r&&!isNaN(r)&&!isNaN(l)){e[t]=r,e[i]=l;for(const n in e)if(n!==t&&n!==i)if(s.isDateField(n)){const t=new Date(e[n]);e[n]=R(t,e[n])?t.getTime():null}else if(s.isNumericField(n)){const t=O(e[n]);isNaN(t)?e[n]=null:e[n]=t}e[n]=m,m++,o.push(new Y(l,r)),a.push(e)}}if(!(0,d.fS)({wkid:4326},r))if((0,d.sS)(r))for(const e of o)[e.x,e.y]=(0,h.hG)(e.x,e.y,X);else o=(0,u.oj)(c.N,o,H.Z.WGS84,r,null,null);const _=[];for(let e=0;e<o.length;e++){const{x:t,y:i}=o[e],s=a[e];s[n]=e+1,_.push(new f.u_(new p.Z([],[t,i]),s,null,s[n]))}return _}_parseCoordinateValue(e){if(null==e||""===e)return null;let t=O(e);return(isNaN(t)||Math.abs(t)>181)&&(t=parseFloat(e)),t}async _checkProjection(e){try{await(0,g._W)(d.Zn,e)}catch{throw new r.Z("csv-layer:projection-not-supported","Projection not supported")}}}},25278:(e,t,i)=>{i.d(t,{Dm:()=>c,Hq:()=>d,MS:()=>h,bU:()=>a});var n=i(80442),s=i(22974),r=i(61159),o=i(58333);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.I4:"esriGeometryPolyline"===e?o.ET:o.lF}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function c(e,t){if((0,n.Z)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let i=`this.${t} = null;`;for(const t in e)i+=`this${l.test(t)?`.${t}`:`["${t}"]`} = ${JSON.stringify(e[t])};`;const n=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${i};\n }\n }\n `)();return()=>new n}catch(i){return()=>({[t]:null,...e})}}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,s.d9)(e)}}]}function h(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0},query:r.g,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1}}}},99514:(e,t,i)=>{i.d(t,{Z:()=>o});var n=i(35671);function s(e){return"oid"===e.type||"esriFieldTypeOID"===e.type}function r(e){return"global-id"===e.type||"esriFieldTypeGlobalID"===e.type}class o{constructor(e=[]){if(this.fields=[],this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this.dateFields=[],this.numericFields=[],this._requiredFields=null,!e)return;this.fields=e;const t=[];for(const o of e){const e=o&&o.name;if(e){const u=a(e),c=l(e);this._fieldsMap.set(e,o),this._fieldsMap.set(u,o),this._normalizedFieldsMap.set(c,o),t.push(u),"date"===(i=o).type||"esriFieldTypeDate"===i.type?(this.dateFields.push(o),this._dateFieldsSet.add(o)):(0,n.H7)(o)&&(this._numericFieldsSet.add(o),this.numericFields.push(o)),s(o)||r(o)||(o.editable=null==o.editable||!!o.editable,o.nullable=null==o.nullable||!!o.nullable)}}var i;t.sort(),this.uid=t.join(",")}destroy(){this._fieldsMap.clear()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)s(e)||r(e)||e.nullable||void 0!==(0,n.os)(e)||this._requiredFields.push(e)}return this._requiredFields}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(a(e))??this._normalizedFieldsMap.get(l(e)),t&&this._fieldsMap.set(e,t),t)}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){const t=this.get(e);if(t)return t.name??void 0}}function a(e){return e.trim().toLowerCase()}function l(e){return(0,n.q6)(e).toLowerCase()}},11282:(e,t,i)=>{i.d(t,{cv:()=>a,en:()=>o,lA:()=>r}),i(68773),i(40330);var n=i(22974),s=i(17452);function r(e,t){return t?{...t,query:{...e,...t.query}}:{query:e}}function o(e){return"string"==typeof e?(0,s.mN)(e):(0,n.d9)(e)}function a(e,t,i){const n={};for(const s in e){if("declaredClass"===s)continue;const r=e[s];if(null!=r&&"function"!=typeof r)if(Array.isArray(r)){n[s]=[];for(let e=0;e<r.length;e++)n[s][e]=a(r[e])}else if("object"==typeof r)if(r.toJSON){const e=r.toJSON(i&&i[s]);n[s]=t?e:JSON.stringify(e)}else n[s]=t?r:JSON.stringify(r);else n[s]=r}return n}i(71058)},58333:(e,t,i)=>{i.d(t,{ET:()=>r,I4:()=>s,eG:()=>l,lF:()=>o,lj:()=>c,qP:()=>a,wW:()=>u});const n=[252,146,31,255],s={type:"esriSMS",style:"esriSMSCircle",size:6,color:n,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},r={type:"esriSLS",style:"esriSLSSolid",width:.75,color:n},o={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},a={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},l={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},u={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},c={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9956,4202,8694,3492],{3920:(e,t,r)=>{r.d(t,{p:()=>p,r:()=>u});var i=r(43697),n=r(15923),o=r(61247),s=r(5600),l=r(52011),a=r(72762);const p=e=>{let t=class extends e{destroy(){this.destroyed||(this._get("handles")?.destroy(),this._get("updatingHandles")?.destroy())}get handles(){return this._get("handles")||new o.Z}get updatingHandles(){return this._get("updatingHandles")||new a.t}};return(0,i._)([(0,s.Cb)({readOnly:!0})],t.prototype,"handles",null),(0,i._)([(0,s.Cb)({readOnly:!0})],t.prototype,"updatingHandles",null),t=(0,i._)([(0,l.j)("esri.core.HandleOwner")],t),t};let u=class extends(p(n.Z)){};u=(0,i._)([(0,l.j)("esri.core.HandleOwner")],u)},42033:(e,t,r)=>{r.d(t,{E:()=>n,_:()=>o});var i=r(70586);async function n(e,t){const{WhereClause:i}=await r.e(1534).then(r.bind(r,41534));return i.create(e,t)}function o(e,t){return(0,i.pC)(e)?(0,i.pC)(t)?`(${e}) AND (${t})`:e:t}},72762:(e,t,r)=>{r.d(t,{t:()=>y});var i=r(43697),n=r(15923),o=r(61247),s=r(70586),l=r(17445),a=r(1654),p=r(5600),u=r(52011);let y=class extends n.Z{constructor(){super(...arguments),this.updating=!1,this._handleId=0,this._handles=new o.Z,this._scheduleHandleId=0,this._pendingPromises=new Set}destroy(){this.removeAll(),this._handles.destroy()}add(e,t,r={}){return this._installWatch(e,t,r,l.YP)}addWhen(e,t,r={}){return this._installWatch(e,t,r,l.gx)}addOnCollectionChange(e,t,{initial:r=!1,final:i=!1}={}){const n=++this._handleId;return this._handles.add([(0,l.on)(e,"after-changes",this._createSyncUpdatingCallback(),l.Z_),(0,l.on)(e,"change",t,{onListenerAdd:r?e=>t({added:e.toArray(),removed:[]}):void 0,onListenerRemove:i?e=>t({added:[],removed:e.toArray()}):void 0})],n),{remove:()=>this._handles.remove(n)}}addPromise(e){if((0,s.Wi)(e))return e;const t=++this._handleId;this._handles.add({remove:()=>{this._pendingPromises.delete(e)&&(0!==this._pendingPromises.size||this._handles.has(d)||this._set("updating",!1))}},t),this._pendingPromises.add(e),this._set("updating",!0);const r=()=>this._handles.remove(t);return e.then(r,r),e}removeAll(){this._pendingPromises.clear(),this._handles.removeAll(),this._set("updating",!1)}_installWatch(e,t,r={},i){const n=++this._handleId;r.sync||this._installSyncUpdatingWatch(e,n);const o=i(e,t,r);return this._handles.add(o,n),{remove:()=>this._handles.remove(n)}}_installSyncUpdatingWatch(e,t){const r=this._createSyncUpdatingCallback(),i=(0,l.YP)(e,r,{sync:!0,equals:()=>!1});return this._handles.add(i,t),i}_createSyncUpdatingCallback(){return()=>{this._handles.remove(d),++this._scheduleHandleId;const e=this._scheduleHandleId;this._get("updating")||this._set("updating",!0),this._handles.add((0,a.Os)((()=>{e===this._scheduleHandleId&&(this._set("updating",this._pendingPromises.size>0),this._handles.remove(d))})),d)}}};(0,i._)([(0,p.Cb)({readOnly:!0})],y.prototype,"updating",void 0),y=(0,i._)([(0,u.j)("esri.core.support.WatchUpdatingTracking")],y);const d=-42},51806:(e,t,r)=>{r.d(t,{aX:()=>N});var i=r(68773),n=r(20102),o=r(92604),s=r(70586),l=r(38913),a=r(58901),p=r(82971),u=r(33955);const y={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new a.Z({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:p.Z.WebMercator}),minus180Line:new a.Z({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:p.Z.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new a.Z({paths:[[[180,-180],[180,180]]],spatialReference:p.Z.WGS84}),minus180Line:new a.Z({paths:[[[-180,-180],[-180,180]]],spatialReference:p.Z.WGS84})}};function d(e,t){return Math.ceil((e-t)/(2*t))}function c(e,t){const r=h(e);for(const e of r)for(const r of e)r[0]+=t;return e}function h(e){return(0,u.oU)(e)?e.rings:e.paths}var f=r(8744),m=r(40488),g=(r(66577),r(3172)),S=r(11282),b=r(17452);const _=o.Z.getLogger("esri.geometry.support.normalizeUtils");function w(e){return"polygon"===e[0].type}function v(e){return"polyline"===e[0].type}function C(e,t,r){if(t){const t=function(e,t){if(!(e instanceof a.Z||e instanceof l.Z)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw _.error(e),new n.Z(e)}const r=h(e),i=[];for(const e of r){const r=[];i.push(r),r.push([e[0][0],e[0][1]]);for(let i=0;i<e.length-1;i++){const n=e[i][0],o=e[i][1],s=e[i+1][0],l=e[i+1][1],a=Math.sqrt((s-n)*(s-n)+(l-o)*(l-o)),p=(l-o)/a,u=(s-n)/a,y=a/t;if(y>1){for(let e=1;e<=y-1;e++){const i=e*t,s=u*i+n,l=p*i+o;r.push([s,l])}const e=(a+Math.floor(y-1)*t)/2,i=u*e+n,s=p*e+o;r.push([i,s])}r.push([s,l])}}return function(e){return"polygon"===e.type}(e)?new l.Z({rings:i,spatialReference:e.spatialReference}):new a.Z({paths:i,spatialReference:e.spatialReference})}(e,1e6);e=(0,m.Sx)(t,!0)}return r&&(e=c(e,r)),e}function O(e,t,r){if(Array.isArray(e)){const i=e[0];if(i>t){const r=d(i,t);e[0]=i+r*(-2*t)}else if(i<r){const t=d(i,r);e[0]=i+t*(-2*r)}}else{const i=e.x;if(i>t){const r=d(i,t);e=e.clone().offset(r*(-2*t),0)}else if(i<r){const t=d(i,r);e=e.clone().offset(t*(-2*r),0)}}return e}function x(e,t){let r=-1;for(let i=0;i<t.cutIndexes.length;i++){const n=t.cutIndexes[i],o=t.geometries[i],s=h(o);for(let e=0;e<s.length;e++){const t=s[e];t.some((r=>{if(r[0]<180)return!0;{let r=0;for(let e=0;e<t.length;e++){const i=t[e][0];r=i>r?i:r}r=Number(r.toFixed(9));const i=-360*d(r,180);for(let r=0;r<t.length;r++){const t=o.getPoint(e,r);o.setPoint(e,r,t.clone().offset(i,0))}return!0}}))}if(n===r){if(w(e))for(const t of h(o))e[n]=e[n].addRing(t);else if(v(e))for(const t of h(o))e[n]=e[n].addPath(t)}else r=n,e[n]=o}return e}async function N(e,t,r){if(!Array.isArray(e))return N([e],t);t&&"string"!=typeof t&&_.warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const n="string"==typeof t?t:t?.url??i.Z.geometryServiceUrl;let o,p,h,w,v,T,L,Z,I=0;const J=[],M=[];for(const t of e)if((0,s.Wi)(t))M.push(t);else if(o||(o=t.spatialReference,p=(0,f.C5)(o),h=o.isWebMercator,T=h?102100:4326,w=y[T].maxX,v=y[T].minX,L=y[T].plus180Line,Z=y[T].minus180Line),p)if("mesh"===t.type)M.push(t);else if("point"===t.type)M.push(O(t.clone(),w,v));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>O(e,w,v))),M.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,p);M.push(e.rings?new l.Z(e):e)}else if(t.extent){const e=t.extent,r=d(e.xmin,v)*(2*w);let i=0===r?t.clone():c(t.clone(),r);e.offset(r,0),e.intersects(L)&&e.xmax!==w?(I=e.xmax>I?e.xmax:I,i=C(i,h),J.push(i),M.push("cut")):e.intersects(Z)&&e.xmin!==v?(I=e.xmax*(2*w)>I?e.xmax*(2*w):I,i=C(i,h,360),J.push(i),M.push("cut")):M.push(i)}else M.push(t.clone());else M.push(t);let j=d(I,w),R=-90;const A=j,F=new a.Z;for(;j>0;){const e=360*j-180;F.addPath([[e,R],[e,-1*R]]),R*=-1,j--}if(J.length>0&&A>0){const t=x(J,await async function(e,t,r,i){const n=(0,S.en)(e),o=t[0].spatialReference,s={...i,query:{...n.query,f:"json",sr:JSON.stringify(o),target:JSON.stringify({geometryType:(0,u.Ji)(t[0]),geometries:t}),cutter:JSON.stringify(r)}},l=await(0,g.default)(n.path+"/cut",s),{cutIndexes:a,geometries:p=[]}=l.data;return{cutIndexes:a,geometries:p.map((e=>{const t=(0,u.im)(e);return t.spatialReference=o,t}))}}(n,J,F,r)),i=[],o=[];for(let r=0;r<M.length;r++){const n=M[r];if("cut"!==n)o.push(n);else{const n=t.shift(),l=e[r];(0,s.pC)(l)&&"polygon"===l.type&&l.rings&&l.rings.length>1&&n.rings.length>=l.rings.length?(i.push(n),o.push("simplify")):o.push(h?(0,m.$)(n):n)}}if(!i.length)return o;const l=await async function(e,t,r){const i="string"==typeof e?(0,b.mN)(e):e,n=t[0].spatialReference,o=(0,u.Ji)(t[0]),s={...r,query:{...i.query,f:"json",sr:n.wkid?n.wkid:JSON.stringify(n),geometries:JSON.stringify((a=t,{geometryType:(0,u.Ji)(a[0]),geometries:a.map((e=>e.toJSON()))}))}},{data:l}=await(0,g.default)(i.path+"/simplify",s);var a;return function(e,t,r){const i=(0,u.q9)(t);return e.map((e=>{const t=i.fromJSON(e);return t.spatialReference=r,t}))}(l.geometries,o,n)}(n,i,r),a=[];for(let e=0;e<o.length;e++){const t=o[e];"simplify"!==t?a.push(t):a.push(h?(0,m.$)(l.shift()):l.shift())}return a}const E=[];for(let e=0;e<M.length;e++){const t=M[e];if("cut"!==t)E.push(t);else{const e=J.shift();E.push(!0===h?(0,m.$)(e):e)}}return E}},69285:(e,t,r)=>{r.d(t,{k:()=>s});var i=r(70586),n=r(67900),o=r(8744);function s(e,t,r){if((0,i.Wi)(t)||(0,i.Wi)(r)||r.vcsWkid||(0,o.fS)(t,r))return null;const s=(0,n._R)(t)/(0,n._R)(r);if(1===s)return null;switch(e){case"point":case"esriGeometryPoint":return e=>function(e,t){e&&null!=e.z&&(e.z*=t)}(e,s);case"polyline":case"esriGeometryPolyline":return e=>function(e,t){if(e)for(const r of e.paths)for(const e of r)e.length>2&&(e[2]*=t)}(e,s);case"polygon":case"esriGeometryPolygon":return e=>function(e,t){if(e)for(const r of e.rings)for(const e of r)e.length>2&&(e[2]*=t)}(e,s);case"multipoint":case"esriGeometryMultipoint":return e=>function(e,t){if(e)for(const r of e.points)r.length>2&&(r[2]*=t)}(e,s);case"extent":case"esriGeometryExtent":return e=>function(e,t){e&&null!=e.zmin&&null!=e.zmax&&(e.zmin*=t,e.zmax*=t)}(e,s);default:return null}}},62128:(e,t,r)=>{r.r(t),r.d(t,{default:()=>Q});var i=r(43697),n=(r(66577),r(38171)),o=(r(9790),r(46791)),s=r(20102),l=r(22974),a=r(70586),p=r(16453),u=r(78286),y=r(20941),d=r(5600),c=r(75215),h=r(71715),f=r(52011),m=r(30556),g=r(44547),S=r(24470),b=r(51806),_=r(8744),w=r(19238),v=(r(67676),r(70921)),C=r(3920);r(80442),r(92604);let O=class extends((0,C.p)(o.Z)){constructor(e){super(e),this.handles.add([this.on("before-add",(e=>{(0,a.Wi)(e.item)&&e.preventDefault()})),this.on("after-add",(e=>this._own(e.item))),this.on("after-remove",(e=>this._release(e.item)))])}get owner(){return this._get("owner")}set owner(e){e!==this._get("owner")&&(this._releaseAll(),this._set("owner",e),this._ownAll())}_ownAll(){for(const e of this.items)this._own(e)}_releaseAll(){for(const e of this.items)this._release(e)}_createNewInstance(e){return this.itemType?new(o.Z.ofType(this.itemType.Type))(e):new o.Z(e)}};(0,i._)([(0,d.Cb)()],O.prototype,"owner",null),O=(0,i._)([(0,f.j)("esri.core.support.OwningCollection")],O);var x=r(87085),N=r(71612),T=r(72965),L=r(52421);let Z=class extends O{_own(e){e.layer&&"remove"in e.layer&&e.layer!==this.owner&&e.layer.remove(e),e.layer=this.owner}_release(e){e.layer===this.owner&&(e.layer=null)}};(0,i._)([(0,L.c)({Type:n.Z,ensureType:(0,c.se)(n.Z)})],Z.prototype,"itemType",void 0),Z=(0,i._)([(0,f.j)("esri.support.GraphicsCollection")],Z);var I=r(86787);let J=class extends((0,N.h)((0,T.M)(x.Z))){constructor(e){super(e),this.elevationInfo=null,this.graphics=new Z,this.screenSizePerspectiveEnabled=!0,this.type="graphics",this.internal=!1}destroy(){this.removeAll(),this.graphics.destroy()}add(e){return this.graphics.add(e),this}addMany(e){return this.graphics.addMany(e),this}removeAll(){return this.graphics.removeAll(),this}remove(e){this.graphics.remove(e)}removeMany(e){this.graphics.removeMany(e)}on(e,t){return super.on(e,t)}graphicChanged(e){this.emit("graphic-update",e)}};var M,j;(0,i._)([(0,d.Cb)({type:I.Z})],J.prototype,"elevationInfo",void 0),(0,i._)([(0,d.Cb)((M=Z,j="graphics",{type:M,cast:v.R,set(e){const t=(0,v.Z)(e,this._get(j),M);t.owner=this,this._set(j,t)}}))],J.prototype,"graphics",void 0),(0,i._)([(0,d.Cb)({type:["show","hide"]})],J.prototype,"listMode",void 0),(0,i._)([(0,d.Cb)()],J.prototype,"screenSizePerspectiveEnabled",void 0),(0,i._)([(0,d.Cb)({readOnly:!0})],J.prototype,"type",void 0),(0,i._)([(0,d.Cb)({constructOnly:!0})],J.prototype,"internal",void 0),J=(0,i._)([(0,f.j)("esri.layers.GraphicsLayer")],J);const R=J;var A=r(92908),F=r(38009),E=r(16859),P=r(1231),z=r(20256),W=r(4095),k=r(77987),D=r(78724),G=r(82971),q=r(6570);function U(e){return"markup"===e.featureCollectionType||e.layers.some((e=>null!=e.layerDefinition.visibilityField||!H(e)))}function H({layerDefinition:e,featureSet:t}){const r=e.geometryType??t.geometryType;return $.find((t=>r===t.geometryTypeJSON&&e.drawingInfo?.renderer?.symbol?.type===t.identifyingSymbol.type))}function K(){return new q.Z({xmin:-180,ymin:-90,xmax:180,ymax:90})}const X=new P.Z({name:"OBJECTID",alias:"OBJECTID",type:"oid",nullable:!1,editable:!1}),B=new P.Z({name:"title",alias:"Title",type:"string",nullable:!0,editable:!0});let V=class extends R{constructor(e){super(e),this.visibilityMode="inherited"}initialize(){for(const e of this.graphics)e.sourceLayer=this.layer;this.graphics.on("after-add",(e=>{e.item.sourceLayer=this.layer})),this.graphics.on("after-remove",(e=>{e.item.sourceLayer=null}))}get fullExtent(){const e=this.layer?.spatialReference,t=this.fullBounds;return e?(0,a.Wi)(t)?(0,g.dz)(K(),e).geometry:(0,S.HH)(t,e):null}get fullBounds(){const e=this.layer?.spatialReference;if(!e)return null;const t=(0,S.cS)();return this.graphics.forEach((r=>{const i=(0,a.pC)(r.geometry)?(0,g.dz)(r.geometry,e).geometry:null;(0,a.pC)(i)&&(0,S.jn)(t,"point"===i.type?i:i.extent,t)})),(0,S.fS)(t,S.Gv)?null:t}get sublayers(){return this.graphics}};(0,i._)([(0,d.Cb)({readOnly:!0})],V.prototype,"fullExtent",null),(0,i._)([(0,d.Cb)({readOnly:!0})],V.prototype,"fullBounds",null),(0,i._)([(0,d.Cb)({readOnly:!0})],V.prototype,"sublayers",null),(0,i._)([(0,d.Cb)()],V.prototype,"layer",void 0),(0,i._)([(0,d.Cb)()],V.prototype,"layerId",void 0),(0,i._)([(0,d.Cb)({readOnly:!0})],V.prototype,"visibilityMode",void 0),V=(0,i._)([(0,f.j)("esri.layers.MapNotesLayer.MapNotesSublayer")],V);const $=[{geometryType:"polygon",geometryTypeJSON:"esriGeometryPolygon",id:"polygonLayer",layerId:0,title:"Polygons",identifyingSymbol:(new z.Z).toJSON()},{geometryType:"polyline",geometryTypeJSON:"esriGeometryPolyline",id:"polylineLayer",layerId:1,title:"Polylines",identifyingSymbol:(new W.Z).toJSON()},{geometryType:"multipoint",geometryTypeJSON:"esriGeometryMultipoint",id:"multipointLayer",layerId:2,title:"Multipoints",identifyingSymbol:(new k.Z).toJSON()},{geometryType:"point",geometryTypeJSON:"esriGeometryPoint",id:"pointLayer",layerId:3,title:"Points",identifyingSymbol:(new k.Z).toJSON()},{geometryType:"point",geometryTypeJSON:"esriGeometryPoint",id:"textLayer",layerId:4,title:"Text",identifyingSymbol:(new D.Z).toJSON()}];let Y=class extends((0,N.h)((0,T.M)((0,F.q)((0,E.I)((0,p.R)(x.Z)))))){constructor(e){super(e),this.capabilities={operations:{supportsMapNotesEditing:!0}},this.featureCollections=null,this.featureCollectionJSON=null,this.featureCollectionType="notes",this.legendEnabled=!1,this.listMode="hide-children",this.minScale=0,this.maxScale=0,this.spatialReference=G.Z.WGS84,this.sublayers=new o.Z($.map((e=>new V({id:e.id,layerId:e.layerId,title:e.title,layer:this})))),this.title="Map Notes",this.type="map-notes",this.visibilityMode="inherited"}readCapabilities(e,t,r){return{operations:{supportsMapNotesEditing:!U(t)&&"portal-item"!==r?.origin}}}readFeatureCollections(e,t,r){if(!U(t))return null;const i=t.layers.map((e=>{const t=new w.default;return t.read(e,r),t}));return new o.Z({items:i})}readLegacyfeatureCollectionJSON(e,t){return U(t)?(0,l.d9)(t.featureCollection):null}get fullExtent(){const e=this.spatialReference,t=(0,S.cS)();return(0,a.pC)(this.sublayers)?this.sublayers.forEach((({fullBounds:e})=>(0,a.pC)(e)?(0,S.jn)(t,e,t):t),t):this.featureCollectionJSON?.layers.some((e=>e.layerDefinition.extent))&&this.featureCollectionJSON.layers.forEach((r=>{const i=(0,g.dz)(r.layerDefinition.extent,e).geometry;(0,a.pC)(i)&&(0,S.jn)(t,i,t)})),(0,S.fS)(t,S.Gv)?(0,g.dz)(K(),e).geometry:(0,S.HH)(t,e)}readMinScale(e,t){for(const e of t.layers)if(null!=e.layerDefinition.minScale)return e.layerDefinition.minScale;return 0}readMaxScale(e,t){for(const e of t.layers)if(null!=e.layerDefinition.maxScale)return e.layerDefinition.maxScale;return 0}get multipointLayer(){return this._findSublayer("multipointLayer")}get pointLayer(){return this._findSublayer("pointLayer")}get polygonLayer(){return this._findSublayer("polygonLayer")}get polylineLayer(){return this._findSublayer("polylineLayer")}readSpatialReference(e,t){return t.layers.length?G.Z.fromJSON(t.layers[0].layerDefinition.spatialReference):G.Z.WGS84}readSublayers(e,t,r){if(U(t))return null;const i=[];let s=t.layers.reduce(((e,t)=>Math.max(e,t.layerDefinition.id??-1)),-1)+1;for(const e of t.layers){const{layerDefinition:t,featureSet:r}=e,o=t.id??s++,l=H(e);if((0,a.pC)(l)){const e=new V({id:l.id,title:t.name,layerId:o,layer:this,graphics:r.features.map((({geometry:e,symbol:t,attributes:r,popupInfo:i})=>n.Z.fromJSON({attributes:r,geometry:e,symbol:t,popupTemplate:i})))});i.push(e)}}return new o.Z(i)}writeSublayers(e,t,r,i){const{minScale:n,maxScale:o}=this;if((0,a.Wi)(e))return;const l=e.some((e=>e.graphics.length>0));if(!this.capabilities.operations.supportsMapNotesEditing)return void(l&&i?.messages?.push(new s.Z("map-notes-layer:editing-not-supported","New map notes cannot be added to this layer")));const p=[];let y=this.spatialReference.toJSON();e:for(const t of e)for(const e of t.graphics)if((0,a.pC)(e.geometry)){y=e.geometry.spatialReference.toJSON();break e}for(const t of $){const r=e.find((e=>t.id===e.id));this._writeMapNoteSublayer(p,r,t,n,o,y,i)}(0,u.RB)("featureCollection.layers",p,t)}get textLayer(){return this._findSublayer("textLayer")}load(e){return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Feature Collection"]},e)),Promise.resolve(this)}read(e,t){"featureCollection"in e&&(e=(0,l.d9)(e),Object.assign(e,e.featureCollection)),super.read(e,t)}async beforeSave(){if((0,a.Wi)(this.sublayers))return;let e=null;const t=[];for(const r of this.sublayers)for(const i of r.graphics)if((0,a.pC)(i.geometry)){const r=i.geometry;e?(0,_.fS)(r.spatialReference,e)||((0,g.Up)(r.spatialReference,e)||(0,g.kR)()||await(0,g.zD)(),i.geometry=(0,g.iV)(r,e)):e=r.spatialReference,t.push(i)}const r=await(0,b.aX)(t.map((e=>e.geometry)));t.forEach(((e,t)=>e.geometry=r[t]))}_findSublayer(e){return(0,a.Wi)(this.sublayers)?null:this.sublayers?.find((t=>t.id===e))??null}_writeMapNoteSublayer(e,t,r,i,n,o,s){const p=[];if(!(0,a.Wi)(t)){for(const e of t.graphics)this._writeMapNote(p,e,r.geometryType,s);this._normalizeObjectIds(p,X),e.push({layerDefinition:{name:t.title,drawingInfo:{renderer:{type:"simple",symbol:(0,l.d9)(r.identifyingSymbol)}},id:t.layerId,geometryType:r.geometryTypeJSON,minScale:i,maxScale:n,objectIdField:"OBJECTID",fields:[X.toJSON(),B.toJSON()],spatialReference:o},featureSet:{features:p,geometryType:r.geometryTypeJSON}})}}_writeMapNote(e,t,r,i){if((0,a.Wi)(t))return;const{geometry:n,symbol:o,popupTemplate:s}=t;if((0,a.Wi)(n))return;if(n.type!==r)return void i?.messages?.push(new y.Z("map-notes-layer:invalid-geometry-type",`Geometry "${n.type}" cannot be saved in "${r}" layer`,{graphic:t}));if((0,a.Wi)(o))return void i?.messages?.push(new y.Z("map-notes-layer:no-symbol","Skipping map notes with no symbol",{graphic:t}));const l={attributes:{...t.attributes},geometry:n.toJSON(),symbol:o.toJSON()};(0,a.pC)(s)&&(l.popupInfo=s.toJSON()),e.push(l)}_normalizeObjectIds(e,t){const r=t.name;let i=(0,A.S)(r,e)+1;const n=new Set;for(const t of e){t.attributes||(t.attributes={});const{attributes:e}=t;(null==e[r]||n.has(e[r]))&&(e[r]=i++),n.add(e[r])}}};(0,i._)([(0,d.Cb)({readOnly:!0})],Y.prototype,"capabilities",void 0),(0,i._)([(0,h.r)(["portal-item","web-map"],"capabilities",["layers"])],Y.prototype,"readCapabilities",null),(0,i._)([(0,d.Cb)({readOnly:!0})],Y.prototype,"featureCollections",void 0),(0,i._)([(0,h.r)(["web-map","portal-item"],"featureCollections",["layers"])],Y.prototype,"readFeatureCollections",null),(0,i._)([(0,d.Cb)({readOnly:!0,json:{origins:{"web-map":{write:{enabled:!0,target:"featureCollection"}}}}})],Y.prototype,"featureCollectionJSON",void 0),(0,i._)([(0,h.r)(["web-map","portal-item"],"featureCollectionJSON",["featureCollection"])],Y.prototype,"readLegacyfeatureCollectionJSON",null),(0,i._)([(0,d.Cb)({readOnly:!0,json:{read:!0,write:{enabled:!0,ignoreOrigin:!0}}})],Y.prototype,"featureCollectionType",void 0),(0,i._)([(0,d.Cb)({readOnly:!0})],Y.prototype,"fullExtent",null),(0,i._)([(0,d.Cb)({readOnly:!0,json:{origins:{"web-map":{write:{target:"featureCollection.showLegend",overridePolicy(){return{enabled:null!=this.featureCollectionJSON}}}}}}})],Y.prototype,"legendEnabled",void 0),(0,i._)([(0,d.Cb)({type:["show","hide","hide-children"]})],Y.prototype,"listMode",void 0),(0,i._)([(0,d.Cb)({type:Number,nonNullable:!0,json:{write:!1}})],Y.prototype,"minScale",void 0),(0,i._)([(0,h.r)(["web-map","portal-item"],"minScale",["layers"])],Y.prototype,"readMinScale",null),(0,i._)([(0,d.Cb)({type:Number,nonNullable:!0,json:{write:!1}})],Y.prototype,"maxScale",void 0),(0,i._)([(0,h.r)(["web-map","portal-item"],"maxScale",["layers"])],Y.prototype,"readMaxScale",null),(0,i._)([(0,d.Cb)({readOnly:!0})],Y.prototype,"multipointLayer",null),(0,i._)([(0,d.Cb)({value:"ArcGISFeatureLayer",type:["ArcGISFeatureLayer"]})],Y.prototype,"operationalLayerType",void 0),(0,i._)([(0,d.Cb)({readOnly:!0})],Y.prototype,"pointLayer",null),(0,i._)([(0,d.Cb)({readOnly:!0})],Y.prototype,"polygonLayer",null),(0,i._)([(0,d.Cb)({readOnly:!0})],Y.prototype,"polylineLayer",null),(0,i._)([(0,d.Cb)({type:G.Z})],Y.prototype,"spatialReference",void 0),(0,i._)([(0,h.r)(["web-map","portal-item"],"spatialReference",["layers"])],Y.prototype,"readSpatialReference",null),(0,i._)([(0,d.Cb)({readOnly:!0,json:{origins:{"web-map":{write:{ignoreOrigin:!0}}}}})],Y.prototype,"sublayers",void 0),(0,i._)([(0,h.r)("web-map","sublayers",["layers"])],Y.prototype,"readSublayers",null),(0,i._)([(0,m.c)("web-map","sublayers")],Y.prototype,"writeSublayers",null),(0,i._)([(0,d.Cb)({readOnly:!0})],Y.prototype,"textLayer",null),(0,i._)([(0,d.Cb)()],Y.prototype,"title",void 0),(0,i._)([(0,d.Cb)({readOnly:!0,json:{read:!1}})],Y.prototype,"type",void 0),Y=(0,i._)([(0,f.j)("esri.layers.MapNotesLayer")],Y);const Q=Y},92908:(e,t,r)=>{r.d(t,{S:()=>n,X:()=>i});const i=1;function n(e,t){let r=0;for(const i of t){const t=i.attributes?.[e];"number"==typeof t&&isFinite(t)&&(r=Math.max(r,t))}return r}},54295:(e,t,r)=>{r.d(t,{V:()=>s});var i=r(43697),n=r(5600),o=(r(67676),r(75215),r(52011));const s=e=>{let t=class extends e{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,i._)([(0,n.Cb)({type:String})],t.prototype,"apiKey",null),t=(0,i._)([(0,o.j)("esri.layers.mixins.APIKeyMixin")],t),t}},17287:(e,t,r)=>{r.d(t,{Y:()=>p});var i=r(43697),n=r(92604),o=r(70586),s=r(5600),l=(r(67676),r(75215),r(52011)),a=r(66677);const p=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,a.Qc)(this.url);if((0,o.pC)(e)&&e.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,a.Nm)(e,n.Z.getLogger(this.declaredClass)))}};return(0,i._)([(0,s.Cb)()],t.prototype,"title",null),(0,i._)([(0,s.Cb)({type:String})],t.prototype,"url",null),t=(0,i._)([(0,l.j)("esri.layers.mixins.ArcGISService")],t),t}},70082:(e,t,r)=>{r.d(t,{Z:()=>y});var i=r(43697),n=r(2368),o=r(35454),s=r(96674),l=r(5600),a=(r(67676),r(75215),r(52011));const p=new o.X({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"});let u=class extends((0,n.J)(s.wq)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,i._)([(0,l.Cb)({json:{write:!0}})],u.prototype,"name",void 0),(0,i._)([(0,l.Cb)({json:{write:!0}})],u.prototype,"description",void 0),(0,i._)([(0,l.Cb)({json:{read:p.read,write:p.write}})],u.prototype,"drawingTool",void 0),(0,i._)([(0,l.Cb)({json:{write:!0}})],u.prototype,"prototype",void 0),(0,i._)([(0,l.Cb)({json:{write:!0}})],u.prototype,"thumbnail",void 0),u=(0,i._)([(0,a.j)("esri.layers.support.FeatureTemplate")],u);const y=u},16451:(e,t,r)=>{r.d(t,{Z:()=>c});var i=r(43697),n=r(2368),o=r(96674),s=r(5600),l=(r(67676),r(75215),r(71715)),a=r(52011),p=r(30556),u=r(72729),y=r(70082);let d=class extends((0,n.J)(o.wq)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,u.im)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,i._)([(0,s.Cb)({json:{write:!0}})],d.prototype,"id",void 0),(0,i._)([(0,s.Cb)({json:{write:!0}})],d.prototype,"name",void 0),(0,i._)([(0,s.Cb)({json:{write:!0}})],d.prototype,"domains",void 0),(0,i._)([(0,l.r)("domains")],d.prototype,"readDomains",null),(0,i._)([(0,p.c)("domains")],d.prototype,"writeDomains",null),(0,i._)([(0,s.Cb)({type:[y.Z],json:{write:!0}})],d.prototype,"templates",void 0),d=(0,i._)([(0,a.j)("esri.layers.support.FeatureType")],d);const c=d},56765:(e,t,r)=>{r.d(t,{Z:()=>u});var i,n=r(43697),o=r(46791),s=r(96674),l=r(5600),a=(r(67676),r(75215),r(52011));let p=i=class extends s.wq{constructor(e){super(e),this.floorField=null,this.viewAllMode=!1,this.viewAllLevelIds=new o.Z}clone(){return new i({floorField:this.floorField,viewAllMode:this.viewAllMode,viewAllLevelIds:this.viewAllLevelIds})}};(0,n._)([(0,l.Cb)({type:String,json:{write:!0}})],p.prototype,"floorField",void 0),(0,n._)([(0,l.Cb)({json:{read:!1,write:!1}})],p.prototype,"viewAllMode",void 0),(0,n._)([(0,l.Cb)({json:{read:!1,write:!1}})],p.prototype,"viewAllLevelIds",void 0),p=i=(0,n._)([(0,a.j)("esri.layers.support.LayerFloorInfo")],p);const u=p},51706:(e,t,r)=>{var i,n;function o(e){return e&&"esri.renderers.visualVariables.SizeVariable"===e.declaredClass}function s(e){return null!=e&&!isNaN(e)&&isFinite(e)}function l(e){return e.valueExpression?i.Expression:e.field&&"string"==typeof e.field?i.Field:i.Unknown}function a(e,t){const r=t||l(e),o=e.valueUnit||"unknown";return r===i.Unknown?n.Constant:e.stops?n.Stops:null!=e.minSize&&null!=e.maxSize&&null!=e.minDataValue&&null!=e.maxDataValue?n.ClampedLinear:"unknown"===o?null!=e.minSize&&null!=e.minDataValue?e.minSize&&e.minDataValue?n.Proportional:n.Additive:n.Identity:n.RealWorldSize}r.d(t,{PS:()=>l,QW:()=>a,RY:()=>i,hL:()=>n,iY:()=>o,qh:()=>s}),function(e){e.Unknown="unknown",e.Expression="expression",e.Field="field"}(i||(i={})),function(e){e.Unknown="unknown",e.Stops="stops",e.ClampedLinear="clamped-linear",e.Proportional="proportional",e.Additive="additive",e.Constant="constant",e.Identity="identity",e.RealWorldSize="real-world-size"}(n||(n={}))},28694:(e,t,r)=>{r.d(t,{p:()=>o});var i=r(70586),n=r(69285);function o(e,t,r){if(!r||!r.features||!r.hasZ)return;const o=(0,n.k)(r.geometryType,t,e.outSpatialReference);if(!(0,i.Wi)(o))for(const e of r.features)o(e.geometry)}},11282:(e,t,r)=>{r.d(t,{cv:()=>l,en:()=>s,lA:()=>o}),r(68773),r(40330);var i=r(22974),n=r(17452);function o(e,t){return t?{...t,query:{...e,...t.query}}:{query:e}}function s(e){return"string"==typeof e?(0,n.mN)(e):(0,i.d9)(e)}function l(e,t,r){const i={};for(const n in e){if("declaredClass"===n)continue;const o=e[n];if(null!=o&&"function"!=typeof o)if(Array.isArray(o)){i[n]=[];for(let e=0;e<o.length;e++)i[n][e]=l(o[e])}else if("object"==typeof o)if(o.toJSON){const e=o.toJSON(r&&r[n]);i[n]=t?e:JSON.stringify(e)}else i[n]=t?o:JSON.stringify(o);else i[n]=o}return i}r(71058)},58333:(e,t,r)=>{r.d(t,{ET:()=>o,I4:()=>n,eG:()=>a,lF:()=>s,lj:()=>u,qP:()=>l,wW:()=>p});const i=[252,146,31,255],n={type:"esriSMS",style:"esriSMSCircle",size:6,color:i,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:i},s={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},l={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},a={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},p={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},u={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7542],{92835:(e,t,r)=>{r.d(t,{Z:()=>g});var s,i=r(43697),n=r(96674),o=r(70586),a=r(35463),l=r(5600),h=(r(67676),r(75215),r(71715)),c=r(52011),u=r(30556);let d=s=class extends n.wq{constructor(e){super(e),this.end=null,this.start=null}static get allTime(){return p}static get empty(){return m}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?e.getTime():null}get isAllTime(){return this.equals(s.allTime)}get isEmpty(){return this.equals(s.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?e.getTime():null}clone(){return new s({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=(0,o.pC)(this.start)?this.start.getTime():this.start,r=(0,o.pC)(this.end)?this.end.getTime():this.end,s=(0,o.pC)(e.start)?e.start.getTime():e.start,i=(0,o.pC)(e.end)?e.end.getTime():e.end;return t===s&&r===i}expandTo(e){if(this.isEmpty||this.isAllTime)return this.clone();const t=(0,o.yw)(this.start,(t=>(0,a.JE)(t,e))),r=(0,o.yw)(this.end,(t=>{const r=(0,a.JE)(t,e);return t.getTime()===r.getTime()?r:(0,a.Nm)(r,1,e)}));return new s({start:t,end:r})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return s.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=(0,o.R2)(this.start,-1/0,(e=>e.getTime())),r=(0,o.R2)(this.end,1/0,(e=>e.getTime())),i=(0,o.R2)(e.start,-1/0,(e=>e.getTime())),n=(0,o.R2)(e.end,1/0,(e=>e.getTime()));let a,l;if(i>=t&&i<=r?a=i:t>=i&&t<=n&&(a=t),r>=i&&r<=n?l=r:n>=t&&n<=r&&(l=n),null!=a&&null!=l&&!isNaN(a)&&!isNaN(l)){const e=new s;return e.start=a===-1/0?null:new Date(a),e.end=l===1/0?null:new Date(l),e}return s.empty}offset(e,t){if(this.isEmpty||this.isAllTime)return this.clone();const r=new s,{start:i,end:n}=this;return(0,o.pC)(i)&&(r.start=(0,a.Nm)(i,e,t)),(0,o.pC)(n)&&(r.end=(0,a.Nm)(n,e,t)),r}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return p.clone();const t=(0,o.pC)(this.start)&&(0,o.pC)(e.start)?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,r=(0,o.pC)(this.end)&&(0,o.pC)(e.end)?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new s({start:t,end:r})}};(0,i._)([(0,l.Cb)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"end",void 0),(0,i._)([(0,h.r)("end")],d.prototype,"readEnd",null),(0,i._)([(0,u.c)("end")],d.prototype,"writeEnd",null),(0,i._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],d.prototype,"isAllTime",null),(0,i._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],d.prototype,"isEmpty",null),(0,i._)([(0,l.Cb)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"start",void 0),(0,i._)([(0,h.r)("start")],d.prototype,"readStart",null),(0,i._)([(0,u.c)("start")],d.prototype,"writeStart",null),d=s=(0,i._)([(0,c.j)("esri.TimeExtent")],d);const p=new d,m=new d({start:void 0,end:void 0}),g=d},13867:(e,t,r)=>{r.d(t,{Z:()=>i});var s=r(69801);class i{constructor(e,t){this._storage=new s.WJ,this._storage.maxSize=e,t&&this._storage.registerRemoveFunc("",t)}put(e,t,r){this._storage.put(e,t,r,1)}pop(e){return this._storage.pop(e)}get(e){return this._storage.get(e)}clear(){this._storage.clearAll()}destroy(){this._storage.destroy()}get maxSize(){return this._storage.maxSize}set maxSize(e){this._storage.maxSize=e}}},69801:(e,t,r)=>{r.d(t,{WJ:()=>l,Xq:()=>a});var s,i,n=r(70586),o=r(44553);(i=s||(s={}))[i.ALL=0]="ALL",i[i.SOME=1]="SOME";class a{constructor(e,t,r){this._namespace=e,this._storage=t,this._removeFunc=!1,this._hit=0,this._miss=0,this._storage.register(this),this._namespace+=":",r&&(this._storage.registerRemoveFunc(this._namespace,r),this._removeFunc=!0)}destroy(){this._storage.clear(this._namespace),this._removeFunc&&this._storage.deregisterRemoveFunc(this._namespace),this._storage.deregister(this),this._storage=null}get namespace(){return this._namespace.slice(0,-1)}get hitRate(){return this._hit/(this._hit+this._miss)}get size(){return this._storage.size}get maxSize(){return this._storage.maxSize}resetHitRate(){this._hit=this._miss=0}put(e,t,r,s=0){this._storage.put(this._namespace+e,t,r,s)}get(e){const t=this._storage.get(this._namespace+e);return void 0===t?++this._miss:++this._hit,t}pop(e){const t=this._storage.pop(this._namespace+e);return void 0===t?++this._miss:++this._hit,t}updateSize(e,t,r){this._storage.updateSize(this._namespace+e,t,r)}clear(){this._storage.clear(this._namespace)}clearAll(){this._storage.clearAll()}getStats(){return this._storage.getStats()}resetStats(){this._storage.resetStats()}}class l{constructor(e=10485760){this._maxSize=e,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._removeFuncs=new o.Z,this._users=new o.Z}destroy(){this.clearAll(),this._removeFuncs.clear(),this._users.clear(),this._db=null}register(e){this._users.push(e)}deregister(e){this._users.removeUnordered(e)}registerRemoveFunc(e,t){this._removeFuncs.push([e,t])}deregisterRemoveFunc(e){this._removeFuncs.filterInPlace((t=>t[0]!==e))}get size(){return this._size}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,0),this._checkSizeLimit()}put(e,t,r,i){const n=this._db.get(e);if(n&&(this._size-=n.size,this._db.delete(e),n.entry!==t&&this._notifyRemove(e,n.entry,s.ALL)),r>this._maxSize)return void this._notifyRemove(e,t,s.ALL);if(void 0===t)return void console.warn("Refusing to cache undefined entry ");if(!r||r<0)return void console.warn("Refusing to cache entry with invalid size "+r);const o=1+Math.max(i,-3)- -3;this._db.set(e,{entry:t,size:r,lifetime:o,lives:o}),this._size+=r,this._checkSizeLimit()}updateSize(e,t,r){const i=this._db.get(e);if(i&&i.entry===t){for(this._size-=i.size;r>this._maxSize;){const i=this._notifyRemove(e,t,s.SOME);if(!((0,n.pC)(i)&&i>0))return void this._db.delete(e);r=i}i.size=r,this._size+=r,this._checkSizeLimit()}}pop(e){const t=this._db.get(e);if(t)return this._size-=t.size,this._db.delete(e),++this._hit,t.entry;++this._miss}get(e){const t=this._db.get(e);if(void 0!==t)return this._db.delete(e),t.lives=t.lifetime,this._db.set(e,t),++this._hit,t.entry;++this._miss}getStats(){const e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},r=new Array;this._db.forEach(((e,s)=>{const i=e.lifetime;r[i]=(r[i]||0)+e.size,this._users.forAll((r=>{const i=r.namespace;if(s.startsWith(i)){const r=t[i]||0;t[i]=r+e.size}}))}));const s={};this._users.forAll((e=>{const r=e.namespace;if(!isNaN(e.hitRate)&&e.hitRate>0){const i=t[r]||0;t[r]=i,s[r]=Math.round(100*e.hitRate)+"%"}else s[r]="0%"}));const i=Object.keys(t);i.sort(((e,r)=>t[r]-t[e])),i.forEach((r=>e[r]=Math.round(t[r]/2**20)+"MB / "+s[r]));for(let t=r.length-1;t>=0;--t){const s=r[t];s&&(e["Priority "+(t+-3-1)]=Math.round(s/this.size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._users.forAll((e=>e.resetHitRate()))}clear(e){this._db.forEach(((t,r)=>{r.startsWith(e)&&(this._size-=t.size,this._db.delete(r),this._notifyRemove(r,t.entry,s.ALL))}))}clearAll(){this._db.forEach(((e,t)=>this._notifyRemove(t,e.entry,s.ALL))),this._size=0,this._db.clear()}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,r){let s;return this._removeFuncs.some((i=>{if(e.startsWith(i[0])){const e=i[1](t,r);return"number"==typeof e&&(s=e),!0}return!1})),s}_checkSizeLimit(){if(!(this._size<=this._maxSize))for(const[e,t]of this._db){if(this._db.delete(e),t.lives<=1){this._size-=t.size;const r=this._notifyRemove(e,t.entry,s.SOME);(0,n.pC)(r)&&r>0&&(this._size+=r,t.lives=t.lifetime,t.size=r,this._db.set(e,t))}else--t.lives,this._db.set(e,t);if(this._size<=.9*this.maxSize)return}}}},16453:(e,t,r)=>{r.d(t,{R:()=>w,w:()=>v});var s=r(43697),i=r(15923),n=r(70586),o=r(41103),a=r(22974),l=r(31263);class h{constructor(){this._propertyOriginMap=new Map,this._originStores=new Array(l.kk),this._values=new Map,this.multipleOriginsSupported=!0}clone(e){const t=new h,r=this._originStores[l.s3.DEFAULTS];r&&r.forEach(((e,r)=>{t.set(r,(0,a.d9)(e),l.s3.DEFAULTS)}));for(let r=l.s3.SERVICE;r<l.kk;r++){const s=this._originStores[r];s&&s.forEach(((s,i)=>{e&&e.has(i)||t.set(i,(0,a.d9)(s),r)}))}return t}get(e,t){const r=void 0===t?this._values:this._originStores[t];return r?r.get(e):void 0}keys(e){const t=null==e?this._values:this._originStores[e];return t?[...t.keys()]:[]}set(e,t,r=l.s3.USER){let s=this._originStores[r];if(s||(s=new Map,this._originStores[r]=s),s.set(e,t),!this._values.has(e)||(0,n.j0)(this._propertyOriginMap.get(e))<=r){const s=this._values.get(e);return this._values.set(e,t),this._propertyOriginMap.set(e,r),s!==t}return!1}delete(e,t=l.s3.USER){const r=this._originStores[t];if(!r)return;const s=r.get(e);if(r.delete(e),this._values.has(e)&&this._propertyOriginMap.get(e)===t){this._values.delete(e);for(let r=t-1;r>=0;r--){const t=this._originStores[r];if(t&&t.has(e)){this._values.set(e,t.get(e)),this._propertyOriginMap.set(e,r);break}}}return s}has(e,t){const r=void 0===t?this._values:this._originStores[t];return!!r&&r.has(e)}revert(e,t){for(;t>0&&!this.has(e,t);)--t;const r=this._originStores[t],s=r&&r.get(e),i=this._values.get(e);return this._values.set(e,s),this._propertyOriginMap.set(e,t),i!==s}originOf(e){return this._propertyOriginMap.get(e)||l.s3.DEFAULTS}forEach(e){this._values.forEach(e)}}var c=r(50549),u=r(1153),d=r(52011);const p=e=>{let t=class extends e{constructor(...e){super(...e);const t=(0,n.j0)((0,u.vw)(this)),r=t.store,s=new h;t.store=s,(0,o.M)(t,r,s)}read(e,t){(0,c.i)(this,e,t)}getAtOrigin(e,t){const r=m(this),s=(0,l.M9)(t);if("string"==typeof e)return r.get(e,s);const i={};return e.forEach((e=>{i[e]=r.get(e,s)})),i}originOf(e){return(0,l.x3)(this.originIdOf(e))}originIdOf(e){return m(this).originOf(e)}revert(e,t){const r=m(this),s=(0,l.M9)(t),i=(0,u.vw)(this);let n;n="string"==typeof e?"*"===e?r.keys(s):[e]:e,n.forEach((e=>{i.invalidate(e),r.revert(e,s),i.commit(e)}))}};return t=(0,s._)([(0,d.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],t),t};function m(e){return(0,u.vw)(e).store}let g=class extends(p(i.Z)){};g=(0,s._)([(0,d.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],g);var y=r(76169);const f=e=>{let t=class extends e{constructor(...e){super(...e)}clear(e,t="user"){return _(this).delete(e,(0,l.M9)(t))}write(e={},t){return(0,y.c)(this,e=e||{},t),e}setAtOrigin(e,t,r){(0,u.vw)(this).setAtOrigin(e,t,(0,l.M9)(r))}removeOrigin(e){const t=_(this),r=(0,l.M9)(e),s=t.keys(r);for(const e of s)t.originOf(e)===r&&t.set(e,t.get(e,r),l.s3.USER)}updateOrigin(e,t){const r=_(this),s=(0,l.M9)(t),i=this.get(e);for(let t=s+1;t<l.kk;++t)r.delete(e,t);r.set(e,i,s)}toJSON(e){return this.write({},e)}};return t=(0,s._)([(0,d.j)("esri.core.WriteableMultiOriginJSONSupport")],t),t.prototype.toJSON.isDefaultToJSON=!0,t};function _(e){return(0,u.vw)(e).store}const w=e=>{let t=class extends(f(p(e))){constructor(...e){super(...e)}};return t=(0,s._)([(0,d.j)("esri.core.MultiOriginJSONSupport")],t),t};let v=class extends(w(i.Z)){};v=(0,s._)([(0,d.j)("esri.core.MultiOriginJSONSupport")],v)},64830:(e,t,r)=>{r.d(t,{Z:()=>i});var s=r(70586);class i{constructor(e=(e=>e.values().next().value)){this._peeker=e,this._items=new Set}get length(){return this._items.size}clear(){this._items.clear()}last(){if(0===this._items.size)return;let e;for(e of this._items);return e}peek(){if(0!==this._items.size)return this._peeker(this._items)}push(e){this.contains(e)||this._items.add(e)}contains(e){return this._items.has(e)}pop(){if(0===this.length)return;const e=this.peek();return this._items.delete((0,s.j0)(e)),e}popLast(){if(0===this.length)return;const e=this.last();return this._items.delete((0,s.j0)(e)),e}remove(e){this._items.delete(e)}filter(e){return this._items.forEach((t=>{e(t)||this._items.delete(t)})),this}}},17445:(e,t,r)=>{r.d(t,{N1:()=>d,YP:()=>l,Z_:()=>g,gx:()=>h,nn:()=>y,on:()=>u,tX:()=>f});var s=r(91460),i=r(50758),n=r(70586),o=r(95330),a=r(26258);function l(e,t,r={}){return c(e,t,r,p)}function h(e,t,r={}){return c(e,t,r,m)}function c(e,t,r={},s){let i=null;const o=r.once?(e,r)=>{s(e)&&((0,n.hw)(i),t(e,r))}:(e,r)=>{s(e)&&t(e,r)};if(i=(0,a.aQ)(e,o,r.sync,r.equals),r.initial){const t=e();o(t,t)}return i}function u(e,t,r,o={}){let a=null,h=null,c=null;function u(){a&&h&&(h.remove(),o.onListenerRemove?.(a),a=null,h=null)}function d(e){o.once&&o.once&&(0,n.hw)(c),r(e)}const p=l(e,((e,r)=>{u(),(0,s.vT)(e)&&(a=e,h=(0,s.on)(e,t,d),o.onListenerAdd?.(e))}),{sync:o.sync,initial:!0});return c=(0,i.kB)((()=>{p.remove(),u()})),c}function d(e,t){return function(e,t,r){if((0,o.Hc)(r))return Promise.reject((0,o.zE)());const s=e();if(t?.(s))return Promise.resolve(s);let a=null;function l(){a=(0,n.hw)(a)}return new Promise(((s,n)=>{a=(0,i.AL)([(0,o.fu)(r,(()=>{l(),n((0,o.zE)())})),c(e,(e=>{l(),s(e)}),{sync:!1,once:!0},t??p)])}))}(e,m,t)}function p(e){return!0}function m(e){return!!e}r(87538);const g={sync:!0},y={initial:!0},f={sync:!0,initial:!0}},35463:(e,t,r)=>{r.d(t,{JE:()=>o,Nm:()=>n,rJ:()=>a}),r(80442);const s={milliseconds:1,seconds:1e3,minutes:6e4,hours:36e5,days:864e5,weeks:6048e5,months:26784e5,years:31536e6,decades:31536e7,centuries:31536e8},i={milliseconds:{getter:"getMilliseconds",setter:"setMilliseconds",multiplier:1},seconds:{getter:"getSeconds",setter:"setSeconds",multiplier:1},minutes:{getter:"getMinutes",setter:"setMinutes",multiplier:1},hours:{getter:"getHours",setter:"setHours",multiplier:1},days:{getter:"getDate",setter:"setDate",multiplier:1},weeks:{getter:"getDate",setter:"setDate",multiplier:7},months:{getter:"getMonth",setter:"setMonth",multiplier:1},years:{getter:"getFullYear",setter:"setFullYear",multiplier:1},decades:{getter:"getFullYear",setter:"setFullYear",multiplier:10},centuries:{getter:"getFullYear",setter:"setFullYear",multiplier:100}};function n(e,t,r){const s=new Date(e.getTime());if(t&&r){const e=i[r],{getter:n,setter:o,multiplier:a}=e;if("months"===r){const e=function(e,t){const r=new Date(e,t+1,1);return r.setDate(0),r.getDate()}(s.getFullYear(),s.getMonth()+t);s.getDate()>e&&s.setDate(e)}s[o](s[n]()+t*a)}return s}function o(e,t){switch(t){case"milliseconds":return new Date(e.getTime());case"seconds":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds());case"minutes":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes());case"hours":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours());case"days":return new Date(e.getFullYear(),e.getMonth(),e.getDate());case"weeks":return new Date(e.getFullYear(),e.getMonth(),e.getDate()-e.getDay());case"months":return new Date(e.getFullYear(),e.getMonth(),1);case"years":return new Date(e.getFullYear(),0,1);case"decades":return new Date(e.getFullYear()-e.getFullYear()%10,0,1);case"centuries":return new Date(e.getFullYear()-e.getFullYear()%100,0,1);default:return new Date}}function a(e,t,r){return 0===e?0:e*s[t]/s[r]}},80903:(e,t,r)=>{r.d(t,{Z:()=>l});var s=r(50758),i=r(92604),n=r(95330),o=r(64830),a=r(25045);class l{constructor(){this._inUseClients=new Array,this._clients=new Array,this._clientPromises=new Array,this._ongoingJobsQueue=new o.Z}destroy(){this.close()}get closed(){return!this._clients||!this._clients.length}open(e,t){return new Promise(((r,s)=>{let i=!0;const o=e=>{(0,n.k_)(t.signal),i&&(i=!1,e())};this._clients.length=e.length,this._clientPromises.length=e.length,this._inUseClients.length=e.length;for(let i=0;i<e.length;++i){const l=e[i];(0,n.y8)(l)?this._clientPromises[i]=l.then((e=>(this._clients[i]=new a.default(e,t,(()=>this._ongoingJobsQueue.pop()??null)),o(r),this._clients[i])),(()=>(o(s),null))):(this._clients[i]=new a.default(l,t,(()=>this._ongoingJobsQueue.pop()??null)),this._clientPromises[i]=Promise.resolve(this._clients[i]),o(r))}}))}broadcast(e,t,r){const s=new Array(this._clientPromises.length);for(let i=0;i<this._clientPromises.length;++i){const n=this._clientPromises[i];s[i]=n.then((s=>s?.invoke(e,t,r)))}return s}close(){let e;for(;e=this._ongoingJobsQueue.pop();)e.deferred.reject((0,n.zE)(`Worker closing, aborting job calling '${e.methodName}'`));for(const e of this._clientPromises)e.then((e=>e?.close()));this._clients.length=0,this._clientPromises.length=0}invoke(e,t,r){let s;Array.isArray(r)?(i.Z.getLogger("esri.core.workers.Connection").warn("invoke()","The transferList parameter is deprecated, use the options object instead"),s={transferList:r}):s=r;const o=(0,n.dD)();this._ongoingJobsQueue.push({methodName:e,data:t,invokeOptions:s,deferred:o});for(let e=0;e<this._clientPromises.length;e++){const t=this._clients[e];t?t.jobAdded():this._clientPromises[e].then((e=>e?.jobAdded()))}return o.promise}on(e,t){return Promise.all(this._clientPromises).then((()=>(0,s.AL)(this._clients.map((r=>r.on(e,t))))))}openPorts(){return new Promise((e=>{const t=new Array(this._clientPromises.length);let r=t.length;for(let s=0;s<this._clientPromises.length;++s)this._clientPromises[s].then((i=>{i&&(t[s]=i.openPort()),0==--r&&e(t)}))}))}get test(){return{numClients:this._clients.length}}}},78346:(e,t,r)=>{r.d(t,{bA:()=>z});var s=r(20102),i=r(80442),n=r(95330),o=r(80903),a=r(25045),l=r(40330),h=r(92604),c=r(70586),u=r(94362),d=r(99880),p=r(68773),m=(r(2587),r(17452));const g={};function y(e){const t={async:e.async,isDebug:e.isDebug,locale:e.locale,baseUrl:e.baseUrl,has:{...e.has},map:{...e.map},packages:e.packages&&e.packages.concat()||[],paths:{...e.paths}};return e.hasOwnProperty("async")||(t.async=!0),e.hasOwnProperty("isDebug")||(t.isDebug=!1),e.baseUrl||(t.baseUrl=g.baseUrl),g.packages?.forEach((e=>{!function(e,t){for(const r of e)if(r.name===t.name)return;e.push(t)}(t.packages??[],e)})),t}var f=r(41213);class _{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...r)=>e[t](...r)}))}}class w{constructor(){this._dispatcher=new _,this._workerPostMessage({type:u.Cs.HANDSHAKE})}terminate(){}get onmessage(){return this._onmessageHandler}set onmessage(e){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler),this._onmessageHandler=e,e&&this.addEventListener("message",e)}get onmessageerror(){return this._onmessageerrorHandler}set onmessageerror(e){this._onmessageerrorHandler&&this.removeEventListener("messageerror",this._onmessageerrorHandler),this._onmessageerrorHandler=e,e&&this.addEventListener("messageerror",e)}get onerror(){return this._onerrorHandler}set onerror(e){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler),this._onerrorHandler=e,e&&this.addEventListener("error",e)}postMessage(e){(0,f.Y)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,r){this._dispatcher.addEventListener(e,t,r)}removeEventListener(e,t,r){this._dispatcher.removeEventListener(e,t,r)}_workerPostMessage(e){(0,f.Y)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,u.QM)(e);if(t&&t.type===u.Cs.OPEN){const{modulePath:e,jobId:r}=t;let s=await a.default.loadWorker(e);s||(s=await import(e));const i=a.default.connect(s);this._workerPostMessage({type:u.Cs.OPENED,jobId:r,data:i})}}}var v=r(70171),b=r(17202);const S=h.Z.getLogger("esri.core.workers.workerFactory"),{HANDSHAKE:k}=u.Cs;let L,E;const M="Failed to create Worker. Fallback to execute module in main thread";async function I(e){return new Promise((t=>{function r(i){const n=(0,u.QM)(i);n&&n.type===k&&(e.removeEventListener("message",r),e.removeEventListener("error",s),t(e))}function s(t){t.preventDefault(),e.removeEventListener("message",r),e.removeEventListener("error",s),S.warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new w).addEventListener("message",r),e.addEventListener("error",s)}e.addEventListener("message",r),e.addEventListener("error",s)}))}let C=0;const{ABORT:T,INVOKE:O,OPEN:A,OPENED:x,RESPONSE:D}=u.Cs;class j{constructor(e,t){this._outJobs=new Map,this._inJobs=new Map,this.worker=e,this.id=t,e.addEventListener("message",this._onMessage.bind(this)),e.addEventListener("error",(e=>{e.preventDefault(),h.Z.getLogger("esri.core.workers.WorkerOwner").error(e)}))}static async create(e){const t=await async function(){if(!(0,i.Z)("esri-workers")||((0,i.Z)("mozilla"),0))return I(new w);if(!L&&!E)try{const e='let globalId=0;const outgoing=new Map,configuration=JSON.parse("{CONFIGURATION}");self.esriConfig=configuration.esriConfig;const workerPath=self.esriConfig.workers.workerPath,HANDSHAKE=0,OPEN=1,OPENED=2,RESPONSE=3,INVOKE=4,ABORT=5;function createAbortError(){const e=new Error("Aborted");return e.name="AbortError",e}function receiveMessage(e){return e&&e.data?"string"==typeof e.data?JSON.parse(e.data):e.data:null}function invokeStaticMessage(e,o,r){const t=r&&r.signal,n=globalId++;return new Promise(((r,i)=>{if(t){if(t.aborted)return i(createAbortError());t.addEventListener("abort",(()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:5,jobId:n}),i(createAbortError()))}))}outgoing.set(n,{resolve:r,reject:i}),self.postMessage({type:4,jobId:n,methodName:e,abortable:null!=t,data:o})}))}let workerRevisionChecked=!1;function checkWorkerRevision(e){if(!workerRevisionChecked&&e.kernelInfo){workerRevisionChecked=!0;const{revision:o,version:r}=configuration.kernelInfo,{revision:t,version:n}=e.kernelInfo;esriConfig.assetsPath!==esriConfig.defaultAssetsPath&&o!==t&&console.warn(`Version mismatch detected between ArcGIS API for JavaScript modules and assets. For more information visit https://bit.ly/3QnsuSo.\\nModules version: ${r}\\nAssets version: ${n}`)}}function messageHandler(e){const o=receiveMessage(e);if(!o)return;const r=o.jobId;switch(o.type){case 1:let n;function t(e){const o=n.connect(e);self.postMessage({type:2,jobId:r,data:o},[o])}"function"==typeof define&&define.amd?require([workerPath],(e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||new Promise((e=>{require([o.modulePath],e)})))).then(t)})):"System"in self&&"function"==typeof System.import?System.import(workerPath).then((e=>(n=e.default,checkWorkerRevision(n),n.loadWorker(o.modulePath)))).then((e=>e||System.import(o.modulePath))).then(t):esriConfig.workers.useDynamicImport?import(workerPath).then((e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||import(o.modulePath))).then(t)})):(self.RemoteClient||importScripts(workerPath),n=self.RemoteClient.default||self.RemoteClient,checkWorkerRevision(n),n.loadWorker(o.modulePath).then(t));break;case 3:if(outgoing.has(r)){const i=outgoing.get(r);outgoing.delete(r),o.error?i.reject(JSON.parse(o.error)):i.resolve(o.data)}}}self.dojoConfig=configuration.loaderConfig,esriConfig.workers.loaderUrl&&(self.importScripts(esriConfig.workers.loaderUrl),"function"==typeof require&&"function"==typeof require.config&&require.config(configuration.loaderConfig)),self.addEventListener("message",messageHandler),self.postMessage({type:0});'.split('"{CONFIGURATION}"').join(`'${function(){let e;if(null!=p.Z.default){const t={...p.Z};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(p.Z));e.assetsPath=(0,m.hF)(e.assetsPath),e.defaultAssetsPath=e.defaultAssetsPath?(0,m.hF)(e.defaultAssetsPath):void 0,e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,v.Kd)(),e.has={"esri-csp-restrictions":(0,i.Z)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,i.Z)("esri-2d-update-debug"),"featurelayer-pbf":(0,i.Z)("featurelayer-pbf"),"featurelayer-simplify-thresholds":(0,i.Z)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,i.Z)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,i.Z)("featurelayer-simplify-mobile-factor"),"esri-atomics":(0,i.Z)("esri-atomics"),"esri-shared-array-buffer":(0,i.Z)("esri-shared-array-buffer"),"esri-tiles-debug":(0,i.Z)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,i.Z)("esri-workers-arraybuffer-transfer"),"feature-polyline-generalization-factor":(0,i.Z)("feature-polyline-generalization-factor"),"host-webworker":1,"polylabel-placement-enabled":(0,i.Z)("polylabel-placement-enabled")},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,m.hF)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,m.hF)(e.workers.workerPath):e.workers.workerPath=(0,m.hF)((0,d.V)("esri/core/workers/RemoteClient.js")),e.workers.useDynamicImport=!1;const t=p.Z.workers.loaderConfig,r=y({baseUrl:t?.baseUrl,locale:(0,v.Kd)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...t?.has},map:{...t?.map},paths:{...t?.paths},packages:t?.packages||[]}),s={version:l.i8,buildDate:b.r,revision:b.$};return JSON.stringify({esriConfig:e,loaderConfig:r,kernelInfo:s})}()}'`);L=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){E=e||{}}let e;if(L)try{e=new Worker(L,{name:"esri-worker-"+C++})}catch(t){S.warn(M,E),e=new w}else S.warn(M,E),e=new w;return I(e)}();return new j(t,e)}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:r}=t,s=(0,u.jt)();return new Promise(((t,i)=>{const o={resolve:t,reject:i,abortHandle:(0,n.$F)(r,(()=>{this._outJobs.delete(s),this._post({type:T,jobId:s})}))};this._outJobs.set(s,o),this._post({type:A,jobId:s,modulePath:e})}))}_onMessage(e){const t=(0,u.QM)(e);if(t)switch(t.type){case x:this._onOpenedMessage(t);break;case D:this._onResponseMessage(t);break;case T:this._onAbortMessage(t);break;case O:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,r=e.jobId,s=t.get(r);s&&(s.controller&&s.controller.abort(),t.delete(r))}_onInvokeMessage(e){const{methodName:t,jobId:r,data:s,abortable:i}=e,o=i?new AbortController:null,a=this._inJobs,h=l.Nv[t];let c;try{if("function"!=typeof h)throw new TypeError(`${t} is not a function`);c=h.call(null,s,{signal:o?o.signal:null})}catch(e){return void this._post({type:D,jobId:r,error:(0,u.AB)(e)})}(0,n.y8)(c)?(a.set(r,{controller:o,promise:c}),c.then((e=>{a.has(r)&&(a.delete(r),this._post({type:D,jobId:r},e))}),(e=>{a.has(r)&&(a.delete(r),e||(e={message:"Error encountered at method"+t}),(0,n.D_)(e)||this._post({type:D,jobId:r,error:(0,u.AB)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:D,jobId:r},c)}_onOpenedMessage(e){const{jobId:t,data:r}=e,s=this._outJobs.get(t);s&&(this._outJobs.delete(t),(0,c.hw)(s.abortHandle),s.resolve(r))}_onResponseMessage(e){const{jobId:t,error:r,data:i}=e,n=this._outJobs.get(t);n&&(this._outJobs.delete(t),(0,c.hw)(n.abortHandle),r?n.reject(s.Z.fromJSON(JSON.parse(r))):n.resolve(i))}_post(e,t,r){return(0,u.oi)(this.worker,e,t,r)}}let R=(0,i.Z)("esri-workers-debug")?1:(0,i.Z)("esri-mobile")?Math.min(navigator.hardwareConcurrency-1,3):(0,i.Z)("host-browser")?navigator.hardwareConcurrency-1:0;R||(R=(0,i.Z)("safari")&&(0,i.Z)("mac")||(0,i.Z)("trident")?7:2);let P=0;const N=[];async function Z(e,t){const r=new o.Z;return await r.open(e,t),r}async function z(e,t={}){if("string"!=typeof e)throw new s.Z("workers:undefined-module","modulePath is missing");let r=t.strategy||"distributed";if((0,i.Z)("host-webworker")&&!(0,i.Z)("esri-workers")&&(r="local"),"local"===r){let r=await a.default.loadWorker(e);r||(r=await import(e)),(0,n.k_)(t.signal);const s=t.client||r;return Z([a.default.connect(r)],{...t,client:s})}if(await async function(){if(U)return U;F=new AbortController;const e=[];for(let t=0;t<R;t++){const r=j.create(t).then((e=>(N[t]=e,e)));e.push(r)}return U=Promise.all(e),U}(),(0,n.k_)(t.signal),"dedicated"===r){const r=P++%R;return Z([await N[r].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const r=Math.min(t.maxNumWorkers,R);if(r<R){const s=new Array(r);for(let i=0;i<r;++i){const r=P++%R;s[i]=N[r].open(e,t)}return Z(s,t)}}return Z(N.map((r=>r.open(e,t))),t)}let F,U=null},79235:(e,t,r)=>{r.d(t,{Z:()=>w});var s,i=r(43697),n=r(67676),o=r(35454),a=r(96674),l=r(67900),h=r(20941),c=r(5600),u=(r(75215),r(71715)),d=r(52011),p=r(30556);const m=(0,o.w)()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),g=m.jsonValues.slice();(0,n.e$)(g,"orthometric");const y=(0,o.w)()({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"});let f=s=class extends a.wq{constructor(e){super(e),this.heightModel="gravity-related-height",this.heightUnit="meters",this.vertCRS=null}writeHeightModel(e,t,r){return m.write(e,t,r)}readHeightModel(e,t,r){return m.read(e)||(r&&r.messages&&r.messages.push(function(e,t){return new h.Z("height-model:unsupported",`Height model of value '${e}' is not supported`,t)}(e,{context:r})),null)}readHeightUnit(e,t,r){return y.read(e)||(r&&r.messages&&r.messages.push(_(e,{context:r})),null)}readHeightUnitService(e,t,r){return(0,l.$C)(e)||y.read(e)||(r&&r.messages&&r.messages.push(_(e,{context:r})),null)}readVertCRS(e,t){return t.vertCRS||t.ellipsoid||t.geoid}clone(){return new s({heightModel:this.heightModel,heightUnit:this.heightUnit,vertCRS:this.vertCRS})}equals(e){return!!e&&(this===e||this.heightModel===e.heightModel&&this.heightUnit===e.heightUnit&&this.vertCRS===e.vertCRS)}static deriveUnitFromSR(e,t){const r=(0,l.cM)(t);return new s({heightModel:e.heightModel,heightUnit:r,vertCRS:e.vertCRS})}write(e,t){return t={origin:"web-scene",...t},super.write(e,t)}static fromJSON(e){if(!e)return null;const t=new s;return t.read(e,{origin:"web-scene"}),t}};function _(e,t){return new h.Z("height-unit:unsupported",`Height unit of value '${e}' is not supported`,t)}(0,i._)([(0,c.Cb)({type:m.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:g,default:"ellipsoidal"}}}})],f.prototype,"heightModel",void 0),(0,i._)([(0,p.c)("web-scene","heightModel")],f.prototype,"writeHeightModel",null),(0,i._)([(0,u.r)(["web-scene","service"],"heightModel")],f.prototype,"readHeightModel",null),(0,i._)([(0,c.Cb)({type:y.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:y.jsonValues,write:y.write}}}})],f.prototype,"heightUnit",void 0),(0,i._)([(0,u.r)("web-scene","heightUnit")],f.prototype,"readHeightUnit",null),(0,i._)([(0,u.r)("service","heightUnit")],f.prototype,"readHeightUnitService",null),(0,i._)([(0,c.Cb)({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],f.prototype,"vertCRS",void 0),(0,i._)([(0,u.r)("service","vertCRS",["vertCRS","ellipsoid","geoid"])],f.prototype,"readVertCRS",null),f=s=(0,i._)([(0,d.j)("esri.geometry.HeightModelInfo")],f);const w=f},2587:(e,t,r)=>{r(90344),r(18848),r(940),r(70171);var s=r(94443),i=r(3172),n=r(20102),o=r(70586);async function a(e){if((0,o.pC)(h.fetchBundleAsset))return h.fetchBundleAsset(e);const t=await(0,i.default)(e,{responseType:"text"});return JSON.parse(t.data)}class l{constructor({base:e="",pattern:t,location:r=new URL(window.location.href)}){let s;s="string"==typeof r?e=>new URL(e,new URL(r,window.location.href)).href:r instanceof URL?e=>new URL(e,r).href:r,this.pattern="string"==typeof t?new RegExp(`^${t}`):t,this.getAssetUrl=s,e=e?e.endsWith("/")?e:e+"/":"",this.matcher=new RegExp(`^${e}(?:(.*)/)?(.*)$`)}fetchMessageBundle(e,t){return async function(e,t,r,i){const o=t.exec(r);if(!o)throw new n.Z("esri-intl:invalid-bundle",`Bundle id "${r}" is not compatible with the pattern "${t}"`);const l=o[1]?`${o[1]}/`:"",h=o[2],c=(0,s.Su)(i),u=`${l}${h}.json`,d=c?`${l}${h}_${c}.json`:u;let p;try{p=await a(e(d))}catch(t){if(d===u)throw new n.Z("intl:unknown-bundle",`Bundle "${r}" cannot be loaded`,{error:t});try{p=await a(e(u))}catch(e){throw new n.Z("intl:unknown-bundle",`Bundle "${r}" cannot be loaded`,{error:e})}}return p}(this.getAssetUrl,this.matcher,e,t)}}const h={};var c,u=r(99880);(0,s.tz)((c={pattern:"esri/",location:u.V},new l(c)))},90344:(e,t,r)=>{r.d(t,{Ze:()=>y,p6:()=>f});var s=r(35454),i=r(70171);const n={year:"numeric",month:"numeric",day:"numeric"},o={year:"numeric",month:"long",day:"numeric"},a={year:"numeric",month:"short",day:"numeric"},l={year:"numeric",month:"long",weekday:"long",day:"numeric"},h={hour:"numeric",minute:"numeric"},c={...h,second:"numeric"},u={"short-date":n,"short-date-short-time":{...n,...h},"short-date-short-time-24":{...n,...h,hour12:!1},"short-date-long-time":{...n,...c},"short-date-long-time-24":{...n,...c,hour12:!1},"short-date-le":n,"short-date-le-short-time":{...n,...h},"short-date-le-short-time-24":{...n,...h,hour12:!1},"short-date-le-long-time":{...n,...c},"short-date-le-long-time-24":{...n,...c,hour12:!1},"long-month-day-year":o,"long-month-day-year-short-time":{...o,...h},"long-month-day-year-short-time-24":{...o,...h,hour12:!1},"long-month-day-year-long-time":{...o,...c},"long-month-day-year-long-time-24":{...o,...c,hour12:!1},"day-short-month-year":a,"day-short-month-year-short-time":{...a,...h},"day-short-month-year-short-time-24":{...a,...h,hour12:!1},"day-short-month-year-long-time":{...a,...c},"day-short-month-year-long-time-24":{...a,...c,hour12:!1},"long-date":l,"long-date-short-time":{...l,...h},"long-date-short-time-24":{...l,...h,hour12:!1},"long-date-long-time":{...l,...c},"long-date-long-time-24":{...l,...c,hour12:!1},"long-month-year":{month:"long",year:"numeric"},"short-month-year":{month:"short",year:"numeric"},year:{year:"numeric"},"short-time":h,"long-time":c},d=(0,s.w)()({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"}),p=(d.apiValues,d.toJSON.bind(d),d.fromJSON.bind(d),{ar:"ar-u-nu-latn-ca-gregory"});let m=new WeakMap,g=u["short-date-short-time"];function y(e){return e?u[e]:null}function f(e,t){return function(e){const t=e||g;let r=m.get(t);if(!r){const e=(0,i.Kd)(),s=p[(0,i.Kd)()]||e;r=new Intl.DateTimeFormat(s,t),m.set(t,r)}return r}(t).format(e)}(0,i.Ze)((()=>{m=new WeakMap,g=u["short-date-short-time"]}))},18848:(e,t,r)=>{r.d(t,{sh:()=>l,uf:()=>h});var s=r(70586),i=r(70171);const n={ar:"ar-u-nu-latn"};let o=new WeakMap,a={};function l(e={}){const t={};return null!=e.digitSeparator&&(t.useGrouping=e.digitSeparator),null!=e.places&&(t.minimumFractionDigits=t.maximumFractionDigits=e.places),t}function h(e,t){return-0===e&&(e=0),function(e){const t=e||a;if(!o.has(t)){const r=(0,i.Kd)(),s=n[(0,i.Kd)()]||r;o.set(t,new Intl.NumberFormat(s,e))}return(0,s.j0)(o.get(t))}(t).format(e)}(0,i.Ze)((()=>{o=new WeakMap,a={}}))},940:(e,t,r)=>{r.d(t,{n:()=>h});var s=r(92604),i=r(78286),n=r(19153),o=r(90344),a=r(18848);const l=s.Z.getLogger("esri.intl.substitute");function h(e,t,r={}){const{format:s={}}=r;return(0,n.gx)(e,(e=>function(e,t,r){let s,n;const o=e.indexOf(":");if(-1===o?s=e.trim():(s=e.slice(0,o).trim(),n=e.slice(o+1).trim()),!s)return"";const a=(0,i.hS)(s,t);if(null==a)return"";const l=(n?r?.[n]:null)??r?.[s];return l?c(a,l):n?u(a,n):d(a)}(e,t,s)))}function c(e,t){switch(t.type){case"date":return(0,o.p6)(e,t.intlOptions);case"number":return(0,a.uf)(e,t.intlOptions);default:return l.warn("missing format descriptor for key {key}"),d(e)}}function u(e,t){switch(t.toLowerCase()){case"dateformat":return(0,o.p6)(e);case"numberformat":return(0,a.uf)(e);default:return l.warn(`inline format is unsupported since 4.12: ${t}`),/^(dateformat|datestring)/i.test(t)?(0,o.p6)(e):/^numberformat/i.test(t)?(0,a.uf)(e):d(e)}}function d(e){switch(typeof e){case"string":return e;case"number":return(0,a.uf)(e);case"boolean":return""+e;default:return e instanceof Date?(0,o.p6)(e):""}}},49932:(e,t,r)=>{r.r(t),r.d(t,{default:()=>C});var s=r(43697),i=r(3172),n=r(20102),o=r(70586),a=r(16453),l=r(95330),h=r(17452),c=r(5600),u=r(67676),d=(r(75215),r(71715)),p=r(52011),m=r(79235),g=r(87085),y=r(46486),f=r(17287),_=r(38009),w=r(16859),v=r(21506),b=r(50758),S=r(92604),k=r(78346);class L{constructor(e,t,r,s,i={}){this._mainMethod=t,this._transferLists=r,this._listeners=[],this._promise=(0,k.bA)(e,{...i,schedule:s}).then((e=>{if(void 0===this._thread){this._thread=e,this._promise=null,i.hasInitialize&&this.broadcast({},"initialize");for(const e of this._listeners)this._connectListener(e)}else e.close()})),this._promise.catch((t=>S.Z.getLogger("esri.core.workers.WorkerHandle").error(`Failed to initialize ${e} worker: ${t}`)))}on(e,t){const r={removed:!1,eventName:e,callback:t,threadHandle:null};return this._listeners.push(r),this._connectListener(r),(0,b.kB)((()=>{r.removed=!0,(0,u.Od)(this._listeners,r),this._thread&&(0,o.pC)(r.threadHandle)&&r.threadHandle.remove()}))}destroy(){this._thread&&(this._thread.close(),this._thread=null),this._promise=null}invoke(e,t){return this.invokeMethod(this._mainMethod,e,t)}invokeMethod(e,t,r){if(this._thread){const s=this._transferLists[e],i=s?s(t):[];return this._thread.invoke(e,t,{transferList:i,signal:r})}return this._promise?this._promise.then((()=>((0,l.k_)(r),this.invokeMethod(e,t,r)))):Promise.reject(null)}broadcast(e,t){return this._thread?Promise.all(this._thread.broadcast(t,e)).then((()=>{})):this._promise?this._promise.then((()=>this.broadcast(e,t))):Promise.reject()}get promise(){return this._promise}_connectListener(e){this._thread&&this._thread.on(e.eventName,e.callback).then((t=>{e.removed||(e.threadHandle=t)}))}}class E extends L{constructor(e=null){super("LercWorker","_decode",{_decode:e=>[e.buffer]},e,{strategy:"dedicated"}),this.schedule=e,this.ref=0}decode(e,t,r){return e&&0!==e.byteLength?this.invoke({buffer:e,options:t},r):Promise.resolve(null)}release(){--this.ref<=0&&(M.forEach(((e,t)=>{e===this&&M.delete(t)})),this.destroy())}}const M=new Map;let I=class extends((0,y.Z)((0,f.Y)((0,_.q)((0,w.I)((0,a.R)(g.Z)))))){constructor(...e){super(...e),this.copyright=null,this.heightModelInfo=null,this.path=null,this.minScale=void 0,this.maxScale=void 0,this.opacity=1,this.operationalLayerType="ArcGISTiledElevationServiceLayer",this.sourceJSON=null,this.type="elevation",this.url=null,this.version=null,this._lercDecoder=function(e=null){let t=M.get((0,o.Wg)(e));return t||((0,o.pC)(e)?(t=new E((t=>e.schedule(t))),M.set(e,t)):(t=new E,M.set(null,t))),++t.ref,t}()}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}destroy(){this._lercDecoder=(0,o.RY)(this._lercDecoder)}readVersion(e,t){let r=t.currentVersion;return r||(r=9.3),r}load(e){const t=(0,o.pC)(e)?e.signal:null;return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Image Service"],supportsData:!1,validateItem:e=>{for(let t=0;t<e.typeKeywords.length;t++)if("elevation 3d layer"===e.typeKeywords[t].toLowerCase())return!0;throw new n.Z("portal:invalid-layer-item-type","Invalid layer item type '${type}', expected '${expectedType}' ",{type:"Image Service",expectedType:"Image Service Elevation 3D Layer"})}},e).catch(l.r9).then((()=>this._fetchImageService(t)))),Promise.resolve(this)}fetchTile(e,t,r,s){const n=(0,o.pC)((s=s||{signal:null}).signal)?s.signal:s.signal=(new AbortController).signal,a={responseType:"array-buffer",signal:n},l={noDataValue:s.noDataValue,returnFileInfo:!0};return this.load().then((()=>this._fetchTileAvailability(e,t,r,s))).then((()=>(0,i.default)(this.getTileUrl(e,t,r),a))).then((e=>this._lercDecoder.decode(e.data,l,n))).then((e=>({values:e.pixelData,width:e.width,height:e.height,maxZError:e.fileInfo?.maxZError,noDataValue:e.noDataValue,minValue:e.minValue,maxValue:e.maxValue})))}getTileUrl(e,t,r){const s=!this.tilemapCache&&this.supportsBlankTile,i=(0,h.B7)({...this.parsedUrl.query,blankTile:!s&&null});return`${this.parsedUrl.path}/tile/${e}/${t}/${r}${i?"?"+i:""}`}async queryElevation(e,t){const{ElevationQuery:s}=await Promise.all([r.e(4547),r.e(4268)]).then(r.bind(r,55642));return(0,l.k_)(t),(new s).query(this,e,t)}async createElevationSampler(e,t){const{ElevationQuery:s}=await Promise.all([r.e(4547),r.e(4268)]).then(r.bind(r,55642));return(0,l.k_)(t),(new s).createSampler(this,e,t)}_fetchTileAvailability(e,t,r,s){return this.tilemapCache?this.tilemapCache.fetchAvailability(e,t,r,s):Promise.resolve("unknown")}async _fetchImageService(e){if(this.sourceJSON)return this.sourceJSON;const t={query:{f:"json",...this.parsedUrl.query},responseType:"json",signal:e},r=await(0,i.default)(this.parsedUrl.path,t);r.ssl&&(this.url=this.url?.replace(/^http:/i,"https:")),this.sourceJSON=r.data,this.read(r.data,{origin:"service",url:this.parsedUrl})}get hasOverriddenFetchTile(){return!this.fetchTile.__isDefault__}};(0,s._)([(0,c.Cb)({json:{read:{source:"copyrightText"}}})],I.prototype,"copyright",void 0),(0,s._)([(0,c.Cb)({readOnly:!0,type:m.Z})],I.prototype,"heightModelInfo",void 0),(0,s._)([(0,c.Cb)({type:String,json:{origins:{"web-scene":{read:!0,write:!0}},read:!1}})],I.prototype,"path",void 0),(0,s._)([(0,c.Cb)({type:["show","hide"]})],I.prototype,"listMode",void 0),(0,s._)([(0,c.Cb)({json:{read:!1,write:!1,origins:{service:{read:!1,write:!1},"portal-item":{read:!1,write:!1},"web-document":{read:!1,write:!1}}},readOnly:!0})],I.prototype,"minScale",void 0),(0,s._)([(0,c.Cb)({json:{read:!1,write:!1,origins:{service:{read:!1,write:!1},"portal-item":{read:!1,write:!1},"web-document":{read:!1,write:!1}}},readOnly:!0})],I.prototype,"maxScale",void 0),(0,s._)([(0,c.Cb)({json:{read:!1,write:!1,origins:{"web-document":{read:!1,write:!1}}}})],I.prototype,"opacity",void 0),(0,s._)([(0,c.Cb)({type:["ArcGISTiledElevationServiceLayer"]})],I.prototype,"operationalLayerType",void 0),(0,s._)([(0,c.Cb)()],I.prototype,"sourceJSON",void 0),(0,s._)([(0,c.Cb)({json:{read:!1},value:"elevation",readOnly:!0})],I.prototype,"type",void 0),(0,s._)([(0,c.Cb)(v.HQ)],I.prototype,"url",void 0),(0,s._)([(0,c.Cb)()],I.prototype,"version",void 0),(0,s._)([(0,d.r)("version",["currentVersion"])],I.prototype,"readVersion",null),I=(0,s._)([(0,p.j)("esri.layers.ElevationLayer")],I),I.prototype.fetchTile.__isDefault__=!0;const C=I},46486:(e,t,r)=>{r.d(t,{Z:()=>c});var s=r(43697),i=(r(66577),r(5600)),n=(r(67676),r(75215),r(71715)),o=r(52011),a=r(45322),l=r(56608),h=r(82971);const c=e=>{let t=class extends e{constructor(){super(...arguments),this.copyright=null,this.minScale=0,this.maxScale=0,this.spatialReference=null,this.tileInfo=null,this.tilemapCache=null}readMinScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}readMaxScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}get supportsBlankTile(){return this.version>=10.2}readTilemapCache(e,t){return t.capabilities&&t.capabilities.includes("Tilemap")?new l.y({layer:this}):null}};return(0,s._)([(0,i.Cb)({json:{read:{source:"copyrightText"}}})],t.prototype,"copyright",void 0),(0,s._)([(0,i.Cb)()],t.prototype,"minScale",void 0),(0,s._)([(0,n.r)("service","minScale")],t.prototype,"readMinScale",null),(0,s._)([(0,i.Cb)()],t.prototype,"maxScale",void 0),(0,s._)([(0,n.r)("service","maxScale")],t.prototype,"readMaxScale",null),(0,s._)([(0,i.Cb)({type:h.Z})],t.prototype,"spatialReference",void 0),(0,s._)([(0,i.Cb)({readOnly:!0})],t.prototype,"supportsBlankTile",null),(0,s._)([(0,i.Cb)(a.h)],t.prototype,"tileInfo",void 0),(0,s._)([(0,i.Cb)()],t.prototype,"tilemapCache",void 0),(0,s._)([(0,n.r)("service","tilemapCache",["capabilities"])],t.prototype,"readTilemapCache",null),(0,s._)([(0,i.Cb)()],t.prototype,"version",void 0),t=(0,s._)([(0,o.j)("esri.layers.mixins.ArcGISCachedService")],t),t}},17287:(e,t,r)=>{r.d(t,{Y:()=>h});var s=r(43697),i=r(92604),n=r(70586),o=r(5600),a=(r(67676),r(75215),r(52011)),l=r(66677);const h=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,l.Qc)(this.url);if((0,n.pC)(e)&&e.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,l.Nm)(e,i.Z.getLogger(this.declaredClass)))}};return(0,s._)([(0,o.Cb)()],t.prototype,"title",null),(0,s._)([(0,o.Cb)({type:String})],t.prototype,"url",null),t=(0,s._)([(0,a.j)("esri.layers.mixins.ArcGISService")],t),t}},38009:(e,t,r)=>{r.d(t,{q:()=>p});var s=r(43697),i=r(20102),n=r(17452),o=r(5600),a=(r(67676),r(75215),r(52011)),l=r(30556),h=r(50549),c=r(76169);const u={"web-scene/operational-layers":{ArcGISDimensionLayer:!0,ArcGISFeatureLayer:!0,ArcGISImageServiceLayer:!0,ArcGISMapServiceLayer:!0,ArcGISSceneServiceLayer:!0,ArcGISTiledElevationServiceLayer:!0,ArcGISTiledImageServiceLayer:!0,ArcGISTiledMapServiceLayer:!0,BuildingSceneLayer:!0,GroupLayer:!0,IntegratedMeshLayer:!0,OGCFeatureLayer:!0,PointCloudLayer:!0,WebTiledLayer:!0,CSV:!0,GeoJSON:!0,VectorTileLayer:!0,WFS:!0,WMS:!0,KML:!0,RasterDataLayer:!0,Voxel:!0,LineOfSightLayer:!0},"web-scene/basemap":{ArcGISTiledImageServiceLayer:!0,ArcGISTiledMapServiceLayer:!0,WebTiledLayer:!0,OpenStreetMap:!0,VectorTileLayer:!0,ArcGISImageServiceLayer:!0,WMS:!0,ArcGISMapServiceLayer:!0},"web-scene/ground":{ArcGISTiledElevationServiceLayer:!0,RasterDataElevationLayer:!0},"web-map/operational-layers":{ArcGISAnnotationLayer:!0,ArcGISDimensionLayer:!0,ArcGISFeatureLayer:!0,ArcGISImageServiceLayer:!0,ArcGISImageServiceVectorLayer:!0,ArcGISMapServiceLayer:!0,ArcGISStreamLayer:!0,ArcGISTiledImageServiceLayer:!0,ArcGISTiledMapServiceLayer:!0,BingMapsAerial:!0,BingMapsHybrid:!0,BingMapsRoad:!0,CSV:!0,GeoRSS:!0,GeoJSON:!0,GroupLayer:!0,KML:!0,OGCFeatureLayer:!0,OrientedImageryLayer:!0,SubtypeGroupLayer:!0,VectorTileLayer:!0,WFS:!0,WMS:!0,WebTiledLayer:!0},"web-map/basemap":{ArcGISImageServiceLayer:!0,ArcGISImageServiceVectorLayer:!0,ArcGISMapServiceLayer:!0,ArcGISTiledImageServiceLayer:!0,ArcGISTiledMapServiceLayer:!0,OpenStreetMap:!0,VectorTileLayer:!0,WMS:!0,WebTiledLayer:!0,BingMapsAerial:!0,BingMapsRoad:!0,BingMapsHybrid:!0},"web-map/tables":{ArcGISFeatureLayer:!0},"portal-item/operational-layers":{ArcGISFeatureLayer:!0,ArcGISSceneServiceLayer:!0,PointCloudLayer:!0,BuildingSceneLayer:!0,IntegratedMeshLayer:!0,OrientedImageryLayer:!0}};var d=r(21506);const p=e=>{let t=class extends e{constructor(){super(...arguments),this.title=null}writeListMode(e,t,r,s){(s&&"ground"===s.layerContainerType||e&&(0,c.d)(this,r,{},s))&&(t[r]=e)}writeOperationalLayerType(e,t,r,s){!e||s&&"tables"===s.layerContainerType||(t.layerType=e)}writeTitle(e,t){t.title=e??"Layer"}read(e,t){t&&(t.layer=this),(0,h.$)(this,e,(t=>super.read(e,t)),t)}write(e,t){if(t?.origin){const e=`${t.origin}/${t.layerContainerType||"operational-layers"}`,r=u[e];let s=r&&r[this.operationalLayerType];if("ArcGISTiledElevationServiceLayer"===this.operationalLayerType&&"web-scene/operational-layers"===e&&(s=!1),"ArcGISDimensionLayer"===this.operationalLayerType&&"web-map/operational-layers"===e&&(s=!1),!s)return t.messages?.push(new i.Z("layer:unsupported",`Layers (${this.title}, ${this.id}) of type '${this.declaredClass}' are not supported in the context of '${e}'`,{layer:this})),null}const r=super.write(e,{...t,layer:this}),s=!!t&&!!t.messages&&!!t.messages.filter((e=>e instanceof i.Z&&"web-document-write:property-required"===e.name)).length;return(0,n.jc)(r?.url)?(t?.messages?.push(new i.Z("layer:invalid-url",`Layer (${this.title}, ${this.id}) of type '${this.declaredClass}' using a Blob URL cannot be written to web scenes and web maps`,{layer:this})),null):!this.url&&s?null:r}beforeSave(){}};return(0,s._)([(0,o.Cb)({type:String,json:{write:{ignoreOrigin:!0},origins:{"web-scene":{write:{isRequired:!0,ignoreOrigin:!0}},"portal-item":{write:!1}}}})],t.prototype,"id",void 0),(0,s._)([(0,o.Cb)(d.rT)],t.prototype,"listMode",void 0),(0,s._)([(0,l.c)("listMode")],t.prototype,"writeListMode",null),(0,s._)([(0,o.Cb)({type:String,readOnly:!0,json:{read:!1,write:{target:"layerType",ignoreOrigin:!0},origins:{"portal-item":{write:!1}}}})],t.prototype,"operationalLayerType",void 0),(0,s._)([(0,l.c)("operationalLayerType")],t.prototype,"writeOperationalLayerType",null),(0,s._)([(0,o.Cb)(d.Oh)],t.prototype,"opacity",void 0),(0,s._)([(0,o.Cb)({type:String,json:{write:{ignoreOrigin:!0,writerEnsuresNonNull:!0},origins:{"web-scene":{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}},"portal-item":{write:!1}}},value:"Layer"})],t.prototype,"title",void 0),(0,s._)([(0,l.c)("title"),(0,l.c)(["web-scene"],"title")],t.prototype,"writeTitle",null),(0,s._)([(0,o.Cb)({type:Boolean,json:{name:"visibility"}})],t.prototype,"visible",void 0),t=(0,s._)([(0,a.j)("esri.layers.mixins.OperationalLayer")],t),t}},16859:(e,t,r)=>{r.d(t,{I:()=>w});var s=r(43697),i=r(40330),n=r(3172),o=r(66643),a=r(20102),l=r(92604),h=r(70586),c=r(95330),u=r(17452),d=r(5600),p=(r(67676),r(75215),r(71715)),m=r(52011),g=r(30556),y=r(65587),f=r(15235),_=r(86082);const w=e=>{let t=class extends e{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0}destroy(){this.portalItem=(0,h.SC)(this.portalItem)}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new f.default({id:t.itemId,portal:r&&r.portal})}writePortalItem(e,t){e&&e.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem&&this.portalItem.id)try{const s=await Promise.all([r.e(4547),r.e(9300),r.e(661)]).then(r.bind(r,18062));return(0,c.k_)(t),await s.load({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap},t)}catch(e){throw(0,c.D_)(e)||l.Z.getLogger(this.declaredClass).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch((e=>((0,c.r9)(e),!0))))}async _fetchUserHasEditingPrivileges(e){const t=this.url?i.id?.findCredential(this.url):null;if(!t)return!0;const r=v.credential===t?v.user:await this._fetchEditingUser(e);return v.credential=t,v.user=r,(0,h.Wi)(r)||null==r.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const r=i.id.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;const s=`${r.owningSystemUrl}/sharing/rest`,a=y.Z.getDefault();if(a&&a.loaded&&(0,u.Fv)(a.restUrl)===(0,u.Fv)(s))return a.user;const l=`${s}/community/self`,c=(0,h.pC)(e)?e.signal:null,d=await(0,o.q6)((0,n.default)(l,{authMode:"no-prompt",query:{f:"json"},signal:c}));return d.ok?_.default.fromJSON(d.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const r=t&&t.portal,s=this.portalItem&&this.portalItem.id&&(this.portalItem.portal||y.Z.getDefault());return r&&s&&!(0,u.tm)(s.restUrl,r.restUrl)?(t.messages&&t.messages.push(new a.Z("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, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,s._)([(0,d.Cb)({type:f.default})],t.prototype,"portalItem",null),(0,s._)([(0,p.r)("web-document","portalItem",["itemId"])],t.prototype,"readPortalItem",null),(0,s._)([(0,g.c)("web-document","portalItem",{itemId:{type:String}})],t.prototype,"writePortalItem",null),(0,s._)([(0,d.Cb)({clonable:!1})],t.prototype,"resourceReferences",void 0),(0,s._)([(0,d.Cb)({readOnly:!0})],t.prototype,"userHasEditingPrivileges",void 0),t=(0,s._)([(0,m.j)("esri.layers.mixins.PortalLayer")],t),t},v={credential:null,user:null}},21506:(e,t,r)=>{r.d(t,{qG:()=>v,PV:()=>y,id:()=>S,iR:()=>p,rn:()=>g,rT:()=>E,u1:()=>L,rO:()=>k,Oh:()=>_,bT:()=>w,C_:()=>d,Lx:()=>f,vg:()=>b,YI:()=>u,HQ:()=>m});var s=r(92835),i=r(6570),n=r(82971),o=r(25929),a=r(70586),l=(r(95330),r(35463)),h=r(86787),c=r(65242);const u={type:Boolean,value:!0,json:{origins:{service:{read:!1,write:!1},"web-map":{read:!1,write:!1}},name:"screenSizePerspective",write:!0}},d={type:Boolean,value:!0,json:{name:"disablePopup",read:{reader:(e,t)=>!t.disablePopup},write:{enabled:!0,writer(e,t,r){t[r]=!e}}}},p={type:Boolean,value:!0,nonNullable:!0,json:{name:"showLabels",write:!0}},m={type:String,json:{origins:{"portal-item":{write:!1}},write:{isRequired:!0,ignoreOrigin:!0,writer:o.w}}},g={type:Boolean,value:!0,nonNullable:!0,json:{origins:{service:{read:{enabled:!1}}},name:"showLegend",write:!0}},y={value:null,type:h.Z,json:{origins:{service:{name:"elevationInfo",write:!0}},name:"layerDefinition.elevationInfo",write:!0}};function f(e){return{type:e,readOnly:!0,json:{origins:{service:{read:!0}},read:!1}}}const _={type:Number,json:{origins:{"web-document":{write:!0,read:!0},"portal-item":{write:!0}}}},w={..._,json:{..._.json,origins:{"web-document":{..._.json.origins["web-document"],write:{enabled:!0,target:{opacity:{type:Number},"layerDefinition.drawingInfo.transparency":{type:Number}}}}},read:{source:["layerDefinition.drawingInfo.transparency","drawingInfo.transparency"],reader:(e,t,r)=>r&&"service"!==r.origin||!t.drawingInfo||void 0===t.drawingInfo.transparency?t.layerDefinition&&t.layerDefinition.drawingInfo&&void 0!==t.layerDefinition.drawingInfo.transparency?(0,c.b)(t.layerDefinition.drawingInfo.transparency):void 0:(0,c.b)(t.drawingInfo.transparency)}}},v={type:s.Z,readOnly:!0,get(){if(!this.layer?.timeInfo)return null;const{datesInUnknownTimezone:e,timeOffset:t,useViewTime:r}=this.layer,i=this.view?.timeExtent;let n=this.layer.timeExtent;e&&(n=function(e){if(!e)return e;const{start:t,end:r}=e;return new s.Z({start:(0,a.pC)(t)?(0,l.Nm)(t,t.getTimezoneOffset(),"minutes"):t,end:(0,a.pC)(r)?(0,l.Nm)(r,r.getTimezoneOffset(),"minutes"):r})}(n));let o=r?i&&n?i.intersection(n):i||n:n;if(!o||o.isEmpty||o.isAllTime)return o;t&&(o=o.offset(-t.value,t.unit)),e&&(o=function(e){if(!e)return e;const{start:t,end:r}=e;return new s.Z({start:(0,a.pC)(t)?(0,l.Nm)(t,-t.getTimezoneOffset(),"minutes"):t,end:(0,a.pC)(r)?(0,l.Nm)(r,-r.getTimezoneOffset(),"minutes"):r})}(o));const h=this._get("timeExtent");return o.equals(h)?h:o}},b={type:i.Z,readOnly:!0,json:{origins:{service:{read:{source:["fullExtent","spatialReference"],reader:(e,t)=>{const r=i.Z.fromJSON(e);return null!=t.spatialReference&&"object"==typeof t.spatialReference&&(r.spatialReference=n.Z.fromJSON(t.spatialReference)),r}}}},read:!1}},S={type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}}}},k={type:Number,json:{origins:{service:{write:{enabled:!1}}},read:{source:"layerDefinition.minScale"},write:{target:"layerDefinition.minScale"}}},L={type:Number,json:{origins:{service:{write:{enabled:!1}}},read:{source:"layerDefinition.maxScale"},write:{target:"layerDefinition.maxScale"}}},E={json:{write:{ignoreOrigin:!0},origins:{"web-map":{read:!1,write:!1}}}}},99282:(e,t,r)=>{r.d(t,{a:()=>n});var s=r(67900),i=r(68441);const n={inches:(0,s.En)(1,"meters","inches"),feet:(0,s.En)(1,"meters","feet"),"us-feet":(0,s.En)(1,"meters","us-feet"),yards:(0,s.En)(1,"meters","yards"),miles:(0,s.En)(1,"meters","miles"),"nautical-miles":(0,s.En)(1,"meters","nautical-miles"),millimeters:(0,s.En)(1,"meters","millimeters"),centimeters:(0,s.En)(1,"meters","centimeters"),decimeters:(0,s.En)(1,"meters","decimeters"),meters:(0,s.En)(1,"meters","meters"),kilometers:(0,s.En)(1,"meters","kilometers"),"decimal-degrees":1/(0,s.ty)(1,"meters",i.sv.radius)}},86787:(e,t,r)=>{r.d(t,{Z:()=>v});var s,i=r(43697),n=r(35454),o=r(96674),a=r(70586),l=r(5600),h=(r(67676),r(75215),r(71715)),c=r(52011),u=r(30556),d=r(35671);let p=s=class extends o.wq{constructor(e){super(e)}async collectRequiredFields(e,t){return(0,d.io)(e,t,this.expression)}clone(){return new s({expression:this.expression,title:this.title})}equals(e){return this.expression===e.expression&&this.title===e.title}};(0,i._)([(0,l.Cb)({type:String,json:{write:!0}})],p.prototype,"expression",void 0),(0,i._)([(0,l.Cb)({type:String,json:{write:!0}})],p.prototype,"title",void 0),p=s=(0,i._)([(0,c.j)("esri.layers.support.FeatureExpressionInfo")],p);const m=p;var g,y=r(12541);const f=(0,n.w)()({onTheGround:"on-the-ground",relativeToGround:"relative-to-ground",relativeToScene:"relative-to-scene",absoluteHeight:"absolute-height"}),_=new n.X({foot:"feet",kilometer:"kilometers",meter:"meters",mile:"miles","us-foot":"us-feet",yard:"yards"});let w=g=class extends o.wq{constructor(e){super(e),this.offset=null}readFeatureExpressionInfo(e,t){return null!=e?e:t.featureExpression&&0===t.featureExpression.value?{expression:"0"}:void 0}writeFeatureExpressionInfo(e,t,r,s){t[r]=e.write({},s),"0"===e.expression&&(t.featureExpression={value:0})}get mode(){const{offset:e,featureExpressionInfo:t}=this;return this._isOverridden("mode")?this._get("mode"):(0,a.pC)(e)||t?"relative-to-ground":"on-the-ground"}set mode(e){this._override("mode",e)}set unit(e){this._set("unit",e)}write(e,t){return this.offset||this.mode||this.featureExpressionInfo||this.unit?super.write(e,t):null}clone(){return new g({mode:this.mode,offset:this.offset,featureExpressionInfo:this.featureExpressionInfo?this.featureExpressionInfo.clone():void 0,unit:this.unit})}equals(e){return this.mode===e.mode&&this.offset===e.offset&&this.unit===e.unit&&(0,a._W)(this.featureExpressionInfo,e.featureExpressionInfo)}};(0,i._)([(0,l.Cb)({type:m,json:{write:!0}})],w.prototype,"featureExpressionInfo",void 0),(0,i._)([(0,h.r)("featureExpressionInfo",["featureExpressionInfo","featureExpression"])],w.prototype,"readFeatureExpressionInfo",null),(0,i._)([(0,u.c)("featureExpressionInfo",{featureExpressionInfo:{type:m},"featureExpression.value":{type:[0]}})],w.prototype,"writeFeatureExpressionInfo",null),(0,i._)([(0,l.Cb)({type:f.apiValues,nonNullable:!0,json:{type:f.jsonValues,read:f.read,write:{writer:f.write,isRequired:!0}}})],w.prototype,"mode",null),(0,i._)([(0,l.Cb)({type:Number,json:{write:!0}})],w.prototype,"offset",void 0),(0,i._)([(0,l.Cb)({type:y.f9,json:{type:String,read:_.read,write:_.write}})],w.prototype,"unit",null),w=g=(0,i._)([(0,c.j)("esri.layers.support.ElevationInfo")],w);const v=w},12541:(e,t,r)=>{r.d(t,{Z7:()=>i,f9:()=>n});var s=r(99282);function i(e){return 1/(s.a[e]||1)}const n=function(){const e=Object.keys(s.a);return e.sort(),e}()},65242:(e,t,r)=>{r.d(t,{a:()=>i,b:()=>n});var s=r(75215);function i(e){const t=(0,s.vU)(100*(1-e));return Math.max(0,Math.min(t,100))}function n(e){const t=1-e/100;return Math.max(0,Math.min(t,1))}}}]);
|