@arcgis/core 6.0.0-next.32 → 6.0.0-next.34

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 (142) hide show
  1. package/README.md +2 -2
  2. package/applications/Urban/meshUtils.d.ts +1 -0
  3. package/applications/Urban/meshUtils.js +1 -1
  4. package/assets/esri/core/workers/RemoteClient.js +1 -1
  5. package/assets/esri/core/workers/chunks/{f3dc0bc0e00635855a7a.js → 03daf6f235c6edef6268.js} +1 -1
  6. package/assets/esri/core/workers/chunks/04a1d08c3b5b1dc7628f.js +1 -0
  7. package/assets/esri/core/workers/chunks/{1eaf8bfdd3765a90ccc2.js → 0523f893870a1546d7d9.js} +1 -1
  8. package/assets/esri/core/workers/chunks/{72d20d3957d612f86431.js → 0a508e25ec05363e1f04.js} +1 -1
  9. package/assets/esri/core/workers/chunks/{84038dd85005fea413eb.js → 139e753d95cfc9470e74.js} +1 -1
  10. package/assets/esri/core/workers/chunks/15950c2fb173b62ee0ec.js +1 -0
  11. package/assets/esri/core/workers/chunks/{418addce122dbb8897b4.js → 1a614bac5db42c6263f8.js} +1 -1
  12. package/assets/esri/core/workers/chunks/{58c3ae6030def2ed5f31.js → 1b17f5f720f6cf3f6d73.js} +1 -1
  13. package/assets/esri/core/workers/chunks/{f9dc38761b314d33890f.js → 1f51567f47c2e2fc8a23.js} +1 -1
  14. package/assets/esri/core/workers/chunks/2211ff0a1f1ae8100231.js +1 -0
  15. package/assets/esri/core/workers/chunks/24ada9511b074dc5ae27.js +1 -0
  16. package/assets/esri/core/workers/chunks/29c610ce1c81ebb84a6b.js +1 -0
  17. package/assets/esri/core/workers/chunks/2b4dd42920d37b1ff0a9.js +2 -0
  18. package/assets/esri/core/workers/chunks/2c8ca43563c4f3e94535.js +1 -0
  19. package/assets/esri/core/workers/chunks/{55a9eaeb152a3abada67.js → 311e4969f19df63451dd.js} +1 -1
  20. package/assets/esri/core/workers/chunks/{8da2a10318f49d0dc73a.js → 31ef7b7074b3e3829763.js} +1 -1
  21. package/assets/esri/core/workers/chunks/{360c944c610efa2051fc.js → 379db67f78161ebd5468.js} +2 -2
  22. package/assets/esri/core/workers/chunks/{b8fd7c3b36981261378b.js → 38df7b1d58c4bcf693d0.js} +1 -1
  23. package/assets/esri/core/workers/chunks/{be55771758e4bcef0976.js → 3e406043a374ee17475b.js} +1 -1
  24. package/assets/esri/core/workers/chunks/46c290108a90518ef695.js +1 -0
  25. package/assets/esri/core/workers/chunks/{a596779eaeec7310671d.js → 478a89317a12e9b4d146.js} +1 -1
  26. package/assets/esri/core/workers/chunks/{fcc3902d6d9eda6f09f5.js → 48b8b57f559a53c6c513.js} +1 -1
  27. package/assets/esri/core/workers/chunks/4f3e0d583cfa9d1d6727.js +2 -0
  28. package/assets/esri/core/workers/chunks/507ecc3692e6d0700958.js +1 -0
  29. package/assets/esri/core/workers/chunks/{bd46a04a9ee4ea9e6ef1.js → 5864bce1498a13ee5b7e.js} +2 -2
  30. package/assets/esri/core/workers/chunks/{f4d91d470ca5fea0bd26.js → 5bd1414220e42cb8ebcf.js} +1 -1
  31. package/assets/esri/core/workers/chunks/5c3aa8386705c5e40358.js +1 -0
  32. package/assets/esri/core/workers/chunks/{176d75e76318bfc25a53.js → 60c8eedd06080edab3e3.js} +1 -1
  33. package/assets/esri/core/workers/chunks/661847f1b7044f21600f.js +1 -0
  34. package/assets/esri/core/workers/chunks/{1a8d8274df292d65f82e.js → 676c8c0329d68f9f3ac4.js} +1 -1
  35. package/assets/esri/core/workers/chunks/{29cc6b1705418b1be5d7.js → 687deb918eb48a963c8f.js} +1 -1
  36. package/assets/esri/core/workers/chunks/{0694c7bcfe71692e2ccf.js → 723df53cfa0189837d01.js} +1 -1
  37. package/assets/esri/core/workers/chunks/7582654a0fc70910731c.js +1 -0
  38. package/assets/esri/core/workers/chunks/{1ee4df0fd61440cb5f02.js → 7810586c35dfe1437516.js} +1 -1
  39. package/assets/esri/core/workers/chunks/8517d96fc8ba7b21d845.js +2 -0
  40. package/assets/esri/core/workers/chunks/90360c0bd053d3e3fd77.js +1 -0
  41. package/assets/esri/core/workers/chunks/9c3de54513bf8619271c.js +1 -0
  42. package/assets/esri/core/workers/chunks/{0e445ec3523de9f2dfa2.js → a107f16cd004626b5018.js} +1 -1
  43. package/assets/esri/core/workers/chunks/{e3b212f8af448ec29eef.js → a1e8209d00809c9520a0.js} +1 -1
  44. package/assets/esri/core/workers/chunks/{46453ebfee17b5421d9d.js → bf62be00f3040f91aaee.js} +1 -1
  45. package/assets/esri/core/workers/chunks/{89dc49e784f7ba3b93ea.js → c034c30e577d620b8e28.js} +1 -1
  46. package/assets/esri/core/workers/chunks/c5bf19da62a3d31009fe.js +2 -0
  47. package/assets/esri/core/workers/chunks/{2226c20c38e20713bcb5.js.LICENSE.txt → c5bf19da62a3d31009fe.js.LICENSE.txt} +1 -1
  48. package/assets/esri/core/workers/chunks/{6bb191b19ce43a27f205.js → caad4f475d6eb01c2850.js} +1 -1
  49. package/assets/esri/core/workers/chunks/cd55cad81accf51d2989.js +1 -0
  50. package/assets/esri/core/workers/chunks/db1f7b2562de495b3401.js +2 -0
  51. package/assets/esri/core/workers/chunks/e0a37d3bcb9a944e53dd.js +1 -0
  52. package/assets/esri/core/workers/chunks/{fe6dcb21570395e46ce8.js → e0a7a75709121a26f255.js} +1 -1
  53. package/assets/esri/core/workers/chunks/{096b2bf1c0d69d27f20c.js → e8e54faf947a582b4cf7.js} +1 -1
  54. package/assets/esri/core/workers/chunks/{636e9c4ac1f9ae98f9d1.js → ea81f9d71b0842a4be26.js} +1 -1
  55. package/assets/esri/core/workers/chunks/{164c8eeefa8232b2b191.js → eaa0e906b46ae4c84d72.js} +2 -2
  56. package/assets/esri/core/workers/chunks/{a504a5e06cb89a620799.js → ec8b7476eac4718eb0ac.js} +1 -1
  57. package/chunks/GlobalIllumination.glsl.js +55 -46
  58. package/chunks/GlobalIlluminationBlur.glsl.js +13 -9
  59. package/chunks/RibbonLine.glsl.js +90 -88
  60. package/config.js +1 -1
  61. package/core/has.js +1 -1
  62. package/core/workers.d.ts +1 -0
  63. package/geometry/support/MeshLocalVertexSpace.d.ts +3 -3
  64. package/geometry/support/aaBoundingRect.js +1 -1
  65. package/geometry/support/meshUtils/convertMeshVertexSpace.js +1 -1
  66. package/geometry/support/meshUtils/vertexSpaceConversion.js +1 -1
  67. package/identity/IdentityManagerBase.js +1 -1
  68. package/kernel.d.ts +3 -3
  69. package/kernel.js +1 -1
  70. package/layers/VoxelWasmPerSceneView.js +1 -1
  71. package/layers/WFSLayer.d.ts +8 -4
  72. package/layers/graphics/sources/WFSSource.js +1 -1
  73. package/layers/graphics/sources/geojson/geojson.js +1 -1
  74. package/layers/mixins/ArcGISMapService.d.ts +17 -0
  75. package/layers/mixins/ArcGISMapService.js +1 -1
  76. package/layers/ogc/wfsUtils.d.ts +7 -2
  77. package/layers/ogc/wfsUtils.js +1 -1
  78. package/layers/ogc/xmlUtils.js +1 -1
  79. package/package.json +4 -4
  80. package/rest/route.d.ts +1 -1
  81. package/rest/support/AreasAndLengthsParameters.d.ts +1 -1
  82. package/rest/support/LengthsParameters.d.ts +1 -1
  83. package/symbols/TextSymbol.d.ts +0 -1
  84. package/views/2d/layers/imagery/BaseImageryTileSubView2D.js +1 -1
  85. package/views/3d/FocusAreasView.js +1 -1
  86. package/views/3d/analysis/AreaMeasurement/support/AreaMeasurementVisualization.js +1 -1
  87. package/views/3d/analysis/DirectLineMeasurement/DirectLineMeasurementVisualization.js +1 -1
  88. package/views/3d/analysis/ElevationProfile/ElevationProfileLineSceneComputation.js +1 -1
  89. package/views/3d/analysis/LineOfSight/LineOfSightController.js +1 -1
  90. package/views/3d/layers/graphics/ElevationAligners.js +1 -1
  91. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  92. package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
  93. package/views/3d/layers/graphics/Graphics3DMeshObject3DGraphicLayer.js +1 -1
  94. package/views/3d/layers/graphics/Graphics3DSymbol.js +1 -1
  95. package/views/3d/layers/graphics/Graphics3DWaterSymbolLayer.js +1 -1
  96. package/views/3d/layers/graphics/Graphics3DWebStyleSymbol.js +1 -1
  97. package/views/3d/layers/graphics/MeshFastUpdateProcessor.js +1 -1
  98. package/views/3d/layers/graphics/polygonUtils.js +1 -1
  99. package/views/3d/state/ScreenSizePerspective.js +1 -1
  100. package/views/3d/state/ViewStateManager.js +1 -1
  101. package/views/3d/state/helpers/SceneIntersectionHelper.js +1 -1
  102. package/views/3d/support/RenderCoordsHelper.js +1 -1
  103. package/views/3d/terrain/TerrainRenderer.js +1 -1
  104. package/views/3d/terrain/TerrainSurface.js +1 -1
  105. package/views/3d/terrain/TileRenderer.js +1 -1
  106. package/views/3d/webgl-engine/lib/ManagedTexture.js +1 -1
  107. package/views/3d/webgl-engine/lib/NavigationDepthCache.js +1 -1
  108. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  109. package/views/3d/webgl-engine/lib/RibbonLineVertexInfo.js +1 -1
  110. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  111. package/views/3d/webgl-engine/materials/WaterMaterial.js +1 -1
  112. package/views/SceneView.js +1 -1
  113. package/views/webgl/BufferObject.js +1 -1
  114. package/views/webgl/FramebufferObject.js +1 -1
  115. package/widgets/ElevationProfile/ElevationProfileLineView.js +1 -1
  116. package/widgets/HistogramRangeSlider.d.ts +1 -1
  117. package/assets/esri/core/workers/chunks/0cc7fba402a93e6d2455.js +0 -2
  118. package/assets/esri/core/workers/chunks/131185d26343a997495e.js +0 -1
  119. package/assets/esri/core/workers/chunks/1a3f71c4d97c36050030.js +0 -1
  120. package/assets/esri/core/workers/chunks/2226c20c38e20713bcb5.js +0 -2
  121. package/assets/esri/core/workers/chunks/2981e904ab62f3ed80d0.js +0 -2
  122. package/assets/esri/core/workers/chunks/32cc59e126df8c96a0cf.js +0 -2
  123. package/assets/esri/core/workers/chunks/5bb6c255bdc8aa9ba23e.js +0 -1
  124. package/assets/esri/core/workers/chunks/654f5441227579d2b6b4.js +0 -1
  125. package/assets/esri/core/workers/chunks/7084dd6e10c6c1393e92.js +0 -1
  126. package/assets/esri/core/workers/chunks/7566321c6a2913f2852b.js +0 -1
  127. package/assets/esri/core/workers/chunks/7b5cd150a4d0139850be.js +0 -1
  128. package/assets/esri/core/workers/chunks/7cc9d7a88b64e25fce14.js +0 -1
  129. package/assets/esri/core/workers/chunks/844eedda8f749972f707.js +0 -2
  130. package/assets/esri/core/workers/chunks/87177e0f82e8a6ae3189.js +0 -1
  131. package/assets/esri/core/workers/chunks/9976eaa81085c0d17e14.js +0 -1
  132. package/assets/esri/core/workers/chunks/a2196a49f89d57a0a1c7.js +0 -1
  133. package/assets/esri/core/workers/chunks/aba259a70bee68d2edb7.js +0 -1
  134. package/assets/esri/core/workers/chunks/b9cb92858a576eb6aa06.js +0 -1
  135. package/assets/esri/core/workers/chunks/c33a9635c294c8774977.js +0 -1
  136. package/assets/esri/core/workers/chunks/f39c700f3db7db52b522.js +0 -1
  137. /package/assets/esri/core/workers/chunks/{844eedda8f749972f707.js.LICENSE.txt → 2b4dd42920d37b1ff0a9.js.LICENSE.txt} +0 -0
  138. /package/assets/esri/core/workers/chunks/{32cc59e126df8c96a0cf.js.LICENSE.txt → 4f3e0d583cfa9d1d6727.js.LICENSE.txt} +0 -0
  139. /package/assets/esri/core/workers/chunks/{bd46a04a9ee4ea9e6ef1.js.LICENSE.txt → 5864bce1498a13ee5b7e.js.LICENSE.txt} +0 -0
  140. /package/assets/esri/core/workers/chunks/{0cc7fba402a93e6d2455.js.LICENSE.txt → 8517d96fc8ba7b21d845.js.LICENSE.txt} +0 -0
  141. /package/assets/esri/core/workers/chunks/{2981e904ab62f3ed80d0.js.LICENSE.txt → db1f7b2562de495b3401.js.LICENSE.txt} +0 -0
  142. /package/assets/esri/core/workers/chunks/{164c8eeefa8232b2b191.js.LICENSE.txt → eaa0e906b46ae4c84d72.js.LICENSE.txt} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6884],{38961(e,t,r){var i=r(32198),s=r(7762),o=r(36708),a=r(10107),l=r(64108),n=r(80559);let u=class extends s.A{constructor(e){super(e),this.getCollections=null}initialize(){this.addHandles((0,n.fm)(()=>this._refresh(),o.OH))}destroy(){this.getCollections=null}_refresh(){let e=this.getCollections?.();if(null==e)return void this.removeAll();let t=0;for(let r of e)null!=r&&(t=this._processCollection(t,r));this.splice(t)}_createNewInstance(e){return new s.A(e)}_processCollection(e,t){if(!t)return e;let r=this.itemFilterFunction??(e=>!!e);for(let i of t)if(i){if(r(i)){let t=this.indexOf(i,e);t>=0?t!==e&&this.reorder(i,e):this.add(i,e),++e}if(this.getChildrenFunction){let t=this.getChildrenFunction(i);if(Array.isArray(t))for(let r of t)e=this._processCollection(e,r);else e=this._processCollection(e,t)}}return e}};(0,i.Cg)([(0,a.MZ)()],u.prototype,"getCollections",void 0),(0,i.Cg)([(0,a.MZ)()],u.prototype,"getChildrenFunction",void 0),(0,i.Cg)([(0,a.MZ)()],u.prototype,"itemFilterFunction",void 0),u=(0,i.Cg)([(0,l.$)("esri.core.CollectionFlattener")],u);const p=u;r.d(t,["A",0,p])},46140(e,t,r){r.d(t,{A:()=>s});var i=r(49186);class s{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}toString(){return`${this.major}.${this.minor}`}validate(e){if(this.major!==e.major){let t=this._context&&this._context+":",r=this._context&&this._context+" ";throw new i.A(t+"unsupported-version",`Required major ${r}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new s(this.major,this.minor,this._context)}static parse(e,t=""){let[r,o]=e.split("."),a=/^\s*\d+\s*$/;if(!r?.match||!a.test(r)){let r=t&&t+":";throw new i.A(r+"invalid-version","Expected major version to be a number, but got '${version}'",{version:e})}if(!o?.match||!a.test(o)){let r=t&&t+":";throw new i.A(r+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:e})}return new s(parseInt(r,10),parseInt(o,10),t)}}},6797(e,t,r){r.d(t,{Ui:()=>y});var i=r(69622),s=r(7762),o=r(88620);const a=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function l(e){return e instanceof i.A}function n(e){return e instanceof s.A?Object.keys(e.items):l(e)?(0,o.oY)(e).keys():e?Object.keys(e):[]}function u(e,t){return e instanceof s.A?e.items[t]:e[t]}function p(e){return e?e.declaredClass:null}function d(e,t){let r=e.diff;if(r&&"function"==typeof r)return r(e,t);let i=n(e),s=n(t);if(0===i.length&&0===s.length)return;if(!i.length||!s.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};let o=s.filter(e=>!i.includes(e)),y=i.filter(e=>!s.includes(e)),c=i.filter(r=>s.includes(r)&&u(e,r)!==u(t,r)).concat(o,y).sort(),h=p(e);if(h&&a.has(h)&&c.length)return{type:"complete",oldValue:e,newValue:t};let f,g=l(e)&&l(t);for(let i of c){let s,o=u(e,i),a=u(t,i);if((g||"function"!=typeof o&&"function"!=typeof a)&&o!==a&&(null!=o||null!=a)){if(r&&r[i]&&"function"==typeof r[i])s=r[i]?.(o,a);else if(o instanceof Date&&a instanceof Date){if(o.getTime()===a.getTime())continue;s={type:"complete",oldValue:o,newValue:a}}else s="object"==typeof o&&"object"==typeof a&&p(o)===p(a)?d(o,a):{type:"complete",oldValue:o,newValue:a};null!=s&&(null==f?f={type:"partial",diff:{[i]:s}}:f.diff[i]=s)}}return f}function y(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&p(e)!==p(t)?{type:"complete",oldValue:e,newValue:t}:d(e,t)}},81583(e,t,r){r.d(t,{L:()=>l,g:()=>a});var i=r(60999),s=r(7762),o=r(92474);async function a(e,t){return await e.load(),l(e,t)}async function l(e,t){let r=[],a=(...e)=>{for(let t of e)null!=t&&(Array.isArray(t)?a(...t):s.A.isCollection(t)?t.forEach(e=>a(e)):(0,o.Zm)(t)&&r.push(t))};t(a);let l=null;if(await(0,i.Tj)(r,async e=>{let t=await(0,i.Ke)(function(e){return"loadAll"in e&&"function"==typeof e.loadAll}(e)?e.loadAll():e.load());!1===t.ok&&!l&&(l=t)}),l)throw l.error;return e}},64314(e,t,r){r.d(t,{A:()=>C});var i=r(32198),s=r(69622),o=r(49186),a=r(44208),l=r(17676),n=r(84952),u=r(91429),p=r(21325),d=r(20557),y=r(2272),c=r(99614),h=r(20615),f=r(74910),g=r(78286),m=r(99199),b=r(62815),v=r(63746);class w{constructor(e){this._options=e,this.featureSet={features:[]},this.parseOnly=null,this._transformInPlace=null,this._transformInPlaceXY=null,this._finishVertex=w._finishVertexNonPoint,this._attributesClass=null,this._previousX=0,this._previousY=0,this._point=null,this._lengths=null,this._vertex=[],this._part=null,this._parts=null,this._i=0}queryGeometryType(){return this.featureSet.queryGeometryType}queryGeometry(){return this.featureSet.queryGeometry}idField(e){"string"==typeof e&&(this.featureSet.objectIdFieldName=e)}finish(){this._options.applyTransform&&(this.featureSet.transform=null);let{spatialReference:e,features:t}=this.featureSet;if(e)for(let{geometry:r}of t)r&&(r.spatialReference=e)}feature(){this._attributesClass??=(0,v._)(this.featureSet.fields?.map(e=>e.name)??[]),this.featureSet.features.push({attributes:new this._attributesClass}),this._options.applyTransform&&this._setVertexTransformer()}centroid([e,t]){this.featureSet.features.at(-1).centroid={x:e,y:t}}geometry(e,t,r){this._previousX=this._previousY=0,this._lengths=r;let i,{hasZ:s,hasM:o}=this.featureSet;switch(s??=!1,o??=!1,this._i=0,this._vertex=[0,0],s&&this._vertex.push(0),o&&this._vertex.push(0),this._finishVertex=w._finishVertexNonPoint,t){case"esriGeometryPoint":this._point={x:0,y:0},i=this._point,this._finishVertex=s?o?w._finishVertexPointXYZM:w._finishVertexPointXYZ:o?w._finishVertexPointXYM:w._finishVertexPointXY;break;case"esriGeometryMultipoint":i={points:[],hasZ:s,hasM:o},this._part=i.points,this._parts=[];break;case"esriGeometryPolyline":i={paths:[],hasZ:s,hasM:o},this._parts=i.paths,this._part=[];break;case"esriGeometryPolygon":i={rings:[],hasZ:s,hasM:o},this._parts=i.rings,this._part=[]}1===e?(this.featureSet.queryGeometry=i,this.featureSet.queryGeometryType=t,this._options.applyTransform||this._setVertexTransformer()):this.featureSet.features.at(-1).geometry=i}coord(e){let t=this._vertex;t[this._i++]=e,this._i<t.length||(this._i=0,this._transformInPlace&&(t[0]+=this._previousX,t[1]+=this._previousY,[this._previousX,this._previousY]=t,this._transformInPlace(t)),this._finishVertex(this))}curvedGeometry(e,t,r,i){let s,{hasZ:o,hasM:a}=this.featureSet;switch(o??=!1,a??=!1,e){case"esriGeometryPoint":case"esriGeometryMultipoint":throw Error(`Curved ${e} does not make sense`);case"esriGeometryPolyline":s={paths:[],curvePaths:[],hasZ:o,hasM:a},this._parts=s.curvePaths,this._part=[];break;case"esriGeometryPolygon":s={rings:[],curveRings:[],hasZ:o,hasM:a},this._parts=s.curveRings,this._part=[]}this.featureSet.features.at(-1).geometry=s}startCurvedPart(e){this._part.push(this._transform(e))}finishCurvedPart(e){this._parts.push(this._part),this._part=[]}lineSegment(e,t){this._part.push(this._transform(t))}bezierSegment(e,t,r,i){this._part.push({b:[this._transform(t),this._transformXY(r),this._transformXY(i)]})}circularArcSegment(e,t,r){this._part.push({c:[this._transform(t),this._transformXY(r)]})}ellipticArcSegment(e,t,r,i,s,o,a,l){this._part.push({a:[this._transform(t),this._transformXY(r),i,s,o,a,l]})}static _finishVertexPointXY({_point:e,_vertex:t}){[e.x,e.y]=t}static _finishVertexPointXYZ({_point:e,_vertex:t}){[e.x,e.y,e.z]=t}static _finishVertexPointXYM({_point:e,_vertex:t}){[e.x,e.y,e.m]=t}static _finishVertexPointXYZM({_point:e,_vertex:t}){[e.x,e.y,e.z,e.m]=t}static _finishVertexNonPoint(e){let{_part:t,_parts:r,_lengths:i,_vertex:s}=e;t.push([...s]),t.length<i[r.length]||(e._previousX=e._previousY=0,e._part=[],r.push(t))}_setVertexTransformer(){let{sourceSpatialReference:e}=this._options,{spatialReference:t,hasZ:r,transform:i}=this.featureSet,s=r?(0,b.d)(e,t):1;this._transformInPlace??=(0,v.M)(this.featureSet,s),this._transformInPlaceXY??=(0,v.M)({transform:i})}_transform(e){let t=[...e];return this._transformInPlace?.(t),t}_transformXY(e){let t=[e[0],e[1]];return this._transformInPlaceXY?.(t),t}}var S=r(80893),I=r(22671),x=r(97552);let C=class extends s.A{constructor(e){super(e),this.dynamicDataSource=null,this.fieldsIndex=null,this.gdbVersion=null,this.infoFor3D=null,this.pbfSupported=!1,this.pbfSupportedWithCurves=!1,this.queryAttachmentsSupported=!1,this.relativeTimeBinWindow=0,this.sourceSpatialReference=null,this.timeInformation=null,this.uniqueIdFields=null,this.url=null}get parsedUrl(){return(0,n.An)(this.url)}async execute(e,t){let r=await this.executeJSON(e,t);return this.featureSetFromJSON(e,r,t)}async executeJSON(e,t){let r,i=this._normalizeQuery(e),s=null!=e.outStatistics?.[0],o=(0,a.A)("featurelayer-pbf-statistics");if(this.pbfSupported&&(!s||o)&&(!e.returnTrueCurves||this.pbfSupportedWithCurves))try{r=await async function(e,t,r,i){let s=(0,y.Dl)(e),o={...r},a=x.A.from(t),l=!a.quantizationParameters;return await(0,S.IJ)(s,a,new w({sourceSpatialReference:a.sourceSpatialReference,applyTransform:l}),o,i)}(this.url,i,t,{timeInformation:this.timeInformation,uniqueIdFields:this.uniqueIdFields})}catch(e){if("query:parsing-pbf"!==e.name)throw e;this.pbfSupported=!1}return r??=await(0,m.e)(this.url,i,t,{timeInformation:this.timeInformation,uniqueIdFields:this.uniqueIdFields}),this._normalizeFields(r.fields),r}async featureSetFromJSON(e,t,i){if(!this._queryGet3DObjectFormat(e)||null==this.infoFor3D||!t.features)return I.A.fromJSON(t);let{meshFeatureSetFromJSON:s}=await(0,l.qr)(Promise.all([r.e(2258),r.e(8331),r.e(9855)]).then(()=>r(40050)),i);return s(e,this.infoFor3D,t)}executeForCount(e,t){return(0,h.I)(this.url,this._normalizeQuery(e),t,{timeInformation:this.timeInformation,uniqueIdFields:this.uniqueIdFields})}executeForExtent(e,t){return(0,f.L)(this.url,this._normalizeQuery(e),t)}executeForIds(e,t){return(0,g.V)(this.url,this._normalizeQuery(e),t,{timeInformation:this.timeInformation,uniqueIdFields:this.uniqueIdFields})}async executeRelationshipQuery(e,t){let[{default:i},{executeRelationshipQuery:s}]=await(0,l.qr)(Promise.all([Promise.resolve().then(()=>r(26591)),r.e(1763).then(()=>r(71763))]),t),o=i.from(e);return(this.gdbVersion||this.dynamicDataSource)&&(o=o.clone(),o.gdbVersion=o.gdbVersion||this.gdbVersion,o.dynamicDataSource=o.dynamicDataSource||this.dynamicDataSource),s(this.url,o,t)}async executeRelationshipQueryForCount(e,t){let[{default:i},{executeRelationshipQueryForCount:s}]=await(0,l.qr)(Promise.all([Promise.resolve().then(()=>r(26591)),r.e(1763).then(()=>r(71763))]),t),o=i.from(e);return(this.gdbVersion||this.dynamicDataSource)&&(o=o.clone(),o.gdbVersion=o.gdbVersion||this.gdbVersion,o.dynamicDataSource=o.dynamicDataSource||this.dynamicDataSource),s(this.url,o,t)}async executeAttachmentQuery(e,t){let{executeAttachmentQuery:i,fetchAttachments:s,processAttachmentQueryResult:o}=await(0,l.qr)(r.e(9239).then(()=>r(9239)),t),a=(0,y.Dl)(this.url);return o(a,await(this.queryAttachmentsSupported?i(a,e,t):s(a,e,t)))}async executeAttributeBinsQuery(e,t){let{executeAttributeBinsQuery:i}=await(0,l.qr)(r.e(3103).then(()=>r(33103)),t);return i(this.parsedUrl,e,t)}async executePivotQuery(e,t){let{executePivotQuery:i}=await(0,l.qr)(r.e(566).then(()=>r(80566)),t);return i(this.parsedUrl,e,t)}async executeTopFeaturesQuery(e,t){let{executeTopFeaturesQuery:i}=await(0,l.qr)(r.e(1273).then(()=>r(11273)),t);return i(this.parsedUrl,e,this.sourceSpatialReference,t)}async executeForTopIds(e,t){let{executeForTopIds:i}=await(0,l.qr)(r.e(1277).then(()=>r(21277)),t);return i(this.parsedUrl,e,t)}async executeForTopExtents(e,t){let{executeForTopExtents:i}=await(0,l.qr)(r.e(8018).then(()=>r(8018)),t);return i(this.parsedUrl,e,t)}async executeForTopCount(e,t){let{executeForTopCount:i}=await(0,l.qr)(r.e(980).then(()=>r(10980)),t);return i(this.parsedUrl,e,t)}_normalizeQuery(e){let t=x.A.from(e);t.sourceSpatialReference=t.sourceSpatialReference||this.sourceSpatialReference,(this.gdbVersion||this.dynamicDataSource)&&(t=t===e?t.clone():t,t.gdbVersion=e.gdbVersion||this.gdbVersion,t.dynamicDataSource=e.dynamicDataSource||this.dynamicDataSource);let{infoFor3D:r}=this,i=this._queryGet3DObjectFormat(e);if(null!=r&&i){if(t=t===e?t.clone():t,t.formatOf3DObjects=i,t.outSpatialReference&&!(0,p.aI)(t.outSpatialReference,this.sourceSpatialReference))throw new o.A("query:unsupported-out-spatial-reference","3D object feature services do not support projection of geometries");if(null==t.outFields||!t.outFields.includes("*")){t=t===e?t.clone():t,t.outFields??(t.outFields=[]);let{originX:i,originY:s,originZ:o,translationX:a,translationY:l,translationZ:n,scaleX:u,scaleY:p,scaleZ:d,rotationX:y,rotationY:c,rotationZ:h,rotationDeg:f}=r.transformFieldRoles;t.outFields.push(i,s,o,a,l,n,u,p,d,y,c,h,f)}}return t}_normalizeFields(e){if(null!=this.fieldsIndex&&null!=e)for(let t of e){let e=this.fieldsIndex.get(t.name);e&&Object.assign(t,e.toJSON())}}_queryGet3DObjectFormat({returnGeometry:e,multipatchOption:t,outStatistics:r}){return!0!==e||"xyFootprint"===t||r?null:(0,d.Hz)(this.infoFor3D)}};(0,i.Cg)([(0,u.MZ)({types:c.e})],C.prototype,"dynamicDataSource",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"fieldsIndex",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"gdbVersion",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"infoFor3D",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],C.prototype,"parsedUrl",null),(0,i.Cg)([(0,u.MZ)()],C.prototype,"pbfSupported",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"pbfSupportedWithCurves",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"queryAttachmentsSupported",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"relativeTimeBinWindow",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"sourceSpatialReference",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"timeInformation",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"uniqueIdFields",void 0),(0,i.Cg)([(0,u.MZ)({type:String})],C.prototype,"url",void 0),C=(0,i.Cg)([(0,u.$K)("esri.layers.graphics.sources.support.QueryTask")],C)},52136(e,t,r){var i=r(32198),s=r(91429);r.d(t,["p",0,e=>{let t=e,r=class extends t{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null==e?(this._clearOverride("apiKey"),this.clear("apiKey","user")):this._override("apiKey",e)}};return(0,i.Cg)([(0,s.MZ)({type:String})],r.prototype,"apiKey",null),r=(0,i.Cg)([(0,s.$K)("esri.layers.mixins.APIKeyMixin")],r),r}])},98534(e,t,r){var i=r(32198),s=r(56507),o=r(5479),a=r(91869),l=r(17676),n=r(84952),u=r(46140),p=r(91429),d=r(5443),y=r(16930),c=r(60694),h=r(10873),f=r(10407),g=r(36005);r.d(t,["V",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.capabilities=void 0,this.copyright=null,this.fullExtent=null,this.legendEnabled=!0,this.spatialReference=null,this.version=void 0,this._allLayersAndTablesMap=null}readCapabilities(e,t){let r=t.capabilities&&t.capabilities.split(",").map(e=>e.toLowerCase().trim());if(!r)return{operations:{supportsExportMap:!1,supportsExportTiles:!1,supportsIdentify:!1,supportsQuery:!1,supportsTileMap:!1},exportMap:null,exportTiles:null};let i=this.type,s="tile"!==i&&!!t.supportsDynamicLayers,o=r.includes("query"),a=r.includes("map"),l=!!t.exportTilesAllowed,n=r.includes("tilemap"),p=r.includes("data"),d="tile"!==i&&(!t.tileInfo||s),y="tile"!==i&&(!t.tileInfo||s),c="tile"!==i,h="tile"!==i&&s&&t.currentVersion>=11.1,f=t.cimVersion?u.A.parse(t.cimVersion):null,g=f?.greaterEqual(1,4)??!1,m=f?.greaterEqual(2,0)??!1;return{operations:{supportsExportMap:a,supportsExportTiles:l,supportsIdentify:o,supportsQuery:p,supportsTileMap:n},exportMap:a?{supportsArcadeExpressionForLabeling:g,supportsCIMSymbols:m,supportsDynamicLayers:s,supportsSublayerOrderBy:h,supportsSublayerDefinitionExpression:y,supportsSublayerVisibility:d,supportsSublayersChanges:c}:null,exportTiles:l?{maxExportTilesCount:+t.maxExportTilesCount}:null}}readVersion(e,t){let r=t.currentVersion;return r||=t.hasOwnProperty("capabilities")||t.hasOwnProperty("tables")?10:t.hasOwnProperty("supportedImageFormatTypes")?9.31:9.3,r}async fetchRelatedService(e){let t=this.portalItem;if(!t||!(0,f.bK)(t))return null;this._relatedFeatureServicePromise||=t.fetchRelatedItems({relationshipType:"Service2Service",direction:"reverse"},e).then(e=>e.find(e=>"Feature Service"===e.type)??null,()=>null);let r=await this._relatedFeatureServicePromise;return(0,l.Te)(e),r?{itemId:r.id,url:r.url}:null}async fetchSublayerInfo(e,t){let{source:r}=e;if(this?.portalItem&&"tile"===this.type&&"map-layer"===r?.type&&(0,f.bK)(this.portalItem)&&e.originIdOf("url")<2){let i=await this.fetchRelatedService(t);i&&(e.url=(0,n.fj)(i.url,r.mapLayerId.toString()),e.layerItemId=i.itemId)}let i,{url:o}=e;if("data-layer"===r.type||"workspace-layer"===r.type)i=(await(0,s.A)(o,{responseType:"json",query:{f:"json",...this.customParameters,token:this.apiKey},...t})).data;else{let s=e.id;"map-layer"===r?.type&&(s=r.mapLayerId);try{i=(await this.fetchAllLayersAndTables(t)).get(s)}catch{}if(o&&e.originIdOf("url")>2)try{let e=await this._fetchAllLayersAndTablesFromService(o),t=(0,c.qg)(o)?.sublayer??r.mapLayerId,s=structuredClone(e.get(t));if(null!=s){for(let e of["drawingInfo","maxScale","minScale","name"])delete s[e];i={...i,...s}}}catch{}}return i}async fetchAllLayersAndTables(e){return this._fetchAllLayersAndTablesFromService(this.parsedUrl?.path,e)}async _fetchAllLayersAndTablesFromService(e,t){await this.load(t),this._allLayersAndTablesMap||=new Map;let r=(0,c.qg)(e),i=await(0,a.tE)(this._allLayersAndTablesMap,r?.url.path,()=>(0,s.A)((0,n.fj)(r?.url.path,"/layers"),{query:{f:"json",...this.customParameters,token:this.apiKey}}).then(async e=>{let t=new Map,{layers:i,tables:a}=e.data,l=[...i??[],...a??[]];for(let e of l)t.set(e.id,e);if((0,o.zN)(t.values(),e=>null==e.capabilities||null==e.extent)){let{data:e}=await(0,s.A)(r?.url.path,{query:{f:"json",...this.customParameters,token:this.apiKey}}).catch(()=>({data:{capabilities:"",fullExtent:void 0}}));for(let r of t.values())r.capabilities??=e.capabilities??"",r.extent??=e.fullExtent}return{result:t}},e=>({error:e})));if((0,l.Te)(t),"result"in i)return i.result;throw i.error}};return(0,i.Cg)([(0,p.MZ)({readOnly:!0})],r.prototype,"capabilities",void 0),(0,i.Cg)([(0,g.w)("service","capabilities",["capabilities","cimVersion","currentVersion","exportTilesAllowed","maxExportTilesCount","supportsDynamicLayers","tileInfo"])],r.prototype,"readCapabilities",null),(0,i.Cg)([(0,p.MZ)({json:{read:{source:"copyrightText"}}})],r.prototype,"copyright",void 0),(0,i.Cg)([(0,p.MZ)({type:d.A})],r.prototype,"fullExtent",void 0),(0,i.Cg)([(0,p.MZ)(h.id)],r.prototype,"id",void 0),(0,i.Cg)([(0,p.MZ)({type:Boolean,json:{origins:{service:{read:{enabled:!1}}},read:{source:"showLegend"},write:{target:"showLegend"}}})],r.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,p.MZ)(h.M6)],r.prototype,"popupEnabled",void 0),(0,i.Cg)([(0,p.MZ)({type:y.A})],r.prototype,"spatialReference",void 0),(0,i.Cg)([(0,p.MZ)({readOnly:!0})],r.prototype,"version",void 0),(0,i.Cg)([(0,g.w)("service","version",["currentVersion","capabilities","tables","supportedImageFormatTypes"])],r.prototype,"readVersion",null),r=(0,i.Cg)([(0,p.$K)("esri.layers.mixins.ArcGISMapService")],r),r}])},32756(e,t,r){r.d(t,{Rr:()=>l});var i=r(32198),s=r(93637),o=r(91429),a=r(91880);function l(e,t,r){if(!e)return null;let i=e.find(e=>!!e.field);if(!i)return null;let s=new a.A;return s.read(i,r),[s]}const n={type:[a.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:l},write:{writer:function(e,t,r,i){let o=e.find(e=>!!e.field);o&&(0,s.sM)(r,[o.toJSON()],t)}}}};r.d(t,["fY",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,i.Cg)([(0,o.MZ)(n)],r.prototype,"orderBy",void 0),r=(0,i.Cg)([(0,o.$K)("esri.layers.mixins.OrderedLayer")],r),r},"ne",0,n])},91921(e,t,r){var i=r(32198),s=r(7762),o=r(38961),a=r(49186),l=r(53966),n=r(36708),u=r(91429),p=r(35666),d=r(88620),y=r(15775),c=r(63389);const h=s.A.ofType(y.A);function f(e,t){e&&e.forEach(e=>{t(e),e.sublayers&&e.sublayers.length&&f(e.sublayers,t)})}r.d(t,["I",0,e=>{let t=e,r=class extends t{constructor(...e){super(...e),this.allSublayers=new o.A({getCollections:()=>[this.sublayers],getChildrenFunction:e=>e.sublayers}),this.sublayersSourceJSON={2:{},3:{},4:{},5:{},6:{}},this.subtables=null,this.addHandles([(0,n.wB)(()=>this.sublayers,(e,t)=>this._handleSublayersChange(e,t),n.OH),(0,n.wB)(()=>this.subtables,(e,t)=>this._handleSublayersChange(e,t),n.OH)])}destroy(){this.allSublayers.destroy()}readSublayers(e,t){if(!t||!e)return;let{sublayersSourceJSON:r}=this,i=(0,p.aB)(t.origin);if(i<2||(r[i]={context:t,visibleLayers:e.visibleLayers||r[i].visibleLayers,layers:e.layers||r[i].layers},i>2))return;this._set("serviceSublayers",this.createSublayersForOrigin("service").sublayers);let{sublayers:s,origin:o}=this.createSublayersForOrigin("web-document"),a=(0,d.oY)(this);a.setDefaultOrigin(o),this._set("sublayers",new h(s)),a.setDefaultOrigin("user")}findSublayerById(e){return this.allSublayers.find(t=>t.id===e)}createServiceSublayers(){return this.createSublayersForOrigin("service").sublayers}createSublayersForOrigin(e){let t,r=(0,p.aB)("web-document"===e?"web-map":e),i=2,s=this.sublayersSourceJSON[2].layers,o=this.sublayersSourceJSON[2].context,a=null,l=[3,4,5].filter(e=>e<=r);for(let e of l){let t=this.sublayersSourceJSON[e];(0,c._X)(t.layers)&&(i=e,s=t.layers,o=t.context,t.visibleLayers&&(a={visibleLayers:t.visibleLayers,context:t.context}))}let n=[3,4,5].filter(e=>e>i&&e<=r),u=null;for(let e of n){let{layers:r,visibleLayers:i,context:s}=this.sublayersSourceJSON[e];r&&(u={layers:r,context:s},t??=e),i&&(a={visibleLayers:i,context:s})}let d=function(e,t){let r=[],i={};return e&&e.forEach(e=>{let s=new y.A;if(s.read(e,t),i[s.id]=s,null!=e.parentLayerId&&-1!==e.parentLayerId){let t=i[e.parentLayerId];t.sublayers||=[],t.sublayers.unshift(s)}else r.unshift(s)}),r}(s,o),g=new Map,m=new Set;if(u)for(let e of u.layers)g.set(e.id,e);if(a?.visibleLayers)for(let e of a.visibleLayers)m.add(e);return f(d,e=>{u&&e.read(g.get(e.id),u.context),a&&e.read({defaultVisibility:m.has(e.id)},a.context)}),{origin:(0,p.OL)(i),originWithPartialOverrides:t?(0,p.OL)(t):null,sublayers:new h({items:d})}}read(e,t){super.read(e,t),this.readSublayers(e,t)}_handleSublayersChange(e,t){t&&(t.forEach(e=>{e.parent=null,e.layer=null}),this.removeHandles("sublayers-owner")),e&&(e.forEach(e=>{e.parent=this,e.layer=this}),this.addHandles([e.on("after-add",({item:e})=>{e.parent=this,e.layer=this}),e.on("after-remove",({item:e})=>{e.parent=null,e.layer=null})],"sublayers-owner"),"tile"===this.type&&this.addHandles(e.on("before-changes",e=>{l.A.getLogger("esri.layers.TileLayer").error(new a.A("tilelayer:sublayers-non-modifiable","Sublayer can't be added, moved, or removed from the layer's sublayers",{layer:this})),e.preventDefault()}),"sublayers-owner"))}};return(0,i.Cg)([(0,u.MZ)({readOnly:!0})],r.prototype,"allSublayers",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],r.prototype,"effectiveScaleRange",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],r.prototype,"effectiveVisible",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0,type:s.A.ofType(y.A)})],r.prototype,"serviceSublayers",void 0),(0,i.Cg)([(0,u.MZ)({value:null,type:h,json:{read:!1,write:{allowNull:!0,ignoreOrigin:!0}}})],r.prototype,"sublayers",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],r.prototype,"sublayersSourceJSON",void 0),(0,i.Cg)([(0,u.MZ)({type:h,json:{read:{source:"tables"}}})],r.prototype,"subtables",void 0),r=(0,i.Cg)([(0,u.$K)("esri.layers.mixins.SublayersOwner")],r),r}])},28032(e,t,r){r.d(t,{A:()=>n});var i=r(32198),s=r(69540),o=r(25482),a=r(91429),l=r(56400);let n=class extends((0,s.OU)(o.o)){constructor(e){super(e),this.creatorField=null,this.creationDateField=null,this.editorField=null,this.editDateField=null,this.realm=null,this.timeZone=null}};(0,i.Cg)([(0,a.MZ)()],n.prototype,"creatorField",void 0),(0,i.Cg)([(0,a.MZ)()],n.prototype,"creationDateField",void 0),(0,i.Cg)([(0,a.MZ)()],n.prototype,"editorField",void 0),(0,i.Cg)([(0,a.MZ)()],n.prototype,"editDateField",void 0),(0,i.Cg)([(0,a.MZ)()],n.prototype,"realm",void 0),(0,i.Cg)([(0,a.MZ)((0,l.P6)("dateFieldsTimeReference",!0))],n.prototype,"timeZone",void 0),n=(0,i.Cg)([(0,a.$K)("esri.layers.support.EditFieldsInfo")],n)},29005(e,t,r){r.d(t,{A:()=>u});var i=r(32198),s=r(69540),o=r(66552),a=r(25482),l=r(91429);const n=new o.J({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let u=class extends((0,s.OU)(a.o)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,i.Cg)([(0,l.MZ)({json:{write:!0}})],u.prototype,"name",void 0),(0,i.Cg)([(0,l.MZ)({json:{write:!0}})],u.prototype,"description",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:n.read,write:n.write}})],u.prototype,"drawingTool",void 0),(0,i.Cg)([(0,l.MZ)({json:{write:!0}})],u.prototype,"prototype",void 0),(0,i.Cg)([(0,l.MZ)({json:{write:!0}})],u.prototype,"thumbnail",void 0),u=(0,i.Cg)([(0,l.$K)("esri.layers.support.FeatureTemplate")],u)},33143(e,t,r){r.d(t,{A:()=>d});var i=r(32198),s=r(69540),o=r(25482),a=r(91429),l=r(8631),n=r(29005),u=r(36005),p=r(43937);let d=class extends((0,s.OU)(o.o)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){let t={};for(let r of Object.keys(e))t[r]=(0,l.r)(e[r]);return t}writeDomains(e,t){let r={};for(let t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"id",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"name",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"domains",void 0),(0,i.Cg)([(0,u.w)("domains")],d.prototype,"readDomains",null),(0,i.Cg)([(0,p.K)("domains")],d.prototype,"writeDomains",null),(0,i.Cg)([(0,a.MZ)({type:[n.A],json:{write:!0}})],d.prototype,"templates",void 0),d=(0,i.Cg)([(0,a.$K)("esri.layers.support.FeatureType")],d)},46499(e,t,r){r.d(t,{A:()=>C});var i,s,o=r(32198),a=(r(44208),r(66552)),l=r(25482),n=r(4718),u=r(90629),p=r(91429),d=r(90360),y=r(73913),c=r(32730),h=r(77548),f=r(59868),g=r(73838),m=r(33910),b=r(36005),v=r(43937);const w=new a.J({esriServerPointLabelPlacementAboveCenter:"above-center",esriServerPointLabelPlacementAboveLeft:"above-left",esriServerPointLabelPlacementAboveRight:"above-right",esriServerPointLabelPlacementBelowCenter:"below-center",esriServerPointLabelPlacementBelowLeft:"below-left",esriServerPointLabelPlacementBelowRight:"below-right",esriServerPointLabelPlacementCenterCenter:"center-center",esriServerPointLabelPlacementCenterLeft:"center-left",esriServerPointLabelPlacementCenterRight:"center-right",esriServerLinePlacementAboveAfter:"above-after",esriServerLinePlacementAboveAlong:"above-along",esriServerLinePlacementAboveBefore:"above-before",esriServerLinePlacementAboveStart:"above-start",esriServerLinePlacementAboveEnd:"above-end",esriServerLinePlacementBelowAfter:"below-after",esriServerLinePlacementBelowAlong:"below-along",esriServerLinePlacementBelowBefore:"below-before",esriServerLinePlacementBelowStart:"below-start",esriServerLinePlacementBelowEnd:"below-end",esriServerLinePlacementCenterAfter:"center-after",esriServerLinePlacementCenterAlong:"center-along",esriServerLinePlacementCenterBefore:"center-before",esriServerLinePlacementCenterStart:"center-start",esriServerLinePlacementCenterEnd:"center-end",esriServerPolygonPlacementAlwaysHorizontal:"always-horizontal"},{ignoreUnknown:!0});function S(e,t,r){return{enabled:!(0,h.TU)(r?.layer)}}function I(e){return!e||"service"!==e.origin&&"map-image"!==e.layer?.type}function x(e){return!!function(e){return"map-image"===e?.type}(e)&&!!e.capabilities?.exportMap?.supportsArcadeExpressionForLabeling}let C=class extends l.o{static{i=c.vK}static{s=this}static evaluateWhere(e,t){let r=(e,t,r)=>{switch(t){case"=":return e==r;case"<>":return e!=r;case">":return e>r;case">=":return e>=r;case"<":return e<r;case"<=":return e<=r}return!1};try{if(null==e)return!0;let i=e.split(" ");if(3===i.length)return r(t[i[0]],i[1],i[2]);if(7===i.length){let e=r(t[i[0]],i[1],i[2]),s=i[3],o=r(t[i[4]],i[5],i[6]);switch(s){case"AND":return e&&o;case"OR":return e||o}}return!1}catch{}}constructor(e){super(e),this[i]=!0,this.type="label",this.name=null,this.allowOverrun=!1,this.deconflictionStrategy="static",this.labelExpression=null,this.labelExpressionInfo=null,this.labelPlacement=null,this.offsetDistance=0,this.labelPosition="curved",this.maxScale=0,this.minScale=0,this.repeatLabel=!0,this.symbol=f.Hk,this.useCodedValues=void 0,this.where=null}readLabelExpression(e,t){let r=t.labelExpressionInfo;if(!r||!r.value&&!r.expression)return e}writeLabelExpression(e,t,r){if(this.labelExpressionInfo)if(null!=this.labelExpressionInfo.value)e=(0,c.D3)(this.labelExpressionInfo.value);else if(null!=this.labelExpressionInfo.expression){let t=(0,c.tH)(this.labelExpressionInfo.expression);t&&(e="["+t+"]")}null!=e&&(t[r]=e)}writeLabelExpressionInfo(e,t,r,i){if(null==e&&null!=this.labelExpression&&I(i))e=new y.A({expression:this.getLabelExpressionArcade()});else if(!e)return;let s=e.toJSON(i);s.expression&&(t[r]=s)}writeMaxScale(e,t){(e||this.minScale)&&(t.maxScale=e)}writeMinScale(e,t){(e||this.maxScale)&&(t.minScale=e)}get repeatLabelDistance(){return this._get("repeatLabelDistance")}set repeatLabelDistance(e){this._set("repeatLabelDistance",e)}getLabelExpression(){return(0,c.XJ)(this)}getLabelExpressionArcade(){return(0,c.BI)(this)}getLabelExpressionSingleField(){return(0,c.rU)(this)}hash(){return JSON.stringify(this)}clone(){return new s({allowOverrun:this.allowOverrun,deconflictionStrategy:this.deconflictionStrategy,labelExpression:this.labelExpression,labelExpressionInfo:(0,n.o8)(this.labelExpressionInfo),labelPosition:this.labelPosition,labelPlacement:this.labelPlacement,offsetDistance:this.offsetDistance,maxScale:this.maxScale,minScale:this.minScale,name:this.name,repeatLabel:this.repeatLabel,repeatLabelDistance:this.repeatLabelDistance,symbol:(0,n.o8)(this.symbol),where:this.where,useCodedValues:this.useCodedValues})}};(0,o.Cg)([(0,p.MZ)({type:String,json:{write:!0}})],C.prototype,"name",void 0),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:!0,default:!1,origins:{"web-scene":{write:!1},"portal-item":{default:!1,write:{overridePolicy:S}}}}})],C.prototype,"allowOverrun",void 0),(0,o.Cg)([(0,p.MZ)({type:String,json:{write:!0,default:"static",origins:{"web-scene":{write:!1},"portal-item":{default:"static",write:{overridePolicy:S}}}}})],C.prototype,"deconflictionStrategy",void 0),(0,o.Cg)([(0,p.MZ)({type:String,json:{write:{overridePolicy(e,t,r){return this.labelExpressionInfo&&"service"===r?.origin&&x(r.layer)?{enabled:!1}:{allowNull:!0}}}}})],C.prototype,"labelExpression",void 0),(0,o.Cg)([(0,b.w)("labelExpression")],C.prototype,"readLabelExpression",null),(0,o.Cg)([(0,v.K)("labelExpression")],C.prototype,"writeLabelExpression",null),(0,o.Cg)([(0,p.MZ)({type:y.A,json:{write:{overridePolicy:(e,t,r)=>function(e){return I(e)||x(e?.layer)}(r)?{allowNull:!0}:{enabled:!1}}}})],C.prototype,"labelExpressionInfo",void 0),(0,o.Cg)([(0,v.K)("labelExpressionInfo")],C.prototype,"writeLabelExpressionInfo",null),(0,o.Cg)([(0,p.MZ)({type:w.apiValues,json:{type:w.jsonValues,read:w.read,write:w.write}})],C.prototype,"labelPlacement",void 0),(0,o.Cg)([(0,p.MZ)({type:Number,json:{read:!0,write:!0,default:0,origins:{"web-scene":{write:!1}}}})],C.prototype,"offsetDistance",void 0),(0,o.Cg)([(0,p.MZ)({type:["curved","parallel"],json:{write:!0,origins:{"web-map":{write:!1},"web-scene":{write:!1},"portal-item":{write:!1}}}})],C.prototype,"labelPosition",void 0),(0,o.Cg)([(0,p.MZ)({type:Number})],C.prototype,"maxScale",void 0),(0,o.Cg)([(0,v.K)("maxScale")],C.prototype,"writeMaxScale",null),(0,o.Cg)([(0,p.MZ)({type:Number})],C.prototype,"minScale",void 0),(0,o.Cg)([(0,v.K)("minScale")],C.prototype,"writeMinScale",null),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:!0,origins:{"web-scene":{write:!1},"portal-item":{write:{overridePolicy:S}}}}})],C.prototype,"repeatLabel",void 0),(0,o.Cg)([(0,p.MZ)({type:Number,cast:u.cr,json:{write:!0,origins:{"web-scene":{write:!1},"portal-item":{write:{overridePolicy:S}}}}})],C.prototype,"repeatLabelDistance",null),(0,o.Cg)([(0,p.MZ)({types:m.em,json:{types:m.em,origins:{"portal-item":{types:m.em,read:{reader:(0,d.C)({types:m.em})},default:null},"web-scene":{types:m.Rv,read:{reader:(0,d.C)({types:m.Rv})},write:g.oO,default:null}},write:g.oO,default:null}})],C.prototype,"symbol",void 0),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:!0}})],C.prototype,"useCodedValues",void 0),(0,o.Cg)([(0,p.MZ)({type:String,json:{write:!0}})],C.prototype,"where",void 0),C=s=(0,o.Cg)([(0,p.$K)("esri.layers.support.LabelClass")],C)},73913(e,t,r){r.d(t,{A:()=>p});var i,s=r(32198),o=r(25482),a=r(91429),l=r(32730),n=r(36005),u=r(43937);let p=class extends o.o{static{i=this}constructor(e){super(e),this.name=null,this.expression=null,this.title=null,this.value=null}readExpression(e,t){return t.value?(0,l.mX)(t.value):e}writeExpression(e,t,r){null!=this.value&&(e=(0,l.mX)(this.value)),null!=e&&(t[r]=e)}clone(){return new i({name:this.name,expression:this.expression,title:this.title,value:this.value})}};(0,s.Cg)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{write:!1}}}})],p.prototype,"name",void 0),(0,s.Cg)([(0,a.MZ)({type:String,json:{write:{writerEnsuresNonNull:!0}}})],p.prototype,"expression",void 0),(0,s.Cg)([(0,n.w)("expression",["expression","value"])],p.prototype,"readExpression",null),(0,s.Cg)([(0,u.K)("expression")],p.prototype,"writeExpression",null),(0,s.Cg)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{write:!1}}}})],p.prototype,"title",void 0),(0,s.Cg)([(0,a.MZ)({json:{read:!1,write:!1}})],p.prototype,"value",void 0),p=i=(0,s.Cg)([(0,a.$K)("esri.layers.support.LabelExpressionInfo")],p)},37352(e,t,r){r.d(t,{A:()=>n});var i,s=r(32198),o=r(7762),a=r(25482),l=r(91429);let n=i=class extends a.o{constructor(e){super(e),this.floorField=null,this.viewAllMode=!1,this.viewAllLevelIds=new o.A}clone(){return new i({floorField:this.floorField,viewAllMode:this.viewAllMode,viewAllLevelIds:this.viewAllLevelIds})}};(0,s.Cg)([(0,l.MZ)({type:String,json:{write:{isRequired:!0}}})],n.prototype,"floorField",void 0),(0,s.Cg)([(0,l.MZ)({json:{read:!1,write:!1}})],n.prototype,"viewAllMode",void 0),(0,s.Cg)([(0,l.MZ)({json:{read:!1,write:!1}})],n.prototype,"viewAllLevelIds",void 0),n=i=(0,s.Cg)([(0,l.$K)("esri.layers.support.LayerFloorInfo")],n)},91880(e,t,r){r.d(t,{A:()=>u});var i,s=r(32198),o=r(66552),a=r(25482),l=r(91429);const n=new o.J({asc:"ascending",desc:"descending"});let u=class extends a.o{static{i=this}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.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],u.prototype,"field",void 0),(0,s.Cg)([(0,l.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],u.prototype,"valueExpression",void 0),(0,s.Cg)([(0,l.MZ)({type:n.apiValues,json:{type:n.jsonValues,read:n.read,write:n.write}})],u.prototype,"order",void 0),u=i=(0,s.Cg)([(0,l.$K)("esri.layers.support.OrderByInfo")],u)},45067(e,t,r){r.d(t,{A:()=>p});var i=r(32198),s=r(69540),o=r(66552),a=r(25482),l=r(91429);const n=new o.J({esriRelCardinalityOneToOne:"one-to-one",esriRelCardinalityOneToMany:"one-to-many",esriRelCardinalityManyToMany:"many-to-many"}),u=new o.J({esriRelRoleOrigin:"origin",esriRelRoleDestination:"destination"});let p=class extends((0,s.OU)(a.o)){constructor(e){super(e),this.cardinality=null,this.catalogId=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,i.Cg)([(0,l.MZ)({json:{read:n.read,write:n.write}})],p.prototype,"cardinality",void 0),(0,i.Cg)([(0,l.MZ)({json:{name:"catalogID"}})],p.prototype,"catalogId",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:!0,write:!0}})],p.prototype,"composite",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:!0,write:!0}})],p.prototype,"id",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:!0,write:!0}})],p.prototype,"keyField",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:!0,write:!0}})],p.prototype,"keyFieldInRelationshipTable",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:!0,write:!0}})],p.prototype,"name",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:!0,write:!0}})],p.prototype,"relatedTableId",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:!0,write:!0}})],p.prototype,"relationshipTableId",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:u.read,write:u.write}})],p.prototype,"role",void 0),p=(0,i.Cg)([(0,l.$K)("esri.layers.support.Relationship")],p)},15775(e,t,r){r.d(t,{A:()=>ge});var i=r(32198),s=r(40124),o=r(56507),a=r(7762),l=r(49186),n=r(44208),u=r(4902),p=r(4718),d=r(92474),y=r(53966),c=r(25728),h=r(39516),f=r(84952),g=r(91429),m=r(78888),b=r(35666),v=r(88620),w=r(5443),S=r(16930),I=r(83960),x=r(50498),C=r(41910),A=r(60950),M=r(89808),_=r(99959);const F=Symbol("isMapImageGraphicOriginSymbol");var P;class O extends _.A{get[(P=F,A.ym)](){return this.sublayer}get[M.Q](){return this.layer}get[C.e7](){return this.sublayer}constructor(e,t){super(),this[P]=!0,this.type="map-image",this.layer=e,this.sublayer=t}get id(){return`${this.layer.id}:__${this.sublayer.id}__`}}const L=Symbol("isTileGraphicOriginSymbol");var T;class Z extends _.A{get[(T=L,A.ym)](){return this.sublayer}get[M.Q](){return this.layer}get[C.e7](){return this.sublayer}constructor(e,t){super(),this[T]=!0,this.type="tile",this.layer=e,this.sublayer=t}get id(){return`${this.layer.id}:__${this.sublayer.id}__`}}var D,j=r(64314),E=r(32756),q=r(28032),V=r(15426),R=r(33143),N=r(20437),B=r(95466),k=r(30524),z=r(46499),$=r(39383),K=r(37352),J=r(91880),Q=r(45067),U=r(6666),G=r(41214),X=r(2272),Y=r(65615),W=r(93849),H=r(29308),ee=r(54546),te=r(97552),re=r(30291),ie=r(33910),se=r(43440),oe=r(36005),ae=r(43937);function le(e){return"esriSMS"===e?.type}function ne(e,t,r){let i=r.minimumWritableOrigin||r.origin;return!!i&&e.originIdOf(t)>=(0,b.aB)(i)}function ue(e,t,r){let i=ne(this,t,r);return{ignoreOrigin:!0,allowNull:i,enabled:!!r&&"map-image"===r.layer?.type&&(r.writeSublayerStructure||i)}}function pe(e,t,r){return{enabled:!!r&&"tile"===r.layer?.type&&(ne(this,t,r)||this._isOverridden(t))}}function de(e,t,r){return{ignoreOrigin:!0,enabled:r&&r.writeSublayerStructure||!1}}function ye(e,t,r){return{ignoreOrigin:!0,enabled:!!r?.writeSublayerStructure&&this.originIdOf(t)>2}}function ce(e,t,r){return{ignoreOrigin:!0,enabled:!!r&&(r.writeSublayerStructure||ne(this,t,r))}}let he=0;const fe=new Set(["layer","parent","loaded","loadStatus","loadError","loadWarnings"]);let ge=class extends((0,c.M)((0,u.s)(d.x_))){static{D=this}constructor(e){super(e),this.attributeTableTemplate=null,this.capabilities=void 0,this.editFieldsInfo=null,this.maxScaleRange={minScale:0,maxScale:0},this.fields=null,this.fullExtent=null,this.geometryType=null,this.globalIdField=null,this.isTable=!1,this.legendEnabled=!0,this.objectIdField=null,this.parent=null,this.popupEnabled=!0,this.popupTemplate=null,this.relationships=null,this.sourceJSON=null,this.spatialReference=null,this.title=null,this.typeIdField=null,this.type="sublayer",this.types=null,this.uniqueIdFields=null,this._lastParsedUrl=null}async load(e){return this.addResolvingPromise(this.reload(e)),this}readCapabilities(e,t){t=t.layerDefinition||t;let{attachment:r,operations:{supportsQuery:i,supportsQueryAttachments:s},query:{supportsFormatPBF:o,supportsOrderBy:a,supportsPagination:l,relativeTimeBinWindow:n},data:{supportsAttachment:u},queryRelated:p}=(0,U.S$)(t,this.url);return{attachment:{supportsOrderByFields:r?.supportsOrderByFields??!1,supportsResize:r?.supportsResize??!1,supportsTypeWildcard:r?.supportsTypeWildcard??!1},exportMap:{supportsModification:!!t.canModifyLayer},operations:{supportsQuery:i,supportsQueryAttachments:s},data:{supportsAttachment:u},query:{relativeTimeBinWindow:n,supportsFormatPBF:o,supportsOrderBy:a,supportsPagination:l},queryRelated:p}}get defaultPopupTemplate(){return this.createPopupTemplate()}set definitionExpression(e){this._setAndNotifyLayer("definitionExpression",e)}get effectiveScaleRange(){let e=this._get("effectiveScaleRange"),{maxScale:t,minScale:r,parent:i}=this,s={minScale:r,maxScale:t};return void 0!==i?.effectiveScaleRange&&(0,I.RH)(s,i.effectiveScaleRange),e&&e.minScale===s.minScale&&e.maxScale===s.maxScale?e:s}get effectiveUniqueIdFields(){return this.uniqueIdFields?[...this.uniqueIdFields]:this.objectIdField?[this.objectIdField]:[]}get effectiveVisible(){return this.visible&&(this.parent?.effectiveVisible??!0)}readMaxScaleRange(e,t){return{minScale:(t=t.layerDefinition||t).minScale??0,maxScale:t.maxScale??0}}get fieldsIndex(){return new B.A(this.fields||[])}set floorInfo(e){this._setAndNotifyLayer("floorInfo",e)}readGlobalIdFieldFromService(e,t){if((t=t.layerDefinition||t).globalIdField)return t.globalIdField;if(t.fields)for(let e of t.fields)if("esriFieldTypeGlobalID"===e.type)return e.name}get graphicOrigin(){if(!this.layer)return null;switch(this.layer.type){case"tile":return new Z(this.layer,this);case"map-image":return new O(this.layer,this)}}get id(){return this._get("id")??he++}set id(e){this._get("id")!==e&&(!1===this.layer?.capabilities?.exportMap?.supportsDynamicLayers?this._logLockedError("id","capability not available 'layer.capabilities.exportMap.supportsDynamicLayers'"):this._set("id",e))}readIsTable(e,t){return"Table"===t.type}set labelingInfo(e){this._setAndNotifyLayer("labelingInfo",e)}writeLabelingInfo(e,t,r,i){e&&e.length&&(t.layerDefinition={drawingInfo:{labelingInfo:e.map(e=>e.write({},i))}})}set labelsVisible(e){this._setAndNotifyLayer("labelsVisible",e)}set layer(e){this._set("layer",e),this.sublayers?.forEach(t=>t.layer=e)}set listMode(e){this._set("listMode",e)}get loaded(){return super.loaded}set minScale(e){this._setAndNotifyLayer("minScale",e)}readMinScale(e,t){return t.minScale||t.layerDefinition?.minScale||0}set maxScale(e){this._setAndNotifyLayer("maxScale",e)}readMaxScale(e,t){return t.maxScale||t.layerDefinition?.maxScale||0}readObjectIdFieldFromService(e,t){return(t=t.layerDefinition||t).objectIdField?t.objectIdField:t.fields?.find(e=>"esriFieldTypeOID"===e.type)?.name}set opacity(e){this._setAndNotifyLayer("opacity",e)}readOpacity(e,t){let{layerDefinition:r}=t;return 1-.01*(r?.transparency??r?.drawingInfo?.transparency??0)}writeOpacity(e,t,r,i){t.layerDefinition={drawingInfo:{transparency:100-100*e}}}set orderBy(e){this._setAndNotifyLayer("orderBy",e)}writeParent(e,t){t.parentLayerId=this.parent&&this.parent!==this.layer?(0,m.Vr)(this.parent.id):-1}get queryTask(){if(!this.layer)return null;let{capabilities:e,fieldsIndex:t,layer:r,uniqueIdFields:i,url:s}=this,{spatialReference:o}=r,a="gdbVersion"in r?r.gdbVersion:void 0,l=(0,n.A)("featurelayer-pbf")&&e?.query.supportsFormatPBF,u=e?.operations?.supportsQueryAttachments??!1,p=e?.query?.relativeTimeBinWindow??0;return new j.A({fieldsIndex:t,gdbVersion:a,pbfSupported:l,queryAttachmentsSupported:u,relativeTimeBinWindow:p,sourceSpatialReference:o,uniqueIdFields:i,url:s})}set renderer(e){if((0,k.yp)(e,this.fieldsIndex),e)for(let t of e.symbols)if((0,ie.wk)(t)){y.A.getLogger(this).warn("Sublayer renderer should use 2D symbols");break}this._setAndNotifyLayer("renderer",e)}get source(){return this._get("source")||new W.A({mapLayerId:this.id})}set source(e){this._setAndNotifyLayer("source",e)}get sublayers(){return this._get("sublayers")}set sublayers(e){this._handleSublayersChange(e,this._get("sublayers")),this._set("sublayers",e)}castSublayers(e){return(0,m.dp)(a.A.ofType(D),e)}writeSublayers(e,t,r){this.sublayers?.length&&(t[r]=this.sublayers.map(e=>e.id).toArray().reverse())}readTitle(e,t){return t.layerDefinition?.name??t.name}readTypeIdField(e,t){let r=(t=t.layerDefinition||t).typeIdField;if(r&&t.fields){r=r.toLowerCase();let e=t.fields.find(e=>e.name.toLowerCase()===r);e&&(r=e.name)}return r}readUniqueIdFields(e,t){return t.layerDefinition?.uniqueIdInfo?.OIDFieldContainsHashValue?t.layerDefinition.uniqueIdInfo.fields:null}get url(){let e=this.layer?.parsedUrl??this._lastParsedUrl,t=this.source;if(!e)return null;if(this._lastParsedUrl=e,"map-layer"===t?.type)return`${e.path}/${t.mapLayerId}`;let r={layer:JSON.stringify({source:this.source})};return`${e.path}/dynamicLayer?${(0,f.x0)(r)}`}set url(e){this._overrideIfSome("url",e)}set visible(e){this._setAndNotifyLayer("visible",e)}writeVisible(e,t,r,i){t[r]=this.getAtOrigin("defaultVisibility","service")||e}clone(){let{store:e}=(0,v.oY)(this),t=new D;return(0,v.oY)(t).store=e.clone(fe),this.commitProperty("url"),t._lastParsedUrl=this._lastParsedUrl,t}createPopupTemplate(e){return(0,re.tn)(this,e)}createQuery(){return new te.A({returnGeometry:!0,where:this.definitionExpression||"1=1"})}async createFeatureLayer(){if(this.sublayers)return null;let e,t=(await Promise.all([r.e(6361),r.e(9953),r.e(6263),r.e(8247),r.e(5087),r.e(8589),r.e(1560)]).then(()=>r(18589))).default,{layer:i,url:s}=this;if(s&&this.originIdOf("url")>2)e=new t({url:s});else{if(!i?.parsedUrl)throw new l.A("createFeatureLayer:missing-information","Cannot create a FeatureLayer without a url or a parent layer");{let r=i.parsedUrl;e=new t({url:r.path}),r&&this.source&&("map-layer"===this.source.type?e.layerId=this.source.mapLayerId:e.dynamicDataSource=this.source)}}return null!=i?.refreshInterval&&(e.refreshInterval=i.refreshInterval),this.definitionExpression&&(e.definitionExpression=this.definitionExpression),this.floorInfo&&(e.floorInfo=(0,p.o8)(this.floorInfo)),this.originIdOf("labelingInfo")>2&&(e.labelingInfo=(0,p.o8)(this.labelingInfo)),this.originIdOf("labelsVisible")>0&&(e.labelsVisible=this.labelsVisible),this.originIdOf("legendEnabled")>0&&(e.legendEnabled=this.legendEnabled),this.originIdOf("visible")>0&&(e.visible=this.visible),this.originIdOf("minScale")>0&&(e.minScale=this.minScale),this.originIdOf("maxScale")>0&&(e.maxScale=this.maxScale),this.originIdOf("opacity")>0&&(e.opacity=this.opacity),this.originIdOf("popupTemplate")>0&&(e.popupTemplate=(0,p.o8)(this.popupTemplate)),this.originIdOf("renderer")>2&&(e.renderer=(0,p.o8)(this.renderer)),"data-layer"===this.source?.type&&(e.dynamicDataSource=this.source.clone()),this.originIdOf("title")>0&&(e.title=this.title),"map-image"===i?.type&&i.originIdOf("customParameters")>0&&(e.customParameters=i.customParameters),"tile"===i?.type&&i.originIdOf("customParameters")>0&&(e.customParameters=i.customParameters),e}getField(e){return this.fieldsIndex.get(e)}getFeatureType(e){return(0,V.xd)(this.types,this.typeIdField,e)}getFieldDomain(e,t){let r=t?.feature,i=this.getFeatureType(r);if(i){let t=i.domains&&i.domains[e];if(t&&"inherited"!==t.type)return t}return this._getLayerDomain(e)}async queryAttachments(e,t){await this.load();let r=ee.A.from(e),i=this.capabilities;if(!i?.data?.supportsAttachment)throw new l.A("queryAttachments:not-supported","this layer doesn't support attachments");let{attachmentTypes:s,objectIds:o,globalIds:a,num:n,size:u,start:p,where:d}=r;if(!i?.operations?.supportsQueryAttachments&&(s?.length>0||a?.length>0||u?.length>0||n||p||d))throw new l.A("queryAttachments:option-not-supported","when 'capabilities.operations.supportsQueryAttachments' is false, only objectIds is supported",r);if(!(o?.length||a?.length||d))throw new l.A("queryAttachments:invalid-query","'objectIds', 'globalIds', or 'where' are required to perform attachment query",r);return!i?.attachment?.supportsOrderByFields&&r.orderByFields?.length&&(r=r.clone(),r.orderByFields=null),this.queryTask.executeAttachmentQuery(r,t)}async queryFeatureCount(e=this.createQuery(),t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new l.A("queryFeatureCount:not-supported","this layer doesn't support queries.");if(!this.url)throw new l.A("queryFeatureCount:not-supported","this layer has no url.");let r=this.layer?.apiKey;return await this.queryTask.executeForCount(e,{...t,query:{...this.layer?.customParameters,token:r}})}async queryFeatures(e=this.createQuery(),t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new l.A("queryFeatures:not-supported","this layer doesn't support queries.");if(!this.url)throw new l.A("queryFeatures:not-supported","this layer has no url.");let r=await this.queryTask.execute(e,{...t,query:{...this.layer?.customParameters,token:this.layer?.apiKey}});if(r?.features){let e=this.graphicOrigin;for(let t of r.features)t.sourceLayer=this,t.origin=e}return r}async queryObjectIds(e=this.createQuery(),t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new l.A("queryObjectIds:not-supported","this layer doesn't support queries.");if(!this.url)throw new l.A("queryObjectIds:not-supported","this layer has no url.");let r=this.layer?.apiKey;return await this.queryTask.executeForIds(e,{...t,query:{...this.layer?.customParameters,token:r}})}async queryRelatedFeatures(e,t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new l.A("queryRelatedFeatures:not-supported","this layer doesn't support queries.");if(!this.url)throw new l.A("queryRelatedFeatures:not-supported","this layer has no url.");let r=this.layer?.apiKey;return await this.queryTask.executeRelationshipQuery(e,{...t,query:{...this.layer?.customParameters,token:r}})}async queryRelatedFeaturesCount(e,t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new l.A("queryRelatedFeaturesCount:not-supported","this layer doesn't support queries.");if(!this.capabilities.queryRelated.supportsCount)throw new l.A("queryRelatedFeaturesCount:not-supported","this layer doesn't support query related counts.");if(!this.url)throw new l.A("queryRelatedFeaturesCount:not-supported","this layer has no url.");let r=this.layer?.apiKey;return await this.queryTask.executeRelationshipQueryForCount(e,{...t,query:{...this.layer?.customParameters,token:r}})}async reload(e){if("not-loaded"===this.loadStatus)return this.load(e).then(()=>{});let{layer:t,url:r}=this;if(!t&&!r)throw new l.A("sublayer:missing-layer","Sublayer can't be loaded without being part of a layer",{sublayer:this});let i=t?await t.fetchSublayerInfo(this,e):(await(0,o.A)(r,{query:{f:"json"},...e})).data;i&&(this.sourceJSON={...this.sourceJSON,...i},this.read({layerDefinition:i},{origin:"service",layer:t,url:(0,X.Dl)(r)}))}toExportImageJSON(e){let t={id:this.id,source:this.source?.toJSON()||{mapLayerId:this.id,type:"mapLayer"}},r=(0,h.mA)(e,this.definitionExpression);null!=r&&(t.definitionExpression=r);let i=["renderer","labelingInfo","opacity","labelsVisible"].reduce((e,t)=>(e[t]=this.originIdOf(t),e),{});if(Object.keys(i).some(e=>i[e]>2)){let e=t.drawingInfo={};if(i.renderer>2&&(e.renderer=this.renderer?this.renderer.toJSON():null),i.labelsVisible>2&&(e.showLabels=this.labelsVisible),this.labelsVisible&&i.labelingInfo>2)if(this.labelingInfo){!this.loaded&&this.labelingInfo?.some(e=>!e.labelPlacement)&&y.A.getLogger(this).warnOnce(`A Sublayer (title: ${this.title}, id: ${this.id}) has an undefined 'labelPlacement' and so labels cannot be displayed. Either define a valid 'labelPlacement' or call Sublayer.load() to use a default value based on geometry type.`,{sublayer:this});let t=this.labelingInfo;null!=this.geometryType&&(t=(0,$.z)(this.labelingInfo,x.gy.toJSON(this.geometryType))),e.showLabels=!0,e.labelingInfo=t.filter(e=>e.labelPlacement).map(e=>e.toJSON({origin:"service",layer:this.layer}))}else e.showLabels=!1;i.opacity>2&&(e.transparency=100-100*this.opacity),this._assignDefaultSymbolColors(e.renderer)}return(this.layer?.capabilities?.exportMap?.supportsSublayerOrderBy??!1)&&this.originIdOf("orderBy")>2&&(t.orderBy=this.orderBy?.map(e=>e.toJSON())??null),t}_assignDefaultSymbolColors(e){this._forEachSimpleMarkerSymbols(e,e=>{e.color||("esriSMSX"===e.style||"esriSMSCross"===e.style)&&(e.color=e.outline?.color?e.outline.color:[0,0,0,0])})}_forEachSimpleMarkerSymbols(e,t){if(e){let r=("uniqueValueInfos"in e?e.uniqueValueInfos:"classBreakInfos"in e?e.classBreakInfos:null)??[];for(let e of r)le(e.symbol)&&t(e.symbol);"symbol"in e&&le(e.symbol)&&t(e.symbol),"defaultSymbol"in e&&le(e.defaultSymbol)&&t(e.defaultSymbol)}}_setAndNotifyLayer(e,t){let r,i,s=this.layer,o=this._get(e);switch(e){case"definitionExpression":case"floorInfo":r="supportsSublayerDefinitionExpression";break;case"minScale":case"maxScale":case"visible":r="supportsSublayerVisibility";break;case"labelingInfo":case"labelsVisible":case"opacity":case"renderer":case"source":r="supportsDynamicLayers",i="supportsModification";break;case"orderBy":r="supportsSublayerOrderBy",i="supportsModification"}let a=(0,v.oY)(this).getDefaultOrigin();if("service"!==a){if(r&&!1===this.layer?.capabilities?.exportMap?.[r])return void this._logLockedError(e,`capability not available 'layer.capabilities.exportMap.${r}'`);if(i&&!1===this.capabilities?.exportMap[i])return void this._logLockedError(e,`capability not available 'capabilities.exportMap.${i}'`)}"source"===e&&"not-loaded"!==this.loadStatus?this._logLockedError(e,"'source' can't be changed after calling sublayer.load()"):(this._set(e,t),"service"!==a&&o!==t&&s?.emit&&s.emit("sublayer-update",{propertyName:e,target:this}))}_handleSublayersChange(e,t){t&&(t.forEach(e=>{e.parent=null,e.layer=null}),this.removeAllHandles()),e&&(e.forEach(e=>{e.parent=this,e.layer=this.layer}),this.addHandles([e.on("after-add",({item:e})=>{e.parent=this,e.layer=this.layer}),e.on("after-remove",({item:e})=>{e.parent=null,e.layer=null}),e.on("before-changes",e=>{(this.layer?.capabilities?.exportMap?.supportsSublayersChanges??!0)||(y.A.getLogger(this).error(new l.A("sublayer:sublayers-non-modifiable","Sublayer can't be added, moved, or removed from the layer's sublayers",{sublayer:this,layer:this.layer})),e.preventDefault())})]))}_logLockedError(e,t){let{layer:r,declaredClass:i}=this;y.A.getLogger(i).error(new l.A("sublayer:locked",`Property '${String(e)}' can't be changed on Sublayer from the layer '${r?.id}'`,{reason:t,sublayer:this,layer:r}))}_getLayerDomain(e){return this.fieldsIndex.get(e)?.domain??null}static{this.test={isMapImageLayerOverridePolicy:e=>e===ye||e===de||e===ue,isTileImageLayerOverridePolicy:e=>e===pe}}};(0,i.Cg)([(0,g.MZ)({type:se.A,json:{name:"attributeTableInfo",write:{overridePolicy:ue},origins:{"web-scene":{write:!1}}}})],ge.prototype,"attributeTableTemplate",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],ge.prototype,"capabilities",void 0),(0,i.Cg)([(0,oe.w)("service","capabilities",["layerDefinition.canModifyLayer","layerDefinition.capabilities"])],ge.prototype,"readCapabilities",null),(0,i.Cg)([(0,g.MZ)()],ge.prototype,"defaultPopupTemplate",null),(0,i.Cg)([(0,g.MZ)({type:String,value:null,json:{name:"layerDefinition.definitionExpression",write:{allowNull:!0,overridePolicy:ue}}})],ge.prototype,"definitionExpression",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0,type:q.A,json:{origins:{service:{read:{source:"layerDefinition.editFieldsInfo"}}}}})],ge.prototype,"editFieldsInfo",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],ge.prototype,"effectiveScaleRange",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0,type:[String]})],ge.prototype,"effectiveUniqueIdFields",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],ge.prototype,"effectiveVisible",null),(0,i.Cg)([(0,oe.w)("service","maxScaleRange",["minScale","maxScale"])],ge.prototype,"readMaxScaleRange",null),(0,i.Cg)([(0,g.MZ)({type:[N.A],json:{origins:{service:{read:{source:"layerDefinition.fields"}}}}})],ge.prototype,"fields",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],ge.prototype,"fieldsIndex",null),(0,i.Cg)([(0,g.MZ)({type:K.A,value:null,json:{name:"layerDefinition.floorInfo",read:{source:"layerDefinition.floorInfo"},write:{target:"layerDefinition.floorInfo",overridePolicy:ue},origins:{"web-scene":{read:!1,write:!1}}}})],ge.prototype,"floorInfo",null),(0,i.Cg)([(0,g.MZ)({type:w.A,json:{read:{source:"layerDefinition.extent"}}})],ge.prototype,"fullExtent",void 0),(0,i.Cg)([(0,g.MZ)({type:x.gy.apiValues,json:{origins:{service:{name:"layerDefinition.geometryType",read:{reader:x.gy.read}}}}})],ge.prototype,"geometryType",void 0),(0,i.Cg)([(0,g.MZ)({type:String})],ge.prototype,"globalIdField",void 0),(0,i.Cg)([(0,oe.w)("service","globalIdField",["layerDefinition.globalIdField","layerDefinition.fields"])],ge.prototype,"readGlobalIdFieldFromService",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],ge.prototype,"graphicOrigin",null),(0,i.Cg)([(0,g.MZ)({type:m.jz,json:{write:{ignoreOrigin:!0}}})],ge.prototype,"id",null),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],ge.prototype,"isTable",void 0),(0,i.Cg)([(0,oe.w)("service","isTable",["type"])],ge.prototype,"readIsTable",null),(0,i.Cg)([(0,g.MZ)({value:null,type:[z.A],json:{read:{source:"layerDefinition.drawingInfo.labelingInfo"},write:{target:"layerDefinition.drawingInfo.labelingInfo",overridePolicy:ye}}})],ge.prototype,"labelingInfo",null),(0,i.Cg)([(0,ae.K)("labelingInfo")],ge.prototype,"writeLabelingInfo",null),(0,i.Cg)([(0,g.MZ)({type:Boolean,value:!0,json:{read:{source:"layerDefinition.drawingInfo.showLabels"},write:{target:"layerDefinition.drawingInfo.showLabels",overridePolicy:de}}})],ge.prototype,"labelsVisible",null),(0,i.Cg)([(0,g.MZ)({value:null})],ge.prototype,"layer",null),(0,i.Cg)([(0,g.MZ)({type:String,json:{write:{overridePolicy:pe}}})],ge.prototype,"layerItemId",void 0),(0,i.Cg)([(0,g.MZ)({type:Boolean,value:!0,json:{origins:{service:{read:{enabled:!1}}},read:{source:"showLegend"},write:{target:"showLegend",overridePolicy:ce}}})],ge.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,g.MZ)({type:["show","hide","hide-children"],value:"show",json:{read:!1,write:!1,origins:{"web-scene":{read:!0,write:!0}}}})],ge.prototype,"listMode",null),(0,i.Cg)([(0,g.MZ)({type:Number,value:0,json:{write:{overridePolicy:de}}})],ge.prototype,"minScale",null),(0,i.Cg)([(0,oe.w)("minScale",["minScale","layerDefinition.minScale"])],ge.prototype,"readMinScale",null),(0,i.Cg)([(0,g.MZ)({type:Number,value:0,json:{write:{overridePolicy:de}}})],ge.prototype,"maxScale",null),(0,i.Cg)([(0,oe.w)("maxScale",["maxScale","layerDefinition.maxScale"])],ge.prototype,"readMaxScale",null),(0,i.Cg)([(0,g.MZ)()],ge.prototype,"objectIdField",void 0),(0,i.Cg)([(0,oe.w)("service","objectIdField",["layerDefinition.objectIdField","layerDefinition.fields"])],ge.prototype,"readObjectIdFieldFromService",null),(0,i.Cg)([(0,g.MZ)({type:Number,value:1,json:{write:{target:"layerDefinition.drawingInfo.transparency",overridePolicy:de}}})],ge.prototype,"opacity",null),(0,i.Cg)([(0,oe.w)("opacity",["layerDefinition.drawingInfo.transparency","layerDefinition.transparency"])],ge.prototype,"readOpacity",null),(0,i.Cg)([(0,ae.K)("opacity")],ge.prototype,"writeOpacity",null),(0,i.Cg)([(0,g.MZ)({value:null,type:[J.A],json:{name:"layerDefinition.orderBy",read:{reader:E.Rr},write:{overridePolicy:ue},origins:{"web-scene":{read:!1,write:!1}}}})],ge.prototype,"orderBy",null),(0,i.Cg)([(0,g.MZ)({json:{type:m.jz,write:{target:"parentLayerId",writerEnsuresNonNull:!0,overridePolicy:de}}})],ge.prototype,"parent",void 0),(0,i.Cg)([(0,ae.K)("parent")],ge.prototype,"writeParent",null),(0,i.Cg)([(0,g.MZ)({type:Boolean,value:!0,json:{read:{source:"disablePopup",reader:(e,t)=>!t.disablePopup},write:{target:"disablePopup",overridePolicy:ce,writer(e,t,r){t[r]=!e}}}})],ge.prototype,"popupEnabled",void 0),(0,i.Cg)([(0,g.MZ)({type:s.A,json:{read:{source:"popupInfo"},write:{target:"popupInfo",overridePolicy:ce}}})],ge.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,g.MZ)({readOnly:!0})],ge.prototype,"queryTask",null),(0,i.Cg)([(0,g.MZ)({type:[Q.A],readOnly:!0,json:{origins:{service:{read:{source:"layerDefinition.relationships"}}}}})],ge.prototype,"relationships",void 0),(0,i.Cg)([(0,g.MZ)({types:G.Hg,value:null,json:{name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:ye},origins:{"web-scene":{types:G.XJ,name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:ye}}}}})],ge.prototype,"renderer",null),(0,i.Cg)([(0,g.MZ)({types:{key:"type",base:null,typeMap:{"data-layer":Y.A,"map-layer":W.A,"workspace-layer":H.A}},cast(e){if(e){if("mapLayerId"in e)return(0,m.PZ)(W.A,e);if("dataSource"in e)return(0,m.PZ)(Y.A,e);if("workspaceId"in e&&"layerId"in e)return(0,m.PZ)(H.A,e)}return e},json:{name:"layerDefinition.source",types:{key:"type",base:null,typeMap:{"data-layer":Y.A,"map-layer":W.A}},write:{overridePolicy:de}}})],ge.prototype,"source",null),(0,i.Cg)([(0,g.MZ)()],ge.prototype,"sourceJSON",void 0),(0,i.Cg)([(0,g.MZ)({type:S.A,json:{origins:{service:{read:{source:"layerDefinition.extent.spatialReference"}}}}})],ge.prototype,"spatialReference",void 0),(0,i.Cg)([(0,g.MZ)({value:null,json:{type:[m.jz],write:{target:"subLayerIds",allowNull:!0,overridePolicy:de}}})],ge.prototype,"sublayers",null),(0,i.Cg)([(0,g.wg)("sublayers")],ge.prototype,"castSublayers",null),(0,i.Cg)([(0,ae.K)("sublayers")],ge.prototype,"writeSublayers",null),(0,i.Cg)([(0,g.MZ)({type:String,json:{name:"name",write:{overridePolicy:ce}}})],ge.prototype,"title",void 0),(0,i.Cg)([(0,oe.w)("service","title",["name","layerDefinition.name"])],ge.prototype,"readTitle",null),(0,i.Cg)([(0,g.MZ)({type:String})],ge.prototype,"typeIdField",void 0),(0,i.Cg)([(0,g.MZ)({json:{read:!1},readOnly:!0,value:"sublayer"})],ge.prototype,"type",void 0),(0,i.Cg)([(0,oe.w)("typeIdField",["layerDefinition.typeIdField"])],ge.prototype,"readTypeIdField",null),(0,i.Cg)([(0,g.MZ)({type:[R.A],json:{origins:{service:{read:{source:"layerDefinition.types"}}}}})],ge.prototype,"types",void 0),(0,i.Cg)([(0,g.MZ)({type:[String],readOnly:!0})],ge.prototype,"uniqueIdFields",void 0),(0,i.Cg)([(0,oe.w)("service","uniqueIdFields",["layerDefinition.uniqueIdInfo.OIDFieldContainsHashValue","layerDefinition.uniqueIdInfo.fields"])],ge.prototype,"readUniqueIdFields",null),(0,i.Cg)([(0,g.MZ)({type:String,json:{name:"layerUrl",write:{overridePolicy:pe}}})],ge.prototype,"url",null),(0,i.Cg)([(0,g.MZ)({type:Boolean,value:!0,json:{read:{source:"defaultVisibility"},write:{target:"defaultVisibility",overridePolicy:de}}})],ge.prototype,"visible",null),(0,i.Cg)([(0,ae.K)("visible")],ge.prototype,"writeVisible",null),ge=D=(0,i.Cg)([(0,g.$K)("esri.layers.support.Sublayer")],ge)},33446(e,t,r){r.d(t,{Cp:()=>a,mn:()=>o});var i=r(49186),s=r(17676);async function o(e,t,r){let o;try{o=await l(e,r)}catch(e){throw new i.A("request:server",`Unable to load ${t}`,{url:t,error:e})}return(0,s.Te)(r),o}async function a(e,t,r,o,a){let n;try{n=await l(e,a)}catch(e){throw new i.A("request:server",`Unable to load tile ${t}/${r}/${o}`,{error:e,level:t,row:r,col:o})}return(0,s.Te)(a),n}async function l(e,t){let r=await createImageBitmap(e,{imageOrientation:t?.imageOrientation??"none"}),i=t?.type??(e instanceof Blob?e.type.startsWith("image/")?e.type:t?.allowDeriveTypeFromData?await async function(e){return e.byteLength<2?"unknown":137===e[0]&&80===e[1]?"image/png":71===e[0]&&73===e[1]?"image/gif":66===e[0]&&77===e[1]?"image/bmp":255===e[0]&&216===e[1]?"image/jpeg":"unknown"}(await e.bytes()):void 0:void 0);return new n(r,i)}class n{constructor(e,t){this.bitmap=e,this.type=t}get isOpaque(){return"image/jpeg"===this.type}}},39383(e,t,r){r.d(t,{w:()=>n,z:()=>d});var i=r(49186),s=r(53966),o=r(46499);const a=()=>s.A.getLogger("esri.layers.support.labelingInfo"),l=/\[([^[\]]+)\]/gi;function n(e,t,r){return e?e.map(e=>{let i=new o.A;if(i.read(e,r),i.labelExpression){let e=t.fields||t.layerDefinition?.fields||this.fields;i.labelExpression=i.labelExpression.replaceAll(l,(t,r)=>`[${function(e,t){if(!t)return e;let r=e.toLowerCase();for(let e=0;e<t.length;e++){let i=t[e].name;if(i.toLowerCase()===r)return i}return e}(r,e)}]`)}return i}):null}const u=["above-right","above-center","above-left","center-center","center-left","center-right","below-center","below-left","below-right"],p={esriGeometryPoint:u,esriGeometryMultiPatch:["always-horizontal"],esriGeometryPolygon:["always-horizontal"],esriGeometryPolyline:["center-along","above-along","below-along"],esriGeometryMultipoint:u,esriGeometryEnvelope:null};function d(e,t){let r=[];for(let s of e){let e=s.labelPlacement,o=p[t];if(!s.symbol)return a().warn("No ILabelClass symbol specified."),[];if(!o)return a().error(new i.A("labeling:unsupported-geometry-type",`Unable to create labels for layer, geometry type '${t}' is not supported`)),[];if(o.includes(e))r.push(s);else{let i=o[0];e&&a().warn(`Found invalid label placement type ${e} for ${t}. Defaulting to ${i}`);let l=s.clone();l.labelPlacement=i,r.push(l)}}return r}},63389(e,t,r){function i(e,t,r){return!(t.flatten(({sublayers:e})=>e).length===e.length&&!e.some(e=>e.originIdOf("minScale")>r||e.originIdOf("maxScale")>r||e.originIdOf("renderer")>r||e.originIdOf("labelingInfo")>r||e.originIdOf("opacity")>r||e.originIdOf("labelsVisible")>r||e.originIdOf("source")>r)&&o(e,t))}function s(e,t,r){return!!e.some(e=>{let t=e.source,i=!t||"map-layer"===t.type&&t.mapLayerId===e.id&&(null==t.gdbVersion||t.gdbVersion===r);e.commitProperty("renderer"),e.commitProperty("labelingInfo"),e.commitProperty("opacity"),e.commitProperty("labelsVisible"),e.commitProperty("orderBy");let s=e.layer?.capabilities?.exportMap?.supportsSublayerOrderBy??!1;return!i||e.originIdOf("renderer")>2||e.originIdOf("labelingInfo")>2||e.originIdOf("opacity")>2||e.originIdOf("labelsVisible")>2||s&&e.originIdOf("orderBy")>2})||!o(e,t)}function o(e,t){if(!e?.length||null==t)return!0;let r=t.slice().reverse().flatten(({sublayers:e})=>e&&e.toArray().reverse()).map(e=>e.id).toArray();if(e.length>r.length)return!1;let i=0,s=r.length;for(let{id:t}of e){for(;i<s&&r[i]!==t;)i++;if(i>=s)return!1}return!0}function a(e){return!!e&&e.some(e=>null!=e.minScale||null!=e.layerDefinition?.minScale)}r.d(t,{Sk:()=>s,Zx:()=>i,_X:()=>a})},73681(e,t,r){r.d(t,{n:()=>n});var i=r(49186),s=r(53966),o=r(46140),a=r(95466),l=r(55674);class n{static async from(e,t,r){let a=e.dictionary_version?o.A.parse(e.dictionary_version):null,p=new Set(e.itemsNames),d={};if(t)for(let e in t)d[e]=t[e];if(e.authoringInfo.configuration)for(let t of e.authoringInfo.configuration)d.hasOwnProperty(t.name)||(d[t.name]=t.value);let y=new Set(e.authoringInfo.symbol);for(let e of Object.keys(r))y.delete(e);y.size&&s.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:y});let c=await(0,l.xR)(e.expression,null,d);if(!c)throw new i.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");let h=!a||!a.greaterEqual(4,0);h&&s.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:a});let f=new u(r,h);return new n(h,p,c,f)}constructor(e,t,r,i){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=i}get itemNames(){return this._itemNames}evaluate(e,t,r,i){try{return this._reader.bind(e,r,i),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){s.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new a.A(e);let t=e.map(e=>({...e,type:"esriFieldTypeString"}));return new a.A(t)}}class u extends l.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){let t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);let t=this._getField(e);return null==t||null==this._boundTarget.attributes[t.name]?"":""+this._boundTarget.attributes[t.name]}}},20615(e,t,r){r.d(t,{I:()=>a});var i=r(2272),s=r(80893),o=r(97552);function a(e,t,r,a){return(0,s.gW)((0,i.Dl)(e),o.A.from(t),r,a)}},74910(e,t,r){r.d(t,{L:()=>l});var i=r(5443),s=r(2272),o=r(80893),a=r(97552);async function l(e,t,r){let l=(0,s.Dl)(e),n=await(0,o.Jf)(l,a.A.from(t),{...r}),u=n.extent;return!u||isNaN(u.xmin)||isNaN(u.ymin)||isNaN(u.xmax)||isNaN(u.ymax)?{count:n.count,extent:null}:{count:n.count,extent:i.A.fromJSON(u)}}},78286(e,t,r){r.d(t,{V:()=>a});var i=r(2272),s=r(80893),o=r(97552);async function a(e,t,r,a){let l=(0,i.Dl)(e),n=await(0,s.Pk)(l,o.A.from(t),r,a);return n.objectIds??function(e){if(e)return function(e){return!Array.isArray(e[0])}(e)?e:e.map(e=>JSON.stringify(e))}(n.uniqueIds)??[]}},99199(e,t,r){r.d(t,{e:()=>n,s:()=>l});var i=r(2272),s=r(80893),o=r(22671),a=r(97552);async function l(e,t,r,i){let s=await n(e,t,r,i);return o.A.fromJSON(s)}function n(e,t,r,o){let l=(0,i.Dl)(e),n={...r},u=a.A.from(t);return(0,s.eW)(l,u,u.sourceSpatialReference,n,o)}},63746(e,t,r){function i(e){return class{constructor(){for(let t of e)this[t]=null}}}function s(e,t=1){let{transform:r,hasZ:i,hasM:s}=e;if(null==r)return i&&1!==t?e=>{e[2]*=t}:null;let[o,a]=function(e,t,r,i){let{scale:s,translate:o,originPosition:a}=e;return"upperLeft"===a&&(s=s.map((e,t)=>1===t?-e:e)),t&&(s=s.map((e,t)=>2===t?e*i:e),o=o.map((e,t)=>2===t?e*i:e)),!t&&r&&(s=s.filter((e,t)=>2!==t),o=o.filter((e,t)=>2!==t)),[s,o]}(r,i,s,t),l=e.hasZ?3:2;return e=>{for(let t=0;t<e.length&&(t!==l||0!==e[t]);++t)e[t]=e[t]*o[t]+a[t]}}r.d(t,{M:()=>s,_:()=>i})},41366(e,t,r){var i=r(32198),s=r(66552),o=r(53966),a=r(91429),l=r(93223);const n=(0,s.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),u="percent-of-total",p="field";r.d(t,["K",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.normalizationField=null,this.normalizationMaxValue=null,this.normalizationMinValue=null,this.normalizationTotal=null}get normalizationType(){let e=this._get("normalizationType"),t=!!this.normalizationField,r=null!=this.normalizationTotal;return t||r?(e=t&&p||r&&u||null,t&&r&&o.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):(e===p||e===u)&&(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,i.Cg)([(0,a.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],r.prototype,"normalizationField",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],r.prototype,"normalizationMaxValue",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],r.prototype,"normalizationMinValue",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],r.prototype,"normalizationTotal",void 0),(0,i.Cg)([(0,l.e)(n,{name:"parameters.normalizationType"})],r.prototype,"normalizationType",null),r=(0,i.Cg)([(0,a.$K)("esri.rest.support.NormalizationBinParametersMixin")],r),r},"Q",0,n])},93470(e,t,r){const i=[252,146,31,255],s={type:"esriSMS",style:"esriSMSCircle",size:6,color:i,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:i};r.d(t,["Cb",0,s,"HW",0,{type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},"JR",0,[153,153,153,255],"JZ",0,{type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},"WR",0,{type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},"b6",0,{type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null},"fT",0,i,"nC",0,{type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},"yM",0,o])}}]);
@@ -1,2 +0,0 @@
1
- /*! For license information please see 844eedda8f749972f707.js.LICENSE.txt */
2
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6198],{62414(t,n,e){e.d(n,{AO:()=>N,Kr:()=>b,nq:()=>S,tp:()=>R,yT:()=>s});var r=["input:not([inert]):not([inert] *)","select:not([inert]):not([inert] *)","textarea:not([inert]):not([inert] *)","a[href]:not([inert]):not([inert] *)","area[href]:not([inert]):not([inert] *)","button:not([inert]):not([inert] *)","[tabindex]:not(slot):not([inert]):not([inert] *)","audio[controls]:not([inert]):not([inert] *)","video[controls]:not([inert]):not([inert] *)",'[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)',"details>summary:first-of-type:not([inert]):not([inert] *)","details:not([inert]):not([inert] *)"],o=r.join(","),i="undefined"==typeof Element,a=i?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,u=!i&&Element.prototype.getRootNode?function(t){var n;return null==t||null===(n=t.getRootNode)||void 0===n?void 0:n.call(t)}:function(t){return null==t?void 0:t.ownerDocument},l=function(t,n){var e;void 0===n&&(n=!0);var r=null==t||null===(e=t.getAttribute)||void 0===e?void 0:e.call(t,"inert");return""===r||"true"===r||n&&t&&("function"==typeof t.closest?t.closest("[inert]"):l(t.parentNode))},c=function(t,n,e){if(l(t))return[];var r=Array.prototype.slice.apply(t.querySelectorAll(o));return n&&a.call(t,o)&&r.unshift(t),r.filter(e)},d=function(t,n,e){for(var r=[],i=Array.from(t);i.length;){var u=i.shift();if(!l(u,!1))if("SLOT"===u.tagName){var c=u.assignedElements(),f=c.length?c:u.children,s=d(f,!0,e);e.flatten?r.push.apply(r,s):r.push({scopeParent:u,candidates:s})}else{a.call(u,o)&&e.filter(u)&&(n||!t.includes(u))&&r.push(u);var p=u.shadowRoot||"function"==typeof e.getShadowRoot&&e.getShadowRoot(u),h=!l(p,!1)&&(!e.shadowRootFilter||e.shadowRootFilter(u));if(p&&h){var m=d(!0===p?u.children:p.children,!0,e);e.flatten?r.push.apply(r,m):r.push({scopeParent:u,candidates:m})}else i.unshift.apply(i,u.children)}}return r},f=function(t){return!isNaN(parseInt(t.getAttribute("tabindex"),10))},s=function(t){if(!t)throw new Error("No node provided");return t.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||function(t){var n,e=null==t||null===(n=t.getAttribute)||void 0===n?void 0:n.call(t,"contenteditable");return""===e||"true"===e}(t))&&!f(t)?0:t.tabIndex},p=function(t,n){return t.tabIndex===n.tabIndex?t.documentOrder-n.documentOrder:t.tabIndex-n.tabIndex},h=function(t){return"INPUT"===t.tagName},m=function(t){var n=t.getBoundingClientRect(),e=n.width,r=n.height;return 0===e&&0===r},y=function(t,n){return!(n.disabled||function(t){return h(t)&&"hidden"===t.type}(n)||function(t,n){var e=n.displayCheck,r=n.getShadowRoot;if("full-native"===e&&"checkVisibility"in t)return!t.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});var o=getComputedStyle(t).visibility;if("hidden"===o||"collapse"===o)return!0;var i=a.call(t,"details>summary:first-of-type")?t.parentElement:t;if(a.call(i,"details:not([open]) *"))return!0;if(e&&"full"!==e&&"full-native"!==e&&"legacy-full"!==e){if("non-zero-area"===e)return m(t)}else{if("function"==typeof r){for(var l=t;t;){var c=t.parentElement,d=u(t);if(c&&!c.shadowRoot&&!0===r(c))return m(t);t=t.assignedSlot?t.assignedSlot:c||d===t.ownerDocument?c:d.host}t=l}if(function(t){var n,e,r,o,i=t&&u(t),a=null===(n=i)||void 0===n?void 0:n.host,l=!1;if(i&&i!==t)for(l=!!(null!==(e=a)&&void 0!==e&&null!==(r=e.ownerDocument)&&void 0!==r&&r.contains(a)||null!=t&&null!==(o=t.ownerDocument)&&void 0!==o&&o.contains(t));!l&&a;){var c,d,f;l=!(null===(d=a=null===(c=i=u(a))||void 0===c?void 0:c.host)||void 0===d||null===(f=d.ownerDocument)||void 0===f||!f.contains(a))}return l}(t))return!t.getClientRects().length;if("legacy-full"!==e)return!0}return!1}(n,t)||function(t){return"DETAILS"===t.tagName&&Array.prototype.slice.apply(t.children).some(function(t){return"SUMMARY"===t.tagName})}(n)||function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var n=t.parentElement;n;){if("FIELDSET"===n.tagName&&n.disabled){for(var e=0;e<n.children.length;e++){var r=n.children.item(e);if("LEGEND"===r.tagName)return!!a.call(n,"fieldset[disabled] *")||!r.contains(t)}return!0}n=n.parentElement}return!1}(n))},v=function(t,n){return!(function(t){return function(t){return h(t)&&"radio"===t.type}(t)&&!function(t){if(!t.name)return!0;var n,e=t.form||u(t),r=function(t){return e.querySelectorAll('input[type="radio"][name="'+t+'"]')};if("undefined"!=typeof window&&void 0!==window.CSS&&"function"==typeof window.CSS.escape)n=r(window.CSS.escape(t.name));else try{n=r(t.name)}catch(t){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",t.message),!1}var o=function(t,n){for(var e=0;e<t.length;e++)if(t[e].checked&&t[e].form===n)return t[e]}(n,t.form);return!o||o===t}(t)}(n)||s(n)<0||!y(t,n))},g=function(t){var n=parseInt(t.getAttribute("tabindex"),10);return!!(isNaN(n)||n>=0)},w=function(t){var n=[],e=[];return t.forEach(function(t,r){var o=!!t.scopeParent,i=o?t.scopeParent:t,a=function(t,n){var e=s(t);return e<0&&n&&!f(t)?0:e}(i,o),u=o?w(t.candidates):i;0===a?o?n.push.apply(n,u):n.push(i):e.push({documentOrder:r,tabIndex:a,item:t,isScope:o,content:u})}),e.sort(p).reduce(function(t,n){return n.isScope?t.push.apply(t,n.content):t.push(n.content),t},[]).concat(n)},b=function(t,n){var e;return e=(n=n||{}).getShadowRoot?d([t],n.includeContainer,{filter:v.bind(null,n),flatten:!1,getShadowRoot:n.getShadowRoot,shadowRootFilter:g}):c(t,n.includeContainer,v.bind(null,n)),w(e)},S=function(t,n){return(n=n||{}).getShadowRoot?d([t],n.includeContainer,{filter:y.bind(null,n),flatten:!0,getShadowRoot:n.getShadowRoot}):c(t,n.includeContainer,y.bind(null,n))},N=function(t,n){if(n=n||{},!t)throw new Error("No node provided");return!1!==a.call(t,o)&&v(n,t)},E=r.concat("iframe:not([inert]):not([inert] *)").join(","),R=function(t,n){if(n=n||{},!t)throw new Error("No node provided");return!1!==a.call(t,E)&&y(n,t)}},56198(t,n,e){e.d(n,{a:()=>b,b:()=>w,c:()=>c,d:()=>v,f:()=>f,g:()=>i,h:()=>S,i:()=>E,l:()=>T,m:()=>a,o:()=>N,q:()=>l,r:()=>m,s:()=>g,u:()=>y,v:()=>h,w:()=>R,z:()=>d});var r=e(62414);const o={getShadowRoot:!0};function i(t){return t.getRootNode()}function a(t){const n=i(t);return"host"in n?n:null}function u(t){return t.host||null}function l(t,{selector:n,id:e}){if(!t)return null;t.assignedSlot&&(t=t.assignedSlot);const r=i(t),o=e?"getElementById"in r?r.getElementById(e):null:n?r.querySelector(n):null;if(o)return o;const a=u(r);return a?l(a,{selector:n,id:e}):null}function c(t,n){if(!t)return null;const e=t.closest(n);if(e)return e;const r=u(i(t));return r?c(r,n):null}function d(t){return"function"==typeof t?.setFocus}async function f(t,n=!1,e="tabbable",r,o){if(t)return d(t)&&r!==t?t.setFocus(o):("tabbable"===e?s:p)(t,n,o)}function s(t,n,e){(function(t,n){if(t)return(0,r.Kr)(t,{...o,includeContainer:n})[0]??t})(t,n)?.focus(e)}function p(t,n,e){(function(t,n){if(t)return(0,r.nq)(t,{...o,includeContainer:n})[0]??t})(t,n)?.focus(e)}function h(t,n,e){return"string"==typeof n&&""!==n?n:""===n||!0===n?t[e]:void 0}function m(t){return g(t)||v(t)}function y(t){for(const n of t.childNodes)if(n.nodeType===Node.TEXT_NODE&&""!==n.textContent?.trim()||n.nodeType===Node.ELEMENT_NODE)return!0;return!1}function v(t){return!!function(t){return function(t){return t.currentTarget.assignedNodes({flatten:!0})}(t).filter(t=>t.nodeType===Node.TEXT_NODE).map(t=>t.textContent).join("").trim()}(t)}function g(t){return!!w(t).length}function w(t,n){return b(t.currentTarget,n)}function b(t,n){const e=t.assignedElements({flatten:!0});return n?function(t,n){return t.filter(t=>t.matches(n))}(e,n):e}function S(t){return!(!t.isPrimary||0!==t.button)}function N(t){return 0===t.detail}function E(t,n){if(!t.parentNode||!n.parentNode||t.parentNode!==n.parentNode)return!1;const e=Array.from(t.parentNode.children);return e.indexOf(t)<e.indexOf(n)}async function R(t,n){return async function(t,n,e){let r=C(t,e,n);if(r||(await async function(){await new Promise(t=>requestAnimationFrame(()=>t()))}(),r=C(t,e,n)),r)try{await r.finished}catch{}}(t,n,"transition")}function C(t,n,e){return t.getAnimations().find(t=>"transition"===n?"transitionProperty"in t&&t.transitionProperty===e:"animationName"in t&&t.animationName===e)}function T(t){return t.endsWith("px")?parseFloat(t):t.endsWith("vw")?A(parseFloat(t),window.innerWidth):t.endsWith("vh")?A(parseFloat(t),window.innerHeight):0}function A(t,n){return t*n/100}e.d(n,["t",0,o])}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1904],{52106(e,t,r){r.d(t,{A:()=>M});var i,l,s=r(32198),n=r(40124),a=r(69540),o=r(51447),u=r(25482),p=r(53966),d=r(36708),h=r(24326),m=r(91429),y=r(12195),c=r(65864),g=r(50498),f=r(55156),b=r(60950),v=r(54339),w=r(94128),C=r(33910);const I=Symbol("meshGeometryHandles");function x(e){if(null==e)return null;let t={};for(let r in e){let i=e[r];i&&(t[r]=i.toJSON())}return 0===Object.keys(t).length?null:t}let M=class extends((0,a.OU)(u.o)){static{i=w.Z}static{l=this}constructor(e){super(e),this[i]=!0,this.distance=null,this.isAggregate=!1,this.layer=null,this.origin=null,this.sourceLayer=null,this.statisticsAggregatedIds=void 0,this._version=0,Object.defineProperty(this,"uid",{value:(0,h.c)(),configurable:!0}),Object.defineProperty(this,"_lastMeshTransform",{value:{},configurable:!0,writable:!0,enumerable:!1}),arguments.length>1&&(0,o.eF)(p.A.getLogger(this),"Graphic",{version:"4.30"})}set aggregateGeometries(e){let t=this._get("aggregateGeometries");JSON.stringify(t)!==JSON.stringify(e)&&this._set("aggregateGeometries",e)}set attributes(e){let t=this._get("attributes");t!==e&&(this._set("attributes",e),this._notifyLayer("attributes",t,e))}set geometry(e){let t=this._get("geometry");t!==e&&(this._set("geometry",e),this._watchMeshGeometryChanges(),this._notifyLayer("geometry",t,e))}set popupTemplate(e){let t=this._get("popupTemplate");t!==e&&(this._set("popupTemplate",e),this._notifyLayer("popupTemplate",t,e))}set symbol(e){let t=this._get("symbol");t!==e&&(this._set("symbol",e),this._notifyLayer("symbol",t,e))}get version(){return this._version}set visible(e){let t=this._get("visible");t!==e&&(this._set("visible",e),this._notifyLayer("visible",t,e))}cloneShallow(){return new l({aggregateGeometries:this.aggregateGeometries,statisticsAggregatedIds:this.statisticsAggregatedIds,attributes:this.attributes,geometry:this.geometry,isAggregate:this.isAggregate,layer:this.layer,popupTemplate:this.popupTemplate,sourceLayer:this.sourceLayer,symbol:this.symbol,visible:this.visible,origin:this.origin})}getEffectivePopupTemplate(e=!1){if(this.popupTemplate)return this.popupTemplate;let t=(0,b.E_)(this.origin);if(t)return t.popupTemplate??(e?t.defaultPopupTemplate:null)??null;let r=this.origin&&"layer"in this.origin?this.origin.layer:null;for(let t of[r,this.sourceLayer,this.layer])if(t&&"object"==typeof t){if("popupTemplate"in t&&t.popupTemplate)return t.popupTemplate;if(e&&"defaultPopupTemplate"in t&&null!=t.defaultPopupTemplate)return t.defaultPopupTemplate}return null}getAttribute(e){return this.attributes?.[e]}setAttribute(e,t){if(this.attributes){let r=this.getAttribute(e);this.attributes[e]=t,this._notifyLayer("attributes",r,t,e)}else this.attributes={[e]:t}}getObjectId(){let e=(0,f.I)(this.origin);if(e)return(0,v.r)(this,e);let t=this.sourceLayer??this.layer;return t?(0,v.r)(this,t):null}getGlobalId(){let e=(0,f.I)(this.origin);if(e?.globalIdField)return this.getAttribute(e.globalIdField);let t=this.sourceLayer??this.layer;return t&&"globalIdField"in t&&t.globalIdField?this.getAttribute(t.globalIdField):null}toJSON(){let e={aggregateGeometries:x(this.aggregateGeometries),geometry:this.geometry?.toJSON()??null,symbol:this.symbol?.toJSON()??null,attributes:(0,y.W)(this.attributes)?this.attributes.toJSON():{...this.attributes},popupTemplate:this.popupTemplate?.toJSON()??null};return this.statisticsAggregatedIds?.length&&(e.aggregateIds=[...this.statisticsAggregatedIds]),null!=this.distance&&(e.distance=this.distance),e}notifyMeshTransformChanged(e={}){let{geometry:t}=this;if("mesh"===t?.type){let r={origin:t.origin,transform:t.transform};this._notifyLayer("origin-transform",r,r,e.action)}}_notifyLayer(e,t,r,i){if(this._version++,!this.layer||!("graphicChanged"in this.layer))return;let l={graphic:this,property:e,oldValue:t,newValue:r};"origin-transform"===e&&(l.action=i),"attributes"===e&&(l.attributeName=i),this.layer.graphicChanged(l)}_watchMeshGeometryChanges(){this.removeHandles(I);let e=this.geometry;"mesh"===e?.type&&this.addHandles([(0,d.z7)(()=>e.vertexSpace.origin?{localMatrix:e.transform?.localMatrix,origin:e.vertexSpace.origin}:void 0,({localMatrix:e,origin:t})=>{(this._lastMeshTransform.localMatrix!==e||this._lastMeshTransform.origin!==t)&&(this._lastMeshTransform.localMatrix=e,this._lastMeshTransform.origin=t,this.notifyMeshTransformChanged())}),(0,d.z7)(()=>({vertexAttributes:e.vertexAttributes}),()=>{e.vertexSpace.origin?(this._lastMeshTransform.localMatrix=e.transform?.localMatrix,this._lastMeshTransform.origin=e.vertexSpace.origin):(this._lastMeshTransform.localMatrix=void 0,this._lastMeshTransform.origin=void 0),this._notifyLayer("geometry",e,e)},{equals:(e,t)=>e===t,sync:!0})],I)}};(0,s.Cg)([(0,m.MZ)({value:null,json:{read:function(e){if(!e)return null;let t={};for(let r in e){let i=(0,c.rS)(e[r]);i&&(t[r]=i)}return 0===Object.keys(t).length?null:t}}})],M.prototype,"aggregateGeometries",null),(0,s.Cg)([(0,m.MZ)({value:null})],M.prototype,"attributes",null),(0,s.Cg)([(0,m.MZ)({value:null,types:g.yR,json:{read:c.rS}})],M.prototype,"geometry",null),(0,s.Cg)([(0,m.MZ)()],M.prototype,"distance",void 0),(0,s.Cg)([(0,m.MZ)({type:Boolean})],M.prototype,"isAggregate",void 0),(0,s.Cg)([(0,m.MZ)({clonable:!1})],M.prototype,"layer",void 0),(0,s.Cg)([(0,m.MZ)({clonable:"reference"})],M.prototype,"origin",void 0),(0,s.Cg)([(0,m.MZ)({type:n.A,value:null})],M.prototype,"popupTemplate",null),(0,s.Cg)([(0,m.MZ)({clonable:"reference"})],M.prototype,"sourceLayer",void 0),(0,s.Cg)([(0,m.MZ)({json:{name:"aggregateIds",read:e=>e?.map(e=>Array.isArray(e)?JSON.stringify(e):e)}})],M.prototype,"statisticsAggregatedIds",void 0),(0,s.Cg)([(0,m.MZ)({value:null,types:C.Es})],M.prototype,"symbol",null),(0,s.Cg)([(0,m.MZ)({clonable:!1,json:{read:!1,write:!1}})],M.prototype,"_version",void 0),(0,s.Cg)([(0,m.MZ)({type:Boolean,value:!0})],M.prototype,"visible",null),M=l=(0,s.Cg)([(0,m.$K)("esri.Graphic")],M)},38961(e,t,r){var i=r(32198),l=r(7762),s=r(36708),n=r(10107),a=r(64108),o=r(80559);let u=class extends l.A{constructor(e){super(e),this.getCollections=null}initialize(){this.addHandles((0,o.fm)(()=>this._refresh(),s.OH))}destroy(){this.getCollections=null}_refresh(){let e=this.getCollections?.();if(null==e)return void this.removeAll();let t=0;for(let r of e)null!=r&&(t=this._processCollection(t,r));this.splice(t)}_createNewInstance(e){return new l.A(e)}_processCollection(e,t){if(!t)return e;let r=this.itemFilterFunction??(e=>!!e);for(let i of t)if(i){if(r(i)){let t=this.indexOf(i,e);t>=0?t!==e&&this.reorder(i,e):this.add(i,e),++e}if(this.getChildrenFunction){let t=this.getChildrenFunction(i);if(Array.isArray(t))for(let r of t)e=this._processCollection(e,r);else e=this._processCollection(e,t)}}return e}};(0,i.Cg)([(0,n.MZ)()],u.prototype,"getCollections",void 0),(0,i.Cg)([(0,n.MZ)()],u.prototype,"getChildrenFunction",void 0),(0,i.Cg)([(0,n.MZ)()],u.prototype,"itemFilterFunction",void 0),u=(0,i.Cg)([(0,a.$)("esri.core.CollectionFlattener")],u);const p=u;r.d(t,["A",0,p])},60999(e,t,r){r.d(t,{DZ:()=>y,Ke:()=>m,QA:()=>c,Tj:()=>p,UT:()=>g,aD:()=>b,jJ:()=>u});var i=r(32198),l=r(69622),s=r(97768),n=r(17676),a=r(10107),o=r(64108);function u(e,t,r){return(0,n.Lx)(e.map((e,i)=>t.apply(r,[e,i])))}async function p(e,t,r){return(await(0,n.Lx)(e.map((e,i)=>t.apply(r,[e,i])))).map(e=>e.value)}function d(e){return{ok:!0,value:e}}function h(e){return{ok:!1,error:e}}async function m(e){if(null==e)return{ok:!1,error:Error("no promise provided")};try{return d(await e)}catch(e){return h(e)}}async function y(e){try{return d(await e)}catch(e){return(0,n.QP)(e),h(e)}}function c(e){if(!0===e.ok)return e.value;throw e.error}function g(e,t){return new f(e,t)}let f=class extends l.A{get value(){return null!=(e=this._result)&&!0===e.ok?e.value:null;var e}get error(){return null!=(e=this._result)&&!1===e.ok?e.error:null;var e}get finished(){return null!=this._result}constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,s.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;let{signal:r}=this._abortController;this.promise=e(r),this.promise.then(e=>{this._result=d(e),this._cleanup()},e=>{this._result=h(e),this._cleanup()}),this._abortHandle=(0,n.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,s.xt)(this._abortHandle),this._abortController=null}};(0,i.Cg)([(0,a.MZ)()],f.prototype,"value",null),(0,i.Cg)([(0,a.MZ)()],f.prototype,"error",null),(0,i.Cg)([(0,a.MZ)()],f.prototype,"finished",null),(0,i.Cg)([(0,a.MZ)()],f.prototype,"promise",void 0),(0,i.Cg)([(0,a.MZ)()],f.prototype,"_result",void 0),f=(0,i.Cg)([(0,o.$)("esri.core.asyncUtils.ReactiveTask")],f);class b{constructor(){this._sequence=Promise.resolve()}async acquire(){let e;this._sequence=new Promise(t=>{e=this._sequence.then(()=>t,()=>t)});let t=await e;return{[Symbol.dispose]:t}}async run(e){let t={stack:[],error:void 0,hasError:!1};try{return(0,i.mS)(t,await this.acquire(),!1),await e()}catch(e){t.error=e,t.hasError=!0}finally{(0,i.hk)(t)}}}},16494(e,t,r){var i=r(76361);const l=["dd","dl","dt","h1","h2","h3","h4","h5","h6","sub","sup",..."animate.animatetransform.circle.clippath.defs.ellipse.g.image.line.lineargradient.marker.mask.path.pattern.polygon.polyline.radialgradient.rect.stop.svg.switch.symbol.text.textpath.tspan.use".split(".")].reduce((e,t)=>(e[t]=[],e),{}),s="align.alink.alt.bgcolor.border.cellpadding.cellspacing.class.color.cols.colspan.coords.d.dir.face.height.hspace.ismap.lang.marginheight.marginwidth.multiple.nohref.noresize.noshade.nowrap.ref.rel.rev.rows.rowspan.scrolling.shape.span.summary.tabindex.title.usemap.valign.value.vlink.vspace.width".split("."),n=new i.I({whiteList:l,onTagAttr:(e,t,r)=>{let i=`${t}="${r}"`;if(s.includes(t))return i},stripIgnoreTag:!0,stripIgnoreTagBody:["script","style"]},!0),a=new i.I({whiteList:{br:[]},stripIgnoreTag:!0,escapeHtml:e=>e},!1);r.d(t,["Nd",0,a,"W5",0,n])},55156(e,t,r){r.d(t,{I:()=>l});const i=Symbol("idFieldsProviderSymbol");function l(e){return(t=e)&&i in t?e[i]:void 0;var t}r.d(t,["e",0,i])},51904(e,t,r){r.r(t),r.d(t,{default:()=>Ae});var i=r(32198),l=r(92602),s=r(52106),n=r(40124),a=r(56507),o=r(7762),u=r(38961),p=r(49186),d=r(66552),h=r(4718),m=r(25728),y=r(17676),c=r(36708),g=r(16494),f=r(84952),b=r(91429),v=r(78888),w=r(49422),C=r(5443),I=r(16930),x=r(83960),M=r(21325),A=r(4146),S=r(63074),_=r(34287),E=r(8303),O=r(54310),P=r(25036),F=r(82935),T=r(38458),L=r(60694),N=r(10873),R=r(69622);const Z={visible:"visibleSublayers"};let U=class extends R.A{constructor(e){super(e),this.scale=0}set layer(e){this._get("layer")!==e&&(this._set("layer",e),this.removeHandles("layer"),e&&this.addHandles([e.sublayers.on("change",()=>this.notifyChange("visibleSublayers")),e.on("wms-sublayer-update",e=>this.notifyChange(Z[e.propertyName]))],"layer"))}get layers(){return this.visibleSublayers.filter(({name:e})=>e).map(({name:e})=>e).join()}get version(){this.commitProperty("layers");let e=this.layer;return e&&e.commitProperty("imageTransparency"),(this._get("version")||0)+1}get visibleSublayers(){let{layer:e,scale:t}=this,r=e?.sublayers,i=[],l=e=>{let{minScale:r,maxScale:s,sublayers:n,visible:a}=e;a&&(0===t||(0===r||t<=r)&&(0===s||t>=s))&&(n?n.forEach(l):i.push(e))};return r?.forEach(l),i}toJSON(){let{layer:e,layers:t}=this,{imageFormat:r,imageTransparency:i,version:l}=e;return{format:r,request:"GetMap",service:"WMS",styles:"",transparent:i?"TRUE":"FALSE",version:l,layers:t}}};(0,i.Cg)([(0,b.MZ)()],U.prototype,"layer",null),(0,i.Cg)([(0,b.MZ)({readOnly:!0})],U.prototype,"layers",null),(0,i.Cg)([(0,b.MZ)({type:Number})],U.prototype,"scale",void 0),(0,i.Cg)([(0,b.MZ)({readOnly:!0})],U.prototype,"version",null),(0,i.Cg)([(0,b.MZ)({readOnly:!0})],U.prototype,"visibleSublayers",null),U=(0,i.Cg)([(0,b.$K)("esri.layers.support.ExportWMSImageParameters")],U);var j,H=r(33446),q=r(4902),$=r(36005);let G=0,k=j=class extends((0,q.s)((0,m.M)(R.A))){constructor(e){super(e),this.description=null,this.dimensions=null,this.fullExtent=null,this.fullExtents=null,this.legendUrl=null,this.legendEnabled=!0,this.layer=null,this.maxScale=0,this.minScale=0,this.name=null,this.parent=null,this.popupEnabled=!1,this.queryable=!1,this.spatialReferences=null,this.title=null,this.addHandles([(0,c.on)(()=>this.sublayers,"after-add",({item:e})=>{e.parent=this,e.layer=this.layer},c.OH),(0,c.on)(()=>this.sublayers,"after-remove",({item:e})=>{e.layer=e.parent=null},c.OH),(0,c.wB)(()=>this.sublayers,(e,t)=>{if(t)for(let e of t)e.layer=e.parent=null;if(e)for(let t of e)t.parent=this,t.layer=this.layer},c.OH),(0,c.wB)(()=>this.layer,e=>{if(this.sublayers)for(let t of this.sublayers)t.layer=e},c.OH)])}get id(){return this._get("id")??G++}set id(e){this._set("id",e)}readLegendUrl(e,t){return t.legendUrl??t.legendURL??null}get effectiveScaleRange(){let{minScale:e,maxScale:t}=this;return{minScale:e,maxScale:t}}get sublayers(){return this._get("sublayers")}set sublayers(e){this._set("sublayers",e)}castSublayers(e){return(0,v.dp)(o.A.ofType(j),e)}set visible(e){this._setAndNotifyLayer("visible",e)}clone(){let e=new j;return this.hasOwnProperty("description")&&(e.description=this.description),this.hasOwnProperty("fullExtent")&&(e.fullExtent=this.fullExtent.clone()),this.hasOwnProperty("fullExtents")&&(e.fullExtents=this.fullExtents?.map(e=>e.clone())??null),this.hasOwnProperty("legendUrl")&&(e.legendUrl=this.legendUrl),this.hasOwnProperty("legendEnabled")&&(e.legendEnabled=this.legendEnabled),this.hasOwnProperty("layer")&&(e.layer=this.layer),this.hasOwnProperty("name")&&(e.name=this.name),this.hasOwnProperty("parent")&&(e.parent=this.parent),this.hasOwnProperty("queryable")&&(e.queryable=this.queryable),this.hasOwnProperty("sublayers")&&(e.sublayers=this.sublayers?.map(e=>e.clone())),this.hasOwnProperty("spatialReferences")&&(e.spatialReferences=this.spatialReferences?.map(e=>e)),this.hasOwnProperty("visible")&&(e.visible=this.visible),this.hasOwnProperty("title")&&(e.title=this.title),e}_setAndNotifyLayer(e,t){let r=this.layer;this._get(e)!==t&&(this._set(e,t),r&&r.emit("wms-sublayer-update",{propertyName:e,id:this.id}))}};(0,i.Cg)([(0,b.MZ)()],k.prototype,"description",void 0),(0,i.Cg)([(0,b.MZ)({readOnly:!0})],k.prototype,"dimensions",void 0),(0,i.Cg)([(0,b.MZ)({type:C.A,json:{name:"extent"}})],k.prototype,"fullExtent",void 0),(0,i.Cg)([(0,b.MZ)()],k.prototype,"fullExtents",void 0),(0,i.Cg)([(0,b.MZ)({type:Number,json:{write:{enabled:!1,overridePolicy:()=>({ignoreOrigin:!0,enabled:!0})}}})],k.prototype,"id",null),(0,i.Cg)([(0,b.MZ)({type:String,json:{name:"legendUrl",write:{ignoreOrigin:!0}}})],k.prototype,"legendUrl",void 0),(0,i.Cg)([(0,$.w)("legendUrl",["legendUrl","legendURL"])],k.prototype,"readLegendUrl",null),(0,i.Cg)([(0,b.MZ)({type:Boolean,json:{name:"showLegend",origins:{"web-map":{read:!1,write:!1},"web-scene":{read:!1,write:!1}}}})],k.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,b.MZ)()],k.prototype,"layer",void 0),(0,i.Cg)([(0,b.MZ)()],k.prototype,"maxScale",void 0),(0,i.Cg)([(0,b.MZ)()],k.prototype,"minScale",void 0),(0,i.Cg)([(0,b.MZ)({readOnly:!0})],k.prototype,"effectiveScaleRange",null),(0,i.Cg)([(0,b.MZ)({type:String,json:{write:{ignoreOrigin:!0}}})],k.prototype,"name",void 0),(0,i.Cg)([(0,b.MZ)()],k.prototype,"parent",void 0),(0,i.Cg)([(0,b.MZ)({type:Boolean,json:{read:{source:"showPopup"},write:{ignoreOrigin:!0,target:"showPopup"}}})],k.prototype,"popupEnabled",void 0),(0,i.Cg)([(0,b.MZ)({type:Boolean,json:{write:{ignoreOrigin:!0}}})],k.prototype,"queryable",void 0),(0,i.Cg)([(0,b.MZ)()],k.prototype,"sublayers",null),(0,i.Cg)([(0,b.wg)("sublayers")],k.prototype,"castSublayers",null),(0,i.Cg)([(0,b.MZ)({type:[Number],json:{read:{source:"spatialReferences"}}})],k.prototype,"spatialReferences",void 0),(0,i.Cg)([(0,b.MZ)({type:String,json:{write:{ignoreOrigin:!0}}})],k.prototype,"title",void 0),(0,i.Cg)([(0,b.MZ)({type:Boolean,value:!0,json:{read:{source:"defaultVisibility"}}})],k.prototype,"visible",null),k=j=(0,i.Cg)([(0,b.$K)("esri.layers.support.WMSSublayer")],k);var B=r(4576),D=r(34747);const V={84:4326,83:4269,27:4267};function W(e){if(!e)return null;let t={idCounter:-1};"string"==typeof e&&(e=(new DOMParser).parseFromString(e,"text/xml"));let r=e.documentElement;if("ServiceExceptionReport"===r.nodeName){let e=Array.prototype.slice.call(r.childNodes).map(e=>e.textContent).join("\r\n");throw new p.A("wmslayer:wms-capabilities-xml-is-not-valid","The server returned errors when the WMS capabilities were requested.",e)}let i=Y("Capability",r),l=Y("Service",r),s=i&&Y("Request",i);if(!i||!l||!s)return null;let n=Y("Layer",i);if(!n)return null;let a="WMS_Capabilities"===r.nodeName||"WMT_MS_Capabilities"===r.nodeName?r.getAttribute("version"):"1.3.0",o=X("Title",l,"")||X("Name",l,""),u=X("AccessConstraints",l,""),d=/^none$/i.test(u)?"":u,h=X("Abstract",l,""),m=parseInt(X("MaxWidth",l,"5000"),10),y=parseInt(X("MaxHeight",l,"5000"),10),c=re(s,"GetMap"),g=te(s,"GetMap"),f=le(n,a,t);if(!f)return null;let b,v=0,w=Array.prototype.slice.call(i.childNodes),C=f.sublayers??[],I=e=>{null!=e&&C.push(e)};w.forEach(e=>{"Layer"===e.nodeName&&(0===v?b=e:(1===v&&f.name&&(f.name="",I(le(b,a,t))),I(le(e,a,t))),v++)});let x=f.sublayers??[],M=f.fullExtents??[];0===x.length&&x.push(f),f.extent??=x[0].extent;let A=f.spatialReferences.length>0?f.spatialReferences:J(f),S=te(s,"GetFeatureInfo"),_=S?re(s,"GetFeatureInfo"):null,E=K(x),O=f.minScale||0,P=f.maxScale||0,F=f.dimensions??[],T=E.reduce((e,t)=>e.concat(t.dimensions??[]),[]),L=F.concat(T).filter(ne),N=null;if(L.length){let{start:e,end:t}=L.map(e=>{let{extent:t}=e;return function(e){return Array.isArray(e)&&e.length>0&&e[0]instanceof Date}(t)?t.map(e=>e.getTime()):t?.map(e=>[e.min.getTime(),e.max.getTime()])}).flat(2).filter(B.Ru).reduce((e,t)=>({start:Math.min(e.start,t),end:Math.max(e.end,t)}),{start:1/0,end:-1/0});N={startTimeField:null,endTimeField:null,trackIdField:void 0,timeExtent:[e,t]}}return{copyright:d,description:h,dimensions:F,extent:f.extent,fullExtents:M,featureInfoFormats:_,featureInfoUrl:S,mapUrl:g,maxWidth:m,maxHeight:y,maxScale:P,minScale:O,layers:E,spatialReferences:A,supportedImageFormatTypes:c,timeInfo:N,title:o,version:a}}function J(e){if(e.spatialReferences.length>0)return e.spatialReferences;if(e.sublayers)for(let t of e.sublayers){let e=J(t);if(e.length>0)return e}return[]}function K(e){let t=[];for(let r of e)t.push(r),r.sublayers?.length&&(t=t.concat(K(r.sublayers)),delete r.sublayers);return t}function z(e,t,r){return t.getAttribute(e)??r}function Y(e,t){for(let r=0;r<t.childNodes.length;r++){let i=t.childNodes[r];if(se(i)&&i.nodeName===e)return i}return null}function Q(e,t){if(null==t)return[];let r=[];for(let i=0;i<t.childNodes.length;i++){let l=t.childNodes[i];se(l)&&l.nodeName===e&&r.push(l)}return r}function X(e,t,r){return Y(e,t)?.textContent??r}function ee(e,t,r){let i=parseFloat(e.getAttribute("minx")??"0"),l=parseFloat(e.getAttribute("miny")??"0"),s=parseFloat(e.getAttribute("maxx")??"0"),n=parseFloat(e.getAttribute("maxy")??"0");return{xmin:r?isNaN(l)?-Number.MAX_VALUE:l:isNaN(i)?-Number.MAX_VALUE:i,ymin:r?isNaN(i)?-Number.MAX_VALUE:i:isNaN(l)?-Number.MAX_VALUE:l,xmax:r?isNaN(n)?Number.MAX_VALUE:n:isNaN(s)?Number.MAX_VALUE:s,ymax:r?isNaN(s)?Number.MAX_VALUE:s:isNaN(n)?Number.MAX_VALUE:n,spatialReference:{wkid:t}}}function te(e,t){let r=Y(t,e);if(r){let e=Y("DCPType",r);if(e){let t=Y("HTTP",e);if(t){let e=Y("Get",t);if(e){let t=function(e,t,r){let i=Y("OnlineResource",r);return i?z("xlink:href",i,null):null}(0,0,e);if(t){let e=t.indexOf("&");return-1!==e&&e===t.length-1&&(t=t.slice(0,-1)),function(e,t){let r=[],i=(0,f.An)(e);for(let e in i.query)i.query.hasOwnProperty(e)&&(t.includes(e.toLowerCase())||r.push(e+"="+i.query[e]));return i.path+(r.length?"?"+r.join("&"):"")}(t,["service","request"])}}}}}return null}function re(e,t){let r=Q("Operation",e);if(!r.length)return Q("Format",Y(t,e)).map(({textContent:e})=>e).filter(B.Ru);let i=[];for(let e of r)if(e.getAttribute("name")===t){let t=Q("Format",e);for(let{textContent:e}of t)null!=e&&i.push(e)}return i}function ie(e,t,r){let i=Y(t,e);if(!i)return r;let{textContent:l}=i;if(null==l||""===l)return r;let s=Number(l);return isNaN(s)?r:s}function le(e,t,r){if(!e)return null;let i=e.getAttribute("queryable")?.toLowerCase(),l="1"===i||"true"===i,s={id:r.idCounter++,fullExtents:[],parentLayerId:null,queryable:l,spatialReferences:[],sublayers:null},n=Y("LatLonBoundingBox",e),a=Y("EX_GeographicBoundingBox",e),o=n?ee(n,4326):a?{xmin:parseFloat(X("westBoundLongitude",a,"0")),ymin:parseFloat(X("southBoundLatitude",a,"0")),xmax:parseFloat(X("eastBoundLongitude",a,"0")),ymax:parseFloat(X("northBoundLatitude",a,"0")),spatialReference:{wkid:4326}}:{xmin:-180,ymin:-90,xmax:180,ymax:90,spatialReference:{wkid:4326}};s.minScale=ie(e,"MaxScaleDenominator",0),s.maxScale=ie(e,"MinScaleDenominator",0);let u=["1.0.0","1.1.0","1.1.1"].includes(t)?"SRS":"CRS";return Array.prototype.slice.call(e.childNodes).forEach(e=>{if("Name"===e.nodeName)s.name=e.textContent||"";else if("Title"===e.nodeName)s.title=e.textContent||"";else if("Abstract"===e.nodeName)s.description=e.textContent||"";else if("BoundingBox"===e.nodeName){let r=e.getAttribute(u),i=r?.indexOf(":");if(i&&i>-1){let l=parseInt(r.slice(i+1),10);0!==l&&!isNaN(l)&&(l=V[l]??l);let n="1.3.0"===t?ee(e,l,(0,T.m)(l)):ee(e,l);n&&s.fullExtents&&s.fullExtents.push(n)}}else if(e.nodeName===u)(e.textContent?.split(" ")??[]).forEach(e=>{let t=NaN;if(e.includes(":")){let[r,i]=e.toUpperCase().split(":");("CRS"===r||"EPSG"===r)&&(t=parseInt(i,10))}else t=parseInt(e,10);if(0!==t&&!isNaN(t)){let e=V[t]??t;s.spatialReferences.includes(e)||s.spatialReferences.push(e)}});else if("Style"!==e.nodeName||s.legendUrl){if("Layer"===e.nodeName){let i=le(e,t,r);i&&(i.parentLayerId=s.id,s.sublayers||=[],s.sublayers.push(i))}}else{let t=Y("LegendURL",e);if(t){let e=Y("OnlineResource",t);e&&(s.legendUrl=e.getAttribute("xlink:href"))}}}),s.extent=o,s.dimensions=Q("Dimension",e).filter(e=>e.getAttribute("name")&&e.getAttribute("units")&&e.textContent).map(e=>{let t=e.getAttribute("name"),r=e.getAttribute("units"),i=e.textContent,l=e.getAttribute("unitSymbol")??void 0,s=e.getAttribute("default")??void 0,n="0"!==z("default",e,"0"),a="0"!==z("nearestValue",e,"0"),o="0"!==z("current",e,"0");return ne({name:t,units:r})?{name:"time",units:"ISO8601",extent:ue(i),default:ue(s),multipleValues:n,nearestValue:a,current:o}:function(e){return/^elevation$/i.test(e.name)&&/^(epsg|crs):\d+$/i.test(e.units)}({name:t,units:r})?{name:"elevation",units:r,extent:ae(i),unitSymbol:l,default:ae(s),multipleValues:n,nearestValue:a}:{name:t,units:r,extent:oe(i),unitSymbol:l,default:oe(s),multipleValues:n,nearestValue:a}}),s}function se(e){return e.nodeType===Node.ELEMENT_NODE}function ne(e){return/^time$/i.test(e.name)&&/^iso8601$/i.test(e.units)}function ae(e){if(!e)return;let t=e.includes("/"),r=e.split(",");return t?r.map(e=>{let t=e.split("/");return t.length<2?null:{min:parseFloat(t[0]),max:parseFloat(t[1]),resolution:t.length>=3&&"0"!==t[2]?parseFloat(t[2]):void 0}}).filter(B.Ru):r.map(e=>parseFloat(e))}function oe(e){if(!e)return;let t=e.includes("/"),r=e.split(",");return t?r.map(e=>{let t=e.split("/");return t.length<2?null:{min:t[0],max:t[1],resolution:t.length>=3&&"0"!==t[2]?t[2]:void 0}}).filter(B.Ru):r}function ue(e){if(!e)return;let t=e.includes("/"),r=e.split(",");return t?r.map(e=>{let t=e.split("/");return t.length<2?null:{min:pe(t[0]),max:pe(t[1]),resolution:t.length>=3&&"0"!==t[2]?de(t[2]):void 0}}).filter(B.Ru):r.map(e=>pe(e))}function pe(e){return D.c9.fromISO(e,{zone:D.mQ.utcInstance}).toJSDate()}function de(e){let t=e.match(/(?:p(\d+y|\d+(?:\.|,)\d+y)?(\d+m|\d+(?:\.|,)\d+m)?(\d+d|\d+(?:\.|,)\d+d)?)?(?:t(\d+h|\d+(?:\.|,)\d+h)?(\d+m|\d+(?:\.|,)\d+m)?(\d+s|\d+(?:\.|,)\d+s)?)?/i);return t?{years:he(t[1]),months:he(t[2]),days:he(t[3]),hours:he(t[4]),minutes:he(t[5]),seconds:he(t[6])}:null}function he(e){if(!e)return 0;let t=e.match(/(?:\d+(?:\.|,)\d+|\d+)/);if(!t)return 0;let r=t[0].replace(",",".");return Number(r)}function me(e){return e.toISOString().replace(/\.[0-9]{3}/,"")}function ye(e){if(!e||e.isAllTime||e.isEmpty)return;let{start:t,end:r}=e;return t&&t.getTime()===r?.getTime()?`${me(t)}`:`${t?me(t):"0000-01-01T00:00:00Z"}/${r?me(r):"9999-12-31T23:59:59Z"}`}const ce=new Set([102100,3857,102113,900913]),ge=new Set([3395,54004]);var fe=r(79677),be=r(10184),ve=r(43937);const we=new d.J({bmp:"image/bmp",gif:"image/gif",jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml"},{ignoreUnknown:!1});function Ce(e){return"text/html"===e}function Ie(e){return"text/plain"===e}let xe=class extends((0,S.dM)((0,F.e)((0,O.J)((0,P.j)((0,_.q)((0,E.A)((0,m.M)(A.A)))))))){constructor(...e){super(...e),this.allSublayers=new u.A({getCollections:()=>[this.sublayers],getChildrenFunction:e=>e.sublayers}),this.customParameters=null,this.customLayerParameters=null,this.copyright=null,this.description=null,this.dimensions=null,this.fullExtent=null,this.fullExtents=null,this.featureInfoFormats=null,this.featureInfoUrl=null,this.fetchFeatureInfoFunction=null,this.imageFormat=null,this.imageMaxHeight=2048,this.imageMaxWidth=2048,this.imageTransparency=!0,this.legendEnabled=!0,this.mapUrl=null,this.isReference=null,this.operationalLayerType="WMS",this.spatialReference=null,this.spatialReferences=null,this.sublayers=null,this.type="wms",this.version=null,this.addHandles([(0,c.on)(()=>this.sublayers,"after-add",({item:e})=>{e.parent=e.layer=this},c.OH),(0,c.on)(()=>this.sublayers,"after-remove",({item:e})=>{e.layer=e.parent=null},c.OH),(0,c.wB)(()=>this.sublayers,(e,t)=>{if(t)for(let e of t)e.layer=e.parent=null;if(e)for(let t of e)t.parent=t.layer=this},c.OH)])}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}destroy(){this.allSublayers.destroy()}load(e){let t=null==e?null:e.signal;return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["WMS"]},e).catch(y.QP).then(()=>this._fetchService(t)).then(()=>this._checkLayerValidity())),Promise.resolve(this)}get timeInfo(){return super.timeInfo}set timeInfo(e){super.timeInfo=e}readFullExtentFromItemOrMap(e,t){let r=t.extent;return r?new C.A({xmin:r[0][0],ymin:r[0][1],xmax:r[1][0],ymax:r[1][1]}):null}writeFullExtent(e,t){t.extent=[[e.xmin,e.ymin],[e.xmax,e.ymax]]}get featureInfoFormat(){return null==this.featureInfoFormats?null:this.featureInfoFormats.find(Ce)??this.featureInfoFormats.find(Ie)??null}set featureInfoFormat(e){null==e?(this.revertToOrigin("featureInfoFormat","service"),this._clearOverride("featureInfoFormat")):(Ce(e)||Ie(e))&&this._override("featureInfoFormat",e)}readImageFormat(e,t){let r=t.supportedImageFormatTypes;return r&&r.includes("image/png")?"image/png":r&&r[0]}readSpatialReferenceFromItemOrDocument(e,t){return new I.A(t.spatialReferences[0])}writeSpatialReferences(e,t){let r=this.spatialReference?.wkid;e&&r?(t.spatialReferences=e.filter(e=>e!==r),t.spatialReferences.unshift(r)):t.spatialReferences=e}readSublayersFromItemOrMap(e,t,r){return Me(t.layers,r,t.visibleLayers)}readSublayers(e,t,r){return Me(t.layers,r)}writeSublayers(e,t,r,i){t.layers=[];let l=new Map,s=e.flatten(({sublayers:e})=>e??[]);for(let e of s)if("number"==typeof e.parent?.id){let t=l.get(e.parent.id);null==t?l.set(e.parent.id,[e.id]):t.push(e.id)}for(let e of s){let r={sublayer:e,...i},s=e.write({parentLayerId:"number"==typeof e.parent?.id?e.parent.id:-1},r);if(l.has(e.id)&&(s.sublayerIds=l.get(e.id)),!e.sublayers&&e.name){let i=e.write({},r);delete i.id,t.layers.push(i)}}t.visibleLayers=s.filter(({visible:e,sublayers:t})=>e&&!t).map(({name:e})=>e).toArray()}set url(e){if(!e)return void this._set("url",e);let{path:t,query:r}=(0,f.An)(e);for(let e in r)/^(request|service)$/i.test(e)&&delete r[e];let i=(0,f.a6)(t,r??{});this._set("url",i)}createExportImageParameters(e,t,r,i){let l=i?.pixelRatio??1,s=(0,x.X_)({extent:e,width:t})*l,n=new U({layer:this,scale:s}),{xmin:a,ymin:o,xmax:u,ymax:p,spatialReference:d}=e,h=function(e,t){let r=e.wkid;return null!=t&&((null==r||!t.includes(r))&&e.latestWkid&&(r=e.latestWkid),null!=r&&ce.has(r))?t.find(e=>ce.has(e))||t.find(e=>ge.has(e))||102100:r}(d,this.spatialReferences),m="1.3.0"===this.version&&(0,T.m)(h)?`${o},${a},${p},${u}`:`${a},${o},${u},${p}`,y=n.toJSON();return{bbox:m,["1.3.0"===this.version?"crs":"srs"]:null==h||isNaN(h)?void 0:"EPSG:"+h,...y}}async fetchImage(e,t,r,i){let l=this.mapUrl,s=this.createExportImageParameters(e,t,r,i);if(!s.layers){let e=document.createElement("canvas");return e.width=t,e.height=r,e}let n=ye(i?.timeExtent),o={responseType:"image",query:this._mixCustomParameters({width:t,height:r,...s,time:n,...this.refreshParameters}),signal:i?.signal};return(0,a.A)(l??"",o).then(e=>e.data)}async fetchImageBitmap(e,t,r,i){let l=this.mapUrl??"",s=this.createExportImageParameters(e,t,r,i);if(!s.layers){let e=document.createElement("canvas");return e.width=t,e.height=r,e}let n=ye(i?.timeExtent),o={responseType:"blob",query:this._mixCustomParameters({width:t,height:r,...s,time:n,...this.refreshParameters}),signal:i?.signal},{data:u}=await(0,a.A)(l,o);return(0,H.mn)(u,l,i)}fetchFeatureInfo(e,t,r,i,l){let s=(0,x.X_)({extent:e,width:t}),n=function(e){let t=e.filter(e=>e.popupEnabled&&e.name&&e.queryable);return t.length?t.map(({name:e})=>e).join():null}(new U({layer:this,scale:s}).visibleSublayers);if(null==this.featureInfoUrl||null==n||null==this.fetchFeatureInfoFunction&&null==this.featureInfoFormat)return Promise.resolve([]);let a="1.3.0"===this.version?{I:i,J:l}:{x:i,y:l},o={query_layers:n,request:"GetFeatureInfo",info_format:this.featureInfoFormat,feature_count:25,width:t,height:r,...a},u={...this.createExportImageParameters(e,t,r),...o},p=this._mixCustomParameters(u);return null==this.fetchFeatureInfoFunction?this._defaultFetchFeatureInfoFunction((0,f.a6)(this.featureInfoUrl,p)):this.fetchFeatureInfoFunction(p)}findSublayerById(e){return this.allSublayers.find(t=>t.id===e)}findSublayerByName(e){return this.allSublayers.find(t=>t.name===e)}serviceSupportsSpatialReference(e){return(0,L.bd)(this.url)||null!=this.spatialReferences&&this.spatialReferences.some(t=>{let r=900913===t?I.A.WebMercator:new I.A({wkid:t});return(0,M.aI)(r,e)})}_defaultFetchFeatureInfoFunction(e){let t=document.createElement("iframe");t.src=(0,f.yM)(g.W5.sanitizeUrl((0,f.s2)(e))),t.style.border="none",t.style.margin="0",t.style.width="100%",t.setAttribute("sandbox","");let r=new n.A({title:this.title,content:t}),i=new s.A({sourceLayer:this,popupTemplate:r});return Promise.resolve([i])}async _fetchService(e){if(!this.resourceInfo&&this.parsedUrl?.path){let{path:t,query:r}=this.parsedUrl,{data:i}=await(0,a.A)(t,{query:{SERVICE:"WMS",REQUEST:"GetCapabilities",...r,...this.customParameters},responseType:"xml",signal:e});this.resourceInfo=W(i)}if(this.parsedUrl){let e=new f.s0(this.parsedUrl.path),{httpsDomains:t}=l.A.request;"https"!==e.scheme||e.port&&"443"!==e.port||!e.host||t.includes(e.host)||t.push(e.host)}this.read(this.resourceInfo,{origin:"service"})}_checkLayerValidity(){if(!this.allSublayers.length)throw new p.A("wmslayer:empty-layer","The layer doesn't have any sublayer")}_mixCustomParameters(e){if(!this.customLayerParameters&&!this.customParameters)return e;let t={...this.customParameters,...this.customLayerParameters};for(let r in t)e[r.toLowerCase()]=t[r];return e}};function Me(e,t,r){e??=[];let i=new Map;e.every(e=>null==e.id)&&(e=(0,h.o8)(e)).forEach((e,t)=>e.id=t);for(let l of e){let e=new k;e.read(l,t),r&&!r.includes(e.name)&&(e.visible=!1),i.set(e.id,e)}let l=[];for(let t of e){let e=null==t.id?null:i.get(t.id);if(e)if(null!=t.parentLayerId&&t.parentLayerId>=0){let r=i.get(t.parentLayerId);if(!r)continue;r.sublayers||=new o.A,r.sublayers.push(e)}else l.push(e)}return l}(0,i.Cg)([(0,b.MZ)({type:fe.A})],xe.prototype,"timeExtent",void 0),(0,i.Cg)([(0,b.MZ)({type:be.A})],xe.prototype,"timeOffset",void 0),(0,i.Cg)([(0,b.MZ)({readOnly:!0})],xe.prototype,"allSublayers",void 0),(0,i.Cg)([(0,b.MZ)({json:{type:Object,write:!0}})],xe.prototype,"customParameters",void 0),(0,i.Cg)([(0,b.MZ)({json:{type:Object,write:!0}})],xe.prototype,"customLayerParameters",void 0),(0,i.Cg)([(0,b.MZ)({type:String,json:{write:!0}})],xe.prototype,"copyright",void 0),(0,i.Cg)([(0,b.MZ)()],xe.prototype,"description",void 0),(0,i.Cg)([(0,b.MZ)({readOnly:!0})],xe.prototype,"dimensions",void 0),(0,i.Cg)([(0,b.MZ)({json:{type:[[Number]],read:{source:"extent"},write:{target:"extent"},origins:{"web-document":{write:{ignoreOrigin:!0}},"portal-item":{write:{ignoreOrigin:!0}}}}})],xe.prototype,"fullExtent",void 0),(0,i.Cg)([(0,$.w)(["web-document","portal-item"],"fullExtent",["extent"])],xe.prototype,"readFullExtentFromItemOrMap",null),(0,i.Cg)([(0,ve.K)(["web-document","portal-item"],"fullExtent",{extent:{type:[[Number]]}})],xe.prototype,"writeFullExtent",null),(0,i.Cg)([(0,b.MZ)({type:[C.A]})],xe.prototype,"fullExtents",void 0),(0,i.Cg)([(0,b.MZ)({type:String,json:{write:{ignoreOrigin:!0}}})],xe.prototype,"featureInfoFormat",null),(0,i.Cg)([(0,b.MZ)({type:[String],readOnly:!0})],xe.prototype,"featureInfoFormats",void 0),(0,i.Cg)([(0,b.MZ)({type:String,json:{write:{ignoreOrigin:!0}}})],xe.prototype,"featureInfoUrl",void 0),(0,i.Cg)([(0,b.MZ)()],xe.prototype,"fetchFeatureInfoFunction",void 0),(0,i.Cg)([(0,b.MZ)({type:String,json:{origins:{"web-document":{default:"image/png",type:we.jsonValues,read:{reader:we.read,source:"format"},write:{writer:we.write,target:"format"}}}}})],xe.prototype,"imageFormat",void 0),(0,i.Cg)([(0,$.w)("imageFormat",["supportedImageFormatTypes"])],xe.prototype,"readImageFormat",null),(0,i.Cg)([(0,b.MZ)({type:Number,json:{read:{source:"maxHeight"},write:{target:"maxHeight"}}})],xe.prototype,"imageMaxHeight",void 0),(0,i.Cg)([(0,b.MZ)({type:Number,json:{read:{source:"maxWidth"},write:{target:"maxWidth"}}})],xe.prototype,"imageMaxWidth",void 0),(0,i.Cg)([(0,b.MZ)()],xe.prototype,"imageTransparency",void 0),(0,i.Cg)([(0,b.MZ)(N.fV)],xe.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,b.MZ)({type:["show","hide","hide-children"]})],xe.prototype,"listMode",void 0),(0,i.Cg)([(0,b.MZ)({type:String,json:{write:{ignoreOrigin:!0}}})],xe.prototype,"mapUrl",void 0),(0,i.Cg)([(0,b.MZ)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],xe.prototype,"isReference",void 0),(0,i.Cg)([(0,b.MZ)({type:["WMS"]})],xe.prototype,"operationalLayerType",void 0),(0,i.Cg)([(0,b.MZ)()],xe.prototype,"resourceInfo",void 0),(0,i.Cg)([(0,b.MZ)({type:I.A,json:{origins:{service:{read:{source:"extent.spatialReference"}}},write:!1}})],xe.prototype,"spatialReference",void 0),(0,i.Cg)([(0,$.w)(["web-document","portal-item"],"spatialReference",["spatialReferences"])],xe.prototype,"readSpatialReferenceFromItemOrDocument",null),(0,i.Cg)([(0,b.MZ)({type:[v.jz],json:{read:!1,origins:{service:{read:!0},"web-document":{read:!1,write:{ignoreOrigin:!0}},"portal-item":{read:!1,write:{ignoreOrigin:!0}}}}})],xe.prototype,"spatialReferences",void 0),(0,i.Cg)([(0,ve.K)(["web-document","portal-item"],"spatialReferences")],xe.prototype,"writeSpatialReferences",null),(0,i.Cg)([(0,b.MZ)({type:o.A.ofType(k),json:{write:{target:"layers",overridePolicy(e,t,r){if(function(e,t){return e.some(e=>{for(let r in e)if((0,w.R)(e,r,null,t))return!0;return!1})}(this.allSublayers,r))return{ignoreOrigin:!0}}}}})],xe.prototype,"sublayers",void 0),(0,i.Cg)([(0,$.w)(["web-document","portal-item"],"sublayers",["layers","visibleLayers"])],xe.prototype,"readSublayersFromItemOrMap",null),(0,i.Cg)([(0,$.w)("service","sublayers",["layers"])],xe.prototype,"readSublayers",null),(0,i.Cg)([(0,ve.K)("sublayers",{layers:{type:[k]},visibleLayers:{type:[String]}})],xe.prototype,"writeSublayers",null),(0,i.Cg)([(0,b.MZ)({json:{read:!1},readOnly:!0,value:"wms"})],xe.prototype,"type",void 0),(0,i.Cg)([(0,b.MZ)(N.OZ)],xe.prototype,"url",null),(0,i.Cg)([(0,b.MZ)({type:String,json:{write:{ignoreOrigin:!0}}})],xe.prototype,"version",void 0),xe=(0,i.Cg)([(0,b.$K)("esri.layers.WMSLayer")],xe);const Ae=xe},54339(e,t,r){function i(e,t){switch(t.type){case"object-id":case"unique-id-simple":return e.attributes[t.fieldName];case"unique-id-composite":{let r=[];for(let i of t.fieldNames)r.push(e.attributes[i]??null);return JSON.stringify(r)}}}function l(e,t){if("uniqueIdFields"in t&&t.uniqueIdFields?.length){if(1===t.uniqueIdFields.length)return e.attributes?.[t.uniqueIdFields[0]];let r=t.uniqueIdFields.map(t=>e.attributes?.[t]);return JSON.stringify(r)}return"objectIdField"in t&&t.objectIdField?e.attributes?.[t.objectIdField]:null}r.d(t,{W:()=>i,r:()=>l})},8303(e,t,r){var i=r(32198),l=r(92602),s=r(70333),n=r(56507),a=r(60999),o=r(49186),u=r(36563),p=r(53966),d=r(97768),h=r(17676),m=r(84952),y=r(91429),c=r(77548),g=r(20655),f=r(80812),b=r(41318),v=r(10407),w=r(26121),C=r(36005),I=r(43937);const x={credential:null,user:null};r.d(t,["A",0,e=>{let t=e,M=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){super.destroy(),this.portalItem=(0,d.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}get portalItem(){return this._get("portalItem")}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new f.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{let{load:i}=await r.e(1204).then(()=>r(41204));return(0,h.Te)(t),await i({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,h.zf)(e)||p.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async reloadFromPortal(e,t){if(!this.loaded||!this.portalItem?.id)return!1;let i=t?.signal?null:new AbortController;try{let{reload:l}=await r.e(1204).then(()=>r(41204));return i&&this.addHandles((0,u.rE)(i),"reloadFromPortal"),await l({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t?.signal?t:{signal:i.signal})}catch(e){throw(0,h.zf)(e)||p.A.getLogger(this).warn(`Failed to reload layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}finally{i&&this.removeHandles("reloadFromPortal")}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,h.QP)(e),!0)))}async setUserPrivileges(e,t){if(!l.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{let{features:{edit:r,fullEdit:i},content:{updateItem:l}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",i),this._set("userHasUpdateItemPrivileges",l)}catch(e){(0,h.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);let i,l,n=!s.id?.findCredential(this.url),a=e===r.id;if(a&&r.portal.user)return this._getUserPrivileges(r,n);if(a)i=r.portal.url;else try{i=await(0,c.wI)(this.url,t)}catch(e){(0,h.QP)(e)}if(!i||!(0,m.b8)(i,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{let e=null==t?null:t.signal;l=await(s.id?.getCredential(`${i}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,h.QP)(e)}if(!l)return{features:{edit:!0,fullEdit:!1},content:{updateItem:!1}};try{if(a?await r.reload():(r=new f.default({id:e,portal:{url:i}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,n)}catch(e){(0,h.QP)(e)}return{features:{edit:!0,fullEdit:!1},content:{updateItem:!1}}}_getUserPrivileges(e,t){let r=(0,v.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,h.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){let t=this.url?s.id?.findCredential(this.url):null;if(!t)return!0;let r=x.credential===t?x.user:await this._fetchEditingUser(e);return x.credential=t,x.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){let t=this.portalItem?.portal?.user;if(t)return t;let r=s.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;let i=`${r.owningSystemUrl}/sharing/rest`,l=g.A.getDefault();if(l&&l.loaded&&(0,m.S8)(l.restUrl)===(0,m.S8)(i))return l.user;let o=`${i}/community/self`,u=null==e?null:e.signal,p=await(0,a.Ke)((0,n.A)(o,{authMode:"no-prompt",query:{f:"json"},signal:u}));return p.ok?b.A.fromJSON(p.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){return(0,w.wN)(this.portalItem,t)?(t?.messages?.push(new o.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,i.Cg)([(0,y.MZ)({type:f.default})],M.prototype,"portalItem",null),(0,i.Cg)([(0,C.w)("web-document","portalItem",["itemId"])],M.prototype,"readPortalItem",null),(0,i.Cg)([(0,I.K)("web-document","portalItem",{itemId:{type:String}})],M.prototype,"writePortalItem",null),(0,i.Cg)([(0,y.MZ)({clonable:!1})],M.prototype,"resourceReferences",void 0),(0,i.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],M.prototype,"userHasEditingPrivileges",void 0),(0,i.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],M.prototype,"userHasFullEditingPrivileges",void 0),(0,i.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],M.prototype,"userHasUpdateItemPrivileges",void 0),M=(0,i.Cg)([(0,y.$K)("esri.layers.mixins.PortalLayer")],M),M}])},82935(e,t,r){var i=r(32198),l=r(91429),s=r(30524),n=r(96184),a=r(73133),o=r(79677),u=r(10184),p=r(36005);const d={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation"}}};r.d(t,["B",0,d,"e",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){let r=t.timeInfo.exportOptions;if(!r)return null;let i=r.timeOffset,l=a.j.fromJSON(r.timeOffsetUnits);return i&&l?new u.A({value:i,unit:l}):null}get timeInfo(){return this._get("timeInfo")}set timeInfo(e){(0,s.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,i.Cg)([(0,l.MZ)({type:o.A,json:{write:!1}})],r.prototype,"timeExtent",void 0),(0,i.Cg)([(0,l.MZ)({type:u.A})],r.prototype,"timeOffset",void 0),(0,i.Cg)([(0,p.w)("service","timeOffset",["timeInfo.exportOptions"])],r.prototype,"readOffset",null),(0,i.Cg)([(0,l.MZ)({value:null,type:n.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],r.prototype,"timeInfo",null),(0,i.Cg)([(0,l.MZ)(d)],r.prototype,"useViewTime",void 0),r=(0,i.Cg)([(0,l.$K)("esri.layers.mixins.TemporalLayer")],r),r}])},38458(e,t,r){r.d(t,{m:()=>l});const i=[[3819,3819],[3821,3824],[3889,3889],[3906,3906],[4001,4025],[4027,4036],[4039,4047],[4052,4055],[4074,4075],[4080,4081],[4120,4176],[4178,4185],[4188,4216],[4218,4289],[4291,4304],[4306,4319],[4322,4326],[4463,4463],[4470,4470],[4475,4475],[4483,4483],[4490,4490],[4555,4558],[4600,4646],[4657,4765],[4801,4811],[4813,4821],[4823,4824],[4901,4904],[5013,5013],[5132,5132],[5228,5229],[5233,5233],[5246,5246],[5252,5252],[5264,5264],[5324,5340],[5354,5354],[5360,5360],[5365,5365],[5370,5373],[5381,5381],[5393,5393],[5451,5451],[5464,5464],[5467,5467],[5489,5489],[5524,5524],[5527,5527],[5546,5546],[2044,2045],[2081,2083],[2085,2086],[2093,2093],[2096,2098],[2105,2132],[2169,2170],[2176,2180],[2193,2193],[2200,2200],[2206,2212],[2319,2319],[2320,2462],[2523,2549],[2551,2735],[2738,2758],[2935,2941],[2953,2953],[3006,3030],[3034,3035],[3038,3051],[3058,3059],[3068,3068],[3114,3118],[3126,3138],[3150,3151],[3300,3301],[3328,3335],[3346,3346],[3350,3352],[3366,3366],[3389,3390],[3416,3417],[3833,3841],[3844,3850],[3854,3854],[3873,3885],[3907,3910],[4026,4026],[4037,4038],[4417,4417],[4434,4434],[4491,4554],[4839,4839],[5048,5048],[5105,5130],[5253,5259],[5269,5275],[5343,5349],[5479,5482],[5518,5519],[5520,5520],[20004,20032],[20064,20092],[21413,21423],[21473,21483],[21896,21899],[22171,22177],[22181,22187],[22191,22197],[25884,25884],[27205,27232],[27391,27398],[27492,27492],[28402,28432],[28462,28492],[30161,30179],[30800,30800],[31251,31259],[31275,31279],[31281,31290],[31466,31700]];function l(e){return null!=e&&i.some(([t,r])=>e>=t&&e<=r)}},33446(e,t,r){r.d(t,{Cp:()=>n,mn:()=>s});var i=r(49186),l=r(17676);async function s(e,t,r){let s;try{s=await a(e,r)}catch(e){throw new i.A("request:server",`Unable to load ${t}`,{url:t,error:e})}return(0,l.Te)(r),s}async function n(e,t,r,s,n){let o;try{o=await a(e,n)}catch(e){throw new i.A("request:server",`Unable to load tile ${t}/${r}/${s}`,{error:e,level:t,row:r,col:s})}return(0,l.Te)(n),o}async function a(e,t){let r=await createImageBitmap(e,{imageOrientation:t?.imageOrientation??"none"}),i=t?.type??(e instanceof Blob?e.type.startsWith("image/")?e.type:t?.allowDeriveTypeFromData?await async function(e){return e.byteLength<2?"unknown":137===e[0]&&80===e[1]?"image/png":71===e[0]&&73===e[1]?"image/gif":66===e[0]&&77===e[1]?"image/bmp":255===e[0]&&216===e[1]?"image/jpeg":"unknown"}(await e.bytes()):void 0:void 0);return new o(r,i)}class o{constructor(e,t){this.bitmap=e,this.type=t}get isOpaque(){return"image/jpeg"===this.type}}},10407(e,t,r){r.d(t,{It:()=>m,LG:()=>n,OM:()=>u,Sm:()=>p,Y:()=>a,bK:()=>o,sQ:()=>d});var i=r(99917),l=r(16930),s=r(28735);function n(e,t){if(!a(e,t)){let r=e.typeKeywords;r?r.push(t):e.typeKeywords=[t]}}function a(e,t){return!!e.typeKeywords?.includes(t)}function o(e){return a(e,h.HOSTED_SERVICE)}function u(e,t){let r=e.typeKeywords;if(r){let e=r.indexOf(t);e>-1&&r.splice(e,1)}}function p(e,t,r){r?n(e,t):u(e,t)}async function d(e){let t,r=e.clone().normalize();if(r.length>1)for(let e of r)t?e.width>t.width&&(t=e):t=e;else t=r[0];return async function(e){let t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,s.ci)(e);let r=l.A.WGS84;return await(0,i.initializeProjection)(t,r),(0,i.project)(e,r)}(t)}const h={CHARTS:"Charts",CATALOG_LAYER:"CatalogLayer",DYNAMIC:"Dynamic",DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",PARCEL_FABRIC:"ParcelFabric",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery",UTILITY_NETWORK:"UtilityNetwork"};function m(e){let{portal:t,isOrgItem:r,itemControl:i}=e,l=t.user?.privileges,s=!l||l.includes("features:user:edit"),n=!!r&&!!l?.includes("features:user:fullEdit"),a="update"===i||"admin"===i;return a?n=s=!0:n&&(s=!0),{features:{edit:s,fullEdit:n},content:{updateItem:a}}}r.d(t,["mm",0,h])},26121(e,t,r){r.d(t,{I6:()=>p,ci:()=>u,dL:()=>o,wN:()=>d});var i=r(49186),l=r(84952),s=r(77548),n=r(20655),a=r(59923);async function o(e){let t=[];for(let r of e.allLayers)if("beforeSave"in r&&"function"==typeof r.beforeSave){let e=r.beforeSave();e&&t.push(e)}await Promise.allSettled(t)}function u(e,t,r){let l=(e.messages??[]).filter(({type:e})=>"error"===e).map(({name:e,message:t,details:r})=>new i.A(e,t,r));if(e.blockedRelativeUrls&&(l=l.concat(e.blockedRelativeUrls.map(e=>(0,a.GL)("url",`Relative url '${e}' is not supported`)))),r){let{ignoreUnsupported:e,supplementalUnsupportedErrors:t=[],requiredPropertyChecksDisabled:i}=r;e&&(l=l.filter(({name:e})=>!(a.MG.has(e)||t.includes(e)))),i&&(l=l.filter(e=>"web-document-write:property-required"!==e.name))}if(l.length>0)throw new i.A(t.errorName,"Failed to save due to unsupported or invalid content. See 'details.errors' for more detailed information",{errors:l})}function p(e){return(0,s.qd)(e).some(e=>!!e.charts?.length)}function d(e,t){let r=t?.portal,i=e?.id&&(e.portal||n.A.getDefault());return!!r&&!!i&&!(0,l.ut)(i.restUrl,r.restUrl)}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1560,3997,7745],{52106(e,t,r){r.d(t,{A:()=>M});var i,n,o=r(32198),s=r(40124),l=r(69540),a=r(51447),u=r(25482),p=r(53966),d=r(36708),c=r(24326),y=r(91429),f=r(12195),h=r(65864),g=r(50498),m=r(55156),w=r(60950),b=r(54339),v=r(94128),S=r(33910);const C=Symbol("meshGeometryHandles");function x(e){if(null==e)return null;let t={};for(let r in e){let i=e[r];i&&(t[r]=i.toJSON())}return 0===Object.keys(t).length?null:t}let M=class extends((0,l.OU)(u.o)){static{i=v.Z}static{n=this}constructor(e){super(e),this[i]=!0,this.distance=null,this.isAggregate=!1,this.layer=null,this.origin=null,this.sourceLayer=null,this.statisticsAggregatedIds=void 0,this._version=0,Object.defineProperty(this,"uid",{value:(0,c.c)(),configurable:!0}),Object.defineProperty(this,"_lastMeshTransform",{value:{},configurable:!0,writable:!0,enumerable:!1}),arguments.length>1&&(0,a.eF)(p.A.getLogger(this),"Graphic",{version:"4.30"})}set aggregateGeometries(e){let t=this._get("aggregateGeometries");JSON.stringify(t)!==JSON.stringify(e)&&this._set("aggregateGeometries",e)}set attributes(e){let t=this._get("attributes");t!==e&&(this._set("attributes",e),this._notifyLayer("attributes",t,e))}set geometry(e){let t=this._get("geometry");t!==e&&(this._set("geometry",e),this._watchMeshGeometryChanges(),this._notifyLayer("geometry",t,e))}set popupTemplate(e){let t=this._get("popupTemplate");t!==e&&(this._set("popupTemplate",e),this._notifyLayer("popupTemplate",t,e))}set symbol(e){let t=this._get("symbol");t!==e&&(this._set("symbol",e),this._notifyLayer("symbol",t,e))}get version(){return this._version}set visible(e){let t=this._get("visible");t!==e&&(this._set("visible",e),this._notifyLayer("visible",t,e))}cloneShallow(){return new n({aggregateGeometries:this.aggregateGeometries,statisticsAggregatedIds:this.statisticsAggregatedIds,attributes:this.attributes,geometry:this.geometry,isAggregate:this.isAggregate,layer:this.layer,popupTemplate:this.popupTemplate,sourceLayer:this.sourceLayer,symbol:this.symbol,visible:this.visible,origin:this.origin})}getEffectivePopupTemplate(e=!1){if(this.popupTemplate)return this.popupTemplate;let t=(0,w.E_)(this.origin);if(t)return t.popupTemplate??(e?t.defaultPopupTemplate:null)??null;let r=this.origin&&"layer"in this.origin?this.origin.layer:null;for(let t of[r,this.sourceLayer,this.layer])if(t&&"object"==typeof t){if("popupTemplate"in t&&t.popupTemplate)return t.popupTemplate;if(e&&"defaultPopupTemplate"in t&&null!=t.defaultPopupTemplate)return t.defaultPopupTemplate}return null}getAttribute(e){return this.attributes?.[e]}setAttribute(e,t){if(this.attributes){let r=this.getAttribute(e);this.attributes[e]=t,this._notifyLayer("attributes",r,t,e)}else this.attributes={[e]:t}}getObjectId(){let e=(0,m.I)(this.origin);if(e)return(0,b.r)(this,e);let t=this.sourceLayer??this.layer;return t?(0,b.r)(this,t):null}getGlobalId(){let e=(0,m.I)(this.origin);if(e?.globalIdField)return this.getAttribute(e.globalIdField);let t=this.sourceLayer??this.layer;return t&&"globalIdField"in t&&t.globalIdField?this.getAttribute(t.globalIdField):null}toJSON(){let e={aggregateGeometries:x(this.aggregateGeometries),geometry:this.geometry?.toJSON()??null,symbol:this.symbol?.toJSON()??null,attributes:(0,f.W)(this.attributes)?this.attributes.toJSON():{...this.attributes},popupTemplate:this.popupTemplate?.toJSON()??null};return this.statisticsAggregatedIds?.length&&(e.aggregateIds=[...this.statisticsAggregatedIds]),null!=this.distance&&(e.distance=this.distance),e}notifyMeshTransformChanged(e={}){let{geometry:t}=this;if("mesh"===t?.type){let r={origin:t.origin,transform:t.transform};this._notifyLayer("origin-transform",r,r,e.action)}}_notifyLayer(e,t,r,i){if(this._version++,!this.layer||!("graphicChanged"in this.layer))return;let n={graphic:this,property:e,oldValue:t,newValue:r};"origin-transform"===e&&(n.action=i),"attributes"===e&&(n.attributeName=i),this.layer.graphicChanged(n)}_watchMeshGeometryChanges(){this.removeHandles(C);let e=this.geometry;"mesh"===e?.type&&this.addHandles([(0,d.z7)(()=>e.vertexSpace.origin?{localMatrix:e.transform?.localMatrix,origin:e.vertexSpace.origin}:void 0,({localMatrix:e,origin:t})=>{(this._lastMeshTransform.localMatrix!==e||this._lastMeshTransform.origin!==t)&&(this._lastMeshTransform.localMatrix=e,this._lastMeshTransform.origin=t,this.notifyMeshTransformChanged())}),(0,d.z7)(()=>({vertexAttributes:e.vertexAttributes}),()=>{e.vertexSpace.origin?(this._lastMeshTransform.localMatrix=e.transform?.localMatrix,this._lastMeshTransform.origin=e.vertexSpace.origin):(this._lastMeshTransform.localMatrix=void 0,this._lastMeshTransform.origin=void 0),this._notifyLayer("geometry",e,e)},{equals:(e,t)=>e===t,sync:!0})],C)}};(0,o.Cg)([(0,y.MZ)({value:null,json:{read:function(e){if(!e)return null;let t={};for(let r in e){let i=(0,h.rS)(e[r]);i&&(t[r]=i)}return 0===Object.keys(t).length?null:t}}})],M.prototype,"aggregateGeometries",null),(0,o.Cg)([(0,y.MZ)({value:null})],M.prototype,"attributes",null),(0,o.Cg)([(0,y.MZ)({value:null,types:g.yR,json:{read:h.rS}})],M.prototype,"geometry",null),(0,o.Cg)([(0,y.MZ)()],M.prototype,"distance",void 0),(0,o.Cg)([(0,y.MZ)({type:Boolean})],M.prototype,"isAggregate",void 0),(0,o.Cg)([(0,y.MZ)({clonable:!1})],M.prototype,"layer",void 0),(0,o.Cg)([(0,y.MZ)({clonable:"reference"})],M.prototype,"origin",void 0),(0,o.Cg)([(0,y.MZ)({type:s.A,value:null})],M.prototype,"popupTemplate",null),(0,o.Cg)([(0,y.MZ)({clonable:"reference"})],M.prototype,"sourceLayer",void 0),(0,o.Cg)([(0,y.MZ)({json:{name:"aggregateIds",read:e=>e?.map(e=>Array.isArray(e)?JSON.stringify(e):e)}})],M.prototype,"statisticsAggregatedIds",void 0),(0,o.Cg)([(0,y.MZ)({value:null,types:S.Es})],M.prototype,"symbol",null),(0,o.Cg)([(0,y.MZ)({clonable:!1,json:{read:!1,write:!1}})],M.prototype,"_version",void 0),(0,o.Cg)([(0,y.MZ)({type:Boolean,value:!0})],M.prototype,"visible",null),M=n=(0,o.Cg)([(0,y.$K)("esri.Graphic")],M)},46140(e,t,r){r.d(t,{A:()=>n});var i=r(49186);class n{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}toString(){return`${this.major}.${this.minor}`}validate(e){if(this.major!==e.major){let t=this._context&&this._context+":",r=this._context&&this._context+" ";throw new i.A(t+"unsupported-version",`Required major ${r}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new n(this.major,this.minor,this._context)}static parse(e,t=""){let[r,o]=e.split("."),s=/^\s*\d+\s*$/;if(!r?.match||!s.test(r)){let r=t&&t+":";throw new i.A(r+"invalid-version","Expected major version to be a number, but got '${version}'",{version:e})}if(!o?.match||!s.test(o)){let r=t&&t+":";throw new i.A(r+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:e})}return new n(parseInt(r,10),parseInt(o,10),t)}}},6797(e,t,r){r.d(t,{Ui:()=>c});var i=r(69622),n=r(7762),o=r(88620);const s=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function l(e){return e instanceof i.A}function a(e){return e instanceof n.A?Object.keys(e.items):l(e)?(0,o.oY)(e).keys():e?Object.keys(e):[]}function u(e,t){return e instanceof n.A?e.items[t]:e[t]}function p(e){return e?e.declaredClass:null}function d(e,t){let r=e.diff;if(r&&"function"==typeof r)return r(e,t);let i=a(e),n=a(t);if(0===i.length&&0===n.length)return;if(!i.length||!n.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};let o=n.filter(e=>!i.includes(e)),c=i.filter(e=>!n.includes(e)),y=i.filter(r=>n.includes(r)&&u(e,r)!==u(t,r)).concat(o,c).sort(),f=p(e);if(f&&s.has(f)&&y.length)return{type:"complete",oldValue:e,newValue:t};let h,g=l(e)&&l(t);for(let i of y){let n,o=u(e,i),s=u(t,i);if((g||"function"!=typeof o&&"function"!=typeof s)&&o!==s&&(null!=o||null!=s)){if(r&&r[i]&&"function"==typeof r[i])n=r[i]?.(o,s);else if(o instanceof Date&&s instanceof Date){if(o.getTime()===s.getTime())continue;n={type:"complete",oldValue:o,newValue:s}}else n="object"==typeof o&&"object"==typeof s&&p(o)===p(s)?d(o,s):{type:"complete",oldValue:o,newValue:s};null!=n&&(null==h?h={type:"partial",diff:{[i]:n}}:h.diff[i]=n)}}return h}function c(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&p(e)!==p(t)?{type:"complete",oldValue:e,newValue:t}:d(e,t)}},67482(e,t,r){function i(e){return null!==n(e)}function n(e){return function(e){let t=o.exec(e);if(!t?.groups)return null;let r=t.groups,i=+r.year,n=r.month-1,s=+r.day,l=+(r.hours??"0"),a=+(r.minutes??"0"),u=+(r.seconds??"0");if(l>23||a>59||u>59)return null;let p,d=r.ms??"0",c=d?+d.padEnd(3,"0").slice(0,3):0;if(r.isUTC||!r.offsetSign)p=Date.UTC(i,n,s,l,a,u,c);else{let e=+r.offsetHours,t=+r.offsetMinutes;p=6e4*("+"===r.offsetSign?-1:1)*(60*e+t)+Date.UTC(i,n,s,l,a,u,c)}return Number.isNaN(p)?null:p}(e)??function(e){let t=new Date(e),r=t.getTime();return Number.isNaN(r)?null:e.toLowerCase()===t.toUTCString().toLowerCase()?r:null}(e)??function(e){if(!s.test(e))return null;let t=new Date(e);return Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset()}(e)}r.d(t,{C:()=>i,_:()=>n});const o=/^(?:(?<year>-?\d{4,})-(?<month>\d{2})-(?<day>\d{2}))(?:T(?<hours>\d{2}):(?<minutes>\d{2}):(?<seconds>\d{2})(?:\.(?<ms>\d+))?)?(?:(?<isUTC>Z)|(?:(?<offsetSign>\+|-)(?<offsetHours>\d{2}):(?<offsetMinutes>\d{2})))?$/,s=/^((\d{1,2}[/-]\d{1,2}[/-]\d{4})|(\d{4}[/-]\d{1,2}[/-]\d{1,2}))( \d{1,2}:\d{1,2}:\d{1,2}( ((AM)|(PM)))?)?$/i},69397(e,t,r){r.d(t,{Qf:()=>a,Qh:()=>s,lM:()=>o,ro:()=>u,rq:()=>p});var i=r(44208),n=r(34275);function o(e){if(!e)return 0;let t=d;for(let r in e)e.hasOwnProperty(r)&&(t+=l(e[r],!1));return t}function s(e){if(!e)return 0;if("number"==typeof e[0])return a(e);if(Array.isArray(e))return function(e){let t=e.length;if(0===t||"number"==typeof e[0])return p(e,8);let r=c;for(let i=0;i<t;i++)r+=l(e[i]);return r}(e);let t=d;for(let r in e)e.hasOwnProperty(r)&&(t+=l(e[r]));return t}function l(e,t=!0){switch(typeof e){case"object":return t?s(e):d;case"string":return function(e){return 32+e.length}(e);case"number":return 16;case"boolean":return 4;default:return 8}}function a(...e){return e.reduce((e,t)=>e+u(t),0)}function u(e,t=16){return e?(0,n.iu)(e)?e.byteLength+f:Array.isArray(e)?p(e,t):0:0}function p(e,t){return c+e.length*t}const d=32,c=16,y=(0,i.A)("ios")||!(0,i.A)("chrome")&&!(0,i.A)("opr")?8:4,f=145;r.d(t,["JY",0,y])},83027(e,t,r){const i=r(29953).ho;r.d(t,["h",0,i])},55156(e,t,r){r.d(t,{I:()=>n});const i=Symbol("idFieldsProviderSymbol");function n(e){return(t=e)&&i in t?e[i]:void 0;var t}r.d(t,["e",0,i])},21901(e,t,r){r.r(t),r.d(t,{default:()=>oe});var i=r(32198),n=r(40124),o=r(25728),s=r(93637),l=r(84952),a=r(91429),u=r(78888),p=r(5443),d=r(16930),c=r(50498),y=r(41910),f=r(55156),h=r(60950),g=r(89808),m=r(99959);const w=Symbol("isWFSGraphicOrigin");var b;class v extends m.A{get[(b=w,h.ym)](){return this.layer}get[f.e](){return this.layer}get[g.Q](){return this.layer}get[y.e7](){return this.layer}constructor(e){super(),this[b]=!0,this.type="wfs",this.layer=e}get id(){return this.layer.id}}var S=r(4146),C=r(49186),x=r(44208),M=r(92474),P=r(53966),A=r(17676),F=r(83027),T=r(64714),I=r(34322),O=r(37745),R=r(22671);r(98623);let Z=class extends M.x_{constructor(){super(...arguments),this._connection=null,this._workerHandler=null,this.capabilities=(0,T.f)(!1,!1),this.type="wfs",this.refresh=(0,A.sg)(async()=>{await this.load();let e={customParameters:this.layer.customParameters,maxRecordCount:this.layer.maxRecordCount,maxTotalRecordCount:this.layer.maxTotalRecordCount,maxPageCount:this.layer.maxPageCount},{extent:t}=await this._workerHandler.refresh(e);return t&&(this.sourceJSON.extent=t),{dataChanged:!0,updates:{extent:this.sourceJSON.extent}}})}load(e){let t=null==e?null:e.signal;return this.addResolvingPromise(this._startWorker({signal:t})),Promise.resolve(this)}destroy(){this._connection?.close(),this._connection=null,this._workerHandler=null}async openPorts(){return await this.load(),this._connection.openPorts()}async queryFeatures(e,t={}){let r=await this.queryFeaturesJSON(e,t);return R.A.fromJSON(r)}async queryFeaturesJSON(e,t={}){return await this.load(t),this._workerHandler.queryFeatures(e?e.toJSON():void 0,t)}async queryFeatureCount(e,t={}){return await this.load(t),this._workerHandler.queryFeatureCount(e?e.toJSON():void 0,t)}async queryObjectIds(e,t={}){return await this.load(t),this._workerHandler.queryObjectIds(e?e.toJSON():void 0,t)}async queryExtent(e,t={}){await this.load(t);let r=await this._workerHandler.queryExtent(e?e.toJSON():void 0,t);return{count:r.count,extent:p.A.fromJSON(r.extent)}}async querySnapping(e,t={}){return await this.load(t),this._workerHandler.querySnapping(e,t)}async queryAttributeBins(e,t={}){await this.load(t);let r=await this._workerHandler.queryAttributeBins(e?.toJSON(),t);return O.default.fromJSON(r)}async _createLoadOptions(e){let{url:t,customParameters:r,name:i,namespaceUri:n,fields:o,geometryType:s,maxRecordCount:l,maxPageCount:a,maxTotalRecordCount:u,swapXY:p}=this.layer,d="defaults"===this.layer.originOf("spatialReference")?void 0:this.layer.spatialReference;if(!t)throw new C.A("wfs-layer:missing-url","WFSLayer must be created with a url");this.wfsCapabilities||=await(0,I.Fu)(t,{customParameters:r,...e});let y=["fields","geometryType","name","namespaceUri","swapXY"].some(e=>null==this.layer[e])?await(0,I.O8)(this.wfsCapabilities,i,n,{spatialReference:d,customParameters:r,signal:e?.signal}):{...(0,I.YW)(o??[]),geometryType:s,name:i,namespaceUri:n,spatialReference:d,swapXY:p},f=(0,I.mG)(this.wfsCapabilities.readFeatureTypes(),y.name,y.namespaceUri),h=c.gy.toJSON(y.geometryType),{operations:g}=this.wfsCapabilities,m=g.GetFeature.url,w=g.GetFeature.outputFormat;return{customParameters:r,featureType:f,fields:y.fields?.map(e=>e.toJSON())??[],geometryField:y.geometryField,geometryType:h,getFeatureUrl:m,getFeatureOutputFormat:w,maxRecordCount:l,maxPageCount:a,maxTotalRecordCount:u,objectIdField:y.objectIdField,spatialReference:y.spatialReference?.toJSON(),swapXY:!!y.swapXY}}async _startWorker(e){let[t,r]=await(0,A.Lx)([this._createLoadOptions(e),(0,F.h)("WFSSourceWorker",{...e,strategy:(0,x.A)("feature-layers-workers")?"dedicated":"local",registryTarget:this})]),i=t.error||r.error||null,n=r.value||null;if(i)throw n&&n.close(),i;let o=t.value;this._connection=r.value,this._workerHandler=this._connection.createInvokeProxy();let s=await this._workerHandler.load(o,e);for(let e of s.warnings)P.A.getLogger(this.layer).warn("#load()",`${e.message} (title: '${this.layer.title||"no title"}', id: '${this.layer.id??"no id"}')`,{warning:e});this.sourceJSON={dateFieldsTimeReference:{timeZoneIANA:"UTC"},extent:s.extent,fields:o.fields,geometryType:o.geometryType,objectIdField:o.objectIdField,geometryField:o.geometryField,drawingInfo:(0,T.F0)(o.geometryType),name:o.featureType.title,wfsInfo:{name:o.featureType.name,featureUrl:o.getFeatureUrl,maxFeatures:o.maxRecordCount,swapXY:o.swapXY,supportedSpatialReferences:o.featureType.supportedSpatialReferences,version:"2.0.0",wfsNamespace:o.featureType.namespaceUri}}}};(0,i.Cg)([(0,a.MZ)()],Z.prototype,"capabilities",void 0),(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],Z.prototype,"layer",void 0),(0,i.Cg)([(0,a.MZ)()],Z.prototype,"sourceJSON",void 0),(0,i.Cg)([(0,a.MZ)()],Z.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)()],Z.prototype,"wfsCapabilities",void 0),Z=(0,i.Cg)([(0,a.$K)("esri.layers.graphics.sources.WFSSource")],Z);var j,E=r(63074),L=r(69208),N=r(6455),_=r(87718),G=r(56658),k=r(34287),q=r(32756),U=r(8303),D=r(54310),$=r(25036),z=r(82935),J=r(10873),B=r(15426),H=r(20437),V=r(17036),W=r(30524),Q=r(46499),Y=r(39383),K=r(41214),X=r(97552),ee=r(30291),te=r(56400),re=r(43937);const ie=(0,V.p)();let ne=j=class extends((0,q.fY)((0,N.FJ)((0,L.d)((0,G.J)((0,_.F)((0,E.dM)((0,D.J)((0,$.j)((0,k.q)((0,U.A)((0,o.M)(S.A)))))))))))){static fromWFSLayerInfo(e){let{customParameters:t,fields:r,geometryField:i,geometryType:n,name:o,namespaceUri:s,objectIdField:l,spatialReference:a,swapXY:u,url:p,wfsCapabilities:d}=e;return new j({customParameters:t,fields:r,geometryField:i,geometryType:n,name:o,namespaceUri:s,objectIdField:l,spatialReference:a,swapXY:u,url:p,wfsCapabilities:d})}constructor(e){super(e),this.copyright=null,this.customParameters=null,this.dateFieldsTimeZone=null,this.definitionExpression=null,this.displayField=null,this.elevationInfo=null,this.featureUrl=void 0,this.fields=null,this.fieldsIndex=null,this.fullExtent=null,this.geometryType=null,this.graphicOrigin=new v(this),this.labelsVisible=!0,this.labelingInfo=null,this.legendEnabled=!0,this.objectIdField=null,this.operationalLayerType="WFS",this.maxRecordCount=3e3,this.maxPageCount=10,this.maxTotalRecordCount=2e5,this.mode=0,this.name=null,this.namespaceUri=null,this.outFields=null,this.popupEnabled=!0,this.popupTemplate=null,this.screenSizePerspectiveEnabled=!0,this.source=new Z({layer:this}),this.spatialReference=d.A.WGS84,this.spatialReferences=[4326],this.swapXY=void 0,this.title="WFS",this.type="wfs",this.url=null,this.useViewTime=!0,this.version=void 0}destroy(){this.source?.destroy()}load(e){return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["WFS"]},e).then(()=>this.source.load(e)).then(()=>{this.read(this.source.sourceJSON,{origin:"service",url:this.parsedUrl}),["objectIdField","fields","spatialReference","name","namespaceUri"].forEach(e=>this.revertToOrigin(e,"service")),(0,W.yp)(this.renderer,this.fieldsIndex)})),Promise.resolve(this)}get capabilities(){return this.source?.capabilities}get createQueryVersion(){return this.commitProperty("definitionExpression"),this.commitProperty("geometryType"),this.commitProperty("capabilities"),(this._get("createQueryVersion")||0)+1}get defaultPopupTemplate(){return this.createPopupTemplate()}writeFields(e,t,r){let i=e.filter(e=>e.name!==I.i5);this.geometryField&&i.unshift(new H.A({name:this.geometryField,alias:this.geometryField,type:"geometry"})),(0,s.sM)(r,i.map(e=>e.toJSON()),t)}get parsedUrl(){return(0,l.An)(this.url)}set renderer(e){(0,W.yp)(e,this.fieldsIndex),this._set("renderer",e)}get wfsCapabilities(){return this.source?.wfsCapabilities}set wfsCapabilities(e){this.source&&(this.source.wfsCapabilities=e)}createPopupTemplate(e){return(0,ee.tn)(this,e)}createQuery(){return new X.A({returnGeometry:!0,outFields:["*"],where:this.definitionExpression||"1=1"})}getFieldDomain(e,t){return this.getField(e)?.domain}getField(e){return this.fieldsIndex?.get(e)}queryFeatures(e,t){return this.load().then(()=>this.source.queryFeatures(X.A.from(e)||this.createQuery(),t)).then(e=>{if(e?.features)for(let t of e.features)t.layer=t.sourceLayer=this,t.origin=this.graphicOrigin;return e})}queryObjectIds(e,t){return this.load().then(()=>this.source.queryObjectIds(X.A.from(e)||this.createQuery(),t))}queryFeatureCount(e,t){return this.load().then(()=>this.source.queryFeatureCount(X.A.from(e)||this.createQuery(),t))}queryExtent(e,t){return this.load().then(()=>this.source.queryExtent(X.A.from(e)||this.createQuery(),t))}async queryAttributeBins(e,t){let{source:i,capabilities:n}=await this.load();(0,B.ZJ)(e,n,"WFSLayer");let o=await r.e(4575).then(()=>r(14575)),s=await i.queryAttributeBins(o.default.from(e),t);if(s.features)for(let e of s.features)e.layer=e.sourceLayer=this;return s}async hasDataChanged(){try{let{dataChanged:e,updates:t}=await this.source.refresh();return null!=t&&this.read(t,{origin:"service",url:this.parsedUrl,ignoreDefaults:!0}),e}catch{}return!1}};(0,i.Cg)([(0,a.MZ)({readOnly:!0})],ne.prototype,"capabilities",null),(0,i.Cg)([(0,a.MZ)({type:String})],ne.prototype,"copyright",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],ne.prototype,"createQueryVersion",null),(0,i.Cg)([(0,a.MZ)({json:{name:"wfsInfo.customParameters",write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0),ignoreOrigin:!0})}}})],ne.prototype,"customParameters",void 0),(0,i.Cg)([(0,a.MZ)((0,te.P6)("dateFieldsTimeReference"))],ne.prototype,"dateFieldsTimeZone",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],ne.prototype,"defaultPopupTemplate",null),(0,i.Cg)([(0,a.MZ)({type:String,json:{name:"layerDefinition.definitionExpression",write:{enabled:!0,allowNull:!0}}})],ne.prototype,"definitionExpression",void 0),(0,i.Cg)([(0,a.MZ)({type:String})],ne.prototype,"displayField",void 0),(0,i.Cg)([(0,a.MZ)(J.Yj)],ne.prototype,"elevationInfo",void 0),(0,i.Cg)([(0,a.MZ)({type:String,readOnly:!0,json:{name:"wfsInfo.featureUrl",write:{ignoreOrigin:!0,isRequired:!0}}})],ne.prototype,"featureUrl",void 0),(0,i.Cg)([(0,a.MZ)({type:[H.A],json:{name:"layerDefinition.fields",write:{ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"fields"}}}})],ne.prototype,"fields",void 0),(0,i.Cg)([(0,re.K)("fields")],ne.prototype,"writeFields",null),(0,i.Cg)([(0,a.MZ)(ie.fieldsIndex)],ne.prototype,"fieldsIndex",void 0),(0,i.Cg)([(0,a.MZ)({type:p.A,json:{name:"extent"}})],ne.prototype,"fullExtent",void 0),(0,i.Cg)([(0,a.MZ)()],ne.prototype,"geometryField",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{read:{source:"layerDefinition.geometryType",reader:c.gy.read},write:{target:"layerDefinition.geometryType",writer:c.gy.write,ignoreOrigin:!0},origins:{service:{read:c.gy.read}}}})],ne.prototype,"geometryType",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0,clonable:!1})],ne.prototype,"graphicOrigin",void 0),(0,i.Cg)([(0,a.MZ)({type:String})],ne.prototype,"id",void 0),(0,i.Cg)([(0,a.MZ)(J.kF)],ne.prototype,"labelsVisible",void 0),(0,i.Cg)([(0,a.MZ)({type:[Q.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:{reader:Y.w},write:!0}})],ne.prototype,"labelingInfo",void 0),(0,i.Cg)([(0,a.MZ)(J.fV)],ne.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,a.MZ)({type:["show","hide"]})],ne.prototype,"listMode",void 0),(0,i.Cg)([(0,a.MZ)({type:String})],ne.prototype,"objectIdField",void 0),(0,i.Cg)([(0,a.MZ)({type:["WFS"]})],ne.prototype,"operationalLayerType",void 0),(0,i.Cg)([(0,a.MZ)({type:u.jz,json:{name:"wfsInfo.maxFeatures",write:{ignoreOrigin:!0,isRequired:!0}}})],ne.prototype,"maxRecordCount",void 0),(0,i.Cg)([(0,a.MZ)({type:u.jz})],ne.prototype,"maxPageCount",void 0),(0,i.Cg)([(0,a.MZ)({type:u.jz})],ne.prototype,"maxTotalRecordCount",void 0),(0,i.Cg)([(0,a.MZ)({type:[0],readOnly:!0,json:{origins:{"web-map":{write:{ignoreOrigin:!0,isRequired:!0}}}}})],ne.prototype,"mode",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{name:"wfsInfo.name",write:{ignoreOrigin:!0,isRequired:!0}}})],ne.prototype,"name",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{name:"wfsInfo.wfsNamespace",write:{ignoreOrigin:!0,isRequired:!0}}})],ne.prototype,"namespaceUri",void 0),(0,i.Cg)([(0,a.MZ)(J.Ih)],ne.prototype,"opacity",void 0),(0,i.Cg)([(0,a.MZ)(ie.outFields)],ne.prototype,"outFields",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],ne.prototype,"parsedUrl",null),(0,i.Cg)([(0,a.MZ)(J.M6)],ne.prototype,"popupEnabled",void 0),(0,i.Cg)([(0,a.MZ)({type:n.A,json:{name:"popupInfo",write:!0}})],ne.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,a.MZ)({types:K.Hg,json:{origins:{service:{name:"drawingInfo.renderer"},"web-scene":{types:K.XJ,name:"layerDefinition.drawingInfo.renderer",write:!0}},name:"layerDefinition.drawingInfo.renderer",write:{ignoreOrigin:!0}}})],ne.prototype,"renderer",null),(0,i.Cg)([(0,a.MZ)(J.PY)],ne.prototype,"screenSizePerspectiveEnabled",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],ne.prototype,"source",void 0),(0,i.Cg)([(0,a.MZ)({type:d.A,json:{name:"layerDefinition.spatialReference",write:{ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"extent.spatialReference"}}}})],ne.prototype,"spatialReference",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0,type:[u.jz],json:{name:"wfsInfo.supportedSpatialReferences",write:{ignoreOrigin:!0,isRequired:!0}}})],ne.prototype,"spatialReferences",void 0),(0,i.Cg)([(0,a.MZ)({type:Boolean,value:!1,json:{name:"wfsInfo.swapXY",write:{ignoreOrigin:!0,isRequired:!0}}})],ne.prototype,"swapXY",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:{ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"name"}}}})],ne.prototype,"title",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!1},readOnly:!0})],ne.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)(J.OZ)],ne.prototype,"url",void 0),(0,i.Cg)([(0,a.MZ)(z.B)],ne.prototype,"useViewTime",void 0),(0,i.Cg)([(0,a.MZ)({type:String,readOnly:!0,json:{name:"wfsInfo.version",write:{ignoreOrigin:!0,isRequired:!0}}})],ne.prototype,"version",void 0),(0,i.Cg)([(0,a.MZ)()],ne.prototype,"wfsCapabilities",null),ne=j=(0,i.Cg)([(0,a.$K)("esri.layers.WFSLayer")],ne);const oe=ne},43334(e,t,r){r.d(t,{N3:()=>l,Om:()=>s});var i=r(69397),n=r(27647),o=r(92722);class s{constructor(e,t,r,i,n=0,o=null,s=null){this.geometry=e,this.attributes=t,this.centroid=r,this.objectId=i,this.displayId=n,this.distance=o,this.vertexCount=s}static fromJSON(e){let t=e.geometry?o.A.fromJSON(e.geometry):null,r=e.centroid?o.A.fromJSON(e.centroid):null,i=e.objectId;return new s(t,e.attributes,r,i,void 0,e.distance,e.vertexCount)}weakClone(){return new s(this.geometry,this.attributes,this.centroid,this.objectId,this.displayId,this.distance,this.vertexCount)}clone(){return new s(this.geometry?.clone(),{...this.attributes},this.centroid?.clone(),this.objectId,this.displayId,this.distance,this.vertexCount)}ensureCentroid(e){return this.centroid??=(0,n.Q)(this.geometry),this.centroid}get usedMemory(){return 128+(0,i.lM)(this.attributes)+(this.geometry?.usedMemory??0)}}function l(e){return!!e.geometry?.coords?.length}},58512(e,t,r){r.d(t,{A:()=>i});class i{constructor(){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(){let e=new i;return 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}}},92722(e,t,r){r.d(t,{A:()=>n});var i=r(69397);class n{constructor(e=[],t=[],r=!1,i=!1){this.lengths=e??[],this.coords=t??[],this.hasZ=r,this.hasM=i}static fromJSON({lengths:e,coords:t,hasZ:r,hasM:i}){return new n(e,t,r||!1,i||!1)}static fromRect([e,t,r,i]){let o=r-e,s=i-t;return new n([5],[e,t,o,0,0,s,-o,0,0,-s])}get isPoint(){return 0===this.lengths.length&&this.coords.length>=2}get maxLength(){return Math.max(...this.lengths)}get size(){return this.isPoint?1:this.lengths.reduce((e,t)=>e+t,0)}get usedMemory(){return 64+(0,i.Qf)(this.lengths,this.coords)}get stride(){return+!!this.hasZ+2+ +!!this.hasM}area(){if(this.isPoint)return 0;let e=0,t=0;for(let r of this.lengths){if(r<3)continue;let{stride:i}=this,n=this.coords[i*t],o=this.coords[i*t+1];for(let s=1;s<r;s+=1){let r=i*(t+s),l=this.coords[r],a=this.coords[r+1];e+=-.5*(l-n)*(a+o),n=l,o=a}t+=r}return e}forEachVertex(e){let t=0;if(this.isPoint)return e(this.coords[0],this.coords[1]);let{stride:r}=this;for(let i of this.lengths){for(let n=0;n<i;n++){let i=r*(t+n);e(this.coords[i],this.coords[i+1])}t+=i}}deltaDecode(){let e=this.clone(),{coords:t,lengths:r}=e,i=0,{stride:n}=this;for(let e of r){for(let r=1;r<e;r++){let e=n*(i+r);t[e]+=t[e-n],t[e+1]+=t[e+1-n]}i+=e}return e}clone(e){if(this.isPoint)return new n([],Array.from(this.coords.slice(0,this.stride)),this.hasZ,this.hasM);let t=Array.from(this.lengths),{stride:r,size:i}=this,o=this.coords.slice(0,i*r);return e?(e.set(o),new n(t,e,this.hasZ,this.hasM)):new n(t,Array.from(o),this.hasZ,this.hasM)}justXY(){let{stride:e,size:t}=this;if(2===e)return this;let r=Array(t*e);for(let t=0,i=0;t<r.length;t+=e)r[i++]=this.coords[t],r[i++]=this.coords[t+1];return new n(this.lengths,r,!1,!1)}}},27647(e,t,r){r.d(t,{Q:()=>o});var i=r(92722);function n(e,t){return e?t?4:3:t?3:2}function o(e){if(null==e||!e?.lengths.length)return null;let{lengths:t,coords:r,stride:n,hasZ:o,hasM:a}=e,u=new i.A([],[],o,!1),p=u.coords,d=[],c=o?[1/0,-1/0,1/0,-1/0,1/0,-1/0]:[1/0,-1/0,1/0,-1/0],y=0;for(let e of t){let t=s(c,r,y,e,o,a);t&&d.push(t),y+=e*n}if(d.sort((e,t)=>{let r=e[2]-t[2];return 0===r&&o&&(r=e[4]-t[4]),r}),d.length){let e=6*d[0][2];p[0]=d[0][0]/e,p[1]=d[0][1]/e,o&&(e=6*d[0][4],p[2]=0===e?0:d[0][3]/e),(p[0]<c[0]||p[0]>c[1]||p[1]<c[2]||p[1]>c[3]||o&&(p[2]<c[4]||p[2]>c[5]))&&(p.length=0)}if(!p.length){let i=e.lengths[0]?l(r,0,t[0],o,a):null;if(!i)return null;p[0]=i[0],p[1]=i[1],o&&(p[2]=i[2]??0)}return u}function s(e,t,r,i,o,s){let l=n(o,s),a=r,u=r+l,p=0,d=0,c=0,y=0,f=0;for(let r=0,n=i-1;r<n;r++,a+=l,u+=l){let r=t[a],i=t[a+1],n=t[a+2],s=t[u],l=t[u+1],h=t[u+2],g=r*l-s*i;y+=g,p+=(r+s)*g,d+=(i+l)*g,o&&(g=r*h-s*n,c+=(n+h)*g,f+=g),r<e[0]&&(e[0]=r),r>e[1]&&(e[1]=r),i<e[2]&&(e[2]=i),i>e[3]&&(e[3]=i),o&&(n<e[4]&&(e[4]=n),n>e[5]&&(e[5]=n))}if(y>0&&(y*=-1),f>0&&(f*=-1),!y)return null;let h=[p,d,.5*y];return o&&(h[3]=c,h[4]=.5*f),h}function l(e,t,r,i,o){let s=n(i,o),l=t,c=t+s,y=0,f=0,h=0,g=0;for(let t=0,n=r-1;t<n;t++,l+=s,c+=s){let t=e[l],r=e[l+1],n=e[l+2],o=e[c],s=e[c+1],m=e[c+2],w=i?u(t,r,n,o,s,m):a(t,r,o,s);if(w)if(y+=w,i){let e=d(t,r,n,o,s,m);f+=w*e[0],h+=w*e[1],g+=w*e[2]}else{let e=p(t,r,o,s);f+=w*e[0],h+=w*e[1]}}return y>0?i?[f/y,h/y,g/y]:[f/y,h/y]:r>0?i?[e[t],e[t+1],e[t+2]]:[e[t],e[t+1]]:null}function a(e,t,r,i){let n=r-e,o=i-t;return Math.sqrt(n*n+o*o)}function u(e,t,r,i,n,o){let s=i-e,l=n-t,a=o-r;return Math.sqrt(s*s+l*l+a*a)}function p(e,t,r,i){return[e+.5*(r-e),t+.5*(i-t)]}function d(e,t,r,i,n,o){return[e+.5*(i-e),t+.5*(n-t),r+.5*(o-r)]}},99352(e,t,r){r.d(t,["F",0,{supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!0,supportedSpatialAggregationStatistics:{envelope:!0,centroid:!0,convexHull:!0},supportsStatisticsAggregatedIds:!0,supportsCentroid:!0,supportsCentroidOnDegeneratedQuantizedGeometry:!0,supportsCacheHint:!0,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDistance:!0,supportsOutDistance:!1,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsPaginationOnAggregatedQueries:!1,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!0,supportsReturnMesh:!1,supportsReturnExceededLimitGeometries:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsFormatPBFWithCurves:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,maxUniqueIDCount:void 0,relativeTimeBinWindow:0,standardMaxRecordCount:void 0,standardMaxRecordCountNoGeometry:void 0,tileMaxRecordCount:void 0,supportsTrueCurve:!1},"P",0,{supportsDate:!0,supportsFixedInterval:!0,supportsAutoInterval:!0,supportsFixedBoundaries:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!0,supportedStatistics:{count:!0,sum:!0,avg:!0,var:!0,stddev:!0,min:!0,max:!0,percentileContinuous:!0,percentileDiscrete:!0,envelope:!0,centroid:!0,convexHull:!0},supportedNormalizationTypes:{field:!0,log:!0,naturalLog:!0,percentOfTotal:!0,squareRoot:!0}}])},54339(e,t,r){function i(e,t){switch(t.type){case"object-id":case"unique-id-simple":return e.attributes[t.fieldName];case"unique-id-composite":{let r=[];for(let i of t.fieldNames)r.push(e.attributes[i]??null);return JSON.stringify(r)}}}function n(e,t){if("uniqueIdFields"in t&&t.uniqueIdFields?.length){if(1===t.uniqueIdFields.length)return e.attributes?.[t.uniqueIdFields[0]];let r=t.uniqueIdFields.map(t=>e.attributes?.[t]);return JSON.stringify(r)}return"objectIdField"in t&&t.objectIdField?e.attributes?.[t.objectIdField]:null}r.d(t,{W:()=>i,r:()=>n})},90708(e,t,r){r.d(t,{Ap:()=>F,B2:()=>g,DF:()=>C,Di:()=>j,E2:()=>Z,IE:()=>h,Nl:()=>U,PR:()=>P,Rk:()=>V,Ux:()=>L,Ye:()=>I,ZF:()=>G,aQ:()=>B,jH:()=>q,jQ:()=>J,kz:()=>D,oN:()=>E,q3:()=>k,qN:()=>x,zv:()=>N});var i=r(49186),n=r(53966),o=r(97768),s=r(70328),l=r(19419),a=r(60408),u=r(43334),p=r(58512),d=r(92722),c=r(54339);const y=()=>n.A.getLogger("esri.layers.graphics.featureConversionUtils"),f={esriGeometryPoint:0,esriGeometryPolyline:2,esriGeometryPolygon:3,esriGeometryMultipoint:0,esriGeometryMultiPatch:3,esriGeometryEnvelope:0};function h({scale:e,translate:t},r){return Math.round((r-t[0])/e[0])}function g({scale:e,translate:t},r){return Math.round((t[1]-r)/e[1])}function m({scale:e,translate:t},r){return Math.round((r-t[0])/e[0])}function w({scale:e,translate:t},r){return Math.round((r-t[1])/e[1])}function b({scale:e,translate:t},r,i){return r*e[i]+t[i]}function v(e,t,r){return t&&(e.hasZ=!0),r&&(e.hasM=!0),e}function S(e,t,r,i){if(t&&i&&e!==r)return(t,r,i,n)=>{i[n++]=t[r++],i[n++]=t[r++],e?r++:i[n++]=0,i[n++]=t[r++]??0};let n=+!!r+2+ +!!i,o=n-((!e&&r?1:0)+(!t&&i?1:0));return(e,t,r,i)=>{for(let s=0;s<n;++s)r[i++]=s<o?e[t++]??0:0}}function C(e,t,r){if(!e)return null;let{coords:i,hasZ:n,hasM:o}=e,[s,l]=i,a=n?i[2]:0,u=o?i[+!!n+2]:0;return{x:s,y:l,z:t?a:void 0,m:r?u:void 0}}function x(e,t=(0,a.Pv)(e),r=(0,a.W0)(e)){let{x:i,y:n,z:o,m:s}=e,l=[i,n];return t&&l.push(o??0),r&&l.push(s??0),new d.A([],l,t,r)}function M(e,t,r){if(null==e)return null;let{coords:i,stride:n,hasZ:o,hasM:s}=e,l=S(o,s,t,r),a=[];for(let e=0;e<i.length;e+=n){let t=[];l(i,e,t,0),a.push(t)}return v({points:a},t,r)}function P(e,t=(0,a.Pv)(e),r=(0,a.W0)(e)){let{points:i,hasZ:n,hasM:o}=e,s=new d.A([i.length],[],t,r),{coords:l,stride:u}=s,p=0,c=S(n??!1,o??!1,t,r);for(let e of i)c(e,0,l,p),p+=u;return s}function A(e,t,r){if(!e)return null;let{coords:i,lengths:n,stride:o,hasZ:s,hasM:l}=e,a=0,u=S(s,l,t,r),p=[];for(let e of n){let t=[];for(let r=0;r<e;r++){let e=[];u(i,a,e,0),a+=o,t.push(e)}p.push(t)}return v({paths:p},t,r)}function F(e,t=(0,a.Pv)(e),r=(0,a.W0)(e)){let{paths:i,hasZ:n,hasM:o}=e,s=S(n??!1,o??!1,t,r),l=new d.A([],[],t,r),{lengths:u,coords:p,stride:c}=l,y=0;for(let e of i){for(let t of e)s(t,0,p,y),y+=c;u.push(e.length)}return l}function T(e,t,r){if(!e)return null;let{coords:i,lengths:n,stride:o,hasZ:s,hasM:l}=e,a=0,u=S(s,l,t,r),p=[];for(let e of n){let t=[];for(let r=0;r<e;r++){let e=[];u(i,a,e,0),a+=o,t.push(e)}p.push(t)}return v({rings:p},t,r)}function I(e,t=(0,a.Pv)(e),r=(0,a.W0)(e)){let{rings:i,hasZ:n,hasM:o}=e,s=new d.A([],[],t,r),{lengths:l,coords:u,stride:p}=s,c=0,y=S(n??!1,o??!1,t,r);for(let e of i){for(let t of e)y(t,0,u,c),c+=p;l.push(e.length)}return s}const O=[],R=[];function Z(e,t,r,i,n){O[0]=e;let[o]=j(R,O,t,r,i,n);return W(O),W(R),o}function j(e,t,r,n,o,s){if(W(e),!r){for(let r of t){let t=(0,c.W)(r,s);e.push(new u.Om(null,r.attributes,null,t,void 0,r.distance,r.vertexCount))}return e}switch(r){case"esriGeometryPoint":return function(e,t,r,i,n){for(let o of t){let{geometry:t,attributes:s,centroid:l}=o,p=(0,a.Pv)(t),d=(0,a.W0)(t);e.push(new u.Om(t?x(t,r&&p,i&&d):null,s,l?x(l,!1,!1):null,(0,c.W)(o,n),o.displayId,o.distance,o.vertexCount))}return e}(e,t,n,o,s);case"esriGeometryMultipoint":return function(e,t,r,i,n){for(let o of t){let{geometry:t,attributes:s}=o,l=(0,a.Pv)(t),p=(0,a.W0)(t);e.push(new u.Om(t?P(t,r&&l,i&&p):null,s,null,(0,c.W)(o,n),o.displayId,o.distance,o.vertexCount))}return e}(e,t,n,o,s);case"esriGeometryPolyline":return function(e,t,r,i,n){for(let o of t){let{geometry:t,attributes:s,centroid:l}=o,p=(0,a.Pv)(t),d=(0,a.W0)(t);e.push(new u.Om(t?F(t,r&&p,i&&d):null,s,l?x(l,!1,!1):null,(0,c.W)(o,n),o.displayId,o.distance,o.vertexCount))}return e}(e,t,n,o,s);case"esriGeometryPolygon":case"esriGeometryMultiPatch":return function(e,t,r,i,n){for(let o of t){let{geometry:t,attributes:s,centroid:l}=o,p=(0,a.Pv)(t),d=(0,a.W0)(t);e.push(new u.Om(t?I(t,r&&p,i&&d):null,s,l?x(l,!1,!1):null,(0,c.W)(o,n),o.displayId,o.distance,o.vertexCount))}return e}(e,t,n,o,s);default:y().error("convertToFeatureSet:unknown-geometry",new i.A("internal:geometry",`Unable to parse unknown geometry type '${r}'`)),W(e)}return e}function E(e,t,r,i){R[0]=e,_(O,R,t,r,i);let n=O[0];return W(O),W(R),n}function L(e,t=(0,a.Pv)(e),r=(0,a.W0)(e)){return null==e?null:(0,a.fT)(e)?x(e,t,r):(0,a.Bi)(e)?I(e,t,r):(0,a.Rg)(e)?F(e,t,r):(0,a.U9)(e)?P(e,t,r):void y().error("convertFromGeometry:unknown-geometry",new i.A("internal:geometry",`Unable to parse unknown geometry type '${e}'`))}function N(e,t,r,n){if(null==e)return null;let o="coords"in e?e:e.geometry;if(null==o)return null;switch(t){case"esriGeometryPoint":return C(o,r,n);case"esriGeometryMultipoint":return M(o,r,n);case"esriGeometryPolyline":return A(o,r,n);case"esriGeometryPolygon":return T(o,r,n);default:return y().error("convertToGeometry:unknown-geometry",new i.A("internal:geometry",`Unable to parse unknown geometry type '${t}'`)),null}}function _(e,t,r,n,o){if(W(e),null==r)return function(e,t){for(let r of t)e.push({attributes:r.attributes});return e}(e,t);switch(r){case"esriGeometryPoint":return function(e,t,r,i){for(let{geometry:n,attributes:o}of t)e.push({attributes:o,geometry:C(n,r,i)});return e}(e,t,n,o);case"esriGeometryMultipoint":return function(e,t,r,i){for(let{geometry:n,attributes:o}of t)e.push({geometry:n&&M(n,r,i),attributes:o});return e}(e,t,n,o);case"esriGeometryPolyline":return function(e,t,r,i){for(let{geometry:n,attributes:o}of t)e.push({geometry:n&&A(n,r,i),attributes:o});return e}(e,t,n,o);case"esriGeometryPolygon":return function(e,t,r,i){for(let{geometry:n,attributes:o,centroid:s}of t){let t=T(n,r,i),l=C(s,!1,!1);e.push(s?{geometry:t,attributes:o,centroid:l}:{geometry:t,attributes:o})}return e}(e,t,n,o);default:y().error("convertToFeatureSet:unknown-geometry",new i.A("internal:geometry",`Unable to parse unknown geometry type '${r}'`))}return e}function G(e){let{spatialReference:t,transform:r,fields:i,hasM:n,hasZ:o,features:s,geometryType:l,exceededTransferLimit:a,queryGeometry:u,queryGeometryType:p}=e,d={features:_([],s,l,o,n),fields:i,geometryType:l,spatialReference:t,queryGeometry:N(u,p,o,n)};return r&&(d.transform=r),a&&(d.exceededTransferLimit=a),n&&(d.hasM=n),o&&(d.hasZ=o),d}function k(e,t){let r=new p.A,{hasM:i,hasZ:n,features:o,spatialReference:s,geometryType:l,exceededTransferLimit:a,transform:u,fields:d,globalIdFieldName:c}=e;return d&&(r.fields=d),r.geometryType=l??null,r.spatialReference=s??null,o&&j(r.features,o,l,n,i,t),a&&(r.exceededTransferLimit=a),i&&(r.hasM=i),n&&(r.hasZ=n),u&&(r.transform=u),c&&(r.globalIdFieldName=c),r}function q(e,t){let{geometryType:r,features:i}=t;if(!e)return t;for(let t=0;t<i.length;t++){let n=i[t],o=n.weakClone();o.geometry=U(n.geometry,r,e),o.centroid=U(n.centroid,"esriGeometryPoint",e),i[t]=o}return t.transform=e,t}function U(e,t,r,i,n,o=!1){if(null==e||!e?.coords.length)return null;let s=f[t],{coords:l,lengths:a,stride:u,hasZ:p,hasM:c}=e;i??=p,n??=c;let y=new d.A([],[],i,n),b=y.stride,v=S(p,c,i,n),C=0,x=[0,0,0,0].slice(b),M=o?m:h,P=o?w:g;function A(){v(l,C,x,0),C+=u,x[0]=M(r,x[0]),x[1]=P(r,x[1])}if(e.isPoint)return A(),y.coords.push(...x),y;let F=0;for(let e of a){if(e<s)continue;let t=1;A(),y.coords.push(...x);let[r,i]=x;for(let n=1;n<e;n++){A();let[e,n]=x;(r!==e||i!==n)&&(o||(x[0]-=r,x[1]-=i),y.coords.push(...x),r=e,i=n,t++)}t>=s?(y.lengths.push(t),F=y.coords.length):W(y.coords,F)}return W(y.coords,F),y.coords.length?y:null}function D(e,t,r,i=e.hasZ,n=e.hasM){if(!e.coords.length)return null;let o=f[t],{coords:s,lengths:l,stride:a,hasZ:u,hasM:p}=e,c=new d.A([],[],i,n),y=c.stride,h=S(u,p,i,n);if(e.isPoint)return h(s,0,c.coords,0),c;let g=0,m=r*r;for(let e of l){if(e<o){g+=e*a;continue}let t=c.coords.length/y,r=g,i=g+(e-1)*a;h(s,r,c.coords,c.coords.length),z(c.coords,s,a,m,h,r,i),h(s,i,c.coords,c.coords.length);let n=c.coords.length/y-t;n>=o?c.lengths.push(n):W(c.coords,t*y),g+=e*a}return c.coords.length?c:null}function $(e,t,r,i){let n=e[t],o=e[t+1],s=e[r],l=e[r+1],a=e[i],u=e[i+1],p=s,d=l,c=a-p,y=u-d;if(0!==c||0!==y){let e=((n-p)*c+(o-d)*y)/(c*c+y*y);e>1?(p=a,d=u):e>0&&(p+=c*e,d+=y*e)}return c=n-p,y=o-d,c*c+y*y}function z(e,t,r,i,n,o,s){let l,a=i,u=0;for(let e=o+r;e<s;e+=r)l=$(t,e,o,s),l>a&&(u=e,a=l);a>i&&(u-o>r&&z(e,t,r,i,n,o,u),n(t,u,e,e.length),s-u>r&&z(e,t,r,i,n,u,s))}function J(e,t){if(!t?.coords?.length)return null;let r=1/0,i=1/0,n=-1/0,o=-1/0,{coords:a,stride:u}=t;for(let e=0;e<a.length;e+=u){let t=a[e],s=a[e+1];r=Math.min(r,t),n=Math.max(n,t),i=Math.min(i,s),o=Math.max(o,s)}return(0,s.is)(e)?(0,s.BI)(e,r,i,n,o):(0,l.fA)(r,i,n,o,e),e}function B(e,t){let{coords:r,lengths:i,stride:n,hasZ:s,hasM:l}=e;if(!r.length)return void(i.length=0);(0,o.Lw)(t);let{originPosition:a,scale:u,translate:p}=t,d=Q;d.originPosition=a;let c=d.scale;c[0]=u[0]??1,c[1]=-(u[1]??1),c[2]=u[2]??1,c[3]=u[3]??1;let y=d.translate;if(y[0]=p[0]??0,y[1]=p[1]??0,y[2]=p[2]??0,y[3]=p[3]??0,l&&!s&&(c[2]=c[3],y[2]=y[3]),!i.length){for(let e=0;e<n;++e)r[e]=b(d,r[e],e);return void(i.length=0)}let f=0;for(let e=0;e<i.length;e++){let t=i[e];i[e]=t;for(let e=0;e<n;++e)r[f+e]=b(d,r[f+e],e);let o=r[f],s=r[f+1];f+=n;for(let e=1;e<t;e++,f+=n){o+=r[f]*c[0],s+=r[f+1]*c[1],r[f]=o,r[f+1]=s;for(let e=2;e<n;++e)r[f+e]=b(d,r[f+e],e)}}}function H(e,t,r,i){let n=0,o=e[i*t],s=e[i*(t+1)];for(let l=1;l<r;l++){let r=o+e[i*(t+l)],a=s+e[i*(t+l)+1],u=(r-o)*(a+s);o=r,s=a,n+=u}return.5*n}function V(e,t){let{coords:r,lengths:i}=e,n=0,o=0;for(let e=0;e<i.length;e++){let s=i[e];o+=H(r,n,s,t),n+=s}return Math.abs(o)}function W(e,t=0){e.length!==t&&(e.length=t)}const Q={originPosition:"lowerLeft",scale:[1,1,1,1],translate:[0,0,0,0]}},85113(e,t,r){r.d(t,{BM:()=>P,bd:()=>A,sO:()=>M,xD:()=>d});var i=r(67482),n=r(49186),o=r(21325),s=r(90708),l=r(43334),a=r(92722),u=r(30524);const p={LineString:"esriGeometryPolyline",MultiLineString:"esriGeometryPolyline",MultiPoint:"esriGeometryMultipoint",Point:"esriGeometryPoint",Polygon:"esriGeometryPolygon",MultiPolygon:"esriGeometryPolygon"};function d(e){return p[e]}function*c(e){switch(e.type){case"Feature":yield e;break;case"FeatureCollection":for(let t of e.features)t&&(yield t)}}function*y(e){if(e)switch(e.type){case"Point":yield e.coordinates;break;case"LineString":case"MultiPoint":yield*e.coordinates;break;case"MultiLineString":case"Polygon":for(let t of e.coordinates)yield*t;break;case"MultiPolygon":for(let t of e.coordinates)for(let e of t)yield*e}}function f(e){for(let t of e)if(t.length>2)return!0;return!1}function h(e){let t=0;for(let r=0;r<e.length;r++){let i=e[r],n=e[(r+1)%e.length];t+=i[0]*n[1]-n[0]*i[1]}return t<=0}function g(e){let t=e[0],r=e[e.length-1];(t[0]!==r[0]||t[1]!==r[1]||t[2]!==r[2])&&e.push(t)}function m(e,t){let{coordinates:r,type:i}=e,n=t.hasZ??!1;switch(i){case"Point":return new a.A([],[...r],n,!1);case"LineString":return(0,s.Ap)({paths:[r],hasZ:!0},n,!1);case"MultiLineString":return(0,s.Ap)({paths:r,hasZ:!0},n,!1);case"MultiPoint":return(0,s.PR)({points:r,hasZ:!0},n,!1);case"Polygon":case"MultiPolygon":{let e=new a.A([],[],n,!1);for(let t of"Polygon"===i?[r]:r){w(e,t[0],n);for(let r=1;r<t.length;r++)b(e,t[r],n)}return e}}}function w(e,t,r){g(t),function(e){return!h(e)}(t)?S(e,t,r):v(e,t,r)}function b(e,t,r){g(t),function(e){return h(e)}(t)?S(e,t,r):v(e,t,r)}function v(e,t,r){for(let i of t)C(e,i,r);e.lengths.push(t.length)}function S(e,t,r){for(let i=t.length-1;i>=0;i--)C(e,t[i],r);e.lengths.push(t.length)}function C(e,[t,r,i],n){e.coords.push(t,r),n&&e.coords.push(i||0)}function x(e){switch(typeof e){case"string":return(0,i.C)(e)?"esriFieldTypeDate":"esriFieldTypeString";case"number":return"esriFieldTypeDouble";default:return"unknown"}}function M(e,t=4326){if(!e)throw new n.A("geojson-layer:empty","GeoJSON data is empty");if("Feature"!==e.type&&"FeatureCollection"!==e.type)throw new n.A("geojson-layer:unsupported-geojson-object","missing or not supported GeoJSON object type",{data:e});let{crs:r}=e;if(!r)return;let i="string"==typeof r?r:"name"===r.type?r.properties.name:"EPSG"===r.type?r.properties.code:null,s=(0,o.oT)({wkid:t})?RegExp(".*(CRS84H?|4326)$","i"):RegExp(`.*(${t})$`,"i");if(!i||!s.test(i))throw new n.A("geojson:unsupported-crs","unsupported GeoJSON 'crs' member",{crs:r})}function P(e,t={}){let r,i=[],n=new Set,o=new Set,s=!1,l=null,a=!1,{geometryType:p=null}=t;for(let t of c(e)){let{geometry:e,properties:c,id:h}=t;if((!e||(p||=d(e.type),d(e.type)===p))&&(s||=f(y(e)),a||(a=null!=h,a&&(r=typeof h,c&&(l=Object.keys(c).filter(e=>c[e]===h)))),c&&l&&a&&null!=h&&(l.length>1?l=l.filter(e=>c[e]===h):1===l.length&&(l=c[l[0]]===h?l:[])),c))for(let e in c){if(n.has(e))continue;let t=x(c[e]);if("unknown"===t){o.add(e);continue}o.delete(e),n.add(e);let r=(0,u.rS)(e);r&&i.push({name:r,alias:e,type:t})}}let h=(0,u.rS)(1===l?.length&&l[0]||null)??void 0;if(h)for(let e of i)if(e.name===h&&(0,u.WA)(e)){e.type="esriFieldTypeOID";break}return{fields:i,geometryType:p,hasZ:s,objectIdFieldName:h,objectIdFieldType:r,unknownFields:Array.from(o)}}function A(e,t){return Array.from(function*(e,t={}){let{geometryType:r,objectIdField:i}=t;for(let n of e){let{geometry:e,properties:o,id:s}=n;if(e&&d(e.type)!==r)continue;let a,u=o||{};i&&(a=u[i],null!=s&&!a&&(u[i]=a=s)),yield new l.Om(e&&m(e,t),u,null,a)}}(c(e),t))}},64714(e,t,r){r.d(t,{F0:()=>l,Vx:()=>p,e2:()=>c,f:()=>h});var i=r(44208),n=r(4718),o=r(99352),s=r(93470);function l(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?s.Cb:"esriGeometryPolyline"===e?s.yM:s.WR}}}const a=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function p(e,t){if((0,i.A)("esri-csp-restrictions"))return()=>t?{[t]:null,...e}:{...e};try{let r="";t&&(r+=`this${d(t)} = null;`);for(let t in e)r+=`this${d(t)} = ${JSON.stringify(e[t])};`;let i=Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${r};\n }\n }\n `)();return()=>new i}catch{return()=>t?{[t]:null,...e}:{...e}}}function d(e){return a.test(e)?`.${e}`:`[${JSON.stringify(e)}]`}function c(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,n.o8)(e)}}]}const y={...o.F,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!1,supportsDistance:!1,supportsExtent:!1,supportsQuantization:!1,supportsQueryGeometry:!1,supportsDisjointSpatialRelationship:!1},f={...o.P,supportedStatistics:{...o.P.supportedStatistics,envelope:!1,centroid:!1,convexHull:!1}};function h(e,t,r=!1){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportedCurveTypes:[],supportsAttachment:!1,supportsM:!1,supportsTrueCurve:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:r?y:o.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:r?f:o.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsTrueCurveUpdate:t,supportsTrueCurveUpdateByTrueCurveClientsOnly:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},69208(e,t,r){var i=r(32198),n=r(91429);r.d(t,["d",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.customParameters=null}};return(0,i.Cg)([(0,n.MZ)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],r.prototype,"customParameters",void 0),r=(0,i.Cg)([(0,n.$K)("esri.layers.mixins.CustomParametersMixin")],r),r}])},32756(e,t,r){r.d(t,{Rr:()=>l});var i=r(32198),n=r(93637),o=r(91429),s=r(91880);function l(e,t,r){if(!e)return null;let i=e.find(e=>!!e.field);if(!i)return null;let n=new s.A;return n.read(i,r),[n]}const a={type:[s.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:l},write:{writer:function(e,t,r,i){let o=e.find(e=>!!e.field);o&&(0,n.sM)(r,[o.toJSON()],t)}}}};r.d(t,["fY",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,i.Cg)([(0,o.MZ)(a)],r.prototype,"orderBy",void 0),r=(0,i.Cg)([(0,o.$K)("esri.layers.mixins.OrderedLayer")],r),r},"ne",0,a])},8303(e,t,r){var i=r(32198),n=r(92602),o=r(70333),s=r(56507),l=r(60999),a=r(49186),u=r(36563),p=r(53966),d=r(97768),c=r(17676),y=r(84952),f=r(91429),h=r(77548),g=r(20655),m=r(80812),w=r(41318),b=r(10407),v=r(26121),S=r(36005),C=r(43937);const x={credential:null,user:null};r.d(t,["A",0,e=>{let t=e,M=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){super.destroy(),this.portalItem=(0,d.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}get portalItem(){return this._get("portalItem")}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new m.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{let{load:i}=await r.e(1204).then(()=>r(41204));return(0,c.Te)(t),await i({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,c.zf)(e)||p.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async reloadFromPortal(e,t){if(!this.loaded||!this.portalItem?.id)return!1;let i=t?.signal?null:new AbortController;try{let{reload:n}=await r.e(1204).then(()=>r(41204));return i&&this.addHandles((0,u.rE)(i),"reloadFromPortal"),await n({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t?.signal?t:{signal:i.signal})}catch(e){throw(0,c.zf)(e)||p.A.getLogger(this).warn(`Failed to reload layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}finally{i&&this.removeHandles("reloadFromPortal")}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,c.QP)(e),!0)))}async setUserPrivileges(e,t){if(!n.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{let{features:{edit:r,fullEdit:i},content:{updateItem:n}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",i),this._set("userHasUpdateItemPrivileges",n)}catch(e){(0,c.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);let i,n,s=!o.id?.findCredential(this.url),l=e===r.id;if(l&&r.portal.user)return this._getUserPrivileges(r,s);if(l)i=r.portal.url;else try{i=await(0,h.wI)(this.url,t)}catch(e){(0,c.QP)(e)}if(!i||!(0,y.b8)(i,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{let e=null==t?null:t.signal;n=await(o.id?.getCredential(`${i}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,c.QP)(e)}if(!n)return{features:{edit:!0,fullEdit:!1},content:{updateItem:!1}};try{if(l?await r.reload():(r=new m.default({id:e,portal:{url:i}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,s)}catch(e){(0,c.QP)(e)}return{features:{edit:!0,fullEdit:!1},content:{updateItem:!1}}}_getUserPrivileges(e,t){let r=(0,b.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,c.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){let t=this.url?o.id?.findCredential(this.url):null;if(!t)return!0;let r=x.credential===t?x.user:await this._fetchEditingUser(e);return x.credential=t,x.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){let t=this.portalItem?.portal?.user;if(t)return t;let r=o.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;let i=`${r.owningSystemUrl}/sharing/rest`,n=g.A.getDefault();if(n&&n.loaded&&(0,y.S8)(n.restUrl)===(0,y.S8)(i))return n.user;let a=`${i}/community/self`,u=null==e?null:e.signal,p=await(0,l.Ke)((0,s.A)(a,{authMode:"no-prompt",query:{f:"json"},signal:u}));return p.ok?w.A.fromJSON(p.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){return(0,v.wN)(this.portalItem,t)?(t?.messages?.push(new a.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,i.Cg)([(0,f.MZ)({type:m.default})],M.prototype,"portalItem",null),(0,i.Cg)([(0,S.w)("web-document","portalItem",["itemId"])],M.prototype,"readPortalItem",null),(0,i.Cg)([(0,C.K)("web-document","portalItem",{itemId:{type:String}})],M.prototype,"writePortalItem",null),(0,i.Cg)([(0,f.MZ)({clonable:!1})],M.prototype,"resourceReferences",void 0),(0,i.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],M.prototype,"userHasEditingPrivileges",void 0),(0,i.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],M.prototype,"userHasFullEditingPrivileges",void 0),(0,i.Cg)([(0,f.MZ)({type:Boolean,readOnly:!0})],M.prototype,"userHasUpdateItemPrivileges",void 0),M=(0,i.Cg)([(0,f.$K)("esri.layers.mixins.PortalLayer")],M),M}])},82935(e,t,r){var i=r(32198),n=r(91429),o=r(30524),s=r(96184),l=r(73133),a=r(79677),u=r(10184),p=r(36005);const d={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation"}}};r.d(t,["B",0,d,"e",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){let r=t.timeInfo.exportOptions;if(!r)return null;let i=r.timeOffset,n=l.j.fromJSON(r.timeOffsetUnits);return i&&n?new u.A({value:i,unit:n}):null}get timeInfo(){return this._get("timeInfo")}set timeInfo(e){(0,o.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,i.Cg)([(0,n.MZ)({type:a.A,json:{write:!1}})],r.prototype,"timeExtent",void 0),(0,i.Cg)([(0,n.MZ)({type:u.A})],r.prototype,"timeOffset",void 0),(0,i.Cg)([(0,p.w)("service","timeOffset",["timeInfo.exportOptions"])],r.prototype,"readOffset",null),(0,i.Cg)([(0,n.MZ)({value:null,type:s.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],r.prototype,"timeInfo",null),(0,i.Cg)([(0,n.MZ)(d)],r.prototype,"useViewTime",void 0),r=(0,i.Cg)([(0,n.$K)("esri.layers.mixins.TemporalLayer")],r),r}])},34322(e,t,r){r.d(t,{E:()=>L,Fu:()=>C,O8:()=>T,UH:()=>k,YW:()=>I,mG:()=>F,x$:()=>j});var i=r(56507),n=r(49186),o=r(5479),s=r(84952),l=r(5443),a=r(99917),u=r(16930),p=r(21325),d=r(50498),c=r(85113),y=r(13043),f=r(60694),h=r(20437),g=r(30524);const m="xlink:href",w="2.0.0",b="__esri_wfs_id__",v="wfs-layer:feature-type-not-found",S="wfs-layer:unknown-geometry-type";async function C(e,t){let r=function(e){let t=N(e);(function(e){let t=e.firstElementChild?.getAttribute("version");if(t&&t!==w)throw new n.A("wfs-layer:unsupported-wfs-version",`Unsupported WFS version ${t}. Supported version: ${w}`)})(t),G(t);let r=t.firstElementChild,i=(0,o.PP)(function(e){return(0,y.i)(e,{FeatureTypeList:{FeatureType:e=>{let t={typeName:"undefined:undefined",name:"",title:"",description:"",extent:null,namespacePrefix:"",namespaceUri:"",defaultSpatialReference:4326,supportedSpatialReferences:[]},r=new Set;return(0,y.p)(e,{Name:e=>{let{name:r,prefix:i}=_(e.textContent);t.typeName=`${i}:${r}`,t.name=r,t.namespacePrefix=i,t.namespaceUri=e.lookupNamespaceURI(i)},Abstract:e=>{t.description=e.textContent},Title:e=>{t.title=e.textContent},WGS84BoundingBox:e=>{t.extent=l.A.fromJSON(function(e){let t,r,i,n;for(let o of e.children)switch(o.localName){case"LowerCorner":[t,r]=o.textContent.split(" ").map(e=>Number.parseFloat(e));break;case"UpperCorner":[i,n]=o.textContent.split(" ").map(e=>Number.parseFloat(e))}return{xmin:t,ymin:r,xmax:i,ymax:n,spatialReference:p.KK}}(e))},DefaultCRS:e=>{let i=A(e);i&&(t.defaultSpatialReference=i,r.add(i))},OtherCRS:e=>{let t=A(e);t&&r.add(t)}}),t.title||=t.name,r.add(4326),t.supportedSpatialReferences.push(...r),t}}})}(r));return{operations:P(r),get featureTypes(){return Array.from(i())},readFeatureTypes:i}}((await(0,i.A)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"GetCapabilities",VERSION:w,...t?.customParameters},signal:t?.signal})).data);return function(e,t){(0,s.m3)(e)&&((0,s.FX)(e,t.operations.DescribeFeatureType.url,!0)&&(t.operations.DescribeFeatureType.url=(0,s.lM)(t.operations.DescribeFeatureType.url)),(0,s.FX)(e,t.operations.GetFeature.url,!0)&&(t.operations.GetFeature.url=(0,s.lM)(t.operations.GetFeature.url)))}(e,r),r}const x=["json","application/json; subtype=geojson; charset=utf-8","application/json; subtype=geojson","application/json","geojson","application/geo+json"];function M(e){for(let t of x){let r=e.findIndex(e=>e.toLowerCase()===t);if(r>=0)return e[r]}return null}function P(e){let t=!0,r={GetCapabilities:{url:""},DescribeFeatureType:{url:""},GetFeature:{url:"",outputFormat:null,supportsPagination:!1}},i=[],o=[];if((0,y.p)(e,{OperationsMetadata:{Parameter:e=>{if("outputformat"===e.getAttribute("name")?.toLowerCase())return{AllowedValues:{Value:({textContent:e})=>{e&&i.push(e)}}}},Operation:e=>{switch(e.getAttribute("name")){case"GetCapabilities":return{DCP:{HTTP:{Get:e=>{r.GetCapabilities.url=e.getAttribute(m)}}}};case"DescribeFeatureType":return{DCP:{HTTP:{Get:e=>{r.DescribeFeatureType.url=e.getAttribute(m)}}}};case"GetFeature":return{DCP:{HTTP:{Get:e=>{r.GetFeature.url=e.getAttribute(m)}}},Parameter:e=>{if("outputformat"===e.getAttribute("name")?.toLowerCase())return{AllowedValues:{Value:({textContent:e})=>{e&&o.push(e)}}}}}}},Constraint:e=>{switch(e.getAttribute("name")){case"KVPEncoding":return{DefaultValue:e=>{t="true"===e.textContent.toLowerCase()}};case"ImplementsResultPaging":return{DefaultValue:e=>{r.GetFeature.supportsPagination="true"===e.textContent.toLowerCase()}}}}}}),r.GetFeature.outputFormat=M(o)??M(i),!t)throw new n.A("wfs-layer:kvp-encoding-not-supported","WFS service doesn't support key/value pair (KVP) encoding");if(null==r.GetFeature.outputFormat)throw new n.A("wfs-layer:geojson-not-supported","WFS service doesn't support GeoJSON output format");return r}function A(e){let t=parseInt(e.textContent?.match(/(?<wkid>\d+$)/i)?.groups?.wkid??"",10);if(!Number.isNaN(t))return t}function F(e,t,r){return(0,o.I6)(e,e=>r?e.name===t&&e.namespaceUri===r:e.typeName===t||e.name===t)}async function T(e,t,r,i={}){let{featureType:o,extent:s}=await async function(e,t,r,i={}){let o=e.readFeatureTypes(),s=t?F(o,t,r):o.next().value,{spatialReference:l=new u.A({wkid:s?.defaultSpatialReference})}=i;if(null==s)throw t?new n.A(v,`The type '${t}' could not be found in the service`):new n.A("wfs-layer:empty-service","The service is empty");let d=s.extent;if(d&&!(0,p.aI)(d.spatialReference,l))try{await(0,a.initializeProjection)(d.spatialReference,l,void 0,i),d=(0,a.project)(d,l)}catch{throw new n.A("wfs-layer:unsupported-spatial-reference","Projection not supported")}return{extent:d,spatialReference:l,featureType:s}}(e,t,r,i),{spatialReference:l}=k(e.operations.GetFeature.url,o,i.spatialReference),{fields:d,geometryType:c,swapXY:y,objectIdField:f,geometryField:h}=await async function(e,t,r,i={}){let{typeName:o}=t,[s,l]=await Promise.allSettled([R(e.operations.DescribeFeatureType.url,o,i),O(e,o,r,i)]),a=e=>{let t=`An error occurred while getting info about the feature type '${o}'`;return new n.A("wfs-layer:getWFSLayerTypeInfo-error",t,{error:e})};if("rejected"===s.status)throw a(s.reason);if("rejected"===l.status)throw a(l.reason);let{fields:u,errors:p}=s.value??{},d=s.value?.geometryType||l.value?.geometryType,c=l.value?.swapXY??!1;if(null==d)throw new n.A(S,`The geometry type could not be determined for type '${o}`,{typeName:o,geometryType:d,fields:u,errors:p});return{...I(u??[]),geometryType:d,swapXY:c}}(e,o,l,i);return{url:e.operations.GetCapabilities.url,name:o.name,namespaceUri:o.namespaceUri,fields:d,geometryField:h,geometryType:c,objectIdField:f,spatialReference:i.spatialReference??new u.A({wkid:o.defaultSpatialReference}),extent:s,swapXY:y,wfsCapabilities:e,customParameters:i.customParameters}}function I(e){let t=e.find(e=>"geometry"===e.type),r=e.find(e=>"oid"===e.type);return e=e.filter(e=>"geometry"!==e.type),r||(r=new h.A({name:b,type:"oid",alias:b}),e.unshift(r)),{geometryField:t?.name??null,objectIdField:r.name,fields:e}}async function O(e,t,r,n={}){let o,s=!1,[l,a]=await Promise.all([j(e.operations.GetFeature.url,t,r,e.operations.GetFeature.outputFormat,{...n,count:1}),(0,i.A)(e.operations.GetFeature.url,{responseType:"text",query:E(t,r,void 0,{...n,count:1}),signal:n?.signal})]),u="FeatureCollection"===l.type&&l.features[0]?.geometry;if(u){let e;switch(o=d.gy.fromJSON((0,c.xD)(u.type)),u.type){case"Point":e=u.coordinates;break;case"LineString":case"MultiPoint":e=u.coordinates[0];break;case"MultiLineString":case"Polygon":e=u.coordinates[0][0];break;case"MultiPolygon":e=u.coordinates[0][0][0]}let t=/<[^>]*pos[^>]*> *(-?\d+(?:\.\d+)?) (-?\d+(?:\.\d+)?)/.exec(a.data);if(t){let r=e[0].toFixed(3),i=e[1].toFixed(3),n=parseFloat(t[1]).toFixed(3);r===parseFloat(t[2]).toFixed(3)&&i===n&&(s=!0)}}return{geometryType:o,swapXY:s}}async function R(e,t,r){return function(e,t){let{name:r}=_(e),i=N(t);G(i);let s=(0,o.I6)((0,y.i)(i.firstElementChild,{element:e=>e}),e=>e.getAttribute("name")===r);if(null!=s){let e=s.getAttribute("type"),t=e?(0,o.I6)((0,y.i)(i.firstElementChild,{complexType:e=>e}),t=>t.getAttribute("name")===_(e).name):(0,o.I6)((0,y.i)(s,{complexType:e=>e}),()=>!0);if(t)return function(e){let t,r=[],i=[],o=(0,y.i)(e,{complexContent:{extension:{sequence:{element:e=>e}}}});for(let s of o){let o,l,a=s.getAttribute("name");if(!a)continue;if(s.hasAttribute("type")?o=_(s.getAttribute("type")).name:(0,y.p)(s,{simpleType:{restriction:e=>(o=_(e.getAttribute("base")).name,{maxLength:e=>{l=+e.getAttribute("value")}})}}),!o)continue;let u="true"===s.getAttribute("nillable"),p=!1;switch(o.toLowerCase()){case"integer":case"nonpositiveinteger":case"negativeinteger":case"long":case"int":case"short":case"byte":case"nonnegativeinteger":case"unsignedlong":case"unsignedint":case"unsignedshort":case"unsignedbyte":case"positiveinteger":i.push(new h.A({name:a,alias:a,type:"integer",nullable:u,length:(0,g._b)("integer")}));break;case"float":case"double":case"decimal":i.push(new h.A({name:a,alias:a,type:"double",nullable:u,length:(0,g._b)("double")}));break;case"boolean":case"string":case"gyearmonth":case"gyear":case"gmonthday":case"gday":case"gmonth":case"anyuri":case"qname":case"notation":case"normalizedstring":case"token":case"language":case"idrefs":case"entities":case"nmtoken":case"nmtokens":case"name":case"ncname":case"id":case"idref":case"entity":case"duration":case"time":i.push(new h.A({name:a,alias:a,type:"string",nullable:u,length:l??(0,g._b)("string")}));break;case"datetime":case"date":i.push(new h.A({name:a,alias:a,type:"date",nullable:u,length:l??(0,g._b)("date")}));break;case"pointpropertytype":t="point",p=!0;break;case"multipointpropertytype":t="multipoint",p=!0;break;case"curvepropertytype":case"multicurvepropertytype":case"multilinestringpropertytype":t="polyline",p=!0;break;case"surfacepropertytype":case"multisurfacepropertytype":case"multipolygonpropertytype":t="polygon",p=!0;break;case"geometrypropertytype":case"multigeometrypropertytype":p=!0,r.push(new n.A(S,`geometry type '${o}' is not supported`,{type:(new XMLSerializer).serializeToString(e)}));break;default:r.push(new n.A("wfs-layer:unknown-field-type",`Unknown field type '${o}'`,{type:(new XMLSerializer).serializeToString(e)}))}p&&i.push(new h.A({name:a,alias:a,type:"geometry",nullable:u}))}for(let e of i)if("integer"===e.type&&!e.nullable&&Z.has(e.name.toLowerCase())){e.type="oid";break}return{geometryType:t,fields:i,errors:r}}(t)}throw new n.A(v,`Type '${e}' not found in document`,{document:(new XMLSerializer).serializeToString(i)})}(t,(await(0,i.A)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"DescribeFeatureType",VERSION:w,TYPENAME:t,TYPENAMES:t,...r?.customParameters},signal:r?.signal})).data)}const Z=new Set(["objectid","fid"]);async function j(e,t,r,o,s){let{data:l}=await(0,i.A)(e,{responseType:"text",query:E(t,r,o,s),signal:s?.signal});l=l.replaceAll(/": +(-?\d+),(\d+)(,)?/g,'": $1.$2$3');try{return JSON.parse(l)}catch(e){throw new n.A("wfs-layer:malformed-json","Error while parsing the response",{response:l,error:e})}}function E(e,t,r,i){let n="number"==typeof t?t:t.wkid;return{SERVICE:"WFS",REQUEST:"GetFeature",VERSION:w,TYPENAMES:e,OUTPUTFORMAT:r,SRSNAME:"EPSG:"+n,STARTINDEX:i?.startIndex,COUNT:i?.count,...i?.customParameters}}async function L(e,t,r){let n=await(0,i.A)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"GetFeature",VERSION:w,TYPENAMES:t,RESULTTYPE:"hits",...r?.customParameters},signal:r?.signal}),o=/numberMatched=["'](?<numberMatched>\d+)["']/gi.exec(n.data);if(o?.groups)return+o.groups.numberMatched}function N(e){return(new DOMParser).parseFromString(e.trim(),"text/xml")}function _(e){let[t,r]=e.split(":");return{prefix:r?t:"",name:r??t}}function G(e){let t="",r="";if((0,y.p)(e.firstElementChild,{Exception:e=>(t=e.getAttribute("exceptionCode"),{ExceptionText:e=>{r=e.textContent}})}),t)throw new n.A(`wfs-layer:${t}`,r)}function k(e,t,r){let i={wkid:t.defaultSpatialReference},n=null==r?.wkid?i:{wkid:r.wkid};return{spatialReference:n,getFeatureSpatialReference:(0,f.Fi)(e)||n.wkid&&t.supportedSpatialReferences.includes(n.wkid)?{wkid:n.wkid}:{wkid:t.defaultSpatialReference}}}r.d(t,["i5",0,b])},13043(e,t,r){function i(e,t){if(e&&t)for(let r of e.children)if(r.localName in t){let e=t[r.localName];if("function"==typeof e){let t=e(r);t&&i(r,t)}else i(r,e)}}function*n(e,t){for(let r of e.children)if(r.localName in t){let e=t[r.localName];"function"==typeof e?yield e(r):yield*n(r,e)}}r.d(t,{i:()=>n,p:()=>i})},46499(e,t,r){r.d(t,{A:()=>M});var i,n,o=r(32198),s=(r(44208),r(66552)),l=r(25482),a=r(4718),u=r(90629),p=r(91429),d=r(90360),c=r(73913),y=r(32730),f=r(77548),h=r(59868),g=r(73838),m=r(33910),w=r(36005),b=r(43937);const v=new s.J({esriServerPointLabelPlacementAboveCenter:"above-center",esriServerPointLabelPlacementAboveLeft:"above-left",esriServerPointLabelPlacementAboveRight:"above-right",esriServerPointLabelPlacementBelowCenter:"below-center",esriServerPointLabelPlacementBelowLeft:"below-left",esriServerPointLabelPlacementBelowRight:"below-right",esriServerPointLabelPlacementCenterCenter:"center-center",esriServerPointLabelPlacementCenterLeft:"center-left",esriServerPointLabelPlacementCenterRight:"center-right",esriServerLinePlacementAboveAfter:"above-after",esriServerLinePlacementAboveAlong:"above-along",esriServerLinePlacementAboveBefore:"above-before",esriServerLinePlacementAboveStart:"above-start",esriServerLinePlacementAboveEnd:"above-end",esriServerLinePlacementBelowAfter:"below-after",esriServerLinePlacementBelowAlong:"below-along",esriServerLinePlacementBelowBefore:"below-before",esriServerLinePlacementBelowStart:"below-start",esriServerLinePlacementBelowEnd:"below-end",esriServerLinePlacementCenterAfter:"center-after",esriServerLinePlacementCenterAlong:"center-along",esriServerLinePlacementCenterBefore:"center-before",esriServerLinePlacementCenterStart:"center-start",esriServerLinePlacementCenterEnd:"center-end",esriServerPolygonPlacementAlwaysHorizontal:"always-horizontal"},{ignoreUnknown:!0});function S(e,t,r){return{enabled:!(0,f.TU)(r?.layer)}}function C(e){return!e||"service"!==e.origin&&"map-image"!==e.layer?.type}function x(e){return!!function(e){return"map-image"===e?.type}(e)&&!!e.capabilities?.exportMap?.supportsArcadeExpressionForLabeling}let M=class extends l.o{static{i=y.vK}static{n=this}static evaluateWhere(e,t){let r=(e,t,r)=>{switch(t){case"=":return e==r;case"<>":return e!=r;case">":return e>r;case">=":return e>=r;case"<":return e<r;case"<=":return e<=r}return!1};try{if(null==e)return!0;let i=e.split(" ");if(3===i.length)return r(t[i[0]],i[1],i[2]);if(7===i.length){let e=r(t[i[0]],i[1],i[2]),n=i[3],o=r(t[i[4]],i[5],i[6]);switch(n){case"AND":return e&&o;case"OR":return e||o}}return!1}catch{}}constructor(e){super(e),this[i]=!0,this.type="label",this.name=null,this.allowOverrun=!1,this.deconflictionStrategy="static",this.labelExpression=null,this.labelExpressionInfo=null,this.labelPlacement=null,this.offsetDistance=0,this.labelPosition="curved",this.maxScale=0,this.minScale=0,this.repeatLabel=!0,this.symbol=h.Hk,this.useCodedValues=void 0,this.where=null}readLabelExpression(e,t){let r=t.labelExpressionInfo;if(!r||!r.value&&!r.expression)return e}writeLabelExpression(e,t,r){if(this.labelExpressionInfo)if(null!=this.labelExpressionInfo.value)e=(0,y.D3)(this.labelExpressionInfo.value);else if(null!=this.labelExpressionInfo.expression){let t=(0,y.tH)(this.labelExpressionInfo.expression);t&&(e="["+t+"]")}null!=e&&(t[r]=e)}writeLabelExpressionInfo(e,t,r,i){if(null==e&&null!=this.labelExpression&&C(i))e=new c.A({expression:this.getLabelExpressionArcade()});else if(!e)return;let n=e.toJSON(i);n.expression&&(t[r]=n)}writeMaxScale(e,t){(e||this.minScale)&&(t.maxScale=e)}writeMinScale(e,t){(e||this.maxScale)&&(t.minScale=e)}get repeatLabelDistance(){return this._get("repeatLabelDistance")}set repeatLabelDistance(e){this._set("repeatLabelDistance",e)}getLabelExpression(){return(0,y.XJ)(this)}getLabelExpressionArcade(){return(0,y.BI)(this)}getLabelExpressionSingleField(){return(0,y.rU)(this)}hash(){return JSON.stringify(this)}clone(){return new n({allowOverrun:this.allowOverrun,deconflictionStrategy:this.deconflictionStrategy,labelExpression:this.labelExpression,labelExpressionInfo:(0,a.o8)(this.labelExpressionInfo),labelPosition:this.labelPosition,labelPlacement:this.labelPlacement,offsetDistance:this.offsetDistance,maxScale:this.maxScale,minScale:this.minScale,name:this.name,repeatLabel:this.repeatLabel,repeatLabelDistance:this.repeatLabelDistance,symbol:(0,a.o8)(this.symbol),where:this.where,useCodedValues:this.useCodedValues})}};(0,o.Cg)([(0,p.MZ)({type:String,json:{write:!0}})],M.prototype,"name",void 0),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:!0,default:!1,origins:{"web-scene":{write:!1},"portal-item":{default:!1,write:{overridePolicy:S}}}}})],M.prototype,"allowOverrun",void 0),(0,o.Cg)([(0,p.MZ)({type:String,json:{write:!0,default:"static",origins:{"web-scene":{write:!1},"portal-item":{default:"static",write:{overridePolicy:S}}}}})],M.prototype,"deconflictionStrategy",void 0),(0,o.Cg)([(0,p.MZ)({type:String,json:{write:{overridePolicy(e,t,r){return this.labelExpressionInfo&&"service"===r?.origin&&x(r.layer)?{enabled:!1}:{allowNull:!0}}}}})],M.prototype,"labelExpression",void 0),(0,o.Cg)([(0,w.w)("labelExpression")],M.prototype,"readLabelExpression",null),(0,o.Cg)([(0,b.K)("labelExpression")],M.prototype,"writeLabelExpression",null),(0,o.Cg)([(0,p.MZ)({type:c.A,json:{write:{overridePolicy:(e,t,r)=>function(e){return C(e)||x(e?.layer)}(r)?{allowNull:!0}:{enabled:!1}}}})],M.prototype,"labelExpressionInfo",void 0),(0,o.Cg)([(0,b.K)("labelExpressionInfo")],M.prototype,"writeLabelExpressionInfo",null),(0,o.Cg)([(0,p.MZ)({type:v.apiValues,json:{type:v.jsonValues,read:v.read,write:v.write}})],M.prototype,"labelPlacement",void 0),(0,o.Cg)([(0,p.MZ)({type:Number,json:{read:!0,write:!0,default:0,origins:{"web-scene":{write:!1}}}})],M.prototype,"offsetDistance",void 0),(0,o.Cg)([(0,p.MZ)({type:["curved","parallel"],json:{write:!0,origins:{"web-map":{write:!1},"web-scene":{write:!1},"portal-item":{write:!1}}}})],M.prototype,"labelPosition",void 0),(0,o.Cg)([(0,p.MZ)({type:Number})],M.prototype,"maxScale",void 0),(0,o.Cg)([(0,b.K)("maxScale")],M.prototype,"writeMaxScale",null),(0,o.Cg)([(0,p.MZ)({type:Number})],M.prototype,"minScale",void 0),(0,o.Cg)([(0,b.K)("minScale")],M.prototype,"writeMinScale",null),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:!0,origins:{"web-scene":{write:!1},"portal-item":{write:{overridePolicy:S}}}}})],M.prototype,"repeatLabel",void 0),(0,o.Cg)([(0,p.MZ)({type:Number,cast:u.cr,json:{write:!0,origins:{"web-scene":{write:!1},"portal-item":{write:{overridePolicy:S}}}}})],M.prototype,"repeatLabelDistance",null),(0,o.Cg)([(0,p.MZ)({types:m.em,json:{types:m.em,origins:{"portal-item":{types:m.em,read:{reader:(0,d.C)({types:m.em})},default:null},"web-scene":{types:m.Rv,read:{reader:(0,d.C)({types:m.Rv})},write:g.oO,default:null}},write:g.oO,default:null}})],M.prototype,"symbol",void 0),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:!0}})],M.prototype,"useCodedValues",void 0),(0,o.Cg)([(0,p.MZ)({type:String,json:{write:!0}})],M.prototype,"where",void 0),M=n=(0,o.Cg)([(0,p.$K)("esri.layers.support.LabelClass")],M)},73913(e,t,r){r.d(t,{A:()=>p});var i,n=r(32198),o=r(25482),s=r(91429),l=r(32730),a=r(36005),u=r(43937);let p=class extends o.o{static{i=this}constructor(e){super(e),this.name=null,this.expression=null,this.title=null,this.value=null}readExpression(e,t){return t.value?(0,l.mX)(t.value):e}writeExpression(e,t,r){null!=this.value&&(e=(0,l.mX)(this.value)),null!=e&&(t[r]=e)}clone(){return new i({name:this.name,expression:this.expression,title:this.title,value:this.value})}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0,origins:{"web-scene":{write:!1}}}})],p.prototype,"name",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:{writerEnsuresNonNull:!0}}})],p.prototype,"expression",void 0),(0,n.Cg)([(0,a.w)("expression",["expression","value"])],p.prototype,"readExpression",null),(0,n.Cg)([(0,u.K)("expression")],p.prototype,"writeExpression",null),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0,origins:{"web-scene":{write:!1}}}})],p.prototype,"title",void 0),(0,n.Cg)([(0,s.MZ)({json:{read:!1,write:!1}})],p.prototype,"value",void 0),p=i=(0,n.Cg)([(0,s.$K)("esri.layers.support.LabelExpressionInfo")],p)},91880(e,t,r){r.d(t,{A:()=>u});var i,n=r(32198),o=r(66552),s=r(25482),l=r(91429);const a=new o.J({asc:"ascending",desc:"descending"});let u=class extends s.o{static{i=this}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,n.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],u.prototype,"field",void 0),(0,n.Cg)([(0,l.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],u.prototype,"valueExpression",void 0),(0,n.Cg)([(0,l.MZ)({type:a.apiValues,json:{type:a.jsonValues,read:a.read,write:a.write}})],u.prototype,"order",void 0),u=i=(0,n.Cg)([(0,l.$K)("esri.layers.support.OrderByInfo")],u)},41560(e,t,r){r.d(t,{Ch:()=>s,mW:()=>o});var i=r(34727),n=r(39516);function o(e,t){return{...t,filterMode:e.mode}}function s(e,t,r){let o=function(e){if("manual"===u(e))return null;let t=[-1/0,1/0];for(let{minScale:r,maxScale:i}of e.filters)t[0]=Math.max(t[0],p(r)),t[1]=Math.min(t[1],d(i));return t}(e);if(o&&((0,i.gg)(t,o[0])||(0,i.ZH)(r,o[1])))return"";let s=Array.from(l(e,t,r)),a=function(e,t,r){if(0===e.length)return!0;let n=p(e.at(0)?.minScale),o=d(e.at(-1)?.maxScale);if((0,i.ZH)(n,t)||(0,i.gg)(o,r))return!0;for(let t=0;t<e.length-1;t++){let r=e[t],n=e[t+1];if((0,i.ZH)(p(n.minScale),d(r.maxScale)))return!0}return!1}(s,t,r)?"1=1":s.map(e=>e.where||"1=1").reduce((e,t)=>(0,n.IW)(e,t),"");return a&&"1=1"!==a?a:""}function*l(e,t,r){if("manual"===u(e)){let t=e.filters.find(t=>t.id===e.activeFilterId);t&&(yield t)}else{"object"==typeof t&&(t=t.scale);for(let i of e.filters)a(i.minScale,i.maxScale,t,r)&&(yield i)}}function a(e,t,r,n){return e=p(e),r=p(r),t=d(t),!(!(0,i.Sp)(r,e)&&(n??r)>e||(0,i.Hx)(t,r)||void 0!==n&&(0,i.Sp)(n,e))}function u(e){return"mode"in e?e.mode:e.filterMode}function p(e){return e||1/0}function d(e){return e||0}},17036(e,t,r){r.d(t,{p:()=>a});var i=r(44208),n=r(53966),o=r(20437),s=r(95466),l=r(30524);function a(){return{fields:{type:[o.A],value:null,set:function(e){if(e&&(0,i.A)("big-integer-warning-enabled")){let t=e.filter(e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8);if(t.length){let e=t.map(e=>`'${e.name}'`).join(", ");n.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${2**53-1} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return s.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){let e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(let t of e)this.fieldsIndex?.has(t)||n.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e});return(0,l.DB)(this.fieldsIndex,e)}}}}},39383(e,t,r){r.d(t,{w:()=>a,z:()=>d});var i=r(49186),n=r(53966),o=r(46499);const s=()=>n.A.getLogger("esri.layers.support.labelingInfo"),l=/\[([^[\]]+)\]/gi;function a(e,t,r){return e?e.map(e=>{let i=new o.A;if(i.read(e,r),i.labelExpression){let e=t.fields||t.layerDefinition?.fields||this.fields;i.labelExpression=i.labelExpression.replaceAll(l,(t,r)=>`[${function(e,t){if(!t)return e;let r=e.toLowerCase();for(let e=0;e<t.length;e++){let i=t[e].name;if(i.toLowerCase()===r)return i}return e}(r,e)}]`)}return i}):null}const u=["above-right","above-center","above-left","center-center","center-left","center-right","below-center","below-left","below-right"],p={esriGeometryPoint:u,esriGeometryMultiPatch:["always-horizontal"],esriGeometryPolygon:["always-horizontal"],esriGeometryPolyline:["center-along","above-along","below-along"],esriGeometryMultipoint:u,esriGeometryEnvelope:null};function d(e,t){let r=[];for(let n of e){let e=n.labelPlacement,o=p[t];if(!n.symbol)return s().warn("No ILabelClass symbol specified."),[];if(!o)return s().error(new i.A("labeling:unsupported-geometry-type",`Unable to create labels for layer, geometry type '${t}' is not supported`)),[];if(o.includes(e))r.push(n);else{let i=o[0];e&&s().warn(`Found invalid label placement type ${e} for ${t}. Defaulting to ${i}`);let l=n.clone();l.labelPlacement=i,r.push(l)}}return r}},73681(e,t,r){r.d(t,{n:()=>a});var i=r(49186),n=r(53966),o=r(46140),s=r(95466),l=r(55674);class a{static async from(e,t,r){let s=e.dictionary_version?o.A.parse(e.dictionary_version):null,p=new Set(e.itemsNames),d={};if(t)for(let e in t)d[e]=t[e];if(e.authoringInfo.configuration)for(let t of e.authoringInfo.configuration)d.hasOwnProperty(t.name)||(d[t.name]=t.value);let c=new Set(e.authoringInfo.symbol);for(let e of Object.keys(r))c.delete(e);c.size&&n.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:c});let y=await(0,l.xR)(e.expression,null,d);if(!y)throw new i.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");let f=!s||!s.greaterEqual(4,0);f&&n.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:s});let h=new u(r,f);return new a(f,p,y,h)}constructor(e,t,r,i){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=i}get itemNames(){return this._itemNames}evaluate(e,t,r,i){try{return this._reader.bind(e,r,i),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){n.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new s.A(e);let t=e.map(e=>({...e,type:"esriFieldTypeString"}));return new s.A(t)}}class u extends l.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){let t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);let t=this._getField(e);return null==t||null==this._boundTarget.attributes[t.name]?"":""+this._boundTarget.attributes[t.name]}}},37745(e,t,r){r.r(t),r.d(t,{default:()=>c});var i,n=r(32198),o=r(52106),s=r(4718),l=r(91429);let a=class extends o.A{static{i=this}constructor(e){super(e),this.stackedAttributes=null}cloneShallow(){return new i(Object.assign({stackedAttributes:this.stackedAttributes},super.cloneShallow()))}toJSON(){return{...super.toJSON(),stackedAttributes:(0,s.o8)(this.stackedAttributes)}}};(0,n.Cg)([(0,l.MZ)()],a.prototype,"stackedAttributes",void 0),a=i=(0,n.Cg)([(0,l.$K)("esri.AttributeBinsGraphic")],a);var u=r(69540),p=r(22671),d=r(36005);let c=class extends((0,u.OU)(p.A)){constructor(e){super(e),this.features=[]}readFeatures(e,t){return this.readFeaturesWithClass(e,t,a)}};(0,n.Cg)([(0,l.MZ)({type:[a],json:{write:!0}})],c.prototype,"features",void 0),(0,n.Cg)([(0,d.w)("features")],c.prototype,"readFeatures",null),c=(0,n.Cg)([(0,l.$K)("esri.rest.support.AttributeBinsFeatureSet")],c)},22671(e,t,r){r.d(t,{A:()=>w});var i,n=r(32198),o=r(52106),s=r(66552),l=r(25482),a=r(4718),u=r(91429),p=r(16930),d=r(60408),c=r(65864),y=r(50498),f=r(20437),h=r(36005),g=r(43937);const m=new s.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let w=i=class extends l.o{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){return this.readFeaturesWithClass(e,t,o.A)}writeGeometryType(e,t,r,i){if(e)return void m.write(e,t,r,i);let{features:n}=this;if(n)for(let e of n)if(null!=e?.geometry)return void m.write(e.geometry.type,t,r,i)}readQueryGeometry(e,t){if(!e)return null;let r=!!e.spatialReference,i=(0,c.rS)(e);return i&&!r&&t.spatialReference&&(i.spatialReference=p.A.fromJSON(t.spatialReference)),i}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());let{features:r}=this;if(r)for(let e of r)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new i(this.cloneProperties())}cloneProperties(){return(0,a.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){let t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){let i=t.features[r];i.geometry&&=(e?.[r])?.toJSON()||i.geometry}return t}quantize(e){let{scale:[t,r],translate:[i,n]}=e,o=this.features,s=this._getQuantizationFunction(this.geometryType,e=>Math.round((e-i)/t),e=>Math.round((n-e)/r));for(let e=0,t=o.length;e<t;e++)s?.(o[e].geometry)||(o.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){let{geometryType:e,features:t,transform:r}=this;if(!r)return this;let{translate:[i,n],scale:[o,s]}=r,l=null,a=null;if(this.hasZ&&null!=r?.scale?.[2]){let{translate:[,,e],scale:[,,t]}=r;l=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){let{translate:[,,,e],scale:[,,,t]}=r;a=r=>null==r?r:r*t+e}let u=this._getHydrationFunction(e,e=>e*o+i,e=>n-e*s,l,a);for(let{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}readFeaturesWithClass(e,t,r){let i=p.A.fromJSON(t.spatialReference),n=[];for(let t=0;t<e.length;t++){let o=e[t],s=r.fromJSON(o),l=o.geometry?.spatialReference;null!=s.geometry&&!l&&(s.geometry.spatialReference=i);let a=o.aggregateGeometries,u=s.aggregateGeometries;if(a&&null!=u)for(let e in u){let t=u[e],r=a[e]?.spatialReference;null!=t&&!r&&(t.spatialReference=i)}n.push(s)}return n}_quantizePoints(e,t,r){let i,n,o=[];for(let s=0,l=e.length;s<l;s++){let l=e[s];if(s>0){let e=t(l[0]),s=r(l[1]);(e!==i||s!==n)&&(o.push([e-i,s-n]),i=e,n=s)}else i=t(l[0]),n=r(l[1]),o.push([i,n])}return o.length>0?o:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{let i=(0,d.Bi)(e)?e.rings:e.paths,n=[];for(let e=0,o=i.length;e<o;e++){let o=i[e],s=this._quantizePoints(o,t,r);s&&n.push(s)}return n.length>0?((0,d.Bi)(e)?e.rings=n:e.paths=n,e):null}:"multipoint"===e?e=>{let i=this._quantizePoints(e.points,t,r);return i&&i.length>0?(e.points=i,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r,i,n){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y),i&&(e.z=i(e.z))}:"polyline"===e||"polygon"===e?e=>{let o,s,l=(0,d.Bi)(e)?e.rings:e.paths;for(let e=0,i=l.length;e<i;e++){let i=l[e];for(let e=0,n=i.length;e<n;e++){let n=i[e];e>0?(o+=n[0],s+=n[1]):(o=n[0],s=n[1]),n[0]=t(o),n[1]=r(s)}}if(i&&n)for(let e=0,t=l.length;e<t;e++){let t=l[e];for(let e=0,r=t.length;e<r;e++){let r=t[e];r[2]=i(r[2]),r[3]=n(r[3])}}else if(i)for(let e=0,t=l.length;e<t;e++){let t=l[e];for(let e=0,r=t.length;e<r;e++){let r=t[e];r[2]=i(r[2])}}else if(n)for(let e=0,t=l.length;e<t;e++){let t=l[e];for(let e=0,r=t.length;e<r;e++){let r=t[e];r[2]=n(r[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=r(e.ymin),e.xmax=t(e.xmax),e.ymax=r(e.ymax),i&&null!=e.zmax&&null!=e.zmin&&(e.zmax=i(e.zmax),e.zmin=i(e.zmin)),n&&null!=e.mmax&&null!=e.mmin&&(e.mmax=n(e.mmax),e.mmin=n(e.mmin))}:"multipoint"===e?e=>{let o,s,l=e.points;for(let e=0,i=l.length;e<i;e++){let i=l[e];e>0?(o+=i[0],s+=i[1]):(o=i[0],s=i[1]),i[0]=t(o),i[1]=r(s)}if(i&&n)for(let e=0,t=l.length;e<t;e++){let t=l[e];t[2]=i(t[2]),t[3]=n(t[3])}else if(i)for(let e=0,t=l.length;e<t;e++){let t=l[e];t[2]=i(t[2])}else if(n)for(let e=0,t=l.length;e<t;e++){let t=l[e];t[2]=n(t[2])}}:null}};(0,n.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],w.prototype,"displayFieldName",void 0),(0,n.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"exceededTransferLimit",void 0),(0,n.Cg)([(0,u.MZ)({type:[o.A],json:{write:!0}})],w.prototype,"features",void 0),(0,n.Cg)([(0,h.w)("features")],w.prototype,"readFeatures",null),(0,n.Cg)([(0,u.MZ)({type:[f.A],json:{write:!0}})],w.prototype,"fields",void 0),(0,n.Cg)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:m.read}}})],w.prototype,"geometryType",void 0),(0,n.Cg)([(0,g.K)("geometryType")],w.prototype,"writeGeometryType",null),(0,n.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"hasM",void 0),(0,n.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"hasZ",void 0),(0,n.Cg)([(0,u.MZ)({types:y.yR,json:{write:!0}})],w.prototype,"queryGeometry",void 0),(0,n.Cg)([(0,h.w)("queryGeometry")],w.prototype,"readQueryGeometry",null),(0,n.Cg)([(0,u.MZ)({type:p.A,json:{write:!0}})],w.prototype,"spatialReference",void 0),(0,n.Cg)([(0,g.K)("spatialReference")],w.prototype,"writeSpatialReference",null),(0,n.Cg)([(0,u.MZ)({json:{write:!0}})],w.prototype,"transform",void 0),w=i=(0,n.Cg)([(0,u.$K)("esri.rest.support.FeatureSet")],w),w.prototype.toJSON.isDefaultToJSON=!0},41366(e,t,r){var i=r(32198),n=r(66552),o=r(53966),s=r(91429),l=r(93223);const a=(0,n.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),u="percent-of-total",p="field";r.d(t,["K",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.normalizationField=null,this.normalizationMaxValue=null,this.normalizationMinValue=null,this.normalizationTotal=null}get normalizationType(){let e=this._get("normalizationType"),t=!!this.normalizationField,r=null!=this.normalizationTotal;return t||r?(e=t&&p||r&&u||null,t&&r&&o.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):(e===p||e===u)&&(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,i.Cg)([(0,s.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],r.prototype,"normalizationField",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],r.prototype,"normalizationMaxValue",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],r.prototype,"normalizationMinValue",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],r.prototype,"normalizationTotal",void 0),(0,i.Cg)([(0,l.e)(a,{name:"parameters.normalizationType"})],r.prototype,"normalizationType",null),r=(0,i.Cg)([(0,s.$K)("esri.rest.support.NormalizationBinParametersMixin")],r),r},"Q",0,a])},93470(e,t,r){const i=[252,146,31,255],n={type:"esriSMS",style:"esriSMSCircle",size:6,color:i,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:i};r.d(t,["Cb",0,n,"HW",0,{type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},"JR",0,[153,153,153,255],"JZ",0,{type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},"WR",0,{type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},"b6",0,{type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null},"fT",0,i,"nC",0,{type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},"yM",0,o])},26121(e,t,r){r.d(t,{I6:()=>p,ci:()=>u,dL:()=>a,wN:()=>d});var i=r(49186),n=r(84952),o=r(77548),s=r(20655),l=r(59923);async function a(e){let t=[];for(let r of e.allLayers)if("beforeSave"in r&&"function"==typeof r.beforeSave){let e=r.beforeSave();e&&t.push(e)}await Promise.allSettled(t)}function u(e,t,r){let n=(e.messages??[]).filter(({type:e})=>"error"===e).map(({name:e,message:t,details:r})=>new i.A(e,t,r));if(e.blockedRelativeUrls&&(n=n.concat(e.blockedRelativeUrls.map(e=>(0,l.GL)("url",`Relative url '${e}' is not supported`)))),r){let{ignoreUnsupported:e,supplementalUnsupportedErrors:t=[],requiredPropertyChecksDisabled:i}=r;e&&(n=n.filter(({name:e})=>!(l.MG.has(e)||t.includes(e)))),i&&(n=n.filter(e=>"web-document-write:property-required"!==e.name))}if(n.length>0)throw new i.A(t.errorName,"Failed to save due to unsupported or invalid content. See 'details.errors' for more detailed information",{errors:n})}function p(e){return(0,o.qd)(e).some(e=>!!e.charts?.length)}function d(e,t){let r=t?.portal,i=e?.id&&(e.portal||s.A.getDefault());return!!r&&!!i&&!(0,n.ut)(i.restUrl,r.restUrl)}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8846],{28846(e,t,r){r.d(t,{convertMeshVertexSpace:()=>u});var o=r(49186),s=r(4718),i=r(17676),l=r(1193),n=r(66895),c=r(72258);async function u(e,t,r){await Promise.resolve(),(0,i.Te)(r);let u=(0,c.UR)(e,t,{useEllipsoid:r?.useEllipsoid});if(!u)throw new o.A("meshUtils:convertVertexSpace()","Failed to convert to provided vertex space due to projection errors");return e.clone((0,n.Lz)(void 0,{vertexAttributes:new l.A({...u,uv:(0,s.o8)(e.vertexAttributes.uv),color:(0,s.o8)(e.vertexAttributes.color)}),vertexSpace:t,transform:null}))}}}]);