@arcgis/core 5.2.0-next.85 → 5.2.0-next.87

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 (127) hide show
  1. package/assets/esri/core/workers/RemoteClient.js +1 -1
  2. package/assets/esri/core/workers/chunks/0993e51d3a9701ed2198.js +1 -0
  3. package/assets/esri/core/workers/chunks/114ba901fd319ce87dc6.js +1 -0
  4. package/assets/esri/core/workers/chunks/{3aeb934ebdab1d8c4608.js → 12a3b55195ce3244259d.js} +1 -1
  5. package/assets/esri/core/workers/chunks/{7c3d46201b11a45f79d0.js → 39c0a3eb6a870953d530.js} +74 -107
  6. package/assets/esri/core/workers/chunks/3b009c05eaec5a7048a8.js +1 -0
  7. package/assets/esri/core/workers/chunks/3b376318df4ff8519370.js +1 -0
  8. package/assets/esri/core/workers/chunks/{a0da026a06de379b8f39.js → 3de20165796fa4f76728.js} +1 -1
  9. package/assets/esri/core/workers/chunks/414093fa4957d17bf551.js +1 -0
  10. package/assets/esri/core/workers/chunks/{4ec306e5c11808b96e07.js → 48b31b8534e7bfe42976.js} +1 -1
  11. package/assets/esri/core/workers/chunks/48f6af09436723f2d861.js +1 -0
  12. package/assets/esri/core/workers/chunks/5536cee0dfc183584a9b.js +1 -0
  13. package/assets/esri/core/workers/chunks/6561c01c67db1f4c546e.js +1 -0
  14. package/assets/esri/core/workers/chunks/68705692335d57522030.js +1 -0
  15. package/assets/esri/core/workers/chunks/{ed5e9718c4dcad1156f7.js → 6f2a9259240769c7cd6e.js} +1 -1
  16. package/assets/esri/core/workers/chunks/7b2174b19d06c16715f0.js +1 -0
  17. package/assets/esri/core/workers/chunks/{b015b8c7a073dbc4a3ad.js → 820c530b8765ecb1f36e.js} +1 -1
  18. package/assets/esri/core/workers/chunks/830daaca32352da6eebe.js +1 -0
  19. package/assets/esri/core/workers/chunks/8c2921081ca3e7fd0385.js +1 -0
  20. package/assets/esri/core/workers/chunks/91496f5a9fd8ae197d3f.js +1 -0
  21. package/assets/esri/core/workers/chunks/9407db0584c730591161.js +1 -0
  22. package/assets/esri/core/workers/chunks/9658b46a7111cda53b0d.js +1 -0
  23. package/assets/esri/core/workers/chunks/974bcaf2a059b8cfb153.js +1 -0
  24. package/assets/esri/core/workers/chunks/9c7fc1c97125ea2a7b7e.js +1 -0
  25. package/assets/esri/core/workers/chunks/9ee6e8a6b9bfda758c21.js +1 -0
  26. package/assets/esri/core/workers/chunks/b3c518ca8679fbe16ece.js +1 -0
  27. package/assets/esri/core/workers/chunks/b61b7005edd9ced925e9.js +1 -0
  28. package/assets/esri/core/workers/chunks/bfdb332c155a39028c9d.js +1 -0
  29. package/assets/esri/core/workers/chunks/c1a7c475ce0c59ffa75a.js +1 -0
  30. package/assets/esri/core/workers/chunks/{3da39efc5f68f15c105f.js → c2b2942456f1b10d0e96.js} +1 -1
  31. package/assets/esri/core/workers/chunks/c5dc2743c7116d0bc0d8.js +1 -0
  32. package/assets/esri/core/workers/chunks/c68cc3b9c170b8de22dc.js +1 -0
  33. package/assets/esri/core/workers/chunks/d56603e1d0031f3c5f3b.js +1 -0
  34. package/assets/esri/core/workers/chunks/e474106292834633e7d4.js +1 -0
  35. package/assets/esri/core/workers/chunks/{d09491b340af3b779505.js → f988d5a6dcc15fe34797.js} +1 -1
  36. package/assets/esri/core/workers/chunks/fbd02e8277fe2252ecd2.js +1 -0
  37. package/assets/esri/rest/knowledgeGraph/wasmInterface/arcgis-knowledge-client-core-simd.wasm +0 -0
  38. package/assets/esri/rest/knowledgeGraph/wasmInterface/arcgis-knowledge-client-core.wasm +0 -0
  39. package/assets/esri/themes/base/widgets/_BuildingDisciplinesTree.scss +1 -1
  40. package/assets/esri/themes/base/widgets/_Daylight.scss +2 -2
  41. package/assets/esri/themes/base/widgets/_Editor.scss +1 -1
  42. package/assets/esri/themes/base/widgets/_Sketch.scss +1 -1
  43. package/assets/esri/themes/base/widgets/_SketchTooltipControls.scss +1 -1
  44. package/assets/esri/themes/base/widgets/_Slider.scss +1 -1
  45. package/assets/esri/themes/base/widgets/_SnappingControls.scss +1 -1
  46. package/assets/esri/themes/base/widgets/_TimezonePicker.scss +1 -1
  47. package/chunks/EmissionComposite.glsl.js +2 -2
  48. package/chunks/GlobalIllumination.glsl.js +69 -102
  49. package/chunks/RibbonLine.glsl.js +202 -141
  50. package/chunks/arcgis-knowledge-client-core-simd.js +1 -1
  51. package/chunks/arcgis-knowledge-client-core.js +1 -1
  52. package/config.js +1 -1
  53. package/core/libs/gl-matrix-2/math/vec3.js +1 -1
  54. package/geometry/operators/projectOperator.d.ts +1 -1
  55. package/geometry/operators/shapePreservingProjectOperator.d.ts +15 -1
  56. package/geometry/operators/support/GeographicTransformation.d.ts +4 -3
  57. package/geometry/operators/support/GeographicTransformationStep.d.ts +2 -1
  58. package/geometry/operators/support/geographicTransformationUtils.d.ts +22 -15
  59. package/geometry/operators/types.d.ts +2 -1
  60. package/geometry/support/convexPolyhedron.js +2 -0
  61. package/geometry/support/frustum.js +1 -1
  62. package/kernel.js +1 -1
  63. package/layers/LinkChartLayer.js +1 -1
  64. package/layers/support/mediaUtils.js +1 -1
  65. package/package.json +3 -3
  66. package/popup/FeatureContentCollection.js +1 -1
  67. package/support/actions/ActionBase.d.ts +1 -1
  68. package/support/revision.js +1 -1
  69. package/views/2d/engine/webgl/shaderGraph/techniques/labels/LabelMeshWriter.js +1 -1
  70. package/views/3d/layers/graphics/Graphics3DExtrudeSymbolLayer.js +1 -1
  71. package/views/3d/layers/graphics/Graphics3DLineCalloutSymbolLayer.js +1 -1
  72. package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
  73. package/views/3d/layers/graphics/polygonUtils.js +1 -1
  74. package/views/3d/layers/support/FeatureTileVisibility3D.js +1 -1
  75. package/views/3d/layers/support/HeatmapFeatureProcessor.js +1 -1
  76. package/views/3d/state/utils/navigationUtils.js +1 -1
  77. package/views/3d/state/utils/ropePullUtils.js +2 -0
  78. package/views/3d/support/ElevationAgnosticVisibility.js +2 -0
  79. package/views/3d/support/engineContent/line.js +1 -1
  80. package/views/3d/support/sphericalTileUtils.js +2 -0
  81. package/views/3d/webgl-engine/core/shaderLibrary/util/GaussianSplatCovariance.glsl.js +9 -3
  82. package/views/3d/webgl-engine/core/shaderLibrary/util/GaussianSplatEvaluation.glsl.js +5 -8
  83. package/views/3d/webgl-engine/lib/Geometry.js +1 -1
  84. package/views/3d/webgl-engine/lib/GeometryUtil.js +1 -1
  85. package/views/3d/webgl-engine/lib/GridLocalOriginFactory.js +1 -1
  86. package/views/3d/webgl-engine/lib/Material.js +1 -1
  87. package/views/3d/webgl-engine/lib/PathGeometry.js +1 -1
  88. package/views/3d/webgl-engine/lib/RayIntersections.js +1 -1
  89. package/views/3d/webgl-engine/lib/RenderGeometry.js +1 -1
  90. package/views/3d/webgl-engine/lib/screenPolygonTriangleIntersections.js +1 -1
  91. package/views/3d/webgl-engine/materials/HUDMaterial.js +1 -1
  92. package/views/3d/webgl-engine/materials/HeatmapDensityMaterial.js +1 -1
  93. package/views/3d/webgl-engine/materials/LineCalloutMaterial.js +1 -1
  94. package/views/3d/webgl-engine/materials/LineMarkerMaterial.js +1 -1
  95. package/views/3d/webgl-engine/materials/MeasurementArrowMaterial.js +1 -1
  96. package/views/3d/webgl-engine/materials/NativeLineMaterial.js +1 -1
  97. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  98. package/views/3d/webgl-engine/shaders/GaussianSplatPass.glsl.js +39 -51
  99. package/views/3d/webgl-engine/shaders/RibbonLine.glsl.js +1 -1
  100. package/views/popupAdapter.js +1 -1
  101. package/assets/esri/core/workers/chunks/05acc17cb66fa6c08845.js +0 -1
  102. package/assets/esri/core/workers/chunks/11224af8b037ccbf252c.js +0 -1
  103. package/assets/esri/core/workers/chunks/17a10916114754f1f216.js +0 -1
  104. package/assets/esri/core/workers/chunks/1b4e050a3884fc6fa6cf.js +0 -1
  105. package/assets/esri/core/workers/chunks/2f652b330a9978a68e83.js +0 -1
  106. package/assets/esri/core/workers/chunks/33d6ca59eeb88e739c81.js +0 -1
  107. package/assets/esri/core/workers/chunks/3cecf627827f5d9213a9.js +0 -1
  108. package/assets/esri/core/workers/chunks/40ec85b7813a396ee490.js +0 -1
  109. package/assets/esri/core/workers/chunks/4e94793aab42ebd251ca.js +0 -1
  110. package/assets/esri/core/workers/chunks/5903dceb172897e5675b.js +0 -1
  111. package/assets/esri/core/workers/chunks/5e5a05abcb41915802f6.js +0 -1
  112. package/assets/esri/core/workers/chunks/62f37d1075390a177ae9.js +0 -1
  113. package/assets/esri/core/workers/chunks/73cb944b87ffce33bb49.js +0 -1
  114. package/assets/esri/core/workers/chunks/86de2d1f13915ab7a51d.js +0 -1
  115. package/assets/esri/core/workers/chunks/9b5e890fb0ab29f3a3f1.js +0 -1
  116. package/assets/esri/core/workers/chunks/a183b77854f5b42c1a86.js +0 -1
  117. package/assets/esri/core/workers/chunks/ad29b77843a7d93d9f8a.js +0 -1
  118. package/assets/esri/core/workers/chunks/b812f817c465c64e8c63.js +0 -1
  119. package/assets/esri/core/workers/chunks/b94b36581842749863f0.js +0 -1
  120. package/assets/esri/core/workers/chunks/bc6e488f5fbd50f9f3d0.js +0 -1
  121. package/assets/esri/core/workers/chunks/c229325f41f10fe7f732.js +0 -1
  122. package/assets/esri/core/workers/chunks/ca6652c6304ad0e37e8f.js +0 -1
  123. package/assets/esri/core/workers/chunks/d4d2a0d882fef463e7bc.js +0 -1
  124. package/assets/esri/core/workers/chunks/da45d9576b8d66131623.js +0 -1
  125. package/assets/esri/core/workers/chunks/e76662562e03eef52ba4.js +0 -1
  126. package/assets/esri/core/workers/chunks/f1d0208c6b09c1c4b248.js +0 -1
  127. package/assets/esri/core/workers/chunks/f3680b71d496839de72c.js +0 -1
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3705],{9093(t,e,n){function r(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function o(t){return[t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8],t[9],t[10],t[11],t[12],t[13],t[14],t[15]]}n.d(e,{o8:()=>o,vt:()=>r});const i=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:i,clone:o,create:r,fromValues:function(t,e,n,r,o,i,c,a,u,s,f,l,d,h,g,w){return[t,e,n,r,o,i,c,a,u,s,f,l,d,h,g,w]}},Symbol.toStringTag,{value:"Module"})),n.d(e,["zK",0,i])},35522(t,e,n){n.d(e,{$A:()=>I,Bw:()=>i,C:()=>c,Cc:()=>T,DI:()=>U,Io:()=>p,Ln:()=>b,Om:()=>v,Qr:()=>l,Re:()=>s,S8:()=>C,T9:()=>w,WQ:()=>u,Z0:()=>x,_S:()=>h,aI:()=>D,ei:()=>B,fw:()=>E,gL:()=>z,hG:()=>M,hZ:()=>a,hs:()=>y,jk:()=>g,lw:()=>f,m3:()=>m,oW:()=>S,t2:()=>L,tn:()=>d,ze:()=>A});var r=n(51850),o=n(34304);function i(t){const e=t[0],n=t[1],r=t[2];return Math.sqrt(e*e+n*n+r*r)}function c(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function a(t,e,n,r){return t[0]=e,t[1]=n,t[2]=r,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}function s(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t}function f(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t[2]=e[2]*n[2],t}function l(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t[2]=e[2]/n[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 g(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}function w(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}function y(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t}function b(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}function p(t,e){const n=e[0]-t[0],r=e[1]-t[1],o=e[2]-t[2];return Math.sqrt(n*n+r*r+o*o)}function M(t,e){const n=e[0]-t[0],r=e[1]-t[1],o=e[2]-t[2];return n*n+r*r+o*o}function m(t){const e=t[0],n=t[1],r=t[2];return e*e+n*n+r*r}function A(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t}function U(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t}function C(t,e){const n=e[0],r=e[1],o=e[2];let i=n*n+r*r+o*o;return i>0&&(i=1/Math.sqrt(i),t[0]=e[0]*i,t[1]=e[1]*i,t[2]=e[2]*i),t}function v(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function I(t,e,n){const r=e[0],o=e[1],i=e[2],c=n[0],a=n[1],u=n[2];return t[0]=o*u-i*a,t[1]=i*c-r*u,t[2]=r*a-o*c,t}function T(t,e,n,r){const o=e[0],i=e[1],c=e[2];return t[0]=o+r*(n[0]-o),t[1]=i+r*(n[1]-i),t[2]=c+r*(n[2]-c),t}function x(t,e,n){const r=e[0],o=e[1],i=e[2];return t[0]=n[0]*r+n[4]*o+n[8]*i+n[12],t[1]=n[1]*r+n[5]*o+n[9]*i+n[13],t[2]=n[2]*r+n[6]*o+n[10]*i+n[14],t}function B(t,e,n){const r=e[0],o=e[1],i=e[2];return t[0]=r*n[0]+o*n[3]+i*n[6],t[1]=r*n[1]+o*n[4]+i*n[7],t[2]=r*n[2]+o*n[5]+i*n[8],t}function z(t,e,n){return E(t,e,n[0],n[1],n[2],n[3])}function E(t,e,n,r,o,i){const c=e[0],a=e[1],u=e[2],s=r*u-o*a,f=o*c-n*u,l=n*a-r*c,d=r*l-o*f,h=o*s-n*l,g=n*f-r*s,w=2*i;return t[0]=c+s*w+2*d,t[1]=a+f*w+2*h,t[2]=u+l*w+2*g,t}const F=(0,r.vt)(),O=(0,r.vt)();function L(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]}function D(t,e){if(t===e)return!0;const n=t[0],r=t[1],i=t[2],c=e[0],a=e[1],u=e[2],s=(0,o.FD)();return Math.abs(n-c)<=s*Math.max(1,Math.abs(n),Math.abs(c))&&Math.abs(r-a)<=s*Math.max(1,Math.abs(r),Math.abs(a))&&Math.abs(i-u)<=s*Math.max(1,Math.abs(i),Math.abs(u))}function S(t,e,n){const r=n[0]-e[0],o=n[1]-e[1],i=n[2]-e[2];let c=r*r+o*o+i*i;return c>0?(c=1/Math.sqrt(c),t[0]=r*c,t[1]=o*c,t[2]=i*c,t):(t[0]=0,t[1]=0,t[2]=0,t)}const P=s,k=f,_=l,V=p,j=M,q=i,Y=m;Object.freeze(Object.defineProperty({__proto__:null,abs:d,add:u,angle:function(t,e){C(F,t),C(O,e);const n=v(F,O);return n>1?0:n<-1?Math.PI:Math.acos(n)},bezier:function(t,e,n,r,o,i){const c=1-i,a=c*c,u=i*i,s=a*c,f=3*i*a,l=3*u*c,d=u*i;return t[0]=e[0]*s+n[0]*f+r[0]*l+o[0]*d,t[1]=e[1]*s+n[1]*f+r[1]*l+o[1]*d,t[2]=e[2]*s+n[2]*f+r[2]*l+o[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,n=1){return t[0]=Math.min(Math.max(t[0],e),n),t[1]=Math.min(Math.max(t[1],e),n),t[2]=Math.min(Math.max(t[2],e),n),t},copy:c,cross:I,crossAndNormalize:function(t,e,n){const r=e[0],o=e[1],i=e[2],c=n[0],a=n[1],u=n[2],s=o*u-i*a,f=i*c-r*u,l=r*a-o*c,d=Math.sqrt(s*s+f*f+l*l);return t[0]=s/d,t[1]=f/d,t[2]=l/d,t},direction:S,dist:V,distance:p,div:_,divide:l,dot:v,equals:D,exactEquals:L,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,n,r,o,i){const c=i*i,a=c*(2*i-3)+1,u=c*(i-2)+i,s=c*(i-1),f=c*(3-2*i);return t[0]=e[0]*a+n[0]*u+r[0]*s+o[0]*f,t[1]=e[1]*a+n[1]*u+r[1]*s+o[1]*f,t[2]=e[2]*a+n[2]*u+r[2]*s+o[2]*f,t},inverse:U,len:q,length:i,lerp:T,max:w,min:g,mul:k,multiply:f,negate:A,normalize:C,random:function(t,e=1){const n=o.Ov,r=2*n()*Math.PI,i=2*n()-1,c=Math.sqrt(1-i*i)*e;return t[0]=Math.cos(r)*c,t[1]=Math.sin(r)*c,t[2]=i*e,t},rotateX:function(t,e,n,r){const o=[],i=[];return o[0]=e[0]-n[0],o[1]=e[1]-n[1],o[2]=e[2]-n[2],i[0]=o[0],i[1]=o[1]*Math.cos(r)-o[2]*Math.sin(r),i[2]=o[1]*Math.sin(r)+o[2]*Math.cos(r),t[0]=i[0]+n[0],t[1]=i[1]+n[1],t[2]=i[2]+n[2],t},rotateY:function(t,e,n,r){const o=[],i=[];return o[0]=e[0]-n[0],o[1]=e[1]-n[1],o[2]=e[2]-n[2],i[0]=o[2]*Math.sin(r)+o[0]*Math.cos(r),i[1]=o[1],i[2]=o[2]*Math.cos(r)-o[0]*Math.sin(r),t[0]=i[0]+n[0],t[1]=i[1]+n[1],t[2]=i[2]+n[2],t},rotateZ:function(t,e,n,r){const o=[],i=[];return o[0]=e[0]-n[0],o[1]=e[1]-n[1],o[2]=e[2]-n[2],i[0]=o[0]*Math.cos(r)-o[1]*Math.sin(r),i[1]=o[0]*Math.sin(r)+o[1]*Math.cos(r),i[2]=o[2],t[0]=i[0]+n[0],t[1]=i[1]+n[1],t[2]=i[2]+n[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:y,scaleAndAdd:b,scaleTo:function(t,e){return y(t,t,e/q(t))},set:a,sign:h,sqrDist:j,sqrLen:Y,squaredDistance:M,squaredLength:m,str:function(t){return"vec3("+t[0]+", "+t[1]+", "+t[2]+")"},sub:P,subtract:s,transformMat3:B,transformMat4:x,transformMat4Z:function(t,e){return e[2]*t[0]+e[6]*t[1]+e[10]*t[2]+e[14]},transformQuat:z,transformQuatValues:E},Symbol.toStringTag,{value:"Module"})),n.d(e,["Il",0,q,"jb",0,P,"lo",0,j,"uE",0,Y,"xg",0,V])},59418(t,e,n){n.d(e,{wH:()=>w,MA:()=>d,E5:()=>h,m0:()=>b});var r=n(49186),o=n(4718),i=n(53966),c=n(34275),a=n(37203);const u=()=>i.A.getLogger("esri.views.3d.layers.i3s.I3SBinaryReader");function s(t,e,n){let o="",i=0;for(;i<n;){const c=t[e+i];if(c<128)o+=String.fromCharCode(c),i++;else if(c>=192&&c<224){if(i+1>=n)throw new r.A("utf8-decode-error","UTF-8 Decode failed. Two byte character was truncated.");const a=(31&c)<<6|63&t[e+i+1];o+=String.fromCharCode(a),i+=2}else if(c>=224&&c<240){if(i+2>=n)throw new r.A("utf8-decode-error","UTF-8 Decode failed. Multi byte character was truncated.");const a=(15&c)<<12|(63&t[e+i+1])<<6|63&t[e+i+2];o+=String.fromCharCode(a),i+=3}else{if(!(c>=240&&c<248))throw new r.A("utf8-decode-error","UTF-8 Decode failed. Invalid multi byte sequence.");{if(i+3>=n)throw new r.A("utf8-decode-error","UTF-8 Decode failed. Multi byte character was truncated.");const a=(7&c)<<18|(63&t[e+i+1])<<12|(63&t[e+i+2])<<6|63&t[e+i+3];if(a>=65536){const t=55296+(a-65536>>10),e=56320+(1023&a);o+=String.fromCharCode(t,e)}else o+=String.fromCharCode(a);i+=4}}}return o}function f(t,e){const n={byteOffset:0,byteCount:0,fields:Object.create(null)};let r=0;for(let o=0;o<e.length;o++){const i=e[o],c=i.valueType||i.type,a=M[c];n.fields[i.property]=a(t,r),r+=p[c].BYTES_PER_ELEMENT}return n.byteCount=r,n}function l(t,e,n){const o=[];let i,c,a=0;for(c=0;c<t;c+=1){if(i=e[c],i>0){if(o.push(s(n,a,i-1)),0!==n[a+i-1])throw new r.A("string-array-error","Invalid string array: missing null termination.")}else o.push(null);a+=i}return o}function d(t,e){return new(0,p[e.valueType])(t,e.byteOffset,e.count*e.valuesPerElement)}function h(t,e){if(!t)return null;const n=t[e];return(0,c.IY)(t)?-32768===n?null:n:(0,c._G)(t)?n===c.h2?null:n:n!=n?null:n}function g(t,e,n){if(e!==t&&u().error(`Invalid ${n} buffer size\n expected: ${t}, actual: ${e})`),e<t)throw new r.A("buffer-too-small","Binary buffer is too small",{expectedSize:t,actualSize:e})}function w(t,e){const n=f(t,e&&e.header);let r=n.byteCount;const o={isDraco:!1,header:n,byteOffset:n.byteCount,byteCount:0,vertexAttributes:{}},i=n.fields,c=null!=i.vertexCount?i.vertexCount:i.count;for(const t of e.ordering){if(!e.vertexAttributes[t])continue;const n={...e.vertexAttributes[t],byteOffset:r,count:c},i=y[t]||"_"+t;o.vertexAttributes[i]=n,r+=A(n.valueType)*n.valuesPerElement*c}const a=i.faceCount;if(e.faces&&a){o.faces={};for(const t of e.ordering){if(!e.faces[t])continue;const n={...e.faces[t],byteOffset:r,count:a};o.faces[t]=n,r+=A(n.valueType)*n.valuesPerElement*a}}const u=i.featureCount;if(e.featureAttributes&&e.featureAttributeOrder&&u){o.featureAttributes={};for(const t of e.featureAttributeOrder){if(!e.featureAttributes[t])continue;const n={...e.featureAttributes[t],byteOffset:r,count:u};o.featureAttributes[t]=n,r+=("UInt64"===n.valueType?8:A(n.valueType))*n.valuesPerElement*u}}return g(r,t.byteLength,"geometry"),o.byteCount=r-o.byteOffset,o}const y={position:"position",normal:"normal",color:"color",uv0:"uv0",region:"uvRegion"};function b(t,e,n,i=!1){if("lepcc-rgb"===t.encoding)return i?(0,a.mb)(e):function(t){return Array.isArray(t)?t.length<1024?t:new Uint8Array(t):t.length<1024?Array.from(t):t}((0,a.mb)(e));if("lepcc-intensity"===t.encoding)return i?(0,a.Ax)(e):function(t){return Array.isArray(t)?t.length<1024?t:new Uint16Array(t):t.length<1024?Array.from(t):t}((0,a.Ax)(e));if(null!=t.encoding&&""!==t.encoding)throw new r.A("unknown-attribute-storage-info-encoding","Unknown Attribute Storage Info Encoding");t["attributeByteCounts "]&&!t.attributeByteCounts&&(u().warn("Warning: Trailing space in 'attributeByteCounts '."),t.attributeByteCounts=t["attributeByteCounts "]),"ObjectIds"===t.ordering[0]&&t.hasOwnProperty("objectIds")&&(u().warn("Warning: Case error in objectIds"),t.ordering[0]="objectIds");const c=function(t,e,n){const i=null!=e.header?f(t,e.header):{byteOffset:0,byteCount:0,fields:{count:n}},c={header:i,byteOffset:i.byteCount,byteCount:0,entries:Object.create(null)};let a=i.byteCount;for(let t=0;t<e.ordering.length;t++){const n=e.ordering[t],u=(0,o.o8)(e[n]);if(u.count=i.fields.count??0,"String"===u.valueType){if(u.byteOffset=a,u.byteCount=i.fields[n+"ByteCount"],"UTF-8"!==u.encoding)throw new r.A("unsupported-encoding","Unsupported String encoding.",{encoding:u.encoding});if(u.timeEncoding&&"ECMA_ISO8601"!==u.timeEncoding)throw new r.A("unsupported-time-encoding","Unsupported time encoding.",{timeEncoding:u.timeEncoding})}else{if(!m(u.valueType))throw new r.A("unsupported-value-type","Unsupported binary valueType",{valueType:u.valueType});{const t=A(u.valueType);a+=a%t!==0?t-a%t:0,u.byteOffset=a,u.byteCount=t*u.valuesPerElement*u.count}}a+=u.byteCount??0,c.entries[n]=u}return c.byteCount=a-c.byteOffset,c}(e,t,n);g(c.byteOffset+c.byteCount,e.byteLength,"attribute");const s=c.entries.attributeValues||c.entries.objectIds;if(s){if("String"===s.valueType){const t=c.entries.attributeByteCounts,n=d(e,t),r=function(t,e){return new Uint8Array(t,e.byteOffset,e.byteCount)}(e,s);return s.timeEncoding?function(t,e,n){return l(t,e,n).map(t=>{const e=t?Date.parse(t):null;return null==e||Number.isNaN(e)?null:e})}(t.count,n,r):l(t.count,n,r)}return i?d(e,s):function(t,e){const n=d(t,e);if(n.length>=1024)return n;const r=new Array;return n.forEach((t,e)=>r.push(h(n,e))),r}(e,s)}throw new r.A("bad-attribute-storage-info","Bad attributeStorageInfo specification.")}const p={Float32:Float32Array,Float64:Float64Array,UInt8:Uint8Array,Int8:Int8Array,UInt16:Uint16Array,Int16:Int16Array,UInt32:Uint32Array,Int32:Int32Array},M={Float32:(t,e)=>new DataView(t,0).getFloat32(e,!0),Float64:(t,e)=>new DataView(t,0).getFloat64(e,!0),UInt8:(t,e)=>new DataView(t,0).getUint8(e),Int8:(t,e)=>new DataView(t,0).getInt8(e),UInt16:(t,e)=>new DataView(t,0).getUint16(e,!0),Int16:(t,e)=>new DataView(t,0).getInt16(e,!0),UInt32:(t,e)=>new DataView(t,0).getUint32(e,!0),Int32:(t,e)=>new DataView(t,0).getInt32(e,!0)};function m(t){return p.hasOwnProperty(t)}function A(t){return m(t)?p[t].BYTES_PER_ELEMENT:0}},37203(t,e,n){n.d(e,{Ax:()=>h,Me:()=>a,mb:()=>l});var r=n(49186);const o=!0;function i(t,e,n){return{identifier:String.fromCharCode.apply(null,new Uint8Array(t,n+0,10)),version:e.getUint16(n+10,o),checksum:e.getUint32(n+12,o)}}function c(t,e){return{sizeLo:t.getUint32(e+0,o),sizeHi:t.getUint32(e+4,o),minX:t.getFloat64(e+8,o),minY:t.getFloat64(e+16,o),minZ:t.getFloat64(e+24,o),maxX:t.getFloat64(e+32,o),maxY:t.getFloat64(e+40,o),maxZ:t.getFloat64(e+48,o),errorX:t.getFloat64(e+56,o),errorY:t.getFloat64(e+64,o),errorZ:t.getFloat64(e+72,o),count:t.getUint32(e+80,o),reserved:t.getUint32(e+84,o)}}function a(t){const e=new DataView(t,0);let n=0;const{identifier:o,version:a}=i(t,e,n);if(n+=16,"LEPCC "!==o)throw new r.A("lepcc-decode-error","Bad identifier");if(a>1)throw new r.A("lepcc-decode-error","Unknown version");const s=c(e,n);if(n+=88,s.sizeHi*2**32+s.sizeLo!==t.byteLength)throw new r.A("lepcc-decode-error","Bad size");const f=new Float64Array(3*s.count),l=[],d=[],h=[],g=[];if(n=u(t,n,l),n=u(t,n,d),n=u(t,n,h),n=u(t,n,g),n!==t.byteLength)throw new r.A("lepcc-decode-error","Bad length");let w=0,y=0;for(let t=0;t<l.length;t++){y+=l[t];let e=0;for(let n=0;n<d[t];n++){e+=h[w];const t=g[w];f[3*w]=Math.min(s.maxX,s.minX+2*s.errorX*e),f[3*w+1]=Math.min(s.maxY,s.minY+2*s.errorY*y),f[3*w+2]=Math.min(s.maxZ,s.minZ+2*s.errorZ*t),w++}}return{errorX:s.errorX,errorY:s.errorY,errorZ:s.errorZ,result:f}}function u(t,e,n){const r=[];e=s(t,e,r);const o=[];for(let i=0;i<r.length;i++){o.length=0,e=s(t,e,o);for(let t=0;t<o.length;t++)n.push(o[t]+r[i])}return e}function s(t,e,n){const i=new DataView(t,e),c=i.getUint8(0),a=31&c,u=!!(32&c),s=(192&c)>>6;let f=0;if(0===s)f=i.getUint32(1,o),e+=5;else if(1===s)f=i.getUint16(1,o),e+=3;else{if(2!==s)throw new r.A("lepcc-decode-error","Bad count type");f=i.getUint8(1),e+=2}if(u)throw new r.A("lepcc-decode-error","LUT not implemented");const l=Math.ceil(f*a/8),d=new Uint8Array(t,e,l);let h=0,g=0,w=0;const y=-1>>>32-a;for(let t=0;t<f;t++){for(;g<a;)h|=d[w]<<g,g+=8,w+=1;n[t]=h&y,h>>>=a,g-=a,g+a>32&&(h|=d[w-1]>>8-g)}return e+w}function f(t,e){return{sizeLo:t.getUint32(e+0,o),sizeHi:t.getUint32(e+4,o),count:t.getUint32(e+8,o),colorMapCount:t.getUint16(e+12,o),lookupMethod:t.getUint8(e+14),compressionMethod:t.getUint8(e+15)}}function l(t){const e=new DataView(t,0);let n=0;const{identifier:o,version:c}=i(t,e,n);if(n+=16,"ClusterRGB"!==o)throw new r.A("lepcc-decode-error","Bad identifier");if(c>1)throw new r.A("lepcc-decode-error","Unknown version");const a=f(e,n);if(n+=16,a.sizeHi*2**32+a.sizeLo!==t.byteLength)throw new r.A("lepcc-decode-error","Bad size");if((2===a.lookupMethod||1===a.lookupMethod)&&0===a.compressionMethod){if(3*a.colorMapCount+a.count+n!==t.byteLength||a.colorMapCount>256)throw new r.A("lepcc-decode-error","Bad count");const e=new Uint8Array(t,n,3*a.colorMapCount),o=new Uint8Array(t,n+3*a.colorMapCount,a.count),i=new Uint8Array(3*a.count);for(let t=0;t<a.count;t++){const n=o[t];i[3*t]=e[3*n],i[3*t+1]=e[3*n+1],i[3*t+2]=e[3*n+2]}return i}if(0===a.lookupMethod&&0===a.compressionMethod){if(3*a.count+n!==t.byteLength||0!==a.colorMapCount)throw new r.A("lepcc-decode-error","Bad count");return new Uint8Array(t,n).slice()}if(a.lookupMethod<=2&&1===a.compressionMethod){if(n+3!==t.byteLength||1!==a.colorMapCount)throw new r.A("lepcc-decode-error","Bad count");const o=e.getUint8(n),i=e.getUint8(n+1),c=e.getUint8(n+2),u=new Uint8Array(3*a.count);for(let t=0;t<a.count;t++)u[3*t]=o,u[3*t+1]=i,u[3*t+2]=c;return u}throw new r.A("lepcc-decode-error","Bad method "+a.lookupMethod+","+a.compressionMethod)}function d(t,e){return{sizeLo:t.getUint32(e+0,o),sizeHi:t.getUint32(e+4,o),count:t.getUint32(e+8,o),scaleFactor:t.getUint16(e+12,o),bitsPerPoint:t.getUint8(e+14),reserved:t.getUint8(e+15)}}function h(t){const e=new DataView(t,0);let n=0;const{identifier:o,version:c}=i(t,e,n);if(n+=16,"Intensity "!==o)throw new r.A("lepcc-decode-error","Bad identifier");if(c>1)throw new r.A("lepcc-decode-error","Unknown version");const a=d(e,n);if(n+=16,a.sizeHi*2**32+a.sizeLo!==t.byteLength)throw new r.A("lepcc-decode-error","Bad size");const u=new Uint16Array(a.count);if(8===a.bitsPerPoint){if(a.count+n!==t.byteLength)throw new r.A("lepcc-decode-error","Bad size");const e=new Uint8Array(t,n,a.count);for(let t=0;t<a.count;t++)u[t]=e[t]*a.scaleFactor}else if(16===a.bitsPerPoint){if(2*a.count+n!==t.byteLength)throw new r.A("lepcc-decode-error","Bad size");const e=new Uint16Array(t,n,a.count);for(let t=0;t<a.count;t++)u[t]=e[t]*a.scaleFactor}else{const e=[];if(s(t,n,e)!==t.byteLength)throw new r.A("lepcc-decode-error","Bad size");for(let t=0;t<a.count;t++)u[t]=e[t]*a.scaleFactor}return u}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9013],{29013(a,r,e){async function t(a={}){var r,e=a,t="./this.program",n="";try{n=new URL(".","").href}catch{}r=async a=>{if((a=await fetch(a,{credentials:"same-origin"})).ok)return a.arrayBuffer();throw Error(a.status+" : "+a.url)};var o,i,s,u,f,l,h,c,w,d,v,p,m,b,y,g=console.log.bind(console),$=console.error.bind(console),A=!1,k=!1;function C(){var a=Yr.buffer;f=new Int8Array(a),h=new Int16Array(a),l=new Uint8Array(a),c=new Uint16Array(a),w=new Int32Array(a),d=new Uint32Array(a),v=new Float32Array(a),p=new Float64Array(a),m=new BigInt64Array(a),b=new BigUint64Array(a)}function E(a){throw e.onAbort?.(a),$(a="Aborted("+a+")"),A=!0,a=new WebAssembly.RuntimeError(a+". Build with -sASSERTIONS for more info."),u?.(a),a}async function x(a){if(!o)try{var e=await r(a);return new Uint8Array(e)}catch{}if(a!=y||!o)throw"both async and sync fetching of the wasm failed";return new Uint8Array(o)}class O{name="ExitStatus";constructor(a){this.message=`Program terminated with exit(${a})`,this.status=a}}var T=a=>{for(;0<a.length;)a.shift()(e)},D=[],R=[],S=()=>{var a=e.preRun.shift();R.push(a)},j=!0;class P{constructor(a){this.ra=a-24}}var q={},I=a=>{for(;a.length;){var r=a.pop();a.pop()(r)}};function B(a){return this.sa(d[a>>2])}var U={},z={},M={},F=class extends Error{constructor(a){super(a),this.name="InternalError"}},N=(a,r,e)=>{function t(r){if((r=e(r)).length!==a.length)throw new F("Mismatched type converter count");for(var t=0;t<a.length;++t)H(a[t],r[t])}a.forEach(a=>M[a]=r);var n=Array(r.length),o=[],i=0;for(let[a,e]of r.entries())z.hasOwnProperty(e)?n[a]=z[e]:(o.push(e),U.hasOwnProperty(e)||(U[e]=[]),U[e].push(()=>{n[a]=z[e],++i===o.length&&t(n)}));0===o.length&&t(n)},L=a=>{for(var r="";;){var e=l[a++];if(!e)return r;r+=String.fromCharCode(e)}},W=class extends Error{constructor(a){super(a),this.name="BindingError"}};function H(a,r,e={}){return function(a,r,e={}){var t=r.name;if(!a)throw new W(`type "${t}" must have a positive integer typeid pointer`);if(z.hasOwnProperty(a)){if(e.Pb)return;throw new W(`Cannot register type '${t}' twice`)}z[a]=r,delete M[a],U.hasOwnProperty(a)&&(r=U[a],delete U[a],r.forEach(a=>a()))}(a,r,e)}var G=(a,r,e)=>{switch(r){case 1:return e?a=>f[a]:a=>l[a];case 2:return e?a=>h[a>>1]:a=>c[a>>1];case 4:return e?a=>w[a>>2]:a=>d[a>>2];case 8:return e?a=>m[a>>3]:a=>b[a>>3];default:throw new TypeError(`invalid integer width (${r}): ${a}`)}},J=a=>{throw new W(a.ma.ta.na.name+" instance already deleted")},K=!1,_=()=>{},V=a=>globalThis.FinalizationRegistry?(K=new FinalizationRegistry(a=>{--(a=a.ma).count.value,0===a.count.value&&(a.xa?a.Ca.Ha(a.xa):a.ta.na.Ha(a.ra))}),_=a=>{K.unregister(a)},(V=a=>{var r=a.ma;return r.xa&&K.register(a,{ma:r},a),a})(a)):(V=a=>a,a);function Q(){}var Y=(a,r)=>Object.defineProperty(r,"name",{value:a}),X={},Z=(a,r,e)=>{if(void 0===a[r].ua){var t=a[r];a[r]=function(...t){if(!a[r].ua.hasOwnProperty(t.length))throw new W(`Function '${e}' called with an invalid number of arguments (${t.length}) - expects one of (${a[r].ua})!`);return a[r].ua[t.length].apply(this,t)},a[r].ua=[],a[r].ua[t.Ja]=t}},aa=(a,r,t)=>{if(e.hasOwnProperty(a)){if(void 0===t||void 0!==e[a].ua&&void 0!==e[a].ua[t])throw new W(`Cannot register public name '${a}' twice`);if(Z(e,a,a),e[a].ua.hasOwnProperty(t))throw new W(`Cannot register multiple overloads of a function with the same number of arguments (${t})!`);e[a].ua[t]=r}else e[a]=r,e[a].Ja=t};function ra(a,r,e,t,n,o,i,s){this.name=a,this.constructor=r,this.Ma=e,this.Ha=t,this.za=n,this.Kb=o,this.Xa=i,this.Ib=s,this.Vb=[]}var ea=(a,r,e)=>{for(;r!==e;){if(!r.Xa)throw new W(`Expected null or instance of ${e.name}, got an instance of ${r.name}`);a=r.Xa(a),r=r.za}return a},ta=a=>{if(null===a)return"null";var r=typeof a;return"object"===r||"array"===r||"function"===r?a.toString():""+a};function na(a,r){if(null===r){if(this.lb)throw new W(`null is not a valid ${this.name}`);return 0}if(!r.ma)throw new W(`Cannot pass "${ta(r)}" as a ${this.name}`);if(!r.ma.ra)throw new W(`Cannot pass deleted object as a pointer of type ${this.name}`);return ea(r.ma.ra,r.ma.ta.na,this.na)}function oa(a,r){if(null===r){if(this.lb)throw new W(`null is not a valid ${this.name}`);if(this.ab){var e=this.ob();return null!==a&&a.push(this.Ha,e),e}return 0}if(!r||!r.ma)throw new W(`Cannot pass "${ta(r)}" as a ${this.name}`);if(!r.ma.ra)throw new W(`Cannot pass deleted object as a pointer of type ${this.name}`);if(!this.$a&&r.ma.ta.$a)throw new W(`Cannot convert argument of type ${r.ma.Ca?r.ma.Ca.name:r.ma.ta.name} to parameter type ${this.name}`);if(e=ea(r.ma.ra,r.ma.ta.na,this.na),this.ab){if(void 0===r.ma.xa)throw new W("Passing raw pointer to smart pointer is illegal");switch(this.$b){case 0:if(r.ma.Ca!==this)throw new W(`Cannot convert argument of type ${r.ma.Ca?r.ma.Ca.name:r.ma.ta.name} to parameter type ${this.name}`);e=r.ma.xa;break;case 1:e=r.ma.xa;break;case 2:if(r.ma.Ca===this)e=r.ma.xa;else{var t=r.clone();e=this.Wb(e,Ea(()=>t.delete())),null!==a&&a.push(this.Ha,e)}break;default:throw new W("Unsupported sharing policy")}}return e}function ia(a,r){if(null===r){if(this.lb)throw new W(`null is not a valid ${this.name}`);return 0}if(!r.ma)throw new W(`Cannot pass "${ta(r)}" as a ${this.name}`);if(!r.ma.ra)throw new W(`Cannot pass deleted object as a pointer of type ${this.name}`);if(r.ma.ta.$a)throw new W(`Cannot convert argument of type ${r.ma.ta.name} to parameter type ${this.name}`);return ea(r.ma.ra,r.ma.ta.na,this.na)}var sa=(a,r,e)=>r===e?a:void 0===e.za||null===(a=sa(a,r,e.za))?null:e.Ib(a),ua={},fa=(a,r)=>{if(!r.ta||!r.ra)throw new F("makeClassHandle requires ptr and ptrType");if(!!r.Ca!=!!r.xa)throw new F("Both smartPtrType and smartPtr must be specified");return r.count={value:1},V(Object.create(a,{ma:{value:r,writable:!0}}))};function la(a,r,e,t,n,o,i,s,u,f,l){this.name=a,this.na=r,this.lb=e,this.$a=t,this.ab=n,this.Ub=o,this.$b=i,this.zb=s,this.ob=u,this.Wb=f,this.Ha=l,n||void 0!==r.za?this.va=oa:(this.va=t?na:ia,this.ya=null)}var ha=(a,r,t)=>{if(!e.hasOwnProperty(a))throw new F("Replacing nonexistent public symbol");void 0!==e[a].ua&&void 0!==t?e[a].ua[t]=r:(e[a]=r,e[a].Ja=t)},ca=[],wa=(a,r)=>{var e;if(a=L(a),(e=ca[r])||(ca[r]=e=Xr.get(r)),"function"!=typeof e)throw new W(`unknown function pointer with signature ${a}: ${r}`);return e};class da extends Error{}var va=a=>{a=Jr(a);var r=L(a);return _r(a),r},pa=(a,r)=>{var e=[],t={};throw r.forEach(function a(r){t[r]||z[r]||(M[r]?M[r].forEach(a):(e.push(r),t[r]=!0))}),new da(`${a}: `+e.map(va).join([", "]))};function ma(a,r,e,t,n){var o=r.length;if(2>o)throw new W("argTypes array size mismatch! Must at least get return value and 'this' types!");var i=null!==r[1]&&null!==e,s=function(a){for(var r=1;r<a.length;++r)if(null!==a[r]&&void 0===a[r].ya)return!0;return!1}(r),u=!r[0].Qb,f=o-2,l=Array(f),h=[],c=[];return Y(a,function(...a){if(c.length=0,h.length=i?2:1,h[0]=n,i){var e=r[1].va(c,this);h[1]=e}for(var o=0;o<f;++o)l[o]=r[o+2].va(c,a[o]),h.push(l[o]);if(a=t(...h),s)I(c);else for(o=i?1:2;o<r.length;o++){var w=1===o?e:l[o-2];null!==r[o].ya&&r[o].ya(w)}return u?r[0].sa(a):void 0})}var ba=(a,r)=>{for(var e=[],t=0;t<a;t++)e.push(d[r+4*t>>2]);return e},ya=a=>{const r=(a=a.trim()).indexOf("(");return-1===r?a:a.slice(0,r)},ga=(a,r,e)=>{if(!(a instanceof Object))throw new W(`${e} with invalid "this": ${a}`);if(!(a instanceof r.na.constructor))throw new W(`${e} incompatible with "this" of type ${a.constructor.name}`);if(!a.ma.ra)throw new W(`cannot call emscripten binding method ${e} on deleted object`);return ea(a.ma.ra,a.ma.ta.na,r.na)},$a=[],Aa=[0,1,,1,null,1,!0,1,!1,1],ka=a=>{9<a&&0===--Aa[a+1]&&(Aa[a]=void 0,$a.push(a))},Ca=a=>{if(!a)throw new W(`Cannot use deleted val. handle = ${a}`);return Aa[a]},Ea=a=>{switch(a){case void 0:return 2;case null:return 4;case!0:return 6;case!1:return 8;default:const r=$a.pop()||Aa.length;return Aa[r]=a,Aa[r+1]=1,r}},xa={name:"emscripten::val",sa:a=>{var r=Ca(a);return ka(a),r},va:(a,r)=>Ea(r),Aa:B,ya:null},Oa=(a,r,e)=>{switch(r){case 1:return e?function(a){return this.sa(f[a])}:function(a){return this.sa(l[a])};case 2:return e?function(a){return this.sa(h[a>>1])}:function(a){return this.sa(c[a>>1])};case 4:return e?function(a){return this.sa(w[a>>2])}:function(a){return this.sa(d[a>>2])};default:throw new TypeError(`invalid integer width (${r}): ${a}`)}},Ta=(a,r)=>{var e=z[a];if(void 0===e)throw a=`${r} has unknown type ${va(a)}`,new W(a);return e},Da=(a,r)=>{switch(r){case 4:return function(a){return this.sa(v[a>>2])};case 8:return function(a){return this.sa(p[a>>3])};default:throw new TypeError(`invalid float width (${r}): ${a}`)}},Ra=Object.assign({optional:!0},xa),Sa=(a,r,e,t)=>{if(!(0<t))return 0;var n=e;t=e+t-1;for(var o=0;o<a.length;++o){var i=a.codePointAt(o);if(127>=i){if(e>=t)break;r[e++]=i}else if(2047>=i){if(e+1>=t)break;r[e++]=192|i>>6,r[e++]=128|63&i}else if(65535>=i){if(e+2>=t)break;r[e++]=224|i>>12,r[e++]=128|i>>6&63,r[e++]=128|63&i}else{if(e+3>=t)break;r[e++]=240|i>>18,r[e++]=128|i>>12&63,r[e++]=128|i>>6&63,r[e++]=128|63&i,o++}}return r[e]=0,e-n},ja=a=>{for(var r=0,e=0;e<a.length;++e){var t=a.charCodeAt(e);127>=t?r++:2047>=t?r+=2:55296<=t&&57343>=t?(r+=4,++e):r+=3}return r},Pa=globalThis.TextDecoder&&new TextDecoder,qa=(a,r,e,t)=>{if(e=r+e,t)return e;for(;a[r]&&!(r>=e);)++r;return r},Ia=(a,r=0,e,t)=>{if(16<(e=qa(a,r,e,t))-r&&a.buffer&&Pa)return Pa.decode(a.subarray(r,e));for(t="";r<e;){var n=a[r++];if(128&n){var o=63&a[r++];if(192==(224&n))t+=String.fromCharCode((31&n)<<6|o);else{var i=63&a[r++];65536>(n=224==(240&n)?(15&n)<<12|o<<6|i:(7&n)<<18|o<<12|i<<6|63&a[r++])?t+=String.fromCharCode(n):(n-=65536,t+=String.fromCharCode(55296|n>>10,56320|1023&n))}}else t+=String.fromCharCode(n)}return t},Ba=globalThis.TextDecoder?new TextDecoder("utf-16le"):void 0,Ua=(a,r,e)=>{if(16<(r=qa(c,a>>=1,r/2,e))-a&&Ba)return Ba.decode(c.subarray(a,r));for(e="";a<r;++a)e+=String.fromCharCode(c[a]);return e},za=(a,r,e)=>{if(e??=2147483647,2>e)return 0;var t=r;e=(e-=2)<2*a.length?e/2:a.length;for(var n=0;n<e;++n)h[r>>1]=a.charCodeAt(n),r+=2;return h[r>>1]=0,r-t},Ma=a=>2*a.length,Fa=(a,r,e)=>{var t="";a>>=2;for(var n=0;!(n>=r/4);n++){var o=d[a+n];if(!o&&!e)break;t+=String.fromCodePoint(o)}return t},Na=(a,r,e)=>{if(e??=2147483647,4>e)return 0;var t=r;e=t+e-4;for(var n=0;n<a.length;++n){var o=a.codePointAt(n);if(65535<o&&n++,w[r>>2]=o,(r+=4)+4>e)break}return w[r>>2]=0,r-t},La=a=>{for(var r=0,e=0;e<a.length;++e)65535<a.codePointAt(e)&&e++,r+=4;return r},Wa=0,Ha=[],Ga={},Ja=a=>{var r=Ga[a];return void 0===r?L(a):r},Ka=(a,r)=>{for(var e=0,t=a.length-1;0<=t;t--){var n=a[t];"."===n?a.splice(t,1):".."===n?(a.splice(t,1),e++):e&&(a.splice(t,1),e--)}if(r)for(;e;e--)a.unshift("..");return a},_a=a=>{var r="/"===a.charAt(0),e="/"===a.slice(-1);return(a=Ka(a.split("/").filter(a=>!!a),!r).join("/"))||r||(a="."),a&&e&&(a+="/"),(r?"/":"")+a},Va=a=>{var r=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/.exec(a).slice(1);return a=r[0],r=r[1],a||r?(r&&=r.slice(0,-1),a+r):"."},Qa=a=>{(Qa=a=>crypto.getRandomValues(a))(a)},Ya=[],Xa=[];function Za(a,r){Xa[a]={input:[],output:[],Ra:r},Er(a,ar)}var ar={open(a){var r=Xa[a.node.fb];if(!r)throw new cr(43);a.Da=r,a.seekable=!1},close(a){a.Da.Ra.Za(a.Da)},Za(a){a.Da.Ra.Za(a.Da)},read(a,r,e,t){if(!a.Da||!a.Da.Ra.tb)throw new cr(60);for(var n=0,o=0;o<t;o++){try{var i=a.Da.Ra.tb(a.Da)}catch(a){throw new cr(29)}if(void 0===i&&0===n)throw new cr(6);if(null==i)break;n++,r[e+o]=i}return n&&(a.node.Na=Date.now()),n},write(a,r,e,t){if(!a.Da||!a.Da.Ra.nb)throw new cr(60);try{for(var n=0;n<t;n++)a.Da.Ra.nb(a.Da,r[e+n])}catch(a){throw new cr(29)}return t&&(a.node.Ea=a.node.Ba=Date.now()),n}},rr={tb(){a:{if(!Ya.length){var a=null;if(globalThis.window?.prompt&&null!==(a=window.prompt("Input: "))&&(a+="\n"),!a){var r=null;break a}r=Array(ja(a)+1),a=Sa(a,r,0,r.length),r.length=a,Ya=r}r=Ya.shift()}return r},nb(a,r){null===r||10===r?(g(Ia(a.output)),a.output=[]):0!=r&&a.output.push(r)},Za(a){0<a.output?.length&&(g(Ia(a.output)),a.output=[])},oc:()=>({fc:25856,ic:5,ec:191,hc:35387,dc:[3,28,127,21,4,0,1,0,17,19,26,0,18,15,23,22,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]}),pc:()=>0,qc:()=>[24,80]},er={nb(a,r){null===r||10===r?($(Ia(a.output)),a.output=[]):0!=r&&a.output.push(r)},Za(a){0<a.output?.length&&($(Ia(a.output)),a.output=[])}},tr={Ga:null,Ka:()=>tr.createNode(null,"/",16895,0),createNode(a,r,e,t){if(24576==(61440&e)||4096==(61440&e))throw new cr(63);return tr.Ga||(tr.Ga={dir:{node:{La:tr.pa.La,Ia:tr.pa.Ia,Ua:tr.pa.Ua,cb:tr.pa.cb,Ab:tr.pa.Ab,Eb:tr.pa.Eb,Db:tr.pa.Db,pb:tr.pa.pb,gb:tr.pa.gb},stream:{Fa:tr.qa.Fa}},file:{node:{La:tr.pa.La,Ia:tr.pa.Ia},stream:{Fa:tr.qa.Fa,read:tr.qa.read,write:tr.qa.write,wb:tr.qa.wb,yb:tr.qa.yb}},link:{node:{La:tr.pa.La,Ia:tr.pa.Ia,Wa:tr.pa.Wa},stream:{}},qb:{node:{La:tr.pa.La,Ia:tr.pa.Ia},stream:Cr}}),16384==(61440&(e=br(a,r,e,t)).mode)?(e.pa=tr.Ga.dir.node,e.qa=tr.Ga.dir.stream,e.oa={}):32768==(61440&e.mode)?(e.pa=tr.Ga.file.node,e.qa=tr.Ga.file.stream,e.wa=0,e.oa=null):40960==(61440&e.mode)?(e.pa=tr.Ga.link.node,e.qa=tr.Ga.link.stream):8192==(61440&e.mode)&&(e.pa=tr.Ga.qb.node,e.qa=tr.Ga.qb.stream),e.Na=e.Ea=e.Ba=Date.now(),a&&(a.oa[r]=e,a.Na=a.Ea=a.Ba=e.Na),e},lc:a=>a.oa?a.oa.subarray?a.oa.subarray(0,a.wa):new Uint8Array(a.oa):new Uint8Array(0),pa:{La(a){var r={};return r.jc=8192==(61440&a.mode)?a.id:1,r.nc=a.id,r.mode=a.mode,r.rc=1,r.uid=0,r.mc=0,r.fb=a.fb,16384==(61440&a.mode)?r.size=4096:32768==(61440&a.mode)?r.size=a.wa:40960==(61440&a.mode)?r.size=a.link.length:r.size=0,r.Na=new Date(a.Na),r.Ea=new Date(a.Ea),r.Ba=new Date(a.Ba),r.Gb=4096,r.cc=Math.ceil(r.size/r.Gb),r},Ia(a,r){for(var e of["mode","atime","mtime","ctime"])null!=r[e]&&(a[e]=r[e]);void 0!==r.size&&(r=r.size,a.wa!=r&&(0==r?(a.oa=null,a.wa=0):(e=a.oa,a.oa=new Uint8Array(r),e&&a.oa.set(e.subarray(0,Math.min(r,a.wa))),a.wa=r)))},Ua(){throw tr.hb||(tr.hb=new cr(44),tr.hb.stack="<generic error, no stack>"),tr.hb},cb:(a,r,e,t)=>tr.createNode(a,r,e,t),Ab(a,r,e){try{var t=mr(r,e)}catch(a){}if(t){if(16384==(61440&a.mode))for(var n in t.oa)throw new cr(55);if(n=pr(t.parent.id,t.name),ur[n]===t)ur[n]=t.Qa;else for(n=ur[n];n;){if(n.Qa===t){n.Qa=t.Qa;break}n=n.Qa}}delete a.parent.oa[a.name],r.oa[e]=a,a.name=e,r.Ba=r.Ea=a.parent.Ba=a.parent.Ea=Date.now()},Eb(a,r){delete a.oa[r],a.Ba=a.Ea=Date.now()},Db(a,r){var e,t=mr(a,r);for(e in t.oa)throw new cr(55);delete a.oa[r],a.Ba=a.Ea=Date.now()},pb:a=>[".","..",...Object.keys(a.oa)],gb:(a,r,e)=>((a=tr.createNode(a,r,41471,0)).link=e,a),Wa(a){if(40960!=(61440&a.mode))throw new cr(28);return a.link}},qa:{read(a,r,e,t,n){var o=a.node.oa;if(n>=a.node.wa)return 0;if(8<(a=Math.min(a.node.wa-n,t))&&o.subarray)r.set(o.subarray(n,n+a),e);else for(t=0;t<a;t++)r[e+t]=o[n+t];return a},write(a,r,e,t,n,o){if(r.buffer===f.buffer&&(o=!1),!t)return 0;if((a=a.node).Ea=a.Ba=Date.now(),r.subarray&&(!a.oa||a.oa.subarray)){if(o)return a.oa=r.subarray(e,e+t),a.wa=t;if(0===a.wa&&0===n)return a.oa=r.slice(e,e+t),a.wa=t;if(n+t<=a.wa)return a.oa.set(r.subarray(e,e+t),n),t}o=n+t;var i=a.oa?a.oa.length:0;if(i>=o||(o=Math.max(o,i*(1048576>i?2:1.125)>>>0),0!=i&&(o=Math.max(o,256)),i=a.oa,a.oa=new Uint8Array(o),0<a.wa&&a.oa.set(i.subarray(0,a.wa),0)),a.oa.subarray&&r.subarray)a.oa.set(r.subarray(e,e+t),n);else for(o=0;o<t;o++)a.oa[n+o]=r[e+o];return a.wa=Math.max(a.wa,n+t),t},Fa(a,r,e){if(1===e?r+=a.position:2===e&&32768==(61440&a.node.mode)&&(r+=a.node.wa),0>r)throw new cr(28);return r},wb(a,r,e,t,n){if(32768!=(61440&a.node.mode))throw new cr(43);if(a=a.node.oa,2&n||!a||a.buffer!==f.buffer){n=!0,t=65536*Math.ceil(r/65536);var o=Vr(65536,t);if(o&&l.fill(0,o,o+t),!(t=o))throw new cr(48);a&&((0<e||e+r<a.length)&&(a=a.subarray?a.subarray(e,e+r):Array.prototype.slice.call(a,e,e+r)),f.set(a,t))}else n=!1,t=a.byteOffset;return{ra:t,bc:n}},yb:(a,r,e,t)=>(tr.qa.write(a,r,0,t,e,!1),0)}},nr=null,or={},ir=[],sr=1,ur=null,fr=!1,lr=!0,hr={},cr=class{name="ErrnoError";constructor(a){this.Ta=a}},wr=class{bb={};node=null;get flags(){return this.bb.flags}set flags(a){this.bb.flags=a}get position(){return this.bb.position}set position(a){this.bb.position=a}},dr=class{pa={};qa={};eb=null;constructor(a,r,e,t){a||=this,this.parent=a,this.Ka=a.Ka,this.id=sr++,this.name=r,this.mode=e,this.fb=t,this.Na=this.Ea=this.Ba=Date.now()}get read(){return!(365&~this.mode)}set read(a){a?this.mode|=365:this.mode&=-366}get write(){return!(146&~this.mode)}set write(a){a?this.mode|=146:this.mode&=-147}};function vr(a,r={}){if(!a)throw new cr(44);r.jb??(r.jb=!0),"/"===a.charAt(0)||(a="//"+a);var e=0;a:for(;40>e;e++){a=a.split("/").filter(a=>!!a);for(var t=nr,n="/",o=0;o<a.length;o++){var i=o===a.length-1;if(i&&r.parent)break;if("."!==a[o])if(".."===a[o]){if(n=Va(n),t===t.parent){a=n+"/"+a.slice(o+1).join("/"),e--;continue a}t=t.parent}else{n=_a(n+"/"+a[o]);try{t=mr(t,a[o])}catch(a){if(44===a?.Ta&&i&&r.Tb)return{path:n};throw a}if(!t.eb||i&&!r.jb||(t=t.eb.root),40960==(61440&t.mode)&&(!i||r.ib)){if(!t.pa.Wa)throw new cr(52);"/"===(t=t.pa.Wa(t)).charAt(0)||(t=Va(n)+"/"+t),a=t+"/"+a.slice(o+1).join("/");continue a}}}return{path:n,node:t}}throw new cr(32)}function pr(a,r){for(var e=0,t=0;t<r.length;t++)e=(e<<5)-e+r.charCodeAt(t)|0;return(a+e>>>0)%ur.length}function mr(a,r){var e=16384==(61440&a.mode)?(e=gr(a,"x"))?e:a.pa.Ua?0:2:54;if(e)throw new cr(e);for(e=ur[pr(a.id,r)];e;e=e.Qa){var t=e.name;if(e.parent.id===a.id&&t===r)return e}return a.pa.Ua(a,r)}function br(a,r,e,t){return r=pr((a=new dr(a,r,e,t)).parent.id,a.name),a.Qa=ur[r],ur[r]=a}function yr(a){var r=["r","w","rw"][3&a];return 512&a&&(r+="w"),r}function gr(a,r){return lr?0:!r.includes("r")||292&a.mode?r.includes("w")&&!(146&a.mode)||r.includes("x")&&!(73&a.mode)?2:0:2}function $r(a,r){if(16384!=(61440&a.mode))return 54;try{return mr(a,r),20}catch(a){}return gr(a,"wx")}function Ar(a){if(!(a=ir[a]))throw new cr(8);return a}function kr(a,r){var e=void 0,t=e?null:a;if(e??=a.pa.Ia,!e)throw new cr(63);e(t,r)}var Cr={open(a){a.qa=or[a.node.fb].qa,a.qa.open?.(a)},Fa(){throw new cr(70)}};function Er(a,r){or[a]={qa:r}}function xr(a,r){var e="/"===r;if(e&&nr)throw new cr(10);if(!e&&r){var t=vr(r,{jb:!1});if(r=t.path,(t=t.node).eb)throw new cr(10);if(16384!=(61440&t.mode))throw new cr(54)}r={type:a,sc:{},xb:r,Sb:[]},(a=a.Ka(r)).Ka=r,r.root=a,e?nr=a:t&&(t.eb=r,t.Ka&&t.Ka.Sb.push(r))}function Or(a,r,e){var t=vr(a,{parent:!0}).node;if(!(a=a&&a.match(/([^\/]+|\/)\/*$/)[1]))throw new cr(28);if("."===a||".."===a)throw new cr(20);var n=$r(t,a);if(n)throw new cr(n);if(!t.pa.cb)throw new cr(63);return t.pa.cb(t,a,r,e)}function Tr(a){return Or(a,16895,0)}function Dr(a,r,e){void 0===e&&(e=r,r=438),Or(a,8192|r,e)}function Rr(a,r){if(!((...a)=>{for(var r="",e=!1,t=a.length-1;-1<=t&&!e;t--){if("string"!=typeof(e=0<=t?a[t]:"/"))throw new TypeError("Arguments to path.resolve must be strings");if(!e)return"";r=e+"/"+r,e="/"===e.charAt(0)}return(e?"/":"")+(r=Ka(r.split("/").filter(a=>!!a),!e).join("/"))||"."})(a))throw new cr(44);var e=vr(r,{parent:!0}).node;if(!e)throw new cr(44);var t=$r(e,r=r&&r.match(/([^\/]+|\/)\/*$/)[1]);if(t)throw new cr(t);if(!e.pa.gb)throw new cr(63);e.pa.gb(e,r,a)}function Sr(a,r){if(""===a)throw new cr(44);if("string"==typeof r){var t={r:0,"r+":2,w:577,"w+":578,a:1089,"a+":1090}[r];if(void 0===t)throw Error(`Unknown file open mode: ${r}`);r=t}if(t=64&r?33206:0,"object"==typeof a)var n=a;else{var o=a.endsWith("/");n=(a=vr(a,{ib:!(131072&r),Tb:!0})).node,a=a.path}var i=!1;if(64&r)if(n){if(128&r)throw new cr(20)}else{if(o)throw new cr(31);n=Or(a,511|t,0),i=!0}if(!n)throw new cr(44);if(8192==(61440&n.mode)&&(r&=-513),65536&r&&16384!=(61440&n.mode))throw new cr(54);if(!i&&(o=n?40960==(61440&n.mode)?32:16384==(61440&n.mode)&&("r"!==yr(r)||576&r)?31:gr(n,yr(r)):44))throw new cr(o);if(512&r&&!i){if(16384==(61440&(o="string"==typeof(o=n)?vr(o,{ib:!0}).node:o).mode))throw new cr(31);if(32768!=(61440&o.mode))throw new cr(28);var s=gr(o,"w");if(s)throw new cr(s);kr(o,{size:0,timestamp:Date.now()})}r&=-131713;a:for(o=n;;){if(o===o.parent){o=o.Ka.xb;var u=u?"/"!==o[o.length-1]?`${o}/${u}`:o+u:o;break a}u=u?`${o.name}/${u}`:o.name,o=o.parent}if(u={node:n,path:u,flags:r,seekable:!0,position:0,qa:n.qa,ac:[],error:!1},o=-1,u=Object.assign(new wr,u),-1==o)a:{for(o=0;4096>=o;o++)if(!ir[o])break a;throw new cr(33)}u.Pa=o,ir[o]=u,u.qa.open&&u.qa.open(u),i&&(t&=511,kr(n="string"==typeof n?vr(n,{ib:!0}).node:n,{mode:4095&t|-4096&n.mode,Ba:Date.now(),kc:void 0})),!e.logReadFiles||1&r||a in hr||(hr[a]=1)}function jr(a,r,e){if(null===a.Pa)throw new cr(8);if(!a.seekable||!a.qa.Fa)throw new cr(70);if(0!=e&&1!=e&&2!=e)throw new cr(28);a.position=a.qa.Fa(a,r,e),a.ac=[]}function Pr(a,r,e){a=_a("/dev/"+a);var t=((a,r)=>{var e=0;return a&&(e|=365),r&&(e|=146),e})(!!r,!!e);Pr.vb??(Pr.vb=64);var n=Pr.vb++<<8;Er(n,{open(a){a.seekable=!1},close(){e?.buffer?.length&&e(10)},read(a,e,t,n){for(var o=0,i=0;i<n;i++){try{var s=r()}catch(a){throw new cr(29)}if(void 0===s&&0===o)throw new cr(6);if(null==s)break;o++,e[t+i]=s}return o&&(a.node.Na=Date.now()),o},write(a,r,t,n){for(var o=0;o<n;o++)try{e(r[t+o])}catch(a){throw new cr(29)}return n&&(a.node.Ea=a.node.Ba=Date.now()),o}}),Dr(a,t,n)}var qr,Ir={},Br={},Ur=a=>{if(!(a instanceof O||"unwind"==a))throw a},zr=a=>{throw i=a,j||0<Wa||(e.onExit?.(a),A=!0),new O(a)},Mr=[],Fr={},Nr=a=>{var r;return(r=/\bwasm-function\[\d+\]:(0x[0-9a-f]+)/.exec(a))?+r[1]:(r=/:(\d+):\d+(?:\)|$)/.exec(a))?2147483648|+r[1]:0},Lr=a=>{for(var r of a)(a=Nr(r))&&(Fr[a]=r)},Wr=a=>{if(!(a=Fr[a]))return 0;var r;if(r=/^\s+at .*\.wasm\.(.*) \(.*\)$/.exec(a))r=r[1];else if(r=/^\s+at (.*) \(.*\)$/.exec(a))r=r[1];else{if(!(r=/^(.+?)@/.exec(a)))return 0;r=r[1]}_r(Wr.Bb??0),a=Wr;var e=ja(r)+1,t=Kr(e);return t&&Sa(r,l,t,e),a.Bb=t,Wr.Bb},Hr={},Gr=()=>{if(!qr){var a,r={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:(globalThis.navigator?.language??"C").replace("-","_")+".UTF-8",_:t||"./this.program"};for(a in Hr)void 0===Hr[a]?delete r[a]:r[a]=Hr[a];var e=[];for(a in r)e.push(`${a}=${r[a]}`);qr=e}return qr};if((()=>{let a=Q.prototype;Object.assign(a,{isAliasOf:function(a){if(!(this instanceof Q&&a instanceof Q))return!1;var r=this.ma.ta.na,e=this.ma.ra;a.ma=a.ma;var t=a.ma.ta.na;for(a=a.ma.ra;r.za;)e=r.Xa(e),r=r.za;for(;t.za;)a=t.Xa(a),t=t.za;return r===t&&e===a},clone:function(){if(this.ma.ra||J(this),this.ma.Va)return this.ma.count.value+=1,this;var a=V,r=Object,e=r.create,t=Object.getPrototypeOf(this),n=this.ma;return(a=a(e.call(r,t,{ma:{value:{count:n.count,Sa:n.Sa,Va:n.Va,ra:n.ra,ta:n.ta,xa:n.xa,Ca:n.Ca}}}))).ma.count.value+=1,a.ma.Sa=!1,a},delete(){if(this.ma.ra||J(this),this.ma.Sa&&!this.ma.Va)throw new W("Object already scheduled for deletion");_(this);var a=this.ma;--a.count.value,0===a.count.value&&(a.xa?a.Ca.Ha(a.xa):a.ta.na.Ha(a.ra)),this.ma.Va||(this.ma.xa=void 0,this.ma.ra=void 0)},isDeleted:function(){return!this.ma.ra},deleteLater:function(){if(this.ma.ra||J(this),this.ma.Sa&&!this.ma.Va)throw new W("Object already scheduled for deletion");return this.ma.Sa=!0,this}});const r=Symbol.dispose;r&&(a[r]=a.delete)})(),Object.assign(la.prototype,{Lb(a){return this.zb&&(a=this.zb(a)),a},rb(a){this.Ha?.(a)},Aa:B,sa:function(a){function r(){return this.ab?fa(this.na.Ma,{ta:this.Ub,ra:e,Ca:this,xa:a}):fa(this.na.Ma,{ta:this,ra:a})}var e=this.Lb(a);if(!e)return this.rb(a),null;var t=((a,r)=>{if(void 0===r)throw new W("ptr should not be undefined");for(;a.za;)r=a.Xa(r),a=a.za;return ua[r]})(this.na,e);if(void 0!==t)return 0===t.ma.count.value?(t.ma.ra=e,t.ma.xa=a,t.clone()):(t=t.clone(),this.rb(a),t);if(t=this.na.Kb(e),!(t=X[t]))return r.call(this);t=this.$a?t.Hb:t.pointerType;var n=sa(e,this.na,t.na);return null===n?r.call(this):this.ab?fa(t.na.Ma,{ta:t,ra:n,Ca:this,xa:a}):fa(t.na.Ma,{ta:t,ra:n})}}),ur=Array(4096),xr(tr,"/"),Tr("/tmp"),Tr("/home"),Tr("/home/web_user"),function(){Tr("/dev"),Er(259,{read:()=>0,write:(a,r,e,t)=>t,Fa:()=>0}),Dr("/dev/null",259),Za(1280,rr),Za(1536,er),Dr("/dev/tty",1280),Dr("/dev/tty1",1536);var a=new Uint8Array(1024),r=0,e=()=>(0===r&&(Qa(a),r=a.byteLength),a[--r]);Pr("random",e),Pr("urandom",e),Tr("/dev/shm"),Tr("/dev/shm/tmp")}(),function(){Tr("/proc");var a=Tr("/proc/self");Tr("/proc/self/fd"),xr({Ka(){var r=br(a,"fd",16895,73);return r.qa={Fa:tr.qa.Fa},r.pa={Ua(a,r){var e=Ar(a=+r);return(a={parent:null,Ka:{xb:"fake"},pa:{Wa:()=>e.path},id:a+1}).parent=a},pb:()=>Array.from(ir.entries()).filter(([,a])=>a).map(([a])=>a.toString())},r}},"/proc/self/fd")}(),e.noExitRuntime&&(j=e.noExitRuntime),e.print&&(g=e.print),e.printErr&&($=e.printErr),e.wasmBinary&&(o=e.wasmBinary),e.thisProgram&&(t=e.thisProgram),e.preInit)for("function"==typeof e.preInit&&(e.preInit=[e.preInit]);0<e.preInit.length;)e.preInit.shift()();var Jr,Kr,_r,Vr,Qr,Yr,Xr,Zr,ae={251432:()=>"undefined"!=typeof wasmOffsetConverter},re={U:function(){return"undefined"!=typeof wasmOffsetConverter},n:(a,r,e)=>{var t=new P(a);throw d[t.ra+16>>2]=0,d[t.ra+4>>2]=r,d[t.ra+8>>2]=e,a},Q:()=>E(""),r:a=>{var r=q[a];delete q[a];var e=r.ob,t=r.Ha,n=r.sb,o=n.map(a=>a.Ob).concat(n.map(a=>a.Yb));N([a],o,a=>{var o,i,s={};for([o,i]of n.entries()){const r=a[o],e=i.Mb,t=i.Nb,u=a[o+n.length],f=i.Xb,l=i.Zb;s[i.Jb]={read:a=>r.sa(e(t,a)),write:(a,r)=>{var e=[];f(l,a,u.va(e,r)),I(e)},optional:r.optional}}return[{name:r.name,sa:a=>{var r,e={};for(r in s)e[r]=s[r].read(a);return t(a),e},va:(a,r)=>{for(var n in s)if(!(n in r)&&!s[n].optional)throw new TypeError(`Missing field: "${n}"`);var o=e();for(n in s)s[n].write(o,r[n]);return null!==a&&a.push(t,o),o},Aa:B,ya:t}]})},E:(a,r,e,t,n)=>{r=L(r);let o=a=>a;if(t=0n===t){const a=8*e;o=r=>BigInt.asUintN(a,r),n=o(n)}H(a,{name:r,sa:o,va:(a,r)=>("number"==typeof r&&(r=BigInt(r)),r),Aa:G(r,e,!t),ya:null})},ba:(a,r,e,t)=>{H(a,{name:r=L(r),sa:function(a){return!!a},va:function(a,r){return r?e:t},Aa:function(a){return this.sa(l[a])},ya:null})},e:(a,r,e,t,n,o,i,s,u,f,l,h,c)=>{l=L(l),o=wa(n,o),s&&=wa(i,s),f&&=wa(u,f),c=wa(h,c);var w=(a=>{var r=(a=a.replace(/[^a-zA-Z0-9_]/g,"$")).charCodeAt(0);return 48<=r&&57>=r?`_${a}`:a})(l);aa(w,function(){pa(`Cannot construct ${l} due to unbound types`,[t])}),N([a,r,e],t?[t]:[],r=>{if(r=r[0],t)var e=r.na,n=e.Ma;else n=Q.prototype;r=Y(l,function(...a){if(Object.getPrototypeOf(this)!==i)throw new W(`Use 'new' to construct ${l}`);if(void 0===h.Oa)throw new W(`${l} has no accessible constructor`);var r=h.Oa[a.length];if(void 0===r)throw new W(`Tried to invoke ctor of ${l} with invalid number of parameters (${a.length}) - expected (${Object.keys(h.Oa).toString()}) parameters instead!`);return r.apply(this,a)});var i=Object.create(n,{constructor:{value:r}});r.prototype=i;var u,h=new ra(l,r,i,c,e,o,s,f);return h.za&&((u=h.za).Ya??(u.Ya=[]),h.za.Ya.push(h)),e=new la(l,h,!0,!1,!1),u=new la(l+"*",h,!1,!1,!1),n=new la(l+" const*",h,!1,!0,!1),X[a]={pointerType:u,Hb:n},ha(w,r),[e,u,n]})},v:(a,r,e,t,n,o,i)=>{var s=ba(e,t);r=L(r),r=ya(r),o=wa(n,o),N([],[a],a=>{function t(){pa(`Cannot call ${n} due to unbound types`,s)}var n=`${(a=a[0]).name}.${r}`;r.startsWith("@@")&&(r=Symbol[r.substring(2)]);var u=a.na.constructor;return void 0===u[r]?(t.Ja=e-1,u[r]=t):(Z(u,r,n),u[r].ua[e-1]=t),N([],s,t=>{if(t=ma(n,[t[0],null].concat(t.slice(1)),null,o,i),void 0===u[r].ua?(t.Ja=e-1,u[r]=t):u[r].ua[e-1]=t,a.na.Ya)for(const e of a.na.Ya)e.constructor.hasOwnProperty(r)||(e.constructor[r]=t);return[]}),[]})},g:(a,r,e,t,n,o)=>{var i=ba(r,e);n=wa(t,n),N([],[a],a=>{var e=`constructor ${(a=a[0]).name}`;if(void 0===a.na.Oa&&(a.na.Oa=[]),void 0!==a.na.Oa[r-1])throw new W(`Cannot register multiple constructors with identical number of parameters (${r-1}) for class '${a.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);return a.na.Oa[r-1]=()=>{pa(`Cannot construct ${a.name} due to unbound types`,i)},N([],i,t=>(t.splice(1,0,null),a.na.Oa[r-1]=ma(e,t,null,n,o),[])),[]})},b:(a,r,e,t,n,o,i,s)=>{var u=ba(e,t);r=L(r),r=ya(r),o=wa(n,o),N([],[a],a=>{function t(){pa(`Cannot call ${n} due to unbound types`,u)}var n=`${(a=a[0]).name}.${r}`;r.startsWith("@@")&&(r=Symbol[r.substring(2)]),s&&a.na.Vb.push(r);var f=a.na.Ma,l=f[r];return void 0===l||void 0===l.ua&&l.className!==a.name&&l.Ja===e-2?(t.Ja=e-2,t.className=a.name,f[r]=t):(Z(f,r,n),f[r].ua[e-2]=t),N([],u,t=>(t=ma(n,t,a,o,i),void 0===f[r].ua?(t.Ja=e-2,f[r]=t):f[r].ua[e-2]=t,[])),[]})},c:(a,r,e,t,n,o,i,s,u,f)=>{r=L(r),n=wa(t,n),N([],[a],a=>{var t=`${(a=a[0]).name}.${r}`,l={get(){pa(`Cannot access ${t} due to unbound types`,[e,i])},enumerable:!0,configurable:!0};return l.set=u?()=>pa(`Cannot access ${t} due to unbound types`,[e,i]):()=>{throw new W(t+" is a read-only property")},Object.defineProperty(a.na.Ma,r,l),N([],u?[e,i]:[e],e=>{var i=e[0],l={get(){var r=ga(this,a,t+" getter");return i.sa(n(o,r))},enumerable:!0};if(u){u=wa(s,u);var h=e[1];l.set=function(r){var e=ga(this,a,t+" setter"),n=[];u(f,e,h.va(n,r)),I(n)}}return Object.defineProperty(a.na.Ma,r,l),[]}),[]})},_:a=>H(a,xa),m:(a,r,t,n,o)=>{switch(r=L(r),o=0===o?"object":1===o?"number":"string"){case"object":function s(){}s.values={},H(a,{name:r,constructor:s,valueType:o,sa:function(a){return this.constructor.values[a]},va:(a,r)=>r.value,Aa:Oa(r,t,n),ya:null}),aa(r,s);break;case"number":var i={};H(a,{name:r,mb:i,valueType:o,sa:a=>a,va:(a,r)=>r,Aa:Oa(r,t,n),ya:null}),aa(r,i),delete e[r].Ja;break;case"string":H(a,{name:r,Fb:{},Cb:{},mb:i={},valueType:o,sa:function(a){return this.Cb[a]},va:function(a,r){return this.Fb[r]},Aa:Oa(r,t,n),ya:null}),aa(r,i),delete e[r].Ja}},d:(a,r,e)=>{var t=Ta(a,"enum");switch(r=L(r),t.valueType){case"object":a=t.constructor,t=Object.create(t.constructor.prototype,{value:{value:e},constructor:{value:Y(`${t.name}_${r}`,function(){})}}),a.values[e]=t,a[r]=t;break;case"number":t.mb[r]=e;break;case"string":t.Fb[r]=e,t.Cb[e]=r,t.mb[r]=r}},D:(a,r,e)=>{H(a,{name:r=L(r),sa:a=>a,va:(a,r)=>r,Aa:Da(r,e),ya:null})},da:(a,r,e,t,n,o)=>{var i=ba(r,e);a=L(a),a=ya(a),n=wa(t,n),aa(a,function(){pa(`Cannot call ${a} due to unbound types`,i)},r-1),N([],i,e=>(ha(a,ma(a,[e[0],null].concat(e.slice(1)),null,n,o),r-1),[]))},w:(a,r,e,t,n)=>{r=L(r);let o=a=>a;if(0===t){var i=32-8*e;o=a=>a<<i>>>i,n=o(n)}H(a,{name:r,sa:o,va:(a,r)=>r,Aa:G(r,e,0!==t),ya:null})},p:(a,r,e)=>{function t(a){return new n(f.buffer,d[a+4>>2],d[a>>2])}var n=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array,BigInt64Array,BigUint64Array][r];H(a,{name:e=L(e),sa:t,Aa:t},{Pb:!0})},t:a=>{H(a,Ra)},k:(a,r,e,t,n,o,i,s,u,f,l,h)=>{e=L(e),o=wa(n,o),s=wa(i,s),f=wa(u,f),h=wa(l,h),N([a],[r],a=>(a=a[0],[new la(e,a.na,!1,!1,!0,a,t,o,s,f,h)]))},aa:(a,r)=>{H(a,{name:r=L(r),sa(a){var r=(r=a+4)?Ia(l,r,d[a>>2],!0):"";return _r(a),r},va(a,r){r instanceof ArrayBuffer&&(r=new Uint8Array(r));var e="string"==typeof r;if(!(e||ArrayBuffer.isView(r)&&1==r.BYTES_PER_ELEMENT))throw new W("Cannot pass non-string to std::string");var t=e?ja(r):r.length,n=Kr(4+t+1),o=n+4;return d[n>>2]=t,e?Sa(r,l,o,t+1):l.set(r,o),null!==a&&a.push(_r,n),n},Aa:B,ya(a){_r(a)}})},A:(a,r,e)=>{if(e=L(e),2===r)var t=Ua,n=za,o=Ma;else t=Fa,n=Na,o=La;H(a,{name:e,sa:a=>{var e=t(a+4,d[a>>2]*r,!0);return _r(a),e},va:(a,t)=>{if("string"!=typeof t)throw new W(`Cannot pass non-string to C++ string type ${e}`);var i=o(t),s=Kr(4+i+r);return d[s>>2]=i/r,n(t,s+4,i+r),null!==a&&a.push(_r,s),s},Aa:B,ya(a){_r(a)}})},s:(a,r,e,t,n,o)=>{q[a]={name:L(r),ob:wa(e,t),Ha:wa(n,o),sb:[]}},l:(a,r,e,t,n,o,i,s,u,f)=>{q[a].sb.push({Jb:L(r),Ob:e,Mb:wa(t,n),Nb:o,Yb:i,Xb:wa(s,u),Zb:f})},ca:(a,r)=>{H(a,{Qb:!0,name:r=L(r),sa:()=>{},va:()=>{}})},I:()=>{j=!1,Wa=0},i:(a,r,e)=>{var[t,...n]=((a,r)=>{for(var e=Array(a),t=0;t<a;++t)e[t]=Ta(d[r+4*t>>2],`parameter ${t}`);return e})(a,r),o=t.va.bind(t),i=n.map(a=>a.Aa.bind(a));a--;var s=Array(a);return r=`methodCaller<(${n.map(a=>a.name)}) => ${t.name}>`,(a=>{var r=Ha.length;return Ha.push(a),r})(Y(r,(r,t,n,u)=>{for(var f=0,l=0;l<a;++l)s[l]=i[l](u+f),f+=8;switch(e){case 0:var h=Ca(r).apply(null,s);break;case 2:h=Reflect.construct(Ca(r),s);break;case 3:h=s[0];break;case 1:h=Ca(r)[Ja(t)](...s)}return h=o(r=[],h),r.length&&(d[n>>2]=Ea(r)),h}))},a:ka,W:a=>a?(a=Ja(a),Ea(globalThis[a])):Ea(globalThis),q:(a,r)=>(a=Ca(a),r=Ca(r),Ea(a[r])),f:a=>{9<a&&(Aa[a+1]+=1)},$:(a,r)=>(a=Ca(a))instanceof Ca(r),j:(a,r,e,t,n)=>Ha[a](r,e,t,n),Z:(a,r,e,t,n)=>Ha[a](r,e,t,n),u:a=>"number"==typeof(a=Ca(a)),x:a=>"string"==typeof(a=Ca(a)),F:()=>Ea([]),o:a=>Ea(Ja(a)),h:a=>{var r=Ca(a);I(r),ka(a)},z:a=>(a=Ca(a),Ea(typeof a)),G:(a,r)=>{if(Br[a]&&(clearTimeout(Br[a].id),delete Br[a]),!r)return 0;var e=setTimeout(()=>{delete Br[a],(a=>{if(!A)try{if(a(),!(j||0<Wa))try{i=a=i,zr(a)}catch(a){Ur(a)}}catch(a){Ur(a)}})(()=>Qr(a,performance.now()))},r);return Br[a]={id:e,tc:r},0},S:(a,r,e,t)=>{var n=(new Date).getFullYear(),o=new Date(n,0,1).getTimezoneOffset();n=new Date(n,6,1).getTimezoneOffset(),d[a>>2]=60*Math.max(o,n),w[r>>2]=Number(o!=n),a=(r=a=>{var r=Math.abs(a);return`UTC${0<=a?"-":"+"}${String(Math.floor(r/60)).padStart(2,"0")}${String(r%60).padStart(2,"0")}`})(o),r=r(n),n<o?(Sa(a,l,e,17),Sa(r,l,t,17)):(Sa(a,l,t,17),Sa(r,l,e,17))},P:function(a,r,e){return 0<=a&&3>=a?(m[e>>3]=BigInt(Math.round(1e6*(0===a?Date.now():performance.now()))),0):28},Y:(a,r,e)=>{Mr.length=0;for(var t;t=l[r++];){var n=105!=t;e+=(n&=112!=t)&&e%8?4:0,Mr.push(112==t?d[e>>2]:106==t?m[e>>3]:105==t?w[e>>2]:p[e>>3]),e+=n?8:4}return ae[a](...Mr)},C:(a,r)=>$(a?Ia(l,a,r):""),y:()=>performance.now(),T:Wr,H:a=>{var r=l.length;if(2147483648<(a>>>=0))return!1;for(var e=1;4>=e;e*=2){var t=r*(1+.2/e);t=Math.min(t,a+100663296);a:{t=(Math.min(2147483648,65536*Math.ceil(Math.max(a,t)/65536))-Yr.buffer.byteLength+65535)/65536|0;try{Yr.grow(t),C();var n=1;break a}catch(a){}n=void 0}if(n)return!0}return!1},X:()=>{var a=Error().stack.toString().split("\n");return"Error"==a[0]&&a.shift(),Lr(a),Fr.ub=Nr(a[3]),Fr.Rb=a,Fr.ub},V:(a,r,e)=>{if(Fr.ub==a)var t=Fr.Rb;else"Error"==(t=Error().stack.toString().split("\n"))[0]&&t.shift(),Lr(t);for(var n=3;t[n]&&Nr(t[n])!=a;)++n;for(a=0;a<e&&t[a+n];++a)w[r+4*a>>2]=Nr(t[a+n]);return a},K:(a,r)=>{var e,t=0,n=0;for(e of Gr()){var o=r+t;d[a+n>>2]=o,t+=Sa(e,l,o,1/0)+1,n+=4}return 0},L:(a,r)=>{var e=Gr();for(var t of(d[a>>2]=e.length,a=0,e))a+=ja(t)+1;return d[r>>2]=a,0},B:a=>{i=a,zr(a)},O:function(a){try{var r=Ar(a);if(null===r.Pa)throw new cr(8);r.kb&&(r.kb=null);try{r.qa.close&&r.qa.close(r)}catch(a){throw a}finally{ir[r.Pa]=null}return r.Pa=null,0}catch(a){if(void 0===Ir||"ErrnoError"!==a.name)throw a;return a.Ta}},N:function(a,r,e,t){try{a:{var n=Ar(a);a=r;for(var o,i=r=0;i<e;i++){var s=d[a>>2],u=d[a+4>>2];a+=8;var l=n,h=s,c=u,w=o,v=f;if(0>c||0>w)throw new cr(28);if(null===l.Pa)throw new cr(8);if(1==(2097155&l.flags))throw new cr(8);if(16384==(61440&l.node.mode))throw new cr(31);if(!l.qa.read)throw new cr(28);var p=void 0!==w;if(p){if(!l.seekable)throw new cr(70)}else w=l.position;var m=l.qa.read(l,v,h,c,w);p||(l.position+=m);var b=m;if(0>b){var y=-1;break a}if(r+=b,b<u)break;void 0!==o&&(o+=b)}y=r}return d[t>>2]=y,0}catch(a){if(void 0===Ir||"ErrnoError"!==a.name)throw a;return a.Ta}},J:function(a,r,e,t){r=-9007199254740992>r||9007199254740992<r?NaN:Number(r);try{if(isNaN(r))return 61;var n=Ar(a);return jr(n,r,e),m[t>>3]=BigInt(n.position),n.kb&&0===r&&0===e&&(n.kb=null),0}catch(a){if(void 0===Ir||"ErrnoError"!==a.name)throw a;return a.Ta}},M:function(a,r,e,t){try{a:{var n=Ar(a);a=r;for(var o,i=r=0;i<e;i++){var s=d[a>>2],u=d[a+4>>2];a+=8;var l=n,h=s,c=u,w=o,v=f;if(0>c||0>w)throw new cr(28);if(null===l.Pa)throw new cr(8);if(!(2097155&l.flags))throw new cr(8);if(16384==(61440&l.node.mode))throw new cr(31);if(!l.qa.write)throw new cr(28);l.seekable&&1024&l.flags&&jr(l,0,2);var p=void 0!==w;if(p){if(!l.seekable)throw new cr(70)}else w=l.position;var m=l.qa.write(l,v,h,c,w,void 0);p||(l.position+=m);var b=m;if(0>b){var y=-1;break a}if(r+=b,b<u)break;void 0!==o&&(o+=b)}y=r}return d[t>>2]=y,0}catch(a){if(void 0===Ir||"ErrnoError"!==a.name)throw a;return a.Ta}},R:zr};return Zr=await async function(){function a(a){return a=Zr=a.exports,Jr=a.ga,Kr=a.ha,_r=a.ia,Vr=a.ka,Qr=a.la,Yr=a.ea,Xr=a.ja,C(),Zr}var r={a:re};return e.instantiateWasm?new Promise(t=>{e.instantiateWasm(r,(r,e)=>{t(a(r))})}):(y??=e.locateFile?e.locateFile?e.locateFile("arcgis-knowledge-client-core.wasm",n):n+"arcgis-knowledge-client-core.wasm":new URL("arcgis-knowledge-client-core.wasm","").href,a((await async function(a){var r=y;if(!o)try{var e=fetch(r,{credentials:"same-origin"});return await WebAssembly.instantiateStreaming(e,a)}catch(a){$(`wasm streaming compile failed: ${a}`),$("falling back to ArrayBuffer instantiation")}return async function(a,r){try{var e=await x(a);return await WebAssembly.instantiate(e,r)}catch(a){$(`failed to asynchronously prepare wasm: ${a}`),E(a)}}(r,a)}(r)).instance))}(),function(){function a(){if(e.calledRun=!0,!A){var a,r;if(k=!0,e.noFSInit||fr||(fr=!0,a??=e.stdin,r??=e.stdout,t??=e.stderr,a?Pr("stdin",a):Rr("/dev/tty","/dev/stdin"),r?Pr("stdout",null,r):Rr("/dev/tty","/dev/stdout"),t?Pr("stderr",null,t):Rr("/dev/tty1","/dev/stderr"),Sr("/dev/stdin",0),Sr("/dev/stdout",1),Sr("/dev/stderr",1)),Zr.fa(),lr=!1,s?.(e),e.onRuntimeInitialized?.(),e.postRun)for("function"==typeof e.postRun&&(e.postRun=[e.postRun]);e.postRun.length;){var t=e.postRun.shift();D.push(t)}T(D)}}if(e.preRun)for("function"==typeof e.preRun&&(e.preRun=[e.preRun]);e.preRun.length;)S();T(R),e.setStatus?(e.setStatus("Running..."),setTimeout(()=>{setTimeout(()=>e.setStatus(""),1),a()},1)):a()}(),k?e:new Promise((a,r)=>{s=a,u=r})}e.d(r,{default:()=>t})}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7214],{29242(t,e,r){function n(){return[1,0,0,0,1,0,0,0,1]}function s(t,e,r,n,s,i,u,o,a){return[t,e,r,n,s,i,u,o,a]}r.d(e,{fA:()=>s,vt:()=>n});const i=[1,0,0,0,1,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:i,clone:function(t){return[t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8]]},create:n,fromValues:s},Symbol.toStringTag,{value:"Module"})),r.d(e,["zK",0,i])},82534(t,e,r){function n(){return[0,0,0,1]}function s(t){return[t[0],t[1],t[2],t[3]]}r.d(e,{o8:()=>s,vt:()=>n});const i=[0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:i,clone:s,create:n,fromValues:function(t,e,r,n){return[t,e,r,n]}},Symbol.toStringTag,{value:"Module"})),r.d(e,["zK",0,i])},48163(t,e,r){function n(){return[0,0]}function s(t){return[t[0],t[1]]}function i(t,e){return[t,e]}function u(){return i(1,1)}function o(){return i(-1,-1)}function a(){return i(1,0)}function c(){return i(0,1)}r.d(e,{fA:()=>i,o8:()=>s,vt:()=>n});const f=u(),l=o(),h=a(),d=c();Object.freeze(Object.defineProperty({__proto__:null,NEGATIVE_ONES:l,ONES:f,UNIT_X:h,UNIT_Y:d,ZEROS:[0,0],clone:s,create:n,freeze:function(t,e){return[t,e]},fromArray:function(t,e=[0,0]){const r=Math.min(2,t.length);for(let n=0;n<r;++n)e[n]=t[n];return e},fromValues:i,negativeOnes:o,ones:u,unitX:a,unitY:c,zeros:function(){return[0,0]}},Symbol.toStringTag,{value:"Module"})),r.d(e,["IA",0,l,"Un",0,f])},51850(t,e,r){function n(){return[0,0,0]}function s(t){return[t[0],t[1],t[2]]}function i(t,e,r){return[t,e,r]}function u(t,e,r){return[t,e,r]}function o(t,e=[0,0,0]){const r=Math.min(3,t.length);for(let n=0;n<r;++n)e[n]=t[n];return e}function a(){return i(1,1,1)}function c(){return i(1,0,0)}function f(){return i(0,1,0)}function l(){return i(0,0,1)}r.d(e,{CN:()=>u,ci:()=>o,fA:()=>i,o8:()=>s,vt:()=>n});const h=[0,0,0],d=a(),p=c(),y=f(),m=l();Object.freeze(Object.defineProperty({__proto__:null,ONES:d,UNIT_X:p,UNIT_Y:y,UNIT_Z:m,ZEROS:h,clone:s,create:n,freeze:u,fromArray:o,fromValues:i,ones:a,unitX:c,unitY:f,unitZ:l,zeros:function(){return[0,0,0]}},Symbol.toStringTag,{value:"Module"})),r.d(e,["Cb",0,m,"Cw",0,p,"JP",0,y,"Un",0,d,"uY",0,h])},91829(t,e,r){function n(){return[0,0,0,0]}function s(t,e,r,n){return[t,e,r,n]}function i(){return s(1,1,1,1)}function u(){return s(1,0,0,0)}function o(){return s(0,1,0,0)}function a(){return s(0,0,1,0)}function c(){return s(0,0,0,1)}r.d(e,{_Y:()=>c,fA:()=>s,vt:()=>n});const f=[0,0,0,0],l=i(),h=u(),d=o(),p=a(),y=c();Object.freeze(Object.defineProperty({__proto__:null,ONES:l,UNIT_W:y,UNIT_X:h,UNIT_Y:d,UNIT_Z:p,ZEROS:f,clone:function(t){return[t[0],t[1],t[2],t[3]]},create:n,freeze:function(t,e,r,n){return[t,e,r,n]},fromArray:function(t,e=[0,0,0,0]){const r=Math.min(4,t.length);for(let n=0;n<r;++n)e[n]=t[n];return e},fromValues:s,ones:i,unitW:c,unitX:u,unitY:o,unitZ:a,zeros:function(){return[0,0,0,0]}},Symbol.toStringTag,{value:"Module"})),r.d(e,["Un",0,l,"uY",0,f])},34304(t,e,r){r.d(e,{DF:()=>a,FD:()=>s,ct:()=>c});let n=1e-6;function s(){return n}const i=Math.random,u=Math.PI/180,o=180/Math.PI;function a(t){return t*u}function c(t){return t*o}Object.freeze(Object.defineProperty({__proto__:null,RANDOM:i,equals:function(t,e){return Math.abs(t-e)<=n*Math.max(1,Math.abs(t),Math.abs(e))},getEpsilon:s,setEpsilon:function(t){n=t},toDegree:c,toRadian:a},Symbol.toStringTag,{value:"Module"})),r.d(e,["Ov",0,i])},77690(t,e,r){r.d(e,{B8:()=>o,Ge:()=>d,I0:()=>h,KC:()=>a,a4:()=>c,hZ:()=>i,hs:()=>l,lw:()=>f,mg:()=>u,z0:()=>s});var n=r(34304);function s(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[4],t[4]=e[5],t[5]=e[6],t[6]=e[8],t[7]=e[9],t[8]=e[10],t}function i(t,e,r,n,s,i,u,o,a,c){return t[0]=e,t[1]=r,t[2]=n,t[3]=s,t[4]=i,t[5]=u,t[6]=o,t[7]=a,t[8]=c,t}function u(t,e){if(t===e){const r=e[1],n=e[2],s=e[5];t[1]=e[3],t[2]=e[6],t[3]=r,t[5]=e[7],t[6]=n,t[7]=s}else t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8];return t}function o(t,e){const r=e[0],n=e[1],s=e[2],i=e[3],u=e[4],o=e[5],a=e[6],c=e[7],f=e[8],l=f*u-o*c,h=-f*i+o*a,d=c*i-u*a;let p=r*l+n*h+s*d;return p?(p=1/p,t[0]=l*p,t[1]=(-f*n+s*c)*p,t[2]=(o*n-s*u)*p,t[3]=h*p,t[4]=(f*r-s*a)*p,t[5]=(-o*r+s*i)*p,t[6]=d*p,t[7]=(-c*r+n*a)*p,t[8]=(u*r-n*i)*p,t):null}function a(t,e){const r=e[0],n=e[1],s=e[2],i=e[3],u=e[4],o=e[5],a=e[6],c=e[7],f=e[8];return t[0]=u*f-o*c,t[1]=s*c-n*f,t[2]=n*o-s*u,t[3]=o*a-i*f,t[4]=r*f-s*a,t[5]=s*i-r*o,t[6]=i*c-u*a,t[7]=n*a-r*c,t[8]=r*u-n*i,t}function c(t){const e=t[0],r=t[1],n=t[2],s=t[3],i=t[4],u=t[5],o=t[6],a=t[7],c=t[8];return e*(c*i-u*a)+r*(-c*s+u*o)+n*(a*s-i*o)}function f(t,e,r){const n=e[0],s=e[1],i=e[2],u=e[3],o=e[4],a=e[5],c=e[6],f=e[7],l=e[8],h=r[0],d=r[1],p=r[2],y=r[3],m=r[4],E=r[5],M=r[6],B=r[7],T=r[8];return t[0]=h*n+d*u+p*c,t[1]=h*s+d*o+p*f,t[2]=h*i+d*a+p*l,t[3]=y*n+m*u+E*c,t[4]=y*s+m*o+E*f,t[5]=y*i+m*a+E*l,t[6]=M*n+B*u+T*c,t[7]=M*s+B*o+T*f,t[8]=M*i+B*a+T*l,t}function l(t,e,r){const n=r[0],s=r[1],i=r[2];return t[0]=n*e[0],t[1]=n*e[1],t[2]=n*e[2],t[3]=s*e[3],t[4]=s*e[4],t[5]=s*e[5],t[6]=i*e[6],t[7]=i*e[7],t[8]=i*e[8],t}function h(t,e){const r=e[0],n=e[1],s=e[2],i=e[3],u=r+r,o=n+n,a=s+s,c=r*u,f=n*u,l=n*o,h=s*u,d=s*o,p=s*a,y=i*u,m=i*o,E=i*a;return t[0]=1-l-p,t[3]=f-E,t[6]=h+m,t[1]=f+E,t[4]=1-c-p,t[7]=d-y,t[2]=h-m,t[5]=d+y,t[8]=1-c-l,t}function d(t,e){const r=e[0],n=e[1],s=e[2],i=e[3],u=e[4],o=e[5],a=e[6],c=e[7],f=e[8],l=e[9],h=e[10],d=e[11],p=e[12],y=e[13],m=e[14],E=e[15],M=r*o-n*u,B=r*a-s*u,T=r*c-i*u,_=n*a-s*o,b=n*c-i*o,S=s*c-i*a,A=f*y-l*p,g=f*m-h*p,v=f*E-d*p,x=l*m-h*y,N=l*E-d*y,R=h*E-d*m;let I=M*R-B*N+T*x+_*v-b*g+S*A;return I?(I=1/I,t[0]=(o*R-a*N+c*x)*I,t[1]=(a*v-u*R-c*g)*I,t[2]=(u*N-o*v+c*A)*I,t[3]=(s*N-n*R-i*x)*I,t[4]=(r*R-s*v+i*g)*I,t[5]=(n*v-r*N-i*A)*I,t[6]=(y*S-m*b+E*_)*I,t[7]=(m*T-p*S-E*B)*I,t[8]=(p*b-y*T+E*M)*I,t):null}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[3]=e[3]-r[3],t[4]=e[4]-r[4],t[5]=e[5]-r[5],t[6]=e[6]-r[6],t[7]=e[7]-r[7],t[8]=e[8]-r[8],t}const y=f,m=p;Object.freeze(Object.defineProperty({__proto__:null,add:function(t,e,r){return t[0]=e[0]+r[0],t[1]=e[1]+r[1],t[2]=e[2]+r[2],t[3]=e[3]+r[3],t[4]=e[4]+r[4],t[5]=e[5]+r[5],t[6]=e[6]+r[6],t[7]=e[7]+r[7],t[8]=e[8]+r[8],t},adjoint:a,copy:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t},determinant:c,equals:function(t,e){const r=t[0],s=t[1],i=t[2],u=t[3],o=t[4],a=t[5],c=t[6],f=t[7],l=t[8],h=e[0],d=e[1],p=e[2],y=e[3],m=e[4],E=e[5],M=e[6],B=e[7],T=e[8],_=(0,n.FD)();return Math.abs(r-h)<=_*Math.max(1,Math.abs(r),Math.abs(h))&&Math.abs(s-d)<=_*Math.max(1,Math.abs(s),Math.abs(d))&&Math.abs(i-p)<=_*Math.max(1,Math.abs(i),Math.abs(p))&&Math.abs(u-y)<=_*Math.max(1,Math.abs(u),Math.abs(y))&&Math.abs(o-m)<=_*Math.max(1,Math.abs(o),Math.abs(m))&&Math.abs(a-E)<=_*Math.max(1,Math.abs(a),Math.abs(E))&&Math.abs(c-M)<=_*Math.max(1,Math.abs(c),Math.abs(M))&&Math.abs(f-B)<=_*Math.max(1,Math.abs(f),Math.abs(B))&&Math.abs(l-T)<=_*Math.max(1,Math.abs(l),Math.abs(T))},exactEquals:function(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]&&t[3]===e[3]&&t[4]===e[4]&&t[5]===e[5]&&t[6]===e[6]&&t[7]===e[7]&&t[8]===e[8]},frob:function(t){return Math.sqrt(t[0]**2+t[1]**2+t[2]**2+t[3]**2+t[4]**2+t[5]**2+t[6]**2+t[7]**2+t[8]**2)},fromMat2d:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=0,t[3]=e[2],t[4]=e[3],t[5]=0,t[6]=e[4],t[7]=e[5],t[8]=1,t},fromMat4:s,fromQuat:h,fromRotation:function(t,e){const r=Math.sin(e),n=Math.cos(e);return t[0]=n,t[1]=r,t[2]=0,t[3]=-r,t[4]=n,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},fromScaling:function(t,e){return t[0]=e[0],t[1]=0,t[2]=0,t[3]=0,t[4]=e[1],t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},fromTranslation:function(t,e){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=e[0],t[7]=e[1],t[8]=1,t},identity:function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},invert:o,isOrthoNormal:function(t){const e=(0,n.FD)(),r=t[0],s=t[1],i=t[2],u=t[3],o=t[4],a=t[5],c=t[6],f=t[7],l=t[8];return Math.abs(1-(r*r+u*u+c*c))<=e&&Math.abs(1-(s*s+o*o+f*f))<=e&&Math.abs(1-(i*i+a*a+l*l))<=e},mul:y,multiply:f,multiplyScalar:function(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t[4]=e[4]*r,t[5]=e[5]*r,t[6]=e[6]*r,t[7]=e[7]*r,t[8]=e[8]*r,t},multiplyScalarAndAdd:function(t,e,r,n){return t[0]=e[0]+r[0]*n,t[1]=e[1]+r[1]*n,t[2]=e[2]+r[2]*n,t[3]=e[3]+r[3]*n,t[4]=e[4]+r[4]*n,t[5]=e[5]+r[5]*n,t[6]=e[6]+r[6]*n,t[7]=e[7]+r[7]*n,t[8]=e[8]+r[8]*n,t},normalFromMat4:d,normalFromMat4Legacy:function(t,e){const r=e[0],n=e[1],s=e[2],i=e[4],u=e[5],o=e[6],a=e[8],c=e[9],f=e[10],l=f*u-o*c,h=-f*i+o*a,d=c*i-u*a,p=r*l+n*h+s*d;if(!p)return null;const y=1/p;return t[0]=l*y,t[1]=(-f*n+s*c)*y,t[2]=(o*n-s*u)*y,t[3]=h*y,t[4]=(f*r-s*a)*y,t[5]=(-o*r+s*i)*y,t[6]=d*y,t[7]=(-c*r+n*a)*y,t[8]=(u*r-n*i)*y,t},projection:function(t,e,r){return t[0]=2/e,t[1]=0,t[2]=0,t[3]=0,t[4]=-2/r,t[5]=0,t[6]=-1,t[7]=1,t[8]=1,t},rotate:function(t,e,r){const n=e[0],s=e[1],i=e[2],u=e[3],o=e[4],a=e[5],c=e[6],f=e[7],l=e[8],h=Math.sin(r),d=Math.cos(r);return t[0]=d*n+h*u,t[1]=d*s+h*o,t[2]=d*i+h*a,t[3]=d*u-h*n,t[4]=d*o-h*s,t[5]=d*a-h*i,t[6]=c,t[7]=f,t[8]=l,t},scale:l,scaleByVec2:function(t,e,r){const n=r[0],s=r[1];return t[0]=n*e[0],t[1]=n*e[1],t[2]=n*e[2],t[3]=s*e[3],t[4]=s*e[4],t[5]=s*e[5],t},set:i,str:function(t){return"mat3("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+")"},sub:m,subtract:p,translate:function(t,e,r){const n=e[0],s=e[1],i=e[2],u=e[3],o=e[4],a=e[5],c=e[6],f=e[7],l=e[8],h=r[0],d=r[1];return t[0]=n,t[1]=s,t[2]=i,t[3]=u,t[4]=o,t[5]=a,t[6]=h*n+d*u+c,t[7]=h*s+d*o+f,t[8]=h*i+d*a+l,t},transpose:u},Symbol.toStringTag,{value:"Module"}))},37585(t,e,r){r.d(e,{C:()=>i,Cc:()=>b,Io:()=>m,LI:()=>d,Ln:()=>y,Om:()=>_,Re:()=>a,S8:()=>T,T9:()=>l,WQ:()=>o,aI:()=>v,e$:()=>A,hG:()=>E,hZ:()=>u,hs:()=>p,l0:()=>S,qE:()=>h,t2:()=>g});var n=r(34727),s=r(34304);function i(t,e){return t[0]=e[0],t[1]=e[1],t}function u(t,e,r){return t[0]=e,t[1]=r,t}function o(t,e,r){return t[0]=e[0]+r[0],t[1]=e[1]+r[1],t}function a(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t}function c(t,e,r){return t[0]=e[0]*r[0],t[1]=e[1]*r[1],t}function f(t,e,r){return t[0]=e[0]/r[0],t[1]=e[1]/r[1],t}function l(t,e,r){return t[0]=Math.max(e[0],r[0]),t[1]=Math.max(e[1],r[1]),t}function h(t,e,r,s){return t[0]=(0,n.qE)(e[0],r[0],s[0]),t[1]=(0,n.qE)(e[1],r[1],s[1]),t}function d(t,e){return t[0]=Math.round(e[0]),t[1]=Math.round(e[1]),t}function p(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t}function y(t,e,r,n){return t[0]=e[0]+r[0]*n,t[1]=e[1]+r[1]*n,t}function m(t,e){const r=e[0]-t[0],n=e[1]-t[1];return Math.sqrt(r*r+n*n)}function E(t,e){const r=e[0]-t[0],n=e[1]-t[1];return r*r+n*n}function M(t){const e=t[0],r=t[1];return Math.sqrt(e*e+r*r)}function B(t){const e=t[0],r=t[1];return e*e+r*r}function T(t,e){const r=e[0],n=e[1];let s=r*r+n*n;return s>0&&(s=1/Math.sqrt(s),t[0]=e[0]*s,t[1]=e[1]*s),t}function _(t,e){return t[0]*e[0]+t[1]*e[1]}function b(t,e,r,n){const s=e[0],i=e[1];return t[0]=s+n*(r[0]-s),t[1]=i+n*(r[1]-i),t}function S(t,e,r){const n=e[0],s=e[1];return t[0]=r[0]*n+r[2]*s+r[4],t[1]=r[1]*n+r[3]*s+r[5],t}function A(t,e,r,n){const s=e[0]-r[0],i=e[1]-r[1],u=Math.sin(n),o=Math.cos(n);return t[0]=s*o-i*u+r[0],t[1]=s*u+i*o+r[1],t}function g(t,e){return t[0]===e[0]&&t[1]===e[1]}function v(t,e){const r=t[0],n=t[1],i=e[0],u=e[1],o=(0,s.FD)();return Math.abs(r-i)<=o*Math.max(1,Math.abs(r),Math.abs(i))&&Math.abs(n-u)<=o*Math.max(1,Math.abs(n),Math.abs(u))}const x=M,N=a,R=c,I=f,O=m,C=E,w=B;Object.freeze(Object.defineProperty({__proto__:null,add:o,angle:function(t,e){const r=t[0],n=t[1],s=e[0],i=e[1];let u=r*r+n*n;u>0&&(u=1/Math.sqrt(u));let o=s*s+i*i;o>0&&(o=1/Math.sqrt(o));const a=(r*s+n*i)*u*o;return a>1?0:a<-1?Math.PI:Math.acos(a)},ceil:function(t,e){return t[0]=Math.ceil(e[0]),t[1]=Math.ceil(e[1]),t},clamp:h,copy:i,cross:function(t,e,r){const n=e[0]*r[1]-e[1]*r[0];return t[0]=t[1]=0,t[2]=n,t},dist:O,distance:m,div:I,divide:f,dot:_,equals:v,exactEquals:g,floor:function(t,e){return t[0]=Math.floor(e[0]),t[1]=Math.floor(e[1]),t},inverse:function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t},len:x,length:M,lerp:b,max:l,min:function(t,e,r){return t[0]=Math.min(e[0],r[0]),t[1]=Math.min(e[1],r[1]),t},mul:R,multiply:c,negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t},normalize:T,projectAndScale:function(t,e,r,n,s){let i=e[0]-r[0],u=e[1]-r[1];const o=(n[0]*i+n[1]*u)*(s-1);return i=n[0]*o,u=n[1]*o,t[0]=e[0]+i,t[1]=e[1]+u,t},random:function(t,e=1){const r=2*(0,s.Ov)()*Math.PI;return t[0]=Math.cos(r)*e,t[1]=Math.sin(r)*e,t},rotate:A,round:d,scale:p,scaleAndAdd:y,set:u,sqrDist:C,sqrLen:w,squaredDistance:E,squaredLength:B,str:function(t){return"vec2("+t[0]+", "+t[1]+")"},sub:N,subtract:a,transformMat2:function(t,e,r){const n=e[0],s=e[1];return t[0]=r[0]*n+r[2]*s,t[1]=r[1]*n+r[3]*s,t},transformMat2d:S,transformMat3:function(t,e,r){const n=e[0],s=e[1];return t[0]=r[0]*n+r[3]*s+r[6],t[1]=r[1]*n+r[4]*s+r[7],t},transformMat4:function(t,e,r){const n=e[0],s=e[1];return t[0]=r[0]*n+r[4]*s+r[12],t[1]=r[1]*n+r[5]*s+r[13],t}},Symbol.toStringTag,{value:"Module"})),r.d(e,["Il",0,x,"jb",0,N,"xg",0,O])},35522(t,e,r){r.d(e,{$A:()=>g,Bw:()=>i,C:()=>u,Cc:()=>v,DI:()=>b,Io:()=>M,Ln:()=>E,Om:()=>A,Qr:()=>l,Re:()=>c,S8:()=>S,T9:()=>y,WQ:()=>a,Z0:()=>x,_S:()=>d,aI:()=>F,ei:()=>N,fw:()=>I,gL:()=>R,hG:()=>B,hZ:()=>o,hs:()=>m,jk:()=>p,lw:()=>f,m3:()=>T,oW:()=>U,t2:()=>w,tn:()=>h,ze:()=>_});var n=r(51850),s=r(34304);function i(t){const e=t[0],r=t[1],n=t[2];return Math.sqrt(e*e+r*r+n*n)}function u(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function o(t,e,r,n){return t[0]=e,t[1]=r,t[2]=n,t}function a(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 f(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 h(t,e){return t[0]=Math.abs(e[0]),t[1]=Math.abs(e[1]),t[2]=Math.abs(e[2]),t}function d(t,e){return t[0]=Math.sign(e[0]),t[1]=Math.sign(e[1]),t[2]=Math.sign(e[2]),t}function p(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 y(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 E(t,e,r,n){return t[0]=e[0]+r[0]*n,t[1]=e[1]+r[1]*n,t[2]=e[2]+r[2]*n,t}function M(t,e){const r=e[0]-t[0],n=e[1]-t[1],s=e[2]-t[2];return Math.sqrt(r*r+n*n+s*s)}function B(t,e){const r=e[0]-t[0],n=e[1]-t[1],s=e[2]-t[2];return r*r+n*n+s*s}function T(t){const e=t[0],r=t[1],n=t[2];return e*e+r*r+n*n}function _(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t}function b(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t}function S(t,e){const r=e[0],n=e[1],s=e[2];let i=r*r+n*n+s*s;return i>0&&(i=1/Math.sqrt(i),t[0]=e[0]*i,t[1]=e[1]*i,t[2]=e[2]*i),t}function A(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function g(t,e,r){const n=e[0],s=e[1],i=e[2],u=r[0],o=r[1],a=r[2];return t[0]=s*a-i*o,t[1]=i*u-n*a,t[2]=n*o-s*u,t}function v(t,e,r,n){const s=e[0],i=e[1],u=e[2];return t[0]=s+n*(r[0]-s),t[1]=i+n*(r[1]-i),t[2]=u+n*(r[2]-u),t}function x(t,e,r){const n=e[0],s=e[1],i=e[2];return t[0]=r[0]*n+r[4]*s+r[8]*i+r[12],t[1]=r[1]*n+r[5]*s+r[9]*i+r[13],t[2]=r[2]*n+r[6]*s+r[10]*i+r[14],t}function N(t,e,r){const n=e[0],s=e[1],i=e[2];return t[0]=n*r[0]+s*r[3]+i*r[6],t[1]=n*r[1]+s*r[4]+i*r[7],t[2]=n*r[2]+s*r[5]+i*r[8],t}function R(t,e,r){return I(t,e,r[0],r[1],r[2],r[3])}function I(t,e,r,n,s,i){const u=e[0],o=e[1],a=e[2],c=n*a-s*o,f=s*u-r*a,l=r*o-n*u,h=n*l-s*f,d=s*c-r*l,p=r*f-n*c,y=2*i;return t[0]=u+c*y+2*h,t[1]=o+f*y+2*d,t[2]=a+l*y+2*p,t}const O=(0,n.vt)(),C=(0,n.vt)();function w(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]}function F(t,e){if(t===e)return!0;const r=t[0],n=t[1],i=t[2],u=e[0],o=e[1],a=e[2],c=(0,s.FD)();return Math.abs(r-u)<=c*Math.max(1,Math.abs(r),Math.abs(u))&&Math.abs(n-o)<=c*Math.max(1,Math.abs(n),Math.abs(o))&&Math.abs(i-a)<=c*Math.max(1,Math.abs(i),Math.abs(a))}function U(t,e,r){const n=r[0]-e[0],s=r[1]-e[1],i=r[2]-e[2];let u=n*n+s*s+i*i;return u>0?(u=1/Math.sqrt(u),t[0]=n*u,t[1]=s*u,t[2]=i*u,t):(t[0]=0,t[1]=0,t[2]=0,t)}const L=c,D=f,G=l,P=M,V=B,q=i,Y=T;Object.freeze(Object.defineProperty({__proto__:null,abs:h,add:a,angle:function(t,e){S(O,t),S(C,e);const r=A(O,C);return r>1?0:r<-1?Math.PI:Math.acos(r)},bezier:function(t,e,r,n,s,i){const u=1-i,o=u*u,a=i*i,c=o*u,f=3*i*o,l=3*a*u,h=a*i;return t[0]=e[0]*c+r[0]*f+n[0]*l+s[0]*h,t[1]=e[1]*c+r[1]*f+n[1]*l+s[1]*h,t[2]=e[2]*c+r[2]*f+n[2]*l+s[2]*h,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:u,cross:g,crossAndNormalize:function(t,e,r){const n=e[0],s=e[1],i=e[2],u=r[0],o=r[1],a=r[2],c=s*a-i*o,f=i*u-n*a,l=n*o-s*u,h=Math.sqrt(c*c+f*f+l*l);return t[0]=c/h,t[1]=f/h,t[2]=l/h,t},direction:U,dist:P,distance:M,div:G,divide:l,dot:A,equals:F,exactEquals:w,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,n,s,i){const u=i*i,o=u*(2*i-3)+1,a=u*(i-2)+i,c=u*(i-1),f=u*(3-2*i);return t[0]=e[0]*o+r[0]*a+n[0]*c+s[0]*f,t[1]=e[1]*o+r[1]*a+n[1]*c+s[1]*f,t[2]=e[2]*o+r[2]*a+n[2]*c+s[2]*f,t},inverse:b,len:q,length:i,lerp:v,max:y,min:p,mul:D,multiply:f,negate:_,normalize:S,random:function(t,e=1){const r=s.Ov,n=2*r()*Math.PI,i=2*r()-1,u=Math.sqrt(1-i*i)*e;return t[0]=Math.cos(n)*u,t[1]=Math.sin(n)*u,t[2]=i*e,t},rotateX:function(t,e,r,n){const s=[],i=[];return s[0]=e[0]-r[0],s[1]=e[1]-r[1],s[2]=e[2]-r[2],i[0]=s[0],i[1]=s[1]*Math.cos(n)-s[2]*Math.sin(n),i[2]=s[1]*Math.sin(n)+s[2]*Math.cos(n),t[0]=i[0]+r[0],t[1]=i[1]+r[1],t[2]=i[2]+r[2],t},rotateY:function(t,e,r,n){const s=[],i=[];return s[0]=e[0]-r[0],s[1]=e[1]-r[1],s[2]=e[2]-r[2],i[0]=s[2]*Math.sin(n)+s[0]*Math.cos(n),i[1]=s[1],i[2]=s[2]*Math.cos(n)-s[0]*Math.sin(n),t[0]=i[0]+r[0],t[1]=i[1]+r[1],t[2]=i[2]+r[2],t},rotateZ:function(t,e,r,n){const s=[],i=[];return s[0]=e[0]-r[0],s[1]=e[1]-r[1],s[2]=e[2]-r[2],i[0]=s[0]*Math.cos(n)-s[1]*Math.sin(n),i[1]=s[0]*Math.sin(n)+s[1]*Math.cos(n),i[2]=s[2],t[0]=i[0]+r[0],t[1]=i[1]+r[1],t[2]=i[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:E,scaleTo:function(t,e){return m(t,t,e/q(t))},set:o,sign:d,sqrDist:V,sqrLen:Y,squaredDistance:B,squaredLength:T,str:function(t){return"vec3("+t[0]+", "+t[1]+", "+t[2]+")"},sub:L,subtract:c,transformMat3:N,transformMat4:x,transformMat4Z:function(t,e){return e[2]*t[0]+e[6]*t[1]+e[10]*t[2]+e[14]},transformQuat:R,transformQuatValues:I},Symbol.toStringTag,{value:"Module"})),r.d(e,["Il",0,q,"jb",0,L,"lo",0,V,"uE",0,Y,"xg",0,P])},78955(t,e,r){r.d(e,{Bw:()=>m,C:()=>s,Cc:()=>T,LI:()=>h,Om:()=>B,S8:()=>M,T9:()=>l,WQ:()=>u,Z0:()=>_,aI:()=>S,hG:()=>y,hZ:()=>i,hs:()=>d,jk:()=>f,m3:()=>E,t2:()=>b});var n=r(34304);function s(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}function i(t,e,r,n,s){return t[0]=e,t[1]=r,t[2]=n,t[3]=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[3]=e[3]+r[3],t}function o(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t[2]=e[2]-r[2],t[3]=e[3]-r[3],t}function a(t,e,r){return t[0]=e[0]*r[0],t[1]=e[1]*r[1],t[2]=e[2]*r[2],t[3]=e[3]*r[3],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[3]=e[3]/r[3],t}function f(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[3]=Math.min(e[3],r[3]),t}function l(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[3]=Math.max(e[3],r[3]),t}function h(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,r){return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t}function p(t,e){const r=e[0]-t[0],n=e[1]-t[1],s=e[2]-t[2],i=e[3]-t[3];return Math.sqrt(r*r+n*n+s*s+i*i)}function y(t,e){const r=e[0]-t[0],n=e[1]-t[1],s=e[2]-t[2],i=e[3]-t[3];return r*r+n*n+s*s+i*i}function m(t){const e=t[0],r=t[1],n=t[2],s=t[3];return Math.sqrt(e*e+r*r+n*n+s*s)}function E(t){const e=t[0],r=t[1],n=t[2],s=t[3];return e*e+r*r+n*n+s*s}function M(t,e){const r=e[0],n=e[1],s=e[2],i=e[3];let u=r*r+n*n+s*s+i*i;return u>0&&(u=1/Math.sqrt(u),t[0]=r*u,t[1]=n*u,t[2]=s*u,t[3]=i*u),t}function B(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]}function T(t,e,r,n){const s=e[0],i=e[1],u=e[2],o=e[3];return t[0]=s+n*(r[0]-s),t[1]=i+n*(r[1]-i),t[2]=u+n*(r[2]-u),t[3]=o+n*(r[3]-o),t}function _(t,e,r){const n=e[0],s=e[1],i=e[2],u=e[3];return t[0]=r[0]*n+r[4]*s+r[8]*i+r[12]*u,t[1]=r[1]*n+r[5]*s+r[9]*i+r[13]*u,t[2]=r[2]*n+r[6]*s+r[10]*i+r[14]*u,t[3]=r[3]*n+r[7]*s+r[11]*i+r[15]*u,t}function b(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]&&t[3]===e[3]}function S(t,e){const r=t[0],s=t[1],i=t[2],u=t[3],o=e[0],a=e[1],c=e[2],f=e[3],l=(0,n.FD)();return Math.abs(r-o)<=l*Math.max(1,Math.abs(r),Math.abs(o))&&Math.abs(s-a)<=l*Math.max(1,Math.abs(s),Math.abs(a))&&Math.abs(i-c)<=l*Math.max(1,Math.abs(i),Math.abs(c))&&Math.abs(u-f)<=l*Math.max(1,Math.abs(u),Math.abs(f))}const A=o,g=a,v=c,x=p,N=y,R=m,I=E;Object.freeze(Object.defineProperty({__proto__:null,add:u,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:s,copyVec3:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t},dist:x,distance:p,div:v,divide:c,dot:B,equals:S,exactEquals:b,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:R,length:m,lerp:T,max:l,min:f,mul:g,multiply:a,negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t[3]=-e[3],t},normalize:M,random:function(t,e=1){const r=n.Ov;let s,i,u,o,a,c;do{s=2*r()-1,i=2*r()-1,a=s*s+i*i}while(a>=1);do{u=2*r()-1,o=2*r()-1,c=u*u+o*o}while(c>=1);const f=Math.sqrt((1-a)/c);return t[0]=e*s,t[1]=e*i,t[2]=e*u*f,t[3]=e*o*f,t},round:h,scale:d,scaleAndAdd:function(t,e,r,n){return t[0]=e[0]+r[0]*n,t[1]=e[1]+r[1]*n,t[2]=e[2]+r[2]*n,t[3]=e[3]+r[3]*n,t},set:i,sqrDist:N,sqrLen:I,squaredDistance:y,squaredLength:E,str:function(t){return"vec4("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+")"},sub:A,subtract:o,transformMat4:_,transformQuat:function(t,e,r){const n=e[0],s=e[1],i=e[2],u=r[0],o=r[1],a=r[2],c=r[3],f=c*n+o*i-a*s,l=c*s+a*n-u*i,h=c*i+u*s-o*n,d=-u*n-o*s-a*i;return t[0]=f*c+d*-u+l*-a-h*-o,t[1]=l*c+d*-o+h*-u-f*-a,t[2]=h*c+d*-a+f*-o-l*-u,t[3]=e[3],t}},Symbol.toStringTag,{value:"Module"}))},34727(t,e,r){r.d(e,{$8:()=>A,Cc:()=>o,Hx:()=>m,Io:()=>b,KJ:()=>f,OS:()=>x,Sp:()=>d,XM:()=>l,YN:()=>h,ZH:()=>y,b6:()=>S,cU:()=>s,gg:()=>p,hs:()=>a,kU:()=>c,mP:()=>u,or:()=>v,pF:()=>R,qE:()=>i});const n=new Float32Array(1);function s(t){--t;for(let e=1;e<32;e<<=1)t|=t>>e;return t+1}function i(t,e,r){return Math.min(Math.max(t,e),r)}function u(t,e){return 0===e?0:Math.ceil(t/e)*e}function o(t,e,r){return t+(e-t)*r}function a(t,e,r,n,s){return o(n,s,(t-e)/(r-e))}function c(t){return t*Math.PI/180}function f(t){return 180*t/Math.PI}function l(t){return Math.acos(i(t,-1,1))}function h(t){return Math.asin(i(t,-1,1))}function d(t,e,r=1e-6){return t===e||!(!Number.isFinite(t)||!Number.isFinite(e))&&(t>e?t-e:e-t)<=r}function p(t,e,r=1e-6){return!d(t,e,r)&&t>e}function y(t,e,r=1e-6){return!d(t,e,r)&&t<e}function m(t,e,r=1e-6){return d(t,e,r)||t>e}const E=new DataView(new ArrayBuffer(Float64Array.BYTES_PER_ELEMENT));function M(t){return E.setFloat64(0,t),E.getBigInt64(0)}const B=1000000n,T=_(1);function _(t){const e=M(t=Math.abs(t)),r=function(t){return E.setBigInt64(0,t),E.getFloat64(0)}(e<=B?B:e-B);return Math.abs(t-r)}function b(t,e,r=T){if(t===e)return!0;if(!Number.isFinite(t)||!Number.isFinite(e))return!1;if(null!=r&&_(Math.min(Math.abs(t),Math.abs(e)))<r)return Math.abs(t-e)<=r;const n=M(t),s=M(e);return n<0==s<0&&!((n<s?s-n:n-s)>B)}function S(t,e,r=1e-6){if(t===e)return!0;if(!Number.isFinite(t)||!Number.isFinite(e))return!1;const n=Math.abs(t-e),s=Math.abs(t),i=Math.abs(e);if(0===t||0===e||s<1e-12&&i<1e-12){if(n>.01*r)return!1}else if(n/(s+i)>r)return!1;return!0}function A(t){return g(Math.max(-N,Math.min(t,N)))}function g(t){return n[0]=t,n[0]}function v(t){const e=t[0]*t[0]+t[1]*t[1]+t[2]*t[2],r=t[3]*t[3]+t[4]*t[4]+t[5]*t[5],n=t[6]*t[6]+t[7]*t[7]+t[8]*t[8];return!(d(e,1)&&d(r,1)&&d(n,1))}function x(t,e){return(t%e+e)%e}const N=g(34028234663852886e22);function R(t,e,r){if(void 0===r||0===+r)return Math[t](e);if(e=+e,r=+r,isNaN(e)||"number"!=typeof r||r%1!=0)return NaN;let n=e.toString().split("e");return n=(e=Math[t](+(n[0]+"e"+(n[1]?+n[1]-r:-r)))).toString().split("e"),+(n[0]+"e"+(n[1]?+n[1]+r:r))}r.d(e,["pq",0,N])},13030(t,e,r){r.d(e,{Y$:()=>M,XW:()=>E,qB:()=>R,Qt:()=>$,My:()=>K,bf:()=>H,jZ:()=>g,j0:()=>v,Sx:()=>x,E$:()=>N,Qy:()=>it,h:()=>D,P:()=>q,SL:()=>w,dy:()=>nt,ES:()=>ut,gH:()=>T,ZD:()=>B,si:()=>I,mJ:()=>Q,UL:()=>tt,D6:()=>X,Yi:()=>G,An:()=>Y,LC:()=>F,xs:()=>b,EC:()=>_,Xm:()=>O,Vp:()=>W,zD:()=>et,m8:()=>Z,nS:()=>P,H$:()=>z,eI:()=>U,td:()=>st,Eq:()=>A,jz:()=>S,Aj:()=>C,E7:()=>J,Y4:()=>rt,TX:()=>k,Uz:()=>V,ml:()=>j,XP:()=>L});var n=r(34727),s=r(37585),i=r(48163),u=r(78955),o=r(91829),a=r(20498);class c{static{this.ElementCount=9}constructor(t,e,r=0,n,s){this.TypedArrayConstructor=t,this.elementCount=9;const i=this.TypedArrayConstructor;void 0===n&&(n=9*i.BYTES_PER_ELEMENT);const u=0===e.byteLength?0:r;this.typedBuffer=null==s?new i(e,u):new i(e,u,(s-r)/i.BYTES_PER_ELEMENT),this.typedBufferStride=n/i.BYTES_PER_ELEMENT,this.count=Math.ceil(this.typedBuffer.length/this.typedBufferStride),this.stride=this.typedBufferStride*this.TypedArrayConstructor.BYTES_PER_ELEMENT}sliceBuffer(t,e,r=this.count-e){const n=this.typedBuffer.byteOffset+e*this.stride;return new t(this.buffer,n,this.stride,n+r*this.stride)}getMat(t,e){let r=t*this.typedBufferStride;for(let t=0;t<9;t++)e[t]=this.typedBuffer[r++];return e}setMat(t,e){let r=t*this.typedBufferStride;for(let t=0;t<9;t++)this.typedBuffer[r++]=e[t]}get(t,e){return this.typedBuffer[t*this.typedBufferStride+e]}set(t,e,r){this.typedBuffer[t*this.typedBufferStride+e]=r}copyFrom(t,e,r){const n=this.typedBuffer,s=e.typedBuffer;let i=t*this.typedBufferStride,u=r*e.typedBufferStride;for(let t=0;t<9;++t)n[i++]=s[u++]}get buffer(){return this.typedBuffer.buffer}}class f{static{this.ElementCount=16}constructor(t,e,r=0,n,s){this.TypedArrayConstructor=t,this.elementCount=16;const i=this.TypedArrayConstructor;void 0===n&&(n=16*i.BYTES_PER_ELEMENT);const u=0===e.byteLength?0:r;this.typedBuffer=null==s?new i(e,u):new i(e,u,(s-r)/i.BYTES_PER_ELEMENT),this.typedBufferStride=n/i.BYTES_PER_ELEMENT,this.count=Math.ceil(this.typedBuffer.length/this.typedBufferStride),this.stride=this.typedBufferStride*this.TypedArrayConstructor.BYTES_PER_ELEMENT}sliceBuffer(t,e,r=this.count-e){const n=this.typedBuffer.byteOffset+e*this.stride;return new t(this.buffer,n,this.stride,n+r*this.stride)}getMat(t,e){let r=t*this.typedBufferStride;for(let t=0;t<16;t++)e[t]=this.typedBuffer[r++];return e}setMat(t,e){let r=t*this.typedBufferStride;for(let t=0;t<16;t++)this.typedBuffer[r++]=e[t]}get(t,e){return this.typedBuffer[t*this.typedBufferStride+e]}set(t,e,r){this.typedBuffer[t*this.typedBufferStride+e]=r}copyFrom(t,e,r){this.copyFromTypedBuffer(t,e.typedBuffer,r*e.typedBufferStride)}copyFromTypedBuffer(t,e,r){const n=this.typedBuffer;let s=t*this.typedBufferStride;for(let t=0;t<16;++t)n[s++]=e[r++]}get buffer(){return this.typedBuffer.buffer}}class l{static{this.ElementCount=1}constructor(t,e,r=0,n,s){this.TypedArrayConstructor=t,this.elementCount=1;const i=this.TypedArrayConstructor;void 0===n&&(n=i.BYTES_PER_ELEMENT);const u=0===e.byteLength?0:r;this.typedBuffer=null==s?new i(e,u):new i(e,u,(s-r)/i.BYTES_PER_ELEMENT),this.stride=n,this.typedBufferStride=n/i.BYTES_PER_ELEMENT,this.count=Math.ceil(this.typedBuffer.length/this.typedBufferStride)}sliceBuffer(t,e,r=this.count-e){const n=this.typedBuffer.byteOffset+e*this.stride;return new t(this.buffer,n,this.stride,n+r*this.stride)}get(t){return this.typedBuffer[t*this.typedBufferStride]}set(t,e){this.typedBuffer[t*this.typedBufferStride]=e}get buffer(){return this.typedBuffer.buffer}}class h{static{this.ElementCount=2}constructor(t,e,r=0,n,s){this.TypedArrayConstructor=t,this.start=r,this.elementCount=2;const i=this.TypedArrayConstructor;void 0===n&&(n=2*i.BYTES_PER_ELEMENT);const u=0===e.byteLength?0:r;this.typedBuffer=null==s?new i(e,u):new i(e,u,(s-r)/i.BYTES_PER_ELEMENT),this.typedBufferStride=n/i.BYTES_PER_ELEMENT,this.count=Math.ceil(this.typedBuffer.length/this.typedBufferStride),this.stride=this.typedBufferStride*this.TypedArrayConstructor.BYTES_PER_ELEMENT}sliceBuffer(t,e,r=this.count-e){const n=this.typedBuffer.byteOffset+e*this.stride;return new t(this.buffer,n,this.stride,n+r*this.stride)}getVec(t,e){return t*=this.typedBufferStride,(0,s.hZ)(e,this.typedBuffer[t],this.typedBuffer[t+1])}setVec(t,e){t*=this.typedBufferStride,this.typedBuffer[t++]=e[0],this.typedBuffer[t]=e[1]}get(t,e){return this.typedBuffer[t*this.typedBufferStride+e]}set(t,e,r){this.typedBuffer[t*this.typedBufferStride+e]=r}setValues(t,e,r){t*=this.typedBufferStride,this.typedBuffer[t++]=e,this.typedBuffer[t]=r}copyFrom(t,e,r){const n=this.typedBuffer,s=e.typedBuffer;let i=t*this.typedBufferStride,u=r*e.typedBufferStride;n[i++]=s[u++],n[i]=s[u]}get buffer(){return this.typedBuffer.buffer}}var d=r(35522);class p{static{this.ElementCount=3}constructor(t,e,r=0,n,s){this.TypedArrayConstructor=t,this.elementCount=3;const i=this.TypedArrayConstructor;void 0===n&&(n=3*i.BYTES_PER_ELEMENT);const u=0===e.byteLength?0:r;this.typedBuffer=null==s?new i(e,u):new i(e,u,(s-r)/i.BYTES_PER_ELEMENT),this.typedBufferStride=n/i.BYTES_PER_ELEMENT,this.count=Math.ceil(this.typedBuffer.length/this.typedBufferStride),this.stride=this.typedBufferStride*this.TypedArrayConstructor.BYTES_PER_ELEMENT}sliceBuffer(t,e,r=this.count-e){const n=this.typedBuffer.byteOffset+e*this.stride;return new t(this.buffer,n,this.stride,n+r*this.stride)}getVec(t,e){return t*=this.typedBufferStride,(0,d.hZ)(e,this.typedBuffer[t],this.typedBuffer[t+1],this.typedBuffer[t+2])}setVec(t,e){t*=this.typedBufferStride,this.typedBuffer[t++]=e[0],this.typedBuffer[t++]=e[1],this.typedBuffer[t]=e[2]}get(t,e){return this.typedBuffer[t*this.typedBufferStride+e]}set(t,e,r){this.typedBuffer[t*this.typedBufferStride+e]=r}setValues(t,e,r,n){t*=this.typedBufferStride,this.typedBuffer[t++]=e,this.typedBuffer[t++]=r,this.typedBuffer[t]=n}copyFrom(t,e,r){const n=this.typedBuffer,s=e.typedBuffer;let i=t*this.typedBufferStride,u=r*e.typedBufferStride;n[i++]=s[u++],n[i++]=s[u++],n[i]=s[u]}get buffer(){return this.typedBuffer.buffer}}class y{static{this.ElementCount=4}constructor(t,e,r=0,n,s){this.TypedArrayConstructor=t,this.start=r,this.elementCount=4;const i=this.TypedArrayConstructor;void 0===n&&(n=4*i.BYTES_PER_ELEMENT);const u=0===e.byteLength?0:r;this.typedBuffer=null==s?new i(e,u):new i(e,u,(s-r)/i.BYTES_PER_ELEMENT),this.typedBufferStride=n/i.BYTES_PER_ELEMENT,this.count=Math.ceil(this.typedBuffer.length/this.typedBufferStride),this.stride=this.typedBufferStride*this.TypedArrayConstructor.BYTES_PER_ELEMENT}sliceBuffer(t,e,r=this.count-e){const n=this.typedBuffer.byteOffset+e*this.stride;return new t(this.buffer,n,this.stride,n+r*this.stride)}getVec(t,e){return t*=this.typedBufferStride,(0,u.hZ)(e,this.typedBuffer[t++],this.typedBuffer[t++],this.typedBuffer[t++],this.typedBuffer[t])}setVec(t,e){t*=this.typedBufferStride,this.typedBuffer[t++]=e[0],this.typedBuffer[t++]=e[1],this.typedBuffer[t++]=e[2],this.typedBuffer[t]=e[3]}get(t,e){return this.typedBuffer[t*this.typedBufferStride+e]}set(t,e,r){this.typedBuffer[t*this.typedBufferStride+e]=r}setValues(t,e,r,n,s){t*=this.typedBufferStride,this.typedBuffer[t++]=e,this.typedBuffer[t++]=r,this.typedBuffer[t++]=n,this.typedBuffer[t]=s}copyFrom(t,e,r){const n=this.typedBuffer,s=e.typedBuffer;let i=t*this.typedBufferStride,u=r*e.typedBufferStride;n[i++]=s[u++],n[i++]=s[u++],n[i++]=s[u++],n[i]=s[u]}get buffer(){return this.typedBuffer.buffer}}var m=r(620);class E extends l{constructor(t,e=0,r,n){(0,m.vA)(a.SX),super((0,a.pX)(),t,e,r,n),this.elementType="f16"}static{this.ElementType="f16"}}class M extends l{constructor(t,e=0,r,n){super(Float32Array,t,e,r,n),this.elementType="f32"}static{this.ElementType="f32"}}class B extends h{constructor(t,e=0,r,n){(0,m.vA)(a.SX),super((0,a.pX)(),t,e,r,n),this.elementType="f16"}slice(t,e){return this.sliceBuffer(B,t,e)}static{this.ElementType="f16"}}class T extends h{constructor(t,e=0,r,n){super(Float32Array,t,e,r,n),this.elementType="f32"}slice(t,e){return this.sliceBuffer(T,t,e)}static{this.ElementType="f32"}}class _ extends p{constructor(t,e=0,r,n){(0,m.vA)(a.SX),super((0,a.pX)(),t,e,r,n),this.elementType="f16"}slice(t,e){return this.sliceBuffer(_,t,e)}static{this.ElementType="f16"}}class b extends p{constructor(t,e=0,r,n){super(Float32Array,t,e,r,n),this.elementType="f32"}slice(t,e){return this.sliceBuffer(b,t,e)}static fromTypedArray(t,e){return new b(t.buffer,t.byteOffset,e,t.byteOffset+t.byteLength)}static{this.ElementType="f32"}}class S extends y{constructor(t,e=0,r,n){(0,m.vA)(a.SX),super((0,a.pX)(),t,e,r,n),this.elementType="f16"}slice(t,e){return this.sliceBuffer(S,t,e)}static{this.ElementType="f16"}}class A extends y{constructor(t,e=0,r,n){super(Float32Array,t,e,r,n),this.elementType="f32"}slice(t,e){return this.sliceBuffer(A,t,e)}static{this.ElementType="f32"}}class g extends c{constructor(t,e=0,r,n){super(Float32Array,t,e,r,n),this.elementType="f32"}slice(t,e){return this.sliceBuffer(g,t,e)}static{this.ElementType="f32"}}class v extends c{constructor(t,e=0,r,n){super(Float64Array,t,e,r,n),this.elementType="f64"}slice(t,e){return this.sliceBuffer(v,t,e)}static{this.ElementType="f64"}}class x extends f{constructor(t,e=0,r,n){super(Float32Array,t,e,r,n),this.elementType="f32"}slice(t,e){return this.sliceBuffer(x,t,e)}static{this.ElementType="f32"}}class N extends f{constructor(t,e=0,r,n){super(Float64Array,t,e,r,n),this.elementType="f64"}slice(t,e){return this.sliceBuffer(N,t,e)}static{this.ElementType="f64"}}class R extends l{constructor(t,e=0,r,n){super(Float64Array,t,e,r,n),this.elementType="f64"}slice(t,e){return this.sliceBuffer(R,t,e)}static{this.ElementType="f64"}}class I extends h{constructor(t,e=0,r,n){super(Float64Array,t,e,r,n),this.elementType="f64"}slice(t,e){return this.sliceBuffer(I,t,e)}static{this.ElementType="f64"}}class O extends p{constructor(t,e=0,r,n){super(Float64Array,t,e,r,n),this.elementType="f64"}slice(t,e){return this.sliceBuffer(O,t,e)}static fromTypedArray(t,e){return new O(t.buffer,t.byteOffset,e,t.byteOffset+t.byteLength)}static{this.ElementType="f64"}}class C extends y{constructor(t,e=0,r,n){super(Float64Array,t,e,r,n),this.elementType="f64"}slice(t,e){return this.sliceBuffer(C,t,e)}static{this.ElementType="f64"}}class w extends l{constructor(t,e=0,r,n){super(Uint8Array,t,e,r,n),this.elementType="u8"}slice(t,e){return this.sliceBuffer(w,t,e)}static{this.ElementType="u8"}}class F extends h{constructor(t,e=0,r,n){super(Uint8Array,t,e,r,n),this.elementType="u8"}slice(t,e){return this.sliceBuffer(F,t,e)}static{this.ElementType="u8"}}class U extends p{constructor(t,e=0,r,n){super(Uint8Array,t,e,r,n),this.elementType="u8"}slice(t,e){return this.sliceBuffer(U,t,e)}static fromTypedArray(t,e){return new U(t.buffer,t.byteOffset,e,t.byteOffset+t.byteLength)}static{this.ElementType="u8"}}class L extends y{constructor(t,e=0,r,n){super(Uint8Array,t,e,r,n),this.elementType="u8"}slice(t,e){return this.sliceBuffer(L,t,e)}static{this.ElementType="u8"}}class D extends l{constructor(t,e=0,r,n){super(Uint16Array,t,e,r,n),this.elementType="u16"}slice(t,e){return this.sliceBuffer(D,t,e)}static{this.ElementType="u16"}}class G extends h{constructor(t,e=0,r,n){super(Uint16Array,t,e,r,n),this.elementType="u16"}slice(t,e){return this.sliceBuffer(G,t,e)}static{this.ElementType="u16"}}class P extends p{constructor(t,e=0,r,n){super(Uint16Array,t,e,r,n),this.elementType="u16"}slice(t,e){return this.sliceBuffer(P,t,e)}static{this.ElementType="u16"}}class V extends y{constructor(t,e=0,r,n){super(Uint16Array,t,e,r,n),this.elementType="u16"}slice(t,e){return this.sliceBuffer(V,t,e)}static{this.ElementType="u16"}}class q extends l{constructor(t,e=0,r,n){super(Uint32Array,t,e,r,n),this.elementType="u32"}slice(t,e){return this.sliceBuffer(q,t,e)}static{this.ElementType="u32"}}class Y extends h{constructor(t,e=0,r,n){super(Uint32Array,t,e,r,n),this.elementType="u32"}slice(t,e){return this.sliceBuffer(Y,t,e)}static{this.ElementType="u32"}}class z extends p{constructor(t,e=0,r,n){super(Uint32Array,t,e,r,n),this.elementType="u32"}slice(t,e){return this.sliceBuffer(z,t,e)}static{this.ElementType="u32"}}class j extends y{constructor(t,e=0,r,n){super(Uint32Array,t,e,r,n),this.elementType="u32"}slice(t,e){return this.sliceBuffer(j,t,e)}static{this.ElementType="u32"}}class H extends l{constructor(t,e=0,r,n){super(Int8Array,t,e,r,n),this.elementType="i8"}slice(t,e){return this.sliceBuffer(H,t,e)}static{this.ElementType="i8"}}class X extends h{constructor(t,e=0,r,n){super(Int8Array,t,e,r,n),this.elementType="i8"}slice(t,e){return this.sliceBuffer(X,t,e)}static{this.ElementType="i8"}}class Z extends p{constructor(t,e=0,r,n){super(Int8Array,t,e,r,n),this.elementType="i8"}slice(t,e){return this.sliceBuffer(Z,t,e)}static{this.ElementType="i8"}}class k extends y{constructor(t,e=0,r,n){super(Int8Array,t,e,r,n),this.elementType="i8"}slice(t,e){return this.sliceBuffer(k,t,e)}static{this.ElementType="i8"}}class $ extends l{constructor(t,e=0,r,n){super(Int16Array,t,e,r,n),this.elementType="i16"}slice(t,e){return this.sliceBuffer($,t,e)}static{this.ElementType="i16"}}class Q extends h{constructor(t,e=0,r,n){super(Int16Array,t,e,r,n),this.elementType="i16"}slice(t,e){return this.sliceBuffer(Q,t,e)}static{this.ElementType="i16"}}class W extends p{constructor(t,e=0,r,n){super(Int16Array,t,e,r,n),this.elementType="i16"}slice(t,e){return this.sliceBuffer(W,t,e)}static{this.ElementType="i16"}}class J extends y{constructor(t,e=0,r,n){super(Int16Array,t,e,r,n),this.elementType="i16"}slice(t,e){return this.sliceBuffer(J,t,e)}static{this.ElementType="i16"}}class K extends l{constructor(t,e=0,r,n){super(Int32Array,t,e,r,n),this.elementType="i32"}slice(t,e){return this.sliceBuffer(K,t,e)}static{this.ElementType="i32"}}class tt extends h{constructor(t,e=0,r,n){super(Int32Array,t,e,r,n),this.elementType="i32"}slice(t,e){return this.sliceBuffer(tt,t,e)}static{this.ElementType="i32"}}class et extends p{constructor(t,e=0,r,n){super(Int32Array,t,e,r,n),this.elementType="i32"}slice(t,e){return this.sliceBuffer(et,t,e)}static{this.ElementType="i32"}}class rt extends y{constructor(t,e=0,r,n){super(Int32Array,t,e,r,n),this.elementType="i32"}slice(t,e){return this.sliceBuffer(rt,t,e)}static{this.ElementType="i32"}}class nt extends w{constructor(t,e=0,r,n){super(t,e,r,n)}get(t){return this.typedBuffer[t*this.typedBufferStride]/255}set(t,e){this.typedBuffer[t*this.typedBufferStride]=Math.round(255*(0,n.qE)(e,0,1))}slice(t,e){return this.sliceBuffer(nt,t,e)}}class st extends L{constructor(t,e=0,r,n){super(t,e,r,n)}getVec(t,e){return(0,u.hs)(e,super.getVec(t,e),1/255)}setVec(t,e){(0,u.jk)(at,(0,u.T9)(at,e,o.uY),o.Un),(0,u.hs)(at,at,255),(0,u.LI)(at,at),super.setVec(t,at)}get(t,e){return super.get(t,e)/255}set(t,e,r){super.set(t,e,Math.round(255*(0,n.qE)(r,0,1)))}setValues(t,e,r,n,s){(0,u.hZ)(at,e,r,n,s),this.setVec(t,at)}slice(t,e){return this.sliceBuffer(st,t,e)}}class it extends ${constructor(t,e=0,r,n){super(t,e,r,n)}get(t){return Math.max(super.get(t)/32767,-1)}set(t,e){super.set(t,Math.round(32767*(0,n.qE)(e,-1,1)))}slice(t,e){return this.sliceBuffer(it,t,e)}}class ut extends Q{constructor(t,e=0,r,n){super(t,e,r,n)}getVec(t,e){return(0,s.hZ)(ot,-1,-1),(0,s.T9)(e,(0,s.hs)(e,super.getVec(t,e),1/32767),ot)}setVec(t,e){(0,s.qE)(ot,e,i.IA,i.Un),(0,s.hs)(ot,ot,32767),(0,s.LI)(ot,ot),super.setVec(t,ot)}get(t,e){return Math.max(super.get(t,e)/32767,-1)}set(t,e,r){super.set(t,e,Math.round(32767*(0,n.qE)(r,-1,1)))}setValues(t,e,r){(0,s.hZ)(ot,e,r),this.setVec(t,ot)}slice(t,e){return this.sliceBuffer(ut,t,e)}}const ot=(0,i.vt)(),at=(0,o.vt)()},90239(t,e,r){function n(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}}r.d(e,{GJ:()=>n})},20498(t,e,r){r.d(e,{SX:()=>i,pX:()=>s});let n=globalThis.Float16Array;function s(){return n}let i=!!n},77214(t,e,r){r.r(e),r.d(e,{destroyContext:()=>b,initialize:()=>B,processVertices:()=>_});var n=r(82534),s=r(51850),i=r(13030),u=r(77690),o=r(29242),a=r(35522),c=r(89606);class f{constructor(t=1/0,e=-1/0){this.minElevation=t,this.maxElevation=e}get elevationRangeValid(){return!Number.isNaN(this.minElevation)}get isEmpty(){return!(this.minElevation<=this.maxElevation)}contains(t){return this.minElevation<=t.minElevation&&this.maxElevation>=t.maxElevation}invalidateElevationRange(){this.minElevation=NaN}initializeEmpty(){this.minElevation=1/0,this.maxElevation=-1/0}expandElevationRange(t){const e=Math.min(this.minElevation,t.minElevation),r=Math.max(this.maxElevation,t.maxElevation),n=e!==this.minElevation||r!==this.maxElevation;return this.minElevation=e,this.maxElevation=r,n}expandElevationRangeValues(t,e){const r=Math.min(this.minElevation,t),n=Math.max(this.maxElevation,e),s=r!==this.minElevation||n!==this.maxElevation;return this.minElevation=r,this.maxElevation=n,s}setElevationRange(t){this.minElevation=t.minElevation,this.maxElevation=t.maxElevation}setElevationRangeValues(t,e){this.minElevation=t,this.maxElevation=e}equals(t){return this.minElevation===t.minElevation&&this.maxElevation===t.maxElevation}}var l=r(1843),h=r(65786);h.Y;class d extends h.Y{constructor(t,e,r){super(),this.hasVertexColors=t,this.hasNormals=e,this.textureCoordinateType=r}}function p(t){const e=(0,l.BP)().vec3f("position");return t.hasNormals&&e.vec2i16("normalCompressed",{glNormalized:!0}),1===t.textureCoordinateType?e.vec2f("uv0"):2===t.textureCoordinateType&&(e.vec2f("uv0"),e.vec4u16("uvRegion",{glNormalized:!0})),t.hasVertexColors&&e.vec4u8("color",{glNormalized:!0}),e.freeze()}function y(t,e,r,n,i,u,o){const a=new Array,l=(0,s.fA)(0,0,0),h=new f,y={origin:e,ellipsoidRadius:r,isGlobal:n,ecefRotation:i};for(const e of t){const{componentIndex:t,positionView:r,indicesView:n,texCoord0Data:s,colorView:i,normalsData:f}=e,E=r.count,M=s?1:0,B=new d(null!=i,null!=f||o,M),T=o&&null==f?(0,c.GN)(n.typedBuffer,r.typedBuffer,r.typedBufferStride):null,_=T?.outputVertexCount??E,b=p(B),S=b.createBuffer(_),A=T?b.fields.get("normalCompressed"):null;if(null!=T&&null==A)throw new Error("computeNormals requires a reserved NORMALCOMPRESSED attribute in layout");let g;if(m(y,{texCoord0Data:s,colorView:i,packedNormalsSource:T?T.packedNormals:f??null},S,{positionView:r,tileObb:u,obbHalfSizeAccumulator:l,elevationRange:h}),null!=T){const t=b.stride/4,e=A.offset/4,r=E,n=new Uint32Array(S.buffer);(0,c.yf)(n,t,e,n,t,r,_,T.appendedVertexToOriginal,T.packedNormals),g=T.indices}else g=n.typedBuffer;a.push({componentIndex:t,positionView:r,indicesView:n,layout:b,textureCoordinateType:M,interleavedVertexData:S.buffer,indices:g})}return{vertexProcessingOutputs:a,obbHalfSizeAccumulator:l,elevationRange:h}}function m(t,e,r,n){const{origin:s,ellipsoidRadius:c,isGlobal:f,ecefRotation:l}=t,{texCoord0Data:h,colorView:d,packedNormalsSource:p}=e,{positionView:y,tileObb:m,obbHalfSizeAccumulator:B,elevationRange:T}=n,_=r.getField("position",i.xs),b=_.typedBuffer,S=_.typedBufferStride,A=null!=h?r.getField("uv0",i.gH):null,g=A?.typedBuffer,v=A?.typedBufferStride??0,x=d?.typedBuffer,N=d?.elementCount??0,R=null!=d?r.getField("color",i.XP):null,I=R?.typedBuffer,O=R?.typedBufferStride??0,C=null!=p?r.getField("normalCompressed",i.mJ):null,w=null!=C?new Uint32Array(C.typedBuffer.buffer,C.typedBuffer.byteOffset,C.typedBuffer.length/2):null,F=null!=C?C.typedBufferStride/2:0,U=(0,u.I0)(M,m.quaternionConjugate),L=(0,a.ei)(E,m.center,U),D=U[0],G=U[1],P=U[2],V=U[3],q=U[4],Y=U[5],z=U[6],j=U[7],H=U[8],X=L[0],Z=L[1],k=L[2],$=l[0],Q=l[1],W=l[2],J=l[3],K=l[4],tt=l[5],et=l[6],rt=l[7],nt=l[8],st=l!==o.zK,it=s[0],ut=s[1],ot=s[2],at=y.count,ct=y.typedBufferStride,ft=y.typedBuffer,lt=null!=g&&null!=h,ht=null!=I&&null!=x&&(3===N||4===N),dt=4===N,pt=null!=w&&null!=p;let yt=B[0],mt=B[1],Et=B[2];for(let t=0;t<at;++t){const e=t*ct,r=ft[e],n=ft[e+1],s=ft[e+2],i=r+it,u=n+ut,o=s+ot,a=f?Math.sqrt(i*i+u*u+o*o)-c:o;T.expandElevationRangeValues(a,a);const l=Math.abs(i*D+u*V+o*z-X),d=Math.abs(i*G+u*q+o*j-Z),y=Math.abs(i*P+u*Y+o*H-k);yt=Math.max(yt,l),mt=Math.max(mt,d),Et=Math.max(Et,y),st&&(ft[e]=r*$+n*J+s*et,ft[e+1]=r*Q+n*K+s*rt,ft[e+2]=r*W+n*tt+s*nt);const m=t*S;if(b[m]=r,b[m+1]=n,b[m+2]=s,lt){const e=2*t,r=t*v;g[r]=h[e],g[r+1]=h[e+1]}if(ht){const e=t*O;if(dt){const r=4*t;I[e]=x[r],I[e+1]=x[r+1],I[e+2]=x[r+2],I[e+3]=x[r+3]}else{const r=3*t;I[e]=x[r],I[e+1]=x[r+1],I[e+2]=x[r+2],I[e+3]=255}}pt&&(w[t*F]=p[t])}B[0]=yt,B[1]=mt,B[2]=Et}const E=(0,s.vt)(),M=(0,o.vt)();function B(){}function T(t){const{colorData:e,colorElementCount:r}=t;if(null==e||0===r)return;const n=e.byteOffset,s=n+e.byteLength;return 3===r?e instanceof Float32Array?new i.xs(e.buffer,n,void 0,s):e instanceof Uint8Array?new i.eI(e.buffer,n,void 0,s):new i.nS(e.buffer,n,void 0,s):e instanceof Float32Array?new i.Eq(e.buffer,n,void 0,s):e instanceof Uint8Array?new i.XP(e.buffer,n,void 0,s):new i.Uz(e.buffer,n,void 0,s)}async function _(t){const e={center:(0,s.o8)(t.tileObbCenter),quaternionConjugate:(0,n.o8)(t.tileObbQuaternionConjugate)},{vertexProcessingOutputs:r,obbHalfSizeAccumulator:u,elevationRange:o}=y(t.inputs.map((t,e)=>{const{indicesData:r}=t,n=t.positionData.byteOffset,s=n+t.positionData.byteLength,u=t.positionStride*Float32Array.BYTES_PER_ELEMENT,o=r.byteOffset,a=o+r.byteLength;return{componentIndex:e,positionView:new i.xs(t.positionData.buffer,n,u,s),indicesView:r instanceof Uint16Array?new i.h(r.buffer,o,void 0,a):new i.P(r.buffer,o,void 0,a),texCoord0Data:t.texCoord0Data??void 0,colorView:T(t),normalsData:t.normalsData??void 0}}),t.origin,t.ellipsoidRadius,t.isGlobal,t.ecefRotation,e,t.imVertexNormals),a=(f=r,l=t.isGlobal,f.map(t=>({positionData:l?t.positionView.typedBuffer:null,interleavedVertexData:t.interleavedVertexData,renderIndices:t.indices===t.indicesView.typedBuffer?null:t.indices}))),c=function(t){const e=[];for(const r of t)null!=r.positionData&&e.push(r.positionData.buffer),e.push(r.interleavedVertexData),null!=r.renderIndices&&e.push(r.renderIndices.buffer);return e}(a);var f,l;return{result:{outputs:a,obbHalfSizeAccumulator:(0,s.o8)(u),minElevation:o.minElevation,maxElevation:o.maxElevation},transferList:c}}function b(t){}},89606(t,e,r){r.d(e,{GN:()=>l,MU:()=>f,yf:()=>d});var n=r(35522),s=r(51850),i=r(10614),u=r(63907),o=r(74038);class a{constructor(t,e){this.data=t,this.indices=e}}class c{constructor(t,e,r,n,s){this.indices=t,this.packedNormals=e,this.appendedVertexToOriginal=r,this.outputVertexCount=n,this.appendedVertexCount=s}}function f(t,e,r,c,f){return!c||r.some(({name:t})=>"normal"===t||"normalCompressed"===t)?function(t,e,r,u){const o=new a(t.slice().buffer,e);if(!u)return o;const c=r[0].stride,f=o.data.byteLength/c;for(const t of r)if("normalCompressed"===t.name){const{offset:e}=t,r=new Int16Array(o.data),a=(0,s.vt)();for(let t=0;t<f;++t)(0,i.Tz)(a,r,t,c/2,e/2),(0,n.ei)(a,a,u),(0,i.aT)(r,t,a[0],a[1],a[2],c/2,e/2)}else if("normal"===t.name){const{offset:e}=t,r=new Float32Array(o.data),i=(0,s.vt)();for(let t=0;t<f;++t){const s=(t*c+e)/4;i[0]=r[s],i[1]=r[s+1],i[2]=r[s+2],(0,n.ei)(i,i,u),r[s]=i[0],r[s+1]=i[1],r[s+2]=i[2]}}return o}(t,e,r,f):function(t,e,r,n){const s=r[0].stride,i=s/4,a=new Float32Array(t.buffer,t.byteOffset,t.byteLength/4),c=t.byteLength/s,f=s+4;r.forEach(t=>t.stride=f),r.push(new o._("normalCompressed",2,u.pe.SHORT,s,f,!0));const d=l(e,a,i,n);return h(a,c,s,f,d)}(t,e,r,f)}function l(t,e,r,n){const s=t.length/3,i=e.length/r,{faceNormals:u,faceAreas:o,faceEdges:a,edgeFaces:c,vertexFaces:f,vertexFaceCountAndOffset:l}=function(t,e,r,n,s,i){const u=new Float32Array(3*s),o=new Float32Array(s),a=new Uint32Array(3*s),c=new Int32Array(3*s*2),f=3*s,l=new Uint32Array(f),h=new Uint32Array(2*r);for(let t=0;t<s;++t){const e=3*t;for(let t=0;t<3;++t)++h[2*n[e+t]]}{let t=0;for(let e=0;e<r;++e){const r=2*e;h[r+1]=t,t+=h[r]}for(let t=0;t<s;++t){const e=3*t;for(let r=0;r<3;++r)l[h[2*n[e+r]+1]++]=t}for(let t=0;t<r;++t)h[2*t+1]-=h[2*t]}let d=0;const p=new Uint32Array(2*f*2),y=new Uint32Array(2*r);for(let t=0;t<r;++t){const e=2*t,r=4*h[e+1];y[e]=r,y[e+1]=r}function m(t,e,r){const n=Math.min(t,e),s=Math.max(t,e),i=t<e?0:1,u=2*n,o=y[u],a=y[u+1];let f=-1;for(let t=o;t<a;t+=2)if(p[t]===s){f=p[t+1];break}return-1===f&&(f=d++,p[a]=s,p[a+1]=f,y[u+1]=a+2,c[2*f+(1-i)]=-1),c[2*f+i]=r,f}for(let r=0;r<n.length;r+=3){const s=n[r],c=s*e,f=t[c],l=t[c+1],h=t[c+2],d=n[r+1],p=d*e,y=t[p],E=t[p+1],M=t[p+2],B=n[r+2],T=B*e,_=f-y,b=l-E,S=h-M,A=f-t[T],g=l-t[T+1],v=h-t[T+2],x=b*v-S*g,N=S*A-_*v,R=_*g-b*A,I=Math.sqrt(x*x+N*N+R*R)||1,O=r/3;o[O]=.5*I;const C=1/I;if(i){const t=i[0]*x+i[3]*N+i[6]*R,e=i[1]*x+i[4]*N+i[7]*R,r=i[2]*x+i[5]*N+i[8]*R;u[3*O]=t*C,u[3*O+1]=e*C,u[3*O+2]=r*C}else u[3*O]=x*C,u[3*O+1]=N*C,u[3*O+2]=R*C;const w=m(s,d,O),F=m(d,B,O),U=m(B,s,O);a[3*O]=w,a[3*O+1]=F,a[3*O+2]=U}return{faceNormals:u,faceAreas:o,faceEdges:a,vertexFaces:l,vertexFaceCountAndOffset:h,edgeFaces:c}}(e,r,i,t,s,n);return function(t,e,r,n,s,i){const u=new Uint8Array(e),o=new Uint32Array(e),a=new Uint32Array(3*e);let c=0;const f=new Uint32Array(e);let l=0;for(let e=0;e<t.length;e+=3){const t=e/3;if(1===u[t])continue;u[t]=1;const h=r[3*t],d=r[3*t+1],p=r[3*t+2];for(l=0,f[l++]=t,a[0]=s[3*t],a[1]=s[3*t+1],a[2]=s[3*t+2],c=3,o[t]=t+1;c>0;){const e=a[--c];for(let n=0;n<2;++n){const m=i[2*e+n];if(-1===m||o[m]===t+1)continue;o[m]=t+1;const E=r[3*m],M=r[3*m+1],B=r[3*m+2];if(Math.abs(1-(h*E+d*M+p*B))<y){f[l++]=m,u[m]=1;for(let t=0;t<3;++t){const r=s[3*m+t];r!==e&&(a[c++]=r)}}}}if(l>1){let t=0,e=0,s=0,i=0;for(let u=0;u<l;++u){const o=f[u],a=n[o];t+=a,e+=r[3*o]*a,s+=r[3*o+1]*a,i+=r[3*o+2]*a}const u=Math.sqrt(e*e+s*s+i*i)||1;e/=u,s/=u,i/=u;for(let u=0;u<l;++u){const o=f[u];r[3*o]=e,r[3*o+1]=s,r[3*o+2]=i,n[o]=t}}}}(t,s,u,o,a,c),p(s,i,t,u,o,f,l)}function h(t,e,r,n,s){const i=r/4,u=n/4,o=s.outputVertexCount,c=new Float32Array(o*u),f=new Uint32Array(c.buffer),l=i,h=new Uint32Array(t.buffer,t.byteOffset,t.length);return function(t,e,r,n,s,i,u){for(let o=0;o<i;++o){const i=o*s,a=o*e;for(let e=0;e<s;++e)t[a+e]=n[i+e];t[a+r]=u[o]}}(f,u,l,h,i,e,s.packedNormals),d(f,u,l,h,i,e,o,s.appendedVertexToOriginal,s.packedNormals),new a(c.buffer,s.indices)}function d(t,e,r,n,s,i,u,o,a){for(let c=i;c<u;++c){const u=o[c-i]*s,f=c*e;for(let e=0;e<s;++e)t[f+e]=n[u+e];t[f+r]=a[c]}}function p(t,e,r,n,s,i,u){const o=3*t,a=new(o<256?Uint8Array:o<65536?Uint16Array:Uint32Array)(r);let f=e;const l=new(e<256?Uint8Array:e<65536?Uint16Array:Uint32Array)(o-e),h=new ArrayBuffer(4*o),d=new Int16Array(h),p=new Uint32Array(h);let y=0,E=0;const M=new Uint32Array(t);let B=0;const T=1-m;for(let t=0;t<e;++t){y=u[2*t+1],E=y+u[2*t];let r=t;for(;y<E;){{const t=i[--E],e=3*t,u=n[e],o=n[e+1],a=n[e+2];B=0,M[B++]=t;let c=y;for(;c<E;){const t=i[c],e=3*t;if(u*n[e]+o*n[e+1]+a*n[e+2]>T){M[B++]=t;const e=--E;if(c<e){i[c]=i[e];continue}}++c}let f=0,l=0,h=0;if(1===B)f=u,l=o,h=a;else{for(let t=0;t<B;++t){const e=M[t],r=s[e],i=3*e;f+=n[i]*r,l+=n[i+1]*r,h+=n[i+2]*r}const t=Math.sqrt(f*f+l*l+h*h)||1;f/=t,l/=t,h/=t}{const t=1/(Math.abs(f)+Math.abs(l)+Math.abs(h)),e=f*t,n=l*t;let s=e,i=n;h<=0&&(s=(e>=0?1:-1)*(1-Math.abs(n)),i=(n>=0?1:-1)*(1-Math.abs(e)));const u=2*r,o=Math.round(32767*s),a=Math.round(32767*i);d[u]=o<-32767?-32767:o>32767?32767:o,d[u+1]=a<-32767?-32767:a>32767?32767:a}}if(r!==t)for(let e=0;e<B;++e){const n=3*M[e];a[n]===t&&(a[n]=r),a[n+1]===t&&(a[n+1]=r),a[n+2]===t&&(a[n+2]=r)}if(y>=E)break;r=f++,l[r-e]=t}}return new c(a,p,l,f,f-e)}const y=.04,m=.8},1843(t,e,r){r.d(e,{BP:()=>l,l5:()=>h});var n=r(20498),s=r(13030),i=r(90239),u=r(4431),o=r(620),a=r(85079);class c{constructor(t,e,r=0){this.layout=t,this.byteOffset=r,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,r+n.offset,this.stride)}}get stride(){return this.layout.stride}get count(){return this.byteLength/this.stride}get byteLength(){return this.buffer.byteLength-this.byteOffset}getField(t,e){const r=this[t];return r&&r.elementCount===e.ElementCount&&r.elementType===e.ElementType?r:null}slice(t,e){return new c(this.layout,this.buffer.slice(t*this.stride,e*this.stride))}copyFrom(t,e=0,r=0,n=t.count){const s=this.stride;if(s%4==0){const i=new Uint32Array(t.buffer,e*s,n*s/4);new Uint32Array(this.buffer,r*s,n*s/4).set(i)}else{const i=new Uint8Array(t.buffer,e*s,n*s);new Uint8Array(this.buffer,r*s,n*s).set(i)}return this}get usedMemory(){return this.byteLength}dispose(){}}class f{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:y(t[1].constructor)})))}freeze(){return this}get locations(){return(0,a.Xk)((0,u.U)(this))}vec2f16(t,e){return this._appendField(t,n.SX?s.ZD:s.gH,e),this}vec2f(t,e){return this._appendField(t,s.gH,e),this}vec2f64(t,e){return this._appendField(t,s.si,e),this}vec3f16(t,e){return this._appendField(t,n.SX?s.EC:s.xs,e),this}vec3f(t,e){return this._appendField(t,s.xs,e),this}vec3f64(t,e){return this._appendField(t,s.Xm,e),this}vec4f16(t,e){return this._appendField(t,n.SX?s.jz:s.Eq,e),this}vec4f(t,e){return this._appendField(t,s.Eq,e),this}vec4f64(t,e){return this._appendField(t,s.Aj,e),this}mat3f(t,e){return this._appendField(t,s.jZ,e),this}mat3f64(t,e){return this._appendField(t,s.j0,e),this}mat4f(t,e){return this._appendField(t,s.Sx,e),this}mat4f64(t,e){return this._appendField(t,s.E$,e),this}vec4u8(t,e){return this._appendField(t,s.XP,e),this}f16(t,e){return this._appendField(t,n.SX?s.XW:s.Y$,e),this}f32(t,e){return this._appendField(t,s.Y$,e),this}f64(t,e){return this._appendField(t,s.qB,e),this}u8(t,e){return this._appendField(t,s.SL,e),this}u16(t,e){return this._appendField(t,s.h,e),this}i8(t,e){return this._appendField(t,s.bf,e),this}vec2i8(t,e){return this._appendField(t,s.D6,e),this}vec2i16(t,e){return this._appendField(t,s.mJ,e),this}vec2u8(t,e){return this._appendField(t,s.LC,e),this}vec2u16(t,e){return this._appendField(t,s.Yi,e),this}vec4u16(t,e){return this._appendField(t,s.Uz,e),this}vec4i16(t,e){return this._appendField(t,s.E7,e),this}u32(t,e){return this._appendField(t,s.P,e),this}_appendField(t,e,r){this._fields.has(t)&&(0,o.vA)(!1,`${t} already added to vertex buffer layout`);const n=e.ElementCount*(0,i.GJ)(e.ElementType),s=this._stride;this._fields.set(t,{constructor:e,size:n,offset:s,optional:r}),this._alignFields()}_alignFields(){let t=0,e=1;this._fields.forEach(r=>{const n=(0,i.GJ)(r.constructor.ElementType);t=Math.floor((t+n-1)/n)*n,r.offset=t,t+=r.size,e=Math.max(e,n)}),t=Math.floor((t+e-1)/e)*e,this._stride=t}createBuffer(t){return new c(this,t)}createView(t,e){return new c(this,t,e)}clone(){const t=new f;return t._stride=this._stride,t._fields=new Map,this._fields.forEach((e,r)=>t._fields.set(r,e)),t.BufferType=this.BufferType,t}get stride(){return this._stride}get fields(){return this._fields}}function l(){return new f}class h{constructor(t){this.fields=new Array,t.fields.forEach((t,e)=>{const r={...t,constructor:p(t.constructor)};this.fields.push([e,r])}),this.stride=t.stride}}const d=[s.Y$,s.gH,s.xs,s.Eq,s.jZ,s.Sx,s.qB,s.si,s.Xm,s.Aj,s.j0,s.E$,s.SL,s.LC,s.eI,s.XP,s.h,s.Yi,s.nS,s.Uz,s.P,s.An,s.H$,s.ml,s.bf,s.D6,s.m8,s.TX,s.Qt,s.mJ,s.Vp,s.E7,s.My,s.UL,s.zD,s.Y4];function p(t){return`${t.ElementType}_${t.ElementCount}`}function y(t){return m.get(t)}const m=new Map;d.forEach(t=>m.set(p(t),t))},4431(t,e,r){r.d(e,{U:()=>i});var n=r(63907),s=r(74038);function i(t,e=0){const r=t.stride;return t.fields.entries().map(([t,i])=>{const u=i.constructor.ElementCount,o=function(t){switch(t){case"u8":return n.pe.UNSIGNED_BYTE;case"u16":return n.pe.UNSIGNED_SHORT;case"u32":return n.pe.UNSIGNED_INT;case"i8":return n.pe.BYTE;case"i16":return n.pe.SHORT;case"i32":return n.pe.INT;case"f16":return n.pe.HALF_FLOAT;case"f32":return n.pe.FLOAT;default:throw new Error("BufferType not supported in WebGL")}}(i.constructor.ElementType),a=i.offset,c=i.optional?.glNormalized??!1,f=i.optional?.integer??!1;return new s._(t,u,o,a,r,c,e,f)}).toArray()}},10614(t,e,r){r.d(e,{Tz:()=>u,aT:()=>i});var n=r(34727),s=r(35522);function i(t,e,r,n,s,i=2,u=0){const a=1/(Math.abs(r)+Math.abs(n)+Math.abs(s)),c=r*a,f=n*a,l=s<=0?(c>=0?1:-1)*(1-Math.abs(f)):c,h=s<=0?(f>=0?1:-1)*(1-Math.abs(c)):f,d=e*i+u;t[d]=o(l),t[d+1]=o(h)}function u(t,e,r,n=2,i=0){const u=r*n+i,o=a(e[u]),c=a(e[u+1]),f=1-Math.abs(o)-Math.abs(c);return t[2]=f,f<0?(t[0]=(o>=0?1:-1)*(1-Math.abs(c)),t[1]=(c>=0?1:-1)*(1-Math.abs(o))):(t[0]=o,t[1]=c),(0,s.S8)(t,t)}function o(t){return(0,n.qE)(Math.round(32767*t),-32767,32767)}function a(t){return(0,n.qE)(t/32767,-1,1)}r(51850)},620(t,e,r){r.d(e,{O_:()=>i,vA:()=>s}),r(48163),r(78955),(0,r(91829).vt)();class n{constructor(t){this.message=t}toString(){return`AssertException: ${this.message}`}}function s(t,e="Assertion"){if(!t){const t=new Error(e).stack;throw new n(`${e} at ${t}`)}}function i(t,e,r,n){let s,i=(r[0]-t[0])/e[0],u=(n[0]-t[0])/e[0];i>u&&(s=i,i=u,u=s);let o=(r[1]-t[1])/e[1],a=(n[1]-t[1])/e[1];if(o>a&&(s=o,o=a,a=s),i>a||o>u)return!1;o>i&&(i=o),a<u&&(u=a);let c=(r[2]-t[2])/e[2],f=(n[2]-t[2])/e[2];return c>f&&(s=c,c=f,f=s),!(i>f||c>u||(f<u&&(u=f),u<0))}},65786(t,e,r){const n=class{};new n,r.d(e,["Y",0,n])},85079(t,e,r){r.d(e,{Sk:()=>u,Xk:()=>s,_u:()=>i});var n=r(21818);function s(t){let e=0;return(0,n.z)(new Map(t.map(({name:t,count:r})=>{const n=[t,e];return 16===r?e+=4:9===r?e+=3:++e,n})))}function i(t){const e=new Map;let r=0;return t.forEach(t=>t.forEach(({name:t,count:n})=>{e.set(t,r),16===n?r+=4:9===n?r+=3:++r})),e}function u(t){return i(Array.from(t.values()).map(({layout:t})=>t))}},74038(t,e,r){r.d(e,{_:()=>n});class n{constructor(t,e,r,n,s,i=!1,u=0,o=!1){this.name=t,this.count=e,this.type=r,this.offset=n,this.stride=s,this.normalized=i,this.divisor=u,this.integer=o}}},63907(t,e,r){const n={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},i=Object.values(s),u={FLOAT:n.FLOAT,UNSIGNED_BYTE:n.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:n.BYTE,UNSIGNED_SHORT:n.UNSIGNED_SHORT,SHORT:n.SHORT,UNSIGNED_INT:n.UNSIGNED_INT,INT:n.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};r.d(e,["CQ",0,{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},"H0",0,s,"SB",0,{DEPTH_COMPONENT16:33189,DEPTH_COMPONENT24:33190,DEPTH_COMPONENT32F:36012},"WR",0,{POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6},"XN",0,i,"iE",0,{DEPTH24_STENCIL8:35056,DEPTH32F_STENCIL8:36013},"ld",0,u,"pe",0,n,"vt",0,{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}])}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5186],{60999(e,t,r){r.d(t,{DZ:()=>f,Ke:()=>p,Tj:()=>c,UT:()=>g,aD:()=>y,jJ:()=>u});var n=r(32198),i=r(69622),s=r(97768),o=r(17676),a=r(10107),l=r(64108);function u(e,t,r){return(0,o.Lx)(e.map((e,n)=>t.apply(r,[e,n])))}async function c(e,t,r){return(await(0,o.Lx)(e.map((e,n)=>t.apply(r,[e,n])))).map(e=>e.value)}function h(e){return{ok:!0,value:e}}function d(e){return{ok:!1,error:e}}async function p(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return h(await e)}catch(e){return d(e)}}async function f(e){try{return h(await e)}catch(e){return(0,o.QP)(e),d(e)}}function g(e,t){return new m(e,t)}let m=class extends i.A{get value(){return null!=(e=this._result)&&!0===e.ok?e.value:null;var e}get error(){return null!=(e=this._result)&&!1===e.ok?e.error:null;var e}get finished(){return null!=this._result}constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,s.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:r}=this._abortController;this.promise=e(r),this.promise.then(e=>{this._result=h(e),this._cleanup()},e=>{this._result=d(e),this._cleanup()}),this._abortHandle=(0,o.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,s.xt)(this._abortHandle),this._abortController=null}};(0,n.Cg)([(0,a.MZ)()],m.prototype,"value",null),(0,n.Cg)([(0,a.MZ)()],m.prototype,"error",null),(0,n.Cg)([(0,a.MZ)()],m.prototype,"finished",null),(0,n.Cg)([(0,a.MZ)()],m.prototype,"promise",void 0),(0,n.Cg)([(0,a.MZ)()],m.prototype,"_result",void 0),m=(0,n.Cg)([(0,l.$)("esri.core.asyncUtils.ReactiveTask")],m);class y{constructor(){this._sequence=Promise.resolve()}async acquire(){let e;this._sequence=new Promise(t=>{e=this._sequence.then(()=>t,()=>t)});const t=await e;return{[Symbol.dispose]:t}}async run(e){const t={stack:[],error:void 0,hasError:!1};try{return(0,n.mS)(t,await this.acquire(),!1),await e()}catch(e){t.error=e,t.hasError=!0}finally{(0,n.hk)(t)}}}},35522(e,t,r){r.d(t,{$A:()=>x,Bw:()=>s,C:()=>o,Cc:()=>I,DI:()=>b,Io:()=>M,Ln:()=>y,Om:()=>A,Qr:()=>h,Re:()=>u,S8:()=>_,T9:()=>g,WQ:()=>l,Z0:()=>C,_S:()=>p,aI:()=>T,ei:()=>E,fw:()=>P,gL:()=>R,hG:()=>v,hZ:()=>a,hs:()=>m,jk:()=>f,lw:()=>c,m3:()=>w,oW:()=>j,t2:()=>k,tn:()=>d,ze:()=>S});var n=r(51850),i=r(34304);function s(e){const t=e[0],r=e[1],n=e[2];return Math.sqrt(t*t+r*r+n*n)}function o(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function a(e,t,r,n){return e[0]=t,e[1]=r,e[2]=n,e}function l(e,t,r){return e[0]=t[0]+r[0],e[1]=t[1]+r[1],e[2]=t[2]+r[2],e}function u(e,t,r){return e[0]=t[0]-r[0],e[1]=t[1]-r[1],e[2]=t[2]-r[2],e}function c(e,t,r){return e[0]=t[0]*r[0],e[1]=t[1]*r[1],e[2]=t[2]*r[2],e}function h(e,t,r){return e[0]=t[0]/r[0],e[1]=t[1]/r[1],e[2]=t[2]/r[2],e}function d(e,t){return e[0]=Math.abs(t[0]),e[1]=Math.abs(t[1]),e[2]=Math.abs(t[2]),e}function p(e,t){return e[0]=Math.sign(t[0]),e[1]=Math.sign(t[1]),e[2]=Math.sign(t[2]),e}function f(e,t,r){return e[0]=Math.min(t[0],r[0]),e[1]=Math.min(t[1],r[1]),e[2]=Math.min(t[2],r[2]),e}function g(e,t,r){return e[0]=Math.max(t[0],r[0]),e[1]=Math.max(t[1],r[1]),e[2]=Math.max(t[2],r[2]),e}function m(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e[2]=t[2]*r,e}function y(e,t,r,n){return e[0]=t[0]+r[0]*n,e[1]=t[1]+r[1]*n,e[2]=t[2]+r[2]*n,e}function M(e,t){const r=t[0]-e[0],n=t[1]-e[1],i=t[2]-e[2];return Math.sqrt(r*r+n*n+i*i)}function v(e,t){const r=t[0]-e[0],n=t[1]-e[1],i=t[2]-e[2];return r*r+n*n+i*i}function w(e){const t=e[0],r=e[1],n=e[2];return t*t+r*r+n*n}function S(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e}function b(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e}function _(e,t){const r=t[0],n=t[1],i=t[2];let s=r*r+n*n+i*i;return s>0&&(s=1/Math.sqrt(s),e[0]=t[0]*s,e[1]=t[1]*s,e[2]=t[2]*s),e}function A(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function x(e,t,r){const n=t[0],i=t[1],s=t[2],o=r[0],a=r[1],l=r[2];return e[0]=i*l-s*a,e[1]=s*o-n*l,e[2]=n*a-i*o,e}function I(e,t,r,n){const i=t[0],s=t[1],o=t[2];return e[0]=i+n*(r[0]-i),e[1]=s+n*(r[1]-s),e[2]=o+n*(r[2]-o),e}function C(e,t,r){const n=t[0],i=t[1],s=t[2];return e[0]=r[0]*n+r[4]*i+r[8]*s+r[12],e[1]=r[1]*n+r[5]*i+r[9]*s+r[13],e[2]=r[2]*n+r[6]*i+r[10]*s+r[14],e}function E(e,t,r){const n=t[0],i=t[1],s=t[2];return e[0]=n*r[0]+i*r[3]+s*r[6],e[1]=n*r[1]+i*r[4]+s*r[7],e[2]=n*r[2]+i*r[5]+s*r[8],e}function R(e,t,r){return P(e,t,r[0],r[1],r[2],r[3])}function P(e,t,r,n,i,s){const o=t[0],a=t[1],l=t[2],u=n*l-i*a,c=i*o-r*l,h=r*a-n*o,d=n*h-i*c,p=i*u-r*h,f=r*c-n*u,g=2*s;return e[0]=o+u*g+2*d,e[1]=a+c*g+2*p,e[2]=l+h*g+2*f,e}const U=(0,n.vt)(),L=(0,n.vt)();function k(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function T(e,t){if(e===t)return!0;const r=e[0],n=e[1],s=e[2],o=t[0],a=t[1],l=t[2],u=(0,i.FD)();return Math.abs(r-o)<=u*Math.max(1,Math.abs(r),Math.abs(o))&&Math.abs(n-a)<=u*Math.max(1,Math.abs(n),Math.abs(a))&&Math.abs(s-l)<=u*Math.max(1,Math.abs(s),Math.abs(l))}function j(e,t,r){const n=r[0]-t[0],i=r[1]-t[1],s=r[2]-t[2];let o=n*n+i*i+s*s;return o>0?(o=1/Math.sqrt(o),e[0]=n*o,e[1]=i*o,e[2]=s*o,e):(e[0]=0,e[1]=0,e[2]=0,e)}const H=u,O=c,W=h,Z=M,$=v,G=s,V=w;Object.freeze(Object.defineProperty({__proto__:null,abs:d,add:l,angle:function(e,t){_(U,e),_(L,t);const r=A(U,L);return r>1?0:r<-1?Math.PI:Math.acos(r)},bezier:function(e,t,r,n,i,s){const o=1-s,a=o*o,l=s*s,u=a*o,c=3*s*a,h=3*l*o,d=l*s;return e[0]=t[0]*u+r[0]*c+n[0]*h+i[0]*d,e[1]=t[1]*u+r[1]*c+n[1]*h+i[1]*d,e[2]=t[2]*u+r[2]*c+n[2]*h+i[2]*d,e},ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e},clamp:function(e,t=0,r=1){return e[0]=Math.min(Math.max(e[0],t),r),e[1]=Math.min(Math.max(e[1],t),r),e[2]=Math.min(Math.max(e[2],t),r),e},copy:o,cross:x,crossAndNormalize:function(e,t,r){const n=t[0],i=t[1],s=t[2],o=r[0],a=r[1],l=r[2],u=i*l-s*a,c=s*o-n*l,h=n*a-i*o,d=Math.sqrt(u*u+c*c+h*h);return e[0]=u/d,e[1]=c/d,e[2]=h/d,e},direction:j,dist:Z,distance:M,div:W,divide:h,dot:A,equals:T,exactEquals:k,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e},hermite:function(e,t,r,n,i,s){const o=s*s,a=o*(2*s-3)+1,l=o*(s-2)+s,u=o*(s-1),c=o*(3-2*s);return e[0]=t[0]*a+r[0]*l+n[0]*u+i[0]*c,e[1]=t[1]*a+r[1]*l+n[1]*u+i[1]*c,e[2]=t[2]*a+r[2]*l+n[2]*u+i[2]*c,e},inverse:b,len:G,length:s,lerp:I,max:g,min:f,mul:O,multiply:c,negate:S,normalize:_,random:function(e,t=1){const r=i.Ov,n=2*r()*Math.PI,s=2*r()-1,o=Math.sqrt(1-s*s)*t;return e[0]=Math.cos(n)*o,e[1]=Math.sin(n)*o,e[2]=s*t,e},rotateX:function(e,t,r,n){const i=[],s=[];return i[0]=t[0]-r[0],i[1]=t[1]-r[1],i[2]=t[2]-r[2],s[0]=i[0],s[1]=i[1]*Math.cos(n)-i[2]*Math.sin(n),s[2]=i[1]*Math.sin(n)+i[2]*Math.cos(n),e[0]=s[0]+r[0],e[1]=s[1]+r[1],e[2]=s[2]+r[2],e},rotateY:function(e,t,r,n){const i=[],s=[];return i[0]=t[0]-r[0],i[1]=t[1]-r[1],i[2]=t[2]-r[2],s[0]=i[2]*Math.sin(n)+i[0]*Math.cos(n),s[1]=i[1],s[2]=i[2]*Math.cos(n)-i[0]*Math.sin(n),e[0]=s[0]+r[0],e[1]=s[1]+r[1],e[2]=s[2]+r[2],e},rotateZ:function(e,t,r,n){const i=[],s=[];return i[0]=t[0]-r[0],i[1]=t[1]-r[1],i[2]=t[2]-r[2],s[0]=i[0]*Math.cos(n)-i[1]*Math.sin(n),s[1]=i[0]*Math.sin(n)+i[1]*Math.cos(n),s[2]=i[2],e[0]=s[0]+r[0],e[1]=s[1]+r[1],e[2]=s[2]+r[2],e},round:function(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e},scale:m,scaleAndAdd:y,scaleTo:function(e,t){return m(e,e,t/G(e))},set:a,sign:p,sqrDist:$,sqrLen:V,squaredDistance:v,squaredLength:w,str:function(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"},sub:H,subtract:u,transformMat3:E,transformMat4:C,transformMat4Z:function(e,t){return t[2]*e[0]+t[6]*e[1]+t[10]*e[2]+t[14]},transformQuat:R,transformQuatValues:P},Symbol.toStringTag,{value:"Module"})),r.d(t,["Il",0,G,"jb",0,H,"lo",0,$,"uE",0,V,"xg",0,Z])},56512(e,t,r){function n(e){let t,r,n=[],i=!1;return function(...s){return i&&t===this&&function(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;++r)if(e[r]!==t[r])return!1;return!0}(s,n)||(r=e.apply(this,s),t=this,n=s,i=!0),r}}r.d(t,{B:()=>n})},54239(e,t,r){r.d(t,{A:()=>y});var n,i=r(32198),s=r(4576),o=r(66552),a=r(25482),l=r(86211),u=r(67076),c=r(91429),h=r(97348),d=r(43937),p=r(36005);const f=(0,o.O)()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),g=f.jsonValues.slice();(0,s.Xy)(g,"orthometric");const m=(0,o.O)()({meter:"meters",foot:"feet","us-foot":"us-feet","clarke-foot":"clarke-feet","clarke-yard":"clarke-yards","clarke-link":"clarke-links","sears-yard":"sears-yards","sears-foot":"sears-feet","sears-chain":"sears-chains","benoit-1895-b-chain":"benoit-1895-b-chains","indian-yard":"indian-yards","indian-1937-yard":"indian-1937-yards","gold-coast-foot":"gold-coast-feet","sears-1922-truncated-chain":"sears-1922-truncated-chains","50-kilometers":"50-kilometers","150-kilometers":"150-kilometers"});let y=n=class extends a.o{constructor(e){super(e),this.heightModel="gravity-related-height",this.heightUnit="meters",this.vertCRS=null}writeHeightModel(e,t,r){return f.write(e,t,r)}readHeightModel(e,t,r){return f.read(e)||(r?.messages&&r.messages.push(function(e,t){return new u.A("height-model:unsupported",`Height model of value '${e}' is not supported`,t)}(e,{context:r})),null)}readHeightUnit(e,t,r){return m.read(e)||(r?.messages&&r.messages.push(M(e,{context:r})),null)}readHeightUnitService(e,t,r){return(0,l.LA)(e)||m.read(e)||(r?.messages&&r.messages.push(M(e,{context:r})),null)}readVertCRS(e,t){return t.vertCRS||t.ellipsoid||t.geoid}clone(){return new n({heightModel:this.heightModel,heightUnit:this.heightUnit,vertCRS:this.vertCRS})}equals(e){return!!e&&(this===e||this.heightModel===e.heightModel&&this.heightUnit===e.heightUnit&&this.vertCRS===e.vertCRS)}static deriveUnitFromSR(e,t){const r=(0,l.k1)(t);return new n({heightModel:e.heightModel,heightUnit:r??void 0,vertCRS:e.vertCRS})}static fromSpatialReference(e){const{latestVcsWkid:t,vcsWkid:r}=e;if(!r)return null;const i=(null!=t?h.B.get(t):null)??h.B.get(r);return i?new n({heightModel:0===i.type?"gravity-related-height":"ellipsoidal",heightUnit:(0,l.LA)(i.unit.name),vertCRS:i.datum}):null}write(e,t){return t={origin:"web-scene",...t},super.write(e,t)}static fromJSON(e){if(!e)return null;const t=new n;return t.read(e,{origin:"web-scene"}),t}};function M(e,t){return new u.A("height-unit:unsupported",`Height unit of value '${e}' is not supported`,t)}(0,i.Cg)([(0,c.MZ)({type:f.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:g,default:"ellipsoidal",write:{isRequired:!0}}}}})],y.prototype,"heightModel",void 0),(0,i.Cg)([(0,d.K)("web-scene","heightModel")],y.prototype,"writeHeightModel",null),(0,i.Cg)([(0,p.w)(["web-scene","service"],"heightModel")],y.prototype,"readHeightModel",null),(0,i.Cg)([(0,c.MZ)({type:m.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:m.jsonValues,write:{writer:m.write,isRequired:!0}}}}})],y.prototype,"heightUnit",void 0),(0,i.Cg)([(0,p.w)("web-scene","heightUnit")],y.prototype,"readHeightUnit",null),(0,i.Cg)([(0,p.w)("service","heightUnit")],y.prototype,"readHeightUnitService",null),(0,i.Cg)([(0,c.MZ)({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],y.prototype,"vertCRS",void 0),(0,i.Cg)([(0,p.w)("service","vertCRS",["vertCRS","ellipsoid","geoid"])],y.prototype,"readVertCRS",null),y=n=(0,i.Cg)([(0,c.$K)("esri.geometry.HeightModelInfo")],y)},18768(e,t,r){var n=r(32198),i=r(53966),s=r(91429),o=r(60694);r.d(t,["b",0,e=>{const t=e;let r=class extends t{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,o.qg)(this.url);if(e?.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,o.Jf)(e,i.A.getLogger(this)))}};return(0,n.Cg)([(0,s.MZ)()],r.prototype,"title",null),(0,n.Cg)([(0,s.MZ)({type:String})],r.prototype,"url",null),r=(0,n.Cg)([(0,s.$K)("esri.layers.mixins.ArcGISService")],r),r}])},69208(e,t,r){var n=r(32198),i=r(91429);r.d(t,["d",0,e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.customParameters=null}};return(0,n.Cg)([(0,i.MZ)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],r.prototype,"customParameters",void 0),r=(0,n.Cg)([(0,i.$K)("esri.layers.mixins.CustomParametersMixin")],r),r}])},8303(e,t,r){var n=r(32198),i=r(92602),s=r(70333),o=r(11254),a=r(60999),l=r(49186),u=r(36563),c=r(53966),h=r(97768),d=r(17676),p=r(84952),f=r(91429),g=r(77548),m=r(20655),y=r(80812),M=r(41318),v=r(10407),w=r(36005),S=r(43937);const b={credential:null,user:null};r.d(t,["A",0,e=>{const t=e;let _=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){super.destroy(),this.portalItem=(0,h.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,r){if(t.itemId)return new y.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:n}=await r.e(1204).then(r.bind(r,41204));return(0,d.Te)(t),await n({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,d.zf)(e)||c.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async reloadFromPortal(e){if(!this.loaded||!this.portalItem?.id)return!1;try{const{reload:t}=await r.e(1204).then(r.bind(r,41204)),n=new AbortController,i=(0,u.rE)(n);return this.addHandles(i,"reloadFromPortal"),await t({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},{signal:n.signal})}catch(e){throw(0,d.zf)(e)||c.A.getLogger(this).warn(`Failed to reload layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}finally{this.removeHandles("reloadFromPortal")}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,d.QP)(e),!0)))}async setUserPrivileges(e,t){if(!i.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:r,fullEdit:n},content:{updateItem:i}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",n),this._set("userHasUpdateItemPrivileges",i)}catch(e){(0,d.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);const n=!s.id?.findCredential(this.url),i=e===r.id;if(i&&r.portal.user)return this._getUserPrivileges(r,n);let o,a;if(i)o=r.portal.url;else try{o=await(0,g.wI)(this.url,t)}catch(e){(0,d.QP)(e)}if(!o||!(0,p.b8)(o,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;a=await(s.id?.getCredential(`${o}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,d.QP)(e)}const l=!0,u=!1,c=!1;if(!a)return{features:{edit:l,fullEdit:u},content:{updateItem:c}};try{if(i?await r.reload():(r=new y.default({id:e,portal:{url:o}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,n)}catch(e){(0,d.QP)(e)}return{features:{edit:l,fullEdit:u},content:{updateItem:c}}}_getUserPrivileges(e,t){const r=(0,v.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,d.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?s.id?.findCredential(this.url):null;if(!t)return!0;const r=b.credential===t?b.user:await this._fetchEditingUser(e);return b.credential=t,b.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const r=s.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;const n=`${r.owningSystemUrl}/sharing/rest`,i=m.A.getDefault();if(i&&i.loaded&&(0,p.S8)(i.restUrl)===(0,p.S8)(n))return i.user;const l=`${n}/community/self`,u=null!=e?e.signal:null,c=await(0,a.Ke)((0,o.A)(l,{authMode:"no-prompt",query:{f:"json"},signal:u}));return c.ok?M.A.fromJSON(c.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const r=t?.portal,n=this.portalItem?.id&&(this.portalItem.portal||m.A.getDefault());return r&&n&&!(0,p.ut)(n.restUrl,r.restUrl)?(t.messages&&t.messages.push(new l.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,n.Cg)([(0,f.MZ)({type:y.default})],_.prototype,"portalItem",null),(0,n.Cg)([(0,w.w)("web-document","portalItem",["itemId"])],_.prototype,"readPortalItem",null),(0,n.Cg)([(0,S.K)("web-document","portalItem",{itemId:{type:String}})],_.prototype,"writePortalItem",null),(0,n.Cg)([(0,f.MZ)({clonable:!1})],_.prototype,"resourceReferences",void 0),(0,n.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],_.prototype,"userHasEditingPrivileges",void 0),(0,n.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],_.prototype,"userHasFullEditingPrivileges",void 0),(0,n.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],_.prototype,"userHasUpdateItemPrivileges",void 0),_=(0,n.Cg)([(0,f.$K)("esri.layers.mixins.PortalLayer")],_),_}])},25036(e,t,r){var n=r(32198),i=r(91429);r.d(t,["j",0,e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.minScale=0,this.maxScale=0}get effectiveScaleRange(){const e={minScale:this.minScale,maxScale:this.maxScale},t=this.parent;void 0!==t?.effectiveScaleRange&&function(e,t){e.minScale=e.minScale>0?t.minScale>0?Math.min(e.minScale,t.minScale):e.minScale:t.minScale,e.maxScale=e.maxScale>0?t.maxScale>0?Math.max(e.maxScale,t.maxScale):e.maxScale:t.maxScale}(e,t.effectiveScaleRange);const r=this._get("effectiveScaleRange");return r&&r.minScale===e.minScale&&r.maxScale===e.maxScale?r:e}};return(0,n.Cg)([(0,i.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],r.prototype,"minScale",void 0),(0,n.Cg)([(0,i.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],r.prototype,"maxScale",void 0),(0,n.Cg)([(0,i.MZ)({readOnly:!0})],r.prototype,"effectiveScaleRange",null),r=(0,n.Cg)([(0,i.$K)("esri.layers.mixins.ScaleRangeLayer")],r),r}])},88546(e,t,r){r.d(t,{_8:()=>m,uB:()=>y});var n=r(34727),i=r(35522),s=r(51850),o=r(73941),a=r(5443),l=r(54239),u=r(16930),c=r(9762);const h=new u.A({wkid:4326,vcsWkid:115700}),d=new a.A(-180,-90,180,90,h);function p(e,t){if(!Array.isArray(e)||e.length<t)return!1;for(const t of e)if("number"!=typeof t)return!1;return!0}const f=7645211,g={xmin:-180,ymin:-90,zmin:-450,xmax:180,ymax:90,zmax:8850};function m(e){return!(!(e.extensions?.ESRI_crs?.wkid||e.extensions?.ESRI_crs?.latestWkid||e.extensions?.ESRI_crs?.wkt)||!e.root?.extensions?.ESRI_crs?.boundingVolume?.box&&!e.root?.extensions?.ESRI_crs?.boundingVolume?.sphere)}function y(e,t=!1){let r=new u.A({wkid:4326,vcsWkid:115700}),l=e.root?.boundingVolume,h=!1,d=e?.root?.transform;if(t&&(e.extensions?.ESRI_crs?.wkid||e.extensions?.ESRI_crs?.latestWkid||e.extensions?.ESRI_crs?.wkt)&&(e.root?.extensions?.ESRI_crs?.boundingVolume?.box||e.root?.extensions?.ESRI_crs?.boundingVolume?.sphere))r=new u.A(e.extensions?.ESRI_crs),l=e.root?.extensions?.ESRI_crs?.boundingVolume,d=e.root?.transform,h=!0;else if(!l)return new a.A(-180,-90,180,90,r);if(l.box){const e=l?.box;if(e[3]>f&&e[7]>f&&e[11]>f)return new a.A({...g,spatialReference:r})}const m=(0,s.vt)();if(!h&&l.region&&p(l.region,6)){const e=l.region,t=(0,n.KJ)(e[0]),i=(0,n.KJ)(e[1]),s=e[4],o=(0,n.KJ)(e[2]),u=(0,n.KJ)(e[3]),c=e[5];return new a.A({xmin:t,ymin:i,zmin:s,xmax:o,ymax:u,zmax:c,spatialReference:r})}if(l.sphere&&p(l.sphere,4)){const e=l.sphere,t=(0,s.fA)(e[0],e[1],e[2]),n=e[3]/Math.sqrt(3),f=(0,s.vt)();(0,i.Re)(f,t,(0,s.fA)(n,n,n));const g=(0,s.vt)();if((0,i.WQ)(g,t,(0,s.fA)(n,n,n)),d&&p(d,16)){const e=d;(0,i.Z0)(m,f,e),(0,i.C)(f,m),(0,i.Z0)(m,g,e),(0,i.C)(g,m)}h||((0,c.projectBuffer)(f,o.Ro,0,f,u.A.WGS84,0),(0,c.projectBuffer)(g,o.Ro,0,g,u.A.WGS84,0));const y=(0,s.vt)(),M=(0,s.vt)();return(0,i.jk)(y,f,g),(0,i.T9)(M,f,g),new a.A({xmin:y[0],ymin:y[1],zmin:y[2],xmax:M[0],ymax:M[1],zmax:M[2],spatialReference:r})}if(l.box&&p(l.box,12)){const e=l.box,t=(0,s.fA)(e[0],e[1],e[2]),n=(0,s.fA)(e[3],e[4],e[5]),f=(0,s.fA)(e[6],e[7],e[8]),g=(0,s.fA)(e[9],e[10],e[11]),m=[];for(let e=0;e<8;++e)m.push((0,s.vt)());if((0,i.WQ)(m[0],t,n),(0,i.WQ)(m[0],m[0],f),(0,i.WQ)(m[0],m[0],g),(0,i.jb)(m[1],t,n),(0,i.WQ)(m[1],m[1],f),(0,i.WQ)(m[1],m[1],g),(0,i.WQ)(m[2],t,n),(0,i.jb)(m[2],m[2],f),(0,i.WQ)(m[2],m[2],g),(0,i.jb)(m[3],t,n),(0,i.jb)(m[3],m[3],f),(0,i.WQ)(m[3],m[3],g),(0,i.WQ)(m[4],t,n),(0,i.WQ)(m[4],m[4],f),(0,i.jb)(m[4],m[4],g),(0,i.jb)(m[5],t,n),(0,i.WQ)(m[5],m[5],f),(0,i.jb)(m[5],m[5],g),(0,i.WQ)(m[6],t,n),(0,i.jb)(m[6],m[6],f),(0,i.jb)(m[6],m[6],g),(0,i.jb)(m[7],t,n),(0,i.jb)(m[7],m[7],f),(0,i.jb)(m[7],m[7],g),d&&p(d,16)){const e=d;for(let t=0;t<8;++t)(0,i.Z0)(m[t],m[t],e)}const y=(0,s.fA)(-Number.MAX_VALUE,-Number.MAX_VALUE,-Number.MAX_VALUE),M=(0,s.fA)(Number.MAX_VALUE,Number.MAX_VALUE,Number.MAX_VALUE);for(let e=0;e<8;++e)h||(0,c.projectBuffer)(m[e],o.Ro,0,m[e],u.A.WGS84,0),(0,i.jk)(M,M,m[e]),(0,i.T9)(y,y,m[e]);return new a.A({xmin:M[0],ymin:M[1],zmin:M[2],xmax:y[0],ymax:y[1],zmax:y[2],spatialReference:r})}return new a.A(-180,-90,180,90,r)}new Map([[5773,new l.A({heightModel:"gravity-related-height",heightUnit:"meters",vertCRS:"EGM96_Geoid"})],[3855,new l.A({heightModel:"gravity-related-height",heightUnit:"meters",vertCRS:"EGM2008_Geoid"})],[115700,new l.A({heightModel:"ellipsoidal",heightUnit:"meters",vertCRS:"WGS_1984"})],[115701,new l.A({heightModel:"ellipsoidal",heightUnit:"meters",vertCRS:"ETRS_1989"})],[6360,new l.A({heightModel:"gravity-related-height",heightUnit:"us-feet",vertCRS:"NAVD88_height_(ftUS)"})],[7837,new l.A({heightModel:"gravity-related-height",heightUnit:"meters",vertCRS:"DHHN2016_(height)"})],[5709,new l.A({heightModel:"gravity-related-height",heightUnit:"meters",vertCRS:"NAP"})]]),r.d(t,["Zx",0,h,"zq",0,d])},10407(e,t,r){r.d(t,{It:()=>p,LG:()=>o,OM:()=>u,Sm:()=>c,Y:()=>a,bK:()=>l,sQ:()=>h});var n=r(99917),i=r(16930),s=r(28735);function o(e,t){if(!a(e,t)){const r=e.typeKeywords;r?r.push(t):e.typeKeywords=[t]}}function a(e,t){return!!e.typeKeywords?.includes(t)}function l(e){return a(e,d.HOSTED_SERVICE)}function u(e,t){const r=e.typeKeywords;if(r){const e=r.indexOf(t);e>-1&&r.splice(e,1)}}function c(e,t,r){r?o(e,t):u(e,t)}async function h(e){const t=e.clone().normalize();let r;if(t.length>1)for(const e of t)r?e.width>r.width&&(r=e):r=e;else r=t[0];return async function(e){const t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,s.ci)(e);const r=i.A.WGS84;return await(0,n.initializeProjection)(t,r),(0,n.project)(e,r)}(r)}const d={CHARTS:"Charts",CATALOG_LAYER:"CatalogLayer",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",PARCEL_FABRIC:"ParcelFabric",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery",UTILITY_NETWORK:"UtilityNetwork"};function p(e){const{portal:t,isOrgItem:r,itemControl:n}=e,i=t.user?.privileges;let s=!i||i.includes("features:user:edit"),o=!!r&&!!i?.includes("features:user:fullEdit");const a="update"===n||"admin"===n;return a?o=s=!0:o&&(s=!0),{features:{edit:s,fullEdit:o},content:{updateItem:a}}}r.d(t,["mm",0,d])},24212(e,t,r){r.d(t,{$7:()=>l,B:()=>a,M7:()=>h,XF:()=>c,tW:()=>u,w7:()=>o});var n=r(56512),i=r(86211),s=r(16271);function o(e,t){return function(e,t){return t?.mode?t.mode:function(e){return e?d:p}(e).mode}(null==e||(e.hasZ??!1),t)}function a(e,t,r){return r&&r.mode!==t?`${e} only support ${t} elevation mode`:null}function l(e,t,r){return r?.mode===t?`${e} do not support ${t} elevation mode`:null}function u(e,t){return null!=t?.featureExpressionInfo&&"0"!==t.featureExpressionInfo.expression?`${e} do not support featureExpressionInfo`:null}function c(e,t){t&&e.warn(".elevationInfo=",t)}function h(e){return(e?.offset??0)*(0,s.Ao)(e?.unit)}(0,n.B)((e,t,r)=>{if(!e)return 0;if("decimal-degrees"===t)return 0;const n="unknown"!==t&&t?t:"meters",s=(0,i.mq)(r);return s?(0,i.oU)(e,n,s):0});const d={mode:"absolute-height",offset:0},p={mode:"on-the-ground",offset:null}},78553(e,t,r){r.d(t,{D:()=>s,p:()=>i});var n=r(56507);function i(e){const t=(0,n.Vr)(100*(1-e));return Math.max(0,Math.min(t,100))}function s(e){const t=1-e/100;return Math.max(0,Math.min(t,1))}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9078],{32198(e,t,n){function r(e,t,n,r){var i,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(o=(s<3?i(o):s>3?i(t,n,o):i(t,n))||o);return s>3&&o&&Object.defineProperty(t,n,o),o}function i(e,t,n){if(null!=t){if("object"!=typeof t&&"function"!=typeof t)throw new TypeError("Object expected.");var r,i;if(n){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(void 0===r){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose],n&&(i=r)}if("function"!=typeof r)throw new TypeError("Object not disposable.");i&&(r=function(){try{i.call(this)}catch(e){return Promise.reject(e)}}),e.stack.push({value:t,dispose:r,async:n})}else n&&e.stack.push({async:!0});return t}n.d(t,{Cg:()=>r,hk:()=>o,mS:()=>i}),Object.create,Object.create;var s="function"==typeof SuppressedError?SuppressedError:function(e,t,n){var r=new Error(n);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};function o(e){function t(t){e.error=e.hasError?new s(t,e.error,"An error was suppressed during disposal."):t,e.hasError=!0}var n,r=0;return function i(){for(;n=e.stack.pop();)try{if(!n.async&&1===r)return r=0,e.stack.push(n),Promise.resolve().then(i);if(n.dispose){var s=n.dispose.call(n.value);if(n.async)return r|=2,Promise.resolve(s).then(i,function(e){return t(e),i()})}else r|=1}catch(e){t(e)}if(1===r)return e.hasError?Promise.reject(e.error):Promise.resolve();if(e.hasError)throw e.error}()}},9093(e,t,n){function r(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function i(e){return[e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15]]}n.d(t,{o8:()=>i,vt:()=>r});const s=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:s,clone:i,create:r,fromValues:function(e,t,n,r,i,s,o,a,u,l,c,h,p,f,d,g){return[e,t,n,r,i,s,o,a,u,l,c,h,p,f,d,g]}},Symbol.toStringTag,{value:"Module"})),n.d(t,["zK",0,s])},51850(e,t,n){function r(){return[0,0,0]}function i(e){return[e[0],e[1],e[2]]}function s(e,t,n){return[e,t,n]}function o(e,t,n){return[e,t,n]}function a(e,t=[0,0,0]){const n=Math.min(3,e.length);for(let r=0;r<n;++r)t[r]=e[r];return t}function u(){return s(1,1,1)}function l(){return s(1,0,0)}function c(){return s(0,1,0)}function h(){return s(0,0,1)}n.d(t,{CN:()=>o,ci:()=>a,fA:()=>s,o8:()=>i,vt:()=>r});const p=[0,0,0],f=u(),d=l(),g=c(),y=h();Object.freeze(Object.defineProperty({__proto__:null,ONES:f,UNIT_X:d,UNIT_Y:g,UNIT_Z:y,ZEROS:p,clone:i,create:r,freeze:o,fromArray:a,fromValues:s,ones:u,unitX:l,unitY:c,unitZ:h,zeros:function(){return[0,0,0]}},Symbol.toStringTag,{value:"Module"})),n.d(t,["Cb",0,y,"Cw",0,d,"JP",0,g,"Un",0,f,"uY",0,p])},35522(e,t,n){n.d(t,{$A:()=>T,Bw:()=>s,C:()=>o,Cc:()=>A,DI:()=>x,Io:()=>_,Ln:()=>m,Om:()=>S,Qr:()=>h,Re:()=>l,S8:()=>w,T9:()=>g,WQ:()=>u,Z0:()=>I,_S:()=>f,aI:()=>N,ei:()=>P,fw:()=>R,gL:()=>k,hG:()=>v,hZ:()=>a,hs:()=>y,jk:()=>d,lw:()=>c,m3:()=>b,oW:()=>F,t2:()=>Z,tn:()=>p,ze:()=>M});var r=n(51850),i=n(34304);function s(e){const t=e[0],n=e[1],r=e[2];return Math.sqrt(t*t+n*n+r*r)}function o(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function a(e,t,n,r){return e[0]=t,e[1]=n,e[2]=r,e}function u(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e[2]=t[2]+n[2],e}function l(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e[2]=t[2]-n[2],e}function c(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e[2]=t[2]*n[2],e}function h(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e[2]=t[2]/n[2],e}function p(e,t){return e[0]=Math.abs(t[0]),e[1]=Math.abs(t[1]),e[2]=Math.abs(t[2]),e}function f(e,t){return e[0]=Math.sign(t[0]),e[1]=Math.sign(t[1]),e[2]=Math.sign(t[2]),e}function d(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e[2]=Math.min(t[2],n[2]),e}function g(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e[2]=Math.max(t[2],n[2]),e}function y(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e}function m(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e[2]=t[2]+n[2]*r,e}function _(e,t){const n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2];return Math.sqrt(n*n+r*r+i*i)}function v(e,t){const n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2];return n*n+r*r+i*i}function b(e){const t=e[0],n=e[1],r=e[2];return t*t+n*n+r*r}function M(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e}function x(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e}function w(e,t){const n=t[0],r=t[1],i=t[2];let s=n*n+r*r+i*i;return s>0&&(s=1/Math.sqrt(s),e[0]=t[0]*s,e[1]=t[1]*s,e[2]=t[2]*s),e}function S(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function T(e,t,n){const r=t[0],i=t[1],s=t[2],o=n[0],a=n[1],u=n[2];return e[0]=i*u-s*a,e[1]=s*o-r*u,e[2]=r*a-i*o,e}function A(e,t,n,r){const i=t[0],s=t[1],o=t[2];return e[0]=i+r*(n[0]-i),e[1]=s+r*(n[1]-s),e[2]=o+r*(n[2]-o),e}function I(e,t,n){const r=t[0],i=t[1],s=t[2];return e[0]=n[0]*r+n[4]*i+n[8]*s+n[12],e[1]=n[1]*r+n[5]*i+n[9]*s+n[13],e[2]=n[2]*r+n[6]*i+n[10]*s+n[14],e}function P(e,t,n){const r=t[0],i=t[1],s=t[2];return e[0]=r*n[0]+i*n[3]+s*n[6],e[1]=r*n[1]+i*n[4]+s*n[7],e[2]=r*n[2]+i*n[5]+s*n[8],e}function k(e,t,n){return R(e,t,n[0],n[1],n[2],n[3])}function R(e,t,n,r,i,s){const o=t[0],a=t[1],u=t[2],l=r*u-i*a,c=i*o-n*u,h=n*a-r*o,p=r*h-i*c,f=i*l-n*h,d=n*c-r*l,g=2*s;return e[0]=o+l*g+2*p,e[1]=a+c*g+2*f,e[2]=u+h*g+2*d,e}const C=(0,r.vt)(),V=(0,r.vt)();function Z(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function N(e,t){if(e===t)return!0;const n=e[0],r=e[1],s=e[2],o=t[0],a=t[1],u=t[2],l=(0,i.FD)();return Math.abs(n-o)<=l*Math.max(1,Math.abs(n),Math.abs(o))&&Math.abs(r-a)<=l*Math.max(1,Math.abs(r),Math.abs(a))&&Math.abs(s-u)<=l*Math.max(1,Math.abs(s),Math.abs(u))}function F(e,t,n){const r=n[0]-t[0],i=n[1]-t[1],s=n[2]-t[2];let o=r*r+i*i+s*s;return o>0?(o=1/Math.sqrt(o),e[0]=r*o,e[1]=i*o,e[2]=s*o,e):(e[0]=0,e[1]=0,e[2]=0,e)}const O=l,q=c,G=h,E=_,D=v,j=s,z=b;Object.freeze(Object.defineProperty({__proto__:null,abs:p,add:u,angle:function(e,t){w(C,e),w(V,t);const n=S(C,V);return n>1?0:n<-1?Math.PI:Math.acos(n)},bezier:function(e,t,n,r,i,s){const o=1-s,a=o*o,u=s*s,l=a*o,c=3*s*a,h=3*u*o,p=u*s;return e[0]=t[0]*l+n[0]*c+r[0]*h+i[0]*p,e[1]=t[1]*l+n[1]*c+r[1]*h+i[1]*p,e[2]=t[2]*l+n[2]*c+r[2]*h+i[2]*p,e},ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e},clamp:function(e,t=0,n=1){return e[0]=Math.min(Math.max(e[0],t),n),e[1]=Math.min(Math.max(e[1],t),n),e[2]=Math.min(Math.max(e[2],t),n),e},copy:o,cross:T,crossAndNormalize:function(e,t,n){const r=t[0],i=t[1],s=t[2],o=n[0],a=n[1],u=n[2],l=i*u-s*a,c=s*o-r*u,h=r*a-i*o,p=Math.sqrt(l*l+c*c+h*h);return e[0]=l/p,e[1]=c/p,e[2]=h/p,e},direction:F,dist:E,distance:_,div:G,divide:h,dot:S,equals:N,exactEquals:Z,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e},hermite:function(e,t,n,r,i,s){const o=s*s,a=o*(2*s-3)+1,u=o*(s-2)+s,l=o*(s-1),c=o*(3-2*s);return e[0]=t[0]*a+n[0]*u+r[0]*l+i[0]*c,e[1]=t[1]*a+n[1]*u+r[1]*l+i[1]*c,e[2]=t[2]*a+n[2]*u+r[2]*l+i[2]*c,e},inverse:x,len:j,length:s,lerp:A,max:g,min:d,mul:q,multiply:c,negate:M,normalize:w,random:function(e,t=1){const n=i.Ov,r=2*n()*Math.PI,s=2*n()-1,o=Math.sqrt(1-s*s)*t;return e[0]=Math.cos(r)*o,e[1]=Math.sin(r)*o,e[2]=s*t,e},rotateX:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[0],s[1]=i[1]*Math.cos(r)-i[2]*Math.sin(r),s[2]=i[1]*Math.sin(r)+i[2]*Math.cos(r),e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},rotateY:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[2]*Math.sin(r)+i[0]*Math.cos(r),s[1]=i[1],s[2]=i[2]*Math.cos(r)-i[0]*Math.sin(r),e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},rotateZ:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[0]*Math.cos(r)-i[1]*Math.sin(r),s[1]=i[0]*Math.sin(r)+i[1]*Math.cos(r),s[2]=i[2],e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},round:function(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e},scale:y,scaleAndAdd:m,scaleTo:function(e,t){return y(e,e,t/j(e))},set:a,sign:f,sqrDist:D,sqrLen:z,squaredDistance:v,squaredLength:b,str:function(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"},sub:O,subtract:l,transformMat3:P,transformMat4:I,transformMat4Z:function(e,t){return t[2]*e[0]+t[6]*e[1]+t[10]*e[2]+t[14]},transformQuat:k,transformQuatValues:R},Symbol.toStringTag,{value:"Module"})),n.d(t,["Il",0,j,"jb",0,O,"lo",0,D,"uE",0,z,"xg",0,E])},69397(e,t,n){n.d(t,{Qf:()=>a,Qh:()=>s,lM:()=>i});var r=n(34275);function i(e){if(!e)return 0;let t=l;for(const n in e)e.hasOwnProperty(n)&&(t+=o(e[n],!1));return t}function s(e){if(!e)return 0;if("number"==typeof e[0])return a(e);if(Array.isArray(e))return function(e){const t=e.length;if(0===t||"number"==typeof e[0])return u(e,8);let n=c;for(let r=0;r<t;r++)n+=o(e[r]);return n}(e);let t=l;for(const n in e)e.hasOwnProperty(n)&&(t+=o(e[n]));return t}function o(e,t=!0){switch(typeof e){case"object":return t?s(e):l;case"string":return function(e){return 32+e.length}(e);case"number":return 16;case"boolean":return 4;default:return 8}}function a(...e){return e.reduce((e,t)=>e+(t?(0,r.iu)(t)?t.byteLength+h:Array.isArray(t)?u(t,16):0:0),0)}function u(e,t){return c+e.length*t}const l=32,c=16,h=145},51624(e,t,n){n.d(t,{A:()=>l});var r=n(44208),i=n(69397),s=n(93687);const o=4294967296,a=new TextDecoder("utf-8"),u=(0,r.A)("safari")||(0,r.A)("ios")?6:(0,r.A)("ff")?12:32;class l{constructor(e,t,n=0,r=e?.byteLength??0){this._tag=0,this._dataType=99,this._init(e,t,n,r)}[Symbol.dispose](){this.release()}_init(e,t,n,r){this._data=e,this._dataView=t,this._pos=n,this._end=r}get usedMemory(){return 64+(0,i.Qf)(this._data)}asUnsafe(){return this}clone(){return new l(this._data,this._dataView,this._pos,this._end)}clonePooled(){return l.constructPooled(this._data,this._dataView,this._pos,this._end)}static constructPooled(e,t,n=0,r=e?.byteLength??0){const i=l.pool.acquire();return i._init(e,t,n,r),i}pos(){return this._pos}move(e){this._pos=e}nextTag(e){for(;;){if(this._pos===this._end)return!1;const t=this._decodeVarint();if(this._tag=t>>3,this._dataType=7&t,!e||e===this._tag)break;this.skip()}return!0}next(){if(this._pos===this._end)return!1;const e=this._decodeVarint();return this._tag=e>>3,this._dataType=7&e,!0}empty(){return this._pos>=this._end}tag(){return this._tag}getInt32(){return this._decodeVarint()}getInt64(){return this._decodeVarint()}getUInt32(){let e=4294967295;if(e=(127&this._data[this._pos])>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<7)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<14)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<21)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(15&this._data[this._pos])<<28)>>>0,this._data[this._pos++]<128)return e;throw new Error("Varint overflow")}getPackedEnd(){const e=this.getUInt32();return this._pos+e}getUInt64(){return this._decodeVarint()}getSInt32(){const e=this.getUInt32();return e>>>1^-(1&e)}getSInt64(){return this._decodeSVarint()}getBool(){const e=0!==this._data[this._pos];return this._skip(1),e}getEnum(){return this._decodeVarint()}getFixed64(){const e=this._dataView,t=this._pos,n=e.getUint32(t,!0)+e.getUint32(t+4,!0)*o;return this._skip(8),n}getSFixed64(){const e=this._dataView,t=this._pos,n=e.getUint32(t,!0)+e.getInt32(t+4,!0)*o;return this._skip(8),n}getDouble(){const e=this._dataView.getFloat64(this._pos,!0);return this._skip(8),e}getFixed32(){const e=this._dataView.getUint32(this._pos,!0);return this._skip(4),e}getSFixed32(){const e=this._dataView.getInt32(this._pos,!0);return this._skip(4),e}getFloat(){const e=this._dataView.getFloat32(this._pos,!0);return this._skip(4),e}getString(){const e=this._getLength(),t=this._pos,n=this._toString(this._data,t,t+e);return this._skip(e),n}getBytes(){const e=this._getLength(),t=this._pos,n=this._toBytes(this._data,t,t+e);return this._skip(e),n}getLength(){return this._getLengthUnsafe()}processMessageWithArgs(e,t,n,r){const i=this.getMessage(),s=e(i,t,n,r);return i.release(),s}processMessage(e){const t=this.getMessage(),n=e(t);return t.release(),n}getMessage(){const e=this._getLength(),t=l.pool.acquire();return t._init(this._data,this._dataView,this._pos,this._pos+e),this._skip(e),t}release(){l.pool.release(this)}dataType(){return this._dataType}skip(){switch(this._dataType){case 0:this._decodeVarint();break;case 1:this._skip(8);break;case 2:this._skip(this._getLength());break;case 5:this._skip(4);break;default:throw new Error("Invalid data type!")}}skipToEnd(){for(;this.next();)this.skip()}skipLen(e){this._skip(e)}_skip(e){if(this._pos+e>this._end)throw new Error("Attempt to skip past the end of buffer!");this._pos+=e}_decodeVarint(){const e=this._data;let t=this._pos,n=0,r=0;if(this._end-t>=10)do{if(r=e[t++],n|=127&r,!(128&r))break;if(r=e[t++],n|=(127&r)<<7,!(128&r))break;if(r=e[t++],n|=(127&r)<<14,!(128&r))break;if(r=e[t++],n|=(127&r)<<21,!(128&r))break;if(r=e[t++],n+=268435456*(127&r),!(128&r))break;if(r=e[t++],n+=34359738368*(127&r),!(128&r))break;if(r=e[t++],n+=4398046511104*(127&r),!(128&r))break;if(r=e[t++],n+=562949953421312*(127&r),!(128&r))break;if(r=e[t++],n+=72057594037927940*(127&r),!(128&r))break;if(r=e[t++],n+=0x8000000000000000*(127&r),!(128&r))break;throw new Error("Varint too long!")}while(0);else{let i=1;for(;t!==this._end&&(r=e[t],128&r);)++t,n+=(127&r)*i,i*=128;if(t===this._end)throw new Error("Varint overrun!");++t,n+=r*i}return this._pos=t,n}_decodeSVarint(){const e=this._data;let t,n=0,r=0;const i=1&e[this._pos];if(r=e[this._pos++],n|=127&r,!(128&r))return i?-(n+1)/2:n/2;if(r=e[this._pos++],n|=(127&r)<<7,!(128&r))return i?-(n+1)/2:n/2;if(r=e[this._pos++],n|=(127&r)<<14,!(128&r))return i?-(n+1)/2:n/2;if(r=e[this._pos++],n|=(127&r)<<21,!(128&r))return i?-(n+1)/2:n/2;if(r=e[this._pos++],n+=268435456*(127&r),!(128&r))return i?-(n+1)/2:n/2;if(r=e[this._pos++],n+=34359738368*(127&r),!(128&r))return i?-(n+1)/2:n/2;if(r=e[this._pos++],n+=4398046511104*(127&r),!(128&r))return i?-(n+1)/2:n/2;if(t=BigInt(n),r=e[this._pos++],t+=0x2000000000000n*BigInt(127&r),!(128&r))return Number(i?-(t+1n)/2n:t/2n);if(r=e[this._pos++],t+=0x100000000000000n*BigInt(127&r),!(128&r))return Number(i?-(t+1n)/2n:t/2n);if(r=e[this._pos++],t+=0x8000000000000000n*BigInt(127&r),!(128&r))return Number(i?-(t+1n)/2n:t/2n);throw new Error("Varint too long!")}_getLength(){if(2!==this._dataType)throw new Error("Not a delimited data type!");return this._decodeVarint()}_getLengthUnsafe(){return this.getUInt32()}_toString(e,t,n){if((n=Math.min(this._end,n))-t>u){const r=e.subarray(t,n);return a.decode(r)}let r="",i="";for(let s=t;s<n;++s){const t=e[s];128&t?i+="%"+t.toString(16):(r+=decodeURIComponent(i)+String.fromCharCode(t),i="")}return i.length&&(r+=decodeURIComponent(i)),r}_toBytes(e,t,n){return n=Math.min(this._end,n),new Uint8Array(e.buffer,t,n-t)}static{this.pool=new s.A(()=>new l(null,null),void 0,e=>{e._data=null,e._dataView=null})}}},48526(e,t,n){n.d(t,{A:()=>y});var r,i=n(32198),s=n(4576),o=n(4718),a=n(91429),u=n(5443),l=n(91075),c=n(86738),h=n(16930),p=n(90634),f=n(47610),d=n(56993),g=n(43937);let y=r=class extends l.A{constructor(e){super(function(e){if(!e)return;let{points:t,hasM:n,hasZ:r,spatialReference:i}=e;switch(t??=[],t?.at(0)?.length){case 4:r??=!0,n??=!0;break;case 3:r??=!0!==n,n??=!r;break;default:r??=!1,n??=!1}return i??=h.A.WGS84,{...e,hasM:n,hasZ:r,points:t,spatialReference:i}}(e)),this.points=[],this.type="multipoint"}get cache(){return this.commitProperty("points"),this.commitProperty("hasZ"),this.commitProperty("hasM"),this.commitProperty("spatialReference"),{}}get extent(){const e=(0,p.ge)(this);return e?new u.A({...e,spatialReference:this.spatialReference}):null}writePoints(e,t){t.points=(0,o.o8)(this.points)}clone(){const{points:e,spatialReference:t,hasM:n,hasZ:i}=this;return new r({points:(0,o.o8)(e),spatialReference:t.clone(),hasM:n,hasZ:i})}equals(e){if(this===e)return!0;if(null==e)return!1;const t=this.spatialReference,n=e.spatialReference;return null!=t==(null!=n)&&!(null!=t&&null!=n&&!t.equals(n))&&(0,s.aI)(this.points,e.points,f.v6)}addPoint(e){return(0,d.h)(this,e),Array.isArray(e)?this.points.push(e):this.points.push(e.toArray()),this.notifyChange("points"),this}getPoint(e){if(!this._validateInputs(e))return null;const t=this.points[e],n={x:t[0],y:t[1],spatialReference:this.spatialReference};let r=2;return this.hasZ&&(n.z=t[2],r=3),this.hasM&&(n.m=t[r]),new c.A(n)}removePoint(e){if(!this._validateInputs(e))return null;const t=new c.A(this.points.splice(e,1)[0],this.spatialReference);return this.notifyChange("points"),t}setPoint(e,t){return this._validateInputs(e)?((0,d.h)(this,t),Array.isArray(t)||(t=t.toArray()),this.points[e]=t,this.notifyChange("points"),this):this}toJSON(e){return this.write({},e)}_validateInputs(e){return null!=e&&e>=0&&e<this.points.length}};(0,i.Cg)([(0,a.MZ)({readOnly:!0})],y.prototype,"cache",null),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],y.prototype,"extent",null),(0,i.Cg)([(0,a.MZ)({type:[[Number]],json:{write:{isRequired:!0}}})],y.prototype,"points",void 0),(0,i.Cg)([(0,g.K)("points")],y.prototype,"writePoints",null),y=r=(0,i.Cg)([(0,a.$K)("esri.geometry.Multipoint")],y),y.prototype.toJSON.isDefaultToJSON=!0},39829(e,t,n){n.d(t,{A:()=>w});var r,i=n(32198),s=n(4576),o=n(51447),a=n(4718),u=n(53966),l=n(91429),c=n(5443),h=n(91075),p=n(86738),f=n(16930),d=n(12359),g=n(94078),y=n(95108),m=n(90634),_=n(47610),v=n(28735),b=n(56993),M=n(43937);function x(e){return!Array.isArray(e[0])}let w=r=class extends h.A{static fromExtent(e){const t=e.clone().normalize(),{spatialReference:n}=e;let i=!1,s=!1;for(const e of t)e.hasZ&&(i=!0),e.hasM&&(s=!0);const o={rings:t.map(e=>{const t=[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]];if(i&&e.hasZ){const n=e.zmin+.5*(e.zmax-e.zmin);for(let e=0;e<t.length;e++)t[e].push(n)}if(s&&e.hasM){const n=e.mmin+.5*(e.mmax-e.mmin);for(let e=0;e<t.length;e++)t[e].push(n)}return t}),spatialReference:n};return i&&(o.hasZ=!0),s&&(o.hasM=!0),new r(o)}constructor(e){super(function(e){if(!e)return;let{rings:t,hasM:n,hasZ:r,spatialReference:i}=e;switch(t??=[],function(e){return"number"==typeof e[0]?.[0]}(t)&&(t=[t]),t[0]?.[0]?.length){case 4:r??=!0,n??=!0;break;case 3:r??=!0!==n,n??=!r;break;default:r??=!1,n??=!1}return i??=f.A.WGS84,{...e,hasM:n,hasZ:r,rings:t,spatialReference:i}}(e)),this.curveRings=void 0,this.rings=[],this.type="polygon"}get cache(){return this.commitProperty("curveRings"),this.commitProperty("hasM"),this.commitProperty("hasZ"),this.commitProperty("rings"),this.commitProperty("spatialReference"),{}}get centroid(){(0,o.Lx)(u.A.getLogger(this),"centroid",{replacement:"Please use centroidOperator.execute() instead.",version:"4.34",warnOnce:!0});const e=(0,d.Ve)(this);return e?p.A.fromJSON(e):null}writeCurveRings(e,t){t.curveRings=(0,a.o8)(e)}get extent(){const e=(0,m.v)(this),{spatialReference:t}=this;return e?new c.A({...e,spatialReference:t}):null}writeRings(e,t){t.rings=(0,a.o8)(this.rings)}addRing(e){if(!e)return;const t=this.rings,n=t.length;if(x(e)){const r=[];for(let t=0,n=e.length;t<n;t++)r[t]=e[t].toArray();t[n]=r}else t[n]=e.slice();return this.notifyChange("rings"),this}clone(){const e=new r;return e.spatialReference=this.spatialReference,e.rings=(0,a.o8)(this.rings),e.curveRings=(0,a.o8)(this.curveRings),e.hasZ=this.hasZ,e.hasM=this.hasM,e}equals(e){if(this===e)return!0;if(null==e)return!1;const t=this.spatialReference,n=e.spatialReference;if(null!=t!=(null!=n))return!1;if(null!=t&&null!=n&&!t.equals(n))return!1;if(this.rings.length!==e.rings.length)return!1;for(let t=0;t<this.rings.length;t++){const n=this.rings[t],r=e.rings[t];if(!(0,s.aI)(n,r,_.v6))return!1}return!0}contains(e){if(!e)return!1;const t=(0,v.Cv)(e,this.spatialReference);return(0,g.m3)(this,null!=t?t:e)}isClockwise(e){const t=x(e)?e.map(e=>this.hasZ?this.hasM?[e.x,e.y,e.z,e.m]:[e.x,e.y,e.z]:[e.x,e.y]):e;return(0,y.$3)(t)}getPoint(e,t){if(!this._validateInputs(e,t))return null;const n=this.rings[e][t],r=this.hasZ,i=this.hasM;return r&&!i?new p.A(n[0],n[1],n[2],void 0,this.spatialReference):i&&!r?new p.A(n[0],n[1],void 0,n[2],this.spatialReference):r&&i?new p.A(n[0],n[1],n[2],n[3],this.spatialReference):new p.A(n[0],n[1],this.spatialReference)}insertPoint(e,t,n){return this._validateInputs(e,t,!0)?((0,b.h)(this,n),Array.isArray(n)||(n=n.toArray()),this.rings[e].splice(t,0,n),this.notifyChange("rings"),this):this}removePoint(e,t){if(!this._validateInputs(e,t))return null;const n=new p.A(this.rings[e].splice(t,1)[0],this.spatialReference);return this.notifyChange("rings"),n}removeRing(e){if(!this._validateInputs(e,null))return null;const t=this.rings.splice(e,1)[0],n=this.spatialReference,r=t.map(e=>new p.A(e,n));return this.notifyChange("rings"),r}setPoint(e,t,n){return this._validateInputs(e,t)?((0,b.h)(this,n),Array.isArray(n)||(n=n.toArray()),this.rings[e][t]=n,this.notifyChange("rings"),this):this}_validateInputs(e,t,n=!1){if(null==e||e<0||e>=this.rings.length)return!1;if(null!=t){const r=this.rings[e];if(n&&(t<0||t>r.length))return!1;if(!n&&(t<0||t>=r.length))return!1}return!0}toJSON(e){return this.write({},e)}};(0,i.Cg)([(0,l.MZ)({readOnly:!0})],w.prototype,"cache",null),(0,i.Cg)([(0,l.MZ)({readOnly:!0})],w.prototype,"centroid",null),(0,i.Cg)([(0,l.MZ)({json:{write:!0,origins:{"portal-item":{write:!1},"web-map":{write:!1},"web-scene":{write:!1}}}})],w.prototype,"curveRings",void 0),(0,i.Cg)([(0,M.K)("curveRings")],w.prototype,"writeCurveRings",null),(0,i.Cg)([(0,l.MZ)({readOnly:!0})],w.prototype,"extent",null),(0,i.Cg)([(0,l.MZ)({type:[[[Number]]],json:{write:{isRequired:!0}}})],w.prototype,"rings",void 0),(0,i.Cg)([(0,M.K)("rings")],w.prototype,"writeRings",null),w=r=(0,i.Cg)([(0,l.$K)("esri.geometry.Polygon")],w),w.prototype.toJSON.isDefaultToJSON=!0},82799(e,t,n){n.d(t,{A:()=>d});var r,i=n(32198),s=n(4718),o=n(91429),a=n(5443),u=n(91075),l=n(86738),c=n(16930),h=n(90634),p=n(56993),f=n(43937);let d=r=class extends u.A{constructor(e){super(function(e){if(!e)return;let{paths:t,hasM:n,hasZ:r,spatialReference:i}=e;switch(t??=[],function(e){return"number"==typeof e[0]?.[0]}(t)&&(t=[t]),t[0]?.[0]?.length){case 4:r??=!0,n??=!0;break;case 3:r??=!0!==n,n??=!r;break;default:r??=!1,n??=!1}return i??=c.A.WGS84,{...e,hasM:n,hasZ:r,paths:t,spatialReference:i}}(e)),this.curvePaths=void 0,this.paths=[],this.type="polyline"}get cache(){return this.commitProperty("curvePaths"),this.commitProperty("hasM"),this.commitProperty("hasZ"),this.commitProperty("paths"),this.commitProperty("spatialReference"),{}}writeCurvePaths(e,t){t.curvePaths=(0,s.o8)(e)}get extent(){const e=(0,h.Z3)(this),{spatialReference:t}=this;return e?new a.A({...e,spatialReference:t}):null}writePaths(e,t){t.paths=(0,s.o8)(this.paths)}addPath(e){if(!e)return;const t=this.paths,n=t.length;if(function(e){return!Array.isArray(e[0])}(e)){const r=[];for(let t=0,n=e.length;t<n;t++)r[t]=e[t].toArray();t[n]=r}else t[n]=e.slice();return this.notifyChange("paths"),this}clone(){const e=new r;return e.spatialReference=this.spatialReference,e.paths=(0,s.o8)(this.paths),e.curvePaths=(0,s.o8)(this.curvePaths),e.hasZ=this.hasZ,e.hasM=this.hasM,e}getPoint(e,t){if(!this._validateInputs(e,t))return null;const n=this.paths[e][t],r=this.hasZ,i=this.hasM;return r&&!i?new l.A(n[0],n[1],n[2],void 0,this.spatialReference):i&&!r?new l.A(n[0],n[1],void 0,n[2],this.spatialReference):r&&i?new l.A(n[0],n[1],n[2],n[3],this.spatialReference):new l.A(n[0],n[1],this.spatialReference)}insertPoint(e,t,n){return this._validateInputs(e,t,!0)?((0,p.h)(this,n),Array.isArray(n)||(n=n.toArray()),this.paths[e].splice(t,0,n),this.notifyChange("paths"),this):this}removePath(e){if(!this._validateInputs(e,null))return null;const t=this.paths.splice(e,1)[0],n=this.spatialReference,r=t.map(e=>new l.A(e,n));return this.notifyChange("paths"),r}removePoint(e,t){if(!this._validateInputs(e,t))return null;const n=new l.A(this.paths[e].splice(t,1)[0],this.spatialReference);return this.notifyChange("paths"),n}setPoint(e,t,n){return this._validateInputs(e,t)?((0,p.h)(this,n),Array.isArray(n)||(n=n.toArray()),this.paths[e][t]=n,this.notifyChange("paths"),this):this}_validateInputs(e,t,n=!1){if(null==e||e<0||e>=this.paths.length)return!1;if(null!=t){const r=this.paths[e];if(n&&(t<0||t>r.length))return!1;if(!n&&(t<0||t>=r.length))return!1}return!0}toJSON(e){return this.write({},e)}};(0,i.Cg)([(0,o.MZ)({readOnly:!0})],d.prototype,"cache",null),(0,i.Cg)([(0,o.MZ)({json:{write:!0,origins:{"portal-item":{write:!1},"web-map":{write:!1},"web-scene":{write:!1}}}})],d.prototype,"curvePaths",void 0),(0,i.Cg)([(0,f.K)("curvePaths")],d.prototype,"writeCurvePaths",null),(0,i.Cg)([(0,o.MZ)({readOnly:!0})],d.prototype,"extent",null),(0,i.Cg)([(0,o.MZ)({type:[[[Number]]],json:{write:{isRequired:!0}}})],d.prototype,"paths",void 0),(0,i.Cg)([(0,f.K)("paths")],d.prototype,"writePaths",null),d=r=(0,i.Cg)([(0,o.$K)("esri.geometry.Polyline")],d),d.prototype.toJSON.isDefaultToJSON=!0},4197(e,t,n){n.d(t,{Vj:()=>c,cj:()=>l,jh:()=>s,l5:()=>a,yH:()=>u});var r=n(34275),i=n(9093);function s(e){return e<=1024?new Array(e).fill(0):new Float64Array(e)}function o(e){return((0,r.iu)(e)?e.byteLength/8:e.length)<=1024?Array.from(e):new Float64Array(e)}function a(e,t,n){return Array.isArray(e)?e.slice(t,t+n):e.subarray(t,t+n)}function u(e,t){if(0===t.length)return o(e);if(0===e.length)return o(t);const n=s(e.length+t.length);for(let t=0;t<e.length;++t)n[t]=e[t];for(let r=0;r<t.length;++r)n[e.length+r]=t[r];return n}function l(e){return[...e]}function c(e){const t=(0,i.vt)();for(let n=0;n<16;++n)t[n]=e[n];return t}},70328(e,t,n){n.d(t,{BI:()=>I,C:()=>o,DC:()=>p,Ej:()=>v,Ie:()=>T,Jt:()=>A,Lu:()=>M,Ne:()=>x,RF:()=>h,TF:()=>m,VL:()=>d,aI:()=>k,fA:()=>a,gE:()=>l,gX:()=>_,hZ:()=>S,iT:()=>f,is:()=>P,pg:()=>b,uJ:()=>y,vI:()=>w,vY:()=>u,vt:()=>s,w1:()=>c,yr:()=>g}),n(35522);var r=n(5443),i=(n(19419),n(4197));function s(e=C){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function o(e,t){for(let n=0;n<6;n++)e[n]=t[n];return e}function a(e,t,n,r,i,o,a=s()){return a[0]=e,a[1]=t,a[2]=n,a[3]=r,a[4]=i,a[5]=o,a}function u(e,t=s()){return function(e,t,n,r=s()){return S(r,R),function(e,t,n=0,r=t.length/3){let i=e[0],s=e[1],o=e[2],a=e[3],u=e[4],l=e[5];for(let e=0;e<r;e++)i=Math.min(i,t[n+3*e]),s=Math.min(s,t[n+3*e+1]),o=Math.min(o,t[n+3*e+2]),a=Math.max(a,t[n+3*e]),u=Math.max(u,t[n+3*e+1]),l=Math.max(l,t[n+3*e+2]);e[0]=i,e[1]=s,e[2]=o,e[3]=a,e[4]=u,e[5]=l}(r,e,t,n),r}(e,0,e.length/3,t)}function l(e,t=(0,i.jh)(24)){const[n,r,s,o,a,u]=e;return t[0]=n,t[1]=r,t[2]=s,t[3]=n,t[4]=r,t[5]=u,t[6]=n,t[7]=a,t[8]=s,t[9]=n,t[10]=a,t[11]=u,t[12]=o,t[13]=r,t[14]=s,t[15]=o,t[16]=r,t[17]=u,t[18]=o,t[19]=a,t[20]=s,t[21]=o,t[22]=a,t[23]=u,t}function c(e,t){const n=isFinite(e[2])||isFinite(e[5]);return new r.A(n?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function h(e,t,n=e){n[0]=Math.min(e[0],t[0]),n[1]=Math.min(e[1],t[1]),n[2]=Math.min(e[2],t[2]),n[3]=Math.max(e[3],t[3]),n[4]=Math.max(e[4],t[4]),n[5]=Math.max(e[5],t[5])}function p(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[3]=Math.max(e[3],t[2]),e[4]=Math.max(e[4],t[3])}function f(e,[t,n,r]){!function(e,t,n,r){e[0]=Math.min(e[0],t),e[1]=Math.min(e[1],n),e[2]=Math.min(e[2],r),e[3]=Math.max(e[3],t),e[4]=Math.max(e[4],n),e[5]=Math.max(e[5],r)}(e,t,n,r)}function d(e){return e[0]>=e[3]?0:e[3]-e[0]}function g(e){return e[1]>=e[4]?0:e[4]-e[1]}function y(e){return e[2]>=e[5]?0:e[5]-e[2]}function m(e){const t=d(e),n=y(e),r=g(e);return t*t+n*n+r*r}function _(e,t=[0,0,0]){return t[0]=e[0]+d(e)/2,t[1]=e[1]+g(e)/2,t[2]=e[2]+y(e)/2,t}function v(e,t=[0,0,0]){return t[0]=d(e),t[1]=g(e),t[2]=y(e),t}function b(e,t){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function M(e,t){return t[0]=e[3],t[1]=e[4],t[2]=e[5],t}function x(e,t,n=e){return n[0]=t[0],n[1]=t[1],n[2]=t[2],n!==e&&(n[3]=e[3],n[4]=e[4],n[5]=e[5]),n}function w(e,t,n=e){return n[3]=t[0],n[4]=t[1],n[5]=t[2],n!==e&&(n[0]=e[0],n[1]=e[1],n[2]=e[2]),e}function S(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function T(e){return e?S(e,R):s(R)}function A(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function I(e,t,n,r,i){return e[0]=t,e[1]=n,e[2]=Number.NEGATIVE_INFINITY,e[3]=r,e[4]=i,e[5]=Number.POSITIVE_INFINITY,e}function P(e){return 6===e.length}function k(e,t,n){if(null==e||null==t)return e===t;if(!P(e)||!P(t))return!1;if(n){for(let r=0;r<e.length;r++)if(!n(e[r],t[r]))return!1}else for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}const R=[1/0,1/0,1/0,-1/0,-1/0,-1/0],C=[0,0,0,0,0,0];s(),n.d(t,["qv",0,R,"v_",0,C])},90634(e,t,n){n.d(t,{HA:()=>c,JM:()=>h,Z3:()=>d,ge:()=>p,v:()=>f});var r=n(537);const i=[];function s(e,t,n,r){return{xmin:e,ymin:t,xmax:n,ymax:r}}function o(e,t,n,r,i,s){return{xmin:e,ymin:t,zmin:n,xmax:r,ymax:i,zmax:s}}function a(e,t,n,r,i,s){return{xmin:e,ymin:t,mmin:n,xmax:r,ymax:i,mmax:s}}function u(e,t,n,r,i,s,o,a){return{xmin:e,ymin:t,zmin:n,mmin:r,xmax:i,ymax:s,zmax:o,mmax:a}}function l(e,t=!1,n=!1){return t?n?u(e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7]):o(e[0],e[1],e[2],e[3],e[4],e[5]):n?a(e[0],e[1],e[2],e[3],e[4],e[5]):s(e[0],e[1],e[2],e[3])}function c(e){return e?function(e){return void 0!==e.xmin&&void 0!==e.ymin&&void 0!==e.xmax&&void 0!==e.ymax}(e)?e:function(e){return void 0!==e.x&&void 0!==e.y}(e)?function(e){const{x:t,y:n,z:r,m:i}=e,l=null!=i;return null!=r?l?u(t,n,r,i,t,n,r,i):o(t,n,r,t,n,r):l?a(t,n,i,t,n,i):s(t,n,t,n)}(e):function(e){return void 0!==e.rings}(e)?f(e):function(e){return void 0!==e.paths}(e)?d(e):function(e){return void 0!==e.points}(e)?p(e):null:null}function h(e,{xmin:t,ymin:n,zmin:r,mmin:i,xmax:s,ymax:o,zmax:a,mmax:u}){e.xmin=Math.min(e.xmin,t),e.xmax=Math.max(e.xmax,s),e.ymin=Math.min(e.ymin,n),e.ymax=Math.max(e.ymax,o),null!=e.zmin&&(e.zmin=Math.min(e.zmin,r),e.zmax=Math.max(e.zmax,a)),null!=e.mmin&&(e.mmin=Math.min(e.mmin,i),e.mmax=Math.max(e.mmax,u))}function p(e){const{hasZ:t,hasM:n,points:s}=e,o=(0,r.Pj)(i,s,t??!1,n??!1,t??!1,n??!1);return o?l(o,t,n):null}function f(e){const{hasZ:t,hasM:n,rings:s,curveRings:o}=e,a=(0,r.Yz)(i,o??s,t??!1,n??!1);return a?l(a,t,n):null}function d(e){const{hasZ:t,hasM:n,paths:s,curvePaths:o}=e,a=(0,r.Yz)(i,o??s,t??!1,n??!1);return a?l(a,t,n):null}},47610(e,t,n){function r([e,t,n,r],[i,s,o,a]){return e===i&&t===s&&(null==n&&null==o||n===o)&&(null==r&&null==a||r===a)}n.d(t,{v6:()=>r}),n(5443),n(83960)},83960(e,t,n){n.d(t,{X_:()=>s,oW:()=>a,zx:()=>o});var r=n(34727),i=n(86211);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*39.37*96:0}function o(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}},50498(e,t,n){var r=n(66552),i=n(5443),s=n(91075),o=n(48526),a=n(86738),u=n(39829),l=n(82799);const c=(0,r.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),h=(0,r.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"}),p={base:s.A,key:"type",typeMap:{extent:i.A,multipoint:o.A,point:a.A,polyline:l.A,polygon:u.A}},f=new r.J({esriGeometryBezier3Curve:"cubic-bezier",esriGeometryCircularArc:"circular-arc",esriGeometryEllipticArc:"elliptic-arc"},{ignoreUnknown:!0});n.d(t,["Ye",0,h,"gy",0,c,"iI",0,f,"yR",0,p])},56993(e,t,n){function r(e,t,n=!1){let{hasM:r,hasZ:i}=e;Array.isArray(t)?4!==t.length||r||i?3===t.length&&n&&!r?(i=!0,r=!1):3===t.length&&r&&i&&(r=!1,i=!1):(r=!0,i=!0):(i=!i&&t.hasZ&&(!r||t.hasM),r=!r&&t.hasM&&(!i||t.hasZ)),e.hasZ=i,e.hasM=r}n.d(t,{h:()=>r})},62815(e,t,n){n.d(t,{N:()=>a,d:()=>u});var r=n(86211),i=n(73941),s=n(21325),o=n(52006);function a(e,t,n){const r=u(t,n);if(1!==r)switch(e){case"point":case"esriGeometryPoint":return e=>function(e,t){null!=e?.z&&(e.z*=t)}(e,r);case"polyline":case"esriGeometryPolyline":return e=>function(e,t){if(e){if(e.curvePaths)for(const n of e.curvePaths)for(const e of n){const n=(0,o.yP)(e);n.length>2&&(n[2]*=t)}if(e.paths)for(const n of e.paths)for(const e of n)e.length>2&&(e[2]*=t)}}(e,r);case"polygon":case"esriGeometryPolygon":return e=>function(e,t){if(e){if(e.curveRings)for(const n of e.curveRings)for(const e of n){const n=(0,o.yP)(e);n.length>2&&(n[2]*=t)}if(e.rings)for(const n of e.rings)for(const e of n)e.length>2&&(e[2]*=t)}}(e,r);case"multipoint":case"esriGeometryMultipoint":return e=>function(e,t){if(e)for(const n of e.points)n.length>2&&(n[2]*=t)}(e,r);case"extent":case"esriGeometryEnvelope":return e=>function(e,t){e&&null!=e.zmin&&null!=e.zmax&&(e.zmin*=t,e.zmax*=t)}(e,r);default:return}}function u(e,t){return null==e||null==t||(0,s.aI)(e,t)||(0,i.xP)(e)||(0,i.xP)(t)?1:(0,r.G9)(e)/(0,r.G9)(t)}},39357(e,t,n){n.d(t,{A:()=>a});var r,i=n(32198),s=n(25482),o=n(91429);let a=r=class extends s.o{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,i.Cg)([(0,o.MZ)({type:String,json:{write:{isRequired:!0}}})],a.prototype,"name",void 0),(0,i.Cg)([(0,o.MZ)({type:[String,Number],json:{write:{isRequired:!0}}})],a.prototype,"code",void 0),a=r=(0,i.Cg)([(0,o.$K)("esri.layers.support.CodedValue")],a)},53177(e,t,n){n.d(t,{A:()=>c});var r,i=n(32198),s=n(4718),o=n(91429),a=n(39357),u=n(76357),l=n(93223);let c=class extends u.A{static{r=this}constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const n=String(e);this.codedValues.some(e=>(String(e.code)===n&&(t=e.name),!!t))}return t}clone(){return new r({codedValues:(0,s.o8)(this.codedValues),name:this.name})}};(0,i.Cg)([(0,o.MZ)({type:[a.A],json:{write:{isRequired:!0}}})],c.prototype,"codedValues",void 0),(0,i.Cg)([(0,l.e)({codedValue:"coded-value"})],c.prototype,"type",void 0),c=r=(0,i.Cg)([(0,o.$K)("esri.layers.support.CodedValueDomain")],c)},76357(e,t,n){n.d(t,{A:()=>l});var r=n(32198),i=n(66552),s=n(25482),o=n(91429),a=n(93223);const u=new i.J({inherited:"inherited",codedValue:"coded-value",range:"range"});let l=class extends s.o{constructor(e){super(e),this.name=null,this.type=null}};(0,r.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],l.prototype,"name",void 0),(0,r.Cg)([(0,a.e)(u),(0,o.MZ)({json:{write:{isRequired:!0}}})],l.prototype,"type",void 0),l=(0,r.Cg)([(0,o.$K)("esri.layers.support.Domain")],l)},20437(e,t,n){n.d(t,{A:()=>d});var r,i=n(32198),s=n(66552),o=n(25482),a=n(91429),u=n(56507),l=n(8631),c=n(98453),h=n(36005),p=n(93223);const f=new s.J({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",currency:"currency",dateAndTime:"date-and-time",description:"description",emailAddress:"email-address",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",phoneNumber:"phone-number",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier",url:"url"});let d=class extends o.o{static{r=this}constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?.value??null}readValueType(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?f.fromJSON(n.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain?.clone()??null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,i.Cg)([(0,a.MZ)({type:String,json:{write:!0}})],d.prototype,"alias",void 0),(0,i.Cg)([(0,a.MZ)({type:[String,Number],json:{write:{allowNull:!0}}})],d.prototype,"defaultValue",void 0),(0,i.Cg)([(0,a.MZ)()],d.prototype,"description",void 0),(0,i.Cg)([(0,h.w)("description")],d.prototype,"readDescription",null),(0,i.Cg)([(0,a.MZ)({types:l.g,json:{read:{reader:l.r},write:!0}})],d.prototype,"domain",void 0),(0,i.Cg)([(0,a.MZ)({type:Boolean,json:{write:!0}})],d.prototype,"editable",void 0),(0,i.Cg)([(0,a.MZ)({type:u.jz,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],d.prototype,"length",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{write:!0}})],d.prototype,"name",void 0),(0,i.Cg)([(0,a.MZ)({type:Boolean,json:{write:!0}})],d.prototype,"nullable",void 0),(0,i.Cg)([(0,p.e)(c.m)],d.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)()],d.prototype,"valueType",void 0),(0,i.Cg)([(0,h.w)("valueType",["description"])],d.prototype,"readValueType",null),(0,i.Cg)([(0,a.MZ)({type:Boolean,json:{read:!1}})],d.prototype,"visible",void 0),d=r=(0,i.Cg)([(0,a.$K)("esri.layers.support.Field")],d)},41628(e,t,n){n.d(t,{A:()=>u});var r,i=n(32198),s=n(91429),o=n(76357),a=n(93223);let u=class extends o.A{static{r=this}constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new r({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,i.Cg)([(0,s.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,n){t[n]=[this.minValue||0,e]},isRequired:!0}}})],u.prototype,"maxValue",void 0),(0,i.Cg)([(0,s.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,n){t[n]=[e,this.maxValue||0]},isRequired:!0}}})],u.prototype,"minValue",void 0),(0,i.Cg)([(0,a.e)({range:"range"})],u.prototype,"type",void 0),u=r=(0,i.Cg)([(0,s.$K)("esri.layers.support.RangeDomain")],u)},8631(e,t,n){n.d(t,{r:()=>p,g:()=>h});var r,i=n(53177),s=n(76357),o=n(32198),a=n(91429),u=n(93223);let l=class extends s.A{static{r=this}constructor(e){super(e),this.type="inherited"}clone(){return new r}};(0,o.Cg)([(0,u.e)({inherited:"inherited"})],l.prototype,"type",void 0),l=r=(0,o.Cg)([(0,a.$K)("esri.layers.support.InheritedDomain")],l);var c=n(41628);const h={key:"type",base:s.A,typeMap:{range:c.A,"coded-value":i.A,inherited:l}};function p(e){if(!e?.type)return null;switch(e.type){case"range":return c.A.fromJSON(e);case"codedValue":return i.A.fromJSON(e);case"inherited":return l.fromJSON(e)}return null}},98453(e,t,n){const r=new(n(66552).J)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"});n.d(t,["m",0,r])},53655(e,t,n){n.d(t,{SH:()=>Z,ae:()=>P,cn:()=>g});var r=n(32198),i=n(49186),s=n(51624),o=n(50498);const a=["esriGeometryPoint","esriGeometryMultipoint","esriGeometryPolyline","esriGeometryPolygon"],u=["esriFieldTypeSmallInteger","esriFieldTypeInteger","esriFieldTypeSingle","esriFieldTypeDouble","esriFieldTypeString","esriFieldTypeDate","esriFieldTypeOID","esriFieldTypeGeometry","esriFieldTypeBlob","esriFieldTypeRaster","esriFieldTypeGUID","esriFieldTypeGlobalID","esriFieldTypeXML","esriFieldTypeBigInteger","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"],l=["sqlTypeBigInt","sqlTypeBinary","sqlTypeBit","sqlTypeChar","sqlTypeDate","sqlTypeDecimal","sqlTypeDouble","sqlTypeFloat","sqlTypeGeometry","sqlTypeGUID","sqlTypeInteger","sqlTypeLongNVarchar","sqlTypeLongVarbinary","sqlTypeLongVarchar","sqlTypeNChar","sqlTypeNVarchar","sqlTypeOther","sqlTypeReal","sqlTypeSmallInt","sqlTypeSqlXml","sqlTypeTime","sqlTypeTimestamp","sqlTypeTimestamp2","sqlTypeTinyInt","sqlTypeVarbinary","sqlTypeVarchar"],c=["upperLeft","lowerLeft"];function h(e,t){const n=e.getEnum();return n<t.length?t[n]:void 0}function p(e,t){e.featureSet.geometryType=e.usesShortGeometryTypes?o.gy.fromJSON(t):t}function f(e,t=e.featureSet.geometryType){return e.usesShortGeometryTypes?o.gy.toJSON(t):t}function d(e){const t=e.asUnsafe();for(;t.next();)switch(t.tag()){case 1:return t.getString();case 2:return t.getFloat();case 3:return t.getDouble();case 4:return t.getSInt32();case 5:return t.getUInt32();case 6:return t.getInt64();case 7:return t.getUInt64();case 8:return t.getSInt64();case 9:return t.getBool();default:return t.skip(),null}return null}function g(e){const t=e.asUnsafe(),n={type:u[0]};for(;t.next();)switch(t.tag()){case 1:n.name=t.getString();break;case 2:n.type=h(t,u);break;case 3:n.alias=t.getString();break;case 4:n.sqlType=h(t,l);break;case 5:default:t.skip();break;case 6:n.defaultValue=t.getString()}return n}function y(e){const t={},n=e.asUnsafe();for(;n.next();)switch(n.tag()){case 1:t.name=n.getString();break;case 2:t.isSystemMaintained=n.getBool();break;default:n.skip()}return t}let m=[];function _(e,t,n){let r=f(t),i=0;const s=e.asUnsafe();for(;s.next();)switch(s.tag()){case 1:1===n?r=f(t,h(s,a)):s.skip();continue;case 2:for(const e=s.getPackedEnd();s.pos()<e;)m[i++]=s.getUInt32();continue;case 3:i>0?(m.length=i,null!=t.geometry(n,r,m)&&(m=[])):t.geometry(n,r,[]);for(const e=s.getPackedEnd();s.pos()<e;)t.coord(s.getSInt64());continue;default:s.skip()}}function v(e,t){const n=[],r=e.asUnsafe();for(;r.next();)if(3!==r.tag())r.skip();else for(const e=r.getPackedEnd();r.pos()<e;)n.push(r.getSInt64());t.centroid(n)}let b=[],M=[],x=[];function w(e,t){const n={stack:[],error:void 0,hasError:!1};try{let i=0;const s=m;let o=0;const a=e.asUnsafe(),u=(0,r.mS)(n,a.clonePooled().asUnsafe(),!1);for(;a.next();)switch(a.tag()){case 2:for(const l=a.getPackedEnd();a.pos()<l;)s[i++]=a.getUInt32();continue;case 3:if(!("curvedGeometry"in t))throw new Error(`Tried to parse curved geometry in a ${t.constructor.name}, which doesn't support them.`);a.processMessageWithArgs(S,o++);continue;case 4:{const c=a.getUInt32(),h=a.pos()+c;if(0===o||0===i||0===c){a.move(h);continue}s.length=i,x.length=M.length=o,t.curvedGeometry(f(t),s,M,x);const{hasZ:p,hasM:d}=t.featureSet,g=[],y=[0,0];function _(){for(let e=0;e<y.length;++e)g[e]=y[e],y[e]=a.getSInt64()}p&&y.push(0),d&&y.push(0);const v=[0,0],w=[0,0],T=v,A=v;let I=0;for(let P=0;P<i;++P){_(),g.fill(0),t.startCurvedPart(y);for(const k=I+s[P];I<k;++I){const R=M[I],C=x[I];switch(R){case 0:for(let V=0;V<C;++V)_(),y[0]+=g[0],y[1]+=g[1],t.lineSegment(g,y);continue;case 1:for(let Z=0;Z<C;++Z)_(),T[0]=a.getSInt64(),T[1]=a.getSInt64(),t.circularArcSegment(g,y,T);continue;case 2:for(let N=0;N<C;++N)_(),v[0]=a.getSInt64(),v[1]=a.getSInt64(),w[0]=a.getSInt64(),w[1]=a.getSInt64(),t.bezierSegment(g,y,v,w);continue;case 3:if(u.move(b[I]),u.getUInt32()<7*C)throw new Error("Not implemented: compressed full circle encoding");for(let F=0;F<C;++F){_(),A[0]=u.getDouble(),A[1]=u.getDouble();const O=u.getDouble(),q=u.getDouble(),G=u.getDouble(),E=u.getDouble(),D=u.getDouble();t.ellipticArcSegment(g,y,A,O,q,G,E,D)}continue}}t.finishCurvedPart(y)}continue}default:a.skip()}}catch(j){n.error=j,n.hasError=!0}finally{(0,r.hk)(n)}}function S(e,t){const n=e.asUnsafe();let r=0,i=0,s=0;for(;n.next();)switch(n.tag()){case 1:r=n.getEnum();continue;case 2:i=n.getUInt32();continue;case 3:s=n.pos(),n.skip();continue;default:n.skip()}if(3===r&&0===s)throw new Error("An elliptic arc segment set did not include a parameters array");M[t]=r,x[t]=i,b[t]=s}function T(e,t){t.feature();const n=t.featureSet.features.at(-1);let r=0;const{fields:i}=t.featureSet;for(;e.next();)switch(e.tag()){case 1:if(null==i)throw new Error("A Feature had attributes but the FeatureResult didn't include any fields");n.attributes[i[r++].name]=e.processMessage(d);continue;case 2:e.processMessageWithArgs(_,t,0);continue;case 4:e.processMessageWithArgs(v,t);continue;case 7:e.processMessageWithArgs(w,t);continue;case 11:n.distance=e.getDouble();continue;default:e.skip();continue}t.finishFeature?.()}function A(e){const t=[1,1,1,1],n=e.asUnsafe();for(;n.next();)switch(n.tag()){case 1:t[0]=n.getDouble();break;case 2:t[1]=n.getDouble();break;case 4:t[2]=n.getDouble();break;case 3:t[3]=n.getDouble();break;default:n.skip()}return t}function I(e){const t=[0,0,0,0],n=e.asUnsafe();for(;n.next();)switch(n.tag()){case 1:t[0]=n.getDouble();break;case 2:t[1]=n.getDouble();break;case 4:t[2]=n.getDouble();break;case 3:t[3]=n.getDouble();break;default:n.skip()}return t}function P(e){const t={originPosition:c[0]},n=e.asUnsafe();for(;n.next();)switch(n.tag()){case 1:t.originPosition=h(n,c);break;case 2:t.scale=n.processMessage(A);break;case 3:t.translate=n.processMessage(I);break;default:n.skip()}return t}function k(e){const t={},n=e.asUnsafe();for(;n.next();)switch(n.tag()){case 1:t.shapeAreaFieldName=n.getString();break;case 2:t.shapeLengthFieldName=n.getString();break;case 3:t.units=n.getString();break;default:n.skip()}return t}function R(e){const t={};for(;e.next();)switch(e.tag()){case 1:t.wkid=e.getUInt32();break;case 5:t.wkt=e.getString();break;case 2:t.latestWkid=e.getUInt32();break;case 3:t.vcsWkid=e.getUInt32();break;case 4:t.latestVcsWkid=e.getUInt32();break;default:e.skip()}return t}function C(e,t){const n=e.asUnsafe();if(t.featureSet.features.length=0,"features"===t.parseOnly?.type){const e=t.parseOnly.indices.values();let r=0,i=e.next().value;for(;n.next();)15===n.tag()&&r++===i?(i=e.next().value,n.processMessageWithArgs(T,t)):n.skip();return}let r=!1;for("metadata"===t.parseOnly?.type&&(r=!0,t.parseOnly.featureCount=0),p(t,"esriGeometryPoint");n.next();)switch(n.tag()){case 1:t.idField(n.getString());continue;case 3:t.featureSet.globalIdFieldName=n.getString();continue;case 4:t.featureSet.geohashFieldName=n.getString();continue;case 5:t.featureSet.geometryProperties=n.processMessage(k);continue;case 7:p(t,h(n,a));continue;case 8:t.featureSet.spatialReference=n.processMessageWithArgs(R);continue;case 10:t.featureSet.hasZ=n.getBool();continue;case 11:t.featureSet.hasM=n.getBool();continue;case 12:t.featureSet.transform=n.processMessage(P);continue;case 9:t.featureSet.exceededTransferLimit=n.getBool();continue;case 13:t.featureSet.fields??=[],t.featureSet.fields.push(n.processMessage(g));continue;case 15:if(r){++t.parseOnly.featureCount,n.skip();continue}n.processMessageWithArgs(T,t);continue;case 2:t.idField(n.processMessage(y));continue;default:n.skip()}}function V(e,t,n){let r=-1;for(;e.next();)switch(e.tag()){case 4:r=e.pos(),e.skip();continue;case 1:e.processMessageWithArgs(C,t);continue;default:e.skip()}if(-1!==r){if(!t.queryGeometry()){const n=e.pos();e.move(r),e.processMessageWithArgs(_,t,1),e.move(n)}n.queryGeometryType=t.queryGeometryType(),n.queryGeometry=t.queryGeometry()}t.finish(),n.featureResult=t.featureSet}function Z(e,t){const n={stack:[],error:void 0,hasError:!1};try{(0,r.mS)(n,{[Symbol.dispose](){m=[],b=[],M=[],x=[]}},!1);try{const n={stack:[],error:void 0,hasError:!1};try{const i=(0,r.mS)(n,s.A.constructPooled(new Uint8Array(e),new DataView(e)),!1);let o;for(;i.next();)2===i.tag()?(o={},i.processMessageWithArgs(V,t,o)):i.skip();return o}catch(e){n.error=e,n.hasError=!0}finally{(0,r.hk)(n)}}catch(e){throw new i.A("query:parsing-pbf","Error while parsing FeatureSet PBF payload",{error:e})}}catch(e){n.error=e,n.hasError=!0}finally{(0,r.hk)(n)}}},63746(e,t,n){function r(e){return class{constructor(){for(const t of e)this[t]=null}}}function i(e,t=1){const{transform:n,hasZ:r,hasM:i}=e;if(null==n)return r&&1!==t?e=>{e[2]*=t}:null;const[s,o]=function(e,t,n,r){let{scale:i,translate:s,originPosition:o}=e;return"upperLeft"===o&&(i=i.map((e,t)=>1===t?-e:e)),t&&(i=i.map((e,t)=>2===t?e*r:e),s=s.map((e,t)=>2===t?e*r:e)),!t&&n&&(i=i.filter((e,t)=>2!==t),s=s.filter((e,t)=>2!==t)),[i,s]}(n,r,i,t),a=e.hasZ?3:2;return e=>{for(let t=0;t<e.length&&(t!==a||0!==e[t]);++t)e[t]=e[t]*s[t]+o[t]}}n.d(t,{M:()=>i,_:()=>r})},66208(e,t,n){n.d(t,{m:()=>i});var r=n(53655);function i(e,t){const{featureResult:n}=(0,r.SH)(e,t);return n}},39078(e,t,n){n.r(t),n.d(t,{default:()=>f});var r=n(24326),i=n(16930),s=n(62815),o=(n(70328),n(19419),n(50498),n(20437));n(44208),n(34727),n(21325);class a{constructor(e,t,n){this.uid=e,this.geometry=t,this.attributes=n,this.visible=!0,this.objectId=null,this.centroid=null}}class u{constructor(){this.exceededTransferLimit=!1,this.features=[],this.fields=[],this.hasM=!1,this.hasZ=!1,this.geometryType=null,this.objectIdFieldName=null,this.globalIdFieldName=null,this.geometryProperties=null,this.geohashFieldName=null,this.spatialReference=null,this.transform=null}}var l=n(63746);class c{constructor(e){this._options=e,this.featureSet=new u,this.usesShortGeometryTypes=!0,this._queryGeometryType=null,this._queryGeometry=null,this.parseOnly=null,this.missingAttributes=[],this._transformInPlace=null,this._attributesClass=null,this._previousX=0,this._previousY=0,this._point=null,this._lengths=null,this._vertex=[],this._part=null,this._parts=null,this._i=0,this._finishVertex=c._finishVertexNonPoint}queryGeometryType(){return this._queryGeometryType}queryGeometry(){return this._queryGeometry}idField(e){"string"==typeof e&&(this.featureSet.objectIdFieldName=e)}finish(){this._options.applyTransform&&(this.featureSet.transform=null);let{spatialReference:e,features:t,fields:n}=this.featureSet;if(!e||e instanceof i.A||(this.featureSet.spatialReference=e=i.A.fromJSON(e)),e)for(const{geometry:n}of t)n&&(n.spatialReference=e);n.forEach((e,t)=>{e instanceof o.A||(n[t]=o.A.fromJSON(e))})}_setVertexTransformer(){const{sourceSpatialReference:e}=this._options,{spatialReference:t,hasZ:n}=this.featureSet,r=n?(0,s.d)(e,t):1;this._transformInPlace??=(0,l.M)(this.featureSet,r)}feature(){this._attributesClass??=(0,l._)(this.featureSet.fields?.map(e=>e.name)??[]),this.featureSet.features.push(new a((0,r.c)(),null,new this._attributesClass)),this._options.applyTransform&&this._setVertexTransformer()}finishFeature(){const{maxStringAttributeLength:e,maxStringAttributeFields:t}=this._options,{attributes:n}=this.featureSet.features.at(-1),r=n[this.featureSet.objectIdFieldName];!function(e,t,n,r){if(t?.size&&null!=n&&e)for(const i in e){if(!t.has(i))continue;const s=e[i];"string"==typeof s&&s.length>n&&(r(i),e[i]="")}}(n,t,e,e=>{null!=r&&this.missingAttributes.push({objectId:r,attribute:e})})}_createPoint(){const{hasZ:e,hasM:t,spatialReference:n}=this.featureSet,r={type:"point",x:0,y:0,spatialReference:n,hasZ:e,hasM:t};return e&&(r.z=0),t&&(r.m=0),r}centroid(e){const{hasZ:t,hasM:n}=this.featureSet,r=this._createPoint();[r.x,r.y]=e,t&&(r.z=e[2]),n&&(r.m=e.at(-1)),this.featureSet.features.at(-1).centroid=r}geometry(e,t,n){this._previousX=this._previousY=0,this._lengths=n;let r,{spatialReference:i,hasZ:s,hasM:o}=this.featureSet;switch(s??=!1,o??=!1,this._vertex=[0,0],s&&this._vertex.push(0),o&&this._vertex.push(0),this._finishVertex=c._finishVertexNonPoint,t){case"esriGeometryPoint":this._point=this._createPoint(),r=this._point,this._finishVertex=s?o?c._finishVertexPointXYZM:c._finishVertexPointXYZ:o?c._finishVertexPointXYM:c._finishVertexPointXY;break;case"esriGeometryMultipoint":r={type:"multipoint",points:[],spatialReference:i,hasZ:s,hasM:o},this._part=r.points,this._parts=[];break;case"esriGeometryPolyline":r={type:"polyline",paths:[],spatialReference:i,hasZ:s,hasM:o},this._parts=r.paths,this._part=[];break;case"esriGeometryPolygon":r={type:"polygon",rings:[],spatialReference:i,hasZ:s,hasM:o},this._parts=r.rings,this._part=[]}1===e?(this._queryGeometry=r,this._queryGeometryType=t,this._options.applyTransform||this._setVertexTransformer()):this.featureSet.features.at(-1).geometry=r}coord(e){const t=this._vertex;t[this._i++]=e,this._i<t.length||(this._i=0,this._transformInPlace&&(t[0]+=this._previousX,t[1]+=this._previousY,[this._previousX,this._previousY]=t,this._transformInPlace(t)),this._finishVertex(this))}static _finishVertexPointXY({_point:e,_vertex:t}){[e.x,e.y]=t}static _finishVertexPointXYZ({_point:e,_vertex:t}){[e.x,e.y,e.z]=t}static _finishVertexPointXYM({_point:e,_vertex:t}){[e.x,e.y,e.m]=t}static _finishVertexPointXYZM({_point:e,_vertex:t}){[e.x,e.y,e.z,e.m]=t}static _finishVertexNonPoint(e){const{_part:t,_parts:n,_lengths:r,_vertex:i}=e;t.push([...i]),t.length<r[n.length]||(e._previousX=e._previousY=0,e._part=[],n.push(t))}}var h=n(66208);class p{_parseFeatureQuery(e){const t=new c(e.options),n=(0,h.m)(e.buffer,t),r={...n,spatialReference:n.spatialReference?.toJSON(),fields:n.fields?n.fields.map(e=>e.toJSON()):void 0,missingAttributes:t.missingAttributes};return Promise.resolve(r)}}function f(){return new p}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3309],{93309(e,t,i){i.r(t),i.d(t,{default:()=>V});var a=i(32198),n=i(67996),o=i(7762),s=i(51447),r=i(49186),l=i(53966),h=i(91869),d=i(25728),p=i(17676),u=i(36708),g=i(91429),c=i(35666),y=i(5443),m=i(86738),f=i(82799),L=i(12359),C=i(4146),M=i(90708),w=i(15375);const b={MULTIPLIER:"multiplier",ABSOLUTE:"absolute-value"};var k=i(24137),T=i(62796),v=i(40736),E=i(69860),N=i(99916),D=i(63074),S=i(34287),x=i(25036),I=i(10873),A=i(8460),_=i(69540),R=i(25482),Z=i(56507),B=i(69647),z=i(93223);let O=class extends((0,_.OU)(R.o)){constructor(e){super(e),this.durationLineWidth=5,this.entityPositionAtDurationRatio=1,this.eventsTicksVisualization="start-and-end",this.lineSeparationMultiplier=1,this.moveFirstBends=!0,this.secondBendRatio=.3,this.separateTimeOverlaps=!0,this.separateTimelineOverlaps=!0,this.separatedLineShapeRatio=0,this.showDurationLineForNonZeroDurationEntityEvents=!1,this.showNonZeroDurationIntervalBounds=!1,this.spaceSeparatedLinesEvenly=!1,this.timeBannerUTCOffsetInMinutes=0,this.timeDirection="right",this.useBezierCurves=!1}};(0,a.Cg)([(0,g.MZ)({type:Z.jz,range:{min:1,max:10},json:{write:!0}})],O.prototype,"durationLineWidth",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:1},json:{write:!0}})],O.prototype,"entityPositionAtDurationRatio",void 0),(0,a.Cg)([(0,z.e)(B.SJ)],O.prototype,"eventsTicksVisualization",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0},json:{write:!0}})],O.prototype,"lineSeparationMultiplier",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"moveFirstBends",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:1},json:{write:!0}})],O.prototype,"secondBendRatio",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"separateTimeOverlaps",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"separateTimelineOverlaps",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:1},json:{write:!0}})],O.prototype,"separatedLineShapeRatio",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"showDurationLineForNonZeroDurationEntityEvents",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"showNonZeroDurationIntervalBounds",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"spaceSeparatedLinesEvenly",void 0),(0,a.Cg)([(0,g.MZ)({type:Z.jz,json:{write:!0}})],O.prototype,"timeBannerUTCOffsetInMinutes",void 0),(0,a.Cg)([(0,g.MZ)({type:["bottom","left","right","top"],json:{write:!0}})],O.prototype,"timeDirection",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"useBezierCurves",void 0),O=(0,a.Cg)([(0,g.$K)("esri.linkChart.ChronologicalLayoutSettings")],O);const P=O;let U=class extends((0,_.OU)(R.o)){constructor(e){super(e),this.absoluteIdealEdgeLength=1,this.autoRepulsionRadius=!0,this.computationBudgetTime=2,this.idealEdgeLengthType="multiplier",this.multiplicativeIdealEdgeLength=1,this.repulsionRadiusMultiplier=1}};(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:360},json:{write:!0}})],U.prototype,"absoluteIdealEdgeLength",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],U.prototype,"autoRepulsionRadius",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,json:{write:!1}})],U.prototype,"computationBudgetTime",void 0),(0,a.Cg)([(0,z.e)(B.lg)],U.prototype,"idealEdgeLengthType",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:5},json:{write:!0}})],U.prototype,"multiplicativeIdealEdgeLength",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:1,max:99},json:{write:!0}})],U.prototype,"repulsionRadiusMultiplier",void 0),U=(0,a.Cg)([(0,g.$K)("esri.linkChart.OrganicLayoutSettings")],U);const j=U;let F=class extends((0,_.OU)(R.o)){constructor(e){super(e),this.rootEntities=[]}};(0,a.Cg)([(0,g.MZ)({type:[Object],json:{write:!0}})],F.prototype,"rootEntities",void 0),F=(0,a.Cg)([(0,g.$K)("esri.linkChart.RootedLayoutSettings")],F);let G=class extends((0,_.OU)(R.o)){constructor(e){super(e),this.chronologicalLayoutSettings=null,this.organicLayoutSettings=null,this.rootedLayoutSettings=null}};(0,a.Cg)([(0,g.MZ)({type:P,json:{write:!0}})],G.prototype,"chronologicalLayoutSettings",void 0),(0,a.Cg)([(0,g.MZ)({type:j,json:{write:!0}})],G.prototype,"organicLayoutSettings",void 0),(0,a.Cg)([(0,g.MZ)({type:F,json:{write:!0}})],G.prototype,"rootedLayoutSettings",void 0),G=(0,a.Cg)([(0,g.$K)("esri.linkChart.LayoutSettings")],G);var H=i(54628),$=i(53902),K=i(56400);let Q=class extends((0,S.q)((0,D.dM)((0,x.j)((0,d.M)(C.A))))){constructor(e){if(super(e),this.url=null,this.dataPreloadedInLocalCache=!1,this.initializationLinkChartConfig=null,this.membershipModified=!0,this._currentLinkChartConfig={layoutMode:"organic-standard"},this._graphTypeLookup=new Map,this.dataManager=null,this.knowledgeGraph=null,this.layers=new(o.A.ofType(T.A)),this.entityLinkChartDiagramLookup=new Map,this.relationshipLinkChartDiagramLookup=new Map,this.linkChartExtent=new y.A({xmin:-1e-7,ymin:-1e-7,xmax:1e-7,ymax:1e-7}),this.memberEntityTypes=null,this.memberRelationshipTypes=null,this.operationalLayerType="LinkChartLayer",this.sublayerIdsCache=new Map,this.tables=new(o.A.ofType(T.A)),this.type="link-chart",this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1,this.chronologicalAuxiliaryGraphics=null,this._originalInclusionList=e?.initializationInclusionModeDefinition,e?.dataPreloadedInLocalCache&&!e?.initializationInclusionModeDefinition)throw new r.A("knowledge-graph:linkchart-layer-constructor","If creating a link chart composite layer and configured that data is already loaded in the cache, you must specify an inclusion list so the Composite Layer knows what records belong to it");this.addHandles((0,u.wB)(()=>this.layers.concat(this.tables),(e,t)=>this._handleSublayersChange(e,t),u.OH))}normalizeCtorArgs(e){if(!e)return{};const{url:t,dataPreloadedInLocalCache:i,initializationLinkChartConfig:a}=e;let{title:n}=e;return!n&&e?.url&&(n=(0,v.$L)(e.url)),{url:t,title:n,dataPreloadedInLocalCache:i,initializationLinkChartConfig:a}}_initializeLayerProperties(e){const t=new Set;let i=[],a=[];if(e.inclusionModeDefinition&&(!e.inclusionModeDefinition.namedTypeDefinitions||e.inclusionModeDefinition.namedTypeDefinitions.size<1))throw new r.A("knowledge-graph:composite-layer-constructor","If an explicit inclusion definition is defined, at least one namedTypeDefinition must also be defined");e.inclusionModeDefinition?.generateAllSublayers?(i=e.knowledgeGraph.dataModel.entityTypes??[],a=e.knowledgeGraph.dataModel.relationshipTypes??[]):e.inclusionModeDefinition?.namedTypeDefinitions&&e.inclusionModeDefinition?.namedTypeDefinitions.size>0?e.inclusionModeDefinition?.namedTypeDefinitions.forEach((n,o)=>{const s=this._graphTypeLookup.get(o);if(!s)return l.A.getLogger(this).warn(`A named type, ${o}, was in the inclusion list that wasn't in the data model and will be removed`),void e.inclusionModeDefinition?.namedTypeDefinitions.delete(o);"relationship"===s.type?t.has(o)||(t.add(o),a.push(s)):"entity"===s.type?t.has(o)||(t.add(o),i.push(s)):(l.A.getLogger(this).warn(`A named type, ${o}, was in the inclusion list that wasn't properly modeled and will be removed`),e.inclusionModeDefinition?.namedTypeDefinitions.delete(o))}):(i=e.knowledgeGraph.dataModel.entityTypes??[],a=e.knowledgeGraph.dataModel.relationshipTypes??[]);const n=new k.P({knowledgeGraph:e.knowledgeGraph,inclusionModeDefinition:e.inclusionModeDefinition});this.knowledgeGraph=e.knowledgeGraph,this.memberEntityTypes=i,this.memberRelationshipTypes=a,this.dataManager=n}load(e){const t=async()=>{const e=[],t=[];this.loadLayerAssumingLocalCache(),this._layersLoadedFromAuthoritativeItem()||await(0,v.qN)(this),this.dataManager.inclusionModeDefinition&&(this.dataManager.inclusionModeDefinition.generateAllSublayers=!1),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.forEach(e=>{e.useAllData=!1}),await this._initializeDiagram(),this.layers.forEach(i=>{t.push(i.refreshCachedQueryEngine()),e.push(new Promise(e=>{i.on("layerview-create",()=>{e(null)})}))}),this.tables.forEach(e=>{t.push(e.refreshCachedQueryEngine())}),await Promise.all(t)};return this.addResolvingPromise(new Promise(i=>{(0,$.fetchKnowledgeGraph)(this.url).then(async a=>{a.dataModel.entityTypes?.forEach(e=>{e.name&&this._graphTypeLookup.set(e.name,e)}),a.dataModel.relationshipTypes?.forEach(e=>{e.name&&this._graphTypeLookup.set(e.name,e)});const o=this.linkChart?.linkChartProperties;6===o?.originIdOf("entitiesUrl")&&(this.membershipModified=!1,(0,H.lV)([o.entitiesUrl??"",o.relationshipsUrl??""],this.linkChart?.portalItem?.itemUrl??"").then(e=>{this.linkChart?.linkChartProperties?.setCreationDatesForResources?.(e)},()=>{}),this._originalInclusionList=await n.XW.fetchAndConvertSerializedLinkChart({entitiesUrl:o?.entitiesUrl,relationshipsUrl:o?.relationshipsUrl},{signal:e?.signal}),this._alignLayersDataModelAndInclusionDefinition(a.dataModel),this.initializationLinkChartConfig={layoutSettings:o?.layoutSettings??void 0,layoutMode:(0,N.k5)(o.layoutType)}),this._initializeLayerProperties({knowledgeGraph:a,inclusionModeDefinition:this._originalInclusionList}),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.size||(this.dataManager.inclusionModeDefinition={generateAllSublayers:!1,namedTypeDefinitions:new Map},this.dataManager.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.set(e.name,{useAllData:!0})}),this.dataManager.knowledgeGraph.dataModel.relationshipTypes?.forEach(e=>{e.name&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.set(e.name,{useAllData:!0})}));const{edit:s,fullEdit:r,updateItem:l}=await(0,v.N1)(a.serviceDefinition.serviceItemId,this.url,e);if(this._set("userHasEditingPrivileges",s),this._set("userHasFullEditingPrivileges",r),this._set("userHasUpdateItemPrivileges",l),this.read({dateFieldsTimeReference:a.serviceDefinition.dateFieldsTimeReference},{origin:"service"}),this.dataPreloadedInLocalCache){const e=E.A.getInstance();for(const[t,i]of this.dataManager.inclusionModeDefinition?.namedTypeDefinitions??[])for(const a of i.members?.values()??[]){const i=e.readFromStoreById(`${t}__${a.id}`);i&&(0,h.tE)(this.dataManager.sublayerCaches,t,()=>new Map).set(a.id,i)}await t()}else{const i="geographic-organic-standard"===this.initializationLinkChartConfig?.layoutMode;this.addResolvingPromise(this.dataManager.refreshCacheContent(void 0,!1,i,!0).then(async()=>{(0,p.Te)(e),await t()}))}i(null)}).catch(()=>{})})),Promise.resolve(this)}set initializationInclusionModeDefinition(e){"loaded"!==this.loadStatus&&"failed"!==this.loadStatus?this._set("initializationInclusionModeDefinition",e):l.A.getLogger(this).error("#initializationInclusionModeDefinition","initializationInclusionModeDefinition cannot be changed after the layer is loaded.")}get linkChart(){return this.parent}get sublayerCapabilities(){return(0,v.hZ)(this.knowledgeGraph)}async addRecords(e,t){let i=[];t?.cascadeAddRelationshipEndNodes&&this.dataManager.knowledgeGraph.dataModel&&(i=await(0,N.aq)(e,this.dataManager.knowledgeGraph));const a=e.concat(i).filter(e=>!this.sublayerIdsCache.get(e.typeName)?.has(e.id));a.length>0&&(this.membershipModified=!0),await this._handleNewRecords(a,t)}async createSublayerForNamedType(e){await this.load();const t=this._graphTypeLookup.get(e);if(!t)throw new r.A("knowledge-graph:missing-type","The specified type does not exist in the knowledge graph.");if(this.dataManager.sublayerCaches.has(e))throw new r.A("knowledge-graph:duplicate-type","The specified type already exists as a sublayer.");this.dataManager.sublayerCaches.set(e,new Map),(0,h.tE)(this.sublayerIdsCache,e,()=>new Set);const i=this._createSublayer(t);return"entity"===t.type?this.dataManager.entityTypeNames.add(e):this.dataManager.relationshipTypeNames.add(e),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.set(e,{useAllData:!1,members:new Map}),i.geometryType?this.layers.push(i):this.tables.push(i),await(0,v.qN)(this,[e]),this._refreshNamedTypes(),i}async removeRecords(e,{cascadeRemoveRelationships:t=!0,recalculateLayout:i=!1,overrideMembershipCheck:a=!1}={cascadeRemoveRelationships:!0,recalculateLayout:!1,overrideMembershipCheck:!1}){let n=[];for(const t of e)(a||!1===this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.get(t.typeName)?.useAllData&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.get(t.typeName)?.members?.has(t.id))&&n.push(t);if(t){const e=new Set,t=[];for(const t of n)if(this.dataManager.nodeConnectionsLookup.has(t.id))for(const i of this.dataManager.nodeConnectionsLookup.get(t.id))e.add(i);for(const i of e)if(this.dataManager.memberIdTypeLookup.has(i))for(const e of this.dataManager.memberIdTypeLookup.get(i))this.dataManager.relationshipTypeNames.has(e)&&t.push({id:i,typeName:e});n=n.concat(t)}const o=this._currentLinkChartConfig.layoutSettings?.rootedLayoutSettings?.rootEntities;if(o?.length){const e=new Set(n.map(({id:e})=>e)),t=o.filter(({id:t})=>!e.has(t));if(t.length!==o.length){this._currentLinkChartConfig.layoutSettings.rootedLayoutSettings.rootEntities=t;const e=this.linkChart?.linkChartProperties;e?.layoutSettings?.rootedLayoutSettings&&(e.layoutSettings.rootedLayoutSettings.rootEntities=t)}}this.dataManager.removeFromLayer(n);for(const e of n)this.sublayerIdsCache.get(e.typeName)?.delete(e.id),this.dataManager.relationshipTypeNames.has(e.typeName)?this.relationshipLinkChartDiagramLookup.delete(e.id):this.entityLinkChartDiagramLookup.delete(e.id);const s=i?void 0:this.getCurrentNodeLocations();await this._calculateLayoutWithSublayerTimeInfo(this._currentLinkChartConfig.layoutMode,{layoutSettings:this._currentLinkChartConfig.layoutSettings,lockedEntityLocations:s}),n.length>0&&(this.membershipModified=!0);const r=[];return this.layers.forEach(e=>{r.push(e.refreshCachedQueryEngine())}),await Promise.all(r),this._refreshNamedTypes(),n}async expand(e,t){let i=[];try{const a=await this.dataManager.getConnectedRecordIds(e,t?.relationshipTypeNames,t);i=a.filter(e=>!this.sublayerIdsCache.get(e.typeName)?.has(e.id)),await this._handleNewRecords(i,t),a.length>0&&(this.membershipModified=!0),(0,p.Te)(t?.signal)}catch(e){throw(0,p.zf)(e)&&i.length>0&&await this.removeRecords(i,{overrideMembershipCheck:!0}),e}return{records:i}}loadLayerAssumingLocalCache(){const e=[...this.memberRelationshipTypes,...this.memberEntityTypes];this.layers.length||0===this.originIdOf("tables")?0===this.originIdOf("layers")?this._createSublayers(e,this.layers,e=>!!e.geometryType):this._updateSublayers(e,this.layers):this.layers=new o.A,this.tables.length||0===this.originIdOf("layers")?0===this.originIdOf("tables")?this._createSublayers(e,this.tables,e=>!e.geometryType):this._updateSublayers(e,this.tables):this.tables=new o.A,this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{const i=(0,h.tE)(this.sublayerIdsCache,t,()=>new Set);e.members?.forEach(({id:e,linkChartLocation:a})=>{if(i.add(e),a){const i="coords"in a&&"lengths"in a?a:(0,M.Ux)(a);this.dataManager.relationshipTypeNames.has(t)?this.relationshipLinkChartDiagramLookup.set(e,i):this.entityLinkChartDiagramLookup.set(e,i)}})})}async calculateLinkChartLayout(e="organic-standard",t){const i=[],a=[],n=[];this.dataManager.sublayerCaches.forEach((e,t)=>{this.dataManager.entityTypeNames.has(t)?e.forEach(e=>{i.push({typeName:t,feature:e})}):this.dataManager.relationshipTypeNames.has(t)&&e.forEach(e=>{a.push({typeName:t,feature:e})})}),this.entityLinkChartDiagramLookup=new Map,this.relationshipLinkChartDiagramLookup=new Map;const o=new Map,s=new Map,d=new Map,u=new Map,g=new Uint8Array(i.length),c=new Float64Array(i.length),C=new Float64Array(i.length),b=new Float64Array(i.length),k=new Float64Array(i.length),T=new Uint32Array(a.length),v=new Uint32Array(a.length),E=new Float64Array(a.length),N=new Float64Array(a.length),D=[];let S=!1;const x=new y.A({xmin:-1e-7,ymin:-1e-7,xmax:1e-7,ymax:1e-7});let I,_="organic-standard",R=0,Z=0;const B=A.i6.apply;switch(_="geographic-organic-standard"===e?"organic-standard":e,_){case"organic-standard":I=A.pM.apply;break;case"organic-community":I=A.Tu.apply;break;case"hierarchical-bottom-to-top":I=A.$C.apply;break;case"radial-root-centric":I=A.vJ.apply;break;case"tree-left-to-right":I=A.Xq.apply;break;default:I=A.Wg.apply}let z=!1;const O=new Set(t?.layoutSettings?.rootedLayoutSettings?.rootEntities?.map(({id:e})=>e));i.forEach(({typeName:i,feature:a})=>{if("chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e&&t?.lockedEntityLocations?.has(a.attributes[w.dr])){"geographic-organic-standard"===e&&this.dataManager.geographicLookup.has(i)?g[R]=2:g[R]=0;const n=t.lockedEntityLocations.get(a.attributes[w.dr]);c[R]=n.x,C[R]=n.y}else if("geographic-organic-standard"===e&&this.dataManager.geographicLookup.has(i)){g[R]=2;let e=null;const t=a.attributes[this.dataManager.geographicLookup.get(i).name],n=this.dataManager.geographicLookup.get(i)?.geometryType;switch(n){case"esriGeometryPoint":c[R]=t?.x,C[R]=t?.y;break;case"esriGeometryPolygon":{const i=t?(0,L.Ve)(t):null;e=i?m.A.fromJSON(i):null,null!=e?.x&&null!=e?.y?(c[R]=e.x,C[R]=e.y):g[R]=1;break}case"esriGeometryPolyline":case"esriGeometryMultipoint":e=t?.extent?.center,null!=e?.x&&null!=e?.y?(c[R]=e.x,C[R]=e.y):g[R]=1;break;default:g[R]=1}(null==c[R]||null==C[R]||Number.isNaN(c[R])||Number.isNaN(C[R]))&&(g[R]=1,c[R]=0,C[R]=0)}else if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){!z&&t?.lockedEntityLocations?.has(a.attributes[w.dr])&&(z=!0);const e=t?.timeInfoByTypeName?.get(i),n=e?.startField,o=n&&e?.startField?a.attributes[n]:null;b[R]=o?new Date(o).getTime():NaN;const s=e?.endField,r=s&&e?.endField?a.attributes[s]:null;k[R]=r?new Date(r).getTime():NaN,c[R]=0,C[R]=0,g[R]=1}else g[R]=1,c[R]=0,C[R]=0;O.has(a.attributes[w.dr])&&(g[R]|=4),u.set(a.attributes[w.dr],R),D[R]={feature:a,typeName:i},R++}),z&&l.A.getLogger(this).warn("Locked node locations are not supported for chronological layout at this time. Requested node locations were ignored");let P=!1;const U=new Map;a.forEach(i=>{const a=i.feature.attributes[w.Cz],o=i.feature.attributes[w.KQ],s=u.get(a),r=u.get(o),l=t?.timeInfoByTypeName?.get(i.typeName),h=t?.timeInfoByTypeName?l?.startField:null,d=h?i.feature.attributes[h]:null,p=l?.endField,g=p?i.feature.attributes[p]:null;if(void 0!==s&&void 0!==r){let t=a+"-"+o;"chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e||(t=t+"-"+d+"-"+g);const l=U.get(t),h=l?.has(i.typeName);h||(T[Z]=s,v[Z]=r,"chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e||(E[Z]=d?new Date(d).getTime():NaN,N[Z]=g?new Date(g).getTime():NaN),void 0===l?U.set(t,new Map([[i.typeName,Z]])):l.set(i.typeName,Z),Z++),n.push(i)}else P=!0,this.relationshipLinkChartDiagramLookup.set(a,null)}),P&&l.A.getLogger(this).warn("A relationship is a member of this layer that has either origin or destination entity nodes that are not members. The diagram geometry will be set to null");const j=this._validateOrganicLayoutSettings(e,t?.layoutSettings?.organicLayoutSettings),F=this._convertValidatedOrganicSettingsToCalculationSettings(j);await(0,A.Hh)();let G=1,H=null;if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){let i;({status:G,links:H,graphics:i}=B(()=>t?.signal?.aborted??!1,g,c,C,b,k,T.subarray(0,Z),v.subarray(0,Z),E.subarray(0,Z),N.subarray(0,Z),"chronological-multi-timeline"===e,t?.layoutSettings?.chronologicalLayoutSettings)),0===G&&(this.chronologicalAuxiliaryGraphics=i)}else({status:G,links:H}=I(()=>t?.signal?.aborted??!1,g,c,C,T.subarray(0,Z),v.subarray(0,Z),F.computationBudgetTime,F.idealEdgeLengthMultiplier,F.repulsionRadiusMultiplier));if((0,p.Te)(t?.signal),1===G)throw new r.A("knowledge-graph:layout-failed","Attempting to arrange the records in the specified layout failed");if(2===G)throw(0,p.NK)();for(let e=0;e<D.length;e++){if(C[e]>84.9999?C[e]=84.9999:C[e]<-84.9999&&(C[e]=-84.9999),c[e]>179.9999?c[e]=179.9999:c[e]<-179.9999&&(c[e]=-179.9999),D[e].feature.attributes[w.T1]=new m.A(c[e],C[e]),o.has(D[e].typeName)){const t=o.get(D[e].typeName);t?.set(D[e].feature.attributes[w.dr],D[e].feature)}else{const t=new Map;t.set(D[e].feature.attributes[w.dr],D[e].feature),o.set(D[e].typeName,t)}d.set(D[e].feature.attributes[w.dr],D[e].feature);const t=(0,M.Ux)(D[e].feature.attributes[w.T1]);this.entityLinkChartDiagramLookup.set(D[e].feature.attributes[w.dr],D[e].feature.attributes[w.T1]?t:null);const i=(0,h.tE)(this.dataManager.inclusionModeDefinition.namedTypeDefinitions,D[e].typeName,()=>({useAllData:!1,members:new Map}));(0,h.tE)(i.members,D[e].feature.attributes[w.dr],()=>({id:D[e].feature.attributes[w.dr],linkChartLocation:void 0})).linkChartLocation=D[e].feature.attributes[w.T1];const{x:a,y:n}=D[e].feature.attributes[w.T1];if(S)x.xmin=Math.min(x.xmin,a),x.xmax=Math.max(x.xmax,a),x.ymin=Math.min(x.ymin,n),x.ymax=Math.max(x.ymax,n);else{const e=1e-7;x.xmin=a-e,x.xmax=a+e,x.ymin=n-e,x.ymax=n+e,S=!0}}if(this.linkChartExtent.xmin=x.xmin,this.linkChartExtent.xmax=x.xmax,this.linkChartExtent.ymin=x.ymin,this.linkChartExtent.ymax=x.ymax,!H)throw new r.A("knowledge-graph:layout-failed","Attempting to retrieve link geometry from diagram engine failed");const $=new Map,K=new Map,Q=new Map,V=new Set;for(let i=0;i<n.length;i++){const a=[],o=n[i],r=o.feature.attributes[w.Cz],p=o.feature.attributes[w.KQ];let g=r+"-"+p;if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){const e=t?.timeInfoByTypeName?.get(o.typeName),i=t?.timeInfoByTypeName?e?.startField:null,a=i?o.feature.attributes[i]:null,n=e?.endField;g+="-"+a+"-"+(n?o.feature.attributes[n]:null)}const c=U.get(g).get(o.typeName),y=0===c?0:H?.vertexEndIndex[c-1];if(!V.has(c)){if(V.add(c),2===H.types[c]){const e=[H.vertices[2*y],H.vertices[2*y+1]],t=[H.vertices[2*(y+1)],H.vertices[2*(y+1)+1]],i=[.5*(e[0]+t[0]),.5*(e[1]+t[1])],n=[i[0]-e[0],i[1]-e[1]],o=[i[0]+n[1],i[1]-n[0]],s=[i[0]-n[1],i[1]+n[0]];a.push(e),a.push(o),a.push(t),a.push(s),a.push(e)}else{if(0!==H.types[c]){l.A.getLogger(this).warn("A relationship generated an unsupported link geometry type. It will not be rendered");continue}for(let e=y;e<H.vertexEndIndex[c];e++)a.push([H.vertices[2*e],H.vertices[2*e+1]])}if("chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e){const e=D[u.get(r)]?.feature.attributes[w.T1],t=D[u.get(p)]?.feature.attributes[w.T1];a[0][0]===e.x&&a[0][1]===e.y||(a[0]=[e.x,e.y]),a[a.length-1][0]===t.x&&a[a.length-1][1]===t.y||(a[a.length-1]=[t.x,t.y])}for(let e=1;e<a.length-1;e++)a[e][1]>85.5?a[e][1]=85.5:a[e][1]<-85.5&&(a[e][1]=-85.5),a[e][0]>179.9999?a[e][0]=179.9999:a[e][0]<-179.9999&&(a[e][0]=-179.9999);$.has(g)?$.get(g).push(a):$.set(g,[a])}const m=$.get(g);K.has(g)||(K.set(g,new Map),Q.set(g,new Map));const L=K.get(g),C=Q.get(g);L.has(o.typeName)||(L.set(o.typeName,m.shift()),C.set(o.typeName,0));const b=L.get(o.typeName);C.set(o.typeName,C.get(o.typeName)+1);const k=new f.A({paths:[b]});if(o.feature.attributes[w.T1]=k,s.has(o.typeName)){const e=s.get(o.typeName);e?.set(o.feature.attributes[w.dr],o.feature)}else{const e=new Map;e.set(o.feature.attributes[w.dr],o.feature),s.set(o.typeName,e)}d.set(o.feature.attributes[w.dr],o.feature);const T=(0,M.Ux)(o.feature.attributes[w.T1]);this.relationshipLinkChartDiagramLookup.set(o.feature.attributes[w.dr],o.feature.attributes[w.T1]?T:null);const v=(0,h.tE)(this.dataManager.inclusionModeDefinition.namedTypeDefinitions,o.typeName,()=>({useAllData:!1,members:new Map}));(0,h.tE)(v.members,o.feature.attributes[w.dr],()=>({id:o.feature.attributes[w.dr],linkChartLocation:void 0})).linkChartLocation=T}for(const e of n)e.feature.attributes[w.M1]=Q.get(e.feature.attributes[w.Cz]+"-"+e.feature.attributes[w.KQ])?.get(e.typeName)??null;return this._currentLinkChartConfig={layoutMode:e,layoutSettings:t?.layoutSettings?.clone()},{nodes:o,links:s,idMap:d}}async applyNewLinkChartLayout(e="organic-standard",t){let{lockedNodeLocations:i,lockedEntityLocations:a,rootEntityIds:n,...o}=t??{};!a&&i?((0,s.io)(l.A.getLogger(this),"lockedNodeLocations is deprecated in 5.0. Use lockedEntityLocations instead.",{replacement:"Use lockedEntityLocations instead.",version:"5.0"}),a=i):a&&i&&(0,s.io)(l.A.getLogger(this),"Both lockedNodeLocations (deprecated in 5.0) and lockedEntityLocations are defined. Use lockedEntityLocations only instead.",{replacement:"Use lockedEntityLocations instead.",version:"5.0"});const r=o.layoutSettings?.rootedLayoutSettings?.rootEntities;if(!r&&n){(0,s.io)(l.A.getLogger(this),"rootEntityIds is deprecated in 5.1. Use layoutSettings.rootedLayoutSettings.rootEntities instead.",{replacement:"Use layoutSettings.rootedLayoutSettings.rootEntities instead.",version:"5.1"});const e=[];for(const t of n){const i=this.dataManager.memberIdTypeLookup.get(t),a=Array.from(i??[]).find(e=>this.dataManager.entityTypeNames.has(e));a&&e.push({id:t,typeName:a})}o.layoutSettings=o.layoutSettings??new G,o.layoutSettings.rootedLayoutSettings=o.layoutSettings.rootedLayoutSettings??new F,o.layoutSettings.rootedLayoutSettings.rootEntities=e}else r&&n&&(0,s.io)(l.A.getLogger(this),"Both rootEntityIds (deprecated in 5.1) and layoutSettings.rootedLayoutSettings.rootEntities are defined. Use layoutSettings.rootedLayoutSettings.rootEntities only instead.",{replacement:"Use layoutSettings.rootedLayoutSettings.rootEntities instead.",version:"5.1"});const h=[];await this._calculateLayoutWithSublayerTimeInfo(e,{...o,lockedEntityLocations:a}),this.layers.forEach(e=>{h.push(e.refreshCachedQueryEngine())}),this.membershipModified=!0,await Promise.all(h),this._refreshNamedTypes()}getCurrentNodeLocations(){const e=new Map;for(const[t,i]of this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.entries()??[])this.dataManager.relationshipTypeNames.has(t)||i?.members?.forEach(t=>{const i=t.linkChartLocation;let a;const n=t.id;i&&(a="x"in i?{x:i.x,y:i.y}:{x:i.coords[0],y:i.coords[1]},e.set(n,new m.A({x:a.x,y:a.y})))});return e}async refreshLinkChartCache(e){await this.dataManager.refreshCacheContent(e);const t=[];this.layers.forEach(e=>{t.push(e.refreshCachedQueryEngine())}),await Promise.all(t),this._refreshNamedTypes()}async connectBetweenEntities(e,t){if(!e.length)return{records:[]};let i=[];try{let a=[];for(const e of this.dataManager.relationshipTypeNames){const t=this.sublayerIdsCache.get(e);t&&(a=a.concat(Array.from(t.keys())))}i=await this.dataManager.getRelationshipsBetweenNodes(e,a,t),await this._handleNewRecords(i,t),(0,p.Te)(t)}catch(e){throw(0,p.zf)(e)&&this.removeRecords(i),e}return{records:i}}async connectFromEntities(e,t){if(!e.length)return{records:[]};let i=[];try{let a=[];for(const e of this.dataManager.relationshipTypeNames){const t=this.sublayerIdsCache.get(e);t&&(a=a.concat(Array.from(t.keys())))}let n=[];for(const e of this.dataManager.entityTypeNames){const t=this.sublayerIdsCache.get(e);t&&(n=n.concat(Array.from(t)))}i=await this.dataManager.getRelationshipsFromNodes(e,n,a,t),await this._handleNewRecords(i,t),i.length>0&&(this.membershipModified=!0),(0,p.Te)(t)}catch(e){throw(0,p.zf)(e)&&this.removeRecords(i),e}return{records:i}}getCurrentLayout(){return this._currentLinkChartConfig.layoutMode}async _calculateLayoutWithSublayerTimeInfo(e="organic-standard",t){const i=new Map;this.layers.forEach(e=>{i.set(e.objectType.name,e.timeInfo)}),await this.calculateLinkChartLayout(e,{timeInfoByTypeName:i,...t}),this.linkChart?.handleChronologicalOverlay()}async _handleNewRecords(e,t){const i=new Set,a=[],n=this.layers.concat(this.tables);for(const t of e)this._graphTypeLookup.has(t.typeName)&&(!1===n.some(e=>e.objectType.name===t.typeName)&&(this.dataManager.sublayerCaches.set(t.typeName,new Map),i.add(t.typeName)),(0,h.tE)(this.sublayerIdsCache,t.typeName,()=>new Set).add(t.id),a.push(t));this.dataManager.addToLayer(a);for(const e of i){const t=this._graphTypeLookup.get(e);if(t){const i=this._createSublayer(t);"entity"===t.type?this.dataManager.entityTypeNames.add(e):this.dataManager.relationshipTypeNames.add(e),i.geometryType?this.layers.push(i):this.tables.push(i)}}await(0,v.qN)(this,Array.from(i),t),await this.dataManager.refreshCacheContent(e.map(e=>e.id),void 0,void 0,void 0,t);const o={layoutSettings:this._currentLinkChartConfig.layoutSettings,lockedEntityLocations:new Map};for(const[e,t]of this.entityLinkChartDiagramLookup.entries())t&&o.lockedEntityLocations.set(e,new m.A(t.coords[0],t.coords[1]));await this.applyNewLinkChartLayout(this._currentLinkChartConfig.layoutMode,o)}_createSublayers(e,t,i){e.forEach(e=>{const a=this._createSublayer(e);i(a)&&t.push(a),this._updateSublayerCaches(e)})}_updateSublayers(e,t){t.forEach(t=>{t.parentCompositeLayer=this;const i=e.find(e=>e.type===t.graphType&&e.name===t.graphTypeName);i&&(t.objectType=i,t.read({title:i.name},{origin:"service"}),this._updateSublayerCaches(i))})}_updateSublayerCaches({name:e}){if(!e)return;const t=this.dataManager.sublayerCaches;t.has(e)||t.set(e,new Map)}_layersLoadedFromAuthoritativeItem(){const e=this.originIdOf("layers");return e>=3&&e<7}async _initializeDiagram(){this.initializationLinkChartConfig?this.initializationLinkChartConfig.doNotRecalculateLayout?(this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{e?.members?.forEach(e=>{const i=e.linkChartLocation;let a;const n=e.id;if(!i)return;a="x"in i?{x:i.x,y:i.y}:{x:i.coords[0],y:i.coords[1]};const o=(0,M.Ux)(a);this.dataManager.relationshipTypeNames.has(t)?this.relationshipLinkChartDiagramLookup.set(n,o):this.entityLinkChartDiagramLookup.set(n,o),this.linkChartExtent.xmin>a.x&&(this.linkChartExtent.xmin=a.x),this.linkChartExtent.xmax<a.x&&(this.linkChartExtent.xmax=a.x),this.linkChartExtent.ymin>a.y&&(this.linkChartExtent.ymin=a.y),this.linkChartExtent.ymax<a.y&&(this.linkChartExtent.ymax=a.y)})}),this.memberRelationshipTypes.forEach(e=>{e.name&&this.dataManager.sublayerCaches.get(e.name)?.forEach(e=>{const t=this.relationshipLinkChartDiagramLookup.get(e.attributes[w.Cz]),i=this.relationshipLinkChartDiagramLookup.get(e.attributes[w.KQ]);if(t&&i){const a=(0,M.Ux)(new f.A({paths:[[[t.coords[0],t.coords[1]],[i.coords[0],i.coords[1]]]]}));this.relationshipLinkChartDiagramLookup.set(e.attributes[w.dr],a)}else this.relationshipLinkChartDiagramLookup.set(e.attributes[w.dr],null)})})):await this._calculateLayoutWithSublayerTimeInfo(this.initializationLinkChartConfig.layoutMode,{lockedEntityLocations:this.getCurrentNodeLocations(),...this.initializationLinkChartConfig}):await this._calculateLayoutWithSublayerTimeInfo("organic-standard",{lockedEntityLocations:this.getCurrentNodeLocations()})}_refreshNamedTypes(){for(const e of this.layers)e.emit("refresh",{dataChanged:!0});for(const e of this.tables)e.emit("refresh",{dataChanged:!0})}_validateOrganicLayoutSettings(e,t){const i=e=>"number"==typeof e&&!isNaN(e),a=e=>i(e)&&e>=0,n={};if(!new Set(["organic-standard","organic-community","geographic-organic-standard","chronological-multi-timeline","chronological-mono-timeline"]).has(e)||!t)return n;const{computationBudgetTime:o,autoRepulsionRadius:s,repulsionRadiusMultiplier:r,absoluteIdealEdgeLength:h,multiplicativeIdealEdgeLength:d,idealEdgeLengthType:p}=t;return(e=>i(e)&&e>=1)(o)?n.computationBudgetTime=o:o&&l.A.getLogger(this).warn("Invalid layout computationBudgetTime setting, will revert to default setting"),n.autoRepulsionRadius=s,!s&&(e=>i(e)&&e>=1)(r)?n.repulsionRadiusMultiplier=r:s||(n.autoRepulsionRadius=!0,l.A.getLogger(this).warn("Invalid layout repulsionRadiusMultiplier setting, will revert to default setting")),"geographic-organic-standard"===e&&((e=>Object.values(b).includes(e))(p)?n.idealEdgeLengthType=p:void 0!==p&&l.A.getLogger(this).warn('Invalid layout idealEdgeLengthType setting, will revert to "multiplier" setting'),"absolute-value"===p&&a(h)?n.absoluteIdealEdgeLength=h:"absolute-value"===p&&void 0!==h?l.A.getLogger(this).warn("Invalid layout idealEdgeLength setting, will revert to default setting"):"multiplier"===p&&a(d)?n.multiplicativeIdealEdgeLength=d:"multiplier"===p&&void 0!==d&&l.A.getLogger(this).warn("Invalid layout idealEdgeLength setting, will revert to default setting")),n}_convertValidatedOrganicSettingsToCalculationSettings(e){let t=e.idealEdgeLengthType===b.ABSOLUTE?e.absoluteIdealEdgeLength:e.multiplicativeIdealEdgeLength;return e.idealEdgeLengthType===b.ABSOLUTE&&(void 0===t?t=-1:t*=-1),{computationBudgetTime:e.computationBudgetTime??void 0,repulsionRadiusMultiplier:e.repulsionRadiusMultiplier&&!e.autoRepulsionRadius?e.repulsionRadiusMultiplier:void 0,idealEdgeLengthMultiplier:t}}_createSublayer(e){return new T.A({objectType:e,parentCompositeLayer:this,graphType:e.type})}_handleSublayersChange(e,t){if(t&&(t.forEach(e=>{e.parent=null}),this.removeHandles("sublayers-owner")),e){const t=[];e.forEach(e=>{e.parent=this,t.push(this._createVisibleRefreshHandle(e))}),this.addHandles([...t,e.on("after-add",({item:e})=>{e.parent=this,this.addHandles(this._createVisibleRefreshHandle(e),"sublayers-owner")}),e.on("after-remove",({item:e})=>{e.parent=null})],"sublayers-owner")}}_createVisibleRefreshHandle(e){return(0,u.wB)(()=>e.visible,(t,i)=>{!0===t&&!1===i&&e.emit("refresh",{dataChanged:!0})})}_alignLayersDataModelAndInclusionDefinition(e){const t=new Set((e.entityTypes??[]).map(e=>e.name).concat((e.relationshipTypes??[]).map(e=>e.name))),i=new Set((e.entityTypes??[]).map(e=>e.name)),a=new Set((e.relationshipTypes??[]).map(e=>e.name));if(this.layers){for(const e of this.layers)!e.graphType&&t.has(e.graphTypeName)&&(e.graphType=i.has(e.graphTypeName)?"entity":"relationship");const e=this.layers.filter(e=>t.has(e.graphTypeName)&&("entity"===e.graphType?i.has(e.graphTypeName):a.has(e.graphTypeName)));this.setAtOrigin("layers",e,(0,c.OL)(this.originIdOf("layers")))}else this.layers=new o.A;if(this.layers&&this._originalInclusionList){const e=new Set(this._originalInclusionList.namedTypeDefinitions.keys()),t=this.tables?.map(e=>e.graphTypeName)??[],i=this.layers.map(e=>e.graphTypeName).concat(t);for(const t of i)e.has(t)||this._originalInclusionList.namedTypeDefinitions.set(t,{useAllData:!1,members:new Map});const a=[];for(const e of this._originalInclusionList.namedTypeDefinitions.keys())i.includes(e)||(l.A.getLogger(this).warn(`A named type, ${e}, was in the serialized feature collection but did not have a sublayer config in the item, so will be removed`),a.push(e));for(const e of a)this._originalInclusionList.namedTypeDefinitions.delete(e)}}};(0,a.Cg)([(0,g.MZ)(I.OZ)],Q.prototype,"url",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"dataPreloadedInLocalCache",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"initializationLinkChartConfig",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"membershipModified",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"dataManager",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"initializationInclusionModeDefinition",null),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"knowledgeGraph",void 0),(0,a.Cg)([(0,g.MZ)({type:o.A.ofType(T.A),json:{write:{ignoreOrigin:!0}}})],Q.prototype,"layers",void 0),(0,a.Cg)([(0,g.MZ)({readOnly:!0})],Q.prototype,"linkChart",null),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"entityLinkChartDiagramLookup",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"relationshipLinkChartDiagramLookup",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"linkChartExtent",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"memberEntityTypes",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"memberRelationshipTypes",void 0),(0,a.Cg)([(0,g.MZ)({type:["LinkChartLayer"]})],Q.prototype,"operationalLayerType",void 0),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"sublayerCapabilities",null),(0,a.Cg)([(0,g.MZ)()],Q.prototype,"sublayerIdsCache",void 0),(0,a.Cg)([(0,g.MZ)({type:o.A.ofType(T.A),json:{write:{ignoreOrigin:!0}}})],Q.prototype,"tables",void 0),(0,a.Cg)([(0,g.MZ)({json:{read:!1}})],Q.prototype,"type",void 0),(0,a.Cg)([(0,g.MZ)({readOnly:!0})],Q.prototype,"userHasEditingPrivileges",void 0),(0,a.Cg)([(0,g.MZ)({readOnly:!0})],Q.prototype,"userHasFullEditingPrivileges",void 0),(0,a.Cg)([(0,g.MZ)({readOnly:!0})],Q.prototype,"userHasUpdateItemPrivileges",void 0),(0,a.Cg)([(0,g.MZ)({json:{read:!1}})],Q.prototype,"chronologicalAuxiliaryGraphics",void 0),(0,a.Cg)([(0,g.MZ)((0,K.P6)("dateFieldsTimeReference"))],Q.prototype,"dateFieldsTimeZone",void 0),Q=(0,a.Cg)([(0,g.$K)("esri.layers.LinkChartLayer")],Q);const V=Q}}]);