@arcgis/core 5.2.0-next.155 → 5.2.0-next.156

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 (162) hide show
  1. package/assets/esri/core/workers/RemoteClient.js +1 -1
  2. package/assets/esri/core/workers/chunks/{d994bcf0a65d1c07160f.js → 0320cbd825f9a4222042.js} +1 -1
  3. package/assets/esri/core/workers/chunks/0590857215c547e63b51.js +1 -0
  4. package/assets/esri/core/workers/chunks/08fe248e412bb170210d.js +1 -0
  5. package/assets/esri/core/workers/chunks/0cb50bc2b2125c5fedf2.js +1 -0
  6. package/assets/esri/core/workers/chunks/1201b8c5852830836eac.js +1 -0
  7. package/assets/esri/core/workers/chunks/129e04d24ced77c9bb6d.js +1 -0
  8. package/assets/esri/core/workers/chunks/15e1117a706a98b17ad5.js +1 -0
  9. package/assets/esri/core/workers/chunks/164e74d586297946a717.js +1 -0
  10. package/assets/esri/core/workers/chunks/168a523bdc3653081f8a.js +1 -0
  11. package/assets/esri/core/workers/chunks/{6f4e6022a52de0c54aab.js → 172cfeb5f415e4662432.js} +1 -1
  12. package/assets/esri/core/workers/chunks/1aa4f5394a596e544aeb.js +1 -0
  13. package/assets/esri/core/workers/chunks/22b01fe31bbf0bdc48db.js +1 -0
  14. package/assets/esri/core/workers/chunks/27c2da2e779def2ee08b.js +1 -0
  15. package/assets/esri/core/workers/chunks/{481589c3eddad6e026ad.js → 369780276b2755361f7d.js} +1 -1
  16. package/assets/esri/core/workers/chunks/{2a226b69d38c72a47a08.js → 3914d96147642a9d4b01.js} +1 -1
  17. package/assets/esri/core/workers/chunks/{731018c0deffc41ffc97.js → 3e3e076fa5e8d5d5f33f.js} +1 -1
  18. package/assets/esri/core/workers/chunks/{96b6ea199ad949fef17c.js → 43cf862577bf37344ff4.js} +1 -1
  19. package/assets/esri/core/workers/chunks/4932773663469919d10a.js +1 -0
  20. package/assets/esri/core/workers/chunks/4996869b9cbd8c8ddcfa.js +1 -0
  21. package/assets/esri/core/workers/chunks/4c389472b8cdb0c55154.js +1 -0
  22. package/assets/esri/core/workers/chunks/4e4f747de424941a0bfa.js +1 -0
  23. package/assets/esri/core/workers/chunks/{eb815148ae65388dd733.js → 544070198d2ca556103a.js} +1 -1
  24. package/assets/esri/core/workers/chunks/5736feefa261589b6273.js +1 -0
  25. package/assets/esri/core/workers/chunks/{aeaaff7a4b1a99540f52.js → 5cb26bbaa08114aec5ce.js} +1 -1
  26. package/assets/esri/core/workers/chunks/6f73e41e14817acfaead.js +1 -0
  27. package/assets/esri/core/workers/chunks/{320e5942a098dd104366.js → 74137ffec5265628c33b.js} +1 -1
  28. package/assets/esri/core/workers/chunks/7446d0dfebf93e86c098.js +1 -0
  29. package/assets/esri/core/workers/chunks/{688f2dbf784e66082308.js → 74c866e0b66e61751861.js} +1 -1
  30. package/assets/esri/core/workers/chunks/7711ae5612f685078fc8.js +1 -0
  31. package/assets/esri/core/workers/chunks/{5116b569a8dbda4910c8.js → 784a2fba3e18286958d1.js} +1 -1
  32. package/assets/esri/core/workers/chunks/{f6e62d2d279a328cbed7.js → 7bcedf479b07a4b4a234.js} +1 -1
  33. package/assets/esri/core/workers/chunks/842893e75696428d536f.js +1 -0
  34. package/assets/esri/core/workers/chunks/8e19629899a5becf8e19.js +1 -0
  35. package/assets/esri/core/workers/chunks/950d4578dc450467404c.js +1 -0
  36. package/assets/esri/core/workers/chunks/{68be3fb88ca61f82fb90.js → 95dbbddac6581b9d671f.js} +1 -1
  37. package/assets/esri/core/workers/chunks/{900181f68449d8f82eeb.js → aa1ac7954e4f0fefe15b.js} +1 -1
  38. package/assets/esri/core/workers/chunks/ac24b4370dc7194a3107.js +1 -0
  39. package/assets/esri/core/workers/chunks/ace2e0a9d9013edd8624.js +1 -0
  40. package/assets/esri/core/workers/chunks/b1d5d236d5268fcbc74b.js +1 -0
  41. package/assets/esri/core/workers/chunks/{49ff0985fb307ac193ab.js → b573df59391ca41ee5a7.js} +1 -1
  42. package/assets/esri/core/workers/chunks/bac8c32665e982896ecc.js +1 -0
  43. package/assets/esri/core/workers/chunks/{f3da30d7300b92bd8bb0.js → befa32b9e7b3fbdd431e.js} +1 -1
  44. package/assets/esri/core/workers/chunks/{6c469b43089767176ced.js → c5ed67fdf261cbb1624b.js} +1 -1
  45. package/assets/esri/core/workers/chunks/d9b1aed88b205689cec6.js +1 -0
  46. package/assets/esri/core/workers/chunks/{c598b22f78ccc57f9d6d.js → dfd2dc5cdc97ffba8926.js} +1 -1
  47. package/assets/esri/core/workers/chunks/e1b7806ab3e1967b15f0.js +1 -0
  48. package/assets/esri/core/workers/chunks/eaddffcc7004101fc230.js +1 -0
  49. package/assets/esri/core/workers/chunks/eb2652ec48faa78de3c5.js +1 -0
  50. package/assets/esri/core/workers/chunks/{c62738f84c914671b143.js → f4a7aa3cdbc0c429c359.js} +1 -1
  51. package/assets/esri/themes/base/widgets/_OrientedImageryViewer.scss +4 -0
  52. package/assets/esri/themes/dark/main.css +1 -1
  53. package/assets/esri/themes/light/main.css +1 -1
  54. package/assets/esri/themes/light/view.css +1 -1
  55. package/config.d.ts +2 -0
  56. package/config.js +1 -1
  57. package/core/ObjectPool.js +1 -1
  58. package/core/PooledArray.js +1 -1
  59. package/core/accessorSupport/tracking/SimpleTrackingTarget.js +1 -1
  60. package/geometry/support/buffer/BufferPool.js +1 -1
  61. package/geometry/support/coordsUtils.js +1 -1
  62. package/kernel.js +1 -1
  63. package/layers/AnnotationFeatureLayer.d.ts +2 -2
  64. package/layers/AnnotationFeatureLayer.js +1 -1
  65. package/layers/CatalogLayer.d.ts +2 -2
  66. package/layers/CatalogLayer.js +1 -1
  67. package/layers/DimensionFeatureLayer.d.ts +2 -2
  68. package/layers/DimensionFeatureLayer.js +1 -1
  69. package/layers/FeatureLayer.d.ts +2 -2
  70. package/layers/FeatureLayer.js +1 -1
  71. package/layers/SubtypeGroupLayer.d.ts +2 -2
  72. package/layers/SubtypeGroupLayer.js +1 -1
  73. package/layers/geospatialPDF/GeospatialPDFFrame.js +1 -1
  74. package/layers/geospatialPDF/GeospatialPDFLayerWorker.js +9 -9
  75. package/layers/geospatialPDF/GeospatialPDFWorkerClient.js +1 -1
  76. package/layers/geospatialPDF/LGIDictMapFrame.js +1 -1
  77. package/layers/geospatialPDF/ViewportMeasureFrame.js +1 -1
  78. package/layers/geospatialPDF/geospatialPDFParserUtils.js +1 -1
  79. package/layers/graphics/controllers/FeatureTileController3D.js +1 -1
  80. package/layers/graphics/sources/parquet/FileProvider.js +1 -1
  81. package/layers/mixins/{FeatureLayerReload.d.ts → ReloadableLayer.d.ts} +5 -3
  82. package/layers/mixins/ReloadableLayer.js +2 -0
  83. package/layers/orientedImagery/core/coverageUtils.js +1 -1
  84. package/layers/raster/datasets/BaseRaster.js +1 -1
  85. package/layers/raster/datasets/GeospatialPDFRaster.js +1 -1
  86. package/layers/raster/datasets/ImageAuxRaster.js +1 -1
  87. package/layers/raster/datasets/ImageServerRaster.js +1 -1
  88. package/layers/raster/datasets/MRFRaster.js +1 -1
  89. package/layers/raster/datasets/TIFFRaster.js +1 -1
  90. package/layers/raster/datasets/WCSRaster.js +1 -1
  91. package/layers/raster/formats/ImageCanvasDecoder.js +1 -1
  92. package/layers/raster/formats/RasterCodec.js +1 -1
  93. package/layers/raster/formats/TiffDecoder.js +1 -1
  94. package/layers/raster/formats/Zlib.js +1 -1
  95. package/layers/support/RasterWorker.js +1 -1
  96. package/package.json +2 -2
  97. package/popup/FeatureModel.js +1 -1
  98. package/popup/FeaturesModel.js +1 -1
  99. package/request/process.js +1 -1
  100. package/request/types.d.ts +7 -0
  101. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueBackground.js +1 -1
  102. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueFill.js +1 -1
  103. package/views/3d/analysis/DirectLineMeasurementAnalysisView3D.js +1 -1
  104. package/views/3d/analysis/LineOfSight/LineOfSightItemTool.js +1 -1
  105. package/views/3d/analysis/LineOfSight/LineOfSightPlacementController.js +1 -1
  106. package/views/3d/analysis/LineOfSight/{LineOfSightRootPlugin.js → LineOfSightPlacementRootPlugin.js} +1 -1
  107. package/views/3d/analysis/LineOfSight/LineOfSightTool.js +1 -1
  108. package/views/3d/analysis/Viewshed/ViewshedSubTool.js +1 -1
  109. package/views/3d/analysis/Viewshed/ViewshedTool.js +1 -1
  110. package/views/3d/interactive/editingTools/ManipulatedObject3DGraphic.js +1 -1
  111. package/views/3d/support/MemoryController.js +1 -1
  112. package/views/3d/webgl-engine/effects/RenderPluginManager.js +1 -1
  113. package/views/3d/webgl-engine/effects/geometry/RenderOccluded.js +1 -1
  114. package/widgets/BatchAttributeForm/inputs/support/DynamicChoiceController.js +1 -1
  115. package/widgets/HistogramRangeSlider.d.ts +2 -2
  116. package/widgets/HistogramRangeSlider.js +1 -1
  117. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  118. package/widgets/OrientedImageryViewer.js +2 -2
  119. package/widgets/PanoramicViewer/PanoramicVideoViewerViewModel.js +1 -1
  120. package/widgets/ScaleRangeSlider/ScaleRangeSliderViewModel.d.ts +5 -2
  121. package/widgets/ScaleRangeSlider/ScaleRangeSliderViewModel.js +1 -1
  122. package/widgets/ScaleRangeSlider.js +1 -1
  123. package/widgets/ValuePicker/ValuePickerBaseComponent.d.ts +5 -1
  124. package/widgets/ValuePicker/ValuePickerCollection.d.ts +2 -0
  125. package/widgets/ValuePicker/ValuePickerCombobox.d.ts +7 -1
  126. package/widgets/ValuePicker/ValuePickerLabel.d.ts +7 -1
  127. package/widgets/ValuePicker/ValuePickerSlider.d.ts +2 -0
  128. package/widgets/ValuePicker/ValuePickerSliderVisibleElements.d.ts +5 -1
  129. package/widgets/ValuePicker/ValuePickerVisibleElements.d.ts +5 -1
  130. package/widgets/ValuePicker/types.d.ts +2 -0
  131. package/assets/esri/core/workers/chunks/03261b9451e293a0fac8.js +0 -1
  132. package/assets/esri/core/workers/chunks/0ad0484ffcbe4ad21bd3.js +0 -1
  133. package/assets/esri/core/workers/chunks/19743dedaa40446259ec.js +0 -1
  134. package/assets/esri/core/workers/chunks/1c65ab9ed611c322ce27.js +0 -1
  135. package/assets/esri/core/workers/chunks/1f339247b68b061ab0a4.js +0 -1
  136. package/assets/esri/core/workers/chunks/251921cd10ecfbc89451.js +0 -1
  137. package/assets/esri/core/workers/chunks/3252b1fae363bb0129a0.js +0 -1
  138. package/assets/esri/core/workers/chunks/408e81c8f1eff8a7b379.js +0 -1
  139. package/assets/esri/core/workers/chunks/50036a323c2e7f155311.js +0 -1
  140. package/assets/esri/core/workers/chunks/55dcbf296d8d0092e473.js +0 -1
  141. package/assets/esri/core/workers/chunks/59b216b60464611742d4.js +0 -1
  142. package/assets/esri/core/workers/chunks/5bfea0c55aca826de536.js +0 -1
  143. package/assets/esri/core/workers/chunks/60d3056a31d982c9cad0.js +0 -1
  144. package/assets/esri/core/workers/chunks/6558488ea96620439f34.js +0 -1
  145. package/assets/esri/core/workers/chunks/6aebf7cfd294e88bf926.js +0 -1
  146. package/assets/esri/core/workers/chunks/6b43bb78f9839ed43135.js +0 -1
  147. package/assets/esri/core/workers/chunks/6c83398cf586ecea0eb1.js +0 -1
  148. package/assets/esri/core/workers/chunks/7267b17de212207142c9.js +0 -1
  149. package/assets/esri/core/workers/chunks/88c74f3316f1fc253207.js +0 -1
  150. package/assets/esri/core/workers/chunks/912080c90b5cc2e817cf.js +0 -1
  151. package/assets/esri/core/workers/chunks/a97d85774f9a417202df.js +0 -1
  152. package/assets/esri/core/workers/chunks/aff32980d91dab07dfb7.js +0 -1
  153. package/assets/esri/core/workers/chunks/b1b4066e8d1c0c9656e5.js +0 -1
  154. package/assets/esri/core/workers/chunks/b6ba66a05030d3815dfd.js +0 -1
  155. package/assets/esri/core/workers/chunks/bbec9d2e3b75a5c59681.js +0 -1
  156. package/assets/esri/core/workers/chunks/bf69024804ac51c8f733.js +0 -1
  157. package/assets/esri/core/workers/chunks/c1254cd131a62750ff6f.js +0 -1
  158. package/assets/esri/core/workers/chunks/d938987344bce83cc660.js +0 -1
  159. package/assets/esri/core/workers/chunks/db1ab9b9c8bf5c7635d3.js +0 -1
  160. package/assets/esri/core/workers/chunks/fd9663952d5a94f3a83f.js +0 -1
  161. package/layers/mixins/FeatureLayerReload.js +0 -2
  162. /package/views/3d/analysis/LineOfSight/{lineOfSightPlacementUtils.js → placementUtils.js} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1003],{1003(e,t,i){i.r(t),i.d(t,{default:()=>me});var a=i(49186),r=i(32198),s=i(91429),n=i(49859),l=i(68197),o=i(5443),f=i(16930),u=i(73444),h=i(94778),c=i(14140);function p(e){return["x","e","east","long","longitude"].includes(e.toLowerCase())}function d(e){return["y","n","west","lat","latitude"].includes(e.toLowerCase())}function m(e){let{axes:t}=e.domain,i=Object.keys(t),a=[],r=[],s=-1,n=-1,l=[];for(let e=0;e<i.length;e++){let o=i[e];p(o)?s=e:d(o)&&(n=e);let f=t[o],u=[];if("values"in f){f.values.forEach(e=>u.push("string"==typeof e?new Date(e).getTime():e));let e=u[1]-u[0];a.push([u[0]-.5*e,u[u.length-1]+.5*e]),r.push(e)}else{let{start:e,stop:t,num:i}=f,s=(t-e)/(i-1);a.push([e-.5*s,t+.5*s]),r.push(s);for(let t=0;t<i;t++)u.push(e+s*t)}l.push({name:o,values:u,extent:[u[0],u[u.length-1]]})}s>-1&&-1===n?n=+(0===s):n>-1&&-1===s?s=+(0===n):-1===n&&-1===s&&(s=0,n=1),l=l.filter((e,t)=>t!==s&&t!==n);let{referencing:u}=e.domain,h=u.find(e=>e.coordinates.includes(i[s])).system.id,c=h?.slice(h.lastIndexOf("/")+1),m=null==c||"CRS84"===c?4326:Number(c),g=new f.A({wkid:m}),[y,x]=a[s],[w,I]=a[n],b=new o.A({xmin:y,xmax:x,ymin:w,ymax:I,spatialReference:g});return{width:Math.round(b.width/r[s]),height:Math.round(b.height/r[n]),extent:b,dimensions:l}}function g(e){let t=(0,u.lR)();return t?e[t]??Object.values(e)[0]:Object.values(e)[0]}function y(){return Math.round(255*Math.random())}function x(e){let t={},{parameters:i}=e;if(!i)return t;for(let[e,a]of Object.entries(i)){let{type:i,description:r,unit:s,categoryEncoding:n,observedProperty:o}=a;if("Parameter"===i&&(t[e]={},r&&(t[e].description=g(r)),s&&(t[e].unit=s.label?g(s.label):null,t[e].symbol=s.symbol?.value),n)){let i=Object.entries(n).map((e,t)=>({OID:t,Value:Number(e[1]),ClassName:e[0].slice(e[0].lastIndexOf("/")+1),Count:1})),a=!1;o?.categories?.length&&(o.categories.forEach(e=>{if(!e.id)return;let t=e.id.slice(e.id.lastIndexOf("/")+1),r=i.find(e=>e.ClassName===t);if(r&&(r.Label=e.label?g(e.label):null,e.preferredColor)){let t=l.A.fromHex(e.preferredColor);t&&(a=!0,r.Red=t.r,r.Green=t.g,r.Blue=t.b)}}),a&&i.forEach(e=>{e.Red??(e.Red=y(),e.Green=y(),e.Blue=y())}));let r={objectIdFieldName:"",fields:[{name:"OID",type:"esriFieldTypeOID",alias:"OID",domain:null},{name:"Value",type:"esriFieldTypeInteger",alias:"Value",domain:null},{name:"Count",type:"esriFieldTypeDouble",alias:"Count",domain:null},{name:"ClassName",type:"esriFieldTypeString",alias:"ClassName",domain:null,length:50},{name:"Label",type:"esriFieldTypeString",alias:"Label",domain:null,length:50}],features:i.map(e=>({attributes:e}))};a&&r.fields.push({name:"Red",type:"esriFieldTypeInteger",alias:"Red",domain:null},{name:"Green",type:"esriFieldTypeInteger",alias:"Green",domain:null},{name:"Blue",type:"esriFieldTypeInteger",alias:"Blue",domain:null}),t[e].attributeTable=r}}return t}function w(e){let t=Number.MAX_VALUE,i=-Number.MAX_VALUE;for(let a=0;a<e.length;a++){let r=e[a];null!=r&&(r<t&&(t=r),r>i&&(i=r))}return(0,h.X1)(t,i)}function I(e,t,i){let a=e.map((e,i)=>({name:e,count:t[i]})).sort((e,t)=>e.name>t.name?-1:1),r=(e=>t=>e*=t.count)(1),s=[...a.slice(1),{name:"",count:1}].reverse().map(r).reverse(),n=0;for(let r=e.length-1;r>=0;r--){let l=a.findIndex(({name:t})=>t===e[r]);n+=s[l]*(i%t[r]),i=Math.floor(i/t[r])}return n}var b=i(17676),v=i(4366),C=i(47520),S=i(51927),T=i(45617),A=i(87186);let R=class extends n.A{constructor(){super(...arguments),this.datasetFormat="MEMORY",this.preGenerateTiles=!0,this.source=null}get url(){return""}fetchRawTile(e,t,i,a={}){if(!this._pixelBlockTiles){let{rasterInfo:r}=this,[s,n]=r.storageInfo.tileInfo.size,{sliceId:l}=a,{pixelBlocks:o}=this.source,f={pixelBlock:null==l?o[0]:o[l],useBilinear:"thematic"!==r.dataType,tileSize:{width:s,height:n},level:e,row:t,col:i},u=this.rasterJobHandler?this.rasterJobHandler.clipTile(f,a):(0,C.J$)(f);return Promise.resolve(u)}let r=this._pixelBlockTiles.get(`${e}/${t}/${i}`);return Promise.resolve(r)}async _open(e){let t=this.source,{pixelBlocks:i,attributeTable:a,statistics:r,histograms:s,name:n,nativeExtent:l,transform:u,colormap:h}=t,c=i[0],{width:p,height:d,pixelType:m}=c,g=t.extent??new o.A({xmin:-.5,ymin:.5,xmax:p-.5,ymax:d-.5,spatialReference:new f.A({wkid:3857})}),y=t.isPseudoSpatialReference??!t.extent,x={x:g.width/p,y:g.height/d},w={...t.keyProperties};t.dataType&&(w.DataType=t.dataType),t.bandInfos&&(w.BandProperties=t.bandInfos.map(e=>e.toJSON())),a&&(w.DataType="Thematic");let I=new A.A({width:p,height:d,pixelType:m,extent:g,nativeExtent:l,attributeTable:a,colormap:h,transform:u,pixelSize:x,spatialReference:g.spatialReference,bandCount:c.pixels.length,keyProperties:w,multidimensionalInfo:t.multidimensionalInfo,statistics:r,isPseudoSpatialReference:y,histograms:s});this.ioConfig.skipMapInfo&&this.updateImageSpaceRasterInfo(I),this.createRemoteDatasetStorageInfo(I,512,512),this._set("rasterInfo",I),this.updateTileInfo(),I.multidimensionalInfo?await this._buildMDimStats(t.pixelBlocks,I.multidimensionalInfo):this.preGenerateTiles&&await this._buildInMemoryRaster(c,{width:512,height:512},e),I.multidimensionalInfo||(this.source=null),this.datasetName=n}async _buildInMemoryRaster(e,t,i){let{rasterInfo:r}=this,s=r.storageInfo.maximumPyramidLevel??0,n="thematic"!==r.dataType,l=this.rasterJobHandler?this.rasterJobHandler.split({pixelBlock:e,tileSize:t,maximumPyramidLevel:s,useBilinear:n},i):Promise.resolve((0,C.lD)(e,t,s,n)),o=null!=r.statistics,f=null!=r.histograms,u=this.ioConfig.skipStatistics||o?Promise.resolve({statistics:null,histograms:null}):this.rasterJobHandler?this.rasterJobHandler.estimateStatisticsHistograms({pixelBlock:e},i):Promise.resolve((0,S.f4)(e)),h=await(0,b.Lx)([l,u]);if(!h[0].value&&h[1].value)throw new a.A("inmemory-raster:open","failed to build in memory raster");this._pixelBlockTiles=h[0].value,o||(r.statistics=h[1].value?.statistics),f||(r.histograms=h[1].value?.histograms)}async _buildMDimStats(e,t,i){for(let a=0;a<t.variables.length;a++){let r=t.variables[a];if(r.statistics)continue;let s=r.dimensions.map(e=>new T.A({variableName:r.name,dimensionName:e.name,values:[e.values?.[0]??e.extent?.[0]],isSlice:!0})),n=(0,v.NG)(s,t),l=null==n?null:e[n];if(null==l)continue;let o=this.rasterJobHandler?await this.rasterJobHandler.computeStatisticsHistograms({pixelBlock:l},i):(0,S.eH)(l);r.statistics=o.statistics,r.histograms||=o.histograms}}};(0,r.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],R.prototype,"datasetFormat",void 0),(0,r.Cg)([(0,s.MZ)({constructOnly:!0})],R.prototype,"preGenerateTiles",void 0),(0,r.Cg)([(0,s.MZ)()],R.prototype,"source",void 0),(0,r.Cg)([(0,s.MZ)()],R.prototype,"url",null),R=(0,r.Cg)([(0,s.$K)("esri.layers.raster.datasets.InMemoryRaster")],R);const M=R;var _=i(22671);let O=class extends n.A{constructor(){super(...arguments),this.datasetFormat="CovJSON"}fetchRawTile(e,t,i,a={}){return this._inMemoryRaster.fetchRawTile(e,t,i,a)}async _open(e){let{extent:t,pixelBlocks:i,multidimensionalInfo:a,attributeTable:r,bandNames:s}=await this._fetchData(e),{statistics:n,histograms:l}=(0,S.eH)(i[0]),o=s?.map(e=>({BandName:e})),f={DataType:r?"Thematic":a?"Scientific":"Generic",BandProperties:o},u=new M({source:{extent:t,pixelBlocks:i,attributeTable:r?_.A.fromJSON(r):null,multidimensionalInfo:a,statistics:n,histograms:l,keyProperties:f,isPseudoSpatialReference:!1}});await u.open(),this._inMemoryRaster=u;let h=this.source?"":this.url.slice(this.url.lastIndexOf("/")+1);this._set("datasetName",h.slice(0,h.indexOf("."))),this._set("rasterInfo",u.rasterInfo)}async _fetchData(e){let t=this.source??(await this.request(this.url,{signal:e?.signal})).data,i="imagery-tile-layer:open-coverage-json";if("coverage"!==t.type?.toLowerCase()||"grid"!==t.domain?.domainType?.toLowerCase())throw new a.A(i,"Only coverage with Grid domain type is supported");if(!t.ranges)throw new a.A(i,"Missing ranges in the grid coverage data");if(!t.domain.referencing?.length)throw new a.A(i,"Missing domain referencing in the grid coverage data");let r=Object.values(t.ranges);for(let e=0;e<r.length;e++){let{axisNames:t,shape:s,type:n,values:l}=r[e];if(!("ndarray"===n.toLowerCase()&&l?.length&&t?.length&&s?.length))throw new a.A(i,"Only ranges with valid NdArray, axisNames, shape, and inline values are supported");if(!p(t[t.length-1])||!d(t[t.length-2]))throw new a.A(i,"Only row-major ordered pixel values are supported. X axis must be the last axis.")}return function(e){let{width:t,height:i,extent:a,dimensions:r}=m(e),{ranges:s}=e,n=Object.keys(s).sort((e,t)=>e<t?-1:1),l=[];for(let e=0;e<n.length;e++){let t=n[e];r?.length&&l.push({name:t,dimensions:r})}let o=x(e);l.forEach(e=>o[e.name]&&Object.assign(e,o[e.name]));let f=l.length?{variables:l}:void 0,u=[];for(let e=0;e<n.length;e++){let{values:a,dataType:l,axisNames:o,shape:f}=s[n[e]],h=f.length>2?e*f.slice(0,-2).reduce((e,t)=>e*t):0,p=o.slice(0,-2),d=f.slice(0,-2),m="float"===l?"f32":w(a),g=t*i,y=a.length/g;for(let s=0;s<y;s++){let n=c.A.createEmptyBand(m,g),l=new Uint8Array(g).fill(255),o=!1,f=s*g;for(let e=0;e<g;e++){let t=a[f+e];null==t?(l[e]=0,o=!0):n[e]=t}if(0===e||r?.length){let e=new c.A({width:t,height:i,mask:o?l:null,pixels:[n],pixelType:m});e.updateStatistics(),r?.length?u[I(p,d,s)+h]=e:u.push(e)}else{let e=u[s];e.pixels.push(n),o?e.mask&&=c.A.combineBandMasks([e.mask,l]):e.mask=o?l:null}}}return{extent:a,pixelBlocks:u,multidimensionalInfo:f,attributeTable:Object.values(o).find(e=>e.attributeTable)?.attributeTable,bandNames:f?void 0:n}}(t)}};(0,r.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],O.prototype,"datasetFormat",void 0),(0,r.Cg)([(0,s.MZ)({constructOnly:!0})],O.prototype,"source",void 0),O=(0,r.Cg)([(0,s.$K)("esri.layers.raster.datasets.CovJSONRaster")],O);const k=O;var F=i(4576),B=i(21325),P=i(330),D=i(43163);function N(e,t){if(!e||!t)return null;let i=[];for(let a=0;a<e.length;a++)i.push(e[a]),i.push(t[a]);return i}function E(e){if(!e)return null;let t=Number(e);if(!isNaN(t)&&0!==t)return new f.A({wkid:t});if(e=String(e).trim(),(0,B.jp)(e))return new f.A({wkt2:e});let i=e.toUpperCase();if(i.startsWith("COMPD_CS")){if(!i.includes("VERTCS")||!i.includes("GEOGCS")&&!i.startsWith("PROJCS"))return null;let a=i.indexOf("VERTCS"),r=i.indexOf("PROJCS"),s=r>-1?r:i.indexOf("GEOGCS");if(-1===s)return null;let n=e.slice(s,e.lastIndexOf("]",a)+1).trim(),l=e.slice(a,e.lastIndexOf("]")).trim();t=L(n);let o=t?new f.A({wkid:t}):new f.A({wkt:n}),u=L(l);return u&&(o.vcsWkid=u),o}return i.startsWith("GEOGCS")||i.startsWith("PROJCS")?(t=L(e),0===t?new f.A({wkt:e}):new f.A({wkid:t})):null}function L(e){let t=e.replaceAll("]","[").replaceAll('"',"").split("[").map(e=>e.trim()).filter(e=>""!==e),i=t[t.length-1].split(","),a=i[0]?.toLowerCase();if(("epsg"===a||"esri"===a)&&e.endsWith('"]]')){let e=Number(i[1]);if(!isNaN(e)&&0!==e)return e}return 0}function H(e){if("pamdataset"!==e?.documentElement.tagName?.toLowerCase())return{};let t={spatialReference:null,transform:null,metadata:{},rasterBands:[],statistics:null,histograms:null};e.documentElement.childNodes.forEach(e=>{if(1===e.nodeType)if((0,P.g7)(e,"SRS")){if(!t.spatialReference){let i=(0,P.mX)(e);t.spatialReference=E(i)}}else if((0,P.g7)(e,"Metadata"))if("xml:ESRI"===e.getAttribute("domain")){let{spatialReference:i,transform:a}=function(e){let t=(0,P.V6)(e,"GeodataXform"),i=E((0,P.v7)(t,"SpatialReference/WKID")||(0,P.mX)(t,"SpatialReference/WKT"));if("typens:PolynomialXform"!==t.getAttribute("xsi:type"))return{spatialReference:i,transform:null};let a=(0,P.v7)(t,"PolynomialOrder")??1,r=(0,P.Ui)(t,"CoeffX/Double"),s=(0,P.Ui)(t,"CoeffY/Double"),n=(0,P.Ui)(t,"InverseCoeffX/Double"),l=(0,P.Ui)(t,"InverseCoeffY/Double"),o=N(r,s),f=N(n,l);return{spatialReference:i,transform:o&&f&&o.length&&f.length?new D.A({spatialReference:i,polynomialOrder:a,forwardCoefficients:o,inverseCoefficients:f}):null}}(e);t.transform=a,t.spatialReference||=i}else(0,P.IC)(e,"MDI").forEach(e=>t.metadata[e.getAttribute("key")]=(0,P.mX)(e));else if((0,P.g7)(e,"PAMRasterBand")){let i=function(e){let t,i,a,r,s=(0,P.v7)(e,"NoDataValue"),n=(0,P.V6)(e,"Histograms/HistItem"),l=(0,P.v7)(n,"HistMin"),o=(0,P.v7)(n,"HistMax"),f=(0,P.v7)(n,"BucketCount"),u=(0,P.mX)(n,"HistCounts")?.split("|").map(e=>Number(e));(0,P.IC)(e,"Metadata/MDI").forEach(e=>{let s=Number(e.textContent??e.nodeValue);switch(e.getAttribute("key").toUpperCase()){case"STATISTICS_MINIMUM":t=s;break;case"STATISTICS_MAXIMUM":i=s;break;case"STATISTICS_MEAN":a=s;break;case"STATISTICS_STDDEV":r=s}});let h=(0,P.v7)(e,"Metadata/SourceBandIndex");return{noDataValue:s,histogram:u?.length&&null!=l&&null!=o?{min:l,max:o,size:f||u.length,counts:u}:null,sourceBandIndex:h,statistics:null!=t&&null!=i?{min:t,max:i,avg:a,stddev:r}:null}}(e);null!=i.sourceBandIndex&&null==t.rasterBands[i.sourceBandIndex]?t.rasterBands[i.sourceBandIndex]=i:t.rasterBands.push(i)}});let i=t.rasterBands;return i.length&&(t.statistics=i[0].statistics?i.map(e=>e.statistics).filter(F.Ru):null,t.histograms=i[0].histogram?i.map(e=>e.histogram).filter(F.Ru):null),t}var z=i(85951),J=i(96381);let U=class extends n.A{set rasterJobHandler(e){this._set("rasterJobHandler",e),this._inMemoryRaster&&(this._inMemoryRaster.rasterJobHandler=e)}fetchRawTile(e,t,i,a={}){if(this._imageBlob){let{blockWidth:a,blockHeight:r}=this.rasterInfo.storageInfo;return this.decodePixelBlock(this._imageBlob,{tileSize:[a,r],tileIndex:[e,t,i],canvasUsage:"canvas-only",cloneSource:!0,skipStatistics:!0})}return this._inMemoryRaster?this._inMemoryRaster.fetchRawTile(e,t,i,a):Promise.resolve(null)}async _open(e){let t=await this._fetchData(e);if(null==t)throw new a.A("image-aux-raster:open","the data cannot be decoded");let{spatialReference:i,statistics:r,histograms:s,transform:n}=await this._fetchAuxiliaryData(e),l=!i;l&&(i=new f.A({wkid:3857})),s?.length&&null==r&&(r=(0,S.Pg)(s));let{width:u,height:h,pixelBlock:c}=t,p=new o.A({xmin:-.5,ymin:.5-h,xmax:u-.5,ymax:.5,spatialReference:i}),d=n?n.forwardTransform(p):p,m=!0;if(n){let e=n.forwardCoefficients;m=e&&0===e[1]&&0===e[2],m&&(n=null,p=d)}if(!c){let e=new A.A({width:u,height:h,bandCount:3,pixelType:"u8",extent:d,nativeExtent:p,transform:n,pixelSize:{x:d.width/u,y:d.height/h},spatialReference:d.spatialReference,keyProperties:{DataType:"Processed"}});return this.ioConfig.skipMapInfo&&this.updateImageSpaceRasterInfo(e),this.createRemoteDatasetStorageInfo(e,512,512),this._set("rasterInfo",e),void this.updateTileInfo()}let{rasterJobHandler:g,ioConfig:y}=this,x=new M({preGenerateTiles:!1,rasterJobHandler:g,source:{extent:d,nativeExtent:p,transform:n,pixelBlocks:[c],statistics:r,histograms:s,keyProperties:{DataType:"Processed"},isPseudoSpatialReference:l},ioConfig:{...y,sampling:"closest",skipStatistics:!0}});await x.open(),x.source=null,this._set("rasterInfo",x.rasterInfo),this._inMemoryRaster=x}async _fetchData(e){let{data:t}=await this.request(this.url,{responseType:"array-buffer",signal:e?.signal}),i=(0,J.g)(t);if("jpg"!==i&&"png"!==i&&"gif"!==i&&"bmp"!==i)throw new a.A("image-aux-raster:open","the data is not a supported format");if(this._set("datasetFormat",i.toUpperCase()),"jpg"===i){let e=(0,z.R)(t);if(null==e)throw new a.A("image-aux-raster:open","the data is not a supported format");return this._imageBlob=t,e}try{let e=await this.decodePixelBlock(t,{format:i,canvasUsage:"canvas-only",cloneSource:!0,skipStatistics:!0});return this._imageBlob=t,e?{width:e.width,height:e.height,pixelBlock:e}:null}catch{let e=await this.decodePixelBlock(t,{format:i,canvasUsage:"no-canvas",skipStatistics:!0});return e?{width:e.width,height:e.height,pixelBlock:e}:null}}async _fetchAuxiliaryData(e){let t=e?.signal,{skipExtensions:i=[],skipMapInfo:a}=this.ioConfig,r=a||i.includes("aux.xml")?null:this.request(this.url+".aux.xml",{responseType:"xml",signal:t}),s=this.datasetFormat,n="JPG"===s?"jgw":"PNG"===s?"pgw":"BMP"===s?"bpw":null,l=n&&i.includes(n)?null:this.request(this.url.slice(0,this.url.lastIndexOf("."))+"."+n,{responseType:"text",signal:t}),o=await(0,b.Lx)([r,l]);if(t?.aborted)throw(0,b.NK)();let f=H(o[0].value?.data);if(!f.transform){let e=o[1].value?o[1].value.data.split("\n").slice(0,6).map(e=>Number(e)):null;f.transform=6===e?.length?new D.A({forwardCoefficients:[e[4],e[5],e[0],-e[1],e[2],-e[3]]}):null}return f}};(0,r.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],U.prototype,"datasetFormat",void 0),(0,r.Cg)([(0,s.MZ)()],U.prototype,"rasterJobHandler",null),U=(0,r.Cg)([(0,s.$K)("esri.layers.raster.datasets.ImageAuxRaster")],U);const G=U;var q=i(97768),j=i(84952),W=i(86738),V=i(75414),Z=i(20223),X=i(87045),$=i(25943),Y=i(82371);let K=class extends n.A{constructor(){super(...arguments),this._levelOffset=0,this._tilemapCache=null,this._slices=null,this.datasetFormat="RasterTileServer",this.tileType=null}async fetchRawTile(e,t,i,a={}){let{storageInfo:r,extent:s}=this.rasterInfo,{transposeInfo:n}=r,l=null!=n&&!!a.transposedVariableName;if(this._slices&&!l&&null==a.sliceId)return null;let o,f,u=l?0:r.maximumPyramidLevel-e+this._levelOffset,h=`${this.url}/tile/${u}/${t}/${i}`,c={...this._slices?l?{variable:a.transposedVariableName}:{sliceId:a.sliceId||0}:null,...a.refreshParameters};if(r.isBsqTile){let e=(a.bandIds?.length?a.bandIds:[0,1,2]).map(e=>this.request(h,{query:{...c,bandId:e},responseType:"array-buffer",signal:a.signal})),t=await Promise.all(e),i=t.map(e=>e.data.byteLength).reduce((e,t)=>e+t),r=new Uint8Array(i);f=[];let s=0;for(let{data:e}of t)f.push(s),r.set(new Uint8Array(e),s),s+=e.byteLength;o=r.buffer}else o=(await this.request(h,{query:c,responseType:"array-buffer",signal:a.signal})).data;if(!o)return null;let{tileInfo:p}=r,d=l?n.tileSize:p.size,m=/^(mixed|jp)/i.test(p.format),g=await this.decodePixelBlock(o,{width:d[0],height:d[1],planes:f?.length,offsets:f,pixelType:null,isPoint:"Elevation"===this.tileType,returnInterleaved:l,noDataValue:this.rasterInfo.noDataValue,applyJpegMask:m});if(null==g)return null;let y=r.blockBoundary[e];if("jpg"!==r.compression||i>y.minCol&&i<y.maxCol&&t>y.minRow&&t<y.maxRow)return g;let{origin:x,blockWidth:w,blockHeight:I}=r,{x:b,y:v}=this.getPyramidPixelSize(e),S=Math.round((s.xmin-x.x)/b)%w,T=Math.round((s.xmax-x.x)/b)%w||w,A=Math.round((x.y-s.ymax)/v)%I,R=Math.round((x.y-s.ymin)/v)%I||I,M=i===y.minCol?S:0,_=t===y.minRow?A:0,O=i===y.maxCol?T:w,k=t===y.maxRow?R:I;return(0,C.z$)(g,{x:M,y:_},{width:O-M,height:k-_}),g}getSliceIndex(e){if(!this._slices||null==e||0===e.length)return null;let t=e;for(let e=0;e<this._slices.length;e++){let i=this._slices[e].multidimensionalDefinition;if(i.length===t.length&&!i.some(e=>{let i=t.find(t=>e.variableName===t.variableName&&t.dimensionName===e.dimensionName);return!i||(Array.isArray(e.values[0])?`${e.values[0][0]}-${e.values[0][1]}`:e.values[0])!==(Array.isArray(i.values[0])?`${i.values[0][0]}-${i.values[0][1]}`:i.values[0])}))return e}return null}async fetchVariableStatisticsHistograms(e,t){let i=this.request(this.url+"/statistics",{query:{variable:e,f:"json"},signal:t}).then(e=>e.data?.statistics),a=this.request(this.url+"/histograms",{query:{variable:e,f:"json"},signal:t}).then(e=>e.data?.histograms),r=await Promise.all([i,a]);return r[0]&&r[0].forEach(e=>{e.avg=e.mean,e.stddev=e.standardDeviation}),r[1]?.[0]?.counts?.length||(r[1]=null),{statistics:r[0]||null,histograms:r[1]||null}}async computeBestPyramidLevelForLocation(e,t={}){if(!this._tilemapCache)return 0;let i=this.identifyPixelLocation(e,0,t.datumTransformation);if(null===i)return null;let a=0,{maximumPyramidLevel:r}=this.rasterInfo.storageInfo,s=r-a+this._levelOffset,n=i.srcLocation;for(;s>=0;){try{if("available"===await this._tilemapCache.fetchAvailability(s,i.row,i.col,t))break}catch{}if(s--,a++,i=this.identifyPixelLocation(n,a,t.datumTransformation),null===i)return null}return-1===s||null==i?null:a}async _open(e){let t=e?.signal,i=this.sourceJSON?{data:this.sourceJSON}:await this.request(this.url,{query:{f:"json"},signal:t});i.ssl&&(this.url=this.url.replace(/^http:/i,"https:"));let r=i.data;if(this.sourceJSON=r,!r)throw new a.A("imageserverraster:open","cannot initialize tiled image service, missing service info");if(!r.tileInfo)throw new a.A("imageserverraster:open","use ImageryLayer to open non-tiled image services");this._fixScaleInServiceInfo();this.tileType=r.cacheType,this.tileType??=["jpg","jpeg","png","png8","png24","png32","mixed"].includes(r.tileInfo.format.toLowerCase())?"Map":"lerc"===r.tileInfo.format.toLowerCase()?"Elevation":"Raster",this.datasetName=r.name?.slice(r.name.indexOf("/")+1)??"";let s=this.rasterInfo??await this._fetchRasterInfo({signal:t});if(null==s)throw new a.A("image-server-raster:open","cannot initialize image service");(0,Y.E9)(s,r);let n="Map"===this.tileType?function(e,t){if(!e)return null;let{minScale:i,maxScale:a,minLOD:r,maxLOD:s}=t;if(null!=r&&null!=s)return X.A.fromJSON({...e,lods:e.lods.filter(({level:e})=>null!=e&&e>=r&&e<=s)});if(0!==i&&0!==a){let t=e=>Math.round(1e4*e)/1e4,r=i?t(i):1/0,s=a?t(a):-1/0;return X.A.fromJSON({...e,lods:e.lods.filter(e=>{let i=t(e.scale);return i<=r&&i>=s})})}return X.A.fromJSON(e)}(r.tileInfo,r):X.A.fromJSON(r.tileInfo);(0,q.Lw)(n);let[l,o]=this._computeMinMaxLOD(s,n),{extent:f,pixelSize:u}=s,h=.001*Math.min(u.x,u.y);(u.x!==u.y||Math.abs(l.resolution-u.x)>h)&&(u.x=u.y=l.resolution,s.width=Math.ceil((f.xmax-f.xmin)/u.x-.1),s.height=Math.ceil((f.ymax-f.ymin)/u.y-.1));let c=l.level-o.level,[p,d]=n.size,m=[],g=[],{lods:y}=n;y.forEach((e,t)=>{e.level>=o.level&&e.level<=l.level&&m.push({x:e.resolution,y:e.resolution}),t<y.length-1&&g.push(Math.round(10*e.resolution/y[t+1].resolution)/10)}),m.sort((e,t)=>e.x-t.x);let x,w=this.computeBlockBoundary(f,p,d,n.origin,m,c),I=m.length>1?m.slice(1):null;r.transposeInfo&&(x={tileSize:[r.transposeInfo.rows,r.transposeInfo.cols],packetSize:s.keyProperties?._yxs.PacketSize??0});let b=g.length<=1||g.length>=3&&g.slice(0,-1).every(e=>e===g[0])?g[0]??2:Math.round(10/(o.resolution/l.resolution)**(-1/c))/10,v=!!r.bsq&&"Raster"===this.tileType;if(s.storageInfo=new Z.A({blockWidth:n.size[0],blockHeight:n.size[1],pyramidBlockWidth:n.size[0],pyramidBlockHeight:n.size[1],pyramidResolutions:I,pyramidScalingFactor:b,compression:n.format,origin:n.origin,firstPyramidLevel:1,maximumPyramidLevel:c,tileInfo:n,isBsqTile:v,transposeInfo:x,blockBoundary:w}),function(e){let{extent:t,spatialReference:i}=e;t.xmin>-1&&t.xmax>181&&i?.wkid&&i.isGeographic&&(e.nativeExtent=e.extent,e.transform=new V.A,e.extent=e.transform.forwardTransform(t))}(s),this._set("rasterInfo",s),r.capabilities.toLowerCase().includes("tilemap")){let e={tileInfo:s.storageInfo.tileInfo,parsedUrl:(0,j.An)(this.url),url:this.url,tileServers:[]};this._tilemapCache=new $.d({layer:e})}}async _fetchRasterInfo(e){let t=this.sourceJSON;if("Map"===this.tileType){let e=t.fullExtent||t.extent,i=Math.ceil((e.xmax-e.xmin)/t.pixelSizeX-.1),a=Math.ceil((e.ymax-e.ymin)/t.pixelSizeY-.1),r=f.A.fromJSON(t.spatialReference||e.spatialReference),s=new W.A({x:t.pixelSizeX,y:t.pixelSizeY,spatialReference:r});return new A.A({width:i,height:a,bandCount:3,extent:o.A.fromJSON(e),spatialReference:r,pixelSize:s,pixelType:"u8",statistics:null,keyProperties:{DataType:"processed"}})}let i={...e,query:{...this.ioConfig.customFetchParameters,f:"json"}},a=(0,Y.Tw)(this.url,this.sourceJSON,i),r=t.hasMultidimensions?this.request(`${this.url}/slices`,i).then(e=>e.data?.slices).catch(()=>null):null,s=await Promise.all([a,r]);return this._slices=s[1],s[0]}_fixScaleInServiceInfo(){let{sourceJSON:e}=this;e.minScale&&e.minScale<0&&(e.minScale=0),e.maxScale&&e.maxScale<0&&(e.maxScale=0)}_computeMinMaxLOD(e,t){let{pixelSize:i}=e,a=.5/e.width*i.x,{lods:r}=t,s=t.lodAt(Math.max.apply(null,r.map(e=>e.level))),n=t.lodAt(Math.min.apply(null,r.map(e=>e.level))),{tileType:l}=this;if("Map"===l)return this._levelOffset=r[0].level,[s,n];if("Raster"===l)return[r.find(e=>e.resolution===i.x)??s,n];let{minScale:o,maxScale:f}=this.sourceJSON,u=s;f>0&&(u=r.find(e=>Math.abs(e.scale-f)<a),u||=r.filter(e=>e.scale>f).sort((e,t)=>e.scale>t.scale?1:-1)[0]??s);let h=n;return o>0&&(h=r.find(e=>Math.abs(e.scale-o)<a)??n,this._levelOffset=h.level-n.level),[u,h]}};(0,r.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],K.prototype,"datasetFormat",void 0),(0,r.Cg)([(0,s.MZ)()],K.prototype,"tileType",void 0),K=(0,r.Cg)([(0,s.$K)("esri.layers.raster.datasets.ImageServerRaster")],K);const Q=K;var ee=i(10713);const te=new Map([["byte","u8"],["signedbyte","s8"],["int8","s8"],["uint8","u8"],["int16","s16"],["uint16","u16"],["int32","s32"],["uint32","u32"],["float32","f32"],["float64","f64"],["double64","f64"]]),ie=new Map;ie.set("none",{blobExtension:".til",isOneSegment:!0,decoderFormat:"bip"}),ie.set("lerc",{blobExtension:".lrc",isOneSegment:!1,decoderFormat:"lerc"}),ie.set("deflate",{blobExtension:".pzp",isOneSegment:!0,decoderFormat:"deflate"}),ie.set("jpeg",{blobExtension:".pjg",isOneSegment:!0,decoderFormat:"jpg"}),ie.set("qb3",{blobExtension:".pq3",isOneSegment:!0,decoderFormat:"qb3"});let ae=class extends n.A{constructor(){super(...arguments),this._files=null,this._storageIndex=null,this._isBsq=!1,this.datasetFormat="MRF"}async fetchRawTile(e,t,i,a={}){let{blockWidth:r,blockHeight:s,blockBoundary:n}=this.rasterInfo.storageInfo,l=n[e];if(!l||l.maxRow<t||l.maxCol<i||l.minRow>t||l.minCol>i)return null;let{bandCount:o,pixelType:f}=this.rasterInfo,{ranges:u,actualTileWidth:h,actualTileHeight:p}=this._getTileLocation(e,t,i);if(!u||0===u.length)return null;if(u.some(e=>e.from>e.to)){let e=new Uint8Array(r*s);return new c.A({width:r,height:s,pixels:void 0,mask:e,validPixelCount:0})}let{bandIds:d}=this.ioConfig,m=this._getBandSegmentCount(),g=[],y=0;for(y=0;y<m;y++)(!d||d.includes(y))&&g.push(this.request(this._files.data,{range:{from:u[y].from,to:u[y].to},responseType:"array-buffer",signal:a.signal}));let x=await Promise.all(g),w=x.map(e=>e.data.byteLength).reduce((e,t)=>e+t),I=new Uint8Array(w),b=[],v=0;for(y=0;y<m;y++)b.push(v),I.set(new Uint8Array(x[y].data),v),v+=x[y].data.byteLength;let C=ie.get(this.rasterInfo.storageInfo.compression).decoderFormat,S="jpg"===C&&4===o&&1===b.length,T=await this.decodePixelBlock(I.buffer,{width:r,height:s,format:C,planes:d?.length||o,offsets:b,pixelType:f,canvasUsage:S?"no-canvas":void 0,decodeJpegAsRgb:!1}).catch(()=>null);if(null==T)return null;let{noDataValue:A}=this.rasterInfo;if(null!=A&&"lerc"!==C&&!T.mask&&(A=A[0],null!=A)){let e=T.width*T.height,t=new Uint8Array(e);if(Math.abs(A)>1e24)for(y=0;y<e;y++)Math.abs((T.pixels[0][y]-A)/A)>1e-6&&(t[y]=1);else for(y=0;y<e;y++)T.pixels[0][y]!==A&&(t[y]=1);T.mask=t}let R=0,M=0;if(h!==r||p!==s){let e=T.mask;if(e)for(y=0;y<s;y++)if(M=y*r,y<p)for(R=h;R<r;R++)e[M+R]=0;else for(R=0;R<r;R++)e[M+R]=0;else for(e=new Uint8Array(r*s),T.mask=e,y=0;y<p;y++)for(M=y*r,R=0;R<h;R++)e[M+R]=1}return T}async _open(e){this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);let t=e?e.signal:null,i=await this.request(this.url,{responseType:"xml",signal:t}),{rasterInfo:a,files:r}=this._parseHeader(i.data),{skipMapInfo:s,skipExtensions:n=[]}=this.ioConfig;if(!n.includes("aux.xml")&&!s){let t=await this._fetchAuxiliaryData(e);null!=t&&(a.statistics=t.statistics??a.statistics,a.histograms=t.histograms,t.histograms&&null==a.statistics&&(a.statistics=(0,S.Pg)(t.histograms)))}s&&this.updateImageSpaceRasterInfo(a),this._set("rasterInfo",a),this._files=r;let l=await this.request(r.index,{responseType:"array-buffer",signal:t});this._storageIndex=function(e){if(e.byteLength%16>0)throw Error("invalid array buffer must be multiples of 16");let t;if(ee.Z){let i=new Uint8Array(e),a=new ArrayBuffer(e.byteLength),r=new Uint8Array(a);for(let t=0;t<e.byteLength/4;t++)for(let e=0;e<4;e++)r[4*t+e]=i[4*t+3-e];t=new Uint32Array(a)}else t=new Uint32Array(e);return t}(l.data);let{blockWidth:o,blockHeight:f}=this.rasterInfo.storageInfo,u=this.rasterInfo.storageInfo.pyramidScalingFactor,{width:h,height:c}=this.rasterInfo,p=[],d=this._getBandSegmentCount(),m=0,g=-1;for(;m<this._storageIndex.length;){g++;let e=Math.ceil(h/o/u**g)-1,t=Math.ceil(c/f/u**g)-1;m+=(e+1)*(t+1)*d*4,p.push({maxRow:t,maxCol:e,minCol:0,minRow:0})}this.rasterInfo.storageInfo.blockBoundary=p,g>0&&(this.rasterInfo.storageInfo.firstPyramidLevel=1,this.rasterInfo.storageInfo.maximumPyramidLevel=g),this.updateTileInfo()}_getBandSegmentCount(){return this._isBsq?this.rasterInfo.bandCount:1}_getTileLocation(e,t,i){let a,r,s,{blockWidth:n,blockHeight:l,pyramidScalingFactor:o}=this.rasterInfo.storageInfo,{width:f,height:u}=this.rasterInfo,h=this._getBandSegmentCount(),c=0,p=0;for(s=0;s<e;s++)p=o**s,a=Math.ceil(f/n/p),r=Math.ceil(u/l/p),c+=a*r;p=o**e,a=Math.ceil(f/n/p),r=Math.ceil(u/l/p),c+=t*a+i,c*=4*h;let d=this._storageIndex.subarray(c,c+4*h),m=0,g=0,y=[];for(let e=0;e<h;e++)m=d[4*e]*2**32+d[4*e+1],g=m+d[4*e+2]*2**32+d[4*e+3]-1,y.push({from:m,to:g});return{ranges:y,actualTileWidth:i<a-1?n:Math.ceil(f/p)-n*(a-1),actualTileHeight:t<r-1?l:Math.ceil(u/p)-l*(r-1)}}_parseHeader(e){let t=(0,P.V6)(e,"MRF_META/Raster");if(!t)throw new a.A("mrf:open","not a valid MRF format");let i=(0,P.V6)(t,"Size"),r=parseInt(i.getAttribute("x"),10),s=parseInt(i.getAttribute("y"),10),n=parseInt(i.getAttribute("c"),10),l=((0,P.mX)(t,"Compression")||"none").toLowerCase();if(!ie.has(l))throw new a.A("mrf:open","currently does not support compression "+l);let u=(0,P.mX)(t,"DataType")||"UInt8",h=te.get(u.toLowerCase());if(null==h)throw new a.A("mrf:open","currently does not support pixel type "+u);let c=(0,P.V6)(t,"PageSize"),p=parseInt(c.getAttribute("x"),10),d=parseInt(c.getAttribute("y"),10),m=c.getAttribute("c"),g=m?m===String(n):ie.get(l).isOneSegment;this._isBsq=!g;let y,x=(0,P.V6)(t,"DataValues");if(x){let e=x.getAttribute("NoData");null!=e&&(y=e.trim().split(" ").map(e=>parseFloat(e)))}if((0,P.V6)(e,"MRF_META/CachedSource"))throw new a.A("mrf:open","currently does not support MRF referencing other data files");let w,I=(0,P.V6)(e,"MRF_META/GeoTags"),b=(0,P.V6)(I,"BoundingBox"),v=!1;if(null!=b){let e=parseFloat(b.getAttribute("minx")),t=parseFloat(b.getAttribute("miny")),i=parseFloat(b.getAttribute("maxx")),a=parseFloat(b.getAttribute("maxy")),r=(0,P.mX)(I,"Projection")||"",s=f.A.WGS84;if("LOCAL_CS[]"!==r)if(r.toLowerCase().startsWith("epsg:")){let e=Number(r.slice(5));!isNaN(e)&&0!==e&&(s=new f.A({wkid:e}))}else s=E(r)??f.A.WGS84;else v=!0,s=new f.A({wkid:3857});w=new o.A(e,t,i,a),w.spatialReference=s}else v=!0,w=new o.A({xmin:-.5,ymin:.5-s,xmax:r-.5,ymax:.5,spatialReference:new f.A({wkid:3857})});let C=(0,P.V6)(e,"MRF_META/Rsets"),S=parseInt(C?.getAttribute("scale")||"2",10),T=w.spatialReference,R=new Z.A({origin:new W.A({x:w.xmin,y:w.ymax,spatialReference:T}),blockWidth:p,blockHeight:d,pyramidBlockWidth:p,pyramidBlockHeight:d,compression:l,pyramidScalingFactor:S}),M=new W.A({x:w.width/r,y:w.height/s,spatialReference:T}),_=new A.A({width:r,height:s,extent:w,isPseudoSpatialReference:v,spatialReference:T,bandCount:n,pixelType:h,pixelSize:M,noDataValue:y,storageInfo:R}),O=this._getAuxFullPath((0,P.mX)(t,"DataFile")),k=this._getAuxFullPath((0,P.mX)(t,"IndexFile"));return{rasterInfo:_,files:{mrf:this.url,index:k||this.url.replace(".mrf",".idx"),data:O||this.url.replace(".mrf",ie.get(l).blobExtension)}}}_getAuxFullPath(e){return!e||e.includes("\\")?null:e.includes("/")?e.startsWith(new URL(this.url).origin)?e:null:`${this.url.slice(0,this.url.lastIndexOf("/"))}/${e}`}async _fetchAuxiliaryData(e){try{let{data:t}=await this.request(this.url+".aux.xml",{responseType:"xml",signal:e?.signal});return H(t)}catch{return null}}};(0,r.Cg)([(0,s.MZ)()],ae.prototype,"_files",void 0),(0,r.Cg)([(0,s.MZ)()],ae.prototype,"_storageIndex",void 0),(0,r.Cg)([(0,s.MZ)()],ae.prototype,"_isBsq",void 0),(0,r.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],ae.prototype,"datasetFormat",void 0),ae=(0,r.Cg)([(0,s.$K)("esri.layers.raster.datasets.MRFRaster")],ae);const re=ae;i(44208);var se=i(53966),ne=i(9334);function le(e){let t=e.fields,i=e.records,a=t.some(e=>"oid"===e.name.toLowerCase())?"OBJECTID":"OID",r=[{name:a,type:"esriFieldTypeOID",alias:"OID"}].concat(t.map(e=>({name:e.name,type:"esriFieldType"+e.typeName,alias:e.name}))),s=r.map(e=>e.name),n=[],l=0,o=0;return i.forEach(e=>{let t={};for(t[a]=l++,o=1;o<s.length;o++)t[s[o]]=e[o-1];n.push({attributes:t})}),{displayFieldName:"",fields:r,features:n}}function oe(e){let t=new DataView(e),i=3&t.getUint8(0);if(3!==i)return{header:{version:i},recordSet:null};let a=t.getUint32(4,!0),r=t.getUint16(8,!0),s=t.getUint16(10,!0),n={version:i,recordCount:a,headerByteCount:r,recordByteCount:s},l=32,o=[],f=[];for(;13!==t.getUint8(l);){let i=String.fromCharCode(t.getUint8(l+11)).trim();o.push({name:(0,ne.w)(new Uint8Array(e,l,11)),type:i,typeName:["String","Date","Double","Boolean","String","Integer"][["C","D","F","L","M","N"].indexOf(i)],length:t.getUint8(l+16)}),l+=32}if(l+=1,o.length>0)for(;f.length<a&&e.byteLength-l>s;){let i=[];32===t.getUint8(l)?(l+=1,o.forEach(t=>{if("C"===t.type)i.push((0,ne.w)(new Uint8Array(e,l,t.length)).trim());else if("N"===t.type)i.push(parseInt(String.fromCharCode.apply(null,new Uint8Array(e,l,t.length)).trim(),10));else if("F"===t.type)i.push(parseFloat(String.fromCharCode.apply(null,new Uint8Array(e,l,t.length)).trim()));else if("D"===t.type){let a=String.fromCharCode.apply(null,new Uint8Array(e,l,t.length)).trim();i.push(new Date(parseInt(a.slice(0,4),10),parseInt(a.slice(4,6),10)-1,parseInt(a.slice(6,8),10)))}l+=t.length}),f.push(i)):l+=s}return{header:n,fields:o,records:f,recordSet:le({fields:o,records:f})}}var fe=i(44094),ue=i(94213);const he="none-tiled tiff is not optimized for access, convert to COG and retry.";let ce=class extends n.A{constructor(){super(...arguments),this._files=null,this._headerInfo=null,this._bufferSize=1048576,this._chunkSize=10485760,this.datasetFormat="TIFF"}async fetchRawTile(e,t,i,a={}){if(!this._headerInfo?.isSupported||this.isBlockOutside(e,t,i))return null;let r=await this._fetchRawTiffTile(e,t,i,!1,a);if(null!=r&&this._headerInfo.hasMaskBand){let s=await this._fetchRawTiffTile(e,t,i,!0,a);null!=s&&s.pixels[0]instanceof Uint8Array&&(r.mask=s.pixels[0])}return r}async _open(e){let t=e?e.signal:null,{data:i}=await this.request(this.url,{range:{from:0,to:this._bufferSize},responseType:"array-buffer",signal:t});if(!i)throw new a.A("tiffraster:open","failed to open url "+this.url);this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1,this.url.lastIndexOf("."));let{littleEndian:r,firstIFDPos:s,isBigTiff:n}=(0,fe.uT)(i),l=[],u={fileChunk:i,posIFD:s,fileOffset:0};await this._readIFDs(l,u,r,n?8:4,t);let{imageInfo:h,rasterInfo:c}=function(e){let t=(0,fe.uc)(e),{width:i,height:a,tileWidth:r,tileHeight:s,planes:n,pixelType:l,compression:u,firstPyramidLevel:h,maximumPyramidLevel:c,pyramidBlockWidth:p,pyramidBlockHeight:d,pyramidResolutions:m,tileBoundary:g,affine:y,metadata:x,colormap:w}=t,I=E(t.extent.spatialReference?.wkt||t.extent.spatialReference?.wkid),b=!!t.isPseudoGeographic;I??=(b=!0,new f.A({wkid:3857}));let v=new o.A({...t.extent,spatialReference:I}),C=v?new W.A({x:v.xmin,y:v.ymax,spatialReference:I}):new W.A({x:0,y:0}),S=new Z.A({blockWidth:r,blockHeight:s,pyramidBlockWidth:p,pyramidBlockHeight:d,compression:u,origin:C,firstPyramidLevel:h,maximumPyramidLevel:c,pyramidResolutions:m,blockBoundary:g}),T=new W.A({x:(v.xmax-v.xmin)/i,y:(v.ymax-v.ymin)/a,spatialReference:I}),R=x?{BandProperties:x.bandProperties,DataType:x.dataType}:{},M=new A.A({width:i,height:a,bandCount:n,pixelType:l,pixelSize:T,storageInfo:S,spatialReference:I,isPseudoSpatialReference:b,keyProperties:R,extent:v,colormap:w,statistics:x?x.statistics:null});if(y?.length&&(M.nativeExtent=new o.A({xmin:-.5,ymin:.5-a,xmax:i-.5,ymax:.5,spatialReference:I}),M.transform=new D.A({polynomialOrder:1,forwardCoefficients:[y[2]+y[0]/2,y[5]-y[3]/2,y[0],y[3],-y[1],-y[4]]}),M.extent=M.transform.forwardTransform(M.nativeExtent),M.pixelSize=new W.A({x:(v.xmax-v.xmin)/i,y:(v.ymax-v.ymin)/a,spatialReference:I}),S.origin.x=-.5,S.origin.y=.5),m){let{x:e,y:t}=M.pixelSize;m.forEach(i=>{i.x*=e,i.y*=t})}return{imageInfo:t,rasterInfo:M}}(l),p=(0,fe.zS)(l),d=(0,fe.r9)(l);if(this._headerInfo={littleEndian:r,isBigTiff:n,ifds:l,pyramidIFDs:p,maskIFDs:d,...h},this._set("rasterInfo",c),!h.isSupported)throw new a.A("tiffraster:open","this tiff is not supported: "+h.message);if(!h.tileWidth||!h.tileHeight)throw new a.A("tiffraster:open",he);c.isPseudoSpatialReference&&se.A.getLogger(this).warn("The spatial reference for this tiff is unsupported. Only EPSG spatial reference codes and Esri WKTs are supported.");let m=l[0].get("PREDICTOR")?.values?.[0];if(3===l[0].get("SAMPLEFORMAT")?.values?.[0]&&2===m)throw new a.A("tiffraster:open","unsupported horizontal difference encoding. Predictor=3 is supported for floating point data");let{skipMapInfo:g,skipExtensions:y=[]}=this.ioConfig;if(!y.includes("aux.xml")&&!g){let t=await this._fetchAuxiliaryMetaData(e);null!=t&&function(e,t){if(t.statistics=e.statistics??t.statistics,t.histograms=e.histograms,e.histograms&&null==t.statistics&&(t.statistics=(0,S.Pg)(e.histograms)),e.transform&&null==t.transform){t.transform=e.transform,t.nativeExtent=t.extent;let i=t.transform.forwardTransform(t.nativeExtent);t.pixelSize=new W.A({x:(i.xmax-i.xmin)/t.width,y:(i.ymax-i.ymin)/t.height,spatialReference:t.spatialReference}),t.extent=i}t.isPseudoSpatialReference&&e.spatialReference&&(t.spatialReference=e.spatialReference,t.extent.spatialReference=t.nativeExtent.spatialReference=t.storageInfo.origin.spatialReference=t.spatialReference)}(t,c)}!y.includes("vat.dbf")&&1===c.bandCount&&"u8"===c.pixelType&&!g&&(c.attributeTable=await this._fetchAuxiliaryTable(e),null!=c.attributeTable&&(c.keyProperties.DataType="thematic")),g&&this.updateImageSpaceRasterInfo(c),this.updateTileInfo()}async _validateOrFetchHeaderBuffer(e,t){let{fileChunk:i,fileOffset:a,posIFD:r}=e;return(r+8>=i.byteLength||r<0)&&(a=r+a,i=(await this.request(this.url,{range:{from:a,to:a+this._bufferSize},responseType:"array-buffer",signal:t})).data,r=0),{fileChunk:i,fileOffset:a,posIFD:r}}async _readIFDs(e,t,i,r=4,s){if(!t.posIFD)return null;t=await this._validateOrFetchHeaderBuffer(t,s);let n=await this._readIFD(t,i,ue.NB,r,s);if(!n?.ifd)throw new a.A("tiffraster:open","cannot parse tiff header. failed to open url "+this.url);if(e.push(n.ifd),!n.nextIFD)return null;t.posIFD=n.nextIFD-t.fileOffset,await this._readIFDs(e,t,i,r,s)}async _readIFD(e,t,i=ue.NB,r=4,s){let{fileChunk:n,posIFD:l,fileOffset:o}=e;if(!e.fileChunk)return null;let f=(0,fe.JM)(n,t,l,o,i,r);if(f.success){let{ifd:e}=f;if(!e)throw new a.A("tiffraster:open","cannot parse tiff header. failed to open url "+this.url);if(!(this.ioConfig.loadFullMetadata||i!==ue.NB||e.has("TILEWIDTH")&&e.has("TILELENGTH")))throw new a.A("tiffraster:open",he);let r=[];if(e.forEach(e=>{e.values||r.push(e)}),r.length>0&&await this._fillOffsets(r,t,f.nextIFD,s),e.has("GEOKEYDIRECTORY")){let i=e.get("GEOKEYDIRECTORY"),a=i?.values;if(a&&a.length>4){let e=a[0]+"."+a[1]+"."+a[2];l=i.valueOffset+6-o;let r=await this._validateOrFetchHeaderBuffer({fileChunk:n,posIFD:l,fileOffset:o},s);i.data=(await this._readIFD(r,t,ue.YC,2,s))?.ifd,i.data&&i.data.set("GEOTIFFVersion",{id:0,type:2,valueCount:1,valueOffset:null,values:[e]})}}return f}return f.requiredBufferSize?(n=(await this.request(this.url,{range:{from:o,to:o+l+f.requiredBufferSize+8},responseType:"array-buffer",signal:s})).data,n.byteLength<l+f.requiredBufferSize?null:(e.fileChunk=n,e.fileOffset=o,this._readIFD(e,t,i,r,s))):null}async _fillOffsets(e,t,i,a){let r=e.filter(e=>null!=e.offlineOffsetSize);if(0===r.length)return;let s=r.map(e=>e.offlineOffsetSize),n=Math.min.apply(null,s.map(e=>e[0])),l=Math.max.apply(null,s.map(e=>e[0]+e[1])),o=1===s.length||l-n<=this._bufferSize;if(!o&&s.length>1&&(s.sort((e,t)=>e[0]-t[0]),o=s.reduce((e,t)=>e===t[0]?t[0]+t[1]:0,s[0][0])===l),o){let e=await this._fetchOffsets(n,Math.max(l,n+this._bufferSize),a);return void r.forEach(i=>(0,fe.Cr)(e,t,i,n))}let f=r.map(async e=>{let i=e.offlineOffsetSize,r=await this._fetchOffsets(i[0],i[1]+i[0],a);(0,fe.Cr)(r,t,e,i[0])});await Promise.all(f)}async _fetchOffsets(e,t,i){let a=[],r=this._chunkSize,s=Math.ceil((t-e)/r),n=e;for(let e=0;e<s;e++)a.push(this.request(this.url,{range:{from:n,to:e===s-1?t:n+r-1},responseType:"array-buffer",signal:i})),n+=r;let l=await Promise.all(a);if(1===s)return l[0].data;let o=new Uint8Array(t-e+1);for(let e=0;e<s;e++)o.set(new Uint8Array(l[e].data),e*r);return o.buffer}async _fetchRawTiffTile(e,t,i,a,r={}){let s=this._getTileLocation(e,t,i,a);if(!s)return null;let{ranges:n,actualTileWidth:l,actualTileHeight:o,ifd:f}=s,u=n.map(e=>this.request(this.url,{range:e,responseType:"array-buffer",signal:r.signal})),h=await Promise.all(u),c=h.map(e=>e.data.byteLength).reduce((e,t)=>e+t),p=1===h.length?h[0].data:new ArrayBuffer(c),d=[0],m=[0];if(h.length>1){let e=new Uint8Array(p);for(let t=0,i=0;t<h.length;t++){let a=h[t].data;e.set(new Uint8Array(a),i),d[t]=i,i+=a.byteLength,m[t]=a.byteLength}}let{blockWidth:g,blockHeight:y}=this.getBlockWidthHeight(e),x=await this.decodePixelBlock(p,{format:"tiff",customOptions:{headerInfo:this._headerInfo,ifd:f,offsets:d,sizes:m},width:g,height:y,planes:null,pixelType:null});if(null==x)return null;if(l!==g||o!==y){let e=x.mask;if(e)for(let t=0;t<y;t++){let i=t*g;if(t<o)for(let t=l;t<g;t++)e[i+t]=0;else for(let t=0;t<g;t++)e[i+t]=0}else{e=new Uint8Array(g*y),x.mask=e;for(let t=0;t<o;t++){let i=t*g;for(let t=0;t<l;t++)e[i+t]=1}}}return x}_getTileLocation(e,t,i,a=!1){let{firstPyramidLevel:r,blockBoundary:s}=this.rasterInfo.storageInfo,n=0===e?0:e-(r-1),{_headerInfo:l}=this;if(!l)return null;let o=a?l.maskIFDs[n]:0===n?l.ifds[0]:l.pyramidIFDs[n-1];if(!o)return null;let f=(0,fe.XO)(o,l),u=(0,fe.wc)(o,"TILEOFFSETS"),h=(0,fe.wc)(o,"TILEBYTECOUNTS");if(!u?.length||!h?.length)return null;let{minRow:c,minCol:p,maxRow:d,maxCol:m}=s[n];if(t>d||i>m||t<c||i<p)return null;let g=(0,fe.LZ)(o,"IMAGEWIDTH"),y=(0,fe.LZ)(o,"IMAGELENGTH"),x=(0,fe.LZ)(o,"TILEWIDTH"),w=(0,fe.LZ)(o,"TILELENGTH"),I=[];if(f){let{bandCount:e}=this.rasterInfo;for(let a=0;a<e;a++){let e=a*(d+1)*(m+1)+t*(m+1)+i;I[a]={from:u[e],to:u[e]+h[e]-1}}}else{let e=t*(m+1)+i;I.push({from:u[e],to:u[e]+h[e]-1})}for(let e=0;e<I.length;e++)if(null==I[e].from||!I[e].to||I[e].to<0)return null;return{ranges:I,ifd:o,actualTileWidth:i===m&&g%x||x,actualTileHeight:t===d&&y%w||w}}async _fetchAuxiliaryMetaData(e){try{let{data:t}=await this.request(this.url+".aux.xml",{responseType:"xml",signal:e?.signal});return H(t)}catch{return null}}async _fetchAuxiliaryTable(e){try{let{data:t}=await this.request(this.url+".vat.dbf",{responseType:"array-buffer",signal:e?.signal}),i=oe(t);return i?.recordSet?_.A.fromJSON(i.recordSet):null}catch{return null}}};(0,r.Cg)([(0,s.MZ)()],ce.prototype,"_files",void 0),(0,r.Cg)([(0,s.MZ)()],ce.prototype,"_headerInfo",void 0),(0,r.Cg)([(0,s.MZ)()],ce.prototype,"_bufferSize",void 0),(0,r.Cg)([(0,s.MZ)()],ce.prototype,"_chunkSize",void 0),(0,r.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],ce.prototype,"datasetFormat",void 0),ce=(0,r.Cg)([(0,s.$K)("esri.layers.raster.datasets.TIFFRaster")],ce);const pe=ce,de=new Map;de.set("MRF",{desc:"Meta Raster Format",constructor:re}),de.set("TIFF",{desc:"GeoTIFF",constructor:pe}),de.set("RasterTileServer",{desc:"Raster Tile Server",constructor:Q}),de.set("JPG",{desc:"JPG Raster Format",constructor:G}),de.set("PNG",{desc:"PNG Raster Format",constructor:G}),de.set("GIF",{desc:"GIF Raster Format",constructor:G}),de.set("BMP",{desc:"BMP Raster Format",constructor:G}),de.set("CovJSON",{desc:"COVJSON Raster Format",constructor:k}),de.set("MEMORY",{desc:"In Memory Raster Format",constructor:M});class me{static get supportedFormats(){let e=new Set;return de.forEach((t,i)=>e.add(i)),e}static async open(e){let{url:t,ioConfig:i,source:r,sourceJSON:s}=e,n=e.datasetFormat??i?.datasetFormat;n??(t.includes(".")?n=t.slice(t.lastIndexOf(".")+1).toUpperCase():"coverage"===r?.type?.toLowerCase()?n="CovJSON":r?.extent&&r.pixelblocks&&(n="MEMORY")),"OVR"===n||"TIF"===n||"DM"===n?n="TIFF":"JPG"===n||"JPEG"===n||"JFIF"===n?n="JPG":"COVJSON"===n&&(n="CovJSON"),t.toLowerCase().includes("/imageserver")&&!t.toLowerCase().includes("/wcsserver")&&(n="RasterTileServer");let l={url:t,source:r,sourceJSON:s,datasetFormat:n,ioConfig:i??{bandIds:null,sampling:null}};if(Object.keys(l).forEach(e=>{l[e]??delete l[e]}),n){if(!this.supportedFormats.has(n))throw new a.A("rasterfactory:open","not a supported format "+n);if("CRF"===n)throw new a.A("rasterfactory:open",`cannot open raster: ${t}`);let i=new(0,de.get(n).constructor)(l);return i.rasterJobHandler=e.rasterJobHandler,i.rasterInfo=e.rasterInfo,await i.open({signal:e.signal}),i}let o=Array.from(de.keys()).filter(e=>"CovJSON"!==e&&"Memory"!==e),f=0,u=()=>{if(n=o[f++],!n||"CRF"===n)return null;let t=new(0,de.get(n).constructor)(l);return t.rasterJobHandler=e.rasterJobHandler,t.open({signal:e.signal}).then(()=>t).catch(()=>u())};return u()}static register(e,t,i){de.has(e.toUpperCase())||de.set(e.toUpperCase(),{desc:t,constructor:i})}}},10333(e,t,i){i.d(t,{A:()=>n});var a=i(32198),r=i(25482),s=i(91429);let n=class extends r.o{get affectsPixelSize(){return!1}forwardTransform(e){return e}inverseTransform(e){return e}};(0,a.Cg)([(0,s.MZ)()],n.prototype,"affectsPixelSize",null),(0,a.Cg)([(0,s.MZ)({json:{write:!0}})],n.prototype,"spatialReference",void 0),n=(0,a.Cg)([(0,s.$K)("esri.layers.raster.transforms.BaseRasterTransform")],n)},75414(e,t,i){i.d(t,{A:()=>o});var a,r=i(32198),s=i(91429),n=i(10333),l=i(93223);let o=a=class extends n.A{constructor(){super(...arguments),this.type="gcs-shift",this.tolerance=1e-8}forwardTransform(e){return"point"===(e=e.clone()).type?(e.x>180+this.tolerance&&(e.x-=360),e):(e.xmin>=180-this.tolerance?(e.xmax-=360,e.xmin-=360):e.xmax>180+this.tolerance&&(e.xmin=-180,e.xmax=180),e)}inverseTransform(e){return"point"===(e=e.clone()).type?(e.x<-this.tolerance&&(e.x+=360),e):(e.xmin<-this.tolerance&&(e.xmin+=360,e.xmax+=360),e)}clone(){return new a({tolerance:this.tolerance})}};(0,r.Cg)([(0,l.e)({GCSShiftXform:"gcs-shift"})],o.prototype,"type",void 0),(0,r.Cg)([(0,s.MZ)()],o.prototype,"tolerance",void 0),o=a=(0,r.Cg)([(0,s.$K)("esri.layers.raster.transforms.GCSShiftTransform")],o)},43163(e,t,i){i.d(t,{A:()=>d});var a,r=i(32198),s=i(91429),n=i(5443),l=i(86738),o=i(10333),f=i(36005),u=i(43937),h=i(93223);function c(e,t,i){let{x:a,y:r}=t;if(i<2)return{x:e[0]+a*e[2]+r*e[4],y:e[1]+a*e[3]+r*e[5]};if(2===i){let t=a*a,i=r*r,s=a*r;return{x:e[0]+a*e[2]+r*e[4]+t*e[6]+s*e[8]+i*e[10],y:e[1]+a*e[3]+r*e[5]+t*e[7]+s*e[9]+i*e[11]}}let s=a*a,n=r*r,l=a*r,o=s*a,f=s*r,u=a*n,h=r*n;return{x:e[0]+a*e[2]+r*e[4]+s*e[6]+l*e[8]+n*e[10]+o*e[12]+f*e[14]+u*e[16]+h*e[18],y:e[1]+a*e[3]+r*e[5]+s*e[7]+l*e[9]+n*e[11]+o*e[13]+f*e[15]+u*e[17]+h*e[19]}}function p(e,t,i){let{xmin:a,ymin:r,xmax:s,ymax:l,spatialReference:o}=t,f=[];if(i<2)f.push({x:a,y:l}),f.push({x:s,y:l}),f.push({x:a,y:r}),f.push({x:s,y:r});else{let e=10;for(let t=0;t<e;t++)f.push({x:a,y:r+(l-r)*t/(e-1)}),f.push({x:s,y:r+(l-r)*t/(e-1)});e=8;for(let t=1;t<=e;t++)f.push({x:a+(s-a)*t/e,y:r}),f.push({x:a+(s-a)*t/e,y:l})}f=f.map(t=>c(e,t,i));let u=f.map(e=>e.x),h=f.map(e=>e.y);return new n.A({xmin:Math.min.apply(null,u),xmax:Math.max.apply(null,u),ymin:Math.min.apply(null,h),ymax:Math.max.apply(null,h),spatialReference:o})}let d=a=class extends o.A{constructor(){super(...arguments),this.polynomialOrder=1,this.type="polynomial"}readForwardCoefficients(e,t){let{coeffX:i,coeffY:a}=t;if(!i?.length||!a?.length||i.length!==a.length)return null;let r=[];for(let e=0;e<i.length;e++)r.push(i[e]),r.push(a[e]);return r}writeForwardCoefficients(e,t,i){let a=[],r=[];for(let t=0;t<e?.length;t++)t%2==0?a.push(e[t]):r.push(e[t]);t.coeffX=a,t.coeffY=r}get inverseCoefficients(){let e=this._get("inverseCoefficients"),t=this._get("forwardCoefficients");return!e&&t&&this.polynomialOrder<2&&(e=function(e){let[t,i,a,r,s,n]=e,l=a*n-s*r,o=s*r-a*n;return[(s*i-t*n)/l,(a*i-t*r)/o,n/l,r/o,-s/l,-a/o]}(t)),e}set inverseCoefficients(e){this._set("inverseCoefficients",e)}readInverseCoefficients(e,t){let{inverseCoeffX:i,inverseCoeffY:a}=t;if(!i?.length||!a?.length||i.length!==a.length)return null;let r=[];for(let e=0;e<i.length;e++)r.push(i[e]),r.push(a[e]);return r}writeInverseCoefficients(e,t,i){let a=[],r=[];for(let t=0;t<e?.length;t++)t%2==0?a.push(e[t]):r.push(e[t]);t.inverseCoeffX=a,t.inverseCoeffY=r}get affectsPixelSize(){return this.polynomialOrder>0}forwardTransform(e){if("point"===e.type){let t=c(this.forwardCoefficients,e,this.polynomialOrder);return new l.A({x:t.x,y:t.y,spatialReference:e.spatialReference})}return p(this.forwardCoefficients,e,this.polynomialOrder)}inverseTransform(e){if("point"===e.type){let t=c(this.inverseCoefficients,e,this.polynomialOrder);return new l.A({x:t.x,y:t.y,spatialReference:e.spatialReference})}return p(this.inverseCoefficients,e,this.polynomialOrder)}clone(){return new a({polynomialOrder:this.polynomialOrder,forwardCoefficients:this.forwardCoefficients?[...this.forwardCoefficients]:null,inverseCoefficients:this.inverseCoefficients?[...this.inverseCoefficients]:null})}};(0,r.Cg)([(0,s.MZ)({json:{write:!0}})],d.prototype,"polynomialOrder",void 0),(0,r.Cg)([(0,s.MZ)()],d.prototype,"forwardCoefficients",void 0),(0,r.Cg)([(0,f.w)("forwardCoefficients",["coeffX","coeffY"])],d.prototype,"readForwardCoefficients",null),(0,r.Cg)([(0,u.K)("forwardCoefficients")],d.prototype,"writeForwardCoefficients",null),(0,r.Cg)([(0,s.MZ)({json:{write:!0}})],d.prototype,"inverseCoefficients",null),(0,r.Cg)([(0,f.w)("inverseCoefficients",["inverseCoeffX","inverseCoeffY"])],d.prototype,"readInverseCoefficients",null),(0,r.Cg)([(0,u.K)("inverseCoefficients")],d.prototype,"writeInverseCoefficients",null),(0,r.Cg)([(0,s.MZ)()],d.prototype,"affectsPixelSize",null),(0,r.Cg)([(0,h.e)({PolynomialXform:"polynomial"})],d.prototype,"type",void 0),d=a=(0,r.Cg)([(0,s.$K)("esri.layers.raster.transforms.PolynomialTransform")],d)}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[563],{15142(t,e,s){s.d(e,{A:()=>o});var r=s(4576),i=s(21818);const l=(t,e,s,r)=>{let i=e,l=e,h=s>>>1,n=t[i-1];for(;l<=h;){l=i<<1,l<s&&r(t[l-1],t[l])<0&&++l;let e=t[l-1];if(r(e,n)<=0)break;t[i-1]=e,i=l}t[i-1]=n},h=(t,e)=>t<e?-1:+(t>e);function n(t,e,s,r){void 0===e&&(e=0),void 0===s&&(s=t.length),void 0===r&&(r=h);for(let i=s>>>1;i>e;i--)l(t,i,s,r);let i=e+1;for(let h=s-1;h>e;h--){let s=t[e];t[e]=t[h],t[h]=s,l(t,i,h,r)}}function*a(t,e,s,r){void 0===e&&(e=0),void 0===s&&(s=t.length),void 0===r&&(r=h);for(let i=s>>>1;i>e;i--)l(t,i,s,r),yield;let i=e+1;for(let h=s-1;h>e;h--){let s=t[e];t[e]=t[h],t[h]=s,l(t,i,h,r),yield}}class o{constructor(t){this.data=[],this._length=0,this._allocator=void 0,this._deallocator=()=>null,this._shrink=()=>{},this._hint=new r.vW,t&&(t.initialSize&&(this.data=Array(t.initialSize)),t.allocator&&(this._allocator=t.allocator),void 0!==t.deallocator&&(this._deallocator=t.deallocator),t.shrink&&(this._shrink=()=>c(this)))}toArray(){return this.data.slice(0,this.length)}filter(t){let e=[];for(let s=0;s<this._length;s++){let r=this.data[s];t(r)&&e.push(r)}return e}at(t){if((t=Math.trunc(t)||0)<0&&(t+=this._length),!(t<0||t>=this._length))return this.data[t]}includes(t,e){let s=this.data.indexOf(t,e);return-1!==s&&s<this.length}get length(){return this._length}set length(t){if(t>this._length){if(this._allocator){for(;this._length<t;)this.data[this._length++]=this._allocator(this.data[this._length]);return}this._length=t}else{if(this._deallocator)for(let e=t;e<this._length;++e)this.data[e]=this._deallocator(this.data[e]);this._length=t,this._shrink()}}clear(){this.length=0}prune(){this.clear(),this.data=[]}push(t){this.data[this._length++]=t}pushArray(t,e=t.length){for(let s=0;s<e;s++)this.data[this._length++]=t[s]}pushAll(t){for(let e of t)this.data[this._length++]=e}fill(t,e){for(let s=0;s<e;s++)this.data[this._length++]=t}pushNew(){this._allocator&&(this.data[this.length]=this._allocator(this.data[this.length]));let t=this.data[this._length];return++this._length,t}unshift(t){this.data.unshift(t),this._length++,c(this)}pop(){if(0===this.length)return;let t=this.data[this.length-1];return--this.length,this._shrink(),t}remove(t){let e=(0,r.qh)(this.data,(0,i.z)(t),this.length,this._hint);if(-1!==e)return this.data.splice(e,1),--this.length,t}removeUnordered(t){return this.removeUnorderedIndex((0,r.qh)(this.data,(0,i.z)(t),this.length,this._hint))}removeUnorderedIndex(t){if(!(t>=this.length||t<0))return this.swapElements(t,this.length-1),this.pop()}removeUnorderedMany(t,e=t.length,s){this.length=(0,r.mW)(this.data,t,this.length,e,this._hint,s),this._shrink()}front(){if(0!==this.length)return this.data[0]}back(){if(0!==this.length)return this.data[this.length-1]}swapElements(t,e){if(t>=this.length||e>=this.length||t===e)return;let s=this.data[t];this.data[t]=this.data[e],this.data[e]=s}sort(t){n(this.data,0,this.length,t)}iterableSort(t){return a(this.data,0,this.length,t)}some(t,e){for(let s=0;s<this.length;++s)if(t.call(e,this.data[s],s,this.data))return!0;return!1}find(t,e){let{data:s,length:r}=this;for(let i=0;i<r;++i)if(t.call(e,s[i]))return s[i]}filterInPlace(t,e){let s=0;for(let r=0;r<this._length;++r){let i=this.data[r];t.call(e,i,r,this.data)&&(this.data[r]=this.data[s],this.data[s]=i,s++)}if(this._deallocator)for(let t=s;t<this._length;t++)this.data[t]=this._deallocator(this.data[t]);return this._length=s,this._shrink(),this}forAll(t,e){let{data:s,length:r}=this;for(let i=0;i<r;++i)t.call(e,s[i],i,s)}forEach(t,e){this.data.slice(0,this.length).forEach(t,e)}map(t,e){let s=Array(this.length);for(let r=0;r<this.length;++r)s[r]=t.call(e,this.data[r],r,this.data);return s}reduce(t,e){let s=e;for(let e=0;e<this.length;++e)s=t(s,this.data[e],e,this.data);return s}has(t){let e=this.length,s=this.data;for(let r=0;r<e;++r)if(s[r]===t)return!0;return!1}*[Symbol.iterator](){for(let t=0;t<this.length;++t)yield this.data[t]}}function c(t){t.data.length>1.5*t.length&&(t.data.length=Math.floor(1.1*t.length))}},9775(t,e,s){s.d(e,{A:()=>l});var r=s(62788),i=s(95488);class l{constructor(t=t=>t.values().next().value){this._peeker=t,this._observable=new i.I,this._items=new Set}get length(){return(0,r.gc)(this._observable),this._items.size}clear(){0!==this.length&&(this._items.clear(),this._observable.notify())}last(){if(0===this.length)return;let t;for(t of this._items);return t}peek(){if(0!==this.length)return this._peeker(this._items)}push(t){this.contains(t)||(this._items.add(t),this._observable.notify())}contains(t){return(0,r.gc)(this._observable),this._items.has(t)}pop(){if(0===this.length)return;let t=this.peek();return this._items.delete(t),this._observable.notify(),t}popLast(){if(0===this.length)return;let t=this.last();return this._items.delete(t),this._observable.notify(),t}remove(t){this.contains(t)&&(this._items.delete(t),this._observable.notify())}filter(t){let e=this.length;return this._items.forEach(e=>{t(e)||this._items.delete(e)}),e!==this._items.size&&this._observable.notify(),this}*[Symbol.iterator](){(0,r.gc)(this._observable),yield*this._items}}},563(t,e,s){s.d(e,{QueueProcessor:()=>o,SharedConcurrency:()=>u});var r=s(97768),i=s(17676),l=s(9775),h=s(32587),n=s(76030),a=s(44794);class o{constructor(t){this._schedule=null,this._deferreds=new h.A,this._controllers=new h.A,this._processingItems=new h.A,this._pausedSignal=(0,a.v)(!1),this.process=t.process,this.concurrency=t.concurrency,this.sharedConcurrency=t.sharedConcurrency??d,this._queue=new l.A(t.peeker)}destroy(){this.clear(),this._schedule=(0,r.xt)(this._schedule)}get updating(){return this.running}get length(){return this._processingItems.size+this._queue.length}get running(){return!this._pausedSignal.value&&this._queue.length>0&&!this.full}get full(){return this._processingItems.size>=this.concurrency||this.sharedConcurrency.full}abort(t){this._controllers.get(t)?.abort()}clear(){this._queue.clear();let t=Array.from(this._controllers.values());this._controllers.clear(),t.forEach(t=>t.abort()),this.sharedConcurrency.current.value-=this._processingItems.size,this._processingItems.clear(),this._cancelNext()}forEach(t){this._deferreds.forEach((e,s)=>t(s))}_get(t){return this._deferreds.get(t)?.promise}pause(){this._pausedSignal.value||(this._pausedSignal.value=!0,this._cancelNext())}push(t,e){let s=this._get(t);if(s)return s;let r=new AbortController,l=Promise.withResolvers(),h=e?(0,i.u7)(e,()=>r.abort()):null,n=(0,i.NY)(r.signal,()=>{let e=this._processingItems.get(t);e&&e.controller.abort(),a(),l.reject((0,i.NK)())}),a=()=>{n.remove(),h?.remove(),this._removeItem(t),this._queue.remove(t),this._scheduleNext()};return this._deferreds.set(t,l),this._controllers.set(t,r),l.promise.then(a,a),this._queue.push(t),this._scheduleNext(),l.promise}last(){return this._queue.last()}reset(){let t=Array.from(this._processingItems.values());this.sharedConcurrency.current.value-=this._processingItems.size,this._processingItems.clear();for(let e of t)this._queue.push(e.item),e.controller.abort();this._scheduleNext()}resume(){this._pausedSignal.value&&(this._pausedSignal.value=!1,this._scheduleNext())}takeAll(){let t=[];for(;this._queue.length;)t.push(this._queue.pop());return this.clear(),t}_removeItem(t){this._deferreds.delete(t),this._controllers.delete(t),this._processingItems.has(t)&&(this._processingItems.delete(t),--this.sharedConcurrency.current.value)}_scheduleNext(){this._pausedSignal.value||this._schedule||(this._schedule=(0,n._)(()=>{this._schedule=null,this._next()}))}_next(){for(;this._queue.length>0&&this._processingItems.size<this.concurrency&&!this.sharedConcurrency.full;)this._process(this._queue.pop())}_cancelNext(){this._schedule&&=(this._schedule.remove(),null)}_processResult(t,e){this._canProcessFulfillment(t)&&(this._scheduleNext(),this._deferreds.get(t.item).resolve(e))}_processError(t,e){this._canProcessFulfillment(t)&&(this._scheduleNext(),this._deferreds.get(t.item).reject(e))}_canProcessFulfillment(t){return!(!this._deferreds.get(t.item)||this._processingItems.get(t.item)!==t)}_process(t){if(null==t)return;let e,s=new AbortController,r=new c(t,s);this._processingItems.set(t,r),this.sharedConcurrency.current.value+=1;try{e=this.process(t,s.signal)}catch(t){this._processError(r,t)}(0,i.$X)(e)?(r.promise=e,e.then(t=>this._processResult(r,t),t=>this._processError(r,t))):this._processResult(r,e)}}class c{constructor(t,e){this.item=t,this.controller=e,this.promise=null}}class u{constructor(t){this.limit=t,this.current=(0,a.v)(0)}get full(){return this.current.value>=this.limit}}const d=new u(1/0)},32587(t,e,s){s.d(e,{A:()=>l});var r=s(62788),i=s(95488);class l{constructor(t){this._observable=new i.I,this._notifyPending=!1,this._batchDepth=0,this._map=new Map(t)}get size(){return(0,r.gc)(this._observable),this._map.size}batch(t){try{this._batchDepth++,t()}finally{this._batchDepth--,this._notifyPending&&0===this._batchDepth&&(this._notifyPending=!1,this._notify())}}clear(){this._map.size>0&&(this._map.clear(),this._notify())}delete(t){let e=this._map.delete(t);return e&&this._notify(),e}entries(){return(0,r.gc)(this._observable),this._map.entries()}forEach(t,e){(0,r.gc)(this._observable),this._map.forEach((s,r)=>t.call(e,s,r,this),e)}get(t){return(0,r.gc)(this._observable),this._map.get(t)}has(t){return(0,r.gc)(this._observable),this._map.has(t)}keys(){return(0,r.gc)(this._observable),this._map.keys()}set(t,e){return this._map.set(t,e),this._notify(),this}transformValues(t,e=this._map.keys()){this.batch(()=>{for(let s of e){if(!this._map.has(s))continue;let e=this._map.get(s),r=t(e,s);r!==e&&this.set(s,r)}})}values(){return(0,r.gc)(this._observable),this._map.values()}[Symbol.iterator](){return(0,r.gc)(this._observable),this._map[Symbol.iterator]()}[Symbol.dispose](){this._observable.destroy()}get[Symbol.toStringTag](){return this._map[Symbol.toStringTag]}_notify(){this._batchDepth>0?this._notifyPending=!0:this._observable.notify()}}},11406(t,e,s){s.d(e,{T:()=>l});var r=s(36563);class i{constructor(t,e){this._observers=t,this._observer=e}remove(){let{_observers:t,_observer:e}=this;if(t[t.length-1]===e)return void t.pop();let s=t.indexOf(this._observer);-1!==s&&t.splice(s,1)}}class l{constructor(){this._observers=null,this.destroyed=!1}observe(t){if(this.destroyed||t.destroyed)return h;this._observers??=[];let e=this._observers,s=!1,r=!1;for(let i of e)if(i.destroyed)r=!0;else if(i===t){s=!0;break}return s||(e.push(t),r&&this._removeDestroyedObservers()),new i(e,t)}_removeDestroyedObservers(){let t=this._observers;if(!t)return;let e=t.length;if(0===e)return;let s=0;for(let r=0;r<e;++r){for(;r+s<e&&t[r+s].destroyed;)++s;if(s>0){if(!(r+s<e))break;t[r]=t[r+s]}}t.length=e-s}destroy(){if(this.destroyed)return;this.destroyed=!0;let t=this._observers;if(null!=t){for(let e of t)e.onCommitted();this._observers=null}}}const h=(0,r.hA)()},62788(t,e,s){s.d(e,{F_:()=>_,Xr:()=>v,a:()=>d,fE:()=>p,gc:()=>o}),s(44208);var r=s(53966),i=s(88620),l=s(47328);const h=new(s(67867).R),n=[];let a=h;function o(t){a.onAccessed(t)}let c=!1,u=!1;function d(t,e,s){if(c)return f(t,e,s);let i;if(u){a=t,n.push(t);try{i=e.call(s)}catch(t){throw r.A.getLogger("esri.core.accessorSupport.tracking").error(t),t}finally{g()}}else{a=t,n.push(t);try{i=e.call(s)}finally{g()}}return i}function _(t,e){return d(h,t,e)}function f(t,e,s){let i,l=c;c=!0,a=t,n.push(t);try{i=e.call(s)}catch(t){u&&r.A.getLogger("esri.core.accessorSupport.tracking").error(t)}return g(),c=l,i}function g(){let t=n.length;if(t>1){let e=n.pop();a=n[t-2],e.onTrackingEnd()}else if(1===t){let t=n.pop();a=h,t.onTrackingEnd()}else a=h}function p(t,e){if(e.flags&l.i.DepTrackingInitialized)return;e.flags|=l.i.DepTrackingInitialized;let s=u;u=!1,e.flags&l.i.AutoTracked?f(e.trackingTarget,e.metadata.get,t):v(t,e),u=s}const m=[];function v(t,e){e.flags&l.i.ExplicitlyTracking||(e.flags|=l.i.ExplicitlyTracking,f(e.trackingTarget,()=>{let s=e.metadata.dependsOn||m;for(let e of s)if("string"!=typeof e||e.includes(".")){let s=(0,i.AH)(e);for(let e=0,r=t;e<s.length&&"object"==typeof r&&r;++e)r=y(r,s[e],e!==s.length-1)}else y(t,e,!1)}),e.flags&=~l.i.ExplicitlyTracking)}function y(t,e,s){let r=e.endsWith("?")?e.slice(0,-1):e;if(null!=t.getItemAt||Array.isArray(t)){let e=parseInt(r,10);if(!isNaN(e))return Array.isArray(t)?t[e]:t.at(e)}let l=(0,i.oY)(t);if(l){let e=l.propertiesByName.get(r);e&&(o(e),p(t,e))}return s?t[r]:void 0}},47328(t,e,s){s.d(e,["i",0,{Dirty:1,Overridden:2,Computing:4,NonNullable:8,HasDefaultValue:16,DepTrackingInitialized:32,AutoTracked:64,ExplicitlyTracking:128}])},95488(t,e,s){s.d(e,{I:()=>i});var r=s(11406);class i extends r.T{notify(){let t=this._observers;if(t&&t.length>0){let e=t.slice();for(let t of e)t.onInvalidated(),t.onCommitted()}}}},67867(t,e,s){s.d(e,{R:()=>r});class r{constructor(t){this.accessed=void 0,this._handles=void 0,this._observer=t}destroy(){this.clear(),this.accessed=void 0,this._observer=void 0}onAccessed(t){null!=this._observer&&t!==this._observer&&(this.accessed??=new Set,this.accessed.add(t))}onTrackingEnd(){null!=this._observer&&(this.clear(),null!=this.accessed&&(this._handles??=[],this.accessed.forEach(t=>{this._handles.push(t.observe(this._observer))}),this.accessed.clear()))}clear(){if(null!=this._handles)for(;this._handles.length;)this._handles.pop().remove()}}},88620(t,e,s){s.d(e,{AH:()=>o,h1:()=>n,oY:()=>l,qg:()=>u,yh:()=>h});var r=s(36563),i=s(4718);function l(t){return t.__accessor__??null}function h(t,e){return null!=t?.metadata?.[e]}function n(t,e,s){return a(t,e,s?{policy:s,path:""}:null)}function a(t,e,s){return e?Object.keys(e).reduce((t,r)=>{let l=r;if("__proto__"===l)return t;let h=null,n="merge";if(s&&(h=s.path?`${s.path}.${r}`:r,n=s.policy(h)),"replace"===n||"replace-arrays"===n&&Array.isArray(t[l]))return t[l]=e[l],t;if(void 0===t[l])return t[l]=(0,i.o8)(e[l]),t;let o=t[l],c=e[l];if(o===c)return t;if(Array.isArray(c)||Array.isArray(t))o=t[l]=o?Array.isArray(o)?o.slice():[o]:[],c&&(Array.isArray(c)||(c=[c]),c.forEach(t=>{o.includes(t)||o.push(t)}));else if(c&&"object"==typeof c)if(s){let e=s.path;s.path=h,t[l]=a(o,c,s),s.path=e}else t[l]=a(o,c,null);else(!t.hasOwnProperty(r)||e.hasOwnProperty(r))&&(t[l]=c);return t},t||{}):t}function o(t){return Array.isArray(t)?t:t.split(".")}function c(t){return t.includes(",")?t.split(",").map(t=>t.trim()):[t.trim()]}function u(t,e,s,i){let l=function(t){if(Array.isArray(t)){let e=[];for(let s of t)e.push(...c(s));return e}return c(t)}(e);if(1!==l.length){let e=l.map(e=>i(t,e,s));return(0,r.vE)(e)}return i(t,l[0],s)}},26390(t,e,s){s.d(e,{d:()=>i});const r=[];function i(t){r.push(t),1===r.length&&queueMicrotask(()=>{let t=r.slice();r.length=0;for(let e of t)e()})}},76030(t,e,s){s.d(e,{_:()=>p,$m:()=>w,md:()=>k});var r=s(26390);function i(t,e,s,r,i){console.timeStamp(t,e,s,i,r)}class l{constructor(t,e=30){this.name=t,this._counter=0,this._samples=Array(e)}push(t){null!=t&&(this._samples[++this._counter%this._samples.length]=t)}set(t){null!=t&&(this._samples[this._counter%this._samples.length]=t)}get median(){return this._samples.slice().sort((t,e)=>t-e)[Math.floor(this._samples.length/2)]}get average(){return this._samples.reduce((t,e)=>t+e,0)/this._samples.length}get last(){return this._samples[this._counter%this._samples.length]}}var h=s(15142),n=s(17676),a=s(78659);class o{constructor(t){this.callback=t,this.isActive=!0}remove(){this.isActive=!1}}let c=0;const u={time:(0,a.l5)(0),deltaTime:(0,a.l5)(0),elapsedFrameTime:(0,a.l5)(0),frameDuration:(0,a.l5)(0)},d=["prepare","preRender","render","postRender","update","finish"],_=[],f=new h.A,g={frameTasks:f,willDispatch:!1,clearFrameTasks:function(t=!1){f.forAll(t=>{t.removed=!0}),t&&b()},dispatch:A,executeFrameTasks:function(t){let e=(0,a.l5)(t-c);c=t;let s=1e3/60,r=Math.max(0,e-s);u.time=t,u.frameDuration=(0,a.l5)(s-r);for(let s=0;s<d.length;s++){let r=performance.now(),l=d[s];f.forAll(r=>{r.paused||r.removed||(0===s&&r.ticks++,!r.phases[l])||(u.elapsedFrameTime=(0,a.l5)(performance.now()-t),u.deltaTime=0===r.ticks?(0,a.l5)(0):e,r.phases[l]?.call(r,u))});let h=performance.now();I[s].push(h-r),i(l,r,h,"Maps SDK","Scheduling")}b();let l=performance.now();S.push(l-t),i("Animation Frame",t,l,"Maps SDK","Scheduling")},reschedule:function(){null!=m&&(cancelAnimationFrame(m),m=requestAnimationFrame(v))}};function p(t){let e=new o(t);return _.push(e),g.willDispatch||(g.willDispatch=!0,(0,r.d)(A)),e}let m=null;function v(){let t=performance.now();m=null,m=f.some(t=>!t.paused&&!t.removed)?requestAnimationFrame(v):null,g.executeFrameTasks(t)}const y=new h.A;function b(){f.forAll(t=>{t.removed&&y.push(t)}),f.removeUnorderedMany(y.data,y.length),y.clear()}function A(){for(;_.length;){let t=_.shift();t.isActive&&t.callback()}g.willDispatch=!1}function k(t=1,e){let s=Promise.withResolvers(),i=()=>{(0,n.G4)(e)?s.reject((0,n.NK)()):0===t?s.resolve():(--t,(0,r.d)(()=>i()))};return i(),s.promise}async function w(t){await function(t){return k(1,t)}(t),await new Promise(e=>requestAnimationFrame(()=>{t?.aborted||e()}))}const I=d.map(t=>new l(t)),S=new l("total")},44794(t,e,s){s.d(e,{v:()=>n});var r=s(4718),i=s(62788),l=s(95488);class h{constructor(t,e){this._observable=new l.I,this._value=t,this._equalityFunction=e}get value(){return(0,i.gc)(this._observable),this._value}set value(t){this._equalityFunction(t,this._value)||(this._value=t,this._observable.notify())}mutate(t){t(this._value),this._observable.notify()}}function n(t,e=r.gh){return new h(t,e)}},78659(t,e,s){function r(t){return t}function i(t){return 1e3*t}function l(t){return t}s.d(e,{Kp:()=>l,gr:()=>i,l5:()=>r})}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[895,3276,4144],{61691(e,t,r){r.d(t,{G:()=>n});class n{*[Symbol.iterator](){let e=this.next();for(;e;)yield e,e=this.next()}}},76061(e,t,r){r.d(t,{S:()=>o});var n=r(61691);class o extends n.G{m_aGeoms;m_iGeom=-1;constructor(e){super(),this.m_aGeoms=e?e.slice():[]}next(){if(this.m_iGeom<this.m_aGeoms.length-1){let e=this.m_aGeoms[++this.m_iGeom];return this.m_aGeoms[this.m_iGeom]=null,e}return null}tock(){return!1}getGeometryID(){return this.m_iGeom}getRank(){return 1}}},4144(e,t,r){r.r(t),r.d(t,{clipToSpatialReference:()=>l,execute:()=>c,executeMany:()=>s,foldInto360Range:()=>f,foldInto360RangeGeodetic:()=>m,isLoaded:()=>a,load:()=>u,normalizeGeometry:()=>p,supportsCurves:()=>d,transform:()=>y});var n=r(76061),o=r(83290);let i;function a(){return!!i&&(0,o.i)()}async function u(){if(!a()){let[e,t]=await Promise.all([Promise.all([r.e(9187),r.e(8885),r.e(9117),r.e(9192)]).then(()=>r(9192)),Promise.all([r.e(9187),r.e(8885),r.e(9117),r.e(5756)]).then(()=>r(15756)).then(({injectPe:e})=>e),(0,o.l)()]);i=new e.OperatorProject,t(o.p)}}function l(e,t,r){return i.clipToSpatialReference(e,t,null,r)}function c(e,t){return i.execute(e,t,null)}function s(e,t){let r=i.executeMany(new n.S(e),t,null);return Array.from(r)}function f(e,t){return i.foldInto360Range(e,t)}function m(e,t,r){return i.foldInto360RangeGeodetic(e,t,r)}function p(e,t,r){return i.normalizeGeometry(e,t,r)}function d(){return i.supportsCurves()}function y(e,t,r,n,o){return i.transform(e,t,r,n,o)}},83276(e,t,r){r.r(t),r.d(t,{execute:()=>G,executeMany:()=>v,isLoaded:()=>d,load:()=>h,projectExecute:()=>g,projectExecuteMany:()=>x,projectIsLoaded:()=>p,projectLoad:()=>y,projectSupportsCurves:()=>f,supportsCurves:()=>m});var n=r(4144),o=r(85036),i=r(17499);let a,u,l,c,s,f,m;function p(){return!!a&&(0,n.isLoaded)()}function d(){return(0,o.Q)("projectOperator","isLoaded","projectIsLoaded"),p()}async function y(){if(!p()){let[e,t]=await Promise.all([Promise.all([r.e(9187),r.e(8885),r.e(9117),r.e(3299),r.e(9567),r.e(9829),r.e(1666)]).then(()=>r(78125)),Promise.all([r.e(9187),r.e(8885),r.e(9117),r.e(6129)]).then(()=>r(86129)),(0,n.load)()]);a=e.fromGeometry,u=e.fromSpatialReference,l=e.getSpatialReference,c=e.toGeometry,s=t.createProjectionTransformation,f=(0,n.supportsCurves)(),m=f}}function h(){return(0,o.Q)("projectOperator","load","projectLoad"),y()}function g(e,t,r){let o=l(e),f=s(u(o),u(t),r),m=c((0,n.execute)(a(e),f),t);return!r?.zConversionDisabled&&m?.hasZ&&(0,i.g)([m],o,t),m}function G(e,t,r){return(0,o.Q)("projectOperator","execute","projectExecute"),g(e,t,r)}function x(e,t,r){let o=e.map(a),f=l(e),m=s(u(f),u(t),r),p=(0,n.executeMany)(o,m).map(e=>c(e,t));return!r?.zConversionDisabled&&p&&(0,i.g)(p,f,t),p}function v(e,t,r){return(0,o.Q)("projectOperator","executeMany","projectExecuteMany"),x(e,t,r)}},85036(e,t,r){r.d(t,{Q:()=>i});var n=r(51447),o=r(53966);function i(e,t,r){(0,n.io)(o.A.getLogger(`esri.geometry.operators.${e}`),`${t} is deprecated. Refactor using @arcgis/codemod or manually replace usages with ${r} instead.`,{replacement:r,warnOnce:!0})}},17499(e,t,r){r.d(t,{g:()=>i});var n=r(60408),o=r(62815);function i(e,t,r){let i;for(let a of e)if(a&&(0,n.Pv)(a)&&!("vertexAttributes"in a)){if(!i){let e="type"in a?a.type:(0,n.$B)(a);if(i=(0,o.N)(e,t,r),!i)return}i(a)}}},62815(e,t,r){r.d(t,{N:()=>u,d:()=>l});var n=r(86211),o=r(73941),i=r(21325),a=r(52006);function u(e,t,r){let n=l(t,r);if(1!==n)switch(e){case"point":case"esriGeometryPoint":return e=>function(e,t){null!=e?.z&&(e.z*=t)}(e,n);case"polyline":case"esriGeometryPolyline":return e=>function(e,t){if(e){if(e.curvePaths)for(let r of e.curvePaths)for(let e of r){let r=(0,a.yP)(e);r.length>2&&(r[2]*=t)}if(e.paths)for(let r of e.paths)for(let e of r)e.length>2&&(e[2]*=t)}}(e,n);case"polygon":case"esriGeometryPolygon":return e=>function(e,t){if(e){if(e.curveRings)for(let r of e.curveRings)for(let e of r){let r=(0,a.yP)(e);r.length>2&&(r[2]*=t)}if(e.rings)for(let r of e.rings)for(let e of r)e.length>2&&(e[2]*=t)}}(e,n);case"multipoint":case"esriGeometryMultipoint":return e=>function(e,t){if(e)for(let r of e.points)r.length>2&&(r[2]*=t)}(e,n);case"extent":case"esriGeometryEnvelope":return e=>function(e,t){e&&null!=e.zmin&&null!=e.zmax&&(e.zmin*=t,e.zmax*=t)}(e,n);default:return}}function l(e,t){return null==e||null==t||(0,i.aI)(e,t)||(0,o.xP)(e)||(0,o.xP)(t)?1:(0,n.G9)(e)/(0,n.G9)(t)}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3354,6707],{73354(t,e,n){n.d(e,{a:()=>f,b:()=>a,c:()=>i,d:()=>s,e:()=>c,f:()=>u,l:()=>h,n:()=>m,t:()=>o}),n(44208);var r=n(72727);function i(t,e,n){o(t.typedBuffer,e.typedBuffer,n,t.typedBufferStride,e.typedBufferStride)}function o(t,e,n,i=3,o=i){let s=(0,r.k)(t.length,i,3),a=(0,r.k)(e.length,o,3),l=Math.min(s,a),h=n[0],u=n[1],f=n[2],c=n[4],m=n[5],d=n[6],p=n[8],y=n[9],g=n[10],_=n[12],M=n[13],b=n[14],v=0,x=0;for(let n=0;n<l;n++){let n=e[v],r=e[v+1],s=e[v+2];t[x]=h*n+c*r+p*s+_,t[x+1]=u*n+m*r+y*s+M,t[x+2]=f*n+d*r+g*s+b,v+=o,x+=i}return t}function s(t,e,n){a(t.typedBuffer,e.typedBuffer,n,t.typedBufferStride,e.typedBufferStride)}function a(t,e,n,i=3,o=i){let s=(0,r.k)(t.length,i,3),a=(0,r.k)(e.length,o,3),l=Math.min(s,a),h=n[0],u=n[1],f=n[2],c=n[3],m=n[4],d=n[5],p=n[6],y=n[7],g=n[8],_=0,M=0;for(let n=0;n<l;n++){let n=e[_],r=e[_+1],s=e[_+2];t[M]=h*n+c*r+p*s,t[M+1]=u*n+m*r+y*s,t[M+2]=f*n+d*r+g*s,_+=o,M+=i}}function l(t,e,n,r=3,i=r){let o=Math.min(t.length/r,e.length/i),s=0,a=0;for(let l=0;l<o;l++)t[a]=n*e[s],t[a+1]=n*e[s+1],t[a+2]=n*e[s+2],s+=i,a+=r;return t}function h(t,e,n,r){u(t.typedBuffer,e.typedBuffer,n,r,t.typedBufferStride,e.typedBufferStride)}function u(t,e,n,r,i=3,o=i){let s=Math.min(t.length/i,e.length/o),a=0,l=0,h=1/2.2;for(let u=0;u<s;u++)t[l]=r*(n*e[a])**h,t[l+1]=r*(n*e[a+1])**h,t[l+2]=r*(n*e[a+2])**h,a+=o,l+=i}function f(t,e,n,i=3,o=i){let s=(0,r.k)(t.length,i,3),a=(0,r.k)(e.length,o,3),l=Math.min(s,a),h=0,u=0;for(let r=0;r<l;r++)t[u]=e[h]+n[0],t[u+1]=e[h+1]+n[1],t[u+2]=e[h+2]+n[2],h+=o,u+=i;return t}function c(t,e){m(t.typedBuffer,e.typedBuffer,t.typedBufferStride,e.typedBufferStride)}function m(t,e,n=3,r=n){let i=Math.min(t.length/n,e.length/r),o=0,s=0;for(let a=0;a<i;a++){let i=e[o],a=e[o+1],l=e[o+2],h=i*i+a*a+l*l;if(h>0){let e=1/Math.sqrt(h);t[s]=e*i,t[s+1]=e*a,t[s+2]=e*l}o+=r,s+=n}}Object.freeze(Object.defineProperty({__proto__:null,linearToSRGB:u,linearToSRGBView:h,normalize:m,normalizeView:c,scale:l,scaleView:function(t,e,n){l(t.typedBuffer,e.typedBuffer,n,t.typedBufferStride,e.typedBufferStride)},shiftRight:function(t,e,n){let r=Math.min(t.count,e.count),i=t.typedBuffer,o=t.typedBufferStride,s=e.typedBuffer,a=e.typedBufferStride,l=0,h=0;for(let t=0;t<r;t++)i[h]=s[l]>>n,i[h+1]=s[l+1]>>n,i[h+2]=s[l+2]>>n,l+=a,h+=o},transformMat3:a,transformMat3View:s,transformMat4:o,transformMat4View:i,translate:f},Symbol.toStringTag,{value:"Module"}))},69540(t,e,n){var r=n(32198),i=n(69622),o=(n(44208),n(4718)),s=(n(53966),n(97768)),a=n(88620),l=n(64108);const h=Symbol("ClonableMixin"),u=t=>{var e;let n=t,i=class extends n{constructor(){super(...arguments),this[e]=!0}static{e=h}clone(t){let e=(0,a.oY)(this);(0,s.Lw)(e,"unable to clone instance of non-accessor class");let n=e.metadata,r=e.store,i={},l=new Map;for(let e in n){let s=n[e],a=r?.originOf(e),h=s.clonable;if(s.readOnly||!1===h||7!==a&&0!==a&&5!==a&&4!==a)continue;let u=this[e],f=null;if("function"==typeof h)f=h(u,t);else if("reference"===h)f=u;else if(f=(0,o.TU)(u,t),null!=u&&null==f)continue;0===a?l.set(e,f):i[e]=f}let h=new(0,Object.getPrototypeOf(this).constructor)(i);if(l.size){let t=(0,a.oY)(h)?.store;if(t)for(let[e,n]of l)t.set(e,n,0)}return h}};return i=(0,r.Cg)([(0,l.$)("esri.core.Clonable")],i),i},f=u(i.A);n.d(e,["OU",0,u,"Pw",0,f])},9775(t,e,n){n.d(e,{A:()=>o});var r=n(62788),i=n(95488);class o{constructor(t=t=>t.values().next().value){this._peeker=t,this._observable=new i.I,this._items=new Set}get length(){return(0,r.gc)(this._observable),this._items.size}clear(){0!==this.length&&(this._items.clear(),this._observable.notify())}last(){if(0===this.length)return;let t;for(t of this._items);return t}peek(){if(0!==this.length)return this._peeker(this._items)}push(t){this.contains(t)||(this._items.add(t),this._observable.notify())}contains(t){return(0,r.gc)(this._observable),this._items.has(t)}pop(){if(0===this.length)return;let t=this.peek();return this._items.delete(t),this._observable.notify(),t}popLast(){if(0===this.length)return;let t=this.last();return this._items.delete(t),this._observable.notify(),t}remove(t){this.contains(t)&&(this._items.delete(t),this._observable.notify())}filter(t){let e=this.length;return this._items.forEach(e=>{t(e)||this._items.delete(e)}),e!==this._items.size&&this._observable.notify(),this}*[Symbol.iterator](){(0,r.gc)(this._observable),yield*this._items}}},95488(t,e,n){n.d(e,{I:()=>i});var r=n(11406);class i extends r.T{notify(){let t=this._observers;if(t&&t.length>0){let e=t.slice();for(let t of e)t.onInvalidated(),t.onCommitted()}}}},9093(t,e,n){function r(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function i(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:()=>i,vt:()=>r});const o=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:o,clone:i,create:r,fromValues:function(t,e,n,r,i,o,s,a,l,h,u,f,c,m,d,p){return[t,e,n,r,i,o,s,a,l,h,u,f,c,m,d,p]}},Symbol.toStringTag,{value:"Module"})),n.d(e,["zK",0,o])},51850(t,e,n){function r(){return[0,0,0]}function i(t){return[t[0],t[1],t[2]]}function o(t,e,n){return[t,e,n]}function s(t,e,n){return[t,e,n]}function a(t,e=[0,0,0]){let n=Math.min(3,t.length);for(let r=0;r<n;++r)e[r]=t[r];return e}function l(){return o(1,1,1)}function h(){return o(1,0,0)}function u(){return o(0,1,0)}function f(){return o(0,0,1)}n.d(e,{CN:()=>s,ci:()=>a,fA:()=>o,o8:()=>i,vt:()=>r});const c=[0,0,0],m=l(),d=h(),p=u(),y=f();Object.freeze(Object.defineProperty({__proto__:null,ONES:m,UNIT_X:d,UNIT_Y:p,UNIT_Z:y,ZEROS:c,clone:i,create:r,freeze:s,fromArray:a,fromValues:o,ones:l,unitX:h,unitY:u,unitZ:f,zeros:function(){return[0,0,0]}},Symbol.toStringTag,{value:"Module"})),n.d(e,["Cb",0,y,"Cw",0,d,"JP",0,p,"Un",0,m,"uY",0,c])},34304(t,e,n){n.d(e,{DF:()=>l,FD:()=>i,ct:()=>h});let r=1e-6;function i(){return r}const o=Math.random,s=Math.PI/180,a=180/Math.PI;function l(t){return t*s}function h(t){return t*a}Object.freeze(Object.defineProperty({__proto__:null,RANDOM:o,equals:function(t,e){return Math.abs(t-e)<=r*Math.max(1,Math.abs(t),Math.abs(e))},getEpsilon:i,setEpsilon:function(t){r=t},toDegree:h,toRadian:l},Symbol.toStringTag,{value:"Module"})),n.d(e,["Ov",0,o])},58083(t,e,n){n.d(e,{$0:()=>g,$h:()=>T,B8:()=>u,C:()=>o,D_:()=>a,N9:()=>M,O7:()=>w,Qw:()=>h,Tl:()=>c,X_:()=>S,e$:()=>d,eL:()=>p,hM:()=>_,hZ:()=>s,hs:()=>m,kN:()=>y,l:()=>A,lw:()=>f,mg:()=>l,o1:()=>R,sC:()=>x,t2:()=>I,t5:()=>C,tZ:()=>P,ut:()=>O});var r=n(51850),i=n(34304);function o(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[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function s(t,e,n,r,i,o,s,a,l,h,u,f,c,m,d,p,y){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=o,t[5]=s,t[6]=a,t[7]=l,t[8]=h,t[9]=u,t[10]=f,t[11]=c,t[12]=m,t[13]=d,t[14]=p,t[15]=y,t}function a(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function l(t,e){if(t===e){let n=e[1],r=e[2],i=e[3],o=e[6],s=e[7],a=e[11];t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=n,t[6]=e[9],t[7]=e[13],t[8]=r,t[9]=o,t[11]=e[14],t[12]=i,t[13]=s,t[14]=a}else t[0]=e[0],t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=e[1],t[5]=e[5],t[6]=e[9],t[7]=e[13],t[8]=e[2],t[9]=e[6],t[10]=e[10],t[11]=e[14],t[12]=e[3],t[13]=e[7],t[14]=e[11],t[15]=e[15];return t}function h(t,e){return u(t,e)||a(t),t}function u(t,e){let n=e[0],r=e[1],i=e[2],o=e[3],s=e[4],a=e[5],l=e[6],h=e[7],u=e[8],f=e[9],c=e[10],m=e[11],d=e[12],p=e[13],y=e[14],g=e[15],_=n*a-r*s,M=n*l-i*s,b=n*h-o*s,v=r*l-i*a,x=r*h-o*a,S=i*h-o*l,A=u*p-f*d,R=u*y-c*d,w=u*g-m*d,T=f*y-c*p,C=f*g-m*p,E=c*g-m*y,I=_*E-M*C+b*T+v*w-x*R+S*A;return I?(I=1/I,t[0]=(a*E-l*C+h*T)*I,t[1]=(i*C-r*E-o*T)*I,t[2]=(p*S-y*x+g*v)*I,t[3]=(c*x-f*S-m*v)*I,t[4]=(l*w-s*E-h*R)*I,t[5]=(n*E-i*w+o*R)*I,t[6]=(y*b-d*S-g*M)*I,t[7]=(u*S-c*b+m*M)*I,t[8]=(s*C-a*w+h*A)*I,t[9]=(r*w-n*C-o*A)*I,t[10]=(d*x-p*b+g*_)*I,t[11]=(f*b-u*x-m*_)*I,t[12]=(a*R-s*T-l*A)*I,t[13]=(n*T-r*R+i*A)*I,t[14]=(p*M-d*v-y*_)*I,t[15]=(u*v-f*M+c*_)*I,t):null}function f(t,e,n){let r=e[0],i=e[1],o=e[2],s=e[3],a=e[4],l=e[5],h=e[6],u=e[7],f=e[8],c=e[9],m=e[10],d=e[11],p=e[12],y=e[13],g=e[14],_=e[15],M=n[0],b=n[1],v=n[2],x=n[3];return t[0]=M*r+b*a+v*f+x*p,t[1]=M*i+b*l+v*c+x*y,t[2]=M*o+b*h+v*m+x*g,t[3]=M*s+b*u+v*d+x*_,M=n[4],b=n[5],v=n[6],x=n[7],t[4]=M*r+b*a+v*f+x*p,t[5]=M*i+b*l+v*c+x*y,t[6]=M*o+b*h+v*m+x*g,t[7]=M*s+b*u+v*d+x*_,M=n[8],b=n[9],v=n[10],x=n[11],t[8]=M*r+b*a+v*f+x*p,t[9]=M*i+b*l+v*c+x*y,t[10]=M*o+b*h+v*m+x*g,t[11]=M*s+b*u+v*d+x*_,M=n[12],b=n[13],v=n[14],x=n[15],t[12]=M*r+b*a+v*f+x*p,t[13]=M*i+b*l+v*c+x*y,t[14]=M*o+b*h+v*m+x*g,t[15]=M*s+b*u+v*d+x*_,t}function c(t,e,n){let r=n[0],i=n[1],o=n[2];if(e===t)t[12]=e[0]*r+e[4]*i+e[8]*o+e[12],t[13]=e[1]*r+e[5]*i+e[9]*o+e[13],t[14]=e[2]*r+e[6]*i+e[10]*o+e[14],t[15]=e[3]*r+e[7]*i+e[11]*o+e[15];else{let n=e[0],s=e[1],a=e[2],l=e[3],h=e[4],u=e[5],f=e[6],c=e[7],m=e[8],d=e[9],p=e[10],y=e[11];t[0]=n,t[1]=s,t[2]=a,t[3]=l,t[4]=h,t[5]=u,t[6]=f,t[7]=c,t[8]=m,t[9]=d,t[10]=p,t[11]=y,t[12]=n*r+h*i+m*o+e[12],t[13]=s*r+u*i+d*o+e[13],t[14]=a*r+f*i+p*o+e[14],t[15]=l*r+c*i+y*o+e[15]}return t}function m(t,e,n){let r=n[0],i=n[1],o=n[2];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]*i,t[5]=e[5]*i,t[6]=e[6]*i,t[7]=e[7]*i,t[8]=e[8]*o,t[9]=e[9]*o,t[10]=e[10]*o,t[11]=e[11]*o,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function d(t,e,n,r){let s=r[0],a=r[1],l=r[2],h=Math.sqrt(s*s+a*a+l*l);if(h<=(0,i.FD)())return void o(t,e);h=1/h,s*=h,a*=h,l*=h;let u=Math.sin(n),f=Math.cos(n),c=1-f,m=e[0],d=e[1],p=e[2],y=e[3],g=e[4],_=e[5],M=e[6],b=e[7],v=e[8],x=e[9],S=e[10],A=e[11],R=s*s*c+f,w=a*s*c+l*u,T=l*s*c-a*u,C=s*a*c-l*u,E=a*a*c+f,I=l*a*c+s*u,O=s*l*c+a*u,P=a*l*c-s*u,N=l*l*c+f;t[0]=m*R+g*w+v*T,t[1]=d*R+_*w+x*T,t[2]=p*R+M*w+S*T,t[3]=y*R+b*w+A*T,t[4]=m*C+g*E+v*I,t[5]=d*C+_*E+x*I,t[6]=p*C+M*E+S*I,t[7]=y*C+b*E+A*I,t[8]=m*O+g*P+v*N,t[9]=d*O+_*P+x*N,t[10]=p*O+M*P+S*N,t[11]=y*O+b*P+A*N,e!==t&&(t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15])}function p(t,e,n){let r=Math.sin(n),i=Math.cos(n),o=e[4],s=e[5],a=e[6],l=e[7],h=e[8],u=e[9],f=e[10],c=e[11];return e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[4]=o*i+h*r,t[5]=s*i+u*r,t[6]=a*i+f*r,t[7]=l*i+c*r,t[8]=h*i-o*r,t[9]=u*i-s*r,t[10]=f*i-a*r,t[11]=c*i-l*r,t}function y(t,e){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=e[0],t[13]=e[1],t[14]=e[2],t[15]=1,t}function g(t,e,n){if(0===e)return a(t);let r=n[0],o=n[1],s=n[2],l=Math.sqrt(r*r+o*o+s*s);if(l<=(0,i.FD)())return null;l=1/l,r*=l,o*=l,s*=l;let h=Math.sin(e),u=Math.cos(e),f=1-u;return t[0]=r*r*f+u,t[1]=o*r*f+s*h,t[2]=s*r*f-o*h,t[3]=0,t[4]=r*o*f-s*h,t[5]=o*o*f+u,t[6]=s*o*f+r*h,t[7]=0,t[8]=r*s*f+o*h,t[9]=o*s*f-r*h,t[10]=s*s*f+u,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function _(t,e){let n=Math.sin(e),r=Math.cos(e);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=r,t[6]=n,t[7]=0,t[8]=0,t[9]=-n,t[10]=r,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function M(t,e){let n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=n,t[2]=0,t[3]=0,t[4]=-n,t[5]=r,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function b(t,e,n){let r=e[0],i=e[1],o=e[2],s=e[3],a=r+r,l=i+i,h=o+o,u=r*a,f=r*l,c=r*h,m=i*l,d=i*h,p=o*h,y=s*a,g=s*l,_=s*h;return t[0]=1-(m+p),t[1]=f+_,t[2]=c-g,t[3]=0,t[4]=f-_,t[5]=1-(u+p),t[6]=d+y,t[7]=0,t[8]=c+g,t[9]=d-y,t[10]=1-(u+m),t[11]=0,t[12]=n[0],t[13]=n[1],t[14]=n[2],t[15]=1,t}const v=(0,r.vt)();function x(t,e){return t[0]=e[12],t[1]=e[13],t[2]=e[14],t}function S(t,e){let n=e[0],r=e[1],i=e[2],o=e[4],s=e[5],a=e[6],l=e[8],h=e[9],u=e[10];return t[0]=Math.sqrt(n*n+r*r+i*i),t[1]=Math.sqrt(o*o+s*s+a*a),t[2]=Math.sqrt(l*l+h*h+u*u),t}function A(t,e){let n=e[0]+e[5]+e[10],r=0;return n>0?(r=2*Math.sqrt(n+1),t[3]=.25*r,t[0]=(e[6]-e[9])/r,t[1]=(e[8]-e[2])/r,t[2]=(e[1]-e[4])/r):e[0]>e[5]&&e[0]>e[10]?(r=2*Math.sqrt(1+e[0]-e[5]-e[10]),t[3]=(e[6]-e[9])/r,t[0]=.25*r,t[1]=(e[1]+e[4])/r,t[2]=(e[8]+e[2])/r):e[5]>e[10]?(r=2*Math.sqrt(1+e[5]-e[0]-e[10]),t[3]=(e[8]-e[2])/r,t[0]=(e[1]+e[4])/r,t[1]=.25*r,t[2]=(e[6]+e[9])/r):(r=2*Math.sqrt(1+e[10]-e[0]-e[5]),t[3]=(e[1]-e[4])/r,t[0]=(e[8]+e[2])/r,t[1]=(e[6]+e[9])/r,t[2]=.25*r),t}function R(t,e,n,r){let i=e[0],o=e[1],s=e[2],a=e[3],l=i+i,h=o+o,u=s+s,f=i*l,c=i*h,m=i*u,d=o*h,p=o*u,y=s*u,g=a*l,_=a*h,M=a*u,b=r[0],v=r[1],x=r[2];return t[0]=(1-(d+y))*b,t[1]=(c+M)*b,t[2]=(m-_)*b,t[3]=0,t[4]=(c-M)*v,t[5]=(1-(f+y))*v,t[6]=(p+g)*v,t[7]=0,t[8]=(m+_)*x,t[9]=(p-g)*x,t[10]=(1-(f+d))*x,t[11]=0,t[12]=n[0],t[13]=n[1],t[14]=n[2],t[15]=1,t}function w(t,e,n,r,i){let o=e[0],s=e[1],a=e[2],l=e[3],h=o+o,u=s+s,f=a+a,c=o*h,m=o*u,d=o*f,p=s*u,y=s*f,g=a*f,_=l*h,M=l*u,b=l*f,v=r[0],x=r[1],S=r[2],A=i[0],R=i[1],w=i[2],T=(1-(p+g))*v,C=(m+b)*v,E=(d-M)*v,I=(m-b)*x,O=(1-(c+g))*x,P=(y+_)*x,N=(d+M)*S,L=(y-_)*S,D=(1-(c+p))*S;return t[0]=T,t[1]=C,t[2]=E,t[3]=0,t[4]=I,t[5]=O,t[6]=P,t[7]=0,t[8]=N,t[9]=L,t[10]=D,t[11]=0,t[12]=n[0]+A-(T*A+I*R+N*w),t[13]=n[1]+R-(C*A+O*R+L*w),t[14]=n[2]+w-(E*A+P*R+D*w),t[15]=1,t}function T(t,e,n,r,i,o,s){let a=1/(n-e),l=1/(i-r),h=1/(o-s);return t[0]=2*o*a,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=2*o*l,t[6]=0,t[7]=0,t[8]=(n+e)*a,t[9]=(i+r)*l,t[10]=(s+o)*h,t[11]=-1,t[12]=0,t[13]=0,t[14]=s*o*2*h,t[15]=0,t}function C(t,e,n,r){let o=e[0],s=e[1],l=e[2],h=o-n[0],u=s-n[1],f=l-n[2],c=(0,i.FD)();if(Math.abs(h)<c&&Math.abs(u)<c&&Math.abs(f)<c)return void a(t);let m=1/Math.sqrt(h*h+u*u+f*f);h*=m,u*=m,f*=m;let d=r[0],p=r[1],y=r[2],g=p*f-y*u,_=y*h-d*f,M=d*u-p*h;m=Math.sqrt(g*g+_*_+M*M),m?(m=1/m,g*=m,_*=m,M*=m):(g=0,_=0,M=0);let b=u*M-f*_,v=f*g-h*M,x=h*_-u*g;m=Math.sqrt(b*b+v*v+x*x),m?(m=1/m,b*=m,v*=m,x*=m):(b=0,v=0,x=0),t[0]=g,t[1]=b,t[2]=h,t[3]=0,t[4]=_,t[5]=v,t[6]=u,t[7]=0,t[8]=M,t[9]=x,t[10]=f,t[11]=0,t[12]=-(g*o+_*s+M*l),t[13]=-(b*o+v*s+x*l),t[14]=-(h*o+u*s+f*l),t[15]=1}function E(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t[3]=e[3]-n[3],t[4]=e[4]-n[4],t[5]=e[5]-n[5],t[6]=e[6]-n[6],t[7]=e[7]-n[7],t[8]=e[8]-n[8],t[9]=e[9]-n[9],t[10]=e[10]-n[10],t[11]=e[11]-n[11],t[12]=e[12]-n[12],t[13]=e[13]-n[13],t[14]=e[14]-n[14],t[15]=e[15]-n[15],t}function I(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[9]===e[9]&&t[10]===e[10]&&t[11]===e[11]&&t[12]===e[12]&&t[13]===e[13]&&t[14]===e[14]&&t[15]===e[15]}function O(t){let e=(0,i.FD)(),n=t[0],r=t[1],o=t[2],s=t[4],a=t[5],l=t[6],h=t[8],u=t[9],f=t[10];return Math.abs(1-(n*n+s*s+h*h))<=e&&Math.abs(1-(r*r+a*a+u*u))<=e&&Math.abs(1-(o*o+l*l+f*f))<=e}function P(t){return 1===t[0]&&0===t[1]&&0===t[2]&&0===t[4]&&1===t[5]&&0===t[6]&&0===t[8]&&0===t[9]&&1===t[10]}const N=f,L=E;Object.freeze(Object.defineProperty({__proto__:null,add:function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t[3]=e[3]+n[3],t[4]=e[4]+n[4],t[5]=e[5]+n[5],t[6]=e[6]+n[6],t[7]=e[7]+n[7],t[8]=e[8]+n[8],t[9]=e[9]+n[9],t[10]=e[10]+n[10],t[11]=e[11]+n[11],t[12]=e[12]+n[12],t[13]=e[13]+n[13],t[14]=e[14]+n[14],t[15]=e[15]+n[15],t},adjoint:function(t,e){let n=e[0],r=e[1],i=e[2],o=e[3],s=e[4],a=e[5],l=e[6],h=e[7],u=e[8],f=e[9],c=e[10],m=e[11],d=e[12],p=e[13],y=e[14],g=e[15];return t[0]=a*(c*g-m*y)-f*(l*g-h*y)+p*(l*m-h*c),t[1]=-(r*(c*g-m*y)-f*(i*g-o*y)+p*(i*m-o*c)),t[2]=r*(l*g-h*y)-a*(i*g-o*y)+p*(i*h-o*l),t[3]=-(r*(l*m-h*c)-a*(i*m-o*c)+f*(i*h-o*l)),t[4]=-(s*(c*g-m*y)-u*(l*g-h*y)+d*(l*m-h*c)),t[5]=n*(c*g-m*y)-u*(i*g-o*y)+d*(i*m-o*c),t[6]=-(n*(l*g-h*y)-s*(i*g-o*y)+d*(i*h-o*l)),t[7]=n*(l*m-h*c)-s*(i*m-o*c)+u*(i*h-o*l),t[8]=s*(f*g-m*p)-u*(a*g-h*p)+d*(a*m-h*f),t[9]=-(n*(f*g-m*p)-u*(r*g-o*p)+d*(r*m-o*f)),t[10]=n*(a*g-h*p)-s*(r*g-o*p)+d*(r*h-o*a),t[11]=-(n*(a*m-h*f)-s*(r*m-o*f)+u*(r*h-o*a)),t[12]=-(s*(f*y-c*p)-u*(a*y-l*p)+d*(a*c-l*f)),t[13]=n*(f*y-c*p)-u*(r*y-i*p)+d*(r*c-i*f),t[14]=-(n*(a*y-l*p)-s*(r*y-i*p)+d*(r*l-i*a)),t[15]=n*(a*c-l*f)-s*(r*c-i*f)+u*(r*l-i*a),t},copy:o,determinant:function(t){let e=t[0],n=t[1],r=t[2],i=t[3],o=t[4],s=t[5],a=t[6],l=t[7],h=t[8],u=t[9],f=t[10],c=t[11],m=t[12],d=t[13],p=t[14],y=t[15];return(e*s-n*o)*(f*y-c*p)-(e*a-r*o)*(u*y-c*d)+(e*l-i*o)*(u*p-f*d)+(n*a-r*s)*(h*y-c*m)-(n*l-i*s)*(h*p-f*m)+(r*l-i*a)*(h*d-u*m)},equals:function(t,e){if(t===e)return!0;let n=t[0],r=t[1],o=t[2],s=t[3],a=t[4],l=t[5],h=t[6],u=t[7],f=t[8],c=t[9],m=t[10],d=t[11],p=t[12],y=t[13],g=t[14],_=t[15],M=e[0],b=e[1],v=e[2],x=e[3],S=e[4],A=e[5],R=e[6],w=e[7],T=e[8],C=e[9],E=e[10],I=e[11],O=e[12],P=e[13],N=e[14],L=e[15],D=(0,i.FD)();return Math.abs(n-M)<=D*Math.max(1,Math.abs(n),Math.abs(M))&&Math.abs(r-b)<=D*Math.max(1,Math.abs(r),Math.abs(b))&&Math.abs(o-v)<=D*Math.max(1,Math.abs(o),Math.abs(v))&&Math.abs(s-x)<=D*Math.max(1,Math.abs(s),Math.abs(x))&&Math.abs(a-S)<=D*Math.max(1,Math.abs(a),Math.abs(S))&&Math.abs(l-A)<=D*Math.max(1,Math.abs(l),Math.abs(A))&&Math.abs(h-R)<=D*Math.max(1,Math.abs(h),Math.abs(R))&&Math.abs(u-w)<=D*Math.max(1,Math.abs(u),Math.abs(w))&&Math.abs(f-T)<=D*Math.max(1,Math.abs(f),Math.abs(T))&&Math.abs(c-C)<=D*Math.max(1,Math.abs(c),Math.abs(C))&&Math.abs(m-E)<=D*Math.max(1,Math.abs(m),Math.abs(E))&&Math.abs(d-I)<=D*Math.max(1,Math.abs(d),Math.abs(I))&&Math.abs(p-O)<=D*Math.max(1,Math.abs(p),Math.abs(O))&&Math.abs(y-P)<=D*Math.max(1,Math.abs(y),Math.abs(P))&&Math.abs(g-N)<=D*Math.max(1,Math.abs(g),Math.abs(N))&&Math.abs(_-L)<=D*Math.max(1,Math.abs(_),Math.abs(L))},exactEquals:I,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+t[9]**2+t[10]**2+t[11]**2+t[12]**2+t[13]**2+t[14]**2+t[15]**2)},fromQuat:function(t,e){let n=e[0],r=e[1],i=e[2],o=e[3],s=n+n,a=r+r,l=i+i,h=n*s,u=r*s,f=r*a,c=i*s,m=i*a,d=i*l,p=o*s,y=o*a,g=o*l;return t[0]=1-f-d,t[1]=u+g,t[2]=c-y,t[3]=0,t[4]=u-g,t[5]=1-h-d,t[6]=m+p,t[7]=0,t[8]=c+y,t[9]=m-p,t[10]=1-h-f,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromQuat2:function(t,e){let n=v,r=-e[0],i=-e[1],o=-e[2],s=e[3],a=e[4],l=e[5],h=e[6],u=e[7],f=r*r+i*i+o*o+s*s;return f>0?(n[0]=2*(a*s+u*r+l*o-h*i)/f,n[1]=2*(l*s+u*i+h*r-a*o)/f,n[2]=2*(h*s+u*o+a*i-l*r)/f):(n[0]=2*(a*s+u*r+l*o-h*i),n[1]=2*(l*s+u*i+h*r-a*o),n[2]=2*(h*s+u*o+a*i-l*r)),b(t,e,n),t},fromRotation:g,fromRotationTranslation:b,fromRotationTranslationScale:R,fromRotationTranslationScaleOrigin:w,fromScaling:function(t,e){return t[0]=e[0],t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=e[1],t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=e[2],t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromTranslation:y,fromXRotation:_,fromYRotation:function(t,e){let n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=0,t[2]=-n,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=n,t[9]=0,t[10]=r,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromZRotation:M,frustum:T,getRotation:A,getScale:S,getTranslation:x,hasIdentityRotation:P,identity:a,invert:u,invertOrIdentity:h,isOrthoNormal:O,lookAt:C,mul:N,multiply:f,multiplyScalar:function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t[4]=e[4]*n,t[5]=e[5]*n,t[6]=e[6]*n,t[7]=e[7]*n,t[8]=e[8]*n,t[9]=e[9]*n,t[10]=e[10]*n,t[11]=e[11]*n,t[12]=e[12]*n,t[13]=e[13]*n,t[14]=e[14]*n,t[15]=e[15]*n,t},multiplyScalarAndAdd:function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t[3]=e[3]+n[3]*r,t[4]=e[4]+n[4]*r,t[5]=e[5]+n[5]*r,t[6]=e[6]+n[6]*r,t[7]=e[7]+n[7]*r,t[8]=e[8]+n[8]*r,t[9]=e[9]+n[9]*r,t[10]=e[10]+n[10]*r,t[11]=e[11]+n[11]*r,t[12]=e[12]+n[12]*r,t[13]=e[13]+n[13]*r,t[14]=e[14]+n[14]*r,t[15]=e[15]+n[15]*r,t},ortho:function(t,e,n,r,i,o,s){let a=1/(e-n),l=1/(r-i),h=1/(o-s);return t[0]=-2*a,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*l,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=2*h,t[11]=0,t[12]=(e+n)*a,t[13]=(i+r)*l,t[14]=(s+o)*h,t[15]=1,t},perspective:function(t,e,n,r,i){let o,s=1/Math.tan(e/2);return t[0]=s/n,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=s,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,null!=i&&i!==1/0?(o=1/(r-i),t[10]=(i+r)*o,t[14]=2*i*r*o):(t[10]=-1,t[14]=-2*r),t},perspectiveFromFieldOfView:function(t,e,n,r){let i=Math.tan(e.upDegrees*Math.PI/180),o=Math.tan(e.downDegrees*Math.PI/180),s=Math.tan(e.leftDegrees*Math.PI/180),a=Math.tan(e.rightDegrees*Math.PI/180),l=2/(s+a),h=2/(i+o);return t[0]=l,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=h,t[6]=0,t[7]=0,t[8]=-(s-a)*l*.5,t[9]=(i-o)*h*.5,t[10]=r/(n-r),t[11]=-1,t[12]=0,t[13]=0,t[14]=r*n/(n-r),t[15]=0,t},rotate:d,rotateX:p,rotateY:function(t,e,n){let r=Math.sin(n),i=Math.cos(n),o=e[0],s=e[1],a=e[2],l=e[3],h=e[8],u=e[9],f=e[10],c=e[11];return e!==t&&(t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=o*i-h*r,t[1]=s*i-u*r,t[2]=a*i-f*r,t[3]=l*i-c*r,t[8]=o*r+h*i,t[9]=s*r+u*i,t[10]=a*r+f*i,t[11]=l*r+c*i,t},rotateZ:function(t,e,n){let r=Math.sin(n),i=Math.cos(n),o=e[0],s=e[1],a=e[2],l=e[3],h=e[4],u=e[5],f=e[6],c=e[7];return e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=o*i+h*r,t[1]=s*i+u*r,t[2]=a*i+f*r,t[3]=l*i+c*r,t[4]=h*i-o*r,t[5]=u*i-s*r,t[6]=f*i-a*r,t[7]=c*i-l*r,t},scale:m,set:s,str:function(t){return"mat4("+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]+")"},sub:L,subtract:E,targetTo:function(t,e,n,r){let i=e[0],o=e[1],s=e[2],a=r[0],l=r[1],h=r[2],u=i-n[0],f=o-n[1],c=s-n[2],m=u*u+f*f+c*c;m>0&&(m=1/Math.sqrt(m),u*=m,f*=m,c*=m);let d=l*c-h*f,p=h*u-a*c,y=a*f-l*u;return m=d*d+p*p+y*y,m>0&&(m=1/Math.sqrt(m),d*=m,p*=m,y*=m),t[0]=d,t[1]=p,t[2]=y,t[3]=0,t[4]=f*y-c*p,t[5]=c*d-u*y,t[6]=u*p-f*d,t[7]=0,t[8]=u,t[9]=f,t[10]=c,t[11]=0,t[12]=i,t[13]=o,t[14]=s,t[15]=1,t},translate:c,transpose:l},Symbol.toStringTag,{value:"Module"}))},35522(t,e,n){n.d(e,{$A:()=>R,Bw:()=>o,C:()=>s,Cc:()=>w,DI:()=>x,Io:()=>_,Ln:()=>g,Om:()=>A,Qr:()=>f,Re:()=>h,S8:()=>S,T9:()=>p,WQ:()=>l,Z0:()=>T,_S:()=>m,aI:()=>L,ei:()=>C,fw:()=>I,gL:()=>E,hG:()=>M,hZ:()=>a,hs:()=>y,jk:()=>d,lw:()=>u,m3:()=>b,oW:()=>D,t2:()=>N,tn:()=>c,ze:()=>v});var r=n(51850),i=n(34304);function o(t){let e=t[0],n=t[1],r=t[2];return Math.sqrt(e*e+n*n+r*r)}function s(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 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 h(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],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 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 c(t,e){return t[0]=Math.abs(e[0]),t[1]=Math.abs(e[1]),t[2]=Math.abs(e[2]),t}function m(t,e){return t[0]=Math.sign(e[0]),t[1]=Math.sign(e[1]),t[2]=Math.sign(e[2]),t}function d(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 p(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 g(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 _(t,e){let n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return Math.sqrt(n*n+r*r+i*i)}function M(t,e){let n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return n*n+r*r+i*i}function b(t){let e=t[0],n=t[1],r=t[2];return e*e+n*n+r*r}function v(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t}function x(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t}function S(t,e=t){let n=e[0],r=e[1],i=e[2],o=n*n+r*r+i*i;return o>0&&(o=1/Math.sqrt(o),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o),t}function A(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function R(t,e,n){let r=e[0],i=e[1],o=e[2],s=n[0],a=n[1],l=n[2];return t[0]=i*l-o*a,t[1]=o*s-r*l,t[2]=r*a-i*s,t}function w(t,e,n,r){let i=e[0],o=e[1],s=e[2];return t[0]=i+r*(n[0]-i),t[1]=o+r*(n[1]-o),t[2]=s+r*(n[2]-s),t}function T(t,e,n){let r=e[0],i=e[1],o=e[2];return t[0]=n[0]*r+n[4]*i+n[8]*o+n[12],t[1]=n[1]*r+n[5]*i+n[9]*o+n[13],t[2]=n[2]*r+n[6]*i+n[10]*o+n[14],t}function C(t,e,n){let r=e[0],i=e[1],o=e[2];return t[0]=r*n[0]+i*n[3]+o*n[6],t[1]=r*n[1]+i*n[4]+o*n[7],t[2]=r*n[2]+i*n[5]+o*n[8],t}function E(t,e,n){return I(t,e,n[0],n[1],n[2],n[3])}function I(t,e,n,r,i,o){let s=e[0],a=e[1],l=e[2],h=r*l-i*a,u=i*s-n*l,f=n*a-r*s,c=r*f-i*u,m=i*h-n*f,d=n*u-r*h,p=2*o;return t[0]=s+h*p+2*c,t[1]=a+u*p+2*m,t[2]=l+f*p+2*d,t}const O=(0,r.vt)(),P=(0,r.vt)();function N(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]}function L(t,e){if(t===e)return!0;let n=t[0],r=t[1],o=t[2],s=e[0],a=e[1],l=e[2],h=(0,i.FD)();return Math.abs(n-s)<=h*Math.max(1,Math.abs(n),Math.abs(s))&&Math.abs(r-a)<=h*Math.max(1,Math.abs(r),Math.abs(a))&&Math.abs(o-l)<=h*Math.max(1,Math.abs(o),Math.abs(l))}function D(t,e,n){let r=n[0]-e[0],i=n[1]-e[1],o=n[2]-e[2],s=r*r+i*i+o*o;return s>0?(s=1/Math.sqrt(s),t[0]=r*s,t[1]=i*s,t[2]=o*s,t):(t[0]=0,t[1]=0,t[2]=0,t)}const B=h,G=u,U=f,F=_,j=M,k=o,Z=b;Object.freeze(Object.defineProperty({__proto__:null,abs:c,add:l,angle:function(t,e){S(O,t),S(P,e);let n=A(O,P);return n>1?0:n<-1?Math.PI:Math.acos(n)},bezier:function(t,e,n,r,i,o){let s=1-o,a=s*s,l=o*o,h=a*s,u=3*o*a,f=3*l*s,c=l*o;return t[0]=e[0]*h+n[0]*u+r[0]*f+i[0]*c,t[1]=e[1]*h+n[1]*u+r[1]*f+i[1]*c,t[2]=e[2]*h+n[2]*u+r[2]*f+i[2]*c,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:s,cross:R,crossAndNormalize:function(t,e,n){let r=e[0],i=e[1],o=e[2],s=n[0],a=n[1],l=n[2],h=i*l-o*a,u=o*s-r*l,f=r*a-i*s,c=Math.sqrt(h*h+u*u+f*f);return t[0]=h/c,t[1]=u/c,t[2]=f/c,t},direction:D,dist:F,distance:_,div:U,divide:f,dot:A,equals:L,exactEquals:N,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,i,o){let s=o*o,a=s*(2*o-3)+1,l=s*(o-2)+o,h=s*(o-1),u=s*(3-2*o);return t[0]=e[0]*a+n[0]*l+r[0]*h+i[0]*u,t[1]=e[1]*a+n[1]*l+r[1]*h+i[1]*u,t[2]=e[2]*a+n[2]*l+r[2]*h+i[2]*u,t},inverse:x,len:k,length:o,lerp:w,max:p,min:d,mul:G,multiply:u,negate:v,normalize:S,random:function(t,e=1){let n=i.Ov,r=2*n()*Math.PI,o=2*n()-1,s=Math.sqrt(1-o*o)*e;return t[0]=Math.cos(r)*s,t[1]=Math.sin(r)*s,t[2]=o*e,t},rotateX:function(t,e,n,r){let i=[],o=[];return i[0]=e[0]-n[0],i[1]=e[1]-n[1],i[2]=e[2]-n[2],o[0]=i[0],o[1]=i[1]*Math.cos(r)-i[2]*Math.sin(r),o[2]=i[1]*Math.sin(r)+i[2]*Math.cos(r),t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[2]+n[2],t},rotateY:function(t,e,n,r){let i=[],o=[];return i[0]=e[0]-n[0],i[1]=e[1]-n[1],i[2]=e[2]-n[2],o[0]=i[2]*Math.sin(r)+i[0]*Math.cos(r),o[1]=i[1],o[2]=i[2]*Math.cos(r)-i[0]*Math.sin(r),t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[2]+n[2],t},rotateZ:function(t,e,n,r){let i=[],o=[];return i[0]=e[0]-n[0],i[1]=e[1]-n[1],i[2]=e[2]-n[2],o[0]=i[0]*Math.cos(r)-i[1]*Math.sin(r),o[1]=i[0]*Math.sin(r)+i[1]*Math.cos(r),o[2]=i[2],t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[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:g,scaleTo:function(t,e){return y(t,t,e/k(t))},set:a,sign:m,sqrDist:j,sqrLen:Z,squaredDistance:M,squaredLength:b,str:function(t){return"vec3("+t[0]+", "+t[1]+", "+t[2]+")"},sub:B,subtract:h,transformMat3:C,transformMat4:T,transformMat4Z:function(t,e){return e[2]*t[0]+e[6]*t[1]+e[10]*t[2]+e[14]},transformQuat:E,transformQuatValues:I},Symbol.toStringTag,{value:"Module"})),n.d(e,["Il",0,k,"jb",0,B,"lo",0,j,"uE",0,Z])},83027(t,e,n){const r=n(29953).ho;n.d(e,["h",0,r])},35982(t,e,n){n.d(e,{B:()=>u});var r=n(4576),i=n(71511),o=n(36563),s=n(53966),a=n(97768),l=n(17676),h=n(83027);class u{constructor(t,e,n,r,i={}){this._mainMethod=e,this._transferLists=n,this._listeners=[],this._onClientConnectedHandle=null,this._destroyed=!1,this._promise=(0,h.h)(t,{...i,schedule:r}).then(t=>{null!=this._thread||this._destroyed?t.close():(this._thread=t,this._promise=null,this._onClientConnectedHandle=this._thread.onClientConnected(t=>{i.hasInitialize&&t.invoke("initialize",{}).catch(()=>{});for(let e of this._listeners)this._connectListenerToClient(e,t);this._onClientConnected(t)}))}),this._promise.catch(e=>s.A.getLogger("esri.core.workers.WorkerHandle").error(`Failed to initialize ${t} worker: ${e}`))}on(t,e){let n=new f(t,e);return this._listeners.push(n),this._connectListener(n),(0,o.hA)(()=>{(0,r.TF)(this._listeners,n),n.destroy()})}[Symbol.dispose](){this.destroy()}destroy(){this._onClientConnectedHandle=(0,a.xt)(this._onClientConnectedHandle),this._thread&&=(this._thread.close(),null),this._promise=null;for(let t of this._listeners)t.destroy();this._listeners.length=0,this._transferLists={},this._destroyed=!0}invoke(t,e,n){return this.invokeMethod(this._mainMethod,t,e,n)}invokeMethod(t,e,n,r){if(this._thread){let i=this._transferLists[t],o=i?i(e):[];return this._thread.invoke(t,e,{transferList:o,signal:n,jobPriority:r})}return this._promise?this._promise.then(()=>((0,l.Te)(n),this.invokeMethod(t,e,n))):Promise.reject((0,l.NK)())}broadcast(t,e){return this._thread?Promise.all(this._thread.broadcast(e,t)).then(c):this._promise?this._promise.then(()=>this.broadcast(t,e)):Promise.reject((0,l.NK)())}get promise(){return this._promise}_onClientConnected(t){}_connectListener(t){this._thread&&t.add(this._thread.on(t.eventName,t.callback))}_connectListenerToClient(t,e){t.add(e.on(t.eventName,t.callback))}}class f{constructor(t,e){this.eventName=t,this.callback=e,this._handles=new i.A}add(t){this._handles.add(t)}destroy(){this._handles.destroy()}}function c(){}},48526(t,e,n){n.d(e,{A:()=>y});var r,i=n(32198),o=n(4576),s=n(4718),a=n(91429),l=n(5443),h=n(91075),u=n(86738),f=n(16930),c=n(90634),m=n(47610),d=n(56993),p=n(43937);let y=r=class extends h.A{constructor(t){super(function(t){if(!t)return;let{points:e,hasM:n,hasZ:r,spatialReference:i}=t;switch(e??=[],e?.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??=f.A.WGS84,{...t,hasM:n,hasZ:r,points:e,spatialReference:i}}(t)),this.points=[],this.type="multipoint"}get cache(){return this.commitProperty("points"),this.commitProperty("hasZ"),this.commitProperty("hasM"),this.commitProperty("spatialReference"),{}}get extent(){let t=(0,c.ge)(this);return t?new l.A({...t,spatialReference:this.spatialReference}):null}writePoints(t,e){e.points=(0,s.o8)(this.points)}clone(){let{points:t,spatialReference:e,hasM:n,hasZ:i}=this;return new r({points:(0,s.o8)(t),spatialReference:e.clone(),hasM:n,hasZ:i})}equals(t){if(this===t)return!0;if(null==t)return!1;let e=this.spatialReference,n=t.spatialReference;return!(null!=e!=(null!=n)||null!=e&&null!=n&&!e.equals(n))&&(0,o.aI)(this.points,t.points,m.v6)}addPoint(t){return(0,d.h)(this,t),Array.isArray(t)?this.points.push(t):this.points.push(t.toArray()),this.notifyChange("points"),this}getPoint(t){if(!this._validateInputs(t))return null;let e=this.points[t],n={x:e[0],y:e[1],spatialReference:this.spatialReference},r=2;return this.hasZ&&(n.z=e[2],r=3),this.hasM&&(n.m=e[r]),new u.A(n)}removePoint(t){if(!this._validateInputs(t))return null;let e=new u.A(this.points.splice(t,1)[0],this.spatialReference);return this.notifyChange("points"),e}setPoint(t,e){return this._validateInputs(t)?((0,d.h)(this,e),Array.isArray(e)||(e=e.toArray()),this.points[t]=e,this.notifyChange("points"),this):this}toJSON(t){return this.write({},t)}_validateInputs(t){return null!=t&&t>=0&&t<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,p.K)("points")],y.prototype,"writePoints",null),y=r=(0,i.Cg)([(0,a.$K)("esri.geometry.Multipoint")],y),y.prototype.toJSON.isDefaultToJSON=!0},82799(t,e,n){n.d(e,{A:()=>d});var r,i=n(32198),o=n(4718),s=n(91429),a=n(5443),l=n(91075),h=n(86738),u=n(16930),f=n(90634),c=n(56993),m=n(43937);let d=r=class extends l.A{constructor(t){super(function(t){if(!t)return;let{paths:e,hasM:n,hasZ:r,spatialReference:i}=t;switch(e??=[],function(t){return"number"==typeof t[0]?.[0]}(e)&&(e=[e]),e[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??=u.A.WGS84,{...t,hasM:n,hasZ:r,paths:e,spatialReference:i}}(t)),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(t,e){e.curvePaths=(0,o.o8)(t)}get extent(){let t=(0,f.Z3)(this),{spatialReference:e}=this;return t?new a.A({...t,spatialReference:e}):null}writePaths(t,e){e.paths=(0,o.o8)(this.paths)}addPath(t){if(!t)return;let e=this.paths,n=e.length;if(function(t){return!Array.isArray(t[0])}(t)){let r=[];for(let e=0,n=t.length;e<n;e++)r[e]=t[e].toArray();e[n]=r}else e[n]=t.slice();return this.notifyChange("paths"),this}clone(){let t=new r;return t.spatialReference=this.spatialReference,t.paths=(0,o.o8)(this.paths),t.curvePaths=(0,o.o8)(this.curvePaths),t.hasZ=this.hasZ,t.hasM=this.hasM,t}getPoint(t,e){if(!this._validateInputs(t,e))return null;let n=this.paths[t][e],r=this.hasZ,i=this.hasM;return r&&!i?new h.A(n[0],n[1],n[2],void 0,this.spatialReference):i&&!r?new h.A(n[0],n[1],void 0,n[2],this.spatialReference):r&&i?new h.A(n[0],n[1],n[2],n[3],this.spatialReference):new h.A(n[0],n[1],this.spatialReference)}insertPoint(t,e,n){return this._validateInputs(t,e,!0)?((0,c.h)(this,n),Array.isArray(n)||(n=n.toArray()),this.paths[t].splice(e,0,n),this.notifyChange("paths"),this):this}removePath(t){if(!this._validateInputs(t,null))return null;let e=this.paths.splice(t,1)[0],n=this.spatialReference,r=e.map(t=>new h.A(t,n));return this.notifyChange("paths"),r}removePoint(t,e){if(!this._validateInputs(t,e))return null;let n=new h.A(this.paths[t].splice(e,1)[0],this.spatialReference);return this.notifyChange("paths"),n}setPoint(t,e,n){return this._validateInputs(t,e)?((0,c.h)(this,n),Array.isArray(n)||(n=n.toArray()),this.paths[t][e]=n,this.notifyChange("paths"),this):this}_validateInputs(t,e,n=!1){if(null==t||t<0||t>=this.paths.length)return!1;if(null!=e){let r=this.paths[t];if(n&&(e<0||e>r.length)||!n&&(e<0||e>=r.length))return!1}return!0}toJSON(t){return this.write({},t)}};(0,i.Cg)([(0,s.MZ)({readOnly:!0})],d.prototype,"cache",null),(0,i.Cg)([(0,s.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,m.K)("curvePaths")],d.prototype,"writeCurvePaths",null),(0,i.Cg)([(0,s.MZ)({readOnly:!0})],d.prototype,"extent",null),(0,i.Cg)([(0,s.MZ)({type:[[[Number]]],json:{write:{isRequired:!0}}})],d.prototype,"paths",void 0),(0,i.Cg)([(0,m.K)("paths")],d.prototype,"writePaths",null),d=r=(0,i.Cg)([(0,s.$K)("esri.geometry.Polyline")],d),d.prototype.toJSON.isDefaultToJSON=!0},65806(t,e,n){n.d(e,{g:()=>s});var r=n(51850),i=n(99917),o=n(9762);function s(t,e,n,r){if((0,i.canProjectWithoutEngine)(t.spatialReference,n))return a[0]=t.x,a[1]=t.y,a[2]=t.z??0,(0,o.projectBuffer)(a,t.spatialReference,0,e,n,0);let s=(0,i.tryProject)(t,n,r);return!!s&&(e[0]=s.x,e[1]=s.y,e[2]=s.z??0,!0)}const a=(0,r.vt)()},27993(t,e,n){n.d(e,{F:()=>a});var r=n(99917),i=n(16930),o=n(9762),s=n(65806);function a(t,e,n,i){return!(null==e||null==i||t.length<2)&&((0,r.canProjectWithoutEngine)(e,i)?(0,o.projectBuffer)(t,e,0,n,i,0,1):(l.x=t[0],l.y=t[1],l.z=t[2],l.spatialReference=e,(0,s.g)(l,n,i)))}const l={x:0,y:0,z:0,hasZ:!0,hasM:!1,spatialReference:i.A.WGS84,type:"point"}},4197(t,e,n){n.d(e,{Vj:()=>u,cj:()=>h,jh:()=>o,l5:()=>a,yH:()=>l});var r=n(34275),i=n(9093);function o(t){return t<=1024?Array(t).fill(0):new Float64Array(t)}function s(t){return((0,r.iu)(t)?t.byteLength/8:t.length)<=1024?Array.from(t):new Float64Array(t)}function a(t,e,n){return Array.isArray(t)?t.slice(e,e+n):t.subarray(e,e+n)}function l(t,e){if(0===e.length)return s(t);if(0===t.length)return s(e);let n=o(t.length+e.length);for(let e=0;e<t.length;++e)n[e]=t[e];for(let r=0;r<e.length;++r)n[t.length+r]=e[r];return n}function h(t){return[...t]}function u(t){let e=(0,i.vt)();for(let n=0;n<16;++n)e[n]=t[n];return e}},95696(t,e,n){n.d(e,{A:()=>h});var r,i=n(32198),o=n(69540),s=n(25482),a=n(91429),l=n(93223);let h=class extends((0,o.OU)(s.o)){static{r=this}constructor(t){super(t),this.type="georeferenced",this.origin=null}static{this.absolute=new r}};(0,i.Cg)([(0,l.e)({georeferenced:"georeferenced"},{readOnly:!0})],h.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],nonNullable:!1,json:{write:!0}})],h.prototype,"origin",void 0),h=r=(0,i.Cg)([(0,a.$K)("esri.geometry.support.MeshGeoreferencedVertexSpace")],h)},18251(t,e,n){n.d(e,{A:()=>h});var r=n(32198),i=n(69540),o=n(25482),s=n(91429),a=n(51850),l=n(93223);let h=class extends((0,i.OU)(o.o)){constructor(t){super(t),this.type="local",this.origin=(0,a.vt)()}};(0,r.Cg)([(0,l.e)({local:"local"},{readOnly:!0})],h.prototype,"type",void 0),(0,r.Cg)([(0,s.MZ)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"origin",void 0),h=(0,r.Cg)([(0,s.$K)("esri.geometry.support.MeshLocalVertexSpace")],h)},72727(t,e,n){function r(t,e,n){if(e<=0)return 0;let r=t-n;return r<0?0:Math.floor(r/e)+1}n.d(e,{k:()=>r}),n(53966)},52006(t,e,n){function r(t){return"curveRings"in t&&!!t.curveRings?.length||"curvePaths"in t&&!!t.curvePaths?.length}function i(t){return"curveRings"in t?t.curveRings:t.curvePaths}function o(t){return"b"in t}function s(t){return"c"in t}function a(t){return Array.isArray(t)}function l(t){return"a"in t}function h(t){return"a"in t&&4===t.a.length}function u(t){return"a"in t&&7===t.a.length}function f(t,e){return i(t).flat().some(t=>function(t,e){return!(a(t)||(o(t)?e.has("cubic-bezier"):s(t)?e.has("circular-arc"):!h(t)&&!u(t)||e.has("elliptic-arc")))}(t,e))}function c(t){return a(t)?t:o(t)?t.b[0]:s(t)?t.c[0]:t.a[0]}function m(t){if(o(t)){let[e,n,r]=t.b;return{b:[[...e],[...n],[...r]]}}if(s(t)){let[e,n]=t.c;return{c:[[...e],[...n]]}}if(a(t))return[...t];if(h(t)){let[e,n,r,i]=t.a;return{a:[[...e],[...n],r,i]}}if(u(t)){let[e,n,r,i,o,s,a]=t.a;return{a:[[...e],[...n],r,i,o,s,a]}}return t}n.d(e,{DA:()=>h,Ed:()=>r,FD:()=>i,FG:()=>l,V8:()=>f,Xq:()=>a,aO:()=>s,n1:()=>o,tk:()=>m,wY:()=>u,yP:()=>c}),n(4576)},60408(t,e,n){function r(t){return void 0!==t.xmin&&void 0!==t.ymin&&void 0!==t.xmax&&void 0!==t.ymax}function i(t){return void 0!==t.points}function o(t){return void 0!==t.x&&void 0!==t.y}function s(t){return void 0!==t.paths||void 0!==t.curvePaths}function a(t){return void 0!==t.rings||void 0!==t.curveRings}function l(t){return"object"==typeof t&&"vertexAttributes"in t}function h(t){return t?o(t)?"esriGeometryPoint":s(t)?"esriGeometryPolyline":a(t)?"esriGeometryPolygon":r(t)?"esriGeometryEnvelope":i(t)?"esriGeometryMultipoint":null:null}function u(t){return null!=t&&("hasZ"in t&&t.hasZ||"z"in t&&null!=t.z)}function f(t){return null!=t&&("hasM"in t&&t.hasM||"m"in t&&null!=t.m)}n.d(e,{$B:()=>h,Bi:()=>a,Pv:()=>u,Rg:()=>s,U9:()=>i,W0:()=>f,ZC:()=>r,fT:()=>o,uW:()=>l})},80754(t,e,n){n.d(e,{kS:()=>h,kd:()=>l});var r=n(82799),i=n(16930),o=n(60408),s=n(52006);const a={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new r.A({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:i.A.WebMercator}),minus180Line:new r.A({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:i.A.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new r.A({paths:[[[180,-180],[180,180]]],spatialReference:i.A.WGS84}),minus180Line:new r.A({paths:[[[-180,-180],[-180,180]]],spatialReference:i.A.WGS84})}};function l(t,e){return Math.ceil((t-e)/(2*e))}function h(t,e){if((0,s.Ed)(t))for(let n of function(t){return(0,o.Bi)(t)?t.curveRings:t.curvePaths}(t))for(let t of n){if((0,s.aO)(t)){let[n,r]=t.c;n[0]+=e,r[0]+=e;continue}if((0,s.FG)(t)){let[n,r]=t.a;n[0]+=e,r[0]+=e;continue}if((0,s.n1)(t)){let[n,r,i]=t.b;n[0]+=e,r[0]+=e,i[0]+=e;continue}t[0]+=e}for(let n of function(t){return(0,o.Bi)(t)?t.rings:t.paths}(t))for(let t of n)t[0]+=e;return t}n.d(e,["j7",0,a])},89056(t,e,n){n.d(e,{b3:()=>f,jZ:()=>u});var r=n(12195),i=n(19419),o=n(537),s=n(95108),a=n(60408),l=n(80754),h=n(21325);function u(t){return c(t,!0)}function f(t){return c(t,!1)}function c(t,e){if(null==t)return null;let n=t.spatialReference,i=(0,h.Vp)(n),s=(0,r.W)(t)?t.toJSON():t;if(!i)return s;let u=(0,h.K8)(n)?102100:4326,f=l.j7[u].maxX,c=l.j7[u].minX;if((0,a.fT)(s))return d(s,f,c);if((0,a.U9)(s))return s.points=s.points.map(t=>d(t,f,c)),s;if((0,a.ZC)(s))return m(s,i);if((0,a.Bi)(s)||(0,a.Rg)(s)){let t=(0,o.Rg)(b,s),n={xmin:t[0],ymin:t[1],xmax:t[2],ymax:t[3]},r=(0,l.kd)(n.xmin,c),i=2*f*r,a=0===i?s:(0,l.kS)(s,i);return n.xmin+=i,n.xmax+=i,n.xmax>f?_(a,f,e):n.xmin<c?_(a,c,e):a}return s}function m(t,e){if(!e)return t;let n=function(t,e){let n=[],{ymin:r,ymax:i,xmin:o,xmax:s}=t,a=t.xmax-t.xmin,[l,h]=e.valid,{x:u,frameId:f}=p(t.xmin,e),{x:c,frameId:m}=p(t.xmax,e),d=u===c&&a>0;if(a>2*h){let t={xmin:o<s?u:c,ymin:r,xmax:h,ymax:i},e={xmin:l,ymin:r,xmax:o<s?c:u,ymax:i},a={xmin:0,ymin:r,xmax:h,ymax:i},d={xmin:l,ymin:r,xmax:0,ymax:i},p=[],g=[];y(t,a)&&p.push(f),y(t,d)&&g.push(f),y(e,a)&&p.push(m),y(e,d)&&g.push(m);for(let t=f+1;t<m;t++)p.push(t),g.push(t);n.push(new M(t,[f]),new M(e,[m]),new M(a,p),new M(d,g))}else u>c||d?n.push(new M({xmin:u,ymin:r,xmax:h,ymax:i},[f]),new M({xmin:l,ymin:r,xmax:c,ymax:i},[m])):n.push(new M({xmin:u,ymin:r,xmax:c,ymax:i},[f]));return n}(t,e).map(t=>t.extent);return n.length<2?n[0]||t:n.length>2?(t.xmin=e.valid[0],t.xmax=e.valid[1],t):{rings:n.map(t=>[[t.xmin,t.ymin],[t.xmin,t.ymax],[t.xmax,t.ymax],[t.xmax,t.ymin],[t.xmin,t.ymin]])}}function d(t,e,n){if(Array.isArray(t)){let r=t[0];if(r>e){let n=(0,l.kd)(r,e);t[0]=r+-2*e*n}else if(r<n){let e=(0,l.kd)(r,n);t[0]=r+-2*n*e}}else{let r=t.x;if(r>e){let n=(0,l.kd)(r,e);t.x+=-2*e*n}else if(r<n){let e=(0,l.kd)(r,n);t.x+=-2*n*e}}return t}function p(t,e){let n,[r,i]=e.valid,o=2*i,s=0;return t>i?(n=Math.ceil(Math.abs(t-i)/o),t-=n*o,s=n):t<r&&(n=Math.ceil(Math.abs(t-r)/o),t+=n*o,s=-n),{x:t,frameId:s}}function y(t,e){let{xmin:n,ymin:r,xmax:i,ymax:o}=e;return g(t,n,r)&&g(t,n,o)&&g(t,i,o)&&g(t,i,r)}function g(t,e,n){return e>=t.xmin&&e<=t.xmax&&n>=t.ymin&&n<=t.ymax}function _(t,e,n=!0){let r=!(0,a.Rg)(t);if(r&&(0,s.m3)(t),n)return(new v).cut(t,e);let i=r?t.rings:t.paths,o=r?4:2,l=i.length,h=-2*e;for(let t=0;t<l;t++){let e=i[t];if(e&&e.length>=o){let t=[];for(let[n,...r]of e)t.push([n+h,...r]);i.push(t)}}return r?t.rings=i:t.paths=i,t}class M{constructor(t,e){this.extent=t,this.frameIds=e}}const b=(0,i.vt)();class v{constructor(){this._linesIn=[],this._linesOut=[]}cut(t,e){let n;if(this._xCut=e,t.rings)this._closed=!0,n=t.rings,this._minPts=4;else{if(!t.paths)return null;this._closed=!1,n=t.paths,this._minPts=2}for(let t of n){if(!t||t.length<this._minPts)continue;let e=!0;for(let n of t)e?(this.moveTo(n),e=!1):this.lineTo(n);this._closed&&this.close()}this._pushLineIn(),this._pushLineOut(),n=[];for(let t of this._linesIn)t&&t.length>=this._minPts&&n.push(t);let r=-2*this._xCut;for(let t of this._linesOut)if(t&&t.length>=this._minPts){for(let e of t)e[0]+=r;n.push(t)}return this._closed?t.rings=n:t.paths=n,t}moveTo(t){this._pushLineIn(),this._pushLineOut(),this._prevSide=this._side(t[0]),this._moveTo(t,this._prevSide),this._prevPt=t,this._firstPt=t}lineTo(t){let e=this._side(t[0]);if(e*this._prevSide===-1){let n=this._intersect(this._prevPt,t);this._lineTo(n,0),this._prevSide=0,this._lineTo(t,e)}else this._lineTo(t,e);this._prevSide=e,this._prevPt=t}close(){let t=this._firstPt,e=this._prevPt;(t[0]!==e[0]||t[1]!==e[1])&&this.lineTo(t),this._checkClosingPt(this._lineIn),this._checkClosingPt(this._lineOut)}_moveTo(t,e){this._closed?(this._lineIn.push(x(t,e<=0?t[0]:this._xCut)),this._lineOut.push(x(t,e>=0?t[0]:this._xCut))):(e<=0&&this._lineIn.push(t.slice()),e>=0&&this._lineOut.push(t.slice()))}_lineTo(t,e){this._closed?(S(this._lineIn,t,e<=0?t[0]:this._xCut),S(this._lineOut,t,e>=0?t[0]:this._xCut)):e<0?(0===this._prevSide&&this._pushLineOut(),this._lineIn.push(t.slice())):e>0?(0===this._prevSide&&this._pushLineIn(),this._lineOut.push(t.slice())):this._prevSide<0?(this._lineIn.push(t.slice()),this._lineOut.push(t.slice())):this._prevSide>0&&(this._lineOut.push(t.slice()),this._lineIn.push(t.slice()))}_checkClosingPt(t){let e=t.length;e>3&&t[0][0]===this._xCut&&t[e-2][0]===this._xCut&&t[1][0]===this._xCut&&(t[0]=t[e-2].slice(),t.pop())}_side(t){return t<this._xCut?-1:+(t>this._xCut)}_intersect(t,e){let n=(this._xCut-t[0])/(e[0]-t[0]),r=[this._xCut,t[1]+n*(e[1]-t[1])],i=Math.min(t.length,e.length);for(let o=2;o<i;o++)r.push(t[o]+n*(e[o]-t[o]));return r}_pushLineIn(){this._lineIn&&this._lineIn.length>=this._minPts&&this._linesIn.push(this._lineIn),this._lineIn=[]}_pushLineOut(){this._lineOut&&this._lineOut.length>=this._minPts&&this._linesOut.push(this._lineOut),this._lineOut=[]}}function x(t,e){let n=t.slice();return n[0]=e,n}function S(t,e,n){let r=t.length;r>1&&t[r-1][0]===n&&t[r-2][0]===n?t[r-1]=x(e,n):t.push(x(e,n))}},97770(t,e,n){n.d(e,{Ey:()=>I,F8:()=>E,J2:()=>R,Yq:()=>T,_m:()=>w,iS:()=>C,wj:()=>O});var r=n(66552),i=n(73444),o=n(98623),s=n(34747);const a={dateStyle:void 0,year:void 0,month:void 0,day:void 0,weekday:void 0},l={timeStyle:void 0,hour12:void 0,hourCycle:void 0,hour:void 0,minute:void 0,second:void 0},h={timeZone:"UTC"},u={year:"numeric",month:"numeric",day:"numeric"},f={year:"numeric",month:"long",day:"numeric"},c={year:"numeric",month:"short",day:"numeric"},m={year:"numeric",month:"long",weekday:"long",day:"numeric"},d={hour:"numeric",minute:"numeric"},p={...d,second:"numeric"},y={hourCycle:"h23"},g={...d,...y},_={...p,...y},M={"short-date":u,"short-date-short-time":{...u,...d},"short-date-short-time-24":{...u,...g},"short-date-long-time":{...u,...p},"short-date-long-time-24":{...u,..._},"short-date-le":u,"short-date-le-short-time":{...u,...d},"short-date-le-short-time-24":{...u,...g},"short-date-le-long-time":{...u,...p},"short-date-le-long-time-24":{...u,..._},"long-month-day-year":f,"long-month-day-year-short-time":{...f,...d},"long-month-day-year-short-time-24":{...f,...g},"long-month-day-year-long-time":{...f,...p},"long-month-day-year-long-time-24":{...f,..._},"day-short-month-year":c,"day-short-month-year-short-time":{...c,...d},"day-short-month-year-short-time-24":{...c,...g},"day-short-month-year-long-time":{...c,...p},"day-short-month-year-long-time-24":{...c,..._},"long-date":m,"long-date-short-time":{...m,...d},"long-date-short-time-24":{...m,...g},"long-date-long-time":{...m,...p},"long-date-long-time-24":{...m,..._},"long-month-year":{month:"long",year:"numeric"},"short-month-year":{month:"short",year:"numeric"},year:{year:"numeric"},"short-time":d,"long-time":p},b=(0,r.O)()({shortDate:"short-date",shortDateShortTime:"short-date-short-time",shortDateShortTime24:"short-date-short-time-24",shortDateLongTime:"short-date-long-time",shortDateLongTime24:"short-date-long-time-24",shortDateLE:"short-date-le",shortDateLEShortTime:"short-date-le-short-time",shortDateLEShortTime24:"short-date-le-short-time-24",shortDateLELongTime:"short-date-le-long-time",shortDateLELongTime24:"short-date-le-long-time-24",longMonthDayYear:"long-month-day-year",longMonthDayYearShortTime:"long-month-day-year-short-time",longMonthDayYearShortTime24:"long-month-day-year-short-time-24",longMonthDayYearLongTime:"long-month-day-year-long-time",longMonthDayYearLongTime24:"long-month-day-year-long-time-24",dayShortMonthYear:"day-short-month-year",dayShortMonthYearShortTime:"day-short-month-year-short-time",dayShortMonthYearShortTime24:"day-short-month-year-short-time-24",dayShortMonthYearLongTime:"day-short-month-year-long-time",dayShortMonthYearLongTime24:"day-short-month-year-long-time-24",longDate:"long-date",longDateShortTime:"long-date-short-time",longDateShortTime24:"long-date-short-time-24",longDateLongTime:"long-date-long-time",longDateLongTime24:"long-date-long-time-24",longMonthYear:"long-month-year",shortMonthYear:"short-month-year",year:"year"}),v={ar:"ar-u-nu-latn-ca-gregory",nn:"no-NN"};function x(){let t=(0,i.lR)();return(t&&v[t])??(0,i.QC)()}"mart"!==new Intl.DateTimeFormat("bs",{month:"long"}).formatToParts(new Date(2025,2)).find(({type:t})=>"month"===t)?.value.toLowerCase()&&(v.bs="sr-Latn-CS");let S=new WeakMap;const A=M["short-date-short-time"];function R(t){return M[t]}function w(t){let{dateStyle:e,timeStyle:n,hour12:r,year:i,month:o}=t,s={};return e?s.dateStyle=e:i&&(s.year=i,s.month=o||void 0),n&&!s.year&&(s.timeStyle=n,s.hour12="auto"===r?void 0:"always"===r),s}function T(t,e=A){return function(t){let e=S.get(t);if(!e){let n=x(),r=O(t.timeZone??"system"),i={...t,timeZone:r};e=new Intl.DateTimeFormat(n,i),S.set(t,e)}return e}(e).format(t)}function C(t,e=A){return T(new Date(t),{...e,...h,...l})}function E(t,e=A){return T(new Date(`1970-01-01T${t}Z`),{...e,...h,...a})}function I(t,e=A){let n=s.c9.fromISO(t,{setZone:!0});if(!n.isValid)return t;if(e.timeZone)return T(n.toJSDate(),e);let r=0===n.offset?"UTC":e.timeZone,i={...e,timeZone:r};return n.toLocaleString(i,{locale:x()})}function O(t){switch(t){case"system":return o.N;case o.L:return"UTC";default:return t}}(0,i.Ml)(()=>{S=new WeakMap}),n.d(e,["_v",0,b])},73444(t,e,n){n.d(e,{JK:()=>l,Ml:()=>y,QC:()=>f,lR:()=>u,oQ:()=>d});var r=n(36563);let i;n(44208);const o=globalThis.esriConfig?.locale,s=globalThis.document?.documentElement;function a(){let t=s?.getAttribute("lang"),e=globalThis.navigator?.language;return o??t??e??"en"}function l(){return void 0===i&&(i=a()),i}const h=/^(?<language>[a-z]{2,3})(?:-(?<extlang>[a-z]{3}))?(?:-[A-Z][a-z]{3})?(?:-(?<region>[A-Z]{2}|\d{3}))?(?:-.*)?$/;function u(t=l()){return c(t)?.language}function f(t=l()){let e=c(t);return e?.language&&e?.extlang?t.replace(`${e.language}-`,""):t}function c(t=l()){return h.exec(t)?.groups}const m=[];function d(t){return m.push(t),(0,r.hA)(()=>{m.splice(m.indexOf(t),1)})}new Map;const p=[];function y(t){return p.push(t),(0,r.hA)(()=>p.splice(p.indexOf(t),1))}function g(){let t=a();i!==t&&([...p].forEach(e=>e(t)),i=t,[...m].forEach(e=>e(t)))}globalThis.addEventListener?.("languagechange",g),s&&new MutationObserver(()=>{g()}).observe(s,{attributeFilter:["lang"]})},98623(t,e,n){const r=Intl.DateTimeFormat().resolvedOptions().timeZone;n.d(e,["L",0,"unknown","N",0,r])},89606(t,e,n){n.d(e,{GN:()=>f,MU:()=>u,yf:()=>m});var r=n(35522),i=n(51850),o=n(10614),s=n(63907),a=n(74038);class l{constructor(t,e){this.data=t,this.indices=e}}class h{constructor(t,e,n,r,i){this.indices=t,this.packedNormals=e,this.appendedVertexToOriginal=n,this.outputVertexCount=r,this.appendedVertexCount=i}}function u(t,e,n,h,u){return!h||n.some(({name:t})=>"normal"===t||"normalCompressed"===t)?function(t,e,n,s){let a=new l(t.slice().buffer,e);if(!s)return a;let h=n[0].stride,u=a.data.byteLength/h;for(let t of n)if("normalCompressed"===t.name){let{offset:e}=t,n=new Int16Array(a.data),l=(0,i.vt)();for(let t=0;t<u;++t)(0,o.Tz)(l,n,t,h/2,e/2),(0,r.ei)(l,l,s),(0,o.aT)(n,t,l[0],l[1],l[2],h/2,e/2)}else if("normal"===t.name){let{offset:e}=t,n=new Float32Array(a.data),o=(0,i.vt)();for(let t=0;t<u;++t){let i=(t*h+e)/4;o[0]=n[i],o[1]=n[i+1],o[2]=n[i+2],(0,r.ei)(o,o,s),n[i]=o[0],n[i+1]=o[1],n[i+2]=o[2]}}return a}(t,e,n,u):function(t,e,n,r){let i=n[0].stride,o=i/4,l=new Float32Array(t.buffer,t.byteOffset,t.byteLength/4),h=t.byteLength/i,u=1<n.length?n[1].offset/4:o,m=i+4;return n.forEach((t,e)=>{t.stride=m,e>=1&&(t.offset+=4)}),n.splice(1,0,new a._("normalCompressed",2,s.pe.SHORT,12,m,!0)),c(l,h,u,i,m,f(e,l,o,r))}(t,e,n,u)}function f(t,e,n,r){let i=t.length/3,o=e.length/n,{faceNormals:s,faceAreas:a,faceEdges:l,edgeFaces:h,vertexFaces:u,vertexFaceCountAndOffset:f}=function(t,e,n,r,i,o){let s=new Float32Array(3*i),a=new Float32Array(i),l=new Uint32Array(3*i),h=new Int32Array(2*(3*i)),u=3*i,f=new Uint32Array(u),c=new Uint32Array(2*n);for(let t=0;t<i;++t){let e=3*t;for(let t=0;t<3;++t)++c[2*r[e+t]]}{let t=0;for(let e=0;e<n;++e){let n=2*e;c[n+1]=t,t+=c[n]}for(let t=0;t<i;++t){let e=3*t;for(let n=0;n<3;++n)f[c[2*r[e+n]+1]++]=t}for(let t=0;t<n;++t)c[2*t+1]-=c[2*t]}let m=0,d=new Uint32Array(2*u*2),p=new Uint32Array(2*n);for(let t=0;t<n;++t){let e=2*t,n=4*c[e+1];p[e]=n,p[e+1]=n}function y(t,e,n){let r=Math.min(t,e),i=Math.max(t,e),o=t<e?0:1,s=2*r,a=p[s],l=p[s+1],u=-1;for(let t=a;t<l;t+=2)if(d[t]===i){u=d[t+1];break}return-1===u&&(u=m++,d[l]=i,d[l+1]=u,p[s+1]=l+2,h[2*u+(1-o)]=-1),h[2*u+o]=n,u}for(let n=0;n<r.length;n+=3){let i=r[n],h=i*e,u=t[h],f=t[h+1],c=t[h+2],m=r[n+1],d=m*e,p=t[d],g=t[d+1],_=t[d+2],M=r[n+2],b=M*e,v=u-p,x=f-g,S=c-_,A=u-t[b],R=f-t[b+1],w=c-t[b+2],T=x*w-S*R,C=S*A-v*w,E=v*R-x*A,I=Math.sqrt(T*T+C*C+E*E)||1,O=n/3;a[O]=.5*I;let P=1/I;if(o){let t=o[0]*T+o[3]*C+o[6]*E,e=o[1]*T+o[4]*C+o[7]*E,n=o[2]*T+o[5]*C+o[8]*E;s[3*O]=t*P,s[3*O+1]=e*P,s[3*O+2]=n*P}else s[3*O]=T*P,s[3*O+1]=C*P,s[3*O+2]=E*P;let N=y(i,m,O),L=y(m,M,O),D=y(M,i,O);l[3*O]=N,l[3*O+1]=L,l[3*O+2]=D}return{faceNormals:s,faceAreas:a,faceEdges:l,vertexFaces:f,vertexFaceCountAndOffset:c,edgeFaces:h}}(e,n,o,t,i,r);return function(t,e,n,r,i,o){let s=new Uint8Array(e),a=new Uint32Array(e),l=new Uint32Array(3*e),h=0,u=new Uint32Array(e),f=0;for(let e=0;e<t.length;e+=3){let t=e/3;if(1===s[t])continue;s[t]=1;let c=n[3*t],m=n[3*t+1],d=n[3*t+2];for(f=0,u[f++]=t,l[0]=i[3*t],l[1]=i[3*t+1],l[2]=i[3*t+2],h=3,a[t]=t+1;h>0;){let e=l[--h];for(let r=0;r<2;++r){let y=o[2*e+r];if(-1===y||a[y]===t+1)continue;a[y]=t+1;let g=n[3*y],_=n[3*y+1],M=n[3*y+2];if(Math.abs(1-(c*g+m*_+d*M))<p){u[f++]=y,s[y]=1;for(let t=0;t<3;++t){let n=i[3*y+t];n!==e&&(l[h++]=n)}}}}if(f>1){let t=0,e=0,i=0,o=0;for(let s=0;s<f;++s){let a=u[s],l=r[a];t+=l,e+=n[3*a]*l,i+=n[3*a+1]*l,o+=n[3*a+2]*l}let s=Math.sqrt(e*e+i*i+o*o)||1;e/=s,i/=s,o/=s;for(let s=0;s<f;++s){let a=u[s];n[3*a]=e,n[3*a+1]=i,n[3*a+2]=o,r[a]=t}}}}(t,i,s,a,l,h),d(i,o,t,s,a,u,f)}function c(t,e,n,r,i,o){let s=r/4,a=i/4,h=o.outputVertexCount,u=new Float32Array(h*a),f=new Uint32Array(u.buffer),c=new Uint32Array(t.buffer,t.byteOffset,t.length);return function(t,e,n,r,i,o,s){for(let a=0;a<o;++a){let o=a*i,l=a*e;for(let e=0;e<n;++e)t[l+e]=r[o+e];t[l+n]=s[a];for(let e=n;e<i;++e)t[l+e+1]=r[o+e]}}(f,a,n,c,s,e,o.packedNormals),m(f,a,n,c,s,e,h,o.appendedVertexToOriginal,o.packedNormals,!0),new l(u.buffer,o.indices)}function m(t,e,n,r,i,o,s,a,l,h){for(let u=o;u<s;++u){let s=a[u-o]*i,f=u*e;for(let e=0;e<i;++e)t[f+e+(h&&e>=n?1:0)]=r[s+e];t[f+n]=l[u]}}function d(t,e,n,r,i,o,s){let a=3*t,l=new(a<256?Uint8Array:a<65536?Uint16Array:Uint32Array)(n),u=e,f=new(e<256?Uint8Array:e<65536?Uint16Array:Uint32Array)(a-e),c=new ArrayBuffer(4*a),m=new Int16Array(c),d=new Uint32Array(c),p=0,g=0,_=new Uint32Array(t),M=0,b=1-y;for(let t=0;t<e;++t){p=s[2*t+1],g=p+s[2*t];let n=t;for(;p<g;){{let t=o[--g],e=3*t,s=r[e],a=r[e+1],l=r[e+2];M=0,_[M++]=t;let h=p;for(;h<g;){let t=o[h],e=3*t;if(s*r[e]+a*r[e+1]+l*r[e+2]>b){_[M++]=t;let e=--g;if(h<e){o[h]=o[e];continue}}++h}let u=0,f=0,c=0;if(1===M)u=s,f=a,c=l;else{for(let t=0;t<M;++t){let e=_[t],n=i[e],o=3*e;u+=r[o]*n,f+=r[o+1]*n,c+=r[o+2]*n}let t=Math.sqrt(u*u+f*f+c*c)||1;u/=t,f/=t,c/=t}{let t=1/(Math.abs(u)+Math.abs(f)+Math.abs(c)),e=u*t,r=f*t,i=e,o=r;c<=0&&(i=(e>=0?1:-1)*(1-Math.abs(r)),o=(r>=0?1:-1)*(1-Math.abs(e)));let s=2*n,a=Math.round(32767*i),l=Math.round(32767*o);m[s]=a<-32767?-32767:a>32767?32767:a,m[s+1]=l<-32767?-32767:l>32767?32767:l}}if(n!==t)for(let e=0;e<M;++e){let r=3*_[e];l[r]===t&&(l[r]=n),l[r+1]===t&&(l[r+1]=n),l[r+2]===t&&(l[r+2]=n)}if(p>=g)break;n=u++,f[n-e]=t}}return new h(l,d,f,u,u-e)}const p=.04,y=.8},94715(t,e,n){n.r(e),n.d(e,{destroyContext:()=>R,dracoDecompressPointCloudData:()=>M,filterObbsForModifications:()=>b,filterObbsForModificationsSync:()=>I,initialize:()=>N,interpretObbModificationResults:()=>E,process:()=>_,project:()=>S,setLegacySchema:()=>x,setModifications:()=>v,setModificationsSync:()=>T,test:()=>D,transformNormals:()=>A});var r=n(34727),i=n(77690),o=n(29242),s=n(58083),a=n(9093),l=n(16930),h=n(4197),u=n(95696),f=n(18251),c=n(73354),m=n(2741);function d(){p=null}let p;var y=n(89606),g=n(98697);async function _(t){w=await L();let e=[t.geometryBuffer];return{result:C(w,t,e),transferList:e}}async function M(t){w=await L();let e=[t.geometryBuffer],{geometryBuffer:n}=t,r=n.byteLength,i=w._malloc(r),o=new Uint8Array(w.HEAPU8.buffer,i,r);o.set(new Uint8Array(n));let s=w.dracoDecompressPointCloudData(i,o.byteLength);if(w._free(i),s.error.length>0)throw Error(`i3s.wasm: ${s.error}`);let a=s.featureIds?.length>0?s.featureIds.slice():null,l=s.positions.slice();return a&&e.push(a.buffer),e.push(l.buffer),{result:{positions:l,featureIds:a},transferList:e}}async function b(t){await L(),I(t);let e={buffer:t.buffer};return{result:e,transferList:[e.buffer]}}async function v(t){await L(),T(t)}async function x(t){w=await L(),w.setLegacySchema(t.context,t.jsonSchema)}async function S(t){let e,{localMatrix:r,origin:i,positions:o,vertexSpace:s}=t,a=l.A.fromJSON(t.inSpatialReference),c=l.A.fromJSON(t.outSpatialReference),m=r?(0,h.Vj)(r):void 0,d=(0,h.cj)(i),[{projectBuffer:p},{initializeProjection:y}]=await Promise.all([Promise.resolve().then(()=>n(9762)),Promise.resolve().then(()=>n(99917))]);await y(a,c);let g=[0,0,0];if(!p(d,a,0,g,c,0))throw Error("Failed to project");if("georeferenced"===s.type&&null==s.origin){if(e=new Float64Array(o.length),!p(o,a,0,e,c,0,e.length/3))throw Error("Failed to project")}else{let t="georeferenced"===s.type?u.A.fromJSON(s):f.A.fromJSON(s),{projectMeshVertexPositions:r}=await Promise.all([n.e(2258),n.e(2346)]).then(()=>n(74594)),i=r({vertexAttributes:{position:o},transform:m?{localMatrix:m}:void 0,vertexSpace:t,spatialReference:a},c);if(!i)throw Error("Failed to project");e=i}let _=e.length,[M,b,v]=g;for(let t=0;t<_;t+=3)e[t]-=M,e[t+1]-=b,e[t+2]-=v;return{result:{projected:e,original:o,projectedOrigin:g},transferList:[e.buffer,o.buffer]}}async function A({normalMatrix:t,normals:e}){let n=new Float32Array(e.length);return(0,c.b)(n,e,t),(0,r.or)(t)&&(0,c.n)(n,n),{result:{transformed:n,original:e},transferList:[n.buffer,e.buffer]}}function R(t){O(t)}let w;function T(t){if(!w)return;let e=t.modifications,n=w._malloc(8*e.length),r=new Float64Array(w.HEAPU8.buffer,n,e.length);for(let t=0;t<e.length;++t)r[t]=e[t];w.setModifications(t.context,n,e.length,t.isGeodetic),w._free(n)}function C(t,e,n){let{context:r,globalTrafo:l,geometryElevationOffset:h,mbs:u,obbData:f,layouts:c,needNormals:m,computeNormals:d,elevationOffset:p,planetRadiusInGlobalMode:_,geometryBuffer:M,geometryDescriptor:b,geometryData:v,indexToVertexProjector:x,vertexToRenderProjector:S,normalReferenceFrame:A}=e,R=t._malloc(M.byteLength),w=t._malloc(33*Float64Array.BYTES_PER_ELEMENT),T=new Uint8Array(t.HEAPU8.buffer,R,M.byteLength);T.set(new Uint8Array(M));let C=new Float64Array(t.HEAPU8.buffer,w,33);P(C,[NaN,NaN,NaN],0);let E=3;P(C,l,E),E+=16,P(C,u.center,E),E+=3,C[E++]=u.radius,f&&P(C,f,E++);let I={isDraco:!1,isLegacy:!1,color:c.some(t=>t.some(t=>"color"===t.name)),normal:m&&c.some(t=>t.some(t=>"normalCompressed"===t.name)),uv0:c.some(t=>t.some(t=>"uv0"===t.name)),uvRegion:c.some(t=>t.some(t=>"uvRegion"===t.name)),featureIndex:b.featureIndex},O=t.process(r,!!f,R,T.byteLength,b,I,w,p,x,S,A);if(t._free(w),t._free(R),O.error.length>0)throw Error(`i3s.wasm: ${O.error}`);if(O.discarded)return null;let N=O.componentOffsets.length>0?O.componentOffsets.slice():null,L=O.featureIds.length>0?O.featureIds.slice():null,D=O.anchorIds.length>0?Array.from(O.anchorIds):null,B=O.anchors.length>0?Array.from(O.anchors):null,G=1===O.indicesType?new Uint16Array(O.indices.buffer,O.indices.byteOffset,O.indices.byteLength/2).slice():new Uint32Array(O.indices.buffer,O.indices.byteOffset,O.indices.byteLength/4).slice(),U=c[0].slice(),F=(0,i.z0)((0,o.vt)(),l),j=(0,y.MU)(O.interleavedVertedData,G,U,d&&!I.normal,F),k=O.positions.slice(),Z=function(t,e,n,r,i){let o=n?(0,a.o8)(n):(0,a.vt)();(0,s.lw)(o,e,o);let l=o[0],h=o[1],u=o[2],f=o[4],c=o[5],m=o[6],d=o[8],p=o[9],y=o[10],g=o[12],_=o[13],M=o[14],b=1/0,v=-1/0;for(let e=0;e<t.length;e+=3){let n=t[e],o=t[e+1],s=t[e+2],a=n*u+o*m+s*y+M,x=0;if(r>0){let t=n*l+o*f+s*d+g,e=n*h+o*c+s*p+_;x=Math.sqrt(t*t+e*e+a*a)-r}else x=a;x-=i,b=Math.min(b,x),v=Math.max(v,x)}return{minElevation:b,maxElevation:v}}(k,l,v?.geometries[0]?.transformation,_,h),{buffer:q,byteOffset:H,byteLength:z}=O.positionIndices,Y=1===O.positionIndicesType?new Uint16Array(q,H,z/2).slice():new Uint32Array(q,H,z/4).slice(),V=new g._b(U,j.data,j.indices,O.hasColors,O.hasModifications,{data:k,indices:Y});return L&&n.push(L.buffer),N&&n.push(N.buffer),n.push(j.data),n.push(j.indices.buffer),n.push(k.buffer),n.push(Y.buffer),new g.sQ(N,L,D,B,V,l,O.obb,Z.minElevation,Z.maxElevation)}function E(t){return 0===t?0:1===t?1:2===t?2:3}function I(t){if(!w)return;let{context:e,buffer:n}=t,r=w._malloc(n.byteLength),i=n.byteLength/Float64Array.BYTES_PER_ELEMENT,o=new Float64Array(w.HEAPU8.buffer,r,i),s=new Float64Array(n);o.set(s),w.filterOBBs(e,r,i),s.set(o),w._free(r)}function O(t){0===w?.destroy(t)&&(w=null,d())}function P(t,e,n){for(let r=0;r<e.length;++r)t[r+n]=e[r]}async function N(){w||await L()}async function L(){return w??=await(p??=(async()=>{try{return await(await n.e(2980).then(()=>n(82980))).default({locateFile:t=>(0,m.s)(`esri/libs/i3s/${t}`)})}catch(t){throw d(),t}})(),p),w}const D={transform:(t,e)=>w&&C(w,t,e),destroy:O}},98697(t,e,n){n.d(e,{Cm:()=>m,H1:()=>M,Ir:()=>y,_b:()=>f,sQ:()=>c});var r=n(53966),i=n(15142),o=n(51850),s=n(35982),a=n(39829),l=n(99917),h=n(27993),u=n(89056);class f{constructor(t,e,n,r,i,o){this.layout=t,this.interleavedVertexData=e,this.indices=n,this.hasColors=r,this.hasModifications=i,this.positionData=o}}class c{constructor(t,e,n,r,i,o,s,a,l){this.componentOffsets=t,this.featureIds=e,this.anchorIds=n,this.anchors=r,this.transformedGeometry=i,this.globalTrafo=o,this.obb=s,this.geometryMinElevation=a,this.geometryMaxElevation=l}}class m extends s.B{constructor(t){super("SceneLayerWorker","process",{process:t=>[t.geometryBuffer],project:t=>[t.positions.buffer],transformNormals:t=>[t.normals.buffer]},t,{hasInitialize:!0}),this._schemasByContext=new Map,this._modificationsByContext=new Map}_onClientConnected(t){for(let[e,n]of this._schemasByContext)t.invoke("setLegacySchema",{context:e,jsonSchema:n}).catch(()=>{});for(let e of this._modificationsByContext.values())t.invoke("setModifications",e).catch(()=>{})}setModifications(t,e,n){let r={context:t,modifications:e,isGeodetic:n};return this._modificationsByContext.set(t,r),this.broadcast(r,"setModifications")}setLegacySchema(t,e){let n=JSON.stringify(e);return this._schemasByContext.set(t,n),this.broadcast({context:t,jsonSchema:n},"setLegacySchema")}destroyContext(t){return this._schemasByContext.delete(t),this._modificationsByContext.delete(t),this.broadcast(t,"destroyContext")}async destroyContextAndSelf(t){await this.destroyContext(t),this.destroy()}project(t,e){return this.invokeMethod("project",t,e)}transformNormals(t,e){return this.invokeMethod("transformNormals",t,e)}}const d=new i.A({deallocator:null}),p=(0,o.vt)();function y(t,e,n,i=!1){d.clear();let o=1/0,s=1/0,h=-1/0,f=-1/0,c=!1;for(let t of e){let e="clip"===t.type?2:+("mask"===t.type),m=t.geometry,p=m.spatialReference??n;if(p!==n&&!(0,l.canProjectWithoutEngine)(p,n)){r.A.getLogger("esri.views.3d.layers.SceneLayerWorkerHandle").warn("im-modification-projection-failed","Can't project modification polygon into layer spatial reference, ignoring modification",{polygon:m});continue}let y=m.rings;if(p!==n){let t=g(m.rings,p,n);if(null==t){r.A.getLogger("esri.views.3d.layers.SceneLayerWorkerHandle").warn("im-modification-projection-failed","Can't project modification polygon into layer spatial reference, ignoring modification",{polygon:m});continue}y=t}let M=y;if(i){let t=(0,u.jZ)(new a.A({rings:y,spatialReference:n}));null!=t&&(y=t.rings)}let b=1===M.length&&y.length>1?[...y.map(t=>[t]),M]:[y];if(b.some(t=>0===t.length||t.some(t=>t.length<3||t.some(t=>!_(t)))))r.A.getLogger("esri.views.3d.layers.SceneLayerWorkerHandle").warn("im-modification-invalid-polygon","Ignoring invalid modification polygon (empty ring, fewer than 3 vertices, or non-finite coordinates).",{polygon:m});else{c||=1===e;for(let t of b){d.push(e),d.push(t.length);for(let e of t){d.push(e.length);for(let t of e){let e=t[2]??0;d.push(t[0]),d.push(t[1]),d.push(e),o=Math.min(o,t[0]),s=Math.min(s,t[1]),h=Math.max(h,t[0]),f=Math.max(f,t[1])}}}}}if(null!=t)if(c){let e=1e-4;d.push(2),d.push(2),d.push(4),d.push(o-e),d.push(s-e),d.push(0),d.push(h+e),d.push(s-e),d.push(0),d.push(h+e),d.push(f+e),d.push(0),d.push(o-e),d.push(f+e),d.push(0),d.push(4),d.push(t[0]),d.push(t[1]),d.push(0),d.push(t[2]),d.push(t[1]),d.push(0),d.push(t[2]),d.push(t[3]),d.push(0),d.push(t[0]),d.push(t[3]),d.push(0)}else d.push(1),d.push(1),d.push(4),d.push(t[0]),d.push(t[1]),d.push(0),d.push(t[2]),d.push(t[1]),d.push(0),d.push(t[2]),d.push(t[3]),d.push(0),d.push(t[0]),d.push(t[3]),d.push(0);d.push(3);let m=new Float64Array(d.length);for(let t=0;t<d.length;++t)m[t]=d.at(t);return m}function g(t,e,n){let r=[];for(let i of t){let t=[];for(let r of i){if(!(0,h.F)(r,e,p,n)||!_(p))return null;t.push([p[0],p[1],p[2]])}r.push(t)}return r}function _(t){return Number.isFinite(t[0])&&Number.isFinite(t[1])&&(null==t[2]||Number.isFinite(t[2]))}function M(t,e){let n=0;for(let r of e){let e=r.geometry,i=e.rings.length,o=e.rings.some(t=>t.length<3);if(0!==i&&!o){n+=1,n+=1;for(let r=0;r<e.rings.length;++r){let i=e.rings[r];n+=1;for(let o=0;o<i.length;++o){let i=[t[n+0],t[n+1],t[n+2]];n+=3,e.setPoint(r,o,i)}}}}}},10614(t,e,n){n.d(e,{Tz:()=>s,aT:()=>o});var r=n(34727),i=n(35522);function o(t,e,n,r,i,o=2,s=0){let l=1/(Math.abs(n)+Math.abs(r)+Math.abs(i)),h=n*l,u=r*l,f=i<=0?(h>=0?1:-1)*(1-Math.abs(u)):h,c=i<=0?(u>=0?1:-1)*(1-Math.abs(h)):u,m=e*o+s;t[m]=a(f),t[m+1]=a(c)}function s(t,e,n,r=2,o=0){let s=n*r+o,a=l(e[s]),h=l(e[s+1]),u=1-Math.abs(a)-Math.abs(h);return t[2]=u,u<0?(t[0]=(a>=0?1:-1)*(1-Math.abs(h)),t[1]=(h>=0?1:-1)*(1-Math.abs(a))):(t[0]=a,t[1]=h),(0,i.S8)(t,t)}function a(t){return(0,r.qE)(Math.round(32767*t),-32767,32767)}function l(t){return(0,r.qE)(t/32767,-1,1)}n(51850)},74038(t,e,n){n.d(e,{_:()=>r});class r{constructor(t,e,n,r,i,o=!1,s=0,a=!1){this.name=t,this.count=e,this.type=n,this.offset=r,this.stride=i,this.normalized=o,this.divisor=s,this.integer=a}}},63907(t,e,n){const r={BYTE:5120,UNSIGNED_BYTE:5121,SHORT:5122,UNSIGNED_SHORT:5123,INT:5124,UNSIGNED_INT:5125,FLOAT:5126,HALF_FLOAT:5131},i={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},o=Object.values(i),s={FLOAT:r.FLOAT,UNSIGNED_BYTE:r.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:r.BYTE,UNSIGNED_SHORT:r.UNSIGNED_SHORT,SHORT:r.SHORT,UNSIGNED_INT:r.UNSIGNED_INT,INT:r.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};n.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,i,"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,o,"iE",0,{DEPTH24_STENCIL8:35056,DEPTH32F_STENCIL8:36013},"ld",0,s,"pe",0,r,"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}])}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[506,1666,7992,8125],{69397(t,e,r){r.d(e,{Qf:()=>h,Qh:()=>i,lM:()=>n});var s=r(34275);function n(t){if(!t)return 0;let e=l;for(let r in t)t.hasOwnProperty(r)&&(e+=a(t[r],!1));return e}function i(t){if(!t)return 0;if("number"==typeof t[0])return h(t);if(Array.isArray(t))return function(t){let e=t.length;if(0===e||"number"==typeof t[0])return o(t,8);let r=u;for(let s=0;s<e;s++)r+=a(t[s]);return r}(t);let e=l;for(let r in t)t.hasOwnProperty(r)&&(e+=a(t[r]));return e}function a(t,e=!0){switch(typeof t){case"object":return e?i(t):l;case"string":return function(t){return 32+t.length}(t);case"number":return 16;case"boolean":return 4;default:return 8}}function h(...t){return t.reduce((t,e)=>t+(e?(0,s.iu)(e)?e.byteLength+f:Array.isArray(e)?o(e,16):0:0),0)}function o(t,e){return u+t.length*e}const l=32,u=16,f=145},87992(t,e,r){r.d(e,{JR:()=>Z,ME:()=>M,MY:()=>R,NO:()=>C,Nh:()=>A,V2:()=>I,_s:()=>_,e6:()=>Y,gh:()=>P,jm:()=>w,tr:()=>X,uX:()=>m});var s=r(32198),n=r(16930),i=r(19419),a=r(60408),h=r(21325),o=r(513),l=r(50954),u=r(79567),f=r(52006),p=r(49663),c=r(46068),g=r(92722);class m{constructor({type:t,spatialReference:e,vertexCount:r,vertexXY:s,vertexZ:n,vertexM:i,partCount:a,partOffsets:h,partFlags:o,segmentFlags:l,segmentIndices:u,segmentParams:f,segmentCountArc:p,segmentCountBezier:c}){this.segmentCountArc=0,this.segmentCountBezier=0,this.type=t,this.spatialReference=e,this.vertexCount=r,this.vertexXY=s,this.vertexZ=n,this.vertexM=i,this.partCount=a,this.partOffsets=h,this.partFlags=o,this.segmentFlags=l,this.segmentIndices=u,this.segmentParams=f,this.segmentCountArc=p,this.segmentCountBezier=c}get segmentParamCount(){return 10*this.segmentCountArc+4*this.segmentCountBezier}get segmentCountLine(){let{segmentCount:t,segmentCountArc:e,segmentCountBezier:r}=this;return t&&t-e-r}get segmentCount(){return"polyline"===this.type?this.vertexCount-this.partCount:"polygon"===this.type?this.vertexCount:0}get hasZ(){return null!=this.vertexZ}get hasM(){return null!=this.vertexM}hasCurves(){return this.segmentCountArc+this.segmentCountBezier>0}isMultipart(){return"polyline"===this.type||"polygon"===this.type}get usedMemory(){function t(t){return t?64+t.byteLength:0}return t(this.vertexXY)+t(this.vertexZ)+t(this.vertexM)+t(this.partOffsets)+t(this.partFlags)+t(this.segmentFlags)+t(this.segmentIndices)+t(this.segmentParams)}clone(){let{type:t,vertexCount:e,partCount:r,hasZ:s,hasM:n,segmentCountArc:i,segmentCountBezier:a}=this,h=I(t,e,r,s,n,this.hasCurves(),i,a);h.spatialReference=this.spatialReference;let{vertexXY:o,vertexZ:l,vertexM:u}=this;if(h.vertexXY.set(o.subarray(0,2*e),0),h.vertexZ?.set(l.subarray(0,e),0),h.vertexM?.set(u.subarray(0,e),0),this.isMultipart()){let{partOffsets:t,partFlags:e}=this;h.partFlags.set(e.subarray(0,r+1)),h.partOffsets.set(t.subarray(0,r+1))}if(this.hasCurves()){let{segmentFlags:t,segmentIndices:r,segmentParams:s,segmentParamCount:n}=this;h.segmentFlags.set(t.subarray(0,e),0),h.segmentIndices.set(r.subarray(0,e),0),h.segmentParams.set(s.subarray(0,n),0)}return h}equals(t){return this.equalsWithinTolerance(t,0)}equalsWithinTolerance(t,e){if(null==t)return!1;if(this===t)return!0;if(!(0,h.aI)(this.spatialReference,t.spatialReference)||this.vertexCount!==t.vertexCount||this.partCount!==t.partCount||this.hasZ!==t.hasZ||this.hasM!==t.hasM||this.hasCurves()!==t.hasCurves()||this.segmentCountArc!==t.segmentCountArc||this.segmentCountBezier!==t.segmentCountBezier)return!1;let r=0===e?(t,e)=>t!==e||isNaN(t)!==isNaN(e):(t,r)=>Math.abs(t-r)>e||isNaN(t)!==isNaN(r);for(let e=0;e<this.vertexCount;++e)if(r(this.vertexXY[2*e],t.vertexXY[2*e])||r(this.vertexXY[2*e+1],t.vertexXY[2*e+1]))return!1;if(this.hasZ)for(let e=0;e<this.vertexCount;++e)if(r(this.vertexZ[e],t.vertexZ[e]))return!1;if(this.hasM)for(let e=0;e<this.vertexCount;++e)if(r(this.vertexM[e],t.vertexM[e]))return!1;for(let e=0;e<this.partCount;++e)if(this.partFlags[e]!==t.partFlags[e]||this.partOffsets[e]!==t.partOffsets[e])return!1;if(this.hasCurves()){for(let e=0;e<this.vertexCount;++e)if(this.segmentFlags[e]!==t.segmentFlags[e]||this.segmentIndices[e]!==t.segmentIndices[e])return!1;for(let e=0;e<this.segmentParamCount;++e)if(r(this.segmentParams[e],t.segmentParams[e]))return!1}return!0}get parts(){return this.isMultipart()?new y(this):[][Symbol.iterator]()}}class y{constructor(t){this.geometry=t,this.value=new x(t)}get done(){return this.value.index>=this.geometry.partCount}next(){return++this.value.index,this}[Symbol.iterator](){return this}}class x{constructor(t){this.geometry=t,this.index=-1,this._readVertex=V(t),this._segments=new d(this)}get segments(){return this._segments.reset(),this._segments}get startVertex(){return this._readVertex(this.geometry.partOffsets[this.index])}get vertexCount(){let t=this.geometry.partOffsets;return t[this.index+1]-t[this.index]}}class d{constructor(t){this._part=t,this._partStart=0,this._partEnd=0,this.value=new v(t.geometry)}get _partIsClosed(){return!!(1&this._part.geometry.partFlags?.[this._part.index])}get done(){return this.value.indexOfStartVertex>this._partEnd}next(){++this.value.indexOfStartVertex;let t=this.value.indexOfStartVertex>=this._partEnd;return this.value.indexOfEndVertex=t&&this._partIsClosed?this._partStart:this.value.indexOfStartVertex+1,this}[Symbol.iterator](){return this}reset(){let{index:t}=this._part,e=this._part.geometry.partOffsets;this._partStart=e[t],this._partEnd=e[t+1]-(this._partIsClosed?1:2),this.value.indexOfStartVertex=this._partStart-1}}class v{constructor(t){this.geometry=t,this.indexOfStartVertex=-1,this.indexOfEndVertex=-1,this._readVertex=V(t)}get xStart(){return this.geometry.vertexXY[2*this.indexOfStartVertex]}get yStart(){return this.geometry.vertexXY[2*this.indexOfStartVertex+1]}get zStart(){return this.geometry.vertexZ[this.indexOfStartVertex]}get mStart(){return this.geometry.vertexM[this.indexOfStartVertex]}get xEnd(){return this.geometry.vertexXY[2*this.indexOfEndVertex]}get yEnd(){return this.geometry.vertexXY[2*this.indexOfEndVertex+1]}get zEnd(){return this.geometry.vertexZ[this.indexOfEndVertex]}get mEnd(){return this.geometry.vertexM[this.indexOfEndVertex]}get start(){return this._readVertex(this.indexOfStartVertex)}get end(){return this._readVertex(this.indexOfEndVertex)}get curve(){let t=this.geometry.segmentFlags?.[this.indexOfStartVertex]??1;if(1===t)return this.end;let e=this.geometry.segmentParams,r=this.geometry.segmentIndices[this.indexOfStartVertex];if(2===t){let t=e[r++],s=e[r++],n=e[r++],i=e[r++];return{b:[this.end,[t,s],[n,i]]}}let s=e[r++],n=e[r++],i=e[r++],a=e[r++],h=e[r++],o=e[r++];r++,r++;let l=e[r++],u=e[r++];if(!(4&s)&&1===i)return{c:[this.end,[l,u]]};let f=2&s?0:1,p=1&s?0:1;return{a:[this.end,[h,o],f,p,a,n,i]}}}function C(t,e){let r={stack:[],error:void 0,hasError:!1};try{return e??=(0,i.Ie)(),(0,s.mS)(r,new E(t,["vertexZ","vertexM","spatialReference"]),!1),(0,i.bx)(e,function(t){let e,{vertexCount:r,vertexXY:n,vertexZ:a,vertexM:h}=t,o=O(t);if(t.hasCurves()){let r={stack:[],error:void 0,hasError:!1};try{(0,s.mS)(r,new E(t,["vertexZ","vertexM"]),!1);let n=(0,i.Ie)();for(let e of t.parts){let t=e.startVertex;for(let{curve:r}of e.segments)(0,u.e)(n,t,r),t=(0,f.yP)(r)}let[a,h,l,p]=n;e={xmin:a,ymin:h,xmax:l,ymax:p,spatialReference:o}}catch(t){r.error=t,r.hasError=!0}finally{(0,s.hk)(r)}}else{let t,s,i,a;t=s=1/0,i=a=-1/0;for(let e=0;e<r;++e){let r=n[2*e],h=n[2*e+1];t=Math.min(t,r),i=Math.max(i,r),s=Math.min(s,h),a=Math.max(a,h)}e={xmin:t,ymin:s,xmax:i,ymax:a,spatialReference:o}}if(a){let t=1/0,r=-1/0;for(let e of a)t=Math.min(t,e),r=Math.max(r,e);e.zmin=t,e.zmax=r}if(h){let t=1/0,r=-1/0;for(let e of h)t=Math.min(t,e),r=Math.max(r,e);e.mmin=t,e.mmax=r}return e}(t)),e}catch(t){r.error=t,r.hasError=!0}finally{(0,s.hk)(r)}}function M(t){let e,r,s;if((0,a.fT)(t)){s="point";let{x:n,y:i,z:a,m:h}=t,o=[n,i];null!=a&&o.push(a),null!=h&&o.push(h),r=[[o]],e=1}else(0,a.U9)(t)?(s="multipoint",r=[t.points],e=t.points.length):(0,a.Rg)(t)?(s="polyline",r=t.curvePaths??t.paths,e=r.reduce((t,e)=>t+e.length,0)):(s="polygon",r=t.curveRings??t.rings,e=r.reduce((t,e)=>(0===e.length||(t+=e.length,S(e[0],(0,f.yP)(e.at(-1)))&&--t),t),0));let n=I(s,e,s.includes("point")?0:r.length,(0,a.Pv)(t),(0,a.W0)(t),(0,f.Ed)(t)),{hasZ:i,hasM:h,vertexXY:o,vertexZ:l,vertexM:u}=n;function p(t){o[2*g]=t[0],o[2*g+1]=t[1],i&&(l[g]=t[2]),h&&(u[g]=t[c]),++g}n.spatialReference=t.spatialReference??void 0;let c=n.hasZ?3:2,g=0;if(!n.isMultipart()){if(!i&&!h){for(let[t,e]of r[0])o[2*g]=t,o[2*g+1]=e,++g;return n}for(let t of r[0])p(t);return n}let m="polygon"===s,{partOffsets:y}=n,x=0;if(!(0,f.Ed)(t)){for(let t of r){if(y[x++]=g,0===t.length)continue;let e=t.length;if(m&&S(t[0],t.at(-1))&&--e,i||h)for(let r=0;r<e;++r)p(t[r]);else for(let r=0;r<e;++r){let[e,s]=t[r];o[2*g]=e,o[2*g+1]=s,++g}}return y[x]=g,n}function d(t){let e=v+t;if(e<=(n.segmentParams?.length??0))return;let r=e*N;r=20*Math.ceil(r/20);let s=n.segmentParams;n.segmentParams=new Float64Array(r),null!=s&&n.segmentParams.set(s)}let v=0;for(let t of r){if(n.partOffsets[x++]=g,0===t.length)continue;let e=t[0],r=e;for(let e=1;e<t.length;++e){let s=t[e];p(r);let i=g-1;(0,f.wY)(s)?(d(10),++n.segmentCountArc,v=_(r,s,n,i,v),r=s.a[0]):(0,f.DA)(s)?(d(10),++n.segmentCountArc,v=b(r,s,n,i,v),r=s.a[0]):(0,f.aO)(s)?(d(10),++n.segmentCountArc,v=Y(r,s,n,i,v),r=s.c[0]):(0,f.n1)(s)?(d(4),++n.segmentCountBezier,v=X(0,s,n,i,v),r=s.b[0]):r=s}m&&S(e,r)||p(r)}return n.partOffsets[x]=g,n}function P(t){let e=V(t),{vertexCount:r,partCount:s,hasZ:n,hasM:i}=t,a=O(t),h=0;if(!t.isMultipart()){if("point"===t.type){let[e,r]=t.vertexXY;return{x:e,y:r,z:t.vertexZ?.[0],m:t.vertexM?.[0],spatialReference:a}}let s=[];for(;h<r;)s.push(e(h++));return{points:s,spatialReference:a,hasZ:n,hasM:i}}if(!t.hasCurves()){let r=[];for(let n=0;n<s;++n){let s=!!(1&t.partFlags[n]),i=t.partOffsets[n+1],a=[];for(;h<i;)a.push(e(h++));s&&a.length>0&&a.push([...a[0]]),r.push(a)}return"polygon"===t.type?{rings:r,hasZ:n,hasM:i,spatialReference:a}:{paths:r,hasZ:n,hasM:i,spatialReference:a}}let o=[];for(let{segments:e,startVertex:r}of t.parts){let t=[r];for(let{curve:r}of e)t.push(r);o.push(t)}return"polygon"===t.type?{rings:[],curveRings:o,hasZ:n,hasM:i,spatialReference:a}:{paths:[],curvePaths:o,hasZ:n,hasM:i,spatialReference:a}}function A(t,{lengths:e,coords:r,hasZ:s,hasM:n},i){let a=t.includes("point")?0:e.length,h="polygon"===t,o="point"===t?1:e.reduce((t,e)=>t+e,0)-(h?a:0);s??=!1,n??=!1;let l=I(t,o,a,s,n,!1,0,0);if(l.spatialReference=i??void 0,!l.isMultipart()){for(let t=0,e=0;t<o;++t)l.vertexXY[2*t]=r[e++],l.vertexXY[2*t+1]=r[e++],s&&(l.vertexZ[t]=r[e++]),n&&(l.vertexM[t]=r[e++]);return l}let u=2+Number(s)+Number(n),f=0,p=0;l.partOffsets[0]=0;for(let t of e){let e=l.partOffsets[p],i=e+t-Number(h);l.partOffsets[++p]=i;for(let t=e;t<i;++t)l.vertexXY[2*t]=r[f++],l.vertexXY[2*t+1]=r[f++],s&&(l.vertexZ[t]=r[f++]),n&&(l.vertexM[t]=r[f++]);h&&(f+=u)}return l}function Z({type:t,vertexCount:e,vertexXY:r,vertexZ:s,vertexM:n,partCount:i,partOffsets:a,partFlags:h,hasZ:o,hasM:l}){let u=new g.A([],[],o,l);i=Math.max(i,1);let f=0;for(let t=0;t<i;++t){let i=a?.[t+1]??e,p=u.coords.length;for(let t=f;t<i;++t)u.coords.push(r[2*t],r[2*t+1]),o&&u.coords.push(s[t]),l&&u.coords.push(n[t]);if(h&&1&h[t]){let t=f;u.coords.push(r[2*t],r[2*t+1]),o&&u.coords.push(s[t]),l&&u.coords.push(n[t])}u.lengths.push((u.coords.length-p)/u.stride),f=i}return"point"===t&&(u.lengths.length=0),u}function w(...t){let e=new Set;for(let r of t){if(!r)continue;let t=[r.vertexXY,r.vertexZ,r.vertexM,r.partOffsets,r.partFlags,r.segmentFlags,r.segmentIndices,r.segmentParams];for(let r of t){let t=r?.buffer;t&&e.add(t)}}return Array.from(e)}function R(t,e){return"getSpatialReference"in t&&(e=function(t){if(null==t)return;let e=t.getText()||void 0,r=t.isCustomWkid()?0:t.getOldID();if(r<=0)return{wkt:e};let s=t.getLatestID();(s<=0||s===r)&&(s=void 0);let n=t.getVCS();if(null==n)return{wkid:r,latestWkid:s,wkt:e};let i=n.isCustomWkid()?0:n.getOldID();if(i<=0)return{wkt:e};let a=t.getLatestVerticalID();return(a<=0||a===i)&&(a=void 0),{wkid:r,wkt:e,latestWkid:s,vcsWkid:i,latestVcsWkid:a}}(t.getSpatialReference()),t=t.getGeometry()),new m({...t.toFlatGeometry(),spatialReference:e})}class E{constructor(t,e){this.target=t,this.keys=e,this.oldValues=e.map(e=>t[e]);for(let r of e)t[r]=void 0}[Symbol.dispose](){this.keys.map((t,e)=>{this.target[t]=this.oldValues[e]})}}function O({spatialReference:t}){return t instanceof n.A?t.toJSON():t}function V({vertexXY:t,vertexZ:e,vertexM:r}){return e?r?s=>[t[2*s],t[2*s+1],e[s],r[s]]:r=>[t[2*r],t[2*r+1],e[r]]:r?e=>[t[2*e],t[2*e+1],r[e]]:e=>[t[2*e],t[2*e+1]]}function S(t,e){return t.every((t,r)=>t===e[r])}function I(t,e,r,s,n,i,a,h){a??=0,h??=0;let o=new m({type:t,vertexCount:e,vertexXY:null,vertexZ:void 0,vertexM:void 0,partCount:r,partOffsets:void 0,partFlags:void 0,segmentFlags:void 0,segmentIndices:void 0,segmentParams:void 0,segmentCountArc:a,segmentCountBezier:h}),l=2*Float64Array.BYTES_PER_ELEMENT*e;s&&(l+=Float64Array.BYTES_PER_ELEMENT*e),n&&(l+=Float64Array.BYTES_PER_ELEMENT*e),o.isMultipart()&&(l+=(r+1)*Int32Array.BYTES_PER_ELEMENT,l+=(r+1)*Int8Array.BYTES_PER_ELEMENT),i&&(l+=e*Int8Array.BYTES_PER_ELEMENT,l+=e*Int32Array.BYTES_PER_ELEMENT,l+=o.segmentParamCount*Float64Array.BYTES_PER_ELEMENT);let u=new ArrayBuffer(l),f=0;return o.vertexXY=new Float64Array(u,f,2*e),f+=o.vertexXY.byteLength,s&&(o.vertexZ=new Float64Array(u,f,e),f+=o.vertexZ.byteLength),n&&(o.vertexM=new Float64Array(u,f,e),f+=o.vertexM.byteLength),i&&(o.segmentParams=new Float64Array(u,f,o.segmentParamCount),f+=o.segmentParams.byteLength,o.segmentIndices=new Int32Array(u,f,e),o.segmentIndices.fill(k),f+=o.segmentIndices.byteLength),o.isMultipart()&&(o.partOffsets=new Int32Array(u,f,r+1),f+=o.partOffsets.byteLength,o.partFlags=new Int8Array(u,f,r+1),f+=o.partFlags.byteLength,"polygon"===o.type&&o.partFlags.subarray(0,r).fill(1)),i&&(o.segmentFlags=new Int8Array(u,f,e),o.segmentFlags.fill(1),f+=o.segmentFlags.byteLength),o}function _(t,e,{segmentFlags:r,segmentIndices:s,segmentParams:n},i,a){r[i]=4,s[i]=a;let[h,[o,l],u,f,p,g,m]=e.a,y=4;f||(y|=1),u||(y|=2);let x=(0,c.SW)(t,e),[d,v]=(0,c.Uk)(x,.5);return n[a++]=y,n[a++]=g,n[a++]=m,n[a++]=p,n[a++]=o,n[a++]=l,n[a++]=x.u2-x.u1,n[a++]=x.u1,n[a++]=d,n[a++]=v,a}function b(t,e,{segmentFlags:r,segmentIndices:s,segmentParams:n},i,a){r[i]=4,s[i]=a;let h=(0,p.io)(t,e);return F(h,4,...(0,o.mq)(h,.5),n,a)}function Y(t,e,{segmentFlags:r,segmentIndices:s,segmentParams:n},i,a){return r[i]=4,s[i]=a,F((0,l.pM)(t,e),0,...e.c[1],n,a)}function F(t,e,r,s,n,i){let{cx:a,cy:h,thetaStart:o,thetaEnd:l,radius:u}=t;return o>l||(e|=1),Math.abs(l-o)<=Math.PI||(e|=2),n[i++]=e,n[i++]=u,n[i++]=1,n[i++]=0,n[i++]=a,n[i++]=h,n[i++]=l-o,n[i++]=o,n[i++]=r,n[i++]=s,i}function X(t,{b:[e,[r,s],[n,i]]},{segmentFlags:a,segmentIndices:h,segmentParams:o},l,u){return a[l]=2,h[l]=u,o[u++]=r,o[u++]=s,o[u++]=n,o[u++]=i,u}const N=1.61803,k=-1},48526(t,e,r){r.d(e,{A:()=>y});var s,n=r(32198),i=r(4576),a=r(4718),h=r(91429),o=r(5443),l=r(91075),u=r(86738),f=r(16930),p=r(90634),c=r(47610),g=r(56993),m=r(43937);let y=s=class extends l.A{constructor(t){super(function(t){if(!t)return;let{points:e,hasM:r,hasZ:s,spatialReference:n}=t;switch(e??=[],e?.at(0)?.length){case 4:s??=!0,r??=!0;break;case 3:s??=!0!==r,r??=!s;break;default:s??=!1,r??=!1}return n??=f.A.WGS84,{...t,hasM:r,hasZ:s,points:e,spatialReference:n}}(t)),this.points=[],this.type="multipoint"}get cache(){return this.commitProperty("points"),this.commitProperty("hasZ"),this.commitProperty("hasM"),this.commitProperty("spatialReference"),{}}get extent(){let t=(0,p.ge)(this);return t?new o.A({...t,spatialReference:this.spatialReference}):null}writePoints(t,e){e.points=(0,a.o8)(this.points)}clone(){let{points:t,spatialReference:e,hasM:r,hasZ:n}=this;return new s({points:(0,a.o8)(t),spatialReference:e.clone(),hasM:r,hasZ:n})}equals(t){if(this===t)return!0;if(null==t)return!1;let e=this.spatialReference,r=t.spatialReference;return!(null!=e!=(null!=r)||null!=e&&null!=r&&!e.equals(r))&&(0,i.aI)(this.points,t.points,c.v6)}addPoint(t){return(0,g.h)(this,t),Array.isArray(t)?this.points.push(t):this.points.push(t.toArray()),this.notifyChange("points"),this}getPoint(t){if(!this._validateInputs(t))return null;let e=this.points[t],r={x:e[0],y:e[1],spatialReference:this.spatialReference},s=2;return this.hasZ&&(r.z=e[2],s=3),this.hasM&&(r.m=e[s]),new u.A(r)}removePoint(t){if(!this._validateInputs(t))return null;let e=new u.A(this.points.splice(t,1)[0],this.spatialReference);return this.notifyChange("points"),e}setPoint(t,e){return this._validateInputs(t)?((0,g.h)(this,e),Array.isArray(e)||(e=e.toArray()),this.points[t]=e,this.notifyChange("points"),this):this}toJSON(t){return this.write({},t)}_validateInputs(t){return null!=t&&t>=0&&t<this.points.length}};(0,n.Cg)([(0,h.MZ)({readOnly:!0})],y.prototype,"cache",null),(0,n.Cg)([(0,h.MZ)({readOnly:!0})],y.prototype,"extent",null),(0,n.Cg)([(0,h.MZ)({type:[[Number]],json:{write:{isRequired:!0}}})],y.prototype,"points",void 0),(0,n.Cg)([(0,m.K)("points")],y.prototype,"writePoints",null),y=s=(0,n.Cg)([(0,h.$K)("esri.geometry.Multipoint")],y),y.prototype.toJSON.isDefaultToJSON=!0},82799(t,e,r){r.d(e,{A:()=>g});var s,n=r(32198),i=r(4718),a=r(91429),h=r(5443),o=r(91075),l=r(86738),u=r(16930),f=r(90634),p=r(56993),c=r(43937);let g=s=class extends o.A{constructor(t){super(function(t){if(!t)return;let{paths:e,hasM:r,hasZ:s,spatialReference:n}=t;switch(e??=[],function(t){return"number"==typeof t[0]?.[0]}(e)&&(e=[e]),e[0]?.[0]?.length){case 4:s??=!0,r??=!0;break;case 3:s??=!0!==r,r??=!s;break;default:s??=!1,r??=!1}return n??=u.A.WGS84,{...t,hasM:r,hasZ:s,paths:e,spatialReference:n}}(t)),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(t,e){e.curvePaths=(0,i.o8)(t)}get extent(){let t=(0,f.Z3)(this),{spatialReference:e}=this;return t?new h.A({...t,spatialReference:e}):null}writePaths(t,e){e.paths=(0,i.o8)(this.paths)}addPath(t){if(!t)return;let e=this.paths,r=e.length;if(function(t){return!Array.isArray(t[0])}(t)){let s=[];for(let e=0,r=t.length;e<r;e++)s[e]=t[e].toArray();e[r]=s}else e[r]=t.slice();return this.notifyChange("paths"),this}clone(){let t=new s;return t.spatialReference=this.spatialReference,t.paths=(0,i.o8)(this.paths),t.curvePaths=(0,i.o8)(this.curvePaths),t.hasZ=this.hasZ,t.hasM=this.hasM,t}getPoint(t,e){if(!this._validateInputs(t,e))return null;let r=this.paths[t][e],s=this.hasZ,n=this.hasM;return s&&!n?new l.A(r[0],r[1],r[2],void 0,this.spatialReference):n&&!s?new l.A(r[0],r[1],void 0,r[2],this.spatialReference):s&&n?new l.A(r[0],r[1],r[2],r[3],this.spatialReference):new l.A(r[0],r[1],this.spatialReference)}insertPoint(t,e,r){return this._validateInputs(t,e,!0)?((0,p.h)(this,r),Array.isArray(r)||(r=r.toArray()),this.paths[t].splice(e,0,r),this.notifyChange("paths"),this):this}removePath(t){if(!this._validateInputs(t,null))return null;let e=this.paths.splice(t,1)[0],r=this.spatialReference,s=e.map(t=>new l.A(t,r));return this.notifyChange("paths"),s}removePoint(t,e){if(!this._validateInputs(t,e))return null;let r=new l.A(this.paths[t].splice(e,1)[0],this.spatialReference);return this.notifyChange("paths"),r}setPoint(t,e,r){return this._validateInputs(t,e)?((0,p.h)(this,r),Array.isArray(r)||(r=r.toArray()),this.paths[t][e]=r,this.notifyChange("paths"),this):this}_validateInputs(t,e,r=!1){if(null==t||t<0||t>=this.paths.length)return!1;if(null!=e){let s=this.paths[t];if(r&&(e<0||e>s.length)||!r&&(e<0||e>=s.length))return!1}return!0}toJSON(t){return this.write({},t)}};(0,n.Cg)([(0,a.MZ)({readOnly:!0})],g.prototype,"cache",null),(0,n.Cg)([(0,a.MZ)({json:{write:!0,origins:{"portal-item":{write:!1},"web-map":{write:!1},"web-scene":{write:!1}}}})],g.prototype,"curvePaths",void 0),(0,n.Cg)([(0,c.K)("curvePaths")],g.prototype,"writeCurvePaths",null),(0,n.Cg)([(0,a.MZ)({readOnly:!0})],g.prototype,"extent",null),(0,n.Cg)([(0,a.MZ)({type:[[[Number]]],json:{write:{isRequired:!0}}})],g.prototype,"paths",void 0),(0,n.Cg)([(0,c.K)("paths")],g.prototype,"writePaths",null),g=s=(0,n.Cg)([(0,a.$K)("esri.geometry.Polyline")],g),g.prototype.toJSON.isDefaultToJSON=!0},78125(t,e,r){r.r(e),r.d(e,{fromExtent:()=>y,fromGeometry:()=>m,fromMultipoint:()=>x,fromPoint:()=>d,fromPolygon:()=>v,fromPolyline:()=>C,fromPolylineUsingImportOperator:()=>M,fromSpatialReference:()=>P,getSpatialReference:()=>g,toExtent:()=>Z,toGeometry:()=>A,toMultipoint:()=>w,toPoint:()=>R,toPolygon:()=>E,toPolyline:()=>O});var s=r(83661),n=r(55537),i=r(95213),a=r(88885),h=r(5443),o=r(48526),l=r(86738),u=r(39829),f=r(82799),p=(r(90293),r(83299));const c="_gxVersion";function g(t){return Array.isArray(t)?t[0].spatialReference:t.spatialReference}function m(t){switch(t.type){case"point":return d(t);case"multipoint":return x(t);case"polyline":return C(t);case"polygon":return v(t);case"extent":return y(t);default:throw Error(`Unsupported geometry type: ${t.type}`)}}function y(t){if(!t.getCacheValue(c)){let e=new i.E;e.setCoords(t.xmin,t.ymin,t.xmax,t.ymax),t.hasM&&e.setInterval(2,0,t.mmin,t.mmax),t.hasZ&&e.setInterval(1,0,t.zmin,t.zmax),t.setCacheValue(c,e)}return t.getCacheValue(c)}function x(t){if(!t.getCacheValue(c)){let e=new a.M,r=new i.P,s=t.points,n=t.hasM,h=t.hasZ,o=h?3:2;for(let t=0,i=s.length;t<i;t++){let i=s[t];r.setXYCoords(i[0],i[1]),h&&r.setZ(i[2]??0),n&&r.setM(i[o]??NaN),e.add(r)}t.setCacheValue(c,e)}return t.getCacheValue(c)}function d(t){if(!t.getCacheValue(c)){let e=new i.P;e.setXYCoords(t.x,t.y),t.hasM&&e.setM(t.m),t.hasZ&&e.setZ(t.z),t.setCacheValue(c,e)}return t.getCacheValue(c)}function v(t){if(!t.getCacheValue(c)){let{curveRings:e,hasM:r,hasZ:s,rings:n}=t,i=(0,p.fromGeometryToGXGeometry)({curveRings:e,hasM:r,hasZ:s,rings:n});t.setCacheValue(c,i)}return t.getCacheValue(c)}function C(t){if(!t.getCacheValue(c)){let{curvePaths:e,hasM:r,hasZ:s,paths:n}=t,i=(0,p.fromGeometryToGXGeometry)({curvePaths:e,hasM:r,hasZ:s,paths:n});t.setCacheValue(c,i)}return t.getCacheValue(c)}function M(t){if(!t.getCacheValue(c)){let{curvePaths:e,hasM:r,hasZ:s,paths:n}=t,i=(0,p.fromGeometryToGXGeometryUsingImportOperator)({curvePaths:e,hasM:r,hasZ:s,paths:n});t.setCacheValue(c,i)}return t.getCacheValue(c)}function P(t){return t.cache?(t.cache[c]??=(0,p.fromSpatialReference)(t),t.cache[c]):(0,p.fromSpatialReference)(t)}function A(t,e){if(t)switch(t.getGeometryType()){case n.G.enumPoint:return R(t,e);case n.G.enumEnvelope:return Z(t,e);case n.G.enumMultiPoint:return w(t,e);case n.G.enumPolyline:return O(t,e);case n.G.enumPolygon:return E(t,e)}return null}function Z(t,e){if(t.isEmpty())return null;let r=new h.A({xmin:t.getXMin(),ymin:t.getYMin(),xmax:t.getXMax(),ymax:t.getYMax(),spatialReference:e}),s=t.getDescription();if(s.hasM()){let e=t.queryInterval(2,0);r.mmin=e.vmin,r.mmax=e.vmax}if(s.hasZ()){let e=t.queryInterval(1,0);r.zmin=e.vmin,r.zmax=e.vmax}return r.setCacheValue(c,t),r}function w(t,e){if(t.isEmpty())return null;let r=t.getDescription(),s=r.hasM(),n=r.hasZ(),a=[],h=new i.P;for(let e=0,r=t.getPointCount();e<r;e++){t.getPointByVal(e,h);let r=[h.getX(),h.getY()];n&&r.push(h.getZ()),s&&r.push(h.getM()),a.push(r)}let l=new o.A({hasM:s,hasZ:n,points:a,spatialReference:e});return l.setCacheValue(c,t),l}function R(t,e){if(t instanceof s.P)return new l.A({x:t.x,y:t.y,spatialReference:e});if(t.isEmpty())return null;let r=new l.A({x:t.getX(),y:t.getY(),spatialReference:e}),n=t.getDescription();return n.hasM()&&(r.m=t.getM()),n.hasZ()&&(r.z=t.getZ()),r.setCacheValue(c,t),r}function E(t,e){if(t.isEmpty())return null;let r=u.A.fromJSON({...(0,p.toGeometry)(t,null),spatialReference:e});return r.setCacheValue(c,t),r}function O(t,e){if(t.isEmpty())return null;let r=f.A.fromJSON({...(0,p.toGeometry)(t,null),spatialReference:e});return r.setCacheValue(c,t),r}},92722(t,e,r){r.d(e,{A:()=>n});var s=r(69397);class n{constructor(t=[],e=[],r=!1,s=!1){this.lengths=t??[],this.coords=e??[],this.hasZ=r,this.hasM=s}static fromJSON({lengths:t,coords:e,hasZ:r,hasM:s}){return new n(t,e,r||!1,s||!1)}static fromRect([t,e,r,s]){let i=r-t,a=s-e;return new n([5],[t,e,i,0,0,a,-i,0,0,-a])}get isPoint(){return 0===this.lengths.length&&this.coords.length>=2}get maxLength(){return Math.max(...this.lengths)}get size(){return this.isPoint?1:this.lengths.reduce((t,e)=>t+e,0)}get usedMemory(){return 64+(0,s.Qf)(this.lengths,this.coords)}get stride(){return+!!this.hasZ+2+ +!!this.hasM}area(){if(this.isPoint)return 0;let t=0,e=0;for(let r of this.lengths){if(r<3)continue;let{stride:s}=this,n=this.coords[s*e],i=this.coords[s*e+1];for(let a=1;a<r;a+=1){let r=s*(e+a),h=this.coords[r],o=this.coords[r+1];t+=-.5*(h-n)*(o+i),n=h,i=o}e+=r}return t}forEachVertex(t){let e=0;if(this.isPoint)return t(this.coords[0],this.coords[1]);let{stride:r}=this;for(let s of this.lengths){for(let n=0;n<s;n++){let s=r*(e+n);t(this.coords[s],this.coords[s+1])}e+=s}}deltaDecode(){let t=this.clone(),{coords:e,lengths:r}=t,s=0,{stride:n}=this;for(let t of r){for(let r=1;r<t;r++){let t=n*(s+r);e[t]+=e[t-n],e[t+1]+=e[t+1-n]}s+=t}return t}clone(t){if(this.isPoint)return new n([],Array.from(this.coords.slice(0,this.stride)),this.hasZ,this.hasM);let e=Array.from(this.lengths),{stride:r,size:s}=this,i=this.coords.slice(0,s*r);return t?(t.set(i),new n(e,t,this.hasZ,this.hasM)):new n(e,Array.from(i),this.hasZ,this.hasM)}justXY(){let{stride:t,size:e}=this;if(2===t)return this;let r=Array(e*t);for(let e=0,s=0;e<r.length;e+=t)r[s++]=this.coords[e],r[s++]=this.coords[e+1];return new n(this.lengths,r,!1,!1)}}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[433],{15142(t,e,i){i.d(e,{A:()=>o});var s=i(4576),a=i(21818);const h=(t,e,i,s)=>{let a=e,h=e,n=i>>>1,l=t[a-1];for(;h<=n;){h=a<<1,h<i&&s(t[h-1],t[h])<0&&++h;let e=t[h-1];if(s(e,l)<=0)break;t[a-1]=e,a=h}t[a-1]=l},n=(t,e)=>t<e?-1:+(t>e);function l(t,e,i,s){void 0===e&&(e=0),void 0===i&&(i=t.length),void 0===s&&(s=n);for(let a=i>>>1;a>e;a--)h(t,a,i,s);let a=e+1;for(let n=i-1;n>e;n--){let i=t[e];t[e]=t[n],t[n]=i,h(t,a,n,s)}}function*r(t,e,i,s){void 0===e&&(e=0),void 0===i&&(i=t.length),void 0===s&&(s=n);for(let a=i>>>1;a>e;a--)h(t,a,i,s),yield;let a=e+1;for(let n=i-1;n>e;n--){let i=t[e];t[e]=t[n],t[n]=i,h(t,a,n,s),yield}}class o{constructor(t){this.data=[],this._length=0,this._allocator=void 0,this._deallocator=()=>null,this._shrink=()=>{},this._hint=new s.vW,t&&(t.initialSize&&(this.data=Array(t.initialSize)),t.allocator&&(this._allocator=t.allocator),void 0!==t.deallocator&&(this._deallocator=t.deallocator),t.shrink&&(this._shrink=()=>d(this)))}toArray(){return this.data.slice(0,this.length)}filter(t){let e=[];for(let i=0;i<this._length;i++){let s=this.data[i];t(s)&&e.push(s)}return e}at(t){if((t=Math.trunc(t)||0)<0&&(t+=this._length),!(t<0||t>=this._length))return this.data[t]}includes(t,e){let i=this.data.indexOf(t,e);return-1!==i&&i<this.length}get length(){return this._length}set length(t){if(t>this._length){if(this._allocator){for(;this._length<t;)this.data[this._length++]=this._allocator(this.data[this._length]);return}this._length=t}else{if(this._deallocator)for(let e=t;e<this._length;++e)this.data[e]=this._deallocator(this.data[e]);this._length=t,this._shrink()}}clear(){this.length=0}prune(){this.clear(),this.data=[]}push(t){this.data[this._length++]=t}pushArray(t,e=t.length){for(let i=0;i<e;i++)this.data[this._length++]=t[i]}pushAll(t){for(let e of t)this.data[this._length++]=e}fill(t,e){for(let i=0;i<e;i++)this.data[this._length++]=t}pushNew(){this._allocator&&(this.data[this.length]=this._allocator(this.data[this.length]));let t=this.data[this._length];return++this._length,t}unshift(t){this.data.unshift(t),this._length++,d(this)}pop(){if(0===this.length)return;let t=this.data[this.length-1];return--this.length,this._shrink(),t}remove(t){let e=(0,s.qh)(this.data,(0,a.z)(t),this.length,this._hint);if(-1!==e)return this.data.splice(e,1),--this.length,t}removeUnordered(t){return this.removeUnorderedIndex((0,s.qh)(this.data,(0,a.z)(t),this.length,this._hint))}removeUnorderedIndex(t){if(!(t>=this.length||t<0))return this.swapElements(t,this.length-1),this.pop()}removeUnorderedMany(t,e=t.length,i){this.length=(0,s.mW)(this.data,t,this.length,e,this._hint,i),this._shrink()}front(){if(0!==this.length)return this.data[0]}back(){if(0!==this.length)return this.data[this.length-1]}swapElements(t,e){if(t>=this.length||e>=this.length||t===e)return;let i=this.data[t];this.data[t]=this.data[e],this.data[e]=i}sort(t){l(this.data,0,this.length,t)}iterableSort(t){return r(this.data,0,this.length,t)}some(t,e){for(let i=0;i<this.length;++i)if(t.call(e,this.data[i],i,this.data))return!0;return!1}find(t,e){let{data:i,length:s}=this;for(let a=0;a<s;++a)if(t.call(e,i[a]))return i[a]}filterInPlace(t,e){let i=0;for(let s=0;s<this._length;++s){let a=this.data[s];t.call(e,a,s,this.data)&&(this.data[s]=this.data[i],this.data[i]=a,i++)}if(this._deallocator)for(let t=i;t<this._length;t++)this.data[t]=this._deallocator(this.data[t]);return this._length=i,this._shrink(),this}forAll(t,e){let{data:i,length:s}=this;for(let a=0;a<s;++a)t.call(e,i[a],a,i)}forEach(t,e){this.data.slice(0,this.length).forEach(t,e)}map(t,e){let i=Array(this.length);for(let s=0;s<this.length;++s)i[s]=t.call(e,this.data[s],s,this.data);return i}reduce(t,e){let i=e;for(let e=0;e<this.length;++e)i=t(i,this.data[e],e,this.data);return i}has(t){let e=this.length,i=this.data;for(let s=0;s<e;++s)if(i[s]===t)return!0;return!1}*[Symbol.iterator](){for(let t=0;t<this.length;++t)yield this.data[t]}}function d(t){t.data.length>1.5*t.length&&(t.data.length=Math.floor(1.1*t.length))}},71936(t,e,i){i.r(e),i.d(e,{default:()=>r});var s=i(1843);function a(t,e){return e.push(t.buffer),{buffer:t.buffer,layout:new s.l5(t.layout)}}var h=i(99058),n=i(93406),l=i(44801);class r{async extract(t){let e=o(t),i=(0,l.o6)(e),s=[e.data.buffer];return{result:d(i,s),transferList:s}}async extractComponentsEdgeLocations(t){let e=o(t),i=(0,l.hx)(e.data,e.skipDeduplicate,e.indices,e.indicesLength),s=[];return{result:a((0,n.K)(i,u).regular.instancesData,s),transferList:s}}async extractEdgeLocations(t){let e=o(t),i=(0,l.hx)(e.data,e.skipDeduplicate,e.indices,e.indicesLength),s=[];return{result:a((0,n.K)(i,c).regular.instancesData,s),transferList:s}}}function o(t){return{data:h.I$.createView(t.dataBuffer),indices:"Uint32Array"===t.indicesType?new Uint32Array(t.indices):"Uint16Array"===t.indicesType?new Uint16Array(t.indices):"Uint8Array"===t.indicesType?new Uint8Array(t.indices):t.indices,indicesLength:t.indicesLength,writerSettings:t.writerSettings,skipDeduplicate:t.skipDeduplicate}}function d(t,e){return e.push(t.regular.lodInfo.lengths.buffer),e.push(t.silhouette.lodInfo.lengths.buffer),{regular:{instancesData:a(t.regular.instancesData,e),lodInfo:{lengths:t.regular.lodInfo.lengths.buffer}},silhouette:{instancesData:a(t.silhouette.instancesData,e),lodInfo:{lengths:t.silhouette.lodInfo.lengths.buffer}},averageEdgeLength:t.averageEdgeLength}}const c=new class{allocate(t){return l.Jb.createBuffer(t)}trim(t,e){return t.slice(0,e)}write(t,e,i){t.position0.setVec(e,i.position0),t.position1.setVec(e,i.position1)}},u=new class{allocate(t){return l.HY.createBuffer(t)}trim(t,e){return t.slice(0,e)}write(t,e,i){t.position0.setVec(e,i.position0),t.position1.setVec(e,i.position1),t.componentIndex.set(e,i.componentIndex)}}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3500],{49859(e,t,i){i.d(t,{A:()=>L});var l=i(32198),r=i(56507),n=i(49186),o=i(25482),s=i(53966),a=i(17676),u=i(563),c=i(91429),h=i(78888),f=i(5443),m=i(86738),d=i(16930),p=i(7548),x=i(4366),g=i(37373);const y=new Map,I=new class{constructor(e=15e3,t=5e3,i=-1){this._timer=null,this._cachedBlocks=new Map,this._size=-1,this._duration=e,this._interval=Math.min(e,t),this._size=i}decreaseRefCount(e,t){let i=e+"/"+t,l=this._cachedBlocks;if(l.has(i)){let e=l.get(i);return e.refCount--,e.refCount<=0&&(l.delete(i),e.controller&&e.controller.abort()),e.refCount}return 0}getBlock(e,t){let i=e+"/"+t,l=this._cachedBlocks;if(l.has(i)){let e=l.get(i);return e.ts=Date.now(),e.refCount++,l.delete(i),l.set(i,e),e.block}return null}putBlock(e,t,i,l){let r=this._cachedBlocks,n=e+"/"+t;if(r.has(n)){let e=r.get(n);e.ts=Date.now(),e.refCount++}else r.set(n,{block:i,ts:Date.now(),refCount:1,controller:l});this._trim(),this._updateTimer()}deleteBlock(e,t){let i=this._cachedBlocks,l=e+"/"+t;i.has(l)&&i.delete(l)}updateMaxSize(e){this._size=e,this._trim()}empty(){this._cachedBlocks.clear(),this._clearTimer()}getCurrentSize(){return this._cachedBlocks.size}_updateTimer(){if(null!=this._timer)return;let e=this._cachedBlocks;this._timer=setInterval(()=>{let t=Array.from(e),i=Date.now();for(let l=0;l<t.length&&t[l][1].ts<=i-this._duration;l++)e.delete(t[l][0]);0===e.size&&this._clearTimer()},this._interval)}_trim(){let e=this._cachedBlocks;if(-1===this._size||this._size>=e.size)return;let t=Array.from(e).sort((e,t)=>e[1].refCount-t[1].refCount||e[1].ts-t[1].ts);for(let i=0;i<t.length-this._size;i++)e.delete(t[i][0])}_clearTimer(){null!=this._timer&&(clearInterval(this._timer),this._timer=null)}}(15e3,5e3,100);function w(e,t,i){let l=y.get(e);if(!l)return null==t?I.decreaseRefCount(e,i):0;if(null==t||null==l[t])return I.decreaseRefCount(e,i);let r=l[t]?.cache,n=r?.get(i);if(r&&n){if(n.refCount--,0===n.refCount){r.delete(i);for(let e=0;e<l.length;e++)l[e]?.cache.delete(i);n.controller&&n.controller.abort()}return n.refCount}return 0}function R(e,t,i){let l=y.get(e);if(!l)return null==t?I.getBlock(e,i):null;if(null==t||null==l[t]){for(let e=0;e<l.length;e++){let t=l[e]?.cache.get(i);if(t)return t.refCount++,t.block}return I.getBlock(e,i)}let r=l[t]?.cache.get(i);if(r)return r.refCount++,r.block;for(let e=0;e<l.length;e++){if(e===t||!l[e])continue;let r=l[e]?.cache,n=r?.get(i);if(r&&n)return n.refCount++,r.set(i,n),n.block}return null}function k(e,t,i,l,r=null){let n=y.get(e);if(!n)return void(t??I.putBlock(e,i,l,r));if(null==t||null==n[t])return void I.putBlock(e,i,l,r);let o={refCount:1,block:l,isResolved:!1,isRejected:!1,controller:r};l.then(()=>o.isResolved=!0).catch(()=>o.isRejected=!0),n[t]?.cache.set(i,o)}function _(e,t,i){let l=y.get(e);l?null!=t&&null!=l[t]?l[t]?.cache.delete(i):I.deleteBlock(e,i):t??I.deleteBlock(e,i)}var b=i(94778),v=i(96381),S=i(34930),C=i(47520),T=i(34251),B=i(60694),M=i(10873),P=i(45617),A=i(91806),z=i(20223),W=i(87045);let H=0,L=class extends o.o{constructor(){super(...arguments),this._tileFetchQueue=new u.QueueProcessor({concurrency:32,process:(e,t)=>this.fetchRawTile(e.pyramidLevel,e.row,e.col,{...e.options,signal:t})}),this.datasetName=null,this.datasetFormat=null,this.hasUniqueSourceStorageInfo=!0,this.rasterInfo=null,this.ioConfig={sampling:"closest"},this.rawBlockRegistryIds=[],this.refresh=(0,a.sg)(async e=>{await this._openPromise;let t=await this._refresh(e);return t.dataChanged&&function(e,t){let i=y.get(e);if(i){let e=t.map(e=>i[e]).filter(e=>null!=e);for(let t of e)t&&(Array.from(t.cache.values()).forEach(e=>{!e.isResolved&&!e.isRejected&&e.controller&&e.controller.abort()}),t.cache.clear())}}(this.rasterId,this.rawBlockRegistryIds),t})}normalizeCtorArgs(e){return e?.ioConfig&&(e={...e,ioConfig:{resolution:null,bandIds:null,sampling:"closest",tileInfo:W.A.create(),...e.ioConfig}}),e}get _isGlobalWrappableSource(){let{rasterInfo:e}=this,t=(0,g.FT)(e.spatialReference);return null!=t&&e.extent.width>=t/2}get _hasNoneOrGCSShiftTransform(){let{transform:e}=this.rasterInfo;return null==e||"gcs-shift"===e.type}set rasterJobHandler(e){this._set("rasterJobHandler",e),(0,p.qg)(this)&&this.primaryRasters?.rasters?.forEach(t=>t.rasterJobHandler=e)}get rasterId(){return this.url||"rasterId-"+H++}set url(e){this._set("url",(0,B.Jf)(e,s.A.getLogger(this)))}async open(e){return this._openPromise??=(0,g.Hh)().then(()=>this._open(e)),this._openPromise}async fetchTile(e,t,i,l={}){let r=l.tileInfo||this.rasterInfo.storageInfo.tileInfo,o=this.getTileExtentFromTileInfo(e,t,i,r);if(!o)throw new n.A("imagery-tile:out-of-bounds","Level for fetch tile out of range");return l={noClip:!0,...l},this.fetchPixels(o,r.size[0],r.size[1],l)}async identify(e,t={}){e=(0,h.PZ)(m.A,e).clone().normalize();let{multidimensionalDefinition:i,timeExtent:l}=t,{rasterInfo:r}=this,{hasMultidimensionalTranspose:n,multidimensionalInfo:o}=r,{transposedVariableName:s}=t,a=null!=o&&n&&(null!=l||(0,x.DY)(i));a&&!s&&(s=null!=i&&i.length>0?i[0].variableName??void 0:o.variables[0].name,t={...t,transposedVariableName:s}),t=this._getRequestOptionsWithSliceId(t);let{spatialReference:u,extent:c}=r,{datumTransformation:d}=t,y=(0,g._I)(e,u,d);if(!c.intersects(y))return{location:y,value:null};if(null!=r.transform){let e=r.transform.inverseTransform(y);if(!r.nativeExtent.intersects(e))return{location:e,value:null};y=e}let I=null!=s&&null!=o&&r.hasMultidimensionalTranspose;if((0,p.qg)(this)){let e=this.primaryRasters.rasters[0];if(I)return e.identify(y,t);let{pixelSize:l}=r,n=3*l.x/2,o=3*l.y/2,s=new f.A({xmin:y.x-n,xmax:y.x+n,ymin:y.y-o,ymax:y.y+o,spatialReference:u}),a={interpolation:"nearest",multidimensionalDefinition:i,sliceId:t.sliceId,bandIds:t.bandIds},{pixelBlock:c}=await e.fetchPixels(s,3,3,a),{pixelBlock:h}=await this.fetchPixels(s,3,3,a);if(null==c)return{location:y,value:null};let m,d=!c.mask||c.mask[4]?c.pixels.map(e=>e[4]):null;return null!=h&&(m=!h.mask||h.mask[4]?h.pixels.map(e=>e[4]):void 0),{location:y,value:d,processedValue:m,pyramidLevel:0}}let w=0;if(!I){let{srcResolution:i}=t;if(i)i.spatialReference&&(i=(0,S.T5)(new m.A(i),u)),w=(0,g.t$)(i,r,this.ioConfig.sampling).pyramidLevel;else if(w=await this.computeBestPyramidLevelForLocation(e,t),null==w)return{location:y,value:null}}let R=this.identifyPixelLocation(y,w,null,I);if(null===R)return{location:y,value:null};let{row:k,col:_,rowOffset:b,colOffset:v,blockWidth:C}=R,T=await this._fetchRawTile(w,k,_,t);if(!T?.pixels?.length)return{location:y,value:null};let B=b*C+v;return this._processIdentifyResult(T,{srcLocation:y,position:B,pyramidLevel:w,useTransposedTile:!!I,requestSomeSlices:a,identifyOptions:t})}async fetchPixels(e,t,i,l={}){e=(0,g.Ps)(e),l=this._getRequestOptionsWithSliceId(l);let{_hasNoneOrGCSShiftTransform:r}=this;if(l.requestRawData&&r)return this._fetchPixels(e,t,i,l);let n=(0,g.FT)(e.spatialReference),o=(0,g.OM)(e);if(null==n||0===o||1===o&&this._isGlobalWrappableSource&&r)return this._fetchPixels(e,t,i,l);if(o>=3)return{extent:e,pixelBlock:null};let s=[],{xmin:a,xmax:u}=e,c=Math.round(n/(u-a)*t),h=c-Math.round((n/2-a)/(u-a)*t),m=0,d=[];for(let r=0;r<=o;r++){let p=0===r?a:-n/2,x=r===o?u-n*r:n/2,g=new f.A({xmin:p,xmax:x,ymin:e.ymin,ymax:e.ymax,spatialReference:e.spatialReference}),y=0===r?c-h:r===o?t-m:c;m+=y,d.push(y);let I=l.disableWrapAround&&r>0?null:this._fetchPixels(g,y,i,l);s.push(I)}let p=(await Promise.all(s)).map(e=>e?.pixelBlock),x=null,y={width:t,height:i};return x=this.rasterJobHandler?(await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:p,srcMosaicSize:y,destDimension:null,coefs:null,sampleSpacing:null,interpolation:"nearest",alignmentInfo:null,blockWidths:d},l)).pixelBlock:(0,C.z7)(p,y,{blockWidths:d}),{extent:e,srcExtent:(0,g._l)(e,this.rasterInfo.spatialReference,l.datumTransformation),pixelBlock:x}}async fetchRawPixels(e,t,i,l={}){t={x:Math.floor(t.x),y:Math.floor(t.y)};let r=await this._fetchRawTiles(e,t,i,l),{nativeExtent:n,nativePixelSize:o,storageInfo:s}=this.rasterInfo,a=2**e,u=o.x*a,c=o.y*a,h=new f.A({xmin:n.xmin+u*t.x,xmax:n.xmin+u*(t.x+i.width-1),ymin:n.ymax-c*(t.y+i.height-1),ymax:n.ymax-c*t.y,spatialReference:n.spatialReference});if(!r)return{extent:h,srcExtent:h,pixelBlock:null};let{pixelBlocks:m,mosaicSize:d}=r;if(1===m.length&&null!=m[0]&&m[0].width===i.width&&m[0].height===i.height)return{extent:h,srcExtent:h,pixelBlock:r.pixelBlocks[0]};let p,x=e>0?s.pyramidBlockWidth:s.blockWidth,g=e>0?s.pyramidBlockHeight:s.blockHeight,y={x:t.x%x,y:t.y%g};return p=this.rasterJobHandler?(await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:m,srcMosaicSize:d,destDimension:i,clipOffset:y,clipSize:i,coefs:null,sampleSpacing:null,interpolation:l.interpolation,alignmentInfo:null,blockWidths:null},l)).pixelBlock:(0,C.z7)(m,d,{clipOffset:y,clipSize:i}),{extent:h,srcExtent:h,pixelBlock:p}}fetchRawTile(e,t,i,l){throw new n.A("BaseRaster:read-not-implemented","fetchRawTile() is not implemented")}computeExtent(e){return(0,g._l)(this.rasterInfo.extent,e)}decodePixelBlock(e,t){return this.rasterJobHandler?this.rasterJobHandler.decode({data:e,options:t}):(0,v.D)(e,t)}async request(e,t,i=0){let{customFetchParameters:l}=this.ioConfig,{range:n,query:o,headers:s}=t;i=i??t.retryCount??this.ioConfig.retryCount;let a=n?{Range:`bytes=${n.from}-${n.to}`}:null;try{return await(0,r.A)(e,{...t,query:{...o,...l},headers:{...s,...a}})}catch(l){if(i>0)return i--,this.request(e,t,i);throw l}}getSliceIndex(e){let{multidimensionalInfo:t}=this.rasterInfo;return null==t||null==e||0===e.length?null:(0,x.NG)(e,t)}getTileExtentFromTileInfo(e,t,i,l){let r=l.lodAt(e);return r?this.getTileExtent({x:r.resolution,y:r.resolution},t,i,l.origin,l.spatialReference,l.size):null}updateTileInfo(){let{storageInfo:e,spatialReference:t,extent:i,pixelSize:l}=this.rasterInfo,{pyramidResolutions:r}=e;if(!e.tileInfo){let n=[],o=e.maximumPyramidLevel||0,s=(l.x+l.y)/2,a=1/.0254*96*s;for(let e=0;e<=o&&(n.unshift(new A.A({level:o-e,resolution:s,scale:a})),e!==o);e++)if(r){let t=(r[e].x+r[e].y)/2;a*=t/s,s=t}else s*=2,a*=2;let u=new m.A({x:i.xmin,y:i.ymax,spatialReference:t});e.tileInfo=new W.A({origin:u,size:[e.blockWidth,e.blockHeight],spatialReference:t,lods:n}),e.isVirtualTileInfo=!0}}createRemoteDatasetStorageInfo(e,t=512,i=512,l){let{width:r,height:n,nativeExtent:o,pixelSize:s,spatialReference:a}=e,u=new m.A({x:o.xmin,y:o.ymax,spatialReference:a});l??=Math.max(0,Math.round(Math.log(Math.max(r,n))/Math.LN2-8));let c=this.computeBlockBoundary(o,512,512,{x:o.xmin,y:o.ymax},[s],l);e.storageInfo=new z.A({blockWidth:t,blockHeight:i,pyramidBlockWidth:t,pyramidBlockHeight:i,origin:u,firstPyramidLevel:1,maximumPyramidLevel:l,blockBoundary:c})}async computeBestPyramidLevelForLocation(e,t={}){return 0}computeBlockBoundary(e,t,i,l,r,n=0,o=2){if(1===r.length&&n>0){r=[...r];let{x:e,y:t}=r[0];for(let i=0;i<n;i++)e*=o,t*=o,r.push({x:e,y:t})}let s=[],{x:a,y:u}=l;for(let l=0;l<r.length;l++){let{x:n,y:o}=r[l];s.push({minCol:Math.floor((e.xmin-a+.1*n)/t/n),maxCol:Math.floor((e.xmax-a-.1*n)/t/n),minRow:Math.floor((u-e.ymax+.1*o)/i/o),maxRow:Math.floor((u-e.ymin-.1*o)/i/o)})}return s}getPyramidPixelSize(e){let{nativePixelSize:t}=this.rasterInfo,{pyramidResolutions:i,pyramidScalingFactor:l}=this.rasterInfo.storageInfo;if(0===e)return t;if(null!=i&&i.length)return i[e-1];let r=l**e;return{x:t.x*r,y:t.y*r}}identifyPixelLocation(e,t,i,l){let{spatialReference:r,nativeExtent:n,storageInfo:o}=this.rasterInfo,{maximumPyramidLevel:s,origin:a,transposeInfo:u}=o,c=l&&null!=u?u.tileSize[0]:o.blockWidth,h=l&&null!=u?u.tileSize[1]:o.blockHeight,f=(0,g._I)(e,r,i);if(!n.intersects(f)||t<0||t>s)return null;let{x:m,y:d}=this.getPyramidPixelSize(t),p=(a.y-f.y)/d/h,x=(f.x-a.x)/m/c,y=Math.min(h-1,Math.floor((p-Math.floor(p))*h)),I=Math.min(c-1,Math.floor((x-Math.floor(x))*c));return{pyramidLevel:t,row:Math.floor(p),col:Math.floor(x),rowOffset:y,colOffset:I,blockWidth:c,srcLocation:f}}getTileExtent(e,t,i,l,r,n){let[o,s]=n,a=l.x+i*o*e.x,u=a+o*e.x,c=l.y-t*s*e.y,h=c-s*e.y;return new f.A({xmin:a,xmax:u,ymin:h,ymax:c,spatialReference:r})}getBlockWidthHeight(e){return{blockWidth:e>0?this.rasterInfo.storageInfo.pyramidBlockWidth:this.rasterInfo.storageInfo.blockWidth,blockHeight:e>0?this.rasterInfo.storageInfo.pyramidBlockHeight:this.rasterInfo.storageInfo.blockHeight}}isBlockOutside(e,t,i){let l=this.rasterInfo.storageInfo.blockBoundary[e];return!l||l.maxRow<t||l.maxCol<i||l.minRow>t||l.minCol>i}updateImageSpaceRasterInfo(e){let{pixelSize:t}=e,{width:i,height:l}=e,r=d.A.WebMercator;e.spatialReference=r,e.extent=e.nativeExtent=new f.A({xmin:-.5,ymax:.5,xmax:i-.5,ymin:.5-l,spatialReference:r}),e.isPseudoSpatialReference=!0,e.transform=null,e.pixelSize=new m.A({x:1,y:1,spatialReference:r});let{extent:n,storageInfo:o}=e;if(o){o.origin=new m.A({x:n.xmin,y:n.ymax,spatialReference:r});let{pyramidResolutions:i,tileInfo:l}=o;if(i&&i.forEach(e=>{e.x/=t.x,e.y/=t.y}),l){l.origin=o.origin;let t=(e.nativePixelSize.x+e.nativePixelSize.y)/2;l.lods.forEach((e,i)=>{e.resolution=t*2**i,e.scale=96*e.resolution/.0254})}}}async _refresh(e){return{dataChanged:!0}}async _fetchPixels(e,t,i,l={}){let r=(0,g.OM)(e);if(r>=2)return{extent:e,pixelBlock:null};let n=this._getSourceDataInfo(e,t,i,l),{pyramidLevel:o,srcResolution:s,srcWidth:a,srcHeight:u,ul:c}=n,{srcExtent:h}=n;if(0===a||0===u)return{extent:e,srcExtent:h,pixelBlock:null};let{rasterInfo:f}=this,d=f.transform,p="gcs-shift"===d?.type,x=null!=(0,g.FT)(e.spatialReference);(p||!x)&&(r=(0,g.OM)(h,p));let y=await this._fetchRawTiles(o,c,{width:a,height:u,wrapCount:r},l);if(!y)return{extent:e,srcExtent:h,pixelBlock:null};h=y.extent;let I=f.storageInfo,w=o>0?I.pyramidBlockWidth:I.blockWidth,R=o>0?I.pyramidBlockHeight:I.blockHeight,{x:k,y:_}=f.pixelSize;if(o>0){let{pyramidResolutions:e,pyramidScalingFactor:t}=I;if(null!=e&&e[o-1])({x:k,y:_}=e[o-1]);else{let e=t**o;k*=e,_*=e}}let b=f.spatialReference,v=new m.A({x:k,y:_,spatialReference:b}),S=w===a&&R===u&&c.x%w===0&&c.y%R===0,B=new m.A({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/i,spatialReference:e.spatialReference}),M=!e.spatialReference.equals(b),P=b.isGeographic?1e-9:1e-4,{datumTransformation:A}=l;if(!M&&S&&1===y.pixelBlocks.length&&w===t&&R===i&&function(e,t,i){return Math.abs(e.x-t.x)<i&&Math.abs(e.y-t.y)<i}(s,B,P))return{extent:e,srcExtent:h,srcTilePixelSize:v,pixelBlock:y.pixelBlocks[0]};let z=x&&null!=(0,g.FT)(h.spatialReference)&&this._hasNoneOrGCSShiftTransform,W=l.requestProjectedLocalDirections&&this.rasterInfo.dataType.startsWith("vector");W&&!this.rasterJobHandler&&await(0,g.Hh)();let H,L=this.rasterJobHandler?await this.rasterJobHandler.getProjectionOffsetGrid({projectedExtent:e,srcBufferExtent:h,pixelSize:B.toJSON(),datumTransformation:A,rasterTransform:d,hasWrapAround:r>0||z,isAdaptive:!1!==this.ioConfig.optimizeProjectionAccuracy,includeGCSGrid:W},l):(0,g.l0)({projectedExtent:e,srcBufferExtent:h,pixelSize:B,datumTransformation:A,rasterTransform:d,hasWrapAround:r>0||z,isAdaptive:!1,includeGCSGrid:W}),O=!l.requestRawData,D={rows:L.spacing[0],cols:L.spacing[1]},E=this._hasNoneOrGCSShiftTransform?this._getRasterTileAlignmentInfo(o,h.xmin):void 0,{pixelBlocks:N,mosaicSize:F,isPartiallyFilled:q}=y,G=null;if(this.rasterJobHandler){let e=await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:N,srcMosaicSize:F,destDimension:O?{width:t,height:i}:null,coefs:O?L.coefficients:null,sampleSpacing:O?D:null,projectDirections:W,gcsGrid:W?L.gcsGrid:null,isUV:"vector-uv"===this.rasterInfo.dataType,interpolation:l.interpolation,alignmentInfo:E,blockWidths:null},l);({pixelBlock:H,localNorthDirections:G}=e)}else{let e=(0,C.z7)(N,F,{alignmentInfo:E});H=O?(0,C.$i)(e,{width:t,height:i},L.coefficients,D,l.interpolation):e,W&&L.gcsGrid&&(G=(0,C.QF)({width:t,height:i},L.gcsGrid),H=(0,T.Y2)(H,this.rasterInfo.dataType,G))}return l.requestRawData||W?{extent:e,srcExtent:h,srcTilePixelSize:v,pixelBlock:H,transformGrid:L,localNorthDirections:G,isPartiallyFilled:q}:{extent:e,srcExtent:e,srcTilePixelSize:v,pixelBlock:H}}async _fetchRawTiles(e,t,i,l){let{origin:r,blockBoundary:n}=this.rasterInfo.storageInfo,{blockWidth:o,blockHeight:s}=this.getBlockWidthHeight(e),{x:a,y:u}=t,{width:c,height:h,wrapCount:m}=i,d=this._getRasterTileAlignmentInfo(e,0);l.buffer&&(a-=l.buffer.cols,u-=l.buffer.rows,c+=2*l.buffer.cols,h+=2*l.buffer.rows);let p=0,x=0,g=0;m&&null!=d&&(({worldColumnCountFromOrigin:x,originColumnOffset:g,rightPadding:p}=d),x*d.blockWidth-p>=a+c&&(p=0));let y=Math.floor(a/o),I=Math.floor(u/s),w=Math.floor((a+c+p-1)/o),R=Math.floor((u+h+p-1)/s),k=n[e];if(!k)return null;let{minRow:_,minCol:b,maxCol:v,maxRow:S}=k;if(0===m&&(R<_||w<b||I>S||y>v))return null;let C=[],T=!1,B=null==this.ioConfig.allowPartialFill?l.allowPartialFill:this.ioConfig.allowPartialFill;for(let t=I;t<=R;t++)for(let i=y;i<=w;i++){let r=i;if(!l.disableWrapAround&&m&&null!=d&&x<=i&&(r=i-x-g),t>=_&&r>=b&&S>=t&&v>=r){let i=this._fetchRawTile(e,t,r,l);B?C.push(new Promise(e=>{i.then(t=>e(t)).catch(()=>{T=!0,e(null)})})):C.push(i)}else C.push(Promise.resolve(null))}if(0===C.length)return null;let M=await Promise.all(C),P={height:(R-I+1)*s,width:(w-y+1)*o},{spatialReference:A}=this.rasterInfo,{x:z,y:W}=this.getPyramidPixelSize(e);return{extent:new f.A({xmin:r.x+y*o*z,xmax:r.x+(w+1)*o*z,ymin:r.y-(R+1)*s*W,ymax:r.y-I*s*W,spatialReference:A}),pixelBlocks:M,mosaicSize:P,isPartiallyFilled:T}}_fetchRawTile(e,t,i,l){let{storageInfo:r}=this.rasterInfo,n=null!=r.transposeInfo&&!!l.transposedVariableName;if(!n){let l=r.blockBoundary[e];if(!l)return Promise.resolve(null);let{minRow:n,minCol:o,maxCol:s,maxRow:a}=l;if(t<n||i<o||t>a||i>s)return Promise.resolve(null)}let o=n?l.transposeVariableName:l.sliceId,s=r.isBsqTile?l.bandIds:null,u=function(e,t,i){let l=[];return null!=t&&l.push(`sliceId=${t}`),null!=i&&l.push(`bandIds=${i.join(",")}`),l.length?`${e}?${l.join("&")}`:e}(this.rasterId,o,s),c=`${e}/${t}/${i}`,h=R(u,l.registryId,c);if(null==h){let n=new AbortController,o=l.bandIds?.slice();if(o?.length&&r.isBsqTile){let r=new Set(o),s=[],a=Array.from(r);for(let r of a)s.push(this._tileFetchQueue.push({pyramidLevel:e,row:t,col:i,options:{...l,bandIds:[r]}},{signal:n.signal}));h=Promise.all(s).then(e=>{if(e.some(e=>null==e))return null;if(a.length!==o.length){let t=[];for(let i of o){let l=e[a.indexOf(i)];t.includes(l)&&(l=l.clone()),t.push(l)}e=t}return this.rasterJobHandler?this.rasterJobHandler.compositeBands({pixelBlocks:e},{signal:n.signal,transferPixelsToWorker:!0}):(0,C.Wy)(e)})}else h=this._tileFetchQueue.push({pyramidLevel:e,row:t,col:i,options:l},{signal:n.signal});k(u,l.registryId,c,h,n),h.catch(()=>_(u,l.registryId,c))}return l.signal&&(0,a.u7)(l,()=>{w(u,l.registryId,c)}),h}_computeMagDirValues(e){let{bandCount:t,dataType:i}=this.rasterInfo;if((2!==t||"vector-magdir"!==i)&&"vector-uv"!==i||2!==e?.length||!e[0]?.length)return null;let l=e[0].length;if("vector-magdir"===i){let t=e[1].map(e=>(e+360)%360);return[e[0],t]}let[r,n]=e,o=[],s=[];for(let e=0;e<l;e++){let[t,i]=(0,T.Lu)([r[e],n[e]]);o.push(t),s.push(i)}return[o,s]}_getRasterTileAlignmentInfo(e,t){return this._rasterTileAlignmentInfo??=(0,g.DO)(this.rasterInfo),null==this._rasterTileAlignmentInfo.pyramidsInfo?null:{startX:t,halfWorldWidth:this._rasterTileAlignmentInfo.halfWorldWidth,hasGCSSShiftTransform:this._rasterTileAlignmentInfo.hasGCSSShiftTransform,...this._rasterTileAlignmentInfo.pyramidsInfo[e]}}_getSourceDataInfo(e,t,i,l={}){let r={datumTransformation:l.datumTransformation,pyramidLevel:0,pyramidResolution:null,srcExtent:null,srcHeight:0,srcResolution:null,srcWidth:0,ul:{x:0,y:0}};l.srcResolution&&(r.srcResolution=l.srcResolution,this._updateSourceDataInfo(e,r));let n=this.rasterInfo.storageInfo.maximumPyramidLevel||0,{srcWidth:o,srcHeight:s,pyramidLevel:a}=r,u=o/t,c=s/i,h=a<n&&u*c>=16,f=a===n&&this._requireTooManySrcTiles(o,s,t,i);if(h||f||0===o||0===s){let o=new m.A({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/i,spatialReference:e.spatialReference}),s=(0,g.Wo)(o,this.rasterInfo.spatialReference,e,r.datumTransformation),f=!s||l.srcResolution&&s.x+s.y<l.srcResolution.x+l.srcResolution.y;if(h&&l.srcResolution&&f){let e=Math.round(Math.log(Math.max(u,c))/Math.LN2)-1;if(n-a+3>=e){let t=2**e;s={x:l.srcResolution.x*t,y:l.srcResolution.y*t}}}s&&(r.srcResolution=s,this._updateSourceDataInfo(e,r))}return this._requireTooManySrcTiles(r.srcWidth,r.srcHeight,t,i)&&(r.srcWidth=0,r.srcHeight=0),r}_requireTooManySrcTiles(e,t,i,l){let{tileInfo:r}=this.rasterInfo.storageInfo,n=e/i,o=t/l;return Math.ceil(e/r.size[0])*Math.ceil(t/r.size[1])>=256*Math.max(1,(i+l)/1024)||n>8||o>8}_updateSourceDataInfo(e,t){t.srcWidth=0,t.srcHeight=0;let{rasterInfo:i}=this,l=i.spatialReference,{srcResolution:r,datumTransformation:n}=t,{pyramidLevel:o,pyramidResolution:s,excessiveReading:a}=(0,g.t$)(r,i,this.ioConfig.sampling);if(a)return;let u=t.srcExtent||(0,g._l)(e,l,n);if(null==u)return;let c=i.transform;c&&(u=c.inverseTransform(u)),t.srcExtent=u;let{origin:h}=i.storageInfo,{width:f,height:m,ul:d}=(0,p.$g)(u,h,s,o);t.pyramidLevel=o,t.pyramidResolution=s,t.srcWidth=f,t.srcHeight=m,t.ul=d}_getRequestOptionsWithSliceId(e){return null!=this.rasterInfo.multidimensionalInfo&&null==e.sliceId&&(e={...e,sliceId:this.getSliceIndex(e.multidimensionalDefinition)}),e}_processIdentifyResult(e,t){let{srcLocation:i,position:l,pyramidLevel:r,useTransposedTile:n}=t,o=e.pixels[0].length/e.width/e.height;if(e.mask&&!e.mask[l])return{location:i,value:null};let{multidimensionalInfo:s}=this.rasterInfo;if(null==s||!n){let t=e.pixels.map(e=>e[l]),n={location:i,value:t,pyramidLevel:r},o=this._computeMagDirValues(t.map(e=>[e]));return o?.length&&(n.magdirValue=o.map(e=>e[0])),n}let a=e.pixels.map(e=>e.slice(l*o,l*o+o)),u=this._computeMagDirValues(a),{requestSomeSlices:c,identifyOptions:h}=t,f=(0,x.QW)(s,h.transposedVariableName);if(c){let e=(0,x.xx)(f,h.multidimensionalDefinition,h.timeExtent);a=a.map(t=>e.map(e=>t[e])),u=u?.map(t=>e.map(e=>t[e])),f=e.map(e=>f[e])}let m,d=e.noDataValues||this.rasterInfo.noDataValue,p={pixels:a,pixelType:e.pixelType};return null!=d&&((0,b.Sp)(p,d),m=p.mask),{location:i,value:null,dataSeries:f.map((e,t)=>{let i={value:0===m?.[t]?null:a.map(e=>e[t]),multidimensionalDefinition:e.multidimensionalDefinition.map(e=>new P.A({...e,isSlice:!0}))};return u?.length&&(i.magdirValue=[u[0][t],u[1][t]]),i}),pyramidLevel:r}}};(0,l.Cg)([(0,c.MZ)()],L.prototype,"_rasterTileAlignmentInfo",void 0),(0,l.Cg)([(0,c.MZ)()],L.prototype,"_tileFetchQueue",void 0),(0,l.Cg)([(0,c.MZ)({readOnly:!0})],L.prototype,"_isGlobalWrappableSource",null),(0,l.Cg)([(0,c.MZ)({readOnly:!0})],L.prototype,"_hasNoneOrGCSShiftTransform",null),(0,l.Cg)([(0,c.MZ)()],L.prototype,"_openPromise",void 0),(0,l.Cg)([(0,c.MZ)()],L.prototype,"rasterJobHandler",null),(0,l.Cg)([(0,c.MZ)({readOnly:!0})],L.prototype,"rasterId",null),(0,l.Cg)([(0,c.MZ)(M.OZ)],L.prototype,"url",null),(0,l.Cg)([(0,c.MZ)({type:String,json:{write:!0}})],L.prototype,"datasetName",void 0),(0,l.Cg)([(0,c.MZ)({type:String,json:{write:!0}})],L.prototype,"datasetFormat",void 0),(0,l.Cg)([(0,c.MZ)()],L.prototype,"hasUniqueSourceStorageInfo",void 0),(0,l.Cg)([(0,c.MZ)()],L.prototype,"rasterInfo",void 0),(0,l.Cg)([(0,c.MZ)()],L.prototype,"ioConfig",void 0),(0,l.Cg)([(0,c.MZ)()],L.prototype,"sourceJSON",void 0),(0,l.Cg)([(0,c.MZ)()],L.prototype,"rawBlockRegistryIds",void 0),L=(0,l.Cg)([(0,c.$K)("esri.layers.raster.datasets.BaseRaster")],L)},330(e,t,i){function l(e,t){if(!e||!t)return[];let i=t;t.includes("/")?(i=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";let r=[];if(t){let n=l(e,i);for(let e=0;e<n.length;e++)l(n[e],t).forEach(e=>r.push(e));return r}let n=e.getElementsByTagNameNS("*",i);if(!n||0===n.length)return[];for(let e=0;e<n.length;e++)r.push(n[e]||n.item(e));return r}function r(e,t){if(!e||!t)return null;let i=t;t.includes("/")?(i=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";let n=l(e,i);return n.length>0?t?r(n[0],t):n[0]:null}function n(e,t=null){let i,l=t?r(e,t):e;return l?(i=l.textContent||l.nodeValue,i?i.trim():null):null}function o(e,t){let i,r=l(e,t),n=[];for(let e=0;e<r.length;e++)i=r[e].textContent||r[e].nodeValue,i&&(i=i.trim(),""!==i&&n.push(i));return n}function s(e,t=null){return n(e,t)?.split(" ").map(e=>Number(e))??[]}function a(e,t){return o(e,t).map(e=>Number(e))}function u(e,t){let i=n(e,t);return Number(i)}function c(e,t){let i=e?.nodeName?.toLowerCase(),l=t.toLowerCase();return i.slice(i.lastIndexOf(":")+1)===l}function h(e){return e.nodeName.slice(e.nodeName.lastIndexOf(":")+1)}i.d(t,{Dy:()=>o,IC:()=>l,Ui:()=>a,V6:()=>r,g7:()=>c,mX:()=>n,pN:()=>s,v7:()=>u,vv:()=>h})}}]);