@arcgis/core 4.28.0-rc.2 → 4.28.0-rc.4

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 (163) hide show
  1. package/arcade/ArcadeDate.js +1 -1
  2. package/arcade/functions/featuresetbase.js +1 -1
  3. package/assets/esri/core/workers/RemoteClient.js +1 -1
  4. package/assets/esri/core/workers/chunks/{0e354096ad8817971eed.js → 02d235849ba93541d7ad.js} +1 -1
  5. package/assets/esri/core/workers/chunks/0422c5160491fbcf01dc.js +1 -0
  6. package/assets/esri/core/workers/chunks/1da721608993783dc9cf.js +1 -0
  7. package/assets/esri/core/workers/chunks/224e79f6c172da444e0a.js +1 -0
  8. package/assets/esri/core/workers/chunks/{ca3d5803cdf035d7389d.js → 30776102fbab294bfe7b.js} +1 -1
  9. package/assets/esri/core/workers/chunks/{61dec8399919b278b636.js → 3ac9001b19a90faf5573.js} +1 -1
  10. package/assets/esri/core/workers/chunks/{fa6103e3d4e857b0035b.js → 3dcb2a82e1e4b520c9c9.js} +11 -8
  11. package/assets/esri/core/workers/chunks/41081c921037e543a22f.js +1 -0
  12. package/assets/esri/core/workers/chunks/4564a7885d045a850887.js +1 -0
  13. package/assets/esri/core/workers/chunks/4adf3a8c6b49c381a633.js +1 -0
  14. package/assets/esri/core/workers/chunks/{2721aa6b6941b28b9758.js → 63c8bf00120a4e67f5b0.js} +1 -1
  15. package/assets/esri/core/workers/chunks/6bc1f6f8a2408fa4bb6a.js +1 -0
  16. package/assets/esri/core/workers/chunks/74951370a341f02d3714.js +1 -0
  17. package/assets/esri/core/workers/chunks/78e49a70193e5adea17c.js +1 -0
  18. package/assets/esri/core/workers/chunks/7b8377b3a9f78f9d3613.js +1 -0
  19. package/assets/esri/core/workers/chunks/{fd28400141a6751327ae.js → 7cf7f2b991a7cbdad2ce.js} +1 -1
  20. package/assets/esri/core/workers/chunks/830d99e6c58a52a58973.js +1 -0
  21. package/assets/esri/core/workers/chunks/{1a723bb4a341f645e5fe.js → 83b8141f0c80e3448012.js} +1 -1
  22. package/assets/esri/core/workers/chunks/8f7997e8e6ee9e56239f.js +1 -0
  23. package/assets/esri/core/workers/chunks/934c32c49bb9e21482fd.js +1 -0
  24. package/assets/esri/core/workers/chunks/{a4341ec0fe89b865d849.js → a160576f21ada91995ac.js} +1 -1
  25. package/assets/esri/core/workers/chunks/a1e16c33f1843dbdce26.js +1 -0
  26. package/assets/esri/core/workers/chunks/{d07235ce2765a25b9be4.js → a50ec5b647a160199cb2.js} +1 -1
  27. package/assets/esri/core/workers/chunks/b6bd31674076e543d8b2.js +1 -0
  28. package/assets/esri/core/workers/chunks/{77923afde29ae1ff10ca.js → b6e86e179f99b5cf8dff.js} +1 -1
  29. package/assets/esri/core/workers/chunks/c3ddf5dbc34f118002df.js +1 -0
  30. package/assets/esri/core/workers/chunks/{562eafa5090827ebb7ec.js → c87e9280681c20d042b5.js} +1 -1
  31. package/assets/esri/core/workers/chunks/{7b3d5f044c96e2c2af11.js → d191267d91a53db42956.js} +1 -1
  32. package/assets/esri/core/workers/chunks/ffa330a19a09679212fb.js +1 -0
  33. package/assets/esri/themes/base/widgets/_BasemapGallery.scss +9 -13
  34. package/assets/esri/themes/base/widgets/_Features.scss +5 -0
  35. package/assets/esri/themes/base/widgets/_Legend.scss +1 -1
  36. package/assets/esri/themes/base/widgets/_Popup.scss +0 -1
  37. package/assets/esri/themes/base/widgets/_TimeZoneLabel.scss +3 -3
  38. package/assets/esri/themes/dark/main.css +1 -1
  39. package/assets/esri/themes/light/main.css +1 -1
  40. package/assets/esri/themes/light/view.css +1 -1
  41. package/geometry/support/meshUtils/georeference.js +1 -1
  42. package/interfaces.d.ts +1506 -314
  43. package/intl/date.js +1 -1
  44. package/kernel.js +1 -1
  45. package/layers/FeatureLayer.js +1 -1
  46. package/layers/GroupLayer.js +1 -1
  47. package/layers/OrientedImageryLayer.js +1 -1
  48. package/layers/SceneLayer.js +1 -1
  49. package/layers/graphics/controllers/I3SOnDemandController.js +1 -1
  50. package/layers/graphics/data/QueryEngineResult.js +1 -1
  51. package/layers/graphics/data/queryValidationUtils.js +1 -1
  52. package/layers/mixins/ArcGISMapService.js +1 -1
  53. package/layers/save/groupLayerUtils.js +1 -1
  54. package/layers/save/utils.js +1 -1
  55. package/layers/support/ImageElement.js +1 -1
  56. package/layers/support/LayerContingentValuesCache.js +1 -1
  57. package/layers/support/Sublayer.js +1 -1
  58. package/layers/support/Subtype.d.ts +4 -0
  59. package/layers/support/Subtype.js +1 -1
  60. package/layers/support/imageryRendererUtils.js +1 -1
  61. package/networks/Network.js +1 -1
  62. package/package.json +1 -1
  63. package/portal/support/jsonContext.js +1 -1
  64. package/portal/support/layersLoader.js +1 -1
  65. package/rest/featureService/FeatureService.d.ts +4 -0
  66. package/rest/featureService/FeatureService.js +1 -1
  67. package/rest/featureService/utils.d.ts +4 -0
  68. package/rest/query/operations/query.js +1 -1
  69. package/smartMapping/support/utils.js +1 -1
  70. package/statistics/utils.js +1 -1
  71. package/support/basemapUtils.js +1 -1
  72. package/support/revision.js +1 -1
  73. package/versionManagement/VersionManagementService.d.ts +4 -0
  74. package/versionManagement/VersionManagementService.js +1 -1
  75. package/views/2d/engine/Container.js +1 -1
  76. package/views/2d/engine/vectorTiles/VTLPainter3D.js +1 -1
  77. package/views/2d/engine/webgl/Overlay.js +1 -1
  78. package/views/2d/input/handlers/KeyPan.js +1 -1
  79. package/views/2d/interactive/editingTools/manipulations/DragManipulation.js +1 -1
  80. package/views/2d/layers/FeatureLayerView2D.js +1 -1
  81. package/views/3d/analysis/Slice/RotateManipulator.js +1 -1
  82. package/views/3d/analysis/Slice/ShiftManipulator.js +1 -1
  83. package/views/3d/interactive/editingTools/transformGraphic/ExtentTransformTool.js +1 -1
  84. package/views/3d/interactive/measurementTools/areaMeasurement3D/AreaMeasurement3DView.js +1 -1
  85. package/views/3d/interactive/visualElements/LineVisualElement.js +1 -1
  86. package/views/3d/layers/I3SMeshView3D.js +1 -1
  87. package/views/3d/layers/MediaLayerView3D.js +1 -1
  88. package/views/3d/layers/SceneLayerWorker.js +1 -1
  89. package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
  90. package/views/3d/layers/graphics/defaultSymbolComplexity.js +1 -1
  91. package/views/3d/layers/graphics/elevationAlignPointsInFeatures.js +1 -1
  92. package/views/3d/layers/i3s/I3SClientNodeLoader.js +1 -1
  93. package/views/3d/support/MemoryController.js +1 -1
  94. package/views/3d/support/PBFDecoder.js +1 -1
  95. package/views/3d/support/ResourceController.js +1 -1
  96. package/views/3d/terrain/OverlayFramebufferObject.js +1 -1
  97. package/views/3d/webgl-engine/core/FBOCache.js +1 -1
  98. package/views/3d/webgl-engine/core/FBOPool.js +5 -0
  99. package/views/3d/webgl-engine/core/shaderLibrary/attributes/InstancedDoublePrecision.glsl.js +9 -6
  100. package/views/3d/webgl-engine/core/shaderLibrary/shading/EvaluateSceneLighting.glsl.js +2 -2
  101. package/views/3d/webgl-engine/effects/highlight/Highlight.js +1 -1
  102. package/views/3d/webgl-engine/effects/ssao/SSAO.js +1 -1
  103. package/views/3d/webgl-engine/lib/Camera.js +1 -1
  104. package/views/3d/webgl-engine/lib/OffscreenRendering.js +1 -1
  105. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  106. package/views/3d/webgl-engine/lib/Texture.js +1 -1
  107. package/views/3d/webgl-engine/lib/textureUtils.js +1 -1
  108. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  109. package/views/3d/webgl-engine/parts/RenderView.js +1 -1
  110. package/views/3d/webgl-engine/parts/ScreenshotManager.js +1 -1
  111. package/views/3d/webgl-engine/shaders/sources/edgeRenderer/EdgeUtil.glsl.js +1 -1
  112. package/views/draw/DrawOperation.js +1 -1
  113. package/views/draw/support/Reshape.js +1 -1
  114. package/views/interactive/sketch/constraints.js +1 -1
  115. package/views/interactive/snapping/FeatureSnappingEngine.js +1 -1
  116. package/views/interactive/snapping/featureSources/FeatureCollectionSnappingSource.js +1 -1
  117. package/views/interactive/snapping/featureSources/FeatureServiceSnappingSource.js +1 -1
  118. package/views/interactive/snapping/featureSources/GraphicsSnappingSource.js +1 -1
  119. package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorker.js +1 -1
  120. package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorkerHandle.js +1 -1
  121. package/views/interactive/snapping/featureSources/queryEngineUtils.js +1 -1
  122. package/views/interactive/snapping/featureSources/snappingCandidateElevationAlignment.js +1 -1
  123. package/webdoc/support/writeUtils.js +1 -1
  124. package/widgets/BasemapGallery.js +1 -1
  125. package/widgets/DirectionalPad.js +1 -1
  126. package/widgets/Editor/CreateFeaturesWorkflow.js +1 -1
  127. package/widgets/Editor/EditorViewModel.js +1 -1
  128. package/widgets/Editor/UpdateRecordWorkflow.js +1 -1
  129. package/widgets/Editor/UpdateWorkflow.js +1 -1
  130. package/widgets/Editor/VisibleElements.js +1 -1
  131. package/widgets/Editor/workflowUtils.js +1 -1
  132. package/widgets/Editor.js +1 -1
  133. package/widgets/FeatureForm/FieldInput.js +1 -1
  134. package/widgets/FeatureForm/FormExpressionsManager.js +1 -1
  135. package/widgets/FeatureForm.js +1 -1
  136. package/widgets/Features.js +1 -1
  137. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.d.ts +4 -0
  138. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  139. package/widgets/OrientedImageryViewer.js +1 -1
  140. package/widgets/TimeSlider.js +1 -1
  141. package/widgets/TimeZoneLabel.js +1 -1
  142. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceViewModel.js +1 -1
  143. package/widgets/UtilityNetworkTrace.js +1 -1
  144. package/widgets/support/dateUtils.js +1 -1
  145. package/assets/esri/core/workers/chunks/00da3c16741a9bc47f3a.js +0 -1
  146. package/assets/esri/core/workers/chunks/0e4646d14fa0775bf463.js +0 -1
  147. package/assets/esri/core/workers/chunks/4e0bf30da4281070e453.js +0 -1
  148. package/assets/esri/core/workers/chunks/51b8913dff24e693bd25.js +0 -1
  149. package/assets/esri/core/workers/chunks/5e907ec0ee1565b5fbbc.js +0 -1
  150. package/assets/esri/core/workers/chunks/7388fd97e7b1a2142744.js +0 -1
  151. package/assets/esri/core/workers/chunks/7648f3341b7dff2825c3.js +0 -1
  152. package/assets/esri/core/workers/chunks/92d8f75e616afa5c761e.js +0 -1
  153. package/assets/esri/core/workers/chunks/9c77d69a13ec22cdd760.js +0 -1
  154. package/assets/esri/core/workers/chunks/a821fa1870b83fed5d31.js +0 -1
  155. package/assets/esri/core/workers/chunks/a877a4826cd6a46ec99b.js +0 -1
  156. package/assets/esri/core/workers/chunks/b251d8a856dc8b9406e0.js +0 -1
  157. package/assets/esri/core/workers/chunks/c416df0668f6c596095f.js +0 -1
  158. package/assets/esri/core/workers/chunks/d8c696da42f8f8919b83.js +0 -1
  159. package/assets/esri/core/workers/chunks/f0d342303fc20e266d27.js +0 -1
  160. package/assets/esri/core/workers/chunks/fac3e57784d7f37053af.js +0 -1
  161. package/assets/esri/core/workers/chunks/fc95b1a36ed68b851400.js +0 -1
  162. package/widgets/DirectionalPad/DirectionalPadViewModel.d.ts +0 -4
  163. package/widgets/DirectionalPad.d.ts +0 -4
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4680,5935],{84552:(e,t,i)=>{i.d(t,{Z:()=>c});var r=i(43697),o=i(2368),n=i(96674),s=i(35463),l=i(5600),a=(i(75215),i(67676),i(80442),i(36030)),p=i(52011),d=i(78981);let u=class extends((0,o.J)(n.wq)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,s.rJ)(this.value,this.unit,"milliseconds")}};(0,r._)([(0,a.J)(d.v,{nonNullable:!0})],u.prototype,"unit",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0},nonNullable:!0})],u.prototype,"value",void 0),u=(0,r._)([(0,p.j)("esri.TimeInterval")],u);const c=u},41123:(e,t,i)=>{i.d(t,{D:()=>o,z:()=>n});const r="randomUUID"in crypto;function o(){if(r)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function n(){return`{${o()}}`}},90100:(e,t,i)=>{i.d(t,{Z:()=>Ue});var r,o=i(43697),n=i(96674),s=i(22974),l=i(5600),a=i(90578),p=i(71715),d=i(52011),u=i(30556),c=i(75215);i(67676),i(80442);let y=r=class extends n.wq{constructor(e){super(e),this.expression=null,this.name=null,this.returnType="boolean",this.title=null}clone(){return new r({name:this.name,title:this.title,expression:this.expression,returnType:this.returnType})}};(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],y.prototype,"expression",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],y.prototype,"name",void 0),(0,o._)([(0,l.Cb)({type:["boolean","date","number","string"],json:{write:!0}})],y.prototype,"returnType",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],y.prototype,"title",void 0),y=r=(0,o._)([(0,d.j)("esri.form.ExpressionInfo")],y);const h=y;let m=class extends n.wq{constructor(e){super(e),this.description=null,this.label=null,this.type=null,this.visibilityExpression=null}};(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],m.prototype,"description",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],m.prototype,"label",void 0),(0,o._)([(0,l.Cb)()],m.prototype,"type",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],m.prototype,"visibilityExpression",void 0),m=(0,o._)([(0,d.j)("esri.form.elements.Element")],m);const f=m;var b;let v=b=class extends n.wq{constructor(e){super(e),this.type=null}clone(){return new b({type:this.type})}};(0,o._)([(0,l.Cb)({type:["attachment","audio","document","image","signature","video"],json:{write:!0}})],v.prototype,"type",void 0),v=b=(0,o._)([(0,d.j)("esri.form.elements.inputs.AttachmentInput")],v);const w=v;var g;let _=g=class extends f{constructor(e){super(e),this.attachmentKeyword=null,this.editableExpression=null,this.input=null,this.type="attachment"}clone(){return new g({attachmentKeyword:this.attachmentKeyword,description:this.description,editableExpression:this.editableExpression,input:this.input,label:this.label,visibilityExpression:this.visibilityExpression})}};(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],_.prototype,"attachmentKeyword",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],_.prototype,"editableExpression",void 0),(0,o._)([(0,l.Cb)({type:w,json:{read:{source:"inputType"},write:{target:"inputType"}}})],_.prototype,"input",void 0),(0,o._)([(0,l.Cb)({type:["attachment"],json:{read:!1,write:!0}})],_.prototype,"type",void 0),_=g=(0,o._)([(0,d.j)("esri.form.elements.AttachmentElement")],_);const x=_;var C=i(60235),j=i(92604);let I=class extends n.wq{constructor(e){super(e),this.type=null}};(0,o._)([(0,l.Cb)()],I.prototype,"type",void 0),I=(0,o._)([(0,d.j)("esri.form.elements.inputs.Input")],I);const S=I;let F=class extends S{constructor(e){super(e),this.maxLength=null,this.minLength=0}};(0,o._)([(0,l.Cb)({type:Number,json:{write:!0}})],F.prototype,"maxLength",void 0),(0,o._)([(0,l.Cb)({type:Number,json:{write:!0}})],F.prototype,"minLength",void 0),F=(0,o._)([(0,d.j)("esri.form.elements.inputs.TextInput")],F);const E=F;var M;let T=M=class extends E{constructor(e){super(e),this.type="barcode-scanner"}clone(){return new M({maxLength:this.maxLength,minLength:this.minLength})}};(0,o._)([(0,l.Cb)({type:["barcode-scanner"],json:{read:!1,write:!0}})],T.prototype,"type",void 0),T=M=(0,o._)([(0,d.j)("esri.form.elements.inputs.BarcodeScannerInput")],T);const O=T;var R;let U=R=class extends S{constructor(e){super(e),this.noValueOptionLabel=null,this.showNoValueOption=!0,this.type="combo-box"}clone(){return new R({showNoValueOption:this.showNoValueOption,noValueOptionLabel:this.noValueOptionLabel})}};(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],U.prototype,"noValueOptionLabel",void 0),(0,o._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],U.prototype,"showNoValueOption",void 0),(0,o._)([(0,l.Cb)({type:["combo-box"],json:{read:!1,write:!0}})],U.prototype,"type",void 0),U=R=(0,o._)([(0,d.j)("esri.form.elements.inputs.ComboBoxInput")],U);const V=U;var Z;function A(e){return null!=e?e:null}function k(e){return null!=e?e:null}let D=Z=class extends S{constructor(e){super(e),this.max=null,this.min=null,this.type="date-picker"}readMax(e,t){return A(t.max)}writeMax(e,t){t.max=k(e)}readMin(e,t){return A(t.min)}writeMin(e,t){t.min=k(e)}clone(){return new Z({max:this.max,min:this.min})}};(0,o._)([(0,l.Cb)({type:String,json:{type:String,write:!0}})],D.prototype,"max",void 0),(0,o._)([(0,p.r)("max")],D.prototype,"readMax",null),(0,o._)([(0,u.c)("max")],D.prototype,"writeMax",null),(0,o._)([(0,l.Cb)({type:String,json:{type:String,write:!0}})],D.prototype,"min",void 0),(0,o._)([(0,p.r)("min")],D.prototype,"readMin",null),(0,o._)([(0,u.c)("min")],D.prototype,"writeMin",null),(0,o._)([(0,l.Cb)({type:["date-picker"],json:{read:!1,write:!0}})],D.prototype,"type",void 0),D=Z=(0,o._)([(0,d.j)("esri.form.elements.inputs.DatePickerInput")],D);const N=D;var L;function q(e){return null!=e?e:null}function B(e){return null!=e?e:null}let P=L=class extends S{constructor(e){super(e),this.includeTimeOffset=!0,this.max=null,this.min=null,this.timeResolution="minutes",this.type="datetimeoffset-picker"}readMax(e,t){return q(t.max)}writeMax(e,t){t.max=B(e)}readMin(e,t){return q(t.min)}writeMin(e,t){t.min=B(e)}readTimeResolution(e,t){return q(t.timeResolution)}writeTimeResolution(e,t){t.timeResolution=B(e)}clone(){return new L({includeTimeOffset:this.includeTimeOffset,max:this.max,min:this.min,timeResolution:this.timeResolution})}};(0,o._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],P.prototype,"includeTimeOffset",void 0),(0,o._)([(0,l.Cb)({type:String,json:{type:String,write:!0}})],P.prototype,"max",void 0),(0,o._)([(0,p.r)("max")],P.prototype,"readMax",null),(0,o._)([(0,u.c)("max")],P.prototype,"writeMax",null),(0,o._)([(0,l.Cb)({type:String,json:{type:String,write:!0}})],P.prototype,"min",void 0),(0,o._)([(0,p.r)("min")],P.prototype,"readMin",null),(0,o._)([(0,u.c)("min")],P.prototype,"writeMin",null),(0,o._)([(0,l.Cb)({type:String,json:{type:String,write:!0}})],P.prototype,"timeResolution",void 0),(0,o._)([(0,p.r)("timeResolution")],P.prototype,"readTimeResolution",null),(0,o._)([(0,u.c)("timeResolution")],P.prototype,"writeTimeResolution",null),(0,o._)([(0,l.Cb)({type:["datetimeoffset-picker"],json:{read:!1,write:!0}})],P.prototype,"type",void 0),P=L=(0,o._)([(0,d.j)("esri.form.elements.inputs.DateTimeOffsetPickerInput")],P);const G=P;var H;function J(e){return null!=e?new Date(e):null}function Q(e){return e?e.getTime():null}let W=H=class extends S{constructor(e){super(e),this.includeTime=!1,this.max=null,this.min=null,this.type="datetime-picker"}readMax(e,t){return J(t.max)}writeMax(e,t){t.max=Q(e)}readMin(e,t){return J(t.min)}writeMin(e,t){t.min=Q(e)}clone(){return new H({includeTime:this.includeTime,max:this.max,min:this.min})}};(0,o._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],W.prototype,"includeTime",void 0),(0,o._)([(0,l.Cb)({type:Date,json:{type:Number,write:!0}})],W.prototype,"max",void 0),(0,o._)([(0,p.r)("max")],W.prototype,"readMax",null),(0,o._)([(0,u.c)("max")],W.prototype,"writeMax",null),(0,o._)([(0,l.Cb)({type:Date,json:{type:Number,write:!0}})],W.prototype,"min",void 0),(0,o._)([(0,p.r)("min")],W.prototype,"readMin",null),(0,o._)([(0,u.c)("min")],W.prototype,"writeMin",null),(0,o._)([(0,l.Cb)({type:["datetime-picker"],json:{read:!1,write:!0}})],W.prototype,"type",void 0),W=H=(0,o._)([(0,d.j)("esri.form.elements.inputs.DateTimePickerInput")],W);const $=W;var z;let X=z=class extends S{constructor(e){super(e),this.noValueOptionLabel=null,this.showNoValueOption=!0,this.type="radio-buttons"}clone(){return new z({noValueOptionLabel:this.noValueOptionLabel,showNoValueOption:this.showNoValueOption})}};(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],X.prototype,"noValueOptionLabel",void 0),(0,o._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],X.prototype,"showNoValueOption",void 0),(0,o._)([(0,l.Cb)({type:["radio-buttons"],json:{read:!1,write:!0}})],X.prototype,"type",void 0),X=z=(0,o._)([(0,d.j)("esri.form.elements.inputs.RadioButtonsInput")],X);const K=X;var Y;let ee=Y=class extends S{constructor(e){super(e),this.offValue=null,this.onValue=null,this.type="switch"}clone(){return new Y({offValue:this.offValue,onValue:this.onValue})}};(0,o._)([(0,l.Cb)({type:[String,Number],json:{write:!0}})],ee.prototype,"offValue",void 0),(0,o._)([(0,l.Cb)({type:[String,Number],json:{write:!0}})],ee.prototype,"onValue",void 0),(0,o._)([(0,l.Cb)({type:["switch"],json:{read:!1,write:!0}})],ee.prototype,"type",void 0),ee=Y=(0,o._)([(0,d.j)("esri.form.elements.inputs.SwitchInput")],ee);const te=ee;var ie;let re=ie=class extends E{constructor(e){super(e),this.type="text-area"}clone(){return new ie({maxLength:this.maxLength,minLength:this.minLength})}};(0,o._)([(0,l.Cb)({type:["text-area"],json:{read:!1,write:!0}})],re.prototype,"type",void 0),re=ie=(0,o._)([(0,d.j)("esri.form.elements.inputs.TextAreaInput")],re);const oe=re;var ne;let se=ne=class extends E{constructor(e){super(e),this.type="text-box"}clone(){return new ne({maxLength:this.maxLength,minLength:this.minLength})}};(0,o._)([(0,l.Cb)({type:["text-box"],json:{read:!1,write:!0}})],se.prototype,"type",void 0),se=ne=(0,o._)([(0,d.j)("esri.form.elements.inputs.TextBoxInput")],se);const le=se;var ae;function pe(e){return null!=e?e:null}function de(e){return null!=e?e:null}let ue=ae=class extends S{constructor(e){super(e),this.max=null,this.min=null,this.timeResolution="minutes",this.type="time-picker"}readMax(e,t){return pe(t.max)}writeMax(e,t){t.max=de(e)}readMin(e,t){return pe(t.min)}writeMin(e,t){t.min=de(e)}readTimeResolution(e,t){return pe(t.timeResolution)}writeTimeResolution(e,t){t.timeResolution=de(e)}clone(){return new ae({max:this.max,min:this.min,timeResolution:this.timeResolution})}};(0,o._)([(0,l.Cb)({type:String,json:{type:String,write:!0}})],ue.prototype,"max",void 0),(0,o._)([(0,p.r)("max")],ue.prototype,"readMax",null),(0,o._)([(0,u.c)("max")],ue.prototype,"writeMax",null),(0,o._)([(0,l.Cb)({type:String,json:{type:String,write:!0}})],ue.prototype,"min",void 0),(0,o._)([(0,p.r)("min")],ue.prototype,"readMin",null),(0,o._)([(0,u.c)("min")],ue.prototype,"writeMin",null),(0,o._)([(0,l.Cb)({type:String,json:{type:String,write:!0}})],ue.prototype,"timeResolution",void 0),(0,o._)([(0,p.r)("timeResolution")],ue.prototype,"readTimeResolution",null),(0,o._)([(0,u.c)("timeResolution")],ue.prototype,"writeTimeResolution",null),(0,o._)([(0,l.Cb)({type:["time-picker"],json:{read:!1,write:!0}})],ue.prototype,"type",void 0),ue=ae=(0,o._)([(0,d.j)("esri.form.elements.inputs.TimePickerInput")],ue);const ce={base:S,key:"type",typeMap:{"barcode-scanner":O,"combo-box":V,"date-picker":N,"datetime-picker":$,"datetimeoffset-picker":G,"radio-buttons":K,switch:te,"text-area":oe,"text-box":le,"time-picker":ue}};var ye,he=i(72729);const me="esri.form.elements.FieldElement",fe=j.Z.getLogger(me);let be=ye=class extends f{constructor(e){super(e),this.domain=null,this.editableExpression=null,this.fieldName=null,this.hint=null,this.input=null,this.requiredExpression=null,this.type="field",this.valueExpression=null}get editable(){return(0,C.Mr)(fe,"editable",{replacement:"editableExpression",version:"4.26",warnOnce:!0}),this._get("editable")??!0}set editable(e){(0,C.Mr)(fe,"editable",{replacement:"editableExpression",version:"4.26",warnOnce:!0}),this._set("editable",e)}clone(){return new ye({description:this.description,domain:this.domain,editable:this.editable,editableExpression:this.editableExpression,fieldName:this.fieldName,hint:this.hint,input:this.input,label:this.label,requiredExpression:this.requiredExpression,valueExpression:this.valueExpression,visibilityExpression:this.visibilityExpression})}};(0,o._)([(0,l.Cb)({types:he.V5,json:{read:{reader:he.im},write:!0}})],be.prototype,"domain",void 0),(0,o._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],be.prototype,"editable",null),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],be.prototype,"editableExpression",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],be.prototype,"fieldName",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],be.prototype,"hint",void 0),(0,o._)([(0,l.Cb)({types:ce,json:{read:{source:"inputType"},write:{target:"inputType"}}})],be.prototype,"input",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],be.prototype,"requiredExpression",void 0),(0,o._)([(0,l.Cb)({type:String,json:{read:!1,write:!0}})],be.prototype,"type",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],be.prototype,"valueExpression",void 0),be=ye=(0,o._)([(0,d.j)(me)],be);const ve=be;var we,ge=i(44729);let _e=we=class extends f{constructor(e){super(e),this.displayCount=null,this.displayType="list",this.editableExpression=null,this.orderByFields=null,this.relationshipId=null,this.type="relationship"}clone(){return new we({description:this.description,displayCount:this.displayCount,displayType:this.displayType,editableExpression:this.editableExpression,label:this.label,orderByFields:(0,s.d9)(this.orderByFields),relationshipId:this.relationshipId,visibilityExpression:this.visibilityExpression})}};(0,o._)([(0,l.Cb)({type:Number,json:{write:!0}})],_e.prototype,"displayCount",void 0),(0,o._)([(0,l.Cb)({type:["list"],json:{write:!0}})],_e.prototype,"displayType",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],_e.prototype,"editableExpression",void 0),(0,o._)([(0,l.Cb)({type:[ge.Z],json:{write:!0}})],_e.prototype,"orderByFields",void 0),(0,o._)([(0,l.Cb)({type:Number,json:{write:!0}})],_e.prototype,"relationshipId",void 0),(0,o._)([(0,l.Cb)({type:["relationship"],json:{read:!1,write:!0}})],_e.prototype,"type",void 0),_e=we=(0,o._)([(0,d.j)("esri.form.elements.RelationshipElement")],_e);const xe=_e;function Ce(e){return{typesWithGroup:{base:f,key:"type",typeMap:{attachment:x,field:ve,group:e,relationship:xe}},typesWithoutGroup:{base:f,key:"type",typeMap:{attachment:x,field:ve,relationship:xe}}}}function je(e,t,i=!0){if(!e)return null;const r=i?t.typesWithGroup.typeMap:t.typesWithoutGroup.typeMap;return e.filter((e=>r[e.type])).map((e=>r[e.type].fromJSON(e)))}function Ie(e,t,i=!0){if(!e)return null;const r=i?t.typesWithGroup.typeMap:t.typesWithoutGroup.typeMap;return e.filter((e=>r[e.type])).map((e=>e.toJSON()))}function Se(e,t,i=!0){return e?e.map((e=>(0,c.N7)(i?t.typesWithGroup:t.typesWithoutGroup,e))):null}var Fe;let Ee=Fe=class extends f{constructor(e){super(e),this.elements=null,this.initialState="expanded",this.type="group"}castElements(e){return Se(e,Me,!1)}readElements(e,t){return je(t.formElements,Me,!1)}writeElements(e,t){t.formElements=Ie(e,Me,!1)}clone(){return new Fe({description:this.description,elements:(0,s.d9)(this.elements),initialState:this.initialState,label:this.label,visibilityExpression:this.visibilityExpression})}};(0,o._)([(0,l.Cb)({json:{write:!0}})],Ee.prototype,"elements",void 0),(0,o._)([(0,a.p)("elements")],Ee.prototype,"castElements",null),(0,o._)([(0,p.r)("elements",["formElements"])],Ee.prototype,"readElements",null),(0,o._)([(0,u.c)("elements")],Ee.prototype,"writeElements",null),(0,o._)([(0,l.Cb)({type:["collapsed","expanded"],json:{write:!0}})],Ee.prototype,"initialState",void 0),(0,o._)([(0,l.Cb)({type:String,json:{read:!1,write:!0}})],Ee.prototype,"type",void 0),Ee=Fe=(0,o._)([(0,d.j)("esri.form.elements.GroupElement")],Ee);const Me=Ce(Ee);var Te;const Oe=Ce(Ee);let Re=Te=class extends n.wq{constructor(e){super(e),this.description=null,this.elements=null,this.expressionInfos=null,this.preserveFieldValuesWhenHidden=!1,this.title=null}castElements(e){return Se(e,Oe)}readElements(e,t){return je(t.formElements,Oe)}writeElements(e,t){t.formElements=Ie(e,Oe)}clone(){return new Te({description:this.description,expressionInfos:(0,s.d9)(this.expressionInfos),elements:(0,s.d9)(this.elements),title:this.title,preserveFieldValuesWhenHidden:this.preserveFieldValuesWhenHidden})}};(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],Re.prototype,"description",void 0),(0,o._)([(0,l.Cb)({json:{write:!0}})],Re.prototype,"elements",void 0),(0,o._)([(0,a.p)("elements")],Re.prototype,"castElements",null),(0,o._)([(0,p.r)("elements",["formElements"])],Re.prototype,"readElements",null),(0,o._)([(0,u.c)("elements")],Re.prototype,"writeElements",null),(0,o._)([(0,l.Cb)({type:[h],json:{write:!0}})],Re.prototype,"expressionInfos",void 0),(0,o._)([(0,l.Cb)({type:Boolean,json:{default:!1,write:!0}})],Re.prototype,"preserveFieldValuesWhenHidden",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],Re.prototype,"title",void 0),Re=Te=(0,o._)([(0,d.j)("esri.form.FormTemplate")],Re);const Ue=Re},79235:(e,t,i)=>{i.d(t,{Z:()=>w});var r,o=i(43697),n=i(67676),s=i(35454),l=i(96674),a=i(67900),p=i(20941),d=i(5600),u=(i(75215),i(80442),i(71715)),c=i(52011),y=i(30556);const h=(0,s.w)()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),m=h.jsonValues.slice();(0,n.e$)(m,"orthometric");const f=(0,s.w)()({meter:"meters",foot:"feet","us-foot":"us-feet","clarke-foot":"clarke-feet","clarke-yard":"clarke-yards","clarke-link":"clarke-links","sears-yard":"sears-yards","sears-foot":"sears-feet","sears-chain":"sears-chains","benoit-1895-b-chain":"benoit-1895-b-chains","indian-yard":"indian-yards","indian-1937-yard":"indian-1937-yards","gold-coast-foot":"gold-coast-feet","sears-1922-truncated-chain":"sears-1922-truncated-chains","50-kilometers":"50-kilometers","150-kilometers":"150-kilometers"});let b=r=class extends l.wq{constructor(e){super(e),this.heightModel="gravity-related-height",this.heightUnit="meters",this.vertCRS=null}writeHeightModel(e,t,i){return h.write(e,t,i)}readHeightModel(e,t,i){return h.read(e)||(i?.messages&&i.messages.push(function(e,t){return new p.Z("height-model:unsupported",`Height model of value '${e}' is not supported`,t)}(e,{context:i})),null)}readHeightUnit(e,t,i){return f.read(e)||(i?.messages&&i.messages.push(v(e,{context:i})),null)}readHeightUnitService(e,t,i){return(0,a.$C)(e)||f.read(e)||(i?.messages&&i.messages.push(v(e,{context:i})),null)}readVertCRS(e,t){return t.vertCRS||t.ellipsoid||t.geoid}clone(){return new r({heightModel:this.heightModel,heightUnit:this.heightUnit,vertCRS:this.vertCRS})}equals(e){return!!e&&(this===e||this.heightModel===e.heightModel&&this.heightUnit===e.heightUnit&&this.vertCRS===e.vertCRS)}static deriveUnitFromSR(e,t){const i=(0,a.cM)(t);return new r({heightModel:e.heightModel,heightUnit:i,vertCRS:e.vertCRS})}write(e,t){return t={origin:"web-scene",...t},super.write(e,t)}static fromJSON(e){if(!e)return null;const t=new r;return t.read(e,{origin:"web-scene"}),t}};function v(e,t){return new p.Z("height-unit:unsupported",`Height unit of value '${e}' is not supported`,t)}(0,o._)([(0,d.Cb)({type:h.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:m,default:"ellipsoidal"}}}})],b.prototype,"heightModel",void 0),(0,o._)([(0,y.c)("web-scene","heightModel")],b.prototype,"writeHeightModel",null),(0,o._)([(0,u.r)(["web-scene","service"],"heightModel")],b.prototype,"readHeightModel",null),(0,o._)([(0,d.Cb)({type:f.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:f.jsonValues,write:f.write}}}})],b.prototype,"heightUnit",void 0),(0,o._)([(0,u.r)("web-scene","heightUnit")],b.prototype,"readHeightUnit",null),(0,o._)([(0,u.r)("service","heightUnit")],b.prototype,"readHeightUnitService",null),(0,o._)([(0,d.Cb)({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],b.prototype,"vertCRS",void 0),(0,o._)([(0,u.r)("service","vertCRS",["vertCRS","ellipsoid","geoid"])],b.prototype,"readVertCRS",null),b=r=(0,o._)([(0,c.j)("esri.geometry.HeightModelInfo")],b);const w=b},66361:(e,t,i)=>{i.d(t,{jF:()=>d,lQ:()=>y,o1:()=>f});var r=i(43697),o=i(32448),n=i(22974),s=i(95330),l=(i(92604),i(75215),i(20102),i(80442),i(52011)),a=i(18596);const p=new o.Z.EventEmitter;function d(e,t,i=null,r=!1){const o=(0,s.hh)();return r=null==t||r,p.emit("apply-edits",{serviceUrl:e,layerId:t,gdbVersion:i,mayReceiveServiceEdits:r,result:o.promise}),o}const u="esri.layers.mixins.EditBusLayer",c=Symbol(u);function y(e){return null!=e&&"object"==typeof e&&c in e}function h(e){return null!=e&&"object"==typeof e&&"gdbVersion"in e}function m(e,t,i){const r=new URL(e).host,o=a.Jp.get(r),n=e=>!e||e===o;return n(t)&&n(i)||t===i}const f=e=>{var t;let i=class extends e{constructor(...e){super(...e),this[t]=!0,this._applyEditsHandler=e=>{const{serviceUrl:t,layerId:i,gdbVersion:r,mayReceiveServiceEdits:o,result:s}=e,l=t===this.url,p=null!=i&&null!=this.layerId&&i===this.layerId,d=h(this),u=h(this)&&m(t,r,this.gdbVersion);if(!l||d&&!u||!p&&!o)return;const c=s.then((e=>{if(p&&(e.addedFeatures.length||e.updatedFeatures.length||e.deletedFeatures.length||e.addedAttachments.length||e.updatedAttachments.length||e.deletedAttachments.length))return this.emit("edits",(0,n.d9)(e)),e;const t=e.editedFeatures?.find((({layerId:e})=>e===this.layerId));if(t){const{adds:i,updates:r,deletes:o}=t.editedFeatures,s={edits:null,addedAttachments:[],deletedAttachments:[],updatedAttachments:[],addedFeatures:i?i.map((({attributes:e})=>({objectId:this.objectIdField&&e[this.objectIdField],globalId:this.globalIdField&&e[this.globalIdField]}))):[],deletedFeatures:o?o.map((({attributes:e})=>({objectId:this.objectIdField&&e[this.objectIdField],globalId:this.globalIdField&&e[this.globalIdField]}))):[],updatedFeatures:r?r.map((({current:{attributes:e}})=>({objectId:this.objectIdField&&e[this.objectIdField],globalId:this.globalIdField&&e[this.globalIdField]}))):[],editedFeatures:(0,n.d9)(e.editedFeatures),exceededTransferLimit:!1,historicMoment:(0,n.d9)(e.historicMoment)};return this.emit("edits",s),s}return{edits:null,addedAttachments:[],deletedAttachments:[],updatedAttachments:[],addedFeatures:[],deletedFeatures:[],updatedFeatures:[],editedFeatures:(0,n.d9)(e.editedFeatures),exceededTransferLimit:!1,historicMoment:(0,n.d9)(e.historicMoment)}})).then((e=>("historicMoment"in this&&this.historicMoment!==e.historicMoment&&(0,a.JV)(t,r)&&(this.historicMoment=e.historicMoment),e)));this.emit("apply-edits",{result:c})},this._updateMomentHandler=e=>{const{serviceUrl:t,gdbVersion:i,moment:r}=e,o=t===this.url,n=h(this),s=h(this)&&m(t,i,this.gdbVersion),l=h(this)&&!m(t,this.gdbVersion,null);o&&n&&s&&l&&"historicMoment"in this&&this.historicMoment!==r&&(this.historicMoment=r)},this.when().then((()=>{this.addHandles(function(e){return p.on("apply-edits",new WeakRef(e))}(this._applyEditsHandler)),"historicMoment"in this&&this.addHandles(function(e){return p.on("update-moment",new WeakRef(e))}(this._updateMomentHandler))}),(()=>{}))}};return t=c,i=(0,r._)([(0,l.j)(u)],i),i}},25113:(e,t,i)=>{i.d(t,{B:()=>k});var r=i(43697),o=i(46791),n=i(22974),s=i(92604),l=i(5600),a=(i(75215),i(71715)),p=i(52011),d=i(30556),u=i(82960),c=i(6570),y=i(79235),h=i(82971),m=i(66677),f=i(21506),b=i(2368),v=i(96674),w=(i(67676),i(80442),i(25031));let g=class extends((0,b.J)(v.wq)){constructor(e){super(e),this.creatorField=null,this.creationDateField=null,this.editorField=null,this.editDateField=null,this.realm=null,this.timeZone=null}};(0,r._)([(0,l.Cb)()],g.prototype,"creatorField",void 0),(0,r._)([(0,l.Cb)()],g.prototype,"creationDateField",void 0),(0,r._)([(0,l.Cb)()],g.prototype,"editorField",void 0),(0,r._)([(0,l.Cb)()],g.prototype,"editDateField",void 0),(0,r._)([(0,l.Cb)()],g.prototype,"realm",void 0),(0,r._)([(0,l.Cb)((0,w.mi)("dateFieldsTimeReference",!0))],g.prototype,"timeZone",void 0),g=(0,r._)([(0,p.j)("esri.layers.support.EditFieldsInfo")],g);const _=g;let x=class extends((0,b.J)(v.wq)){constructor(e){super(e)}};(0,r._)([(0,l.Cb)({constructOnly:!0,json:{write:!0}})],x.prototype,"name",void 0),(0,r._)([(0,l.Cb)({constructOnly:!0,json:{write:!0}})],x.prototype,"fields",void 0),(0,r._)([(0,l.Cb)({constructOnly:!0,json:{write:!0}})],x.prototype,"isAscending",void 0),(0,r._)([(0,l.Cb)({constructOnly:!0,json:{write:!0}})],x.prototype,"indexType",void 0),(0,r._)([(0,l.Cb)({constructOnly:!0,json:{write:!0}})],x.prototype,"isUnique",void 0),(0,r._)([(0,l.Cb)({constructOnly:!0,json:{write:!0}})],x.prototype,"description",void 0),x=(0,r._)([(0,p.j)("esri.layers.support.FeatureIndex")],x);var C=i(45574),j=i(67900);let I=class extends((0,b.J)(v.wq)){constructor(e){super(e),this.shapeAreaField=null,this.shapeLengthField=null,this.units=null}};(0,r._)([(0,l.Cb)({type:String,json:{read:{source:"shapeAreaFieldName"}}})],I.prototype,"shapeAreaField",void 0),(0,r._)([(0,l.Cb)({type:String,json:{read:{source:"shapeLengthFieldName"}}})],I.prototype,"shapeLengthField",void 0),(0,r._)([(0,l.Cb)({type:String,json:{read:e=>j.gV.read(e)||j.Jo.read(e)}})],I.prototype,"units",void 0),I=(0,r._)([(0,p.j)("esri.layers.support.GeometryFieldsInfo")],I);const S=I;var F=i(56765),E=i(35454);const M=new E.X({esriRelCardinalityOneToOne:"one-to-one",esriRelCardinalityOneToMany:"one-to-many",esriRelCardinalityManyToMany:"many-to-many"}),T=new E.X({esriRelRoleOrigin:"origin",esriRelRoleDestination:"destination"});let O=class extends((0,b.J)(v.wq)){constructor(e){super(e),this.cardinality=null,this.composite=null,this.id=null,this.keyField=null,this.keyFieldInRelationshipTable=null,this.name=null,this.relatedTableId=null,this.relationshipTableId=null,this.role=null}};(0,r._)([(0,l.Cb)({json:{read:M.read,write:M.write}})],O.prototype,"cardinality",void 0),(0,r._)([(0,l.Cb)({json:{read:!0,write:!0}})],O.prototype,"composite",void 0),(0,r._)([(0,l.Cb)({json:{read:!0,write:!0}})],O.prototype,"id",void 0),(0,r._)([(0,l.Cb)({json:{read:!0,write:!0}})],O.prototype,"keyField",void 0),(0,r._)([(0,l.Cb)({json:{read:!0,write:!0}})],O.prototype,"keyFieldInRelationshipTable",void 0),(0,r._)([(0,l.Cb)({json:{read:!0,write:!0}})],O.prototype,"name",void 0),(0,r._)([(0,l.Cb)({json:{read:!0,write:!0}})],O.prototype,"relatedTableId",void 0),(0,r._)([(0,l.Cb)({json:{read:!0,write:!0}})],O.prototype,"relationshipTableId",void 0),(0,r._)([(0,l.Cb)({json:{read:T.read,write:T.write}})],O.prototype,"role",void 0),O=(0,r._)([(0,p.j)("esri.layers.support.Relationship")],O);const R=O;var U=i(54275),V=i(72729);let Z=class extends((0,b.J)(v.wq)){constructor(){super(...arguments),this.code=null,this.defaultValues={},this.domains=null,this.name=null}readDomains(e){if(!e)return null;const t={};for(const i of Object.keys(e))t[i]=(0,V.im)(e[i]);return t}writeDomains(e,t){if(!e)return;const i={};for(const t of Object.keys(e))e[t]&&(i[t]=e[t]?.toJSON());t.domains=i}};(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],Z.prototype,"code",void 0),(0,r._)([(0,l.Cb)({type:Object,json:{write:!0}})],Z.prototype,"defaultValues",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Z.prototype,"domains",void 0),(0,r._)([(0,a.r)("domains")],Z.prototype,"readDomains",null),(0,r._)([(0,d.c)("domains")],Z.prototype,"writeDomains",null),(0,r._)([(0,l.Cb)({type:String,json:{write:!0}})],Z.prototype,"name",void 0),Z=(0,r._)([(0,p.j)("esri.layers.support.Subtype")],Z);const A=Z,k=e=>{let t=class extends e{constructor(){super(...arguments),this.copyright=null,this.capabilities=null,this.dateFieldsTimeZone=null,this.datesInUnknownTimezone=!1,this.definitionExpression=null,this.displayField=null,this.editFieldsInfo=null,this.editingInfo=null,this.elevationInfo=null,this.floorInfo=null,this.fullExtent=null,this.gdbVersion=null,this.geometryFieldsInfo=null,this.geometryType=null,this.globalIdField=null,this.hasM=void 0,this.hasZ=void 0,this.heightModelInfo=null,this.historicMoment=null,this.indexes=new(o.Z.ofType(x)),this.isTable=!1,this.layerId=void 0,this.maxScale=0,this.minScale=0,this.objectIdField=null,this.preferredTimeZone=null,this.relationships=null,this.returnM=void 0,this.returnZ=void 0,this.serviceDefinitionExpression=null,this.serviceItemId=null,this.sourceJSON=null,this.spatialReference=h.Z.WGS84,this.subtypeField=null,this.subtypes=null,this.trackIdField=null,this.version=void 0}get authenticationTriggerEvent(){if(!this.url)return null;const{capabilities:e}=this;if(e){const{query:t,operations:i,editing:r}=e;if(!t.supportsQueryByOthers||!t.supportsQueryByAnonymous)return"load";if(i.supportsEditing&&!(r.supportsUpdateByOthers&&r.supportsUpdateByAnonymous&&r.supportsDeleteByOthers&&r.supportsDeleteByAnonymous))return"load"}return this.userHasUpdateItemPrivileges?(0,C.uA)(this)?"load":this.hasUpdateItemRestrictions?e.operations.supportsQuery?"editing":"load":null:this.userHasFullEditingPrivileges&&this.hasFullEditingRestrictions?"editing":null}readCapabilitiesFromService(e,t){return(0,U.h)(t,this.url)}readEditingInfo(e,t){const{editingInfo:i}=t;return i?{lastEditDate:null!=i.lastEditDate?new Date(i.lastEditDate):null}:null}get effectiveCapabilities(){const e=this.capabilities;if(!e)return null;const t=(0,n.d9)(e),{operations:i,editing:r}=t;return this.sourceJSON?.isMultiServicesView?(this.userHasUpdateItemPrivileges&&(i.supportsQuery=!0),t):this.userHasUpdateItemPrivileges?(i.supportsAdd=i.supportsDelete=i.supportsEditing=i.supportsQuery=i.supportsUpdate=r.supportsDeleteByOthers=r.supportsGeometryUpdate=r.supportsUpdateByOthers=!0,t):(this.userHasFullEditingPrivileges&&i.supportsEditing&&(i.supportsAdd=i.supportsDelete=i.supportsUpdate=r.supportsGeometryUpdate=!0),t)}readGlobalIdFieldFromService(e,t){return(0,C.rk)(t)}get hasFullEditingRestrictions(){const e=this.capabilities;if(!e||this.sourceJSON?.isMultiServicesView)return!1;const{operations:t,editing:i}=e;return t.supportsEditing&&!(t.supportsAdd&&t.supportsDelete&&t.supportsUpdate&&i.supportsGeometryUpdate)}get hasUpdateItemRestrictions(){const e=this.capabilities;if(!e)return!1;const{operations:t,editing:i}=e;return this.sourceJSON?.isMultiServicesView?!t.supportsQuery:!(t.supportsAdd&&t.supportsDelete&&t.supportsEditing&&t.supportsQuery&&t.supportsUpdate&&i.supportsDeleteByOthers&&i.supportsGeometryUpdate&&i.supportsUpdateByOthers)}readIsTableFromService(e,t){return"Table"===t.type}readMaxScale(e,t){return t.effectiveMaxScale||e||0}readMinScale(e,t){return t.effectiveMinScale||e||0}readObjectIdFieldFromService(e,t){return(0,C.kZ)(t)}readServiceDefinitionExpression(e,t){return t.definitionQuery||t.definitionExpression}set url(e){const t=(0,m.XG)({layer:this,url:e,nonStandardUrlAllowed:!0,logger:s.Z.getLogger(this)});this._set("url",t.url),null!=t.layerId&&this._set("layerId",t.layerId)}writeUrl(e,t,i,r){(0,m.wH)(this,e,null,t,r)}readVersion(e,t){return(0,C.JY)(t)}};return(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"authenticationTriggerEvent",null),(0,r._)([(0,l.Cb)({type:String,json:{origins:{service:{read:{source:"copyrightText"}}}}})],t.prototype,"copyright",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,json:{read:!1,origins:{service:{read:{source:["advancedQueryCapabilities","allowGeometryUpdates","allowUpdateWithoutMValues","archivingInfo","capabilities","datesInUnknownTimezone","hasAttachments","hasM","hasZ","maxRecordCount","maxRecordCountFactor","ownershipBasedAccessControlForFeatures","standardMaxRecordCount","supportedQueryFormats","supportsAdvancedQueries","supportsApplyEditsWithGlobalIds","supportsAttachmentsByUploadId","supportsAttachmentsResizing","supportsCalculate","supportsCoordinatesQuantization","supportsExceedsLimitStatistics","supportsFieldDescriptionProperty","supportsQuantizationEditMode","supportsRollbackOnFailureParameter","supportsStatistics","supportsTruncate","supportsValidateSql","tileMaxRecordCount","useStandardizedQueries"]}}}}})],t.prototype,"capabilities",void 0),(0,r._)([(0,a.r)("service","capabilities")],t.prototype,"readCapabilitiesFromService",null),(0,r._)([(0,l.Cb)((0,w.mi)("dateFieldsTimeReference"))],t.prototype,"dateFieldsTimeZone",void 0),(0,r._)([(0,l.Cb)({type:Boolean})],t.prototype,"datesInUnknownTimezone",void 0),(0,r._)([(0,l.Cb)({type:String,json:{origins:{service:{read:!1,write:!1}},name:"layerDefinition.definitionExpression",write:{enabled:!0,allowNull:!0}}})],t.prototype,"definitionExpression",void 0),(0,r._)([(0,l.Cb)({type:String,json:{origins:{service:{read:{source:"displayField"}}}}})],t.prototype,"displayField",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,type:_})],t.prototype,"editFieldsInfo",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"editingInfo",void 0),(0,r._)([(0,a.r)("editingInfo")],t.prototype,"readEditingInfo",null),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"effectiveCapabilities",null),(0,r._)([(0,l.Cb)((()=>{const e=(0,n.d9)(f.PV),t=e.json.origins;return t["web-map"]={read:!1,write:!1},t["portal-item"]={read:!1,write:!1},e})())],t.prototype,"elevationInfo",void 0),(0,r._)([(0,l.Cb)({type:F.Z,json:{name:"layerDefinition.floorInfo",write:!0,origins:{"web-scene":{name:"layerDefinition.floorInfo",write:{enabled:!0,layerContainerTypes:u.C}}}}})],t.prototype,"floorInfo",void 0),(0,r._)([(0,l.Cb)({type:c.Z,json:{origins:{service:{read:{source:"extent"}}}}})],t.prototype,"fullExtent",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"gdbVersion",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,type:S,json:{read:{source:"geometryProperties"}}})],t.prototype,"geometryFieldsInfo",void 0),(0,r._)([(0,l.Cb)({type:["point","polygon","polyline","multipoint","multipatch","mesh"],json:{origins:{service:{read:C.Fr.read}}}})],t.prototype,"geometryType",void 0),(0,r._)([(0,l.Cb)({type:String})],t.prototype,"globalIdField",void 0),(0,r._)([(0,a.r)("service","globalIdField",["globalIdField","fields"])],t.prototype,"readGlobalIdFieldFromService",null),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"hasFullEditingRestrictions",null),(0,r._)([(0,l.Cb)({type:Boolean,json:{origins:{service:{read:!0}}}})],t.prototype,"hasM",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"hasUpdateItemRestrictions",null),(0,r._)([(0,l.Cb)({type:Boolean,json:{origins:{service:{read:!0}}}})],t.prototype,"hasZ",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,type:y.Z})],t.prototype,"heightModelInfo",void 0),(0,r._)([(0,l.Cb)({type:Date})],t.prototype,"historicMoment",void 0),(0,r._)([(0,l.Cb)({type:o.Z.ofType(x),readOnly:!0})],t.prototype,"indexes",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"isTable",void 0),(0,r._)([(0,a.r)("service","isTable",["type"])],t.prototype,"readIsTableFromService",null),(0,r._)([(0,l.Cb)({type:Number,json:{origins:{service:{read:{source:"id"}},"portal-item":{read:!1,write:{target:"id"}}},read:!1}})],t.prototype,"layerId",void 0),(0,r._)([(0,l.Cb)(f.u1)],t.prototype,"maxScale",void 0),(0,r._)([(0,a.r)("service","maxScale",["maxScale","effectiveMaxScale"])],t.prototype,"readMaxScale",null),(0,r._)([(0,l.Cb)(f.rO)],t.prototype,"minScale",void 0),(0,r._)([(0,a.r)("service","minScale",["minScale","effectiveMinScale"])],t.prototype,"readMinScale",null),(0,r._)([(0,l.Cb)({type:String})],t.prototype,"objectIdField",void 0),(0,r._)([(0,a.r)("service","objectIdField",["objectIdField","fields"])],t.prototype,"readObjectIdFieldFromService",null),(0,r._)([(0,l.Cb)((0,w.mi)("preferredTimeReference"))],t.prototype,"preferredTimeZone",void 0),(0,r._)([(0,l.Cb)({type:[R],readOnly:!0})],t.prototype,"relationships",void 0),(0,r._)([(0,l.Cb)({type:Boolean})],t.prototype,"returnM",void 0),(0,r._)([(0,l.Cb)({type:Boolean})],t.prototype,"returnZ",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,json:{write:!1}})],t.prototype,"serverGens",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"serviceDefinitionExpression",void 0),(0,r._)([(0,a.r)("service","serviceDefinitionExpression",["definitionQuery","definitionExpression"])],t.prototype,"readServiceDefinitionExpression",null),(0,r._)([(0,l.Cb)({type:String,readOnly:!0,json:{read:!1,origins:{service:{read:!0}}}})],t.prototype,"serviceItemId",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"sourceJSON",void 0),(0,r._)([(0,l.Cb)({type:h.Z,json:{origins:{service:{read:{source:"extent.spatialReference"}}}}})],t.prototype,"spatialReference",void 0),(0,r._)([(0,l.Cb)({type:String,readOnly:!0,json:{origins:{service:{read:!0}}}})],t.prototype,"subtypeField",void 0),(0,r._)([(0,l.Cb)({type:[A],readOnly:!0,json:{read:!1,origins:{service:{read:!0}}}})],t.prototype,"subtypes",void 0),(0,r._)([(0,l.Cb)({type:String,json:{read:{source:"timeInfo.trackIdField"}}})],t.prototype,"trackIdField",void 0),(0,r._)([(0,l.Cb)(f.HQ)],t.prototype,"url",null),(0,r._)([(0,d.c)("url")],t.prototype,"writeUrl",null),(0,r._)([(0,l.Cb)({json:{origins:{service:{read:!0}},read:!1}})],t.prototype,"version",void 0),(0,r._)([(0,a.r)("service","version",["currentVersion","capabilities","drawingInfo","hasAttachments","htmlPopupType","relationships","timeInfo","typeIdField","types"])],t.prototype,"readVersion",null),t=(0,r._)([(0,p.j)("esri.layers.mixins.FeatureLayerBase")],t),t}},28294:(e,t,i)=>{i.d(t,{n:()=>c});var r=i(43697),o=i(92835),n=i(84552),s=i(5600),l=(i(75215),i(67676),i(80442),i(71715)),a=i(52011),p=i(35671),d=i(76259),u=i(78981);const c=e=>{let t=class extends e{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 r=i.timeOffset,o=u.v.fromJSON(i.timeOffsetUnits);return r&&o?new n.Z({value:r,unit:o}):null}set timeInfo(e){(0,p.UF)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,r._)([(0,s.Cb)({type:o.Z,json:{write:!1}})],t.prototype,"timeExtent",void 0),(0,r._)([(0,s.Cb)({type:n.Z})],t.prototype,"timeOffset",void 0),(0,r._)([(0,l.r)("service","timeOffset",["timeInfo.exportOptions"])],t.prototype,"readOffset",null),(0,r._)([(0,s.Cb)({value:null,type:d.Z,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],t.prototype,"timeInfo",null),(0,r._)([(0,s.Cb)({type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation"},origins:{"web-scene":{read:!1,write:!1}}}})],t.prototype,"useViewTime",void 0),t=(0,r._)([(0,a.j)("esri.layers.mixins.TemporalLayer")],t),t}},76259:(e,t,i)=>{i.d(t,{Z:()=>m});var r=i(43697),o=i(92835),n=i(84552),s=i(2368),l=i(96674),a=i(5600),p=(i(75215),i(67676),i(80442),i(71715)),d=i(52011),u=i(30556),c=i(25031);function y(e,t){return n.Z.fromJSON({value:e,unit:t})}let h=class extends((0,s.J)(l.wq)){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}readFullTimeExtent(e,t){if(!t.timeExtent||!Array.isArray(t.timeExtent)||2!==t.timeExtent.length)return null;const i=new Date(t.timeExtent[0]),r=new Date(t.timeExtent[1]);return new o.Z({start:i,end:r})}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=[e.start.getTime(),e.end.getTime()]:t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?y(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?y(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,r._)([(0,a.Cb)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],h.prototype,"cumulative",void 0),(0,r._)([(0,a.Cb)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],h.prototype,"endField",void 0),(0,r._)([(0,a.Cb)({type:o.Z,json:{write:{enabled:!0,allowNull:!0}}})],h.prototype,"fullTimeExtent",void 0),(0,r._)([(0,p.r)("fullTimeExtent",["timeExtent"])],h.prototype,"readFullTimeExtent",null),(0,r._)([(0,u.c)("fullTimeExtent")],h.prototype,"writeFullTimeExtent",null),(0,r._)([(0,a.Cb)({type:Boolean,json:{write:!0}})],h.prototype,"hasLiveData",void 0),(0,r._)([(0,a.Cb)({type:n.Z,json:{write:{enabled:!0,allowNull:!0}}})],h.prototype,"interval",void 0),(0,r._)([(0,p.r)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],h.prototype,"readInterval",null),(0,r._)([(0,u.c)("interval")],h.prototype,"writeInterval",null),(0,r._)([(0,a.Cb)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],h.prototype,"startField",void 0),(0,r._)([(0,a.Cb)((0,c.mi)("timeReference",!0))],h.prototype,"timeZone",void 0),(0,r._)([(0,a.Cb)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],h.prototype,"trackIdField",void 0),(0,r._)([(0,a.Cb)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],h.prototype,"useTime",void 0),h=(0,r._)([(0,d.j)("esri.layers.support.TimeInfo")],h);const m=h},45574:(e,t,i)=>{i.d(t,{JD:()=>w,Jj:()=>x,sX:()=>N,Ob:()=>q,rP:()=>U,FV:()=>j,nU:()=>D,Ci:()=>I,Fr:()=>v,HW:()=>P,gG:()=>R,uA:()=>B,SU:()=>S,KE:()=>M,VG:()=>E,tD:()=>F,kp:()=>T,C9:()=>O,rk:()=>V,kZ:()=>Z,JY:()=>A,Y5:()=>_,uj:()=>C});var r=i(40330),o=i(9790),n=i(66643),s=i(20102),l=i(35454),a=i(42033),p=i(63213),d=i(14165);async function u(e,t,i){t=t.clone(),e.capabilities.query.supportsMaxRecordCountFactor&&(t.maxRecordCountFactor=c(e));const r=function(e){return c(e)*function(e){return e.capabilities.query.maxRecordCount||2e3}(e)}(e),o=e.capabilities.query.supportsPagination;t.start=0,t.num=r;let n=null;for(;;){const s=await e.source.queryFeaturesJSON(t,i);if(null==n?n=s:n.features=n.features.concat(s.features),n.exceededTransferLimit=s.exceededTransferLimit,!o||!s.exceededTransferLimit)break;t.start+=r}return n}function c(e){return e.capabilities.query.supportsMaxRecordCountFactor?d.Z.MAX_MAX_RECORD_COUNT_FACTOR:1}var y=i(84230),h=i(84382),m=i(81571),f=i(56545),b=i(75935);const v=new l.X({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryMultiPatch:"multipatch"});async function w(e,t,i,r){const o=await k(e);if(await g(e,t,r),!o.addAttachment)throw new s.Z(r,"Layer source does not support addAttachment capability");return o.addAttachment(t,i)}function g(e,t,i){const{attributes:r}=t,{objectIdField:o}=e;return e.capabilities?.data?.supportsAttachment?t?r?o&&r[o]?Promise.resolve():Promise.reject(new s.Z(i,`feature is missing the identifying attribute ${o}`)):Promise.reject(new s.Z(i,"'attributes' are required on a feature to query attachments")):Promise.reject(new s.Z(i,"A feature is required to add/delete/update attachments")):Promise.reject(new s.Z(i,"this layer doesn't support attachments"))}async function _(e,t,i,r,o){const n=await k(e);if(await g(e,t,o),!n.updateAttachment)throw new s.Z(o,"Layer source does not support updateAttachment capability");return n.updateAttachment(t,i,r)}async function x(e,t,r){const{applyEdits:o}=await i.e(4720).then(i.bind(i,14720)),n=await e.load(),{source:s,globalIdField:l}=n;let a=r;return("feature"===n.type?n.infoFor3D:null)&&null!=t.deleteFeatures&&null!=l&&(a={...a,globalIdToObjectId:await P(e,t.deleteFeatures,l)}),o(n,s,t,r)}async function C(e,t,r){const{uploadAssets:o}=await i.e(4720).then(i.bind(i,14720)),n=await e.load();return o(n,n.source,t,r)}async function j(e,t,i,r){const o=await k(e);if(await g(e,t,r),!o.deleteAttachments)throw new s.Z(r,"Layer source does not support deleteAttachments capability");return o.deleteAttachments(t,i)}async function I(e,t,i){const r=(await e.load({signal:t?.signal})).source;if(!r.fetchRecomputedExtents)throw new s.Z(i,"Layer source does not support fetchUpdates capability");return r.fetchRecomputedExtents(t)}async function S(e,t,i,r){t=f.Z.from(t),await e.load();const o=e.source,n=e.capabilities;if(!n?.data?.supportsAttachment)throw new s.Z(r,"this layer doesn't support attachments");const{attachmentTypes:l,objectIds:a,globalIds:p,num:d,size:u,start:c,where:y}=t;if(!n?.operations?.supportsQueryAttachments&&(l?.length>0||p?.length>0||u?.length>0||d||c||y))throw new s.Z(r,"when 'capabilities.operations.supportsQueryAttachments' is false, only objectIds is supported",t);if(!(a?.length||p?.length||y))throw new s.Z(r,"'objectIds', 'globalIds', or 'where' are required to perform attachment query",t);if(!o.queryAttachments)throw new s.Z(r,"Layer source does not support queryAttachments capability",t);return o.queryAttachments(t)}async function F(e,t,i,r){const o=await k(e);if(!o.queryObjectIds)throw new s.Z(r,"Layer source does not support queryObjectIds capability");return o.queryObjectIds(d.Z.from(t)??e.createQuery(),i)}async function E(e,t,i,r){const o=await k(e);if(!o.queryFeatureCount)throw new s.Z(r,"Layer source does not support queryFeatureCount capability");return o.queryFeatureCount(d.Z.from(t)??e.createQuery(),i)}async function M(e,t,i,r){const o=await k(e);if(!o.queryExtent)throw new s.Z(r,"Layer source does not support queryExtent capability");return o.queryExtent(d.Z.from(t)??e.createQuery(),i)}async function T(e,t,i,r){const o=await k(e);if(!o.queryRelatedFeatures)throw new s.Z(r,"Layer source does not support queryRelatedFeatures capability");return o.queryRelatedFeatures(b.default.from(t),i)}async function O(e,t,i,r){const o=await k(e);if(!o.queryRelatedFeaturesCount)throw new s.Z(r,"Layer source does not support queryRelatedFeaturesCount capability");return o.queryRelatedFeaturesCount(b.default.from(t),i)}async function R(e){const t=e.source;if(t?.refresh)try{const{dataChanged:i,updates:r}=await t.refresh();if(null!=r&&(e.sourceJSON={...e.sourceJSON,...r},e.read(r,{origin:"service",url:e.parsedUrl})),i)return!0}catch{}if(e.definitionExpression)try{return(await(0,a.E)(e.definitionExpression,e.fieldsIndex)).hasDateFunctions}catch{}return!1}function U(e){const t=new d.Z,i=e.capabilities?.data,r=e.capabilities?.query;t.historicMoment=e.historicMoment,t.gdbVersion=e.gdbVersion,t.returnGeometry=!0,r&&(t.compactGeometryEnabled=r.supportsCompactGeometry,t.defaultSpatialReferenceEnabled=r.supportsDefaultSpatialReference),i&&(i.supportsZ&&null!=e.returnZ&&(t.returnZ=e.returnZ),i.supportsM&&null!=e.returnM&&(t.returnM=e.returnM)),t.outFields=["*"];const{timeOffset:o,timeExtent:n}=e;return t.timeExtent=null!=o&&null!=n?n.offset(-o.value,o.unit):n||null,t.multipatchOption="multipatch"===e.geometryType?"xyFootprint":null,t}function V(e){const{globalIdField:t,fields:i}=e;if(t)return t;if(i)for(const e of i)if("esriFieldTypeGlobalID"===e.type)return e.name}function Z(e){const{objectIdField:t,fields:i}=e;if(t)return t;if(i)for(const e of i)if("esriFieldTypeOID"===e.type)return e.name}function A(e){return e.currentVersion?e.currentVersion:e.hasOwnProperty("capabilities")||e.hasOwnProperty("drawingInfo")||e.hasOwnProperty("hasAttachments")||e.hasOwnProperty("htmlPopupType")||e.hasOwnProperty("relationships")||e.hasOwnProperty("timeInfo")||e.hasOwnProperty("typeIdField")||e.hasOwnProperty("types")?10:9.3}async function k(e){return(await e.load()).source}async function D(e,t,i){const o=e.parsedUrl?.path;o&&e.authenticationTriggerEvent===t&&await async function(e,t){if(!r.id)return;if(r.id.findCredential(e))return;let i;try{const o=await(0,y.oP)(e,t);o&&(i=await r.id.checkSignInStatus(`${o}/sharing`))}catch(e){}if(i)try{const i=null!=t?t.signal:null;await r.id.getCredential(e,{signal:i})}catch(e){}}(o,i)}function N(e){return!e.sourceJSON?.isMultiServicesView&&(e.userHasUpdateItemPrivileges||e.editingEnabled)}const L=(0,p.d)({types:o.QT});function q(e,t){if(e.defaultSymbol)return e.types?.length?new m.Z({defaultSymbol:L(e.defaultSymbol,e,t),field:e.typeIdField,uniqueValueInfos:e.types.map((e=>({id:e.id,symbol:L(e.symbol,e,t)})))}):new h.Z({symbol:L(e.defaultSymbol,e,t)})}function B(e){let t=e.sourceJSON?.cacheMaxAge;if(!t)return!1;const i=e.editingInfo?.lastEditDate?.getTime();return null==i||(t*=1e3,Date.now()-i<t)}async function P(e,t,i){if(null==t)return null;const r=[],{objectIdField:o}=e;if(t.forEach((e=>{let t=null;if("attributes"in e){const{attributes:r}=e;t={globalId:r[i],objectId:null!=r[o]&&-1!==r[o]?r[o]:null}}else t={globalId:e.globalId,objectId:null!=e.objectId&&-1!==e.objectId?e.objectId:null};null!=t.globalId&&(null!=t.objectId&&-1!==t.objectId||r.push(t.globalId))})),0===r.length)return null;const s=e.createQuery();s.where=r.map((e=>`${i}='${e}'`)).join(" OR "),s.returnGeometry=!1,s.outFields=[o,i],s.cacheHint=!1;const l=await(0,n.mt)(u(e,s));if(!l.ok)return null;const a=new Map,p=l.value.features;for(const e of p){const t=e.attributes[i],r=e.attributes[o];null!=t&&null!=r&&-1!==r&&a.set(t,r)}return a}},53518:(e,t,i)=>{i.d(t,{v:()=>a});var r=i(80442),o=i(92604),n=i(1231),s=i(99514),l=i(35671);function a(){return{fields:{type:[n.Z],value:null,set:function(e){if(e&&(0,r.Z)("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(", ");o.Z.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 s.Z.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||o.Z.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,l.Q0)(this.fieldsIndex,e)}}}}},60199:(e,t,i)=>{i.d(t,{D:()=>n});var r=i(66677);const o=[];function n(e,t){if((0,r.M8)(e.url??""))return!0;const{wkid:i}=t;for(const t of o){if((e.version??0)>=t[0])return!0;if("function"==typeof t[1]&&(t[1]=t[1]()),t[1].has(i))return!1}return!0}o.push([10.91,()=>{const e=new Set([9709,9716,9741,9761,9766]);for(let t=9712;t<=9713;t++)e.add(t);for(let t=9748;t<=9749;t++)e.add(t);for(let t=20904;t<=20932;t++)e.add(t);for(let t=21004;t<=21032;t++)e.add(t);for(let t=21207;t<=21264;t++)e.add(t);for(let t=21307;t<=21364;t++)e.add(t);for(let t=23301;t<=23333;t++)e.add(t);for(let t=102759;t<=102760;t++)e.add(t);for(let t=102934;t<=102955;t++)e.add(t);return e}]),o.push([10.9,()=>{const e=new Set([9300,9354,9364,9367,9373,9377,9387,9456,9473,9498,9678,9680,29874,103599,103872,104028]);for(let t=9356;t<=9360;t++)e.add(t);for(let t=9404;t<=9407;t++)e.add(t);for(let t=9476;t<=9482;t++)e.add(t);for(let t=9487;t<=9494;t++)e.add(t);for(let t=9697;t<=9699;t++)e.add(t);return e}]),o.push([10.81,()=>{const e=new Set([9265,9333,103598,103699]);for(let t=9248;t<=9254;t++)e.add(t);for(let t=9271;t<=9273;t++)e.add(t);for(let t=9284;t<=9285;t++)e.add(t);for(let t=21453;t<=21463;t++)e.add(t);return e}]),o.push([10.8,()=>{const e=new Set([8088,8395,8428,8433,8531,8687,8692,8694,8699,8900,9003,9006,9009,9012,9017,9191]);for(let t=8035;t<=8036;t++)e.add(t);for(let t=8455;t<=8456;t++)e.add(t);for(let t=8518;t<=8529;t++)e.add(t);for(let t=8533;t<=8536;t++)e.add(t);for(let t=8538;t<=8540;t++)e.add(t);for(let t=8677;t<=8679;t++)e.add(t);for(let t=8902;t<=8903;t++)e.add(t);for(let t=8907;t<=8910;t++)e.add(t);for(let t=8949;t<=8951;t++)e.add(t);for(let t=8972;t<=8987;t++)e.add(t);for(let t=9039;t<=9040;t++)e.add(t);for(let t=9068;t<=9069;t++)e.add(t);for(let t=9140;t<=9141;t++)e.add(t);for(let t=9148;t<=9150;t++)e.add(t);for(let t=9153;t<=9159;t++)e.add(t);for(let t=9205;t<=9218;t++)e.add(t);for(let t=9221;t<=9222;t++)e.add(t);for(let t=54098;t<=54101;t++)e.add(t);return e}]),o.push([10.71,()=>{const e=new Set([6316]);for(let t=8351;t<=8353;t++)e.add(t);for(let t=9294;t<=9297;t++)e.add(t);for(let t=22619;t<=22621;t++)e.add(t);for(let t=103586;t<=103594;t++)e.add(t);return e}]),o.push([10.7,()=>{const e=new Set([8387,8391,8427,8545,8682,8685,8818,31370,104022,104024,104975]);for(let t=8065;t<=8068;t++)e.add(t);for(let t=8082;t<=8083;t++)e.add(t);for(let t=8379;t<=8385;t++)e.add(t);for(let t=8836;t<=8840;t++)e.add(t);for(let t=8857;t<=8860;t++)e.add(t);for(let t=53035;t<=53037;t++)e.add(t);for(let t=54090;t<=54091;t++)e.add(t);for(let t=102498;t<=102499;t++)e.add(t);return e}]),o.push([10.61,()=>new Set([102497])]),o.push([10.6,()=>{const e=new Set([7803,7805,7887,8086,8232,8237,8240,8246,8249,8252,8255,9019,9391]);for(let t=7755;t<=7787;t++)e.add(t);for(let t=7791;t<=7795;t++)e.add(t);for(let t=7799;t<=7801;t++)e.add(t);for(let t=7825;t<=7831;t++)e.add(t);for(let t=7877;t<=7878;t++)e.add(t);for(let t=7882;t<=7883;t++)e.add(t);for(let t=7991;t<=7992;t++)e.add(t);for(let t=8042;t<=8043;t++)e.add(t);for(let t=8058;t<=8059;t++)e.add(t);for(let t=8311;t<=8348;t++)e.add(t);for(let t=9060;t<=9067;t++)e.add(t);for(let t=102562;t<=102568;t++)e.add(t);for(let t=102799;t<=102900;t++)e.add(t);return e}])},78981:(e,t,i)=>{i.d(t,{v:()=>r});const r=(0,i(35454).w)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},75935:(e,t,i)=>{i.r(t),i.d(t,{default:()=>h});var r,o=i(43697),n=(i(66577),i(96674)),s=i(22974),l=i(5600),a=i(75215),p=i(52011),d=i(30556),u=i(10158),c=i(82971);let y=r=class extends n.wq{constructor(e){super(e),this.cacheHint=void 0,this.dynamicDataSource=void 0,this.gdbVersion=null,this.geometryPrecision=void 0,this.historicMoment=null,this.maxAllowableOffset=void 0,this.objectIds=null,this.orderByFields=null,this.outFields=null,this.outSpatialReference=null,this.relationshipId=void 0,this.start=void 0,this.num=void 0,this.returnGeometry=!1,this.returnM=void 0,this.returnZ=void 0,this.where=null}_writeHistoricMoment(e,t){t.historicMoment=e&&e.getTime()}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10,this.start>0&&null==this.where&&(t.definitionExpression="1=1")}clone(){return new r((0,s.d9)({cacheHint:this.cacheHint,dynamicDataSource:this.dynamicDataSource,gdbVersion:this.gdbVersion,geometryPrecision:this.geometryPrecision,historicMoment:this.historicMoment&&new Date(this.historicMoment.getTime()),maxAllowableOffset:this.maxAllowableOffset,objectIds:this.objectIds,orderByFields:this.orderByFields,outFields:this.outFields,outSpatialReference:this.outSpatialReference,relationshipId:this.relationshipId,start:this.start,num:this.num,returnGeometry:this.returnGeometry,where:this.where,returnZ:this.returnZ,returnM:this.returnM}))}};(0,o._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],y.prototype,"cacheHint",void 0),(0,o._)([(0,l.Cb)({type:u.n,json:{write:!0}})],y.prototype,"dynamicDataSource",void 0),(0,o._)([(0,l.Cb)({type:String,json:{write:!0}})],y.prototype,"gdbVersion",void 0),(0,o._)([(0,l.Cb)({type:Number,json:{write:!0}})],y.prototype,"geometryPrecision",void 0),(0,o._)([(0,l.Cb)({type:Date})],y.prototype,"historicMoment",void 0),(0,o._)([(0,d.c)("historicMoment")],y.prototype,"_writeHistoricMoment",null),(0,o._)([(0,l.Cb)({type:Number,json:{write:!0}})],y.prototype,"maxAllowableOffset",void 0),(0,o._)([(0,l.Cb)({type:[Number],json:{write:!0}})],y.prototype,"objectIds",void 0),(0,o._)([(0,l.Cb)({type:[String],json:{write:!0}})],y.prototype,"orderByFields",void 0),(0,o._)([(0,l.Cb)({type:[String],json:{write:!0}})],y.prototype,"outFields",void 0),(0,o._)([(0,l.Cb)({type:c.Z,json:{read:{source:"outSR"},write:{target:"outSR"}}})],y.prototype,"outSpatialReference",void 0),(0,o._)([(0,l.Cb)({json:{write:!0}})],y.prototype,"relationshipId",void 0),(0,o._)([(0,l.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],y.prototype,"start",void 0),(0,o._)([(0,d.c)("start"),(0,d.c)("num")],y.prototype,"writeStart",null),(0,o._)([(0,l.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],y.prototype,"num",void 0),(0,o._)([(0,l.Cb)({json:{write:!0}})],y.prototype,"returnGeometry",void 0),(0,o._)([(0,l.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],y.prototype,"returnM",void 0),(0,o._)([(0,l.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],y.prototype,"returnZ",void 0),(0,o._)([(0,l.Cb)({type:String,json:{read:{source:"definitionExpression"},write:{target:"definitionExpression"}}})],y.prototype,"where",void 0),y=r=(0,o._)([(0,p.j)("esri.rest.support.RelationshipQuery")],y),y.from=(0,a.se)(y);const h=y},18596:(e,t,i)=>{i.d(t,{JV:()=>l,Jp:()=>o,Px:()=>s,U8:()=>r});const r=(0,i(41123).z)(),o=new Map,n=new Map;async function s(e,t,o=!1){if(!e||!t)return!0;const s=e.replace(/\/FeatureServer/i,"/VersionManagementServer").replace(/\/\d*$/,""),l=n.get(s)?.entries();if(l)for(const[e,n]of l)if(n.name===t){const t=!n.stack?.hasForwardEdits();if(!t&&o){const[{deleteForwardEdits:t},{default:o}]=await Promise.all([i.e(1316).then(i.bind(i,51316)),i.e(4573).then(i.bind(i,84573))]);return t(s,e,new o({sessionId:r,moment:n.moment}))}return t}return!0}function l(e,t){if(!e)return!1;const i=e.replace(/\/FeatureServer/i,"/VersionManagementServer").replace(/\/\d*$/,""),r=n.get(i)?.entries();if(r)for(const[e,i]of r)if(i.name===t)return"edit"===i.lockType;return!1}new Map},12259:(e,t,i)=>{var r;i.d(t,{x:()=>r}),function(e){e[e.SAVE=0]="SAVE",e[e.SAVE_AS=1]="SAVE_AS"}(r||(r={}))}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4697],{65845:(e,t,r)=>{r.d(t,{D:()=>i});var a=r(81153);function i(e){e?.writtenProperties&&e.writtenProperties.forEach((({target:e,propName:t,newOrigin:r})=>{(0,a.l)(e)&&r&&e.originOf(t)!==r&&e.updateOrigin(t,r)}))}},81153:(e,t,r)=>{function a(e){return e&&"getAtOrigin"in e&&"originOf"in e}r.d(t,{l:()=>a})},64697:(e,t,r)=>{r.d(t,{save:()=>c,saveAs:()=>d});var a=r(64383),i=r(14661);const n="Image Service",o="imagery-layer-save",l="imagery-layer-save-as",s="imagery-tile-layer-save",p="imagery-tile-layer-save-as";function u(e){if("imagery"===e.type)return{isValid:!0};const{raster:t}=e,r="Function"===t?.datasetFormat?t.primaryRasters?.rasters[0]:t;return{isValid:"RasterTileServer"===r?.datasetFormat&&("Raster"===r.tileType||"Map"===r.tileType),errorMessage:"imagery tile layer should be created from a tiled image service."}}function m(e){const t=e.layerJSON;return Promise.resolve(t&&Object.keys(t).length?t:null)}async function y(e,t){const{parsedUrl:r,title:a,fullExtent:n}=e;t.url=r.path,t.title||=a,t.extent=await(0,i.$o)(n),"imagery-tile"===e.type&&(0,i.qj)(t,i.Kz.TILED_IMAGERY)}async function c(e,t){const r="imagery"===e.type?o:s;return(0,a.a1)({layer:e,itemType:n,validateLayer:u,createItemData:m,errorNamePrefix:r},t)}async function d(e,t,r){const i="imagery"===e.type?l:p;return(0,a.po)({layer:e,itemType:n,validateLayer:u,createItemData:m,errorNamePrefix:i,newItem:t,setItemProperties:y},r)}},64383:(e,t,r)=>{r.d(t,{a1:()=>g,po:()=>v});var a=r(20102),i=r(65845),n=r(48522),o=r(15235),l=r(33516),s=r(14661),p=r(14769);async function u(e){const{layer:t,errorNamePrefix:r,validateLayer:i}=e;await t.load(),function(e,t,r){const i=r(e);if(!i.isValid)throw new a.Z(`${t}:invalid-parameters`,i.errorMessage,{layer:e})}(t,r,i)}function m(e,t){return`Layer (title: ${e.title}, id: ${e.id}) of type '${e.declaredClass}' ${t}`}function y(e){const{item:t,itemType:r,errorNamePrefix:i,layer:n,validateItem:o}=e;if((0,p.w)(t),t.type!==r)throw new a.Z(`${i}:portal-item-wrong-type`,`Portal item type should be "${r}"`,{item:t,layer:n});if(o){const e=o(t);if(!e.isValid)throw new a.Z(`${i}:invalid-parameters`,e.errorMessage,{layer:n})}}function c(e){const{layer:t,errorNamePrefix:r}=e,{portalItem:i}=t;if(!i)throw new a.Z(`${r}:portal-item-not-set`,m(t,"requires the portalItem property to be set"));if(!i.loaded)throw new a.Z(`${r}:portal-item-not-loaded`,m(t,"cannot be saved to a portal item that does not exist or is inaccessible"));y({...e,item:i})}function d(e){const{newItem:t,itemType:r}=e;let a=o.default.from(t);return a.id&&(a=a.clone(),a.id=null),a.type??=r,a.portal??=n.Z.getDefault(),y({...e,item:a}),a}async function f(e,t,r){"beforeSave"in e&&"function"==typeof e.beforeSave&&await e.beforeSave();const i=e.write({},t);return function(e,t){let r=(e.messages??[]).filter((({type:e})=>"error"===e)).map((({name:e,message:t,details:r})=>new a.Z(e,t,r)));if(t?.ignoreUnsupported&&(r=r.filter((({name:e})=>"layer:unsupported"!==e&&"symbol:unsupported"!==e&&"symbol-layer:unsupported"!==e&&"property:unsupported"!==e&&"url:unsupported"!==e))),r.length>0)throw new a.Z("layer-write:unsupported","Failed to save layer due to unsupported or invalid content. See 'details.errors' for more detailed information",{errors:r})}(t,r),i}function w(e){(0,s.qj)(e,s.Kz.JSAPI),e.typeKeywords&&(e.typeKeywords=e.typeKeywords.filter(((e,t,r)=>r.indexOf(e)===t)))}async function g(e,t){const{layer:r,createItemData:a,createJSONContext:n}=e;await u(e),c(e);const o=r.portalItem,s=n?n(o):(0,l.Yv)(o),p=await f(r,s,t),m=await a({layer:r,layerJSON:p},o);return w(o),await o.update({data:m}),(0,i.D)(s),o}async function v(e,t){const{layer:r,createItemData:a,createJSONContext:n,setItemProperties:o}=e;await u(e);const s=d(e),p=n?n(s):(0,l.Yv)(s),m=await f(r,p,t),y=await a({layer:r,layerJSON:m},s);return await o(r,s),w(s),await async function(e,t,r){const a=e.portal;await a.signIn(),await(a.user?.addItem({item:e,data:t,folder:r?.folder}))}(s,y,t),r.portalItem=s,(0,i.D)(p),s}},33516:(e,t,r)=>{r.d(t,{M4:()=>s,Yv:()=>o,ht:()=>n,wk:()=>l});var a=r(17452),i=r(48522);function n(e){return{origin:"portal-item",url:(0,a.mN)(e.itemUrl),portal:e.portal||i.Z.getDefault(),portalItem:e,readResourcePaths:[]}}function o(e){return{origin:"portal-item",messages:[],writtenProperties:[],url:e.itemUrl?(0,a.mN)(e.itemUrl):null,portal:e.portal||i.Z.getDefault(),portalItem:e}}function l(e){return{origin:"web-map",url:(0,a.mN)(e.itemUrl),portal:e.portal||i.Z.getDefault(),portalItem:e,readResourcePaths:[]}}function s(e){return{origin:"web-map",messages:[],writtenProperties:[],url:e.itemUrl?(0,a.mN)(e.itemUrl):null,portal:e.portal||i.Z.getDefault(),portalItem:e}}},14769:(e,t,r)=>{r.d(t,{w:()=>o});var a=r(68773),i=r(20102),n=r(71058);function o(e){if(a.default.apiKey&&(0,n.r)(e.portal.url))throw new i.Z("save-api-key-utils:api-key-not-supported",`Saving is not supported on ${e.portal.url} when using an api key`)}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3794,8592],{48853:(e,t,s)=>{s.d(t,{Qn:()=>d,iG:()=>h});var i,r=s(19153),n=s(1542),a=s(17126);(i||(i={})).TimeZoneNotRecognized="TimeZoneNotRecognized";const o={[i.TimeZoneNotRecognized]:"Timezone identifier has not been recognized."};class l extends Error{constructor(e,t){super((0,r.gx)(o[e],t)),this.declaredRootClass="esri.arcade.arcadedate.dateerror",Error.captureStackTrace&&Error.captureStackTrace(this,l)}}function u(e,t,s){return e<t?e-t:e>s?e-s:0}function c(e,t,s){return e<t?t:e>s?s:e}class h{constructor(e){this._date=e,this.declaredRootClass="esri.arcade.arcadedate"}static fromParts(e=0,t=1,s=1,i=0,r=0,n=0,o=0,l){if(isNaN(e)||isNaN(t)||isNaN(s)||isNaN(i)||isNaN(r)||isNaN(n)||isNaN(o))return null;const m=a.ou.local(e,t).daysInMonth;let f=a.ou.fromObject({day:c(s,1,m),year:e,month:c(t,1,12),hour:c(i,0,23),minute:c(r,0,59),second:c(n,0,59),millisecond:c(o,0,999)},{zone:d(l)});return f=f.plus({months:u(t,1,12),days:u(s,1,m),hours:u(i,0,23),minutes:u(r,0,59),seconds:u(n,0,59),milliseconds:u(o,0,999)}),new h(f)}static get systemTimeZoneCanonicalName(){return Intl.DateTimeFormat().resolvedOptions().timeZone??"system"}static arcadeDateAndZoneToArcadeDate(e,t){const s=d(t);return e.isUnknownTimeZone||s===n.yV.instance?h.fromParts(e.year,e.monthJS+1,e.day,e.hour,e.minute,e.second,e.millisecond,s):new h(e._date.setZone(s))}static dateJSToArcadeDate(e){return new h(a.ou.fromJSDate(e,{zone:"system"}))}static dateJSAndZoneToArcadeDate(e,t="system"){const s=d(t);return new h(a.ou.fromJSDate(e,{zone:s}))}static unknownEpochToArcadeDate(e){return new h(a.ou.fromMillis(e,{zone:n.yV.instance}))}static unknownDateJSToArcadeDate(e){return new h(a.ou.fromMillis(e.getTime(),{zone:n.yV.instance}))}static epochToArcadeDate(e,t="system"){const s=d(t);return new h(a.ou.fromMillis(e,{zone:s}))}static dateTimeToArcadeDate(e){return new h(e)}clone(){return new h(this._date)}changeTimeZone(e){const t=d(e);return h.dateTimeToArcadeDate(this._date.setZone(t))}static dateTimeAndZoneToArcadeDate(e,t){const s=d(t);return e.zone===n.yV.instance||s===n.yV.instance?h.fromParts(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond,s):new h(e.setZone(s))}static nowToArcadeDate(e){const t=d(e);return new h(a.ou.fromJSDate(new Date,{zone:t}))}static nowUTCToArcadeDate(){return new h(a.ou.utc())}get isSystem(){return"system"===this.timeZone||this.timeZone===h.systemTimeZoneCanonicalName}equals(e){return this.isSystem&&e.isSystem?this.toNumber()===e.toNumber():this.isUnknownTimeZone===e.isUnknownTimeZone&&this._date.equals(e._date)}get isUnknownTimeZone(){return this._date.zone===n.yV.instance}get isValid(){return this._date.isValid}get hour(){return this._date.hour}get second(){return this._date.second}get day(){return this._date.day}get dayOfWeekISO(){return this._date.weekday}get dayOfWeekJS(){let e=this._date.weekday;return e>6&&(e=0),e}get millisecond(){return this._date.millisecond}get monthISO(){return this._date.month}get weekISO(){return this._date.weekNumber}get yearISO(){return this._date.weekYear}get monthJS(){return this._date.month-1}get year(){return this._date.year}get minute(){return this._date.minute}get zone(){return this._date.zone}get timeZoneOffset(){return this.isUnknownTimeZone?0:this._date.offset}get timeZone(){if(this.isUnknownTimeZone)return"unknown";if("system"===this._date.zone.type)return"system";const e=this.zone;return"fixed"===e.type?0===e.fixed?"UTC":e.formatOffset(0,"short"):e.name}stringify(){return JSON.stringify(this.toJSDate())}plus(e){return new h(this._date.plus(e))}diff(e,t="milliseconds"){return this._date.diff(e._date,t)[t]}toISOString(e){return e?this._date.toISO({suppressMilliseconds:!0,includeOffset:!this.isUnknownTimeZone}):this._date.toISO({includeOffset:!this.isUnknownTimeZone})}toFormat(e,t){return this.isUnknownTimeZone&&(e=e.replaceAll("Z","")),this._date.toFormat(e,t)}toJSDate(){return this._date.toJSDate()}toSQLValue(){return this._date.toFormat("yyyy-LL-dd HH:mm:ss")}toSQLWithKeyword(){return`timestamp '${this.toSQLValue()}'`}toDateTime(){return this._date}toNumber(){return this._date.toMillis()}getTime(){return this._date.toMillis()}toUTC(){return new h(this._date.toUTC())}toLocal(){return new h(this._date.toLocal())}toString(){return this.toISOString(!0)}static fromReaderAsTimeStampOffset(e){if(!e)return null;const t=a.ou.fromISO(e,{setZone:!0});return new h(t)}}function d(e,t=!0){if(e instanceof a.ld)return e;if("system"===e.toLowerCase())return"system";if("utc"===e.toLowerCase())return"UTC";if("unknown"===e.toLowerCase())return n.yV.instance;if(/^[\+\-]?[0-9]{1,2}([:][0-9]{2})?$/.test(e)){const t=a.Qf.parseSpecifier("UTC"+(e.startsWith("+")||e.startsWith("-")?"":"+")+e);if(t)return t}const s=a.vF.create(e);if(!s.isValid){if(t)throw new l(i.TimeZoneNotRecognized);return null}return s}},77286:(e,t,s)=>{s.d(t,{EI:()=>r,Lz:()=>a,SV:()=>n,U:()=>l,r1:()=>o});var i=s(6570);function r(e){if(null==e)return null;if("number"==typeof e)return e;let t=e.toLowerCase();switch(t=t.replaceAll(/\s/g,""),t=t.replaceAll("-",""),t){case"meters":case"meter":case"m":case"squaremeters":case"squaremeter":return 109404;case"miles":case"mile":case"squaremile":case"squaremiles":return 109439;case"kilometers":case"kilometer":case"squarekilometers":case"squarekilometer":case"km":return 109414;case"acres":case"acre":case"ac":return 109402;case"hectares":case"hectare":case"ha":return 109401;case"yard":case"yd":case"yards":case"squareyards":case"squareyard":return 109442;case"feet":case"ft":case"foot":case"squarefeet":case"squarefoot":return 109405;case"nmi":case"nauticalmile":case"nauticalmiles":case"squarenauticalmile":case"squarenauticalmiles":return 109409}return null}function n(e){if(null==e)return null;switch(e.type){case"polygon":case"multipoint":case"polyline":return e.extent;case"point":return new i.Z({xmin:e.x,ymin:e.y,xmax:e.x,ymax:e.y,spatialReference:e.spatialReference});case"extent":return e}return null}function a(e){if(null==e)return null;if("number"==typeof e)return e;let t=e.toLowerCase();switch(t=t.replaceAll(/\s/g,""),t=t.replaceAll("-",""),t){case"meters":case"meter":case"m":case"squaremeters":case"squaremeter":return 9001;case"miles":case"mile":case"squaremile":case"squaremiles":return 9093;case"kilometers":case"kilometer":case"squarekilometers":case"squarekilometer":case"km":return 9036;case"yard":case"yd":case"yards":case"squareyards":case"squareyard":return 9096;case"feet":case"ft":case"foot":case"squarefeet":case"squarefoot":return 9002;case"nmi":case"nauticalmile":case"nauticalmiles":case"squarenauticalmile":case"squarenauticalmiles":return 9030}return null}function o(e){if(null==e)return null;const t=e.clone();return void 0!==e.cache._geVersion&&(t.cache._geVersion=e.cache._geVersion),t}function l(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e}},88764:(e,t,s)=>{s.d(t,{q:()=>l});var i,r,n,a=s(5732),o={exports:{}};i=o,r=function(){function e(s,i,r,n,a){for(;n>r;){if(n-r>600){var o=n-r+1,l=i-r+1,u=Math.log(o),c=.5*Math.exp(2*u/3),h=.5*Math.sqrt(u*c*(o-c)/o)*(l-o/2<0?-1:1);e(s,i,Math.max(r,Math.floor(i-l*c/o+h)),Math.min(n,Math.floor(i+(o-l)*c/o+h)),a)}var d=s[i],m=r,f=n;for(t(s,r,i),a(s[n],d)>0&&t(s,r,n);m<f;){for(t(s,m,f),m++,f--;a(s[m],d)<0;)m++;for(;a(s[f],d)>0;)f--}0===a(s[r],d)?t(s,r,f):t(s,++f,n),f<=i&&(r=f+1),i<=f&&(n=f-1)}}function t(e,t,s){var i=e[t];e[t]=e[s],e[s]=i}function s(e,t){return e<t?-1:e>t?1:0}return function(t,i,r,n,a){e(t,i,r||0,n||t.length-1,a||s)}},void 0!==(n=r())&&(i.exports=n);const l=(0,a.g)(o.exports)},95528:(e,t,s)=>{s.d(t,{t:()=>o});var i=s(22974),r=s(58971),n=s(10661);class a{constructor(e,t){this._observable=new n.s,this._value=e,this._equalityFunction=t}get value(){return(0,r.it)(this._observable),this._value}set value(e){this._equalityFunction(e,this._value)||(this._value=e,this._observable.notify())}mutate(e){e(this._value),this._observable.notify()}}function o(e,t=i.y7){return new a(e,t)}},22641:(e,t,s)=>{s.d(t,{u:()=>o});var i=s(48853),r=s(70171),n=s(17126);function a(e){e=e.replaceAll(/LTS|LT|LL?L?L?|l{1,4}/g,"[$&]");let t="";const s=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g;for(const i of e.match(s)||[])switch(i){case"D":t+="d";break;case"DD":t+="dd";break;case"DDD":t+="o";break;case"d":t+="c";break;case"ddd":t+="ccc";break;case"dddd":t+="cccc";break;case"M":t+="L";break;case"MM":t+="LL";break;case"MMM":t+="LLL";break;case"MMMM":t+="LLLL";break;case"YY":t+="yy";break;case"Y":case"YYYY":t+="yyyy";break;case"Q":t+="q";break;case"X":case"x":t+=i;break;default:i.length>=2&&"["===i.slice(0,1)&&"]"===i.slice(-1)?t+=`'${i.slice(1,-1)}'`:t+=`'${i}'`}return t}class o{constructor(e,t,s){this._year=e,this._month=t,this._day=s,this.declaredRootClass="esri.core.sql.dateonly"}get month(){return this._month}get monthJS(){return this._month-1}get year(){return this._year}get day(){return this._day}get isValid(){return this.toDateTime("unknown").isValid}equals(e){return e instanceof o&&e.day===this.day&&e.month===this.month&&e.year===this.year}clone(){return new o(this._year,this._month,this._day)}toDateTime(e){return n.ou.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.Qn)(e)})}toDateTimeLuxon(e){return n.ou.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.Qn)(e)})}toString(){return`${this.year.toString().padStart(4,"0")}-${this.month.toString().padStart(2,"0")}-${this.day.toString().padStart(2,"0")}`}toFormat(e=null){if(null===e||""===e)return this.toString();if(!(e=a(e)))return"";const t=this.toDateTime("unknown");return i.iG.dateTimeToArcadeDate(t).toFormat(e,{locale:(0,r.Kd)(),numberingSystem:"latn"})}toArcadeDate(){const e=this.toDateTime("unknown");return i.iG.dateTimeToArcadeDate(e)}toNumber(){return this.toDateTime("unknown").toMillis()}toJSDate(){return this.toDateTime("unknown").toJSDate()}toStorageFormat(){return this.toFormat("yyyy-LL-dd")}toSQLValue(){return this.toFormat("yyyy-LL-dd")}toSQLWithKeyword(){return"date '"+this.toFormat("yyyy-LL-dd")+"'"}plus(e,t){return o.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}toUTCDateTime(){return n.ou.utc(this.year,this.month,this.day,0,0,0,0)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}static fromMilliseconds(e){const t=n.ou.fromMillis(e,{zone:n.Qf.utcInstance});return t.isValid?o.fromParts(t.year,t.month,t.day):null}static fromSeconds(e){const t=n.ou.fromSeconds(e,{zone:n.Qf.utcInstance});return t.isValid?o.fromParts(t.year,t.month,t.day):null}static fromReader(e){if(!e)return null;const t=e.split("-");return 3!==t.length?null:new o(parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10))}static fromParts(e,t,s){const i=new o(e,t,s);return!1===i.isValid?null:i}static fromDateJS(e){return o.fromParts(e.getFullYear(),e.getMonth()+1,e.getDay())}static fromDateTime(e){return o.fromParts(e.year,e.month,e.day)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e)return null;if(null===e)return null;const s=[];if(t)(t=a(t))&&s.push(t);else if(null===t||""===t){const t=n.ou.fromISO(e,{setZone:!0});return t.isValid?o.fromParts(t.year,t.month,t.day):null}for(const i of s){const s=n.ou.fromFormat(e,t??i);if(s.isValid)return new o(s.year,s.month,s.day)}return null}static fromNow(e="system"){const t=n.ou.fromJSDate(new Date).setZone((0,i.Qn)(e));return new o(t.year,t.month,t.day)}}},53970:(e,t,s)=>{s.d(t,{n:()=>o});var i=s(77286),r=s(70171),n=s(17126);function a(e){if(!e)return"";const t=/(a|A|hh?|HH?|mm?|ss?|SSS|S|.)/g;let s="";for(const i of e.match(t)||[])switch(i){case"SSS":case"m":case"mm":case"h":case"hh":case"H":case"HH":case"s":case"ss":s+=i;break;case"A":case"a":s+="a";break;default:s+=`'${i}'`}return s}class o{constructor(e,t,s,i){this._hour=e,this._minute=t,this._second=s,this._millisecond=i,this.declaredRootClass="esri.core.sql.timeonly"}get hour(){return this._hour}get minute(){return this._minute}get second(){return this._second}get millisecond(){return this._millisecond}equals(e){return e instanceof o&&e.hour===this.hour&&e.minute===this.minute&&e.second===this.second&&e.millisecond===this.millisecond}clone(){return new o(this.hour,this.minute,this.second,this.millisecond)}isValid(){return(0,i.U)(this.hour)&&(0,i.U)(this.minute)&&(0,i.U)(this.second)&&(0,i.U)(this.millisecond)&&this.hour>=0&&this.hour<24&&this.minute>=0&&this.minute<60&&this.second>=0&&this.second<60&&this.millisecond>=0&&this.millisecond<1e3}toString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`+(this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):"")}toSQLValue(){return this.toString()}toSQLWithKeyword(){return`time '${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}${this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):""}'`}toStorageString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`}toFormat(e=null){return null===e||""===e?this.toString():(e=a(e))?n.ou.local(1970,1,1,this._hour,this._minute,this._second,this._millisecond).toFormat(e,{locale:(0,r.Kd)(),numberingSystem:"latn"}):""}toNumber(){return this.millisecond+1e3*this.second+1e3*this.minute*60+60*this.hour*60*1e3}static fromParts(e,t,s,i){const r=new o(e,t,s,i);return r.isValid()?r:null}static fromReader(e){if(!e)return null;const t=e.split(":");return 3!==t.length?null:new o(parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10),0)}static fromMilliseconds(e){if(e>864e5||e<0)return null;const t=Math.floor(e/1e3%60),s=Math.floor(e/6e4%60),i=Math.floor(e/36e5%24),r=Math.floor(e%1e3);return new o(i,s,t,r)}static fromDateJS(e){return new o(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}static fromDateTime(e){return new o(e.hour,e.minute,e.second,e.millisecond)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e)return null;if(null===e)return null;const s=[];t?(t=a(t))&&s.push(t):null!==t&&""!==t||(s.push("HH:mm:ss"),s.push("HH:mm:ss.SSS"),s.push("hh:mm:ss a"),s.push("hh:mm:ss.SSS a"),s.push("HH:mm"),s.push("hh:mm a"),s.push("H:mm"),s.push("h:mm a"),s.push("H:mm:ss"),s.push("h:mm:ss a"),s.push("H:mm:ss.SSS"),s.push("h:mm:ss.SSS a"));for(const t of s){const s=n.ou.fromFormat(e,t);if(s.isValid)return new o(s.hour,s.minute,s.second,s.millisecond)}return null}plus(e,t){switch(e){case"days":case"years":case"months":return this.clone();case"hours":case"minutes":case"seconds":case"milliseconds":return o.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}return null}toUTCDateTime(){return n.ou.utc(1970,1,1,this.hour,this.minute,this.second,this.millisecond)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}}},1542:(e,t,s)=>{s.d(t,{A4:()=>n,L9:()=>a,Rw:()=>o,yV:()=>r});var i=s(17126);class r{}function n(e){return e instanceof i.ld?e===r.instance:"unknown"===e?.toString().toLowerCase()}function a(e){return n(e)?r.instance:e}function o(e,t){return i.ou.fromObject({day:e.day,year:e.year,month:e.month,hour:e.hour,minute:e.minute,second:e.second,millisecond:e.millisecond},{zone:t})}r.instance=new i.vF("Etc/UTC")},37455:(e,t,s)=>{s.d(t,{N:()=>i});const i={convertToGEGeometry:function(e,t){return null==t?null:e.convertJSONToGeometry(t)},exportPoint:function(e,t,s){const i=new r(e.getPointX(t),e.getPointY(t),s),n=e.hasZ(t),a=e.hasM(t);return n&&(i.z=e.getPointZ(t)),a&&(i.m=e.getPointM(t)),i},exportPolygon:function(e,t,s){return new n(e.exportPaths(t),s,e.hasZ(t),e.hasM(t))},exportPolyline:function(e,t,s){return new a(e.exportPaths(t),s,e.hasZ(t),e.hasM(t))},exportMultipoint:function(e,t,s){return new o(e.exportPoints(t),s,e.hasZ(t),e.hasM(t))},exportExtent:function(e,t,s){const i=e.hasZ(t),r=e.hasM(t),n=new l(e.getXMin(t),e.getYMin(t),e.getXMax(t),e.getYMax(t),s);if(i){const s=e.getZExtent(t);n.zmin=s.vmin,n.zmax=s.vmax}if(r){const s=e.getMExtent(t);n.mmin=s.vmin,n.mmax=s.vmax}return n}};class r{constructor(e,t,s){this.x=e,this.y=t,this.spatialReference=s,this.z=void 0,this.m=void 0}}class n{constructor(e,t,s,i){this.rings=e,this.spatialReference=t,this.hasZ=void 0,this.hasM=void 0,s&&(this.hasZ=s),i&&(this.hasM=i)}}class a{constructor(e,t,s,i){this.paths=e,this.spatialReference=t,this.hasZ=void 0,this.hasM=void 0,s&&(this.hasZ=s),i&&(this.hasM=i)}}class o{constructor(e,t,s,i){this.points=e,this.spatialReference=t,this.hasZ=void 0,this.hasM=void 0,s&&(this.hasZ=s),i&&(this.hasM=i)}}class l{constructor(e,t,s,i,r){this.xmin=e,this.ymin=t,this.xmax=s,this.ymax=i,this.spatialReference=r,this.zmin=void 0,this.zmax=void 0,this.mmin=void 0,this.mmax=void 0}}},60437:(e,t,s)=>{s.d(t,{G_:()=>_,HH:()=>a,JR:()=>f,TC:()=>o,Tn:()=>h,Ue:()=>r,al:()=>n,bZ:()=>p,cS:()=>m,dp:()=>u,fS:()=>g,is:()=>y,op:()=>c,pp:()=>l,t8:()=>d});var i=s(6570);function r(e=T){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function n(e,t,s,i,n,a,o=r()){return o[0]=e,o[1]=t,o[2]=s,o[3]=i,o[4]=n,o[5]=a,o}function a(e,t){const s=isFinite(e[2])||isFinite(e[5]);return new i.Z(s?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function o(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}function l(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}function u(e,t=[0,0,0]){return t[0]=function(e){return e[0]>=e[3]?0:e[3]-e[0]}(e),t[1]=function(e){return e[1]>=e[4]?0:e[4]-e[1]}(e),t[2]=function(e){return e[2]>=e[5]?0:e[5]-e[2]}(e),t}function c(e,t,s=e){return s[0]=t[0],s[1]=t[1],s[2]=t[2],s!==e&&(s[3]=e[3],s[4]=e[4],s[5]=e[5]),s}function h(e,t,s=e){return s[3]=t[0],s[4]=t[1],s[5]=t[2],s!==e&&(s[0]=e[0],s[1]=e[1],s[2]=e[2]),e}function d(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function m(e){return e?d(e,_):r(_)}function f(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function p(e,t,s,i,r){return e[0]=t,e[1]=s,e[2]=Number.NEGATIVE_INFINITY,e[3]=i,e[4]=r,e[5]=Number.POSITIVE_INFINITY,e}function y(e){return 6===e.length}function g(e,t,s){if(null==e||null==t)return e===t;if(!y(e)||!y(t))return!1;if(s){for(let i=0;i<e.length;i++)if(!s(e[i],t[i]))return!1}else for(let s=0;s<e.length;s++)if(e[s]!==t[s])return!1;return!0}s(24470);const _=[1/0,1/0,1/0,-1/0,-1/0,-1/0],T=[0,0,0,0,0,0];r()},70272:(e,t,s)=>{s.d(t,{S6:()=>r,nd:()=>n,u_:()=>i});class i{constructor(e=null,t={},s,i){this.geometry=e,this.attributes=t,this.centroid=s,this.objectId=i,this.displayId=0,this.geohashX=0,this.geohashY=0}weakClone(){const e=new i(this.geometry,this.attributes,this.centroid,this.objectId);return e.displayId=this.displayId,e.geohashX=this.geohashX,e.geohashY=this.geohashY,e}}function r(e){return!!e.geometry?.coords?.length}class n extends i{}},44876:(e,t,s)=>{s.d(t,{Z:()=>i});class i{constructor(){this.objectIdFieldName=null,this.globalIdFieldName=null,this.geohashFieldName=null,this.geometryProperties=null,this.geometryType=null,this.spatialReference=null,this.hasZ=!1,this.hasM=!1,this.features=[],this.fields=[],this.transform=null,this.exceededTransferLimit=!1,this.uniqueIdField=null,this.queryGeometryType=null,this.queryGeometry=null}weakClone(){const e=new i;return e.objectIdFieldName=this.objectIdFieldName,e.globalIdFieldName=this.globalIdFieldName,e.geohashFieldName=this.geohashFieldName,e.geometryProperties=this.geometryProperties,e.geometryType=this.geometryType,e.spatialReference=this.spatialReference,e.hasZ=this.hasZ,e.hasM=this.hasM,e.features=this.features,e.fields=this.fields,e.transform=this.transform,e.exceededTransferLimit=this.exceededTransferLimit,e.uniqueIdField=this.uniqueIdField,e.queryGeometry=this.queryGeometry,e.queryGeometryType=this.queryGeometryType,e}}},5428:(e,t,s)=>{s.d(t,{Z:()=>i});class i{constructor(e=[],t=[],s=!1){this.lengths=e??[],this.coords=t??[],this.hasIndeterminateRingOrder=s}static fromRect(e){const[t,s,r,n]=e,a=r-t,o=n-s;return new i([5],[t,s,a,0,0,o,-a,0,0,-o])}get isPoint(){return 0===this.lengths.length}get maxLength(){return Math.max(...this.lengths)}get size(){return this.lengths.reduce(((e,t)=>e+t))}forEachVertex(e){let t=0;this.lengths.length||e(this.coords[0],this.coords[1]);for(let s=0;s<this.lengths.length;s++){const i=this.lengths[s];for(let s=0;s<i;s++)e(this.coords[2*(s+t)],this.coords[2*(s+t)+1]);t+=i}}clone(e){return e?(e.set(this.coords),new i(this.lengths.slice(),e,this.hasIndeterminateRingOrder)):new i(this.lengths.slice(),this.coords.slice(),this.hasIndeterminateRingOrder)}}},3489:(e,t,s)=>{s.d(t,{q:()=>Ge});var i=s(67676),r=s(20102),n=s(96674),a=s(22974),o=s(70586),l=s(69801),u=s(95330),c=s(67900),h=s(73615),d=s(60437),m=s(24470),f=s(20322),p=s(33955),y=s(16306),g=s(8744),_=s(98732),T=s(13867),S=s(8968),x=s(86719);const I=new class{constructor(e,t){this._cache=new T.z(e),this._invalidCache=new T.z(t)}get(e,t){const s=`${t.uid}:${e}`,i=this._cache.get(s);if(i)return i;if(null!=this._invalidCache.get(s))return null;try{const i=S.WhereClause.create(e,t);return this._cache.put(s,i),i}catch(e){return this._invalidCache.put(s,e),null}}getError(e,t){const s=`${t.uid}:${e}`;return this._invalidCache.get(s)??null}}(50,500),F="unsupported-query",w=" as ",R=new Set(["esriFieldTypeOID","esriFieldTypeSmallInteger","esriFieldTypeBigInteger","esriFieldTypeInteger","esriFieldTypeSingle","esriFieldTypeDouble","esriFieldTypeLong"]),E=new Set(["esriFieldTypeDate","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]),b=new Set(["esriFieldTypeString","esriFieldTypeGUID","esriFieldTypeGlobalID",...R,...E]);function N(e,t,s={}){const i=v(t,e);if(!i){const s=I.getError(t,e);throw new r.Z(F,"invalid SQL expression",{expression:t,error:s})}const n=s.expressionName||"expression";if(s.validateStandardized&&!i.isStandardized)throw new r.Z(F,`${n} is not standard`,{expression:t});if(s.validateAggregate&&!i.isAggregate)throw new r.Z(F,`${n} does not contain a valid aggregate function`,{expression:t});return i.fieldNames}function A(e,t,s,i,n){if(!s)return!0;const a="having clause",o=N(e,s,{validateAggregate:!0,expressionName:a});C(e,t,o,{expressionName:a,query:n});const l=v(s,e),u=l?.getExpressions().every((t=>{const{aggregateType:s,field:r}=t,n=e.get(r)?.name;return i.some((t=>{const{onStatisticField:i,statisticType:r}=t,a=e.get(i)?.name;return a===n&&r.toLowerCase().trim()===s}))}));if(!u)throw new r.Z(F,"expressions in having clause should also exist in outStatistics",{having:s});return!0}function v(e,t){return e?I.get(e,t):null}function D(e){return/\((.*?)\)/.test(e)?e:e.split(w)[0]}function M(e){return e.split(w)[1]}function C(e,t,s,i={}){const n=new Map;if(function(e,t,s,i,r){for(const n of r)if("*"!==n)if(t.get(n))O(e,t,s,i,n);else try{const r=N(t,D(n),{validateStandardized:!0});for(const n of r)O(e,t,s,i,n)}catch(t){e.set(n,{type:"expression-error",expression:n,error:t})}}(n,e,t,i.allowedFieldTypes??b,s),n.size){const e=i.expressionName??"expression";throw new r.Z(F,`${e} contains invalid or missing fields`,{errors:Array.from(n.values()),query:i.query})}}function O(e,t,s,i,r){if("*"===r)return;const n=t.get(r);n?s.has(n.name)?!1===i?.has(n.type)&&e.set(r,{type:"invalid-type",fieldName:n.name,fieldType:x.v.fromJSON(n.type),allowedFieldTypes:Array.from(i,(e=>x.v.fromJSON(e)))}):e.set(r,{type:"missing-field",fieldName:n.name}):e.set(r,{type:"invalid-field",fieldName:r})}var P=s(42712),k=s(37427),Z=s(61159),L=s(35308),G=s(49600),U=s(82397),q=s(35671),V=s(79213),z=s(24452),Q=s(59266);class Y{constructor(e,t,s){this._fieldDataCache=new Map,this._returnDistinctMap=new Map,this.returnDistinctValues=e.returnDistinctValues??!1,this.fieldsIndex=s,this.featureAdapter=t;const i=e.outFields;if(i&&!i.includes("*")){this.outFields=i;let e=0;for(const t of i){const i=D(t),r=this.fieldsIndex.get(i),n=r?null:v(i,s),a=r?r.name:M(t)||"FIELD_EXP_"+e++;this._fieldDataCache.set(t,{alias:a,clause:n})}}}countDistinctValues(e){return this.returnDistinctValues?(e.forEach((e=>this.getAttributes(e))),this._returnDistinctMap.size):e.length}getAttributes(e){const t=this._processAttributesForOutFields(e);return this._processAttributesForDistinctValues(t)}getFieldValue(e,t,s){const i=s?s.name:t;let r=null;return this._fieldDataCache.has(i)?r=this._fieldDataCache.get(i)?.clause:s||(r=v(t,this.fieldsIndex),this._fieldDataCache.set(i,{alias:i,clause:r})),s?this.featureAdapter.getAttribute(e,i):r?.calculateValue(e,this.featureAdapter)}getDataValues(e,t,s=!0){const i=t.normalizationType,r=t.normalizationTotal,n=this.fieldsIndex.get(t.field),a=(0,q.UQ)(n)||(0,q.ig)(n),o=(0,q.sX)(n);return e.map((e=>{let n=t.field&&this.getFieldValue(e,t.field,this.fieldsIndex.get(t.field));if(t.field2?(n=`${(0,z.wk)(n)}${t.fieldDelimiter}${(0,z.wk)(this.getFieldValue(e,t.field2,this.fieldsIndex.get(t.field2)))}`,t.field3&&(n=`${n}${t.fieldDelimiter}${(0,z.wk)(this.getFieldValue(e,t.field3,this.fieldsIndex.get(t.field3)))}`)):"string"==typeof n&&s&&(a?n=n?new Date(n).getTime():null:o&&(n=n?(0,V.yO)(n):null)),i&&Number.isFinite(n)){const s="field"===i&&t.normalizationField?this.getFieldValue(e,t.normalizationField,this.fieldsIndex.get(t.normalizationField)):null;n=(0,z.fk)(n,i,s,r)}return n}))}async getExpressionValues(e,t,s,i,r){const{arcadeUtils:n}=await(0,Q.LC)(),a=n.hasGeometryOperations(t);a&&await n.enableGeometryOperations();const o=n.createFunction(t),l=n.getViewInfo(s),u={fields:this.fieldsIndex.fields};return e.map((e=>{const t={attributes:this.featureAdapter.getAttributes(e),layer:u,geometry:a?{...(0,P.Op)(i.geometryType,i.hasZ,i.hasM,this.featureAdapter.getGeometry(e)),spatialReference:s?.spatialReference}:null},c=n.createExecContext(t,l,r);return n.executeFunction(o,c)}))}validateItem(e,t){return this._fieldDataCache.has(t)||this._fieldDataCache.set(t,{alias:t,clause:v(t,this.fieldsIndex)}),this._fieldDataCache.get(t)?.clause?.testFeature(e,this.featureAdapter)??!1}validateItems(e,t){return this._fieldDataCache.has(t)||this._fieldDataCache.set(t,{alias:t,clause:v(t,this.fieldsIndex)}),this._fieldDataCache.get(t)?.clause?.testSet(e,this.featureAdapter)??!1}_processAttributesForOutFields(e){const t=this.outFields;if(!t?.length)return this.featureAdapter.getAttributes(e);const s={};for(const i of t){const{alias:t,clause:r}=this._fieldDataCache.get(i);s[t]=r?r.calculateValue(e,this.featureAdapter):this.featureAdapter.getAttribute(e,t)}return s}_processAttributesForDistinctValues(e){if(null==e||!this.returnDistinctValues)return e;const t=this.outFields,s=[];if(t)for(const i of t){const{alias:t}=this._fieldDataCache.get(i);s.push(e[t])}else for(const t in e)s.push(e[t]);const i=`${(t||["*"]).join(",")}=${s.join(",")}`;let r=this._returnDistinctMap.get(i)||0;return this._returnDistinctMap.set(i,++r),r>1?null:e}}function j(e,t,s){return{objectId:e,target:t,distance:s,type:"vertex"}}function B(e,t,s,i,r,n=!1){return{objectId:e,target:t,distance:s,type:"edge",start:i,end:r,draped:n}}class H{constructor(e,t,s){this.items=e,this.query=t,this.geometryType=s.geometryType,this.hasM=s.hasM,this.hasZ=s.hasZ,this.fieldsIndex=s.fieldsIndex,this.objectIdField=s.objectIdField,this.spatialReference=s.spatialReference,this.featureAdapter=s.featureAdapter}get size(){return this.items.length}createQueryResponseForCount(){const e=new Y(this.query,this.featureAdapter,this.fieldsIndex);if(!this.query.outStatistics)return e.countDistinctValues(this.items);const{groupByFieldsForStatistics:t,having:s,outStatistics:i}=this.query,r=t?.length;if(!r)return 1;const n=new Map,a=new Map,o=new Set;for(const r of i){const{statisticType:i}=r,l="exceedslimit"!==i?r.onStatisticField:void 0;if(!a.has(l)){const s=[];for(const i of t){const t=this._getAttributeValues(e,i,n);s.push(t)}a.set(l,this._calculateUniqueValues(s,e.returnDistinctValues))}const u=a.get(l);for(const t in u){const{data:i,items:r}=u[t],n=i.join(",");s&&!e.validateItems(r,s)||o.add(n)}}return o.size}async createQueryResponse(){let e;if(e=this.query.outStatistics?this.query.outStatistics.some((e=>"exceedslimit"===e.statisticType))?this._createExceedsLimitQueryResponse(this.query):await this._createStatisticsQueryResponse(this.query):this._createFeatureQueryResponse(this.query),this.query.returnQueryGeometry){const t=this.query.geometry;(0,g.JY)(this.query.outSR)&&!(0,g.fS)(t.spatialReference,this.query.outSR)?e.queryGeometry=(0,P.S2)({spatialReference:this.query.outSR,...(0,k.iV)(t,t.spatialReference,this.query.outSR)}):e.queryGeometry=(0,P.S2)({spatialReference:this.query.outSR,...t})}return e}createSnappingResponse(e,t){const s=this.featureAdapter,i=J(this.hasZ,this.hasM),{point:r,mode:n}=e,a="number"==typeof e.distance?e.distance:e.distance.x,o="number"==typeof e.distance?e.distance:e.distance.y,l={candidates:[]},u="esriGeometryPolygon"===this.geometryType,c=this._getPointCreator(n,this.spatialReference,t),h=new W(null,0),d=new W(null,0),m={x:0,y:0,z:0};for(const t of this.items){const n=s.getGeometry(t);if(null==n)continue;const{coords:f,lengths:p}=n;if(h.coords=f,d.coords=f,e.returnEdge){let e=0;for(let n=0;n<p.length;n++){const u=p[n];for(let n=0;n<u;n++,e+=i){const f=h;if(f.coordsIndex=e,n!==u-1){const n=d;n.coordsIndex=e+i;const u=m;$(m,r,f,n);const h=(r.x-u.x)/a,p=(r.y-u.y)/o,y=h*h+p*p;y<=1&&l.candidates.push(B(s.getObjectId(t),c(u),Math.sqrt(y),c(f),c(n)))}}}}if("none"!==e.vertexMode){const n=u?f.length-i:f.length;if("all"===e.vertexMode)for(let e=0;e<n;e+=i){const i=h;i.coordsIndex=e;const n=(r.x-i.x)/a,u=(r.y-i.y)/o,d=n*n+u*u;d<=1&&l.candidates.push(j(s.getObjectId(t),c(i),Math.sqrt(d)))}else if("ends"===e.vertexMode){const e=[0];u||e.push(f.length-i);for(const i of e){const e=h;e.coordsIndex=i;const n=(r.x-e.x)/a,u=(r.y-e.y)/o,d=n*n+u*u;d<=1&&l.candidates.push(j(s.getObjectId(t),c(e),Math.sqrt(d)))}}}}return l.candidates.sort(((e,t)=>e.distance-t.distance)),l}_getPointCreator(e,t,s){const i=null==s||(0,g.fS)(t,s)?e=>e:e=>(0,k.iV)(e,t,s),{hasZ:r}=this;return"3d"===e?r?({x:e,y:t,z:s})=>i({x:e,y:t,z:s}):({x:e,y:t})=>i({x:e,y:t,z:0}):({x:e,y:t})=>i({x:e,y:t})}async createSummaryStatisticsResponse(e){const{field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,minValue:a,maxValue:o,scale:l,timeZone:u}=e,c=this.fieldsIndex.get(t),h=(0,q.y2)(c)||(0,q.UQ)(c)||(0,q.ig)(c),d=await this._getDataValues({field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,scale:l,timeZone:u}),m=(0,z.S5)({normalizationType:r,normalizationField:i,minValue:a,maxValue:o}),f={value:.5,fieldType:c?.type},p=(0,q.qN)(c)?(0,z.H0)({values:d,supportsNullCount:m,percentileParams:f}):(0,z.i5)({values:d,minValue:a,maxValue:o,useSampleStdDev:!r,supportsNullCount:m,percentileParams:f});return(0,z.F_)(p,h)}async createUniqueValuesResponse(e){const{field:t,valueExpression:s,domains:i,returnAllCodedValues:r,scale:n,timeZone:a}=e,o=await this._getDataValues({field:t,field2:e.field2,field3:e.field3,fieldDelimiter:e.fieldDelimiter,valueExpression:s,scale:n,timeZone:a},!1),l=(0,z.eT)(o);return(0,z.Qm)(l,i,r,e.fieldDelimiter)}async createClassBreaksResponse(e){const{field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,classificationMethod:a,standardDeviationInterval:o,minValue:l,maxValue:u,numClasses:c,scale:h,timeZone:d}=e,m=await this._getDataValues({field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,scale:h,timeZone:d}),f=(0,z.G2)(m,{field:t,normalizationField:i,normalizationType:r,normalizationTotal:n,classificationMethod:a,standardDeviationInterval:o,minValue:l,maxValue:u,numClasses:c});return(0,z.DL)(f,a)}async createHistogramResponse(e){const{field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,classificationMethod:a,standardDeviationInterval:o,minValue:l,maxValue:u,numBins:c,scale:h,timeZone:d}=e,m=await this._getDataValues({field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,scale:h,timeZone:d});return(0,z.oF)(m,{field:t,normalizationField:i,normalizationType:r,normalizationTotal:n,classificationMethod:a,standardDeviationInterval:o,minValue:l,maxValue:u,numBins:c})}_sortFeatures(e,t,s){if(e.length>1&&t?.length)for(const i of t.reverse()){const t=i.split(" "),r=t[0],n=this.fieldsIndex.get(r),a=!!t[1]&&"desc"===t[1].toLowerCase(),o=(0,z.Lq)(n?.type,a);e.sort(((e,t)=>{const i=s(e,r,n),a=s(t,r,n);return o(i,a)}))}}_createFeatureQueryResponse(e){const t=this.items,{geometryType:s,hasM:i,hasZ:r,objectIdField:n,spatialReference:a}=this,{outFields:o,outSR:l,quantizationParameters:u,resultRecordCount:c,resultOffset:h,returnZ:d,returnM:m}=e,f=null!=c&&t.length>(h||0)+c,p=o&&(o.includes("*")?[...this.fieldsIndex.fields]:o.map((e=>this.fieldsIndex.get(e))));return{exceededTransferLimit:f,features:this._createFeatures(e,t),fields:p,geometryType:s,hasM:i&&m,hasZ:r&&d,objectIdFieldName:n,spatialReference:(0,P.S2)(l||a),transform:u&&(0,U.vY)(u)||null}}_createFeatures(e,t){const s=new Y(e,this.featureAdapter,this.fieldsIndex),{hasM:i,hasZ:r}=this,{orderByFields:n,quantizationParameters:a,returnGeometry:o,returnCentroid:l,maxAllowableOffset:u,resultOffset:c,resultRecordCount:h,returnZ:d=!1,returnM:m=!1}=e,f=r&&d,p=i&&m;let y=[],g=0;const _=[...t];if(this._sortFeatures(_,n,((e,t,i)=>s.getFieldValue(e,t,i))),o||l){const e=(0,U.vY)(a)??void 0;if(o&&!l)for(const t of _)y[g++]={attributes:s.getAttributes(t),geometry:(0,P.Op)(this.geometryType,this.hasZ,this.hasM,this.featureAdapter.getGeometry(t),u,e,f,p)};else if(!o&&l)for(const t of _)y[g++]={attributes:s.getAttributes(t),centroid:(0,P.EG)(this,this.featureAdapter.getCentroid(t,this),e)};else for(const t of _)y[g++]={attributes:s.getAttributes(t),centroid:(0,P.EG)(this,this.featureAdapter.getCentroid(t,this),e),geometry:(0,P.Op)(this.geometryType,this.hasZ,this.hasM,this.featureAdapter.getGeometry(t),u,e,f,p)}}else for(const e of _){const t=s.getAttributes(e);t&&(y[g++]={attributes:t})}const T=c||0;if(null!=h){const e=T+h;y=y.slice(T,Math.min(y.length,e))}return y}_createExceedsLimitQueryResponse(e){let t=!1,s=Number.POSITIVE_INFINITY,i=Number.POSITIVE_INFINITY,r=Number.POSITIVE_INFINITY;for(const t of e.outStatistics??[])if("exceedslimit"===t.statisticType){s=null!=t.maxPointCount?t.maxPointCount:Number.POSITIVE_INFINITY,i=null!=t.maxRecordCount?t.maxRecordCount:Number.POSITIVE_INFINITY,r=null!=t.maxVertexCount?t.maxVertexCount:Number.POSITIVE_INFINITY;break}if("esriGeometryPoint"===this.geometryType)t=this.items.length>s;else if(this.items.length>i)t=!0;else{const e=J(this.hasZ,this.hasM),s=this.featureAdapter;t=this.items.reduce(((e,t)=>{const i=s.getGeometry(t);return e+(null!=i&&i.coords.length||0)}),0)/e>r}return{fields:[{name:"exceedslimit",type:"esriFieldTypeInteger",alias:"exceedslimit",sqlType:"sqlTypeInteger",domain:null,defaultValue:null}],features:[{attributes:{exceedslimit:Number(t)}}]}}async _createStatisticsQueryResponse(e){const t={attributes:{}},s=[],i=new Map,r=new Map,n=new Map,a=new Map,o=new Y(e,this.featureAdapter,this.fieldsIndex),l=e.outStatistics,{groupByFieldsForStatistics:u,having:c,orderByFields:h,resultRecordCount:d}=e,m=u?.length,f=!!m,p=f?u[0]:null,y=f&&!this.fieldsIndex.get(p);for(const e of l??[]){const{outStatisticFieldName:l,statisticType:h}=e,g=e,_="exceedslimit"!==h?e.onStatisticField:void 0,T="percentile_disc"===h||"percentile_cont"===h,S="EnvelopeAggregate"===h||"CentroidAggregate"===h||"ConvexHullAggregate"===h,x=f&&1===m&&(_===p||y)&&"count"===h;if(f){if(!n.has(_)){const e=[];for(const t of u){const s=this._getAttributeValues(o,t,i);e.push(s)}n.set(_,this._calculateUniqueValues(e,!S&&o.returnDistinctValues))}const e=n.get(_);if(!e)continue;const t=Object.keys(e);d&&(t.sort(),t.length=d);for(const s of t){const{count:t,data:r,items:n,itemPositions:h}=e[s],d=r.join(",");if(!c||o.validateItems(n,c)){const e=a.get(d)||{attributes:{}};if(S){e.aggregateGeometries||(e.aggregateGeometries={});const{aggregateGeometries:t,outStatisticFieldName:s}=await this._getAggregateGeometry(g,n);e.aggregateGeometries[s]=t}else{let s=null;if(x)s=t;else{const e=this._getAttributeValues(o,_,i),t=h.map((t=>e[t]));s=T&&"statisticParameters"in g?this._getPercentileValue(g,t):this._getStatisticValue(g,t,null,o.returnDistinctValues)}e.attributes[l]=s}let s=0;u.forEach(((t,i)=>e.attributes[this.fieldsIndex.get(t)?t:"EXPR_"+ ++s]=r[i])),a.set(d,e)}}}else if(S){t.aggregateGeometries||(t.aggregateGeometries={});const{aggregateGeometries:e,outStatisticFieldName:s}=await this._getAggregateGeometry(g,this.items);t.aggregateGeometries[s]=e}else{const e=this._getAttributeValues(o,_,i);t.attributes[l]=T&&"statisticParameters"in g?this._getPercentileValue(g,e):this._getStatisticValue(g,e,r,o.returnDistinctValues)}const I="min"!==h&&"max"!==h||!(0,q.qN)(this.fieldsIndex.get(_))&&!this._isAnyDateField(_)?null:this.fieldsIndex.get(_)?.type;s.push({name:l,alias:l,type:I||"esriFieldTypeDouble"})}const g=f?Array.from(a.values()):[t];return this._sortFeatures(g,h,((e,t)=>e.attributes[t])),{fields:s,features:g}}_isAnyDateField(e){const t=this.fieldsIndex.get(e);return(0,q.y2)(t)||(0,q.UQ)(t)||(0,q.ig)(t)||(0,q.sX)(t)}async _getAggregateGeometry(e,t){const{convexHull:i,union:r}=await Promise.all([s.e(5837),s.e(247)]).then(s.bind(s,30247)),{statisticType:n,outStatisticFieldName:a}=e,{featureAdapter:o,spatialReference:l,geometryType:u,hasZ:c,hasM:h}=this,d=t.map((e=>(0,P.Op)(u,c,h,o.getGeometry(e)))),m=i(l,d,!0)[0],f={aggregateGeometries:null,outStatisticFieldName:null};if("EnvelopeAggregate"===n){const e=m?(0,G._w)(m):(0,G.aO)(r(l,d));f.aggregateGeometries={...e,spatialReference:l},f.outStatisticFieldName=a||"extent"}else if("CentroidAggregate"===n){const e=m?(0,L.tO)(m):(0,L.$G)((0,G.aO)(r(l,d)));f.aggregateGeometries={x:e[0],y:e[1],spatialReference:l},f.outStatisticFieldName=a||"centroid"}else"ConvexHullAggregate"===n&&(f.aggregateGeometries=m,f.outStatisticFieldName=a||"convexHull");return f}_getStatisticValue(e,t,s,i){const{onStatisticField:r,statisticType:n}=e;let a=null;return a=s?.has(r)?s.get(r):(0,q.qN)(this.fieldsIndex.get(r))||this._isAnyDateField(r)?(0,z.H0)({values:t,returnDistinct:i}):(0,z.i5)({values:i?[...new Set(t)]:t,minValue:null,maxValue:null,useSampleStdDev:!0}),s&&s.set(r,a),a["var"===n?"variance":n]}_getPercentileValue(e,t){const{onStatisticField:s,statisticParameters:i,statisticType:r}=e,{value:n,orderBy:a}=i,o=this.fieldsIndex.get(s);return(0,z.XL)(t,{value:n,orderBy:a,fieldType:o?.type,isDiscrete:"percentile_disc"===r})}_getAttributeValues(e,t,s){if(s.has(t))return s.get(t);const i=this.fieldsIndex.get(t),r=this.items.map((s=>e.getFieldValue(s,t,i)));return s.set(t,r),r}_calculateUniqueValues(e,t){const s={},i=this.items,r=i.length;for(let n=0;n<r;n++){const r=i[n],a=[];for(const t of e)a.push(t[n]);const o=a.join(",");null==s[o]?s[o]={count:1,data:a,items:[r],itemPositions:[n]}:(t||s[o].count++,s[o].items.push(r),s[o].itemPositions.push(n))}return s}async _getDataValues(e,t=!0){const s=new Y(this.query,this.featureAdapter,this.fieldsIndex),{valueExpression:i,scale:r,timeZone:n}=e;return i?s.getExpressionValues(this.items,i,{viewingMode:"map",scale:r,spatialReference:this.query.outSR||this.spatialReference},{geometryType:this.geometryType,hasZ:this.hasZ,hasM:this.hasM},n):s.getDataValues(this.items,(0,a.d9)(e),t)}}function $(e,t,s,i){const r=i.x-s.x,n=i.y-s.y,a=r*r+n*n,o=(t.x-s.x)*r+(t.y-s.y)*n,l=Math.min(1,Math.max(0,o/a));e.x=s.x+r*l,e.y=s.y+n*l}function J(e,t){return e?t?4:3:t?3:2}class W{constructor(e,t){this.coords=e,this.coordsIndex=t}get x(){return this.coords[this.coordsIndex]}get y(){return this.coords[this.coordsIndex+1]}get z(){return this.coords[this.coordsIndex+2]}}var X=s(22222),K=s(10402);const ee="unsupported-query";async function te(e,{fieldsIndex:t,geometryType:s,spatialReference:i,availableFields:n}){if((e.distance??0)<0||null!=e.geometryPrecision||e.multipatchOption||e.pixelSize||e.relationParam||e.text)throw new r.Z(ee,"Unsupported query options",{query:e});return se(t,n,e),function(e,t,s){const{outStatistics:i,groupByFieldsForStatistics:n,having:a}=s,o=n?.length,l=i?.length;if(a){if(!o||!l)throw new r.Z(ee,"outStatistics and groupByFieldsForStatistics should be specified with having",{query:s});A(e,t,a,i,s)}if(l){if(null==(u=i)||!u.every((e=>"exceedslimit"!==e.statisticType)))return;const a=i.map((e=>e.onStatisticField)).filter(Boolean);C(e,t,a,{expressionName:"onStatisticFields",query:s}),o&&C(e,t,n,{expressionName:"groupByFieldsForStatistics",query:s});for(const n of i){const{onStatisticField:i,statisticType:a}=n;if("percentile_disc"!==a&&"percentile_cont"!==a||!("statisticParameters"in n))e.get(i)&&"count"!==a&&"min"!==a&&"max"!==a&&C(e,t,[i],{expressionName:`outStatistics with '${a}' statistic type`,allowedFieldTypes:ie,query:s});else{const{statisticParameters:e}=n;if(!e)throw new r.Z(ee,"statisticParameters should be set for percentile type",{definition:n,query:s})}}}var u}(t,n,e),Promise.all([(0,K.P0)(e,s,i),(0,k._W)(i,e.outSR)]).then((()=>e))}function se(e,t,s){const{outFields:i,orderByFields:n,returnDistinctValues:a,outStatistics:o}=s,l=o?o.map((e=>e.outStatisticFieldName&&e.outStatisticFieldName.toLowerCase())).filter(Boolean):[];if(n&&n.length>0){const i=" asc",r=" desc",a=n.map((e=>{const t=e.toLowerCase();return t.includes(i)?t.split(i)[0]:t.includes(r)?t.split(r)[0]:e})).filter((e=>!l.includes(e)));C(e,t,a,{expressionName:"orderByFields",query:s})}if(i&&i.length>0)C(e,t,i,{expressionName:"outFields",query:s});else if(a)throw new r.Z(ee,"outFields should be specified for returnDistinctValues",{query:s});!function(e,t,s,i){if(!s)return!0;const r="where clause";C(e,t,N(e,s,{validateStandardized:!0,expressionName:r}),{expressionName:r,query:i})}(e,t,s.where,s)}const ie=new Set([...R,...E]);async function re(e,t,s,i){let n=[];if(s.valueExpression){const{arcadeUtils:e}=await(0,Q.LC)();n=e.extractFieldNames(s.valueExpression)}if(s.field&&n.push(s.field),s.field2&&n.push(s.field2),s.field3&&n.push(s.field3),s.normalizationField&&n.push(s.normalizationField),!n.length&&!s.valueExpression)throw new r.Z(ee,"field or valueExpression is required",{params:s});C(e,t,n,{expressionName:"statistics",query:i})}var ne=s(17590),ae=s(99514),oe=s(61247),le=(s(80442),s(92604)),ue=s(54790),ce=s(44553),he=s(17445),de=s(95528),me=s(76882);class fe{constructor(){this._tasks=new Array,this._running=(0,de.t)(!1)}get length(){return this._tasks.length}get running(){return this._running.value}destroy(){this.cancelAll()}runTask(e){for(;!e.done&&this._process(e);)e.madeProgress()}push(e,t,s){return this._running.value=!0,new Promise(((i,r)=>this._tasks.push(new pe(i,r,e,t,s))))}unshift(e,t,s){return this._running.value=!0,new Promise(((i,r)=>this._tasks.unshift(new pe(i,r,e,t,s))))}_process(e){if(0===this._tasks.length)return!1;const t=this._tasks.shift();try{const s=(0,u.Hc)(t.signal);if(s&&!t.abortCallback)t.reject((0,u.zE)());else{const i=s?t.abortCallback?.((0,u.zE)()):t.callback(e);(0,u.y8)(i)?i.then(t.resolve,t.reject):t.resolve(i)}}catch(e){t.reject(e)}return this._running.value=this._tasks.length>0,!0}cancelAll(){const e=(0,u.zE)();for(const t of this._tasks)if(t.abortCallback){const s=t.abortCallback(e);t.resolve(s)}else t.reject(e);this._tasks.length=0,this._running.value=!1}}class pe{constructor(e,t,s,i=void 0,r=void 0){this.resolve=e,this.reject=t,this.callback=s,this.signal=i,this.abortCallback=r}}var ye=s(43697),ge=s(92036),_e=s(5600),Te=(s(75215),s(52011));let Se=class extends ge.Z{constructor(){super(...arguments),this.SCHEDULER_LOG_SLOW_TASKS=!1,this.FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES=!1}};(0,ye._)([(0,_e.Cb)()],Se.prototype,"SCHEDULER_LOG_SLOW_TASKS",void 0),(0,ye._)([(0,_e.Cb)()],Se.prototype,"FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES",void 0),Se=(0,ye._)([(0,Te.j)("esri.views.support.DebugFlags")],Se);const xe=new Se;var Ie,Fe,we,Re=s(95720);(we=Ie||(Ie={}))[we.YIELD=1]="YIELD",function(e){e.RESOURCE_CONTROLLER_IMMEDIATE="immediate",e.RESOURCE_CONTROLLER="schedule",e.SLIDE="slide",e.STREAM_DATA_LOADER="stream loader",e.ELEVATION_QUERY="elevation query",e.TERRAIN_SURFACE="terrain",e.SURFACE_GEOMETRY_UPDATES="surface geometry updates",e.LOD_RENDERER="LoD renderer",e.GRAPHICS_CORE="Graphics3D",e.I3S_CONTROLLER="I3S",e.POINT_CLOUD_LAYER="point cloud",e.FEATURE_TILE_FETCHER="feature fetcher",e.OVERLAY="overlay",e.STAGE="stage",e.GRAPHICS_DECONFLICTOR="graphics deconflictor",e.FILTER_VISIBILITY="Graphics3D filter visibility",e.SCALE_VISIBILITY="Graphics3D scale visibility",e.FRUSTUM_VISIBILITY="Graphics3D frustum visibility",e.POINT_OF_INTEREST_FREQUENT="POI frequent",e.POINT_OF_INTEREST_INFREQUENT="POI infrequent",e.LABELER="labeler",e.FEATURE_QUERY_ENGINE="feature query",e.FEATURE_TILE_TREE="feature tile tree",e.FEATURE_TILE_TREE_ACTIVE="fast feature tile tree",e.ELEVATION_ALIGNMENT="elevation alignment",e.TEXT_TEXTURE_ATLAS="text texture atlas",e.TEXTURE_UNLOAD="texture unload",e.LINE_OF_SIGHT_TOOL="line of sight tool",e.LINE_OF_SIGHT_TOOL_INTERACTIVE="interactive line of sight tool",e.ELEVATION_PROFILE="elevation profile",e.SNAPPING="snapping",e.SHADOW_ACCUMULATOR="shadow accumulator",e.CLOUDS_GENERATOR="clouds generator",e[e.NONE=0]="NONE",e[e.TEST_PRIO=1]="TEST_PRIO"}(Fe||(Fe={}));const Ee=new Map([[Fe.RESOURCE_CONTROLLER_IMMEDIATE,0],[Fe.RESOURCE_CONTROLLER,4],[Fe.SLIDE,0],[Fe.STREAM_DATA_LOADER,0],[Fe.ELEVATION_QUERY,0],[Fe.TERRAIN_SURFACE,1],[Fe.SURFACE_GEOMETRY_UPDATES,1],[Fe.LOD_RENDERER,2],[Fe.GRAPHICS_CORE,2],[Fe.I3S_CONTROLLER,2],[Fe.POINT_CLOUD_LAYER,2],[Fe.FEATURE_TILE_FETCHER,2],[Fe.OVERLAY,4],[Fe.STAGE,4],[Fe.GRAPHICS_DECONFLICTOR,4],[Fe.FILTER_VISIBILITY,4],[Fe.SCALE_VISIBILITY,4],[Fe.FRUSTUM_VISIBILITY,4],[Fe.CLOUDS_GENERATOR,4],[Fe.POINT_OF_INTEREST_FREQUENT,6],[Fe.POINT_OF_INTEREST_INFREQUENT,30],[Fe.LABELER,8],[Fe.FEATURE_QUERY_ENGINE,8],[Fe.FEATURE_TILE_TREE,16],[Fe.FEATURE_TILE_TREE_ACTIVE,0],[Fe.ELEVATION_ALIGNMENT,12],[Fe.TEXT_TEXTURE_ATLAS,12],[Fe.TEXTURE_UNLOAD,12],[Fe.LINE_OF_SIGHT_TOOL,16],[Fe.LINE_OF_SIGHT_TOOL_INTERACTIVE,0],[Fe.SNAPPING,0],[Fe.SHADOW_ACCUMULATOR,30]]);function be(e){return Ee.has(e)?Ee.get(e):"number"==typeof e?e:1}const Ne=(0,me.HA)(6.5),Ae=(0,me.HA)(1),ve=(0,me.HA)(30),De=(0,me.HA)(1e3/30),Me=(0,me.HA)(100);var Ce,Oe;!function(e){e.Scheduler=class{get updating(){return this._updating.value}_updatingChanged(){this._updating.value=this._tasks.some((e=>e.needsUpdate))}constructor(){this._updating=(0,de.t)(!0),this._microTaskQueued=!1,this._frameNumber=0,this.performanceInfo={total:new ue.Z("total"),tasks:new Map},this._frameTaskTimes=new Map,this._budget=new s,this._state=Re.n.INTERACTING,this._tasks=new ce.Z,this._runQueue=new ce.Z,this._load=0,this._idleStateCallbacks=new ce.Z,this._idleUpdatesStartFired=!1,this._forceTask=!1,this._debug=!1,this._debugHandle=(0,he.YP)((()=>xe.SCHEDULER_LOG_SLOW_TASKS),(e=>this._debug=e),he.nn);for(const e of Object.keys(Fe))this.performanceInfo.tasks.set(Fe[e],new ue.Z(Fe[e]));const e=this;this._test={FRAME_SAFETY_BUDGET:Ne,INTERACTING_BUDGET:De,IDLE_BUDGET:Me,get availableBudget(){return e._budget.budget},usedBudget:0,getBudget:()=>e._budget,setBudget:t=>e._budget=t,updateTask:e=>this._updateTask(e),getState:e=>this._getState(e),getRuntime:e=>this._getRuntime(e),frameTaskTimes:this._frameTaskTimes,resetRuntimes:()=>this._resetRuntimes(),getRunning:()=>this._getRunning()}}destroy(){this._tasks.toArray().forEach((e=>e.remove())),this._tasks.clear(),(0,o.hw)(this._debugHandle),this._microTaskQueued=!1,this._updatingChanged()}taskRunningChanged(e){this._updatingChanged(),e&&this._budget.remaining>0&&!this._microTaskQueued&&(this._microTaskQueued=!0,queueMicrotask((()=>{this._microTaskQueued&&(this._microTaskQueued=!1,this._budget.remaining>0&&this._schedule()&&this.frame())})))}registerTask(e,s){const i=be(e),r=new t(this,e,s,i);return this._tasks.push(r),this._updatingChanged(),this.performanceInfo.tasks.has(e)||this.performanceInfo.tasks.set(e,new ue.Z(e)),r}registerIdleStateCallbacks(e,t){const s={idleBegin:e,idleEnd:t};this._idleStateCallbacks.push(s),this.state===Re.n.IDLE&&this._idleUpdatesStartFired&&s.idleBegin();const i=this;return{remove:()=>this._removeIdleStateCallbacks(s),set idleBegin(e){i._idleUpdatesStartFired&&(s.idleEnd(),i._state===Re.n.IDLE&&e()),s.idleBegin=e},set idleEnd(e){s.idleEnd=e}}}get load(){return this._load}set state(e){this._state!==e&&(this._state=e,this.state!==Re.n.IDLE&&this._idleUpdatesStartFired&&(this._idleUpdatesStartFired=!1,this._idleStateCallbacks.forAll((e=>e.idleEnd()))))}get state(){return this._state}updateBudget(e){this._test.usedBudget=0,++this._frameNumber;let t=Ne,s=e.frameDuration,i=Ae;switch(this.state){case Re.n.IDLE:t=(0,me.HA)(0),s=(0,me.HA)(Math.max(Me,e.frameDuration)),i=ve;break;case Re.n.INTERACTING:s=(0,me.HA)(Math.max(De,e.frameDuration));case Re.n.ANIMATING:}return s=(0,me.HA)(s-e.elapsedFrameTime-t),this.state!==Re.n.IDLE&&s<Ae&&!this._forceTask?(this._forceTask=!0,!1):(s=(0,me.HA)(Math.max(s,i)),this._budget.reset(s,this.state),this._updateLoad(),this._schedule())}frame(){switch(this._forceTask=!1,this._microTaskQueued=!1,this.state){case Re.n.IDLE:this._idleUpdatesStartFired||(this._idleUpdatesStartFired=!0,this._idleStateCallbacks.forAll((e=>e.idleBegin()))),this._runIdle();break;case Re.n.INTERACTING:this._runInteracting();break;default:this._runAnimating()}this._test.usedBudget=this._budget.elapsed}stopFrame(){this._budget.reset((0,me.HA)(0),this._state),this._budget.madeProgress()}_removeIdleStateCallbacks(e){this._idleUpdatesStartFired&&e.idleEnd(),this._idleStateCallbacks.removeUnordered(e)}removeTask(e){this._tasks.removeUnordered(e),this._runQueue.removeUnordered(e),this._updatingChanged()}_updateTask(e){this._tasks.forAll((t=>{t.name===e&&t.setPriority(e)}))}_getState(e){if(this._runQueue.some((t=>t.name===e)))return Oe.SCHEDULED;let t=Oe.IDLE;return this._tasks.forAll((s=>{s.name===e&&s.needsUpdate&&(s.schedulePriority<=1?t=Oe.READY:t!==Oe.READY&&(t=Oe.WAITING))})),t}_getRuntime(e){let t=0;return this._tasks.forAll((s=>{s.name===e&&(t+=s.runtime)})),t}_resetRuntimes(){this._tasks.forAll((e=>e.runtime=0))}_getRunning(){const e=new Map;if(this._tasks.forAll((t=>{t.needsUpdate&&e.set(t.name,(e.get(t.name)||0)+1)})),0===e.size)return null;let t="";return e.forEach(((e,s)=>{t+=e>1?` ${e}x ${s}`:` ${s}`})),t}_runIdle(){this._run()}_runInteracting(){this._run()}_runAnimating(){this._run()}_updateLoad(){const e=this._tasks.reduce(((e,t)=>t.needsUpdate?++e:e),0);this._load=.9*this._load+e*(1-.9)}_schedule(){for(this._runQueue.filterInPlace((e=>!!e.needsUpdate||(e.schedulePriority=e.basePriority,!1))),this._tasks.forAll((e=>{0===e.basePriority&&e.needsUpdate&&!this._runQueue.includes(e)&&e.blockFrame!==this._frameNumber&&this._runQueue.unshift(e)}));0===this._runQueue.length;){let e=!1,t=0;if(this._tasks.forAll((s=>{s.needsUpdate&&0!==s.schedulePriority&&0!==s.basePriority&&s.blockFrame!==this._frameNumber&&(e=!0,t=Math.max(t,s.basePriority),1===s.schedulePriority?(s.schedulePriority=0,this._runQueue.push(s)):--s.schedulePriority)})),!e)return this._updatingChanged(),!1}return this._updatingChanged(),!0}_run(){const e=this._budget.now();this._startFrameTaskTimes();do{for(;this._runQueue.length>0;){const t=this._budget.now(),s=this._runQueue.pop();this._budget.resetProgress();try{s.task.runTask(this._budget)===Ie.YIELD&&(s.blockFrame=this._frameNumber)}catch(e){le.Z.getLogger("esri.views.support.Scheduler").error(`Exception in task "${s.name}"`,e),s.blockFrame=this._frameNumber}!this._budget.hasProgressed&&s.blockFrame!==this._frameNumber&&s.needsUpdate&&(s.name,Fe.I3S_CONTROLLER,s.blockFrame=this._frameNumber),s.schedulePriority=s.basePriority;const i=this._budget.now()-t;if(s.runtime+=i,this._frameTaskTimes.set(s.priority,this._frameTaskTimes.get(s.priority)+i),this._debug&&i>2*this._budget.budget&&console.log("Task",s.name,"used",i,"of max",this._budget.budget,"ms"),this._budget.remaining<=0)return this._updatingChanged(),void this._recordFrameTaskTimes(this._budget.now()-e)}}while(this._schedule());this._updatingChanged(),this._recordFrameTaskTimes(this._budget.now()-e)}_startFrameTaskTimes(){for(const e of Object.keys(Fe))this._frameTaskTimes.set(Fe[e],0)}_recordFrameTaskTimes(e){this._frameTaskTimes.forEach(((e,t)=>this.performanceInfo.tasks.get(t).record(e))),this.performanceInfo.total.record(e)}get test(){return this._test}};class t{get task(){return this._task.value}get updating(){return this._queue.running}constructor(e,t,s,i){this._scheduler=e,this.name=t,this._basePriority=i,this.blockFrame=0,this.runtime=0,this._queue=new fe,this._handles=new oe.Z,this.schedulePriority=this._basePriority,this._task=(0,de.t)(null!=s?s:this._queue),this._handles.add((0,he.gx)((()=>this.task.running),(t=>e.taskRunningChanged(t))))}remove(){this.processQueue(Pe),this._scheduler.removeTask(this),this.schedule=ke.schedule,this.reschedule=ke.reschedule,this._handles.destroy()}get basePriority(){return this._basePriority}setPriority(e){this.name=e;const t=be(e);0!==this._basePriority&&0===this.schedulePriority||(this.schedulePriority=t),this._basePriority=t}get priority(){return this.name}set priority(e){this.setPriority(e)}get needsUpdate(){return this.updating||this.task.running}schedule(e,t,s){return this._queue.push(e,t,s)}reschedule(e,t,s){return this._queue.unshift(e,t,s)}processQueue(e){this._queue.runTask(e)}}class s{constructor(){this._begin="undefined"!=typeof performance?performance.now():0,this._budget=0,this._state=Re.n.IDLE,this._done=!1,this._progressed=!1,this._enabled=!0}run(e){return!this.done&&(!0===e()&&this.madeProgress(),!0)}get done(){return this._done}get budget(){return this._budget}madeProgress(){return this._progressed=!0,this._done=this.elapsed>=this._budget&&this._enabled,this._done}get state(){return this._state}get enabled(){return this._enabled}set enabled(e){this._enabled=e}reset(e,t){this._begin=this.now(),this._budget=e,this._state=t,this.resetProgress()}get remaining(){return Math.max(this._budget-this.elapsed,0)}now(){return performance.now()}get elapsed(){return performance.now()-this._begin}resetProgress(){this._progressed=!1,this._done=!1}get hasProgressed(){return this._progressed}}e.Budget=s}(Ce||(Ce={})),function(e){e.SCHEDULED="s",e.READY="r",e.WAITING="w",e.IDLE="i"}(Oe||(Oe={}));const Pe=(()=>{const e=new Ce.Budget;return e.enabled=!1,e})(),ke=new class{remove(){}processQueue(){}schedule(e,t,s){try{if((0,u.Hc)(t)){const e=(0,u.zE)();return s?Promise.resolve(s(e)):Promise.reject(e)}return(0,u.gx)(e(Pe))}catch(e){return Promise.reject(e)}}reschedule(e,t,s){return this.schedule(e,t,s)}},Ze=new l.WJ(2e6);let Le=0;class Ge{constructor(e){this._geometryQueryCache=null,this._changeHandle=null,this.capabilities={query:Z.g},this.geometryType=e.geometryType,this.hasM=!!e.hasM,this.hasZ=!!e.hasZ,this.objectIdField=e.objectIdField,this.spatialReference=e.spatialReference,this.definitionExpression=e.definitionExpression,this.featureStore=e.featureStore,this.aggregateAdapter=e.aggregateAdapter,this._changeHandle=this.featureStore.events.on("changed",(()=>this.clearCache())),this.timeInfo=e.timeInfo,e.cacheSpatialQueries&&(this._geometryQueryCache=new l.Xq(Le+++"$$",Ze)),this.fieldsIndex=(0,n.AK)(e.fieldsIndex)?e.fieldsIndex:ae.Z.fromJSON(e.fieldsIndex),this.availableFields=null==e.availableFields?new Set(this.fieldsIndex.fields.map((e=>e.name))):new Set(e.availableFields.map((e=>this.fieldsIndex.get(e)?.name)).filter((e=>null!=e))),e.scheduler&&e.priority&&(this._frameTask=e.scheduler.registerTask(e.priority))}destroy(){this._frameTask=(0,o.hw)(this._frameTask),this.clearCache(),(0,o.SC)(this._geometryQueryCache),this._changeHandle=(0,o.hw)(this._changeHandle)}get featureAdapter(){return this.featureStore.featureAdapter}clearCache(){this._geometryQueryCache?.clear(),this._allFeaturesPromise=null,this._timeExtentPromise=null,this._fullExtentPromise=null}async executeQuery(e,t){try{return(await this._executeQuery(e,{},t)).createQueryResponse()}catch(t){if(t!==X.Ti)throw t;return new H([],e,this).createQueryResponse()}}async executeQueryForCount(e={},t){try{return(await this._executeQuery(e,{returnGeometry:!1,returnCentroid:!1,outSR:null},t)).createQueryResponseForCount()}catch(e){if(e!==X.Ti)throw e;return 0}}async executeQueryForExtent(e,t){const s=e.outSR;try{const i=await this._executeQuery(e,{returnGeometry:!0,returnCentroid:!1,outSR:null},t),r=i.size;return r?{count:r,extent:await this._getBounds(i.items,i.spatialReference,s||this.spatialReference)}:{count:0,extent:null}}catch(e){if(e===X.Ti)return{count:0,extent:null};throw e}}async executeQueryForIds(e,t){return this.executeQueryForIdSet(e,t).then((e=>Array.from(e)))}async executeQueryForIdSet(e,t){try{const s=await this._executeQuery(e,{returnGeometry:!0,returnCentroid:!1,outSR:null},t),i=s.items,r=new Set;return await this._reschedule((()=>{for(const e of i)r.add(s.featureAdapter.getObjectId(e))}),t),r}catch(e){if(e===X.Ti)return new Set;throw e}}async executeQueryForSnapping(e,t){const{point:s,distance:i,returnEdge:r,vertexMode:n}=e;if(!r&&"none"===n)return{candidates:[]};let o=(0,a.d9)(e.query);o=await this._schedule((()=>(0,X.j6)(o,this.definitionExpression,this.spatialReference)),t),o=await this._reschedule((()=>te(o,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference})),t);const l=!(0,g.fS)(s.spatialReference,this.spatialReference);l&&await(0,k._W)(s.spatialReference,this.spatialReference);const u="number"==typeof i?i:i.x,c="number"==typeof i?i:i.y,h={xmin:s.x-u,xmax:s.x+u,ymin:s.y-c,ymax:s.y+c,spatialReference:s.spatialReference},d=l?(0,k.iV)(h,this.spatialReference):h;if(!d)return{candidates:[]};const m=(await(0,y.aX)((0,p.im)(s),null,{signal:t}))[0],f=(await(0,y.aX)((0,p.im)(d),null,{signal:t}))[0];if(null==m||null==f)return{candidates:[]};const _=new H(await this._reschedule((()=>this._searchFeatures(this._getQueryBBoxes(f.toJSON()))),t),o,this);await this._reschedule((()=>this._executeObjectIdsQuery(_)),t),await this._reschedule((()=>this._executeTimeQuery(_)),t),await this._reschedule((()=>this._executeAttributesQuery(_)),t),await this._reschedule((()=>this._executeGeometryQueryForSnapping(_,t)),t);const T=m.toJSON(),S=l?(0,k.iV)(T,this.spatialReference):T,x=l?Math.max(d.xmax-d.xmin,d.ymax-d.ymin)/2:i;return _.createSnappingResponse({...e,point:S,distance:x},s.spatialReference)}async executeQueryForLatestObservations(e,t){if(!this.timeInfo?.trackIdField)throw new r.Z("unsupported-query","Missing timeInfo or timeInfo.trackIdField",{query:e,timeInfo:this.timeInfo});try{const s=await this._executeQuery(e,{},t);return await this._reschedule((()=>this._filterLatest(s)),t),s.createQueryResponse()}catch(t){if(t!==X.Ti)throw t;return new H([],e,this).createQueryResponse()}}async executeQueryForSummaryStatistics(e={},t,s){const{field:i,normalizationField:r,valueExpression:n}=t;return(await this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n},s)).createSummaryStatisticsResponse(t)}async executeQueryForUniqueValues(e={},t,s){const{field:i,field2:r,field3:n,valueExpression:a}=t;return(await this._executeQueryForStatistics(e,{field:i,field2:r,field3:n,valueExpression:a},s)).createUniqueValuesResponse(t)}async executeQueryForClassBreaks(e={},t,s){const{field:i,normalizationField:r,valueExpression:n}=t;return(await this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n},s)).createClassBreaksResponse(t)}async executeQueryForHistogram(e={},t,s){const{field:i,normalizationField:r,valueExpression:n}=t;return(await this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n},s)).createHistogramResponse(t)}async fetchRecomputedExtents(e){this._timeExtentPromise||=(0,ne.R)(this.timeInfo,this.featureStore);const[t,s]=await Promise.all([this._getFullExtent(),this._timeExtentPromise]);return(0,u.k_)(e),{fullExtent:t,timeExtent:s}}async _getBounds(e,t,s){const i=(0,d.t8)((0,d.Ue)(),d.G_);await this.featureStore.forEachBounds(e,(e=>(0,d.TC)(i,e)));const r={xmin:i[0],ymin:i[1],xmax:i[3],ymax:i[4],spatialReference:(0,P.S2)(this.spatialReference)};this.hasZ&&isFinite(i[2])&&isFinite(i[5])&&(r.zmin=i[2],r.zmax=i[5]);const n=(0,k.iV)(r,t,s);if(n.spatialReference=(0,P.S2)(s),n.xmax-n.xmin==0){const e=(0,c.c9)(n.spatialReference);n.xmin-=e,n.xmax+=e}if(n.ymax-n.ymin==0){const e=(0,c.c9)(n.spatialReference);n.ymin-=e,n.ymax+=e}if(this.hasZ&&null!=n.zmin&&null!=n.zmax&&n.zmax-n.zmin==0){const e=(0,c.c9)(n.spatialReference);n.zmin-=e,n.zmax+=e}return n}_getFullExtent(){return this._fullExtentPromise||="getFullExtent"in this.featureStore&&this.featureStore.getFullExtent?Promise.resolve(this.featureStore.getFullExtent(this.spatialReference)):this._getAllFeatures().then((e=>this._getBounds(e,this.spatialReference,this.spatialReference))),this._fullExtentPromise}async _schedule(e,t){return null!=this._frameTask?this._frameTask.schedule(e,t):e(Pe)}async _reschedule(e,t){return null!=this._frameTask?this._frameTask.reschedule(e,t):e(Pe)}async _getAllFeaturesQueryEngineResult(e){return new H(await this._getAllFeatures(),e,this)}async _getAllFeatures(){if(null==this._allFeaturesPromise){const e=[];this._allFeaturesPromise=(async()=>{await this.featureStore.forEach((t=>e.push(t)))})().then((()=>e))}const e=this._allFeaturesPromise,t=await e;return e===this._allFeaturesPromise?t.slice():this._getAllFeatures()}async _executeQuery(e,t,s){e=(0,a.d9)(e),e=await this._schedule((()=>(0,X.Up)(e,this.definitionExpression,this.spatialReference)),s),e=await this._reschedule((()=>te(e,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference})),s),e={...e,...t};const i=await this._reschedule((()=>this._executeSceneFilterQuery(e,s)),s),r=await this._reschedule((()=>this._executeGeometryQuery(e,i,s)),s);return await this._reschedule((()=>this._executeAggregateIdsQuery(r)),s),await this._reschedule((()=>this._executeObjectIdsQuery(r)),s),await this._reschedule((()=>this._executeTimeQuery(r)),s),await this._reschedule((()=>this._executeAttributesQuery(r)),s),r}async _executeSceneFilterQuery(e,t){if(null==e.sceneFilter)return null;const{outSR:s,returnGeometry:i,returnCentroid:r}=e,n=this.featureStore.featureSpatialReference,a=e.sceneFilter.geometry,o=null==n||(0,g.fS)(n,a.spatialReference)?a:(0,k.iV)(a,n);if(!o)return null;const l=i||r,u=(0,g.JY)(s)&&!(0,g.fS)(this.spatialReference,s)&&l?async e=>this._project(e,s):e=>e,c=this.featureAdapter,h=await this._reschedule((()=>this._searchFeatures(this._getQueryBBoxes(o))),t);if("disjoint"===e.sceneFilter.spatialRelationship){if(!h.length)return null;const s=new Set;for(const e of h)s.add(c.getObjectId(e));const i=await this._reschedule((()=>this._getAllFeatures()),t),r=await this._reschedule((async()=>{const r=await(0,K.cW)("esriSpatialRelDisjoint",o,this.geometryType,this.hasZ,this.hasM),n=await this._runSpatialFilter(i,(e=>!s.has(c.getObjectId(e))||r(c.getGeometry(e))),t);return new H(n,e,this)}),t);return u(r)}if(!h.length)return new H([],e,this);if(this._canExecuteSinglePass(o,e))return u(new H(h,e,this));const d=await(0,K.cW)("esriSpatialRelContains",o,this.geometryType,this.hasZ,this.hasM),m=await this._runSpatialFilter(h,(e=>d(c.getGeometry(e))),t);return u(new H(m,e,this))}async _executeGeometryQuery(e,t,s){if(null!=t&&0===t.items.length)return t;e=null!=t?t.query:e;const{geometry:r,outSR:n,spatialRel:a,returnGeometry:o,returnCentroid:l}=e,u=this.featureStore.featureSpatialReference,c=!r||null==u||(0,g.fS)(u,r.spatialReference)?r:(0,k.iV)(r,u),h=o||l,d=(0,g.JY)(n)&&!(0,g.fS)(this.spatialReference,n),m=this._geometryQueryCache&&null==t?d&&h?JSON.stringify({originalFilterGeometry:r,spatialRelationship:a,outSpatialReference:n}):JSON.stringify({originalFilterGeometry:r,spatialRelationship:a}):null,f=m?this._geometryQueryCache.get(m):null;if(null!=f)return new H(f,e,this);const p=async e=>(d&&h&&await this._project(e,n),m&&this._geometryQueryCache.put(m,e.items,e.items.length+1),e);if(!c)return p(null!=t?t:await this._getAllFeaturesQueryEngineResult(e));const y=this.featureAdapter;let _=await this._reschedule((()=>this._searchFeatures(this._getQueryBBoxes(r))),s);if("esriSpatialRelDisjoint"===a){if(!_.length)return p(null!=t?t:await this._getAllFeaturesQueryEngineResult(e));const i=new Set;for(const e of _)i.add(y.getObjectId(e));const r=null!=t?t.items:await this._reschedule((()=>this._getAllFeatures()),s),n=await this._reschedule((async()=>{const t=await(0,K.cW)(a,c,this.geometryType,this.hasZ,this.hasM),n=await this._runSpatialFilter(r,(e=>!i.has(y.getObjectId(e))||t(y.getGeometry(e))),s);return new H(n,e,this)}),s);return p(n)}if(null!=t){const e=new i.SO;_=_.filter((s=>(0,i.cq)(t.items,s,t.items.length,e)>=0))}if(!_.length){const t=new H([],e,this);return m&&this._geometryQueryCache.put(m,t.items,1),t}if(this._canExecuteSinglePass(c,e))return p(new H(_,e,this));const T=await(0,K.cW)(a,c,this.geometryType,this.hasZ,this.hasM),S=await this._runSpatialFilter(_,(e=>T(y.getGeometry(e))),s);return p(new H(S,e,this))}async _executeGeometryQueryForSnapping(e,t){const{query:s}=e,{spatialRel:i}=s;if(!e?.items?.length||!s.geometry||!i)return;const r=await(0,K.cW)(i,s.geometry,this.geometryType,this.hasZ,this.hasM),n=await this._runSpatialFilter(e.items,(e=>r(e.geometry)),t);e.items=n}_executeAggregateIdsQuery(e){if(0===e.items.length||!e.query.aggregateIds?.length||null==this.aggregateAdapter)return;const t=new Set;for(const s of e.query.aggregateIds)this.aggregateAdapter.getFeatureObjectIds(s).forEach((e=>t.add(e)));const s=this.featureAdapter.getObjectId;e.items=e.items.filter((e=>t.has(s(e))))}_executeObjectIdsQuery(e){if(0===e.items.length||!e.query.objectIds?.length)return;const t=new Set(e.query.objectIds),s=this.featureAdapter.getObjectId;e.items=e.items.filter((e=>t.has(s(e))))}_executeTimeQuery(e){if(0===e.items.length)return;const t=(0,ne.y)(this.timeInfo,e.query.timeExtent,this.featureAdapter);null!=t&&(e.items=e.items.filter(t))}_executeAttributesQuery(e){if(0===e.items.length)return;const t=v(e.query.where,this.fieldsIndex);if(t){if(!t.isStandardized)throw new TypeError("Where clause is not standardized");e.items=e.items.filter((e=>t.testFeature(e,this.featureAdapter)))}}async _runSpatialFilter(e,t,s){if(!t)return e;if(null==this._frameTask)return e.filter((e=>t(e)));let i=0;const r=new Array,n=async a=>{for(;i<e.length;){const o=e[i++];t(o)&&(r.push(o),a.madeProgress()),a.done&&await this._reschedule((e=>n(e)),s)}};return this._reschedule((e=>n(e)),s).then((()=>r))}_filterLatest(e){const{trackIdField:t,startTimeField:s,endTimeField:i}=this.timeInfo,r=i||s,n=new Map,a=this.featureAdapter.getAttribute;for(const s of e.items){const e=a(s,t),i=a(s,r),o=n.get(e);(!o||i>a(o,r))&&n.set(e,s)}e.items=Array.from(n.values())}_canExecuteSinglePass(e,t){const{spatialRel:s}=t;return(0,K.hN)(e)&&("esriSpatialRelEnvelopeIntersects"===s||"esriGeometryPoint"===this.geometryType&&("esriSpatialRelIntersects"===s||"esriSpatialRelContains"===s))}async _project(e,t){if(!t||(0,g.fS)(this.spatialReference,t))return e;const s=this.featureAdapter;let i;try{const e=await this._getFullExtent();i=(0,h.getTransformation)(this.spatialReference,t,e)}catch{}const r=await(0,k.oj)(e.items.map((e=>(0,P.Op)(this.geometryType,this.hasZ,this.hasM,s.getGeometry(e)))),this.spatialReference,t,i);return e.items=r.map(((t,i)=>s.cloneWithGeometry(e.items[i],(0,_.GH)(t,this.hasZ,this.hasM)))),e}_getQueryBBoxes(e){if((0,K.hN)(e)){if((0,p.YX)(e))return[(0,m.al)(Math.min(e.xmin,e.xmax),Math.min(e.ymin,e.ymax),Math.max(e.xmin,e.xmax),Math.max(e.ymin,e.ymax))];if((0,p.oU)(e))return e.rings.map((e=>(0,m.al)(Math.min(e[0][0],e[2][0]),Math.min(e[0][1],e[2][1]),Math.max(e[0][0],e[2][0]),Math.max(e[0][1],e[2][1]))))}return[(0,f.$P)((0,m.Ue)(),e)]}async _searchFeatures(e){const t=new Set;await Promise.all(e.map((e=>this.featureStore.forEachInBounds(e,(e=>t.add(e))))));const s=Array.from(t.values());return t.clear(),s}async _executeQueryForStatistics(e,t,s){e=(0,a.d9)(e);try{e=await this._schedule((()=>(0,X.Up)(e,this.definitionExpression,this.spatialReference)),s),e=await this._reschedule((()=>async function(e,t,{fieldsIndex:s,geometryType:i,spatialReference:n,availableFields:a}){if((e.distance??0)<0||null!=e.geometryPrecision||e.multipatchOption||e.pixelSize||e.relationParam||e.text||e.outStatistics||e.groupByFieldsForStatistics||e.having||e.orderByFields)throw new r.Z(ee,"Unsupported query options",{query:e});return se(s,a,e),Promise.all([re(s,a,t,e),(0,K.P0)(e,i,n),(0,k._W)(n,e.outSR)]).then((()=>e))}(e,t,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference})),s);const i=await this._reschedule((()=>this._executeSceneFilterQuery(e,s)),s),n=await this._reschedule((()=>this._executeGeometryQuery(e,i,s)),s);return await this._reschedule((()=>this._executeAggregateIdsQuery(n)),s),await this._reschedule((()=>this._executeObjectIdsQuery(n)),s),await this._reschedule((()=>this._executeTimeQuery(n)),s),await this._reschedule((()=>this._executeAttributesQuery(n)),s),n}catch(t){if(t!==X.Ti)throw t;return new H([],e,this)}}}},61159:(e,t,s)=>{s.d(t,{g:()=>i});const i={supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!0,supportsCacheHint:!1,supportsDistance:!0,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0}},42712:(e,t,s)=>{s.d(t,{EG:()=>u,Op:()=>c,S2:()=>h});var i=s(98732),r=s(5428);const n=new r.Z,a=new r.Z,o=new r.Z,l={esriGeometryPoint:i.fQ,esriGeometryPolyline:i.J6,esriGeometryPolygon:i.eG,esriGeometryMultipoint:i.Iv};function u(e,t,s,r=e.hasZ,n=e.hasM){if(null==t)return null;const a=e.hasZ&&r,l=e.hasM&&n;if(s){const u=(0,i.Nh)(o,t,e.hasZ,e.hasM,"esriGeometryPoint",s,r,n);return(0,i.fQ)(u,a,l)}return(0,i.fQ)(t,a,l)}function c(e,t,s,r,u,c,h=t,d=s){const m=t&&h,f=s&&d,p=null!=r?"coords"in r?r:r.geometry:null;if(null==p)return null;if(u){let r=(0,i.zj)(a,p,t,s,e,u,h,d);return c&&(r=(0,i.Nh)(o,r,m,f,e,c)),l[e]?.(r,m,f)??null}if(c){const r=(0,i.Nh)(o,p,t,s,e,c,h,d);return l[e]?.(r,m,f)??null}return(0,i.hY)(n,p,t,s,h,d),l[e]?.(n,m,f)??null}function h(e){return e&&d in e?JSON.parse(JSON.stringify(e,m)):e}const d="_geVersion",m=(e,t)=>e!==d?t:void 0},37427:(e,t,s)=>{s.d(t,{_W:()=>m,iV:()=>y,oj:()=>_});var i=s(67676),r=s(95330),n=s(73615),a=s(37455),o=s(8744),l=s(40488);const u=[0,0];function c(e,t){if(!t)return null;if("x"in t){const s={x:0,y:0};return[s.x,s.y]=e(t.x,t.y,u),null!=t.z&&(s.z=t.z),null!=t.m&&(s.m=t.m),s}if("xmin"in t){const s={xmin:0,ymin:0,xmax:0,ymax:0};return[s.xmin,s.ymin]=e(t.xmin,t.ymin,u),[s.xmax,s.ymax]=e(t.xmax,t.ymax,u),t.hasZ&&(s.zmin=t.zmin,s.zmax=t.zmax,s.hasZ=!0),t.hasM&&(s.mmin=t.mmin,s.mmax=t.mmax,s.hasM=!0),s}return"rings"in t?{rings:h(t.rings,e),hasM:t.hasM,hasZ:t.hasZ}:"paths"in t?{paths:h(t.paths,e),hasM:t.hasM,hasZ:t.hasZ}:"points"in t?{points:d(t.points,e),hasM:t.hasM,hasZ:t.hasZ}:null}function h(e,t){const s=[];for(const i of e)s.push(d(i,t));return s}function d(e,t){const s=[];for(const i of e){const e=t(i[0],i[1],[0,0]);s.push(e),i.length>2&&e.push(i[2]),i.length>3&&e.push(i[3])}return s}async function m(e,t){if(!e||!t)return;const s=Array.isArray(e)?e.map((e=>null!=e.geometry?e.geometry.spatialReference:null)).filter(i.pC):[e];await(0,n.initializeProjection)(s.map((e=>({source:e,dest:t}))))}const f=c.bind(null,l.hG),p=c.bind(null,l.R6);function y(e,t,s,i){if(!e)return e;if(s||(s=t,t=e.spatialReference),!(0,o.JY)(t)||!(0,o.JY)(s)||(0,o.fS)(t,s))return e;if((0,l.Q8)(t,s)){const t=(0,o.sS)(s)?f(e):p(e);return t.spatialReference=s,t}return(0,n.projectMany)(a.N,[e],t,s,null,i)[0]}const g=new class{constructor(){this._jobs=[],this._timer=null,this._process=this._process.bind(this)}async push(e,t,s,i){if(!e?.length||!t||!s||(0,o.fS)(t,s))return e;const n={geometries:e,inSpatialReference:t,outSpatialReference:s,geographicTransformation:i,resolve:(0,r.hh)()};return this._jobs.push(n),this._timer??=setTimeout(this._process,10),n.resolve.promise}_process(){this._timer=null;const e=this._jobs.shift();if(!e)return;const{geometries:t,inSpatialReference:s,outSpatialReference:i,resolve:r,geographicTransformation:u}=e;(0,l.Q8)(s,i)?(0,o.sS)(i)?r(t.map(f)):r(t.map(p)):r((0,n.projectMany)(a.N,t,s,i,u,null)),this._jobs.length>0&&(this._timer=setTimeout(this._process,10))}};function _(e,t,s,i){return g.push(e,t,s,i)}},22222:(e,t,s)=>{s.d(t,{Ti:()=>d,Up:()=>m,j6:()=>f});var i=s(35454),r=s(67900),n=s(73615),a=s(49600),o=s(33955),l=s(16306),u=s(8744),c=s(37427);const h=new i.X({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"}),d=Object.freeze({});async function m(e,t,s){const{outFields:i,orderByFields:r,groupByFieldsForStatistics:n,outStatistics:a}=e;if(i)for(let e=0;e<i.length;e++)i[e]=i[e].trim();if(r)for(let e=0;e<r.length;e++)r[e]=r[e].trim();if(n)for(let e=0;e<n.length;e++)n[e]=n[e].trim();if(a)for(let e=0;e<a.length;e++)a[e].onStatisticField&&(a[e].onStatisticField=a[e].onStatisticField.trim());return e.geometry&&!e.outSR&&(e.outSR=e.geometry.spatialReference),f(e,t,s)}async function f(e,t,i){if(!e)return null;let{where:n}=e;if(e.where=n=n?.trim(),(!n||/^1 *= *1$/.test(n)||t&&t===n)&&(e.where=null),!e.geometry)return e;let m=await async function(e){const{distance:t,units:i}=e,n=e.geometry;if(null==t||"vertexAttributes"in n)return n;const a=n.spatialReference,o=i?h.fromJSON(i):(0,r.qE)(a),l=a&&((0,u.sT)(a)||(0,u.sS)(a))?n:await(0,c._W)(a,u.Zn).then((()=>(0,c.iV)(n,u.Zn)));return(await async function(){return(await Promise.all([s.e(5837),s.e(247)]).then(s.bind(s,30247))).geodesicBuffer}())(l.spatialReference,l,t,o)}(e);if(e.distance=0,e.units=null,"esriSpatialRelEnvelopeIntersects"===e.spatialRel){const{spatialReference:t}=e.geometry;m=(0,a.aO)(m),m.spatialReference=t}if(m){await(0,c._W)(m.spatialReference,i),m=function(e,t){const s=e.spatialReference;return p(e,t)&&(0,o.YX)(e)?{spatialReference:s,rings:[[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]]]}:e}(m,i);const t=(await(0,l.aX)((0,o.im)(m)))[0];if(null==t)throw d;const s="quantizationParameters"in e&&e.quantizationParameters?.tolerance||"maxAllowableOffset"in e&&e.maxAllowableOffset||0,r=s&&p(m,i)?{densificationStep:8*s}:void 0,n=t.toJSON(),a=(0,c.iV)(n,n.spatialReference,i,r);if(!a)throw d;a.spatialReference=i,e.geometry=a}return e}function p(e,t){if(!e)return!1;const s=e.spatialReference;return((0,o.YX)(e)||(0,o.oU)(e)||(0,o.l9)(e))&&!(0,u.fS)(s,t)&&!(0,n.canProjectWithoutEngine)(s,t)}},10402:(e,t,s)=>{s.d(t,{hN:()=>x,P0:()=>S,cW:()=>T});var i=s(20102),r=s(54102),n=s(87416),a=s(33955),o=s(8744);function l(e,t){return e?t?4:3:t?3:2}function u(e,t,s,i,r,n){const a=l(r,n),{coords:o,lengths:u}=i;if(!u)return!1;for(let i=0,r=0;i<u.length;i++,r+=a)if(!c(e,t,s,o[r],o[r+1]))return!1;return!0}function c(e,t,s,i,r){if(!e)return!1;const n=l(t,s),{coords:a,lengths:o}=e;let u=!1,c=0;for(const e of o)u=h(u,a,n,c,e,i,r),c+=e*n;return u}function h(e,t,s,i,r,n,a){let o=e,l=i;for(let e=i,u=i+r*s;e<u;e+=s){l=e+s,l===u&&(l=i);const r=t[e],c=t[e+1],h=t[l],d=t[l+1];(c<a&&d>=a||d<a&&c>=a)&&r+(a-c)/(d-c)*(h-r)<n&&(o=!o)}return o}var d=s(98732),m=s(5428),f=s(42712),p=s(37427);const y="unsupported-query",g={esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"intersects",esriSpatialRelIndexIntersects:null,esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:null},_={spatialRelationship:{esriSpatialRelIntersects:!0,esriSpatialRelContains:!0,esriSpatialRelWithin:!0,esriSpatialRelCrosses:!0,esriSpatialRelDisjoint:!0,esriSpatialRelTouches:!0,esriSpatialRelOverlaps:!0,esriSpatialRelEnvelopeIntersects:!0,esriSpatialRelIndexIntersects:!1,esriSpatialRelRelation:!1},queryGeometry:{esriGeometryPoint:!0,esriGeometryMultipoint:!0,esriGeometryPolyline:!0,esriGeometryPolygon:!0,esriGeometryEnvelope:!0},layerGeometry:{esriGeometryPoint:!0,esriGeometryMultipoint:!0,esriGeometryPolyline:!0,esriGeometryPolygon:!0,esriGeometryEnvelope:!1}};function T(e,t,i,o,l){if((0,a.oU)(t)&&"esriGeometryPoint"===i&&("esriSpatialRelIntersects"===e||"esriSpatialRelContains"===e)){const e=(0,d.Uy)(new m.Z,t,!1,!1);return Promise.resolve((t=>function(e,t,s,i){return c(e,!1,!1,i.coords[0],i.coords[1])}(e,0,0,t)))}if((0,a.oU)(t)&&"esriGeometryMultipoint"===i){const s=(0,d.Uy)(new m.Z,t,!1,!1);if("esriSpatialRelContains"===e)return Promise.resolve((e=>u(s,!1,!1,e,o,l)))}if((0,a.YX)(t)&&"esriGeometryPoint"===i&&("esriSpatialRelIntersects"===e||"esriSpatialRelContains"===e))return Promise.resolve((e=>(0,r.aV)(t,(0,f.Op)(i,o,l,e))));if((0,a.YX)(t)&&"esriGeometryMultipoint"===i&&"esriSpatialRelContains"===e)return Promise.resolve((e=>(0,r.lQ)(t,(0,f.Op)(i,o,l,e))));if((0,a.YX)(t)&&"esriSpatialRelIntersects"===e){const e="mesh"===(h=i)?n.h_:(0,n.IY)(h);return Promise.resolve((s=>e(t,(0,f.Op)(i,o,l,s))))}var h;return Promise.all([s.e(5837),s.e(247)]).then(s.bind(s,30247)).then((s=>{const r=s[g[e]].bind(null,t.spatialReference,t);return e=>r((0,f.Op)(i,o,l,e))}))}async function S(e,t,s){const{spatialRel:r,geometry:n}=e;if(n){if(!function(e){return null!=e&&!0===_.spatialRelationship[e]}(r))throw new i.Z(y,"Unsupported query spatial relationship",{query:e});if((0,o.JY)(n.spatialReference)&&(0,o.JY)(s)){if(!function(e){return null!=e&&!0===_.queryGeometry[(0,a.Ji)(e)]}(n))throw new i.Z(y,"Unsupported query geometry type",{query:e});if(!function(e){return null!=e&&!0===_.layerGeometry[e]}(t))throw new i.Z(y,"Unsupported layer geometry type",{query:e});if(e.outSR)return(0,p._W)(e.geometry?.spatialReference,e.outSR)}}}function x(e){if((0,a.YX)(e))return!0;if((0,a.oU)(e)){for(const t of e.rings){if(5!==t.length)return!1;if(t[0][0]!==t[1][0]||t[0][0]!==t[4][0]||t[2][0]!==t[3][0]||t[0][1]!==t[3][1]||t[0][1]!==t[4][1]||t[1][1]!==t[2][1])return!1}return!0}return!1}},17590:(e,t,s)=>{async function i(e,t){if(!e)return null;const s=t.featureAdapter,{startTimeField:i,endTimeField:r}=e;let n=Number.POSITIVE_INFINITY,a=Number.NEGATIVE_INFINITY;if(i&&r)await t.forEach((e=>{const t=s.getAttribute(e,i),o=s.getAttribute(e,r);null==t||isNaN(t)||(n=Math.min(n,t)),null==o||isNaN(o)||(a=Math.max(a,o))}));else{const e=i||r;await t.forEach((t=>{const i=s.getAttribute(t,e);null==i||isNaN(i)||(n=Math.min(n,i),a=Math.max(a,i))}))}return{start:n,end:a}}function r(e,t,s){if(!t||!e)return null;const{startTimeField:i,endTimeField:r}=e;if(!i&&!r)return null;const{start:n,end:a}=t;if(null===n&&null===a)return null;if(void 0===n&&void 0===a)return()=>!1;const o=s.getAttributeAsTimestamp?.bind(s)??s.getAttribute.bind(s);return i&&r?function(e,t,s,i,r){return null!=i&&null!=r?n=>{const a=e(n,t),o=e(n,s);return(null==a||a<=r)&&(null==o||o>=i)}:null!=i?t=>{const r=e(t,s);return null==r||r>=i}:null!=r?s=>{const i=e(s,t);return null==i||i<=r}:void 0}(o,i,r,n,a):function(e,t,s,i){return null!=s&&null!=i&&s===i?i=>e(i,t)===s:null!=s&&null!=i?r=>{const n=e(r,t);return null!=n&&n>=s&&n<=i}:null!=s?i=>{const r=e(i,t);return null!=r&&r>=s}:null!=i?s=>{const r=e(s,t);return null!=r&&r<=i}:void 0}(o,i||r,n,a)}s.d(t,{R:()=>i,y:()=>r})},98732:(e,t,s)=>{s.d(t,{$:()=>se,$g:()=>ie,EI:()=>Q,GH:()=>Y,IN:()=>x,Iv:()=>O,J6:()=>k,Jd:()=>S,Nh:()=>X,RZ:()=>W,Uy:()=>G,XA:()=>V,Yn:()=>z,cn:()=>H,dd:()=>C,di:()=>j,eG:()=>L,fQ:()=>F,hY:()=>re,h_:()=>$,lM:()=>J,lz:()=>ae,zj:()=>K});var i=s(20102),r=s(92604),n=s(70586),a=s(60437),o=s(24470),l=s(33955),u=s(70272),c=s(44876),h=s(5428);function d(e,t){return e?t?4:3:t?3:2}const m=r.Z.getLogger("esri.layers.graphics.featureConversionUtils"),f={esriGeometryPoint:0,esriGeometryPolyline:2,esriGeometryPolygon:3,esriGeometryMultipoint:0,esriGeometryEnvelope:0},p=(e,t,s,i,r,n)=>{e[s]=r,e[s+1]=n},y=(e,t,s,i,r,n)=>{e[s]=r,e[s+1]=n,e[s+2]=t[i+2]},g=(e,t,s,i,r,n)=>{e[s]=r,e[s+1]=n,e[s+2]=t[i+3]},_=(e,t,s,i,r,n)=>{e[s]=r,e[s+1]=n,e[s+2]=t[i+2],e[s+3]=t[i+3]};function T(e,t,s,i){if(e){if(s)return t&&i?_:y;if(t&&i)return g}else if(t&&i)return y;return p}function S({scale:e,translate:t},s){return Math.round((s-t[0])/e[0])}function x({scale:e,translate:t},s){return Math.round((t[1]-s)/e[1])}function I({scale:e,translate:t},s,i){return s*e[i]+t[i]}function F(e,t,s){return e?t?s?v(e):E(e):s?N(e):w(e):null}function w(e){const t=e.coords;return{x:t[0],y:t[1]}}function R(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e}function E(e){const t=e.coords;return{x:t[0],y:t[1],z:t[2]}}function b(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.z,e}function N(e){const t=e.coords;return{x:t[0],y:t[1],m:t[2]}}function A(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.m,e}function v(e){const t=e.coords;return{x:t[0],y:t[1],z:t[2],m:t[3]}}function D(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.z,e.coords[3]=t.m,e}function M(e,t){return e&&t?D:e?b:t?A:R}function C(e,t,s=M(null!=t.z,null!=t.m)){return s(e,t)}function O(e,t,s){if(null==e)return null;const i=d(t,s),r=[];for(let t=0;t<e.coords.length;t+=i){const s=[];for(let r=0;r<i;r++)s.push(e.coords[t+r]);r.push(s)}return t?s?{points:r,hasZ:t,hasM:s}:{points:r,hasZ:t}:s?{points:r,hasM:s}:{points:r}}function P(e,t,s=d(t.hasZ,t.hasM)){e.lengths[0]=t.points.length;const i=e.coords;let r=0;for(const e of t.points)for(let t=0;t<s;t++)i[r++]=e[t];return e}function k(e,t,s){if(!e)return null;const i=d(t,s),{coords:r,lengths:n}=e,a=[];let o=0;for(const e of n){const t=[];for(let s=0;s<e;s++){const e=[];for(let t=0;t<i;t++)e.push(r[o++]);t.push(e)}a.push(t)}return t?s?{paths:a,hasZ:t,hasM:s}:{paths:a,hasZ:t}:s?{paths:a,hasM:s}:{paths:a}}function Z(e,t,s=d(t.hasZ,t.hasM)){const{lengths:i,coords:r}=e;let n=0;for(const e of t.paths){for(const t of e)for(let e=0;e<s;e++)r[n++]=t[e];i.push(e.length)}return e}function L(e,t,s){if(!e)return null;const i=d(t,s),{coords:r,lengths:n}=e,a=[];let o=0;for(const e of n){const t=[];for(let s=0;s<e;s++){const e=[];for(let t=0;t<i;t++)e.push(r[o++]);t.push(e)}a.push(t)}return t?s?{rings:a,hasZ:t,hasM:s}:{rings:a,hasZ:t}:s?{rings:a,hasM:s}:{rings:a}}function G(e,t,s=t.hasZ,i=t.hasM){return function(e,t,s,i){const r=d(s,i),{lengths:n,coords:a}=e;let o=0;oe(e);for(const e of t){for(const t of e)for(let e=0;e<r;e++)a[o++]=t[e];n.push(e.length)}return e}(e,t.rings,s,i)}const U=[],q=[];function V(e,t,s,i,r){U[0]=e;const[n]=z(q,U,t,s,i,r);return le(U),le(q),n}function z(e,t,s,r,n,a){if(le(e),!s){for(const s of t){const t=a?s.attributes[a]:void 0;e.push(new u.u_(null,s.attributes,null,t))}return e}switch(s){case"esriGeometryPoint":return function(e,t,s,i,r){const n=M(s,i);for(const{geometry:s,attributes:i}of t){const t=null!=s?n(new h.Z,s):null;e.push(new u.u_(t,i,null,r?i[r]:void 0))}return e}(e,t,r,n,a);case"esriGeometryMultipoint":return function(e,t,s,i,r){const n=d(s,i);for(const{geometry:s,attributes:i}of t){const t=null!=s?P(new h.Z,s,n):null;e.push(new u.u_(t,i,null,r?i[r]:void 0))}return e}(e,t,r,n,a);case"esriGeometryPolyline":return function(e,t,s,i,r){const n=d(s,i);for(const{geometry:s,attributes:i}of t){const t=null!=s?Z(new h.Z,s,n):null;e.push(new u.u_(t,i,null,r?i[r]:void 0))}return e}(e,t,r,n,a);case"esriGeometryPolygon":return function(e,t,s,i,r){for(const{geometry:n,centroid:a,attributes:o}of t){const t=null!=n?G(new h.Z,n,s,i):null,l=r?o[r]:void 0;null!=a?e.push(new u.u_(t,o,R(new h.Z,a),l)):e.push(new u.u_(t,o,null,l))}return e}(e,t,r,n,a);default:m.error("convertToFeatureSet:unknown-geometry",new i.Z(`Unable to parse unknown geometry type '${s}'`)),le(e)}return e}function Q(e,t,s,i){q[0]=e,B(U,q,t,s,i);const r=U[0];return le(U),le(q),r}function Y(e,t,s){if(null==e)return null;const r=new h.Z;return"hasZ"in e&&null==t&&(t=e.hasZ),"hasM"in e&&null==s&&(s=e.hasM),(0,l.wp)(e)?M(null!=t?t:null!=e.z,null!=s?s:null!=e.m)(r,e):(0,l.oU)(e)?G(r,e,t,s):(0,l.l9)(e)?Z(r,e,d(t,s)):(0,l.aW)(e)?P(r,e,d(t,s)):void m.error("convertFromGeometry:unknown-geometry",new i.Z(`Unable to parse unknown geometry type '${e}'`))}function j(e,t,s,r){const n=e&&("coords"in e?e:e.geometry);if(null==n)return null;switch(t){case"esriGeometryPoint":{let e=w;return s&&r?e=v:s?e=E:r&&(e=N),e(n)}case"esriGeometryMultipoint":return O(n,s,r);case"esriGeometryPolyline":return k(n,s,r);case"esriGeometryPolygon":return L(n,s,r);default:return m.error("convertToGeometry:unknown-geometry",new i.Z(`Unable to parse unknown geometry type '${t}'`)),null}}function B(e,t,s,r,n){if(le(e),null==s)return function(e,t){for(const s of t)e.push({attributes:s.attributes});return e}(e,t);switch(s){case"esriGeometryPoint":return function(e,t,s,i){let r=w;s&&i?r=v:s?r=E:i&&(r=N);for(const s of t){const{geometry:t,attributes:i}=s,n=null!=t?r(t):null;e.push({attributes:i,geometry:n})}return e}(e,t,r,n);case"esriGeometryMultipoint":return function(e,t,s,i){for(const{geometry:r,attributes:n}of t)e.push({attributes:n,geometry:null!=r?O(r,s,i):null});return e}(e,t,r,n);case"esriGeometryPolyline":return function(e,t,s,i){for(const{geometry:r,attributes:n}of t)e.push({attributes:n,geometry:null!=r?k(r,s,i):null});return e}(e,t,r,n);case"esriGeometryPolygon":return function(e,t,s,i){for(const{geometry:r,attributes:n,centroid:a}of t){const t=null!=r?L(r,s,i):null;if(null!=a){const s=w(a);e.push({attributes:n,centroid:s,geometry:t})}else e.push({attributes:n,geometry:t})}return e}(e,t,r,n);default:m.error("convertToFeatureSet:unknown-geometry",new i.Z(`Unable to parse unknown geometry type '${s}'`))}return e}function H(e){const{objectIdFieldName:t,spatialReference:s,transform:i,fields:r,hasM:n,hasZ:a,features:o,geometryType:l,exceededTransferLimit:u,uniqueIdField:c,queryGeometry:h,queryGeometryType:d}=e,m={features:B([],o,l,a,n),fields:r,geometryType:l,objectIdFieldName:t,spatialReference:s,uniqueIdField:c,queryGeometry:j(h,d,!1,!1)};return i&&(m.transform=i),u&&(m.exceededTransferLimit=u),n&&(m.hasM=n),a&&(m.hasZ=a),m}function $(e,t){const s=new c.Z,{hasM:r,hasZ:n,features:a,objectIdFieldName:o,spatialReference:l,geometryType:u,exceededTransferLimit:h,transform:d,fields:f}=e;return f&&(s.fields=f),s.geometryType=u??null,s.objectIdFieldName=o??t??null,s.spatialReference=l??null,s.objectIdFieldName?(a&&z(s.features,a,u,n,r,s.objectIdFieldName),h&&(s.exceededTransferLimit=h),r&&(s.hasM=r),n&&(s.hasZ=n),d&&(s.transform=d),s):(m.error(new i.Z("optimized-features:invalid-objectIdFieldName","objectIdFieldName is missing")),s)}function J(e){const{transform:t,features:s,hasM:i,hasZ:r}=e;if(!t)return e;for(const e of s)null!=e.geometry&&ie(e.geometry,e.geometry,i,r,t),null!=e.centroid&&ie(e.centroid,e.centroid,i,r,t);return e.transform=null,e}function W(e,t){const{geometryType:s,features:i,hasM:r,hasZ:n}=t;if(!e)return t;for(let t=0;t<i.length;t++){const a=i[t],o=a.weakClone();o.geometry=new h.Z,X(o.geometry,a.geometry,r,n,s,e),a.centroid&&(o.centroid=new h.Z,X(o.centroid,a.centroid,r,n,"esriGeometryPoint",e)),i[t]=o}return t.transform=e,t}function X(e,t,s,i,r,n,a=s,o=i){if(oe(e),!t?.coords.length)return null;const l=f[r],{coords:u,lengths:c}=t,h=d(s,i),m=d(s&&a,i&&o),p=T(s,i,a,o);if(!c.length)return p(e.coords,u,0,0,S(n,u[0]),x(n,u[1])),oe(e,h,0),e;let y,g,_,I,F=0,w=0,R=w;for(const t of c){if(t<l)continue;let s=0;w=R,_=y=S(n,u[F]),I=g=x(n,u[F+1]),p(e.coords,u,w,F,_,I),s++,F+=h,w+=m;for(let i=1;i<t;i++,F+=h)_=S(n,u[F]),I=x(n,u[F+1]),_===y&&I===g||(p(e.coords,u,w,F,_-y,I-g),w+=m,s++,y=_,g=I);s>=l&&(e.lengths.push(s),R=w)}return le(e.coords,R),e.coords.length?e:null}function K(e,t,s,i,r,n,a=s,o=i){if(oe(e),!t?.coords.length)return null;const l=f[r],{coords:u,lengths:c}=t,h=d(s,i),m=d(s&&a,i&&o),p=T(s,i,a,o);if(!c.length)return p(e.coords,u,0,0,u[0],u[1]),oe(e,h,0),e;let y=0;const g=n*n;for(const t of c){if(t<l){y+=t*h;continue}const s=e.coords.length/m,i=y,r=y+(t-1)*h;p(e.coords,u,e.coords.length,i,u[i],u[i+1]),te(e.coords,u,h,g,p,i,r),p(e.coords,u,e.coords.length,r,u[r],u[r+1]);const n=e.coords.length/m-s;n>=l?e.lengths.push(n):le(e.coords,s*m),y+=t*h}return e.coords.length?e:null}function ee(e,t,s,i){const r=e[t],n=e[t+1],a=e[s],o=e[s+1],l=e[i],u=e[i+1];let c=a,h=o,d=l-c,m=u-h;if(0!==d||0!==m){const e=((r-c)*d+(n-h)*m)/(d*d+m*m);e>1?(c=l,h=u):e>0&&(c+=d*e,h+=m*e)}return d=r-c,m=n-h,d*d+m*m}function te(e,t,s,i,r,n,a){let o,l=i,u=0;for(let e=n+s;e<a;e+=s)o=ee(t,e,n,a),o>l&&(u=e,l=o);l>i&&(u-n>s&&te(e,t,s,i,r,n,u),r(e,t,e.length,u,t[u],t[u+1]),a-u>s&&te(e,t,s,i,r,u,a))}function se(e,t,s,i){if(!t?.coords?.length)return null;const r=d(s,i);let n=Number.POSITIVE_INFINITY,l=Number.POSITIVE_INFINITY,u=Number.NEGATIVE_INFINITY,c=Number.NEGATIVE_INFINITY;if(t&&t.coords){const e=t.coords;for(let t=0;t<e.length;t+=r){const s=e[t],i=e[t+1];n=Math.min(n,s),u=Math.max(u,s),l=Math.min(l,i),c=Math.max(c,i)}}return(0,a.is)(e)?(0,a.bZ)(e,n,l,u,c):(0,o.al)(n,l,u,c,e),e}function ie(e,t,s,i,r){const{coords:a,lengths:o}=t,l=d(s,i);if(!a.length)return e!==t&&oe(e),e;(0,n.O3)(r);const{originPosition:u,scale:c,translate:h}=r,m=ue;m.originPosition=u;const f=m.scale;f[0]=c[0]??1,f[1]=-(c[1]??1),f[2]=c[2]??1,f[3]=c[3]??1;const p=m.translate;if(p[0]=h[0]??0,p[1]=h[1]??0,p[2]=h[2]??0,p[3]=h[3]??0,!o.length){for(let t=0;t<l;++t)e.coords[t]=I(m,a[t],t);return e!==t&&oe(e,l,0),e}let y=0;for(let t=0;t<o.length;t++){const s=o[t];e.lengths[t]=s;for(let t=0;t<l;++t)e.coords[y+t]=I(m,a[y+t],t);let i=e.coords[y],r=e.coords[y+1];y+=l;for(let t=1;t<s;t++,y+=l){i+=a[y]*f[0],r+=a[y+1]*f[1],e.coords[y]=i,e.coords[y+1]=r;for(let t=2;t<l;++t)e.coords[y+t]=I(m,a[y+t],t)}}return e!==t&&oe(e,a.length,o.length),e}function re(e,t,s,i,r,n){if(oe(e),e.lengths.push(...t.lengths),s===r&&i===n)for(let s=0;s<t.coords.length;s++)e.coords.push(t.coords[s]);else{const a=d(s,i),o=T(s,i,r,n),l=t.coords;for(let t=0;t<l.length;t+=a)o(e.coords,l,e.coords.length,t,l[t],l[t+1])}return e}function ne(e,t,s,i){let r=0,n=e[i*t],a=e[i*(t+1)];for(let o=1;o<s;o++){const s=n+e[i*(t+o)],l=a+e[i*(t+o)+1],u=(s-n)*(l+a);n=s,a=l,r+=u}return.5*r}function ae(e,t){const{coords:s,lengths:i}=e;let r=0,n=0;for(let e=0;e<i.length;e++){const a=i[e];n+=ne(s,r,a,t),r+=a}return Math.abs(n)}function oe(e,t=0,s=0){le(e.lengths,s),le(e.coords,t)}function le(e,t=0){e.length!==t&&(e.length=t)}const ue={originPosition:"lowerLeft",scale:[1,1,1,1],translate:[0,0,0,0]}},99514:(e,t,s)=>{s.d(t,{Z:()=>l});var i=s(20102),r=s(96674),n=s(92604),a=s(35671),o=s(25031);class l{static fromJSON(e){return new l(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new l(e.fields??[],d(e))}static fromLayerJSON(e){return new l(e.fields??[],d(e))}constructor(e=[],t){this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this._requiredFields=null,this.dateFields=[],this.numericFields=[],this.fields=e||[],this._timeZoneByFieldName=t?new Map(t):null;const s=[];for(const e of this.fields){const t=e?.name,i=c(t);if(t&&i){const r=u(t);this._fieldsMap.set(t,e),this._fieldsMap.set(r,e),this._normalizedFieldsMap.set(i,e),s.push(`${r}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,a.y2)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,a.H7)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,a.Dl)(e)||(0,a.Se)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}s.sort(),this.uid=s.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,a.Dl)(e)||(0,a.Se)(e)||e.nullable||void 0!==(0,a.os)(e)||this._requiredFields.push(e)}return this._requiredFields}equals(e){return this.uid===e?.uid}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(u(e))??this._normalizedFieldsMap.get(c(e)),t&&this._fieldsMap.set(e,t),t)}getTimeZone(e){const t=this.get(e&&"string"!=typeof e?e.name:e);return t?this._timeZoneByFieldName?this._timeZoneByFieldName.get(t.name):"date"===t.type||"esriFieldTypeDate"===t.type?(n.Z.getLogger("esri.layers.support.FieldsIndex").error(new i.Z("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),o.pt):h.has(t.type)?o._4:null:null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,a.sX)(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){return this.get(e)?.name??void 0}toJSON(){return{fields:this.fields.map((e=>(0,r.AK)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function u(e){return e.trim().toLowerCase()}function c(e){return(0,a.q6)(e)?.toLowerCase()??""}const h=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function d(e){const t=new Map;if(!e.fields)return t;const s=!0===e.datesInUnknownTimezone,{timeInfo:i,editFieldsInfo:r}=e,n=(i?"startField"in i?i.startField:i.startTimeField:"")??"",a=(i?"endField"in i?i.endField:i.endTimeField:"")??"",l=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,o.Jv)(e.dateFieldsTimeReference):null,c=r?function(e){return"timeZone"in e}(r)?r.timeZone??l:r.dateFieldsTimeReference?(0,o.Jv)(r.dateFieldsTimeReference):l??o.pt:null,d=i?function(e){return"timeZone"in e}(i)?i.timeZone??l:i.timeReference?(0,o.Jv)(i.timeReference):l:null,m=new Map([[u(r?.creationDateField??""),c],[u(r?.editDateField??""),c],[u(n),d],[u(a),d]]);for(const{name:i,type:r}of e.fields)if(h.has(r))t.set(i,o._4);else if("date"!==r&&"esriFieldTypeDate"!==r)t.set(i,null);else if(s)t.set(i,o._4);else{const e=m.get(u(i??""))??l;t.set(i,e)}return t}},86719:(e,t,s)=>{s.d(t,{v:()=>i});const i=new(s(35454).X)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"})},95720:(e,t,s)=>{var i;s.d(t,{n:()=>i}),function(e){e[e.ANIMATING=0]="ANIMATING",e[e.INTERACTING=1]="INTERACTING",e[e.IDLE=2]="IDLE"}(i||(i={}))}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9238],{19238:(e,t,r)=>{r.r(t),r.d(t,{default:()=>Pe});var i=r(43697),s=r(51773),o=(r(16050),r(12501),r(28756),r(92271),r(72529),r(5499),r(84382),r(81571),r(91423)),n=r(32400),a=r(3172),l=r(9790),u=r(2368),d=r(46791),p=r(20102),c=r(22974),y=r(92604),h=r(16453),f=r(78286),b=r(95330),m=r(42033),g=r(17452),w=r(5600),_=r(90578),v=r(71715),S=r(52011),C=r(30556),F=r(82960),I=r(90100),T=r(82971),E=r(87085),j=(r(66577),r(38171)),R=r(80442),x=r(83379),O=r(609),D=r(56569),M=r(75215),q=(r(67676),r(52421)),Z=r(59431),P=r(28694),L=r(74889),N=r(6570),G=r(38913),A=r(86973);let k=0,B=class extends(x.Z.LoadableMixin((0,O.v)(d.Z))){constructor(e){super(e),this._idToClientGraphic=null,this.type="memory"}load(e){const t=null!=e?e.signal:null;return this.addResolvingPromise(this._startWorker(t)),Promise.resolve(this)}destroy(){this._connection?.close(),this._connection=null}get _workerGeometryType(){const e=this.layer?.geometryType;return e?this._geometryTypeRequiresClientGraphicMapping(e)?"polygon":e:null}applyEdits(e){return this.load().then((()=>this._applyEdits(e)))}openPorts(){return this.load().then((()=>this._connection.openPorts()))}async queryFeatures(e,t={}){await this.load(t);const r=await this._connection.invoke("queryFeatures",e?e.toJSON():null,t);(0,P.p)(e,this.layer.spatialReference,r);const i=L.Z.fromJSON(r);if(!this._requiresClientGraphicMapping())return i;const s=this.layer.objectIdField;for(const e of i.features){const t=e.attributes[s],r=this._idToClientGraphic.get(t);r&&(e.geometry=r.geometry)}return i.geometryType=this.layer.geometryType,i}async queryFeaturesJSON(e,t={}){if(this._requiresClientGraphicMapping())throw new p.Z("query-features-json:unsupported","Cannot query in JSON format for client only geometry types (mesh and extent)");await this.load(t);const r=await this._connection.invoke("queryFeatures",e?e.toJSON():null,t);return(0,P.p)(e,this.layer.spatialReference,r),r}queryFeatureCount(e,t={}){return this.load(t).then((()=>this._connection.invoke("queryFeatureCount",e?e.toJSON():null,t)))}queryObjectIds(e,t={}){return this.load(t).then((()=>this._connection.invoke("queryObjectIds",e?e.toJSON():null,t)))}queryExtent(e,t={}){return this.load(t).then((()=>this._connection.invoke("queryExtent",e?e.toJSON():null,t))).then((e=>({count:e.count,extent:N.Z.fromJSON(e.extent)})))}querySnapping(e,t={}){return this.load(t).then((()=>this._connection.invoke("querySnapping",e,t)))}async _applyEdits(e){if(!this._connection)throw new p.Z("feature-layer-source:edit-failure","Memory source not loaded");const t=this.layer.objectIdField;let r=null;const i=[],s=[];await Promise.all([this._prepareClientMapping(e.addFeatures,null),this._prepareClientMapping(e.updateFeatures,null)]);const o=e=>"objectId"in e&&null!=e.objectId?e.objectId:"attributes"in e&&null!=e.attributes[t]?e.attributes[t]:null;if(e.addFeatures&&(r=this._prepareAddFeatures(e.addFeatures)),e.deleteFeatures)for(const t of e.deleteFeatures){const e=o(t);null!=e&&i.push(e)}const n=e.updateFeatures&&this._idToClientGraphic?new Map:null;if(e.updateFeatures)for(const t of e.updateFeatures)if(s.push(this._serializeFeature(t)),n){const e=o(t);null!=e&&n.set(e,t)}(0,Z.P)(r?r.features:null,s,this.layer.spatialReference);const{fullExtent:a,featureEditResults:l}=await this._connection.invoke("applyEdits",{adds:r?r.features:[],updates:s,deletes:i});return this.fullExtent=a,r&&r.finish(l.uidToObjectId),this._updateClientGraphicIds(n,l),this._createEditsResult(l)}async _prepareClientMapping(e,t){if("mesh"!==this._layerOrSourceGeometryType||null==e)return;const r=[];for(const{geometry:i}of e)null==i||"mesh"!==i.type||i.hasExtent||i.loaded||r.push(i.load({signal:t}));r.length&&await Promise.all(r)}_updateClientGraphicIds(e,t){if(this._idToClientGraphic){if(e)for(const r of t.updateResults){if(!r.success)continue;const t=e.get(r.objectId);null!=t&&this._addIdToClientGraphic(t)}for(const e of t.deleteResults)e.success&&this._idToClientGraphic.delete(e.objectId)}}_createEditsResult(e){return{addFeatureResults:e.addResults?e.addResults.map(this._createFeatureEditResult,this):[],updateFeatureResults:e.updateResults?e.updateResults.map(this._createFeatureEditResult,this):[],deleteFeatureResults:e.deleteResults?e.deleteResults.map(this._createFeatureEditResult,this):[],addAttachmentResults:[],updateAttachmentResults:[],deleteAttachmentResults:[]}}_createFeatureEditResult(e){const t=!0===e.success?null:e.error||{code:void 0,description:void 0};return{objectId:e.objectId,globalId:e.globalId,error:t?new p.Z("feature-layer-source:edit-failure",t.description,{code:t.code}):null}}_prepareAddFeatures(e){const t=new Map,r=new Array(e.length);let i=null;for(let s=0;s<e.length;s++){const o=e[s],n=this._serializeFeature(o);i||null==o.geometry||(i=o.geometry.type),r[s]=n,t.set(`${n.uid}`,o)}const s=this;return{features:r,inferredGeometryType:i,finish(e){const r=s.sourceJSON.objectIdField;for(const i in e){const o=e[i],n=t.get(i);n&&(n.attributes||(n.attributes={}),-1===o?delete n.attributes[r]:n.attributes[r]=o,s._addIdToClientGraphic(n))}}}}_addIdToClientGraphic(e){if(!this._idToClientGraphic)return;const t=this.sourceJSON.objectIdField,r=e.attributes?.[t];null!=r&&this._idToClientGraphic.set(r,e)}get _layerOrSourceGeometryType(){return this.layer?.geometryType??this.sourceJSON?.geometryType}_requiresClientGraphicMapping(){return this._geometryTypeRequiresClientGraphicMapping(this._layerOrSourceGeometryType)}_geometryRequiresClientGraphicMapping(e){return this._geometryTypeRequiresClientGraphicMapping(e.type)}_geometryTypeRequiresClientGraphicMapping(e){return"mesh"===e||"multipatch"===e||"extent"===e}_serializeFeature(e){const{attributes:t}=e,r=this._geometryForSerialization(e),i=(k++).toString();return r?{uid:i,geometry:r.toJSON(),attributes:t}:{uid:i,attributes:t}}_geometryForSerialization(e){const{geometry:t}=e;return null==t?null:this._geometryRequiresClientGraphicMapping(t)?t.extent?G.Z.fromExtent(t.extent):null:t}async _startWorker(e){this._connection=await(0,D.bA)("MemorySourceWorker",{strategy:(0,R.Z)("feature-layers-workers")?"dedicated":"local",signal:e,registryTarget:this});const{fields:t,spatialReference:r,objectIdField:i,hasM:s,hasZ:o,timeInfo:n,dateFieldsTimeZone:a}=this.layer,l="defaults"===this.layer.originOf("spatialReference");await this._prepareClientMapping(this.items,e);const u=this._prepareAddFeatures(this.items);this.addHandles(this.on("before-changes",(e=>{y.Z.getLogger(this).error("Source modifications will not propagate after layer has been loaded. Please use .applyEdits() instead"),e.preventDefault()})));const d={features:u.features,fields:t?.map((e=>e.toJSON())),geometryType:A.P.toJSON(this._workerGeometryType),hasM:"mesh"!==this._layerOrSourceGeometryType&&s,hasZ:"mesh"===this._layerOrSourceGeometryType||o,objectIdField:i,spatialReference:l?null:r&&r.toJSON(),timeInfo:n?.toJSON()??null,dateFieldsTimeZone:a},p=await this._connection.invoke("load",d,{signal:e});for(const e of p.warnings)y.Z.getLogger(this.layer).warn("#load()",`${e.message} (title: '${this.layer.title||"no title"}', id: '${this.layer.id??"no id"}')`,{warning:e});p.featureErrors.length&&y.Z.getLogger(this.layer).warn("#load()",`Encountered ${p.featureErrors.length} validation errors while loading features. (title: '${this.layer.title||"no title"}', id: '${this.layer.id??"no id"}')`,{errors:p.featureErrors});const c=p.layerDefinition;this._geometryTypeRequiresClientGraphicMapping(u.inferredGeometryType)&&(c.geometryType=A.P.toJSON(u.inferredGeometryType)),this.sourceJSON=c,this._requiresClientGraphicMapping()&&(this._idToClientGraphic=new Map),u.finish(p.assignedObjectIds)}};(0,i._)([(0,q.c)({Type:j.Z,ensureType:(0,M.se)(j.Z)})],B.prototype,"itemType",void 0),(0,i._)([(0,w.Cb)()],B.prototype,"type",void 0),(0,i._)([(0,w.Cb)({constructOnly:!0})],B.prototype,"layer",void 0),(0,i._)([(0,w.Cb)({readOnly:!0})],B.prototype,"_workerGeometryType",null),(0,i._)([(0,w.Cb)()],B.prototype,"sourceJSON",void 0),B=(0,i._)([(0,S.j)("esri.layers.graphics.sources.MemorySource")],B);var J=r(54295),V=r(17287),U=r(71612),$=r(17017),Q=r(66361),W=r(69637),z=r(25113),H=r(6404),X=r(38009),Y=r(68825),K=r(16859),ee=r(92036);let te=class extends ee.Z{constructor(){super(...arguments),this.updating=!1,this.status="unknown"}};(0,i._)([(0,w.Cb)()],te.prototype,"updating",void 0),(0,i._)([(0,w.Cb)()],te.prototype,"status",void 0),te=(0,i._)([(0,S.j)("esri.layers.support.PublishingInfo")],te);const re=te,ie="esri.layers.mixins.PublishableLayer",se=Symbol(ie),oe=e=>{var t;let r=class extends e{constructor(){super(...arguments),this[t]=!0}get publishingInfo(){if(this.destroyed)return null;const e=this._get("publishingInfo");if(e)return e;const t=new re;return this._checkPublishingStatus(t),t}_checkPublishingStatus(e){let t=0;const r=async s=>{let o;e.updating=!0;try{o=await this.fetchPublishingStatus()}catch(e){o="unavailable"}"published"!==o&&"unavailable"!==o||("publishing"===e.status&&this.refresh(),i.remove()),e.status=o,e.updating=!1,i.removed||(t=setTimeout(r,s,s+125))},i={removed:!1,remove(){this.removed=!0,clearTimeout(t)}};this.when().catch((()=>i.remove())),r(250),this.addHandles(i)}};return t=se,(0,i._)([(0,w.Cb)({readOnly:!0,clonable:!1})],r.prototype,"publishingInfo",null),r=(0,i._)([(0,S.j)(ie)],r),r};var ne=r(34760),ae=r(72965),le=r(28294),ue=r(66677),de=r(21506),pe=r(45574),ce=r(70082),ye=r(16451),he=r(53518),fe=r(35671),be=r(54306),me=r(30707),ge=r(54275),we=r(76259),_e=r(60199),ve=r(10158),Se=r(40555),Ce=r(14165),Fe=r(28141),Ie=r(32163),Te=r(12259),Ee=r(65242);const je="FeatureLayer",Re="esri.layers.FeatureLayer",xe=y.Z.getLogger(Re);function Oe(e,t){return new p.Z("layer:unsupported",`Layer (${e.title}, ${e.id}) of type '${e.declaredClass}' ${t}`,{layer:e})}function De(e){return e&&e instanceof d.Z}const Me=(0,he.v)();function qe(e,t,r){const i=!!r?.writeLayerSchema;return{enabled:i,ignoreOrigin:i}}let Ze=class extends((0,z.B)((0,H.M)((0,W.b)(oe((0,Q.o1)((0,U.h)((0,Y.c)((0,le.n)((0,ae.M)((0,ne.Q)((0,V.Y)((0,X.q)((0,K.I)((0,h.R)((0,$.N)((0,J.V)((0,u.J)(E.Z)))))))))))))))))){constructor(...e){super(...e),this.charts=null,this.copyright=null,this.displayField=null,this.dynamicDataSource=null,this.fields=null,this.fieldsIndex=null,this.formTemplate=null,this.fullExtent=null,this.geometryType=null,this.hasM=void 0,this.hasZ=void 0,this.infoFor3D=null,this.isTable=!1,this.labelsVisible=!0,this.labelingInfo=null,this.legendEnabled=!0,this.objectIdField=null,this.outFields=null,this.path=null,this.popupEnabled=!0,this.popupTemplate=null,this.screenSizePerspectiveEnabled=!0,this.spatialReference=T.Z.WGS84,this.subtypeCode=null,this.templates=null,this.timeInfo=null,this.title=null,this.sublayerTitleMode="item-title",this.type="feature",this.typeIdField=null,this.types=null,this.visible=!0,this._debouncedSaveOperations=(0,b.Ds)((async(e,t,i)=>{const{save:s,saveAs:o}=await r.e(2664).then(r.bind(r,32664));switch(e){case Te.x.SAVE:return s(this,t);case Te.x.SAVE_AS:return o(this,i,t)}}))}destroy(){this.source?.destroy()}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}load(e){const t=null!=e?e.signal:null;if(this.portalItem?.loaded&&this.source)return this.addResolvingPromise(this.createGraphicsSource(t).then((e=>this.initLayerProperties(e)))),Promise.resolve(this);const r=this.loadFromPortal({supportedTypes:["Feature Service","Feature Collection","Scene Service"]},e).catch(b.r9).then((async()=>{if(this.url&&null==this.layerId&&/FeatureServer|MapServer\/*$/i.test(this.url)){const e=await this._fetchFirstLayerId(t);null!=e&&(this.layerId=e)}if(!this.url&&!this._hasMemorySource())throw new p.Z("feature-layer:missing-url-or-source","Feature layer must be created with either a url or a source");return this.initLayerProperties(await this.createGraphicsSource(t))})).then((()=>(0,pe.nU)(this,"load",e)));return this.addResolvingPromise(r),Promise.resolve(this)}readCapabilities(e,t){return t=t.layerDefinition||t,(0,ge.h)(t,this.url)}get createQueryVersion(){return this.commitProperty("definitionExpression"),this.commitProperty("dynamicDataSource"),this.commitProperty("timeExtent"),this.commitProperty("timeOffset"),this.commitProperty("geometryType"),this.commitProperty("gdbVersion"),this.commitProperty("historicMoment"),this.commitProperty("returnZ"),this.commitProperty("capabilities"),this.commitProperty("returnM"),(this._get("createQueryVersion")??0)+1}get editingEnabled(){return!(this.loaded&&!this.capabilities?.operations.supportsEditing)&&(this._isOverridden("editingEnabled")?this._get("editingEnabled"):this._hasMemorySource()||this.userHasEditingPrivileges)}set editingEnabled(e){this._overrideIfSome("editingEnabled",e)}readEditingEnabled(e,t){return this._readEditingEnabled(t,!1)}readEditingEnabledFromWebMap(e,t,r){return this._readEditingEnabled(t,!0,r)}writeEditingEnabled(e,t){this._writeEditingEnabled(e,t,!1)}writeEditingEnabledToWebMap(e,t,r,i){this._writeEditingEnabled(e,t,!0,i)}get effectiveEditingEnabled(){return(0,pe.sX)(this)}readIsTable(e,t){return"Table"===(t=t?.layerDefinition??t).type||!t.geometryType}writeIsTable(e,t,r,i){i?.writeLayerSchema&&(0,f.RB)(r,e?"Table":"Feature Layer",t)}readGlobalIdField(e,t){return(0,pe.rk)(t.layerDefinition||t)}readObjectIdField(e,t){return(0,pe.kZ)(t.layerDefinition||t)}get parsedUrl(){const e=(0,g.mN)(this.url);return null!=e&&(null!=this.dynamicDataSource?e.path=(0,g.v_)(e.path,"dynamicLayer"):null!=this.layerId&&(e.path=(0,g.v_)(e.path,this.layerId.toString()))),e}get defaultPopupTemplate(){return this.createPopupTemplate()}set renderer(e){(0,fe.YN)(e,this.fieldsIndex),this._set("renderer",e)}readRenderer(e,t,r){t=t.layerDefinition||t;const i=t.drawingInfo?.renderer;if(i){const e=(0,o.a)(i,t,r)??void 0;return e||xe.error("Failed to create renderer",{rendererDefinition:t.drawingInfo.renderer,layer:this,context:r}),e}return(0,pe.Ob)(t,r)}set source(e){const t=this._get("source");t!==e&&(De(t)&&this._resetMemorySource(t),De(e)&&this._initMemorySource(e),this._set("source",e))}castSource(e){return e?Array.isArray(e)||e instanceof d.Z?new B({layer:this,items:e}):e:null}readSource(e,t){const r=L.Z.fromJSON(t.featureSet);return new B({layer:this,items:r?.features??[]})}readTemplates(e,t){const r=t.editFieldsInfo,i=r?.creatorField,s=r?.editorField;return e=e?.map((e=>ce.Z.fromJSON(e))),this._fixTemplates(e,i),this._fixTemplates(e,s),e}readTitle(e,t){const r=t.layerDefinition?.name??t.name,i=t.title||t.layerDefinition?.title;if(r){const e=this.portalItem?.title;if("item-title"===this.sublayerTitleMode)return this.url?(0,ue.a7)(this.url,r):r;let t=r;if(!t&&this.url){const e=(0,ue.Qc)(this.url);null!=e&&(t=e.title)}if(!t)return;return"item-title-and-service-name"===this.sublayerTitleMode&&e&&e!==t&&(t=e+" - "+t),(0,ue.ld)(t)}if("item-title"===this.sublayerTitleMode&&i)return i}readTitleFromWebMap(e,t){return t.title||t.layerDefinition?.name}readTypeIdField(e,t){let r=(t=t.layerDefinition||t).typeIdField;if(r&&t.fields){r=r.toLowerCase();const e=t.fields.find((e=>e.name.toLowerCase()===r));e&&(r=e.name)}return r}readTypes(e,t){e=(t=t.layerDefinition||t).types;const r=t.editFieldsInfo,i=r?.creatorField,s=r?.editorField;return e?.map((e=>(e=ye.Z.fromJSON(e),this._fixTemplates(e.templates,i),this._fixTemplates(e.templates,s),e)))}readVisible(e,t){return null!=t.layerDefinition?.defaultVisibility?!!t.layerDefinition.defaultVisibility:null!=t.visibility?!!t.visibility:void 0}async addAttachment(e,t){return(0,pe.JD)(this,e,t,je)}async updateAttachment(e,t,r){return(0,pe.Y5)(this,e,t,r,je)}async applyEdits(e,t){return(0,pe.Jj)(this,e,t)}async uploadAssets(e,t){return(0,pe.uj)(this,e,t)}on(e,t){return super.on(e,t)}createPopupTemplate(e){return(0,Ie.eZ)(this,e)}async createGraphicsSource(e){if(this._hasMemorySource()&&this.source)return this.source.load({signal:e});const{default:t}=await(0,b.Hl)(Promise.all([r.e(4599),r.e(9735),r.e(9379)]).then(r.bind(r,49379)),e);return new t({layer:this}).load({signal:e})}createQuery(){const e=(0,pe.rP)(this);e.dynamicDataSource=this.dynamicDataSource;const t=null!=this.subtypeCode?`${this.subtypeField} = ${this.subtypeCode}`:null,r=(0,m._)(this.definitionExpression,t);return e.where=r||"1=1",e}async deleteAttachments(e,t){return(0,pe.FV)(this,e,t,je)}async fetchRecomputedExtents(e){return(0,pe.Ci)(this,e,je)}getFeatureType(e){const{typeIdField:t,types:r}=this;if(!t||!e)return null;const i=e.attributes?e.attributes[t]:void 0;if(null==i)return null;let s=null;return r?.some((e=>{const{id:t}=e;return null!=t&&(t.toString()===i.toString()&&(s=e),!!s)})),s}getFieldDomain(e,t){const r=t?.feature,i=this.getFeatureType(r);if(i){const t=i.domains&&i.domains[e];if(t&&"inherited"!==t.type)return t}return this._getLayerDomain(e)}getField(e){return this.fieldsIndex.get(e)}async queryAttachments(e,t){return(0,pe.SU)(this,e,t,je)}async queryFeatures(e,t){const r=await this.load(),i=await r.source.queryFeatures(Ce.Z.from(e)??r.createQuery(),t);if(i?.features)for(const e of i.features)e.layer=e.sourceLayer=r;return i}async queryObjectIds(e,t){return(0,pe.tD)(this,e,t,je)}async queryFeatureCount(e,t){return(0,pe.VG)(this,e,t,je)}async queryExtent(e,t){return(0,pe.KE)(this,e,t,je)}async queryRelatedFeatures(e,t){return(0,pe.kp)(this,e,t,je)}async queryRelatedFeaturesCount(e,t){return(0,pe.C9)(this,e,t,je)}async queryTopFeatures(e,t){const{source:r,capabilities:i}=await this.load();if(!r.queryTopFeatures||!i?.query?.supportsTopFeaturesQuery)throw new p.Z(je,"Layer source does not support queryTopFeatures capability");const s=await r.queryTopFeatures(Fe.Z.from(e),t);if(s?.features)for(const e of s.features)e.layer=e.sourceLayer=this;return s}async queryTopObjectIds(e,t){const{source:r,capabilities:i}=await this.load();if(!r.queryTopObjectIds||!i?.query.supportsTopFeaturesQuery)throw new p.Z(je,"Layer source does not support queryTopObjectIds capability");return r.queryTopObjectIds(Fe.Z.from(e),t)}async queryTopFeaturesExtent(e,t){const{source:r,capabilities:i}=await this.load();if(!r.queryTopExtents||!i?.query?.supportsTopFeaturesQuery)throw new p.Z(je,"Layer source does not support queryTopExtents capability");return r.queryTopExtents(Fe.Z.from(e),t)}async queryTopFeatureCount(e,t){const{source:r,capabilities:i}=await this.load();if(!r.queryTopCount||!i?.query?.supportsTopFeaturesQuery)throw new p.Z(je,"Layer source does not support queryFeatureCount capability");return r.queryTopCount(Fe.Z.from(e),t)}read(e,t){const r=e.featureCollection;if(r){const e=r.layers;e&&1===e.length&&(super.read(e[0],t),null!=r.showLegend&&super.read({showLegend:r.showLegend},t))}super.read(e,t),t&&"service"===t.origin&&(this.revert(["objectIdField","fields","timeInfo","dateFieldsTimeZone"],"service"),this.spatialReference||this.revert(["spatialReference"],"service"))}write(e,t){t={...t,origin:t?.origin??void 0,writeLayerSchema:t?.writeLayerSchema??this._hasMemorySource()};const{origin:r,layerContainerType:i,messages:s}=t;if(this.dynamicDataSource)return s?.push(Oe(this,"using a dynamic data source cannot be written to web scenes, web maps and feature service items")),null;if(this.isTable){if(("web-map"===r||"web-scene"===r)&&"tables"!==i)return s?.push(Oe(this,`a table source can only be written to tables, not ${i}`)),null;if(this._hasMemorySource())return s?.push(Oe(this,"using an in-memory table source cannot be written to web scenes and web maps")),null}else if(this.loaded&&("web-map"===r||"web-scene"===r)&&"tables"===i)return s?.push(Oe(this,"using a non-table source cannot be written to tables in web maps or web scenes")),null;return super.write(e,t)}clone(){if(this._hasMemorySource())throw new p.Z(je,`FeatureLayer (title: ${this.title}, id: ${this.id}) created using in-memory source cannot be cloned`);return super.clone()}serviceSupportsSpatialReference(e){return!!this.loaded&&("memory"===this.source?.type||(0,_e.D)(this,e))}async save(e){return this._debouncedSaveOperations(Te.x.SAVE,e)}async saveAs(e,t){return this._debouncedSaveOperations(Te.x.SAVE_AS,t,e)}_readEditingEnabled(e,t,r){let i=e.layerDefinition?.capabilities;return i?this._hasEditingCapability(i):(i=e.capabilities,t&&"web-map"===r?.origin&&!this._hasMemorySource()&&i?this._hasEditingCapability(i):void 0)}_hasEditingCapability(e){return e.toLowerCase().split(",").map((e=>e.trim())).includes("editing")}_writeEditingEnabled(e,t,r,i){if(!e){const e=this.capabilities?.operations?.supportsSync?"Query,Sync":"Query";(0,f.RB)("layerDefinition.capabilities",e,t),r&&!i?.writeLayerSchema&&(t.capabilities=e)}}_getLayerDomain(e){const t=this.fieldsIndex.get(e);return t?t.domain:null}_fetchFirstLayerId(e){return(0,a.Z)(this.url,{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:e}).then((e=>{const t=e.data;if(t)return Array.isArray(t.layers)&&t.layers.length>0?t.layers[0].id:Array.isArray(t.tables)&&t.tables.length>0?t.tables[0].id:void 0}))}async initLayerProperties(e){return this._set("source",e),e.sourceJSON&&(this.sourceJSON=e.sourceJSON,this.read(e.sourceJSON,{origin:"service",portalItem:this.portalItem,portal:this.portalItem?.portal,url:this.parsedUrl})),this._verifySource(),this._verifyFields(),(0,fe.YN)(this.renderer,this.fieldsIndex),(0,fe.UF)(this.timeInfo,this.fieldsIndex),(0,Se.y)(this,{origin:"service"})}async hasDataChanged(){return(0,pe.gG)(this)}async fetchPublishingStatus(){const e=this.source;return e?.fetchPublishingStatus?e.fetchPublishingStatus():"unavailable"}_verifyFields(){const e=this.parsedUrl?.path??"undefined";this.objectIdField||console.log("FeatureLayer: 'objectIdField' property is not defined (url: "+e+")"),this.isTable||this._hasMemorySource()||-1!==e.search(/\/FeatureServer\//i)||this.fields?.some((e=>"geometry"===e.type))||console.log("FeatureLayer: unable to find field of type 'geometry' in the layer 'fields' list. If you are using a map service layer, features will not have geometry (url: "+e+")")}_fixTemplates(e,t){e&&e.forEach((e=>{const r=e.prototype?.attributes;r&&t&&delete r[t]}))}_verifySource(){if(this._hasMemorySource()){if(this.url)throw new p.Z("feature-layer:mixed-source-and-url","FeatureLayer cannot be created with both an in-memory source and a url")}else if(!this.url)throw new p.Z("feature-layer:source-or-url-required","FeatureLayer requires either a url, a valid portal item or a source")}_initMemorySource(e){e.forEach((e=>{e.layer=this,e.sourceLayer=this})),this.addHandles([e.on("after-add",(e=>{e.item.layer=this,e.item.sourceLayer=this})),e.on("after-remove",(e=>{e.item.layer=null,e.item.sourceLayer=null}))],"fl-source")}_resetMemorySource(e){e.forEach((e=>{e.layer=null,e.sourceLayer=null})),this.removeHandles("fl-source")}_hasMemorySource(){return!(this.url||!this.source)}};(0,i._)([(0,v.r)("service","capabilities")],Ze.prototype,"readCapabilities",null),(0,i._)([(0,w.Cb)({json:{origins:{"web-scene":{write:!1}},write:!0}})],Ze.prototype,"charts",void 0),(0,i._)([(0,w.Cb)({readOnly:!0})],Ze.prototype,"createQueryVersion",null),(0,i._)([(0,w.Cb)({json:{read:{source:"layerDefinition.copyrightText"}}})],Ze.prototype,"copyright",void 0),(0,i._)([(0,w.Cb)({json:{read:{source:"layerDefinition.displayField"}}})],Ze.prototype,"displayField",void 0),(0,i._)([(0,w.Cb)({types:l.LB,readOnly:!0})],Ze.prototype,"defaultSymbol",void 0),(0,i._)([(0,w.Cb)({type:ve.n})],Ze.prototype,"dynamicDataSource",void 0),(0,i._)([(0,w.Cb)({type:Boolean})],Ze.prototype,"editingEnabled",null),(0,i._)([(0,v.r)(["portal-item","web-scene"],"editingEnabled",["layerDefinition.capabilities"])],Ze.prototype,"readEditingEnabled",null),(0,i._)([(0,v.r)("web-map","editingEnabled",["capabilities","layerDefinition.capabilities"])],Ze.prototype,"readEditingEnabledFromWebMap",null),(0,i._)([(0,C.c)(["portal-item","web-scene"],"editingEnabled",{"layerDefinition.capabilities":{type:String}})],Ze.prototype,"writeEditingEnabled",null),(0,i._)([(0,C.c)("web-map","editingEnabled",{capabilities:{type:String},"layerDefinition.capabilities":{type:String}})],Ze.prototype,"writeEditingEnabledToWebMap",null),(0,i._)([(0,w.Cb)({readOnly:!0})],Ze.prototype,"effectiveEditingEnabled",null),(0,i._)([(0,w.Cb)({...Me.fields,json:{read:{source:"layerDefinition.fields"},origins:{service:{name:"fields"},"web-map":{write:{target:"layerDefinition.fields",overridePolicy:qe}}}}})],Ze.prototype,"fields",void 0),(0,i._)([(0,w.Cb)(Me.fieldsIndex)],Ze.prototype,"fieldsIndex",void 0),(0,i._)([(0,w.Cb)({type:I.Z,json:{name:"formInfo",write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],Ze.prototype,"formTemplate",void 0),(0,i._)([(0,w.Cb)({json:{read:{source:"layerDefinition.extent"}}})],Ze.prototype,"fullExtent",void 0),(0,i._)([(0,w.Cb)({json:{origins:{"web-map":{write:{target:"layerDefinition.geometryType",overridePolicy:qe,writer(e,t,r){const i=e?pe.Fr.toJSON(e):null;i&&(0,f.RB)(r,i,t)}}}},read:{source:"layerDefinition.geometryType",reader:pe.Fr.read}}})],Ze.prototype,"geometryType",void 0),(0,i._)([(0,w.Cb)({json:{read:{source:"layerDefinition.hasM"}}})],Ze.prototype,"hasM",void 0),(0,i._)([(0,w.Cb)({json:{read:{source:"layerDefinition.hasZ"}}})],Ze.prototype,"hasZ",void 0),(0,i._)([(0,w.Cb)(de.id)],Ze.prototype,"id",void 0),(0,i._)([(0,w.Cb)({readOnly:!0,json:{origins:{service:{read:!0}},read:!1}})],Ze.prototype,"infoFor3D",void 0),(0,i._)([(0,w.Cb)({json:{origins:{"web-map":{write:{target:"layerDefinition.type"}}}}})],Ze.prototype,"isTable",void 0),(0,i._)([(0,v.r)("service","isTable",["type","geometryType"]),(0,v.r)("isTable",["layerDefinition.type","layerDefinition.geometryType"])],Ze.prototype,"readIsTable",null),(0,i._)([(0,C.c)("web-map","isTable")],Ze.prototype,"writeIsTable",null),(0,i._)([(0,w.Cb)(de.iR)],Ze.prototype,"labelsVisible",void 0),(0,i._)([(0,w.Cb)({type:[be.Z],json:{origins:{service:{name:"drawingInfo.labelingInfo",read:me.r,write:!1},"web-scene":{name:"layerDefinition.drawingInfo.labelingInfo",read:me.r,write:{enabled:!0,layerContainerTypes:F.C}}},name:"layerDefinition.drawingInfo.labelingInfo",read:me.r,write:!0}})],Ze.prototype,"labelingInfo",void 0),(0,i._)([(0,w.Cb)((()=>{const e=(0,c.d9)(de.bT);return e.json.origins["portal-item"]={write:{target:"layerDefinition.drawingInfo.transparency",writer(e,t,r){(0,f.RB)(r,(0,Ee.a)(e),t)}}},e})())],Ze.prototype,"opacity",void 0),(0,i._)([(0,w.Cb)(de.rn)],Ze.prototype,"legendEnabled",void 0),(0,i._)([(0,w.Cb)({type:["show","hide"],json:(()=>{const e=(0,c.d9)(de.rT.json);return e.origins["portal-item"]={read:!1,write:!1},e})()})],Ze.prototype,"listMode",void 0),(0,i._)([(0,v.r)("globalIdField",["layerDefinition.globalIdField","layerDefinition.fields"])],Ze.prototype,"readGlobalIdField",null),(0,i._)([(0,w.Cb)({json:{origins:{"web-map":{write:{target:"layerDefinition.objectIdField",overridePolicy:qe}}}}})],Ze.prototype,"objectIdField",void 0),(0,i._)([(0,v.r)("objectIdField",["layerDefinition.objectIdField","layerDefinition.fields"])],Ze.prototype,"readObjectIdField",null),(0,i._)([(0,w.Cb)({value:"ArcGISFeatureLayer",type:["ArcGISFeatureLayer"]})],Ze.prototype,"operationalLayerType",void 0),(0,i._)([(0,w.Cb)(Me.outFields)],Ze.prototype,"outFields",void 0),(0,i._)([(0,w.Cb)({readOnly:!0})],Ze.prototype,"parsedUrl",null),(0,i._)([(0,w.Cb)({type:String,json:{origins:{"web-scene":{read:!0,write:!0}},read:!1}})],Ze.prototype,"path",void 0),(0,i._)([(0,w.Cb)(de.C_)],Ze.prototype,"popupEnabled",void 0),(0,i._)([(0,w.Cb)({type:s.Z,json:{name:"popupInfo",write:!0}})],Ze.prototype,"popupTemplate",void 0),(0,i._)([(0,w.Cb)({readOnly:!0})],Ze.prototype,"defaultPopupTemplate",null),(0,i._)([(0,w.Cb)({types:n.A,json:{origins:{service:{write:{target:"drawingInfo.renderer",enabled:!1}},"web-scene":{types:n.o,name:"layerDefinition.drawingInfo.renderer",write:{layerContainerTypes:F.C,overridePolicy:(e,t,r)=>({ignoreOrigin:r?.writeLayerSchema})}}},write:{target:"layerDefinition.drawingInfo.renderer",overridePolicy:(e,t,r)=>({ignoreOrigin:r?.writeLayerSchema})}}})],Ze.prototype,"renderer",null),(0,i._)([(0,v.r)("service","renderer",["drawingInfo.renderer","defaultSymbol"]),(0,v.r)("renderer",["layerDefinition.drawingInfo.renderer","layerDefinition.defaultSymbol"])],Ze.prototype,"readRenderer",null),(0,i._)([(0,w.Cb)((()=>{const e=(0,c.d9)(de.YI);return e.json.origins["portal-item"]={read:!1,write:!1},e})())],Ze.prototype,"screenSizePerspectiveEnabled",void 0),(0,i._)([(0,w.Cb)({clonable:!1})],Ze.prototype,"source",null),(0,i._)([(0,_.p)("source")],Ze.prototype,"castSource",null),(0,i._)([(0,v.r)("portal-item","source",["featureSet"]),(0,v.r)("web-map","source",["featureSet"])],Ze.prototype,"readSource",null),(0,i._)([(0,w.Cb)({json:{read:{source:"layerDefinition.extent.spatialReference"}}})],Ze.prototype,"spatialReference",void 0),(0,i._)([(0,w.Cb)({type:Number})],Ze.prototype,"subtypeCode",void 0),(0,i._)([(0,w.Cb)({type:[ce.Z]})],Ze.prototype,"templates",void 0),(0,i._)([(0,v.r)("templates",["editFieldsInfo","creatorField","editorField","templates"])],Ze.prototype,"readTemplates",null),(0,i._)([(0,w.Cb)({type:we.Z})],Ze.prototype,"timeInfo",void 0),(0,i._)([(0,w.Cb)()],Ze.prototype,"title",void 0),(0,i._)([(0,v.r)("service","title",["name"]),(0,v.r)("portal-item","title",["layerDefinition.title","layerDefinition.name","title"])],Ze.prototype,"readTitle",null),(0,i._)([(0,v.r)("web-map","title",["layerDefinition.name","title"])],Ze.prototype,"readTitleFromWebMap",null),(0,i._)([(0,w.Cb)({type:String})],Ze.prototype,"sublayerTitleMode",void 0),(0,i._)([(0,w.Cb)({json:{read:!1}})],Ze.prototype,"type",void 0),(0,i._)([(0,w.Cb)({type:String})],Ze.prototype,"typeIdField",void 0),(0,i._)([(0,v.r)("service","typeIdField"),(0,v.r)("typeIdField",["layerDefinition.typeIdField"])],Ze.prototype,"readTypeIdField",null),(0,i._)([(0,w.Cb)({type:[ye.Z]})],Ze.prototype,"types",void 0),(0,i._)([(0,v.r)("service","types",["types"]),(0,v.r)("types",["layerDefinition.types"])],Ze.prototype,"readTypes",null),(0,i._)([(0,w.Cb)({type:Boolean,json:{origins:{"portal-item":{write:{target:"layerDefinition.defaultVisibility"}}}}})],Ze.prototype,"visible",void 0),(0,i._)([(0,v.r)("portal-item","visible",["visibility","layerDefinition.defaultVisibility"])],Ze.prototype,"readVisible",null),Ze=(0,i._)([(0,S.j)(Re)],Ze);const Pe=Ze},69637:(e,t,r)=>{r.d(t,{b:()=>E});var i,s=r(43697),o=r(5600),n=(r(75215),r(67676),r(80442),r(52011)),a=r(20102),l=r(96674),u=r(78286),d=r(72746),p=r(66577),c=r(92835),y=r(35454),h=r(22974),f=r(14165);const b=new y.X({esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"envelope-intersects",esriSpatialRelIndexIntersects:"index-intersects",esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:"relation"}),m=new y.X({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"});let g=i=class extends l.wq{constructor(e){super(e),this.where=null,this.geometry=null,this.spatialRelationship="intersects",this.distance=void 0,this.objectIds=null,this.units=null,this.timeExtent=null}createQuery(e={}){const{where:t,geometry:r,spatialRelationship:i,timeExtent:s,objectIds:o,units:n,distance:a}=this;return new f.Z({geometry:(0,h.d9)(r),objectIds:(0,h.d9)(o),spatialRelationship:i,timeExtent:(0,h.d9)(s),where:t,units:n,distance:a,...e})}clone(){const{where:e,geometry:t,spatialRelationship:r,timeExtent:s,objectIds:o,units:n,distance:a}=this;return new i({geometry:(0,h.d9)(t),objectIds:(0,h.d9)(o),spatialRelationship:r,timeExtent:(0,h.d9)(s),where:e,units:n,distance:a})}};(0,s._)([(0,o.Cb)({type:String,json:{write:!0}})],g.prototype,"where",void 0),(0,s._)([(0,o.Cb)({types:p.qM,json:{write:!0}})],g.prototype,"geometry",void 0),(0,s._)([(0,o.Cb)({type:b.apiValues,json:{name:"spatialRel",read:{reader:b.read},write:{allowNull:!1,writer:b.write,overridePolicy(){return{enabled:null!=this.geometry}}}}})],g.prototype,"spatialRelationship",void 0),(0,s._)([(0,o.Cb)({type:Number,json:{write:{overridePolicy(e){return{enabled:null!=e&&null!=this.geometry}}}}})],g.prototype,"distance",void 0),(0,s._)([(0,o.Cb)({type:[Number],json:{write:!0}})],g.prototype,"objectIds",void 0),(0,s._)([(0,o.Cb)({type:m.apiValues,json:{read:m.read,write:{writer:m.write,overridePolicy(e){return{enabled:null!=e&&null!=this.geometry}}}}})],g.prototype,"units",void 0),(0,s._)([(0,o.Cb)({type:c.Z,json:{write:!0}})],g.prototype,"timeExtent",void 0),g=i=(0,s._)([(0,n.j)("esri.layers.support.FeatureFilter")],g);const w=g;var _;const v={read:{reader:d.ij},write:{writer:d.cW,overridePolicy(){return{allowNull:null!=this.excludedEffect,isRequired:null==this.excludedEffect}}}},S={read:{reader:d.ij},write:{writer:d.cW,overridePolicy(){return{allowNull:null!=this.includedEffect,isRequired:null==this.includedEffect}}}},C={name:"showExcludedLabels",default:!0};let F=_=class extends l.wq{constructor(e){super(e),this.filter=null,this.includedEffect=null,this.excludedEffect=null,this.excludedLabelsVisible=!1}write(e,t){const r=super.write(e,t);if(t?.origin){if(r.filter){const e=Object.keys(r.filter);if(e.length>1||"where"!==e[0])return t.messages?.push(new a.Z("web-document-write:unsupported-feature-effect","Invalid feature effect 'filter'. A filter can only contain a 'where' property",{layer:t.layer,effect:this})),null}if("showExcludedLabels"in r)return t.messages?.push(new a.Z("web-document-write:unsupported-feature-effect","Invalid value for property 'excludedLabelsVisible' which should always be 'true'",{layer:t.layer,effect:this})),null}return r}clone(){return new _({filter:null!=this.filter?this.filter.clone():null,includedEffect:this.includedEffect,excludedEffect:this.excludedEffect,excludedLabelsVisible:this.excludedLabelsVisible})}};(0,s._)([(0,o.Cb)({type:w,json:{write:{allowNull:!0,writer(e,t,r,i){const s=e?.write({},i);s&&0!==Object.keys(s).length?(0,u.RB)(r,s,t):(0,u.RB)(r,null,t)}}}})],F.prototype,"filter",void 0),(0,s._)([(0,o.Cb)({json:{write:!0,origins:{"web-map":v,"portal-item":v}}})],F.prototype,"includedEffect",void 0),(0,s._)([(0,o.Cb)({json:{write:!0,origins:{"web-map":S,"portal-item":S}}})],F.prototype,"excludedEffect",void 0),(0,s._)([(0,o.Cb)({type:Boolean,json:{write:!0,name:"showExcludedLabels",origins:{"web-map":C,"portal-item":C}}})],F.prototype,"excludedLabelsVisible",void 0),F=_=(0,s._)([(0,n.j)("esri.layers.support.FeatureEffect")],F);const I=F,T={write:{allowNull:!0}},E=e=>{let t=class extends e{constructor(){super(...arguments),this.featureEffect=null}};return(0,s._)([(0,o.Cb)({type:I,json:{origins:{"web-map":T,"portal-item":T}}})],t.prototype,"featureEffect",void 0),t=(0,s._)([(0,n.j)("esri.layers.mixins.FeatureEffectLayer")],t),t}},68825:(e,t,r)=>{r.d(t,{c:()=>f});var i,s=r(43697),o=r(78286),n=r(5600),a=(r(75215),r(67676),r(80442),r(52011)),l=r(35454),u=r(96674);const d=new l.X({asc:"ascending",desc:"descending"});let p=i=class extends u.wq{constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new i({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,s._)([(0,n.Cb)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,s._)([(0,n.Cb)({type:String,json:{write:!0}})],p.prototype,"valueExpression",void 0),(0,s._)([(0,n.Cb)({type:d.apiValues,json:{read:d.read,write:d.write}})],p.prototype,"order",void 0),p=i=(0,s._)([(0,a.j)("esri.layers.support.OrderByInfo")],p);const c=p;function y(e,t,r){if(!e)return null;const i=e.find((e=>!!e.field));if(!i)return null;const s=new c;return s.read(i,r),[s]}function h(e,t,r,i){const s=e.find((e=>!!e.field));s&&(0,o.RB)(r,[s.toJSON()],t)}const f=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,s._)([(0,n.Cb)({type:[c],json:{origins:{"web-scene":{write:!1,read:!1}},read:{source:"layerDefinition.orderBy",reader:y},write:{target:"layerDefinition.orderBy",writer:h}}})],t.prototype,"orderBy",void 0),t=(0,s._)([(0,a.j)("esri.layers.mixins.OrderedLayer")],t),t}},40555:(e,t,r)=>{r.d(t,{y:()=>n});var i=r(66643),s=r(95330),o=r(20941);async function n(e,t,r){const n=e&&e.getAtOrigin&&e.getAtOrigin("renderer",t.origin);if(n&&"unique-value"===n.type&&n.styleOrigin){const a=await(0,i.q6)(n.populateFromStyle());if((0,s.k_)(r),!1===a.ok){const r=a.error;t?.messages&&t.messages.push(new o.Z("renderer:style-reference",`Failed to create unique value renderer from style reference: ${r.message}`,{error:r,context:t})),e.clear("renderer",t?.origin)}}}},59431:(e,t,r)=>{r.d(t,{P:()=>n});var i=r(67900),s=r(8744);function o(e,t,r){if(null==e.hasM||e.hasZ)for(const e of t)for(const t of e)t.length>2&&(t[2]*=r)}function n(e,t,r){if(!e&&!t||!r)return;const s=(0,i._R)(r);a(e,r,s),a(t,r,s)}function a(e,t,r){if(e)for(const i of e)l(i.geometry,t,r)}function l(e,t,r){if(!e?.spatialReference||(0,s.fS)(e.spatialReference,t))return;const n=(0,i._R)(e.spatialReference)/r;if(1!==n)if("x"in e)null!=e.z&&(e.z*=n);else if("rings"in e)o(e,e.rings,n);else if("paths"in e)o(e,e.paths,n);else if("points"in e&&(null==e.hasM||e.hasZ))for(const t of e.points)t.length>2&&(t[2]*=n)}},28141:(e,t,r)=>{r.d(t,{Z:()=>S});var i,s=r(43697),o=r(66577),n=r(92835),a=r(35454),l=r(96674),u=r(22974),d=r(5600),p=r(75215),c=r(52011),y=r(30556),h=r(33955);r(67676),r(80442);let f=i=class extends l.wq{constructor(e){super(e),this.groupByFields=void 0,this.topCount=void 0,this.orderByFields=void 0}clone(){return new i({groupByFields:this.groupByFields,topCount:this.topCount,orderByFields:this.orderByFields})}};(0,s._)([(0,d.Cb)({type:[String],json:{write:!0}})],f.prototype,"groupByFields",void 0),(0,s._)([(0,d.Cb)({type:Number,json:{write:!0}})],f.prototype,"topCount",void 0),(0,s._)([(0,d.Cb)({type:[String],json:{write:!0}})],f.prototype,"orderByFields",void 0),f=i=(0,s._)([(0,c.j)("esri.rest.support.TopFilter")],f);const b=f;var m,g=r(82971);const w=new a.X({esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"envelope-intersects",esriSpatialRelIndexIntersects:"index-intersects",esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:"relation"}),_=new a.X({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"});let v=m=class extends l.wq{constructor(e){super(e),this.cacheHint=void 0,this.distance=void 0,this.geometry=null,this.geometryPrecision=void 0,this.maxAllowableOffset=void 0,this.num=void 0,this.objectIds=null,this.orderByFields=null,this.outFields=null,this.outSpatialReference=null,this.resultType=null,this.returnGeometry=!1,this.returnM=void 0,this.returnZ=void 0,this.start=void 0,this.spatialRelationship="intersects",this.timeExtent=null,this.topFilter=void 0,this.units=null,this.where="1=1"}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10}clone(){return new m((0,u.d9)({cacheHint:this.cacheHint,distance:this.distance,geometry:this.geometry,geometryPrecision:this.geometryPrecision,maxAllowableOffset:this.maxAllowableOffset,num:this.num,objectIds:this.objectIds,orderByFields:this.orderByFields,outFields:this.outFields,outSpatialReference:this.outSpatialReference,resultType:this.resultType,returnGeometry:this.returnGeometry,returnZ:this.returnZ,returnM:this.returnM,start:this.start,spatialRelationship:this.spatialRelationship,timeExtent:this.timeExtent,topFilter:this.topFilter,units:this.units,where:this.where}))}};(0,s._)([(0,d.Cb)({type:Boolean,json:{write:!0}})],v.prototype,"cacheHint",void 0),(0,s._)([(0,d.Cb)({type:Number,json:{write:{overridePolicy:e=>({enabled:e>0})}}})],v.prototype,"distance",void 0),(0,s._)([(0,d.Cb)({types:o.qM,json:{read:h.im,write:!0}})],v.prototype,"geometry",void 0),(0,s._)([(0,d.Cb)({type:Number,json:{write:!0}})],v.prototype,"geometryPrecision",void 0),(0,s._)([(0,d.Cb)({type:Number,json:{write:!0}})],v.prototype,"maxAllowableOffset",void 0),(0,s._)([(0,d.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],v.prototype,"num",void 0),(0,s._)([(0,d.Cb)({json:{write:!0}})],v.prototype,"objectIds",void 0),(0,s._)([(0,d.Cb)({type:[String],json:{write:!0}})],v.prototype,"orderByFields",void 0),(0,s._)([(0,d.Cb)({type:[String],json:{write:!0}})],v.prototype,"outFields",void 0),(0,s._)([(0,d.Cb)({type:g.Z,json:{read:{source:"outSR"},write:{target:"outSR"}}})],v.prototype,"outSpatialReference",void 0),(0,s._)([(0,d.Cb)({type:String,json:{write:!0}})],v.prototype,"resultType",void 0),(0,s._)([(0,d.Cb)({json:{write:!0}})],v.prototype,"returnGeometry",void 0),(0,s._)([(0,d.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"returnM",void 0),(0,s._)([(0,d.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"returnZ",void 0),(0,s._)([(0,d.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],v.prototype,"start",void 0),(0,s._)([(0,y.c)("start"),(0,y.c)("num")],v.prototype,"writeStart",null),(0,s._)([(0,d.Cb)({type:String,json:{read:{source:"spatialRel",reader:w.read},write:{target:"spatialRel",writer:w.write}}})],v.prototype,"spatialRelationship",void 0),(0,s._)([(0,d.Cb)({type:n.Z,json:{write:!0}})],v.prototype,"timeExtent",void 0),(0,s._)([(0,d.Cb)({type:b,json:{write:!0}})],v.prototype,"topFilter",void 0),(0,s._)([(0,d.Cb)({type:String,json:{read:_.read,write:{writer:_.write,overridePolicy(e){return{enabled:null!=e&&null!=this.distance&&this.distance>0}}}}})],v.prototype,"units",void 0),(0,s._)([(0,d.Cb)({type:String,json:{write:!0}})],v.prototype,"where",void 0),v=m=(0,s._)([(0,c.j)("esri.rest.support.TopFeaturesQuery")],v),v.from=(0,p.se)(v);const S=v}}]);