text: "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2415,3172,5732,7049],{92835:(e,t,r)=>{r.d(t,{Z:()=>m});var n,s=r(43697),i=r(10736),o=r(70586),a=r(35463),l=r(5600),u=(r(67676),r(80442),r(75215),r(71715)),c=r(52011),h=r(30556);let d=n=class extends i.wq{constructor(e){super(e),this.end=null,this.start=null}static get allTime(){return p}static get empty(){return f}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?e.getTime():null}get isAllTime(){return this.equals(n.allTime)}get isEmpty(){return this.equals(n.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?e.getTime():null}clone(){return new n({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=(0,o.pC)(this.start)?this.start.getTime():this.start,r=(0,o.pC)(this.end)?this.end.getTime():this.end,n=(0,o.pC)(e.start)?e.start.getTime():e.start,s=(0,o.pC)(e.end)?e.end.getTime():e.end;return t===n&&r===s}expandTo(e){if(this.isEmpty||this.isAllTime)return this.clone();const t=(0,o.Po)(this.start,(t=>(0,a.JE)(t,e))),r=(0,o.Po)(this.end,(t=>(0,a.Nm)((0,a.JE)(t,e),1,e)));return new n({start:t,end:r})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return n.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=(0,o.R2)(this.start,-1/0,(e=>e.getTime())),r=(0,o.R2)(this.end,1/0,(e=>e.getTime())),s=(0,o.R2)(e.start,-1/0,(e=>e.getTime())),i=(0,o.R2)(e.end,1/0,(e=>e.getTime()));let a,l;if(s>=t&&s<=r?a=s:t>=s&&t<=i&&(a=t),r>=s&&r<=i?l=r:i>=t&&i<=r&&(l=i),!isNaN(a)&&!isNaN(l)){const e=new n;return e.start=a===-1/0?null:new Date(a),e.end=l===1/0?null:new Date(l),e}return n.empty}offset(e,t){if(this.isEmpty||this.isAllTime)return this.clone();const r=new n,{start:s,end:i}=this;return(0,o.pC)(s)&&(r.start=(0,a.Nm)(s,e,t)),(0,o.pC)(i)&&(r.end=(0,a.Nm)(i,e,t)),r}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return p.clone();const t=(0,o.pC)(this.start)&&(0,o.pC)(e.start)?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,r=(0,o.pC)(this.end)&&(0,o.pC)(e.end)?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new n({start:t,end:r})}};(0,s._)([(0,l.Cb)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"end",void 0),(0,s._)([(0,u.r)("end")],d.prototype,"readEnd",null),(0,s._)([(0,h.c)("end")],d.prototype,"writeEnd",null),(0,s._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],d.prototype,"isAllTime",null),(0,s._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],d.prototype,"isEmpty",null),(0,s._)([(0,l.Cb)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"start",void 0),(0,s._)([(0,u.r)("start")],d.prototype,"readStart",null),(0,s._)([(0,h.c)("start")],d.prototype,"writeStart",null),d=n=(0,s._)([(0,c.j)("esri.TimeExtent")],d);const p=new d,f=new d({start:void 0,end:void 0}),m=d},5732:(e,t,r)=>{r.d(t,{a:()=>i,c:()=>n,g:()=>s});var n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function s(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function i(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}},46851:(e,t,r)=>{r.d(t,{E:()=>n,R:()=>s});const n=1e-6,s=Math.random,i=Math.PI/180,o=180/Math.PI;Object.freeze({__proto__:null,EPSILON:n,RANDOM:s,toRadian:function(e){return e*i},toDegree:function(e){return e*o},equals:function(e,t){return Math.abs(e-t)<=n*Math.max(1,Math.abs(e),Math.abs(t))}})},52138:(e,t,r)=>{r.d(t,{a:()=>l,b:()=>u,d:()=>p,e:()=>i,f:()=>d,g:()=>v,h:()=>b,i:()=>a,m:()=>c,o:()=>f,q:()=>_,s:()=>o,t:()=>h});var n=r(65617),s=r(46851);function i(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function o(e,t,r,n,s,i,o,a,l,u,c,h,d,p,f,m,y){return e[0]=t,e[1]=r,e[2]=n,e[3]=s,e[4]=i,e[5]=o,e[6]=a,e[7]=l,e[8]=u,e[9]=c,e[10]=h,e[11]=d,e[12]=p,e[13]=f,e[14]=m,e[15]=y,e}function a(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function l(e,t){if(e===t){const r=t[1],n=t[2],s=t[3],i=t[6],o=t[7],a=t[11];e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=r,e[6]=t[9],e[7]=t[13],e[8]=n,e[9]=i,e[11]=t[14],e[12]=s,e[13]=o,e[14]=a}else e[0]=t[0],e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=t[1],e[5]=t[5],e[6]=t[9],e[7]=t[13],e[8]=t[2],e[9]=t[6],e[10]=t[10],e[11]=t[14],e[12]=t[3],e[13]=t[7],e[14]=t[11],e[15]=t[15];return e}function u(e,t){const r=t[0],n=t[1],s=t[2],i=t[3],o=t[4],a=t[5],l=t[6],u=t[7],c=t[8],h=t[9],d=t[10],p=t[11],f=t[12],m=t[13],y=t[14],g=t[15],b=r*a-n*o,v=r*l-s*o,_=r*u-i*o,w=n*l-s*a,x=n*u-i*a,C=s*u-i*l,E=c*m-h*f,M=c*y-d*f,O=c*g-p*f,S=h*y-d*m,I=h*g-p*m,q=d*g-p*y;let U=b*q-v*I+_*S+w*O-x*M+C*E;return U?(U=1/U,e[0]=(a*q-l*I+u*S)*U,e[1]=(s*I-n*q-i*S)*U,e[2]=(m*C-y*x+g*w)*U,e[3]=(d*x-h*C-p*w)*U,e[4]=(l*O-o*q-u*M)*U,e[5]=(r*q-s*O+i*M)*U,e[6]=(y*_-f*C-g*v)*U,e[7]=(c*C-d*_+p*v)*U,e[8]=(o*I-a*O+u*E)*U,e[9]=(n*O-r*I-i*E)*U,e[10]=(f*x-m*_+g*b)*U,e[11]=(h*_-c*x-p*b)*U,e[12]=(a*M-o*S-l*E)*U,e[13]=(r*S-n*M+s*E)*U,e[14]=(m*v-f*w-y*b)*U,e[15]=(c*w-h*v+d*b)*U,e):null}function c(e,t,r){const n=t[0],s=t[1],i=t[2],o=t[3],a=t[4],l=t[5],u=t[6],c=t[7],h=t[8],d=t[9],p=t[10],f=t[11],m=t[12],y=t[13],g=t[14],b=t[15];let v=r[0],_=r[1],w=r[2],x=r[3];return e[0]=v*n+_*a+w*h+x*m,e[1]=v*s+_*l+w*d+x*y,e[2]=v*i+_*u+w*p+x*g,e[3]=v*o+_*c+w*f+x*b,v=r[4],_=r[5],w=r[6],x=r[7],e[4]=v*n+_*a+w*h+x*m,e[5]=v*s+_*l+w*d+x*y,e[6]=v*i+_*u+w*p+x*g,e[7]=v*o+_*c+w*f+x*b,v=r[8],_=r[9],w=r[10],x=r[11],e[8]=v*n+_*a+w*h+x*m,e[9]=v*s+_*l+w*d+x*y,e[10]=v*i+_*u+w*p+x*g,e[11]=v*o+_*c+w*f+x*b,v=r[12],_=r[13],w=r[14],x=r[15],e[12]=v*n+_*a+w*h+x*m,e[13]=v*s+_*l+w*d+x*y,e[14]=v*i+_*u+w*p+x*g,e[15]=v*o+_*c+w*f+x*b,e}function h(e,t,r){const n=r[0],s=r[1],i=r[2];let o,a,l,u,c,h,d,p,f,m,y,g;return t===e?(e[12]=t[0]*n+t[4]*s+t[8]*i+t[12],e[13]=t[1]*n+t[5]*s+t[9]*i+t[13],e[14]=t[2]*n+t[6]*s+t[10]*i+t[14],e[15]=t[3]*n+t[7]*s+t[11]*i+t[15]):(o=t[0],a=t[1],l=t[2],u=t[3],c=t[4],h=t[5],d=t[6],p=t[7],f=t[8],m=t[9],y=t[10],g=t[11],e[0]=o,e[1]=a,e[2]=l,e[3]=u,e[4]=c,e[5]=h,e[6]=d,e[7]=p,e[8]=f,e[9]=m,e[10]=y,e[11]=g,e[12]=o*n+c*s+f*i+t[12],e[13]=a*n+h*s+m*i+t[13],e[14]=l*n+d*s+y*i+t[14],e[15]=u*n+p*s+g*i+t[15]),e}function d(e,t,r){const n=r[0],s=r[1],i=r[2];return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e[4]=t[4]*s,e[5]=t[5]*s,e[6]=t[6]*s,e[7]=t[7]*s,e[8]=t[8]*i,e[9]=t[9]*i,e[10]=t[10]*i,e[11]=t[11]*i,e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function p(e,t,r,n){let i,o,a,l,u,c,h,d,p,f,m,y,g,b,v,_,w,x,C,E,M,O,S,I,q=n[0],U=n[1],T=n[2],N=Math.sqrt(q*q+U*U+T*T);return N<s.E?null:(N=1/N,q*=N,U*=N,T*=N,i=Math.sin(r),o=Math.cos(r),a=1-o,l=t[0],u=t[1],c=t[2],h=t[3],d=t[4],p=t[5],f=t[6],m=t[7],y=t[8],g=t[9],b=t[10],v=t[11],_=q*q*a+o,w=U*q*a+T*i,x=T*q*a-U*i,C=q*U*a-T*i,E=U*U*a+o,M=T*U*a+q*i,O=q*T*a+U*i,S=U*T*a-q*i,I=T*T*a+o,e[0]=l*_+d*w+y*x,e[1]=u*_+p*w+g*x,e[2]=c*_+f*w+b*x,e[3]=h*_+m*w+v*x,e[4]=l*C+d*E+y*M,e[5]=u*C+p*E+g*M,e[6]=c*C+f*E+b*M,e[7]=h*C+m*E+v*M,e[8]=l*O+d*S+y*I,e[9]=u*O+p*S+g*I,e[10]=c*O+f*S+b*I,e[11]=h*O+m*S+v*I,t!==e&&(e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e)}function f(e,t){const r=Math.sin(t),n=Math.cos(t);return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=n,e[6]=r,e[7]=0,e[8]=0,e[9]=-r,e[10]=n,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function m(e,t,r){const n=t[0],s=t[1],i=t[2],o=t[3],a=n+n,l=s+s,u=i+i,c=n*a,h=n*l,d=n*u,p=s*l,f=s*u,m=i*u,y=o*a,g=o*l,b=o*u;return e[0]=1-(p+m),e[1]=h+b,e[2]=d-g,e[3]=0,e[4]=h-b,e[5]=1-(c+m),e[6]=f+y,e[7]=0,e[8]=d+g,e[9]=f-y,e[10]=1-(c+p),e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e}const y=(0,n.c)();function g(e,t,r){return e[0]=t[0]-r[0],e[1]=t[1]-r[1],e[2]=t[2]-r[2],e[3]=t[3]-r[3],e[4]=t[4]-r[4],e[5]=t[5]-r[5],e[6]=t[6]-r[6],e[7]=t[7]-r[7],e[8]=t[8]-r[8],e[9]=t[9]-r[9],e[10]=t[10]-r[10],e[11]=t[11]-r[11],e[12]=t[12]-r[12],e[13]=t[13]-r[13],e[14]=t[14]-r[14],e[15]=t[15]-r[15],e}function b(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&e[4]===t[4]&&e[5]===t[5]&&e[6]===t[6]&&e[7]===t[7]&&e[8]===t[8]&&e[9]===t[9]&&e[10]===t[10]&&e[11]===t[11]&&e[12]===t[12]&&e[13]===t[13]&&e[14]===t[14]&&e[15]===t[15]}function v(e,t){if(e===t)return!0;const r=e[0],n=e[1],i=e[2],o=e[3],a=e[4],l=e[5],u=e[6],c=e[7],h=e[8],d=e[9],p=e[10],f=e[11],m=e[12],y=e[13],g=e[14],b=e[15],v=t[0],_=t[1],w=t[2],x=t[3],C=t[4],E=t[5],M=t[6],O=t[7],S=t[8],I=t[9],q=t[10],U=t[11],T=t[12],N=t[13],A=t[14],P=t[15];return Math.abs(r-v)<=s.E*Math.max(1,Math.abs(r),Math.abs(v))&&Math.abs(n-_)<=s.E*Math.max(1,Math.abs(n),Math.abs(_))&&Math.abs(i-w)<=s.E*Math.max(1,Math.abs(i),Math.abs(w))&&Math.abs(o-x)<=s.E*Math.max(1,Math.abs(o),Math.abs(x))&&Math.abs(a-C)<=s.E*Math.max(1,Math.abs(a),Math.abs(C))&&Math.abs(l-E)<=s.E*Math.max(1,Math.abs(l),Math.abs(E))&&Math.abs(u-M)<=s.E*Math.max(1,Math.abs(u),Math.abs(M))&&Math.abs(c-O)<=s.E*Math.max(1,Math.abs(c),Math.abs(O))&&Math.abs(h-S)<=s.E*Math.max(1,Math.abs(h),Math.abs(S))&&Math.abs(d-I)<=s.E*Math.max(1,Math.abs(d),Math.abs(I))&&Math.abs(p-q)<=s.E*Math.max(1,Math.abs(p),Math.abs(q))&&Math.abs(f-U)<=s.E*Math.max(1,Math.abs(f),Math.abs(U))&&Math.abs(m-T)<=s.E*Math.max(1,Math.abs(m),Math.abs(T))&&Math.abs(y-N)<=s.E*Math.max(1,Math.abs(y),Math.abs(N))&&Math.abs(g-A)<=s.E*Math.max(1,Math.abs(g),Math.abs(A))&&Math.abs(b-P)<=s.E*Math.max(1,Math.abs(b),Math.abs(P))}function _(e){const t=s.E,r=e[0],n=e[1],i=e[2],o=e[4],a=e[5],l=e[6],u=e[8],c=e[9],h=e[10];return Math.abs(1-(r*r+o*o+u*u))<=t&&Math.abs(1-(n*n+a*a+c*c))<=t&&Math.abs(1-(i*i+l*l+h*h))<=t}const w=c,x=g;Object.freeze({__proto__:null,copy:i,set:o,identity:a,transpose:l,invert:u,adjoint:function(e,t){const r=t[0],n=t[1],s=t[2],i=t[3],o=t[4],a=t[5],l=t[6],u=t[7],c=t[8],h=t[9],d=t[10],p=t[11],f=t[12],m=t[13],y=t[14],g=t[15];return e[0]=a*(d*g-p*y)-h*(l*g-u*y)+m*(l*p-u*d),e[1]=-(n*(d*g-p*y)-h*(s*g-i*y)+m*(s*p-i*d)),e[2]=n*(l*g-u*y)-a*(s*g-i*y)+m*(s*u-i*l),e[3]=-(n*(l*p-u*d)-a*(s*p-i*d)+h*(s*u-i*l)),e[4]=-(o*(d*g-p*y)-c*(l*g-u*y)+f*(l*p-u*d)),e[5]=r*(d*g-p*y)-c*(s*g-i*y)+f*(s*p-i*d),e[6]=-(r*(l*g-u*y)-o*(s*g-i*y)+f*(s*u-i*l)),e[7]=r*(l*p-u*d)-o*(s*p-i*d)+c*(s*u-i*l),e[8]=o*(h*g-p*m)-c*(a*g-u*m)+f*(a*p-u*h),e[9]=-(r*(h*g-p*m)-c*(n*g-i*m)+f*(n*p-i*h)),e[10]=r*(a*g-u*m)-o*(n*g-i*m)+f*(n*u-i*a),e[11]=-(r*(a*p-u*h)-o*(n*p-i*h)+c*(n*u-i*a)),e[12]=-(o*(h*y-d*m)-c*(a*y-l*m)+f*(a*d-l*h)),e[13]=r*(h*y-d*m)-c*(n*y-s*m)+f*(n*d-s*h),e[14]=-(r*(a*y-l*m)-o*(n*y-s*m)+f*(n*l-s*a)),e[15]=r*(a*d-l*h)-o*(n*d-s*h)+c*(n*l-s*a),e},determinant:function(e){const t=e[0],r=e[1],n=e[2],s=e[3],i=e[4],o=e[5],a=e[6],l=e[7],u=e[8],c=e[9],h=e[10],d=e[11],p=e[12],f=e[13],m=e[14],y=e[15];return(t*o-r*i)*(h*y-d*m)-(t*a-n*i)*(c*y-d*f)+(t*l-s*i)*(c*m-h*f)+(r*a-n*o)*(u*y-d*p)-(r*l-s*o)*(u*m-h*p)+(n*l-s*a)*(u*f-c*p)},multiply:c,translate:h,scale:d,rotate:p,rotateX:function(e,t,r){const n=Math.sin(r),s=Math.cos(r),i=t[4],o=t[5],a=t[6],l=t[7],u=t[8],c=t[9],h=t[10],d=t[11];return t!==e&&(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[4]=i*s+u*n,e[5]=o*s+c*n,e[6]=a*s+h*n,e[7]=l*s+d*n,e[8]=u*s-i*n,e[9]=c*s-o*n,e[10]=h*s-a*n,e[11]=d*s-l*n,e},rotateY:function(e,t,r){const n=Math.sin(r),s=Math.cos(r),i=t[0],o=t[1],a=t[2],l=t[3],u=t[8],c=t[9],h=t[10],d=t[11];return t!==e&&(e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=i*s-u*n,e[1]=o*s-c*n,e[2]=a*s-h*n,e[3]=l*s-d*n,e[8]=i*n+u*s,e[9]=o*n+c*s,e[10]=a*n+h*s,e[11]=l*n+d*s,e},rotateZ:function(e,t,r){const n=Math.sin(r),s=Math.cos(r),i=t[0],o=t[1],a=t[2],l=t[3],u=t[4],c=t[5],h=t[6],d=t[7];return t!==e&&(e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=i*s+u*n,e[1]=o*s+c*n,e[2]=a*s+h*n,e[3]=l*s+d*n,e[4]=u*s-i*n,e[5]=c*s-o*n,e[6]=h*s-a*n,e[7]=d*s-l*n,e},fromTranslation:function(e,t){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=t[0],e[13]=t[1],e[14]=t[2],e[15]=1,e},fromScaling:function(e,t){return e[0]=t[0],e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=t[1],e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=t[2],e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromRotation:function(e,t,r){let n,i,o,a=r[0],l=r[1],u=r[2],c=Math.sqrt(a*a+l*l+u*u);return c<s.E?null:(c=1/c,a*=c,l*=c,u*=c,n=Math.sin(t),i=Math.cos(t),o=1-i,e[0]=a*a*o+i,e[1]=l*a*o+u*n,e[2]=u*a*o-l*n,e[3]=0,e[4]=a*l*o-u*n,e[5]=l*l*o+i,e[6]=u*l*o+a*n,e[7]=0,e[8]=a*u*o+l*n,e[9]=l*u*o-a*n,e[10]=u*u*o+i,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e)},fromXRotation:f,fromYRotation:function(e,t){const r=Math.sin(t),n=Math.cos(t);return e[0]=n,e[1]=0,e[2]=-r,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=r,e[9]=0,e[10]=n,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromZRotation:function(e,t){const r=Math.sin(t),n=Math.cos(t);return e[0]=n,e[1]=r,e[2]=0,e[3]=0,e[4]=-r,e[5]=n,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromRotationTranslation:m,fromQuat2:function(e,t){const r=y,n=-t[0],s=-t[1],i=-t[2],o=t[3],a=t[4],l=t[5],u=t[6],c=t[7],h=n*n+s*s+i*i+o*o;return h>0?(r[0]=2*(a*o+c*n+l*i-u*s)/h,r[1]=2*(l*o+c*s+u*n-a*i)/h,r[2]=2*(u*o+c*i+a*s-l*n)/h):(r[0]=2*(a*o+c*n+l*i-u*s),r[1]=2*(l*o+c*s+u*n-a*i),r[2]=2*(u*o+c*i+a*s-l*n)),m(e,t,r),e},getTranslation:function(e,t){return e[0]=t[12],e[1]=t[13],e[2]=t[14],e},getScaling:function(e,t){const r=t[0],n=t[1],s=t[2],i=t[4],o=t[5],a=t[6],l=t[8],u=t[9],c=t[10];return e[0]=Math.sqrt(r*r+n*n+s*s),e[1]=Math.sqrt(i*i+o*o+a*a),e[2]=Math.sqrt(l*l+u*u+c*c),e},getRotation:function(e,t){const r=t[0]+t[5]+t[10];let n=0;return r>0?(n=2*Math.sqrt(r+1),e[3]=.25*n,e[0]=(t[6]-t[9])/n,e[1]=(t[8]-t[2])/n,e[2]=(t[1]-t[4])/n):t[0]>t[5]&&t[0]>t[10]?(n=2*Math.sqrt(1+t[0]-t[5]-t[10]),e[3]=(t[6]-t[9])/n,e[0]=.25*n,e[1]=(t[1]+t[4])/n,e[2]=(t[8]+t[2])/n):t[5]>t[10]?(n=2*Math.sqrt(1+t[5]-t[0]-t[10]),e[3]=(t[8]-t[2])/n,e[0]=(t[1]+t[4])/n,e[1]=.25*n,e[2]=(t[6]+t[9])/n):(n=2*Math.sqrt(1+t[10]-t[0]-t[5]),e[3]=(t[1]-t[4])/n,e[0]=(t[8]+t[2])/n,e[1]=(t[6]+t[9])/n,e[2]=.25*n),e},fromRotationTranslationScale:function(e,t,r,n){const s=t[0],i=t[1],o=t[2],a=t[3],l=s+s,u=i+i,c=o+o,h=s*l,d=s*u,p=s*c,f=i*u,m=i*c,y=o*c,g=a*l,b=a*u,v=a*c,_=n[0],w=n[1],x=n[2];return e[0]=(1-(f+y))*_,e[1]=(d+v)*_,e[2]=(p-b)*_,e[3]=0,e[4]=(d-v)*w,e[5]=(1-(h+y))*w,e[6]=(m+g)*w,e[7]=0,e[8]=(p+b)*x,e[9]=(m-g)*x,e[10]=(1-(h+f))*x,e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e},fromRotationTranslationScaleOrigin:function(e,t,r,n,s){const i=t[0],o=t[1],a=t[2],l=t[3],u=i+i,c=o+o,h=a+a,d=i*u,p=i*c,f=i*h,m=o*c,y=o*h,g=a*h,b=l*u,v=l*c,_=l*h,w=n[0],x=n[1],C=n[2],E=s[0],M=s[1],O=s[2],S=(1-(m+g))*w,I=(p+_)*w,q=(f-v)*w,U=(p-_)*x,T=(1-(d+g))*x,N=(y+b)*x,A=(f+v)*C,P=(y-b)*C,k=(1-(d+m))*C;return e[0]=S,e[1]=I,e[2]=q,e[3]=0,e[4]=U,e[5]=T,e[6]=N,e[7]=0,e[8]=A,e[9]=P,e[10]=k,e[11]=0,e[12]=r[0]+E-(S*E+U*M+A*O),e[13]=r[1]+M-(I*E+T*M+P*O),e[14]=r[2]+O-(q*E+N*M+k*O),e[15]=1,e},fromQuat:function(e,t){const r=t[0],n=t[1],s=t[2],i=t[3],o=r+r,a=n+n,l=s+s,u=r*o,c=n*o,h=n*a,d=s*o,p=s*a,f=s*l,m=i*o,y=i*a,g=i*l;return e[0]=1-h-f,e[1]=c+g,e[2]=d-y,e[3]=0,e[4]=c-g,e[5]=1-u-f,e[6]=p+m,e[7]=0,e[8]=d+y,e[9]=p-m,e[10]=1-u-h,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},frustum:function(e,t,r,n,s,i,o){const a=1/(r-t),l=1/(s-n),u=1/(i-o);return e[0]=2*i*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=2*i*l,e[6]=0,e[7]=0,e[8]=(r+t)*a,e[9]=(s+n)*l,e[10]=(o+i)*u,e[11]=-1,e[12]=0,e[13]=0,e[14]=o*i*2*u,e[15]=0,e},perspective:function(e,t,r,n,s){const i=1/Math.tan(t/2);let o;return e[0]=i/r,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=i,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,null!=s&&s!==1/0?(o=1/(n-s),e[10]=(s+n)*o,e[14]=2*s*n*o):(e[10]=-1,e[14]=-2*n),e},perspectiveFromFieldOfView:function(e,t,r,n){const s=Math.tan(t.upDegrees*Math.PI/180),i=Math.tan(t.downDegrees*Math.PI/180),o=Math.tan(t.leftDegrees*Math.PI/180),a=Math.tan(t.rightDegrees*Math.PI/180),l=2/(o+a),u=2/(s+i);return e[0]=l,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=u,e[6]=0,e[7]=0,e[8]=-(o-a)*l*.5,e[9]=(s-i)*u*.5,e[10]=n/(r-n),e[11]=-1,e[12]=0,e[13]=0,e[14]=n*r/(r-n),e[15]=0,e},ortho:function(e,t,r,n,s,i,o){const a=1/(t-r),l=1/(n-s),u=1/(i-o);return e[0]=-2*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*u,e[11]=0,e[12]=(t+r)*a,e[13]=(s+n)*l,e[14]=(o+i)*u,e[15]=1,e},lookAt:function(e,t,r,n){let i,o,l,u,c,h,d,p,f,m;const y=t[0],g=t[1],b=t[2],v=n[0],_=n[1],w=n[2],x=r[0],C=r[1],E=r[2];return Math.abs(y-x)<s.E&&Math.abs(g-C)<s.E&&Math.abs(b-E)<s.E?a(e):(d=y-x,p=g-C,f=b-E,m=1/Math.sqrt(d*d+p*p+f*f),d*=m,p*=m,f*=m,i=_*f-w*p,o=w*d-v*f,l=v*p-_*d,m=Math.sqrt(i*i+o*o+l*l),m?(m=1/m,i*=m,o*=m,l*=m):(i=0,o=0,l=0),u=p*l-f*o,c=f*i-d*l,h=d*o-p*i,m=Math.sqrt(u*u+c*c+h*h),m?(m=1/m,u*=m,c*=m,h*=m):(u=0,c=0,h=0),e[0]=i,e[1]=u,e[2]=d,e[3]=0,e[4]=o,e[5]=c,e[6]=p,e[7]=0,e[8]=l,e[9]=h,e[10]=f,e[11]=0,e[12]=-(i*y+o*g+l*b),e[13]=-(u*y+c*g+h*b),e[14]=-(d*y+p*g+f*b),e[15]=1,e)},targetTo:function(e,t,r,n){const s=t[0],i=t[1],o=t[2],a=n[0],l=n[1],u=n[2];let c=s-r[0],h=i-r[1],d=o-r[2],p=c*c+h*h+d*d;p>0&&(p=1/Math.sqrt(p),c*=p,h*=p,d*=p);let f=l*d-u*h,m=u*c-a*d,y=a*h-l*c;return p=f*f+m*m+y*y,p>0&&(p=1/Math.sqrt(p),f*=p,m*=p,y*=p),e[0]=f,e[1]=m,e[2]=y,e[3]=0,e[4]=h*y-d*m,e[5]=d*f-c*y,e[6]=c*m-h*f,e[7]=0,e[8]=c,e[9]=h,e[10]=d,e[11]=0,e[12]=s,e[13]=i,e[14]=o,e[15]=1,e},str:function(e){return"mat4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+", "+e[9]+", "+e[10]+", "+e[11]+", "+e[12]+", "+e[13]+", "+e[14]+", "+e[15]+")"},frob:function(e){return Math.sqrt(e[0]**2+e[1]**2+e[2]**2+e[3]**2+e[4]**2+e[5]**2+e[6]**2+e[7]**2+e[8]**2+e[9]**2+e[10]**2+e[11]**2+e[12]**2+e[13]**2+e[14]**2+e[15]**2)},add:function(e,t,r){return e[0]=t[0]+r[0],e[1]=t[1]+r[1],e[2]=t[2]+r[2],e[3]=t[3]+r[3],e[4]=t[4]+r[4],e[5]=t[5]+r[5],e[6]=t[6]+r[6],e[7]=t[7]+r[7],e[8]=t[8]+r[8],e[9]=t[9]+r[9],e[10]=t[10]+r[10],e[11]=t[11]+r[11],e[12]=t[12]+r[12],e[13]=t[13]+r[13],e[14]=t[14]+r[14],e[15]=t[15]+r[15],e},subtract:g,multiplyScalar:function(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e[2]=t[2]*r,e[3]=t[3]*r,e[4]=t[4]*r,e[5]=t[5]*r,e[6]=t[6]*r,e[7]=t[7]*r,e[8]=t[8]*r,e[9]=t[9]*r,e[10]=t[10]*r,e[11]=t[11]*r,e[12]=t[12]*r,e[13]=t[13]*r,e[14]=t[14]*r,e[15]=t[15]*r,e},multiplyScalarAndAdd:function(e,t,r,n){return e[0]=t[0]+r[0]*n,e[1]=t[1]+r[1]*n,e[2]=t[2]+r[2]*n,e[3]=t[3]+r[3]*n,e[4]=t[4]+r[4]*n,e[5]=t[5]+r[5]*n,e[6]=t[6]+r[6]*n,e[7]=t[7]+r[7]*n,e[8]=t[8]+r[8]*n,e[9]=t[9]+r[9]*n,e[10]=t[10]+r[10]*n,e[11]=t[11]+r[11]*n,e[12]=t[12]+r[12]*n,e[13]=t[13]+r[13]*n,e[14]=t[14]+r[14]*n,e[15]=t[15]+r[15]*n,e},exactEquals:b,equals:v,isOrthoNormal:_,mul:w,sub:x})},25929:(e,t,r)=>{r.d(t,{f:()=>i,i:()=>h,p:()=>p,r:()=>a,t:()=>o,w:()=>l});var n=r(70586),s=r(17452);function i(e,t){const r=t&&t.url&&t.url.path;if(e&&r&&(e=(0,s.hF)(e,r,{preserveProtocolRelative:!0}),t.portalItem&&t.readResourcePaths)){const r=(0,s.PF)(e,t.portalItem.itemUrl);c.test(r)&&t.readResourcePaths.push(t.portalItem.resourceFromPath(r).path)}return d(e,t&&t.portal)}function o(e,t,r=0){if(!e)return e;!(0,s.YP)(e)&&t&&t.blockedRelativeUrls&&t.blockedRelativeUrls.push(e);let n=(0,s.hF)(e);if(t){const r=t.verifyItemRelativeUrls&&t.verifyItemRelativeUrls.rootPath||t.url&&t.url.path;if(r){const i=d(r,t.portal);n=(0,s.PF)(d(n,t.portal),i,i),n!==e&&t.verifyItemRelativeUrls&&t.verifyItemRelativeUrls.writtenUrls.push(n)}}return n=function(e,t){return t&&!t.isPortal&&t.urlKey&&t.customBaseUrl?(0,s.Ie)(e,`${t.urlKey}.${t.customBaseUrl}`,t.portalHostname):e}(n,t&&t.portal),(0,s.YP)(n)&&(n=(0,s.Fv)(n)),null!=t&&t.resources&&null!=t&&t.portalItem&&!(0,s.YP)(n)&&!(0,s.HK)(n)&&0===r&&t.resources.toKeep.push({resource:t.portalItem.resourceFromPath(n)}),n}function a(e,t,r){return i(e,r)}function l(e,t,r,n){const s=o(e,n);void 0!==s&&(t[r]=s)}const u=/\/items\/([^\/]+)\/resources\//,c=/^\.\/resources\//;function h(e){const t=(0,n.pC)(e)?e.match(u):null;return(0,n.pC)(t)?t[1]:null}function d(e,t){if(!t||t.isPortal||!t.urlKey||!t.customBaseUrl)return e;const r=`${t.urlKey}.${t.customBaseUrl}`;return(0,s.D6)(s.Gd,`${s.Gd.scheme}://${r}`)?(0,s.Ie)(e,t.portalHostname,r):(0,s.Ie)(e,r,t.portalHostname)}const p=Object.freeze({__proto__:null,fromJSON:i,toJSON:o,read:a,write:l,itemIdFromResourceUrl:h})},65617:(e,t,r)=>{function n(){return[0,0,0]}function s(e){return[e[0],e[1],e[2]]}function i(e,t,r){return[e,t,r]}function o(e){const t=[0,0,0],r=Math.min(3,e.length);for(let n=0;n<r;++n)t[n]=e[n];return t}function a(e,t){return new Float64Array(e,t,3)}function l(){return i(1,1,1)}function u(){return i(1,0,0)}function c(){return i(0,1,0)}function h(){return i(0,0,1)}r.d(t,{O:()=>p,Z:()=>d,a:()=>s,b:()=>a,c:()=>n,d:()=>o,f:()=>i});const d=[0,0,0],p=l(),f=u(),m=c(),y=h();Object.freeze({__proto__:null,create:n,clone:s,fromValues:i,fromArray:o,createView:a,zeros:function(){return[0,0,0]},ones:l,unitX:u,unitY:c,unitZ:h,ZEROS:d,ONES:p,UNIT_X:f,UNIT_Y:m,UNIT_Z:y})},35270:(e,t,r)=>{r.d(t,{h$:()=>s,VL:()=>i,rW:()=>l,B7:()=>a});const n={transparent:[0,0,0,0],black:[0,0,0,1],silver:[192,192,192,1],gray:[128,128,128,1],white:[255,255,255,1],maroon:[128,0,0,1],red:[255,0,0,1],purple:[128,0,128,1],fuchsia:[255,0,255,1],green:[0,128,0,1],lime:[0,255,0,1],olive:[128,128,0,1],yellow:[255,255,0,1],navy:[0,0,128,1],blue:[0,0,255,1],teal:[0,128,128,1],aqua:[0,255,255,1],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],blanchedalmond:[255,235,205,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],oldlace:[253,245,230,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],rebeccapurple:[102,51,153,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],whitesmoke:[245,245,245,1],yellowgreen:[154,205,50,1]};function s(e){var t;return null!=(t=n[e.toLowerCase()])?t:null}function i(e){const t=s(e);return t?[...t]:t}function o(e,t,r){r<0&&++r,r>1&&--r;const n=6*r;return n<1?e+(t-e)*n:2*r<1?t:3*r<2?e+(t-e)*(2/3-r)*6:e}function a(e,t,r,n=1){const s=(e%360+360)%360/360,i=r<=.5?r*(t+1):r+t-r*t,a=2*r-i;return[Math.round(255*o(a,i,s+1/3)),Math.round(255*o(a,i,s)),Math.round(255*o(a,i,s-1/3)),n]}function l(e){const t=e.length>5,r=t?8:4,n=(1<<r)-1,s=t?1:17,i=t?9===e.length:5===e.length;let o=Number("0x"+e.substr(1));if(isNaN(o))return null;const a=[0,0,0,1];let l;return i&&(l=o&n,o>>=r,a[3]=s*l/255),l=o&n,o>>=r,a[2]=s*l,l=o&n,o>>=r,a[1]=s*l,l=o&n,o>>=r,a[0]=s*l,a}},81049:(e,t,r)=>{r.d(t,{Z:()=>U});var n,s=r(43697),i=r(3894),o=r(32448),a=r(22974),l=r(70586),u=r(71143),c=r(90584),h=r(5600),d=r(75215),p=r(52421),f=r(52011),m=r(58971),y=r(39020);class g{constructor(){this._observers=[]}observe(e){return this._observers.includes(e)||this._observers.push(e),new y.X(this._observers,e)}notify(){const e=this._observers.slice();for(let t=0;t<e.length;++t){const r=e[t];r.onInvalidated(),r.onCommitted()}}}const b=new u.Z(class{constructor(){this.target=null,this.cancellable=!1,this.defaultPrevented=!1,this.item=void 0,this.type=void 0}preventDefault(){this.cancellable&&(this.defaultPrevented=!0)}reset(e){this.defaultPrevented=!1,this.item=e}},void 0,(e=>{e.item=null,e.target=null,e.defaultPrevented=!1,e.cancellable=!1})),v=()=>{};function _(e){return e?e instanceof q?e.toArray():e.length?Array.prototype.slice.apply(e):[]:[]}function w(e){if(e&&e.length)return e[0]}function x(e,t,r,n){const s=Math.min(e.length-r,t.length-n);let i=0;for(;i<s&&e[r+i]===t[n+i];)i++;return i}function C(e,t,r,n){t&&t.forEach(((t,s,i)=>{e.push(t),C(e,r.call(n,t,s,i),r,n)}))}const E=new Set,M=new Set,O=new Set,S=new Map;let I=0,q=n=class extends o.Z.EventedAccessor{constructor(e){super(e),this._chgListeners=[],this._notifications=null,this._timer=null,this._observable=new g,this.length=0,this._items=[],Object.defineProperty(this,"uid",{value:I++})}static isCollection(e){return null!=e&&e instanceof n}normalizeCtorArgs(e){return e?Array.isArray(e)||e instanceof n?{items:e}:e:{}}destroy(){this.removeAll()}*[Symbol.iterator](){yield*this.items}get items(){return(0,m.it)(this._observable),this._items}set items(e){this._emitBeforeChanges(1)||(this._splice(0,this.length,..._(e)),this._emitAfterChanges(1))}hasEventListener(e){return"change"===e?this._chgListeners.length>0:this._emitter.hasEventListener(e)}on(e,t){if("change"===e){const e=this._chgListeners,r={removed:!1,callback:t};return e.push(r),this._notifications&&this._notifications.push({listeners:e.slice(),items:this._items.slice(),changes:[]}),{remove(){this.remove=v,r.removed=!0,e.splice(e.indexOf(r),1)}}}return this._emitter.on(e,t)}once(e,t){const r=this.on(e,t);return{remove(){r.remove()}}}add(e,t){if((0,m.it)(this._observable),this._emitBeforeChanges(1))return this;const r=this.getNextIndex(null!=t?t:null);return this._splice(r,0,e),this._emitAfterChanges(1),this}addMany(e,t=this._items.length){if((0,m.it)(this._observable),!e||!e.length)return this;if(this._emitBeforeChanges(1))return this;const r=this.getNextIndex(t);return this._splice(r,0,..._(e)),this._emitAfterChanges(1),this}removeAll(){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(2))return[];const e=this._splice(0,this.length)||[];return this._emitAfterChanges(2),e}clone(){return(0,m.it)(this._observable),this._createNewInstance({items:this._items.map(a.d9)})}concat(...e){(0,m.it)(this._observable);const t=e.map(_);return this._createNewInstance({items:this._items.concat(...t)})}drain(e,t){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(2))return;const r=(0,l.j0)(this._splice(0,this.length)),n=r.length;for(let s=0;s<n;s++)e.call(t,r[s],s,r);this._emitAfterChanges(2)}every(e,t){return(0,m.it)(this._observable),this._items.every(e,t)}filter(e,t){let r;return(0,m.it)(this._observable),r=2===arguments.length?this._items.filter(e,t):this._items.filter(e),this._createNewInstance({items:r})}find(e,t){return(0,m.it)(this._observable),this._items.find(e,t)}findIndex(e,t){return(0,m.it)(this._observable),this._items.findIndex(e,t)}flatten(e,t){(0,m.it)(this._observable);const r=[];return C(r,this,e,t),new n(r)}forEach(e,t){return(0,m.it)(this._observable),this._items.forEach(e,t)}getItemAt(e){return(0,m.it)(this._observable),this._items[e]}getNextIndex(e){(0,m.it)(this._observable);const t=this.length;return(e=null==e?t:e)<0?e=0:e>t&&(e=t),e}includes(e,t=0){return(0,m.it)(this._observable),this._items.includes(e,t)}indexOf(e,t=0){return(0,m.it)(this._observable),this._items.indexOf(e,t)}join(e=","){return(0,m.it)(this._observable),this._items.join(e)}lastIndexOf(e,t=this.length-1){return(0,m.it)(this._observable),this._items.lastIndexOf(e,t)}map(e,t){(0,m.it)(this._observable);const r=this._items.map(e,t);return new n({items:r})}reorder(e,t=this.length-1){(0,m.it)(this._observable);const r=this.indexOf(e);if(-1!==r){if(t<0?t=0:t>=this.length&&(t=this.length-1),r!==t){if(this._emitBeforeChanges(4))return e;this._splice(r,1),this._splice(t,0,e),this._emitAfterChanges(4)}return e}}pop(){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(2))return;const e=w(this._splice(this.length-1,1));return this._emitAfterChanges(2),e}push(...e){return(0,m.it)(this._observable),this._emitBeforeChanges(1)||(this._splice(this.length,0,...e),this._emitAfterChanges(1)),this.length}reduce(e,t){(0,m.it)(this._observable);const r=this._items;return 2===arguments.length?r.reduce(e,t):r.reduce(e)}reduceRight(e,t){(0,m.it)(this._observable);const r=this._items;return 2===arguments.length?r.reduceRight(e,t):r.reduceRight(e)}remove(e){return(0,m.it)(this._observable),this.removeAt(this.indexOf(e))}removeAt(e){if((0,m.it)(this._observable),e<0||e>=this.length||this._emitBeforeChanges(2))return;const t=w(this._splice(e,1));return this._emitAfterChanges(2),t}removeMany(e){if((0,m.it)(this._observable),!e||!e.length||this._emitBeforeChanges(2))return[];const t=e instanceof n?e.toArray():e,r=this._items,s=[],i=t.length;for(let e=0;e<i;e++){const n=t[e],i=r.indexOf(n);if(i>-1){const n=1+x(t,r,e+1,i+1),o=this._splice(i,n);o&&o.length>0&&s.push.apply(s,o),e+=n-1}}return this._emitAfterChanges(2),s}reverse(){if((0,m.it)(this._observable),this._emitBeforeChanges(4))return this;const e=this._splice(0,this.length);return e&&(e.reverse(),this._splice(0,0,...e)),this._emitAfterChanges(4),this}shift(){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(2))return;const e=w(this._splice(0,1));return this._emitAfterChanges(2),e}slice(e=0,t=this.length){return(0,m.it)(this._observable),this._createNewInstance({items:this._items.slice(e,t)})}some(e,t){return(0,m.it)(this._observable),this._items.some(e,t)}sort(e){if((0,m.it)(this._observable),!this.length||this._emitBeforeChanges(4))return this;const t=(0,l.j0)(this._splice(0,this.length));return arguments.length?t.sort(e):t.sort(),this._splice(0,0,...t),this._emitAfterChanges(4),this}splice(e,t,...r){(0,m.it)(this._observable);const n=(t?2:0)|(r.length?1:0);if(this._emitBeforeChanges(n))return[];const s=this._splice(e,t,...r)||[];return this._emitAfterChanges(n),s}toArray(){return(0,m.it)(this._observable),this._items.slice()}toJSON(){return(0,m.it)(this._observable),this.toArray()}toLocaleString(){return(0,m.it)(this._observable),this._items.toLocaleString()}toString(){return(0,m.it)(this._observable),this._items.toString()}unshift(...e){return(0,m.it)(this._observable),!e.length||this._emitBeforeChanges(1)||(this._splice(0,0,...e),this._emitAfterChanges(1)),this.length}_createNewInstance(e){return new this.constructor(e)}_splice(e,t,...r){const n=this._items,s=this.itemType;let i,o;if(!this._notifications&&this.hasEventListener("change")&&(this._notifications=[{listeners:this._chgListeners.slice(),items:this._items.slice(),changes:[]}],this._timer&&this._timer.remove(),this._timer=(0,c.Os)((()=>this._dispatchChange()))),t){if(o=n.splice(e,t),this.hasEventListener("before-remove")){const t=b.acquire();t.target=this,t.cancellable=!0;for(let r=0,s=o.length;r<s;r++)i=o[r],t.reset(i),this.emit("before-remove",t),t.defaultPrevented&&(o.splice(r,1),n.splice(e,0,i),e+=1,r-=1,s-=1);b.release(t)}if(this.length=this._items.length,this.hasEventListener("after-remove")){const e=b.acquire();e.target=this,e.cancellable=!1;const t=o.length;for(let r=0;r<t;r++)e.reset(o[r]),this.emit("after-remove",e);b.release(e)}}if(r&&r.length){if(s){const e=[];for(const t of r){const r=s.ensureType(t);null==r&&null!=t||e.push(r)}r=e}const t=this.hasEventListener("before-add"),i=this.hasEventListener("after-add"),o=e===this.length;if(t||i){const s=b.acquire();s.target=this,s.cancellable=!0;const a=b.acquire();a.target=this,a.cancellable=!1;for(const l of r)t?(s.reset(l),this.emit("before-add",s),s.defaultPrevented||(o?n.push(l):n.splice(e++,0,l),this._set("length",n.length),i&&(a.reset(l),this.emit("after-add",a)))):(o?n.push(l):n.splice(e++,0,l),this._set("length",n.length),a.reset(l),this.emit("after-add",a));b.release(a),b.release(s)}else{if(o)for(const e of r)n.push(e);else n.splice(e,0,...r);this._set("length",n.length)}}return(r&&r.length||o&&o.length)&&this._notifyChangeEvent(r,o),o}_emitBeforeChanges(e){let t=!1;if(this.hasEventListener("before-changes")){const r=b.acquire();r.target=this,r.cancellable=!0,r.type=e,this.emit("before-changes",r),t=r.defaultPrevented,b.release(r)}return t}_emitAfterChanges(e){if(this.hasEventListener("after-changes")){const t=b.acquire();t.target=this,t.cancellable=!1,t.type=e,this.emit("after-changes",t),b.release(t)}this._observable.notify()}_notifyChangeEvent(e,t){this.hasEventListener("change")&&this._notifications&&this._notifications[this._notifications.length-1].changes.push({added:e,removed:t})}_dispatchChange(){if(this._timer&&(this._timer.remove(),this._timer=null),!this._notifications)return;const e=this._notifications;this._notifications=null;for(const t of e){const e=t.changes;E.clear(),M.clear(),O.clear();for(const{added:t,removed:r}of e){if(t)if(0===O.size&&0===M.size)for(const e of t)E.add(e);else for(const e of t)M.has(e)?(O.add(e),M.delete(e)):O.has(e)||E.add(e);if(r)if(0===O.size&&0===E.size)for(const e of r)M.add(e);else for(const e of r)E.has(e)?E.delete(e):(O.delete(e),M.add(e))}const r=i.Z.acquire();E.forEach((e=>{r.push(e)}));const n=i.Z.acquire();M.forEach((e=>{n.push(e)}));const s=this._items,o=t.items,a=i.Z.acquire();if(O.forEach((e=>{o.indexOf(e)!==s.indexOf(e)&&a.push(e)})),t.listeners&&(r.length||n.length||a.length)){const e={target:this,added:r,removed:n,moved:a},s=t.listeners.length;for(let r=0;r<s;r++){const n=t.listeners[r];n.removed||n.callback.call(this,e)}}i.Z.release(r),i.Z.release(n),i.Z.release(a)}E.clear(),M.clear(),O.clear()}};q.ofType=e=>{if(!e)return n;if(S.has(e))return S.get(e);let t=null;if("function"==typeof e)t=e.prototype.declaredClass;else if(e.base)t=e.base.prototype.declaredClass;else for(const r in e.typeMap){const n=e.typeMap[r].prototype.declaredClass;t?t+=` | ${n}`:t=n}let r=class extends n{};return(0,s._)([(0,p.c)({Type:e,ensureType:"function"==typeof e?(0,d.se)(e):(0,d.N7)(e)})],r.prototype,"itemType",void 0),r=(0,s._)([(0,f.j)(`esri.core.Collection<${t}>`)],r),S.set(e,r),r},(0,s._)([(0,h.Cb)()],q.prototype,"length",void 0),(0,s._)([(0,h.Cb)()],q.prototype,"items",null),q=n=(0,s._)([(0,f.j)("esri.core.Collection")],q);const U=q},57435:(e,t,r)=>{r.d(t,{Z:()=>h});var n=r(43697),s=r(81049),i=r(3920),o=r(70586),a=(r(26258),r(87538)),l=r(5600),u=(r(67676),r(80442),r(75215),r(52011));let c=class extends((0,i.p)(s.Z)){constructor(e){super(e),this.getCollections=null}initialize(){this.handles.add((0,a.EH)((()=>this.refresh())))}destroy(){this.getCollections=null}refresh(){const e=(0,o.pC)(this.getCollections)?this.getCollections():null;if((0,o.Wi)(e))return void this.removeAll();let t=0;for(const r of e)(0,o.pC)(r)&&(t=this._processCollection(t,r));this.splice(t,this.length)}_createNewInstance(e){return new s.Z(e)}_processCollection(e,t){if(!t)return e;const r=this.itemFilterFunction?this.itemFilterFunction:e=>!!e;for(const n of t)if(n){if(r(n)){const t=this.indexOf(n,e);t>=0?t!==e&&this.reorder(n,e):this.add(n,e),++e}if(this.getChildrenFunction){const t=this.getChildrenFunction(n);if(Array.isArray(t))for(const r of t)e=this._processCollection(e,r);else e=this._processCollection(e,t)}}return e}};(0,n._)([(0,l.Cb)()],c.prototype,"getCollections",void 0),(0,n._)([(0,l.Cb)()],c.prototype,"getChildrenFunction",void 0),(0,n._)([(0,l.Cb)()],c.prototype,"itemFilterFunction",void 0),c=(0,n._)([(0,u.j)("esri.core.CollectionFlattener")],c);const h=c},32448:(e,t,r)=>{r.d(t,{Z:()=>l});var n=r(43697),s=r(15923),i=r(50758),o=r(52011);class a{constructor(){this._emitter=new a.EventEmitter(this)}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}}!function(e){class t{constructor(e=null){this.target=e,this._listenersMap=null}clear(){this._listenersMap&&this._listenersMap.clear(),this._listenersMap=null}emit(e,t){const r=this._listenersMap&&this._listenersMap.get(e);if(!r)return!1;const n=this.target||this;return[...r].forEach((e=>{e.call(n,t)})),r.length>0}on(e,t){if(Array.isArray(e)){const r=e.map((e=>this.on(e,t)));return(0,i.AL)(r)}if(e.indexOf(",")>-1)throw new TypeError("Evented.on() with a comma delimited string of event types is not supported");this._listenersMap||(this._listenersMap=new Map);const r=this._listenersMap.get(e)||[];return r.push(t),this._listenersMap.set(e,r),{remove:()=>{const r=this._listenersMap&&this._listenersMap.get(e)||[],n=r.indexOf(t);n>=0&&r.splice(n,1)}}}once(e,t){const r=this.on(e,(e=>{r.remove(),t.call(null,e)}));return r}hasEventListener(e){const t=this._listenersMap&&this._listenersMap.get(e);return null!=t&&t.length>0}}e.EventEmitter=t,e.EventedMixin=e=>{let r=class extends e{constructor(){super(...arguments),this._emitter=new t}destroy(){this._emitter.clear()}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}};return r=(0,n._)([(0,o.j)("esri.core.Evented")],r),r};let r=class extends s.Z{constructor(){super(...arguments),this._emitter=new a.EventEmitter(this)}destroy(){this._emitter.clear()}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}};r=(0,n._)([(0,o.j)("esri.core.Evented")],r),e.EventedAccessor=r}(a||(a={}));const l=a},3920:(e,t,r)=>{r.d(t,{r:()=>c,p:()=>u});var n=r(43697),s=r(15923),i=r(61247),o=r(5600),a=r(52011),l=r(89749);const u=e=>{let t=class extends e{destroy(){this.destroyed||(this.handles.destroy(),this.updatingHandles.destroy())}get handles(){return this._get("handles")||new i.Z}get updatingHandles(){return this._get("updatingHandles")||new l.t}};return(0,n._)([(0,o.Cb)({readOnly:!0})],t.prototype,"handles",null),(0,n._)([(0,o.Cb)({readOnly:!0})],t.prototype,"updatingHandles",null),t=(0,n._)([(0,a.j)("esri.core.HandleOwner")],t),t};let c=class extends(u(s.Z)){};c=(0,n._)([(0,a.j)("esri.core.HandleOwner")],c)},61247:(e,t,r)=>{r.d(t,{Z:()=>c});var n=r(43697),s=r(15923),i=r(81049),o=r(70586),a=r(5600),l=r(52011);let u=class extends s.Z{constructor(e){super(e),this._groups=new Map}destroy(){this.removeAll()}get size(){let e=0;return this._groups.forEach((t=>{e+=t.length})),e}add(e,t){if(!this._isHandle(e)&&!Array.isArray(e)&&!i.Z.isCollection(e))return this;const r=this._getOrCreateGroup(t);return Array.isArray(e)||i.Z.isCollection(e)?e.forEach((e=>this._isHandle(e)&&r.push(e))):r.push(e),this.notifyChange("size"),this}forEach(e,t){if("function"==typeof e)this._groups.forEach((t=>t.forEach(e)));else{const r=this._getGroup(e);r&&t&&r.forEach(t)}}has(e){return this._groups.has(this._ensureGroupKey(e))}remove(e){if(Array.isArray(e)||i.Z.isCollection(e))return e.forEach(this.remove,this),this;if(!this.has(e))return this;const t=this._getGroup(e);for(let e=0;e<t.length;e++)t[e].remove();return this._deleteGroup(e),this.notifyChange("size"),this}removeAll(){return this._groups.forEach((e=>{for(let t=0;t<e.length;t++)e[t].remove()})),this._groups.clear(),this.notifyChange("size"),this}_isHandle(e){return e&&!!e.remove}_getOrCreateGroup(e){if(this.has(e))return this._getGroup(e);const t=[];return this._groups.set(this._ensureGroupKey(e),t),t}_getGroup(e){return(0,o.j0)(this._groups.get(this._ensureGroupKey(e)))}_deleteGroup(e){return this._groups.delete(this._ensureGroupKey(e))}_ensureGroupKey(e){return e||"_default_"}};(0,n._)([(0,a.Cb)({readOnly:!0})],u.prototype,"size",null),u=(0,n._)([(0,l.j)("esri.core.Handles")],u);const c=u},16453:(e,t,r)=>{r.d(t,{R:()=>b,w:()=>v});var n=r(43697),s=r(15923),i=r(70586),o=r(22974),a=r(31263);class l{constructor(){this._propertyOriginMap=new Map,this._originStores=new Array(a.kk),this._values=new Map}clone(e){const t=new l,r=this._originStores[0];r&&r.forEach(((e,r)=>{t.set(r,(0,o.d9)(e),0)}));for(let r=2;r<a.kk;r++){const n=this._originStores[r];n&&n.forEach(((n,s)=>{e&&e.has(s)||t.set(s,(0,o.d9)(n),r)}))}return t}get(e,t){const r=void 0===t?this._values:this._originStores[t];return r?r.get(e):void 0}keys(e){const t=null==e?this._values:this._originStores[e];return t?[...t.keys()]:[]}set(e,t,r=6){let n=this._originStores[r];if(n||(n=new Map,this._originStores[r]=n),n.set(e,t),!this._values.has(e)||(0,i.j0)(this._propertyOriginMap.get(e))<=r){const n=this._values.get(e);return this._values.set(e,t),this._propertyOriginMap.set(e,r),n!==t}return!1}delete(e,t=6){const r=this._originStores[t];if(!r)return;const n=r.get(e);if(r.delete(e),this._values.has(e)&&this._propertyOriginMap.get(e)===t){this._values.delete(e);for(let r=t-1;r>=0;r--){const t=this._originStores[r];if(t&&t.has(e)){this._values.set(e,t.get(e)),this._propertyOriginMap.set(e,r);break}}}return n}has(e,t){const r=void 0===t?this._values:this._originStores[t];return!!r&&r.has(e)}revert(e,t){for(;t>0&&!this.has(e,t);)--t;const r=this._originStores[t],n=r&&r.get(e),s=this._values.get(e);return this._values.set(e,n),this._propertyOriginMap.set(e,t),s!==n}originOf(e){return this._propertyOriginMap.get(e)||0}forEach(e){this._values.forEach(e)}}var u=r(50549),c=r(1153),h=r(52011);const d=e=>{let t=class extends e{constructor(...e){super(...e);const t=(0,i.j0)((0,c.vw)(this)),r=t.metadatas,n=t.store,s=new l;t.store=s,n.keys().forEach((e=>{s.set(e,n.get(e),0)})),Object.keys(r).forEach((e=>{t.internalGet(e)&&s.set(e,t.internalGet(e),0)}))}read(e,t){(0,u.ij)(this,e,t)}getAtOrigin(e,t){const r=p(this),n=(0,a.M9)(t);if("string"==typeof e)return r.get(e,n);const s={};return e.forEach((e=>{s[e]=r.get(e,n)})),s}originOf(e){return(0,a.x3)(this.originIdOf(e))}originIdOf(e){return p(this).originOf(e)}revert(e,t){const r=p(this),n=(0,a.M9)(t),s=(0,c.vw)(this);let i;i="string"==typeof e?"*"===e?r.keys(n):[e]:e,i.forEach((e=>{s.invalidate(e),r.revert(e,n),s.commit(e)}))}};return t=(0,n._)([(0,h.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],t),t};function p(e){return(0,c.vw)(e).store}let f=class extends(d(s.Z)){};f=(0,n._)([(0,h.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],f);var m=r(76169);const y=e=>{let t=class extends e{constructor(...e){super(...e)}clear(e,t="user"){return g(this).delete(e,(0,a.M9)(t))}write(e={},t){return(0,m.cW)(this,e=e||{},t),e}setAtOrigin(e,t,r){(0,c.vw)(this).setAtOrigin(e,t,(0,a.M9)(r))}removeOrigin(e){const t=g(this),r=(0,a.M9)(e),n=t.keys(r);for(const e of n)t.originOf(e)===r&&t.set(e,t.get(e,r),6)}updateOrigin(e,t){const r=g(this),n=(0,a.M9)(t),s=this.get(e);for(let t=n+1;t<a.kk;++t)r.delete(e,t);r.set(e,s,n)}toJSON(e){return this.write({},e)}};return t=(0,n._)([(0,h.j)("esri.core.WriteableMultiOriginJSONSupport")],t),t.prototype.toJSON.isDefaultToJSON=!0,t};function g(e){return(0,c.vw)(e).store}const b=e=>{let t=class extends(y(d(e))){constructor(...e){super(...e)}};return t=(0,n._)([(0,h.j)("esri.core.MultiOriginJSONSupport")],t),t};let v=class extends(b(s.Z)){};v=(0,n._)([(0,h.j)("esri.core.MultiOriginJSONSupport")],v)},52421:(e,t,r)=>{function n(e){return(t,r)=>{t[r]=e}}r.d(t,{c:()=>n})},91460:(e,t,r)=>{function n(e){return e&&("function"==typeof e.on||"function"==typeof e.addEventListener)}function s(e,t,r){if(!n(e))throw new TypeError("target is not a Evented or EventTarget object");if("on"in e)return e.on(t,r);if(Array.isArray(t)){const n=t.slice();for(const t of n)e.addEventListener(t,r);return{remove(){for(const t of n)e.removeEventListener(t,r)}}}return e.addEventListener(t,r),{remove(){e.removeEventListener(t,r)}}}function i(e,t,r){if(!n(e))throw new TypeError("target is not a Evented or EventTarget object");if("once"in e)return e.once(t,r);const i=s(e,t,(t=>{i.remove(),r.call(e,t)}));return{remove(){i.remove()}}}r.d(t,{vT:()=>n,on:()=>s,IH:()=>i})},95330:(e,t,r)=>{r.d(t,{e4:()=>O,$6:()=>l,Ue:()=>u,zE:()=>c,dD:()=>w,hh:()=>T,vr:()=>N,Ds:()=>U,as:()=>x,WW:()=>C,R8:()=>_,D_:()=>v,Hc:()=>p,tI:()=>q,y8:()=>S,fu:()=>y,$F:()=>g,d1:()=>E,DB:()=>M,r9:()=>f,k_:()=>h,H9:()=>m,gx:()=>I,Hl:()=>b});const n=(s=r(16358).Z,{setTimeout:(e,t)=>{const r=s.setTimeout(e,t);return{remove:()=>s.clearTimeout(r)}}});var s,i=r(20102),o=r(91460),a=(r(92604),r(70586));function l(e){return Promise.all(e)}function u(e){return new Promise(((t,r)=>{try{e(t,r)}catch(e){Promise.resolve().then((()=>r(e)))}}))}function c(e="Aborted"){return new i.Z("AbortError",e)}function h(e,t="Aborted"){if(p(e))throw c(t)}function d(e){return(0,a.pC)(e)?"aborted"in e?e:e.signal:e}function p(e){const t=d(e);return(0,a.pC)(t)&&t.aborted}function f(e){if(v(e))throw e}function m(e){if(!v(e))throw e}function y(e,t){const r=d(e);if(!(0,a.Wi)(r)){if(!r.aborted)return(0,o.IH)(r,"abort",(()=>t()));t()}}function g(e,t){const r=d(e);if(!(0,a.Wi)(r))return h(r),(0,o.IH)(r,"abort",(()=>t(c())))}function b(e,t){const r=d(t);return(0,a.Wi)(r)?e:new Promise(((r,n)=>{let s=y(t,(()=>n(c())));const i=()=>s=(0,a.hw)(s);e.then(i,i),e.then(r,n)}))}function v(e){return e&&"AbortError"===e.name}function _(e){return e.catch((e=>{if(!v(e))throw e}))}function w(){let e=null;const t=new Promise(((t,r)=>{e={promise:void 0,resolve:t,reject:r}}));return e.promise=t,e}function x(e){if(!e)return;if("function"!=typeof e.forEach){const t=Object.keys(e);return x(t.map((t=>e[t]))).then((e=>{const r={};return t.forEach(((t,n)=>r[t]=e[n])),r}))}const t=e;return u((e=>{const r=[];let n=t.length;0===n&&e(r),t.forEach((t=>{const s={promise:t||Promise.resolve(t)};r.push(s),s.promise.then((e=>{s.value=e})).catch((e=>{s.error=e})).then((()=>{--n,0===n&&e(r)}))}))}))}function C(e){return x(e).then((e=>e.filter((e=>!!e.value)).map((e=>e.value))))}function E(e){return Promise.reject(e)}function M(e){return Promise.resolve(e)}function O(e,t,r){const n=new AbortController;return y(r,(()=>n.abort())),new Promise(((r,s)=>{let i=setTimeout((()=>{i=0,r(t)}),e);y(n,(()=>{i&&(clearTimeout(i),s(c()))}))}))}function S(e){return e&&"function"==typeof e.then}function I(e){return q(e)?e:Promise.resolve(e)}function q(e){return e&&"object"==typeof e&&"then"in e&&"function"==typeof e.then}function U(e,t=-1){let r,n,s,i,o=null;const l=(...u)=>{if(r){n=u,i&&i.reject(c()),i=w();const e=(0,a.j0)(i.promise);if(o){const e=o;o=null,e.abort()}return e}if(s=i||w(),i=null,t>0){const n=new AbortController;r=I(e(...u,n.signal));const s=r;O(t).then((()=>{r===s&&(i?n.abort():o=n)}))}else r=1,r=I(e(...u));const h=()=>{const e=n;n=s=r=o=null,null!=e&&l(...e)},d=r,p=s;return d.then(h,h),d.then(p.resolve,p.reject),(0,a.j0)(p.promise)};return l}function T(){let e,t;const r=new Promise(((r,n)=>{e=r,t=n})),s=t=>{e(t)};return s.resolve=t=>e(t),s.reject=e=>t(e),s.timeout=(e,t)=>n.setTimeout((()=>s.reject(t)),e),s.promise=r,s}function N(e){let t=new AbortController;const r=e(t.signal);let n={promise:r,finished:!1,abort:()=>{t&&(t.abort(),t=null)}};const s=()=>{n&&(n.finished=!0,n=null),t=null};return r.then(s,s),n}},17445:(e,t,r)=>{r.d(t,{Ym:()=>i}),r(91460);var n=r(70586),s=r(26258);function i(e,t,r={}){return function(e,t,r={},i){let o=null;const a=r.once?(e,r)=>{i(e)&&((0,n.hw)(o),t(e,r))}:(e,r)=>{i(e)&&t(e,r)};if(o=(0,s.aQ)(e,a,r.sync,r.equals),r.initial){const t=e();a(t,t)}return o}(e,t,r,o)}function o(e){return!0}r(87538)},35463:(e,t,r)=>{r.d(t,{rJ:()=>a,Nm:()=>i,JE:()=>o}),r(80442);const n={milliseconds:1,seconds:1e3,minutes:6e4,hours:36e5,days:864e5,weeks:6048e5,months:26784e5,years:31536e6,decades:31536e7,centuries:31536e8},s={milliseconds:{getter:"getMilliseconds",setter:"setMilliseconds",multiplier:1},seconds:{getter:"getSeconds",setter:"setSeconds",multiplier:1},minutes:{getter:"getMinutes",setter:"setMinutes",multiplier:1},hours:{getter:"getHours",setter:"setHours",multiplier:1},days:{getter:"getDate",setter:"setDate",multiplier:1},weeks:{getter:"getDate",setter:"setDate",multiplier:7},months:{getter:"getMonth",setter:"setMonth",multiplier:1},years:{getter:"getFullYear",setter:"setFullYear",multiplier:1},decades:{getter:"getFullYear",setter:"setFullYear",multiplier:10},centuries:{getter:"getFullYear",setter:"setFullYear",multiplier:100}};function i(e,t,r){const n=new Date(e.getTime());if(t&&r){const e=s[r],{getter:i,setter:o,multiplier:a}=e;n[o](n[i]()+t*a)}return n}function o(e,t){switch(t){case"milliseconds":return new Date(e.getTime());case"seconds":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds());case"minutes":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes());case"hours":return new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours());case"days":return new Date(e.getFullYear(),e.getMonth(),e.getDate());case"weeks":return new Date(e.getFullYear(),e.getMonth(),e.getDate()-e.getDay());case"months":return new Date(e.getFullYear(),e.getMonth(),1);case"years":return new Date(e.getFullYear(),0,1);case"decades":return new Date(e.getFullYear()-e.getFullYear()%10,0,1);case"centuries":return new Date(e.getFullYear()-e.getFullYear()%100,0,1);default:return new Date}}function a(e,t,r){return 0===e?0:e*n[t]/n[r]}},67900:(e,t,r)=>{r.d(t,{gV:()=>L,En:()=>C,Z7:()=>q,c9:()=>I,_R:()=>O,qE:()=>N,cM:()=>S,hd:()=>c,ty:()=>E,Jo:()=>j,$C:()=>M}),r(80442);var n=r(35454),s=r(70586),i=r(24678),o=r(82971),a=r(68441),l=r(8744),u=r(58116);const c=39.37,h=a.sv.radius*Math.PI/200,d=/UNIT\[([^\]]+)\]\]$/i,p=u.Z,f=/UNIT\[([^\]]+)\]/i,m=new Set([4261,4305,4807,4810,4811,4812,4816,4819,4821,4901,4902,37225,104139,104140]),y=(0,n.wY)()({meter:"meters",foot:"feet",foot_us:"us-feet",foot_clarke:"clarke-feet",yard_clarke:"clarke-yards",link_clarke:"clarke-links",yard_sears:"sears-yards",foot_sears:"sears-feet",chain_sears:"sears-chains",chain_benoit_1895_b:"benoit-1895-b-chains",yard_indian:"indian-yards",yard_indian_1937:"indian-1937-yards",foot_gold_coast:"gold-coast-feet",chain_sears_1922_truncated:"sears-1922-truncated-chains","50_kilometers":"50-kilometers","150_kilometers":"150-kilometers"}),g=e=>e*e,b=e=>e*e*e,v={length:{baseUnit:"meters",units:{millimeters:{inBaseUnits:.001},centimeters:{inBaseUnits:.01},decimeters:{inBaseUnits:.1},meters:{inBaseUnits:1},kilometers:{inBaseUnits:1e3},inches:{inBaseUnits:.0254},feet:{inBaseUnits:.3048},yards:{inBaseUnits:.9144},miles:{inBaseUnits:1609.344},"nautical-miles":{inBaseUnits:1852},"us-feet":{inBaseUnits:1200/3937}}},area:{baseUnit:"square-meters",units:{"square-millimeters":{inBaseUnits:g(.001)},"square-centimeters":{inBaseUnits:g(.01)},"square-decimeters":{inBaseUnits:g(.1)},"square-meters":{inBaseUnits:1},"square-kilometers":{inBaseUnits:g(1e3)},"square-inches":{inBaseUnits:g(.0254)},"square-feet":{inBaseUnits:g(.3048)},"square-yards":{inBaseUnits:g(.9144)},"square-miles":{inBaseUnits:g(1609.344)},"square-us-feet":{inBaseUnits:g(1200/3937)},acres:{inBaseUnits:.0015625*g(1609.344)},ares:{inBaseUnits:100},hectares:{inBaseUnits:1e4}}},volume:{baseUnit:"liters",units:{liters:{inBaseUnits:1},"cubic-millimeters":{inBaseUnits:1e3*b(.001)},"cubic-centimeters":{inBaseUnits:1e3*b(.01)},"cubic-decimeters":{inBaseUnits:1e3*b(.1)},"cubic-meters":{inBaseUnits:1e3},"cubic-kilometers":{inBaseUnits:1e3*b(1e3)},"cubic-inches":{inBaseUnits:1e3*b(.0254)},"cubic-feet":{inBaseUnits:1e3*b(.3048)},"cubic-yards":{inBaseUnits:1e3*b(.9144)},"cubic-miles":{inBaseUnits:1e3*b(1609.344)}}},angle:{baseUnit:"radians",units:{radians:{inBaseUnits:1},degrees:{inBaseUnits:Math.PI/180}}}},_=function(){const e={};for(const t in v)for(const r in v[t].units)e[r]=t;return e}();function w(e){const t=_[e];if(t)return t;throw new Error("unknown measure")}function x(e,t=null){return t=t||w(e),v[t].baseUnit===e}function C(e,t,r){if(t===r)return e;const n=w(t);if(n!==w(r))throw new Error("incompatible units");const s=x(t,n)?e:function(e,t,r){return e*v[r].units[t].inBaseUnits}(e,t,n);return x(r,n)?s:function(e,t,r){return e/v[r].units[t].inBaseUnits}(s,r,n)}function E(e,t,r){return C(e,t,"meters")/(r*Math.PI/180)}function M(e){return y.fromJSON(e.toLowerCase())||null}function O(e){if(e&&"object"==typeof e&&!(0,l.N$)(e))return 1;const t=I(e);return t>1e5?1:t}function S(e){return I(e)>=(e instanceof o.Z?(0,i.Iu)(e).metersPerDegree:1e5)?"meters":N(e)}function I(e,t=a.sv.metersPerDegree){return q(e,!0)||t}function q(e,t=!1){let r,n,s=null;if(null!=e&&("object"==typeof e?(r=e.wkid,n=e.wkt):"number"==typeof e?r=e:"string"==typeof e&&(n=e)),r){if((0,l.o$)(r))return a.yr.metersPerDegree;if((0,l.ME)(r))return a.Z1.metersPerDegree;s=p.values[p[r]],!s&&t&&m.has(r)&&(s=h)}else n&&(P(n)?s=U(d.exec(n),s):A(n)&&(s=U(f.exec(n),s)));return s}function U(e,t){return e&&e[1]?T(e[1]):t}function T(e){return parseFloat(e.split(",")[1])}function N(e){let t,r,n=null;if(null!=e&&("object"==typeof e?(t=e.wkid,r=e.wkt):"number"==typeof e?t=e:"string"==typeof e&&(r=e)),t)n=p.units[p[t]];else if(r){const e=P(r)?d:A(r)?f:null;if(e){const t=e.exec(r);t&&t[1]&&(n=function(e){const t=/[\\"\\']{1}([^\\"\\']+)/.exec(e);let r=t&&t[1];if(!r||-1===p.units.indexOf(r)){const t=T(e);r=null;const n=p.values;for(let e=0;e<n.length;++e)if(Math.abs(t-n[e])<1e-7){r=p.units[e];break}}return r}(t[1]))}}return(0,s.pC)(n)?M(n):null}function A(e){return/^GEOCCS/i.test(e)}function P(e){return/^PROJCS/i.test(e)}const k={esriAcres:"acres",esriAres:"ares",esriHectares:"hectares",esriSquareCentimeters:"square-centimeters",esriSquareDecimeters:"square-decimeters",esriSquareFeet:"square-feet",esriSquareInches:"square-inches",esriSquareKilometers:"square-kilometers",esriSquareMeters:"square-meters",esriSquareMiles:"square-miles",esriSquareMillimeters:"square-millimeters",esriSquareUsFeet:"square-us-feet",esriSquareYards:"square-yards"},R={esriCentimeters:"centimeters",esriDecimeters:"decimeters",esriFeet:"feet",esriInches:"inches",esriKilometers:"kilometers",esriMeters:"meters",esriMiles:"miles",esriMillimeters:"millimeters",esriNauticalMiles:"nautical-miles",esriYards:"yards"},L=(0,n.wY)()(k),j=(0,n.wY)()(R);(0,n.wY)()({...k,...R})},17452:(e,t,r)=>{r.d(t,{R9:()=>b,qg:()=>S,tD:()=>T,ZN:()=>ue,fl:()=>ce,AX:()=>w,Gd:()=>v,Ie:()=>oe,sJ:()=>V,AH:()=>Y,vt:()=>se,oh:()=>k,P$:()=>$,Ml:()=>he,ed:()=>N,b7:()=>O,D6:()=>R,tm:()=>A,YP:()=>G,jc:()=>H,HK:()=>W,$U:()=>Q,oC:()=>X,kl:()=>L,v_:()=>B,hF:()=>Z,_l:()=>z,PF:()=>F,Fv:()=>D,B7:()=>M,u0:()=>C,Yd:()=>ne,Hu:()=>le,Qj:()=>ie,hO:()=>ee,mN:()=>x});var n=r(68773),s=r(20102),i=(r(16358),r(92604)),o=r(70586);const a=i.Z.getLogger("esri.core.urlUtils"),l=n.Z.request,u="esri/config: esriConfig.request.proxyUrl is not set.",c=/^\s*[a-z][a-z0-9-+.]*:(?![0-9])/i,h=/^\s*http:/i,d=/^\s*https:/i,p=/^\s*file:/i,f=/:\d+$/,m=/^https?:\/\/[^/]+\.arcgis.com\/sharing(\/|$)/i,y=new RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$"),g=new RegExp("^((([^\\[:]+):)?([^@]+)@)?(\\[([^\\]]+)\\]|([^\\[:]*))(:([0-9]+))?$");class b{constructor(e=""){this.uri=e,this.scheme=null,this.authority=null,this.path=null,this.query=null,this.fragment=null,this.user=null,this.password=null,this.host=null,this.port=null;let t=(0,o.j0)(this.uri.match(y));this.scheme=t[2]||(t[1]?"":null),this.authority=t[4]||(t[3]?"":null),this.path=t[5],this.query=t[7]||(t[6]?"":null),this.fragment=t[9]||(t[8]?"":null),null!=this.authority&&(t=(0,o.j0)(this.authority.match(g)),this.user=t[3]||null,this.password=t[4]||null,this.host=t[6]||t[7],this.port=t[9]||null)}toString(){return this.uri}}const v=new b(n.Z.applicationUrl),_={},w=(()=>{const e=(0,o.j0)(v.path),t=e.substring(0,e.lastIndexOf(e.split("/")[e.split("/").length-1]));return`${v.scheme}://${v.host}${null!=v.port?`:${v.port}`:""}${t}`})();function x(e){const t={path:null,query:null},r=new b(e),n=e.indexOf("?");return null===r.query?t.path=e:(t.path=e.substring(0,n),t.query=C(r.query)),r.fragment&&(t.hash=r.fragment,null===r.query&&(t.path=t.path.substring(0,t.path.length-(r.fragment.length+1)))),t}function C(e){const t=e.split("&"),r={};for(const e of t){if(!e)continue;const t=e.indexOf("=");let n,s;t<0?(n=decodeURIComponent(e),s=""):(n=decodeURIComponent(e.slice(0,t)),s=decodeURIComponent(e.slice(t+1)));let i=r[n];"string"==typeof i&&(i=r[n]=[i]),Array.isArray(i)?i.push(s):r[n]=s}return r}function E(e){return e&&"object"==typeof e&&"toJSON"in e&&"function"==typeof e.toJSON}function M(e,t){return e?t&&"function"==typeof t?Object.keys(e).map((r=>encodeURIComponent(r)+"="+encodeURIComponent(t(r,e[r])))).join("&"):Object.keys(e).map((r=>{const n=e[r];if(null==n)return"";const s=encodeURIComponent(r)+"=",i=t&&t[r];return i?s+encodeURIComponent(i(n)):Array.isArray(n)?n.map((e=>E(e)?s+encodeURIComponent(JSON.stringify(e)):s+encodeURIComponent(e))).join("&"):E(n)?s+encodeURIComponent(JSON.stringify(n)):s+encodeURIComponent(n)})).filter((e=>e)).join("&"):""}function O(e=!1){let t,r=l.proxyUrl;if("string"==typeof e){t=Q(e);const n=N(e);n&&(r=n.proxyUrl)}else t=!!e;if(!r)throw a.warn(u),new s.Z("urlutils:proxy-not-set",u);return t&&te()&&(r=ee(r)),x(r)}function S(e){const t=N(e);let r,n;if(t){const e=q(t.proxyUrl);r=e.path,n=e.query?C(e.query):null}if(r){const t=x(e);e=r+"?"+t.path;const s=M({...n,...t.query});s&&(e=`${e}?${s}`)}return e}const I={path:"",query:""};function q(e){const t=e.indexOf("?");return-1!==t?(I.path=e.slice(0,t),I.query=e.slice(t+1)):(I.path=e,I.query=null),I}function U(e){return(e=re(e=function(e){return e&&"/"===e[e.length-1]?e:`${e}/`}(e=q(e).path),!0)).toLowerCase()}function T(e){const t={proxyUrl:e.proxyUrl,urlPrefix:U(e.urlPrefix)},r=l.proxyRules,n=t.urlPrefix;let s=r.length;for(let e=0;e<r.length;e++){const t=r[e].urlPrefix;if(0===n.indexOf(t)){if(n.length===t.length)return-1;s=e;break}0===t.indexOf(n)&&(s=e+1)}return r.splice(s,0,t),s}function N(e){const t=l.proxyRules,r=U(e);for(let e=0;e<t.length;e++)if(0===r.indexOf(t[e].urlPrefix))return t[e]}function A(e,t){return e=P(e),t=P(t),re(e)===re(t)}function P(e){const t=(e=D(e)).indexOf("/sharing");return t>0?e.substring(0,t):e.replace(/\/+$/,"")}function k(e){const t=t=>null==t||t instanceof RegExp&&t.test(e)||"string"==typeof t&&e.startsWith(t),r=l.interceptors;if(r)for(const e of r)if(Array.isArray(e.urls)){if(e.urls.some(t))return e}else if(t(e.urls))return e;return null}function R(e,t,r=!1){const n=ae(e),s=ae(t);return!(!r&&n.scheme!==s.scheme)&&null!=n.host&&null!=s.host&&n.host.toLowerCase()===s.host.toLowerCase()&&n.port===s.port}function L(e){if("string"==typeof e){if(!G(e))return!0;e=ae(e)}if(R(e,v))return!0;const t=l.trustedServers||[];for(let r=0;r<t.length;r++){const n=j(t[r]);for(let t=0;t<n.length;t++)if(R(e,n[t]))return!0}return!1}function j(e){return _[e]||(K(e)||X(e)?_[e]=[new b(Z(e))]:_[e]=[new b(`http://${e}`),new b(`https://${e}`)]),_[e]}function Z(e,t=w,r){return X(e)?r&&r.preserveProtocolRelative?e:"http"===v.scheme&&v.authority===$(e).slice(2)?`http:${e}`:`https:${e}`:K(e)?e:(0,o.j0)(B("/"===e[0]?function(e){const t=e.indexOf("//"),r=e.indexOf("/",t+2);return-1===r?e:e.slice(0,r)}(t):t,e))}function F(e,t=w,r){if(!G(e))return e;const n=D(e),s=n.toLowerCase(),i=D(t).toLowerCase().replace(/\/+$/,""),o=r?D(r).toLowerCase().replace(/\/+$/,""):null;if(o&&0!==i.indexOf(o))return e;const a=(e,t,r)=>-1===(r=e.indexOf(t,r))?e.length:r;let l=a(s,"/",s.indexOf("//")+2),u=-1;for(;s.slice(0,l+1)===i.slice(0,l)+"/"&&(u=l+1,l!==s.length);)l=a(s,"/",l+1);if(-1===u)return e;if(o&&u<o.length)return e;e=n.slice(u);const c=i.slice(u-1).replace(/[^/]+/g,"").length;if(c>0)for(let t=0;t<c;t++)e=`../${e}`;else e=`./${e}`;return e}function D(e){return function(e){const t=l.httpsDomains;if(!function(e){return h.test(e)||"http"===v.scheme&&X(e)}(e))return e;const r=e.indexOf("/",7);let n;if(n=-1===r?e:e.slice(0,r),n=n.toLowerCase().slice(7),f.test(n)){if(!n.endsWith(":80"))return e;n=n.slice(0,-3),e=e.replace(":80","")}return"http"===v.scheme&&n===v.authority&&!m.test(e)||(te()&&n===v.authority||t&&t.some((e=>n===e||n.endsWith(`.${e}`)))||te()&&!N(e))&&(e=ee(e)),e}(e=function(e){return e.replace(/^(https?:\/\/)(arcgis\.com)/i,"$1www.$2")}(e=function(e){if(/^https?:\/\//i.test(e)){const t=q(e);e=(e=t.path.replace(/\/{2,}/g,"/")).replace("/","//"),t.query&&(e+=`?${t.query}`)}return e}(e=Z(e=e.trim()))))}function B(...e){const t=e.filter(o.pC);if(!t||!t.length)return;const r=[];if(G(t[0])){const e=t[0],n=e.indexOf("//");-1!==n&&(r.push(e.slice(0,n+1)),function(e){return p.test(e)}(t[0])&&(r[0]+="/"),t[0]=e.slice(n+2))}else"/"===t[0][0]&&r.push("");const n=t.reduce(((e,t)=>t?e.concat(t.split("/")):e),[]);for(let e=0;e<n.length;e++){const t=n[e];".."===t&&r.length>0&&".."!==r[r.length-1]?r.pop():(!t&&e===n.length-1||t&&("."!==t||0===r.length))&&r.push(t)}return r.join("/")}function $(e,t=!1){if(H(e)||W(e))return null;let r=e.indexOf("://");if(-1===r&&X(e))r=2;else{if(-1===r)return null;r+=3}const n=e.indexOf("/",r);return-1!==n&&(e=e.slice(0,n)),t&&(e=re(e,!0)),e}function G(e){return X(e)||K(e)}function H(e){return null!=e&&"blob:"===e.slice(0,5)}function W(e){return"data:"===e.slice(0,5)}function Y(e){const t=V(e);if(!t||!t.isBase64)return null;const r=atob(t.data),n=new Uint8Array(r.length);for(let e=0;e<r.length;e++)n[e]=r.charCodeAt(e);return n.buffer}const J=/^data:(.*?)(;base64)?,(.*)$/;function V(e){const t=e.match(J);if(!t)return null;const[,r,n,s]=t;return{mediaType:r,isBase64:!!n,data:s}}function z(e){return e.isBase64?`data:${e.mediaType};base64,${e.data}`:`data:${e.mediaType},${e.data}`}function X(e){return null!=e&&void 0!==e&&"/"===e[0]&&"/"===e[1]}function K(e){return c.test(e)}function Q(e){return d.test(e)||"https"===v.scheme&&X(e)}function ee(e){return X(e)?`https:${e}`:e.replace(h,"https:")}function te(){return"https"===v.scheme}function re(e,t=!1){return X(e)?e.slice(2):(e=e.replace(c,""),t&&e.length>1&&"/"===e[0]&&"/"===e[1]&&(e=e.slice(2)),e)}function ne(e){let t=0;if(G(e)){const r=e.indexOf("//");-1!==r&&(t=r+2)}const r=e.lastIndexOf("/");return r<t?e:e.slice(0,r+1)}function se(e,t){if(!e)return"";const r=x(e).path.replace(/\/+$/,""),n=r.substring(r.lastIndexOf("/")+1);if(null==t||!t.length)return n;const s=new RegExp(`.(${t.join("|")})$`,"ig");return n.replace(s,"")}function ie(e){return e.replace(/\/+$/,"")}function oe(e,t,r){if(!(t&&r&&e&&G(e)))return e;const n=e.indexOf("//"),s=e.indexOf("/",n+2),i=e.indexOf(":",n+2),o=Math.min(s<0?e.length:s,i<0?e.length:i);return e.slice(n+2,o).toLowerCase()!==t.toLowerCase()?e:`${e.slice(0,n+2)}${r}${e.slice(o)}`}function ae(e){return"string"==typeof e?new b(Z(e)):(e.scheme||(e.scheme=v.scheme),e)}function le(e,t){const r=x(e),n=Object.keys(r.query||{});return n.length>0&&t&&t.warn("removeQueryParameters()",`Url query parameters are not supported, the following parameters have been removed: ${n.join(", ")}.`),r.path}function ue(e,t,r){const n=x(e),s=n.query||{};return s[t]=String(r),`${n.path}?${M(s)}`}function ce(e,t){const r=x(e),n=r.query||{};for(const e in t)n[e]=t[e];const s=M(n);return s?`${r.path}?${s}`:r.path}function he(e){if((0,o.Wi)(e))return null;const t=e.match(de);return t?t[1]:null}const de=/.*?\.([^\/]*)$/},43050:(e,t,r)=>{r.d(t,{S1:()=>o,on:()=>h,OY:()=>c,cm:()=>l,N1:()=>a,LR:()=>u,tH:()=>d});var n=r(91460),s=(r(22974),r(95330));const i=/\?(\.|$)/g;function o(e,t,r,n){const s=Array.isArray(t)?t:t.indexOf(",")>-1?t.split(","):[t],o=function(e,t,r,n){return e.watch(t,r,n)}(e,t,r,n);for(const t of s){const n=t.trim().replace(i,"$1"),s=e.get(n);r.call(e,s,s,n,e)}return o}function a(e,t,r,n){return d(e,t,p,r,n)}function l(e,t,r,n){return d(e,t,f,r,n)}function u(e,t,r,n){return d(e,t,m,r,n)}function c(e,t,r,n){return d(e,t,y,r,n)}function h(e,t,r,s,i,a,l){const u={};function c(t){const n=u[t];n&&(a&&a(n.target,t,e,r),n.handle.remove(),delete u[t])}const h=o(e,t,((t,o,a)=>{c(a),(0,n.vT)(t)&&(u[a]={handle:(0,n.on)(t,r,s),target:t},i&&i(t,a,e,r))}),l);return{remove(){h.remove();for(const e in u)c(e)}}}function d(e,t,r,n,i){const o="function"==typeof n?n:null,a="object"==typeof n?n:null;"boolean"==typeof n&&(i=n);let l,u=!1;function c(){l&&(l.remove(),l=null)}const h=(0,s.dD)();(0,s.fu)(a,(()=>{c(),h.reject((0,s.zE)())}));const d={then:h.promise.then.bind(h.promise),catch:h.promise.catch.bind(h.promise),remove:c};return Object.freeze(d),l=function(e,t,r,n,s){const i=e.watch(t,((t,s,i,o)=>{r&&!r(t)||null==n||n.call(e,t,s,i,o)}),s);if(Array.isArray(t))for(const s of t){const i=e.get(s);r&&r(i)&&(null==n||n.call(e,i,i,t,e))}else{const s=e.get(t);r&&r(s)&&(null==n||n.call(e,s,s,t,e))}return i}(e,t,r,((t,r,n,s)=>{u=!0,c(),o&&o.call(e,t,r,n,s),h.resolve({value:t,oldValue:r,propertyName:n,target:s})}),i),u&&c(),d}function p(e){return!!e}function f(e){return!e}function m(e){return!0===e}function y(e){return!1===e}},66577:(e,t,r)=>{r.d(t,{qM:()=>c});var n=r(75215),s=r(6570),i=r(9361),o=r(65091),a=r(13473),l=r(17332),u=r(58901);r(82971),r(86973),r(33955);const c={base:i.Z,key:"type",typeMap:{extent:s.Z,multipoint:o.Z,point:a.Z,polyline:u.Z,polygon:l.Z}};(0,n.N7)(c)},24678:(e,t,r)=>{r.d(t,{GG:()=>a,HQ:()=>l,VY:()=>u,wY:()=>c,Iu:()=>p,e8:()=>f,rS:()=>d,N_:()=>h});var n=r(82971),s=r(68441),i=r(8744);function o(e){return new n.Z({wkt:`GEOCCS["Spherical geocentric",\n    DATUM["Not specified",\n      SPHEROID["Sphere",${e.radius},0]],\n    PRIMEM["Greenwich",0.0,\n      AUTHORITY["EPSG","8901"]],\n    UNIT["m",1.0],\n    AXIS["Geocentric X",OTHER],\n    AXIS["Geocentric Y",EAST],\n    AXIS["Geocentric Z",NORTH]\n  ]`})}const a=o(s.sv),l=o(s.yr),u=o(s.Z1),c=new n.Z({wkt:`GEOCCS["WGS 84",\n  DATUM["WGS_1984",\n    SPHEROID["WGS 84",${s.sv.radius},298.257223563,\n      AUTHORITY["EPSG","7030"]],\n    AUTHORITY["EPSG","6326"]],\n  PRIMEM["Greenwich",0,\n    AUTHORITY["EPSG","8901"]],\n  UNIT["m",1.0,\n    AUTHORITY["EPSG","9001"]],\n  AXIS["Geocentric X",OTHER],\n  AXIS["Geocentric Y",OTHER],\n  AXIS["Geocentric Z",NORTH],\n  AUTHORITY["EPSG","4978"]\n]`});function h(e){return e&&e===s.yr?l:e&&e===s.Z1?u:a}function d(e){return e&&((0,i.BZ)(e)||e===l)?l:e&&((0,i.V2)(e)||e===u)?u:a}function p(e){return e&&((0,i.BZ)(e)||e===l)?s.yr:e&&((0,i.V2)(e)||e===u)?s.Z1:s.sv}function f(e){return(0,i.o$)(e)?s.yr:(0,i.ME)(e)?s.Z1:s.sv}},33955:(e,t,r)=>{r.d(t,{im:()=>m,q9:()=>b,Ji:()=>y,YX:()=>c,aW:()=>h,wp:()=>d,oU:()=>f,l9:()=>p});var n=r(70586),s=r(6570),i=r(9361),o=r(65091),a=r(13473),l=r(17332),u=r(58901);function c(e){return void 0!==e.xmin&&void 0!==e.ymin&&void 0!==e.xmax&&void 0!==e.ymax}function h(e){return void 0!==e.points}function d(e){return void 0!==e.x&&void 0!==e.y}function p(e){return void 0!==e.paths}function f(e){return void 0!==e.rings}function m(e){return(0,n.Wi)(e)?null:e instanceof i.Z?e:d(e)?a.Z.fromJSON(e):p(e)?u.Z.fromJSON(e):f(e)?l.Z.fromJSON(e):h(e)?o.Z.fromJSON(e):c(e)?s.Z.fromJSON(e):null}function y(e){return e?d(e)?"esriGeometryPoint":p(e)?"esriGeometryPolyline":f(e)?"esriGeometryPolygon":c(e)?"esriGeometryEnvelope":h(e)?"esriGeometryMultipoint":null:null}const g={esriGeometryPoint:a.Z,esriGeometryPolyline:u.Z,esriGeometryPolygon:l.Z,esriGeometryEnvelope:s.Z,esriGeometryMultipoint:o.Z};function b(e){return e&&g[e]||null}},86973:(e,t,r)=>{r.d(t,{Mk:()=>s,P$:()=>i});var n=r(35454);const s=(0,n.wY)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),i=(0,n.wY)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"})},40330:(e,t,r)=>{r.d(t,{Dp:()=>u,id:()=>a,qh:()=>l,i8:()=>i,Nv:()=>o});var n=r(80442),s=r(17452);const i="4.22",o={async request(e,t){var n;const{default:i}=await r.e(3172).then(r.bind(r,3172)),o=e.options,a=o.responseType;o.signal=null==t?void 0:t.signal,o.responseType="native"===a||"native-request-init"===a?"native-request-init":["blob","json","text"].includes(a)&&null!=(n=(0,s.oh)(e.url))&&n.after?a:"array-buffer";const l=await i(e.url,o),u={data:l.data,ssl:l.ssl};switch(l.requestOptions.responseType){case"native-request-init":return delete u.data.signal,u;case"blob":u.data=await u.data.arrayBuffer();break;case"json":u.data=(new TextEncoder).encode(JSON.stringify(u.data)).buffer;break;case"text":u.data=(new TextEncoder).encode(u.data).buffer}return{result:u,transferList:[u.data]}}};let a;function l(e){a=e}function u(e){const t=a&&a.findCredential(e);return t&&t.token?(0,s.ZN)(e,"token",t.token):e}(0,n.Z)("host-webworker")||((0,n.Z)("edge")||(0,n.Z)("trident"))&&console.warn("Deprecated browser - see http://esriurl.com/oldbrowser")},29600:(e,t,r)=>{r.d(t,{Z:()=>_});var n=r(43697),s=r(68773),i=(r(66577),r(3172)),o=r(20102),a=r(32448),l=r(10699),u=r(83379),c=r(92604),h=r(95330),d=r(17452),p=r(5600),f=(r(67676),r(80442),r(75215),r(52011)),m=r(6570),y=r(82971);let g=0;const b=c.Z.getLogger("esri.layers.Layer");let v=class extends(a.Z.EventedMixin((0,l.I)(u.Z))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new m.Z(-180,-90,180,90,y.Z.WGS84),this.id=Date.now().toString(16)+"-layer-"+g++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=y.Z.WGS84,this.title=null,this.type=null,this.url=null,this.visible=!0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e,n=await r.e(3529).then(r.bind(r,63529));try{return await n.fromUrl(t)}catch(e){throw b.error("#fromArcGISServerUrl({ url: '"+t.url+"'})","Failed to create layer from arcgis server url",e),e}}static async fromPortalItem(e){const t="portalItem"in e?e:{portalItem:e},n=await r.e(8008).then(r.bind(r,28008));try{return await n.fromItem(t)}catch(e){const r=t&&t.portalItem,n=r&&r.id||"unset",i=r&&r.portal&&r.portal.url||s.Z.portalUrl;throw b.error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+i+"', id: '"+n+"')",e),e}}initialize(){this.when().catch((e=>{var t,r;(0,h.D_)(e)||c.Z.getLogger(this.declaredClass).error("#load()",`Failed to load layer (title: '${null!=(t=this.title)?t:"no title"}', id: '${null!=(r=this.id)?r:"no id"}')`,{error:e})}))}destroy(){if(this.parent){const e=this,t=this.parent;"layers"in t&&t.layers.includes(e)?t.layers.remove(e):"tables"in t&&t.tables.includes(e)?t.tables.remove(e):"baseLayers"in t&&t.baseLayers.includes(e)?t.baseLayers.remove(e):"baseLayers"in t&&t.referenceLayers.includes(e)&&t.referenceLayers.remove(e)}}get hasAttributionData(){return null!=this.attributionDataUrl}get parsedUrl(){const e=this.url;return e?(0,d.mN)(e):null}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,i.default)(e,{query:{f:"json"},responseType:"json"})).data;throw new o.Z("layer:no-attribution-data","Layer does not have attribution data")}};(0,n._)([(0,p.Cb)({type:String})],v.prototype,"attributionDataUrl",void 0),(0,n._)([(0,p.Cb)({type:m.Z})],v.prototype,"fullExtent",void 0),(0,n._)([(0,p.Cb)({readOnly:!0})],v.prototype,"hasAttributionData",null),(0,n._)([(0,p.Cb)({type:String})],v.prototype,"id",void 0),(0,n._)([(0,p.Cb)({type:Boolean,nonNullable:!0})],v.prototype,"legendEnabled",void 0),(0,n._)([(0,p.Cb)({type:["show","hide","hide-children"]})],v.prototype,"listMode",void 0),(0,n._)([(0,p.Cb)({type:Number,range:{min:0,max:1},nonNullable:!0})],v.prototype,"opacity",void 0),(0,n._)([(0,p.Cb)()],v.prototype,"parent",void 0),(0,n._)([(0,p.Cb)({readOnly:!0})],v.prototype,"parsedUrl",null),(0,n._)([(0,p.Cb)({type:Boolean})],v.prototype,"popupEnabled",void 0),(0,n._)([(0,p.Cb)({type:Boolean})],v.prototype,"attributionVisible",void 0),(0,n._)([(0,p.Cb)({type:y.Z})],v.prototype,"spatialReference",void 0),(0,n._)([(0,p.Cb)({type:String})],v.prototype,"title",void 0),(0,n._)([(0,p.Cb)({type:String,readOnly:!0,json:{read:!1}})],v.prototype,"type",void 0),(0,n._)([(0,p.Cb)()],v.prototype,"url",void 0),(0,n._)([(0,p.Cb)({type:Boolean,nonNullable:!0})],v.prototype,"visible",void 0),v=(0,n._)([(0,f.j)("esri.layers.Layer")],v);const _=v},25906:(e,t,r)=>{r.r(t),r.d(t,{default:()=>_e});var n=r(43697),s=r(68773),i=r(38171),o=r(51773),a=r(3172),l=r(81049),u=r(57435),c=r(3920),h=r(35454),d=r(22974),p=r(70586),f=r(16453),m=r(95330),y=r(17452),g=r(5600),b=r(75215),v=r(71715),_=r(52011),w=r(30556),x=r(76169),C=r(6570),E=r(82971),M=r(91040),O=r(8744),S=r(29600),I=r(41522),q=r(38009),U=r(16859),T=r(34760),N=r(72965),A=r(28294),P=r(66677),k=r(21506),R=r(15923);r(67676),r(80442);const L={visible:"visibleSublayers"};let j=class extends((0,c.p)(R.Z)){constructor(e){super(e),this.scale=0}set layer(e){this._get("layer")!==e&&(this._set("layer",e),this.handles.remove("layer"),e&&this.handles.add([e.sublayers.on("change",(()=>this.notifyChange("visibleSublayers"))),e.on("wms-sublayer-update",(e=>this.notifyChange(L[e.propertyName])))],"layer"))}get layers(){const{visibleSublayers:e}=this;return e.filter((e=>e.name)).map((e=>e.name)).join(",")}get version(){this.commitProperty("layers");const e=this.layer;return e&&e.commitProperty("imageTransparency"),(this._get("version")||0)+1}get visibleSublayers(){const{layer:e,scale:t}=this,r=null==e?void 0:e.sublayers,n=[],s=e=>{const{minScale:r,maxScale:i,sublayers:o,visible:a}=e;a&&(0===t||(0===r||t<=r)&&(0===i||t>=i))&&(o?o.forEach(s):n.unshift(e))};return null==r||r.forEach(s),n}toJSON(){const{layer:e,layers:t}=this,{imageFormat:r,imageTransparency:n,version:s}=e;return{format:r,request:"GetMap",service:"WMS",styles:"",transparent:n,version:s,layers:t}}};(0,n._)([(0,g.Cb)()],j.prototype,"layer",null),(0,n._)([(0,g.Cb)({readOnly:!0})],j.prototype,"layers",null),(0,n._)([(0,g.Cb)({type:Number})],j.prototype,"scale",void 0),(0,n._)([(0,g.Cb)({readOnly:!0})],j.prototype,"version",null),(0,n._)([(0,g.Cb)({readOnly:!0})],j.prototype,"visibleSublayers",null),j=(0,n._)([(0,_.j)("esri.layers.support.ExportWMSImageParameters")],j);var Z,F=r(61247),D=r(90578);let B=0,$=Z=class extends f.w{constructor(e){super(e),this._sublayersHandles=new F.Z,this.dimensions=null,this.fullExtents=null,this.featureInfoFormat=null,this.featureInfoUrl=null,this.legendUrl=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.popupEnabled=!1,this.queryable=!1,this.spatialReferences=null}get description(){return this._get("description")}set description(e){this._set("description",e)}get fullExtent(){return this._get("fullExtent")}set fullExtent(e){this._set("fullExtent",e)}readExtent(e,t){return(e=t.extent)?C.Z.fromJSON(e):null}get id(){const e=this._get("id");return null==e?B++:e}set id(e){this._set("id",e)}readLegendUrl(e,t){return t?t.legendUrl||t.legendURL:null}set layer(e){this._set("layer",e),this.sublayers&&this.sublayers.forEach((t=>t.layer=e))}get name(){return this._get("name")}set name(e){this._set("name",e)}set sublayers(e){const t=this._get("sublayers");t&&(t.forEach((e=>{e.layer=null})),this._sublayersHandles.removeAll(),this._sublayersHandles=null),e&&(e.forEach((e=>{e.parent=this,e.layer=this.layer})),this._sublayersHandles.add([e.on("after-add",(({item:e})=>{e.parent=this,e.layer=this.layer})),e.on("after-remove",(({item:e})=>{e.parent=null,e.layer=null}))])),this._set("sublayers",e)}castSublayers(e){return(0,b.se)(l.Z.ofType(Z),e)}get title(){return this._get("title")}set title(e){this._set("title",e)}get visible(){return this._get("visible")}set visible(e){this._setAndNotifyLayer("visible",e)}clone(){const e=new Z;return this.hasOwnProperty("description")&&(e.description=this.description),this.hasOwnProperty("fullExtent")&&(e.fullExtent=this.fullExtent.clone()),this.hasOwnProperty("fullExtents")&&(e.fullExtents=this.fullExtents.map((e=>e.clone()))),this.hasOwnProperty("featureInfoFormat")&&(e.featureInfoFormat=this.featureInfoFormat),this.hasOwnProperty("featureInfoUrl")&&(e.featureInfoUrl=this.featureInfoUrl),this.hasOwnProperty("legendUrl")&&(e.legendUrl=this.legendUrl),this.hasOwnProperty("legendEnabled")&&(e.legendEnabled=this.legendEnabled),this.hasOwnProperty("layer")&&(e.layer=this.layer),this.hasOwnProperty("name")&&(e.name=this.name),this.hasOwnProperty("parent")&&(e.parent=this.parent),this.hasOwnProperty("queryable")&&(e.queryable=this.queryable),this.hasOwnProperty("sublayers")&&(e.sublayers=this.sublayers&&this.sublayers.map((e=>e.clone()))),this.hasOwnProperty("spatialReferences")&&(e.spatialReferences=this.spatialReferences.map((e=>e))),this.hasOwnProperty("visible")&&(e.visible=this.visible),this.hasOwnProperty("title")&&(e.title=this.title),e}_setAndNotifyLayer(e,t){const r=this.layer;this._get(e)!==t&&(this._set(e,t),r&&r.emit("wms-sublayer-update",{propertyName:e,id:this.id}))}};(0,n._)([(0,g.Cb)()],$.prototype,"description",null),(0,n._)([(0,g.Cb)({readOnly:!0})],$.prototype,"dimensions",void 0),(0,n._)([(0,g.Cb)({value:null})],$.prototype,"fullExtent",null),(0,n._)([(0,v.r)("fullExtent",["extent"])],$.prototype,"readExtent",null),(0,n._)([(0,g.Cb)()],$.prototype,"fullExtents",void 0),(0,n._)([(0,g.Cb)()],$.prototype,"featureInfoFormat",void 0),(0,n._)([(0,g.Cb)()],$.prototype,"featureInfoUrl",void 0),(0,n._)([(0,g.Cb)({type:Number,json:{write:{enabled:!1,overridePolicy:()=>({ignoreOrigin:!0,enabled:!0})}}})],$.prototype,"id",null),(0,n._)([(0,g.Cb)({type:String,json:{origins:{"web-document":{read:{source:["legendUrl","legendURL"]},write:{target:"legendUrl",ignoreOrigin:!0}}},read:{source:"legendURL"},write:{ignoreOrigin:!0}}})],$.prototype,"legendUrl",void 0),(0,n._)([(0,v.r)(["web-document"],"legendUrl")],$.prototype,"readLegendUrl",null),(0,n._)([(0,g.Cb)({value:!0,type:Boolean,json:{read:{source:"showLegend"},write:{target:"showLegend"},origins:{"web-map":{read:!1,write:!1},"web-scene":{read:!1,write:!1}}}})],$.prototype,"legendEnabled",void 0),(0,n._)([(0,g.Cb)({value:null})],$.prototype,"layer",null),(0,n._)([(0,g.Cb)()],$.prototype,"maxScale",void 0),(0,n._)([(0,g.Cb)()],$.prototype,"minScale",void 0),(0,n._)([(0,g.Cb)({type:String,value:null,json:{read:{source:"name"},write:{ignoreOrigin:!0}}})],$.prototype,"name",null),(0,n._)([(0,g.Cb)()],$.prototype,"parent",void 0),(0,n._)([(0,g.Cb)({type:Boolean,json:{read:{source:"showPopup"},write:{ignoreOrigin:!0,target:"showPopup"}}})],$.prototype,"popupEnabled",void 0),(0,n._)([(0,g.Cb)({type:Boolean,json:{write:{ignoreOrigin:!0}}})],$.prototype,"queryable",void 0),(0,n._)([(0,g.Cb)()],$.prototype,"sublayers",null),(0,n._)([(0,D.p)("sublayers")],$.prototype,"castSublayers",null),(0,n._)([(0,g.Cb)({type:[Number],json:{read:{source:"spatialReferences"}}})],$.prototype,"spatialReferences",void 0),(0,n._)([(0,g.Cb)({type:String,value:null,json:{write:{ignoreOrigin:!0}}})],$.prototype,"title",null),(0,n._)([(0,g.Cb)({type:Boolean,value:!0,json:{read:{source:"defaultVisibility"}}})],$.prototype,"visible",null),$=Z=(0,n._)([(0,_.j)("esri.layers.support.WMSSublayer")],$);const G=$;var H=r(20102);const W=[[4001,4999],[2044,2045],[2081,2083],[2085,2086],[2093,2093],[2096,2098],[2105,2132],[2169,2170],[2176,2180],[2193,2193],[2200,2200],[2206,2212],[2319,2319],[2320,2462],[2523,2549],[2551,2735],[2738,2758],[2935,2941],[2953,2953],[3006,3030],[3034,3035],[3058,3059],[3068,3068],[3114,3118],[3126,3138],[3300,3301],[3328,3335],[3346,3346],[3350,3352],[3366,3366],[3416,3416],[20004,20032],[20064,20092],[21413,21423],[21473,21483],[21896,21899],[22171,22177],[22181,22187],[22191,22197],[25884,25884],[27205,27232],[27391,27398],[27492,27492],[28402,28432],[28462,28492],[30161,30179],[30800,30800],[31251,31259],[31275,31279],[31281,31290],[31466,31700]],Y={84:4326,83:4269,27:4267};function J(e){if(!e)return null;const t={idCounter:-1};"string"==typeof e&&(e=(new DOMParser).parseFromString(e,"text/xml"));const r=e.documentElement;if("ServiceExceptionReport"===r.nodeName){const e=Array.prototype.slice.call(r.childNodes).map((e=>e.textContent)).join("\r\n");throw new H.Z("wmslayer:wms-capabilities-xml-is-not-valid","The server returned errors when the WMS capabilities were requested.",e)}const n=Q("Capability",r),s=Q("Service",r),i=Q("Request",n);if(!n||!s||!i)return null;const o=Q("Layer",n);if(!o)return null;const a="WMS_Capabilities"===r.nodeName||"WMT_MS_Capabilities"===r.nodeName?r.getAttribute("version"):"1.3.0",l=te("Title",s,"")||te("Name",s,""),u=te("AccessConstraints",s,""),c=te("Abstract",s,""),h=parseInt(te("MaxWidth",s,"5000"),10),d=parseInt(te("MaxHeight",s,"5000"),10),p=se(i,"GetMap"),f=ne(i,"GetMap"),m=oe(o,a,t);let y,g,b,v=0;if(Array.prototype.slice.call(n.childNodes).forEach((e=>{"Layer"===e.nodeName&&(0===v?y=e:1===v?(m.name&&(m.name="",m.sublayers.push(oe(y,a,t))),m.sublayers.push(oe(e,a,t))):m.sublayers.push(oe(e,a,t)),v++)})),!m)return null;const _=m.fullExtents;if(g=m.sublayers,g||(g=[]),0===g.length&&g.push(m),b=m.extent,!b){const e=new C.Z(g[0].extent);m.extent=e.toJSON(),b=m.extent}const w=m.spatialReferences.length>0?m.spatialReferences:z(m),x=ne(i,"GetFeatureInfo");let E;if(x){const e=se(i,"GetFeatureInfo");e.indexOf("text/html")>-1?E="text/html":e.indexOf("text/plain")>-1&&(E="text/plain")}if(!E){const e=function(t){t&&(t.queryable=!1,t.sublayers&&t.sublayers.forEach((t=>{e(t)})))};e(m)}const M=X(g),O=m.minScale||0,S=m.maxScale||0,I=m.dimensions,q=M.reduce(((e,t)=>e.concat(t.dimensions)),[]),U=I.concat(q).filter(le);let T=null;if(U.length>0){let e=Number.POSITIVE_INFINITY,t=Number.NEGATIVE_INFINITY;U.forEach((r=>{const{extent:n}=r;!function(e){return Array.isArray(e)&&e.length>0&&e[0]instanceof Date}(n)?n.forEach((r=>{e=Math.min(e,r.min.getTime()),t=Math.max(t,r.max.getTime())})):n.forEach((r=>{e=Math.min(e,r.getTime()),t=Math.max(t,r.getTime())}))})),T={startTimeField:null,endTimeField:null,trackIdField:null,timeExtent:[e,t]}}return{copyright:u,description:c,dimensions:I,extent:b,fullExtents:_,featureInfoFormat:E,featureInfoUrl:x,mapUrl:f,maxWidth:h,maxHeight:d,maxScale:S,minScale:O,layers:M,spatialReferences:w,supportedImageFormatTypes:p,timeInfo:T,title:l,version:a}}function V(e){return W.some((([t,r])=>e>=t&&e<=r))}function z(e){if(e.spatialReferences.length>0)return e.spatialReferences;if(e.sublayers)for(const t of e.sublayers){const e=z(t);if(e.length>0)return e}return[]}function X(e){let t=[];return e.forEach((e=>{t.push(e),e.sublayers&&e.sublayers.length&&(t=t.concat(X(e.sublayers)),delete e.sublayers)})),t}function K(e,t,r){var n;return null!=(n=t.getAttribute(e))?n:r}function Q(e,t){for(let r=0;r<t.childNodes.length;r++){const n=t.childNodes[r];if(ae(n)&&n.nodeName===e)return n}return null}function ee(e,t){const r=[];for(let n=0;n<t.childNodes.length;n++){const s=t.childNodes[n];ae(s)&&s.nodeName===e&&r.push(s)}return r}function te(e,t,r){const n=Q(e,t);return n?n.textContent:r}function re(e,t,r){if(!e)return null;const n=parseFloat(e.getAttribute("minx")),s=parseFloat(e.getAttribute("miny")),i=parseFloat(e.getAttribute("maxx")),o=parseFloat(e.getAttribute("maxy"));let a,l,u,c;r?(a=isNaN(s)?-Number.MAX_VALUE:s,l=isNaN(n)?-Number.MAX_VALUE:n,u=isNaN(o)?Number.MAX_VALUE:o,c=isNaN(i)?Number.MAX_VALUE:i):(a=isNaN(n)?-Number.MAX_VALUE:n,l=isNaN(s)?-Number.MAX_VALUE:s,u=isNaN(i)?Number.MAX_VALUE:i,c=isNaN(o)?Number.MAX_VALUE:o);const h=new E.Z({wkid:t});return new C.Z({xmin:a,ymin:l,xmax:u,ymax:c,spatialReference:h})}function ne(e,t){const r=Q(t,e);if(r){const e=Q("DCPType",r);if(e){const t=Q("HTTP",e);if(t){const e=Q("Get",t);if(e){let t=function(e,t,r,n){const s=Q("OnlineResource",r);return s?K("xlink:href",s,null):null}(0,0,e);if(t)return t.indexOf("&")===t.length-1&&(t=t.substring(0,t.length-1)),function(e,t){const r=[],n=(0,y.mN)(e);for(const e in n.query)n.query.hasOwnProperty(e)&&-1===t.indexOf(e.toLowerCase())&&r.push(e+"="+n.query[e]);return n.path+(r.length?"?"+r.join("&"):"")}(t,["service","request"])}}}}return null}function se(e,t){const r=ee("Operation",e);if(0===r.length)return ee("Format",Q(t,e)).map((e=>e.textContent));const n=[];return r.forEach((e=>{e.getAttribute("name")===t&&ee("Format",e).forEach((e=>{n.push(e.textContent)}))})),n}function ie(e,t,r){const n=Q(t,e);if(!n)return r;const{textContent:s}=n;if(null==s||""===s)return r;const i=Number(s);return isNaN(i)?r:i}function oe(e,t,r){var n;if(!e)return null;const s={id:r.idCounter++,fullExtents:[],parentLayerId:null,queryable:"1"===e.getAttribute("queryable"),spatialReferences:[],sublayers:null},i=Q("LatLonBoundingBox",e),o=Q("EX_GeographicBoundingBox",e);let a=null;i&&(a=re(i,4326)),o&&(a=new C.Z(0,0,0,0,new E.Z({wkid:4326})),a.xmin=parseFloat(te("westBoundLongitude",o,"0")),a.ymin=parseFloat(te("southBoundLatitude",o,"0")),a.xmax=parseFloat(te("eastBoundLongitude",o,"0")),a.ymax=parseFloat(te("northBoundLatitude",o,"0"))),i||o||(a=new C.Z(-180,-90,180,90,new E.Z({wkid:4326}))),s.minScale=ie(e,"MaxScaleDenominator",0),s.maxScale=ie(e,"MinScaleDenominator",0);const l=["1.0.0","1.1.0","1.1.1"].indexOf(t)>-1?"SRS":"CRS";return Array.prototype.slice.call(e.childNodes).forEach((e=>{if("Name"===e.nodeName)s.name=e.textContent||"";else if("Title"===e.nodeName)s.title=e.textContent||"";else if("Abstract"===e.nodeName)s.description=e.textContent||"";else if("BoundingBox"===e.nodeName){const r=e.getAttribute(l);if(r&&0===r.indexOf("EPSG:")){const n=parseInt(r.substring(5),10);0===n||isNaN(n)||a||(a="1.3.0"===t?re(e,n,V(n)):re(e,n))}const n=r&&r.indexOf(":");if(n&&n>-1){let i=parseInt(r.substring(n+1,r.length),10);0===i||isNaN(i)||(i=Y[i]?Y[i]:i);const o="1.3.0"===t?re(e,i,V(i)):re(e,i);s.fullExtents.push(o)}}else if(e.nodeName===l)e.textContent.split(" ").forEach((e=>{const t=e.includes(":")?parseInt(e.split(":")[1],10):parseInt(e,10);if(0!==t&&!isNaN(t)){const e=Y[t]?Y[t]:t;s.spatialReferences.includes(e)||s.spatialReferences.push(e)}}));else if("Style"!==e.nodeName||s.legendURL){if("Layer"===e.nodeName){const n=oe(e,t,r);n&&(n.parentLayerId=s.id,s.sublayers||(s.sublayers=[]),s.sublayers.push(n))}}else{const t=Q("LegendURL",e);if(t){const e=Q("OnlineResource",t);e&&(s.legendURL=e.getAttribute("xlink:href"))}}})),s.extent=null==(n=a)?void 0:n.toJSON(),s.dimensions=ee("Dimension",e).filter((e=>e.getAttribute("name")&&e.getAttribute("units")&&e.textContent)).map((e=>{const t=e.getAttribute("name"),r=e.getAttribute("units"),n=e.textContent,s=e.getAttribute("unitSymbol"),i=e.getAttribute("default"),o="0"!==K("default",e,"0"),a="0"!==K("nearestValue",e,"0"),l="0"!==K("current",e,"0");return/^time$/i.test(t)&&/^ISO8601$/i.test(r)?{name:"time",units:"ISO8601",extent:he(n),default:he(i),multipleValues:o,nearestValue:a,current:l}:/^elevation$/i.test(t)?{name:"elevation",units:r,extent:ue(n),unitSymbol:s,default:ue(i),multipleValues:o,nearestValue:a}:{name:t,units:r,extent:ce(n),unitSymbol:s,default:ce(i),multipleValues:o,nearestValue:a}})),s}function ae(e){return e.nodeType===Node.ELEMENT_NODE}function le(e){return"time"===e.name}function ue(e){if(!e)return null;const t=-1!==e.indexOf("/"),r=e.split(",");return t?r.map((e=>{const t=e.split("/");return t.length<2?null:{min:parseFloat(t[0]),max:parseFloat(t[1]),resolution:t.length>=3&&"0"!==t[2]?parseFloat(t[2]):void 0}})).filter((e=>e)):r.map((e=>parseFloat(e)))}function ce(e){if(!e)return null;const t=-1!==e.indexOf("/"),r=e.split(",");return t?r.map((e=>{const t=e.split("/");return t.length<2?null:{min:t[0],max:t[1],resolution:t.length>=3&&"0"!==t[2]?t[2]:void 0}})).filter((e=>e)):r}function he(e){if(!e)return null;const t=-1!==e.indexOf("/"),r=e.split(",");return t?r.map((e=>{const t=e.split("/");return t.length<2?null:{min:new Date(t[0]),max:new Date(t[1]),resolution:t.length>=3&&"0"!==t[2]?de(t[2]):void 0}})).filter((e=>e)):r.map((e=>new Date(e)))}function de(e){const t=e.match(/(?:p(\d+y|\d+(?:.|,)\d+y)?(\d+m|\d+(?:.|,)\d+m)?(\d+d|\d+(?:.|,)\d+d)?)?(?:t(\d+h|\d+(?:.|,)\d+h)?(\d+m|\d+(?:.|,)\d+m)?(\d+s|\d+(?:.|,)\d+s)?)?/i);return t?{years:pe(t[1]),months:pe(t[2]),days:pe(t[3]),hours:pe(t[4]),minutes:pe(t[5]),seconds:pe(t[6])}:null}function pe(e){if(!e)return 0;const t=e.match(/(?:\d+(?:.|,)\d+|\d+)/);if(!t)return 0;const r=t[0].replace(",",".");return Number(r)}function fe(e){return e.toISOString().replace(/\.[0-9]{3}/,"")}const me=new Set([102100,3857,102113,900913]),ye=new Set([3395,54004]),ge=new h.Xn({bmp:"image/bmp",gif:"image/gif",jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml"},{ignoreUnknown:!1});let be=class extends((0,c.p)((0,I.h)((0,A.n)((0,T.Q)((0,N.M)((0,q.q)((0,U.I)((0,f.R)(S.Z))))))))){constructor(...e){super(...e),this.allSublayers=new u.Z({getCollections:()=>[this.sublayers],getChildrenFunction:e=>e.sublayers}),this.customParameters=null,this.customLayerParameters=null,this.copyright=null,this.description=null,this.dimensions=null,this.fullExtent=null,this.fullExtents=null,this.featureInfoFormat=null,this.featureInfoUrl=null,this.imageFormat=null,this.imageMaxHeight=2048,this.imageMaxWidth=2048,this.imageTransparency=!0,this.legendEnabled=!0,this.mapUrl=null,this.isReference=null,this.operationalLayerType="WMS",this.spatialReference=null,this.spatialReferences=null,this.sublayers=null,this.type="wms",this.url=null,this.version=null,this.watch("sublayers",((e,t)=>{if(t){for(const e of t)e.layer=null;this.handles.remove("wms-sublayer")}if(e){for(const t of e)t.parent=this,t.layer=this;this.handles.add([e.on("after-add",(({item:e})=>{e.parent=this,e.layer=this})),e.on("after-remove",(({item:e})=>{e.parent=null,e.layer=null}))],"wms-sublayer")}}),!0)}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}load(e){const t=(0,p.pC)(e)?e.signal:null;return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["WMS"]},e).catch(m.r9).then((()=>this._fetchService(t)))),Promise.resolve(this)}readFullExtentFromItemOrMap(e,t){const r=t.extent;return new C.Z({xmin:r[0][0],ymin:r[0][1],xmax:r[1][0],ymax:r[1][1]})}writeFullExtent(e,t){t.extent=[[e.xmin,e.ymin],[e.xmax,e.ymax]]}readImageFormat(e,t){const r=t.supportedImageFormatTypes;return r&&r.indexOf("image/png")>-1?"image/png":r&&r[0]}readSpatialReferenceFromItemOrDocument(e,t){return new E.Z(t.spatialReferences[0])}writeSpatialReferences(e,t){const r=this.spatialReference&&this.spatialReference.wkid;e&&r?(t.spatialReferences=e.filter((e=>e!==r)),t.spatialReferences.unshift(r)):t.spatialReferences=e}readSublayersFromItemOrMap(e,t,r){return ve(t.layers,r,t.visibleLayers)}readSublayers(e,t,r){return ve(t.layers,r)}writeSublayers(e,t,r,n){t.layers=[];const s=new Map,i=e.flatten((({sublayers:e})=>e&&e.toArray())).toArray();i.forEach((e=>{"number"==typeof e.parent.id&&(s.has(e.parent.id)?s.get(e.parent.id).push(e.id):s.set(e.parent.id,[e.id]))})),i.forEach((e=>{const r={sublayer:e,...n},i=e.write({parentLayerId:"number"==typeof e.parent.id?e.parent.id:-1},r);if(s.has(e.id)&&(i.sublayerIds=s.get(e.id)),!e.sublayers&&e.name){const n=e.write({},r);delete n.id,t.layers.push(n)}})),t.visibleLayers=i.filter((e=>e.visible&&!e.sublayers)).map((e=>e.name))}createExportImageParameters(e,t,r,n){const s=n&&n.pixelRatio||1,i=(0,M.yZ)({extent:e,width:t})*s,o=new j({layer:this,scale:i}),{xmin:a,ymin:l,xmax:u,ymax:c,spatialReference:h}=e,d=function(e,t){let r=e.wkid;return(0,p.Wi)(t)?r:(!t.includes(r)&&e.latestWkid&&(r=e.latestWkid),me.has(r)?t.find((e=>me.has(e)))||t.find((e=>ye.has(e)))||102100:r)}(h,this.spatialReferences),f="1.3.0"===this.version&&V(d)?`${l},${a},${c},${u}`:`${a},${l},${u},${c}`,m=o.toJSON();return{bbox:f,["1.3.0"===this.version?"crs":"srs"]:isNaN(d)?void 0:"EPSG:"+d,...m}}async fetchImage(e,t,r,n){var s,i;const o=this.mapUrl,l=this.createExportImageParameters(e,t,r,n);if(!l.layers){const e=document.createElement("canvas");return e.width=t,e.height=r,e}const u=null==n||null==(s=n.timeExtent)?void 0:s.start,c=null==n||null==(i=n.timeExtent)?void 0:i.end,h=(0,p.pC)(u)&&(0,p.pC)(c)?u.getTime()===c.getTime()?fe(u):`${fe(u)}/${fe(c)}`:void 0,d={responseType:"image",query:this._mixCustomParameters({width:t,height:r,...l,time:h,...this.refreshParameters}),signal:null==n?void 0:n.signal};return(0,a.default)(o,d).then((e=>e.data))}fetchFeatureInfo(e,t,r,n,s){const a=(0,M.yZ)({extent:e,width:t}),l=function(e){return e.length?e.filter((e=>e.popupEnabled&&e.name&&e.queryable)).map((e=>e.name)).join(","):""}(new j({layer:this,scale:a}).visibleSublayers);if(!this.featureInfoUrl||!l)return null;const u="1.3.0"===this.version?{I:n,J:s}:{x:n,y:s},c={query_layers:l,request:"GetFeatureInfo",info_format:this.featureInfoFormat,feature_count:25,width:t,height:r,...u},h={...this.createExportImageParameters(e,t,r),...c},d=this._mixCustomParameters(h),p=(0,y.fl)(this.featureInfoUrl,d),f=document.createElement("iframe");f.src=p,f.style.border="none",f.style.margin="0",f.style.width="100%",f.setAttribute("sandbox","");const m=new o.Z({title:this.title,content:f});return new i.Z({sourceLayer:this,popupTemplate:m})}findSublayerById(e){return this.allSublayers.find((t=>t.id===e))}findSublayerByName(e){return this.allSublayers.find((t=>t.name===e))}supportsSpatialReference(e){return(0,P.G)(this.url)||this.spatialReferences.some((t=>{const r=900913===t?E.Z.WebMercator:new E.Z({wkid:t});return(0,O.fS)(r,e)}))}async _fetchService(e){if(!this.resourceInfo){this.parsedUrl.query&&this.parsedUrl.query.service&&(this.parsedUrl.query.SERVICE=this.parsedUrl.query.service,delete this.parsedUrl.query.service),this.parsedUrl.query&&this.parsedUrl.query.request&&(this.parsedUrl.query.REQUEST=this.parsedUrl.query.request,delete this.parsedUrl.query.request);const t=await(0,a.default)(this.parsedUrl.path,{query:{SERVICE:"WMS",REQUEST:"GetCapabilities",...this.parsedUrl.query,...this.customParameters},responseType:"xml",signal:e});this.resourceInfo=J(t.data)}if(this.parsedUrl){const e=new y.R9(this.parsedUrl.path);"https"!==e.scheme||e.port&&"443"!==e.port||-1!==s.Z.request.httpsDomains.indexOf(e.host)||s.Z.request.httpsDomains.push(e.host)}this.read(this.resourceInfo,{origin:"service"})}_mixCustomParameters(e){if(!this.customLayerParameters&&!this.customParameters)return e;const t={...this.customParameters,...this.customLayerParameters};for(const r in t)e[r.toLowerCase()]=t[r];return e}};function ve(e,t,r){const n=new Map;e.every((e=>null==e.id))&&(e=(0,d.d9)(e)).forEach(((e,t)=>e.id=t));for(const s of e){const e=new G;e.read(s,t),-1===(null==r?void 0:r.indexOf(e.name))&&(e.visible=!1),n.set(e.id,e)}const s=[];for(const t of e){const e=n.get(t.id);if(null!=t.parentLayerId&&t.parentLayerId>=0){const r=n.get(t.parentLayerId);r.sublayers||(r.sublayers=new l.Z),r.sublayers.unshift(e)}else s.unshift(e)}return s}(0,n._)([(0,g.Cb)({readOnly:!0})],be.prototype,"allSublayers",void 0),(0,n._)([(0,g.Cb)({json:{type:Object,write:!0}})],be.prototype,"customParameters",void 0),(0,n._)([(0,g.Cb)({json:{type:Object,write:!0}})],be.prototype,"customLayerParameters",void 0),(0,n._)([(0,g.Cb)({type:String,json:{write:!0}})],be.prototype,"copyright",void 0),(0,n._)([(0,g.Cb)()],be.prototype,"description",void 0),(0,n._)([(0,g.Cb)({readOnly:!0})],be.prototype,"dimensions",void 0),(0,n._)([(0,g.Cb)({json:{type:[[Number]],read:{source:"extent"},write:{target:"extent"},origins:{"web-document":{write:{ignoreOrigin:!0}},"portal-item":{write:{ignoreOrigin:!0}}}}})],be.prototype,"fullExtent",void 0),(0,n._)([(0,v.r)(["web-document","portal-item"],"fullExtent",["extent"])],be.prototype,"readFullExtentFromItemOrMap",null),(0,n._)([(0,w.c)(["web-document","portal-item"],"fullExtent",{extent:{type:[[Number]]}})],be.prototype,"writeFullExtent",null),(0,n._)([(0,g.Cb)()],be.prototype,"fullExtents",void 0),(0,n._)([(0,g.Cb)({type:String,json:{write:{ignoreOrigin:!0}}})],be.prototype,"featureInfoFormat",void 0),(0,n._)([(0,g.Cb)({type:String,json:{write:{ignoreOrigin:!0}}})],be.prototype,"featureInfoUrl",void 0),(0,n._)([(0,g.Cb)({type:String,json:{origins:{"web-document":{default:"image/png",type:ge.jsonValues,read:{reader:ge.read,source:"format"},write:{writer:ge.write,target:"format"}}}}})],be.prototype,"imageFormat",void 0),(0,n._)([(0,v.r)("imageFormat",["supportedImageFormatTypes"])],be.prototype,"readImageFormat",null),(0,n._)([(0,g.Cb)({type:Number,json:{read:{source:"maxHeight"},write:{target:"maxHeight"}}})],be.prototype,"imageMaxHeight",void 0),(0,n._)([(0,g.Cb)({type:Number,json:{read:{source:"maxWidth"},write:{target:"maxWidth"}}})],be.prototype,"imageMaxWidth",void 0),(0,n._)([(0,g.Cb)()],be.prototype,"imageTransparency",void 0),(0,n._)([(0,g.Cb)(k.rn)],be.prototype,"legendEnabled",void 0),(0,n._)([(0,g.Cb)({type:["show","hide","hide-children"]})],be.prototype,"listMode",void 0),(0,n._)([(0,g.Cb)({type:String,json:{write:{ignoreOrigin:!0}}})],be.prototype,"mapUrl",void 0),(0,n._)([(0,g.Cb)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],be.prototype,"isReference",void 0),(0,n._)([(0,g.Cb)({type:["WMS"]})],be.prototype,"operationalLayerType",void 0),(0,n._)([(0,g.Cb)({type:E.Z,json:{origins:{service:{read:{source:"extent.spatialReference"}}},write:!1}})],be.prototype,"spatialReference",void 0),(0,n._)([(0,v.r)(["web-document","portal-item"],"spatialReference",["spatialReferences"])],be.prototype,"readSpatialReferenceFromItemOrDocument",null),(0,n._)([(0,g.Cb)({type:[b.z8],json:{read:!1,origins:{service:{read:!0},"web-document":{read:!1,write:{ignoreOrigin:!0}},"portal-item":{read:!1,write:{ignoreOrigin:!0}}}}})],be.prototype,"spatialReferences",void 0),(0,n._)([(0,w.c)(["web-document","portal-item"],"spatialReferences")],be.prototype,"writeSpatialReferences",null),(0,n._)([(0,g.Cb)({type:l.Z.ofType(G),json:{write:{target:"layers",overridePolicy(e,t,r){if(function(e,t){return e.some((e=>{for(const r in e)if((0,x.df)(e,r,null,t))return!0;return!1}))}(this.allSublayers,r))return{ignoreOrigin:!0}}}}})],be.prototype,"sublayers",void 0),(0,n._)([(0,v.r)(["web-document","portal-item"],"sublayers",["layers","visibleLayers"])],be.prototype,"readSublayersFromItemOrMap",null),(0,n._)([(0,v.r)("service","sublayers",["layers"])],be.prototype,"readSublayers",null),(0,n._)([(0,w.c)("sublayers",{layers:{type:[G]},visibleLayers:{type:[String]}})],be.prototype,"writeSublayers",null),(0,n._)([(0,g.Cb)({json:{read:!1},readOnly:!0,value:"wms"})],be.prototype,"type",void 0),(0,n._)([(0,g.Cb)(k.HQ)],be.prototype,"url",void 0),(0,n._)([(0,g.Cb)({type:String,json:{write:{ignoreOrigin:!0}}})],be.prototype,"version",void 0),be=(0,n._)([(0,_.j)("esri.layers.WMSLayer")],be);const _e=be},34760:(e,t,r)=>{r.d(t,{Q:()=>g});var n=r(43697),s=r(92604),i=r(95330),o=r(5600),a=(r(67676),r(80442),r(75215),r(52011)),l=r(81049),u=(r(26258),r(87538));const c=new l.Z,h=new WeakMap;function d(e){return e&&"object"==typeof e&&"refreshInterval"in e&&"refresh"in e}function p(e,t){return Number.isFinite(e)&&Number.isFinite(t)?t<=0?e:p(t,e%t):0}let f=0,m=0;function y(){const e=Date.now();for(const r of c)if(r.refreshInterval){var t;e-(null!=(t=h.get(r))?t:0)+5>=6e4*r.refreshInterval&&(h.set(r,e),r.refresh(e))}}(0,u.EH)((()=>{const e=Date.now();let t=0;for(const r of c)t=p(Math.round(6e4*r.refreshInterval),t),r.refreshInterval?h.get(r)||h.set(r,e):h.delete(r);if(t!==m){if(m=t,clearInterval(f),0===m)return void(f=0);f=setInterval(y,m)}}));const g=e=>{let t=class extends e{constructor(...e){super(...e),this.refreshInterval=0,this.refreshTimestamp=0,this._debounceHasDataChanged=(0,i.Ds)((()=>this.hasDataChanged())),this.when().then((()=>{!function(e){d(e)&&c.push(e)}(this)}),(()=>{}))}destroy(){var e;d(e=this)&&c.includes(e)&&c.remove(e)}get refreshParameters(){return{_ts:this.refreshTimestamp||null}}refresh(e=Date.now()){(0,i.R8)(this._debounceHasDataChanged()).then((t=>{t&&this._set("refreshTimestamp",e),this.emit("refresh",{dataChanged:t})}),(e=>{s.Z.getLogger(this.declaredClass).error(e),this.emit("refresh",{dataChanged:!1,error:e})}))}async hasDataChanged(){return!0}};return(0,n._)([(0,o.Cb)({type:Number,cast:e=>e>=.1?e:e<=0?0:.1,json:{write:!0}})],t.prototype,"refreshInterval",void 0),(0,n._)([(0,o.Cb)({readOnly:!0})],t.prototype,"refreshTimestamp",void 0),(0,n._)([(0,o.Cb)()],t.prototype,"refreshParameters",null),t=(0,n._)([(0,a.j)("esri.layers.mixins.RefreshableLayer")],t),t}},66677:(e,t,r)=>{r.d(t,{ld:()=>f,B5:()=>h,M8:()=>y,G:()=>_,Qc:()=>d,DR:()=>p,Nm:()=>g,XG:()=>b,a7:()=>m,wH:()=>v});var n=r(70586),s=r(17452),i=r(25929);const o={mapserver:"MapServer",imageserver:"ImageServer",featureserver:"FeatureServer",sceneserver:"SceneServer",streamserver:"StreamServer",vectortileserver:"VectorTileServer"},a=Object.values(o),l=new RegExp(`^((?:https?:)?\\/\\/\\S+?\\/rest\\/services\\/(.+?)\\/(${a.join("|")}))(?:\\/(?:layers\\/)?(\\d+))?`,"i"),u=new RegExp(`^((?:https?:)?\\/\\/\\S+?\\/([^\\/\\n]+)\\/(${a.join("|")}))(?:\\/(?:layers\\/)?(\\d+))?`,"i"),c=/(.*?)\/(?:layers\/)?(\d+)\/?$/i;function h(e){return!!l.test(e)}function d(e){const t=(0,s.mN)(e),r=t.path.match(l)||t.path.match(u);if(!r)return null;const[,n,i,a,c]=r,h=i.indexOf("/");return{title:f(-1!==h?i.slice(h+1):i),serverType:o[a.toLowerCase()],sublayer:null!=c&&""!==c?parseInt(c,10):null,url:{path:n}}}function p(e){const t=(0,s.mN)(e).path.match(c);return t?{serviceUrl:t[1],sublayerId:Number(t[2])}:null}function f(e){return(e=e.replace(/\s*[/_]+\s*/g," "))[0].toUpperCase()+e.slice(1)}function m(e,t){const r=[];if(e){const t=d(e);(0,n.pC)(t)&&t.title&&r.push(t.title)}if(t){const e=f(t);r.push(e)}if(2===r.length){if(-1!==r[0].toLowerCase().indexOf(r[1].toLowerCase()))return r[0];if(-1!==r[1].toLowerCase().indexOf(r[0].toLowerCase()))return r[1]}return r.join(" - ")}function y(e){if(!e)return!1;const t=-1!==(e=e.toLowerCase()).indexOf(".arcgis.com/"),r=-1!==e.indexOf("//services")||-1!==e.indexOf("//tiles")||-1!==e.indexOf("//features");return t&&r}function g(e,t){return e?(0,s.Qj)((0,s.Hu)(e,t)):e}function b(e){let{url:t}=e;if(!t)return{url:t};t=(0,s.Hu)(t,e.logger);const r=(0,s.mN)(t),i=d(r.path);let o;if((0,n.pC)(i))null!=i.sublayer&&null==e.layer.layerId&&(o=i.sublayer),t=i.url.path;else if(e.nonStandardUrlAllowed){const e=p(r.path);(0,n.pC)(e)&&(t=e.serviceUrl,o=e.sublayerId)}return{url:(0,s.Qj)(t),layerId:o}}function v(e,t,r,n,o){(0,i.w)(t,n,"url",o),n.url&&null!=e.layerId&&(n.url=(0,s.v_)(n.url,r,e.layerId.toString()))}function _(e){if(!e)return!1;const t=e.toLowerCase(),r=-1!==t.indexOf("/services/"),n=-1!==t.indexOf("/mapserver/wmsserver"),s=-1!==t.indexOf("/imageserver/wmsserver"),i=-1!==t.indexOf("/wmsserver");return r&&(n||s||i)}},3172:(e,t,r)=>{r.r(t),r.d(t,{default:()=>f});var n=r(68773),s=r(40330),i=r(20102),o=r(16358),a=r(80442),l=r(22974),u=r(70586),c=r(95330),h=r(17452),d=r(71058),p=r(85958);async function f(e,t){var l;const p=(0,h.HK)(e),b=(0,h.jc)(e);b||p||(e=(0,h.Fv)(e));const v={url:e,requestOptions:{...(0,u.Wg)(t)}};let _=(0,h.oh)(e);if(_){const e=await async function(e,t){if(null!=e.responseData)return e.responseData;if(e.headers&&(t.requestOptions.headers={...t.requestOptions.headers,...e.headers}),e.query&&(t.requestOptions.query={...t.requestOptions.query,...e.query}),e.before){let r,n;try{n=await e.before(t)}catch(e){r=E("request:interceptor",e,t)}if((n instanceof Error||n instanceof i.Z)&&(r=E("request:interceptor",n,t)),r)throw e.error&&e.error(r),r;return n}}(_,v);if(null!=e)return{data:e,getHeader:w,requestOptions:v.requestOptions,url:v.url};_.after||_.error||(_=null)}if(e=v.url,"image"===(t=v.requestOptions).responseType){if((0,a.Z)("host-webworker")||(0,a.Z)("host-node"))throw E("request:invalid-parameters",new Error("responseType 'image' is not supported in Web Workers or Node environment"),v)}else if(p)throw E("request:invalid-parameters",new Error("Data URLs are not supported for responseType = "+t.responseType),v);if("head"===t.method){if(t.body)throw E("request:invalid-parameters",new Error("body parameter cannot be set when method is 'head'"),v);if(p||b)throw E("request:invalid-parameters",new Error("data and blob URLs are not supported for method 'head'"),v)}if(await async function(){(0,a.Z)("host-webworker")?m||(m=await Promise.all([r.e(102),r.e(9884)]).then(r.bind(r,29884))):f._abortableFetch||(f._abortableFetch=o.Z.fetch.bind(o.Z))}(),m)return m.execute(e,t);const x=new AbortController;(0,c.fu)(t,(()=>x.abort()));const C={controller:x,credential:null,credentialToken:null,fetchOptions:null,hasToken:!1,interceptor:_,params:v,redoRequest:!1,useIdentity:y.useIdentity,useProxy:!1,useSSL:!1,withCredentials:!1},I=await async function(e){var t,r;let i,a;await async function(e){const t=e.params.url,r=e.params.requestOptions,i=e.controller.signal,a=r.body;let l=null,u=null,h=null;if(g&&"HTMLFormElement"in o.Z&&(a instanceof FormData?l=a:a instanceof HTMLFormElement&&(u=a,l=new FormData(u))),"string"==typeof a&&(h=a),e.fetchOptions={cache:r.cacheBust&&!f._abortableFetch.polyfill?"no-cache":"default",credentials:"same-origin",headers:r.headers||{},method:"head"===r.method?"HEAD":"GET",mode:"cors",redirect:"follow",signal:i},(l||h)&&(e.fetchOptions.body=l||h),"anonymous"===r.authMode&&(e.useIdentity=!1),e.hasToken=!!(/token=/i.test(t)||r.query&&r.query.token||l&&l.get&&l.get("token")||u&&u.elements.token),!e.hasToken&&n.Z.apiKey&&(0,d.r)(t)&&(r.query||(r.query={}),r.query.token=n.Z.apiKey,e.hasToken=!0),e.useIdentity&&!e.hasToken&&!e.credentialToken&&!O(t)&&!(0,c.Hc)(i)){let n;"immediate"===r.authMode?(await M(),n=await s.id.getCredential(t,{signal:i}),e.credential=n):"no-prompt"===r.authMode?(await M(),n=await s.id.getCredential(t,{prompt:!1,signal:i}).catch((()=>{})),e.credential=n):s.id&&(n=s.id.findCredential(t)),n&&(e.credentialToken=n.token,e.useSSL=!!n.ssl)}}(e);try{do{[i,a]=await S(e)}while(!await q(e,i,a))}catch(t){const r=E("request:server",t,e.params,i);throw r.details.ssl=e.useSSL,e.interceptor&&e.interceptor.error&&e.interceptor.error(r),r}const l=e.params.url;if(/\/sharing\/rest\/(accounts|portals)\/self/i.test(l)&&!e.hasToken&&!e.credentialToken&&null!=(t=a)&&null!=(r=t.user)&&r.username&&!(0,h.kl)(l)){const e=(0,h.P$)(l,!0);e&&y.trustedServers.push(e)}const u=e.credential;if(u&&s.id){const e=s.id.findServerInfo(u.server);let t=e&&e.owningSystemUrl;if(t){t=t.replace(/\/?$/,"/sharing");const e=s.id.findCredential(t,u.userId);e&&-1===s.id._getIdenticalSvcIdx(t,e)&&e.resources.unshift(t)}}return{data:a,getHeader:i?e=>i.headers.get(e):w,requestOptions:e.params.requestOptions,ssl:e.useSSL,url:e.params.url}}(C);return null==(l=_)||null==l.after||l.after(I),I}let m;const y=n.Z.request,g="FormData"in o.Z,b=[499,498,403,401],v=["COM_0056","COM_0057","SB_0008"],_=[/\/arcgis\/tokens/i,/\/sharing(\/rest)?\/generatetoken/i,/\/rest\/info/i],w=()=>null,x=Symbol();function C(e){const t=(0,h.P$)(e);return!t||t.endsWith(".arcgis.com")||f._corsServers.includes(t)||(0,h.kl)(t)}function E(e,t,r,n){let s="Error";const o={url:r.url,requestOptions:r.requestOptions,getHeader:w,ssl:!1};if(t instanceof i.Z)return t.details?(t.details=(0,l.d9)(t.details),t.details.url=r.url,t.details.requestOptions=r.requestOptions):t.details=o,t;if(t){const e=n&&(e=>n.headers.get(e)),r=n&&n.status,i=t.message;i&&(s=i),e&&(o.getHeader=e),o.httpStatus=(null!=t.httpCode?t.httpCode:t.code)||r||0,o.subCode=t.subcode,o.messageCode=t.messageCode,"string"==typeof t.details?o.messages=[t.details]:o.messages=t.details,o.raw=x in t?t[x]:t}return(0,c.D_)(t)?(0,c.zE)():new i.Z(e,s,o)}async function M(){s.id||await Promise.all([r.e(7824),r.e(8778),r.e(102),r.e(9625)]).then(r.bind(r,79339))}function O(e){return _.some((t=>t.test(e)))}async function S(e){let t=e.params.url;const r=e.params.requestOptions,n=e.fetchOptions,i=(0,h.jc)(t)||(0,h.HK)(t),o=r.responseType||"json",l=i?0:null!=r.timeout?r.timeout:y.timeout;let u=!1;if(!i){e.useSSL&&(t=(0,h.hO)(t)),r.cacheBust&&"default"===n.cache&&(t=(0,h.ZN)(t,"request.preventCache",Date.now()));let i={...r.query};e.credentialToken&&(i.token=e.credentialToken);let o=(0,h.B7)(i);(0,a.Z)("esri-url-encodes-apostrophe")&&(o=o.replace(/'/g,"%27"));const l=t.length+1+o.length;let c;u="delete"===r.method||"post"===r.method||"put"===r.method||!!r.body||l>y.maxUrlLength;const d=r.useProxy||!!(0,h.ed)(t);if(d){const e=(0,h.b7)(t);c=e.path,!u&&c.length+1+l>y.maxUrlLength&&(u=!0),e.query&&(i={...e.query,...i})}if("HEAD"===n.method&&(u||d)){if(u){if(l>y.maxUrlLength)throw E("request:invalid-parameters",new Error("URL exceeds maximum length"),e.params);throw E("request:invalid-parameters",new Error("cannot use POST request when method is 'head'"),e.params)}if(d)throw E("request:invalid-parameters",new Error("cannot use proxy when method is 'head'"),e.params)}if(u?(n.method="delete"===r.method?"DELETE":"put"===r.method?"PUT":"POST",r.body?t=(0,h.fl)(t,i):(n.body=(0,h.B7)(i),n.headers["Content-Type"]="application/x-www-form-urlencoded")):t=(0,h.fl)(t,i),d&&(e.useProxy=!0,t=`${c}?${t}`),i.token&&g&&n.body instanceof FormData){const e=n.body;e.set?e.set("token",i.token):e.append("token",i.token)}if(r.hasOwnProperty("withCredentials"))e.withCredentials=r.withCredentials;else if(!(0,h.D6)(t,h.Gd))if((0,h.kl)(t))e.withCredentials=!0;else if(s.id){const r=s.id.findServerInfo(t);r&&r.webTierAuth&&(e.withCredentials=!0)}e.withCredentials&&(n.credentials="include")}let d,p,m=0,b=!1;l>0&&(m=setTimeout((()=>{b=!0,e.controller.abort()}),l));try{if("native-request-init"===r.responseType)p=n,p.url=t;else if("image"!==r.responseType||"default"!==n.cache||"GET"!==n.method||u||function(e){if(e)for(const t of Object.getOwnPropertyNames(e))if(e[t])return!0;return!1}(r.headers)||!i&&!e.useProxy&&y.proxyUrl&&!C(t)){if(d=await f._abortableFetch(t,n),e.useProxy||function(e){const t=(0,h.P$)(e);t&&!f._corsServers.includes(t)&&f._corsServers.push(t)}(t),"native"===r.responseType)p=d;else if("HEAD"!==n.method)if(d.ok){switch(o){case"array-buffer":p=await d.arrayBuffer();break;case"blob":case"image":p=await d.blob();break;default:p=await d.text()}if(m&&(clearTimeout(m),m=0),"json"===o||"xml"===o||"document"===o)if(p)switch(o){case"json":p=JSON.parse(p);break;case"xml":p=I(p,"application/xml");break;case"document":p=I(p,"text/html")}else p=null;if(p){if("array-buffer"===o||"blob"===o){const e=d.headers.get("Content-Type");if(/application\/json|text\/plain/i.test(e)&&p["blob"===o?"size":"byteLength"]<=750)try{const e=await new Response(p).json();e.error&&(p=e)}catch{}}"image"===o&&p instanceof Blob&&(p=await U(URL.createObjectURL(p),e,!0))}}else p=await d.text()}else p=await U(t,e)}catch(n){if("AbortError"===n.name){if(b)throw new Error("Timeout exceeded");throw(0,c.zE)("Request canceled")}if(!(!d&&n instanceof TypeError&&y.proxyUrl)||r.body||"delete"===r.method||"head"===r.method||"post"===r.method||"put"===r.method||e.useProxy||C(t))throw n;e.redoRequest=!0,(0,h.tD)({proxyUrl:y.proxyUrl,urlPrefix:(0,h.P$)(t)})}finally{m&&clearTimeout(m)}return[d,p]}function I(e,t){let r;try{r=(new DOMParser).parseFromString(e,t)}catch{}if(!r||r.getElementsByTagName("parsererror").length)throw new SyntaxError("XML Parse error");return r}async function q(e,t,r){if(e.redoRequest)return e.redoRequest=!1,!1;const n=e.params.requestOptions;if(!t||"native"===n.responseType||"native-request-init"===n.responseType)return!0;let i,o,a,l;if(!t.ok)throw i=new Error(`Unable to load ${t.url} status: ${t.status}`),i[x]=r,i;null!=r&&r.error&&(i=r.error),i&&(o=Number(i.code),a=i.hasOwnProperty("subcode")?Number(i.subcode):null,l=i.messageCode,l=l&&l.toUpperCase());const u=n.authMode;if(403===o&&(4===a||i.message&&i.message.toLowerCase().indexOf("ssl")>-1&&-1===i.message.toLowerCase().indexOf("permission"))){if(!e.useSSL)return e.useSSL=!0,!1}else if(!e.hasToken&&e.useIdentity&&("no-prompt"!==u||498===o)&&-1!==b.indexOf(o)&&!O(e.params.url)&&(403!==o||-1===v.indexOf(l)&&(null==a||2===a&&e.credentialToken))){await M();try{const t=await s.id.getCredential(e.params.url,{error:E("request:server",i,e.params),prompt:"no-prompt"!==u,signal:e.controller.signal,token:e.credentialToken});return e.credential=t,e.credentialToken=t.token,e.useSSL=e.useSSL||t.ssl,!1}catch(t){if("no-prompt"===u)return e.credential=null,e.credentialToken=null,!1;i=t}}if(i)throw i;return!0}function U(e,t,r=!1){const n=t.controller.signal,s=new Image;return t.withCredentials?s.crossOrigin="use-credentials":s.crossOrigin="anonymous",s.alt="",s.src=e,(0,p.f)(s,e,r,n)}f._abortableFetch=null,f._corsServers=["https://server.arcgisonline.com","https://services.arcgisonline.com"]},71058:(e,t,r)=>{r.d(t,{r:()=>i});var n=r(17452);const s=["elevation3d.arcgis.com","js.arcgis.com","jsdev.arcgis.com","jsqa.arcgis.com","static.arcgis.com"];function i(e){const t=(0,n.P$)(e,!0);return t&&t.endsWith(".arcgis.com")&&!s.includes(t)&&!e.endsWith("/sharing/rest/generateToken")}},85958:(e,t,r)=>{r.d(t,{f:()=>o});var n=r(80442),s=r(70586),i=r(95330);function o(e,t,r=!1,o){return new Promise(((l,u)=>{if((0,i.Hc)(o))return void u(a());let c=()=>{p(),u(new Error(`Unable to load ${t}`))},h=()=>{const t=e;p(),l(t)},d=()=>{if(!e)return;const t=e;p(),t.src="",u(a())};const p=()=>{(0,n.Z)("esri-image-decode")||(e.removeEventListener("error",c),e.removeEventListener("load",h)),c=null,h=null,e=null,(0,s.pC)(o)&&o.removeEventListener("abort",d),d=null,r&&URL.revokeObjectURL(t)};(0,s.pC)(o)&&o.addEventListener("abort",d),(0,n.Z)("esri-image-decode")?e.decode().then(h,c):(e.addEventListener("error",c),e.addEventListener("load",h))}))}function a(){try{return new DOMException("Aborted","AbortError")}catch{const e=new Error;return e.name="AbortError",e}}},89749:(e,t,r)=>{r.d(t,{t:()=>p});var n=r(43697),s=r(15923),i=r(61247),o=r(70586),a=r(17445),l=r(90584),u=r(43050),c=r(67723),h=r(5600),d=r(52011);let p=class extends s.Z{constructor(){super(...arguments),this.updating=!1,this.handleId=0,this.handles=new i.Z,this.scheduleHandleId=0,this.pendingPromises=new Set}destroy(){this.removeAll(),this.handles.destroy()}add(e,t,r,n=0){const s=0!=(1&n),i=++this.handleId;s||this.installSyncUpdatingWatch(e,t,i);const o=0!=(2&n)?(0,u.S1)(e,t,r,s):e.watch(t,r,s);return this.handles.add(o,i),{remove:()=>this.handles.remove(i)}}addOnCollectionPropertyChange(e,t,r,n=0){const s=0!=(2&n),i=++this.handleId;return this.handles.add([(0,u.on)(e,t,"after-changes",this.createSyncUpdatingCallback()),(0,u.on)(e,t,"change",r,s?e=>{r({added:e.items,removed:[],moved:[],target:e})}:void 0)],i),{remove:()=>{this.handles.remove(i)}}}addOnCollectionChange(e,t,r=0){const n=0!=(2&r),s=++this.handleId;return this.handles.add([e.on("after-changes",this.createSyncUpdatingCallback()),e.on("change",t)],s),n&&t({added:e.items,removed:[],moved:[],target:e}),{remove:()=>{this.handles.remove(s)}}}addPromise(e){if((0,o.Wi)(e))return e;const t=++this.handleId;this.handles.add({remove:()=>{this.pendingPromises.delete(e)&&(0!==this.pendingPromises.size||this.handles.has(f)||this._set("updating",!1))}},t),this.pendingPromises.add(e),this._set("updating",!0);const r=()=>this.handles.remove(t);return e.then(r,r),e}removeAll(){this.pendingPromises.clear(),this.handles.removeAll(),this._set("updating",!1)}installSyncUpdatingWatch(e,t,r){const n=this.createSyncUpdatingCallback(),s=(0,a.Ym)((()=>(0,c.$z)(e,t)),n,{sync:!0,equals:()=>!1});return this.handles.add(s,r),s}createSyncUpdatingCallback(){return()=>{this.handles.remove(f),++this.scheduleHandleId;const e=this.scheduleHandleId;this._get("updating")||this._set("updating",!0),this.handles.add((0,l.Os)((()=>{e===this.scheduleHandleId&&(this._set("updating",this.pendingPromises.size>0),this.handles.remove(f))})),f)}}};(0,n._)([(0,h.Cb)({readOnly:!0})],p.prototype,"updating",void 0),p=(0,n._)([(0,d.j)("esri.views.support.WatchUpdatingTracking")],p);const f=-42}}]);