@arcgis/core 4.31.0-next.20240921 → 4.31.0-next.20240923
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/1810cb638ca1d52de7b2.js +1 -0
- package/assets/esri/core/workers/chunks/{69f6f35b04c722aba8cf.js → 238897e72fedd6754af7.js} +1 -1
- package/assets/esri/core/workers/chunks/2807eb7bfe4868fe840f.js +1 -0
- package/assets/esri/core/workers/chunks/{6c07116c8f7361780803.js → 2b04d2f8466d16a24a80.js} +1 -1
- package/assets/esri/core/workers/chunks/{83649583139b818d4dfa.js → 356f6cc122287412b888.js} +1 -1
- package/assets/esri/core/workers/chunks/36a1de3752ff13d77b4d.js +1 -0
- package/assets/esri/core/workers/chunks/{bf406a46515d5dfebe06.js → 3d207d1c6effda13b448.js} +1 -1
- package/assets/esri/core/workers/chunks/460ae228640fd5e545ad.js +1 -0
- package/assets/esri/core/workers/chunks/{f14cefc311a21116d21b.js → 4c0d37b799edae391ab2.js} +1 -1
- package/assets/esri/core/workers/chunks/{16eda85f728423c4ed02.js → 4ea08495271f6d291b05.js} +1 -1
- package/assets/esri/core/workers/chunks/{cf147f34032a8d07f322.js → 53becb5fe10f7f38311f.js} +1 -1
- package/assets/esri/core/workers/chunks/{24d45530fe47b3114daf.js → 5652ff08dcc5afd3d739.js} +1 -1
- package/assets/esri/core/workers/chunks/5fe1f8881959df0e61ce.js +1 -0
- package/assets/esri/core/workers/chunks/62f4eda8a9f4de481dcb.js +1 -0
- package/assets/esri/core/workers/chunks/{3fa3e1e6595668ca0e18.js → 686613864dd54d1cae3c.js} +1 -1
- package/assets/esri/core/workers/chunks/{5d0d36230a5b8309c9e4.js → 75bf6dff29056a5a1242.js} +1 -1
- package/assets/esri/core/workers/chunks/{a7bd5bb21a7f3030ee13.js → 783d66397f16899dd0e9.js} +1 -1
- package/assets/esri/core/workers/chunks/7bc57e2a3836ddc8f121.js +1 -0
- package/assets/esri/core/workers/chunks/{2658205b1ab2502c0bc7.js → 856c82a20027435fd306.js} +1 -1
- package/assets/esri/core/workers/chunks/{99944b05d3142903511c.js → 93fb720bbfb3628f9c71.js} +1 -1
- package/assets/esri/core/workers/chunks/{14f77efbfba0ca9efb6c.js → 9dce33a9bcfb852a74d3.js} +1 -1
- package/assets/esri/core/workers/chunks/{de7e197223471c7b66a7.js → afb35deb035c9c9225c9.js} +1 -1
- package/assets/esri/core/workers/chunks/{5f9beed2a9599b9ce649.js → bc37c0dc14ea54f1b9e8.js} +1 -1
- package/assets/esri/core/workers/chunks/{35f92652df2561845d47.js → c9aa8df2f62e6d40b771.js} +1 -1
- package/assets/esri/core/workers/chunks/d8435cc010bd2260feec.js +1 -0
- package/assets/esri/core/workers/chunks/e5a8ab8d02a616469f1d.js +1 -0
- package/assets/esri/core/workers/chunks/f1446e56c35e59b904e1.js +1 -0
- package/assets/esri/core/workers/chunks/{6508ff21b0a5725629eb.js → fa3f9691a9bd1bbb25d3.js} +1 -1
- package/assets/esri/core/workers/chunks/{008f290833724454160d.js → fab59ee41f96b2378768.js} +1 -1
- package/assets/esri/core/workers/chunks/{67ea066a903f5ad31155.js → fe709db8238127f91e59.js} +1 -1
- package/layers/FeatureLayer.js +1 -1
- package/layers/SubtypeGroupLayer.js +1 -1
- package/layers/orientedImagery/core/coverageUtils.js +1 -1
- package/layers/orientedImagery/core/utils.js +1 -1
- package/layers/orientedImagery/transformations/imageToWorld.js +1 -1
- package/layers/orientedImagery/transformations/updateElevationUtils.js +1 -1
- package/layers/orientedImagery/transformations/utils.js +1 -1
- package/layers/support/SubtypeSublayer.js +1 -1
- package/layers/support/featureLayerUtils.js +1 -1
- package/package.json +1 -1
- package/support/revision.js +1 -1
- package/views/interactive/sketch/constraintUtils.js +1 -1
- package/views/interactive/sketch/constraints.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/assets/esri/core/workers/chunks/0eb789af3c26fecdf3be.js +0 -1
- package/assets/esri/core/workers/chunks/41a3c7d286a050002d20.js +0 -1
- package/assets/esri/core/workers/chunks/59e4731d246203e94a96.js +0 -1
- package/assets/esri/core/workers/chunks/69c09478c899cd5e5013.js +0 -1
- package/assets/esri/core/workers/chunks/7088f771163fda53d196.js +0 -1
- package/assets/esri/core/workers/chunks/79ed119c70ce6ea02f71.js +0 -1
- package/assets/esri/core/workers/chunks/b5c02dbf540ededb863c.js +0 -1
- package/assets/esri/core/workers/chunks/eeacd5fa9fb9b1dee5f7.js +0 -1
- package/assets/esri/core/workers/chunks/f7c96d34c70ed36da7c2.js +0 -1
- package/assets/esri/core/workers/chunks/f9e90a2fda559ca68848.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1389],{68197:(e,t,i)=>{i.d(t,{A:()=>d});var r,n,s=i(40876),o=i(34727),l=i(56507);function a(e){return(0,o.qE)((0,l.Vr)(e),0,255)}function u(e,t,i){return e=Number(e),isNaN(e)?i:e<t?t:e>i?i:e}function c(e,t){const i=e.toString(16).padStart(2,"0");return t?i.slice(0,1):i}class p{static blendColors(e,t,i,r=new p){return r.r=Math.round(e.r+(t.r-e.r)*i),r.g=Math.round(e.g+(t.g-e.g)*i),r.b=Math.round(e.b+(t.b-e.b)*i),r.a=e.a+(t.a-e.a)*i,r._sanitize()}static fromRgb(e,t){const i=e.toLowerCase().match(/^(rgba?|hsla?)\(([\s.\-,%0-9]+)\)/);if(i){const e=i[2].split(/\s*,\s*/),r=i[1];if("rgb"===r&&3===e.length||"rgba"===r&&4===e.length){const i=e[0];if("%"===i.charAt(i.length-1)){const i=e.map((e=>2.56*parseFloat(e)));return 4===e.length&&(i[3]=parseFloat(e[3])),p.fromArray(i,t)}return p.fromArray(e.map((e=>parseFloat(e))),t)}if("hsl"===r&&3===e.length||"hsla"===r&&4===e.length)return p.fromArray((0,s.z$)(parseFloat(e[0]),parseFloat(e[1])/100,parseFloat(e[2])/100,parseFloat(e[3])),t)}return null}static fromHex(e,t=new p){if("#"!==e[0]||isNaN(Number(`0x${e.slice(1)}`)))return null;switch(e.length){case 4:case 5:{const i=parseInt(e.slice(1,2),16),r=parseInt(e.slice(2,3),16),n=parseInt(e.slice(3,4),16),s=5===e.length?15:parseInt(e.slice(4),16);return p.fromArray([i+16*i,r+16*r,n+16*n,(s+16*s)/255],t)}case 7:case 9:{const i=parseInt(e.slice(1,3),16),r=parseInt(e.slice(3,5),16),n=parseInt(e.slice(5,7),16),s=7===e.length?255:parseInt(e.slice(7),16);return p.fromArray([i,r,n,s/255],t)}default:return null}}static fromArray(e,t=new p){return t._set(Number(e[0]),Number(e[1]),Number(e[2]),Number(e[3])),isNaN(t.a)&&(t.a=1),t._sanitize()}static fromString(e,t){const i=(0,s.V6)(e)?(0,s.TS)(e):null;return i&&p.fromArray(i,t)||p.fromRgb(e,t)||p.fromHex(e,t)}static fromJSON(e){return null!=e?new p([e[0],e[1],e[2],(e[3]??255)/255]):void 0}static toUnitRGB(e){return null!=e?[e.r/255,e.g/255,e.b/255]:null}static toUnitRGBA(e){return null!=e?[e.r/255,e.g/255,e.b/255,null!=e.a?e.a:1]:null}constructor(e){this.r=255,this.g=255,this.b=255,this.a=1,e&&this.setColor(e)}get isBright(){return.299*this.r+.587*this.g+.114*this.b>=127}setColor(e){return"string"==typeof e?p.fromString(e,this):Array.isArray(e)?p.fromArray(e,this):(this._set(e.r??0,e.g??0,e.b??0,e.a??1),e instanceof p||this._sanitize()),this}toRgb(){return[this.r,this.g,this.b]}toRgba(){return[this.r,this.g,this.b,this.a]}toHex(e){const t=e?.capitalize??!1,i=e?.digits??6,r=3===i||4===i,n=4===i||8===i,s=`#${c(this.r,r)}${c(this.g,r)}${c(this.b,r)}${n?c(Math.round(255*this.a),r):""}`;return t?s.toUpperCase():s}toCss(e=!1){const t=this.r+", "+this.g+", "+this.b;return e?`rgba(${t}, ${this.a})`:`rgb(${t})`}toString(){return this.toCss(!0)}toJSON(){return this.toArray()}toArray(e=p.AlphaMode.ALWAYS){const t=a(this.r),i=a(this.g),r=a(this.b);return e===p.AlphaMode.ALWAYS||1!==this.a?[t,i,r,a(255*this.a)]:[t,i,r]}clone(){return new p(this.toRgba())}hash(){return this.r<<24|this.g<<16|this.b<<8|255*this.a}equals(e){return null!=e&&e.r===this.r&&e.g===this.g&&e.b===this.b&&e.a===this.a}_sanitize(){return this.r=Math.round(u(this.r,0,255)),this.g=Math.round(u(this.g,0,255)),this.b=Math.round(u(this.b,0,255)),this.a=u(this.a,0,1),this}_set(e,t,i,r){this.r=e,this.g=t,this.b=i,this.a=r}}p.prototype.declaredClass="esri.Color",(n=(r=p||(p={})).AlphaMode||(r.AlphaMode={}))[n.ALWAYS=0]="ALWAYS",n[n.UNLESS_OPAQUE=1]="UNLESS_OPAQUE";const d=p},38954:(e,t,i)=>{i.d(t,{A:()=>h,B:()=>c,C:()=>m,D:()=>p,E:()=>R,F:()=>q,G:()=>L,a:()=>l,b:()=>A,c:()=>o,e:()=>z,f:()=>u,g:()=>a,h:()=>j,i:()=>w,j:()=>f,k:()=>S,l:()=>x,m:()=>s,n:()=>_,o:()=>T,p:()=>v,q:()=>M,r:()=>g,s:()=>b,t:()=>I,u:()=>V,v:()=>d,w:()=>E,x:()=>$,y:()=>y,z:()=>P});var r=i(51850),n=i(34304);function s(e){const t=e[0],i=e[1],r=e[2];return Math.sqrt(t*t+i*i+r*r)}function o(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function l(e,t,i,r){return e[0]=t,e[1]=i,e[2]=r,e}function a(e,t,i){return e[0]=t[0]+i[0],e[1]=t[1]+i[1],e[2]=t[2]+i[2],e}function u(e,t,i){return e[0]=t[0]-i[0],e[1]=t[1]-i[1],e[2]=t[2]-i[2],e}function c(e,t,i){return e[0]=t[0]*i[0],e[1]=t[1]*i[1],e[2]=t[2]*i[2],e}function p(e,t,i){return e[0]=t[0]/i[0],e[1]=t[1]/i[1],e[2]=t[2]/i[2],e}function d(e,t){return e[0]=Math.abs(t[0]),e[1]=Math.abs(t[1]),e[2]=Math.abs(t[2]),e}function h(e,t){return e[0]=Math.sign(t[0]),e[1]=Math.sign(t[1]),e[2]=Math.sign(t[2]),e}function y(e,t,i){return e[0]=Math.min(t[0],i[0]),e[1]=Math.min(t[1],i[1]),e[2]=Math.min(t[2],i[2]),e}function m(e,t,i){return e[0]=Math.max(t[0],i[0]),e[1]=Math.max(t[1],i[1]),e[2]=Math.max(t[2],i[2]),e}function f(e,t,i){return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e}function g(e,t,i,r){return e[0]=t[0]+i[0]*r,e[1]=t[1]+i[1]*r,e[2]=t[2]+i[2]*r,e}function v(e,t){const i=t[0]-e[0],r=t[1]-e[1],n=t[2]-e[2];return Math.sqrt(i*i+r*r+n*n)}function b(e,t){const i=t[0]-e[0],r=t[1]-e[1],n=t[2]-e[2];return i*i+r*r+n*n}function M(e){const t=e[0],i=e[1],r=e[2];return t*t+i*i+r*r}function S(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e}function w(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e}function _(e,t){const i=t[0],r=t[1],n=t[2];let s=i*i+r*r+n*n;return s>0&&(s=1/Math.sqrt(s),e[0]=t[0]*s,e[1]=t[1]*s,e[2]=t[2]*s),e}function x(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function A(e,t,i){const r=t[0],n=t[1],s=t[2],o=i[0],l=i[1],a=i[2];return e[0]=n*a-s*l,e[1]=s*o-r*a,e[2]=r*l-n*o,e}function T(e,t,i,r){const n=t[0],s=t[1],o=t[2];return e[0]=n+r*(i[0]-n),e[1]=s+r*(i[1]-s),e[2]=o+r*(i[2]-o),e}function j(e,t,i){const r=t[0],n=t[1],s=t[2];return e[0]=i[0]*r+i[4]*n+i[8]*s+i[12],e[1]=i[1]*r+i[5]*n+i[9]*s+i[13],e[2]=i[2]*r+i[6]*n+i[10]*s+i[14],e}function I(e,t,i){const r=t[0],n=t[1],s=t[2];return e[0]=r*i[0]+n*i[3]+s*i[6],e[1]=r*i[1]+n*i[4]+s*i[7],e[2]=r*i[2]+n*i[5]+s*i[8],e}function V(e,t,i){const r=i[0],n=i[1],s=i[2],o=i[3],l=t[0],a=t[1],u=t[2],c=n*u-s*a,p=s*l-r*u,d=r*a-n*l,h=n*d-s*p,y=s*c-r*d,m=r*p-n*c,f=2*o;return e[0]=l+c*f+2*h,e[1]=a+p*f+2*y,e[2]=u+d*f+2*m,e}const F=(0,r.vt)(),N=(0,r.vt)();function z(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function R(e,t,i){const r=i[0]-t[0],n=i[1]-t[1],s=i[2]-t[2];let o=r*r+n*n+s*s;return o>0?(o=1/Math.sqrt(o),e[0]=r*o,e[1]=n*o,e[2]=s*o,e):(e[0]=0,e[1]=0,e[2]=0,e)}const P=u,O=c,D=p,q=v,E=b,L=s,$=M;Object.freeze(Object.defineProperty({__proto__:null,abs:d,add:a,angle:function(e,t){_(F,e),_(N,t);const i=x(F,N);return i>1?0:i<-1?Math.PI:Math.acos(i)},bezier:function(e,t,i,r,n,s){const o=1-s,l=o*o,a=s*s,u=l*o,c=3*s*l,p=3*a*o,d=a*s;return e[0]=t[0]*u+i[0]*c+r[0]*p+n[0]*d,e[1]=t[1]*u+i[1]*c+r[1]*p+n[1]*d,e[2]=t[2]*u+i[2]*c+r[2]*p+n[2]*d,e},ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e},clamp:function(e,t=0,i=1){return e[0]=Math.min(Math.max(e[0],t),i),e[1]=Math.min(Math.max(e[1],t),i),e[2]=Math.min(Math.max(e[2],t),i),e},copy:o,cross:A,crossAndNormalize:function(e,t,i){const r=t[0],n=t[1],s=t[2],o=i[0],l=i[1],a=i[2],u=n*a-s*l,c=s*o-r*a,p=r*l-n*o,d=Math.sqrt(u*u+c*c+p*p);return e[0]=u/d,e[1]=c/d,e[2]=p/d,e},direction:R,dist:q,distance:v,div:D,divide:p,dot:x,equals:function(e,t){if(e===t)return!0;const i=e[0],r=e[1],s=e[2],o=t[0],l=t[1],a=t[2],u=(0,n.FD)();return Math.abs(i-o)<=u*Math.max(1,Math.abs(i),Math.abs(o))&&Math.abs(r-l)<=u*Math.max(1,Math.abs(r),Math.abs(l))&&Math.abs(s-a)<=u*Math.max(1,Math.abs(s),Math.abs(a))},exactEquals:z,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e},hermite:function(e,t,i,r,n,s){const o=s*s,l=o*(2*s-3)+1,a=o*(s-2)+s,u=o*(s-1),c=o*(3-2*s);return e[0]=t[0]*l+i[0]*a+r[0]*u+n[0]*c,e[1]=t[1]*l+i[1]*a+r[1]*u+n[1]*c,e[2]=t[2]*l+i[2]*a+r[2]*u+n[2]*c,e},inverse:w,len:L,length:s,lerp:T,max:m,min:y,mul:O,multiply:c,negate:S,normalize:_,random:function(e,t=1){const i=n.Ov,r=2*i()*Math.PI,s=2*i()-1,o=Math.sqrt(1-s*s)*t;return e[0]=Math.cos(r)*o,e[1]=Math.sin(r)*o,e[2]=s*t,e},rotateX:function(e,t,i,r){const n=[],s=[];return n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[0],s[1]=n[1]*Math.cos(r)-n[2]*Math.sin(r),s[2]=n[1]*Math.sin(r)+n[2]*Math.cos(r),e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2],e},rotateY:function(e,t,i,r){const n=[],s=[];return n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[2]*Math.sin(r)+n[0]*Math.cos(r),s[1]=n[1],s[2]=n[2]*Math.cos(r)-n[0]*Math.sin(r),e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2],e},rotateZ:function(e,t,i,r){const n=[],s=[];return n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[0]*Math.cos(r)-n[1]*Math.sin(r),s[1]=n[0]*Math.sin(r)+n[1]*Math.cos(r),s[2]=n[2],e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2],e},round:function(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e},scale:f,scaleAndAdd:g,set:l,sign:h,sqrDist:E,sqrLen:$,squaredDistance:b,squaredLength:M,str:function(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"},sub:P,subtract:u,transformMat3:I,transformMat4:j,transformQuat:V},Symbol.toStringTag,{value:"Module"}))},69540:(e,t,i)=>{i.d(t,{O:()=>c,P:()=>p});var r=i(90237),n=i(69622),s=(i(44208),i(4718)),o=(i(53966),i(97768)),l=i(35666),a=i(88620),u=i(40608);const c=e=>{let t=class extends e{clone(){const e=(0,a.oY)(this);(0,o.Lw)(e,"unable to clone instance of non-accessor class");const t=e.metadata,i=e.store,r={},n=new Map;for(const e in t){const o=t[e],a=i?.originOf(e),u=o.clonable;if(o.readOnly||!1===u||a!==l.Gr.USER&&a!==l.Gr.DEFAULTS&&a!==l.Gr.WEB_MAP&&a!==l.Gr.WEB_SCENE)continue;const c=this[e];let p=null;p="function"==typeof u?u(c):"reference"===u?c:(0,s.TU)(c),null!=c&&null==p||(a===l.Gr.DEFAULTS?n.set(e,p):r[e]=p)}const u=new(0,Object.getPrototypeOf(this).constructor)(r);if(n.size){const e=(0,a.oY)(u)?.store;if(e)for(const[t,i]of n)e.set(t,i,l.Gr.DEFAULTS)}return u}};return t=(0,r._)([(0,u.$)("esri.core.Clonable")],t),t};let p=class extends(c(n.A)){};p=(0,r._)([(0,u.$)("esri.core.Clonable")],p)},69052:(e,t,i)=>{i.d(t,{ie:()=>l});var r=i(34727);class n{constructor(e,t){this.min=e,this.max=t,this.range=t-e}normalize(e,t=0,i=!1){return s(this.range,this.min,this.max,e,t,i)}clamp(e,t=0){return(0,r.qE)(e-t,this.min,this.max)+t}monotonic(e,t,i){return e<t?t:t+o(this.range,e-t,i)}minimalMonotonic(e,t,i){return s(this.range,e,e+this.range,t,i)}center(e,t,i){return t=this.monotonic(e,t,i),this.normalize((e+t)/2,i)}diff(e,t,i){return this.monotonic(e,t,i)-e}shortestSignedDiff(e,t){e=this.normalize(e);const i=(t=this.normalize(t))-e,r=t<e?this.minimalMonotonic(e,t)-e:t-this.minimalMonotonic(t,e);return Math.abs(i)<Math.abs(r)?i:r}contains(e,t,i){return t=this.minimalMonotonic(e,t),(i=this.minimalMonotonic(e,i))>e&&i<t}}function s(e,t,i,r,n=0,s=!1){return(r-=n)<t?r+=o(e,t-r):r>i&&(r-=o(e,r-i)),s&&r===i&&(r=t),r+n}function o(e,t,i=0){return Math.ceil((t-i)/e)*e+i}new n(0,2*Math.PI),new n(-Math.PI,Math.PI);const l=new n(0,360)},29242:(e,t,i)=>{function r(){return[1,0,0,0,1,0,0,0,1]}function n(e,t,i,r,n,s,o,l,a){return[e,t,i,r,n,s,o,l,a]}i.d(t,{fA:()=>n,vt:()=>r,zK:()=>s});const s=[1,0,0,0,1,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:s,clone:function(e){return[e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8]]},create:r,createView:function(e,t){return new Float64Array(e,t,9)},fromValues:n},Symbol.toStringTag,{value:"Module"}))},82534:(e,t,i)=>{function r(){return[0,0,0,1]}function n(e){return[e[0],e[1],e[2],e[3]]}i.d(t,{o8:()=>n,vt:()=>r,zK:()=>s});const s=[0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:s,clone:n,create:r,createView:function(e,t){return new Float64Array(e,t,4)},fromValues:function(e,t,i,r){return[e,t,i,r]}},Symbol.toStringTag,{value:"Module"}))},67026:(e,t,i)=>{i.d(t,{A6:()=>m,Xd:()=>c,Xr:()=>h,hZ:()=>g,lw:()=>p,t2:()=>I,x8:()=>u});var r=i(29242),n=i(82534),s=i(51850),o=i(34304),l=i(38954),a=i(87317);function u(e,t,i){i*=.5;const r=Math.sin(i);return e[0]=r*t[0],e[1]=r*t[1],e[2]=r*t[2],e[3]=Math.cos(i),e}function c(e,t){const i=2*Math.acos(t[3]),r=Math.sin(i/2);return r>(0,o.FD)()?(e[0]=t[0]/r,e[1]=t[1]/r,e[2]=t[2]/r):(e[0]=1,e[1]=0,e[2]=0),i}function p(e,t,i){const r=t[0],n=t[1],s=t[2],o=t[3],l=i[0],a=i[1],u=i[2],c=i[3];return e[0]=r*c+o*l+n*u-s*a,e[1]=n*c+o*a+s*l-r*u,e[2]=s*c+o*u+r*a-n*l,e[3]=o*c-r*l-n*a-s*u,e}function d(e,t,i,r){const n=t[0],s=t[1],l=t[2],a=t[3];let u,c,p,d,h,y=i[0],m=i[1],f=i[2],g=i[3];return c=n*y+s*m+l*f+a*g,c<0&&(c=-c,y=-y,m=-m,f=-f,g=-g),1-c>(0,o.FD)()?(u=Math.acos(c),p=Math.sin(u),d=Math.sin((1-r)*u)/p,h=Math.sin(r*u)/p):(d=1-r,h=r),e[0]=d*n+h*y,e[1]=d*s+h*m,e[2]=d*l+h*f,e[3]=d*a+h*g,e}function h(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e[3]=t[3],e}function y(e,t){const i=t[0]+t[4]+t[8];let r;if(i>0)r=Math.sqrt(i+1),e[3]=.5*r,r=.5/r,e[0]=(t[5]-t[7])*r,e[1]=(t[6]-t[2])*r,e[2]=(t[1]-t[3])*r;else{let i=0;t[4]>t[0]&&(i=1),t[8]>t[3*i+i]&&(i=2);const n=(i+1)%3,s=(i+2)%3;r=Math.sqrt(t[3*i+i]-t[3*n+n]-t[3*s+s]+1),e[i]=.5*r,r=.5/r,e[3]=(t[3*n+s]-t[3*s+n])*r,e[n]=(t[3*n+i]+t[3*i+n])*r,e[s]=(t[3*s+i]+t[3*i+s])*r}return e}function m(e,t,i,r){const n=.5*Math.PI/180;t*=n,i*=n,r*=n;const s=Math.sin(t),o=Math.cos(t),l=Math.sin(i),a=Math.cos(i),u=Math.sin(r),c=Math.cos(r);return e[0]=s*a*c-o*l*u,e[1]=o*l*c+s*a*u,e[2]=o*a*u-s*l*c,e[3]=o*a*c+s*l*u,e}const f=a.c,g=a.s,v=a.g,b=p,M=a.d,S=a.h,w=a.l,_=a.j,x=_,A=a.b,T=A,j=a.n,I=a.a,V=a.e,F=(0,s.vt)(),N=(0,s.fA)(1,0,0),z=(0,s.fA)(0,1,0),R=(0,n.vt)(),P=(0,n.vt)(),O=(0,r.vt)();Object.freeze(Object.defineProperty({__proto__:null,add:v,calculateW:function(e,t){const i=t[0],r=t[1],n=t[2];return e[0]=i,e[1]=r,e[2]=n,e[3]=Math.sqrt(Math.abs(1-i*i-r*r-n*n)),e},conjugate:h,copy:f,dot:S,equals:V,exactEquals:I,fromEuler:m,fromMat3:y,getAxisAngle:c,identity:function(e){return e[0]=0,e[1]=0,e[2]=0,e[3]=1,e},invert:function(e,t){const i=t[0],r=t[1],n=t[2],s=t[3],o=i*i+r*r+n*n+s*s,l=o?1/o:0;return e[0]=-i*l,e[1]=-r*l,e[2]=-n*l,e[3]=s*l,e},len:x,length:_,lerp:w,mul:b,multiply:p,normalize:j,random:function(e){const t=o.Ov,i=t(),r=t(),n=t(),s=Math.sqrt(1-i),l=Math.sqrt(i);return e[0]=s*Math.sin(2*Math.PI*r),e[1]=s*Math.cos(2*Math.PI*r),e[2]=l*Math.sin(2*Math.PI*n),e[3]=l*Math.cos(2*Math.PI*n),e},rotateX:function(e,t,i){i*=.5;const r=t[0],n=t[1],s=t[2],o=t[3],l=Math.sin(i),a=Math.cos(i);return e[0]=r*a+o*l,e[1]=n*a+s*l,e[2]=s*a-n*l,e[3]=o*a-r*l,e},rotateY:function(e,t,i){i*=.5;const r=t[0],n=t[1],s=t[2],o=t[3],l=Math.sin(i),a=Math.cos(i);return e[0]=r*a-s*l,e[1]=n*a+o*l,e[2]=s*a+r*l,e[3]=o*a-n*l,e},rotateZ:function(e,t,i){i*=.5;const r=t[0],n=t[1],s=t[2],o=t[3],l=Math.sin(i),a=Math.cos(i);return e[0]=r*a+n*l,e[1]=n*a-r*l,e[2]=s*a+o*l,e[3]=o*a-s*l,e},rotationTo:function(e,t,i){const r=(0,l.l)(t,i);return r<-.999999?((0,l.b)(F,N,t),(0,l.G)(F)<1e-6&&(0,l.b)(F,z,t),(0,l.n)(F,F),u(e,F,Math.PI),e):r>.999999?(e[0]=0,e[1]=0,e[2]=0,e[3]=1,e):((0,l.b)(F,t,i),e[0]=F[0],e[1]=F[1],e[2]=F[2],e[3]=1+r,j(e,e))},scale:M,set:g,setAxes:function(e,t,i,r){const n=O;return n[0]=i[0],n[3]=i[1],n[6]=i[2],n[1]=r[0],n[4]=r[1],n[7]=r[2],n[2]=-t[0],n[5]=-t[1],n[8]=-t[2],j(e,y(e,n))},setAxisAngle:u,slerp:d,sqlerp:function(e,t,i,r,n,s){return d(R,t,n,s),d(P,i,r,s),d(e,R,P,2*s*(1-s)),e},sqrLen:T,squaredLength:A,str:function(e){return"quat("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")"}},Symbol.toStringTag,{value:"Module"}))},3330:(e,t,i)=>{i.d(t,{GB:()=>n,Qo:()=>o,Y4:()=>s});var r=i(96285);class n{}function s(e){return e instanceof r.bo?e===n.instance:"unknown"===e?.toString().toLowerCase()}function o(e){return s(e)?n.instance:e}n.instance=new r.oh("Etc/UTC")},54239:(e,t,i)=>{i.d(t,{A:()=>b});var r,n=i(90237),s=i(4576),o=i(66552),l=i(25482),a=i(83047),u=i(67076),c=i(10107),p=(i(44208),i(53966),i(36005)),d=i(40608),h=i(43937);const y=(0,o.O)()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),m=y.jsonValues.slice();(0,s.Xy)(m,"orthometric");const f=(0,o.O)()({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 g=r=class extends l.oY{constructor(e){super(e),this.heightModel="gravity-related-height",this.heightUnit="meters",this.vertCRS=null}writeHeightModel(e,t,i){return y.write(e,t,i)}readHeightModel(e,t,i){return y.read(e)||(i?.messages&&i.messages.push(function(e,t){return new u.A("height-model:unsupported",`Height model of value '${e}' is not supported`,t)}(e,{context:i})),null)}readHeightUnit(e,t,i){return f.read(e)||(i?.messages&&i.messages.push(v(e,{context:i})),null)}readHeightUnitService(e,t,i){return(0,a.LA)(e)||f.read(e)||(i?.messages&&i.messages.push(v(e,{context:i})),null)}readVertCRS(e,t){return t.vertCRS||t.ellipsoid||t.geoid}clone(){return new r({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 i=(0,a.k1)(t);return new r({heightModel:e.heightModel,heightUnit:i??void 0,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 r;return t.read(e,{origin:"web-scene"}),t}};function v(e,t){return new u.A("height-unit:unsupported",`Height unit of value '${e}' is not supported`,t)}(0,n._)([(0,c.M)({type:y.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:m,default:"ellipsoidal"}}}})],g.prototype,"heightModel",void 0),(0,n._)([(0,h.K)("web-scene","heightModel")],g.prototype,"writeHeightModel",null),(0,n._)([(0,p.w)(["web-scene","service"],"heightModel")],g.prototype,"readHeightModel",null),(0,n._)([(0,c.M)({type:f.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:f.jsonValues,write:f.write}}}})],g.prototype,"heightUnit",void 0),(0,n._)([(0,p.w)("web-scene","heightUnit")],g.prototype,"readHeightUnit",null),(0,n._)([(0,p.w)("service","heightUnit")],g.prototype,"readHeightUnitService",null),(0,n._)([(0,c.M)({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],g.prototype,"vertCRS",void 0),(0,n._)([(0,p.w)("service","vertCRS",["vertCRS","ellipsoid","geoid"])],g.prototype,"readVertCRS",null),g=r=(0,n._)([(0,d.$)("esri.geometry.HeightModelInfo")],g);const b=g},16183:(e,t,i)=>{i.r(t),i.d(t,{default:()=>We});var r=i(90237),n=i(13874),s=i(5503),o=i(49186),l=i(53966),a=i(92071),u=i(74887),c=i(10107),p=i(56507),d=(i(87811),i(44208),i(36005)),h=i(40608),y=i(38954),m=i(51850),f=i(5443),g=i(4146),v=i(52136),b=i(18768),M=i(69208),S=i(16131),w=i(8303),_=i(25036),x=i(58947),A=i(60694),T=i(10873),j=i(20437),I=i(95466),V=i(96184),F=i(69540),N=i(69052),z=i(25482),R=i(87024),P=i(67026),O=i(82534),D=i(34304);const q=(0,m.vt)(),E=(0,O.vt)(),L=(0,O.vt)(),$=(0,O.vt)(),U=(0,m.fA)(0,0,1),C=(0,m.fA)(0,1,0),B=(0,m.fA)(1,0,0);function k(e){(0,y.c)(q,e),(0,y.n)(q,q);const t=Math.atan2(q[1],q[0]),i=(0,P.x8)((0,O.vt)(),U,-t);(0,y.u)(q,q,i);const r=-1*Math.atan2(q[2],q[0]);return[(0,D.ct)(t)+270,(0,D.ct)(r)+90]}function Y(e,t){return(0,P.x8)(L,U,(0,D.DF)(e-270)),(0,P.x8)($,C,(0,D.DF)(t-90)),(0,P.lw)(E,L,$),(0,y.c)(q,B),(0,y.u)(q,q,E),(0,y.n)(q,q),[q[0],q[1],q[2]]}var H=i(79901);let J=class extends((0,F.O)(z.oY)){constructor(e){super(e),this.enabled=!0,this.label="",this.normal=null,this.point=null}get orientation(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,p.GB)(e),0,!0)}set orientation(e){const t=Y(e,this.tilt);this._set("normal",t),this._set("orientation",e)}get tilt(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,p.GB)(t),0,!0)}set tilt(e){const t=Y(this.orientation,e);this._set("normal",t),this._set("tilt",e)}};(0,r._)([(0,c.M)({type:Boolean,json:{write:!0}})],J.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],J.prototype,"label",void 0),(0,r._)([(0,c.M)({type:Number,json:{read:!1},clonable:!1,range:{min:0,max:360}}),(0,H.w)((e=>N.ie.normalize((0,p.GB)(e),0,!0)))],J.prototype,"orientation",null),(0,r._)([(0,c.M)({type:Number,json:{read:!1},clonable:!1,range:{min:0,max:360}}),(0,H.w)((e=>N.ie.normalize((0,p.GB)(e),0,!0)))],J.prototype,"tilt",null),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],J.prototype,"normal",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],J.prototype,"point",void 0),J=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelSlice")],J);const Z=J;var G=i(97159);let K=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.enabled=!0,this.href=null,this.id=null,this.label="",this.normal=null,this.point=null,this.sizeInPixel=null,this.slices=null,this.timeId=0,this.variableId=null}get orientation(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,p.GB)(e),0,!0)}get tilt(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,p.GB)(t),0,!0)}};(0,r._)([(0,c.M)({type:Boolean,json:{default:!0,write:!0}})],K.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{origins:{service:{read:G.r}},write:{enabled:!0,isRequired:!0}}}),(0,R.P)({origins:["web-scene"],type:"resource",prefix:"sections",compress:!0})],K.prototype,"href",void 0),(0,r._)([(0,c.M)({type:p.jz,json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"id",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],K.prototype,"label",void 0),(0,r._)([(0,c.M)({type:Number,clonable:!1,readOnly:!0,range:{min:0,max:360}})],K.prototype,"orientation",null),(0,r._)([(0,c.M)({type:Number,clonable:!1,readOnly:!0,range:{min:0,max:360}})],K.prototype,"tilt",null),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"normal",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"point",void 0),(0,r._)([(0,c.M)({type:[p.jz],json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"sizeInPixel",void 0),(0,r._)([(0,c.M)({type:[Z],json:{write:!0}})],K.prototype,"slices",void 0),(0,r._)([(0,c.M)({type:p.jz,json:{default:0,write:!0}})],K.prototype,"timeId",void 0),(0,r._)([(0,c.M)({type:p.jz,json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"variableId",void 0),K=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelSection")],K);const W=K;let Q=class extends z.oY{constructor(){super(...arguments),this.diffuseFactor=.5,this.specularFactor=.5}};(0,r._)([(0,c.M)({type:Number,range:{min:0,max:1},json:{default:.5,write:!0}})],Q.prototype,"diffuseFactor",void 0),(0,r._)([(0,c.M)({type:Number,range:{min:0,max:1},json:{default:.5,write:!0}})],Q.prototype,"specularFactor",void 0),Q=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelSimpleShading")],Q);const X=Q;let ee=class extends z.oY{constructor(){super(...arguments),this.continuity=null,this.hasNoData=!1,this.noData=0,this.offset=0,this.scale=1,this.type=null}};(0,r._)([(0,c.M)({type:["discrete","continuous"],json:{write:!0}})],ee.prototype,"continuity",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{write:!0}})],ee.prototype,"hasNoData",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],ee.prototype,"noData",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],ee.prototype,"offset",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],ee.prototype,"scale",void 0),(0,r._)([(0,c.M)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],ee.prototype,"type",void 0),ee=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelFormat")],ee);const te=ee;let ie=class extends z.oY{constructor(){super(...arguments),this.id=null,this.description="",this.name=null,this.originalFormat=null,this.renderingFormat=null,this.unit="",this.volumeId=0,this.type=null}};(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],ie.prototype,"id",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],ie.prototype,"description",void 0),(0,r._)([(0,c.M)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],ie.prototype,"name",void 0),(0,r._)([(0,c.M)({type:te,json:{write:!0}})],ie.prototype,"originalFormat",void 0),(0,r._)([(0,c.M)({type:te,json:{write:{enabled:!0,isRequired:!0}}})],ie.prototype,"renderingFormat",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],ie.prototype,"unit",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],ie.prototype,"volumeId",void 0),(0,r._)([(0,c.M)({type:["stc-hot-spot-results","stc-cluster-outlier-results","stc-estimated-bin","generic-nearest-interpolated"],json:{write:!0}})],ie.prototype,"type",void 0),ie=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVariable")],ie);const re=ie;var ne=i(4718),se=i(68197);let oe=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.color=se.A.fromArray([0,0,0,0]),this.value=0,this.enabled=!0,this.label="",this.colorLocked=!1}};(0,r._)([(0,c.M)({type:se.A,json:{type:[p.jz],write:{enabled:!0,isRequired:!0}}})],oe.prototype,"color",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],oe.prototype,"value",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{default:!0,write:!0}})],oe.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],oe.prototype,"label",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{default:!1,write:!0}})],oe.prototype,"colorLocked",void 0),oe=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelIsosurface")],oe);const le=oe;var ae=i(62885),ue=i(34727);let ce=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.color=null,this.position=0}};(0,r._)([(0,c.M)({type:se.A,json:{type:[p.jz],write:{enabled:!0,isRequired:!0}}})],ce.prototype,"color",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],ce.prototype,"position",void 0),ce=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelColorStop")],ce);const pe=ce;let de=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.opacity=1,this.position=0}};(0,r._)([(0,c.M)({type:Number,json:{name:"alpha",write:{enabled:!0,isRequired:!0}}})],de.prototype,"opacity",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],de.prototype,"position",void 0),de=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelOpacityStop")],de);const he=de;let ye=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.enabled=!1,this.range=null}};(0,r._)([(0,c.M)({type:Boolean,json:{default:!1,write:!0}})],ye.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],ye.prototype,"range",void 0),ye=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelRangeFilter")],ye);const me=ye;var fe,ge;(ge=fe||(fe={}))[ge.Color=1]="Color",ge[ge.Alpha=2]="Alpha",ge[ge.Both=3]="Both";let ve=class extends((0,F.O)(z.oY)){constructor(e){super(e),this.interpolation=null,this.stretchRange=null,this.rangeFilter=null,this._colorMapSize=256,this.colorStops=new(s.A.ofType(pe)),this.opacityStops=new(s.A.ofType(he))}set colorStops(e){this._set("colorStops",(0,ae.V)(e,this._get("colorStops"),s.A.ofType(pe)))}set opacityStops(e){this._set("opacityStops",(0,ae.V)(e,this._get("opacityStops"),s.A.ofType(he)))}getPreviousNext(e,t,i){let r=e;for(;--r>0&&t[r].type!==i&&t[r].type!==fe.Both;);let n=e;const s=t.length;for(;++n<s&&t[n].type!==i&&t[n].type!==fe.Both;);return[r,n]}get rasterizedTransferFunction(){const e=[];if(this.colorStops.length<2)return e;const t=[],i=[];for(const t of this.colorStops){if(!t.color)return e;i.push({color:{r:t.color.r,g:t.color.g,b:t.color.b,a:Math.round(255*(1-t.color.a))},position:t.position,type:fe.Color})}if(0===this.opacityStops.length)for(const e of i)t.push({color:e.color,position:e.position});else{for(const e of this.opacityStops){const t=(0,ue.qE)(e.position,0,1),r=Math.round(255*(0,ue.qE)(1-e.opacity,0,1));let n=!1;for(const e of i)if(e.type===fe.Color&&Math.abs(e.position-t)<1e-5){e.color.a=r,e.type=fe.Both,n=!0;break}n||i.push({color:{r:0,g:0,b:0,a:r},position:e.position,type:fe.Alpha})}i.sort(((e,t)=>e.position<t.position?-1:1));const e=i.length;for(let t=0;t<e;++t){const r=i[t];if(r.type!==fe.Both)if(r.type===fe.Color){const[n,s]=this.getPreviousNext(t,i,fe.Alpha);if(-1!==n&&s!==e){const e=(r.position-i[n].position)/(i[s].position-i[n].position);r.color.a=Math.round((0,ue.Cc)(i[n].color.a,i[s].color.a,e))}else r.color.a=-1!==n?i[n].color.a:i[s].color.a}else{const[n,s]=this.getPreviousNext(t,i,fe.Color);if(-1!==n&&s!==e){const e=(r.position-i[n].position)/(i[s].position-i[n].position),t=i[n].color,o=i[s].color;Me.forEach((i=>{r.color[i]=Math.round((0,ue.Cc)(t[i],o[i],e))}))}else-1!==n?Me.forEach((e=>{r.color[e]=i[n].color[e]})):Me.forEach((e=>{r.color[e]=i[s].color[e]}))}}for(const e of i)t.push({color:e.color,position:e.position})}t[0].position=0,t[t.length-1].position=1;let r=0,n=1;for(let i=0;i<this._colorMapSize;++i){const s=i/this._colorMapSize;for(;s>t[n].position;)r=n++;const o=(s-t[r].position)/(t[n].position-t[r].position),l=t[r].color,a=t[n].color,u=new se.A;Me.forEach((e=>{u[e]=Math.round((0,ue.Cc)(l[e],a[e],o))})),u.a=(0,ue.qE)(1-(0,ue.Cc)(l.a,a.a,o)/255,0,1),e.push(u)}return e}getColorForContinuousDataValue(e,t){const i=this.rasterizedTransferFunction;if(this.colorStops.length<2||!Array.isArray(this.stretchRange)||this.stretchRange.length<2||i.length<256)return null;let r=this.stretchRange[0],n=this.stretchRange[1];if(r>n){const e=r;r=n,n=e}e=(0,ue.qE)(e,r,n);const s=i[Math.round((e-r)/(n-r)*(this._colorMapSize-1))].clone();return t||(s.a=1),s}};(0,r._)([(0,c.M)({type:["linear","nearest"],json:{write:!0}})],ve.prototype,"interpolation",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],ve.prototype,"stretchRange",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(pe),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.colorStops&&this.colorStops.length>0}}}}})],ve.prototype,"colorStops",null),(0,r._)([(0,c.M)({type:s.A.ofType(he),json:{read:{source:"alphaStops"},write:{enabled:!0,target:"alphaStops",overridePolicy(){return{enabled:!!this.opacityStops&&this.opacityStops.length>0}}}}})],ve.prototype,"opacityStops",null),(0,r._)([(0,c.M)({type:me,json:{write:!0}})],ve.prototype,"rangeFilter",void 0),(0,r._)([(0,c.M)({type:[se.A],clonable:!1,json:{read:!1}})],ve.prototype,"rasterizedTransferFunction",null),ve=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelTransferFunctionStyle")],ve);const be=ve,Me=["r","g","b"];let Se=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.color=se.A.fromArray([0,0,0,0]),this.value=0,this.enabled=!0,this.label=""}};(0,r._)([(0,c.M)({type:se.A,json:{type:[p.jz],write:{enabled:!0,isRequired:!0}}})],Se.prototype,"color",void 0),(0,r._)([(0,c.M)({type:p.jz,json:{write:{enabled:!0,isRequired:!0}}})],Se.prototype,"value",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{default:!0,write:!0}})],Se.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Se.prototype,"label",void 0),Se=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelUniqueValue")],Se);const we=Se;var _e;let xe=_e=class extends z.oY{constructor(e){super(e),this.variableId=0,this.label="",this.transferFunction=null,this.uniqueValues=null,this.isosurfaces=null,this.uniqueValues=new(s.A.ofType(we)),this.isosurfaces=new(s.A.ofType(le))}clone(){return new _e({variableId:this.variableId,label:this.label,transferFunction:(0,ne.o8)(this.transferFunction),uniqueValues:(0,ne.o8)(this.uniqueValues),isosurfaces:(0,ne.o8)(this.isosurfaces)})}};(0,r._)([(0,c.M)({type:p.jz,json:{write:{enabled:!0,isRequired:!0}}})],xe.prototype,"variableId",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],xe.prototype,"label",void 0),(0,r._)([(0,c.M)({type:be,json:{write:{enabled:!0,overridePolicy(){return{enabled:!this.uniqueValues||this.uniqueValues.length<1}}}}})],xe.prototype,"transferFunction",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(we),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.uniqueValues&&this.uniqueValues.length>0}}}}})],xe.prototype,"uniqueValues",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(le),json:{write:{enabled:!0,overridePolicy(){const e=!this.uniqueValues||this.uniqueValues.length<1,t=!!this.isosurfaces&&this.isosurfaces.length>0;return{enabled:e&&t}}}}})],xe.prototype,"isosurfaces",void 0),xe=_e=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVariableStyle")],xe);const Ae=xe;var Te=i(88930),je=i(86738),Ie=i(16930),Ve=i(21325);function Fe(e){const t=/^(days?|hours?|minutes?|seconds?|d|h|m|s) since (\d{1,4})-(\d{1,2})-(\d{1,2})[ |T](\d{1,2}):(\d{1,2}):(\d{1,2})(\.[0-9]+)?[\s|Z]?(([+|\-|\s?])(\d{1,2}):(\d{1,2}))?$/i.exec(e);if(null==t)return{didParse:!1};const[,i,r,n,s,o,l,a,u,c,p,d,h]=t;let y="seconds";const m=i.charAt(0).toLowerCase();"d"===m?y="days":"h"===m?y="hours":"m"===m&&(y="minutes");const f=parseInt(r,10);if(Number.isNaN(f))return{didParse:!1};const g=parseInt(n,10);if(Number.isNaN(g)||g<1||g>12)return{didParse:!1};const v=parseInt(s,10);if(Number.isNaN(v)||v<1||v>31)return{didParse:!1};if(2===g){const e=f%4==0&&(f%100!=0||f%400==0);if(e&&v>29||!e&&v>28)return{didParse:!1}}else if((4===g||6===g||9===g||11===g)&&v>30)return{didParse:!1};const b=parseInt(o,10);if(Number.isNaN(b)||b<0||b>23)return{didParse:!1};const M=parseInt(l,10);if(Number.isNaN(M)||M<0||M>59)return{didParse:!1};const S=parseInt(a,10);if(Number.isNaN(S)||S<0||S>59)return{didParse:!1};let w=1,_=0,x=0;if(p&&(w="-"===p?-1:1),d){if(_=parseInt(d,10),Number.isNaN(_)||_<0)return{didParse:!1};if(0!==_){const e=w*_;if(e<-12||e>14)return{didParse:!1}}}if(h&&(x=parseInt(h,10),Number.isNaN(x)||x<0||x>59))return{didParse:!1};const A=`${f}`.padStart(4,"0"),T=`${g}`.padStart(2,"0"),j=`${v}`.padStart(2,"0"),I=`${b}`.padStart(2,"0"),V=`${M}`.padStart(2,"0"),F=`${S}`.padStart(2,"0");let N="Z";return 0===_&&0===x||(N=w>0?"+":"-",N+=`${_}`.padStart(2,"0"),N+=":",N+=`${x}`.padStart(2,"0")),{didParse:!0,unit:y,reference:new Date(`${A}-${T}-${j}T${I}:${V}:${F}.000${N}`)}}let Ne=class extends z.oY{constructor(){super(...arguments),this.values=null}};(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],Ne.prototype,"values",void 0),Ne=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelIrregularSpacing")],Ne);const ze=Ne;let Re=class extends z.oY{constructor(){super(...arguments),this.scale=1,this.offset=0}};(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],Re.prototype,"scale",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],Re.prototype,"offset",void 0),Re=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelRegularSpacing")],Re);const Pe=Re;let Oe=class extends z.oY{constructor(){super(...arguments),this.irregularSpacing=null,this.isPositiveUp=!0,this.isWrappedDateLine=!1,this.label=null,this.name=null,this.quantity=null,this.regularSpacing=null,this.size=0,this.unit=null}get isRegular(){return(null==this.irregularSpacing||void 0===this.irregularSpacing)&&null!==this.regularSpacing}getRange(){return this.isRegular?[this.regularSpacing.offset,this.regularSpacing.offset+this.regularSpacing.scale*(this.size-1)]:Array.isArray(this.irregularSpacing?.values)&&this.irregularSpacing.values.length>1?[this.irregularSpacing.values[0],this.irregularSpacing.values[this.irregularSpacing.values.length-1]]:[0,0]}};(0,r._)([(0,c.M)({type:ze,json:{write:!0}})],Oe.prototype,"irregularSpacing",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{write:!0}})],Oe.prototype,"isPositiveUp",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{write:!0}})],Oe.prototype,"isWrappedDateLine",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Oe.prototype,"label",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Oe.prototype,"name",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Oe.prototype,"quantity",void 0),(0,r._)([(0,c.M)({type:Pe,json:{write:!0}})],Oe.prototype,"regularSpacing",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],Oe.prototype,"size",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Oe.prototype,"unit",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{read:!1}})],Oe.prototype,"isRegular",null),Oe=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelDimension")],Oe);const De=Oe;let qe=class extends z.oY{constructor(e){super(e),this.id=0,this.dimensions=null,this.spatialReference=Ie.A.WGS84}get zDimension(){if(!this.dimensions)return-1;if(!Array.isArray(this.dimensions))return-1;if(4!==this.dimensions.length)return-1;for(let e=2;e<4;++e)if(this.dimensions[e].size>0)return e;return-1}get isValid(){return!(!this.dimensions||!Array.isArray(this.dimensions)||4!==this.dimensions.length||this.dimensions[0].size<1||this.dimensions[1].size<1||-1===this.zDimension||this.dimensions[this.zDimension].size<1)}get originInLayerSpace3D(){if(!this.isValid||"xyt"===this.volumeType)return[0,0,0];const e=this.dimensions[0].getRange(),t=this.dimensions[1].getRange(),i=this.dimensions[2],r=i.isRegular?i.getRange():[0,i.size];return[e[0],t[0],r[0]]}get voxelSizeInLayerSpaceSigned(){if(!this.isValid||"xyt"===this.volumeType)return[0,0,0];const e=this.dimensions[0].getRange(),t=this.dimensions[1].getRange(),i=this.dimensions[2],r=i.isRegular?i.getRange():[0,i.size],n=[this.sizeInVoxels[0],this.sizeInVoxels[1],this.sizeInVoxels[2]];for(let e=0;e<3;++e)n[e]<2?n[e]=1:n[e]-=1;return i.isRegular&&!i.isPositiveUp&&(n[2]*=-1),[(e[1]-e[0])/n[0],(t[1]-t[0])/n[1],(r[1]-r[0])/n[2]]}get volumeType(){if(this.isValid){const e=this.dimensions[2].size>0;let t=this.dimensions[3].size>0;if(t){const e=this.dimensions[3];t="time"===e.quantity,t&&null!==e.unit&&(t=Fe(e.unit).didParse)}if(!e&&t)return"xyt";if(e&&t)return"xyzt"}return"xyz"}get sizeInVoxels(){if(!this.isValid)return[0,0,0];const e=this.zDimension;return[this.dimensions[0].size,this.dimensions[1].size,this.dimensions[e].size]}get timeStops(){if("xyzt"!==this.volumeType)return[];const e=this.dimensions[3],t=[],i=Fe(e.unit);if(i.didParse)if(e.isRegular){const r=e.regularSpacing?.offset??0,n=e.regularSpacing?.scale||1;for(let s=0;s<e.size;++s){const e=r+n*s;t.push((0,Te.mi)(i.reference,e,i.unit))}}else if(Array.isArray(e.irregularSpacing?.values)&&e.irregularSpacing.values.length>0)for(let r=0;r<e.irregularSpacing.values.length;++r){const n=e.irregularSpacing.values[r];t.push((0,Te.mi)(i.reference,n,i.unit))}return t}computeVoxelSpaceLocation(e){if(!this.isValid)return[0,0,0];if("xyt"===this.volumeType)return l.A.getLogger(this).error("computeVoxelSpacePosition cannot be used with XYT volumes."),[0,0,0];if(!(0,Ve.aI)(this.spatialReference,e.spatialReference))return l.A.getLogger(this).error("pos argument should have the same spatial reference as the VoxelLayer."),[0,0,0];const t=(0,m.fA)(e.x,e.y,e.z??0);(0,y.f)(t,t,this.originInLayerSpace3D),(0,y.D)(t,t,this.voxelSizeInLayerSpaceSigned);const i=this.dimensions[this.zDimension];if(!i.isRegular&&Array.isArray(i.irregularSpacing?.values)&&i.irregularSpacing.values.length>1){const r=e.z??0,n=i.irregularSpacing.values,s=i.isPositiveUp?1:-1,o=n.reduce(((e,t)=>Math.abs(s*t-r)<Math.abs(s*e-r)?t:e));for(let e=0;e<n.length;++e)if(n[e]===o){t[2]=e;break}}return[t[0],t[1],t[2]]}computeLayerSpaceLocation(e){if(!this.isValid)return new je.A({x:0,y:0,spatialReference:this.spatialReference});const t=(0,m.ci)(e);if((0,y.B)(t,t,this.voxelSizeInLayerSpaceSigned),(0,y.g)(t,t,this.originInLayerSpace3D),"xyt"===this.volumeType)return new je.A({x:t[0],y:t[1],spatialReference:this.spatialReference});const i=this.dimensions[this.zDimension];return i.isRegular||Array.isArray(i.irregularSpacing?.values)&&(e[2]<0?t[2]=i.irregularSpacing.values[0]:e[2]<i.irregularSpacing.values.length?t[2]=i.irregularSpacing.values[e[2]]:t[2]=i.irregularSpacing.values[i.irregularSpacing.values.length-1],i.isPositiveUp||(t[2]*=-1)),new je.A({x:t[0],y:t[1],z:t[2],spatialReference:this.spatialReference})}};(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],qe.prototype,"id",void 0),(0,r._)([(0,c.M)({type:[De],json:{write:{enabled:!0,isRequired:!0}}})],qe.prototype,"dimensions",void 0),(0,r._)([(0,c.M)({type:Ie.A,json:{read:{enabled:!1}}})],qe.prototype,"spatialReference",void 0),(0,r._)([(0,c.M)({type:Number,json:{read:!1}})],qe.prototype,"zDimension",null),(0,r._)([(0,c.M)({type:[Boolean],json:{read:!1}})],qe.prototype,"isValid",null),(0,r._)([(0,c.M)({type:[Number],json:{read:!1}})],qe.prototype,"originInLayerSpace3D",null),(0,r._)([(0,c.M)({type:[Number],json:{read:!1}})],qe.prototype,"voxelSizeInLayerSpaceSigned",null),(0,r._)([(0,c.M)({type:["xyz","xyzt","xyt"],json:{read:{enabled:!1}}})],qe.prototype,"volumeType",null),(0,r._)([(0,c.M)({type:[Number],json:{read:!1}})],qe.prototype,"sizeInVoxels",null),(0,r._)([(0,c.M)({type:[Date],json:{read:!1,write:!1}})],qe.prototype,"timeStops",null),qe=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVolume")],qe);const Ee=qe;var Le;let $e=Le=class extends z.oY{constructor(){super(...arguments),this.apronWidth=1,this.brickSize=[32,32,32],this.maxLodLevel=0,this.nodeSize=[4,4,4]}isValid(){const e=new Le;return e.apronWidth===this.apronWidth&&e.maxLodLevel===this.maxLodLevel&&!!this.brickSize&&!!this.nodeSize&&!(!Array.isArray(this.brickSize)||!Array.isArray(this.nodeSize))&&3===this.brickSize.length&&3===this.nodeSize.length&&32===this.brickSize[0]&&32===this.brickSize[1]&&32===this.brickSize[2]&&4===this.nodeSize[0]&&4===this.nodeSize[1]&&4===this.nodeSize[2]}};(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],$e.prototype,"apronWidth",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],$e.prototype,"brickSize",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],$e.prototype,"maxLodLevel",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],$e.prototype,"nodeSize",void 0),$e=Le=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVolumeIndex")],$e);const Ue=$e;let Ce=class extends((0,F.O)(z.oY)){constructor(e){super(e),this.enabled=!0,this.label="",this.normal=null,this.point=null}get orientation(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,p.GB)(e),0,!0)}set orientation(e){const t=Y(e,this.tilt);this._set("normal",t),this._set("orientation",e)}get tilt(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,p.GB)(t),0,!0)}set tilt(e){const t=Y(this.orientation,e);this._set("normal",t),this._set("tilt",e)}};(0,r._)([(0,c.M)({type:Boolean,json:{default:!0,write:!0}})],Ce.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Ce.prototype,"label",void 0),(0,r._)([(0,c.M)({type:Number,json:{read:!1},clonable:!1,range:{min:0,max:360}}),(0,H.w)((e=>N.ie.normalize((0,p.GB)(e),0,!0)))],Ce.prototype,"orientation",null),(0,r._)([(0,c.M)({type:Number,json:{read:!1},clonable:!1,range:{min:0,max:360}}),(0,H.w)((e=>N.ie.normalize((0,p.GB)(e),0,!0)))],Ce.prototype,"tilt",null),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],Ce.prototype,"normal",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],Ce.prototype,"point",void 0),Ce=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelDynamicSection")],Ce);const Be=Ce;var ke;let Ye=ke=class extends z.oY{constructor(e){super(e),this.volumeId=0,this.verticalExaggeration=1,this.exaggerationMode="scale-height",this.verticalOffset=0,this.slices=new(s.A.ofType(Z)),this.dynamicSections=new(s.A.ofType(Be))}set slices(e){this._set("slices",(0,ae.V)(e,this._get("slices"),s.A.ofType(Z)))}set dynamicSections(e){this._set("dynamicSections",(0,ae.V)(e,this._get("dynamicSections"),s.A.ofType(Be)))}clone(){return new ke({volumeId:this.volumeId,verticalExaggeration:this.verticalExaggeration,exaggerationMode:this.exaggerationMode,verticalOffset:this.verticalOffset,slices:(0,ne.o8)(this.slices),dynamicSections:(0,ne.o8)(this.dynamicSections)})}};(0,r._)([(0,c.M)({type:p.jz,json:{write:{enabled:!0,isRequired:!0}}})],Ye.prototype,"volumeId",void 0),(0,r._)([(0,c.M)({type:Number,json:{default:1,write:!0}})],Ye.prototype,"verticalExaggeration",void 0),(0,r._)([(0,c.M)({type:["scale-position","scale-height"],json:{default:"scale-height",write:!0}})],Ye.prototype,"exaggerationMode",void 0),(0,r._)([(0,c.M)({type:Number,json:{default:0,write:!0}})],Ye.prototype,"verticalOffset",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(Z),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.slices&&this.slices.length>0}}}}})],Ye.prototype,"slices",null),(0,r._)([(0,c.M)({type:s.A.ofType(Be),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.dynamicSections&&this.dynamicSections.length>0}}}}})],Ye.prototype,"dynamicSections",null),Ye=ke=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVolumeStyle")],Ye);const He=Ye;var Je=i(30291),Ze=i(79677),Ge=i(10184);let Ke=class extends((0,x.w6)((0,b.b)((0,S.q)((0,w.A)((0,_.j)((0,a.P)((0,M.d)((0,v.p)(g.A))))))))){constructor(e){super(e),this.serviceRoot="",this.operationalLayerType="Voxel",this.legendEnabled=!0,this.title=null,this.sections=null,this.currentVariableId=0,this.volumeStyles=null,this.renderMode="volume",this.variableStyles=null,this.enableSlices=!0,this.enableSections=!0,this.enableDynamicSections=!0,this.enableIsosurfaces=!0,this.shading=new X,this.opacity=1,this.variables=new s.A,this.volumes=new s.A,this.index=null,this.minScale=0,this.maxScale=0,this.type="voxel",this.version={major:Number.NaN,minor:Number.NaN,versionString:""},this.fullExtent=null,this.popupEnabled=!1,this.popupTemplate=null,this.test=null,this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0,this.volumeStyles=new(s.A.ofType(He)),this.variableStyles=new(s.A.ofType(Ae)),this.sections=new(s.A.ofType(W))}normalizeCtorArgs(e){return e?.constantUpscaling&&(this.test={constantUpscaling:!0},delete e.constantUpscaling),e}set url(e){this._set("url",(0,A.Jf)(e,l.A.getLogger(this)))}load(e){const t=null!=e?e.signal:null,i=this.loadFromPortal({supportedTypes:["Scene Service"]},e).catch(u.QP).then((()=>this._fetchService(t))).then((()=>this.serviceRoot=this.url));return this.addResolvingPromise(i),Promise.resolve(this)}read(e,t){super.read(e,t),"service"===t?.origin&&this.version.major<=3&&this.version.minor<=0&&!this.getAtOrigin("popupTemplate","service")&&this.setAtOrigin("popupTemplate",this.createPopupTemplate(),"service");for(const e of this.volumes)e.spatialReference=this.spatialReference}readVersion(e,t){return super.parseVersionString(e)}validateLayer(e){if(e.layerType&&e.layerType!==this.operationalLayerType)throw new o.A("voxel-layer:layer-type-not-supported","VoxelLayer does not support this layer type",{layerType:e.layerType});if(isNaN(this.version.major)||isNaN(this.version.minor)||this.version.major<3)throw new o.A("layer:service-version-not-supported","Service version is not supported.",{serviceVersion:this.version.versionString,supportedVersions:"3.x"});if(this.version.major>3)throw new o.A("layer:service-version-too-new","Service version is too new.",{serviceVersion:this.version.versionString,supportedVersions:"3.x"})}readFullExtent(e,t,i){if(null!=e&&"object"==typeof e){const r=f.A.fromJSON(e,i);if(0===r.zmin&&0===r.zmax&&Array.isArray(t.volumes)){const e=Ee.fromJSON(t.volumes[0]);if(e.isValid&&"xyt"!==e.volumeType){const t=e.dimensions[2];if(t.isRegular){let e=t.regularSpacing.offset,i=t.regularSpacing.offset+t.regularSpacing.scale*(t.size-1);if(e>i){const t=e;e=i,i=t}r.zmin=e,r.zmax=i}}}return r}return null}get fields(){const e=[new j.A({name:"Voxel.Position",alias:"Voxel Position",domain:null,editable:!1,length:128,type:"string"}),new j.A({name:"Voxel.CurrentVariable",alias:"Current Variable",domain:null,editable:!1,length:128,type:"string"})];for(const t of this.variables){const i=new j.A({name:t.name,alias:t.description,domain:null,editable:!1,length:128,type:"discrete"===t.renderingFormat.continuity?"string":"double"});e.push(i)}const t=this.getVolume(null);if(null!=t){if("xyzt"===t.volumeType||"xyt"===t.volumeType){const t=new j.A({name:"Voxel.LocalTime",alias:"Local Time",domain:null,editable:!1,length:256,type:"date"});e.push(t);const i=new j.A({name:"Voxel.SourceTime",alias:"Source Time",domain:null,editable:!1,length:256,type:"string"});e.push(i)}if("xyt"!==t.volumeType){const t=new j.A({name:"Voxel.Depth",alias:"Depth",domain:null,editable:!1,length:128,type:"double"});e.push(t)}}return e}get fieldsIndex(){return this.loaded?new I.A(this.fields):null}getField(e){return this.fieldsIndex?.get(e)}get defaultPopupTemplate(){return this.createPopupTemplate()}createPopupTemplate(e){const t=this.fields;return(0,Je.tn)({fields:t,title:"{Voxel.Position}"},e)}getConfiguration(){const e={layerType:this.operationalLayerType,version:this.version.versionString,name:this.title,spatialReference:this.spatialReference,fullExtent:this.fullExtent,volumes:this.volumes.toJSON(),variables:this.variables.toJSON(),index:this.index?.toJSON(),sections:this.getSections(),style:{volumeStyles:this.getVolumeStyles(),currentVariableId:this.currentVariableId,renderMode:this.renderMode,variableStyles:this.getVariableStyles(),enableSections:this.enableSections,enableDynamicSections:this.enableDynamicSections,enableIsosurfaces:this.enableIsosurfaces,enableSlices:this.enableSlices,shading:this.shading}};return e.index&&this.index?.isValid()?JSON.stringify(e):""}getVariableStyle(e){let t=-1;if(t=null!=e?e:this.currentVariableId,!this.variableStyles||-1===t)return null;const i=this.variableStyles.findIndex((e=>e.variableId===t));return i<0?null:this.variableStyles.at(i)}getVariable(e){let t=-1;if(t=null!=e?e:this.currentVariableId,!this.variables||-1===t)return null;const i=this.variables.findIndex((e=>e.id===t));return i<0?null:this.variables.at(i)}getVolume(e){const t=this.getVariable(e);return null!=t?this.volumes.find((({id:e})=>e===t.volumeId)):null}get timeInfo(){const e=this.getVolume(null);if("xyzt"!==e?.volumeType)return null;const t=e.timeStops;if(!t?.length)return null;const i=new Ze.A({start:t[0],end:t.at(-1)});return new V.A({fullTimeExtent:i,stops:t})}getVolumeStyle(e){const t=this.getVariable(e);return null!=t?this.volumeStyles.find((({volumeId:e})=>e===t.volumeId)):null}getColorForContinuousDataValue(e,t,i){const r=this.getVariable(e);if(null==r||"continuous"!==r.renderingFormat?.continuity)return null;if(!this.variableStyles)return null;const n=this.variableStyles.findIndex((t=>t.variableId===e));if(n<0)return null;const s=this.variableStyles.at(n);return s?.transferFunction?s.transferFunction.getColorForContinuousDataValue(t,i):null}getSections(){const e=[];for(const t of this.sections)e.push(new W({enabled:t.enabled,href:t.href,id:t.id,label:t.label,normal:t.normal,point:t.point,sizeInPixel:t.sizeInPixel,slices:t.slices,timeId:t.timeId,variableId:t.variableId}));return e}getVariableStyles(){const e=[];for(const t of this.variableStyles){const i=this._getVariable(t);if(null!=i){const r=t.clone();r.isosurfaces.length>4&&(r.isosurfaces=r.isosurfaces.slice(0,3),l.A.getLogger(this).error("A maximum of 4 isosurfaces are supported for Voxel Layers."));for(const e of r.isosurfaces)if(!e.colorLocked){const t=this.getColorForContinuousDataValue(r.variableId,e.value,!1);null===t||t.equals(e.color)||(e.color=t)}if("continuous"===i.renderingFormat.continuity)(null===r.transferFunction||r.transferFunction.colorStops.length<2)&&l.A.getLogger(this).error(`VoxelVariableStyle for variable ${i.id} is invalid. At least 2 color stops are required in the transferFunction for continuous Voxel Layer variables.`),null!==r.transferFunction&&(Array.isArray(r.transferFunction.stretchRange)&&2===r.transferFunction.stretchRange.length||(l.A.getLogger(this).error(`VoxelVariableStyle for variable ${i.id} is invalid. The stretchRange of the transferFunction for continuous Voxel Layer variables must be of the form [minimumDataValue, maximumDataValue].`),r.transferFunction.stretchRange=[0,1],r.transferFunction.colorStops.removeAll()));else if("discrete"===i.renderingFormat.continuity)if(0===t.uniqueValues.length)l.A.getLogger(this).error(`VoxelVariableStyle for variable ${i.id} is invalid. Unique values are required for discrete Voxel Layer variables.`);else for(const e of t.uniqueValues)null!==e.label&&void 0!==e.label||null===e.value||void 0===e.value||(e.label=e.value.toString());e.push(r)}else l.A.getLogger(this).error(`VoxelVariable ID=${t.variableId} doesn't exist, VoxelVariableStyle for this VoxelVariable will be ignored.`)}return e}getVolumeStyles(){const e=[];for(const t of this.volumeStyles){const i=this._getVolumeFromVolumeId(t.volumeId);if(null!=i){const r=t.clone();for(const e of r.slices)this._isPlaneValid(e,[0,1,i.zDimension],i.dimensions)||(e.enabled=!1,e.label="invalid");for(const e of r.dynamicSections)this._isPlaneValid(e,[0,1,i.zDimension],i.dimensions)||(e.enabled=!1,e.label="invalid");e.push(r)}else l.A.getLogger(this).error(`VoxelVolume ID=${t.volumeId} doesn't exist, VoxelVolumeStyle for this VoxelVolume will be ignored.`)}return e}_getVariable(e){const t=e.variableId;for(const e of this.variables)if(e.id===t)return e;return null}_getVolumeFromVolumeId(e){for(const t of this.volumes)if(t.id===e)return t;return null}_isPlaneValid(e,t,i){if(!e.point)return!1;if(!Array.isArray(e.point)||3!==e.point.length)return!1;if(!e.normal)return!1;if(!Array.isArray(e.normal)||3!==e.normal.length)return!1;const r=(0,m.fA)(e.normal[0],e.normal[1],e.normal[2]);return(0,y.n)(r,r),!(Math.abs(r[0])+Math.abs(r[1])+Math.abs(r[2])<1e-6||(e.normal[0]=r[0],e.normal[1]=r[1],e.normal[2]=r[2],0))}};(0,r._)([(0,c.M)({type:["Voxel"]})],Ke.prototype,"operationalLayerType",void 0),(0,r._)([(0,c.M)(T.fV)],Ke.prototype,"legendEnabled",void 0),(0,r._)([(0,c.M)({json:{write:!0}})],Ke.prototype,"title",void 0),(0,r._)([(0,c.M)(T.OZ)],Ke.prototype,"url",null),(0,r._)([(0,c.M)({type:s.A.ofType(W),json:{origins:{"web-scene":{name:"layerDefinition.sections",write:!0}}}})],Ke.prototype,"sections",void 0),(0,r._)([(0,c.M)({type:p.jz,json:{origins:{"web-scene":{name:"layerDefinition.style.currentVariableId",write:{enabled:!0,isRequired:!0,ignoreOrigin:!0}},service:{name:"style.currentVariableId"}}}})],Ke.prototype,"currentVariableId",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(He),json:{origins:{"web-scene":{name:"layerDefinition.style.volumeStyles",write:!0},service:{name:"style.volumeStyles"}}}})],Ke.prototype,"volumeStyles",void 0),(0,r._)([(0,c.M)({type:["volume","surfaces"],json:{origins:{"web-scene":{name:"layerDefinition.style.renderMode",write:!0},service:{name:"style.renderMode"}}}})],Ke.prototype,"renderMode",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(Ae),json:{origins:{"web-scene":{name:"layerDefinition.style.variableStyles",write:!0},service:{name:"style.variableStyles"}}}})],Ke.prototype,"variableStyles",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{origins:{"web-scene":{name:"layerDefinition.style.enableSlices",write:!0},service:{name:"style.enableSlices"}}}})],Ke.prototype,"enableSlices",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{origins:{"web-scene":{name:"layerDefinition.style.enableSections",write:!0},service:{name:"style.enableSections"}}}})],Ke.prototype,"enableSections",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{origins:{"web-scene":{name:"layerDefinition.style.enableDynamicSections",write:!0},service:{name:"style.enableDynamicSections"}}}})],Ke.prototype,"enableDynamicSections",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{origins:{"web-scene":{name:"layerDefinition.style.enableIsosurfaces",write:!0},service:{name:"style.enableIsosurfaces"}}}})],Ke.prototype,"enableIsosurfaces",void 0),(0,r._)([(0,c.M)({type:X,json:{origins:{"web-scene":{name:"layerDefinition.style.shading",write:!0},service:{name:"style.shading"}}}})],Ke.prototype,"shading",void 0),(0,r._)([(0,c.M)({type:["show","hide"]})],Ke.prototype,"listMode",void 0),(0,r._)([(0,c.M)({type:Number,range:{min:0,max:1},nonNullable:!0,json:{read:!1,write:!1,origins:{"web-scene":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],Ke.prototype,"opacity",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(re)})],Ke.prototype,"variables",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(Ee)})],Ke.prototype,"volumes",void 0),(0,r._)([(0,c.M)({type:Ue})],Ke.prototype,"index",void 0),(0,r._)([(0,c.M)({type:Number,json:{name:"layerDefinition.minScale",write:!0,origins:{service:{read:!1,write:!1}}}})],Ke.prototype,"minScale",void 0),(0,r._)([(0,c.M)({type:Number,json:{name:"layerDefinition.maxScale",write:!0,origins:{service:{read:!1,write:!1}}}})],Ke.prototype,"maxScale",void 0),(0,r._)([(0,c.M)({json:{read:!1},readOnly:!0})],Ke.prototype,"type",void 0),(0,r._)([(0,c.M)({readOnly:!0,json:{name:"serviceVersion"}})],Ke.prototype,"version",void 0),(0,r._)([(0,d.w)("service","version")],Ke.prototype,"readVersion",null),(0,r._)([(0,c.M)({type:f.A})],Ke.prototype,"fullExtent",void 0),(0,r._)([(0,d.w)("service","fullExtent",["fullExtent"])],Ke.prototype,"readFullExtent",null),(0,r._)([(0,c.M)({readOnly:!0,clonable:!1,json:{read:!1}})],Ke.prototype,"fields",null),(0,r._)([(0,c.M)({readOnly:!0})],Ke.prototype,"fieldsIndex",null),(0,r._)([(0,c.M)({type:Boolean,json:{name:"disablePopup",read:{reader:(e,t)=>!t.disablePopup},write:{enabled:!0,ignoreOrigin:!0,writer(e,t,i){t[i]=!e}},origins:{"portal-item":{default:!0},"web-scene":{default:!0}}}})],Ke.prototype,"popupEnabled",void 0),(0,r._)([(0,c.M)({type:n.A,json:{name:"popupInfo",write:!0}})],Ke.prototype,"popupTemplate",void 0),(0,r._)([(0,c.M)({readOnly:!0,json:{read:!1}})],Ke.prototype,"defaultPopupTemplate",null),(0,r._)([(0,c.M)({type:V.A,readOnly:!0,json:{read:!1}})],Ke.prototype,"timeInfo",null),(0,r._)([(0,c.M)({type:Ze.A,json:{read:!1}})],Ke.prototype,"timeExtent",void 0),(0,r._)([(0,c.M)({type:Ge.A,json:{read:!1}})],Ke.prototype,"timeOffset",void 0),(0,r._)([(0,c.M)({type:Boolean,nonNullable:!0,json:{origins:{"web-scene":{name:"timeAnimation",write:!0},service:{read:!1}}}})],Ke.prototype,"useViewTime",void 0),Ke=(0,r._)([(0,h.$)("esri.layers.VoxelLayer")],Ke);const We=Ke},52136:(e,t,i)=>{i.d(t,{p:()=>o});var r=i(90237),n=i(10107),s=(i(44208),i(53966),i(87811),i(40608));const o=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,r._)([(0,n.M)({type:String})],t.prototype,"apiKey",null),t=(0,r._)([(0,s.$)("esri.layers.mixins.APIKeyMixin")],t),t}},18768:(e,t,i)=>{i.d(t,{b:()=>a});var r=i(90237),n=i(53966),s=i(10107),o=(i(44208),i(87811),i(40608)),l=i(60694);const a=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.qg)(this.url);if(null!=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.Jf)(e,n.A.getLogger(this)))}};return(0,r._)([(0,s.M)()],t.prototype,"title",null),(0,r._)([(0,s.M)({type:String})],t.prototype,"url",null),t=(0,r._)([(0,o.$)("esri.layers.mixins.ArcGISService")],t),t}},69208:(e,t,i)=>{i.d(t,{d:()=>o});var r=i(90237),n=i(10107),s=(i(44208),i(53966),i(87811),i(40608));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,r._)([(0,n.M)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,r._)([(0,s.$)("esri.layers.mixins.CustomParametersMixin")],t),t}},8303:(e,t,i)=>{i.d(t,{A:()=>w});var r=i(90237),n=i(92602),s=i(70333),o=i(78888),l=i(60999),a=i(49186),u=i(53966),c=i(97768),p=i(74887),d=i(84952),h=i(10107),y=(i(44208),i(87811),i(36005)),m=i(40608),f=i(43937),g=i(83531),v=i(20655),b=i(80812),M=i(41318),S=i(10407);const w=e=>{let t=class extends e{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,c.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,i){if(t.itemId)return new b.default({id:t.itemId,portal:i?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:r}=await Promise.all([i.e(5356),i.e(1204)]).then(i.bind(i,41204));return(0,p.Te)(t),await r({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap},t)}catch(e){throw(0,p.zf)(e)||u.A.getLogger(this).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,p.QP)(e),!0))))}async setUserPrivileges(e,t){if(!n.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:i,fullEdit:r},content:{updateItem:n}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",i),this._set("userHasFullEditingPrivileges",r),this._set("userHasUpdateItemPrivileges",n)}catch(e){(0,p.QP)(e)}}async _fetchUserPrivileges(e,t){let i=this.portalItem;if(!e||!i||!i.loaded||i.sourceUrl)return this._fetchFallbackUserPrivileges(t);const r=e===i.id;if(r&&i.portal.user)return(0,S.It)(i);let n,o;if(r)n=i.portal.url;else try{n=await(0,g.wI)(this.url,t)}catch(e){(0,p.QP)(e)}if(!n||!(0,d.b8)(n,i.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;o=await(s.id?.getCredential(`${n}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,p.QP)(e)}const l=!0,a=!1,u=!1;if(!o)return{features:{edit:l,fullEdit:a},content:{updateItem:u}};try{if(r?await i.reload():(i=new b.default({id:e,portal:{url:n}}),await i.load(t)),i.portal.user)return(0,S.It)(i)}catch(e){(0,p.QP)(e)}return{features:{edit:l,fullEdit:a},content:{updateItem:u}}}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,p.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?s.id?.findCredential(this.url):null;if(!t)return!0;const i=_.credential===t?_.user:await this._fetchEditingUser(e);return _.credential=t,_.user=i,null==i?.privileges||i.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const i=s.id?.findServerInfo(this.url??"");if(!i?.owningSystemUrl)return null;const r=`${i.owningSystemUrl}/sharing/rest`,n=v.A.getDefault();if(n&&n.loaded&&(0,d.S8)(n.restUrl)===(0,d.S8)(r))return n.user;const a=`${r}/community/self`,u=null!=e?e.signal:null,c=await(0,l.Ke)((0,o.A)(a,{authMode:"no-prompt",query:{f:"json"},signal:u}));return c.ok?M.A.fromJSON(c.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const i=t?.portal,r=this.portalItem?.id&&(this.portalItem.portal||v.A.getDefault());return i&&r&&!(0,d.ut)(r.restUrl,i.restUrl)?(t.messages&&t.messages.push(new a.A("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,r._)([(0,h.M)({type:b.default})],t.prototype,"portalItem",null),(0,r._)([(0,y.w)("web-document","portalItem",["itemId"])],t.prototype,"readPortalItem",null),(0,r._)([(0,f.K)("web-document","portalItem",{itemId:{type:String}})],t.prototype,"writePortalItem",null),(0,r._)([(0,h.M)({clonable:!1})],t.prototype,"resourceReferences",void 0),(0,r._)([(0,h.M)({type:Boolean,readOnly:!0})],t.prototype,"userHasEditingPrivileges",void 0),(0,r._)([(0,h.M)({type:Boolean,readOnly:!0})],t.prototype,"userHasFullEditingPrivileges",void 0),(0,r._)([(0,h.M)({type:Boolean,readOnly:!0})],t.prototype,"userHasUpdateItemPrivileges",void 0),t=(0,r._)([(0,m.$)("esri.layers.mixins.PortalLayer")],t),t},_={credential:null,user:null}},25036:(e,t,i)=>{i.d(t,{j:()=>o});var r=i(90237),n=i(10107),s=(i(44208),i(53966),i(87811),i(40608));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.minScale=0,this.maxScale=0}get effectiveScaleRange(){const e={minScale:this.minScale,maxScale:this.maxScale},t=this.parent;t&&"effectiveScaleRange"in t&&function(e,t){e.minScale=e.minScale>0?t.minScale>0?Math.min(e.minScale,t.minScale):e.minScale:t.minScale,e.maxScale=e.maxScale>0?t.maxScale>0?Math.max(e.maxScale,t.maxScale):e.maxScale:t.maxScale}(e,t.effectiveScaleRange);const i=this._get("effectiveScaleRange");return i&&i.minScale===e.minScale&&i.maxScale===e.maxScale?i:e}};return(0,r._)([(0,n.M)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"minScale",void 0),(0,r._)([(0,n.M)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"maxScale",void 0),(0,r._)([(0,n.M)({readOnly:!0})],t.prototype,"effectiveScaleRange",null),t=(0,r._)([(0,s.$)("esri.layers.mixins.ScaleRangeLayer")],t),t}},20437:(e,t,i)=>{i.d(t,{A:()=>f});var r,n=i(90237),s=i(66552),o=i(25482),l=i(10107),a=i(56507),u=(i(87811),i(44208),i(93223)),c=i(36005),p=i(40608),d=i(72088),h=i(98453);const y=new s.J({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",dateAndTime:"date-and-time",description:"description",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier"});let m=r=class extends o.oY{constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let i=null;try{i=t?JSON.parse(t):null}catch(e){}return i?.value??null}readValueType(e,{description:t}){let i=null;try{i=t?JSON.parse(t):null}catch(e){}return i?y.fromJSON(i.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain?.clone()??null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,n._)([(0,l.M)({type:String,json:{write:!0}})],m.prototype,"alias",void 0),(0,n._)([(0,l.M)({type:[String,Number],json:{write:{allowNull:!0}}})],m.prototype,"defaultValue",void 0),(0,n._)([(0,l.M)()],m.prototype,"description",void 0),(0,n._)([(0,c.w)("description")],m.prototype,"readDescription",null),(0,n._)([(0,l.M)({types:d.gK,json:{read:{reader:d.rS},write:!0}})],m.prototype,"domain",void 0),(0,n._)([(0,l.M)({type:Boolean,json:{write:!0}})],m.prototype,"editable",void 0),(0,n._)([(0,l.M)({type:a.jz,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],m.prototype,"length",void 0),(0,n._)([(0,l.M)({type:String,json:{write:!0}})],m.prototype,"name",void 0),(0,n._)([(0,l.M)({type:Boolean,json:{write:!0}})],m.prototype,"nullable",void 0),(0,n._)([(0,u.e)(h.m)],m.prototype,"type",void 0),(0,n._)([(0,l.M)()],m.prototype,"valueType",void 0),(0,n._)([(0,c.w)("valueType",["description"])],m.prototype,"readValueType",null),(0,n._)([(0,l.M)({type:Boolean,json:{read:!1}})],m.prototype,"visible",void 0),m=r=(0,n._)([(0,p.$)("esri.layers.support.Field")],m);const f=m},95466:(e,t,i)=>{i.d(t,{A:()=>d});var r=i(49186),n=i(25482),s=i(53966),o=i(91869),l=i(3330),a=i(30524),u=i(56400),c=i(96285);const p=new Map;class d{static fromJSON(e){return new d(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new d(e.fields??[],f(e))}static fromLayerJSON(e){return new d(e.fields??[],f(e))}constructor(e=[],t){this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this._requiredFields=null,this.dateFields=[],this.numericFields=[],this.fields=e||[],this._timeZoneByFieldName=t?new Map(t):null;const i=[];for(const e of this.fields){const t=e?.name,r=y(t);if(t&&r){const n=h(t);this._fieldsMap.set(t,e),this._fieldsMap.set(n,e),this._normalizedFieldsMap.set(r,e),i.push(`${n}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,a.vE)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,a.WA)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,a.te)(e)||(0,a.Xz)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}i.sort(),this.uid=i.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,a.te)(e)||(0,a.Xz)(e)||e.nullable||void 0!==(0,a.lD)(e)||this._requiredFields.push(e)}return this._requiredFields}equals(e){return this.uid===e?.uid}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(h(e))??this._normalizedFieldsMap.get(y(e)),t&&this._fieldsMap.set(e,t),t)}getTimeZone(e){const t=this.get(e&&"string"!=typeof e?e.name:e);return t?this._timeZoneByFieldName?this._timeZoneByFieldName.get(t.name):"date"===t.type||"esriFieldTypeDate"===t.type?(s.A.getLogger("esri.layers.support.FieldsIndex").error(new r.A("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),u.n$):m.has(t.type)?u.L5:null:null}getLuxonTimeZone(e){const t=this.getTimeZone(e);return t?t===u.L5?l.GB.instance:t===u.n$?c.mQ.utcInstance:(0,o.tE)(p,t,(()=>c.oh.create(t))):null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,a.OH)(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){return this.get(e)?.name??void 0}toJSON(){return{fields:this.fields.map((e=>(0,n.Wj)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function h(e){return e.trim().toLowerCase()}function y(e){return(0,a.rS)(e)?.toLowerCase()??""}const m=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function f(e){const t=new Map;if(!e.fields)return t;const i=!0===e.datesInUnknownTimezone,{timeInfo:r,editFieldsInfo:n}=e,s=(r?"startField"in r?r.startField:r.startTimeField:"")??"",o=(r?"endField"in r?r.endField:r.endTimeField:"")??"",l=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,u.ZS)(e.dateFieldsTimeReference):null,a=n?function(e){return"timeZone"in e}(n)?n.timeZone??l:n.dateFieldsTimeReference?(0,u.ZS)(n.dateFieldsTimeReference):l??u.n$:null,c=r?function(e){return"timeZone"in e}(r)?r.timeZone??l:r.timeReference?(0,u.ZS)(r.timeReference):l:null,p=new Map([[h(n?.creationDateField??""),a],[h(n?.editDateField??""),a],[h(s),c],[h(o),c]]);for(const{name:r,type:n}of e.fields)if(m.has(n))t.set(r,u.L5);else if("date"!==n&&"esriFieldTypeDate"!==n)t.set(r,null);else if(i)t.set(r,u.L5);else{const e=p.get(h(r??""))??l;t.set(r,e)}return t}},96184:(e,t,i)=>{i.d(t,{A:()=>m});var r=i(90237),n=i(69540),s=i(25482),o=i(10107),l=(i(44208),i(53966),i(87811),i(36005)),a=i(40608),u=i(43937),c=i(79677),p=i(10184),d=i(56400);function h(e,t){return p.A.fromJSON({value:e,unit:t})}let y=class extends((0,n.O)(s.oY)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?c.A.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?h(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?h(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,r._)([(0,o.M)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],y.prototype,"cumulative",void 0),(0,r._)([(0,o.M)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"endField",void 0),(0,r._)([(0,o.M)({type:c.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"fullTimeExtent",void 0),(0,r._)([(0,l.w)("fullTimeExtent",["timeExtent"])],y.prototype,"readFullTimeExtent",null),(0,r._)([(0,u.K)("fullTimeExtent")],y.prototype,"writeFullTimeExtent",null),(0,r._)([(0,o.M)({type:Boolean,json:{write:!0}})],y.prototype,"hasLiveData",void 0),(0,r._)([(0,o.M)({type:p.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"interval",void 0),(0,r._)([(0,l.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],y.prototype,"readInterval",null),(0,r._)([(0,u.K)("interval")],y.prototype,"writeInterval",null),(0,r._)([(0,o.M)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"startField",void 0),(0,r._)([(0,o.M)((0,d.P6)("timeReference",!0))],y.prototype,"timeZone",void 0),(0,r._)([(0,o.M)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"trackIdField",void 0),(0,r._)([(0,o.M)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],y.prototype,"useTime",void 0),(0,r._)([(0,o.M)({type:[Date],json:{read:!1}})],y.prototype,"stops",void 0),y=(0,r._)([(0,a.$)("esri.layers.support.TimeInfo")],y);const m=y},72088:(e,t,i)=>{i.d(t,{rS:()=>x,gK:()=>_}),i(44208);var r,n=i(90237),s=i(4718),o=i(10107),l=(i(53966),i(93223)),a=i(40608),u=i(25482);i(87811);let c=r=class extends u.oY{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,n._)([(0,o.M)({type:String,json:{write:!0}})],c.prototype,"name",void 0),(0,n._)([(0,o.M)({type:[String,Number],json:{write:!0}})],c.prototype,"code",void 0),c=r=(0,n._)([(0,a.$)("esri.layers.support.CodedValue")],c);const p=new(i(66552).J)({inherited:"inherited",codedValue:"coded-value",range:"range"});let d=class extends u.oY{constructor(e){super(e),this.name=null,this.type=null}};(0,n._)([(0,o.M)({type:String,json:{write:!0}})],d.prototype,"name",void 0),(0,n._)([(0,l.e)(p)],d.prototype,"type",void 0),d=(0,n._)([(0,a.$)("esri.layers.support.Domain")],d);const h=d;var y;let m=y=class extends h{constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const i=String(e);this.codedValues.some((e=>(String(e.code)===i&&(t=e.name),!!t)))}return t}clone(){return new y({codedValues:(0,s.o8)(this.codedValues),name:this.name})}};(0,n._)([(0,o.M)({type:[c],json:{write:!0}})],m.prototype,"codedValues",void 0),(0,n._)([(0,l.e)({codedValue:"coded-value"})],m.prototype,"type",void 0),m=y=(0,n._)([(0,a.$)("esri.layers.support.CodedValueDomain")],m);const f=m;var g;i(49186);let v=g=class extends h{constructor(e){super(e),this.type="inherited"}clone(){return new g}};(0,n._)([(0,l.e)({inherited:"inherited"})],v.prototype,"type",void 0),v=g=(0,n._)([(0,a.$)("esri.layers.support.InheritedDomain")],v);const b=v;var M;let S=M=class extends h{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new M({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,n._)([(0,o.M)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,i){t[i]=[this.minValue||0,e]}}}})],S.prototype,"maxValue",void 0),(0,n._)([(0,o.M)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,i){t[i]=[e,this.maxValue||0]}}}})],S.prototype,"minValue",void 0),(0,n._)([(0,l.e)({range:"range"})],S.prototype,"type",void 0),S=M=(0,n._)([(0,a.$)("esri.layers.support.RangeDomain")],S);const w=S,_={key:"type",base:h,typeMap:{range:S,"coded-value":f,inherited:b}};function x(e){if(!e?.type)return null;switch(e.type){case"range":return w.fromJSON(e);case"codedValue":return f.fromJSON(e);case"inherited":return b.fromJSON(e)}return null}},98453:(e,t,i)=>{i.d(t,{m:()=>r});const r=new(i(66552).J)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"})},73133:(e,t,i)=>{i.d(t,{j:()=>r});const r=(0,i(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},30291:(e,t,i)=>{i.d(t,{tn:()=>u});var r=i(13874),n=i(30524),s=i(28122),o=(i(84424),i(80737),i(96808),i(66159)),l=(i(67336),i(92094),i(23721),i(41227)),a=i(68780);function u({displayField:e,editFieldsInfo:t,fields:i,objectIdField:a,title:u},h){if(!i)return null;const m=function(e,t){const i=t?.visibleFieldNames;return function(e,t){const i=e;return t&&(e=e.filter((e=>!t.includes(e.type)))),e===i&&(e=e.slice()),e.sort(p),e}(e.fields??[],t?.ignoreFieldTypes||y).map((t=>new l.A({fieldName:t.name,isEditable:(0,n.R$)(t,e),label:t.alias,format:d(t),visible:c(t,{...e,visibleFieldNames:i})})))}({editFieldsInfo:t,fields:i,objectIdField:a},h);if(!m.length)return null;const f=function(e){const t=(0,n.mB)(e),{titleBase:i}=e;return t?`${i}: {${t.trim()}}`:i??""}({titleBase:u,fields:i,displayField:e}),g=[new o.A,new s.A];return new r.A({title:f,content:g,fieldInfos:m})}const c=(e,t)=>t.visibleFieldNames?t.visibleFieldNames.has(e.name):(0,n.Bz)(e,t);function p(e,t){return"oid"===e.type?-1:"oid"===t.type?1:h(e)?-1:h(t)?1:(e.alias||e.name).toLocaleLowerCase().localeCompare((t.alias||t.name).toLocaleLowerCase())}function d(e){switch(e.type){case"small-integer":case"integer":case"single":return new a.A({digitSeparator:!0,places:0});case"double":return new a.A({digitSeparator:!0,places:2});case"string":return(0,n.JL)(e.name)?new a.A({digitSeparator:!0,places:0}):void 0;default:return}}function h(e){if("name"===(e.name&&e.name.toLowerCase()))return!0;const t=e.alias?.toLowerCase();return"name"===t}const y=["geometry","blob","raster","guid","xml"]},79677:(e,t,i)=>{i.d(t,{A:()=>h});var r,n=i(90237),s=i(25482),o=i(88930),l=i(10107),a=(i(44208),i(53966),i(87811),i(36005)),u=i(40608),c=i(43937),p=i(56400);let d=r=class extends s.oY{static get allTime(){return y}static get empty(){return m}static fromArray(e){return new r({start:null!=e[0]?new Date(e[0]):e[0],end:null!=e[1]?new Date(e[1]):e[1]})}constructor(e){super(e),this.end=null,this.start=null}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?.getTime()??null}get isAllTime(){return this.equals(r.allTime)}get isEmpty(){return this.equals(r.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?.getTime()??null}clone(){return new r({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=this.start?.getTime()??this.start,i=this.end?.getTime()??this.end,r=e.start?.getTime()??e.start,n=e.end?.getTime()??e.end;return t===r&&i===n}expandTo(e,t=p.qU){if(this.isEmpty||this.isAllTime)return this.clone();let i=this.start;i&&(i=(0,o.lL)(i,e,t));let n=this.end;if(n){const i=(0,o.lL)(n,e,t);n=n.getTime()===i.getTime()?i:(0,o.S1)(i,1,e,t)}return new r({start:i,end:n})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return r.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=this.start?.getTime()??-1/0,i=this.end?.getTime()??1/0,n=e.start?.getTime()??-1/0,s=e.end?.getTime()??1/0;let o,l;return n>=t&&n<=i?o=n:t>=n&&t<=s&&(o=t),i>=n&&i<=s?l=i:s>=t&&s<=i&&(l=s),null==o||null==l||isNaN(o)||isNaN(l)?r.empty:new r({start:o===-1/0?null:new Date(o),end:l===1/0?null:new Date(l)})}offset(e,t,i=p.qU){if(this.isEmpty||this.isAllTime)return this.clone();const n=new r,{start:s,end:l}=this;return null!=s&&(n.start=(0,o.S1)(s,e,t,i)),null!=l&&(n.end=(0,o.S1)(l,e,t,i)),n}toArray(){return this.isEmpty?[void 0,void 0]:[this.start?.getTime()??null,this.end?.getTime()??null]}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return y.clone();const t=null!=this.start&&null!=e.start?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,i=null!=this.end&&null!=e.end?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new r({start:t,end:i})}};(0,n._)([(0,l.M)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"end",void 0),(0,n._)([(0,a.w)("end")],d.prototype,"readEnd",null),(0,n._)([(0,c.K)("end")],d.prototype,"writeEnd",null),(0,n._)([(0,l.M)({readOnly:!0,json:{read:!1}})],d.prototype,"isAllTime",null),(0,n._)([(0,l.M)({readOnly:!0,json:{read:!1}})],d.prototype,"isEmpty",null),(0,n._)([(0,l.M)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"start",void 0),(0,n._)([(0,a.w)("start")],d.prototype,"readStart",null),(0,n._)([(0,c.K)("start")],d.prototype,"writeStart",null),d=r=(0,n._)([(0,u.$)("esri.time.TimeExtent")],d);const h=d,y=new d,m=new d({start:void 0,end:void 0})},10184:(e,t,i)=>{i.d(t,{A:()=>d});var r=i(90237),n=i(69540),s=i(25482),o=i(88930),l=i(10107),a=(i(44208),i(53966),i(87811),i(93223)),u=i(40608),c=i(73133);let p=class extends((0,n.O)(s.oY)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,r._)([(0,a.e)(c.j,{nonNullable:!0})],p.prototype,"unit",void 0),(0,r._)([(0,l.M)({type:Number,json:{write:!0},nonNullable:!0})],p.prototype,"value",void 0),p=(0,r._)([(0,u.$)("esri.time.TimeInterval")],p);const d=p}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1389],{68197:(e,t,i)=>{i.d(t,{A:()=>p});var r,n,s=i(40876),o=i(34727),l=i(56507);function a(e){return(0,o.qE)((0,l.Vr)(e),0,255)}function u(e,t,i){return e=Number(e),isNaN(e)?i:e<t?t:e>i?i:e}function c(e,t){const i=e.toString(16).padStart(2,"0");return t?i.slice(0,1):i}class d{static blendColors(e,t,i,r=new d){return r.r=Math.round(e.r+(t.r-e.r)*i),r.g=Math.round(e.g+(t.g-e.g)*i),r.b=Math.round(e.b+(t.b-e.b)*i),r.a=e.a+(t.a-e.a)*i,r._sanitize()}static fromRgb(e,t){const i=e.toLowerCase().match(/^(rgba?|hsla?)\(([\s.\-,%0-9]+)\)/);if(i){const e=i[2].split(/\s*,\s*/),r=i[1];if("rgb"===r&&3===e.length||"rgba"===r&&4===e.length){const i=e[0];if("%"===i.charAt(i.length-1)){const i=e.map((e=>2.56*parseFloat(e)));return 4===e.length&&(i[3]=parseFloat(e[3])),d.fromArray(i,t)}return d.fromArray(e.map((e=>parseFloat(e))),t)}if("hsl"===r&&3===e.length||"hsla"===r&&4===e.length)return d.fromArray((0,s.z$)(parseFloat(e[0]),parseFloat(e[1])/100,parseFloat(e[2])/100,parseFloat(e[3])),t)}return null}static fromHex(e,t=new d){if("#"!==e[0]||isNaN(Number(`0x${e.slice(1)}`)))return null;switch(e.length){case 4:case 5:{const i=parseInt(e.slice(1,2),16),r=parseInt(e.slice(2,3),16),n=parseInt(e.slice(3,4),16),s=5===e.length?15:parseInt(e.slice(4),16);return d.fromArray([i+16*i,r+16*r,n+16*n,(s+16*s)/255],t)}case 7:case 9:{const i=parseInt(e.slice(1,3),16),r=parseInt(e.slice(3,5),16),n=parseInt(e.slice(5,7),16),s=7===e.length?255:parseInt(e.slice(7),16);return d.fromArray([i,r,n,s/255],t)}default:return null}}static fromArray(e,t=new d){return t._set(Number(e[0]),Number(e[1]),Number(e[2]),Number(e[3])),isNaN(t.a)&&(t.a=1),t._sanitize()}static fromString(e,t){const i=(0,s.V6)(e)?(0,s.TS)(e):null;return i&&d.fromArray(i,t)||d.fromRgb(e,t)||d.fromHex(e,t)}static fromJSON(e){return null!=e?new d([e[0],e[1],e[2],(e[3]??255)/255]):void 0}static toUnitRGB(e){return null!=e?[e.r/255,e.g/255,e.b/255]:null}static toUnitRGBA(e){return null!=e?[e.r/255,e.g/255,e.b/255,null!=e.a?e.a:1]:null}constructor(e){this.r=255,this.g=255,this.b=255,this.a=1,e&&this.setColor(e)}get isBright(){return.299*this.r+.587*this.g+.114*this.b>=127}setColor(e){return"string"==typeof e?d.fromString(e,this):Array.isArray(e)?d.fromArray(e,this):(this._set(e.r??0,e.g??0,e.b??0,e.a??1),e instanceof d||this._sanitize()),this}toRgb(){return[this.r,this.g,this.b]}toRgba(){return[this.r,this.g,this.b,this.a]}toHex(e){const t=e?.capitalize??!1,i=e?.digits??6,r=3===i||4===i,n=4===i||8===i,s=`#${c(this.r,r)}${c(this.g,r)}${c(this.b,r)}${n?c(Math.round(255*this.a),r):""}`;return t?s.toUpperCase():s}toCss(e=!1){const t=this.r+", "+this.g+", "+this.b;return e?`rgba(${t}, ${this.a})`:`rgb(${t})`}toString(){return this.toCss(!0)}toJSON(){return this.toArray()}toArray(e=d.AlphaMode.ALWAYS){const t=a(this.r),i=a(this.g),r=a(this.b);return e===d.AlphaMode.ALWAYS||1!==this.a?[t,i,r,a(255*this.a)]:[t,i,r]}clone(){return new d(this.toRgba())}hash(){return this.r<<24|this.g<<16|this.b<<8|255*this.a}equals(e){return null!=e&&e.r===this.r&&e.g===this.g&&e.b===this.b&&e.a===this.a}_sanitize(){return this.r=Math.round(u(this.r,0,255)),this.g=Math.round(u(this.g,0,255)),this.b=Math.round(u(this.b,0,255)),this.a=u(this.a,0,1),this}_set(e,t,i,r){this.r=e,this.g=t,this.b=i,this.a=r}}d.prototype.declaredClass="esri.Color",(n=(r=d||(d={})).AlphaMode||(r.AlphaMode={}))[n.ALWAYS=0]="ALWAYS",n[n.UNLESS_OPAQUE=1]="UNLESS_OPAQUE";const p=d},38954:(e,t,i)=>{i.d(t,{A:()=>h,B:()=>c,C:()=>m,D:()=>d,E:()=>R,F:()=>q,G:()=>L,a:()=>l,b:()=>A,c:()=>o,e:()=>z,f:()=>u,g:()=>a,h:()=>j,i:()=>w,j:()=>f,k:()=>S,l:()=>x,m:()=>s,n:()=>_,o:()=>T,p:()=>v,q:()=>M,r:()=>g,s:()=>b,t:()=>I,u:()=>V,v:()=>p,w:()=>E,x:()=>$,y:()=>y,z:()=>P});var r=i(51850),n=i(34304);function s(e){const t=e[0],i=e[1],r=e[2];return Math.sqrt(t*t+i*i+r*r)}function o(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function l(e,t,i,r){return e[0]=t,e[1]=i,e[2]=r,e}function a(e,t,i){return e[0]=t[0]+i[0],e[1]=t[1]+i[1],e[2]=t[2]+i[2],e}function u(e,t,i){return e[0]=t[0]-i[0],e[1]=t[1]-i[1],e[2]=t[2]-i[2],e}function c(e,t,i){return e[0]=t[0]*i[0],e[1]=t[1]*i[1],e[2]=t[2]*i[2],e}function d(e,t,i){return e[0]=t[0]/i[0],e[1]=t[1]/i[1],e[2]=t[2]/i[2],e}function p(e,t){return e[0]=Math.abs(t[0]),e[1]=Math.abs(t[1]),e[2]=Math.abs(t[2]),e}function h(e,t){return e[0]=Math.sign(t[0]),e[1]=Math.sign(t[1]),e[2]=Math.sign(t[2]),e}function y(e,t,i){return e[0]=Math.min(t[0],i[0]),e[1]=Math.min(t[1],i[1]),e[2]=Math.min(t[2],i[2]),e}function m(e,t,i){return e[0]=Math.max(t[0],i[0]),e[1]=Math.max(t[1],i[1]),e[2]=Math.max(t[2],i[2]),e}function f(e,t,i){return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e}function g(e,t,i,r){return e[0]=t[0]+i[0]*r,e[1]=t[1]+i[1]*r,e[2]=t[2]+i[2]*r,e}function v(e,t){const i=t[0]-e[0],r=t[1]-e[1],n=t[2]-e[2];return Math.sqrt(i*i+r*r+n*n)}function b(e,t){const i=t[0]-e[0],r=t[1]-e[1],n=t[2]-e[2];return i*i+r*r+n*n}function M(e){const t=e[0],i=e[1],r=e[2];return t*t+i*i+r*r}function S(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e}function w(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e}function _(e,t){const i=t[0],r=t[1],n=t[2];let s=i*i+r*r+n*n;return s>0&&(s=1/Math.sqrt(s),e[0]=t[0]*s,e[1]=t[1]*s,e[2]=t[2]*s),e}function x(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function A(e,t,i){const r=t[0],n=t[1],s=t[2],o=i[0],l=i[1],a=i[2];return e[0]=n*a-s*l,e[1]=s*o-r*a,e[2]=r*l-n*o,e}function T(e,t,i,r){const n=t[0],s=t[1],o=t[2];return e[0]=n+r*(i[0]-n),e[1]=s+r*(i[1]-s),e[2]=o+r*(i[2]-o),e}function j(e,t,i){const r=t[0],n=t[1],s=t[2];return e[0]=i[0]*r+i[4]*n+i[8]*s+i[12],e[1]=i[1]*r+i[5]*n+i[9]*s+i[13],e[2]=i[2]*r+i[6]*n+i[10]*s+i[14],e}function I(e,t,i){const r=t[0],n=t[1],s=t[2];return e[0]=r*i[0]+n*i[3]+s*i[6],e[1]=r*i[1]+n*i[4]+s*i[7],e[2]=r*i[2]+n*i[5]+s*i[8],e}function V(e,t,i){const r=i[0],n=i[1],s=i[2],o=i[3],l=t[0],a=t[1],u=t[2],c=n*u-s*a,d=s*l-r*u,p=r*a-n*l,h=n*p-s*d,y=s*c-r*p,m=r*d-n*c,f=2*o;return e[0]=l+c*f+2*h,e[1]=a+d*f+2*y,e[2]=u+p*f+2*m,e}const F=(0,r.vt)(),N=(0,r.vt)();function z(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function R(e,t,i){const r=i[0]-t[0],n=i[1]-t[1],s=i[2]-t[2];let o=r*r+n*n+s*s;return o>0?(o=1/Math.sqrt(o),e[0]=r*o,e[1]=n*o,e[2]=s*o,e):(e[0]=0,e[1]=0,e[2]=0,e)}const P=u,O=c,D=d,q=v,E=b,L=s,$=M;Object.freeze(Object.defineProperty({__proto__:null,abs:p,add:a,angle:function(e,t){_(F,e),_(N,t);const i=x(F,N);return i>1?0:i<-1?Math.PI:Math.acos(i)},bezier:function(e,t,i,r,n,s){const o=1-s,l=o*o,a=s*s,u=l*o,c=3*s*l,d=3*a*o,p=a*s;return e[0]=t[0]*u+i[0]*c+r[0]*d+n[0]*p,e[1]=t[1]*u+i[1]*c+r[1]*d+n[1]*p,e[2]=t[2]*u+i[2]*c+r[2]*d+n[2]*p,e},ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e},clamp:function(e,t=0,i=1){return e[0]=Math.min(Math.max(e[0],t),i),e[1]=Math.min(Math.max(e[1],t),i),e[2]=Math.min(Math.max(e[2],t),i),e},copy:o,cross:A,crossAndNormalize:function(e,t,i){const r=t[0],n=t[1],s=t[2],o=i[0],l=i[1],a=i[2],u=n*a-s*l,c=s*o-r*a,d=r*l-n*o,p=Math.sqrt(u*u+c*c+d*d);return e[0]=u/p,e[1]=c/p,e[2]=d/p,e},direction:R,dist:q,distance:v,div:D,divide:d,dot:x,equals:function(e,t){if(e===t)return!0;const i=e[0],r=e[1],s=e[2],o=t[0],l=t[1],a=t[2],u=(0,n.FD)();return Math.abs(i-o)<=u*Math.max(1,Math.abs(i),Math.abs(o))&&Math.abs(r-l)<=u*Math.max(1,Math.abs(r),Math.abs(l))&&Math.abs(s-a)<=u*Math.max(1,Math.abs(s),Math.abs(a))},exactEquals:z,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e},hermite:function(e,t,i,r,n,s){const o=s*s,l=o*(2*s-3)+1,a=o*(s-2)+s,u=o*(s-1),c=o*(3-2*s);return e[0]=t[0]*l+i[0]*a+r[0]*u+n[0]*c,e[1]=t[1]*l+i[1]*a+r[1]*u+n[1]*c,e[2]=t[2]*l+i[2]*a+r[2]*u+n[2]*c,e},inverse:w,len:L,length:s,lerp:T,max:m,min:y,mul:O,multiply:c,negate:S,normalize:_,random:function(e,t=1){const i=n.Ov,r=2*i()*Math.PI,s=2*i()-1,o=Math.sqrt(1-s*s)*t;return e[0]=Math.cos(r)*o,e[1]=Math.sin(r)*o,e[2]=s*t,e},rotateX:function(e,t,i,r){const n=[],s=[];return n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[0],s[1]=n[1]*Math.cos(r)-n[2]*Math.sin(r),s[2]=n[1]*Math.sin(r)+n[2]*Math.cos(r),e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2],e},rotateY:function(e,t,i,r){const n=[],s=[];return n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[2]*Math.sin(r)+n[0]*Math.cos(r),s[1]=n[1],s[2]=n[2]*Math.cos(r)-n[0]*Math.sin(r),e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2],e},rotateZ:function(e,t,i,r){const n=[],s=[];return n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[0]*Math.cos(r)-n[1]*Math.sin(r),s[1]=n[0]*Math.sin(r)+n[1]*Math.cos(r),s[2]=n[2],e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2],e},round:function(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e},scale:f,scaleAndAdd:g,set:l,sign:h,sqrDist:E,sqrLen:$,squaredDistance:b,squaredLength:M,str:function(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"},sub:P,subtract:u,transformMat3:I,transformMat4:j,transformQuat:V},Symbol.toStringTag,{value:"Module"}))},69540:(e,t,i)=>{i.d(t,{O:()=>c,P:()=>d});var r=i(90237),n=i(69622),s=(i(44208),i(4718)),o=(i(53966),i(97768)),l=i(35666),a=i(88620),u=i(40608);const c=e=>{let t=class extends e{clone(){const e=(0,a.oY)(this);(0,o.Lw)(e,"unable to clone instance of non-accessor class");const t=e.metadata,i=e.store,r={},n=new Map;for(const e in t){const o=t[e],a=i?.originOf(e),u=o.clonable;if(o.readOnly||!1===u||a!==l.Gr.USER&&a!==l.Gr.DEFAULTS&&a!==l.Gr.WEB_MAP&&a!==l.Gr.WEB_SCENE)continue;const c=this[e];let d=null;d="function"==typeof u?u(c):"reference"===u?c:(0,s.TU)(c),null!=c&&null==d||(a===l.Gr.DEFAULTS?n.set(e,d):r[e]=d)}const u=new(0,Object.getPrototypeOf(this).constructor)(r);if(n.size){const e=(0,a.oY)(u)?.store;if(e)for(const[t,i]of n)e.set(t,i,l.Gr.DEFAULTS)}return u}};return t=(0,r._)([(0,u.$)("esri.core.Clonable")],t),t};let d=class extends(c(n.A)){};d=(0,r._)([(0,u.$)("esri.core.Clonable")],d)},69052:(e,t,i)=>{i.d(t,{ie:()=>l});var r=i(34727);class n{constructor(e,t){this.min=e,this.max=t,this.range=t-e}normalize(e,t=0,i=!1){return s(this.range,this.min,this.max,e,t,i)}clamp(e,t=0){return(0,r.qE)(e-t,this.min,this.max)+t}monotonic(e,t,i){return e<t?t:t+o(this.range,e-t,i)}minimalMonotonic(e,t,i){return s(this.range,e,e+this.range,t,i)}center(e,t,i){return t=this.monotonic(e,t,i),this.normalize((e+t)/2,i)}diff(e,t,i){return this.monotonic(e,t,i)-e}shortestSignedDiff(e,t){e=this.normalize(e);const i=(t=this.normalize(t))-e,r=t<e?this.minimalMonotonic(e,t)-e:t-this.minimalMonotonic(t,e);return Math.abs(i)<Math.abs(r)?i:r}contains(e,t,i){return t=this.minimalMonotonic(e,t),(i=this.minimalMonotonic(e,i))>e&&i<t}}function s(e,t,i,r,n=0,s=!1){return(r-=n)<t?r+=o(e,t-r):r>i&&(r-=o(e,r-i)),s&&r===i&&(r=t),r+n}function o(e,t,i=0){return Math.ceil((t-i)/e)*e+i}new n(0,2*Math.PI),new n(-Math.PI,Math.PI);const l=new n(0,360)},29242:(e,t,i)=>{function r(){return[1,0,0,0,1,0,0,0,1]}function n(e,t,i,r,n,s,o,l,a){return[e,t,i,r,n,s,o,l,a]}i.d(t,{fA:()=>n,vt:()=>r,zK:()=>s});const s=[1,0,0,0,1,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:s,clone:function(e){return[e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8]]},create:r,createView:function(e,t){return new Float64Array(e,t,9)},fromValues:n},Symbol.toStringTag,{value:"Module"}))},82534:(e,t,i)=>{function r(){return[0,0,0,1]}function n(e){return[e[0],e[1],e[2],e[3]]}i.d(t,{o8:()=>n,vt:()=>r,zK:()=>s});const s=[0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:s,clone:n,create:r,createView:function(e,t){return new Float64Array(e,t,4)},fromValues:function(e,t,i,r){return[e,t,i,r]}},Symbol.toStringTag,{value:"Module"}))},67026:(e,t,i)=>{i.d(t,{A6:()=>m,Xd:()=>c,Xr:()=>h,hZ:()=>g,lw:()=>d,t2:()=>I,x8:()=>u});var r=i(29242),n=i(82534),s=i(51850),o=i(34304),l=i(38954),a=i(87317);function u(e,t,i){i*=.5;const r=Math.sin(i);return e[0]=r*t[0],e[1]=r*t[1],e[2]=r*t[2],e[3]=Math.cos(i),e}function c(e,t){const i=2*Math.acos(t[3]),r=Math.sin(i/2);return r>(0,o.FD)()?(e[0]=t[0]/r,e[1]=t[1]/r,e[2]=t[2]/r):(e[0]=1,e[1]=0,e[2]=0),i}function d(e,t,i){const r=t[0],n=t[1],s=t[2],o=t[3],l=i[0],a=i[1],u=i[2],c=i[3];return e[0]=r*c+o*l+n*u-s*a,e[1]=n*c+o*a+s*l-r*u,e[2]=s*c+o*u+r*a-n*l,e[3]=o*c-r*l-n*a-s*u,e}function p(e,t,i,r){const n=t[0],s=t[1],l=t[2],a=t[3];let u,c,d,p,h,y=i[0],m=i[1],f=i[2],g=i[3];return c=n*y+s*m+l*f+a*g,c<0&&(c=-c,y=-y,m=-m,f=-f,g=-g),1-c>(0,o.FD)()?(u=Math.acos(c),d=Math.sin(u),p=Math.sin((1-r)*u)/d,h=Math.sin(r*u)/d):(p=1-r,h=r),e[0]=p*n+h*y,e[1]=p*s+h*m,e[2]=p*l+h*f,e[3]=p*a+h*g,e}function h(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e[3]=t[3],e}function y(e,t){const i=t[0]+t[4]+t[8];let r;if(i>0)r=Math.sqrt(i+1),e[3]=.5*r,r=.5/r,e[0]=(t[5]-t[7])*r,e[1]=(t[6]-t[2])*r,e[2]=(t[1]-t[3])*r;else{let i=0;t[4]>t[0]&&(i=1),t[8]>t[3*i+i]&&(i=2);const n=(i+1)%3,s=(i+2)%3;r=Math.sqrt(t[3*i+i]-t[3*n+n]-t[3*s+s]+1),e[i]=.5*r,r=.5/r,e[3]=(t[3*n+s]-t[3*s+n])*r,e[n]=(t[3*n+i]+t[3*i+n])*r,e[s]=(t[3*s+i]+t[3*i+s])*r}return e}function m(e,t,i,r){const n=.5*Math.PI/180;t*=n,i*=n,r*=n;const s=Math.sin(t),o=Math.cos(t),l=Math.sin(i),a=Math.cos(i),u=Math.sin(r),c=Math.cos(r);return e[0]=s*a*c-o*l*u,e[1]=o*l*c+s*a*u,e[2]=o*a*u-s*l*c,e[3]=o*a*c+s*l*u,e}const f=a.c,g=a.s,v=a.g,b=d,M=a.d,S=a.h,w=a.l,_=a.j,x=_,A=a.b,T=A,j=a.n,I=a.a,V=a.e,F=(0,s.vt)(),N=(0,s.fA)(1,0,0),z=(0,s.fA)(0,1,0),R=(0,n.vt)(),P=(0,n.vt)(),O=(0,r.vt)();Object.freeze(Object.defineProperty({__proto__:null,add:v,calculateW:function(e,t){const i=t[0],r=t[1],n=t[2];return e[0]=i,e[1]=r,e[2]=n,e[3]=Math.sqrt(Math.abs(1-i*i-r*r-n*n)),e},conjugate:h,copy:f,dot:S,equals:V,exactEquals:I,fromEuler:m,fromMat3:y,getAxisAngle:c,identity:function(e){return e[0]=0,e[1]=0,e[2]=0,e[3]=1,e},invert:function(e,t){const i=t[0],r=t[1],n=t[2],s=t[3],o=i*i+r*r+n*n+s*s,l=o?1/o:0;return e[0]=-i*l,e[1]=-r*l,e[2]=-n*l,e[3]=s*l,e},len:x,length:_,lerp:w,mul:b,multiply:d,normalize:j,random:function(e){const t=o.Ov,i=t(),r=t(),n=t(),s=Math.sqrt(1-i),l=Math.sqrt(i);return e[0]=s*Math.sin(2*Math.PI*r),e[1]=s*Math.cos(2*Math.PI*r),e[2]=l*Math.sin(2*Math.PI*n),e[3]=l*Math.cos(2*Math.PI*n),e},rotateX:function(e,t,i){i*=.5;const r=t[0],n=t[1],s=t[2],o=t[3],l=Math.sin(i),a=Math.cos(i);return e[0]=r*a+o*l,e[1]=n*a+s*l,e[2]=s*a-n*l,e[3]=o*a-r*l,e},rotateY:function(e,t,i){i*=.5;const r=t[0],n=t[1],s=t[2],o=t[3],l=Math.sin(i),a=Math.cos(i);return e[0]=r*a-s*l,e[1]=n*a+o*l,e[2]=s*a+r*l,e[3]=o*a-n*l,e},rotateZ:function(e,t,i){i*=.5;const r=t[0],n=t[1],s=t[2],o=t[3],l=Math.sin(i),a=Math.cos(i);return e[0]=r*a+n*l,e[1]=n*a-r*l,e[2]=s*a+o*l,e[3]=o*a-s*l,e},rotationTo:function(e,t,i){const r=(0,l.l)(t,i);return r<-.999999?((0,l.b)(F,N,t),(0,l.G)(F)<1e-6&&(0,l.b)(F,z,t),(0,l.n)(F,F),u(e,F,Math.PI),e):r>.999999?(e[0]=0,e[1]=0,e[2]=0,e[3]=1,e):((0,l.b)(F,t,i),e[0]=F[0],e[1]=F[1],e[2]=F[2],e[3]=1+r,j(e,e))},scale:M,set:g,setAxes:function(e,t,i,r){const n=O;return n[0]=i[0],n[3]=i[1],n[6]=i[2],n[1]=r[0],n[4]=r[1],n[7]=r[2],n[2]=-t[0],n[5]=-t[1],n[8]=-t[2],j(e,y(e,n))},setAxisAngle:u,slerp:p,sqlerp:function(e,t,i,r,n,s){return p(R,t,n,s),p(P,i,r,s),p(e,R,P,2*s*(1-s)),e},sqrLen:T,squaredLength:A,str:function(e){return"quat("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")"}},Symbol.toStringTag,{value:"Module"}))},3330:(e,t,i)=>{i.d(t,{GB:()=>n,Qo:()=>o,Y4:()=>s});var r=i(96285);class n{}function s(e){return e instanceof r.bo?e===n.instance:"unknown"===e?.toString().toLowerCase()}function o(e){return s(e)?n.instance:e}n.instance=new r.oh("Etc/UTC")},54239:(e,t,i)=>{i.d(t,{A:()=>b});var r,n=i(90237),s=i(4576),o=i(66552),l=i(25482),a=i(83047),u=i(67076),c=i(10107),d=(i(44208),i(53966),i(36005)),p=i(40608),h=i(43937);const y=(0,o.O)()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),m=y.jsonValues.slice();(0,s.Xy)(m,"orthometric");const f=(0,o.O)()({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 g=r=class extends l.oY{constructor(e){super(e),this.heightModel="gravity-related-height",this.heightUnit="meters",this.vertCRS=null}writeHeightModel(e,t,i){return y.write(e,t,i)}readHeightModel(e,t,i){return y.read(e)||(i?.messages&&i.messages.push(function(e,t){return new u.A("height-model:unsupported",`Height model of value '${e}' is not supported`,t)}(e,{context:i})),null)}readHeightUnit(e,t,i){return f.read(e)||(i?.messages&&i.messages.push(v(e,{context:i})),null)}readHeightUnitService(e,t,i){return(0,a.LA)(e)||f.read(e)||(i?.messages&&i.messages.push(v(e,{context:i})),null)}readVertCRS(e,t){return t.vertCRS||t.ellipsoid||t.geoid}clone(){return new r({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 i=(0,a.k1)(t);return new r({heightModel:e.heightModel,heightUnit:i??void 0,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 r;return t.read(e,{origin:"web-scene"}),t}};function v(e,t){return new u.A("height-unit:unsupported",`Height unit of value '${e}' is not supported`,t)}(0,n._)([(0,c.M)({type:y.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:m,default:"ellipsoidal"}}}})],g.prototype,"heightModel",void 0),(0,n._)([(0,h.K)("web-scene","heightModel")],g.prototype,"writeHeightModel",null),(0,n._)([(0,d.w)(["web-scene","service"],"heightModel")],g.prototype,"readHeightModel",null),(0,n._)([(0,c.M)({type:f.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:f.jsonValues,write:f.write}}}})],g.prototype,"heightUnit",void 0),(0,n._)([(0,d.w)("web-scene","heightUnit")],g.prototype,"readHeightUnit",null),(0,n._)([(0,d.w)("service","heightUnit")],g.prototype,"readHeightUnitService",null),(0,n._)([(0,c.M)({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],g.prototype,"vertCRS",void 0),(0,n._)([(0,d.w)("service","vertCRS",["vertCRS","ellipsoid","geoid"])],g.prototype,"readVertCRS",null),g=r=(0,n._)([(0,p.$)("esri.geometry.HeightModelInfo")],g);const b=g},16183:(e,t,i)=>{i.r(t),i.d(t,{default:()=>We});var r=i(90237),n=i(13874),s=i(5503),o=i(49186),l=i(53966),a=i(92071),u=i(74887),c=i(10107),d=i(56507),p=(i(87811),i(44208),i(36005)),h=i(40608),y=i(38954),m=i(51850),f=i(5443),g=i(4146),v=i(52136),b=i(18768),M=i(69208),S=i(16131),w=i(8303),_=i(25036),x=i(58947),A=i(60694),T=i(10873),j=i(20437),I=i(95466),V=i(96184),F=i(69540),N=i(69052),z=i(25482),R=i(87024),P=i(67026),O=i(82534),D=i(34304);const q=(0,m.vt)(),E=(0,O.vt)(),L=(0,O.vt)(),$=(0,O.vt)(),U=(0,m.fA)(0,0,1),C=(0,m.fA)(0,1,0),B=(0,m.fA)(1,0,0);function k(e){(0,y.c)(q,e),(0,y.n)(q,q);const t=Math.atan2(q[1],q[0]),i=(0,P.x8)((0,O.vt)(),U,-t);(0,y.u)(q,q,i);const r=-1*Math.atan2(q[2],q[0]);return[(0,D.ct)(t)+270,(0,D.ct)(r)+90]}function Y(e,t){return(0,P.x8)(L,U,(0,D.DF)(e-270)),(0,P.x8)($,C,(0,D.DF)(t-90)),(0,P.lw)(E,L,$),(0,y.c)(q,B),(0,y.u)(q,q,E),(0,y.n)(q,q),[q[0],q[1],q[2]]}var H=i(79901);let J=class extends((0,F.O)(z.oY)){constructor(e){super(e),this.enabled=!0,this.label="",this.normal=null,this.point=null}get orientation(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,d.GB)(e),0,!0)}set orientation(e){const t=Y(e,this.tilt);this._set("normal",t),this._set("orientation",e)}get tilt(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,d.GB)(t),0,!0)}set tilt(e){const t=Y(this.orientation,e);this._set("normal",t),this._set("tilt",e)}};(0,r._)([(0,c.M)({type:Boolean,json:{write:!0}})],J.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],J.prototype,"label",void 0),(0,r._)([(0,c.M)({type:Number,json:{read:!1},clonable:!1,range:{min:0,max:360}}),(0,H.w)((e=>N.ie.normalize((0,d.GB)(e),0,!0)))],J.prototype,"orientation",null),(0,r._)([(0,c.M)({type:Number,json:{read:!1},clonable:!1,range:{min:0,max:360}}),(0,H.w)((e=>N.ie.normalize((0,d.GB)(e),0,!0)))],J.prototype,"tilt",null),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],J.prototype,"normal",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],J.prototype,"point",void 0),J=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelSlice")],J);const Z=J;var G=i(97159);let K=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.enabled=!0,this.href=null,this.id=null,this.label="",this.normal=null,this.point=null,this.sizeInPixel=null,this.slices=null,this.timeId=0,this.variableId=null}get orientation(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,d.GB)(e),0,!0)}get tilt(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,d.GB)(t),0,!0)}};(0,r._)([(0,c.M)({type:Boolean,json:{default:!0,write:!0}})],K.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{origins:{service:{read:G.r}},write:{enabled:!0,isRequired:!0}}}),(0,R.P)({origins:["web-scene"],type:"resource",prefix:"sections",compress:!0})],K.prototype,"href",void 0),(0,r._)([(0,c.M)({type:d.jz,json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"id",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],K.prototype,"label",void 0),(0,r._)([(0,c.M)({type:Number,clonable:!1,readOnly:!0,range:{min:0,max:360}})],K.prototype,"orientation",null),(0,r._)([(0,c.M)({type:Number,clonable:!1,readOnly:!0,range:{min:0,max:360}})],K.prototype,"tilt",null),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"normal",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"point",void 0),(0,r._)([(0,c.M)({type:[d.jz],json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"sizeInPixel",void 0),(0,r._)([(0,c.M)({type:[Z],json:{write:!0}})],K.prototype,"slices",void 0),(0,r._)([(0,c.M)({type:d.jz,json:{default:0,write:!0}})],K.prototype,"timeId",void 0),(0,r._)([(0,c.M)({type:d.jz,json:{write:{enabled:!0,isRequired:!0}}})],K.prototype,"variableId",void 0),K=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelSection")],K);const W=K;let Q=class extends z.oY{constructor(){super(...arguments),this.diffuseFactor=.5,this.specularFactor=.5}};(0,r._)([(0,c.M)({type:Number,range:{min:0,max:1},json:{default:.5,write:!0}})],Q.prototype,"diffuseFactor",void 0),(0,r._)([(0,c.M)({type:Number,range:{min:0,max:1},json:{default:.5,write:!0}})],Q.prototype,"specularFactor",void 0),Q=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelSimpleShading")],Q);const X=Q;let ee=class extends z.oY{constructor(){super(...arguments),this.continuity=null,this.hasNoData=!1,this.noData=0,this.offset=0,this.scale=1,this.type=null}};(0,r._)([(0,c.M)({type:["discrete","continuous"],json:{write:!0}})],ee.prototype,"continuity",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{write:!0}})],ee.prototype,"hasNoData",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],ee.prototype,"noData",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],ee.prototype,"offset",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],ee.prototype,"scale",void 0),(0,r._)([(0,c.M)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],ee.prototype,"type",void 0),ee=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelFormat")],ee);const te=ee;let ie=class extends z.oY{constructor(){super(...arguments),this.id=null,this.description="",this.name=null,this.originalFormat=null,this.renderingFormat=null,this.unit="",this.volumeId=0,this.type=null}};(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],ie.prototype,"id",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],ie.prototype,"description",void 0),(0,r._)([(0,c.M)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],ie.prototype,"name",void 0),(0,r._)([(0,c.M)({type:te,json:{write:!0}})],ie.prototype,"originalFormat",void 0),(0,r._)([(0,c.M)({type:te,json:{write:{enabled:!0,isRequired:!0}}})],ie.prototype,"renderingFormat",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],ie.prototype,"unit",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],ie.prototype,"volumeId",void 0),(0,r._)([(0,c.M)({type:["stc-hot-spot-results","stc-cluster-outlier-results","stc-estimated-bin","generic-nearest-interpolated"],json:{write:!0}})],ie.prototype,"type",void 0),ie=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVariable")],ie);const re=ie;var ne=i(4718),se=i(68197);let oe=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.color=se.A.fromArray([0,0,0,0]),this.value=0,this.enabled=!0,this.label="",this.colorLocked=!1}};(0,r._)([(0,c.M)({type:se.A,json:{type:[d.jz],write:{enabled:!0,isRequired:!0}}})],oe.prototype,"color",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],oe.prototype,"value",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{default:!0,write:!0}})],oe.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],oe.prototype,"label",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{default:!1,write:!0}})],oe.prototype,"colorLocked",void 0),oe=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelIsosurface")],oe);const le=oe;var ae=i(62885),ue=i(34727);let ce=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.color=null,this.position=0}};(0,r._)([(0,c.M)({type:se.A,json:{type:[d.jz],write:{enabled:!0,isRequired:!0}}})],ce.prototype,"color",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],ce.prototype,"position",void 0),ce=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelColorStop")],ce);const de=ce;let pe=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.opacity=1,this.position=0}};(0,r._)([(0,c.M)({type:Number,json:{name:"alpha",write:{enabled:!0,isRequired:!0}}})],pe.prototype,"opacity",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],pe.prototype,"position",void 0),pe=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelOpacityStop")],pe);const he=pe;let ye=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.enabled=!1,this.range=null}};(0,r._)([(0,c.M)({type:Boolean,json:{default:!1,write:!0}})],ye.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],ye.prototype,"range",void 0),ye=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelRangeFilter")],ye);const me=ye;var fe,ge;(ge=fe||(fe={}))[ge.Color=1]="Color",ge[ge.Alpha=2]="Alpha",ge[ge.Both=3]="Both";let ve=class extends((0,F.O)(z.oY)){constructor(e){super(e),this.interpolation=null,this.stretchRange=null,this.rangeFilter=null,this._colorMapSize=256,this.colorStops=new(s.A.ofType(de)),this.opacityStops=new(s.A.ofType(he))}set colorStops(e){this._set("colorStops",(0,ae.V)(e,this._get("colorStops"),s.A.ofType(de)))}set opacityStops(e){this._set("opacityStops",(0,ae.V)(e,this._get("opacityStops"),s.A.ofType(he)))}getPreviousNext(e,t,i){let r=e;for(;--r>0&&t[r].type!==i&&t[r].type!==fe.Both;);let n=e;const s=t.length;for(;++n<s&&t[n].type!==i&&t[n].type!==fe.Both;);return[r,n]}get rasterizedTransferFunction(){const e=[];if(this.colorStops.length<2)return e;const t=[],i=[];for(const t of this.colorStops){if(!t.color)return e;i.push({color:{r:t.color.r,g:t.color.g,b:t.color.b,a:Math.round(255*(1-t.color.a))},position:t.position,type:fe.Color})}if(0===this.opacityStops.length)for(const e of i)t.push({color:e.color,position:e.position});else{for(const e of this.opacityStops){const t=(0,ue.qE)(e.position,0,1),r=Math.round(255*(0,ue.qE)(1-e.opacity,0,1));let n=!1;for(const e of i)if(e.type===fe.Color&&Math.abs(e.position-t)<1e-5){e.color.a=r,e.type=fe.Both,n=!0;break}n||i.push({color:{r:0,g:0,b:0,a:r},position:e.position,type:fe.Alpha})}i.sort(((e,t)=>e.position<t.position?-1:1));const e=i.length;for(let t=0;t<e;++t){const r=i[t];if(r.type!==fe.Both)if(r.type===fe.Color){const[n,s]=this.getPreviousNext(t,i,fe.Alpha);if(-1!==n&&s!==e){const e=(r.position-i[n].position)/(i[s].position-i[n].position);r.color.a=Math.round((0,ue.Cc)(i[n].color.a,i[s].color.a,e))}else r.color.a=-1!==n?i[n].color.a:i[s].color.a}else{const[n,s]=this.getPreviousNext(t,i,fe.Color);if(-1!==n&&s!==e){const e=(r.position-i[n].position)/(i[s].position-i[n].position),t=i[n].color,o=i[s].color;Me.forEach((i=>{r.color[i]=Math.round((0,ue.Cc)(t[i],o[i],e))}))}else-1!==n?Me.forEach((e=>{r.color[e]=i[n].color[e]})):Me.forEach((e=>{r.color[e]=i[s].color[e]}))}}for(const e of i)t.push({color:e.color,position:e.position})}t[0].position=0,t[t.length-1].position=1;let r=0,n=1;for(let i=0;i<this._colorMapSize;++i){const s=i/this._colorMapSize;for(;s>t[n].position;)r=n++;const o=(s-t[r].position)/(t[n].position-t[r].position),l=t[r].color,a=t[n].color,u=new se.A;Me.forEach((e=>{u[e]=Math.round((0,ue.Cc)(l[e],a[e],o))})),u.a=(0,ue.qE)(1-(0,ue.Cc)(l.a,a.a,o)/255,0,1),e.push(u)}return e}getColorForContinuousDataValue(e,t){const i=this.rasterizedTransferFunction;if(this.colorStops.length<2||!Array.isArray(this.stretchRange)||this.stretchRange.length<2||i.length<256)return null;let r=this.stretchRange[0],n=this.stretchRange[1];if(r>n){const e=r;r=n,n=e}e=(0,ue.qE)(e,r,n);const s=i[Math.round((e-r)/(n-r)*(this._colorMapSize-1))].clone();return t||(s.a=1),s}};(0,r._)([(0,c.M)({type:["linear","nearest"],json:{write:!0}})],ve.prototype,"interpolation",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],ve.prototype,"stretchRange",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(de),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.colorStops&&this.colorStops.length>0}}}}})],ve.prototype,"colorStops",null),(0,r._)([(0,c.M)({type:s.A.ofType(he),json:{read:{source:"alphaStops"},write:{enabled:!0,target:"alphaStops",overridePolicy(){return{enabled:!!this.opacityStops&&this.opacityStops.length>0}}}}})],ve.prototype,"opacityStops",null),(0,r._)([(0,c.M)({type:me,json:{write:!0}})],ve.prototype,"rangeFilter",void 0),(0,r._)([(0,c.M)({type:[se.A],clonable:!1,json:{read:!1}})],ve.prototype,"rasterizedTransferFunction",null),ve=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelTransferFunctionStyle")],ve);const be=ve,Me=["r","g","b"];let Se=class extends((0,F.O)(z.oY)){constructor(){super(...arguments),this.color=se.A.fromArray([0,0,0,0]),this.value=0,this.enabled=!0,this.label=""}};(0,r._)([(0,c.M)({type:se.A,json:{type:[d.jz],write:{enabled:!0,isRequired:!0}}})],Se.prototype,"color",void 0),(0,r._)([(0,c.M)({type:d.jz,json:{write:{enabled:!0,isRequired:!0}}})],Se.prototype,"value",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{default:!0,write:!0}})],Se.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Se.prototype,"label",void 0),Se=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelUniqueValue")],Se);const we=Se;var _e;let xe=_e=class extends z.oY{constructor(e){super(e),this.variableId=0,this.label="",this.transferFunction=null,this.uniqueValues=null,this.isosurfaces=null,this.uniqueValues=new(s.A.ofType(we)),this.isosurfaces=new(s.A.ofType(le))}clone(){return new _e({variableId:this.variableId,label:this.label,transferFunction:(0,ne.o8)(this.transferFunction),uniqueValues:(0,ne.o8)(this.uniqueValues),isosurfaces:(0,ne.o8)(this.isosurfaces)})}};(0,r._)([(0,c.M)({type:d.jz,json:{write:{enabled:!0,isRequired:!0}}})],xe.prototype,"variableId",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],xe.prototype,"label",void 0),(0,r._)([(0,c.M)({type:be,json:{write:{enabled:!0,overridePolicy(){return{enabled:!this.uniqueValues||this.uniqueValues.length<1}}}}})],xe.prototype,"transferFunction",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(we),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.uniqueValues&&this.uniqueValues.length>0}}}}})],xe.prototype,"uniqueValues",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(le),json:{write:{enabled:!0,overridePolicy(){const e=!this.uniqueValues||this.uniqueValues.length<1,t=!!this.isosurfaces&&this.isosurfaces.length>0;return{enabled:e&&t}}}}})],xe.prototype,"isosurfaces",void 0),xe=_e=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVariableStyle")],xe);const Ae=xe;var Te=i(88930),je=i(86738),Ie=i(16930),Ve=i(21325);function Fe(e){const t=/^(days?|hours?|minutes?|seconds?|d|h|m|s) since (\d{1,4})-(\d{1,2})-(\d{1,2})[ |T](\d{1,2}):(\d{1,2}):(\d{1,2})(\.[0-9]+)?[\s|Z]?(([+|\-|\s?])(\d{1,2}):(\d{1,2}))?$/i.exec(e);if(null==t)return{didParse:!1};const[,i,r,n,s,o,l,a,u,c,d,p,h]=t;let y="seconds";const m=i.charAt(0).toLowerCase();"d"===m?y="days":"h"===m?y="hours":"m"===m&&(y="minutes");const f=parseInt(r,10);if(Number.isNaN(f))return{didParse:!1};const g=parseInt(n,10);if(Number.isNaN(g)||g<1||g>12)return{didParse:!1};const v=parseInt(s,10);if(Number.isNaN(v)||v<1||v>31)return{didParse:!1};if(2===g){const e=f%4==0&&(f%100!=0||f%400==0);if(e&&v>29||!e&&v>28)return{didParse:!1}}else if((4===g||6===g||9===g||11===g)&&v>30)return{didParse:!1};const b=parseInt(o,10);if(Number.isNaN(b)||b<0||b>23)return{didParse:!1};const M=parseInt(l,10);if(Number.isNaN(M)||M<0||M>59)return{didParse:!1};const S=parseInt(a,10);if(Number.isNaN(S)||S<0||S>59)return{didParse:!1};let w=1,_=0,x=0;if(d&&(w="-"===d?-1:1),p){if(_=parseInt(p,10),Number.isNaN(_)||_<0)return{didParse:!1};if(0!==_){const e=w*_;if(e<-12||e>14)return{didParse:!1}}}if(h&&(x=parseInt(h,10),Number.isNaN(x)||x<0||x>59))return{didParse:!1};const A=`${f}`.padStart(4,"0"),T=`${g}`.padStart(2,"0"),j=`${v}`.padStart(2,"0"),I=`${b}`.padStart(2,"0"),V=`${M}`.padStart(2,"0"),F=`${S}`.padStart(2,"0");let N="Z";return 0===_&&0===x||(N=w>0?"+":"-",N+=`${_}`.padStart(2,"0"),N+=":",N+=`${x}`.padStart(2,"0")),{didParse:!0,unit:y,reference:new Date(`${A}-${T}-${j}T${I}:${V}:${F}.000${N}`)}}let Ne=class extends z.oY{constructor(){super(...arguments),this.values=null}};(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],Ne.prototype,"values",void 0),Ne=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelIrregularSpacing")],Ne);const ze=Ne;let Re=class extends z.oY{constructor(){super(...arguments),this.scale=1,this.offset=0}};(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],Re.prototype,"scale",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],Re.prototype,"offset",void 0),Re=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelRegularSpacing")],Re);const Pe=Re;let Oe=class extends z.oY{constructor(){super(...arguments),this.irregularSpacing=null,this.isPositiveUp=!0,this.isWrappedDateLine=!1,this.label=null,this.name=null,this.quantity=null,this.regularSpacing=null,this.size=0,this.unit=null}get isRegular(){return(null==this.irregularSpacing||void 0===this.irregularSpacing)&&null!==this.regularSpacing}getRange(){return this.isRegular?[this.regularSpacing.offset,this.regularSpacing.offset+this.regularSpacing.scale*(this.size-1)]:Array.isArray(this.irregularSpacing?.values)&&this.irregularSpacing.values.length>1?[this.irregularSpacing.values[0],this.irregularSpacing.values[this.irregularSpacing.values.length-1]]:[0,0]}};(0,r._)([(0,c.M)({type:ze,json:{write:!0}})],Oe.prototype,"irregularSpacing",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{write:!0}})],Oe.prototype,"isPositiveUp",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{write:!0}})],Oe.prototype,"isWrappedDateLine",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Oe.prototype,"label",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Oe.prototype,"name",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Oe.prototype,"quantity",void 0),(0,r._)([(0,c.M)({type:Pe,json:{write:!0}})],Oe.prototype,"regularSpacing",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:!0}})],Oe.prototype,"size",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Oe.prototype,"unit",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{read:!1}})],Oe.prototype,"isRegular",null),Oe=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelDimension")],Oe);const De=Oe;let qe=class extends z.oY{constructor(e){super(e),this.id=0,this.dimensions=null,this.spatialReference=Ie.A.WGS84}get zDimension(){if(!this.dimensions)return-1;if(!Array.isArray(this.dimensions))return-1;if(4!==this.dimensions.length)return-1;for(let e=2;e<4;++e)if(this.dimensions[e].size>0)return e;return-1}get isValid(){return!(!this.dimensions||!Array.isArray(this.dimensions)||4!==this.dimensions.length||this.dimensions[0].size<1||this.dimensions[1].size<1||-1===this.zDimension||this.dimensions[this.zDimension].size<1)}get originInLayerSpace3D(){if(!this.isValid||"xyt"===this.volumeType)return[0,0,0];const e=this.dimensions[0].getRange(),t=this.dimensions[1].getRange(),i=this.dimensions[2],r=i.isRegular?i.getRange():[0,i.size];return[e[0],t[0],r[0]]}get voxelSizeInLayerSpaceSigned(){if(!this.isValid||"xyt"===this.volumeType)return[0,0,0];const e=this.dimensions[0].getRange(),t=this.dimensions[1].getRange(),i=this.dimensions[2],r=i.isRegular?i.getRange():[0,i.size],n=[this.sizeInVoxels[0],this.sizeInVoxels[1],this.sizeInVoxels[2]];for(let e=0;e<3;++e)n[e]<2?n[e]=1:n[e]-=1;return i.isRegular&&!i.isPositiveUp&&(n[2]*=-1),[(e[1]-e[0])/n[0],(t[1]-t[0])/n[1],(r[1]-r[0])/n[2]]}get volumeType(){if(this.isValid){const e=this.dimensions[2].size>0;let t=this.dimensions[3].size>0;if(t){const e=this.dimensions[3];t="time"===e.quantity,t&&null!==e.unit&&(t=Fe(e.unit).didParse)}if(!e&&t)return"xyt";if(e&&t)return"xyzt"}return"xyz"}get sizeInVoxels(){if(!this.isValid)return[0,0,0];const e=this.zDimension;return[this.dimensions[0].size,this.dimensions[1].size,this.dimensions[e].size]}get timeStops(){if("xyzt"!==this.volumeType)return[];const e=this.dimensions[3],t=[],i=Fe(e.unit);if(i.didParse)if(e.isRegular){const r=e.regularSpacing?.offset??0,n=e.regularSpacing?.scale||1;for(let s=0;s<e.size;++s){const e=r+n*s;t.push((0,Te.mi)(i.reference,e,i.unit))}}else if(Array.isArray(e.irregularSpacing?.values)&&e.irregularSpacing.values.length>0)for(let r=0;r<e.irregularSpacing.values.length;++r){const n=e.irregularSpacing.values[r];t.push((0,Te.mi)(i.reference,n,i.unit))}return t}computeVoxelSpaceLocation(e){if(!this.isValid)return[0,0,0];if("xyt"===this.volumeType)return l.A.getLogger(this).error("computeVoxelSpacePosition cannot be used with XYT volumes."),[0,0,0];if(!(0,Ve.aI)(this.spatialReference,e.spatialReference))return l.A.getLogger(this).error("pos argument should have the same spatial reference as the VoxelLayer."),[0,0,0];const t=(0,m.fA)(e.x,e.y,e.z??0);(0,y.f)(t,t,this.originInLayerSpace3D),(0,y.D)(t,t,this.voxelSizeInLayerSpaceSigned);const i=this.dimensions[this.zDimension];if(!i.isRegular&&Array.isArray(i.irregularSpacing?.values)&&i.irregularSpacing.values.length>1){const r=e.z??0,n=i.irregularSpacing.values,s=i.isPositiveUp?1:-1,o=n.reduce(((e,t)=>Math.abs(s*t-r)<Math.abs(s*e-r)?t:e));for(let e=0;e<n.length;++e)if(n[e]===o){t[2]=e;break}}return[t[0],t[1],t[2]]}computeLayerSpaceLocation(e){if(!this.isValid)return new je.A({x:0,y:0,spatialReference:this.spatialReference});const t=(0,m.ci)(e);if((0,y.B)(t,t,this.voxelSizeInLayerSpaceSigned),(0,y.g)(t,t,this.originInLayerSpace3D),"xyt"===this.volumeType)return new je.A({x:t[0],y:t[1],spatialReference:this.spatialReference});const i=this.dimensions[this.zDimension];return i.isRegular||Array.isArray(i.irregularSpacing?.values)&&(e[2]<0?t[2]=i.irregularSpacing.values[0]:e[2]<i.irregularSpacing.values.length?t[2]=i.irregularSpacing.values[e[2]]:t[2]=i.irregularSpacing.values[i.irregularSpacing.values.length-1],i.isPositiveUp||(t[2]*=-1)),new je.A({x:t[0],y:t[1],z:t[2],spatialReference:this.spatialReference})}};(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],qe.prototype,"id",void 0),(0,r._)([(0,c.M)({type:[De],json:{write:{enabled:!0,isRequired:!0}}})],qe.prototype,"dimensions",void 0),(0,r._)([(0,c.M)({type:Ie.A,json:{read:{enabled:!1}}})],qe.prototype,"spatialReference",void 0),(0,r._)([(0,c.M)({type:Number,json:{read:!1}})],qe.prototype,"zDimension",null),(0,r._)([(0,c.M)({type:[Boolean],json:{read:!1}})],qe.prototype,"isValid",null),(0,r._)([(0,c.M)({type:[Number],json:{read:!1}})],qe.prototype,"originInLayerSpace3D",null),(0,r._)([(0,c.M)({type:[Number],json:{read:!1}})],qe.prototype,"voxelSizeInLayerSpaceSigned",null),(0,r._)([(0,c.M)({type:["xyz","xyzt","xyt"],json:{read:{enabled:!1}}})],qe.prototype,"volumeType",null),(0,r._)([(0,c.M)({type:[Number],json:{read:!1}})],qe.prototype,"sizeInVoxels",null),(0,r._)([(0,c.M)({type:[Date],json:{read:!1,write:!1}})],qe.prototype,"timeStops",null),qe=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVolume")],qe);const Ee=qe;var Le;let $e=Le=class extends z.oY{constructor(){super(...arguments),this.apronWidth=1,this.brickSize=[32,32,32],this.maxLodLevel=0,this.nodeSize=[4,4,4]}isValid(){const e=new Le;return e.apronWidth===this.apronWidth&&e.maxLodLevel===this.maxLodLevel&&!!this.brickSize&&!!this.nodeSize&&!(!Array.isArray(this.brickSize)||!Array.isArray(this.nodeSize))&&3===this.brickSize.length&&3===this.nodeSize.length&&32===this.brickSize[0]&&32===this.brickSize[1]&&32===this.brickSize[2]&&4===this.nodeSize[0]&&4===this.nodeSize[1]&&4===this.nodeSize[2]}};(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],$e.prototype,"apronWidth",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],$e.prototype,"brickSize",void 0),(0,r._)([(0,c.M)({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],$e.prototype,"maxLodLevel",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],$e.prototype,"nodeSize",void 0),$e=Le=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVolumeIndex")],$e);const Ue=$e;let Ce=class extends((0,F.O)(z.oY)){constructor(e){super(e),this.enabled=!0,this.label="",this.normal=null,this.point=null}get orientation(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,d.GB)(e),0,!0)}set orientation(e){const t=Y(e,this.tilt);this._set("normal",t),this._set("orientation",e)}get tilt(){if(!Array.isArray(this.normal)||3!==this.normal.length)return 0;const[e,t]=k(this.normal);return N.ie.normalize((0,d.GB)(t),0,!0)}set tilt(e){const t=Y(this.orientation,e);this._set("normal",t),this._set("tilt",e)}};(0,r._)([(0,c.M)({type:Boolean,json:{default:!0,write:!0}})],Ce.prototype,"enabled",void 0),(0,r._)([(0,c.M)({type:String,json:{write:!0}})],Ce.prototype,"label",void 0),(0,r._)([(0,c.M)({type:Number,json:{read:!1},clonable:!1,range:{min:0,max:360}}),(0,H.w)((e=>N.ie.normalize((0,d.GB)(e),0,!0)))],Ce.prototype,"orientation",null),(0,r._)([(0,c.M)({type:Number,json:{read:!1},clonable:!1,range:{min:0,max:360}}),(0,H.w)((e=>N.ie.normalize((0,d.GB)(e),0,!0)))],Ce.prototype,"tilt",null),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],Ce.prototype,"normal",void 0),(0,r._)([(0,c.M)({type:[Number],json:{write:!0}})],Ce.prototype,"point",void 0),Ce=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelDynamicSection")],Ce);const Be=Ce;var ke;let Ye=ke=class extends z.oY{constructor(e){super(e),this.volumeId=0,this.verticalExaggeration=1,this.exaggerationMode="scale-height",this.verticalOffset=0,this.slices=new(s.A.ofType(Z)),this.dynamicSections=new(s.A.ofType(Be))}set slices(e){this._set("slices",(0,ae.V)(e,this._get("slices"),s.A.ofType(Z)))}set dynamicSections(e){this._set("dynamicSections",(0,ae.V)(e,this._get("dynamicSections"),s.A.ofType(Be)))}clone(){return new ke({volumeId:this.volumeId,verticalExaggeration:this.verticalExaggeration,exaggerationMode:this.exaggerationMode,verticalOffset:this.verticalOffset,slices:(0,ne.o8)(this.slices),dynamicSections:(0,ne.o8)(this.dynamicSections)})}};(0,r._)([(0,c.M)({type:d.jz,json:{write:{enabled:!0,isRequired:!0}}})],Ye.prototype,"volumeId",void 0),(0,r._)([(0,c.M)({type:Number,json:{default:1,write:!0}})],Ye.prototype,"verticalExaggeration",void 0),(0,r._)([(0,c.M)({type:["scale-position","scale-height"],json:{default:"scale-height",write:!0}})],Ye.prototype,"exaggerationMode",void 0),(0,r._)([(0,c.M)({type:Number,json:{default:0,write:!0}})],Ye.prototype,"verticalOffset",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(Z),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.slices&&this.slices.length>0}}}}})],Ye.prototype,"slices",null),(0,r._)([(0,c.M)({type:s.A.ofType(Be),json:{write:{enabled:!0,overridePolicy(){return{enabled:!!this.dynamicSections&&this.dynamicSections.length>0}}}}})],Ye.prototype,"dynamicSections",null),Ye=ke=(0,r._)([(0,h.$)("esri.layers.voxel.VoxelVolumeStyle")],Ye);const He=Ye;var Je=i(30291),Ze=i(79677),Ge=i(10184);let Ke=class extends((0,x.w6)((0,b.b)((0,S.q)((0,w.A)((0,_.j)((0,a.P)((0,M.d)((0,v.p)(g.A))))))))){constructor(e){super(e),this.serviceRoot="",this.operationalLayerType="Voxel",this.legendEnabled=!0,this.title=null,this.sections=null,this.currentVariableId=0,this.volumeStyles=null,this.renderMode="volume",this.variableStyles=null,this.enableSlices=!0,this.enableSections=!0,this.enableDynamicSections=!0,this.enableIsosurfaces=!0,this.shading=new X,this.opacity=1,this.variables=new s.A,this.volumes=new s.A,this.index=null,this.minScale=0,this.maxScale=0,this.type="voxel",this.version={major:Number.NaN,minor:Number.NaN,versionString:""},this.fullExtent=null,this.popupEnabled=!1,this.popupTemplate=null,this.test=null,this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0,this.volumeStyles=new(s.A.ofType(He)),this.variableStyles=new(s.A.ofType(Ae)),this.sections=new(s.A.ofType(W))}normalizeCtorArgs(e){return e?.constantUpscaling&&(this.test={constantUpscaling:!0},delete e.constantUpscaling),e}set url(e){this._set("url",(0,A.Jf)(e,l.A.getLogger(this)))}load(e){const t=null!=e?e.signal:null,i=this.loadFromPortal({supportedTypes:["Scene Service"]},e).catch(u.QP).then((()=>this._fetchService(t))).then((()=>this.serviceRoot=this.url));return this.addResolvingPromise(i),Promise.resolve(this)}read(e,t){super.read(e,t),"service"===t?.origin&&this.version.major<=3&&this.version.minor<=0&&!this.getAtOrigin("popupTemplate","service")&&this.setAtOrigin("popupTemplate",this.createPopupTemplate(),"service");for(const e of this.volumes)e.spatialReference=this.spatialReference}readVersion(e,t){return super.parseVersionString(e)}validateLayer(e){if(e.layerType&&e.layerType!==this.operationalLayerType)throw new o.A("voxel-layer:layer-type-not-supported","VoxelLayer does not support this layer type",{layerType:e.layerType});if(isNaN(this.version.major)||isNaN(this.version.minor)||this.version.major<3)throw new o.A("layer:service-version-not-supported","Service version is not supported.",{serviceVersion:this.version.versionString,supportedVersions:"3.x"});if(this.version.major>3)throw new o.A("layer:service-version-too-new","Service version is too new.",{serviceVersion:this.version.versionString,supportedVersions:"3.x"})}readFullExtent(e,t,i){if(null!=e&&"object"==typeof e){const r=f.A.fromJSON(e,i);if(0===r.zmin&&0===r.zmax&&Array.isArray(t.volumes)){const e=Ee.fromJSON(t.volumes[0]);if(e.isValid&&"xyt"!==e.volumeType){const t=e.dimensions[2];if(t.isRegular){let e=t.regularSpacing.offset,i=t.regularSpacing.offset+t.regularSpacing.scale*(t.size-1);if(e>i){const t=e;e=i,i=t}r.zmin=e,r.zmax=i}}}return r}return null}get fields(){const e=[new j.A({name:"Voxel.Position",alias:"Voxel Position",domain:null,editable:!1,length:128,type:"string"}),new j.A({name:"Voxel.CurrentVariable",alias:"Current Variable",domain:null,editable:!1,length:128,type:"string"})];for(const t of this.variables){const i=new j.A({name:t.name,alias:t.description,domain:null,editable:!1,length:128,type:"discrete"===t.renderingFormat.continuity?"string":"double"});e.push(i)}const t=this.getVolume(null);if(null!=t){if("xyzt"===t.volumeType||"xyt"===t.volumeType){const t=new j.A({name:"Voxel.LocalTime",alias:"Local Time",domain:null,editable:!1,length:256,type:"date"});e.push(t);const i=new j.A({name:"Voxel.SourceTime",alias:"Source Time",domain:null,editable:!1,length:256,type:"string"});e.push(i)}if("xyt"!==t.volumeType){const t=new j.A({name:"Voxel.Depth",alias:"Depth",domain:null,editable:!1,length:128,type:"double"});e.push(t)}}return e}get fieldsIndex(){return this.loaded?new I.A(this.fields):null}getField(e){return this.fieldsIndex?.get(e)}get defaultPopupTemplate(){return this.createPopupTemplate()}createPopupTemplate(e){const t=this.fields;return(0,Je.tn)({fields:t,title:"{Voxel.Position}"},e)}getConfiguration(){const e={layerType:this.operationalLayerType,version:this.version.versionString,name:this.title,spatialReference:this.spatialReference,fullExtent:this.fullExtent,volumes:this.volumes.toJSON(),variables:this.variables.toJSON(),index:this.index?.toJSON(),sections:this.getSections(),style:{volumeStyles:this.getVolumeStyles(),currentVariableId:this.currentVariableId,renderMode:this.renderMode,variableStyles:this.getVariableStyles(),enableSections:this.enableSections,enableDynamicSections:this.enableDynamicSections,enableIsosurfaces:this.enableIsosurfaces,enableSlices:this.enableSlices,shading:this.shading}};return e.index&&this.index?.isValid()?JSON.stringify(e):""}getVariableStyle(e){let t=-1;if(t=null!=e?e:this.currentVariableId,!this.variableStyles||-1===t)return null;const i=this.variableStyles.findIndex((e=>e.variableId===t));return i<0?null:this.variableStyles.at(i)}getVariable(e){let t=-1;if(t=null!=e?e:this.currentVariableId,!this.variables||-1===t)return null;const i=this.variables.findIndex((e=>e.id===t));return i<0?null:this.variables.at(i)}getVolume(e){const t=this.getVariable(e);return null!=t?this.volumes.find((({id:e})=>e===t.volumeId)):null}get timeInfo(){const e=this.getVolume(null);if("xyzt"!==e?.volumeType)return null;const t=e.timeStops;if(!t?.length)return null;const i=new Ze.A({start:t[0],end:t.at(-1)});return new V.A({fullTimeExtent:i,stops:t})}getVolumeStyle(e){const t=this.getVariable(e);return null!=t?this.volumeStyles.find((({volumeId:e})=>e===t.volumeId)):null}getColorForContinuousDataValue(e,t,i){const r=this.getVariable(e);if(null==r||"continuous"!==r.renderingFormat?.continuity)return null;if(!this.variableStyles)return null;const n=this.variableStyles.findIndex((t=>t.variableId===e));if(n<0)return null;const s=this.variableStyles.at(n);return s?.transferFunction?s.transferFunction.getColorForContinuousDataValue(t,i):null}getSections(){const e=[];for(const t of this.sections)e.push(new W({enabled:t.enabled,href:t.href,id:t.id,label:t.label,normal:t.normal,point:t.point,sizeInPixel:t.sizeInPixel,slices:t.slices,timeId:t.timeId,variableId:t.variableId}));return e}getVariableStyles(){const e=[];for(const t of this.variableStyles){const i=this._getVariable(t);if(null!=i){const r=t.clone();r.isosurfaces.length>4&&(r.isosurfaces=r.isosurfaces.slice(0,3),l.A.getLogger(this).error("A maximum of 4 isosurfaces are supported for Voxel Layers."));for(const e of r.isosurfaces)if(!e.colorLocked){const t=this.getColorForContinuousDataValue(r.variableId,e.value,!1);null===t||t.equals(e.color)||(e.color=t)}if("continuous"===i.renderingFormat.continuity)(null===r.transferFunction||r.transferFunction.colorStops.length<2)&&l.A.getLogger(this).error(`VoxelVariableStyle for variable ${i.id} is invalid. At least 2 color stops are required in the transferFunction for continuous Voxel Layer variables.`),null!==r.transferFunction&&(Array.isArray(r.transferFunction.stretchRange)&&2===r.transferFunction.stretchRange.length||(l.A.getLogger(this).error(`VoxelVariableStyle for variable ${i.id} is invalid. The stretchRange of the transferFunction for continuous Voxel Layer variables must be of the form [minimumDataValue, maximumDataValue].`),r.transferFunction.stretchRange=[0,1],r.transferFunction.colorStops.removeAll()));else if("discrete"===i.renderingFormat.continuity)if(0===t.uniqueValues.length)l.A.getLogger(this).error(`VoxelVariableStyle for variable ${i.id} is invalid. Unique values are required for discrete Voxel Layer variables.`);else for(const e of t.uniqueValues)null!==e.label&&void 0!==e.label||null===e.value||void 0===e.value||(e.label=e.value.toString());e.push(r)}else l.A.getLogger(this).error(`VoxelVariable ID=${t.variableId} doesn't exist, VoxelVariableStyle for this VoxelVariable will be ignored.`)}return e}getVolumeStyles(){const e=[];for(const t of this.volumeStyles){const i=this._getVolumeFromVolumeId(t.volumeId);if(null!=i){const r=t.clone();for(const e of r.slices)this._isPlaneValid(e,[0,1,i.zDimension],i.dimensions)||(e.enabled=!1,e.label="invalid");for(const e of r.dynamicSections)this._isPlaneValid(e,[0,1,i.zDimension],i.dimensions)||(e.enabled=!1,e.label="invalid");e.push(r)}else l.A.getLogger(this).error(`VoxelVolume ID=${t.volumeId} doesn't exist, VoxelVolumeStyle for this VoxelVolume will be ignored.`)}return e}_getVariable(e){const t=e.variableId;for(const e of this.variables)if(e.id===t)return e;return null}_getVolumeFromVolumeId(e){for(const t of this.volumes)if(t.id===e)return t;return null}_isPlaneValid(e,t,i){if(!e.point)return!1;if(!Array.isArray(e.point)||3!==e.point.length)return!1;if(!e.normal)return!1;if(!Array.isArray(e.normal)||3!==e.normal.length)return!1;const r=(0,m.fA)(e.normal[0],e.normal[1],e.normal[2]);return(0,y.n)(r,r),!(Math.abs(r[0])+Math.abs(r[1])+Math.abs(r[2])<1e-6||(e.normal[0]=r[0],e.normal[1]=r[1],e.normal[2]=r[2],0))}};(0,r._)([(0,c.M)({type:["Voxel"]})],Ke.prototype,"operationalLayerType",void 0),(0,r._)([(0,c.M)(T.fV)],Ke.prototype,"legendEnabled",void 0),(0,r._)([(0,c.M)({json:{write:!0}})],Ke.prototype,"title",void 0),(0,r._)([(0,c.M)(T.OZ)],Ke.prototype,"url",null),(0,r._)([(0,c.M)({type:s.A.ofType(W),json:{origins:{"web-scene":{name:"layerDefinition.sections",write:!0}}}})],Ke.prototype,"sections",void 0),(0,r._)([(0,c.M)({type:d.jz,json:{origins:{"web-scene":{name:"layerDefinition.style.currentVariableId",write:{enabled:!0,isRequired:!0,ignoreOrigin:!0}},service:{name:"style.currentVariableId"}}}})],Ke.prototype,"currentVariableId",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(He),json:{origins:{"web-scene":{name:"layerDefinition.style.volumeStyles",write:!0},service:{name:"style.volumeStyles"}}}})],Ke.prototype,"volumeStyles",void 0),(0,r._)([(0,c.M)({type:["volume","surfaces"],json:{origins:{"web-scene":{name:"layerDefinition.style.renderMode",write:!0},service:{name:"style.renderMode"}}}})],Ke.prototype,"renderMode",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(Ae),json:{origins:{"web-scene":{name:"layerDefinition.style.variableStyles",write:!0},service:{name:"style.variableStyles"}}}})],Ke.prototype,"variableStyles",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{origins:{"web-scene":{name:"layerDefinition.style.enableSlices",write:!0},service:{name:"style.enableSlices"}}}})],Ke.prototype,"enableSlices",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{origins:{"web-scene":{name:"layerDefinition.style.enableSections",write:!0},service:{name:"style.enableSections"}}}})],Ke.prototype,"enableSections",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{origins:{"web-scene":{name:"layerDefinition.style.enableDynamicSections",write:!0},service:{name:"style.enableDynamicSections"}}}})],Ke.prototype,"enableDynamicSections",void 0),(0,r._)([(0,c.M)({type:Boolean,json:{origins:{"web-scene":{name:"layerDefinition.style.enableIsosurfaces",write:!0},service:{name:"style.enableIsosurfaces"}}}})],Ke.prototype,"enableIsosurfaces",void 0),(0,r._)([(0,c.M)({type:X,json:{origins:{"web-scene":{name:"layerDefinition.style.shading",write:!0},service:{name:"style.shading"}}}})],Ke.prototype,"shading",void 0),(0,r._)([(0,c.M)({type:["show","hide"]})],Ke.prototype,"listMode",void 0),(0,r._)([(0,c.M)({type:Number,range:{min:0,max:1},nonNullable:!0,json:{read:!1,write:!1,origins:{"web-scene":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],Ke.prototype,"opacity",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(re)})],Ke.prototype,"variables",void 0),(0,r._)([(0,c.M)({type:s.A.ofType(Ee)})],Ke.prototype,"volumes",void 0),(0,r._)([(0,c.M)({type:Ue})],Ke.prototype,"index",void 0),(0,r._)([(0,c.M)({type:Number,json:{name:"layerDefinition.minScale",write:!0,origins:{service:{read:!1,write:!1}}}})],Ke.prototype,"minScale",void 0),(0,r._)([(0,c.M)({type:Number,json:{name:"layerDefinition.maxScale",write:!0,origins:{service:{read:!1,write:!1}}}})],Ke.prototype,"maxScale",void 0),(0,r._)([(0,c.M)({json:{read:!1},readOnly:!0})],Ke.prototype,"type",void 0),(0,r._)([(0,c.M)({readOnly:!0,json:{name:"serviceVersion"}})],Ke.prototype,"version",void 0),(0,r._)([(0,p.w)("service","version")],Ke.prototype,"readVersion",null),(0,r._)([(0,c.M)({type:f.A})],Ke.prototype,"fullExtent",void 0),(0,r._)([(0,p.w)("service","fullExtent",["fullExtent"])],Ke.prototype,"readFullExtent",null),(0,r._)([(0,c.M)({readOnly:!0,clonable:!1,json:{read:!1}})],Ke.prototype,"fields",null),(0,r._)([(0,c.M)({readOnly:!0})],Ke.prototype,"fieldsIndex",null),(0,r._)([(0,c.M)({type:Boolean,json:{name:"disablePopup",read:{reader:(e,t)=>!t.disablePopup},write:{enabled:!0,ignoreOrigin:!0,writer(e,t,i){t[i]=!e}},origins:{"portal-item":{default:!0},"web-scene":{default:!0}}}})],Ke.prototype,"popupEnabled",void 0),(0,r._)([(0,c.M)({type:n.A,json:{name:"popupInfo",write:!0}})],Ke.prototype,"popupTemplate",void 0),(0,r._)([(0,c.M)({readOnly:!0,json:{read:!1}})],Ke.prototype,"defaultPopupTemplate",null),(0,r._)([(0,c.M)({type:V.A,readOnly:!0,json:{read:!1}})],Ke.prototype,"timeInfo",null),(0,r._)([(0,c.M)({type:Ze.A,json:{read:!1}})],Ke.prototype,"timeExtent",void 0),(0,r._)([(0,c.M)({type:Ge.A,json:{read:!1}})],Ke.prototype,"timeOffset",void 0),(0,r._)([(0,c.M)({type:Boolean,nonNullable:!0,json:{origins:{"web-scene":{name:"timeAnimation",write:!0},service:{read:!1}}}})],Ke.prototype,"useViewTime",void 0),Ke=(0,r._)([(0,h.$)("esri.layers.VoxelLayer")],Ke);const We=Ke},52136:(e,t,i)=>{i.d(t,{p:()=>o});var r=i(90237),n=i(10107),s=(i(44208),i(53966),i(87811),i(40608));const o=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,r._)([(0,n.M)({type:String})],t.prototype,"apiKey",null),t=(0,r._)([(0,s.$)("esri.layers.mixins.APIKeyMixin")],t),t}},18768:(e,t,i)=>{i.d(t,{b:()=>a});var r=i(90237),n=i(53966),s=i(10107),o=(i(44208),i(87811),i(40608)),l=i(60694);const a=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.qg)(this.url);if(null!=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.Jf)(e,n.A.getLogger(this)))}};return(0,r._)([(0,s.M)()],t.prototype,"title",null),(0,r._)([(0,s.M)({type:String})],t.prototype,"url",null),t=(0,r._)([(0,o.$)("esri.layers.mixins.ArcGISService")],t),t}},69208:(e,t,i)=>{i.d(t,{d:()=>o});var r=i(90237),n=i(10107),s=(i(44208),i(53966),i(87811),i(40608));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,r._)([(0,n.M)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,r._)([(0,s.$)("esri.layers.mixins.CustomParametersMixin")],t),t}},8303:(e,t,i)=>{i.d(t,{A:()=>w});var r=i(90237),n=i(92602),s=i(70333),o=i(78888),l=i(60999),a=i(49186),u=i(53966),c=i(97768),d=i(74887),p=i(84952),h=i(10107),y=(i(44208),i(87811),i(36005)),m=i(40608),f=i(43937),g=i(83531),v=i(20655),b=i(80812),M=i(41318),S=i(10407);const w=e=>{let t=class extends e{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,c.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,i){if(t.itemId)return new b.default({id:t.itemId,portal:i?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:r}=await Promise.all([i.e(5356),i.e(1204)]).then(i.bind(i,41204));return(0,d.Te)(t),await r({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap},t)}catch(e){throw(0,d.zf)(e)||u.A.getLogger(this).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,d.QP)(e),!0))))}async setUserPrivileges(e,t){if(!n.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:i,fullEdit:r},content:{updateItem:n}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",i),this._set("userHasFullEditingPrivileges",r),this._set("userHasUpdateItemPrivileges",n)}catch(e){(0,d.QP)(e)}}async _fetchUserPrivileges(e,t){let i=this.portalItem;if(!e||!i||!i.loaded||i.sourceUrl)return this._fetchFallbackUserPrivileges(t);const r=e===i.id;if(r&&i.portal.user)return(0,S.It)(i);let n,o;if(r)n=i.portal.url;else try{n=await(0,g.wI)(this.url,t)}catch(e){(0,d.QP)(e)}if(!n||!(0,p.b8)(n,i.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;o=await(s.id?.getCredential(`${n}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,d.QP)(e)}const l=!0,a=!1,u=!1;if(!o)return{features:{edit:l,fullEdit:a},content:{updateItem:u}};try{if(r?await i.reload():(i=new b.default({id:e,portal:{url:n}}),await i.load(t)),i.portal.user)return(0,S.It)(i)}catch(e){(0,d.QP)(e)}return{features:{edit:l,fullEdit:a},content:{updateItem:u}}}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,d.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?s.id?.findCredential(this.url):null;if(!t)return!0;const i=_.credential===t?_.user:await this._fetchEditingUser(e);return _.credential=t,_.user=i,null==i?.privileges||i.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const i=s.id?.findServerInfo(this.url??"");if(!i?.owningSystemUrl)return null;const r=`${i.owningSystemUrl}/sharing/rest`,n=v.A.getDefault();if(n&&n.loaded&&(0,p.S8)(n.restUrl)===(0,p.S8)(r))return n.user;const a=`${r}/community/self`,u=null!=e?e.signal:null,c=await(0,l.Ke)((0,o.A)(a,{authMode:"no-prompt",query:{f:"json"},signal:u}));return c.ok?M.A.fromJSON(c.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const i=t?.portal,r=this.portalItem?.id&&(this.portalItem.portal||v.A.getDefault());return i&&r&&!(0,p.ut)(r.restUrl,i.restUrl)?(t.messages&&t.messages.push(new a.A("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,r._)([(0,h.M)({type:b.default})],t.prototype,"portalItem",null),(0,r._)([(0,y.w)("web-document","portalItem",["itemId"])],t.prototype,"readPortalItem",null),(0,r._)([(0,f.K)("web-document","portalItem",{itemId:{type:String}})],t.prototype,"writePortalItem",null),(0,r._)([(0,h.M)({clonable:!1})],t.prototype,"resourceReferences",void 0),(0,r._)([(0,h.M)({type:Boolean,readOnly:!0})],t.prototype,"userHasEditingPrivileges",void 0),(0,r._)([(0,h.M)({type:Boolean,readOnly:!0})],t.prototype,"userHasFullEditingPrivileges",void 0),(0,r._)([(0,h.M)({type:Boolean,readOnly:!0})],t.prototype,"userHasUpdateItemPrivileges",void 0),t=(0,r._)([(0,m.$)("esri.layers.mixins.PortalLayer")],t),t},_={credential:null,user:null}},25036:(e,t,i)=>{i.d(t,{j:()=>o});var r=i(90237),n=i(10107),s=(i(44208),i(53966),i(87811),i(40608));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.minScale=0,this.maxScale=0}get effectiveScaleRange(){const e={minScale:this.minScale,maxScale:this.maxScale},t=this.parent;t&&"effectiveScaleRange"in t&&function(e,t){e.minScale=e.minScale>0?t.minScale>0?Math.min(e.minScale,t.minScale):e.minScale:t.minScale,e.maxScale=e.maxScale>0?t.maxScale>0?Math.max(e.maxScale,t.maxScale):e.maxScale:t.maxScale}(e,t.effectiveScaleRange);const i=this._get("effectiveScaleRange");return i&&i.minScale===e.minScale&&i.maxScale===e.maxScale?i:e}};return(0,r._)([(0,n.M)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"minScale",void 0),(0,r._)([(0,n.M)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"maxScale",void 0),(0,r._)([(0,n.M)({readOnly:!0})],t.prototype,"effectiveScaleRange",null),t=(0,r._)([(0,s.$)("esri.layers.mixins.ScaleRangeLayer")],t),t}},39357:(e,t,i)=>{i.d(t,{H:()=>a});var r,n=i(90237),s=i(25482),o=i(10107),l=(i(44208),i(53966),i(87811),i(40608));let a=r=class extends s.oY{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,n._)([(0,o.M)({type:String,json:{write:!0}})],a.prototype,"name",void 0),(0,n._)([(0,o.M)({type:[String,Number],json:{write:!0}})],a.prototype,"code",void 0),a=r=(0,n._)([(0,l.$)("esri.layers.support.CodedValue")],a)},53177:(e,t,i)=>{i.d(t,{A:()=>p});var r,n=i(90237),s=i(4718),o=i(10107),l=(i(44208),i(53966),i(93223)),a=i(40608),u=i(39357),c=i(76357);let d=r=class extends c.A{constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const i=String(e);this.codedValues.some((e=>(String(e.code)===i&&(t=e.name),!!t)))}return t}clone(){return new r({codedValues:(0,s.o8)(this.codedValues),name:this.name})}};(0,n._)([(0,o.M)({type:[u.H],json:{write:!0}})],d.prototype,"codedValues",void 0),(0,n._)([(0,l.e)({codedValue:"coded-value"})],d.prototype,"type",void 0),d=r=(0,n._)([(0,a.$)("esri.layers.support.CodedValueDomain")],d);const p=d},76357:(e,t,i)=>{i.d(t,{A:()=>d});var r=i(90237),n=i(66552),s=i(25482),o=i(10107),l=(i(44208),i(53966),i(87811),i(93223)),a=i(40608);const u=new n.J({inherited:"inherited",codedValue:"coded-value",range:"range"});let c=class extends s.oY{constructor(e){super(e),this.name=null,this.type=null}};(0,r._)([(0,o.M)({type:String,json:{write:!0}})],c.prototype,"name",void 0),(0,r._)([(0,l.e)(u)],c.prototype,"type",void 0),c=(0,r._)([(0,a.$)("esri.layers.support.Domain")],c);const d=c},20437:(e,t,i)=>{i.d(t,{A:()=>f});var r,n=i(90237),s=i(66552),o=i(25482),l=i(10107),a=i(56507),u=(i(87811),i(44208),i(93223)),c=i(36005),d=i(40608),p=i(80451),h=i(98453);const y=new s.J({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",dateAndTime:"date-and-time",description:"description",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier"});let m=r=class extends o.oY{constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let i=null;try{i=t?JSON.parse(t):null}catch(e){}return i?.value??null}readValueType(e,{description:t}){let i=null;try{i=t?JSON.parse(t):null}catch(e){}return i?y.fromJSON(i.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain?.clone()??null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,n._)([(0,l.M)({type:String,json:{write:!0}})],m.prototype,"alias",void 0),(0,n._)([(0,l.M)({type:[String,Number],json:{write:{allowNull:!0}}})],m.prototype,"defaultValue",void 0),(0,n._)([(0,l.M)()],m.prototype,"description",void 0),(0,n._)([(0,c.w)("description")],m.prototype,"readDescription",null),(0,n._)([(0,l.M)({types:p.gK,json:{read:{reader:p.rS},write:!0}})],m.prototype,"domain",void 0),(0,n._)([(0,l.M)({type:Boolean,json:{write:!0}})],m.prototype,"editable",void 0),(0,n._)([(0,l.M)({type:a.jz,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],m.prototype,"length",void 0),(0,n._)([(0,l.M)({type:String,json:{write:!0}})],m.prototype,"name",void 0),(0,n._)([(0,l.M)({type:Boolean,json:{write:!0}})],m.prototype,"nullable",void 0),(0,n._)([(0,u.e)(h.m)],m.prototype,"type",void 0),(0,n._)([(0,l.M)()],m.prototype,"valueType",void 0),(0,n._)([(0,c.w)("valueType",["description"])],m.prototype,"readValueType",null),(0,n._)([(0,l.M)({type:Boolean,json:{read:!1}})],m.prototype,"visible",void 0),m=r=(0,n._)([(0,d.$)("esri.layers.support.Field")],m);const f=m},95466:(e,t,i)=>{i.d(t,{A:()=>p});var r=i(49186),n=i(25482),s=i(53966),o=i(91869),l=i(3330),a=i(30524),u=i(56400),c=i(96285);const d=new Map;class p{static fromJSON(e){return new p(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new p(e.fields??[],f(e))}static fromLayerJSON(e){return new p(e.fields??[],f(e))}constructor(e=[],t){this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this._requiredFields=null,this.dateFields=[],this.numericFields=[],this.fields=e||[],this._timeZoneByFieldName=t?new Map(t):null;const i=[];for(const e of this.fields){const t=e?.name,r=y(t);if(t&&r){const n=h(t);this._fieldsMap.set(t,e),this._fieldsMap.set(n,e),this._normalizedFieldsMap.set(r,e),i.push(`${n}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,a.vE)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,a.WA)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,a.te)(e)||(0,a.Xz)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}i.sort(),this.uid=i.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,a.te)(e)||(0,a.Xz)(e)||e.nullable||void 0!==(0,a.lD)(e)||this._requiredFields.push(e)}return this._requiredFields}equals(e){return this.uid===e?.uid}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(h(e))??this._normalizedFieldsMap.get(y(e)),t&&this._fieldsMap.set(e,t),t)}getTimeZone(e){const t=this.get(e&&"string"!=typeof e?e.name:e);return t?this._timeZoneByFieldName?this._timeZoneByFieldName.get(t.name):"date"===t.type||"esriFieldTypeDate"===t.type?(s.A.getLogger("esri.layers.support.FieldsIndex").error(new r.A("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),u.n$):m.has(t.type)?u.L5:null:null}getLuxonTimeZone(e){const t=this.getTimeZone(e);return t?t===u.L5?l.GB.instance:t===u.n$?c.mQ.utcInstance:(0,o.tE)(d,t,(()=>c.oh.create(t))):null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,a.OH)(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){return this.get(e)?.name??void 0}toJSON(){return{fields:this.fields.map((e=>(0,n.Wj)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function h(e){return e.trim().toLowerCase()}function y(e){return(0,a.rS)(e)?.toLowerCase()??""}const m=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function f(e){const t=new Map;if(!e.fields)return t;const i=!0===e.datesInUnknownTimezone,{timeInfo:r,editFieldsInfo:n}=e,s=(r?"startField"in r?r.startField:r.startTimeField:"")??"",o=(r?"endField"in r?r.endField:r.endTimeField:"")??"",l=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,u.ZS)(e.dateFieldsTimeReference):null,a=n?function(e){return"timeZone"in e}(n)?n.timeZone??l:n.dateFieldsTimeReference?(0,u.ZS)(n.dateFieldsTimeReference):l??u.n$:null,c=r?function(e){return"timeZone"in e}(r)?r.timeZone??l:r.timeReference?(0,u.ZS)(r.timeReference):l:null,d=new Map([[h(n?.creationDateField??""),a],[h(n?.editDateField??""),a],[h(s),c],[h(o),c]]);for(const{name:r,type:n}of e.fields)if(m.has(n))t.set(r,u.L5);else if("date"!==n&&"esriFieldTypeDate"!==n)t.set(r,null);else if(i)t.set(r,u.L5);else{const e=d.get(h(r??""))??l;t.set(r,e)}return t}},96184:(e,t,i)=>{i.d(t,{A:()=>m});var r=i(90237),n=i(69540),s=i(25482),o=i(10107),l=(i(44208),i(53966),i(87811),i(36005)),a=i(40608),u=i(43937),c=i(79677),d=i(10184),p=i(56400);function h(e,t){return d.A.fromJSON({value:e,unit:t})}let y=class extends((0,n.O)(s.oY)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?c.A.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?h(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?h(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,r._)([(0,o.M)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],y.prototype,"cumulative",void 0),(0,r._)([(0,o.M)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"endField",void 0),(0,r._)([(0,o.M)({type:c.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"fullTimeExtent",void 0),(0,r._)([(0,l.w)("fullTimeExtent",["timeExtent"])],y.prototype,"readFullTimeExtent",null),(0,r._)([(0,u.K)("fullTimeExtent")],y.prototype,"writeFullTimeExtent",null),(0,r._)([(0,o.M)({type:Boolean,json:{write:!0}})],y.prototype,"hasLiveData",void 0),(0,r._)([(0,o.M)({type:d.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"interval",void 0),(0,r._)([(0,l.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],y.prototype,"readInterval",null),(0,r._)([(0,u.K)("interval")],y.prototype,"writeInterval",null),(0,r._)([(0,o.M)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"startField",void 0),(0,r._)([(0,o.M)((0,p.P6)("timeReference",!0))],y.prototype,"timeZone",void 0),(0,r._)([(0,o.M)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"trackIdField",void 0),(0,r._)([(0,o.M)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],y.prototype,"useTime",void 0),(0,r._)([(0,o.M)({type:[Date],json:{read:!1}})],y.prototype,"stops",void 0),y=(0,r._)([(0,a.$)("esri.layers.support.TimeInfo")],y);const m=y},80451:(e,t,i)=>{i.d(t,{rS:()=>f,gK:()=>m}),i(44208);var r,n=i(53177),s=i(76357),o=i(90237),l=(i(53966),i(87811),i(49186),i(93223)),a=i(40608);let u=r=class extends s.A{constructor(e){super(e),this.type="inherited"}clone(){return new r}};(0,o._)([(0,l.e)({inherited:"inherited"})],u.prototype,"type",void 0),u=r=(0,o._)([(0,a.$)("esri.layers.support.InheritedDomain")],u);const c=u;var d,p=i(10107);let h=d=class extends s.A{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new d({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,o._)([(0,p.M)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,i){t[i]=[this.minValue||0,e]}}}})],h.prototype,"maxValue",void 0),(0,o._)([(0,p.M)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,i){t[i]=[e,this.maxValue||0]}}}})],h.prototype,"minValue",void 0),(0,o._)([(0,l.e)({range:"range"})],h.prototype,"type",void 0),h=d=(0,o._)([(0,a.$)("esri.layers.support.RangeDomain")],h);const y=h,m={key:"type",base:s.A,typeMap:{range:y,"coded-value":n.A,inherited:c}};function f(e){if(!e?.type)return null;switch(e.type){case"range":return y.fromJSON(e);case"codedValue":return n.A.fromJSON(e);case"inherited":return c.fromJSON(e)}return null}},98453:(e,t,i)=>{i.d(t,{m:()=>r});const r=new(i(66552).J)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"})},73133:(e,t,i)=>{i.d(t,{j:()=>r});const r=(0,i(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},30291:(e,t,i)=>{i.d(t,{tn:()=>u});var r=i(13874),n=i(30524),s=i(28122),o=(i(84424),i(80737),i(96808),i(66159)),l=(i(67336),i(92094),i(23721),i(41227)),a=i(68780);function u({displayField:e,editFieldsInfo:t,fields:i,objectIdField:a,title:u},h){if(!i)return null;const m=function(e,t){const i=t?.visibleFieldNames;return function(e,t){const i=e;return t&&(e=e.filter((e=>!t.includes(e.type)))),e===i&&(e=e.slice()),e.sort(d),e}(e.fields??[],t?.ignoreFieldTypes||y).map((t=>new l.A({fieldName:t.name,isEditable:(0,n.R$)(t,e),label:t.alias,format:p(t),visible:c(t,{...e,visibleFieldNames:i})})))}({editFieldsInfo:t,fields:i,objectIdField:a},h);if(!m.length)return null;const f=function(e){const t=(0,n.mB)(e),{titleBase:i}=e;return t?`${i}: {${t.trim()}}`:i??""}({titleBase:u,fields:i,displayField:e}),g=[new o.A,new s.A];return new r.A({title:f,content:g,fieldInfos:m})}const c=(e,t)=>t.visibleFieldNames?t.visibleFieldNames.has(e.name):(0,n.Bz)(e,t);function d(e,t){return"oid"===e.type?-1:"oid"===t.type?1:h(e)?-1:h(t)?1:(e.alias||e.name).toLocaleLowerCase().localeCompare((t.alias||t.name).toLocaleLowerCase())}function p(e){switch(e.type){case"small-integer":case"integer":case"single":return new a.A({digitSeparator:!0,places:0});case"double":return new a.A({digitSeparator:!0,places:2});case"string":return(0,n.JL)(e.name)?new a.A({digitSeparator:!0,places:0}):void 0;default:return}}function h(e){if("name"===(e.name&&e.name.toLowerCase()))return!0;const t=e.alias?.toLowerCase();return"name"===t}const y=["geometry","blob","raster","guid","xml"]},79677:(e,t,i)=>{i.d(t,{A:()=>h});var r,n=i(90237),s=i(25482),o=i(88930),l=i(10107),a=(i(44208),i(53966),i(87811),i(36005)),u=i(40608),c=i(43937),d=i(56400);let p=r=class extends s.oY{static get allTime(){return y}static get empty(){return m}static fromArray(e){return new r({start:null!=e[0]?new Date(e[0]):e[0],end:null!=e[1]?new Date(e[1]):e[1]})}constructor(e){super(e),this.end=null,this.start=null}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?.getTime()??null}get isAllTime(){return this.equals(r.allTime)}get isEmpty(){return this.equals(r.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?.getTime()??null}clone(){return new r({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=this.start?.getTime()??this.start,i=this.end?.getTime()??this.end,r=e.start?.getTime()??e.start,n=e.end?.getTime()??e.end;return t===r&&i===n}expandTo(e,t=d.qU){if(this.isEmpty||this.isAllTime)return this.clone();let i=this.start;i&&(i=(0,o.lL)(i,e,t));let n=this.end;if(n){const i=(0,o.lL)(n,e,t);n=n.getTime()===i.getTime()?i:(0,o.S1)(i,1,e,t)}return new r({start:i,end:n})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return r.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=this.start?.getTime()??-1/0,i=this.end?.getTime()??1/0,n=e.start?.getTime()??-1/0,s=e.end?.getTime()??1/0;let o,l;return n>=t&&n<=i?o=n:t>=n&&t<=s&&(o=t),i>=n&&i<=s?l=i:s>=t&&s<=i&&(l=s),null==o||null==l||isNaN(o)||isNaN(l)?r.empty:new r({start:o===-1/0?null:new Date(o),end:l===1/0?null:new Date(l)})}offset(e,t,i=d.qU){if(this.isEmpty||this.isAllTime)return this.clone();const n=new r,{start:s,end:l}=this;return null!=s&&(n.start=(0,o.S1)(s,e,t,i)),null!=l&&(n.end=(0,o.S1)(l,e,t,i)),n}toArray(){return this.isEmpty?[void 0,void 0]:[this.start?.getTime()??null,this.end?.getTime()??null]}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return y.clone();const t=null!=this.start&&null!=e.start?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,i=null!=this.end&&null!=e.end?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new r({start:t,end:i})}};(0,n._)([(0,l.M)({type:Date,json:{write:{allowNull:!0}}})],p.prototype,"end",void 0),(0,n._)([(0,a.w)("end")],p.prototype,"readEnd",null),(0,n._)([(0,c.K)("end")],p.prototype,"writeEnd",null),(0,n._)([(0,l.M)({readOnly:!0,json:{read:!1}})],p.prototype,"isAllTime",null),(0,n._)([(0,l.M)({readOnly:!0,json:{read:!1}})],p.prototype,"isEmpty",null),(0,n._)([(0,l.M)({type:Date,json:{write:{allowNull:!0}}})],p.prototype,"start",void 0),(0,n._)([(0,a.w)("start")],p.prototype,"readStart",null),(0,n._)([(0,c.K)("start")],p.prototype,"writeStart",null),p=r=(0,n._)([(0,u.$)("esri.time.TimeExtent")],p);const h=p,y=new p,m=new p({start:void 0,end:void 0})},10184:(e,t,i)=>{i.d(t,{A:()=>p});var r=i(90237),n=i(69540),s=i(25482),o=i(88930),l=i(10107),a=(i(44208),i(53966),i(87811),i(93223)),u=i(40608),c=i(73133);let d=class extends((0,n.O)(s.oY)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,r._)([(0,a.e)(c.j,{nonNullable:!0})],d.prototype,"unit",void 0),(0,r._)([(0,l.M)({type:Number,json:{write:!0},nonNullable:!0})],d.prototype,"value",void 0),d=(0,r._)([(0,u.$)("esri.time.TimeInterval")],d);const p=d}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1967,3069],{13069:(e,t,n)=>{n.d(t,{lk:()=>r,vD:()=>s,yS:()=>i});const o="randomUUID"in crypto;function r(){if(o)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function i(){return`{${r().toUpperCase()}}`}function s(){return`{${r()}}`}},33143:(e,t,n)=>{n.d(t,{A:()=>f});var o=n(90237),r=n(69540),i=n(25482),s=n(10107),l=(n(44208),n(53966),n(87811),n(36005)),a=n(40608),p=n(43937),u=n(
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1967,3069],{13069:(e,t,n)=>{n.d(t,{lk:()=>r,vD:()=>s,yS:()=>i});const o="randomUUID"in crypto;function r(){if(o)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function i(){return`{${r().toUpperCase()}}`}function s(){return`{${r()}}`}},33143:(e,t,n)=>{n.d(t,{A:()=>f});var o=n(90237),r=n(69540),i=n(25482),s=n(10107),l=(n(44208),n(53966),n(87811),n(36005)),a=n(40608),p=n(43937),u=n(80451),c=n(29005);let y=class extends((0,r.O)(i.oY)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const n of Object.keys(e))t[n]=(0,u.rS)(e[n]);return t}writeDomains(e,t){const n={};for(const t of Object.keys(e))e[t]&&(n[t]=e[t]?.toJSON());t.domains=n}};(0,o._)([(0,s.M)({json:{write:!0}})],y.prototype,"id",void 0),(0,o._)([(0,s.M)({json:{write:!0}})],y.prototype,"name",void 0),(0,o._)([(0,s.M)({json:{write:!0}})],y.prototype,"domains",void 0),(0,o._)([(0,l.w)("domains")],y.prototype,"readDomains",null),(0,o._)([(0,p.K)("domains")],y.prototype,"writeDomains",null),(0,o._)([(0,s.M)({type:[c.A],json:{write:!0}})],y.prototype,"templates",void 0),y=(0,o._)([(0,a.$)("esri.layers.support.FeatureType")],y);const f=y},10407:(e,t,n)=>{n.d(t,{It:()=>y,LG:()=>s,OM:()=>p,Y:()=>l,bK:()=>a,mm:()=>c,sQ:()=>u});var o=n(57251),r=n(16930),i=n(28735);function s(e,t){if(!l(e,t)){const n=e.typeKeywords;n?n.push(t):e.typeKeywords=[t]}}function l(e,t){return!!e.typeKeywords?.includes(t)}function a(e){return l(e,c.HOSTED_SERVICE)}function p(e,t){const n=e.typeKeywords;if(n){const e=n.indexOf(t);e>-1&&n.splice(e,1)}}async function u(e){const t=e.clone().normalize();let n;if(t.length>1)for(const e of t)n?e.width>n.width&&(n=e):n=e;else n=t[0];return async function(e){const t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,i.ci)(e);const n=r.A.WGS84;return await(0,o.initializeProjection)(t,n),(0,o.project)(e,n)}(n)}const c={DEVELOPER_BASEMAP:"DeveloperBasemap",JSAPI:"ArcGIS API for JavaScript",METADATA:"Metadata",MULTI_LAYER:"Multilayer",SINGLE_LAYER:"Singlelayer",TABLE:"Table",HOSTED_SERVICE:"Hosted Service",LOCAL_SCENE:"ViewingMode-Local",TILED_IMAGERY:"Tiled Imagery",GROUP_LAYER_MAP:"Map"};function y(e){const{portal:t,isOrgItem:n,itemControl:o}=e,r=t.user?.privileges;let i=!r||r.includes("features:user:edit"),s=!!n&&!!r?.includes("features:user:fullEdit");const l="update"===o||"admin"===o;return l?s=i=!0:s&&(i=!0),{features:{edit:i,fullEdit:s},content:{updateItem:l}}}},22671:(e,t,n)=>{n.d(t,{A:()=>_});var o,r=n(90237),i=n(59456),s=n(52106),l=n(66552),a=n(25482),p=n(4718),u=n(10107),c=(n(44208),n(53966),n(36005)),y=n(40608),f=n(43937),m=n(16930),d=n(65864),h=n(20437);const g=new l.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let w=o=class extends a.oY{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){const n=m.A.fromJSON(t.spatialReference),o=[];for(let t=0;t<e.length;t++){const r=e[t],i=s.A.fromJSON(r),l=r.geometry?.spatialReference;null==i.geometry||l||(i.geometry.spatialReference=n);const a=r.aggregateGeometries,p=i.aggregateGeometries;if(a&&null!=p)for(const e in p){const t=p[e],o=a[e],r=o?.spatialReference;null==t||r||(t.spatialReference=n)}o.push(i)}return o}writeGeometryType(e,t,n,o){if(e)return void g.write(e,t,n,o);const{features:r}=this;if(r)for(const e of r)if(null!=e?.geometry)return void g.write(e.geometry.type,t,n,o)}readQueryGeometry(e,t){if(!e)return null;const n=!!e.spatialReference,o=(0,d.rS)(e);return o&&!n&&t.spatialReference&&(o.spatialReference=m.A.fromJSON(t.spatialReference)),o}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:n}=this;if(n)for(const e of n)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new o(this.cloneProperties())}cloneProperties(){return(0,p.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let n=0;n<t.features.length;n++){const o=t.features[n];if(o.geometry){const t=e?.[n];o.geometry=t?.toJSON()||o.geometry}}return t}quantize(e){const{scale:[t,n],translate:[o,r]}=e,i=this.features,s=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-o)/t)),(e=>Math.round((r-e)/n)));for(let e=0,t=i.length;e<t;e++)s?.(i[e].geometry)||(i.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:n}=this;if(!n)return this;const{translate:[o,r],scale:[i,s]}=n;let l=null,a=null;if(this.hasZ&&null!=n?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=n;l=n=>n*t+e}if(this.hasM&&null!=n?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=n;a=n=>null==n?n:n*t+e}const p=this._getHydrationFunction(e,(e=>e*i+o),(e=>r-e*s),l,a);for(const{geometry:e}of t)null!=e&&p&&p(e);return this.transform=null,this}_quantizePoints(e,t,n){let o,r;const i=[];for(let s=0,l=e.length;s<l;s++){const l=e[s];if(s>0){const e=t(l[0]),s=n(l[1]);e===o&&s===r||(i.push([e-o,s-r]),o=e,r=s)}else o=t(l[0]),r=n(l[1]),i.push([o,r])}return i.length>0?i:null}_getQuantizationFunction(e,t,n){return"point"===e?e=>(e.x=t(e.x),e.y=n(e.y),e):"polyline"===e||"polygon"===e?e=>{const o=(0,d.Bi)(e)?e.rings:e.paths,r=[];for(let e=0,i=o.length;e<i;e++){const i=o[e],s=this._quantizePoints(i,t,n);s&&r.push(s)}return r.length>0?((0,d.Bi)(e)?e.rings=r:e.paths=r,e):null}:"multipoint"===e?e=>{const o=this._quantizePoints(e.points,t,n);return o&&o.length>0?(e.points=o,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,n,o,r){return"point"===e?e=>{e.x=t(e.x),e.y=n(e.y),o&&(e.z=o(e.z))}:"polyline"===e||"polygon"===e?e=>{const i=(0,d.Bi)(e)?e.rings:e.paths;let s,l;for(let e=0,o=i.length;e<o;e++){const o=i[e];for(let e=0,r=o.length;e<r;e++){const r=o[e];e>0?(s+=r[0],l+=r[1]):(s=r[0],l=r[1]),r[0]=t(s),r[1]=n(l)}}if(o&&r)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=o(n[2]),n[3]=r(n[3])}}else if(o)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=o(n[2])}}else if(r)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=r(n[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=n(e.ymin),e.xmax=t(e.xmax),e.ymax=n(e.ymax),o&&null!=e.zmax&&null!=e.zmin&&(e.zmax=o(e.zmax),e.zmin=o(e.zmin)),r&&null!=e.mmax&&null!=e.mmin&&(e.mmax=r(e.mmax),e.mmin=r(e.mmin))}:"multipoint"===e?e=>{const i=e.points;let s,l;for(let e=0,o=i.length;e<o;e++){const o=i[e];e>0?(s+=o[0],l+=o[1]):(s=o[0],l=o[1]),o[0]=t(s),o[1]=n(l)}if(o&&r)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=o(t[2]),t[3]=r(t[3])}else if(o)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=o(t[2])}else if(r)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=r(t[2])}}:null}};(0,r._)([(0,u.M)({type:String,json:{write:!0}})],w.prototype,"displayFieldName",void 0),(0,r._)([(0,u.M)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"exceededTransferLimit",void 0),(0,r._)([(0,u.M)({type:[s.A],json:{write:!0}})],w.prototype,"features",void 0),(0,r._)([(0,c.w)("features")],w.prototype,"readFeatures",null),(0,r._)([(0,u.M)({type:[h.A],json:{write:!0}})],w.prototype,"fields",void 0),(0,r._)([(0,u.M)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],w.prototype,"geometryType",void 0),(0,r._)([(0,f.K)("geometryType")],w.prototype,"writeGeometryType",null),(0,r._)([(0,u.M)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"hasM",void 0),(0,r._)([(0,u.M)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"hasZ",void 0),(0,r._)([(0,u.M)({types:i.yR,json:{write:!0}})],w.prototype,"queryGeometry",void 0),(0,r._)([(0,c.w)("queryGeometry")],w.prototype,"readQueryGeometry",null),(0,r._)([(0,u.M)({type:m.A,json:{write:!0}})],w.prototype,"spatialReference",void 0),(0,r._)([(0,f.K)("spatialReference")],w.prototype,"writeSpatialReference",null),(0,r._)([(0,u.M)({json:{write:!0}})],w.prototype,"transform",void 0),w=o=(0,r._)([(0,y.$)("esri.rest.support.FeatureSet")],w),w.prototype.toJSON.isDefaultToJSON=!0;const _=w}}]);
|