@arcgis/core 4.32.0-next.20250105 → 4.32.0-next.20250107
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.
- package/AttributeBinsGraphic.js +5 -0
- package/README.md +1 -1
- package/applications/MapViewer/templateUtils.js +1 -1
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/000771f8eefcd6af0fda.js +1 -0
- package/assets/esri/core/workers/chunks/{9372d08ba8bf3342c48f.js → 011ccfd3acee83e7dc68.js} +1 -1
- package/assets/esri/core/workers/chunks/03af4a51043677ffcd0f.js +1 -0
- package/assets/esri/core/workers/chunks/{d07da8b63d83af179a2c.js → 05943caacfd28c383810.js} +1 -1
- package/assets/esri/core/workers/chunks/{9f495ad57cdbfa90c5b8.js → 095aeb19e2207c8361ca.js} +1 -1
- package/assets/esri/core/workers/chunks/{67c7bdc0c91a8f803ea8.js → 11cb25dfab7c8467897a.js} +1 -1
- package/assets/esri/core/workers/chunks/{42aa697b4718b75b8cb2.js → 1abeba63bf623a746d5c.js} +2 -2
- package/assets/esri/core/workers/chunks/{42aa697b4718b75b8cb2.js.LICENSE.txt → 1abeba63bf623a746d5c.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/{a57cead317eb2fc9afd8.js → 206194cf069ad4bcc3ad.js} +1 -1
- package/assets/esri/core/workers/chunks/{0673d811c496143fc3d4.js → 2779cf112299b612a73a.js} +1 -1
- package/assets/esri/core/workers/chunks/{bd37c9cc720587665fd3.js → 304b88ade7551130ad3a.js} +1 -1
- package/assets/esri/core/workers/chunks/{aedff36d3fec86abb9fb.js → 30a84ddf0384bb52fdbe.js} +1 -1
- package/assets/esri/core/workers/chunks/{367af4aa7e170c8553e3.js → 33a13544b9e5f4f20bce.js} +1 -1
- package/assets/esri/core/workers/chunks/{dce55e7f76adecc055c3.js → 35d9457109d0631a1ca8.js} +1 -1
- package/assets/esri/core/workers/chunks/{00c0fbe19c12691cf2c3.js → 368a36be515e60e35154.js} +1 -1
- package/assets/esri/core/workers/chunks/{3a90163b76b0bc7f21d2.js → 3767defbd9c4b2e86886.js} +1 -1
- package/assets/esri/core/workers/chunks/3a3e9701e5d7b05f41b7.js +1 -0
- package/assets/esri/core/workers/chunks/{9a498f2c007f4d78d4dd.js → 4234539a9721104acafb.js} +1 -1
- package/assets/esri/core/workers/chunks/{76fa5c7c87831ad25cde.js → 435c037ccba71f1e22d3.js} +1 -1
- package/assets/esri/core/workers/chunks/4387c47ae1b36d770f1d.js +1 -0
- package/assets/esri/core/workers/chunks/{88c68881cbdf4e911832.js → 4423aac6e44c3dbf184e.js} +1 -1
- package/assets/esri/core/workers/chunks/44ec3c77339b9765aaa4.js +1 -0
- package/assets/esri/core/workers/chunks/4b77c8d994498899631a.js +1 -0
- package/assets/esri/core/workers/chunks/62f8949a2d9076f3c1ea.js +2 -0
- package/assets/esri/core/workers/chunks/{c8cd6ba5600d8ff8db0b.js.LICENSE.txt → 62f8949a2d9076f3c1ea.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/{664aa401887b59abd7b7.js → 6400f39a965900f66ce7.js} +1 -1
- package/assets/esri/core/workers/chunks/{ddce265c46e4dfeb6c6d.js → 66d40a486aa3caa76106.js} +1 -1
- package/assets/esri/core/workers/chunks/6b3ee691646fbc39445c.js +1 -0
- package/assets/esri/core/workers/chunks/{533a7fd64b17bb294545.js → 6c58f792e2ae3736f662.js} +1 -1
- package/assets/esri/core/workers/chunks/{370b230fd2d7703d0698.js → 6efb36bc2205203ff44d.js} +2 -2
- package/assets/esri/core/workers/chunks/{370b230fd2d7703d0698.js.LICENSE.txt → 6efb36bc2205203ff44d.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/{a90611cdc86190799560.js → 7a43fda8984549a084b8.js} +1 -1
- package/assets/esri/core/workers/chunks/7b753da3b8a6d75abf20.js +1 -0
- package/assets/esri/core/workers/chunks/{9b020c47ca9ff5de9bb8.js → 7db356976198c4df76c1.js} +1 -1
- package/assets/esri/core/workers/chunks/{4c56698cf1c669371865.js → 81816410cb1453938593.js} +1 -1
- package/assets/esri/core/workers/chunks/{4ffaa2c5ab47a599ee9f.js → 82266ca8002554198208.js} +1 -1
- package/assets/esri/core/workers/chunks/{f19d3c855f6e93544918.js → 8be0151a24c9af76a976.js} +1 -1
- package/assets/esri/core/workers/chunks/{d9e396adf3354ee68339.js → 8f2b2d2dc9935b0d2039.js} +1 -1
- package/assets/esri/core/workers/chunks/907a91266e25cc4b9d42.js +1 -0
- package/assets/esri/core/workers/chunks/{a77aa86896bbb0e088df.js → 9857491cafa0278d9ae6.js} +1 -1
- package/assets/esri/core/workers/chunks/{993db7646a8fc60179eb.js → 98da074899c82f0ded0b.js} +1 -1
- package/assets/esri/core/workers/chunks/{3bb94da29dac3367ecc6.js → a1edd3f68e691ea39594.js} +1 -1
- package/assets/esri/core/workers/chunks/b07710e01494a6cda097.js +1 -0
- package/assets/esri/core/workers/chunks/{6a4305eb1e52b80ecb5c.js → b8ea84adff5619040494.js} +3 -3
- package/assets/esri/core/workers/chunks/{005727711cca0614c2ab.js → c05e0bd145a1c27d6857.js} +2 -2
- package/assets/esri/core/workers/chunks/{005727711cca0614c2ab.js.LICENSE.txt → c05e0bd145a1c27d6857.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/c4374b6bc5c8dc6435c7.js +1 -0
- package/assets/esri/core/workers/chunks/c49707b577f3805f0142.js +1 -0
- package/assets/esri/core/workers/chunks/c5a928dcff7dc8a8cc9f.js +2 -0
- package/assets/esri/core/workers/chunks/{f4e3db71d1adae717535.js.LICENSE.txt → c5a928dcff7dc8a8cc9f.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/cac79b64a7dade8bf486.js +2 -0
- package/assets/esri/core/workers/chunks/{bf0a0ca7fdac98f06a89.js.LICENSE.txt → cac79b64a7dade8bf486.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/{2cccaf50134c65944e0a.js → d0876eed5249b029f9f0.js} +1 -1
- package/assets/esri/core/workers/chunks/{178f606c8896ae5f39de.js → d1dbbab4a4c6072c182f.js} +1 -1
- package/assets/esri/core/workers/chunks/{8e42fb623f56942958d8.js → d74b5dc60f02892d03e7.js} +1 -1
- package/assets/esri/core/workers/chunks/{9ad7d095e614e7e8d7f5.js → dca0eb66116e4b5403fc.js} +1 -1
- package/assets/esri/core/workers/chunks/e27b8674a3492db51f2e.js +1 -0
- package/assets/esri/core/workers/chunks/{756c2f7c8659deab6c96.js → e2d987c39a6ef318511c.js} +2 -2
- package/assets/esri/core/workers/chunks/{756c2f7c8659deab6c96.js.LICENSE.txt → e2d987c39a6ef318511c.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/{943428cf643e87ccfaad.js → e7e26b71f9eb28421936.js} +1 -1
- package/assets/esri/core/workers/chunks/{f0adabf6d71a27f3183b.js → e80b0646a7e0e466ea65.js} +1 -1
- package/assets/esri/core/workers/chunks/e9c21907fabcedbd32ae.js +1 -0
- package/assets/esri/core/workers/chunks/{f9af0473878d960a02f2.js → f6d6bc43ac1c13892d44.js} +1 -1
- package/assets/esri/core/workers/chunks/{3ed7c8138231de3a3b96.js → f8c960df1dabab120c70.js} +1 -1
- package/assets/esri/core/workers/chunks/{fdd8a5eb07466541f1f9.js → fd95b19f02d8dfef2baf.js} +1 -1
- package/assets/esri/widgets/support/GridControls/t9n/GridControls_ja.json +1 -1
- package/chunks/bufferOperator.js +1 -1
- package/chunks/geodesicBufferOperator.js +1 -1
- package/chunks/terrainUtilsPlanar.js +1 -1
- package/chunks/terrainUtilsSpherical.js +1 -1
- package/core/MemCachePool.js +1 -1
- package/geometry/operators/graphicBufferOperator.js +1 -1
- package/geometry/support/meshVertexSpaceUtils.js +1 -1
- package/interfaces.d.ts +101 -5
- package/layers/graphics/data/QueryEngineResult.js +1 -1
- package/layers/graphics/data/queryUtils.js +1 -1
- package/layers/graphics/data/queryValidationUtils.js +1 -1
- package/layers/graphics/sources/WFSSource.js +1 -1
- package/layers/support/capabilities.js +1 -1
- package/layers/support/featureLayerUtils.js +1 -1
- package/layers/support/serviceCapabilitiesUtils.js +1 -1
- package/package.json +2 -2
- package/renderers/RasterStretchRenderer.js +1 -1
- package/rest/query/executeAttributeBinsQuery.js +1 -1
- package/rest/support/AttributeBinsFeatureSet.js +5 -0
- package/rest/support/AttributeBinsQuery.js +1 -1
- package/rest/support/BinParametersAttributes.js +1 -1
- package/rest/support/BinParametersBase.js +1 -1
- package/rest/support/DateBinParameters.js +1 -1
- package/rest/support/FeatureSet.js +1 -1
- package/rest/support/NormalizationBinParametersMixin.js +1 -1
- package/rest/support/Query.js +1 -1
- package/rest/support/TopFeaturesQuery.js +1 -1
- package/smartMapping/renderers/dotDensity.js +1 -1
- package/smartMapping/renderers/pieChart.js +1 -1
- package/smartMapping/statistics/summaryStatisticsForAttributes.js +1 -1
- package/support/revision.js +1 -1
- package/symbols/cim/CIMSymbolDrawHelper.js +1 -1
- package/symbols/cim/cimAnalyzer.js +1 -1
- package/views/2d/engine/Bitmap.js +1 -1
- package/views/2d/engine/BitmapContainer.js +1 -1
- package/views/2d/engine/BitmapTileContainer.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/bitmap/BitmapTechnique.js +1 -1
- package/views/2d/input/MapViewInputManager.js +1 -1
- package/views/2d/input/handlers/DragPan.js +1 -1
- package/views/2d/input/handlers/DragRotate.js +1 -1
- package/views/2d/input/handlers/MouseWheelZoom.js +1 -1
- package/views/2d/layers/FeatureLayerView2D.js +1 -1
- package/views/3d/analysis/Dimension/lengthDimensionUtils.js +1 -1
- package/views/3d/analysis/LineOfSight/LineOfSightRayIntersector.js +1 -1
- package/views/3d/analysis/Viewshed/ViewshedSubTool.js +1 -1
- package/views/3d/input/SceneInputManager.js +1 -1
- package/views/3d/input/handlers/DragRotate.js +1 -1
- package/views/3d/input/handlers/DragZoom.js +1 -1
- package/views/3d/input/handlers/MouseWheelZoom.js +1 -1
- package/views/3d/input/handlers/PinchAndPanNavigation.js +1 -1
- package/views/3d/layerViewModuleImportUtils.js +1 -1
- package/views/3d/layers/GroupLayerView3D.js +5 -0
- package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
- package/views/3d/state/NearFarHeuristic.js +1 -1
- package/views/3d/terrain/OverlayManager.js +1 -1
- package/views/3d/terrain/TerrainRenderer.js +1 -1
- package/views/3d/terrain/TerrainSurface.js +1 -1
- package/views/3d/terrain/terrainUtilsPlanar.js +1 -1
- package/views/3d/terrain/terrainUtilsSpherical.js +1 -1
- package/views/3d/webgl-engine/collections/Component/SourceGeometry.js +1 -1
- package/views/3d/webgl-engine/lib/Intersector.js +1 -1
- package/views/3d/webgl-engine/lib/depthRangeUtils.js +1 -1
- package/views/3d/webgl-engine/shaders/OutputColorHighlightOID.glsl.js +4 -4
- package/views/View2D.js +1 -1
- package/views/draw/support/HighlightHelper.js +1 -1
- package/views/input/handlers/support.js +1 -1
- package/views/layers/DimensionLayerView.js +1 -1
- package/views/navigation/Navigation.js +1 -1
- package/views/navigation/NavigationActionMap.d.ts +4 -0
- package/views/navigation/NavigationActionMap.js +5 -0
- package/views/webgl/Texture.js +1 -1
- package/views/webgl/textureUtils.js +5 -0
- package/widgets/Editor/UpdateRecordWorkflow.js +1 -1
- package/widgets/Editor/UpdateWorkflow.js +1 -1
- package/widgets/ElevationProfile/ElevationProfileLineView.js +1 -1
- package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
- package/widgets/FeatureTable/Grid/Grid.js +1 -1
- package/widgets/FeatureTable/support/tableUtils.js +1 -1
- package/widgets/NavigationToggle/NavigationToggleViewModel.js +1 -1
- package/widgets/support/ColorPicker.js +1 -1
- package/assets/esri/core/workers/chunks/0a3bf1b74cce1b6b7ed8.js +0 -1
- package/assets/esri/core/workers/chunks/0d2411a941c42acb8cc2.js +0 -1
- package/assets/esri/core/workers/chunks/13720b1d97fb7d80e972.js +0 -1
- package/assets/esri/core/workers/chunks/14b87f3dd9942e6b19d0.js +0 -1
- package/assets/esri/core/workers/chunks/16530347bd78dc6c2fcd.js +0 -1
- package/assets/esri/core/workers/chunks/1a713cc601c6fcd97d2f.js +0 -1
- package/assets/esri/core/workers/chunks/3029354194f1a3030c5c.js +0 -1
- package/assets/esri/core/workers/chunks/318a39b56851e707edad.js +0 -1
- package/assets/esri/core/workers/chunks/53cd990b2c988518de6d.js +0 -1
- package/assets/esri/core/workers/chunks/5a0eb9dfe668cf290462.js +0 -1
- package/assets/esri/core/workers/chunks/9f0ebeae8a3ba360284b.js +0 -1
- package/assets/esri/core/workers/chunks/a3cef3837f4df9ab022e.js +0 -1
- package/assets/esri/core/workers/chunks/bf0a0ca7fdac98f06a89.js +0 -2
- package/assets/esri/core/workers/chunks/c8cd6ba5600d8ff8db0b.js +0 -2
- package/assets/esri/core/workers/chunks/ea250d66089967976c05.js +0 -1
- package/assets/esri/core/workers/chunks/ecf317c6c790b3cc83bf.js +0 -1
- package/assets/esri/core/workers/chunks/f4e3db71d1adae717535.js +0 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2083],{67996:(e,t,r)=>{r.d(t,{cZ:()=>D,XW:()=>j,fe:()=>O});var n,s,i=r(78888),o=r(49186),a=r(91869),l=(r(90708),r(92722)),u=(r(59456),r(16930));class d{constructor(){this.version="",this.queryResult=new p}}class p{constructor(){this.featureResult=new c}}class c{constructor(){this.objectIdFieldName="",this.uniqueIdField=new h,this.globalIdFieldName="",this.geohashFieldName="",this.geometryProperties=new y,this.geometryType=null,this.spatialReference=new u.A,this.exceededTransferLimit=!1,this.hasZ=!1,this.hasM=!1,this.transform=new m,this.fields=[],this.fieldNameToAttributeIndexMap={},this.values=[],this.features=[],this.geometryFields=[]}}class h{constructor(){this.name="",this.isSystemMaintained=!1}}class y{constructor(){this.shapeAreaFieldName="",this.shapeLengthFieldName="",this.units=""}}class m{constructor(){this.quantizeOriginPosition="upperLeft",this.scale=new f,this.translate=new g}}class f{constructor(){this.xScale=0,this.yScale=0,this.mScale=0,this.zScale=0}}class g{constructor(){this.xTranslate=0,this.yTranslate=0,this.mTranslate=0,this.zTranslate=0}}class _{constructor(){this.name="",this.fieldType="esriFieldTypeString",this.alias="",this.sqlType="sqlTypeVarchar",this.domain="",this.defaultValue=""}}class b{constructor(){this.attributes=[],this.compressedGeometry=new w,this.centroid=new w,this.aggregateGeometries=[]}}class w{constructor(){this.geometryType=null,this.lengths=[],this.coords=[]}}(s=n||(n={})).ELEMENTUID="ELEMENTUID",s.TYPENAME="TYPENAME";const v=[n.ELEMENTUID,n.TYPENAME];var T,I;!function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME"}(T||(T={})),function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME",e[e.FROMUID=2]="FROMUID",e[e.TOUID=3]="TOUID"}(I||(I={}));var E,M,A,x,S=r(45724),N=r(35448);function k(e){const t=new w;t.geometryType=N.bV[e.geometry_type.value];const r=[],n=[];for(let t=0;t<e.lengths.length;t++)r.push(e.lengths[t]);for(let t=0;t<e.coords.length;t++)n.push(e.coords[t]);return t.lengths=r,t.coords=n,t}function L(e){const t=new _;return t.name=e.name,t.alias=e.alias,t.fieldType=N.r5[e.field_type.value],t.sqlType=A[e.sql_type.value],t.domain=e.domain,t.defaultValue=e.default_value,t}function C(e){const t=L(e);return t.geometryType=N.bV[e.geometry_type.value],t}function R(e){const t=new m;t.quantizeOriginPosition=M[e.quantizeOriginPosition.value];const r=t.scale,n=e.scale;r.xScale=n.xScale,r.yScale=n.yScale,r.mScale=n.mScale,r.zScale=n.zScale;const s=t.translate,i=e.translate;return s.xTranslate=i.xTranslate,s.yTranslate=i.yTranslate,s.mTranslate=i.mTranslate,s.zTranslate=i.zTranslate,t}async function D(e,t){t??=!1;const r={generateAllSublayers:t,namedTypeDefinitions:new Map};return await async function(e){const t=await(0,i.A)(e,{responseType:"array-buffer"}),r=await t.data;return async function(e){const t=new((await(0,S.I)()).MapOfObjectIdentifierSetsDecoder),r=t.decode(new Uint8Array(e)),n=new Map;if(0!==r.error_code)throw new o.A("knowledge-graph:layer-support-utils",r.error_message);const s=t.get_map_of_identifier_sets(),i=s.keys,a=i.size();for(let e=0;e<a;e++){const t=i.get(e),r=s.query_identifier_set(t),a=[];if(r.id_array_type.value===x.GLOBALID_ARRAY){const e=r.get_globalid_array(),t=e.count();for(let r=0;r<t;r++)a.push(e.get_globalid_at(r))}else if(r.id_array_type.value===x.IDENTIFIER_ARRAY){const e=r.get_identifier_array(),t=e.count();for(let r=0;r<t;r++)a.push(e.get_identifier_at(r).toString())}else if(r.id_array_type.value===x.STRING_ARRAY){const e=r.get_string_array(),t=e.count();for(let r=0;r<t;r++)a.push(e.get_string_at(r))}else{if(r.id_array_type.value!==x.OID_ARRAY)throw new o.A("knowledge-graph:layer-support-utils","Tried to encode an unexpected ID Array type.");{const e=r.get_oid_array(),t=e.count();for(let r=0;r<t;r++)a.push(e.get_objectid_at(r).toString())}}n.set(t,a)}return t.delete(),n}(new Uint8Array(r))}(e).then((e=>{!function(e,t){for(const[r,n]of e){const e=(0,a.tE)(t.namedTypeDefinitions,r,(()=>({useAllData:!1,members:new Map})));for(const t of n)e.members.has(t)||e.members.set(t,{id:t})}}(e,r)})),r}async function O(e){const t=await(0,S.I)(),r=new t.MapOfObjectIdentifierSets;!function(e,t,r){for(const[n,s]of r.namedTypeDefinitions){if(!s.members||s.useAllData)continue;const r=s.members.keys();let i=!1,o=!0;const a=new t.ObjectIdArray,l=new t.StringArray,u=new t.GlobalIdArray,d=new t.IdentifierArray,p=new t.ObjectIdentifierSet;for(const e of r)o&&(i=!isNaN(Number(e)),o=!1),i?a.add_objectid(Number(e)):(l.add_string(e),u.add_globalid(e)),d.add_identifier(e);p.set_oid_array(a),p.set_string_array(l),p.set_globalid_array(u),p.set_identifier_array(d),a.delete(),l.delete(),u.delete(),d.delete(),e.put_identifier_set(n,p),p.delete()}}(r,t,e);const n=new t.MapOfObjectIdentifierSetsEncoder;try{n.set_map_of_identifier_sets(r),n.encode();const e=n.get_encoding_result();if(0!==e.error.error_code)throw new o.A("knowledge-graph:layer-support-utils",e.error.error_message);const t=structuredClone(e.get_byte_buffer());return n.delete(),t}finally{r.delete()}}async function B(e){const t=await(0,i.A)(e,{responseType:"array-buffer"});return async function(e){const t=new((await(0,S.I)()).FeatureCollectionDecoder),r=t.decode(new Uint8Array(e));if(0!==r.error_code)throw new o.A("knowledge-graph:layer-support-utils",r.error_message);const n=function(e){const t=new d;t.version=e.version;const r=e.get_query_result();if(0!==r.results_type.value)throw new Error("Got a non-feature collection type");const n=r.get_feature_result(),s=t.queryResult.featureResult;s.objectIdFieldName=n.objectid_field_name,s.exceededTransferLimit=n.exceeded_transfer_limit,s.hasM=n.has_m,s.hasZ=n.has_z,s.geometryType=N.bV[n.geometry_type.value],s.globalIdFieldName=n.globalid_field_name,s.geohashFieldName=n.geohash_field_name;const i=s.uniqueIdField,o=n.unique_id_field;i.name=o.name,i.isSystemMaintained=o.isSystemMaintained;const a=s.geometryProperties,l=n.geometry_properties;a.shapeAreaFieldName=l.shapeAreaFieldName,a.shapeLengthFieldName=l.shapeLengthFieldName,a.units=l.units;const u=s.spatialReference,p=n.spatial_reference;u.wkid=p.wkid,u.latestWkid=p.latestWkid,u.vcsWkid=p.vcsWkid,u.latestVcsWkid=p.latestVcsWkid,u.wkt=p.wkt,s.transform=R(n.transform);const c=s.fields,h=s.fieldNameToAttributeIndexMap,y=n.fields,m=y.size();for(let e=0;e<m;e++){const t=y.get(e),r=L(t);c.push(r),h[r.name]=e,t.delete()}y.delete();const f=s.values,g=n.values_count();for(let e=0;e<g;e++)f.push(n.get_value_at(e));const _=s.features,w=n.features,T=w.size();if(T>0)for(const e of v)if(void 0===h[e])throw new Error(`Feature collection missing required attribute: ${e}`);for(let e=0;e<T;e++){const t=new b,r=w.get(e),n=t.attributes,s=r.attributes_count();for(let e=0;e<s;e++)n.push(r.get_attribute_at(e));const i=r.get_compressed_geometry();i&&(t.compressedGeometry=k(i),t.centroid=k(r.get_centroid()));const o=t.aggregateGeometries,a=r.aggregate_geometries,l=a.size();for(let e=0;e<l;e++){const t=a.get(e),r=k(t);o.push(r),t.delete()}a.delete(),_.push(t),r.delete()}w.delete();const I=s.geometryFields,E=n.geometry_fields,M=E.size();for(let e=0;e<M;e++){const t=E.get(e),r=C(t);I.push(r),t.delete()}return E.delete(),t}(t.get_feature_collection());return t.delete(),n}(await t.data)}function F(e,t){if(!e?.queryResult?.featureResult)return t;const r=e.queryResult.featureResult.fieldNameToAttributeIndexMap;for(const s of e.queryResult.featureResult.features){const e=s.attributes[r[n.TYPENAME]],i=(0,a.tE)(t.namedTypeDefinitions,e,(()=>({useAllData:!1,members:new Map}))),o=s.attributes[r[n.ELEMENTUID]];if(s.compressedGeometry?.coords?.length>0){let e=s.compressedGeometry.lengths;"esriGeometryPoint"===s.compressedGeometry.geometryType&&(e=[]),i.members.set(o,{id:o,linkChartLocation:new l.A(e,s.compressedGeometry.coords)})}else i.members.set(o,{id:o})}return t}!function(e){e[e.featureResult=0]="featureResult",e[e.countResult=1]="countResult",e[e.idsResult=2]="idsResult"}(E||(E={})),function(e){e[e.upperLeft=0]="upperLeft",e[e.lowerLeft=1]="lowerLeft"}(M||(M={})),function(e){e[e.sqlTypeBigInt=0]="sqlTypeBigInt",e[e.sqlTypeBinary=1]="sqlTypeBinary",e[e.sqlTypeBit=2]="sqlTypeBit",e[e.sqlTypeChar=3]="sqlTypeChar",e[e.sqlTypeDate=4]="sqlTypeDate",e[e.sqlTypeDecimal=5]="sqlTypeDecimal",e[e.sqlTypeDouble=6]="sqlTypeDouble",e[e.sqlTypeFloat=7]="sqlTypeFloat",e[e.sqlTypeGeometry=8]="sqlTypeGeometry",e[e.sqlTypeGUID=9]="sqlTypeGUID",e[e.sqlTypeInteger=10]="sqlTypeInteger",e[e.sqlTypeLongNVarchar=11]="sqlTypeLongNVarchar",e[e.sqlTypeLongVarbinary=12]="sqlTypeLongVarbinary",e[e.sqlTypeLongVarchar=13]="sqlTypeLongVarchar",e[e.sqlTypeNChar=14]="sqlTypeNChar",e[e.sqlTypeNVarChar=15]="sqlTypeNVarChar",e[e.sqlTypeOther=16]="sqlTypeOther",e[e.sqlTypeReal=17]="sqlTypeReal",e[e.sqlTypeSmallInt=18]="sqlTypeSmallInt",e[e.sqlTypeSqlXml=19]="sqlTypeSqlXml",e[e.sqlTypeTime=20]="sqlTypeTime",e[e.sqlTypeTimestamp=21]="sqlTypeTimestamp",e[e.sqlTypeTimestamp2=22]="sqlTypeTimestamp2",e[e.sqlTypeTinyInt=23]="sqlTypeTinyInt",e[e.sqlTypeVarbinary=24]="sqlTypeVarbinary",e[e.sqlTypeVarchar=25]="sqlTypeVarchar"}(A||(A={})),function(e){e[e.OID_ARRAY=0]="OID_ARRAY",e[e.GLOBALID_ARRAY=1]="GLOBALID_ARRAY",e[e.STRING_ARRAY=2]="STRING_ARRAY",e[e.IDENTIFIER_ARRAY=3]="IDENTIFIER_ARRAY"}(x||(x={}));const j={fetchAndConvertSerializedLinkChart:e=>async function(e){const t=[],r={generateAllSublayers:!1,namedTypeDefinitions:new Map};return e.entitiesUrl&&t.push(B(e.entitiesUrl).then((e=>{F(e,r)}))),e.relationshipsUrl&&t.push(B(e.relationshipsUrl).then((e=>{F(e,r)}))),await Promise.all(t),r}(e)}},9775:(e,t,r)=>{r.d(t,{A:()=>i});var n=r(62788),s=r(95488);class i{constructor(e=e=>e.values().next().value){this._peeker=e,this._observable=new s.I,this._items=new Set}get length(){return(0,n.gc)(this._observable),this._items.size}clear(){0!==this.length&&(this._items.clear(),this._observable.notify())}last(){if(0===this.length)return;let e;for(e of this._items);return e}peek(){if(0!==this.length)return this._peeker(this._items)}push(e){this.contains(e)||(this._items.add(e),this._observable.notify())}contains(e){return(0,n.gc)(this._observable),this._items.has(e)}pop(){if(0===this.length)return;const e=this.peek();return this._items.delete(e),this._observable.notify(),e}popLast(){if(0===this.length)return;const e=this.last();return this._items.delete(e),this._observable.notify(),e}remove(e){this.contains(e)&&(this._items.delete(e),this._observable.notify())}filter(e){const t=this.length;return this._items.forEach((t=>{e(t)||this._items.delete(t)})),t!==this._items.size&&this._observable.notify(),this}*[Symbol.iterator](){(0,n.gc)(this._observable),yield*this._items}}},75503:(e,t,r)=>{r.d(t,{E:()=>M,w:()=>a});var n=r(4576),s=(r(44208),r(4718)),i=r(3694),o=r(11006);class a{constructor(e=9,t){this._compareMinX=c,this._compareMinY=h,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),v.prune(),T.prune(),I.prune(),E.prune()}all(e){l(this._data,e)}search(e,t){let r=this._data;const n=this._toBBox;if(b(e,r))for(v.clear();r;){for(let s=0,i=r.children.length;s<i;s++){const i=r.children[s],o=r.leaf?n(i):i;b(e,o)&&(r.leaf?t(i):_(e,o)?l(i,t):v.push(i))}r=v.pop()}}collides(e){let t=this._data;const r=this._toBBox;if(!b(e,t))return!1;for(v.clear();t;){for(let n=0,s=t.children.length;n<s;n++){const s=t.children[n],i=t.leaf?r(s):s;if(b(e,i)){if(t.leaf||_(e,i))return!0;v.push(s)}}t=v.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,r=e.length;t<r;t++)this.insert(e[t]);return this}let t=this._build(e.slice(),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new x([]),this}remove(e){if(!e)return this;let t,r=this._data,s=null,i=0,o=!1;const a=this._toBBox(e);for(I.clear(),E.clear();r||I.length>0;){if(r||(r=I.pop(),s=I.data[I.length-1],i=E.pop()??0,o=!0),r.leaf&&(t=(0,n.qh)(r.children,e,r.children.length,r.indexHint),-1!==t))return r.children.splice(t,1),I.push(r),this._condense(I),this;o||r.leaf||!_(r,a)?s?(i++,r=s.children[i],o=!1):r=null:(I.push(r),E.push(i),i=0,s=r,r=r.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,r,n){const s=r-t+1;let i=this._maxEntries;if(s<=i){const n=new x(e.slice(t,r+1));return u(n,this._toBBox),n}n||(n=Math.ceil(Math.log(s)/Math.log(i)),i=Math.ceil(s/i**(n-1)));const o=new S([]);o.height=n;const a=Math.ceil(s/i),l=a*Math.ceil(Math.sqrt(i));w(e,t,r,l,this._compareMinX);for(let s=t;s<=r;s+=l){const t=Math.min(s+l-1,r);w(e,s,t,a,this._compareMinY);for(let r=s;r<=t;r+=a){const s=Math.min(r+a-1,t);o.children.push(this._build(e,r,s,n-1))}}return u(o,this._toBBox),o}_insert(e,t,r){const n=this._toBBox,s=r?e:n(e);I.clear();const i=function(e,t,r,n){for(;n.push(t),!0!==t.leaf&&n.length-1!==r;){let r,n=1/0,s=1/0;for(let i=0,o=t.children.length;i<o;i++){const o=t.children[i],a=y(o),l=f(e,o)-a;l<s?(s=l,n=a<n?a:n,r=o):l===s&&a<n&&(n=a,r=o)}t=r||t.children[0]}return t}(s,this._data,t,I);for(i.children.push(e),p(i,s);t>=0&&I.data[t].children.length>this._maxEntries;)this._split(I,t),t--;!function(e,t,r){for(let n=r;n>=0;n--)p(t.data[n],e)}(s,I,t)}_split(e,t){const r=e.data[t],n=r.children.length,s=this._minEntries;this._chooseSplitAxis(r,s,n);const i=this._chooseSplitIndex(r,s,n);if(!i)return;const o=r.children.splice(i,r.children.length-i),a=r.leaf?new x(o):new S(o);a.height=r.height,u(r,this._toBBox),u(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(r,a)}_splitRoot(e,t){this._data=new S([e,t]),this._data.height=e.height+1,u(this._data,this._toBBox)}_chooseSplitIndex(e,t,r){let n,s,i;n=s=1/0;for(let o=t;o<=r-t;o++){const t=d(e,0,o,this._toBBox),a=d(e,o,r,this._toBBox),l=g(t,a),u=y(t)+y(a);l<n?(n=l,i=o,s=u<s?u:s):l===n&&u<s&&(s=u,i=o)}return i}_chooseSplitAxis(e,t,r){const n=e.leaf?this._compareMinX:c,s=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,r,n)<this._allDistMargin(e,t,r,s)&&e.children.sort(n)}_allDistMargin(e,t,r,n){e.children.sort(n);const s=this._toBBox,i=d(e,0,t,s),o=d(e,r-t,r,s);let a=m(i)+m(o);for(let n=t;n<r-t;n++){const t=e.children[n];p(i,e.leaf?s(t):t),a+=m(i)}for(let n=r-t-1;n>=t;n--){const t=e.children[n];p(o,e.leaf?s(t):t),a+=m(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const r=e.data[t];if(0===r.children.length)if(t>0){const s=e.data[t-1],i=s.children;i.splice((0,n.qh)(i,r,i.length,s.indexHint),1)}else this.clear();else u(r,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function l(e,t){let r=e;for(T.clear();r;){if(!0===r.leaf)for(const e of r.children)t((0,s.zI)(e));else T.pushArray(r.children);r=T.pop()??null}}function u(e,t){d(e,0,e.children.length,t,e)}function d(e,t,r,n,s){s||(s=new x([])),s.minX=1/0,s.minY=1/0,s.maxX=-1/0,s.maxY=-1/0;for(let i,o=t;o<r;o++)i=e.children[o],p(s,e.leaf?n(i):i);return s}function p(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function c(e,t){return e.minX-t.minX}function h(e,t){return e.minY-t.minY}function y(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function m(e){return e.maxX-e.minX+(e.maxY-e.minY)}function f(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function g(e,t){const r=Math.max(e.minX,t.minX),n=Math.max(e.minY,t.minY),s=Math.min(e.maxX,t.maxX),i=Math.min(e.maxY,t.maxY);return Math.max(0,s-r)*Math.max(0,i-n)}function _(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function b(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function w(e,t,r,n,s){const i=[t,r];for(;i.length;){const t=i.pop(),r=i.pop();if(t-r<=n)continue;const a=r+Math.ceil((t-r)/n/2)*n;(0,o.q)(e,a,r,t,s),i.push(r,a,a,t)}}const v=new i.A,T=new i.A,I=new i.A,E=new i.A({deallocator:void 0});class M{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class A extends M{constructor(){super(...arguments),this.height=1,this.indexHint=new n.vW}}class x extends A{constructor(e){super(),this.children=e,this.leaf=!0}}class S extends A{constructor(e){super(),this.children=e,this.leaf=!1}}},10382:(e,t,r)=>{r.d(t,{A:()=>u});var n=r(36563),s=(r(44208),r(74887)),i=r(9775),o=r(72457),a=r(52268),l=r(61322);class u{constructor(){this._inUseClients=new Array,this._clients=new Array,this._clientPromises=new Array,this._ongoingJobsQueue=new i.A}destroy(){this.close()}get closed(){return!this._clients?.length}open(e,t){return new Promise(((r,n)=>{let i=!0;const o=e=>{(0,s.Te)(t.signal),i&&(i=!1,e())};this._clients.length=e.length,this._clientPromises.length=e.length,this._inUseClients.length=e.length;for(let i=0;i<e.length;++i){const a=e[i];(0,s.$X)(a)?this._clientPromises[i]=a.then((e=>(this._clients[i]=new l.default(e,t,this._ongoingJobsQueue),o(r),this._clients[i])),(()=>(o(n),null))):(this._clients[i]=new l.default(a,t,this._ongoingJobsQueue),this._clientPromises[i]=Promise.resolve(this._clients[i]),o(r))}}))}broadcast(e,t,r){const n=new Array(this._clientPromises.length);for(let s=0;s<this._clientPromises.length;++s){const i=this._clientPromises[s];n[s]=i.then((n=>n?.invoke(e,t,r)))}return n}close(){let e;for(;e=this._ongoingJobsQueue.pop();)e.resolver.reject((0,s.NK)(`Worker closing, aborting job calling '${e.methodName}'`));for(const e of this._clientPromises)e.then((e=>e?.close()));this._clients.length=0,this._clientPromises.length=0,this._inUseClients.length=0,(0,o.h)(this)}invoke(e,t,r){return this.apply(e,[t],r)}apply(e,t,r){const n=(0,s.Tw)();this._ongoingJobsQueue.push({methodName:e,data:t,invokeOptions:r,resolver:n});for(let e=0;e<this._clientPromises.length;e++){const t=this._clients[e];t?t.jobAdded():this._clientPromises[e].then((e=>e?.jobAdded()))}return n.promise}createInvokeProxy(e){return(0,a.L)(this,e)}on(e,t){return Promise.all(this._clientPromises).then((()=>(0,n.vE)(this._clients.map((r=>r.on(e,t))))))}openPorts(){return new Promise((e=>{const t=new Array(this._clientPromises.length);let r=t.length;for(let n=0;n<this._clientPromises.length;++n)this._clientPromises[n].then((s=>{s&&(t[n]=s.openPort()),0==--r&&e(t)}))}))}get test(){}}},72457:(e,t,r)=>{r.d(t,{h:()=>i,k:()=>s});const n=new FinalizationRegistry((e=>{e.close()}));function s(e,t){n.register(e,t,t)}function i(e){n.unregister(e)}},29953:(e,t,r)=>{r.d(t,{ho:()=>G});var n=r(49186),s=r(44208),i=r(74887),o=r(10382),a=r(72457),l=r(61322),u=r(53966),d=r(97768),p=r(78888),c=r(84952);const h={async request(e,t){const r=e.options,n=r.responseType;r.signal=t?.signal,r.responseType="native"===n||"native-request-init"===n?"native-request-init":n&&["blob","json","text"].includes(n)&&(0,c.sC)(e.url)?.after?n:"array-buffer";const s=await(0,p.A)(e.url,r),i={data:s.data,httpStatus:s.httpStatus,ssl:s.ssl};switch(s.requestOptions?.responseType){case"native-request-init":return delete i.data.signal,i;case"blob":i.data=await i.data.arrayBuffer();break;case"json":i.data=(new TextEncoder).encode(JSON.stringify(i.data)).buffer;break;case"text":i.data=(new TextEncoder).encode(i.data).buffer}return{result:i,transferList:[i.data]}}};var y=r(8341),m=r(2741),f=r(92602),g=(r(47566),r(70333));const _={};var b=r(26390);class w{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...r)=>e[t](...r)}))}}class v{constructor(){this._dispatcher=new w,this._workerPostMessage({type:y.Go.HANDSHAKE})}terminate(){}get onmessage(){return this._onmessageHandler}set onmessage(e){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler),this._onmessageHandler=e,e&&this.addEventListener("message",e)}get onmessageerror(){return this._onmessageerrorHandler}set onmessageerror(e){this._onmessageerrorHandler&&this.removeEventListener("messageerror",this._onmessageerrorHandler),this._onmessageerrorHandler=e,e&&this.addEventListener("messageerror",e)}get onerror(){return this._onerrorHandler}set onerror(e){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler),this._onerrorHandler=e,e&&this.addEventListener("error",e)}postMessage(e){(0,b.d)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,r){this._dispatcher.addEventListener(e,t,r)}removeEventListener(e,t,r){this._dispatcher.removeEventListener(e,t,r)}_workerPostMessage(e){(0,b.d)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,y.VI)(e);if(t&&t.type===y.Go.OPEN){const{modulePath:e,jobId:r}=t;let n=await l.default.loadWorker(e);n||(n=await import(e));const s=l.default.connect(n);this._workerPostMessage({type:y.Go.OPENED,jobId:r,data:s})}}}var T=r(73444),I=r(18357);const E=()=>u.A.getLogger("esri.core.workers.workerFactory"),{HANDSHAKE:M}=y.Go;let A,x;const S="Failed to create Worker. Fallback to execute module in main thread";async function N(e){return new Promise((t=>{function r(s){const i=(0,y.VI)(s);i&&i.type===M&&(e.removeEventListener("message",r),e.removeEventListener("error",n),t(e))}function n(t){t.preventDefault(),e.removeEventListener("message",r),e.removeEventListener("error",n),E().warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new v).addEventListener("message",r),e.addEventListener("error",n)}e.addEventListener("message",r),e.addEventListener("error",n)}))}let k=0;const{ABORT:L,INVOKE:C,OPEN:R,OPENED:D,RESPONSE:O}=y.Go;class B{static async create(e){const t=await async function(){if(!(0,s.A)("esri-workers"))return N(new v);if(!A&&!x)try{const e='let globalId=0;const outgoing=new Map,configuration={CONFIGURATION};self.esriConfig=configuration.esriConfig;const workerPath=self.esriConfig.workers.workerPath,HANDSHAKE=0,OPEN=1,OPENED=2,RESPONSE=3,INVOKE=4,ABORT=5;function createAbortError(){const e=new Error("Aborted");return e.name="AbortError",e}function receiveMessage(e){return e&&e.data?"string"==typeof e.data?JSON.parse(e.data):e.data:null}function invokeStaticMessage(e,o,r){const t=r&&r.signal,n=globalId++;let s=null;return new Promise(((r,i)=>{if(t){if(t.aborted)return i(createAbortError());s=()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:5,jobId:n}),i(createAbortError()))},t.addEventListener("abort",s)}outgoing.set(n,{resolve:r,reject:i}),self.postMessage({type:4,jobId:n,methodName:e,abortable:null!=t,data:o})})).finally((()=>{t&&t.removeEventListener("abort",s)}))}let workerRevisionChecked=!1;function checkWorkerRevision(e){if(!workerRevisionChecked&&e.kernelInfo){workerRevisionChecked=!0;const{revision:o,fullVersion:r}=configuration.kernelInfo,{revision:t,fullVersion:n,version:s}=e.kernelInfo;esriConfig.assetsPath!==esriConfig.defaultAssetsPath&&o!==t&&console.warn(`Version mismatch detected between ArcGIS Maps SDK for JavaScript modules and assets. For more information visit https://bit.ly/3QnsuSo.\nModules version: ${r}\nAssets version: ${n??s}\nAssets path: ${esriConfig.assetsPath}`)}}function messageHandler(e){const o=receiveMessage(e);if(!o)return;const r=o.jobId;switch(o.type){case 1:let n;function t(e){const o=n.connect(e);self.postMessage({type:2,jobId:r,data:o},[o])}"function"==typeof define&&define.amd?require([workerPath],(e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||new Promise((e=>{require([o.modulePath],e)})))).then(t)})):"System"in self&&"function"==typeof System.import?System.import(workerPath).then((e=>(n=e.default,checkWorkerRevision(n),n.loadWorker(o.modulePath)))).then((e=>e||System.import(o.modulePath))).then(t):esriConfig.workers.useDynamicImport?import(workerPath).then((e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||import(o.modulePath))).then(t)})):(self.RemoteClient||importScripts(workerPath),n=self.RemoteClient.default||self.RemoteClient,checkWorkerRevision(n),n.loadWorker(o.modulePath).then(t));break;case 3:if(outgoing.has(r)){const s=outgoing.get(r);outgoing.delete(r),o.error?s.reject(JSON.parse(o.error)):s.resolve(o.data)}}}self.dojoConfig=configuration.loaderConfig,esriConfig.workers.loaderUrl&&(self.importScripts(esriConfig.workers.loaderUrl),"function"==typeof require&&"function"==typeof require.config&&require.config(configuration.loaderConfig)),self.addEventListener("message",messageHandler),self.postMessage({type:0});'.split("{CONFIGURATION}").join(function(){let e;if(null!=f.A.default){const t={...f.A};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(f.A));e.assetsPath=(0,c.s2)(e.assetsPath),e.defaultAssetsPath=e.defaultAssetsPath?(0,c.s2)(e.defaultAssetsPath):void 0,e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,T.JK)(),e.has={"esri-csp-restrictions":(0,s.A)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,s.A)("esri-2d-update-debug"),"esri-2d-log-updating":(0,s.A)("esri-2d-log-updating"),"featurelayer-pbf":(0,s.A)("featurelayer-pbf"),"featurelayer-fast-triangulation-enabled":(0,s.A)("featurelayer-fast-triangulation-enabled"),"featurelayer-simplify-thresholds":(0,s.A)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,s.A)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,s.A)("featurelayer-simplify-mobile-factor"),"featurelayer-query-max-depth":(0,s.A)("featurelayer-query-max-depth"),"featurelayer-query-pausing-enabled":(0,s.A)("featurelayer-query-pausing-enabled"),"featurelayer-snapshot-enabled":(0,s.A)("featurelayer-snapshot-enabled"),"esri-atomics":(0,s.A)("esri-atomics"),"esri-shared-array-buffer":(0,s.A)("esri-shared-array-buffer"),"esri-tiles-debug":(0,s.A)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,s.A)("esri-workers-arraybuffer-transfer"),"feature-polyline-generalization-factor":(0,s.A)("feature-polyline-generalization-factor"),"host-webworker":1},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,c.s2)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,c.s2)(e.workers.workerPath):e.workers.workerPath=(0,c.s2)((0,m.s)("esri/core/workers/RemoteClient.js")),e.workers.useDynamicImport=!1;const t=f.A.workers.loaderConfig,r=function(e){const t={async:e.async,isDebug:e.isDebug,locale:e.locale,baseUrl:e.baseUrl,has:{...e.has},map:{...e.map},packages:e.packages?.slice()||[],paths:{..._.paths,...e.paths}};return e.hasOwnProperty("async")||(t.async=!0),e.hasOwnProperty("isDebug")||(t.isDebug=!1),e.baseUrl||(t.baseUrl=_.baseUrl),t}({baseUrl:t?.baseUrl,locale:(0,T.JK)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...t?.has},map:{...t?.map},paths:{...t?.paths},packages:t?.packages||[]}),n={buildDate:I.$,fullVersion:g.ol,revision:I.u};return JSON.stringify({esriConfig:e,loaderConfig:r,kernelInfo:n})}());A=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){x=e||{}}let e;if(A)try{e=new Worker(A,{name:"esri-worker-"+k++})}catch(t){E().warn(S,x),e=new v}else E().warn(S,x),e=new v;return N(e)}();return new B(t,e)}constructor(e,t){this._outJobs=new Map,this._inJobs=new Map,this.worker=e,this.id=t,e.addEventListener("message",this._onMessage.bind(this)),e.addEventListener("error",(e=>{e.preventDefault(),u.A.getLogger("esri.core.workers.WorkerOwner").error(e)}))}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:r}=t,n=(0,y.Jc)();return new Promise(((t,s)=>{const o={resolve:t,reject:s,abortHandle:(0,i.NY)(r,(()=>{this._outJobs.delete(n),this._post({type:L,jobId:n})}))};this._outJobs.set(n,o),this._post({type:R,jobId:n,modulePath:e})}))}_onMessage(e){const t=(0,y.VI)(e);if(t)switch(t.type){case D:this._onOpenedMessage(t);break;case O:this._onResponseMessage(t);break;case L:this._onAbortMessage(t);break;case C:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,r=e.jobId,n=t.get(r);n&&(n.controller&&n.controller.abort(),t.delete(r))}_onInvokeMessage(e){const{methodName:t,jobId:r,data:n,abortable:s}=e,o=s?new AbortController:null,a=this._inJobs,l=h[t];let u;try{if("function"!=typeof l)throw new TypeError(`${t} is not a function`);u=l.call(null,n,{signal:o?o.signal:null})}catch(e){return void this._post({type:O,jobId:r,error:(0,y.mF)(e)})}(0,i.$X)(u)?(a.set(r,{controller:o,promise:u}),u.then((e=>{a.has(r)&&(a.delete(r),this._post({type:O,jobId:r},e))}),(e=>{a.has(r)&&(a.delete(r),e||(e={message:"Error encountered at method"+t}),(0,i.zf)(e)||this._post({type:O,jobId:r,error:(0,y.mF)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:O,jobId:r},u)}_onOpenedMessage(e){const{jobId:t,data:r}=e,n=this._outJobs.get(t);n&&(this._outJobs.delete(t),(0,d.xt)(n.abortHandle),n.resolve(r))}_onResponseMessage(e){const{jobId:t,error:r,data:s}=e,i=this._outJobs.get(t);i&&(this._outJobs.delete(t),(0,d.xt)(i.abortHandle),r?i.reject(n.A.fromJSON(JSON.parse(r))):i.resolve(s))}_post(e,t,r){return(0,y.u1)(this.worker,e,t,r)}}const F=(0,s.A)("host-browser")?Math.min(navigator.hardwareConcurrency-1,(0,s.A)("workers-pool-size")??8):0;let j=(0,s.A)("esri-mobile")?Math.min(F,3):F;j||(j=(0,s.A)("safari")&&(0,s.A)("mac")?7:2);let P=0;const q=[];async function Z(e,t){const r=new o.A,{registryTarget:n,...s}=t;return await r.open(e,s),n&&(0,a.k)(n,r),r}async function G(e,t={}){if("string"!=typeof e)throw new n.A("workers:undefined-module","modulePath is missing");let r=t.strategy||"distributed";if((0,s.A)("host-webworker")&&!(0,s.A)("esri-workers")&&(r="local"),"local"===r){let r=await l.default.loadWorker(e);r||(r=await import(e)),(0,i.Te)(t.signal);const n=t.client||r;return Z([l.default.connect(r,t.schedule)],{...t,client:n})}if(await async function(){if(U)return U;$=new AbortController;const e=[];for(let t=0;t<j;t++){const r=B.create(t).then((e=>(q[t]=e,e)));e.push(r)}return U=Promise.all(e),U}(),(0,i.Te)(t.signal),"dedicated"===r){const r=P++%j;return Z([await q[r].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const r=Math.min(t.maxNumWorkers,j);if(r<j){const n=new Array(r);for(let s=0;s<r;++s){const r=P++%j;n[s]=q[r].open(e,t)}return Z(n,t)}}return Z(q.map((r=>r.open(e,t))),t)}let $,U=null},6518:(e,t,r)=>{r.d(t,{F:()=>a});var n=r(44208),s=r(75503),i=r(19419);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new s.w(9,(0,n.A)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((r,n)=>{e[t++]=n})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,i.Ie)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,r){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,r)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},83221:(e,t,r)=>{r.d(t,{A:()=>y});var n=r(4576),s=r(49186),i=r(65529),o=r(53966),a=r(70328),l=r(19419),u=r(90708),d=r(6518),p=r(51441),c=r(37730);const h=(0,a.vt)();class y{constructor(e){this.geometryInfo=e,this._boundsStore=new d.F,this._featuresById=new Map,this.events=new i.A,this.featureAdapter=c.T}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach((t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,r,n,s]=this.fullBounds;return{xmin:t,ymin:r,xmax:n,ymax:s,spatialReference:(0,p.ag)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map((e=>this._upsert(e)));return this._emitChanged(),t.filter(n.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const r of e){const e=this._boundsStore.get(r.objectId);e&&t((0,a.Jt)(h,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new s.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const r=this._featuresById.get(t);let n;if(r?(e.displayId=r.displayId,n=this._boundsStore.get(t),this._boundsStore.delete(t)):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);n=(0,u.jQ)(null!=n?n:(0,l.vt)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=n&&this._boundsStore.set(t,n),this._featuresById.set(t,e)}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new s.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const r=this._featuresById.get(t);if(!r)return this._add(e),e;const{geometry:n,attributes:i}=e;for(const e in i)r.attributes[e]=i[e];return n&&(r.geometry=n,this._boundsStore.set(t,(0,u.jQ)((0,l.vt)(),n,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),r}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._boundsStore.delete(t),this._featuresById.delete(t),e}}},37730:(e,t,r)=>{r.d(t,{T:()=>s});var n=r(43334);const s={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new n.Om(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>e.ensureCentroid(t)}},64714:(e,t,r)=>{r.d(t,{F0:()=>l,Vx:()=>p,e2:()=>h,f:()=>y});var n=r(44208),s=r(4718),i=r(99352),o=r(4071),a=r(93470);function l(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?a.Cb:"esriGeometryPolyline"===e?a.yM:a.WR}}}const u=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let d=1;function p(e,t){if((0,n.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let r=`this${c(t)} = null;`;for(const t in e)r+=`this${c(t)} = ${JSON.stringify(e[t])};`;const n=new Function(`\n return class AttributesClass$${d++} {\n constructor() {\n ${r};\n }\n }\n `)();return()=>new n}catch(r){return()=>({[t]:null,...e})}}function c(e){return u.test(e)?`.${e}`:`["${e}"]`}function h(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,s.o8)(e)}}]}function y(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:i.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:o.$,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},80340:(e,t,r)=>{r.d(t,{P:()=>T});var n=r(90237),s=(r(59456),r(69622)),i=r(49186),o=r(53966),a=r(91869),l=r(74887),u=r(39516),d=r(10107),p=(r(44208),r(87811),r(40608)),c=r(39829),h=r(57251),y=r(21325),m=r(85342),f=r(69860),g=r(30504),_=r(71402),b=r(42538),w=r(61956),v=r(5443);let T=class extends s.A{constructor(e){super(e),this._processingCacheUpdatesLookup=new Map,this.knowledgeGraph=null,this.inclusionModeDefinition={generateAllSublayers:!0,namedTypeDefinitions:new Map},this.entityTypeNames=new Set,this.relationshipTypeNames=new Set,this.geographicLookup=new Map,this.sublayerCaches=new Map,this.nodeConnectionsLookup=new Map,this.relationshipConnectionsLookup=new Map,this.memberIdTypeLookup=new Map;const t=new Map;e.knowledgeGraph.dataModel.entityTypes?.forEach((r=>{r.name&&(t.set(r.name,"entity"),this._processingCacheUpdatesLookup.set(r.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.entityTypeNames.add(r.name),r.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(r.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.knowledgeGraph.dataModel.relationshipTypes?.forEach((r=>{r.name&&(t.set(r.name,"relationship"),this._processingCacheUpdatesLookup.set(r.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.relationshipTypeNames.add(r.name),r.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(r.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.inclusionModeDefinition?.namedTypeDefinitions.forEach(((r,n)=>{if("entity"===t.get(n))this.entityTypeNames.add(n);else{if("relationship"!==t.get(n))return o.A.getLogger(this).warn(`A named type, ${n}, was in the inclusion list that wasn't in the data model and will be removed`),void e.inclusionModeDefinition?.namedTypeDefinitions.delete(n);this.relationshipTypeNames.add(n)}const s=new Map;r.members?.forEach((e=>{(0,a.tE)(this.memberIdTypeLookup,e.id,(()=>new Set)).add(n);const t=this.getById(e.id);t&&s.set(e.id,t)})),this.sublayerCaches.set(n,s)}))}addToLayer(e){e.forEach((({typeName:e,id:t})=>{if(!this.inclusionModeDefinition)throw new i.A("knowledge-graph:layer-data-manager","You cannot add to a layer's exclusion list if it was not created with an exclusion list originally");if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){const r=this.inclusionModeDefinition.namedTypeDefinitions.get(e);r.members||(r.members=new Map),r.members.set(t,{id:t}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}else{const r=new Map;r.set(t,{id:t}),this.inclusionModeDefinition.namedTypeDefinitions.set(e,{useAllData:!1,members:r}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}))}getById(e){return f.A.getInstance().readFromStoreById(e)}async getData(e,t,r){if(t.objectType.name&&this.inclusionModeDefinition?.namedTypeDefinitions&&this.inclusionModeDefinition.namedTypeDefinitions.size>0&&!this.inclusionModeDefinition.namedTypeDefinitions.has(t.objectType.name))return[];let n;if(n=e||new w.A({where:"1=1",outFields:["*"]}),"link-chart"===t.parentCompositeLayer.type){const e=t.parentCompositeLayer,r=this._processingCacheUpdatesLookup.get(t.objectType.name??""),s=n.outFields;s&&1===s.length&&s[0]===m.dr&&"1=1"===n.where||await Promise.all(r??[]);const i=this.sublayerCaches.has(t.objectType.name??"")?Array.from(this.sublayerCaches.get(t.objectType.name)?.values()):[],o=[];return i.forEach((r=>{if(this.relationshipTypeNames.has(t.objectType.name)){r.geometry=e.relationshipLinkChartDiagramLookup.get(r.attributes[t.objectIdField]);const n=this.memberIdTypeLookup.get(r.attributes[m.Cz]),s=this.memberIdTypeLookup.get(r.attributes[m.KQ]),i=this._isEndEntitySpatial(n,r,m.Cz),o=this._isEndEntitySpatial(s,r,m.KQ);r.attributes[m.BL]=Number(i&&o)}else{r.geometry=e.entityLinkChartDiagramLookup.get(r.attributes[t.objectIdField]);const n=this.geographicLookup.get(t.objectType.name);n&&r.attributes[n.name]?r.attributes[m.BL]=1:r.attributes[m.BL]=0}r.attributes[m.T1]=r.geometry,o.push(r)})),o}return this.retrieveDataFromService(n,t,r)}async getConnectedRecordIds(e,t,r){const n=[];let s="";const i=this._getNamedTypeIdMapFromNodeIds(e);if(t&&0!==t?.length){for(const e of t)s=s+e+"|";s=s.slice(0,-1)}const o={},a=[];for(const[e,r]of i){const n=`${e}_ids`;o[n]=r,t&&0!==t?.length?a.push(`MATCH (n:${e}) WHERE id(n) IN $${n} WITH n MATCH (n)-[r:${s}]-(m) RETURN id(r), type(r), id(m), labels(m)[0]`):a.push(`MATCH (n:${e}) WHERE id(n) IN $${n} WITH n MATCH (n)-[r]-(m) RETURN id(r), type(r), id(m), labels(m)[0]`)}if(!a.length)return n;const l=a.join(" UNION "),u=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:l,bindParameters:o}),{signal:r?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await u.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];n.push({id:r[0],typeName:r[1]}),n.push({id:r[2],typeName:r[3]})}}return n}async getRelationshipsBetweenNodes(e,t,r){const n=this._getNamedTypeIdMapFromNodeIds(e);if(0===n.size)return[];const s={relationshipExclusionIds:t,possibleConnectionEntityIds:e},i=[];for(const[e,t]of n.entries()){const r=`${e}_ids`;s[r]=t,i.push(`MATCH (n:${e}) WHERE id(n) IN $${r} WITH n MATCH (n)-[r]->(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const o=i.join(" UNION "),a=[],l=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:o,bindParameters:s}),{signal:r?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await l.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];a.push({id:r[0],typeName:r[1]})}}return a}async getRelationshipsFromNodes(e,t,r,n){const s=this._getNamedTypeIdMapFromNodeIds(e);if(0===s.size||0===t.length)return[];const i={relationshipExclusionIds:r,possibleConnectionEntityIds:t},o=[];for(const[e,t]of s.entries()){const r=`${e}_ids`;i[r]=t,o.push(`MATCH (n:${e}) WHERE id(n) IN $${r} WITH n MATCH (n)-[r]-(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const a=o.join(" UNION "),l=new Map,u=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:a,bindParameters:i}),{signal:n?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await u.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];let n=l.get(r[1]);n||(n=new Set,l.set(r[1],n)),n.add(r[0])}}const d=[];for(const[e,t]of l)for(const r of t)d.push({id:r,typeName:e});return d}async refreshCacheContent(e,t,r,n=!0,s){const o=f.A.getInstance(),u=[],d=new Map,p=new Map;this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&p.set(e.name,e)})),this.knowledgeGraph.dataModel.relationshipTypes?.forEach((e=>{e.name&&p.set(e.name,e)})),e||this.inclusionModeDefinition?e?e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const t of this.memberIdTypeLookup.get(e))d.has(t)?d.get(t)?.push(e):d.set(t,[e])})):this.inclusionModeDefinition?.namedTypeDefinitions?.forEach(((e,t)=>{e.useAllData?d.set(t,null):e.members&&e.members.forEach((e=>{d.has(t)&&null!==d.get(t)?d.get(t)?.push(e.id):d.set(t,[e.id])}))})):(this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&d.set(e.name,null)})),this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&d.set(e.name,null)})));for(const[e,l]of d){const d=new Set(l),c=new Promise(((u,c)=>{(async()=>{const u=new Set,c=[];let h,y="",f=!1;if(t||p.get(e)?.properties?.forEach((e=>{e.name&&u.add(e.name)})),r&&this.geographicLookup.has(e)){const t=this.geographicLookup.get(e)?.name;t&&u.add(t)}if(this.entityTypeNames.has(e))y=`MATCH (n:${e}) ${l?"WHERE id(n) IN $ids ":""}return ID(n)`,u.forEach((e=>{y+=`, n.${e}`,c.push(e)}));else{if(!this.relationshipTypeNames.has(e))throw new i.A("knowledge-graph:layer-data-manager",`The graph type of ${e} could not be determined. Was this type set in the KG data model and inclusion definition?`);f=!0,y=`MATCH ()-[n:${e}]->() ${l?"WHERE id(n) IN $ids ":""}return ID(n), id(startNode(n)), id(endNode(n))`,u.forEach((e=>{y+=`, n.${e}`,c.push(e)}))}h=new b.A(l?{openCypherQuery:y,bindParameters:{ids:l}}:{openCypherQuery:y});const g=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,h,{signal:s?.signal})).resultRowsStream.getReader();for(;;){const{done:t,value:r}=await g.read();if(t)break;const s=[];for(let e=0;e<r.length;e++){const t=r[e];let n=0,i=0;const o={properties:{}};for(o.id=t[n],n++,i++,f&&(o.originId=t[n],n++,i++,o.destinationId=t[n],n++,i++,(0,a.tE)(this.nodeConnectionsLookup,o.originId,(()=>new Set)).add(o.id),(0,a.tE)(this.nodeConnectionsLookup,o.destinationId,(()=>new Set)).add(o.id),(0,a.tE)(this.relationshipConnectionsLookup,o.id,(()=>[o.originId,o.destinationId])));n<t.length;n++)o.properties[c[n-i]]=t[n];d.delete(o.id),s.push(o)}const i=o.writeToStore(s,m.dr,this.geographicLookup.get(e)?.name);this.sublayerCaches.has(e)||this.sublayerCaches.set(e,new Map),n&&!this.inclusionModeDefinition?.namedTypeDefinitions.has(e)&&this.inclusionModeDefinition?.namedTypeDefinitions.set(e,{useAllData:!1,members:new Map}),n&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members&&(this.inclusionModeDefinition.namedTypeDefinitions.get(e).members=new Map);const l=this.sublayerCaches.get(e);i.forEach((t=>{l?.set(t.attributes[m.dr],t),n&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.has(t.attributes[m.dr])&&(this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.set(t.attributes[m.dr],{id:t.attributes[m.dr]}),(0,a.tE)(this.memberIdTypeLookup,t.attributes[m.dr],(()=>new Set)).add(e))}))}const w=this.inclusionModeDefinition?.namedTypeDefinitions.get(e);if(w)for(const e of d)w.members?.delete(e)})().then((()=>{u(null)})).catch((e=>{"AbortError"===e.name?u(null):c(e)}))}));u.push(c),this._processingCacheUpdatesLookup.get(e)?.push(c)}if(await Promise.all(u),s?.signal?.aborted)throw(0,l.NK)()}removeFromLayer(e){const t=new Set,r=new Set(e.map((e=>e.id)));for(const r of e)t.add(r.typeName),1===this.memberIdTypeLookup.get(r.id)?.size?this.memberIdTypeLookup.delete(r.id):this.memberIdTypeLookup.get(r.id)?.delete(r.typeName),this.inclusionModeDefinition?.namedTypeDefinitions.forEach(((e,t)=>{t===r.typeName&&e.members?.has(r.id)&&e.members.delete(r.id)}));t.forEach((e=>{this.sublayerCaches.get(e)?.forEach(((t,n)=>{r.has(n)&&this.sublayerCaches.get(e)?.delete(n)}))}))}async retrieveDataFromService(e,t,r){const n=f.A.getInstance(),s=new Set,o=[];let a,l="",d=[];const p="relationship"===t.graphType,w=this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData,T=t.parentCompositeLayer.sublayerIdsCache.get(t.objectType.name);let I=!w&&T?Array.from(T).sort():null;if(this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData)this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData&&null!=e.objectIds&&(I=e.objectIds);else if(null!=e.objectIds&&I&&I.length>0){const t=e.objectIds;e.objectIds=I.filter((e=>t.includes(e)))}else if(null!=e.objectIds)I=e.objectIds;else{if(this.inclusionModeDefinition?.namedTypeDefinitions.has(t.objectType.name)&&(!this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members||this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members?.size<1))return e.objectIds=[],[];e.objectIds=I}if(null!=e.outFields){const r=e.outFields;r.includes("*")?t.fields.forEach((e=>{s.add(e.name)})):r.forEach((e=>{e!==m.dr&&e!==t.geometryFieldName&&s.add(e)}))}if(null!=e.geometry){const r=e.geometry;let n;const d=t.parentCompositeLayer.dataManager.knowledgeGraph.serviceDefinition,m=d?.spatialReference,f=d?.serviceCapabilities?.geometryCapabilities;let _=f?.geometryMaxBoundingRectangleSizeX,w=f?.geometryMaxBoundingRectangleSizeY;if("point"===r.type){let e=r;e.spatialReference?.isWGS84||(await(0,h.initializeProjection)(e.spatialReference,y.KK),e=(0,h.project)(e,y.KK)),n=new v.A({spatialReference:y.KK,xmin:e.x-1e-4,ymin:e.y-1e-4,xmax:e.x+1e-4,ymax:e.y+1e-4})}else r?.extent?.spatialReference&&!r.spatialReference?.isWGS84?(await(0,h.initializeProjection)(r.extent.spatialReference,y.KK),n=(0,h.project)(r.extent,y.KK)):n=r.extent;if(_&&w&&m){if(4326!==m.wkid){const e=new v.A({spatialReference:m,xmax:_,ymax:w}),t=(0,h.project)(e,y.KK);_=t.xmax,w=t.ymax}if(n.xmax-n.xmin>_)throw new i.A("knowledge-graph:layer-data-manager",`Extent x bounds should be within ${_}° latitude, limit exceeded`);if(n.ymax-n.ymin>w)throw new i.A("knowledge-graph:layer-data-manager",`Extent y bounds should be within ${w}° longitude, limit exceeded`)}if(null!=e.where&&"1=1"!==e.where){const r=await(0,u.G)(e.where.toUpperCase(),t.fieldsIndex);t.fields.forEach((e=>{r.fieldNames.includes(e.name)&&s.add(e.name)}))}l=p?`Match ()-[n:${t.objectType.name}]->() WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n), id(startNode(r)), id(endNode(r))`:`Match (n:${t.objectType.name}) WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n)`,t.geometryFieldName&&s.add(t.geometryFieldName),s.forEach((e=>{l+=`, n.${e}`,o.push(e)})),a=new b.A({openCypherQuery:l,bindParameters:{param_filter_geom:new c.A({rings:(0,g.Wq)(n)})}})}else{let r="";if(null!=e.where&&"1=1"!==e.where){const n=await(0,u.G)(e.where,t.fieldsIndex);t.fields.forEach((e=>{n.fieldNames.includes(e.name)&&s.add(e.name)}));const i=new Set(["column-reference","string","number","binary-expression"]),o=new Set(["=","<","<=","<>",">",">=","AND","OR","LIKE"]);let a=!1;const l=e=>{if("column-reference"===e.type)return`n.${e.column}`;if("string"===e.type)return`'${e.value}'`;if("number"===e.type)return`${e.value}`;if("binary-expression"===e.type&&i.has(e.left.type)&&i.has(e.right.type)&&o.has(e.operator))return`${l(e.left)} ${e.operator} ${l(e.right)}`;if("binary-expression"===e.type&&"LIKE"===e.operator){let t="";if("function"===e.left.type&&"column-reference"===e.left.args.value[0].type)t+=`lower(n.${e.left.args.value[0].column})`;else{if("column-reference"!==e.left.type)return a=!0,"";t+=`lower(n.${e.left.column})`}if(t+=" CONTAINS (","string"!==e.right.type)return a=!0,"";{let r=e.right.value;"%"===r.charAt(0)&&(r=r.slice(1)),"%"===r.charAt(r.length-1)&&(r=r.slice(0,-1)),t+=`'${r.toLowerCase()}')`}return t}return a=!0,""};r=l(n.parseTree),a&&(r="")}let n="";n=p?`Match ()-[n:${t.objectType.name}]->()`:`Match (n:${t.objectType.name})`;let i=!1;I&&(i=!0,n+=" WHERE ID(n) IN $ids"),r&&(n+=i?" AND":" WHERE",n+=` ${r}`),n+=" return ID(n)",p&&(n+=", id(startNode(n)), id(endNode(n))"),e.returnGeometry&&t.geometryFieldName&&s.add(t.geometryFieldName),s.forEach((e=>{n+=`, n.${e}`,o.push(e)})),a=new b.A(I?{openCypherQuery:n,bindParameters:{ids:I}}:{openCypherQuery:n})}const E=(await(0,_.executeQueryStreaming)(t.parentCompositeLayer.dataManager.knowledgeGraph,a,r)).resultRowsStream.getReader();for(;;){const{done:e,value:r}=await E.read();if(e)break;const s=[];for(let e=0;e<r.length;e++){const t=r[e];let n=0,i=0;const a={properties:{}};for(a.id=t[n],n++,i++,p&&(a.originId=t[n],n++,i++,a.destinationId=t[n],n++,i++);n<t.length;n++)a.properties[o[n-i]]=t[n];s.push(a)}d=d.concat(n.writeToStore(s,m.dr,t.parentCompositeLayer.dataManager.geographicLookup.get(t.objectType.name)?.name))}return d}_isEndEntitySpatial(e,t,r){for(const n of e??[])if(this.entityTypeNames.has(n)){const e=this.geographicLookup.get(n),s=e&&this.sublayerCaches.get(n)?.get(t.attributes[r]);if(e&&s?.attributes[e.name])return!0}return!1}_getNamedTypeIdMapFromNodeIds(e){const t=new Map;return e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const r of this.memberIdTypeLookup.get(e)){if(!this.entityTypeNames.has(r))return;t.has(r)?t.get(r)?.push(e):t.set(r,[e])}})),t}};(0,n._)([(0,d.MZ)()],T.prototype,"knowledgeGraph",void 0),(0,n._)([(0,d.MZ)()],T.prototype,"inclusionModeDefinition",void 0),(0,n._)([(0,d.MZ)()],T.prototype,"entityTypeNames",void 0),(0,n._)([(0,d.MZ)()],T.prototype,"relationshipTypeNames",void 0),(0,n._)([(0,d.MZ)()],T.prototype,"geographicLookup",void 0),(0,n._)([(0,d.MZ)()],T.prototype,"sublayerCaches",void 0),(0,n._)([(0,d.MZ)()],T.prototype,"nodeConnectionsLookup",void 0),(0,n._)([(0,d.MZ)()],T.prototype,"relationshipConnectionsLookup",void 0),(0,n._)([(0,d.MZ)()],T.prototype,"memberIdTypeLookup",void 0),T=(0,n._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphLayerDataManager")],T)},70643:(e,t,r)=>{r.d(t,{A:()=>X});var n=r(90237),s=(r(59456),r(13874)),i=(r(86162),r(52464),r(65345),r(42980),r(20917),r(92438),r(96576),r(93618),r(65494)),o=r(15036),a=r(4718),l=r(92071),u=(r(29953),r(10107)),d=(r(44208),r(53966),r(40608)),p=r(43937),c=r(35666),h=r(57251),y=r(16930),m=r(21325),f=r(4146),g=r(83221),_=r(19730),b=r(64714);r(87811);const w=(0,r(17036).p)(),v=e=>{let t=class extends e{constructor(){super(...arguments),this.fields=[],this.fieldsIndex=null}};return(0,n._)([(0,u.MZ)(w.fields)],t.prototype,"fields",void 0),(0,n._)([(0,u.MZ)(w.fieldsIndex)],t.prototype,"fieldsIndex",void 0),t=(0,n._)([(0,d.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayerBase")],t),t};var T=r(85342),I=r(63074),E=r(87718),M=r(76294),A=r(32756),x=r(54310),S=r(25036),N=r(82935),k=r(10873),L=r(13213),C=r(20437),R=r(30524),D=r(81457),O=r(39383),B=r(96184),F=r(22671),j=r(61956),P=r(30291),q=r(61322),Z=r(5443),G=r(39829),$=r(82799),U=r(86738),H=r(50498);function Q(e){if(!e.json)return e;e.json.write=Y(e.json.write);const t=e.json.origins;if(!t)return e;let r;for(r in t){const e=t[r];e&&(e.write=Y(e.write))}return e}function Y(e){return"object"==typeof e&&e?(!1!==e.enabled&&(e.overridePolicy=function(e){const{target:t,writer:r,overridePolicy:n,...s}=e;return function(e,t){const r=J.call(this,e,t);return r.enabled?{...s,...r}:r}}(e)),e):!0===e?z():e}function z(){return{overridePolicy:J}}function J(e,t){const r=!!this.geometryType;let n={enabled:r};return r&&(n={...n,...W.call(this,e,t)}),n}function W(e,t){return{ignoreOrigin:this.originIdOf(t)>c.Gr.DEFAULTS}}let V=class extends(v((0,M.J)((0,E.F)((0,I.dM)((0,A.fY)((0,N.e)((0,S.j)((0,x.J)((0,l.P)(f.A)))))))))){constructor(e){super(e),this.blendMode="normal",this.capabilities=(0,b.f)(!1,!1),this.charts=null,this.definitionExpression=null,this.displayField="",this.effect=null,this.elevationInfo=null,this.featureEffect=null,this.graphType=null,this.labelsVisible=!0,this.labelingInfo=null,this.layerType=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.objectIdField=T.dr,this.objectType=null,this.opacity=1,this.orderBy=null,this.parent=null,this.parentCompositeLayer=null,this.persistenceEnabled=!0,this.popupEnabled=!0,this.popupTemplate=null,this.refreshInterval=0,this.source={openPorts:()=>this.load().then((()=>{const e=new MessageChannel;return new q.default(e.port1,{channel:e,client:{queryFeatures:(e,t={})=>{const r=j.A.fromJSON(e);return this.queryFeaturesJSON(r,t)}}}),[e.port2]}))},this.type="knowledge-graph-sublayer",this.useViewTime=!0,this.visible=!0}get defaultPopupTemplate(){return this.createPopupTemplate()}set featureReduction(e){const t=this._normalizeFeatureReduction(e);this._set("featureReduction",t)}get fields(){const e=[];return this.objectType?.properties?.forEach((t=>{const r="esriFieldTypeOID"===t.fieldType?"esriFieldTypeInteger":t.fieldType;e.push(C.A.fromJSON({name:t.name,type:r,alias:t.alias,defaultValue:t.defaultValue,editable:t.editable,nullable:t.nullable}))})),e.push(C.A.fromJSON({name:this.objectIdField,type:"esriFieldTypeString",alias:this.objectIdField,editable:!1}),C.A.fromJSON({name:T.M1,type:"esriFieldTypeInteger",alias:T.M1,editable:!1}),C.A.fromJSON({name:T.BL,type:"esriFieldTypeInteger",alias:T.BL,editable:!1})),e}get geometryType(){if("link-chart"===this.parentCompositeLayer?.type)return"relationship"===this.graphType?"polyline":"point";const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.geometryType;return t&&"esriGeometryNull"!==t?H.g.fromJSON(t):null}get geometryFieldName(){if("link-chart"===this.parentCompositeLayer?.type)return T.T1;const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name);return e?.name??null}get graphTypeName(){return this.objectType?.name}get hasM(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,r=t?this.objectType?.properties?.[t]:null;return r?.hasM??!1}get hasZ(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,r=t?this.objectType?.properties?.[t]:null;return r?.hasZ??!1}set renderer(e){(0,R.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){return this._isOverridden("renderer")?this._get("renderer"):"link-chart"===this.parentCompositeLayer?.type?"relationship"===this.graphType?(0,i.r)((0,b.F0)(H.g.toJSON("polyline")).renderer):(0,i.r)((0,b.F0)(H.g.toJSON("point")).renderer):(0,i.r)((0,b.F0)(H.g.toJSON(this.geometryType)).renderer)}get spatialReference(){return this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel?.spatialReference??y.A.WGS84}set timeInfo(e){this._set("timeInfo",e)}get title(){return this._isOverridden("title")?this._get("title"):this.graphTypeName}set title(e){this._set("title",e)}writeTitle(e,t){t.title=e??"Layer"}createPopupTemplate(e){return(0,P.tn)(this,e)}createQuery(){return new j.A({where:"1=1",outFields:["*"]})}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){return null}async queryFeatures(e,t){const{resolvedQuery:r,queryEngine:n}=await this._setupQueryObjects(e),s=F.A.fromJSON(await n.executeQuery(r.toJSON(),t?.signal));return s.features.forEach((e=>{e.sourceLayer=this})),s}async queryFeaturesJSON(e,t){const{resolvedQuery:r,queryEngine:n}=await this._setupQueryObjects(e);return await n.executeQuery(r.toJSON(),t?.signal)}async queryFeatureCount(e,t){const{resolvedQuery:r,queryEngine:n}=await this._setupQueryObjects(e);return n.executeQueryForCount(r.toJSON(),t?.signal)}async queryExtent(e={},t){const r={...e,returnGeometry:!0},{resolvedQuery:n,queryEngine:s}=await this._setupQueryObjects(r),i=await s.executeQueryForExtent(n.toJSON(),t?.signal);let o;return o=null!=i.extent?.xmin&&null!=i.extent?.xmax&&null!=i.extent?.ymin&&null!=i.extent?.ymax?new Z.A(i.extent):new Z.A,{count:i.count,extent:o}}async queryObjectIds(e,t){const r=j.A.from(e);let n;if("link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)n=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(r,this,t);n=this.loadQueryEngine(e)}return n.executeQueryForIds(r.toJSON(),t?.signal)}loadQueryEngine(e){const t=new g.A({geometryType:H.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ}),r=new _.do({fieldsIndex:this.fieldsIndex.toJSON(),geometryType:H.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ,objectIdField:this.objectIdField,spatialReference:this.spatialReference.toJSON(),timeInfo:this.timeInfo?.toJSON(),featureStore:t});return r.featureStore.addMany(e),r}async refreshCachedQueryEngine(){const e=await this.parentCompositeLayer.dataManager.getData(new j.A({where:"1=1",outFields:[T.dr]}),this);this._cachedQueryEngine=this.loadQueryEngine(e)}load(e){return this.addResolvingPromise(this.parent.load(e).then((()=>(0,R.sv)(this.timeInfo,this.fieldsIndex)))),Promise.resolve(this)}async _setupQueryObjects(e,t){const r=j.A.from(e),n=r.geometry;if(n&&!n.spatialReference?.isWGS84&&(await(0,h.initializeProjection)(n.spatialReference,m.KK),r.geometry=(0,h.project)(n instanceof G.A||n instanceof $.A||n instanceof U.A?n:n.extent,m.KK)),"link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)return{resolvedQuery:r,queryEngine:this._cachedQueryEngine};const s=await this.parentCompositeLayer.dataManager.getData(r,this,t);return{resolvedQuery:r,queryEngine:this.loadQueryEngine(s)}}};(0,n._)([(0,u.MZ)(Q((0,a.o8)(I.sU)))],V.prototype,"blendMode",void 0),(0,n._)([(0,u.MZ)()],V.prototype,"capabilities",void 0),(0,n._)([(0,u.MZ)({json:{origins:{"web-scene":{write:!1}},write:z()}})],V.prototype,"charts",void 0),(0,n._)([(0,u.MZ)({readOnly:!0})],V.prototype,"defaultPopupTemplate",null),(0,n._)([(0,u.MZ)({type:String,json:{origins:{service:{read:!1}},name:"layerDefinition.definitionExpression",write:{ignoreOrigin:!0}}})],V.prototype,"definitionExpression",void 0),(0,n._)([(0,u.MZ)()],V.prototype,"displayField",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(I.LF)))],V.prototype,"effect",void 0),(0,n._)([(0,u.MZ)()],V.prototype,"elevationInfo",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(E.Y)))],V.prototype,"featureEffect",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(L.d)))],V.prototype,"featureReduction",null),(0,n._)([(0,u.MZ)()],V.prototype,"fields",null),(0,n._)([(0,u.MZ)()],V.prototype,"geometryType",null),(0,n._)([(0,u.MZ)()],V.prototype,"geometryFieldName",null),(0,n._)([(0,u.MZ)({type:["entity","relationship"],nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],V.prototype,"graphType",void 0),(0,n._)([(0,u.MZ)({type:String,nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],V.prototype,"graphTypeName",null),(0,n._)([(0,u.MZ)()],V.prototype,"hasM",null),(0,n._)([(0,u.MZ)()],V.prototype,"hasZ",null),(0,n._)([(0,u.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],V.prototype,"id",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(k.kF)))],V.prototype,"labelsVisible",void 0),(0,n._)([(0,u.MZ)({type:[D.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:O.w,write:z()}})],V.prototype,"labelingInfo",void 0),(0,n._)([(0,u.MZ)({readOnly:!0,json:{read:!1,write:{writer(e,t){switch(this.parentCompositeLayer.type){case"link-chart":t.layerType="LinkChartSubLayer";break;case"knowledge-graph":t.layerType=this.geometryType?"KnowledgeGraphSubLayer":"KnowledgeGraphSubTable"}},isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],V.prototype,"layerType",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(k.fV)))],V.prototype,"legendEnabled",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(k.hG)))],V.prototype,"maxScale",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(k.hn)))],V.prototype,"minScale",void 0),(0,n._)([(0,u.MZ)()],V.prototype,"objectIdField",void 0),(0,n._)([(0,u.MZ)()],V.prototype,"objectType",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(k.ke)))],V.prototype,"opacity",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(A.ne)))],V.prototype,"orderBy",void 0),(0,n._)([(0,u.MZ)({clonable:!1})],V.prototype,"parent",void 0),(0,n._)([(0,u.MZ)()],V.prototype,"parentCompositeLayer",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(k.M6)))],V.prototype,"popupEnabled",void 0),(0,n._)([(0,u.MZ)({type:s.A,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],V.prototype,"popupTemplate",void 0),(0,n._)([(0,u.MZ)({type:Number,json:{write:{overridePolicy:W}}})],V.prototype,"refreshInterval",void 0),(0,n._)([(0,u.MZ)({types:o.H,json:{name:"layerDefinition.drawingInfo.renderer",write:z()}})],V.prototype,"renderer",null),(0,n._)([(0,u.MZ)()],V.prototype,"source",void 0),(0,n._)([(0,u.MZ)()],V.prototype,"spatialReference",null),(0,n._)([(0,u.MZ)({type:B.A,json:{name:"layerDefinition.timeInfo",write:!0,origins:{"web-document":{name:"layerDefinition.timeInfo",read:!0,write:!0},"portal-item":{name:"layerDefinition.timeInfo",read:!0,write:!0}}}})],V.prototype,"timeInfo",null),(0,n._)([(0,u.MZ)({type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],V.prototype,"title",null),(0,n._)([(0,p.K)("title")],V.prototype,"writeTitle",null),(0,n._)([(0,u.MZ)({json:{read:!1}})],V.prototype,"type",void 0),(0,n._)([(0,u.MZ)(Q((0,a.o8)(N.B)))],V.prototype,"useViewTime",void 0),(0,n._)([(0,u.MZ)({type:Boolean,json:{name:"visibility",write:z()}})],V.prototype,"visible",void 0),V=(0,n._)([(0,d.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayer")],V);const X=V},69860:(e,t,r)=>{r.d(t,{A:()=>a}),r(59456);var n=r(90708),s=r(43334),i=r(85342),o=r(65864);class a{constructor(){this._featureLookup=new Map}static getInstance(){return a.instance||(a.instance=new a),a.instance}static resetInstance(){a.instance&&(a.instance=null)}deleteFromStore(e){e.forEach((e=>{this._featureLookup.delete(e)}))}readFromStoreByList(e){const t=[];return e.forEach((e=>{const r=this.readFromStoreById(e);r&&t.push(r)})),t}readFromStoreById(e){return this._featureLookup.get(e)??null}writeToStore(e,t,r){const a=[];return e.forEach((e=>{if(!e?.id)return;e.properties||(e.properties=[]);let l,u=null;if(r&&e.properties[r]&&(u=(0,n.Ux)(e.properties[r])),"originId"in e&&"destinationId"in e&&(e.properties[i.Cz]=e.originId,e.properties[i.KQ]=e.destinationId),e.properties[t]=e.id,e.id&&this._featureLookup.has(e.id)&&this._featureLookup.get(e.id).attributes){const n=this._featureLookup.get(e.id),i=JSON.parse(JSON.stringify(Object.assign(n.attributes,e.properties)));r&&e.properties[r]&&(i[r]=(0,o.rS)(e.properties[r])),l=new s.Om(u?JSON.parse(JSON.stringify(u)):n?.geometry?JSON.parse(JSON.stringify(n.geometry)):null,i,null,e.properties[t])}else l=new s.Om(u?JSON.parse(JSON.stringify(u)):null,e.properties,null,e.properties[t]);this._featureLookup.set(`${e.typeName?`${e.typeName}__${e.id}`:e.id}`,l),a.push(l)})),a}}},85342:(e,t,r)=>{r.d(t,{BL:()=>u,Cz:()=>i,KQ:()=>o,M1:()=>l,T1:()=>a,dr:()=>s,qN:()=>c});var n=r(71402);const s="ESRI__ID",i="ESRI__OriginID",o="ESRI__DestID",a="ESRI__LayoutGeometry",l="ESRI__AggregationCount",u="LC.ESRI__IsSpatial",d={initializeLayersFromClientData:async(e,t,r)=>{if(t||(t=[...e.layers,...e.tables].map((e=>e.graphTypeName))),0===t?.length)return;const s=new Map;for(const r of t)s.set(r,p(e,r));const i=await(0,n.fetchClientDataAtKeys)(e.dataManager.knowledgeGraph,Array.from(s.values()),{requestOptions:{signal:r?.signal}});for(const t of[...e.layers,...e.tables]){const r=t.objectType.name;if(null==r)continue;const n=i.get(p(e,r));if(n){const e=JSON.parse(n);null===e||"object"!=typeof e||e.hasOwnProperty("showLabels")||(e.showLabels=!1),t.read(e,{origin:"service"})}}}},p=(e,t)=>"knowledge-graph"===e.type?`${t}/Map`:`${t}/LinkChart/LinkChartSubLayer`;async function c(e,t,r){return d.initializeLayersFromClientData(e,t,r)}},30504:(e,t,r)=>{r.d(t,{k5:()=>u,aq:()=>l,Wq:()=>d}),r(59456),r(52106),r(61147);var n=r(49186),s=(r(94194),r(85342),r(69860),r(8460),r(66552));(0,s.O)()({none:"none",startAndEnd:"start-and-end",startOnly:"start-only"}),(0,s.O)()({absoluteValue:"absolute-value",multiplier:"multiplier"});const i=new Map([["basic-grid","basic-grid"],["geographic-organic-standard","geographic-organic-standard"],["hierarchical-bottom-to-top","hierarchical-bottom-to-top"],["hierarchical-top-to-bottom","hierarchical-bottom-to-top"],["organic-community","organic-community"],["organic-fusiform","organic-standard"],["organic-leaf-circle","organic-standard"],["organic-standard","organic-standard"],["radial-node-centric","radial-root-centric"],["radial-root-centric","radial-root-centric"],["tree-bottom-to-top","tree-left-to-right"],["tree-left-to-right","tree-left-to-right"],["tree-right-to-left","tree-left-to-right"],["tree-top-to-bottom","tree-left-to-right"],["chronological-mono-timeline","chronological-mono-timeline"],["chronological-multi-timeline","chronological-multi-timeline"]]);var o=r(71402),a=r(42538);async function l(e,t,r){const n=[],s=function(e,t){const r=new Map;if(t.dataModel?.relationshipTypes)for(const e of t.dataModel.relationshipTypes)e.name&&r.set(e.name,[]);for(const t of e)r.has(t.typeName)&&r.get(t.typeName)?.push(t.id);return r}(e,t),i={},l=[];for(const[e,t]of s){if(t.length<1)continue;const r=`${e}_ids`;i[r]=t,l.push(`MATCH (n)-[r:${e}]->(m) WHERE id(r) in $${r} RETURN id(n), labels(n)[0], id(m), labels(m)[0]`)}if(0===l.length)return[];const u=l.join(" UNION "),d=new a.A({openCypherQuery:u,bindParameters:i}),p=(await(0,o.executeQueryStreaming)(t,d,r?.requestOptions)).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await p.read();if(e)break;for(const e of t)n.push({id:e[0],typeName:e[1]}),n.push({id:e[2],typeName:e[3]})}return n}r(40863),r(82799),r(94985),r(39829),r(68249),r(86738);const u=e=>i.get(e)??"radial-root-centric";function d(e){if(!e.spatialReference.isWGS84)throw new n.A("knowledge-graph:layer-support-utils","The utilsExtentToInBoundsRings function only supports WGS84 spatial references.");return e.clone().normalize().map((e=>[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]]))}},82935:(e,t,r)=>{r.d(t,{B:()=>h,e:()=>y});var n=r(90237),s=r(10107),i=(r(44208),r(53966),r(87811),r(36005)),o=r(40608),a=r(89317),l=r(30524),u=r(96184),d=r(73133),p=r(79677),c=r(10184);const h={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:a.K}}},y=e=>{let t=class extends e{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const r=t.timeInfo.exportOptions;if(!r)return null;const n=r.timeOffset,s=d.j.fromJSON(r.timeOffsetUnits);return n&&s?new c.A({value:n,unit:s}):null}set timeInfo(e){(0,l.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,n._)([(0,s.MZ)({type:p.A,json:{write:!1}})],t.prototype,"timeExtent",void 0),(0,n._)([(0,s.MZ)({type:c.A})],t.prototype,"timeOffset",void 0),(0,n._)([(0,i.w)("service","timeOffset",["timeInfo.exportOptions"])],t.prototype,"readOffset",null),(0,n._)([(0,s.MZ)({value:null,type:u.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],t.prototype,"timeInfo",null),(0,n._)([(0,s.MZ)(h)],t.prototype,"useViewTime",void 0),t=(0,n._)([(0,o.$)("esri.layers.mixins.TemporalLayer")],t),t}},96184:(e,t,r)=>{r.d(t,{A:()=>m});var n=r(90237),s=r(69540),i=r(25482),o=r(10107),a=(r(44208),r(53966),r(87811),r(36005)),l=r(40608),u=r(43937),d=r(79677),p=r(10184),c=r(56400);function h(e,t){return p.A.fromJSON({value:e,unit:t})}let y=class extends(s.A.ClonableMixin(i.A)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?d.A.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?h(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?h(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,n._)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],y.prototype,"cumulative",void 0),(0,n._)([(0,o.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"endField",void 0),(0,n._)([(0,o.MZ)({type:d.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"fullTimeExtent",void 0),(0,n._)([(0,a.w)("fullTimeExtent",["timeExtent"])],y.prototype,"readFullTimeExtent",null),(0,n._)([(0,u.K)("fullTimeExtent")],y.prototype,"writeFullTimeExtent",null),(0,n._)([(0,o.MZ)({type:Boolean,json:{write:!0}})],y.prototype,"hasLiveData",void 0),(0,n._)([(0,o.MZ)({type:p.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"interval",void 0),(0,n._)([(0,a.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],y.prototype,"readInterval",null),(0,n._)([(0,u.K)("interval")],y.prototype,"writeInterval",null),(0,n._)([(0,o.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"startField",void 0),(0,n._)([(0,o.MZ)((0,c.P6)("timeReference",!0))],y.prototype,"timeZone",void 0),(0,n._)([(0,o.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"trackIdField",void 0),(0,n._)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],y.prototype,"useTime",void 0),(0,n._)([(0,o.MZ)({type:[Date],json:{read:!1}})],y.prototype,"stops",void 0),y=(0,n._)([(0,l.$)("esri.layers.support.TimeInfo")],y);const m=y},4071:(e,t,r)=>{r.d(t,{$:()=>n,P:()=>s});const n={supportsDate:!1,supportsFixedInterval:!1,supportsAutoInterval:!1,supportsFixedBoundaries:!1,supportedStatistics:void 0},s={analytics:{supportsCacheHint:!1},attachment:{supportsContentType:!1,supportsExifInfo:!1,supportsKeywords:!1,supportsName:!1,supportsSize:!1,supportsCacheHint:!1,supportsResize:!1},data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:!1},editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsAsyncApplyEdits:!1,zDefault:void 0},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryBins:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:n,query:{maxRecordCount:0,maxRecordCountFactor:0,standardMaxRecordCount:0,supportsCacheHint:!1,supportsCentroid:!1,supportsCompactGeometry:!1,supportsCurrentUser:!1,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsReturnMesh:!1,supportsSqlExpression:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsTrueCurve:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsStatistics:!1,tileMaxRecordCount:0}}},17036:(e,t,r)=>{r.d(t,{p:()=>l});var n=r(44208),s=r(53966),i=r(20437),o=r(95466),a=r(30524);function l(){return{fields:{type:[i.A],value:null,set:function(e){if(e&&(0,n.A)("big-integer-warning-enabled")){const t=e.filter((e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8));if(t.length){const e=t.map((e=>`'${e.name}'`)).join(", ");s.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${Number.MAX_SAFE_INTEGER} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return o.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){const e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(const t of e){const r=this.fieldsIndex?.has(t);r||s.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,a.DB)(this.fieldsIndex,e)}}}}},8460:(e,t,r)=>{r.d(t,{$C:()=>f,Hh:()=>o,J:()=>u,JT:()=>l,Tu:()=>y,Wg:()=>m,Xq:()=>_,i6:()=>b,pM:()=>h,tx:()=>a,vJ:()=>g});var n=r(2741);let s,i=null;function o(){return s||(s=r.e(3666).then(r.bind(r,3666)).then((e=>e.l)).then((({default:e})=>e({locateFile:e=>(0,n.s)(`esri/libs/linkchartlayout/${e}`)}))).then((e=>{!function(e){i=e}(e)})),s)}var a,l,u,d,p,c,h,y,m,f,g,_,b,w,v;function T(e){const t=Object.keys(d).filter((e=>isNaN(parseInt(e,10)))).indexOf(e.timeDirection);let r=p.startAndEnd;switch(e.eventsTicksVisualization){case"start-only":r=p.startOnly;break;case"none":r=p.none}return{timeDirection:{value:t>-1?t:d.right},timeBannerUTCOffsetInMinutes:e.timeBannerUTCOffsetInMinutes,eventsTicksVisualization:{value:r},showDurationLineForNonZeroDurationEntityEvents:e.showDurationLineForNonZeroDurationEntityEvents,durationLineWidth:e.durationLineWidth,entityPositionAtDurationRatio:e.entityPositionAtDurationRatio,showNonZeroDurationIntervalBounds:e.showNonZeroDurationIntervalBounds,separateTimeOverlaps:e.separateTimeOverlaps,separateTimelineOverlaps:e.separateTimelineOverlaps,moveFirstBends:e.moveFirstBends,secondBendRatio:e.secondBendRatio,lineSeparationMultiplier:e.lineSeparationMultiplier,spaceSeparatedLinesEvenly:e.spaceSeparatedLinesEvenly,useBezierCurves:e.useBezierCurves,separatedLineShapeRatio:e.separatedLineShapeRatio}}function I(e,t,r,n,s,o){const a=r.length,u=s.length,d=Float64Array.BYTES_PER_ELEMENT,p=Uint32Array.BYTES_PER_ELEMENT,c=Uint8Array.BYTES_PER_ELEMENT,h=16+a*(c+2*d)+u*(2*p),y=i._malloc(h);try{const c=y+16-y%16,h=c+a*d,m=h+a*d,f=m+u*p,g=f+u*p,_=()=>[i.HEAPF64.subarray(c>>3,(c>>3)+a),i.HEAPF64.subarray(h>>3,(h>>3)+a),i.HEAPU32.subarray(m>>2,(m>>2)+u),i.HEAPU32.subarray(f>>2,(f>>2)+u),i.HEAPU8.subarray(g,g+a)],[b,w,v,T,I]=_();b.set(r),w.set(n),v.set(s),T.set(o),I.set(t);const E=e(a,g,c,h,u,m,f);let M=null,A=null;if(E.value===l.Success){const e=i.getLayoutLinksTypes(),t=i.getLayoutLinksVerticesEndIndices(),r=i.getLayoutLinksVertices(),n=i.countLayoutLinksVertices();!u||e&&t?n&&!r?E.value=l.Error:(M={types:new Uint8Array(i.HEAPU8.subarray(e,e+u)),vertexEndIndex:new Uint32Array(i.HEAPU32.subarray(t>>2,(t>>2)+u)),vertices:new Float64Array(i.HEAPF64.subarray(r>>3,(r>>3)+2*n))},A=i.getAuxiliaryGraphicElements()):E.value=l.Error}const[x,S,N,k,L]=_();return r.set(x),n.set(S),s.set(N),o.set(k),t.set(L),{status:E.value,links:M,graphics:A}}finally{i._free(y),i.cleanupLayout()}}(c=a||(a={}))[c.None=0]="None",c[c.IsMovable=1]="IsMovable",c[c.IsGeographic=2]="IsGeographic",c[c.IsRoot=4]="IsRoot",c[c.IsOld=8]="IsOld",function(e){e[e.Success=0]="Success",e[e.Error=1]="Error",e[e.Canceled=2]="Canceled"}(l||(l={})),function(e){e[e.Regular=0]="Regular",e[e.Curved=1]="Curved",e[e.Recursive=2]="Recursive"}(u||(u={})),function(e){e[e.right=0]="right",e[e.left=1]="left",e[e.top=2]="top",e[e.bottom=3]="bottom"}(d||(d={})),function(e){e[e.none=0]="none",e[e.startOnly=1]="startOnly",e[e.startAndEnd=2]="startAndEnd"}(p||(p={})),function(e){e.getMinIdealEdgeLength=function(){return i.getMinIdealEdgeLength()},e.apply=function(e,t,r,n,s,o,a=2,l=1,u=-1){return I(((t,r,n,s,o,d,p)=>i.applyForceDirectedLayout(e,t,r,n,s,o,d,p,a,l,u)),t,r,n,s,o)}}(h||(h={})),function(e){e.apply=function(e,t,r,n,s,o,a=2,l=1,u=-1){return I(((t,r,n,s,o,d,p)=>i.applyCommunityLayout(e,t,r,n,s,o,d,p,a,l,u)),t,r,n,s,o)}}(y||(y={})),function(e){e.apply=function(e,t,r,n,s,o){return I(((t,r,n,s,o,a,l)=>i.applySimpleLayout(e,t,r,n,s,o,a,l)),t,r,n,s,o)}}(m||(m={})),function(e){e.apply=function(e,t,r,n,s,o){return I(((t,r,n,s,o,a,l)=>i.applyHierarchicalLayout(e,t,r,n,s,o,a,l)),t,r,n,s,o)}}(f||(f={})),function(e){e.apply=function(e,t,r,n,s,o){return I(((t,r,n,s,o,a,l)=>i.applyRadialTreeLayout(e,t,r,n,s,o,a,l)),t,r,n,s,o)}}(g||(g={})),function(e){e.apply=function(e,t,r,n,s,o){return I(((t,r,n,s,o,a,l)=>i.applySmartTreeLayout(e,t,r,n,s,o,a,l)),t,r,n,s,o)}}(_||(_={})),function(e){e.apply=function(e,t,r,n,s,o,a,u,c,h,y,m){const f={timeDirection:d.right,timeBannerUTCOffsetInMinutes:0,eventsTicksVisualization:p.startAndEnd,showDurationLineForNonZeroDurationEntityEvents:!0,durationLineWidth:5,entityPositionAtDurationRatio:1,showNonZeroDurationIntervalBounds:!1,separateTimeOverlaps:!0,separateTimelineOverlaps:!0,moveFirstBends:!0,secondBendRatio:.3,lineSeparationMultiplier:1,spaceSeparatedLinesEvenly:!1,useBezierCurves:!1,separatedLineShapeRatio:0};return I(((t,r,n,a,u,d,p)=>{if(s.length!==t)return{value:l.Error};if(o.length!==t)return{value:l.Error};if(c.length!==u)return{value:l.Error};if(h.length!==u)return{value:l.Error};const g=Float64Array.BYTES_PER_ELEMENT,_=16,b=i._malloc(_+t*g),w=i._malloc(_+t*g),v=i._malloc(_+u*g),I=i._malloc(_+u*g),E=b+_-b%_,M=w+_-w%_,A=v+_-v%_,x=I+_-I%_;try{i.HEAPF64.subarray(E>>3,(E>>3)+t).set(s),i.HEAPF64.subarray(M>>3,(M>>3)+t).set(o),i.HEAPF64.subarray(A>>3,(A>>3)+u).set(c),i.HEAPF64.subarray(x>>3,(x>>3)+u).set(h);const l=T(Object.assign(f,m));return i.applyChronologicalLayout(e,t,r,n,a,E,M,u,d,p,A,x,y,l)}finally{i._free(b),i._free(w),i._free(v),i._free(I)}}),t,r,n,a,u)}}(b||(b={})),function(e){e[e.Undirected=0]="Undirected",e[e.Directed=1]="Directed",e[e.Reversed=2]="Reversed"}(w||(w={})),function(e){e[e.ByCC_Raw=0]="ByCC_Raw",e[e.ByCC_NormalizeGlobally=1]="ByCC_NormalizeGlobally",e[e.ByCC_NormalizeByCC=2]="ByCC_NormalizeByCC"}(v||(v={}))},73133:(e,t,r)=>{r.d(t,{j:()=>n});const n=(0,r(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},25927:(e,t,r)=>{r.d(t,{A:()=>u});var n=r(90237),s=(r(59456),r(10107)),i=(r(44208),r(53966),r(87811),r(40608)),o=r(54238),a=r(86738);let l=class extends o.A{constructor(e){super(e),this.layoutGeometry=null}};(0,n._)([(0,s.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,n._)([(0,i.$)("esri.rest.knowledgeGraph.Entity")],l);const u=l},54238:(e,t,r)=>{r.d(t,{A:()=>l});var n=r(90237),s=r(10107),i=(r(44208),r(53966),r(87811),r(40608)),o=r(77901);let a=class extends o.A{constructor(e){super(e),this.typeName=null,this.id=null}};(0,n._)([(0,s.MZ)({type:String,json:{write:!0}})],a.prototype,"typeName",void 0),(0,n._)([(0,s.MZ)({type:String,json:{write:!0}})],a.prototype,"id",void 0),a=(0,n._)([(0,i.$)("esri.rest.knowledgeGraph.GraphNamedObject")],a);const l=a},77901:(e,t,r)=>{r.d(t,{A:()=>l});var n=r(90237),s=r(25482),i=r(10107),o=(r(44208),r(53966),r(87811),r(40608));let a=class extends s.A{constructor(e){super(e),this.properties=null}};(0,n._)([(0,i.MZ)({json:{write:!0}})],a.prototype,"properties",void 0),a=(0,n._)([(0,o.$)("esri.rest.knowledgeGraph.GraphObject")],a);const l=a},42538:(e,t,r)=>{r.d(t,{A:()=>d});var n=r(90237),s=r(10107),i=(r(44208),r(53966),r(87811),r(40608)),o=r(69622);let a=class extends o.A{constructor(e){super(e),this.openCypherQuery=""}};(0,n._)([(0,s.MZ)()],a.prototype,"openCypherQuery",void 0),a=(0,n._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQuery")],a);const l=a;let u=class extends l{constructor(e){super(e),this.bindParameters=null,this.bindGeometryQuantizationParameters=null,this.outputQuantizationParameters=null,this.outputSpatialReference=null,this.provenanceBehavior=null}};(0,n._)([(0,s.MZ)()],u.prototype,"bindParameters",void 0),(0,n._)([(0,s.MZ)()],u.prototype,"bindGeometryQuantizationParameters",void 0),(0,n._)([(0,s.MZ)()],u.prototype,"outputQuantizationParameters",void 0),(0,n._)([(0,s.MZ)()],u.prototype,"outputSpatialReference",void 0),(0,n._)([(0,s.MZ)()],u.prototype,"provenanceBehavior",void 0),u=(0,n._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQueryStreaming")],u);const d=u},40662:(e,t,r)=>{r.d(t,{A:()=>a});var n=r(90237),s=(r(53966),r(44208),r(87811),r(49186),r(40608)),i=r(77901);let o=class extends i.A{constructor(e){super(e)}};o=(0,n._)([(0,s.$)("esri.rest.knowledgeGraph.ObjectValue")],o);const a=o},42095:(e,t,r)=>{r.d(t,{A:()=>u});var n=r(90237),s=r(25482),i=r(10107),o=(r(44208),r(53966),r(87811),r(40608)),a=r(77901);let l=class extends s.A{constructor(e){super(e),this.path=null}};(0,n._)([(0,i.MZ)({type:[a.A],json:{write:!0}})],l.prototype,"path",void 0),l=(0,n._)([(0,o.$)("esri.rest.knowledgeGraph.Path")],l);const u=l},23150:(e,t,r)=>{r.d(t,{A:()=>u});var n=r(90237),s=(r(59456),r(10107)),i=(r(44208),r(53966),r(87811),r(40608)),o=r(54238),a=r(82799);let l=class extends o.A{constructor(e){super(e),this.originId=null,this.destinationId=null,this.layoutGeometry=null}};(0,n._)([(0,s.MZ)({type:String,json:{write:!0}})],l.prototype,"originId",void 0),(0,n._)([(0,s.MZ)({type:String,json:{write:!0}})],l.prototype,"destinationId",void 0),(0,n._)([(0,s.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,n._)([(0,i.$)("esri.rest.knowledgeGraph.Relationship")],l);const u=l},10184:(e,t,r)=>{r.d(t,{A:()=>c});var n=r(90237),s=r(69540),i=r(25482),o=r(88930),a=r(10107),l=(r(44208),r(53966),r(87811),r(93223)),u=r(40608),d=r(73133);let p=class extends(s.A.ClonableMixin(i.A)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,n._)([(0,l.e)(d.j,{nonNullable:!0})],p.prototype,"unit",void 0),(0,n._)([(0,a.MZ)({type:Number,json:{write:!0},nonNullable:!0})],p.prototype,"value",void 0),p=(0,n._)([(0,u.$)("esri.time.TimeInterval")],p);const c=p}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2083],{67996:(e,t,r)=>{r.d(t,{cZ:()=>D,XW:()=>j,fe:()=>O});var s,n,i=r(78888),o=r(49186),a=r(91869),l=(r(90708),r(92722)),u=(r(59456),r(16930));class p{constructor(){this.version="",this.queryResult=new d}}class d{constructor(){this.featureResult=new c}}class c{constructor(){this.objectIdFieldName="",this.uniqueIdField=new h,this.globalIdFieldName="",this.geohashFieldName="",this.geometryProperties=new y,this.geometryType=null,this.spatialReference=new u.A,this.exceededTransferLimit=!1,this.hasZ=!1,this.hasM=!1,this.transform=new m,this.fields=[],this.fieldNameToAttributeIndexMap={},this.values=[],this.features=[],this.geometryFields=[]}}class h{constructor(){this.name="",this.isSystemMaintained=!1}}class y{constructor(){this.shapeAreaFieldName="",this.shapeLengthFieldName="",this.units=""}}class m{constructor(){this.quantizeOriginPosition="upperLeft",this.scale=new f,this.translate=new g}}class f{constructor(){this.xScale=0,this.yScale=0,this.mScale=0,this.zScale=0}}class g{constructor(){this.xTranslate=0,this.yTranslate=0,this.mTranslate=0,this.zTranslate=0}}class _{constructor(){this.name="",this.fieldType="esriFieldTypeString",this.alias="",this.sqlType="sqlTypeVarchar",this.domain="",this.defaultValue=""}}class b{constructor(){this.attributes=[],this.compressedGeometry=new w,this.centroid=new w,this.aggregateGeometries=[]}}class w{constructor(){this.geometryType=null,this.lengths=[],this.coords=[]}}(n=s||(s={})).ELEMENTUID="ELEMENTUID",n.TYPENAME="TYPENAME";const v=[s.ELEMENTUID,s.TYPENAME];var T,I;!function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME"}(T||(T={})),function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME",e[e.FROMUID=2]="FROMUID",e[e.TOUID=3]="TOUID"}(I||(I={}));var E,M,A,x,S=r(45724),N=r(35448);function k(e){const t=new w;t.geometryType=N.bV[e.geometry_type.value];const r=[],s=[];for(let t=0;t<e.lengths.length;t++)r.push(e.lengths[t]);for(let t=0;t<e.coords.length;t++)s.push(e.coords[t]);return t.lengths=r,t.coords=s,t}function L(e){const t=new _;return t.name=e.name,t.alias=e.alias,t.fieldType=N.r5[e.field_type.value],t.sqlType=A[e.sql_type.value],t.domain=e.domain,t.defaultValue=e.default_value,t}function C(e){const t=L(e);return t.geometryType=N.bV[e.geometry_type.value],t}function R(e){const t=new m;t.quantizeOriginPosition=M[e.quantizeOriginPosition.value];const r=t.scale,s=e.scale;r.xScale=s.xScale,r.yScale=s.yScale,r.mScale=s.mScale,r.zScale=s.zScale;const n=t.translate,i=e.translate;return n.xTranslate=i.xTranslate,n.yTranslate=i.yTranslate,n.mTranslate=i.mTranslate,n.zTranslate=i.zTranslate,t}async function D(e,t){t??=!1;const r={generateAllSublayers:t,namedTypeDefinitions:new Map};return await async function(e){const t=await(0,i.A)(e,{responseType:"array-buffer"}),r=await t.data;return async function(e){const t=new((await(0,S.I)()).MapOfObjectIdentifierSetsDecoder),r=t.decode(new Uint8Array(e)),s=new Map;if(0!==r.error_code)throw new o.A("knowledge-graph:layer-support-utils",r.error_message);const n=t.get_map_of_identifier_sets(),i=n.keys,a=i.size();for(let e=0;e<a;e++){const t=i.get(e),r=n.query_identifier_set(t),a=[];if(r.id_array_type.value===x.GLOBALID_ARRAY){const e=r.get_globalid_array(),t=e.count();for(let r=0;r<t;r++)a.push(e.get_globalid_at(r))}else if(r.id_array_type.value===x.IDENTIFIER_ARRAY){const e=r.get_identifier_array(),t=e.count();for(let r=0;r<t;r++)a.push(e.get_identifier_at(r).toString())}else if(r.id_array_type.value===x.STRING_ARRAY){const e=r.get_string_array(),t=e.count();for(let r=0;r<t;r++)a.push(e.get_string_at(r))}else{if(r.id_array_type.value!==x.OID_ARRAY)throw new o.A("knowledge-graph:layer-support-utils","Tried to encode an unexpected ID Array type.");{const e=r.get_oid_array(),t=e.count();for(let r=0;r<t;r++)a.push(e.get_objectid_at(r).toString())}}s.set(t,a)}return t.delete(),s}(new Uint8Array(r))}(e).then((e=>{!function(e,t){for(const[r,s]of e){const e=(0,a.tE)(t.namedTypeDefinitions,r,(()=>({useAllData:!1,members:new Map})));for(const t of s)e.members.has(t)||e.members.set(t,{id:t})}}(e,r)})),r}async function O(e){const t=await(0,S.I)(),r=new t.MapOfObjectIdentifierSets;!function(e,t,r){for(const[s,n]of r.namedTypeDefinitions){if(!n.members||n.useAllData)continue;const r=n.members.keys();let i=!1,o=!0;const a=new t.ObjectIdArray,l=new t.StringArray,u=new t.GlobalIdArray,p=new t.IdentifierArray,d=new t.ObjectIdentifierSet;for(const e of r)o&&(i=!isNaN(Number(e)),o=!1),i?a.add_objectid(Number(e)):(l.add_string(e),u.add_globalid(e)),p.add_identifier(e);d.set_oid_array(a),d.set_string_array(l),d.set_globalid_array(u),d.set_identifier_array(p),a.delete(),l.delete(),u.delete(),p.delete(),e.put_identifier_set(s,d),d.delete()}}(r,t,e);const s=new t.MapOfObjectIdentifierSetsEncoder;try{s.set_map_of_identifier_sets(r),s.encode();const e=s.get_encoding_result();if(0!==e.error.error_code)throw new o.A("knowledge-graph:layer-support-utils",e.error.error_message);const t=structuredClone(e.get_byte_buffer());return s.delete(),t}finally{r.delete()}}async function B(e){const t=await(0,i.A)(e,{responseType:"array-buffer"});return async function(e){const t=new((await(0,S.I)()).FeatureCollectionDecoder),r=t.decode(new Uint8Array(e));if(0!==r.error_code)throw new o.A("knowledge-graph:layer-support-utils",r.error_message);const s=function(e){const t=new p;t.version=e.version;const r=e.get_query_result();if(0!==r.results_type.value)throw new Error("Got a non-feature collection type");const s=r.get_feature_result(),n=t.queryResult.featureResult;n.objectIdFieldName=s.objectid_field_name,n.exceededTransferLimit=s.exceeded_transfer_limit,n.hasM=s.has_m,n.hasZ=s.has_z,n.geometryType=N.bV[s.geometry_type.value],n.globalIdFieldName=s.globalid_field_name,n.geohashFieldName=s.geohash_field_name;const i=n.uniqueIdField,o=s.unique_id_field;i.name=o.name,i.isSystemMaintained=o.isSystemMaintained;const a=n.geometryProperties,l=s.geometry_properties;a.shapeAreaFieldName=l.shapeAreaFieldName,a.shapeLengthFieldName=l.shapeLengthFieldName,a.units=l.units;const u=n.spatialReference,d=s.spatial_reference;u.wkid=d.wkid,u.latestWkid=d.latestWkid,u.vcsWkid=d.vcsWkid,u.latestVcsWkid=d.latestVcsWkid,u.wkt=d.wkt,n.transform=R(s.transform);const c=n.fields,h=n.fieldNameToAttributeIndexMap,y=s.fields,m=y.size();for(let e=0;e<m;e++){const t=y.get(e),r=L(t);c.push(r),h[r.name]=e,t.delete()}y.delete();const f=n.values,g=s.values_count();for(let e=0;e<g;e++)f.push(s.get_value_at(e));const _=n.features,w=s.features,T=w.size();if(T>0)for(const e of v)if(void 0===h[e])throw new Error(`Feature collection missing required attribute: ${e}`);for(let e=0;e<T;e++){const t=new b,r=w.get(e),s=t.attributes,n=r.attributes_count();for(let e=0;e<n;e++)s.push(r.get_attribute_at(e));const i=r.get_compressed_geometry();i&&(t.compressedGeometry=k(i),t.centroid=k(r.get_centroid()));const o=t.aggregateGeometries,a=r.aggregate_geometries,l=a.size();for(let e=0;e<l;e++){const t=a.get(e),r=k(t);o.push(r),t.delete()}a.delete(),_.push(t),r.delete()}w.delete();const I=n.geometryFields,E=s.geometry_fields,M=E.size();for(let e=0;e<M;e++){const t=E.get(e),r=C(t);I.push(r),t.delete()}return E.delete(),t}(t.get_feature_collection());return t.delete(),s}(await t.data)}function F(e,t){if(!e?.queryResult?.featureResult)return t;const r=e.queryResult.featureResult.fieldNameToAttributeIndexMap;for(const n of e.queryResult.featureResult.features){const e=n.attributes[r[s.TYPENAME]],i=(0,a.tE)(t.namedTypeDefinitions,e,(()=>({useAllData:!1,members:new Map}))),o=n.attributes[r[s.ELEMENTUID]];if(n.compressedGeometry?.coords?.length>0){let e=n.compressedGeometry.lengths;"esriGeometryPoint"===n.compressedGeometry.geometryType&&(e=[]),i.members.set(o,{id:o,linkChartLocation:new l.A(e,n.compressedGeometry.coords)})}else i.members.set(o,{id:o})}return t}!function(e){e[e.featureResult=0]="featureResult",e[e.countResult=1]="countResult",e[e.idsResult=2]="idsResult"}(E||(E={})),function(e){e[e.upperLeft=0]="upperLeft",e[e.lowerLeft=1]="lowerLeft"}(M||(M={})),function(e){e[e.sqlTypeBigInt=0]="sqlTypeBigInt",e[e.sqlTypeBinary=1]="sqlTypeBinary",e[e.sqlTypeBit=2]="sqlTypeBit",e[e.sqlTypeChar=3]="sqlTypeChar",e[e.sqlTypeDate=4]="sqlTypeDate",e[e.sqlTypeDecimal=5]="sqlTypeDecimal",e[e.sqlTypeDouble=6]="sqlTypeDouble",e[e.sqlTypeFloat=7]="sqlTypeFloat",e[e.sqlTypeGeometry=8]="sqlTypeGeometry",e[e.sqlTypeGUID=9]="sqlTypeGUID",e[e.sqlTypeInteger=10]="sqlTypeInteger",e[e.sqlTypeLongNVarchar=11]="sqlTypeLongNVarchar",e[e.sqlTypeLongVarbinary=12]="sqlTypeLongVarbinary",e[e.sqlTypeLongVarchar=13]="sqlTypeLongVarchar",e[e.sqlTypeNChar=14]="sqlTypeNChar",e[e.sqlTypeNVarChar=15]="sqlTypeNVarChar",e[e.sqlTypeOther=16]="sqlTypeOther",e[e.sqlTypeReal=17]="sqlTypeReal",e[e.sqlTypeSmallInt=18]="sqlTypeSmallInt",e[e.sqlTypeSqlXml=19]="sqlTypeSqlXml",e[e.sqlTypeTime=20]="sqlTypeTime",e[e.sqlTypeTimestamp=21]="sqlTypeTimestamp",e[e.sqlTypeTimestamp2=22]="sqlTypeTimestamp2",e[e.sqlTypeTinyInt=23]="sqlTypeTinyInt",e[e.sqlTypeVarbinary=24]="sqlTypeVarbinary",e[e.sqlTypeVarchar=25]="sqlTypeVarchar"}(A||(A={})),function(e){e[e.OID_ARRAY=0]="OID_ARRAY",e[e.GLOBALID_ARRAY=1]="GLOBALID_ARRAY",e[e.STRING_ARRAY=2]="STRING_ARRAY",e[e.IDENTIFIER_ARRAY=3]="IDENTIFIER_ARRAY"}(x||(x={}));const j={fetchAndConvertSerializedLinkChart:e=>async function(e){const t=[],r={generateAllSublayers:!1,namedTypeDefinitions:new Map};return e.entitiesUrl&&t.push(B(e.entitiesUrl).then((e=>{F(e,r)}))),e.relationshipsUrl&&t.push(B(e.relationshipsUrl).then((e=>{F(e,r)}))),await Promise.all(t),r}(e)}},9775:(e,t,r)=>{r.d(t,{A:()=>i});var s=r(62788),n=r(95488);class i{constructor(e=e=>e.values().next().value){this._peeker=e,this._observable=new n.I,this._items=new Set}get length(){return(0,s.gc)(this._observable),this._items.size}clear(){0!==this.length&&(this._items.clear(),this._observable.notify())}last(){if(0===this.length)return;let e;for(e of this._items);return e}peek(){if(0!==this.length)return this._peeker(this._items)}push(e){this.contains(e)||(this._items.add(e),this._observable.notify())}contains(e){return(0,s.gc)(this._observable),this._items.has(e)}pop(){if(0===this.length)return;const e=this.peek();return this._items.delete(e),this._observable.notify(),e}popLast(){if(0===this.length)return;const e=this.last();return this._items.delete(e),this._observable.notify(),e}remove(e){this.contains(e)&&(this._items.delete(e),this._observable.notify())}filter(e){const t=this.length;return this._items.forEach((t=>{e(t)||this._items.delete(t)})),t!==this._items.size&&this._observable.notify(),this}*[Symbol.iterator](){(0,s.gc)(this._observable),yield*this._items}}},75503:(e,t,r)=>{r.d(t,{E:()=>M,w:()=>a});var s=r(4576),n=(r(44208),r(4718)),i=r(3694),o=r(11006);class a{constructor(e=9,t){this._compareMinX=c,this._compareMinY=h,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),v.prune(),T.prune(),I.prune(),E.prune()}all(e){l(this._data,e)}search(e,t){let r=this._data;const s=this._toBBox;if(b(e,r))for(v.clear();r;){for(let n=0,i=r.children.length;n<i;n++){const i=r.children[n],o=r.leaf?s(i):i;b(e,o)&&(r.leaf?t(i):_(e,o)?l(i,t):v.push(i))}r=v.pop()}}collides(e){let t=this._data;const r=this._toBBox;if(!b(e,t))return!1;for(v.clear();t;){for(let s=0,n=t.children.length;s<n;s++){const n=t.children[s],i=t.leaf?r(n):n;if(b(e,i)){if(t.leaf||_(e,i))return!0;v.push(n)}}t=v.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,r=e.length;t<r;t++)this.insert(e[t]);return this}let t=this._build(e.slice(),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new x([]),this}remove(e){if(!e)return this;let t,r=this._data,n=null,i=0,o=!1;const a=this._toBBox(e);for(I.clear(),E.clear();r||I.length>0;){if(r||(r=I.pop(),n=I.data[I.length-1],i=E.pop()??0,o=!0),r.leaf&&(t=(0,s.qh)(r.children,e,r.children.length,r.indexHint),-1!==t))return r.children.splice(t,1),I.push(r),this._condense(I),this;o||r.leaf||!_(r,a)?n?(i++,r=n.children[i],o=!1):r=null:(I.push(r),E.push(i),i=0,n=r,r=r.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,r,s){const n=r-t+1;let i=this._maxEntries;if(n<=i){const s=new x(e.slice(t,r+1));return u(s,this._toBBox),s}s||(s=Math.ceil(Math.log(n)/Math.log(i)),i=Math.ceil(n/i**(s-1)));const o=new S([]);o.height=s;const a=Math.ceil(n/i),l=a*Math.ceil(Math.sqrt(i));w(e,t,r,l,this._compareMinX);for(let n=t;n<=r;n+=l){const t=Math.min(n+l-1,r);w(e,n,t,a,this._compareMinY);for(let r=n;r<=t;r+=a){const n=Math.min(r+a-1,t);o.children.push(this._build(e,r,n,s-1))}}return u(o,this._toBBox),o}_insert(e,t,r){const s=this._toBBox,n=r?e:s(e);I.clear();const i=function(e,t,r,s){for(;s.push(t),!0!==t.leaf&&s.length-1!==r;){let r,s=1/0,n=1/0;for(let i=0,o=t.children.length;i<o;i++){const o=t.children[i],a=y(o),l=f(e,o)-a;l<n?(n=l,s=a<s?a:s,r=o):l===n&&a<s&&(s=a,r=o)}t=r||t.children[0]}return t}(n,this._data,t,I);for(i.children.push(e),d(i,n);t>=0&&I.data[t].children.length>this._maxEntries;)this._split(I,t),t--;!function(e,t,r){for(let s=r;s>=0;s--)d(t.data[s],e)}(n,I,t)}_split(e,t){const r=e.data[t],s=r.children.length,n=this._minEntries;this._chooseSplitAxis(r,n,s);const i=this._chooseSplitIndex(r,n,s);if(!i)return;const o=r.children.splice(i,r.children.length-i),a=r.leaf?new x(o):new S(o);a.height=r.height,u(r,this._toBBox),u(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(r,a)}_splitRoot(e,t){this._data=new S([e,t]),this._data.height=e.height+1,u(this._data,this._toBBox)}_chooseSplitIndex(e,t,r){let s,n,i;s=n=1/0;for(let o=t;o<=r-t;o++){const t=p(e,0,o,this._toBBox),a=p(e,o,r,this._toBBox),l=g(t,a),u=y(t)+y(a);l<s?(s=l,i=o,n=u<n?u:n):l===s&&u<n&&(n=u,i=o)}return i}_chooseSplitAxis(e,t,r){const s=e.leaf?this._compareMinX:c,n=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,r,s)<this._allDistMargin(e,t,r,n)&&e.children.sort(s)}_allDistMargin(e,t,r,s){e.children.sort(s);const n=this._toBBox,i=p(e,0,t,n),o=p(e,r-t,r,n);let a=m(i)+m(o);for(let s=t;s<r-t;s++){const t=e.children[s];d(i,e.leaf?n(t):t),a+=m(i)}for(let s=r-t-1;s>=t;s--){const t=e.children[s];d(o,e.leaf?n(t):t),a+=m(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const r=e.data[t];if(0===r.children.length)if(t>0){const n=e.data[t-1],i=n.children;i.splice((0,s.qh)(i,r,i.length,n.indexHint),1)}else this.clear();else u(r,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function l(e,t){let r=e;for(T.clear();r;){if(!0===r.leaf)for(const e of r.children)t((0,n.zI)(e));else T.pushArray(r.children);r=T.pop()??null}}function u(e,t){p(e,0,e.children.length,t,e)}function p(e,t,r,s,n){n||(n=new x([])),n.minX=1/0,n.minY=1/0,n.maxX=-1/0,n.maxY=-1/0;for(let i,o=t;o<r;o++)i=e.children[o],d(n,e.leaf?s(i):i);return n}function d(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function c(e,t){return e.minX-t.minX}function h(e,t){return e.minY-t.minY}function y(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function m(e){return e.maxX-e.minX+(e.maxY-e.minY)}function f(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function g(e,t){const r=Math.max(e.minX,t.minX),s=Math.max(e.minY,t.minY),n=Math.min(e.maxX,t.maxX),i=Math.min(e.maxY,t.maxY);return Math.max(0,n-r)*Math.max(0,i-s)}function _(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function b(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function w(e,t,r,s,n){const i=[t,r];for(;i.length;){const t=i.pop(),r=i.pop();if(t-r<=s)continue;const a=r+Math.ceil((t-r)/s/2)*s;(0,o.q)(e,a,r,t,n),i.push(r,a,a,t)}}const v=new i.A,T=new i.A,I=new i.A,E=new i.A({deallocator:void 0});class M{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class A extends M{constructor(){super(...arguments),this.height=1,this.indexHint=new s.vW}}class x extends A{constructor(e){super(),this.children=e,this.leaf=!0}}class S extends A{constructor(e){super(),this.children=e,this.leaf=!1}}},10382:(e,t,r)=>{r.d(t,{A:()=>u});var s=r(36563),n=(r(44208),r(74887)),i=r(9775),o=r(72457),a=r(52268),l=r(61322);class u{constructor(){this._inUseClients=new Array,this._clients=new Array,this._clientPromises=new Array,this._ongoingJobsQueue=new i.A}destroy(){this.close()}get closed(){return!this._clients?.length}open(e,t){return new Promise(((r,s)=>{let i=!0;const o=e=>{(0,n.Te)(t.signal),i&&(i=!1,e())};this._clients.length=e.length,this._clientPromises.length=e.length,this._inUseClients.length=e.length;for(let i=0;i<e.length;++i){const a=e[i];(0,n.$X)(a)?this._clientPromises[i]=a.then((e=>(this._clients[i]=new l.default(e,t,this._ongoingJobsQueue),o(r),this._clients[i])),(()=>(o(s),null))):(this._clients[i]=new l.default(a,t,this._ongoingJobsQueue),this._clientPromises[i]=Promise.resolve(this._clients[i]),o(r))}}))}broadcast(e,t,r){const s=new Array(this._clientPromises.length);for(let n=0;n<this._clientPromises.length;++n){const i=this._clientPromises[n];s[n]=i.then((s=>s?.invoke(e,t,r)))}return s}close(){let e;for(;e=this._ongoingJobsQueue.pop();)e.resolver.reject((0,n.NK)(`Worker closing, aborting job calling '${e.methodName}'`));for(const e of this._clientPromises)e.then((e=>e?.close()));this._clients.length=0,this._clientPromises.length=0,this._inUseClients.length=0,(0,o.h)(this)}invoke(e,t,r){return this.apply(e,[t],r)}apply(e,t,r){const s=(0,n.Tw)();this._ongoingJobsQueue.push({methodName:e,data:t,invokeOptions:r,resolver:s});for(let e=0;e<this._clientPromises.length;e++){const t=this._clients[e];t?t.jobAdded():this._clientPromises[e].then((e=>e?.jobAdded()))}return s.promise}createInvokeProxy(e){return(0,a.L)(this,e)}on(e,t){return Promise.all(this._clientPromises).then((()=>(0,s.vE)(this._clients.map((r=>r.on(e,t))))))}openPorts(){return new Promise((e=>{const t=new Array(this._clientPromises.length);let r=t.length;for(let s=0;s<this._clientPromises.length;++s)this._clientPromises[s].then((n=>{n&&(t[s]=n.openPort()),0==--r&&e(t)}))}))}get test(){}}},72457:(e,t,r)=>{r.d(t,{h:()=>i,k:()=>n});const s=new FinalizationRegistry((e=>{e.close()}));function n(e,t){s.register(e,t,t)}function i(e){s.unregister(e)}},29953:(e,t,r)=>{r.d(t,{ho:()=>G});var s=r(49186),n=r(44208),i=r(74887),o=r(10382),a=r(72457),l=r(61322),u=r(53966),p=r(97768),d=r(78888),c=r(84952);const h={async request(e,t){const r=e.options,s=r.responseType;r.signal=t?.signal,r.responseType="native"===s||"native-request-init"===s?"native-request-init":s&&["blob","json","text"].includes(s)&&(0,c.sC)(e.url)?.after?s:"array-buffer";const n=await(0,d.A)(e.url,r),i={data:n.data,httpStatus:n.httpStatus,ssl:n.ssl};switch(n.requestOptions?.responseType){case"native-request-init":return delete i.data.signal,i;case"blob":i.data=await i.data.arrayBuffer();break;case"json":i.data=(new TextEncoder).encode(JSON.stringify(i.data)).buffer;break;case"text":i.data=(new TextEncoder).encode(i.data).buffer}return{result:i,transferList:[i.data]}}};var y=r(8341),m=r(2741),f=r(92602),g=(r(47566),r(70333));const _={};var b=r(26390);class w{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...r)=>e[t](...r)}))}}class v{constructor(){this._dispatcher=new w,this._workerPostMessage({type:y.Go.HANDSHAKE})}terminate(){}get onmessage(){return this._onmessageHandler}set onmessage(e){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler),this._onmessageHandler=e,e&&this.addEventListener("message",e)}get onmessageerror(){return this._onmessageerrorHandler}set onmessageerror(e){this._onmessageerrorHandler&&this.removeEventListener("messageerror",this._onmessageerrorHandler),this._onmessageerrorHandler=e,e&&this.addEventListener("messageerror",e)}get onerror(){return this._onerrorHandler}set onerror(e){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler),this._onerrorHandler=e,e&&this.addEventListener("error",e)}postMessage(e){(0,b.d)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,r){this._dispatcher.addEventListener(e,t,r)}removeEventListener(e,t,r){this._dispatcher.removeEventListener(e,t,r)}_workerPostMessage(e){(0,b.d)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,y.VI)(e);if(t&&t.type===y.Go.OPEN){const{modulePath:e,jobId:r}=t;let s=await l.default.loadWorker(e);s||(s=await import(e));const n=l.default.connect(s);this._workerPostMessage({type:y.Go.OPENED,jobId:r,data:n})}}}var T=r(73444),I=r(18357);const E=()=>u.A.getLogger("esri.core.workers.workerFactory"),{HANDSHAKE:M}=y.Go;let A,x;const S="Failed to create Worker. Fallback to execute module in main thread";async function N(e){return new Promise((t=>{function r(n){const i=(0,y.VI)(n);i&&i.type===M&&(e.removeEventListener("message",r),e.removeEventListener("error",s),t(e))}function s(t){t.preventDefault(),e.removeEventListener("message",r),e.removeEventListener("error",s),E().warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new v).addEventListener("message",r),e.addEventListener("error",s)}e.addEventListener("message",r),e.addEventListener("error",s)}))}let k=0;const{ABORT:L,INVOKE:C,OPEN:R,OPENED:D,RESPONSE:O}=y.Go;class B{static async create(e){const t=await async function(){if(!(0,n.A)("esri-workers"))return N(new v);if(!A&&!x)try{const e='let globalId=0;const outgoing=new Map,configuration={CONFIGURATION};self.esriConfig=configuration.esriConfig;const workerPath=self.esriConfig.workers.workerPath,HANDSHAKE=0,OPEN=1,OPENED=2,RESPONSE=3,INVOKE=4,ABORT=5;function createAbortError(){const e=new Error("Aborted");return e.name="AbortError",e}function receiveMessage(e){return e&&e.data?"string"==typeof e.data?JSON.parse(e.data):e.data:null}function invokeStaticMessage(e,o,r){const t=r&&r.signal,n=globalId++;let s=null;return new Promise(((r,i)=>{if(t){if(t.aborted)return i(createAbortError());s=()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:5,jobId:n}),i(createAbortError()))},t.addEventListener("abort",s)}outgoing.set(n,{resolve:r,reject:i}),self.postMessage({type:4,jobId:n,methodName:e,abortable:null!=t,data:o})})).finally((()=>{t&&t.removeEventListener("abort",s)}))}let workerRevisionChecked=!1;function checkWorkerRevision(e){if(!workerRevisionChecked&&e.kernelInfo){workerRevisionChecked=!0;const{revision:o,fullVersion:r}=configuration.kernelInfo,{revision:t,fullVersion:n,version:s}=e.kernelInfo;esriConfig.assetsPath!==esriConfig.defaultAssetsPath&&o!==t&&console.warn(`Version mismatch detected between ArcGIS Maps SDK for JavaScript modules and assets. For more information visit https://bit.ly/3QnsuSo.\nModules version: ${r}\nAssets version: ${n??s}\nAssets path: ${esriConfig.assetsPath}`)}}function messageHandler(e){const o=receiveMessage(e);if(!o)return;const r=o.jobId;switch(o.type){case 1:let n;function t(e){const o=n.connect(e);self.postMessage({type:2,jobId:r,data:o},[o])}"function"==typeof define&&define.amd?require([workerPath],(e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||new Promise((e=>{require([o.modulePath],e)})))).then(t)})):"System"in self&&"function"==typeof System.import?System.import(workerPath).then((e=>(n=e.default,checkWorkerRevision(n),n.loadWorker(o.modulePath)))).then((e=>e||System.import(o.modulePath))).then(t):esriConfig.workers.useDynamicImport?import(workerPath).then((e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||import(o.modulePath))).then(t)})):(self.RemoteClient||importScripts(workerPath),n=self.RemoteClient.default||self.RemoteClient,checkWorkerRevision(n),n.loadWorker(o.modulePath).then(t));break;case 3:if(outgoing.has(r)){const s=outgoing.get(r);outgoing.delete(r),o.error?s.reject(JSON.parse(o.error)):s.resolve(o.data)}}}self.dojoConfig=configuration.loaderConfig,esriConfig.workers.loaderUrl&&(self.importScripts(esriConfig.workers.loaderUrl),"function"==typeof require&&"function"==typeof require.config&&require.config(configuration.loaderConfig)),self.addEventListener("message",messageHandler),self.postMessage({type:0});'.split("{CONFIGURATION}").join(function(){let e;if(null!=f.A.default){const t={...f.A};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(f.A));e.assetsPath=(0,c.s2)(e.assetsPath),e.defaultAssetsPath=e.defaultAssetsPath?(0,c.s2)(e.defaultAssetsPath):void 0,e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,T.JK)(),e.has={"esri-csp-restrictions":(0,n.A)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,n.A)("esri-2d-update-debug"),"esri-2d-log-updating":(0,n.A)("esri-2d-log-updating"),"featurelayer-pbf":(0,n.A)("featurelayer-pbf"),"featurelayer-fast-triangulation-enabled":(0,n.A)("featurelayer-fast-triangulation-enabled"),"featurelayer-simplify-thresholds":(0,n.A)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,n.A)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,n.A)("featurelayer-simplify-mobile-factor"),"featurelayer-query-max-depth":(0,n.A)("featurelayer-query-max-depth"),"featurelayer-query-pausing-enabled":(0,n.A)("featurelayer-query-pausing-enabled"),"featurelayer-snapshot-enabled":(0,n.A)("featurelayer-snapshot-enabled"),"esri-atomics":(0,n.A)("esri-atomics"),"esri-shared-array-buffer":(0,n.A)("esri-shared-array-buffer"),"esri-tiles-debug":(0,n.A)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,n.A)("esri-workers-arraybuffer-transfer"),"feature-polyline-generalization-factor":(0,n.A)("feature-polyline-generalization-factor"),"host-webworker":1},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,c.s2)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,c.s2)(e.workers.workerPath):e.workers.workerPath=(0,c.s2)((0,m.s)("esri/core/workers/RemoteClient.js")),e.workers.useDynamicImport=!1;const t=f.A.workers.loaderConfig,r=function(e){const t={async:e.async,isDebug:e.isDebug,locale:e.locale,baseUrl:e.baseUrl,has:{...e.has},map:{...e.map},packages:e.packages?.slice()||[],paths:{..._.paths,...e.paths}};return e.hasOwnProperty("async")||(t.async=!0),e.hasOwnProperty("isDebug")||(t.isDebug=!1),e.baseUrl||(t.baseUrl=_.baseUrl),t}({baseUrl:t?.baseUrl,locale:(0,T.JK)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...t?.has},map:{...t?.map},paths:{...t?.paths},packages:t?.packages||[]}),s={buildDate:I.$,fullVersion:g.ol,revision:I.u};return JSON.stringify({esriConfig:e,loaderConfig:r,kernelInfo:s})}());A=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){x=e||{}}let e;if(A)try{e=new Worker(A,{name:"esri-worker-"+k++})}catch(t){E().warn(S,x),e=new v}else E().warn(S,x),e=new v;return N(e)}();return new B(t,e)}constructor(e,t){this._outJobs=new Map,this._inJobs=new Map,this.worker=e,this.id=t,e.addEventListener("message",this._onMessage.bind(this)),e.addEventListener("error",(e=>{e.preventDefault(),u.A.getLogger("esri.core.workers.WorkerOwner").error(e)}))}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:r}=t,s=(0,y.Jc)();return new Promise(((t,n)=>{const o={resolve:t,reject:n,abortHandle:(0,i.NY)(r,(()=>{this._outJobs.delete(s),this._post({type:L,jobId:s})}))};this._outJobs.set(s,o),this._post({type:R,jobId:s,modulePath:e})}))}_onMessage(e){const t=(0,y.VI)(e);if(t)switch(t.type){case D:this._onOpenedMessage(t);break;case O:this._onResponseMessage(t);break;case L:this._onAbortMessage(t);break;case C:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,r=e.jobId,s=t.get(r);s&&(s.controller&&s.controller.abort(),t.delete(r))}_onInvokeMessage(e){const{methodName:t,jobId:r,data:s,abortable:n}=e,o=n?new AbortController:null,a=this._inJobs,l=h[t];let u;try{if("function"!=typeof l)throw new TypeError(`${t} is not a function`);u=l.call(null,s,{signal:o?o.signal:null})}catch(e){return void this._post({type:O,jobId:r,error:(0,y.mF)(e)})}(0,i.$X)(u)?(a.set(r,{controller:o,promise:u}),u.then((e=>{a.has(r)&&(a.delete(r),this._post({type:O,jobId:r},e))}),(e=>{a.has(r)&&(a.delete(r),e||(e={message:"Error encountered at method"+t}),(0,i.zf)(e)||this._post({type:O,jobId:r,error:(0,y.mF)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:O,jobId:r},u)}_onOpenedMessage(e){const{jobId:t,data:r}=e,s=this._outJobs.get(t);s&&(this._outJobs.delete(t),(0,p.xt)(s.abortHandle),s.resolve(r))}_onResponseMessage(e){const{jobId:t,error:r,data:n}=e,i=this._outJobs.get(t);i&&(this._outJobs.delete(t),(0,p.xt)(i.abortHandle),r?i.reject(s.A.fromJSON(JSON.parse(r))):i.resolve(n))}_post(e,t,r){return(0,y.u1)(this.worker,e,t,r)}}const F=(0,n.A)("host-browser")?Math.min(navigator.hardwareConcurrency-1,(0,n.A)("workers-pool-size")??8):0;let j=(0,n.A)("esri-mobile")?Math.min(F,3):F;j||(j=(0,n.A)("safari")&&(0,n.A)("mac")?7:2);let P=0;const q=[];async function Z(e,t){const r=new o.A,{registryTarget:s,...n}=t;return await r.open(e,n),s&&(0,a.k)(s,r),r}async function G(e,t={}){if("string"!=typeof e)throw new s.A("workers:undefined-module","modulePath is missing");let r=t.strategy||"distributed";if((0,n.A)("host-webworker")&&!(0,n.A)("esri-workers")&&(r="local"),"local"===r){let r=await l.default.loadWorker(e);r||(r=await import(e)),(0,i.Te)(t.signal);const s=t.client||r;return Z([l.default.connect(r,t.schedule)],{...t,client:s})}if(await async function(){if(U)return U;$=new AbortController;const e=[];for(let t=0;t<j;t++){const r=B.create(t).then((e=>(q[t]=e,e)));e.push(r)}return U=Promise.all(e),U}(),(0,i.Te)(t.signal),"dedicated"===r){const r=P++%j;return Z([await q[r].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const r=Math.min(t.maxNumWorkers,j);if(r<j){const s=new Array(r);for(let n=0;n<r;++n){const r=P++%j;s[n]=q[r].open(e,t)}return Z(s,t)}}return Z(q.map((r=>r.open(e,t))),t)}let $,U=null},6518:(e,t,r)=>{r.d(t,{F:()=>a});var s=r(44208),n=r(75503),i=r(19419);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new n.w(9,(0,s.A)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((r,s)=>{e[t++]=s})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,i.Ie)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,r){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,r)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},83221:(e,t,r)=>{r.d(t,{A:()=>y});var s=r(4576),n=r(49186),i=r(65529),o=r(53966),a=r(70328),l=r(19419),u=r(90708),p=r(6518),d=r(51441),c=r(37730);const h=(0,a.vt)();class y{constructor(e){this.geometryInfo=e,this._boundsStore=new p.F,this._featuresById=new Map,this.events=new i.A,this.featureAdapter=c.T}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach((t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,r,s,n]=this.fullBounds;return{xmin:t,ymin:r,xmax:s,ymax:n,spatialReference:(0,d.ag)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map((e=>this._upsert(e)));return this._emitChanged(),t.filter(s.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const r of e){const e=this._boundsStore.get(r.objectId);e&&t((0,a.Jt)(h,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const r=this._featuresById.get(t);let s;if(r?(e.displayId=r.displayId,s=this._boundsStore.get(t),this._boundsStore.delete(t)):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);s=(0,u.jQ)(null!=s?s:(0,l.vt)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=s&&this._boundsStore.set(t,s),this._featuresById.set(t,e)}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const r=this._featuresById.get(t);if(!r)return this._add(e),e;const{geometry:s,attributes:i}=e;for(const e in i)r.attributes[e]=i[e];return s&&(r.geometry=s,this._boundsStore.set(t,(0,u.jQ)((0,l.vt)(),s,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),r}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._boundsStore.delete(t),this._featuresById.delete(t),e}}},37730:(e,t,r)=>{r.d(t,{T:()=>n});var s=r(43334);const n={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new s.Om(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>e.ensureCentroid(t)}},64714:(e,t,r)=>{r.d(t,{F0:()=>l,Vx:()=>d,e2:()=>h,f:()=>y});var s=r(44208),n=r(4718),i=r(99352),o=r(4071),a=r(93470);function l(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?a.Cb:"esriGeometryPolyline"===e?a.yM:a.WR}}}const u=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let p=1;function d(e,t){if((0,s.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let r=`this${c(t)} = null;`;for(const t in e)r+=`this${c(t)} = ${JSON.stringify(e[t])};`;const s=new Function(`\n return class AttributesClass$${p++} {\n constructor() {\n ${r};\n }\n }\n `)();return()=>new s}catch(r){return()=>({[t]:null,...e})}}function c(e){return u.test(e)?`.${e}`:`["${e}"]`}function h(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,n.o8)(e)}}]}function y(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:i.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:o.$,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},80340:(e,t,r)=>{r.d(t,{P:()=>T});var s=r(90237),n=(r(59456),r(69622)),i=r(49186),o=r(53966),a=r(91869),l=r(74887),u=r(39516),p=r(10107),d=(r(44208),r(87811),r(40608)),c=r(39829),h=r(57251),y=r(21325),m=r(85342),f=r(69860),g=r(30504),_=r(71402),b=r(42538),w=r(61956),v=r(5443);let T=class extends n.A{constructor(e){super(e),this._processingCacheUpdatesLookup=new Map,this.knowledgeGraph=null,this.inclusionModeDefinition={generateAllSublayers:!0,namedTypeDefinitions:new Map},this.entityTypeNames=new Set,this.relationshipTypeNames=new Set,this.geographicLookup=new Map,this.sublayerCaches=new Map,this.nodeConnectionsLookup=new Map,this.relationshipConnectionsLookup=new Map,this.memberIdTypeLookup=new Map;const t=new Map;e.knowledgeGraph.dataModel.entityTypes?.forEach((r=>{r.name&&(t.set(r.name,"entity"),this._processingCacheUpdatesLookup.set(r.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.entityTypeNames.add(r.name),r.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(r.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.knowledgeGraph.dataModel.relationshipTypes?.forEach((r=>{r.name&&(t.set(r.name,"relationship"),this._processingCacheUpdatesLookup.set(r.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.relationshipTypeNames.add(r.name),r.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(r.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.inclusionModeDefinition?.namedTypeDefinitions.forEach(((r,s)=>{if("entity"===t.get(s))this.entityTypeNames.add(s);else{if("relationship"!==t.get(s))return o.A.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);this.relationshipTypeNames.add(s)}const n=new Map;r.members?.forEach((e=>{(0,a.tE)(this.memberIdTypeLookup,e.id,(()=>new Set)).add(s);const t=this.getById(e.id);t&&n.set(e.id,t)})),this.sublayerCaches.set(s,n)}))}addToLayer(e){e.forEach((({typeName:e,id:t})=>{if(!this.inclusionModeDefinition)throw new i.A("knowledge-graph:layer-data-manager","You cannot add to a layer's exclusion list if it was not created with an exclusion list originally");if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){const r=this.inclusionModeDefinition.namedTypeDefinitions.get(e);r.members||(r.members=new Map),r.members.set(t,{id:t}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}else{const r=new Map;r.set(t,{id:t}),this.inclusionModeDefinition.namedTypeDefinitions.set(e,{useAllData:!1,members:r}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}))}getById(e){return f.A.getInstance().readFromStoreById(e)}async getData(e,t,r){if(t.objectType.name&&this.inclusionModeDefinition?.namedTypeDefinitions&&this.inclusionModeDefinition.namedTypeDefinitions.size>0&&!this.inclusionModeDefinition.namedTypeDefinitions.has(t.objectType.name))return[];let s;if(s=e||new w.A({where:"1=1",outFields:["*"]}),"link-chart"===t.parentCompositeLayer.type){const e=t.parentCompositeLayer,r=this._processingCacheUpdatesLookup.get(t.objectType.name??""),n=s.outFields;n&&1===n.length&&n[0]===m.dr&&"1=1"===s.where||await Promise.all(r??[]);const i=this.sublayerCaches.has(t.objectType.name??"")?Array.from(this.sublayerCaches.get(t.objectType.name)?.values()):[],o=[];return i.forEach((r=>{if(this.relationshipTypeNames.has(t.objectType.name)){r.geometry=e.relationshipLinkChartDiagramLookup.get(r.attributes[t.objectIdField]);const s=this.memberIdTypeLookup.get(r.attributes[m.Cz]),n=this.memberIdTypeLookup.get(r.attributes[m.KQ]),i=this._isEndEntitySpatial(s,r,m.Cz),o=this._isEndEntitySpatial(n,r,m.KQ);r.attributes[m.BL]=Number(i&&o)}else{r.geometry=e.entityLinkChartDiagramLookup.get(r.attributes[t.objectIdField]);const s=this.geographicLookup.get(t.objectType.name);s&&r.attributes[s.name]?r.attributes[m.BL]=1:r.attributes[m.BL]=0}r.attributes[m.T1]=r.geometry,o.push(r)})),o}return this.retrieveDataFromService(s,t,r)}async getConnectedRecordIds(e,t,r){const s=[];let n="";const i=this._getNamedTypeIdMapFromNodeIds(e);if(t&&0!==t?.length){for(const e of t)n=n+e+"|";n=n.slice(0,-1)}const o={},a=[];for(const[e,r]of i){const s=`${e}_ids`;o[s]=r,t&&0!==t?.length?a.push(`MATCH (n:${e}) WHERE id(n) IN $${s} WITH n MATCH (n)-[r:${n}]-(m) RETURN id(r), type(r), id(m), labels(m)[0]`):a.push(`MATCH (n:${e}) WHERE id(n) IN $${s} WITH n MATCH (n)-[r]-(m) RETURN id(r), type(r), id(m), labels(m)[0]`)}if(!a.length)return s;const l=a.join(" UNION "),u=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:l,bindParameters:o}),{signal:r?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await u.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];s.push({id:r[0],typeName:r[1]}),s.push({id:r[2],typeName:r[3]})}}return s}async getRelationshipsBetweenNodes(e,t,r){const s=this._getNamedTypeIdMapFromNodeIds(e);if(0===s.size)return[];const n={relationshipExclusionIds:t,possibleConnectionEntityIds:e},i=[];for(const[e,t]of s.entries()){const r=`${e}_ids`;n[r]=t,i.push(`MATCH (n:${e}) WHERE id(n) IN $${r} WITH n MATCH (n)-[r]->(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const o=i.join(" UNION "),a=[],l=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:o,bindParameters:n}),{signal:r?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await l.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];a.push({id:r[0],typeName:r[1]})}}return a}async getRelationshipsFromNodes(e,t,r,s){const n=this._getNamedTypeIdMapFromNodeIds(e);if(0===n.size||0===t.length)return[];const i={relationshipExclusionIds:r,possibleConnectionEntityIds:t},o=[];for(const[e,t]of n.entries()){const r=`${e}_ids`;i[r]=t,o.push(`MATCH (n:${e}) WHERE id(n) IN $${r} WITH n MATCH (n)-[r]-(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const a=o.join(" UNION "),l=new Map,u=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:a,bindParameters:i}),{signal:s?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await u.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];let s=l.get(r[1]);s||(s=new Set,l.set(r[1],s)),s.add(r[0])}}const p=[];for(const[e,t]of l)for(const r of t)p.push({id:r,typeName:e});return p}async refreshCacheContent(e,t,r,s=!0,n){const o=f.A.getInstance(),u=[],p=new Map,d=new Map;this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&d.set(e.name,e)})),this.knowledgeGraph.dataModel.relationshipTypes?.forEach((e=>{e.name&&d.set(e.name,e)})),e||this.inclusionModeDefinition?e?e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const t of this.memberIdTypeLookup.get(e))p.has(t)?p.get(t)?.push(e):p.set(t,[e])})):this.inclusionModeDefinition?.namedTypeDefinitions?.forEach(((e,t)=>{e.useAllData?p.set(t,null):e.members&&e.members.forEach((e=>{p.has(t)&&null!==p.get(t)?p.get(t)?.push(e.id):p.set(t,[e.id])}))})):(this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&p.set(e.name,null)})),this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&p.set(e.name,null)})));for(const[e,l]of p){const p=new Set(l),c=new Promise(((u,c)=>{(async()=>{const u=new Set,c=[];let h,y="",f=!1;if(t||d.get(e)?.properties?.forEach((e=>{e.name&&u.add(e.name)})),r&&this.geographicLookup.has(e)){const t=this.geographicLookup.get(e)?.name;t&&u.add(t)}if(this.entityTypeNames.has(e))y=`MATCH (n:${e}) ${l?"WHERE id(n) IN $ids ":""}return ID(n)`,u.forEach((e=>{y+=`, n.${e}`,c.push(e)}));else{if(!this.relationshipTypeNames.has(e))throw new i.A("knowledge-graph:layer-data-manager",`The graph type of ${e} could not be determined. Was this type set in the KG data model and inclusion definition?`);f=!0,y=`MATCH ()-[n:${e}]->() ${l?"WHERE id(n) IN $ids ":""}return ID(n), id(startNode(n)), id(endNode(n))`,u.forEach((e=>{y+=`, n.${e}`,c.push(e)}))}h=new b.A(l?{openCypherQuery:y,bindParameters:{ids:l}}:{openCypherQuery:y});const g=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,h,{signal:n?.signal})).resultRowsStream.getReader();for(;;){const{done:t,value:r}=await g.read();if(t)break;const n=[];for(let e=0;e<r.length;e++){const t=r[e];let s=0,i=0;const o={properties:{}};for(o.id=t[s],s++,i++,f&&(o.originId=t[s],s++,i++,o.destinationId=t[s],s++,i++,(0,a.tE)(this.nodeConnectionsLookup,o.originId,(()=>new Set)).add(o.id),(0,a.tE)(this.nodeConnectionsLookup,o.destinationId,(()=>new Set)).add(o.id),(0,a.tE)(this.relationshipConnectionsLookup,o.id,(()=>[o.originId,o.destinationId])));s<t.length;s++)o.properties[c[s-i]]=t[s];p.delete(o.id),n.push(o)}const i=o.writeToStore(n,m.dr,this.geographicLookup.get(e)?.name);this.sublayerCaches.has(e)||this.sublayerCaches.set(e,new Map),s&&!this.inclusionModeDefinition?.namedTypeDefinitions.has(e)&&this.inclusionModeDefinition?.namedTypeDefinitions.set(e,{useAllData:!1,members:new Map}),s&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members&&(this.inclusionModeDefinition.namedTypeDefinitions.get(e).members=new Map);const l=this.sublayerCaches.get(e);i.forEach((t=>{l?.set(t.attributes[m.dr],t),s&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.has(t.attributes[m.dr])&&(this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.set(t.attributes[m.dr],{id:t.attributes[m.dr]}),(0,a.tE)(this.memberIdTypeLookup,t.attributes[m.dr],(()=>new Set)).add(e))}))}const w=this.inclusionModeDefinition?.namedTypeDefinitions.get(e);if(w)for(const e of p)w.members?.delete(e)})().then((()=>{u(null)})).catch((e=>{"AbortError"===e.name?u(null):c(e)}))}));u.push(c),this._processingCacheUpdatesLookup.get(e)?.push(c)}if(await Promise.all(u),n?.signal?.aborted)throw(0,l.NK)()}removeFromLayer(e){const t=new Set,r=new Set(e.map((e=>e.id)));for(const r of e)t.add(r.typeName),1===this.memberIdTypeLookup.get(r.id)?.size?this.memberIdTypeLookup.delete(r.id):this.memberIdTypeLookup.get(r.id)?.delete(r.typeName),this.inclusionModeDefinition?.namedTypeDefinitions.forEach(((e,t)=>{t===r.typeName&&e.members?.has(r.id)&&e.members.delete(r.id)}));t.forEach((e=>{this.sublayerCaches.get(e)?.forEach(((t,s)=>{r.has(s)&&this.sublayerCaches.get(e)?.delete(s)}))}))}async retrieveDataFromService(e,t,r){const s=f.A.getInstance(),n=new Set,o=[];let a,l="",p=[];const d="relationship"===t.graphType,w=this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData,T=t.parentCompositeLayer.sublayerIdsCache.get(t.objectType.name);let I=!w&&T?Array.from(T).sort():null;if(this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData)this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData&&null!=e.objectIds&&(I=e.objectIds);else if(null!=e.objectIds&&I&&I.length>0){const t=e.objectIds;e.objectIds=I.filter((e=>t.includes(e)))}else if(null!=e.objectIds)I=e.objectIds;else{if(this.inclusionModeDefinition?.namedTypeDefinitions.has(t.objectType.name)&&(!this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members||this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members?.size<1))return e.objectIds=[],[];e.objectIds=I}if(null!=e.outFields){const r=e.outFields;r.includes("*")?t.fields.forEach((e=>{n.add(e.name)})):r.forEach((e=>{e!==m.dr&&e!==t.geometryFieldName&&n.add(e)}))}if(null!=e.geometry){const r=e.geometry;let s;const p=t.parentCompositeLayer.dataManager.knowledgeGraph.serviceDefinition,m=p?.spatialReference,f=p?.serviceCapabilities?.geometryCapabilities;let _=f?.geometryMaxBoundingRectangleSizeX,w=f?.geometryMaxBoundingRectangleSizeY;if("point"===r.type){let e=r;e.spatialReference?.isWGS84||(await(0,h.initializeProjection)(e.spatialReference,y.KK),e=(0,h.project)(e,y.KK)),s=new v.A({spatialReference:y.KK,xmin:e.x-1e-4,ymin:e.y-1e-4,xmax:e.x+1e-4,ymax:e.y+1e-4})}else r?.extent?.spatialReference&&!r.spatialReference?.isWGS84?(await(0,h.initializeProjection)(r.extent.spatialReference,y.KK),s=(0,h.project)(r.extent,y.KK)):s=r.extent;if(_&&w&&m){if(4326!==m.wkid){const e=new v.A({spatialReference:m,xmax:_,ymax:w}),t=(0,h.project)(e,y.KK);_=t.xmax,w=t.ymax}if(s.xmax-s.xmin>_)throw new i.A("knowledge-graph:layer-data-manager",`Extent x bounds should be within ${_}° latitude, limit exceeded`);if(s.ymax-s.ymin>w)throw new i.A("knowledge-graph:layer-data-manager",`Extent y bounds should be within ${w}° longitude, limit exceeded`)}if(null!=e.where&&"1=1"!==e.where){const r=await(0,u.G)(e.where.toUpperCase(),t.fieldsIndex);t.fields.forEach((e=>{r.fieldNames.includes(e.name)&&n.add(e.name)}))}l=d?`Match ()-[n:${t.objectType.name}]->() WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n), id(startNode(r)), id(endNode(r))`:`Match (n:${t.objectType.name}) WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n)`,t.geometryFieldName&&n.add(t.geometryFieldName),n.forEach((e=>{l+=`, n.${e}`,o.push(e)})),a=new b.A({openCypherQuery:l,bindParameters:{param_filter_geom:new c.A({rings:(0,g.Wq)(s)})}})}else{let r="";if(null!=e.where&&"1=1"!==e.where){const s=await(0,u.G)(e.where,t.fieldsIndex);t.fields.forEach((e=>{s.fieldNames.includes(e.name)&&n.add(e.name)}));const i=new Set(["column-reference","string","number","binary-expression"]),o=new Set(["=","<","<=","<>",">",">=","AND","OR","LIKE"]);let a=!1;const l=e=>{if("column-reference"===e.type)return`n.${e.column}`;if("string"===e.type)return`'${e.value}'`;if("number"===e.type)return`${e.value}`;if("binary-expression"===e.type&&i.has(e.left.type)&&i.has(e.right.type)&&o.has(e.operator))return`${l(e.left)} ${e.operator} ${l(e.right)}`;if("binary-expression"===e.type&&"LIKE"===e.operator){let t="";if("function"===e.left.type&&"column-reference"===e.left.args.value[0].type)t+=`lower(n.${e.left.args.value[0].column})`;else{if("column-reference"!==e.left.type)return a=!0,"";t+=`lower(n.${e.left.column})`}if(t+=" CONTAINS (","string"!==e.right.type)return a=!0,"";{let r=e.right.value;"%"===r.charAt(0)&&(r=r.slice(1)),"%"===r.charAt(r.length-1)&&(r=r.slice(0,-1)),t+=`'${r.toLowerCase()}')`}return t}return a=!0,""};r=l(s.parseTree),a&&(r="")}let s="";s=d?`Match ()-[n:${t.objectType.name}]->()`:`Match (n:${t.objectType.name})`;let i=!1;I&&(i=!0,s+=" WHERE ID(n) IN $ids"),r&&(s+=i?" AND":" WHERE",s+=` ${r}`),s+=" return ID(n)",d&&(s+=", id(startNode(n)), id(endNode(n))"),e.returnGeometry&&t.geometryFieldName&&n.add(t.geometryFieldName),n.forEach((e=>{s+=`, n.${e}`,o.push(e)})),a=new b.A(I?{openCypherQuery:s,bindParameters:{ids:I}}:{openCypherQuery:s})}const E=(await(0,_.executeQueryStreaming)(t.parentCompositeLayer.dataManager.knowledgeGraph,a,r)).resultRowsStream.getReader();for(;;){const{done:e,value:r}=await E.read();if(e)break;const n=[];for(let e=0;e<r.length;e++){const t=r[e];let s=0,i=0;const a={properties:{}};for(a.id=t[s],s++,i++,d&&(a.originId=t[s],s++,i++,a.destinationId=t[s],s++,i++);s<t.length;s++)a.properties[o[s-i]]=t[s];n.push(a)}p=p.concat(s.writeToStore(n,m.dr,t.parentCompositeLayer.dataManager.geographicLookup.get(t.objectType.name)?.name))}return p}_isEndEntitySpatial(e,t,r){for(const s of e??[])if(this.entityTypeNames.has(s)){const e=this.geographicLookup.get(s),n=e&&this.sublayerCaches.get(s)?.get(t.attributes[r]);if(e&&n?.attributes[e.name])return!0}return!1}_getNamedTypeIdMapFromNodeIds(e){const t=new Map;return e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const r of this.memberIdTypeLookup.get(e)){if(!this.entityTypeNames.has(r))return;t.has(r)?t.get(r)?.push(e):t.set(r,[e])}})),t}};(0,s._)([(0,p.MZ)()],T.prototype,"knowledgeGraph",void 0),(0,s._)([(0,p.MZ)()],T.prototype,"inclusionModeDefinition",void 0),(0,s._)([(0,p.MZ)()],T.prototype,"entityTypeNames",void 0),(0,s._)([(0,p.MZ)()],T.prototype,"relationshipTypeNames",void 0),(0,s._)([(0,p.MZ)()],T.prototype,"geographicLookup",void 0),(0,s._)([(0,p.MZ)()],T.prototype,"sublayerCaches",void 0),(0,s._)([(0,p.MZ)()],T.prototype,"nodeConnectionsLookup",void 0),(0,s._)([(0,p.MZ)()],T.prototype,"relationshipConnectionsLookup",void 0),(0,s._)([(0,p.MZ)()],T.prototype,"memberIdTypeLookup",void 0),T=(0,s._)([(0,d.$)("esri.layers.knowledgeGraph.KnowledgeGraphLayerDataManager")],T)},70643:(e,t,r)=>{r.d(t,{A:()=>X});var s=r(90237),n=(r(59456),r(13874)),i=(r(86162),r(52464),r(65345),r(42980),r(20917),r(92438),r(96576),r(93618),r(65494)),o=r(15036),a=r(4718),l=r(92071),u=(r(29953),r(10107)),p=(r(44208),r(53966),r(40608)),d=r(43937),c=r(35666),h=r(57251),y=r(16930),m=r(21325),f=r(4146),g=r(83221),_=r(19730),b=r(64714);r(87811);const w=(0,r(17036).p)(),v=e=>{let t=class extends e{constructor(){super(...arguments),this.fields=[],this.fieldsIndex=null}};return(0,s._)([(0,u.MZ)(w.fields)],t.prototype,"fields",void 0),(0,s._)([(0,u.MZ)(w.fieldsIndex)],t.prototype,"fieldsIndex",void 0),t=(0,s._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayerBase")],t),t};var T=r(85342),I=r(63074),E=r(87718),M=r(76294),A=r(32756),x=r(54310),S=r(25036),N=r(82935),k=r(10873),L=r(13213),C=r(20437),R=r(30524),D=r(81457),O=r(39383),B=r(96184),F=r(22671),j=r(61956),P=r(30291),q=r(61322),Z=r(5443),G=r(39829),$=r(82799),U=r(86738),H=r(50498);function Q(e){if(!e.json)return e;e.json.write=z(e.json.write);const t=e.json.origins;if(!t)return e;let r;for(r in t){const e=t[r];e&&(e.write=z(e.write))}return e}function z(e){return"object"==typeof e&&e?(!1!==e.enabled&&(e.overridePolicy=function(e){const{target:t,writer:r,overridePolicy:s,...n}=e;return function(e,t){const r=J.call(this,e,t);return r.enabled?{...n,...r}:r}}(e)),e):!0===e?Y():e}function Y(){return{overridePolicy:J}}function J(e,t){const r=!!this.geometryType;let s={enabled:r};return r&&(s={...s,...W.call(this,e,t)}),s}function W(e,t){return{ignoreOrigin:this.originIdOf(t)>c.Gr.DEFAULTS}}let V=class extends(v((0,M.J)((0,E.F)((0,I.dM)((0,A.fY)((0,N.e)((0,S.j)((0,x.J)((0,l.P)(f.A)))))))))){constructor(e){super(e),this.blendMode="normal",this.capabilities=(0,b.f)(!1,!1),this.charts=null,this.definitionExpression=null,this.displayField="",this.effect=null,this.elevationInfo=null,this.featureEffect=null,this.graphType=null,this.labelsVisible=!0,this.labelingInfo=null,this.layerType=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.objectIdField=T.dr,this.objectType=null,this.opacity=1,this.orderBy=null,this.parent=null,this.parentCompositeLayer=null,this.persistenceEnabled=!0,this.popupEnabled=!0,this.popupTemplate=null,this.refreshInterval=0,this.source={openPorts:()=>this.load().then((()=>{const e=new MessageChannel;return new q.default(e.port1,{channel:e,client:{queryFeatures:(e,t={})=>{const r=j.A.fromJSON(e);return this.queryFeaturesJSON(r,t)}}}),[e.port2]}))},this.type="knowledge-graph-sublayer",this.useViewTime=!0,this.visible=!0}get defaultPopupTemplate(){return this.createPopupTemplate()}set featureReduction(e){const t=this._normalizeFeatureReduction(e);this._set("featureReduction",t)}get fields(){const e=[];return this.objectType?.properties?.forEach((t=>{const r="esriFieldTypeOID"===t.fieldType?"esriFieldTypeInteger":t.fieldType;e.push(C.A.fromJSON({name:t.name,type:r,alias:t.alias,defaultValue:t.defaultValue,editable:t.editable,nullable:t.nullable}))})),e.push(C.A.fromJSON({name:this.objectIdField,type:"esriFieldTypeString",alias:this.objectIdField,editable:!1}),C.A.fromJSON({name:T.M1,type:"esriFieldTypeInteger",alias:T.M1,editable:!1}),C.A.fromJSON({name:T.BL,type:"esriFieldTypeInteger",alias:T.BL,editable:!1})),e}get geometryType(){if("link-chart"===this.parentCompositeLayer?.type)return"relationship"===this.graphType?"polyline":"point";const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.geometryType;return t&&"esriGeometryNull"!==t?H.g.fromJSON(t):null}get geometryFieldName(){if("link-chart"===this.parentCompositeLayer?.type)return T.T1;const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name);return e?.name??null}get graphTypeName(){return this.objectType?.name}get hasM(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,r=t?this.objectType?.properties?.[t]:null;return r?.hasM??!1}get hasZ(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,r=t?this.objectType?.properties?.[t]:null;return r?.hasZ??!1}set renderer(e){(0,R.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){return this._isOverridden("renderer")?this._get("renderer"):"link-chart"===this.parentCompositeLayer?.type?"relationship"===this.graphType?(0,i.r)((0,b.F0)(H.g.toJSON("polyline")).renderer):(0,i.r)((0,b.F0)(H.g.toJSON("point")).renderer):(0,i.r)((0,b.F0)(H.g.toJSON(this.geometryType)).renderer)}get spatialReference(){return this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel?.spatialReference??y.A.WGS84}set timeInfo(e){this._set("timeInfo",e)}get title(){return this._isOverridden("title")?this._get("title"):this.graphTypeName}set title(e){this._set("title",e)}writeTitle(e,t){t.title=e??"Layer"}createPopupTemplate(e){return(0,P.tn)(this,e)}createQuery(){return new j.A({where:"1=1",outFields:["*"]})}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){return null}async queryFeatures(e,t){const{resolvedQuery:r,queryEngine:s}=await this._setupQueryObjects(e),n=F.A.fromJSON(await s.executeQuery(r.toJSON(),t?.signal));return n.features.forEach((e=>{e.sourceLayer=this})),n}async queryFeaturesJSON(e,t){const{resolvedQuery:r,queryEngine:s}=await this._setupQueryObjects(e);return await s.executeQuery(r.toJSON(),t?.signal)}async queryFeatureCount(e,t){const{resolvedQuery:r,queryEngine:s}=await this._setupQueryObjects(e);return s.executeQueryForCount(r.toJSON(),t?.signal)}async queryExtent(e={},t){const r={...e,returnGeometry:!0},{resolvedQuery:s,queryEngine:n}=await this._setupQueryObjects(r),i=await n.executeQueryForExtent(s.toJSON(),t?.signal);let o;return o=null!=i.extent?.xmin&&null!=i.extent?.xmax&&null!=i.extent?.ymin&&null!=i.extent?.ymax?new Z.A(i.extent):new Z.A,{count:i.count,extent:o}}async queryObjectIds(e,t){const r=j.A.from(e);let s;if("link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)s=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(r,this,t);s=this.loadQueryEngine(e)}return s.executeQueryForIds(r.toJSON(),t?.signal)}loadQueryEngine(e){const t=new g.A({geometryType:H.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ}),r=new _.do({fieldsIndex:this.fieldsIndex.toJSON(),geometryType:H.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ,objectIdField:this.objectIdField,spatialReference:this.spatialReference.toJSON(),timeInfo:this.timeInfo?.toJSON(),featureStore:t});return r.featureStore.addMany(e),r}async refreshCachedQueryEngine(){const e=await this.parentCompositeLayer.dataManager.getData(new j.A({where:"1=1",outFields:[T.dr]}),this);this._cachedQueryEngine=this.loadQueryEngine(e)}load(e){return this.addResolvingPromise(this.parent.load(e).then((()=>(0,R.sv)(this.timeInfo,this.fieldsIndex)))),Promise.resolve(this)}async _setupQueryObjects(e,t){const r=j.A.from(e),s=r.geometry;if(s&&!s.spatialReference?.isWGS84&&(await(0,h.initializeProjection)(s.spatialReference,m.KK),r.geometry=(0,h.project)(s instanceof G.A||s instanceof $.A||s instanceof U.A?s:s.extent,m.KK)),"link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)return{resolvedQuery:r,queryEngine:this._cachedQueryEngine};const n=await this.parentCompositeLayer.dataManager.getData(r,this,t);return{resolvedQuery:r,queryEngine:this.loadQueryEngine(n)}}};(0,s._)([(0,u.MZ)(Q((0,a.o8)(I.sU)))],V.prototype,"blendMode",void 0),(0,s._)([(0,u.MZ)()],V.prototype,"capabilities",void 0),(0,s._)([(0,u.MZ)({json:{origins:{"web-scene":{write:!1}},write:Y()}})],V.prototype,"charts",void 0),(0,s._)([(0,u.MZ)({readOnly:!0})],V.prototype,"defaultPopupTemplate",null),(0,s._)([(0,u.MZ)({type:String,json:{origins:{service:{read:!1}},name:"layerDefinition.definitionExpression",write:{ignoreOrigin:!0}}})],V.prototype,"definitionExpression",void 0),(0,s._)([(0,u.MZ)()],V.prototype,"displayField",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(I.LF)))],V.prototype,"effect",void 0),(0,s._)([(0,u.MZ)()],V.prototype,"elevationInfo",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(E.Y)))],V.prototype,"featureEffect",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(L.d)))],V.prototype,"featureReduction",null),(0,s._)([(0,u.MZ)()],V.prototype,"fields",null),(0,s._)([(0,u.MZ)()],V.prototype,"geometryType",null),(0,s._)([(0,u.MZ)()],V.prototype,"geometryFieldName",null),(0,s._)([(0,u.MZ)({type:["entity","relationship"],nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],V.prototype,"graphType",void 0),(0,s._)([(0,u.MZ)({type:String,nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],V.prototype,"graphTypeName",null),(0,s._)([(0,u.MZ)()],V.prototype,"hasM",null),(0,s._)([(0,u.MZ)()],V.prototype,"hasZ",null),(0,s._)([(0,u.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],V.prototype,"id",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(k.kF)))],V.prototype,"labelsVisible",void 0),(0,s._)([(0,u.MZ)({type:[D.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:O.w,write:Y()}})],V.prototype,"labelingInfo",void 0),(0,s._)([(0,u.MZ)({readOnly:!0,json:{read:!1,write:{writer(e,t){switch(this.parentCompositeLayer.type){case"link-chart":t.layerType="LinkChartSubLayer";break;case"knowledge-graph":t.layerType=this.geometryType?"KnowledgeGraphSubLayer":"KnowledgeGraphSubTable"}},isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],V.prototype,"layerType",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(k.fV)))],V.prototype,"legendEnabled",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(k.hG)))],V.prototype,"maxScale",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(k.hn)))],V.prototype,"minScale",void 0),(0,s._)([(0,u.MZ)()],V.prototype,"objectIdField",void 0),(0,s._)([(0,u.MZ)()],V.prototype,"objectType",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(k.ke)))],V.prototype,"opacity",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(A.ne)))],V.prototype,"orderBy",void 0),(0,s._)([(0,u.MZ)({clonable:!1})],V.prototype,"parent",void 0),(0,s._)([(0,u.MZ)()],V.prototype,"parentCompositeLayer",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(k.M6)))],V.prototype,"popupEnabled",void 0),(0,s._)([(0,u.MZ)({type:n.A,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],V.prototype,"popupTemplate",void 0),(0,s._)([(0,u.MZ)({type:Number,json:{write:{overridePolicy:W}}})],V.prototype,"refreshInterval",void 0),(0,s._)([(0,u.MZ)({types:o.H,json:{name:"layerDefinition.drawingInfo.renderer",write:Y()}})],V.prototype,"renderer",null),(0,s._)([(0,u.MZ)()],V.prototype,"source",void 0),(0,s._)([(0,u.MZ)()],V.prototype,"spatialReference",null),(0,s._)([(0,u.MZ)({type:B.A,json:{name:"layerDefinition.timeInfo",write:!0,origins:{"web-document":{name:"layerDefinition.timeInfo",read:!0,write:!0},"portal-item":{name:"layerDefinition.timeInfo",read:!0,write:!0}}}})],V.prototype,"timeInfo",null),(0,s._)([(0,u.MZ)({type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],V.prototype,"title",null),(0,s._)([(0,d.K)("title")],V.prototype,"writeTitle",null),(0,s._)([(0,u.MZ)({json:{read:!1}})],V.prototype,"type",void 0),(0,s._)([(0,u.MZ)(Q((0,a.o8)(N.B)))],V.prototype,"useViewTime",void 0),(0,s._)([(0,u.MZ)({type:Boolean,json:{name:"visibility",write:Y()}})],V.prototype,"visible",void 0),V=(0,s._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayer")],V);const X=V},69860:(e,t,r)=>{r.d(t,{A:()=>a}),r(59456);var s=r(90708),n=r(43334),i=r(85342),o=r(65864);class a{constructor(){this._featureLookup=new Map}static getInstance(){return a.instance||(a.instance=new a),a.instance}static resetInstance(){a.instance&&(a.instance=null)}deleteFromStore(e){e.forEach((e=>{this._featureLookup.delete(e)}))}readFromStoreByList(e){const t=[];return e.forEach((e=>{const r=this.readFromStoreById(e);r&&t.push(r)})),t}readFromStoreById(e){return this._featureLookup.get(e)??null}writeToStore(e,t,r){const a=[];return e.forEach((e=>{if(!e?.id)return;e.properties||(e.properties=[]);let l,u=null;if(r&&e.properties[r]&&(u=(0,s.Ux)(e.properties[r])),"originId"in e&&"destinationId"in e&&(e.properties[i.Cz]=e.originId,e.properties[i.KQ]=e.destinationId),e.properties[t]=e.id,e.id&&this._featureLookup.has(e.id)&&this._featureLookup.get(e.id).attributes){const s=this._featureLookup.get(e.id),i=JSON.parse(JSON.stringify(Object.assign(s.attributes,e.properties)));r&&e.properties[r]&&(i[r]=(0,o.rS)(e.properties[r])),l=new n.Om(u?JSON.parse(JSON.stringify(u)):s?.geometry?JSON.parse(JSON.stringify(s.geometry)):null,i,null,e.properties[t])}else l=new n.Om(u?JSON.parse(JSON.stringify(u)):null,e.properties,null,e.properties[t]);this._featureLookup.set(`${e.typeName?`${e.typeName}__${e.id}`:e.id}`,l),a.push(l)})),a}}},85342:(e,t,r)=>{r.d(t,{BL:()=>u,Cz:()=>i,KQ:()=>o,M1:()=>l,T1:()=>a,dr:()=>n,qN:()=>c});var s=r(71402);const n="ESRI__ID",i="ESRI__OriginID",o="ESRI__DestID",a="ESRI__LayoutGeometry",l="ESRI__AggregationCount",u="LC.ESRI__IsSpatial",p={initializeLayersFromClientData:async(e,t,r)=>{if(t||(t=[...e.layers,...e.tables].map((e=>e.graphTypeName))),0===t?.length)return;const n=new Map;for(const r of t)n.set(r,d(e,r));const i=await(0,s.fetchClientDataAtKeys)(e.dataManager.knowledgeGraph,Array.from(n.values()),{requestOptions:{signal:r?.signal}});for(const t of[...e.layers,...e.tables]){const r=t.objectType.name;if(null==r)continue;const s=i.get(d(e,r));if(s){const e=JSON.parse(s);null===e||"object"!=typeof e||e.hasOwnProperty("showLabels")||(e.showLabels=!1),t.read(e,{origin:"service"})}}}},d=(e,t)=>"knowledge-graph"===e.type?`${t}/Map`:`${t}/LinkChart/LinkChartSubLayer`;async function c(e,t,r){return p.initializeLayersFromClientData(e,t,r)}},30504:(e,t,r)=>{r.d(t,{k5:()=>u,aq:()=>l,Wq:()=>p}),r(59456),r(52106),r(61147);var s=r(49186),n=(r(94194),r(85342),r(69860),r(8460),r(66552));(0,n.O)()({none:"none",startAndEnd:"start-and-end",startOnly:"start-only"}),(0,n.O)()({absoluteValue:"absolute-value",multiplier:"multiplier"});const i=new Map([["basic-grid","basic-grid"],["geographic-organic-standard","geographic-organic-standard"],["hierarchical-bottom-to-top","hierarchical-bottom-to-top"],["hierarchical-top-to-bottom","hierarchical-bottom-to-top"],["organic-community","organic-community"],["organic-fusiform","organic-standard"],["organic-leaf-circle","organic-standard"],["organic-standard","organic-standard"],["radial-node-centric","radial-root-centric"],["radial-root-centric","radial-root-centric"],["tree-bottom-to-top","tree-left-to-right"],["tree-left-to-right","tree-left-to-right"],["tree-right-to-left","tree-left-to-right"],["tree-top-to-bottom","tree-left-to-right"],["chronological-mono-timeline","chronological-mono-timeline"],["chronological-multi-timeline","chronological-multi-timeline"]]);var o=r(71402),a=r(42538);async function l(e,t,r){const s=[],n=function(e,t){const r=new Map;if(t.dataModel?.relationshipTypes)for(const e of t.dataModel.relationshipTypes)e.name&&r.set(e.name,[]);for(const t of e)r.has(t.typeName)&&r.get(t.typeName)?.push(t.id);return r}(e,t),i={},l=[];for(const[e,t]of n){if(t.length<1)continue;const r=`${e}_ids`;i[r]=t,l.push(`MATCH (n)-[r:${e}]->(m) WHERE id(r) in $${r} RETURN id(n), labels(n)[0], id(m), labels(m)[0]`)}if(0===l.length)return[];const u=l.join(" UNION "),p=new a.A({openCypherQuery:u,bindParameters:i}),d=(await(0,o.executeQueryStreaming)(t,p,r?.requestOptions)).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await d.read();if(e)break;for(const e of t)s.push({id:e[0],typeName:e[1]}),s.push({id:e[2],typeName:e[3]})}return s}r(40863),r(82799),r(94985),r(39829),r(68249),r(86738);const u=e=>i.get(e)??"radial-root-centric";function p(e){if(!e.spatialReference.isWGS84)throw new s.A("knowledge-graph:layer-support-utils","The utilsExtentToInBoundsRings function only supports WGS84 spatial references.");return e.clone().normalize().map((e=>[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]]))}},82935:(e,t,r)=>{r.d(t,{B:()=>h,e:()=>y});var s=r(90237),n=r(10107),i=(r(44208),r(53966),r(87811),r(36005)),o=r(40608),a=r(89317),l=r(30524),u=r(96184),p=r(73133),d=r(79677),c=r(10184);const h={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:a.K}}},y=e=>{let t=class extends e{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const r=t.timeInfo.exportOptions;if(!r)return null;const s=r.timeOffset,n=p.j.fromJSON(r.timeOffsetUnits);return s&&n?new c.A({value:s,unit:n}):null}set timeInfo(e){(0,l.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,s._)([(0,n.MZ)({type:d.A,json:{write:!1}})],t.prototype,"timeExtent",void 0),(0,s._)([(0,n.MZ)({type:c.A})],t.prototype,"timeOffset",void 0),(0,s._)([(0,i.w)("service","timeOffset",["timeInfo.exportOptions"])],t.prototype,"readOffset",null),(0,s._)([(0,n.MZ)({value:null,type:u.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],t.prototype,"timeInfo",null),(0,s._)([(0,n.MZ)(h)],t.prototype,"useViewTime",void 0),t=(0,s._)([(0,o.$)("esri.layers.mixins.TemporalLayer")],t),t}},96184:(e,t,r)=>{r.d(t,{A:()=>m});var s=r(90237),n=r(69540),i=r(25482),o=r(10107),a=(r(44208),r(53966),r(87811),r(36005)),l=r(40608),u=r(43937),p=r(79677),d=r(10184),c=r(56400);function h(e,t){return d.A.fromJSON({value:e,unit:t})}let y=class extends(n.A.ClonableMixin(i.A)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?p.A.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?h(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?h(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,s._)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],y.prototype,"cumulative",void 0),(0,s._)([(0,o.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"endField",void 0),(0,s._)([(0,o.MZ)({type:p.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"fullTimeExtent",void 0),(0,s._)([(0,a.w)("fullTimeExtent",["timeExtent"])],y.prototype,"readFullTimeExtent",null),(0,s._)([(0,u.K)("fullTimeExtent")],y.prototype,"writeFullTimeExtent",null),(0,s._)([(0,o.MZ)({type:Boolean,json:{write:!0}})],y.prototype,"hasLiveData",void 0),(0,s._)([(0,o.MZ)({type:d.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"interval",void 0),(0,s._)([(0,a.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],y.prototype,"readInterval",null),(0,s._)([(0,u.K)("interval")],y.prototype,"writeInterval",null),(0,s._)([(0,o.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"startField",void 0),(0,s._)([(0,o.MZ)((0,c.P6)("timeReference",!0))],y.prototype,"timeZone",void 0),(0,s._)([(0,o.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"trackIdField",void 0),(0,s._)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],y.prototype,"useTime",void 0),(0,s._)([(0,o.MZ)({type:[Date],json:{read:!1}})],y.prototype,"stops",void 0),y=(0,s._)([(0,l.$)("esri.layers.support.TimeInfo")],y);const m=y},4071:(e,t,r)=>{r.d(t,{$:()=>s,P:()=>n});const s={supportsDate:!1,supportsFixedInterval:!1,supportsAutoInterval:!1,supportsFixedBoundaries:!1,supportsStackBy:!1,supportsSplitBy:!1,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!1,supportedStatistics:void 0,supportedNormalizationTypes:void 0},n={analytics:{supportsCacheHint:!1},attachment:{supportsContentType:!1,supportsExifInfo:!1,supportsKeywords:!1,supportsName:!1,supportsSize:!1,supportsCacheHint:!1,supportsResize:!1},data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:!1},editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsAsyncApplyEdits:!1,zDefault:void 0},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryBins:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s,query:{maxRecordCount:0,maxRecordCountFactor:0,standardMaxRecordCount:0,supportsCacheHint:!1,supportsCentroid:!1,supportsCompactGeometry:!1,supportsCurrentUser:!1,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsReturnMesh:!1,supportsSqlExpression:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsTrueCurve:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsStatistics:!1,tileMaxRecordCount:0}}},17036:(e,t,r)=>{r.d(t,{p:()=>l});var s=r(44208),n=r(53966),i=r(20437),o=r(95466),a=r(30524);function l(){return{fields:{type:[i.A],value:null,set:function(e){if(e&&(0,s.A)("big-integer-warning-enabled")){const t=e.filter((e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8));if(t.length){const e=t.map((e=>`'${e.name}'`)).join(", ");n.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${Number.MAX_SAFE_INTEGER} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return o.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){const e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(const t of e){const r=this.fieldsIndex?.has(t);r||n.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,a.DB)(this.fieldsIndex,e)}}}}},8460:(e,t,r)=>{r.d(t,{$C:()=>f,Hh:()=>o,J:()=>u,JT:()=>l,Tu:()=>y,Wg:()=>m,Xq:()=>_,i6:()=>b,pM:()=>h,tx:()=>a,vJ:()=>g});var s=r(2741);let n,i=null;function o(){return n||(n=r.e(3666).then(r.bind(r,3666)).then((e=>e.l)).then((({default:e})=>e({locateFile:e=>(0,s.s)(`esri/libs/linkchartlayout/${e}`)}))).then((e=>{!function(e){i=e}(e)})),n)}var a,l,u,p,d,c,h,y,m,f,g,_,b,w,v;function T(e){const t=Object.keys(p).filter((e=>isNaN(parseInt(e,10)))).indexOf(e.timeDirection);let r=d.startAndEnd;switch(e.eventsTicksVisualization){case"start-only":r=d.startOnly;break;case"none":r=d.none}return{timeDirection:{value:t>-1?t:p.right},timeBannerUTCOffsetInMinutes:e.timeBannerUTCOffsetInMinutes,eventsTicksVisualization:{value:r},showDurationLineForNonZeroDurationEntityEvents:e.showDurationLineForNonZeroDurationEntityEvents,durationLineWidth:e.durationLineWidth,entityPositionAtDurationRatio:e.entityPositionAtDurationRatio,showNonZeroDurationIntervalBounds:e.showNonZeroDurationIntervalBounds,separateTimeOverlaps:e.separateTimeOverlaps,separateTimelineOverlaps:e.separateTimelineOverlaps,moveFirstBends:e.moveFirstBends,secondBendRatio:e.secondBendRatio,lineSeparationMultiplier:e.lineSeparationMultiplier,spaceSeparatedLinesEvenly:e.spaceSeparatedLinesEvenly,useBezierCurves:e.useBezierCurves,separatedLineShapeRatio:e.separatedLineShapeRatio}}function I(e,t,r,s,n,o){const a=r.length,u=n.length,p=Float64Array.BYTES_PER_ELEMENT,d=Uint32Array.BYTES_PER_ELEMENT,c=Uint8Array.BYTES_PER_ELEMENT,h=16+a*(c+2*p)+u*(2*d),y=i._malloc(h);try{const c=y+16-y%16,h=c+a*p,m=h+a*p,f=m+u*d,g=f+u*d,_=()=>[i.HEAPF64.subarray(c>>3,(c>>3)+a),i.HEAPF64.subarray(h>>3,(h>>3)+a),i.HEAPU32.subarray(m>>2,(m>>2)+u),i.HEAPU32.subarray(f>>2,(f>>2)+u),i.HEAPU8.subarray(g,g+a)],[b,w,v,T,I]=_();b.set(r),w.set(s),v.set(n),T.set(o),I.set(t);const E=e(a,g,c,h,u,m,f);let M=null,A=null;if(E.value===l.Success){const e=i.getLayoutLinksTypes(),t=i.getLayoutLinksVerticesEndIndices(),r=i.getLayoutLinksVertices(),s=i.countLayoutLinksVertices();!u||e&&t?s&&!r?E.value=l.Error:(M={types:new Uint8Array(i.HEAPU8.subarray(e,e+u)),vertexEndIndex:new Uint32Array(i.HEAPU32.subarray(t>>2,(t>>2)+u)),vertices:new Float64Array(i.HEAPF64.subarray(r>>3,(r>>3)+2*s))},A=i.getAuxiliaryGraphicElements()):E.value=l.Error}const[x,S,N,k,L]=_();return r.set(x),s.set(S),n.set(N),o.set(k),t.set(L),{status:E.value,links:M,graphics:A}}finally{i._free(y),i.cleanupLayout()}}(c=a||(a={}))[c.None=0]="None",c[c.IsMovable=1]="IsMovable",c[c.IsGeographic=2]="IsGeographic",c[c.IsRoot=4]="IsRoot",c[c.IsOld=8]="IsOld",function(e){e[e.Success=0]="Success",e[e.Error=1]="Error",e[e.Canceled=2]="Canceled"}(l||(l={})),function(e){e[e.Regular=0]="Regular",e[e.Curved=1]="Curved",e[e.Recursive=2]="Recursive"}(u||(u={})),function(e){e[e.right=0]="right",e[e.left=1]="left",e[e.top=2]="top",e[e.bottom=3]="bottom"}(p||(p={})),function(e){e[e.none=0]="none",e[e.startOnly=1]="startOnly",e[e.startAndEnd=2]="startAndEnd"}(d||(d={})),function(e){e.getMinIdealEdgeLength=function(){return i.getMinIdealEdgeLength()},e.apply=function(e,t,r,s,n,o,a=2,l=1,u=-1){return I(((t,r,s,n,o,p,d)=>i.applyForceDirectedLayout(e,t,r,s,n,o,p,d,a,l,u)),t,r,s,n,o)}}(h||(h={})),function(e){e.apply=function(e,t,r,s,n,o,a=2,l=1,u=-1){return I(((t,r,s,n,o,p,d)=>i.applyCommunityLayout(e,t,r,s,n,o,p,d,a,l,u)),t,r,s,n,o)}}(y||(y={})),function(e){e.apply=function(e,t,r,s,n,o){return I(((t,r,s,n,o,a,l)=>i.applySimpleLayout(e,t,r,s,n,o,a,l)),t,r,s,n,o)}}(m||(m={})),function(e){e.apply=function(e,t,r,s,n,o){return I(((t,r,s,n,o,a,l)=>i.applyHierarchicalLayout(e,t,r,s,n,o,a,l)),t,r,s,n,o)}}(f||(f={})),function(e){e.apply=function(e,t,r,s,n,o){return I(((t,r,s,n,o,a,l)=>i.applyRadialTreeLayout(e,t,r,s,n,o,a,l)),t,r,s,n,o)}}(g||(g={})),function(e){e.apply=function(e,t,r,s,n,o){return I(((t,r,s,n,o,a,l)=>i.applySmartTreeLayout(e,t,r,s,n,o,a,l)),t,r,s,n,o)}}(_||(_={})),function(e){e.apply=function(e,t,r,s,n,o,a,u,c,h,y,m){const f={timeDirection:p.right,timeBannerUTCOffsetInMinutes:0,eventsTicksVisualization:d.startAndEnd,showDurationLineForNonZeroDurationEntityEvents:!0,durationLineWidth:5,entityPositionAtDurationRatio:1,showNonZeroDurationIntervalBounds:!1,separateTimeOverlaps:!0,separateTimelineOverlaps:!0,moveFirstBends:!0,secondBendRatio:.3,lineSeparationMultiplier:1,spaceSeparatedLinesEvenly:!1,useBezierCurves:!1,separatedLineShapeRatio:0};return I(((t,r,s,a,u,p,d)=>{if(n.length!==t)return{value:l.Error};if(o.length!==t)return{value:l.Error};if(c.length!==u)return{value:l.Error};if(h.length!==u)return{value:l.Error};const g=Float64Array.BYTES_PER_ELEMENT,_=16,b=i._malloc(_+t*g),w=i._malloc(_+t*g),v=i._malloc(_+u*g),I=i._malloc(_+u*g),E=b+_-b%_,M=w+_-w%_,A=v+_-v%_,x=I+_-I%_;try{i.HEAPF64.subarray(E>>3,(E>>3)+t).set(n),i.HEAPF64.subarray(M>>3,(M>>3)+t).set(o),i.HEAPF64.subarray(A>>3,(A>>3)+u).set(c),i.HEAPF64.subarray(x>>3,(x>>3)+u).set(h);const l=T(Object.assign(f,m));return i.applyChronologicalLayout(e,t,r,s,a,E,M,u,p,d,A,x,y,l)}finally{i._free(b),i._free(w),i._free(v),i._free(I)}}),t,r,s,a,u)}}(b||(b={})),function(e){e[e.Undirected=0]="Undirected",e[e.Directed=1]="Directed",e[e.Reversed=2]="Reversed"}(w||(w={})),function(e){e[e.ByCC_Raw=0]="ByCC_Raw",e[e.ByCC_NormalizeGlobally=1]="ByCC_NormalizeGlobally",e[e.ByCC_NormalizeByCC=2]="ByCC_NormalizeByCC"}(v||(v={}))},73133:(e,t,r)=>{r.d(t,{j:()=>s});const s=(0,r(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},25927:(e,t,r)=>{r.d(t,{A:()=>u});var s=r(90237),n=(r(59456),r(10107)),i=(r(44208),r(53966),r(87811),r(40608)),o=r(54238),a=r(86738);let l=class extends o.A{constructor(e){super(e),this.layoutGeometry=null}};(0,s._)([(0,n.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,s._)([(0,i.$)("esri.rest.knowledgeGraph.Entity")],l);const u=l},54238:(e,t,r)=>{r.d(t,{A:()=>l});var s=r(90237),n=r(10107),i=(r(44208),r(53966),r(87811),r(40608)),o=r(77901);let a=class extends o.A{constructor(e){super(e),this.typeName=null,this.id=null}};(0,s._)([(0,n.MZ)({type:String,json:{write:!0}})],a.prototype,"typeName",void 0),(0,s._)([(0,n.MZ)({type:String,json:{write:!0}})],a.prototype,"id",void 0),a=(0,s._)([(0,i.$)("esri.rest.knowledgeGraph.GraphNamedObject")],a);const l=a},77901:(e,t,r)=>{r.d(t,{A:()=>l});var s=r(90237),n=r(25482),i=r(10107),o=(r(44208),r(53966),r(87811),r(40608));let a=class extends n.A{constructor(e){super(e),this.properties=null}};(0,s._)([(0,i.MZ)({json:{write:!0}})],a.prototype,"properties",void 0),a=(0,s._)([(0,o.$)("esri.rest.knowledgeGraph.GraphObject")],a);const l=a},42538:(e,t,r)=>{r.d(t,{A:()=>p});var s=r(90237),n=r(10107),i=(r(44208),r(53966),r(87811),r(40608)),o=r(69622);let a=class extends o.A{constructor(e){super(e),this.openCypherQuery=""}};(0,s._)([(0,n.MZ)()],a.prototype,"openCypherQuery",void 0),a=(0,s._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQuery")],a);const l=a;let u=class extends l{constructor(e){super(e),this.bindParameters=null,this.bindGeometryQuantizationParameters=null,this.outputQuantizationParameters=null,this.outputSpatialReference=null,this.provenanceBehavior=null}};(0,s._)([(0,n.MZ)()],u.prototype,"bindParameters",void 0),(0,s._)([(0,n.MZ)()],u.prototype,"bindGeometryQuantizationParameters",void 0),(0,s._)([(0,n.MZ)()],u.prototype,"outputQuantizationParameters",void 0),(0,s._)([(0,n.MZ)()],u.prototype,"outputSpatialReference",void 0),(0,s._)([(0,n.MZ)()],u.prototype,"provenanceBehavior",void 0),u=(0,s._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQueryStreaming")],u);const p=u},40662:(e,t,r)=>{r.d(t,{A:()=>a});var s=r(90237),n=(r(53966),r(44208),r(87811),r(49186),r(40608)),i=r(77901);let o=class extends i.A{constructor(e){super(e)}};o=(0,s._)([(0,n.$)("esri.rest.knowledgeGraph.ObjectValue")],o);const a=o},42095:(e,t,r)=>{r.d(t,{A:()=>u});var s=r(90237),n=r(25482),i=r(10107),o=(r(44208),r(53966),r(87811),r(40608)),a=r(77901);let l=class extends n.A{constructor(e){super(e),this.path=null}};(0,s._)([(0,i.MZ)({type:[a.A],json:{write:!0}})],l.prototype,"path",void 0),l=(0,s._)([(0,o.$)("esri.rest.knowledgeGraph.Path")],l);const u=l},23150:(e,t,r)=>{r.d(t,{A:()=>u});var s=r(90237),n=(r(59456),r(10107)),i=(r(44208),r(53966),r(87811),r(40608)),o=r(54238),a=r(82799);let l=class extends o.A{constructor(e){super(e),this.originId=null,this.destinationId=null,this.layoutGeometry=null}};(0,s._)([(0,n.MZ)({type:String,json:{write:!0}})],l.prototype,"originId",void 0),(0,s._)([(0,n.MZ)({type:String,json:{write:!0}})],l.prototype,"destinationId",void 0),(0,s._)([(0,n.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,s._)([(0,i.$)("esri.rest.knowledgeGraph.Relationship")],l);const u=l},10184:(e,t,r)=>{r.d(t,{A:()=>c});var s=r(90237),n=r(69540),i=r(25482),o=r(88930),a=r(10107),l=(r(44208),r(53966),r(87811),r(93223)),u=r(40608),p=r(73133);let d=class extends(n.A.ClonableMixin(i.A)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,s._)([(0,l.e)(p.j,{nonNullable:!0})],d.prototype,"unit",void 0),(0,s._)([(0,a.MZ)({type:Number,json:{write:!0},nonNullable:!0})],d.prototype,"value",void 0),d=(0,s._)([(0,u.$)("esri.time.TimeInterval")],d);const c=d}}]);
|