@arcgis/core 5.0.0-next.42 → 5.0.0-next.43

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (89) hide show
  1. package/arcade/featureset/sources/FeatureLayerOGC.js +1 -1
  2. package/assets/esri/core/workers/RemoteClient.js +1 -1
  3. package/assets/esri/core/workers/chunks/00ff4ca88c9d291d82c3.js +1 -0
  4. package/assets/esri/core/workers/chunks/04a0685ee53ef74883aa.js +1 -0
  5. package/assets/esri/core/workers/chunks/{c320a29df40e85fb4a8e.js → 15a0750c10b510564a42.js} +1 -1
  6. package/assets/esri/core/workers/chunks/{816227de5bd42b437df4.js → 233f9eb617f3d72995b5.js} +1 -1
  7. package/assets/esri/core/workers/chunks/{fb9643b74cf35221ff98.js → 249504f7d356be80d214.js} +1 -1
  8. package/assets/esri/core/workers/chunks/{9d95f38da21f97214f83.js → 324d66962aeec17d3e28.js} +10 -10
  9. package/assets/esri/core/workers/chunks/385cfd3087f00dbd1146.js +1 -0
  10. package/assets/esri/core/workers/chunks/{4f4d51181ae7db9fbe6d.js → 4404b6f931f681cca342.js} +1 -1
  11. package/assets/esri/core/workers/chunks/555a0ea44ba77819d493.js +1 -0
  12. package/assets/esri/core/workers/chunks/6e8925412fb90f88d688.js +1 -0
  13. package/assets/esri/core/workers/chunks/83da9ee6544ee9d3c124.js +1 -0
  14. package/assets/esri/core/workers/chunks/{da517b4b07d4d27ce94c.js → 8e26831f71634288f834.js} +1 -1
  15. package/assets/esri/core/workers/chunks/{c367c7e553be3682f2db.js → 93c5f097bb7b380bb175.js} +1 -1
  16. package/assets/esri/core/workers/chunks/9c7682b300b877f60095.js +1 -0
  17. package/assets/esri/core/workers/chunks/{f3b3b193959db809c8c6.js → ab520fd1ae917daf07d8.js} +1 -1
  18. package/assets/esri/core/workers/chunks/{2c9865e34f32fb5683e5.js → af8d6e6949930d0e6c7b.js} +1 -1
  19. package/assets/esri/core/workers/chunks/c9942ca57f542582ab4d.js +1 -0
  20. package/assets/esri/core/workers/chunks/da2ba40bc017bff0fe49.js +1 -0
  21. package/assets/esri/core/workers/chunks/e5a6a646f27715152714.js +1 -0
  22. package/assets/esri/core/workers/chunks/e8a9971c8354569cb81d.js +1 -0
  23. package/assets/esri/core/workers/chunks/ed550bf27f2bbf8d30fa.js +1 -0
  24. package/assets/esri/core/workers/chunks/ee186ddbb1eb5144a790.js +1 -0
  25. package/assets/esri/core/workers/chunks/{1357cc637524cd254974.js → ffcdc7ae03b0570e0db8.js} +1 -1
  26. package/assets/esri/themes/base/widgets/_Attribution.scss +1 -1
  27. package/assets/esri/themes/dark/main.css +1 -1
  28. package/assets/esri/themes/light/main.css +1 -1
  29. package/assets/esri/themes/light/view.css +1 -1
  30. package/config.js +1 -1
  31. package/core/PooledArray.js +1 -1
  32. package/geometry/FlatGeometry.js +1 -1
  33. package/geometry/support/MeshMaterialMetallicRoughness.js +1 -1
  34. package/geometry/support/meshUtils/exporters/gltf/gltf.js +1 -1
  35. package/geometry/support/meshUtils/loadGLTFMesh.js +1 -1
  36. package/interfaces.d.ts +31 -35
  37. package/kernel.js +1 -1
  38. package/layers/graphics/controllers/I3SOnDemandController.js +1 -1
  39. package/layers/graphics/sources/support/clientSideDefaults.js +1 -1
  40. package/package.json +1 -1
  41. package/support/revision.js +1 -1
  42. package/views/2d/engine/webgl/cpuMapped/MappedMesh.js +1 -1
  43. package/views/2d/engine/webgl/shaderGraph/typed/TypedShaderProgram.js +1 -1
  44. package/views/2d/engine/webgl/textureUtils.js +1 -1
  45. package/views/2d/layers/MediaLayerView2D.js +1 -1
  46. package/views/2d/layers/TileLayerView2D.js +1 -1
  47. package/views/3d/glTF/LoaderResult.js +1 -1
  48. package/views/3d/glTF/internal/Resource.js +1 -1
  49. package/views/3d/glTF/loader.js +1 -1
  50. package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
  51. package/views/3d/layers/graphics/Graphics3DExtrudeSymbolLayer.js +1 -1
  52. package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
  53. package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
  54. package/views/3d/layers/graphics/Graphics3DPathSymbolLayer.js +1 -1
  55. package/views/3d/layers/graphics/objectResourceUtils.js +1 -1
  56. package/views/3d/layers/i3s/I3SGraphicsMap.js +1 -1
  57. package/views/3d/layers/i3s/I3SIndex.js +1 -1
  58. package/views/3d/support/buffer/glUtil.js +1 -1
  59. package/views/3d/support/gaussianSplatting/GaussianSplatFadeTexture.js +1 -1
  60. package/views/3d/support/gaussianSplatting/GaussianSplatOrderTexture.js +1 -1
  61. package/views/3d/support/gaussianSplatting/GaussianSplatTextureAtlas.js +1 -1
  62. package/views/3d/webgl-engine/collections/Component/Material/ComponentData.glsl.js +1 -1
  63. package/views/3d/webgl-engine/core/shaderLibrary/TextureBackedBuffer.glsl.js +10 -10
  64. package/views/3d/webgl-engine/lib/edgeRendering/bufferLayouts.js +1 -1
  65. package/views/3d/webgl-engine/lib/edgeRendering/edgeProcessing.js +1 -1
  66. package/views/3d/webgl-engine/materials/DefaultLayouts.js +1 -1
  67. package/views/3d/webgl-engine/materials/DefaultMaterial.js +1 -1
  68. package/views/3d/webgl-engine/materials/PathTechnique.js +1 -1
  69. package/views/3d/webgl-engine/shaders/DefaultMaterialTechnique.js +1 -1
  70. package/views/3d/webgl-engine/shaders/sources/edgeRenderer/EdgeUtil.glsl.js +9 -9
  71. package/views/VideoView.js +1 -1
  72. package/views/webgl/ShaderBuilder.js +1 -1
  73. package/views/webgl/Util.js +1 -1
  74. package/views/webgl/VertexElementDescriptor.js +1 -1
  75. package/widgets/Editor.js +1 -1
  76. package/widgets/VersionManagement/VersionManagementViewModel.js +1 -1
  77. package/assets/esri/core/workers/chunks/0a5427127634738aa239.js +0 -1
  78. package/assets/esri/core/workers/chunks/110429583b28c28c36ee.js +0 -1
  79. package/assets/esri/core/workers/chunks/145c6a7cdcc9893efb27.js +0 -1
  80. package/assets/esri/core/workers/chunks/1bacdd17e199e22b5cd1.js +0 -1
  81. package/assets/esri/core/workers/chunks/1d566539ff6fb6ac798c.js +0 -1
  82. package/assets/esri/core/workers/chunks/5dc0d853c21ccb6054c7.js +0 -1
  83. package/assets/esri/core/workers/chunks/613cbac9cb925cd20b48.js +0 -1
  84. package/assets/esri/core/workers/chunks/800c91302eaad7f00877.js +0 -1
  85. package/assets/esri/core/workers/chunks/c4de24582c29fda5a033.js +0 -1
  86. package/assets/esri/core/workers/chunks/d786b17cc9062b1450ac.js +0 -1
  87. package/assets/esri/core/workers/chunks/d9958654c6438f28237b.js +0 -1
  88. package/assets/esri/core/workers/chunks/e6fa6f9c278589c8a713.js +0 -1
  89. package/assets/esri/core/workers/chunks/e7f4d135ef9665de1468.js +0 -1
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2593],{18251:(t,e,r)=>{r.d(e,{A:()=>l});var s=r(31635),n=r(69540),a=r(25482),i=r(91429),o=r(51850),u=r(93223);let l=class extends((0,n.OU)(a.o)){constructor(t){super(t),this.type="local",this.origin=(0,o.vt)()}};(0,s.Cg)([(0,u.e)({local:"local"},{readOnly:!0})],l.prototype,"type",void 0),(0,s.Cg)([(0,i.MZ)({type:[Number],nonNullable:!0,json:{write:!0}})],l.prototype,"origin",void 0),l=(0,s.Cg)([(0,i.$K)("esri.geometry.support.MeshLocalVertexSpace")],l)},20615:(t,e,r)=>{r.d(e,{I:()=>i});var s=r(2272),n=r(80893),a=r(61956);function i(t,e,r,i){return(0,n.gW)((0,s.Dl)(t),a.A.from(e),r,i)}},24770:(t,e,r)=>{r.d(e,{$I:()=>m,AU:()=>h,g7:()=>f,i4:()=>c,ui:()=>p,up:()=>b,vt:()=>l,yo:()=>y});var s=r(34727),n=r(58083),a=r(67026),i=r(82534),o=r(38954),u=r(51850);function l(t=b){return[t[0],t[1],t[2],t[3]]}function c(t,e,r=l()){return(0,o.d)(r,t),r[3]=e,r}function p(t,e=l()){const r=(0,n.l)(M,t);return g(e,(0,s.KJ)((0,a.Xd)(e,r))),e}function d(t,e,r=l()){return(0,a.x8)(M,t,m(t)),(0,a.x8)(A,e,m(e)),(0,a.lw)(M,A,M),g(r,(0,s.KJ)((0,a.Xd)(r,M)))}function h(t,e,r,s=l()){return c(u.Cw,t,S),c(u.JP,e,_),c(u.Cb,r,v),d(S,_,S),d(S,v,s),s}function y(t){return t}function f(t){return t[3]}function m(t){return(0,s.kU)(t[3])}function g(t,e){return t[3]=e,t}const b=[0,0,1,0],M=(0,i.vt)(),A=(0,i.vt)(),S=(l(),l()),_=l(),v=l()},27615:(t,e,r)=>{r.d(e,{CK:()=>u,Hq:()=>o,MW:()=>l,TE:()=>c,yJ:()=>p});var s=r(38954),n=r(86738),a=r(95696),i=r(18251);function o(t){return null!=t.origin}function u(t){return o(t.vertexSpace)}function l(t,e){if(!o(t))return null;const[r,s,a]=t.origin;return new n.A({x:r,y:s,z:a,spatialReference:e})}function c(t,e){const{x:r,y:s,z:n,spatialReference:o}=t,u=[r,s,n??0];return"local"===(e?.vertexSpace??function(t){return t.isGeographic||t.isWebMercator?"local":"georeferenced"}(o))?new i.A({origin:u}):new a.A({origin:u})}function p(t,e){return t.type===e.type&&(t.origin===e.origin||null!=t.origin&&null!=e.origin&&(0,s.m)(t.origin,e.origin))}},38954:(t,e,r)=>{r.d(e,{A:()=>c,B:()=>p,C:()=>b,D:()=>E,E:()=>A,F:()=>P,G:()=>G,H:()=>J,a:()=>D,b:()=>a,c:()=>g,d:()=>i,e:()=>l,f:()=>x,g:()=>q,h:()=>o,i:()=>u,j:()=>m,l:()=>w,m:()=>T,n:()=>v,o:()=>_,p:()=>F,q:()=>S,r:()=>I,s:()=>M,t:()=>R,u:()=>d,v:()=>j,w:()=>U,x:()=>f,y:()=>y,z:()=>h});var s=r(51850),n=r(34304);function a(t){const e=t[0],r=t[1],s=t[2];return Math.sqrt(e*e+r*r+s*s)}function i(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function o(t,e,r,s){return t[0]=e,t[1]=r,t[2]=s,t}function u(t,e,r){return t[0]=e[0]+r[0],t[1]=e[1]+r[1],t[2]=e[2]+r[2],t}function l(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t[2]=e[2]-r[2],t}function c(t,e,r){return t[0]=e[0]*r[0],t[1]=e[1]*r[1],t[2]=e[2]*r[2],t}function p(t,e,r){return t[0]=e[0]/r[0],t[1]=e[1]/r[1],t[2]=e[2]/r[2],t}function d(t,e){return t[0]=Math.abs(e[0]),t[1]=Math.abs(e[1]),t[2]=Math.abs(e[2]),t}function h(t,e){return t[0]=Math.sign(e[0]),t[1]=Math.sign(e[1]),t[2]=Math.sign(e[2]),t}function y(t,e,r){return t[0]=Math.min(e[0],r[0]),t[1]=Math.min(e[1],r[1]),t[2]=Math.min(e[2],r[2]),t}function f(t,e,r){return t[0]=Math.max(e[0],r[0]),t[1]=Math.max(e[1],r[1]),t[2]=Math.max(e[2],r[2]),t}function m(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t}function g(t,e,r,s){return t[0]=e[0]+r[0]*s,t[1]=e[1]+r[1]*s,t[2]=e[2]+r[2]*s,t}function b(t,e){const r=e[0]-t[0],s=e[1]-t[1],n=e[2]-t[2];return Math.sqrt(r*r+s*s+n*n)}function M(t,e){const r=e[0]-t[0],s=e[1]-t[1],n=e[2]-t[2];return r*r+s*s+n*n}function A(t){const e=t[0],r=t[1],s=t[2];return e*e+r*r+s*s}function S(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t}function _(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t}function v(t,e){const r=e[0],s=e[1],n=e[2];let a=r*r+s*s+n*n;return a>0&&(a=1/Math.sqrt(a),t[0]=e[0]*a,t[1]=e[1]*a,t[2]=e[2]*a),t}function q(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function x(t,e,r){const s=e[0],n=e[1],a=e[2],i=r[0],o=r[1],u=r[2];return t[0]=n*u-a*o,t[1]=a*i-s*u,t[2]=s*o-n*i,t}function w(t,e,r,s){const n=e[0],a=e[1],i=e[2];return t[0]=n+s*(r[0]-n),t[1]=a+s*(r[1]-a),t[2]=i+s*(r[2]-i),t}function F(t,e,r){const s=e[0],n=e[1],a=e[2];return t[0]=r[0]*s+r[4]*n+r[8]*a+r[12],t[1]=r[1]*s+r[5]*n+r[9]*a+r[13],t[2]=r[2]*s+r[6]*n+r[10]*a+r[14],t}function R(t,e,r){const s=e[0],n=e[1],a=e[2];return t[0]=s*r[0]+n*r[3]+a*r[6],t[1]=s*r[1]+n*r[4]+a*r[7],t[2]=s*r[2]+n*r[5]+a*r[8],t}function I(t,e,r){const s=r[0],n=r[1],a=r[2],i=r[3],o=e[0],u=e[1],l=e[2],c=n*l-a*u,p=a*o-s*l,d=s*u-n*o,h=n*d-a*p,y=a*c-s*d,f=s*p-n*c,m=2*i;return t[0]=o+c*m+2*h,t[1]=u+p*m+2*y,t[2]=l+d*m+2*f,t}const C=(0,s.vt)(),O=(0,s.vt)();function T(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]}function P(t,e){if(t===e)return!0;const r=t[0],s=t[1],a=t[2],i=e[0],o=e[1],u=e[2],l=(0,n.FD)();return Math.abs(r-i)<=l*Math.max(1,Math.abs(r),Math.abs(i))&&Math.abs(s-o)<=l*Math.max(1,Math.abs(s),Math.abs(o))&&Math.abs(a-u)<=l*Math.max(1,Math.abs(a),Math.abs(u))}function E(t,e,r){const s=r[0]-e[0],n=r[1]-e[1],a=r[2]-e[2];let i=s*s+n*n+a*a;return i>0?(i=1/Math.sqrt(i),t[0]=s*i,t[1]=n*i,t[2]=a*i,t):(t[0]=0,t[1]=0,t[2]=0,t)}const D=l,N=c,Q=p,G=b,j=M,J=a,U=A;Object.freeze(Object.defineProperty({__proto__:null,abs:d,add:u,angle:function(t,e){v(C,t),v(O,e);const r=q(C,O);return r>1?0:r<-1?Math.PI:Math.acos(r)},bezier:function(t,e,r,s,n,a){const i=1-a,o=i*i,u=a*a,l=o*i,c=3*a*o,p=3*u*i,d=u*a;return t[0]=e[0]*l+r[0]*c+s[0]*p+n[0]*d,t[1]=e[1]*l+r[1]*c+s[1]*p+n[1]*d,t[2]=e[2]*l+r[2]*c+s[2]*p+n[2]*d,t},ceil:function(t,e){return t[0]=Math.ceil(e[0]),t[1]=Math.ceil(e[1]),t[2]=Math.ceil(e[2]),t},clamp:function(t,e=0,r=1){return t[0]=Math.min(Math.max(t[0],e),r),t[1]=Math.min(Math.max(t[1],e),r),t[2]=Math.min(Math.max(t[2],e),r),t},copy:i,cross:x,crossAndNormalize:function(t,e,r){const s=e[0],n=e[1],a=e[2],i=r[0],o=r[1],u=r[2],l=n*u-a*o,c=a*i-s*u,p=s*o-n*i,d=Math.sqrt(l*l+c*c+p*p);return t[0]=l/d,t[1]=c/d,t[2]=p/d,t},direction:E,dist:G,distance:b,div:Q,divide:p,dot:q,equals:P,exactEquals:T,floor:function(t,e){return t[0]=Math.floor(e[0]),t[1]=Math.floor(e[1]),t[2]=Math.floor(e[2]),t},hermite:function(t,e,r,s,n,a){const i=a*a,o=i*(2*a-3)+1,u=i*(a-2)+a,l=i*(a-1),c=i*(3-2*a);return t[0]=e[0]*o+r[0]*u+s[0]*l+n[0]*c,t[1]=e[1]*o+r[1]*u+s[1]*l+n[1]*c,t[2]=e[2]*o+r[2]*u+s[2]*l+n[2]*c,t},inverse:_,len:J,length:a,lerp:w,max:f,min:y,mul:N,multiply:c,negate:S,normalize:v,random:function(t,e=1){const r=n.Ov,s=2*r()*Math.PI,a=2*r()-1,i=Math.sqrt(1-a*a)*e;return t[0]=Math.cos(s)*i,t[1]=Math.sin(s)*i,t[2]=a*e,t},rotateX:function(t,e,r,s){const n=[],a=[];return n[0]=e[0]-r[0],n[1]=e[1]-r[1],n[2]=e[2]-r[2],a[0]=n[0],a[1]=n[1]*Math.cos(s)-n[2]*Math.sin(s),a[2]=n[1]*Math.sin(s)+n[2]*Math.cos(s),t[0]=a[0]+r[0],t[1]=a[1]+r[1],t[2]=a[2]+r[2],t},rotateY:function(t,e,r,s){const n=[],a=[];return n[0]=e[0]-r[0],n[1]=e[1]-r[1],n[2]=e[2]-r[2],a[0]=n[2]*Math.sin(s)+n[0]*Math.cos(s),a[1]=n[1],a[2]=n[2]*Math.cos(s)-n[0]*Math.sin(s),t[0]=a[0]+r[0],t[1]=a[1]+r[1],t[2]=a[2]+r[2],t},rotateZ:function(t,e,r,s){const n=[],a=[];return n[0]=e[0]-r[0],n[1]=e[1]-r[1],n[2]=e[2]-r[2],a[0]=n[0]*Math.cos(s)-n[1]*Math.sin(s),a[1]=n[0]*Math.sin(s)+n[1]*Math.cos(s),a[2]=n[2],t[0]=a[0]+r[0],t[1]=a[1]+r[1],t[2]=a[2]+r[2],t},round:function(t,e){return t[0]=Math.round(e[0]),t[1]=Math.round(e[1]),t[2]=Math.round(e[2]),t},scale:m,scaleAndAdd:g,set:o,sign:h,sqrDist:j,sqrLen:U,squaredDistance:M,squaredLength:A,str:function(t){return"vec3("+t[0]+", "+t[1]+", "+t[2]+")"},sub:D,subtract:l,transformMat3:R,transformMat4:F,transformQuat:I},Symbol.toStringTag,{value:"Module"}))},63579:(t,e,r)=>{r.d(e,{Bq:()=>u,Qp:()=>o,WN:()=>m,dK:()=>g,eN:()=>h,fH:()=>f,in:()=>y,yr:()=>l});var s=r(11254),n=r(4576),a=(r(44208),r(74887)),i=r(20557);class o{constructor(t,e,r){this.assetName=t,this.assetMimeType=e,this.parts=r}equals(t){return this===t||this.assetName===t.assetName&&this.assetMimeType===t.assetMimeType&&(0,n.aI)(this.parts,t.parts,(t,e)=>t.equals(e))}isOnService(t){return this.parts.every(e=>e.isOnService(t))}makeHash(){let t="";for(const e of this.parts)t+=e.partHash;return t}async toBlob(t){const{parts:e}=this;if(1===e.length)return e[0].toBlob(t);const r=await Promise.all(e.map(e=>e.toBlob(t)));return(0,a.Te)(t),new Blob(r)}}class u{constructor(t,e){this.partUrl=t,this.partHash=e}equals(t){return this===t||this.partUrl===t.partUrl&&this.partHash===t.partHash}isOnService(t){return this.partUrl.startsWith(`${t.path}/assets/`)}async toBlob(t){const{data:e}=await(0,s.A)(this.partUrl,{responseType:"blob"});return(0,a.Te)(t),e}}function l(t){return function(t){switch(t?.type){case"client":return Array.isArray(t.files)?t.files.some(d):d(t.files);case"service":return t.assets.some(d);case"loadable":return!0;default:return!1}}(t?.source)}const c=/^(model\/gltf\+json)|(model\/gltf-binary)$/,p=/\.(gltf|glb)/i;function d(t){if(t instanceof File){const{type:e,name:r}=t;return c.test(e)||p.test(r)}return c.test(t.assetMimeType)||p.test(t.assetName)}function h(t,e){if(!t)return!1;const{source:r}=t;return function(t,e){return"service"===t.type&&t.assets.every(t=>t.isOnService(e))}(r,e)}function y(t,e){if(t===e)return!0;const{source:r}=t,{source:s}=e;if(r===s)return!0;if("service"===r.type&&"service"===s.type){if(r.assets.length!==s.assets.length)return!1;const t=(t,e)=>t.assetName<e.assetName?-1:t.assetName>e.assetName?1:0,e=[...r.assets].sort(t),n=[...s.assets].sort(t);for(let t=0;t<e.length;++t)if(!e[t].equals(n[t]))return!1;return!0}return!1}function f(t,e){return t instanceof File?(0,i.rq)(t,e):(0,i.z$)(t.assetMimeType,t.assetName,e)}function m(t){switch(t.type){case"client":return Array.isArray(t.files)?t.files:[t.files];case"service":return t.assets;case"loadable":return}}function g(t){return!!t.original}},64314:(t,e,r)=>{r.d(e,{A:()=>O});var s=r(31635),n=r(69622),a=r(49186),i=r(44208),o=r(74887),u=r(84952),l=r(91429),c=r(21325),p=r(20557),d=r(27733),h=r(2272),y=r(20615),f=r(74910),m=r(78286),g=r(99199),b=r(97768),M=r(62815),A=r(90708);function S(t,e){return e}function _(t,e,r,s){switch(r){case 0:return w(t,e+s,0);case 1:return"lowerLeft"===t.originPosition?w(t,e+s,1):function({translate:t,scale:e},r,s){return t[s]-r*e[s]}(t,e+s,1)}}function v(t,e,r,s){return 2===r?w(t,e,2):_(t,e,r,s)}function q(t,e,r,s){return 2===r?0===e?0:w(t,e,3):_(t,e,r,s)}function x(t,e,r,s){return 3===r?0===e?0:w(t,e,3):v(t,e,r,s)}function w({translate:t,scale:e},r,s){return t[s]+r*e[s]}class F{constructor(t){this._options=t,this.geometryTypes=["esriGeometryPoint","esriGeometryMultipoint","esriGeometryPolyline","esriGeometryPolygon"],this._previousCoordinate=[0,0],this._transform=null,this._applyTransform=S,this._lengths=[],this._currentLengthIndex=0,this._toAddInCurrentPath=0,this._vertexDimension=0,this._mValueOffset=null,this._coordinateBuffer=null,this._coordinateBufferPtr=0,this._attributesConstructor=class{}}createFeatureResult(){return{fields:[],features:[]}}finishFeatureResult(t){if(this._options.applyTransform&&(t.transform=null),this._attributesConstructor=class{},this._coordinateBuffer=null,this._lengths.length=0,!t.hasZ)return;const e=(0,M.N)(t.geometryType,this._options.sourceSpatialReference,t.spatialReference);if(null!=e)for(const r of t.features)e(r.geometry)}createSpatialReference(){return{}}addField(t,e){const r=t.fields;(0,b.Lw)(r),r.push(e);const s=r.map(t=>t.name);this._attributesConstructor=function(){for(const t of s)this[t]=null}}addFeature(t,e){t.features.push(e)}prepareFeatures(t){switch(this._transform=t.transform,this._options.applyTransform&&t.transform&&(this._applyTransform=this._deriveApplyTransform(t)),this._mValueOffset=null,this._vertexDimension=2,t.hasZ&&this._vertexDimension++,t.hasM&&(this._mValueOffset=this._vertexDimension,this._vertexDimension++),t.geometryType){case"esriGeometryPoint":this.addCoordinate=(t,e,r)=>this.addCoordinatePoint(t,e,r),this.createGeometry=t=>this.createPointGeometry(t);break;case"esriGeometryPolygon":this.addCoordinate=(t,e,r)=>this._addCoordinatePolygon(t,e,r),this.createGeometry=t=>this._createPolygonGeometry(t);break;case"esriGeometryPolyline":this.addCoordinate=(t,e,r)=>this._addCoordinatePolyline(t,e,r),this.createGeometry=t=>this._createPolylineGeometry(t);break;case"esriGeometryMultipoint":this.addCoordinate=(t,e,r)=>this._addCoordinateMultipoint(t,e,r),this.createGeometry=t=>this._createMultipointGeometry(t)}}createFeature(){return this._lengths.length=0,this._currentLengthIndex=0,this._previousCoordinate[0]=0,this._previousCoordinate[1]=0,this._coordinateBuffer=null,this._coordinateBufferPtr=0,{attributes:new this._attributesConstructor}}allocateCoordinates(){}addLength(t,e,r){0===this._lengths.length&&(this._toAddInCurrentPath=e),this._lengths.push(e)}addQueryGeometry(t,e){const{queryGeometry:r,queryGeometryType:s}=e,n=r.justXY();this._transform&&(0,A.aQ)(n,this._transform);const a=(0,A.zv)(n,s,!1,!1);t.queryGeometryType=s,t.queryGeometry={...a}}createPointGeometry(t){const e={x:0,y:0,spatialReference:t.spatialReference};return t.hasZ&&(e.z=0),t.hasM&&(e.m=0),e}addCoordinatePoint(t,e,r){const s=this._transform;switch(e=this._applyTransform(s,e,r,0),r){case 0:t.x=e;break;case 1:t.y=e;break;case 2:"z"in t?t.z=e:t.m=e;break;case 3:t.m=e}}_transformPathLikeValue(t,e){let r=0;e<=1&&(r=this._previousCoordinate[e],this._previousCoordinate[e]+=t);const s=this._transform;return null!==this._mValueOffset&&0===t&&e>0&&!(e%this._mValueOffset)?0:this._applyTransform(s,t,e,r)}_addCoordinatePolyline(t,e,r){this._dehydratedAddPointsCoordinate(t.paths,e,r)}_addCoordinatePolygon(t,e,r){this._dehydratedAddPointsCoordinate(t.rings,e,r)}_addCoordinateMultipoint(t,e,r){0===r&&t.points.push([]);const s=this._transformPathLikeValue(e,r);t.points[t.points.length-1].push(s)}_createPolygonGeometry(t){return{rings:[[]],spatialReference:t.spatialReference,hasZ:!!t.hasZ,hasM:!!t.hasM}}_createPolylineGeometry(t){return{paths:[[]],spatialReference:t.spatialReference,hasZ:!!t.hasZ,hasM:!!t.hasM}}_createMultipointGeometry(t){return{points:[],spatialReference:t.spatialReference,hasZ:!!t.hasZ,hasM:!!t.hasM}}_dehydratedAddPointsCoordinate(t,e,r){0===r&&0===this._toAddInCurrentPath--&&(t.push([]),this._toAddInCurrentPath=this._lengths[++this._currentLengthIndex]-1,this._previousCoordinate[0]=0,this._previousCoordinate[1]=0);const s=this._transformPathLikeValue(e,r),n=t[t.length-1];0===r&&(this._coordinateBufferPtr=0,this._coordinateBuffer=new Array(this._vertexDimension),n.push(this._coordinateBuffer)),this._coordinateBuffer[this._coordinateBufferPtr++]=s}_deriveApplyTransform(t){const{hasZ:e,hasM:r}=t;return e&&r?x:e?v:r?q:_}}var R=r(80893),I=r(22671),C=r(61956);let O=class extends n.A{constructor(t){super(t),this.dynamicDataSource=null,this.fieldsIndex=null,this.gdbVersion=null,this.infoFor3D=null,this.pbfSupported=!1,this.queryAttachmentsSupported=!1,this.sourceSpatialReference=null,this.uniqueIdFields=null,this.url=null}get parsedUrl(){return(0,u.An)(this.url)}async execute(t,e){const r=await this.executeJSON(t,e);return this.featureSetFromJSON(t,r,e)}async executeJSON(t,e){const r=this._normalizeQuery(t),s=null!=t.outStatistics?.[0],n=(0,i.A)("featurelayer-pbf-statistics"),a=(!s||n)&&!0!==t.returnTrueCurves;let o;if(this.pbfSupported&&a)try{o=await async function(t,e,r,s){const n=(0,h.Dl)(t),a={...r},i=C.A.from(e),o=!i.quantizationParameters;return await(0,R.IJ)(n,i,new F({sourceSpatialReference:i.sourceSpatialReference,applyTransform:o}),a,s)}(this.url,r,e,{uniqueIdFields:this.uniqueIdFields})}catch(t){if("query:parsing-pbf"!==t.name)throw t;this.pbfSupported=!1}return this.pbfSupported&&a||(o=await(0,g.e)(this.url,r,e,{uniqueIdFields:this.uniqueIdFields})),this._normalizeFields(o.fields),o}async featureSetFromJSON(t,e,s){if(!this._queryGet3DObjectFormat(t)||null==this.infoFor3D||!e.features)return I.A.fromJSON(e);const{meshFeatureSetFromJSON:n}=await(0,o.qr)(Promise.all([r.e(8487),r.e(36),r.e(5066)]).then(r.bind(r,40050)),s);return n(t,this.infoFor3D,e)}executeForCount(t,e){return(0,y.I)(this.url,this._normalizeQuery(t),e,{uniqueIdFields:this.uniqueIdFields})}executeForExtent(t,e){return(0,f.L)(this.url,this._normalizeQuery(t),e)}executeForIds(t,e){return(0,m.V)(this.url,this._normalizeQuery(t),e,{uniqueIdFields:this.uniqueIdFields})}async executeRelationshipQuery(t,e){const[{default:s},{executeRelationshipQuery:n}]=await(0,o.qr)(Promise.all([Promise.resolve().then(r.bind(r,26591)),r.e(1763).then(r.bind(r,71763))]),e);let a=s.from(t);return(this.gdbVersion||this.dynamicDataSource)&&(a=a.clone(),a.gdbVersion=a.gdbVersion||this.gdbVersion,a.dynamicDataSource=a.dynamicDataSource||this.dynamicDataSource),n(this.url,a,e)}async executeRelationshipQueryForCount(t,e){const[{default:s},{executeRelationshipQueryForCount:n}]=await(0,o.qr)(Promise.all([Promise.resolve().then(r.bind(r,26591)),r.e(1763).then(r.bind(r,71763))]),e);let a=s.from(t);return(this.gdbVersion||this.dynamicDataSource)&&(a=a.clone(),a.gdbVersion=a.gdbVersion||this.gdbVersion,a.dynamicDataSource=a.dynamicDataSource||this.dynamicDataSource),n(this.url,a,e)}async executeAttachmentQuery(t,e){const{executeAttachmentQuery:s,fetchAttachments:n,processAttachmentQueryResult:a}=await(0,o.qr)(r.e(9239).then(r.bind(r,9239)),e),i=(0,h.Dl)(this.url);return a(i,await(this.queryAttachmentsSupported?s(i,t,e):n(i,t,e)))}async executeAttributeBinsQuery(t,e){const{executeAttributeBinsQuery:s}=await(0,o.qr)(r.e(3103).then(r.bind(r,33103)),e);return s(this.parsedUrl,t,e)}async executePivotQuery(t,e){const{executePivotQuery:s}=await(0,o.qr)(r.e(566).then(r.bind(r,80566)),e);return s(this.parsedUrl,t,e)}async executeTopFeaturesQuery(t,e){const{executeTopFeaturesQuery:s}=await(0,o.qr)(r.e(1273).then(r.bind(r,11273)),e);return s(this.parsedUrl,t,this.sourceSpatialReference,e)}async executeForTopIds(t,e){const{executeForTopIds:s}=await(0,o.qr)(r.e(1277).then(r.bind(r,21277)),e);return s(this.parsedUrl,t,e)}async executeForTopExtents(t,e){const{executeForTopExtents:s}=await(0,o.qr)(r.e(8018).then(r.bind(r,8018)),e);return s(this.parsedUrl,t,e)}async executeForTopCount(t,e){const{executeForTopCount:s}=await(0,o.qr)(r.e(980).then(r.bind(r,10980)),e);return s(this.parsedUrl,t,e)}_normalizeQuery(t){let e=C.A.from(t);e.sourceSpatialReference=e.sourceSpatialReference||this.sourceSpatialReference,(this.gdbVersion||this.dynamicDataSource)&&(e=e===t?e.clone():e,e.gdbVersion=t.gdbVersion||this.gdbVersion,e.dynamicDataSource=t.dynamicDataSource?d.L.from(t.dynamicDataSource):this.dynamicDataSource);const{infoFor3D:r}=this,s=this._queryGet3DObjectFormat(t);if(null!=r&&s){if(e=e===t?e.clone():e,e.formatOf3DObjects=s,e.outSpatialReference&&!(0,c.aI)(e.outSpatialReference,this.sourceSpatialReference))throw new a.A("query:unsupported-out-spatial-reference","3D object feature services do not support projection of geometries");if(null==e.outFields||!e.outFields.includes("*")){e=e===t?e.clone():e,null==e.outFields&&(e.outFields=[]);const{originX:s,originY:n,originZ:a,translationX:i,translationY:o,translationZ:u,scaleX:l,scaleY:c,scaleZ:p,rotationX:d,rotationY:h,rotationZ:y,rotationDeg:f}=r.transformFieldRoles;e.outFields.push(s,n,a,i,o,u,l,c,p,d,h,y,f)}}return e}_normalizeFields(t){if(null!=this.fieldsIndex&&null!=t)for(const e of t){const t=this.fieldsIndex.get(e.name);t&&Object.assign(e,t.toJSON())}}_queryGet3DObjectFormat({returnGeometry:t,multipatchOption:e,outStatistics:r}){return!0!==t||"xyFootprint"===e||r?null:(0,p.Hz)(this.infoFor3D)}};(0,s.Cg)([(0,l.MZ)({type:d.L})],O.prototype,"dynamicDataSource",void 0),(0,s.Cg)([(0,l.MZ)()],O.prototype,"fieldsIndex",void 0),(0,s.Cg)([(0,l.MZ)()],O.prototype,"gdbVersion",void 0),(0,s.Cg)([(0,l.MZ)()],O.prototype,"infoFor3D",void 0),(0,s.Cg)([(0,l.MZ)({readOnly:!0})],O.prototype,"parsedUrl",null),(0,s.Cg)([(0,l.MZ)()],O.prototype,"pbfSupported",void 0),(0,s.Cg)([(0,l.MZ)()],O.prototype,"queryAttachmentsSupported",void 0),(0,s.Cg)([(0,l.MZ)()],O.prototype,"sourceSpatialReference",void 0),(0,s.Cg)([(0,l.MZ)()],O.prototype,"uniqueIdFields",void 0),(0,s.Cg)([(0,l.MZ)({type:String})],O.prototype,"url",void 0),O=(0,s.Cg)([(0,l.$K)("esri.layers.graphics.sources.support.QueryTask")],O)},64714:(t,e,r)=>{r.d(e,{F0:()=>o,Vx:()=>c,e2:()=>d,f:()=>h});var s=r(44208),n=r(4718),a=r(99352),i=r(93470);function o(t){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===t||"esriGeometryMultipoint"===t?i.Cb:"esriGeometryPolyline"===t?i.yM:i.WR}}}const u=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let l=1;function c(t,e){if((0,s.A)("esri-csp-restrictions"))return()=>({[e]:null,...t});try{let r=`this${p(e)} = null;`;for(const e in t)r+=`this${p(e)} = ${JSON.stringify(t[e])};`;const s=new Function(`\n return class AttributesClass$${l++} {\n constructor() {\n ${r};\n }\n }\n `)();return()=>new s}catch(r){return()=>({[e]:null,...t})}}function p(t){return u.test(t)?`.${t}`:`[${JSON.stringify(t)}]`}function d(t={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,n.o8)(t)}}]}function h(t,e){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:t},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:e,supportsDelete:e,supportsEditing:e,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:e,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:a.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:a.P,editing:{supportsGeometryUpdate:e,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},67026:(t,e,r)=>{r.d(e,{A6:()=>f,Xd:()=>c,Xr:()=>h,hZ:()=>g,lw:()=>p,t2:()=>R,x8:()=>l});var s=r(29242),n=r(82534),a=r(51850),i=r(34304),o=r(38954),u=r(87317);function l(t,e,r){r*=.5;const s=Math.sin(r);return t[0]=s*e[0],t[1]=s*e[1],t[2]=s*e[2],t[3]=Math.cos(r),t}function c(t,e){const r=2*Math.acos(e[3]),s=Math.sin(r/2);return s>(0,i.FD)()?(t[0]=e[0]/s,t[1]=e[1]/s,t[2]=e[2]/s):(t[0]=1,t[1]=0,t[2]=0),r}function p(t,e,r){const s=e[0],n=e[1],a=e[2],i=e[3],o=r[0],u=r[1],l=r[2],c=r[3];return t[0]=s*c+i*o+n*l-a*u,t[1]=n*c+i*u+a*o-s*l,t[2]=a*c+i*l+s*u-n*o,t[3]=i*c-s*o-n*u-a*l,t}function d(t,e,r,s){const n=e[0],a=e[1],o=e[2],u=e[3];let l,c,p,d,h,y=r[0],f=r[1],m=r[2],g=r[3];return c=n*y+a*f+o*m+u*g,c<0&&(c=-c,y=-y,f=-f,m=-m,g=-g),1-c>(0,i.FD)()?(l=Math.acos(c),p=Math.sin(l),d=Math.sin((1-s)*l)/p,h=Math.sin(s*l)/p):(d=1-s,h=s),t[0]=d*n+h*y,t[1]=d*a+h*f,t[2]=d*o+h*m,t[3]=d*u+h*g,t}function h(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t[3]=e[3],t}function y(t,e){const r=e[0]+e[4]+e[8];let s;if(r>0)s=Math.sqrt(r+1),t[3]=.5*s,s=.5/s,t[0]=(e[5]-e[7])*s,t[1]=(e[6]-e[2])*s,t[2]=(e[1]-e[3])*s;else{let r=0;e[4]>e[0]&&(r=1),e[8]>e[3*r+r]&&(r=2);const n=(r+1)%3,a=(r+2)%3;s=Math.sqrt(e[3*r+r]-e[3*n+n]-e[3*a+a]+1),t[r]=.5*s,s=.5/s,t[3]=(e[3*n+a]-e[3*a+n])*s,t[n]=(e[3*n+r]+e[3*r+n])*s,t[a]=(e[3*a+r]+e[3*r+a])*s}return t}function f(t,e,r,s){const n=.5*Math.PI/180;e*=n,r*=n,s*=n;const a=Math.sin(e),i=Math.cos(e),o=Math.sin(r),u=Math.cos(r),l=Math.sin(s),c=Math.cos(s);return t[0]=a*u*c-i*o*l,t[1]=i*o*c+a*u*l,t[2]=i*u*l-a*o*c,t[3]=i*u*c+a*o*l,t}const m=u.f,g=u.c,b=u.i,M=p,A=u.s,S=u.h,_=u.l,v=u.j,q=v,x=u.d,w=x,F=u.n,R=u.a,I=u.e,C=(0,a.vt)(),O=(0,a.fA)(1,0,0),T=(0,a.fA)(0,1,0),P=(0,n.vt)(),E=(0,n.vt)(),D=(0,s.vt)();Object.freeze(Object.defineProperty({__proto__:null,add:b,calculateW:function(t,e){const r=e[0],s=e[1],n=e[2];return t[0]=r,t[1]=s,t[2]=n,t[3]=Math.sqrt(Math.abs(1-r*r-s*s-n*n)),t},conjugate:h,copy:m,dot:S,equals:I,exactEquals:R,fromEuler:f,fromMat3:y,getAxisAngle:c,identity:function(t){return t[0]=0,t[1]=0,t[2]=0,t[3]=1,t},invert:function(t,e){const r=e[0],s=e[1],n=e[2],a=e[3],i=r*r+s*s+n*n+a*a,o=i?1/i:0;return t[0]=-r*o,t[1]=-s*o,t[2]=-n*o,t[3]=a*o,t},len:q,length:v,lerp:_,mul:M,multiply:p,normalize:F,random:function(t){const e=i.Ov,r=e(),s=e(),n=e(),a=Math.sqrt(1-r),o=Math.sqrt(r);return t[0]=a*Math.sin(2*Math.PI*s),t[1]=a*Math.cos(2*Math.PI*s),t[2]=o*Math.sin(2*Math.PI*n),t[3]=o*Math.cos(2*Math.PI*n),t},rotateX:function(t,e,r){r*=.5;const s=e[0],n=e[1],a=e[2],i=e[3],o=Math.sin(r),u=Math.cos(r);return t[0]=s*u+i*o,t[1]=n*u+a*o,t[2]=a*u-n*o,t[3]=i*u-s*o,t},rotateY:function(t,e,r){r*=.5;const s=e[0],n=e[1],a=e[2],i=e[3],o=Math.sin(r),u=Math.cos(r);return t[0]=s*u-a*o,t[1]=n*u+i*o,t[2]=a*u+s*o,t[3]=i*u-n*o,t},rotateZ:function(t,e,r){r*=.5;const s=e[0],n=e[1],a=e[2],i=e[3],o=Math.sin(r),u=Math.cos(r);return t[0]=s*u+n*o,t[1]=n*u-s*o,t[2]=a*u+i*o,t[3]=i*u-a*o,t},rotationTo:function(t,e,r){const s=(0,o.g)(e,r);return s<-.999999?((0,o.f)(C,O,e),(0,o.H)(C)<1e-6&&(0,o.f)(C,T,e),(0,o.n)(C,C),l(t,C,Math.PI),t):s>.999999?(t[0]=0,t[1]=0,t[2]=0,t[3]=1,t):((0,o.f)(C,e,r),t[0]=C[0],t[1]=C[1],t[2]=C[2],t[3]=1+s,F(t,t))},scale:A,set:g,setAxes:function(t,e,r,s){const n=D;return n[0]=r[0],n[3]=r[1],n[6]=r[2],n[1]=s[0],n[4]=s[1],n[7]=s[2],n[2]=-e[0],n[5]=-e[1],n[8]=-e[2],F(t,y(t,n))},setAxisAngle:l,slerp:d,sqlerp:function(t,e,r,s,n,a){return d(P,e,n,a),d(E,r,s,a),d(t,P,E,2*a*(1-a)),t},sqrLen:w,squaredLength:x,str:function(t){return"quat("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+")"}},Symbol.toStringTag,{value:"Module"}))},72593:(t,e,r)=>{r.r(e),r.d(e,{default:()=>$});var s=r(31635),n=r(92602),a=r(11254),i=r(4576),o=r(49186),u=r(44208),l=r(66552),c=r(92474),p=r(53966),d=r(93637),h=r(74887),y=r(36708),f=r(84952),m=r(13069),g=r(91429),b=r(5443),M=r(16930),A=r(95696),S=r(27615),_=r(63579),v=r(52106),q=r(86211),x=r(91218),w=r(65864),F=r(73836),R=r(21325),I=r(78628);async function C(t,e,r){const{geometry:s}=e,n={...e.attributes};if(null!=r&&"mesh"===s?.type){const{transformFieldRoles:e}=r,{origin:a,spatialReference:i,vertexSpace:o}=s,u=s.transform??new F.A,l="local"===o.type,c=t.spatialReference,p=c.isGeographic,d=(0,R.aI)(c,i),h=(0,x.isEqualBaseGCS)(i,c)&&(0,x.canProjectWithoutEngine)(i,c);if(!(l&&p&&h||!l&&!p&&d))return null;const y=(0,x.projectWithoutEngine)(a,i,c);if(null==y)return null;if(n[e.originX]=y.x,n[e.originY]=y.y,n[e.originZ]=y.z??0,null!=u){const{translation:t,scale:r,rotation:s}=u,a=l?1:(0,q.KX)(i)/(0,q.KX)(c);n[e.translationX]=t[0]*a,n[e.translationY]=t[2]*a,n[e.translationZ]=-t[1]*a,n[e.scaleX]=r[0],n[e.scaleY]=r[2],n[e.scaleZ]=r[1],n[e.rotationX]=s[0],n[e.rotationY]=s[2],n[e.rotationZ]=-s[1],n[e.rotationDeg]=s[3]}return{attributes:n}}return null==s?{attributes:n}:"mesh"===s.type||"extent"===s.type?null:{geometry:s.toJSON(),attributes:n}}async function O(t,e){const r=await Promise.all((e.addAttachments??[]).map(e=>T(t,e))),s=await Promise.all((e.updateAttachments??[]).map(e=>T(t,e))),n=e.deleteAttachments??[];return r.length||s.length||n.length?{adds:r,updates:s,deletes:[...n]}:null}async function T(t,e){const{feature:r,attachment:s}=e,{globalId:n,name:a,contentType:i,data:o,uploadId:u}=s,l={globalId:n};if(r&&("attributes"in r?l.parentGlobalId=r.attributes?.[t.globalIdField]:r.globalId&&(l.parentGlobalId=r.globalId)),u)l.uploadId=u;else if(o){const t=await(0,f._0)(o);t&&(l.contentType=t.mediaType,l.data=t.data),o instanceof File&&(l.name=o.name)}return a&&(l.name=a),i&&(l.contentType=i),l}function P(t){const e=!0===t.success?null:t.error||{code:void 0,description:"Feature edit failed"};return{objectId:t.objectId,globalId:t.globalId,error:e?new o.A("feature-layer-source:edit-failure",e.description,{code:e.code}):null}}function E(t,e){return new v.A({attributes:t.attributes,geometry:(0,w.rS)({...t.geometry,spatialReference:e})})}function D(t,e){return{adds:t?.adds?.map(t=>E(t,e))||[],updates:t?.updates?.map(t=>({original:E(t[0],e),current:E(t[1],e)}))||[],deletes:t?.deletes?.map(t=>E(t,e))||[],spatialReference:e}}var N=r(64714),Q=r(64314),G=r(60694),j=r(15426),J=r(20557),U=r(99199),Z=r(96520),k=r(61956),B=r(79677),L=r(20816);const V=new l.J({originalAndCurrentFeatures:"original-and-current-features",none:"none"}),z=new l.J({Started:"published",Publishing:"publishing",Stopped:"unavailable"});let $=class extends c.x_{constructor(t){super(t),this.type="feature-layer",this.supportedSourceTypes=new Set(["Feature Layer","Oriented Imagery Layer","Table","Catalog Layer"]),this.refresh=(0,h.sg)(async()=>{await this.load();const t=this.sourceJSON.editingInfo?.lastEditDate;if(null==t)return{dataChanged:!0,updates:{}};try{await this._fetchService(null)}catch{return{dataChanged:!0,updates:{}}}const e=t!==this.sourceJSON.editingInfo?.lastEditDate;return{dataChanged:e,updates:e?{editingInfo:this.sourceJSON.editingInfo,extent:this.sourceJSON.extent}:null}}),this._ongoingAssetUploads=new Map}load(t){const e=this.layer.sourceJSON,r=this._fetchService(e,{...t}).then(()=>this.layer.setUserPrivileges(this.sourceJSON.serviceItemId,t)).then(()=>this._ensureLatestMetadata(t));return this.addResolvingPromise(r),Promise.resolve(this)}initialize(){this.addHandles([(0,y.wB)(()=>{const t=this.layer;return t&&"lastEditsEventDate"in t?t.lastEditsEventDate:null},t=>this._handleLastEditsEventChange(t))])}destroy(){this._removeEditInterceptor()}get queryTask(){const{capabilities:t,parsedUrl:e,gdbVersion:r,spatialReference:s,fieldsIndex:n,uniqueIdFields:a}=this.layer,i="infoFor3D"in this.layer?this.layer.infoFor3D:null,o="dynamicDataSource"in this.layer?this.layer.dynamicDataSource:null,l=(0,u.A)("featurelayer-pbf")&&t?.query.supportsFormatPBF&&null==i;return new Q.A({dynamicDataSource:o,fieldsIndex:n,gdbVersion:r,infoFor3D:i,pbfSupported:l,queryAttachmentsSupported:t?.operations?.supportsQueryAttachments??!1,sourceSpatialReference:s,uniqueIdFields:a,url:e.path})}async addAttachment(t,e){await this.load();const{layer:r}=this;await(0,j.VA)(r,"editing");const s=t.attributes[r.objectIdField],n=r.parsedUrl.path+"/"+s+"/addAttachment",i=this._getLayerRequestOptions(),o=this._getFormDataForAttachment(e,i.query);try{return P((await(0,a.A)(n,{body:o})).data.addAttachmentResult)}catch(t){throw this._createAttachmentErrorResult(s,t)}}async updateAttachment(t,e,r){await this.load();const{layer:s}=this;await(0,j.VA)(s,"editing");const n=t.attributes[s.objectIdField],i=s.parsedUrl.path+"/"+n+"/updateAttachment",o=this._getLayerRequestOptions({query:{attachmentId:e}}),u=this._getFormDataForAttachment(r,o.query);try{return P((await(0,a.A)(i,{body:u})).data.updateAttachmentResult)}catch(t){throw this._createAttachmentErrorResult(n,t)}}async applyEdits(t,e){await this.load();const{layer:r}=this;await(0,j.VA)(r,"editing");const s="infoFor3D"in r?r.infoFor3D:null,n=null!=s,u=n||(e?.globalIdUsed??!1),l=n?await this._uploadMeshesAndGetAssetMapEditsJSON(t):null,c=t.addFeatures?.map(t=>C(this.layer,t,s))??[],p=(await Promise.all(c)).filter(i.Ru),d=t.updateFeatures?.map(t=>C(this.layer,t,s))??[],h=(await Promise.all(d)).filter(i.Ru),y=function(t,e,r){if(!e||0===e.length)return[];if(r&&(0,I.zp)(e))return e.map(t=>t.globalId);if((0,I.r3)(e))return e.map(t=>t.objectId);const s=r?t.globalIdField:t.objectIdField;return s?e.map(t=>t.getAttribute(s)):[]}(this.layer,t.deleteFeatures,u);(0,Z.u)(p,h,r.spatialReference);const f=await O(this.layer,t),m=r.capabilities.editing.supportsAsyncApplyEdits&&n,g=e?.gdbVersion||r.gdbVersion,b={gdbVersion:g,rollbackOnFailure:e?.rollbackOnFailureEnabled,useGlobalIds:u,returnEditMoment:e?.returnEditMoment,usePreviousEditMoment:e?.usePreviousEditMoment,async:m};await(0,L.ZJ)(this.layer.url,g,!0);const M=(0,L.w5)(this.layer.url,g||null);if(await(0,L.We)(r.url,g,r.historicMoment))throw new o.A("feature-layer-source:historic-version","Editing a historic version is not allowed");e?.returnServiceEditsOption?(b.edits=JSON.stringify([{id:r.layerId,adds:p.length?p:null,updates:h.length?h:null,deletes:y.length?y:null,attachments:f,assetMaps:l}]),b.returnServiceEditsOption=V.toJSON(e?.returnServiceEditsOption),b.returnServiceEditsInSourceSR=e?.returnServiceEditsInSourceSR):(b.adds=p.length?JSON.stringify(p):null,b.updates=h.length?JSON.stringify(h):null,b.deletes=y.length?u?JSON.stringify(y):y.join(","):null,b.attachments=f&&JSON.stringify(f),b.assetMaps=null!=l?JSON.stringify(l):void 0);const A=this._getLayerRequestOptions({method:"post",query:b});M&&(A.authMode="immediate",A.query.returnEditMoment=!0,A.query.sessionId=L.TA);const S=e?.returnServiceEditsOption?r.url:r.parsedUrl.path;let _;try{_=m?await this._asyncApplyEdits(S+"/applyEdits",A):await(0,a.A)(S+"/applyEdits",A)}catch(t){if(!function(t){const e=t.details.raw,r=+e.code,s=+e.extendedCode;return 500===r&&(-2147217144===s||-2147467261===s)}(t))throw t;A.authMode="immediate",_=m?await this._asyncApplyEdits(S+"/applyEdits",A):await(0,a.A)(S+"/applyEdits",A)}return this._createEditsResult(_)}async deleteAttachments(t,e){await this.load();const{layer:r}=this;await(0,j.VA)(r,"editing");const s=t.attributes[r.objectIdField],n=r.parsedUrl.path+"/"+s+"/deleteAttachments";try{return(await(0,a.A)(n,this._getLayerRequestOptions({query:{attachmentIds:e.join(",")},method:"post"}))).data.deleteAttachmentResults.map(P)}catch(t){throw this._createAttachmentErrorResult(s,t)}}fetchRecomputedExtents(t={}){const e=t.signal;return this.load({signal:e}).then(async()=>{const e=this._getLayerRequestOptions({...t,query:{returnUpdates:!0}}),{layerId:r,url:s}=this.layer,{data:n}=await(0,a.A)(`${s}/${r}`,e),{id:i,extent:o,fullExtent:u,timeExtent:l}=n,c=o||u;return{id:i,fullExtent:c&&b.A.fromJSON(c),timeExtent:l&&B.A.fromJSON({start:l[0],end:l[1]})}})}async queryAttachments(t,e={}){await this.load();const r=this._getLayerRequestOptions(e);return this.queryTask.executeAttachmentQuery(t,r)}async queryFeatures(t,e){await this.load();const r=await this.queryTask.execute(t,{...e,query:this._createRequestQueryOptions(e)});if(t.outStatistics?.length&&r.features.length){const e=new Map;if(r.features.forEach(r=>{const s=r.attributes;t.outStatistics?.forEach(({outStatisticFieldName:t})=>{if(t){const r=t.toLowerCase();r&&r in s&&t!==r&&(s[t]=s[r],delete s[r],e.set(r,t))}})}),null!=r.fields)for(const t of r.fields){const r=e.get(t.name.toLowerCase());null!=r&&(t.name=r)}}return r}async queryFeaturesJSON(t,e){return await this.load(),this.queryTask.executeJSON(t,{...e,query:this._createRequestQueryOptions(e)})}async queryObjectIds(t,e){return await this.load(),this.queryTask.executeForIds(t,{...e,query:this._createRequestQueryOptions(e)})}async queryFeatureCount(t,e){return await this.load(),this.queryTask.executeForCount(t,{...e,query:this._createRequestQueryOptions(e)})}async queryExtent(t,e){return await this.load(),this.queryTask.executeForExtent(t,{...e,query:this._createRequestQueryOptions(e)})}async queryRelatedFeatures(t,e){return await this.load(),this.queryTask.executeRelationshipQuery(t,{...e,query:this._createRequestQueryOptions(e)})}async queryRelatedFeaturesCount(t,e){return await this.load(),this.queryTask.executeRelationshipQueryForCount(t,{...e,query:this._createRequestQueryOptions(e)})}async queryPivot(t,e){return await this.load(),this.queryTask.executePivotQuery(t,{...e,query:this._createRequestQueryOptions(e)})}async queryTopFeatures(t,e){return await this.load(),this.queryTask.executeTopFeaturesQuery(t,{...e,query:this._createRequestQueryOptions(e)})}async queryAttributeBins(t,e){return await this.load(),this.queryTask.executeAttributeBinsQuery(t,{...e,query:this._createRequestQueryOptions(e)})}async queryTopObjectIds(t,e){return await this.load(),this.queryTask.executeForTopIds(t,{...e,query:this._createRequestQueryOptions(e)})}async queryTopExtents(t,e){return await this.load(),this.queryTask.executeForTopExtents(t,{...e,query:this._createRequestQueryOptions(e)})}async queryTopCount(t,e){return await this.load(),this.queryTask.executeForTopCount(t,{...e,query:this._createRequestQueryOptions(e)})}async fetchPublishingStatus(){if(!(0,G.Wo)(this.layer.url))return"unavailable";const t=(0,f.fj)(this.layer.url,"status"),e=await(0,a.A)(t,{query:{f:"json"}});return z.fromJSON(e.data.status)}async uploadAssets(t,e){const{uploadAssets:s}=await r.e(1384).then(r.bind(r,31384));return s(t,{layer:this.layer,ongoingUploads:this._ongoingAssetUploads},e)}_handleLastEditsEventChange(t){const e=this.layer;if(null==t||!("capabilities"in e)||!("effectiveCapabilities"in e))return;if(e.capabilities?.operations?.supportsEditing||!e.effectiveCapabilities?.operations?.supportsEditing)return;const r=e.url;null!=r&&("layerId"in e&&(0,f.fj)(r,e.layerId.toString()),this._getOrCreateEditInterceptor(r).before=e=>{const r=e.requestOptions.method??"auto";if("auto"===r||"head"===r){const r=e.requestOptions.query??{};r._ts=t.getTime(),e.requestOptions.query=r}})}_getOrCreateEditInterceptor(t){return null==this._editInterceptor&&(this._editInterceptor={urls:t},n.A.request.internalInterceptors.push(this._editInterceptor)),this._editInterceptor}_removeEditInterceptor(){null!=this._editInterceptor&&((0,i.TF)(n.A.request.internalInterceptors,this._editInterceptor),this._editInterceptor=null)}async _asyncApplyEdits(t,e){const r=(await(0,a.A)(t,e)).data.statusUrl;for(;;){const t=(await(0,a.A)(r,{query:{f:"json"},responseType:"json"})).data;switch(t.status){case"Completed":return(0,a.A)(t.resultUrl,{query:{f:"json"},responseType:"json"});case"CompletedWithErrors":throw new o.A("async-applyEdits-failed","asynchronous applyEdits call failed.");case"Failed ImportChanges":case"InProgress":case"Pending":case"ExportAttachments":case"ExportChanges":case"ExportingData":case"ExportingSnapshot":case"ImportAttachments":case"ProvisioningReplica":case"UnRegisteringReplica":break;default:throw new o.A("async-applyEdits-failed","asynchronous applyEdits call failed (undefined response status)")}await(0,h.Pl)(H)}}_createRequestQueryOptions(t){const e={...this.layer.customParameters,token:this.layer.apiKey,...t?.query};return this.layer.datesInUnknownTimezone&&(e.timeReferenceUnknownClient=!0),e}async _fetchService(t,e){if(!t){const r={};(0,u.A)("featurelayer-advanced-symbols")&&(r.returnAdvancedSymbols=!0),e?.cacheBust&&(r._ts=Date.now());const{data:s}=await(0,a.A)(this.layer.parsedUrl.path,this._getLayerRequestOptions({query:r,signal:e?.signal}));t=s}this.layer.applyPreferredHost(t),this.sourceJSON=await this._patchServiceJSON(t,e?.signal);const r=t.type;if(!this.supportedSourceTypes.has(r))throw new o.A("feature-layer-source:unsupported-type",`Source type "${r}" is not supported`)}async _patchServiceJSON(t,e){if("Table"!==t.type&&t.geometryType&&!t?.drawingInfo?.renderer&&!t.defaultSymbol){const e=(0,N.F0)(t.geometryType).renderer;(0,d.sM)("drawingInfo.renderer",e,t)}if("esriGeometryMultiPatch"===t.geometryType&&t.infoFor3D&&(t.geometryType="mesh"),null==t.extent)try{const{data:r}=await(0,a.A)(this.layer.url,this._getLayerRequestOptions({signal:e}));r.spatialReference&&(t.extent={xmin:0,ymin:0,xmax:0,ymax:0,spatialReference:r.spatialReference})}catch(t){(0,h.QP)(t)}return t}async _ensureLatestMetadata(t){if(this.layer.userHasUpdateItemPrivileges&&this.sourceJSON.cacheMaxAge>0)return this._fetchService(null,{...t,cacheBust:!0})}async _uploadMeshesAndGetAssetMapEditsJSON(t){const{addAssetFeatures:e}=t;if(!e?.length)return null;if(await this._areAllAssetsAlreadyMapped(e))return null;const s=t.addFeatures.filter(t=>t.geometry);if(e.length!==s.length+t.updateFeatures.length)throw new o.A("feature-layer-source:unsupported-mesh-edits","Mixing attribute only edits with mesh geometry edits is not currently supported");const n=new Array,a=new Map;for(const t of e){const{geometry:e}=t,{vertexSpace:s}=e;if((0,S.Hq)(s))n.push(e);else{const s=e.origin,{convertMeshVertexSpace:i}=await Promise.all([r.e(8487),r.e(4496)]).then(r.bind(r,28846)),o=await i(e,new A.A({origin:[s.x,s.y,s.z??0]}));a.set(o,e),t.geometry=o,n.push(o)}}await this.uploadAssets(n);for(const[t,e]of a)e.addExternalSources(t.metadata.externalSources.items);return{adds:this._getAssetMapEditsJSON(e),updates:[],deletes:[]}}_getAssetMapEditsJSON(t){const e=new Array,r=this.layer.globalIdField,s=this.layer.parsedUrl;for(const n of t){const t=n.geometry,{metadata:a}=t,i=a.getExternalSourcesOnService(s),o=n.getAttribute(r);if(0===i.length){p.A.getLogger(this).error(`Skipping feature ${o}. The mesh it is associated with has not been uploaded to the service and cannot be mapped to it.`);continue}const{source:u}=i.find(_.dK)??i[0];for(const t of u.assets)1===t.parts.length?e.push({globalId:(0,m.yS)(),parentGlobalId:o,assetName:t.assetName,assetHash:t.parts[0].partHash,flags:[]}):p.A.getLogger(this).error(`Skipping asset ${t.assetName}. It does not have exactly one part, so we cannot map it to a feature.`)}return e}_createEditsResult(t){const e=t.data,{layerId:r}=this.layer,s=[];let n=null;if(Array.isArray(e))for(const t of e)s.push({id:t.id,editedFeatures:t.editedFeatures}),t.id===r&&(n={addResults:t.addResults??[],updateResults:t.updateResults??[],deleteResults:t.deleteResults??[],attachments:t.attachments,editMoment:t.editMoment});else n=e;const a=function(t){const e=t?.assetMaps;if(e){for(const t of e.addResults)t.success||p.A.getLogger("esri.layers.graphics.sources.support.sourceUtils").error(`Failed to map asset to feature with globalId ${t.globalId}.`);for(const t of e.updateResults)t.success||p.A.getLogger("esri.layers.graphics.sources.support.sourceUtils").error(`Failed to map asset to feature with globalId ${t.globalId}.`)}const r=t?.attachments,s={addFeatureResults:t?.addResults?.map(P)??[],updateFeatureResults:t?.updateResults?.map(P)??[],deleteFeatureResults:t?.deleteResults?.map(P)??[],addAttachmentResults:r?.addResults?r.addResults.map(P):[],updateAttachmentResults:r?.updateResults?r.updateResults.map(P):[],deleteAttachmentResults:r?.deleteResults?r.deleteResults.map(P):[]};return t?.editMoment&&(s.editMoment=t.editMoment),s}(n);if(s.length>0){a.editedFeatureResults=[];for(const t of s){const{editedFeatures:e}=t,r=e?.spatialReference?new M.A(e.spatialReference):null;a.editedFeatureResults.push({layerId:t.id,editedFeatures:D(e,r)})}}return a}_createAttachmentErrorResult(t,e){const r=e.details.messages?.[0]||e.message,s=e.details.httpStatus||e.details.messageCode;return{objectId:t,globalId:null,error:new o.A("feature-layer-source:attachment-failure",r,{code:s})}}_getFormDataForAttachment(t,e){const r=t instanceof FormData?t:t&&t.elements?new FormData(t):null;if(r)for(const t in e){const s=e[t];null!=s&&(r.set?r.set(t,s):r.append(t,s))}return r}_getLayerRequestOptions(t={}){const{layer:e,layer:{parsedUrl:r,gdbVersion:s}}=this;return{...t,query:{gdbVersion:s,layer:"dynamicDataSource"in e&&e.dynamicDataSource?JSON.stringify({source:e.dynamicDataSource}):void 0,...r.query,f:"json",...this._createRequestQueryOptions(t)},responseType:"json"}}async _areAllAssetsAlreadyMapped(t){const{layer:e}=this,{globalIdField:r,parsedUrl:s}=e,n="infoFor3D"in e?e.infoFor3D:null;if(null==n||null==r)return!1;const a=(0,J.JZ)(n);if(null==a)return!1;const o=(0,f.fj)(s.path,`../${a.id}`),u=new Array;for(const e of t){if(!(e.geometry.metadata.getExternalSourcesOnService(s).length>0))return!1;u.push(e)}const l=u.map(t=>t.getAttribute(r)).filter(i.Ru);if(0===l.length)return!1;const{assetMapFieldRoles:{parentGlobalId:c,assetHash:p}}=n,d=new k.A({where:`${c} IN (${l.map(t=>`'${t}'`)})`,outFields:[p,c],returnGeometry:!1}),h=await(0,U.s)(o,d),{features:y}=h;return 0!==y.length&&!u.some(t=>{const e=t.getAttribute(r);if(!e)return!0;const{metadata:n}=t.geometry,a=y.filter(t=>t.getAttribute(c)===e);if(0===a.length)return!0;const i=a.map(t=>t.getAttribute(p));return n.getExternalSourcesOnService(s).flatMap(({source:t})=>t.assets.flatMap(t=>t.parts.map(t=>t.partHash))).some(t=>i.every(e=>t!==e))})}};(0,s.Cg)([(0,g.MZ)()],$.prototype,"type",void 0),(0,s.Cg)([(0,g.MZ)({constructOnly:!0})],$.prototype,"layer",void 0),(0,s.Cg)([(0,g.MZ)({constructOnly:!0})],$.prototype,"supportedSourceTypes",void 0),(0,s.Cg)([(0,g.MZ)({readOnly:!0})],$.prototype,"queryTask",null),$=(0,s.Cg)([(0,g.$K)("esri.layers.graphics.sources.FeatureLayerSource")],$);const H=1e3},73836:(t,e,r)=>{r.d(e,{A:()=>h});var s=r(31635),n=r(69540),a=r(25482),i=r(91429),o=r(58083),u=r(9093),l=r(67026),c=r(82534),p=r(51850),d=r(24770);let h=class extends((0,n.OU)(a.o)){constructor(t){super(t),this.translation=(0,p.vt)(),this.rotationAxis=(0,p.ci)(d.up),this.rotationAngle=0,this.scale=(0,p.fA)(1,1,1)}get rotation(){return(0,d.i4)(this.rotationAxis,this.rotationAngle)}set rotation(t){this.rotationAxis=(0,p.o8)((0,d.yo)(t)),this.rotationAngle=(0,d.g7)(t)}get localMatrix(){const t=(0,u.vt)();return(0,l.x8)(y,(0,d.yo)(this.rotation),(0,d.$I)(this.rotation)),(0,o.o1)(t,y,this.translation,this.scale),t}get localMatrixInverse(){return(0,o.B8)((0,u.vt)(),this.localMatrix)}equals(t){return this===t||null!=t&&(0,o.t2)(this.localMatrix,t.localMatrix)}};(0,s.Cg)([(0,i.MZ)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"translation",void 0),(0,s.Cg)([(0,i.MZ)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"rotationAxis",void 0),(0,s.Cg)([(0,i.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],h.prototype,"rotationAngle",void 0),(0,s.Cg)([(0,i.MZ)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"scale",void 0),(0,s.Cg)([(0,i.MZ)()],h.prototype,"rotation",null),(0,s.Cg)([(0,i.MZ)()],h.prototype,"localMatrix",null),(0,s.Cg)([(0,i.MZ)()],h.prototype,"localMatrixInverse",null),h=(0,s.Cg)([(0,i.$K)("esri.geometry.support.MeshTransform")],h);const y=(0,c.vt)()},74910:(t,e,r)=>{r.d(e,{L:()=>o});var s=r(5443),n=r(2272),a=r(80893),i=r(61956);async function o(t,e,r){const o=(0,n.Dl)(t),u=await(0,a.Jf)(o,i.A.from(e),{...r}),l=u.extent;return!l||isNaN(l.xmin)||isNaN(l.ymin)||isNaN(l.xmax)||isNaN(l.ymax)?{count:u.count,extent:null}:{count:u.count,extent:s.A.fromJSON(l)}}},78286:(t,e,r)=>{r.d(e,{V:()=>i});var s=r(2272),n=r(80893),a=r(61956);async function i(t,e,r,i){const o=(0,s.Dl)(t),u=await(0,n.Pk)(o,a.A.from(e),r,i);return u.objectIds??function(t){if(t)return function(t){return!Array.isArray(t[0])}(t)?t:t.map(t=>JSON.stringify(t))}(u.uniqueIds)??[]}},82534:(t,e,r)=>{function s(){return[0,0,0,1]}function n(t){return[t[0],t[1],t[2],t[3]]}r.d(e,{o8:()=>n,vt:()=>s,zK:()=>a});const a=[0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:a,clone:n,create:s,fromValues:function(t,e,r,s){return[t,e,r,s]}},Symbol.toStringTag,{value:"Module"}))},95696:(t,e,r)=>{r.d(e,{A:()=>l});var s,n=r(31635),a=r(69540),i=r(25482),o=r(91429),u=r(93223);let l=class extends((0,a.OU)(i.o)){static{s=this}constructor(t){super(t),this.type="georeferenced",this.origin=null}static{this.absolute=new s}};(0,n.Cg)([(0,u.e)({georeferenced:"georeferenced"},{readOnly:!0})],l.prototype,"type",void 0),(0,n.Cg)([(0,o.MZ)({type:[Number],nonNullable:!1,json:{write:!0}})],l.prototype,"origin",void 0),l=s=(0,n.Cg)([(0,o.$K)("esri.geometry.support.MeshGeoreferencedVertexSpace")],l)},99199:(t,e,r)=>{r.d(e,{e:()=>u,s:()=>o});var s=r(2272),n=r(80893),a=r(22671),i=r(61956);async function o(t,e,r,s){const n=await u(t,e,r,s);return a.A.fromJSON(n)}function u(t,e,r,a){const o=(0,s.Dl)(t),u={...r},l=i.A.from(e);return(0,n.eW)(o,l,l.sourceSpatialReference,u,a)}},99352:(t,e,r)=>{r.d(e,{F:()=>s,P:()=>n});const s={supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!0,supportsCentroidOnDegeneratedQuantizedGeometry:!0,supportsCacheHint:!0,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDistance:!0,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsPaginationOnAggregatedQueries:!1,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!0,supportsReturnMesh:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,maxUniqueIDCount:void 0,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0,supportsTrueCurve:!1},n={supportsDate:!0,supportsFixedInterval:!0,supportsAutoInterval:!0,supportsFixedBoundaries:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!0,supportedStatistics:{count:!0,sum:!0,avg:!0,var:!0,stddev:!0,min:!0,max:!0,percentileContinuous:!0,percentileDiscrete:!0,envelope:!0,centroid:!0,convexHull:!0},supportedNormalizationTypes:{field:!0,log:!0,naturalLog:!0,percentOfTotal:!0,squareRoot:!0}}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5977],{159:(e,t,n)=>{n.d(t,{A:()=>a});var r,i=n(31635),o=n(69622),s=n(91429),l=n(99157);let a=r=class extends o.A{constructor(e){super(e),this.steps=[]}getInverse(){const e=new r;for(let t=this.steps.length-1;t>=0;t--){const n=this.steps[t];e.steps.push(n.getInverse())}return e}};(0,i.Cg)([(0,s.MZ)({type:[l.A],nonNullable:!0})],a.prototype,"steps",void 0),a=r=(0,i.Cg)([(0,s.$K)("esri.geometry.operators.support.GeographicTransformation")],a)},6455:(e,t,n)=>{n.d(t,{FJ:()=>h,Dp:()=>w,KV:()=>v});var r=n(31635),i=n(93637),o=n(91429),s=n(89317),l=n(69540),a=n(7762),u=n(25482),p=n(83960),c=n(13069);const d={write:{overridePolicy:(e,t,n)=>({enabled:!n||"scale"===n.filterMode})}};let f=class extends((0,l.OU)(u.o)){constructor(e){super(e),this.id=(0,c.lk)(),this.maxScale=0,this.minScale=0,this.title="",this.where=null}};(0,r.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],f.prototype,"id",void 0),(0,r.Cg)([(0,o.MZ)({type:Number,json:d})],f.prototype,"maxScale",void 0),(0,r.Cg)([(0,o.MZ)({type:Number,json:d})],f.prototype,"minScale",void 0),(0,r.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],f.prototype,"title",void 0),(0,r.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],f.prototype,"where",void 0),f=(0,r.Cg)([(0,o.$K)("esri.layers.support.DisplayFilter")],f);var y=n(41560),m=n(43937);let g=class extends((0,l.OU)(u.o)){constructor(e){super(e),this.activeFilterId=null,this.filters=new(a.A.ofType(f)),this.mode="manual"}writeFilters(e,t,n,r){const i=e.toArray();"scale"===this.mode&&i.sort((e,t)=>{const n=(0,p.oW)(t.minScale,e.minScale),r=e.maxScale-t.maxScale;return 0===n?r:n}),t[n]=i.map(e=>e.toJSON(r))}write(e,t){return super.write(e,(0,y.mW)(this,t))}};(0,r.Cg)([(0,o.MZ)({type:String,json:{write:{overridePolicy:(e,t,n)=>({enabled:"manual"===n.filterMode,isRequired:!0})}}})],g.prototype,"activeFilterId",void 0),(0,r.Cg)([(0,o.MZ)({type:a.A.ofType(f),nonNullable:!0,json:{write:!0}})],g.prototype,"filters",void 0),(0,r.Cg)([(0,m.K)("filters")],g.prototype,"writeFilters",null),(0,r.Cg)([(0,o.MZ)({type:["manual","scale"],nonNullable:!0,json:{name:"filterMode",write:!0}})],g.prototype,"mode",void 0),g=(0,r.Cg)([(0,o.$K)("esri.layers.support.DisplayFilterInfo")],g);const h=e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.displayFilterEnabled=!0,this.displayFilterInfo=null}};return(0,r.Cg)([(0,o.MZ)(w)],n.prototype,"displayFilterEnabled",void 0),(0,r.Cg)([(0,o.MZ)(v)],n.prototype,"displayFilterInfo",void 0),n=(0,r.Cg)([(0,o.$K)("esri.layers.mixins.DisplayFilteredLayer")],n),n},w={type:Boolean,json:{name:"layerDefinition.disableDisplayFilter",read:{reader:e=>!e},write:{layerContainerTypes:s.K,writer(e,t,n){(0,i.sM)(n,!e,t)}},origins:{"web-scene":{write:!1,read:!1}}}},v={type:g,json:{name:"layerDefinition.displayFilterInfo",write:{enabled:!0,allowNull:!0,layerContainerTypes:s.K},origins:{"web-scene":{write:!1,read:!1}}}}},8303:(e,t,n)=>{n.d(t,{A:()=>I});var r=n(31635),i=n(92602),o=n(70333),s=n(11254),l=n(60999),a=n(49186),u=n(53966),p=n(97768),c=n(74887),d=n(84952),f=n(91429),y=n(77548),m=n(20655),g=n(80812),h=n(41318),w=n(10407),v=n(36005),C=n(43937);const I=e=>{const t=e;let I=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,p.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}get portalItem(){return this._get("portalItem")}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,n){if(t.itemId)return new g.default({id:t.itemId,portal:n?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:r}=await n.e(1204).then(n.bind(n,41204));return(0,c.Te)(t),await r({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,c.zf)(e)||u.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,c.QP)(e),!0)))}async setUserPrivileges(e,t){if(!i.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:n,fullEdit:r},content:{updateItem:i}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",n),this._set("userHasFullEditingPrivileges",r),this._set("userHasUpdateItemPrivileges",i)}catch(e){(0,c.QP)(e)}}async _fetchUserPrivileges(e,t){let n=this.portalItem;if(!e||!n||!n.loaded||n.sourceUrl)return this._fetchFallbackUserPrivileges(t);const r=!o.id?.findCredential(this.url),i=e===n.id;if(i&&n.portal.user)return this._getUserPrivileges(n,r);let s,l;if(i)s=n.portal.url;else try{s=await(0,y.wI)(this.url,t)}catch(e){(0,c.QP)(e)}if(!s||!(0,d.b8)(s,n.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;l=await(o.id?.getCredential(`${s}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,c.QP)(e)}const a=!0,u=!1,p=!1;if(!l)return{features:{edit:a,fullEdit:u},content:{updateItem:p}};try{if(i?await n.reload():(n=new g.default({id:e,portal:{url:s}}),await n.load(t)),n.portal.user)return this._getUserPrivileges(n,r)}catch(e){(0,c.QP)(e)}return{features:{edit:a,fullEdit:u},content:{updateItem:p}}}_getUserPrivileges(e,t){const n=(0,w.It)(e);return t&&(n.features.edit=!0),n}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,c.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?o.id?.findCredential(this.url):null;if(!t)return!0;const n=M.credential===t?M.user:await this._fetchEditingUser(e);return M.credential=t,M.user=n,null==n?.privileges||n.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const n=o.id?.findServerInfo(this.url??"");if(!n?.owningSystemUrl)return null;const r=`${n.owningSystemUrl}/sharing/rest`,i=m.A.getDefault();if(i&&i.loaded&&(0,d.S8)(i.restUrl)===(0,d.S8)(r))return i.user;const a=`${r}/community/self`,u=null!=e?e.signal:null,p=await(0,l.Ke)((0,s.A)(a,{authMode:"no-prompt",query:{f:"json"},signal:u}));return p.ok?h.A.fromJSON(p.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const n=t?.portal,r=this.portalItem?.id&&(this.portalItem.portal||m.A.getDefault());return n&&r&&!(0,d.ut)(r.restUrl,n.restUrl)?(t.messages&&t.messages.push(new a.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,r.Cg)([(0,f.MZ)({type:g.default})],I.prototype,"portalItem",null),(0,r.Cg)([(0,v.w)("web-document","portalItem",["itemId"])],I.prototype,"readPortalItem",null),(0,r.Cg)([(0,C.K)("web-document","portalItem",{itemId:{type:String}})],I.prototype,"writePortalItem",null),(0,r.Cg)([(0,f.MZ)({clonable:!1})],I.prototype,"resourceReferences",void 0),(0,r.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasEditingPrivileges",void 0),(0,r.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasFullEditingPrivileges",void 0),(0,r.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasUpdateItemPrivileges",void 0),I=(0,r.Cg)([(0,f.$K)("esri.layers.mixins.PortalLayer")],I),I},M={credential:null,user:null}},9762:(e,t,n)=>{n.r(t),n.d(t,{projectBuffer:()=>i});var r=n(37539);function i(e,t,n,i,o,s,l=Math.floor(e.length/3)){const a=(0,r.jd)(t,o);if(null==a)return!1;if(a===r.pO){if(e===i&&n===s)return!0;const t=n+3*l;for(let r=n,o=s;r<t;r++,o++)i[o]=e[r]??0;return!0}const u=n+3*l;for(let t=n,r=s;t<u;t+=3,r+=3)a(e,t,i,r);return!0}},10184:(e,t,n)=>{n.d(t,{A:()=>p});var r=n(31635),i=n(69540),o=n(25482),s=n(88930),l=n(91429),a=n(73133),u=n(93223);let p=class extends((0,i.OU)(o.o)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,s.t)(this.value,this.unit,"milliseconds")}};(0,r.Cg)([(0,u.e)(a.j,{nonNullable:!0})],p.prototype,"unit",void 0),(0,r.Cg)([(0,l.MZ)({type:Number,json:{write:!0},nonNullable:!0})],p.prototype,"value",void 0),p=(0,r.Cg)([(0,l.$K)("esri.time.TimeInterval")],p)},10407:(e,t,n)=>{n.d(t,{It:()=>f,LG:()=>s,OM:()=>u,Sm:()=>p,Y:()=>l,bK:()=>a,mm:()=>d,sQ:()=>c});var r=n(91218),i=n(16930),o=n(28735);function s(e,t){if(!l(e,t)){const n=e.typeKeywords;n?n.push(t):e.typeKeywords=[t]}}function l(e,t){return!!e.typeKeywords?.includes(t)}function a(e){return l(e,d.HOSTED_SERVICE)}function u(e,t){const n=e.typeKeywords;if(n){const e=n.indexOf(t);e>-1&&n.splice(e,1)}}function p(e,t,n){n?s(e,t):u(e,t)}async function c(e){const t=e.clone().normalize();let n;if(t.length>1)for(const e of t)n?e.width>n.width&&(n=e):n=e;else n=t[0];return async function(e){const t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,o.ci)(e);const n=i.A.WGS84;return await(0,r.initializeProjection)(t,n),(0,r.project)(e,n)}(n)}const d={CHARTS:"Charts",DYNAMIC:"Dynamic",DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery"};function f(e){const{portal:t,isOrgItem:n,itemControl:r}=e,i=t.user?.privileges;let o=!i||i.includes("features:user:edit"),s=!!n&&!!i?.includes("features:user:fullEdit");const l="update"===r||"admin"===r;return l?s=o=!0:s&&(o=!0),{features:{edit:o,fullEdit:s},content:{updateItem:l}}}},17036:(e,t,n)=>{n.d(t,{p:()=>a});var r=n(44208),i=n(53966),o=n(20437),s=n(95466),l=n(30524);function a(){return{fields:{type:[o.A],value:null,set:function(e){if(e&&(0,r.A)("big-integer-warning-enabled")){const t=e.filter(e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8);if(t.length){const e=t.map(e=>`'${e.name}'`).join(", ");i.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${Number.MAX_SAFE_INTEGER} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return s.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){const e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(const t of e){const n=this.fieldsIndex?.has(t);n||i.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,l.DB)(this.fieldsIndex,e)}}}}},22671:(e,t,n)=>{n.d(t,{A:()=>h});var r,i=n(31635),o=n(52106),s=n(66552),l=n(25482),a=n(4718),u=n(91429),p=n(16930),c=n(65864),d=n(50498),f=n(20437),y=n(36005),m=n(43937);const g=new s.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let h=r=class extends l.o{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){return this.readFeaturesWithClass(e,t,o.A)}writeGeometryType(e,t,n,r){if(e)return void g.write(e,t,n,r);const{features:i}=this;if(i)for(const e of i)if(null!=e?.geometry)return void g.write(e.geometry.type,t,n,r)}readQueryGeometry(e,t){if(!e)return null;const n=!!e.spatialReference,r=(0,c.rS)(e);return r&&!n&&t.spatialReference&&(r.spatialReference=p.A.fromJSON(t.spatialReference)),r}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:n}=this;if(n)for(const e of n)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new r(this.cloneProperties())}cloneProperties(){return(0,a.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let n=0;n<t.features.length;n++){const r=t.features[n];if(r.geometry){const t=e?.[n];r.geometry=t?.toJSON()||r.geometry}}return t}quantize(e){const{scale:[t,n],translate:[r,i]}=e,o=this.features,s=this._getQuantizationFunction(this.geometryType,e=>Math.round((e-r)/t),e=>Math.round((i-e)/n));for(let e=0,t=o.length;e<t;e++)s?.(o[e].geometry)||(o.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:n}=this;if(!n)return this;const{translate:[r,i],scale:[o,s]}=n;let l=null,a=null;if(this.hasZ&&null!=n?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=n;l=n=>n*t+e}if(this.hasM&&null!=n?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=n;a=n=>null==n?n:n*t+e}const u=this._getHydrationFunction(e,e=>e*o+r,e=>i-e*s,l,a);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}readFeaturesWithClass(e,t,n){const r=p.A.fromJSON(t.spatialReference),i=[];for(let t=0;t<e.length;t++){const o=e[t],s=n.fromJSON(o),l=o.geometry?.spatialReference;null==s.geometry||l||(s.geometry.spatialReference=r);const a=o.aggregateGeometries,u=s.aggregateGeometries;if(a&&null!=u)for(const e in u){const t=u[e],n=a[e],i=n?.spatialReference;null==t||i||(t.spatialReference=r)}i.push(s)}return i}_quantizePoints(e,t,n){let r,i;const o=[];for(let s=0,l=e.length;s<l;s++){const l=e[s];if(s>0){const e=t(l[0]),s=n(l[1]);e===r&&s===i||(o.push([e-r,s-i]),r=e,i=s)}else r=t(l[0]),i=n(l[1]),o.push([r,i])}return o.length>0?o:null}_getQuantizationFunction(e,t,n){return"point"===e?e=>(e.x=t(e.x),e.y=n(e.y),e):"polyline"===e||"polygon"===e?e=>{const r=(0,c.Bi)(e)?e.rings:e.paths,i=[];for(let e=0,o=r.length;e<o;e++){const o=r[e],s=this._quantizePoints(o,t,n);s&&i.push(s)}return i.length>0?((0,c.Bi)(e)?e.rings=i:e.paths=i,e):null}:"multipoint"===e?e=>{const r=this._quantizePoints(e.points,t,n);return r&&r.length>0?(e.points=r,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,n,r,i){return"point"===e?e=>{e.x=t(e.x),e.y=n(e.y),r&&(e.z=r(e.z))}:"polyline"===e||"polygon"===e?e=>{const o=(0,c.Bi)(e)?e.rings:e.paths;let s,l;for(let e=0,r=o.length;e<r;e++){const r=o[e];for(let e=0,i=r.length;e<i;e++){const i=r[e];e>0?(s+=i[0],l+=i[1]):(s=i[0],l=i[1]),i[0]=t(s),i[1]=n(l)}}if(r&&i)for(let e=0,t=o.length;e<t;e++){const t=o[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=r(n[2]),n[3]=i(n[3])}}else if(r)for(let e=0,t=o.length;e<t;e++){const t=o[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=r(n[2])}}else if(i)for(let e=0,t=o.length;e<t;e++){const t=o[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=i(n[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=n(e.ymin),e.xmax=t(e.xmax),e.ymax=n(e.ymax),r&&null!=e.zmax&&null!=e.zmin&&(e.zmax=r(e.zmax),e.zmin=r(e.zmin)),i&&null!=e.mmax&&null!=e.mmin&&(e.mmax=i(e.mmax),e.mmin=i(e.mmin))}:"multipoint"===e?e=>{const o=e.points;let s,l;for(let e=0,r=o.length;e<r;e++){const r=o[e];e>0?(s+=r[0],l+=r[1]):(s=r[0],l=r[1]),r[0]=t(s),r[1]=n(l)}if(r&&i)for(let e=0,t=o.length;e<t;e++){const t=o[e];t[2]=r(t[2]),t[3]=i(t[3])}else if(r)for(let e=0,t=o.length;e<t;e++){const t=o[e];t[2]=r(t[2])}else if(i)for(let e=0,t=o.length;e<t;e++){const t=o[e];t[2]=i(t[2])}}:null}};(0,i.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],h.prototype,"displayFieldName",void 0),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],h.prototype,"exceededTransferLimit",void 0),(0,i.Cg)([(0,u.MZ)({type:[o.A],json:{write:!0}})],h.prototype,"features",void 0),(0,i.Cg)([(0,y.w)("features")],h.prototype,"readFeatures",null),(0,i.Cg)([(0,u.MZ)({type:[f.A],json:{write:!0}})],h.prototype,"fields",void 0),(0,i.Cg)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],h.prototype,"geometryType",void 0),(0,i.Cg)([(0,m.K)("geometryType")],h.prototype,"writeGeometryType",null),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],h.prototype,"hasM",void 0),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],h.prototype,"hasZ",void 0),(0,i.Cg)([(0,u.MZ)({types:d.yR,json:{write:!0}})],h.prototype,"queryGeometry",void 0),(0,i.Cg)([(0,y.w)("queryGeometry")],h.prototype,"readQueryGeometry",null),(0,i.Cg)([(0,u.MZ)({type:p.A,json:{write:!0}})],h.prototype,"spatialReference",void 0),(0,i.Cg)([(0,m.K)("spatialReference")],h.prototype,"writeSpatialReference",null),(0,i.Cg)([(0,u.MZ)({json:{write:!0}})],h.prototype,"transform",void 0),h=r=(0,i.Cg)([(0,u.$K)("esri.rest.support.FeatureSet")],h),h.prototype.toJSON.isDefaultToJSON=!0},29005:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(31635),i=n(69540),o=n(66552),s=n(25482),l=n(91429);const a=new o.J({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let u=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,r.Cg)([(0,l.MZ)({json:{write:!0}})],u.prototype,"name",void 0),(0,r.Cg)([(0,l.MZ)({json:{write:!0}})],u.prototype,"description",void 0),(0,r.Cg)([(0,l.MZ)({json:{read:a.read,write:a.write}})],u.prototype,"drawingTool",void 0),(0,r.Cg)([(0,l.MZ)({json:{write:!0}})],u.prototype,"prototype",void 0),(0,r.Cg)([(0,l.MZ)({json:{write:!0}})],u.prototype,"thumbnail",void 0),u=(0,r.Cg)([(0,l.$K)("esri.layers.support.FeatureTemplate")],u)},32756:(e,t,n)=>{n.d(t,{Rr:()=>l,fY:()=>u,ne:()=>a});var r=n(31635),i=n(93637),o=n(91429),s=n(91880);function l(e,t,n){if(!e)return null;const r=e.find(e=>!!e.field);if(!r)return null;const i=new s.A;return i.read(r,n),[i]}const a={type:[s.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:l},write:{writer:function(e,t,n,r){const o=e.find(e=>!!e.field);o&&(0,i.sM)(n,[o.toJSON()],t)}}}},u=e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,r.Cg)([(0,o.MZ)(a)],n.prototype,"orderBy",void 0),n=(0,r.Cg)([(0,o.$K)("esri.layers.mixins.OrderedLayer")],n),n}},33143:(e,t,n)=>{n.d(t,{A:()=>c});var r=n(31635),i=n(69540),o=n(25482),s=n(91429),l=n(8631),a=n(29005),u=n(36005),p=n(43937);let c=class extends((0,i.OU)(o.o)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const n of Object.keys(e))t[n]=(0,l.rS)(e[n]);return t}writeDomains(e,t){const n={};for(const t of Object.keys(e))e[t]&&(n[t]=e[t]?.toJSON());t.domains=n}};(0,r.Cg)([(0,s.MZ)({json:{write:!0}})],c.prototype,"id",void 0),(0,r.Cg)([(0,s.MZ)({json:{write:!0}})],c.prototype,"name",void 0),(0,r.Cg)([(0,s.MZ)({json:{write:!0}})],c.prototype,"domains",void 0),(0,r.Cg)([(0,u.w)("domains")],c.prototype,"readDomains",null),(0,r.Cg)([(0,p.K)("domains")],c.prototype,"writeDomains",null),(0,r.Cg)([(0,s.MZ)({type:[a.A],json:{write:!0}})],c.prototype,"templates",void 0),c=(0,r.Cg)([(0,s.$K)("esri.layers.support.FeatureType")],c)},37539:(e,t,n)=>{n.d(t,{pO:()=>m,jd:()=>d,Tp:()=>f,w5:()=>c});var r=n(34727),i=n(86211),o=n(73941),s=n(79258);Math.PI;const l=s.$O.radius,a=s.$O.eccentricitySquared,u={a1:l*a,a2:l*a*l*a,a3:l*a*a/2,a4:l*a*l*a*2.5,a5:l*a+l*a*a/2,a6:1-a};s.$O.radius,s.$O.flattening,s.Sw.radius,s.Sw.flattening,s.sH.radius,s.sH.flattening,s.sH.radius;var p=n(21325);const c={2:{5:m,7:null,9:null,10:m,1:S,6:null,8:null,0:null,3:h,11:w,2:m,4:F},5:{5:m,7:null,9:null,10:m,1:S,6:null,8:null,0:null,3:h,11:w,2:m,4:F},7:{5:null,7:m,9:null,10:m,1:null,6:M,8:null,0:null,3:null,11:null,2:null,4:null},9:{5:null,7:null,9:m,10:m,1:null,6:null,8:I,0:null,3:null,11:null,2:null,4:null},3:{5:g,7:null,9:null,10:g,1:function(e,t,n,r){const i=e[t]/E,o=Z-2*Math.atan(Math.exp(-e[t+1]/E)),s=E+(e[t+2]??0),l=Math.cos(o)*s;n[r]=Math.cos(i)*l,n[r+1]=Math.sin(i)*l,n[r+2]=Math.sin(o)*s},6:null,8:null,0:null,3:m,11:function(e,t,n,r){g(e,t,n,r),w(n,r,n,r)},2:g,4:function(e,t,n,r){g(e,t,n,r),F(n,r,n,r)}},4:{5:P,7:null,9:null,10:P,1:function(e,t,n,r){P(e,t,n,r),S(n,r,n,r)},6:null,8:null,0:null,3:function(e,t,n,r){P(e,t,n,r),h(n,r,n,r)},11:function(e,t,n,r){P(e,t,n,r),w(n,r,n,r)},2:P,4:m},1:{5:A,7:null,9:null,10:A,1:m,6:null,8:null,0:null,3:function(e,t,n,r){A(e,t,n,r),h(n,r,n,r)},11:function(e,t,n,r){A(e,t,n,r),w(n,r,n,r)},2:A,4:function(e,t,n,r){A(e,t,n,r),F(n,r,n,r)}},6:{5:null,7:b,9:null,10:b,1:null,6:m,8:null,0:null,3:null,11:null,2:null,4:null},8:{5:null,7:null,9:x,10:x,1:null,6:null,8:m,0:null,3:null,11:null,2:null,4:null},0:{5:null,7:null,9:null,10:null,1:null,6:null,8:null,0:m,3:null,11:null,2:null,4:null},10:{5:m,7:m,9:m,10:m,1:S,6:M,8:I,0:null,3:h,11:w,2:m,4:F},11:{5:v,7:null,9:null,10:v,1:function(e,t,n,r){v(e,t,n,r),S(n,r,n,r)},6:null,8:null,0:null,3:function(e,t,n,r){v(e,t,n,r),h(n,r,n,r)},11:m,2:v,4:function(e,t,n,r){v(e,t,n,r),F(n,r,n,r)}}};function d(e,t){return f(e,t)?.projector}function f(e,t){if(null==e||null==t)return null;if(j.source.spatialReference===e&&j.dest.spatialReference===t)return j;const n=y(e,j.source),r=y(t,j.dest);return 0===n&&0===r?(0,p.aI)(e,t)?j.projector=m:j.projector=null:j.projector=c[n][r],j}function y(e,t){return e?t.spatialReference===e?t.spatialReferenceId:(t.spatialReference=e,"metersPerUnit"in t&&(t.metersPerUnit=(0,i.GA)(e,1)),(0,o.jA)(e)?t.spatialReferenceId=1:(0,p.oT)(e)?t.spatialReferenceId=2:(0,p.K8)(e)?t.spatialReferenceId=3:(0,p.r1)(e)?t.spatialReferenceId=11:e.wkt===o.Ro.wkt?t.spatialReferenceId=4:4490===e.wkid?t.spatialReferenceId=5:e.wkt===o.FY.wkt?t.spatialReferenceId=6:e.wkt===o.LJ.wkt?t.spatialReferenceId=8:(0,p.q8)(e)?t.spatialReferenceId=7:(0,p.KQ)(e)?t.spatialReferenceId=9:t.spatialReferenceId=0):0}function m(e,t,n,r){e!==n&&(n[r++]=e[t++],n[r++]=e[t++],n[r]=e[t]??0)}function g(e,t,n,r){n[r]=O*(e[t]/E),n[r+1]=O*(Z-2*Math.atan(Math.exp(-e[t+1]/E))),n[r+2]=e[t+2]??0}function h(e,t,n,i){!function(e,t,n,i,o){const s=.4999999*Math.PI,l=(0,r.qE)(R*e[t+1],-s,s),a=Math.sin(l);n[i++]=R*e[t]*o.radius,n[i++]=o.halfSemiMajorAxis*Math.log((1+a)/(1-a)),n[i]=e[t+2]??0}(e,t,n,i,s.$O)}function w(e,t,n,r){n[r]=e[t]*N,n[r+1]=e[t+1]*N,n[r+2]=e[t+2]??0}function v(e,t,n,r){n[r]=e[t]*D,n[r+1]=e[t+1]*D,n[r+2]=e[t+2]??0}function C(e,t,n,r,i){const o=i+(e[t+2]??0),s=R*e[t],l=R*e[t+1],a=Math.cos(l)*o;n[r]=Math.cos(s)*a,n[r+1]=Math.sin(s)*a,n[r+2]=Math.sin(l)*o}function I(e,t,n,r){C(e,t,n,r,s.Sw.radius)}function M(e,t,n,r){C(e,t,n,r,s.sH.radius)}function S(e,t,n,r){C(e,t,n,r,s.$O.radius)}function T(e,t,n,i,o){const s=e[t],l=e[t+1],a=e[t+2]??0,u=Math.sqrt(s*s+l*l+a*a),p=(0,r.YN)(a/(0===u?1:u)),c=Math.atan2(l,s);n[i++]=O*c,n[i++]=O*p,n[i]=u-o}function x(e,t,n,r){T(e,t,n,r,s.Sw.radius)}function b(e,t,n,r){T(e,t,n,r,s.sH.radius)}function A(e,t,n,r){T(e,t,n,r,s.$O.radius)}function F(e,t,n,r){!function(e,t,n,r,i){const o=R*e[t],s=R*e[t+1],l=e[t+2]??0,a=Math.sin(s),u=Math.cos(s),p=i.radius/Math.sqrt(1-i.eccentricitySquared*a*a);n[r++]=(p+l)*u*Math.cos(o),n[r++]=(p+l)*u*Math.sin(o),n[r++]=(p*(1-i.eccentricitySquared)+l)*a}(e,t,n,r,s.$O)}function P(e,t,n,r){const i=u,o=e[t],l=e[t+1],a=e[t+2]??0;let p,c,d,f,y,m,g,h,w,v,C,I,M,S,T,x,b,A,F,P,j;p=Math.abs(a),c=o*o+l*l,d=Math.sqrt(c),f=c+a*a,y=Math.sqrt(f),P=Math.atan2(l,o),m=a*a/f,g=c/f,S=i.a2/y,T=i.a3-i.a4/y,g>.3?(h=p/y*(1+g*(i.a1+S+m*T)/y),F=Math.asin(h),v=h*h,w=Math.sqrt(1-v)):(w=d/y*(1-m*(i.a5-S-g*T)/y),F=Math.acos(w),v=1-w*w,h=Math.sqrt(v)),C=1-s.$O.eccentricitySquared*v,I=s.$O.radius/Math.sqrt(C),M=i.a6*I,S=d-I*w,T=p-M*h,b=w*S+h*T,x=w*T-h*S,A=x/(M/C+b),F+=A,j=b+x*A/2,a<0&&(F=-F),n[r++]=O*P,n[r++]=O*F,n[r]=j}const j={source:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},dest:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},projector:m},R=(0,r.kU)(1),O=(0,r.KJ)(1),Z=.5*Math.PI,E=s.$O.radius,N=E*Math.PI/180,D=180/(E*Math.PI)},41560:(e,t,n)=>{n.d(t,{Ch:()=>s,mW:()=>o});var r=n(34727),i=n(39516);function o(e,t){return{...t,filterMode:e.mode}}function s(e,t,n){const o=function(e){if("manual"===u(e))return null;const t=[Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY];for(const{minScale:n,maxScale:r}of e.filters)t[0]=Math.max(t[0],p(n)),t[1]=Math.min(t[1],c(r));return t}(e);if(o&&((0,r.gg)(t,o[0])||(0,r.ZH)(n,o[1])))return"";const s=Array.from(l(e,t,n)),a=function(e,t,n){if(0===e.length)return!0;const i=p(e.at(0)?.minScale),o=c(e.at(-1)?.maxScale);if((0,r.ZH)(i,t)||(0,r.gg)(o,n))return!0;for(let t=0;t<e.length-1;t++){const n=e[t],i=e[t+1];if((0,r.ZH)(p(i.minScale),c(n.maxScale)))return!0}return!1}(s,t,n)?"1=1":s.map(e=>e.where||"1=1").reduce((e,t)=>(0,i.IW)(e,t),"");return a&&"1=1"!==a?a:""}function*l(e,t,n){if("manual"===u(e)){const t=e.filters.find(t=>t.id===e.activeFilterId);t&&(yield t)}else{"object"==typeof t&&(t=t.scale);for(const r of e.filters)a(r.minScale,r.maxScale,t,n)&&(yield r)}}function a(e,t,n,i){return e=p(e),n=p(n),t=c(t),!(!(0,r.Sp)(n,e)&&(i??n)>e||(0,r.Hx)(t,n)||void 0!==i&&(0,r.Sp)(i,e))}function u(e){return"mode"in e?e.mode:e.filterMode}function p(e){return e||Number.POSITIVE_INFINITY}function c(e){return e||0}},62815:(e,t,n)=>{n.d(t,{N:()=>s});var r=n(86211),i=n(73941),o=n(21325);function s(e,t,n){if(null==t||null==n||n.vcsWkid||(0,o.aI)(t,n)||(0,i.xP)(t)||(0,i.xP)(n))return null;const s=(0,r.G9)(t)/(0,r.G9)(n);if(1===s)return null;switch(e){case"point":case"esriGeometryPoint":return e=>function(e,t){null!=e?.z&&(e.z*=t)}(e,s);case"polyline":case"esriGeometryPolyline":return e=>function(e,t){if(e)for(const n of e.paths)for(const e of n)e.length>2&&(e[2]*=t)}(e,s);case"polygon":case"esriGeometryPolygon":return e=>function(e,t){if(e)for(const n of e.rings)for(const e of n)e.length>2&&(e[2]*=t)}(e,s);case"multipoint":case"esriGeometryMultipoint":return e=>function(e,t){if(e)for(const n of e.points)n.length>2&&(n[2]*=t)}(e,s);case"extent":case"esriGeometryEnvelope":return e=>function(e,t){e&&null!=e.zmin&&null!=e.zmax&&(e.zmin*=t,e.zmax*=t)}(e,s);default:return null}}},63396:(e,t,n)=>{n.d(t,{d:()=>M});var r=n(31635),i=n(91429),o=n(60950),s=n(99959);class l extends s.A{constructor(e){super(),this.type="track",this.trackInfoProvider=e}get id(){return this.trackInfoProvider.id}get[o.ym](){return this.trackInfoProvider.trackInfo}}var a=n(37838),u=n(69540),p=n(25482),c=n(93637),d=n(50820),f=n(10873),y=n(46499),m=n(41214);let g=class extends((0,u.OU)(p.o)){constructor(e){super(e),this.labelingInfo=null,this.labelsVisible=!0,this.renderer=null,this.visible=!0}};(0,r.Cg)([(0,i.MZ)({type:[y.A],json:{write:!0}})],g.prototype,"labelingInfo",void 0),(0,r.Cg)([(0,i.MZ)(f.kF)],g.prototype,"labelsVisible",void 0),(0,r.Cg)([(0,i.MZ)({types:m.Hg,json:{write:!0}})],g.prototype,"renderer",void 0),(0,r.Cg)([(0,i.MZ)({type:Boolean,json:{write:!0}})],g.prototype,"visible",void 0),g=(0,r.Cg)([(0,i.$K)("esri.layers.support.TrackPartInfo")],g);var h=n(96576),w=n(59868),v=n(10184),C=n(43937);let I=class extends((0,u.OU)(p.o)){constructor(e){super(e),this.enabled=!0,this.fields=[],this.latestObservations=new g({renderer:new h.A({symbol:w.UK.clone()})}),this.maxDisplayDuration=null,this.maxDisplayObservationsPerTrack=0,this.popupEnabled=!0,this.popupTemplate=null,this.previousObservations=new g({renderer:new h.A({symbol:w.UK.clone()})}),this.trackLines=new g({renderer:new h.A({symbol:w.A7.clone()})}),this.timeField="startTimeField"}writeFields(e,t,n){const r=e.filter(e=>"avg_angle"!==e.statisticType).map(e=>e.toJSON());(0,c.sM)(n,r,t)}};(0,r.Cg)([(0,i.MZ)({type:Boolean,json:{write:!0}})],I.prototype,"enabled",void 0),(0,r.Cg)([(0,i.MZ)({type:[d.A],json:{write:!0}})],I.prototype,"fields",void 0),(0,r.Cg)([(0,C.K)("fields")],I.prototype,"writeFields",null),(0,r.Cg)([(0,i.MZ)({type:g,json:{write:!0}})],I.prototype,"latestObservations",void 0),(0,r.Cg)([(0,i.MZ)({type:v.A,json:{write:!0}})],I.prototype,"maxDisplayDuration",void 0),(0,r.Cg)([(0,i.MZ)({type:Number,json:{write:!0}})],I.prototype,"maxDisplayObservationsPerTrack",void 0),(0,r.Cg)([(0,i.MZ)(f.M6)],I.prototype,"popupEnabled",void 0),(0,r.Cg)([(0,i.MZ)({type:a.A,json:{name:"popupInfo",write:!0}})],I.prototype,"popupTemplate",void 0),(0,r.Cg)([(0,i.MZ)({type:g,json:{write:!0}})],I.prototype,"previousObservations",void 0),(0,r.Cg)([(0,i.MZ)({type:g,json:{write:!0}})],I.prototype,"trackLines",void 0),(0,r.Cg)([(0,i.MZ)({type:["timeReceived","startTimeField","endTimeField"],json:{read:!0,write:!0}})],I.prototype,"timeField",void 0),I=(0,r.Cg)([(0,i.$K)("esri.layers.support.TrackInfo")],I);const M=e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.trackGraphicOrigin=new l(this),this.trackInfo=null}};return(0,r.Cg)([(0,i.MZ)({readOnly:!0,clonable:!1})],n.prototype,"trackGraphicOrigin",void 0),(0,r.Cg)([(0,i.MZ)({type:I})],n.prototype,"trackInfo",void 0),n=(0,r.Cg)([(0,i.$K)("esri.layers.mixins.TrackableLayer")],n),n}},64714:(e,t,n)=>{n.d(t,{F0:()=>l,Vx:()=>p,e2:()=>d,f:()=>f});var r=n(44208),i=n(4718),o=n(99352),s=n(93470);function l(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?s.Cb:"esriGeometryPolyline"===e?s.yM:s.WR}}}const a=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function p(e,t){if((0,r.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let n=`this${c(t)} = null;`;for(const t in e)n+=`this${c(t)} = ${JSON.stringify(e[t])};`;const r=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${n};\n }\n }\n `)();return()=>new r}catch(n){return()=>({[t]:null,...e})}}function c(e){return a.test(e)?`.${e}`:`[${JSON.stringify(e)}]`}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,i.o8)(e)}}]}function f(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:o.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:o.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},65977:(e,t,n)=>{n.r(t),n.d(t,{default:()=>W});var r=n(31635),i=n(37838),o=n(49186),s=n(25728),l=n(91429),a=n(5443),u=n(16930),p=n(50498),c=n(55156),d=n(60950),f=n(89808),y=n(99959);const m=Symbol("isOGCFeatureGraphicOrigin");var g;class h extends y.A{get[(g=m,d.ym)](){return this.layer}get[c.e](){return this.layer}get[f.Q](){return this.layer}constructor(e){super(),this[g]=!0,this.type="ogc-feature",this.layer=e}get id(){return this.layer.id}}var w=n(4146),v=n(92474),C=n(799),I=n(75321),M=n(4071),S=n(22671);let T=class extends v.x_{constructor(){super(...arguments),this.featureDefinition=null,this.type="ogc-feature"}load(e){return this.addResolvingPromise(this._loadOGCServices(this.layer,e)),this.when()}getSource(){const{featureDefinition:{collection:e,layerDefinition:t,spatialReference:n,supportedCrs:r},layer:{apiKey:i,customParameters:o,effectiveMaxRecordCount:s}}=this;return{type:"ogc-source",collection:e,layerDefinition:t,maxRecordCount:s,queryParameters:{apiKey:i,customParameters:o},spatialReference:n,supportedCrs:r}}queryExtent(e,t={}){return null}queryFeatureCount(e,t={}){return null}queryFeatures(e,t={}){return this.queryFeaturesJSON(e,t).then(e=>S.A.fromJSON(e))}queryFeaturesJSON(e,t={}){const n=this.getSource();return this.load(t).then(()=>(0,I.bW)(n,e,t))}queryObjectIds(e,t={}){return null}serviceSupportsSpatialReference(e){const{isWebMercator:t,isWGS84:n,latestWkid:r,wkid:i}=e,{supportedCrs:o}=this.featureDefinition;return n||t||!!i&&!!o[i]||!!r&&!!o[r]}_conformsToType(e,t){const n=new RegExp(`^${(0,C.Cj)(t)}$`,"i");return e.conformsTo.some(e=>n.test(e))??!1}_getCapabilities(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!1,supportsQueryBins:!1,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},query:{maxRecordCount:t,maxRecordCountFactor:void 0,maxUniqueIDCount:void 0,standardMaxRecordCount:void 0,supportsCacheHint:!1,supportsCentroid:!1,supportsCentroidOnDegeneratedQuantizedGeometry:!1,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPaginationOnAggregatedQueries:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsReturnMesh:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsStatistics:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,supportsSqlExpression:!1,supportsTrueCurve:!1,tileMaxRecordCount:void 0},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:M.$,editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUploadWithItemId:!1,supportsUpdateWithoutM:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}_getMaxRecordCount(e){const t=e?.components?.parameters;return t?.limit?.schema?.maximum??t?.limitFeatures?.schema?.maximum}_getStorageSpatialReference(e){const t=e.storageCrs??I.QE,n=(0,I.J0)(t);return null==n?u.A.WGS84:new u.A({wkid:n})}_getSupportedSpatialReferences(e,t){const n="#/crs",r=e.crs??[I.QE],i=r.includes(n)?r.filter(e=>e!==n).concat(t.crs??[]):r,o=/^http:\/\/www\.opengis.net\/def\/crs\/epsg\/.*\/3785$/i;return i.filter(e=>!o.test(e))}async _loadOGCServices(e,t){const n=null!=t?t.signal:null,{apiKey:r,collectionId:i,customParameters:s,fields:l,geometryType:a,hasZ:u,objectIdField:c,timeInfo:d,url:f}=e,y={fields:l?.map(e=>e.toJSON()),geometryType:p.Ye.toJSON(a),hasZ:u,objectIdField:c,timeInfo:d?.toJSON()},m={apiKey:r,customParameters:s,signal:n},g=await(0,I.Ki)(f,m),[h,w]=await Promise.all([(0,I.Px)(g,m),(0,I.bV)(g,m)]);if(!this._conformsToType(h,"http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/geojson"))throw new o.A("ogc-feature-layer:no-geojson-support","Server does not support geojson");const v=w.collections.find(({id:e})=>e===i);if(!v)throw new o.A("ogc-feature-layer:collection-not-found","Server does not contain the named collection");const M=this._conformsToType(h,"http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/oas30")?await(0,I.GA)(g,m):null,S=await(0,I.GL)(v,y,m),T=this._getMaxRecordCount(M),x=this._getCapabilities(S.hasZ,T),b=this._getStorageSpatialReference(v).toJSON(),A=this._getSupportedSpatialReferences(v,w),F=new RegExp(`^${(0,C.Cj)(I.vJ)}`,"i"),P={};for(const e of A){const t=(0,I.J0)(e);null!=t&&(P[t]||(P[t]=e.replace(F,"")))}this.featureDefinition={capabilities:x,collection:v,layerDefinition:S,spatialReference:b,supportedCrs:P}}};(0,r.Cg)([(0,l.MZ)()],T.prototype,"featureDefinition",void 0),(0,r.Cg)([(0,l.MZ)({constructOnly:!0})],T.prototype,"layer",void 0),(0,r.Cg)([(0,l.MZ)()],T.prototype,"type",void 0),T=(0,r.Cg)([(0,l.$K)("esri.layers.graphics.sources.OGCFeatureSource")],T);var x=n(52136),b=n(63074),A=n(69208),F=n(6455),P=n(87718),j=n(56658),R=n(16131),O=n(32756),Z=n(8303),E=n(54310),N=n(25036),D=n(82935),k=n(63396),G=n(10873),U=n(33143),_=n(20437),L=n(17036),$=n(30524),B=n(46499),q=n(39383),z=n(41214),K=n(61956),J=n(30291);const H=(0,L.p)();let Q=class extends((0,F.FJ)((0,x.p)((0,A.d)((0,j.J)((0,P.F)((0,b.dM)((0,O.fY)((0,D.e)((0,k.d)((0,N.j)((0,R.q)((0,Z.A)((0,E.J)((0,s.P)(w.A))))))))))))))){constructor(e){super(e),this.capabilities=null,this.collectionId=null,this.copyright=null,this.description=null,this.displayField=null,this.elevationInfo=null,this.fields=null,this.fieldsIndex=null,this.fullExtent=null,this.geometryType=null,this.graphicOrigin=new h(this),this.hasZ=void 0,this.labelingInfo=null,this.labelsVisible=!0,this.legendEnabled=!0,this.maxRecordCount=null,this.objectIdField=null,this.operationalLayerType="OGCFeatureLayer",this.popupEnabled=!0,this.popupTemplate=null,this.screenSizePerspectiveEnabled=!0,this.source=new T({layer:this}),this.spatialReference=null,this.title=null,this.type="ogc-feature",this.typeIdField=null,this.types=null,this.url=null}destroy(){this.source?.destroy()}load(e){return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["OGCFeatureServer"]},e).then(()=>this._fetchService(e))),this.when()}get defaultPopupTemplate(){return this.createPopupTemplate()}get effectiveMaxRecordCount(){return this.maxRecordCount??this.capabilities?.query.maxRecordCount??5e3}get isTable(){return this.loaded&&null==this.geometryType}set renderer(e){(0,$.yp)(e,this.fieldsIndex),this._set("renderer",e)}createPopupTemplate(e){return(0,J.tn)(this,e)}createQuery(){return new K.A}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){let n,r=!1;const i=t?.feature?.attributes,o=this.typeIdField&&i?.[this.typeIdField];return null!=o&&this.types&&(r=this.types.some(t=>t.id==o&&(n=t.domains?.[e],"inherited"===n?.type&&(n=this._getLayerDomain(e)),!0))),r||n||(n=this._getLayerDomain(e)),n}queryFeatures(e,t){return this.load().then(()=>this.source.queryFeatures(K.A.from(e)||this.createQuery(),t)).then(e=>(e?.features?.forEach(e=>{e.layer=e.sourceLayer=this,e.origin=this.graphicOrigin}),e))}async queryAttributeBins(e,t){throw new o.A("OGCFeatureLayer","Layer source does not support queryAttributeBins capability")}serviceSupportsSpatialReference(e){return this.source?.serviceSupportsSpatialReference(e)??!1}async _fetchService(e){await this.source.load(e),this.read(this.source.featureDefinition,{origin:"service"}),(0,$.yp)(this.renderer,this.fieldsIndex),(0,$.sv)(this.timeInfo,this.fieldsIndex)}_getLayerDomain(e){if(!this.fields)return null;for(const t of this.fields)if(t.name===e&&t.domain)return t.domain;return null}};(0,r.Cg)([(0,l.MZ)({readOnly:!0,json:{origins:{service:{read:!0}}}})],Q.prototype,"capabilities",void 0),(0,r.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],Q.prototype,"collectionId",void 0),(0,r.Cg)([(0,l.MZ)({type:String})],Q.prototype,"copyright",void 0),(0,r.Cg)([(0,l.MZ)({readOnly:!0})],Q.prototype,"defaultPopupTemplate",null),(0,r.Cg)([(0,l.MZ)({readOnly:!0,type:String,json:{origins:{service:{name:"collection.description"}}}})],Q.prototype,"description",void 0),(0,r.Cg)([(0,l.MZ)({type:String})],Q.prototype,"displayField",void 0),(0,r.Cg)([(0,l.MZ)({type:Number})],Q.prototype,"effectiveMaxRecordCount",null),(0,r.Cg)([(0,l.MZ)(G.Yj)],Q.prototype,"elevationInfo",void 0),(0,r.Cg)([(0,l.MZ)({type:[_.A],json:{origins:{service:{name:"layerDefinition.fields"}}}})],Q.prototype,"fields",void 0),(0,r.Cg)([(0,l.MZ)(H.fieldsIndex)],Q.prototype,"fieldsIndex",void 0),(0,r.Cg)([(0,l.MZ)({readOnly:!0,type:a.A,json:{origins:{service:{name:"layerDefinition.extent"}}}})],Q.prototype,"fullExtent",void 0),(0,r.Cg)([(0,l.MZ)({type:p.gy.apiValues,json:{origins:{service:{name:"layerDefinition.geometryType",read:{reader:p.gy.read}}}}})],Q.prototype,"geometryType",void 0),(0,r.Cg)([(0,l.MZ)({readOnly:!0,clonable:!1})],Q.prototype,"graphicOrigin",void 0),(0,r.Cg)([(0,l.MZ)({type:Boolean,json:{origins:{service:{name:"layerDefinition.hasZ"}}}})],Q.prototype,"hasZ",void 0),(0,r.Cg)([(0,l.MZ)({type:Boolean,readOnly:!0})],Q.prototype,"isTable",null),(0,r.Cg)([(0,l.MZ)({type:[B.A],json:{origins:{"web-document":{name:"layerDefinition.drawingInfo.labelingInfo",read:{reader:q.w},write:!0}}}})],Q.prototype,"labelingInfo",void 0),(0,r.Cg)([(0,l.MZ)(G.kF)],Q.prototype,"labelsVisible",void 0),(0,r.Cg)([(0,l.MZ)(G.fV)],Q.prototype,"legendEnabled",void 0),(0,r.Cg)([(0,l.MZ)({type:Number})],Q.prototype,"maxRecordCount",void 0),(0,r.Cg)([(0,l.MZ)({type:String,json:{origins:{service:{name:"layerDefinition.objectIdField"}}}})],Q.prototype,"objectIdField",void 0),(0,r.Cg)([(0,l.MZ)({type:["OGCFeatureLayer"]})],Q.prototype,"operationalLayerType",void 0),(0,r.Cg)([(0,l.MZ)(G.M6)],Q.prototype,"popupEnabled",void 0),(0,r.Cg)([(0,l.MZ)({type:i.A,json:{name:"popupInfo",write:!0}})],Q.prototype,"popupTemplate",void 0),(0,r.Cg)([(0,l.MZ)({types:z.Hg,json:{origins:{service:{name:"layerDefinition.drawingInfo.renderer",write:!1},"web-scene":{types:z.XJ,name:"layerDefinition.drawingInfo.renderer",write:!0}},name:"layerDefinition.drawingInfo.renderer",write:!0}})],Q.prototype,"renderer",null),(0,r.Cg)([(0,l.MZ)(G.PY)],Q.prototype,"screenSizePerspectiveEnabled",void 0),(0,r.Cg)([(0,l.MZ)({readOnly:!0})],Q.prototype,"source",void 0),(0,r.Cg)([(0,l.MZ)({readOnly:!0,type:u.A,json:{origins:{service:{read:!0}}}})],Q.prototype,"spatialReference",void 0),(0,r.Cg)([(0,l.MZ)({type:String,json:{write:{enabled:!0,ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"collection.title"}}}})],Q.prototype,"title",void 0),(0,r.Cg)([(0,l.MZ)({readOnly:!0,json:{read:!1}})],Q.prototype,"type",void 0),(0,r.Cg)([(0,l.MZ)({type:String,readOnly:!0})],Q.prototype,"typeIdField",void 0),(0,r.Cg)([(0,l.MZ)({type:[U.A]})],Q.prototype,"types",void 0),(0,r.Cg)([(0,l.MZ)(G.OZ)],Q.prototype,"url",void 0),Q=(0,r.Cg)([(0,l.$K)("esri.layers.OGCFeatureLayer")],Q);const W=Q},67482:(e,t,n)=>{function r(e){return null!=l(e)||null!=s(e)}function i(e){return a.test(e)}function o(e){return l(e)??s(e)}function s(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let n=!0;if(p&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,r=0;for(;!t&&r<=e.length;)t=!u.test(e[r]),r++;n=!t}}return n}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function l(e){const t=a.exec(e);if(!t?.groups)return null;const n=t.groups,r=+n.year,i=+n.month-1,o=+n.day,s=+(n.hours??"0"),l=+(n.minutes??"0"),u=+(n.seconds??"0");if(s>23)return null;if(l>59)return null;if(u>59)return null;const p=n.ms??"0",c=p?+p.padEnd(3,"0").slice(0,3):0;let d;if(n.isUTC||!n.offsetSign)d=Date.UTC(r,i,o,s,l,u,c);else{const e=+n.offsetHours,t=+n.offsetMinutes;d=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(r,i,o,s,l,u,c)}return Number.isNaN(d)?null:d}n.d(t,{Br:()=>i,Cq:()=>r,_U:()=>o});const a=/^(?:(?<year>-?\d{4,})-(?<month>\d{2})-(?<day>\d{2}))(?:T(?<hours>\d{2}):(?<minutes>\d{2}):(?<seconds>\d{2})(?:\.(?<ms>\d+))?)?(?:(?<isUTC>Z)|(?:(?<offsetSign>\+|-)(?<offsetHours>\d{2}):(?<offsetMinutes>\d{2})))?$/,u=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,p=!Number.isNaN(new Date("technology 10").getTime())},69208:(e,t,n)=>{n.d(t,{d:()=>o});var r=n(31635),i=n(91429);const o=e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.customParameters=null}};return(0,r.Cg)([(0,i.MZ)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],n.prototype,"customParameters",void 0),n=(0,r.Cg)([(0,i.$K)("esri.layers.mixins.CustomParametersMixin")],n),n}},73133:(e,t,n)=>{n.d(t,{j:()=>r});const r=(0,n(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},75321:(e,t,n)=>{n.d(t,{GA:()=>A,GL:()=>S,I:()=>j,J0:()=>F,Ki:()=>b,Px:()=>x,QE:()=>M,bV:()=>T,bW:()=>P,vJ:()=>I});var r=n(11254),i=n(49186),o=n(53966),s=n(84952),l=n(16930),a=n(21325),u=n(28735),p=n(90708),c=n(58512),d=n(85113),f=n(64714),y=n(82832),m=n(95466),g=n(98453),h=n(98623);const w=()=>o.A.getLogger("esri.layers.ogc.ogcFeatureUtils"),v="startindex",C=new Set([v,"offset"]),I="http://www.opengis.net/def/crs/",M=`${I}OGC/1.3/CRS84`;async function S(e,t,n={},o=5){const{links:l}=e,a=N(l,"items","application/geo+json")||N(l,"http://www.opengis.net/def/rel/ogc/1.0/items","application/geo+json");if(null==a)throw new i.A("ogc-feature-layer:missing-items-page","Missing items url");const{apiKey:u,customParameters:p,signal:c}=n,y=(0,s.s2)(a.href,e.landingPage.url),C={limit:o,...p,token:u},I=(0,s.a6)(y,C),{data:M}=await(0,r.A)(I,{signal:c,headers:{accept:"application/geo+json"}}),S=D(I,o,M.links)??v;(0,d.sO)(M);const T=M.numberMatched,x=(0,d.BM)(M,{geometryType:t.geometryType}),b=t.fields||x.fields||[],A=null!=t.hasZ?t.hasZ:x.hasZ,F=x.geometryType,P=t.objectIdField||x.objectIdFieldName||"OBJECTID";let j=t.timeInfo;const R=b.find(({name:e})=>e===P);if(R)R.editable=!1,R.nullable=!1;else{if(!x.objectIdFieldType)throw new i.A("ogc-feature-layer:missing-feature-id","Collection geojson require a feature id as a unique identifier");b.unshift({name:P,alias:P,type:"number"===x.objectIdFieldType?"esriFieldTypeOID":"esriFieldTypeString",editable:!1,nullable:!1})}if(P!==x.objectIdFieldName){const e=b.find(({name:e})=>e===x.objectIdFieldName);e&&(e.type="esriFieldTypeInteger")}b===x.fields&&x.unknownFields.length>0&&w().warn({name:"ogc-feature-layer:unknown-field-types",message:"Some fields types couldn't be inferred from the features and were dropped",details:{unknownFields:x.unknownFields}});for(const e of b){if(null==e.name&&(e.name=e.alias),null==e.alias&&(e.alias=e.name),"esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type&&(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable),!e.name)throw new i.A("ogc-feature-layer:invalid-field-name","field name is missing",{field:e});if(!g.m.jsonValues.includes(e.type))throw new i.A("ogc-feature-layer:invalid-field-type",`invalid type for field "${e.name}"`,{field:e})}if(j){const e=new m.A(b);if(j.startTimeField){const t=e.get(j.startTimeField);t?(j.startTimeField=t.name,t.type="esriFieldTypeDate"):j.startTimeField=null}if(j.endTimeField){const t=e.get(j.endTimeField);t?(j.endTimeField=t.name,t.type="esriFieldTypeDate"):j.endTimeField=null}if(j.trackIdField){const t=e.get(j.trackIdField);t?j.trackIdField=t.name:(j.trackIdField=null,w().warn({name:"ogc-feature-layer:invalid-timeInfo-trackIdField",message:"trackIdField is missing",details:{timeInfo:j}}))}j.timeReference||={timeZoneIANA:h.n$},j.startTimeField||j.endTimeField||(w().warn({name:"ogc-feature-layer:invalid-timeInfo",message:"startTimeField and endTimeField are missing",details:{timeInfo:j}}),j=void 0)}return{drawingInfo:F?(0,f.F0)(F):null,extent:E(e),geometryType:F,fields:b,hasZ:!!A,objectIdField:P,paginationParameter:S,timeInfo:j,featureCount:T}}async function T(e,t={}){const{links:n,url:o}=e,l=N(n,"data","application/json")||N(n,"http://www.opengis.net/def/rel/ogc/1.0/data","application/json");if(null==l)throw new i.A("ogc-feature-layer:missing-collections-page","Missing collections url");const{apiKey:a,customParameters:u,signal:p}=t,c=(0,s.s2)(l.href,o),{data:d}=await(0,r.A)(c,{signal:p,headers:{accept:"application/json"},query:{...u,token:a}});for(const t of d.collections)t.landingPage=e;return d}async function x(e,t={}){const{links:n,url:o}=e,l=N(n,"conformance","application/json")||N(n,"http://www.opengis.net/def/rel/ogc/1.0/conformance","application/json");if(null==l)throw new i.A("ogc-feature-layer:missing-conformance-page","Missing conformance url");const{apiKey:a,customParameters:u,signal:p}=t,c=(0,s.s2)(l.href,o),{data:d}=await(0,r.A)(c,{signal:p,headers:{accept:"application/json"},query:{...u,token:a}});return d}async function b(e,t={}){const{apiKey:n,customParameters:i,signal:o}=t,{data:s}=await(0,r.A)(e,{signal:o,headers:{accept:"application/json"},query:{...i,token:n}});return s.url=e,s}async function A(e,t={}){const{links:n,url:i}=e,o=N(n,"service-desc","application/vnd.oai.openapi+json;version=3.0");if(null==o)return w().warn("ogc-feature-layer:missing-openapi-page","The OGC API-Features server does not have an OpenAPI page."),null;const{apiKey:l,customParameters:a,signal:u}=t,p=(0,s.s2)(o.href,i),{data:c}=await(0,r.A)(p,{signal:u,headers:{accept:"application/vnd.oai.openapi+json;version=3.0"},query:{...a,token:l}});return c}function F(e){const t=/^http:\/\/www\.opengis.net\/def\/crs\/(?<authority>.*)\/(?<version>.*)\/(?<code>.*)$/i.exec(e),n=t?.groups;if(!n)return null;const{authority:r,code:i}=n;switch(r.toLowerCase()){case"ogc":switch(i.toLowerCase()){case"crs27":return l.A.GCS_NAD_1927.wkid;case"crs83":return 4269;case"crs84":case"crs84h":return l.A.WGS84.wkid;default:return null}case"esri":case"epsg":{const e=Number.parseInt(i,10);return Number.isNaN(e)?null:e}default:return null}}async function P(e,t,n){const r=await j(e,t,n);return(0,p.ZF)(r)}async function j(e,t,n){const{collection:{links:o,landingPage:{url:f}},layerDefinition:g,maxRecordCount:h,queryParameters:{apiKey:w,customParameters:v},spatialReference:C,supportedCrs:I}=e,M=N(o,"items","application/geo+json")||N(o,"http://www.opengis.net/def/rel/ogc/1.0/items","application/geo+json");if(!M)throw new i.A("ogc-feature-layer:missing-items-page","Missing items url");const{geometry:S,num:T,start:x,timeExtent:b,where:A}=t;if(t.objectIds)throw new i.A("ogc-feature-layer:query-by-objectids-not-supported","Queries with object ids are not supported");const F=l.A.fromJSON(C),P=t.outSpatialReference??F,j=P.isWGS84?null:R(P,I),O=Z(S,I),E=function(e){if(!e)return null;const{start:t,end:n}=e;return`${null!=t?t.toISOString():".."}/${null!=n?n.toISOString():".."}`}(b),D=(Q=A)&&"1=1"!==Q?Q:null,k=T??(null==x?h:10),G=0===x?void 0:x,{fields:U,geometryType:_,hasZ:L,objectIdField:$,paginationParameter:B}=g,q=(0,s.s2)(M.href,f),{data:z}=await(0,r.A)(q,{...n,query:{...v,...O,crs:j,datetime:E,query:D,limit:k,[B]:G,token:w},headers:{accept:"application/geo+json"}}),K=(0,d.bd)(z,{geometryType:_,hasZ:L,objectIdField:$}),J=K.length===k&&!!N(z.links??[],"next","application/geo+json"),H=new m.A(U);var Q;for(const e of K){const t={};(0,y.MB)(H,t,e.attributes,!0);for(const e of H.fields)e.nullable&&!(e.name in t)&&(t[e.name]=null);t[$]=e.attributes[$],e.attributes=t}if(!j&&P.isWebMercator)for(const e of K)if(null!=e.geometry&&null!=_){const t=(0,p.zv)(e.geometry,_,L,!1);t.spatialReference=l.A.WGS84,e.geometry=(0,p.Ux)((0,u.Cv)(t,P))}for(const e of K)e.objectId=e.attributes[$];const W=j||!j&&P.isWebMercator?P.toJSON():a.KK,V=new c.A;return V.exceededTransferLimit=J,V.features=K,V.fields=U,V.geometryType=_,V.hasZ=L,V.spatialReference=W,V}function R(e,t){const{isWebMercator:n,wkid:r,latestWkid:i}=e;if(!r&&!i)return null;const o=n?t[3857]??t[102100]??t[102113]??t[900913]:r&&t[r]||i&&t[i];return o?`${I}${o}`:null}function O(e){if(!e)return"";const{xmin:t,ymin:n,xmax:r,ymax:i}=e;return`${t},${n},${r},${i}`}function Z(e,t){if(!function(e){return null!=e&&"extent"===e.type}(e))return null;const{spatialReference:n}=e;if(!n||n.isWGS84)return{bbox:O(e)};const r=R(n,t);return null!=r?{bbox:O(e),"bbox-crs":r}:n.isWebMercator?{bbox:O((0,u.Cv)(e,l.A.WGS84))}:null}function E(e){const t=e.extent?.spatial;if(!t)return null;const n=t.bbox[0],r=4===n.length,[i,o]=n,s=r?void 0:n[2];return{xmin:i,ymin:o,xmax:r?n[2]:n[3],ymax:r?n[3]:n[4],zmin:s,zmax:r?void 0:n[5],spatialReference:l.A.WGS84.toJSON()}}function N(e,t,n){return e.find(({rel:e,type:r})=>e===t&&r===n)??e.find(({rel:e,type:n})=>e===t&&!n)}function D(e,t,n){if(!n)return;const r=N(n,"next","application/geo+json"),i=(0,s.An)(r?.href)?.query;if(!i)return;const o=(0,s.An)(e).query,l=Object.keys(o??{}),a=Object.entries(i).filter(([e])=>!l.includes(e)).find(([e,n])=>C.has(e.toLowerCase())&&Number.parseInt(n,10)===t),u=a?.[0];return u}},82832:(e,t,n)=>{n.d(t,{$1:()=>g,CR:()=>m,MB:()=>d,PC:()=>h,Yx:()=>a,bP:()=>p});var r=n(67482),i=n(21325),o=n(30524);class s{constructor(e){this.description=e,this.code=null}}class l{constructor(e){this.globalId=null,this.objectId=null,this.success=!1,this.uniqueId=null,this.error=new s(e)}}function a(e){return new l(e)}class u{constructor(e){this.globalId=null,this.success=!0,this.objectId=this.uniqueId=e}}function p(e){return new u(e)}const c=new Set;function d(e,t,n,r=!1){c.clear();for(const i in n){const s=e.get(i);if(!s)continue;const l=f(s,n[i]);if(c.add(s.name),s&&(r||s.editable)){const e=(0,o.CJ)(s,l);if(e)return a((0,o.uo)(e,s,l));t[s.name]=l}}for(const t of e.requiredFields??[])if(!c.has(t.name))return a(`missing required field "${t.name}"`);return null}function f(e,t){let n=t;return(0,o.WA)(e)&&"string"==typeof t?n=parseFloat(t):(0,o.yM)(e)&&null!=t&&"string"!=typeof t?n=String(t):(0,o.vE)(e)&&"string"==typeof t&&(n=(0,r._U)(t)),(0,o.WX)(n)}let y;function m(e,t){if(!e||!(0,i.fn)(t))return e;if("rings"in e||"paths"in e){if(null==y)throw new TypeError("geometry engine not loaded");return y.simplify(t,e)}return e}async function g(e,t){!(0,i.fn)(e)||"esriGeometryPolygon"!==t&&"esriGeometryPolyline"!==t||await async function(){return null==y&&(y=await n.e(1023).then(n.bind(n,81023))),y}()}const h={supportsAutoIntervalBin:!0,supportsFixedIntervalBin:!0,supportsFixedBoundariesBin:!0,supportsDateBin:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsNormalization:!0,supportedStatisticTypes:["COUNT","SUM","AVG","VAR","STDDEV","MIN","MAX","PERCENTILE_CONT","PERCENTILE_DISC","CentroidAggregate","EnvelopeAggregate","ConvexHullAggregate"],supportedNormalizationTypes:["field","log","naturalLog","percentOfTotal","squareRoot"]}},82935:(e,t,n)=>{n.d(t,{B:()=>d,e:()=>f});var r=n(31635),i=n(91429),o=n(89317),s=n(30524),l=n(96184),a=n(73133),u=n(79677),p=n(10184),c=n(36005);const d={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:o.K}}},f=e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const n=t.timeInfo.exportOptions;if(!n)return null;const r=n.timeOffset,i=a.j.fromJSON(n.timeOffsetUnits);return r&&i?new p.A({value:r,unit:i}):null}get timeInfo(){return this._get("timeInfo")}set timeInfo(e){(0,s.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,r.Cg)([(0,i.MZ)({type:u.A,json:{write:!1}})],n.prototype,"timeExtent",void 0),(0,r.Cg)([(0,i.MZ)({type:p.A})],n.prototype,"timeOffset",void 0),(0,r.Cg)([(0,c.w)("service","timeOffset",["timeInfo.exportOptions"])],n.prototype,"readOffset",null),(0,r.Cg)([(0,i.MZ)({value:null,type:l.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],n.prototype,"timeInfo",null),(0,r.Cg)([(0,i.MZ)(d)],n.prototype,"useViewTime",void 0),n=(0,r.Cg)([(0,i.$K)("esri.layers.mixins.TemporalLayer")],n),n}},83960:(e,t,n)=>{n.d(t,{X_:()=>s,oW:()=>a,zx:()=>l});var r=n(34727),i=n(86211);const o=96;function s(e,t){const n=t||e.extent,r=e.width,s=(0,i.GA)(n?.spatialReference);return n&&r?n.width/r*s*i.dy*o:0}function l(e,t,n){return function(e,t){return 0===t||(0,r.Sp)(e,t)||e<t}(e,t)&&function(e,t){return 0===t||(0,r.Sp)(e,t)||e>t}(e,n)}function a(e,t){return(0,r.Sp)(e,t)?0:(e||Number.POSITIVE_INFINITY)>(t||Number.POSITIVE_INFINITY)?1:-1}},85113:(e,t,n)=>{n.d(t,{BM:()=>x,bd:()=>b,sO:()=>T,xD:()=>c});var r=n(67482),i=n(49186),o=n(21325),s=n(90708),l=n(43334),a=n(92722),u=n(30524);const p={LineString:"esriGeometryPolyline",MultiLineString:"esriGeometryPolyline",MultiPoint:"esriGeometryMultipoint",Point:"esriGeometryPoint",Polygon:"esriGeometryPolygon",MultiPolygon:"esriGeometryPolygon"};function c(e){return p[e]}function*d(e){switch(e.type){case"Feature":yield e;break;case"FeatureCollection":for(const t of e.features)t&&(yield t)}}function*f(e){if(e)switch(e.type){case"Point":yield e.coordinates;break;case"LineString":case"MultiPoint":yield*e.coordinates;break;case"MultiLineString":case"Polygon":for(const t of e.coordinates)yield*t;break;case"MultiPolygon":for(const t of e.coordinates)for(const e of t)yield*e}}function y(e){for(const t of e)if(t.length>2)return!0;return!1}function m(e){let t=0;for(let n=0;n<e.length;n++){const r=e[n],i=e[(n+1)%e.length];t+=r[0]*i[1]-i[0]*r[1]}return t<=0}function g(e){const t=e[0],n=e[e.length-1];t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]||e.push(t)}function h(e,t){const{coordinates:n,type:r}=e,i=t.hasZ??!1,o=!0;switch(r){case"Point":return new a.A([],[...n],i,!1);case"LineString":return(0,s.Ap)({paths:[n],hasZ:o},i,!1);case"MultiLineString":return(0,s.Ap)({paths:n,hasZ:o},i,!1);case"MultiPoint":return(0,s.PR)({points:n,hasZ:o},i,!1);case"Polygon":case"MultiPolygon":{const e=new a.A([],[],i,!1);for(const t of"Polygon"===r?[n]:n){w(e,t[0],i);for(let n=1;n<t.length;n++)v(e,t[n],i)}return e}}}function w(e,t,n){g(t),function(e){return!m(e)}(t)?I(e,t,n):C(e,t,n)}function v(e,t,n){g(t),function(e){return m(e)}(t)?I(e,t,n):C(e,t,n)}function C(e,t,n){for(const r of t)M(e,r,n);e.lengths.push(t.length)}function I(e,t,n){for(let r=t.length-1;r>=0;r--)M(e,t[r],n);e.lengths.push(t.length)}function M(e,[t,n,r],i){e.coords.push(t,n),i&&e.coords.push(r||0)}function S(e){switch(typeof e){case"string":return(0,r.Br)(e)?"esriFieldTypeDate":"esriFieldTypeString";case"number":return"esriFieldTypeDouble";default:return"unknown"}}function T(e,t=4326){if(!e)throw new i.A("geojson-layer:empty","GeoJSON data is empty");if("Feature"!==e.type&&"FeatureCollection"!==e.type)throw new i.A("geojson-layer:unsupported-geojson-object","missing or not supported GeoJSON object type",{data:e});const{crs:n}=e;if(!n)return;const r="string"==typeof n?n:"name"===n.type?n.properties.name:"EPSG"===n.type?n.properties.code:null,s=(0,o.oT)({wkid:t})?new RegExp(".*(CRS84H?|4326)$","i"):new RegExp(`.*(${t})$`,"i");if(!r||!s.test(r))throw new i.A("geojson:unsupported-crs","unsupported GeoJSON 'crs' member",{crs:n})}function x(e,t={}){const n=[],r=new Set,i=new Set;let o,s=!1,l=null,a=!1,{geometryType:p=null}=t;for(const t of d(e)){const{geometry:e,properties:d,id:m}=t;if((!e||(p||(p=c(e.type)),c(e.type)===p))&&(s||(s=y(f(e))),a||(a=null!=m,a&&(o=typeof m,d&&(l=Object.keys(d).filter(e=>d[e]===m)))),d&&l&&a&&null!=m&&(l.length>1?l=l.filter(e=>d[e]===m):1===l.length&&(l=d[l[0]]===m?l:[])),d))for(const e in d){if(r.has(e))continue;const t=S(d[e]);if("unknown"===t){i.add(e);continue}i.delete(e),r.add(e);const o=(0,u.rS)(e);o&&n.push({name:o,alias:e,type:t})}}const m=(0,u.rS)(1===l?.length&&l[0]||null)??void 0;if(m)for(const e of n)if(e.name===m&&(0,u.WA)(e)){e.type="esriFieldTypeOID";break}return{fields:n,geometryType:p,hasZ:s,objectIdFieldName:m,objectIdFieldType:o,unknownFields:Array.from(i)}}function b(e,t){return Array.from(function*(e,t={}){const{geometryType:n,objectIdField:r}=t;for(const i of e){const{geometry:e,properties:o,id:s}=i;if(e&&c(e.type)!==n)continue;const a=o||{};let u;r&&(u=a[r],null==s||u||(a[r]=u=s)),yield new l.Om(e&&h(e,t),a,null,u)}}(d(e),t))}},91218:(e,t,n)=>{n.r(t),n.d(t,{canProjectWithoutEngine:()=>q,initializeProjection:()=>K,isEqualBaseGCS:()=>z,isLoaded:()=>j,isLoadedOrLoad:()=>R,isLoadedOrLoadFor:()=>O,load:()=>E,project:()=>N,projectExtent:()=>ne,projectMany:()=>D,projectMultipoint:()=>W,projectOrLoad:()=>k,projectOrLoadMany:()=>G,projectPoint:()=>H,projectPolygon:()=>ee,projectPolyline:()=>Y,projectWithZConversion:()=>B,projectWithoutEngine:()=>J,requiresLoad:()=>Z,test:()=>L,tryProjectWithZConversion:()=>$,unload:()=>_});var r=n(49186),i=n(74887),o=n(62788),s=n(95488),l=n(51850),a=n(21276),u=n(73941),p=n(5443),c=n(91075),d=n(48526),f=n(86738),y=n(39829),m=n(82799),g=n(16930),h=n(159),w=n(9762),v=n(37539);function C(e,t,n,r,i,o){return I[0]=e,I[1]=t,I[2]=n,(0,w.projectBuffer)(I,r,0,i,o,0)}const I=(0,l.vt)();var M=n(21325),S=n(62815);let T=null,x=null,b=null,A=null,F={};const P=new s.I;function j(){return!!(x?.isLoaded()&&b?.isLoaded()&&A?.isLoaded())}function R(){return!!j()||((0,o.gc)(P),E(),!1)}function O(e,t){return!e||!t||q(e,t)||R()}function Z(e,t){return!q(e,t)&&!j()}async function E(e){null==T&&(T=Promise.all([n.e(3276).then(n.bind(n,83276)).then(e=>(x=e,x.load())),n.e(8377).then(n.bind(n,8377)).then(e=>(b=e,b.load())),n.e(2158).then(n.bind(n,12158)).then(e=>(A=e,A.load()))])),await T,(0,i.Te)(e),P.notify()}function N(e,t,n){return Array.isArray(e)?0===e.length?[]:((0,a.H)(e),D(e,e[0].spatialReference,t,n)):((0,a.f)(e),D([e],e.spatialReference,t,n)[0])}function D(e,t,n,r){if(null==t||null==n)return e;if(q(t,n,r))return e.map(e=>J(e,t,n));if(null==r?.geographicTransformation&&(0,u.jA)(t))return e.map(e=>J(e,t,g.A.WGS84)).map(e=>$(e,n));if(null==r?.geographicTransformation&&(0,u.jA)(n))return e.map(e=>$(e,g.A.WGS84)).map(e=>J(e,g.A.WGS84,n));if(!j())throw new U;if(!r?.geographicTransformation)if(r?.extendedParams)r={...r,geographicTransformation:A.getTransformation(t,n,r.areaOfInterestExtent)||new h.A};else if(!r?.areaOfInterestExtent){const e=function(e,t){return[e.wkid?.toString()??"-1",e.wkt?.toString()??"",e.wkt2?.toString()??"",t.wkid?.toString()??"-1",t.wkt?.toString()??"",t.wkt2?.toString()??""].join()}(t,n);let i=F[e];i||(i=A.getTransformation(t,n)||new h.A,F[e]=i),r={geographicTransformation:i}}return e[0].spatialReference||(e[0].spatialReference=t),e[0]instanceof c.A?x.executeMany(e,n,r):b.executeMany(e,n,r)}function k(e,t){const n=G([e],t);return null!=n.pending?{pending:n.pending,geometry:null}:null!=n.geometries?{pending:null,geometry:n.geometries[0]}:{pending:null,geometry:null}}function G(e,t){if(!j())for(const n of e)if(null!=n&&!(0,M.aI)(n.spatialReference,t)&&(0,M.fn)(n.spatialReference)&&(0,M.fn)(t)&&!q(n.spatialReference,t))return(0,o.gc)(P),{pending:E(),geometries:null};return{pending:null,geometries:e.map(e=>null==e?null:(0,M.aI)(e.spatialReference,t)?e:(0,M.fn)(e.spatialReference)&&(0,M.fn)(t)?$(e,t):null)}}class U extends r.A{constructor(){super("projection:not-loaded","projection engine not fully loaded yet, please call load()")}}function _(){T=null,x=null,b=null,A=null,F={}}const L={get loadPromise(){return T}};function $(e,t){try{const n=N(e,t);if(null==n)return null;"xmin"in e&&"xmin"in n&&(n.zmin=e.zmin,n.zmax=e.zmax);const r=(0,S.N)(n.type,e.spatialReference,t);return null!=r&&r(n),n}catch(e){if(!(e instanceof U))throw e;return null}}async function B(e,t,n){const r=e.spatialReference;return null!=r&&null!=t&&await K(r,t,null,n),$(e,t)}function q(e,t,n){return!(n?.areaOfInterestExtent||n?.extendedParams||n?.geographicTransformation)&&(!!(0,M.aI)(e,t)||(0,M.fn)(e)&&(0,M.fn)(t)&&!!(0,v.jd)(e,t))}function z(e,t){if((0,M.aI)(e,t))return!0;if(!(0,M.fn)(e)||!(0,M.fn)(t))return!1;const n=(0,M.oT)(e)||(0,M.K8)(e)||(0,M.x1)(e),r=(0,M.oT)(t)||(0,M.K8)(t)||(0,M.x1)(t);return n&&r}async function K(e,t,n,r){if(j())return(0,i.NO)(r);if(Array.isArray(e)){for(const{source:t,dest:n,options:i}of e)if(t&&n&&!q(t,n,i))return E(r)}else if(e&&t&&!q(e,t,n))return E(r);return(0,i.NO)(r)}function J(e,t,n){return e?"x"in e?Q(e,t,new f.A,n,0):"xmin"in e?re(e,t,new p.A,n,0):"rings"in e?te(e,t,new y.A,n,0):"paths"in e?X(e,t,new m.A,n,0):"points"in e?V(e,t,new d.A,n,0):null:null}function H(e,t,n=t.spatialReference,r=0){return null!=n&&null!=e.spatialReference&&null!=Q(e,e.spatialReference,t,n,r)}function Q(e,t,n,r,i){oe[0]=e.x,oe[1]=e.y;const o=e.z;return oe[2]=void 0!==o?o:i,(0,w.projectBuffer)(oe,t,0,oe,r,0)?(n.x=oe[0],n.y=oe[1],n.spatialReference=r,void 0!==o||(0,u.xP)(r)?(n.z=oe[2],n.hasZ=!0):(n.z=void 0,n.hasZ=!1),void 0===e.m?(n.m=void 0,n.hasM=!1):(n.m=e.m,n.hasM=!0),n):null}function W(e,t,n=t.spatialReference,r=0){return null!=e.spatialReference&&null!=n&&null!=V(e,e.spatialReference,t,n,r)}function V(e,t,n,r,i){const{points:o,hasZ:s,hasM:l}=e,a=[],p=o.length,c=[];for(const e of o)c.push(e[0],e[1],s?e[2]:i);if(!(0,w.projectBuffer)(c,t,0,c,r,0,p))return null;const d=s||(0,u.xP)(r);for(let e=0;e<p;++e){const t=3*e,n=c[t],r=c[t+1];d&&l?a.push([n,r,c[t+2],o[e][3]]):d?a.push([n,r,c[t+2]]):l?a.push([n,r,o[e][2]]):a.push([n,r])}return n.points=a,n.spatialReference=r,n.hasZ=s,n.hasM=l,n}function Y(e,t,n=t.spatialReference,r=0){return null!=e.spatialReference&&null!=n&&null!=X(e,e.spatialReference,t,n,r)}function X(e,t,n,r,i){const{paths:o,hasZ:s,hasM:l}=e,a=[];if(!ie(o,s??!1,l??!1,t,a,r,i))return null;const p=s||(0,u.xP)(r);return n.paths=a,n.spatialReference=r,n.hasZ=p,n.hasM=l,n}function ee(e,t,n=t.spatialReference,r=0){return null!=e.spatialReference&&null!=n&&null!=te(e,e.spatialReference,t,n,r)}function te(e,t,n,r,i){const{rings:o,hasZ:s,hasM:l}=e,a=[];if(!ie(o,s??!1,l??!1,t,a,r,i))return null;const p=s||(0,u.xP)(r);return n.rings=a,n.spatialReference=r,n.hasZ=p,n.hasM=l,n}function ne(e,t,n=t.spatialReference,r=0){return null!=e.spatialReference&&null!=n&&null!=re(e,e.spatialReference,t,n,r)}function re(e,t,n,r,i){const{xmin:o,ymin:s,xmax:l,ymax:a,hasZ:p,hasM:c}=e;if(!C(o,s,p?e.zmin:i,t,oe,r))return null;const d=p||(0,u.xP)(r);return n.xmin=oe[0],n.ymin=oe[1],d&&(n.zmin=oe[2]),C(l,a,p?e.zmax:i,t,oe,r)?(n.xmax=oe[0],n.ymax=oe[1],d&&(n.zmax=oe[2]),c&&(n.mmin=e.mmin,n.mmax=e.mmax),n.spatialReference=r,n):null}function ie(e,t,n,r,i,o,s=0){const l=new Array;for(const n of e)for(const e of n)l.push(e[0],e[1],t?e[2]:s);if(!(0,w.projectBuffer)(l,r,0,l,o,0))return!1;let a=0;i.length=0;const p=t||(0,u.xP)(o);for(const t of e){const e=new Array;for(const r of t)p&&n?e.push([l[a++],l[a++],l[a++],r[3]]):p?e.push([l[a++],l[a++],l[a++]]):n?(e.push([l[a++],l[a++],r[2]]),a++):(e.push([l[a++],l[a++]]),a++);i.push(e)}return!0}const oe=(0,l.vt)()},91880:(e,t,n)=>{n.d(t,{A:()=>u});var r,i=n(31635),o=n(66552),s=n(25482),l=n(91429);const a=new o.J({asc:"ascending",desc:"descending"});let u=class extends s.o{static{r=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new r({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,i.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],u.prototype,"field",void 0),(0,i.Cg)([(0,l.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],u.prototype,"valueExpression",void 0),(0,i.Cg)([(0,l.MZ)({type:a.apiValues,json:{type:a.jsonValues,read:a.read,write:a.write}})],u.prototype,"order",void 0),u=r=(0,i.Cg)([(0,l.$K)("esri.layers.support.OrderByInfo")],u)},96184:(e,t,n)=>{n.d(t,{A:()=>f});var r=n(31635),i=n(69540),o=n(25482),s=n(91429),l=n(79677),a=n(10184),u=n(56400),p=n(36005),c=n(43937);function d(e,t){return a.A.fromJSON({value:e,unit:t})}let f=class extends((0,i.OU)(o.o)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?l.A.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?d(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?d(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,r.Cg)([(0,s.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],f.prototype,"cumulative",void 0),(0,r.Cg)([(0,s.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"endField",void 0),(0,r.Cg)([(0,s.MZ)({type:l.A,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"fullTimeExtent",void 0),(0,r.Cg)([(0,p.w)("fullTimeExtent",["timeExtent"])],f.prototype,"readFullTimeExtent",null),(0,r.Cg)([(0,c.K)("fullTimeExtent")],f.prototype,"writeFullTimeExtent",null),(0,r.Cg)([(0,s.MZ)({type:Boolean,json:{write:!0}})],f.prototype,"hasLiveData",void 0),(0,r.Cg)([(0,s.MZ)({type:a.A,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"interval",void 0),(0,r.Cg)([(0,p.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],f.prototype,"readInterval",null),(0,r.Cg)([(0,c.K)("interval")],f.prototype,"writeInterval",null),(0,r.Cg)([(0,s.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"startField",void 0),(0,r.Cg)([(0,s.MZ)((0,u.P6)("timeReference",!0))],f.prototype,"timeZone",void 0),(0,r.Cg)([(0,s.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"trackIdField",void 0),(0,r.Cg)([(0,s.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],f.prototype,"useTime",void 0),(0,r.Cg)([(0,s.MZ)({type:[Date],json:{read:!1}})],f.prototype,"stops",void 0),f=(0,r.Cg)([(0,s.$K)("esri.layers.support.TimeInfo")],f)},99157:(e,t,n)=>{n.d(t,{A:()=>l});var r,i=n(31635),o=n(69622),s=n(91429);let l=r=class extends o.A{constructor(e){super(e),this.isInverse=!1,this.wkt=null,this.wkid=null}getInverse(){return new r({isInverse:!this.isInverse,wkid:this.wkid,wkt:this.wkt})}};(0,i.Cg)([(0,s.MZ)()],l.prototype,"isInverse",void 0),(0,i.Cg)([(0,s.MZ)()],l.prototype,"wkt",void 0),(0,i.Cg)([(0,s.MZ)()],l.prototype,"wkid",void 0),l=r=(0,i.Cg)([(0,s.$K)("esri.geometry.operators.support.GeographicTransformationStep")],l)},99352:(e,t,n)=>{n.d(t,{F:()=>r,P:()=>i});const r={supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!0,supportsCentroidOnDegeneratedQuantizedGeometry:!0,supportsCacheHint:!0,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDistance:!0,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsPaginationOnAggregatedQueries:!1,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!0,supportsReturnMesh:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,maxUniqueIDCount:void 0,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0,supportsTrueCurve:!1},i={supportsDate:!0,supportsFixedInterval:!0,supportsAutoInterval:!0,supportsFixedBoundaries:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!0,supportedStatistics:{count:!0,sum:!0,avg:!0,var:!0,stddev:!0,min:!0,max:!0,percentileContinuous:!0,percentileDiscrete:!0,envelope:!0,centroid:!0,convexHull:!0},supportedNormalizationTypes:{field:!0,log:!0,naturalLog:!0,percentOfTotal:!0,squareRoot:!0}}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1698],{24045:(e,t,r)=>{function o(e,t){const r=e.count;t||(t=new e.TypedArrayConstructor(r));for(let o=0;o<r;o++)t[o]=e.get(o);return t}r.d(t,{m:()=>o}),Object.freeze(Object.defineProperty({__proto__:null,makeDense:o},Symbol.toStringTag,{value:"Module"}))},51698:(e,t,r)=>{r.d(t,{loadGLTF:()=>j});var o=r(53966),n=r(93637),s=r(9093),a=r(49186),i=r(91869),u=r(74887),l=r(84952),c=r(46140),f=r(58083),d=r(67026),p=r(82534),m=r(13030),h=r(24045),T=(r(44208),r(2741));let w;function g(){return w??=(async()=>{const{default:e}=await r.e(2423).then(r.bind(r,2423));return await e({locateFile:e=>(0,T.s)(`esri/libs/dracoMeshDecoder/${e}`)})})(),w}class b{constructor(e){this._data=e,this._offset4=0,this._dataUint32=new Uint32Array(this._data,0,Math.floor(this._data.byteLength/4))}readUint32(){const e=this._offset4;return this._offset4+=1,this._dataUint32[e]}readUint8Array(e){const t=4*this._offset4;return this._offset4+=e/4,new Uint8Array(this._data,t,e)}remainingBytes(){return this._data.byteLength-4*this._offset4}}var y=r(21818);const x={baseColorFactor:[1,1,1,1],metallicFactor:1,roughnessFactor:1},_={pbrMetallicRoughness:x,emissiveFactor:[0,0,0],alphaMode:"OPAQUE",alphaCutoff:.5,doubleSided:!1},S={ESRI_externalColorMixMode:"tint",ESRI_receiveShadows:!0,ESRI_receiveAmbientOcclusion:!0},A=(e={})=>{const t={...x,...e.pbrMetallicRoughness},r=function(e){switch(e.ESRI_externalColorMixMode){case"multiply":case"tint":case"ignore":case"replace":break;default:(0,y.Xb)(e.ESRI_externalColorMixMode),e.ESRI_externalColorMixMode="tint"}return e}({...S,...e.extras});return{..._,...e,pbrMetallicRoughness:t,extras:r}},O={magFilter:9729,minFilter:9987,wrapS:10497,wrapT:10497},v=e=>({...O,...e});var R=r(51530),N=r(63907);const C=1179937895;class E{constructor(e,t,r,o){if(this._context=e,this.uri=t,this.json=r,this._glbBuffer=o,this._bufferLoaders=new Map,this._textureLoaders=new Map,this._dracoBuffersSize=0,this._textureCache=new Map,this._materialCache=new Map,this._nodeParentMap=new Map,this._nodeTransformCache=new Map,this._supportedExtensions=["KHR_texture_basisu","KHR_texture_transform","KHR_draco_mesh_compression","KHR_materials_emissive_strength"],this._baseUri=function(e){let t,r;return e.replace(/^(.*\/)?([^/]*)$/,(e,o,n)=>(t=o||"",r=n||"","")),{dirPart:t,filePart:r}}(this.uri).dirPart,this._checkVersionSupported(),this._checkRequiredExtensionsSupported(),null==r.scenes)throw new a.A("gltf-loader-unsupported-feature","Scenes must be defined.");if(null==r.meshes)throw new a.A("gltf-loader-unsupported-feature","Meshes must be defined");if(null==r.nodes)throw new a.A("gltf-loader-unsupported-feature","Nodes must be defined.");this._computeNodeParents()}static async load(e,t,r){if((0,l.DB)(t)){const r=(0,l.r$)(t);if(r&&"model/gltf-binary"!==r.mediaType)try{const o=JSON.parse(r.isBase64?atob(r.data):r.data);return new E(e,t,o)}catch{}const o=(0,l.lJ)(t);if(E._isGLBData(o))return this._fromGLBData(e,t,o)}if(G.test(t)||"gltf"===r?.expectedType){const o=await e.loadJSON(t,r);return new E(e,t,o)}const o=await e.loadBinary(t,r);if(E._isGLBData(o))return this._fromGLBData(e,t,o);if(P.test(t)||"glb"===r?.expectedType)throw new a.A("gltf-loader-invalid-glb","This is not a valid glb file.");const n=await e.loadJSON(t,r);return new E(e,t,n)}static _isGLBData(e){if(null==e)return!1;const t=new b(e);return t.remainingBytes()>=4&&t.readUint32()===C}static async _fromGLBData(e,t,r){const o=await E._parseGLBData(r);return new E(e,t,o.json,o.binaryData)}static async _parseGLBData(e){const t=new b(e);if(t.remainingBytes()<12)throw new a.A("gltf-loader-error","glb binary data is insufficiently large.");const r=t.readUint32(),n=t.readUint32(),s=t.readUint32();if(r!==C)throw new a.A("gltf-loader-error","Magic first 4 bytes do not fit to expected glb value.");if(e.byteLength<s)throw new a.A("gltf-loader-error","glb binary data is smaller than header specifies.");if(2!==n)throw new a.A("gltf-loader-unsupported-feature","An unsupported glb container version was detected. Only version 2 is supported.");let i,u,l=0;for(;t.remainingBytes()>=8;){const e=t.readUint32(),r=t.readUint32();if(0===l){if(1313821514!==r)throw new a.A("gltf-loader-error","First glb chunk must be JSON.");if(e<0)throw new a.A("gltf-loader-error","No JSON data found.");i=await(0,R.KB)(t.readUint8Array(e))}else if(1===l){if(5130562!==r)throw new a.A("gltf-loader-unsupported-feature","Second glb chunk expected to be BIN.");u=t.readUint8Array(e)}else o.A.getLogger("esri.views.3d.glTF").warn("[Unsupported Feature] More than 2 glb chunks detected. Skipping.");l+=1}if(!i)throw new a.A("gltf-loader-error","No glb JSON chunk detected.");return{json:i,binaryData:u}}async getBuffer(e,t){const r=this.json.buffers[e];if(null==r.uri){if(null==this._glbBuffer)throw new a.A("gltf-loader-error","glb buffer not present");return this._glbBuffer}const o=await this._getBufferLoader(e,t);if(o.byteLength!==r.byteLength)throw new a.A("gltf-loader-error","Buffer byte lengths should match.");return o}async _getBufferLoader(e,t){const r=this._bufferLoaders.get(e);if(r)return r;const o=this.json.buffers[e].uri,n=this._context.loadBinary(this._resolveUri(o),t).then(e=>new Uint8Array(e));return this._bufferLoaders.set(e,n),n}_validateAccessor(e){if(!this.json.accessors)throw new a.A("gltf-loader-unsupported-feature","Accessors missing.");const t=this.json.accessors[e];if(t.type in["MAT2","MAT3","MAT4"])throw new a.A("gltf-loader-unsupported-feature",`AttributeType ${t.type} is not supported`);return t}_getComponentInfo(e,t){const r=F[e.type],o=t?.componentType||e.componentType,n=D[o];return{componentType:o,componentCount:r,componentByteSize:n,denseByteStride:r*n}}getDracoAccessor(e,t){const r=this._validateAccessor(e),o=t.accessorInfos.get(e),{componentType:n,componentCount:s,componentByteSize:a,denseByteStride:i}=this._getComponentInfo(r,o);return{raw:t.data.buffer,byteStride:i,byteOffset:t.data.byteOffset+(o?.byteOffset||0),entryCount:o?.count??r.count,isDenselyPacked:!0,componentCount:s,componentByteSize:a,componentType:n,min:r.min,max:r.max,normalized:!!r.normalized}}async getAccessor(e,t){const r=this._validateAccessor(e);if(null==r?.bufferView)throw new a.A("gltf-loader-unsupported-feature","Some accessor does not specify a bufferView.");const{componentCount:o,componentByteSize:n,denseByteStride:s}=this._getComponentInfo(r),i=this.json.bufferViews[r.bufferView],u=await this.getBuffer(i.buffer,t),l=i.byteStride||s;return{raw:u.buffer,byteStride:l,byteOffset:u.byteOffset+(i.byteOffset||0)+(r.byteOffset||0),entryCount:r.count,isDenselyPacked:l===s,componentCount:o,componentByteSize:n,componentType:r.componentType,min:r.min,max:r.max,normalized:!!r.normalized}}async getIndexData(e,t,r){if(null==e.indices)return;const o=e.indices,n=r?this.getDracoAccessor(o,r):await this.getAccessor(o,t);if(n.isDenselyPacked)switch(n.componentType){case N.pe.UNSIGNED_BYTE:return new Uint8Array(n.raw,n.byteOffset,n.entryCount);case N.pe.UNSIGNED_SHORT:return new Uint16Array(n.raw,n.byteOffset,n.entryCount);case N.pe.UNSIGNED_INT:return new Uint32Array(n.raw,n.byteOffset,n.entryCount)}else switch(n.componentType){case N.pe.UNSIGNED_BYTE:return(0,h.m)(U(m.SL,n));case N.pe.UNSIGNED_SHORT:return(0,h.m)(U(m.h,n));case N.pe.UNSIGNED_INT:return(0,h.m)(U(m.P,n))}}async getPositionData(e,t,r){if(null==e.attributes.POSITION)throw new a.A("gltf-loader-unsupported-feature","No POSITION vertex data found.");const o=e.attributes.POSITION,s=r?this.getDracoAccessor(o,r):await this.getAccessor(o,t);if(s.componentType!==N.pe.FLOAT)throw new a.A("gltf-loader-unsupported-feature","Expected type FLOAT for POSITION vertex attribute, but found "+(0,n.i7)(N.pe,s.componentType));if(3!==s.componentCount)throw new a.A("gltf-loader-unsupported-feature","POSITION vertex attribute must have 3 components, but found "+s.componentCount.toFixed());return U(m.xs,s)}async getNormalData(e,t,r){if(null==e.attributes.NORMAL)throw new a.A("gltf-loader-error","No NORMAL vertex data found.");const o=e.attributes.NORMAL,s=r?this.getDracoAccessor(o,r):await this.getAccessor(o,t);if(s.componentType!==N.pe.FLOAT)throw new a.A("gltf-loader-unsupported-feature","Expected type FLOAT for NORMAL vertex attribute, but found "+(0,n.i7)(N.pe,s.componentType));if(3!==s.componentCount)throw new a.A("gltf-loader-unsupported-feature","NORMAL vertex attribute must have 3 components, but found "+s.componentCount.toFixed());return U(m.xs,s)}async getTangentData(e,t,r){if(null==e.attributes.TANGENT)throw new a.A("gltf-loader-error","No TANGENT vertex data found.");const o=e.attributes.TANGENT,s=r?this.getDracoAccessor(o,r):await this.getAccessor(o,t);if(s.componentType!==N.pe.FLOAT)throw new a.A("gltf-loader-unsupported-feature","Expected type FLOAT for TANGENT vertex attribute, but found "+(0,n.i7)(N.pe,s.componentType));if(4!==s.componentCount)throw new a.A("gltf-loader-unsupported-feature","TANGENT vertex attribute must have 4 components, but found "+s.componentCount.toFixed());return U(m.Eq,s)}async getTextureCoordinates(e,t,r){if(null==e.attributes.TEXCOORD_0)throw new a.A("gltf-loader-error","No TEXCOORD_0 vertex data found.");const o=e.attributes.TEXCOORD_0,n=r?this.getDracoAccessor(o,r):await this.getAccessor(o,t);if(2!==n.componentCount)throw new a.A("gltf-loader-unsupported-feature","TEXCOORD_0 vertex attribute must have 2 components, but found "+n.componentCount.toFixed());if(n.componentType===N.pe.FLOAT)return U(m.gH,n);if(!n.normalized)throw new a.A("gltf-loader-unsupported-feature","Integer component types are only supported for a normalized accessor for TEXCOORD_0.");return function(e){switch(e.componentType){case N.pe.BYTE:return new m.D6(e.raw,e.byteOffset,e.byteStride,e.byteOffset+e.byteStride*e.entryCount);case N.pe.UNSIGNED_BYTE:return new m.LC(e.raw,e.byteOffset,e.byteStride,e.byteOffset+e.byteStride*e.entryCount);case N.pe.SHORT:return new m.mJ(e.raw,e.byteOffset,e.byteStride,e.byteOffset+e.byteStride*e.entryCount);case N.pe.UNSIGNED_SHORT:return new m.Yi(e.raw,e.byteOffset,e.byteStride,e.byteOffset+e.byteStride*e.entryCount);case N.pe.UNSIGNED_INT:return new m.An(e.raw,e.byteOffset,e.byteStride,e.byteOffset+e.byteStride*e.entryCount);case N.pe.FLOAT:return new m.gH(e.raw,e.byteOffset,e.byteStride,e.byteOffset+e.byteStride*e.entryCount)}}(n)}async getVertexColors(e,t,r){if(null==e.attributes.COLOR_0)throw new a.A("gltf-loader-error","No COLOR_0 vertex data found.");const o=e.attributes.COLOR_0,s=r?this.getDracoAccessor(o,r):await this.getAccessor(o,t);if(4!==s.componentCount&&3!==s.componentCount)throw new a.A("gltf-loader-unsupported-feature","COLOR_0 attribute must have 3 or 4 components, but found "+s.componentCount.toFixed());if(4===s.componentCount){if(s.componentType===N.pe.FLOAT)return U(m.Eq,s);if(s.componentType===N.pe.UNSIGNED_BYTE)return U(m.XP,s);if(s.componentType===N.pe.UNSIGNED_SHORT)return U(m.Uz,s)}else if(3===s.componentCount){if(s.componentType===N.pe.FLOAT)return U(m.xs,s);if(s.componentType===N.pe.UNSIGNED_BYTE)return U(m.eI,s);if(s.componentType===N.pe.UNSIGNED_SHORT)return U(m.nS,s)}throw new a.A("gltf-loader-unsupported-feature","Unsupported component type for COLOR_0 attribute: "+(0,n.i7)(N.pe,s.componentType))}hasPositions(e){return void 0!==e.attributes.POSITION}hasNormals(e){return void 0!==e.attributes.NORMAL}hasVertexColors(e){return void 0!==e.attributes.COLOR_0}hasTextureCoordinates(e){return void 0!==e.attributes.TEXCOORD_0}hasTangents(e){return void 0!==e.attributes.TANGENT}async getMaterial(e,t,r){let o=e.material?this._materialCache.get(e.material):void 0;if(!o){const n=null!=e.material?A(this.json.materials[e.material]):A(),s=n.pbrMetallicRoughness,a=this.hasVertexColors(e),i=this.getTexture(s.baseColorTexture,t),u=this.getTexture(n.normalTexture,t),l=r?this.getTexture(n.occlusionTexture,t):void 0,c=r?this.getTexture(n.emissiveTexture,t):void 0,f=r?this.getTexture(s.metallicRoughnessTexture,t):void 0,d=null!=e.material?e.material:-1;o={alphaMode:n.alphaMode,alphaCutoff:n.alphaCutoff,color:s.baseColorFactor,doubleSided:!!n.doubleSided,colorTexture:await i,normalTexture:await u,name:n.name,id:d,occlusionTexture:await l,emissiveTexture:await c,emissiveFactor:n.emissiveFactor,emissiveStrengthKHR:n.extensions?.KHR_materials_emissive_strength?.emissiveStrength,metallicFactor:s.metallicFactor,roughnessFactor:s.roughnessFactor,metallicRoughnessTexture:await f,hasVertexColors:a,ESRI_externalColorMixMode:n.extras.ESRI_externalColorMixMode,colorTextureTransform:s?.baseColorTexture?.extensions?.KHR_texture_transform,normalTextureTransform:n.normalTexture?.extensions?.KHR_texture_transform,occlusionTextureTransform:n.occlusionTexture?.extensions?.KHR_texture_transform,emissiveTextureTransform:n.emissiveTexture?.extensions?.KHR_texture_transform,metallicRoughnessTextureTransform:s?.metallicRoughnessTexture?.extensions?.KHR_texture_transform,receiveAmbientOcclusion:n.extras.ESRI_receiveAmbientOcclusion,receiveShadows:n.extras.ESRI_receiveShadows}}return o}async decode(e,t){const r=e.extensions?.KHR_draco_mesh_compression;if(!r)return;if(null==e.indices)throw new a.A("gltf-loader-error","Found Draco compressed primitive without indices.");const o=this.json.bufferViews[r.bufferView],n=await this.getBuffer(o.buffer,t),s=(await g()).decode(new Uint8Array(n.buffer,n.byteOffset+(o.byteOffset||0),o.byteLength));this._bufferLoaders.delete(o.buffer);const i=new Map([[e.indices,s.indices],[e.attributes.POSITION,s.positions]]);return e.attributes.TEXCOORD_0&&i.set(e.attributes.TEXCOORD_0,s.uvs),e.attributes.NORMAL&&i.set(e.attributes.NORMAL,s.normals),e.attributes.COLOR_0&&i.set(e.attributes.COLOR_0,s.colors),e.attributes.TANGENT&&i.set(e.attributes.TANGENT,s.tangents),this._dracoBuffersSize+=s.buffer.byteLength,{data:s.buffer,accessorInfos:i}}async getTexture(e,t){if(!e)return;if(0!==(e.texCoord||0))throw new a.A("gltf-loader-unsupported-feature","Only TEXCOORD with index 0 is supported.");const r=e.index,o=this.json.textures[r],n=v(null!=o.sampler?this.json.samplers[o.sampler]:{}),s=B(o),u=this.json.images[s],l=await this._loadTextureImageData(r,o,t);return(0,i.tE)(this._textureCache,r,()=>{const e=e=>33071===e||33648===e||10497===e,t=e=>{throw new a.A("gltf-loader-error",`Unexpected TextureSampler WrapMode: ${e}`)};return{data:l,wrapS:e(n.wrapS)?n.wrapS:t(n.wrapS),wrapT:e(n.wrapT)?n.wrapT:t(n.wrapT),minFilter:n.minFilter,name:u.name,id:r}})}getNodeTransform(e){if(void 0===e)return I;let t=this._nodeTransformCache.get(e);if(!t){const r=this.getNodeTransform(this._getNodeParent(e)),o=this.json.nodes[e];o.matrix?t=(0,f.lw)((0,s.vt)(),r,o.matrix):o.translation||o.rotation||o.scale?(t=(0,s.o8)(r),o.translation&&(0,f.Tl)(t,t,o.translation),o.rotation&&(M[3]=(0,d.Xd)(M,o.rotation),(0,f.e$)(t,t,M[3],M)),o.scale&&(0,f.hs)(t,t,o.scale)):t=(0,s.o8)(r),this._nodeTransformCache.set(e,t)}return t}_resolveUri(e){return(0,l.s2)(e,this._baseUri)}_getNodeParent(e){return this._nodeParentMap.get(e)}_checkVersionSupported(){const e=c.R.parse(this.json.asset.version,"glTF");L.validate(e)}_checkRequiredExtensionsSupported(){const e=this.json;if(e.extensionsRequired&&!e.extensionsRequired.every(e=>this._supportedExtensions.includes(e)))throw new a.A("gltf-loader-unsupported-feature","gltf loader was not able to load unsupported feature. Required extensions: "+e.extensionsRequired.join(", "))}_computeNodeParents(){this.json.nodes.forEach((e,t)=>{e.children&&e.children.forEach(e=>{this._nodeParentMap.set(e,t)})})}async _loadTextureImageData(e,t,r){const o=this._textureLoaders.get(e);if(o)return o;const n=this._createTextureLoader(t,r);return this._textureLoaders.set(e,n),n}async _createTextureLoader(e,t){const r=B(e),o=this.json.images[r];if(o.uri){if(o.uri.endsWith(".ktx2")){const e=await this._context.loadBinary(this._resolveUri(o.uri),t);return new R.Xi(new Uint8Array(e))}return this._context.loadImage(this._resolveUri(o.uri),t)}if(null==o.bufferView)throw new a.A("gltf-loader-unsupported-feature","Image bufferView must be defined.");if(null==o.mimeType)throw new a.A("gltf-loader-unsupported-feature","Image mimeType must be defined.");const n=this.json.bufferViews[o.bufferView],s=await this.getBuffer(n.buffer,t);if(null!=n.byteStride)throw new a.A("gltf-loader-unsupported-feature","byteStride not supported for image buffer");const i=s.byteOffset+(n.byteOffset||0);return(0,R.pn)(new Uint8Array(s.buffer,i,n.byteLength),o.mimeType)}async getLoadedBuffersSize(){if(this._glbBuffer)return this._glbBuffer.byteLength;const e=await(0,u.nA)(Array.from(this._bufferLoaders.values())),t=await(0,u.nA)(Array.from(this._textureLoaders.values()));return e.reduce((e,t)=>e+(t?.byteLength??0),0)+this._dracoBuffersSize+t.reduce((e,t)=>e+(t?(0,R.x3)(t)?t.data.byteLength:t.width*t.height*4:0),0)}}const I=(0,f.hM)((0,s.vt)(),Math.PI/2),L=new c.R(2,0,"glTF"),M=(0,p.vt)(),F={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},D={[N.pe.BYTE]:1,[N.pe.UNSIGNED_BYTE]:1,[N.pe.SHORT]:2,[N.pe.UNSIGNED_SHORT]:2,[N.pe.HALF_FLOAT]:2,[N.pe.FLOAT]:4,[N.pe.INT]:4,[N.pe.UNSIGNED_INT]:4};function U(e,t){return new e(t.raw,t.byteOffset,t.byteStride,t.byteOffset+t.byteStride*(t.entryCount-1)+t.componentByteSize*t.componentCount)}function B(e){if(null!=e.extensions?.KHR_texture_basisu)return e.extensions.KHR_texture_basisu.source;if(null!==e.source)return e.source;throw new a.A("gltf-loader-unsupported-feature","Source is expected to be defined for a texture. It can also be omitted in favour of an KHR_texture_basisu extension tag.")}const G=/\.gltf$/i,P=/\.glb$/i;let H=0;async function j(e,t,r={},a=!0){const i=await E.load(e,t,r),u="gltf_"+H++,l={lods:[],materials:new Map,textures:new Map,meta:k(i)},c=!(!i.json.asset.extras||"symbolResource"!==i.json.asset.extras.ESRI_type),f=i.json.asset.extras?.ESRI_webstyleSymbol?.webstyle,d=new Map;let p=!1;await V(i,async(e,t,c,f)=>{const m=d.get(c)??0;d.set(c,m+1);const h=void 0!==e.mode?e.mode:N.WR.TRIANGLES,T=h===N.WR.TRIANGLES||h===N.WR.TRIANGLE_STRIP||h===N.WR.TRIANGLE_FAN?h:null;if(null==T)return void o.A.getLogger("esri.views.3d.glTF").warn("[Unsupported Feature] Unsupported primitive mode ("+(0,n.i7)(N.WR,h)+"). Skipping primitive.");if(!i.hasPositions(e))return void o.A.getLogger("esri.views.3d.glTF").warn("Skipping primitive without POSITION vertex attribute.");const w=await i.decode(e,r);p||=!!w;const g=i.getPositionData(e,r,w),b=i.getMaterial(e,r,a),y=i.hasNormals(e)?i.getNormalData(e,r,w):null,x=i.hasTangents(e)?i.getTangentData(e,r,w):null,_=i.hasTextureCoordinates(e)?i.getTextureCoordinates(e,r,w):null,S=i.hasVertexColors(e)?i.getVertexColors(e,r,w):null,A=i.getIndexData(e,r,w),O={name:f,transform:(0,s.o8)(t),attributes:{position:await g,normal:y?await y:null,texCoord0:_?await _:null,color:S?await S:null,tangent:x?await x:null},indices:await A,primitiveType:T,material:K(l,await b,u)};let v=null;null!=l.meta?.ESRI_lod&&"screenSpaceRadius"===l.meta.ESRI_lod.metric&&(v=l.meta.ESRI_lod.thresholds[c]),l.lods[c]=l.lods[c]||{parts:[],name:f,lodThreshold:v},l.lods[c].parts[m]=O});for(const e of l.lods)e.parts=e.parts.filter(e=>!!e);const m=await i.getLoadedBuffersSize();return{model:l,meta:{isEsriSymbolResource:c,uri:i.uri,ESRI_webstyle:f,isDracoDecompressed:p},customMeta:{},usedMemory:m}}function k(e){const t=e.json;let r=null;return t.nodes.forEach(e=>{const t=e.extras;null!=t&&(t.ESRI_proxyEllipsoid||t.ESRI_lod)&&(r=t)}),r}async function V(e,t){const r=e.json,n=r.scenes[r.scene||0].nodes,s=n.length>1,a=[];for(const e of n){const t=r.nodes[e];a.push(i(e,0)),z(t)&&!s&&t.extensions.MSFT_lod.ids.forEach((e,t)=>i(e,t+1))}async function i(n,s){const u=r.nodes[n],l=e.getNodeTransform(n);if(null!=u.weights&&o.A.getLogger("esri.views.3d.glTF").warn("[Unsupported Feature] Morph targets are not supported."),null!=u.mesh){const e=r.meshes[u.mesh];for(const r of e.primitives)a.push(t(r,l,s,e.name))}for(const e of u.children||[])a.push(i(e,s))}await Promise.all(a)}function z(e){return e.extensions?.MSFT_lod&&Array.isArray(e.extensions.MSFT_lod.ids)}function K(e,t,r){const o=t=>{const o=`${r}_tex_${t&&t.id}${t?.name?"_"+t.name:""}`;if(t&&!e.textures.has(o)){const r=function(e,t={}){return{data:e,parameters:{wrap:{s:10497,t:10497,...t.wrap},noUnpackFlip:!0,mipmap:!1,...t}}}(t.data,{wrap:{s:t.wrapS,t:t.wrapT},mipmap:$.has(t.minFilter),noUnpackFlip:!0});e.textures.set(o,r)}return o},n=`${r}_mat_${t.id}_${t.name}`;if(!e.materials.has(n)){const r=function(e={}){return{color:[1,1,1],opacity:1,alphaMode:"OPAQUE",alphaCutoff:.5,doubleSided:!1,castShadows:!0,receiveShadows:!0,receiveAmbientOcclusion:!0,colorTexture:null,normalTexture:null,occlusionTexture:null,emissiveTexture:null,emissiveStrengthKHR:null,metallicRoughnessTexture:null,colorTextureTransform:null,normalTextureTransform:null,occlusionTextureTransform:null,emissiveTextureTransform:null,metallicRoughnessTextureTransform:null,emissiveFactor:[0,0,0],metallicFactor:1,roughnessFactor:1,colorMixMode:"multiply",...e}}({color:[t.color[0],t.color[1],t.color[2]],opacity:t.color[3],alphaMode:t.alphaMode,alphaCutoff:t.alphaCutoff,doubleSided:t.doubleSided,colorMixMode:t.ESRI_externalColorMixMode,colorTexture:t.colorTexture?o(t.colorTexture):void 0,normalTexture:t.normalTexture?o(t.normalTexture):void 0,occlusionTexture:t.occlusionTexture?o(t.occlusionTexture):void 0,emissiveTexture:t.emissiveTexture?o(t.emissiveTexture):void 0,metallicRoughnessTexture:t.metallicRoughnessTexture?o(t.metallicRoughnessTexture):void 0,emissiveFactor:[t.emissiveFactor[0],t.emissiveFactor[1],t.emissiveFactor[2]],emissiveStrengthKHR:t.emissiveStrengthKHR,colorTextureTransform:t.colorTextureTransform,normalTextureTransform:t.normalTextureTransform,occlusionTextureTransform:t.occlusionTextureTransform,emissiveTextureTransform:t.emissiveTextureTransform,metallicRoughnessTextureTransform:t.metallicRoughnessTextureTransform,metallicFactor:t.metallicFactor,roughnessFactor:t.roughnessFactor,receiveShadows:t.receiveShadows,receiveAmbientOcclusion:t.receiveAmbientOcclusion});e.materials.set(n,r)}return n}const $=new Set([9987,9985])}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9466],{7142:(t,e,r)=>{function n(t,e){return s(t,"any",e?.origin)}function o(t,e){return s(t,"read",e?.origin)}function i(t,e){return s(t,"write",e?.origin)}function s(t,e,r){let n=t?.json;if(n?.origins&&r){let t;t="link-chart"===r?n.origins[r]&&("any"===e||e in n.origins[r])?n.origins[r]:n.origins["web-map"]:n.origins[r],t&&("any"===e||e in t)&&(n=t)}return n}r.d(e,{N5:()=>o,k4:()=>i,xF:()=>n})},10107:(t,e,r)=>{r.d(e,{MZ:()=>c,rM:()=>l});var n=r(53966),o=r(56507),i=r(16649),s=r(96156),a=r(47821);function c(t={}){return(e,r)=>{if(e===Function.prototype)throw new Error(`Inappropriate use of @property() on a static field: ${e.name}.${r}. Accessor does not support static properties.`);const c=Object.getOwnPropertyDescriptor(e,r),l=(0,s.z4)(e,r);c&&(c.get||c.set?(l.get=c.get||l.get,l.set=c.set||l.set):"value"in c&&("value"in t&&n.A.getLogger("esri.core.accessorSupport.decorators.property").warn(`@property() will redefine the value of "${r}" on "${e.constructor.name}" already defined in the metadata`,t),l.value=t.value=c.value)),null!=t.readOnly&&(l.readOnly=t.readOnly);const u=t.aliasOf;if(u){const t="string"==typeof u?u:u.source,e="string"==typeof u?null:!0===u.overridable;let n;l.dependsOn=[t],l.get=function(){let e=(0,i.Jt)(this,t);if("function"==typeof e){n||(n=t.split(".").slice(0,-1).join("."));const r=(0,i.Jt)(this,n);r&&(e=e.bind(r))}return e},l.readOnly||(l.set=e?function(t){this._override(r,t)}:function(e){(0,a.h)(this,t,e)})}const f=t.type,h=t.types;if(!l.cast){let e;f&&!1!==t.useTypeForAutocast?e=function(t){let e=0,r=t;if((0,o.Zu)(t))return(0,o.Nd)(t);for(;Array.isArray(r)&&1===r.length&&"string"!=typeof r[0]&&"number"!=typeof r[0];)r=r[0],e++;const n=r;if((0,o.EK)(n))return 0===e?(0,o.MB)(n):(0,o._e)((0,o.MB)(n),e);if(1===e)return(0,o.eC)(n);if(e>1)return(0,o.e6)(n,e);const i=t;return i.from?i.from:(0,o.dp)(i)}(f):h&&(e=Array.isArray(h)?(0,o.wB)((0,o.aq)(h[0])):(0,o.aq)(h)),t.cast=function(t,e){if(t||e)return t?e?(r,n)=>e(t(r,n),n):t:e}(t.cast,e)}(0,s.CX)(l,t),t.range&&(l.cast=(0,o.Qp)(l.cast,t.range))}}function l(t,e,r){const n=(0,s.z4)(t,r);n.json||(n.json={});let o=n.json;return void 0!==e&&(o.origins||(o.origins={}),o.origins[e]||(o.origins[e]={}),o=o.origins[e]),o}},15142:(t,e,r)=>{r.d(e,{A:()=>l});var n=r(4576),o=r(21818);const i=(t,e,r,n)=>{let o=e,i=e;const s=r>>>1,a=t[o-1];for(;i<=s;){i=o<<1,i<r&&n(t[i-1],t[i])<0&&++i;const e=t[i-1];if(n(e,a)<=0)break;t[o-1]=e,o=i}t[o-1]=a},s=(t,e)=>t<e?-1:t>e?1:0;function a(t,e,r,n){void 0===e&&(e=0),void 0===r&&(r=t.length),void 0===n&&(n=s);for(let o=r>>>1;o>e;o--)i(t,o,r,n);const o=e+1;for(let s=r-1;s>e;s--){const r=t[e];t[e]=t[s],t[s]=r,i(t,o,s,n)}}function*c(t,e,r,n){void 0===e&&(e=0),void 0===r&&(r=t.length),void 0===n&&(n=s);for(let o=r>>>1;o>e;o--)i(t,o,r,n),yield;const o=e+1;for(let s=r-1;s>e;s--){const r=t[e];t[e]=t[s],t[s]=r,i(t,o,s,n),yield}}class l{constructor(t){this.data=[],this._length=0,this._allocator=void 0,this._deallocator=()=>null,this._shrink=()=>{},this._hint=new n.vW,t&&(t.initialSize&&(this.data=new Array(t.initialSize)),t.allocator&&(this._allocator=t.allocator),void 0!==t.deallocator&&(this._deallocator=t.deallocator),t.shrink&&(this._shrink=()=>u(this)))}toArray(){return this.data.slice(0,this.length)}filter(t){const e=new Array;for(let r=0;r<this._length;r++){const n=this.data[r];t(n)&&e.push(n)}return e}at(t){if((t=Math.trunc(t)||0)<0&&(t+=this._length),!(t<0||t>=this._length))return this.data[t]}includes(t,e){const r=this.data.indexOf(t,e);return-1!==r&&r<this.length}get length(){return this._length}set length(t){if(t>this._length){if(this._allocator){for(;this._length<t;)this.data[this._length++]=this._allocator(this.data[this._length]);return}this._length=t}else{if(this._deallocator)for(let e=t;e<this._length;++e)this.data[e]=this._deallocator(this.data[e]);this._length=t,this._shrink()}}clear(){this.length=0}prune(){this.clear(),this.data=[]}push(t){this.data[this._length++]=t}pushArray(t,e=t.length){for(let r=0;r<e;r++)this.data[this._length++]=t[r]}pushAll(t){for(const e of t)this.data[this._length++]=e}fill(t,e){for(let r=0;r<e;r++)this.data[this._length++]=t}pushNew(){this._allocator&&(this.data[this.length]=this._allocator(this.data[this.length]));const t=this.data[this._length];return++this._length,t}unshift(t){this.data.unshift(t),this._length++,u(this)}pop(){if(0===this.length)return;const t=this.data[this.length-1];return this.length=this.length-1,this._shrink(),t}remove(t){const e=(0,n.qh)(this.data,(0,o.zI)(t),this.length,this._hint);if(-1!==e)return this.data.splice(e,1),this.length=this.length-1,t}removeUnordered(t){return this.removeUnorderedIndex((0,n.qh)(this.data,(0,o.zI)(t),this.length,this._hint))}removeUnorderedIndex(t){if(!(t>=this.length||t<0))return this.swapElements(t,this.length-1),this.pop()}removeUnorderedMany(t,e=t.length,r){this.length=(0,n.mW)(this.data,t,this.length,e,this._hint,r),this._shrink()}front(){if(0!==this.length)return this.data[0]}back(){if(0!==this.length)return this.data[this.length-1]}swapElements(t,e){if(t>=this.length||e>=this.length||t===e)return;const r=this.data[t];this.data[t]=this.data[e],this.data[e]=r}sort(t){a(this.data,0,this.length,t)}iterableSort(t){return c(this.data,0,this.length,t)}some(t,e){for(let r=0;r<this.length;++r)if(t.call(e,this.data[r],r,this.data))return!0;return!1}find(t,e){const{data:r,length:n}=this;for(let o=0;o<n;++o)if(t.call(e,r[o]))return r[o]}filterInPlace(t,e){let r=0;for(let n=0;n<this._length;++n){const o=this.data[n];t.call(e,o,n,this.data)&&(this.data[n]=this.data[r],this.data[r]=o,r++)}if(this._deallocator)for(let t=r;t<this._length;t++)this.data[t]=this._deallocator(this.data[t]);return this._length=r,this._shrink(),this}forAll(t,e){const{data:r,length:n}=this;for(let o=0;o<n;++o)t.call(e,r[o],o,r)}forEach(t,e){this.data.slice(0,this.length).forEach(t,e)}map(t,e){const r=new Array(this.length);for(let n=0;n<this.length;++n)r[n]=t.call(e,this.data[n],n,this.data);return r}reduce(t,e){let r=e;for(let e=0;e<this.length;++e)r=t(r,this.data[e],e,this.data);return r}has(t){const e=this.length,r=this.data;for(let n=0;n<e;++n)if(r[n]===t)return!0;return!1}*[Symbol.iterator](){for(let t=0;t<this.length;t++)yield this.data[t]}}function u(t){t.data.length>1.5*t.length&&(t.data.length=Math.floor(1.1*t.length))}},15903:(t,e,r)=>{function n(t){return!!t&&t.prototype?.declaredClass&&0===t.prototype.declaredClass.indexOf("esri.core.Collection")}r.d(e,{P:()=>n})},16649:(t,e,r)=>{r.d(e,{Jt:()=>a,RP:()=>s,t2:()=>c});var n=r(88620);function o(t,e){const r=t.endsWith("?")?t.slice(0,-1):t;if(null!=e.getItemAt||Array.isArray(e)){const t=parseInt(r,10);if(!isNaN(t))return Array.isArray(e)?e[t]:e.at(t)}const o=(0,n.oY)(e);return(0,n.yh)(o,r)?o.get(r):e[r]}function i(t,e,r){if(null==t)return t;const n=o(e[r],t);return!n&&r<e.length-1?void 0:r===e.length-1?n:i(n,e,r+1)}function s(t,e,r=0){return"string"!=typeof e||e.includes(".")?i(t,(0,n.AH)(e),r):o(e,t)}function a(t,e){return s(t,e)}function c(t,e){return void 0!==s(e,t)}},24326:(t,e,r)=>{r.d(e,{c:()=>o});let n=0;function o(){return++n}},26390:(t,e,r)=>{r.d(e,{d:()=>o});const n=[];function o(t){n.push(t),1===n.length&&queueMicrotask(()=>{const t=n.slice();n.length=0;for(const e of t)e()})}},36005:(t,e,r)=>{r.d(e,{w:()=>o});var n=r(10107);function o(t,e,r){let o,i;return void 0===e||Array.isArray(e)?(i=t,r=e,o=[void 0]):(i=e,o=Array.isArray(t)?t:[t]),(t,e)=>{const s=t.constructor.prototype;o.forEach(o=>{const a=(0,n.rM)(t,o,i);a.read&&"object"==typeof a.read||(a.read={}),a.read.reader=s[e],r&&(a.read.source=(a.read.source||[]).concat(r))})}}},43937:(t,e,r)=>{r.d(e,{K:()=>o});var n=r(10107);function o(t,e,r){let o,i;return void 0===e?(i=t,o=[void 0]):"string"!=typeof e?(i=t,o=[void 0],r=e):(i=e,o=Array.isArray(t)?t:[t]),(t,e)=>{const s=t.constructor.prototype;for(const a of o){const o=(0,n.rM)(t,a,i);o.write&&"object"==typeof o.write||(o.write={}),r&&(o.write.target=r),o.write.writer=s[e]}}}},47328:(t,e,r)=>{r.d(e,{i:()=>n});const n={Dirty:1,Overridden:2,Computing:4,NonNullable:8,HasDefaultValue:16,DepTrackingInitialized:32,AutoTracked:64,ExplicitlyTracking:128}},47821:(t,e,r)=>{r.d(e,{h:()=>s});var n=r(49186),o=r(44208),i=(r(53966),r(16649));function s(t,e,r){if(t&&e)if("object"==typeof e)for(const r of Object.getOwnPropertyNames(e))s(t,r,e[r]);else{if(e.includes(".")){const n=e.split("."),o=n.splice(-1,1)[0];return void s((0,i.Jt)(t,n),o,r)}const a=t.__accessor__;null!=a&&function(t,e){if((0,o.A)("esri-unknown-property-errors")&&!function(t,e){return null!=e.metadata[t]}(t,e))throw new n.A("set:unknown-property",function(t,e){return"setting unknown property '"+t+"' on instance of "+e.host.declaredClass}(t,e))}(e,a),t[e]=r}}},56454:(t,e,r)=>{r.d(e,{G:()=>n});const n=Symbol("Accessor-beforeDestroy")},56507:(t,e,r)=>{r.d(e,{EK:()=>S,GB:()=>l,GX:()=>c,MB:()=>T,Nd:()=>z,PZ:()=>v,Qp:()=>h,Uv:()=>E,Vr:()=>u,Zu:()=>C,_e:()=>k,aq:()=>M,dp:()=>A,e6:()=>N,eC:()=>j,gK:()=>P,jz:()=>$,wB:()=>m}),r(44208);var n=r(53966),o=r(91869);const i=()=>n.A.getLogger("esri.core.accessorSupport.ensureTypes");function s(t){if(null==t)return t;const e=new Date(t);return isNaN(e.getTime())?(i().error("Accessor#set",`Invalid date value: '${t}', falling back to current date`),new Date):e}function a(t){return null==t?t:!!t}function c(t){return null==t?t:t.toString()}function l(t,e=0){return null==t?t:(t=parseFloat(t),isNaN(t)?e:t)}function u(t){return null==t?t:Math.round(parseFloat(t))}function f(t){return null}function h(t,e){return r=>{let n=t(r);return null!=e.step&&(n=Math.round(n/e.step)*e.step),null!=e.min&&(n=Math.max(e.min,n)),null!=e.max&&(n=Math.min(e.max,n)),n}}function p(t){return t?.constructor&&void 0!==t.constructor.__accessorMetadata__}function d(t,e){return null!=e&&t&&!(e instanceof t)}function y(t){return t&&"isCollection"in t}function g(t){return t?.Type?"function"==typeof t.Type?t.Type:t.Type.base:null}function _(t,e){return!!p(e)&&(i().error("Accessor#set","Assigning an instance of '"+(e.declaredClass||"unknown")+"' which is not a subclass of '"+w(t)+"'"),!0)}function v(t,e){return null==e?e:y(t)?function(t,e){if(!e?.constructor||!y(e.constructor))return _(t,e)?e:new t(e);const r=g(t.prototype.itemType),n=g(e.constructor.prototype.itemType);return r?n?r===n?e:r.prototype.isPrototypeOf(n.prototype)?new t(e):(_(t,e),e):new t(e):e}(t,e):d(t,e)?_(t,e)?e:new t(e):e}function w(t){return t?.prototype?.declaredClass||"unknown"}const b=new WeakMap;function A(t,e){const r=function(t){switch(t){case Number:return t=>l(t);case $:return u;case Boolean:return a;case String:return c;case Date:return s;case E:return f;default:return(0,o.tE)(b,t,()=>v.bind(null,t))}}(t);return 1===arguments.length?r:r(e)}function m(t,e,r){return 1===arguments.length?m.bind(null,t):e?Array.isArray(e)?e.map(e=>t(e,r)):[t(e,r)]:e}function j(t,e){return 1===arguments.length?m(e=>A(t,e)):m(e=>A(t,e),e)}function O(t,e,r){return 0!==e&&Array.isArray(r)?r.map(r=>O(t,e-1,r)):t(r)}function k(t,e,r){if(2===arguments.length)return r=>k(t,e,r);if(!r)return r;r=O(t,e,r);let n=e,o=r;for(;n>0&&Array.isArray(o);)n--,o=o[0];if(void 0!==o)for(let t=0;t<n;t++)r=[r];return r}function N(t,e,r){return 2===arguments.length?k(e=>A(t,e),e):k(e=>A(t,e),e,r)}function S(t){return!!Array.isArray(t)&&!t.some(e=>{const r=typeof e;return!("string"===r||"number"===r||"function"===r&&t.length>1)})}function T(t,e){if(2===arguments.length)return T(t).call(null,e);const r=new Set,n=t.filter(t=>"function"!=typeof t),o=t.filter(t=>"function"==typeof t);for(const e of t)"string"!=typeof e&&"number"!=typeof e||r.add(e);let s=null,a=null;return(t,e)=>{if(null==t)return t;const c=typeof t,l="string"===c||"number"===c;return l&&(r.has(t)||o.some(t=>"string"===c&&t===String||"number"===c&&t===Number))||"object"===c&&o.some(e=>!d(e,t))?t:(l&&n.length?(s||(s=n.map(t=>"string"==typeof t?`'${t}'`:`${t}`).join(", ")),i().error("Accessor#set",`'${t}' is not a valid value for this property, only the following values are valid: ${s}`)):"object"==typeof t&&o.length?(a||(a=o.map(t=>w(t)).join(", ")),i().error("Accessor#set",`'${t}' is not a valid value for this property, value must be one of ${a}`)):i().error("Accessor#set",`'${t}' is not a valid value for this property`),e&&(e.valid=!1),null)}}function M(t,e){if(2===arguments.length)return M(t).call(null,e);const r={},n=[],o=[];for(const e in t.typeMap){const i=t.typeMap[e];r[e]=A(i),n.push(w(i)),o.push(e)}const s=()=>`'${n.join("', '")}'`,a=()=>`'${o.join("', '")}'`,c="string"==typeof t.key?e=>e[t.key]:t.key;return e=>{if(t.base&&!d(t.base,e))return e;if(null==e)return e;const n=c(e)||t.defaultKeyValue,o=r[n];if(!o)return i().error("Accessor#set",`Invalid property value, value needs to be one of ${s()}, or a plain object that can autocast (having .type = ${a()})`),null;if(!d(t.typeMap[n],e))return e;if("string"==typeof t.key&&!p(e)){const r={};for(const n in e)n!==t.key&&(r[n]=e[n]);return o(r)}return o(e)}}class ${}class E{}const P={native:t=>({type:"native",value:t}),array:t=>({type:"array",value:t}),oneOf:t=>({type:"one-of",values:t})};function C(t){if(!t||"object"!=typeof t&&"function"!=typeof t||!("type"in t))return!1;switch(t.type){case"native":case"array":case"one-of":return!0}return!1}function z(t){switch(t.type){case"native":return A(t.value);case"array":return m(z(t.value));case"one-of":return function(t){let e=null;return(r,n)=>D(r,t)?r:(null==e&&(e=I(t)),i().error("Accessor#set",`Invalid property value, value needs to be of type ${e}`),n&&(n.valid=!1),null)}(t);default:return null}}function I(t){switch(t.type){case"native":switch(t.value){case Number:return"number";case String:return"string";case Boolean:return"boolean";case $:return"integer";case Date:return"date";case E:return"null";default:return w(t.value)}case"array":return`array of ${I(t.value)}`;case"one-of":{const e=t.values.map(t=>I(t));return`one of ${e.slice(0,-1)} or ${e[e.length-1]}`}}return"unknown"}function D(t,e){if(null==t)return!0;switch(e.type){case"native":switch(e.value){case Number:case $:return"number"==typeof t;case Boolean:return"boolean"==typeof t;case String:return"string"==typeof t;case E:return null===t}return t instanceof e.value;case"array":return!!Array.isArray(t)&&!t.some(t=>!D(t,e.value));case"one-of":return e.values.some(e=>D(t,e))}}},62788:(t,e,r)=>{r.d(e,{F_:()=>p,Xr:()=>w,a:()=>h,fE:()=>_,gc:()=>l}),r(44208);var n=r(53966),o=r(88620),i=r(47328);const s=new(r(67867).R),a=[];let c=s;function l(t){c.onAccessed(t)}let u=!1,f=!1;function h(t,e,r){if(u)return d(t,e,r);let n=null;return y(t),n=e.call(r),g(),n}function p(t,e){return h(s,t,e)}function d(t,e,r){const o=u;u=!0,y(t);let i=null;try{i=e.call(r)}catch(t){f&&n.A.getLogger("esri.core.accessorSupport.tracking").error(t)}return g(),u=o,i}function y(t){c=t,a.push(t)}function g(){const t=a.length;if(t>1){const e=a.pop();c=a[t-2],e.onTrackingEnd()}else if(1===t){const t=a.pop();c=s,t.onTrackingEnd()}else c=s}function _(t,e){if(e.flags&i.i.DepTrackingInitialized)return;e.flags|=i.i.DepTrackingInitialized;const r=f;f=!1,e.flags&i.i.AutoTracked?d(e.trackingTarget,e.metadata.get,t):w(t,e),f=r}const v=[];function w(t,e){e.flags&i.i.ExplicitlyTracking||(e.flags|=i.i.ExplicitlyTracking,d(e.trackingTarget,()=>{const r=e.metadata.dependsOn||v;for(const e of r)if("string"!=typeof e||e.includes(".")){const r=(0,o.AH)(e);for(let e=0,n=t;e<r.length&&null!=n&&"object"==typeof n;++e)n=b(n,r[e],e!==r.length-1)}else b(t,e,!1)}),e.flags&=~i.i.ExplicitlyTracking)}function b(t,e,r){const n=e.endsWith("?")?e.slice(0,-1):e;if(null!=t.getItemAt||Array.isArray(t)){const e=parseInt(n,10);if(!isNaN(e))return Array.isArray(t)?t[e]:t.at(e)}const i=(0,o.oY)(t);if(i){const e=i.propertiesByName.get(n);e&&(l(e),_(t,e))}return r?t[n]:void 0}},64108:(t,e,r)=>{r.d(e,{$:()=>A}),r(44208);var n=r(53966),o=r(56454),i=r(85537),s=r(96156),a=r(62788),c=r(56507),l=r(90360);function u(t){if(t.json||(t.json={}),h(t.json),p(t.json),f(t.json),t.json.origins)for(const e in t.json.origins)h(t.json.origins[e]),p(t.json.origins[e]),f(t.json.origins[e]);return!0}function f(t){t.name&&(t.read&&"object"==typeof t.read?void 0===t.read.source&&(t.read.source=t.name):t.read={source:t.name},t.write&&"object"==typeof t.write?void 0===t.write.target&&(t.write.target=t.name):t.write={target:t.name})}function h(t){"boolean"==typeof t.read?t.read={enabled:t.read}:"function"==typeof t.read?t.read={enabled:!0,reader:t.read}:t.read&&"object"==typeof t.read&&void 0===t.read.enabled&&(t.read.enabled=!0)}function p(t){"boolean"==typeof t.write?t.write={enabled:t.write}:"function"==typeof t.write?t.write={enabled:!0,writer:t.write}:t.write&&"object"==typeof t.write&&void 0===t.write.enabled&&(t.write.enabled=!0)}var d=r(67124);function y(t){return t.type?g(t):_(t)}function g(t){if(!t.type)return;let e=0,r=t.type;for(;Array.isArray(r)&&!(0,c.EK)(r);)r=r[0],e++;return{type:r,ndimArray:e}}function _(t){if(!t.types)return;let e=0,r=t.types;for(;Array.isArray(r);)r=r[0],e++;return{types:r,ndimArray:e}}function v(t){u(t)&&(function(t){if(t.json&&t.json.origins){const e=t.json.origins,r={"web-document":["web-scene","web-map"]};for(const t in r)if(e[t]){const n=e[t];r[t].forEach(t=>{e[t]=n}),delete e[t]}}}(t),function(t){const e=function(t){return t.json.types?_(t.json):t.type?g(t):_(t)}(t);if(t.json.origins)for(const r in t.json.origins){const n=t.json.origins[r],o=n.types?y(n):e;(0,l.v)(o,n,!1),n.types&&!n.write&&t.json.write?.enabled&&(n.write={...t.json.write}),(0,d.v)(o,n)}(0,l.v)(e,t.json,!0),(0,d.v)(e,t.json)}(t))}const w=new Set,b=new Set;function A(t){return e=>{t??="esri.core.Accessor",e.prototype.declaredClass=t,j(e);const r=[],n=[];let a=e.prototype;for(;a;)a.hasOwnProperty("initialize")&&!w.has(a.initialize)&&(w.add(a.initialize),r.push(a.initialize)),a.hasOwnProperty("destroy")&&!b.has(a.destroy)&&(b.add(a.destroy),n.push(a.destroy)),a=Object.getPrototypeOf(a);w.clear(),b.clear();const c=class extends e{constructor(...t){if(super(...t),this.constructor===c&&"function"==typeof this.postscript){if(r.length&&Object.defineProperty(this,"initialize",{enumerable:!1,configurable:!0,value(){for(let t=r.length-1;t>=0;t--)r[t].call(this)}}),n.length){let t=!1;const e=this[o.G];Object.defineProperty(this,"destroy",{enumerable:!1,configurable:!0,value(){if(!t){this.__accessor__.lifecycle=i.v.DESTROYING,t=!0,e.call(this);for(let t=0;t<n.length;t++)n[t].call(this)}}})}Object.defineProperty(this,Symbol.dispose,{enumerable:!1,configurable:!0,value(){this.destroy()}}),this.postscript()}}};c.__accessorMetadata__=(0,s.tD)(e.prototype),c.prototype.declaredClass=t;const l=(t||"AccessorSubclass").split(".").slice(-1)[0];return Object.defineProperty(c,"name",{value:l,configurable:!0}),c}}function m(t,e){return null==e.get?function(){const e=this.__accessor__,r=e.propertiesByName.get(t);if(void 0===r)return;e.mutable&&(0,a.gc)(r);const n=e.store;return n.has(t)?n.get(t):r.metadata.value}:function(){const e=this.__accessor__,r=e.propertiesByName.get(t);if(void 0!==r)return r.getComputed(e)}}function j(t){const e=t.prototype,r=(0,s.tD)(e),n={};for(const t of Object.getOwnPropertyNames(r)){const e=r[t];v(e),n[t]={enumerable:!0,configurable:!0,get:m(t,e),set(r){const n=this.__accessor__;if(void 0!==n){if(n.mutable)return n.initialized&&e.readOnly?O("read-only",t):n.lifecycle===i.v.CONSTRUCTED&&e.constructOnly?O("construct-only",t):void n.set(t,r)}else Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:r})}}}Object.defineProperties(t.prototype,n)}const O=(t,e)=>{n.A.getLogger("esri.core.Accessor").error(`cannot assign to ${t} property '${e}'`)}},66552:(t,e,r)=>{r.d(e,{J:()=>o,O:()=>s});var n=r(93637);class o{constructor(t,e={ignoreUnknown:!1,useNumericKeys:!1}){this._jsonToAPI=t,this._options=e,this.apiValues=[],this.jsonValues=[],this._apiToJSON=function(t){const e={};for(const r in t)e[t[r]]=r;return e}(t),this.apiValues=i(this._apiToJSON),this.jsonValues=i(this._jsonToAPI),this.read=t=>this.fromJSON(t),this.write=(t,e,r)=>{const o=this.toJSON(t);void 0!==o&&(0,n.sM)(r,o,e)},this.write.isJSONMapWriter=!0}toJSON(t){if(null==t)return null;if(this._apiToJSON.hasOwnProperty(t)){const e=this._apiToJSON[t];return this._options.useNumericKeys?+e:e}return this._options.ignoreUnknown?null:t}fromJSON(t){return null!=t&&this._jsonToAPI.hasOwnProperty(t)?this._jsonToAPI[t]:this._options.ignoreUnknown?void 0:t}}function i(t){const e=[];for(const r in t)e.push(r);return e.sort(),e}function s(){return function(t,e){return new o(t,{ignoreUnknown:!0,...e})}}},67076:(t,e,r)=>{r.d(e,{A:()=>o});var n=r(79907);class o extends n.A{constructor(t,e,r){super(t,e,r)}}o.prototype.type="warning"},67124:(t,e,r)=>{r.d(e,{B:()=>f,v:()=>a});var n=r(49186),o=r(53966),i=r(93637),s=r(15903);function a(t,e){if(!e.write||e.write.writer||!1===e.write.enabled&&!e.write.overridePolicy)return;const r=t?.ndimArray??0;t&&(1===r||"type"in t&&(0,s.P)(t.type))?e.write.writer=h:r>1?e.write.writer=function(t){return(e,r,n,o)=>{let s;if(null===e)s=null;else{s=p(e,o,t);let r=t,n=s;for(;r>0&&Array.isArray(n);)r--,n=n[0];if(void 0!==n)for(let t=0;t<r;t++)s=[s]}(0,i.sM)(n,s,r)}}(r):e.types?Array.isArray(e.types)?e.write.writer=function(t){return(e,r,n,o)=>e&&Array.isArray(e)?l(e.filter(e=>c(e,t,o)),r,n,o):l(e,r,n,o)}(e.types[0]):e.write.writer=function(t){return(e,r,n,o)=>e?c(e,t,o)?l(e,r,n,o):void 0:l(e,r,n,o)}(e.types):e.write.writer=l}function c(t,e,r){for(const r in e.typeMap)if(t instanceof e.typeMap[r])return!0;if(r?.messages){const i=e.errorContext??"type",s=`Values of type '${("function"!=typeof e.key?t[e.key]:t.declaredClass)??"Unknown"}' cannot be written`;r&&r.messages&&t&&r.messages.push(new n.A(`${i}:unsupported`,s,{definition:t,context:r})),o.A.getLogger("esri.core.accessorSupport.extensions.serializableProperty.writer").error(s)}return!1}function l(t,e,r,n){(0,i.sM)(r,u(t,n),e)}function u(t,e){return t&&"function"==typeof t.write?t.write({},e):t&&"function"==typeof t.toJSON?t.toJSON():"number"==typeof t?f(t):t}function f(t){return t===-1/0?-Number.MAX_VALUE:t===1/0?Number.MAX_VALUE:isNaN(t)?null:t}function h(t,e,r,n){let o;null===t?o=null:t&&"function"==typeof t.map?(o=t.map(t=>u(t,n)),"function"==typeof o.toArray&&(o=o.toArray())):o=[u(t,n)],(0,i.sM)(r,o,e)}function p(t,e,r){return 0!==r&&Array.isArray(t)?t.map(t=>p(t,e,r-1)):u(t,e)}},67867:(t,e,r)=>{r.d(e,{R:()=>n});class n{constructor(t){this.accessed=void 0,this._handles=void 0,this._observer=t}destroy(){this.accessed?.clear(),this.clear()}onAccessed(t){null!=this._observer&&t!==this._observer&&(null==this.accessed&&(this.accessed=new Set),this.accessed.add(t))}onTrackingEnd(){null!=this._observer&&(this.clear(),null!=this.accessed&&(null==this._handles&&(this._handles=[]),this.accessed.forEach(t=>{this._handles.push(t.observe(this._observer))}),this.accessed.clear()))}clear(){if(null!=this._handles){for(let t=0;t<this._handles.length;++t)this._handles[t].remove();this._handles.length=0}}}},79901:(t,e,r)=>{r.d(e,{w:()=>c});var n=r(56507),o=r(96156);const i=Object.prototype.toString;function s(t){const e="__accessorMetadata__"in t?(0,n.dp)(t):t;return function(...t){if(t.push(e),"number"==typeof t[2])throw new Error("Using @cast has parameter decorator is not supported since 4.16");return a.apply(this,t)}}function a(t,e,r,n){(0,o.z4)(t,e).cast=n}function c(...t){if(3!==t.length||"string"!=typeof t[1])return 1===t.length&&"[object Function]"===i.call(t[0])?s(t[0]):1===t.length&&"string"==typeof t[0]?function(t){return(e,r)=>{(0,o.z4)(e,t).cast=e[r]}}(t[0]):void 0}},85537:(t,e,r)=>{r.d(e,{v:()=>n});const n={INITIALIZING:0,CONSTRUCTING:1,CONSTRUCTED:2,DESTROYING:3,DESTROYED:4}},88620:(t,e,r)=>{r.d(e,{AH:()=>l,h1:()=>a,oY:()=>i,qg:()=>f,yh:()=>s});var n=r(36563),o=r(4718);function i(t){return t.__accessor__??null}function s(t,e){return null!=t?.metadata?.[e]}function a(t,e,r){return c(t,e,r?{policy:r,path:""}:null)}function c(t,e,r){return e?Object.keys(e).reduce((t,n)=>{const i=n;if("__proto__"===i)return t;let s=null,a="merge";if(r&&(s=r.path?`${r.path}.${n}`:n,a=r.policy(s)),"replace"===a)return t[i]=e[i],t;if("replace-arrays"===a&&Array.isArray(t[i]))return t[i]=e[i],t;if(void 0===t[i])return t[i]=(0,o.o8)(e[i]),t;let l=t[i],u=e[i];if(l===u)return t;if(Array.isArray(u)||Array.isArray(t))l=l?Array.isArray(l)?t[i]=l.slice():t[i]=[l]:t[i]=[],u&&(Array.isArray(u)||(u=[u]),u.forEach(t=>{l.includes(t)||l.push(t)}));else if(u&&"object"==typeof u)if(r){const e=r.path;r.path=s,t[i]=c(l,u,r),r.path=e}else t[i]=c(l,u,null);else t.hasOwnProperty(n)&&!e.hasOwnProperty(n)||(t[i]=u);return t},t||{}):t}function l(t){return Array.isArray(t)?t:t.split(".")}function u(t){return t.includes(",")?t.split(",").map(t=>t.trim()):[t.trim()]}function f(t,e,r,o){const i=function(t){if(Array.isArray(t)){const e=[];for(const r of t)e.push(...u(r));return e}return u(t)}(e);if(1!==i.length){const e=i.map(e=>o(t,e,r));return(0,n.vE)(e)}return o(t,i[0],r)}},90360:(t,e,r)=>{r.d(e,{C:()=>f,v:()=>u});var n=r(53966),o=r(93637),i=r(67076),s=r(96156),a=r(15903),c=r(7142);const l=()=>n.A.getLogger("esri.core.accessorSupport.extensions.serializableProperty.reader");function u(t,e,r){t&&(!r&&!e.read||e.read?.reader||!1===e.read?.enabled||function(t){return"types"in t?_(t.types):g(t.type)}(t)&&(0,o.sM)("read.reader",f(t),e))}function f(t){const e=t.ndimArray??0;if(e>1)return function(t){const e=h(t),r=p.bind(null,e),n=t.ndimArray??0;return(t,e,o)=>{if(null==t)return t;t=r(t,o,n);let i=n,s=t;for(;i>0&&Array.isArray(s);)i--,s=s[0];if(void 0!==s)for(let e=0;e<i;e++)t=[t];return t}}(t);if(1===e)return d(t);if("type"in t&&y(t.type)){const e=t.type.prototype?.itemType?.Type,r=d("function"==typeof e?{type:e}:{types:e});return(e,n,o)=>{const i=r(e,n,o);return i?new t.type(i):i}}return h(t)}function h(t){return"type"in t?function(t){return t.prototype.read?(e,r,n)=>{if(null==e)return e;const o=typeof e;if("object"!==o)return void l().error(`Expected JSON value of type 'object' to deserialize type '${t.prototype.declaredClass}', but got '${o}'`);const i=new t;return i.read(e,n),i}:t.fromJSON}(t.type):function(t){let e=null;const r=t.errorContext??"type",n=t.validate;return(o,a,u)=>{if(null==o)return o;const f=typeof o;if("object"!==f)return void l().error(`Expected JSON value of type 'object' to deserialize, but got '${f}'`);e||(e=function(t){const e={};for(const r in t.typeMap){const n=t.typeMap[r],o=(0,s.tD)(n.prototype);if("function"==typeof t.key)continue;const i=o[t.key];if(!i)continue;if(i.json?.type&&Array.isArray(i.json.type)&&1===i.json.type.length&&"string"==typeof i.json.type[0]){e[i.json.type[0]]=n;continue}const a=i.json?.write;if(!a?.writer){e[r]=n;continue}const c=a.target,l="string"==typeof c?c:t.key,u={};a.writer(r,u,l),u[l]&&(e[u[l]]=n)}return e}(t));const h=t.key;if("string"!=typeof h)return;const p=o[function(t,e,r){const n=Object.values(e)[0],o=(0,s.tD)(n.prototype)[t],i=(0,c.N5)(o,r),a=i?.read?.source;return a&&"string"==typeof a?a:t}(h,e,u)],d=p?e[p]:t.defaultKeyValue?t.typeMap[t.defaultKeyValue]:void 0;if(!d){const t=`Type '${p||"unknown"}' is not supported`;return u?.messages&&o&&u.messages.push(new i.A(`${r}:unsupported`,t,{definition:o,context:u})),void l().error(t)}const y=new d;return y.read(o,u),n?n(y):y}}(t.types)}function p(t,e,r,n){return 0!==n&&Array.isArray(e)?e.map(e=>p(t,e,r,n-1)):t(e,void 0,r)}function d(t){const e=h(t);return(t,r,n)=>{if(null==t)return t;if(Array.isArray(t)){const r=[];for(const o of t){const t=e(o,void 0,n);void 0!==t&&r.push(t)}return r}const o=e(t,void 0,n);return void 0!==o?[o]:void 0}}function y(t){if(!(0,a.P)(t))return!1;const e=t.prototype.itemType;return!(!e||!e.Type)&&("function"==typeof e.Type?g(e.Type):_(e.Type))}function g(t){return!Array.isArray(t)&&!!t&&("object"==typeof t||"function"==typeof t)&&t.prototype&&("read"in t.prototype||"fromJSON"in t||y(t))}function _(t){for(const e in t.typeMap)if(!g(t.typeMap[e]))return!1;return!0}},91429:(t,e,r)=>{r.d(e,{wg:()=>c,MZ:()=>s,$K:()=>a});var n=r(10107),o=r(79901),i=r(64108);r(93223),r(36005),r(43937);const s=n.MZ,a=i.$;function c(...t){return(0,o.w)(...t)}},93223:(t,e,r)=>{r.d(e,{e:()=>i});var n=r(66552),o=r(10107);function i(t,e={}){const r=t instanceof n.J?t:new n.J(t,e),{alwaysWriteDefaults:i,default:s,ignoreUnknown:a=!0,name:c,nonNullable:l,readOnly:u=!1}=e;return(0,o.MZ)({type:a?r.apiValues:String,json:{type:r.jsonValues,default:s,name:c,read:!u&&{reader:r.read},write:{writer:r.write,alwaysWriteDefaults:i}},nonNullable:l,readOnly:u})}},93687:(t,e,r)=>{r.d(e,{A:()=>o});var n=r(44208);class o{constructor(t,e,r,n=1,o=0){this._creator=t,this._acquireFunction=e,this._releaseFunction=r,this.allocationSize=n,this._pool=new Array(o),this._initialSize=o;for(let t=0;t<o;t++)this._pool[t]=this._creator();this.allocationSize=Math.max(n,1)}destroy(){this.prune(0)}acquire(...t){let e;if(o.test.disabled)e=this._creator();else{if(0===this._pool.length){const t=this.allocationSize;for(let e=0;e<t;e++)this._pool[e]=this._creator()}e=this._pool.pop()}return this._acquireFunction?this._acquireFunction(e,...t):function(t){return t?.acquire&&"function"==typeof t.acquire}(e)&&e.acquire(...t),e}release(t){var e;t&&!o.test.disabled&&(this._releaseFunction?this._releaseFunction(t):(e=t,e?.release&&"function"==typeof e.release&&t.release()),this._pool.push(t))}prune(t=this._initialSize){if(!(t>=this._pool.length)){for(let e=t;e<this._pool.length;++e){const t=this._pool[e];this._dispose(t)}this._pool.length=t}}_dispose(t){t.dispose&&"function"==typeof t.dispose&&t.dispose()}static{this.test={disabled:!!(0,n.A)("esri-tests-disable-memory-pools")}}}},96156:(t,e,r)=>{r.d(e,{CX:()=>a,tD:()=>i,z4:()=>s});var n=r(4718),o=r(88620);function i(t){let e=t.constructor.__accessorMetadata__;const r=Object.prototype.hasOwnProperty.call(t.constructor,"__accessorMetadata__");if(e){if(!r){e=Object.create(e);for(const t in e)e[t]=(0,n.o8)(e[t]);Object.defineProperty(t.constructor,"__accessorMetadata__",{value:e,enumerable:!1,configurable:!0,writable:!0})}}else e={},Object.defineProperty(t.constructor,"__accessorMetadata__",{value:e,enumerable:!1,configurable:!0,writable:!0});return t.constructor.__accessorMetadata__}function s(t,e){const r=i(t);let n=r[e];return n||(n=r[e]={}),n}function a(t,e){return(0,o.h1)(t,e,l)}const c=/^(?:[^.]+\.)?(?:value|type|(?:json\.type|json\.origins\.[^.]\.type))$/;function l(t){return c.test(t)?"replace":"merge"}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8243],{1843:(t,e,n)=>{n.d(e,{BP:()=>c,l5:()=>f});var r=n(20498),i=n(13030),s=n(90239),a=n(4431),h=n(620),o=n(85079);class u{constructor(t,e){this.layout=t,this.buffer="number"==typeof e?new ArrayBuffer(e*t.stride):e;for(const e of t.fields.keys()){const n=t.fields.get(e);this[e]=new n.constructor(this.buffer,n.offset,this.stride)}}get stride(){return this.layout.stride}get count(){return this.buffer.byteLength/this.stride}get byteLength(){return this.buffer.byteLength}getField(t,e){const n=this[t];return n&&n.elementCount===e.ElementCount&&n.elementType===e.ElementType?n:null}slice(t,e){return new u(this.layout,this.buffer.slice(t*this.stride,e*this.stride))}copyFrom(t,e=0,n=0,r=t.count){const i=this.stride;if(i%4==0){const s=new Uint32Array(t.buffer,e*i,r*i/4);new Uint32Array(this.buffer,n*i,r*i/4).set(s)}else{const s=new Uint8Array(t.buffer,e*i,r*i);new Uint8Array(this.buffer,n*i,r*i).set(s)}return this}get usedMemory(){return this.byteLength}dispose(){}}class l{constructor(t){this._stride=0,this._fields=new Map,t&&(this._stride=t.stride,t.fields.forEach(t=>this._fields.set(t[0],{...t[1],constructor:E(t[1].constructor)})))}freeze(){return this}get locations(){return(0,o.Xk)((0,a.U)(this))}vec2f16(t,e){return this._appendField(t,r.SX?i.ZD:i.gH,e),this}vec2f(t,e){return this._appendField(t,i.gH,e),this}vec2f64(t,e){return this._appendField(t,i.si,e),this}vec3f16(t,e){return this._appendField(t,r.SX?i.EC:i.xs,e),this}vec3f(t,e){return this._appendField(t,i.xs,e),this}vec3f64(t,e){return this._appendField(t,i.Xm,e),this}vec4f16(t,e){return this._appendField(t,r.SX?i.jz:i.Eq,e),this}vec4f(t,e){return this._appendField(t,i.Eq,e),this}vec4f64(t,e){return this._appendField(t,i.Aj,e),this}mat3f(t,e){return this._appendField(t,i.jZ,e),this}mat3f64(t,e){return this._appendField(t,i.j0,e),this}mat4f(t,e){return this._appendField(t,i.Sx,e),this}mat4f64(t,e){return this._appendField(t,i.E$,e),this}vec4u8(t,e){return this._appendField(t,i.XP,e),this}f16(t,e){return this._appendField(t,r.SX?i.XW:i.Y$,e),this}f32(t,e){return this._appendField(t,i.Y$,e),this}f64(t,e){return this._appendField(t,i.qB,e),this}u8(t,e){return this._appendField(t,i.SL,e),this}u16(t,e){return this._appendField(t,i.h,e),this}i8(t,e){return this._appendField(t,i.bf,e),this}vec2i8(t,e){return this._appendField(t,i.D6,e),this}vec2i16(t,e){return this._appendField(t,i.mJ,e),this}vec2u8(t,e){return this._appendField(t,i.LC,e),this}vec2u16(t,e){return this._appendField(t,i.Yi,e),this}vec4u16(t,e){return this._appendField(t,i.Uz,e),this}vec4i16(t,e){return this._appendField(t,i.E7,e),this}u32(t,e){return this._appendField(t,i.P,e),this}_appendField(t,e,n){this._fields.has(t)&&(0,h.vA)(!1,`${t} already added to vertex buffer layout`);const r=e.ElementCount*(0,s.GJ)(e.ElementType),i=this._stride;this._fields.set(t,{constructor:e,size:r,offset:i,optional:n}),this._alignFields()}_alignFields(){let t=0,e=1;this._fields.forEach(n=>{const r=(0,s.GJ)(n.constructor.ElementType);t=Math.floor((t+r-1)/r)*r,n.offset=t,t+=n.size,e=Math.max(e,r)}),t=Math.floor((t+e-1)/e)*e,this._stride=t}createBuffer(t){return new u(this,t)}createView(t){return new u(this,t)}clone(){const t=new l;return t._stride=this._stride,t._fields=new Map,this._fields.forEach((e,n)=>t._fields.set(n,e)),t.BufferType=this.BufferType,t}get stride(){return this._stride}get fields(){return this._fields}}function c(){return new l}class f{constructor(t){this.fields=new Array,t.fields.forEach((t,e)=>{const n={...t,constructor:_(t.constructor)};this.fields.push([e,n])}),this.stride=t.stride}}const d=[i.Y$,i.gH,i.xs,i.Eq,i.jZ,i.Sx,i.qB,i.si,i.Xm,i.Aj,i.j0,i.E$,i.SL,i.LC,i.eI,i.XP,i.h,i.Yi,i.nS,i.Uz,i.P,i.An,i.H$,i.ml,i.bf,i.D6,i.m8,i.TX,i.Qt,i.mJ,i.Vp,i.E7,i.My,i.UL,i.zD,i.Y4];function _(t){return`${t.ElementType}_${t.ElementCount}`}function E(t){return p.get(t)}const p=new Map;d.forEach(t=>p.set(_(t),t))},4431:(t,e,n)=>{n.d(e,{U:()=>s}),n(44208);var r=n(63907),i=n(74038);function s(t,e=0){const n=t.stride;return Array.from(t.fields.keys()).map(s=>{const a=t.fields.get(s),h=a.constructor.ElementCount,o=function(t){switch(t){case"u8":return r.pe.UNSIGNED_BYTE;case"u16":return r.pe.UNSIGNED_SHORT;case"u32":return r.pe.UNSIGNED_INT;case"i8":return r.pe.BYTE;case"i16":return r.pe.SHORT;case"i32":return r.pe.INT;case"f16":return r.pe.HALF_FLOAT;case"f32":return r.pe.FLOAT;default:throw new Error("BufferType not supported in WebGL")}}(a.constructor.ElementType),u=a.offset,l=a.optional?.glNormalized??!1,c=a.optional?.integer??!1;return new i._(s,h,o,u,n,l,e,c)})}},11868:(t,e,n)=>{n.d(e,{Wz:()=>s,oe:()=>i});var r=n(34275);function i(t,e=!1){return t<=r.y9?e?new Array(t).fill(0):new Array(t):new Float32Array(t)}function s(t){return(Array.isArray(t)?t.length:t.byteLength/8)<=r.y9?Array.from(t):new Float32Array(t)}},15142:(t,e,n)=>{n.d(e,{A:()=>u});var r=n(4576),i=n(21818);const s=(t,e,n,r)=>{let i=e,s=e;const a=n>>>1,h=t[i-1];for(;s<=a;){s=i<<1,s<n&&r(t[s-1],t[s])<0&&++s;const e=t[s-1];if(r(e,h)<=0)break;t[i-1]=e,i=s}t[i-1]=h},a=(t,e)=>t<e?-1:t>e?1:0;function h(t,e,n,r){void 0===e&&(e=0),void 0===n&&(n=t.length),void 0===r&&(r=a);for(let i=n>>>1;i>e;i--)s(t,i,n,r);const i=e+1;for(let a=n-1;a>e;a--){const n=t[e];t[e]=t[a],t[a]=n,s(t,i,a,r)}}function*o(t,e,n,r){void 0===e&&(e=0),void 0===n&&(n=t.length),void 0===r&&(r=a);for(let i=n>>>1;i>e;i--)s(t,i,n,r),yield;const i=e+1;for(let a=n-1;a>e;a--){const n=t[e];t[e]=t[a],t[a]=n,s(t,i,a,r),yield}}class u{constructor(t){this.data=[],this._length=0,this._allocator=void 0,this._deallocator=()=>null,this._shrink=()=>{},this._hint=new r.vW,t&&(t.initialSize&&(this.data=new Array(t.initialSize)),t.allocator&&(this._allocator=t.allocator),void 0!==t.deallocator&&(this._deallocator=t.deallocator),t.shrink&&(this._shrink=()=>l(this)))}toArray(){return this.data.slice(0,this.length)}filter(t){const e=new Array;for(let n=0;n<this._length;n++){const r=this.data[n];t(r)&&e.push(r)}return e}at(t){if((t=Math.trunc(t)||0)<0&&(t+=this._length),!(t<0||t>=this._length))return this.data[t]}includes(t,e){const n=this.data.indexOf(t,e);return-1!==n&&n<this.length}get length(){return this._length}set length(t){if(t>this._length){if(this._allocator){for(;this._length<t;)this.data[this._length++]=this._allocator(this.data[this._length]);return}this._length=t}else{if(this._deallocator)for(let e=t;e<this._length;++e)this.data[e]=this._deallocator(this.data[e]);this._length=t,this._shrink()}}clear(){this.length=0}prune(){this.clear(),this.data=[]}push(t){this.data[this._length++]=t}pushArray(t,e=t.length){for(let n=0;n<e;n++)this.data[this._length++]=t[n]}pushAll(t){for(const e of t)this.data[this._length++]=e}fill(t,e){for(let n=0;n<e;n++)this.data[this._length++]=t}pushNew(){this._allocator&&(this.data[this.length]=this._allocator(this.data[this.length]));const t=this.data[this._length];return++this._length,t}unshift(t){this.data.unshift(t),this._length++,l(this)}pop(){if(0===this.length)return;const t=this.data[this.length-1];return this.length=this.length-1,this._shrink(),t}remove(t){const e=(0,r.qh)(this.data,(0,i.zI)(t),this.length,this._hint);if(-1!==e)return this.data.splice(e,1),this.length=this.length-1,t}removeUnordered(t){return this.removeUnorderedIndex((0,r.qh)(this.data,(0,i.zI)(t),this.length,this._hint))}removeUnorderedIndex(t){if(!(t>=this.length||t<0))return this.swapElements(t,this.length-1),this.pop()}removeUnorderedMany(t,e=t.length,n){this.length=(0,r.mW)(this.data,t,this.length,e,this._hint,n),this._shrink()}front(){if(0!==this.length)return this.data[0]}back(){if(0!==this.length)return this.data[this.length-1]}swapElements(t,e){if(t>=this.length||e>=this.length||t===e)return;const n=this.data[t];this.data[t]=this.data[e],this.data[e]=n}sort(t){h(this.data,0,this.length,t)}iterableSort(t){return o(this.data,0,this.length,t)}some(t,e){for(let n=0;n<this.length;++n)if(t.call(e,this.data[n],n,this.data))return!0;return!1}find(t,e){const{data:n,length:r}=this;for(let i=0;i<r;++i)if(t.call(e,n[i]))return n[i]}filterInPlace(t,e){let n=0;for(let r=0;r<this._length;++r){const i=this.data[r];t.call(e,i,r,this.data)&&(this.data[r]=this.data[n],this.data[n]=i,n++)}if(this._deallocator)for(let t=n;t<this._length;t++)this.data[t]=this._deallocator(this.data[t]);return this._length=n,this._shrink(),this}forAll(t,e){const{data:n,length:r}=this;for(let i=0;i<r;++i)t.call(e,n[i],i,n)}forEach(t,e){this.data.slice(0,this.length).forEach(t,e)}map(t,e){const n=new Array(this.length);for(let r=0;r<this.length;++r)n[r]=t.call(e,this.data[r],r,this.data);return n}reduce(t,e){let n=e;for(let e=0;e<this.length;++e)n=t(n,this.data[e],e,this.data);return n}has(t){const e=this.length,n=this.data;for(let r=0;r<e;++r)if(n[r]===t)return!0;return!1}*[Symbol.iterator](){for(let t=0;t<this.length;t++)yield this.data[t]}}function l(t){t.data.length>1.5*t.length&&(t.data.length=Math.floor(1.1*t.length))}},63907:(t,e,n)=>{n.d(e,{$0:()=>c,CQ:()=>p,Fq:()=>_,H0:()=>s,SB:()=>o,WR:()=>r,XN:()=>a,iE:()=>h,ld:()=>u,nI:()=>E,pe:()=>i,r6:()=>f,vt:()=>l,yI:()=>d});const r={POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6},i={BYTE:5120,UNSIGNED_BYTE:5121,SHORT:5122,UNSIGNED_SHORT:5123,INT:5124,UNSIGNED_INT:5125,FLOAT:5126,HALF_FLOAT:5131},s={RGBA4:32854,R16F:33325,RG16F:33327,RGB32F:34837,RGBA16F:34842,R32F:33326,RG32F:33328,RGBA32F:34836,R11F_G11F_B10F:35898,RGB8:32849,RGBA8:32856,RGB5_A1:32855,R8:33321,RG8:33323,R8I:33329,R8UI:33330,R16I:33331,R16UI:33332,R32I:33333,R32UI:33334,RG8I:33335,RG8UI:33336,RG16I:33337,RG16UI:33338,RG32I:33339,RG32UI:33340,RGB16F:34843,RGB9_E5:35901,SRGB8:35905,SRGB8_ALPHA8:35907,RGB565:36194,RGBA32UI:36208,RGB32UI:36209,RGBA16UI:36214,RGB16UI:36215,RGBA8UI:36220,RGB8UI:36221,RGBA32I:36226,RGB32I:36227,RGBA16I:36232,RGB16I:36233,RGBA8I:36238,RGB8I:36239,R8_SNORM:36756,RG8_SNORM:36757,RGB8_SNORM:36758,RGBA8_SNORM:36759,RGB10_A2:32857,RGB10_A2UI:36975},a=Object.values(s),h={DEPTH24_STENCIL8:35056,DEPTH32F_STENCIL8:36013},o={DEPTH_COMPONENT16:33189,DEPTH_COMPONENT24:33190,DEPTH_COMPONENT32F:36012},u={FLOAT:i.FLOAT,UNSIGNED_BYTE:i.UNSIGNED_BYTE,UNSIGNED_INT_24_8:34042,UNSIGNED_SHORT_4_4_4_4:32819,UNSIGNED_SHORT_5_5_5_1:32820,UNSIGNED_SHORT_5_6_5:33635,BYTE:i.BYTE,UNSIGNED_SHORT:i.UNSIGNED_SHORT,SHORT:i.SHORT,UNSIGNED_INT:i.UNSIGNED_INT,INT:i.INT,HALF_FLOAT:5131,UNSIGNED_INT_2_10_10_10_REV:33640,UNSIGNED_INT_10F_11F_11F_REV:35899,UNSIGNED_INT_5_9_9_9_REV:35902,FLOAT_32_UNSIGNED_INT_24_8_REV:36269},l={Texture:0,TileTexture:1,BufferObject:2,VertexArrayObject:3,Shader:4,Program:5,FramebufferObject:6,Renderbuffer:7,TransformFeedback:8,Sync:9,UNCOUNTED:10,LinesOfCode:10,Uniform:11,COUNT:12},c=0,f=36064,d=36065,_=36066,E=33306,p={COMPRESSED_RGB_S3TC_DXT1_EXT:33776,COMPRESSED_RGBA_S3TC_DXT1_EXT:33777,COMPRESSED_RGBA_S3TC_DXT3_EXT:33778,COMPRESSED_RGBA_S3TC_DXT5_EXT:33779,COMPRESSED_R11_EAC:37488,COMPRESSED_SIGNED_R11_EAC:37489,COMPRESSED_RG11_EAC:37490,COMPRESSED_SIGNED_RG11_EAC:37491,COMPRESSED_RGB8_ETC2:37492,COMPRESSED_SRGB8_ETC2:37493,COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2:37494,COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2:37495,COMPRESSED_RGBA8_ETC2_EAC:37496,COMPRESSED_SRGB8_ALPHA8_ETC2_EAC:37497}},71936:(t,e,n)=>{n.r(e),n.d(e,{default:()=>o});var r=n(1843);function i(t,e){return e.push(t.buffer),{buffer:t.buffer,layout:new r.l5(t.layout)}}var s=n(76216),a=n(93406),h=n(431);class o{async extract(t){const e=u(t),n=(0,h.o6)(e),r=[e.data.buffer];return{result:l(n,r),transferList:r}}async extractComponentsEdgeLocations(t){const e=u(t),n=(0,h.hx)(e.data,e.skipDeduplicate,e.indices,e.indicesLength),r=[];return{result:i((0,a.K)(n,f).regular.instancesData,r),transferList:r}}async extractEdgeLocations(t){const e=u(t),n=(0,h.hx)(e.data,e.skipDeduplicate,e.indices,e.indicesLength),r=[];return{result:i((0,a.K)(n,c).regular.instancesData,r),transferList:r}}}function u(t){return{data:s.I$.createView(t.dataBuffer),indices:"Uint32Array"===t.indicesType?new Uint32Array(t.indices):"Uint16Array"===t.indicesType?new Uint16Array(t.indices):t.indices,indicesLength:t.indicesLength,writerSettings:t.writerSettings,skipDeduplicate:t.skipDeduplicate}}function l(t,e){return e.push(t.regular.lodInfo.lengths.buffer),e.push(t.silhouette.lodInfo.lengths.buffer),{regular:{instancesData:i(t.regular.instancesData,e),lodInfo:{lengths:t.regular.lodInfo.lengths.buffer}},silhouette:{instancesData:i(t.silhouette.instancesData,e),lodInfo:{lengths:t.silhouette.lodInfo.lengths.buffer}},averageEdgeLength:t.averageEdgeLength}}const c=new class{allocate(t){return h.Jb.createBuffer(t)}trim(t,e){return t.slice(0,e)}write(t,e,n){t.position0.setVec(e,n.position0),t.position1.setVec(e,n.position1)}},f=new class{allocate(t){return h.HY.createBuffer(t)}trim(t,e){return t.slice(0,e)}write(t,e,n){t.position0.setVec(e,n.position0),t.position1.setVec(e,n.position1),t.componentIndex.set(e,n.componentIndex)}}},74038:(t,e,n)=>{n.d(e,{_:()=>r});class r{constructor(t,e,n,r,i,s=!1,a=0,h=!1){this.name=t,this.count=e,this.type=n,this.offset=r,this.stride=i,this.normalized=s,this.divisor=a,this.integer=h}}},85079:(t,e,n)=>{n.d(e,{Xk:()=>i,_u:()=>s});var r=n(21818);function i(t){let e=0;return(0,r.zI)(new Map(t.map(({name:t,count:n})=>{const r=[t,e];return 16===n?e+=4:9===n?e+=3:++e,r})))}function s(t){const e=new Map;let n=0;return t.forEach(t=>t.forEach(({name:t,count:r})=>{e.set(t,n),16===r?n+=4:9===r?n+=3:++n})),e}},87317:(t,e,n)=>{n.d(e,{a:()=>y,b:()=>c,c:()=>s,d:()=>g,e:()=>I,f:()=>i,g:()=>E,h:()=>S,i:()=>a,j:()=>p,l:()=>T,m:()=>l,n:()=>R,r:()=>f,s:()=>d,t:()=>A});var r=n(34304);function i(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}function s(t,e,n,r,i){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t}function a(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t[3]=e[3]+n[3],t}function h(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t[3]=e[3]-n[3],t}function o(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t[2]=e[2]*n[2],t[3]=e[3]*n[3],t}function u(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t[2]=e[2]/n[2],t[3]=e[3]/n[3],t}function l(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t[2]=Math.min(e[2],n[2]),t[3]=Math.min(e[3],n[3]),t}function c(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t[2]=Math.max(e[2],n[2]),t[3]=Math.max(e[3],n[3]),t}function f(t,e){return t[0]=Math.round(e[0]),t[1]=Math.round(e[1]),t[2]=Math.round(e[2]),t[3]=Math.round(e[3]),t}function d(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t}function _(t,e){const n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2],s=e[3]-t[3];return Math.sqrt(n*n+r*r+i*i+s*s)}function E(t,e){const n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2],s=e[3]-t[3];return n*n+r*r+i*i+s*s}function p(t){const e=t[0],n=t[1],r=t[2],i=t[3];return Math.sqrt(e*e+n*n+r*r+i*i)}function g(t){const e=t[0],n=t[1],r=t[2],i=t[3];return e*e+n*n+r*r+i*i}function R(t,e){const n=e[0],r=e[1],i=e[2],s=e[3];let a=n*n+r*r+i*i+s*s;return a>0&&(a=1/Math.sqrt(a),t[0]=n*a,t[1]=r*a,t[2]=i*a,t[3]=s*a),t}function S(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]}function T(t,e,n,r){const i=e[0],s=e[1],a=e[2],h=e[3];return t[0]=i+r*(n[0]-i),t[1]=s+r*(n[1]-s),t[2]=a+r*(n[2]-a),t[3]=h+r*(n[3]-h),t}function A(t,e,n){const r=e[0],i=e[1],s=e[2],a=e[3];return t[0]=n[0]*r+n[4]*i+n[8]*s+n[12]*a,t[1]=n[1]*r+n[5]*i+n[9]*s+n[13]*a,t[2]=n[2]*r+n[6]*i+n[10]*s+n[14]*a,t[3]=n[3]*r+n[7]*i+n[11]*s+n[15]*a,t}function y(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]&&t[3]===e[3]}function I(t,e){const n=t[0],i=t[1],s=t[2],a=t[3],h=e[0],o=e[1],u=e[2],l=e[3],c=(0,r.FD)();return Math.abs(n-h)<=c*Math.max(1,Math.abs(n),Math.abs(h))&&Math.abs(i-o)<=c*Math.max(1,Math.abs(i),Math.abs(o))&&Math.abs(s-u)<=c*Math.max(1,Math.abs(s),Math.abs(u))&&Math.abs(a-l)<=c*Math.max(1,Math.abs(a),Math.abs(l))}const N=h,m=o,M=u,G=_,U=E,b=p,F=g;Object.freeze(Object.defineProperty({__proto__:null,add:a,ceil:function(t,e){return t[0]=Math.ceil(e[0]),t[1]=Math.ceil(e[1]),t[2]=Math.ceil(e[2]),t[3]=Math.ceil(e[3]),t},copy:i,copyVec3:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t},dist:G,distance:_,div:M,divide:u,dot:S,equals:I,exactEquals:y,floor:function(t,e){return t[0]=Math.floor(e[0]),t[1]=Math.floor(e[1]),t[2]=Math.floor(e[2]),t[3]=Math.floor(e[3]),t},inverse:function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t[3]=1/e[3],t},len:b,length:p,lerp:T,max:c,min:l,mul:m,multiply:o,negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t[3]=-e[3],t},normalize:R,random:function(t,e=1){const n=r.Ov;let i,s,a,h,o,u;do{i=2*n()-1,s=2*n()-1,o=i*i+s*s}while(o>=1);do{a=2*n()-1,h=2*n()-1,u=a*a+h*h}while(u>=1);const l=Math.sqrt((1-o)/u);return t[0]=e*i,t[1]=e*s,t[2]=e*a*l,t[3]=e*h*l,t},round:f,scale:d,scaleAndAdd:function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t[3]=e[3]+n[3]*r,t},set:s,sqrDist:U,sqrLen:F,squaredDistance:E,squaredLength:g,str:function(t){return"vec4("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+")"},sub:N,subtract:h,transformMat4:A,transformQuat:function(t,e,n){const r=e[0],i=e[1],s=e[2],a=n[0],h=n[1],o=n[2],u=n[3],l=u*r+h*s-o*i,c=u*i+o*r-a*s,f=u*s+a*i-h*r,d=-a*r-h*i-o*s;return t[0]=l*u+d*-a+c*-o-f*-h,t[1]=c*u+d*-h+f*-a-l*-o,t[2]=f*u+d*-o+l*-h-c*-a,t[3]=e[3],t}},Symbol.toStringTag,{value:"Module"}))},90239:(t,e,n)=>{function r(t){switch(t){case"u8":case"i8":return 1;case"u16":case"i16":case"f16":return 2;case"u32":case"i32":case"f32":return 4;case"f64":return 8}}n.d(e,{GJ:()=>r})},91829:(t,e,n)=>{function r(){return[0,0,0,0]}function i(t){return[t[0],t[1],t[2],t[3]]}function s(t,e,n,r){return[t,e,n,r]}function a(t,e,n,r){return[t,e,n,r]}function h(t,e=[0,0,0,0]){const n=Math.min(4,t.length);for(let r=0;r<n;++r)e[r]=t[r];return e}function o(){return s(1,1,1,1)}function u(){return s(1,0,0,0)}function l(){return s(0,1,0,0)}function c(){return s(0,0,1,0)}function f(){return s(0,0,0,1)}n.d(e,{CN:()=>a,Un:()=>_,ci:()=>h,fA:()=>s,o8:()=>i,uY:()=>d,vt:()=>r});const d=[0,0,0,0],_=o(),E=u(),p=l(),g=c(),R=f();Object.freeze(Object.defineProperty({__proto__:null,ONES:_,UNIT_W:R,UNIT_X:E,UNIT_Y:p,UNIT_Z:g,ZEROS:d,clone:i,create:r,freeze:a,fromArray:h,fromValues:s,ones:o,unitW:f,unitX:u,unitY:l,unitZ:c,zeros:function(){return[0,0,0,0]}},Symbol.toStringTag,{value:"Module"}))},97146:(t,e,n)=>{n.d(e,{Dg:()=>s,my:()=>a,tM:()=>l,uW:()=>i});var r=n(34275);function i(t){return s(t,!0)}function s(t,e){if(Array.isArray(t)){if(t.length<r.y9)return t}else if(t.length<r.y9)return Array.from(t);let n=!0,i=!0;return t.some((t,e)=>(n=n&&0===t,i=i&&t===e,!n&&!i)),n?function(t){if(1===t)return o;if(t<r.y9)return new Array(t).fill(0);if(t>f.length){const e=Math.max(2*f.length,t);f=new Uint8Array(e)}return new Uint8Array(f.buffer,0,t)}(t.length):i?l(t.length):(0,r.iu)(t)&&t.BYTES_PER_ELEMENT===Uint16Array.BYTES_PER_ELEMENT?t:function(t,e){for(const n of t){if(n>=65536)return(0,r.iu)(t)?t:new Uint32Array(t);n>=256&&(e=!1)}return e?new Uint8Array(t):new Uint16Array(t)}(t,!e)}function a(t){return t<=r.y9?new Array(t):t<=65536?new Uint16Array(t):new Uint32Array(t)}let h=c(131072);const o=[0],u=(()=>{const t=new Uint16Array(65536);for(let e=0;e<t.length;++e)t[e]=e;return t})();function l(t){return 1===t?o:t<r.y9?Array.from(new Uint16Array(u.buffer,0,t)):t<u.length?new Uint16Array(u.buffer,0,t):(t>h.length&&(h=c(Math.max(2*h.length,t))),new Uint32Array(h.buffer,0,t))}function c(t){const e=new Uint32Array(t);for(let t=0;t<e.length;t++)e[t]=t;return e}let f=new Uint8Array(65536)}}]);