@arcgis/core 6.0.0-next.28 → 6.0.0-next.29

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 (321) hide show
  1. package/arcgisGlobal.d.ts +0 -2
  2. package/assets/esri/core/workers/RemoteClient.js +1 -1
  3. package/assets/esri/core/workers/chunks/131185d26343a997495e.js +1 -0
  4. package/assets/esri/core/workers/chunks/{dbda982485d3fe26c729.js → 13c64087be3b2985a21b.js} +1 -1
  5. package/assets/esri/core/workers/chunks/144bad0c2415c345736a.js +1 -0
  6. package/assets/esri/core/workers/chunks/176d0a06ebff5a29dedf.js +1 -0
  7. package/assets/esri/core/workers/chunks/{b0ca81a07cff25df19d2.js → 176d75e76318bfc25a53.js} +1 -1
  8. package/assets/esri/core/workers/chunks/18776a130d96879a68b1.js +1 -0
  9. package/assets/esri/core/workers/chunks/{e35641a3a4da8cfbcf54.js → 189321d88026bd7e6d3e.js} +1 -1
  10. package/assets/esri/core/workers/chunks/18e7fa4d3e0b1a084cc6.js +1 -0
  11. package/assets/esri/core/workers/chunks/{1168bc5c9f0a7e1f63a2.js → 1989410a618865f02dec.js} +1 -1
  12. package/assets/esri/core/workers/chunks/{2c0cb214fedb29487eef.js → 199a7f97916679e0257c.js} +1 -1
  13. package/assets/esri/core/workers/chunks/1c406ab2bf99ac563316.js +1 -0
  14. package/assets/esri/core/workers/chunks/1d96fbad881a7d14a950.js +1 -0
  15. package/assets/esri/core/workers/chunks/{42d44c7d532df5ee70e9.js → 1deca3de77b1a9a07da4.js} +1 -1
  16. package/assets/esri/core/workers/chunks/{45f826554499c38968c6.js → 1ee4df0fd61440cb5f02.js} +1 -1
  17. package/assets/esri/core/workers/chunks/22e73501e1435a896826.js +1 -0
  18. package/assets/esri/core/workers/chunks/25657f70c5f04a4ed978.js +1 -0
  19. package/assets/esri/core/workers/chunks/276a0b549acf048e8673.js +1 -0
  20. package/assets/esri/core/workers/chunks/{56e903ccef66cbe18f92.js → 2cd60fd062d954322c1f.js} +1 -1
  21. package/assets/esri/core/workers/chunks/{ad96132bc89671e595f3.js → 2d3e0e4442dbc6ec6def.js} +1 -1
  22. package/assets/esri/core/workers/chunks/2de4296590bf9f9e9add.js +1 -0
  23. package/assets/esri/core/workers/chunks/2f5d014d6a72108b0b3a.js +1 -0
  24. package/assets/esri/core/workers/chunks/{0363d29fc665d169ebc4.js → 3105336a05f38a95ebea.js} +1 -1
  25. package/assets/esri/core/workers/chunks/379ef56f6b32494832a6.js +1 -0
  26. package/assets/esri/core/workers/chunks/3aafdb905c697bc9b1ad.js +1 -0
  27. package/assets/esri/core/workers/chunks/40c2674dae73f0942751.js +1 -0
  28. package/assets/esri/core/workers/chunks/418addce122dbb8897b4.js +1 -0
  29. package/assets/esri/core/workers/chunks/4419732baf3459a80e6d.js +1 -0
  30. package/assets/esri/core/workers/chunks/4976f5567fc7f1b63d10.js +1 -0
  31. package/assets/esri/core/workers/chunks/4e17665dd9048c300d87.js +1 -0
  32. package/assets/esri/core/workers/chunks/5396b6e99a0546a25d19.js +1 -0
  33. package/assets/esri/core/workers/chunks/53c7510df09b71ab5646.js +1 -0
  34. package/assets/esri/core/workers/chunks/561c48cb4d49b150765b.js +1 -0
  35. package/assets/esri/core/workers/chunks/{d90a3bfd45b5ed4092e0.js → 590fe0f56bc4c33a50e7.js} +1 -1
  36. package/assets/esri/core/workers/chunks/5bb6c255bdc8aa9ba23e.js +1 -0
  37. package/assets/esri/core/workers/chunks/5f1cb79aec9c4a9b7ddc.js +29 -0
  38. package/assets/esri/core/workers/chunks/{23a4806b4cdf7cc32e4d.js → 5f787809b74eed7b9a91.js} +1 -1
  39. package/assets/esri/core/workers/chunks/636e9c4ac1f9ae98f9d1.js +1 -0
  40. package/assets/esri/core/workers/chunks/654f5441227579d2b6b4.js +1 -0
  41. package/assets/esri/core/workers/chunks/692f0093c444fcc752b5.js +1 -0
  42. package/assets/esri/core/workers/chunks/69627b2634da64dd885f.js +1 -0
  43. package/assets/esri/core/workers/chunks/6a7de221cea4426cb490.js +1 -0
  44. package/assets/esri/core/workers/chunks/7030a4d0714a35995a58.js +1 -0
  45. package/assets/esri/core/workers/chunks/72d20d3957d612f86431.js +1 -0
  46. package/assets/esri/core/workers/chunks/7862abd24fb5c3b12e6b.js +1 -0
  47. package/assets/esri/core/workers/chunks/7a0b4dc0cda190367a39.js +1 -0
  48. package/assets/esri/core/workers/chunks/{5eec1c1162779574f46e.js → 7c75a8ee266c36baa902.js} +1 -1
  49. package/assets/esri/core/workers/chunks/{ab1660f5f8a5268c2fac.js → 84038dd85005fea413eb.js} +1 -1
  50. package/assets/esri/core/workers/chunks/849f446c718e892f39ce.js +1 -0
  51. package/assets/esri/core/workers/chunks/{8ac2098ecdc40ad41055.js → 8502274806ea52308822.js} +1 -1
  52. package/assets/esri/core/workers/chunks/865cebc5c982c040ab6f.js +1 -0
  53. package/assets/esri/core/workers/chunks/{76196c414e48834f7b92.js → 8f008eedb11685ee2048.js} +1 -1
  54. package/assets/esri/core/workers/chunks/90d797ab82d4a68ba32f.js +1 -0
  55. package/assets/esri/core/workers/chunks/9184c947cdefe06bf551.js +1 -0
  56. package/assets/esri/core/workers/chunks/9976eaa81085c0d17e14.js +1 -0
  57. package/assets/esri/core/workers/chunks/{177f353ce72133e2eeed.js → 9c2436464b7dfd666678.js} +1 -1
  58. package/assets/esri/core/workers/chunks/a125650edbed802e419a.js +1 -0
  59. package/assets/esri/core/workers/chunks/{23fd4de56de352f63e2d.js → a2196a49f89d57a0a1c7.js} +1 -1
  60. package/assets/esri/core/workers/chunks/ad21757d78e372fa2ed6.js +1 -0
  61. package/assets/esri/core/workers/chunks/b01688ccc29d33bfc82d.js +1 -0
  62. package/assets/esri/core/workers/chunks/b5eff28cf482d920b9ea.js +1 -0
  63. package/assets/esri/core/workers/chunks/{04ecf15524ff3838c01c.js → ba4520ddcb6a49988da6.js} +1 -1
  64. package/assets/esri/core/workers/chunks/be55771758e4bcef0976.js +1 -0
  65. package/assets/esri/core/workers/chunks/bead830a677690eeb6fb.js +1 -0
  66. package/assets/esri/core/workers/chunks/c131e0dd180a4c10e12e.js +1 -0
  67. package/assets/esri/core/workers/chunks/c1cf3edce15f09648eb4.js +1 -0
  68. package/assets/esri/core/workers/chunks/c4f78a481f43cfae7b63.js +1 -0
  69. package/assets/esri/core/workers/chunks/c570b90995c65bbb2e14.js +1 -0
  70. package/assets/esri/core/workers/chunks/c576bef77e34920af188.js +1 -0
  71. package/assets/esri/core/workers/chunks/c9feffb9884cfed52c4b.js +1 -0
  72. package/assets/esri/core/workers/chunks/cc97e4fd0dacad970a23.js +1 -0
  73. package/assets/esri/core/workers/chunks/ce324dde6d7daea33638.js +1 -0
  74. package/assets/esri/core/workers/chunks/d1d6154b4af1c9cc497b.js +1 -0
  75. package/assets/esri/core/workers/chunks/d3c3fb079ad97970f834.js +1 -0
  76. package/assets/esri/core/workers/chunks/daae21cf77864f3293ef.js +1 -0
  77. package/assets/esri/core/workers/chunks/dc2f93453dfa40f623ab.js +1 -0
  78. package/assets/esri/core/workers/chunks/dcf6024dc19428ff2b9d.js +1 -0
  79. package/assets/esri/core/workers/chunks/dd30b02c5978c1c5f511.js +1 -0
  80. package/assets/esri/core/workers/chunks/de3f140058aa0b907b65.js +1 -0
  81. package/assets/esri/core/workers/chunks/df375d1b0dab5ecbd1be.js +1 -0
  82. package/assets/esri/core/workers/chunks/{ef2c3febcceedc44b3ac.js → dfd4782b11d6fdca0492.js} +1 -1
  83. package/assets/esri/core/workers/chunks/{48cc58890fddbcf69cef.js → e121d15b883184ee83e7.js} +1 -1
  84. package/assets/esri/core/workers/chunks/{67e06d606c7fd2064adf.js → e2c6cd8dac01e129ccfe.js} +1 -1
  85. package/assets/esri/core/workers/chunks/e3b212f8af448ec29eef.js +1 -0
  86. package/assets/esri/core/workers/chunks/e4042e43f0081fe49f7b.js +1 -0
  87. package/assets/esri/core/workers/chunks/e480e7d5f40049a2053b.js +1 -0
  88. package/assets/esri/core/workers/chunks/eaab787a5f2445be5e5a.js +1 -0
  89. package/assets/esri/core/workers/chunks/edd36a1fc80b1d29907e.js +1 -0
  90. package/assets/esri/core/workers/chunks/ee0dc906cc7979080329.js +1 -0
  91. package/assets/esri/core/workers/chunks/f07fb9b3fa30d7ee1681.js +1 -0
  92. package/assets/esri/core/workers/chunks/f09bc86cd52224febfcb.js +1 -0
  93. package/assets/esri/core/workers/chunks/{037c67ef5c4398d5954d.js → f2dab9fcd90ce38ae3d1.js} +1 -1
  94. package/assets/esri/core/workers/chunks/f39c700f3db7db52b522.js +1 -0
  95. package/assets/esri/core/workers/chunks/f3b4159c0722df8ffe13.js +1 -0
  96. package/assets/esri/core/workers/chunks/f3dc0bc0e00635855a7a.js +1 -0
  97. package/assets/esri/core/workers/chunks/f45064066e1ab041a0b2.js +1 -0
  98. package/assets/esri/core/workers/chunks/{dc7aa0a1eb6c6e361f9f.js → f7398cfd8bbd041bd635.js} +1 -1
  99. package/assets/esri/core/workers/chunks/f9dc38761b314d33890f.js +1 -0
  100. package/assets/esri/core/workers/chunks/fe6dcb21570395e46ce8.js +1 -0
  101. package/assets/esri/core/workers/chunks/{9c4961213ac6ec283dd9.js → fefdd10bdd5a4c8d8ed0.js} +44 -47
  102. package/assets/esri/core/workers/chunks/ffe49d9e7df081bef4a5.js +1 -0
  103. package/assets/esri/themes/base/_core.scss +0 -2
  104. package/assets/esri/themes/dark/main.css +1 -1
  105. package/assets/esri/themes/light/main.css +1 -1
  106. package/assets/esri/themes/light/view.css +1 -1
  107. package/chunks/Component.glsl.js +48 -48
  108. package/chunks/EmissionComposite.glsl.js +1 -1
  109. package/chunks/Fog.glsl.js +1 -1
  110. package/chunks/GaussianSplatDepth.glsl.js +15 -7
  111. package/chunks/GaussianSplatShadow.glsl.js +14 -4
  112. package/config.d.ts +12 -9
  113. package/config.js +1 -1
  114. package/form/FormTemplate.d.ts +1 -1
  115. package/form/elements/AttachmentElement.d.ts +2 -0
  116. package/form/elements/FieldElement.d.ts +2 -2
  117. package/form/elements/FieldElement.js +1 -1
  118. package/form/elements/RelationshipElement.d.ts +1 -1
  119. package/form/elements/TextElement.d.ts +2 -2
  120. package/form/elements/UtilityNetworkAssociationsElement.d.ts +1 -1
  121. package/form/elements/inputs/inputUtils.js +1 -1
  122. package/form/elements/inputs/types.d.ts +19 -0
  123. package/form/elements/inputs.d.ts +3 -2
  124. package/form/elements/inputs.js +1 -1
  125. package/interfaces.d.ts +0 -14
  126. package/kernel.js +1 -1
  127. package/layers/VideoLayer.d.ts +5 -5
  128. package/layers/knowledgeGraph/KnowledgeGraphSublayer.js +1 -1
  129. package/layers/orientedImagery/core/coverageUtils.js +1 -1
  130. package/layers/orientedImagery/transformations/rotationUtils.js +2 -0
  131. package/layers/orientedImagery/transformations/utils.js +1 -1
  132. package/layers/save/parquetLayerUtils.js +1 -1
  133. package/layers/support/vectorTileLayerLoader.js +1 -1
  134. package/package.json +2 -2
  135. package/smartMapping/support/adapters/support/histogramUtils.js +1 -1
  136. package/views/2d/engine/vectorTiles/TileHandler.js +1 -1
  137. package/views/2d/engine/vectorTiles/style/GeoJSONVectorTileSource.js +1 -1
  138. package/views/2d/engine/vectorTiles/style/GeoJSONVectorTileSourceWorker.js +1 -1
  139. package/views/2d/engine/vectorTiles/style/geoJSONVectorTileUtils.js +2 -0
  140. package/views/2d/engine/webgl/collisions/LabelMetric.js +1 -1
  141. package/views/2d/engine/webgl/collisions/LabelStore.js +1 -1
  142. package/views/2d/layers/VectorTileLayerView2D.js +1 -1
  143. package/views/2d/layers/features/FeatureContainer.js +1 -1
  144. package/views/2d/layers/support/visualVariableSimpleUtils.js +1 -1
  145. package/views/3d/state/controllers/PointToPointAnimationController.js +1 -1
  146. package/views/3d/support/ResourceController.js +1 -1
  147. package/views/3d/terrain/TerrainRenderer.js +1 -1
  148. package/views/3d/terrain/TerrainSurface.js +1 -1
  149. package/views/3d/terrain/TileAgent.js +1 -1
  150. package/views/3d/webgl-engine/Stage.js +1 -1
  151. package/views/3d/webgl-engine/collections/Component/Material/Component.glsl.js +1 -1
  152. package/views/3d/webgl-engine/core/shaderLibrary/attributes/RibbonVertexPosition.glsl.js +23 -26
  153. package/views/3d/webgl-engine/core/shaderLibrary/attributes/VertexPosition.glsl.js +18 -21
  154. package/views/3d/webgl-engine/core/shaderLibrary/attributes/VerticalOffset.glsl.js +5 -5
  155. package/views/3d/webgl-engine/core/shaderLibrary/shading/ComputeFragmentNormals.glsl.js +10 -12
  156. package/views/3d/webgl-engine/core/shaderLibrary/shading/EvaluateSceneLighting.glsl.js +22 -25
  157. package/views/3d/webgl-engine/effects/RenderPluginContext.js +2 -0
  158. package/views/3d/webgl-engine/effects/fog/Fog.js +1 -1
  159. package/views/3d/webgl-engine/effects/globalIllumination/GlobalIllumination.js +1 -1
  160. package/views/3d/webgl-engine/effects/glow/applyEmissiveGlow.glsl.js +3 -3
  161. package/views/3d/webgl-engine/effects/highlight/Highlight.js +1 -1
  162. package/views/3d/webgl-engine/lib/GaussianSplatDepthRenderer.js +1 -1
  163. package/views/3d/webgl-engine/lib/GaussianSplatRenderer.js +1 -1
  164. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  165. package/views/3d/webgl-engine/lib/edgeRendering/EdgeUtil.glsl.js +30 -35
  166. package/views/3d/webgl-engine/parts/RenderView.js +1 -1
  167. package/views/3d/webgl-engine/shaders/EmissiveTechniqueConfiguration.js +1 -1
  168. package/views/3d/webgl-engine/shaders/GaussianSplatPass.glsl.js +62 -53
  169. package/views/3d/webgl-engine/shaders/GaussianSplatTechniqueConfiguration.js +1 -1
  170. package/views/VideoView.d.ts +10 -0
  171. package/views/VideoView.js +1 -1
  172. package/views/layers/LayerView.d.ts +10 -2
  173. package/widgets/BatchAttributeForm/inputs/FieldInput.d.ts +2 -2
  174. package/widgets/Editor/EditorViewModel.d.ts +10 -12
  175. package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
  176. package/widgets/FeatureTable/support/EditableColumnTemplateMixin.js +1 -1
  177. package/widgets/OrientedImageryViewer/ImageMeasurementWorker.js +1 -1
  178. package/widgets/OrientedImageryViewer/adapters/sketch/MeasurementAdapter.js +1 -1
  179. package/widgets/OrientedImageryViewer/adapters/view/SceneViewAdapter.js +1 -1
  180. package/widgets/OrientedImageryViewer/imageMeasurementUtils.js +1 -1
  181. package/widgets/OrientedImageryViewer/imageMeasurementWorkerUtils.js +2 -0
  182. package/widgets/OrientedImageryViewer/services/ImageMeasurementService.js +1 -1
  183. package/widgets/OrientedImageryViewer/support/superimposeUtils.js +1 -1
  184. package/widgets/support/iconUtils.js +1 -1
  185. package/assets/esri/core/workers/chunks/010f57ec7fdbedf78d02.js +0 -1
  186. package/assets/esri/core/workers/chunks/03f33cb78b5405ab7e23.js +0 -1
  187. package/assets/esri/core/workers/chunks/0487e1d7a7cecf7c1c25.js +0 -1
  188. package/assets/esri/core/workers/chunks/09300e74e5b014ce6269.js +0 -1
  189. package/assets/esri/core/workers/chunks/0d9c4c6c571ce26d356b.js +0 -1
  190. package/assets/esri/core/workers/chunks/112ed86f812e4400a7e0.js +0 -1
  191. package/assets/esri/core/workers/chunks/151e5799ede763a03ee2.js +0 -1
  192. package/assets/esri/core/workers/chunks/173f89c55a5c79ff065b.js +0 -1
  193. package/assets/esri/core/workers/chunks/2447d2e2a4a3ab8fcf94.js +0 -1
  194. package/assets/esri/core/workers/chunks/2a36fe3f3f257a779a1b.js +0 -1
  195. package/assets/esri/core/workers/chunks/2a97268000c6d03ef720.js +0 -1
  196. package/assets/esri/core/workers/chunks/2cf8172be83b10b11bdc.js +0 -1
  197. package/assets/esri/core/workers/chunks/2df37a9a95ceebb87a5f.js +0 -1
  198. package/assets/esri/core/workers/chunks/2e00c155e447e4930442.js +0 -1
  199. package/assets/esri/core/workers/chunks/2f91fd61019d2a37476d.js +0 -1
  200. package/assets/esri/core/workers/chunks/30af63b3b750142faadb.js +0 -1
  201. package/assets/esri/core/workers/chunks/3a47fc97c400fca2c736.js +0 -1
  202. package/assets/esri/core/workers/chunks/3cd04d23b73beaf79650.js +0 -1
  203. package/assets/esri/core/workers/chunks/426b4eb500fdfe9df325.js +0 -1
  204. package/assets/esri/core/workers/chunks/45367aa8e5c5d574de94.js +0 -1
  205. package/assets/esri/core/workers/chunks/47c97640ec525676918b.js +0 -1
  206. package/assets/esri/core/workers/chunks/47d074136a7f8e551a9a.js +0 -1
  207. package/assets/esri/core/workers/chunks/4a6b92ecbb1f1c55cc43.js +0 -1
  208. package/assets/esri/core/workers/chunks/4cb751dc8d00bdaeb04c.js +0 -1
  209. package/assets/esri/core/workers/chunks/518ab22f80c3300bcfff.js +0 -1
  210. package/assets/esri/core/workers/chunks/53ff68d4f9e365fc15cd.js +0 -1
  211. package/assets/esri/core/workers/chunks/58609bf94f72bc4f1952.js +0 -1
  212. package/assets/esri/core/workers/chunks/586a929bc037e23857af.js +0 -1
  213. package/assets/esri/core/workers/chunks/5c7780f804d789cb37f5.js +0 -1
  214. package/assets/esri/core/workers/chunks/5d76f4d97beee494bbbf.js +0 -1
  215. package/assets/esri/core/workers/chunks/603fdbbe9534c614928f.js +0 -1
  216. package/assets/esri/core/workers/chunks/611e3cdf67283c11576f.js +0 -1
  217. package/assets/esri/core/workers/chunks/6431480ba0fa8c8d487f.js +0 -1
  218. package/assets/esri/core/workers/chunks/652faf4359ac072c5dde.js +0 -1
  219. package/assets/esri/core/workers/chunks/65c98f3449044fa4fd79.js +0 -1
  220. package/assets/esri/core/workers/chunks/6b9961261241fdce0e94.js +0 -1
  221. package/assets/esri/core/workers/chunks/6dfe96b056bec30068df.js +0 -1
  222. package/assets/esri/core/workers/chunks/6f897b4e7ddd1dd1672b.js +0 -1
  223. package/assets/esri/core/workers/chunks/70cc2d79653d66e85b58.js +0 -1
  224. package/assets/esri/core/workers/chunks/7159d9c36869cd82599e.js +0 -29
  225. package/assets/esri/core/workers/chunks/7393f63043a1da3d05a6.js +0 -1
  226. package/assets/esri/core/workers/chunks/7449568eb2305bf2d650.js +0 -1
  227. package/assets/esri/core/workers/chunks/75d551a449bba61ce238.js +0 -1
  228. package/assets/esri/core/workers/chunks/76e27e36050a3dd9d249.js +0 -1
  229. package/assets/esri/core/workers/chunks/76f877e2d2493d56afab.js +0 -1
  230. package/assets/esri/core/workers/chunks/7748c2886d0122b40eeb.js +0 -1
  231. package/assets/esri/core/workers/chunks/78643f116677950ea29a.js +0 -1
  232. package/assets/esri/core/workers/chunks/78fbe330f16bdbdb886e.js +0 -1
  233. package/assets/esri/core/workers/chunks/7e0f04a5038e2a4f6e4b.js +0 -1
  234. package/assets/esri/core/workers/chunks/7f16ae01ccd9b6114d1c.js +0 -1
  235. package/assets/esri/core/workers/chunks/90153b5230b3a4985c14.js +0 -1
  236. package/assets/esri/core/workers/chunks/9189dfe19a2a2ccd5173.js +0 -1
  237. package/assets/esri/core/workers/chunks/943a0f140813ee4ab04a.js +0 -1
  238. package/assets/esri/core/workers/chunks/98be2f621801e230aa01.js +0 -1
  239. package/assets/esri/core/workers/chunks/99f51d5d9da6e9bfc430.js +0 -1
  240. package/assets/esri/core/workers/chunks/9aebe876b1a2fb075f9c.js +0 -1
  241. package/assets/esri/core/workers/chunks/9b6929faf649e81265fb.js +0 -1
  242. package/assets/esri/core/workers/chunks/9dd48e75b4e8d9811d81.js +0 -1
  243. package/assets/esri/core/workers/chunks/a163c6005aba3378edaa.js +0 -1
  244. package/assets/esri/core/workers/chunks/a8286febe371dc186aaa.js +0 -1
  245. package/assets/esri/core/workers/chunks/acb265a22be5e12f38e5.js +0 -1
  246. package/assets/esri/core/workers/chunks/b12acf1f694f82e00df9.js +0 -1
  247. package/assets/esri/core/workers/chunks/b83cef2d3f528726d492.js +0 -1
  248. package/assets/esri/core/workers/chunks/b9596d862da1ec342cd3.js +0 -1
  249. package/assets/esri/core/workers/chunks/bc1fcc9c897461e68e29.js +0 -1
  250. package/assets/esri/core/workers/chunks/bdc221d94300c225665a.js +0 -1
  251. package/assets/esri/core/workers/chunks/be97a629e2ae4d13ceb3.js +0 -1
  252. package/assets/esri/core/workers/chunks/bfb39590c548188f5052.js +0 -1
  253. package/assets/esri/core/workers/chunks/c2318c014e97ba519be8.js +0 -1
  254. package/assets/esri/core/workers/chunks/c62237c344e341619341.js +0 -1
  255. package/assets/esri/core/workers/chunks/cdb5c26fed7d9a97db49.js +0 -1
  256. package/assets/esri/core/workers/chunks/cdf0c7706d3e1221f49b.js +0 -1
  257. package/assets/esri/core/workers/chunks/cea0db3ee326f60610eb.js +0 -1
  258. package/assets/esri/core/workers/chunks/d7f2f1708d2a2668676c.js +0 -1
  259. package/assets/esri/core/workers/chunks/daf9b691817e83a11f3c.js +0 -1
  260. package/assets/esri/core/workers/chunks/db41490bd39d863305bf.js +0 -1
  261. package/assets/esri/core/workers/chunks/ddc95cdac6c06fc4794c.js +0 -1
  262. package/assets/esri/core/workers/chunks/df26ec0b508cf4716e0a.js +0 -1
  263. package/assets/esri/core/workers/chunks/e11159e3dc3353b27c57.js +0 -1
  264. package/assets/esri/core/workers/chunks/e4a57a0a9629faafd6c6.js +0 -1
  265. package/assets/esri/core/workers/chunks/ebc1a2ef3aed8aa29424.js +0 -1
  266. package/assets/esri/core/workers/chunks/ec1c4d66142b6efb0e8b.js +0 -1
  267. package/assets/esri/core/workers/chunks/ef12fa3574d4cbf8b084.js +0 -1
  268. package/assets/esri/core/workers/chunks/f2d56f5c15d5977e1d19.js +0 -1
  269. package/assets/esri/core/workers/chunks/f7bfa3d33b05b250ce33.js +0 -1
  270. package/assets/esri/core/workers/chunks/f905f1a1aa4c123cbe83.js +0 -1
  271. package/assets/esri/core/workers/chunks/fc139f251dc0523074e7.js +0 -1
  272. package/assets/esri/themes/base/widgets/_VideoPlayer.scss +0 -129
  273. package/assets/esri/widgets/VideoPlayer/t9n/messages.ar.json +0 -1
  274. package/assets/esri/widgets/VideoPlayer/t9n/messages.bg.json +0 -1
  275. package/assets/esri/widgets/VideoPlayer/t9n/messages.bs.json +0 -1
  276. package/assets/esri/widgets/VideoPlayer/t9n/messages.ca.json +0 -1
  277. package/assets/esri/widgets/VideoPlayer/t9n/messages.cs.json +0 -1
  278. package/assets/esri/widgets/VideoPlayer/t9n/messages.da.json +0 -1
  279. package/assets/esri/widgets/VideoPlayer/t9n/messages.de.json +0 -1
  280. package/assets/esri/widgets/VideoPlayer/t9n/messages.el.json +0 -1
  281. package/assets/esri/widgets/VideoPlayer/t9n/messages.en.json +0 -1
  282. package/assets/esri/widgets/VideoPlayer/t9n/messages.es.json +0 -1
  283. package/assets/esri/widgets/VideoPlayer/t9n/messages.et.json +0 -1
  284. package/assets/esri/widgets/VideoPlayer/t9n/messages.fi.json +0 -1
  285. package/assets/esri/widgets/VideoPlayer/t9n/messages.fr.json +0 -1
  286. package/assets/esri/widgets/VideoPlayer/t9n/messages.he.json +0 -1
  287. package/assets/esri/widgets/VideoPlayer/t9n/messages.hr.json +0 -1
  288. package/assets/esri/widgets/VideoPlayer/t9n/messages.hu.json +0 -1
  289. package/assets/esri/widgets/VideoPlayer/t9n/messages.id.json +0 -1
  290. package/assets/esri/widgets/VideoPlayer/t9n/messages.it.json +0 -1
  291. package/assets/esri/widgets/VideoPlayer/t9n/messages.ja.json +0 -1
  292. package/assets/esri/widgets/VideoPlayer/t9n/messages.ko.json +0 -1
  293. package/assets/esri/widgets/VideoPlayer/t9n/messages.lt.json +0 -1
  294. package/assets/esri/widgets/VideoPlayer/t9n/messages.lv.json +0 -1
  295. package/assets/esri/widgets/VideoPlayer/t9n/messages.nl.json +0 -1
  296. package/assets/esri/widgets/VideoPlayer/t9n/messages.no.json +0 -1
  297. package/assets/esri/widgets/VideoPlayer/t9n/messages.pl.json +0 -1
  298. package/assets/esri/widgets/VideoPlayer/t9n/messages.pt-BR.json +0 -1
  299. package/assets/esri/widgets/VideoPlayer/t9n/messages.pt-PT.json +0 -1
  300. package/assets/esri/widgets/VideoPlayer/t9n/messages.ro.json +0 -1
  301. package/assets/esri/widgets/VideoPlayer/t9n/messages.ru.json +0 -1
  302. package/assets/esri/widgets/VideoPlayer/t9n/messages.sk.json +0 -1
  303. package/assets/esri/widgets/VideoPlayer/t9n/messages.sl.json +0 -1
  304. package/assets/esri/widgets/VideoPlayer/t9n/messages.sr.json +0 -1
  305. package/assets/esri/widgets/VideoPlayer/t9n/messages.sv.json +0 -1
  306. package/assets/esri/widgets/VideoPlayer/t9n/messages.th.json +0 -1
  307. package/assets/esri/widgets/VideoPlayer/t9n/messages.tr.json +0 -1
  308. package/assets/esri/widgets/VideoPlayer/t9n/messages.uk.json +0 -1
  309. package/assets/esri/widgets/VideoPlayer/t9n/messages.vi.json +0 -1
  310. package/assets/esri/widgets/VideoPlayer/t9n/messages.zh-CN.json +0 -1
  311. package/assets/esri/widgets/VideoPlayer/t9n/messages.zh-HK.json +0 -1
  312. package/assets/esri/widgets/VideoPlayer/t9n/messages.zh-TW.json +0 -1
  313. package/widgets/VideoPlayer/VideoPlayerViewModel.d.ts +0 -232
  314. package/widgets/VideoPlayer/VideoPlayerViewModel.js +0 -2
  315. package/widgets/VideoPlayer/components/MetadataSection.js +0 -2
  316. package/widgets/VideoPlayer/components/PlayerActionsGroup.js +0 -2
  317. package/widgets/VideoPlayer/components/PlayerControlsGroup.js +0 -2
  318. package/widgets/VideoPlayer/components/SettingsButton.js +0 -2
  319. package/widgets/VideoPlayer/css.js +0 -2
  320. package/widgets/VideoPlayer.d.ts +0 -119
  321. package/widgets/VideoPlayer.js +0 -2
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2958,5804,6553],{46130(e,t,r){r.d(t,{v:()=>o});var a=r(76553);function o(e){e?.writtenProperties&&e.writtenProperties.forEach(({target:e,propName:t,newOrigin:r})=>{(0,a.H)(e)&&r&&e.originOf(t)!==r&&e.updateOrigin(t,r)})}},76553(e,t,r){function a(e){return e&&"getAtOrigin"in e&&"originOf"in e}r.d(t,{H:()=>a})},13069(e,t,r){r.d(t,{AG:()=>i,lk:()=>o,vD:()=>n,yS:()=>s});const a="randomUUID"in crypto;function o(){if(a)return crypto.randomUUID();let e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;let t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function s(){return`{${o().toUpperCase()}}`}function n(){return`{${o()}}`}function i(e){let t=e.toUpperCase();return e.startsWith("{")?t:`{${t}}`}},32958(e,t,r){r.d(t,{save:()=>y,saveAs:()=>v});var a=r(71530),o=r(88788),s=r(10407),n=r(91682),i=r(26121);const l="Group Layer",u=s.mm.GROUP_LAYER_MAP;function c(e){return{isValid:"group"===e.type,errorMessage:"Layer.type should be 'group'"}}function p(e){return{isValid:(0,s.Y)(e,u),errorMessage:`Layer.portalItem.typeKeywords should have '${u}'`}}function m(e,t){return{...(0,o.m)(e,"web-map",{withResources:!0}),initiator:t}}function f(e){let t=e.layerJSON;return Promise.resolve(t&&Object.keys(t).length?t:null)}function d(e,t){(0,s.Sm)(t,s.mm.CHARTS,(0,i.I6)(e))}function h(e,t){d(e,t)}async function w(e,t){t.title||=e.title,(0,s.OM)(t,s.mm.METADATA),(0,s.LG)(t,u),d(e,t)}async function y(e,t){return(0,a.UN)({layer:e,itemType:l,validateLayer:c,validateItem:p,createJSONContext:t=>m(t,e),createItemData:f,errorNamePrefix:"group-layer-save",setItemProperties:h,saveResources:async(t,r)=>(e.sourceIsPortalItem||await t.removeAllResources().catch(()=>{}),(0,n.r)(e.resourceReferences,r))},t)}async function v(e,t,r){return(0,a.Uh)({layer:e,itemType:l,validateLayer:c,createJSONContext:t=>m(t,e),createItemData:f,errorNamePrefix:"group-layer-save-as",newItem:t,setItemProperties:w,saveResources:(t,r)=>(0,n.r)(e.resourceReferences,r)},r)}},71530(e,t,r){r.d(t,{UN:()=>v,Uh:()=>I});var a=r(49186),o=r(46130),s=r(20655),n=r(80812),i=r(88788),l=r(10407),u=r(26121);async function c(e){let{layer:t,errorNamePrefix:r,validateLayer:o}=e;await t.load(),function(e,t,r){let o=r(e);if(!o.isValid)throw new a.A(`${t}:invalid-parameters`,o.errorMessage,{layer:e})}(t,r,o)}function p(e,t){return`Layer (title: ${e.title}, id: ${e.id}) of type '${e.declaredClass}' ${t}`}function m(e){let{item:t,errorNamePrefix:r,layer:o,validateItem:s}=e;if(function(e){let{item:t,itemType:r,additionalItemType:o,errorNamePrefix:s,layer:n}=e,i=[r];if(o&&i.push(o),!i.includes(t.type)){let e=i.map(e=>`'${e}'`).join(", ");throw new a.A(`${s}:portal-item-wrong-type`,`Portal item type should be one of: "${e}"`,{item:t,layer:n})}}(e),s){let e=s(t);if(!e.isValid)throw new a.A(`${r}:invalid-parameters`,e.errorMessage,{layer:o})}}function f(e){let{layer:t,errorNamePrefix:r}=e,{portalItem:o}=t;if(!o)throw new a.A(`${r}:portal-item-not-set`,p(t,"requires the portalItem property to be set"));if(!o.loaded)throw new a.A(`${r}:portal-item-not-loaded`,p(t,"cannot be saved to a portal item that does not exist or is inaccessible"));m({...e,item:o})}function d(e){let{newItem:t,itemType:r}=e,a=n.default.from(t);return a.id&&(a=a.clone(),a.id=null),a.type??=r,a.portal??=s.A.getDefault(),m({...e,item:a}),a}function h(e){return(0,i.m)(e,"portal-item")}async function w(e,t,r){"beforeSave"in e&&"function"==typeof e.beforeSave&&await e.beforeSave();let a=e.write({},t);return await Promise.all(t.resources?.pendingOperations??[]),(0,u.ci)(t,{errorName:"layer-write:unsupported"},r),a}function y(e){(0,l.LG)(e,l.mm.JSAPI),e.typeKeywords&&=e.typeKeywords.filter((e,t,r)=>r.indexOf(e)===t)}async function v(e,t){let{layer:r,createItemData:a,createJSONContext:s,setItemProperties:n,saveResources:i,supplementalUnsupportedErrors:l}=e;await c(e),f(e);let u=r.portalItem,p=s?s(u):h(u),m=await a({layer:r,layerJSON:await w(r,p,{...t,supplementalUnsupportedErrors:l})},u);return await(n?.(r,u,m)),y(u),await u.update({data:m}),(0,o.v)(p),await(i?.(u,p)),u}async function I(e,t){let{layer:r,createItemData:a,createJSONContext:s,setItemProperties:n,saveResources:i,supplementalUnsupportedErrors:l}=e;await c(e);let u=d(e),p=s?s(u):h(u),m=await a({layer:r,layerJSON:await w(r,p,{...t,supplementalUnsupportedErrors:l})},u);return await n(r,u,m),y(u),await async function(e,t,r){let a=e.portal;await a.signIn(),await a.user.addItem({item:e,data:t,folder:r?.folder})}(u,m,t),r.portalItem=u,(0,o.v)(p),await(i?.(u,p)),u}},88788(e,t,r){r.d(t,{m:()=>n,v:()=>s});var a=r(84952),o=r(20655);function s(e,t){return{...i(e,t),readResourcePaths:[]}}function n(e,t,r){let o=(0,a.An)(r?.forceNewItemContext?null:e.itemUrl);return{...i(e,t,r),messages:[],writtenProperties:[],blockedRelativeUrls:[],verifyItemRelativeUrls:o?{rootPath:o.path,writtenUrls:[]}:null,resources:r?.withResources?{toAdd:[],toUpdate:[],toKeep:[],pendingOperations:[]}:null}}function i(e,t,r){return{origin:t,url:(0,a.An)(r?.forceNewItemContext?null:e.itemUrl),portal:e.portal||o.A.getDefault(),portalItem:e}}},15804(e,t,r){r.d(t,{addOrUpdateResources:()=>i,bg:()=>m,cL:()=>p,fetchResources:()=>n,removeAllResources:()=>u,removeResource:()=>l});var a=r(56507),o=r(49186),s=r(84952);async function n(e,t={},r){await e.load(r);let a=(0,s.fj)(e.itemUrl,"resources"),{start:o=1,num:n=10,sortOrder:i="asc",sortField:l="resource"}=t,u={query:{start:o,num:n,sortOrder:i,sortField:l,token:e.apiKey},signal:r?.signal},c=await e.portal.request(a,u);return{total:c.total,nextStart:c.nextStart,resources:c.resources.map(({created:t,size:r,resource:a})=>({created:new Date(t),size:r,resource:e.resourceFromPath(a)}))}}async function i(e,t,r,a){let n=new Map;for(let{resource:e,content:a,compress:s,access:i}of t){if(!e.hasPath())throw new o.A(`portal-item-resource-${r}:invalid-path`,"Resource does not have a valid path");let[t,l]=c(e.path),u=`${t}/${s??""}/${i??""}`;n.has(u)||n.set(u,{prefix:t,compress:s,access:i,files:[]}),n.get(u).files.push({fileName:l,content:a})}await e.load(a);let i=(0,s.fj)(e.userItemUrl,"add"===r?"addResources":"updateResources");for(let{prefix:t,compress:r,access:s,files:l}of n.values())for(let n=0;n<l.length;n+=25){let u=l.slice(n,n+25),c=new FormData;t&&"."!==t&&c.append("resourcesPrefix",t),r&&c.append("compress","true"),s&&c.append("access",s);let p=0;for(let{fileName:e,content:t}of u)c.append("file"+ ++p,t,e);c.append("f","json");try{await e.portal.request(i,{method:"post",body:c,signal:a?.signal})}catch(e){if(a?.ignoreResourceCopyErrors&&e instanceof o.A&&"CONT_00942"===e.details?.messageCode)continue;throw e}}}async function l(e,t,r){if(!t.hasPath())throw new o.A("portal-item-resources-remove:invalid-path","Resource does not have a valid path");await e.load(r);let a=(0,s.fj)(e.userItemUrl,"removeResources");await e.portal.request(a,{method:"post",query:{resource:t.path},signal:r?.signal}),t.portalItem=null}async function u(e,t){await e.load(t);let r=(0,s.fj)(e.userItemUrl,"removeResources");return e.portal.request(r,{method:"post",query:{deleteAll:!0},signal:t?.signal})}function c(e){let t=e.lastIndexOf("/");return-1===t?[".",e]:[e.slice(0,t),e.slice(t+1)]}async function p(e){return"blob"===e.type?e.blob:"json"===e.type?new Blob([e.jsonString],{type:"application/json"}):(await(0,a.A)(e.url,{responseType:"blob"})).data}function m(e,t){if(!e.hasPath())return null;let[r,,a]=function(e){let[t,r]=function(e){let t=(0,s.Zo)(e);return null==t?[e,""]:[e.slice(0,e.length-t.length-1),`.${t}`]}(e),[a,o]=c(t);return[a,o,r]}(e.path);return e.portalItem.resourceFromPath((0,s.fj)(r,t+a))}},91682(e,t,r){r.d(t,{S:()=>l,r:()=>i});var a=r(49186),o=r(17676),s=r(13069),n=r(15804);async function i(e,t,r){await c(await u(e,t,r),t,r)}async function l(e,t,r,a,o){let s=await u(r,a,o);await e.update({data:t}),await c(s,a,o)}async function u(e,t,i){if(!t?.resources)return;let l=function(e,t){let{portalItem:r,portalItemResourcePath:a}=e,{portalItem:o,portalItemResourcePath:s}=t;return r===o&&(!(a||s)||a===s)}(e,t)?new Set(e.paths):new Set;e.paths.length=0,e.portalItem=t.portalItem,e.portalItemResourcePath=t.portalItemResourcePath;let u=new Set(t.resources.toKeep.map(e=>e.resource.path)),c=new Set,p=[];u.forEach(t=>{l.delete(t),e.paths.push(t)});let m=[],f=[],d=[];for(let r of t.resources.toUpdate)if(l.delete(r.resource.path),u.has(r.resource.path)||c.has(r.resource.path)){let{resource:t,content:a,finish:o}=r,i=(0,n.bg)(t,(0,s.lk)());e.paths.push(i.path),m.push({resource:i,content:await(0,n.cL)(a),compress:r.compress}),o&&d.push(()=>o(i))}else{e.paths.push(r.resource.path),f.push({resource:r.resource,content:await(0,n.cL)(r.content),compress:r.compress});let t=r.finish;t&&d.push(()=>t(r.resource)),c.add(r.resource.path)}for(let r of t.resources.toAdd)if(e.paths.push(r.resource.path),l.has(r.resource.path))l.delete(r.resource.path);else{m.push({resource:r.resource,content:await(0,n.cL)(r.content),compress:r.compress});let e=r.finish;e&&d.push(()=>e(r.resource))}if(m.length||f.length){let{addOrUpdateResources:e}=await Promise.resolve().then(()=>r(15804));await e(t.portalItem,m,"add",i),await e(t.portalItem,f,"update",i)}if(d.forEach(e=>e()),0===p.length)return l;let h=await(0,o.Ol)(p);if((0,o.Te)(i),h.length>0)throw new a.A("save:resources","Failed to save one or more resources",{errors:h});return l}async function c(e,t,r){if(!e||!t.portalItem)return;let a=[];for(let o of e){let e=t.portalItem.resourceFromPath(o);a.push(e.portalItem.removeResource(e,r))}await(0,o.Lx)(a)}}}]);
@@ -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]?I.deleteBlock(e,i):l[t]?.cache.delete(i):t??I.deleteBlock(e,i)}var b=i(94778),v=i(40951),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,i){return this.rasterJobHandler?this.rasterJobHandler.decode({data:e,options:t},i):(0,v.D)(e,t,i)}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,t,i,{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})}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2867],{66131(e,t,s){s.d(t,{lY:()=>d,mT:()=>m});var i=s(59534),r=s(799),n=s(3330),o=s(84741),a=s(34747);const l={TimeZoneNotRecognized:"Timezone identifier has not been recognized."};class c extends Error{constructor(e,t){super((0,r.HC)(l[e],t)),this.declaredRootClass="esri.arcade.arcadedate.dateerror",Error.captureStackTrace&&Error.captureStackTrace(this,c)}}function h(e,t,s){return e<t?e-t:e>s?e-s:0}function u(e,t,s){return e<t?t:e>s?s:e}class d{constructor(e){this._date=e,this.declaredRootClass="esri.arcade.arcadedate"}static fromParts(e=0,t=1,s=1,i=0,r=0,n=0,o=0,l){if(isNaN(e)||isNaN(t)||isNaN(s)||isNaN(i)||isNaN(r)||isNaN(n)||isNaN(o))return null;let c=a.c9.local(e,t).daysInMonth,f=a.c9.fromObject({day:u(s,1,c),year:e,month:u(t,1,12),hour:u(i,0,23),minute:u(r,0,59),second:u(n,0,59),millisecond:u(o,0,999)},{zone:m(l)});return f=f.plus({months:h(t,1,12),days:h(s,1,c),hours:h(i,0,23),minutes:h(r,0,59),seconds:h(n,0,59),milliseconds:h(o,0,999)}),new d(f)}static get systemTimeZoneCanonicalName(){return Intl.DateTimeFormat().resolvedOptions().timeZone??"system"}static arcadeDateAndZoneToArcadeDate(e,t){let s=m(t);return e.isUnknownTimeZone||s===n.GB.instance?d.fromParts(e.year,e.monthJS+1,e.day,e.hour,e.minute,e.second,e.millisecond,s):new d(e._date.setZone(s))}static dateJSToArcadeDate(e){return new d(a.c9.fromJSDate(e,{zone:"system"}))}static dateJSAndZoneToArcadeDate(e,t="system"){let s=m(t);return new d(a.c9.fromJSDate(e,{zone:s}))}static unknownEpochToArcadeDate(e){return new d(a.c9.fromMillis(e,{zone:n.GB.instance}))}static unknownDateJSToArcadeDate(e){return new d(a.c9.fromMillis(e.getTime(),{zone:n.GB.instance}))}static epochToArcadeDate(e,t="system"){let s=m(t);return new d(a.c9.fromMillis(e,{zone:s}))}static dateTimeToArcadeDate(e){return new d(e)}clone(){return new d(this._date)}changeTimeZone(e){let t=m(e);return d.dateTimeToArcadeDate(this._date.setZone(t))}static dateTimeAndZoneToArcadeDate(e,t){let s=m(t);return e.zone===n.GB.instance||s===n.GB.instance?d.fromParts(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond,s):new d(e.setZone(s))}static nowToArcadeDate(e){let t=m(e);return new d(a.c9.fromJSDate(new Date,{zone:t}))}static nowUTCToArcadeDate(){return new d(a.c9.utc())}get isSystem(){return"system"===this.timeZone||this.timeZone===d.systemTimeZoneCanonicalName}equals(e){return this.isSystem&&e.isSystem?this.toNumber()===e.toNumber():this.isUnknownTimeZone===e.isUnknownTimeZone&&this._date.equals(e._date)}get isUnknownTimeZone(){return this._date.zone===n.GB.instance}get isValid(){return this._date.isValid}get hour(){return this._date.hour}get second(){return this._date.second}get day(){return this._date.day}get dayOfWeekISO(){return this._date.weekday}get dayOfWeekJS(){let e=this._date.weekday;return e>6&&(e=0),e}get millisecond(){return this._date.millisecond}get monthISO(){return this._date.month}get weekISO(){return this._date.weekNumber}get yearISO(){return this._date.weekYear}get monthJS(){return this._date.month-1}get year(){return this._date.year}get minute(){return this._date.minute}get zone(){return this._date.zone}get timeZoneOffset(){return this.isUnknownTimeZone?0:this._date.offset}get timeZone(){if(this.isUnknownTimeZone)return"unknown";if("system"===this._date.zone.type)return"system";let e=this.zone;return"fixed"===e.type?0===e.fixed?"UTC":e.formatOffset(0,"short"):e.name}stringify(){return JSON.stringify(this.toJSDate())}plus(e){return new d(this._date.plus(e))}diff(e,t){return this._date.diff(e._date,t)[t]}toISODate(){return this._date.toISODate()}toISOString(e){return e?this._date.toISO({suppressMilliseconds:!0,includeOffset:!this.isUnknownTimeZone}):this._date.toISO({includeOffset:!this.isUnknownTimeZone})}toISOTime(e,t){return this._date.toISOTime({suppressMilliseconds:e,includeOffset:t&&!this.isUnknownTimeZone})}toFormat(e,t){return this.isUnknownTimeZone&&(e=e.replaceAll("Z","")),this._date.toFormat(e,t)}toJSDate(){return this._date.toJSDate()}toSQLValue(){return this._date.toFormat("yyyy-LL-dd HH:mm:ss")}toSQLWithKeyword(){return`timestamp '${this.toSQLValue()}'`}toDateTime(){return this._date}toNumber(){return this._date.toMillis()}getTime(){return this._date.toMillis()}toUTC(){return new d(this._date.toUTC())}toLocal(){return new d(this._date.toLocal())}toString(){return this.toISOString(!0)}static fromReaderAsTimeStampOffset(e){if(!e)return null;let t=a.c9.fromISO(e,{setZone:!0});return new d(t)}}function m(e,t=!0){if(e instanceof a.bo)return e;switch((0,i.B)(e)){case"system":return"system";case"utc":return"UTC";case"unknown":return n.GB.instance}if(/^[+-]?[0-9]{1,2}(:[0-9]{2})?$/.test(e)){let t=a.mQ.parseSpecifier("UTC"+(e.startsWith("+")||e.startsWith("-")?"":"+")+e);if(t)return t}let s=(0,o.p)(e);if(!s.isValid){if(t)throw new c("TimeZoneNotRecognized");return null}return s}},59534(e,t,s){s.d(t,{B:()=>r,b:()=>n});var i=s(85935);function r(e){return e.toLowerCase().replaceAll(/[\s-]+/g,"")}class n{constructor(e,t){let s=new Map;for(let t of e){let e=r(t);if(s.has(e))throw Error(`${t} already added as ${s.get(e)}`);s.set(e,t)}if(null!=t)for(let[e,i]of t){let t=r(e);if(s.has(t))throw Error(`${e} already associated with ${s.get(t)}`);s.set(t,i)}this._enumMap=s}lookup(e){return this._enumMap.get(r(e))}get(e){let t=this.lookup(e);if(null==t)throw new i.D$("InvalidParameter",null);return t}}},85935(e,t,s){s.d(t,{D$:()=>a,O$:()=>h,i2:()=>u,mT:()=>c,ps:()=>m});var i=s(799);const r={TypeNotAllowedInFeature:"Feature attributes only support dates, numbers, strings, guids.",LogicError:"Logic error - {reason}",CannotCompareDateAndTime:"Cannot compare date or dateonly with timeonly types",NeverReach:"Encountered unreachable logic",AsyncNotEnabled:"Async Arcade must be enabled for this script",ModuleAccessorMustBeString:"Module accessor must be a string",ModuleExportNotFound:"Module has no export with provided identifier",ModulesNotSupported:"Current profile does not support modules",ArrayAccessMustBeNumber:"Array accessor must be a number",FunctionNotFound:"Function not found",FieldNotFound:"Key not found - {key}",CircularModules:"Circular module dependencies are not allowed",Cancelled:"Execution cancelled",UnsupportedHashType:"Type not supported in hash function",IllegalResult:"Value is not a supported return type",PortalRequired:"Portal is required",InvalidParameter:"Invalid parameter",WrongNumberOfParameters:"Call with wrong number of parameters",Unrecognized:"Unrecognized code structure",UnrecognizedType:"Unrecognized type",WrongSpatialReference:"Cannot work with geometry in this spatial reference. It is different to the execution spatial reference",BooleanConditionRequired:"Conditions must use booleans",NoFunctionInDictionary:"Dictionaries cannot contain functions.",NoFunctionInArray:"Arrays cannot contain functions.",NoFunctionInTemplateLiteral:"Template Literals do not expect functions by value.",KeyAccessorMustBeString:"Accessor must be a string",KeyMustBeString:"Object keys must be a string",Immutable:"Object is immutable",UnexpectedToken:"Unexpected token",MemberOfNull:"Cannot access property of null object",MaximumCallDepth:"Exceeded maximum function depth",OutOfBounds:"Out of bounds",InvalidIdentifier:"Identifier not recognized",CallNonFunction:"Expression is not a function",InvalidMemberAccessKey:"Cannot access value using a key of this type",AssignModuleFunction:"Cannot assign function to module variable",UnsupportUnaryOperator:"Unsupported unary operator",UnsupportedOperator:"Unsupported operator",LogicalExpressionOnlyBoolean:"Logical expressions must be boolean",LogicExpressionOrAnd:"Logical expression can only be combined with || or &&",CannotChangeTimeZoneTime:"Cannot change the timezone of a Time",CannotChangeTimeZoneDateOnly:"Cannot change the timezone of a DateOnly",FeatureSetDoesNotHaveSubtypes:"FeatureSet does not have subtypes"};function n(e){return"object"==typeof e&&"line"in e&&"column"in e&&"number"==typeof e.line&&"number"==typeof e.column}class o extends Error{constructor(e,t){super(l(t)+("object"==typeof e&&e&&"message"in e?e.message:""),{cause:e}),this.loc=t?.loc??null}}class a extends Error{constructor(e,t,s){super("Execution error - "+l(t)+(0,i.HC)(r[e],s)),this.declaredRootClass="esri.arcade.arcadeexecutionerror",this.loc=t?.loc??null}}function l(e){return null==e?.loc?"":`Line ${e.loc.start.line}:${e.loc.start.column}: `}class c extends Error{constructor(e,t,s){super("Compilation error - "+l(t)+(0,i.HC)(r[e],s)),this.declaredRootClass="esri.arcade.arcadecompilationerror",this.loc=t?.loc??null}}class h extends Error{constructor(){super("Uncompilable code structures"),this.declaredRootClass="esri.arcade.arcadeuncompilableerror"}}function u(e,t){return!function(e){if(e instanceof Error&&"loc"in e){let t=e.loc;return null==t||"object"==typeof t&&"start"in t&&null!=t.start&&n(t.start)&&(!("end"in t)||null==t.end||n(t.end))}return!1}(e)||null==e.loc&&null!=t?.loc?new o(e,t):e}const d={UnrecognizedUri:"Unrecognized uri - {uri}",UnsupportedUriProtocol:"Unrecognized uri protocol"};class m extends Error{constructor(e,t){super((0,i.HC)(d[e],t)),this.declaredRootClass="esri.arcade.arcademoduleerror"}}},66344(e,t,s){s.d(t,{q:()=>a});const i=!!(0,s(44208).A)("esri-tests-disable-gpu-memory-measurements");Symbol.iterator;class r{get size(){return this._size}constructor(e=10485760,t=.3){this._maxSize=e,this._maxClientSizeRatio=t,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._clients=new Map,this._sizeLimits=new Map}destroy(){this.clearAll(),this._sizeLimits.clear(),this._clients.clear(),this._db.clear()}register(e){this._clients.set(e.id.slice(0,-1),e)}deregister(e){this.clear(e),this._sizeLimits.delete(e),this._clients.delete(e.id.slice(0,-1))}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,-1),this._checkSize()}get _maxClientSize(){return this._maxSize*this._maxClientSizeRatio}getSize(e,t){return this._db.get(e.id+t)?.size??0}put(e,t,s,r,o){t=e.id+t;let a=this._db.get(t);if(a&&(this._size-=a.size,e.size-=a.size,this._db.delete(t),a.entry!==s&&this._notifyRemove(t,a.entry,a.size,0)),r>this._maxSize)return void this._notifyRemove(t,s,r,0);if(void 0===s)return void console.warn("Refusing to cache undefined entry ");if(!r||r<0)return i||console.warn(`Refusing to cache entry with size ${r} for key ${t}`),void this._notifyRemove(t,s,0,0);let l=1+Math.max(o,-4)- -3;this._db.set(t,new n(s,r,l)),this._size+=r,e.size+=r,this._checkSize()}updateSize(e,t){t=e.id+t;let s=this._db.get(t);if(!s)return;this._size-=s.size,e.size-=s.size;let i=s.entry.usedMemory;for(;i>this._maxSize;){let e=this._notifyRemove(t,s.entry,i,1);if(!(null!=e&&e>0))return void this._db.delete(t);i=e}s.size=i,this._size+=i,e.size+=i,this._checkSize()}pop(e,t){t=e.id+t;let s=this._db.get(t);if(s)return this._size-=s.size,e.size-=s.size,this._db.delete(t),++this._hit,s.entry;++this._miss}get(e,t){t=e.id+t;let s=this._db.get(t);if(void 0!==s)return this._db.delete(t),s.lives=s.lifetime,this._db.set(t,s),++this._hit,s.entry;++this._miss}peek(e,t){let s=this._db.get(e.id+t);return s?++this._hit:++this._miss,s?.entry}get performanceInfo(){let e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},s=[];this._db.forEach((e,i)=>{let r=e.lifetime;s[r]=(s[r]||0)+e.size,this._clients.forEach(s=>{let{id:r,name:n}=s;if(i.startsWith(r)){let s=t[n]||0;t[n]=s+e.size}})});let i={};this._clients.forEach(e=>{let s=e.name;if("hitRate"in e&&"number"==typeof e.hitRate&&!isNaN(e.hitRate)&&e.hitRate>0){let r=t[s]||0;t[s]=r,i[s]=Math.round(100*e.hitRate)+"%"}else i[s]="0%"});let r=Object.keys(t);r.sort((e,s)=>t[s]-t[e]),r.forEach(s=>e[s]=Math.round(t[s]/2**20)+"MB / "+i[s]);for(let t=s.length-1;t>=0;--t){let i=s[t];i&&(e["Priority "+(t+-3-1)]=Math.round(i/this._size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._clients.forEach(e=>e.resetHitRate())}clear(e){let t=e.id;this._db.forEach((e,s)=>{s.startsWith(t)&&(this._size-=e.size,this._db.delete(s),this._notifyRemove(s,e.entry,e.size,0))}),e.size=0}clearAll(){this._db.forEach((e,t)=>this._notifyRemove(t,e.entry,e.size,0)),this._clients.forEach(e=>e.size=0),this._size=0,this._db.clear()}*values(e){for(let[t,s]of this._db)t.startsWith(e.id)&&(yield s.entry)}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,s,i){let r=this._clients.get(e.split(o)[0])?.removeFunc,n=r?.(t,i,s);return"number"==typeof n?n:null}_checkSize(){this._sizeLimits.forEach((e,t)=>this._checkSizeLimits(e,t)),this._clients.forEach(e=>this._checkSizeLimits(this._maxClientSize,e)),this._checkSizeLimits(this.maxSize)}setMaxClientSize(e,t){null==t||t<=0?this._sizeLimits.delete(e):this._sizeLimits.set(e,t)}_checkSizeLimits(e,t){let s=t??this;if(s.size<=e)return;let i=t?.id,r=!0;for(;r;){r=!1;for(let[n,a]of this._db)if(0===a.lifetime&&(!i||n.startsWith(i))){let i=t??this._clients.get(n.split(o)[0]);if(this._purgeItem(n,a,i),s.size<=.9*e)return;r||=this._db.has(n)}}for(let[r,n]of this._db)if(!i||r.startsWith(i)){let i=t??this._clients.get(r.split(o)[0]);if(this._purgeItem(r,n,i),s.size<=.9*e)return}}_purgeItem(e,t,s){if(this._db.delete(e),t.lives<=1){this._size-=t.size,s&&(s.size-=t.size);let i=this._notifyRemove(e,t.entry,t.size,1);null!=i&&i>0&&(this._size+=i,s&&(s.size+=i),t.lives=t.lifetime,t.size=i,this._db.set(e,t))}else--t.lives,this._db.set(e,t)}}new r(0);class n{constructor(e,t,s){this.entry=e,this.size=t,this.lifetime=s,this.lives=s}}const o=":";class a{constructor(e,t){this.removeFunc=t,this.id="",this.name="",this.size=0,this._storage=new r(e,1),this._storage.register(this)}destroy(){this._storage.deregister(this),this._storage.destroy()}put(e,t,s=1){this._storage.put(this,e,t,s,1)}pop(e){return this._storage.pop(this,e)}get(e){return this._storage.get(this,e)}clear(){this._storage.clearAll()}get maxSize(){return this._storage.maxSize}set maxSize(e){this._storage.maxSize=e}resetHitRate(){}}},44729(e,t,s){s.d(t,{n:()=>l});var i=s(66131),r=s(73444),n=s(34747);function o(e){e=e.replaceAll(/LTS|LT|L{1,4}|l{1,4}/g,"[$&]");let t="";for(let s of e.match(/(\[[^[]*\])|(\\)?([Hh]mm(ss)?|Mo|M{1,4}|Do|DDDo|D{1,4}|d{2,4}|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g)||[])switch(s){case"D":t+="d";break;case"DD":t+="dd";break;case"DDD":t+="o";break;case"d":t+="c";break;case"ddd":t+="ccc";break;case"dddd":t+="cccc";break;case"M":t+="L";break;case"MM":t+="LL";break;case"MMM":t+="LLL";break;case"MMMM":t+="LLLL";break;case"YY":t+="yy";break;case"Y":case"YYYY":t+="yyyy";break;case"Q":t+="q";break;case"X":case"x":t+=s;break;default:s.length>=2&&s.startsWith("[")&&s.endsWith("]")?t+=`'${s.slice(1,-1)}'`:t+=`'${s}'`}return t}const a="esri.core.sql.dateonly";class l{constructor(e,t,s){this._year=e,this._month=t,this._day=s,this.declaredRootClass=a}static isDateOnly(e){return"object"==typeof e&&!!e&&"declaredRootClass"in e&&e.declaredRootClass===a}get month(){return this._month}get monthJS(){return this._month-1}get year(){return this._year}get day(){return this._day}get isValid(){return this.toDateTime("unknown").isValid}equals(e){return l.isDateOnly(e)&&e.day===this.day&&e.month===this.month&&e.year===this.year}compare(e){return this.year===e.year?this.month===e.month?this.day-e.day:this.month-e.month:this.year-e.year}clone(){return new l(this._year,this._month,this._day)}toDateTime(e){return n.c9.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.mT)(e)})}toDateTimeLuxon(e){return n.c9.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.mT)(e)})}toString(){return`${this.year.toString().padStart(4,"0")}-${this.month.toString().padStart(2,"0")}-${this.day.toString().padStart(2,"0")}`}toFormat(e=null,t=!0){if(null===e||""===e)return this.toString();if(t&&(e=o(e)),!e)return"";let s=this.toDateTime("unknown");return i.lY.dateTimeToArcadeDate(s).toFormat(e,{locale:(0,r.JK)(),numberingSystem:"latn"})}toArcadeDate(){let e=this.toDateTime("unknown");return i.lY.dateTimeToArcadeDate(e)}toNumber(){return this.toDateTime("unknown").toMillis()}toJSDate(){return this.toDateTime("unknown").toJSDate()}toStorageFormat(){return this.toFormat("yyyy-LL-dd",!1)}toSQLValue(){return this.toFormat("yyyy-LL-dd",!1)}toSQLWithKeyword(){return"date '"+this.toFormat("yyyy-LL-dd",!1)+"'"}plus(e,t){return l.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}toUTCDateTime(){return n.c9.utc(this.year,this.month,this.day,0,0,0,0)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}static fromMilliseconds(e){let t=n.c9.fromMillis(e,{zone:n.mQ.utcInstance});return t.isValid?l.fromParts(t.year,t.month,t.day):null}static fromSeconds(e){let t=n.c9.fromSeconds(e,{zone:n.mQ.utcInstance});return t.isValid?l.fromParts(t.year,t.month,t.day):null}static fromReader(e){if(!e)return null;let t=e.indexOf("-");if(t<0)return null;let s=e.indexOf("-",t+1);return s<0?null:new l(parseInt(e.slice(0,t),10),parseInt(e.slice(t+1,s),10),parseInt(e.slice(s+1),10))}static fromParts(e,t,s){let i=new l(e,t,s);return!1===i.isValid?null:i}static fromDateJS(e){return l.fromParts(e.getFullYear(),e.getMonth()+1,e.getDay())}static fromDateTime(e){return l.fromParts(e.year,e.month,e.day)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e||null===e)return null;let s=[];if(t)(t=o(t))&&s.push(t);else if(null===t||""===t){let t=n.c9.fromISO(e,{setZone:!0});return t.isValid?l.fromParts(t.year,t.month,t.day):null}for(let i of s){let s=n.c9.fromFormat(e,t??i);if(s.isValid)return new l(s.year,s.month,s.day)}return null}static fromNow(e="system"){let t=n.c9.fromJSDate(new Date).setZone((0,i.mT)(e));return new l(t.year,t.month,t.day)}}},15032(e,t,s){s.d(t,{k:()=>l});var i=s(73444),r=s(54218),n=s(34747);function o(e){if(!e)return"";let t=/(a|A|hh?|HH?|mm?|ss?|SSS|S|.)/g,s="";for(let i of e.match(t)||[])switch(i){case"SSS":case"m":case"mm":case"h":case"hh":case"H":case"HH":case"s":case"ss":s+=i;break;case"A":case"a":s+="a";break;default:s+=`'${i}'`}return s}const a="esri.core.sql.timeonly";class l{constructor(e,t,s,i){this._hour=e,this._minute=t,this._second=s,this._millisecond=i,this.declaredRootClass=a}static isTimeOnly(e){return"object"==typeof e&&!!e&&"declaredRootClass"in e&&e.declaredRootClass===a}get hour(){return this._hour}get minute(){return this._minute}get second(){return this._second}get millisecond(){return this._millisecond}equals(e){return l.isTimeOnly(e)&&e.hour===this.hour&&e.minute===this.minute&&e.second===this.second&&e.millisecond===this.millisecond}clone(){return new l(this.hour,this.minute,this.second,this.millisecond)}isValid(){return(0,r.Fq)(this.hour)&&(0,r.Fq)(this.minute)&&(0,r.Fq)(this.second)&&(0,r.Fq)(this.millisecond)&&this.hour>=0&&this.hour<24&&this.minute>=0&&this.minute<60&&this.second>=0&&this.second<60&&this.millisecond>=0&&this.millisecond<1e3}toString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`+(this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):"")}toSQLValue(){return this.toString()}toSQLWithKeyword(){return`time '${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}${this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):""}'`}toStorageString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`}toFormat(e=null){return null===e||""===e?this.toString():(e=o(e))?n.c9.local(1970,1,1,this._hour,this._minute,this._second,this._millisecond).toFormat(e,{locale:(0,i.JK)(),numberingSystem:"latn"}):""}toNumber(){return this.millisecond+1e3*this.second+1e3*this.minute*60+60*this.hour*60*1e3}static fromParts(e,t,s,i){let r=new l(e,t,s,i);return r.isValid()?r:null}static fromReader(e){if(!e)return null;let t=e.indexOf(":");if(t<0)return null;let s=e.indexOf(":",t+1);return s<0?null:new l(parseInt(e.slice(0,t),10),parseInt(e.slice(t+1,s),10),parseInt(e.slice(s+1),10),0)}static fromMilliseconds(e){if(e>864e5||e<0)return null;let t=Math.floor(e/1e3%60),s=Math.floor(e/6e4%60),i=Math.floor(e/36e5%24),r=Math.floor(e%1e3);return new l(i,s,t,r)}static fromDateJS(e){return new l(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}static fromDateTime(e){return new l(e.hour,e.minute,e.second,e.millisecond)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e||null===e)return null;let s=[];t?(t=o(t))&&s.push(t):(null===t||""===t)&&(s.push("HH:mm:ss"),s.push("HH:mm:ss.SSS"),s.push("hh:mm:ss a"),s.push("hh:mm:ss.SSS a"),s.push("HH:mm"),s.push("hh:mm a"),s.push("H:mm"),s.push("h:mm a"),s.push("H:mm:ss"),s.push("h:mm:ss a"),s.push("H:mm:ss.SSS"),s.push("h:mm:ss.SSS a"));for(let t of s){let s=n.c9.fromFormat(e,t);if(s.isValid)return new l(s.hour,s.minute,s.second,s.millisecond)}return null}plus(e,t){switch(e){case"days":case"years":case"months":return this.clone();case"hours":case"minutes":case"seconds":case"milliseconds":return l.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}return null}toUTCDateTime(){return n.c9.utc(1970,1,1,this.hour,this.minute,this.second,this.millisecond)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}}},44123(e,t,s){s.d(t,{WhereClauseCache:()=>n});var i=s(66344),r=s(89696);class n{constructor(e,t){this._cache=new i.q(e),this._invalidCache=new i.q(t)}get(e,t){let s=`${t?.uid}:${e}`,i=this._cache.get(s);if(i)return i;if(null!=this._invalidCache.get(s))return null;try{let i=r.A.create(e,{fieldsIndex:t});return this._cache.put(s,i),i}catch(e){return this._invalidCache.put(s,e),null}}getError(e,t){let s=`${t?.uid}:${e}`;return this._invalidCache.get(s)??null}}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2491],{11006(e,t,n){function r(e,t,n,r,o){i(e,t,n||0,r||e.length-1,o||s)}function i(e,t,n,r,s){for(;r>n;){if(r-n>600){var l=r-n+1,a=t-n+1,u=Math.log(l),h=.5*Math.exp(2*u/3),c=.5*Math.sqrt(u*h*(l-h)/l)*(a-l/2<0?-1:1);i(e,t,Math.max(n,Math.floor(t-a*h/l+c)),Math.min(r,Math.floor(t+(l-a)*h/l+c)),s)}var d=e[t],p=n,m=r;for(o(e,n,t),s(e[r],d)>0&&o(e,n,r);p<m;){for(o(e,p,m),p++,m--;s(e[p],d)<0;)p++;for(;s(e[m],d)>0;)m--}0===s(e[n],d)?o(e,n,m):o(e,++m,r),m<=t&&(n=m+1),t<=m&&(r=m-1)}}function o(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function s(e,t){return e<t?-1:+(e>t)}n.d(t,{q:()=>r})},40876(e,t,n){n.d(t,{Eq:()=>p,G1:()=>f,Q6:()=>_,TS:()=>o,V6:()=>i,Vm:()=>m,ay:()=>a,c1:()=>g,c4:()=>s,j5:()=>u,lT:()=>c,oW:()=>h,xV:()=>v});const r={transparent:[0,0,0,0],black:[0,0,0,1],silver:[192,192,192,1],gray:[128,128,128,1],white:[255,255,255,1],maroon:[128,0,0,1],red:[255,0,0,1],purple:[128,0,128,1],fuchsia:[255,0,255,1],green:[0,128,0,1],lime:[0,255,0,1],olive:[128,128,0,1],yellow:[255,255,0,1],navy:[0,0,128,1],blue:[0,0,255,1],teal:[0,128,128,1],aqua:[0,255,255,1],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],blanchedalmond:[255,235,205,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],oldlace:[253,245,230,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],rebeccapurple:[102,51,153,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],whitesmoke:[245,245,245,1],yellowgreen:[154,205,50,1]};function i(e){return!!r[e]||!!r[e.toLowerCase()]}function o(e){return r[e]??r[e.toLowerCase()]}function s(e){return[...o(e)]}function l(e,t,n){n<0&&++n,n>1&&--n;let r=6*n;return r<1?e+(t-e)*r:2*n<1?t:3*n<2?e+(t-e)*(2/3-n)*6:e}function a(e,t,n,r=1){let i=(e%360+360)%360/360,o=n<=.5?n*(t+1):n+t-n*t,s=2*n-o;return[Math.round(255*l(s,o,i+1/3)),Math.round(255*l(s,o,i)),Math.round(255*l(s,o,i-1/3)),r]}function u(e){let t=e.length>5,n=t?8:4,r=(1<<n)-1,i=t?1:17,o=t?9===e.length:5===e.length,s=Number("0x"+e.slice(1));if(isNaN(s))return null;let l,a=[0,0,0,1];return o&&(l=s&r,s>>=n,a[3]=i*l/255),l=s&r,s>>=n,a[2]=i*l,l=s&r,s>>=n,a[1]=i*l,l=s&r,s>>=n,a[0]=i*l,a}function h(e){if(!e.startsWith("#")||isNaN(Number(`0x${e.slice(1)}`)))return null;switch(e.length){case 4:case 5:{let t=parseInt(e.slice(1,2),16),n=parseInt(e.slice(2,3),16),r=parseInt(e.slice(3,4),16),i=4===e.length?15:parseInt(e.slice(4),16);return[t+16*t,n+16*n,r+16*r,(i+16*i)/255]}case 7:case 9:return[parseInt(e.slice(1,3),16),parseInt(e.slice(3,5),16),parseInt(e.slice(5,7),16),(7===e.length?255:parseInt(e.slice(7),16))/255];default:return null}}function c(e){let t=e.toLowerCase().match(/^(rgba?|hsla?)\(([\s.\-,%0-9]+)\)/);if(t){let e=t[2].split(/\s*,\s*/),n=t[1];if("rgb"===n&&3===e.length||"rgba"===n&&4===e.length){if(e[0].endsWith("%")){let t=e.map(e=>2.56*parseFloat(e));return 4===e.length&&(t[3]=parseFloat(e[3])),d(t)}return d(e.map(e=>parseFloat(e)))}if("hsl"===n&&3===e.length||"hsla"===n&&4===e.length)return a(parseFloat(e[0]),parseFloat(e[1])/100,parseFloat(e[2])/100,parseFloat(e[3]??"1"))}return null}function d(e){return e[0]=g(e[0]),e[1]=g(e[1]),e[2]=g(e[2]),e[3]=4===e.length?f(e[3]):1,e}function p(e){let t=i(e)?o(e):null;return t??=c(e),t??=h(e),t}function m(e){let t=p(e);return null==t?null:[t[0]/255,t[1]/255,t[2]/255,t[3]]}function f(e){return y(e,0,1)}function g(e){return Math.round(y(e,0,255))}function y(e,t,n){return e=Number(e),isNaN(e)?n:e<t?t:e>n?n:e}const x=1/2.2;function _(e){return e**2.2}function v(e){return e**x}n.d(t,["iw",0,x])},62885(e,t,n){n.d(t,{H:()=>o,V:()=>i});var r=n(7762);function i(e,t,n=r.A){return t||=new n,t===e||t.destroyed||(t.removeAll(),(i=e)&&(Array.isArray(i)||"items"in i&&Array.isArray(i.items))?t.addMany(e):e&&t.add(e)),t;var i}function o(e){return e}},21287(e,t,n){n.d(t,{M5:()=>c,eV:()=>h});var r=n(56507),i=n(49186),o=n(17676),s=n(84952),l=n(26306);let a=null,u=!0;function h(e,t,n,r){if(!t||!n)throw Error("Cannot construct image data without dimensions");if(u)try{return new ImageData(e,t,n)}catch{u=!1}let i=function(e,t,n){return n||=(a||(a=document.createElement("canvas"),a.width=1,a.height=1),a),n.getContext("2d").createImageData(e,t)}(t,n,r);return i.data.set(e,0),i}async function c(e,t){let{arrayBuffer:a,mediaType:u}=await async function(e,t){let n=(0,s.r$)(e);if(n?.isBase64)return{arrayBuffer:(0,l.M)(n.data),mediaType:n.mediaType};let i=await(0,r.A)(e,{responseType:"array-buffer",...t});return{arrayBuffer:i.data,mediaType:i.getHeader?.("Content-Type")??""}}(e,t),h="image/png"===u;if("image/gif"===u){let{isAnimatedGIF:e,parseGif:r}=await n.e(820).then(()=>n(10820));if(e(a))return r(a,t)}if(h){let{isAnimatedPNG:e,parseApng:r}=await n.e(2390).then(()=>n(22390));if(e(a))return r(a,t)}return async function(e,t){let n=window.URL.createObjectURL(e);try{let{data:e}=await(0,r.A)(n,{...t,responseType:"image"});return e}catch(e){throw(0,o.zf)(e)?e:new i.A("invalid-image",`Could not fetch requested image at ${n}`)}finally{window.URL.revokeObjectURL(n)}}(new Blob([a],{type:u}),t)}},48163(e,t,n){function r(){return[0,0]}function i(e){return[e[0],e[1]]}function o(e,t){return[e,t]}function s(){return o(1,1)}function l(){return o(-1,-1)}function a(){return o(1,0)}function u(){return o(0,1)}n.d(t,{fA:()=>o,o8:()=>i,vt:()=>r});const h=s(),c=l(),d=a(),p=u();Object.freeze(Object.defineProperty({__proto__:null,NEGATIVE_ONES:c,ONES:h,UNIT_X:d,UNIT_Y:p,ZEROS:[0,0],clone:i,create:r,freeze:function(e,t){return[e,t]},fromArray:function(e,t=[0,0]){let n=Math.min(2,e.length);for(let r=0;r<n;++r)t[r]=e[r];return t},fromValues:o,negativeOnes:l,ones:s,unitX:a,unitY:u,zeros:function(){return[0,0]}},Symbol.toStringTag,{value:"Module"})),n.d(t,["IA",0,c,"Un",0,h])},35522(e,t,n){n.d(t,{$A:()=>I,Bw:()=>o,C:()=>s,Cc:()=>C,DI:()=>M,Io:()=>x,Ln:()=>y,Om:()=>P,Qr:()=>c,Re:()=>u,S8:()=>b,T9:()=>f,WQ:()=>a,Z0:()=>A,_S:()=>p,aI:()=>E,ei:()=>R,fw:()=>O,gL:()=>S,hG:()=>_,hZ:()=>l,hs:()=>g,jk:()=>m,lw:()=>h,m3:()=>v,oW:()=>Z,t2:()=>T,tn:()=>d,ze:()=>w});var r=n(51850),i=n(34304);function o(e){let t=e[0],n=e[1],r=e[2];return Math.sqrt(t*t+n*n+r*r)}function s(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function l(e,t,n,r){return e[0]=t,e[1]=n,e[2]=r,e}function a(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e[2]=t[2]+n[2],e}function u(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e[2]=t[2]-n[2],e}function h(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e[2]=t[2]*n[2],e}function c(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e[2]=t[2]/n[2],e}function d(e,t){return e[0]=Math.abs(t[0]),e[1]=Math.abs(t[1]),e[2]=Math.abs(t[2]),e}function p(e,t){return e[0]=Math.sign(t[0]),e[1]=Math.sign(t[1]),e[2]=Math.sign(t[2]),e}function m(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e[2]=Math.min(t[2],n[2]),e}function f(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e[2]=Math.max(t[2],n[2]),e}function g(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e}function y(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e[2]=t[2]+n[2]*r,e}function x(e,t){let n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2];return Math.sqrt(n*n+r*r+i*i)}function _(e,t){let n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2];return n*n+r*r+i*i}function v(e){let t=e[0],n=e[1],r=e[2];return t*t+n*n+r*r}function w(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e}function M(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e}function b(e,t=e){let n=t[0],r=t[1],i=t[2],o=n*n+r*r+i*i;return o>0&&(o=1/Math.sqrt(o),e[0]=t[0]*o,e[1]=t[1]*o,e[2]=t[2]*o),e}function P(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function I(e,t,n){let r=t[0],i=t[1],o=t[2],s=n[0],l=n[1],a=n[2];return e[0]=i*a-o*l,e[1]=o*s-r*a,e[2]=r*l-i*s,e}function C(e,t,n,r){let i=t[0],o=t[1],s=t[2];return e[0]=i+r*(n[0]-i),e[1]=o+r*(n[1]-o),e[2]=s+r*(n[2]-s),e}function A(e,t,n){let r=t[0],i=t[1],o=t[2];return e[0]=n[0]*r+n[4]*i+n[8]*o+n[12],e[1]=n[1]*r+n[5]*i+n[9]*o+n[13],e[2]=n[2]*r+n[6]*i+n[10]*o+n[14],e}function R(e,t,n){let r=t[0],i=t[1],o=t[2];return e[0]=r*n[0]+i*n[3]+o*n[6],e[1]=r*n[1]+i*n[4]+o*n[7],e[2]=r*n[2]+i*n[5]+o*n[8],e}function S(e,t,n){return O(e,t,n[0],n[1],n[2],n[3])}function O(e,t,n,r,i,o){let s=t[0],l=t[1],a=t[2],u=r*a-i*l,h=i*s-n*a,c=n*l-r*s,d=r*c-i*h,p=i*u-n*c,m=n*h-r*u,f=2*o;return e[0]=s+u*f+2*d,e[1]=l+h*f+2*p,e[2]=a+c*f+2*m,e}const L=(0,r.vt)(),B=(0,r.vt)();function T(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function E(e,t){if(e===t)return!0;let n=e[0],r=e[1],o=e[2],s=t[0],l=t[1],a=t[2],u=(0,i.FD)();return Math.abs(n-s)<=u*Math.max(1,Math.abs(n),Math.abs(s))&&Math.abs(r-l)<=u*Math.max(1,Math.abs(r),Math.abs(l))&&Math.abs(o-a)<=u*Math.max(1,Math.abs(o),Math.abs(a))}function Z(e,t,n){let r=n[0]-t[0],i=n[1]-t[1],o=n[2]-t[2],s=r*r+i*i+o*o;return s>0?(s=1/Math.sqrt(s),e[0]=r*s,e[1]=i*s,e[2]=o*s,e):(e[0]=0,e[1]=0,e[2]=0,e)}const k=u,j=h,U=c,N=x,X=_,Y=o,H=v;Object.freeze(Object.defineProperty({__proto__:null,abs:d,add:a,angle:function(e,t){b(L,e),b(B,t);let n=P(L,B);return n>1?0:n<-1?Math.PI:Math.acos(n)},bezier:function(e,t,n,r,i,o){let s=1-o,l=s*s,a=o*o,u=l*s,h=3*o*l,c=3*a*s,d=a*o;return e[0]=t[0]*u+n[0]*h+r[0]*c+i[0]*d,e[1]=t[1]*u+n[1]*h+r[1]*c+i[1]*d,e[2]=t[2]*u+n[2]*h+r[2]*c+i[2]*d,e},ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e},clamp:function(e,t=0,n=1){return e[0]=Math.min(Math.max(e[0],t),n),e[1]=Math.min(Math.max(e[1],t),n),e[2]=Math.min(Math.max(e[2],t),n),e},copy:s,cross:I,crossAndNormalize:function(e,t,n){let r=t[0],i=t[1],o=t[2],s=n[0],l=n[1],a=n[2],u=i*a-o*l,h=o*s-r*a,c=r*l-i*s,d=Math.sqrt(u*u+h*h+c*c);return e[0]=u/d,e[1]=h/d,e[2]=c/d,e},direction:Z,dist:N,distance:x,div:U,divide:c,dot:P,equals:E,exactEquals:T,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e},hermite:function(e,t,n,r,i,o){let s=o*o,l=s*(2*o-3)+1,a=s*(o-2)+o,u=s*(o-1),h=s*(3-2*o);return e[0]=t[0]*l+n[0]*a+r[0]*u+i[0]*h,e[1]=t[1]*l+n[1]*a+r[1]*u+i[1]*h,e[2]=t[2]*l+n[2]*a+r[2]*u+i[2]*h,e},inverse:M,len:Y,length:o,lerp:C,max:f,min:m,mul:j,multiply:h,negate:w,normalize:b,random:function(e,t=1){let n=i.Ov,r=2*n()*Math.PI,o=2*n()-1,s=Math.sqrt(1-o*o)*t;return e[0]=Math.cos(r)*s,e[1]=Math.sin(r)*s,e[2]=o*t,e},rotateX:function(e,t,n,r){let i=[],o=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[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),e[0]=o[0]+n[0],e[1]=o[1]+n[1],e[2]=o[2]+n[2],e},rotateY:function(e,t,n,r){let i=[],o=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[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),e[0]=o[0]+n[0],e[1]=o[1]+n[1],e[2]=o[2]+n[2],e},rotateZ:function(e,t,n,r){let i=[],o=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[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],e[0]=o[0]+n[0],e[1]=o[1]+n[1],e[2]=o[2]+n[2],e},round:function(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e},scale:g,scaleAndAdd:y,scaleTo:function(e,t){return g(e,e,t/Y(e))},set:l,sign:p,sqrDist:X,sqrLen:H,squaredDistance:_,squaredLength:v,str:function(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"},sub:k,subtract:u,transformMat3:R,transformMat4:A,transformMat4Z:function(e,t){return t[2]*e[0]+t[6]*e[1]+t[10]*e[2]+t[14]},transformQuat:S,transformQuatValues:O},Symbol.toStringTag,{value:"Module"})),n.d(t,["Il",0,Y,"jb",0,k,"lo",0,X,"uE",0,H])},75503(e,t,n){n.d(t,{wq:()=>l});var r=n(4576),i=n(21818),o=(n(44208),n(15142)),s=n(11006);class l{constructor(e=9,t){this._compareMinX=d,this._compareMinY=p,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),w.prune(),M.prune(),b.prune(),P.prune()}all(e){a(this._data,e)}search(e,t){let n=this._data,r=this._toBBox;if(_(e,n))for(w.clear();n;){for(let i=0,o=n.children.length;i<o;i++){let o=n.children[i],s=n.leaf?r(o):o;_(e,s)&&(n.leaf?t(o):x(e,s)?a(o,t):w.push(o))}n=w.pop()}}collides(e){let t=this._data,n=this._toBBox;if(!_(e,t))return!1;for(w.clear();t;){for(let r=0,i=t.children.length;r<i;r++){let i=t.children[r],o=t.leaf?n(i):i;if(_(e,o)){if(t.leaf||x(e,o))return!0;w.push(i)}}t=w.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,n=e.length;t<n;t++)this.insert(e[t]);return this}let t=this._build(e.slice(),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){let e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new A([]),this}remove(e){if(!e)return this;let t,n=this._data,o=null,s=0,l=!1,a=this._toBBox(e);for(b.clear(),P.clear();n||b.length>0;){if(n||(n=b.pop(),o=b.data[b.length-1],s=P.pop()??0,l=!0),n.leaf&&(t=(0,r.qh)(n.children,(0,i.z)(e),n.children.length,n.indexHint),-1!==t))return n.children.splice(t,1),b.push(n),this._condense(b),this;l||n.leaf||!x(n,a)?o?(s++,n=o.children[s],l=!1):n=null:(b.push(n),P.push(s),s=0,o=n,n=n.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,n,r){let i=n-t+1,o=this._maxEntries;if(i<=o){let r=new A(e.slice(t,n+1));return u(r,this._toBBox),r}r||(r=Math.ceil(Math.log(i)/Math.log(o)),o=Math.ceil(i/o**(r-1)));let s=new R([]);s.height=r;let l=Math.ceil(i/o),a=l*Math.ceil(Math.sqrt(o));v(e,t,n,a,this._compareMinX);for(let i=t;i<=n;i+=a){let t=Math.min(i+a-1,n);v(e,i,t,l,this._compareMinY);for(let n=i;n<=t;n+=l){let i=Math.min(n+l-1,t);s.children.push(this._build(e,n,i,r-1))}}return u(s,this._toBBox),s}_insert(e,t,n){let r=this._toBBox,i=n?e:r(e);b.clear();let o=function(e,t,n,r){for(;r.push(t),!0!==t.leaf&&r.length-1!==n;){let n,r=1/0,i=1/0;for(let o=0,s=t.children.length;o<s;o++){let s=t.children[o],l=m(s),a=g(e,s)-l;a<i?(i=a,r=l<r?l:r,n=s):a===i&&l<r&&(r=l,n=s)}t=n||t.children[0]}return t}(i,this._data,t,b);for(o.children.push(e),c(o,i);t>=0&&b.data[t].children.length>this._maxEntries;)this._split(b,t),t--;!function(e,t,n){for(let r=n;r>=0;r--)c(t.data[r],e)}(i,b,t)}_split(e,t){let n=e.data[t],r=n.children.length,i=this._minEntries;this._chooseSplitAxis(n,i,r);let o=this._chooseSplitIndex(n,i,r);if(!o)return;let s=n.children.splice(o,n.children.length-o),l=n.leaf?new A(s):new R(s);l.height=n.height,u(n,this._toBBox),u(l,this._toBBox),t?e.data[t-1].children.push(l):this._splitRoot(n,l)}_splitRoot(e,t){this._data=new R([e,t]),this._data.height=e.height+1,u(this._data,this._toBBox)}_chooseSplitIndex(e,t,n){let r,i,o;r=i=1/0;for(let s=t;s<=n-t;s++){let t=h(e,0,s,this._toBBox),l=h(e,s,n,this._toBBox),a=y(t,l),u=m(t)+m(l);a<r?(r=a,o=s,i=u<i?u:i):a===r&&u<i&&(i=u,o=s)}return o}_chooseSplitAxis(e,t,n){let r=e.leaf?this._compareMinX:d,i=e.leaf?this._compareMinY:p;this._allDistMargin(e,t,n,r)<this._allDistMargin(e,t,n,i)&&e.children.sort(r)}_allDistMargin(e,t,n,r){e.children.sort(r);let i=this._toBBox,o=h(e,0,t,i),s=h(e,n-t,n,i),l=f(o)+f(s);for(let r=t;r<n-t;r++){let t=e.children[r];c(o,e.leaf?i(t):t),l+=f(o)}for(let r=n-t-1;r>=t;r--){let t=e.children[r];c(s,e.leaf?i(t):t),l+=f(s)}return l}_condense(e){for(let t=e.length-1;t>=0;t--){let n=e.data[t];if(0===n.children.length)if(t>0){let i=e.data[t-1],o=i.children;o.splice((0,r.qh)(o,n,o.length,i.indexHint),1)}else this.clear();else u(n,this._toBBox)}}_initFormat(e){let t=["return a"," - b",";"];this._compareMinX=Function("a","b",t.join(e[0])),this._compareMinY=Function("a","b",t.join(e[1])),this._toBBox=Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function a(e,t){let n=e;for(M.clear();n;){if(!0===n.leaf)for(let e of n.children)t((0,i.z)(e));else M.pushArray(n.children);n=M.pop()??null}}function u(e,t){h(e,0,e.children.length,t,e)}function h(e,t,n,r,i){i||=new A([]),i.minX=1/0,i.minY=1/0,i.maxX=-1/0,i.maxY=-1/0;for(let o,s=t;s<n;s++)o=e.children[s],c(i,e.leaf?r(o):o);return i}function c(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function d(e,t){return e.minX-t.minX}function p(e,t){return e.minY-t.minY}function m(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function f(e){return e.maxX-e.minX+(e.maxY-e.minY)}function g(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function y(e,t){let n=Math.max(e.minX,t.minX),r=Math.max(e.minY,t.minY),i=Math.min(e.maxX,t.maxX),o=Math.min(e.maxY,t.maxY);return Math.max(0,i-n)*Math.max(0,o-r)}function x(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function _(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function v(e,t,n,r,i){let o=[t,n];for(;o.length;){let t=o.pop(),n=o.pop();if(t-n<=r)continue;let l=n+Math.ceil((t-n)/r/2)*r;(0,s.q)(e,l,n,t,i),o.push(n,l,l,t)}}const w=new o.A,M=new o.A,b=new o.A,P=new o.A({deallocator:void 0});class I{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class C extends I{constructor(){super(...arguments),this.height=1,this.indexHint=new r.vW}}class A extends C{constructor(e){super(),this.children=e,this.leaf=!0}}class R extends C{constructor(e){super(),this.children=e,this.leaf=!1}}},16494(e,t,n){var r=n(76361);const i=["dd","dl","dt","h1","h2","h3","h4","h5","h6","sub","sup",..."animate.animatetransform.circle.clippath.defs.ellipse.g.image.line.lineargradient.marker.mask.path.pattern.polygon.polyline.radialgradient.rect.stop.svg.switch.symbol.text.textpath.tspan.use".split(".")].reduce((e,t)=>(e[t]=[],e),{}),o="align.alink.alt.bgcolor.border.cellpadding.cellspacing.class.color.cols.colspan.coords.d.dir.face.height.hspace.ismap.lang.marginheight.marginwidth.multiple.nohref.noresize.noshade.nowrap.ref.rel.rev.rows.rowspan.scrolling.shape.span.summary.tabindex.title.usemap.valign.value.vlink.vspace.width".split("."),s=new r.I({whiteList:i,onTagAttr:(e,t,n)=>{let r=`${t}="${n}"`;if(o.includes(t))return r},stripIgnoreTag:!0,stripIgnoreTagBody:["script","style"]},!0),l=new r.I({whiteList:{br:[]},stripIgnoreTag:!0,escapeHtml:e=>e},!1);n.d(t,["Nd",0,l,"W5",0,s])},90629(e,t,n){n.d(t,{Lz:()=>s,PN:()=>l,cr:()=>a,gs:()=>h,r_:()=>c,tc:()=>u}),n(39829);const r=/^-?(\d+(\.\d+)?)\s*((px)|(pt))?$/i,i=l(1),o=s(1);function s(e){return e?e/72*96:0}function l(e){return e?72*e/96:0}function a(e){if("string"==typeof e){let t=e.match(r);if(t){let n=Number(t[1]),r=t[3]&&t[3].toLowerCase(),i=e.startsWith("-"),o="px"===r?l(n):n;return i?-o:o}return console.warn("screenUtils.toPt: input not recognized!"),null}return e}function u(e=0,t=0){return{x:e,y:t}}function h(e=0,t=0){return[e,t]}function c(e=0,t=0,n=0){return[e,t,n]}n.d(t,["L7",0,o,"ps",0,i])},13069(e,t,n){n.d(t,{AG:()=>l,lk:()=>i,vD:()=>s,yS:()=>o});const r="randomUUID"in crypto;function i(){if(r)return crypto.randomUUID();let e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;let t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function o(){return`{${i().toUpperCase()}}`}function s(){return`{${i()}}`}function l(e){let t=e.toUpperCase();return e.startsWith("{")?t:`{${t}}`}},80754(e,t,n){n.d(t,{kS:()=>u,kd:()=>a});var r=n(82799),i=n(16930),o=n(60408),s=n(52006);const l={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 a(e,t){return Math.ceil((e-t)/(2*t))}function u(e,t){if((0,s.Ed)(e))for(let n of function(e){return(0,o.Bi)(e)?e.curveRings:e.curvePaths}(e))for(let e of n)if((0,s.aO)(e)){let[n,r]=e.c;n[0]+=t,r[0]+=t}else if((0,s.FG)(e)){let[n,r]=e.a;n[0]+=t,r[0]+=t}else if((0,s.n1)(e)){let[n,r,i]=e.b;n[0]+=t,r[0]+=t,i[0]+=t}else e[0]+=t;for(let n of function(e){return(0,o.Bi)(e)?e.rings:e.paths}(e))for(let e of n)e[0]+=t;return e}n.d(t,["j7",0,l])},89056(e,t,n){n.d(t,{b3:()=>c,jZ:()=>h});var r=n(12195),i=n(19419),o=n(537),s=n(95108),l=n(60408),a=n(80754),u=n(21325);function h(e){return d(e,!0)}function c(e){return d(e,!1)}function d(e,t){if(null==e)return null;let n=e.spatialReference,i=(0,u.Vp)(n),s=(0,r.W)(e)?e.toJSON():e;if(!i)return s;let h=(0,u.K8)(n)?102100:4326,c=a.j7[h].maxX,d=a.j7[h].minX;if((0,l.fT)(s))return m(s,c,d);if((0,l.U9)(s))return s.points=s.points.map(e=>m(e,c,d)),s;if((0,l.ZC)(s))return p(s,i);if((0,l.Bi)(s)||(0,l.Rg)(s)){let e=(0,o.Rg)(v,s),n={xmin:e[0],ymin:e[1],xmax:e[2],ymax:e[3]},r=(0,a.kd)(n.xmin,d),i=2*c*r,l=0===i?s:(0,a.kS)(s,i);return n.xmin+=i,n.xmax+=i,n.xmax>c?x(l,c,t):n.xmin<d?x(l,d,t):l}return s}function p(e,t){if(!t)return e;let n=function(e,t){let n=[],{ymin:r,ymax:i,xmin:o,xmax:s}=e,l=e.xmax-e.xmin,[a,u]=t.valid,{x:h,frameId:c}=f(e.xmin,t),{x:d,frameId:p}=f(e.xmax,t),m=h===d&&l>0;if(l>2*u){let e={xmin:o<s?h:d,ymin:r,xmax:u,ymax:i},t={xmin:a,ymin:r,xmax:o<s?d:h,ymax:i},l={xmin:0,ymin:r,xmax:u,ymax:i},m={xmin:a,ymin:r,xmax:0,ymax:i},f=[],y=[];g(e,l)&&f.push(c),g(e,m)&&y.push(c),g(t,l)&&f.push(p),g(t,m)&&y.push(p);for(let e=c+1;e<p;e++)f.push(e),y.push(e);n.push(new _(e,[c]),new _(t,[p]),new _(l,f),new _(m,y))}else h>d||m?n.push(new _({xmin:h,ymin:r,xmax:u,ymax:i},[c]),new _({xmin:a,ymin:r,xmax:d,ymax:i},[p])):n.push(new _({xmin:h,ymin:r,xmax:d,ymax:i},[c]));return n}(e,t).map(e=>e.extent);return n.length<2?n[0]||e:n.length>2?(e.xmin=t.valid[0],e.xmax=t.valid[1],e):{rings:n.map(e=>[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]])}}function m(e,t,n){if(Array.isArray(e)){let r=e[0];if(r>t){let n=(0,a.kd)(r,t);e[0]=r+-2*t*n}else if(r<n){let t=(0,a.kd)(r,n);e[0]=r+-2*n*t}}else{let r=e.x;if(r>t){let n=(0,a.kd)(r,t);e.x+=-2*t*n}else if(r<n){let t=(0,a.kd)(r,n);e.x+=-2*n*t}}return e}function f(e,t){let n,[r,i]=t.valid,o=2*i,s=0;return e>i?(n=Math.ceil(Math.abs(e-i)/o),e-=n*o,s=n):e<r&&(n=Math.ceil(Math.abs(e-r)/o),e+=n*o,s=-n),{x:e,frameId:s}}function g(e,t){let{xmin:n,ymin:r,xmax:i,ymax:o}=t;return y(e,n,r)&&y(e,n,o)&&y(e,i,o)&&y(e,i,r)}function y(e,t,n){return t>=e.xmin&&t<=e.xmax&&n>=e.ymin&&n<=e.ymax}function x(e,t,n=!0){let r=!(0,l.Rg)(e);if(r&&(0,s.m3)(e),n)return(new w).cut(e,t);let i=r?e.rings:e.paths,o=r?4:2,a=i.length,u=-2*t;for(let e=0;e<a;e++){let t=i[e];if(t&&t.length>=o){let e=[];for(let[n,...r]of t)e.push([n+u,...r]);i.push(e)}}return r?e.rings=i:e.paths=i,e}class _{constructor(e,t){this.extent=e,this.frameIds=t}}const v=(0,i.vt)();class w{constructor(){this._linesIn=[],this._linesOut=[]}cut(e,t){let n;if(this._xCut=t,e.rings)this._closed=!0,n=e.rings,this._minPts=4;else{if(!e.paths)return null;this._closed=!1,n=e.paths,this._minPts=2}for(let e of n){if(!e||e.length<this._minPts)continue;let t=!0;for(let n of e)t?(this.moveTo(n),t=!1):this.lineTo(n);this._closed&&this.close()}this._pushLineIn(),this._pushLineOut(),n=[];for(let e of this._linesIn)e&&e.length>=this._minPts&&n.push(e);let r=-2*this._xCut;for(let e of this._linesOut)if(e&&e.length>=this._minPts){for(let t of e)t[0]+=r;n.push(e)}return this._closed?e.rings=n:e.paths=n,e}moveTo(e){this._pushLineIn(),this._pushLineOut(),this._prevSide=this._side(e[0]),this._moveTo(e,this._prevSide),this._prevPt=e,this._firstPt=e}lineTo(e){let t=this._side(e[0]);if(t*this._prevSide===-1){let n=this._intersect(this._prevPt,e);this._lineTo(n,0),this._prevSide=0,this._lineTo(e,t)}else this._lineTo(e,t);this._prevSide=t,this._prevPt=e}close(){let e=this._firstPt,t=this._prevPt;(e[0]!==t[0]||e[1]!==t[1])&&this.lineTo(e),this._checkClosingPt(this._lineIn),this._checkClosingPt(this._lineOut)}_moveTo(e,t){this._closed?(this._lineIn.push(M(e,t<=0?e[0]:this._xCut)),this._lineOut.push(M(e,t>=0?e[0]:this._xCut))):(t<=0&&this._lineIn.push(e.slice()),t>=0&&this._lineOut.push(e.slice()))}_lineTo(e,t){this._closed?(b(this._lineIn,e,t<=0?e[0]:this._xCut),b(this._lineOut,e,t>=0?e[0]:this._xCut)):t<0?(0===this._prevSide&&this._pushLineOut(),this._lineIn.push(e.slice())):t>0?(0===this._prevSide&&this._pushLineIn(),this._lineOut.push(e.slice())):this._prevSide<0?(this._lineIn.push(e.slice()),this._lineOut.push(e.slice())):this._prevSide>0&&(this._lineOut.push(e.slice()),this._lineIn.push(e.slice()))}_checkClosingPt(e){let t=e.length;t>3&&e[0][0]===this._xCut&&e[t-2][0]===this._xCut&&e[1][0]===this._xCut&&(e[0]=e[t-2].slice(),e.pop())}_side(e){return e<this._xCut?-1:+(e>this._xCut)}_intersect(e,t){let n=(this._xCut-e[0])/(t[0]-e[0]),r=[this._xCut,e[1]+n*(t[1]-e[1])],i=Math.min(e.length,t.length);for(let o=2;o<i;o++)r.push(e[o]+n*(t[o]-e[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 M(e,t){let n=e.slice();return n[0]=t,n}function b(e,t,n){let r=e.length;r>1&&e[r-1][0]===n&&e[r-2][0]===n?e[r-1]=M(t,n):e.push(M(t,n))}},90182(e,t,n){n.r(t),n.d(t,{default:()=>nt});var r=n(32198),i=n(7762),o=n(49186),s=n(53966),l=n(25728),a=n(17676),u=n(91429),h=n(16930),c=n(4146),d=n(63074),p=n(34287),m=n(8303),f=n(25036),g=n(69540),y=n(25482),x=n(77690),_=n(29242),v=n(37585),w=n(35522);const M=(0,n(51850).vt)(),b=(0,_.vt)(),P=(0,_.vt)(),I=(0,_.vt)();function C(e,t,n){return(0,w.hZ)(M,t[0],t[1],1),(0,w.ei)(M,M,(0,x.mg)(b,n)),0===M[2]?(0,v.hZ)(e,M[0],M[1]):(0,v.hZ)(e,M[0]/M[2],M[1]/M[2])}function A(e,t,n){return R(P,t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7]),R(I,n[0],n[1],n[2],n[3],n[4],n[5],n[6],n[7]),(0,x.lw)(e,(0,x.KC)(P,P),I),0!==e[8]&&(e[0]/=e[8],e[1]/=e[8],e[2]/=e[8],e[3]/=e[8],e[4]/=e[8],e[5]/=e[8],e[6]/=e[8],e[7]/=e[8],e[8]/=e[8]),e}function R(e,t,n,r,i,o,s,l,a){(0,x.hZ)(e,t,r,o,n,i,s,1,1,1),(0,w.hZ)(M,l,a,1),(0,x.KC)(b,e);let[u,h,c]=(0,w.ei)(M,M,(0,x.mg)(b,b));return(0,x.hZ)(b,u,0,0,0,h,0,0,0,c),(0,x.lw)(e,b,e)}var S=n(90629),O=n(48163),L=n(86738),B=n(39829),T=n(99917),E=n(56560);const Z=e=>{let t=e;return class extends t{projectOrWarn(e,t){if(null==e)return e;let{geometry:n,pending:r}=(0,T.projectOrLoad)(e,t);return r?null:r||n?n:(s.A.getLogger(this).warn("geometry could not be projected to the spatial reference",{georeference:this,geometry:e,sourceSpatialReference:e.spatialReference,targetSpatialReference:t}),null)}}};var k=n(36005),j=n(43937);const U=(0,_.vt)(),N=(0,O.vt)();let X=class extends y.o{};(0,r.Cg)([(0,u.MZ)({type:Number,json:{write:{isRequired:!0}}})],X.prototype,"x",void 0),(0,r.Cg)([(0,u.MZ)({type:Number,json:{write:{isRequired:!0}}})],X.prototype,"y",void 0),X=(0,r.Cg)([(0,u.$K)("esri.layers.support.ControlPointsGeoreference.ControlPointJSONType")],X);let Y=class extends((0,y.T)(Z(g.Pw))){constructor(e){super(e),this.height=0,this.type="control-points",this.width=0}get controlPoints(){return this._get("controlPoints")??null}set controlPoints(e){this._set("controlPoints",e)}readControlPoints(e,t){let n=h.A.fromJSON(t.spatialReference),r=(0,_.fA)(...t.coefficients,1);return e.map(e=>((0,v.hZ)(N,e.x,e.y),C(N,N,r),{sourcePoint:e,mapPoint:new L.A({x:N[0],y:N[1],spatialReference:n})}))}writeControlPoints(e,t,n,r){if(null==this.transform){let e=new o.A("web-document-write:invalid-georeference","Invalid 'controlPoints', 'width', 'height' configuration. Make sure the parent media element is loaded i.e. the ImageElement or VideoElement set as 'MediaLayer.source'.",{layer:r?.layer,georeference:this});r?.messages?r.messages.push(e):s.A.getLogger(this).error(e.name,e.message)}else null!=e&&H(e[0])&&(t.controlPoints=e.map(e=>{let t=e.sourcePoint;return{x:t.x,y:t.y}}),t.spatialReference=e[0].mapPoint.spatialReference.toJSON(),t.coefficients=this.transform.slice(0,8))}get coords(){if(null==this.controlPoints)return null;let e=this._updateTransform(U);if(null==e||!H(this.controlPoints[0]))return null;let t=this.controlPoints[0].mapPoint.spatialReference;return function(e,t,n,r){let i=(0,O.fA)(0,n),o=(0,O.fA)(0,0),s=(0,O.fA)(t,0),l=(0,O.fA)(t,n);return C(i,i,e),C(o,o,e),C(s,s,e),C(l,l,e),new B.A({rings:[[i,o,s,l,i]],spatialReference:r})}(e,this.width,this.height,t)}set coords(e){if(null==this.controlPoints||!H(this.controlPoints[0]))return;let t=this.controlPoints[0].mapPoint.spatialReference;if(null==(e=this.projectOrWarn(e,t)))return;let{width:n,height:r}=this,{rings:[[i,o,s,l]]}=e,a=new E.A({sourcePoint:(0,S.tc)(0,r),mapPoint:new L.A({x:i[0],y:i[1],spatialReference:t})}),u=new E.A({sourcePoint:(0,S.tc)(0,0),mapPoint:new L.A({x:o[0],y:o[1],spatialReference:t})}),h=new E.A({sourcePoint:(0,S.tc)(n,0),mapPoint:new L.A({x:s[0],y:s[1],spatialReference:t})}),c=new E.A({sourcePoint:(0,S.tc)(n,r),mapPoint:new L.A({x:l[0],y:l[1],spatialReference:t})});H(a)&&H(u)&&H(h)&&H(c)&&(Q(U,a,u,h,c),this.controlPoints=this.controlPoints.map(({sourcePoint:e})=>((0,v.hZ)(N,e.x,e.y),C(N,N,U),{sourcePoint:e,mapPoint:new L.A({x:N[0],y:N[1],spatialReference:t})})))}get inverseTransform(){return null==this.transform?null:(0,x.B8)((0,_.vt)(),this.transform)}get transform(){return this._updateTransform()}toMap(e){if(null==e||null==this.transform||null==this.controlPoints||!H(this.controlPoints[0]))return null;(0,v.hZ)(N,e.x,e.y);let t=this.controlPoints[0].mapPoint.spatialReference;return C(N,N,this.transform),new L.A({x:N[0],y:N[1],spatialReference:t})}toSource(e){if(null==e||null==this.inverseTransform||null==this.controlPoints||!H(this.controlPoints[0]))return null;let t=this.controlPoints[0].mapPoint.spatialReference;return e=e.normalize(),null==(e=(0,T.projectOrLoad)(e,t).geometry)?null:((0,v.hZ)(N,e.x,e.y),C(N,N,this.inverseTransform),(0,S.tc)(N[0],N[1]))}toSourceNormalized(e){let t=this.toSource(e);return null!=t&&(t.x/=this.width,t.y/=this.height),t}_updateTransform(e){let{controlPoints:t,width:n,height:r}=this;if(!(null!=t&&n>0&&r>0))return null;let[i,o,s,l]=t;if(!H(i))return null;let a=i.mapPoint.spatialReference,u=this._projectControlPoint(o,a),h=this._projectControlPoint(s,a),c=this._projectControlPoint(l,a);if(!(u.valid&&h.valid&&c.valid&&H(u.controlPoint)))return null;e??=(0,_.vt)();let d=null;return d=H(h.controlPoint)&&H(c.controlPoint)?Q(e,i,u.controlPoint,h.controlPoint,c.controlPoint):H(h.controlPoint)?function(e,t,n,r){return J(q,V,t),J($,W,n),J(z,G,r),(0,v.Cc)(F,q,$,.5),(0,v.e$)(F,z,F,Math.PI),(0,v.Cc)(D,V,W,.5),(0,v.e$)(D,G,D,Math.PI),re(e,q,$,z,F,V,W,G,D)}(e,i,u.controlPoint,h.controlPoint):function(e,t,n){return J(q,V,t),J($,W,n),(0,v.e$)(z,$,q,K),(0,v.e$)(F,q,$,K),(0,v.e$)(G,W,V,-K),(0,v.e$)(D,V,W,-K),re(e,q,$,z,F,V,W,G,D)}(e,i,u.controlPoint),d.every(e=>0===e)?null:d}_projectControlPoint(e,t){if(!H(e))return{valid:!0,controlPoint:e};let{sourcePoint:n,mapPoint:r}=e,{geometry:i,pending:o}=(0,T.projectOrLoad)(r,t);return o?{valid:!1,controlPoint:null}:o||i?{valid:!0,controlPoint:new E.A({sourcePoint:n,mapPoint:i})}:(s.A.getLogger(this).warn("map point could not be projected to the spatial reference",{georeference:this,controlPoint:e,sourceSpatialReference:r.spatialReference,targetSpatialReference:t}),{valid:!1,controlPoint:null})}};function H(e){return null!=e?.sourcePoint&&null!=e.mapPoint}(0,r.Cg)([(0,u.MZ)({type:[E.A],json:{write:{allowNull:!1,isRequired:!0,target:{controlPoints:{type:[X],isRequired:!0},coefficients:{type:[Number],isRequired:!0},spatialReference:{type:h.A,isRequired:!0}}}}})],Y.prototype,"controlPoints",null),(0,r.Cg)([(0,k.w)("controlPoints")],Y.prototype,"readControlPoints",null),(0,r.Cg)([(0,j.K)("controlPoints")],Y.prototype,"writeControlPoints",null),(0,r.Cg)([(0,u.MZ)({clonable:!1})],Y.prototype,"coords",null),(0,r.Cg)([(0,u.MZ)({type:Number,nonNullable:!0,json:{write:{isRequired:!0}}})],Y.prototype,"height",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],Y.prototype,"inverseTransform",null),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],Y.prototype,"transform",null),(0,r.Cg)([(0,u.MZ)({type:Number,nonNullable:!0,json:{write:{isRequired:!0}}})],Y.prototype,"width",void 0),Y=(0,r.Cg)([(0,u.$K)("esri.layers.support.ControlPointsGeoreference")],Y);const q=(0,O.vt)(),$=(0,O.vt)(),z=(0,O.vt)(),F=(0,O.vt)(),V=(0,O.vt)(),W=(0,O.vt)(),G=(0,O.vt)(),D=(0,O.vt)(),K=Math.PI/2;function J(e,t,n){(0,v.hZ)(e,n.sourcePoint.x,n.sourcePoint.y),(0,v.hZ)(t,n.mapPoint.x,n.mapPoint.y)}function Q(e,t,n,r,i){return J(q,V,t),J($,W,n),J(z,G,r),J(F,D,i),re(e,q,$,z,F,V,W,G,D)}const ee=Array(8).fill(0),te=Array(8).fill(0);function ne(e,t,n,r,i){return e[0]=t[0],e[1]=t[1],e[2]=n[0],e[3]=n[1],e[4]=r[0],e[5]=r[1],e[6]=i[0],e[7]=i[1],e}function re(e,t,n,r,i,o,s,l,a){return A(e,ne(ee,t,n,r,i),ne(te,o,s,l,a))}var ie=n(56507),oe=n(21287),se=n(84952),le=n(13069),ae=n(92474),ue=n(64108);let he=0;const ce=e=>{let t=e,n=class extends t{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:he++})}};return n=(0,r.Cg)([(0,ue.$)("esri.core.NumericIdentifiable")],n),n};var de=n(35666),pe=n(5443),me=n(21325);const fe=(0,O.vt)();let ge=class extends(Z(g.Pw)){constructor(e){super(e),this.bottomLeft=null,this.bottomRight=null,this.topLeft=null,this.topRight=null,this.type="corners"}get coords(){let{topLeft:e,topRight:t,bottomLeft:n,bottomRight:r}=this;if(null==e||null==t||null==n||null==r)return null;let i=e.spatialReference;return t=this.projectOrWarn(t,i),n=this.projectOrWarn(n,i),r=this.projectOrWarn(r,i),null==t||null==n||null==r?null:new B.A({rings:[[[n.x,n.y],[e.x,e.y],[t.x,t.y],[r.x,r.y],[n.x,n.y]]],spatialReference:i})}set coords(e){let{topLeft:t}=this;if(null==t)return;let n=t.spatialReference;if(null==(e=this.projectOrWarn(e,n)))return;let{rings:[[r,i,o,s]]}=e;this.bottomLeft=new L.A({x:r[0],y:r[1],spatialReference:n}),this.topLeft=new L.A({x:i[0],y:i[1],spatialReference:n}),this.topRight=new L.A({x:o[0],y:o[1],spatialReference:n}),this.bottomRight=new L.A({x:s[0],y:s[1],spatialReference:n})}toSourceNormalized(e){let{topLeft:t,topRight:n,bottomRight:r,bottomLeft:i}=this;if(null==e||null==t||null==n||null==r||null==i)return null;let o=t.spatialReference;e=e.normalize();let s=(0,T.projectOrLoad)(e,o).geometry;if(null==s)return null;(0,v.hZ)(fe,s.x,s.y);let l=A((0,_.vt)(),[t.x,t.y,i.x,i.y,n.x,n.y,r.x,r.y],[0,0,0,1,1,0,1,1]);return C(fe,fe,l),(0,S.tc)(fe[0],fe[1])}};(0,r.Cg)([(0,u.MZ)({clonable:!1})],ge.prototype,"coords",null),(0,r.Cg)([(0,u.MZ)({type:L.A})],ge.prototype,"bottomLeft",void 0),(0,r.Cg)([(0,u.MZ)({type:L.A})],ge.prototype,"bottomRight",void 0),(0,r.Cg)([(0,u.MZ)({type:L.A})],ge.prototype,"topLeft",void 0),(0,r.Cg)([(0,u.MZ)({type:L.A})],ge.prototype,"topRight",void 0),ge=(0,r.Cg)([(0,u.$K)("esri.layers.support.CornersGeoreference")],ge);const ye=ge;var xe=n(34727),_e=n(34304);let ve=class extends(Z(g.Pw)){constructor(e){super(e),this.extent=null,this.rotation=0,this.type="extent-and-rotation"}get coords(){if(null==this.extent)return null;let e,{xmin:t,ymin:n,xmax:r,ymax:i,spatialReference:o}=this.extent;if(this.rotation){let{x:o,y:s}=this.extent.center,l=we(o,s,this.rotation);e=[l(t,n),l(t,i),l(r,i),l(r,n)],e.push(e[0])}else e=[[t,n],[t,i],[r,i],[r,n],[t,n]];return new B.A({rings:[e],spatialReference:o})}set coords(e){if(null==e||null==this.extent)return;let t=this.extent.spatialReference;if(e=this.projectOrWarn(e,t),null==e?.extent)return;let{rings:[[n,r,i]],extent:{center:{x:o,y:s}}}=e,l=(0,xe.KJ)(Math.PI/2-Math.atan2(r[1]-n[1],r[0]-n[0])),a=we(o,s,-l),[u,h]=a(n[0],n[1]),[c,d]=a(i[0],i[1]);this.extent=new pe.A({xmin:u,ymin:h,xmax:c,ymax:d,spatialReference:t}),this.rotation=l}toSourceNormalized(e){let{extent:t,rotation:n}=this;if(null==e||null==t)return null;let{xmin:r,ymin:i,xmax:o,ymax:s,center:l,spatialReference:a}=t;e=e.normalize();let u=(0,T.projectOrLoad)(e,a).geometry;if(null==u)return null;let h=u.x,c=u.y;return n&&([h,c]=we(l.x,l.y,-n)(h,c)),(0,S.tc)((0,xe.hs)(h,r,o,0,1),(0,xe.hs)(c,s,i,0,1))}};function we(e,t,n){let r=(0,_e.DF)(n),i=Math.cos(r),o=Math.sin(r);return(n,r)=>[i*(n-e)+o*(r-t)+e,i*(r-t)-o*(n-e)+t]}function Me(e,t){let n=(0,de.aB)(t);return function(e){return"media"===e?.type}(e)&&!!e.portalItem&&null!=n&&n>3}function be(e,t,n){return{enabled:!Me(n?.layer,n?.origin),ignoreOrigin:!0}}(0,r.Cg)([(0,u.MZ)({clonable:!1})],ve.prototype,"coords",null),(0,r.Cg)([(0,u.MZ)({type:pe.A})],ve.prototype,"extent",void 0),(0,r.Cg)([(0,u.MZ)({type:Number})],ve.prototype,"rotation",void 0),ve=(0,r.Cg)([(0,u.$K)("esri.layers.support.ExtentAndRotationGeoreference")],ve);const Pe={json:{name:"url",type:String,write:{overridePolicy:be}}},Ie={readOnly:!0,json:{read:!1,write:{target:"mediaType",overridePolicy:be}}},Ce={types:{key:"type",base:null,typeMap:{"control-points":Y,corners:ye,"extent-and-rotation":ve}},json:{types:{key:"type",base:null,typeMap:{"control-points":Y}},write:{overridePolicy:()=>({enabled:!0,ignoreOrigin:!0})}}};var Ae=n(59923);let Re=class extends(ce((0,l.M)(ae.x_))){constructor(e){super(e),this.georeference=null,this.opacity=1}readGeoreference(e){return Y.fromJSON(e)}writeGeoreference(e,t,n,r){let i=r?.resources?.pendingOperations,o=()=>{let i=function(e,t,n){if(!e||"control-points"===e.type)return e;let{coords:r}=e;if(5!==r?.rings[0]?.length)return null;let[i,o,s,l]=r.rings[0],{spatialReference:a}=r;return new Y({controlPoints:[new E.A({mapPoint:new L.A({x:i[0],y:i[1],spatialReference:a}),sourcePoint:(0,S.tc)(0,n)}),new E.A({mapPoint:new L.A({x:o[0],y:o[1],spatialReference:a}),sourcePoint:(0,S.tc)(0,0)}),new E.A({mapPoint:new L.A({x:s[0],y:s[1],spatialReference:a}),sourcePoint:(0,S.tc)(t,0)}),new E.A({mapPoint:new L.A({x:l[0],y:l[1],spatialReference:a}),sourcePoint:(0,S.tc)(t,n)})],width:t,height:n})}(this.georeference,this.contentWidth,this.contentHeight);if(i){if("control-points"!==e.type&&s.A.getLogger(this).warn(`only georeference of type 'control-points' may be persisted. The georeference of type '${e.type}' has been automatically converted.`),4!==i.controlPoints?.length)return void(0,Ae.qt)(r,"ControlPointsGeoreference.controlPoints","only 'control-points' georeference with 4 control points may be persisted.");t[n]=i.write({},r)}};"control-points"!==e.type&&!this.loaded&&i?(t[n]={},i.push(this.load().then(o))):o()}get contentWidth(){return 0}get contentHeight(){return 0}toSource(e){let{georeference:t,contentWidth:n,contentHeight:r}=this;if(null==e||null==t||0===n||0===r)return null;let i=t.toSourceNormalized(e);return null==i?null:(i.x*=n,i.y*=r,i)}};(0,r.Cg)([(0,u.MZ)(Ce)],Re.prototype,"georeference",void 0),(0,r.Cg)([(0,k.w)("georeference")],Re.prototype,"readGeoreference",null),(0,r.Cg)([(0,j.K)("georeference")],Re.prototype,"writeGeoreference",null),(0,r.Cg)([(0,u.MZ)({json:{read:!1,write:!1}})],Re.prototype,"opacity",void 0),Re=(0,r.Cg)([(0,u.$K)("esri.layers.support.MediaElementBase")],Re);var Se=n(85648);const Oe=Symbol("ImageElementInstance"),Le=Symbol("VideoElementInstance");function Be(e){return"object"==typeof e&&!!e&&Oe in e}function Te(e){return Be(e)||function(e){return"object"==typeof e&&!!e&&Le in e}(e)}var Ee,Ze=n(97159);let ke=class extends Re{static{Ee=Oe}constructor(e){super(e),this.animationOptions=null,this.content=null,this.image=null,this.type="image",this[Ee]=!0,this.image=null}load(){let e=this.image;if("string"==typeof e){let t=(0,oe.M5)(e).then(e=>{this._set("content",e)});this.addResolvingPromise(t)}else if(e instanceof HTMLImageElement){let t=e.decode().then(()=>{this._set("content",e)});this.addResolvingPromise(t)}else e?this._set("content",e):this.addResolvingPromise(Promise.reject(new o.A("image-element:invalid-image-type","Invalid image type",{image:e})));return Promise.resolve(this)}get contentWidth(){return null==this.content?0:this.content instanceof HTMLImageElement?this.content.naturalWidth:this.content.width}get contentHeight(){return null==this.content?0:this.content instanceof HTMLImageElement?this.content.naturalHeight:this.content.height}readImage(e,t,n){return(0,Ze.f)(t.url,n)}writeImage(e,t,n,r){if(null==e)return;let i=r?.portalItem,o=r?.resources;if(!i||!o)return void("string"==typeof e&&(t[n]=(0,Ze.t)(e,r)));let s=function(e){return"string"==typeof e&&!(0,se.DB)(e)&&!(0,se.w8)(e)}(e)?e:null;if(s){if(null==(0,Ze.i)(s))return void(t[n]=s);let e=(0,Ze.t)(s,{...r,verifyItemRelativeUrls:r?.verifyItemRelativeUrls?{writtenUrls:r.verifyItemRelativeUrls.writtenUrls,rootPath:void 0}:void 0},1);if(i&&e&&!(0,se.oP)(e))return o.toKeep.push({resource:i.resourceFromPath(e),compress:!1}),void(t[n]=e)}t[n]="<pending>",o.pendingOperations.push(async function(e){return"string"==typeof e?(0,se.DB)(e)?(0,se.N9)(e):(await(0,ie.A)(e,{responseType:"blob"})).data:new Promise(t=>function(e){if(e instanceof HTMLCanvasElement)return e;let t=e instanceof HTMLImageElement?e.naturalWidth:e.width,n=e instanceof HTMLImageElement?e.naturalHeight:e.height,r=document.createElement("canvas"),i=r.getContext("2d");return r.width=t,r.height=n,e instanceof HTMLImageElement?i.drawImage(e,0,0,e.width,e.height):e instanceof ImageData&&i.putImageData(e,0,0),r}(e).toBlob(t))}(e).then(e=>{let r=function(e,t){let n=(0,le.lk)(),r=`${(0,se.fj)("media",n)}.${(0,Se.n)({type:"blob",blob:e})}`;return t.resourceFromPath(r)}(e,i);t[n]=r.itemRelativeUrl,o.toAdd.push({resource:r,content:{type:"blob",blob:e},compress:!1,finish:e=>{this.image=e.url}})}))}};(0,r.Cg)([(0,u.MZ)()],ke.prototype,"animationOptions",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],ke.prototype,"content",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],ke.prototype,"contentWidth",null),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],ke.prototype,"contentHeight",null),(0,r.Cg)([(0,u.MZ)(Pe)],ke.prototype,"image",void 0),(0,r.Cg)([(0,k.w)("image",["url"])],ke.prototype,"readImage",null),(0,r.Cg)([(0,j.K)("image")],ke.prototype,"writeImage",null),(0,r.Cg)([(0,u.MZ)(Ie)],ke.prototype,"type",void 0),ke=(0,r.Cg)([(0,u.$K)("esri.layers.support.ImageElement")],ke);var je=n(62885),Ue=n(65529),Ne=n(61893),Xe=n(36708),Ye=n(19419),He=n(12176),qe=n(6518),$e=n(69622),ze=n(89056);let Fe=class extends $e.A{constructor(e){super(e)}get bounds(){let e=this.coords;return null==e?.extent?null:(0,Ye.VY)(e.extent)}get coords(){let e=this.element.georeference?.coords;return(0,T.projectOrLoad)(e,this.spatialReference).geometry}get normalizedCoords(){return B.A.fromJSON((0,ze.jZ)(this.coords))}get normalizedBounds(){let e=null==this.normalizedCoords?null:this.normalizedCoords.extent;return null==e?null:(0,Ye.VY)(e)}};(0,r.Cg)([(0,u.MZ)()],Fe.prototype,"spatialReference",void 0),(0,r.Cg)([(0,u.MZ)()],Fe.prototype,"element",void 0),(0,r.Cg)([(0,u.MZ)()],Fe.prototype,"bounds",null),(0,r.Cg)([(0,u.MZ)()],Fe.prototype,"coords",null),(0,r.Cg)([(0,u.MZ)()],Fe.prototype,"normalizedCoords",null),(0,r.Cg)([(0,u.MZ)()],Fe.prototype,"normalizedBounds",null),Fe=(0,r.Cg)([(0,u.$K)("esri.layers.support.MediaElementView")],Fe);var Ve,We=n(16494),Ge=n(38969);const De=Symbol("canplay");let Ke=class extends Re{static{Ve=Le}constructor(e){super(e),this.autoplay=!0,this.content=null,this.type="video",this[Ve]=!0}load(){let e=this.video;return"string"==typeof e?this.addResolvingPromise(this._preProcessVideoUrl(e).then(async e=>{let t=document.createElement("video");return t.src=We.W5.sanitizeUrl((0,se.s2)(e)),t.crossOrigin="anonymous",t.autoplay=this.autoplay,t.muted=!0,t.loop=!0,t.playsInline=!0,this._loadVideo(t).then(()=>{this._set("content",t)})})):e instanceof HTMLVideoElement?this.addResolvingPromise(this._loadVideo(e).then(()=>{this._set("content",e)})):this.addResolvingPromise(Promise.reject(new o.A("video-element:invalid-video-type","Invalid video type",{video:e}))),Promise.resolve(this)}get contentWidth(){return this.content?.videoWidth??0}get contentHeight(){return this.content?.videoHeight??0}get currentTime(){return this.content?.currentTime}set currentTime(e){if(!this.content)return;let t=(0,xe.qE)(e,0,this.content.duration);"fastSeek"in this.content?this.content.fastSeek(t):this.content.currentTime=t,this.content.play().then(()=>{this.content?.pause()}).catch(()=>{})}get duration(){return this.content?.duration}set video(e){"not-loaded"===this.loadStatus?this._set("video",e):s.A.getLogger(this).error("#video","video cannot be changed after the element is loaded.")}writeVideo(e,t,n,r){if(!e)return void(r?.messages&&r.messages.push(new o.A("video-element:unsupported-video","video source is missing")));let i=function(e){return"string"==typeof e&&!(0,se.DB)(e)&&!(0,se.w8)(e)}(e)?e:null;if(!i)return void(r?.messages&&r.messages.push(new o.A("video-element:unsupported-video","video source must be an absolute url")));!(0,se.oP)(i)&&r?.blockedRelativeUrls&&r.blockedRelativeUrls.push(i);let s=(0,se.s2)(i);(0,Ze.i)(s)?r?.messages&&r.messages.push(new o.A("video-element:unsupported-video","video source cannot be an item resource")):t[n]=s}async _preProcessVideoUrl(e){if((0,se.zs)(e))return(0,se.yM)(e);try{return await(0,ie.A)(e,{method:"head"}),e}catch{try{return(0,se.yM)(e,!0)}catch{return e}}}async _loadVideo(e){"anonymous"!==e.crossOrigin&&(e.crossOrigin="anonymous",(0,se.w8)(e.src)||(e.src=e.src));try{await(0,Ge.i)(e,e=>this.addHandles(e,De)),this.autoplay&&await e.play().catch(e=>{throw console.error(e),e})}finally{this.removeHandles(De)}}};(0,r.Cg)([(0,u.MZ)()],Ke.prototype,"autoplay",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],Ke.prototype,"content",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],Ke.prototype,"contentWidth",null),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],Ke.prototype,"contentHeight",null),(0,r.Cg)([(0,u.MZ)({type:Number})],Ke.prototype,"currentTime",null),(0,r.Cg)([(0,u.MZ)({type:Number})],Ke.prototype,"duration",null),(0,r.Cg)([(0,u.MZ)(Pe)],Ke.prototype,"video",null),(0,r.Cg)([(0,j.K)("video")],Ke.prototype,"writeVideo",null),(0,r.Cg)([(0,u.MZ)(Ie)],Ke.prototype,"type",void 0),Ke=(0,r.Cg)([(0,u.$K)("esri.layers.support.VideoElement")],Ke);const Je={key:"type",defaultKeyValue:"image",base:Re,typeMap:{image:ke,video:Ke}},Qe=i.A.ofType(Je);let et=class extends((0,ae.WV)((0,Ne.g)(Ue.nJ))){constructor(e){super(e),this._index=new qe.F,this._elementViewsMap=new Map,this._elementsIndexes=new Map,this._elementsChangedHandler=e=>{for(let t of e.removed){let e=this._elementViewsMap.get(t);this._elementViewsMap.delete(t),this._index.delete(e),this.removeHandles(e),e.destroy(),this.notifyChange("fullExtent")}let{spatialReference:t}=this;for(let n of e.added){if(this._elementViewsMap.get(n))continue;let e=new Fe({spatialReference:t,element:n});this._elementViewsMap.set(n,e);let r=(0,Xe.wB)(()=>e.coords,()=>this._updateIndexForElement(e,!1));this._updateIndexForElement(e,!0),this.addHandles(r,e)}this._elementsIndexes.clear(),this.elements.forEach((e,t)=>this._elementsIndexes.set(e,t)),this.emit("refresh")},this.elements=new Qe}async load(e){if((0,a.Te)(e),!this.spatialReference){let e=this.elements.find(e=>null!=e.georeference?.coords);this._set("spatialReference",e?e.georeference.coords.spatialReference:h.A.WGS84)}return this._elementsChangedHandler({added:this.elements.items,removed:[]}),this.addHandles(this.elements.on("change",this._elementsChangedHandler)),this}destroy(){this._index.clear(),this._elementViewsMap.clear(),this._elementsIndexes.clear()}get elements(){return this._get("elements")}set elements(e){this._set("elements",(0,je.V)(e,this._get("elements"),Qe))}get fullExtent(){if("not-loaded"===this.loadStatus)return null;let e=this._index.fullBounds;return null==e?null:new pe.A({xmin:e[0],ymin:e[1],xmax:e[2],ymax:e[3],spatialReference:this.spatialReference})}set spatialReference(e){"not-loaded"===this.loadStatus?this._set("spatialReference",e):s.A.getLogger(this).error("#spatialReference","spatialReference cannot be changed after the source is loaded.")}async queryElements(e,t){await this.load(),await(0,T.initializeProjection)(e.spatialReference,this.spatialReference,null,t);let n=(0,me.aI)(e.spatialReference,this.spatialReference)?e:(0,T.project)(e,this.spatialReference);if(!n)return[];let r=n.normalize(),i=[];for(let e of r)this._index.forEachInBounds((0,Ye.VY)(e),({normalizedCoords:t,element:n})=>{null!=t&&(0,He.fA)(e,t)&&i.push(n)});return i.sort((e,t)=>this._elementsIndexes.get(e)-this._elementsIndexes.get(t)),i}hasElement(e){return this.elements.includes(e)}_updateIndexForElement(e,t){let n=e.normalizedBounds,r=this._index.has(e),i=null!=n;this._index.delete(e),i&&this._index.set(e,n),this.notifyChange("fullExtent"),t||(r===i?this.emit("change",{element:e.element}):this.emit("refresh"))}};(0,r.Cg)([(0,u.MZ)()],et.prototype,"elements",null),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],et.prototype,"fullExtent",null),(0,r.Cg)([(0,u.MZ)()],et.prototype,"spatialReference",null),et=(0,r.Cg)([(0,u.$K)("esri.layers.support.LocalMediaElementSource")],et);let tt=class extends((0,d.dM)((0,f.j)((0,p.q)((0,m.A)((0,l.M)(c.A)))))){constructor(e){super(e),this.effectiveSource=null,this.georeference=null,this.copyright=null,this.operationalLayerType="MediaLayer",this.spatialReference=null,this.type="media",this._debouncedSaveOperations=(0,a.sg)(async(e,t,r)=>{let{save:i,saveAs:o}=await n.e(3561).then(()=>n(63561));switch(e){case 0:return i(this,t);case 1:return o(this,r,t)}}),this.source=new et}load(e){return this.addResolvingPromise(this._doLoad(e)),Promise.resolve(this)}async _doLoad(e){await this.loadFromPortal({supportedTypes:["Media Layer"]},e);let t=this.source;if(!t)throw new o.A("media-layer:source-missing","Set 'MediaLayer.source' before loading the layer.");let n=this._getSourceOverride(t,this.georeference);n&&(this.setAtOrigin("source",n,"web-map"),this.setAtOrigin("source",n,"web-scene"),t=n);let r=Te(t)?new et({elements:new i.A([t])}):t;this._set("effectiveSource",r),this.spatialReference&&(r.spatialReference=this.spatialReference),await r.load(e),this.spatialReference=r.spatialReference}destroy(){this.effectiveSource?.destroy(),this.effectiveSource!==this.source&&this.source?.destroy()}readGeoreference(e,t){return e&&"itemId"in t&&t.itemId?e:void 0}get fullExtent(){return this.loaded?this.effectiveSource.fullExtent:null}get loaded(){return super.loaded}get source(){return this._get("source")}set source(e){"loaded"===this.loadStatus||"failed"===this.loadStatus?s.A.getLogger(this).error("#source","source cannot be changed after the layer is loaded."):this._set("source",e)}castSource(e){return e?Array.isArray(e)?new et({elements:new i.A(e)}):e instanceof i.A?new et({elements:e}):e:null}readSource(e,t,n){if("itemId"in t&&t.itemId)return;let r=this._createSource(t);return r?.read(t,n),r}writeSource(e,t,n,r){if(e&&e instanceof et){let t=e.elements.length;if(1!==t)return void(r?.messages&&r.messages.push(new o.A("media-layer:unsupported-source",`local media element source can only be persisted if it contains exactly one ImageElement, but it has ${t}.`)));e=e.elements.at(0)}Te(e)?e.write(t,r):r?.messages&&(e?r.messages.push(new o.A("media-layer:unsupported-source","only media elements of type 'ImageElement' or 'VideoElement' can be persisted")):r.messages.push(new o.A("media-layer:unsupported-source","the media layer is missing a source")))}async save(e){return this._debouncedSaveOperations(0,e)}async saveAs(e,t){return this._debouncedSaveOperations(1,t,e)}_createSource(e){if("mediaType"in e)switch(e.mediaType){case"image":return new ke;case"video":return new Ke}return null}_getSourceOverride(e,t){if(Te(e)&&3===this.originIdOf("source")&&t&&(5===this.originIdOf("georeference")||4===this.originIdOf("georeference"))){let n=e.toJSON(),r=this._createSource(n);return r.read({...n},{origin:"portal-item"}),r.read({georeference:t},{origin:"web-map"}),r.read({georeference:t},{origin:"web-scene"}),r}return null}};(0,r.Cg)([(0,u.MZ)({readOnly:!0})],tt.prototype,"effectiveSource",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0,json:{read:!1,write:!1,origins:{"web-document":{read:!0}}}})],tt.prototype,"georeference",void 0),(0,r.Cg)([(0,k.w)("web-document","georeference")],tt.prototype,"readGeoreference",null),(0,r.Cg)([(0,u.MZ)({type:String})],tt.prototype,"copyright",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],tt.prototype,"fullExtent",null),(0,r.Cg)([(0,u.MZ)({type:["MediaLayer"]})],tt.prototype,"operationalLayerType",void 0),(0,r.Cg)([(0,u.MZ)({type:["show","hide"]})],tt.prototype,"listMode",void 0),(0,r.Cg)([(0,u.MZ)({nonNullable:!0,json:{write:{enabled:!0,allowNull:!1,target:{url:{type:String},mediaType:{type:["image","video"]},georeference:{type:Y}},overridePolicy(e,t,n){return{enabled:!0,allowNull:!1,ignoreOrigin:Me(this,n?.origin)&&Te(e)&&!!e.georeference&&e.originIdOf("georeference")>3}}}}})],tt.prototype,"source",null),(0,r.Cg)([(0,u.wg)("source")],tt.prototype,"castSource",null),(0,r.Cg)([(0,k.w)("source",["url"])],tt.prototype,"readSource",null),(0,r.Cg)([(0,j.K)("source")],tt.prototype,"writeSource",null),(0,r.Cg)([(0,u.MZ)({type:h.A})],tt.prototype,"spatialReference",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0})],tt.prototype,"type",void 0),tt=(0,r.Cg)([(0,u.$K)("esri.layers.MediaLayer")],tt);const nt=tt},6518(e,t,n){n.d(t,{F:()=>l});var r=n(44208),i=n(75503),o=n(19419);const s={minX:0,minY:0,maxX:0,maxY:0};class l{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new i.wq(9,(0,r.A)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){let e=Array(this._idByBounds.size),t=0;this._idByBounds.forEach((n,r)=>{e[t++]=r}),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter(e=>this._idByBounds.has(e))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;let e=(0,o.Ie)();for(let t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){let t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,n){(function(e){s.minX=e[0],s.minY=e[1],s.maxX=e[2],s.maxY=e[3]})(t),e.search(s,n)}(this._index,e,e=>t(this._idByBounds.get(e)))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){let t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},8303(e,t,n){var r=n(32198),i=n(92602),o=n(70333),s=n(56507),l=n(60999),a=n(49186),u=n(36563),h=n(53966),c=n(97768),d=n(17676),p=n(84952),m=n(91429),f=n(77548),g=n(20655),y=n(80812),x=n(41318),_=n(10407),v=n(26121),w=n(36005),M=n(43937);const b={credential:null,user:null};n.d(t,["A",0,e=>{let t=e,P=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){super.destroy(),this.portalItem=(0,c.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}get portalItem(){return this._get("portalItem")}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,n){if(t.itemId)return new y.default({id:t.itemId,portal:n?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{let{load:r}=await n.e(1204).then(()=>n(41204));return(0,d.Te)(t),await r({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,d.zf)(e)||h.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async reloadFromPortal(e,t){if(!this.loaded||!this.portalItem?.id)return!1;let r=t?.signal?null:new AbortController;try{let{reload:i}=await n.e(1204).then(()=>n(41204));return r&&this.addHandles((0,u.rE)(r),"reloadFromPortal"),await i({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t?.signal?t:{signal:r.signal})}catch(e){throw(0,d.zf)(e)||h.A.getLogger(this).warn(`Failed to reload layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}finally{r&&this.removeHandles("reloadFromPortal")}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,d.QP)(e),!0)))}async setUserPrivileges(e,t){if(!i.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{let{features:{edit:n,fullEdit:r},content:{updateItem:i}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",n),this._set("userHasFullEditingPrivileges",r),this._set("userHasUpdateItemPrivileges",i)}catch(e){(0,d.QP)(e)}}async _fetchUserPrivileges(e,t){let n=this.portalItem;if(!e||!n||!n.loaded||n.sourceUrl)return this._fetchFallbackUserPrivileges(t);let r,i,s=!o.id?.findCredential(this.url),l=e===n.id;if(l&&n.portal.user)return this._getUserPrivileges(n,s);if(l)r=n.portal.url;else try{r=await(0,f.wI)(this.url,t)}catch(e){(0,d.QP)(e)}if(!r||!(0,p.b8)(r,n.portal.url))return this._fetchFallbackUserPrivileges(t);try{let e=null==t?null:t.signal;i=await(o.id?.getCredential(`${r}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,d.QP)(e)}if(!i)return{features:{edit:!0,fullEdit:!1},content:{updateItem:!1}};try{if(l?await n.reload():(n=new y.default({id:e,portal:{url:r}}),await n.load(t)),n.portal.user)return this._getUserPrivileges(n,s)}catch(e){(0,d.QP)(e)}return{features:{edit:!0,fullEdit:!1},content:{updateItem:!1}}}_getUserPrivileges(e,t){let n=(0,_.It)(e);return t&&(n.features.edit=!0),n}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,d.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){let t=this.url?o.id?.findCredential(this.url):null;if(!t)return!0;let n=b.credential===t?b.user:await this._fetchEditingUser(e);return b.credential=t,b.user=n,null==n?.privileges||n.privileges.includes("features:user:edit")}async _fetchEditingUser(e){let t=this.portalItem?.portal?.user;if(t)return t;let n=o.id?.findServerInfo(this.url??"");if(!n?.owningSystemUrl)return null;let r=`${n.owningSystemUrl}/sharing/rest`,i=g.A.getDefault();if(i&&i.loaded&&(0,p.S8)(i.restUrl)===(0,p.S8)(r))return i.user;let a=`${r}/community/self`,u=null==e?null:e.signal,h=await(0,l.Ke)((0,s.A)(a,{authMode:"no-prompt",query:{f:"json"},signal:u}));return h.ok?x.A.fromJSON(h.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){return(0,v.wN)(this.portalItem,t)?(t?.messages?.push(new a.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,r.Cg)([(0,m.MZ)({type:y.default})],P.prototype,"portalItem",null),(0,r.Cg)([(0,w.w)("web-document","portalItem",["itemId"])],P.prototype,"readPortalItem",null),(0,r.Cg)([(0,M.K)("web-document","portalItem",{itemId:{type:String}})],P.prototype,"writePortalItem",null),(0,r.Cg)([(0,m.MZ)({clonable:!1})],P.prototype,"resourceReferences",void 0),(0,r.Cg)([(0,m.MZ)({type:Boolean,readOnly:!0})],P.prototype,"userHasEditingPrivileges",void 0),(0,r.Cg)([(0,m.MZ)({type:Boolean,readOnly:!0})],P.prototype,"userHasFullEditingPrivileges",void 0),(0,r.Cg)([(0,m.MZ)({type:Boolean,readOnly:!0})],P.prototype,"userHasUpdateItemPrivileges",void 0),P=(0,r.Cg)([(0,m.$K)("esri.layers.mixins.PortalLayer")],P),P}])},38969(e,t,n){n.d(t,{i:()=>i});var r=n(37955);function i(e,t){return new Promise((n,i)=>{e.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA?n():(t((0,r.Oo)(e,"canplay",n)),t((0,r.Oo)(e,"error",i)))})}},85648(e,t,n){n.d(t,{n:()=>i});var r=n(84952);function i(e){return o[function(e){return"json"===e.type?"application/json":"blob"===e.type?e.blob.type:function(e){let t=(0,r.Zo)(e);return a[t]||s}(e.url)}(e)]||l}const o={},s="text/plain",l=o[s],a={png:"image/png",jpeg:"image/jpeg",jpg:"image/jpg",bmp:"image/bmp",gif:"image/gif",json:"application/json",txt:"text/plain",xml:"application/xml",svg:"image/svg+xml",zip:"application/zip",pbf:"application/vnd.mapbox-vector-tile",gz:"application/gzip","bin.gz":"application/octet-stream"};for(let e in a)o[a[e]]=e},26121(e,t,n){n.d(t,{I6:()=>h,ci:()=>u,dL:()=>a,wN:()=>c});var r=n(49186),i=n(84952),o=n(77548),s=n(20655),l=n(59923);async function a(e){let t=[];for(let n of e.allLayers)if("beforeSave"in n&&"function"==typeof n.beforeSave){let e=n.beforeSave();e&&t.push(e)}await Promise.allSettled(t)}function u(e,t,n){let i=(e.messages??[]).filter(({type:e})=>"error"===e).map(({name:e,message:t,details:n})=>new r.A(e,t,n));if(e.blockedRelativeUrls&&(i=i.concat(e.blockedRelativeUrls.map(e=>(0,l.GL)("url",`Relative url '${e}' is not supported`)))),n){let{ignoreUnsupported:e,supplementalUnsupportedErrors:t=[],requiredPropertyChecksDisabled:r}=n;e&&(i=i.filter(({name:e})=>!(l.MG.has(e)||t.includes(e)))),r&&(i=i.filter(e=>"web-document-write:property-required"!==e.name))}if(i.length>0)throw new r.A(t.errorName,"Failed to save due to unsupported or invalid content. See 'details.errors' for more detailed information",{errors:i})}function h(e){return(0,o.qd)(e).some(e=>!!e.charts?.length)}function c(e,t){let n=t?.portal,r=e?.id&&(e.portal||s.A.getDefault());return!!n&&!!r&&!(0,i.ut)(r.restUrl,n.restUrl)}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2867,5248],{66131(e,t,s){s.d(t,{lY:()=>d,mT:()=>m});var i=s(59534),r=s(799),n=s(3330),o=s(84741),a=s(34747);const l={TimeZoneNotRecognized:"Timezone identifier has not been recognized."};class c extends Error{constructor(e,t){super((0,r.HC)(l[e],t)),this.declaredRootClass="esri.arcade.arcadedate.dateerror",Error.captureStackTrace&&Error.captureStackTrace(this,c)}}function u(e,t,s){return e<t?e-t:e>s?e-s:0}function h(e,t,s){return e<t?t:e>s?s:e}class d{constructor(e){this._date=e,this.declaredRootClass="esri.arcade.arcadedate"}static fromParts(e=0,t=1,s=1,i=0,r=0,n=0,o=0,l){if(isNaN(e)||isNaN(t)||isNaN(s)||isNaN(i)||isNaN(r)||isNaN(n)||isNaN(o))return null;let c=a.c9.local(e,t).daysInMonth,f=a.c9.fromObject({day:h(s,1,c),year:e,month:h(t,1,12),hour:h(i,0,23),minute:h(r,0,59),second:h(n,0,59),millisecond:h(o,0,999)},{zone:m(l)});return f=f.plus({months:u(t,1,12),days:u(s,1,c),hours:u(i,0,23),minutes:u(r,0,59),seconds:u(n,0,59),milliseconds:u(o,0,999)}),new d(f)}static get systemTimeZoneCanonicalName(){return Intl.DateTimeFormat().resolvedOptions().timeZone??"system"}static arcadeDateAndZoneToArcadeDate(e,t){let s=m(t);return e.isUnknownTimeZone||s===n.GB.instance?d.fromParts(e.year,e.monthJS+1,e.day,e.hour,e.minute,e.second,e.millisecond,s):new d(e._date.setZone(s))}static dateJSToArcadeDate(e){return new d(a.c9.fromJSDate(e,{zone:"system"}))}static dateJSAndZoneToArcadeDate(e,t="system"){let s=m(t);return new d(a.c9.fromJSDate(e,{zone:s}))}static unknownEpochToArcadeDate(e){return new d(a.c9.fromMillis(e,{zone:n.GB.instance}))}static unknownDateJSToArcadeDate(e){return new d(a.c9.fromMillis(e.getTime(),{zone:n.GB.instance}))}static epochToArcadeDate(e,t="system"){let s=m(t);return new d(a.c9.fromMillis(e,{zone:s}))}static dateTimeToArcadeDate(e){return new d(e)}clone(){return new d(this._date)}changeTimeZone(e){let t=m(e);return d.dateTimeToArcadeDate(this._date.setZone(t))}static dateTimeAndZoneToArcadeDate(e,t){let s=m(t);return e.zone===n.GB.instance||s===n.GB.instance?d.fromParts(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond,s):new d(e.setZone(s))}static nowToArcadeDate(e){let t=m(e);return new d(a.c9.fromJSDate(new Date,{zone:t}))}static nowUTCToArcadeDate(){return new d(a.c9.utc())}get isSystem(){return"system"===this.timeZone||this.timeZone===d.systemTimeZoneCanonicalName}equals(e){return this.isSystem&&e.isSystem?this.toNumber()===e.toNumber():this.isUnknownTimeZone===e.isUnknownTimeZone&&this._date.equals(e._date)}get isUnknownTimeZone(){return this._date.zone===n.GB.instance}get isValid(){return this._date.isValid}get hour(){return this._date.hour}get second(){return this._date.second}get day(){return this._date.day}get dayOfWeekISO(){return this._date.weekday}get dayOfWeekJS(){let e=this._date.weekday;return e>6&&(e=0),e}get millisecond(){return this._date.millisecond}get monthISO(){return this._date.month}get weekISO(){return this._date.weekNumber}get yearISO(){return this._date.weekYear}get monthJS(){return this._date.month-1}get year(){return this._date.year}get minute(){return this._date.minute}get zone(){return this._date.zone}get timeZoneOffset(){return this.isUnknownTimeZone?0:this._date.offset}get timeZone(){if(this.isUnknownTimeZone)return"unknown";if("system"===this._date.zone.type)return"system";let e=this.zone;return"fixed"===e.type?0===e.fixed?"UTC":e.formatOffset(0,"short"):e.name}stringify(){return JSON.stringify(this.toJSDate())}plus(e){return new d(this._date.plus(e))}diff(e,t){return this._date.diff(e._date,t)[t]}toISODate(){return this._date.toISODate()}toISOString(e){return e?this._date.toISO({suppressMilliseconds:!0,includeOffset:!this.isUnknownTimeZone}):this._date.toISO({includeOffset:!this.isUnknownTimeZone})}toISOTime(e,t){return this._date.toISOTime({suppressMilliseconds:e,includeOffset:t&&!this.isUnknownTimeZone})}toFormat(e,t){return this.isUnknownTimeZone&&(e=e.replaceAll("Z","")),this._date.toFormat(e,t)}toJSDate(){return this._date.toJSDate()}toSQLValue(){return this._date.toFormat("yyyy-LL-dd HH:mm:ss")}toSQLWithKeyword(){return`timestamp '${this.toSQLValue()}'`}toDateTime(){return this._date}toNumber(){return this._date.toMillis()}getTime(){return this._date.toMillis()}toUTC(){return new d(this._date.toUTC())}toLocal(){return new d(this._date.toLocal())}toString(){return this.toISOString(!0)}static fromReaderAsTimeStampOffset(e){if(!e)return null;let t=a.c9.fromISO(e,{setZone:!0});return new d(t)}}function m(e,t=!0){if(e instanceof a.bo)return e;switch((0,i.B)(e)){case"system":return"system";case"utc":return"UTC";case"unknown":return n.GB.instance}if(/^[+-]?[0-9]{1,2}(:[0-9]{2})?$/.test(e)){let t=a.mQ.parseSpecifier("UTC"+(e.startsWith("+")||e.startsWith("-")?"":"+")+e);if(t)return t}let s=(0,o.p)(e);if(!s.isValid){if(t)throw new c("TimeZoneNotRecognized");return null}return s}},59534(e,t,s){s.d(t,{B:()=>r,b:()=>n});var i=s(85935);function r(e){return e.toLowerCase().replaceAll(/[\s-]+/g,"")}class n{constructor(e,t){let s=new Map;for(let t of e){let e=r(t);if(s.has(e))throw Error(`${t} already added as ${s.get(e)}`);s.set(e,t)}if(null!=t)for(let[e,i]of t){let t=r(e);if(s.has(t))throw Error(`${e} already associated with ${s.get(t)}`);s.set(t,i)}this._enumMap=s}lookup(e){return this._enumMap.get(r(e))}get(e){let t=this.lookup(e);if(null==t)throw new i.D$("InvalidParameter",null);return t}}},85935(e,t,s){s.d(t,{D$:()=>a,O$:()=>u,i2:()=>h,mT:()=>c,ps:()=>m});var i=s(799);const r={TypeNotAllowedInFeature:"Feature attributes only support dates, numbers, strings, guids.",LogicError:"Logic error - {reason}",CannotCompareDateAndTime:"Cannot compare date or dateonly with timeonly types",NeverReach:"Encountered unreachable logic",AsyncNotEnabled:"Async Arcade must be enabled for this script",ModuleAccessorMustBeString:"Module accessor must be a string",ModuleExportNotFound:"Module has no export with provided identifier",ModulesNotSupported:"Current profile does not support modules",ArrayAccessMustBeNumber:"Array accessor must be a number",FunctionNotFound:"Function not found",FieldNotFound:"Key not found - {key}",CircularModules:"Circular module dependencies are not allowed",Cancelled:"Execution cancelled",UnsupportedHashType:"Type not supported in hash function",IllegalResult:"Value is not a supported return type",PortalRequired:"Portal is required",InvalidParameter:"Invalid parameter",WrongNumberOfParameters:"Call with wrong number of parameters",Unrecognized:"Unrecognized code structure",UnrecognizedType:"Unrecognized type",WrongSpatialReference:"Cannot work with geometry in this spatial reference. It is different to the execution spatial reference",BooleanConditionRequired:"Conditions must use booleans",NoFunctionInDictionary:"Dictionaries cannot contain functions.",NoFunctionInArray:"Arrays cannot contain functions.",NoFunctionInTemplateLiteral:"Template Literals do not expect functions by value.",KeyAccessorMustBeString:"Accessor must be a string",KeyMustBeString:"Object keys must be a string",Immutable:"Object is immutable",UnexpectedToken:"Unexpected token",MemberOfNull:"Cannot access property of null object",MaximumCallDepth:"Exceeded maximum function depth",OutOfBounds:"Out of bounds",InvalidIdentifier:"Identifier not recognized",CallNonFunction:"Expression is not a function",InvalidMemberAccessKey:"Cannot access value using a key of this type",AssignModuleFunction:"Cannot assign function to module variable",UnsupportUnaryOperator:"Unsupported unary operator",UnsupportedOperator:"Unsupported operator",LogicalExpressionOnlyBoolean:"Logical expressions must be boolean",LogicExpressionOrAnd:"Logical expression can only be combined with || or &&",CannotChangeTimeZoneTime:"Cannot change the timezone of a Time",CannotChangeTimeZoneDateOnly:"Cannot change the timezone of a DateOnly",FeatureSetDoesNotHaveSubtypes:"FeatureSet does not have subtypes"};function n(e){return"object"==typeof e&&"line"in e&&"column"in e&&"number"==typeof e.line&&"number"==typeof e.column}class o extends Error{constructor(e,t){super(l(t)+("object"==typeof e&&e&&"message"in e?e.message:""),{cause:e}),this.loc=t?.loc??null}}class a extends Error{constructor(e,t,s){super("Execution error - "+l(t)+(0,i.HC)(r[e],s)),this.declaredRootClass="esri.arcade.arcadeexecutionerror",this.loc=t?.loc??null}}function l(e){return null==e?.loc?"":`Line ${e.loc.start.line}:${e.loc.start.column}: `}class c extends Error{constructor(e,t,s){super("Compilation error - "+l(t)+(0,i.HC)(r[e],s)),this.declaredRootClass="esri.arcade.arcadecompilationerror",this.loc=t?.loc??null}}class u extends Error{constructor(){super("Uncompilable code structures"),this.declaredRootClass="esri.arcade.arcadeuncompilableerror"}}function h(e,t){return!function(e){if(e instanceof Error&&"loc"in e){let t=e.loc;return null==t||"object"==typeof t&&"start"in t&&null!=t.start&&n(t.start)&&(!("end"in t)||null==t.end||n(t.end))}return!1}(e)||null==e.loc&&null!=t?.loc?new o(e,t):e}const d={UnrecognizedUri:"Unrecognized uri - {uri}",UnsupportedUriProtocol:"Unrecognized uri protocol"};class m extends Error{constructor(e,t){super((0,i.HC)(d[e],t)),this.declaredRootClass="esri.arcade.arcademoduleerror"}}},66344(e,t,s){s.d(t,{q:()=>a});const i=!!(0,s(44208).A)("esri-tests-disable-gpu-memory-measurements");Symbol.iterator;class r{get size(){return this._size}constructor(e=10485760,t=.3){this._maxSize=e,this._maxClientSizeRatio=t,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._clients=new Map,this._sizeLimits=new Map}destroy(){this.clearAll(),this._sizeLimits.clear(),this._clients.clear(),this._db.clear()}register(e){this._clients.set(e.id.slice(0,-1),e)}deregister(e){this.clear(e),this._sizeLimits.delete(e),this._clients.delete(e.id.slice(0,-1))}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,-1),this._checkSize()}get _maxClientSize(){return this._maxSize*this._maxClientSizeRatio}getSize(e,t){return this._db.get(e.id+t)?.size??0}put(e,t,s,r,o){t=e.id+t;let a=this._db.get(t);if(a&&(this._size-=a.size,e.size-=a.size,this._db.delete(t),a.entry!==s&&this._notifyRemove(t,a.entry,a.size,0)),r>this._maxSize)return void this._notifyRemove(t,s,r,0);if(void 0===s)return void console.warn("Refusing to cache undefined entry ");if(!r||r<0)return i||console.warn(`Refusing to cache entry with size ${r} for key ${t}`),void this._notifyRemove(t,s,0,0);let l=1+Math.max(o,-4)- -3;this._db.set(t,new n(s,r,l)),this._size+=r,e.size+=r,this._checkSize()}updateSize(e,t){t=e.id+t;let s=this._db.get(t);if(!s)return;this._size-=s.size,e.size-=s.size;let i=s.entry.usedMemory;for(;i>this._maxSize;){let e=this._notifyRemove(t,s.entry,i,1);if(!(null!=e&&e>0))return void this._db.delete(t);i=e}s.size=i,this._size+=i,e.size+=i,this._checkSize()}pop(e,t){t=e.id+t;let s=this._db.get(t);if(s)return this._size-=s.size,e.size-=s.size,this._db.delete(t),++this._hit,s.entry;++this._miss}get(e,t){t=e.id+t;let s=this._db.get(t);if(void 0!==s)return this._db.delete(t),s.lives=s.lifetime,this._db.set(t,s),++this._hit,s.entry;++this._miss}peek(e,t){let s=this._db.get(e.id+t);return s?++this._hit:++this._miss,s?.entry}get performanceInfo(){let e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},s=[];this._db.forEach((e,i)=>{let r=e.lifetime;s[r]=(s[r]||0)+e.size,this._clients.forEach(s=>{let{id:r,name:n}=s;if(i.startsWith(r)){let s=t[n]||0;t[n]=s+e.size}})});let i={};this._clients.forEach(e=>{let s=e.name;if("hitRate"in e&&"number"==typeof e.hitRate&&!isNaN(e.hitRate)&&e.hitRate>0){let r=t[s]||0;t[s]=r,i[s]=Math.round(100*e.hitRate)+"%"}else i[s]="0%"});let r=Object.keys(t);r.sort((e,s)=>t[s]-t[e]),r.forEach(s=>e[s]=Math.round(t[s]/2**20)+"MB / "+i[s]);for(let t=s.length-1;t>=0;--t){let i=s[t];i&&(e["Priority "+(t+-3-1)]=Math.round(i/this._size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._clients.forEach(e=>e.resetHitRate())}clear(e){let t=e.id;this._db.forEach((e,s)=>{s.startsWith(t)&&(this._size-=e.size,this._db.delete(s),this._notifyRemove(s,e.entry,e.size,0))}),e.size=0}clearAll(){this._db.forEach((e,t)=>this._notifyRemove(t,e.entry,e.size,0)),this._clients.forEach(e=>e.size=0),this._size=0,this._db.clear()}*values(e){for(let[t,s]of this._db)t.startsWith(e.id)&&(yield s.entry)}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,s,i){let r=this._clients.get(e.split(o)[0])?.removeFunc,n=r?.(t,i,s);return"number"==typeof n?n:null}_checkSize(){this._sizeLimits.forEach((e,t)=>this._checkSizeLimits(e,t)),this._clients.forEach(e=>this._checkSizeLimits(this._maxClientSize,e)),this._checkSizeLimits(this.maxSize)}setMaxClientSize(e,t){null==t||t<=0?this._sizeLimits.delete(e):this._sizeLimits.set(e,t)}_checkSizeLimits(e,t){let s=t??this;if(s.size<=e)return;let i=t?.id,r=!0;for(;r;){r=!1;for(let[n,a]of this._db)if(0===a.lifetime&&(!i||n.startsWith(i))){let i=t??this._clients.get(n.split(o)[0]);if(this._purgeItem(n,a,i),s.size<=.9*e)return;r||=this._db.has(n)}}for(let[r,n]of this._db)if(!i||r.startsWith(i)){let i=t??this._clients.get(r.split(o)[0]);if(this._purgeItem(r,n,i),s.size<=.9*e)return}}_purgeItem(e,t,s){if(this._db.delete(e),t.lives<=1){this._size-=t.size,s&&(s.size-=t.size);let i=this._notifyRemove(e,t.entry,t.size,1);null!=i&&i>0&&(this._size+=i,s&&(s.size+=i),t.lives=t.lifetime,t.size=i,this._db.set(e,t))}else--t.lives,this._db.set(e,t)}}new r(0);class n{constructor(e,t,s){this.entry=e,this.size=t,this.lifetime=s,this.lives=s}}const o=":";class a{constructor(e,t){this.removeFunc=t,this.id="",this.name="",this.size=0,this._storage=new r(e,1),this._storage.register(this)}destroy(){this._storage.deregister(this),this._storage.destroy()}put(e,t,s=1){this._storage.put(this,e,t,s,1)}pop(e){return this._storage.pop(this,e)}get(e){return this._storage.get(this,e)}clear(){this._storage.clearAll()}get maxSize(){return this._storage.maxSize}set maxSize(e){this._storage.maxSize=e}resetHitRate(){}}},44729(e,t,s){s.d(t,{n:()=>l});var i=s(66131),r=s(73444),n=s(34747);function o(e){e=e.replaceAll(/LTS|LT|L{1,4}|l{1,4}/g,"[$&]");let t="";for(let s of e.match(/(\[[^[]*\])|(\\)?([Hh]mm(ss)?|Mo|M{1,4}|Do|DDDo|D{1,4}|d{2,4}|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g)||[])switch(s){case"D":t+="d";break;case"DD":t+="dd";break;case"DDD":t+="o";break;case"d":t+="c";break;case"ddd":t+="ccc";break;case"dddd":t+="cccc";break;case"M":t+="L";break;case"MM":t+="LL";break;case"MMM":t+="LLL";break;case"MMMM":t+="LLLL";break;case"YY":t+="yy";break;case"Y":case"YYYY":t+="yyyy";break;case"Q":t+="q";break;case"X":case"x":t+=s;break;default:s.length>=2&&s.startsWith("[")&&s.endsWith("]")?t+=`'${s.slice(1,-1)}'`:t+=`'${s}'`}return t}const a="esri.core.sql.dateonly";class l{constructor(e,t,s){this._year=e,this._month=t,this._day=s,this.declaredRootClass=a}static isDateOnly(e){return"object"==typeof e&&!!e&&"declaredRootClass"in e&&e.declaredRootClass===a}get month(){return this._month}get monthJS(){return this._month-1}get year(){return this._year}get day(){return this._day}get isValid(){return this.toDateTime("unknown").isValid}equals(e){return l.isDateOnly(e)&&e.day===this.day&&e.month===this.month&&e.year===this.year}compare(e){return this.year===e.year?this.month===e.month?this.day-e.day:this.month-e.month:this.year-e.year}clone(){return new l(this._year,this._month,this._day)}toDateTime(e){return n.c9.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.mT)(e)})}toDateTimeLuxon(e){return n.c9.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.mT)(e)})}toString(){return`${this.year.toString().padStart(4,"0")}-${this.month.toString().padStart(2,"0")}-${this.day.toString().padStart(2,"0")}`}toFormat(e=null,t=!0){if(null===e||""===e)return this.toString();if(t&&(e=o(e)),!e)return"";let s=this.toDateTime("unknown");return i.lY.dateTimeToArcadeDate(s).toFormat(e,{locale:(0,r.JK)(),numberingSystem:"latn"})}toArcadeDate(){let e=this.toDateTime("unknown");return i.lY.dateTimeToArcadeDate(e)}toNumber(){return this.toDateTime("unknown").toMillis()}toJSDate(){return this.toDateTime("unknown").toJSDate()}toStorageFormat(){return this.toFormat("yyyy-LL-dd",!1)}toSQLValue(){return this.toFormat("yyyy-LL-dd",!1)}toSQLWithKeyword(){return"date '"+this.toFormat("yyyy-LL-dd",!1)+"'"}plus(e,t){return l.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}toUTCDateTime(){return n.c9.utc(this.year,this.month,this.day,0,0,0,0)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}static fromMilliseconds(e){let t=n.c9.fromMillis(e,{zone:n.mQ.utcInstance});return t.isValid?l.fromParts(t.year,t.month,t.day):null}static fromSeconds(e){let t=n.c9.fromSeconds(e,{zone:n.mQ.utcInstance});return t.isValid?l.fromParts(t.year,t.month,t.day):null}static fromReader(e){if(!e)return null;let t=e.indexOf("-");if(t<0)return null;let s=e.indexOf("-",t+1);return s<0?null:new l(parseInt(e.slice(0,t),10),parseInt(e.slice(t+1,s),10),parseInt(e.slice(s+1),10))}static fromParts(e,t,s){let i=new l(e,t,s);return!1===i.isValid?null:i}static fromDateJS(e){return l.fromParts(e.getFullYear(),e.getMonth()+1,e.getDay())}static fromDateTime(e){return l.fromParts(e.year,e.month,e.day)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e||null===e)return null;let s=[];if(t)(t=o(t))&&s.push(t);else if(null===t||""===t){let t=n.c9.fromISO(e,{setZone:!0});return t.isValid?l.fromParts(t.year,t.month,t.day):null}for(let i of s){let s=n.c9.fromFormat(e,t??i);if(s.isValid)return new l(s.year,s.month,s.day)}return null}static fromNow(e="system"){let t=n.c9.fromJSDate(new Date).setZone((0,i.mT)(e));return new l(t.year,t.month,t.day)}}},15032(e,t,s){s.d(t,{k:()=>l});var i=s(73444),r=s(54218),n=s(34747);function o(e){if(!e)return"";let t=/(a|A|hh?|HH?|mm?|ss?|SSS|S|.)/g,s="";for(let i of e.match(t)||[])switch(i){case"SSS":case"m":case"mm":case"h":case"hh":case"H":case"HH":case"s":case"ss":s+=i;break;case"A":case"a":s+="a";break;default:s+=`'${i}'`}return s}const a="esri.core.sql.timeonly";class l{constructor(e,t,s,i){this._hour=e,this._minute=t,this._second=s,this._millisecond=i,this.declaredRootClass=a}static isTimeOnly(e){return"object"==typeof e&&!!e&&"declaredRootClass"in e&&e.declaredRootClass===a}get hour(){return this._hour}get minute(){return this._minute}get second(){return this._second}get millisecond(){return this._millisecond}equals(e){return l.isTimeOnly(e)&&e.hour===this.hour&&e.minute===this.minute&&e.second===this.second&&e.millisecond===this.millisecond}clone(){return new l(this.hour,this.minute,this.second,this.millisecond)}isValid(){return(0,r.Fq)(this.hour)&&(0,r.Fq)(this.minute)&&(0,r.Fq)(this.second)&&(0,r.Fq)(this.millisecond)&&this.hour>=0&&this.hour<24&&this.minute>=0&&this.minute<60&&this.second>=0&&this.second<60&&this.millisecond>=0&&this.millisecond<1e3}toString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`+(this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):"")}toSQLValue(){return this.toString()}toSQLWithKeyword(){return`time '${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}${this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):""}'`}toStorageString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`}toFormat(e=null){return null===e||""===e?this.toString():(e=o(e))?n.c9.local(1970,1,1,this._hour,this._minute,this._second,this._millisecond).toFormat(e,{locale:(0,i.JK)(),numberingSystem:"latn"}):""}toNumber(){return this.millisecond+1e3*this.second+1e3*this.minute*60+60*this.hour*60*1e3}static fromParts(e,t,s,i){let r=new l(e,t,s,i);return r.isValid()?r:null}static fromReader(e){if(!e)return null;let t=e.indexOf(":");if(t<0)return null;let s=e.indexOf(":",t+1);return s<0?null:new l(parseInt(e.slice(0,t),10),parseInt(e.slice(t+1,s),10),parseInt(e.slice(s+1),10),0)}static fromMilliseconds(e){if(e>864e5||e<0)return null;let t=Math.floor(e/1e3%60),s=Math.floor(e/6e4%60),i=Math.floor(e/36e5%24),r=Math.floor(e%1e3);return new l(i,s,t,r)}static fromDateJS(e){return new l(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}static fromDateTime(e){return new l(e.hour,e.minute,e.second,e.millisecond)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e||null===e)return null;let s=[];t?(t=o(t))&&s.push(t):(null===t||""===t)&&(s.push("HH:mm:ss"),s.push("HH:mm:ss.SSS"),s.push("hh:mm:ss a"),s.push("hh:mm:ss.SSS a"),s.push("HH:mm"),s.push("hh:mm a"),s.push("H:mm"),s.push("h:mm a"),s.push("H:mm:ss"),s.push("h:mm:ss a"),s.push("H:mm:ss.SSS"),s.push("h:mm:ss.SSS a"));for(let t of s){let s=n.c9.fromFormat(e,t);if(s.isValid)return new l(s.hour,s.minute,s.second,s.millisecond)}return null}plus(e,t){switch(e){case"days":case"years":case"months":return this.clone();case"hours":case"minutes":case"seconds":case"milliseconds":return l.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}return null}toUTCDateTime(){return n.c9.utc(1970,1,1,this.hour,this.minute,this.second,this.millisecond)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}}},44123(e,t,s){s.d(t,{WhereClauseCache:()=>n});var i=s(66344),r=s(89696);class n{constructor(e,t){this._cache=new i.q(e),this._invalidCache=new i.q(t)}get(e,t){let s=`${t?.uid}:${e}`,i=this._cache.get(s);if(i)return i;if(null!=this._invalidCache.get(s))return null;try{let i=r.A.create(e,{fieldsIndex:t});return this._cache.put(s,i),i}catch(e){return this._invalidCache.put(s,e),null}}getError(e,t){let s=`${t?.uid}:${e}`;return this._invalidCache.get(s)??null}}},73444(e,t,s){s.d(t,{JK:()=>l,Ml:()=>g,QC:()=>h,lR:()=>u,oQ:()=>f});var i=s(36563);let r;s(44208);const n=globalThis.esriConfig?.locale,o=globalThis.document?.documentElement;function a(){let e=o?.getAttribute("lang"),t=globalThis.navigator?.language;return n??e??t??"en"}function l(){return void 0===r&&(r=a()),r}const c=/^(?<language>[a-z]{2,3})(?:-(?<extlang>[a-z]{3}))?(?:-[A-Z][a-z]{3})?(?:-(?<region>[A-Z]{2}|\d{3}))?(?:-.*)?$/;function u(e=l()){return d(e)?.language}function h(e=l()){let t=d(e);return t?.language&&t?.extlang?e.replace(`${t.language}-`,""):e}function d(e=l()){return c.exec(e)?.groups}const m=[];function f(e){return m.push(e),(0,i.hA)(()=>{m.splice(m.indexOf(e),1)})}new Map;const y=[];function g(e){return y.push(e),(0,i.hA)(()=>y.splice(y.indexOf(e),1))}function p(){let e=a();r!==e&&([...y].forEach(t=>t(e)),r=e,[...m].forEach(t=>t(e)))}globalThis.addEventListener?.("languagechange",p),o&&new MutationObserver(()=>{p()}).observe(o,{attributeFilter:["lang"]})}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8768,9260],{66344(e,t,i){i.d(t,{q:()=>a});const r=!!(0,i(44208).A)("esri-tests-disable-gpu-memory-measurements");Symbol.iterator;class l{get size(){return this._size}constructor(e=10485760,t=.3){this._maxSize=e,this._maxClientSizeRatio=t,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._clients=new Map,this._sizeLimits=new Map}destroy(){this.clearAll(),this._sizeLimits.clear(),this._clients.clear(),this._db.clear()}register(e){this._clients.set(e.id.slice(0,-1),e)}deregister(e){this.clear(e),this._sizeLimits.delete(e),this._clients.delete(e.id.slice(0,-1))}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,-1),this._checkSize()}get _maxClientSize(){return this._maxSize*this._maxClientSizeRatio}getSize(e,t){return this._db.get(e.id+t)?.size??0}put(e,t,i,l,o){t=e.id+t;let a=this._db.get(t);if(a&&(this._size-=a.size,e.size-=a.size,this._db.delete(t),a.entry!==i&&this._notifyRemove(t,a.entry,a.size,0)),l>this._maxSize)return void this._notifyRemove(t,i,l,0);if(void 0===i)return void console.warn("Refusing to cache undefined entry ");if(!l||l<0)return r||console.warn(`Refusing to cache entry with size ${l} for key ${t}`),void this._notifyRemove(t,i,0,0);let n=1+Math.max(o,-4)- -3;this._db.set(t,new s(i,l,n)),this._size+=l,e.size+=l,this._checkSize()}updateSize(e,t){t=e.id+t;let i=this._db.get(t);if(!i)return;this._size-=i.size,e.size-=i.size;let r=i.entry.usedMemory;for(;r>this._maxSize;){let e=this._notifyRemove(t,i.entry,r,1);if(!(null!=e&&e>0))return void this._db.delete(t);r=e}i.size=r,this._size+=r,e.size+=r,this._checkSize()}pop(e,t){t=e.id+t;let i=this._db.get(t);if(i)return this._size-=i.size,e.size-=i.size,this._db.delete(t),++this._hit,i.entry;++this._miss}get(e,t){t=e.id+t;let i=this._db.get(t);if(void 0!==i)return this._db.delete(t),i.lives=i.lifetime,this._db.set(t,i),++this._hit,i.entry;++this._miss}peek(e,t){let i=this._db.get(e.id+t);return i?++this._hit:++this._miss,i?.entry}get performanceInfo(){let e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},i=[];this._db.forEach((e,r)=>{let l=e.lifetime;i[l]=(i[l]||0)+e.size,this._clients.forEach(i=>{let{id:l,name:s}=i;if(r.startsWith(l)){let i=t[s]||0;t[s]=i+e.size}})});let r={};this._clients.forEach(e=>{let i=e.name;if("hitRate"in e&&"number"==typeof e.hitRate&&!isNaN(e.hitRate)&&e.hitRate>0){let l=t[i]||0;t[i]=l,r[i]=Math.round(100*e.hitRate)+"%"}else r[i]="0%"});let l=Object.keys(t);l.sort((e,i)=>t[i]-t[e]),l.forEach(i=>e[i]=Math.round(t[i]/2**20)+"MB / "+r[i]);for(let t=i.length-1;t>=0;--t){let r=i[t];r&&(e["Priority "+(t+-3-1)]=Math.round(r/this._size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._clients.forEach(e=>e.resetHitRate())}clear(e){let t=e.id;this._db.forEach((e,i)=>{i.startsWith(t)&&(this._size-=e.size,this._db.delete(i),this._notifyRemove(i,e.entry,e.size,0))}),e.size=0}clearAll(){this._db.forEach((e,t)=>this._notifyRemove(t,e.entry,e.size,0)),this._clients.forEach(e=>e.size=0),this._size=0,this._db.clear()}*values(e){for(let[t,i]of this._db)t.startsWith(e.id)&&(yield i.entry)}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,i,r){let l=this._clients.get(e.split(o)[0])?.removeFunc,s=l?.(t,r,i);return"number"==typeof s?s:null}_checkSize(){this._sizeLimits.forEach((e,t)=>this._checkSizeLimits(e,t)),this._clients.forEach(e=>this._checkSizeLimits(this._maxClientSize,e)),this._checkSizeLimits(this.maxSize)}setMaxClientSize(e,t){null==t||t<=0?this._sizeLimits.delete(e):this._sizeLimits.set(e,t)}_checkSizeLimits(e,t){let i=t??this;if(i.size<=e)return;let r=t?.id,l=!0;for(;l;){l=!1;for(let[s,a]of this._db)if(0===a.lifetime&&(!r||s.startsWith(r))){let r=t??this._clients.get(s.split(o)[0]);if(this._purgeItem(s,a,r),i.size<=.9*e)return;l||=this._db.has(s)}}for(let[l,s]of this._db)if(!r||l.startsWith(r)){let r=t??this._clients.get(l.split(o)[0]);if(this._purgeItem(l,s,r),i.size<=.9*e)return}}_purgeItem(e,t,i){if(this._db.delete(e),t.lives<=1){this._size-=t.size,i&&(i.size-=t.size);let r=this._notifyRemove(e,t.entry,t.size,1);null!=r&&r>0&&(this._size+=r,i&&(i.size+=r),t.lives=t.lifetime,t.size=r,this._db.set(e,t))}else--t.lives,this._db.set(e,t)}}new l(0);class s{constructor(e,t,i){this.entry=e,this.size=t,this.lifetime=i,this.lives=i}}const o=":";class a{constructor(e,t){this.removeFunc=t,this.id="",this.name="",this.size=0,this._storage=new l(e,1),this._storage.register(this)}destroy(){this._storage.deregister(this),this._storage.destroy()}put(e,t,i=1){this._storage.put(this,e,t,i,1)}pop(e){return this._storage.pop(this,e)}get(e){return this._storage.get(this,e)}clear(){this._storage.clearAll()}get maxSize(){return this._storage.maxSize}set maxSize(e){this._storage.maxSize=e}resetHitRate(){}}},60999(e,t,i){i.d(t,{DZ:()=>y,Ke:()=>d,QA:()=>f,Tj:()=>h,UT:()=>m,aD:()=>v,jJ:()=>u});var r=i(32198),l=i(69622),s=i(97768),o=i(17676),a=i(10107),n=i(64108);function u(e,t,i){return(0,o.Lx)(e.map((e,r)=>t.apply(i,[e,r])))}async function h(e,t,i){return(await(0,o.Lx)(e.map((e,r)=>t.apply(i,[e,r])))).map(e=>e.value)}function p(e){return{ok:!0,value:e}}function c(e){return{ok:!1,error:e}}async function d(e){if(null==e)return{ok:!1,error:Error("no promise provided")};try{return p(await e)}catch(e){return c(e)}}async function y(e){try{return p(await e)}catch(e){return(0,o.QP)(e),c(e)}}function f(e){if(!0===e.ok)return e.value;throw e.error}function m(e,t){return new g(e,t)}let g=class extends l.A{get value(){return null!=(e=this._result)&&!0===e.ok?e.value:null;var e}get error(){return null!=(e=this._result)&&!1===e.ok?e.error:null;var e}get finished(){return null!=this._result}constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,s.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;let{signal:i}=this._abortController;this.promise=e(i),this.promise.then(e=>{this._result=p(e),this._cleanup()},e=>{this._result=c(e),this._cleanup()}),this._abortHandle=(0,o.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,s.xt)(this._abortHandle),this._abortController=null}};(0,r.Cg)([(0,a.MZ)()],g.prototype,"value",null),(0,r.Cg)([(0,a.MZ)()],g.prototype,"error",null),(0,r.Cg)([(0,a.MZ)()],g.prototype,"finished",null),(0,r.Cg)([(0,a.MZ)()],g.prototype,"promise",void 0),(0,r.Cg)([(0,a.MZ)()],g.prototype,"_result",void 0),g=(0,r.Cg)([(0,n.$)("esri.core.asyncUtils.ReactiveTask")],g);class v{constructor(){this._sequence=Promise.resolve()}async acquire(){let e;this._sequence=new Promise(t=>{e=this._sequence.then(()=>t,()=>t)});let t=await e;return{[Symbol.dispose]:t}}async run(e){let t={stack:[],error:void 0,hasError:!1};try{return(0,r.mS)(t,await this.acquire(),!1),await e()}catch(e){t.error=e,t.hasError=!0}finally{(0,r.hk)(t)}}}},90629(e,t,i){i.d(t,{Lz:()=>o,PN:()=>a,cr:()=>n,gs:()=>h,r_:()=>p,tc:()=>u}),i(39829);const r=/^-?(\d+(\.\d+)?)\s*((px)|(pt))?$/i,l=a(1),s=o(1);function o(e){return e?e/72*96:0}function a(e){return e?72*e/96:0}function n(e){if("string"==typeof e){let t=e.match(r);if(t){let i=Number(t[1]),r=t[3]&&t[3].toLowerCase(),l=e.startsWith("-"),s="px"===r?a(i):i;return l?-s:s}return console.warn("screenUtils.toPt: input not recognized!"),null}return e}function u(e=0,t=0){return{x:e,y:t}}function h(e=0,t=0){return[e,t]}function p(e=0,t=0,i=0){return[e,t,i]}i.d(t,["L7",0,s,"ps",0,l])},83027(e,t,i){const r=i(29953).ho;i.d(t,["h",0,r])},50638(e,t,i){i.r(t),i.d(t,{default:()=>Se});var r=i(32198),l=i(56507),s=i(60999),o=i(4718),a=i(25728),n=i(17676),u=i(84952),h=i(91429),p=i(5443),c=i(16930),d=i(4146),y=i(52136),f=i(89186),m=i(18768),g=i(63074),v=i(69208),w=i(34287),_=i(8303),A=i(54310),S=i(25036),b=i(10873);let x=null;function C(e){if(x)return x;let t={lossy:"UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA",lossless:"UklGRhoAAABXRUJQVlA4TA0AAAAvAAAAEAcQERGIiP4HAA==",alpha:"UklGRkoAAABXRUJQVlA4WAoAAAAQAAAAAAAAAAAAQUxQSAwAAAARBxAR/Q9ERP8DAABWUDggGAAAABQBAJ0BKgEAAQAAAP4AAA3AAP7mtQAAAA==",animation:"UklGRlIAAABXRUJQVlA4WAoAAAASAAAAAAAAAAAAQU5JTQYAAAD/////AABBTk1GJgAAAAAAAAAAAAAAAAAAAGQAAABWUDhMDQAAAC8AAAAQBxAREYiI/gcA"};return x=new Promise(i=>{let r=new Image;r.onload=()=>{r.onload=r.onerror=null,i(r.width>0&&r.height>0)},r.onerror=()=>{r.onload=r.onerror=null,i(!1)},r.src="data:image/webp;base64,"+t[e]}),x}var I=i(49186),M=i(53966),z=i(34275);class R{constructor(e,t){this._spriteSource=e,this._maxTextureSize=t,this.devicePixelRatio=1,this._spriteImageFormat="png",this._isRetina=!1,this._spritesData={},this.image=null,this.width=null,this.height=null,this.loadStatus="not-loaded","url"===e.type&&e.spriteFormat&&(this._spriteImageFormat=e.spriteFormat),e.pixelRatio&&(this.devicePixelRatio=e.pixelRatio),this.baseURL=e.spriteUrl}get spriteNames(){let e=[];for(let t in this._spritesData)e.push(t);return e.sort(),e}getSpriteInfo(e){return this._spritesData?this._spritesData[e]:null}async load(e){if(this.baseURL){this.loadStatus="loading";try{await this._loadSprites(e),this.loadStatus="loaded"}catch{this.loadStatus="failed"}}else this.loadStatus="failed"}async _loadSprites(e){this._isRetina=this.devicePixelRatio>1.15;let{width:t,height:i,data:r,json:l}=await this._getSpriteData(this._spriteSource,e),s=Object.keys(l);if(!s||0===s.length||!r)return this._spritesData=this.image=null,void(this.width=this.height=0);this._spritesData=l,this.width=t,this.height=i;let o,a=Math.max(this._maxTextureSize,4096);if(t>a||i>a){let e=`Sprite resource for style ${this.baseURL} is bigger than the maximum allowed of ${a} pixels}`;throw M.A.getLogger("esri.layers.support.SpriteSource").error(e),new I.A("SpriteSource",e)}for(let e=0;e<r.length;e+=4)o=r[e+3]/255,r[e]=r[e]*o,r[e+1]=r[e+1]*o,r[e+2]=r[e+2]*o;this.image=r}async _getSpriteData(e,t){if("image"===e.type){let t,i;if(this.devicePixelRatio<1.15){if(!e.spriteSource1x)throw new I.A("SpriteSource","no image data provided for low resolution sprites!");t=e.spriteSource1x.image,i=e.spriteSource1x.json}else{if(!e.spriteSource2x)throw new I.A("SpriteSource","no image data provided for high resolution sprites!");t=e.spriteSource2x.image,i=e.spriteSource2x.json}return"width"in t&&"height"in t&&"data"in t&&((0,z.mw)(t.data)||(0,z.UR)(t.data))?{width:t.width,height:t.height,data:new Uint8Array(t.data),json:i}:{...T(t),json:i}}let i=(0,u.An)(this.baseURL),r=i.query?"?"+(0,u.x0)(i.query):"",s=this._isRetina?"@2x":"",o=`${i.path}${s}.${this._spriteImageFormat}${r}`,a=`${i.path}${s}.json${r}`,[n,h]=await Promise.all([(0,l.A)(a,t),(0,l.A)(o,{responseType:"image",...t})]);return{...T(h.data),json:n.data}}}function T(e){let t=document.createElement("canvas"),i=t.getContext("2d");t.width=e.width,t.height=e.height,i.drawImage(e,0,0,e.width,e.height);let r=i.getImageData(0,0,e.width,e.height);return{width:e.width,height:e.height,data:new Uint8Array(r.data)}}var P=i(87045),L=i(25943),E=i(21325),U=i(28735),O=i(83027);class D{constructor(e,t,i){this.tileServers=[],this.tilemap=null,this.tileInfo=null,this.capabilities=null,this.fullExtent=null,this.initialExtent=null,this.name=e,this.sourceUrl=t;let r=(0,o.o8)(i),l=i.capabilities&&i.capabilities.split(",").map(e=>e.toLowerCase().trim()),s=!0===i?.exportTilesAllowed,a=!0===l?.includes("tilemap"),n=s&&i.hasOwnProperty("maxExportTilesCount")?i.maxExportTilesCount:0;this.capabilities={operations:{supportsExportTiles:s,supportsTileMap:a},exportTiles:s?{maxExportTilesCount:+n}:null},this.tileInfo=P.A.fromJSON(r.tileInfo),this.fullExtent=p.A.fromJSON(i.fullExtent),this.initialExtent=p.A.fromJSON(i.initialExtent)}destroy(){this.tilemap?.destroy()}async getRefKey(e,t){return this.tilemap?this.tilemap.dataKey(e,t):e}isCompatibleWith(e){let t=this.tileInfo,i=e.tileInfo;if(!t.spatialReference.equals(i.spatialReference)||!t.origin.equals(i.origin)||Math.round(t.dpi)!==Math.round(i.dpi))return!1;let r=t.lods,l=i.lods,s=Math.min(r.length,l.length);for(let e=0;e<s;e++){let t=r[e],i=l[e];if(t.level!==i.level||Math.round(t.scale)!==Math.round(i.scale))return!1}return!0}}var $=i(44159);class j extends D{static async create(e,t,i,r,l){if(!0===r.cluster)throw Error("Clustered GeoJSON vector tile sources are not supported.");if(null==r.data)throw Error(`GeoJSON source '${e}' must define a data property.`);let s,o=r.maxzoom??18,a=await(0,O.h)("GeoJSONVectorTileSourceWorker",{signal:l?.signal,strategy:"dedicated"});try{s=await a.invoke("initialize",{definition:r,name:e,requestOptions:k(l)},{signal:l?.signal}),(0,n.Te)(l)}catch(e){throw a.close(),e}return new j(e,t,i,a,r.minzoom??0,o,s.geometryTypes)}constructor(e,t,i,r,l,s,o){super(e,t,i),this._connection=r,this._minZoom=l,this._maxZoom=s,this.geometryTypes=o}destroy(){super.destroy(),this._connection?.close(),this._connection=null}async getRefKey(e,t){if((0,n.Te)(t),e.level<this._minZoom)return null;if(e.level<=this._maxZoom)return e;let i=e.level-this._maxZoom;return new $.A(this._maxZoom,e.row>>i,e.col>>i,e.world)}requestTile(e,t,i,r){return(0,n.Te)(r),this._connection?this._connection.invoke("requestTile",{col:i,level:e,row:t},r):Promise.reject((0,n.NK)())}}function k(e){if(!e)return{};let{signal:t,...i}=e;return i}class Z{constructor(e){this.url=e}destroy(){this._tileIndexPromise=null}async fetchTileIndex(){return this._tileIndexPromise||=(0,l.A)(this.url).then(e=>e.data.index),this._tileIndexPromise}async dataKey(e,t){let i=await this.fetchTileIndex();return(0,n.Te)(t),this._getIndexedDataKey(i,e)}_getIndexedDataKey(e,t){let i=[t];if(t.level<0||t.row<0||t.col<0||t.row>>t.level>0||t.col>>t.level>0)return null;let r=t;for(;0!==r.level;)r=new $.A(r.level-1,r.row>>1,r.col>>1,r.world),i.push(r);let l,s,o=e,a=i.pop();if(1===o)return a;for(;i.length;)if(l=i.pop(),s=(1&l.col)+((1&l.row)<<1),o){if(0===o[s]){a=null;break}if(1===o[s]){a=l;break}a=l,o=o[s]}return a}}var N=i(97768);class F{constructor(e,t){this._tilemap=e,this._tileIndexUrl=t}destroy(){this._tilemap=(0,N.pR)(this._tilemap),this._tileIndexPromise=null}async fetchTileIndex(e){return this._tileIndexPromise||=(0,l.A)(this._tileIndexUrl,{query:{...e?.query}}).then(e=>e.data.index),this._tileIndexPromise}dataKey(e,t){let{level:i,row:r,col:l}=e,s=new $.A(e);return this._tilemap.fetchAvailabilityUpsample(i,r,l,s,t).then(()=>(s.world=e.world,s)).catch(e=>{if((0,n.zf)(e))throw e;return null})}}var G=i(91869);class K{constructor(e){this._tileUrl=e,this._promise=null,this._abortController=null,this._abortOptions=[]}getData(e){(null==this._promise||(0,n.G4)(this._abortController?.signal))&&(this._promise=this._makeRequest(this._tileUrl));let t=this._abortOptions;return t.push(e),(0,n.u7)(e,()=>{t.every(e=>(0,n.G4)(e))&&this._abortController.abort()}),this._promise.then(e=>(0,o.o8)(e))}async _makeRequest(e){this._abortController=new AbortController;let{data:t}=await(0,l.A)(e,{responseType:"array-buffer",signal:this._abortController.signal});return t}}const B=new Map;class q extends D{constructor(e,t,i){super(e,t,i);let r=(0,u.An)(this.sourceUrl),l=(0,o.o8)(i),s=l.tiles;if(r)for(let e=0;e<s.length;e++){let t=(0,u.An)(s[e]);t&&((0,u.oP)(t.path)||(t.path=(0,u.fj)(r.path,t.path)),s[e]=(0,u.a6)(t.path,{...r.query,...t.query}))}this.tileServers=s;let a=i.tileMap&&r?(0,u.a6)((0,u.fj)(r.path,i.tileMap),r.query??{}):null;this.capabilities.operations.supportsTileMap?(this.type="vector-tile",this.tilemap=new F(new L.d({layer:{parsedUrl:r,tileInfo:this.tileInfo},minLOD:l.minLOD??this.tileInfo.lods[0].level,maxLOD:l.maxLOD??this.tileInfo.lods[this.tileInfo.lods.length-1].level}),a)):a&&(this.tilemap=new Z(a))}requestTile(e,t,i,r){return function(e,t,i,r,l){let s=(0,u.An)(e),o=s.query;if(o)for(let[e,l]of Object.entries(o))switch(l){case"{x}":o[e]=r.toString();break;case"{y}":o[e]=i.toString();break;case"{z}":o[e]=t.toString()}let a=s.path;return function(e,t){return(0,G.tE)(B,e,()=>new K(e)).getData(t).finally(()=>B.delete(e))}((0,u.a6)(a.replaceAll(/\{z\}/gi,t.toString()).replaceAll(/\{y\}/gi,i.toString()).replaceAll(/\{x\}/gi,r.toString()),{...s.query}),l)}(this.tileServers[t%this.tileServers.length],e,t,i,r)}}function H(...e){let t;for(let i of e)null!=i&&((0,u.BQ)(i)?t&&=t.split("://")[0]+":"+i.trim():t=(0,u.oP)(i)?i:(0,u.fj)(t,i));return t?(0,u.UC)(t):void 0}async function Q(e,t,i,r,s){let o,a,h;if((0,n.Te)(s),"string"==typeof i){let e=(0,u.S8)(i);h=await(0,l.A)(e,{...s,responseType:"json",query:{f:"json",...s?.query}}),h.ssl&&(o&&=o.replace(/^http:/i,"https:"),a&&=a.replace(/^http:/i,"https:")),o=e,a=e}else null!=i&&(h={data:i},o=i.jsonUrl||null,a=r);let p=h?.data;switch(p?.type){case"Feature":case"FeatureCollection":return e.sourceUrl=o||null,W(e,function(e){return{version:8,sprite:"",glyphs:"",sources:{geojson:{type:"geojson",data:e}},layers:[]}}(p),a,s)}if(J(p))return e.styleUrl=o||null,W(e,p,a,s);if(function(e){return!!e&&!J(e)}(p))return e.primarySourceName?ee(e,p,a,!1,t,s):(e.sourceUrl=o||null,V(p)&&null==e.style&&(t="tilejson"),ee(e,p,a,!0,t,s));throw Error("You must specify the URL or the JSON for a service or for a style.")}function V(e){return"object"==typeof e&&!!e&&"tilejson"in e&&null!=e.tilejson}function J(e){return!!e&&"sources"in e&&!!e.sources}async function W(e,t,i,r){let l=i?(0,u.nM)(i):(0,u.gd)(),s=null==t.layers||0===t.layers.length,o=s?{...t,layers:[]}:t;e.styleBase=l,e.style=o,"webp"===o["sprite-format"]?.toLowerCase()&&(e.spriteFormat="webp");let a=[];if(o.sources&&o.sources.esri&&"geojson"!==o.sources.esri.type){let t=o.sources.esri;t.url?await Q(e,"esri",H(l,t.url),void 0,r):a.push(Q(e,"esri",t,l,r))}for(let t of Object.keys(o.sources))"esri"!==t&&"tilejson"!==t&&"vector"===o.sources[t].type&&(o.sources[t].url?a.push(Q(e,t,H(l,o.sources[t].url),void 0,r)):o.sources[t].tiles&&a.push(Q(e,t,o.sources[t],l,r)));await Promise.all(a);for(let t of Object.keys(o.sources)){let i=o.sources[t];if("geojson"===i.type){let a=await Y(e,t,i,l,r);s&&o.layers.push(...X(t,a.geometryTypes))}}}async function Y(e,t,i,r,l){if(null==i.data)throw Error(`GeoJSON source '${t}' must define a data property.`);let s={...i,type:"geojson",data:"string"==typeof i.data?H(r,i.data):i.data},o=ie({maxzoom:s.maxzoom,minzoom:s.minzoom},e),a=await j.create(t,r,o,s,l);return te(e,t,i,o,a,!e.primarySourceName,r),a}function X(e,t){return t.map(t=>{switch(t){case"polygon":return{id:`${e}_polygon`,type:"fill",source:e,filter:["==","$type","Polygon"],paint:{"fill-color":"#808080"}};case"line":return{id:`${e}_line`,type:"line",source:e,filter:["==","$type","LineString"],paint:{"line-color":"#808080","line-width":1}};case"point":return{id:`${e}_point`,type:"circle",source:e,filter:["==","$type","Point"],paint:{"circle-color":"#808080","circle-radius":3}}}})}async function ee(e,t,i,r,l,s){let o=i?(0,u.UC)(i)+"/":(0,u.gd)(),a=ie(t,e);if(te(e,l,t,a,new q(l,(0,u.a6)(o,s?.query??{}),a),r,o),!V(e)&&"defaultStyles"in t&&!e.style){if(null==t.defaultStyles)throw Error();return"string"==typeof t.defaultStyles?Q(e,"",H(o,t.defaultStyles,"root.json"),void 0,s):Q(e,"",t.defaultStyles,H(o,"root.json"),s)}if(V(t)&&null==e.style&&a.defaultStyles)return Q(e,"",a.defaultStyles,H(o,"root.json"),s)}function te(e,t,i,r,l,s,o){if(!s&&e.primarySourceName in e.sourceNameToSource){let i=e.sourceNameToSource[e.primarySourceName];if(!i.isCompatibleWith(l))return M.A.getLogger("esri.layers.support.vectorTileLayerLoader").warn(`Ignoring source '${t}' because its tiling scheme is incompatible with the primary source '${e.primarySourceName}'.`),void l.destroy();null!=l.fullExtent&&(null==i.fullExtent?i.fullExtent=l.fullExtent.clone():i.fullExtent.union(l.fullExtent)),i.tileInfo&&l.tileInfo&&i.tileInfo.lods.length<l.tileInfo.lods.length&&(i.tileInfo=l.tileInfo)}s&&(e.sourceBase=o,e.source=i,e.validatedSource=r,e.primarySourceName=t),e.sourceNameToSource[t]=l}function ie(e,t){if(function(e){return e.hasOwnProperty("tileInfo")}(e)){let t=e?.tileInfo;return null!=t&&(t.rows??=512,t.cols??=512),e}let i,r={xmin:-20037507.067161843,ymin:-20037507.067161843,xmax:20037507.067161843,ymax:20037507.067161843,spatialReference:{wkid:102100,latestWkid:3857}},l=null;if(V(e)){let{bounds:r,vector_layers:s}=e;if(r){let e=(0,U.Gh)({x:r[0],y:r[1],spatialReference:(0,o.o8)(E.KK)}),t=(0,U.Gh)({x:r[2],y:r[3],spatialReference:(0,o.o8)(E.KK)});l={xmin:e.x,ymin:e.y,xmax:t.x,ymax:t.y,spatialReference:(0,o.o8)(E.ch)}}if(s&&s.length>0)i={version:8,sprite:"",glyphs:"",sources:{tilejson:{type:"vector",url:e.tilejson}},layers:re(s)};else if(null==t.style)throw Error("The TileJSON source does not contain any vector_layers. This VectorTileLayer cannot be loaded.")}null===l&&(l=r);let s=78271.51696400007,a=295828763.7957775,n=[],u=e.hasOwnProperty("maxzoom")&&null!=e.maxzoom?Math.abs(+e.maxzoom):22;for(let e=0;e<=u;e++)n.push({level:e,scale:a,resolution:s}),s/=2,a/=2;return{capabilities:"TilesOnly",initialExtent:l,fullExtent:r,minScale:0,maxScale:0,tiles:e.tiles,tileInfo:{rows:512,cols:512,dpi:96,format:"pbf",origin:{x:-20037508.342787,y:20037508.342787},lods:n,spatialReference:(0,o.o8)(E.ch)},defaultStyles:i}}function re(e){let t=[];for(let i of e)i.geometry_type?t.push(le(i.geometry_type.toLowerCase(),i,!1)):(t.push(le("polygon",i,!0)),t.push(le("line",i,!0)),t.push(le("circle",i,!0)));return t}function le(e,t,i){let{id:r,minzoom:l,maxzoom:s}=t,o={type:"polygon"===e||"polygons"===e?"fill":"line"===e||"lines"===e?"line":"circle",id:r,source:"tilejson","source-layer":r,minzoom:l,maxzoom:s};switch(e){case"fill":i&&(o.id+="_polygon",o.filter='(["==", "$type", "Polygon"])'),o.paint={"fill-color":"#808080"};break;case"line":i&&(o.id+="_line",o.filter='(["==", "$type", "LineString"])');break;case"circle":i&&(o.id+="_point",o.filter='(["==", "$type", "Point"])')}return o}var se=i(88788),oe=i(39131),ae=i(97159),ne=i(86738),ue=i(91806);const he=1e-6;function pe(e,t){if(e===t)return!0;if(null==e&&null!=t||null!=e&&null==t||null==e||null==t||!e.spatialReference.equals(t.spatialReference)||e.dpi!==t.dpi)return!1;let i,r,l=e.origin,s=t.origin;if(Math.abs(l.x-s.x)>=he||Math.abs(l.y-s.y)>=he)return!1;e.lods[0].scale>t.lods[0].scale?(i=e,r=t):(r=e,i=t);for(let e=i.lods[0].scale;e>=r.lods[r.lods.length-1].scale-he;e/=2)if(Math.abs(e-r.lods[0].scale)<he)return!0;return!1}function ce(e,t){if(e===t)return e;if(null==e&&null!=t)return t;if(null!=e&&null==t)return e;if(null==e||null==t)return null;let i=e.size[0],r=e.format,l=e.dpi,s=new ne.A({x:e.origin.x,y:e.origin.y}),o=e.spatialReference,a=e.lods[0].scale>t.lods[0].scale?e.lods[0]:t.lods[0],n=e.lods[e.lods.length-1].scale<=t.lods[t.lods.length-1].scale?e.lods[e.lods.length-1]:t.lods[t.lods.length-1],u=a.scale,h=a.resolution,p=n.scale,c=[],d=u,y=h,f=0;for(;d>=p;)c.push(new ue.A({level:f,resolution:y,scale:d})),f++,d/=2,y/=2;return new P.A({size:[i,i],dpi:l,format:r||"pbf",origin:s,lods:c,spatialReference:o})}var de=i(45013);class ye{constructor(e){this.getUnmaskedRenderer=e}}let fe;function me(){return fe??=function(){let e=new ge,t=function(e){if(typeof WebGL2RenderingContext>"u")return null;let t=document.createElement("canvas");if(!t)return null;let i=t.getContext("webgl2",{failIfMajorPerformanceCaveat:!0});if(i??(i=t.getContext("webgl2"),null!=i&&(e.majorPerformanceCaveat=!0,e.unmaskedRenderer=function(e){let t=e.getExtension("WEBGL_debug_renderer_info");return t?new ye(()=>e.getParameter(t.UNMASKED_RENDERER_WEBGL)):null}(i)?.getUnmaskedRenderer()??"unknown")),null==i)return i;e.available=!0,e.maxTextureSize=i.getParameter(i.MAX_TEXTURE_SIZE),e.supportsVertexShaderSamplers=i.getParameter(i.MAX_VERTEX_TEXTURE_IMAGE_UNITS)>0;let r=i.getShaderPrecisionFormat(i.FRAGMENT_SHADER,i.HIGH_FLOAT);return r&&(e.supportsHighPrecisionFragment=r.precision>0),i}(e);return null==t||(e.supportsColorBufferFloat=null!==t.getExtension("EXT_color_buffer_float"),e.supportsColorBufferFloatBlend=null!==t.getExtension("EXT_float_blend"),e.supportsColorBufferHalfFloat=e.supportsColorBufferFloat||null!==t.getExtension("EXT_color_buffer_half_float")),e}(),fe}class ge{constructor(){this.available=!1,this.majorPerformanceCaveat=!1,this.maxTextureSize=0,this.supportsVertexShaderSamplers=!1,this.supportsHighPrecisionFragment=!1,this.supportsColorBufferFloat=!1,this.supportsColorBufferFloatBlend=!1,this.supportsColorBufferHalfFloat=!1,this.unmaskedRenderer="unloaded"}}var ve=i(59923),we=i(43937),_e=i(36005);let Ae=class extends((0,g.dM)((0,S.j)((0,A.J)((0,f.f)((0,m.b)((0,w.q)((0,_.A)((0,v.d)((0,y.p)((0,a.M)(d.A))))))))))){constructor(...e){super(...e),this._spriteSourceMap=new Map,this.currentStyleInfo=null,this.isReference=null,this.operationalLayerType="VectorTileLayer",this.path=null,this.refreshInterval=0,this.style=null,this.tilemapCache=null,this.type="vector-tile",this.graphicOrigin=null}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}destroy(){if(this.sourceNameToSource)for(let e of Object.values(this.sourceNameToSource))e?.destroy();this.primarySource?.destroy(),this._spriteSourceMap.clear()}async prefetchResources(e){await this.loadSpriteSource(globalThis.devicePixelRatio||1,e)}load(e){let t=this.loadFromPortal({supportedTypes:["Vector Tile Service"],supportsData:!1},e).catch(n.QP).then(async()=>{if(!this.portalItem?.id)return;let t=`${this.portalItem.itemCdnUrl}/resources/styles/root.json`;(await(0,l.A)(t,{...e,query:{f:"json",...this.customParameters,token:this.apiKey},authMode:this.portalItem.portal.authMode})).data&&this.read({url:t},(0,se.v)(this.portalItem,"portal-item"))}).catch(n.QP).then(()=>this._loadStyle(e));return this.addResolvingPromise(t),Promise.resolve(this)}get apiKey(){return super.apiKey}set apiKey(e){super.apiKey=e}get portalItem(){return super.portalItem}set portalItem(e){super.portalItem=e}get attributionDataUrl(){let e=this.currentStyleInfo,t=e?.serviceUrl&&(0,u.An)(e.serviceUrl);if(!t)return null;let i=this._getDefaultAttribution(t.path);return i?(0,u.a6)(i,{...this.customParameters,token:this.apiKey}):null}get capabilities(){let e=this.primarySource;return e?e.capabilities:{operations:{supportsExportTiles:!1,supportsTileMap:!1},exportTiles:null}}get fullExtent(){return this.primarySource?.fullExtent||null}get initialExtent(){return this.primarySource?.initialExtent||null}get parsedUrl(){return this.serviceUrl?(0,u.An)(this.serviceUrl):null}get serviceUrl(){return this.currentStyleInfo?.serviceUrl||null}get spatialReference(){return this.tileInfo?.spatialReference??null}get styleUrl(){return this.currentStyleInfo?.styleUrl||null}writeStyleUrl(e,t){e&&(0,u.BQ)(e)&&(e=`https:${e}`);let i=(0,oe.py)(e);t.styleUrl=(0,ae.e)(e,i)}get tileInfo(){let e=[];for(let t in this.sourceNameToSource)e.push(this.sourceNameToSource[t]);let t=this.primarySource?.tileInfo||new P.A;if(e.length>1)for(let i=0;i<e.length;i++)pe(t,e[i].tileInfo)&&(t=ce(t,e[i].tileInfo));return t}readTilemapCache(e,t){return t.capabilities?.includes("Tilemap")?new L.d({layer:this}):null}set url(e){if(!e)return void this._set("url",e);let t=(0,u.An)(e);this._set("url",t.path),t.query&&(this.customParameters={...this.customParameters,...t.query})}readVersion(e,t){return t.version?parseFloat(t.version):parseFloat(t.currentVersion)}async loadSpriteSource(e=1,t){if(!this._spriteSourceMap.has(e)){let i=me().maxTextureSize,r=this.currentStyleInfo?.spriteUrl?(0,u.a6)(this.currentStyleInfo.spriteUrl,{...this.customParameters,token:this.apiKey}):null,l=new R({type:"url",spriteUrl:r,pixelRatio:e,spriteFormat:this.currentStyleInfo?.spriteFormat},i);await l.load(t),this._spriteSourceMap.set(e,l)}return this._spriteSourceMap.get(e)}async setSpriteSource(e,t){if(!e)return null;let i=me().maxTextureSize,r=e.spriteUrl,l=r?(0,u.a6)(r,{...this.customParameters,token:this.apiKey}):null;if(!l&&"url"===e.type)return null;let s=new R(e,i);try{await s.load(t);let i=e.pixelRatio||1;return this._spriteSourceMap.clear(),this._spriteSourceMap.set(i,s),l&&this.currentStyleInfo&&(this.currentStyleInfo.spriteUrl=l),this.emit("spriteSource-change",{spriteSource:s}),s}catch(e){(0,n.QP)(e)}return null}async loadStyle(e,t){let i=e||this.style||this.url;return this._loadingTask&&"string"==typeof i&&this.url===i||(this._loadingTask?.abort(),this._loadingTask=(0,s.UT)(e=>(this._spriteSourceMap.clear(),this._getSourceAndStyle(i,{signal:e})),t)),this._loadingTask.promise}getStyleLayerId(e){return this.styleRepository.getStyleLayerId(e)}getStyleLayerIndex(e){return this.styleRepository.getStyleLayerIndex(e)}getPaintProperties(e){return(0,o.o8)(this.styleRepository?.getPaintProperties(e))}setPaintProperties(e,t){let i=this.styleRepository.isPainterDataDriven(e);this.styleRepository.setPaintProperties(e,t);let r=this.styleRepository.isPainterDataDriven(e);this.emit("paint-change",{layer:e,paint:t,isDataDriven:i||r})}getStyleLayer(e){return(0,o.o8)(this.styleRepository.getStyleLayer(e))}setStyleLayer(e,t){this.styleRepository.setStyleLayer(e,t),this.emit("style-layer-change",{layer:e,index:t})}deleteStyleLayer(e){this.styleRepository.deleteStyleLayer(e),this.emit("delete-style-layer",{layer:e})}getLayoutProperties(e){return(0,o.o8)(this.styleRepository.getLayoutProperties(e))}setLayoutProperties(e,t){this.styleRepository.setLayoutProperties(e,t),this.emit("layout-change",{layer:e,layout:t})}setStyleLayerVisibility(e,t){this.styleRepository.setStyleLayerVisibility(e,t),this.emit("style-layer-visibility-change",{layer:e,visibility:t})}getStyleLayerVisibility(e){return this.styleRepository.getStyleLayerVisibility(e)?"visible":"none"}write(e,t){return t?.origin&&!this.styleUrl?((0,ve.U4)(t,this,"style defined by JSON only are not supported"),null):super.write(e,t)}getTileUrl(e,t,i){return null}async _getSourceAndStyle(e,t){if(!e)throw Error("invalid style!");let i=await async function(e,t){let i={source:null,sourceBase:null,sourceUrl:null,validatedSource:null,style:null,styleBase:null,styleUrl:null,sourceNameToSource:{},primarySourceName:"",spriteFormat:"png"},[r,l]="string"==typeof e?[e,null]:[null,e.jsonUrl];return await Q(i,"esri",e,l,t),{layerDefinition:i.validatedSource,url:r,serviceUrl:i.sourceUrl,style:i.style,styleUrl:i.styleUrl,spriteUrl:i.style&&i.style.sprite&&H(i.styleBase,i.style.sprite),spriteFormat:i.spriteFormat,glyphsUrl:i.style&&i.style.glyphs&&H(i.styleBase,i.style.glyphs),sourceNameToSource:i.sourceNameToSource,primarySourceName:i.primarySourceName}}(e,{...t,query:{...this.customParameters,token:this.apiKey}});"webp"===i.spriteFormat&&(await C("lossy")||(i.spriteFormat="png")),this._set("currentStyleInfo",{...i}),"string"==typeof e?(this.url=e,this.style=null):(this.url=null,this.style=e),this._set("sourceNameToSource",i.sourceNameToSource),this._set("primarySource",i.sourceNameToSource[i.primarySourceName]),this._set("styleRepository",new de.A(i.style,!1)),this.read(i.layerDefinition,{origin:"service"}),this.emit("load-style")}_getDefaultAttribution(e){let t=e.match(/^https?:\/\/(?:basemaps|basemapsbeta|basemapsdev)(?:-api)?\.arcgis\.com(\/[^/]+)?\/arcgis\/rest\/services\/([^/]+(\/[^/]+)*)\/vectortileserver/i),i=["OpenBasemap_v2","OpenBasemap_GCS_v2","OpenStreetMap_v2","OpenStreetMap_Daylight_v2","OpenStreetMap_Export_v2","OpenStreetMap_FTS_v2","OpenStreetMap_GCS_v2","World_Basemap","World_Basemap_v2","World_Basemap_Export_v2","World_Basemap_GCS_v2","World_Basemap_WGS84","World_Contours_v2","World_Hillshade_v2"];if(!t)return;let r=t[2]&&t[2].toLowerCase();if(!r)return;let l=t[1]||"";for(let e of i)if(e.toLowerCase().includes(r))return(0,u.S8)(`//static.arcgis.com/attribution/Vector${l}/${e}`)}async _loadStyle(e){return this._loadingTask?.promise??this.loadStyle(null,e)}};(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ae.prototype,"attributionDataUrl",null),(0,r.Cg)([(0,h.MZ)({type:["show","hide"]})],Ae.prototype,"listMode",void 0),(0,r.Cg)([(0,h.MZ)({json:{read:!0,write:!0}})],Ae.prototype,"blendMode",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],Ae.prototype,"capabilities",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ae.prototype,"currentStyleInfo",void 0),(0,r.Cg)([(0,h.MZ)({json:{read:!1},readOnly:!0,type:p.A})],Ae.prototype,"fullExtent",null),(0,r.Cg)([(0,h.MZ)({json:{read:!1},readOnly:!0,type:p.A})],Ae.prototype,"initialExtent",null),(0,r.Cg)([(0,h.MZ)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],Ae.prototype,"isReference",void 0),(0,r.Cg)([(0,h.MZ)({type:["VectorTileLayer"]})],Ae.prototype,"operationalLayerType",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ae.prototype,"parsedUrl",null),(0,r.Cg)([(0,h.MZ)({type:String,json:{origins:{"web-scene":{read:!0,write:!0}},read:!1}})],Ae.prototype,"path",void 0),(0,r.Cg)([(0,h.MZ)({type:Number,json:{write:!1,origins:{"web-map":{write:!1},"web-scene":{write:!1},"portal-item":{write:!1}}}})],Ae.prototype,"refreshInterval",void 0),(0,r.Cg)([(0,h.MZ)()],Ae.prototype,"style",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ae.prototype,"serviceUrl",null),(0,r.Cg)([(0,h.MZ)({type:c.A,readOnly:!0})],Ae.prototype,"spatialReference",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ae.prototype,"styleRepository",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ae.prototype,"sourceNameToSource",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ae.prototype,"primarySource",void 0),(0,r.Cg)([(0,h.MZ)({type:String,readOnly:!0,json:{write:{ignoreOrigin:!0},origins:{"web-document":{write:{ignoreOrigin:!0,isRequired:!0}}}}})],Ae.prototype,"styleUrl",null),(0,r.Cg)([(0,we.K)(["portal-item","web-document"],"styleUrl")],Ae.prototype,"writeStyleUrl",null),(0,r.Cg)([(0,h.MZ)({json:{read:!1,origins:{service:{read:!1}}},readOnly:!0,type:P.A})],Ae.prototype,"tileInfo",null),(0,r.Cg)([(0,h.MZ)()],Ae.prototype,"tilemapCache",void 0),(0,r.Cg)([(0,_e.w)("service","tilemapCache",["capabilities","tileInfo"])],Ae.prototype,"readTilemapCache",null),(0,r.Cg)([(0,h.MZ)({json:{read:!1},readOnly:!0,value:"vector-tile"})],Ae.prototype,"type",void 0),(0,r.Cg)([(0,h.MZ)({readOnly:!0,clonable:!1})],Ae.prototype,"graphicOrigin",void 0),(0,r.Cg)([(0,h.MZ)({json:{origins:{"web-document":{read:{source:"styleUrl"}},"portal-item":{read:{source:"url"}}},write:!1,read:!1}}),(0,h.MZ)(b.OZ)],Ae.prototype,"url",null),(0,r.Cg)([(0,h.MZ)({readOnly:!0})],Ae.prototype,"version",void 0),(0,r.Cg)([(0,_e.w)("version",["version","currentVersion"])],Ae.prototype,"readVersion",null),Ae=(0,r.Cg)([(0,h.$K)("esri.layers.VectorTileLayer")],Ae);const Se=Ae},52136(e,t,i){var r=i(32198),l=i(91429);i.d(t,["p",0,e=>{let t=e,i=class extends t{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null==e?(this._clearOverride("apiKey"),this.clear("apiKey","user")):this._override("apiKey",e)}};return(0,r.Cg)([(0,l.MZ)({type:String})],i.prototype,"apiKey",null),i=(0,r.Cg)([(0,l.$K)("esri.layers.mixins.APIKeyMixin")],i),i}])},89186(e,t,i){var r=i(32198),l=i(91429),s=i(16930),o=i(87045),a=i(65509),n=i(25943),u=i(36005);i.d(t,["f",0,e=>{let t=e,i=class extends t{constructor(){super(...arguments),this.copyright=null,this.minScale=0,this.maxScale=0,this.spatialReference=null,this.tileInfo=null,this.tilemapCache=null}destroy(){this.tilemapCache?.destroy?.()}readMinScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}readMaxScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}get supportsBlankTile(){return this.version>=10.2}readTilemapCache(e,t,i){let r=t.capabilities?.toLowerCase().includes("tilemap"),{minLOD:l,maxLOD:s,minScale:u,maxScale:h}=t;if(null==l&&null==s&&(0!==u||0!==h)){let e=e=>Math.round(1e4*e)/1e4;u=e(u||t.tileInfo.lods[0].scale),h=e(h||t.tileInfo.lods[t.tileInfo.lods.length-1].scale);for(let i of t.tileInfo.lods){let t=e(i.scale);l=t>=u?i.level:l,s=t>=h?i.level:s}}if(r)return new n.d({layer:this,minLOD:l,maxLOD:s});if(t.tileInfo){let e=new o.A;return e.read(t.tileInfo,i),new a.A(e,l,s)}return null}};return(0,r.Cg)([(0,l.MZ)({json:{read:{source:"copyrightText"}}})],i.prototype,"copyright",void 0),(0,r.Cg)([(0,l.MZ)()],i.prototype,"minScale",void 0),(0,r.Cg)([(0,u.w)("service","minScale")],i.prototype,"readMinScale",null),(0,r.Cg)([(0,l.MZ)()],i.prototype,"maxScale",void 0),(0,r.Cg)([(0,u.w)("service","maxScale")],i.prototype,"readMaxScale",null),(0,r.Cg)([(0,l.MZ)({type:s.A})],i.prototype,"spatialReference",void 0),(0,r.Cg)([(0,l.MZ)({readOnly:!0})],i.prototype,"supportsBlankTile",null),(0,r.Cg)([(0,l.MZ)({type:o.A})],i.prototype,"tileInfo",void 0),(0,r.Cg)([(0,l.MZ)()],i.prototype,"tilemapCache",void 0),(0,r.Cg)([(0,u.w)("service","tilemapCache",["capabilities","tileInfo"])],i.prototype,"readTilemapCache",null),(0,r.Cg)([(0,l.MZ)()],i.prototype,"version",void 0),i=(0,r.Cg)([(0,l.$K)("esri.layers.mixins.ArcGISCachedService")],i),i}])},18768(e,t,i){var r=i(32198),l=i(53966),s=i(91429),o=i(60694);i.d(t,["b",0,e=>{let t=e,i=class extends t{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){let e=(0,o.qg)(this.url);if(e?.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,o.Jf)(e,l.A.getLogger(this)))}};return(0,r.Cg)([(0,s.MZ)()],i.prototype,"title",null),(0,r.Cg)([(0,s.MZ)({type:String})],i.prototype,"url",null),i=(0,r.Cg)([(0,s.$K)("esri.layers.mixins.ArcGISService")],i),i}])},69208(e,t,i){var r=i(32198),l=i(91429);i.d(t,["d",0,e=>{let t=e,i=class extends t{constructor(){super(...arguments),this.customParameters=null}};return(0,r.Cg)([(0,l.MZ)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],i.prototype,"customParameters",void 0),i=(0,r.Cg)([(0,l.$K)("esri.layers.mixins.CustomParametersMixin")],i),i}])},8303(e,t,i){var r=i(32198),l=i(92602),s=i(70333),o=i(56507),a=i(60999),n=i(49186),u=i(36563),h=i(53966),p=i(97768),c=i(17676),d=i(84952),y=i(91429),f=i(77548),m=i(20655),g=i(80812),v=i(41318),w=i(10407),_=i(26121),A=i(36005),S=i(43937);const b={credential:null,user:null};i.d(t,["A",0,e=>{let t=e,x=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){super.destroy(),this.portalItem=(0,p.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}get portalItem(){return this._get("portalItem")}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,i){if(t.itemId)return new g.default({id:t.itemId,portal:i?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{let{load:r}=await i.e(1204).then(()=>i(41204));return(0,c.Te)(t),await r({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,c.zf)(e)||h.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async reloadFromPortal(e,t){if(!this.loaded||!this.portalItem?.id)return!1;let r=t?.signal?null:new AbortController;try{let{reload:l}=await i.e(1204).then(()=>i(41204));return r&&this.addHandles((0,u.rE)(r),"reloadFromPortal"),await l({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t?.signal?t:{signal:r.signal})}catch(e){throw(0,c.zf)(e)||h.A.getLogger(this).warn(`Failed to reload layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}finally{r&&this.removeHandles("reloadFromPortal")}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,c.QP)(e),!0)))}async setUserPrivileges(e,t){if(!l.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{let{features:{edit:i,fullEdit:r},content:{updateItem:l}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",i),this._set("userHasFullEditingPrivileges",r),this._set("userHasUpdateItemPrivileges",l)}catch(e){(0,c.QP)(e)}}async _fetchUserPrivileges(e,t){let i=this.portalItem;if(!e||!i||!i.loaded||i.sourceUrl)return this._fetchFallbackUserPrivileges(t);let r,l,o=!s.id?.findCredential(this.url),a=e===i.id;if(a&&i.portal.user)return this._getUserPrivileges(i,o);if(a)r=i.portal.url;else try{r=await(0,f.wI)(this.url,t)}catch(e){(0,c.QP)(e)}if(!r||!(0,d.b8)(r,i.portal.url))return this._fetchFallbackUserPrivileges(t);try{let e=null==t?null:t.signal;l=await(s.id?.getCredential(`${r}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,c.QP)(e)}if(!l)return{features:{edit:!0,fullEdit:!1},content:{updateItem:!1}};try{if(a?await i.reload():(i=new g.default({id:e,portal:{url:r}}),await i.load(t)),i.portal.user)return this._getUserPrivileges(i,o)}catch(e){(0,c.QP)(e)}return{features:{edit:!0,fullEdit:!1},content:{updateItem:!1}}}_getUserPrivileges(e,t){let i=(0,w.It)(e);return t&&(i.features.edit=!0),i}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,c.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){let t=this.url?s.id?.findCredential(this.url):null;if(!t)return!0;let i=b.credential===t?b.user:await this._fetchEditingUser(e);return b.credential=t,b.user=i,null==i?.privileges||i.privileges.includes("features:user:edit")}async _fetchEditingUser(e){let t=this.portalItem?.portal?.user;if(t)return t;let i=s.id?.findServerInfo(this.url??"");if(!i?.owningSystemUrl)return null;let r=`${i.owningSystemUrl}/sharing/rest`,l=m.A.getDefault();if(l&&l.loaded&&(0,d.S8)(l.restUrl)===(0,d.S8)(r))return l.user;let n=`${r}/community/self`,u=null==e?null:e.signal,h=await(0,a.Ke)((0,o.A)(n,{authMode:"no-prompt",query:{f:"json"},signal:u}));return h.ok?v.A.fromJSON(h.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){return(0,_.wN)(this.portalItem,t)?(t?.messages?.push(new n.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,r.Cg)([(0,y.MZ)({type:g.default})],x.prototype,"portalItem",null),(0,r.Cg)([(0,A.w)("web-document","portalItem",["itemId"])],x.prototype,"readPortalItem",null),(0,r.Cg)([(0,S.K)("web-document","portalItem",{itemId:{type:String}})],x.prototype,"writePortalItem",null),(0,r.Cg)([(0,y.MZ)({clonable:!1})],x.prototype,"resourceReferences",void 0),(0,r.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],x.prototype,"userHasEditingPrivileges",void 0),(0,r.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],x.prototype,"userHasFullEditingPrivileges",void 0),(0,r.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],x.prototype,"userHasUpdateItemPrivileges",void 0),x=(0,r.Cg)([(0,y.$K)("esri.layers.mixins.PortalLayer")],x),x}])},91806(e,t,i){i.d(t,{A:()=>n});var r,l=i(32198),s=i(25482),o=i(91429),a=i(78888);let n=class extends s.o{static{r=this}constructor(e){super(e),this.cols=null,this.level=0,this.levelValue=null,this.origin=null,this.resolution=0,this.rows=null,this.scale=0}clone(){return new r({cols:this.cols,level:this.level,levelValue:this.levelValue,resolution:this.resolution,rows:this.rows,scale:this.scale})}};(0,l.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],n.prototype,"cols",void 0),(0,l.Cg)([(0,o.MZ)({type:a.jz,json:{write:!0}})],n.prototype,"level",void 0),(0,l.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],n.prototype,"levelValue",void 0),(0,l.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],n.prototype,"origin",void 0),(0,l.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],n.prototype,"resolution",void 0),(0,l.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],n.prototype,"rows",void 0),(0,l.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],n.prototype,"scale",void 0),n=r=(0,l.Cg)([(0,o.$K)("esri.layers.support.LOD")],n)},87045(e,t,i){i.d(t,{A:()=>w});var r,l=i(32198),s=i(66552),o=i(25482),a=i(86211),n=i(91429),u=i(78888),h=i(86738),p=i(16930),c=i(21325),d=i(28735),y=i(91806),f=i(72802),m=i(36005),g=i(43937);const v=new s.J({PNG:"png",PNG8:"png8",PNG24:"png24",PNG32:"png32",JPEG:"jpg",JPG:"jpg",DIB:"dib",TIFF:"tiff",EMF:"emf",PS:"ps",PDF:"pdf",GIF:"gif",SVG:"svg",SVGZ:"svgz",Mixed:"mixed",MIXED:"mixed",LERC:"lerc",LERC2D:"lerc2d",RAW:"raw",JPEGPlus:"jpgplus",pbf:"pbf"});let w=class extends o.o{static{r=this}static create(e={}){let{resolutionFactor:t=1,scales:i,size:l=256,spatialReference:s=p.A.WebMercator,numLODs:o=24}=e;if(!(0,c.fn)(s)){let e=[];if(i)for(let t=0;t<i.length;t++){let r=i[t];e.push(new y.A({level:t,scale:r,resolution:r}))}else{let t=5e-4;for(let i=o-1;i>=0;i--)e.unshift(new y.A({level:i,scale:t,resolution:t})),t*=2}return new r({dpi:96,lods:e,origin:new h.A(0,0,s),size:[l,l],spatialReference:s})}let n=(0,c.Vp)(s),u=e.origin?new h.A({x:e.origin.x,y:e.origin.y,spatialReference:s}):n?new h.A({x:n.origin[0],y:n.origin[1],spatialReference:s}):new h.A({x:0,y:0,spatialReference:s}),d=1/(39.37*(0,a.GA)(s)*96),f=[];if(i)for(let e=0;e<i.length;e++){let t=i[e],r=t*d;f.push(new y.A({level:e,scale:t,resolution:r}))}else{let e=(0,c.EA)(s)?512/l*591657527.5917094:256/l*591657527.591555,i=Math.ceil(o/t);f.push(new y.A({level:0,scale:e,resolution:e*d}));for(let r=1;r<i;r++){let i=e/2**t,l=i*d;f.push(new y.A({level:r,scale:i,resolution:l})),e=i}}return new r({dpi:96,lods:f,origin:u,size:[l,l],spatialReference:s})}constructor(e){super(e),this.dpi=96,this.format=null,this.origin=null,this.size=null,this.spatialReference=null}get isWrappable(){let{spatialReference:e,origin:t}=this;if(e&&t){let i=(0,c.Vp)(e);return e.isWrappable&&!!i&&Math.abs(i.origin[0]-t.x)<=i.dx}return!1}readOrigin(e,t){return h.A.fromJSON({spatialReference:t.spatialReference,...e})}set lods(e){let t=0,i=0,r=[],l=this._levelToLOD={};e&&(t=-1/0,i=1/0,e.forEach(e=>{r.push(e.scale),t=e.scale>t?e.scale:t,i=e.scale<i?e.scale:i,l[e.level]=e})),this._set("scales",r),this._set("lods",e),this._initializeUpsampleLevels()}readSize(e,t){return[t.cols,t.rows]}writeSize(e,t){t.cols=e[0],t.rows=e[1]}zoomToScale(e){let t=this.scales;if(e<=0)return t[0];if(e>=t.length-1)return t[t.length-1];let i=Math.floor(e),r=i+1;return t[i]/(t[i]/t[r])**(e-i)}scaleToZoom(e){let t=this.scales,i=t.length-1,r=0;for(;r<i;r++){let i=t[r],l=t[r+1];if(i<=e)return r;if(l===e)return r+1;if(i>e&&l<e)return r+Math.log(i/e)/Math.log(i/l)}return r}tileAt(e,t,i,r){let l,s,o=this.lodAt(e);if(!o)return null;if("number"==typeof t)l=t,s=i;else if((0,c.aI)(t.spatialReference,this.spatialReference))l=t.x,s=t.y,r=i;else{let e=(0,d.Cv)(t,this.spatialReference);if(null==e)return null;l=e.x,s=e.y,r=i}let a=o.resolution*this.size[0],n=o.resolution*this.size[1];return r??=new f.U(0,0,0),r.level=e,r.row=Math.floor((this.origin.y-s)/n+.001),r.col=Math.floor((l-this.origin.x)/a+.001),this.updateTileInfo(r),r}updateTileInfo(e,t=0){if(!("extent"in e))return!1;let i=this.lodAt(e.level);if(!i&&1===t){let t=this.lods[this.lods.length-1];t.level<e.level&&(i=t)}if(!i)return!1;let r=e.level-i.level,l=i.resolution*this.size[0]/2**r,s=i.resolution*this.size[1]/2**r;return e.extent[0]=this.origin.x+e.col*l,e.extent[1]=this.origin.y-(e.row+1)*s,e.extent[2]=e.extent[0]+l,e.extent[3]=e.extent[1]+s,!0}upsampleTile(e){let t=this._upsampleLevels[e.level];return!(!t||-1===t.parentLevel||(e.level=t.parentLevel,e.row=Math.floor(e.row/t.factor+.001),e.col=Math.floor(e.col/t.factor+.001),this.updateTileInfo(e),0))}getTileBounds(e,t){let i=this.lodAt(t.level);if(null==i)return null;let{resolution:r}=i,l=r*this.size[0],s=r*this.size[1];return e[0]=this.origin.x+t.col*l,e[1]=this.origin.y-(t.row+1)*s,e[2]=e[0]+l,e[3]=e[1]+s,e}lodAt(e){return this._levelToLOD?.[e]??null}clone(){return r.fromJSON(this.write({}))}getCompatibleForVTL(e){if(this.size[0]!==this.size[1]||256===this.size[0]&&512===e)return null;let t=(512===this.size[0]&&256===e?-1:0)+ +!!this.spatialReference.isGeographic;if(this.size[0]===e&&0===t)return this;let i=[],l=this.lods.length-t;for(let e=0;e<l;e++){let r=e+t,{scale:l,resolution:s}=r>=0?this.lods[r]:{scale:2*this.lods[0].scale,resolution:2*this.lods[0].resolution};i.push(new y.A({level:e,scale:l,resolution:s}))}return new r({size:[e,e],dpi:this.dpi,format:this.format,compressionQuality:this.compressionQuality,origin:this.origin,spatialReference:this.spatialReference,lods:i})}_initializeUpsampleLevels(){let e=this.lods;this._upsampleLevels=[];let t=null;for(let i=0;i<e.length;i++){let r=e[i];this._upsampleLevels[r.level]={parentLevel:t?t.level:-1,factor:t?t.resolution/r.resolution:0},t=r}}};(0,l.Cg)([(0,n.MZ)({type:Number,json:{write:!0}})],w.prototype,"compressionQuality",void 0),(0,l.Cg)([(0,n.MZ)({type:Number,json:{write:!0}})],w.prototype,"dpi",void 0),(0,l.Cg)([(0,n.MZ)({type:String,json:{read:v.read,write:v.write,origins:{"web-scene":{read:!1,write:!1}}}})],w.prototype,"format",void 0),(0,l.Cg)([(0,n.MZ)({readOnly:!0})],w.prototype,"isWrappable",null),(0,l.Cg)([(0,n.MZ)({type:h.A,json:{write:!0}})],w.prototype,"origin",void 0),(0,l.Cg)([(0,m.w)("origin")],w.prototype,"readOrigin",null),(0,l.Cg)([(0,n.MZ)({type:[y.A],value:null,json:{write:!0}})],w.prototype,"lods",null),(0,l.Cg)([(0,n.MZ)({readOnly:!0})],w.prototype,"scales",void 0),(0,l.Cg)([(0,n.MZ)({cast:e=>Array.isArray(e)?e:"number"==typeof e?[e,e]:[256,256]})],w.prototype,"size",void 0),(0,l.Cg)([(0,m.w)("size",["rows","cols"])],w.prototype,"readSize",null),(0,l.Cg)([(0,g.K)("size",{cols:{type:u.jz},rows:{type:u.jz}})],w.prototype,"writeSize",null),(0,l.Cg)([(0,n.MZ)({type:p.A,json:{write:!0}})],w.prototype,"spatialReference",void 0),w=r=(0,l.Cg)([(0,n.$K)("esri.layers.support.TileInfo")],w)},65509(e,t,i){i.d(t,{A:()=>s});var r=i(49186),l=i(17676);class s{constructor(e,t=0,i=e.lods[e.lods.length-1].level){this.tileInfo=e,this.minLOD=t,this.maxLOD=i,e.lodAt(t)||(this.minLOD=e.lods[0].level),e.lodAt(i)||(this.maxLOD=e.lods[e.lods.length-1].level)}get effectiveMinLOD(){return this.minLOD??this.tileInfo.lods[0].level}get effectiveMaxLOD(){return this.maxLOD??this.tileInfo.lods[this.tileInfo.lods.length-1].level}getAvailability(e,t,i){let r=this.tileInfo?.lodAt(e);return!r||e<this.minLOD||e>this.maxLOD?"unavailable":r.cols&&r.rows?i>=r.cols[0]&&i<=r.cols[1]&&t>=r.rows[0]&&t<=r.rows[1]?"unknown":"unavailable":"unknown"}async fetchAvailability(e,t,i,s){await(0,l.NO)(s);let o=this.getAvailability(e,t,i);if("unavailable"===o)throw new r.A("tile-map:tile-unavailable","Tile is not available",{level:e,row:t,col:i});return o}async fetchAvailabilityUpsample(e,t,i,r,s){await(0,l.NO)(s),r.level=e,r.row=t,r.col=i;let o=this.tileInfo;return o.updateTileInfo(r),this.fetchAvailability(e,t,i,s).catch(e=>{if((0,l.zf)(e))throw e;if(o.upsampleTile(r))return this.fetchAvailabilityUpsample(r.level,r.row,r.col,r,s);throw e})}}},72802(e,t,i){i.d(t,{U:()=>l});var r=i(19419);class l{constructor(e,t,i,l=(0,r.vt)()){this._level=e,this._row=t,this._col=i,this.extent=l}get id(){return this._id??=`${this.level}/${this.row}/${this.col}`,this._id}get level(){return this._level}set level(e){this._level=e,this._id=null}get row(){return this._row}set row(e){this._row=e,this._id=null}get col(){return this._col}set col(e){this._col=e,this._id=null}toJSON(){return{level:this._level,row:this._row,col:this._col,extent:this.extent}}static fromJSON(e){return new l(e.level,e.row,e.col,e.extent)}}},25943(e,t,i){i.d(t,{d:()=>S});var r,l=i(32198),s=i(56507),o=i(69622),a=i(49186),n=i(36563),u=(i(44208),i(66344)),h=i(15142),p=i(17676),c=i(36708),d=i(76030),y=i(84952),f=i(91429),m=i(72802),g=i(4718),v=i(69397);class w{constructor(e){!function(e){if(!e?.location)throw new a.A("tilemap:missing-location","Location missing from tilemap response");if(!1===e.valid)throw new a.A("tilemap:invalid","Tilemap response was marked as invalid");if(!e.data)throw new a.A("tilemap:missing-data","Data missing from tilemap response");if(!Array.isArray(e.data))throw new a.A("tilemap:data-mismatch","Data must be an array of numbers");if(e.data.length!==e.location.width*e.location.height)throw new a.A("tilemap:data-mismatch","Number of data items does not match width/height of tilemap")}(e);let{location:t,data:i}=e;this.location=Object.freeze((0,g.o8)(t));let r=this.location.width,l=this.location.height,s=!0,o=!0,n=function(e,t=!1){return e<=1024?t?Array(e).fill(0):Array(e):new Uint32Array(e)}(Math.ceil(r*l/32)),u=0;for(let e=0;e<i.length;e++){let t=e%32;i[e]?(o=!1,n[u]|=1<<t):s=!1,31===t&&++u}o?(this._availability="unavailable",this.byteSize=40):s?(this._availability="available",this.byteSize=40):(this._availability=n,this.byteSize=40+(0,v.Qf)(n))}getAvailability(e,t){if("unavailable"===this._availability||"available"===this._availability)return this._availability;let i=(e-this.location.top)*this.location.width+(t-this.location.left),r=i%32,l=i>>5,s=this._availability;return l<0||l>s.length?"unknown":s[l]&1<<r?"available":"unavailable"}static fromDefinition(e,t){let i=e.service.request||s.A,{row:r,col:l,width:o,height:n}=e,u={query:{f:"json"}};return t=t?{...u,...t}:u,i(function(e){let t;if(e.service.tileServers?.length){let i=e.service.tileServers;t=`${i&&i.length?i[e.row%i.length]:e.service.url}/tilemap/${e.level}/${e.row}/${e.col}/${e.width}/${e.height}`}else t=`${e.service.url}/tilemap/${e.level}/${e.row}/${e.col}/${e.width}/${e.height}`;let i=e.service.query;return i&&(t=`${t}?${i}`),t}(e),t).then(e=>e.data).catch(e=>{if(422===e?.details?.httpStatus)return{location:{top:r,left:l,width:o,height:n},valid:!0,data:Array(o*n).fill(0)};throw e}).then(e=>{if(e.location&&(e.location.top!==r||e.location.left!==l||e.location.width!==o||e.location.height!==n))throw new a.A("tilemap:location-mismatch","Tilemap response for different location than requested",{response:e,definition:{top:r,left:l,width:o,height:n}});return w.fromJSON(e)})}static fromJSON(e){return Object.freeze(new w(e))}}function _(e){return`${e.level}/${e.row}/${e.col}/${e.width}/${e.height}`}function A(e,t,i){return new a.A("tile-map:tile-unavailable","Tile is not available",{level:e,row:t,col:i})}let S=class extends o.A{static{r=this}constructor(e){super(e),this._pendingTilemapRequests={},this.request=s.A,this.size=32,this._prefetchingEnabled=!0}initialize(){this._tilemapCache=new u.q(2097152),this.addHandles((0,c.wB)(()=>{let{layer:e}=this;return[e?.parsedUrl,e?.tileServers,e?.apiKey,e?.customParameters]},()=>this._initializeTilemapDefinition(),c.Vh))}get effectiveMinLOD(){return this.minLOD??this.layer.tileInfo.lods[0].level}get effectiveMaxLOD(){return this.maxLOD??this.layer.tileInfo.lods[this.layer.tileInfo.lods.length-1].level}getAvailability(e,t,i){if(!this.layer.tileInfo.lodAt(e)||e<this.effectiveMinLOD||e>this.effectiveMaxLOD)return"unavailable";let r=this._tilemapFromCache(e,t,i,this._tmpTilemapDefinition);return r?r.getAvailability(t,i):"unknown"}fetchAvailability(e,t,i,r){return!this.layer.tileInfo.lodAt(e)||e<this.effectiveMinLOD||e>this.effectiveMaxLOD?Promise.reject(A(e,t,i)):this._fetchTilemap(e,t,i,r).catch(e=>e).then(r=>{if(r instanceof w){let l=r.getAvailability(t,i);if("unavailable"===l)throw A(e,t,i);return l}if((0,p.zf)(r))throw r;return"unknown"})}fetchAvailabilityUpsample(e,t,i,r,l){r.level=e,r.row=t,r.col=i;let s=this.layer.tileInfo;s.updateTileInfo(r);let o=this.fetchAvailability(e,t,i,l).catch(e=>{if((0,p.zf)(e))throw e;if(s.upsampleTile(r))return this.fetchAvailabilityUpsample(r.level,r.row,r.col,r,l);throw e});return this._fetchAvailabilityUpsamplePrefetch(e,t,i,l,o),o}async _fetchAvailabilityUpsamplePrefetch(e,t,i,l,s){if(!this._prefetchingEnabled)return;let o=`prefetch-${e}-${t}-${i}`;if(this.hasHandles(o))return;let a=new AbortController;s.then(()=>a.abort(),()=>a.abort());let u=!1,h=(0,n.hA)(()=>{u||(u=!0,a.abort())});if(this.addHandles(h,o),await(0,d.md)(10,a.signal).catch(()=>{}),u||(u=!0,this.removeHandles(o)),(0,p.G4)(a))return;let c=new m.U(e,t,i),y={...l,signal:a.signal},f=this.layer.tileInfo;for(let e=0;r._prefetches.length<r._maxPrefetch&&f.upsampleTile(c);++e){let e=this.fetchAvailability(c.level,c.row,c.col,y);r._prefetches.push(e);let t=()=>{r._prefetches.removeUnordered(e)};e.then(t,t)}}static{this._maxPrefetch=4}static{this._prefetches=new h.A({initialSize:r._maxPrefetch})}static cleanupTilemapCache(){this._prefetches.prune()}_fetchTilemap(e,t,i,r){if(!this.layer.tileInfo.lodAt(e)||e<this.effectiveMinLOD||e>this.effectiveMaxLOD)return Promise.reject(new a.A("tilemap-cache:level-unavailable",`Level ${e} is unavailable in the service`));let l=this._tmpTilemapDefinition,s=this._tilemapFromCache(e,t,i,l);if(s)return Promise.resolve(s);let o=r?.signal;return r={...r,signal:null},new Promise((e,t)=>{(0,p.u7)(o,()=>t((0,p.NK)()));let i=_(l),s=this._pendingTilemapRequests[i];if(!s){s=w.fromDefinition(l,r).then(e=>(this._tilemapCache.put(i,e,e.byteSize),e));let e=()=>{delete this._pendingTilemapRequests[i]};this._pendingTilemapRequests[i]=s,s.then(e,e)}s.then(e,t)})}_initializeTilemapDefinition(){if(!this.layer.parsedUrl)return;let{parsedUrl:e,apiKey:t,customParameters:i}=this.layer;this._tilemapCache.clear(),this._tmpTilemapDefinition={service:{url:e.path,query:(0,y.x0)({...e.query,...i,token:t??e.query?.token}),tileServers:this.layer.tileServers,request:this.request},width:this.size,height:this.size,level:0,row:0,col:0}}_tilemapFromCache(e,t,i,r){r.level=e,r.row=t-t%this.size,r.col=i-i%this.size;let l=_(r);return this._tilemapCache.get(l)}get test(){}};(0,l.Cg)([(0,f.MZ)({constructOnly:!0})],S.prototype,"layer",void 0),(0,l.Cg)([(0,f.MZ)({constructOnly:!0})],S.prototype,"minLOD",void 0),(0,l.Cg)([(0,f.MZ)({constructOnly:!0})],S.prototype,"maxLOD",void 0),(0,l.Cg)([(0,f.MZ)({constructOnly:!0})],S.prototype,"request",void 0),(0,l.Cg)([(0,f.MZ)({constructOnly:!0})],S.prototype,"size",void 0),S=r=(0,l.Cg)([(0,f.$K)("esri.layers.support.TilemapCache")],S)},88788(e,t,i){i.d(t,{m:()=>o,v:()=>s});var r=i(84952),l=i(20655);function s(e,t){return{...a(e,t),readResourcePaths:[]}}function o(e,t,i){let l=(0,r.An)(i?.forceNewItemContext?null:e.itemUrl);return{...a(e,t,i),messages:[],writtenProperties:[],blockedRelativeUrls:[],verifyItemRelativeUrls:l?{rootPath:l.path,writtenUrls:[]}:null,resources:i?.withResources?{toAdd:[],toUpdate:[],toKeep:[],pendingOperations:[]}:null}}function a(e,t,i){return{origin:t,url:(0,r.An)(i?.forceNewItemContext?null:e.itemUrl),portal:e.portal||l.A.getDefault(),portalItem:e}}},10407(e,t,i){i.d(t,{It:()=>d,LG:()=>o,OM:()=>u,Sm:()=>h,Y:()=>a,bK:()=>n,sQ:()=>p});var r=i(99917),l=i(16930),s=i(28735);function o(e,t){if(!a(e,t)){let i=e.typeKeywords;i?i.push(t):e.typeKeywords=[t]}}function a(e,t){return!!e.typeKeywords?.includes(t)}function n(e){return a(e,c.HOSTED_SERVICE)}function u(e,t){let i=e.typeKeywords;if(i){let e=i.indexOf(t);e>-1&&i.splice(e,1)}}function h(e,t,i){i?o(e,t):u(e,t)}async function p(e){let t,i=e.clone().normalize();if(i.length>1)for(let e of i)t?e.width>t.width&&(t=e):t=e;else t=i[0];return async function(e){let t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,s.ci)(e);let i=l.A.WGS84;return await(0,r.initializeProjection)(t,i),(0,r.project)(e,i)}(t)}const c={CHARTS:"Charts",CATALOG_LAYER:"CatalogLayer",DYNAMIC:"Dynamic",DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",PARCEL_FABRIC:"ParcelFabric",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery",UTILITY_NETWORK:"UtilityNetwork"};function d(e){let{portal:t,isOrgItem:i,itemControl:r}=e,l=t.user?.privileges,s=!l||l.includes("features:user:edit"),o=!!i&&!!l?.includes("features:user:fullEdit"),a="update"===r||"admin"===r;return a?o=s=!0:o&&(s=!0),{features:{edit:s,fullEdit:o},content:{updateItem:a}}}i.d(t,["mm",0,c])},44159(e,t,i){i.d(t,{A:()=>l});var r=i(93687);class l{static{this.pool=new r.A(()=>new l(""),null,null,25,50)}static getId(e,t,i,r){return"object"==typeof e?`${e.level}/${e.row}/${e.col}/${e.world}`:`${e}/${t}/${i}/${r}`}constructor(e,t,i,r){this.set(e,t,i,r)}get key(){return this}get id(){return this.toString()}get normalizedId(){return`${this.level}/${this.row}/${this.col}`}set id(e){this.set(e)}get hash(){let e=4095&this.row,t=4095&this.col,i=63&this.level;return(3&this.world)<<30|t<<22|e<<8|i}acquire(e,t,i,r){this.set(e,t,i,r)}contains(e){let t=e.level-this.level;return t>=0&&this.row===e.row>>t&&this.col===e.col>>t&&this.world===e.world}containsChild(e){let t=e.level-this.level;return t>0&&this.row===e.row>>t&&this.col===e.col>>t&&this.world===e.world}equals(e){return this.level===e.level&&this.row===e.row&&this.col===e.col&&this.world===e.world}clone(){return new l(this)}release(){this.level=0,this.row=0,this.col=0,this.world=0}set(e,t,i,r){if(null==e)this.level=0,this.row=0,this.col=0,this.world=0;else if("object"==typeof e)this.level=e.level||0,this.row=e.row||0,this.col=e.col||0,this.world=e.world||0;else if("string"==typeof e){let[t,i,r,l]=e.split("/");this.level=parseFloat(t),this.row=parseFloat(i),this.col=parseFloat(r),this.world=parseFloat(l)}else this.level=+e,this.row=+t,this.col=+i,this.world=+r||0;return this}toString(){return`${this.level}/${this.row}/${this.col}/${this.world}`}getParentKey(){return this.level<=0?null:new l(this.level-1,this.row>>1,this.col>>1,this.world)}getNormalizedNeighbor(e,t,i){let r=this.clone();return r.col+=e,r.row+=t,i.normalizeKey(r),r}getChildKeys(){let e=this.level+1,t=this.row<<1,i=this.col<<1,r=this.world;return[new l(e,t,i,r),new l(e,t,i+1,r),new l(e,t+1,i,r),new l(e,t+1,i+1,r)]}compareRowMajor(e){return this.row<e.row?-1:this.row>e.row?1:this.col<e.col?-1:+(this.col>e.col)}}},78553(e,t,i){i.d(t,{D:()=>s,p:()=>l});var r=i(78888);function l(e){let t=(0,r.Vr)(100*(1-e));return Math.max(0,Math.min(t,100))}function s(e){let t=1-e/100;return Math.max(0,Math.min(t,1))}},26121(e,t,i){i.d(t,{I6:()=>h,ci:()=>u,dL:()=>n,wN:()=>p});var r=i(49186),l=i(84952),s=i(77548),o=i(20655),a=i(59923);async function n(e){let t=[];for(let i of e.allLayers)if("beforeSave"in i&&"function"==typeof i.beforeSave){let e=i.beforeSave();e&&t.push(e)}await Promise.allSettled(t)}function u(e,t,i){let l=(e.messages??[]).filter(({type:e})=>"error"===e).map(({name:e,message:t,details:i})=>new r.A(e,t,i));if(e.blockedRelativeUrls&&(l=l.concat(e.blockedRelativeUrls.map(e=>(0,a.GL)("url",`Relative url '${e}' is not supported`)))),i){let{ignoreUnsupported:e,supplementalUnsupportedErrors:t=[],requiredPropertyChecksDisabled:r}=i;e&&(l=l.filter(({name:e})=>!(a.MG.has(e)||t.includes(e)))),r&&(l=l.filter(e=>"web-document-write:property-required"!==e.name))}if(l.length>0)throw new r.A(t.errorName,"Failed to save due to unsupported or invalid content. See 'details.errors' for more detailed information",{errors:l})}function h(e){return(0,s.qd)(e).some(e=>!!e.charts?.length)}function p(e,t){let i=t?.portal,r=e?.id&&(e.portal||o.A.getDefault());return!!i&&!!r&&!(0,l.ut)(r.restUrl,i.restUrl)}}}]);