@arcgis/core 5.1.0-next.53 → 5.1.0-next.55

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 (477) hide show
  1. package/analysis/VolumeMeasurement/volumeMeasurementConfiguration.js +1 -1
  2. package/applications/Components/SketchTooltipControls.d.ts +3 -2
  3. package/applications/Components/SketchTooltipControls.js +1 -1
  4. package/applications/Components/navigationDuration.d.ts +15 -0
  5. package/applications/Components/navigationDuration.js +2 -0
  6. package/assets/esri/core/workers/RemoteClient.js +1 -1
  7. package/assets/esri/core/workers/chunks/05bc675c029ed311427f.js +1 -0
  8. package/assets/esri/core/workers/chunks/05d25a98c54679233902.js +1 -0
  9. package/assets/esri/core/workers/chunks/0b4a2361b9f9a6c0b8a7.js +1 -0
  10. package/assets/esri/core/workers/chunks/0e88e61d89f89994c4bf.js +1 -0
  11. package/assets/esri/core/workers/chunks/0f2ab57e4eb722b3b0c0.js +1 -0
  12. package/assets/esri/core/workers/chunks/{f4d31d96681b649ddc95.js → 0ff12fe9e358100668d9.js} +1 -1
  13. package/assets/esri/core/workers/chunks/1613123918e9b0f7cfdb.js +1 -0
  14. package/assets/esri/core/workers/chunks/1a198c9e17f7a058669e.js +1 -0
  15. package/assets/esri/core/workers/chunks/1f91280032aa42b1585b.js +1 -0
  16. package/assets/esri/core/workers/chunks/2327b368673a974dee8b.js +1 -0
  17. package/assets/esri/core/workers/chunks/23eb204d3cb818adea32.js +1 -0
  18. package/assets/esri/core/workers/chunks/254898b41cabe313b6ce.js +1 -0
  19. package/assets/esri/core/workers/chunks/26cafd20c8d03c274389.js +1 -0
  20. package/assets/esri/core/workers/chunks/{a69f1879735a031f62e9.js → 2a2d5f9ea42cb2eee9c6.js} +1 -1
  21. package/assets/esri/core/workers/chunks/2bc6edeb3156d241677b.js +1 -0
  22. package/assets/esri/core/workers/chunks/{d587b7842091affdaac3.js → 3158a3487d3e8a61b680.js} +1 -1
  23. package/assets/esri/core/workers/chunks/34acecd7a314fed12335.js +1 -0
  24. package/assets/esri/core/workers/chunks/{07e791530677f7e70f32.js → 3a2ecb883fdb5c598544.js} +2 -2
  25. package/assets/esri/core/workers/chunks/{cdeb6aec578a1c07d663.js → 3cb0f020f9bfc6653c5d.js} +1 -1
  26. package/assets/esri/core/workers/chunks/3e0752a81a7247c567ab.js +1 -0
  27. package/assets/esri/core/workers/chunks/3ef740d25dc17bef11b2.js +1 -0
  28. package/assets/esri/core/workers/chunks/42e084704dea6e4135b6.js +1 -0
  29. package/assets/esri/core/workers/chunks/{5b3bb636e3bec625e515.js → 4301cb9670fa7c907460.js} +1 -1
  30. package/assets/esri/core/workers/chunks/457bbf27e9bc18132464.js +1 -0
  31. package/assets/esri/core/workers/chunks/45eddf3918973fa8d751.js +1 -0
  32. package/assets/esri/core/workers/chunks/48eca6f51112ba80bd3b.js +1 -0
  33. package/assets/esri/core/workers/chunks/4a6186001323b47c23a4.js +1 -0
  34. package/assets/esri/core/workers/chunks/4b3622fc355fd2fd8678.js +1 -0
  35. package/assets/esri/core/workers/chunks/4e7bb224bde9e5039263.js +1 -0
  36. package/assets/esri/core/workers/chunks/4f847a426973bd350c11.js +1 -0
  37. package/assets/esri/core/workers/chunks/{193775b3b7de8f5dc578.js → 4fb718174c6e07d752e0.js} +1 -1
  38. package/assets/esri/core/workers/chunks/5143f74f1fe7533a6069.js +1 -0
  39. package/assets/esri/core/workers/chunks/{36425d29aaa5852cb41d.js → 522bc1d79dbe957301e4.js} +1 -1
  40. package/assets/esri/core/workers/chunks/52dbfd7519555028a8af.js +1 -0
  41. package/assets/esri/core/workers/chunks/55214e1d9f3d98fa7ed9.js +1 -0
  42. package/assets/esri/core/workers/chunks/56bce3a6701f8549606b.js +1 -0
  43. package/assets/esri/core/workers/chunks/572fcd33ae3648ed4f9c.js +1 -0
  44. package/assets/esri/core/workers/chunks/576a1784e93c5406e657.js +1 -0
  45. package/assets/esri/core/workers/chunks/59289867cce97da74e39.js +1 -0
  46. package/assets/esri/core/workers/chunks/{fdf8fe0f50a9ae548c16.js → 5a1d975b3e9e6b7eff67.js} +1 -1
  47. package/assets/esri/core/workers/chunks/5a83ea967ecde01d5622.js +1 -0
  48. package/assets/esri/core/workers/chunks/5a9620cb66c8e64e4668.js +1 -0
  49. package/assets/esri/core/workers/chunks/5aff2d6ae0d2a2d92ecc.js +1 -0
  50. package/assets/esri/core/workers/chunks/5eb9fdb076488de9cd83.js +1 -0
  51. package/assets/esri/core/workers/chunks/66fc3c4d6c54eee231b9.js +1 -0
  52. package/assets/esri/core/workers/chunks/{de359f89e03da18999fc.js → 691d0a60354b6458b9de.js} +1 -1
  53. package/assets/esri/core/workers/chunks/69644b8a6ce340ca1159.js +1 -0
  54. package/assets/esri/core/workers/chunks/6ab8ed12d162d79a8c55.js +1 -0
  55. package/assets/esri/core/workers/chunks/{d44217de4c73475f9c66.js → 73a045061e69a22b6869.js} +1 -1
  56. package/assets/esri/core/workers/chunks/76064c2c801da55cd844.js +1 -0
  57. package/assets/esri/core/workers/chunks/770880ad43f252962017.js +1 -0
  58. package/assets/esri/core/workers/chunks/78cb6b9ab32abdd1d530.js +1 -0
  59. package/assets/esri/core/workers/chunks/7b6e3cc086d13da770fa.js +1 -0
  60. package/assets/esri/core/workers/chunks/7ed2aa1092c0a2c839c0.js +1 -0
  61. package/assets/esri/core/workers/chunks/83113a9e284701d053b5.js +1 -0
  62. package/assets/esri/core/workers/chunks/8418ad9ad7b6481ebe82.js +1 -0
  63. package/assets/esri/core/workers/chunks/85c72d9fa533552a6e8a.js +1 -0
  64. package/assets/esri/core/workers/chunks/861a7d0e665add901e11.js +1 -0
  65. package/assets/esri/core/workers/chunks/87077f4cbca13e030411.js +1 -0
  66. package/assets/esri/core/workers/chunks/{199f70c0373f6008a545.js → 8df0c154bb0d79a905c0.js} +1 -1
  67. package/assets/esri/core/workers/chunks/9066f095f16448c0a04e.js +1 -0
  68. package/assets/esri/core/workers/chunks/91718795fc4ca6516ac7.js +1 -0
  69. package/assets/esri/core/workers/chunks/929b26999321519824b9.js +1 -0
  70. package/assets/esri/core/workers/chunks/9321f5ec514805307219.js +1 -0
  71. package/assets/esri/core/workers/chunks/932a0b39d85a76377d52.js +1 -0
  72. package/assets/esri/core/workers/chunks/93d1118f7a909d123b40.js +1 -0
  73. package/assets/esri/core/workers/chunks/94f80c46ccf5e19038b8.js +1 -0
  74. package/assets/esri/core/workers/chunks/979c2f52b6d6e1e8241b.js +1 -0
  75. package/assets/esri/core/workers/chunks/{617328964d480d4a3a45.js → 9806cc96414065ae0afe.js} +1 -1
  76. package/assets/esri/core/workers/chunks/{e6220c1fa887e21ffbbd.js → 9a235c92f21df2c17aa8.js} +1 -1
  77. package/assets/esri/core/workers/chunks/{f7fb121169b7e5a5adbc.js → 9d11e7972bc298cb94ce.js} +1 -1
  78. package/assets/esri/core/workers/chunks/a11f05ddd8314b648f76.js +1 -0
  79. package/assets/esri/core/workers/chunks/{15a45e26964c2eb381a6.js → a256edc8337e462f80f0.js} +1 -1
  80. package/assets/esri/core/workers/chunks/a41fabf8b2cf15b7d0c9.js +1 -0
  81. package/assets/esri/core/workers/chunks/{987dc23fdc0a8c7150b9.js → a5bf2718c02a0e645013.js} +1 -1
  82. package/assets/esri/core/workers/chunks/a7a553e245ba011d259f.js +1 -0
  83. package/assets/esri/core/workers/chunks/a8e111a5cfd6151d5dbb.js +1 -0
  84. package/assets/esri/core/workers/chunks/a9eb90b901e64e67b7a3.js +1 -0
  85. package/assets/esri/core/workers/chunks/{21decfc1e477fb769204.js → aa7aaeae31ddb259e55e.js} +1 -1
  86. package/assets/esri/core/workers/chunks/ad1946c084219bb678a0.js +1 -0
  87. package/assets/esri/core/workers/chunks/aed45f7e7eee154a21b8.js +1 -0
  88. package/assets/esri/core/workers/chunks/b056b4c79bcd542dd1d2.js +1 -0
  89. package/assets/esri/core/workers/chunks/b1a0a7cdaf50f98adb3e.js +1 -0
  90. package/assets/esri/core/workers/chunks/b20f4c82d0b44fdb4670.js +1 -0
  91. package/assets/esri/core/workers/chunks/b39b4db86a1049f0b901.js +1 -0
  92. package/assets/esri/core/workers/chunks/{1a1e57267306c07e5bdb.js → b3f0600729227b458a75.js} +1 -1
  93. package/assets/esri/core/workers/chunks/bacc343a79828e456de7.js +1 -0
  94. package/assets/esri/core/workers/chunks/bb047157f09471ecea53.js +1 -0
  95. package/assets/esri/core/workers/chunks/bc3b22dc08c147b8d425.js +1 -0
  96. package/assets/esri/core/workers/chunks/{29c91b5c9ddcea85f39a.js → c250799c131aa4ed2c35.js} +1 -1
  97. package/assets/esri/core/workers/chunks/{a495e60996a36ce19a32.js → c4da2ca1dee0c44051d0.js} +1 -1
  98. package/assets/esri/core/workers/chunks/c6149e0ac1c103e03baf.js +1 -0
  99. package/assets/esri/core/workers/chunks/c69fefe9d51ac7c2b0a6.js +1 -0
  100. package/assets/esri/core/workers/chunks/c86b15f6a18880f921cd.js +1 -0
  101. package/assets/esri/core/workers/chunks/c91d39e8e14be3d8bdf5.js +1 -0
  102. package/assets/esri/core/workers/chunks/c9c5e6996f36ec4b1558.js +1 -0
  103. package/assets/esri/core/workers/chunks/cd391415b8b8320e12e4.js +1 -0
  104. package/assets/esri/core/workers/chunks/d3b3e8c6d7096bc59489.js +1 -0
  105. package/assets/esri/core/workers/chunks/{81b830f0d620587966ca.js → d53c6fc10425adc2c0cf.js} +1 -1
  106. package/assets/esri/core/workers/chunks/d9444dd0d40aa8332b28.js +1 -0
  107. package/assets/esri/core/workers/chunks/da0a61f73d45ea9e71fc.js +1 -0
  108. package/assets/esri/core/workers/chunks/da2a10e72a315c3c1f82.js +1 -0
  109. package/assets/esri/core/workers/chunks/{9ae90a4b281d4103e8bb.js → dc07dc1cd30edc0c4193.js} +1 -1
  110. package/assets/esri/core/workers/chunks/de79645e559a2d1ffa67.js +1 -0
  111. package/assets/esri/core/workers/chunks/e2e3c39876bbe019c57a.js +1 -0
  112. package/assets/esri/core/workers/chunks/e543bb228f3f9d937d43.js +1 -0
  113. package/assets/esri/core/workers/chunks/e7e565e7c0ce1464c6b0.js +1 -0
  114. package/assets/esri/core/workers/chunks/e8a23ae30d586e3a973c.js +1 -0
  115. package/assets/esri/core/workers/chunks/{3c9e1ec94bbcbf494916.js → ea068f75397c3b3337ec.js} +3 -3
  116. package/assets/esri/core/workers/chunks/ec21311584e4fb13e510.js +1 -0
  117. package/assets/esri/core/workers/chunks/{c09bc36347e8eb9fff00.js → f09446b9ff937a84d6d3.js} +1 -1
  118. package/assets/esri/core/workers/chunks/{354b309c8225336bc1e5.js → f6d047358d14328f3622.js} +1 -1
  119. package/assets/esri/core/workers/chunks/f8ee1a99580a7da42cde.js +1 -0
  120. package/assets/esri/core/workers/chunks/{c6a0e770c1a89d3b5913.js → fb9a889ec9fd23739a14.js} +1 -1
  121. package/assets/esri/core/workers/chunks/{b2a67fe89f6505498bc3.js → fe1b67ab7748a3aef231.js} +1 -1
  122. package/assets/esri/core/workers/chunks/fe92f54e45fd21ccd75f.js +1 -0
  123. package/assets/esri/core/workers/chunks/ff0cb1eec14d34214f12.js +1 -0
  124. package/assets/esri/rest/knowledgeGraph/wasmInterface/arcgis-knowledge-client-core-simd.wasm +0 -0
  125. package/assets/esri/rest/knowledgeGraph/wasmInterface/arcgis-knowledge-client-core.wasm +0 -0
  126. package/assets/esri/themes/base/_Ui.scss +3 -3
  127. package/assets/esri/themes/base/_mixins.scss +2 -2
  128. package/assets/esri/themes/base/widgets/_Attachments.scss +3 -3
  129. package/assets/esri/themes/base/widgets/_BasemapGallery.scss +8 -8
  130. package/assets/esri/themes/base/widgets/_BasemapToggle.scss +1 -1
  131. package/assets/esri/themes/base/widgets/_BuildingExplorer.scss +1 -1
  132. package/assets/esri/themes/base/widgets/_BuildingLevelPicker.scss +4 -4
  133. package/assets/esri/themes/base/widgets/_BuildingPhasePicker.scss +1 -1
  134. package/assets/esri/themes/base/widgets/_CoordinateConversion.scss +2 -2
  135. package/assets/esri/themes/base/widgets/_DatePicker.scss +4 -4
  136. package/assets/esri/themes/base/widgets/_Daylight.scss +1 -1
  137. package/assets/esri/themes/base/widgets/_Editor.scss +2 -2
  138. package/assets/esri/themes/base/widgets/_ElevationProfile.scss +2 -2
  139. package/assets/esri/themes/base/widgets/_FeatureMedia.scss +1 -1
  140. package/assets/esri/themes/base/widgets/_FeatureTable.scss +1 -1
  141. package/assets/esri/themes/base/widgets/_FloorFilter.scss +2 -2
  142. package/assets/esri/themes/base/widgets/_Grid.scss +1 -1
  143. package/assets/esri/themes/base/widgets/_GridControls.scss +1 -1
  144. package/assets/esri/themes/base/widgets/_ItemList.scss +1 -1
  145. package/assets/esri/themes/base/widgets/_Legend.scss +1 -1
  146. package/assets/esri/themes/base/widgets/_LineOfSight.scss +1 -1
  147. package/assets/esri/themes/base/widgets/_OrientedImageryViewer.scss +1 -1
  148. package/assets/esri/themes/base/widgets/_OrientedImageryViewerNavigationUI.scss +3 -3
  149. package/assets/esri/themes/base/widgets/_Popup.scss +1 -1
  150. package/assets/esri/themes/base/widgets/_Print.scss +3 -3
  151. package/assets/esri/themes/base/widgets/_Sketch.scss +1 -1
  152. package/assets/esri/themes/base/widgets/_Slice.scss +1 -1
  153. package/assets/esri/themes/base/widgets/_Slider.scss +3 -3
  154. package/assets/esri/themes/base/widgets/_SnappingControls.scss +2 -2
  155. package/assets/esri/themes/base/widgets/_Spinner.scss +2 -2
  156. package/assets/esri/themes/base/widgets/_Swipe.scss +2 -2
  157. package/assets/esri/themes/base/widgets/_Tooltip.scss +2 -2
  158. package/assets/esri/themes/base/widgets/_UtilityNetworkTrace.scss +1 -1
  159. package/assets/esri/themes/base/widgets/_VideoPlayer.scss +2 -2
  160. package/assets/esri/themes/base/widgets/_Widget.scss +8 -8
  161. package/assets/esri/themes/dark/main.css +1 -1
  162. package/assets/esri/themes/light/main.css +1 -1
  163. package/assets/esri/themes/light/view.css +1 -1
  164. package/chunks/CutFillComposition.glsl.js +10 -4
  165. package/chunks/OITBlend.glsl.js +2 -2
  166. package/chunks/RibbonLine.glsl.js +75 -63
  167. package/chunks/ShadowHighlight.glsl.js +1 -1
  168. package/chunks/Viewshed.glsl.js +2 -2
  169. package/chunks/Water.glsl.js +24 -16
  170. package/chunks/arcgis-knowledge-client-core-simd.js +1 -1
  171. package/chunks/arcgis-knowledge-client-core.js +1 -1
  172. package/config.js +1 -1
  173. package/core/libs/gl-matrix-2/math/vec3.js +1 -1
  174. package/geometry/SpatialReference.js +1 -1
  175. package/geometry/operators/offsetOperator.d.ts +1 -1
  176. package/geometry/operators/proximityOperator.d.ts +1 -1
  177. package/geometry/operators/support/apiConverter.js +1 -1
  178. package/geometry/support/aaBoundingBox.js +1 -1
  179. package/geometry/support/curves/bezierCurveUtils.js +1 -1
  180. package/geometry/support/curves/circularArcUtils.js +1 -1
  181. package/geometry/support/curves/ellipticArc4Utils.js +1 -1
  182. package/geometry/support/curves/ellipticArc7Utils.js +1 -1
  183. package/geometry/support/geometryUtils.js +1 -1
  184. package/geometry/support/zscale.js +1 -1
  185. package/interfaces.d.ts +7 -0
  186. package/kernel.js +1 -1
  187. package/layers/LinkChartLayer.js +1 -1
  188. package/layers/OrientedImageryLayer.d.ts +0 -152
  189. package/layers/OrientedImageryLayer.js +1 -1
  190. package/layers/support/layerUtils.js +1 -1
  191. package/package.json +1 -1
  192. package/portal/schemas/definitions.js +1 -1
  193. package/rest/knowledgeGraph/wasmInterface/knowledgeWasmAccess.js +1 -1
  194. package/support/revision.js +1 -1
  195. package/support/tests/serviceMockDependencies.js +1 -1
  196. package/views/2d/engine/flow/FlowContainer.js +1 -1
  197. package/views/2d/engine/flow/FlowStrategy.js +1 -1
  198. package/views/2d/engine/flow/FlowView2D.js +1 -1
  199. package/views/2d/engine/flow/dataUtils.js +1 -1
  200. package/views/2d/engine/flow/particleConstants.js +2 -0
  201. package/views/2d/engine/flow/styles/Imagery.js +1 -1
  202. package/views/2d/engine/flow/styles/Particles.js +1 -1
  203. package/views/2d/engine/flow/styles/Stack.js +1 -1
  204. package/views/2d/engine/flow/styles/Streamlines.js +1 -1
  205. package/views/2d/engine/flow/utils.js +1 -1
  206. package/views/2d/engine/imagery/RasterVFContainer.js +1 -1
  207. package/views/2d/engine/webgl/Painter.js +1 -1
  208. package/views/2d/engine/webgl/Profiler.js +1 -1
  209. package/views/2d/engine/webgl/WGLContainer.js +1 -1
  210. package/views/2d/engine/webgl/mesh/templates/shapingUtils.js +1 -1
  211. package/views/2d/engine/webgl/shaderGraph/techniques/TechniqueRegistry.js +1 -1
  212. package/views/2d/engine/webgl/shaderGraph/techniques/TestTechnique.js +1 -1
  213. package/views/2d/engine/webgl/shaderGraph/techniques/TextureStatisticsTechnique.js +1 -1
  214. package/views/2d/engine/webgl/shaderGraph/techniques/fill/FillTechnique.js +1 -1
  215. package/views/2d/engine/webgl/shaderGraph/techniques/fill/GradientFillTechnique.js +1 -1
  216. package/views/2d/engine/webgl/shaderGraph/techniques/fill/OutlineFillTechnique.js +1 -1
  217. package/views/2d/engine/webgl/shaderGraph/techniques/fill/PatternFillTechnique.js +1 -1
  218. package/views/2d/engine/webgl/shaderGraph/techniques/fill/PatternOutlineFillTechnique.js +1 -1
  219. package/views/2d/engine/webgl/shaderGraph/techniques/flow/FlowTechnique.js +2 -0
  220. package/views/2d/engine/webgl/shaderGraph/techniques/grid/GridTechnique.js +1 -1
  221. package/views/2d/engine/webgl/shaderGraph/techniques/heatmap/HeatmapTechnique.js +1 -1
  222. package/views/2d/engine/webgl/shaderGraph/techniques/labels/LabelMeshWriter.js +1 -1
  223. package/views/2d/engine/webgl/shaderGraph/techniques/labels/LabelTechnique.js +1 -1
  224. package/views/2d/engine/webgl/shaderGraph/techniques/line/GradientStrokeTechnique.js +1 -1
  225. package/views/2d/engine/webgl/shaderGraph/techniques/line/LineTechnique.js +1 -1
  226. package/views/2d/engine/webgl/shaderGraph/techniques/line/TexturedLineTechnique.js +1 -1
  227. package/views/2d/engine/webgl/shaderGraph/techniques/magnifier/MagnifierTechnique.js +1 -1
  228. package/views/2d/engine/webgl/shaderGraph/techniques/markers/MarkerTechnique.js +1 -1
  229. package/views/2d/engine/webgl/shaderGraph/techniques/mesh/MeshWriterRegistry.js +1 -1
  230. package/views/2d/engine/webgl/shaderGraph/techniques/opacity/OpacityTechnique.js +1 -1
  231. package/views/2d/engine/webgl/shaderGraph/techniques/overlay/OverlayTechnique.js +1 -1
  232. package/views/2d/engine/webgl/shaderGraph/techniques/pieChart/PieChartTechnique.js +1 -1
  233. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/flow/FlowImageryShader.js +2 -0
  234. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/flow/FlowParticlesShader.js +2 -0
  235. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/flow/FlowStreamlinesShader.js +2 -0
  236. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/flow/FlowUtils.js +2 -0
  237. package/views/2d/engine/webgl/shaderGraph/techniques/text/TextTechnique.js +1 -1
  238. package/views/2d/engine/webgl/shaderGraph/techniques/tile/TileDebugInfoTechnique.js +1 -1
  239. package/views/2d/engine/webgl/shaderGraph/techniques/tile/TileStencilTechnique.js +1 -1
  240. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueBackground.js +1 -1
  241. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueCircle.js +1 -1
  242. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueFill.js +1 -1
  243. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueLine.js +1 -1
  244. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueSymbol.js +1 -1
  245. package/views/2d/engine/webgl/shaderGraph/techniques/videoScreenRenderer/VideoScreenTechnique.js +1 -1
  246. package/views/2d/engine/webgl/shaderGraph/typed/TypedShaderProgram.js +1 -1
  247. package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
  248. package/views/2d/interactive/editingTools/draw/DrawGraphicTool2D.js +1 -1
  249. package/views/2d/layers/features/FeatureContainer.js +1 -1
  250. package/views/2d/layers/features/RenderState.js +1 -1
  251. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillVisualization.js +1 -1
  252. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementShiftTool.js +1 -1
  253. package/views/3d/interactive/manipulators/ShiftManipulator.js +1 -1
  254. package/views/3d/layers/GaussianSplatLayerView3D.js +1 -1
  255. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  256. package/views/3d/layers/PointCloudLayerView3D.js +1 -1
  257. package/views/3d/layers/graphics/Graphics3DLineSymbolLayer.js +1 -1
  258. package/views/3d/layers/graphics/Graphics3DPolygonFillSymbolLayer.js +1 -1
  259. package/views/3d/layers/graphics/lineUtils.js +1 -1
  260. package/views/3d/layers/i3s/PointCloudRenderer.js +1 -1
  261. package/views/3d/layers/support/Tiles3DBVH.js +1 -1
  262. package/views/3d/layers/support/Tiles3DMeshIntersectionHandler.js +1 -1
  263. package/views/3d/support/gaussianSplatting/GaussianSplatDataStore.js +1 -1
  264. package/views/3d/support/gaussianSplatting/GaussianSplatFadeHelper.js +1 -1
  265. package/views/3d/support/gaussianSplatting/GaussianSplatIntersectionHandler.js +1 -1
  266. package/views/3d/support/gaussianSplatting/GaussianTile.js +1 -1
  267. package/views/3d/support/orientedBoundingBox.js +1 -1
  268. package/views/3d/terrain/TerrainRenderer.js +1 -1
  269. package/views/3d/webgl-engine/collections/Component/ComponentObjectElevationAgnosticBVH.js +1 -1
  270. package/views/3d/webgl-engine/collections/Component/ComponentObjectFixedBVH.js +1 -1
  271. package/views/3d/webgl-engine/collections/Component/Material/ComponentMaterial.js +1 -1
  272. package/views/3d/webgl-engine/collections/Component/Material/ComponentTechnique.js +1 -1
  273. package/views/3d/webgl-engine/core/shaderLibrary/ShaderOutput.js +1 -1
  274. package/views/3d/webgl-engine/core/shaderLibrary/shading/ScreenSpaceReflections.glsl.js +1 -1
  275. package/views/3d/webgl-engine/core/shaderLibrary/shading/WaterColor.glsl.js +1 -1
  276. package/views/3d/webgl-engine/core/shaderTechnique/ShaderTechniqueRepository.js +1 -1
  277. package/views/3d/webgl-engine/effects/highlight/ShadowHighlight.js +1 -1
  278. package/views/3d/webgl-engine/lib/BindParameters.js +1 -1
  279. package/views/3d/webgl-engine/lib/CutFillComputationRenderNode.js +1 -1
  280. package/views/3d/webgl-engine/lib/CutFillVisualizationRenderNode.js +1 -1
  281. package/views/3d/webgl-engine/lib/GLMaterial.js +1 -1
  282. package/views/3d/webgl-engine/lib/GLMaterialLoader.js +2 -0
  283. package/views/3d/webgl-engine/lib/GLMaterialParameters.js +1 -1
  284. package/views/3d/webgl-engine/lib/GLMaterialRepository.js +1 -1
  285. package/views/3d/webgl-engine/lib/PathGeometryData.js +1 -1
  286. package/views/3d/webgl-engine/lib/RayIntersections.js +1 -1
  287. package/views/3d/webgl-engine/lib/RenderContext.js +1 -1
  288. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  289. package/views/3d/webgl-engine/lib/ReprojectionUniforms.js +2 -0
  290. package/views/3d/webgl-engine/lib/ScreenSpaceReflectionsUniforms.js +2 -0
  291. package/views/3d/webgl-engine/lib/TriangleIntersectionData.js +1 -1
  292. package/views/3d/webgl-engine/lib/Viewshed.js +1 -1
  293. package/views/3d/webgl-engine/lib/lodRendering/LodComponentData.js +1 -1
  294. package/views/3d/webgl-engine/lib/lodRendering/LodRenderer.js +1 -1
  295. package/views/3d/webgl-engine/materials/DefaultMaterial.js +1 -1
  296. package/views/3d/webgl-engine/materials/PathMaterial.js +1 -1
  297. package/views/3d/webgl-engine/materials/PathTechnique.js +1 -1
  298. package/views/3d/webgl-engine/materials/PolygonOffset.js +1 -1
  299. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  300. package/views/3d/webgl-engine/materials/ShadedColorMaterial.js +1 -1
  301. package/views/3d/webgl-engine/materials/TriangleMaterial.js +1 -1
  302. package/views/3d/webgl-engine/materials/Water.glsl.js +1 -1
  303. package/views/3d/webgl-engine/materials/WaterMaterial.js +1 -1
  304. package/views/3d/webgl-engine/materials/WaterTechnique.js +1 -1
  305. package/views/3d/webgl-engine/materials/renderers/VaoRenderer.js +1 -1
  306. package/views/3d/webgl-engine/shaders/CheckerBoardTechnique.js +1 -1
  307. package/views/3d/webgl-engine/shaders/ColorMaterialTechnique.js +1 -1
  308. package/views/3d/webgl-engine/shaders/DefaultMaterialTechnique.js +1 -1
  309. package/views/3d/webgl-engine/shaders/ImageMaterialTechnique.js +1 -1
  310. package/views/3d/webgl-engine/shaders/PatternTechnique.js +1 -1
  311. package/views/3d/webgl-engine/shaders/RibbonLineTechnique.js +1 -1
  312. package/views/3d/webgl-engine/shaders/RibbonLineTechniqueConfiguration.js +1 -1
  313. package/views/3d/webgl-engine/shaders/ShadedColorMaterialTechnique.js +1 -1
  314. package/views/3d/webgl-engine/shaders/Viewshed.glsl.js +1 -1
  315. package/views/3d/webgl.js +1 -1
  316. package/views/draw/DrawTool.js +1 -1
  317. package/views/draw/plugins/ShapePlugin.js +1 -1
  318. package/views/draw/plugins/TangentArcSegmentPlugin.js +2 -0
  319. package/views/draw/support/managers/GlobalStateManager.js +1 -1
  320. package/views/draw/support/types.d.ts +9 -0
  321. package/views/interactive/SegmentLabels.js +1 -1
  322. package/views/webgl/AllocationTracer.js +1 -1
  323. package/views/webgl/RenderingContext.js +1 -1
  324. package/views/webgl/checkWebGLError.js +1 -1
  325. package/widgets/Editor/components/Settings.js +1 -1
  326. package/widgets/Features/FeaturesViewModel.js +1 -1
  327. package/widgets/Features.js +1 -1
  328. package/widgets/Search/SearchViewModel.js +1 -1
  329. package/widgets/Search/support/layerSearchUtils.js +1 -1
  330. package/widgets/Search/support/locatorUtils.js +1 -1
  331. package/widgets/Sketch/support/PluginManager.js +1 -1
  332. package/widgets/Sketch.js +1 -1
  333. package/widgets/support/SketchTooltipControls.js +1 -1
  334. package/assets/esri/core/workers/chunks/001492854799c35b53bb.js +0 -1
  335. package/assets/esri/core/workers/chunks/004f991251f09b36fb09.js +0 -1
  336. package/assets/esri/core/workers/chunks/01dd849a2d335e9f3e16.js +0 -1
  337. package/assets/esri/core/workers/chunks/027d733a99f50cadcf22.js +0 -1
  338. package/assets/esri/core/workers/chunks/03d85a706669aaf24d49.js +0 -1
  339. package/assets/esri/core/workers/chunks/0450133e81bce4b48b84.js +0 -1
  340. package/assets/esri/core/workers/chunks/085778ecd39f46324a6b.js +0 -1
  341. package/assets/esri/core/workers/chunks/08dce0019b52042b01fa.js +0 -1
  342. package/assets/esri/core/workers/chunks/0d8294982853308225da.js +0 -1
  343. package/assets/esri/core/workers/chunks/156aecac067213642aae.js +0 -1
  344. package/assets/esri/core/workers/chunks/184e9147f7a2f0ae5915.js +0 -1
  345. package/assets/esri/core/workers/chunks/19f59a2a97c33ff92650.js +0 -1
  346. package/assets/esri/core/workers/chunks/1cce2f8837ad765acf44.js +0 -1
  347. package/assets/esri/core/workers/chunks/20f9f3470cad47d01803.js +0 -1
  348. package/assets/esri/core/workers/chunks/23a9070e9362b8439770.js +0 -1
  349. package/assets/esri/core/workers/chunks/28ac3a75130fe2b57ac7.js +0 -1
  350. package/assets/esri/core/workers/chunks/2b7d020367cb4ebb3c3d.js +0 -1
  351. package/assets/esri/core/workers/chunks/3104b10770903c265626.js +0 -1
  352. package/assets/esri/core/workers/chunks/33f00633131581e06328.js +0 -1
  353. package/assets/esri/core/workers/chunks/365ad1ffd496ed86637b.js +0 -1
  354. package/assets/esri/core/workers/chunks/36a0e48113ab59a4f21d.js +0 -1
  355. package/assets/esri/core/workers/chunks/3874362bf7d43adc41bb.js +0 -1
  356. package/assets/esri/core/workers/chunks/38dc1c4b8721efd4a165.js +0 -1
  357. package/assets/esri/core/workers/chunks/3e9700445518b8f9ae1b.js +0 -1
  358. package/assets/esri/core/workers/chunks/42f3fdad1728433b3510.js +0 -1
  359. package/assets/esri/core/workers/chunks/436941ec88439667022e.js +0 -1
  360. package/assets/esri/core/workers/chunks/440a650ed0867a16f559.js +0 -1
  361. package/assets/esri/core/workers/chunks/440f76c397a813b0dcf9.js +0 -1
  362. package/assets/esri/core/workers/chunks/4812482f28f7205b0938.js +0 -1
  363. package/assets/esri/core/workers/chunks/5317cbef0aac29761575.js +0 -1
  364. package/assets/esri/core/workers/chunks/5344919fc6e8050450f1.js +0 -1
  365. package/assets/esri/core/workers/chunks/54a9e17d6c0fef6a9146.js +0 -1
  366. package/assets/esri/core/workers/chunks/55985c9c48b8e1d1c634.js +0 -1
  367. package/assets/esri/core/workers/chunks/5e5b358e603b13b4d7d7.js +0 -1
  368. package/assets/esri/core/workers/chunks/5e9bd5ed6ecee5b15127.js +0 -1
  369. package/assets/esri/core/workers/chunks/63b9e4a7dad358605c38.js +0 -1
  370. package/assets/esri/core/workers/chunks/64845b1f53eca9db1229.js +0 -1
  371. package/assets/esri/core/workers/chunks/662932d2effd2b384b9e.js +0 -1
  372. package/assets/esri/core/workers/chunks/66d4cbb35d0c290150bf.js +0 -1
  373. package/assets/esri/core/workers/chunks/677d3674cb2c0c05fb7e.js +0 -1
  374. package/assets/esri/core/workers/chunks/6f58ec80abebb7bfbbb0.js +0 -1
  375. package/assets/esri/core/workers/chunks/7100c9038739121c2c4b.js +0 -1
  376. package/assets/esri/core/workers/chunks/7278cc37e85f0242f19b.js +0 -1
  377. package/assets/esri/core/workers/chunks/794f604d4267e374f7dd.js +0 -1
  378. package/assets/esri/core/workers/chunks/7ae8f73c8e2afae98ecb.js +0 -1
  379. package/assets/esri/core/workers/chunks/7d4af7e2cb2f234e12eb.js +0 -1
  380. package/assets/esri/core/workers/chunks/7d56b2ac5030dd8b748e.js +0 -1
  381. package/assets/esri/core/workers/chunks/807b12ace0099300b9b9.js +0 -1
  382. package/assets/esri/core/workers/chunks/816a4b03f2ea49238a6c.js +0 -1
  383. package/assets/esri/core/workers/chunks/842b442cc012d0797333.js +0 -1
  384. package/assets/esri/core/workers/chunks/8903ff28896bd6f34b0d.js +0 -1
  385. package/assets/esri/core/workers/chunks/89e9bc8789b100316136.js +0 -1
  386. package/assets/esri/core/workers/chunks/8afe32d3db9669f972bc.js +0 -1
  387. package/assets/esri/core/workers/chunks/91fd28f50477d16e294e.js +0 -1
  388. package/assets/esri/core/workers/chunks/953f671bdeb2ca9b9f37.js +0 -1
  389. package/assets/esri/core/workers/chunks/96e799ca97989a6ed448.js +0 -1
  390. package/assets/esri/core/workers/chunks/98011b93acf3d5f0b5a2.js +0 -1
  391. package/assets/esri/core/workers/chunks/9c7fd5db0813bdc38582.js +0 -1
  392. package/assets/esri/core/workers/chunks/9db2ff1d4cbb5d1b623e.js +0 -1
  393. package/assets/esri/core/workers/chunks/a2fee1611319665e6aed.js +0 -1
  394. package/assets/esri/core/workers/chunks/a644e30f65347ce846ed.js +0 -1
  395. package/assets/esri/core/workers/chunks/a64daa4945923a178fe5.js +0 -1
  396. package/assets/esri/core/workers/chunks/a84d67c1a1008bca2075.js +0 -1
  397. package/assets/esri/core/workers/chunks/a85575a8d1da09280cd7.js +0 -1
  398. package/assets/esri/core/workers/chunks/ab414a60808ea05a63e6.js +0 -1
  399. package/assets/esri/core/workers/chunks/ac4f7309a249132c22da.js +0 -1
  400. package/assets/esri/core/workers/chunks/aeb1900cfdd0e51cc5f8.js +0 -1
  401. package/assets/esri/core/workers/chunks/ba62f3aa811430787863.js +0 -1
  402. package/assets/esri/core/workers/chunks/c03d0091a6f385b9ce8d.js +0 -1
  403. package/assets/esri/core/workers/chunks/c20aaca8085ce897bd12.js +0 -1
  404. package/assets/esri/core/workers/chunks/c3e711dc608eedda2d14.js +0 -1
  405. package/assets/esri/core/workers/chunks/c4a9006cc6d2938570e0.js +0 -1
  406. package/assets/esri/core/workers/chunks/c692ea68509bddbf7b42.js +0 -1
  407. package/assets/esri/core/workers/chunks/cb8c17daec7055bf99cc.js +0 -1
  408. package/assets/esri/core/workers/chunks/d7439d357f68160844cb.js +0 -1
  409. package/assets/esri/core/workers/chunks/dd319d5fe89b275e93cf.js +0 -1
  410. package/assets/esri/core/workers/chunks/df3e79b56c37156e7895.js +0 -1
  411. package/assets/esri/core/workers/chunks/df8b80b17e371c9be4e6.js +0 -1
  412. package/assets/esri/core/workers/chunks/e77198f8ab47441423c5.js +0 -1
  413. package/assets/esri/core/workers/chunks/e786da40a1c87bed64ca.js +0 -1
  414. package/assets/esri/core/workers/chunks/e8aafef6342c50340a27.js +0 -1
  415. package/assets/esri/core/workers/chunks/ec00348d74e29f48613a.js +0 -1
  416. package/assets/esri/core/workers/chunks/ec65c9c72507ef9a9cf9.js +0 -1
  417. package/assets/esri/core/workers/chunks/eedeff8b344ff699b0b9.js +0 -1
  418. package/assets/esri/core/workers/chunks/f1767b8ba82fdd9bd947.js +0 -1
  419. package/assets/esri/core/workers/chunks/f4201e7dcae224d0caf0.js +0 -1
  420. package/assets/esri/core/workers/chunks/f7cc05fbfc97b4d36eba.js +0 -1
  421. package/assets/esri/core/workers/chunks/f9d369a4683f88ee9d76.js +0 -1
  422. package/assets/esri/core/workers/chunks/fc534c94d55331578195.js +0 -1
  423. package/assets/esri/themes/base/colors/css/brand_colors.css +0 -76
  424. package/assets/esri/themes/base/colors/css/calcite_core_colors.css +0 -169
  425. package/assets/esri/themes/base/colors/css/calcite_core_colors_dark.css +0 -169
  426. package/assets/esri/themes/base/colors/css/calcite_gray_colors.css +0 -43
  427. package/assets/esri/themes/base/colors/css/calcite_gray_colors_dark.css +0 -43
  428. package/assets/esri/themes/base/colors/css/calcite_highlight_colors.css +0 -43
  429. package/assets/esri/themes/base/colors/css/calcite_highlight_colors_dark.css +0 -43
  430. package/assets/esri/themes/base/colors/css/calcite_vibrant_colors.css +0 -67
  431. package/assets/esri/themes/base/colors/css/calcite_vibrant_colors_dark.css +0 -67
  432. package/assets/esri/themes/base/colors/css/complete.css +0 -610
  433. package/assets/esri/themes/base/colors/css/scss/brand_colors.scss +0 -128
  434. package/assets/esri/themes/base/colors/css/scss/calcite_core_colors.scss +0 -289
  435. package/assets/esri/themes/base/colors/css/scss/calcite_core_colors_dark.scss +0 -285
  436. package/assets/esri/themes/base/colors/css/scss/calcite_gray_colors.scss +0 -96
  437. package/assets/esri/themes/base/colors/css/scss/calcite_gray_colors_dark.scss +0 -91
  438. package/assets/esri/themes/base/colors/css/scss/calcite_highlight_colors.scss +0 -69
  439. package/assets/esri/themes/base/colors/css/scss/calcite_highlight_colors_dark.scss +0 -65
  440. package/assets/esri/themes/base/colors/css/scss/calcite_vibrant_colors.scss +0 -128
  441. package/assets/esri/themes/base/colors/css/scss/calcite_vibrant_colors_dark.scss +0 -124
  442. package/assets/esri/themes/base/colors/css/scss/complete.scss +0 -11
  443. package/assets/esri/themes/base/colors/patterns_json/brand_colors.css +0 -366
  444. package/assets/esri/themes/base/colors/patterns_json/calcite_core_colors.css +0 -687
  445. package/assets/esri/themes/base/colors/patterns_json/calcite_core_colors_dark.css +0 -673
  446. package/assets/esri/themes/base/colors/patterns_json/calcite_gray_colors.css +0 -177
  447. package/assets/esri/themes/base/colors/patterns_json/calcite_gray_colors_dark.css +0 -169
  448. package/assets/esri/themes/base/colors/patterns_json/calcite_highlight_colors.css +0 -178
  449. package/assets/esri/themes/base/colors/patterns_json/calcite_highlight_colors_dark.css +0 -169
  450. package/assets/esri/themes/base/colors/patterns_json/calcite_vibrant_colors.css +0 -273
  451. package/assets/esri/themes/base/colors/patterns_json/calcite_vibrant_colors_dark.css +0 -265
  452. package/assets/esri/themes/base/colors/patterns_json/complete.css +0 -2847
  453. package/assets/esri/themes/base/colors/patterns_json/scss/brand_colors.scss +0 -464
  454. package/assets/esri/themes/base/colors/patterns_json/scss/calcite_core_colors.scss +0 -967
  455. package/assets/esri/themes/base/colors/patterns_json/scss/calcite_core_colors_dark.scss +0 -964
  456. package/assets/esri/themes/base/colors/patterns_json/scss/calcite_gray_colors.scss +0 -265
  457. package/assets/esri/themes/base/colors/patterns_json/scss/calcite_gray_colors_dark.scss +0 -263
  458. package/assets/esri/themes/base/colors/patterns_json/scss/calcite_highlight_colors.scss +0 -237
  459. package/assets/esri/themes/base/colors/patterns_json/scss/calcite_highlight_colors_dark.scss +0 -235
  460. package/assets/esri/themes/base/colors/patterns_json/scss/calcite_vibrant_colors.scss +0 -376
  461. package/assets/esri/themes/base/colors/patterns_json/scss/calcite_vibrant_colors_dark.scss +0 -347
  462. package/assets/esri/themes/base/colors/patterns_json/scss/complete.scss +0 -12
  463. package/assets/esri/themes/base/icons/readme/download.png +0 -0
  464. package/assets/esri/themes/base/icons/readme/import-icons.png +0 -0
  465. package/assets/esri/themes/base/icons/readme/import.png +0 -0
  466. package/assets/esri/themes/base/icons/readme/load.png +0 -0
  467. package/assets/esri/themes/base/icons/selection.json +0 -1
  468. package/assets/esri/themes/base/icons/style.css +0 -774
  469. package/views/2d/engine/brushes.js +0 -2
  470. package/views/2d/engine/flow/BrushFlow.js +0 -2
  471. package/views/2d/engine/rasterBrushes.js +0 -2
  472. package/views/2d/engine/webgl/brushes/BrushClip.js +0 -2
  473. package/views/2d/engine/webgl/brushes/WGLBrush.js +0 -2
  474. package/views/2d/engine/webgl/painter/RenderPass.js +0 -2
  475. package/views/2d/engine/webgl/shaders/BackgroundPrograms.js +0 -2
  476. package/views/2d/engine/webgl/shaders/TileInfoPrograms.js +0 -2
  477. package/views/3d/webgl-engine/lib/GLMaterials.js +0 -2
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{floatEqualRelative as t,floatEqualAbsolute as n}from"../../../core/mathUtils.js";import{expandPointInPlace as o,containsXY as r,expandXInPlace as s,expandYInPlace as c}from"../aaBoundingRect.js";import{distance2 as u,interpolateSegment as e,findClosestAndFurthestCurveParametersToPoint as f}from"./mathUtils.js";const i=[0,0];function a(t){const n=1-t,o=n*n,r=t*t;return[o*n,3*t*o,3*r*n,r*t]}function h(t,n,o,r,s){const[c,u,e,f]=a(s);return[t[0]*c+n[0]*u+o[0]*e+r[0]*f,t[1]*c+n[1]*u+o[1]*e+r[1]*f]}function m(t,n,o,r,s){const[c,u,e,f]=a(s);return t*c+n*u+o*e+r*f}function p(t,n,o){const r=t,[s,c,u]=n.b;return h(r,c,u,s,o)}function M(t,n,o){const r=t,[s,c,u]=n.b,f=e([0,0],r,c,o),a=e(i,c,u,o),h=e([0,0],u,s,o),m=e([0,0],f,a,o),p=e([0,0],a,h,o);return[{b:[e([],m,p,o),f,m]},{b:[[...s],p,h]}]}function b(o,r,s){const c=o,[u,e,i]=r.b,a=f(s,[.1,.5,.9],t=>{const n=1-t,[o,r]=h(c,e,i,u,t);return[o,r,3*n*n*(e[0]-c[0])+6*n*t*(i[0]-e[0])+3*t*t*(u[0]-i[0]),3*n*n*(e[1]-c[1])+6*n*t*(i[1]-e[1])+3*t*t*(u[1]-i[1]),6*n*(i[0]-2*e[0]+c[0])+6*t*(u[0]-2*i[0]+e[0]),6*n*(i[1]-2*e[1]+c[1])+6*t*(u[1]-2*i[1]+e[1])]}).map(t=>Math.min(1,Math.max(0,t)));a.push(0,1);let m=1/0;const p=a.map(t=>{const n=h(c,e,i,u,t),[o,r]=n,f=s[0]-o,a=s[1]-r,p=Math.sqrt(f*f+a*a);return m=Math.min(p,m),{t,curvePoint:n,distance:p}}),M=[];for(const f of p){const{t:o,distance:r}=f;t(r,m)&&!M.some(({t})=>n(t,o))&&M.push(f)}return M}function l(t,n,u){const e=n,[f,i,a]=u.b;if(o(t,e),o(t,f),r(t,i[0],i[1])&&r(t,a[0],a[1]))return t;for(const o of q(e[0],i[0],a[0],f[0]))o>0&&o<1&&s(t,m(e[0],i[0],a[0],f[0],o));for(const o of q(e[1],i[1],a[1],f[1]))o>0&&o<1&&c(t,m(e[1],i[1],a[1],f[1],o));return t}function q(t,n,o,r){const s=3*(3*(n-o)-t+r),c=6*(t-2*n+o),u=3*(n-t);if(0===s)return 0!==c?[-u/c]:[];const e=Math.sqrt(c*c-4*s*u);return[(-c+e)/(2*s),(-c-e)/(2*s)]}function d(t,n,o){const r=16;let s=0,c=[n];for(let e=0;e<r;e++){let n=t;const r=[];for(const t of c)r.push(...M(n,t,.5)),n=t.b[0];c=r,n=t,s=0;let e=0;for(const t of c){const[o,r,c]=t.b,f=Math.sqrt(u(n,o));s+=(f+(Math.sqrt(u(n,r))+Math.sqrt(u(r,c))+Math.sqrt(u(c,o))))/2,e+=f,n=o}if(s-e<o)return s}return s}export{l as bezierCurveExtent,d as bezierCurveLength,b as closestPointsOnBezierCurve,p as interpolateBezierCurve,h as interpolateCubicBezier,m as interpolateCubicBezier1D,M as splitBezierCurve};
2
+ import{floatEqualRelative as t,floatEqualAbsolute as n}from"../../../core/mathUtils.js";import{expandPointInPlace as o,containsXY as r,expandXInPlace as s,expandYInPlace as c}from"../aaBoundingRect.js";import{distance2 as u,interpolateSegment as e,findClosestAndFurthestCurveParametersToPoint as f}from"./mathUtils.js";const i=[0,0];function a(t){const n=1-t,o=n*n,r=t*t;return[o*n,3*t*o,3*r*n,r*t]}function h(t,n,o,r,s){const[c,u,e,f]=a(s);return[t[0]*c+n[0]*u+o[0]*e+r[0]*f,t[1]*c+n[1]*u+o[1]*e+r[1]*f]}function m(t,n,o,r,s){const[c,u,e,f]=a(s);return t*c+n*u+o*e+r*f}function b(t,n,o){const r=t,[s,c,u]=n.b;return h(r,c,u,s,o)}function p(t,n){const[o,r,s]=n.b;return o[0]!==s[0]||o[1]!==s[1]?[o[0]-s[0],o[1]-s[1]]:o[0]!==r[0]||o[1]!==r[1]?[o[0]-r[0],o[1]-r[1]]:[o[0]-t[0],o[1]-t[1]]}function M(t,n,o){const r=t,[s,c,u]=n.b,f=e([0,0],r,c,o),a=e(i,c,u,o),h=e([0,0],u,s,o),m=e([0,0],f,a,o),b=e([0,0],a,h,o);return[{b:[e([],m,b,o),f,m]},{b:[[...s],b,h]}]}function l(o,r,s){const c=o,[u,e,i]=r.b,a=f(s,[.1,.5,.9],t=>{const n=1-t,[o,r]=h(c,e,i,u,t);return[o,r,3*n*n*(e[0]-c[0])+6*n*t*(i[0]-e[0])+3*t*t*(u[0]-i[0]),3*n*n*(e[1]-c[1])+6*n*t*(i[1]-e[1])+3*t*t*(u[1]-i[1]),6*n*(i[0]-2*e[0]+c[0])+6*t*(u[0]-2*i[0]+e[0]),6*n*(i[1]-2*e[1]+c[1])+6*t*(u[1]-2*i[1]+e[1])]}).map(t=>Math.min(1,Math.max(0,t)));a.push(0,1);let m=1/0;const b=a.map(t=>{const n=h(c,e,i,u,t),[o,r]=n,f=s[0]-o,a=s[1]-r,b=Math.sqrt(f*f+a*a);return m=Math.min(b,m),{t,curvePoint:n,distance:b}}),p=[];for(const f of b){const{t:o,distance:r}=f;t(r,m)&&!p.some(({t})=>n(t,o))&&p.push(f)}return p}function q(t,n,u){const e=n,[f,i,a]=u.b;if(o(t,e),o(t,f),r(t,i[0],i[1])&&r(t,a[0],a[1]))return t;for(const o of d(e[0],i[0],a[0],f[0]))o>0&&o<1&&s(t,m(e[0],i[0],a[0],f[0],o));for(const o of d(e[1],i[1],a[1],f[1]))o>0&&o<1&&c(t,m(e[1],i[1],a[1],f[1],o));return t}function d(t,n,o,r){const s=3*(3*(n-o)-t+r),c=6*(t-2*n+o),u=3*(n-t);if(0===s)return 0!==c?[-u/c]:[];const e=Math.sqrt(c*c-4*s*u);return[(-c+e)/(2*s),(-c-e)/(2*s)]}function j(t,n,o){const r=16;let s=0,c=[n];for(let e=0;e<r;e++){let n=t;const r=[];for(const t of c)r.push(...M(n,t,.5)),n=t.b[0];c=r,n=t,s=0;let e=0;for(const t of c){const[o,r,c]=t.b,f=Math.sqrt(u(n,o));s+=(f+(Math.sqrt(u(n,r))+Math.sqrt(u(r,c))+Math.sqrt(u(c,o))))/2,e+=f,n=o}if(s-e<o)return s}return s}export{q as bezierCurveExtent,j as bezierCurveLength,p as calculateBezierCurveTangent,l as closestPointsOnBezierCurve,b as interpolateBezierCurve,h as interpolateCubicBezier,m as interpolateCubicBezier1D,M as splitBezierCurve};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{set as t,determinant as n}from"../../../core/libs/gl-matrix-2/math/mat3.js";import{create as r}from"../../../core/libs/gl-matrix-2/factories/mat3f64.js";import{DerivedCircle as c,interpolateCircle as i}from"./circleUtils.js";import{interpolateSegment as o,distance2 as s,wrapAtan2 as a}from"./mathUtils.js";const e=r();function m(r,c,i){const[o,a]=r,[m,l]=c,[u,f]=i;t(e,o,m,u,a,l,f,1,1,1);const h=n(e),M=4*h/(s(r,c)+s(c,i)+s(i,r));if(!isFinite(M)||Math.abs(M)<1e-8)return null;const p=o**2+a**2,b=m**2+l**2,j=u**2+f**2;t(e,p,b,j,a,l,f,1,1,1);const x=n(e);t(e,p,b,j,o,m,u,1,1,1);return[x/h*.5,n(e)/h*-.5]}function l(t,n){const[r,i]=n.c,s=m(t,i,r),e=null==s,l=s??o([],t,r,.5),[u,f]=t,[h,M]=i,[p,b]=r,[j,x]=l,d=u-j,g=f-x,I=Math.sqrt(d*d+g*g),P=a(f-x,u-j),U=a(M-x,h-j);let q=a(b-x,p-j);return(U-P)*(q-U)<0&&(q+=2*Math.sign(P-q)*Math.PI),new c(j,x,I,P,q,e)}function u(t,n,r){const c=i(t,r/2),o=i(t,r),s=i(t,(r+1)/2);return[{c:[o,c]},{c:[[...n.c[0]],s]}]}function f(t,n){const[r]=n.c,{cx:c,cy:i,thetaStart:o,thetaEnd:s,radius:a,isInvalid:e}=l(t,n);return{a:[r,[c,i],Math.abs(s-o)<Math.PI?1:0,o>s?1:0,e?o:0,a,e?0:1]}}export{l as deriveCircleFromCircularArc,u as splitCircularArc,f as toEllipticArc7};
2
+ import{set as t,determinant as n}from"../../../core/libs/gl-matrix-2/math/mat3.js";import{create as r}from"../../../core/libs/gl-matrix-2/factories/mat3f64.js";import{DerivedCircle as c,interpolateCircle as o}from"./circleUtils.js";import{interpolateSegment as i,distance2 as s,wrapAtan2 as a}from"./mathUtils.js";const e=r();function m(r,c,o){const[i,a]=r,[m,u]=c,[l,f]=o;t(e,i,m,l,a,u,f,1,1,1);const h=n(e),M=4*h/(s(r,c)+s(c,o)+s(o,r));if(!isFinite(M)||Math.abs(M)<1e-8)return null;const p=i**2+a**2,x=m**2+u**2,b=l**2+f**2;t(e,p,x,b,a,u,f,1,1,1);const d=n(e);t(e,p,x,b,i,m,l,1,1,1);return[d/h*.5,n(e)/h*-.5]}function u(t,n){const[r,o]=n.c,s=m(t,o,r),e=null==s,u=s??i([],t,r,.5),[l,f]=t,[h,M]=o,[p,x]=r,[b,d]=u,j=l-b,g=f-d,I=Math.sqrt(j*j+g*g),y=a(f-d,l-b),E=a(M-d,h-b);let P=a(x-d,p-b);return(E-y)*(P-E)<0&&(P+=2*Math.sign(y-P)*Math.PI),new c(b,d,I,y,P,e)}function l(t,n,r){const c=o(t,r/2),i=o(t,r),s=o(t,(r+1)/2);return[{c:[i,c]},{c:[[...n.c[0]],s]}]}function f(t,n){const[r,c]=n.c[0],{cx:o,cy:i,thetaEnd:s,thetaStart:a}=u(t,n),e=r-o,m=c-i;return s>a?[-m,e]:[m,-e]}function h(t,n){const[r]=n.c,{cx:c,cy:o,thetaStart:i,thetaEnd:s,radius:a,isInvalid:e}=u(t,n);return{a:[r,[c,o],Math.abs(s-i)<Math.PI?1:0,i>s?1:0,e?i:0,a,e?0:1]}}export{f as calculateCircularArcTangent,u as deriveCircleFromCircularArc,l as splitCircularArc,h as toEllipticArc7};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{floatEqualRelative as t}from"../../../core/mathUtils.js";import{DerivedCircle as a,interpolateCircle as r}from"./circleUtils.js";import{angularRangeOriented as o,wrapAtan2 as s}from"./mathUtils.js";function h(r,h){const[n,c,i,e]=h.a,[m,M]=r,[f,l]=n,[p,u]=c,j=m-p,U=M-u,b=Math.sqrt(j*j+U*U),q=f-p,x=l-u,I=Math.sqrt(q*q+x*x),P=0===b||0===I||!t(b,I),d=b,[w,y]=o(s(M-u,m-p),Math.atan2(l-u,f-p),i,e);return new a(p,u,d,w,y,P)}function n(t,a,o){const{cx:s,cy:h,thetaStart:n,thetaEnd:c}=t,[i,e,m,M]=a.a,f=n*(1-o)+c*o;return[{a:[r(t,o),[s,h],Math.abs(f-n)<Math.PI?1:0,M]},{a:[[...i],[s,h],Math.abs(c-f)<Math.PI?1:0,M]}]}export{h as deriveCircleFromEllipticArc4,n as splitEllipticArc4};
2
+ import{floatEqualRelative as t}from"../../../core/mathUtils.js";import{DerivedCircle as a,interpolateCircle as r}from"./circleUtils.js";import{angularRangeOriented as n,wrapAtan2 as o}from"./mathUtils.js";function c(r,c){const[h,s,e,i]=c.a,[m,M]=r,[f,u]=h,[l,p]=s,j=m-l,x=M-p,U=Math.sqrt(j*j+x*x),b=f-l,d=u-p,q=Math.sqrt(b*b+d*d),y=0===U||0===q||!t(U,q),E=U,[I,P]=n(o(M-p,m-l),Math.atan2(u-p,f-l),e,i);return new a(l,p,E,I,P,y)}function h(t,a,n){const{cx:o,cy:c,thetaStart:h,thetaEnd:s}=t,[e,i,m,M]=a.a,f=h*(1-n)+s*n;return[{a:[r(t,n),[o,c],Math.abs(f-h)<Math.PI?1:0,M]},{a:[[...e],[o,c],Math.abs(s-f)<Math.PI?1:0,M]}]}function s(t,a){const[r,n]=a.a[0],{cx:o,cy:h,thetaEnd:s,thetaStart:e}=c(t,a),i=r-o,m=n-h;return s>e?[-m,i]:[m,-i]}export{s as calculateEllipticArc4Tangent,c as deriveCircleFromEllipticArc4,h as splitEllipticArc4};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{set as t,invert as s,transpose as n,multiply as a}from"../../../core/libs/gl-matrix-2/math/mat3.js";import{create as r}from"../../../core/libs/gl-matrix-2/factories/mat3f64.js";import{transformMat3 as o}from"../../../core/libs/gl-matrix-2/math/vec2.js";import{expandPointInPlace as i}from"../aaBoundingRect.js";import{cloneCurve as c}from"./curveUtils.js";import{angularRangeWrap as h,angularRangeOriented as u,wrapAtan2 as e,angularRange as f,distance2 as m,intersectLineLine as M,findClosestAndFurthestCurveParametersToPoint as l}from"./mathUtils.js";class b{constructor(t,s,n,a,r,o,i,c,h){this.cx=t,this.cy=s,this.a=n,this.b=a,this.cosR=r,this.sinR=o,this.u1=i,this.u2=c,this.isInvalid=h}}function p(t,s){const[n,a,r,o,i,c,h]=s.a,[f,m]=t,[M,l]=n,[p,R]=a,d=c*h,x=Math.cos(i),q=Math.sin(i),[I,g]=u(e(1/d*(m-R)*x-1/d*(f-p)*q,1/c*(m-R)*q+1/c*(f-p)*x),Math.atan2(1/d*(l-R)*x-1/d*(M-p)*q,1/c*(l-R)*q+1/c*(M-p)*x),r,o);return new b(p,R,c,d,x,q,I,g,0===c||0===d)}function R(t,s){const{a:n,b:a,cosR:r,sinR:o,cx:i,cy:c}=t,h=Math.cos(s),u=Math.sin(s);return[n*h*r-a*u*o+i,n*h*o+a*u*r+c]}function d(t,s){const{u1:n,u2:a}=t;return R(t,n*(1-s)+a*s)}function x(t,s,n){if(n<0||n>1)return[];if(0===n||1===n)return[c(s)];const[a,[r,o],i,h,u,e,f]=s.a,{u1:m,u2:M}=t,l=m*(1-n)+M*n;return[{a:[[...d(t,n)],[r,o],Math.abs(l-m)<Math.PI?1:0,h,u,e,f]},{a:[[...a],[r,o],Math.abs(M-l)<Math.PI?1:0,h,u,e,f]}]}function q(t,s){const{a:n,b:a,cosR:r,sinR:o,u1:i,u2:c}=t,u=Math.PI/6,e=l(s,[1*u,2*u,4*u,5*u,7*u,8*u,10*u,11*u],s=>{const i=Math.cos(s),c=Math.sin(s),[h,u]=R(t,s);return[h,u,-n*r*c-a*o*i,-n*o*c+a*r*i,-n*r*i+a*o*c,-n*o*i-a*r*c]}),m=f(i,c),M=new Set(e.map(t=>h(m,t)).filter(t=>t>m.min&&t<m.max));M.add(i),M.add(c);let b,p,d=1/0;for(const h of M){const n=R(t,h),[a,r]=n,o=s[0]-a,u=s[1]-r,e=o*o+u*u;e<d&&(b=(h-i)/(c-i),p=n,d=e)}return{t:b,curvePoint:p,distance:Math.sqrt(d)}}function I(t,s,n){const a=p(s,n),{a:r,b:o,u1:c,u2:u,cosR:e,sinR:m,isInvalid:M}=a,l=n.a[0];if(i(t,s),i(t,l),M)return t;const b=Math.atan2(-o*m,r*e),d=b+Math.PI,x=Math.atan2(o*e,r*m),q=x+Math.PI,I=f(c,u);for(const f of[b,d,x,q].map(t=>h(I,t)))f>I.min&&f<I.max&&i(t,R(a,f));return t}function g(t,s,n){const[a,r,o,i,c,h,u]=s.a,e=p(t,s),{u1:f,u2:l,isInvalid:b}=e,x=l-f;if(b)return Math.sqrt(m(t,a));const q=14,I=[0,0];let g=0,j=[d(e,0),d(e,.25),d(e,.5),d(e,.75),d(e,1)];for(let p=0;p<q;p++){const t=j.length-1,s=x/(2*t),a=[];for(let n=0;n<t;n++)a.push(j[n]),a.push(R(e,f+(2*n+1)*s));a.push(j[j.length-1]),j=a,g=0;let o=0;for(let n=1;n<j.length;n++){const t=j[n-1],s=j[n];if(g+=Math.sqrt(m(t,s)),n>1){const a=j[n-2],i=M(I,a,t,r,s);o+=i?Math.sqrt(m(t,i)):Math.abs(s[0]-t[0])+Math.abs(s[1]-t[1])}else o+=g}if(o-g<n)return g}return g}const j=r(),v=r(),P=r(),y=r();function w(r,i,c){const[h,u,f,M,l,b,R]=i.a,d=p(r,i),{cosR:x,sinR:q,a:I,b:g,cx:w,cy:U}=d,B=o([0,0],h,c),S=o([0,0],u,c),k=c[0]*c[4]<0?1-M:M;{const s=I*I*q*q+g*g*x*x,n=2*(g*g-I*I)*q*x,a=I*I*x*x+g*g*q*q,r=-2*s*w-n*U,o=-n*w-2*a*U;t(j,s,n/2,r/2,n/2,a,o/2,r/2,o/2,s*w*w+n*w*U+a*U*U-I*I*g*g)}if(s(v,c),null==v){const t=o([0,0],r,c);return{a:[B,S,f,M,e(B[1],B[0]),Math.sqrt(m(B,t))/2,0]}}n(P,v),a(y,a(y,P,j),v);{const t=y[0],s=2*y[1],n=y[4],a=2*y[2],r=2*y[5],o=s*s-4*t*n,i=2*(t*r*r+n*a*a-s*a*r+o*y[8]),c=Math.sqrt((t-n)**2+s*s),h=-Math.sqrt(i*(t+n+c))/o,u=-Math.sqrt(i*(t+n-c))/o;return{a:[B,S,f,k,.5*e(-s,n-t),h,u/h]}}}export{b as DerivedEllipse,q as closestPointOnEllipse,p as deriveEllipse,I as ellipticArcExtent,g as ellipticArcLength,d as interpolateEllipse,x as splitEllipticArc7,w as transformEllipticArc};
2
+ import{set as t,invert as n,transpose as s,multiply as a}from"../../../core/libs/gl-matrix-2/math/mat3.js";import{create as r}from"../../../core/libs/gl-matrix-2/factories/mat3f64.js";import{transformMat3 as o,length as i}from"../../../core/libs/gl-matrix-2/math/vec2.js";import{expandPointInPlace as c}from"../aaBoundingRect.js";import{cloneCurve as u}from"./curveUtils.js";import{angularRangeWrap as h,angularRangeOriented as e,wrapAtan2 as f,angularRange as M,distance2 as l,intersectLineLine as m,findClosestAndFurthestCurveParametersToPoint as b}from"./mathUtils.js";class R{constructor(t,n,s,a,r,o,i,c,u){this.cx=t,this.cy=n,this.a=s,this.b=a,this.cosR=r,this.sinR=o,this.u1=i,this.u2=c,this.isInvalid=u}}function p(t,n){const[s,a,r,o,i,c,u]=n.a,[h,M]=t,[l,m]=s,[b,p]=a,d=c*u,x=Math.cos(i),q=Math.sin(i),[I,g]=e(f(1/d*(M-p)*x-1/d*(h-b)*q,1/c*(M-p)*q+1/c*(h-b)*x),Math.atan2(1/d*(m-p)*x-1/d*(l-b)*q,1/c*(m-p)*q+1/c*(l-b)*x),r,o);return new R(b,p,c,d,x,q,I,g,0===c||0===d)}function d(t,n){const{a:s,b:a,cosR:r,sinR:o,cx:i,cy:c}=t,u=Math.cos(n),h=Math.sin(n);return[s*u*r-a*h*o+i,s*u*o+a*h*r+c]}function x(t,n){const{u1:s,u2:a}=t;return d(t,s*(1-n)+a*n)}function q(t,n){const[s,a]=n.a[0],{a:r,b:o,cx:c,cy:u,cosR:h,sinR:e,isInvalid:f,u1:M,u2:l}=p(t,n);if(f)return[s-t[0],a-t[1]];const m=Math.sqrt(r*r-o*o),b=[c+m*h,u+m*e],R=[c-m*h,u-m*e],d=[s-b[0],a-b[1]],x=[s-R[0],a-R[1]],q=i(d),I=i(x),[g,v]=[d[0]/q+x[0]/I,d[1]/q+x[1]/I];return l>M?[-v,g]:[v,g]}function I(t,n,s){if(s<0||s>1)return[];if(0===s||1===s)return[u(n)];const[a,[r,o],i,c,h,e,f]=n.a,{u1:M,u2:l}=t,m=M*(1-s)+l*s;return[{a:[[...x(t,s)],[r,o],Math.abs(m-M)<Math.PI?1:0,c,h,e,f]},{a:[[...a],[r,o],Math.abs(l-m)<Math.PI?1:0,c,h,e,f]}]}function g(t,n){const{a:s,b:a,cosR:r,sinR:o,u1:i,u2:c}=t,u=Math.PI/6,e=b(n,[1*u,2*u,4*u,5*u,7*u,8*u,10*u,11*u],n=>{const i=Math.cos(n),c=Math.sin(n),[u,h]=d(t,n);return[u,h,-s*r*c-a*o*i,-s*o*c+a*r*i,-s*r*i+a*o*c,-s*o*i-a*r*c]}),f=M(i,c),l=new Set(e.map(t=>h(f,t)).filter(t=>t>f.min&&t<f.max));l.add(i),l.add(c);let m,R,p=1/0;for(const h of l){const s=d(t,h),[a,r]=s,o=n[0]-a,u=n[1]-r,e=o*o+u*u;e<p&&(m=(h-i)/(c-i),R=s,p=e)}return{t:m,curvePoint:R,distance:Math.sqrt(p)}}function v(t,n,s){const a=p(n,s),{a:r,b:o,u1:i,u2:u,cosR:e,sinR:f,isInvalid:l}=a,m=s.a[0];if(c(t,n),c(t,m),l)return t;const b=Math.atan2(-o*f,r*e),R=b+Math.PI,x=Math.atan2(o*e,r*f),q=x+Math.PI,I=M(i,u);for(const M of[b,R,x,q].map(t=>h(I,t)))M>I.min&&M<I.max&&c(t,d(a,M));return t}function j(t,n,s){const[a,r,o,i,c,u,h]=n.a,e=p(t,n),{u1:f,u2:M,isInvalid:b}=e,R=M-f;if(b)return Math.sqrt(l(t,a));const q=14,I=[0,0];let g=0,v=[x(e,0),x(e,.25),x(e,.5),x(e,.75),x(e,1)];for(let p=0;p<q;p++){const t=v.length-1,n=R/(2*t),a=[];for(let s=0;s<t;s++)a.push(v[s]),a.push(d(e,f+(2*s+1)*n));a.push(v[v.length-1]),v=a,g=0;let o=0;for(let s=1;s<v.length;s++){const t=v[s-1],n=v[s];if(g+=Math.sqrt(l(t,n)),s>1){const a=v[s-2],i=m(I,a,t,r,n);o+=i?Math.sqrt(l(t,i)):Math.abs(n[0]-t[0])+Math.abs(n[1]-t[1])}else o+=g}if(o-g<s)return g}return g}const P=r(),y=r(),w=r(),U=r();function B(r,i,c){const[u,h,e,M,m,b,R]=i.a,d=p(r,i),{cosR:x,sinR:q,a:I,b:g,cx:v,cy:j}=d,B=o([0,0],u,c),S=o([0,0],h,c),k=c[0]*c[4]<0?1-M:M;{const n=I*I*q*q+g*g*x*x,s=2*(g*g-I*I)*q*x,a=I*I*x*x+g*g*q*q,r=-2*n*v-s*j,o=-s*v-2*a*j;t(P,n,s/2,r/2,s/2,a,o/2,r/2,o/2,n*v*v+s*v*j+a*j*j-I*I*g*g)}if(n(y,c),null==y){const t=o([0,0],r,c);return{a:[B,S,e,M,f(B[1],B[0]),Math.sqrt(l(B,t))/2,0]}}s(w,y),a(U,a(U,w,P),y);{const t=U[0],n=2*U[1],s=U[4],a=2*U[2],r=2*U[5],o=n*n-4*t*s,i=2*(t*r*r+s*a*a-n*a*r+o*U[8]),c=Math.sqrt((t-s)**2+n*n),u=-Math.sqrt(i*(t+s+c))/o,h=-Math.sqrt(i*(t+s-c))/o;return{a:[B,S,e,k,.5*f(-n,s-t),u,h/u]}}}export{R as DerivedEllipse,q as calculateEllipticArc7Tangent,g as closestPointOnEllipse,p as deriveEllipse,v as ellipticArcExtent,j as ellipticArcLength,x as interpolateEllipse,I as splitEllipticArc7,B as transformEllipticArc};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import e from"../Extent.js";import t from"../Point.js";import{polygonCentroidPoint as n}from"./centroid.js";import{getExtentForScale as r}from"./scaleUtils.js";function o(e){switch(e?.type){case"point":return e;case"extent":return e.center;case"polygon":{const r=n(e);return r?t.fromJSON(r):null}case"multipoint":case"polyline":return e.extent?.center;default:return null}}async function a(e,t){if(e.hasZ||"2d"===t.type)return e;const n=t.map?.ground;return n?.layers.length?(await n.queryElevation(e,{cache:t.basemapTerrain?.elevationQueryCache})).geometry:e}function i(e,t,n){return s(e.center,t,n)}function c(e,t,n){switch(e?.type){case"extent":return e;case"multipoint":case"polygon":case"polyline":return e.extent;case"point":return s(e,t,n);default:return null}}function s(t,n,o){const a=t.hasZ?t.z:void 0;if(n?.map){return(null!=o?r(n,o):n.extent).clone().centerAt(t).set({zmax:a,zmin:a})}const{x:i,y:c,spatialReference:s}=t;return new e({xmin:i-.25,ymin:c-.25,xmax:i+.25,ymax:c+.25,spatialReference:s,zmin:a,zmax:a})}export{c as createExtentFromGeometry,s as createExtentFromPoint,o as getPointFromGeometry,a as getPointWithElevation,i as scaleExtent};
2
+ import e from"../Extent.js";import{getExtentForScale as n}from"./scaleUtils.js";async function t(e,n){if(e.hasZ||"2d"===n.type)return e;const t=n.map?.ground;return t?.layers.length?(await t.queryElevation(e,{cache:n.basemapTerrain?.elevationQueryCache})).geometry:e}function r(e,n,t){return a(e.center,n,t)}function a(t,r,a){const i=t.hasZ?t.z:void 0;if(r?.map){return(null!=a?n(r,a):r.extent).clone().centerAt(t).set({zmax:i,zmin:i})}const{x:o,y:c,spatialReference:m}=t;return new e({xmin:o-.25,ymin:c-.25,xmax:o+.25,ymax:c+.25,spatialReference:m,zmin:i,zmax:i})}export{a as createExtentFromPoint,t as getPointWithElevation,r as scaleExtent};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{getMetersPerVerticalUnitForSR as n}from"../../core/units.js";import{isSphericalPCPF as o}from"../ellipsoidUtils.js";import{equals as t}from"./spatialReferenceUtils.js";import{getEndpoint as e}from"./curves/curveUtils.js";function r(n,o,t){const e=i(o,t);if(1!==e)switch(n){case"point":case"esriGeometryPoint":return n=>s(n,e);case"polyline":case"esriGeometryPolyline":return n=>f(n,e);case"polygon":case"esriGeometryPolygon":return n=>c(n,e);case"multipoint":case"esriGeometryMultipoint":return n=>l(n,e);case"extent":case"esriGeometryEnvelope":return n=>u(n,e);default:return}}function i(e,r){if(null==e||null==r||(e.vcsWkid??null)!==(r.vcsWkid??null)||t(e,r)||o(e)||o(r))return 1;return n(e)/n(r)}function s(n,o){null!=n?.z&&(n.z*=o)}function c(n,o){if(n){if(n.curveRings)for(const t of n.curveRings)for(const n of t){const t=e(n);t.length>2&&(t[2]*=o)}if(n.rings)for(const t of n.rings)for(const n of t)n.length>2&&(n[2]*=o)}}function f(n,o){if(n){if(n.curvePaths)for(const t of n.curvePaths)for(const n of t){const t=e(n);t.length>2&&(t[2]*=o)}if(n.paths)for(const t of n.paths)for(const n of t)n.length>2&&(n[2]*=o)}}function l(n,o){if(n)for(const t of n.points)t.length>2&&(t[2]*=o)}function u(n,o){n&&null!=n.zmin&&null!=n.zmax&&(n.zmin*=o,n.zmax*=o)}export{r as getGeometryZScaler,i as zScale};
2
+ import{getMetersPerVerticalUnitForSR as o}from"../../core/units.js";import{isSphericalPCPF as n}from"../ellipsoidUtils.js";import{equals as t}from"./spatialReferenceUtils.js";import{getEndpoint as e}from"./curves/curveUtils.js";function r(o,n,t){const e=i(n,t);if(1!==e)switch(o){case"point":case"esriGeometryPoint":return o=>s(o,e);case"polyline":case"esriGeometryPolyline":return o=>c(o,e);case"polygon":case"esriGeometryPolygon":return o=>f(o,e);case"multipoint":case"esriGeometryMultipoint":return o=>l(o,e);case"extent":case"esriGeometryEnvelope":return o=>u(o,e);default:return}}function i(e,r){if(null==e||null==r||r.vcsWkid||t(e,r)||n(e)||n(r))return 1;return o(e)/o(r)}function s(o,n){null!=o?.z&&(o.z*=n)}function f(o,n){if(o){if(o.curveRings)for(const t of o.curveRings)for(const o of t){const t=e(o);t.length>2&&(t[2]*=n)}if(o.rings)for(const t of o.rings)for(const o of t)o.length>2&&(o[2]*=n)}}function c(o,n){if(o){if(o.curvePaths)for(const t of o.curvePaths)for(const o of t){const t=e(o);t.length>2&&(t[2]*=n)}if(o.paths)for(const t of o.paths)for(const o of t)o.length>2&&(o[2]*=n)}}function l(o,n){if(o)for(const t of o.points)t.length>2&&(t[2]*=n)}function u(o,n){o&&null!=o.zmin&&null!=o.zmax&&(o.zmin*=n,o.zmax*=n)}export{r as getGeometryZScaler,i as zScale};
package/interfaces.d.ts CHANGED
@@ -781,6 +781,13 @@ declare namespace __esri {
781
781
 
782
782
  export const layersEffectsJsonUtils: layersEffectsJsonUtils;
783
783
 
784
+ /** @deprecated since 5.0. Refactor using \@arcgis/codemod */
785
+ interface navigationDuration {
786
+ getGoToDuration: typeof import("./applications/Components/navigationDuration.js").getGoToDuration;
787
+ }
788
+
789
+ export const navigationDuration: navigationDuration;
790
+
784
791
  /** @deprecated since 5.0. Refactor using \@arcgis/codemod */
785
792
  interface previewSymbol2D {
786
793
  getContrastingBackgroundTheme: typeof import("./applications/Components/previewSymbol2D.js").getContrastingBackgroundTheme;
package/kernel.js CHANGED
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import has from"./core/has.js";import{addQueryParameter as o}from"./core/urlUtils.js";export{buildDate,commitHash as revision}from"./support/revision.js";Symbol.dispose??=Symbol("Symbol.dispose"),Symbol.asyncDispose??=Symbol("Symbol.asyncDispose");const e="5.1";let s,r=e;function i(o){s=o}function t(e){const r=s?.findCredential(e);return r?.token?o(e,"token",r.token):e}r="5.1.0-next.53",has("host-webworker")||globalThis.$arcgis||Object.defineProperty(globalThis,"$arcgis",{configurable:!1,enumerable:!0,writable:!1,value:{}}),has("host-webworker");export{t as addTokenParameter,r as fullVersion,s as id,i as setId,e as version};
2
+ import has from"./core/has.js";import{addQueryParameter as o}from"./core/urlUtils.js";export{buildDate,commitHash as revision}from"./support/revision.js";Symbol.dispose??=Symbol("Symbol.dispose"),Symbol.asyncDispose??=Symbol("Symbol.asyncDispose");const e="5.1";let s,r=e;function i(o){s=o}function t(e){const r=s?.findCredential(e);return r?.token?o(e,"token",r.token):e}r="5.1.0-next.55",has("host-webworker")||globalThis.$arcgis||Object.defineProperty(globalThis,"$arcgis",{configurable:!1,enumerable:!0,writable:!1,value:{}}),has("host-webworker");export{t as addTokenParameter,r as fullVersion,s as id,i as setId,e as version};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{__decorate as e}from"tslib";import{serializationUtilsModuleWrapper as t}from"../applications/KnowledgeStudio/resourceSerializationUtils.js";import i from"../core/Collection.js";import{deprecated as a}from"../core/deprecate.js";import n from"../core/Error.js";import o from"../core/Logger.js";import{getOrCreateMapValue as s}from"../core/MapUtils.js";import{MultiOriginJSONSupportMixin as r}from"../core/MultiOriginJSONSupport.js";import{throwIfAborted as l,isAbortError as h,createAbortError as d}from"../core/promiseUtils.js";import{watch as p,sync as c}from"../core/reactiveUtils.js";import{property as u,subclass as y}from"../core/accessorSupport/decorators.js";import{idToName as g}from"../core/accessorSupport/PropertyOrigin.js";import m from"../geometry/Extent.js";import f from"../geometry/Point.js";import L from"../geometry/Polyline.js";import{polygonCentroidPoint as w}from"../geometry/support/centroid.js";import b from"./Layer.js";import{convertFromGeometry as k}from"./graphics/featureConversionUtils.js";import{systemOidFieldName as M,systemOriginIdFieldName as C,systemDestinationIdFieldName as T,systemLayoutGeometryFieldName as v,systemAggregationCountFieldName as N}from"./knowledgeGraph/constants.js";import{IdealEdgeLengthTypeOptions as D}from"./knowledgeGraph/IdealEdgeLengthTypeOptions.js";import{KnowledgeGraphLayerDataManager as E}from"./knowledgeGraph/KnowledgeGraphLayerDataManager.js";import x from"./knowledgeGraph/KnowledgeGraphSublayer.js";import{getTitleFromServerUrl as I,getUserKGSPrivileges as S,createCapabilitiesFromKnowledgeGraph as _,initializeLayersFromClientData as A}from"./knowledgeGraph/layerUtils.js";import R from"./knowledgeGraph/SessionMemoryStorage.js";import{convertLayoutTypeToWebSupportedFormat as j,getRelationshipEndNodeIds as P}from"./knowledgeGraph/supportUtils.js";import{BlendLayer as G}from"./mixins/BlendLayer.js";import{OperationalLayer as z}from"./mixins/OperationalLayer.js";import{ScaleRangeLayer as O}from"./mixins/ScaleRangeLayer.js";import{url as F}from"./support/commonProperties.js";import{LCChronologicalLayout as U,LCSimpleLayout as B,LCSmartTreeLayout as H,LCRadialTreeLayout as Q,LCHierarchicalLayout as W,LCCommunityLayout as $,LCForceDirectedLayout as K,load as J}from"../libs/linkchartlayout/LinkChartLayout.js";import{fetchKnowledgeGraph as V}from"../rest/knowledgeGraphService.js";let q=class extends(z(G(O(r(b))))){constructor(e){if(super(e),this.url=null,this.dataPreloadedInLocalCache=!1,this.initializationLinkChartConfig=null,this.membershipModified=!0,this._currentLinkChartConfig={layoutMode:"organic-standard"},this._graphTypeLookup=new Map,this.dataManager=null,this.knowledgeGraph=null,this.layers=new(i.ofType(x)),this.entityLinkChartDiagramLookup=new Map,this.relationshipLinkChartDiagramLookup=new Map,this.linkChartExtent=new m({xmin:-1e-7,ymin:-1e-7,xmax:1e-7,ymax:1e-7}),this.memberEntityTypes=null,this.memberRelationshipTypes=null,this.operationalLayerType="LinkChartLayer",this.sublayerIdsCache=new Map,this.tables=new(i.ofType(x)),this.type="link-chart",this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1,this.chronologicalAuxiliaryGraphics=null,this._originalInclusionList=e?.initializationInclusionModeDefinition,e?.dataPreloadedInLocalCache&&!e?.initializationInclusionModeDefinition)throw new n("knowledge-graph:linkchart-layer-constructor","If creating a link chart composite layer and configured that data is already loaded in the cache, you must specify an inclusion list so the Composite Layer knows what records belong to it");this.addHandles(p(()=>this.layers.concat(this.tables),(e,t)=>this._handleSublayersChange(e,t),c))}normalizeCtorArgs(e){if(!e)return{};const{url:t,dataPreloadedInLocalCache:i,initializationLinkChartConfig:a}=e;let{title:n}=e;return!n&&e?.url&&(n=I(e.url)),{url:t,title:n,dataPreloadedInLocalCache:i,initializationLinkChartConfig:a}}_initializeLayerProperties(e){const t=new Set;let i=[],a=[];if(e.inclusionModeDefinition&&(!e.inclusionModeDefinition.namedTypeDefinitions||e.inclusionModeDefinition.namedTypeDefinitions.size<1))throw new n("knowledge-graph:composite-layer-constructor","If an explicit inclusion definition is defined, at least one namedTypeDefinition must also be defined");e.inclusionModeDefinition?.generateAllSublayers?(i=e.knowledgeGraph.dataModel.entityTypes??[],a=e.knowledgeGraph.dataModel.relationshipTypes??[]):e.inclusionModeDefinition?.namedTypeDefinitions&&e.inclusionModeDefinition?.namedTypeDefinitions.size>0?e.inclusionModeDefinition?.namedTypeDefinitions.forEach((n,s)=>{const r=this._graphTypeLookup.get(s);if(!r)return o.getLogger(this).warn(`A named type, ${s}, was in the inclusion list that wasn't in the data model and will be removed`),void e.inclusionModeDefinition?.namedTypeDefinitions.delete(s);"relationship"===r.type?t.has(s)||(t.add(s),a.push(r)):"entity"===r.type?t.has(s)||(t.add(s),i.push(r)):(o.getLogger(this).warn(`A named type, ${s}, was in the inclusion list that wasn't properly modeled and will be removed`),e.inclusionModeDefinition?.namedTypeDefinitions.delete(s))}):(i=e.knowledgeGraph.dataModel.entityTypes??[],a=e.knowledgeGraph.dataModel.relationshipTypes??[]);const s=new E({knowledgeGraph:e.knowledgeGraph,inclusionModeDefinition:e.inclusionModeDefinition});this.knowledgeGraph=e.knowledgeGraph,this.memberEntityTypes=i,this.memberRelationshipTypes=a,this.dataManager=s}load(e){const i=async()=>{const e=[],t=[];this.loadLayerAssumingLocalCache(),this._layersLoadedFromAuthoritativeItem()||await A(this),this.dataManager.inclusionModeDefinition&&(this.dataManager.inclusionModeDefinition.generateAllSublayers=!1),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.forEach(e=>{e.useAllData=!1}),await this._initializeDiagram(),this.layers.forEach(i=>{t.push(i.refreshCachedQueryEngine()),e.push(new Promise(e=>{i.on("layerview-create",()=>{e(null)})}))}),this.tables.forEach(e=>{t.push(e.refreshCachedQueryEngine())}),await Promise.all(t)};return this.addResolvingPromise(new Promise(a=>{V(this.url).then(async n=>{n.dataModel.entityTypes?.forEach(e=>{e.name&&this._graphTypeLookup.set(e.name,e)}),n.dataModel.relationshipTypes?.forEach(e=>{e.name&&this._graphTypeLookup.set(e.name,e)});const o=this.linkChart?.linkChartProperties;6===o?.originIdOf("entitiesUrl")&&(this.membershipModified=!1,this._originalInclusionList=await t.fetchAndConvertSerializedLinkChart({entitiesUrl:o?.entitiesUrl,relationshipsUrl:o?.relationshipsUrl},{signal:e?.signal}),this._alignLayersDataModelAndInclusionDefinition(n.dataModel),this.initializationLinkChartConfig={layoutSettings:o?.layoutSettings??void 0,layoutMode:j(o.layoutType)}),this._initializeLayerProperties({knowledgeGraph:n,inclusionModeDefinition:this._originalInclusionList}),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.size||(this.dataManager.inclusionModeDefinition={generateAllSublayers:!1,namedTypeDefinitions:new Map},this.dataManager.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.set(e.name,{useAllData:!0})}),this.dataManager.knowledgeGraph.dataModel.relationshipTypes?.forEach(e=>{e.name&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.set(e.name,{useAllData:!0})}));const{edit:r,fullEdit:h,updateItem:d}=await S(n.serviceDefinition.serviceItemId,this.url,e);if(this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",h),this._set("userHasUpdateItemPrivileges",d),this.dataPreloadedInLocalCache){const e=R.getInstance();for(const[t,i]of this.dataManager.inclusionModeDefinition?.namedTypeDefinitions??[])for(const a of i.members?.values()??[]){const i=e.readFromStoreById(`${t}__${a.id}`);if(i){s(this.dataManager.sublayerCaches,t,()=>new Map).set(a.id,i)}}await i()}else{const t="geographic-organic-standard"===this.initializationLinkChartConfig?.layoutMode;this.addResolvingPromise(this.dataManager.refreshCacheContent(void 0,!1,t,!0).then(async()=>{l(e),await i()}))}a(null)})})),Promise.resolve(this)}set initializationInclusionModeDefinition(e){"loaded"!==this.loadStatus&&"failed"!==this.loadStatus?this._set("initializationInclusionModeDefinition",e):o.getLogger(this).error("#initializationInclusionModeDefinition","initializationInclusionModeDefinition cannot be changed after the layer is loaded.")}get linkChart(){return this.parent}get sublayerCapabilities(){return _(this.knowledgeGraph)}async addRecords(e,t){let i=[];t?.cascadeAddRelationshipEndNodes&&this.dataManager.knowledgeGraph.dataModel&&(i=await P(e,this.dataManager.knowledgeGraph));const a=e.concat(i).filter(e=>!this.sublayerIdsCache.get(e.typeName)?.has(e.id));a.length>0&&(this.membershipModified=!0),await this._handleNewRecords(a,t)}async createSublayerForNamedType(e){await this.load();const t=this._graphTypeLookup.get(e);if(!t)throw new n("knowledge-graph:missing-type","The specified type does not exist in the knowledge graph.");if(this.dataManager.sublayerCaches.has(e))throw new n("knowledge-graph:duplicate-type","The specified type already exists as a sublayer.");this.dataManager.sublayerCaches.set(e,new Map),s(this.sublayerIdsCache,e,()=>new Set);const i=this._createSublayer(t);return"entity"===t.type?this.dataManager.entityTypeNames.add(e):this.dataManager.relationshipTypeNames.add(e),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.set(e,{useAllData:!1,members:new Map}),i.geometryType?this.layers.push(i):this.tables.push(i),await A(this,[e]),this._refreshNamedTypes(),i}async removeRecords(e,{cascadeRemoveRelationships:t=!0,recalculateLayout:i=!1,overrideMembershipCheck:a=!1}={cascadeRemoveRelationships:!0,recalculateLayout:!1,overrideMembershipCheck:!1}){let n=[];for(const r of e)(a||!1===this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.get(r.typeName)?.useAllData&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.get(r.typeName)?.members?.has(r.id))&&n.push(r);if(t){const e=new Set,t=[];for(const i of n)if(this.dataManager.nodeConnectionsLookup.has(i.id))for(const t of this.dataManager.nodeConnectionsLookup.get(i.id))e.add(t);for(const i of e)if(this.dataManager.memberIdTypeLookup.has(i))for(const e of this.dataManager.memberIdTypeLookup.get(i))this.dataManager.relationshipTypeNames.has(e)&&t.push({id:i,typeName:e});n=n.concat(t)}this.dataManager.removeFromLayer(n);for(const r of n)this.sublayerIdsCache.get(r.typeName)?.delete(r.id),this.dataManager.relationshipTypeNames.has(r.typeName)?this.relationshipLinkChartDiagramLookup.delete(r.id):this.entityLinkChartDiagramLookup.delete(r.id);const o=i?void 0:this.getCurrentNodeLocations();await this._calculateLayoutWithSublayerTimeInfo(this._currentLinkChartConfig.layoutMode,{layoutSettings:this._currentLinkChartConfig.layoutSettings,lockedEntityLocations:o}),n.length>0&&(this.membershipModified=!0);const s=[];return this.layers.forEach(e=>{s.push(e.refreshCachedQueryEngine())}),await Promise.all(s),this._refreshNamedTypes(),n}async expand(e,t){let i=[];try{const a=await this.dataManager.getConnectedRecordIds(e,t?.relationshipTypeNames,t);i=a.filter(e=>!this.sublayerIdsCache.get(e.typeName)?.has(e.id)),await this._handleNewRecords(i,t),a.length>0&&(this.membershipModified=!0),l(t?.signal)}catch(a){throw h(a)&&i.length>0&&await this.removeRecords(i,{overrideMembershipCheck:!0}),a}return{records:i}}loadLayerAssumingLocalCache(){const e=[...this.memberRelationshipTypes,...this.memberEntityTypes];this.layers.length||0===this.originIdOf("tables")?0===this.originIdOf("layers")?this._createSublayers(e,this.layers,e=>!!e.geometryType):this._updateSublayers(e,this.layers):this.layers=new i,this.tables.length||0===this.originIdOf("layers")?0===this.originIdOf("tables")?this._createSublayers(e,this.tables,e=>!e.geometryType):this._updateSublayers(e,this.tables):this.tables=new i,this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{const i=s(this.sublayerIdsCache,t,()=>new Set);e.members?.forEach(({id:e,linkChartLocation:a})=>{if(i.add(e),a){const i="coords"in a&&"lengths"in a?a:k(a);this.dataManager.relationshipTypeNames.has(t)?this.relationshipLinkChartDiagramLookup.set(e,i):this.entityLinkChartDiagramLookup.set(e,i)}})})}async calculateLinkChartLayout(e="organic-standard",t){const i=[],a=[],r=[];this.dataManager.sublayerCaches.forEach((e,t)=>{this.dataManager.entityTypeNames.has(t)?e.forEach(e=>{i.push({typeName:t,feature:e})}):this.dataManager.relationshipTypeNames.has(t)&&e.forEach(e=>{a.push({typeName:t,feature:e})})}),this.entityLinkChartDiagramLookup=new Map,this.relationshipLinkChartDiagramLookup=new Map;const h=new Map,p=new Map,c=new Map,u=new Map,y=new Uint8Array(i.length),g=new Float64Array(i.length),b=new Float64Array(i.length),D=new Float64Array(i.length),E=new Float64Array(i.length),x=new Uint32Array(a.length),I=new Uint32Array(a.length),S=new Float64Array(a.length),_=new Float64Array(a.length),A=[],R="organic-standard";let j=!1;const P=new m({xmin:-1e-7,ymin:-1e-7,xmax:1e-7,ymax:1e-7});let G,z="organic-standard",O=0,F=0;const V=U.apply;switch(z="geographic-organic-standard"===e?R:e,z){case"organic-standard":G=K.apply;break;case"organic-community":G=$.apply;break;case"hierarchical-bottom-to-top":G=W.apply;break;case"radial-root-centric":G=Q.apply;break;case"tree-left-to-right":G=H.apply;break;default:G=B.apply}let q=!1;i.forEach(({typeName:i,feature:a})=>{if("chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e&&t?.lockedEntityLocations?.has(a.attributes[M])){"geographic-organic-standard"===e&&this.dataManager.geographicLookup.has(i)?y[O]=2:y[O]=0;const n=t.lockedEntityLocations.get(a.attributes[M]);g[O]=n.x,b[O]=n.y}else if("geographic-organic-standard"===e&&this.dataManager.geographicLookup.has(i)){y[O]=2;let e=null;const t=a.attributes[this.dataManager.geographicLookup.get(i).name],n=this.dataManager.geographicLookup.get(i)?.geometryType;switch(n){case"esriGeometryPoint":g[O]=t?.x,b[O]=t?.y;break;case"esriGeometryPolygon":{const i=w(t);e=i?f.fromJSON(i):null,null!=e?.x&&null!=e?.y?(g[O]=e.x,b[O]=e.y):y[O]=1;break}case"esriGeometryPolyline":case"esriGeometryMultipoint":e=t?.extent?.center,null!=e?.x&&null!=e?.y?(g[O]=e.x,b[O]=e.y):y[O]=1;break;default:y[O]=1}(null==g[O]||null==b[O]||Number.isNaN(g[O])||Number.isNaN(b[O]))&&(y[O]=1,g[O]=0,b[O]=0)}else if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){!q&&t?.lockedEntityLocations?.has(a.attributes[M])&&(q=!0);const e=t?.timeInfoByTypeName?.get(i),n=e?.startField,o=n&&e?.startField?a.attributes[n]:null;D[O]=o?new Date(o).getTime():NaN;const s=e?.endField,r=s&&e?.endField?a.attributes[s]:null;E[O]=r?new Date(r).getTime():NaN,g[O]=0,b[O]=0,y[O]=1}else y[O]=1,g[O]=0,b[O]=0;t?.rootEntityIds?.has(a.attributes[M])&&(y[O]|=4),u.set(a.attributes[M],O),A[O]={feature:a,typeName:i},O++}),q&&o.getLogger(this).warn("Locked node locations are not supported for chronological layout at this time. Requested node locations were ignored");let X=!1;const Y=new Map;a.forEach(i=>{const a=i.feature.attributes[C],n=i.feature.attributes[T],o=u.get(a),s=u.get(n),l=t?.timeInfoByTypeName?.get(i.typeName),h=t?.timeInfoByTypeName?l?.startField:null,d=h?i.feature.attributes[h]:null,p=l?.endField,c=p?i.feature.attributes[p]:null;if(void 0!==o&&void 0!==s){let t=a+"-"+n;"chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e||(t=t+"-"+d+"-"+c);const l=Y.get(t),h=l?.has(i.typeName);h||(x[F]=o,I[F]=s,"chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e||(S[F]=d?new Date(d).getTime():NaN,_[F]=c?new Date(c).getTime():NaN),void 0===l?Y.set(t,new Map([[i.typeName,F]])):l.set(i.typeName,F),F++),r.push(i)}else X=!0,this.relationshipLinkChartDiagramLookup.set(a,null)}),X&&o.getLogger(this).warn("A relationship is a member of this layer that has either origin or destination entity nodes that are not members. The diagram geometry will be set to null");const Z=this._validateOrganicLayoutSettings(e,t?.layoutSettings?.organicLayoutSettings),ee=this._convertValidatedOrganicSettingsToCalculationSettings(Z);await J();let te=1,ie=null;if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){let i;({status:te,links:ie,graphics:i}=V(()=>t?.signal?.aborted??!1,y,g,b,D,E,x.subarray(0,F),I.subarray(0,F),S.subarray(0,F),_.subarray(0,F),"chronological-multi-timeline"===e,t?.layoutSettings?.chronologicalLayoutSettings)),0===te&&(this.chronologicalAuxiliaryGraphics=i)}else({status:te,links:ie}=G(()=>t?.signal?.aborted??!1,y,g,b,x.subarray(0,F),I.subarray(0,F),ee.computationBudgetTime,ee.idealEdgeLengthMultiplier,ee.repulsionRadiusMultiplier));if(l(t?.signal),1===te)throw new n("knowledge-graph:layout-failed","Attempting to arrange the records in the specified layout failed");if(2===te)throw d();for(let n=0;n<A.length;n++){if(b[n]>84.9999?b[n]=84.9999:b[n]<-84.9999&&(b[n]=-84.9999),g[n]>179.9999?g[n]=179.9999:g[n]<-179.9999&&(g[n]=-179.9999),A[n].feature.attributes[v]=new f(g[n],b[n]),h.has(A[n].typeName)){const e=h.get(A[n].typeName);e?.set(A[n].feature.attributes[M],A[n].feature)}else{const e=new Map;e.set(A[n].feature.attributes[M],A[n].feature),h.set(A[n].typeName,e)}c.set(A[n].feature.attributes[M],A[n].feature);const e=k(A[n].feature.attributes[v]);this.entityLinkChartDiagramLookup.set(A[n].feature.attributes[M],A[n].feature.attributes[v]?e:null);const t=s(this.dataManager.inclusionModeDefinition.namedTypeDefinitions,A[n].typeName,()=>({useAllData:!1,members:new Map}));s(t.members,A[n].feature.attributes[M],()=>({id:A[n].feature.attributes[M],linkChartLocation:void 0})).linkChartLocation=A[n].feature.attributes[v];const{x:i,y:a}=A[n].feature.attributes[v];if(j)P.xmin=Math.min(P.xmin,i),P.xmax=Math.max(P.xmax,i),P.ymin=Math.min(P.ymin,a),P.ymax=Math.max(P.ymax,a);else{const e=1e-7;P.xmin=i-e,P.xmax=i+e,P.ymin=a-e,P.ymax=a+e,j=!0}}if(this.linkChartExtent.xmin=P.xmin,this.linkChartExtent.xmax=P.xmax,this.linkChartExtent.ymin=P.ymin,this.linkChartExtent.ymax=P.ymax,!ie)throw new n("knowledge-graph:layout-failed","Attempting to retrieve link geometry from diagram engine failed");const ae=new Map,ne=new Map,oe=new Map,se=new Set;for(let n=0;n<r.length;n++){const i=[],a=r[n],l=a.feature.attributes[C],h=a.feature.attributes[T];let d=l+"-"+h;if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){const e=t?.timeInfoByTypeName?.get(a.typeName),i=t?.timeInfoByTypeName?e?.startField:null,n=i?a.feature.attributes[i]:null,o=e?.endField;d+="-"+n+"-"+(o?a.feature.attributes[o]:null)}const y=Y.get(d).get(a.typeName),g=0===y?0:ie?.vertexEndIndex[y-1];if(!se.has(y)){if(se.add(y),2===ie.types[y]){const e=[ie.vertices[2*g],ie.vertices[2*g+1]],t=[ie.vertices[2*(g+1)],ie.vertices[2*(g+1)+1]],a=[.5*(e[0]+t[0]),.5*(e[1]+t[1])],n=[a[0]-e[0],a[1]-e[1]],o=[a[0]+n[1],a[1]-n[0]],s=[a[0]-n[1],a[1]+n[0]];i.push(e),i.push(o),i.push(t),i.push(s),i.push(e)}else{if(0!==ie.types[y]){o.getLogger(this).warn("A relationship generated an unsupported link geometry type. It will not be rendered");continue}for(let e=g;e<ie.vertexEndIndex[y];e++)i.push([ie.vertices[2*e],ie.vertices[2*e+1]])}if("chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e){const e=A[u.get(l)]?.feature.attributes[v],t=A[u.get(h)]?.feature.attributes[v];i[0][0]===e.x&&i[0][1]===e.y||(i[0]=[e.x,e.y]),i[i.length-1][0]===t.x&&i[i.length-1][1]===t.y||(i[i.length-1]=[t.x,t.y])}for(let e=1;e<i.length-1;e++)i[e][1]>85.5?i[e][1]=85.5:i[e][1]<-85.5&&(i[e][1]=-85.5),i[e][0]>179.9999?i[e][0]=179.9999:i[e][0]<-179.9999&&(i[e][0]=-179.9999);ae.has(d)?ae.get(d).push(i):ae.set(d,[i])}const m=ae.get(d);ne.has(d)||(ne.set(d,new Map),oe.set(d,new Map));const f=ne.get(d),w=oe.get(d);f.has(a.typeName)||(f.set(a.typeName,m.shift()),w.set(a.typeName,0));const b=f.get(a.typeName);w.set(a.typeName,w.get(a.typeName)+1);const N=new L({paths:[b]});if(a.feature.attributes[v]=N,p.has(a.typeName)){const e=p.get(a.typeName);e?.set(a.feature.attributes[M],a.feature)}else{const e=new Map;e.set(a.feature.attributes[M],a.feature),p.set(a.typeName,e)}c.set(a.feature.attributes[M],a.feature);const D=k(a.feature.attributes[v]);this.relationshipLinkChartDiagramLookup.set(a.feature.attributes[M],a.feature.attributes[v]?D:null);const E=s(this.dataManager.inclusionModeDefinition.namedTypeDefinitions,a.typeName,()=>({useAllData:!1,members:new Map}));s(E.members,a.feature.attributes[M],()=>({id:a.feature.attributes[M],linkChartLocation:void 0})).linkChartLocation=D}for(const n of r)n.feature.attributes[N]=oe.get(n.feature.attributes[C]+"-"+n.feature.attributes[T])?.get(n.typeName)??null;return this._currentLinkChartConfig={layoutMode:e,layoutSettings:t?.layoutSettings?.clone()},{nodes:h,links:p,idMap:c}}async applyNewLinkChartLayout(e="organic-standard",t){let{lockedNodeLocations:i,lockedEntityLocations:n,...s}=t??{};!n&&i?(a(o.getLogger(this),"lockedNodeLocations is deprecated in 5.0. Use lockedEntityLocations instead.",{replacement:"Use lockedEntityLocations instead.",version:"5.0"}),n=i):n&&i&&a(o.getLogger(this),"Both lockedNodeLocations (deprecated in 5.0) and lockedEntityLocations are defined. Use lockedEntityLocations only instead.",{replacement:"Use lockedEntityLocations instead.",version:"5.0"});const r=[];await this._calculateLayoutWithSublayerTimeInfo(e,{...s,lockedEntityLocations:n}),this.layers.forEach(e=>{r.push(e.refreshCachedQueryEngine())}),this.membershipModified=!0,await Promise.all(r),this._refreshNamedTypes()}getCurrentNodeLocations(){const e=new Map;for(const[t,i]of this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.entries()??[])this.dataManager.relationshipTypeNames.has(t)||i?.members?.forEach(t=>{const i=t.linkChartLocation;let a;const n=t.id;i&&(a="x"in i?{x:i.x,y:i.y}:{x:i.coords[0],y:i.coords[1]},e.set(n,new f({x:a.x,y:a.y})))});return e}async refreshLinkChartCache(e){await this.dataManager.refreshCacheContent(e);const t=[];this.layers.forEach(e=>{t.push(e.refreshCachedQueryEngine())}),await Promise.all(t),this._refreshNamedTypes()}async connectBetweenEntities(e,t){if(!e.length)return{records:[]};let i=[];try{let a=[];for(const e of this.dataManager.relationshipTypeNames){const t=this.sublayerIdsCache.get(e);t&&(a=a.concat(Array.from(t.keys())))}i=await this.dataManager.getRelationshipsBetweenNodes(e,a,t),await this._handleNewRecords(i,t),l(t)}catch(a){throw h(a)&&this.removeRecords(i),a}return{records:i}}async connectFromEntities(e,t){if(!e.length)return{records:[]};let i=[];try{let a=[];for(const e of this.dataManager.relationshipTypeNames){const t=this.sublayerIdsCache.get(e);t&&(a=a.concat(Array.from(t.keys())))}let n=[];for(const e of this.dataManager.entityTypeNames){const t=this.sublayerIdsCache.get(e);t&&(n=n.concat(Array.from(t)))}i=await this.dataManager.getRelationshipsFromNodes(e,n,a,t),await this._handleNewRecords(i,t),i.length>0&&(this.membershipModified=!0),l(t)}catch(a){throw h(a)&&this.removeRecords(i),a}return{records:i}}getCurrentLayout(){return this._currentLinkChartConfig.layoutMode}async _calculateLayoutWithSublayerTimeInfo(e="organic-standard",t){const i=new Map;this.layers.forEach(e=>{i.set(e.objectType.name,e.timeInfo)}),await this.calculateLinkChartLayout(e,{timeInfoByTypeName:i,...t}),this.linkChart?.handleChronologicalOverlay()}async _handleNewRecords(e,t){const i=new Set,a=[],n=this.layers.concat(this.tables);for(const r of e){if(!this._graphTypeLookup.has(r.typeName))continue;!1===n.some(e=>e.objectType.name===r.typeName)&&(this.dataManager.sublayerCaches.set(r.typeName,new Map),i.add(r.typeName));s(this.sublayerIdsCache,r.typeName,()=>new Set).add(r.id),a.push(r)}this.dataManager.addToLayer(a);for(const s of i){const e=this._graphTypeLookup.get(s);if(e){const t=this._createSublayer(e);"entity"===e.type?this.dataManager.entityTypeNames.add(s):this.dataManager.relationshipTypeNames.add(s),t.geometryType?this.layers.push(t):this.tables.push(t)}}await A(this,Array.from(i),t),await this.dataManager.refreshCacheContent(e.map(e=>e.id),void 0,void 0,void 0,t);const o={layoutSettings:this._currentLinkChartConfig.layoutSettings,lockedEntityLocations:new Map};for(const[s,r]of this.entityLinkChartDiagramLookup.entries())r&&o.lockedEntityLocations.set(s,new f(r.coords[0],r.coords[1]));await this.applyNewLinkChartLayout(this._currentLinkChartConfig.layoutMode,o)}_createSublayers(e,t,i){e.forEach(e=>{const a=this._createSublayer(e);i(a)&&t.push(a),this._updateSublayerCaches(e)})}_updateSublayers(e,t){t.forEach(t=>{t.parentCompositeLayer=this;const i=e.find(e=>e.type===t.graphType&&e.name===t.graphTypeName);i&&(t.objectType=i,t.read({title:i.name},{origin:"service"}),this._updateSublayerCaches(i))})}_updateSublayerCaches({name:e}){if(!e)return;const t=this.dataManager.sublayerCaches;t.has(e)||t.set(e,new Map)}_layersLoadedFromAuthoritativeItem(){const e=this.originIdOf("layers");return e>=3&&e<7}async _initializeDiagram(){this.initializationLinkChartConfig?this.initializationLinkChartConfig.doNotRecalculateLayout?(this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{e?.members?.forEach(e=>{const i=e.linkChartLocation;let a;const n=e.id;if(!i)return;a="x"in i?{x:i.x,y:i.y}:{x:i.coords[0],y:i.coords[1]};const o=k(a);this.dataManager.relationshipTypeNames.has(t)?this.relationshipLinkChartDiagramLookup.set(n,o):this.entityLinkChartDiagramLookup.set(n,o),this.linkChartExtent.xmin>a.x&&(this.linkChartExtent.xmin=a.x),this.linkChartExtent.xmax<a.x&&(this.linkChartExtent.xmax=a.x),this.linkChartExtent.ymin>a.y&&(this.linkChartExtent.ymin=a.y),this.linkChartExtent.ymax<a.y&&(this.linkChartExtent.ymax=a.y)})}),this.memberRelationshipTypes.forEach(e=>{e.name&&this.dataManager.sublayerCaches.get(e.name)?.forEach(e=>{const t=this.relationshipLinkChartDiagramLookup.get(e.attributes[C]),i=this.relationshipLinkChartDiagramLookup.get(e.attributes[T]);if(t&&i){const a=k(new L({paths:[[[t.coords[0],t.coords[1]],[i.coords[0],i.coords[1]]]]}));this.relationshipLinkChartDiagramLookup.set(e.attributes[M],a)}else this.relationshipLinkChartDiagramLookup.set(e.attributes[M],null)})})):await this._calculateLayoutWithSublayerTimeInfo(this.initializationLinkChartConfig.layoutMode,{lockedEntityLocations:this.getCurrentNodeLocations(),...this.initializationLinkChartConfig}):await this._calculateLayoutWithSublayerTimeInfo("organic-standard",{lockedEntityLocations:this.getCurrentNodeLocations()})}_refreshNamedTypes(){for(const e of this.layers)e.emit("refresh",{dataChanged:!0});for(const e of this.tables)e.emit("refresh",{dataChanged:!0})}_validateOrganicLayoutSettings(e,t){const i=e=>"number"==typeof e&&!isNaN(e),a=e=>i(e)&&e>=1,n=e=>i(e)&&e>=1,s=e=>Object.values(D).includes(e),r=e=>i(e)&&e>=0,l={};if(!new Set(["organic-standard","organic-community","geographic-organic-standard","chronological-multi-timeline","chronological-mono-timeline"]).has(e)||!t)return l;const{computationBudgetTime:h,autoRepulsionRadius:d,repulsionRadiusMultiplier:p,absoluteIdealEdgeLength:c,multiplicativeIdealEdgeLength:u,idealEdgeLengthType:y}=t;return n(h)?l.computationBudgetTime=h:h&&o.getLogger(this).warn("Invalid layout computationBudgetTime setting, will revert to default setting"),l.autoRepulsionRadius=d,!d&&a(p)?l.repulsionRadiusMultiplier=p:d||(l.autoRepulsionRadius=!0,o.getLogger(this).warn("Invalid layout repulsionRadiusMultiplier setting, will revert to default setting")),"geographic-organic-standard"===e&&(s(y)?l.idealEdgeLengthType=y:void 0!==y&&o.getLogger(this).warn('Invalid layout idealEdgeLengthType setting, will revert to "multiplier" setting'),"absolute-value"===y&&r(c)?l.absoluteIdealEdgeLength=c:"absolute-value"===y&&void 0!==c?o.getLogger(this).warn("Invalid layout idealEdgeLength setting, will revert to default setting"):"multiplier"===y&&r(u)?l.multiplicativeIdealEdgeLength=u:"multiplier"===y&&void 0!==u&&o.getLogger(this).warn("Invalid layout idealEdgeLength setting, will revert to default setting")),l}_convertValidatedOrganicSettingsToCalculationSettings(e){let t=e.idealEdgeLengthType===D.ABSOLUTE?e.absoluteIdealEdgeLength:e.multiplicativeIdealEdgeLength;return e.idealEdgeLengthType===D.ABSOLUTE&&(void 0===t?t=-1:t*=-1),{computationBudgetTime:e.computationBudgetTime??void 0,repulsionRadiusMultiplier:e.repulsionRadiusMultiplier&&!e.autoRepulsionRadius?e.repulsionRadiusMultiplier:void 0,idealEdgeLengthMultiplier:t}}_createSublayer(e){return new x({objectType:e,parentCompositeLayer:this,graphType:e.type})}_handleSublayersChange(e,t){t&&(t.forEach(e=>{e.parent=null}),this.removeHandles("sublayers-owner")),e&&(e.forEach(e=>{e.parent=this}),this.addHandles([e.on("after-add",({item:e})=>{e.parent=this}),e.on("after-remove",({item:e})=>{e.parent=null})],"sublayers-owner"))}_alignLayersDataModelAndInclusionDefinition(e){const t=new Set((e.entityTypes??[]).map(e=>e.name).concat((e.relationshipTypes??[]).map(e=>e.name))),a=new Set((e.entityTypes??[]).map(e=>e.name)),n=new Set((e.relationshipTypes??[]).map(e=>e.name));if(this.layers){for(const i of this.layers)!i.graphType&&t.has(i.graphTypeName)&&(i.graphType=a.has(i.graphTypeName)?"entity":"relationship");const e=this.layers.filter(e=>t.has(e.graphTypeName)&&("entity"===e.graphType?a.has(e.graphTypeName):n.has(e.graphTypeName)));this.setAtOrigin("layers",e,g(this.originIdOf("layers")))}else this.layers=new i;if(this.layers&&this._originalInclusionList){const e=new Set(this._originalInclusionList.namedTypeDefinitions.keys()),t=this.tables?.map(e=>e.graphTypeName)??[],i=this.layers.map(e=>e.graphTypeName).concat(t);for(const n of i)e.has(n)||this._originalInclusionList.namedTypeDefinitions.set(n,{useAllData:!1,members:new Map});const a=[];for(const n of this._originalInclusionList.namedTypeDefinitions.keys())i.includes(n)||(o.getLogger(this).warn(`A named type, ${n}, was in the serialized feature collection but did not have a sublayer config in the item, so will be removed`),a.push(n));for(const n of a)this._originalInclusionList.namedTypeDefinitions.delete(n)}}};e([u(F)],q.prototype,"url",void 0),e([u()],q.prototype,"dataPreloadedInLocalCache",void 0),e([u()],q.prototype,"initializationLinkChartConfig",void 0),e([u()],q.prototype,"membershipModified",void 0),e([u()],q.prototype,"dataManager",void 0),e([u()],q.prototype,"initializationInclusionModeDefinition",null),e([u()],q.prototype,"knowledgeGraph",void 0),e([u({type:i.ofType(x),json:{write:{ignoreOrigin:!0}}})],q.prototype,"layers",void 0),e([u({readOnly:!0})],q.prototype,"linkChart",null),e([u()],q.prototype,"entityLinkChartDiagramLookup",void 0),e([u()],q.prototype,"relationshipLinkChartDiagramLookup",void 0),e([u()],q.prototype,"linkChartExtent",void 0),e([u()],q.prototype,"memberEntityTypes",void 0),e([u()],q.prototype,"memberRelationshipTypes",void 0),e([u({type:["LinkChartLayer"]})],q.prototype,"operationalLayerType",void 0),e([u()],q.prototype,"sublayerCapabilities",null),e([u()],q.prototype,"sublayerIdsCache",void 0),e([u({type:i.ofType(x),json:{write:{ignoreOrigin:!0}}})],q.prototype,"tables",void 0),e([u({json:{read:!1}})],q.prototype,"type",void 0),e([u({readOnly:!0})],q.prototype,"userHasEditingPrivileges",void 0),e([u({readOnly:!0})],q.prototype,"userHasFullEditingPrivileges",void 0),e([u({readOnly:!0})],q.prototype,"userHasUpdateItemPrivileges",void 0),e([u({json:{read:!1}})],q.prototype,"chronologicalAuxiliaryGraphics",void 0),q=e([y("esri.layers.LinkChartLayer")],q);const X=q;export{X as default};
2
+ import{__decorate as e}from"tslib";import{serializationUtilsModuleWrapper as t}from"../applications/KnowledgeStudio/resourceSerializationUtils.js";import i from"../core/Collection.js";import{deprecated as a}from"../core/deprecate.js";import n from"../core/Error.js";import o from"../core/Logger.js";import{getOrCreateMapValue as s}from"../core/MapUtils.js";import{MultiOriginJSONSupportMixin as r}from"../core/MultiOriginJSONSupport.js";import{throwIfAborted as l,isAbortError as h,createAbortError as d}from"../core/promiseUtils.js";import{watch as p,sync as c}from"../core/reactiveUtils.js";import{property as u,subclass as y}from"../core/accessorSupport/decorators.js";import{idToName as g}from"../core/accessorSupport/PropertyOrigin.js";import m from"../geometry/Extent.js";import f from"../geometry/Point.js";import L from"../geometry/Polyline.js";import{polygonCentroidPoint as w}from"../geometry/support/centroid.js";import b from"./Layer.js";import{convertFromGeometry as k}from"./graphics/featureConversionUtils.js";import{systemOidFieldName as M,systemOriginIdFieldName as C,systemDestinationIdFieldName as T,systemLayoutGeometryFieldName as v,systemAggregationCountFieldName as N}from"./knowledgeGraph/constants.js";import{IdealEdgeLengthTypeOptions as D}from"./knowledgeGraph/IdealEdgeLengthTypeOptions.js";import{KnowledgeGraphLayerDataManager as E}from"./knowledgeGraph/KnowledgeGraphLayerDataManager.js";import x from"./knowledgeGraph/KnowledgeGraphSublayer.js";import{getTitleFromServerUrl as I,getUserKGSPrivileges as S,createCapabilitiesFromKnowledgeGraph as _,initializeLayersFromClientData as A}from"./knowledgeGraph/layerUtils.js";import R from"./knowledgeGraph/SessionMemoryStorage.js";import{convertLayoutTypeToWebSupportedFormat as j,getRelationshipEndNodeIds as P}from"./knowledgeGraph/supportUtils.js";import{BlendLayer as G}from"./mixins/BlendLayer.js";import{OperationalLayer as z}from"./mixins/OperationalLayer.js";import{ScaleRangeLayer as O}from"./mixins/ScaleRangeLayer.js";import{url as F}from"./support/commonProperties.js";import{LCChronologicalLayout as U,LCSimpleLayout as B,LCSmartTreeLayout as H,LCRadialTreeLayout as Q,LCHierarchicalLayout as W,LCCommunityLayout as $,LCForceDirectedLayout as K,load as J}from"../libs/linkchartlayout/LinkChartLayout.js";import{fetchKnowledgeGraph as V}from"../rest/knowledgeGraphService.js";let q=class extends(z(G(O(r(b))))){constructor(e){if(super(e),this.url=null,this.dataPreloadedInLocalCache=!1,this.initializationLinkChartConfig=null,this.membershipModified=!0,this._currentLinkChartConfig={layoutMode:"organic-standard"},this._graphTypeLookup=new Map,this.dataManager=null,this.knowledgeGraph=null,this.layers=new(i.ofType(x)),this.entityLinkChartDiagramLookup=new Map,this.relationshipLinkChartDiagramLookup=new Map,this.linkChartExtent=new m({xmin:-1e-7,ymin:-1e-7,xmax:1e-7,ymax:1e-7}),this.memberEntityTypes=null,this.memberRelationshipTypes=null,this.operationalLayerType="LinkChartLayer",this.sublayerIdsCache=new Map,this.tables=new(i.ofType(x)),this.type="link-chart",this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1,this.chronologicalAuxiliaryGraphics=null,this._originalInclusionList=e?.initializationInclusionModeDefinition,e?.dataPreloadedInLocalCache&&!e?.initializationInclusionModeDefinition)throw new n("knowledge-graph:linkchart-layer-constructor","If creating a link chart composite layer and configured that data is already loaded in the cache, you must specify an inclusion list so the Composite Layer knows what records belong to it");this.addHandles(p(()=>this.layers.concat(this.tables),(e,t)=>this._handleSublayersChange(e,t),c))}normalizeCtorArgs(e){if(!e)return{};const{url:t,dataPreloadedInLocalCache:i,initializationLinkChartConfig:a}=e;let{title:n}=e;return!n&&e?.url&&(n=I(e.url)),{url:t,title:n,dataPreloadedInLocalCache:i,initializationLinkChartConfig:a}}_initializeLayerProperties(e){const t=new Set;let i=[],a=[];if(e.inclusionModeDefinition&&(!e.inclusionModeDefinition.namedTypeDefinitions||e.inclusionModeDefinition.namedTypeDefinitions.size<1))throw new n("knowledge-graph:composite-layer-constructor","If an explicit inclusion definition is defined, at least one namedTypeDefinition must also be defined");e.inclusionModeDefinition?.generateAllSublayers?(i=e.knowledgeGraph.dataModel.entityTypes??[],a=e.knowledgeGraph.dataModel.relationshipTypes??[]):e.inclusionModeDefinition?.namedTypeDefinitions&&e.inclusionModeDefinition?.namedTypeDefinitions.size>0?e.inclusionModeDefinition?.namedTypeDefinitions.forEach((n,s)=>{const r=this._graphTypeLookup.get(s);if(!r)return o.getLogger(this).warn(`A named type, ${s}, was in the inclusion list that wasn't in the data model and will be removed`),void e.inclusionModeDefinition?.namedTypeDefinitions.delete(s);"relationship"===r.type?t.has(s)||(t.add(s),a.push(r)):"entity"===r.type?t.has(s)||(t.add(s),i.push(r)):(o.getLogger(this).warn(`A named type, ${s}, was in the inclusion list that wasn't properly modeled and will be removed`),e.inclusionModeDefinition?.namedTypeDefinitions.delete(s))}):(i=e.knowledgeGraph.dataModel.entityTypes??[],a=e.knowledgeGraph.dataModel.relationshipTypes??[]);const s=new E({knowledgeGraph:e.knowledgeGraph,inclusionModeDefinition:e.inclusionModeDefinition});this.knowledgeGraph=e.knowledgeGraph,this.memberEntityTypes=i,this.memberRelationshipTypes=a,this.dataManager=s}load(e){const i=async()=>{const e=[],t=[];this.loadLayerAssumingLocalCache(),this._layersLoadedFromAuthoritativeItem()||await A(this),this.dataManager.inclusionModeDefinition&&(this.dataManager.inclusionModeDefinition.generateAllSublayers=!1),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.forEach(e=>{e.useAllData=!1}),await this._initializeDiagram(),this.layers.forEach(i=>{t.push(i.refreshCachedQueryEngine()),e.push(new Promise(e=>{i.on("layerview-create",()=>{e(null)})}))}),this.tables.forEach(e=>{t.push(e.refreshCachedQueryEngine())}),await Promise.all(t)};return this.addResolvingPromise(new Promise(a=>{V(this.url).then(async n=>{n.dataModel.entityTypes?.forEach(e=>{e.name&&this._graphTypeLookup.set(e.name,e)}),n.dataModel.relationshipTypes?.forEach(e=>{e.name&&this._graphTypeLookup.set(e.name,e)});const o=this.linkChart?.linkChartProperties;6===o?.originIdOf("entitiesUrl")&&(this.membershipModified=!1,this._originalInclusionList=await t.fetchAndConvertSerializedLinkChart({entitiesUrl:o?.entitiesUrl,relationshipsUrl:o?.relationshipsUrl},{signal:e?.signal}),this._alignLayersDataModelAndInclusionDefinition(n.dataModel),this.initializationLinkChartConfig={layoutSettings:o?.layoutSettings??void 0,layoutMode:j(o.layoutType)}),this._initializeLayerProperties({knowledgeGraph:n,inclusionModeDefinition:this._originalInclusionList}),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.size||(this.dataManager.inclusionModeDefinition={generateAllSublayers:!1,namedTypeDefinitions:new Map},this.dataManager.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.set(e.name,{useAllData:!0})}),this.dataManager.knowledgeGraph.dataModel.relationshipTypes?.forEach(e=>{e.name&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.set(e.name,{useAllData:!0})}));const{edit:r,fullEdit:h,updateItem:d}=await S(n.serviceDefinition.serviceItemId,this.url,e);if(this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",h),this._set("userHasUpdateItemPrivileges",d),this.dataPreloadedInLocalCache){const e=R.getInstance();for(const[t,i]of this.dataManager.inclusionModeDefinition?.namedTypeDefinitions??[])for(const a of i.members?.values()??[]){const i=e.readFromStoreById(`${t}__${a.id}`);if(i){s(this.dataManager.sublayerCaches,t,()=>new Map).set(a.id,i)}}await i()}else{const t="geographic-organic-standard"===this.initializationLinkChartConfig?.layoutMode;this.addResolvingPromise(this.dataManager.refreshCacheContent(void 0,!1,t,!0).then(async()=>{l(e),await i()}))}a(null)})})),Promise.resolve(this)}set initializationInclusionModeDefinition(e){"loaded"!==this.loadStatus&&"failed"!==this.loadStatus?this._set("initializationInclusionModeDefinition",e):o.getLogger(this).error("#initializationInclusionModeDefinition","initializationInclusionModeDefinition cannot be changed after the layer is loaded.")}get linkChart(){return this.parent}get sublayerCapabilities(){return _(this.knowledgeGraph)}async addRecords(e,t){let i=[];t?.cascadeAddRelationshipEndNodes&&this.dataManager.knowledgeGraph.dataModel&&(i=await P(e,this.dataManager.knowledgeGraph));const a=e.concat(i).filter(e=>!this.sublayerIdsCache.get(e.typeName)?.has(e.id));a.length>0&&(this.membershipModified=!0),await this._handleNewRecords(a,t)}async createSublayerForNamedType(e){await this.load();const t=this._graphTypeLookup.get(e);if(!t)throw new n("knowledge-graph:missing-type","The specified type does not exist in the knowledge graph.");if(this.dataManager.sublayerCaches.has(e))throw new n("knowledge-graph:duplicate-type","The specified type already exists as a sublayer.");this.dataManager.sublayerCaches.set(e,new Map),s(this.sublayerIdsCache,e,()=>new Set);const i=this._createSublayer(t);return"entity"===t.type?this.dataManager.entityTypeNames.add(e):this.dataManager.relationshipTypeNames.add(e),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.set(e,{useAllData:!1,members:new Map}),i.geometryType?this.layers.push(i):this.tables.push(i),await A(this,[e]),this._refreshNamedTypes(),i}async removeRecords(e,{cascadeRemoveRelationships:t=!0,recalculateLayout:i=!1,overrideMembershipCheck:a=!1}={cascadeRemoveRelationships:!0,recalculateLayout:!1,overrideMembershipCheck:!1}){let n=[];for(const r of e)(a||!1===this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.get(r.typeName)?.useAllData&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.get(r.typeName)?.members?.has(r.id))&&n.push(r);if(t){const e=new Set,t=[];for(const i of n)if(this.dataManager.nodeConnectionsLookup.has(i.id))for(const t of this.dataManager.nodeConnectionsLookup.get(i.id))e.add(t);for(const i of e)if(this.dataManager.memberIdTypeLookup.has(i))for(const e of this.dataManager.memberIdTypeLookup.get(i))this.dataManager.relationshipTypeNames.has(e)&&t.push({id:i,typeName:e});n=n.concat(t)}this.dataManager.removeFromLayer(n);for(const r of n)this.sublayerIdsCache.get(r.typeName)?.delete(r.id),this.dataManager.relationshipTypeNames.has(r.typeName)?this.relationshipLinkChartDiagramLookup.delete(r.id):this.entityLinkChartDiagramLookup.delete(r.id);const o=i?void 0:this.getCurrentNodeLocations();await this._calculateLayoutWithSublayerTimeInfo(this._currentLinkChartConfig.layoutMode,{layoutSettings:this._currentLinkChartConfig.layoutSettings,lockedEntityLocations:o}),n.length>0&&(this.membershipModified=!0);const s=[];return this.layers.forEach(e=>{s.push(e.refreshCachedQueryEngine())}),await Promise.all(s),this._refreshNamedTypes(),n}async expand(e,t){let i=[];try{const a=await this.dataManager.getConnectedRecordIds(e,t?.relationshipTypeNames,t);i=a.filter(e=>!this.sublayerIdsCache.get(e.typeName)?.has(e.id)),await this._handleNewRecords(i,t),a.length>0&&(this.membershipModified=!0),l(t?.signal)}catch(a){throw h(a)&&i.length>0&&await this.removeRecords(i,{overrideMembershipCheck:!0}),a}return{records:i}}loadLayerAssumingLocalCache(){const e=[...this.memberRelationshipTypes,...this.memberEntityTypes];this.layers.length||0===this.originIdOf("tables")?0===this.originIdOf("layers")?this._createSublayers(e,this.layers,e=>!!e.geometryType):this._updateSublayers(e,this.layers):this.layers=new i,this.tables.length||0===this.originIdOf("layers")?0===this.originIdOf("tables")?this._createSublayers(e,this.tables,e=>!e.geometryType):this._updateSublayers(e,this.tables):this.tables=new i,this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{const i=s(this.sublayerIdsCache,t,()=>new Set);e.members?.forEach(({id:e,linkChartLocation:a})=>{if(i.add(e),a){const i="coords"in a&&"lengths"in a?a:k(a);this.dataManager.relationshipTypeNames.has(t)?this.relationshipLinkChartDiagramLookup.set(e,i):this.entityLinkChartDiagramLookup.set(e,i)}})})}async calculateLinkChartLayout(e="organic-standard",t){const i=[],a=[],r=[];this.dataManager.sublayerCaches.forEach((e,t)=>{this.dataManager.entityTypeNames.has(t)?e.forEach(e=>{i.push({typeName:t,feature:e})}):this.dataManager.relationshipTypeNames.has(t)&&e.forEach(e=>{a.push({typeName:t,feature:e})})}),this.entityLinkChartDiagramLookup=new Map,this.relationshipLinkChartDiagramLookup=new Map;const h=new Map,p=new Map,c=new Map,u=new Map,y=new Uint8Array(i.length),g=new Float64Array(i.length),b=new Float64Array(i.length),D=new Float64Array(i.length),E=new Float64Array(i.length),x=new Uint32Array(a.length),I=new Uint32Array(a.length),S=new Float64Array(a.length),_=new Float64Array(a.length),A=[],R="organic-standard";let j=!1;const P=new m({xmin:-1e-7,ymin:-1e-7,xmax:1e-7,ymax:1e-7});let G,z="organic-standard",O=0,F=0;const V=U.apply;switch(z="geographic-organic-standard"===e?R:e,z){case"organic-standard":G=K.apply;break;case"organic-community":G=$.apply;break;case"hierarchical-bottom-to-top":G=W.apply;break;case"radial-root-centric":G=Q.apply;break;case"tree-left-to-right":G=H.apply;break;default:G=B.apply}let q=!1;i.forEach(({typeName:i,feature:a})=>{if("chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e&&t?.lockedEntityLocations?.has(a.attributes[M])){"geographic-organic-standard"===e&&this.dataManager.geographicLookup.has(i)?y[O]=2:y[O]=0;const n=t.lockedEntityLocations.get(a.attributes[M]);g[O]=n.x,b[O]=n.y}else if("geographic-organic-standard"===e&&this.dataManager.geographicLookup.has(i)){y[O]=2;let e=null;const t=a.attributes[this.dataManager.geographicLookup.get(i).name],n=this.dataManager.geographicLookup.get(i)?.geometryType;switch(n){case"esriGeometryPoint":g[O]=t?.x,b[O]=t?.y;break;case"esriGeometryPolygon":{const i=t?w(t):null;e=i?f.fromJSON(i):null,null!=e?.x&&null!=e?.y?(g[O]=e.x,b[O]=e.y):y[O]=1;break}case"esriGeometryPolyline":case"esriGeometryMultipoint":e=t?.extent?.center,null!=e?.x&&null!=e?.y?(g[O]=e.x,b[O]=e.y):y[O]=1;break;default:y[O]=1}(null==g[O]||null==b[O]||Number.isNaN(g[O])||Number.isNaN(b[O]))&&(y[O]=1,g[O]=0,b[O]=0)}else if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){!q&&t?.lockedEntityLocations?.has(a.attributes[M])&&(q=!0);const e=t?.timeInfoByTypeName?.get(i),n=e?.startField,o=n&&e?.startField?a.attributes[n]:null;D[O]=o?new Date(o).getTime():NaN;const s=e?.endField,r=s&&e?.endField?a.attributes[s]:null;E[O]=r?new Date(r).getTime():NaN,g[O]=0,b[O]=0,y[O]=1}else y[O]=1,g[O]=0,b[O]=0;t?.rootEntityIds?.has(a.attributes[M])&&(y[O]|=4),u.set(a.attributes[M],O),A[O]={feature:a,typeName:i},O++}),q&&o.getLogger(this).warn("Locked node locations are not supported for chronological layout at this time. Requested node locations were ignored");let X=!1;const Y=new Map;a.forEach(i=>{const a=i.feature.attributes[C],n=i.feature.attributes[T],o=u.get(a),s=u.get(n),l=t?.timeInfoByTypeName?.get(i.typeName),h=t?.timeInfoByTypeName?l?.startField:null,d=h?i.feature.attributes[h]:null,p=l?.endField,c=p?i.feature.attributes[p]:null;if(void 0!==o&&void 0!==s){let t=a+"-"+n;"chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e||(t=t+"-"+d+"-"+c);const l=Y.get(t),h=l?.has(i.typeName);h||(x[F]=o,I[F]=s,"chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e||(S[F]=d?new Date(d).getTime():NaN,_[F]=c?new Date(c).getTime():NaN),void 0===l?Y.set(t,new Map([[i.typeName,F]])):l.set(i.typeName,F),F++),r.push(i)}else X=!0,this.relationshipLinkChartDiagramLookup.set(a,null)}),X&&o.getLogger(this).warn("A relationship is a member of this layer that has either origin or destination entity nodes that are not members. The diagram geometry will be set to null");const Z=this._validateOrganicLayoutSettings(e,t?.layoutSettings?.organicLayoutSettings),ee=this._convertValidatedOrganicSettingsToCalculationSettings(Z);await J();let te=1,ie=null;if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){let i;({status:te,links:ie,graphics:i}=V(()=>t?.signal?.aborted??!1,y,g,b,D,E,x.subarray(0,F),I.subarray(0,F),S.subarray(0,F),_.subarray(0,F),"chronological-multi-timeline"===e,t?.layoutSettings?.chronologicalLayoutSettings)),0===te&&(this.chronologicalAuxiliaryGraphics=i)}else({status:te,links:ie}=G(()=>t?.signal?.aborted??!1,y,g,b,x.subarray(0,F),I.subarray(0,F),ee.computationBudgetTime,ee.idealEdgeLengthMultiplier,ee.repulsionRadiusMultiplier));if(l(t?.signal),1===te)throw new n("knowledge-graph:layout-failed","Attempting to arrange the records in the specified layout failed");if(2===te)throw d();for(let n=0;n<A.length;n++){if(b[n]>84.9999?b[n]=84.9999:b[n]<-84.9999&&(b[n]=-84.9999),g[n]>179.9999?g[n]=179.9999:g[n]<-179.9999&&(g[n]=-179.9999),A[n].feature.attributes[v]=new f(g[n],b[n]),h.has(A[n].typeName)){const e=h.get(A[n].typeName);e?.set(A[n].feature.attributes[M],A[n].feature)}else{const e=new Map;e.set(A[n].feature.attributes[M],A[n].feature),h.set(A[n].typeName,e)}c.set(A[n].feature.attributes[M],A[n].feature);const e=k(A[n].feature.attributes[v]);this.entityLinkChartDiagramLookup.set(A[n].feature.attributes[M],A[n].feature.attributes[v]?e:null);const t=s(this.dataManager.inclusionModeDefinition.namedTypeDefinitions,A[n].typeName,()=>({useAllData:!1,members:new Map}));s(t.members,A[n].feature.attributes[M],()=>({id:A[n].feature.attributes[M],linkChartLocation:void 0})).linkChartLocation=A[n].feature.attributes[v];const{x:i,y:a}=A[n].feature.attributes[v];if(j)P.xmin=Math.min(P.xmin,i),P.xmax=Math.max(P.xmax,i),P.ymin=Math.min(P.ymin,a),P.ymax=Math.max(P.ymax,a);else{const e=1e-7;P.xmin=i-e,P.xmax=i+e,P.ymin=a-e,P.ymax=a+e,j=!0}}if(this.linkChartExtent.xmin=P.xmin,this.linkChartExtent.xmax=P.xmax,this.linkChartExtent.ymin=P.ymin,this.linkChartExtent.ymax=P.ymax,!ie)throw new n("knowledge-graph:layout-failed","Attempting to retrieve link geometry from diagram engine failed");const ae=new Map,ne=new Map,oe=new Map,se=new Set;for(let n=0;n<r.length;n++){const i=[],a=r[n],l=a.feature.attributes[C],h=a.feature.attributes[T];let d=l+"-"+h;if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){const e=t?.timeInfoByTypeName?.get(a.typeName),i=t?.timeInfoByTypeName?e?.startField:null,n=i?a.feature.attributes[i]:null,o=e?.endField;d+="-"+n+"-"+(o?a.feature.attributes[o]:null)}const y=Y.get(d).get(a.typeName),g=0===y?0:ie?.vertexEndIndex[y-1];if(!se.has(y)){if(se.add(y),2===ie.types[y]){const e=[ie.vertices[2*g],ie.vertices[2*g+1]],t=[ie.vertices[2*(g+1)],ie.vertices[2*(g+1)+1]],a=[.5*(e[0]+t[0]),.5*(e[1]+t[1])],n=[a[0]-e[0],a[1]-e[1]],o=[a[0]+n[1],a[1]-n[0]],s=[a[0]-n[1],a[1]+n[0]];i.push(e),i.push(o),i.push(t),i.push(s),i.push(e)}else{if(0!==ie.types[y]){o.getLogger(this).warn("A relationship generated an unsupported link geometry type. It will not be rendered");continue}for(let e=g;e<ie.vertexEndIndex[y];e++)i.push([ie.vertices[2*e],ie.vertices[2*e+1]])}if("chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e){const e=A[u.get(l)]?.feature.attributes[v],t=A[u.get(h)]?.feature.attributes[v];i[0][0]===e.x&&i[0][1]===e.y||(i[0]=[e.x,e.y]),i[i.length-1][0]===t.x&&i[i.length-1][1]===t.y||(i[i.length-1]=[t.x,t.y])}for(let e=1;e<i.length-1;e++)i[e][1]>85.5?i[e][1]=85.5:i[e][1]<-85.5&&(i[e][1]=-85.5),i[e][0]>179.9999?i[e][0]=179.9999:i[e][0]<-179.9999&&(i[e][0]=-179.9999);ae.has(d)?ae.get(d).push(i):ae.set(d,[i])}const m=ae.get(d);ne.has(d)||(ne.set(d,new Map),oe.set(d,new Map));const f=ne.get(d),w=oe.get(d);f.has(a.typeName)||(f.set(a.typeName,m.shift()),w.set(a.typeName,0));const b=f.get(a.typeName);w.set(a.typeName,w.get(a.typeName)+1);const N=new L({paths:[b]});if(a.feature.attributes[v]=N,p.has(a.typeName)){const e=p.get(a.typeName);e?.set(a.feature.attributes[M],a.feature)}else{const e=new Map;e.set(a.feature.attributes[M],a.feature),p.set(a.typeName,e)}c.set(a.feature.attributes[M],a.feature);const D=k(a.feature.attributes[v]);this.relationshipLinkChartDiagramLookup.set(a.feature.attributes[M],a.feature.attributes[v]?D:null);const E=s(this.dataManager.inclusionModeDefinition.namedTypeDefinitions,a.typeName,()=>({useAllData:!1,members:new Map}));s(E.members,a.feature.attributes[M],()=>({id:a.feature.attributes[M],linkChartLocation:void 0})).linkChartLocation=D}for(const n of r)n.feature.attributes[N]=oe.get(n.feature.attributes[C]+"-"+n.feature.attributes[T])?.get(n.typeName)??null;return this._currentLinkChartConfig={layoutMode:e,layoutSettings:t?.layoutSettings?.clone()},{nodes:h,links:p,idMap:c}}async applyNewLinkChartLayout(e="organic-standard",t){let{lockedNodeLocations:i,lockedEntityLocations:n,...s}=t??{};!n&&i?(a(o.getLogger(this),"lockedNodeLocations is deprecated in 5.0. Use lockedEntityLocations instead.",{replacement:"Use lockedEntityLocations instead.",version:"5.0"}),n=i):n&&i&&a(o.getLogger(this),"Both lockedNodeLocations (deprecated in 5.0) and lockedEntityLocations are defined. Use lockedEntityLocations only instead.",{replacement:"Use lockedEntityLocations instead.",version:"5.0"});const r=[];await this._calculateLayoutWithSublayerTimeInfo(e,{...s,lockedEntityLocations:n}),this.layers.forEach(e=>{r.push(e.refreshCachedQueryEngine())}),this.membershipModified=!0,await Promise.all(r),this._refreshNamedTypes()}getCurrentNodeLocations(){const e=new Map;for(const[t,i]of this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.entries()??[])this.dataManager.relationshipTypeNames.has(t)||i?.members?.forEach(t=>{const i=t.linkChartLocation;let a;const n=t.id;i&&(a="x"in i?{x:i.x,y:i.y}:{x:i.coords[0],y:i.coords[1]},e.set(n,new f({x:a.x,y:a.y})))});return e}async refreshLinkChartCache(e){await this.dataManager.refreshCacheContent(e);const t=[];this.layers.forEach(e=>{t.push(e.refreshCachedQueryEngine())}),await Promise.all(t),this._refreshNamedTypes()}async connectBetweenEntities(e,t){if(!e.length)return{records:[]};let i=[];try{let a=[];for(const e of this.dataManager.relationshipTypeNames){const t=this.sublayerIdsCache.get(e);t&&(a=a.concat(Array.from(t.keys())))}i=await this.dataManager.getRelationshipsBetweenNodes(e,a,t),await this._handleNewRecords(i,t),l(t)}catch(a){throw h(a)&&this.removeRecords(i),a}return{records:i}}async connectFromEntities(e,t){if(!e.length)return{records:[]};let i=[];try{let a=[];for(const e of this.dataManager.relationshipTypeNames){const t=this.sublayerIdsCache.get(e);t&&(a=a.concat(Array.from(t.keys())))}let n=[];for(const e of this.dataManager.entityTypeNames){const t=this.sublayerIdsCache.get(e);t&&(n=n.concat(Array.from(t)))}i=await this.dataManager.getRelationshipsFromNodes(e,n,a,t),await this._handleNewRecords(i,t),i.length>0&&(this.membershipModified=!0),l(t)}catch(a){throw h(a)&&this.removeRecords(i),a}return{records:i}}getCurrentLayout(){return this._currentLinkChartConfig.layoutMode}async _calculateLayoutWithSublayerTimeInfo(e="organic-standard",t){const i=new Map;this.layers.forEach(e=>{i.set(e.objectType.name,e.timeInfo)}),await this.calculateLinkChartLayout(e,{timeInfoByTypeName:i,...t}),this.linkChart?.handleChronologicalOverlay()}async _handleNewRecords(e,t){const i=new Set,a=[],n=this.layers.concat(this.tables);for(const r of e){if(!this._graphTypeLookup.has(r.typeName))continue;!1===n.some(e=>e.objectType.name===r.typeName)&&(this.dataManager.sublayerCaches.set(r.typeName,new Map),i.add(r.typeName));s(this.sublayerIdsCache,r.typeName,()=>new Set).add(r.id),a.push(r)}this.dataManager.addToLayer(a);for(const s of i){const e=this._graphTypeLookup.get(s);if(e){const t=this._createSublayer(e);"entity"===e.type?this.dataManager.entityTypeNames.add(s):this.dataManager.relationshipTypeNames.add(s),t.geometryType?this.layers.push(t):this.tables.push(t)}}await A(this,Array.from(i),t),await this.dataManager.refreshCacheContent(e.map(e=>e.id),void 0,void 0,void 0,t);const o={layoutSettings:this._currentLinkChartConfig.layoutSettings,lockedEntityLocations:new Map};for(const[s,r]of this.entityLinkChartDiagramLookup.entries())r&&o.lockedEntityLocations.set(s,new f(r.coords[0],r.coords[1]));await this.applyNewLinkChartLayout(this._currentLinkChartConfig.layoutMode,o)}_createSublayers(e,t,i){e.forEach(e=>{const a=this._createSublayer(e);i(a)&&t.push(a),this._updateSublayerCaches(e)})}_updateSublayers(e,t){t.forEach(t=>{t.parentCompositeLayer=this;const i=e.find(e=>e.type===t.graphType&&e.name===t.graphTypeName);i&&(t.objectType=i,t.read({title:i.name},{origin:"service"}),this._updateSublayerCaches(i))})}_updateSublayerCaches({name:e}){if(!e)return;const t=this.dataManager.sublayerCaches;t.has(e)||t.set(e,new Map)}_layersLoadedFromAuthoritativeItem(){const e=this.originIdOf("layers");return e>=3&&e<7}async _initializeDiagram(){this.initializationLinkChartConfig?this.initializationLinkChartConfig.doNotRecalculateLayout?(this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{e?.members?.forEach(e=>{const i=e.linkChartLocation;let a;const n=e.id;if(!i)return;a="x"in i?{x:i.x,y:i.y}:{x:i.coords[0],y:i.coords[1]};const o=k(a);this.dataManager.relationshipTypeNames.has(t)?this.relationshipLinkChartDiagramLookup.set(n,o):this.entityLinkChartDiagramLookup.set(n,o),this.linkChartExtent.xmin>a.x&&(this.linkChartExtent.xmin=a.x),this.linkChartExtent.xmax<a.x&&(this.linkChartExtent.xmax=a.x),this.linkChartExtent.ymin>a.y&&(this.linkChartExtent.ymin=a.y),this.linkChartExtent.ymax<a.y&&(this.linkChartExtent.ymax=a.y)})}),this.memberRelationshipTypes.forEach(e=>{e.name&&this.dataManager.sublayerCaches.get(e.name)?.forEach(e=>{const t=this.relationshipLinkChartDiagramLookup.get(e.attributes[C]),i=this.relationshipLinkChartDiagramLookup.get(e.attributes[T]);if(t&&i){const a=k(new L({paths:[[[t.coords[0],t.coords[1]],[i.coords[0],i.coords[1]]]]}));this.relationshipLinkChartDiagramLookup.set(e.attributes[M],a)}else this.relationshipLinkChartDiagramLookup.set(e.attributes[M],null)})})):await this._calculateLayoutWithSublayerTimeInfo(this.initializationLinkChartConfig.layoutMode,{lockedEntityLocations:this.getCurrentNodeLocations(),...this.initializationLinkChartConfig}):await this._calculateLayoutWithSublayerTimeInfo("organic-standard",{lockedEntityLocations:this.getCurrentNodeLocations()})}_refreshNamedTypes(){for(const e of this.layers)e.emit("refresh",{dataChanged:!0});for(const e of this.tables)e.emit("refresh",{dataChanged:!0})}_validateOrganicLayoutSettings(e,t){const i=e=>"number"==typeof e&&!isNaN(e),a=e=>i(e)&&e>=1,n=e=>i(e)&&e>=1,s=e=>Object.values(D).includes(e),r=e=>i(e)&&e>=0,l={};if(!new Set(["organic-standard","organic-community","geographic-organic-standard","chronological-multi-timeline","chronological-mono-timeline"]).has(e)||!t)return l;const{computationBudgetTime:h,autoRepulsionRadius:d,repulsionRadiusMultiplier:p,absoluteIdealEdgeLength:c,multiplicativeIdealEdgeLength:u,idealEdgeLengthType:y}=t;return n(h)?l.computationBudgetTime=h:h&&o.getLogger(this).warn("Invalid layout computationBudgetTime setting, will revert to default setting"),l.autoRepulsionRadius=d,!d&&a(p)?l.repulsionRadiusMultiplier=p:d||(l.autoRepulsionRadius=!0,o.getLogger(this).warn("Invalid layout repulsionRadiusMultiplier setting, will revert to default setting")),"geographic-organic-standard"===e&&(s(y)?l.idealEdgeLengthType=y:void 0!==y&&o.getLogger(this).warn('Invalid layout idealEdgeLengthType setting, will revert to "multiplier" setting'),"absolute-value"===y&&r(c)?l.absoluteIdealEdgeLength=c:"absolute-value"===y&&void 0!==c?o.getLogger(this).warn("Invalid layout idealEdgeLength setting, will revert to default setting"):"multiplier"===y&&r(u)?l.multiplicativeIdealEdgeLength=u:"multiplier"===y&&void 0!==u&&o.getLogger(this).warn("Invalid layout idealEdgeLength setting, will revert to default setting")),l}_convertValidatedOrganicSettingsToCalculationSettings(e){let t=e.idealEdgeLengthType===D.ABSOLUTE?e.absoluteIdealEdgeLength:e.multiplicativeIdealEdgeLength;return e.idealEdgeLengthType===D.ABSOLUTE&&(void 0===t?t=-1:t*=-1),{computationBudgetTime:e.computationBudgetTime??void 0,repulsionRadiusMultiplier:e.repulsionRadiusMultiplier&&!e.autoRepulsionRadius?e.repulsionRadiusMultiplier:void 0,idealEdgeLengthMultiplier:t}}_createSublayer(e){return new x({objectType:e,parentCompositeLayer:this,graphType:e.type})}_handleSublayersChange(e,t){t&&(t.forEach(e=>{e.parent=null}),this.removeHandles("sublayers-owner")),e&&(e.forEach(e=>{e.parent=this}),this.addHandles([e.on("after-add",({item:e})=>{e.parent=this}),e.on("after-remove",({item:e})=>{e.parent=null})],"sublayers-owner"))}_alignLayersDataModelAndInclusionDefinition(e){const t=new Set((e.entityTypes??[]).map(e=>e.name).concat((e.relationshipTypes??[]).map(e=>e.name))),a=new Set((e.entityTypes??[]).map(e=>e.name)),n=new Set((e.relationshipTypes??[]).map(e=>e.name));if(this.layers){for(const i of this.layers)!i.graphType&&t.has(i.graphTypeName)&&(i.graphType=a.has(i.graphTypeName)?"entity":"relationship");const e=this.layers.filter(e=>t.has(e.graphTypeName)&&("entity"===e.graphType?a.has(e.graphTypeName):n.has(e.graphTypeName)));this.setAtOrigin("layers",e,g(this.originIdOf("layers")))}else this.layers=new i;if(this.layers&&this._originalInclusionList){const e=new Set(this._originalInclusionList.namedTypeDefinitions.keys()),t=this.tables?.map(e=>e.graphTypeName)??[],i=this.layers.map(e=>e.graphTypeName).concat(t);for(const n of i)e.has(n)||this._originalInclusionList.namedTypeDefinitions.set(n,{useAllData:!1,members:new Map});const a=[];for(const n of this._originalInclusionList.namedTypeDefinitions.keys())i.includes(n)||(o.getLogger(this).warn(`A named type, ${n}, was in the serialized feature collection but did not have a sublayer config in the item, so will be removed`),a.push(n));for(const n of a)this._originalInclusionList.namedTypeDefinitions.delete(n)}}};e([u(F)],q.prototype,"url",void 0),e([u()],q.prototype,"dataPreloadedInLocalCache",void 0),e([u()],q.prototype,"initializationLinkChartConfig",void 0),e([u()],q.prototype,"membershipModified",void 0),e([u()],q.prototype,"dataManager",void 0),e([u()],q.prototype,"initializationInclusionModeDefinition",null),e([u()],q.prototype,"knowledgeGraph",void 0),e([u({type:i.ofType(x),json:{write:{ignoreOrigin:!0}}})],q.prototype,"layers",void 0),e([u({readOnly:!0})],q.prototype,"linkChart",null),e([u()],q.prototype,"entityLinkChartDiagramLookup",void 0),e([u()],q.prototype,"relationshipLinkChartDiagramLookup",void 0),e([u()],q.prototype,"linkChartExtent",void 0),e([u()],q.prototype,"memberEntityTypes",void 0),e([u()],q.prototype,"memberRelationshipTypes",void 0),e([u({type:["LinkChartLayer"]})],q.prototype,"operationalLayerType",void 0),e([u()],q.prototype,"sublayerCapabilities",null),e([u()],q.prototype,"sublayerIdsCache",void 0),e([u({type:i.ofType(x),json:{write:{ignoreOrigin:!0}}})],q.prototype,"tables",void 0),e([u({json:{read:!1}})],q.prototype,"type",void 0),e([u({readOnly:!0})],q.prototype,"userHasEditingPrivileges",void 0),e([u({readOnly:!0})],q.prototype,"userHasFullEditingPrivileges",void 0),e([u({readOnly:!0})],q.prototype,"userHasUpdateItemPrivileges",void 0),e([u({json:{read:!1}})],q.prototype,"chronologicalAuxiliaryGraphics",void 0),q=e([y("esri.layers.LinkChartLayer")],q);const X=q;export{X as default};
@@ -2,7 +2,6 @@ import type { __FeatureLayerSansType } from "./FeatureLayer.js";
2
2
  import type SpatialReference from "../geometry/SpatialReference.js";
3
3
  import type FeatureLayer from "./FeatureLayer.js";
4
4
  import type Field from "./support/Field.js";
5
- import type FieldConfiguration from "./support/FieldConfiguration.js";
6
5
  import type PortalItem from "../portal/PortalItem.js";
7
6
  import type FeatureSet from "../rest/support/FeatureSet.js";
8
7
  import type { LayerSaveAsOptions, LayerSaveOptions } from "./types.js";
@@ -48,59 +47,6 @@ export interface OrientedImageryLayerProperties extends FeatureLayerProperties,
48
47
  * @since 4.29
49
48
  */
50
49
  displayField?: string | null;
51
- /**
52
- * > [!WARNING]
53
- * >
54
- * > **Note**
55
- * >
56
- * > This property is currently not supported in OrientedImageryLayer. It is ignored and will always return `null`.
57
- *
58
- * @since 4.34
59
- * @see [getFieldConfiguration()](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#getFieldConfiguration)
60
- * @see [getFieldAlias()](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#getFieldAlias)
61
- * @see [FieldConfiguration](https://developers.arcgis.com/javascript/latest/references/core/layers/support/FieldConfiguration/)
62
- * @example
63
- * // Adding a new field configuration
64
- * const addNewConfig = (layer, fieldName, alias,
65
- * fieldFormat) => {
66
- * // Check if there is already an existing configuration for fieldName
67
- * const existingConfig = layer.getFieldConfiguration(fieldName);
68
- * if (!existingConfig) {
69
- * const newConfig = new FieldConfiguration({ name: fieldName, alias, fieldFormat });
70
- * const newConfigs = clone(layer.fieldConfigurations);
71
- * newConfigs.push(newConfig);
72
- * layer.fieldConfigurations = newConfigs;
73
- * }
74
- * };
75
- * @example
76
- * // Updating an existing field configuration
77
- * const updateConfig = (layer, fieldName, alias,
78
- * fieldFormat) => {
79
- * const existingConfig = layer.getFieldConfiguration(fieldName);
80
- * if (existingConfig) {
81
- * const newConfig = existingConfig.clone();
82
- * newConfig.alias = alias;
83
- * newConfig.fieldFormat = fieldFormat;
84
- *
85
- * const index = layer.fieldConfigurations.indexOf(existingConfig);
86
- * const newConfigs = clone(layer.fieldConfigurations);
87
- * newConfigs[index] = newConfig;
88
- * layer.fieldConfigurations = newConfigs;
89
- * }
90
- * };
91
- * @example
92
- * // Deleting an existing field configuration
93
- * const deleteConfig = (layer, fieldName) => {
94
- * const existingConfig = layer.getFieldConfiguration(fieldName);
95
- * if (existingConfig) {
96
- * const index = layer.fieldConfigurations.indexOf(existingConfig);
97
- * var newConfigs = clone(layer.fieldConfigurations);
98
- * newConfigs.splice(index, 1);
99
- * layer.fieldConfigurations = newConfigs;
100
- * }
101
- * };
102
- */
103
- fieldConfigurations?: FieldConfiguration[] | null;
104
50
  /**
105
51
  * An array of fields in the layer. Each field represents an attribute
106
52
  * that may contain a value for each feature in the layer. For example,
@@ -542,60 +488,6 @@ export default class OrientedImageryLayer extends __FeatureLayerSansType {
542
488
  * layer.farDistance = 60;
543
489
  */
544
490
  accessor farDistance: number | null | undefined;
545
- /**
546
- * > [!WARNING]
547
- * >
548
- * > **Note**
549
- * >
550
- * > This property is currently not supported in OrientedImageryLayer. It is ignored and will always return `null`.
551
- *
552
- * @since 4.34
553
- * @see [getFieldConfiguration()](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#getFieldConfiguration)
554
- * @see [getFieldAlias()](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#getFieldAlias)
555
- * @see [FieldConfiguration](https://developers.arcgis.com/javascript/latest/references/core/layers/support/FieldConfiguration/)
556
- * @example
557
- * // Adding a new field configuration
558
- * const addNewConfig = (layer, fieldName, alias,
559
- * fieldFormat) => {
560
- * // Check if there is already an existing configuration for fieldName
561
- * const existingConfig = layer.getFieldConfiguration(fieldName);
562
- * if (!existingConfig) {
563
- * const newConfig = new FieldConfiguration({ name: fieldName, alias, fieldFormat });
564
- * const newConfigs = clone(layer.fieldConfigurations);
565
- * newConfigs.push(newConfig);
566
- * layer.fieldConfigurations = newConfigs;
567
- * }
568
- * };
569
- * @example
570
- * // Updating an existing field configuration
571
- * const updateConfig = (layer, fieldName, alias,
572
- * fieldFormat) => {
573
- * const existingConfig = layer.getFieldConfiguration(fieldName);
574
- * if (existingConfig) {
575
- * const newConfig = existingConfig.clone();
576
- * newConfig.alias = alias;
577
- * newConfig.fieldFormat = fieldFormat;
578
- *
579
- * const index = layer.fieldConfigurations.indexOf(existingConfig);
580
- * const newConfigs = clone(layer.fieldConfigurations);
581
- * newConfigs[index] = newConfig;
582
- * layer.fieldConfigurations = newConfigs;
583
- * }
584
- * };
585
- * @example
586
- * // Deleting an existing field configuration
587
- * const deleteConfig = (layer, fieldName) => {
588
- * const existingConfig = layer.getFieldConfiguration(fieldName);
589
- * if (existingConfig) {
590
- * const index = layer.fieldConfigurations.indexOf(existingConfig);
591
- * var newConfigs = clone(layer.fieldConfigurations);
592
- * newConfigs.splice(index, 1);
593
- * layer.fieldConfigurations = newConfigs;
594
- * }
595
- * };
596
- */
597
- get fieldConfigurations(): null | undefined;
598
- set fieldConfigurations(value: FieldConfiguration[] | null | undefined);
599
491
  /**
600
492
  * An array of fields in the layer. Each field represents an attribute
601
493
  * that may contain a value for each feature in the layer. For example,
@@ -929,50 +821,6 @@ export default class OrientedImageryLayer extends __FeatureLayerSansType {
929
821
  accessor videoPathPrefix: string | null | undefined;
930
822
  /** Suffix used to build the video url path in conjunction with the image attribute. */
931
823
  accessor videoPathSuffix: string | null | undefined;
932
- /**
933
- * > [!WARNING]
934
- * >
935
- * > **Note**
936
- * >
937
- * > This method is currently not supported in OrientedImageryLayer. It is ignored and will always return `null`.
938
- *
939
- * @returns An array of field configuration objects, or `null` if
940
- * the layer does not have any fields that require formatting.
941
- * @since 4.34
942
- * @see [fieldConfigurations](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#fieldConfigurations)
943
- * @example
944
- * const fieldConfigs = featureLayer.createFieldConfigurations();
945
- * featureLayer.fieldConfigurations = fieldConfigs;
946
- */
947
- createFieldConfigurations(): FieldConfiguration[] | null | undefined;
948
- /**
949
- * > [!WARNING]
950
- * >
951
- * > **Note**
952
- * >
953
- * > This method is currently not supported in OrientedImageryLayer. It is ignored and will always return `null`.
954
- *
955
- * @param fieldName - The name of the field for which to get the alias.
956
- * @returns The field alias of the specified field.
957
- * @since 4.34
958
- * @see [fieldConfigurations](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#fieldConfigurations)
959
- * @see [getFieldConfiguration()](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#getFieldConfiguration)
960
- */
961
- getFieldAlias(fieldName: string): string | null | undefined;
962
- /**
963
- * > [!WARNING]
964
- * >
965
- * > **Note**
966
- * >
967
- * > This method is currently not supported in OrientedImageryLayer. It is ignored and will always return `null`.
968
- *
969
- * @param fieldName - The name of the field for which to get the configuration.
970
- * @returns The field configuration of the specified field.
971
- * @since 4.34
972
- * @see [fieldConfigurations](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#fieldConfigurations)
973
- * @see [getFieldAlias()](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#getFieldAlias)
974
- */
975
- getFieldConfiguration(fieldName: string): FieldConfiguration | null | undefined;
976
824
  /**
977
825
  * Executes a [Query](https://developers.arcgis.com/javascript/latest/references/core/rest/support/Query/) against the feature service and
978
826
  * returns the number of features that satisfy the query. If no parameters are specified,
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{__decorate as e}from"tslib";import t from"../core/Error.js";import{clone as i}from"../core/lang.js";import{setDeepValue as r}from"../core/object.js";import{property as o,subclass as a}from"../core/accessorSupport/decorators.js";import n from"../geometry/SpatialReference.js";import p from"../graphic/OrientedImageryGraphicOrigin.js";import s from"./FeatureLayer.js";import{useViewTimeProperty as l}from"./mixins/TemporalLayer.js";import{getEffectiveElevationSource as d,orientedImageryTypeMap as m,timeIntervalUnitTypeMap as y,verticalMeasurementTypeMap as u,isOrientationAccuracy as c,padAccuracyArray as h}from"./orientedImagery/core/utils.js";import f from"./support/Field.js";import g from"../tables/AttributeTableTemplate.js";import v from"../time/TimeExtent.js";import{writer as S}from"../core/accessorSupport/decorators/writer.js";const j=new Set(["demPathPrefix","demPathSuffix","depthImagePathPrefix","depthImagePathSuffix","elevationSource","horizontalMeasurementUnit","imageGeometryField","imageReferenceField","referenceIDField","sequenceOrderField","verticalMeasurementUnit","videoPathPrefix","videoPathSuffix","timeAnimation","visibilityTimeExtent"]),P=new Set(["elevationSource"]),I=(e,t)=>!j.has(t)&&e,O=(e,t,i)=>{const r=`orientedImageryProperties.${e}`,o={allowNull:P.has(e),ignoreOrigin:!0};return{name:r,write:t?{...o,target:r,writer:t}:o,read:i?{ignoreOrigin:!0,source:r,reader:i}:{ignoreOrigin:!0}}};function w(e){return e.json?(e.json.origins=e.json.origins??{},e.json.origins["web-scene"]={write:!1,read:!1},e):e}function b(e,t,i,r){const{name:o,write:a,read:n}=O(e,t,i),p={name:o,write:a,read:n,origins:{service:{name:`orientedImageryInfo.${o}`,write:t,read:i},"web-scene":{name:o,write:I(a,e),read:I(n,e)},"web-map":{name:o,write:a,read:n}}};return r&&p.origins?(p.type=r,p.origins["web-map"].type=r,p.origins["web-scene"].type=r,p):p}let x=class extends s{constructor(e){super(e),this.attributeTableTemplate=null,this.cameraHeading=null,this.cameraHeight=null,this.cameraPitch=null,this.cameraRoll=null,this.coveragePercent=null,this.demPathPrefix=null,this.demPathSuffix=null,this.depthImagePathPrefix=null,this.depthImagePathSuffix=null,this.elevationSource=null,this.farDistance=null,this.geometryType="point",this.graphicOrigin=new p(this),this.horizontalFieldOfView=null,this.horizontalMeasurementUnit=null,this.imageGeometryField="ImageGeometry",this.imagePathPrefix=null,this.imagePathSuffix=null,this.imageReferenceField="OIObjectID",this.imageRotation=null,this.maximumDistance=null,this.nearDistance=null,this.operationalLayerType="OrientedImageryLayer",this.orientationAccuracy=null,this.orientedImageryType=null,this.referenceIDField="OBJECTID",this.sequenceOrderField="SequenceOrder",this.subtypeField=null,this.subtypes=null,this.supportedSourceTypes=new Set(["Oriented Imagery Layer"]),this.type="oriented-imagery",this.timeIntervalUnit="days",this.useViewTime=!0,this.verticalFieldOfView=null,this.verticalMeasurementUnit=null,this.verticalSearchRange=null,this.videoPathPrefix=null,this.videoPathSuffix=null,this.virtualCacheDirectory=null,this.dataStoreID=null,this.visibilityTimeExtent=null}get effectiveElevationSource(){const{elevationSource:e,demPathPrefix:t,demPathSuffix:i}=this;return d(e,t,i)}get effectiveSequenceOrderField(){const{sequenceOrderField:e,fields:t}=this;return t.find(t=>t.name.toLowerCase()===e?.toLowerCase())?.name??"SequenceOrder"}set fieldConfigurations(e){}get fieldConfigurations(){}writePopupTemplate(e,t,i,r){e&&(t[i]=e.toJSON(r))}get portalItem(){return super.portalItem}set portalItem(e){super.portalItem=e}async save(e){return this._debouncedSaveOperations(0,e)}async saveAs(e,t){return this._debouncedSaveOperations(1,t,e)}findFirstValidLayerId(e){return e.layers?.find(({type:e})=>!!e&&this.supportedSourceTypes.has(e))?.id}_verifySource(){if(super._verifySource(),"point"!==this.geometryType)throw new t("oriented-imagery-layer:invalid-geometry-type","OrientedImageryLayer only supports point geometry type")}};e([o({type:g,json:{write:!1,read:!1}})],x.prototype,"attributeTableTemplate",void 0),e([o({type:Number,json:b("cameraHeading")})],x.prototype,"cameraHeading",void 0),e([o({type:Number,json:b("cameraHeight")})],x.prototype,"cameraHeight",void 0),e([o({type:Number,json:b("cameraPitch")})],x.prototype,"cameraPitch",void 0),e([o({type:Number,json:b("cameraRoll")})],x.prototype,"cameraRoll",void 0),e([o({type:Number,json:b("coveragePercent")})],x.prototype,"coveragePercent",void 0),e([o({type:String,json:b("demPathPrefix")})],x.prototype,"demPathPrefix",void 0),e([o({type:String,json:b("demPathSuffix")})],x.prototype,"demPathSuffix",void 0),e([o({type:String,json:b("depthImagePathPrefix")})],x.prototype,"depthImagePathPrefix",void 0),e([o({type:String,json:b("depthImagePathSuffix")})],x.prototype,"depthImagePathSuffix",void 0),e([o({type:Object,json:b("elevationSource")})],x.prototype,"elevationSource",void 0),e([o({readOnly:!0})],x.prototype,"effectiveElevationSource",null),e([o({readOnly:!0})],x.prototype,"effectiveSequenceOrderField",null),e([o({type:Number,json:b("farDistance")})],x.prototype,"farDistance",void 0),e([o({json:{write:!1}})],x.prototype,"fieldConfigurations",null),e([o({type:[f]})],x.prototype,"fields",void 0),e([o()],x.prototype,"geometryType",void 0),e([o({readOnly:!0,clonable:!1})],x.prototype,"graphicOrigin",void 0),e([o({type:Number,json:b("horizontalFieldOfView")})],x.prototype,"horizontalFieldOfView",void 0),e([o({type:String,json:b("horizontalMeasurementUnit")})],x.prototype,"horizontalMeasurementUnit",void 0),e([o({type:String,json:{...b("imageGeometryField"),default:"ImageGeometry"}})],x.prototype,"imageGeometryField",void 0),e([o({type:String,json:b("imagePathPrefix")})],x.prototype,"imagePathPrefix",void 0),e([o({type:String,json:b("imagePathSuffix")})],x.prototype,"imagePathSuffix",void 0),e([o({type:String,json:{...b("imageReferenceField"),default:"OIObjectID"}})],x.prototype,"imageReferenceField",void 0),e([o({type:Number,json:b("imageRotation")})],x.prototype,"imageRotation",void 0),e([o({type:Number,json:b("maximumDistance")})],x.prototype,"maximumDistance",void 0),e([o({type:Number,json:b("nearDistance")})],x.prototype,"nearDistance",void 0),e([o({type:["OrientedImageryLayer"],json:{origins:{"portal-item":{name:"layerType",write:{enabled:!0,ignoreOrigin:!0}}}}})],x.prototype,"operationalLayerType",void 0),e([o({json:{...b("orientationAccuracy",(e,t,i)=>{r(i,e.join(";"),t)},e=>{const t=e?.split(";")?.map(Number);return c(t)?h(t):[0,0,0,0,0,0,0,0]},String)}})],x.prototype,"orientationAccuracy",void 0),e([o({json:{...b("orientedImageryType",m.write,m.read,m.jsonValues.slice(1))}})],x.prototype,"orientedImageryType",void 0),e([S("popupTemplate")],x.prototype,"writePopupTemplate",null),e([o({type:String,json:{...b("referenceIDField"),default:"OBJECTID"}})],x.prototype,"referenceIDField",void 0),e([o({type:String,json:{...b("sequenceOrderField"),default:"SequenceOrder"}})],x.prototype,"sequenceOrderField",void 0),e([o({type:n})],x.prototype,"spatialReference",void 0),e([o({readOnly:!0})],x.prototype,"subtypeField",void 0),e([o({readOnly:!0})],x.prototype,"subtypes",void 0),e([o({json:{read:!1},value:"oriented-imagery",readOnly:!0})],x.prototype,"type",void 0),e([o({type:y.apiValues,json:{...b("timeIntervalUnit",y.write,y.read,y.jsonValues)}})],x.prototype,"timeIntervalUnit",void 0),e([o(w(i(l)))],x.prototype,"useViewTime",void 0),e([o({type:Number,json:b("verticalFieldOfView")})],x.prototype,"verticalFieldOfView",void 0),e([o({type:u.apiValues,json:{...b("verticalMeasurementUnit",u.write,u.read,u.jsonValues)}})],x.prototype,"verticalMeasurementUnit",void 0),e([o({type:Number,json:b("verticalSearchRange")})],x.prototype,"verticalSearchRange",void 0),e([o({type:String,json:b("videoPathPrefix")})],x.prototype,"videoPathPrefix",void 0),e([o({type:String,json:b("videoPathSuffix")})],x.prototype,"videoPathSuffix",void 0),e([o({type:String,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.orientedImageryProperties.virtualCacheDirectory",read:!0}}}})],x.prototype,"virtualCacheDirectory",void 0),e([o({type:String,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.dsid",read:!0}}}})],x.prototype,"dataStoreID",void 0),e([o({type:v,json:{origins:{"web-scene":{write:!1,read:!1}}}})],x.prototype,"visibilityTimeExtent",void 0),x=e([a("esri.layers.OrientedImageryLayer")],x);const F=x;export{F as default};
2
+ import{__decorate as e}from"tslib";import t from"../core/Error.js";import{clone as i}from"../core/lang.js";import{setDeepValue as r}from"../core/object.js";import{property as o,subclass as a}from"../core/accessorSupport/decorators.js";import n from"../geometry/SpatialReference.js";import s from"../graphic/OrientedImageryGraphicOrigin.js";import p from"./FeatureLayer.js";import{useViewTimeProperty as l}from"./mixins/TemporalLayer.js";import{getEffectiveElevationSource as d,orientedImageryTypeMap as m,timeIntervalUnitTypeMap as y,verticalMeasurementTypeMap as u,isOrientationAccuracy as c,padAccuracyArray as h}from"./orientedImagery/core/utils.js";import g from"./support/Field.js";import f from"../tables/AttributeTableTemplate.js";import v from"../time/TimeExtent.js";const S=new Set(["demPathPrefix","demPathSuffix","depthImagePathPrefix","depthImagePathSuffix","elevationSource","horizontalMeasurementUnit","imageGeometryField","imageReferenceField","referenceIDField","sequenceOrderField","verticalMeasurementUnit","videoPathPrefix","videoPathSuffix","timeAnimation","visibilityTimeExtent"]),j=new Set(["elevationSource"]),P=(e,t)=>!S.has(t)&&e,I=(e,t,i)=>{const r=`orientedImageryProperties.${e}`,o={allowNull:j.has(e),ignoreOrigin:!0};return{name:r,write:t?{...o,target:r,writer:t}:o,read:i?{ignoreOrigin:!0,source:r,reader:i}:{ignoreOrigin:!0}}};function O(e){return e.json?(e.json.origins=e.json.origins??{},e.json.origins["web-scene"]={write:!1,read:!1},e):e}function b(e,t,i,r){const{name:o,write:a,read:n}=I(e,t,i),s={name:o,write:a,read:n,origins:{service:{name:`orientedImageryInfo.${o}`,write:t,read:i},"web-scene":{name:o,write:P(a,e),read:P(n,e)},"web-map":{name:o,write:a,read:n}}};return r&&s.origins?(s.type=r,s.origins["web-map"].type=r,s.origins["web-scene"].type=r,s):s}let x=class extends p{constructor(e){super(e),this.attributeTableTemplate=null,this.cameraHeading=null,this.cameraHeight=null,this.cameraPitch=null,this.cameraRoll=null,this.coveragePercent=null,this.demPathPrefix=null,this.demPathSuffix=null,this.depthImagePathPrefix=null,this.depthImagePathSuffix=null,this.elevationSource=null,this.farDistance=null,this.geometryType="point",this.graphicOrigin=new s(this),this.horizontalFieldOfView=null,this.horizontalMeasurementUnit=null,this.imageGeometryField="ImageGeometry",this.imagePathPrefix=null,this.imagePathSuffix=null,this.imageReferenceField="OIObjectID",this.imageRotation=null,this.maximumDistance=null,this.nearDistance=null,this.operationalLayerType="OrientedImageryLayer",this.orientationAccuracy=null,this.orientedImageryType=null,this.referenceIDField="OBJECTID",this.sequenceOrderField="SequenceOrder",this.subtypeField=null,this.subtypes=null,this.supportedSourceTypes=new Set(["Oriented Imagery Layer"]),this.type="oriented-imagery",this.timeIntervalUnit="days",this.useViewTime=!0,this.verticalFieldOfView=null,this.verticalMeasurementUnit=null,this.verticalSearchRange=null,this.videoPathPrefix=null,this.videoPathSuffix=null,this.virtualCacheDirectory=null,this.dataStoreID=null,this.visibilityTimeExtent=null}get effectiveElevationSource(){const{elevationSource:e,demPathPrefix:t,demPathSuffix:i}=this;return d(e,t,i)}get effectiveSequenceOrderField(){const{sequenceOrderField:e,fields:t}=this;return t.find(t=>t.name.toLowerCase()===e?.toLowerCase())?.name??"SequenceOrder"}get portalItem(){return super.portalItem}set portalItem(e){super.portalItem=e}async save(e){return this._debouncedSaveOperations(0,e)}async saveAs(e,t){return this._debouncedSaveOperations(1,t,e)}findFirstValidLayerId(e){return e.layers?.find(({type:e})=>!!e&&this.supportedSourceTypes.has(e))?.id}_verifySource(){if(super._verifySource(),"point"!==this.geometryType)throw new t("oriented-imagery-layer:invalid-geometry-type","OrientedImageryLayer only supports point geometry type")}};e([o({type:f,json:{write:!1,read:!1}})],x.prototype,"attributeTableTemplate",void 0),e([o({type:Number,json:b("cameraHeading")})],x.prototype,"cameraHeading",void 0),e([o({type:Number,json:b("cameraHeight")})],x.prototype,"cameraHeight",void 0),e([o({type:Number,json:b("cameraPitch")})],x.prototype,"cameraPitch",void 0),e([o({type:Number,json:b("cameraRoll")})],x.prototype,"cameraRoll",void 0),e([o({type:Number,json:b("coveragePercent")})],x.prototype,"coveragePercent",void 0),e([o({type:String,json:b("demPathPrefix")})],x.prototype,"demPathPrefix",void 0),e([o({type:String,json:b("demPathSuffix")})],x.prototype,"demPathSuffix",void 0),e([o({type:String,json:b("depthImagePathPrefix")})],x.prototype,"depthImagePathPrefix",void 0),e([o({type:String,json:b("depthImagePathSuffix")})],x.prototype,"depthImagePathSuffix",void 0),e([o({type:Object,json:b("elevationSource")})],x.prototype,"elevationSource",void 0),e([o({readOnly:!0})],x.prototype,"effectiveElevationSource",null),e([o({readOnly:!0})],x.prototype,"effectiveSequenceOrderField",null),e([o({type:Number,json:b("farDistance")})],x.prototype,"farDistance",void 0),e([o({type:[g]})],x.prototype,"fields",void 0),e([o()],x.prototype,"geometryType",void 0),e([o({readOnly:!0,clonable:!1})],x.prototype,"graphicOrigin",void 0),e([o({type:Number,json:b("horizontalFieldOfView")})],x.prototype,"horizontalFieldOfView",void 0),e([o({type:String,json:b("horizontalMeasurementUnit")})],x.prototype,"horizontalMeasurementUnit",void 0),e([o({type:String,json:{...b("imageGeometryField"),default:"ImageGeometry"}})],x.prototype,"imageGeometryField",void 0),e([o({type:String,json:b("imagePathPrefix")})],x.prototype,"imagePathPrefix",void 0),e([o({type:String,json:b("imagePathSuffix")})],x.prototype,"imagePathSuffix",void 0),e([o({type:String,json:{...b("imageReferenceField"),default:"OIObjectID"}})],x.prototype,"imageReferenceField",void 0),e([o({type:Number,json:b("imageRotation")})],x.prototype,"imageRotation",void 0),e([o({type:Number,json:b("maximumDistance")})],x.prototype,"maximumDistance",void 0),e([o({type:Number,json:b("nearDistance")})],x.prototype,"nearDistance",void 0),e([o({type:["OrientedImageryLayer"],json:{origins:{"portal-item":{name:"layerType",write:{enabled:!0,ignoreOrigin:!0}}}}})],x.prototype,"operationalLayerType",void 0),e([o({json:{...b("orientationAccuracy",(e,t,i)=>{r(i,e.join(";"),t)},e=>{const t=e?.split(";")?.map(Number);return c(t)?h(t):[0,0,0,0,0,0,0,0]},String)}})],x.prototype,"orientationAccuracy",void 0),e([o({json:{...b("orientedImageryType",m.write,m.read,m.jsonValues.slice(1))}})],x.prototype,"orientedImageryType",void 0),e([o({type:String,json:{...b("referenceIDField"),default:"OBJECTID"}})],x.prototype,"referenceIDField",void 0),e([o({type:String,json:{...b("sequenceOrderField"),default:"SequenceOrder"}})],x.prototype,"sequenceOrderField",void 0),e([o({type:n})],x.prototype,"spatialReference",void 0),e([o({readOnly:!0})],x.prototype,"subtypeField",void 0),e([o({readOnly:!0})],x.prototype,"subtypes",void 0),e([o({json:{read:!1},value:"oriented-imagery",readOnly:!0})],x.prototype,"type",void 0),e([o({type:y.apiValues,json:{...b("timeIntervalUnit",y.write,y.read,y.jsonValues)}})],x.prototype,"timeIntervalUnit",void 0),e([o(O(i(l)))],x.prototype,"useViewTime",void 0),e([o({type:Number,json:b("verticalFieldOfView")})],x.prototype,"verticalFieldOfView",void 0),e([o({type:u.apiValues,json:{...b("verticalMeasurementUnit",u.write,u.read,u.jsonValues)}})],x.prototype,"verticalMeasurementUnit",void 0),e([o({type:Number,json:b("verticalSearchRange")})],x.prototype,"verticalSearchRange",void 0),e([o({type:String,json:b("videoPathPrefix")})],x.prototype,"videoPathPrefix",void 0),e([o({type:String,json:b("videoPathSuffix")})],x.prototype,"videoPathSuffix",void 0),e([o({type:String,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.orientedImageryProperties.virtualCacheDirectory",read:!0}}}})],x.prototype,"virtualCacheDirectory",void 0),e([o({type:String,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.dsid",read:!0}}}})],x.prototype,"dataStoreID",void 0),e([o({type:v,json:{origins:{"web-scene":{write:!1,read:!1}}}})],x.prototype,"visibilityTimeExtent",void 0),x=e([a("esri.layers.OrientedImageryLayer")],x);const w=x;export{w as default};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{id as e}from"../../kernel.js";import t from"../../request.js";import n from"../../core/Collection.js";import"../../core/urlUtils.js";import{isLayerFromCatalog as r}from"../catalog/catalogUtils.js";import{isBasemap as i}from"../../support/userTypeGuards/isBasemap.js";function u(e,t){return null!=e&&"object"==typeof e&&"type"in e&&e.type===t}function s(e){return h(e)||d(e)}function o(e){return u(e,"feature")}function c(e){return"gaussian-splat"===e?.type}function a(e){return u(e,"graphics")}function l(e){return u(e,"map-image")}function f(e){return u(e,"map-notes")&&"sublayers"in e}function p(e){return u(e,"knowledge-graph")&&"layers"in e}function y(e){return u(e,"knowledge-graph-sublayer")}function g(e){return u(e,"link-chart")&&"layers"in e}function d(e){return u(e,"scene")}function b(e){return u(e,"subtype-group")&&"sublayers"in e}function m(e){return"subtype-sublayer"===e?.type}function h(e){const t=e?.type;return"imagery-tile"===t||"tile"===t||"open-street-map"===t||"vector-tile"===t||"web-tile"===t||"wmts"===t}function v(e){const t=e?.type;return"base-tile"===t||"tile"===t||"elevation"===t||"imagery-tile"===t||"base-elevation"===t||"open-street-map"===t||"wcs"===t||"web-tile"===t||"wmts"===t||"vector-tile"===t}function w(e){return"group"===e?.type}function j(e){const t=e.parent;return w(t)&&t.tables.includes(e)}const L={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};function S(e){const t=e?.type;return"building-scene"===t||"integrated-mesh"===t||"point-cloud"===t||"scene"===t}function E(e){return"integrated-mesh"===e.type||"integrated-mesh-3dtiles"===e.type}function k(e){return"integrated-mesh-3dtiles"===e.type}function C(e){return"voxel"===e?.type}function x(e){return"imagery-tile"===e?.type}function T(e,t){return i(e?.parent)&&e.parent[t].includes(e)}function U(e){return T(e,"baseLayers")}function M(e){return T(e,"referenceLayers")}function O(e){return"feature"===e?.type&&!e.url&&"memory"===e.source?.type}function P(e){const t=e?.type;return("feature"===t||"subtype-group"===t||"oriented-imagery"===t)&&"feature-layer"===e?.source?.type}function B(e){return"feature"===e?.type&&"feature-layer"===e.source?.type}function I(e){return o(e)&&B(e)}function R(e){const t=e?.type;return"binning"===t||"cluster"===t}function q(e,t){if(!I(e))return;const n=t?.graphic,r=e.featureReduction;if(n){if(n.isAggregate){const e=n.origin;return e&&("featureReductionProvider"in e&&r)?R(r)?r:null:void 0}return e}return t?.checkFeatureReduction&&r?R(r)?r:null:e}function F(e){const t=/[:;]/,n=[];let r=!1;if(e&&(e.forEach((e,i)=>{n.push([i,e]),!r&&t.test(e)&&(r=!0)}),n.length>0)){let e;if(r){const t={};n.forEach(e=>{t[e[0]]=e[1]}),e=JSON.stringify(t)}else{const t=[];n.forEach(e=>{t.push(e[0]+":"+e[1])}),e=t.join(";")}return e}return null}function J(e){if(!e)return;const t=[];return e.forEach((e,n)=>{t.push('"'+n+'":'+JSON.stringify(e))}),t.length?"{"+t.join(",")+"}":void 0}function N(e){if(e.activeLayer){const t=e.activeLayer.tileMatrixSet;if(t)return t;const n=e.activeLayer.tileMatrixSets;if(n)return n}return null}async function A(n,r){const i=e?.findServerInfo(n);if(null!=i?.currentVersion)return i.owningSystemUrl||null;const u=n.toLowerCase().indexOf("/rest/services");if(-1===u)return null;const s=`${n.slice(0,u)}/rest/info`,o=null!=r?r.signal:null,{data:c}=await t(s,{query:{f:"json"},responseType:"json",signal:o});return c?.owningSystemUrl||null}function D(e){if(!("capabilities"in e))return!1;switch(e.type){case"catalog":case"catalog-footprint":case"csv":case"feature":case"geojson":case"imagery":case"knowledge-graph-sublayer":case"ogc-feature":case"oriented-imagery":case"scene":case"sublayer":case"subtype-group":case"subtype-sublayer":case"wfs":return!0;default:return!1}}function G(e){return null!=e&&"object"==typeof e&&"isTable"in e&&!!e.isTable}function V(e){return D(e)?"effectiveCapabilities"in e?e.effectiveCapabilities:e.capabilities:null}function $(e){if(!("editingEnabled"in e))return!1;switch(e.type){case"csv":case"feature":case"geojson":case"oriented-imagery":case"scene":case"subtype-group":case"subtype-sublayer":case"knowledge-graph-sublayer":return!0;default:return!1}}function z(e){return!!$(e)&&("effectiveEditingEnabled"in e?e.effectiveEditingEnabled:e.editingEnabled)}function H(e){if(!e)return[];return("subtypes"in e?e.subtypes:b(e.parent)?e.parent.subtypes:[])??[]}function K(e){return("imagery"===e.type||"imagery-tile"===e.type)&&"flow"===e.renderer?.type}function Q(e){const t=new n;for(const n of e.allLayers.concat(e.allTables))r(n)||j(n)||("charts"in n&&t.push(n),"subtype-group"===n.type&&t.push(...n.sublayers));return t}function W(e,t){return null}function X(e){return null}function Y(e){return!e||"Feature Service"===e.type&&!e.sourceUrl}function Z(e,t){if(!t||!Y(e))return;const n=W(e.url);n&&(e.url=n)}export{Z as applyPreferredHostToPortalItem,z as getEffectiveEditingEnabled,V as getEffectiveLayerCapabilities,q as getFieldConfigurationsContainer,Q as getLayersWithChartSupport,A as getOwningPortalUrl,X as getPreferredHost,W as getPreferredUrl,H as getSubtypesFromLayer,N as getTileMaxtrixSetFromActiveLayer,U as isBaseLayer,s as isBasemap3DSupportedLayer,h as isBasemapSupportedTiledLayer,O as isFeatureCollectionLayer,o as isFeatureLayer,B as isFeatureServiceLayer,c as isGaussianSplatLayer,a as isGraphicsLayer,w as isGroupLayer,x as isImageryTileLayer,k as isIntegratedMesh3DTilesLayer,E as isIntegratedMeshLayer,p as isKnowledgeGraphLayer,y as isKnowledgeGraphSublayer,D as isLayerWithFeatureCapabilities,P as isLayerWithFeatureLayerSource,K as isLayerWithFlowRenderer,g as isLinkChartLayer,l as isMapImageLayer,f as isMapNotesLayer,Y as isPreferredUrlApplicable,M as isReferenceLayer,d as isSceneLayer,S as isSceneServiceLayer,b as isSubtypeGroupLayer,m as isSubtypeSublayer,G as isTable,v as isTiledLayer,C as isVoxelLayer,L as sceneServiceLayerTypeToClassName,F as serializeLayerDefinitions,J as serializeTimeOptions,I as supportsFieldConfiguration};
2
+ import{id as e}from"../../kernel.js";import t from"../../request.js";import n from"../../core/Collection.js";import"../../core/urlUtils.js";import{isLayerFromCatalog as r}from"../catalog/catalogUtils.js";import{isBasemap as i}from"../../support/userTypeGuards/isBasemap.js";function u(e,t){return null!=e&&"object"==typeof e&&"type"in e&&e.type===t}function s(e){return v(e)||b(e)}function o(e){return u(e,"feature")}function c(e){return"gaussian-splat"===e?.type}function a(e){return null!=e&&"object"==typeof e&&"type"in e&&"oriented-imagery"===e.type}function l(e){return u(e,"graphics")}function f(e){return u(e,"map-image")}function p(e){return u(e,"map-notes")&&"sublayers"in e}function y(e){return u(e,"knowledge-graph")&&"layers"in e}function g(e){return u(e,"knowledge-graph-sublayer")}function d(e){return u(e,"link-chart")&&"layers"in e}function b(e){return u(e,"scene")}function m(e){return u(e,"subtype-group")&&"sublayers"in e}function h(e){return"subtype-sublayer"===e?.type}function v(e){const t=e?.type;return"imagery-tile"===t||"tile"===t||"open-street-map"===t||"vector-tile"===t||"web-tile"===t||"wmts"===t}function w(e){const t=e?.type;return"base-tile"===t||"tile"===t||"elevation"===t||"imagery-tile"===t||"base-elevation"===t||"open-street-map"===t||"wcs"===t||"web-tile"===t||"wmts"===t||"vector-tile"===t}function j(e){return"group"===e?.type}function L(e){const t=e.parent;return j(t)&&t.tables.includes(e)}const S={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};function E(e){const t=e?.type;return"building-scene"===t||"integrated-mesh"===t||"point-cloud"===t||"scene"===t}function k(e){return"integrated-mesh"===e.type||"integrated-mesh-3dtiles"===e.type}function C(e){return"integrated-mesh-3dtiles"===e.type}function x(e){return"voxel"===e?.type}function T(e){return"imagery-tile"===e?.type}function U(e,t){return i(e?.parent)&&e.parent[t].includes(e)}function M(e){return U(e,"baseLayers")}function O(e){return U(e,"referenceLayers")}function P(e){return"feature"===e?.type&&!e.url&&"memory"===e.source?.type}function B(e){const t=e?.type;return("feature"===t||"subtype-group"===t||"oriented-imagery"===t)&&"feature-layer"===e?.source?.type}function I(e){return"feature"===e?.type&&"feature-layer"===e.source?.type}function R(e){return a(e)||o(e)&&I(e)}function q(e){const t=e?.type;return"binning"===t||"cluster"===t}function F(e,t){if(!R(e))return;const n=t?.graphic,r=e.featureReduction;if(n){if(n.isAggregate){const e=n.origin;return e&&("featureReductionProvider"in e&&r)?q(r)?r:null:void 0}return e}return t?.checkFeatureReduction&&r?q(r)?r:null:e}function J(e){const t=/[:;]/,n=[];let r=!1;if(e&&(e.forEach((e,i)=>{n.push([i,e]),!r&&t.test(e)&&(r=!0)}),n.length>0)){let e;if(r){const t={};n.forEach(e=>{t[e[0]]=e[1]}),e=JSON.stringify(t)}else{const t=[];n.forEach(e=>{t.push(e[0]+":"+e[1])}),e=t.join(";")}return e}return null}function N(e){if(!e)return;const t=[];return e.forEach((e,n)=>{t.push('"'+n+'":'+JSON.stringify(e))}),t.length?"{"+t.join(",")+"}":void 0}function A(e){if(e.activeLayer){const t=e.activeLayer.tileMatrixSet;if(t)return t;const n=e.activeLayer.tileMatrixSets;if(n)return n}return null}async function D(n,r){const i=e?.findServerInfo(n);if(null!=i?.currentVersion)return i.owningSystemUrl||null;const u=n.toLowerCase().indexOf("/rest/services");if(-1===u)return null;const s=`${n.slice(0,u)}/rest/info`,o=null!=r?r.signal:null,{data:c}=await t(s,{query:{f:"json"},responseType:"json",signal:o});return c?.owningSystemUrl||null}function G(e){if(!("capabilities"in e))return!1;switch(e.type){case"catalog":case"catalog-footprint":case"csv":case"feature":case"geojson":case"imagery":case"knowledge-graph-sublayer":case"ogc-feature":case"oriented-imagery":case"scene":case"sublayer":case"subtype-group":case"subtype-sublayer":case"wfs":return!0;default:return!1}}function V(e){return null!=e&&"object"==typeof e&&"isTable"in e&&!!e.isTable}function $(e){return G(e)?"effectiveCapabilities"in e?e.effectiveCapabilities:e.capabilities:null}function z(e){if(!("editingEnabled"in e))return!1;switch(e.type){case"csv":case"feature":case"geojson":case"oriented-imagery":case"scene":case"subtype-group":case"subtype-sublayer":case"knowledge-graph-sublayer":return!0;default:return!1}}function H(e){return!!z(e)&&("effectiveEditingEnabled"in e?e.effectiveEditingEnabled:e.editingEnabled)}function K(e){if(!e)return[];return("subtypes"in e?e.subtypes:m(e.parent)?e.parent.subtypes:[])??[]}function Q(e){return("imagery"===e.type||"imagery-tile"===e.type)&&"flow"===e.renderer?.type}function W(e){const t=new n;for(const n of e.allLayers.concat(e.allTables))r(n)||L(n)||("charts"in n&&t.push(n),"subtype-group"===n.type&&t.push(...n.sublayers));return t}function X(e,t){return null}function Y(e){return null}function Z(e){return!e||"Feature Service"===e.type&&!e.sourceUrl}function _(e,t){if(!t||!Z(e))return;const n=X(e.url);n&&(e.url=n)}export{_ as applyPreferredHostToPortalItem,H as getEffectiveEditingEnabled,$ as getEffectiveLayerCapabilities,F as getFieldConfigurationsContainer,W as getLayersWithChartSupport,D as getOwningPortalUrl,Y as getPreferredHost,X as getPreferredUrl,K as getSubtypesFromLayer,A as getTileMaxtrixSetFromActiveLayer,M as isBaseLayer,s as isBasemap3DSupportedLayer,v as isBasemapSupportedTiledLayer,P as isFeatureCollectionLayer,o as isFeatureLayer,I as isFeatureServiceLayer,c as isGaussianSplatLayer,l as isGraphicsLayer,j as isGroupLayer,T as isImageryTileLayer,C as isIntegratedMesh3DTilesLayer,k as isIntegratedMeshLayer,y as isKnowledgeGraphLayer,g as isKnowledgeGraphSublayer,G as isLayerWithFeatureCapabilities,B as isLayerWithFeatureLayerSource,Q as isLayerWithFlowRenderer,d as isLinkChartLayer,f as isMapImageLayer,p as isMapNotesLayer,Z as isPreferredUrlApplicable,O as isReferenceLayer,b as isSceneLayer,E as isSceneServiceLayer,m as isSubtypeGroupLayer,h as isSubtypeSublayer,V as isTable,w as isTiledLayer,x as isVoxelLayer,S as sceneServiceLayerTypeToClassName,J as serializeLayerDefinitions,N as serializeTimeOptions,R as supportsFieldConfiguration};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcgis/core",
3
- "version": "5.1.0-next.53",
3
+ "version": "5.1.0-next.55",
4
4
  "homepage": "https://js.arcgis.com",
5
5
  "description": "ArcGIS Maps SDK for JavaScript: A complete 2D and 3D mapping and data visualization API",
6
6
  "keywords": [