@arcgis/core 5.0.0-next.5 → 5.0.0-next.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (137) hide show
  1. package/analysis/VolumeMeasurement/volumeMeasurementConfiguration.js +1 -1
  2. package/assets/esri/core/workers/RemoteClient.js +1 -1
  3. package/assets/esri/core/workers/chunks/020c8913d8e35d63080b.js +1 -0
  4. package/assets/esri/core/workers/chunks/{c2b47a7dc961863d283f.js → 02e69f0c63d97661da60.js} +1 -1
  5. package/assets/esri/core/workers/chunks/087973e7c4fea5fcfa5e.js +1 -0
  6. package/assets/esri/core/workers/chunks/{929ece362604dc301229.js → 17acde0245ecd956306c.js} +1 -1
  7. package/assets/esri/core/workers/chunks/{8cea114168d849c38b1b.js → 20278683bddc8c2d8136.js} +1 -1
  8. package/assets/esri/core/workers/chunks/{dc4982b0ac007bd70213.js → 22d6b8102e75bdef204c.js} +1 -1
  9. package/assets/esri/core/workers/chunks/{3271614322ba4b44fb5a.js → 279366e6b743f9680603.js} +1 -1
  10. package/assets/esri/core/workers/chunks/{f7c99e9c8d19352af38d.js → 3ac7562ea90f91a9f30c.js} +1 -1
  11. package/assets/esri/core/workers/chunks/3f3d492f1093b7832aab.js +1 -0
  12. package/assets/esri/core/workers/chunks/464d42bebb365287808d.js +1 -0
  13. package/assets/esri/core/workers/chunks/{d570c75a425aa29672c8.js → 4d599008e1ea42321b37.js} +1 -1
  14. package/assets/esri/core/workers/chunks/{0686243904381ef863dc.js → 53bd8996e8812f1ad7b2.js} +1 -1
  15. package/assets/esri/core/workers/chunks/{762fe93015b705546188.js → 5bd36dbf46c25bd961c8.js} +1 -1
  16. package/assets/esri/core/workers/chunks/{b7a17927e14f502006b4.js → 5ea0c62016d56990787b.js} +1 -1
  17. package/assets/esri/core/workers/chunks/{2ea6985da4eb0107bb9d.js → 5fc7b61f467f1d60a284.js} +1 -1
  18. package/assets/esri/core/workers/chunks/{a87521ebe632bf783ef4.js → 62a49cfd9a2508950e9f.js} +1 -1
  19. package/assets/esri/core/workers/chunks/{ec13053af1999701464a.js → 6826fe54562dcdc054d7.js} +1 -1
  20. package/assets/esri/core/workers/chunks/{309c5f69ea06f3081d83.js → 73487b9d85e726e9c012.js} +1 -1
  21. package/assets/esri/core/workers/chunks/7413e582bc2b16af6a0f.js +1 -0
  22. package/assets/esri/core/workers/chunks/{88d942cd25bef74fd50a.js → 7461124454bfb4fb6474.js} +1 -1
  23. package/assets/esri/core/workers/chunks/{147ad5fdd02f46b6da24.js → 7544316a75dbd981aea6.js} +1 -1
  24. package/assets/esri/core/workers/chunks/{0f8847f9ae3068833fa4.js → 75bf27271a31e26e1b21.js} +1 -1
  25. package/assets/esri/core/workers/chunks/{630efe10c871425b6a95.js → 76ae1702fecc7ad7017c.js} +1 -1
  26. package/assets/esri/core/workers/chunks/{de1f75c907152df7e788.js → 794748fd1edc29a621cd.js} +1 -1
  27. package/assets/esri/core/workers/chunks/{e1258b6a404e58878c7a.js → 7aaaebbabee27690283c.js} +1 -1
  28. package/assets/esri/core/workers/chunks/{6a69dafeb7c9ca8a3d84.js → 7c4a63aeead2505d6f02.js} +1 -1
  29. package/assets/esri/core/workers/chunks/{d84373a6ec94dcfec8c2.js → 88074189fa10c335370b.js} +1 -1
  30. package/assets/esri/core/workers/chunks/{a8c4fd779e454e4075c4.js → 8833c3d168951be4bf20.js} +1 -1
  31. package/assets/esri/core/workers/chunks/{85622fe99f4d08afe875.js → 8a314b3790313e6dc5db.js} +1 -1
  32. package/assets/esri/core/workers/chunks/{b0b2670596d6d8c32b5e.js → 8c056eac35d05d9524b7.js} +1 -1
  33. package/assets/esri/core/workers/chunks/{1a713dcc9971e1935401.js → 8f56f298e7c1a283f407.js} +1 -1
  34. package/assets/esri/core/workers/chunks/{dabc5a38a472c9719df9.js → 8ffd4710d168c2fcfd96.js} +1 -1
  35. package/assets/esri/core/workers/chunks/{1da74aa308ded5748ef5.js → 90250e9239c173aace88.js} +1 -1
  36. package/assets/esri/core/workers/chunks/90b2b43b8b54c9a1ec35.js +1 -0
  37. package/assets/esri/core/workers/chunks/90f8b4bda28af43ea019.js +1 -0
  38. package/assets/esri/core/workers/chunks/{89027f6800e17fab8973.js → 9486032af3e934d85582.js} +1 -1
  39. package/assets/esri/core/workers/chunks/95c594a87b732f5c4979.js +1 -0
  40. package/assets/esri/core/workers/chunks/{239377336a2009caea01.js → 99859dce1925b406ccd0.js} +1 -1
  41. package/assets/esri/core/workers/chunks/{a137c27ce078bea44f89.js → 9e8dceef4c961f56940d.js} +1 -1
  42. package/assets/esri/core/workers/chunks/{f5b7e7f2860a825ed373.js → 9fac5a12e878cd745354.js} +1 -1
  43. package/assets/esri/core/workers/chunks/{f779034623980bf9a37c.js → a06bac9b8f9e18874de8.js} +2 -2
  44. package/assets/esri/core/workers/chunks/{01642fe19e81bfa33eb5.js → a395373e3173e6458a56.js} +1 -1
  45. package/assets/esri/core/workers/chunks/a3991ae8caa713d4ddcd.js +1 -0
  46. package/assets/esri/core/workers/chunks/{a6ac1ff89c40f3a4797a.js → a712cdff78fc826acd8c.js} +1 -1
  47. package/assets/esri/core/workers/chunks/{af3fc2562bb6d217adf6.js → aa54b6f2aba6952af149.js} +1 -1
  48. package/assets/esri/core/workers/chunks/ac26e3e77df4302f47a2.js +1 -0
  49. package/assets/esri/core/workers/chunks/af5fc5d6c1d072a27df1.js +1 -0
  50. package/assets/esri/core/workers/chunks/{bc3bcf88b252760e2574.js → b3028b1ff75eafd0c358.js} +1 -1
  51. package/assets/esri/core/workers/chunks/{5875a51b97ee9bd438a0.js → bc241c7735e4efba734a.js} +1 -1
  52. package/assets/esri/core/workers/chunks/{56916e56c20465428dd4.js → be3b874f86f627f4fa98.js} +1 -1
  53. package/assets/esri/core/workers/chunks/c4e4da69969499a89a2c.js +1 -0
  54. package/assets/esri/core/workers/chunks/c8733cd621105afab2ac.js +1 -0
  55. package/assets/esri/core/workers/chunks/ccc0da0e01f023c8aa1f.js +1 -0
  56. package/assets/esri/core/workers/chunks/{c0b7e86860838638537f.js → cd1930f08e1fc8b30b14.js} +1 -1
  57. package/assets/esri/core/workers/chunks/{551c6c89b51b99f4864b.js → d1fe816b6990918c13c7.js} +1 -1
  58. package/assets/esri/core/workers/chunks/{8605ec4678eb4511c715.js → d305a21666b1ed5bf33d.js} +1 -1
  59. package/assets/esri/core/workers/chunks/{037b2548bf85e2d7c6ac.js → d40f57f9fc47f9a9f97c.js} +1 -1
  60. package/assets/esri/core/workers/chunks/{a29d7205394cb8b2a847.js → d97fadbc69e055d183a0.js} +1 -1
  61. package/assets/esri/core/workers/chunks/dedc4583b5f32a278124.js +1 -0
  62. package/assets/esri/core/workers/chunks/{e5bcc44f3dc6fc90835a.js → e5a06ce0ef6a9a90e100.js} +1 -1
  63. package/assets/esri/core/workers/chunks/f0e0a63962784acb4ba1.js +1 -0
  64. package/assets/esri/core/workers/chunks/f4d0ae6be1b3984228d0.js +1 -0
  65. package/assets/esri/core/workers/chunks/{7c5c272612198db83851.js → f5e47eea8720ba84665b.js} +1 -1
  66. package/assets/esri/core/workers/chunks/{fa4411e0a5ac3fcba365.js → f65c0102af17390a50ac.js} +1 -1
  67. package/assets/esri/core/workers/chunks/f6c11c8ac687de3ef1ab.js +1 -0
  68. package/assets/esri/core/workers/chunks/{7596d005a4dc3964b140.js → f6c8beb60f6d29945a2e.js} +1 -1
  69. package/assets/esri/core/workers/chunks/{a2a284d4dd5caaecbc2e.js → f746e3f7ebff2bbdf333.js} +1 -1
  70. package/assets/esri/core/workers/chunks/f9324e88c359c03f35aa.js +1 -0
  71. package/assets/esri/core/workers/chunks/{cfa3164e7fa1884dc2b9.js → facb3886714222772ab2.js} +1 -1
  72. package/assets/esri/core/workers/chunks/{aa6eb55e4fb57c4e8eeb.js → fd2efd1d1cf9d95a87e6.js} +1 -1
  73. package/assets/esri/core/workers/chunks/{fe3f95fda29e4844b153.js → fe77ae6cf232a7a3298e.js} +1 -1
  74. package/assets/esri/core/workers/chunks/{2ce4a0fe4fae63c43a81.js → ff35a077ac6776469805.js} +1 -1
  75. package/assets/esri/themes/base/widgets/_UtilityNetworkTrace.scss +14 -4
  76. package/assets/esri/themes/dark/main.css +1 -1
  77. package/assets/esri/themes/light/main.css +1 -1
  78. package/assets/esri/themes/light/view.css +1 -1
  79. package/config.js +1 -1
  80. package/core/Identifiable.js +1 -1
  81. package/core/MultiOriginJSONSupport.js +1 -1
  82. package/core/NumericIdentifiable.js +5 -0
  83. package/core/WriteableMultiOriginJSONMixin.js +5 -0
  84. package/core/performance.js +5 -0
  85. package/core/scheduling.js +1 -1
  86. package/editing/sharedTemplates/executor/support/createFeatureServiceEdit.js +1 -1
  87. package/interfaces.d.ts +18 -2
  88. package/kernel.js +1 -1
  89. package/layers/support/MediaElementBase.js +1 -1
  90. package/layers/support/fieldUtils.js +1 -1
  91. package/package.json +3 -3
  92. package/support/basemapDefinitions.js +1 -1
  93. package/support/revision.js +1 -1
  94. package/symbols/cim/effects/EffectTaperedPolygon.js +1 -1
  95. package/undoredo/support/Services.js +1 -1
  96. package/views/2d/constraints/GeometryConstraint.js +1 -1
  97. package/views/2d/constraints/RotationConstraint.js +1 -1
  98. package/views/2d/constraints/ZoomConstraint.js +1 -1
  99. package/views/2d/engine/vectorTiles/decluttering/SymbolFader.js +1 -1
  100. package/views/2d/layers/FeatureLayerView2D.js +1 -1
  101. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillVisualization.js +1 -1
  102. package/views/3d/layers/FlowSubView3D.js +1 -1
  103. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  104. package/views/3d/layers/graphics/Graphics3DFeatureStore.js +1 -1
  105. package/views/3d/layers/i3s/I3SOverrides.js +1 -1
  106. package/views/3d/layers/support/ImageHighlightHelper3D.js +1 -1
  107. package/views/3d/layers/support/lyr3dTypeConversions.js +1 -1
  108. package/views/3d/support/flow/FlowSubViewExtent3D.js +1 -1
  109. package/views/3d/support/flow/StreamlineResources3DOverlay.js +1 -1
  110. package/views/3d/support/flow/StreamlineResources3DShape.js +1 -1
  111. package/views/3d/terrain/OverlayRenderer.js +1 -1
  112. package/views/3d/webgl-engine/statistics/RendererPerformanceInfo.js +1 -1
  113. package/views/analysis/ElevationProfile/constants.js +1 -1
  114. package/views/support/Scheduler.js +1 -1
  115. package/widgets/Attachments/AttachmentsViewModel.js +1 -1
  116. package/widgets/FeatureTable/Grid/GridViewModel.js +1 -1
  117. package/widgets/Search/LayerSearchSource.js +1 -1
  118. package/widgets/UtilityNetworkTrace.js +1 -1
  119. package/assets/esri/core/workers/chunks/0366b78b0ccf4ed5f6ac.js +0 -1
  120. package/assets/esri/core/workers/chunks/0429c1a3690f20647c9f.js +0 -1
  121. package/assets/esri/core/workers/chunks/0f100e163e1847e04155.js +0 -1
  122. package/assets/esri/core/workers/chunks/1eedac33c9fcd7681427.js +0 -1
  123. package/assets/esri/core/workers/chunks/2f03d33f4ca8a48461fc.js +0 -1
  124. package/assets/esri/core/workers/chunks/50864c1924030e62497d.js +0 -1
  125. package/assets/esri/core/workers/chunks/655360995c1cbc78a5a3.js +0 -1
  126. package/assets/esri/core/workers/chunks/71762199aef5d3107da2.js +0 -1
  127. package/assets/esri/core/workers/chunks/72c851c400752094b162.js +0 -1
  128. package/assets/esri/core/workers/chunks/7558919912f7fdc4837b.js +0 -1
  129. package/assets/esri/core/workers/chunks/829bc5dbda2f51561446.js +0 -1
  130. package/assets/esri/core/workers/chunks/98311fec6c16a1b23586.js +0 -1
  131. package/assets/esri/core/workers/chunks/a61cb4f1ca282bf8b75d.js +0 -1
  132. package/assets/esri/core/workers/chunks/bc6619307f312f9241bf.js +0 -1
  133. package/assets/esri/core/workers/chunks/bfc1e8aec7aace3ff30e.js +0 -1
  134. package/assets/esri/core/workers/chunks/c134ebbaeac514cbd657.js +0 -1
  135. package/assets/esri/core/workers/chunks/c368a8e8d2f1535af446.js +0 -1
  136. package/assets/esri/core/workers/chunks/d886fb97bdb348a16f25.js +0 -1
  137. package/assets/esri/core/workers/chunks/e6a86cad44056735ed26.js +0 -1
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8948],{6455:(e,t,i)=>{i.d(t,{FJ:()=>b,Dp:()=>w,KV:()=>_});var n=i(31635),r=i(93637),s=i(10107),o=(i(44208),i(53966),i(87811),i(64108)),a=i(89317),l=i(69540),p=i(7762),d=i(25482),u=i(43937),c=i(83960),h=i(13069);const y={write:{overridePolicy:(e,t,i)=>({enabled:!i||"scale"===i.filterMode})}};let m=class extends((0,l.OU)(d.o)){constructor(e){super(e),this.id=(0,h.lk)(),this.maxScale=0,this.minScale=0,this.title="",this.where=null}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],m.prototype,"id",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:y})],m.prototype,"maxScale",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:y})],m.prototype,"minScale",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],m.prototype,"title",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],m.prototype,"where",void 0),m=(0,n.Cg)([(0,o.$)("esri.layers.support.DisplayFilter")],m);var f=i(41560);let g=class extends((0,l.OU)(d.o)){constructor(e){super(e),this.activeFilterId=null,this.filters=new(p.A.ofType(m)),this.mode="manual"}writeFilters(e,t,i,n){const r=e.toArray();"scale"===this.mode&&r.sort((e,t)=>{const i=(0,c.oW)(t.minScale,e.minScale),n=e.maxScale-t.maxScale;return 0===i?n:i}),t[i]=r.map(e=>e.toJSON(n))}write(e,t){return super.write(e,(0,f.mW)(this,t))}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:{overridePolicy:(e,t,i)=>({enabled:"manual"===i.filterMode,isRequired:!0})}}})],g.prototype,"activeFilterId",void 0),(0,n.Cg)([(0,s.MZ)({type:p.A.ofType(m),nonNullable:!0,json:{write:!0}})],g.prototype,"filters",void 0),(0,n.Cg)([(0,u.K)("filters")],g.prototype,"writeFilters",null),(0,n.Cg)([(0,s.MZ)({type:["manual","scale"],nonNullable:!0,json:{name:"filterMode",write:!0}})],g.prototype,"mode",void 0),g=(0,n.Cg)([(0,o.$)("esri.layers.support.DisplayFilterInfo")],g);const b=e=>{const t=e;let i=class extends t{constructor(){super(...arguments),this.displayFilterEnabled=!0,this.displayFilterInfo=null}};return(0,n.Cg)([(0,s.MZ)(w)],i.prototype,"displayFilterEnabled",void 0),(0,n.Cg)([(0,s.MZ)(_)],i.prototype,"displayFilterInfo",void 0),i=(0,n.Cg)([(0,o.$)("esri.layers.mixins.DisplayFilteredLayer")],i),i},w={type:Boolean,json:{name:"layerDefinition.disableDisplayFilter",read:{reader:e=>!e},write:{layerContainerTypes:a.K,writer(e,t,i){(0,r.sM)(i,!e,t)}},origins:{"web-scene":{write:!1,read:!1}}}},_={type:g,json:{name:"layerDefinition.displayFilterInfo",write:{enabled:!0,allowNull:!0,layerContainerTypes:a.K},origins:{"web-scene":{write:!1,read:!1}}}}},6518:(e,t,i)=>{i.d(t,{F:()=>a});var n=i(44208),r=i(75503),s=i(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 r.wq(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((i,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,s.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,i){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,i)}(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()))}}},8460:(e,t,i)=>{i.d(t,{$C:()=>y,Hh:()=>o,Tu:()=>c,Wg:()=>h,Xq:()=>f,i6:()=>g,pM:()=>u,vJ:()=>m});var n=i(2741);let r,s=null;function o(){return r||(r=i.e(3666).then(i.bind(i,3666)).then(e=>e.l).then(({default:e})=>e({locateFile:e=>(0,n.s)(`esri/libs/linkchartlayout/${e}`)})).then(e=>{!function(e){s=e}(e)}),r)}const a={right:0,left:1,top:2,bottom:3},l={none:0,"start-only":1,"start-and-end":2};function p(e){const t={timeDirection:"right",timeBannerUTCOffsetInMinutes:0,eventsTicksVisualization:"start-and-end",showDurationLineForNonZeroDurationEntityEvents:!0,durationLineWidth:5,entityPositionAtDurationRatio:1,showNonZeroDurationIntervalBounds:!1,separateTimeOverlaps:!0,separateTimelineOverlaps:!0,moveFirstBends:!0,secondBendRatio:.3,lineSeparationMultiplier:1,spaceSeparatedLinesEvenly:!1,useBezierCurves:!1,separatedLineShapeRatio:0,...e?.toJSON(),eventsTicksVisualization:e?.eventsTicksVisualization??"start-and-end"};return{...t,timeDirection:{value:a[t.timeDirection]??a.right},eventsTicksVisualization:{value:l[t.eventsTicksVisualization]??l["start-and-end"]}}}function d(e,t,i,n,r,o){const a=i.length,l=r.length,p=Float64Array.BYTES_PER_ELEMENT,d=Uint32Array.BYTES_PER_ELEMENT,u=Uint8Array.BYTES_PER_ELEMENT,c=16+a*(u+2*p)+l*(2*d),h=s._malloc(c);try{const u=h+16-h%16,c=u+a*p,y=c+a*p,m=y+l*d,f=m+l*d,g=()=>[s.HEAPF64.subarray(u>>3,(u>>3)+a),s.HEAPF64.subarray(c>>3,(c>>3)+a),s.HEAPU32.subarray(y>>2,(y>>2)+l),s.HEAPU32.subarray(m>>2,(m>>2)+l),s.HEAPU8.subarray(f,f+a)],[b,w,_,M,I]=g();b.set(i),w.set(n),_.set(r),M.set(o),I.set(t);const T=e(a,f,u,c,l,y,m);let C=null,v=null;if(0===T.value){const e=s.getLayoutLinksTypes(),t=s.getLayoutLinksVerticesEndIndices(),i=s.getLayoutLinksVertices(),n=s.countLayoutLinksVertices();!l||e&&t?n&&!i?T.value=1:(C={types:new Uint8Array(s.HEAPU8.subarray(e,e+l)),vertexEndIndex:new Uint32Array(s.HEAPU32.subarray(t>>2,(t>>2)+l)),vertices:new Float64Array(s.HEAPF64.subarray(i>>3,(i>>3)+2*n))},v=s.getAuxiliaryGraphicElements()):T.value=1}const[x,A,E,S,N]=g();return i.set(x),n.set(A),r.set(E),o.set(S),t.set(N),{status:T.value,links:C,graphics:v}}finally{s._free(h),s.cleanupLayout()}}var u,c,h,y,m,f,g,b;(b=u||(u={})).getMinIdealEdgeLength=function(){return s.getMinIdealEdgeLength()},b.apply=function(e,t,i,n,r,o,a=2,l=1,p=-1){return d((t,i,n,r,o,d,u)=>s.applyForceDirectedLayout(e,t,i,n,r,o,d,u,a,l,p),t,i,n,r,o)},function(e){e.apply=function(e,t,i,n,r,o,a=2,l=1,p=-1){return d((t,i,n,r,o,d,u)=>s.applyCommunityLayout(e,t,i,n,r,o,d,u,a,l,p),t,i,n,r,o)}}(c||(c={})),function(e){e.apply=function(e,t,i,n,r,o){return d((t,i,n,r,o,a,l)=>s.applySimpleLayout(e,t,i,n,r,o,a,l),t,i,n,r,o)}}(h||(h={})),function(e){e.apply=function(e,t,i,n,r,o){return d((t,i,n,r,o,a,l)=>s.applyHierarchicalLayout(e,t,i,n,r,o,a,l),t,i,n,r,o)}}(y||(y={})),function(e){e.apply=function(e,t,i,n,r,o){return d((t,i,n,r,o,a,l)=>s.applyRadialTreeLayout(e,t,i,n,r,o,a,l),t,i,n,r,o)}}(m||(m={})),function(e){e.apply=function(e,t,i,n,r,o){return d((t,i,n,r,o,a,l)=>s.applySmartTreeLayout(e,t,i,n,r,o,a,l),t,i,n,r,o)}}(f||(f={})),function(e){e.apply=function(e,t,i,n,r,o,a,l,u,c,h,y){return d((t,i,n,a,l,d,m)=>{if(r.length!==t)return{value:1};if(o.length!==t)return{value:1};if(u.length!==l)return{value:1};if(c.length!==l)return{value:1};const f=Float64Array.BYTES_PER_ELEMENT,g=16,b=s._malloc(g+t*f),w=s._malloc(g+t*f),_=s._malloc(g+l*f),M=s._malloc(g+l*f),I=b+g-b%g,T=w+g-w%g,C=_+g-_%g,v=M+g-M%g;try{return s.HEAPF64.subarray(I>>3,(I>>3)+t).set(r),s.HEAPF64.subarray(T>>3,(T>>3)+t).set(o),s.HEAPF64.subarray(C>>3,(C>>3)+l).set(u),s.HEAPF64.subarray(v>>3,(v>>3)+l).set(c),s.applyChronologicalLayout(e,t,i,n,a,I,T,l,d,m,C,v,h,p(y))}finally{s._free(b),s._free(w),s._free(_),s._free(M)}},t,i,n,a,l)}}(g||(g={}))},10184:(e,t,i)=>{i.d(t,{A:()=>u});var n=i(31635),r=i(69540),s=i(25482),o=i(88930),a=i(10107),l=(i(44208),i(53966),i(87811),i(93223)),p=i(64108),d=i(73133);let u=class extends((0,r.OU)(s.o)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,n.Cg)([(0,l.e)(d.j,{nonNullable:!0})],u.prototype,"unit",void 0),(0,n.Cg)([(0,a.MZ)({type:Number,json:{write:!0},nonNullable:!0})],u.prototype,"value",void 0),u=(0,n.Cg)([(0,p.$)("esri.time.TimeInterval")],u)},15375:(e,t,i)=>{i.d(t,{BL:()=>l,Cz:()=>r,KQ:()=>s,M1:()=>a,T1:()=>o,dr:()=>n});const n="ESRI__ID",r="ESRI__OriginID",s="ESRI__DestID",o="ESRI__LayoutGeometry",a="ESRI__AggregationCount",l="LC.ESRI__IsSpatial"},17036:(e,t,i)=>{i.d(t,{p:()=>l});var n=i(44208),r=i(53966),s=i(20437),o=i(95466),a=i(30524);function l(){return{fields:{type:[s.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(", ");r.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 i=this.fieldsIndex?.has(t);i||r.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)}}}}},23150:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(64108)),o=i(82799),a=i(54238);let l=class extends a.A{constructor(e){super(e),this.originId=null,this.destinationId=null,this.layoutGeometry=null}};(0,n.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],l.prototype,"originId",void 0),(0,n.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],l.prototype,"destinationId",void 0),(0,n.Cg)([(0,r.MZ)({type:o.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.Relationship")],l)},24137:(e,t,i)=>{i.d(t,{P:()=>T});var n=i(31635),r=i(69622),s=i(49186),o=i(53966),a=i(91869),l=i(74887),p=i(39516),d=i(10107),u=(i(44208),i(87811),i(64108)),c=i(5443),h=i(39829),y=i(91218),m=i(21325),f=i(15375);const g=(e,t)=>{if("column-reference"===e.type)return e.column===t.systemOidFieldName?"ID(n)":`n.${e.column}`;if("string"===e.type)return`'${e.value}'`;if("number"===e.type)return`${e.value}`;if("binary-expression"===e.type&&t.supportedSqlTypes.has(e.left.type)&&t.supportedSqlTypes.has(e.right.type)&&t.supportedSqlOperators.has(e.operator))return`${g(e.left,t)} ${e.operator} ${g(e.right,t)}`;if("binary-expression"===e.type&&"LIKE"===e.operator){let i="";if("function"===e.left.type&&"column-reference"===e.left.args.value[0].type)i+=`lower(n.${e.left.args.value[0].column})`;else{if("column-reference"!==e.left.type)return t.unsupportedOperationFound=!0,"";i+=`lower(n.${e.left.column})`}if(i+=" CONTAINS (","string"!==e.right.type)return t.unsupportedOperationFound=!0,"";{let t=e.right.value;t.startsWith("%")&&(t=t.slice(1)),t.endsWith("%")&&(t=t.slice(0,-1)),i+=`'${t.toLowerCase()}')`}return i}return t.unsupportedOperationFound=!0,""};var b=i(69860),w=i(30504),_=i(62568),M=i(42538),I=i(61956);let T=class extends r.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(i=>{i.name&&(t.set(i.name,"entity"),this._processingCacheUpdatesLookup.set(i.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.entityTypeNames.add(i.name),i.properties?.forEach(e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(i.name,{name:e.name??"",geometryType:e.geometryType})}))}),e.knowledgeGraph.dataModel.relationshipTypes?.forEach(i=>{i.name&&(t.set(i.name,"relationship"),this._processingCacheUpdatesLookup.set(i.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.relationshipTypeNames.add(i.name),i.properties?.forEach(e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(i.name,{name:e.name??"",geometryType:e.geometryType})}))}),e.inclusionModeDefinition?.namedTypeDefinitions.forEach((i,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 r=new Map;i.members?.forEach(e=>{(0,a.tE)(this.memberIdTypeLookup,e.id,()=>new Set).add(n)}),this.sublayerCaches.set(n,r)})}addToLayer(e){e.forEach(({typeName:e,id:t})=>{if(!this.inclusionModeDefinition)throw new s.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 i=this.inclusionModeDefinition.namedTypeDefinitions.get(e);i.members||(i.members=new Map),i.members.set(t,{id:t}),(0,a.tE)(this.memberIdTypeLookup,t,()=>new Set).add(e)}}else{const i=new Map;i.set(t,{id:t}),this.inclusionModeDefinition.namedTypeDefinitions.set(e,{useAllData:!1,members:i}),(0,a.tE)(this.memberIdTypeLookup,t,()=>new Set).add(e)}})}getById(e){return b.A.getInstance().readFromStoreById(e)}async getData(e,t,i){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 I.A({where:"1=1",outFields:["*"]}),"link-chart"===t.parentCompositeLayer.type){const e=t.parentCompositeLayer,i=this._processingCacheUpdatesLookup.get(t.objectType.name??""),r=n.outFields;r&&1===r.length&&r[0]===f.dr&&"1=1"===n.where||await Promise.all(i??[]);const s=this.sublayerCaches.has(t.objectType.name??"")?Array.from(this.sublayerCaches.get(t.objectType.name)?.values()):[],o=[];return s.forEach(i=>{if(this.relationshipTypeNames.has(t.objectType.name)){i.geometry=e.relationshipLinkChartDiagramLookup.get(i.attributes[t.objectIdField]);const n=this.memberIdTypeLookup.get(i.attributes[f.Cz]),r=this.memberIdTypeLookup.get(i.attributes[f.KQ]),s=this._isEndEntitySpatial(n,i,f.Cz),o=this._isEndEntitySpatial(r,i,f.KQ);i.attributes[f.BL]=Number(s&&o)}else{i.geometry=e.entityLinkChartDiagramLookup.get(i.attributes[t.objectIdField]);const n=this.geographicLookup.get(t.objectType.name);n&&i.attributes[n.name]?i.attributes[f.BL]=1:i.attributes[f.BL]=0}i.attributes[f.T1]=i.geometry,o.push(i)}),o}return this.retrieveDataFromService(n,t,i)}async getConnectedRecordIds(e,t,i){const n=[];let r="";const s=this._getNamedTypeIdMapFromNodeIds(e);if(t&&0!==t?.length){for(const e of t)r=r+e+"|";r=r.slice(0,-1)}const o={},a=[];for(const[e,i]of s){const n=`${e}_ids`;o[n]=i,t&&0!==t?.length?a.push(`MATCH (n:${e}) WHERE id(n) IN $${n} WITH n MATCH (n)-[r:${r}]-(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 "),p=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new M.A({openCypherQuery:l,bindParameters:o}),{signal:i?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await p.read();if(e)break;for(let e=0;e<t.length;e++){const i=t[e];n.push({id:i[0],typeName:i[1]}),n.push({id:i[2],typeName:i[3]})}}return n}async getRelationshipsBetweenNodes(e,t,i){const n=this._getNamedTypeIdMapFromNodeIds(e);if(0===n.size)return[];const r={relationshipExclusionIds:t,possibleConnectionEntityIds:e},s=[];for(const[e,t]of n.entries()){const i=`${e}_ids`;r[i]=t,s.push(`MATCH (n:${e}) WHERE id(n) IN $${i} WITH n MATCH (n)-[r]->(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const o=s.join(" UNION "),a=[],l=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new M.A({openCypherQuery:o,bindParameters:r}),{signal:i?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await l.read();if(e)break;for(let e=0;e<t.length;e++){const i=t[e];a.push({id:i[0],typeName:i[1]})}}return a}async getRelationshipsFromNodes(e,t,i,n){const r=this._getNamedTypeIdMapFromNodeIds(e);if(0===r.size||0===t.length)return[];const s={relationshipExclusionIds:i,possibleConnectionEntityIds:t},o=[];for(const[e,t]of r.entries()){const i=`${e}_ids`;s[i]=t,o.push(`MATCH (n:${e}) WHERE id(n) IN $${i} 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,p=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new M.A({openCypherQuery:a,bindParameters:s}),{signal:n?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await p.read();if(e)break;for(let e=0;e<t.length;e++){const i=t[e];let n=l.get(i[1]);n||(n=new Set,l.set(i[1],n)),n.add(i[0])}}const d=[];for(const[e,t]of l)for(const i of t)d.push({id:i,typeName:e});return d}async refreshCacheContent(e,t,i,n=!0,r){const o=b.A.getInstance(),p=[],d=new Map,u=new Map;this.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&u.set(e.name,e)}),this.knowledgeGraph.dataModel.relationshipTypes?.forEach(e=>{e.name&&u.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((p,c)=>{(async()=>{const p=new Set,c=[];let h,y="",m=!1;if(t||u.get(e)?.properties?.forEach(e=>{e.name&&p.add(e.name)}),i&&this.geographicLookup.has(e)){const t=this.geographicLookup.get(e)?.name;t&&p.add(t)}if(this.entityTypeNames.has(e))y=`MATCH (n:${e}) ${l?"WHERE id(n) IN $ids ":""}return ID(n)`,p.forEach(e=>{y+=`, n.${e}`,c.push(e)});else{if(!this.relationshipTypeNames.has(e))throw new s.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?`);m=!0,y=`MATCH ()-[n:${e}]->() ${l?"WHERE id(n) IN $ids ":""}return ID(n), id(startNode(n)), id(endNode(n))`,p.forEach(e=>{y+=`, n.${e}`,c.push(e)})}h=new M.A(l?{openCypherQuery:y,bindParameters:{ids:l}}:{openCypherQuery:y});const g=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,h,{signal:r?.signal})).resultRowsStream.getReader();for(;;){const{done:t,value:i}=await g.read();if(t)break;const r=[];for(let e=0;e<i.length;e++){const t=i[e];let n=0,s=0;const o={properties:{}};for(o.id=t[n],n++,s++,m&&(o.originId=t[n],n++,s++,o.destinationId=t[n],n++,s++,(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-s]]=t[n];d.delete(o.id),r.push(o)}const s=o.writeToStore(r,f.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);s.forEach(t=>{l?.set(t.attributes[f.dr],t),n&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.has(t.attributes[f.dr])&&(this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.set(t.attributes[f.dr],{id:t.attributes[f.dr]}),(0,a.tE)(this.memberIdTypeLookup,t.attributes[f.dr],()=>new Set).add(e))})}const b=this.inclusionModeDefinition?.namedTypeDefinitions.get(e);if(b)for(const e of d)b.members?.delete(e)})().then(()=>{p(null)}).catch(e=>{"AbortError"===e.name?p(null):c(e)})});p.push(c),this._processingCacheUpdatesLookup.get(e)?.push(c)}if(await Promise.all(p),r?.signal?.aborted)throw(0,l.NK)()}removeFromLayer(e){const t=new Set,i=new Set(e.map(e=>e.id));for(const i of e)t.add(i.typeName),1===this.memberIdTypeLookup.get(i.id)?.size?this.memberIdTypeLookup.delete(i.id):this.memberIdTypeLookup.get(i.id)?.delete(i.typeName),this.inclusionModeDefinition?.namedTypeDefinitions.forEach((e,t)=>{t===i.typeName&&e.members?.has(i.id)&&e.members.delete(i.id)});t.forEach(e=>{this.sublayerCaches.get(e)?.forEach((t,n)=>{i.has(n)&&this.sublayerCaches.get(e)?.delete(n)})})}async retrieveDataFromService(e,t,i){const n=b.A.getInstance(),r=new Set,o=[];let a,l="",d=[];const u="relationship"===t.graphType,I=this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData,T=t.parentCompositeLayer.sublayerIdsCache.get(t.objectType.name);let C=!I&&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&&(C=e.objectIds);else if(null!=e.objectIds&&C&&C.length>0){const t=e.objectIds;e.objectIds=C.filter(e=>t.includes(e))}else if(null!=e.objectIds)C=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=C}if(null!=e.outFields){const i=e.outFields;i.includes("*")?t.fields.forEach(e=>{r.add(e.name)}):i.forEach(e=>{e!==f.dr&&e!==t.geometryFieldName&&r.add(e)})}if(null!=e.geometry){const i=e.geometry;let n;const d=t.parentCompositeLayer.dataManager.knowledgeGraph.serviceDefinition,f=d?.spatialReference,g=d?.serviceCapabilities?.geometryCapabilities;let b=g?.geometryMaxBoundingRectangleSizeX,_=g?.geometryMaxBoundingRectangleSizeY;if("point"===i.type){let e=i;e.spatialReference?.isWGS84||(await(0,y.initializeProjection)(e.spatialReference,m.KK),e=(0,y.project)(e,m.KK)),n=new c.A({spatialReference:m.KK,xmin:e.x-1e-4,ymin:e.y-1e-4,xmax:e.x+1e-4,ymax:e.y+1e-4})}else i?.extent?.spatialReference&&!i.spatialReference?.isWGS84?(await(0,y.initializeProjection)(i.extent.spatialReference,m.KK),n=(0,y.project)(i.extent,m.KK)):n=i.extent;if(b&&_&&f){if(4326!==f.wkid){const e=new c.A({spatialReference:f,xmax:b,ymax:_}),t=(0,y.project)(e,m.KK);b=t.xmax,_=t.ymax}if(n.xmax-n.xmin>b)throw new s.A("knowledge-graph:layer-data-manager",`Extent x bounds should be within ${b}° latitude, limit exceeded`);if(n.ymax-n.ymin>_)throw new s.A("knowledge-graph:layer-data-manager",`Extent y bounds should be within ${_}° longitude, limit exceeded`)}if(null!=e.where&&"1=1"!==e.where){const i=await(0,p.GP)(e.where.toUpperCase(),t.fieldsIndex);t.fields.forEach(e=>{i.fieldNames.includes(e.name)&&r.add(e.name)})}l=u?`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&&r.add(t.geometryFieldName),r.forEach(e=>{l+=`, n.${e}`,o.push(e)}),a=new M.A({openCypherQuery:l,bindParameters:{param_filter_geom:new h.A({rings:(0,w.Wq)(n)})}})}else{let i="";if(null!=e.where&&"1=1"!==e.where){const n=await(0,p.GP)(e.where,t.fieldsIndex);t.fields.forEach(e=>{n.fieldNames.includes(e.name)&&r.add(e.name)});const s={systemOidFieldName:f.dr,supportedSqlTypes:new Set(["column-reference","string","number","binary-expression"]),supportedSqlOperators:new Set(["=","<","<=","<>",">",">=","AND","OR","LIKE"]),unsupportedOperationFound:!1};i=g(n.parseTree,s),s.unsupportedOperationFound&&(i="")}let n="";n=u?`Match ()-[n:${t.objectType.name}]->()`:`Match (n:${t.objectType.name})`;let s=!1;C&&(s=!0,n+=" WHERE ID(n) IN $ids"),i&&(n+=s?" AND":" WHERE",n+=` ${i}`),n+=" return ID(n)",u&&(n+=", id(startNode(n)), id(endNode(n))"),e.returnGeometry&&t.geometryFieldName&&r.add(t.geometryFieldName),r.forEach(e=>{n+=`, n.${e}`,o.push(e)}),a=new M.A(C?{openCypherQuery:n,bindParameters:{ids:C}}:{openCypherQuery:n})}const v=(await(0,_.executeQueryStreaming)(t.parentCompositeLayer.dataManager.knowledgeGraph,a,i)).resultRowsStream.getReader();for(;;){const{done:e,value:i}=await v.read();if(e)break;const r=[];for(let e=0;e<i.length;e++){const t=i[e];let n=0,s=0;const a={properties:{}};for(a.id=t[n],n++,s++,u&&(a.originId=t[n],n++,s++,a.destinationId=t[n],n++,s++);n<t.length;n++)a.properties[o[n-s]]=t[n];r.push(a)}d=d.concat(n.writeToStore(r,f.dr,t.parentCompositeLayer.dataManager.geographicLookup.get(t.objectType.name)?.name))}return d}_isEndEntitySpatial(e,t,i){for(const n of e??[])if(this.entityTypeNames.has(n)){const e=this.geographicLookup.get(n),r=e&&this.sublayerCaches.get(n)?.get(t.attributes[i]);if(e&&r?.attributes[e.name])return!0}return!1}_getNamedTypeIdMapFromNodeIds(e){const t=new Map;return e.forEach(e=>{if(this.memberIdTypeLookup.has(e))for(const i of this.memberIdTypeLookup.get(e)){if(!this.entityTypeNames.has(i))return;t.has(i)?t.get(i)?.push(e):t.set(i,[e])}}),t}};(0,n.Cg)([(0,d.MZ)()],T.prototype,"knowledgeGraph",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"inclusionModeDefinition",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"entityTypeNames",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"relationshipTypeNames",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"geographicLookup",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"sublayerCaches",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"nodeConnectionsLookup",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"relationshipConnectionsLookup",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"memberIdTypeLookup",void 0),T=(0,n.Cg)([(0,u.$)("esri.layers.knowledgeGraph.KnowledgeGraphLayerDataManager")],T)},25927:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(64108)),o=i(86738),a=i(54238);let l=class extends a.A{constructor(e){super(e),this.layoutGeometry=null}};(0,n.Cg)([(0,r.MZ)({type:o.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.Entity")],l)},30504:(e,t,i)=>{i.d(t,{k5:()=>p,aq:()=>l,Wq:()=>d}),i(52106);var n=i(49186),r=(i(86738),i(39829),i(82799),i(94194),i(69860),i(8460),i(66552));(0,r.O)()({none:"none",startAndEnd:"start-and-end",startOnly:"start-only"}),(0,r.O)()({absoluteValue:"absolute-value",multiplier:"multiplier"});const s=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=i(62568),a=i(42538);async function l(e,t,i){const n=[],r=function(e,t){const i=new Map;if(t.dataModel?.relationshipTypes)for(const e of t.dataModel.relationshipTypes)e.name&&i.set(e.name,[]);for(const t of e)i.has(t.typeName)&&i.get(t.typeName)?.push(t.id);return i}(e,t),s={},l=[];for(const[e,t]of r){if(t.length<1)continue;const i=`${e}_ids`;s[i]=t,l.push(`MATCH (n)-[r:${e}]->(m) WHERE id(r) in $${i} RETURN id(n), labels(n)[0], id(m), labels(m)[0]`)}if(0===l.length)return[];const p=l.join(" UNION "),d=new a.A({openCypherQuery:p,bindParameters:s}),u=(await(0,o.executeQueryStreaming)(t,d,i?.requestOptions)).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await u.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}i(40863),i(94985),i(68249);const p=e=>s.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]])}},37531:(e,t,i)=>{i.d(t,{dt:()=>c,GG:()=>g,UQ:()=>f,Sx:()=>d});var n=i(68197),r=i(60999),s=(i(44208),i(51850)),o=(i(76369),i(62046)),a=(i(2741),i(78888),i(66344));new Map([["dash",[4,3]],["dashdot",[4,3,1,3]],["dot",[1,3]],["longdash",[8,3]],["longdashdot",[8,3,1,3]],["longdashdotdot",[8,3,1,3,1,3]],["shortdash",[4,1]],["shortdashdot",[4,1,1,1]],["shortdashdotdot",[4,1,1,1,1,1]],["shortdot",[1,1]],["solid",[]]]),new a.q(1e3),new n.A([128,128,128]);var l=i(28975),p=i(33910);function d(e,t){if(!e)return null;let i=null;return(0,p.wk)(e)?i=function(e){const t=e.symbolLayers;if(!t)return null;let i=null;return t.forEach(e=>{"object"===e.type&&e.resource?.href||(i="water"===e.type?e.color:e.material?e.material.color:null)}),i?new n.A(i):null}(e):(0,p.$y)(e)&&(i="cim"===e.type?(0,o.Nk)(e):e.color?new n.A(e.color):null),i?u(i,t):null}function u(e,t){if(null==t||null==e)return e;const i=e.toRgba();return i[3]=i[3]*t,new n.A(i)}function c(e,t,i){e&&(t||null!=i)&&(t&&(t=new n.A(t)),(0,p.wk)(e)?function(e,t,i){const r=e.symbolLayers;if(!r)return;const s=(e,r=!1)=>{let s=t??e??null;return null!=i?.override&&(!s&&r&&(s=new n.A([255,255,255])),s&&(s.a=i.override)),u(s,i?.add)};r.forEach(e=>{if("water"===e.type)return void(e.color=u(e.color,i?.add));const t=null!=e.material?e.material.color:null,n=s(t,"icon"===e.type&&null!=e.resource?.href);null==e.material?e.material=new l.N({color:n}):e.material.color=n,"outline"in e&&e.outline?.color&&null!=i?.add&&(e.outline.color=u(e.outline.color,i.add)),"marker"in e&&null!=e.marker&&(e.marker.color=s(e.marker.color))})}(e,t,i):(0,p.$y)(e)&&function(e,t,i){t=t??e.color,null!=i?.override&&t&&(t.a=i.override),t&&(e.color=u(t,i?.add)),"outline"in e&&e.outline?.color&&(e.outline.color=u(e.outline.color,i?.add))}(e,t,i))}function h(e){for(const t of e)if("number"==typeof t)return t;return null}function y(e,t,i){for(let n=0;n<3;n++){const r=e[n];switch(r){case"symbol-value":{const e=i[n];return null!=e?e/t[n]:1}case"proportional":break;default:if(r&&t[n])return r/t[n]}}return null}function m(e,t,i,n){switch(e){case"proportional":return i*n;case"symbol-value":return null!=t?t:i;default:return e}}async function f(e,t){if(e&&t)return(0,p.wk)(e)?async function(e,t){const n=e.symbolLayers;n&&await(0,r.jJ)(n,async e=>async function(e,t){switch(e.type){case"extrude":!function(e,t){const i=t[2];"number"==typeof i&&(e.size=i)}(e,t);break;case"icon":case"line":case"text":!function(e,t){const i=h(t);null!=i&&(e.size=i)}(e,t);break;case"path":!function(e,t){const i=y(t,s.Un,[e.width,void 0,e.height]);null!=i&&(e.width=m(t[0],e.width,1,i),e.height=m(t[2],e.height,1,i))}(e,t);break;case"object":await async function(e,t){const{resourceSize:n,symbolSize:r}=await async function(e){const{computeObjectLayerResourceSize:t}=await i.e(5404).then(i.bind(i,95404)),n=await t(e,10),{width:r,height:s,depth:o}=e,a=[r,o,s];let l=1;for(let e=0;e<3;e++){const t=a[e];if(null!=t){l=t/n[e];break}}for(let e=0;e<3;e++)null==a[e]&&(a[e]=n[e]*l);return{resourceSize:n,symbolSize:a}}(e),s=y(t,n,r);null!=s&&(e.width=m(t[0],r[0],n[0],s),e.depth=m(t[1],r[1],n[1],s),e.height=m(t[2],r[2],n[2],s))}(e,t)}}(e,t))}(e,t):void((0,p.$y)(e)&&function(e,t){const i=h(t);if(null!=i)switch(e.type){case"simple-marker":e.size=i;break;case"picture-marker":{const t=e.width/e.height;t>1?(e.width=i,e.height=i*t):(e.width=i*t,e.height=i);break}case"simple-line":e.width=i;break;case"text":e.font.size=i}}(e,t))}function g(e,t,i){if(e&&null!=t)if((0,p.wk)(e)){const n=e.symbolLayers;n&&n.forEach(e=>{if("object"===e.type)switch(i){case"tilt":e.tilt=(e.tilt??0)+t;break;case"roll":e.roll=(e.roll??0)+t;break;default:e.heading=(e.heading??0)+t}"icon"===e.type&&(e.angle+=t)})}else(0,p.$y)(e)&&("simple-marker"!==e.type&&"picture-marker"!==e.type&&"text"!==e.type||(e.angle+=t))}},37730:(e,t,i)=>{i.d(t,{T:()=>r});var n=i(43334);const r={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)}},40662:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(31635),r=(i(53966),i(44208),i(87811),i(49186),i(64108)),s=i(77901);let o=class extends s.A{constructor(e){super(e)}};o=(0,n.Cg)([(0,r.$)("esri.rest.knowledgeGraph.ObjectValue")],o)},40736:(e,t,i)=>{i.d(t,{Gz:()=>F,O9:()=>L,hZ:()=>k,UT:()=>x,MY:()=>A,Td:()=>v,iW:()=>E,e$:()=>S,qN:()=>I});var n=i(68197),r=i(91869),s=i(99352),o=i(15375),a=i(46499),l=i(73913),p=i(62568),d=i(25927),u=i(31635),c=i(69622),h=i(10107),y=(i(44208),i(53966),i(87811),i(64108));let m=class extends c.A{constructor(e){super(e),this.entityAdds=void 0,this.entityUpdates=void 0,this.entityDeletes=void 0,this.relationshipAdds=void 0,this.relationshipUpdates=void 0,this.relationshipDeletes=void 0,this.options=void 0}};(0,u.Cg)([(0,h.MZ)()],m.prototype,"entityAdds",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"entityUpdates",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"entityDeletes",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"relationshipAdds",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"relationshipUpdates",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"relationshipDeletes",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"options",void 0),m=(0,u.Cg)([(0,y.$)("esri.rest.knowledgeGraph.GraphApplyEdits")],m);var f=i(23150),g=i(54218),b=i(40863),w=i(68249);const _={initializeLayersFromClientData:async(e,t,i)=>{if(t||(t=[...e.layers,...e.tables].map(e=>e.graphTypeName)),0===t?.length)return;const n=new Map;for(const i of t)n.set(i,M(e,i));const r=await(0,p.fetchClientDataAtKeys)(e.dataManager.knowledgeGraph,Array.from(n.values()),{requestOptions:{signal:i?.signal}});for(const t of[...e.layers,...e.tables]){const i=t.objectType.name;if(null==i)continue;const n=r.get(M(e,i));if(n){const e=JSON.parse(n);null===e||"object"!=typeof e||e.hasOwnProperty("showLabels")||(e.showLabels=!1),t.read(e,{origin:"service"})}}}},M=(e,t)=>"knowledge-graph"===e.type?`${t}/Map`:`${t}/LinkChart/LinkChartSubLayer`;async function I(e,t,i){return _.initializeLayersFromClientData(e,t,i)}const T=["#4a0932","#b31515","#18382e","#a64f1b","#102432","#8c213f","#ed9310","#2c6954","#144d59","#ffc730","#75351e","#454f4b","#78b1c2","#191921","#8f8f82","#9be0c0","#dbb658","#87b051","#11495c","#c43541","#9c5596","#44498b","#ad9d63","#86afb3","#5c98ca","#b0bfa2","#73241f","#b86b53","#d9d78c","#3e756d","#f260a1","#a0d17d","#c27c30","#eb82eb","#ffdf3c","#ffb259","#ab52b3","#3cccb4","#0095ba","#d92b30"],C="#8f8f82";function v(e){return e<0||e>=T.length?new n.A(C):new n.A(T[e])}function x(e){const t=e.toArray();return new b.A({data:{type:"CIMSymbolReference",symbol:{type:"CIMLineSymbol",symbolLayers:[{type:"CIMSolidStroke",enable:!0,style:"solid",width:.75,color:t},{type:"CIMVectorMarker",enable:!0,size:6,markerPlacement:{type:"CIMMarkerPlacementOnLine",angleToLine:!0,relativeTo:"LineMiddle"},frame:{xmin:-10,ymin:-5,xmax:0,ymax:5},markerGraphics:[{type:"CIMMarkerGraphic",geometry:{rings:[[[-12,-3.47],[-12,3.6],[1.96,-.03],[-12,-3.47]]]},symbol:{type:"CIMPolygonSymbol",symbolLayers:[{type:"CIMSolidFill",enable:!0,color:t}]}}]}]}}})}function A(e){let t="ESRI__ID",i=4;for(const n of e)if(n.name){if("name"===n.name.toLowerCase()){t=n.name;break}n.name.toLowerCase().includes("name")?(t=n.name,i=2):"esriFieldTypeString"===n.fieldType&&i>3&&(t=n.name,i=3)}return t}function E(e,t,i){const n={color:[80,80,80],haloColor:[255,255,255],haloSize:.7,font:{size:10,weight:"normal"}},r=new a.A({labelExpressionInfo:new l.A({expression:"ESRI__ID"===i?`${t}`:`$feature.${i}`}),labelPlacement:"above-center",symbol:new w.A(n)}),s=new a.A({labelExpressionInfo:new l.A({expression:`'${t}' + IIf($feature.ESRI__AggregationCount>1, ' (' + $feature.ESRI__AggregationCount + ')', '')`}),labelPlacement:"center-along",labelPosition:"parallel",repeatLabel:!1,symbol:new w.A({...n,yoffset:"12px"})});return"entity"===e?[r]:[s]}function S(e,t,i){const n={color:[255,255,255],haloColor:[0,0,0],haloSize:.7,font:{size:10,weight:"bold"}},r="ESRI__ID"===i?`${e}`:`$feature.${i}`;return"point"===t?[new a.A({labelExpressionInfo:new l.A({expression:r}),labelPlacement:"above-center",symbol:new w.A(n)})]:"polyline"===t?[new a.A({labelExpressionInfo:new l.A({expression:r}),labelPlacement:"center-along",repeatLabel:!0,symbol:new w.A(n)})]:"polygon"===t?[new a.A({labelExpressionInfo:new l.A({expression:r}),labelPlacement:"always-horizontal",symbol:new w.A(n)})]:null}const N={capabilities:[],allowGeometryUpdates:!1,serviceCapabilities:{geometryCapabilities:{supportsZValues:!1,supportsMValues:!1}}};function k(e){const{capabilities:t,allowGeometryUpdates:i,serviceCapabilities:{geometryCapabilities:{supportsZValues:n,supportsMValues:r}}}=e?.serviceDefinition||N,o=e?.dataModel.arcgisManaged?t:t.filter(e=>"Query"===e),a=new Set(o);return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:r,supportsZ:n},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:a.has("Create"),supportsDelete:a.has("Delete"),supportsEditing:a.has("Editing"),supportsChangeTracking:!1,supportsQuery:a.has("Query"),supportsQueryBins:!1,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:a.has("Update"),supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,editing:{supportsGeometryUpdate:!!e?.dataModel.arcgisManaged&&i,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:a.has("Delete"),supportsUpdateByAnonymous:!1,supportsUpdateByOthers:a.has("Update"),supportsAsyncApplyEdits:!1,zDefault:void 0}}}function L(e,t){const i=new m,n=t.graphTypeName,s=t.graphType,a=e=>{const i={...e};for(const e of t.fields)e.editable||delete i[e.name];for(const t of Object.keys(e))t.includes("ESRI__")&&delete i[t];return i};for(const t of e.addFeatures??[]){const e=a(t.attributes);t.sourceLayer.graphTypeName===n&&("entity"===s?(i.entityAdds||(i.entityAdds=[]),i.entityAdds.push(new d.A({properties:e,typeName:n}))):(i.relationshipAdds||(i.relationshipAdds=[]),i.relationshipAdds.push(new f.A({properties:e,typeName:n}))))}for(const t of e.updateFeatures??[]){const e=t.attributes[o.dr],r=a(t.attributes);t.sourceLayer.graphTypeName===n&&("entity"===s?(i.entityUpdates||(i.entityUpdates=[]),i.entityUpdates.push(new d.A({id:e,properties:r,typeName:n}))):(i.relationshipUpdates||(i.relationshipUpdates=[]),i.relationshipUpdates.push(new f.A({id:e,properties:r,typeName:n}))))}const l=new Map;for(const t of e.deleteFeatures??[])if((0,g.DU)(t)){const e=t,i=(0,r.tE)(l,e.sourceLayer.graphTypeName,()=>({typeName:e.sourceLayer.graphTypeName,ids:[]}));e.sourceLayer.graphTypeName===n&&i.ids.push(e.attributes[o.dr])}else t.objectId&&"string"==typeof t.objectId&&(0,r.tE)(l,n,()=>({typeName:n,ids:[]})).ids.push(t.objectId);for(const e of l.values())e.ids.length>0&&("entity"===s?(i.entityDeletes||(i.entityDeletes=[]),i.entityDeletes.push({typeName:e.typeName,ids:e.ids})):(i.relationshipDeletes||(i.relationshipDeletes=[]),i.relationshipDeletes.push({typeName:e.typeName,ids:e.ids})));return i}function F(e,t){const i={addFeatureResults:[],updateFeatureResults:[],deleteFeatureResults:[],addAttachmentResults:[],updateAttachmentResults:[],deleteAttachmentResults:[]};for(const n of e.editResults)if(n.typeName===t){for(const e of n.adds)i.addFeatureResults.push({objectId:e.id,globalId:e.id});for(const e of n.updates)i.updateFeatureResults.push({objectId:e.id,globalId:e.id});for(const e of n.deletes)i.deleteFeatureResults.push({objectId:e.id,globalId:e.id})}return i}},42095:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(31635),r=i(25482),s=i(10107),o=(i(44208),i(53966),i(87811),i(64108)),a=i(77901);let l=class extends r.o{constructor(e){super(e),this.path=[]}};(0,n.Cg)([(0,s.MZ)({type:[a.A],json:{write:!0}})],l.prototype,"path",void 0),l=(0,n.Cg)([(0,o.$)("esri.rest.knowledgeGraph.Path")],l)},42538:(e,t,i)=>{i.d(t,{A:()=>p});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(64108)),o=i(16930),a=i(69622);let l=class extends a.A{constructor(e){super(e),this.openCypherQuery=""}};(0,n.Cg)([(0,r.MZ)()],l.prototype,"openCypherQuery",void 0),l=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.GraphQuery")],l);let p=class extends l{constructor(e){super(e),this.bindParameters=null,this.bindGeometryQuantizationParameters=null,this.outputQuantizationParameters=null,this.outputSpatialReference=null,this.provenanceBehavior=null}};(0,n.Cg)([(0,r.MZ)()],p.prototype,"bindParameters",void 0),(0,n.Cg)([(0,r.MZ)()],p.prototype,"bindGeometryQuantizationParameters",void 0),(0,n.Cg)([(0,r.MZ)()],p.prototype,"outputQuantizationParameters",void 0),(0,n.Cg)([(0,r.MZ)({type:o.A})],p.prototype,"outputSpatialReference",void 0),(0,n.Cg)([(0,r.MZ)()],p.prototype,"provenanceBehavior",void 0),p=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.GraphQueryStreaming")],p)},54238:(e,t,i)=>{i.d(t,{A:()=>a});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(64108)),o=i(77901);let a=class extends o.A{constructor(e){super(e),this.typeName=null,this.id=null}};(0,n.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],a.prototype,"typeName",void 0),(0,n.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],a.prototype,"id",void 0),a=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.GraphNamedObject")],a)},62046:(e,t,i)=>{i.d(t,{Fe:()=>d,Nk:()=>s});var n=i(68197),r=i(93397);function s(e){const t=[];return o((0,r.lW)(e),t),t.length?new n.A((0,r.e6)(t[0])):null}function o(e,t){if(!e)return;let i;i="CIMTextSymbol"===e.type?e.symbol:e;const n="CIMPolygonSymbol"===e.type;if(i?.symbolLayers)for(const e of i.symbolLayers)if(!(e.colorLocked||n&&((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))))switch(e.type){case"CIMPictureMarker":case"CIMPictureStroke":case"CIMPictureFill":e.tintColor&&a(t,e.tintColor);break;case"CIMVectorMarker":e.markerGraphics?.forEach(e=>{o(e.symbol,t)});break;case"CIMSolidStroke":case"CIMSolidFill":a(t,e.color);break;case"CIMGradientFill":l(t,e);break;case"CIMHatchFill":o(e.lineSymbol,t)}}function a(e,t){for(const i of e)if(i.join(".")===t.join("."))return;e.push(t)}function l(e,t){const i=t.colorRamp?.type;switch(i){case"CIMMultipartColorRamp":t.colorRamp.colorRamps?.forEach(t=>{"CIMLinearContinuousColorRamp"===t.type&&p(e,t)});break;case"CIMLinearContinuousColorRamp":case"CIMPolarContinuousColorRamp":p(e,t.colorRamp)}}function p(e,t){t&&(t.fromColor&&a(e,t.fromColor),t.toColor&&a(e,t.toColor))}function d(e,t,i){t instanceof n.A||(t=new n.A(t));const s=(0,r.lW)(e);s&&u(s,t,i)}function u(e,t,i){if(!e)return;let n;n="CIMTextSymbol"===e.type?e.symbol:e;const s="CIMPolygonSymbol"===n?.type;if(n?.symbolLayers)for(const e of n.symbolLayers){if(e.colorLocked)continue;if(s)if(i){const{layersToColor:t}=i;if(((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))&&"fill"===t||(0,r.jn)(e)&&"outline"===t)continue}else if((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))continue;const n=t.toArray();switch(e.type){case"CIMPictureMarker":case"CIMPictureStroke":case"CIMPictureFill":e.tintColor=n;break;case"CIMVectorMarker":e.markerGraphics?.forEach(e=>{u(e.symbol,t,i)});break;case"CIMSolidStroke":case"CIMSolidFill":e.color=n;break;case"CIMGradientFill":c(e,t);break;case"CIMHatchFill":u(e.lineSymbol,t,i)}}}function c(e,t){const i=e.colorRamp?.type;switch(i){case"CIMMultipartColorRamp":e.colorRamp.colorRamps?.forEach(e=>{"CIMLinearContinuousColorRamp"===e.type&&h(e,t)});break;case"CIMLinearContinuousColorRamp":case"CIMPolarContinuousColorRamp":h(e.colorRamp,t)}}function h(e,t){if(e&&(e.fromColor&&(e.fromColor=t.toArray()),e.toColor)){const i=t.clone();i.a=0,e.toColor=i.toArray()}}},62796:(e,t,i)=>{i.d(t,{A:()=>he});var n=i(31635),r=i(37838),s=i(49186),o=i(4718),a=i(53966),l=i(92071),p=(i(29953),i(10107)),d=(i(44208),i(64108)),u=i(43937),c=i(5443),h=i(86738),y=i(39829),m=i(82799),f=i(91218),g=i(16930),b=i(21325),w=i(50498),_=i(55156),M=i(60950),I=i(89808),T=i(99959);const C=Symbol("isKnowledgeGraphGraphicOriginSymbol");var v;class x extends T.A{get[(v=C,M.ym)](){return this.sublayer}get[_.e](){return this.sublayer}get[I.Q](){return this.sublayer}constructor(e,t){super(),this[v]=!0,this.type="knowledge-graph",this.layer=e,this.sublayer=t}get id(){return this.layer.id}}const A=Symbol("isLinkChartGraphicOriginSymbol");var E;class S extends T.A{get[(E=A,I.Q)](){return this.layer}constructor(e,t){super(),this[E]=!0,this.type="link-chart",this.layer=e,this.sublayer=t}get id(){return`${this.layer.id}:__${this.sublayer.id}__`}}var N=i(4146),k=i(83221),L=i(56390),F=i(64714),D=i(15375);i(87811);const R=(0,i(17036).p)(),j=e=>{const t=e;let i=class extends t{constructor(){super(...arguments),this.fields=[],this.fieldsIndex=null}};return(0,n.Cg)([(0,p.MZ)(R.fields)],i.prototype,"fields",void 0),(0,n.Cg)([(0,p.MZ)(R.fieldsIndex)],i.prototype,"fieldsIndex",void 0),i=(0,n.Cg)([(0,d.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayerBase")],i),i};var O=i(40736),B=i(63074),Z=i(6455),$=i(87718),P=i(56658),G=i(32756),U=i(54310),q=i(25036),z=i(82935),Q=i(10873),Y=i(13213),H=i(20437),W=i(30524),V=i(46499),X=i(39383),J=i(96184),K=i(96576),ee=i(65494),te=i(41214),ie=i(62568),ne=i(22671),re=i(61956),se=i(30291),oe=i(37531),ae=i(61322);function le(e){if(!e.json)return e;e.json.write=pe(e.json.write);const t=e.json.origins;if(!t)return e;let i;for(i in t){const e=t[i];e&&(e.write=pe(e.write))}return e}function pe(e){return"object"==typeof e&&e?(!1!==e.enabled&&(e.overridePolicy=function(e){const{target:t,writer:i,overridePolicy:n,...r}=e;return function(e,t){const i=ue.call(this,e,t);return i.enabled?{...r,...i}:i}}(e)),e):!0===e?de():e}function de(){return{overridePolicy:ue}}function ue(e,t){const i=!!this.geometryType;let n={enabled:i};return i&&(n={...n,...ce.call(this,e,t)}),n}function ce(e,t){return{ignoreOrigin:this.originIdOf(t)>0}}let he=class extends(j((0,Z.FJ)((0,P.J)((0,$.F)((0,B.dM)((0,G.fY)((0,z.e)((0,q.j)((0,U.J)((0,l.P)(N.A))))))))))){constructor(e){super(e),this.blendMode="normal",this.charts=null,this.definitionExpression=null,this.displayFilterEnabled=!0,this.displayFilterInfo=null,this.effect=null,this.elevationInfo=null,this.featureEffect=null,this.graphType=null,this.labelsVisible=!0,this.layerType=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.objectIdField=D.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 ae.default(e.port1,{channel:e,client:{queryFeatures:(e,t={})=>{const i=re.A.fromJSON(e);return this.queryFeaturesJSON(i,t)}}}),[e.port2]})},this.type="knowledge-graph-sublayer",this.useViewTime=!0,this.visible=!0}get capabilities(){return this.parent?this.parent.sublayerCapabilities:(0,O.hZ)(null)}get userHasUpdateItemPrivileges(){return!!this.parent?.userHasUpdateItemPrivileges}get editingEnabled(){return this._isOverridden("editingEnabled")?this._get("editingEnabled"):this.capabilities.operations.supportsEditing}set editingEnabled(e){this._overrideIfSome("editingEnabled",e)}get isTable(){return"link-chart"!==this.parentCompositeLayer.type&&null==this.geometryFieldName}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 i="esriFieldTypeOID"===t.fieldType?"esriFieldTypeInteger":t.fieldType;e.push(H.A.fromJSON({name:t.name,type:i,alias:t.alias,defaultValue:t.defaultValue,editable:t.editable,nullable:t.nullable}))}),e.push(H.A.fromJSON({name:this.objectIdField,type:"esriFieldTypeString",alias:this.objectIdField,editable:!1}),H.A.fromJSON({name:D.M1,type:"esriFieldTypeInteger",alias:D.M1,editable:!1}),H.A.fromJSON({name:D.BL,type:"esriFieldTypeInteger",alias:D.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?w.gy.fromJSON(t):null}get geometryFieldName(){if("link-chart"===this.parentCompositeLayer?.type)return D.T1;const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name);return e?.name??null}get graphicOrigin(){if(!this.parent)return null;switch(this.parent.type){case"knowledge-graph":return new x(this.parent,this);case"link-chart":return new S(this.parent,this)}}get graphTypeName(){return this.objectType?.name}set graphTypeName(e){this._set("graphTypeName",e)}get hasM(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,i=t?this.objectType?.properties?.[t]:null;return i?.hasM??!1}get hasZ(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,i=t?this.objectType?.properties?.[t]:null;return i?.hasZ??!1}set labelingInfo(e){this._set("labelingInfo",e)}get labelingInfo(){if(this._isOverridden("labelingInfo"))return this._get("labelingInfo");if(!this.objectType||!this.parentCompositeLayer||!this.graphTypeName)return null;const e=this.objectType.properties?(0,O.MY)(this.objectType.properties):"ESRI__ID";return"link-chart"===this.parentCompositeLayer.type?(0,O.iW)(this.graphType,this.graphTypeName,e):(0,O.e$)(this.graphTypeName,this.geometryType,e)}set renderer(e){(0,W.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){if(this._isOverridden("renderer"))return this._get("renderer");const e=this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel,t=[...e?.entityTypes??[],...e?.relationshipTypes??[]].map(e=>e.name).indexOf(this.graphTypeName),i=(0,O.Td)(t);if("link-chart"===this.parentCompositeLayer?.type){if("relationship"===this.graphType)return new K.A({type:"simple",symbol:(0,O.UT)(i)});const e=(0,ee.r)((0,F.F0)(w.gy.toJSON("point")).renderer);return(0,oe.dt)(e.symbol,i),e}const n=(0,ee.r)((0,F.F0)(w.gy.toJSON(this.geometryType)).renderer);return(0,oe.dt)(n.symbol,i),n}get spatialReference(){return this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel?.spatialReference??g.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,se.tn)(this,e)}createQuery(){return new re.A({where:"1=1",outFields:["*"]})}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){return null}async queryFeatures(e,t){await this.load();const{resolvedQuery:i,queryEngine:n}=await this._setupQueryObjects(e),r=this.graphicOrigin,s=ne.A.fromJSON(await n.executeQuery(i.toJSON(),t?.signal));return s.features.forEach(e=>{e.sourceLayer=this,e.origin=r}),s}async queryFeaturesJSON(e,t){await this.load();const{resolvedQuery:i,queryEngine:n}=await this._setupQueryObjects(e);return await n.executeQuery(i.toJSON(),t?.signal)}async queryFeatureCount(e,t){await this.load();const{resolvedQuery:i,queryEngine:n}=await this._setupQueryObjects(e);return n.executeQueryForCount(i.toJSON(),t?.signal)}async queryExtent(e={},t){await this.load();const i={...e,returnGeometry:!0},{resolvedQuery:n,queryEngine:r}=await this._setupQueryObjects(i),s=await r.executeQueryForExtent(n.toJSON(),t?.signal);let o;return o=null!=s.extent?.xmin&&null!=s.extent?.xmax&&null!=s.extent?.ymin&&null!=s.extent?.ymax?new c.A(s.extent):new c.A,{count:s.count,extent:o}}async queryObjectIds(e,t){await this.load();const i=re.A.from(e);let n;if("link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)n=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(i,this,t);n=this.loadQueryEngine(e)}return await n.executeQueryForIds(i.toJSON(),t?.signal)}async applyEdits(e){if(!this.parentCompositeLayer.dataManager.knowledgeGraph)throw new s.A("knowledge-graph-sublayer:no-knowledge-graph","ApplyEdits cannot be executed because the parent does not have a Knowledge Graph model. This is usually caused by the layer not yet being loaded");const t=(0,O.O9)(e,this);t.options={cascadeDelete:!0,cascadeProvenanceDelete:!!this.parent?.knowledgeGraph.serviceDefinition.supportsProvenance||void 0};const i=await(0,ie.executeApplyEdits)(this.parentCompositeLayer.dataManager.knowledgeGraph,t),n=(0,O.Gz)(i,this.graphTypeName),r={addedFeatures:n.addFeatureResults,updatedFeatures:n.updateFeatureResults,deletedFeatures:n.deleteFeatureResults,addedAttachments:n.addAttachmentResults,deletedAttachments:n.deleteAttachmentResults,updatedAttachments:n.updateAttachmentResults,exceededTransferLimit:!1,historicMoment:new Date,edits:void 0};return this.emit("edits",r),this.emit("apply-edits",{result:Promise.resolve(r)}),n}loadQueryEngine(e){const t=new k.A({geometryType:w.gy.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ}),i=new L.do({fieldsIndex:this.fieldsIndex.toJSON(),geometryType:w.gy.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ,featureIdInfo:{type:"object-id",fieldName:this.objectIdField},spatialReference:this.spatialReference.toJSON(),timeInfo:this.timeInfo?.toJSON(),featureStore:t});return i.featureStore.addMany(e),i}async refreshCachedQueryEngine(){const e=await this.parentCompositeLayer.dataManager.getData(new re.A({where:"1=1",outFields:[D.dr]}),this);this._cachedQueryEngine=this.loadQueryEngine(e)}load(e){return this.addResolvingPromise(this.parent.load(e).then(()=>(0,W.sv)(this.timeInfo,this.fieldsIndex))),Promise.resolve(this)}async _setupQueryObjects(e,t){const i=re.A.from(e),n=i.geometry;if(n&&!n.spatialReference?.isWGS84&&(await(0,f.initializeProjection)(n.spatialReference,b.KK),i.geometry=(0,f.project)(n instanceof y.A||n instanceof m.A||n instanceof h.A?n:n.extent,b.KK)),"link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)return{resolvedQuery:i,queryEngine:this._cachedQueryEngine};const r=await this.parentCompositeLayer.dataManager.getData(i,this,t);return{resolvedQuery:i,queryEngine:this.loadQueryEngine(r)}}};(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(B.sU)))],he.prototype,"blendMode",void 0),(0,n.Cg)([(0,p.MZ)({readOnly:!0})],he.prototype,"capabilities",null),(0,n.Cg)([(0,p.MZ)({readOnly:!0})],he.prototype,"userHasUpdateItemPrivileges",null),(0,n.Cg)([(0,p.MZ)({type:Boolean})],he.prototype,"editingEnabled",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"isTable",null),(0,n.Cg)([(0,p.MZ)({json:{origins:{"web-scene":{write:!1}},write:de()}})],he.prototype,"charts",void 0),(0,n.Cg)([(0,p.MZ)({readOnly:!0})],he.prototype,"defaultPopupTemplate",null),(0,n.Cg)([(0,p.MZ)({type:String,json:{origins:{service:{read:!1}},name:"layerDefinition.definitionExpression",write:{ignoreOrigin:!0}}})],he.prototype,"definitionExpression",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Z.Dp)))],he.prototype,"displayFilterEnabled",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Z.KV)))],he.prototype,"displayFilterInfo",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(B.LF)))],he.prototype,"effect",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"elevationInfo",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)($.Y)))],he.prototype,"featureEffect",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Y.d)))],he.prototype,"featureReduction",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"fields",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"geometryType",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"geometryFieldName",null),(0,n.Cg)([(0,p.MZ)({readOnly:!0})],he.prototype,"graphicOrigin",null),(0,n.Cg)([(0,p.MZ)({type:["entity","relationship"],nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],he.prototype,"graphType",void 0),(0,n.Cg)([(0,p.MZ)({type:String,nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],he.prototype,"graphTypeName",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"hasM",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"hasZ",null),(0,n.Cg)([(0,p.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],he.prototype,"id",void 0),(0,n.Cg)([(0,p.MZ)({type:Boolean,value:!0,nonNullable:!0,json:{name:"showLabels",default:!1,write:{overridePolicy(){return{enabled:!!this.geometryType,alwaysWriteDefaults:!0,ignoreOrigin:!0}}}}})],he.prototype,"labelsVisible",void 0),(0,n.Cg)([(0,p.MZ)({type:[V.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:function(e,t,i){const n=[["ESRI__AGGREGATION_COUNT",D.M1],["ESRI__ORIGIN_ID",D.Cz],["ESRI__DESTINATION_ID",D.KQ],["ESRI__LAYOUT_GEOMETRY",D.T1]];try{for(const t of e)for(const[e,i]of n)t.labelExpression=t.labelExpression?.replaceAll(e,i),t.labelExpressionInfo?.expression&&(t.labelExpressionInfo.expression=t.labelExpressionInfo.expression.replaceAll(e,i))}catch(e){a.A.getLogger(this).warn("Error updating labelingInfo",e)}return(0,X.w)(e,t,i)},write:de()}})],he.prototype,"labelingInfo",null),(0,n.Cg)([(0,p.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}}})],he.prototype,"layerType",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.fV)))],he.prototype,"legendEnabled",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.hG)))],he.prototype,"maxScale",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.hn)))],he.prototype,"minScale",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"objectIdField",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"objectType",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.ke)))],he.prototype,"opacity",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(G.ne)))],he.prototype,"orderBy",void 0),(0,n.Cg)([(0,p.MZ)({clonable:!1})],he.prototype,"parent",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"parentCompositeLayer",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.M6)))],he.prototype,"popupEnabled",void 0),(0,n.Cg)([(0,p.MZ)({type:r.A,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],he.prototype,"popupTemplate",void 0),(0,n.Cg)([(0,p.MZ)({type:Number,json:{write:{overridePolicy:ce}}})],he.prototype,"refreshInterval",void 0),(0,n.Cg)([(0,p.MZ)({types:te.Hg,json:{name:"layerDefinition.drawingInfo.renderer",write:de()}})],he.prototype,"renderer",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"source",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"spatialReference",null),(0,n.Cg)([(0,p.MZ)({type:J.A,json:{name:"layerDefinition.timeInfo",write:{overridePolicy:ce},origins:{"web-document":{name:"layerDefinition.timeInfo",read:!0,write:{overridePolicy:ce}},"portal-item":{name:"layerDefinition.timeInfo",read:!0,write:{overridePolicy:ce}}}}})],he.prototype,"timeInfo",null),(0,n.Cg)([(0,p.MZ)({type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],he.prototype,"title",null),(0,n.Cg)([(0,u.K)("title")],he.prototype,"writeTitle",null),(0,n.Cg)([(0,p.MZ)({json:{read:!1}})],he.prototype,"type",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(z.B)))],he.prototype,"useViewTime",void 0),(0,n.Cg)([(0,p.MZ)({type:Boolean,json:{name:"visibility",write:de()}})],he.prototype,"visible",void 0),he=(0,n.Cg)([(0,d.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayer")],he)},64714:(e,t,i)=>{i.d(t,{F0:()=>a,Vx:()=>d,e2:()=>c,f:()=>h});var n=i(44208),r=i(4718),s=i(99352),o=i(93470);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let p=1;function d(e,t){if((0,n.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let i=`this${u(t)} = null;`;for(const t in e)i+=`this${u(t)} = ${JSON.stringify(e[t])};`;const n=new Function(`\n return class AttributesClass$${p++} {\n constructor() {\n ${i};\n }\n }\n `)();return()=>new n}catch(i){return()=>({[t]:null,...e})}}function u(e){return l.test(e)?`.${e}`:`["${e}"]`}function c(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,r.o8)(e)}}]}function h(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:!0,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,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}}}},67996:(e,t,i)=>{i.d(t,{cZ:()=>S,XW:()=>F,fe:()=>N});var n=i(78888),r=i(49186),s=i(91869),o=(i(90708),i(92722)),a=i(16930);class l{constructor(){this.version="",this.queryResult=new p}}class p{constructor(){this.featureResult=new d}}class d{constructor(){this.objectIdFieldName="",this.uniqueIdField=new u,this.globalIdFieldName="",this.geohashFieldName="",this.geometryProperties=new c,this.geometryType=null,this.spatialReference=new a.A,this.exceededTransferLimit=!1,this.hasZ=!1,this.hasM=!1,this.transform=new h,this.fields=[],this.fieldNameToAttributeIndexMap={},this.values=[],this.features=[],this.geometryFields=[]}}class u{constructor(){this.name="",this.isSystemMaintained=!1}}class c{constructor(){this.shapeAreaFieldName="",this.shapeLengthFieldName="",this.units=""}}class h{constructor(){this.quantizeOriginPosition="upperLeft",this.scale=new y,this.translate=new m}}class y{constructor(){this.xScale=0,this.yScale=0,this.mScale=0,this.zScale=0}}class m{constructor(){this.xTranslate=0,this.yTranslate=0,this.mTranslate=0,this.zTranslate=0}}class f{constructor(){this.name="",this.fieldType="esriFieldTypeString",this.alias="",this.sqlType="sqlTypeVarchar",this.domain="",this.defaultValue=""}}class g{constructor(){this.attributes=[],this.compressedGeometry=new b,this.centroid=new b,this.aggregateGeometries=[]}}class b{constructor(){this.geometryType=null,this.lengths=[],this.coords=[]}}const w=["ELEMENTUID","TYPENAME"];var _=i(45724),M=i(35448);const I={upperLeft:0,lowerLeft:1},T={sqlTypeBigInt:0,sqlTypeBinary:1,sqlTypeBit:2,sqlTypeChar:3,sqlTypeDate:4,sqlTypeDecimal:5,sqlTypeDouble:6,sqlTypeFloat:7,sqlTypeGeometry:8,sqlTypeGUID:9,sqlTypeInteger:10,sqlTypeLongNVarchar:11,sqlTypeLongVarbinary:12,sqlTypeLongVarchar:13,sqlTypeNChar:14,sqlTypeNVarChar:15,sqlTypeOther:16,sqlTypeReal:17,sqlTypeSmallInt:18,sqlTypeSqlXml:19,sqlTypeTime:20,sqlTypeTimestamp:21,sqlTypeTimestamp2:22,sqlTypeTinyInt:23,sqlTypeVarbinary:24,sqlTypeVarchar:25};var C=i(93637);function v(e){const t=new b;t.geometryType=(0,C.i7)(M.bV,e.geometry_type.value);const i=[],n=[];for(let t=0;t<e.lengths.length;t++)i.push(e.lengths[t]);for(let t=0;t<e.coords.length;t++)n.push(e.coords[t]);return t.lengths=i,t.coords=n,t}function x(e){const t=new f;return t.name=e.name,t.alias=e.alias,t.fieldType=(0,C.i7)(M.r5,e.field_type.value),t.sqlType=(0,C.i7)(T,e.sql_type.value),t.domain=e.domain,t.defaultValue=e.default_value,t}function A(e){const t=x(e);return t.geometryType=(0,C.i7)(M.bV,e.geometry_type.value),t}function E(e){const t=new h;t.quantizeOriginPosition=(0,C.i7)(I,e.quantizeOriginPosition.value);const i=t.scale,n=e.scale;i.xScale=n.xScale,i.yScale=n.yScale,i.mScale=n.mScale,i.zScale=n.zScale;const r=t.translate,s=e.translate;return r.xTranslate=s.xTranslate,r.yTranslate=s.yTranslate,r.mTranslate=s.mTranslate,r.zTranslate=s.zTranslate,t}async function S(e,t){t??=!1;const i={generateAllSublayers:t,namedTypeDefinitions:new Map};return await async function(e){const t=await(0,n.A)(e,{responseType:"array-buffer"}),i=await t.data;return async function(e){const t=new((await(0,_.I)()).MapOfObjectIdentifierSetsDecoder),i=t.decode(new Uint8Array(e)),n=new Map;if(0!==i.error_code)throw new r.A("knowledge-graph:layer-support-utils",i.error_message);const s=t.get_map_of_identifier_sets(),o=s.keys,a=o.size();for(let e=0;e<a;e++){const t=o.get(e),i=s.query_identifier_set(t),a=[];if(1===i.id_array_type.value){const e=i.get_globalid_array(),t=e.count();for(let i=0;i<t;i++)a.push(e.get_globalid_at(i))}else if(3===i.id_array_type.value){const e=i.get_identifier_array(),t=e.count();for(let i=0;i<t;i++)a.push(e.get_identifier_at(i).toString())}else if(2===i.id_array_type.value){const e=i.get_string_array(),t=e.count();for(let i=0;i<t;i++)a.push(e.get_string_at(i))}else{if(0!==i.id_array_type.value)throw new r.A("knowledge-graph:layer-support-utils","Tried to encode an unexpected ID Array type.");{const e=i.get_oid_array(),t=e.count();for(let i=0;i<t;i++)a.push(e.get_objectid_at(i).toString())}}n.set(t,a)}return t.delete(),n}(new Uint8Array(i))}(e).then(e=>{!function(e,t){for(const[i,n]of e){const e=(0,s.tE)(t.namedTypeDefinitions,i,()=>({useAllData:!1,members:new Map}));for(const t of n)e.members.has(t)||e.members.set(t,{id:t})}}(e,i)}),i}async function N(e){const t=await(0,_.I)(),i=new t.MapOfObjectIdentifierSets;!function(e,t,i){for(const[n,r]of i.namedTypeDefinitions){if(!r.members||r.useAllData)continue;const i=r.members.keys();let s=!1,o=!0;const a=new t.ObjectIdArray,l=new t.StringArray,p=new t.GlobalIdArray,d=new t.IdentifierArray,u=new t.ObjectIdentifierSet;for(const e of i)o&&(s=!isNaN(Number(e)),o=!1),s?a.add_objectid(Number(e)):(l.add_string(e),p.add_globalid(e)),d.add_identifier(e);u.set_oid_array(a),u.set_string_array(l),u.set_globalid_array(p),u.set_identifier_array(d),a.delete(),l.delete(),p.delete(),d.delete(),e.put_identifier_set(n,u),u.delete()}}(i,t,e);const n=new t.MapOfObjectIdentifierSetsEncoder;try{n.set_map_of_identifier_sets(i),n.encode();const e=n.get_encoding_result();if(0!==e.error.error_code)throw new r.A("knowledge-graph:layer-support-utils",e.error.error_message);const t=structuredClone(e.get_byte_buffer());return n.delete(),t}finally{i.delete()}}async function k(e){const t=await(0,n.A)(e,{responseType:"array-buffer"});return async function(e){const t=new((await(0,_.I)()).FeatureCollectionDecoder),i=t.decode(new Uint8Array(e));if(0!==i.error_code)throw new r.A("knowledge-graph:layer-support-utils",i.error_message);const n=function(e){const t=new l;t.version=e.version;const i=e.get_query_result();if(0!==i.results_type.value)throw new Error("Got a non-feature collection type");const n=i.get_feature_result(),r=t.queryResult.featureResult;r.objectIdFieldName=n.objectid_field_name,r.exceededTransferLimit=n.exceeded_transfer_limit,r.hasM=n.has_m,r.hasZ=n.has_z,r.geometryType=(0,C.i7)(M.bV,n.geometry_type.value),r.globalIdFieldName=n.globalid_field_name,r.geohashFieldName=n.geohash_field_name;const s=r.uniqueIdField,o=n.unique_id_field;s.name=o.name,s.isSystemMaintained=o.isSystemMaintained;const a=r.geometryProperties,p=n.geometry_properties;a.shapeAreaFieldName=p.shapeAreaFieldName,a.shapeLengthFieldName=p.shapeLengthFieldName,a.units=p.units;const d=r.spatialReference,u=n.spatial_reference;d.wkid=u.wkid,d.latestWkid=u.latestWkid,d.vcsWkid=u.vcsWkid,d.latestVcsWkid=u.latestVcsWkid,d.wkt=u.wkt,r.transform=E(n.transform);const c=r.fields,h=r.fieldNameToAttributeIndexMap,y=n.fields,m=y.size();for(let e=0;e<m;e++){const t=y.get(e),i=x(t);c.push(i),h[i.name]=e,t.delete()}y.delete();const f=r.values,b=n.values_count();for(let e=0;e<b;e++)f.push(n.get_value_at(e));const _=r.features,I=n.features,T=I.size();if(T>0)for(const e of w)if(void 0===h[e])throw new Error(`Feature collection missing required attribute: ${e}`);for(let e=0;e<T;e++){const t=new g,i=I.get(e),n=t.attributes,r=i.attributes_count();for(let e=0;e<r;e++)n.push(i.get_attribute_at(e));const s=i.get_compressed_geometry();s&&(t.compressedGeometry=v(s),t.centroid=v(i.get_centroid()));const o=t.aggregateGeometries,a=i.aggregate_geometries,l=a.size();for(let e=0;e<l;e++){const t=a.get(e),i=v(t);o.push(i),t.delete()}a.delete(),_.push(t),i.delete()}I.delete();const S=r.geometryFields,N=n.geometry_fields,k=N.size();for(let e=0;e<k;e++){const t=N.get(e),i=A(t);S.push(i),t.delete()}return N.delete(),t}(t.get_feature_collection());return t.delete(),n}(await t.data)}function L(e,t){if(!e?.queryResult?.featureResult)return t;const{hasZ:i,hasM:n}=e.queryResult.featureResult,r=e.queryResult.featureResult.fieldNameToAttributeIndexMap;for(const a of e.queryResult.featureResult.features){const e=a.attributes[r.TYPENAME],l=(0,s.tE)(t.namedTypeDefinitions,e,()=>({useAllData:!1,members:new Map})),p=a.attributes[r.ELEMENTUID];if(a.compressedGeometry?.coords?.length>0){let e=a.compressedGeometry.lengths;"esriGeometryPoint"===a.compressedGeometry.geometryType&&(e=[]),l.members.set(p,{id:p,linkChartLocation:new o.A(e,a.compressedGeometry.coords,i,n)})}else l.members.set(p,{id:p})}return t}const F={fetchAndConvertSerializedLinkChart:e=>async function(e){const t=[],i={generateAllSublayers:!1,namedTypeDefinitions:new Map};return e.entitiesUrl&&t.push(k(e.entitiesUrl).then(e=>{L(e,i)})),e.relationshipsUrl&&t.push(k(e.relationshipsUrl).then(e=>{L(e,i)})),await Promise.all(t),i}(e)}},69860:(e,t,i)=>{i.d(t,{A:()=>a});var n=i(65864),r=i(90708),s=i(43334),o=i(15375);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 i=this.readFromStoreById(e);i&&t.push(i)}),t}readFromStoreById(e){return this._featureLookup.get(e)??null}writeToStore(e,t,i){const a=[];return e.forEach(e=>{if(!e?.id)return;e.properties||(e.properties=[]);let l,p=null;if(i&&e.properties[i]&&(p=(0,r.Ux)(e.properties[i])),"originId"in e&&"destinationId"in e&&(e.properties[o.Cz]=e.originId,e.properties[o.KQ]=e.destinationId),e.properties[t]=e.id,e.id&&this._featureLookup.has(e.id)&&this._featureLookup.get(e.id).attributes){const r=this._featureLookup.get(e.id),o=JSON.parse(JSON.stringify(Object.assign(r.attributes,e.properties)));i&&e.properties[i]&&(o[i]=(0,n.rS)(e.properties[i])),l=new s.Om(p?JSON.parse(JSON.stringify(p)):r?.geometry?JSON.parse(JSON.stringify(r.geometry)):null,o,null,e.properties[t])}else l=new s.Om(p?JSON.parse(JSON.stringify(p)):null,e.properties,null,e.properties[t]);this._featureLookup.set(`${e.typeName?`${e.typeName}__${e.id}`:e.id}`,l),a.push(l)}),a}}},73133:(e,t,i)=>{i.d(t,{j:()=>n});const n=(0,i(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})},75503:(e,t,i)=>{i.d(t,{EC:()=>v,wq:()=>a});var n=i(4576),r=i(21818),s=(i(44208),i(15142)),o=i(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(),M.prune(),I.prune(),T.prune(),C.prune()}all(e){l(this._data,e)}search(e,t){let i=this._data;const n=this._toBBox;if(w(e,i))for(M.clear();i;){for(let r=0,s=i.children.length;r<s;r++){const s=i.children[r],o=i.leaf?n(s):s;w(e,o)&&(i.leaf?t(s):b(e,o)?l(s,t):M.push(s))}i=M.pop()}}collides(e){let t=this._data;const i=this._toBBox;if(!w(e,t))return!1;for(M.clear();t;){for(let n=0,r=t.children.length;n<r;n++){const r=t.children[n],s=t.leaf?i(r):r;if(w(e,s)){if(t.leaf||b(e,s))return!0;M.push(r)}}t=M.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,i=e.length;t<i;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 A([]),this}remove(e){if(!e)return this;let t,i=this._data,s=null,o=0,a=!1;const l=this._toBBox(e);for(T.clear(),C.clear();i||T.length>0;){if(i||(i=T.pop(),s=T.data[T.length-1],o=C.pop()??0,a=!0),i.leaf&&(t=(0,n.qh)(i.children,(0,r.zI)(e),i.children.length,i.indexHint),-1!==t))return i.children.splice(t,1),T.push(i),this._condense(T),this;a||i.leaf||!b(i,l)?s?(o++,i=s.children[o],a=!1):i=null:(T.push(i),C.push(o),o=0,s=i,i=i.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,i,n){const r=i-t+1;let s=this._maxEntries;if(r<=s){const n=new A(e.slice(t,i+1));return p(n,this._toBBox),n}n||(n=Math.ceil(Math.log(r)/Math.log(s)),s=Math.ceil(r/s**(n-1)));const o=new E([]);o.height=n;const a=Math.ceil(r/s),l=a*Math.ceil(Math.sqrt(s));_(e,t,i,l,this._compareMinX);for(let r=t;r<=i;r+=l){const t=Math.min(r+l-1,i);_(e,r,t,a,this._compareMinY);for(let i=r;i<=t;i+=a){const r=Math.min(i+a-1,t);o.children.push(this._build(e,i,r,n-1))}}return p(o,this._toBBox),o}_insert(e,t,i){const n=this._toBBox,r=i?e:n(e);T.clear();const s=function(e,t,i,n){for(;n.push(t),!0!==t.leaf&&n.length-1!==i;){let i,n=1/0,r=1/0;for(let s=0,o=t.children.length;s<o;s++){const o=t.children[s],a=y(o),l=f(e,o)-a;l<r?(r=l,n=a<n?a:n,i=o):l===r&&a<n&&(n=a,i=o)}t=i||t.children[0]}return t}(r,this._data,t,T);for(s.children.push(e),u(s,r);t>=0&&T.data[t].children.length>this._maxEntries;)this._split(T,t),t--;!function(e,t,i){for(let n=i;n>=0;n--)u(t.data[n],e)}(r,T,t)}_split(e,t){const i=e.data[t],n=i.children.length,r=this._minEntries;this._chooseSplitAxis(i,r,n);const s=this._chooseSplitIndex(i,r,n);if(!s)return;const o=i.children.splice(s,i.children.length-s),a=i.leaf?new A(o):new E(o);a.height=i.height,p(i,this._toBBox),p(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(i,a)}_splitRoot(e,t){this._data=new E([e,t]),this._data.height=e.height+1,p(this._data,this._toBBox)}_chooseSplitIndex(e,t,i){let n,r,s;n=r=1/0;for(let o=t;o<=i-t;o++){const t=d(e,0,o,this._toBBox),a=d(e,o,i,this._toBBox),l=g(t,a),p=y(t)+y(a);l<n?(n=l,s=o,r=p<r?p:r):l===n&&p<r&&(r=p,s=o)}return s}_chooseSplitAxis(e,t,i){const n=e.leaf?this._compareMinX:c,r=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,i,n)<this._allDistMargin(e,t,i,r)&&e.children.sort(n)}_allDistMargin(e,t,i,n){e.children.sort(n);const r=this._toBBox,s=d(e,0,t,r),o=d(e,i-t,i,r);let a=m(s)+m(o);for(let n=t;n<i-t;n++){const t=e.children[n];u(s,e.leaf?r(t):t),a+=m(s)}for(let n=i-t-1;n>=t;n--){const t=e.children[n];u(o,e.leaf?r(t):t),a+=m(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const i=e.data[t];if(0===i.children.length)if(t>0){const r=e.data[t-1],s=r.children;s.splice((0,n.qh)(s,i,s.length,r.indexHint),1)}else this.clear();else p(i,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 i=e;for(I.clear();i;){if(!0===i.leaf)for(const e of i.children)t((0,r.zI)(e));else I.pushArray(i.children);i=I.pop()??null}}function p(e,t){d(e,0,e.children.length,t,e)}function d(e,t,i,n,r){r||(r=new A([])),r.minX=1/0,r.minY=1/0,r.maxX=-1/0,r.maxY=-1/0;for(let s,o=t;o<i;o++)s=e.children[o],u(r,e.leaf?n(s):s);return r}function u(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 i=Math.max(e.minX,t.minX),n=Math.max(e.minY,t.minY),r=Math.min(e.maxX,t.maxX),s=Math.min(e.maxY,t.maxY);return Math.max(0,r-i)*Math.max(0,s-n)}function b(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function w(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function _(e,t,i,n,r){const s=[t,i];for(;s.length;){const t=s.pop(),i=s.pop();if(t-i<=n)continue;const a=i+Math.ceil((t-i)/n/2)*n;(0,o.q)(e,a,i,t,r),s.push(i,a,a,t)}}const M=new s.A,I=new s.A,T=new s.A,C=new s.A({deallocator:void 0});class v{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class x extends v{constructor(){super(...arguments),this.height=1,this.indexHint=new n.vW}}class A extends x{constructor(e){super(),this.children=e,this.leaf=!0}}class E extends x{constructor(e){super(),this.children=e,this.leaf=!1}}},77901:(e,t,i)=>{i.d(t,{A:()=>a});var n=i(31635),r=i(25482),s=i(10107),o=(i(44208),i(53966),i(87811),i(64108));let a=class extends r.o{constructor(e){super(e),this.properties=null}};(0,n.Cg)([(0,s.MZ)({json:{write:!0}})],a.prototype,"properties",void 0),a=(0,n.Cg)([(0,o.$)("esri.rest.knowledgeGraph.GraphObject")],a)},82935:(e,t,i)=>{i.d(t,{B:()=>h,e:()=>y});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(36005)),o=i(64108),a=i(89317),l=i(30524),p=i(96184),d=i(73133),u=i(79677),c=i(10184);const h={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:a.K}}},y=e=>{const t=e;let i=class extends t{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const i=t.timeInfo.exportOptions;if(!i)return null;const n=i.timeOffset,r=d.j.fromJSON(i.timeOffsetUnits);return n&&r?new c.A({value:n,unit:r}):null}set timeInfo(e){(0,l.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,n.Cg)([(0,r.MZ)({type:u.A,json:{write:!1}})],i.prototype,"timeExtent",void 0),(0,n.Cg)([(0,r.MZ)({type:c.A})],i.prototype,"timeOffset",void 0),(0,n.Cg)([(0,s.w)("service","timeOffset",["timeInfo.exportOptions"])],i.prototype,"readOffset",null),(0,n.Cg)([(0,r.MZ)({value:null,type:p.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],i.prototype,"timeInfo",null),(0,n.Cg)([(0,r.MZ)(h)],i.prototype,"useViewTime",void 0),i=(0,n.Cg)([(0,o.$)("esri.layers.mixins.TemporalLayer")],i),i}},83221:(e,t,i)=>{i.d(t,{A:()=>y});var n=i(4576),r=i(49186),s=i(65529),o=i(53966),a=i(70328),l=i(19419),p=i(90708),d=i(6518),u=i(51441),c=i(37730);const h=(0,a.vt)();class y{constructor(e){this.geometryInfo=e,this._boundsStore=new d.F,this._featuresById=new Map,this._usedMemory=0,this.events=new s.bk,this.featureAdapter=c.T}get usedMemory(){return this._usedMemory}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,i,n,r]=this.fullBounds;return{xmin:t,ymin:i,xmax:n,ymax:r,spatialReference:(0,u.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(),this._usedMemory=0}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 i of e){const e=this._boundsStore.get(i.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 r.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const i=this._featuresById.get(t);let n;if(i?(e.displayId=i.displayId,n=this._boundsStore.get(t),this._boundsStore.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(i)??0):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);n=(0,p.jQ)(null!=n?n:(0,l.vt)(),e.geometry),null!=n&&this._boundsStore.set(t,n),this._featuresById.set(t,e),this._usedMemory+=this.estimateFeatureUsedMemory?.(e)??0}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new r.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const i=this._featuresById.get(t);if(!i)return this._add(e),e;this._usedMemory-=this.estimateFeatureUsedMemory?.(i)??0;const{geometry:n,attributes:s}=e;for(const e in s)i.attributes[e]=s[e];return n&&(i.geometry=n,this._boundsStore.set(t,(0,p.jQ)((0,l.vt)(),n)??null)),this._usedMemory+=this.estimateFeatureUsedMemory?.(i)??0,i}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._boundsStore.delete(t),this._featuresById.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(e)??0,e}}},83960:(e,t,i)=>{i.d(t,{X_:()=>o,oW:()=>l,zx:()=>a});var n=i(34727),r=i(83047);const s=96;function o(e,t){const i=t||e.extent,n=e.width,o=(0,r.GA)(i?.spatialReference);return i&&n?i.width/n*o*r.dy*s:0}function a(e,t,i){return function(e,t){return 0===t||(0,n.Sp)(e,t)||e<t}(e,t)&&function(e,t){return 0===t||(0,n.Sp)(e,t)||e>t}(e,i)}function l(e,t){return(0,n.Sp)(e,t)?0:(e||Number.POSITIVE_INFINITY)>(t||Number.POSITIVE_INFINITY)?1:-1}},96184:(e,t,i)=>{i.d(t,{A:()=>y});var n=i(31635),r=i(69540),s=i(25482),o=i(10107),a=(i(44208),i(53966),i(87811),i(36005)),l=i(64108),p=i(43937),d=i(79677),u=i(10184),c=i(56400);function h(e,t){return u.A.fromJSON({value:e,unit:t})}let y=class extends((0,r.OU)(s.o)){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.Cg)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],y.prototype,"cumulative",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"endField",void 0),(0,n.Cg)([(0,o.MZ)({type:d.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"fullTimeExtent",void 0),(0,n.Cg)([(0,a.w)("fullTimeExtent",["timeExtent"])],y.prototype,"readFullTimeExtent",null),(0,n.Cg)([(0,p.K)("fullTimeExtent")],y.prototype,"writeFullTimeExtent",null),(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{write:!0}})],y.prototype,"hasLiveData",void 0),(0,n.Cg)([(0,o.MZ)({type:u.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"interval",void 0),(0,n.Cg)([(0,a.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],y.prototype,"readInterval",null),(0,n.Cg)([(0,p.K)("interval")],y.prototype,"writeInterval",null),(0,n.Cg)([(0,o.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"startField",void 0),(0,n.Cg)([(0,o.MZ)((0,c.P6)("timeReference",!0))],y.prototype,"timeZone",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"trackIdField",void 0),(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],y.prototype,"useTime",void 0),(0,n.Cg)([(0,o.MZ)({type:[Date],json:{read:!1}})],y.prototype,"stops",void 0),y=(0,n.Cg)([(0,l.$)("esri.layers.support.TimeInfo")],y)}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8948],{6455:(e,t,i)=>{i.d(t,{FJ:()=>b,Dp:()=>w,KV:()=>_});var n=i(31635),r=i(93637),s=i(10107),o=(i(44208),i(53966),i(87811),i(64108)),a=i(89317),l=i(69540),p=i(7762),d=i(25482),u=i(43937),c=i(83960),h=i(13069);const y={write:{overridePolicy:(e,t,i)=>({enabled:!i||"scale"===i.filterMode})}};let m=class extends((0,l.OU)(d.o)){constructor(e){super(e),this.id=(0,h.lk)(),this.maxScale=0,this.minScale=0,this.title="",this.where=null}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],m.prototype,"id",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:y})],m.prototype,"maxScale",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:y})],m.prototype,"minScale",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],m.prototype,"title",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],m.prototype,"where",void 0),m=(0,n.Cg)([(0,o.$)("esri.layers.support.DisplayFilter")],m);var f=i(41560);let g=class extends((0,l.OU)(d.o)){constructor(e){super(e),this.activeFilterId=null,this.filters=new(p.A.ofType(m)),this.mode="manual"}writeFilters(e,t,i,n){const r=e.toArray();"scale"===this.mode&&r.sort((e,t)=>{const i=(0,c.oW)(t.minScale,e.minScale),n=e.maxScale-t.maxScale;return 0===i?n:i}),t[i]=r.map(e=>e.toJSON(n))}write(e,t){return super.write(e,(0,f.mW)(this,t))}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:{overridePolicy:(e,t,i)=>({enabled:"manual"===i.filterMode,isRequired:!0})}}})],g.prototype,"activeFilterId",void 0),(0,n.Cg)([(0,s.MZ)({type:p.A.ofType(m),nonNullable:!0,json:{write:!0}})],g.prototype,"filters",void 0),(0,n.Cg)([(0,u.K)("filters")],g.prototype,"writeFilters",null),(0,n.Cg)([(0,s.MZ)({type:["manual","scale"],nonNullable:!0,json:{name:"filterMode",write:!0}})],g.prototype,"mode",void 0),g=(0,n.Cg)([(0,o.$)("esri.layers.support.DisplayFilterInfo")],g);const b=e=>{const t=e;let i=class extends t{constructor(){super(...arguments),this.displayFilterEnabled=!0,this.displayFilterInfo=null}};return(0,n.Cg)([(0,s.MZ)(w)],i.prototype,"displayFilterEnabled",void 0),(0,n.Cg)([(0,s.MZ)(_)],i.prototype,"displayFilterInfo",void 0),i=(0,n.Cg)([(0,o.$)("esri.layers.mixins.DisplayFilteredLayer")],i),i},w={type:Boolean,json:{name:"layerDefinition.disableDisplayFilter",read:{reader:e=>!e},write:{layerContainerTypes:a.K,writer(e,t,i){(0,r.sM)(i,!e,t)}},origins:{"web-scene":{write:!1,read:!1}}}},_={type:g,json:{name:"layerDefinition.displayFilterInfo",write:{enabled:!0,allowNull:!0,layerContainerTypes:a.K},origins:{"web-scene":{write:!1,read:!1}}}}},6518:(e,t,i)=>{i.d(t,{F:()=>a});var n=i(44208),r=i(75503),s=i(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 r.wq(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((i,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,s.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,i){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,i)}(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()))}}},8460:(e,t,i)=>{i.d(t,{$C:()=>y,Hh:()=>o,Tu:()=>c,Wg:()=>h,Xq:()=>f,i6:()=>g,pM:()=>u,vJ:()=>m});var n=i(2741);let r,s=null;function o(){return r||(r=i.e(3666).then(i.bind(i,3666)).then(e=>e.l).then(({default:e})=>e({locateFile:e=>(0,n.s)(`esri/libs/linkchartlayout/${e}`)})).then(e=>{!function(e){s=e}(e)}),r)}const a={right:0,left:1,top:2,bottom:3},l={none:0,"start-only":1,"start-and-end":2};function p(e){const t={timeDirection:"right",timeBannerUTCOffsetInMinutes:0,eventsTicksVisualization:"start-and-end",showDurationLineForNonZeroDurationEntityEvents:!0,durationLineWidth:5,entityPositionAtDurationRatio:1,showNonZeroDurationIntervalBounds:!1,separateTimeOverlaps:!0,separateTimelineOverlaps:!0,moveFirstBends:!0,secondBendRatio:.3,lineSeparationMultiplier:1,spaceSeparatedLinesEvenly:!1,useBezierCurves:!1,separatedLineShapeRatio:0,...e?.toJSON(),eventsTicksVisualization:e?.eventsTicksVisualization??"start-and-end"};return{...t,timeDirection:{value:a[t.timeDirection]??a.right},eventsTicksVisualization:{value:l[t.eventsTicksVisualization]??l["start-and-end"]}}}function d(e,t,i,n,r,o){const a=i.length,l=r.length,p=Float64Array.BYTES_PER_ELEMENT,d=Uint32Array.BYTES_PER_ELEMENT,u=Uint8Array.BYTES_PER_ELEMENT,c=16+a*(u+2*p)+l*(2*d),h=s._malloc(c);try{const u=h+16-h%16,c=u+a*p,y=c+a*p,m=y+l*d,f=m+l*d,g=()=>[s.HEAPF64.subarray(u>>3,(u>>3)+a),s.HEAPF64.subarray(c>>3,(c>>3)+a),s.HEAPU32.subarray(y>>2,(y>>2)+l),s.HEAPU32.subarray(m>>2,(m>>2)+l),s.HEAPU8.subarray(f,f+a)],[b,w,_,M,I]=g();b.set(i),w.set(n),_.set(r),M.set(o),I.set(t);const T=e(a,f,u,c,l,y,m);let C=null,v=null;if(0===T.value){const e=s.getLayoutLinksTypes(),t=s.getLayoutLinksVerticesEndIndices(),i=s.getLayoutLinksVertices(),n=s.countLayoutLinksVertices();!l||e&&t?n&&!i?T.value=1:(C={types:new Uint8Array(s.HEAPU8.subarray(e,e+l)),vertexEndIndex:new Uint32Array(s.HEAPU32.subarray(t>>2,(t>>2)+l)),vertices:new Float64Array(s.HEAPF64.subarray(i>>3,(i>>3)+2*n))},v=s.getAuxiliaryGraphicElements()):T.value=1}const[x,A,E,S,N]=g();return i.set(x),n.set(A),r.set(E),o.set(S),t.set(N),{status:T.value,links:C,graphics:v}}finally{s._free(h),s.cleanupLayout()}}var u,c,h,y,m,f,g,b;(b=u||(u={})).getMinIdealEdgeLength=function(){return s.getMinIdealEdgeLength()},b.apply=function(e,t,i,n,r,o,a=2,l=1,p=-1){return d((t,i,n,r,o,d,u)=>s.applyForceDirectedLayout(e,t,i,n,r,o,d,u,a,l,p),t,i,n,r,o)},function(e){e.apply=function(e,t,i,n,r,o,a=2,l=1,p=-1){return d((t,i,n,r,o,d,u)=>s.applyCommunityLayout(e,t,i,n,r,o,d,u,a,l,p),t,i,n,r,o)}}(c||(c={})),function(e){e.apply=function(e,t,i,n,r,o){return d((t,i,n,r,o,a,l)=>s.applySimpleLayout(e,t,i,n,r,o,a,l),t,i,n,r,o)}}(h||(h={})),function(e){e.apply=function(e,t,i,n,r,o){return d((t,i,n,r,o,a,l)=>s.applyHierarchicalLayout(e,t,i,n,r,o,a,l),t,i,n,r,o)}}(y||(y={})),function(e){e.apply=function(e,t,i,n,r,o){return d((t,i,n,r,o,a,l)=>s.applyRadialTreeLayout(e,t,i,n,r,o,a,l),t,i,n,r,o)}}(m||(m={})),function(e){e.apply=function(e,t,i,n,r,o){return d((t,i,n,r,o,a,l)=>s.applySmartTreeLayout(e,t,i,n,r,o,a,l),t,i,n,r,o)}}(f||(f={})),function(e){e.apply=function(e,t,i,n,r,o,a,l,u,c,h,y){return d((t,i,n,a,l,d,m)=>{if(r.length!==t)return{value:1};if(o.length!==t)return{value:1};if(u.length!==l)return{value:1};if(c.length!==l)return{value:1};const f=Float64Array.BYTES_PER_ELEMENT,g=16,b=s._malloc(g+t*f),w=s._malloc(g+t*f),_=s._malloc(g+l*f),M=s._malloc(g+l*f),I=b+g-b%g,T=w+g-w%g,C=_+g-_%g,v=M+g-M%g;try{return s.HEAPF64.subarray(I>>3,(I>>3)+t).set(r),s.HEAPF64.subarray(T>>3,(T>>3)+t).set(o),s.HEAPF64.subarray(C>>3,(C>>3)+l).set(u),s.HEAPF64.subarray(v>>3,(v>>3)+l).set(c),s.applyChronologicalLayout(e,t,i,n,a,I,T,l,d,m,C,v,h,p(y))}finally{s._free(b),s._free(w),s._free(_),s._free(M)}},t,i,n,a,l)}}(g||(g={}))},10184:(e,t,i)=>{i.d(t,{A:()=>u});var n=i(31635),r=i(69540),s=i(25482),o=i(88930),a=i(10107),l=(i(44208),i(53966),i(87811),i(93223)),p=i(64108),d=i(73133);let u=class extends((0,r.OU)(s.o)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,n.Cg)([(0,l.e)(d.j,{nonNullable:!0})],u.prototype,"unit",void 0),(0,n.Cg)([(0,a.MZ)({type:Number,json:{write:!0},nonNullable:!0})],u.prototype,"value",void 0),u=(0,n.Cg)([(0,p.$)("esri.time.TimeInterval")],u)},15375:(e,t,i)=>{i.d(t,{BL:()=>l,Cz:()=>r,KQ:()=>s,M1:()=>a,T1:()=>o,dr:()=>n});const n="ESRI__ID",r="ESRI__OriginID",s="ESRI__DestID",o="ESRI__LayoutGeometry",a="ESRI__AggregationCount",l="LC.ESRI__IsSpatial"},17036:(e,t,i)=>{i.d(t,{p:()=>l});var n=i(44208),r=i(53966),s=i(20437),o=i(95466),a=i(30524);function l(){return{fields:{type:[s.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(", ");r.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 i=this.fieldsIndex?.has(t);i||r.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)}}}}},23150:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(64108)),o=i(82799),a=i(54238);let l=class extends a.A{constructor(e){super(e),this.originId=null,this.destinationId=null,this.layoutGeometry=null}};(0,n.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],l.prototype,"originId",void 0),(0,n.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],l.prototype,"destinationId",void 0),(0,n.Cg)([(0,r.MZ)({type:o.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.Relationship")],l)},24137:(e,t,i)=>{i.d(t,{P:()=>T});var n=i(31635),r=i(69622),s=i(49186),o=i(53966),a=i(91869),l=i(74887),p=i(39516),d=i(10107),u=(i(44208),i(87811),i(64108)),c=i(5443),h=i(39829),y=i(91218),m=i(21325),f=i(15375);const g=(e,t)=>{if("column-reference"===e.type)return e.column===t.systemOidFieldName?"ID(n)":`n.${e.column}`;if("string"===e.type)return`'${e.value}'`;if("number"===e.type)return`${e.value}`;if("binary-expression"===e.type&&t.supportedSqlTypes.has(e.left.type)&&t.supportedSqlTypes.has(e.right.type)&&t.supportedSqlOperators.has(e.operator))return`${g(e.left,t)} ${e.operator} ${g(e.right,t)}`;if("binary-expression"===e.type&&"LIKE"===e.operator){let i="";if("function"===e.left.type&&"column-reference"===e.left.args.value[0].type)i+=`lower(n.${e.left.args.value[0].column})`;else{if("column-reference"!==e.left.type)return t.unsupportedOperationFound=!0,"";i+=`lower(n.${e.left.column})`}if(i+=" CONTAINS (","string"!==e.right.type)return t.unsupportedOperationFound=!0,"";{let t=e.right.value;t.startsWith("%")&&(t=t.slice(1)),t.endsWith("%")&&(t=t.slice(0,-1)),i+=`'${t.toLowerCase()}')`}return i}return t.unsupportedOperationFound=!0,""};var b=i(69860),w=i(30504),_=i(62568),M=i(42538),I=i(61956);let T=class extends r.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(i=>{i.name&&(t.set(i.name,"entity"),this._processingCacheUpdatesLookup.set(i.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.entityTypeNames.add(i.name),i.properties?.forEach(e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(i.name,{name:e.name??"",geometryType:e.geometryType})}))}),e.knowledgeGraph.dataModel.relationshipTypes?.forEach(i=>{i.name&&(t.set(i.name,"relationship"),this._processingCacheUpdatesLookup.set(i.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.relationshipTypeNames.add(i.name),i.properties?.forEach(e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(i.name,{name:e.name??"",geometryType:e.geometryType})}))}),e.inclusionModeDefinition?.namedTypeDefinitions.forEach((i,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 r=new Map;i.members?.forEach(e=>{(0,a.tE)(this.memberIdTypeLookup,e.id,()=>new Set).add(n)}),this.sublayerCaches.set(n,r)})}addToLayer(e){e.forEach(({typeName:e,id:t})=>{if(!this.inclusionModeDefinition)throw new s.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 i=this.inclusionModeDefinition.namedTypeDefinitions.get(e);i.members||(i.members=new Map),i.members.set(t,{id:t}),(0,a.tE)(this.memberIdTypeLookup,t,()=>new Set).add(e)}}else{const i=new Map;i.set(t,{id:t}),this.inclusionModeDefinition.namedTypeDefinitions.set(e,{useAllData:!1,members:i}),(0,a.tE)(this.memberIdTypeLookup,t,()=>new Set).add(e)}})}getById(e){return b.A.getInstance().readFromStoreById(e)}async getData(e,t,i){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 I.A({where:"1=1",outFields:["*"]}),"link-chart"===t.parentCompositeLayer.type){const e=t.parentCompositeLayer,i=this._processingCacheUpdatesLookup.get(t.objectType.name??""),r=n.outFields;r&&1===r.length&&r[0]===f.dr&&"1=1"===n.where||await Promise.all(i??[]);const s=this.sublayerCaches.has(t.objectType.name??"")?Array.from(this.sublayerCaches.get(t.objectType.name)?.values()):[],o=[];return s.forEach(i=>{if(this.relationshipTypeNames.has(t.objectType.name)){i.geometry=e.relationshipLinkChartDiagramLookup.get(i.attributes[t.objectIdField]);const n=this.memberIdTypeLookup.get(i.attributes[f.Cz]),r=this.memberIdTypeLookup.get(i.attributes[f.KQ]),s=this._isEndEntitySpatial(n,i,f.Cz),o=this._isEndEntitySpatial(r,i,f.KQ);i.attributes[f.BL]=Number(s&&o)}else{i.geometry=e.entityLinkChartDiagramLookup.get(i.attributes[t.objectIdField]);const n=this.geographicLookup.get(t.objectType.name);n&&i.attributes[n.name]?i.attributes[f.BL]=1:i.attributes[f.BL]=0}i.attributes[f.T1]=i.geometry,o.push(i)}),o}return this.retrieveDataFromService(n,t,i)}async getConnectedRecordIds(e,t,i){const n=[];let r="";const s=this._getNamedTypeIdMapFromNodeIds(e);if(t&&0!==t?.length){for(const e of t)r=r+e+"|";r=r.slice(0,-1)}const o={},a=[];for(const[e,i]of s){const n=`${e}_ids`;o[n]=i,t&&0!==t?.length?a.push(`MATCH (n:${e}) WHERE id(n) IN $${n} WITH n MATCH (n)-[r:${r}]-(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 "),p=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new M.A({openCypherQuery:l,bindParameters:o}),{signal:i?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await p.read();if(e)break;for(let e=0;e<t.length;e++){const i=t[e];n.push({id:i[0],typeName:i[1]}),n.push({id:i[2],typeName:i[3]})}}return n}async getRelationshipsBetweenNodes(e,t,i){const n=this._getNamedTypeIdMapFromNodeIds(e);if(0===n.size)return[];const r={relationshipExclusionIds:t,possibleConnectionEntityIds:e},s=[];for(const[e,t]of n.entries()){const i=`${e}_ids`;r[i]=t,s.push(`MATCH (n:${e}) WHERE id(n) IN $${i} WITH n MATCH (n)-[r]->(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const o=s.join(" UNION "),a=[],l=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new M.A({openCypherQuery:o,bindParameters:r}),{signal:i?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await l.read();if(e)break;for(let e=0;e<t.length;e++){const i=t[e];a.push({id:i[0],typeName:i[1]})}}return a}async getRelationshipsFromNodes(e,t,i,n){const r=this._getNamedTypeIdMapFromNodeIds(e);if(0===r.size||0===t.length)return[];const s={relationshipExclusionIds:i,possibleConnectionEntityIds:t},o=[];for(const[e,t]of r.entries()){const i=`${e}_ids`;s[i]=t,o.push(`MATCH (n:${e}) WHERE id(n) IN $${i} 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,p=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,new M.A({openCypherQuery:a,bindParameters:s}),{signal:n?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await p.read();if(e)break;for(let e=0;e<t.length;e++){const i=t[e];let n=l.get(i[1]);n||(n=new Set,l.set(i[1],n)),n.add(i[0])}}const d=[];for(const[e,t]of l)for(const i of t)d.push({id:i,typeName:e});return d}async refreshCacheContent(e,t,i,n=!0,r){const o=b.A.getInstance(),p=[],d=new Map,u=new Map;this.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&u.set(e.name,e)}),this.knowledgeGraph.dataModel.relationshipTypes?.forEach(e=>{e.name&&u.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((p,c)=>{(async()=>{const p=new Set,c=[];let h,y="",m=!1;if(t||u.get(e)?.properties?.forEach(e=>{e.name&&p.add(e.name)}),i&&this.geographicLookup.has(e)){const t=this.geographicLookup.get(e)?.name;t&&p.add(t)}if(this.entityTypeNames.has(e))y=`MATCH (n:${e}) ${l?"WHERE id(n) IN $ids ":""}return ID(n)`,p.forEach(e=>{y+=`, n.${e}`,c.push(e)});else{if(!this.relationshipTypeNames.has(e))throw new s.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?`);m=!0,y=`MATCH ()-[n:${e}]->() ${l?"WHERE id(n) IN $ids ":""}return ID(n), id(startNode(n)), id(endNode(n))`,p.forEach(e=>{y+=`, n.${e}`,c.push(e)})}h=new M.A(l?{openCypherQuery:y,bindParameters:{ids:l}}:{openCypherQuery:y});const g=(await(0,_.executeQueryStreaming)(this.knowledgeGraph,h,{signal:r?.signal})).resultRowsStream.getReader();for(;;){const{done:t,value:i}=await g.read();if(t)break;const r=[];for(let e=0;e<i.length;e++){const t=i[e];let n=0,s=0;const o={properties:{}};for(o.id=t[n],n++,s++,m&&(o.originId=t[n],n++,s++,o.destinationId=t[n],n++,s++,(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-s]]=t[n];d.delete(o.id),r.push(o)}const s=o.writeToStore(r,f.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);s.forEach(t=>{l?.set(t.attributes[f.dr],t),n&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.has(t.attributes[f.dr])&&(this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.set(t.attributes[f.dr],{id:t.attributes[f.dr]}),(0,a.tE)(this.memberIdTypeLookup,t.attributes[f.dr],()=>new Set).add(e))})}const b=this.inclusionModeDefinition?.namedTypeDefinitions.get(e);if(b)for(const e of d)b.members?.delete(e)})().then(()=>{p(null)}).catch(e=>{"AbortError"===e.name?p(null):c(e)})});p.push(c),this._processingCacheUpdatesLookup.get(e)?.push(c)}if(await Promise.all(p),r?.signal?.aborted)throw(0,l.NK)()}removeFromLayer(e){const t=new Set,i=new Set(e.map(e=>e.id));for(const i of e)t.add(i.typeName),1===this.memberIdTypeLookup.get(i.id)?.size?this.memberIdTypeLookup.delete(i.id):this.memberIdTypeLookup.get(i.id)?.delete(i.typeName),this.inclusionModeDefinition?.namedTypeDefinitions.forEach((e,t)=>{t===i.typeName&&e.members?.has(i.id)&&e.members.delete(i.id)});t.forEach(e=>{this.sublayerCaches.get(e)?.forEach((t,n)=>{i.has(n)&&this.sublayerCaches.get(e)?.delete(n)})})}async retrieveDataFromService(e,t,i){const n=b.A.getInstance(),r=new Set,o=[];let a,l="",d=[];const u="relationship"===t.graphType,I=this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData,T=t.parentCompositeLayer.sublayerIdsCache.get(t.objectType.name);let C=!I&&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&&(C=e.objectIds);else if(null!=e.objectIds&&C&&C.length>0){const t=e.objectIds;e.objectIds=C.filter(e=>t.includes(e))}else if(null!=e.objectIds)C=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=C}if(null!=e.outFields){const i=e.outFields;i.includes("*")?t.fields.forEach(e=>{r.add(e.name)}):i.forEach(e=>{e!==f.dr&&e!==t.geometryFieldName&&r.add(e)})}if(null!=e.geometry){const i=e.geometry;let n;const d=t.parentCompositeLayer.dataManager.knowledgeGraph.serviceDefinition,f=d?.spatialReference,g=d?.serviceCapabilities?.geometryCapabilities;let b=g?.geometryMaxBoundingRectangleSizeX,_=g?.geometryMaxBoundingRectangleSizeY;if("point"===i.type){let e=i;e.spatialReference?.isWGS84||(await(0,y.initializeProjection)(e.spatialReference,m.KK),e=(0,y.project)(e,m.KK)),n=new c.A({spatialReference:m.KK,xmin:e.x-1e-4,ymin:e.y-1e-4,xmax:e.x+1e-4,ymax:e.y+1e-4})}else i?.extent?.spatialReference&&!i.spatialReference?.isWGS84?(await(0,y.initializeProjection)(i.extent.spatialReference,m.KK),n=(0,y.project)(i.extent,m.KK)):n=i.extent;if(b&&_&&f){if(4326!==f.wkid){const e=new c.A({spatialReference:f,xmax:b,ymax:_}),t=(0,y.project)(e,m.KK);b=t.xmax,_=t.ymax}if(n.xmax-n.xmin>b)throw new s.A("knowledge-graph:layer-data-manager",`Extent x bounds should be within ${b}° latitude, limit exceeded`);if(n.ymax-n.ymin>_)throw new s.A("knowledge-graph:layer-data-manager",`Extent y bounds should be within ${_}° longitude, limit exceeded`)}if(null!=e.where&&"1=1"!==e.where){const i=await(0,p.GP)(e.where.toUpperCase(),t.fieldsIndex);t.fields.forEach(e=>{i.fieldNames.includes(e.name)&&r.add(e.name)})}l=u?`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&&r.add(t.geometryFieldName),r.forEach(e=>{l+=`, n.${e}`,o.push(e)}),a=new M.A({openCypherQuery:l,bindParameters:{param_filter_geom:new h.A({rings:(0,w.Wq)(n)})}})}else{let i="";if(null!=e.where&&"1=1"!==e.where){const n=await(0,p.GP)(e.where,t.fieldsIndex);t.fields.forEach(e=>{n.fieldNames.includes(e.name)&&r.add(e.name)});const s={systemOidFieldName:f.dr,supportedSqlTypes:new Set(["column-reference","string","number","binary-expression"]),supportedSqlOperators:new Set(["=","<","<=","<>",">",">=","AND","OR","LIKE"]),unsupportedOperationFound:!1};i=g(n.parseTree,s),s.unsupportedOperationFound&&(i="")}let n="";n=u?`Match ()-[n:${t.objectType.name}]->()`:`Match (n:${t.objectType.name})`;let s=!1;C&&(s=!0,n+=" WHERE ID(n) IN $ids"),i&&(n+=s?" AND":" WHERE",n+=` ${i}`),n+=" return ID(n)",u&&(n+=", id(startNode(n)), id(endNode(n))"),e.returnGeometry&&t.geometryFieldName&&r.add(t.geometryFieldName),r.forEach(e=>{n+=`, n.${e}`,o.push(e)}),a=new M.A(C?{openCypherQuery:n,bindParameters:{ids:C}}:{openCypherQuery:n})}const v=(await(0,_.executeQueryStreaming)(t.parentCompositeLayer.dataManager.knowledgeGraph,a,i)).resultRowsStream.getReader();for(;;){const{done:e,value:i}=await v.read();if(e)break;const r=[];for(let e=0;e<i.length;e++){const t=i[e];let n=0,s=0;const a={properties:{}};for(a.id=t[n],n++,s++,u&&(a.originId=t[n],n++,s++,a.destinationId=t[n],n++,s++);n<t.length;n++)a.properties[o[n-s]]=t[n];r.push(a)}d=d.concat(n.writeToStore(r,f.dr,t.parentCompositeLayer.dataManager.geographicLookup.get(t.objectType.name)?.name))}return d}_isEndEntitySpatial(e,t,i){for(const n of e??[])if(this.entityTypeNames.has(n)){const e=this.geographicLookup.get(n),r=e&&this.sublayerCaches.get(n)?.get(t.attributes[i]);if(e&&r?.attributes[e.name])return!0}return!1}_getNamedTypeIdMapFromNodeIds(e){const t=new Map;return e.forEach(e=>{if(this.memberIdTypeLookup.has(e))for(const i of this.memberIdTypeLookup.get(e)){if(!this.entityTypeNames.has(i))return;t.has(i)?t.get(i)?.push(e):t.set(i,[e])}}),t}};(0,n.Cg)([(0,d.MZ)()],T.prototype,"knowledgeGraph",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"inclusionModeDefinition",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"entityTypeNames",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"relationshipTypeNames",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"geographicLookup",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"sublayerCaches",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"nodeConnectionsLookup",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"relationshipConnectionsLookup",void 0),(0,n.Cg)([(0,d.MZ)()],T.prototype,"memberIdTypeLookup",void 0),T=(0,n.Cg)([(0,u.$)("esri.layers.knowledgeGraph.KnowledgeGraphLayerDataManager")],T)},25927:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(64108)),o=i(86738),a=i(54238);let l=class extends a.A{constructor(e){super(e),this.layoutGeometry=null}};(0,n.Cg)([(0,r.MZ)({type:o.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.Entity")],l)},30504:(e,t,i)=>{i.d(t,{k5:()=>p,aq:()=>l,Wq:()=>d}),i(52106);var n=i(49186),r=(i(86738),i(39829),i(82799),i(94194),i(69860),i(8460),i(66552));(0,r.O)()({none:"none",startAndEnd:"start-and-end",startOnly:"start-only"}),(0,r.O)()({absoluteValue:"absolute-value",multiplier:"multiplier"});const s=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=i(62568),a=i(42538);async function l(e,t,i){const n=[],r=function(e,t){const i=new Map;if(t.dataModel?.relationshipTypes)for(const e of t.dataModel.relationshipTypes)e.name&&i.set(e.name,[]);for(const t of e)i.has(t.typeName)&&i.get(t.typeName)?.push(t.id);return i}(e,t),s={},l=[];for(const[e,t]of r){if(t.length<1)continue;const i=`${e}_ids`;s[i]=t,l.push(`MATCH (n)-[r:${e}]->(m) WHERE id(r) in $${i} RETURN id(n), labels(n)[0], id(m), labels(m)[0]`)}if(0===l.length)return[];const p=l.join(" UNION "),d=new a.A({openCypherQuery:p,bindParameters:s}),u=(await(0,o.executeQueryStreaming)(t,d,i?.requestOptions)).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await u.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}i(40863),i(94985),i(68249);const p=e=>s.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]])}},37531:(e,t,i)=>{i.d(t,{dt:()=>c,GG:()=>g,UQ:()=>f,Sx:()=>d});var n=i(68197),r=i(60999),s=(i(44208),i(51850)),o=(i(76369),i(62046)),a=(i(2741),i(78888),i(66344));new Map([["dash",[4,3]],["dashdot",[4,3,1,3]],["dot",[1,3]],["longdash",[8,3]],["longdashdot",[8,3,1,3]],["longdashdotdot",[8,3,1,3,1,3]],["shortdash",[4,1]],["shortdashdot",[4,1,1,1]],["shortdashdotdot",[4,1,1,1,1,1]],["shortdot",[1,1]],["solid",[]]]),new a.q(1e3),new n.A([128,128,128]);var l=i(28975),p=i(33910);function d(e,t){if(!e)return null;let i=null;return(0,p.wk)(e)?i=function(e){const t=e.symbolLayers;if(!t)return null;let i=null;return t.forEach(e=>{"object"===e.type&&e.resource?.href||(i="water"===e.type?e.color:e.material?e.material.color:null)}),i?new n.A(i):null}(e):(0,p.$y)(e)&&(i="cim"===e.type?(0,o.Nk)(e):e.color?new n.A(e.color):null),i?u(i,t):null}function u(e,t){if(null==t||null==e)return e;const i=e.toRgba();return i[3]=i[3]*t,new n.A(i)}function c(e,t,i){e&&(t||null!=i)&&(t&&(t=new n.A(t)),(0,p.wk)(e)?function(e,t,i){const r=e.symbolLayers;if(!r)return;const s=(e,r=!1)=>{let s=t??e??null;return null!=i?.override&&(!s&&r&&(s=new n.A([255,255,255])),s&&(s.a=i.override)),u(s,i?.add)};r.forEach(e=>{if("water"===e.type)return void(e.color=u(e.color,i?.add));const t=null!=e.material?e.material.color:null,n=s(t,"icon"===e.type&&null!=e.resource?.href);null==e.material?e.material=new l.N({color:n}):e.material.color=n,"outline"in e&&e.outline?.color&&null!=i?.add&&(e.outline.color=u(e.outline.color,i.add)),"marker"in e&&null!=e.marker&&(e.marker.color=s(e.marker.color))})}(e,t,i):(0,p.$y)(e)&&function(e,t,i){t=t??e.color,null!=i?.override&&t&&(t.a=i.override),t&&(e.color=u(t,i?.add)),"outline"in e&&e.outline?.color&&(e.outline.color=u(e.outline.color,i?.add))}(e,t,i))}function h(e){for(const t of e)if("number"==typeof t)return t;return null}function y(e,t,i){for(let n=0;n<3;n++){const r=e[n];switch(r){case"symbol-value":{const e=i[n];return null!=e?e/t[n]:1}case"proportional":break;default:if(r&&t[n])return r/t[n]}}return null}function m(e,t,i,n){switch(e){case"proportional":return i*n;case"symbol-value":return null!=t?t:i;default:return e}}async function f(e,t){if(e&&t)return(0,p.wk)(e)?async function(e,t){const n=e.symbolLayers;n&&await(0,r.jJ)(n,async e=>async function(e,t){switch(e.type){case"extrude":!function(e,t){const i=t[2];"number"==typeof i&&(e.size=i)}(e,t);break;case"icon":case"line":case"text":!function(e,t){const i=h(t);null!=i&&(e.size=i)}(e,t);break;case"path":!function(e,t){const i=y(t,s.Un,[e.width,void 0,e.height]);null!=i&&(e.width=m(t[0],e.width,1,i),e.height=m(t[2],e.height,1,i))}(e,t);break;case"object":await async function(e,t){const{resourceSize:n,symbolSize:r}=await async function(e){const{computeObjectLayerResourceSize:t}=await i.e(5404).then(i.bind(i,95404)),n=await t(e,10),{width:r,height:s,depth:o}=e,a=[r,o,s];let l=1;for(let e=0;e<3;e++){const t=a[e];if(null!=t){l=t/n[e];break}}for(let e=0;e<3;e++)null==a[e]&&(a[e]=n[e]*l);return{resourceSize:n,symbolSize:a}}(e),s=y(t,n,r);null!=s&&(e.width=m(t[0],r[0],n[0],s),e.depth=m(t[1],r[1],n[1],s),e.height=m(t[2],r[2],n[2],s))}(e,t)}}(e,t))}(e,t):void((0,p.$y)(e)&&function(e,t){const i=h(t);if(null!=i)switch(e.type){case"simple-marker":e.size=i;break;case"picture-marker":{const t=e.width/e.height;t>1?(e.width=i,e.height=i*t):(e.width=i*t,e.height=i);break}case"simple-line":e.width=i;break;case"text":e.font.size=i}}(e,t))}function g(e,t,i){if(e&&null!=t)if((0,p.wk)(e)){const n=e.symbolLayers;n&&n.forEach(e=>{if("object"===e.type)switch(i){case"tilt":e.tilt=(e.tilt??0)+t;break;case"roll":e.roll=(e.roll??0)+t;break;default:e.heading=(e.heading??0)+t}"icon"===e.type&&(e.angle+=t)})}else(0,p.$y)(e)&&("simple-marker"!==e.type&&"picture-marker"!==e.type&&"text"!==e.type||(e.angle+=t))}},37730:(e,t,i)=>{i.d(t,{T:()=>r});var n=i(43334);const r={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)}},40662:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(31635),r=(i(53966),i(44208),i(87811),i(49186),i(64108)),s=i(77901);let o=class extends s.A{constructor(e){super(e)}};o=(0,n.Cg)([(0,r.$)("esri.rest.knowledgeGraph.ObjectValue")],o)},40736:(e,t,i)=>{i.d(t,{Gz:()=>F,O9:()=>L,hZ:()=>k,UT:()=>x,MY:()=>A,Td:()=>v,iW:()=>E,e$:()=>S,qN:()=>I});var n=i(68197),r=i(91869),s=i(99352),o=i(15375),a=i(46499),l=i(73913),p=i(62568),d=i(25927),u=i(31635),c=i(69622),h=i(10107),y=(i(44208),i(53966),i(87811),i(64108));let m=class extends c.A{constructor(e){super(e),this.entityAdds=void 0,this.entityUpdates=void 0,this.entityDeletes=void 0,this.relationshipAdds=void 0,this.relationshipUpdates=void 0,this.relationshipDeletes=void 0,this.options=void 0}};(0,u.Cg)([(0,h.MZ)()],m.prototype,"entityAdds",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"entityUpdates",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"entityDeletes",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"relationshipAdds",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"relationshipUpdates",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"relationshipDeletes",void 0),(0,u.Cg)([(0,h.MZ)()],m.prototype,"options",void 0),m=(0,u.Cg)([(0,y.$)("esri.rest.knowledgeGraph.GraphApplyEdits")],m);var f=i(23150),g=i(54218),b=i(40863),w=i(68249);const _={initializeLayersFromClientData:async(e,t,i)=>{if(t||(t=[...e.layers,...e.tables].map(e=>e.graphTypeName)),0===t?.length)return;const n=new Map;for(const i of t)n.set(i,M(e,i));const r=await(0,p.fetchClientDataAtKeys)(e.dataManager.knowledgeGraph,Array.from(n.values()),{requestOptions:{signal:i?.signal}});for(const t of[...e.layers,...e.tables]){const i=t.objectType.name;if(null==i)continue;const n=r.get(M(e,i));if(n){const e=JSON.parse(n);null===e||"object"!=typeof e||e.hasOwnProperty("showLabels")||(e.showLabels=!1),t.read(e,{origin:"service"})}}}},M=(e,t)=>"knowledge-graph"===e.type?`${t}/Map`:`${t}/LinkChart/LinkChartSubLayer`;async function I(e,t,i){return _.initializeLayersFromClientData(e,t,i)}const T=["#4a0932","#b31515","#18382e","#a64f1b","#102432","#8c213f","#ed9310","#2c6954","#144d59","#ffc730","#75351e","#454f4b","#78b1c2","#191921","#8f8f82","#9be0c0","#dbb658","#87b051","#11495c","#c43541","#9c5596","#44498b","#ad9d63","#86afb3","#5c98ca","#b0bfa2","#73241f","#b86b53","#d9d78c","#3e756d","#f260a1","#a0d17d","#c27c30","#eb82eb","#ffdf3c","#ffb259","#ab52b3","#3cccb4","#0095ba","#d92b30"],C="#8f8f82";function v(e){return e<0||e>=T.length?new n.A(C):new n.A(T[e])}function x(e){const t=e.toArray();return new b.A({data:{type:"CIMSymbolReference",symbol:{type:"CIMLineSymbol",symbolLayers:[{type:"CIMSolidStroke",enable:!0,style:"solid",width:.75,color:t},{type:"CIMVectorMarker",enable:!0,size:6,markerPlacement:{type:"CIMMarkerPlacementOnLine",angleToLine:!0,relativeTo:"LineMiddle"},frame:{xmin:-10,ymin:-5,xmax:0,ymax:5},markerGraphics:[{type:"CIMMarkerGraphic",geometry:{rings:[[[-12,-3.47],[-12,3.6],[1.96,-.03],[-12,-3.47]]]},symbol:{type:"CIMPolygonSymbol",symbolLayers:[{type:"CIMSolidFill",enable:!0,color:t}]}}]}]}}})}function A(e){let t="ESRI__ID",i=4;for(const n of e)if(n.name){if("name"===n.name.toLowerCase()){t=n.name;break}n.name.toLowerCase().includes("name")?(t=n.name,i=2):"esriFieldTypeString"===n.fieldType&&i>3&&(t=n.name,i=3)}return t}function E(e,t,i){const n={color:[80,80,80],haloColor:[255,255,255],haloSize:.7,font:{size:10,weight:"normal"}},r=new a.A({labelExpressionInfo:new l.A({expression:"ESRI__ID"===i?`${t}`:`$feature.${i}`}),labelPlacement:"above-center",symbol:new w.A(n)}),s=new a.A({labelExpressionInfo:new l.A({expression:`'${t}' + IIf($feature.ESRI__AggregationCount>1, ' (' + $feature.ESRI__AggregationCount + ')', '')`}),labelPlacement:"center-along",labelPosition:"parallel",repeatLabel:!1,symbol:new w.A({...n,yoffset:"12px"})});return"entity"===e?[r]:[s]}function S(e,t,i){const n={color:[255,255,255],haloColor:[0,0,0],haloSize:.7,font:{size:10,weight:"bold"}},r="ESRI__ID"===i?`${e}`:`$feature.${i}`;return"point"===t?[new a.A({labelExpressionInfo:new l.A({expression:r}),labelPlacement:"above-center",symbol:new w.A(n)})]:"polyline"===t?[new a.A({labelExpressionInfo:new l.A({expression:r}),labelPlacement:"center-along",repeatLabel:!0,symbol:new w.A(n)})]:"polygon"===t?[new a.A({labelExpressionInfo:new l.A({expression:r}),labelPlacement:"always-horizontal",symbol:new w.A(n)})]:null}const N={capabilities:[],allowGeometryUpdates:!1,serviceCapabilities:{geometryCapabilities:{supportsZValues:!1,supportsMValues:!1}}};function k(e){const{capabilities:t,allowGeometryUpdates:i,serviceCapabilities:{geometryCapabilities:{supportsZValues:n,supportsMValues:r}}}=e?.serviceDefinition||N,o=e?.dataModel.arcgisManaged?t:t.filter(e=>"Query"===e),a=new Set(o);return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:r,supportsZ:n},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:a.has("Create"),supportsDelete:a.has("Delete"),supportsEditing:a.has("Editing"),supportsChangeTracking:!1,supportsQuery:a.has("Query"),supportsQueryBins:!1,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:a.has("Update"),supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,editing:{supportsGeometryUpdate:!!e?.dataModel.arcgisManaged&&i,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:a.has("Delete"),supportsUpdateByAnonymous:!1,supportsUpdateByOthers:a.has("Update"),supportsAsyncApplyEdits:!1,zDefault:void 0}}}function L(e,t){const i=new m,n=t.graphTypeName,s=t.graphType,a=e=>{const i={...e};for(const e of t.fields)e.editable||delete i[e.name];for(const t of Object.keys(e))t.includes("ESRI__")&&delete i[t];return i};for(const t of e.addFeatures??[]){const e=a(t.attributes);t.sourceLayer.graphTypeName===n&&("entity"===s?(i.entityAdds||(i.entityAdds=[]),i.entityAdds.push(new d.A({properties:e,typeName:n}))):(i.relationshipAdds||(i.relationshipAdds=[]),i.relationshipAdds.push(new f.A({properties:e,typeName:n}))))}for(const t of e.updateFeatures??[]){const e=t.attributes[o.dr],r=a(t.attributes);t.sourceLayer.graphTypeName===n&&("entity"===s?(i.entityUpdates||(i.entityUpdates=[]),i.entityUpdates.push(new d.A({id:e,properties:r,typeName:n}))):(i.relationshipUpdates||(i.relationshipUpdates=[]),i.relationshipUpdates.push(new f.A({id:e,properties:r,typeName:n}))))}const l=new Map;for(const t of e.deleteFeatures??[])if((0,g.DU)(t)){const e=t,i=(0,r.tE)(l,e.sourceLayer.graphTypeName,()=>({typeName:e.sourceLayer.graphTypeName,ids:[]}));e.sourceLayer.graphTypeName===n&&i.ids.push(e.attributes[o.dr])}else t.objectId&&"string"==typeof t.objectId&&(0,r.tE)(l,n,()=>({typeName:n,ids:[]})).ids.push(t.objectId);for(const e of l.values())e.ids.length>0&&("entity"===s?(i.entityDeletes||(i.entityDeletes=[]),i.entityDeletes.push({typeName:e.typeName,ids:e.ids})):(i.relationshipDeletes||(i.relationshipDeletes=[]),i.relationshipDeletes.push({typeName:e.typeName,ids:e.ids})));return i}function F(e,t){const i={addFeatureResults:[],updateFeatureResults:[],deleteFeatureResults:[],addAttachmentResults:[],updateAttachmentResults:[],deleteAttachmentResults:[]};for(const n of e.editResults)if(n.typeName===t){for(const e of n.adds)i.addFeatureResults.push({objectId:e.id,globalId:e.id});for(const e of n.updates)i.updateFeatureResults.push({objectId:e.id,globalId:e.id});for(const e of n.deletes)i.deleteFeatureResults.push({objectId:e.id,globalId:e.id})}return i}},42095:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(31635),r=i(25482),s=i(10107),o=(i(44208),i(53966),i(87811),i(64108)),a=i(77901);let l=class extends r.o{constructor(e){super(e),this.path=[]}};(0,n.Cg)([(0,s.MZ)({type:[a.A],json:{write:!0}})],l.prototype,"path",void 0),l=(0,n.Cg)([(0,o.$)("esri.rest.knowledgeGraph.Path")],l)},42538:(e,t,i)=>{i.d(t,{A:()=>p});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(64108)),o=i(16930),a=i(69622);let l=class extends a.A{constructor(e){super(e),this.openCypherQuery=""}};(0,n.Cg)([(0,r.MZ)()],l.prototype,"openCypherQuery",void 0),l=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.GraphQuery")],l);let p=class extends l{constructor(e){super(e),this.bindParameters=null,this.bindGeometryQuantizationParameters=null,this.outputQuantizationParameters=null,this.outputSpatialReference=null,this.provenanceBehavior=null}};(0,n.Cg)([(0,r.MZ)()],p.prototype,"bindParameters",void 0),(0,n.Cg)([(0,r.MZ)()],p.prototype,"bindGeometryQuantizationParameters",void 0),(0,n.Cg)([(0,r.MZ)()],p.prototype,"outputQuantizationParameters",void 0),(0,n.Cg)([(0,r.MZ)({type:o.A})],p.prototype,"outputSpatialReference",void 0),(0,n.Cg)([(0,r.MZ)()],p.prototype,"provenanceBehavior",void 0),p=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.GraphQueryStreaming")],p)},54238:(e,t,i)=>{i.d(t,{A:()=>a});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(64108)),o=i(77901);let a=class extends o.A{constructor(e){super(e),this.typeName=null,this.id=null}};(0,n.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],a.prototype,"typeName",void 0),(0,n.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],a.prototype,"id",void 0),a=(0,n.Cg)([(0,s.$)("esri.rest.knowledgeGraph.GraphNamedObject")],a)},62046:(e,t,i)=>{i.d(t,{Fe:()=>d,Nk:()=>s});var n=i(68197),r=i(93397);function s(e){const t=[];return o((0,r.lW)(e),t),t.length?new n.A((0,r.e6)(t[0])):null}function o(e,t){if(!e)return;let i;i="CIMTextSymbol"===e.type?e.symbol:e;const n="CIMPolygonSymbol"===e.type;if(i?.symbolLayers)for(const e of i.symbolLayers)if(!(e.colorLocked||n&&((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))))switch(e.type){case"CIMPictureMarker":case"CIMPictureStroke":case"CIMPictureFill":e.tintColor&&a(t,e.tintColor);break;case"CIMVectorMarker":e.markerGraphics?.forEach(e=>{o(e.symbol,t)});break;case"CIMSolidStroke":case"CIMSolidFill":a(t,e.color);break;case"CIMGradientFill":l(t,e);break;case"CIMHatchFill":o(e.lineSymbol,t)}}function a(e,t){for(const i of e)if(i.join(".")===t.join("."))return;e.push(t)}function l(e,t){const i=t.colorRamp?.type;switch(i){case"CIMMultipartColorRamp":t.colorRamp.colorRamps?.forEach(t=>{"CIMLinearContinuousColorRamp"===t.type&&p(e,t)});break;case"CIMLinearContinuousColorRamp":case"CIMPolarContinuousColorRamp":p(e,t.colorRamp)}}function p(e,t){t&&(t.fromColor&&a(e,t.fromColor),t.toColor&&a(e,t.toColor))}function d(e,t,i){t instanceof n.A||(t=new n.A(t));const s=(0,r.lW)(e);s&&u(s,t,i)}function u(e,t,i){if(!e)return;let n;n="CIMTextSymbol"===e.type?e.symbol:e;const s="CIMPolygonSymbol"===n?.type;if(n?.symbolLayers)for(const e of n.symbolLayers){if(e.colorLocked)continue;if(s)if(i){const{layersToColor:t}=i;if(((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))&&"fill"===t||(0,r.jn)(e)&&"outline"===t)continue}else if((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))continue;const n=t.toArray();switch(e.type){case"CIMPictureMarker":case"CIMPictureStroke":case"CIMPictureFill":e.tintColor=n;break;case"CIMVectorMarker":e.markerGraphics?.forEach(e=>{u(e.symbol,t,i)});break;case"CIMSolidStroke":case"CIMSolidFill":e.color=n;break;case"CIMGradientFill":c(e,t);break;case"CIMHatchFill":u(e.lineSymbol,t,i)}}}function c(e,t){const i=e.colorRamp?.type;switch(i){case"CIMMultipartColorRamp":e.colorRamp.colorRamps?.forEach(e=>{"CIMLinearContinuousColorRamp"===e.type&&h(e,t)});break;case"CIMLinearContinuousColorRamp":case"CIMPolarContinuousColorRamp":h(e.colorRamp,t)}}function h(e,t){if(e&&(e.fromColor&&(e.fromColor=t.toArray()),e.toColor)){const i=t.clone();i.a=0,e.toColor=i.toArray()}}},62796:(e,t,i)=>{i.d(t,{A:()=>he});var n=i(31635),r=i(37838),s=i(49186),o=i(4718),a=i(53966),l=i(25728),p=(i(29953),i(10107)),d=(i(44208),i(64108)),u=i(43937),c=i(5443),h=i(86738),y=i(39829),m=i(82799),f=i(91218),g=i(16930),b=i(21325),w=i(50498),_=i(55156),M=i(60950),I=i(89808),T=i(99959);const C=Symbol("isKnowledgeGraphGraphicOriginSymbol");var v;class x extends T.A{get[(v=C,M.ym)](){return this.sublayer}get[_.e](){return this.sublayer}get[I.Q](){return this.sublayer}constructor(e,t){super(),this[v]=!0,this.type="knowledge-graph",this.layer=e,this.sublayer=t}get id(){return this.layer.id}}const A=Symbol("isLinkChartGraphicOriginSymbol");var E;class S extends T.A{get[(E=A,I.Q)](){return this.layer}constructor(e,t){super(),this[E]=!0,this.type="link-chart",this.layer=e,this.sublayer=t}get id(){return`${this.layer.id}:__${this.sublayer.id}__`}}var N=i(4146),k=i(83221),L=i(56390),F=i(64714),D=i(15375);i(87811);const R=(0,i(17036).p)(),j=e=>{const t=e;let i=class extends t{constructor(){super(...arguments),this.fields=[],this.fieldsIndex=null}};return(0,n.Cg)([(0,p.MZ)(R.fields)],i.prototype,"fields",void 0),(0,n.Cg)([(0,p.MZ)(R.fieldsIndex)],i.prototype,"fieldsIndex",void 0),i=(0,n.Cg)([(0,d.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayerBase")],i),i};var O=i(40736),B=i(63074),Z=i(6455),$=i(87718),P=i(56658),G=i(32756),U=i(54310),q=i(25036),z=i(82935),Q=i(10873),Y=i(13213),H=i(20437),W=i(30524),V=i(46499),X=i(39383),J=i(96184),K=i(96576),ee=i(65494),te=i(41214),ie=i(62568),ne=i(22671),re=i(61956),se=i(30291),oe=i(37531),ae=i(61322);function le(e){if(!e.json)return e;e.json.write=pe(e.json.write);const t=e.json.origins;if(!t)return e;let i;for(i in t){const e=t[i];e&&(e.write=pe(e.write))}return e}function pe(e){return"object"==typeof e&&e?(!1!==e.enabled&&(e.overridePolicy=function(e){const{target:t,writer:i,overridePolicy:n,...r}=e;return function(e,t){const i=ue.call(this,e,t);return i.enabled?{...r,...i}:i}}(e)),e):!0===e?de():e}function de(){return{overridePolicy:ue}}function ue(e,t){const i=!!this.geometryType;let n={enabled:i};return i&&(n={...n,...ce.call(this,e,t)}),n}function ce(e,t){return{ignoreOrigin:this.originIdOf(t)>0}}let he=class extends(j((0,Z.FJ)((0,P.J)((0,$.F)((0,B.dM)((0,G.fY)((0,z.e)((0,q.j)((0,U.J)((0,l.P)(N.A))))))))))){constructor(e){super(e),this.blendMode="normal",this.charts=null,this.definitionExpression=null,this.displayFilterEnabled=!0,this.displayFilterInfo=null,this.effect=null,this.elevationInfo=null,this.featureEffect=null,this.graphType=null,this.labelsVisible=!0,this.layerType=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.objectIdField=D.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 ae.default(e.port1,{channel:e,client:{queryFeatures:(e,t={})=>{const i=re.A.fromJSON(e);return this.queryFeaturesJSON(i,t)}}}),[e.port2]})},this.type="knowledge-graph-sublayer",this.useViewTime=!0,this.visible=!0}get capabilities(){return this.parent?this.parent.sublayerCapabilities:(0,O.hZ)(null)}get userHasUpdateItemPrivileges(){return!!this.parent?.userHasUpdateItemPrivileges}get editingEnabled(){return this._isOverridden("editingEnabled")?this._get("editingEnabled"):this.capabilities.operations.supportsEditing}set editingEnabled(e){this._overrideIfSome("editingEnabled",e)}get isTable(){return"link-chart"!==this.parentCompositeLayer.type&&null==this.geometryFieldName}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 i="esriFieldTypeOID"===t.fieldType?"esriFieldTypeInteger":t.fieldType;e.push(H.A.fromJSON({name:t.name,type:i,alias:t.alias,defaultValue:t.defaultValue,editable:t.editable,nullable:t.nullable}))}),e.push(H.A.fromJSON({name:this.objectIdField,type:"esriFieldTypeString",alias:this.objectIdField,editable:!1}),H.A.fromJSON({name:D.M1,type:"esriFieldTypeInteger",alias:D.M1,editable:!1}),H.A.fromJSON({name:D.BL,type:"esriFieldTypeInteger",alias:D.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?w.gy.fromJSON(t):null}get geometryFieldName(){if("link-chart"===this.parentCompositeLayer?.type)return D.T1;const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name);return e?.name??null}get graphicOrigin(){if(!this.parent)return null;switch(this.parent.type){case"knowledge-graph":return new x(this.parent,this);case"link-chart":return new S(this.parent,this)}}get graphTypeName(){return this.objectType?.name}set graphTypeName(e){this._set("graphTypeName",e)}get hasM(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,i=t?this.objectType?.properties?.[t]:null;return i?.hasM??!1}get hasZ(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,i=t?this.objectType?.properties?.[t]:null;return i?.hasZ??!1}set labelingInfo(e){this._set("labelingInfo",e)}get labelingInfo(){if(this._isOverridden("labelingInfo"))return this._get("labelingInfo");if(!this.objectType||!this.parentCompositeLayer||!this.graphTypeName)return null;const e=this.objectType.properties?(0,O.MY)(this.objectType.properties):"ESRI__ID";return"link-chart"===this.parentCompositeLayer.type?(0,O.iW)(this.graphType,this.graphTypeName,e):(0,O.e$)(this.graphTypeName,this.geometryType,e)}set renderer(e){(0,W.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){if(this._isOverridden("renderer"))return this._get("renderer");const e=this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel,t=[...e?.entityTypes??[],...e?.relationshipTypes??[]].map(e=>e.name).indexOf(this.graphTypeName),i=(0,O.Td)(t);if("link-chart"===this.parentCompositeLayer?.type){if("relationship"===this.graphType)return new K.A({type:"simple",symbol:(0,O.UT)(i)});const e=(0,ee.r)((0,F.F0)(w.gy.toJSON("point")).renderer);return(0,oe.dt)(e.symbol,i),e}const n=(0,ee.r)((0,F.F0)(w.gy.toJSON(this.geometryType)).renderer);return(0,oe.dt)(n.symbol,i),n}get spatialReference(){return this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel?.spatialReference??g.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,se.tn)(this,e)}createQuery(){return new re.A({where:"1=1",outFields:["*"]})}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){return null}async queryFeatures(e,t){await this.load();const{resolvedQuery:i,queryEngine:n}=await this._setupQueryObjects(e),r=this.graphicOrigin,s=ne.A.fromJSON(await n.executeQuery(i.toJSON(),t?.signal));return s.features.forEach(e=>{e.sourceLayer=this,e.origin=r}),s}async queryFeaturesJSON(e,t){await this.load();const{resolvedQuery:i,queryEngine:n}=await this._setupQueryObjects(e);return await n.executeQuery(i.toJSON(),t?.signal)}async queryFeatureCount(e,t){await this.load();const{resolvedQuery:i,queryEngine:n}=await this._setupQueryObjects(e);return n.executeQueryForCount(i.toJSON(),t?.signal)}async queryExtent(e={},t){await this.load();const i={...e,returnGeometry:!0},{resolvedQuery:n,queryEngine:r}=await this._setupQueryObjects(i),s=await r.executeQueryForExtent(n.toJSON(),t?.signal);let o;return o=null!=s.extent?.xmin&&null!=s.extent?.xmax&&null!=s.extent?.ymin&&null!=s.extent?.ymax?new c.A(s.extent):new c.A,{count:s.count,extent:o}}async queryObjectIds(e,t){await this.load();const i=re.A.from(e);let n;if("link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)n=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(i,this,t);n=this.loadQueryEngine(e)}return await n.executeQueryForIds(i.toJSON(),t?.signal)}async applyEdits(e){if(!this.parentCompositeLayer.dataManager.knowledgeGraph)throw new s.A("knowledge-graph-sublayer:no-knowledge-graph","ApplyEdits cannot be executed because the parent does not have a Knowledge Graph model. This is usually caused by the layer not yet being loaded");const t=(0,O.O9)(e,this);t.options={cascadeDelete:!0,cascadeProvenanceDelete:!!this.parent?.knowledgeGraph.serviceDefinition.supportsProvenance||void 0};const i=await(0,ie.executeApplyEdits)(this.parentCompositeLayer.dataManager.knowledgeGraph,t),n=(0,O.Gz)(i,this.graphTypeName),r={addedFeatures:n.addFeatureResults,updatedFeatures:n.updateFeatureResults,deletedFeatures:n.deleteFeatureResults,addedAttachments:n.addAttachmentResults,deletedAttachments:n.deleteAttachmentResults,updatedAttachments:n.updateAttachmentResults,exceededTransferLimit:!1,historicMoment:new Date,edits:void 0};return this.emit("edits",r),this.emit("apply-edits",{result:Promise.resolve(r)}),n}loadQueryEngine(e){const t=new k.A({geometryType:w.gy.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ}),i=new L.do({fieldsIndex:this.fieldsIndex.toJSON(),geometryType:w.gy.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ,featureIdInfo:{type:"object-id",fieldName:this.objectIdField},spatialReference:this.spatialReference.toJSON(),timeInfo:this.timeInfo?.toJSON(),featureStore:t});return i.featureStore.addMany(e),i}async refreshCachedQueryEngine(){const e=await this.parentCompositeLayer.dataManager.getData(new re.A({where:"1=1",outFields:[D.dr]}),this);this._cachedQueryEngine=this.loadQueryEngine(e)}load(e){return this.addResolvingPromise(this.parent.load(e).then(()=>(0,W.sv)(this.timeInfo,this.fieldsIndex))),Promise.resolve(this)}async _setupQueryObjects(e,t){const i=re.A.from(e),n=i.geometry;if(n&&!n.spatialReference?.isWGS84&&(await(0,f.initializeProjection)(n.spatialReference,b.KK),i.geometry=(0,f.project)(n instanceof y.A||n instanceof m.A||n instanceof h.A?n:n.extent,b.KK)),"link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)return{resolvedQuery:i,queryEngine:this._cachedQueryEngine};const r=await this.parentCompositeLayer.dataManager.getData(i,this,t);return{resolvedQuery:i,queryEngine:this.loadQueryEngine(r)}}};(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(B.sU)))],he.prototype,"blendMode",void 0),(0,n.Cg)([(0,p.MZ)({readOnly:!0})],he.prototype,"capabilities",null),(0,n.Cg)([(0,p.MZ)({readOnly:!0})],he.prototype,"userHasUpdateItemPrivileges",null),(0,n.Cg)([(0,p.MZ)({type:Boolean})],he.prototype,"editingEnabled",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"isTable",null),(0,n.Cg)([(0,p.MZ)({json:{origins:{"web-scene":{write:!1}},write:de()}})],he.prototype,"charts",void 0),(0,n.Cg)([(0,p.MZ)({readOnly:!0})],he.prototype,"defaultPopupTemplate",null),(0,n.Cg)([(0,p.MZ)({type:String,json:{origins:{service:{read:!1}},name:"layerDefinition.definitionExpression",write:{ignoreOrigin:!0}}})],he.prototype,"definitionExpression",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Z.Dp)))],he.prototype,"displayFilterEnabled",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Z.KV)))],he.prototype,"displayFilterInfo",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(B.LF)))],he.prototype,"effect",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"elevationInfo",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)($.Y)))],he.prototype,"featureEffect",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Y.d)))],he.prototype,"featureReduction",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"fields",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"geometryType",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"geometryFieldName",null),(0,n.Cg)([(0,p.MZ)({readOnly:!0})],he.prototype,"graphicOrigin",null),(0,n.Cg)([(0,p.MZ)({type:["entity","relationship"],nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],he.prototype,"graphType",void 0),(0,n.Cg)([(0,p.MZ)({type:String,nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],he.prototype,"graphTypeName",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"hasM",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"hasZ",null),(0,n.Cg)([(0,p.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],he.prototype,"id",void 0),(0,n.Cg)([(0,p.MZ)({type:Boolean,value:!0,nonNullable:!0,json:{name:"showLabels",default:!1,write:{overridePolicy(){return{enabled:!!this.geometryType,alwaysWriteDefaults:!0,ignoreOrigin:!0}}}}})],he.prototype,"labelsVisible",void 0),(0,n.Cg)([(0,p.MZ)({type:[V.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:function(e,t,i){const n=[["ESRI__AGGREGATION_COUNT",D.M1],["ESRI__ORIGIN_ID",D.Cz],["ESRI__DESTINATION_ID",D.KQ],["ESRI__LAYOUT_GEOMETRY",D.T1]];try{for(const t of e)for(const[e,i]of n)t.labelExpression=t.labelExpression?.replaceAll(e,i),t.labelExpressionInfo?.expression&&(t.labelExpressionInfo.expression=t.labelExpressionInfo.expression.replaceAll(e,i))}catch(e){a.A.getLogger(this).warn("Error updating labelingInfo",e)}return(0,X.w)(e,t,i)},write:de()}})],he.prototype,"labelingInfo",null),(0,n.Cg)([(0,p.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}}})],he.prototype,"layerType",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.fV)))],he.prototype,"legendEnabled",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.hG)))],he.prototype,"maxScale",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.hn)))],he.prototype,"minScale",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"objectIdField",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"objectType",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.ke)))],he.prototype,"opacity",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(G.ne)))],he.prototype,"orderBy",void 0),(0,n.Cg)([(0,p.MZ)({clonable:!1})],he.prototype,"parent",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"parentCompositeLayer",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(Q.M6)))],he.prototype,"popupEnabled",void 0),(0,n.Cg)([(0,p.MZ)({type:r.A,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],he.prototype,"popupTemplate",void 0),(0,n.Cg)([(0,p.MZ)({type:Number,json:{write:{overridePolicy:ce}}})],he.prototype,"refreshInterval",void 0),(0,n.Cg)([(0,p.MZ)({types:te.Hg,json:{name:"layerDefinition.drawingInfo.renderer",write:de()}})],he.prototype,"renderer",null),(0,n.Cg)([(0,p.MZ)()],he.prototype,"source",void 0),(0,n.Cg)([(0,p.MZ)()],he.prototype,"spatialReference",null),(0,n.Cg)([(0,p.MZ)({type:J.A,json:{name:"layerDefinition.timeInfo",write:{overridePolicy:ce},origins:{"web-document":{name:"layerDefinition.timeInfo",read:!0,write:{overridePolicy:ce}},"portal-item":{name:"layerDefinition.timeInfo",read:!0,write:{overridePolicy:ce}}}}})],he.prototype,"timeInfo",null),(0,n.Cg)([(0,p.MZ)({type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],he.prototype,"title",null),(0,n.Cg)([(0,u.K)("title")],he.prototype,"writeTitle",null),(0,n.Cg)([(0,p.MZ)({json:{read:!1}})],he.prototype,"type",void 0),(0,n.Cg)([(0,p.MZ)(le((0,o.o8)(z.B)))],he.prototype,"useViewTime",void 0),(0,n.Cg)([(0,p.MZ)({type:Boolean,json:{name:"visibility",write:de()}})],he.prototype,"visible",void 0),he=(0,n.Cg)([(0,d.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayer")],he)},64714:(e,t,i)=>{i.d(t,{F0:()=>a,Vx:()=>d,e2:()=>c,f:()=>h});var n=i(44208),r=i(4718),s=i(99352),o=i(93470);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let p=1;function d(e,t){if((0,n.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let i=`this${u(t)} = null;`;for(const t in e)i+=`this${u(t)} = ${JSON.stringify(e[t])};`;const n=new Function(`\n return class AttributesClass$${p++} {\n constructor() {\n ${i};\n }\n }\n `)();return()=>new n}catch(i){return()=>({[t]:null,...e})}}function u(e){return l.test(e)?`.${e}`:`["${e}"]`}function c(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,r.o8)(e)}}]}function h(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:!0,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,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}}}},67996:(e,t,i)=>{i.d(t,{cZ:()=>S,XW:()=>F,fe:()=>N});var n=i(78888),r=i(49186),s=i(91869),o=(i(90708),i(92722)),a=i(16930);class l{constructor(){this.version="",this.queryResult=new p}}class p{constructor(){this.featureResult=new d}}class d{constructor(){this.objectIdFieldName="",this.uniqueIdField=new u,this.globalIdFieldName="",this.geohashFieldName="",this.geometryProperties=new c,this.geometryType=null,this.spatialReference=new a.A,this.exceededTransferLimit=!1,this.hasZ=!1,this.hasM=!1,this.transform=new h,this.fields=[],this.fieldNameToAttributeIndexMap={},this.values=[],this.features=[],this.geometryFields=[]}}class u{constructor(){this.name="",this.isSystemMaintained=!1}}class c{constructor(){this.shapeAreaFieldName="",this.shapeLengthFieldName="",this.units=""}}class h{constructor(){this.quantizeOriginPosition="upperLeft",this.scale=new y,this.translate=new m}}class y{constructor(){this.xScale=0,this.yScale=0,this.mScale=0,this.zScale=0}}class m{constructor(){this.xTranslate=0,this.yTranslate=0,this.mTranslate=0,this.zTranslate=0}}class f{constructor(){this.name="",this.fieldType="esriFieldTypeString",this.alias="",this.sqlType="sqlTypeVarchar",this.domain="",this.defaultValue=""}}class g{constructor(){this.attributes=[],this.compressedGeometry=new b,this.centroid=new b,this.aggregateGeometries=[]}}class b{constructor(){this.geometryType=null,this.lengths=[],this.coords=[]}}const w=["ELEMENTUID","TYPENAME"];var _=i(45724),M=i(35448);const I={upperLeft:0,lowerLeft:1},T={sqlTypeBigInt:0,sqlTypeBinary:1,sqlTypeBit:2,sqlTypeChar:3,sqlTypeDate:4,sqlTypeDecimal:5,sqlTypeDouble:6,sqlTypeFloat:7,sqlTypeGeometry:8,sqlTypeGUID:9,sqlTypeInteger:10,sqlTypeLongNVarchar:11,sqlTypeLongVarbinary:12,sqlTypeLongVarchar:13,sqlTypeNChar:14,sqlTypeNVarChar:15,sqlTypeOther:16,sqlTypeReal:17,sqlTypeSmallInt:18,sqlTypeSqlXml:19,sqlTypeTime:20,sqlTypeTimestamp:21,sqlTypeTimestamp2:22,sqlTypeTinyInt:23,sqlTypeVarbinary:24,sqlTypeVarchar:25};var C=i(93637);function v(e){const t=new b;t.geometryType=(0,C.i7)(M.bV,e.geometry_type.value);const i=[],n=[];for(let t=0;t<e.lengths.length;t++)i.push(e.lengths[t]);for(let t=0;t<e.coords.length;t++)n.push(e.coords[t]);return t.lengths=i,t.coords=n,t}function x(e){const t=new f;return t.name=e.name,t.alias=e.alias,t.fieldType=(0,C.i7)(M.r5,e.field_type.value),t.sqlType=(0,C.i7)(T,e.sql_type.value),t.domain=e.domain,t.defaultValue=e.default_value,t}function A(e){const t=x(e);return t.geometryType=(0,C.i7)(M.bV,e.geometry_type.value),t}function E(e){const t=new h;t.quantizeOriginPosition=(0,C.i7)(I,e.quantizeOriginPosition.value);const i=t.scale,n=e.scale;i.xScale=n.xScale,i.yScale=n.yScale,i.mScale=n.mScale,i.zScale=n.zScale;const r=t.translate,s=e.translate;return r.xTranslate=s.xTranslate,r.yTranslate=s.yTranslate,r.mTranslate=s.mTranslate,r.zTranslate=s.zTranslate,t}async function S(e,t){t??=!1;const i={generateAllSublayers:t,namedTypeDefinitions:new Map};return await async function(e){const t=await(0,n.A)(e,{responseType:"array-buffer"}),i=await t.data;return async function(e){const t=new((await(0,_.I)()).MapOfObjectIdentifierSetsDecoder),i=t.decode(new Uint8Array(e)),n=new Map;if(0!==i.error_code)throw new r.A("knowledge-graph:layer-support-utils",i.error_message);const s=t.get_map_of_identifier_sets(),o=s.keys,a=o.size();for(let e=0;e<a;e++){const t=o.get(e),i=s.query_identifier_set(t),a=[];if(1===i.id_array_type.value){const e=i.get_globalid_array(),t=e.count();for(let i=0;i<t;i++)a.push(e.get_globalid_at(i))}else if(3===i.id_array_type.value){const e=i.get_identifier_array(),t=e.count();for(let i=0;i<t;i++)a.push(e.get_identifier_at(i).toString())}else if(2===i.id_array_type.value){const e=i.get_string_array(),t=e.count();for(let i=0;i<t;i++)a.push(e.get_string_at(i))}else{if(0!==i.id_array_type.value)throw new r.A("knowledge-graph:layer-support-utils","Tried to encode an unexpected ID Array type.");{const e=i.get_oid_array(),t=e.count();for(let i=0;i<t;i++)a.push(e.get_objectid_at(i).toString())}}n.set(t,a)}return t.delete(),n}(new Uint8Array(i))}(e).then(e=>{!function(e,t){for(const[i,n]of e){const e=(0,s.tE)(t.namedTypeDefinitions,i,()=>({useAllData:!1,members:new Map}));for(const t of n)e.members.has(t)||e.members.set(t,{id:t})}}(e,i)}),i}async function N(e){const t=await(0,_.I)(),i=new t.MapOfObjectIdentifierSets;!function(e,t,i){for(const[n,r]of i.namedTypeDefinitions){if(!r.members||r.useAllData)continue;const i=r.members.keys();let s=!1,o=!0;const a=new t.ObjectIdArray,l=new t.StringArray,p=new t.GlobalIdArray,d=new t.IdentifierArray,u=new t.ObjectIdentifierSet;for(const e of i)o&&(s=!isNaN(Number(e)),o=!1),s?a.add_objectid(Number(e)):(l.add_string(e),p.add_globalid(e)),d.add_identifier(e);u.set_oid_array(a),u.set_string_array(l),u.set_globalid_array(p),u.set_identifier_array(d),a.delete(),l.delete(),p.delete(),d.delete(),e.put_identifier_set(n,u),u.delete()}}(i,t,e);const n=new t.MapOfObjectIdentifierSetsEncoder;try{n.set_map_of_identifier_sets(i),n.encode();const e=n.get_encoding_result();if(0!==e.error.error_code)throw new r.A("knowledge-graph:layer-support-utils",e.error.error_message);const t=structuredClone(e.get_byte_buffer());return n.delete(),t}finally{i.delete()}}async function k(e){const t=await(0,n.A)(e,{responseType:"array-buffer"});return async function(e){const t=new((await(0,_.I)()).FeatureCollectionDecoder),i=t.decode(new Uint8Array(e));if(0!==i.error_code)throw new r.A("knowledge-graph:layer-support-utils",i.error_message);const n=function(e){const t=new l;t.version=e.version;const i=e.get_query_result();if(0!==i.results_type.value)throw new Error("Got a non-feature collection type");const n=i.get_feature_result(),r=t.queryResult.featureResult;r.objectIdFieldName=n.objectid_field_name,r.exceededTransferLimit=n.exceeded_transfer_limit,r.hasM=n.has_m,r.hasZ=n.has_z,r.geometryType=(0,C.i7)(M.bV,n.geometry_type.value),r.globalIdFieldName=n.globalid_field_name,r.geohashFieldName=n.geohash_field_name;const s=r.uniqueIdField,o=n.unique_id_field;s.name=o.name,s.isSystemMaintained=o.isSystemMaintained;const a=r.geometryProperties,p=n.geometry_properties;a.shapeAreaFieldName=p.shapeAreaFieldName,a.shapeLengthFieldName=p.shapeLengthFieldName,a.units=p.units;const d=r.spatialReference,u=n.spatial_reference;d.wkid=u.wkid,d.latestWkid=u.latestWkid,d.vcsWkid=u.vcsWkid,d.latestVcsWkid=u.latestVcsWkid,d.wkt=u.wkt,r.transform=E(n.transform);const c=r.fields,h=r.fieldNameToAttributeIndexMap,y=n.fields,m=y.size();for(let e=0;e<m;e++){const t=y.get(e),i=x(t);c.push(i),h[i.name]=e,t.delete()}y.delete();const f=r.values,b=n.values_count();for(let e=0;e<b;e++)f.push(n.get_value_at(e));const _=r.features,I=n.features,T=I.size();if(T>0)for(const e of w)if(void 0===h[e])throw new Error(`Feature collection missing required attribute: ${e}`);for(let e=0;e<T;e++){const t=new g,i=I.get(e),n=t.attributes,r=i.attributes_count();for(let e=0;e<r;e++)n.push(i.get_attribute_at(e));const s=i.get_compressed_geometry();s&&(t.compressedGeometry=v(s),t.centroid=v(i.get_centroid()));const o=t.aggregateGeometries,a=i.aggregate_geometries,l=a.size();for(let e=0;e<l;e++){const t=a.get(e),i=v(t);o.push(i),t.delete()}a.delete(),_.push(t),i.delete()}I.delete();const S=r.geometryFields,N=n.geometry_fields,k=N.size();for(let e=0;e<k;e++){const t=N.get(e),i=A(t);S.push(i),t.delete()}return N.delete(),t}(t.get_feature_collection());return t.delete(),n}(await t.data)}function L(e,t){if(!e?.queryResult?.featureResult)return t;const{hasZ:i,hasM:n}=e.queryResult.featureResult,r=e.queryResult.featureResult.fieldNameToAttributeIndexMap;for(const a of e.queryResult.featureResult.features){const e=a.attributes[r.TYPENAME],l=(0,s.tE)(t.namedTypeDefinitions,e,()=>({useAllData:!1,members:new Map})),p=a.attributes[r.ELEMENTUID];if(a.compressedGeometry?.coords?.length>0){let e=a.compressedGeometry.lengths;"esriGeometryPoint"===a.compressedGeometry.geometryType&&(e=[]),l.members.set(p,{id:p,linkChartLocation:new o.A(e,a.compressedGeometry.coords,i,n)})}else l.members.set(p,{id:p})}return t}const F={fetchAndConvertSerializedLinkChart:e=>async function(e){const t=[],i={generateAllSublayers:!1,namedTypeDefinitions:new Map};return e.entitiesUrl&&t.push(k(e.entitiesUrl).then(e=>{L(e,i)})),e.relationshipsUrl&&t.push(k(e.relationshipsUrl).then(e=>{L(e,i)})),await Promise.all(t),i}(e)}},69860:(e,t,i)=>{i.d(t,{A:()=>a});var n=i(65864),r=i(90708),s=i(43334),o=i(15375);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 i=this.readFromStoreById(e);i&&t.push(i)}),t}readFromStoreById(e){return this._featureLookup.get(e)??null}writeToStore(e,t,i){const a=[];return e.forEach(e=>{if(!e?.id)return;e.properties||(e.properties=[]);let l,p=null;if(i&&e.properties[i]&&(p=(0,r.Ux)(e.properties[i])),"originId"in e&&"destinationId"in e&&(e.properties[o.Cz]=e.originId,e.properties[o.KQ]=e.destinationId),e.properties[t]=e.id,e.id&&this._featureLookup.has(e.id)&&this._featureLookup.get(e.id).attributes){const r=this._featureLookup.get(e.id),o=JSON.parse(JSON.stringify(Object.assign(r.attributes,e.properties)));i&&e.properties[i]&&(o[i]=(0,n.rS)(e.properties[i])),l=new s.Om(p?JSON.parse(JSON.stringify(p)):r?.geometry?JSON.parse(JSON.stringify(r.geometry)):null,o,null,e.properties[t])}else l=new s.Om(p?JSON.parse(JSON.stringify(p)):null,e.properties,null,e.properties[t]);this._featureLookup.set(`${e.typeName?`${e.typeName}__${e.id}`:e.id}`,l),a.push(l)}),a}}},73133:(e,t,i)=>{i.d(t,{j:()=>n});const n=(0,i(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})},75503:(e,t,i)=>{i.d(t,{EC:()=>v,wq:()=>a});var n=i(4576),r=i(21818),s=(i(44208),i(15142)),o=i(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(),M.prune(),I.prune(),T.prune(),C.prune()}all(e){l(this._data,e)}search(e,t){let i=this._data;const n=this._toBBox;if(w(e,i))for(M.clear();i;){for(let r=0,s=i.children.length;r<s;r++){const s=i.children[r],o=i.leaf?n(s):s;w(e,o)&&(i.leaf?t(s):b(e,o)?l(s,t):M.push(s))}i=M.pop()}}collides(e){let t=this._data;const i=this._toBBox;if(!w(e,t))return!1;for(M.clear();t;){for(let n=0,r=t.children.length;n<r;n++){const r=t.children[n],s=t.leaf?i(r):r;if(w(e,s)){if(t.leaf||b(e,s))return!0;M.push(r)}}t=M.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,i=e.length;t<i;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 A([]),this}remove(e){if(!e)return this;let t,i=this._data,s=null,o=0,a=!1;const l=this._toBBox(e);for(T.clear(),C.clear();i||T.length>0;){if(i||(i=T.pop(),s=T.data[T.length-1],o=C.pop()??0,a=!0),i.leaf&&(t=(0,n.qh)(i.children,(0,r.zI)(e),i.children.length,i.indexHint),-1!==t))return i.children.splice(t,1),T.push(i),this._condense(T),this;a||i.leaf||!b(i,l)?s?(o++,i=s.children[o],a=!1):i=null:(T.push(i),C.push(o),o=0,s=i,i=i.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,i,n){const r=i-t+1;let s=this._maxEntries;if(r<=s){const n=new A(e.slice(t,i+1));return p(n,this._toBBox),n}n||(n=Math.ceil(Math.log(r)/Math.log(s)),s=Math.ceil(r/s**(n-1)));const o=new E([]);o.height=n;const a=Math.ceil(r/s),l=a*Math.ceil(Math.sqrt(s));_(e,t,i,l,this._compareMinX);for(let r=t;r<=i;r+=l){const t=Math.min(r+l-1,i);_(e,r,t,a,this._compareMinY);for(let i=r;i<=t;i+=a){const r=Math.min(i+a-1,t);o.children.push(this._build(e,i,r,n-1))}}return p(o,this._toBBox),o}_insert(e,t,i){const n=this._toBBox,r=i?e:n(e);T.clear();const s=function(e,t,i,n){for(;n.push(t),!0!==t.leaf&&n.length-1!==i;){let i,n=1/0,r=1/0;for(let s=0,o=t.children.length;s<o;s++){const o=t.children[s],a=y(o),l=f(e,o)-a;l<r?(r=l,n=a<n?a:n,i=o):l===r&&a<n&&(n=a,i=o)}t=i||t.children[0]}return t}(r,this._data,t,T);for(s.children.push(e),u(s,r);t>=0&&T.data[t].children.length>this._maxEntries;)this._split(T,t),t--;!function(e,t,i){for(let n=i;n>=0;n--)u(t.data[n],e)}(r,T,t)}_split(e,t){const i=e.data[t],n=i.children.length,r=this._minEntries;this._chooseSplitAxis(i,r,n);const s=this._chooseSplitIndex(i,r,n);if(!s)return;const o=i.children.splice(s,i.children.length-s),a=i.leaf?new A(o):new E(o);a.height=i.height,p(i,this._toBBox),p(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(i,a)}_splitRoot(e,t){this._data=new E([e,t]),this._data.height=e.height+1,p(this._data,this._toBBox)}_chooseSplitIndex(e,t,i){let n,r,s;n=r=1/0;for(let o=t;o<=i-t;o++){const t=d(e,0,o,this._toBBox),a=d(e,o,i,this._toBBox),l=g(t,a),p=y(t)+y(a);l<n?(n=l,s=o,r=p<r?p:r):l===n&&p<r&&(r=p,s=o)}return s}_chooseSplitAxis(e,t,i){const n=e.leaf?this._compareMinX:c,r=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,i,n)<this._allDistMargin(e,t,i,r)&&e.children.sort(n)}_allDistMargin(e,t,i,n){e.children.sort(n);const r=this._toBBox,s=d(e,0,t,r),o=d(e,i-t,i,r);let a=m(s)+m(o);for(let n=t;n<i-t;n++){const t=e.children[n];u(s,e.leaf?r(t):t),a+=m(s)}for(let n=i-t-1;n>=t;n--){const t=e.children[n];u(o,e.leaf?r(t):t),a+=m(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const i=e.data[t];if(0===i.children.length)if(t>0){const r=e.data[t-1],s=r.children;s.splice((0,n.qh)(s,i,s.length,r.indexHint),1)}else this.clear();else p(i,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 i=e;for(I.clear();i;){if(!0===i.leaf)for(const e of i.children)t((0,r.zI)(e));else I.pushArray(i.children);i=I.pop()??null}}function p(e,t){d(e,0,e.children.length,t,e)}function d(e,t,i,n,r){r||(r=new A([])),r.minX=1/0,r.minY=1/0,r.maxX=-1/0,r.maxY=-1/0;for(let s,o=t;o<i;o++)s=e.children[o],u(r,e.leaf?n(s):s);return r}function u(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 i=Math.max(e.minX,t.minX),n=Math.max(e.minY,t.minY),r=Math.min(e.maxX,t.maxX),s=Math.min(e.maxY,t.maxY);return Math.max(0,r-i)*Math.max(0,s-n)}function b(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function w(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function _(e,t,i,n,r){const s=[t,i];for(;s.length;){const t=s.pop(),i=s.pop();if(t-i<=n)continue;const a=i+Math.ceil((t-i)/n/2)*n;(0,o.q)(e,a,i,t,r),s.push(i,a,a,t)}}const M=new s.A,I=new s.A,T=new s.A,C=new s.A({deallocator:void 0});class v{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class x extends v{constructor(){super(...arguments),this.height=1,this.indexHint=new n.vW}}class A extends x{constructor(e){super(),this.children=e,this.leaf=!0}}class E extends x{constructor(e){super(),this.children=e,this.leaf=!1}}},77901:(e,t,i)=>{i.d(t,{A:()=>a});var n=i(31635),r=i(25482),s=i(10107),o=(i(44208),i(53966),i(87811),i(64108));let a=class extends r.o{constructor(e){super(e),this.properties=null}};(0,n.Cg)([(0,s.MZ)({json:{write:!0}})],a.prototype,"properties",void 0),a=(0,n.Cg)([(0,o.$)("esri.rest.knowledgeGraph.GraphObject")],a)},82935:(e,t,i)=>{i.d(t,{B:()=>h,e:()=>y});var n=i(31635),r=i(10107),s=(i(44208),i(53966),i(87811),i(36005)),o=i(64108),a=i(89317),l=i(30524),p=i(96184),d=i(73133),u=i(79677),c=i(10184);const h={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:a.K}}},y=e=>{const t=e;let i=class extends t{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const i=t.timeInfo.exportOptions;if(!i)return null;const n=i.timeOffset,r=d.j.fromJSON(i.timeOffsetUnits);return n&&r?new c.A({value:n,unit:r}):null}set timeInfo(e){(0,l.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,n.Cg)([(0,r.MZ)({type:u.A,json:{write:!1}})],i.prototype,"timeExtent",void 0),(0,n.Cg)([(0,r.MZ)({type:c.A})],i.prototype,"timeOffset",void 0),(0,n.Cg)([(0,s.w)("service","timeOffset",["timeInfo.exportOptions"])],i.prototype,"readOffset",null),(0,n.Cg)([(0,r.MZ)({value:null,type:p.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],i.prototype,"timeInfo",null),(0,n.Cg)([(0,r.MZ)(h)],i.prototype,"useViewTime",void 0),i=(0,n.Cg)([(0,o.$)("esri.layers.mixins.TemporalLayer")],i),i}},83221:(e,t,i)=>{i.d(t,{A:()=>y});var n=i(4576),r=i(49186),s=i(65529),o=i(53966),a=i(70328),l=i(19419),p=i(90708),d=i(6518),u=i(51441),c=i(37730);const h=(0,a.vt)();class y{constructor(e){this.geometryInfo=e,this._boundsStore=new d.F,this._featuresById=new Map,this._usedMemory=0,this.events=new s.bk,this.featureAdapter=c.T}get usedMemory(){return this._usedMemory}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,i,n,r]=this.fullBounds;return{xmin:t,ymin:i,xmax:n,ymax:r,spatialReference:(0,u.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(),this._usedMemory=0}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 i of e){const e=this._boundsStore.get(i.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 r.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const i=this._featuresById.get(t);let n;if(i?(e.displayId=i.displayId,n=this._boundsStore.get(t),this._boundsStore.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(i)??0):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);n=(0,p.jQ)(null!=n?n:(0,l.vt)(),e.geometry),null!=n&&this._boundsStore.set(t,n),this._featuresById.set(t,e),this._usedMemory+=this.estimateFeatureUsedMemory?.(e)??0}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new r.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const i=this._featuresById.get(t);if(!i)return this._add(e),e;this._usedMemory-=this.estimateFeatureUsedMemory?.(i)??0;const{geometry:n,attributes:s}=e;for(const e in s)i.attributes[e]=s[e];return n&&(i.geometry=n,this._boundsStore.set(t,(0,p.jQ)((0,l.vt)(),n)??null)),this._usedMemory+=this.estimateFeatureUsedMemory?.(i)??0,i}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._boundsStore.delete(t),this._featuresById.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(e)??0,e}}},83960:(e,t,i)=>{i.d(t,{X_:()=>o,oW:()=>l,zx:()=>a});var n=i(34727),r=i(83047);const s=96;function o(e,t){const i=t||e.extent,n=e.width,o=(0,r.GA)(i?.spatialReference);return i&&n?i.width/n*o*r.dy*s:0}function a(e,t,i){return function(e,t){return 0===t||(0,n.Sp)(e,t)||e<t}(e,t)&&function(e,t){return 0===t||(0,n.Sp)(e,t)||e>t}(e,i)}function l(e,t){return(0,n.Sp)(e,t)?0:(e||Number.POSITIVE_INFINITY)>(t||Number.POSITIVE_INFINITY)?1:-1}},96184:(e,t,i)=>{i.d(t,{A:()=>y});var n=i(31635),r=i(69540),s=i(25482),o=i(10107),a=(i(44208),i(53966),i(87811),i(36005)),l=i(64108),p=i(43937),d=i(79677),u=i(10184),c=i(56400);function h(e,t){return u.A.fromJSON({value:e,unit:t})}let y=class extends((0,r.OU)(s.o)){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.Cg)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],y.prototype,"cumulative",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"endField",void 0),(0,n.Cg)([(0,o.MZ)({type:d.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"fullTimeExtent",void 0),(0,n.Cg)([(0,a.w)("fullTimeExtent",["timeExtent"])],y.prototype,"readFullTimeExtent",null),(0,n.Cg)([(0,p.K)("fullTimeExtent")],y.prototype,"writeFullTimeExtent",null),(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{write:!0}})],y.prototype,"hasLiveData",void 0),(0,n.Cg)([(0,o.MZ)({type:u.A,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"interval",void 0),(0,n.Cg)([(0,a.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],y.prototype,"readInterval",null),(0,n.Cg)([(0,p.K)("interval")],y.prototype,"writeInterval",null),(0,n.Cg)([(0,o.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"startField",void 0),(0,n.Cg)([(0,o.MZ)((0,c.P6)("timeReference",!0))],y.prototype,"timeZone",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"trackIdField",void 0),(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],y.prototype,"useTime",void 0),(0,n.Cg)([(0,o.MZ)({type:[Date],json:{read:!1}})],y.prototype,"stops",void 0),y=(0,n.Cg)([(0,l.$)("esri.layers.support.TimeInfo")],y)}}]);